From 191ad0f1abbbec923c7d3c1fbd3ab703c425b23e Mon Sep 17 00:00:00 2001 From: "sj.hwang" Date: Fri, 24 Feb 2017 09:57:18 +0900 Subject: [PATCH 0001/1347] Add LineStart, LineEnd to CursorMovePosition --- src/vs/editor/common/editorCommon.ts | 3 +++ src/vs/monaco.d.ts | 2 ++ 2 files changed, 5 insertions(+) diff --git a/src/vs/editor/common/editorCommon.ts b/src/vs/editor/common/editorCommon.ts index 56720ba9b62..2efe42f96a1 100644 --- a/src/vs/editor/common/editorCommon.ts +++ b/src/vs/editor/common/editorCommon.ts @@ -4190,6 +4190,9 @@ export const CursorMovePosition = { Up: 'up', Down: 'down', + LineStart: 'lineStart', + LineEnd: 'lineEnd', + WrappedLineStart: 'wrappedLineStart', WrappedLineFirstNonWhitespaceCharacter: 'wrappedLineFirstNonWhitespaceCharacter', WrappedLineColumnCenter: 'wrappedLineColumnCenter', diff --git a/src/vs/monaco.d.ts b/src/vs/monaco.d.ts index 04c2f68d897..edf37cb5bdc 100644 --- a/src/vs/monaco.d.ts +++ b/src/vs/monaco.d.ts @@ -3320,6 +3320,8 @@ declare module monaco.editor { Right: string; Up: string; Down: string; + LineStart: string; + LineEnd: string; WrappedLineStart: string; WrappedLineFirstNonWhitespaceCharacter: string; WrappedLineColumnCenter: string; -- GitLab From 7ed7dcadd4dd2e03e5397ed55b38554116a392a5 Mon Sep 17 00:00:00 2001 From: "sj.hwang" Date: Fri, 24 Feb 2017 17:36:38 +0900 Subject: [PATCH 0002/1347] Change behavior of home/end button --- src/vs/editor/common/controller/cursor.ts | 10 ++- src/vs/editor/common/controller/oneCursor.ts | 64 ++++++++++++++++++++ 2 files changed, 72 insertions(+), 2 deletions(-) diff --git a/src/vs/editor/common/controller/cursor.ts b/src/vs/editor/common/controller/cursor.ts index 76bff2078a1..a7aebc64093 100644 --- a/src/vs/editor/common/controller/cursor.ts +++ b/src/vs/editor/common/controller/cursor.ts @@ -1234,11 +1234,17 @@ export class Cursor extends EventEmitter { } private _moveToBeginningOfLine(inSelectionMode: boolean, ctx: IMultipleCursorOperationContext): boolean { - return this._invokeForAll(ctx, (cursorIndex: number, oneCursor: OneCursor, oneCtx: IOneCursorOperationContext) => OneCursorOp.moveToBeginningOfLine(oneCursor, inSelectionMode, oneCtx)); + ctx.eventData = ctx.eventData || {}; + ctx.eventData.to = editorCommon.CursorMovePosition.LineStart; + ctx.eventData.select = inSelectionMode; + return this._cursorMove(ctx); } private _moveToEndOfLine(inSelectionMode: boolean, ctx: IMultipleCursorOperationContext): boolean { - return this._invokeForAll(ctx, (cursorIndex: number, oneCursor: OneCursor, oneCtx: IOneCursorOperationContext) => OneCursorOp.moveToEndOfLine(oneCursor, inSelectionMode, oneCtx)); + ctx.eventData = ctx.eventData || {}; + ctx.eventData.to = editorCommon.CursorMovePosition.LineEnd; + ctx.eventData.select = inSelectionMode; + return this._cursorMove(ctx); } private _moveToBeginningOfBuffer(inSelectionMode: boolean, ctx: IMultipleCursorOperationContext): boolean { diff --git a/src/vs/editor/common/controller/oneCursor.ts b/src/vs/editor/common/controller/oneCursor.ts index 877dca6350c..18869925a1e 100644 --- a/src/vs/editor/common/controller/oneCursor.ts +++ b/src/vs/editor/common/controller/oneCursor.ts @@ -537,6 +537,10 @@ export class OneCursorOp { return this._moveUp(cursor, moveParams, ctx); case editorCommon.CursorMovePosition.Down: return this._moveDown(cursor, moveParams, ctx); + case editorCommon.CursorMovePosition.LineStart: + return this._moveToLineStart(cursor, moveParams, ctx); + case editorCommon.CursorMovePosition.LineEnd: + return this._moveToLineEnd(cursor, moveParams, ctx); case editorCommon.CursorMovePosition.WrappedLineStart: viewColumn = cursor.viewModel.getLineMinColumn(viewLineNumber); break; @@ -695,6 +699,66 @@ export class OneCursorOp { ); } + private static _moveToLineStart(cursor: OneCursor, moveArguments: CursorMoveArguments, ctx: IOneCursorOperationContext): boolean { + const currentViewStateColumn = cursor.viewState.position.column; + const currentModelStateColumn = cursor.modelState.position.column; + const isFirstLineOfWrappedLine = currentViewStateColumn === currentModelStateColumn; + + const currentViewStatelineNumber = cursor.viewState.position.lineNumber; + const firstNonBlankColumn = cursor.viewModel.getLineFirstNonWhitespaceColumn(currentViewStatelineNumber); + const isBeginningOfViewLine = currentViewStateColumn === firstNonBlankColumn; + + if (!isFirstLineOfWrappedLine && !isBeginningOfViewLine) { + return this._moveToLineStartByView(cursor, moveArguments.select, ctx); + } else { + return this._moveToLineStartByModel(cursor, moveArguments.select, ctx); + } + } + + private static _moveToLineStartByView(cursor: OneCursor, inSelectionMode: boolean, ctx: IOneCursorOperationContext): boolean { + return this._applyMoveOperationResult( + cursor, ctx, + this._fromViewCursorState(cursor, MoveOperations.moveToBeginningOfLine(cursor.config, cursor.viewModel, cursor.viewState, inSelectionMode)) + ); + } + + private static _moveToLineStartByModel(cursor: OneCursor, inSelectionMode: boolean, ctx: IOneCursorOperationContext): boolean { + return this._applyMoveOperationResult( + cursor, ctx, + this._fromModelCursorState(cursor, MoveOperations.moveToBeginningOfLine(cursor.config, cursor.model, cursor.modelState, inSelectionMode)) + ); + } + + private static _moveToLineEnd(cursor: OneCursor, moveArguments: CursorMoveArguments, ctx: IOneCursorOperationContext): boolean { + const viewStatePosition = cursor.viewState.position; + const viewModelMaxColumn = cursor.viewModel.getLineMaxColumn(viewStatePosition.lineNumber); + const isEndOfViewLine = viewStatePosition.column === viewModelMaxColumn; + + const modelStatePosition = cursor.modelState.position; + const modelMaxColumn = cursor.model.getLineMaxColumn(modelStatePosition.lineNumber); + const isEndLineOfWrappedLine = viewModelMaxColumn - viewStatePosition.column === modelMaxColumn - modelStatePosition.column; + + if (isEndOfViewLine || isEndLineOfWrappedLine) { + return this._moveToLineEndByModel(cursor, moveArguments.select, ctx); + } else { + return this._moveToLineEndByView(cursor, moveArguments.select, ctx); + } + } + + private static _moveToLineEndByView(cursor: OneCursor, inSelectionMode: boolean, ctx: IOneCursorOperationContext): boolean { + return this._applyMoveOperationResult( + cursor, ctx, + this._fromViewCursorState(cursor, MoveOperations.moveToEndOfLine(cursor.config, cursor.viewModel, cursor.viewState, inSelectionMode)) + ); + } + + private static _moveToLineEndByModel(cursor: OneCursor, inSelectionMode: boolean, ctx: IOneCursorOperationContext): boolean { + return this._applyMoveOperationResult( + cursor, ctx, + this._fromModelCursorState(cursor, MoveOperations.moveToEndOfLine(cursor.config, cursor.model, cursor.modelState, inSelectionMode)) + ); + } + public static moveToBeginningOfLine(cursor: OneCursor, inSelectionMode: boolean, ctx: IOneCursorOperationContext): boolean { return this._applyMoveOperationResult( cursor, ctx, -- GitLab From 137f9307953690f3281c1dd5568604c01ed3b324 Mon Sep 17 00:00:00 2001 From: Cristian Date: Sat, 25 Mar 2017 17:37:41 +0200 Subject: [PATCH 0003/1347] #22622 - preliminary version --- src/vs/workbench/parts/debug/browser/media/debugHover.css | 5 ++++- src/vs/workbench/parts/debug/electron-browser/debugHover.ts | 4 ++-- src/vs/workbench/parts/debug/electron-browser/debugViewer.ts | 2 +- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/src/vs/workbench/parts/debug/browser/media/debugHover.css b/src/vs/workbench/parts/debug/browser/media/debugHover.css index 29707f09e11..ddf0a9a1246 100644 --- a/src/vs/workbench/parts/debug/browser/media/debugHover.css +++ b/src/vs/workbench/parts/debug/browser/media/debugHover.css @@ -29,7 +29,7 @@ word-break: normal; text-overflow: ellipsis; height: 18px; - overflow: hidden; + overflow: auto; border-bottom: 1px solid rgba(128, 128, 128, 0.35); } @@ -67,6 +67,9 @@ .monaco-editor .debug-hover-widget .value { white-space: pre-wrap; color: rgba(108, 108, 108, 0.8); + overflow: auto; + max-height: 500px; + z-index: 60; } .monaco-editor .debug-hover-widget .error { diff --git a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts index e88e4e549f5..2076624feee 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts @@ -236,7 +236,7 @@ export class DebugHoverWidget implements IContentWidget { this.valueContainer.hidden = false; renderExpressionValue(expression, this.valueContainer, { showChanged: false, - maxValueLength: MAX_VALUE_RENDER_LENGTH_IN_HOVER, + maxValueLength: null, preserveWhitespace: true }); this.valueContainer.title = ''; @@ -274,7 +274,7 @@ export class DebugHoverWidget implements IContentWidget { if (visibleElementsCount === 0) { this.doShow(this.showAtPosition, this.tree.getInput(), false, true); } else { - const height = Math.min(visibleElementsCount, MAX_ELEMENTS_SHOWN) * 18; + const height = visibleElementsCount * 18; //Math.min(visibleElementsCount, MAX_ELEMENTS_SHOWN) * 18; if (this.treeContainer.clientHeight !== height) { this.treeContainer.style.height = `${height}px`; diff --git a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts index f3847176b72..cba5ab1d7c3 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts @@ -76,7 +76,7 @@ export function renderExpressionValue(expressionOrValue: debug.IExpression | str container.className = 'value changed'; } - if (options.maxValueLength && value.length > options.maxValueLength) { + if (options.maxValueLength && options.maxValueLength > 0 && value.length > options.maxValueLength) { value = value.substr(0, options.maxValueLength) + '...'; } if (value && !options.preserveWhitespace) { -- GitLab From b30e1b71332b1bab2aba41b7fe71c45bc1c97a56 Mon Sep 17 00:00:00 2001 From: Cristian Date: Sat, 25 Mar 2017 17:38:17 +0200 Subject: [PATCH 0004/1347] #22622 - comment out MAX_VALUE_RENDER_LENGTH_IN_HOVER --- src/vs/workbench/parts/debug/electron-browser/debugHover.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts index 2076624feee..1ce0e87f3b7 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts @@ -24,7 +24,7 @@ import { IListService } from 'vs/platform/list/browser/listService'; const $ = dom.$; const MAX_ELEMENTS_SHOWN = 18; -const MAX_VALUE_RENDER_LENGTH_IN_HOVER = 4096; +//const MAX_VALUE_RENDER_LENGTH_IN_HOVER = 4096; export class DebugHoverWidget implements IContentWidget { @@ -274,7 +274,7 @@ export class DebugHoverWidget implements IContentWidget { if (visibleElementsCount === 0) { this.doShow(this.showAtPosition, this.tree.getInput(), false, true); } else { - const height = visibleElementsCount * 18; //Math.min(visibleElementsCount, MAX_ELEMENTS_SHOWN) * 18; + const height = Math.min(visibleElementsCount, MAX_ELEMENTS_SHOWN) * 18; if (this.treeContainer.clientHeight !== height) { this.treeContainer.style.height = `${height}px`; -- GitLab From 517dcacfd5dfe2291c23357e34bd185bfc021272 Mon Sep 17 00:00:00 2001 From: Cristian Date: Sat, 25 Mar 2017 17:44:22 +0200 Subject: [PATCH 0005/1347] #22622 removed comments --- src/vs/workbench/parts/debug/electron-browser/debugHover.ts | 1 - src/vs/workbench/parts/debug/electron-browser/debugViewer.ts | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts index 1ce0e87f3b7..68d1a179e8d 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts @@ -236,7 +236,6 @@ export class DebugHoverWidget implements IContentWidget { this.valueContainer.hidden = false; renderExpressionValue(expression, this.valueContainer, { showChanged: false, - maxValueLength: null, preserveWhitespace: true }); this.valueContainer.title = ''; diff --git a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts index cba5ab1d7c3..f3847176b72 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts @@ -76,7 +76,7 @@ export function renderExpressionValue(expressionOrValue: debug.IExpression | str container.className = 'value changed'; } - if (options.maxValueLength && options.maxValueLength > 0 && value.length > options.maxValueLength) { + if (options.maxValueLength && value.length > options.maxValueLength) { value = value.substr(0, options.maxValueLength) + '...'; } if (value && !options.preserveWhitespace) { -- GitLab From 4cd68b0acd2f88a42a48737da36213b52df4a96d Mon Sep 17 00:00:00 2001 From: Cristian Date: Sat, 25 Mar 2017 17:48:08 +0200 Subject: [PATCH 0006/1347] #22622 - removed comment --- src/vs/workbench/parts/debug/electron-browser/debugHover.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts index 68d1a179e8d..33e4a4e21e0 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts @@ -24,7 +24,6 @@ import { IListService } from 'vs/platform/list/browser/listService'; const $ = dom.$; const MAX_ELEMENTS_SHOWN = 18; -//const MAX_VALUE_RENDER_LENGTH_IN_HOVER = 4096; export class DebugHoverWidget implements IContentWidget { -- GitLab From 6cd2a1e17ff0ad703b59e2c3934053e82cb91fe0 Mon Sep 17 00:00:00 2001 From: Cristian Date: Sat, 15 Apr 2017 09:41:11 +0300 Subject: [PATCH 0007/1347] #22622 - removed z-index --- src/vs/workbench/parts/debug/browser/media/debugHover.css | 1 - 1 file changed, 1 deletion(-) diff --git a/src/vs/workbench/parts/debug/browser/media/debugHover.css b/src/vs/workbench/parts/debug/browser/media/debugHover.css index ddf0a9a1246..8fca6b6d66c 100644 --- a/src/vs/workbench/parts/debug/browser/media/debugHover.css +++ b/src/vs/workbench/parts/debug/browser/media/debugHover.css @@ -69,7 +69,6 @@ color: rgba(108, 108, 108, 0.8); overflow: auto; max-height: 500px; - z-index: 60; } .monaco-editor .debug-hover-widget .error { -- GitLab From 10c0610a6dafc5d7932126678f660e77c895e65c Mon Sep 17 00:00:00 2001 From: Eric Amodio Date: Wed, 12 Apr 2017 00:27:35 -0400 Subject: [PATCH 0008/1347] Fixes #944 - Support wildcards on activationEvents.workspaceContains --- src/vs/workbench/node/extensionHostMain.ts | 34 ++++++++++++++++++---- 1 file changed, 28 insertions(+), 6 deletions(-) diff --git a/src/vs/workbench/node/extensionHostMain.ts b/src/vs/workbench/node/extensionHostMain.ts index d84ec84c924..ae3bd6cb18b 100644 --- a/src/vs/workbench/node/extensionHostMain.ts +++ b/src/vs/workbench/node/extensionHostMain.ts @@ -12,6 +12,8 @@ import { join } from 'path'; import { IRemoteCom } from 'vs/platform/extensions/common/ipcRemoteCom'; import { ExtHostExtensionService } from 'vs/workbench/api/node/extHostExtensionService'; import { ExtHostThreadService } from 'vs/workbench/services/thread/common/extHostThreadService'; +import { QueryType, ISearchQuery } from 'vs/platform/search/common/search'; +import { DiskSearch } from 'vs/workbench/services/search/node/searchService'; import { RemoteTelemetryService } from 'vs/workbench/api/node/extHostTelemetry'; import { IWorkspaceContextService, WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { IInitData, IEnvironment, MainContext } from 'vs/workbench/api/node/extHost.protocol'; @@ -34,6 +36,7 @@ export class ExtensionHostMain { private _isTerminating: boolean = false; private _contextService: IWorkspaceContextService; + private _diskSearch: DiskSearch; private _environment: IEnvironment; private _extensionService: ExtHostExtensionService; @@ -122,13 +125,32 @@ export class ExtensionHostMain { } }); - const fileNames = Object.keys(desiredFilesMap); + const matchingPatterns = Object.keys(desiredFilesMap).map(p => { + // TODO: This is a bit hacky -- maybe this should be implemented by using something like + // `workspaceGlob` or something along those lines? + if (p.indexOf('*') > -1 || p.indexOf('?') > -1) { + if (!this._diskSearch) { + this._diskSearch = new DiskSearch(false); + } + + const query: ISearchQuery = { + folderResources: [workspace.resource], + type: QueryType.File, + maxResults: 1, + includePattern: { [p]: true } + }; + + return this._diskSearch.search(query).then(result => result.results.length ? p : undefined); + } else { + return pfs.exists(join(folderPath, p)).then(exists => exists ? p : undefined); + } + }); - return TPromise.join(fileNames.map(f => pfs.exists(join(folderPath, f)))).then(exists => { - fileNames - .filter((f, i) => exists[i]) - .forEach(fileName => { - const activationEvent = `workspaceContains:${fileName}`; + return TPromise.join(matchingPatterns).then(patterns => { + patterns + .filter(p => p !== undefined) + .forEach(p => { + const activationEvent = `workspaceContains:${p}`; this._extensionService.activateByEvent(activationEvent) .done(null, err => console.error(err)); -- GitLab From 3f4f7303a652e1a2be9158050ab8deaf49735501 Mon Sep 17 00:00:00 2001 From: Coenraad Stijne Date: Tue, 2 May 2017 12:51:23 +0200 Subject: [PATCH 0009/1347] expose stickyness decoration option --- src/vs/editor/common/editorCommon.ts | 1 + src/vs/vscode.d.ts | 16 ++++++++++++++++ src/vs/workbench/api/node/extHost.api.impl.ts | 3 ++- 3 files changed, 19 insertions(+), 1 deletion(-) diff --git a/src/vs/editor/common/editorCommon.ts b/src/vs/editor/common/editorCommon.ts index 4010e1e6175..036430cf02c 100644 --- a/src/vs/editor/common/editorCommon.ts +++ b/src/vs/editor/common/editorCommon.ts @@ -1616,6 +1616,7 @@ export interface IEditorContribution { * @internal */ export interface IThemeDecorationRenderOptions { + stickiness?: TrackedRangeStickiness; backgroundColor?: string; outline?: string; diff --git a/src/vs/vscode.d.ts b/src/vs/vscode.d.ts index 5b5cd0a27af..ac030fc7434 100644 --- a/src/vs/vscode.d.ts +++ b/src/vs/vscode.d.ts @@ -698,6 +698,16 @@ declare module 'vscode' { Full = 7 } + /** + * Describes the behaviour of decorations when typing/editing near their edges. + */ + export enum TrackedRangeStickiness { + AlwaysGrowsWhenTypingAtEdges = 0, + NeverGrowsWhenTypingAtEdges = 1, + GrowsOnlyWhenTypingBefore = 2, + GrowsOnlyWhenTypingAfter = 3 + } + /** * Represents options to configure the behavior of showing a [document](#TextDocument) in an [editor](#TextEditor). */ @@ -725,6 +735,12 @@ declare module 'vscode' { * Represents theme specific rendering styles for a [text editor decoration](#TextEditorDecorationType). */ export interface ThemableDecorationRenderOptions { + /** + * Customize the growing behaviour of the decoration when typing at the edges of the decoration. + * Defaults to TrackedRangeStickiness.AlwaysGrowsWhenTypingAtEdges + */ + stickiness?: TrackedRangeStickiness; + /** * Background color of the decoration. Use rgba() and define transparent background colors to play well with other decorations. */ diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index 4b84e46809a..bae49409524 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -515,6 +515,7 @@ export function createApiFactory( OverviewRulerLane: EditorCommon.OverviewRulerLane, ParameterInformation: extHostTypes.ParameterInformation, Position: extHostTypes.Position, + ProgressLocation: extHostTypes.ProgressLocation, Range: extHostTypes.Range, Selection: extHostTypes.Selection, SignatureHelp: extHostTypes.SignatureHelp, @@ -529,10 +530,10 @@ export function createApiFactory( TextEditorLineNumbersStyle: extHostTypes.TextEditorLineNumbersStyle, TextEditorRevealType: extHostTypes.TextEditorRevealType, TextEditorSelectionChangeKind: extHostTypes.TextEditorSelectionChangeKind, + TrackedRangeStickiness: EditorCommon.TrackedRangeStickiness, Uri: URI, ViewColumn: extHostTypes.ViewColumn, WorkspaceEdit: extHostTypes.WorkspaceEdit, - ProgressLocation: extHostTypes.ProgressLocation, // functions FileLocationKind: extHostTypes.FileLocationKind, ApplyToKind: extHostTypes.ApplyToKind, -- GitLab From bb77c3eb3417d971448ccc635bf4d3d93a65f4d1 Mon Sep 17 00:00:00 2001 From: Coenraad Stijne Date: Tue, 2 May 2017 14:55:30 +0200 Subject: [PATCH 0010/1347] set stickiness in codeeditorservice --- src/vs/editor/browser/services/codeEditorServiceImpl.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/vs/editor/browser/services/codeEditorServiceImpl.ts b/src/vs/editor/browser/services/codeEditorServiceImpl.ts index f79bca4879d..8782b344a49 100644 --- a/src/vs/editor/browser/services/codeEditorServiceImpl.ts +++ b/src/vs/editor/browser/services/codeEditorServiceImpl.ts @@ -204,6 +204,7 @@ class DecorationTypeOptionsProvider implements IModelDecorationOptionsProvider { ); this.isWholeLine = Boolean(options.isWholeLine); + this.stickiness = options.stickiness; if ( typeof themedOpts.light.overviewRulerColor !== 'undefined' -- GitLab From 3cbd4a1973c6317eb43eb9cefb99e301d396b1aa Mon Sep 17 00:00:00 2001 From: Young Rok Kim Date: Sat, 20 May 2017 14:24:38 +0900 Subject: [PATCH 0011/1347] Make TMScope inspector togglable (#19675) --- .../electron-browser/inspectTMScopes.ts | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes.ts b/src/vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes.ts index b0792b493ef..6b424655f7b 100644 --- a/src/vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes.ts +++ b/src/vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes.ts @@ -89,6 +89,14 @@ class InspectTMScopesController extends Disposable implements IEditorContributio this._widget = null; } } + + public toggle(): void { + if (!this._widget) { + this.launch(); + } else { + this.dispose(); + } + } } @editorAction @@ -106,7 +114,7 @@ class InspectTMScopes extends EditorAction { public run(accessor: ServicesAccessor, editor: ICommonCodeEditor): void { let controller = InspectTMScopesController.get(editor); if (controller) { - controller.launch(); + controller.toggle(); } } } -- GitLab From f459d5b17ea49f1e2fa4ae03eac318d67c37b2a6 Mon Sep 17 00:00:00 2001 From: Young Rok Kim Date: Sat, 20 May 2017 15:15:55 +0900 Subject: [PATCH 0012/1347] Add feature to close TMScope inspector with ESCAPE keyboard event --- .../inspectTMScopes/electron-browser/inspectTMScopes.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes.ts b/src/vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes.ts index 6b424655f7b..e407188b906 100644 --- a/src/vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes.ts +++ b/src/vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes.ts @@ -9,6 +9,7 @@ import * as nls from 'vs/nls'; import * as dom from 'vs/base/browser/dom'; import { Disposable } from 'vs/base/common/lifecycle'; import { escape } from 'vs/base/common/strings'; +import { KeyCode } from 'vs/base/common/keyCodes'; import { Position } from 'vs/editor/common/core/position'; import { ICommonCodeEditor, IEditorContribution, IModel } from 'vs/editor/common/editorCommon'; import { editorAction, EditorAction, ServicesAccessor } from 'vs/editor/common/editorCommonExtensions'; @@ -62,6 +63,7 @@ class InspectTMScopesController extends Disposable implements IEditorContributio this._register(this._editor.onDidChangeModel((e) => this.stop())); this._register(this._editor.onDidChangeModelLanguage((e) => this.stop())); + this._register(this._editor.onKeyUp((e) => e.keyCode === KeyCode.Escape && this.stop())); } public getId(): string { @@ -94,7 +96,7 @@ class InspectTMScopesController extends Disposable implements IEditorContributio if (!this._widget) { this.launch(); } else { - this.dispose(); + this.stop(); } } } -- GitLab From 905020f916acfce079e7092a0be0c6b9b9ddb27f Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Mon, 22 May 2017 13:56:23 +0200 Subject: [PATCH 0013/1347] Added smoke test source code. --- smoketest/.gitignore | 7 + smoketest/.vscode/launch.json | 26 + smoketest/.vscode/tasks.json | 10 + smoketest/CONTRIBUTING.md | 12 + smoketest/README.md | 10 + smoketest/package.json | 19 + smoketest/scripts/run.ps1 | 43 ++ smoketest/scripts/run.sh | 43 ++ smoketest/src/areas/common.ts | 163 +++++ smoketest/src/areas/configuration-views.ts | 62 ++ smoketest/src/areas/css.ts | 62 ++ smoketest/src/areas/data-loss.ts | 26 + smoketest/src/areas/extensions.ts | 49 ++ smoketest/src/areas/first-experience.ts | 21 + smoketest/src/areas/git.ts | 69 ++ smoketest/src/areas/integrated-terminal.ts | 38 + smoketest/src/areas/javascript-debug.ts | 42 ++ smoketest/src/areas/javascript.ts | 73 ++ smoketest/src/areas/localization.ts | 55 ++ smoketest/src/areas/search.ts | 50 ++ smoketest/src/areas/statusbar.ts | 99 +++ smoketest/src/areas/tasks.ts | 50 ++ smoketest/src/helpers/screenshot.ts | 48 ++ smoketest/src/helpers/utilities.ts | 37 + smoketest/src/main.ts | 771 +++++++++++++++++++++ smoketest/src/spectron/application.ts | 156 +++++ smoketest/src/spectron/client.ts | 127 ++++ smoketest/tsconfig.json | 21 + vscode-smoketest-express | 1 + 29 files changed, 2190 insertions(+) create mode 100644 smoketest/.gitignore create mode 100644 smoketest/.vscode/launch.json create mode 100644 smoketest/.vscode/tasks.json create mode 100644 smoketest/CONTRIBUTING.md create mode 100644 smoketest/README.md create mode 100644 smoketest/package.json create mode 100644 smoketest/scripts/run.ps1 create mode 100644 smoketest/scripts/run.sh create mode 100644 smoketest/src/areas/common.ts create mode 100644 smoketest/src/areas/configuration-views.ts create mode 100644 smoketest/src/areas/css.ts create mode 100644 smoketest/src/areas/data-loss.ts create mode 100644 smoketest/src/areas/extensions.ts create mode 100644 smoketest/src/areas/first-experience.ts create mode 100644 smoketest/src/areas/git.ts create mode 100644 smoketest/src/areas/integrated-terminal.ts create mode 100644 smoketest/src/areas/javascript-debug.ts create mode 100644 smoketest/src/areas/javascript.ts create mode 100644 smoketest/src/areas/localization.ts create mode 100644 smoketest/src/areas/search.ts create mode 100644 smoketest/src/areas/statusbar.ts create mode 100644 smoketest/src/areas/tasks.ts create mode 100644 smoketest/src/helpers/screenshot.ts create mode 100644 smoketest/src/helpers/utilities.ts create mode 100644 smoketest/src/main.ts create mode 100644 smoketest/src/spectron/application.ts create mode 100644 smoketest/src/spectron/client.ts create mode 100644 smoketest/tsconfig.json create mode 160000 vscode-smoketest-express diff --git a/smoketest/.gitignore b/smoketest/.gitignore new file mode 100644 index 00000000000..532798d3ea9 --- /dev/null +++ b/smoketest/.gitignore @@ -0,0 +1,7 @@ +.DS_Store +npm-debug.log +Thumbs.db +node_modules/ +out/ +keybindings.*.json +test_data/ \ No newline at end of file diff --git a/smoketest/.vscode/launch.json b/smoketest/.vscode/launch.json new file mode 100644 index 00000000000..2de33bbb20b --- /dev/null +++ b/smoketest/.vscode/launch.json @@ -0,0 +1,26 @@ +{ + // Use IntelliSense to learn about possible Node.js debug attributes. + // Hover to view descriptions of existing attributes. + // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 + "version": "0.2.0", + "configurations": [ + { + "type": "node", + "request": "launch", + "name": "Mocha Tests", + "program": "${workspaceRoot}/node_modules/mocha/bin/_mocha", + "args": [ + "-u", + "tdd", + "--timeout", + "999999", + "--colors", + "${workspaceRoot}/out/main.js" + ], + "outFiles": [ "${workspaceRoot}/out/**/*.js" ], + "internalConsoleOptions": "openOnSessionStart", + "sourceMaps": true, + "cwd": "${workspaceRoot}" + } + ] +} \ No newline at end of file diff --git a/smoketest/.vscode/tasks.json b/smoketest/.vscode/tasks.json new file mode 100644 index 00000000000..926b1ddcd18 --- /dev/null +++ b/smoketest/.vscode/tasks.json @@ -0,0 +1,10 @@ +{ + // See https://go.microsoft.com/fwlink/?LinkId=733558 + // for the documentation about the tasks.json format + "version": "0.1.0", + "command": "tsc", + "isShellCommand": true, + "args": ["-p", "."], + "showOutput": "silent", + "problemMatcher": "$tsc" +} \ No newline at end of file diff --git a/smoketest/CONTRIBUTING.md b/smoketest/CONTRIBUTING.md new file mode 100644 index 00000000000..c15016dc1ad --- /dev/null +++ b/smoketest/CONTRIBUTING.md @@ -0,0 +1,12 @@ +# Architecture +* `main.ts` contains the main smoke test suite. It includes all tests separated into mocha `describe()` groups that represent each of the areas of [Smoke Test document](https://github.com/Microsoft/vscode/wiki/Smoke-Test). + +* `./areas/` folder contains a `.ts` file per each area of the document. E.g. `'Search'` area goes under `'search.ts'`. Every area file contains a list of methods with the name that represents the action that can be performed in the corresponding test. This reduces the amount of test suite code and means that if the UI changes, the fix need only be applied in one place. The name of the method reflects the action the tester would do if he would perform the test manually. See [Selenium Page Objects Wiki](https://github.com/SeleniumHQ/selenium/wiki/PageObjects) and [Selenium Bot Style Tests Wiki](https://github.com/SeleniumHQ/selenium/wiki/Bot-Style-Tests) for a good explanation of the implementation. Every smoke test area contains methods that are used in a bot-style approach in `main.ts`. +* `./spectron/` wraps the Spectron, with WebDriverIO API wrapped in `client.ts` and instance of Spectron Application is wrapped in `application.ts`. +* `./scripts/` contains scripts to run the smoke test. + +# Adding new area +To contribute a new smoke test area, add `${area}.ts` file under `./areas`. This has to follow the bot-style approach described in the links mentioned above. Methods should be calling WebDriverIO API through `SpectronClient` class. If there is no existing WebDriverIO method, add it to the class. + +# Adding new test +To add new test area or test, `main.ts` should be updated. The same instruction-style principle needs to be followed with the called area method names that reflect manual tester's actions. \ No newline at end of file diff --git a/smoketest/README.md b/smoketest/README.md new file mode 100644 index 00000000000..318ddb07517 --- /dev/null +++ b/smoketest/README.md @@ -0,0 +1,10 @@ +# VS Code Smoke Testing +This repository contains the smoke test automation code with Spectron for Visual Studio Code. + +The following command is used to run the tests: `.\scripts\run.ps1 -latest "path\to\Code.exe"` on Windows (from PowerShell) and `./scripts/run.sh path/to/binary` on Unix system. + +If you want to include 'Data Migration' area tests use `.\scripts\run.ps1 -latest "path\to\Code.exe" -stable "path\to\CurrentStable.exe"` and `./scripts/run.sh path/to/binary path/to/currentStable` respectively. + +# Contributing + +This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments. diff --git a/smoketest/package.json b/smoketest/package.json new file mode 100644 index 00000000000..a5c3a78273b --- /dev/null +++ b/smoketest/package.json @@ -0,0 +1,19 @@ +{ + "name": "code-oss-dev-smoke-test", + "version": "0.1.0", + "main": "./out/main.js", + "scripts": { + "test": "mocha -u tdd --timeout 360000 --retries 2 --slow 50000 --colors ./out/main.js 2> test_data/errors.log" + }, + "devDependencies": { + "@types/mocha": "^2.2.41", + "@types/node": "^6.0.70", + "@types/webdriverio": "^4.6.1", + "@types/electron": "^1.4.37", + "@types/rimraf": "^0.0.28", + "mocha": "^3.2.0", + "spectron": "^3.6.4", + "typescript": "^2.2.2", + "rimraf": "^2.6.1" + } +} diff --git a/smoketest/scripts/run.ps1 b/smoketest/scripts/run.ps1 new file mode 100644 index 00000000000..d6368da6890 --- /dev/null +++ b/smoketest/scripts/run.ps1 @@ -0,0 +1,43 @@ +Param( + [Parameter(Position=0,mandatory=$true)] + [string] $latest, + [Parameter(Position=1,mandatory=$false)] + [string] $stable +) + +# Setup sample repository for the smoke test +Set-Location .. +if (-Not (Test-Path vscode-smoketest-express)) { + git clone https://github.com/Microsoft/vscode-smoketest-express.git + Set-Location ./vscode-smoketest-express +} else { + Set-Location ./vscode-smoketest-express + git fetch origin master + git reset --hard FETCH_HEAD + git clean -fd +} +npm install + +# Setup the test directory for running +Set-Location ..\smoketest +if (-Not (Test-Path node_modules)) { + npm install +} + +# Configure environment variables +$env:VSCODE_LATEST_PATH = $latest +$env:VSCODE_STABLE_PATH = $stable +$env:SMOKETEST_REPO = "..\vscode-smoketest-express" + +if ($latest.Contains('Insiders')) { + $env:VSCODE_EDITION = 'insiders' +} + +# Retrieve key bindings config file for Windows +$testDirectory = (Resolve-Path .\).Path +$client = New-Object System.Net.WebClient +$client.DownloadFile("https://raw.githubusercontent.com/Microsoft/vscode-docs/master/scripts/keybindings/doc.keybindings.win.json","$testDirectory\test_data\keybindings.win32.json") + +# Compile and launch the smoke test +tsc +npm test \ No newline at end of file diff --git a/smoketest/scripts/run.sh b/smoketest/scripts/run.sh new file mode 100644 index 00000000000..fc103a55539 --- /dev/null +++ b/smoketest/scripts/run.sh @@ -0,0 +1,43 @@ +#!/usr/bin/env bash +if [[ "$#" -ne 1 ]]; then + echo "Usage: ./scripts/run.sh path/to/binary" + echo "To perform data migration tests, use: ./scripts/run.sh path/to/latest_binary path/to/stable_binary" + exit 1 +fi + +# Cloning sample repository for the smoke test +cd .. +if ! [ -d vscode-smoketest-express ]; then + git clone https://github.com/Microsoft/vscode-smoketest-express.git + cd vscode-smoketest-express +else + cd vscode-smoketest-express + git fetch origin master + git reset --hard FETCH_HEAD + git clean -fd +fi +npm install + +# Install Node modules for Spectron +cd ../vscode-smoketest +test -d node_modules || npm install + +# Configuration +export VSCODE_LATEST_PATH="$1" +export VSCODE_STABLE_PATH="$2" +export SMOKETEST_REPO="../vscode-smoketest-express" +mkdir -p test_data + +if [[ $1 == *"Insiders"* || $1 == *"insiders"* ]]; then + export VSCODE_EDITION="insiders" +fi + +if [[ "$OSTYPE" == "darwin"* ]]; then + curl "https://raw.githubusercontent.com/Microsoft/vscode-docs/master/scripts/keybindings/doc.keybindings.osx.json" -o "test_data/keybindings.darwin.json" # Download OS X keybindings +else + wget https://raw.githubusercontent.com/Microsoft/vscode-docs/master/scripts/keybindings/doc.keybindings.linux.json -O test_data/keybindings.linux.json # Download Linux keybindings +fi + +# Compile and launch the smoke test +tsc +exec npm test diff --git a/smoketest/src/areas/common.ts b/smoketest/src/areas/common.ts new file mode 100644 index 00000000000..c955c206eea --- /dev/null +++ b/smoketest/src/areas/common.ts @@ -0,0 +1,163 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from "../spectron/application"; +import { Util } from '../helpers/utilities'; + +/** + * Contains methods that are commonly used across test areas. + */ +export class CommonActions { + private util: Util; + + constructor(private spectron: SpectronApplication) { + this.util = new Util(); + } + + public async getWindowTitle(): Promise { + return this.spectron.client.getTitle(); + } + + public enter(): Promise { + return this.spectron.client.keys(['Enter', 'NULL']); + } + + public async addSetting(setting: string, value: string): Promise { + await this.spectron.command('workbench.action.openGlobalSettings'); + await this.spectron.wait(); + await this.spectron.client.leftClick('.editable-preferences-editor-container .view-lines', 1, 1, false); + await this.spectron.client.keys(['ArrowDown', 'NULL', 'ArrowDown', 'NULL'], false); + await this.spectron.wait(); + await this.spectron.client.keys(`"${setting}": "${value}"`); + await this.spectron.wait(); + return this.saveOpenedFile(); + } + + public async newUntitledFile(): Promise { + await this.spectron.command('workbench.action.files.newUntitledFile'); + return this.spectron.wait(); + } + + public closeTab(): Promise { + return this.spectron.client.keys(['Control', 'w', 'NULL']); + } + + public async getTab(tabName: string, active?: boolean): Promise { + let tabSelector = active ? '.tab.active' : 'div'; + let el = await this.spectron.client.element(`.tabs-container ${tabSelector}[aria-label="${tabName}, tab"]`); + if (el.status === 0) { + return el; + } + + return undefined; + } + + public selectTab(tabName: string): Promise { + return this.spectron.client.click(`.tabs-container div[aria-label="${tabName}, tab"]`); + } + + public async openFirstMatchFile(fileName: string): Promise { + await this.openQuickOpen(); + await this.type(fileName); + await this.spectron.wait(); + await this.enter(); + return this.spectron.wait(); + } + + public saveOpenedFile(): Promise { + return this.spectron.command('workbench.action.files.save'); + } + + public type(text: string): Promise { + let spectron = this.spectron; + + return new Promise(function (res) { + let textSplit = text.split(' '); + + async function type(i: number) { + if (!textSplit[i] || textSplit[i].length <= 0) { + return res(); + } + + const toType = textSplit[i + 1] ? `${textSplit[i]} ` : textSplit[i]; + await spectron.client.keys(toType, false); + await spectron.client.keys(['NULL']); + await type(i + 1); + } + + return type(0); + }); + } + + public showCommands(): Promise { + return this.spectron.command('workbench.action.showCommands'); + } + + public openQuickOpen(): Promise { + return this.spectron.command('workbench.action.quickOpen'); + } + + public closeQuickOpen(): Promise { + return this.spectron.command('workbench.action.closeQuickOpen'); + } + + public selectNextQuickOpenElement(): Promise { + return this.spectron.client.keys(['ArrowDown', 'NULL']); + } + + public async getQuickOpenElements(): Promise { + const elements = await this.spectron.waitFor(this.spectron.client.elements, 'div[aria-label="Quick Picker"] .monaco-tree-rows.show-twisties .monaco-tree-row'); + return elements.value.length; + } + + public async openFile(fileName: string, explorer?: boolean): Promise { + let selector = `div[class="monaco-icon-label file-icon ${fileName}-name-file-icon ${this.getExtensionSelector(fileName)}`; + if (explorer) { + selector += ' explorer-item'; + } + selector += '"]'; + + await this.spectron.waitFor(this.spectron.client.doubleClick, selector); + return this.spectron.wait(); + } + + public getExtensionSelector(fileName: string): string { + const extension = fileName.split('.')[1]; + if (extension === 'js') { + return 'js-ext-file-icon javascript-lang-file-icon'; + } else if (extension === 'json') { + return 'json-ext-file-icon json-lang-file-icon'; + } else if (extension === 'md') { + return 'md-ext-file-icon markdown-lang-file-icon'; + } + + throw new Error('No class defined for this file extension'); + } + + public async getEditorFirstLinePlainText(): Promise { + try { + const span = await this.spectron.client.getText('.view-lines span span'); + if (Array.isArray(span)) { + return span[0]; + } + + return span; + } catch (e) { + return undefined; + } + } + + public removeFile(filePath: string): void { + this.util.removeFile(filePath); + } + + public removeDirectory(directory: string): Promise { + try { + return this.util.rimraf(directory); + } catch (e) { + throw new Error(`Failed to remove ${directory} with an error: ${e}`); + } + } +} \ No newline at end of file diff --git a/smoketest/src/areas/configuration-views.ts b/smoketest/src/areas/configuration-views.ts new file mode 100644 index 00000000000..1291469c849 --- /dev/null +++ b/smoketest/src/areas/configuration-views.ts @@ -0,0 +1,62 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; + +export enum ActivityBarPosition { + LEFT = 0, + RIGHT = 1 +}; + +export class ConfigurationView { + // Stores key binding defined for the toggle of activity bar position + private keybinding: string[]; + + constructor(private spectron: SpectronApplication) { + // noop + } + + public getEditorLineNumbers(): any { + return this.spectron.client.elements('.line-numbers'); + } + + public enterKeybindingsView(): any { + return this.spectron.command('workbench.action.openGlobalKeybindings'); + } + + public selectFirstKeybindingsMatch(): any { + return this.spectron.waitFor(this.spectron.client.click, 'div[aria-label="Keybindings"] .monaco-list-row.keybinding-item'); + } + + public changeKeybinding(): any { + return this.spectron.command('editor.action.defineKeybinding'); + } + + public enterBinding(keys: string[]): any { + this.keybinding = keys; + return this.spectron.client.keys(keys); + } + + public toggleActivityBarPosition(): any { + return this.spectron.client.keys(this.keybinding); + } + + public async getActivityBar(position: ActivityBarPosition) { + let positionClass: string; + + if (position === ActivityBarPosition.LEFT) { + positionClass = 'left'; + } else if (position === ActivityBarPosition.RIGHT) { + positionClass = 'right'; + } else { + throw new Error('No such position for activity bar defined.'); + } + try { + return await this.spectron.waitFor(this.spectron.client.getHTML, `.part.activitybar.${positionClass}`); + } catch (e) { + return undefined; + }; + } +} \ No newline at end of file diff --git a/smoketest/src/areas/css.ts b/smoketest/src/areas/css.ts new file mode 100644 index 00000000000..3388ab4e465 --- /dev/null +++ b/smoketest/src/areas/css.ts @@ -0,0 +1,62 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; + +export enum CSSProblem { + WARNING = 0, + ERROR = 1 +}; + +export class CSS { + + constructor(private spectron: SpectronApplication) { + // noop + } + + public openQuickOutline(): any { + return this.spectron.command('workbench.action.gotoSymbol'); + } + + public toggleProblemsView(): any { + return this.spectron.command('workbench.actions.view.problems'); + } + + public async getEditorProblem(problemType: CSSProblem): Promise { + let selector; + if (problemType === CSSProblem.WARNING) { + selector = 'greensquiggly'; + } else if (problemType === CSSProblem.ERROR) { + selector = 'redsquiggly'; + } else { + throw new Error('No such problem type defined.'); + } + + let el = await this.spectron.client.element(`.view-overlays .cdr.${selector}`); + if (el.status === 0) { + return el; + } + + return undefined; + } + + public async getProblemsViewsProblem(problemType: CSSProblem): Promise { + let selector; + if (problemType === CSSProblem.WARNING) { + selector = 'warning'; + } else if (problemType === CSSProblem.ERROR) { + selector = 'error'; + } else { + throw new Error('No such problem type defined.'); + } + + let el = await this.spectron.client.element(`div[aria-label="Problems grouped by files"] .icon.${selector}`); + if (el.status === 0) { + return el; + } + + return undefined; + } +} \ No newline at end of file diff --git a/smoketest/src/areas/data-loss.ts b/smoketest/src/areas/data-loss.ts new file mode 100644 index 00000000000..dc1ecf93730 --- /dev/null +++ b/smoketest/src/areas/data-loss.ts @@ -0,0 +1,26 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from "../spectron/application"; + +export class DataLoss { + + constructor(private spectron: SpectronApplication) { + } + + public openExplorerViewlet(): Promise { + return this.spectron.command('workbench.view.explorer'); + } + + public async verifyTabIsDirty(tabName: string, active?: boolean): Promise { + let activeSelector = active ? '.active' : ''; + let el = await this.spectron.client.element(`.tabs-container .tab.dirty${activeSelector}[aria-label="${tabName}, tab"]`); + if (el.status === 0) { + return el; + } + + return undefined; + } +} \ No newline at end of file diff --git a/smoketest/src/areas/extensions.ts b/smoketest/src/areas/extensions.ts new file mode 100644 index 00000000000..4edec9d06ef --- /dev/null +++ b/smoketest/src/areas/extensions.ts @@ -0,0 +1,49 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; +import { CommonActions } from "./common"; + +export class Extensions { + + private readonly extensionsViewletSelector = 'div[id="workbench.view.extensions"]'; + + constructor(private spectron: SpectronApplication, private common: CommonActions) { + } + + public async openExtensionsViewlet(): Promise { + await this.spectron.command('workbench.view.extensions'); + return this.spectron.wait(); + } + + public async searchForExtension(name: string): Promise { + const searchBoxSelector = `${this.extensionsViewletSelector} .search-box`; + + await this.spectron.client.clearElement(searchBoxSelector); + await this.spectron.client.click(searchBoxSelector, false); + await this.spectron.client.keys(name); + return this.spectron.client.keys(['NULL', 'Enter', 'NULL']); + } + + public installFirstResult(): Promise { + return this.spectron.client.click(`${this.extensionsViewletSelector} .monaco-list-rows>:nth-child(1) .extension .extension-action.install`); + } + + public getFirstReloadText(): Promise { + return this.spectron.waitFor(this.spectron.client.getText, `${this.extensionsViewletSelector} .monaco-list-rows>:nth-child(1) .extension .extension-action.reload`); + } + + public async selectMinimalIconsTheme(): Promise { + await this.common.showCommands(); + await this.common.type('File Icon Theme'); + await this.spectron.wait(); + await this.common.enter(); + return this.spectron.client.keys(['ArrowDown', 'NULL', 'Enter', 'NULL']); + } + + public async verifyFolderIconAppearance(): Promise { + return this.spectron.waitFor(this.spectron.client.getHTML, 'style[class="contributedIconTheme"]'); + } +} \ No newline at end of file diff --git a/smoketest/src/areas/first-experience.ts b/smoketest/src/areas/first-experience.ts new file mode 100644 index 00000000000..e9141bda899 --- /dev/null +++ b/smoketest/src/areas/first-experience.ts @@ -0,0 +1,21 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from "../spectron/application"; + +export class FirstExperience { + constructor(private spectron: SpectronApplication) { + // noop + } + + public async getWelcomeTab(): Promise { + let el = await this.spectron.client.element('.vs_code_welcome_page-name-file-icon'); + if (el.status === 0) { + return el; + } + + return undefined; + } +} \ No newline at end of file diff --git a/smoketest/src/areas/git.ts b/smoketest/src/areas/git.ts new file mode 100644 index 00000000000..8228771a7d7 --- /dev/null +++ b/smoketest/src/areas/git.ts @@ -0,0 +1,69 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; +import { CommonActions } from "./common"; + +export class Git { + private readonly bodyVarSelector = '.view-lines>:nth-child(6) .mtk11'; + + constructor(private spectron: SpectronApplication, private commonActions: CommonActions) { + // noop + } + + public openGitViewlet(): Promise { + return this.spectron.command('workbench.view.git'); + } + + public getScmIconChanges(): Promise { + return this.spectron.waitFor(this.spectron.client.getText, 'div[id="workbench.parts.activitybar"] .badge.scm-viewlet-label .badge-content'); + } + + public async verifyScmChange(fileName: string): Promise { + let el = await this.spectron.client.element(`div[class="monaco-icon-label file-icon ${fileName}-name-file-icon ${this.commonActions.getExtensionSelector(fileName)}"]`); + if (el.status === 0) { + return el; + } + + return undefined; + } + + public getOriginalAppJsBodyVarName(): Promise { + return this.spectron.waitFor(this.spectron.client.getText, `.editor.original ${this.bodyVarSelector}`); + } + + public getModifiedAppJsBodyVarName(): Promise { + return this.spectron.waitFor(this.spectron.client.getText, `.editor.modified ${this.bodyVarSelector}`); + } + + public async stageFile(fileName: string): Promise { + await this.spectron.client.moveToObject(`div[class="monaco-icon-label file-icon ${fileName}-name-file-icon ${this.commonActions.getExtensionSelector(fileName)}"`); + await this.spectron.client.click('.action-label.icon.contrib-cmd-icon-4'); + return this.spectron.wait(); + } + + public async unstageFile(fileName: string): Promise { + await this.spectron.client.moveToObject(`div[class="monaco-icon-label file-icon ${fileName}-name-file-icon ${this.commonActions.getExtensionSelector(fileName)}"`); + await this.spectron.client.click('.action-label.icon.contrib-cmd-icon-6'); + return this.spectron.wait(); + } + + public getStagedCount(): Promise { + return this.spectron.waitFor(this.spectron.client.getText, '.scm-status.show-file-icons .monaco-list-rows>:nth-child(1) .monaco-count-badge'); + } + + public focusOnCommitBox(): Promise { + return this.spectron.client.click('div[id="workbench.view.scm"] textarea'); + } + + public async pressCommit(): Promise { + await this.spectron.client.click('.action-label.icon.contrib-cmd-icon-10'); + return this.spectron.wait(); + } + + public getOutgoingChanges(): Promise { + return this.spectron.client.getText('a[title="Synchronize changes"]'); + } +} \ No newline at end of file diff --git a/smoketest/src/areas/integrated-terminal.ts b/smoketest/src/areas/integrated-terminal.ts new file mode 100644 index 00000000000..b066db8adf7 --- /dev/null +++ b/smoketest/src/areas/integrated-terminal.ts @@ -0,0 +1,38 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; +import { CommonActions } from "./common"; + +export class IntegratedTerminal { + + constructor(private spectron: SpectronApplication) { + // noop + } + + public async openTerminal(commonActions: CommonActions): Promise { + // Backquote dispatching does not work in OS X + if (process.platform === 'darwin') { + await commonActions.showCommands(); + await commonActions.type('Toggle Integrated Terminal'); + return commonActions.enter(); + } + + return this.spectron.command('workbench.action.terminal.toggleTerminal'); + } + + public async getCommandOutput(command: string): Promise { + const selector = 'div[id="workbench.panel.terminal"] .xterm-rows'; + let readRow = process.platform === 'win32' ? 5 : 2; + let output: string = await this.spectron.client.getText(`${selector}>:nth-child(${readRow})`); + + // If ended up on the wrong line, it could be terminal's restored session (e.g. on OS X) + if (output.trim().endsWith(command)) { + output = await this.spectron.client.getText(`${selector}>:nth-child(${readRow+1})`); // try next line + } + + return output.trim(); // remove many   tags + } +} \ No newline at end of file diff --git a/smoketest/src/areas/javascript-debug.ts b/smoketest/src/areas/javascript-debug.ts new file mode 100644 index 00000000000..948594945d7 --- /dev/null +++ b/smoketest/src/areas/javascript-debug.ts @@ -0,0 +1,42 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; + +export class JavaScriptDebug { + private readonly sidebarSelector = '.margin-view-overlays'; + + constructor(private spectron: SpectronApplication) { + // noop + } + + public openDebugViewlet(): Promise { + return this.spectron.command('workbench.view.debug'); + } + + public async pressConfigureLaunchJson(): Promise { + await this.spectron.waitFor(this.spectron.client.click, 'ul[aria-label="Debug actions"] .action-label.icon.debug-action.configure'); + await this.spectron.wait(); + await this.spectron.client.keys(['ArrowDown', 'NULL', 'Enter']); + return this.spectron.wait(); + } + + public getProgramConfigValue(): Promise { + return this.spectron.client.getText('.view-lines>:nth-child(11) .mtk7'); + } + + public setBreakpointOnLine(lineNumber: number): Promise { + return this.spectron.client.leftClick(`${this.sidebarSelector}>:nth-child(${lineNumber})`, 5, 5); + } + + public async verifyBreakpointOnLine(lineNumber: number): Promise { + let el = await this.spectron.client.element(`${this.sidebarSelector}>:nth-child(${lineNumber}) .cgmr.debug-breakpoint-glyph`); + if (el.status === 0) { + return el; + } + + return undefined; + } +} \ No newline at end of file diff --git a/smoketest/src/areas/javascript.ts b/smoketest/src/areas/javascript.ts new file mode 100644 index 00000000000..a2f2644c86f --- /dev/null +++ b/smoketest/src/areas/javascript.ts @@ -0,0 +1,73 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; + +export class JavaScript { + private readonly appVarSelector = '.view-lines>:nth-child(7) .mtk11'; + private readonly firstCommentSelector = '.margin-view-overlays>:nth-child(3)'; + private readonly expressVarSelector = '.view-lines>:nth-child(11) .mtk10'; + + constructor(private spectron: SpectronApplication) { + // noop + } + + public openQuickOutline(): Promise { + return this.spectron.command('workbench.action.gotoSymbol'); + } + + public async findAppReferences(): Promise { + await this.spectron.client.click(this.appVarSelector, false); + return this.spectron.command('editor.action.referenceSearch.trigger'); + } + + public async getTitleReferencesCount(): Promise { + const meta = await this.spectron.client.getText('.reference-zone-widget.results-loaded .peekview-title .meta'); + + return meta.match(/\d+/)[0]; + } + + public async getTreeReferencesCount(): Promise { + const treeElems = await this.spectron.client.elements('.reference-zone-widget.results-loaded .ref-tree.inline .show-twisties .monaco-tree-row'); + return treeElems.value.length; + } + + public async renameApp(newValue: string): Promise { + await this.spectron.client.click(this.appVarSelector); + await this.spectron.command('editor.action.rename'); + await this.spectron.wait(); + return this.spectron.client.keys(newValue, false); + } + + public async getNewAppName(): Promise { + return this.spectron.client.getText(this.appVarSelector); + } + + public async toggleFirstCommentFold(): Promise { + return this.spectron.client.click(`${this.firstCommentSelector} .cldr.folding`); + } + + public async getFirstCommentFoldedIcon(): Promise { + return this.spectron.client.getHTML(`${this.firstCommentSelector} .cldr.folding.collapsed`); + } + + public async getNextLineNumberAfterFold(): Promise { + return this.spectron.client.getText(`.margin-view-overlays>:nth-child(4) .line-numbers`) + } + + public async goToExpressDefinition(): Promise { + await this.spectron.client.click(this.expressVarSelector); + return this.spectron.command('editor.action.goToDeclaration'); + } + + public async peekExpressDefinition(): Promise { + await this.spectron.client.click(this.expressVarSelector); + return this.spectron.command('editor.action.previewDeclaration'); + } + + public async getPeekExpressResultName(): Promise { + return this.spectron.client.getText('.reference-zone-widget.results-loaded .filename'); + } +} \ No newline at end of file diff --git a/smoketest/src/areas/localization.ts b/smoketest/src/areas/localization.ts new file mode 100644 index 00000000000..4ad30cdeb88 --- /dev/null +++ b/smoketest/src/areas/localization.ts @@ -0,0 +1,55 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; + +export enum ViewletType { + SEARCH = 0, + SCM = 1, + DEBUG = 2, + EXTENSIONS = 3 +} + +export class Localization { + + constructor(private spectron: SpectronApplication) { + // noop + } + + public async getOpenEditorsText(): Promise { + const explorerTitles = await this.spectron.client.getText('div[id="workbench.view.explorer"] .title span'); + return explorerTitles[0]; + } + + public openViewlet(type: ViewletType): Promise { + let command; + + switch (type) { + case ViewletType.SEARCH: + command = 'workbench.view.search'; + break; + case ViewletType.SCM: + command = 'workbench.view.scm'; + break; + case ViewletType.DEBUG: + command = 'workbench.view.debug'; + break; + case ViewletType.EXTENSIONS: + command = 'workbench.view.extensions'; + break; + } + + return this.spectron.command(command, false); + } + + public getOpenedViewletTitle(): Promise { + return this.spectron.client.getText('div[id="workbench.parts.sidebar"] .title-label span'); + } + + public getExtensionsSearchPlaceholder(): Promise { + return this.spectron.client.getAttribute('div[id="workbench.view.extensions"] .search-box', 'placeholder'); + } + +} \ No newline at end of file diff --git a/smoketest/src/areas/search.ts b/smoketest/src/areas/search.ts new file mode 100644 index 00000000000..5477a5f25d9 --- /dev/null +++ b/smoketest/src/areas/search.ts @@ -0,0 +1,50 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; + +export class Search { + + constructor(private spectron: SpectronApplication) { + // noop + } + + public openSearchViewlet(): Promise { + return this.spectron.command('workbench.view.search'); + } + + public async searchFor(text: string): Promise { + await this.spectron.client.keys(text); + return this.spectron.client.keys(['NULL', 'Enter', 'NULL'], false); + } + + public setReplaceText(text: string): any { + return this.spectron.client.setValue('.viewlet .input[title="Replace"]', text); + } + + public replaceFirstMatch(): any { + return this.spectron.client.click('.monaco-tree-rows.show-twisties .action-label.icon.action-replace-all'); + } + + public getResultText(): any { + return this.spectron.waitFor(this.spectron.client.getText, '.search-viewlet .message>p'); + } + + public toggleSearchDetails(): any { + return this.spectron.client.click('.query-details .more'); + } + + public toggleReplace(): any { + return this.spectron.client.click('.monaco-button.toggle-replace-button.collapse'); + } + + public hoverOverResultCount(): any { + return this.spectron.waitFor(this.spectron.client.moveToObject, '.monaco-count-badge'); + } + + public dismissResult(): any { + return this.spectron.client.click('.action-label.icon.action-remove') + } +} \ No newline at end of file diff --git a/smoketest/src/areas/statusbar.ts b/smoketest/src/areas/statusbar.ts new file mode 100644 index 00000000000..93b73495183 --- /dev/null +++ b/smoketest/src/areas/statusbar.ts @@ -0,0 +1,99 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; + +export enum StatusBarElement { + BRANCH_STATUS = 0, + SYNC_STATUS = 1, + PROBLEMS_STATUS = 2, + SELECTION_STATUS = 3, + INDENTATION_STATUS = 4, + ENCODING_STATUS = 5, + EOL_STATUS = 6, + LANGUAGE_STATUS = 7, + FEEDBACK_ICON = 8 +} + +export class StatusBar { + + private selectorsMap: Map; + private readonly mainSelector = 'div[id="workbench.parts.statusbar"]'; + + constructor(private spectron: SpectronApplication) { + this.populateSelectorsMap(); + } + + public async isVisible(element: StatusBarElement): Promise { + const selector = this.selectorsMap.get(element); + if (!selector) { + throw new Error('No such element in the status bar defined.'); + } + + return this.spectron.client.isVisible(selector); + } + + public async clickOn(element: StatusBarElement): Promise { + const selector = this.selectorsMap.get(element); + if (!selector) { + throw new Error('No such element in the status bar defined.'); + } + + return this.spectron.client.click(selector); + } + + public async getProblemsView(): Promise { + let el = await this.spectron.client.element('div[id="workbench.panel.markers"]'); + if (el.status === 0) { + return el; + } + + return undefined; + } + + public async getFeedbackView(): Promise { + let el = await this.spectron.client.element('.feedback-form'); + if (el.status === 0) { + return el; + } + + return undefined; + } + + public isQuickOpenWidgetVisible(): Promise { + return this.spectron.client.isVisible('.quick-open-widget'); + } + + public async getEditorHighlightedLine(lineNumber: number): Promise { + let el = await this.spectron.client.element(`.monaco-editor .view-overlays>:nth-child(${lineNumber}) .current-line`); + if (el.status === 0) { + return el; + } + + return undefined; + } + + public async getEOLMode(): Promise { + const selector = this.selectorsMap.get(StatusBarElement.EOL_STATUS); + if (!selector) { + throw new Error('No such element in the status bar defined.'); + } + + return this.spectron.client.getText(selector); + } + + private populateSelectorsMap(): void { + this.selectorsMap = new Map(); + this.selectorsMap.set(StatusBarElement.BRANCH_STATUS, `${this.mainSelector} .octicon.octicon-git-branch`); + this.selectorsMap.set(StatusBarElement.SYNC_STATUS, `${this.mainSelector} .octicon.octicon-sync`); + this.selectorsMap.set(StatusBarElement.PROBLEMS_STATUS, `${this.mainSelector} .task-statusbar-item[title="Problems"]`); + this.selectorsMap.set(StatusBarElement.SELECTION_STATUS, `${this.mainSelector} .editor-status-selection`); + this.selectorsMap.set(StatusBarElement.INDENTATION_STATUS, `${this.mainSelector} .editor-status-indentation`); + this.selectorsMap.set(StatusBarElement.ENCODING_STATUS, `${this.mainSelector} .editor-status-encoding`); + this.selectorsMap.set(StatusBarElement.EOL_STATUS, `${this.mainSelector} .editor-status-eol`); + this.selectorsMap.set(StatusBarElement.LANGUAGE_STATUS, `${this.mainSelector} .editor-status-mode`); + this.selectorsMap.set(StatusBarElement.FEEDBACK_ICON, `${this.mainSelector} .dropdown.send-feedback`); + } +} \ No newline at end of file diff --git a/smoketest/src/areas/tasks.ts b/smoketest/src/areas/tasks.ts new file mode 100644 index 00000000000..e46c2961df5 --- /dev/null +++ b/smoketest/src/areas/tasks.ts @@ -0,0 +1,50 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; + +export class Tasks { + + private readonly outputViewSelector = 'div[id="workbench.panel.output"] .view-lines'; + private readonly workbenchPanelSelector = 'div[id="workbench.parts.panel"]'; + private readonly problemsViewSelector = 'div[id="workbench.panel.markers"] .monaco-tree-row.expanded'; + + constructor(private spectron: SpectronApplication) { + // noop + } + + public build(): Promise { + return this.spectron.command('workbench.action.tasks.build'); + } + + public openProblemsView(): Promise { + return this.spectron.command('workbench.actions.view.problems'); + } + + public async firstOutputLineEndsWith(fileName: string): Promise { + const firstLine = await this.spectron.waitFor(this.spectron.client.getText, `${this.outputViewSelector}>:nth-child(2)`); + return firstLine.endsWith(fileName); + } + + public getOutputResult(): Promise { + return this.spectron.waitFor(this.spectron.client.getText, `${this.outputViewSelector}>:nth-child(10) span.mtk1`); + } + + public selectOutputViewType(type: string): Promise { + return this.spectron.client.selectByValue(`${this.workbenchPanelSelector} .select-box`, type); + } + + public getOutputViewType(): Promise { + return this.spectron.client.getValue(`${this.workbenchPanelSelector} .select-box`); + } + + public getProblemsViewFirstElementName(): Promise { + return this.spectron.waitFor(this.spectron.client.getText, `${this.problemsViewSelector} .label-name`); + } + + public getProblemsViewFirstElementCount(): Promise { + return this.spectron.waitFor(this.spectron.client.getText, `${this.problemsViewSelector} .monaco-count-badge`); + } +} \ No newline at end of file diff --git a/smoketest/src/helpers/screenshot.ts b/smoketest/src/helpers/screenshot.ts new file mode 100644 index 00000000000..649c38493e4 --- /dev/null +++ b/smoketest/src/helpers/screenshot.ts @@ -0,0 +1,48 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from "../spectron/application"; +var fs = require('fs'); + +const __testTime = new Date().toISOString(); + +export class Screenshot { + private index: number = 0; + private testPath: string; + + constructor(private spectron: SpectronApplication, testName: string) { + const testTime = this.sanitizeFolderName(__testTime); + testName = this.sanitizeFolderName(testName); + + this.testPath = `test_data/screenshots/${testTime}/${testName}`; + this.createFolder(this.testPath); + } + + public capture(): Promise { + return new Promise(async (res, rej) => { + const image: Electron.NativeImage = await this.spectron.app.browserWindow.capturePage(); + fs.writeFile(`${this.testPath}/${this.index}.png`, image, (err) => { + if (err) { + rej(err); + } + }); + this.index++; + res(); + }); + } + + private createFolder(name: string) { + name.split('/').forEach((folderName, i, fullPath) => { + const folder = fullPath.slice(0, i + 1).join('/'); + if (!fs.existsSync(folder)) { + fs.mkdirSync(folder); + } + }); + } + + private sanitizeFolderName(name: string): string { + return name.replace(/[&*:\/]/g, ''); + } +} \ No newline at end of file diff --git a/smoketest/src/helpers/utilities.ts b/smoketest/src/helpers/utilities.ts new file mode 100644 index 00000000000..2a52a4fe7df --- /dev/null +++ b/smoketest/src/helpers/utilities.ts @@ -0,0 +1,37 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +var fs = require('fs'); +var rimraf = require('rimraf'); + +/** + * Contains methods that are commonly used across test areas. + */ +export class Util { + constructor() { + // noop + } + + public removeFile(filePath: string): void { + try { + fs.unlinkSync(`${filePath}`); + } catch (e) { + if (e.code !== 'ENOENT') { + throw e; + } + } + } + + public rimraf(directory: string): Promise { + return new Promise((res, rej) => { + rimraf(directory, (err) => { + if (err) { + rej(err); + } + res(); + }); + }); + } +} \ No newline at end of file diff --git a/smoketest/src/main.ts b/smoketest/src/main.ts new file mode 100644 index 00000000000..9da55ce546a --- /dev/null +++ b/smoketest/src/main.ts @@ -0,0 +1,771 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; +import { SpectronApplication } from "./spectron/application"; +import { CommonActions } from './areas/common'; +import { FirstExperience } from './areas/first-experience'; +import { ConfigurationView, ActivityBarPosition } from './areas/configuration-views'; +import { Search } from './areas/search'; +import { CSS, CSSProblem } from './areas/css'; +import { JavaScript } from './areas/javascript'; +import { JavaScriptDebug } from './areas/javascript-debug'; +import { Git } from './areas/git'; +import { IntegratedTerminal } from './areas/integrated-terminal'; +import { StatusBar, StatusBarElement } from './areas/statusBar'; +import { DataLoss } from './areas/data-loss'; +import { Tasks } from './areas/tasks'; +import { Extensions } from './areas/extensions'; +import { Localization, ViewletType } from "./areas/localization"; + +describe('Smoke Test Suite', function () { + const latestPath = process.env.VSCODE_LATEST_PATH; + const stablePath = process.env.VSCODE_STABLE_PATH; + const insiders = process.env.VSCODE_EDITION; + const workspacePath = process.env.SMOKETEST_REPO; + const tempUserDir = 'test_data/temp_user_dir'; + const tempExtensionsDir = 'test_data/temp_extensions_dir'; + + let app: SpectronApplication; + let common: CommonActions; + this.retries(2); + + if (stablePath) { + context('Data Migration', function () { + + afterEach(async function () { + await app.stop(); + return await common.removeDirectory(tempUserDir) + }); + + function setupSpectron(context: Mocha.ITestCallbackContext, appPath: string, workspace?: string[]): void { + app = new SpectronApplication(appPath, context.test.fullTitle(), context.test.currentRetry(), workspace, [`--user-data-dir=${tempUserDir}`]); + common = new CommonActions(app); + } + + it('checks if the Untitled file is restored migrating from stable to latest', async function () { + const textToType = 'Very dirty file'; + + // Setting up stable version + setupSpectron(this, stablePath); + await app.start(); + + await common.newUntitledFile(); + await common.type(textToType); + await app.stop(); + + await app.wait(); // wait until all resources are released (e.g. locked local storage) + + // Checking latest version for the restored state + setupSpectron(this, latestPath); + await app.start(); + + assert.ok(await common.getTab('Untitled-1')); + await common.selectTab('Untitled-1'); + const editorText = await common.getEditorFirstLinePlainText(); + assert.equal(editorText, textToType); + }); + + it('checks if the newly created dirty file is restored migrating from stable to latest', async function () { + const fileName = 'test_data/plainFile', + firstTextPart = 'This is going to be an unsaved file', secondTextPart = '_that is dirty.'; + + // Setting up stable version + setupSpectron(this, stablePath, [fileName]); + await common.removeFile(`${fileName}`); + await app.start(); + + await common.type(firstTextPart); + await common.saveOpenedFile(); + await app.wait(); + await common.type(secondTextPart); + + await app.stop(); + await app.wait(); // wait until all resources are released (e.g. locked local storage) + + // Checking latest version for the restored state + setupSpectron(this, latestPath); + await app.start(); + assert.ok(await common.getTab(fileName.split('/')[1])); + await common.selectTab(fileName.split('/')[1]); + const editorText = await common.getEditorFirstLinePlainText(); + assert.equal(editorText, firstTextPart.concat(secondTextPart)); + + // Cleanup + await common.removeFile(`${fileName}`); + }); + + it('cheks if opened tabs are restored migrating from stable to latest', async function () { + const fileName1 = 'app.js', fileName2 = 'jsconfig.json', fileName3 = 'readme.md'; + setupSpectron(this, stablePath, [workspacePath]); + await app.start(); + await common.openFile(fileName1, true); + await common.openFile(fileName2, true); + await common.openFile(fileName3, true); + await app.stop(); + + setupSpectron(this, latestPath, [workspacePath]); + await app.start(); + assert.ok(await common.getTab(fileName1)); + assert.ok(await common.getTab(fileName2)); + assert.ok(await common.getTab(fileName3)); + }); + }); + } + + context('Data Loss', function () { + let dataLoss: DataLoss; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath], [`--user-data-dir=${tempUserDir}`]); + common = new CommonActions(app); + dataLoss = new DataLoss(app); + await common.removeDirectory(tempUserDir); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it(`verifies that 'hot exit' works for dirty files`, async function () { + const textToType = 'Hello, Code!', fileName = 'readme.md', untitled = 'Untitled-1'; + await common.newUntitledFile(); + await common.type(textToType); + await dataLoss.openExplorerViewlet(); + await common.openFile(fileName, true); + await common.type(textToType); + + await app.stop(); + await app.start(); + + // check tab presence + assert.ok(await common.getTab(untitled)); + assert.ok(await common.getTab(fileName, true)); + // check if they marked as dirty (icon) and active tab is the last opened + assert.ok(await dataLoss.verifyTabIsDirty(untitled)); + assert.ok(await dataLoss.verifyTabIsDirty(fileName, true)); + }); + + it(`verifies that contents of the dirty files are restored after 'hot exit'`, async function () { + // make one dirty file, + // create one untitled file + const textToType = 'Hello, Code!'; + + // create one untitled file + await common.newUntitledFile(); + await app.wait(); + await common.type(textToType); + + // make one dirty file, + await common.openFile('readme.md', true); + await app.wait(); + await common.type(textToType); + + await app.stop(); + await app.start(); + + // check their contents + let fileDirt = await common.getEditorFirstLinePlainText(); + assert.equal(fileDirt, 'Hello, Code'); // ignore '!' as it is a separate , first part is enough + await common.selectTab('Untitled-1'); + fileDirt = await common.getEditorFirstLinePlainText(); + assert.equal(fileDirt, textToType); + }); + }); + + context('First User Experience', function () { + let experience: FirstExperience; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), undefined, [`--user-data-dir=${tempUserDir}`, `--excludeSwitches=load-component-extension`]); + common = new CommonActions(app); + experience = new FirstExperience(app); + + await common.removeDirectory(tempUserDir); + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it(`verifies if title is set correctly on the clean user-directory startup`, async function () { + const title = await common.getWindowTitle(); + + let expectedTitle = 'Welcome'; + if (process.platform !== 'darwin') { + expectedTitle += ' — Visual Studio Code'; + if (insiders) expectedTitle += ' - Insiders'; + } + + assert.equal(title, expectedTitle); + }); + + it(`verifies if 'Welcome page' tab is presented on the clean user-directory startup`, async function () { + assert.ok(await experience.getWelcomeTab()); + }); + }); + + context('Explorer', function () { + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); + common = new CommonActions(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('quick open search produces correct result', async function () { + await common.openQuickOpen(); + await common.type('.js'); + await app.wait(); + const elCount = await common.getQuickOpenElements(); + assert.equal(elCount, 7); + }); + + it('quick open respects fuzzy matching', async function () { + await common.openQuickOpen(); + await common.type('a.s'); + await app.wait(); + const elCount = await common.getQuickOpenElements(); + assert.equal(elCount, 3); + }); + }); + + context('Configuration and views', function () { + let configView: ConfigurationView; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); + common = new CommonActions(app); + configView = new ConfigurationView(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('turns off editor line numbers and verifies the live change', async function () { + await common.newUntitledFile(); + await app.wait(); + let elements = await configView.getEditorLineNumbers(); + assert.equal(elements.value.length, 1); + await common.addSetting('editor.lineNumbers', 'off'); + await app.wait(); + elements = await configView.getEditorLineNumbers(); + assert.equal(elements.value.length, 0); + }); + + it(`changes 'workbench.action.toggleSidebarPosition' command key binding and verifies it`, async function () { + await configView.enterKeybindingsView() + await common.type('workbench.action.toggleSidebarPosition'); + await app.wait(); + await configView.selectFirstKeybindingsMatch(); + await configView.changeKeybinding(); + await configView.enterBinding(['Control', 'u', 'NULL']); + await common.enter(); + let html = await configView.getActivityBar(ActivityBarPosition.RIGHT); + assert.equal(html, undefined);; + await app.wait(); + await configView.toggleActivityBarPosition(); + html = await configView.getActivityBar(ActivityBarPosition.RIGHT); + assert.ok(html); + }); + }); + + context('Search', function () { + let search: Search; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); + common = new CommonActions(app); + search = new Search(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('searches for body & checks for correct result number', async function () { + const s = search; + await s.openSearchViewlet(); + await s.searchFor('body'); + const result = await s.getResultText(); + assert.equal(result, '7 results in 4 files'); + }); + + it('searches only for *.js files & checks for correct result number', async function () { + const s = search; + await s.openSearchViewlet(); + await s.searchFor('body'); + await s.toggleSearchDetails(); + await s.searchFor('*.js'); + const results = await s.getResultText(); + assert.equal(results, '4 results in 1 file'); + }); + + it('dismisses result & checks for correct result number', async function () { + const s = search; + await s.openSearchViewlet() + await s.searchFor('body'); + await s.hoverOverResultCount(); + await s.dismissResult(); + await app.wait(); + const result = await s.getResultText(); + assert.equal(result, '3 results in 3 files') + }); + + it('replaces first search result with a replace term', async function () { + const s = search; + await s.openSearchViewlet() + await s.searchFor('body'); + await s.toggleReplace(); + await s.setReplaceText('ydob'); + await s.hoverOverResultCount(); + await s.replaceFirstMatch(); + await app.wait(); + await common.saveOpenedFile(); + const result = await s.getResultText(); + assert.equal(result, '3 results in 3 files'); + }); + }); + + context('CSS', function () { + let css: CSS; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); + common = new CommonActions(app); + css = new CSS(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('verifies quick outline', async function () { + await common.openFirstMatchFile('style.css'); + await css.openQuickOutline(); + await app.wait(); + const count = await common.getQuickOpenElements(); + assert.equal(count, 2); + }); + + it('verifies warnings for the empty rule', async function () { + await common.openFirstMatchFile('style.css'); + await common.type('.foo{}'); + await app.wait(); + let warning = await css.getEditorProblem(CSSProblem.WARNING); + assert.ok(warning); + await css.toggleProblemsView(); + warning = await css.getProblemsViewsProblem(CSSProblem.WARNING); + assert.ok(warning); + }); + + it('verifies that warning becomes an error once setting changed', async function () { + await common.addSetting('css.lint.emptyRules', 'error'); + await common.openFirstMatchFile('style.css'); + await common.type('.foo{}'); + await app.wait(); + let error = await css.getEditorProblem(CSSProblem.ERROR); + assert.ok(error); + await css.toggleProblemsView(); + error = await css.getProblemsViewsProblem(CSSProblem.ERROR); + assert.ok(error); + }); + }); + + context('JavaScript', function () { + let js: JavaScript; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); + common = new CommonActions(app); + js = new JavaScript(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('shows correct quick outline', async function () { + await common.openFirstMatchFile('bin/www'); + await js.openQuickOutline(); + await app.wait(); + const symbols = await common.getQuickOpenElements(); + assert.equal(symbols, 12); + }); + + it(`finds 'All References' to 'app'`, async function () { + await common.openFirstMatchFile('bin/www'); + await app.wait(); + await js.findAppReferences(); + const titleCount = await js.getTitleReferencesCount(); + assert.equal(titleCount, 3); + const treeCount = await js.getTreeReferencesCount(); + assert.equal(treeCount, 3); + }); + + it(`renames local 'app' variable`, async function () { + await common.openFirstMatchFile('bin/www'); + + const newVarName = 'newApp'; + await js.renameApp(newVarName); + await common.enter(); + const newName = await js.getNewAppName(); + assert.equal(newName, newVarName); + }); + + it('folds/unfolds the code correctly', async function () { + await common.openFirstMatchFile('bin/www'); + // Fold + await js.toggleFirstCommentFold(); + const foldedIcon = await js.getFirstCommentFoldedIcon(); + assert.ok(foldedIcon); + let nextLineNumber = await js.getNextLineNumberAfterFold(); + assert.equal(nextLineNumber, 7); + // Unfold + await js.toggleFirstCommentFold(); + nextLineNumber = await js.getNextLineNumberAfterFold(); + assert.equal(nextLineNumber, 4); + }); + + it(`verifies that 'Go To Definition' works`, async function () { + await common.openFirstMatchFile('app.js'); + await js.goToExpressDefinition(); + await app.wait(); + assert.ok(await common.getTab('index.d.ts')); + }); + + it(`verifies that 'Peek Definition' works`, async function () { + await common.openFirstMatchFile('app.js'); + await js.peekExpressDefinition(); + const definitionFilename = await js.getPeekExpressResultName(); + assert.equal(definitionFilename, 'index.d.ts'); + }); + }); + + context('Debugging JavaScript', function () { + let jsDebug: JavaScriptDebug; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); + common = new CommonActions(app); + jsDebug = new JavaScriptDebug(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('autodetects program attribute for launch.json', async function () { + await jsDebug.openDebugViewlet(); + await jsDebug.pressConfigureLaunchJson(); + const value = await jsDebug.getProgramConfigValue(); + process.platform === 'win32' ? assert.equal(value, '"${workspaceRoot}\\\\bin\\\\www"') : assert.equal(value, '"${workspaceRoot}/bin/www"'); + }); + + it(`can set a breakpoint and verify if it's set`, async function () { + await common.openFirstMatchFile('index.js'); + await jsDebug.setBreakpointOnLine(6); + const breakpoint = await jsDebug.verifyBreakpointOnLine(6); + assert.ok(breakpoint); + }); + }); + + context('Git', function () { + let git: Git; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); + common = new CommonActions(app); + git = new Git(app, common); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('verifies current changes are picked up by Git viewlet', async function () { + const changesCount = await git.getScmIconChanges(); + assert.equal(changesCount, 2); + await git.openGitViewlet(); + assert.ok(await git.verifyScmChange('app.js')); + assert.ok(await git.verifyScmChange('launch.json')); + }); + + it(`verifies 'app.js' diff viewer changes`, async function () { + await git.openGitViewlet(); + await common.openFile('app.js'); + const original = await git.getOriginalAppJsBodyVarName(); + assert.equal(original, 'bodyParser'); + const modified = await git.getModifiedAppJsBodyVarName(); + assert.equal(modified, 'ydobParser'); + }); + + it(`stages 'app.js' changes and checks stage count`, async function () { + await git.openGitViewlet(); + await app.wait(); + await git.stageFile('app.js'); + const stagedCount = await git.getStagedCount(); + assert.equal(stagedCount, 1); + + // Return back to unstaged state + await git.unstageFile('app.js'); + }); + + it(`stages, commits change to 'app.js' locally and verifies outgoing change`, async function () { + await git.openGitViewlet(); + await app.wait(); + await git.stageFile('app.js'); + await git.focusOnCommitBox(); + await common.type('Test commit'); + await git.pressCommit(); + const changes = await git.getOutgoingChanges(); + assert.equal(changes, ' 0↓ 1↑'); + }); + }); + + context('Integrated Terminal', function () { + let terminal: IntegratedTerminal; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); + common = new CommonActions(app); + terminal = new IntegratedTerminal(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it(`opens terminal, runs 'echo' and verifies the output`, async function () { + const command = 'echo test'; + await terminal.openTerminal(common); + await app.wait(); + await common.type(command); + await common.enter(); + await app.wait(); + // Default Powershell terminal adds 3 header rows at the top, whereas bash does not. + let output = await terminal.getCommandOutput(command); + assert.equal(output, 'test'); + }); + }); + + context('Status Bar', function () { + let statusBar: StatusBar; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); + common = new CommonActions(app); + statusBar = new StatusBar(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('verifies presence of all default status bar elements', async function () { + await app.wait(); + assert.ok(await statusBar.isVisible(StatusBarElement.BRANCH_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.FEEDBACK_ICON)); + assert.ok(await statusBar.isVisible(StatusBarElement.SYNC_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.PROBLEMS_STATUS)); + + await common.openFirstMatchFile('app.js'); + assert.ok(await statusBar.isVisible(StatusBarElement.ENCODING_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.EOL_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.INDENTATION_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.LANGUAGE_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.SELECTION_STATUS)); + }); + + it(`verifies that 'quick open' opens when clicking on 'Branch', 'Indentation Status, 'Encoding', 'EOL' and 'Language' status elements`, async function () { + await app.wait(); + await statusBar.clickOn(StatusBarElement.BRANCH_STATUS); + assert.ok(await statusBar.isQuickOpenWidgetVisible()); + await common.closeQuickOpen(); + + await common.openFirstMatchFile('app.js'); + await statusBar.clickOn(StatusBarElement.INDENTATION_STATUS); + assert.ok(await statusBar.isQuickOpenWidgetVisible()); + await common.closeQuickOpen(); + await statusBar.clickOn(StatusBarElement.ENCODING_STATUS); + assert.ok(await statusBar.isQuickOpenWidgetVisible()); + await common.closeQuickOpen(); + await statusBar.clickOn(StatusBarElement.EOL_STATUS); + assert.ok(await statusBar.isQuickOpenWidgetVisible()); + await common.closeQuickOpen(); + await statusBar.clickOn(StatusBarElement.LANGUAGE_STATUS); + assert.ok(await statusBar.isQuickOpenWidgetVisible()); + await common.closeQuickOpen(); + }); + + it(`verifies that 'Problems View' appears when clicking on 'Problems' status element`, async function () { + await statusBar.clickOn(StatusBarElement.PROBLEMS_STATUS); + assert.ok(await statusBar.getProblemsView()); + }); + + it(`verifies that 'Tweet us feedback' pop-up appears when clicking on 'Feedback' icon`, async function () { + await statusBar.clickOn(StatusBarElement.FEEDBACK_ICON); + assert.ok(await statusBar.getFeedbackView()); + }); + + it(`checks if 'Go to Line' works if called from the status bar`, async function () { + await common.openFirstMatchFile('app.js'); + await statusBar.clickOn(StatusBarElement.SELECTION_STATUS); + const lineNumber = 15; + await common.type(lineNumber.toString()); + await common.enter(); + assert.ok(await statusBar.getEditorHighlightedLine(lineNumber)); + }); + + it(`verifies if changing EOL is reflected in the status bar`, async function () { + await common.openFirstMatchFile('app.js'); + await statusBar.clickOn(StatusBarElement.EOL_STATUS); + await common.selectNextQuickOpenElement(); + await common.enter(); + const currentEOL = await statusBar.getEOLMode(); + assert.equal(currentEOL, 'CRLF'); + }); + }); + + context('Tasks', function () { + let tasks: Tasks; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); + tasks = new Tasks(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('verifies that build task produces 6 errors', async function () { + await tasks.build(); + const res = await tasks.getOutputResult(); + assert.equal(res, '✖ 6 problems (6 errors, 0 warnings)'); + }); + + it(`is able to select 'Git' output`, async function () { + await tasks.build(); + await app.wait(); + await tasks.selectOutputViewType('Git'); + const viewType = await tasks.getOutputViewType(); + assert.equal(viewType, 'Git'); + }); + + it('ensures that build task produces errors in index.js', async function () { + await tasks.build(); + assert.ok(await tasks.firstOutputLineEndsWith('index.js')); + }); + + it(`verifies build errors are reflected in 'Problems View'`, async function () { + await tasks.build(); + await app.wait(); + await tasks.openProblemsView(); + const problemName = await tasks.getProblemsViewFirstElementName(); + assert.equal(problemName, 'index.js'); + const problemsCount = await tasks.getProblemsViewFirstElementCount(); + assert.equal(problemsCount, '6'); + }); + }); + + context('Extensions', function () { + let extensions: Extensions; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath], [`--extensions-dir=${tempExtensionsDir}`]); + common = new CommonActions(app); + extensions = new Extensions(app, common); + await common.removeDirectory(tempExtensionsDir); + + return await app.start(); + }); + afterEach(async function () { + await app.stop(); + return await common.removeDirectory(tempExtensionsDir); + }); + + it(`installs 'vscode-icons' extension and verifies reload is prompted`, async function () { + await extensions.openExtensionsViewlet(); + await extensions.searchForExtension('vscode-icons'); + await app.wait(); + await extensions.installFirstResult(); + await app.wait(); + assert.ok(await extensions.getFirstReloadText()); + }); + + it(`installs an extension and checks if it works on restart`, async function () { + await extensions.openExtensionsViewlet(); + await extensions.searchForExtension('vscode-icons'); + await app.wait(); + await extensions.installFirstResult(); + await app.wait(); + await extensions.getFirstReloadText(); + + await app.stop(); + await app.wait(); // wait until all resources are released (e.g. locked local storage) + await app.start(); + await extensions.selectMinimalIconsTheme(); + const x = await extensions.verifyFolderIconAppearance(); + assert.ok(x); + }); + }); + + context('Localization', function () { + afterEach(async function () { + return await app.stop(); + }); + + it(`starts with 'DE' locale and verifies title and viewlets text is in German`, async function () { + app = new SpectronApplication(latestPath, this.test.fullTitle(), this.test.currentRetry(), [workspacePath, '--locale=DE'], [`--user-data-dir=${tempUserDir}`]); + common = new CommonActions(app); + const locale = new Localization(app); + common.removeDirectory(tempUserDir); + + await app.start(); + + let expectedTitle = 'Willkommen — vscode-smoketest-express'; + if (process.platform !== 'darwin') { + expectedTitle += ' — Visual Studio Code'; + if (insiders) expectedTitle += ' - Insiders'; + } + assert.equal(await common.getWindowTitle(), expectedTitle); + + let text = await locale.getOpenEditorsText(); + assert.equal(text.toLowerCase(), 'geöffnete editoren'); + + await locale.openViewlet(ViewletType.SEARCH); + text = await locale.getOpenedViewletTitle() + assert.equal(text.toLowerCase(), 'suchen'); + + await locale.openViewlet(ViewletType.SCM); + text = await locale.getOpenedViewletTitle(); + assert.equal(text.toLowerCase(), 'quellcodeverwaltung: git'); + + await locale.openViewlet(ViewletType.DEBUG); + text = await locale.getOpenedViewletTitle(); + assert.equal(text.toLowerCase(), 'debuggen'); + + await locale.openViewlet(ViewletType.EXTENSIONS); + text = await locale.getExtensionsSearchPlaceholder(); + assert.equal(text.toLowerCase(), 'nach extensions in marketplace suchen'); + }); + }); + +}); \ No newline at end of file diff --git a/smoketest/src/spectron/application.ts b/smoketest/src/spectron/application.ts new file mode 100644 index 00000000000..5e45474768c --- /dev/null +++ b/smoketest/src/spectron/application.ts @@ -0,0 +1,156 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { Application } from 'spectron'; +import { SpectronClient } from './client'; +import { Screenshot } from "../helpers/screenshot"; +var fs = require('fs'); + +/** + * Wraps Spectron's Application instance with its used methods. + */ +export class SpectronApplication { + public client: SpectronClient; + + private spectron: Application; + private readonly pollTrials = 5; + private readonly pollTimeout = 3; // in secs + private keybindings: any[]; + private screenshot: Screenshot; + + constructor(electronPath: string, testName: string, private testRetry: number, args?: string[], chromeDriverArgs?: string[]) { + if (!args) { + args = []; + } + + this.spectron = new Application({ + path: electronPath, + args: args.concat(['--skip-getting-started']), // prevent 'Getting Started' web page from opening on clean user-data-dir + chromeDriverArgs: chromeDriverArgs + }); + this.screenshot = new Screenshot(this, testName); + this.client = new SpectronClient(this.spectron, this.screenshot); + this.testRetry += 1; // avoid multiplication by 0 for wait times + this.retrieveKeybindings(); + } + + public get app(): Application { + return this.spectron; + } + + public async start(): Promise { + try { + await this.spectron.start(); + await this.focusOnWindow(1); // focuses on main renderer window + return this.checkWindowReady(); + } catch (err) { + throw err; + } + } + + public async stop(): Promise { + if (this.spectron && this.spectron.isRunning()) { + return await this.spectron.stop(); + } + } + + public waitFor(func: (...args: any[]) => any, args: any): Promise { + return this.callClientAPI(func, args, 0); + } + + public wait(): Promise { + return new Promise(resolve => setTimeout(resolve, this.testRetry * this.pollTimeout * 1000)); + } + + public focusOnWindow(index: number): Promise { + return this.client.windowByIndex(index); + } + + private checkWindowReady(): Promise { + return this.waitFor(this.spectron.client.getHTML, '[id="workbench.main.container"]'); + } + + private retrieveKeybindings() { + const os = process.platform; + fs.readFile(`test_data/keybindings.${os}.json`, (err, data) => { + if (err) { + throw err; + } + + this.keybindings = JSON.parse(data); + }); + } + + private callClientAPI(func: (...args: any[]) => Promise, args: any, trial: number): Promise { + if (trial > this.pollTrials) { + return Promise.reject(`Could not retrieve the element in ${this.testRetry * this.pollTrials * this.pollTimeout} seconds.`); + } + + return new Promise(async (res, rej) => { + let resolved = false, capture = false; + + const tryCall = async (resolve: any, reject: any): Promise => { + await this.wait(); + try { + const result = await this.callClientAPI(func, args, ++trial); + res(result); + } catch (error) { + rej(error); + } + } + + try { + const result = await func.call(this.client, args, capture); + if (!resolved && result === '') { + resolved = true; + await tryCall(res, rej); + } else if (!resolved) { + resolved = true; + await this.screenshot.capture(); + res(result); + } + } catch (e) { + if (!resolved) { + resolved = true; + await tryCall(res, rej); + } + } + }); + } + + /** + * Retrieves the command from keybindings file and executes it with WebdriverIO client API + * @param command command (e.g. 'workbench.action.files.newUntitledFile') + */ + public command(command: string, capture?: boolean): Promise { + const binding = this.keybindings.find(x => x['command'] == command); + const keys: string = binding.key; + let keysToPress: string[] = []; + + const chords = keys.split(' '); + chords.forEach((chord) => { + const keys = chord.split('+'); + keys.forEach((key) => keysToPress.push(this.transliterate(key))); + keysToPress.push('NULL'); + }); + + return this.client.keys(keysToPress, capture); + } + + /** + * Transliterates key names from keybindings file to WebdriverIO keyboard actions defined in: + * https://w3c.github.io/webdriver/webdriver-spec.html#keyboard-actions + */ + private transliterate(key: string): string { + switch (key) { + case 'ctrl': + return 'Control'; + case 'cmd': + return 'Meta'; + default: + return key.length === 1 ? key : key.charAt(0).toUpperCase() + key.slice(1); + }; + } +} diff --git a/smoketest/src/spectron/client.ts b/smoketest/src/spectron/client.ts new file mode 100644 index 00000000000..9376bd3e100 --- /dev/null +++ b/smoketest/src/spectron/client.ts @@ -0,0 +1,127 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { Application } from 'spectron'; +import { Screenshot } from '../helpers/screenshot'; + +/** + * Abstracts the Spectron's WebdriverIO managed client property on the created Application instances. + */ +export class SpectronClient { + + constructor(private spectron: Application, private shot: Screenshot) { + // noop + } + + public windowByIndex(index: number): Promise { + return this.spectron.client.windowByIndex(index); + } + + public async keys(keys: string[] | string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.keys(keys); + } + + public async getText(selector: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.getText(selector); + } + + public async getHTML(selector: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.getHTML(selector); + } + + public async click(selector: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.click(selector); + } + + public async doubleClick(selector: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.doubleClick(selector); + } + + public async leftClick(selector: string, xoffset: number, yoffset: number, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.leftClick(selector, xoffset, yoffset); + } + + public async rightClick(selector: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.rightClick(selector); + } + + public async moveToObject(selector: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.moveToObject(selector); + } + + public async setValue(selector: string, text: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.setValue(selector, text); + } + + public async elements(selector: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.elements(selector); + } + + public async element(selector: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.element(selector); + } + + public async dragAndDrop(sourceElem: string, destinationElem: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.dragAndDrop(sourceElem, destinationElem); + } + + public async selectByValue(selector: string, value: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.selectByValue(selector, value); + } + + public async getValue(selector: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.getValue(selector); + } + + public async getAttribute(selector: string, attribute: string, capture: boolean = true): Promise { + await this.execute(capture); + return Promise.resolve(this.spectron.client.getAttribute(selector, attribute)); + } + + public clearElement(selector: string): any { + return this.spectron.client.clearElement(selector); + } + + public buttonDown(): any { + return this.spectron.client.buttonDown(); + } + + public buttonUp(): any { + return this.spectron.client.buttonUp(); + } + + public async isVisible(selector: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.isVisible(selector); + } + + public getTitle(): string { + return this.spectron.client.getTitle(); + } + + private async execute(capture: boolean): Promise { + if (capture) { + try { + await this.shot.capture(); + } catch (e) { + throw new Error(`Screenshot could not be captured: ${e}`); + } + } + } +} \ No newline at end of file diff --git a/smoketest/tsconfig.json b/smoketest/tsconfig.json new file mode 100644 index 00000000000..1b0b03c2d67 --- /dev/null +++ b/smoketest/tsconfig.json @@ -0,0 +1,21 @@ +{ + "compilerOptions": { + "module": "commonjs", + "noImplicitAny": false, + "removeComments": false, + "preserveConstEnums": true, + "target": "es2016", + "strictNullChecks": true, + "noUnusedParameters": false, + "noUnusedLocals": true, + "outDir": "out", + "sourceMap": true, + "lib": [ + "es2016", + "dom" + ] + }, + "exclude": [ + "node_modules" + ] +} \ No newline at end of file diff --git a/vscode-smoketest-express b/vscode-smoketest-express new file mode 160000 index 00000000000..636dd7a2ff7 --- /dev/null +++ b/vscode-smoketest-express @@ -0,0 +1 @@ +Subproject commit 636dd7a2ff71d266c0e015411b47cf5c3a25be5a -- GitLab From aa82577941ea9f8b6337a56df47732fb568b9c64 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Mon, 22 May 2017 15:28:29 +0200 Subject: [PATCH 0014/1347] Moved to test directory. --- {smoketest => test/smoke}/.gitignore | 0 {smoketest => test/smoke}/.vscode/launch.json | 0 {smoketest => test/smoke}/.vscode/tasks.json | 0 {smoketest => test/smoke}/CONTRIBUTING.md | 0 {smoketest => test/smoke}/README.md | 0 {smoketest => test/smoke}/package.json | 0 {smoketest => test/smoke}/scripts/run.ps1 | 11 +++++------ {smoketest => test/smoke}/scripts/run.sh | 0 {smoketest => test/smoke}/src/areas/common.ts | 0 .../smoke}/src/areas/configuration-views.ts | 0 {smoketest => test/smoke}/src/areas/css.ts | 0 {smoketest => test/smoke}/src/areas/data-loss.ts | 0 {smoketest => test/smoke}/src/areas/extensions.ts | 0 .../smoke}/src/areas/first-experience.ts | 0 {smoketest => test/smoke}/src/areas/git.ts | 0 .../smoke}/src/areas/integrated-terminal.ts | 0 .../smoke}/src/areas/javascript-debug.ts | 0 {smoketest => test/smoke}/src/areas/javascript.ts | 0 {smoketest => test/smoke}/src/areas/localization.ts | 0 {smoketest => test/smoke}/src/areas/search.ts | 0 {smoketest => test/smoke}/src/areas/statusbar.ts | 0 {smoketest => test/smoke}/src/areas/tasks.ts | 0 {smoketest => test/smoke}/src/helpers/screenshot.ts | 0 {smoketest => test/smoke}/src/helpers/utilities.ts | 0 {smoketest => test/smoke}/src/main.ts | 0 {smoketest => test/smoke}/src/spectron/application.ts | 0 {smoketest => test/smoke}/src/spectron/client.ts | 0 {smoketest => test/smoke}/tsconfig.json | 0 28 files changed, 5 insertions(+), 6 deletions(-) rename {smoketest => test/smoke}/.gitignore (100%) rename {smoketest => test/smoke}/.vscode/launch.json (100%) rename {smoketest => test/smoke}/.vscode/tasks.json (100%) rename {smoketest => test/smoke}/CONTRIBUTING.md (100%) rename {smoketest => test/smoke}/README.md (100%) rename {smoketest => test/smoke}/package.json (100%) rename {smoketest => test/smoke}/scripts/run.ps1 (84%) rename {smoketest => test/smoke}/scripts/run.sh (100%) rename {smoketest => test/smoke}/src/areas/common.ts (100%) rename {smoketest => test/smoke}/src/areas/configuration-views.ts (100%) rename {smoketest => test/smoke}/src/areas/css.ts (100%) rename {smoketest => test/smoke}/src/areas/data-loss.ts (100%) rename {smoketest => test/smoke}/src/areas/extensions.ts (100%) rename {smoketest => test/smoke}/src/areas/first-experience.ts (100%) rename {smoketest => test/smoke}/src/areas/git.ts (100%) rename {smoketest => test/smoke}/src/areas/integrated-terminal.ts (100%) rename {smoketest => test/smoke}/src/areas/javascript-debug.ts (100%) rename {smoketest => test/smoke}/src/areas/javascript.ts (100%) rename {smoketest => test/smoke}/src/areas/localization.ts (100%) rename {smoketest => test/smoke}/src/areas/search.ts (100%) rename {smoketest => test/smoke}/src/areas/statusbar.ts (100%) rename {smoketest => test/smoke}/src/areas/tasks.ts (100%) rename {smoketest => test/smoke}/src/helpers/screenshot.ts (100%) rename {smoketest => test/smoke}/src/helpers/utilities.ts (100%) rename {smoketest => test/smoke}/src/main.ts (100%) rename {smoketest => test/smoke}/src/spectron/application.ts (100%) rename {smoketest => test/smoke}/src/spectron/client.ts (100%) rename {smoketest => test/smoke}/tsconfig.json (100%) diff --git a/smoketest/.gitignore b/test/smoke/.gitignore similarity index 100% rename from smoketest/.gitignore rename to test/smoke/.gitignore diff --git a/smoketest/.vscode/launch.json b/test/smoke/.vscode/launch.json similarity index 100% rename from smoketest/.vscode/launch.json rename to test/smoke/.vscode/launch.json diff --git a/smoketest/.vscode/tasks.json b/test/smoke/.vscode/tasks.json similarity index 100% rename from smoketest/.vscode/tasks.json rename to test/smoke/.vscode/tasks.json diff --git a/smoketest/CONTRIBUTING.md b/test/smoke/CONTRIBUTING.md similarity index 100% rename from smoketest/CONTRIBUTING.md rename to test/smoke/CONTRIBUTING.md diff --git a/smoketest/README.md b/test/smoke/README.md similarity index 100% rename from smoketest/README.md rename to test/smoke/README.md diff --git a/smoketest/package.json b/test/smoke/package.json similarity index 100% rename from smoketest/package.json rename to test/smoke/package.json diff --git a/smoketest/scripts/run.ps1 b/test/smoke/scripts/run.ps1 similarity index 84% rename from smoketest/scripts/run.ps1 rename to test/smoke/scripts/run.ps1 index d6368da6890..a7e29482a78 100644 --- a/smoketest/scripts/run.ps1 +++ b/test/smoke/scripts/run.ps1 @@ -1,10 +1,9 @@ Param( [Parameter(Position=0,mandatory=$true)] - [string] $latest, - [Parameter(Position=1,mandatory=$false)] - [string] $stable + [string]$arch ) + # Setup sample repository for the smoke test Set-Location .. if (-Not (Test-Path vscode-smoketest-express)) { @@ -19,14 +18,14 @@ if (-Not (Test-Path vscode-smoketest-express)) { npm install # Setup the test directory for running -Set-Location ..\smoketest +Set-Location ..\smoke if (-Not (Test-Path node_modules)) { npm install } # Configure environment variables -$env:VSCODE_LATEST_PATH = $latest -$env:VSCODE_STABLE_PATH = $stable +$env:VSCODE_LATEST_PATH = "$Root\VSCode-win32-$arch" +# $env:VSCODE_STABLE_PATH = $stable $env:SMOKETEST_REPO = "..\vscode-smoketest-express" if ($latest.Contains('Insiders')) { diff --git a/smoketest/scripts/run.sh b/test/smoke/scripts/run.sh similarity index 100% rename from smoketest/scripts/run.sh rename to test/smoke/scripts/run.sh diff --git a/smoketest/src/areas/common.ts b/test/smoke/src/areas/common.ts similarity index 100% rename from smoketest/src/areas/common.ts rename to test/smoke/src/areas/common.ts diff --git a/smoketest/src/areas/configuration-views.ts b/test/smoke/src/areas/configuration-views.ts similarity index 100% rename from smoketest/src/areas/configuration-views.ts rename to test/smoke/src/areas/configuration-views.ts diff --git a/smoketest/src/areas/css.ts b/test/smoke/src/areas/css.ts similarity index 100% rename from smoketest/src/areas/css.ts rename to test/smoke/src/areas/css.ts diff --git a/smoketest/src/areas/data-loss.ts b/test/smoke/src/areas/data-loss.ts similarity index 100% rename from smoketest/src/areas/data-loss.ts rename to test/smoke/src/areas/data-loss.ts diff --git a/smoketest/src/areas/extensions.ts b/test/smoke/src/areas/extensions.ts similarity index 100% rename from smoketest/src/areas/extensions.ts rename to test/smoke/src/areas/extensions.ts diff --git a/smoketest/src/areas/first-experience.ts b/test/smoke/src/areas/first-experience.ts similarity index 100% rename from smoketest/src/areas/first-experience.ts rename to test/smoke/src/areas/first-experience.ts diff --git a/smoketest/src/areas/git.ts b/test/smoke/src/areas/git.ts similarity index 100% rename from smoketest/src/areas/git.ts rename to test/smoke/src/areas/git.ts diff --git a/smoketest/src/areas/integrated-terminal.ts b/test/smoke/src/areas/integrated-terminal.ts similarity index 100% rename from smoketest/src/areas/integrated-terminal.ts rename to test/smoke/src/areas/integrated-terminal.ts diff --git a/smoketest/src/areas/javascript-debug.ts b/test/smoke/src/areas/javascript-debug.ts similarity index 100% rename from smoketest/src/areas/javascript-debug.ts rename to test/smoke/src/areas/javascript-debug.ts diff --git a/smoketest/src/areas/javascript.ts b/test/smoke/src/areas/javascript.ts similarity index 100% rename from smoketest/src/areas/javascript.ts rename to test/smoke/src/areas/javascript.ts diff --git a/smoketest/src/areas/localization.ts b/test/smoke/src/areas/localization.ts similarity index 100% rename from smoketest/src/areas/localization.ts rename to test/smoke/src/areas/localization.ts diff --git a/smoketest/src/areas/search.ts b/test/smoke/src/areas/search.ts similarity index 100% rename from smoketest/src/areas/search.ts rename to test/smoke/src/areas/search.ts diff --git a/smoketest/src/areas/statusbar.ts b/test/smoke/src/areas/statusbar.ts similarity index 100% rename from smoketest/src/areas/statusbar.ts rename to test/smoke/src/areas/statusbar.ts diff --git a/smoketest/src/areas/tasks.ts b/test/smoke/src/areas/tasks.ts similarity index 100% rename from smoketest/src/areas/tasks.ts rename to test/smoke/src/areas/tasks.ts diff --git a/smoketest/src/helpers/screenshot.ts b/test/smoke/src/helpers/screenshot.ts similarity index 100% rename from smoketest/src/helpers/screenshot.ts rename to test/smoke/src/helpers/screenshot.ts diff --git a/smoketest/src/helpers/utilities.ts b/test/smoke/src/helpers/utilities.ts similarity index 100% rename from smoketest/src/helpers/utilities.ts rename to test/smoke/src/helpers/utilities.ts diff --git a/smoketest/src/main.ts b/test/smoke/src/main.ts similarity index 100% rename from smoketest/src/main.ts rename to test/smoke/src/main.ts diff --git a/smoketest/src/spectron/application.ts b/test/smoke/src/spectron/application.ts similarity index 100% rename from smoketest/src/spectron/application.ts rename to test/smoke/src/spectron/application.ts diff --git a/smoketest/src/spectron/client.ts b/test/smoke/src/spectron/client.ts similarity index 100% rename from smoketest/src/spectron/client.ts rename to test/smoke/src/spectron/client.ts diff --git a/smoketest/tsconfig.json b/test/smoke/tsconfig.json similarity index 100% rename from smoketest/tsconfig.json rename to test/smoke/tsconfig.json -- GitLab From de5b4813dcb47d22bb6ae30de67dd4e633a2beb4 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Mon, 22 May 2017 16:04:33 +0200 Subject: [PATCH 0015/1347] Corrected path to binary. --- test/smoke/scripts/run.ps1 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/smoke/scripts/run.ps1 b/test/smoke/scripts/run.ps1 index a7e29482a78..23da3827cbe 100644 --- a/test/smoke/scripts/run.ps1 +++ b/test/smoke/scripts/run.ps1 @@ -24,11 +24,11 @@ if (-Not (Test-Path node_modules)) { } # Configure environment variables -$env:VSCODE_LATEST_PATH = "$Root\VSCode-win32-$arch" +$env:VSCODE_LATEST_PATH = "$Root\VSCode-win32-$arch\Code - OSS.exe" # $env:VSCODE_STABLE_PATH = $stable $env:SMOKETEST_REPO = "..\vscode-smoketest-express" -if ($latest.Contains('Insiders')) { +if ($env:VSCODE_LATEST_PATH.Contains('Insiders')) { $env:VSCODE_EDITION = 'insiders' } -- GitLab From d1759e016cfee7fedcbcb73a17745be6e129d288 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Mon, 22 May 2017 16:08:39 +0200 Subject: [PATCH 0016/1347] Changed executable name. --- test/smoke/scripts/run.ps1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/smoke/scripts/run.ps1 b/test/smoke/scripts/run.ps1 index 23da3827cbe..a2b8c047113 100644 --- a/test/smoke/scripts/run.ps1 +++ b/test/smoke/scripts/run.ps1 @@ -24,7 +24,7 @@ if (-Not (Test-Path node_modules)) { } # Configure environment variables -$env:VSCODE_LATEST_PATH = "$Root\VSCode-win32-$arch\Code - OSS.exe" +$env:VSCODE_LATEST_PATH = "$Root\VSCode-win32-$arch\Code - Insiders.exe" # $env:VSCODE_STABLE_PATH = $stable $env:SMOKETEST_REPO = "..\vscode-smoketest-express" -- GitLab From f2ff02b71db8b07869f35ba8e4dfaf8817828489 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Mon, 22 May 2017 16:52:50 +0200 Subject: [PATCH 0017/1347] Testing build definition. --- test/smoke/scripts/run.ps1 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/test/smoke/scripts/run.ps1 b/test/smoke/scripts/run.ps1 index a2b8c047113..5883ce0dbe8 100644 --- a/test/smoke/scripts/run.ps1 +++ b/test/smoke/scripts/run.ps1 @@ -17,6 +17,8 @@ if (-Not (Test-Path vscode-smoketest-express)) { } npm install +Write-Output "My path: " + $(pwd) + # Setup the test directory for running Set-Location ..\smoke if (-Not (Test-Path node_modules)) { @@ -24,7 +26,7 @@ if (-Not (Test-Path node_modules)) { } # Configure environment variables -$env:VSCODE_LATEST_PATH = "$Root\VSCode-win32-$arch\Code - Insiders.exe" +$env:VSCODE_LATEST_PATH = "$(pwd)\..\VSCode-win32-$arch\Code - Insiders.exe" # $env:VSCODE_STABLE_PATH = $stable $env:SMOKETEST_REPO = "..\vscode-smoketest-express" -- GitLab From 3315fcd486ee9ebd7e7280ac5fe079dbd64048c1 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Mon, 22 May 2017 17:34:16 +0200 Subject: [PATCH 0018/1347] First attempt to make the terminal the default runner. --- .../parts/tasks/common/taskSampleConfig.json | 6 -- .../parts/tasks/common/taskTemplates.ts | 56 +++++------ .../tasks/electron-browser/jsonSchema_v2.ts | 43 ++++++++- .../electron-browser/task.contribution.ts | 96 ++++++++----------- 4 files changed, 102 insertions(+), 99 deletions(-) delete mode 100644 src/vs/workbench/parts/tasks/common/taskSampleConfig.json diff --git a/src/vs/workbench/parts/tasks/common/taskSampleConfig.json b/src/vs/workbench/parts/tasks/common/taskSampleConfig.json deleted file mode 100644 index 5fc7fce47f9..00000000000 --- a/src/vs/workbench/parts/tasks/common/taskSampleConfig.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - // See https://go.microsoft.com/fwlink/?LinkId=733558 - // for the documentation about the tasks.json format - // Use IntelliSense to insert predefined task snippets - -} \ No newline at end of file diff --git a/src/vs/workbench/parts/tasks/common/taskTemplates.ts b/src/vs/workbench/parts/tasks/common/taskTemplates.ts index 01d2b68a0d0..d153e784935 100644 --- a/src/vs/workbench/parts/tasks/common/taskTemplates.ts +++ b/src/vs/workbench/parts/tasks/common/taskTemplates.ts @@ -22,11 +22,9 @@ const gulp: TaskEntry = { '{', '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', '\t// for the documentation about the tasks.json format', - '\t"version": "0.1.0",', - '\t"command": "gulp",', + '\t"version": "2.0.0",', + '\t"command": "gulp --no-color",', '\t"isShellCommand": true,', - '\t"args": ["--no-color"],', - '\t"showOutput": "always"', '}' ].join('\n') }; @@ -39,11 +37,9 @@ const grunt: TaskEntry = { '{', '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', '\t// for the documentation about the tasks.json format', - '\t"version": "0.1.0",', - '\t"command": "grunt",', + '\t"version": "2.0.0",', + '\t"command": "grunt --no-color",', '\t"isShellCommand": true,', - '\t"args": ["--no-color"],', - '\t"showOutput": "always"', '}' ].join('\n') }; @@ -57,23 +53,22 @@ const npm: TaskEntry = { '{', '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', '\t// for the documentation about the tasks.json format', - '\t"version": "0.1.0",', - '\t"command": "npm",', - '\t"isShellCommand": true,', - '\t"showOutput": "always",', - '\t"suppressTaskName": true,', + '\t"version": "2.0.0",', '\t"tasks": [', '\t\t{', '\t\t\t"taskName": "install",', - '\t\t\t"args": ["install"]', + '\t\t\t"command": "npm install",', + '\t\t\t"isShellCommand": true,', '\t\t},', '\t\t{', '\t\t\t"taskName": "update",', - '\t\t\t"args": ["update"]', + '\t\t\t"command": "npm update",', + '\t\t\t"isShellCommand": true,', '\t\t},', '\t\t{', '\t\t\t"taskName": "test",', - '\t\t\t"args": ["run", "test"]', + '\t\t\t"command": "npm run test",', + '\t\t\t"isShellCommand": true,', '\t\t}', '\t]', '}' @@ -89,10 +84,9 @@ const tscConfig: TaskEntry = { '{', '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', '\t// for the documentation about the tasks.json format', - '\t"version": "0.1.0",', - '\t"command": "tsc",', + '\t"version": "2.0.0",', + '\t"command": "tsc -p .",', '\t"isShellCommand": true,', - '\t"args": ["-p", "."],', '\t"showOutput": "silent",', '\t"problemMatcher": "$tsc"', '}' @@ -108,10 +102,9 @@ const tscWatch: TaskEntry = { '{', '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', '\t// for the documentation about the tasks.json format', - '\t"version": "0.1.0",', - '\t"command": "tsc",', + '\t"version": "2.0.0",', + '\t"command": "tsc -w -p .",', '\t"isShellCommand": true,', - '\t"args": ["-w", "-p", "."],', '\t"showOutput": "silent",', '\t"isBackground": true,', '\t"problemMatcher": "$tsc-watch"', @@ -155,7 +148,7 @@ const msbuild: TaskEntry = { '{', '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', '\t// for the documentation about the tasks.json format', - '\t"version": "0.1.0",', + '\t"version": "2.0.0",', '\t"command": "msbuild",', '\t"args": [', '\t\t// Ask msbuild to generate full paths for file names.', @@ -185,11 +178,9 @@ const command: TaskEntry = { '{', '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', '\t// for the documentation about the tasks.json format', - '\t"version": "0.1.0",', - '\t"command": "echo",', + '\t"version": "2.0.0",', + '\t"command": "echo \"Hello World\"",', '\t"isShellCommand": true,', - '\t"args": ["Hello World"],', - '\t"showOutput": "always"', '}' ].join('\n') }; @@ -204,20 +195,19 @@ const maven: TaskEntry = { '{', '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', '\t// for the documentation about the tasks.json format', - '\t"version": "0.1.0",', - '\t"command": "mvn",', - '\t"isShellCommand": true,', + '\t"version": "2.0.0",', '\t"showOutput": "always",', - '\t"suppressTaskName": true,', '\t"tasks": [', '\t\t{', '\t\t\t"taskName": "verify",', - '\t\t\t"args": ["-B", "verify"],', + '\t\t\t"command": "mvn -B verify",', + '\t\t\t"isShellCommand": true,', '\t\t\t"isBuildCommand": true', '\t\t},', '\t\t{', '\t\t\t"taskName": "test",', - '\t\t\t"args": ["-B", "test"],', + '\t\t\t"command": "mvn -B test",', + '\t\t\t"isShellCommand": true,', '\t\t\t"isTestCommand": true', '\t\t}', '\t]', diff --git a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts index 441507853aa..4ece04baf2e 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts @@ -75,12 +75,47 @@ const dependsOn: IJSONSchema = { ] }; +const terminal: IJSONSchema = { + type: 'object', + default: { + reveal: 'always', + echo: false + }, + description: nls.localize('JsonSchema.tasks.terminal', 'Describe how the terminal used to execute a task behaves.'), + properties: { + echo: { + type: 'boolean', + default: false, + description: nls.localize('JsonSchema.tasks.terminal.echo', 'Controls whether the executed command is echoed to the terminal. Default is false.') + }, + reveal: { + type: 'string', + enum: ['always', 'silent', 'never'], + default: 'always', + description: nls.localize('JsonSchema.tasks.terminal.reveals', 'Controls whether the terminal running the task is revealed or not. Default is \"always\".') + } + } +}; + +const group: IJSONSchema = { + type: 'string', + enum: ['none', 'clean', 'build', 'rebuildAll', 'test'], + default: 'none', + description: nls.localize('JsonSchema.tasks.group', 'Defines to which execution group this task belongs to. If omitted the task belongs to no group') +}; + schema.definitions = Objects.deepClone(commonSchema.definitions); let definitions = schema.definitions; -definitions['commandConfiguration']['properties']['isShellCommand'] = Objects.deepClone(shellCommand); -definitions['taskDescription']['properties']['isShellCommand'] = Objects.deepClone(shellCommand); -definitions['taskDescription']['properties']['dependsOn'] = dependsOn; -definitions['taskRunnerConfiguration']['properties']['isShellCommand'] = Objects.deepClone(shellCommand); +definitions.commandConfiguration.properties.isShellCommand = Objects.deepClone(shellCommand); +definitions.taskDescription.properties.isShellCommand = Objects.deepClone(shellCommand); +definitions.taskDescription.properties.dependsOn = dependsOn; +definitions.showOutputType.deprecationMessage = nls.localize('JsonSchema.tasks.showOputput.deprecated', 'The property showOutput is deprecated. Use the terminal property instead.'); +definitions.taskDescription.properties.echoCommand.deprecationMessage = nls.localize('JsonSchema.tasks.echoCommand.deprecated', 'The property echoCommand is deprecated. Use the terminal property instead.'); +definitions.taskDescription.properties.isBuildCommand.deprecationMessage = nls.localize('JsonSchema.tasks.isBuildCommand.deprecated', 'The property isBuildCommand is deprecated. Use the group property instead.'); +definitions.taskDescription.properties.isTestCommand.deprecationMessage = nls.localize('JsonSchema.tasks.isTestCommand.deprecated', 'The property isTestCommand is deprecated. Use the group property instead.'); +definitions.taskDescription.properties.terminal = terminal; +definitions.taskDescription.properties.group = group; +definitions.taskRunnerConfiguration.properties.isShellCommand = Objects.deepClone(shellCommand); Object.getOwnPropertyNames(definitions).forEach(key => { let newKey = key + '2'; diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index 3aff765da6a..997b51b2823 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -85,30 +85,17 @@ let tasksCategory = nls.localize('tasksCategory', "Tasks"); abstract class OpenTaskConfigurationAction extends Action { - private configurationService: IConfigurationService; - private fileService: IFileService; - - private editorService: IWorkbenchEditorService; - private contextService: IWorkspaceContextService; - private outputService: IOutputService; - private messageService: IMessageService; - private quickOpenService: IQuickOpenService; - - constructor(id: string, label: string, @IConfigurationService configurationService: IConfigurationService, - @IWorkbenchEditorService editorService: IWorkbenchEditorService, @IFileService fileService: IFileService, - @IWorkspaceContextService contextService: IWorkspaceContextService, @IOutputService outputService: IOutputService, - @IMessageService messageService: IMessageService, @IQuickOpenService quickOpenService: IQuickOpenService, - @IEnvironmentService private environmentService: IEnvironmentService, - @IConfigurationResolverService private configurationResolverService: IConfigurationResolverService) { + constructor(id: string, label: string, + private taskService: ITaskService, + private configurationService: IConfigurationService, + private editorService: IWorkbenchEditorService, private fileService: IFileService, + private contextService: IWorkspaceContextService, private outputService: IOutputService, + private messageService: IMessageService, private quickOpenService: IQuickOpenService, + private environmentService: IEnvironmentService, + private configurationResolverService: IConfigurationResolverService, + private extensionService: IExtensionService) { super(id, label); - this.configurationService = configurationService; - this.editorService = editorService; - this.fileService = fileService; - this.contextService = contextService; - this.outputService = outputService; - this.messageService = messageService; - this.quickOpenService = quickOpenService; } public run(event?: any): TPromise { @@ -128,27 +115,18 @@ abstract class OpenTaskConfigurationAction extends Action { } let contentPromise: TPromise; if (selection.autoDetect) { - const outputChannel = this.outputService.getChannel(TaskService.OutputChannelId); - outputChannel.show(true); - outputChannel.append(nls.localize('ConfigureTaskRunnerAction.autoDetecting', 'Auto detecting tasks for {0}', selection.id) + '\n'); - let detector = new ProcessRunnerDetector(this.fileService, this.contextService, this.configurationResolverService); - contentPromise = detector.detect(false, selection.id).then((value) => { - let config = value.config; - if (value.stderr && value.stderr.length > 0) { - value.stderr.forEach((line) => { - outputChannel.append(line + '\n'); + contentPromise = this.extensionService.activateByEvent('onCommand:workbench.action.tasks.runTask').then(() => { + return this.taskService.tasks().then((tasks) => { + let tasksToInsert: Task[] = tasks.filter((task) => { + return task.identifier && task.identifier.indexOf(selection.id) === 0 && task.identifier[selection.id.length] === '.' && task.group !== void 0; }); - if (config && (!config.tasks || config.tasks.length === 0)) { - this.messageService.show(Severity.Warning, nls.localize('ConfigureTaskRunnerAction.autoDetect', 'Auto detecting the task system failed. Using default template. Consult the task output for details.')); + if (tasksToInsert.length === 0) { return selection.content; - } else { - this.messageService.show(Severity.Warning, nls.localize('ConfigureTaskRunnerAction.autoDetectError', 'Auto detecting the task system produced errors. Consult the task output for details.')); - } - } - if (config) { - if (value.stdout && value.stdout.length > 0) { - value.stdout.forEach(line => outputChannel.append(line + '\n')); } + let config: TaskConfig.ExternalTaskRunnerConfiguration = { + version: '2.0.0', + tasks: tasksToInsert.map((task) => { return { taskName: task.name }; }) + }; let content = JSON.stringify(config, null, '\t'); content = [ '{', @@ -156,9 +134,7 @@ abstract class OpenTaskConfigurationAction extends Action { '\t// for the documentation about the tasks.json format', ].join('\n') + content.substr(1); return content; - } else { - return selection.content; - } + }); }); } else { contentPromise = TPromise.as(selection.content); @@ -194,14 +170,17 @@ class ConfigureTaskRunnerAction extends OpenTaskConfigurationAction { public static ID = 'workbench.action.tasks.configureTaskRunner'; public static TEXT = nls.localize('ConfigureTaskRunnerAction.label', "Configure Task Runner"); - constructor(id: string, label: string, @IConfigurationService configurationService: IConfigurationService, + constructor(id: string, label: string, + @ITaskService taskService, @IConfigurationService configurationService: IConfigurationService, @IWorkbenchEditorService editorService: IWorkbenchEditorService, @IFileService fileService: IFileService, @IWorkspaceContextService contextService: IWorkspaceContextService, @IOutputService outputService: IOutputService, @IMessageService messageService: IMessageService, @IQuickOpenService quickOpenService: IQuickOpenService, @IEnvironmentService environmentService: IEnvironmentService, - @IConfigurationResolverService configurationResolverService: IConfigurationResolverService) { - super(id, label, configurationService, editorService, fileService, contextService, - outputService, messageService, quickOpenService, environmentService, configurationResolverService); + @IConfigurationResolverService configurationResolverService: IConfigurationResolverService, + @IExtensionService extensionService) { + super(id, label, taskService, configurationService, editorService, fileService, contextService, + outputService, messageService, quickOpenService, environmentService, configurationResolverService, + extensionService); } } @@ -210,14 +189,17 @@ class ConfigureBuildTaskAction extends OpenTaskConfigurationAction { public static ID = 'workbench.action.tasks.configureBuildTask'; public static TEXT = nls.localize('ConfigureBuildTaskAction.label', "Configure Build Task"); - constructor(id: string, label: string, @IConfigurationService configurationService: IConfigurationService, + constructor(id: string, label: string, + @ITaskService taskService, @IConfigurationService configurationService: IConfigurationService, @IWorkbenchEditorService editorService: IWorkbenchEditorService, @IFileService fileService: IFileService, @IWorkspaceContextService contextService: IWorkspaceContextService, @IOutputService outputService: IOutputService, @IMessageService messageService: IMessageService, @IQuickOpenService quickOpenService: IQuickOpenService, @IEnvironmentService environmentService: IEnvironmentService, - @IConfigurationResolverService configurationResolverService: IConfigurationResolverService) { - super(id, label, configurationService, editorService, fileService, contextService, - outputService, messageService, quickOpenService, environmentService, configurationResolverService); + @IConfigurationResolverService configurationResolverService: IConfigurationResolverService, + @IExtensionService extensionService) { + super(id, label, taskService, configurationService, editorService, fileService, contextService, + outputService, messageService, quickOpenService, environmentService, configurationResolverService, + extensionService); } } @@ -1072,7 +1054,7 @@ class TaskService extends EventEmitter implements ITaskService { private getExecutionEngine(): ExecutionEngine { let { config } = this.getConfiguration(); if (!config) { - return ExecutionEngine.Process; + return ExecutionEngine.Terminal; } return TaskConfig.ExecutionEngine.from(config); } @@ -1124,15 +1106,17 @@ class TaskService extends EventEmitter implements ITaskService { } public configureAction(): Action { - return new ConfigureTaskRunnerAction(ConfigureTaskRunnerAction.ID, ConfigureTaskRunnerAction.TEXT, + return new ConfigureTaskRunnerAction(ConfigureTaskRunnerAction.ID, ConfigureTaskRunnerAction.TEXT, this, this.configurationService, this.editorService, this.fileService, this.contextService, - this.outputService, this.messageService, this.quickOpenService, this.environmentService, this.configurationResolverService); + this.outputService, this.messageService, this.quickOpenService, this.environmentService, this.configurationResolverService, + this.extensionService); } private configureBuildTask(): Action { - return new ConfigureBuildTaskAction(ConfigureBuildTaskAction.ID, ConfigureBuildTaskAction.TEXT, + return new ConfigureBuildTaskAction(ConfigureBuildTaskAction.ID, ConfigureBuildTaskAction.TEXT, this, this.configurationService, this.editorService, this.fileService, this.contextService, - this.outputService, this.messageService, this.quickOpenService, this.environmentService, this.configurationResolverService); + this.outputService, this.messageService, this.quickOpenService, this.environmentService, this.configurationResolverService, + this.extensionService); } public beforeShutdown(): boolean | TPromise { -- GitLab From 84ece8b57bd82949eaf5291172319fcd65424d5d Mon Sep 17 00:00:00 2001 From: waisuikei Date: Tue, 23 May 2017 17:14:21 +0800 Subject: [PATCH 0019/1347] Add entry file of oniguruma when packing --- build/gulpfile.vscode.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index f91e140fd96..47bff361df3 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -274,7 +274,7 @@ function packageTask(platform, arch, opts) { const deps = gulp.src(depsSrc, { base: '.', dot: true }) .pipe(util.cleanNodeModule('fsevents', ['binding.gyp', 'fsevents.cc', 'build/**', 'src/**', 'test/**'], ['**/*.node'])) - .pipe(util.cleanNodeModule('oniguruma', ['binding.gyp', 'build/**', 'src/**', 'deps/**'], ['**/*.node'])) + .pipe(util.cleanNodeModule('oniguruma', ['binding.gyp', 'build/**', 'src/**', 'deps/**'], ['**/*.node', 'src/*.js'])) .pipe(util.cleanNodeModule('windows-mutex', ['binding.gyp', 'build/**', 'src/**'], ['**/*.node'])) .pipe(util.cleanNodeModule('native-keymap', ['binding.gyp', 'build/**', 'src/**', 'deps/**'], ['**/*.node'])) .pipe(util.cleanNodeModule('jschardet', ['dist/**'])) -- GitLab From 85fa3c5276e666dbaf344b5d98bfdfa439da5b85 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Tue, 23 May 2017 14:48:36 +0200 Subject: [PATCH 0020/1347] wip: ViewletActivityAction in activity bar --- src/vs/workbench/browser/activity.ts | 39 +++ .../parts/activitybar/activitybarActions.ts | 252 ++++++++++-------- .../parts/activitybar/activitybarPart.ts | 52 +++- 3 files changed, 224 insertions(+), 119 deletions(-) create mode 100644 src/vs/workbench/browser/activity.ts diff --git a/src/vs/workbench/browser/activity.ts b/src/vs/workbench/browser/activity.ts new file mode 100644 index 00000000000..d0912ebc79b --- /dev/null +++ b/src/vs/workbench/browser/activity.ts @@ -0,0 +1,39 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { Registry } from 'vs/platform/platform'; +import { IConstructorSignature0 } from 'vs/platform/instantiation/common/instantiation'; + +export interface IActivity { + id: string; + name: string; + cssClass: string; +} + +export const Extensions = { + Activities: 'workbench.contributions.activities' +}; + +export interface IActivityRegistry { + registerActivity(descriptor: IConstructorSignature0): void; + getActivities(): IConstructorSignature0[]; +} + +export class ActivityRegistry implements IActivityRegistry { + + private activityDescriptors = new Set>(); + + registerActivity(descriptor: IConstructorSignature0): void { + this.activityDescriptors.add(descriptor); + } + + getActivities(): IConstructorSignature0[] { + const result: IConstructorSignature0[] = []; + this.activityDescriptors.forEach(d => result.push(d)); + return result; + } +} + +Registry.add(Extensions.Activities, new ActivityRegistry()); \ No newline at end of file diff --git a/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts b/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts index e1133c4e5ce..b599f0fed2e 100644 --- a/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts +++ b/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts @@ -20,6 +20,7 @@ import { ICommandService } from 'vs/platform/commands/common/commands'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { ViewletDescriptor } from 'vs/workbench/browser/viewlet'; +import { IActivity } from 'vs/workbench/browser/activity'; import { dispose } from 'vs/base/common/lifecycle'; import { IViewletService, } from 'vs/workbench/services/viewlet/browser/viewlet'; import { IPartService, Parts } from 'vs/workbench/services/part/common/partService'; @@ -31,8 +32,12 @@ export class ActivityAction extends Action { private badge: IBadge; private _onDidChangeBadge = new Emitter(); - constructor(id: string, name: string, clazz: string) { - super(id, name, clazz); + get activity(): IActivity { + return this._activity; + } + + constructor(private _activity: IActivity) { + super(_activity.id, _activity.name, _activity.cssClass); this.badge = null; } @@ -74,7 +79,7 @@ export class ViewletActivityAction extends ActivityAction { @IViewletService private viewletService: IViewletService, @IPartService private partService: IPartService ) { - super(viewlet.id, viewlet.name, viewlet.cssClass); + super(viewlet); } public run(event): TPromise { @@ -102,7 +107,15 @@ export class ViewletActivityAction extends ActivityAction { } } -export abstract class ThemableActivityActionItem extends BaseActionItem { +export class ActivityActionItem extends BaseActionItem { + + protected $label: Builder; + protected $badge: Builder; + private $badgeContent: Builder; + + protected get activity(): IActivity { + return (this._action as ActivityAction).activity; + } constructor( action: ActivityAction, @@ -114,31 +127,114 @@ export abstract class ThemableActivityActionItem extends BaseActionItem { this.themeService.onThemeChange(this.onThemeChange, this, this._callOnDispose); } + protected updateStyles(): void { + const theme = this.themeService.getTheme(); + + // Label + if (this.$label) { + const background = theme.getColor(ACTIVITY_BAR_FOREGROUND); + + this.$label.style('background-color', background ? background.toString() : null); + } + + // Badge + if (this.$badgeContent) { + const badgeForeground = theme.getColor(ACTIVITY_BAR_BADGE_FOREGROUND); + const badgeBackground = theme.getColor(ACTIVITY_BAR_BADGE_BACKGROUND); + const contrastBorderColor = theme.getColor(contrastBorder); + + this.$badgeContent.style('color', badgeForeground ? badgeForeground.toString() : null); + this.$badgeContent.style('background-color', badgeBackground ? badgeBackground.toString() : null); + + this.$badgeContent.style('border-style', contrastBorderColor ? 'solid' : null); + this.$badgeContent.style('border-width', contrastBorderColor ? '1px' : null); + this.$badgeContent.style('border-color', contrastBorderColor ? contrastBorderColor.toString() : null); + } + } + + public render(container: HTMLElement): void { + super.render(container); + + // Label + this.$label = $('a.action-label').appendTo(this.builder); + if (this.activity.cssClass) { + this.$label.addClass(this.activity.cssClass); + } + + this.$badge = this.builder.div({ 'class': 'badge' }, (badge: Builder) => { + this.$badgeContent = badge.div({ 'class': 'badge-content' }); + }); + + this.$badge.hide(); + + this.updateStyles(); + } + private onThemeChange(theme: ITheme): void { this.updateStyles(); } - protected abstract updateStyles(): void; + public setBadge(badge: IBadge): void { + this.updateBadge(badge); + } + + protected updateBadge(badge: IBadge): void { + this.$badgeContent.empty(); + this.$badge.hide(); + + if (badge) { + + // Number + if (badge instanceof NumberBadge) { + if (badge.number) { + this.$badgeContent.text(badge.number > 99 ? '99+' : badge.number.toString()); + this.$badge.show(); + } + } + + // Text + else if (badge instanceof TextBadge) { + this.$badgeContent.text(badge.text); + this.$badge.show(); + } + + // Text + else if (badge instanceof IconBadge) { + this.$badge.show(); + } + + // Progress + else if (badge instanceof ProgressBadge) { + this.$badge.show(); + } + + this.$label.attr('aria-label', `${this.activity.name} - ${badge.getDescription()}`); + } + } + + public dispose(): void { + super.dispose(); + this.$badge.destroy(); + } } -export class ActivityActionItem extends ThemableActivityActionItem { +export class ViewletActionItem extends ActivityActionItem { private static manageExtensionAction: ManageExtensionAction; private static toggleViewletPinnedAction: ToggleViewletPinnedAction; private static draggedViewlet: ViewletDescriptor; private $container: Builder; - private $label: Builder; - private name: string; private _keybinding: string; private cssClass: string; - private $badge: Builder; - private $badgeContent: Builder; private mouseUpTimeout: number; + private get viewlet(): ViewletDescriptor { + return this.action.activity as ViewletDescriptor; + } + constructor( - action: ActivityAction, - private viewlet: ViewletDescriptor, + private action: ViewletActivityAction, @IContextMenuService private contextMenuService: IContextMenuService, @IActivityBarService private activityBarService: IActivityBarService, @IKeybindingService private keybindingService: IKeybindingService, @@ -148,45 +244,19 @@ export class ActivityActionItem extends ThemableActivityActionItem { super(action, { draggable: true }, themeService); this.cssClass = action.class; - this.name = viewlet.name; - this._keybinding = this.getKeybindingLabel(viewlet.id); + this._keybinding = this.getKeybindingLabel(this.viewlet.id); - if (!ActivityActionItem.manageExtensionAction) { - ActivityActionItem.manageExtensionAction = instantiationService.createInstance(ManageExtensionAction); + if (!ViewletActionItem.manageExtensionAction) { + ViewletActionItem.manageExtensionAction = instantiationService.createInstance(ManageExtensionAction); } - if (!ActivityActionItem.toggleViewletPinnedAction) { - ActivityActionItem.toggleViewletPinnedAction = instantiationService.createInstance(ToggleViewletPinnedAction, void 0); + if (!ViewletActionItem.toggleViewletPinnedAction) { + ViewletActionItem.toggleViewletPinnedAction = instantiationService.createInstance(ToggleViewletPinnedAction, void 0); } action.onDidChangeBadge(this.handleBadgeChangeEvenet, this, this._callOnDispose); } - protected updateStyles(): void { - const theme = this.themeService.getTheme(); - - // Label - if (this.$label) { - const background = theme.getColor(ACTIVITY_BAR_FOREGROUND); - - this.$label.style('background-color', background ? background.toString() : null); - } - - // Badge - if (this.$badgeContent) { - const badgeForeground = theme.getColor(ACTIVITY_BAR_BADGE_FOREGROUND); - const badgeBackground = theme.getColor(ACTIVITY_BAR_BADGE_BACKGROUND); - const contrastBorderColor = theme.getColor(contrastBorder); - - this.$badgeContent.style('color', badgeForeground ? badgeForeground.toString() : null); - this.$badgeContent.style('background-color', badgeBackground ? badgeBackground.toString() : null); - - this.$badgeContent.style('border-style', contrastBorderColor ? 'solid' : null); - this.$badgeContent.style('border-width', contrastBorderColor ? '1px' : null); - this.$badgeContent.style('border-color', contrastBorderColor ? contrastBorderColor.toString() : null); - } - } - private getKeybindingLabel(id: string): string { const kb = this.keybindingService.lookupKeybinding(id); if (kb) { @@ -240,7 +310,7 @@ export class ActivityActionItem extends ThemableActivityActionItem { // Drag enter let counter = 0; // see https://github.com/Microsoft/vscode/issues/14470 this.$container.on(DOM.EventType.DRAG_ENTER, (e: DragEvent) => { - const draggedViewlet = ActivityActionItem.getDraggedViewlet(); + const draggedViewlet = ViewletActionItem.getDraggedViewlet(); if (draggedViewlet && draggedViewlet.id !== this.viewlet.id) { counter++; this.updateFromDragging(container, true); @@ -249,7 +319,7 @@ export class ActivityActionItem extends ThemableActivityActionItem { // Drag leave this.$container.on(DOM.EventType.DRAG_LEAVE, (e: DragEvent) => { - const draggedViewlet = ActivityActionItem.getDraggedViewlet(); + const draggedViewlet = ViewletActionItem.getDraggedViewlet(); if (draggedViewlet) { counter--; if (counter === 0) { @@ -260,12 +330,12 @@ export class ActivityActionItem extends ThemableActivityActionItem { // Drag end this.$container.on(DOM.EventType.DRAG_END, (e: DragEvent) => { - const draggedViewlet = ActivityActionItem.getDraggedViewlet(); + const draggedViewlet = ViewletActionItem.getDraggedViewlet(); if (draggedViewlet) { counter = 0; this.updateFromDragging(container, false); - ActivityActionItem.clearDraggedViewlet(); + ViewletActionItem.clearDraggedViewlet(); } }); @@ -273,34 +343,21 @@ export class ActivityActionItem extends ThemableActivityActionItem { this.$container.on(DOM.EventType.DROP, (e: DragEvent) => { DOM.EventHelper.stop(e, true); - const draggedViewlet = ActivityActionItem.getDraggedViewlet(); + const draggedViewlet = ViewletActionItem.getDraggedViewlet(); if (draggedViewlet && draggedViewlet.id !== this.viewlet.id) { this.updateFromDragging(container, false); - ActivityActionItem.clearDraggedViewlet(); + ViewletActionItem.clearDraggedViewlet(); this.activityBarService.move(draggedViewlet.id, this.viewlet.id); } }); - // Label - this.$label = $('a.action-label').appendTo(this.builder); - if (this.cssClass) { - this.$label.addClass(this.cssClass); - } - - // Badge - this.$badge = this.builder.div({ 'class': 'badge' }, (badge: Builder) => { - this.$badgeContent = badge.div({ 'class': 'badge-content' }); - }); - - this.$badge.hide(); - // Keybinding this.keybinding = this._keybinding; // force update // Activate on drag over to reveal targets [this.$badge, this.$label].forEach(b => new DelayedDragHandler(b.getHTMLElement(), () => { - if (!ActivityActionItem.getDraggedViewlet() && !this.getAction().checked) { + if (!ViewletActionItem.getDraggedViewlet() && !this.getAction().checked) { this.getAction().run(); } })); @@ -316,29 +373,29 @@ export class ActivityActionItem extends ThemableActivityActionItem { } public static getDraggedViewlet(): ViewletDescriptor { - return ActivityActionItem.draggedViewlet; + return ViewletActionItem.draggedViewlet; } private setDraggedViewlet(viewlet: ViewletDescriptor): void { - ActivityActionItem.draggedViewlet = viewlet; + ViewletActionItem.draggedViewlet = viewlet; } public static clearDraggedViewlet(): void { - ActivityActionItem.draggedViewlet = void 0; + ViewletActionItem.draggedViewlet = void 0; } private showContextMenu(container: HTMLElement): void { - const actions: Action[] = [ActivityActionItem.toggleViewletPinnedAction]; + const actions: Action[] = [ViewletActionItem.toggleViewletPinnedAction]; if (this.viewlet.extensionId) { actions.push(new Separator()); - actions.push(ActivityActionItem.manageExtensionAction); + actions.push(ViewletActionItem.manageExtensionAction); } const isPinned = this.activityBarService.isPinned(this.viewlet.id); if (isPinned) { - ActivityActionItem.toggleViewletPinnedAction.label = nls.localize('removeFromActivityBar', "Remove from Activity Bar"); + ViewletActionItem.toggleViewletPinnedAction.label = nls.localize('removeFromActivityBar', "Remove from Activity Bar"); } else { - ActivityActionItem.toggleViewletPinnedAction.label = nls.localize('keepInActivityBar', "Keep in Activity Bar"); + ViewletActionItem.toggleViewletPinnedAction.label = nls.localize('keepInActivityBar', "Keep in Activity Bar"); } this.contextMenuService.showContextMenu({ @@ -352,10 +409,6 @@ export class ActivityActionItem extends ThemableActivityActionItem { this.$container.domFocus(); } - public setBadge(badge: IBadge): void { - this.updateBadge(badge); - } - public set keybinding(keybinding: string) { this._keybinding = keybinding; @@ -365,49 +418,15 @@ export class ActivityActionItem extends ThemableActivityActionItem { let title: string; if (keybinding) { - title = nls.localize('titleKeybinding', "{0} ({1})", this.name, keybinding); + title = nls.localize('titleKeybinding', "{0} ({1})", this.activity.name, keybinding); } else { - title = this.name; + title = this.activity.name; } this.$label.title(title); this.$badge.title(title); } - private updateBadge(badge: IBadge): void { - this.$badgeContent.empty(); - this.$badge.hide(); - - if (badge) { - - // Number - if (badge instanceof NumberBadge) { - if (badge.number) { - this.$badgeContent.text(badge.number > 99 ? '99+' : badge.number.toString()); - this.$badge.show(); - } - } - - // Text - else if (badge instanceof TextBadge) { - this.$badgeContent.text(badge.text); - this.$badge.show(); - } - - // Text - else if (badge instanceof IconBadge) { - this.$badge.show(); - } - - // Progress - else if (badge instanceof ProgressBadge) { - this.$badge.show(); - } - - this.$label.attr('aria-label', `${this.name} - ${badge.getDescription()}`); - } - } - protected _updateClass(): void { if (this.cssClass) { this.$badge.removeClass(this.cssClass); @@ -443,13 +462,12 @@ export class ActivityActionItem extends ThemableActivityActionItem { public dispose(): void { super.dispose(); - ActivityActionItem.clearDraggedViewlet(); + ViewletActionItem.clearDraggedViewlet(); if (this.mouseUpTimeout) { clearTimeout(this.mouseUpTimeout); } - this.$badge.destroy(); this.$label.destroy(); } } @@ -459,7 +477,11 @@ export class ViewletOverflowActivityAction extends ActivityAction { constructor( private showMenu: () => void ) { - super('activitybar.additionalViewlets.action', nls.localize('additionalViews', "Additional Views"), 'toggle-more'); + super({ + id: 'activitybar.additionalViewlets.action', + name: nls.localize('additionalViews', "Additional Views"), + cssClass: 'toggle-more' + }); } public run(event): TPromise { @@ -469,8 +491,8 @@ export class ViewletOverflowActivityAction extends ActivityAction { } } -export class ViewletOverflowActivityActionItem extends ThemableActivityActionItem { - private $label: Builder; +export class ViewletOverflowActivityActionItem extends ActivityActionItem { + private name: string; private cssClass: string; private actions: OpenViewletAction[]; diff --git a/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts b/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts index d824b944e0c..72bb2ea28d9 100644 --- a/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts +++ b/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts @@ -15,9 +15,11 @@ import { Builder, $, Dimension } from 'vs/base/browser/builder'; import { Action } from 'vs/base/common/actions'; import { ActionsOrientation, ActionBar, IActionItem, Separator } from 'vs/base/browser/ui/actionbar/actionbar'; import { ViewletDescriptor } from 'vs/workbench/browser/viewlet'; +import { IActivity, Extensions as ActivityExtensions, IActivityRegistry } from 'vs/workbench/browser/activity'; +import { Registry } from 'vs/platform/platform'; import { Part } from 'vs/workbench/browser/part'; import { IViewlet } from 'vs/workbench/common/viewlet'; -import { ToggleViewletPinnedAction, ViewletActivityAction, ActivityAction, ActivityActionItem, ViewletOverflowActivityAction, ViewletOverflowActivityActionItem } from 'vs/workbench/browser/parts/activitybar/activitybarActions'; +import { ToggleViewletPinnedAction, ViewletActivityAction, ActivityAction, ViewletActionItem, ViewletOverflowActivityAction, ViewletOverflowActivityActionItem } from 'vs/workbench/browser/parts/activitybar/activitybarActions'; import { IViewletService } from 'vs/workbench/services/viewlet/browser/viewlet'; import { IActivityBarService, IBadge } from 'vs/workbench/services/activity/common/activityBarService'; import { IPartService, Position as SideBarPosition } from 'vs/workbench/services/part/common/partService'; @@ -38,6 +40,21 @@ interface IViewletActivity { clazz: string; } +class GlobalActivityAction extends ActivityAction { + + constructor(activity: IActivity) { + super(activity); + } +} + +class GlobalActivityActionItem extends ViewletActionItem { + + onClick(event: Event): void { + DOM.EventHelper.stop(event, true); + // fire up native menu around this.builder.getHTMLElement() + } +} + export class ActivitybarPart extends Part implements IActivityBarService { private static readonly ACTIVITY_ACTION_HEIGHT = 50; @@ -48,6 +65,7 @@ export class ActivitybarPart extends Part implements IActivityBarService { private dimension: Dimension; private viewletSwitcherBar: ActionBar; + private activityActionBar: ActionBar; private viewletOverflowAction: ViewletOverflowActivityAction; private viewletOverflowActionItem: ViewletOverflowActivityActionItem; @@ -180,6 +198,9 @@ export class ActivitybarPart extends Part implements IActivityBarService { // Top Actionbar with action items for each viewlet action this.createViewletSwitcher($result.clone()); + // Top Actionbar with action items for each viewlet action + this.createActivityActionBar($result.getHTMLElement()); + // Contextmenu for viewlets $(parent).on('contextmenu', (e: MouseEvent) => { DOM.EventHelper.stop(e, true); @@ -189,11 +210,11 @@ export class ActivitybarPart extends Part implements IActivityBarService { // Allow to drop at the end to move viewlet to the end $(parent).on(DOM.EventType.DROP, (e: DragEvent) => { - const draggedViewlet = ActivityActionItem.getDraggedViewlet(); + const draggedViewlet = ViewletActionItem.getDraggedViewlet(); if (draggedViewlet) { DOM.EventHelper.stop(e, true); - ActivityActionItem.clearDraggedViewlet(); + ViewletActionItem.clearDraggedViewlet(); const targetId = this.pinnedViewlets[this.pinnedViewlets.length - 1]; if (targetId !== draggedViewlet.id) { @@ -252,6 +273,29 @@ export class ActivitybarPart extends Part implements IActivityBarService { this.extensionService.onReady().then(() => this.updateViewletSwitcher()); } + private createActivityActionBar(container: HTMLElement): void { + const activityRegistry = Registry.as(ActivityExtensions.Activities); + const descriptors = activityRegistry.getActivities(); + const actions = descriptors + .map(d => this.instantiationService.createInstance(d)) + .map(a => new GlobalActivityAction(a)); + + this.activityActionBar = new ActionBar(container, { + actionItemProvider: a => this.instantiationService.createInstance(GlobalActivityActionItem, a), + orientation: ActionsOrientation.VERTICAL, + ariaLabel: nls.localize('globalActions', "Global Actions"), + animated: false + }); + + actions.forEach(a => this.activityActionBar.push(a)); + + this.updateGlobalSwitcher(); + } + + private updateGlobalSwitcher(): void { + + } + private updateViewletSwitcher() { let viewletsToShow = this.getPinnedViewlets(); @@ -371,7 +415,7 @@ export class ActivitybarPart extends Part implements IActivityBarService { private toAction(viewlet: ViewletDescriptor): ActivityAction { const action = this.instantiationService.createInstance(ViewletActivityAction, viewlet); - this.viewletIdToActionItems[action.id] = this.instantiationService.createInstance(ActivityActionItem, action, viewlet); + this.viewletIdToActionItems[action.id] = this.instantiationService.createInstance(ViewletActionItem, action); this.viewletIdToActions[viewlet.id] = action; return action; -- GitLab From e3c4a2f34d9656abd0f4c8484700a038f7714e08 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Tue, 23 May 2017 14:58:29 +0200 Subject: [PATCH 0021/1347] wip: global update activity --- src/vs/workbench/browser/activity.ts | 6 ++---- .../browser/parts/activitybar/activitybarPart.ts | 13 +++++++------ .../parts/activitybar/media/activitybarpart.css | 3 +++ .../electron-browser/media/update.contribution.css | 9 +++++++++ .../parts/update/electron-browser/media/update.svg | 3 +++ .../update/electron-browser/update.contribution.ts | 11 +++++++++++ 6 files changed, 35 insertions(+), 10 deletions(-) create mode 100644 src/vs/workbench/parts/update/electron-browser/media/update.contribution.css create mode 100644 src/vs/workbench/parts/update/electron-browser/media/update.svg diff --git a/src/vs/workbench/browser/activity.ts b/src/vs/workbench/browser/activity.ts index d0912ebc79b..72bcee88c94 100644 --- a/src/vs/workbench/browser/activity.ts +++ b/src/vs/workbench/browser/activity.ts @@ -12,9 +12,7 @@ export interface IActivity { cssClass: string; } -export const Extensions = { - Activities: 'workbench.contributions.activities' -}; +export const ActivityExtensions = 'workbench.contributions.activities'; export interface IActivityRegistry { registerActivity(descriptor: IConstructorSignature0): void; @@ -36,4 +34,4 @@ export class ActivityRegistry implements IActivityRegistry { } } -Registry.add(Extensions.Activities, new ActivityRegistry()); \ No newline at end of file +Registry.add(ActivityExtensions, new ActivityRegistry()); \ No newline at end of file diff --git a/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts b/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts index 72bb2ea28d9..d548ebd34d3 100644 --- a/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts +++ b/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts @@ -15,11 +15,11 @@ import { Builder, $, Dimension } from 'vs/base/browser/builder'; import { Action } from 'vs/base/common/actions'; import { ActionsOrientation, ActionBar, IActionItem, Separator } from 'vs/base/browser/ui/actionbar/actionbar'; import { ViewletDescriptor } from 'vs/workbench/browser/viewlet'; -import { IActivity, Extensions as ActivityExtensions, IActivityRegistry } from 'vs/workbench/browser/activity'; +import { IActivity, ActivityExtensions, IActivityRegistry } from 'vs/workbench/browser/activity'; import { Registry } from 'vs/platform/platform'; import { Part } from 'vs/workbench/browser/part'; import { IViewlet } from 'vs/workbench/common/viewlet'; -import { ToggleViewletPinnedAction, ViewletActivityAction, ActivityAction, ViewletActionItem, ViewletOverflowActivityAction, ViewletOverflowActivityActionItem } from 'vs/workbench/browser/parts/activitybar/activitybarActions'; +import { ToggleViewletPinnedAction, ViewletActivityAction, ActivityAction, ActivityActionItem, ViewletActionItem, ViewletOverflowActivityAction, ViewletOverflowActivityActionItem } from 'vs/workbench/browser/parts/activitybar/activitybarActions'; import { IViewletService } from 'vs/workbench/services/viewlet/browser/viewlet'; import { IActivityBarService, IBadge } from 'vs/workbench/services/activity/common/activityBarService'; import { IPartService, Position as SideBarPosition } from 'vs/workbench/services/part/common/partService'; @@ -47,10 +47,11 @@ class GlobalActivityAction extends ActivityAction { } } -class GlobalActivityActionItem extends ViewletActionItem { +class GlobalActivityActionItem extends ActivityActionItem { onClick(event: Event): void { DOM.EventHelper.stop(event, true); + console.log('hello world'); // fire up native menu around this.builder.getHTMLElement() } } @@ -199,7 +200,7 @@ export class ActivitybarPart extends Part implements IActivityBarService { this.createViewletSwitcher($result.clone()); // Top Actionbar with action items for each viewlet action - this.createActivityActionBar($result.getHTMLElement()); + this.createGlobalActivityActionBar($result.getHTMLElement()); // Contextmenu for viewlets $(parent).on('contextmenu', (e: MouseEvent) => { @@ -273,8 +274,8 @@ export class ActivitybarPart extends Part implements IActivityBarService { this.extensionService.onReady().then(() => this.updateViewletSwitcher()); } - private createActivityActionBar(container: HTMLElement): void { - const activityRegistry = Registry.as(ActivityExtensions.Activities); + private createGlobalActivityActionBar(container: HTMLElement): void { + const activityRegistry = Registry.as(ActivityExtensions); const descriptors = activityRegistry.getActivities(); const actions = descriptors .map(d => this.instantiationService.createInstance(d)) diff --git a/src/vs/workbench/browser/parts/activitybar/media/activitybarpart.css b/src/vs/workbench/browser/parts/activitybar/media/activitybarpart.css index 7acd81393fb..50061325e7e 100644 --- a/src/vs/workbench/browser/parts/activitybar/media/activitybarpart.css +++ b/src/vs/workbench/browser/parts/activitybar/media/activitybarpart.css @@ -9,6 +9,9 @@ .monaco-workbench > .activitybar > .content { height: 100%; + display: flex; + flex-direction: column; + justify-content: space-between; } .monaco-workbench > .activitybar > .content .monaco-action-bar { diff --git a/src/vs/workbench/parts/update/electron-browser/media/update.contribution.css b/src/vs/workbench/parts/update/electron-browser/media/update.contribution.css new file mode 100644 index 00000000000..a12923fce44 --- /dev/null +++ b/src/vs/workbench/parts/update/electron-browser/media/update.contribution.css @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +.update-activity { + -webkit-mask: url('update.svg') no-repeat 50% 50%; + -webkit-mask-size: 22px; +} \ No newline at end of file diff --git a/src/vs/workbench/parts/update/electron-browser/media/update.svg b/src/vs/workbench/parts/update/electron-browser/media/update.svg new file mode 100644 index 00000000000..637b2ad42de --- /dev/null +++ b/src/vs/workbench/parts/update/electron-browser/media/update.svg @@ -0,0 +1,3 @@ + + + diff --git a/src/vs/workbench/parts/update/electron-browser/update.contribution.ts b/src/vs/workbench/parts/update/electron-browser/update.contribution.ts index 52f121006f5..225857d34e2 100644 --- a/src/vs/workbench/parts/update/electron-browser/update.contribution.ts +++ b/src/vs/workbench/parts/update/electron-browser/update.contribution.ts @@ -6,12 +6,14 @@ 'use strict'; import * as nls from 'vs/nls'; +import 'vs/css!./media/update.contribution'; import { Registry } from 'vs/platform/platform'; import { IWorkbenchContributionsRegistry, Extensions as WorkbenchExtensions } from 'vs/workbench/common/contributions'; import { ShowCurrentReleaseNotesAction, UpdateContribution } from 'vs/workbench/parts/update/electron-browser/update'; import { ReleaseNotesEditor } from 'vs/workbench/parts/update/electron-browser/releaseNotesEditor'; import { ReleaseNotesInput } from 'vs/workbench/parts/update/electron-browser/releaseNotesInput'; import { EditorDescriptor } from 'vs/workbench/browser/parts/editor/baseEditor'; +import { IActivityRegistry, ActivityExtensions, IActivity } from 'vs/workbench/browser/activity'; import { IEditorRegistry, Extensions as EditorExtensions } from 'vs/workbench/common/editor'; import { SyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/workbench/common/actionRegistry'; @@ -52,3 +54,12 @@ configurationRegistry.registerConfiguration({ } } }); + +class UpdateGlobalActivity implements IActivity { + id: string = 'update.activity'; + name: string = 'Update'; + cssClass: string = 'update-activity'; +} + +Registry.as(ActivityExtensions) + .registerActivity(UpdateGlobalActivity); -- GitLab From fb968f36edaa2f43c6eb513fad1c7974a3c13834 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Tue, 23 May 2017 16:15:23 +0200 Subject: [PATCH 0022/1347] wip: update contribution 2 --- src/vs/workbench/browser/activity.ts | 25 ++++--- .../parts/activitybar/activitybarActions.ts | 30 +++++---- .../parts/activitybar/activitybarPart.ts | 65 ++++++++++++++----- .../activitybar/media/activityaction.css | 10 +++ .../electron-browser/update.contribution.ts | 24 +++---- .../parts/update/electron-browser/update.ts | 60 ++++++++++++++++- .../activity/common/activityBarService.ts | 7 ++ 7 files changed, 169 insertions(+), 52 deletions(-) diff --git a/src/vs/workbench/browser/activity.ts b/src/vs/workbench/browser/activity.ts index 72bcee88c94..5f23bef3a5e 100644 --- a/src/vs/workbench/browser/activity.ts +++ b/src/vs/workbench/browser/activity.ts @@ -4,6 +4,7 @@ *--------------------------------------------------------------------------------------------*/ import { Registry } from 'vs/platform/platform'; +import { IAction } from 'vs/base/common/actions'; import { IConstructorSignature0 } from 'vs/platform/instantiation/common/instantiation'; export interface IActivity { @@ -12,26 +13,30 @@ export interface IActivity { cssClass: string; } -export const ActivityExtensions = 'workbench.contributions.activities'; +export interface IGlobalActivity extends IActivity { + getActions(): IAction[]; +} + +export const GlobalActivityExtensions = 'workbench.contributions.globalActivities'; -export interface IActivityRegistry { - registerActivity(descriptor: IConstructorSignature0): void; - getActivities(): IConstructorSignature0[]; +export interface IGlobalActivityRegistry { + registerActivity(descriptor: IConstructorSignature0): void; + getActivities(): IConstructorSignature0[]; } -export class ActivityRegistry implements IActivityRegistry { +export class GlobalActivityRegistry implements IGlobalActivityRegistry { - private activityDescriptors = new Set>(); + private activityDescriptors = new Set>(); - registerActivity(descriptor: IConstructorSignature0): void { + registerActivity(descriptor: IConstructorSignature0): void { this.activityDescriptors.add(descriptor); } - getActivities(): IConstructorSignature0[] { - const result: IConstructorSignature0[] = []; + getActivities(): IConstructorSignature0[] { + const result: IConstructorSignature0[] = []; this.activityDescriptors.forEach(d => result.push(d)); return result; } } -Registry.add(ActivityExtensions, new ActivityRegistry()); \ No newline at end of file +Registry.add(GlobalActivityExtensions, new GlobalActivityRegistry()); \ No newline at end of file diff --git a/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts b/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts index b599f0fed2e..7711afeab12 100644 --- a/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts +++ b/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts @@ -13,7 +13,7 @@ import { Builder, $ } from 'vs/base/browser/builder'; import { DelayedDragHandler } from 'vs/base/browser/dnd'; import { Action } from 'vs/base/common/actions'; import { BaseActionItem, Separator, IBaseActionItemOptions } from 'vs/base/browser/ui/actionbar/actionbar'; -import { IActivityBarService, ProgressBadge, TextBadge, NumberBadge, IconBadge, IBadge } from 'vs/workbench/services/activity/common/activityBarService'; +import { IActivityBarService, DotBadge, ProgressBadge, TextBadge, NumberBadge, IconBadge, IBadge } from 'vs/workbench/services/activity/common/activityBarService'; import Event, { Emitter } from 'vs/base/common/event'; import { IContextMenuService } from 'vs/platform/contextview/browser/contextView'; import { ICommandService } from 'vs/platform/commands/common/commands'; @@ -125,6 +125,7 @@ export class ActivityActionItem extends BaseActionItem { super(null, action, options); this.themeService.onThemeChange(this.onThemeChange, this, this._callOnDispose); + action.onDidChangeBadge(this.handleBadgeChangeEvenet, this, this._callOnDispose); } protected updateStyles(): void { @@ -155,13 +156,15 @@ export class ActivityActionItem extends BaseActionItem { public render(container: HTMLElement): void { super.render(container); + container.title = this.activity.name; + // Label this.$label = $('a.action-label').appendTo(this.builder); if (this.activity.cssClass) { this.$label.addClass(this.activity.cssClass); } - this.$badge = this.builder.div({ 'class': 'badge' }, (badge: Builder) => { + this.$badge = this.builder.clone().div({ 'class': 'badge' }, (badge: Builder) => { this.$badgeContent = badge.div({ 'class': 'badge-content' }); }); @@ -203,6 +206,13 @@ export class ActivityActionItem extends BaseActionItem { this.$badge.show(); } + // Dot + else if (badge instanceof DotBadge) { + this.$badge.addClass('dot-badge'); + this.$badge.title(badge.getDescription()); + this.$badge.show(); + } + // Progress else if (badge instanceof ProgressBadge) { this.$badge.show(); @@ -212,6 +222,13 @@ export class ActivityActionItem extends BaseActionItem { } } + private handleBadgeChangeEvenet(): void { + const action = this.getAction(); + if (action instanceof ActivityAction) { + this.updateBadge(action.getBadge()); + } + } + public dispose(): void { super.dispose(); this.$badge.destroy(); @@ -253,8 +270,6 @@ export class ViewletActionItem extends ActivityActionItem { if (!ViewletActionItem.toggleViewletPinnedAction) { ViewletActionItem.toggleViewletPinnedAction = instantiationService.createInstance(ToggleViewletPinnedAction, void 0); } - - action.onDidChangeBadge(this.handleBadgeChangeEvenet, this, this._callOnDispose); } private getKeybindingLabel(id: string): string { @@ -444,13 +459,6 @@ export class ViewletActionItem extends ActivityActionItem { } } - private handleBadgeChangeEvenet(): void { - const action = this.getAction(); - if (action instanceof ActivityAction) { - this.updateBadge(action.getBadge()); - } - } - protected _updateEnabled(): void { if (this.getAction().enabled) { this.builder.removeClass('disabled'); diff --git a/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts b/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts index d548ebd34d3..65d97eb7484 100644 --- a/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts +++ b/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts @@ -13,9 +13,9 @@ import * as arrays from 'vs/base/common/arrays'; import { illegalArgument } from 'vs/base/common/errors'; import { Builder, $, Dimension } from 'vs/base/browser/builder'; import { Action } from 'vs/base/common/actions'; -import { ActionsOrientation, ActionBar, IActionItem, Separator } from 'vs/base/browser/ui/actionbar/actionbar'; +import { ActionsOrientation, ActionBar, IActionItem, Separator, IBaseActionItemOptions } from 'vs/base/browser/ui/actionbar/actionbar'; import { ViewletDescriptor } from 'vs/workbench/browser/viewlet'; -import { IActivity, ActivityExtensions, IActivityRegistry } from 'vs/workbench/browser/activity'; +import { IGlobalActivity, GlobalActivityExtensions, IGlobalActivityRegistry } from 'vs/workbench/browser/activity'; import { Registry } from 'vs/platform/platform'; import { Part } from 'vs/workbench/browser/part'; import { IViewlet } from 'vs/workbench/common/viewlet'; @@ -29,7 +29,7 @@ import { IStorageService } from 'vs/platform/storage/common/storage'; import { Scope as MementoScope } from 'vs/workbench/common/memento'; import { IContextMenuService } from 'vs/platform/contextview/browser/contextView'; import { StandardMouseEvent } from 'vs/base/browser/mouseEvent'; -import { dispose, IDisposable } from 'vs/base/common/lifecycle'; +import { dispose, IDisposable, toDisposable } from 'vs/base/common/lifecycle'; import { ToggleActivityBarVisibilityAction } from 'vs/workbench/browser/actions/toggleActivityBarVisibility'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { ACTIVITY_BAR_BACKGROUND, ACTIVITY_BAR_BORDER } from 'vs/workbench/common/theme'; @@ -42,17 +42,36 @@ interface IViewletActivity { class GlobalActivityAction extends ActivityAction { - constructor(activity: IActivity) { + constructor(activity: IGlobalActivity) { super(activity); } } class GlobalActivityActionItem extends ActivityActionItem { - onClick(event: Event): void { - DOM.EventHelper.stop(event, true); - console.log('hello world'); - // fire up native menu around this.builder.getHTMLElement() + constructor( + action: GlobalActivityAction, + options: IBaseActionItemOptions, + @IThemeService themeService: IThemeService, + @IContextMenuService protected contextMenuService: IContextMenuService + ) { + super(action, options, themeService); + } + + onClick(e: MouseEvent): void { + const globalAction = this._action as GlobalActivityAction; + const activity = globalAction.activity as IGlobalActivity; + const actions = activity.getActions(); + + const event = new StandardMouseEvent(e); + event.stopPropagation(); + event.preventDefault(); + + this.contextMenuService.showContextMenu({ + getAnchor: () => ({ x: event.posx, y: event.posy }), + getActions: () => TPromise.as(actions), + onHide: () => dispose(actions) + }); } } @@ -70,6 +89,7 @@ export class ActivitybarPart extends Part implements IActivityBarService { private viewletOverflowAction: ViewletOverflowActivityAction; private viewletOverflowActionItem: ViewletOverflowActivityActionItem; + private globalActivityIdToActions: { [globalActivityId: string]: GlobalActivityAction; }; private viewletIdToActions: { [viewletId: string]: ActivityAction; }; private viewletIdToActionItems: { [viewletId: string]: IActionItem; }; private viewletIdToActivityStack: { [viewletId: string]: IViewletActivity[]; }; @@ -90,6 +110,7 @@ export class ActivitybarPart extends Part implements IActivityBarService { ) { super(id, { hasTitle: false }, themeService); + this.globalActivityIdToActions = Object.create(null); this.viewletIdToActionItems = Object.create(null); this.viewletIdToActions = Object.create(null); this.viewletIdToActivityStack = Object.create(null); @@ -142,6 +163,21 @@ export class ActivitybarPart extends Part implements IActivityBarService { } } + public showGlobalActivity(globalActivityId: string, badge: IBadge): IDisposable { + if (!badge) { + throw illegalArgument('badge'); + } + + const action = this.globalActivityIdToActions[globalActivityId]; + + if (!action) { + throw illegalArgument('globalActivityId'); + } + + action.setBadge(badge); + return toDisposable(() => action.setBadge(undefined)); + } + public showActivity(viewletId: string, badge: IBadge, clazz?: string): IDisposable { if (!badge) { throw illegalArgument('badge'); @@ -275,7 +311,7 @@ export class ActivitybarPart extends Part implements IActivityBarService { } private createGlobalActivityActionBar(container: HTMLElement): void { - const activityRegistry = Registry.as(ActivityExtensions); + const activityRegistry = Registry.as(GlobalActivityExtensions); const descriptors = activityRegistry.getActivities(); const actions = descriptors .map(d => this.instantiationService.createInstance(d)) @@ -288,13 +324,10 @@ export class ActivitybarPart extends Part implements IActivityBarService { animated: false }); - actions.forEach(a => this.activityActionBar.push(a)); - - this.updateGlobalSwitcher(); - } - - private updateGlobalSwitcher(): void { - + actions.forEach(a => { + this.globalActivityIdToActions[a.id] = a; + this.activityActionBar.push(a); + }); } private updateViewletSwitcher() { diff --git a/src/vs/workbench/browser/parts/activitybar/media/activityaction.css b/src/vs/workbench/browser/parts/activitybar/media/activityaction.css index f9bb260bdbe..2cc5e0c94bc 100644 --- a/src/vs/workbench/browser/parts/activitybar/media/activityaction.css +++ b/src/vs/workbench/browser/parts/activitybar/media/activityaction.css @@ -67,6 +67,16 @@ text-align: center; } +.monaco-workbench > .activitybar > .content .monaco-action-bar .badge.dot-badge .badge-content { + box-sizing: border-box; + content: ''; + top: 9px; + width: 11px; + height: 11px; + min-width: inherit; + padding: 0; +} + /* Right aligned */ .monaco-workbench > .activitybar.right > .content .monaco-action-bar .action-label { diff --git a/src/vs/workbench/parts/update/electron-browser/update.contribution.ts b/src/vs/workbench/parts/update/electron-browser/update.contribution.ts index 225857d34e2..453af2e270b 100644 --- a/src/vs/workbench/parts/update/electron-browser/update.contribution.ts +++ b/src/vs/workbench/parts/update/electron-browser/update.contribution.ts @@ -8,17 +8,18 @@ import * as nls from 'vs/nls'; import 'vs/css!./media/update.contribution'; import { Registry } from 'vs/platform/platform'; +import { isMacintosh } from 'vs/base/common/platform'; import { IWorkbenchContributionsRegistry, Extensions as WorkbenchExtensions } from 'vs/workbench/common/contributions'; -import { ShowCurrentReleaseNotesAction, UpdateContribution } from 'vs/workbench/parts/update/electron-browser/update'; import { ReleaseNotesEditor } from 'vs/workbench/parts/update/electron-browser/releaseNotesEditor'; import { ReleaseNotesInput } from 'vs/workbench/parts/update/electron-browser/releaseNotesInput'; import { EditorDescriptor } from 'vs/workbench/browser/parts/editor/baseEditor'; -import { IActivityRegistry, ActivityExtensions, IActivity } from 'vs/workbench/browser/activity'; +import { IGlobalActivityRegistry, GlobalActivityExtensions } from 'vs/workbench/browser/activity'; import { IEditorRegistry, Extensions as EditorExtensions } from 'vs/workbench/common/editor'; import { SyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/workbench/common/actionRegistry'; import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; import { IConfigurationRegistry, Extensions as ConfigurationExtensions } from 'vs/platform/configuration/common/configurationRegistry'; +import { ShowCurrentReleaseNotesAction, UpdateContribution, UpdateContribution2 } from './update'; Registry.as(WorkbenchExtensions.Workbench) .registerWorkbenchContribution(UpdateContribution); @@ -34,9 +35,13 @@ const editorDescriptor = new EditorDescriptor( Registry.as(EditorExtensions.Editors) .registerEditor(editorDescriptor, [new SyncDescriptor(ReleaseNotesInput)]); -Registry.as(ActionExtensions.WorkbenchActions) - .registerWorkbenchAction(new SyncActionDescriptor(ShowCurrentReleaseNotesAction, ShowCurrentReleaseNotesAction.ID, ShowCurrentReleaseNotesAction.LABEL), 'Open Release Notes'); - +if (isMacintosh) { + Registry.as(GlobalActivityExtensions) + .registerActivity(UpdateContribution2); +} else { + Registry.as(ActionExtensions.WorkbenchActions) + .registerWorkbenchAction(new SyncActionDescriptor(ShowCurrentReleaseNotesAction, ShowCurrentReleaseNotesAction.ID, ShowCurrentReleaseNotesAction.LABEL), 'Open Release Notes'); +} // Configuration: Update const configurationRegistry = Registry.as(ConfigurationExtensions.Configuration); @@ -54,12 +59,3 @@ configurationRegistry.registerConfiguration({ } } }); - -class UpdateGlobalActivity implements IActivity { - id: string = 'update.activity'; - name: string = 'Update'; - cssClass: string = 'update-activity'; -} - -Registry.as(ActivityExtensions) - .registerActivity(UpdateGlobalActivity); diff --git a/src/vs/workbench/parts/update/electron-browser/update.ts b/src/vs/workbench/parts/update/electron-browser/update.ts index 644f7bd40df..9077a3822d2 100644 --- a/src/vs/workbench/parts/update/electron-browser/update.ts +++ b/src/vs/workbench/parts/update/electron-browser/update.ts @@ -8,14 +8,16 @@ import nls = require('vs/nls'); import severity from 'vs/base/common/severity'; import { TPromise } from 'vs/base/common/winjs.base'; -import { Action } from 'vs/base/common/actions'; +import { IAction, Action } from 'vs/base/common/actions'; import { IMessageService, CloseAction, Severity } from 'vs/platform/message/common/message'; import pkg from 'vs/platform/node/package'; import product from 'vs/platform/node/product'; import URI from 'vs/base/common/uri'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; +import { IActivityBarService, DotBadge } from 'vs/workbench/services/activity/common/activityBarService'; import { IInstantiationService, ServicesAccessor } from 'vs/platform/instantiation/common/instantiation'; import { ReleaseNotesInput } from 'vs/workbench/parts/update/electron-browser/releaseNotesInput'; +import { IGlobalActivity } from 'vs/workbench/browser/activity'; import { IRequestService } from 'vs/platform/request/node/request'; import { asText } from 'vs/base/node/request'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; @@ -262,4 +264,60 @@ export class UpdateContribution implements IWorkbenchContribution { updateService.onError(err => messageService.show(severity.Error, err)); } +} + +export class UpdateContribution2 implements IGlobalActivity { + + get id() { return 'vs.update'; } + get name() { return 'VS Code'; } + get cssClass() { return 'update-activity'; } + + constructor( + @IStorageService storageService: IStorageService, + @IInstantiationService instantiationService: IInstantiationService, + @IMessageService messageService: IMessageService, + @IUpdateService updateService: IUpdateService, + @IWorkbenchEditorService editorService: IWorkbenchEditorService, + @IActivityBarService activityBarService: IActivityBarService + ) { + // updateService.onUpdateReady(update => { + // const applyUpdateAction = instantiationService.createInstance(ApplyUpdateAction); + // const releaseNotesAction = instantiationService.createInstance(ShowReleaseNotesAction, false, update.version); + + // messageService.show(severity.Info, { + // message: nls.localize('updateAvailable', "{0} will be updated after it restarts.", product.nameLong), + // actions: [applyUpdateAction, NotNowAction, releaseNotesAction] + // }); + // }); + + // updateService.onUpdateAvailable(update => { + setTimeout(() => { + const badge = new DotBadge(() => 'UPDATE AVAILABLE'); + activityBarService.showGlobalActivity(this.id, badge); + }, 0); + // }); + + // updateService.onUpdateNotAvailable(explicit => { + // if (!explicit) { + // return; + // } + + // messageService.show(severity.Info, nls.localize('noUpdatesAvailable', "There are no updates currently available.")); + // }); + + updateService.onError(err => messageService.show(severity.Error, err)); + } + + getActions(): IAction[] { + return [ + new Action('foo', 'FOO'), + new Action('bar', 'BAR'), + new Action('foo', 'FOO'), + new Action('bar', 'BAR'), + new Action('foo', 'FOO'), + new Action('bar', 'BAR'), + new Action('foo', 'FOO'), + new Action('bar', 'BAR') + ]; + } } \ No newline at end of file diff --git a/src/vs/workbench/services/activity/common/activityBarService.ts b/src/vs/workbench/services/activity/common/activityBarService.ts index 810b062b63f..a07ea58e26a 100644 --- a/src/vs/workbench/services/activity/common/activityBarService.ts +++ b/src/vs/workbench/services/activity/common/activityBarService.ts @@ -24,6 +24,8 @@ export class BaseBadge implements IBadge { } } +export class DotBadge extends BaseBadge { } + export class NumberBadge extends BaseBadge { public number: number; @@ -63,6 +65,11 @@ export const IActivityBarService = createDecorator('activit export interface IActivityBarService { _serviceBrand: any; + /** + * Show activity in the activitybar for the given global activity. + */ + showGlobalActivity(globalActivityId: string, badge: IBadge): IDisposable; + /** * Show activity in the activitybar for the given viewlet. */ -- GitLab From 145255c1d4a657bf3af29fc73c82e5869d4e1d3f Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Tue, 23 May 2017 17:13:02 +0200 Subject: [PATCH 0023/1347] LightUpdateContribution --- .../electron-browser/update.contribution.ts | 21 +++-- .../parts/update/electron-browser/update.ts | 91 ++++++++++--------- 2 files changed, 58 insertions(+), 54 deletions(-) diff --git a/src/vs/workbench/parts/update/electron-browser/update.contribution.ts b/src/vs/workbench/parts/update/electron-browser/update.contribution.ts index 453af2e270b..39c771ee7c9 100644 --- a/src/vs/workbench/parts/update/electron-browser/update.contribution.ts +++ b/src/vs/workbench/parts/update/electron-browser/update.contribution.ts @@ -19,10 +19,18 @@ import { SyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/workbench/common/actionRegistry'; import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; import { IConfigurationRegistry, Extensions as ConfigurationExtensions } from 'vs/platform/configuration/common/configurationRegistry'; -import { ShowCurrentReleaseNotesAction, UpdateContribution, UpdateContribution2 } from './update'; +import { ShowCurrentReleaseNotesAction, ProductContribution, UpdateContribution, LightUpdateContribution } from './update'; Registry.as(WorkbenchExtensions.Workbench) - .registerWorkbenchContribution(UpdateContribution); + .registerWorkbenchContribution(ProductContribution); + +if (isMacintosh) { + Registry.as(GlobalActivityExtensions) + .registerActivity(LightUpdateContribution); +} else { + Registry.as(WorkbenchExtensions.Workbench) + .registerWorkbenchContribution(UpdateContribution); +} // Editor const editorDescriptor = new EditorDescriptor( @@ -35,13 +43,8 @@ const editorDescriptor = new EditorDescriptor( Registry.as(EditorExtensions.Editors) .registerEditor(editorDescriptor, [new SyncDescriptor(ReleaseNotesInput)]); -if (isMacintosh) { - Registry.as(GlobalActivityExtensions) - .registerActivity(UpdateContribution2); -} else { - Registry.as(ActionExtensions.WorkbenchActions) - .registerWorkbenchAction(new SyncActionDescriptor(ShowCurrentReleaseNotesAction, ShowCurrentReleaseNotesAction.ID, ShowCurrentReleaseNotesAction.LABEL), 'Open Release Notes'); -} +Registry.as(ActionExtensions.WorkbenchActions) + .registerWorkbenchAction(new SyncActionDescriptor(ShowCurrentReleaseNotesAction, ShowCurrentReleaseNotesAction.ID, ShowCurrentReleaseNotesAction.LABEL), 'Open Release Notes'); // Configuration: Update const configurationRegistry = Registry.as(ConfigurationExtensions.Configuration); diff --git a/src/vs/workbench/parts/update/electron-browser/update.ts b/src/vs/workbench/parts/update/electron-browser/update.ts index 9077a3822d2..ff79f211a37 100644 --- a/src/vs/workbench/parts/update/electron-browser/update.ts +++ b/src/vs/workbench/parts/update/electron-browser/update.ts @@ -23,9 +23,10 @@ import { asText } from 'vs/base/node/request'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { KeybindingIO } from 'vs/workbench/services/keybinding/common/keybindingIO'; import { IOpenerService } from 'vs/platform/opener/common/opener'; +import { ICommandService } from 'vs/platform/commands/common/commands'; import { IWorkbenchContribution } from 'vs/workbench/common/contributions'; import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage'; -import { IUpdateService } from 'vs/platform/update/common/update'; +import { IUpdateService, State as UpdateState } from 'vs/platform/update/common/update'; import * as semver from 'semver'; import { OS } from 'vs/base/common/platform'; @@ -191,24 +192,22 @@ const LinkAction = (id: string, message: string, licenseUrl: string) => new Acti () => { window.open(licenseUrl); return TPromise.as(null); } ); -export class UpdateContribution implements IWorkbenchContribution { +export class ProductContribution implements IWorkbenchContribution { private static KEY = 'releaseNotes/lastVersion'; - getId() { return 'vs.update'; } + getId() { return 'vs.product'; } constructor( @IStorageService storageService: IStorageService, @IInstantiationService instantiationService: IInstantiationService, @IMessageService messageService: IMessageService, - @IUpdateService updateService: IUpdateService, @IWorkbenchEditorService editorService: IWorkbenchEditorService ) { - const lastVersion = storageService.get(UpdateContribution.KEY, StorageScope.GLOBAL, ''); + const lastVersion = storageService.get(ProductContribution.KEY, StorageScope.GLOBAL, ''); - // was there an update? + // was there an update? if so, open release notes if (product.releaseNotesUrl && lastVersion && pkg.version !== lastVersion) { - instantiationService.invokeFunction(loadReleaseNotes, pkg.version) - .then( + instantiationService.invokeFunction(loadReleaseNotes, pkg.version).then( text => editorService.openEditor(instantiationService.createInstance(ReleaseNotesInput, pkg.version, text), { pinned: true }), () => { messageService.show(Severity.Info, { @@ -232,8 +231,19 @@ export class UpdateContribution implements IWorkbenchContribution { }); } - storageService.store(UpdateContribution.KEY, pkg.version, StorageScope.GLOBAL); + storageService.store(ProductContribution.KEY, pkg.version, StorageScope.GLOBAL); + } +} + +export class UpdateContribution implements IWorkbenchContribution { + getId() { return 'vs.update'; } + + constructor( + @IInstantiationService instantiationService: IInstantiationService, + @IMessageService messageService: IMessageService, + @IUpdateService updateService: IUpdateService + ) { updateService.onUpdateReady(update => { const applyUpdateAction = instantiationService.createInstance(ApplyUpdateAction); const releaseNotesAction = instantiationService.createInstance(ShowReleaseNotesAction, false, update.version); @@ -266,7 +276,7 @@ export class UpdateContribution implements IWorkbenchContribution { } } -export class UpdateContribution2 implements IGlobalActivity { +export class LightUpdateContribution implements IGlobalActivity { get id() { return 'vs.update'; } get name() { return 'VS Code'; } @@ -274,50 +284,41 @@ export class UpdateContribution2 implements IGlobalActivity { constructor( @IStorageService storageService: IStorageService, + @ICommandService private commandService: ICommandService, @IInstantiationService instantiationService: IInstantiationService, @IMessageService messageService: IMessageService, - @IUpdateService updateService: IUpdateService, + @IUpdateService private updateService: IUpdateService, @IWorkbenchEditorService editorService: IWorkbenchEditorService, @IActivityBarService activityBarService: IActivityBarService ) { - // updateService.onUpdateReady(update => { - // const applyUpdateAction = instantiationService.createInstance(ApplyUpdateAction); - // const releaseNotesAction = instantiationService.createInstance(ShowReleaseNotesAction, false, update.version); - - // messageService.show(severity.Info, { - // message: nls.localize('updateAvailable', "{0} will be updated after it restarts.", product.nameLong), - // actions: [applyUpdateAction, NotNowAction, releaseNotesAction] - // }); - // }); - - // updateService.onUpdateAvailable(update => { - setTimeout(() => { - const badge = new DotBadge(() => 'UPDATE AVAILABLE'); + this.updateService.onUpdateReady(() => { + const badge = new DotBadge(() => nls.localize('updateIsReady', "New update available.")); activityBarService.showGlobalActivity(this.id, badge); - }, 0); - // }); - - // updateService.onUpdateNotAvailable(explicit => { - // if (!explicit) { - // return; - // } - - // messageService.show(severity.Info, nls.localize('noUpdatesAvailable', "There are no updates currently available.")); - // }); + }); - updateService.onError(err => messageService.show(severity.Error, err)); + this.updateService.onError(err => messageService.show(severity.Error, err)); } getActions(): IAction[] { - return [ - new Action('foo', 'FOO'), - new Action('bar', 'BAR'), - new Action('foo', 'FOO'), - new Action('bar', 'BAR'), - new Action('foo', 'FOO'), - new Action('bar', 'BAR'), - new Action('foo', 'FOO'), - new Action('bar', 'BAR') - ]; + switch (this.updateService.state) { + case UpdateState.Uninitialized: + return [new Action('update.notavailable', nls.localize('not available', "Updates Not Available"), undefined, false)]; + + case UpdateState.CheckingForUpdate: + return [new Action('update.checking', nls.localize('checkingForUpdates', "Checking For Updates..."), undefined, false)]; + + case UpdateState.UpdateAvailable: + return [new Action('update.installing', nls.localize('installingUpdate', "Installing Update..."), undefined, false)]; + + case UpdateState.UpdateDownloaded: + return [new Action('update.restart', nls.localize('restartToUpdate', "Restart To Update..."), undefined, true, () => + this.updateService.quitAndInstall() + )]; + + default: + return [new Action('update.check', nls.localize('checkForUpdates', "Check For Updates..."), undefined, this.updateService.state === UpdateState.Idle, () => + this.updateService.checkForUpdates(true) + )]; + } } } \ No newline at end of file -- GitLab From 3ea2c216aa42cffa2549301eff73b52f760d9315 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Wed, 24 May 2017 12:29:51 +0200 Subject: [PATCH 0024/1347] More work to make v2 the default --- src/vs/workbench/api/node/extHostTask.ts | 23 ++- .../parts/tasks/browser/quickOpen.ts | 61 +++++++- .../parts/tasks/browser/restartQuickOpen.ts | 2 +- .../parts/tasks/browser/taskQuickOpen.ts | 2 +- .../parts/tasks/browser/terminateQuickOpen.ts | 2 +- .../parts/tasks/common/taskConfiguration.ts | 144 +++++++++++++----- .../parts/tasks/common/taskTemplates.ts | 9 +- src/vs/workbench/parts/tasks/common/tasks.ts | 77 ++++++---- .../electron-browser/task.contribution.ts | 59 +++---- .../electron-browser/terminalTaskSystem.ts | 16 +- .../parts/tasks/node/processTaskSystem.ts | 11 +- .../tasks/test/node/configuration.test.ts | 82 ++++++---- 12 files changed, 332 insertions(+), 156 deletions(-) diff --git a/src/vs/workbench/api/node/extHostTask.ts b/src/vs/workbench/api/node/extHostTask.ts index f1c5a8065b8..5f23efc8f80 100644 --- a/src/vs/workbench/api/node/extHostTask.ts +++ b/src/vs/workbench/api/node/extHostTask.ts @@ -192,26 +192,26 @@ namespace ProblemMatcher { } namespace RevealKind { - export function from(value: vscode.RevealKind): TaskSystem.ShowOutput { + export function from(value: vscode.RevealKind): TaskSystem.RevealKind { if (value === void 0 || value === null) { - return TaskSystem.ShowOutput.Always; + return TaskSystem.RevealKind.Always; } switch (value) { case types.RevealKind.Silent: - return TaskSystem.ShowOutput.Silent; + return TaskSystem.RevealKind.Silent; case types.RevealKind.Never: - return TaskSystem.ShowOutput.Never; + return TaskSystem.RevealKind.Never; } - return TaskSystem.ShowOutput.Always; + return TaskSystem.RevealKind.Always; } } namespace TerminalBehaviour { - export function from(value: vscode.TerminalBehaviour): { showOutput: TaskSystem.ShowOutput, echo: boolean } { + export function from(value: vscode.TerminalBehaviour): TaskSystem.TerminalBehavior { if (value === void 0 || value === null) { - return { showOutput: TaskSystem.ShowOutput.Always, echo: false }; + return { reveal: TaskSystem.RevealKind.Always, echo: false }; } - return { showOutput: RevealKind.from(value.reveal), echo: !!value.echo }; + return { reveal: RevealKind.from(value.reveal), echo: !!value.echo }; } } @@ -302,8 +302,6 @@ namespace Tasks { if (command === void 0) { return undefined; } - let behaviour = TerminalBehaviour.from(task.terminal); - command.echo = behaviour.echo; let result: TaskSystem.Task = { _id: uuidMap.getUUID(task.identifier), _source: { kind: TaskSystem.TaskSourceKind.Extension, detail: extension.id }, @@ -311,7 +309,6 @@ namespace Tasks { identifier: task.identifier, group: types.TaskGroup.is(task.group) ? task.group : undefined, command: command, - showOutput: behaviour.showOutput, isBackground: !!task.isBackground, suppressTaskName: true, problemMatchers: ProblemMatcher.from(task.problemMatchers) @@ -327,7 +324,7 @@ namespace Tasks { name: value.process, args: Strings.from(value.args), isShellCommand: false, - echo: false, + terminal: TerminalBehaviour.from(value.terminal) }; if (value.options) { result.options = CommandOptions.from(value.options); @@ -342,7 +339,7 @@ namespace Tasks { let result: TaskSystem.CommandConfiguration = { name: value.commandLine, isShellCommand: ShellConfiguration.from(value.options), - echo: false + terminal: TerminalBehaviour.from(value.terminal) }; if (value.options) { result.options = CommandOptions.from(value.options); diff --git a/src/vs/workbench/parts/tasks/browser/quickOpen.ts b/src/vs/workbench/parts/tasks/browser/quickOpen.ts index 743413653aa..754d5756a22 100644 --- a/src/vs/workbench/parts/tasks/browser/quickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/quickOpen.ts @@ -7,6 +7,7 @@ import nls = require('vs/nls'); import Filters = require('vs/base/common/filters'); import { TPromise } from 'vs/base/common/winjs.base'; +import { Action, IAction } from 'vs/base/common/actions'; import Quickopen = require('vs/workbench/browser/quickopen'); import QuickOpen = require('vs/base/parts/quickopen/common/quickOpen'); import Model = require('vs/base/parts/quickopen/browser/quickOpenModel'); @@ -14,21 +15,26 @@ import { IQuickOpenService } from 'vs/platform/quickOpen/common/quickOpen'; import { Task, TaskSourceKind } from 'vs/workbench/parts/tasks/common/tasks'; import { ITaskService } from 'vs/workbench/parts/tasks/common/taskService'; +import { ActionBarContributor } from 'vs/workbench/browser/actionBarRegistry'; export class TaskEntry extends Model.QuickOpenEntry { - constructor(protected taskService: ITaskService, protected task: Task, highlights: Model.IHighlight[] = []) { + constructor(protected taskService: ITaskService, protected _task: Task, highlights: Model.IHighlight[] = []) { super(highlights); - this.task = task; + this._task = _task; } public getLabel(): string { - return this.task.name; + return this._task.name; } public getAriaLabel(): string { return nls.localize('entryAriaLabel', "{0}, tasks", this.getLabel()); } + + public get task(): Task { + return this._task; + } } export class TaskGroupEntry extends Model.QuickOpenEntryGroup { @@ -112,4 +118,53 @@ export abstract class QuickOpenHandler extends Quickopen.QuickOpenHandler { autoFocusFirstEntry: !!input }; } +} + +class CustomizeTaskAction extends Action { + + private static ID = 'workbench.action.tasks.customizeTask'; + private static LABEL = nls.localize('customizeTask', "Customize Task"); + + constructor() { + super(CustomizeTaskAction.ID, CustomizeTaskAction.LABEL); + this.updateClass(); + } + + public updateClass(): void { + this.class = 'quick-open-sidebyside-vertical'; + } + + public run(context: any): TPromise { + return TPromise.as(false); + } +} + +export class QuickOpenActionContributor extends ActionBarContributor { + + constructor() { + super(); + } + + public hasActions(context: any): boolean { + const entry = this.getEntry(context); + + return !!entry; + } + + public getActions(context: any): IAction[] { + const actions: Action[] = []; + + const entry = this.getEntry(context); + if (entry && entry.task._source.kind === TaskSourceKind.Extension) { + actions.push(new CustomizeTaskAction()); + } + return actions; + } + + private getEntry(context: any): TaskEntry { + if (!context || !(context.element instanceof TaskEntry)) { + return undefined; + } + return context.element as TaskEntry; + } } \ No newline at end of file diff --git a/src/vs/workbench/parts/tasks/browser/restartQuickOpen.ts b/src/vs/workbench/parts/tasks/browser/restartQuickOpen.ts index 2c78bdac7e8..95d4d2bd5dd 100644 --- a/src/vs/workbench/parts/tasks/browser/restartQuickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/restartQuickOpen.ts @@ -24,7 +24,7 @@ class TaskEntry extends base.TaskEntry { if (mode === QuickOpen.Mode.PREVIEW) { return false; } - this.taskService.restart(this.task._id); + this.taskService.restart(this._task._id); return true; } } diff --git a/src/vs/workbench/parts/tasks/browser/taskQuickOpen.ts b/src/vs/workbench/parts/tasks/browser/taskQuickOpen.ts index f32f5d199f9..b6939d7a77c 100644 --- a/src/vs/workbench/parts/tasks/browser/taskQuickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/taskQuickOpen.ts @@ -26,7 +26,7 @@ class TaskEntry extends base.TaskEntry { if (mode === QuickOpen.Mode.PREVIEW) { return false; } - this.taskService.run(this.task); + this.taskService.run(this._task); return true; } } diff --git a/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.ts b/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.ts index 767e872a446..80fc424f5d0 100644 --- a/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.ts @@ -24,7 +24,7 @@ class TaskEntry extends base.TaskEntry { if (mode === QuickOpen.Mode.PREVIEW) { return false; } - this.taskService.terminate(this.task._id); + this.taskService.terminate(this._task._id); return true; } } diff --git a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts index 87feaedfd38..b06f6c15bf3 100644 --- a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts +++ b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts @@ -189,6 +189,21 @@ export interface BaseTaskRunnerConfiguration { */ echoCommand?: boolean; + /** + * Controls the behavior of the used terminal + */ + terminal?: { + /** + * The terminal should echo the run command. + */ + echo?: boolean; + /** + * Controls whether or not the terminal is reveal if a task + * is executed. + */ + reveal?: string; + }; + /** * If set to false the task name is added as an additional argument to the * command when executed. If set to true the task name is suppressed. If @@ -402,12 +417,19 @@ namespace ShellConfiguration { } namespace CommandConfiguration { + interface TerminalBehavior { + echo?: boolean; + reveal?: string; + } + interface BaseCommandConfiguationShape { command?: string; isShellCommand?: boolean | ShellConfiguration; args?: string[]; options?: ProcessConfig.CommandOptions; echoCommand?: boolean; + showOutput?: string; + terminal?: TerminalBehavior; taskSelector?: string; } @@ -417,6 +439,70 @@ namespace CommandConfiguration { linux?: BaseCommandConfiguationShape; } + export namespace TerminalBehavior { + export function from(this: void, config: BaseCommandConfiguationShape, context: ParseContext): Tasks.TerminalBehavior { + let echo: boolean = undefined; + let reveal: Tasks.RevealKind = undefined; + if (Types.isBoolean(config.echoCommand)) { + echo = config.echoCommand; + } + if (Types.isString(config.showOutput)) { + reveal = Tasks.RevealKind.fromString(config.showOutput); + } + if (config.terminal) { + if (Types.isBoolean(config.terminal.echo)) { + echo = config.terminal.echo; + } + if (Types.isString(config.terminal.reveal)) { + reveal = Tasks.RevealKind.fromString(config.terminal.reveal); + } + } + if (echo === void 0 && reveal === void 0) { + return undefined; + } + return { echo, reveal }; + } + + export function merge(target: Tasks.TerminalBehavior, source: Tasks.TerminalBehavior): Tasks.TerminalBehavior { + if (isEmpty(source)) { + return target; + } + if (isEmpty(target)) { + return source; + } + mergeProperty(target, source, 'echo'); + mergeProperty(target, source, 'reveal'); + return target; + } + + export function fillDefault(value: Tasks.TerminalBehavior): Tasks.TerminalBehavior { + if (value && Object.isFrozen(value)) { + return value; + } + if (value === void 0) { + return { echo: false, reveal: Tasks.RevealKind.Always }; + } + if (value.echo === void 0) { + value.echo = false; + } + if (value.reveal === void 0) { + value.reveal = Tasks.RevealKind.Always; + } + return value; + } + + export function freeze(value: Tasks.TerminalBehavior): void { + if (value === void 0) { + return; + } + Object.freeze(value); + } + + function isEmpty(this: void, value: Tasks.TerminalBehavior): boolean { + return !value || value.echo === void 0 && value.reveal === void 0; + } + } + export function from(this: void, config: CommandConfiguationShape, context: ParseContext): Tasks.CommandConfiguration { let result: Tasks.CommandConfiguration = fromBase(config, context); @@ -439,7 +525,7 @@ namespace CommandConfiguration { let result: Tasks.CommandConfiguration = { name: undefined, isShellCommand: undefined, - echo: undefined + terminal: undefined }; if (Types.isString(config.command)) { result.name = config.command; @@ -464,8 +550,9 @@ namespace CommandConfiguration { if (config.options !== void 0) { result.options = CommandOptions.from(config.options, context); } - if (Types.isBoolean(config.echoCommand)) { - result.echo = config.echoCommand; + let terminal = TerminalBehavior.from(config, context); + if (terminal) { + result.terminal = terminal; } if (Types.isString(config.taskSelector)) { result.taskSelector = config.taskSelector; @@ -474,11 +561,13 @@ namespace CommandConfiguration { } export function isEmpty(value: Tasks.CommandConfiguration): boolean { - return !value || value.name === void 0 && value.isShellCommand === void 0 && value.args === void 0 && CommandOptions.isEmpty(value.options) && value.echo === void 0; + return !value || value.name === void 0 && value.isShellCommand === void 0 && value.args === void 0 && CommandOptions.isEmpty(value.options) && value.terminal === void 0; } - export function onlyEcho(value: Tasks.CommandConfiguration): boolean { - return value && value.echo !== void 0 && value.name === void 0 && value.isShellCommand === void 0 && value.args === void 0 && CommandOptions.isEmpty(value.options); + export function onlyTerminalBehaviour(value: Tasks.CommandConfiguration): boolean { + return value && + value.terminal && (value.terminal.echo !== void 0 || value.terminal.reveal === void 0) && + value.name === void 0 && value.isShellCommand === void 0 && value.args === void 0 && CommandOptions.isEmpty(value.options); } export function merge(target: Tasks.CommandConfiguration, source: Tasks.CommandConfiguration): Tasks.CommandConfiguration { @@ -500,7 +589,7 @@ namespace CommandConfiguration { target.isShellCommand = source.isShellCommand; } - mergeProperty(target, source, 'echo'); + target.terminal = TerminalBehavior.merge(target.terminal, source.terminal); mergeProperty(target, source, 'taskSelector'); if (source.args !== void 0) { if (target.args === void 0) { @@ -520,9 +609,7 @@ namespace CommandConfiguration { if (value.name !== void 0 && value.isShellCommand === void 0) { value.isShellCommand = false; } - if (value.echo === void 0) { - value.echo = false; - } + value.terminal = TerminalBehavior.fillDefault(value.terminal); if (value.args === void 0) { value.args = EMPTY_ARRAY; } @@ -539,6 +626,9 @@ namespace CommandConfiguration { if (value.options) { CommandOptions.freeze(value.options); } + if (value.terminal) { + TerminalBehavior.freeze(value.terminal); + } if (ShellConfiguration.is(value.isShellCommand)) { ShellConfiguration.freeze(value.isShellCommand); } @@ -660,15 +750,16 @@ namespace TaskDescription { let problemMatchers = ProblemMatcherConverter.from(externalTask.problemMatcher, context); let command: Tasks.CommandConfiguration = externalTask.command !== void 0 ? CommandConfiguration.from(externalTask, context) - : externalTask.echoCommand !== void 0 ? { name: undefined, isShellCommand: undefined, echo: !!externalTask.echoCommand } : undefined; + : externalTask.echoCommand !== void 0 + ? { name: undefined, isShellCommand: undefined, terminal: CommandConfiguration.TerminalBehavior.from(externalTask, context) } + : undefined; let identifer = Types.isString(externalTask.identifier) ? externalTask.identifier : taskName; let task: Tasks.Task = { _id: UUID.generateUuid(), _source: source, name: taskName, identifier: identifer, - command, - showOutput: undefined + command }; if (externalTask.command === void 0 && Types.isStringArray(externalTask.args)) { task.args = externalTask.args.slice(); @@ -682,9 +773,6 @@ namespace TaskDescription { if (externalTask.promptOnClose !== void 0) { task.promptOnClose = !!externalTask.promptOnClose; } - if (Types.isString(externalTask.showOutput)) { - task.showOutput = Tasks.ShowOutput.fromString(externalTask.showOutput); - } if (externalTask.command !== void 0) { // if the task has its own command then we suppress the // task name by default. @@ -793,13 +881,13 @@ namespace TaskDescription { if (CommandConfiguration.isEmpty(task.command) && !CommandConfiguration.isEmpty(globals.command) && globals.command.name !== void 0) { task.command = globals.command; } - if (CommandConfiguration.onlyEcho(task.command)) { + if (CommandConfiguration.onlyTerminalBehaviour(task.command)) { // The globals can have a echo set which would override the local echo // Saves the need of a additional fill method. But might be necessary // at some point. - let oldEcho = task.command.echo; + let oldTerminal = Objects.clone(task.command.terminal); CommandConfiguration.merge(task.command, globals.command); - task.command.echo = oldEcho; + task.command.terminal = oldTerminal; } } // promptOnClose is inferred from isBackground if available @@ -809,9 +897,6 @@ namespace TaskDescription { if (task.suppressTaskName === void 0 && globals.suppressTaskName !== void 0) { task.suppressTaskName = globals.suppressTaskName; } - if (task.showOutput === void 0 && globals.showOutput !== void 0) { - task.showOutput = globals.showOutput; - } } export function fillDefaults(task: Tasks.Task): void { @@ -828,9 +913,6 @@ namespace TaskDescription { if (task.isBackground === void 0) { task.isBackground = false; } - if (task.showOutput === void 0) { - task.showOutput = Tasks.ShowOutput.Always; - } if (task.problemMatchers === void 0) { task.problemMatchers = EMPTY_ARRAY; } @@ -876,7 +958,6 @@ namespace TaskDescription { mergeProperty(target, source, 'args'); mergeProperty(target, source, 'isBackground'); mergeProperty(target, source, 'promptOnClose'); - mergeProperty(target, source, 'showOutput'); mergeProperty(target, source, 'dependsOn'); mergeProperty(target, source, 'problemMatchers'); return target; @@ -887,7 +968,6 @@ interface Globals { command?: Tasks.CommandConfiguration; promptOnClose?: boolean; suppressTaskName?: boolean; - showOutput?: Tasks.ShowOutput; } namespace Globals { @@ -916,9 +996,6 @@ namespace Globals { export function fromBase(this: void, config: BaseTaskRunnerConfiguration, context: ParseContext): Globals { let result: Globals = {}; - if (Types.isString(config.showOutput)) { - result.showOutput = Tasks.ShowOutput.fromString(config.showOutput); - } if (config.suppressTaskName !== void 0) { result.suppressTaskName = !!config.suppressTaskName; } @@ -929,7 +1006,7 @@ namespace Globals { } export function isEmpty(value: Globals): boolean { - return !value || value.command === void 0 && value.promptOnClose === void 0 && value.showOutput === void 0 && value.suppressTaskName === void 0; + return !value || value.command === void 0 && value.promptOnClose === void 0 && value.suppressTaskName === void 0; } export function merge(target: Globals, source: Globals): Globals { @@ -941,7 +1018,6 @@ namespace Globals { } mergeProperty(target, source, 'promptOnClose'); mergeProperty(target, source, 'suppressTaskName'); - mergeProperty(target, source, 'showOutput'); return target; } @@ -952,9 +1028,6 @@ namespace Globals { if (value.suppressTaskName === void 0) { value.suppressTaskName = false; } - if (value.showOutput === void 0) { - value.showOutput = Tasks.ShowOutput.Always; - } if (value.promptOnClose === void 0) { value.promptOnClose = true; } @@ -1059,7 +1132,6 @@ class ConfigurationParser { group: Tasks.TaskGroup.Build, command: undefined, isBackground: isBackground, - showOutput: undefined, suppressTaskName: true, // this must be true since we infer the task from the global data. problemMatchers: matchers }; diff --git a/src/vs/workbench/parts/tasks/common/taskTemplates.ts b/src/vs/workbench/parts/tasks/common/taskTemplates.ts index d153e784935..0d7253582b8 100644 --- a/src/vs/workbench/parts/tasks/common/taskTemplates.ts +++ b/src/vs/workbench/parts/tasks/common/taskTemplates.ts @@ -179,8 +179,13 @@ const command: TaskEntry = { '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', '\t// for the documentation about the tasks.json format', '\t"version": "2.0.0",', - '\t"command": "echo \"Hello World\"",', - '\t"isShellCommand": true,', + '\t"tasks": [', + '\t\t{', + '\t\t\t"taskName": "echo",', + '\t\t\t"command": "echo Hello",', + '\t\t\t"isShellCommand": true', + '\t\t}', + '\t]', '}' ].join('\n') }; diff --git a/src/vs/workbench/parts/tasks/common/tasks.ts b/src/vs/workbench/parts/tasks/common/tasks.ts index c7b3d4ebf9b..4b3031da91f 100644 --- a/src/vs/workbench/parts/tasks/common/tasks.ts +++ b/src/vs/workbench/parts/tasks/common/tasks.ts @@ -41,6 +41,52 @@ export namespace ShellConfiguration { } } +export enum RevealKind { + /** + * Always brings the terminal to front if the task is executed. + */ + Always = 1, + + /** + * Only brings the terminal to front if a problem is detected executing the task + * (e.g. the task couldn't be started because). + */ + Silent = 2, + + /** + * The terminal never comes to front when the task is executed. + */ + Never = 3 +} + +export namespace RevealKind { + export function fromString(value: string): RevealKind { + switch (value.toLowerCase()) { + case 'always': + return RevealKind.Always; + case 'silent': + return RevealKind.Silent; + case 'never': + return RevealKind.Never; + default: + return RevealKind.Always; + } + } +} + +export interface TerminalBehavior { + /** + * Controls whether the terminal executing a task is brought to front or not. + * Defaults to `RevealKind.Always`. + */ + reveal: RevealKind; + + /** + * Controls whether the executed command is printed to the output window or terminal as well. + */ + echo: boolean; +} + export interface CommandConfiguration { /** * The command to execute @@ -68,30 +114,9 @@ export interface CommandConfiguration { taskSelector?: string; /** - * Controls whether the executed command is printed to the output windows as well. + * Describes how the terminal is supposed to behave. */ - echo: boolean; -} - -export enum ShowOutput { - Always = 1, - Silent = 2, - Never = 3 -} - -export namespace ShowOutput { - export function fromString(value: string): ShowOutput { - value = value.toLowerCase(); - if (value === 'always') { - return ShowOutput.Always; - } else if (value === 'silent') { - return ShowOutput.Silent; - } else if (value === 'never') { - return ShowOutput.Never; - } else { - return undefined; - } - } + terminal: TerminalBehavior; } export namespace TaskGroup { @@ -177,12 +202,6 @@ export interface Task { */ promptOnClose?: boolean; - /** - * Controls whether the output of the running tasks is shown or not. Default - * value is "always". - */ - showOutput: ShowOutput; - /** * The other tasks this task depends on. */ diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index ac6c9429c55..98b390f2f21 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -65,11 +65,12 @@ import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; import { IOutputService, IOutputChannelRegistry, Extensions as OutputExt, IOutputChannel } from 'vs/workbench/parts/output/common/output'; +import { Scope, IActionBarRegistry, Extensions as ActionBarExtensions } from 'vs/workbench/browser/actionBarRegistry'; import { ITerminalService } from 'vs/workbench/parts/terminal/common/terminal'; import { ITaskSystem, ITaskResolver, ITaskSummary, ITaskExecuteResult, TaskExecuteKind, TaskError, TaskErrors, TaskSystemEvents } from 'vs/workbench/parts/tasks/common/taskSystem'; -import { Task, TaskSet, TaskGroup, ExecutionEngine, ShowOutput, TaskSourceKind } from 'vs/workbench/parts/tasks/common/tasks'; +import { Task, TaskSet, TaskGroup, ExecutionEngine, TaskSourceKind } from 'vs/workbench/parts/tasks/common/tasks'; import { ITaskService, TaskServiceEvents, ITaskProvider } from 'vs/workbench/parts/tasks/common/taskService'; import { templates as taskTemplates } from 'vs/workbench/parts/tasks/common/taskTemplates'; @@ -77,6 +78,7 @@ import * as TaskConfig from 'vs/workbench/parts/tasks/common/taskConfiguration'; import { ProcessTaskSystem } from 'vs/workbench/parts/tasks/node/processTaskSystem'; import { TerminalTaskSystem } from './terminalTaskSystem'; import { ProcessRunnerDetector } from 'vs/workbench/parts/tasks/node/processRunnerDetector'; +import { QuickOpenActionContributor } from '../browser/quickOpen'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; @@ -758,7 +760,6 @@ class TaskService extends EventEmitter implements ITaskService { identifier: id, dependsOn: primaryTasks.map(task => task._id), command: undefined, - showOutput: ShowOutput.Never }; return { task, resolver }; } @@ -867,30 +868,32 @@ class TaskService extends EventEmitter implements ITaskService { } private getTaskSets(): TPromise { - return new TPromise((resolve, reject) => { - let result: TaskSet[] = []; - let counter: number = 0; - let done = (value: TaskSet) => { - if (value) { - result.push(value); - } - if (--counter === 0) { - resolve(result); - } - }; - let error = () => { - if (--counter === 0) { + return this.extensionService.activateByEvent('onCommand:workbench.action.tasks.runTask').then(() => { + return new TPromise((resolve, reject) => { + let result: TaskSet[] = []; + let counter: number = 0; + let done = (value: TaskSet) => { + if (value) { + result.push(value); + } + if (--counter === 0) { + resolve(result); + } + }; + let error = () => { + if (--counter === 0) { + resolve(result); + } + }; + if (this.getExecutionEngine() === ExecutionEngine.Terminal && this._providers.size > 0) { + this._providers.forEach((provider) => { + counter++; + provider.provideTasks().done(done, error); + }); + } else { resolve(result); } - }; - if (this.getExecutionEngine() === ExecutionEngine.Terminal && this._providers.size > 0) { - this._providers.forEach((provider) => { - counter++; - provider.provideTasks().done(done, error); - }); - } else { - resolve(result); - } + }); }).then((result) => { return this.getWorkspaceTasks().then((workspaceTaskResult) => { let workspaceTasksToDelete: Task[] = []; @@ -1018,10 +1021,7 @@ class TaskService extends EventEmitter implements ITaskService { configPromise = TPromise.as({ config, hasErrors: false }); } } else { - configPromise = new ProcessRunnerDetector(this.fileService, this.contextService, this.configurationResolverService).detect(true).then((value) => { - let hasErrors = this.printStderr(value.stderr); - return { config: value.config, hasErrors }; - }); + configPromise = TPromise.as({ config, hasErrors: false }); } } return configPromise.then((resolved) => { @@ -1326,6 +1326,9 @@ quickOpenRegistry.registerQuickOpenHandler( ) ); +const actionBarRegistry = Registry.as(ActionBarExtensions.Actionbar); +actionBarRegistry.registerActionBarContributor(Scope.VIEWER, QuickOpenActionContributor); + // Status bar let statusbarRegistry = Registry.as(StatusbarExtensions.Statusbar); statusbarRegistry.registerStatusbarItem(new StatusbarItemDescriptor(StatusBarItem, StatusbarAlignment.LEFT, 50 /* Medium Priority */)); diff --git a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts index 00b2950731f..504d0114385 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts @@ -33,7 +33,7 @@ import { IConfigurationResolverService } from 'vs/workbench/services/configurati import { ITerminalService, ITerminalInstance, IShellLaunchConfig } from 'vs/workbench/parts/terminal/common/terminal'; import { IOutputService, IOutputChannel } from 'vs/workbench/parts/output/common/output'; import { StartStopProblemCollector, WatchingProblemCollector, ProblemCollectorEvents } from 'vs/workbench/parts/tasks/common/problemCollectors'; -import { Task, ShowOutput, CommandOptions, ShellConfiguration } from 'vs/workbench/parts/tasks/common/tasks'; +import { Task, RevealKind, CommandOptions, ShellConfiguration } from 'vs/workbench/parts/tasks/common/tasks'; import { ITaskSystem, ITaskSummary, ITaskExecuteResult, TaskExecuteKind, TaskError, TaskErrors, ITaskResolver, TelemetryEvent, Triggers, TaskSystemEvents, TaskEvent, TaskType @@ -134,7 +134,8 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { public run(task: Task, resolver: ITaskResolver, trigger: string = Triggers.command): ITaskExecuteResult { let terminalData = this.activeTasks[task._id]; if (terminalData && terminalData.promise) { - if (task.showOutput === ShowOutput.Always) { + let reveal = task.command.terminal.reveal; + if (reveal === RevealKind.Always) { terminalData.terminal.setVisible(true); } return { kind: TaskExecuteKind.Active, active: { same: true, background: task.isBackground }, promise: terminalData.promise }; @@ -288,7 +289,8 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { this.emit(TaskSystemEvents.Inactive, event); } eventCounter = 0; - if (exitCode && exitCode === 1 && watchingProblemMatcher.numberOfMatches === 0 && task.showOutput !== ShowOutput.Never) { + let reveal = task.command.terminal.reveal; + if (exitCode && exitCode === 1 && watchingProblemMatcher.numberOfMatches === 0 && reveal !== RevealKind.Never) { this.terminalService.setActiveInstance(terminal); this.terminalService.showPanel(false); } @@ -330,7 +332,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { }); } this.terminalService.setActiveInstance(terminal); - if (task.showOutput === ShowOutput.Always) { + if (task.command.terminal.reveal === RevealKind.Always) { this.terminalService.showPanel(false); } this.activeTasks[task._id] = { terminal, task, promise }; @@ -364,7 +366,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { let options = this.resolveOptions(task.command.options); let { command, args } = this.resolveCommandAndArgs(task); let terminalName = nls.localize('TerminalTaskSystem.terminalName', 'Task - {0}', task.name); - let waitOnExit = task.showOutput !== ShowOutput.Never || !task.isBackground; + let waitOnExit = task.command.terminal.reveal !== RevealKind.Never || !task.isBackground; let shellLaunchConfig: IShellLaunchConfig = undefined; if (task.command.isShellCommand) { if (Platform.isWindows && ((options.cwd && TPath.isUNC(options.cwd)) || (!options.cwd && TPath.isUNC(process.cwd())))) { @@ -413,7 +415,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { }); shellArgs.push(commandLine); shellLaunchConfig.args = Platform.isWindows ? shellArgs.join(' ') : shellArgs; - if (task.command.echo) { + if (task.command.terminal.echo) { shellLaunchConfig.initialText = `> ${commandLine}`; } } else { @@ -427,7 +429,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { args, waitOnExit }; - if (task.command.echo) { + if (task.command.terminal.echo) { let getArgsToEcho = (args: string | string[]): string => { if (!args || args.length === 0) { return ''; diff --git a/src/vs/workbench/parts/tasks/node/processTaskSystem.ts b/src/vs/workbench/parts/tasks/node/processTaskSystem.ts index 9cc26f22205..848368e6dc4 100644 --- a/src/vs/workbench/parts/tasks/node/processTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/node/processTaskSystem.ts @@ -29,7 +29,7 @@ import { StartStopProblemCollector, WatchingProblemCollector, ProblemCollectorEv import { ITaskSystem, ITaskSummary, ITaskExecuteResult, TaskExecuteKind, TaskError, TaskErrors, TelemetryEvent, Triggers, TaskSystemEvents, TaskEvent, TaskType } from 'vs/workbench/parts/tasks/common/taskSystem'; -import { Task, CommandOptions, ShowOutput, CommandConfiguration } from 'vs/workbench/parts/tasks/common/tasks'; +import { Task, CommandOptions, RevealKind, CommandConfiguration } from 'vs/workbench/parts/tasks/common/tasks'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; @@ -178,11 +178,12 @@ export class ProcessTaskSystem extends EventEmitter implements ITaskSystem { this.childProcess = new LineProcess(command, args, !!commandConfig.isShellCommand, this.resolveOptions(commandConfig.options)); telemetryEvent.command = this.childProcess.getSanitizedCommand(); // we have no problem matchers defined. So show the output log - if (task.showOutput === ShowOutput.Always || (task.showOutput === ShowOutput.Silent && task.problemMatchers.length === 0)) { + let reveal = task.command.terminal.reveal; + if (reveal === RevealKind.Always || (reveal === RevealKind.Silent && task.problemMatchers.length === 0)) { this.showOutput(); } - if (commandConfig.echo) { + if (commandConfig.terminal.echo) { let prompt: string = Platform.isWindows ? '>' : '$'; this.log(`running command${prompt} ${command} ${args.join(' ')}`); } @@ -214,7 +215,7 @@ export class ProcessTaskSystem extends EventEmitter implements ITaskSystem { if (!this.checkTerminated(task, success)) { this.log(nls.localize('TaskRunnerSystem.watchingBuildTaskFinished', '\nWatching build tasks has finished.')); } - if (success.cmdCode && success.cmdCode === 1 && watchingProblemMatcher.numberOfMatches === 0 && task.showOutput !== ShowOutput.Never) { + if (success.cmdCode && success.cmdCode === 1 && watchingProblemMatcher.numberOfMatches === 0 && reveal !== RevealKind.Never) { this.showOutput(); } taskSummary.exitCode = success.cmdCode; @@ -258,7 +259,7 @@ export class ProcessTaskSystem extends EventEmitter implements ITaskSystem { startStopProblemMatcher.dispose(); this.checkTerminated(task, success); this.emit(TaskSystemEvents.Inactive, event); - if (success.cmdCode && success.cmdCode === 1 && startStopProblemMatcher.numberOfMatches === 0 && task.showOutput !== ShowOutput.Never) { + if (success.cmdCode && success.cmdCode === 1 && startStopProblemMatcher.numberOfMatches === 0 && reveal !== RevealKind.Never) { this.showOutput(); } taskSummary.exitCode = success.cmdCode; diff --git a/src/vs/workbench/parts/tasks/test/node/configuration.test.ts b/src/vs/workbench/parts/tasks/test/node/configuration.test.ts index 40ef9ddda1d..091899e941a 100644 --- a/src/vs/workbench/parts/tasks/test/node/configuration.test.ts +++ b/src/vs/workbench/parts/tasks/test/node/configuration.test.ts @@ -68,10 +68,32 @@ class ConfiguationBuilder { } } +class TerminalBehaviorBuilder { + + public result: Tasks.TerminalBehavior; + + constructor(public parent: CommandConfigurationBuilder) { + this.result = { echo: false, reveal: Tasks.RevealKind.Always }; + } + + public echo(value: boolean): TerminalBehaviorBuilder { + this.result.echo = value; + return this; + } + + public reveal(value: Tasks.RevealKind): TerminalBehaviorBuilder { + this.result.reveal = value; + return this; + } +} + class CommandConfigurationBuilder { public result: Tasks.CommandConfiguration; + private terminalBuilder: TerminalBehaviorBuilder; + constructor(public parent: TaskBuilder, command: string) { + this.terminalBuilder = new TerminalBehaviorBuilder(this); this.result = { name: command, isShellCommand: false, @@ -79,7 +101,7 @@ class CommandConfigurationBuilder { options: { cwd: '${workspaceRoot}' }, - echo: false + terminal: this.terminalBuilder.result }; } @@ -103,15 +125,14 @@ class CommandConfigurationBuilder { return this; } - public echo(value: boolean): CommandConfigurationBuilder { - this.result.echo = value; - return this; - } - public taskSelector(value: string): CommandConfigurationBuilder { this.result.taskSelector = value; return this; } + + public terminal(): TerminalBehaviorBuilder { + return this.terminalBuilder; + } } class TaskBuilder { @@ -127,7 +148,6 @@ class TaskBuilder { identifier: name, name: name, command: this.commandBuilder.result, - showOutput: Tasks.ShowOutput.Always, suppressTaskName: false, isBackground: false, promptOnClose: true, @@ -150,11 +170,6 @@ class TaskBuilder { return this; } - public showOutput(value: Tasks.ShowOutput): TaskBuilder { - this.result.showOutput = value; - return this; - } - public suppressTaskName(value: boolean): TaskBuilder { this.result.suppressTaskName = value; return this; @@ -401,7 +416,6 @@ function assertTask(actual: Tasks.Task, expected: Tasks.Task) { assert.ok(actual._id); assert.strictEqual(actual.name, expected.name, 'name'); assertCommandConfiguration(actual.command, expected.command); - assert.strictEqual(actual.showOutput, expected.showOutput, 'showOutput'); assert.strictEqual(actual.suppressTaskName, expected.suppressTaskName, 'suppressTaskName'); assert.strictEqual(actual.isBackground, expected.isBackground, 'isBackground'); assert.strictEqual(actual.promptOnClose, expected.promptOnClose, 'promptOnClose'); @@ -417,6 +431,7 @@ function assertTask(actual: Tasks.Task, expected: Tasks.Task) { function assertCommandConfiguration(actual: Tasks.CommandConfiguration, expected: Tasks.CommandConfiguration) { assert.strictEqual(typeof actual, typeof expected); if (actual && expected) { + assertTerminalBehavior(actual.terminal, expected.terminal); assert.strictEqual(actual.name, expected.name, 'name'); assert.strictEqual(actual.isShellCommand, expected.isShellCommand, 'isShellCommand'); assert.deepEqual(actual.args, expected.args, 'args'); @@ -428,11 +443,18 @@ function assertCommandConfiguration(actual: Tasks.CommandConfiguration, expected assert.deepEqual(actual.options.env, expected.options.env, 'env'); } } - assert.strictEqual(actual.echo, expected.echo, 'echo'); assert.strictEqual(actual.taskSelector, expected.taskSelector, 'taskSelector'); } } +function assertTerminalBehavior(actual: Tasks.TerminalBehavior, expected: Tasks.TerminalBehavior) { + assert.strictEqual(typeof actual, typeof expected); + if (actual && expected) { + assert.strictEqual(actual.echo, expected.echo); + assert.strictEqual(actual.reveal, expected.reveal); + } +} + function assertProblemMatcher(actual: string | ProblemMatcher, expected: string | ProblemMatcher) { assert.strictEqual(typeof actual, typeof expected); if (typeof actual === 'string' && typeof expected === 'string') { @@ -525,7 +547,7 @@ suite('Tasks Configuration parsing tests', () => { task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). suppressTaskName(true). - showOutput(Tasks.ShowOutput.Silent); + command().terminal().reveal(Tasks.RevealKind.Silent); testConfiguration( { version: '0.1.0', @@ -590,7 +612,7 @@ suite('Tasks Configuration parsing tests', () => { task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). suppressTaskName(true). - showOutput(Tasks.ShowOutput.Never); + command().terminal().reveal(Tasks.RevealKind.Never); testConfiguration( { version: '0.1.0', @@ -607,7 +629,7 @@ suite('Tasks Configuration parsing tests', () => { task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). suppressTaskName(true). - command(). + command().terminal(). echo(true); testConfiguration( { @@ -759,8 +781,8 @@ suite('Tasks Configuration parsing tests', () => { builder. task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). - showOutput(Platform.isWindows ? Tasks.ShowOutput.Always : Tasks.ShowOutput.Never). - suppressTaskName(true); + suppressTaskName(true). + command().terminal().reveal(Platform.isWindows ? Tasks.RevealKind.Always : Tasks.RevealKind.Never); let external: ExternalTaskRunnerConfiguration = { version: '0.1.0', command: 'tsc', @@ -778,7 +800,7 @@ suite('Tasks Configuration parsing tests', () => { task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). suppressTaskName(true). - command(). + command().terminal(). echo(Platform.isWindows ? false : true); let external: ExternalTaskRunnerConfiguration = { version: '0.1.0', @@ -903,12 +925,11 @@ suite('Tasks Configuration parsing tests', () => { let builder = new ConfiguationBuilder(); builder.task('test', 'tsc'). group(Tasks.TaskGroup.Test). - showOutput(Tasks.ShowOutput.Never). args(['--p']). isBackground(true). promptOnClose(false). - command(). - echo(true); + command().terminal(). + echo(true).reveal(Tasks.RevealKind.Never); testConfiguration(external, builder); }); @@ -928,9 +949,8 @@ suite('Tasks Configuration parsing tests', () => { let builder = new ConfiguationBuilder(); builder.task('test', 'tsc'). group(Tasks.TaskGroup.Test). - showOutput(Tasks.ShowOutput.Never). - command(). - echo(true); + command().terminal(). + echo(true).reveal(Tasks.RevealKind.Never); testConfiguration(external, builder); }); @@ -1392,15 +1412,17 @@ suite('Bugs / regression tests', () => { let builder = new ConfiguationBuilder(); if (Platform.isWindows) { builder.task('composeForDebug', 'powershell'). - suppressTaskName(true).showOutput(Tasks.ShowOutput.Always). + suppressTaskName(true). args(['-ExecutionPolicy', 'RemoteSigned', '.\\dockerTask.ps1', '-ComposeForDebug', '-Environment', 'debug']). - command().echo(true).options({ cwd: '${workspaceRoot}' }); + command().options({ cwd: '${workspaceRoot}' }). + terminal().echo(true).reveal(Tasks.RevealKind.Always); testConfiguration(external, builder); } else if (Platform.isMacintosh) { builder.task('composeForDebug', '/bin/bash'). - suppressTaskName(true).showOutput(Tasks.ShowOutput.Always). + suppressTaskName(true). args(['-c', './dockerTask.sh composeForDebug debug']). - command().options({ cwd: '${workspaceRoot}' }); + command().options({ cwd: '${workspaceRoot}' }). + terminal().reveal(Tasks.RevealKind.Always); testConfiguration(external, builder); } }); -- GitLab From 92adbb1bb7ac699d8d487a84d417758539717da7 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Wed, 24 May 2017 12:41:57 +0200 Subject: [PATCH 0025/1347] update service: get initial state --- src/vs/platform/update/common/updateIpc.ts | 25 +++++++++++++++++----- 1 file changed, 20 insertions(+), 5 deletions(-) diff --git a/src/vs/platform/update/common/updateIpc.ts b/src/vs/platform/update/common/updateIpc.ts index 2076719e98a..cb48952d2b3 100644 --- a/src/vs/platform/update/common/updateIpc.ts +++ b/src/vs/platform/update/common/updateIpc.ts @@ -7,7 +7,9 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { IChannel, eventToCall, eventFromCall } from 'vs/base/parts/ipc/common/ipc'; -import Event from 'vs/base/common/event'; +import Event, { Emitter, any, mapEvent } from 'vs/base/common/event'; +import { onUnexpectedError } from 'vs/base/common/errors'; +import { memoize } from 'vs/base/common/decorators'; import { IUpdateService, IRawUpdate, State, IUpdate } from './update'; export interface IUpdateChannel extends IChannel { @@ -18,6 +20,7 @@ export interface IUpdateChannel extends IChannel { call(command: 'event:onStateChange'): TPromise; call(command: 'checkForUpdates', arg: boolean): TPromise; call(command: 'quitAndInstall'): TPromise; + call(command: '_getInitialState'): TPromise; call(command: string, arg?: any): TPromise; } @@ -34,6 +37,7 @@ export class UpdateChannel implements IUpdateChannel { case 'event:onStateChange': return eventToCall(this.service.onStateChange); case 'checkForUpdates': return this.service.checkForUpdates(arg); case 'quitAndInstall': return this.service.quitAndInstall(); + case '_getInitialState': return TPromise.as(this.service.state); } return undefined; } @@ -55,14 +59,25 @@ export class UpdateChannelClient implements IUpdateService { private _onUpdateReady = eventFromCall(this.channel, 'event:onUpdateReady'); get onUpdateReady(): Event { return this._onUpdateReady; } - private _onStateChange = eventFromCall(this.channel, 'event:onStateChange'); - get onStateChange(): Event { return this._onStateChange; } + private _onInitialStateChange = new Emitter(); + private _onRemoteStateChange = eventFromCall(this.channel, 'event:onStateChange'); + + @memoize + get onStateChange(): Event { + const result = any(this._onInitialStateChange.event, this._onRemoteStateChange); + + return mapEvent(result, state => { + this._state = state; + return state; + }); + } private _state: State = State.Uninitialized; get state(): State { return this._state; }; - constructor(private channel: IChannel) { - this.onStateChange(state => this._state = state); + constructor(private channel: IUpdateChannel) { + channel.call('_getInitialState') + .done(state => this._onInitialStateChange.fire(state), onUnexpectedError); } checkForUpdates(explicit: boolean): TPromise { -- GitLab From bbfd39561a5053f6767e7047509c4bd15d1f4411 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Wed, 24 May 2017 15:38:21 +0200 Subject: [PATCH 0026/1347] fix update state changes --- src/vs/platform/update/common/updateIpc.ts | 28 ++++++++++------------ 1 file changed, 13 insertions(+), 15 deletions(-) diff --git a/src/vs/platform/update/common/updateIpc.ts b/src/vs/platform/update/common/updateIpc.ts index cb48952d2b3..169f827d015 100644 --- a/src/vs/platform/update/common/updateIpc.ts +++ b/src/vs/platform/update/common/updateIpc.ts @@ -7,9 +7,8 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { IChannel, eventToCall, eventFromCall } from 'vs/base/parts/ipc/common/ipc'; -import Event, { Emitter, any, mapEvent } from 'vs/base/common/event'; +import Event, { Emitter } from 'vs/base/common/event'; import { onUnexpectedError } from 'vs/base/common/errors'; -import { memoize } from 'vs/base/common/decorators'; import { IUpdateService, IRawUpdate, State, IUpdate } from './update'; export interface IUpdateChannel extends IChannel { @@ -59,25 +58,24 @@ export class UpdateChannelClient implements IUpdateService { private _onUpdateReady = eventFromCall(this.channel, 'event:onUpdateReady'); get onUpdateReady(): Event { return this._onUpdateReady; } - private _onInitialStateChange = new Emitter(); private _onRemoteStateChange = eventFromCall(this.channel, 'event:onStateChange'); - - @memoize - get onStateChange(): Event { - const result = any(this._onInitialStateChange.event, this._onRemoteStateChange); - - return mapEvent(result, state => { - this._state = state; - return state; - }); - } + private _onStateChange = new Emitter(); + get onStateChange(): Event { return this._onStateChange.event; } private _state: State = State.Uninitialized; get state(): State { return this._state; }; constructor(private channel: IUpdateChannel) { - channel.call('_getInitialState') - .done(state => this._onInitialStateChange.fire(state), onUnexpectedError); + // always set this._state as the state changes + this.onStateChange(state => this._state = state); + + channel.call('_getInitialState').done(state => { + // fire initial state + this._onStateChange.fire(state); + + // fire subsequent states as they come in from remote + this._onRemoteStateChange(s => this._onStateChange.fire(state)); + }, onUnexpectedError); } checkForUpdates(explicit: boolean): TPromise { -- GitLab From 5322c9fd5b61d3c568d08453a1a29465f1c252d8 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 24 May 2017 16:36:35 +0200 Subject: [PATCH 0027/1347] Updated the way to run the smoke test. --- test/smoke/.vscode/launch.json | 2 +- test/smoke/CONTRIBUTING.md | 4 +- test/smoke/README.md | 4 +- test/smoke/package.json | 9 +- test/smoke/scripts/run.ps1 | 44 ------ test/smoke/scripts/run.sh | 43 ------ test/smoke/src/areas/common.ts | 12 +- test/smoke/src/areas/css.ts | 4 +- test/smoke/src/areas/data-loss.ts | 2 +- test/smoke/src/areas/extensions.ts | 2 +- test/smoke/src/areas/first-experience.ts | 2 +- test/smoke/src/areas/integrated-terminal.ts | 1 + test/smoke/src/areas/javascript-debug.ts | 2 +- test/smoke/src/areas/statusbar.ts | 6 +- test/smoke/src/areas/tasks.ts | 3 +- test/smoke/src/main.js | 163 ++++++++++++++++++++ test/smoke/src/mocha-runner.js | 21 +++ test/smoke/src/spectron/application.ts | 13 +- test/smoke/src/spectron/client.ts | 2 +- test/smoke/src/{main.ts => tests.ts} | 96 ++++++------ test/smoke/tsconfig.json | 2 +- vscode-smoketest-express | 1 - 22 files changed, 272 insertions(+), 166 deletions(-) delete mode 100644 test/smoke/scripts/run.ps1 delete mode 100644 test/smoke/scripts/run.sh create mode 100644 test/smoke/src/main.js create mode 100644 test/smoke/src/mocha-runner.js rename test/smoke/src/{main.ts => tests.ts} (93%) delete mode 160000 vscode-smoketest-express diff --git a/test/smoke/.vscode/launch.json b/test/smoke/.vscode/launch.json index 2de33bbb20b..25b4e7e4c0e 100644 --- a/test/smoke/.vscode/launch.json +++ b/test/smoke/.vscode/launch.json @@ -15,7 +15,7 @@ "--timeout", "999999", "--colors", - "${workspaceRoot}/out/main.js" + "${workspaceRoot}/out/tests.js" ], "outFiles": [ "${workspaceRoot}/out/**/*.js" ], "internalConsoleOptions": "openOnSessionStart", diff --git a/test/smoke/CONTRIBUTING.md b/test/smoke/CONTRIBUTING.md index c15016dc1ad..8aaef8a7875 100644 --- a/test/smoke/CONTRIBUTING.md +++ b/test/smoke/CONTRIBUTING.md @@ -1,5 +1,7 @@ # Architecture -* `main.ts` contains the main smoke test suite. It includes all tests separated into mocha `describe()` groups that represent each of the areas of [Smoke Test document](https://github.com/Microsoft/vscode/wiki/Smoke-Test). +* `main.js` is used to prepare all smoke test dependencies (fetching key bindings and 'Express' repository, running `npm install` there). +* `mocha-runner.js` launches Mocha programmatically. It is spawned in Node environment from main.js to ensure that it is possible to listen on `stderr`s (primary `process.stderr` is not readable otherwise). This is accomplished because WebDriverIO command deprecation warnings need to be redirected to a separate log. Those warnings are coming from WebDriverIO because ChromeDriver has not migrated from JsonWire to W3C WebDriver protocol. +* `tests.ts` contains the main smoke test suite. It includes all tests separated into mocha `describe()` groups that represent each of the areas of [Smoke Test document](https://github.com/Microsoft/vscode/wiki/Smoke-Test). * `./areas/` folder contains a `.ts` file per each area of the document. E.g. `'Search'` area goes under `'search.ts'`. Every area file contains a list of methods with the name that represents the action that can be performed in the corresponding test. This reduces the amount of test suite code and means that if the UI changes, the fix need only be applied in one place. The name of the method reflects the action the tester would do if he would perform the test manually. See [Selenium Page Objects Wiki](https://github.com/SeleniumHQ/selenium/wiki/PageObjects) and [Selenium Bot Style Tests Wiki](https://github.com/SeleniumHQ/selenium/wiki/Bot-Style-Tests) for a good explanation of the implementation. Every smoke test area contains methods that are used in a bot-style approach in `main.ts`. * `./spectron/` wraps the Spectron, with WebDriverIO API wrapped in `client.ts` and instance of Spectron Application is wrapped in `application.ts`. diff --git a/test/smoke/README.md b/test/smoke/README.md index 318ddb07517..501ec51f087 100644 --- a/test/smoke/README.md +++ b/test/smoke/README.md @@ -1,9 +1,9 @@ # VS Code Smoke Testing This repository contains the smoke test automation code with Spectron for Visual Studio Code. -The following command is used to run the tests: `.\scripts\run.ps1 -latest "path\to\Code.exe"` on Windows (from PowerShell) and `./scripts/run.sh path/to/binary` on Unix system. +The following command is used to run the tests: `npm test -- --latest "path/to/binary"`. -If you want to include 'Data Migration' area tests use `.\scripts\run.ps1 -latest "path\to\Code.exe" -stable "path\to\CurrentStable.exe"` and `./scripts/run.sh path/to/binary path/to/currentStable` respectively. +If you want to include 'Data Migration' area tests use `npm test -- --latest path/to/binary --stable path/to/currentStable` respectively. # Contributing diff --git a/test/smoke/package.json b/test/smoke/package.json index a5c3a78273b..4f637a5adf7 100644 --- a/test/smoke/package.json +++ b/test/smoke/package.json @@ -1,9 +1,10 @@ { "name": "code-oss-dev-smoke-test", "version": "0.1.0", - "main": "./out/main.js", + "main": "./src/main.js", "scripts": { - "test": "mocha -u tdd --timeout 360000 --retries 2 --slow 50000 --colors ./out/main.js 2> test_data/errors.log" + "pretest": "tsc", + "test": "node src/main.js" }, "devDependencies": { "@types/mocha": "^2.2.41", @@ -14,6 +15,8 @@ "mocha": "^3.2.0", "spectron": "^3.6.4", "typescript": "^2.2.2", - "rimraf": "^2.6.1" + "rimraf": "^2.6.1", + "commander": "^2.9.0", + "simple-git": "^1.73.0" } } diff --git a/test/smoke/scripts/run.ps1 b/test/smoke/scripts/run.ps1 deleted file mode 100644 index 5883ce0dbe8..00000000000 --- a/test/smoke/scripts/run.ps1 +++ /dev/null @@ -1,44 +0,0 @@ -Param( - [Parameter(Position=0,mandatory=$true)] - [string]$arch -) - - -# Setup sample repository for the smoke test -Set-Location .. -if (-Not (Test-Path vscode-smoketest-express)) { - git clone https://github.com/Microsoft/vscode-smoketest-express.git - Set-Location ./vscode-smoketest-express -} else { - Set-Location ./vscode-smoketest-express - git fetch origin master - git reset --hard FETCH_HEAD - git clean -fd -} -npm install - -Write-Output "My path: " + $(pwd) - -# Setup the test directory for running -Set-Location ..\smoke -if (-Not (Test-Path node_modules)) { - npm install -} - -# Configure environment variables -$env:VSCODE_LATEST_PATH = "$(pwd)\..\VSCode-win32-$arch\Code - Insiders.exe" -# $env:VSCODE_STABLE_PATH = $stable -$env:SMOKETEST_REPO = "..\vscode-smoketest-express" - -if ($env:VSCODE_LATEST_PATH.Contains('Insiders')) { - $env:VSCODE_EDITION = 'insiders' -} - -# Retrieve key bindings config file for Windows -$testDirectory = (Resolve-Path .\).Path -$client = New-Object System.Net.WebClient -$client.DownloadFile("https://raw.githubusercontent.com/Microsoft/vscode-docs/master/scripts/keybindings/doc.keybindings.win.json","$testDirectory\test_data\keybindings.win32.json") - -# Compile and launch the smoke test -tsc -npm test \ No newline at end of file diff --git a/test/smoke/scripts/run.sh b/test/smoke/scripts/run.sh deleted file mode 100644 index fc103a55539..00000000000 --- a/test/smoke/scripts/run.sh +++ /dev/null @@ -1,43 +0,0 @@ -#!/usr/bin/env bash -if [[ "$#" -ne 1 ]]; then - echo "Usage: ./scripts/run.sh path/to/binary" - echo "To perform data migration tests, use: ./scripts/run.sh path/to/latest_binary path/to/stable_binary" - exit 1 -fi - -# Cloning sample repository for the smoke test -cd .. -if ! [ -d vscode-smoketest-express ]; then - git clone https://github.com/Microsoft/vscode-smoketest-express.git - cd vscode-smoketest-express -else - cd vscode-smoketest-express - git fetch origin master - git reset --hard FETCH_HEAD - git clean -fd -fi -npm install - -# Install Node modules for Spectron -cd ../vscode-smoketest -test -d node_modules || npm install - -# Configuration -export VSCODE_LATEST_PATH="$1" -export VSCODE_STABLE_PATH="$2" -export SMOKETEST_REPO="../vscode-smoketest-express" -mkdir -p test_data - -if [[ $1 == *"Insiders"* || $1 == *"insiders"* ]]; then - export VSCODE_EDITION="insiders" -fi - -if [[ "$OSTYPE" == "darwin"* ]]; then - curl "https://raw.githubusercontent.com/Microsoft/vscode-docs/master/scripts/keybindings/doc.keybindings.osx.json" -o "test_data/keybindings.darwin.json" # Download OS X keybindings -else - wget https://raw.githubusercontent.com/Microsoft/vscode-docs/master/scripts/keybindings/doc.keybindings.linux.json -O test_data/keybindings.linux.json # Download Linux keybindings -fi - -# Compile and launch the smoke test -tsc -exec npm test diff --git a/test/smoke/src/areas/common.ts b/test/smoke/src/areas/common.ts index c955c206eea..33127905ec6 100644 --- a/test/smoke/src/areas/common.ts +++ b/test/smoke/src/areas/common.ts @@ -19,7 +19,7 @@ export class CommonActions { public async getWindowTitle(): Promise { return this.spectron.client.getTitle(); } - + public enter(): Promise { return this.spectron.client.keys(['Enter', 'NULL']); } @@ -34,7 +34,7 @@ export class CommonActions { await this.spectron.wait(); return this.saveOpenedFile(); } - + public async newUntitledFile(): Promise { await this.spectron.command('workbench.action.files.newUntitledFile'); return this.spectron.wait(); @@ -50,7 +50,7 @@ export class CommonActions { if (el.status === 0) { return el; } - + return undefined; } @@ -118,7 +118,7 @@ export class CommonActions { selector += ' explorer-item'; } selector += '"]'; - + await this.spectron.waitFor(this.spectron.client.doubleClick, selector); return this.spectron.wait(); } @@ -132,7 +132,7 @@ export class CommonActions { } else if (extension === 'md') { return 'md-ext-file-icon markdown-lang-file-icon'; } - + throw new Error('No class defined for this file extension'); } @@ -142,7 +142,7 @@ export class CommonActions { if (Array.isArray(span)) { return span[0]; } - + return span; } catch (e) { return undefined; diff --git a/test/smoke/src/areas/css.ts b/test/smoke/src/areas/css.ts index 3388ab4e465..d2cbd62b0a8 100644 --- a/test/smoke/src/areas/css.ts +++ b/test/smoke/src/areas/css.ts @@ -11,7 +11,7 @@ export enum CSSProblem { }; export class CSS { - + constructor(private spectron: SpectronApplication) { // noop } @@ -56,7 +56,7 @@ export class CSS { if (el.status === 0) { return el; } - + return undefined; } } \ No newline at end of file diff --git a/test/smoke/src/areas/data-loss.ts b/test/smoke/src/areas/data-loss.ts index dc1ecf93730..5988ce6f7f8 100644 --- a/test/smoke/src/areas/data-loss.ts +++ b/test/smoke/src/areas/data-loss.ts @@ -20,7 +20,7 @@ export class DataLoss { if (el.status === 0) { return el; } - + return undefined; } } \ No newline at end of file diff --git a/test/smoke/src/areas/extensions.ts b/test/smoke/src/areas/extensions.ts index 4edec9d06ef..bc4e2743e44 100644 --- a/test/smoke/src/areas/extensions.ts +++ b/test/smoke/src/areas/extensions.ts @@ -7,7 +7,7 @@ import { SpectronApplication } from '../spectron/application'; import { CommonActions } from "./common"; export class Extensions { - + private readonly extensionsViewletSelector = 'div[id="workbench.view.extensions"]'; constructor(private spectron: SpectronApplication, private common: CommonActions) { diff --git a/test/smoke/src/areas/first-experience.ts b/test/smoke/src/areas/first-experience.ts index e9141bda899..2d6e9c30eaa 100644 --- a/test/smoke/src/areas/first-experience.ts +++ b/test/smoke/src/areas/first-experience.ts @@ -15,7 +15,7 @@ export class FirstExperience { if (el.status === 0) { return el; } - + return undefined; } } \ No newline at end of file diff --git a/test/smoke/src/areas/integrated-terminal.ts b/test/smoke/src/areas/integrated-terminal.ts index b066db8adf7..c41f2946d4d 100644 --- a/test/smoke/src/areas/integrated-terminal.ts +++ b/test/smoke/src/areas/integrated-terminal.ts @@ -25,6 +25,7 @@ export class IntegratedTerminal { public async getCommandOutput(command: string): Promise { const selector = 'div[id="workbench.panel.terminal"] .xterm-rows'; + // Default Powershell terminal adds 3 header rows at the top, whereas bash does not. let readRow = process.platform === 'win32' ? 5 : 2; let output: string = await this.spectron.client.getText(`${selector}>:nth-child(${readRow})`); diff --git a/test/smoke/src/areas/javascript-debug.ts b/test/smoke/src/areas/javascript-debug.ts index 948594945d7..ff39a985d66 100644 --- a/test/smoke/src/areas/javascript-debug.ts +++ b/test/smoke/src/areas/javascript-debug.ts @@ -36,7 +36,7 @@ export class JavaScriptDebug { if (el.status === 0) { return el; } - + return undefined; } } \ No newline at end of file diff --git a/test/smoke/src/areas/statusbar.ts b/test/smoke/src/areas/statusbar.ts index 93b73495183..8e330c8e121 100644 --- a/test/smoke/src/areas/statusbar.ts +++ b/test/smoke/src/areas/statusbar.ts @@ -49,7 +49,7 @@ export class StatusBar { if (el.status === 0) { return el; } - + return undefined; } @@ -58,7 +58,7 @@ export class StatusBar { if (el.status === 0) { return el; } - + return undefined; } @@ -71,7 +71,7 @@ export class StatusBar { if (el.status === 0) { return el; } - + return undefined; } diff --git a/test/smoke/src/areas/tasks.ts b/test/smoke/src/areas/tasks.ts index e46c2961df5..d83cc173efa 100644 --- a/test/smoke/src/areas/tasks.ts +++ b/test/smoke/src/areas/tasks.ts @@ -25,6 +25,7 @@ export class Tasks { public async firstOutputLineEndsWith(fileName: string): Promise { const firstLine = await this.spectron.waitFor(this.spectron.client.getText, `${this.outputViewSelector}>:nth-child(2)`); + return firstLine.endsWith(fileName); } @@ -40,7 +41,7 @@ export class Tasks { return this.spectron.client.getValue(`${this.workbenchPanelSelector} .select-box`); } - public getProblemsViewFirstElementName(): Promise { + public getProblemsViewFirstElementName(): Promise { return this.spectron.waitFor(this.spectron.client.getText, `${this.problemsViewSelector} .label-name`); } diff --git a/test/smoke/src/main.js b/test/smoke/src/main.js new file mode 100644 index 00000000000..8df41b5c73c --- /dev/null +++ b/test/smoke/src/main.js @@ -0,0 +1,163 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +var fs = require('fs'); +var https = require('https'); +var program = require('commander'); +var git = require('simple-git')(); +var child_process = require('child_process'); +var path = require('path'); + +var tempFolder = `test_data`; +var testRepoUrl = 'https://github.com/Microsoft/vscode-smoketest-express'; +var testRepoLocalDir = path.join(process.cwd(), `${tempFolder}/vscode-smoketest-express`); +var keybindingsUrl = 'https://raw.githubusercontent.com/Microsoft/vscode-docs/master/scripts/keybindings'; + +program + .option('-l, --latest ', 'path to the latest VS Code to test') + .option('-s, --stable [file path]', 'path to the stable VS Code to be used in data migration tests'); + +program.on('--help', () => { + console.log(' Examples:'); + console.log(''); + console.log(' $ npm test -- --latest path/to/binary'); + console.log(' $ npm test -- -l path/to/binary'); + console.log(''); + console.log(' $ npm test -- --latest path/to/latest/binary --stable path/to/stable/binary'); + console.log(' $ npm test -- -l path/to/latest/binary -s path/to/stable/binary'); + console.log(''); +}); +program.parse(process.argv); + +if (!program.latest) { + console.error('You must specify the binary to run the smoke test against'); + process.exit(1); +} +if (!binaryExists(program.latest) || (program.stable && !binaryExists(program.stable))) { + console.error('The file path to electron binary does not exist or permissions do not allow to execute it. Please check the path provided.'); + process.exit(1); +} + +// Setting up environment variables +process.env['VSCODE_LATEST_PATH'] = program.latest; +if (program.stable) process.env['VSCODE_STABLE_PATH'] = program.stable; +process.env['SMOKETEST_REPO'] = testRepoLocalDir; +if (program.stable && program.stable.toLowerCase().startsWith('insiders')) process.env['VSCODE_EDITION'] = 'insiders'; + +// Setting up 'vscode-smoketest-express' project +var os = process.platform; +if (os === 'darwin') os = 'osx'; +else if (os === 'win32') os = 'win'; +var promises = []; + +try { + // promises.push(execute('npm install'), process.cwd()); + promises.push(getKeybindings(`${keybindingsUrl}/doc.keybindings.${os}.json`, `${tempFolder}/keybindings.json`)); + promises.push(cleanOrClone(testRepoUrl, testRepoLocalDir)); + + Promise.all(promises).then(() => { execute('npm install', testRepoLocalDir).then(() => runTests()); }); +} catch (e) { + throw new Error('Error caught running the smoke test: ' + e); +} + + +function runTests() { + console.log('Running tests...') + const spawn = require('child_process').spawn; + var proc = spawn(process.execPath, [ + 'src/mocha-runner.js' + ]); + proc.stdout.on('data', data => { + console.log(data.toString()); + }); + proc.stderr.on('data', data => { + var date = new Date().toLocaleString(); + fs.appendFile(`${tempFolder}/errors.log`, `${date}: ${data.toString()}`, (err) => { + if (err) throw new Error(`Could not write stderr to errors.log with the following error: ${err}`); + }); + }); +} + +function cleanOrClone(repo, dir) { + console.log('Cleaning or cloning test project repository...'); + return new Promise((res, rej) => { + if (!folderExists(dir)) { + git.clone(repo, dir, () => { + console.log('Test repository successfully cloned.'); + res(); + }); + } else { + git.cwd(dir); + git.fetch((err) => { + if (err) rej(err); + resetAndClean(); + }); + } + + var resetAndClean = () => { + git.reset(['FETCH_HEAD', '--hard'], (err) => { + if (err) rej(err); + + git.clean('f', ['-d'], (err) => { + if (err) rej(err); + console.log('Test project was successfully reset to initial state.'); + res(); + }); + }); + } + }); +} + +function execute(cmd, dir) { + return new Promise((res, rej) => { + console.log(`Running ${cmd}...`); + var output = child_process.exec(cmd, { cwd: dir, stdio: [0, 1, 2] }, (error, stdout, stderr) => { + if (error) rej(error); + if (stderr) console.error(stderr); + console.log(stdout); + res(); + }); + }); +} + +function getKeybindings(url, location) { + console.log(`Fetching keybindings from ${url}...`); + return new Promise((resolve, reject) => { + https.get(url, (res) => { + if (res.statusCode != 200) { + reject(`Failed to obtain key bindings with response code: ${res.statusCode}`); + } + + var buffer = []; + res.on('data', (chunk) => buffer.push(chunk)); + res.on('end', () => { + fs.writeFile(location, Buffer.concat(buffer), 'utf8', () => { + console.log('Keybindings were successfully fetched.'); + resolve(); + }); + }); + }).on('error', (e) => { + reject(`Failed to obtain key bindings with an error: ${e}`); + }); + }); +} + +function folderExists(folder) { + try { + fs.accessSync(folder, 'rw'); + return true; + } catch (e) { + return false; + } +} + +function binaryExists(filePath) { + try { + fs.accessSync(filePath, 'x'); + return true; + } catch (e) { + return false; + } +} \ No newline at end of file diff --git a/test/smoke/src/mocha-runner.js b/test/smoke/src/mocha-runner.js new file mode 100644 index 00000000000..2a08adca647 --- /dev/null +++ b/test/smoke/src/mocha-runner.js @@ -0,0 +1,21 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +var Mocha = require('mocha'); +var path = require('path'); + +var mocha = new Mocha({ + timeout: 360000, + retries: 2, + slow: 50000, + useColors: true +}); + +mocha.addFile(path.join(process.cwd(), 'out/tests.js')); +mocha.run((failures) => { + process.on('exit', () => { + process.exit(failures); + }); +}); \ No newline at end of file diff --git a/test/smoke/src/spectron/application.ts b/test/smoke/src/spectron/application.ts index 5e45474768c..d1027a1ef70 100644 --- a/test/smoke/src/spectron/application.ts +++ b/test/smoke/src/spectron/application.ts @@ -7,6 +7,7 @@ import { Application } from 'spectron'; import { SpectronClient } from './client'; import { Screenshot } from "../helpers/screenshot"; var fs = require('fs'); +var path = require('path'); /** * Wraps Spectron's Application instance with its used methods. @@ -16,7 +17,7 @@ export class SpectronApplication { private spectron: Application; private readonly pollTrials = 5; - private readonly pollTimeout = 3; // in secs + private readonly pollTimeout = 3; // in secs private keybindings: any[]; private screenshot: Screenshot; @@ -73,13 +74,15 @@ export class SpectronApplication { } private retrieveKeybindings() { - const os = process.platform; - fs.readFile(`test_data/keybindings.${os}.json`, (err, data) => { + fs.readFile(path.join(process.cwd(), `test_data/keybindings.json`), 'utf8', (err, data) => { if (err) { throw err; } - - this.keybindings = JSON.parse(data); + try { + this.keybindings = JSON.parse(data); + } catch (e) { + throw new Error(`Error parsing keybindings JSON: ${e}`); + } }); } diff --git a/test/smoke/src/spectron/client.ts b/test/smoke/src/spectron/client.ts index 9376bd3e100..6a9003199dc 100644 --- a/test/smoke/src/spectron/client.ts +++ b/test/smoke/src/spectron/client.ts @@ -7,7 +7,7 @@ import { Application } from 'spectron'; import { Screenshot } from '../helpers/screenshot'; /** - * Abstracts the Spectron's WebdriverIO managed client property on the created Application instances. + * Abstracts the Spectron's WebdriverIO managed client property on the created Application instances. */ export class SpectronClient { diff --git a/test/smoke/src/main.ts b/test/smoke/src/tests.ts similarity index 93% rename from test/smoke/src/main.ts rename to test/smoke/src/tests.ts index 9da55ce546a..35d6d1f79ac 100644 --- a/test/smoke/src/main.ts +++ b/test/smoke/src/tests.ts @@ -6,7 +6,7 @@ import * as assert from 'assert'; import { SpectronApplication } from "./spectron/application"; import { CommonActions } from './areas/common'; -import { FirstExperience } from './areas/first-experience'; +// import { FirstExperience } from './areas/first-experience'; import { ConfigurationView, ActivityBarPosition } from './areas/configuration-views'; import { Search } from './areas/search'; import { CSS, CSSProblem } from './areas/css'; @@ -23,14 +23,13 @@ import { Localization, ViewletType } from "./areas/localization"; describe('Smoke Test Suite', function () { const latestPath = process.env.VSCODE_LATEST_PATH; const stablePath = process.env.VSCODE_STABLE_PATH; - const insiders = process.env.VSCODE_EDITION; + // const insiders = process.env.VSCODE_EDITION; const workspacePath = process.env.SMOKETEST_REPO; const tempUserDir = 'test_data/temp_user_dir'; const tempExtensionsDir = 'test_data/temp_extensions_dir'; let app: SpectronApplication; let common: CommonActions; - this.retries(2); if (stablePath) { context('Data Migration', function () { @@ -176,37 +175,38 @@ describe('Smoke Test Suite', function () { }); }); - context('First User Experience', function () { - let experience: FirstExperience; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), undefined, [`--user-data-dir=${tempUserDir}`, `--excludeSwitches=load-component-extension`]); - common = new CommonActions(app); - experience = new FirstExperience(app); - - await common.removeDirectory(tempUserDir); - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it(`verifies if title is set correctly on the clean user-directory startup`, async function () { - const title = await common.getWindowTitle(); - - let expectedTitle = 'Welcome'; - if (process.platform !== 'darwin') { - expectedTitle += ' — Visual Studio Code'; - if (insiders) expectedTitle += ' - Insiders'; - } - - assert.equal(title, expectedTitle); - }); - - it(`verifies if 'Welcome page' tab is presented on the clean user-directory startup`, async function () { - assert.ok(await experience.getWelcomeTab()); - }); - }); + // Do not run until experiments are finished over the first-time startup behaviour. + // context('First User Experience', function () { + // let experience: FirstExperience; + + // beforeEach(async function () { + // app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), undefined, [`--user-data-dir=${tempUserDir}`, `--excludeSwitches=load-component-extension`]); + // common = new CommonActions(app); + // experience = new FirstExperience(app); + + // await common.removeDirectory(tempUserDir); + // return await app.start(); + // }); + // afterEach(async function () { + // return await app.stop(); + // }); + + // it(`verifies if title is set correctly on the clean user-directory startup`, async function () { + // const title = await common.getWindowTitle(); + + // let expectedTitle = 'Welcome'; + // if (process.platform !== 'darwin') { + // expectedTitle += ' — Visual Studio Code'; + // if (insiders) expectedTitle += ' - Insiders'; + // } + + // assert.equal(title, expectedTitle); + // }); + + // it(`verifies if 'Welcome page' tab is presented on the clean user-directory startup`, async function () { + // assert.ok(await experience.getWelcomeTab()); + // }); + // }); context('Explorer', function () { beforeEach(async function () { @@ -557,7 +557,6 @@ describe('Smoke Test Suite', function () { await common.type(command); await common.enter(); await app.wait(); - // Default Powershell terminal adds 3 header rows at the top, whereas bash does not. let output = await terminal.getCommandOutput(command); assert.equal(output, 'test'); }); @@ -660,7 +659,7 @@ describe('Smoke Test Suite', function () { const res = await tasks.getOutputResult(); assert.equal(res, '✖ 6 problems (6 errors, 0 warnings)'); }); - + it(`is able to select 'Git' output`, async function () { await tasks.build(); await app.wait(); @@ -674,7 +673,7 @@ describe('Smoke Test Suite', function () { assert.ok(await tasks.firstOutputLineEndsWith('index.js')); }); - it(`verifies build errors are reflected in 'Problems View'`, async function () { + it(`verifies build errors are reflected in 'Problems View'`, async function () { await tasks.build(); await app.wait(); await tasks.openProblemsView(); @@ -717,9 +716,9 @@ describe('Smoke Test Suite', function () { await extensions.installFirstResult(); await app.wait(); await extensions.getFirstReloadText(); - + await app.stop(); - await app.wait(); // wait until all resources are released (e.g. locked local storage) + await app.wait(); // wait until all resources are released (e.g. locked local storage) await app.start(); await extensions.selectMinimalIconsTheme(); const x = await extensions.verifyFolderIconAppearance(); @@ -739,13 +738,14 @@ describe('Smoke Test Suite', function () { common.removeDirectory(tempUserDir); await app.start(); - - let expectedTitle = 'Willkommen — vscode-smoketest-express'; - if (process.platform !== 'darwin') { - expectedTitle += ' — Visual Studio Code'; - if (insiders) expectedTitle += ' - Insiders'; - } - assert.equal(await common.getWindowTitle(), expectedTitle); + + // Do not run until experiments are finished over the first-time startup behaviour. + // let expectedTitle = 'Willkommen — vscode-smoketest-express'; + // if (process.platform !== 'darwin') { + // expectedTitle += ' — Visual Studio Code'; + // if (insiders) expectedTitle += ' - Insiders'; + // } + // assert.equal(await common.getWindowTitle(), expectedTitle); let text = await locale.getOpenEditorsText(); assert.equal(text.toLowerCase(), 'geöffnete editoren'); @@ -764,8 +764,8 @@ describe('Smoke Test Suite', function () { await locale.openViewlet(ViewletType.EXTENSIONS); text = await locale.getExtensionsSearchPlaceholder(); - assert.equal(text.toLowerCase(), 'nach extensions in marketplace suchen'); + assert.equal(text.toLowerCase(), 'nach erweiterungen im marketplace suchen'); }); }); - + }); \ No newline at end of file diff --git a/test/smoke/tsconfig.json b/test/smoke/tsconfig.json index 1b0b03c2d67..733c1107e83 100644 --- a/test/smoke/tsconfig.json +++ b/test/smoke/tsconfig.json @@ -18,4 +18,4 @@ "exclude": [ "node_modules" ] -} \ No newline at end of file +} diff --git a/vscode-smoketest-express b/vscode-smoketest-express deleted file mode 160000 index 636dd7a2ff7..00000000000 --- a/vscode-smoketest-express +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 636dd7a2ff71d266c0e015411b47cf5c3a25be5a -- GitLab From b5d3f45e25615d35d816d8f6c5fdd51e81bca0e5 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Wed, 24 May 2017 17:01:41 +0200 Subject: [PATCH 0028/1347] fix typo --- src/vs/platform/update/common/updateIpc.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/platform/update/common/updateIpc.ts b/src/vs/platform/update/common/updateIpc.ts index 169f827d015..0dd76ca51f6 100644 --- a/src/vs/platform/update/common/updateIpc.ts +++ b/src/vs/platform/update/common/updateIpc.ts @@ -74,7 +74,7 @@ export class UpdateChannelClient implements IUpdateService { this._onStateChange.fire(state); // fire subsequent states as they come in from remote - this._onRemoteStateChange(s => this._onStateChange.fire(state)); + this._onRemoteStateChange(state => this._onStateChange.fire(state)); }, onUnexpectedError); } -- GitLab From 76bc3fc157f6b80ca0df3d7ee6e8732c2813d886 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Wed, 24 May 2017 17:07:19 +0200 Subject: [PATCH 0029/1347] fix instantiation service warning --- .../workbench/browser/parts/activitybar/activitybarPart.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts b/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts index 65d97eb7484..4085747c900 100644 --- a/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts +++ b/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts @@ -13,7 +13,7 @@ import * as arrays from 'vs/base/common/arrays'; import { illegalArgument } from 'vs/base/common/errors'; import { Builder, $, Dimension } from 'vs/base/browser/builder'; import { Action } from 'vs/base/common/actions'; -import { ActionsOrientation, ActionBar, IActionItem, Separator, IBaseActionItemOptions } from 'vs/base/browser/ui/actionbar/actionbar'; +import { ActionsOrientation, ActionBar, IActionItem, Separator } from 'vs/base/browser/ui/actionbar/actionbar'; import { ViewletDescriptor } from 'vs/workbench/browser/viewlet'; import { IGlobalActivity, GlobalActivityExtensions, IGlobalActivityRegistry } from 'vs/workbench/browser/activity'; import { Registry } from 'vs/platform/platform'; @@ -51,11 +51,10 @@ class GlobalActivityActionItem extends ActivityActionItem { constructor( action: GlobalActivityAction, - options: IBaseActionItemOptions, @IThemeService themeService: IThemeService, @IContextMenuService protected contextMenuService: IContextMenuService ) { - super(action, options, themeService); + super(action, { draggable: false }, themeService); } onClick(e: MouseEvent): void { -- GitLab From 2b931936098af1b362a947e7ac321ae2f245f236 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 24 May 2017 17:37:22 +0200 Subject: [PATCH 0030/1347] Modularised tests. --- test/smoke/src/mocha-runner.js | 1 + test/smoke/src/spectron/application.ts | 8 +- test/smoke/src/tests.ts | 791 +------------------- test/smoke/src/tests/configuration-views.ts | 57 ++ test/smoke/src/tests/css.ts | 61 ++ test/smoke/src/tests/data-loss.ts | 76 ++ test/smoke/src/tests/data-migration.ts | 98 +++ test/smoke/src/tests/explorer.ts | 42 ++ test/smoke/src/tests/extensions.ts | 57 ++ test/smoke/src/tests/git.ts | 69 ++ test/smoke/src/tests/integrated-terminal.ts | 41 + test/smoke/src/tests/javascript-debug.ts | 44 ++ test/smoke/src/tests/javascript.ts | 86 +++ test/smoke/src/tests/localization.ts | 49 ++ test/smoke/src/tests/search.ts | 73 ++ test/smoke/src/tests/statusbar.ts | 94 +++ test/smoke/src/tests/tasks.ts | 56 ++ 17 files changed, 939 insertions(+), 764 deletions(-) create mode 100644 test/smoke/src/tests/configuration-views.ts create mode 100644 test/smoke/src/tests/css.ts create mode 100644 test/smoke/src/tests/data-loss.ts create mode 100644 test/smoke/src/tests/data-migration.ts create mode 100644 test/smoke/src/tests/explorer.ts create mode 100644 test/smoke/src/tests/extensions.ts create mode 100644 test/smoke/src/tests/git.ts create mode 100644 test/smoke/src/tests/integrated-terminal.ts create mode 100644 test/smoke/src/tests/javascript-debug.ts create mode 100644 test/smoke/src/tests/javascript.ts create mode 100644 test/smoke/src/tests/localization.ts create mode 100644 test/smoke/src/tests/search.ts create mode 100644 test/smoke/src/tests/statusbar.ts create mode 100644 test/smoke/src/tests/tasks.ts diff --git a/test/smoke/src/mocha-runner.js b/test/smoke/src/mocha-runner.js index 2a08adca647..8ea1dd905aa 100644 --- a/test/smoke/src/mocha-runner.js +++ b/test/smoke/src/mocha-runner.js @@ -5,6 +5,7 @@ var Mocha = require('mocha'); var path = require('path'); +var fs = require('fs'); var mocha = new Mocha({ timeout: 360000, diff --git a/test/smoke/src/spectron/application.ts b/test/smoke/src/spectron/application.ts index d1027a1ef70..0c8896bcc8d 100644 --- a/test/smoke/src/spectron/application.ts +++ b/test/smoke/src/spectron/application.ts @@ -9,6 +9,12 @@ import { Screenshot } from "../helpers/screenshot"; var fs = require('fs'); var path = require('path'); +export const LATEST_PATH = process.env.VSCODE_LATEST_PATH; +export const STABLE_PATH = process.env.VSCODE_STABLE_PATH; +export const WORKSPACE_PATH = process.env.SMOKETEST_REPO; +export const USER_DIR = 'test_data/temp_user_dir'; +export const EXTENSIONS_DIR = 'test_data/temp_extensions_dir'; + /** * Wraps Spectron's Application instance with its used methods. */ @@ -17,7 +23,7 @@ export class SpectronApplication { private spectron: Application; private readonly pollTrials = 5; - private readonly pollTimeout = 3; // in secs + private readonly pollTimeout = 3; // in secs private keybindings: any[]; private screenshot: Screenshot; diff --git a/test/smoke/src/tests.ts b/test/smoke/src/tests.ts index 35d6d1f79ac..17ca694e209 100644 --- a/test/smoke/src/tests.ts +++ b/test/smoke/src/tests.ts @@ -3,769 +3,34 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import * as assert from 'assert'; -import { SpectronApplication } from "./spectron/application"; -import { CommonActions } from './areas/common'; -// import { FirstExperience } from './areas/first-experience'; -import { ConfigurationView, ActivityBarPosition } from './areas/configuration-views'; -import { Search } from './areas/search'; -import { CSS, CSSProblem } from './areas/css'; -import { JavaScript } from './areas/javascript'; -import { JavaScriptDebug } from './areas/javascript-debug'; -import { Git } from './areas/git'; -import { IntegratedTerminal } from './areas/integrated-terminal'; -import { StatusBar, StatusBarElement } from './areas/statusBar'; -import { DataLoss } from './areas/data-loss'; -import { Tasks } from './areas/tasks'; -import { Extensions } from './areas/extensions'; -import { Localization, ViewletType } from "./areas/localization"; +import { dataLoss } from "./tests/data-loss"; +import { dataMigration } from "./tests/data-migration"; +import { explorer } from "./tests/explorer"; +import { configurationViews } from "./tests/configuration-views"; +import { search } from "./tests/search"; +import { css } from "./tests/css"; +import { javascript } from "./tests/javascript"; +import { javascriptDebug } from "./tests/javascript-debug"; +import { test_git } from "./tests/git"; +import { integratedTerminal } from "./tests/integrated-terminal"; +import { statusBar } from "./tests/statusbar"; +import { tasks } from "./tests/tasks"; +import { extensions } from "./tests/extensions"; +import { localization } from "./tests/localization"; describe('Smoke Test Suite', function () { - const latestPath = process.env.VSCODE_LATEST_PATH; - const stablePath = process.env.VSCODE_STABLE_PATH; - // const insiders = process.env.VSCODE_EDITION; - const workspacePath = process.env.SMOKETEST_REPO; - const tempUserDir = 'test_data/temp_user_dir'; - const tempExtensionsDir = 'test_data/temp_extensions_dir'; - - let app: SpectronApplication; - let common: CommonActions; - - if (stablePath) { - context('Data Migration', function () { - - afterEach(async function () { - await app.stop(); - return await common.removeDirectory(tempUserDir) - }); - - function setupSpectron(context: Mocha.ITestCallbackContext, appPath: string, workspace?: string[]): void { - app = new SpectronApplication(appPath, context.test.fullTitle(), context.test.currentRetry(), workspace, [`--user-data-dir=${tempUserDir}`]); - common = new CommonActions(app); - } - - it('checks if the Untitled file is restored migrating from stable to latest', async function () { - const textToType = 'Very dirty file'; - - // Setting up stable version - setupSpectron(this, stablePath); - await app.start(); - - await common.newUntitledFile(); - await common.type(textToType); - await app.stop(); - - await app.wait(); // wait until all resources are released (e.g. locked local storage) - - // Checking latest version for the restored state - setupSpectron(this, latestPath); - await app.start(); - - assert.ok(await common.getTab('Untitled-1')); - await common.selectTab('Untitled-1'); - const editorText = await common.getEditorFirstLinePlainText(); - assert.equal(editorText, textToType); - }); - - it('checks if the newly created dirty file is restored migrating from stable to latest', async function () { - const fileName = 'test_data/plainFile', - firstTextPart = 'This is going to be an unsaved file', secondTextPart = '_that is dirty.'; - - // Setting up stable version - setupSpectron(this, stablePath, [fileName]); - await common.removeFile(`${fileName}`); - await app.start(); - - await common.type(firstTextPart); - await common.saveOpenedFile(); - await app.wait(); - await common.type(secondTextPart); - - await app.stop(); - await app.wait(); // wait until all resources are released (e.g. locked local storage) - - // Checking latest version for the restored state - setupSpectron(this, latestPath); - await app.start(); - assert.ok(await common.getTab(fileName.split('/')[1])); - await common.selectTab(fileName.split('/')[1]); - const editorText = await common.getEditorFirstLinePlainText(); - assert.equal(editorText, firstTextPart.concat(secondTextPart)); - - // Cleanup - await common.removeFile(`${fileName}`); - }); - - it('cheks if opened tabs are restored migrating from stable to latest', async function () { - const fileName1 = 'app.js', fileName2 = 'jsconfig.json', fileName3 = 'readme.md'; - setupSpectron(this, stablePath, [workspacePath]); - await app.start(); - await common.openFile(fileName1, true); - await common.openFile(fileName2, true); - await common.openFile(fileName3, true); - await app.stop(); - - setupSpectron(this, latestPath, [workspacePath]); - await app.start(); - assert.ok(await common.getTab(fileName1)); - assert.ok(await common.getTab(fileName2)); - assert.ok(await common.getTab(fileName3)); - }); - }); - } - - context('Data Loss', function () { - let dataLoss: DataLoss; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath], [`--user-data-dir=${tempUserDir}`]); - common = new CommonActions(app); - dataLoss = new DataLoss(app); - await common.removeDirectory(tempUserDir); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it(`verifies that 'hot exit' works for dirty files`, async function () { - const textToType = 'Hello, Code!', fileName = 'readme.md', untitled = 'Untitled-1'; - await common.newUntitledFile(); - await common.type(textToType); - await dataLoss.openExplorerViewlet(); - await common.openFile(fileName, true); - await common.type(textToType); - - await app.stop(); - await app.start(); - - // check tab presence - assert.ok(await common.getTab(untitled)); - assert.ok(await common.getTab(fileName, true)); - // check if they marked as dirty (icon) and active tab is the last opened - assert.ok(await dataLoss.verifyTabIsDirty(untitled)); - assert.ok(await dataLoss.verifyTabIsDirty(fileName, true)); - }); - - it(`verifies that contents of the dirty files are restored after 'hot exit'`, async function () { - // make one dirty file, - // create one untitled file - const textToType = 'Hello, Code!'; - - // create one untitled file - await common.newUntitledFile(); - await app.wait(); - await common.type(textToType); - - // make one dirty file, - await common.openFile('readme.md', true); - await app.wait(); - await common.type(textToType); - - await app.stop(); - await app.start(); - - // check their contents - let fileDirt = await common.getEditorFirstLinePlainText(); - assert.equal(fileDirt, 'Hello, Code'); // ignore '!' as it is a separate , first part is enough - await common.selectTab('Untitled-1'); - fileDirt = await common.getEditorFirstLinePlainText(); - assert.equal(fileDirt, textToType); - }); - }); - - // Do not run until experiments are finished over the first-time startup behaviour. - // context('First User Experience', function () { - // let experience: FirstExperience; - - // beforeEach(async function () { - // app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), undefined, [`--user-data-dir=${tempUserDir}`, `--excludeSwitches=load-component-extension`]); - // common = new CommonActions(app); - // experience = new FirstExperience(app); - - // await common.removeDirectory(tempUserDir); - // return await app.start(); - // }); - // afterEach(async function () { - // return await app.stop(); - // }); - - // it(`verifies if title is set correctly on the clean user-directory startup`, async function () { - // const title = await common.getWindowTitle(); - - // let expectedTitle = 'Welcome'; - // if (process.platform !== 'darwin') { - // expectedTitle += ' — Visual Studio Code'; - // if (insiders) expectedTitle += ' - Insiders'; - // } - - // assert.equal(title, expectedTitle); - // }); - - // it(`verifies if 'Welcome page' tab is presented on the clean user-directory startup`, async function () { - // assert.ok(await experience.getWelcomeTab()); - // }); - // }); - - context('Explorer', function () { - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); - common = new CommonActions(app); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it('quick open search produces correct result', async function () { - await common.openQuickOpen(); - await common.type('.js'); - await app.wait(); - const elCount = await common.getQuickOpenElements(); - assert.equal(elCount, 7); - }); - - it('quick open respects fuzzy matching', async function () { - await common.openQuickOpen(); - await common.type('a.s'); - await app.wait(); - const elCount = await common.getQuickOpenElements(); - assert.equal(elCount, 3); - }); - }); - - context('Configuration and views', function () { - let configView: ConfigurationView; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); - common = new CommonActions(app); - configView = new ConfigurationView(app); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it('turns off editor line numbers and verifies the live change', async function () { - await common.newUntitledFile(); - await app.wait(); - let elements = await configView.getEditorLineNumbers(); - assert.equal(elements.value.length, 1); - await common.addSetting('editor.lineNumbers', 'off'); - await app.wait(); - elements = await configView.getEditorLineNumbers(); - assert.equal(elements.value.length, 0); - }); - - it(`changes 'workbench.action.toggleSidebarPosition' command key binding and verifies it`, async function () { - await configView.enterKeybindingsView() - await common.type('workbench.action.toggleSidebarPosition'); - await app.wait(); - await configView.selectFirstKeybindingsMatch(); - await configView.changeKeybinding(); - await configView.enterBinding(['Control', 'u', 'NULL']); - await common.enter(); - let html = await configView.getActivityBar(ActivityBarPosition.RIGHT); - assert.equal(html, undefined);; - await app.wait(); - await configView.toggleActivityBarPosition(); - html = await configView.getActivityBar(ActivityBarPosition.RIGHT); - assert.ok(html); - }); - }); - - context('Search', function () { - let search: Search; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); - common = new CommonActions(app); - search = new Search(app); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it('searches for body & checks for correct result number', async function () { - const s = search; - await s.openSearchViewlet(); - await s.searchFor('body'); - const result = await s.getResultText(); - assert.equal(result, '7 results in 4 files'); - }); - - it('searches only for *.js files & checks for correct result number', async function () { - const s = search; - await s.openSearchViewlet(); - await s.searchFor('body'); - await s.toggleSearchDetails(); - await s.searchFor('*.js'); - const results = await s.getResultText(); - assert.equal(results, '4 results in 1 file'); - }); - - it('dismisses result & checks for correct result number', async function () { - const s = search; - await s.openSearchViewlet() - await s.searchFor('body'); - await s.hoverOverResultCount(); - await s.dismissResult(); - await app.wait(); - const result = await s.getResultText(); - assert.equal(result, '3 results in 3 files') - }); - - it('replaces first search result with a replace term', async function () { - const s = search; - await s.openSearchViewlet() - await s.searchFor('body'); - await s.toggleReplace(); - await s.setReplaceText('ydob'); - await s.hoverOverResultCount(); - await s.replaceFirstMatch(); - await app.wait(); - await common.saveOpenedFile(); - const result = await s.getResultText(); - assert.equal(result, '3 results in 3 files'); - }); - }); - - context('CSS', function () { - let css: CSS; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); - common = new CommonActions(app); - css = new CSS(app); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it('verifies quick outline', async function () { - await common.openFirstMatchFile('style.css'); - await css.openQuickOutline(); - await app.wait(); - const count = await common.getQuickOpenElements(); - assert.equal(count, 2); - }); - - it('verifies warnings for the empty rule', async function () { - await common.openFirstMatchFile('style.css'); - await common.type('.foo{}'); - await app.wait(); - let warning = await css.getEditorProblem(CSSProblem.WARNING); - assert.ok(warning); - await css.toggleProblemsView(); - warning = await css.getProblemsViewsProblem(CSSProblem.WARNING); - assert.ok(warning); - }); - - it('verifies that warning becomes an error once setting changed', async function () { - await common.addSetting('css.lint.emptyRules', 'error'); - await common.openFirstMatchFile('style.css'); - await common.type('.foo{}'); - await app.wait(); - let error = await css.getEditorProblem(CSSProblem.ERROR); - assert.ok(error); - await css.toggleProblemsView(); - error = await css.getProblemsViewsProblem(CSSProblem.ERROR); - assert.ok(error); - }); - }); - - context('JavaScript', function () { - let js: JavaScript; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); - common = new CommonActions(app); - js = new JavaScript(app); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it('shows correct quick outline', async function () { - await common.openFirstMatchFile('bin/www'); - await js.openQuickOutline(); - await app.wait(); - const symbols = await common.getQuickOpenElements(); - assert.equal(symbols, 12); - }); - - it(`finds 'All References' to 'app'`, async function () { - await common.openFirstMatchFile('bin/www'); - await app.wait(); - await js.findAppReferences(); - const titleCount = await js.getTitleReferencesCount(); - assert.equal(titleCount, 3); - const treeCount = await js.getTreeReferencesCount(); - assert.equal(treeCount, 3); - }); - - it(`renames local 'app' variable`, async function () { - await common.openFirstMatchFile('bin/www'); - - const newVarName = 'newApp'; - await js.renameApp(newVarName); - await common.enter(); - const newName = await js.getNewAppName(); - assert.equal(newName, newVarName); - }); - - it('folds/unfolds the code correctly', async function () { - await common.openFirstMatchFile('bin/www'); - // Fold - await js.toggleFirstCommentFold(); - const foldedIcon = await js.getFirstCommentFoldedIcon(); - assert.ok(foldedIcon); - let nextLineNumber = await js.getNextLineNumberAfterFold(); - assert.equal(nextLineNumber, 7); - // Unfold - await js.toggleFirstCommentFold(); - nextLineNumber = await js.getNextLineNumberAfterFold(); - assert.equal(nextLineNumber, 4); - }); - - it(`verifies that 'Go To Definition' works`, async function () { - await common.openFirstMatchFile('app.js'); - await js.goToExpressDefinition(); - await app.wait(); - assert.ok(await common.getTab('index.d.ts')); - }); - - it(`verifies that 'Peek Definition' works`, async function () { - await common.openFirstMatchFile('app.js'); - await js.peekExpressDefinition(); - const definitionFilename = await js.getPeekExpressResultName(); - assert.equal(definitionFilename, 'index.d.ts'); - }); - }); - - context('Debugging JavaScript', function () { - let jsDebug: JavaScriptDebug; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); - common = new CommonActions(app); - jsDebug = new JavaScriptDebug(app); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it('autodetects program attribute for launch.json', async function () { - await jsDebug.openDebugViewlet(); - await jsDebug.pressConfigureLaunchJson(); - const value = await jsDebug.getProgramConfigValue(); - process.platform === 'win32' ? assert.equal(value, '"${workspaceRoot}\\\\bin\\\\www"') : assert.equal(value, '"${workspaceRoot}/bin/www"'); - }); - - it(`can set a breakpoint and verify if it's set`, async function () { - await common.openFirstMatchFile('index.js'); - await jsDebug.setBreakpointOnLine(6); - const breakpoint = await jsDebug.verifyBreakpointOnLine(6); - assert.ok(breakpoint); - }); - }); - - context('Git', function () { - let git: Git; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); - common = new CommonActions(app); - git = new Git(app, common); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it('verifies current changes are picked up by Git viewlet', async function () { - const changesCount = await git.getScmIconChanges(); - assert.equal(changesCount, 2); - await git.openGitViewlet(); - assert.ok(await git.verifyScmChange('app.js')); - assert.ok(await git.verifyScmChange('launch.json')); - }); - - it(`verifies 'app.js' diff viewer changes`, async function () { - await git.openGitViewlet(); - await common.openFile('app.js'); - const original = await git.getOriginalAppJsBodyVarName(); - assert.equal(original, 'bodyParser'); - const modified = await git.getModifiedAppJsBodyVarName(); - assert.equal(modified, 'ydobParser'); - }); - - it(`stages 'app.js' changes and checks stage count`, async function () { - await git.openGitViewlet(); - await app.wait(); - await git.stageFile('app.js'); - const stagedCount = await git.getStagedCount(); - assert.equal(stagedCount, 1); - - // Return back to unstaged state - await git.unstageFile('app.js'); - }); - - it(`stages, commits change to 'app.js' locally and verifies outgoing change`, async function () { - await git.openGitViewlet(); - await app.wait(); - await git.stageFile('app.js'); - await git.focusOnCommitBox(); - await common.type('Test commit'); - await git.pressCommit(); - const changes = await git.getOutgoingChanges(); - assert.equal(changes, ' 0↓ 1↑'); - }); - }); - - context('Integrated Terminal', function () { - let terminal: IntegratedTerminal; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); - common = new CommonActions(app); - terminal = new IntegratedTerminal(app); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it(`opens terminal, runs 'echo' and verifies the output`, async function () { - const command = 'echo test'; - await terminal.openTerminal(common); - await app.wait(); - await common.type(command); - await common.enter(); - await app.wait(); - let output = await terminal.getCommandOutput(command); - assert.equal(output, 'test'); - }); - }); - - context('Status Bar', function () { - let statusBar: StatusBar; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); - common = new CommonActions(app); - statusBar = new StatusBar(app); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it('verifies presence of all default status bar elements', async function () { - await app.wait(); - assert.ok(await statusBar.isVisible(StatusBarElement.BRANCH_STATUS)); - assert.ok(await statusBar.isVisible(StatusBarElement.FEEDBACK_ICON)); - assert.ok(await statusBar.isVisible(StatusBarElement.SYNC_STATUS)); - assert.ok(await statusBar.isVisible(StatusBarElement.PROBLEMS_STATUS)); - - await common.openFirstMatchFile('app.js'); - assert.ok(await statusBar.isVisible(StatusBarElement.ENCODING_STATUS)); - assert.ok(await statusBar.isVisible(StatusBarElement.EOL_STATUS)); - assert.ok(await statusBar.isVisible(StatusBarElement.INDENTATION_STATUS)); - assert.ok(await statusBar.isVisible(StatusBarElement.LANGUAGE_STATUS)); - assert.ok(await statusBar.isVisible(StatusBarElement.SELECTION_STATUS)); - }); - - it(`verifies that 'quick open' opens when clicking on 'Branch', 'Indentation Status, 'Encoding', 'EOL' and 'Language' status elements`, async function () { - await app.wait(); - await statusBar.clickOn(StatusBarElement.BRANCH_STATUS); - assert.ok(await statusBar.isQuickOpenWidgetVisible()); - await common.closeQuickOpen(); - - await common.openFirstMatchFile('app.js'); - await statusBar.clickOn(StatusBarElement.INDENTATION_STATUS); - assert.ok(await statusBar.isQuickOpenWidgetVisible()); - await common.closeQuickOpen(); - await statusBar.clickOn(StatusBarElement.ENCODING_STATUS); - assert.ok(await statusBar.isQuickOpenWidgetVisible()); - await common.closeQuickOpen(); - await statusBar.clickOn(StatusBarElement.EOL_STATUS); - assert.ok(await statusBar.isQuickOpenWidgetVisible()); - await common.closeQuickOpen(); - await statusBar.clickOn(StatusBarElement.LANGUAGE_STATUS); - assert.ok(await statusBar.isQuickOpenWidgetVisible()); - await common.closeQuickOpen(); - }); - - it(`verifies that 'Problems View' appears when clicking on 'Problems' status element`, async function () { - await statusBar.clickOn(StatusBarElement.PROBLEMS_STATUS); - assert.ok(await statusBar.getProblemsView()); - }); - - it(`verifies that 'Tweet us feedback' pop-up appears when clicking on 'Feedback' icon`, async function () { - await statusBar.clickOn(StatusBarElement.FEEDBACK_ICON); - assert.ok(await statusBar.getFeedbackView()); - }); - - it(`checks if 'Go to Line' works if called from the status bar`, async function () { - await common.openFirstMatchFile('app.js'); - await statusBar.clickOn(StatusBarElement.SELECTION_STATUS); - const lineNumber = 15; - await common.type(lineNumber.toString()); - await common.enter(); - assert.ok(await statusBar.getEditorHighlightedLine(lineNumber)); - }); - - it(`verifies if changing EOL is reflected in the status bar`, async function () { - await common.openFirstMatchFile('app.js'); - await statusBar.clickOn(StatusBarElement.EOL_STATUS); - await common.selectNextQuickOpenElement(); - await common.enter(); - const currentEOL = await statusBar.getEOLMode(); - assert.equal(currentEOL, 'CRLF'); - }); - }); - - context('Tasks', function () { - let tasks: Tasks; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); - tasks = new Tasks(app); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it('verifies that build task produces 6 errors', async function () { - await tasks.build(); - const res = await tasks.getOutputResult(); - assert.equal(res, '✖ 6 problems (6 errors, 0 warnings)'); - }); - - it(`is able to select 'Git' output`, async function () { - await tasks.build(); - await app.wait(); - await tasks.selectOutputViewType('Git'); - const viewType = await tasks.getOutputViewType(); - assert.equal(viewType, 'Git'); - }); - - it('ensures that build task produces errors in index.js', async function () { - await tasks.build(); - assert.ok(await tasks.firstOutputLineEndsWith('index.js')); - }); - - it(`verifies build errors are reflected in 'Problems View'`, async function () { - await tasks.build(); - await app.wait(); - await tasks.openProblemsView(); - const problemName = await tasks.getProblemsViewFirstElementName(); - assert.equal(problemName, 'index.js'); - const problemsCount = await tasks.getProblemsViewFirstElementCount(); - assert.equal(problemsCount, '6'); - }); - }); - - context('Extensions', function () { - let extensions: Extensions; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath], [`--extensions-dir=${tempExtensionsDir}`]); - common = new CommonActions(app); - extensions = new Extensions(app, common); - await common.removeDirectory(tempExtensionsDir); - - return await app.start(); - }); - afterEach(async function () { - await app.stop(); - return await common.removeDirectory(tempExtensionsDir); - }); - - it(`installs 'vscode-icons' extension and verifies reload is prompted`, async function () { - await extensions.openExtensionsViewlet(); - await extensions.searchForExtension('vscode-icons'); - await app.wait(); - await extensions.installFirstResult(); - await app.wait(); - assert.ok(await extensions.getFirstReloadText()); - }); - - it(`installs an extension and checks if it works on restart`, async function () { - await extensions.openExtensionsViewlet(); - await extensions.searchForExtension('vscode-icons'); - await app.wait(); - await extensions.installFirstResult(); - await app.wait(); - await extensions.getFirstReloadText(); - - await app.stop(); - await app.wait(); // wait until all resources are released (e.g. locked local storage) - await app.start(); - await extensions.selectMinimalIconsTheme(); - const x = await extensions.verifyFolderIconAppearance(); - assert.ok(x); - }); - }); - - context('Localization', function () { - afterEach(async function () { - return await app.stop(); - }); - - it(`starts with 'DE' locale and verifies title and viewlets text is in German`, async function () { - app = new SpectronApplication(latestPath, this.test.fullTitle(), this.test.currentRetry(), [workspacePath, '--locale=DE'], [`--user-data-dir=${tempUserDir}`]); - common = new CommonActions(app); - const locale = new Localization(app); - common.removeDirectory(tempUserDir); - - await app.start(); - - // Do not run until experiments are finished over the first-time startup behaviour. - // let expectedTitle = 'Willkommen — vscode-smoketest-express'; - // if (process.platform !== 'darwin') { - // expectedTitle += ' — Visual Studio Code'; - // if (insiders) expectedTitle += ' - Insiders'; - // } - // assert.equal(await common.getWindowTitle(), expectedTitle); - - let text = await locale.getOpenEditorsText(); - assert.equal(text.toLowerCase(), 'geöffnete editoren'); - - await locale.openViewlet(ViewletType.SEARCH); - text = await locale.getOpenedViewletTitle() - assert.equal(text.toLowerCase(), 'suchen'); - - await locale.openViewlet(ViewletType.SCM); - text = await locale.getOpenedViewletTitle(); - assert.equal(text.toLowerCase(), 'quellcodeverwaltung: git'); - - await locale.openViewlet(ViewletType.DEBUG); - text = await locale.getOpenedViewletTitle(); - assert.equal(text.toLowerCase(), 'debuggen'); - - await locale.openViewlet(ViewletType.EXTENSIONS); - text = await locale.getExtensionsSearchPlaceholder(); - assert.equal(text.toLowerCase(), 'nach erweiterungen im marketplace suchen'); - }); - }); - + dataMigration(); + dataLoss(); + explorer(); + configurationViews(); + search(); + css(); + javascript(); + javascriptDebug(); + test_git(); + integratedTerminal(); + statusBar(); + tasks(); + extensions(); + localization(); }); \ No newline at end of file diff --git a/test/smoke/src/tests/configuration-views.ts b/test/smoke/src/tests/configuration-views.ts new file mode 100644 index 00000000000..2f61f3337fb --- /dev/null +++ b/test/smoke/src/tests/configuration-views.ts @@ -0,0 +1,57 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { ConfigurationView, ActivityBarPosition } from "../areas/configuration-views"; + +let app: SpectronApplication; +let common: CommonActions; + +export function configurationViews() { + context('Configuration and views', function () { + let configView: ConfigurationView; + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); + common = new CommonActions(app); + configView = new ConfigurationView(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('turns off editor line numbers and verifies the live change', async function () { + await common.newUntitledFile(); + await app.wait(); + let elements = await configView.getEditorLineNumbers(); + assert.equal(elements.value.length, 1); + await common.addSetting('editor.lineNumbers', 'off'); + await app.wait(); + elements = await configView.getEditorLineNumbers(); + assert.equal(elements.value.length, 0); + }); + + it(`changes 'workbench.action.toggleSidebarPosition' command key binding and verifies it`, async function () { + await configView.enterKeybindingsView(); + await common.type('workbench.action.toggleSidebarPosition'); + await app.wait(); + await configView.selectFirstKeybindingsMatch(); + await configView.changeKeybinding(); + await configView.enterBinding(['Control', 'u', 'NULL']); + await common.enter(); + let html = await configView.getActivityBar(ActivityBarPosition.RIGHT); + assert.equal(html, undefined);; + await app.wait(); + await configView.toggleActivityBarPosition(); + html = await configView.getActivityBar(ActivityBarPosition.RIGHT); + assert.ok(html); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/css.ts b/test/smoke/src/tests/css.ts new file mode 100644 index 00000000000..01a0bddbe25 --- /dev/null +++ b/test/smoke/src/tests/css.ts @@ -0,0 +1,61 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { CSS, CSSProblem } from '../areas/css'; + +let app: SpectronApplication; +let common: CommonActions; + +export function css() { + context('CSS', function () { + let css: CSS; + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); + common = new CommonActions(app); + css = new CSS(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('verifies quick outline', async function () { + await common.openFirstMatchFile('style.css'); + await css.openQuickOutline(); + await app.wait(); + const count = await common.getQuickOpenElements(); + assert.equal(count, 2); + }); + + it('verifies warnings for the empty rule', async function () { + await common.openFirstMatchFile('style.css'); + await common.type('.foo{}'); + await app.wait(); + let warning = await css.getEditorProblem(CSSProblem.WARNING); + assert.ok(warning); + await css.toggleProblemsView(); + warning = await css.getProblemsViewsProblem(CSSProblem.WARNING); + assert.ok(warning); + }); + + it('verifies that warning becomes an error once setting changed', async function () { + await common.addSetting('css.lint.emptyRules', 'error'); + await common.openFirstMatchFile('style.css'); + await common.type('.foo{}'); + await app.wait(); + let error = await css.getEditorProblem(CSSProblem.ERROR); + assert.ok(error); + await css.toggleProblemsView(); + error = await css.getProblemsViewsProblem(CSSProblem.ERROR); + assert.ok(error); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/data-loss.ts b/test/smoke/src/tests/data-loss.ts new file mode 100644 index 00000000000..4be1635cfce --- /dev/null +++ b/test/smoke/src/tests/data-loss.ts @@ -0,0 +1,76 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, USER_DIR, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { DataLoss } from "../areas/data-loss"; + +let app: SpectronApplication; +let common: CommonActions; +let dl: DataLoss; + +export function dataLoss() { + context('Data Loss', function () { + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH], [`--user-data-dir=${USER_DIR}`]); + common = new CommonActions(app); + dl = new DataLoss(app); + await common.removeDirectory(USER_DIR); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it(`verifies that 'hot exit' works for dirty files`, async function () { + const textToType = 'Hello, Code!', fileName = 'readme.md', untitled = 'Untitled-1'; + await common.newUntitledFile(); + await common.type(textToType); + await dl.openExplorerViewlet(); + await common.openFile(fileName, true); + await common.type(textToType); + + await app.stop(); + await app.start(); + + // check tab presence + assert.ok(await common.getTab(untitled)); + assert.ok(await common.getTab(fileName, true)); + // check if they marked as dirty (icon) and active tab is the last opened + assert.ok(await dl.verifyTabIsDirty(untitled)); + assert.ok(await dl.verifyTabIsDirty(fileName, true)); + }); + + it(`verifies that contents of the dirty files are restored after 'hot exit'`, async function () { + // make one dirty file, + // create one untitled file + const textToType = 'Hello, Code!'; + + // create one untitled file + await common.newUntitledFile(); + await app.wait(); + await common.type(textToType); + + // make one dirty file, + await common.openFile('readme.md', true); + await app.wait(); + await common.type(textToType); + + await app.stop(); + await app.start(); + + // check their contents + let fileDirt = await common.getEditorFirstLinePlainText(); + assert.equal(fileDirt, 'Hello, Code'); // ignore '!' as it is a separate , first part is enough + await common.selectTab('Untitled-1'); + fileDirt = await common.getEditorFirstLinePlainText(); + assert.equal(fileDirt, textToType); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/data-migration.ts b/test/smoke/src/tests/data-migration.ts new file mode 100644 index 00000000000..0dba58deccb --- /dev/null +++ b/test/smoke/src/tests/data-migration.ts @@ -0,0 +1,98 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, USER_DIR, STABLE_PATH, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; + +let app: SpectronApplication; +let common: CommonActions; + +export function dataMigration() { + if (!STABLE_PATH) { + return; + } + context('Data Migration', function () { + + afterEach(async function () { + await app.stop(); + return await common.removeDirectory(USER_DIR) + }); + + function setupSpectron(context: Mocha.ITestCallbackContext, appPath: string, workspace?: string[]): void { + app = new SpectronApplication(appPath, context.test.fullTitle(), context.test.currentRetry(), workspace, [`--user-data-dir=${USER_DIR}`]); + common = new CommonActions(app); + } + + it('checks if the Untitled file is restored migrating from stable to latest', async function () { + const textToType = 'Very dirty file'; + + // Setting up stable version + setupSpectron(this, STABLE_PATH); + await app.start(); + + await common.newUntitledFile(); + await common.type(textToType); + await app.stop(); + + await app.wait(); // wait until all resources are released (e.g. locked local storage) + + // Checking latest version for the restored state + setupSpectron(this, LATEST_PATH); + await app.start(); + + assert.ok(await common.getTab('Untitled-1')); + await common.selectTab('Untitled-1'); + const editorText = await common.getEditorFirstLinePlainText(); + assert.equal(editorText, textToType); + }); + + it('checks if the newly created dirty file is restored migrating from stable to latest', async function () { + const fileName = 'test_data/plainFile', + firstTextPart = 'This is going to be an unsaved file', secondTextPart = '_that is dirty.'; + + // Setting up stable version + setupSpectron(this, STABLE_PATH, [fileName]); + await common.removeFile(`${fileName}`); + await app.start(); + + await common.type(firstTextPart); + await common.saveOpenedFile(); + await app.wait(); + await common.type(secondTextPart); + + await app.stop(); + await app.wait(); // wait until all resources are released (e.g. locked local storage) + + // Checking latest version for the restored state + setupSpectron(this, LATEST_PATH); + await app.start(); + assert.ok(await common.getTab(fileName.split('/')[1])); + await common.selectTab(fileName.split('/')[1]); + const editorText = await common.getEditorFirstLinePlainText(); + assert.equal(editorText, firstTextPart.concat(secondTextPart)); + + // Cleanup + await common.removeFile(`${fileName}`); + }); + + it('cheks if opened tabs are restored migrating from stable to latest', async function () { + const fileName1 = 'app.js', fileName2 = 'jsconfig.json', fileName3 = 'readme.md'; + setupSpectron(this, STABLE_PATH, [WORKSPACE_PATH]); + await app.start(); + await common.openFile(fileName1, true); + await common.openFile(fileName2, true); + await common.openFile(fileName3, true); + await app.stop(); + + setupSpectron(this, LATEST_PATH, [WORKSPACE_PATH]); + await app.start(); + assert.ok(await common.getTab(fileName1)); + assert.ok(await common.getTab(fileName2)); + assert.ok(await common.getTab(fileName3)); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/explorer.ts b/test/smoke/src/tests/explorer.ts new file mode 100644 index 00000000000..83c2d114196 --- /dev/null +++ b/test/smoke/src/tests/explorer.ts @@ -0,0 +1,42 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; + +let app: SpectronApplication; +let common: CommonActions; + +export function explorer() { + context('Explorer', function () { + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); + common = new CommonActions(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('quick open search produces correct result', async function () { + await common.openQuickOpen(); + await common.type('.js'); + await app.wait(); + const elCount = await common.getQuickOpenElements(); + assert.equal(elCount, 7); + }); + + it('quick open respects fuzzy matching', async function () { + await common.openQuickOpen(); + await common.type('a.s'); + await app.wait(); + const elCount = await common.getQuickOpenElements(); + assert.equal(elCount, 3); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/extensions.ts b/test/smoke/src/tests/extensions.ts new file mode 100644 index 00000000000..a545dd7c674 --- /dev/null +++ b/test/smoke/src/tests/extensions.ts @@ -0,0 +1,57 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH, EXTENSIONS_DIR } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { Extensions } from "../areas/extensions"; + +let app: SpectronApplication; +let common: CommonActions; + +export function extensions() { + context('Extensions', function () { + let extensions: Extensions; + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH], [`--extensions-dir=${EXTENSIONS_DIR}`]); + common = new CommonActions(app); + extensions = new Extensions(app, common); + await common.removeDirectory(EXTENSIONS_DIR); + + return await app.start(); + }); + afterEach(async function () { + await app.stop(); + return await common.removeDirectory(EXTENSIONS_DIR); + }); + + it(`installs 'vscode-icons' extension and verifies reload is prompted`, async function () { + await extensions.openExtensionsViewlet(); + await extensions.searchForExtension('vscode-icons'); + await app.wait(); + await extensions.installFirstResult(); + await app.wait(); + assert.ok(await extensions.getFirstReloadText()); + }); + + it(`installs an extension and checks if it works on restart`, async function () { + await extensions.openExtensionsViewlet(); + await extensions.searchForExtension('vscode-icons'); + await app.wait(); + await extensions.installFirstResult(); + await app.wait(); + await extensions.getFirstReloadText(); + + await app.stop(); + await app.wait(); // wait until all resources are released (e.g. locked local storage) + await app.start(); + await extensions.selectMinimalIconsTheme(); + const x = await extensions.verifyFolderIconAppearance(); + assert.ok(x); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/git.ts b/test/smoke/src/tests/git.ts new file mode 100644 index 00000000000..11d568c7f8b --- /dev/null +++ b/test/smoke/src/tests/git.ts @@ -0,0 +1,69 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { Git } from "../areas/git"; + +let app: SpectronApplication; +let common: CommonActions; + +export function test_git() { + context('Git', function () { + let git: Git; + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); + common = new CommonActions(app); + git = new Git(app, common); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('verifies current changes are picked up by Git viewlet', async function () { + const changesCount = await git.getScmIconChanges(); + assert.equal(changesCount, 2); + await git.openGitViewlet(); + assert.ok(await git.verifyScmChange('app.js')); + assert.ok(await git.verifyScmChange('launch.json')); + }); + + it(`verifies 'app.js' diff viewer changes`, async function () { + await git.openGitViewlet(); + await common.openFile('app.js'); + const original = await git.getOriginalAppJsBodyVarName(); + assert.equal(original, 'bodyParser'); + const modified = await git.getModifiedAppJsBodyVarName(); + assert.equal(modified, 'ydobParser'); + }); + + it(`stages 'app.js' changes and checks stage count`, async function () { + await git.openGitViewlet(); + await app.wait(); + await git.stageFile('app.js'); + const stagedCount = await git.getStagedCount(); + assert.equal(stagedCount, 1); + + // Return back to unstaged state + await git.unstageFile('app.js'); + }); + + it(`stages, commits change to 'app.js' locally and verifies outgoing change`, async function () { + await git.openGitViewlet(); + await app.wait(); + await git.stageFile('app.js'); + await git.focusOnCommitBox(); + await common.type('Test commit'); + await git.pressCommit(); + const changes = await git.getOutgoingChanges(); + assert.equal(changes, ' 0↓ 1↑'); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/integrated-terminal.ts b/test/smoke/src/tests/integrated-terminal.ts new file mode 100644 index 00000000000..95925d03f96 --- /dev/null +++ b/test/smoke/src/tests/integrated-terminal.ts @@ -0,0 +1,41 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { IntegratedTerminal } from "../areas/integrated-terminal"; + +let app: SpectronApplication; +let common: CommonActions; + +export function integratedTerminal() { + context('Integrated Terminal', function () { + let terminal: IntegratedTerminal; + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); + common = new CommonActions(app); + terminal = new IntegratedTerminal(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it(`opens terminal, runs 'echo' and verifies the output`, async function () { + const command = 'echo test'; + await terminal.openTerminal(common); + await app.wait(); + await common.type(command); + await common.enter(); + await app.wait(); + let output = await terminal.getCommandOutput(command); + assert.equal(output, 'test'); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/javascript-debug.ts b/test/smoke/src/tests/javascript-debug.ts new file mode 100644 index 00000000000..7f85ee4f49c --- /dev/null +++ b/test/smoke/src/tests/javascript-debug.ts @@ -0,0 +1,44 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { JavaScriptDebug } from "../areas/javascript-debug"; + +let app: SpectronApplication; +let common: CommonActions; + +export function javascriptDebug() { + context('Debugging JavaScript', function () { + let jsDebug: JavaScriptDebug; + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); + common = new CommonActions(app); + jsDebug = new JavaScriptDebug(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('autodetects program attribute for launch.json', async function () { + await jsDebug.openDebugViewlet(); + await jsDebug.pressConfigureLaunchJson(); + const value = await jsDebug.getProgramConfigValue(); + process.platform === 'win32' ? assert.equal(value, '"${workspaceRoot}\\\\bin\\\\www"') : assert.equal(value, '"${workspaceRoot}/bin/www"'); + }); + + it(`can set a breakpoint and verify if it's set`, async function () { + await common.openFirstMatchFile('index.js'); + await jsDebug.setBreakpointOnLine(6); + const breakpoint = await jsDebug.verifyBreakpointOnLine(6); + assert.ok(breakpoint); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/javascript.ts b/test/smoke/src/tests/javascript.ts new file mode 100644 index 00000000000..2d82fde2d4b --- /dev/null +++ b/test/smoke/src/tests/javascript.ts @@ -0,0 +1,86 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { JavaScript } from "../areas/javascript"; + +let app: SpectronApplication; +let common: CommonActions; + +export function javascript() { + context('JavaScript', function () { + let js: JavaScript; + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); + common = new CommonActions(app); + js = new JavaScript(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('shows correct quick outline', async function () { + await common.openFirstMatchFile('bin/www'); + await js.openQuickOutline(); + await app.wait(); + const symbols = await common.getQuickOpenElements(); + assert.equal(symbols, 12); + }); + + it(`finds 'All References' to 'app'`, async function () { + await common.openFirstMatchFile('bin/www'); + await app.wait(); + await js.findAppReferences(); + const titleCount = await js.getTitleReferencesCount(); + assert.equal(titleCount, 3); + const treeCount = await js.getTreeReferencesCount(); + assert.equal(treeCount, 3); + }); + + it(`renames local 'app' variable`, async function () { + await common.openFirstMatchFile('bin/www'); + + const newVarName = 'newApp'; + await js.renameApp(newVarName); + await common.enter(); + const newName = await js.getNewAppName(); + assert.equal(newName, newVarName); + }); + + it('folds/unfolds the code correctly', async function () { + await common.openFirstMatchFile('bin/www'); + // Fold + await js.toggleFirstCommentFold(); + const foldedIcon = await js.getFirstCommentFoldedIcon(); + assert.ok(foldedIcon); + let nextLineNumber = await js.getNextLineNumberAfterFold(); + assert.equal(nextLineNumber, 7); + // Unfold + await js.toggleFirstCommentFold(); + nextLineNumber = await js.getNextLineNumberAfterFold(); + assert.equal(nextLineNumber, 4); + }); + + it(`verifies that 'Go To Definition' works`, async function () { + await common.openFirstMatchFile('app.js'); + await js.goToExpressDefinition(); + await app.wait(); + assert.ok(await common.getTab('index.d.ts')); + }); + + it(`verifies that 'Peek Definition' works`, async function () { + await common.openFirstMatchFile('app.js'); + await js.peekExpressDefinition(); + const definitionFilename = await js.getPeekExpressResultName(); + assert.equal(definitionFilename, 'index.d.ts'); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/localization.ts b/test/smoke/src/tests/localization.ts new file mode 100644 index 00000000000..35a72186e82 --- /dev/null +++ b/test/smoke/src/tests/localization.ts @@ -0,0 +1,49 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH, USER_DIR } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { Localization, ViewletType } from "../areas/localization"; + +let app: SpectronApplication; +let common: CommonActions; + +export function localization() { + context('Localization', function () { + afterEach(async function () { + return await app.stop(); + }); + + it(`starts with 'DE' locale and verifies title and viewlets text is in German`, async function () { + app = new SpectronApplication(LATEST_PATH, this.test.fullTitle(), this.test.currentRetry(), [WORKSPACE_PATH, '--locale=DE'], [`--user-data-dir=${USER_DIR}`]); + common = new CommonActions(app); + const locale = new Localization(app); + common.removeDirectory(USER_DIR); + + await app.start(); + + let text = await locale.getOpenEditorsText(); + assert.equal(text.toLowerCase(), 'geöffnete editoren'); + + await locale.openViewlet(ViewletType.SEARCH); + text = await locale.getOpenedViewletTitle(); + assert.equal(text.toLowerCase(), 'suchen'); + + await locale.openViewlet(ViewletType.SCM); + text = await locale.getOpenedViewletTitle(); + assert.equal(text.toLowerCase(), 'quellcodeverwaltung: git'); + + await locale.openViewlet(ViewletType.DEBUG); + text = await locale.getOpenedViewletTitle(); + assert.equal(text.toLowerCase(), 'debuggen'); + + await locale.openViewlet(ViewletType.EXTENSIONS); + text = await locale.getExtensionsSearchPlaceholder(); + assert.equal(text.toLowerCase(), 'nach erweiterungen im marketplace suchen'); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/search.ts b/test/smoke/src/tests/search.ts new file mode 100644 index 00000000000..8ab012c9b08 --- /dev/null +++ b/test/smoke/src/tests/search.ts @@ -0,0 +1,73 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { Search } from "../areas/search"; + +let app: SpectronApplication; +let common: CommonActions; + +export function search() { + context('Search', function () { + let search: Search; + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); + common = new CommonActions(app); + search = new Search(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('searches for body & checks for correct result number', async function () { + const s = search; + await s.openSearchViewlet(); + await s.searchFor('body'); + const result = await s.getResultText(); + assert.equal(result, '7 results in 4 files'); + }); + + it('searches only for *.js files & checks for correct result number', async function () { + const s = search; + await s.openSearchViewlet(); + await s.searchFor('body'); + await s.toggleSearchDetails(); + await s.searchFor('*.js'); + const results = await s.getResultText(); + assert.equal(results, '4 results in 1 file'); + }); + + it('dismisses result & checks for correct result number', async function () { + const s = search; + await s.openSearchViewlet(); + await s.searchFor('body'); + await s.hoverOverResultCount(); + await s.dismissResult(); + await app.wait(); + const result = await s.getResultText(); + assert.equal(result, '3 results in 3 files'); + }); + + it('replaces first search result with a replace term', async function () { + const s = search; + await s.openSearchViewlet(); + await s.searchFor('body'); + await s.toggleReplace(); + await s.setReplaceText('ydob'); + await s.hoverOverResultCount(); + await s.replaceFirstMatch(); + await app.wait(); + await common.saveOpenedFile(); + const result = await s.getResultText(); + assert.equal(result, '3 results in 3 files'); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/statusbar.ts b/test/smoke/src/tests/statusbar.ts new file mode 100644 index 00000000000..6fbcf6472c4 --- /dev/null +++ b/test/smoke/src/tests/statusbar.ts @@ -0,0 +1,94 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { StatusBarElement, StatusBar } from "../areas/statusBar"; + +let app: SpectronApplication; +let common: CommonActions; + +export function statusBar() { + context('Status Bar', function () { + let statusBar: StatusBar; + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); + common = new CommonActions(app); + statusBar = new StatusBar(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('verifies presence of all default status bar elements', async function () { + await app.wait(); + assert.ok(await statusBar.isVisible(StatusBarElement.BRANCH_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.FEEDBACK_ICON)); + assert.ok(await statusBar.isVisible(StatusBarElement.SYNC_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.PROBLEMS_STATUS)); + + await common.openFirstMatchFile('app.js'); + assert.ok(await statusBar.isVisible(StatusBarElement.ENCODING_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.EOL_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.INDENTATION_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.LANGUAGE_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.SELECTION_STATUS)); + }); + + it(`verifies that 'quick open' opens when clicking on 'Branch', 'Indentation Status, 'Encoding', 'EOL' and 'Language' status elements`, async function () { + await app.wait(); + await statusBar.clickOn(StatusBarElement.BRANCH_STATUS); + assert.ok(await statusBar.isQuickOpenWidgetVisible()); + await common.closeQuickOpen(); + + await common.openFirstMatchFile('app.js'); + await statusBar.clickOn(StatusBarElement.INDENTATION_STATUS); + assert.ok(await statusBar.isQuickOpenWidgetVisible()); + await common.closeQuickOpen(); + await statusBar.clickOn(StatusBarElement.ENCODING_STATUS); + assert.ok(await statusBar.isQuickOpenWidgetVisible()); + await common.closeQuickOpen(); + await statusBar.clickOn(StatusBarElement.EOL_STATUS); + assert.ok(await statusBar.isQuickOpenWidgetVisible()); + await common.closeQuickOpen(); + await statusBar.clickOn(StatusBarElement.LANGUAGE_STATUS); + assert.ok(await statusBar.isQuickOpenWidgetVisible()); + await common.closeQuickOpen(); + }); + + it(`verifies that 'Problems View' appears when clicking on 'Problems' status element`, async function () { + await statusBar.clickOn(StatusBarElement.PROBLEMS_STATUS); + assert.ok(await statusBar.getProblemsView()); + }); + + it(`verifies that 'Tweet us feedback' pop-up appears when clicking on 'Feedback' icon`, async function () { + await statusBar.clickOn(StatusBarElement.FEEDBACK_ICON); + assert.ok(await statusBar.getFeedbackView()); + }); + + it(`checks if 'Go to Line' works if called from the status bar`, async function () { + await common.openFirstMatchFile('app.js'); + await statusBar.clickOn(StatusBarElement.SELECTION_STATUS); + const lineNumber = 15; + await common.type(lineNumber.toString()); + await common.enter(); + assert.ok(await statusBar.getEditorHighlightedLine(lineNumber)); + }); + + it(`verifies if changing EOL is reflected in the status bar`, async function () { + await common.openFirstMatchFile('app.js'); + await statusBar.clickOn(StatusBarElement.EOL_STATUS); + await common.selectNextQuickOpenElement(); + await common.enter(); + const currentEOL = await statusBar.getEOLMode(); + assert.equal(currentEOL, 'CRLF'); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/tasks.ts b/test/smoke/src/tests/tasks.ts new file mode 100644 index 00000000000..c020aceac0c --- /dev/null +++ b/test/smoke/src/tests/tasks.ts @@ -0,0 +1,56 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { Tasks } from "../areas/tasks"; + +let app: SpectronApplication; + +export function tasks() { + context('Tasks', function () { + let tasks: Tasks; + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); + tasks = new Tasks(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('verifies that build task produces 6 errors', async function () { + await tasks.build(); + const res = await tasks.getOutputResult(); + assert.equal(res, '✖ 6 problems (6 errors, 0 warnings)'); + }); + + it(`is able to select 'Git' output`, async function () { + await tasks.build(); + await app.wait(); + await tasks.selectOutputViewType('Git'); + const viewType = await tasks.getOutputViewType(); + assert.equal(viewType, 'Git'); + }); + + it('ensures that build task produces errors in index.js', async function () { + await tasks.build(); + assert.ok(await tasks.firstOutputLineEndsWith('index.js')); + }); + + it(`verifies build errors are reflected in 'Problems View'`, async function () { + await tasks.build(); + await app.wait(); + await tasks.openProblemsView(); + const problemName = await tasks.getProblemsViewFirstElementName(); + assert.equal(problemName, 'index.js'); + const problemsCount = await tasks.getProblemsViewFirstElementCount(); + assert.equal(problemsCount, '6'); + }); + }); +} \ No newline at end of file -- GitLab From 7236f4a191477510fa4ea0e1771848fd54680386 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 24 May 2017 13:54:05 -0700 Subject: [PATCH 0031/1347] Fix 27195 Make sure we handle the case of `/**/` properly in json files --- extensions/json/syntaxes/JSON.tmLanguage | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/json/syntaxes/JSON.tmLanguage b/extensions/json/syntaxes/JSON.tmLanguage index 9d6a24cc16a..507eb03ec93 100644 --- a/extensions/json/syntaxes/JSON.tmLanguage +++ b/extensions/json/syntaxes/JSON.tmLanguage @@ -98,7 +98,7 @@ begin - /\*\* + /\*\*(?!/) captures 0 -- GitLab From 755d45a10785bf5008f27e10a8d607c4443dbf0c Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Wed, 24 May 2017 20:04:00 -0700 Subject: [PATCH 0032/1347] Clean up termianl imports --- .../electron-browser/terminal.contribution.ts | 4 +- .../electron-browser/terminalActions.ts | 4 +- .../electron-browser/terminalColorRegistry.ts | 2 +- .../electron-browser/terminalInstance.ts | 46 +++++++++---------- .../electron-browser/terminalPanel.ts | 26 +++++------ 5 files changed, 41 insertions(+), 41 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts index 6becf5badb0..c4e3fc01471 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts @@ -7,9 +7,10 @@ import 'vs/css!./media/scrollbar'; import 'vs/css!./media/terminal'; import 'vs/css!./media/xterm'; import 'vs/css!./media/widgets'; +import * as debugActions from 'vs/workbench/parts/debug/browser/debugActions'; +import * as nls from 'vs/nls'; import * as panel from 'vs/workbench/browser/panel'; import * as platform from 'vs/base/common/platform'; -import nls = require('vs/nls'); import { Extensions, IConfigurationRegistry } from 'vs/platform/configuration/common/configurationRegistry'; import { GlobalQuickOpenAction } from 'vs/workbench/browser/parts/quickopen/quickopen.contribution'; import { ITerminalService, KEYBINDING_CONTEXT_TERMINAL_FOCUS, KEYBINDING_CONTEXT_TERMINAL_TEXT_SELECTED, TERMINAL_PANEL_ID, TERMINAL_DEFAULT_RIGHT_CLICK_COPY_PASTE, TerminalCursorStyle } from 'vs/workbench/parts/terminal/common/terminal'; @@ -24,7 +25,6 @@ import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; import { TerminalService } from 'vs/workbench/parts/terminal/electron-browser/terminalService'; import { ToggleTabFocusModeAction } from 'vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode'; import { registerSingleton } from 'vs/platform/instantiation/common/extensions'; -import debugActions = require('vs/workbench/parts/debug/browser/debugActions'); import { KeybindingsRegistry } from 'vs/platform/keybinding/common/keybindingsRegistry'; import { OpenNextRecentlyUsedEditorInGroupAction, OpenPreviousRecentlyUsedEditorInGroupAction, FocusActiveGroupAction, FocusFirstGroupAction, FocusSecondGroupAction, FocusThirdGroupAction } from 'vs/workbench/browser/parts/editor/editorActions'; import { EDITOR_FONT_DEFAULTS } from "vs/editor/common/config/editorOptions"; diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts index 58cd361fd34..3b62f9642ed 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts @@ -3,8 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import nls = require('vs/nls'); -import os = require('os'); +import * as nls from 'vs/nls'; +import * as os from 'os'; import { Action, IAction } from 'vs/base/common/actions'; import { EndOfLinePreference } from 'vs/editor/common/editorCommon'; import { ICodeEditorService } from 'vs/editor/common/services/codeEditorService'; diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.ts index 727078be3bc..27f3f23c8ba 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.ts @@ -3,7 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import nls = require('vs/nls'); +import * as nls from 'vs/nls'; import { registerColor, ColorIdentifier } from 'vs/platform/theme/common/colorRegistry'; diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index 07f8b6b53cb..8d7d30b7099 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -3,15 +3,15 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ +import * as cp from 'child_process'; +import * as os from 'os'; import * as path from 'path'; -import DOM = require('vs/base/browser/dom'); +import * as lifecycle from 'vs/base/common/lifecycle'; +import * as nls from 'vs/nls'; +import * as platform from 'vs/base/common/platform'; +import * as dom from 'vs/base/browser/dom'; import Event, { Emitter } from 'vs/base/common/event'; -import URI from 'vs/base/common/uri'; -import cp = require('child_process'); -import lifecycle = require('vs/base/common/lifecycle'); -import nls = require('vs/nls'); -import os = require('os'); -import platform = require('vs/base/common/platform'); +import Uri from 'vs/base/common/uri'; import xterm = require('xterm'); import { Dimension } from 'vs/base/browser/builder'; import { IContextKeyService, IContextKey } from 'vs/platform/contextkey/common/contextkey'; @@ -39,7 +39,7 @@ class StandardTerminalProcessFactory implements ITerminalProcessFactory { public create(env: { [key: string]: string }): cp.ChildProcess { return cp.fork('./terminalProcess', [], { env, - cwd: URI.parse(path.dirname(require.toUrl('./terminalProcess'))).fsPath + cwd: Uri.parse(path.dirname(require.toUrl('./terminalProcess'))).fsPath }); } } @@ -217,7 +217,7 @@ export class TerminalInstance implements ITerminalInstance { this._container = container; this._wrapperElement = document.createElement('div'); - DOM.addClass(this._wrapperElement, 'terminal-wrapper'); + dom.addClass(this._wrapperElement, 'terminal-wrapper'); this._xtermElement = document.createElement('div'); this._xterm.open(this._xtermElement, false); @@ -242,7 +242,7 @@ export class TerminalInstance implements ITerminalInstance { } return undefined; }); - this._instanceDisposables.push(DOM.addDisposableListener(this._xterm.element, 'mouseup', (event: KeyboardEvent) => { + this._instanceDisposables.push(dom.addDisposableListener(this._xterm.element, 'mouseup', (event: KeyboardEvent) => { // Wait until mouseup has propogated through the DOM before evaluating the new selection // state. setTimeout(() => { @@ -251,7 +251,7 @@ export class TerminalInstance implements ITerminalInstance { })); // xterm.js currently drops selection on keyup as we need to handle this case. - this._instanceDisposables.push(DOM.addDisposableListener(this._xterm.element, 'keyup', (event: KeyboardEvent) => { + this._instanceDisposables.push(dom.addDisposableListener(this._xterm.element, 'keyup', (event: KeyboardEvent) => { // Wait until keyup has propogated through the DOM before evaluating the new selection // state. setTimeout(() => { @@ -262,10 +262,10 @@ export class TerminalInstance implements ITerminalInstance { const xtermHelper: HTMLElement = this._xterm.element.querySelector('.xterm-helpers'); const focusTrap: HTMLElement = document.createElement('div'); focusTrap.setAttribute('tabindex', '0'); - DOM.addClass(focusTrap, 'focus-trap'); - this._instanceDisposables.push(DOM.addDisposableListener(focusTrap, 'focus', (event: FocusEvent) => { + dom.addClass(focusTrap, 'focus-trap'); + this._instanceDisposables.push(dom.addDisposableListener(focusTrap, 'focus', (event: FocusEvent) => { let currentElement = focusTrap; - while (!DOM.hasClass(currentElement, 'part')) { + while (!dom.hasClass(currentElement, 'part')) { currentElement = currentElement.parentElement; } const hidePanelElement = currentElement.querySelector('.hide-panel-action'); @@ -273,17 +273,17 @@ export class TerminalInstance implements ITerminalInstance { })); xtermHelper.insertBefore(focusTrap, this._xterm.textarea); - this._instanceDisposables.push(DOM.addDisposableListener(this._xterm.textarea, 'focus', (event: KeyboardEvent) => { + this._instanceDisposables.push(dom.addDisposableListener(this._xterm.textarea, 'focus', (event: KeyboardEvent) => { this._terminalFocusContextKey.set(true); })); - this._instanceDisposables.push(DOM.addDisposableListener(this._xterm.textarea, 'blur', (event: KeyboardEvent) => { + this._instanceDisposables.push(dom.addDisposableListener(this._xterm.textarea, 'blur', (event: KeyboardEvent) => { this._terminalFocusContextKey.reset(); this._refreshSelectionContextKey(); })); - this._instanceDisposables.push(DOM.addDisposableListener(this._xterm.element, 'focus', (event: KeyboardEvent) => { + this._instanceDisposables.push(dom.addDisposableListener(this._xterm.element, 'focus', (event: KeyboardEvent) => { this._terminalFocusContextKey.set(true); })); - this._instanceDisposables.push(DOM.addDisposableListener(this._xterm.element, 'blur', (event: KeyboardEvent) => { + this._instanceDisposables.push(dom.addDisposableListener(this._xterm.element, 'blur', (event: KeyboardEvent) => { this._terminalFocusContextKey.reset(); this._refreshSelectionContextKey(); })); @@ -336,7 +336,7 @@ export class TerminalInstance implements ITerminalInstance { this._linkHandler.dispose(); } if (this._xterm && this._xterm.element) { - this._hadFocusOnExit = DOM.hasClass(this._xterm.element, 'focus'); + this._hadFocusOnExit = dom.hasClass(this._xterm.element, 'focus'); } if (this._wrapperElement) { this._container.removeChild(this._wrapperElement); @@ -389,7 +389,7 @@ export class TerminalInstance implements ITerminalInstance { public setVisible(visible: boolean): void { this._isVisible = visible; if (this._wrapperElement) { - DOM.toggleClass(this._wrapperElement, 'active', visible); + dom.toggleClass(this._wrapperElement, 'active', visible); } if (visible && this._xterm) { // Trigger a manual scroll event which will sync the viewport and scroll bar. This is @@ -473,9 +473,9 @@ export class TerminalInstance implements ITerminalInstance { } const env = TerminalInstance.createTerminalEnv(process.env, shell, this._getCwd(shell, workspace), locale, this._cols, this._rows); this._title = shell.name || ''; - this._process = cp.fork(URI.parse(require.toUrl('bootstrap')).fsPath, ['--type=terminal'], { + this._process = cp.fork(Uri.parse(require.toUrl('bootstrap')).fsPath, ['--type=terminal'], { env, - cwd: URI.parse(path.dirname(require.toUrl('../node/terminalProcess'))).fsPath + cwd: Uri.parse(path.dirname(require.toUrl('../node/terminalProcess'))).fsPath }); if (!shell.name) { // Only listen for process title changes when a name is not provided @@ -559,7 +559,7 @@ export class TerminalInstance implements ITerminalInstance { } private _attachPressAnyKeyToCloseListener() { - this._processDisposables.push(DOM.addDisposableListener(this._xterm.textarea, 'keypress', (event: KeyboardEvent) => { + this._processDisposables.push(dom.addDisposableListener(this._xterm.textarea, 'keypress', (event: KeyboardEvent) => { this.dispose(); event.preventDefault(); })); diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts index 81ed253bd42..ec880bdd12c 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts @@ -3,9 +3,9 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import DOM = require('vs/base/browser/dom'); -import nls = require('vs/nls'); -import platform = require('vs/base/common/platform'); +import * as dom from 'vs/base/browser/dom'; +import * as nls from 'vs/nls'; +import * as platform from 'vs/base/common/platform'; import { Action, IAction } from 'vs/base/common/actions'; import { Builder, Dimension } from 'vs/base/browser/builder'; import { IActionItem, Separator } from 'vs/base/browser/ui/actionbar/actionbar'; @@ -51,12 +51,12 @@ export class TerminalPanel extends Panel { public create(parent: Builder): TPromise { super.create(parent); this._parentDomElement = parent.getHTMLElement(); - DOM.addClass(this._parentDomElement, 'integrated-terminal'); + dom.addClass(this._parentDomElement, 'integrated-terminal'); this._themeStyleElement = document.createElement('style'); this._fontStyleElement = document.createElement('style'); this._terminalContainer = document.createElement('div'); - DOM.addClass(this._terminalContainer, 'terminal-outer-container'); + dom.addClass(this._terminalContainer, 'terminal-outer-container'); this._parentDomElement.appendChild(this._themeStyleElement); this._parentDomElement.appendChild(this._fontStyleElement); this._parentDomElement.appendChild(this._terminalContainer); @@ -152,7 +152,7 @@ export class TerminalPanel extends Panel { } private _attachEventListeners(): void { - this._register(DOM.addDisposableListener(this._parentDomElement, 'mousedown', (event: MouseEvent) => { + this._register(dom.addDisposableListener(this._parentDomElement, 'mousedown', (event: MouseEvent) => { if (this._terminalService.terminalInstances.length === 0) { return; } @@ -183,7 +183,7 @@ export class TerminalPanel extends Panel { } } })); - this._register(DOM.addDisposableListener(this._parentDomElement, 'contextmenu', (event: MouseEvent) => { + this._register(dom.addDisposableListener(this._parentDomElement, 'contextmenu', (event: MouseEvent) => { if (!this._cancelContextMenu) { const standardEvent = new StandardMouseEvent(event); let anchor: { x: number, y: number } = { x: standardEvent.posx, y: standardEvent.posy }; @@ -196,7 +196,7 @@ export class TerminalPanel extends Panel { } this._cancelContextMenu = false; })); - this._register(DOM.addDisposableListener(this._parentDomElement, 'click', (event) => { + this._register(dom.addDisposableListener(this._parentDomElement, 'click', (event) => { if (this._terminalService.terminalInstances.length === 0) { return; } @@ -205,14 +205,14 @@ export class TerminalPanel extends Panel { this._terminalService.getActiveInstance().focus(); } })); - this._register(DOM.addDisposableListener(this._parentDomElement, 'keyup', (event: KeyboardEvent) => { + this._register(dom.addDisposableListener(this._parentDomElement, 'keyup', (event: KeyboardEvent) => { if (event.keyCode === 27) { // Keep terminal open on escape event.stopPropagation(); } })); - this._register(DOM.addDisposableListener(this._parentDomElement, DOM.EventType.DROP, (e: DragEvent) => { - if (e.target === this._parentDomElement || DOM.isAncestor(e.target as HTMLElement, this._parentDomElement)) { + this._register(dom.addDisposableListener(this._parentDomElement, dom.EventType.DROP, (e: DragEvent) => { + if (e.target === this._parentDomElement || dom.isAncestor(e.target as HTMLElement, this._parentDomElement)) { if (!e.dataTransfer) { return; } @@ -269,8 +269,8 @@ export class TerminalPanel extends Panel { return; } let newFont = this._terminalService.configHelper.getFont(); - DOM.toggleClass(this._parentDomElement, 'enable-ligatures', this._terminalService.configHelper.config.fontLigatures); - DOM.toggleClass(this._parentDomElement, 'disable-bold', !this._terminalService.configHelper.config.enableBold); + dom.toggleClass(this._parentDomElement, 'enable-ligatures', this._terminalService.configHelper.config.fontLigatures); + dom.toggleClass(this._parentDomElement, 'disable-bold', !this._terminalService.configHelper.config.enableBold); if (!this._font || this._fontsDiffer(this._font, newFont)) { this._fontStyleElement.innerHTML = '.monaco-workbench .panel.integrated-terminal .xterm {' + `font-family: ${newFont.fontFamily};` + -- GitLab From 17f0dc9aad1213b46d00fea41e1fe1e68f7ab838 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Wed, 24 May 2017 22:33:35 -0700 Subject: [PATCH 0033/1347] Reverting prev fix as it adds gap between docs and list --- .../editor/contrib/suggest/browser/media/suggest.css | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/src/vs/editor/contrib/suggest/browser/media/suggest.css b/src/vs/editor/contrib/suggest/browser/media/suggest.css index 08b4e45593d..fe64def759b 100644 --- a/src/vs/editor/contrib/suggest/browser/media/suggest.css +++ b/src/vs/editor/contrib/suggest/browser/media/suggest.css @@ -34,18 +34,12 @@ .monaco-editor .suggest-widget.docs-side > .tree, .monaco-editor .suggest-widget.docs-side > .details { - /* subtract 2px for border, and another 2 for the Chromium zoom issue - where the children get slightly bigger width than what is set - which makes the docs go below the list */ - width: calc(50% - 4px); + width: 328px; } .monaco-editor.hc-black .suggest-widget.docs-side > .tree, .monaco-editor.hc-black .suggest-widget.docs-side > .details { - /* subtract 4px for border, and another 2 for the Chromium zoom issue - where the children get slightly bigger width than what is set - which makes the docs go below the list */ - width: calc(50% - 6px); + width: 326px; } /* Styles for Message element for when widget is loading or is empty */ -- GitLab From 9c6dd374824a40b8425835e813b9b16b598b2945 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Wed, 24 May 2017 22:48:10 -0700 Subject: [PATCH 0034/1347] Fixes #26244 prevent double border --- .../contrib/suggest/browser/media/suggest.css | 30 +++++++++---- .../contrib/suggest/browser/suggestWidget.ts | 42 +++++++++++++++---- 2 files changed, 58 insertions(+), 14 deletions(-) diff --git a/src/vs/editor/contrib/suggest/browser/media/suggest.css b/src/vs/editor/contrib/suggest/browser/media/suggest.css index fe64def759b..7ca54b83969 100644 --- a/src/vs/editor/contrib/suggest/browser/media/suggest.css +++ b/src/vs/editor/contrib/suggest/browser/media/suggest.css @@ -34,7 +34,17 @@ .monaco-editor .suggest-widget.docs-side > .tree, .monaco-editor .suggest-widget.docs-side > .details { - width: 328px; + /* subtract 2px for border, and another 2 for the Chromium zoom issue + where the children get slightly bigger width than what is set + which makes the docs go below the list */ + width: calc(50% - 4px); + float: left; + +} + +.monaco-editor .suggest-widget.docs-side.list-right > .tree, +.monaco-editor .suggest-widget.docs-side.list-right > .details { + float: right; } .monaco-editor.hc-black .suggest-widget.docs-side > .tree, @@ -42,6 +52,14 @@ width: 326px; } +.monaco-editor .suggest-widget.docs-side .empty-left-border { + border-left-width: 0px; +} + +.monaco-editor .suggest-widget.docs-side .empty-right-border { + border-right-width: 0px; +} + /* Styles for Message element for when widget is loading or is empty */ .monaco-editor .suggest-widget > .message { padding-left: 22px; @@ -58,13 +76,7 @@ height: 100%; } -.monaco-editor .suggest-widget.docs-side > .tree { - float: left; -} -.monaco-editor .suggest-widget.docs-side.list-right > .tree { - float: right -} /** Styles for each row in the list element **/ @@ -207,6 +219,10 @@ display: none; } +.monaco-editor .suggest-widget.docs-below .details { + border-top-width: 0px; +} + .monaco-editor .suggest-widget .details > .monaco-scrollable-element { flex: 1; } diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index 56871ef9504..c27e0dbaa95 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -948,14 +948,42 @@ export class SuggestWidget implements IContentWidget, IDelegate } private adjustListPosition(): void { - if (hasClass(this.element, 'widget-above') - && hasClass(this.element, 'docs-side') - && this.details.element.offsetHeight > this.listElement.offsetHeight) { - // Docs is bigger than list and widget is above cursor, apply margin-top so that list appears right above cursor - this.listElement.style.marginTop = `${this.details.element.offsetHeight - this.listElement.offsetHeight}px`; - } else { - this.listElement.style.marginTop = '0px'; + + + if (hasClass(this.element, 'docs-side')) { + + if (this.details.element.offsetHeight > this.listElement.offsetHeight) { + if (hasClass(this.element, 'widget-above')) { + // Docs is bigger than list and widget is above cursor, apply margin-top so that list appears right above cursor + this.listElement.style.marginTop = `${this.details.element.offsetHeight - this.listElement.offsetHeight}px`; + } + + if (hasClass(this.element, 'list-right')) { + addClass(this.listElement, 'empty-left-border'); + removeClass(this.listElement, 'empty-right-border'); + } else { + addClass(this.listElement, 'empty-right-border'); + removeClass(this.listElement, 'empty-left-border'); + } + + removeClass(this.details.element, 'empty-left-border'); + removeClass(this.details.element, 'empty-right-border'); + return; + } else { + if (hasClass(this.element, 'list-right')) { + addClass(this.details.element, 'empty-right-border'); + removeClass(this.details.element, 'empty-left-border'); + } else { + addClass(this.details.element, 'empty-left-border'); + removeClass(this.details.element, 'empty-right-border'); + } + + removeClass(this.listElement, 'empty-right-border'); + removeClass(this.listElement, 'empty-left-border'); + } } + + this.listElement.style.marginTop = '0px'; } private renderDetails(): void { -- GitLab From 2e08585bac59ee3e721803e6234e7e0e7623d5c8 Mon Sep 17 00:00:00 2001 From: Daniel Ye Date: Wed, 24 May 2017 22:56:48 -0700 Subject: [PATCH 0035/1347] 2017-05-24. Merged in translations from transifex. --- build/win32/i18n/messages.pt-br.isl | 8 + .../out/settingsDocumentHelper.i18n.json | 2 +- i18n/chs/extensions/gulp/out/main.i18n.json | 2 +- i18n/chs/extensions/jake/out/main.i18n.json | 4 +- i18n/chs/extensions/jake/package.i18n.json | 4 +- .../markdown/out/extension.i18n.json | 6 + .../out/codelensProvider.i18n.json | 6 + .../out/commandHandler.i18n.json | 6 + .../out/mergeDecorator.i18n.json | 6 + .../merge-conflict/package.i18n.json | 6 + i18n/chs/extensions/npm/package.i18n.json | 6 + .../resourceviewer/resourceViewer.i18n.json | 2 - .../src/vs/code/electron-main/menus.i18n.json | 4 +- .../config/commonEditorConfig.i18n.json | 6 +- .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../indentation/common/indentation.i18n.json | 2 +- .../suggest/browser/suggestWidget.i18n.json | 2 +- .../common/configurationRegistry.i18n.json | 2 +- .../markers/common/problemMatcher.i18n.json | 7 + .../api/node/extHostTreeViews.i18n.json | 6 +- .../src/vs/workbench/common/theme.i18n.json | 1 + .../main.contribution.i18n.json | 1 + .../inspectKeybindings.i18n.json | 2 +- .../electron-browser/toggleWordWrap.i18n.json | 2 +- .../parts/debug/node/debugAdapter.i18n.json | 1 + .../actions/evaluateMath.i18n.json | 2 +- .../actions/incrementDecrement.i18n.json | 12 +- .../actions/removeTag.i18n.json | 2 +- .../actions/splitJoinTag.i18n.json | 2 +- .../actions/updateImageSize.i18n.json | 2 +- .../actions/updateTag.i18n.json | 6 +- .../actions/wrapWithAbbreviation.i18n.json | 2 +- .../emmet.contribution.i18n.json | 6 +- .../treeExplorer.contribution.i18n.json | 4 +- .../extensionsUtils.i18n.json | 6 +- .../browser/files.contribution.i18n.json | 1 - .../common/editors/fileEditorInput.i18n.json | 2 +- .../performance.contribution.i18n.json | 8 +- .../browser/keybindingsEditor.i18n.json | 4 +- .../browser/preferencesActions.i18n.json | 2 +- .../scm.contribution.i18n.json | 3 +- .../scm/electron-browser/scmMenus.i18n.json | 3 +- .../electron-browser/TMSnippets.i18n.json | 2 +- .../parts/tasks/browser/quickOpen.i18n.json | 4 +- .../terminalTaskSystem.i18n.json | 3 +- .../tasks/node/processTaskSystem.i18n.json | 3 +- .../electron-browser/watermark.i18n.json | 2 +- .../vs_code_welcome_page.i18n.json | 7 +- .../electron-browser/welcomePage.i18n.json | 14 ++ .../workbenchThemeService.i18n.json | 12 +- .../markdown/out/extension.i18n.json | 6 + .../out/codelensProvider.i18n.json | 6 + .../out/commandHandler.i18n.json | 6 + .../out/mergeDecorator.i18n.json | 6 + .../merge-conflict/package.i18n.json | 6 + i18n/cht/extensions/npm/package.i18n.json | 6 + .../resourceviewer/resourceViewer.i18n.json | 2 - .../src/vs/code/electron-main/menus.i18n.json | 1 + .../config/commonEditorConfig.i18n.json | 1 - .../common/view/editorColorRegistry.i18n.json | 3 + .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../api/node/extHostTreeViews.i18n.json | 4 +- .../src/vs/workbench/common/theme.i18n.json | 1 + .../main.contribution.i18n.json | 1 + .../extensionsUtils.i18n.json | 6 +- .../browser/files.contribution.i18n.json | 1 - .../performance.contribution.i18n.json | 6 +- .../scm.contribution.i18n.json | 1 + .../scm/electron-browser/scmMenus.i18n.json | 1 + .../parts/tasks/browser/quickOpen.i18n.json | 4 +- .../themes.contribution.i18n.json | 1 + .../vs_code_welcome_page.i18n.json | 3 + .../electron-browser/welcomePage.i18n.json | 13 +- .../walkThroughPart.i18n.json | 3 +- i18n/deu/extensions/git/out/main.i18n.json | 2 +- .../markdown/out/extension.i18n.json | 6 + .../out/codelensProvider.i18n.json | 6 + .../out/commandHandler.i18n.json | 6 + .../out/mergeDecorator.i18n.json | 6 + .../merge-conflict/package.i18n.json | 6 + i18n/deu/extensions/npm/package.i18n.json | 6 + .../resourceviewer/resourceViewer.i18n.json | 2 - .../config/commonEditorConfig.i18n.json | 1 - .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../main.contribution.i18n.json | 1 + .../extensionsUtils.i18n.json | 6 +- .../browser/files.contribution.i18n.json | 1 - .../performance.contribution.i18n.json | 6 +- .../electron-browser/welcomePage.i18n.json | 5 + i18n/esn/extensions/jake/out/main.i18n.json | 4 +- i18n/esn/extensions/jake/package.i18n.json | 4 +- .../markdown/out/extension.i18n.json | 6 + .../out/codelensProvider.i18n.json | 6 + .../out/commandHandler.i18n.json | 6 + .../out/mergeDecorator.i18n.json | 6 + .../merge-conflict/package.i18n.json | 6 + i18n/esn/extensions/npm/package.i18n.json | 6 + .../resourceviewer/resourceViewer.i18n.json | 2 - .../config/commonEditorConfig.i18n.json | 3 +- .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../suggest/browser/suggestWidget.i18n.json | 1 + ...guageConfigurationExtensionPoint.i18n.json | 6 +- .../markers/common/problemMatcher.i18n.json | 7 + .../theme/common/colorRegistry.i18n.json | 3 + .../api/node/extHostTreeViews.i18n.json | 6 +- .../src/vs/workbench/common/theme.i18n.json | 1 + .../main.contribution.i18n.json | 1 + .../parts/debug/node/debugAdapter.i18n.json | 1 + .../extensionsUtils.i18n.json | 6 +- .../browser/files.contribution.i18n.json | 1 - .../performance.contribution.i18n.json | 8 +- .../scm.contribution.i18n.json | 1 + .../scm/electron-browser/scmMenus.i18n.json | 1 + .../parts/tasks/browser/quickOpen.i18n.json | 4 +- .../terminalTaskSystem.i18n.json | 3 +- .../tasks/node/processTaskSystem.i18n.json | 3 +- .../vs_code_welcome_page.i18n.json | 5 + .../electron-browser/welcomePage.i18n.json | 14 ++ .../markdown/out/extension.i18n.json | 6 + .../out/codelensProvider.i18n.json | 6 + .../out/commandHandler.i18n.json | 6 + .../out/mergeDecorator.i18n.json | 6 + .../merge-conflict/package.i18n.json | 6 + i18n/fra/extensions/npm/package.i18n.json | 6 + .../resourceviewer/resourceViewer.i18n.json | 2 - .../config/commonEditorConfig.i18n.json | 1 - .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../main.contribution.i18n.json | 1 + .../extensionsUtils.i18n.json | 6 +- .../browser/files.contribution.i18n.json | 1 - .../performance.contribution.i18n.json | 6 +- .../electron-browser/welcomePage.i18n.json | 5 + .../markdown/out/extension.i18n.json | 6 + .../out/codelensProvider.i18n.json | 6 + .../out/commandHandler.i18n.json | 6 + .../out/mergeDecorator.i18n.json | 6 + .../merge-conflict/package.i18n.json | 6 + i18n/ita/extensions/npm/package.i18n.json | 6 + .../resourceviewer/resourceViewer.i18n.json | 2 - .../config/commonEditorConfig.i18n.json | 2 +- .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../markers/common/problemMatcher.i18n.json | 7 + .../main.contribution.i18n.json | 1 + .../extensionsUtils.i18n.json | 6 +- .../browser/files.contribution.i18n.json | 1 - .../performance.contribution.i18n.json | 6 +- .../electron-browser/welcomePage.i18n.json | 5 + i18n/jpn/extensions/jake/out/main.i18n.json | 4 +- i18n/jpn/extensions/jake/package.i18n.json | 4 +- .../markdown/out/extension.i18n.json | 6 + .../out/codelensProvider.i18n.json | 6 + .../out/commandHandler.i18n.json | 6 + .../out/mergeDecorator.i18n.json | 6 + .../merge-conflict/package.i18n.json | 6 + i18n/jpn/extensions/npm/package.i18n.json | 6 + .../extensions/typescript/package.i18n.json | 5 +- .../resourceviewer/resourceViewer.i18n.json | 2 - .../config/commonEditorConfig.i18n.json | 2 +- .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../suggest/browser/suggestWidget.i18n.json | 1 + ...guageConfigurationExtensionPoint.i18n.json | 1 + .../markers/common/problemMatcher.i18n.json | 7 + .../theme/common/colorRegistry.i18n.json | 1 + .../api/node/extHostTreeViews.i18n.json | 6 +- .../src/vs/workbench/common/theme.i18n.json | 1 + .../main.contribution.i18n.json | 1 + .../electronDebugActions.i18n.json | 1 + .../parts/debug/node/debugAdapter.i18n.json | 1 + .../extensionsUtils.i18n.json | 6 +- .../browser/files.contribution.i18n.json | 3 +- .../performance.contribution.i18n.json | 8 +- .../browser/preferencesRenderers.i18n.json | 1 + .../scm.contribution.i18n.json | 1 + .../scm/electron-browser/scmMenus.i18n.json | 1 + .../parts/tasks/browser/quickOpen.i18n.json | 4 +- .../tasks/browser/restartQuickOpen.i18n.json | 2 +- .../tasks/browser/taskQuickOpen.i18n.json | 2 +- .../terminalTaskSystem.i18n.json | 3 +- .../tasks/node/processTaskSystem.i18n.json | 3 +- .../terminalActions.i18n.json | 4 +- .../themes.contribution.i18n.json | 1 + .../vs_code_welcome_page.i18n.json | 7 + .../electron-browser/welcomePage.i18n.json | 18 +- .../configurationEditingService.i18n.json | 1 + .../markdown/out/extension.i18n.json | 6 + .../out/codelensProvider.i18n.json | 6 + .../out/commandHandler.i18n.json | 6 + .../out/mergeDecorator.i18n.json | 6 + .../merge-conflict/package.i18n.json | 6 + i18n/kor/extensions/npm/package.i18n.json | 6 + .../resourceviewer/resourceViewer.i18n.json | 2 - .../config/commonEditorConfig.i18n.json | 1 - .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../main.contribution.i18n.json | 1 + .../extensionsUtils.i18n.json | 6 +- .../browser/files.contribution.i18n.json | 1 - .../performance.contribution.i18n.json | 6 +- .../electron-browser/welcomePage.i18n.json | 5 + .../out/settingsDocumentHelper.i18n.json | 36 ++++ .../css/client/out/cssMain.i18n.json | 8 + i18n/ptb/extensions/css/package.i18n.json | 67 +++++++ .../out/packageDocumentHelper.i18n.json | 9 + .../extensions/git/out/askpass-main.i18n.json | 8 + .../ptb/extensions/git/out/commands.i18n.json | 43 +++++ i18n/ptb/extensions/git/out/main.i18n.json | 11 ++ i18n/ptb/extensions/git/out/model.i18n.json | 14 ++ .../extensions/git/out/scmProvider.i18n.json | 8 + .../extensions/git/out/statusbar.i18n.json | 11 ++ i18n/ptb/extensions/git/package.i18n.json | 48 +++++ i18n/ptb/extensions/grunt/out/main.i18n.json | 8 + i18n/ptb/extensions/grunt/package.i18n.json | 8 + i18n/ptb/extensions/gulp/out/main.i18n.json | 8 + i18n/ptb/extensions/gulp/package.i18n.json | 8 + .../html/client/out/htmlMain.i18n.json | 8 + i18n/ptb/extensions/html/package.i18n.json | 27 +++ i18n/ptb/extensions/jake/out/main.i18n.json | 8 + i18n/ptb/extensions/jake/package.i18n.json | 8 + .../features/bowerJSONContribution.i18n.json | 10 ++ .../packageJSONContribution.i18n.json | 13 ++ .../json/client/out/jsonMain.i18n.json | 8 + i18n/ptb/extensions/json/package.i18n.json | 15 ++ .../markdown/out/extension.i18n.json | 6 + .../out/previewContentProvider.i18n.json | 10 ++ .../markdown/out/security.i18n.json | 11 ++ .../ptb/extensions/markdown/package.i18n.json | 22 +++ .../out/codelensProvider.i18n.json | 6 + .../out/commandHandler.i18n.json | 6 + .../out/mergeDecorator.i18n.json | 6 + .../merge-conflict/package.i18n.json | 6 + i18n/ptb/extensions/npm/package.i18n.json | 6 + .../out/features/validationProvider.i18n.json | 13 ++ i18n/ptb/extensions/php/package.i18n.json | 14 ++ .../out/features/bufferSyncSupport.i18n.json | 12 ++ .../features/completionItemProvider.i18n.json | 9 + ...rectiveCommentCompletionProvider.i18n.json | 10 ++ .../implementationsCodeLensProvider.i18n.json | 10 ++ .../jsDocCompletionProvider.i18n.json | 8 + .../referencesCodeLensProvider.i18n.json | 10 ++ .../typescript/out/typescriptMain.i18n.json | 15 ++ .../out/typescriptServiceClient.i18n.json | 24 +++ .../typescript/out/utils/logger.i18n.json | 8 + .../out/utils/projectStatus.i18n.json | 12 ++ .../out/utils/typingsStatus.i18n.json | 12 ++ .../extensions/typescript/package.i18n.json | 45 +++++ .../browser/ui/actionbar/actionbar.i18n.json | 8 + .../vs/base/browser/ui/aria/aria.i18n.json | 8 + .../browser/ui/findinput/findInput.i18n.json | 8 + .../findinput/findInputCheckboxes.i18n.json | 10 ++ .../browser/ui/inputbox/inputBox.i18n.json | 10 ++ .../resourceviewer/resourceViewer.i18n.json | 15 ++ .../base/browser/ui/toolbar/toolbar.i18n.json | 8 + .../src/vs/base/common/errorMessage.i18n.json | 18 ++ .../base/common/jsonErrorMessages.i18n.json | 16 ++ .../src/vs/base/common/processes.i18n.json | 11 ++ .../ptb/src/vs/base/common/severity.i18n.json | 10 ++ i18n/ptb/src/vs/base/node/processes.i18n.json | 8 + i18n/ptb/src/vs/base/node/zip.i18n.json | 8 + .../browser/quickOpenModel.i18n.json | 9 + .../browser/quickOpenWidget.i18n.json | 9 + .../parts/tree/browser/treeDefaults.i18n.json | 8 + .../src/vs/code/electron-main/menus.i18n.json | 164 ++++++++++++++++++ .../vs/code/electron-main/window.i18n.json | 8 + .../vs/code/electron-main/windows.i18n.json | 22 +++ .../src/vs/code/node/cliProcessMain.i18n.json | 17 ++ .../config/commonEditorConfig.i18n.json | 76 ++++++++ .../common/config/editorOptions.i18n.json | 8 + .../editor/common/controller/cursor.i18n.json | 8 + .../model/textModelWithTokens.i18n.json | 8 + .../common/modes/modesRegistry.i18n.json | 8 + .../editor/common/services/bulkEdit.i18n.json | 11 ++ .../common/services/modeServiceImpl.i18n.json | 16 ++ .../services/modelServiceImpl.i18n.json | 9 + .../common/view/editorColorRegistry.i18n.json | 20 +++ .../browser/accessibility.i18n.json | 15 ++ .../common/bracketMatching.i18n.json | 8 + .../common/caretOperations.i18n.json | 9 + .../common/transpose.i18n.json | 8 + .../clipboard/browser/clipboard.i18n.json | 11 ++ .../contrib/comment/common/comment.i18n.json | 11 ++ .../contextmenu/browser/contextmenu.i18n.json | 8 + .../contrib/find/browser/findWidget.i18n.json | 21 +++ .../find/common/findController.i18n.json | 19 ++ .../contrib/folding/browser/folding.i18n.json | 14 ++ .../format/browser/formatActions.i18n.json | 13 ++ .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../gotoError/browser/gotoError.i18n.json | 13 ++ .../contrib/hover/browser/hover.i18n.json | 8 + .../hover/browser/modesContentHover.i18n.json | 8 + .../common/inPlaceReplace.i18n.json | 9 + .../indentation/common/indentation.i18n.json | 15 ++ .../inspectTMScopes.i18n.json | 9 + .../common/linesOperations.i18n.json | 25 +++ .../contrib/links/browser/links.i18n.json | 12 ++ .../multicursor/common/multicursor.i18n.json | 10 ++ .../browser/parameterHints.i18n.json | 8 + .../browser/parameterHintsWidget.i18n.json | 8 + .../browser/quickFixCommands.i18n.json | 10 ++ .../browser/referenceSearch.i18n.json | 9 + .../browser/referencesController.i18n.json | 8 + .../browser/referencesModel.i18n.json | 14 ++ .../browser/referencesWidget.i18n.json | 27 +++ .../contrib/rename/browser/rename.i18n.json | 11 ++ .../rename/browser/renameInputField.i18n.json | 8 + .../smartSelect/common/smartSelect.i18n.json | 9 + .../browser/suggestController.i18n.json | 9 + .../suggest/browser/suggestWidget.i18n.json | 21 +++ .../common/toggleTabFocusMode.i18n.json | 8 + .../common/wordHighlighter.i18n.json | 9 + .../browser/peekViewWidget.i18n.json | 8 + .../textMate/TMSyntax.i18n.json | 14 ++ ...guageConfigurationExtensionPoint.i18n.json | 23 +++ .../editor/node/textMate/TMGrammars.i18n.json | 13 ++ .../browser/menuItemActionItem.i18n.json | 8 + .../menusExtensionPoint.i18n.json | 41 +++++ .../common/configurationRegistry.i18n.json | 19 ++ .../platform/environment/node/argv.i18n.json | 32 ++++ .../extensionEnablementService.i18n.json | 8 + .../common/extensionManagement.i18n.json | 9 + .../node/extensionGalleryService.i18n.json | 9 + .../node/extensionManagementService.i18n.json | 22 +++ .../common/abstractExtensionService.i18n.json | 11 ++ .../common/extensionsRegistry.i18n.json | 24 +++ .../node/extensionValidator.i18n.json | 24 +++ .../node/integrityServiceImpl.i18n.json | 11 ++ .../jsonValidationExtensionPoint.i18n.json | 15 ++ .../abstractKeybindingService.i18n.json | 9 + .../common/keybindingLabels.i18n.json | 16 ++ .../markers/common/problemMatcher.i18n.json | 61 +++++++ .../platform/message/common/message.i18n.json | 10 ++ .../platform/request/node/request.i18n.json | 11 ++ .../common/telemetryService.i18n.json | 9 + .../theme/common/colorRegistry.i18n.json | 78 +++++++++ .../mainThreadExtensionService.i18n.json | 9 + .../mainThreadMessageService.i18n.json | 10 ++ .../api/node/extHostDiagnostics.i18n.json | 8 + .../api/node/extHostTreeViews.i18n.json | 10 ++ .../browser/actions/configureLocale.i18n.json | 13 ++ .../browser/actions/fileActions.i18n.json | 9 + .../toggleActivityBarVisibility.i18n.json | 9 + .../actions/toggleEditorLayout.i18n.json | 11 ++ .../actions/toggleSidebarPosition.i18n.json | 9 + .../actions/toggleSidebarVisibility.i18n.json | 9 + .../toggleStatusbarVisibility.i18n.json | 9 + .../browser/actions/toggleZenMode.i18n.json | 9 + .../activitybar/activitybarActions.i18n.json | 14 ++ .../activitybar/activitybarPart.i18n.json | 9 + .../browser/parts/compositePart.i18n.json | 9 + .../parts/editor/binaryDiffEditor.i18n.json | 8 + .../parts/editor/binaryEditor.i18n.json | 8 + .../editor/editor.contribution.i18n.json | 16 ++ .../parts/editor/editorActions.i18n.json | 55 ++++++ .../parts/editor/editorCommands.i18n.json | 12 ++ .../browser/parts/editor/editorPart.i18n.json | 14 ++ .../parts/editor/editorPicker.i18n.json | 13 ++ .../parts/editor/editorStatus.i18n.json | 49 ++++++ .../parts/editor/tabsTitleControl.i18n.json | 8 + .../parts/editor/textDiffEditor.i18n.json | 16 ++ .../browser/parts/editor/textEditor.i18n.json | 8 + .../parts/editor/textResourceEditor.i18n.json | 12 ++ .../parts/editor/titleControl.i18n.json | 14 ++ .../parts/panel/panelActions.i18n.json | 15 ++ .../browser/parts/panel/panelPart.i18n.json | 8 + .../quickopen/quickOpenController.i18n.json | 17 ++ .../quickopen.contribution.i18n.json | 12 ++ .../parts/sidebar/sidebarPart.i18n.json | 9 + .../parts/statusbar/statusbarPart.i18n.json | 9 + .../parts/titlebar/titlebarPart.i18n.json | 9 + .../vs/workbench/browser/quickopen.i18n.json | 11 ++ .../vs/workbench/browser/viewlet.i18n.json | 9 + .../src/vs/workbench/common/theme.i18n.json | 44 +++++ .../electron-browser/actions.i18n.json | 41 +++++ .../electron-browser/commands.i18n.json | 8 + .../electron-browser/crashReporter.i18n.json | 9 + .../electron-browser/extensionHost.i18n.json | 11 ++ .../main.contribution.i18n.json | 62 +++++++ .../workbench/electron-browser/main.i18n.json | 9 + .../electron-browser/shell.i18n.json | 8 + .../electron-browser/window.i18n.json | 15 ++ .../node/extensionHostMain.i18n.json | 8 + .../workbench/node/extensionPoints.i18n.json | 11 ++ .../cli.contribution.i18n.json | 18 ++ .../inspectKeybindings.i18n.json | 8 + .../toggleRenderControlCharacter.i18n.json | 8 + .../toggleRenderWhitespace.i18n.json | 8 + .../electron-browser/toggleWordWrap.i18n.json | 11 ++ .../wordWrapMigration.i18n.json | 11 ++ .../debug/browser/breakpointWidget.i18n.json | 13 ++ .../debug/browser/debugActionItems.i18n.json | 9 + .../debug/browser/debugActions.i18n.json | 49 ++++++ .../browser/debugActionsWidget.i18n.json | 8 + .../browser/debugContentProvider.i18n.json | 8 + .../browser/debugEditorActions.i18n.json | 15 ++ .../browser/debugEditorModelManager.i18n.json | 11 ++ .../debug/browser/debugQuickOpen.i18n.json | 11 ++ .../debug/browser/exceptionWidget.i18n.json | 11 ++ .../debug/browser/linkDetector.i18n.json | 9 + .../parts/debug/common/debug.i18n.json | 8 + .../parts/debug/common/debugModel.i18n.json | 9 + .../parts/debug/common/debugSource.i18n.json | 8 + .../debug.contribution.i18n.json | 20 +++ .../electron-browser/debugCommands.i18n.json | 8 + .../debugConfigurationManager.i18n.json | 38 ++++ .../debugEditorContribution.i18n.json | 20 +++ .../electron-browser/debugHover.i18n.json | 8 + .../electron-browser/debugService.i18n.json | 25 +++ .../electron-browser/debugViewer.i18n.json | 28 +++ .../electron-browser/debugViews.i18n.json | 20 +++ .../electronDebugActions.i18n.json | 11 ++ .../rawDebugSession.i18n.json | 12 ++ .../debug/electron-browser/repl.i18n.json | 11 ++ .../electron-browser/replViewer.i18n.json | 12 ++ .../statusbarColorProvider.i18n.json | 8 + .../terminalSupport.i18n.json | 9 + .../parts/debug/node/debugAdapter.i18n.json | 20 +++ .../actions/showEmmetCommands.i18n.json | 8 + .../actions/balance.i18n.json | 9 + .../actions/editPoints.i18n.json | 9 + .../actions/evaluateMath.i18n.json | 8 + .../actions/expandAbbreviation.i18n.json | 8 + .../actions/incrementDecrement.i18n.json | 13 ++ .../actions/matchingPair.i18n.json | 8 + .../actions/mergeLines.i18n.json | 8 + .../actions/reflectCssValue.i18n.json | 8 + .../actions/removeTag.i18n.json | 8 + .../actions/selectItem.i18n.json | 9 + .../actions/splitJoinTag.i18n.json | 8 + .../actions/toggleComment.i18n.json | 8 + .../actions/updateImageSize.i18n.json | 8 + .../actions/updateTag.i18n.json | 10 ++ .../actions/wrapWithAbbreviation.i18n.json | 10 ++ .../emmet.contribution.i18n.json | 13 ++ .../terminal.contribution.i18n.json | 15 ++ .../terminalService.i18n.json | 12 ++ .../treeExplorer.contribution.i18n.json | 14 ++ .../browser/treeExplorerActions.i18n.json | 8 + .../browser/treeExplorerService.i18n.json | 8 + .../browser/views/treeExplorerView.i18n.json | 8 + .../browser/dependenciesViewer.i18n.json | 9 + .../browser/extensionEditor.i18n.json | 39 +++++ .../browser/extensionsActions.i18n.json | 55 ++++++ .../browser/extensionsQuickOpen.i18n.json | 10 ++ .../common/extensionsFileTemplate.i18n.json | 10 ++ .../common/extensionsInput.i18n.json | 8 + .../extensionTipsService.i18n.json | 16 ++ .../extensions.contribution.i18n.json | 15 ++ .../extensionsActions.i18n.json | 11 ++ .../extensionsUtils.i18n.json | 10 ++ .../extensionsViewlet.i18n.json | 15 ++ .../node/extensionsWorkbenchService.i18n.json | 17 ++ .../electron-browser/feedback.i18n.json | 25 +++ .../editors/binaryFileEditor.i18n.json | 8 + .../browser/editors/textFileEditor.i18n.json | 11 ++ .../fileActions.contribution.i18n.json | 11 ++ .../parts/files/browser/fileActions.i18n.json | 73 ++++++++ .../files/browser/fileCommands.i18n.json | 9 + .../browser/files.contribution.i18n.json | 40 +++++ .../files/browser/saveErrorHandler.i18n.json | 16 ++ .../files/browser/views/emptyView.i18n.json | 11 ++ .../browser/views/explorerView.i18n.json | 9 + .../browser/views/explorerViewer.i18n.json | 12 ++ .../browser/views/openEditorsView.i18n.json | 11 ++ .../browser/views/openEditorsViewer.i18n.json | 13 ++ .../files/common/dirtyFilesTracker.i18n.json | 8 + .../common/editors/fileEditorInput.i18n.json | 8 + .../html/browser/html.contribution.i18n.json | 8 + .../html/browser/htmlPreviewPart.i18n.json | 8 + .../parts/html/browser/webview.i18n.json | 8 + .../parts/markers/common/messages.i18n.json | 39 +++++ .../markersElectronContributions.i18n.json | 8 + .../nps.contribution.i18n.json | 11 ++ .../browser/output.contribution.i18n.json | 10 ++ .../output/browser/outputActions.i18n.json | 11 ++ .../output/browser/outputPanel.i18n.json | 9 + .../parts/output/common/output.i18n.json | 9 + .../performance.contribution.i18n.json | 15 ++ .../browser/keybindingWidgets.i18n.json | 9 + .../browser/keybindingsEditor.i18n.json | 35 ++++ .../keybindingsEditorContribution.i18n.json | 10 ++ .../preferences.contribution.i18n.json | 10 ++ .../browser/preferencesActions.i18n.json | 14 ++ .../browser/preferencesEditor.i18n.json | 15 ++ .../browser/preferencesRenderers.i18n.json | 13 ++ .../browser/preferencesService.i18n.json | 13 ++ .../browser/preferencesWidgets.i18n.json | 10 ++ .../common/keybindingsEditorModel.i18n.json | 11 ++ .../common/preferencesModels.i18n.json | 9 + .../browser/commandsHandler.i18n.json | 16 ++ .../browser/gotoLineHandler.i18n.json | 14 ++ .../browser/gotoSymbolHandler.i18n.json | 34 ++++ .../quickopen/browser/helpHandler.i18n.json | 10 ++ .../browser/quickopen.contribution.i18n.json | 14 ++ .../browser/viewPickerHandler.i18n.json | 15 ++ .../scm.contribution.i18n.json | 12 ++ .../electron-browser/scmActivity.i18n.json | 8 + .../scm/electron-browser/scmMenus.i18n.json | 9 + .../scm/electron-browser/scmViewlet.i18n.json | 10 ++ .../browser/openAnythingHandler.i18n.json | 9 + .../search/browser/openFileHandler.i18n.json | 9 + .../browser/openSymbolHandler.i18n.json | 11 ++ .../browser/patternInputWidget.i18n.json | 12 ++ .../search/browser/replaceService.i18n.json | 8 + .../browser/search.contribution.i18n.json | 22 +++ .../search/browser/searchActions.i18n.json | 21 +++ .../browser/searchResultsView.i18n.json | 12 ++ .../search/browser/searchViewlet.i18n.json | 50 ++++++ .../search/browser/searchWidget.i18n.json | 15 ++ .../electron-browser/TMSnippets.i18n.json | 13 ++ .../electron-browser/insertSnippet.i18n.json | 8 + .../snippets.contribution.i18n.json | 16 ++ .../snippetsService.i18n.json | 9 + .../electron-browser/tabCompletion.i18n.json | 8 + .../parts/tasks/browser/quickOpen.i18n.json | 10 ++ .../tasks/browser/restartQuickOpen.i18n.json | 10 ++ .../tasks/browser/taskQuickOpen.i18n.json | 10 ++ .../browser/terminateQuickOpen.i18n.json | 10 ++ .../tasks/common/taskConfiguration.i18n.json | 17 ++ .../tasks/common/taskTemplates.i18n.json | 13 ++ .../jsonSchemaCommon.i18n.json | 38 ++++ .../electron-browser/jsonSchema_v1.i18n.json | 12 ++ .../electron-browser/jsonSchema_v2.i18n.json | 14 ++ .../task.contribution.i18n.json | 47 +++++ .../terminalTaskSystem.i18n.json | 11 ++ .../node/processRunnerDetector.i18n.json | 15 ++ .../tasks/node/processTaskSystem.i18n.json | 12 ++ .../terminal.contribution.i18n.json | 30 ++++ .../terminalActions.i18n.json | 32 ++++ .../terminalColorRegistry.i18n.json | 10 ++ .../terminalConfigHelper.i18n.json | 10 ++ .../terminalInstance.i18n.json | 11 ++ .../terminalLinkHandler.i18n.json | 9 + .../electron-browser/terminalPanel.i18n.json | 11 ++ .../terminalService.i18n.json | 15 ++ .../themes.contribution.i18n.json | 19 ++ ...edWorkspaceSettings.contribution.i18n.json | 11 ++ .../releaseNotesInput.i18n.json | 8 + .../update.contribution.i18n.json | 10 ++ .../update/electron-browser/update.i18n.json | 19 ++ .../electron-browser/watermark.i18n.json | 24 +++ .../overlay/browser/welcomeOverlay.i18n.json | 17 ++ .../vs_code_welcome_page.i18n.json | 44 +++++ .../welcomePage.contribution.i18n.json | 10 ++ .../electron-browser/welcomePage.i18n.json | 31 ++++ .../editor/editorWalkThrough.i18n.json | 9 + .../walkThrough.contribution.i18n.json | 10 ++ .../walkThroughActions.i18n.json | 11 ++ .../walkThroughPart.i18n.json | 10 ++ .../configurationEditingService.i18n.json | 17 ++ .../editor/browser/editorService.i18n.json | 8 + .../electron-browser/fileService.i18n.json | 11 ++ .../services/files/node/fileService.i18n.json | 14 ++ .../common/keybindingEditing.i18n.json | 11 ++ .../keybindingService.i18n.json | 26 +++ .../message/browser/messageList.i18n.json | 14 ++ .../electron-browser/messageService.i18n.json | 9 + .../common/workbenchModeService.i18n.json | 16 ++ .../common/textFileEditorModel.i18n.json | 9 + .../textfile/common/textFileService.i18n.json | 8 + .../textFileService.i18n.json | 18 ++ .../themes/common/colorThemeSchema.i18n.json | 11 ++ .../common/fileIconThemeSchema.i18n.json | 37 ++++ .../electron-browser/colorThemeData.i18n.json | 13 ++ .../workbenchThemeService.i18n.json | 32 ++++ .../markdown/out/extension.i18n.json | 6 + .../out/codelensProvider.i18n.json | 6 + .../out/commandHandler.i18n.json | 6 + .../out/mergeDecorator.i18n.json | 6 + .../merge-conflict/package.i18n.json | 6 + i18n/rus/extensions/npm/package.i18n.json | 6 + .../resourceviewer/resourceViewer.i18n.json | 2 - .../src/vs/code/electron-main/menus.i18n.json | 2 + .../config/commonEditorConfig.i18n.json | 1 - .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../main.contribution.i18n.json | 1 + .../extensionsUtils.i18n.json | 6 +- .../browser/files.contribution.i18n.json | 1 - .../performance.contribution.i18n.json | 6 +- .../electron-browser/welcomePage.i18n.json | 5 + 587 files changed, 6511 insertions(+), 128 deletions(-) create mode 100644 build/win32/i18n/messages.pt-br.isl create mode 100644 i18n/chs/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/chs/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/chs/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/chs/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/chs/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/chs/extensions/npm/package.i18n.json create mode 100644 i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json create mode 100644 i18n/cht/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/cht/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/cht/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/cht/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/cht/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/cht/extensions/npm/package.i18n.json create mode 100644 i18n/cht/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/cht/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json create mode 100644 i18n/deu/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/deu/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/deu/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/deu/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/deu/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/deu/extensions/npm/package.i18n.json create mode 100644 i18n/deu/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/deu/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json create mode 100644 i18n/esn/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/esn/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/esn/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/esn/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/esn/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/esn/extensions/npm/package.i18n.json create mode 100644 i18n/esn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/esn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json create mode 100644 i18n/fra/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/fra/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/fra/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/fra/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/fra/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/fra/extensions/npm/package.i18n.json create mode 100644 i18n/fra/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/fra/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json create mode 100644 i18n/ita/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/ita/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/ita/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/ita/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/ita/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/ita/extensions/npm/package.i18n.json create mode 100644 i18n/ita/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/ita/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json create mode 100644 i18n/jpn/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/jpn/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/jpn/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/jpn/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/jpn/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/jpn/extensions/npm/package.i18n.json create mode 100644 i18n/jpn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/jpn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json create mode 100644 i18n/kor/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/kor/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/kor/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/kor/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/kor/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/kor/extensions/npm/package.i18n.json create mode 100644 i18n/kor/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/kor/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json create mode 100644 i18n/ptb/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json create mode 100644 i18n/ptb/extensions/css/client/out/cssMain.i18n.json create mode 100644 i18n/ptb/extensions/css/package.i18n.json create mode 100644 i18n/ptb/extensions/extension-editing/out/packageDocumentHelper.i18n.json create mode 100644 i18n/ptb/extensions/git/out/askpass-main.i18n.json create mode 100644 i18n/ptb/extensions/git/out/commands.i18n.json create mode 100644 i18n/ptb/extensions/git/out/main.i18n.json create mode 100644 i18n/ptb/extensions/git/out/model.i18n.json create mode 100644 i18n/ptb/extensions/git/out/scmProvider.i18n.json create mode 100644 i18n/ptb/extensions/git/out/statusbar.i18n.json create mode 100644 i18n/ptb/extensions/git/package.i18n.json create mode 100644 i18n/ptb/extensions/grunt/out/main.i18n.json create mode 100644 i18n/ptb/extensions/grunt/package.i18n.json create mode 100644 i18n/ptb/extensions/gulp/out/main.i18n.json create mode 100644 i18n/ptb/extensions/gulp/package.i18n.json create mode 100644 i18n/ptb/extensions/html/client/out/htmlMain.i18n.json create mode 100644 i18n/ptb/extensions/html/package.i18n.json create mode 100644 i18n/ptb/extensions/jake/out/main.i18n.json create mode 100644 i18n/ptb/extensions/jake/package.i18n.json create mode 100644 i18n/ptb/extensions/javascript/out/features/bowerJSONContribution.i18n.json create mode 100644 i18n/ptb/extensions/javascript/out/features/packageJSONContribution.i18n.json create mode 100644 i18n/ptb/extensions/json/client/out/jsonMain.i18n.json create mode 100644 i18n/ptb/extensions/json/package.i18n.json create mode 100644 i18n/ptb/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/ptb/extensions/markdown/out/previewContentProvider.i18n.json create mode 100644 i18n/ptb/extensions/markdown/out/security.i18n.json create mode 100644 i18n/ptb/extensions/markdown/package.i18n.json create mode 100644 i18n/ptb/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/ptb/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/ptb/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/ptb/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/ptb/extensions/npm/package.i18n.json create mode 100644 i18n/ptb/extensions/php/out/features/validationProvider.i18n.json create mode 100644 i18n/ptb/extensions/php/package.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/features/bufferSyncSupport.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/features/completionItemProvider.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/features/implementationsCodeLensProvider.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/features/jsDocCompletionProvider.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/features/referencesCodeLensProvider.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/typescriptMain.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/typescriptServiceClient.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/utils/logger.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/utils/projectStatus.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/utils/typingsStatus.i18n.json create mode 100644 i18n/ptb/extensions/typescript/package.i18n.json create mode 100644 i18n/ptb/src/vs/base/browser/ui/actionbar/actionbar.i18n.json create mode 100644 i18n/ptb/src/vs/base/browser/ui/aria/aria.i18n.json create mode 100644 i18n/ptb/src/vs/base/browser/ui/findinput/findInput.i18n.json create mode 100644 i18n/ptb/src/vs/base/browser/ui/findinput/findInputCheckboxes.i18n.json create mode 100644 i18n/ptb/src/vs/base/browser/ui/inputbox/inputBox.i18n.json create mode 100644 i18n/ptb/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json create mode 100644 i18n/ptb/src/vs/base/browser/ui/toolbar/toolbar.i18n.json create mode 100644 i18n/ptb/src/vs/base/common/errorMessage.i18n.json create mode 100644 i18n/ptb/src/vs/base/common/jsonErrorMessages.i18n.json create mode 100644 i18n/ptb/src/vs/base/common/processes.i18n.json create mode 100644 i18n/ptb/src/vs/base/common/severity.i18n.json create mode 100644 i18n/ptb/src/vs/base/node/processes.i18n.json create mode 100644 i18n/ptb/src/vs/base/node/zip.i18n.json create mode 100644 i18n/ptb/src/vs/base/parts/quickopen/browser/quickOpenModel.i18n.json create mode 100644 i18n/ptb/src/vs/base/parts/quickopen/browser/quickOpenWidget.i18n.json create mode 100644 i18n/ptb/src/vs/base/parts/tree/browser/treeDefaults.i18n.json create mode 100644 i18n/ptb/src/vs/code/electron-main/menus.i18n.json create mode 100644 i18n/ptb/src/vs/code/electron-main/window.i18n.json create mode 100644 i18n/ptb/src/vs/code/electron-main/windows.i18n.json create mode 100644 i18n/ptb/src/vs/code/node/cliProcessMain.i18n.json create mode 100644 i18n/ptb/src/vs/editor/common/config/commonEditorConfig.i18n.json create mode 100644 i18n/ptb/src/vs/editor/common/config/editorOptions.i18n.json create mode 100644 i18n/ptb/src/vs/editor/common/controller/cursor.i18n.json create mode 100644 i18n/ptb/src/vs/editor/common/model/textModelWithTokens.i18n.json create mode 100644 i18n/ptb/src/vs/editor/common/modes/modesRegistry.i18n.json create mode 100644 i18n/ptb/src/vs/editor/common/services/bulkEdit.i18n.json create mode 100644 i18n/ptb/src/vs/editor/common/services/modeServiceImpl.i18n.json create mode 100644 i18n/ptb/src/vs/editor/common/services/modelServiceImpl.i18n.json create mode 100644 i18n/ptb/src/vs/editor/common/view/editorColorRegistry.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/accessibility/browser/accessibility.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/bracketMatching/common/bracketMatching.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/caretOperations/common/caretOperations.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/caretOperations/common/transpose.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/clipboard/browser/clipboard.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/comment/common/comment.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/contextmenu/browser/contextmenu.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/find/browser/findWidget.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/find/common/findController.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/folding/browser/folding.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/format/browser/formatActions.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/hover/browser/hover.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/hover/browser/modesContentHover.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/indentation/common/indentation.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/linesOperations/common/linesOperations.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/links/browser/links.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/multicursor/common/multicursor.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/parameterHints/browser/parameterHints.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/quickFix/browser/quickFixCommands.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesController.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/rename/browser/rename.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/rename/browser/renameInputField.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/smartSelect/common/smartSelect.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/suggest/browser/suggestController.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.i18n.json create mode 100644 i18n/ptb/src/vs/editor/electron-browser/textMate/TMSyntax.i18n.json create mode 100644 i18n/ptb/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json create mode 100644 i18n/ptb/src/vs/editor/node/textMate/TMGrammars.i18n.json create mode 100644 i18n/ptb/src/vs/platform/actions/browser/menuItemActionItem.i18n.json create mode 100644 i18n/ptb/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json create mode 100644 i18n/ptb/src/vs/platform/configuration/common/configurationRegistry.i18n.json create mode 100644 i18n/ptb/src/vs/platform/environment/node/argv.i18n.json create mode 100644 i18n/ptb/src/vs/platform/extensionManagement/common/extensionEnablementService.i18n.json create mode 100644 i18n/ptb/src/vs/platform/extensionManagement/common/extensionManagement.i18n.json create mode 100644 i18n/ptb/src/vs/platform/extensionManagement/node/extensionGalleryService.i18n.json create mode 100644 i18n/ptb/src/vs/platform/extensionManagement/node/extensionManagementService.i18n.json create mode 100644 i18n/ptb/src/vs/platform/extensions/common/abstractExtensionService.i18n.json create mode 100644 i18n/ptb/src/vs/platform/extensions/common/extensionsRegistry.i18n.json create mode 100644 i18n/ptb/src/vs/platform/extensions/node/extensionValidator.i18n.json create mode 100644 i18n/ptb/src/vs/platform/integrity/node/integrityServiceImpl.i18n.json create mode 100644 i18n/ptb/src/vs/platform/jsonschemas/common/jsonValidationExtensionPoint.i18n.json create mode 100644 i18n/ptb/src/vs/platform/keybinding/common/abstractKeybindingService.i18n.json create mode 100644 i18n/ptb/src/vs/platform/keybinding/common/keybindingLabels.i18n.json create mode 100644 i18n/ptb/src/vs/platform/markers/common/problemMatcher.i18n.json create mode 100644 i18n/ptb/src/vs/platform/message/common/message.i18n.json create mode 100644 i18n/ptb/src/vs/platform/request/node/request.i18n.json create mode 100644 i18n/ptb/src/vs/platform/telemetry/common/telemetryService.i18n.json create mode 100644 i18n/ptb/src/vs/platform/theme/common/colorRegistry.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/api/electron-browser/mainThreadExtensionService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/api/electron-browser/mainThreadMessageService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/api/node/extHostDiagnostics.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/api/node/extHostTreeViews.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/actions/configureLocale.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/actions/fileActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/actions/toggleActivityBarVisibility.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/actions/toggleEditorLayout.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/actions/toggleSidebarPosition.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/actions/toggleSidebarVisibility.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/actions/toggleStatusbarVisibility.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/actions/toggleZenMode.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/activitybar/activitybarActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/compositePart.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/binaryDiffEditor.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/binaryEditor.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/editor.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/editorActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/editorCommands.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/editorPart.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/editorPicker.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/tabsTitleControl.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/textDiffEditor.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/textEditor.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/textResourceEditor.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/titleControl.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/panel/panelActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/panel/panelPart.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/quickopen/quickOpenController.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/quickopen/quickopen.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/sidebar/sidebarPart.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/statusbar/statusbarPart.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/titlebar/titlebarPart.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/quickopen.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/viewlet.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/common/theme.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/electron-browser/actions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/electron-browser/commands.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/electron-browser/crashReporter.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/electron-browser/extensionHost.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/electron-browser/main.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/electron-browser/main.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/electron-browser/shell.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/electron-browser/window.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/node/extensionHostMain.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/node/extensionPoints.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/cli/electron-browser/cli.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderControlCharacter.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderWhitespace.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/wordWrapMigration.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/browser/breakpointWidget.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/browser/debugActionItems.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/browser/debugActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/browser/debugActionsWidget.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/browser/debugContentProvider.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/browser/debugEditorActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/browser/debugEditorModelManager.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/browser/debugQuickOpen.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/browser/exceptionWidget.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/browser/linkDetector.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/common/debug.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/common/debugModel.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/common/debugSource.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debug.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugConfigurationManager.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugHover.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugViewer.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/repl.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/replViewer.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/terminalSupport.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/browser/actions/showEmmetCommands.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/balance.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/matchingPair.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/mergeLines.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/reflectCssValue.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/selectItem.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/toggleComment.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/execution/electron-browser/terminal.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/execution/electron-browser/terminalService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorerActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorerService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/explorers/browser/views/treeExplorerView.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/browser/dependenciesViewer.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionsQuickOpen.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/common/extensionsFileTemplate.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/common/extensionsInput.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/feedback/electron-browser/feedback.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/editors/binaryFileEditor.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/editors/textFileEditor.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/fileActions.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/fileActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/fileCommands.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/files.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/saveErrorHandler.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/views/explorerView.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/views/explorerViewer.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsViewer.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/common/dirtyFilesTracker.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/html/browser/html.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/html/browser/htmlPreviewPart.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/html/browser/webview.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/markers/common/messages.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/markers/electron-browser/markersElectronContributions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/nps/electron-browser/nps.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/output/browser/output.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/output/browser/outputActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/output/browser/outputPanel.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/output/common/output.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingWidgets.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/browser/preferences.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesEditor.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesWidgets.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/common/preferencesModels.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/quickopen/browser/gotoLineHandler.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/quickopen/browser/gotoSymbolHandler.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/quickopen/browser/helpHandler.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/quickopen/browser/viewPickerHandler.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmActivity.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmViewlet.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/search/browser/openAnythingHandler.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/search/browser/openFileHandler.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/search/browser/openSymbolHandler.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/search/browser/patternInputWidget.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/search/browser/replaceService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/search/browser/search.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/search/browser/searchActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/search/browser/searchViewlet.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/search/browser/searchWidget.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/insertSnippet.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/snippetsService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/tabCompletion.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/common/taskTemplates.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/node/processRunnerDetector.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/trust/electron-browser/unsupportedWorkspaceSettings.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/update/electron-browser/releaseNotesInput.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/update/electron-browser/update.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/update/electron-browser/update.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/editor/editorWalkThrough.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThrough.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/editor/browser/editorService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/files/electron-browser/fileService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/files/node/fileService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/keybinding/common/keybindingEditing.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/keybinding/electron-browser/keybindingService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/message/browser/messageList.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/message/electron-browser/messageService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/mode/common/workbenchModeService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/textfile/common/textFileEditorModel.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/textfile/common/textFileService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/textfile/electron-browser/textFileService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/themes/common/colorThemeSchema.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/themes/common/fileIconThemeSchema.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/themes/electron-browser/colorThemeData.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json create mode 100644 i18n/rus/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/rus/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/rus/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/rus/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/rus/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/rus/extensions/npm/package.i18n.json create mode 100644 i18n/rus/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/rus/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json diff --git a/build/win32/i18n/messages.pt-br.isl b/build/win32/i18n/messages.pt-br.isl new file mode 100644 index 00000000000..7021e814e8f --- /dev/null +++ b/build/win32/i18n/messages.pt-br.isl @@ -0,0 +1,8 @@ +[CustomMessages] +AddContextMenuFiles=Adicione a ação "Abrir com %1" ao menu de contexto de arquivo do Windows Explorer +AddContextMenuFolders=Adicione a ação "Abrir com %1" ao menu de contexto de diretório do Windows Explorer +AssociateWithFiles=Registre %1 como um editor para tipos de arquivos suportados +AddToPath=Adicione em PATH (disponível após reiniciar) +RunAfter=Executar %1 após a instalação +Other=Outros: +SourceFile=Arquivo Fonte %1 \ No newline at end of file diff --git a/i18n/chs/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json b/i18n/chs/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json index 6ad910135a0..f40aa81fa48 100644 --- a/i18n/chs/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json +++ b/i18n/chs/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json @@ -5,7 +5,7 @@ // Do not edit this file. It is machine generated. { "activeEditorShort": "例如 myFile.txt", - "activeEditorMedium": "e.g. myFolder/myFile.txt", + "activeEditorMedium": "例如 myFolder/myFile.txt", "activeEditorLong": "例如 /Users/Development/myProject/myFolder/myFile.txt", "rootName": "例如 myProject", "rootPath": "例如 /Users/Development/myProject", diff --git a/i18n/chs/extensions/gulp/out/main.i18n.json b/i18n/chs/extensions/gulp/out/main.i18n.json index 500082cf82f..bda8a250c25 100644 --- a/i18n/chs/extensions/gulp/out/main.i18n.json +++ b/i18n/chs/extensions/gulp/out/main.i18n.json @@ -4,5 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "execFailed": "自动检测 gulp 失败,错误为: {0}" + "execFailed": "自动检测 gulp 失败,错误:{0}" } \ No newline at end of file diff --git a/i18n/chs/extensions/jake/out/main.i18n.json b/i18n/chs/extensions/jake/out/main.i18n.json index 8b6ad71cd4e..d2f56bdda98 100644 --- a/i18n/chs/extensions/jake/out/main.i18n.json +++ b/i18n/chs/extensions/jake/out/main.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "execFailed": "自动检测 Jake 失败,错误:{0}" +} \ No newline at end of file diff --git a/i18n/chs/extensions/jake/package.i18n.json b/i18n/chs/extensions/jake/package.i18n.json index 8b6ad71cd4e..46f020cf890 100644 --- a/i18n/chs/extensions/jake/package.i18n.json +++ b/i18n/chs/extensions/jake/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.jake.autoDetect": "控制自动检测 Jake 任务是å¦æ‰“开。默认开å¯ã€‚" +} \ No newline at end of file diff --git a/i18n/chs/extensions/markdown/out/extension.i18n.json b/i18n/chs/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/chs/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/chs/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/chs/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/chs/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/chs/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/chs/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/chs/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/chs/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/chs/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/chs/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/chs/extensions/merge-conflict/package.i18n.json b/i18n/chs/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/chs/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/chs/extensions/npm/package.i18n.json b/i18n/chs/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/chs/extensions/npm/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/chs/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/chs/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index 7b395b9c15a..4e5bf82d935 100644 --- a/i18n/chs/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/chs/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,8 +6,6 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "图åƒå¤ªå¤§ï¼Œæ— æ³•åœ¨ç¼–辑器中显示。 ", - "resourceOpenExternalButton": "打开图片", - "resourceOpenExternalText": " 是å¦ä½¿ç”¨å¤–部程åº?", "nativeBinaryError": "文件将ä¸åœ¨ç¼–辑器中显示,因为它是二进制文件ã€éžå¸¸å¤§æˆ–使用ä¸æ”¯æŒçš„文本编ç ã€‚", "sizeB": "{0} B", "sizeKB": "{0} KB", diff --git a/i18n/chs/src/vs/code/electron-main/menus.i18n.json b/i18n/chs/src/vs/code/electron-main/menus.i18n.json index 16b5dc1479a..4f7e61e056c 100644 --- a/i18n/chs/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/chs/src/vs/code/electron-main/menus.i18n.json @@ -146,7 +146,7 @@ "miInteractivePlayground": "交互å¼æ¼”练场(&&I)", "miDocumentation": "文档(&&D)", "miReleaseNotes": "å‘行说明(&&R)", - "miKeyboardShortcuts": "键盘快æ·æ–¹å¼å‚考(&&K)", + "miKeyboardShortcuts": "å¿«æ·é”®å‚考(&&K)", "miIntroductoryVideos": "介ç»æ€§è§†é¢‘(&&V)", "miTwitter": "在 Twitter 上加入我们(&&J)", "miUserVoice": "æœç´¢åŠŸèƒ½è¯·æ±‚(&&S)", @@ -159,6 +159,6 @@ "miDownloadingUpdate": "正在下载更新...", "miInstallingUpdate": "正在安装更新...", "miCheckForUpdates": "检查更新...", - "aboutDetail": "\n版本 {0}\næ交 {1}\n日期 {2}\nShell {3}\n呈现器 {4}\nNode {5}", + "aboutDetail": "\n版本 {0}\næ交 {1}\n日期 {2}\nShell {3}\n渲染器 {4}\nNode {5}", "okButton": "确定" } \ No newline at end of file diff --git a/i18n/chs/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/chs/src/vs/editor/common/config/commonEditorConfig.i18n.json index ad55e59f4eb..5c4e0b1ea13 100644 --- a/i18n/chs/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/chs/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -14,7 +14,7 @@ "rulers": "显示垂直标尺的列", "wordSeparators": "执行文字相关的导航或æ“作时将用作文字分隔符的字符", "tabSize": "一个制表符等于的空格数。该设置在 `editor.detectIndentation` å¯ç”¨æ—¶æ ¹æ®æ–‡ä»¶å†…容进行é‡å†™ã€‚", - "tabSize.errorMessage": "应为 \\\\\"number\\\\\"。注æ„,值\\\\\"auto\\\\\"已由 \\\\\"editor.detectIndentation\\\\\" 设置替æ¢ã€‚", + "tabSize.errorMessage": "应为“numberâ€ã€‚注æ„,值“autoâ€å·²ç”±â€œeditor.detectIndentationâ€è®¾ç½®æ›¿æ¢ã€‚", "insertSpaces": "按 \"Tab\" æ—¶æ’入空格。该设置在 `editor.detectIndentation` å¯ç”¨æ—¶æ ¹æ®æ–‡ä»¶å†…容进行é‡å†™ã€‚", "insertSpaces.errorMessage": "应为 \"boolean\"。注æ„,值 \"auto\" 已由 \"editor.detectIndentation\" 设置替æ¢ã€‚", "detectIndentation": "当打开文件时,将基于文件内容检测 \"editor.tabSize\" å’Œ \"editor.insertSpaces\"。", @@ -29,7 +29,7 @@ "wordWrap.bounded": "将在最å°è§†åŒºå’Œ \"editor.wordWrapColumn\" 处æ¢è¡Œã€‚", "wordWrap": "控制折行方å¼ã€‚å¯ä»¥é€‰æ‹©ï¼š - “off†(ç¦ç”¨æŠ˜è¡Œï¼‰ï¼Œ - “on†(视区折行), - “wordWrapColumnâ€ï¼ˆåœ¨â€œeditor.wordWrapColumnâ€å¤„折行)或 - “boundedâ€ï¼ˆåœ¨è§†åŒºä¸Žâ€œeditor.wordWrapColumnâ€ä¸¤è€…的较å°è€…处折行)。", "wordWrapColumn": "在 \"editor.wordWrap\" 为 \"wordWrapColumn\" 或 \"bounded\" 时控制编辑器列的æ¢è¡Œã€‚", - "wrappingIndent": "控制æ¢è¡Œçš„行的缩进。å¯ä»¥æ˜¯\\\\\"none\\\\\"〠\\\\\"same\\\\\" 或 \\\\\"indent\\\\\"。", + "wrappingIndent": "控制折行的缩进。å¯ä»¥æ˜¯â€œnoneâ€ã€â€œsameâ€æˆ–“indentâ€ã€‚", "mouseWheelScrollSensitivity": "è¦å¯¹é¼ æ ‡æ»šè½®æ»šåŠ¨äº‹ä»¶çš„ \"deltaX\" å’Œ \"deltaY\" 使用的乘数 ", "quickSuggestions.strings": "在字符串内å¯ç”¨å¿«é€Ÿå»ºè®®ã€‚", "quickSuggestions.comments": "在注释内å¯ç”¨å¿«é€Ÿå»ºè®®ã€‚", @@ -41,7 +41,6 @@ "formatOnType": "控制编辑器是å¦åº”在键入åŽè‡ªåŠ¨è®¾ç½®è¡Œçš„æ ¼å¼", "formatOnPaste": "控制编辑器是å¦åº”自动设置粘贴内容的格å¼ã€‚æ ¼å¼åŒ–程åºå¿…é¡»å¯ç”¨å¹¶ä¸”能设置文档中æŸä¸€èŒƒå›´çš„æ ¼å¼ã€‚", "suggestOnTriggerCharacters": "控制键入触å‘器字符时是å¦åº”自动显示建议", - "acceptSuggestionOnEnter": "控制除了 \"Tab\" 键以外,是å¦è¿˜åº”在é‡åˆ° \"Enter\" 键时接å—建议。帮助é¿å…“æ’入新行â€æˆ–“接å—建议â€ä¹‹é—´å‡ºçŽ°æ­§ä¹‰ã€‚", "acceptSuggestionOnCommitCharacter": "控制是å¦åº”在é‡åˆ°æ交字符时接å—建议。例如,在 JavaScript 中,分å·(\";\")å¯ä»¥ä¸ºæ交字符,å¯æŽ¥å—建议并键入该字符。", "snippetSuggestions": "控制是å¦å°†ä»£ç æ®µä¸Žå…¶ä»–建议一起显示以åŠå®ƒä»¬çš„排åºæ–¹å¼ã€‚", "emptySelectionClipboard": "控制没有选择内容的å¤åˆ¶æ˜¯å¦å¤åˆ¶å½“å‰è¡Œã€‚", @@ -63,6 +62,7 @@ "renderLineHighlight": "控制编辑器应如何呈现当å‰è¡Œçªå‡ºæ˜¾ç¤ºï¼Œå¯èƒ½ä¸ºâ€œæ— â€ã€â€œè£…订线â€ã€â€œçº¿â€å’Œâ€œå…¨éƒ¨â€ã€‚", "codeLens": "控制编辑器是å¦æ˜¾ç¤ºä»£ç æ»¤é•œ", "folding": "控制编辑器是å¦å¯ç”¨ä»£ç æŠ˜å åŠŸèƒ½", + "showFoldingControls": "控制是å¦è‡ªåŠ¨éšè—导航线上的折å æŽ§ä»¶ã€‚", "matchBrackets": "当选择其中一项时,将çªå‡ºæ˜¾ç¤ºåŒ¹é…的括å·ã€‚", "glyphMargin": "控制编辑器是å¦åº”呈现垂直字形边è·ã€‚字形边è·æœ€å¸¸ç”¨äºŽè°ƒè¯•ã€‚", "useTabStops": "在制表ä½åŽæ’入和删除空格", diff --git a/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..e788771d2f2 --- /dev/null +++ b/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "未找到“{0}â€çš„任何定义", + "generic.noResults": "找ä¸åˆ°å®šä¹‰", + "meta.title": " – {0} 定义", + "actions.goToDecl.label": "转到定义", + "actions.goToDeclToSide.label": "打开侧边的定义", + "actions.previewDecl.label": "查看定义", + "goToImplementation.noResultWord": "未找到“{0}â€çš„实现", + "goToImplementation.generic.noResults": "未找到实现", + "meta.implementations.title": "– {0} 个实现", + "actions.goToImplementation.label": "转到实现", + "actions.peekImplementation.label": "速览实现", + "goToTypeDefinition.noResultWord": "未找到“{0}â€çš„类型定义", + "goToTypeDefinition.generic.noResults": "未找到类型定义", + "meta.typeDefinitions.title": " – {0} 个类型定义", + "actions.goToTypeDefinition.label": "转到类型定义", + "actions.peekTypeDefinition.label": "快速查看类型定义" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..ab0b4761cf9 --- /dev/null +++ b/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "å•å‡»æ˜¾ç¤º {0} 个定义。" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/editor/contrib/indentation/common/indentation.i18n.json b/i18n/chs/src/vs/editor/contrib/indentation/common/indentation.i18n.json index 76fa4543d53..5bd5906da32 100644 --- a/i18n/chs/src/vs/editor/contrib/indentation/common/indentation.i18n.json +++ b/i18n/chs/src/vs/editor/contrib/indentation/common/indentation.i18n.json @@ -8,7 +8,7 @@ "indentationToTabs": "将缩进转æ¢ä¸ºåˆ¶è¡¨ç¬¦", "configuredTabSize": "å·²é…置制表符大å°", "selectTabWidth": "选择当å‰æ–‡ä»¶çš„制表符大å°", - "indentUsingTabs": "使用 \\\\\"Tab\\\\\" 缩进", + "indentUsingTabs": "使用“Tabâ€ç¼©è¿›", "indentUsingSpaces": "使用空格缩进", "detectIndentation": "检查内容中的缩进", "editor.reindentlines": "é‡æ–°ç¼©è¿›è¡Œ" diff --git a/i18n/chs/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json b/i18n/chs/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json index 4e1a0a30e42..ec34ba659f1 100644 --- a/i18n/chs/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json +++ b/i18n/chs/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json @@ -9,7 +9,7 @@ "editorSuggestWidgetForeground": "建议å°ç»„件的å‰æ™¯é¢œè‰²ã€‚", "editorSuggestWidgetSelectedBackground": "建议å°ç»„件中被选择æ¡ç›®çš„背景颜色。", "editorSuggestWidgetHighlightForeground": "建议å°ç»„件中匹é…内容的高亮颜色。", - "readMore": "阅读更多...{0}", + "readMore": "阅读详细信æ¯...{0}", "suggestionWithDetailsAriaLabel": "{0}(建议)具有详细信æ¯", "suggestionAriaLabel": "{0},建议", "readLess": "阅读简略信æ¯...{0}", diff --git a/i18n/chs/src/vs/platform/configuration/common/configurationRegistry.i18n.json b/i18n/chs/src/vs/platform/configuration/common/configurationRegistry.i18n.json index ea616506b8e..781727fae4d 100644 --- a/i18n/chs/src/vs/platform/configuration/common/configurationRegistry.i18n.json +++ b/i18n/chs/src/vs/platform/configuration/common/configurationRegistry.i18n.json @@ -10,7 +10,7 @@ "vscode.extension.contributes.configuration": "用于é…置字符串。", "vscode.extension.contributes.configuration.title": "设置摘è¦ã€‚此标签将在设置文件中用作分隔注释。", "vscode.extension.contributes.configuration.properties": "é…置属性的æ述。", - "config.property.languageDefault": "无法注册“{0}â€ã€‚这符åˆå±žæ€§æ¨¡å¼ \"\\\\[.*\\\\]$\",å¯ç”¨äºŽæ述特定语言编辑器设置。请使用 \"configurationDefaults\"。", + "config.property.languageDefault": "无法注册“{0}â€ã€‚其符åˆæè¿°ç‰¹å®šè¯­è¨€ç¼–è¾‘å™¨è®¾ç½®çš„è¡¨è¾¾å¼ \"\\\\[.*\\\\]$\"。请使用 \"configurationDefaults\"。", "config.property.duplicate": "无法注册“{0}â€ã€‚此属性已注册。", "invalid.properties": "configuration.properties 必须是对象", "invalid.type": "如果进行设置,\"configuration.type\" 必须设置为对象", diff --git a/i18n/chs/src/vs/platform/markers/common/problemMatcher.i18n.json b/i18n/chs/src/vs/platform/markers/common/problemMatcher.i18n.json index 7dc0d66e0aa..b9fc2ddbbde 100644 --- a/i18n/chs/src/vs/platform/markers/common/problemMatcher.i18n.json +++ b/i18n/chs/src/vs/platform/markers/common/problemMatcher.i18n.json @@ -34,6 +34,7 @@ "ProblemMatcherParser.noValidIdentifier": "错误: 模å¼å±žæ€§ {0} 是无效的模å¼å˜é‡å。", "ProblemMatcherParser.problemPattern.watchingMatcher": "问题匹é…程åºå¿…须定义监视的开始模å¼å’Œç»“æŸæ¨¡å¼ã€‚", "ProblemMatcherParser.invalidRegexp": "错误: 字符串 {0} ä¸æ˜¯æœ‰æ•ˆçš„正则表达å¼ã€‚\n", + "WatchingPatternSchema.regexp": "用于检测åŽå°ä»»åŠ¡å¼€å§‹æˆ–结æŸçš„正则表达å¼ã€‚", "WatchingPatternSchema.file": "文件å的匹é…组索引。å¯ä»¥çœç•¥ã€‚", "PatternTypeSchema.name": "所æ供或预定义模å¼çš„å称", "PatternTypeSchema.description": "问题模å¼æˆ–者所æ供或预定义问题模å¼çš„å称。如果已指定基准,则å¯ä»¥çœç•¥ã€‚", @@ -42,6 +43,12 @@ "ProblemMatcherSchema.severity": "æ•èŽ·é—®é¢˜çš„默认严é‡æ€§ã€‚如果模å¼æœªå®šä¹‰ä¸¥é‡æ€§çš„匹é…组,则使用。", "ProblemMatcherSchema.applyTo": "控制文本文档上报告的问题是å¦ä»…应用于打开ã€å…³é—­æˆ–所有文档。", "ProblemMatcherSchema.fileLocation": "定义应如何解释问题模å¼ä¸­æŠ¥å‘Šçš„文件å。", + "ProblemMatcherSchema.background": "用于跟踪在åŽå°ä»»åŠ¡ä¸Šæ¿€æ´»çš„匹é…程åºçš„开始和结æŸçš„模å¼ã€‚", + "ProblemMatcherSchema.background.activeOnStart": "如果设置为 true,则会在任务开始时激活åŽå°ç›‘控。这相当于å‘出与 beginPattern 匹é…的行。", + "ProblemMatcherSchema.background.beginsPattern": "如果在输出内匹é…,则会å‘出åŽå°ä»»åŠ¡å¼€å§‹çš„ä¿¡å·ã€‚", + "ProblemMatcherSchema.background.endsPattern": "如果在输出内匹é…,则会å‘出åŽå°ä»»åŠ¡ç»“æŸçš„ä¿¡å·ã€‚", + "ProblemMatcherSchema.watching.deprecated": "“watchingâ€å±žæ€§å·²è¢«å¼ƒç”¨ã€‚请改用“backgroundâ€ã€‚", + "ProblemMatcherSchema.watching": "用于跟踪监视匹é…程åºå¼€å§‹å’Œç»“æŸçš„模å¼ã€‚", "ProblemMatcherSchema.watching.activeOnStart": "如果设置为 true,则当任务开始时观察程åºå¤„于活动模å¼ã€‚这相当于å‘出与 beginPattern 匹é…的行。", "ProblemMatcherSchema.watching.beginsPattern": "如果在输出内匹é…,则在监视任务开始时会å‘出信å·ã€‚", "ProblemMatcherSchema.watching.endsPattern": "如果在输出内匹é…,则在监视任务结æŸæ—¶ä¼šå‘出信å·ã€‚", diff --git a/i18n/chs/src/vs/workbench/api/node/extHostTreeViews.i18n.json b/i18n/chs/src/vs/workbench/api/node/extHostTreeViews.i18n.json index 8b6ad71cd4e..7bfb0b886de 100644 --- a/i18n/chs/src/vs/workbench/api/node/extHostTreeViews.i18n.json +++ b/i18n/chs/src/vs/workbench/api/node/extHostTreeViews.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "treeView.notRegistered": "没有注册 ID 为“{0}â€çš„树形图。", + "treeItem.notFound": "没有在树中找到 ID 为“{0}â€çš„项目。", + "treeView.duplicateElement": "已注册元素 {0}。" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/common/theme.i18n.json b/i18n/chs/src/vs/workbench/common/theme.i18n.json index 64c51b8e74c..0f3e7eb1bf9 100644 --- a/i18n/chs/src/vs/workbench/common/theme.i18n.json +++ b/i18n/chs/src/vs/workbench/common/theme.i18n.json @@ -32,6 +32,7 @@ "activityBarBadgeBackground": "活动通知徽章背景色。活动æ æ˜¾ç¤ºåœ¨æœ€å·¦ä¾§æˆ–最å³ä¾§ï¼Œå¹¶å…许在侧边æ çš„视图间切æ¢ã€‚", "activityBarBadgeForeground": "活动通知徽章å‰æ™¯è‰²ã€‚活动æ æ˜¾ç¤ºåœ¨æœ€å·¦ä¾§æˆ–最å³ä¾§ï¼Œå¹¶å…许在侧边æ çš„视图间切æ¢ã€‚", "sideBarBackground": "侧边æ èƒŒæ™¯è‰²ã€‚侧边æ æ˜¯èµ„æºç®¡ç†å™¨å’Œæœç´¢ç­‰è§†å›¾çš„容器。", + "sideBarForeground": "侧边æ å‰æ™¯è‰²ã€‚侧边æ æ˜¯èµ„æºç®¡ç†å™¨å’Œæœç´¢ç­‰è§†å›¾çš„容器。", "sideBarTitleForeground": "侧边æ æ ‡é¢˜å‰æ™¯è‰²ã€‚侧边æ æ˜¯èµ„æºç®¡ç†å™¨å’Œæœç´¢ç­‰è§†å›¾çš„容器。", "sideBarSectionHeaderBackground": "侧边æ èŠ‚标题的背景颜色。侧边æ æ˜¯èµ„æºç®¡ç†å™¨å’Œæœç´¢ç­‰è§†å›¾çš„容器。", "titleBarActiveForeground": "窗å£å¤„于活动状æ€æ—¶çš„标题æ å‰æ™¯è‰²ã€‚请注æ„,该颜色当å‰ä»…在 macOS 上å—支æŒã€‚", diff --git a/i18n/chs/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/chs/src/vs/workbench/electron-browser/main.contribution.i18n.json index 375f183373b..6997449c1ce 100644 --- a/i18n/chs/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/chs/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -7,6 +7,7 @@ "view": "查看", "help": "帮助", "file": "文件", + "developer": "å¼€å‘者", "showEditorTabs": "控制打开的编辑器是å¦æ˜¾ç¤ºåœ¨é€‰é¡¹å¡ä¸­ã€‚", "editorTabCloseButton": "控制编辑器的选项å¡å…³é—­æŒ‰é’®çš„ä½ç½®ï¼Œæˆ–当设置为 \"off\" æ—¶ç¦ç”¨å…³é—­å®ƒä»¬ã€‚", "showIcons": "控制打开的编辑器是å¦éšå›¾æ ‡ä¸€èµ·æ˜¾ç¤ºã€‚这还需å¯ç”¨å›¾æ ‡ä¸»é¢˜ã€‚", diff --git a/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json b/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json index a188f9c1e90..b163a2de99e 100644 --- a/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json @@ -4,5 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "workbench.action.inspectKeyMap": "å¼€å‘者:检查键映射" + "workbench.action.inspectKeyMap": "å¼€å‘者: 检查键映射" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json b/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json index 8d541bedfe0..a7b3e519e7d 100644 --- a/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json @@ -6,6 +6,6 @@ { "toggle.wordwrap": "查看: 切æ¢è‡ªåŠ¨æ¢è¡Œ", "wordWrap.notInDiffEditor": "ä¸èƒ½åœ¨å·®å¼‚编辑器中切æ¢è‡ªåŠ¨æ¢è¡Œã€‚", - "unwrapMinified": "为此文件ç¦ç”¨æ¢è¡Œ", + "unwrapMinified": "为此文件ç¦ç”¨æŠ˜è¡Œ", "wrapMinified": "为此文件å¯ç”¨æ¢è¡Œ" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json b/i18n/chs/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json index c322b5a660a..54243f83ce3 100644 --- a/i18n/chs/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json @@ -7,6 +7,7 @@ "debugAdapterBinNotFound": "调试适é…器å¯æ‰§è¡Œçš„“{0}â€ä¸å­˜åœ¨ã€‚", "debugAdapterCannotDetermineExecutable": "无法确定调试适é…器“{0}â€çš„å¯æ‰§è¡Œæ–‡ä»¶ã€‚", "debugType": "é…置类型。", + "debugTypeNotRecognised": "无法识别此调试类型。确ä¿å·²ç»å®‰è£…并å¯ç”¨ç›¸åº”的调试扩展。", "node2NotSupported": "ä¸å†æ”¯æŒ \"node2\",改用 \"node\",并将 \"protocol\" 属性设为 \"inspector\"。", "debugName": "é…ç½®å称;在å¯åŠ¨é…置下拉èœå•ä¸­æ˜¾ç¤ºã€‚", "debugRequest": "请求é…置类型。å¯ä»¥æ˜¯â€œå¯åŠ¨â€æˆ–“附加â€ã€‚", diff --git a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json index 0598c67b46e..f4159d50b0e 100644 --- a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json @@ -4,5 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "evaluateMathExpression": "Emmet: 评估数学表达å¼" + "evaluateMathExpression": "Emmet: 求数学表达å¼çš„值" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json index 403f855e5eb..81f7dcfcab1 100644 --- a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json @@ -4,10 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "incrementNumberByOneTenth": "Emmet: 以 0.1 为增é‡", - "incrementNumberByOne": "Emmet: 以 1 为增é‡", - "incrementNumberByTen": "Emmet: 以 10 为增é‡", - "decrementNumberByOneTenth": "Emmet: 以 0.1 为å‡é‡", - "decrementNumberByOne": "Emmet: 以 1 为å‡é‡", - "decrementNumberByTen": "Emmet: 以 10 为å‡é‡" + "incrementNumberByOneTenth": "Emmet: 增加 0.1", + "incrementNumberByOne": "Emmet: 增加 1", + "incrementNumberByTen": "Emmet: 增加 10", + "decrementNumberByOneTenth": "Emmet: å‡å°‘ 0.1", + "decrementNumberByOne": "Emmet: å‡å°‘ 1", + "decrementNumberByTen": "Emmet: å‡å°‘ 10" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json index b58d42bcafe..545f1c107e7 100644 --- a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json @@ -4,5 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "removeTag": "Emmet: 删除标记" + "removeTag": "Emmet: 删除标签" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json index 5796a0dcab8..53e4eaafbd9 100644 --- a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json @@ -4,5 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "splitJoinTag": "Emmet: 分离/è”接标记" + "splitJoinTag": "Emmet: 分离/è”接标签" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json index c5d6fd7b350..d68725525c8 100644 --- a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json @@ -4,5 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "updateImageSize": "Emmet: 更新映åƒå¤§å°" + "updateImageSize": "Emmet: 更新图åƒå¤§å°" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json index 486e5397c4b..8bf2821c120 100644 --- a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "updateTag": "Emmet: 更新标记", - "enterTag": "输入标记", - "tag": "标记" + "updateTag": "Emmet: 更新标签", + "enterTag": "输入标签", + "tag": "标签" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json index dbca7bf9016..21f0c06d363 100644 --- a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "wrapWithAbbreviationAction": "Emmet: 使用缩写进行包装", + "wrapWithAbbreviationAction": "Emmet: 使用缩写进行包围", "enterAbbreviation": "输入缩写", "abbreviation": "缩写" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json index 6a402e79e1e..0701c9f4ae6 100644 --- a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json @@ -6,8 +6,8 @@ { "emmetConfigurationTitle": "Emmet", "triggerExpansionOnTab": "å¯ç”¨åŽï¼ŒæŒ‰ TAB 键时,将展开 Emmet 缩写。", - "emmetPreferences": "用于修改 Emmet çš„æŸäº›æ“作和解决程åºçš„首选项。", + "emmetPreferences": "用于修改 Emmet æŸäº›æ“作和解æžç¨‹åºçš„行为的首选项。", "emmetSyntaxProfiles": "为指定的语法定义é…置文件或使用带有特定规则的é…置文件。", - "emmetExclude": "emmet 缩写ä¸åº”在其中展开的语言数组。", - "emmetExtensionsPath": "è½¬è‡³åŒ…å« Emmet é…置文件ã€ç‰‡æ®µå’Œé¦–选项的文件的路径" + "emmetExclude": "ä¸åº”展开 Emmet 缩写的语言数组。", + "emmetExtensionsPath": "åŒ…å« Emmet é…置文件ã€ä»£ç æ®µå’Œé¦–选项的文件夹路径" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json b/i18n/chs/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json index 5d52f90d627..076eadb1e72 100644 --- a/i18n/chs/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json @@ -4,11 +4,11 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "vscode.extension.contributes.view": "贡献自定义视图", + "vscode.extension.contributes.view": "添加自定义视图", "vscode.extension.contributes.view.id": "用于标识通过 vscode.workspace.createTreeView 创建的视图的唯一 ID", "vscode.extension.contributes.view.label": "用于呈现视图的人类å¯è¯»çš„字符串", "vscode.extension.contributes.view.icon": "视图图标的路径", - "vscode.extension.contributes.views": "贡献自定义视图", + "vscode.extension.contributes.views": "添加自定义视图", "showViewlet": "显示 {0}", "view": "查看" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/chs/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 8b6ad71cd4e..5a4bf096f38 100644 --- a/i18n/chs/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "disableOtherKeymapsConfirmation": "是å¦ç¦ç”¨å…¶ä»–键映射以é¿å…键绑定之间的冲çª?", + "yes": "是", + "no": "å¦" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/chs/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index ba343731820..5813db26a24 100644 --- a/i18n/chs/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,7 +16,6 @@ "associations": "é…置语言的文件关è”(如: \"*.extension\": \"html\")。这些关è”的优先级高于已安装语言的默认关è”。", "encoding": "读å–和编写文件时将使用的默认字符集编ç ã€‚", "autoGuessEncoding": "å¯ç”¨æ—¶ï¼Œä¼šåœ¨æ‰“开文件时å°è¯•çŒœæµ‹å­—符集编ç ", - "eol": "默认行尾字符。", "trimTrailingWhitespace": "å¯ç”¨åŽï¼Œå°†åœ¨ä¿å­˜æ–‡ä»¶æ—¶å‰ªè£å°¾éšç©ºæ ¼ã€‚", "insertFinalNewline": "å¯ç”¨åŽï¼Œä¿å­˜æ–‡ä»¶æ—¶åœ¨æ–‡ä»¶æœ«å°¾æ’入一个最终新行。", "files.autoSave.off": "æ°¸ä¸è‡ªåŠ¨ä¿å­˜æ›´æ–°åŽçš„文件。", diff --git a/i18n/chs/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json b/i18n/chs/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json index f4fa6caa5bc..9745dba4538 100644 --- a/i18n/chs/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json @@ -4,5 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "orphanedFile": "{0} (deleted from disk)" + "orphanedFile": "{0} (ç£ç›˜ä¸Šå·²åˆ é™¤)" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/chs/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index dbd6be98f3e..bb7e4ea7afa 100644 --- a/i18n/chs/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -5,5 +5,11 @@ // Do not edit this file. It is machine generated. { "slow": "检测到å¯åŠ¨ç¼“æ…¢", - "slow.detail": "抱歉,出现了å¯åŠ¨ç¼“慢的情况。请é‡å¯â€œ{0}â€å¹¶å¯ç”¨åˆ†æžï¼Œå°†åˆ†æžæ–‡ä»¶ä¸Žæˆ‘们共享,我们会努力æ高å¯åŠ¨é€Ÿåº¦ã€‚" + "slow.detail": "抱歉,出现了å¯åŠ¨ç¼“慢的情况。请é‡å¯â€œ{0}â€å¹¶å¯ç”¨åˆ†æžï¼Œå°†åˆ†æžæ–‡ä»¶ä¸Žæˆ‘们共享,我们会努力æ高å¯åŠ¨é€Ÿåº¦ã€‚", + "prof.message": "å·²æˆåŠŸåˆ›å»ºæ述文件。", + "prof.detail": "请创建问题并手动附加以下文件:\n{0}", + "prof.restartAndFileIssue": "创建问题并é‡å¯", + "prof.restart": "é‡å¯", + "prof.thanks": "感谢您的帮助。", + "prof.detail.restart": "需è¦é‡æ–°å¯åŠ¨æ‰èƒ½ç»§ç»­ä½¿ç”¨â€œ{0}â€ã€‚å†æ¬¡æ„Ÿè°¢æ‚¨çš„贡献。" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json b/i18n/chs/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json index d4d305eba54..3461ec0a523 100644 --- a/i18n/chs/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json @@ -4,11 +4,11 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "keybindingsInputName": "键盘快æ·é”®", + "keybindingsInputName": "键盘快æ·æ–¹å¼", "SearchKeybindings.AriaLabel": "æœç´¢é”®ç»‘定", "SearchKeybindings.Placeholder": "æœç´¢é”®ç»‘定", "sortByPrecedene": "按优先级排åº", - "header-message": "用于高级自定义打开和编辑", + "header-message": "高级自定义请打开和编辑", "keybindings-file-name": "keybindings.json", "keybindingsLabel": "键绑定", "changeLabel": "更改键绑定", diff --git a/i18n/chs/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json b/i18n/chs/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json index 058e01cd6bf..72a81c0af68 100644 --- a/i18n/chs/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json @@ -6,7 +6,7 @@ { "openGlobalSettings": "打开用户设置", "openGlobalKeybindings": "打开键盘快æ·æ–¹å¼", - "openGlobalKeybindingsFile": "打开键盘快æ·é”®æ–‡ä»¶", + "openGlobalKeybindingsFile": "打开键盘快æ·æ–¹å¼æ–‡ä»¶", "openWorkspaceSettings": "打开工作区设置", "configureLanguageBasedSettings": "é…置语言特定的设置...", "languageDescriptionConfigured": "({0})", diff --git a/i18n/chs/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json b/i18n/chs/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json index ab4166d5cd7..8ea8ff4f96e 100644 --- a/i18n/chs/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json @@ -4,7 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "toggleGitViewlet": "显示 GIT", + "toggleGitViewlet": "显示 Git", + "installAdditionalSCMProviders": "安装其他 SCM æ供程åº...", "source control": "æºä»£ç ç®¡ç†", "toggleSCMViewlet": "显示 SCM", "view": "查看" diff --git a/i18n/chs/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json b/i18n/chs/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json index f03d74e8c9d..89c41c7a05b 100644 --- a/i18n/chs/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "switch provider": "åˆ‡æ¢ SCM æ供程åº..." + "installAdditionalSCMProviders": "安装其他 SCM æ供程åº...", + "switch provider": "切æ¢æºä»£ç ç®¡ç†ç³»ç»Ÿ..." } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json b/i18n/chs/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json index 0c4154de4e5..340ee7fc03e 100644 --- a/i18n/chs/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "vscode.extension.contributes.snippets": "贡献代ç æ®µã€‚", + "vscode.extension.contributes.snippets": "添加代ç æ®µã€‚", "vscode.extension.contributes.snippets-language": "此代ç ç‰‡æ®µå‚与的语言标识符。", "vscode.extension.contributes.snippets-path": "代ç ç‰‡æ®µæ–‡ä»¶çš„路径。该路径相对于扩展文件夹,通常以 \"./snippets/\" 开头。", "invalid.language": "“contributes.{0}.languageâ€ä¸­å­˜åœ¨æœªçŸ¥çš„语言。æ供的值: {1}", diff --git a/i18n/chs/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/chs/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index bf5eec2631c..48bcbb508c2 100644 --- a/i18n/chs/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,5 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0},任务" + "entryAriaLabel": "{0},任务", + "workspace": "æ¥è‡ªå·¥ä½œåŒº", + "extension": "æ¥è‡ªæ‰©å±•" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json b/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json index 2132313f0b6..f5f009904e1 100644 --- a/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json @@ -6,5 +6,6 @@ { "TerminalTaskSystem.unknownError": "在执行任务时å‘生未知错误。请å‚è§ä»»åŠ¡è¾“出日志了解详细信æ¯ã€‚", "TerminalTaskSystem.terminalName": "任务 - {0}", - "TerminalTaskSystem": "无法对 UNC 驱动器执行 shell 命令。" + "TerminalTaskSystem": "无法对 UNC 驱动器执行 shell 命令。", + "unkownProblemMatcher": "无法解æžé—®é¢˜åŒ¹é…ç¨‹åº {0}。此匹é…程åºå°†è¢«å¿½ç•¥" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json b/i18n/chs/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json index aa659de1014..5b8a86d9c21 100644 --- a/i18n/chs/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json @@ -7,5 +7,6 @@ "TaskRunnerSystem.unknownError": "在执行任务时å‘生未知错误。请å‚è§ä»»åŠ¡è¾“出日志了解详细信æ¯ã€‚", "TaskRunnerSystem.watchingBuildTaskFinished": "\n监视生æˆä»»åŠ¡å·²å®Œæˆ", "TaskRunnerSystem.childProcessError": "Failed to launch external program {0} {1}.", - "TaskRunnerSystem.cancelRequested": "\n已根æ®ç”¨æˆ·è¯·æ±‚终止了任务'{0}' " + "TaskRunnerSystem.cancelRequested": "\n已根æ®ç”¨æˆ·è¯·æ±‚终止了任务'{0}' ", + "unkownProblemMatcher": "无法解æžé—®é¢˜åŒ¹é…ç¨‹åº {0}。此匹é…程åºå°†è¢«å¿½ç•¥" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json b/i18n/chs/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json index 082e49f08bc..076dd52ebbb 100644 --- a/i18n/chs/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json @@ -17,7 +17,7 @@ "watermark.selectTheme": "更改主题", "watermark.selectKeymap": "更改键映射", "watermark.keybindingsReference": "键盘å‚考", - "watermark.openGlobalKeybindings": "键盘快æ·é”®", + "watermark.openGlobalKeybindings": "键盘快æ·æ–¹å¼(&&K)", "watermark.unboundCommand": "未绑定", "workbenchConfigurationTitle": "工作å°", "tips.enabled": "å¯ç”¨åŽï¼Œå½“没有打开编辑器时将显示水å°æ示。" diff --git a/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json index 3b9d1ffa9ca..3503db3576a 100644 --- a/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -9,18 +9,23 @@ "welcomePage.start": "开始", "welcomePage.newFile": "新建文件", "welcomePage.openFolder": "打开文件夹...", - "welcomePage.cloneGitRepository": "克隆 GIT 存储库...", + "welcomePage.cloneGitRepository": "克隆 Git 存储库...", "welcomePage.recent": "最近", "welcomePage.moreRecent": "更多...", "welcomePage.noRecentFolders": "无最近使用文件夹", "welcomePage.help": "帮助", + "welcomePage.keybindingsCheatsheet": "å¯æ‰“å°çš„键盘速查表", "welcomePage.introductoryVideos": "入门视频", "welcomePage.productDocumentation": "产å“文档", "welcomePage.gitHubRepository": "GitHub 存储库", "welcomePage.stackOverflow": "Stack Overflow", "welcomePage.showOnStartup": "å¯åŠ¨æ—¶æ˜¾ç¤ºæ¬¢è¿Žé¡µ", "welcomePage.customize": "自定义", + "welcomePage.installExtensionPacks": "工具和语言", + "welcomePage.installExtensionPacksDescription": "安装对 {0} å’Œ {1} 的支æŒ", + "welcomePage.moreExtensions": "更多", "welcomePage.installKeymapDescription": "安装键盘快æ·æ–¹å¼", + "welcomePage.installKeymapExtension": "安装 {0} å’Œ {1} 的键盘快æ·æ–¹å¼", "welcomePage.others": "其他", "welcomePage.colorTheme": "颜色主题", "welcomePage.colorThemeDescription": "使编辑器和代ç å‘ˆçŽ°ä½ å–œæ¬¢çš„外观", diff --git a/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index de7e3aa24d5..07f438f169e 100644 --- a/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -5,11 +5,25 @@ // Do not edit this file. It is machine generated. { "welcomePage": "欢迎使用", + "welcomePage.javaScript": "JavaScript", + "welcomePage.typeScript": "TypeScript", + "welcomePage.python": "Python", + "welcomePage.php": "PHP", + "welcomePage.docker": "Docker", + "welcomePage.vim": "Vim", + "welcomePage.sublime": "Sublime", + "welcomePage.atom": "Atom", + "welcomePage.extensionPackAlreadyInstalled": "已安装对 {0} 的支æŒã€‚", + "welcomePage.willReloadAfterInstallingExtensionPack": "安装对 {0} 的支æŒåŽï¼Œå°†é‡è½½çª—å£ã€‚", + "welcomePage.installingExtensionPack": "正在安装对 {0} 的支æŒ...", + "welcomePage.extensionPackNotFound": "找ä¸åˆ°å¯¹ {0} (ID: {1}) 的支æŒã€‚", "welcomePage.keymapAlreadyInstalled": "已安装 {0} 键盘快æ·æ–¹å¼ã€‚", "welcomePage.willReloadAfterInstallingKeymap": "安装 {0} 键盘快æ·æ–¹å¼åŽï¼Œå°†é‡è½½çª—å£ã€‚", "welcomePage.installingKeymap": "正在安装 {0} 键盘快æ·æ–¹å¼...", "welcomePage.keymapNotFound": "找ä¸åˆ° ID 为 {1} çš„ {0} 键盘快æ·æ–¹å¼ã€‚", "welcome.title": "欢迎使用", + "welcomePage.extensionListSeparator": ",", + "welcomePage.installedExtension": "{0}(已安装)", "ok": "确定", "cancel": "å–消", "welcomePage.quickLinkBackground": "欢迎页快速链接的背景颜色。", diff --git a/i18n/chs/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json b/i18n/chs/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json index 69e35ac02d6..4abe2dbd4b8 100644 --- a/i18n/chs/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json +++ b/i18n/chs/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json @@ -14,18 +14,18 @@ "vscode.extension.contributes.iconThemes.label": "UI 中显示的图标主题的标签。", "vscode.extension.contributes.iconThemes.path": "图标主题定义文件的路径。该路径相对于扩展文件夹,通常是 \"./icons/awesome-icon-theme.json\"。", "migration.completed": "å·²å‘用户设置添加了新的主题设置。{0} 中å¯å¤‡ä»½ã€‚", - "error.cannotloadtheme": "Unable to load {0}: {1}", - "reqarray": "Extension point `{0}` must be an array.", + "error.cannotloadtheme": "无法加载 {0}: {1}", + "reqarray": "扩展点“{0}â€å¿…须是一个数组。", "reqpath": "“contributes.{0}.pathâ€ä¸­åº”为字符串。æ供的值: {1}", "invalid.path.1": "“contributes.{0}.pathâ€({1})应包å«åœ¨æ‰©å±•çš„文件夹({2})内。这å¯èƒ½ä¼šä½¿æ‰©å±•ä¸å¯ç§»æ¤ã€‚", "reqid": "“contributes.{0}.idâ€ä¸­åº”为字符串。æ供的值: {1}", "error.cannotloadicontheme": "Unable to load {0}", "error.cannotparseicontheme": "Problems parsing file icons file: {0}", - "colorTheme": "Specifies the color theme used in the workbench.", - "colorThemeError": "Theme is unknown or not installed.", - "iconTheme": "Specifies the icon theme used in the workbench.", + "colorTheme": "指定工作å°ä¸­ä½¿ç”¨çš„颜色主题。", + "colorThemeError": "主题未知或未安装。", + "iconTheme": "指定在工作å°ä¸­ä½¿ç”¨çš„图标主题。", "noIconThemeDesc": "No file icons", - "iconThemeError": "File icon theme is unknown or not installed.", + "iconThemeError": "文件图标主题未知或未安装。", "workbenchColors": "覆盖当å‰æ‰€é€‰é¢œè‰²ä¸»é¢˜çš„颜色。", "workbenchColors.deprecated": "该设置ä¸å†æ˜¯å®žéªŒæ€§è®¾ç½®ï¼Œå¹¶å·²é‡å‘½å为“workbench.colorCustomizationsâ€", "workbenchColors.deprecatedDescription": "改用“workbench.colorCustomizationsâ€" diff --git a/i18n/cht/extensions/markdown/out/extension.i18n.json b/i18n/cht/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/cht/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/cht/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/cht/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/cht/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/cht/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/cht/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/cht/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/cht/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/cht/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/cht/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/cht/extensions/merge-conflict/package.i18n.json b/i18n/cht/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/cht/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/cht/extensions/npm/package.i18n.json b/i18n/cht/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/cht/extensions/npm/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/cht/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/cht/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index da6b8c6d2c0..c01f13f3bcb 100644 --- a/i18n/cht/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/cht/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,8 +6,6 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "因為影åƒå¤ªå¤§ï¼Œæ‰€ä»¥ç„¡æ³•åœ¨ç·¨è¼¯å™¨ä¸­é¡¯ç¤ºã€‚", - "resourceOpenExternalButton": "é–‹å•Ÿå½±åƒ", - "resourceOpenExternalText": " è¦ä½¿ç”¨å¤–部程å¼å—Ž?", "nativeBinaryError": "檔案為二進ä½æª”ã€éžå¸¸å¤§æˆ–使用ä¸æ”¯æ´çš„文字編碼,因此將ä¸æœƒé¡¯ç¤ºæ–¼ç·¨è¼¯å™¨ä¸­ã€‚", "sizeB": "{0}B", "sizeKB": "{0}KB", diff --git a/i18n/cht/src/vs/code/electron-main/menus.i18n.json b/i18n/cht/src/vs/code/electron-main/menus.i18n.json index a1fa3f356dd..5961aa8e789 100644 --- a/i18n/cht/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/cht/src/vs/code/electron-main/menus.i18n.json @@ -14,6 +14,7 @@ "mHelp": "說明 (&&H)", "miNewWindow": "開新視窗(&&W)", "mAbout": "關於 {0}", + "mServices": "æœå‹™", "mHide": "éš±è— {0}", "mHideOthers": "éš±è—其他", "mShowAll": "全部顯示", diff --git a/i18n/cht/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/cht/src/vs/editor/common/config/commonEditorConfig.i18n.json index ec8f05fe340..f06682edb16 100644 --- a/i18n/cht/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/cht/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -40,7 +40,6 @@ "formatOnType": "控制編輯器是å¦æ‡‰åœ¨è¼¸å…¥ä¸€è¡Œå¾Œè‡ªå‹•æ ¼å¼åŒ–", "formatOnPaste": "控制編輯器是å¦æ‡‰è‡ªå‹•è¨­å®šè²¼ä¸Šçš„內容格å¼ã€‚æ ¼å¼å™¨å¿…é ˆå¯ä¾›ä½¿ç”¨ï¼Œè€Œä¸”æ ¼å¼å™¨æ‡‰è©²èƒ½å¤ è¨­å®šæ–‡ä»¶ä¸­ä¸€å€‹ç¯„åœçš„æ ¼å¼ã€‚", "suggestOnTriggerCharacters": "控制輸入觸發字元時,是å¦æ‡‰è‡ªå‹•é¡¯ç¤ºå»ºè­°", - "acceptSuggestionOnEnter": "控制除了 'Tab' 外,是å¦ä¹Ÿè—‰ç”±æŒ‰ä¸‹ 'Enter' 接å—建議。如此å¯é¿å…æ··æ·†è¦æ’入新行或接å—建議。", "acceptSuggestionOnCommitCharacter": "控制èªå¯å­—元是å¦æ‡‰æŽ¥å—建議。例如在 JavaScript 中,分號 (';') å¯ä»¥æ˜¯æŽ¥å—建議並éµå…¥è©²å­—元的èªå¯å­—元。", "snippetSuggestions": "控制程å¼ç¢¼ç‰‡æ®µæ˜¯å¦éš¨å…¶ä»–建議顯示,以åŠå…¶æŽ’åºæ–¹å¼ã€‚", "emptySelectionClipboard": "控制複製時ä¸é¸å–任何項目是å¦æœƒè¤‡è£½ç›®å‰ç¨‹å¼è¡Œã€‚", diff --git a/i18n/cht/src/vs/editor/common/view/editorColorRegistry.i18n.json b/i18n/cht/src/vs/editor/common/view/editorColorRegistry.i18n.json index 7b011979df9..b08c173b100 100644 --- a/i18n/cht/src/vs/editor/common/view/editorColorRegistry.i18n.json +++ b/i18n/cht/src/vs/editor/common/view/editorColorRegistry.i18n.json @@ -7,6 +7,9 @@ "lineHighlight": "ç›®å‰æ¸¸æ¨™ä½ç½®è¡Œçš„å白顯示背景色彩。", "lineHighlightBorderBox": "ç›®å‰æ¸¸æ¨™ä½ç½®è¡Œä¹‹å‘¨åœæ¡†ç·šçš„背景色彩。", "rangeHighlight": "å白顯示範åœçš„背景色彩,例如 Quick Open 與尋找功能。", + "caret": "編輯器游標的色彩。", + "editorWhitespaces": "編輯器中空白字元的色彩。", + "editorIndentGuides": "編輯器縮排輔助線的色彩。", "editorLineNumbers": "編輯器行號的色彩。", "editorRuler": "編輯器尺è¦çš„色彩", "editorCodeLensForeground": "編輯器程å¼ç¢¼æ¿¾é¡çš„å‰æ™¯è‰²å½©", diff --git a/i18n/cht/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/cht/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..26ea0a1761c --- /dev/null +++ b/i18n/cht/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "找ä¸åˆ° '{0}' 的定義", + "generic.noResults": "找ä¸åˆ°ä»»ä½•å®šç¾©", + "meta.title": " - {0} 個定義", + "actions.goToDecl.label": "移至定義", + "actions.goToDeclToSide.label": "在一å´é–‹å•Ÿå®šç¾©", + "actions.previewDecl.label": "é è¦½å®šç¾©", + "goToImplementation.noResultWord": "找ä¸åˆ° '{0}' 的任何實作", + "goToImplementation.generic.noResults": "找ä¸åˆ°ä»»ä½•å¯¦ä½œ", + "meta.implementations.title": " – {0} 個實作", + "actions.goToImplementation.label": "å‰å¾€å¯¦ä½œ", + "actions.peekImplementation.label": "é è¦½å¯¦ä½œ", + "goToTypeDefinition.noResultWord": "找ä¸åˆ° '{0}' 的任何類型定義", + "goToTypeDefinition.generic.noResults": "找ä¸åˆ°ä»»ä½•é¡žåž‹å®šç¾©", + "meta.typeDefinitions.title": " – {0} 個定義", + "actions.goToTypeDefinition.label": "移至類型定義", + "actions.peekTypeDefinition.label": "é è¦½é¡žåž‹å®šç¾©" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/cht/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..24cf4f7503f --- /dev/null +++ b/i18n/cht/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "按一下以顯示 {0} 項定義。" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/api/node/extHostTreeViews.i18n.json b/i18n/cht/src/vs/workbench/api/node/extHostTreeViews.i18n.json index 8b6ad71cd4e..028bfb1a1d0 100644 --- a/i18n/cht/src/vs/workbench/api/node/extHostTreeViews.i18n.json +++ b/i18n/cht/src/vs/workbench/api/node/extHostTreeViews.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "treeView.duplicateElement": "元件{0}已被註冊" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/common/theme.i18n.json b/i18n/cht/src/vs/workbench/common/theme.i18n.json index 2d8bce1a636..72a8d8abb7e 100644 --- a/i18n/cht/src/vs/workbench/common/theme.i18n.json +++ b/i18n/cht/src/vs/workbench/common/theme.i18n.json @@ -29,6 +29,7 @@ "activityBarBadgeBackground": "活動通知徽章的背景色彩。此活動列會顯示在最左å´æˆ–最å³å´ï¼Œè®“您å¯ä»¥åˆ‡æ›æè¦æ¬„ä½çš„ä¸åŒæª¢è¦–。", "activityBarBadgeForeground": "活動通知徽章的å‰èƒŒæ™¯è‰²å½©ã€‚此活動列會顯示在最左å´æˆ–最å³å´ï¼Œè®“您å¯ä»¥åˆ‡æ›æè¦æ¬„ä½çš„ä¸åŒæª¢è¦–。", "sideBarBackground": "æè¦æ¬„ä½çš„背景色彩。æè¦æ¬„ä½æ˜¯æª¢è¦– (例如 Explorer 與æœå°‹) 的容器。", + "sideBarForeground": "å´æ¬„çš„å‰æ™¯é¡è‰².å´æ¬„包å«Explorer與æœå°‹.", "sideBarTitleForeground": "æè¦æ¬„ä½æ¨™é¡Œçš„å‰æ™¯è‰²å½©ã€‚æè¦æ¬„ä½æ˜¯æª¢è¦– (例如 Explorer 與æœå°‹) 的容器。", "sideBarSectionHeaderBackground": "æè¦æ¬„ä½å€æ®µæ¨™é ­çš„背景色彩。æè¦æ¬„ä½æ˜¯æª¢è¦– (例如 Explorer 與æœå°‹) 的容器。", "titleBarActiveForeground": "作用中視窗之標題列的å‰æ™¯ã€‚請注æ„,目å‰åªæœ‰ macOS 支æ´æ­¤è‰²å½©ã€‚", diff --git a/i18n/cht/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/cht/src/vs/workbench/electron-browser/main.contribution.i18n.json index c1874024aee..bced8b136e5 100644 --- a/i18n/cht/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/cht/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -7,6 +7,7 @@ "view": "檢視", "help": "說明", "file": "檔案", + "developer": "開發人員", "showEditorTabs": "控制已開啟的編輯器是å¦æ‡‰é¡¯ç¤ºåœ¨ç´¢å¼•æ¨™ç±¤ä¸­ã€‚", "editorTabCloseButton": "控制編輯器的索引標籤關閉按鈕ä½ç½®ï¼Œæˆ–在設為 'off' 時將其åœç”¨ã€‚", "showIcons": "控制開啟的編輯器是å¦æ­é…圖示顯示。這需è¦åŒæ™‚啟用圖示佈景主題。", diff --git a/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 8b6ad71cd4e..49a87dcf222 100644 --- a/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "disableOtherKeymapsConfirmation": "è¦åœç”¨å…¶ä»–按éµå°æ‡‰ï¼Œä»¥é¿å…按éµç¹«çµé—œä¿‚發生è¡çªå—Ž?", + "yes": "是", + "no": "å¦" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/cht/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 07e8bfd5963..5b044579208 100644 --- a/i18n/cht/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,7 +16,6 @@ "associations": "將檔案關è¯è¨­å®šç‚ºèªžè¨€ (例如 \"*.extension\": \"html\")。這些語言優先於已安è£èªžè¨€çš„é è¨­é—œè¯ã€‚", "encoding": "讀å–與寫入檔案時è¦ä½¿ç”¨çš„é è¨­å­—元集編碼。", "autoGuessEncoding": "如有啟用,將會在開啟檔案時,嘗試猜測字元集編碼", - "eol": "é è¨­è¡Œå°¾å­—元。", "trimTrailingWhitespace": "若啟用,將在儲存檔案時修剪尾端空白。", "insertFinalNewline": "啟用時,請在儲存檔案時在其çµå°¾æ’入最後一個新行。", "files.autoSave.off": "已變更的檔案一律ä¸æœƒè‡ªå‹•å„²å­˜ã€‚", diff --git a/i18n/cht/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/cht/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index 1c615781faa..f36b3a04dba 100644 --- a/i18n/cht/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -5,5 +5,9 @@ // Do not edit this file. It is machine generated. { "slow": "åµæ¸¬åˆ°å•Ÿå‹•é€Ÿåº¦æ…¢", - "slow.detail": "抱歉! å…ˆå‰çš„啟動速度éŽæ…¢ã€‚è«‹é‡æ–°å•Ÿå‹• '{0}' 並啟用剖æžåŠŸèƒ½ï¼ŒåŒæ™‚將設定檔æ供給我們,我們將努力æå‡å•Ÿå‹•çš„å“質。" + "slow.detail": "抱歉! å…ˆå‰çš„啟動速度éŽæ…¢ã€‚è«‹é‡æ–°å•Ÿå‹• '{0}' 並啟用剖æžåŠŸèƒ½ï¼ŒåŒæ™‚將設定檔æ供給我們,我們將努力æå‡å•Ÿå‹•çš„å“質。", + "prof.message": "å·²æˆåŠŸå»ºç«‹è¨­å®šæª”。", + "prof.detail": "請建立å•é¡Œï¼Œä¸¦æ‰‹å‹•é™„加下列檔案:\n{0}", + "prof.restartAndFileIssue": "建立å•é¡Œä¸¦é‡æ–°å•Ÿå‹•", + "prof.restart": "é‡æ–°å•Ÿå‹•" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json b/i18n/cht/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json index c0bccd6864c..cafed393010 100644 --- a/i18n/cht/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "toggleGitViewlet": "顯示 Git", + "installAdditionalSCMProviders": "安è£é¡å¤–SCMæ供者...", "source control": "原始檔控制", "toggleSCMViewlet": "顯示 SCM", "view": "檢視" diff --git a/i18n/cht/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json b/i18n/cht/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json index d1872f571b1..5450727934a 100644 --- a/i18n/cht/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "installAdditionalSCMProviders": "安è£é¡å¤–SCMæ供者...", "switch provider": "åˆ‡æ› SCM æ供者..." } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/cht/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index e35a0884650..c9f6c178105 100644 --- a/i18n/cht/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,5 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0},工作" + "entryAriaLabel": "{0},工作", + "workspace": "從工作å€", + "extension": "從擴充功能" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json b/i18n/cht/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json index 877f81d59fd..ae636e70679 100644 --- a/i18n/cht/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json @@ -6,6 +6,7 @@ { "selectTheme.label": "色彩佈景主題", "installColorThemes": "安è£å…¶ä»–的色彩佈景主題...", + "themes.selectTheme": "é¸å–色彩主題(上/下éµé è¦½)", "selectIconTheme.label": "檔案圖示佈景主題", "installIconThemes": "安è£å…¶ä»–的檔案圖示主題...", "noIconThemeLabel": "ç„¡", diff --git a/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json index 00a45ea1dc0..9a00f615c32 100644 --- a/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -11,6 +11,7 @@ "welcomePage.openFolder": "開啟資料夾...", "welcomePage.cloneGitRepository": "複製 Git 存放庫...", "welcomePage.recent": "最近使用", + "welcomePage.moreRecent": "更多...", "welcomePage.noRecentFolders": "沒有最近使用的資料夾", "welcomePage.help": "說明", "welcomePage.introductoryVideos": "簡介影片", @@ -19,10 +20,12 @@ "welcomePage.stackOverflow": "Stack Overflow", "welcomePage.showOnStartup": "啟動時顯示歡迎é é¢", "welcomePage.customize": "自訂", + "welcomePage.moreExtensions": "更多", "welcomePage.installKeymapDescription": "安è£éµç›¤å¿«é€Ÿéµ", "welcomePage.others": "其他", "welcomePage.colorTheme": "彩色佈景主題", "welcomePage.colorThemeDescription": "將編輯器åŠæ‚¨çš„程å¼ç¢¼è¨­å®šæˆæ‚¨å–œæ„›çš„外觀", + "welcomePage.learn": "深入了解", "welcomePage.showCommands": "尋找åŠåŸ·è¡Œæ‰€æœ‰å‘½ä»¤", "welcomePage.showCommandsDescription": "從控制å°å¿«é€Ÿå­˜å–åŠæœå°‹å‘½ä»¤ ({0})", "welcomePage.interfaceOverview": "介é¢æ¦‚觀", diff --git a/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 02eb36873b6..dfce04ba61a 100644 --- a/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -5,11 +5,22 @@ // Do not edit this file. It is machine generated. { "welcomePage": "歡迎使用", + "welcomePage.javaScript": "JavaScript", + "welcomePage.typeScript": "TypeScript", + "welcomePage.python": "Python", + "welcomePage.php": "PHP", + "welcomePage.docker": "Docker", + "welcomePage.vim": "活力", + "welcomePage.sublime": "壯麗", + "welcomePage.atom": "Atom", "welcomePage.keymapAlreadyInstalled": "å·²å®‰è£ {0} éµç›¤å¿«é€Ÿéµã€‚", "welcomePage.willReloadAfterInstallingKeymap": "{0} éµç›¤å¿«é€Ÿéµå®‰è£å®Œæˆå¾Œï¼Œå°‡æœƒé‡æ–°è¼‰å…¥æ­¤è¦–窗。", "welcomePage.installingKeymap": "æ­£åœ¨å®‰è£ {0} éµç›¤å¿«é€Ÿéµ...", "welcomePage.keymapNotFound": "找ä¸åˆ°è­˜åˆ¥ç¢¼ç‚º {1} çš„ {0} éµç›¤å¿«é€Ÿéµã€‚", "welcome.title": "歡迎使用", + "welcomePage.extensionListSeparator": ",", + "welcomePage.installedExtension": "{0}(已安è£)", "ok": "確定", - "cancel": "å–消" + "cancel": "å–消", + "welcomePage.quickLinkBackground": "起始é é¢é€£çµçš„背景色彩." } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json b/i18n/cht/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json index 62ddb9869c6..920973ad063 100644 --- a/i18n/cht/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json @@ -5,5 +5,6 @@ // Do not edit this file. It is machine generated. { "walkThrough.unboundCommand": "未繫çµ", - "walkThrough.gitNotFound": "æ‚¨çš„ç³»çµ±ä¸Šä¼¼ä¹Žæœªå®‰è£ Git。" + "walkThrough.gitNotFound": "æ‚¨çš„ç³»çµ±ä¸Šä¼¼ä¹Žæœªå®‰è£ Git。", + "walkThrough.embeddedEditorBackground": "編輯器互動å€å¡Šçš„背景色彩." } \ No newline at end of file diff --git a/i18n/deu/extensions/git/out/main.i18n.json b/i18n/deu/extensions/git/out/main.i18n.json index 6cf07d1824f..58ab0b365d0 100644 --- a/i18n/deu/extensions/git/out/main.i18n.json +++ b/i18n/deu/extensions/git/out/main.i18n.json @@ -7,5 +7,5 @@ "using git": "Verwenden von Git {0} von {1}", "updateGit": "Git aktualisieren", "neverShowAgain": "Nicht mehr anzeigen", - "git20": "Sie haben anscheinend Git {0} installiert. Der Code funktioniert am besten mit Git 2 oder älter" + "git20": "Sie haben anscheinend Git {0} installiert. Code funktioniert am besten mit Git 2 oder neuer" } \ No newline at end of file diff --git a/i18n/deu/extensions/markdown/out/extension.i18n.json b/i18n/deu/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/deu/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/deu/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/deu/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/deu/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/deu/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/deu/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/deu/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/deu/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/deu/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/deu/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/deu/extensions/merge-conflict/package.i18n.json b/i18n/deu/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/deu/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/deu/extensions/npm/package.i18n.json b/i18n/deu/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/deu/extensions/npm/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/deu/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/deu/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index a2b0a61e0fa..24c2e906e90 100644 --- a/i18n/deu/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/deu/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,8 +6,6 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "Das Bild ist zu groß für den Editor. ", - "resourceOpenExternalButton": "Bild öffnen", - "resourceOpenExternalText": " mit externem Programm?", "nativeBinaryError": "Die Datei wird nicht im Editor angezeigt, weil sie binär oder sehr groß ist oder eine nicht unterstützte Textcodierung verwendet.", "sizeB": "{0} B", "sizeKB": "{0} KB", diff --git a/i18n/deu/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/deu/src/vs/editor/common/config/commonEditorConfig.i18n.json index 2fe70e62eed..a01ec274ece 100644 --- a/i18n/deu/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/deu/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -40,7 +40,6 @@ "formatOnType": "Steuert, ob der Editor Zeilen automatisch nach der Eingabe formatiert.", "formatOnPaste": "Steuert, ob der Editor den eingefügten Inhalt automatisch formatiert.", "suggestOnTriggerCharacters": "Steuert, ob Vorschläge automatisch bei der Eingabe von Triggerzeichen angezeigt werden.", - "acceptSuggestionOnEnter": "Steuert, ob Vorschläge über die Eingabetaste (zusätzlich zur TAB-Taste) angenommen werden sollen. Vermeidet Mehrdeutigkeit zwischen dem Einfügen neuer Zeilen oder dem Annehmen von Vorschlägen.", "acceptSuggestionOnCommitCharacter": "Steuert, ob Vorschläge über Commitzeichen angenommen werden sollen. In JavaScript kann ein Semikolon (\";\") beispielsweise ein Commitzeichen sein, das einen Vorschlag annimmt und dieses Zeichen eingibt.", "snippetSuggestions": "Steuert, ob Codeausschnitte mit anderen Vorschlägen angezeigt und wie diese sortiert werden.", "emptySelectionClipboard": "Steuert, ob ein Kopiervorgang ohne Auswahl die aktuelle Zeile kopiert.", diff --git a/i18n/deu/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/deu/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..ffee2c2fa36 --- /dev/null +++ b/i18n/deu/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "Keine Definition gefunden für \"{0}\".", + "generic.noResults": "Keine Definition gefunden", + "meta.title": " – {0} Definitionen", + "actions.goToDecl.label": "Gehe zu Definition", + "actions.goToDeclToSide.label": "Definition an der Seite öffnen", + "actions.previewDecl.label": "Peek-Definition", + "goToImplementation.noResultWord": "Keine Implementierung gefunden für \"{0}\"", + "goToImplementation.generic.noResults": "Keine Implementierung gefunden", + "meta.implementations.title": "{0} Implementierungen", + "actions.goToImplementation.label": "Zur Implementierung wechseln", + "actions.peekImplementation.label": "Vorschau der Implementierung anzeigen", + "goToTypeDefinition.noResultWord": "Keine Typendefinition gefunden für \"{0}\"", + "goToTypeDefinition.generic.noResults": "Keine Typendefinition gefunden", + "meta.typeDefinitions.title": "{0} Typdefinitionen", + "actions.goToTypeDefinition.label": "Zur Typdefinition wechseln", + "actions.peekTypeDefinition.label": "Vorschau der Typdefinition anzeigen" +} \ No newline at end of file diff --git a/i18n/deu/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/deu/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..2d5f00609a8 --- /dev/null +++ b/i18n/deu/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "Klicken Sie, um {0} Definitionen anzuzeigen." +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/deu/src/vs/workbench/electron-browser/main.contribution.i18n.json index e519ed643e2..15f166829b2 100644 --- a/i18n/deu/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/deu/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -7,6 +7,7 @@ "view": "Anzeigen", "help": "Hilfe", "file": "Datei", + "developer": "Entwickler", "showEditorTabs": "Steuert, ob geöffnete Editoren auf Registerkarten angezeigt werden sollen.", "editorTabCloseButton": "Steuert die Position der Schließen-Schaltflächen der Editor-Registerkarten oder deaktiviert sie bei der Einstellung \"off\".", "showIcons": "Steuert, ob geöffnete Editoren mit einem Symbol angezeigt werden sollen. Hierzu muss auch ein Symboldesign aktiviert werden.", diff --git a/i18n/deu/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/deu/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 8b6ad71cd4e..5c79e379437 100644 --- a/i18n/deu/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "disableOtherKeymapsConfirmation": "Andere Tastenzuordnungen deaktivieren, um Konflikte zwischen Tastenzuordnungen zu vermeiden?", + "yes": "Ja", + "no": "Nein" +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/deu/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 8880b15033b..8153f54254b 100644 --- a/i18n/deu/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,7 +16,6 @@ "associations": "Konfigurieren Sie Dateizuordnungen zu Sprachen (beispielsweise \"*.extension\": \"html\"). Diese besitzen Vorrang vor den Standardzuordnungen der installierten Sprachen.", "encoding": "Die Standardzeichensatz-Codierung, die beim Lesen und Schreiben von Dateien verwendet werden soll.", "autoGuessEncoding": "Ist diese Option aktiviert, wird beim Öffnen von Dateien versucht, die Zeichensatzcodierung automatisch zu ermitteln.", - "eol": "Das Zeilenende-Standardzeichen.", "trimTrailingWhitespace": "Bei Aktivierung werden nachgestellte Leerzeichen beim Speichern einer Datei gekürzt.", "insertFinalNewline": "Bei Aktivierung wird beim Speichern einer Datei eine abschließende neue Zeile am Dateiende eingefügt.", "files.autoSave.off": "Eine geänderte Datei wird nie automatisch gespeichert.", diff --git a/i18n/deu/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/deu/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index 96d83227f67..687359bd486 100644 --- a/i18n/deu/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -5,5 +5,9 @@ // Do not edit this file. It is machine generated. { "slow": "Langsamer Start erkannt", - "slow.detail": "Es tut uns leid, dass Ihr Start so langsam war. Starten Sie \"{0}\" mit aktivierter Profilerstellung neu, geben Sie die Profile für uns frei, und wir tun unser Bestes, damit der Start bald wieder perfekt funktioniert." + "slow.detail": "Es tut uns leid, dass Ihr Start so langsam war. Starten Sie \"{0}\" mit aktivierter Profilerstellung neu, geben Sie die Profile für uns frei, und wir tun unser Bestes, damit der Start bald wieder perfekt funktioniert.", + "prof.message": "Profile wurden erfolgreich erstellt.", + "prof.detail": "Erstellen Sie ein Problem, und fügen Sie die folgenden Dateien manuell an:\n{0}", + "prof.restartAndFileIssue": "Problem erstellen und neu starten", + "prof.restart": "Neu starten" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 1bc33347222..5693a1f5b13 100644 --- a/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -5,6 +5,11 @@ // Do not edit this file. It is machine generated. { "welcomePage": "Willkommen", + "welcomePage.typeScript": "TypeScript", + "welcomePage.php": "PHP", + "welcomePage.vim": "Vim", + "welcomePage.sublime": "Sublime", + "welcomePage.atom": "Atom", "welcomePage.keymapAlreadyInstalled": "Die {0} Tastenkombinationen sind bereits installiert.", "welcomePage.willReloadAfterInstallingKeymap": "Das Fenster wird nach der Installation der {0}-Tastaturbefehle neu geladen.", "welcomePage.installingKeymap": "Die {0}-Tastenkombinationen werden installiert...", diff --git a/i18n/esn/extensions/jake/out/main.i18n.json b/i18n/esn/extensions/jake/out/main.i18n.json index 8b6ad71cd4e..1b387f27070 100644 --- a/i18n/esn/extensions/jake/out/main.i18n.json +++ b/i18n/esn/extensions/jake/out/main.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "execFailed": "La detección automática de Jake falló con el error: {0}" +} \ No newline at end of file diff --git a/i18n/esn/extensions/jake/package.i18n.json b/i18n/esn/extensions/jake/package.i18n.json index 8b6ad71cd4e..c22d4c52c92 100644 --- a/i18n/esn/extensions/jake/package.i18n.json +++ b/i18n/esn/extensions/jake/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.jake.autoDetect": "Controla si la detección automática de tareas Jake estan activada/desactivada. El valor predeterminado es \"activada\"." +} \ No newline at end of file diff --git a/i18n/esn/extensions/markdown/out/extension.i18n.json b/i18n/esn/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/esn/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/esn/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/esn/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/esn/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/esn/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/esn/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/esn/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/esn/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/esn/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/esn/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/esn/extensions/merge-conflict/package.i18n.json b/i18n/esn/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/esn/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/esn/extensions/npm/package.i18n.json b/i18n/esn/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/esn/extensions/npm/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/esn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/esn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index f7060053115..8029ab0b3bd 100644 --- a/i18n/esn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/esn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,8 +6,6 @@ { "imgMeta": "{0} x {1} {2}", "largeImageError": "La imagen es muy grande para mostrar en el editor", - "resourceOpenExternalButton": "Abrir imagen", - "resourceOpenExternalText": "usar programa externo?", "nativeBinaryError": "El archivo no se mostrará en el editor porque es binario, muy grande o usa una codificación de texto no compatible.", "sizeB": "{0} B", "sizeKB": "{0} KB", diff --git a/i18n/esn/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/esn/src/vs/editor/common/config/commonEditorConfig.i18n.json index deeb605c6a6..8fe058e55ce 100644 --- a/i18n/esn/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/esn/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -9,6 +9,7 @@ "fontWeight": "Controla el grosor de la fuente.", "fontSize": "Controla el tamaño de fuente en píxeles.", "lineHeight": "Controla la altura de línea. Utilice 0 para calcular el valor de lineHeight a partir de fontSize.", + "letterSpacing": "Controla el espacio entre letras en pixels.", "lineNumbers": "Controla la presentación de los números de línea. Los valores posibles son \"on\", \"off\" y \"relative\". \"relative\" muestra el número de líneas desde la posición actual del cursor.", "rulers": "Columnas en las que mostrar reglas verticales", "wordSeparators": "Caracteres que se usarán como separadores de palabras al realizar operaciones o navegaciones relacionadas con palabras.", @@ -40,7 +41,6 @@ "formatOnType": "Controla si el editor debe dar formato automáticamente a la línea después de escribirla", "formatOnPaste": "Controla si el editor debe formatear automáticamente el contenido pegado. Debe haber disponible un formateador capaz de aplicar formato a un intervalo dentro de un documento.", "suggestOnTriggerCharacters": "Controla si las sugerencias deben aparecer de forma automática al escribir caracteres desencadenadores", - "acceptSuggestionOnEnter": "Controla si las sugerencias deben aceptarse en \"Entrar\" (además de \"TAB\"). Ayuda a evitar la ambigüedad entre insertar nuevas líneas o aceptar sugerencias.", "acceptSuggestionOnCommitCharacter": "Controla si se deben aceptar sugerencias en los caracteres de confirmación. Por ejemplo, en Javascript, el punto y coma (\";\") puede ser un carácter de confirmación que acepta una sugerencia y escribe ese carácter.", "snippetSuggestions": "Controla si se muestran los fragmentos de código con otras sugerencias y cómo se ordenan.", "emptySelectionClipboard": "Controla si al copiar sin selección se copia la línea actual.", @@ -62,6 +62,7 @@ "renderLineHighlight": "Controla cómo el editor debe presentar el resaltado de línea. Las posibilidades son \"ninguno\", \"margen\", \"línea\" y \"todo\".", "codeLens": "Controla si el editor muestra lentes de código", "folding": "Controla si el editor tiene habilitado el plegado de código.", + "showFoldingControls": "Controla cuándo los controles de plegado del margen son ocultados automáticamente.", "matchBrackets": "Resaltar corchetes coincidentes cuando se seleccione uno de ellos.", "glyphMargin": "Controla si el editor debe representar el margen de glifo vertical. El margen de glifo se usa, principalmente, para depuración.", "useTabStops": "La inserción y eliminación del espacio en blanco sigue a las tabulaciones.", diff --git a/i18n/esn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/esn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..d9243b76135 --- /dev/null +++ b/i18n/esn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "No se encontró ninguna definición para \"{0}\"", + "generic.noResults": "No se encontró ninguna definición", + "meta.title": " – {0} definiciones", + "actions.goToDecl.label": "Ir a definición", + "actions.goToDeclToSide.label": "Abrir definición en el lateral", + "actions.previewDecl.label": "Ver la definición", + "goToImplementation.noResultWord": "No se encontró ninguna implementación para \"{0}\"", + "goToImplementation.generic.noResults": "No se encontró ninguna implementación", + "meta.implementations.title": "{0} implementaciones", + "actions.goToImplementation.label": "Ir a implementación", + "actions.peekImplementation.label": "Inspeccionar implementación", + "goToTypeDefinition.noResultWord": "No se encontró ninguna definición de tipo para \"{0}\"", + "goToTypeDefinition.generic.noResults": "No se encontró ninguna definición de tipo", + "meta.typeDefinitions.title": " – {0} definiciones de tipo", + "actions.goToTypeDefinition.label": "Ir a la definición de tipo", + "actions.peekTypeDefinition.label": "Inspeccionar definición de tipo" +} \ No newline at end of file diff --git a/i18n/esn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/esn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..d35f93e7fae --- /dev/null +++ b/i18n/esn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "Haga clic para mostrar {0} definiciones." +} \ No newline at end of file diff --git a/i18n/esn/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json b/i18n/esn/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json index f9d2c2d5f09..bf3d8015426 100644 --- a/i18n/esn/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json +++ b/i18n/esn/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json @@ -12,6 +12,7 @@ "readMore": "Leer más...{0}", "suggestionWithDetailsAriaLabel": "{0}, sugerencia, con detalles", "suggestionAriaLabel": "{0}, sugerencia", + "readLess": "Leer menos...{0}", "suggestWidget.loading": "Cargando...", "suggestWidget.noSuggestions": "No hay sugerencias.", "suggestionAriaAccepted": "{0}, aceptada", diff --git a/i18n/esn/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json b/i18n/esn/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json index df256b0ca88..43ec87cbde1 100644 --- a/i18n/esn/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json +++ b/i18n/esn/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json @@ -15,5 +15,9 @@ "schema.brackets": "Define los corchetes que aumentan o reducen la sangría.", "schema.autoClosingPairs": "Define el par de corchetes. Cuando se escribe un corchete de apertura, se inserta automáticamente el corchete de cierre.", "schema.autoClosingPairs.notIn": "Define una lista de ámbitos donde los pares automáticos están deshabilitados.", - "schema.surroundingPairs": "Define los pares de corchetes que se pueden usar para encerrar una cadena seleccionada." + "schema.surroundingPairs": "Define los pares de corchetes que se pueden usar para encerrar una cadena seleccionada.", + "schema.wordPattern": " La definición de la palabra en el idioma.", + "schema.wordPattern.pattern": "El patrón de expresión regular utilizado para localizar palabras.", + "schema.wordPattern.flags": "Los flags de expresión regular utilizados para localizar palabras.", + "schema.wordPattern.flags.errorMessage": "Debe coincidir con el patrón `/^([gimuy]+)$/`." } \ No newline at end of file diff --git a/i18n/esn/src/vs/platform/markers/common/problemMatcher.i18n.json b/i18n/esn/src/vs/platform/markers/common/problemMatcher.i18n.json index 967ffc75983..1c9dfefb5cb 100644 --- a/i18n/esn/src/vs/platform/markers/common/problemMatcher.i18n.json +++ b/i18n/esn/src/vs/platform/markers/common/problemMatcher.i18n.json @@ -34,6 +34,7 @@ "ProblemMatcherParser.noValidIdentifier": "Error: La propiedad pattern {0} no es un nombre de variable de patrón válido.", "ProblemMatcherParser.problemPattern.watchingMatcher": "Un buscador de coincidencias de problemas debe definir tanto un patrón de inicio como un patrón de finalización para la inspección.", "ProblemMatcherParser.invalidRegexp": "Error: La cadena {0} no es una expresión regular válida.\n", + "WatchingPatternSchema.regexp": "Expresión regular para detectar el principio o el final de una tarea en segundo plano.", "WatchingPatternSchema.file": "Ãndice de grupo de coincidencias del nombre de archivo. Se puede omitir.", "PatternTypeSchema.name": "Nombre de un patrón aportado o predefinido", "PatternTypeSchema.description": "Patrón de problema o nombre de un patrón de problema que se ha aportado o predefinido. Se puede omitir si se especifica la base.", @@ -42,6 +43,12 @@ "ProblemMatcherSchema.severity": "Gravedad predeterminada para los problemas de capturas. Se usa si el patrón no define un grupo de coincidencias para \"severity\".", "ProblemMatcherSchema.applyTo": "Controla si un problema notificado en un documento de texto se aplica solamente a los documentos abiertos, cerrados o a todos los documentos.", "ProblemMatcherSchema.fileLocation": "Define cómo deben interpretarse los nombres de archivo notificados en un patrón de problema.", + "ProblemMatcherSchema.background": "Patrones para hacer seguimiento del comienzo y el final en un comprobador activo de la tarea en segundo plano.", + "ProblemMatcherSchema.background.activeOnStart": "Si se establece en True, el monitor está en modo activo cuando la tarea empieza. Esto es equivalente a emitir una línea que coincide con beginPattern", + "ProblemMatcherSchema.background.beginsPattern": "Si se encuentran coincidencias en la salida, se señala el inicio de una tarea en segundo plano.", + "ProblemMatcherSchema.background.endsPattern": "Si se encuentran coincidencias en la salida, se señala el fin de una tarea en segundo plano.", + "ProblemMatcherSchema.watching.deprecated": "Esta propiedad está en desuso. Use la propiedad en segundo plano.", + "ProblemMatcherSchema.watching": "Patrones para hacer un seguimiento del comienzo y el final de un patrón de supervisión.", "ProblemMatcherSchema.watching.activeOnStart": "Si se establece en true, el monitor está en modo activo cuando la tarea empieza. Esto es equivalente a emitir una línea que coincide con beginPattern", "ProblemMatcherSchema.watching.beginsPattern": "Si se encuentran coincidencias en la salida, se señala el inicio de una tarea de inspección.", "ProblemMatcherSchema.watching.endsPattern": "Si se encuentran coincidencias en la salida, se señala el fin de una tarea de inspección", diff --git a/i18n/esn/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/esn/src/vs/platform/theme/common/colorRegistry.i18n.json index 85f87911be1..889a845a813 100644 --- a/i18n/esn/src/vs/platform/theme/common/colorRegistry.i18n.json +++ b/i18n/esn/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -36,11 +36,13 @@ "dropdownForeground": "Primer plano de lista desplegable.", "dropdownBorder": "Borde de lista desplegable.", "listFocusBackground": "Color de fondo de la lista o el árbol del elemento con el foco cuando la lista o el árbol están activos. Una lista o un árbol tienen el foco del teclado cuando están activos, cuando están inactivos no.", + "listFocusForeground": "Color de fondo de la lista o el árbol del elemento con el foco cuando la lista o el árbol están activos. Una lista o un árbol tienen el foco del teclado cuando están activos, cuando están inactivos no.", "listActiveSelectionBackground": "Color de fondo de la lista o el árbol del elemento seleccionado cuando la lista o el árbol están activos. Una lista o un árbol tienen el foco del teclado cuando están activos, cuando están inactivos no.", "listActiveSelectionForeground": "Color de primer plano de la lista o el árbol del elemento con el foco cuando la lista o el árbol están activos. Una lista o un árbol tienen el foco del teclado cuando están activos, cuando están inactivos no.", "listInactiveSelectionBackground": "Color de fondo de la lista o el árbol del elemento seleccionado cuando la lista o el árbol están inactivos. Una lista o un árbol tienen el foco del teclado cuando están activos, cuando están inactivos no.", "listInactiveSelectionForeground": "Color de primer plano de la lista o el árbol del elemento con el foco cuando la lista o el árbol esta inactiva. Una lista o un árbol tiene el foco del teclado cuando está activo, cuando esta inactiva no.", "listHoverBackground": "Fondo de la lista o el árbol al mantener el mouse sobre los elementos.", + "listHoverForeground": "Color de primer plano de la lista o el árbol al pasar por encima de los elementos con el ratón.", "listDropBackground": "Fondo de arrastrar y colocar la lista o el árbol al mover los elementos con el mouse.", "highlight": "Color de primer plano de la lista o el árbol de las coincidencias resaltadas al buscar dentro de la lista o el ábol.", "pickerGroupForeground": "Selector de color rápido para la agrupación de etiquetas.", @@ -58,6 +60,7 @@ "editorBackground": "Color de fondo del editor.", "editorForeground": "Color de primer plano predeterminado del editor.", "editorWidgetBackground": "Color de fondo del editor de widgets como buscar/reemplazar", + "editorWidgetBorder": "Color de borde del editor de widget.", "editorSelection": "Color de la selección del editor.", "editorInactiveSelection": "Color de la selección en un editor inactivo.", "editorSelectionHighlight": "Color de las regiones con el mismo contenido que la selección.", diff --git a/i18n/esn/src/vs/workbench/api/node/extHostTreeViews.i18n.json b/i18n/esn/src/vs/workbench/api/node/extHostTreeViews.i18n.json index 8b6ad71cd4e..1127a4ec4f8 100644 --- a/i18n/esn/src/vs/workbench/api/node/extHostTreeViews.i18n.json +++ b/i18n/esn/src/vs/workbench/api/node/extHostTreeViews.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "treeView.notRegistered": "No se ha registrado ninga vista del árbol con id '{0}'.", + "treeItem.notFound": "No se encontró ningún item del árbol con id '{0}'.", + "treeView.duplicateElement": "El elemento '{0}' ya está registrado" +} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/common/theme.i18n.json b/i18n/esn/src/vs/workbench/common/theme.i18n.json index 97f9736e665..40dfe03ebb6 100644 --- a/i18n/esn/src/vs/workbench/common/theme.i18n.json +++ b/i18n/esn/src/vs/workbench/common/theme.i18n.json @@ -32,6 +32,7 @@ "activityBarBadgeBackground": "Color de fondo de distintivo de notificación de actividad. La barra de actividad se muestra en el extremo izquierdo o derecho y permite cambiar entre vistas de la barra lateral.", "activityBarBadgeForeground": "Color de primer plano de distintivo de notificación de actividad. La barra de actividad se muestra en el extremo izquierdo o derecho y permite cambiar entre vistas de la barra lateral.", "sideBarBackground": "Color de fondo de la barra lateral, que es el contenedor de vistas como Explorador y Búsqueda.", + "sideBarForeground": "Color de primer plano de la barra lateral, que es el contenedor de vistas como Explorador y Búsqueda.", "sideBarTitleForeground": "Color de primer plano del título de la barra lateral, que es el contenedor de vistas como Explorador y Búsqueda.", "sideBarSectionHeaderBackground": "Color de fondo del encabezado de sección de la barra lateral, que es el contenedor de vistas como Explorador y Búsqueda.", "titleBarActiveForeground": "Color de primer plano de la barra de título cuando la ventana está activa. Tenga en cuenta que, actualmente, este clor solo se admite en macOS.", diff --git a/i18n/esn/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/esn/src/vs/workbench/electron-browser/main.contribution.i18n.json index cbf9d0deef3..543d5451907 100644 --- a/i18n/esn/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/esn/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -7,6 +7,7 @@ "view": "Ver", "help": "Ayuda", "file": "Archivo", + "developer": "Desarrollador", "showEditorTabs": "Controla si los editores abiertos se deben mostrar o no en pestañas.", "editorTabCloseButton": "Controla la posición de los botones de cierre de pestañas del editor o los deshabilita si se establece en \"off\".", "showIcons": "Controla si los editores abiertos deben mostrarse o no con un icono. Requiere que también se habilite un tema de icono.", diff --git a/i18n/esn/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json b/i18n/esn/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json index cb1c2139583..00a55728fff 100644 --- a/i18n/esn/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json @@ -7,6 +7,7 @@ "debugAdapterBinNotFound": "El ejecutable del adaptador de depuración \"{0}\" no existe.", "debugAdapterCannotDetermineExecutable": "No se puede determinar el ejecutable para el adaptador de depuración \"{0}\".", "debugType": "Tipo de configuración.", + "debugTypeNotRecognised": "Este tipo de depuración no se reconoce. Compruebe que tiene instalada la correspondiente extensión de depuración y que está habilitada.", "node2NotSupported": "\"node2\" ya no se admite; use \"node\" en su lugar y establezca el atributo \"protocol\" en \"inspector\".", "debugName": "Nombre de la configuración. Aparece en el menú desplegable de la configuración de inicio.", "debugRequest": "Tipo de solicitud de la configuración. Puede ser \"launch\" o \"attach\".", diff --git a/i18n/esn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/esn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 8b6ad71cd4e..2b42d7a0c5b 100644 --- a/i18n/esn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "disableOtherKeymapsConfirmation": "¿Quiere deshabilitar otras asignaciones de teclado para evitar conflictos entre los enlaces de teclado?", + "yes": "Sí", + "no": "No" +} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/esn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 9b8bcb5fdf1..ef718dc3ee1 100644 --- a/i18n/esn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,7 +16,6 @@ "associations": "Configure asociaciones de archivo para los lenguajes (por ejemplo, \"*.extension\": \"html\"). Estas asociaciones tienen prioridad sobre las asociaciones predeterminadas de los lenguajes instalados.", "encoding": "La codificación del juego de caracteres predeterminada que debe utilizarse al leer y escribir archivos.", "autoGuessEncoding": "Si está opción está habilitada, se intentará adivinar la codificación del juego de caracteres al abrir los archivos", - "eol": "Carácter predeterminado de final de línea.", "trimTrailingWhitespace": "Si se habilita, se recortará el espacio final cuando se guarde un archivo.", "insertFinalNewline": "Si se habilita, inserte una nueva línea final al final del archivo cuando lo guarde.", "files.autoSave.off": "Un archivo con modificaciones no se guarda nunca automáticamente.", diff --git a/i18n/esn/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/esn/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index 712641fcab1..81f5a667ca8 100644 --- a/i18n/esn/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -5,5 +5,11 @@ // Do not edit this file. It is machine generated. { "slow": "Inicio lento detectado", - "slow.detail": "Lamentamos que haya tenido un inicio lento. Reinicie \"{0}\" con la generación de perfiles habilitada, comparta los perfiles con nosotros y trabajaremos a fondo para que vuelva a disfrutar de un inicio increíble." + "slow.detail": "Lamentamos que haya tenido un inicio lento. Reinicie \"{0}\" con la generación de perfiles habilitada, comparta los perfiles con nosotros y trabajaremos a fondo para que vuelva a disfrutar de un inicio increíble.", + "prof.message": "Los perfiles se crearon correctamente.", + "prof.detail": "Cree un problema y asóciele manualmente los siguientes archivos: {0}", + "prof.restartAndFileIssue": "Crear problema y reiniciar", + "prof.restart": "Reiniciar", + "prof.thanks": "Gracias por ayudarnos.", + "prof.detail.restart": "Se necesita un reinicio final para continuar utilizando '{0}'. De nuevo, gracias por su aportación." } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json b/i18n/esn/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json index 2d44f58d514..a77a2211780 100644 --- a/i18n/esn/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "toggleGitViewlet": "Mostrar GIT", + "installAdditionalSCMProviders": "Instalar proveedores adicionales de SCM...", "source control": "Control de código fuente", "toggleSCMViewlet": "Mostrar SCM", "view": "Ver" diff --git a/i18n/esn/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json b/i18n/esn/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json index 58e5c2559c8..048db5a28d0 100644 --- a/i18n/esn/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "installAdditionalSCMProviders": "Instalar proveedores adicionales de SCM...", "switch provider": "Cambiar proveedor de SCM..." } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/esn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index e5995f59713..30e2262eef7 100644 --- a/i18n/esn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,5 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0}, tareas" + "entryAriaLabel": "{0}, tareas", + "workspace": "De área de trabajo", + "extension": "De extensiones" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json b/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json index 930b60298c1..58c4eca7cfe 100644 --- a/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json @@ -6,5 +6,6 @@ { "TerminalTaskSystem.unknownError": "Error desconocido durante la ejecución de una tarea. Vea el registro de resultados de la tarea para obtener más detalles.", "TerminalTaskSystem.terminalName": "Tarea - {0}", - "TerminalTaskSystem": "No se puede ejecutar un comando shell en una unidad UNC." + "TerminalTaskSystem": "No se puede ejecutar un comando shell en una unidad UNC.", + "unkownProblemMatcher": "No puede resolver el comprobador de problemas {0}. Será omitido." } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json b/i18n/esn/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json index 651c8b00513..b300e0e061a 100644 --- a/i18n/esn/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json @@ -7,5 +7,6 @@ "TaskRunnerSystem.unknownError": "Error desconocido durante la ejecución de una tarea. Vea el registro de resultados de la tarea para obtener más detalles.", "TaskRunnerSystem.watchingBuildTaskFinished": "La inspección de las tareas de compilación ha finalizado.", "TaskRunnerSystem.childProcessError": "Failed to launch external program {0} {1}.", - "TaskRunnerSystem.cancelRequested": "La tarea '{0}' se finalizó por solicitud del usuario." + "TaskRunnerSystem.cancelRequested": "La tarea '{0}' se finalizó por solicitud del usuario.", + "unkownProblemMatcher": "No puede resolver el comprobador de problemas {0}. Será omitido" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json index 9591e0b1673..2438b3e1709 100644 --- a/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -14,13 +14,18 @@ "welcomePage.moreRecent": "Más...", "welcomePage.noRecentFolders": "No hay ninguna carpeta reciente", "welcomePage.help": "Ayuda", + "welcomePage.keybindingsCheatsheet": "Hoja imprimible con ayudas de teclado", "welcomePage.introductoryVideos": "Vídeos de introducción", "welcomePage.productDocumentation": "Documentación del producto", "welcomePage.gitHubRepository": "Repositorio de GitHub", "welcomePage.stackOverflow": "Stack Overflow", "welcomePage.showOnStartup": "Mostrar página principal al inicio", "welcomePage.customize": "Personalizar", + "welcomePage.installExtensionPacks": "Herramientas y lenguajes", + "welcomePage.installExtensionPacksDescription": "Instalar soporte para {0} y {1}", + "welcomePage.moreExtensions": "más", "welcomePage.installKeymapDescription": "Instalar los métodos abreviados de teclado", + "welcomePage.installKeymapExtension": "Instalar los métodos abreviados de teclado de {0} y {1}", "welcomePage.others": "otros", "welcomePage.colorTheme": "Tema de color", "welcomePage.colorThemeDescription": "Modifique a su gusto la apariencia del editor y el código", diff --git a/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 28283fba5c3..57b34bdf736 100644 --- a/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -5,11 +5,25 @@ // Do not edit this file. It is machine generated. { "welcomePage": "Bienvenido", + "welcomePage.javaScript": "JavaScript", + "welcomePage.typeScript": "TypeScript", + "welcomePage.python": "Python", + "welcomePage.php": "PHP", + "welcomePage.docker": "Docker", + "welcomePage.vim": "Vim", + "welcomePage.sublime": "Sublime", + "welcomePage.atom": "Atom", + "welcomePage.extensionPackAlreadyInstalled": "El soporte para '{0}' ya está instalado.", + "welcomePage.willReloadAfterInstallingExtensionPack": "La ventana se volverá a cargar después de instalar el soporte para {0}.", + "welcomePage.installingExtensionPack": "Instalando soporte para {0}...", + "welcomePage.extensionPackNotFound": "No se pudo encontrar el soporte para {0} con id {1}.", "welcomePage.keymapAlreadyInstalled": "Los métodos abreviados de teclado {0} ya están instalados.", "welcomePage.willReloadAfterInstallingKeymap": "La ventana se volverá a cargar después de instalar los métodos abreviados de teclado {0}.", "welcomePage.installingKeymap": "Instalando los métodos abreviados de teclado de {0}...", "welcomePage.keymapNotFound": "No se pudieron encontrar los métodos abreviados de teclado {0} con el identificador {1}.", "welcome.title": "Bienvenido", + "welcomePage.extensionListSeparator": ", ", + "welcomePage.installedExtension": "{0} (instalado)", "ok": "Aceptar", "cancel": "Cancelar", "welcomePage.quickLinkBackground": "Color de fondo de los vínculos rápidos en la página principal.", diff --git a/i18n/fra/extensions/markdown/out/extension.i18n.json b/i18n/fra/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/fra/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/fra/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/fra/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/fra/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/fra/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/fra/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/fra/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/fra/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/fra/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/fra/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/fra/extensions/merge-conflict/package.i18n.json b/i18n/fra/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/fra/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/fra/extensions/npm/package.i18n.json b/i18n/fra/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/fra/extensions/npm/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/fra/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/fra/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index d6968482f68..b6faf1c8af7 100644 --- a/i18n/fra/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/fra/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,8 +6,6 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "L'image est trop grande pour être affichée dans l'éditeur. ", - "resourceOpenExternalButton": "Ouvrir l'image", - "resourceOpenExternalText": " en utilisant un programme externe ?", "nativeBinaryError": "Impossible d'afficher le fichier dans l'éditeur : soit il est binaire, soit il est très volumineux, soit il utilise un encodage de texte non pris en charge.", "sizeB": "{0} o", "sizeKB": "{0} Ko", diff --git a/i18n/fra/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/fra/src/vs/editor/common/config/commonEditorConfig.i18n.json index afe0864b817..16acf6481b0 100644 --- a/i18n/fra/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/fra/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -41,7 +41,6 @@ "formatOnType": "Contrôle si l'éditeur doit automatiquement mettre en forme la ligne après la saisie", "formatOnPaste": "Contrôle si l'éditeur doit automatiquement mettre en forme le contenu collé. Un formateur doit être disponible et doit pouvoir mettre en forme une plage dans un document.", "suggestOnTriggerCharacters": "Contrôle si les suggestions doivent s'afficher automatiquement durant la saisie de caractères de déclenchement", - "acceptSuggestionOnEnter": "Contrôle si les suggestions peuvent être acceptées avec Entrée (en plus de Tab). Cela permet d'éviter toute ambiguïté entre l'insertion de nouvelles lignes et l'acceptation de suggestions.", "acceptSuggestionOnCommitCharacter": "Contrôle si les suggestions doivent être acceptées avec des caractères de validation. Par exemple, en JavaScript, le point-virgule (';') peut être un caractère de validation qui permet d'accepter une suggestion et de taper ce caractère.", "snippetSuggestions": "Contrôle si les extraits de code s'affichent en même temps que d'autres suggestions, ainsi que leur mode de tri.", "emptySelectionClipboard": "Contrôle si la copie sans sélection permet de copier la ligne actuelle.", diff --git a/i18n/fra/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/fra/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..0488ff48354 --- /dev/null +++ b/i18n/fra/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "Définition introuvable pour '{0}'", + "generic.noResults": "Définition introuvable", + "meta.title": " – {0} définitions", + "actions.goToDecl.label": "Atteindre la définition", + "actions.goToDeclToSide.label": "Ouvrir la définition sur le côté", + "actions.previewDecl.label": "Apercu de définition", + "goToImplementation.noResultWord": "Implémentation introuvable pour '{0}'", + "goToImplementation.generic.noResults": "Implémentation introuvable", + "meta.implementations.title": "– Implémentations {0}", + "actions.goToImplementation.label": "Accéder à l'implémentation", + "actions.peekImplementation.label": "Aperçu de l'implémentation", + "goToTypeDefinition.noResultWord": "Définition de type introuvable pour '{0}'", + "goToTypeDefinition.generic.noResults": "Définition de type introuvable", + "meta.typeDefinitions.title": " – Définitions de type {0}", + "actions.goToTypeDefinition.label": "Atteindre la définition de type", + "actions.peekTypeDefinition.label": "Aperçu de la définition du type" +} \ No newline at end of file diff --git a/i18n/fra/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/fra/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..247bd9d24da --- /dev/null +++ b/i18n/fra/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "Cliquez pour afficher {0} définitions." +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/fra/src/vs/workbench/electron-browser/main.contribution.i18n.json index 7d14c23b2b5..d1fbda145ce 100644 --- a/i18n/fra/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/fra/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -7,6 +7,7 @@ "view": "Affichage", "help": "Aide", "file": "Fichier", + "developer": "Développeur", "showEditorTabs": "Contrôle si les éditeurs ouverts doivent s'afficher ou non sous des onglets.", "editorTabCloseButton": "Contrôle la position des boutons de fermeture des onglets de l'éditeur, ou les désactive quand le paramètre a la valeur 'off'.", "showIcons": "Contrôle si les éditeurs ouverts doivent s'afficher ou non avec une icône. Cela implique notamment l'activation d'un thème d'icône.", diff --git a/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 8b6ad71cd4e..5ddc77dfc5a 100644 --- a/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "disableOtherKeymapsConfirmation": "Désactiver les autres mappages de touches pour éviter les conflits de combinaisons de touches ?", + "yes": "Oui", + "no": "Non" +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/fra/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 8d72ad31935..6f916235625 100644 --- a/i18n/fra/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,7 +16,6 @@ "associations": "Configurez les associations entre les fichiers et les langages (par exemple, \"*.extension\": \"html\"). Celles-ci ont priorité sur les associations par défaut des langages installés.", "encoding": "Encodage du jeu de caractères par défaut à utiliser durant la lecture et l'écriture des fichiers.", "autoGuessEncoding": "Quand cette option est activée, tente de deviner l'encodage du jeu de caractères à l'ouverture des fichiers", - "eol": "Caractère de fin de ligne par défaut.", "trimTrailingWhitespace": "Si l'option est activée, l'espace blanc de fin est supprimé au moment de l'enregistrement d'un fichier.", "insertFinalNewline": "Quand l'option est activée, une nouvelle ligne finale est insérée à la fin du fichier au moment de son enregistrement.", "files.autoSave.off": "Un fichier dont l'intégrité est compromise n'est jamais enregistré automatiquement.", diff --git a/i18n/fra/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/fra/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index fb432045fcc..56c9603dba7 100644 --- a/i18n/fra/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -5,5 +5,9 @@ // Do not edit this file. It is machine generated. { "slow": "Démarrage lent détecté", - "slow.detail": "Le démarrage a été très lent. Redémarrez '{0}' en ayant activé le profilage, partagez les profils avec nous, et nous ferons en sorte que le démarrage retrouve sa rapidité d'exécution." + "slow.detail": "Le démarrage a été très lent. Redémarrez '{0}' en ayant activé le profilage, partagez les profils avec nous, et nous ferons en sorte que le démarrage retrouve sa rapidité d'exécution.", + "prof.message": "Création réussie des profils.", + "prof.detail": "Créez un problème et joignez manuellement les fichiers suivants :\n{0}", + "prof.restartAndFileIssue": "Créer le problème et redémarrer", + "prof.restart": "Redémarrer" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/fra/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 915c12960a0..66bb9f2ab66 100644 --- a/i18n/fra/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -5,6 +5,11 @@ // Do not edit this file. It is machine generated. { "welcomePage": "Bienvenue", + "welcomePage.typeScript": "TypeScript", + "welcomePage.php": "PHP", + "welcomePage.vim": "Vim", + "welcomePage.sublime": "Sublime", + "welcomePage.atom": "Atom", "welcomePage.keymapAlreadyInstalled": "Les raccourcis clavier {0} sont déjà installés.", "welcomePage.willReloadAfterInstallingKeymap": "La fenêtre se recharge après l'installation des raccourcis clavier {0}.", "welcomePage.installingKeymap": "Installation des raccourcis clavier de {0}...", diff --git a/i18n/ita/extensions/markdown/out/extension.i18n.json b/i18n/ita/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ita/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ita/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/ita/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ita/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ita/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/ita/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ita/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ita/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/ita/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ita/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ita/extensions/merge-conflict/package.i18n.json b/i18n/ita/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ita/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ita/extensions/npm/package.i18n.json b/i18n/ita/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ita/extensions/npm/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ita/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/ita/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index 0ccb13bf8a7..c64a07b4379 100644 --- a/i18n/ita/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/ita/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,8 +6,6 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "L'immagine è troppo grande per essere visualizzata nell'editor", - "resourceOpenExternalButton": "Apri immagine", - "resourceOpenExternalText": " con il programma esterno?", "nativeBinaryError": "Il file non verrà visualizzato nell'editor perché è binario, è molto grande o usa una codifica testo non supportata.", "sizeB": "{0} B", "sizeKB": "{0} KB", diff --git a/i18n/ita/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/ita/src/vs/editor/common/config/commonEditorConfig.i18n.json index 59f730fe1dc..06ec2510c3a 100644 --- a/i18n/ita/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/ita/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -41,7 +41,6 @@ "formatOnType": "Controlla se l'editor deve formattare automaticamente la riga dopo la digitazione", "formatOnPaste": "Controlla se l'editor deve formattare automaticamente il contenuto incollato. Deve essere disponibile un formattatore che deve essere in grado di formattare un intervallo in un documento.", "suggestOnTriggerCharacters": "Controlla se i suggerimenti devono essere visualizzati automaticamente durante la digitazione dei caratteri trigger", - "acceptSuggestionOnEnter": "Controlla se i suggerimenti devono essere accettati con 'INVIO' in aggiunta a 'TAB'. In questo modo è possibile evitare ambiguità tra l'inserimento di nuove righe e l'accettazione di suggerimenti.", "acceptSuggestionOnCommitCharacter": "Controlla se accettare i suggerimenti con i caratteri di commit. Ad esempio, in JavaScript il punto e virgola (';') può essere un carattere di commit che accetta un suggerimento e digita tale carattere.", "snippetSuggestions": "Controlla se i frammenti di codice sono visualizzati con altri suggerimenti e il modo in cui sono ordinati.", "emptySelectionClipboard": "Consente di controllare se, quando si copia senza aver effettuato una selezione, viene copiata la riga corrente.", @@ -63,6 +62,7 @@ "renderLineHighlight": "Consente di controllare in che modo l'editor deve eseguire il rendering dell'evidenziazione di riga corrente. Le opzioni possibili sono 'none', 'gutter', 'line' e 'all'.", "codeLens": "Controlla se nell'editor sono visualizzate le finestre di CodeLens", "folding": "Controlla se per l'editor è abilitata la riduzione del codice", + "showFoldingControls": "Controlla se i controlli di riduzione sul margine della barra di scorrimento sono automaticamente nascosti.", "matchBrackets": "Evidenzia le parentesi corrispondenti quando se ne seleziona una.", "glyphMargin": "Controlla se l'editor deve eseguire il rendering del margine verticale del glifo. Il margine del glifo viene usato principalmente per il debug.", "useTabStops": "Inserimento ed eliminazione dello spazio vuoto dopo le tabulazioni", diff --git a/i18n/ita/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/ita/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..9df481ec1b5 --- /dev/null +++ b/i18n/ita/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "Non è stata trovata alcuna definizione per '{0}'", + "generic.noResults": "Non è stata trovata alcuna definizione", + "meta.title": " - Definizioni di {0}", + "actions.goToDecl.label": "Vai alla definizione", + "actions.goToDeclToSide.label": "Apri definizione lateralmente", + "actions.previewDecl.label": "Visualizza la definizione", + "goToImplementation.noResultWord": "Non sono state trovate implementazioni per '{0}'", + "goToImplementation.generic.noResults": "Non sono state trovate implementazioni", + "meta.implementations.title": "- {0} implementazioni", + "actions.goToImplementation.label": "Vai all'implementazione", + "actions.peekImplementation.label": "Anteprima implementazione", + "goToTypeDefinition.noResultWord": "Non sono state trovate definizioni di tipi per '{0}'", + "goToTypeDefinition.generic.noResults": "Non sono state trovate definizioni di tipi", + "meta.typeDefinitions.title": " - {0} definizioni di tipo", + "actions.goToTypeDefinition.label": "Vai alla definizione di tipo", + "actions.peekTypeDefinition.label": "Anteprima definizione di tipo" +} \ No newline at end of file diff --git a/i18n/ita/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/ita/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..fa526a1f9e6 --- /dev/null +++ b/i18n/ita/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "Fare clic per visualizzare {0} definizioni." +} \ No newline at end of file diff --git a/i18n/ita/src/vs/platform/markers/common/problemMatcher.i18n.json b/i18n/ita/src/vs/platform/markers/common/problemMatcher.i18n.json index a2611139aec..87b88acd388 100644 --- a/i18n/ita/src/vs/platform/markers/common/problemMatcher.i18n.json +++ b/i18n/ita/src/vs/platform/markers/common/problemMatcher.i18n.json @@ -34,6 +34,7 @@ "ProblemMatcherParser.noValidIdentifier": "Errore: la proprietà {0} del criterio non è un nome di variabile criterio valido.", "ProblemMatcherParser.problemPattern.watchingMatcher": "Un matcher problemi deve definire un criterio di inizio e un criterio di fine per il controllo.", "ProblemMatcherParser.invalidRegexp": "Errore: la stringa {0} non è un'espressione regolare valida.\n", + "WatchingPatternSchema.regexp": "L'espressione regolare per rilevare l'inizio o la fine di un'attività in background.", "WatchingPatternSchema.file": "Indice del gruppo di corrispondenze del nome file. Può essere omesso.", "PatternTypeSchema.name": "Nome di un criterio predefinito o aggiunto come contributo", "PatternTypeSchema.description": "Criterio di problema o nome di un criterio di problema predefinito o aggiunto come contributo. Può essere omesso se si specifica base.", @@ -42,6 +43,12 @@ "ProblemMatcherSchema.severity": "Gravità predefinita per i problemi di acquisizione. Viene usato se il criterio non definisce un gruppo di corrispondenze per la gravità.", "ProblemMatcherSchema.applyTo": "Controlla se un problema segnalato in un documento di testo è valido solo per i documenti aperti o chiusi oppure per tutti i documenti.", "ProblemMatcherSchema.fileLocation": "Consente di definire come interpretare i nomi file indicati in un criterio di problema.", + "ProblemMatcherSchema.background": "Criteri per tenere traccia dell'inizio e della fine di un matcher attivo su un'attività in background.", + "ProblemMatcherSchema.background.activeOnStart": "Se impostato a true, il monitor in backbround è in modalità attiva quando l'attività inizia. Equivale a inviare una riga che corrisponde al beginPattern", + "ProblemMatcherSchema.background.beginsPattern": "Se corrisponde nell'output, viene segnalato l'avvio di un'attività in background.", + "ProblemMatcherSchema.background.endsPattern": "Se corrisponde nell'output, viene segnalata la fine di un'attività in background.", + "ProblemMatcherSchema.watching.deprecated": "La proprietà watching è deprecata. In alternativa, utilizzare background (sfondo).", + "ProblemMatcherSchema.watching": "Criteri per tenere traccia dell'inizio e della fine di un matcher watching.", "ProblemMatcherSchema.watching.activeOnStart": "Se impostato su true, indica che il watcher è in modalità attiva all'avvio dell'attività. Equivale a inviare una riga che corrisponde al criterio di avvio", "ProblemMatcherSchema.watching.beginsPattern": "Se corrisponde nell'output, viene segnalato l'avvio di un'attività di controllo.", "ProblemMatcherSchema.watching.endsPattern": "Se corrisponde nell'output, viene segnalata la fine di un'attività di controllo.", diff --git a/i18n/ita/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/ita/src/vs/workbench/electron-browser/main.contribution.i18n.json index c034a8cc727..b13e3a07bdd 100644 --- a/i18n/ita/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/ita/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -7,6 +7,7 @@ "view": "Visualizza", "help": "Guida", "file": "File", + "developer": "Sviluppatore", "showEditorTabs": "Controlla se visualizzare o meno gli editor aperti in schede.", "editorTabCloseButton": "Controlla la posizione dei pulsanti di chiusura delle schede dell'editor oppure li disabilita quando è impostata su 'off'.", "showIcons": "Controlla se visualizzare o meno un'icona per gli editor aperti. Richiede l'abilitazione anche di un tema dell'icona.", diff --git a/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 8b6ad71cd4e..6c3f2e984e8 100644 --- a/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "disableOtherKeymapsConfirmation": "Disabilitare altre mappature tastiera per evitare conflitti tra tasti di scelta rapida?", + "yes": "Sì", + "no": "No" +} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/ita/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 5f1557087a0..a3c0e1da94b 100644 --- a/i18n/ita/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,7 +16,6 @@ "associations": "Consente di configurare le associazioni tra file e linguaggi, ad esempio \"*.extension\": \"html\". Queste hanno la precedenza sulle associazioni predefinite dei linguaggi installate.", "encoding": "Codifica del set di caratteri predefinita da usare durante la lettura e la scrittura di file.", "autoGuessEncoding": "Quando questa opzione è abilitata, la codifica del set di caratteri viene ipotizzata all'apertura dei file", - "eol": "Carattere di fine riga predefinito.", "trimTrailingWhitespace": "Se è abilitato, taglierà lo spazio vuoto quando si salva un file.", "insertFinalNewline": "Se è abilitato, inserisce un carattere di nuova riga finale alla fine del file durante il salvataggio.", "files.autoSave.off": "Un file dirty non viene mai salvato automaticamente.", diff --git a/i18n/ita/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/ita/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index 18ae03ff77a..158ed123e7a 100644 --- a/i18n/ita/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -5,5 +5,9 @@ // Do not edit this file. It is machine generated. { "slow": "È stato rilevato un rallentamento all'avvio", - "slow.detail": "È stato appena rilevato un rallentamento all'avvio. Per consentire a Microsoft di analizzare e risolvere il problema, riavviare '{0}' con la profilatura abilitata e condividere i profili." + "slow.detail": "È stato appena rilevato un rallentamento all'avvio. Per consentire a Microsoft di analizzare e risolvere il problema, riavviare '{0}' con la profilatura abilitata e condividere i profili.", + "prof.message": "I profili sono stati creati.", + "prof.detail": "Creare un problema e allegare manualmente i file seguenti:\n{0}", + "prof.restartAndFileIssue": "Crea problema e riavvia", + "prof.restart": "Riavvia" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/ita/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index d2d18b208df..01f19048853 100644 --- a/i18n/ita/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -5,6 +5,11 @@ // Do not edit this file. It is machine generated. { "welcomePage": "Benvenuti", + "welcomePage.typeScript": "TypeScript", + "welcomePage.php": "PHP", + "welcomePage.vim": "Vim", + "welcomePage.sublime": "Sublime", + "welcomePage.atom": "Atom", "welcomePage.keymapAlreadyInstalled": "I tasti di scelta rapida di {0} sono già installati.", "welcomePage.willReloadAfterInstallingKeymap": "La finestra verrà ricaricata dopo l'installazione dei tasti di scelta rapida di {0}.", "welcomePage.installingKeymap": "Installazione dei tasti di scelta rapida di {0}...", diff --git a/i18n/jpn/extensions/jake/out/main.i18n.json b/i18n/jpn/extensions/jake/out/main.i18n.json index 8b6ad71cd4e..0f77342ecbc 100644 --- a/i18n/jpn/extensions/jake/out/main.i18n.json +++ b/i18n/jpn/extensions/jake/out/main.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "execFailed": "Jake ã®ã‚¨ãƒ©ãƒ¼ã«ã‚ˆã‚‹å¤±æ•—を自動検出: {0}" +} \ No newline at end of file diff --git a/i18n/jpn/extensions/jake/package.i18n.json b/i18n/jpn/extensions/jake/package.i18n.json index 8b6ad71cd4e..def0eab1b4c 100644 --- a/i18n/jpn/extensions/jake/package.i18n.json +++ b/i18n/jpn/extensions/jake/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.jake.autoDetect": "Jake タスクã®è‡ªå‹•æ¤œå‡ºã‚’オンã«ã™ã‚‹ã‹ã‚ªãƒ•ã«ã™ã‚‹ã‹ã‚’制御ã—ã¾ã™ã€‚既定ã¯ã‚ªãƒ³ã§ã™ã€‚" +} \ No newline at end of file diff --git a/i18n/jpn/extensions/markdown/out/extension.i18n.json b/i18n/jpn/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/jpn/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/jpn/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/jpn/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/jpn/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/jpn/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/jpn/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/jpn/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/jpn/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/jpn/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/jpn/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/jpn/extensions/merge-conflict/package.i18n.json b/i18n/jpn/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/jpn/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/jpn/extensions/npm/package.i18n.json b/i18n/jpn/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/jpn/extensions/npm/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/jpn/extensions/typescript/package.i18n.json b/i18n/jpn/extensions/typescript/package.i18n.json index e30965564d0..d3f776eaa11 100644 --- a/i18n/jpn/extensions/typescript/package.i18n.json +++ b/i18n/jpn/extensions/typescript/package.i18n.json @@ -33,10 +33,13 @@ "javascript.validate.enable": "JavaScript ã®æ¤œè¨¼ã‚’有効/無効ã«ã—ã¾ã™ã€‚", "typescript.goToProjectConfig.title": "プロジェクト構æˆã«ç§»å‹•", "javascript.goToProjectConfig.title": "プロジェクト構æˆã«ç§»å‹•", + "javascript.referencesCodeLens.enabled": "JavaScript ファイル内㧠CodeLens ã®å‚照を有効/無効ã«ã—ã¾ã™ã€‚", + "typescript.referencesCodeLens.enabled": "TypeScript ファイル内㧠CodeLens ã®å‚照を有効/無効ã«ã—ã¾ã™ã€‚TypeScript 2.0.6 以上ãŒå¿…è¦ã§ã™ã€‚", "typescript.implementationsCodeLens.enabled": "CodeLens ã®å®Ÿè£…を有効/無効ã«ã—ã¾ã™ã€‚TypeScript 2.2.0 以上ãŒå¿…è¦ã§ã™ã€‚", "typescript.openTsServerLog.title": "TS サーãƒãƒ¼ã®ãƒ­ã‚°ã‚’é–‹ã", "typescript.selectTypeScriptVersion.title": "TypeScript ã®ãƒãƒ¼ã‚¸ãƒ§ãƒ³ã®é¸æŠž", "jsDocCompletion.enabled": " 自動 JSDoc コメントを有効/無効ã«ã—ã¾ã™", "javascript.implicitProjectConfig.checkJs": "JavaScript ファイルã®ã‚»ãƒžãƒ³ãƒ†ã‚£ãƒƒã‚¯ ãƒã‚§ãƒƒã‚¯ã‚’有効/無効ã«ã—ã¾ã™ã€‚既存㮠jsconfi.json ã‚„ tsconfi.json ファイルã®è¨­å®šã¯ã“れより優先ã•ã‚Œã¾ã™ã€‚TypeScript 㯠2.3.1 以上ã§ã‚ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™ã€‚", - "typescript.check.npmIsInstalled": "型定義ã®è‡ªå‹•å–å¾—ã« NPM ãŒã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã¦ã„ã‚‹ã‹ã©ã†ã‹ã‚’確èªã™ã‚‹" + "typescript.check.npmIsInstalled": "型定義ã®è‡ªå‹•å–å¾—ã« NPM ãŒã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã¦ã„ã‚‹ã‹ã©ã†ã‹ã‚’確èªã™ã‚‹", + "javascript.nameSuggestions": "JavaScript ã®å€™è£œãƒªã‚¹ãƒˆå†…ã§ãƒ•ã‚¡ã‚¤ãƒ«ã‹ã‚‰ä¸€æ„ã®åå‰ã‚’å«ã‚€ã‹ã©ã†ã‹ã‚’有効/無効ã«ã—ã¾ã™ã€‚" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/jpn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index ea2e47d9813..e70844baf7b 100644 --- a/i18n/jpn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/jpn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,8 +6,6 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "イメージãŒå¤§ãã™ãŽã¦ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã«è¡¨ç¤ºã§ãã¾ã›ã‚“。", - "resourceOpenExternalButton": "イメージを開ã", - "resourceOpenExternalText": " 外部プログラムを使用ã—ã¦ã„ã¾ã™ã‹?", "nativeBinaryError": "ã“ã®ãƒ•ã‚¡ã‚¤ãƒ«ã¯ãƒã‚¤ãƒŠãƒªã‹ã€éžå¸¸ã«å¤§ãã„ã‹ã€ã¾ãŸã¯ã‚µãƒãƒ¼ãƒˆã•ã‚Œã¦ã„ãªã„テキスト エンコードを使用ã—ã¦ã„ã‚‹ãŸã‚ã€ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã«è¡¨ç¤ºã•ã‚Œã¾ã›ã‚“。", "sizeB": "{0}B", "sizeKB": "{0}KB", diff --git a/i18n/jpn/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/jpn/src/vs/editor/common/config/commonEditorConfig.i18n.json index da6b50dacf0..8ce8d297e00 100644 --- a/i18n/jpn/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/jpn/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -41,7 +41,6 @@ "formatOnType": "エディターã§å…¥åŠ›å¾Œã«è‡ªå‹•çš„ã«è¡Œã®æ›¸å¼è¨­å®šã‚’è¡Œã†ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™", "formatOnPaste": "貼り付ã‘ãŸå†…容ãŒã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã«ã‚ˆã‚Šè‡ªå‹•çš„ã«ãƒ•ã‚©ãƒ¼ãƒžãƒƒãƒˆã•ã‚Œã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚フォーマッタを使用å¯èƒ½ã«ã™ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™ã€‚ã¾ãŸã€ãƒ•ã‚©ãƒ¼ãƒžãƒƒã‚¿ãŒãƒ‰ã‚­ãƒ¥ãƒ¡ãƒ³ãƒˆå†…ã®ç¯„囲をフォーマットã§ããªã‘ã‚Œã°ãªã‚Šã¾ã›ã‚“。", "suggestOnTriggerCharacters": "トリガー文字ã®å…¥åŠ›æ™‚ã«å€™è£œãŒè‡ªå‹•çš„ã«è¡¨ç¤ºã•ã‚Œã‚‹ã‚ˆã†ã«ã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™", - "acceptSuggestionOnEnter": "'Tab' キーã«åŠ ãˆã¦ 'Enter' キーã§å€™è£œã‚’å—ã‘入れるã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚改行ã®æŒ¿å…¥ã‚„候補ã®å映ã®é–“ã§ã‚ã„ã¾ã„ã•ã‚’解消ã™ã‚‹ã®ã«å½¹ç«‹ã¡ã¾ã™ã€‚", "acceptSuggestionOnCommitCharacter": "コミット文字ã§å€™è£œã‚’å—ã‘入れるã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚ãŸã¨ãˆã°ã€JavaScript ã§ã¯ã‚»ãƒŸã‚³ãƒ­ãƒ³ (';') をコミット文字ã«ã—ã¦ã€å€™è£œã‚’å—ã‘入れã¦ãã®æ–‡å­—を入力ã™ã‚‹ã“ã¨ãŒã§ãã¾ã™ã€‚", "snippetSuggestions": "ä»–ã®ä¿®æ­£å€™è£œã¨ä¸€ç·’ã«ã‚¹ãƒ‹ãƒšãƒƒãƒˆã‚’表示ã™ã‚‹ã‹ã©ã†ã‹ã€ãŠã‚ˆã³ãã®ä¸¦ã³æ›¿ãˆã®æ–¹æ³•ã‚’制御ã—ã¾ã™ã€‚", "emptySelectionClipboard": "é¸æŠžç¯„囲を指定ã—ãªã„ã§ã‚³ãƒ”ーã™ã‚‹å ´åˆã«ç¾åœ¨ã®è¡Œã‚’コピーã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚", @@ -63,6 +62,7 @@ "renderLineHighlight": "エディターãŒç¾åœ¨ã®è¡Œã‚’ã©ã®ã‚ˆã†ã«å¼·èª¿è¡¨ç¤ºã™ã‚‹ã‹ã‚’制御ã—ã¾ã™ã€‚考ãˆã‚‰ã‚Œã‚‹å€¤ã¯ 'none'ã€'gutter'ã€'line'ã€'all' ã§ã™ã€‚", "codeLens": "エディター㧠CodeLens を表示ã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã™ã‚‹", "folding": "エディターã§ã‚³ãƒ¼ãƒ‰ã®æŠ˜ã‚ŠãŸãŸã¿ã‚’有効ã«ã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™", + "showFoldingControls": "余白上ã®æŠ˜ã‚ŠãŸãŸã¿ã‚³ãƒ³ãƒˆãƒ­ãƒ¼ãƒ«ã‚’自動的ã«éžè¡¨ç¤ºã«ã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ 。", "matchBrackets": "ã‹ã£ã“ã‚’é¸æŠžã™ã‚‹ã¨ã€å¯¾å¿œã™ã‚‹ã‹ã£ã“を強調表示ã—ã¾ã™ã€‚", "glyphMargin": "エディターã§ç¸¦ã®ã‚°ãƒªãƒ•ä½™ç™½ãŒè¡¨ç¤ºã•ã‚Œã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚ã»ã¨ã‚“ã©ã®å ´åˆã€ã‚°ãƒªãƒ•ä½™ç™½ã¯ãƒ‡ãƒãƒƒã‚°ã«ä½¿ç”¨ã•ã‚Œã¾ã™ã€‚", "useTabStops": "空白ã®æŒ¿å…¥ã‚„削除ã¯ã‚¿ãƒ–ä½ç½®ã«å¾“ã£ã¦è¡Œã‚ã‚Œã¾ã™", diff --git a/i18n/jpn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/jpn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..624f9b7af70 --- /dev/null +++ b/i18n/jpn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "'{0}' ã®å®šç¾©ã¯è¦‹ã¤ã‹ã‚Šã¾ã›ã‚“", + "generic.noResults": "定義ãŒè¦‹ã¤ã‹ã‚Šã¾ã›ã‚“", + "meta.title": " – {0} 個ã®å®šç¾©", + "actions.goToDecl.label": "定義ã¸ç§»å‹•", + "actions.goToDeclToSide.label": "定義を横ã«é–‹ã", + "actions.previewDecl.label": "定義をã“ã“ã«è¡¨ç¤º", + "goToImplementation.noResultWord": "'{0}' ã®å®Ÿè£…ãŒè¦‹ã¤ã‹ã‚Šã¾ã›ã‚“", + "goToImplementation.generic.noResults": "実装ãŒè¦‹ã¤ã‹ã‚Šã¾ã›ã‚“", + "meta.implementations.title": "– {0} 個ã®å®Ÿè£…", + "actions.goToImplementation.label": "実装ã«ç§»å‹•", + "actions.peekImplementation.label": "実装ã®ãƒ—レビュー", + "goToTypeDefinition.noResultWord": "'{0}' ã®åž‹å®šç¾©ãŒè¦‹ã¤ã‹ã‚Šã¾ã›ã‚“", + "goToTypeDefinition.generic.noResults": "型定義ãŒè¦‹ã¤ã‹ã‚Šã¾ã›ã‚“", + "meta.typeDefinitions.title": " – {0} 個ã®åž‹å®šç¾©", + "actions.goToTypeDefinition.label": "型定義ã¸ç§»å‹•", + "actions.peekTypeDefinition.label": "型定義を表示" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/jpn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..f918ba9f96d --- /dev/null +++ b/i18n/jpn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "クリックã—ã¦ã€{0} ã®å®šç¾©ã‚’表示ã—ã¾ã™ã€‚" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json b/i18n/jpn/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json index b5c107a4338..65e2583d291 100644 --- a/i18n/jpn/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json +++ b/i18n/jpn/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json @@ -12,6 +12,7 @@ "readMore": "詳細を表示...{0}", "suggestionWithDetailsAriaLabel": "{0}ã€å€™è£œã€è©³ç´°ã‚ã‚Š", "suggestionAriaLabel": "{0}ã€å€™è£œ", + "readLess": "詳細を隠ã™...{0}", "suggestWidget.loading": "読ã¿è¾¼ã‚“ã§ã„ã¾ã™...", "suggestWidget.noSuggestions": "候補ã¯ã‚ã‚Šã¾ã›ã‚“。", "suggestionAriaAccepted": "{0}ã€å—ã‘入れ済ã¿", diff --git a/i18n/jpn/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json b/i18n/jpn/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json index 991783c6602..7f3e60f73e4 100644 --- a/i18n/jpn/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json +++ b/i18n/jpn/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json @@ -16,6 +16,7 @@ "schema.autoClosingPairs": "角ã‹ã£ã“ã®ãƒšã‚¢ã‚’定義ã—ã¾ã™ã€‚左角ã‹ã£ã“ãŒå…¥åŠ›ã•ã‚Œã‚‹ã¨ã€å³è§’ã‹ã£ã“ãŒè‡ªå‹•çš„ã«æŒ¿å…¥ã•ã‚Œã¾ã™ã€‚", "schema.autoClosingPairs.notIn": "自動ペアãŒç„¡åŠ¹ãªã‚¹ã‚³ãƒ¼ãƒ—ã®ä¸€è¦§ã‚’定義ã—ã¾ã™ã€‚", "schema.surroundingPairs": "é¸æŠžæ–‡å­—列を囲むã¨ãã«ä½¿ç”¨ã§ãる角ã‹ã£ã“ã®ãƒšã‚¢ã‚’定義ã—ã¾ã™ã€‚", + "schema.wordPattern": "言語ã®ãŸã‚ã®å˜èªžã®å®šç¾©ã€‚", "schema.wordPattern.pattern": "言葉ã®ç…§åˆã«ä½¿ç”¨ã™ã‚‹æ­£è¦è¡¨ç¾ãƒ‘ターン。", "schema.wordPattern.flags": "言葉ã®ç…§åˆã«ä½¿ç”¨ã™ã‚‹æ­£è¦è¡¨ç¾ãƒ•ãƒ©ã‚°ã€‚", "schema.wordPattern.flags.errorMessage": "`/^([gimuy]+)$/` パターンã«ä¸€è‡´ã™ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™ã€‚" diff --git a/i18n/jpn/src/vs/platform/markers/common/problemMatcher.i18n.json b/i18n/jpn/src/vs/platform/markers/common/problemMatcher.i18n.json index 2bbfe1d0b1d..df4f3d19acd 100644 --- a/i18n/jpn/src/vs/platform/markers/common/problemMatcher.i18n.json +++ b/i18n/jpn/src/vs/platform/markers/common/problemMatcher.i18n.json @@ -34,6 +34,7 @@ "ProblemMatcherParser.noValidIdentifier": "エラー: パターン プロパティ {0} ã¯æœ‰åŠ¹ãªãƒ‘ターン変数åã§ã¯ã‚ã‚Šã¾ã›ã‚“。", "ProblemMatcherParser.problemPattern.watchingMatcher": "å•é¡Œãƒžãƒƒãƒãƒ£ãƒ¼ã¯ã€ã‚¦ã‚©ãƒƒãƒå¯¾è±¡ã®é–‹å§‹ãƒ‘ターンã¨çµ‚了パターンã®ä¸¡æ–¹ã‚’定義ã™ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™ã€‚", "ProblemMatcherParser.invalidRegexp": "エラー: 文字列 {0} ã¯ã€æœ‰åŠ¹ãªæ­£è¦è¡¨ç¾ã§ã¯ã‚ã‚Šã¾ã›ã‚“。\n", + "WatchingPatternSchema.regexp": "ãƒãƒƒã‚¯ã‚°ãƒ©ã‚¦ãƒ³ãƒ‰ タスクã®é–‹å§‹ã¾ãŸã¯çµ‚了を検出ã™ã‚‹æ­£è¦è¡¨ç¾ã€‚", "WatchingPatternSchema.file": "ファイルåã®ä¸€è‡´ã‚°ãƒ«ãƒ¼ãƒ— インデックス。çœç•¥ã§ãã¾ã™ã€‚", "PatternTypeSchema.name": "æä¾›ã•ã‚ŒãŸã‹äº‹å‰å®šç¾©ã•ã‚ŒãŸå•é¡Œãƒ‘ターンã®åå‰", "PatternTypeSchema.description": "A problem pattern or the name of a contributed or predefined problem pattern. Can be omitted if base is specified.", @@ -42,6 +43,12 @@ "ProblemMatcherSchema.severity": "キャプãƒãƒ£ã•ã‚ŒãŸå•é¡Œã®æ—¢å®šã®é‡å¤§åº¦ã€‚パターンãŒé‡è¦åº¦ã®ä¸€è‡´ã‚°ãƒ«ãƒ¼ãƒ—を定義ã—ã¦ã„ãªã„å ´åˆã«ä½¿ç”¨ã•ã‚Œã¾ã™ã€‚", "ProblemMatcherSchema.applyTo": "テキスト ドキュメントã§å ±å‘Šã•ã‚ŒãŸå•é¡ŒãŒã€é–‹ã„ã¦ã„るドキュメントã®ã¿ã€é–‰ã˜ã‚‰ã‚ŒãŸãƒ‰ã‚­ãƒ¥ãƒ¡ãƒ³ãƒˆã®ã¿ã€ã™ã¹ã¦ã®ãƒ‰ã‚­ãƒ¥ãƒ¡ãƒ³ãƒˆã®ã„ãšã‚Œã«é©ç”¨ã•ã‚Œã‚‹ã‹ã‚’制御ã—ã¾ã™ã€‚", "ProblemMatcherSchema.fileLocation": "å•é¡Œãƒ‘ターンã§å ±å‘Šã•ã‚ŒãŸãƒ•ã‚¡ã‚¤ãƒ«åを解釈ã™ã‚‹æ–¹æ³•ã‚’定義ã—ã¾ã™ã€‚", + "ProblemMatcherSchema.background": "ãƒãƒƒã‚¯ã‚°ãƒ©ã‚¦ãƒ³ãƒ‰ タスクã§ã‚¢ã‚¯ãƒ†ã‚£ãƒ–ãªãƒžãƒƒãƒãƒ£ãƒ¼ã®é–‹å§‹ã¨çµ‚了を追跡ã™ã‚‹ãƒ‘ターン。", + "ProblemMatcherSchema.background.activeOnStart": "true ã«è¨­å®šã™ã‚‹ã¨ã€ã‚¿ã‚¹ã‚¯ã®é–‹å§‹æ™‚ã«ãƒãƒƒã‚¯ã‚°ãƒ©ã‚¦ãƒ³ãƒ‰ モニターãŒã‚¢ã‚¯ãƒ†ã‚£ãƒ– モードã«ãªã‚Šã¾ã™ã€‚ã“れ㯠beginPattern ã¨ä¸€è‡´ã™ã‚‹è¡Œã®ç™ºè¡Œã¨åŒç­‰ã§ã™ã€‚", + "ProblemMatcherSchema.background.beginsPattern": "出力内ã§ä¸€è‡´ã™ã‚‹ã¨ã€ãƒãƒƒã‚¯ã‚°ãƒ©ã‚¦ãƒ³ãƒ‰ タスクã®é–‹å§‹ãŒé€šçŸ¥ã•ã‚Œã¾ã™ã€‚", + "ProblemMatcherSchema.background.endsPattern": "出力内ã§ä¸€è‡´ã™ã‚‹ã¨ã€ãƒãƒƒã‚¯ã‚°ãƒ©ã‚¦ãƒ³ãƒ‰ タスクã®çµ‚了ãŒé€šçŸ¥ã•ã‚Œã¾ã™ã€‚", + "ProblemMatcherSchema.watching.deprecated": "watching プロパティã¯ä½¿ç”¨ã•ã‚Œãªããªã‚Šã¾ã—ãŸã€‚代ã‚ã‚Šã« background ã‚’ã”使用ãã ã•ã„。", + "ProblemMatcherSchema.watching": "監視パターンã®é–‹å§‹ã¨çµ‚了を追跡ã™ã‚‹ãƒžãƒƒãƒãƒ£ãƒ¼ã€‚", "ProblemMatcherSchema.watching.activeOnStart": "true ã«è¨­å®šã™ã‚‹ã¨ã€ã‚¿ã‚¹ã‚¯ã®é–‹å§‹æ™‚ã«ã‚¦ã‚©ãƒƒãƒãƒ£ãƒ¼ãŒã‚¢ã‚¯ãƒ†ã‚£ãƒ– モードã«ãªã‚Šã¾ã™ã€‚ã“れ㯠beginPattern ã¨ä¸€è‡´ã™ã‚‹è¡Œã®ç™ºè¡Œã¨åŒç­‰ã§ã™ã€‚", "ProblemMatcherSchema.watching.beginsPattern": "出力内ã§ä¸€è‡´ã™ã‚‹ã¨ã€ã‚¦ã‚©ãƒƒãƒä¸­ã®ã‚¿ã‚¹ã‚¯ã®é–‹å§‹ãŒé€šçŸ¥ã•ã‚Œã¾ã™ã€‚", "ProblemMatcherSchema.watching.endsPattern": "出力内ã§ä¸€è‡´ã™ã‚‹ã¨ã€ã‚¦ã‚©ãƒƒãƒä¸­ã®ã‚¿ã‚¹ã‚¯ã®çµ‚了ãŒé€šçŸ¥ã•ã‚Œã¾ã™ã€‚", diff --git a/i18n/jpn/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/jpn/src/vs/platform/theme/common/colorRegistry.i18n.json index 8da89f6115c..9872f49057d 100644 --- a/i18n/jpn/src/vs/platform/theme/common/colorRegistry.i18n.json +++ b/i18n/jpn/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -60,6 +60,7 @@ "editorBackground": "エディターã®èƒŒæ™¯è‰²ã€‚", "editorForeground": "エディターã®æ—¢å®šã®å‰æ™¯è‰²ã€‚", "editorWidgetBackground": "検索/ç½®æ›çª“ãªã©ã€ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ ウィジェットã®èƒŒæ™¯è‰²ã€‚", + "editorWidgetBorder": "エディター ウィジェットã®å¢ƒç•Œç·šã®è‰²ã€‚", "editorSelection": "エディターã®é¸æŠžç¯„囲ã®è‰²ã€‚", "editorInactiveSelection": "éžã‚¢ã‚¯ãƒ†ã‚£ãƒ–ãªã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã®é¸æŠžç¯„囲ã®è‰²ã€‚", "editorSelectionHighlight": "é¸æŠžç¯„囲ã¨åŒã˜ã‚³ãƒ³ãƒ†ãƒ³ãƒ„ã®é ˜åŸŸã®è‰²ã€‚", diff --git a/i18n/jpn/src/vs/workbench/api/node/extHostTreeViews.i18n.json b/i18n/jpn/src/vs/workbench/api/node/extHostTreeViews.i18n.json index 8b6ad71cd4e..74c5f0eabd7 100644 --- a/i18n/jpn/src/vs/workbench/api/node/extHostTreeViews.i18n.json +++ b/i18n/jpn/src/vs/workbench/api/node/extHostTreeViews.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "treeView.notRegistered": "ID '{0}' ã®ãƒ„リー ビューã¯ç™»éŒ²ã•ã‚Œã¦ã„ã¾ã›ã‚“。", + "treeItem.notFound": "ID '{0}' ã®ãƒ„リー項目ã¯è¦‹ã¤ã‹ã‚Šã¾ã›ã‚“ã§ã—ãŸã€‚", + "treeView.duplicateElement": " {0} è¦ç´ ã¯æ—¢ã«ç™»éŒ²ã•ã‚Œã¦ã„ã¾ã™ã€‚" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/common/theme.i18n.json b/i18n/jpn/src/vs/workbench/common/theme.i18n.json index b361c556bdc..d183c267924 100644 --- a/i18n/jpn/src/vs/workbench/common/theme.i18n.json +++ b/i18n/jpn/src/vs/workbench/common/theme.i18n.json @@ -32,6 +32,7 @@ "activityBarBadgeBackground": "アクティビティ通知ãƒãƒƒã‚¸ã®èƒŒæ™¯è‰²ã€‚アクティビティ ãƒãƒ¼ã¯å·¦ç«¯ã¾ãŸã¯å³ç«¯ã«è¡¨ç¤ºã•ã‚Œã€ã‚µã‚¤ãƒ‰ ãƒãƒ¼ã®è¡¨ç¤ºã‚’切り替ãˆã‚‹ã“ã¨ãŒã§ãã¾ã™ã€‚", "activityBarBadgeForeground": "アクティビティ通知ãƒãƒƒã‚¸ã®å‰æ™¯è‰²ã€‚アクティビティ ãƒãƒ¼ã¯å·¦ç«¯ã¾ãŸã¯å³ç«¯ã«è¡¨ç¤ºã•ã‚Œã€ã‚µã‚¤ãƒ‰ ãƒãƒ¼ã®è¡¨ç¤ºã‚’切り替ãˆã‚‹ã“ã¨ãŒã§ãã¾ã™ã€‚", "sideBarBackground": "サイド ãƒãƒ¼ã®èƒŒæ™¯è‰²ã€‚サイド ãƒãƒ¼ã¯ã€ã‚¨ã‚¯ã‚¹ãƒ—ローラーや検索ãªã©ã®ãƒ“ューãŒå…¥ã‚‹ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", + "sideBarForeground": "サイド ãƒãƒ¼ã®å‰æ™¯è‰²ã€‚サイド ãƒãƒ¼ã¯ã€ã‚¨ã‚¯ã‚¹ãƒ—ローラーや検索ãªã©ã®ãƒ“ューãŒå…¥ã‚‹ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", "sideBarTitleForeground": "サイド ãƒãƒ¼ã®ã‚¿ã‚¤ãƒˆãƒ«ã®å‰æ™¯è‰²ã€‚サイド ãƒãƒ¼ã¯ã€ã‚¨ã‚¯ã‚¹ãƒ—ローラーや検索ãªã©ã®ãƒ“ューãŒå…¥ã‚‹ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", "sideBarSectionHeaderBackground": "サイド ãƒãƒ¼ã®ã‚»ã‚¯ã‚·ãƒ§ãƒ³ ヘッダーã®èƒŒæ™¯è‰²ã€‚サイド ãƒãƒ¼ã¯ã€ã‚¨ã‚¯ã‚¹ãƒ—ローラーや検索ãªã©ã®ãƒ“ューãŒå…¥ã‚‹ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", "titleBarActiveForeground": "ウィンドウãŒã‚¢ã‚¯ãƒ†ã‚£ãƒ–ãªå ´åˆã®ã‚¿ã‚¤ãƒˆãƒ« ãƒãƒ¼ã®å‰æ™¯ã€‚ç¾åœ¨ã€ã“ã®è‰²ã¯ macOS ã§ã®ã¿ã‚µãƒãƒ¼ãƒˆã•ã‚Œã¦ã„ã‚‹ã®ã§ã”注æ„ãã ã•ã„。", diff --git a/i18n/jpn/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/jpn/src/vs/workbench/electron-browser/main.contribution.i18n.json index e69cb0fb627..d813d5f6c23 100644 --- a/i18n/jpn/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/jpn/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -7,6 +7,7 @@ "view": "表示", "help": "ヘルプ", "file": "ファイル", + "developer": "開発者", "showEditorTabs": "é–‹ã„ã¦ã„るエディターをタブã«è¡¨ç¤ºã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚", "editorTabCloseButton": "エディター タブã®é–‰ã˜ã‚‹ãƒœã‚¿ãƒ³ã®ä½ç½®ã‚’制御ã™ã‚‹ã‹ã€[off] ã«è¨­å®šã—ãŸå ´åˆã«ç„¡åŠ¹ã«ã—ã¾ã™ã€‚", "showIcons": "é–‹ã„ã¦ã„るエディターをアイコンã§è¡¨ç¤ºã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚ã“ã‚Œã«ã¯ã€ã‚¢ã‚¤ã‚³ãƒ³ã®ãƒ†ãƒ¼ãƒžã‚’有効ã«ã™ã‚‹å¿…è¦ã‚‚ã‚ã‚Šã¾ã™ã€‚", diff --git a/i18n/jpn/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json b/i18n/jpn/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json index e57fd60ee0d..8943a8809bd 100644 --- a/i18n/jpn/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json @@ -6,5 +6,6 @@ { "copyValue": "値ã®ã‚³ãƒ”ー", "copy": "コピー", + "copyAll": "ã™ã¹ã¦ã‚³ãƒ”ー", "copyStackTrace": "呼ã³å‡ºã—履歴ã®ã‚³ãƒ”ー" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json b/i18n/jpn/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json index af68e40b4ae..d63fe387f50 100644 --- a/i18n/jpn/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json @@ -7,6 +7,7 @@ "debugAdapterBinNotFound": "デãƒãƒƒã‚° アダプターã®å®Ÿè¡Œå¯èƒ½ãƒ•ã‚¡ã‚¤ãƒ« '{0}' ãŒã‚ã‚Šã¾ã›ã‚“。", "debugAdapterCannotDetermineExecutable": "デãƒãƒƒã‚° アダプター '{0}' ã®å®Ÿè¡Œå¯èƒ½ãƒ•ã‚¡ã‚¤ãƒ«ã‚’判別ã§ãã¾ã›ã‚“。", "debugType": "構æˆã®ç¨®é¡žã€‚", + "debugTypeNotRecognised": "デãƒãƒƒã‚°ã®ç¨®é¡žã¯èªè­˜ã•ã‚Œã¾ã›ã‚“ã§ã—ãŸã€‚対応ã™ã‚‹ãƒ‡ãƒãƒƒã‚°ã®æ‹¡å¼µæ©Ÿèƒ½ãŒã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã¦ãŠã‚Šã€æœ‰åŠ¹ã«ãªã£ã¦ã„ã‚‹ã“ã¨ã‚’確èªã—ã¦ãã ã•ã„。", "node2NotSupported": "\"node2\" ã¯ã‚µãƒãƒ¼ãƒˆã•ã‚Œã¦ã„ã¾ã›ã‚“。代ã‚ã‚Šã« \"node\" を使用ã—ã€\"protocol\" 属性を \"inspector\" ã«è¨­å®šã—ã¦ãã ã•ã„。", "debugName": "構æˆã®åå‰ã€‚起動構æˆã®ãƒ‰ãƒ­ãƒƒãƒ—ダウン メニューã«è¡¨ç¤ºã•ã‚Œã¾ã™ã€‚", "debugRequest": "構æˆã®è¦æ±‚ã®ç¨®é¡žã€‚\"launch\" ã¾ãŸã¯ \"attach\" ã§ã™ã€‚", diff --git a/i18n/jpn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/jpn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 8b6ad71cd4e..e5b2af33ec3 100644 --- a/i18n/jpn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "disableOtherKeymapsConfirmation": "キーãƒã‚¤ãƒ³ãƒ‰é–“ã®ç«¶åˆã‚’回é¿ã™ã‚‹ãŸã‚ã«ã€ä»–ã®ã‚­ãƒ¼ãƒžãƒƒãƒ—を無効ã«ã—ã¾ã™ã‹?", + "yes": "ã¯ã„", + "no": "ã„ã„ãˆ" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/jpn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 15c3aee15db..9356fa119aa 100644 --- a/i18n/jpn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,7 +16,6 @@ "associations": "言語ã«å¯¾ã™ã‚‹ãƒ•ã‚¡ã‚¤ãƒ«ã®é–¢é€£ä»˜ã‘ (例 \"*.extension\": \"html\") を構æˆã—ã¾ã™ã€‚ã“れらã®é–¢é€£ä»˜ã‘ã¯ã€ã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã¦ã„る言語ã®æ—¢å®šã®é–¢é€£ä»˜ã‘より優先ã•ã‚Œã¾ã™ã€‚", "encoding": "ファイルã®èª­ã¿å–ã‚Š/書ãè¾¼ã¿ã§ä½¿ç”¨ã™ã‚‹æ—¢å®šã®æ–‡å­—セット エンコーディング。", "autoGuessEncoding": "有効ãªå ´åˆã€ãƒ•ã‚¡ã‚¤ãƒ«ã‚’é–‹ãã¨ãã«æ–‡å­—セット エンコードを推測ã—ã¾ã™", - "eol": "既定ã®æ”¹è¡Œæ–‡å­—。", "trimTrailingWhitespace": "有効ã«ã™ã‚‹ã¨ã€ãƒ•ã‚¡ã‚¤ãƒ«ã®ä¿å­˜æ™‚ã«æœ«å°¾ã®ç©ºç™½ã‚’トリミングã—ã¾ã™ã€‚", "insertFinalNewline": "有効ã«ã™ã‚‹ã¨ã€ãƒ•ã‚¡ã‚¤ãƒ«ã®ä¿å­˜æ™‚ã«æœ€æ–°ã®è¡Œã‚’末尾ã«æŒ¿å…¥ã—ã¾ã™ã€‚", "files.autoSave.off": "ダーティ ファイルを自動的ã«ä¿å­˜ã™ã‚‹ã“ã¨ã¯ã—ã¾ã›ã‚“。", @@ -27,6 +26,8 @@ "autoSaveDelay": "ダーティ ファイルã®è‡ªå‹•ä¿å­˜ã®é…延をミリ秒å˜ä½ã§åˆ¶å¾¡ã—ã¾ã™ã€‚'files.autoSave' ㌠'{0}' ã«è¨­å®šã•ã‚Œã¦ã„ã‚‹å ´åˆã®ã¿é©ç”¨ã•ã‚Œã¾ã™", "watcherExclude": "ファイル モニタリングã‹ã‚‰é™¤å¤–ã™ã‚‹ãƒ•ã‚¡ã‚¤ãƒ« パス㮠glob パターンを構æˆã—ã¾ã™ã€‚ã“ã®è¨­å®šã‚’変更ã™ã‚‹ã¨ã€å†èµ·å‹•ãŒå¿…è¦ã«ãªã‚Šã¾ã™ã€‚始動時㫠Code ãŒæ¶ˆè²»ã™ã‚‹ CPU 時間ãŒå¤šã„å ´åˆã¯ã€å¤§è¦æ¨¡ãªãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã‚’除外ã—ã¦åˆæœŸãƒ­ãƒ¼ãƒ‰ã‚’減らã›ã¾ã™ã€‚", "hotExit.off": "Hot Exit を無効ã«ã—ã¾ã™ã€‚", + "hotExit.onExit": "アプリケーションãŒé–‰ã˜ã‚‹ã¨ (Windows/Linux ã§æœ€å¾Œã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ãŒé–‰ã˜ã‚‹ã¨ãã€ã¾ãŸã¯ workbench.action.quit コマンドãŒãƒˆãƒªã‚¬ãƒ¼ã•ã‚Œã‚‹ã¨ã (コマンド パレットã€ã‚­ãƒ¼ ãƒã‚¤ãƒ³ãƒ‰ã€ãƒ¡ãƒ‹ãƒ¥ãƒ¼))ã€Hot Exit ãŒãƒˆãƒªã‚¬ãƒ¼ã•ã‚Œã¾ã™ã€‚ãƒãƒƒã‚¯ã‚¢ãƒƒãƒ—ã•ã‚Œã¦ã„ã‚‹ã™ã¹ã¦ã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã¯ã€æ¬¡ã®èµ·å‹•æ™‚ã«å¾©å…ƒã•ã‚Œã¾ã™ã€‚", + "hotExit.onExitAndWindowClose": "アプリケーションãŒé–‰ã˜ã‚‹ã¨ (Windows/Linux ã§æœ€å¾Œã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ãŒé–‰ã˜ã‚‹ã¨ãã€ã¾ãŸã¯ workbench.action.quit コマンドãŒãƒˆãƒªã‚¬ãƒ¼ã™ã‚‹ã¨ã (コマンド パレットã€ã‚­ãƒ¼ ãƒã‚¤ãƒ³ãƒ‰ã€ãƒ¡ãƒ‹ãƒ¥ãƒ¼))ã€Hot Exit ãŒãƒˆãƒªã‚¬ãƒ¼ã•ã‚Œã¾ã™ã€‚ã¾ãŸã€ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ãŒé–‹ã‹ã‚Œã¦ã„るウィンドウã«ã¤ã„ã¦ã‚‚ã€ãã‚ŒãŒæœ€å¾Œã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã‹ã©ã†ã‹ã«é–¢ä¿‚ãªãã€Hot Exit ãŒãƒˆãƒªã‚¬ãƒ¼ã•ã‚Œã¾ã™ã€‚フォルダーãŒé–‹ã‹ã‚Œã¦ã„ãªã„ウィンドウã¯ã™ã¹ã¦ã€æ¬¡å›žã®èµ·å‹•æ™‚ã«å¾©å…ƒã•ã‚Œã¾ã™ã€‚フォルダーã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã‚’シャットダウンå‰ã¨åŒã˜çŠ¶æ…‹ã«å¾©å…ƒã™ã‚‹ã«ã¯ã€\"window.reopenFolders\" ã‚’ \"all\" ã«è¨­å®šã—ã¾ã™ã€‚", "hotExit": "エディターを終了ã™ã‚‹ã¨ãã«ä¿å­˜ã‚’確èªã™ã‚‹ãƒ€ã‚¤ã‚¢ãƒ­ã‚°ã‚’çœç•¥ã—ã€ä¿å­˜ã•ã‚Œã¦ã„ãªã„ファイルをセッション後もä¿æŒã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚", "defaultLanguage": "æ–°ã—ã„ファイルã«å‰²ã‚Šå½“ã¦ã‚‰ã‚Œã‚‹æ—¢å®šã®è¨€èªžãƒ¢ãƒ¼ãƒ‰ã€‚", "editorConfigurationTitle": "エディター", diff --git a/i18n/jpn/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/jpn/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index a71fcb6fc94..e14e57a90eb 100644 --- a/i18n/jpn/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -5,5 +5,11 @@ // Do not edit this file. It is machine generated. { "slow": "スタートアップã®é…延ãŒæ¤œå‡ºã•ã‚Œã¾ã—ãŸ", - "slow.detail": "スタートアップãŒé…ã‹ã£ãŸã¨ã®ã“ã¨ã€ç”³ã—訳ã”ã–ã„ã¾ã›ã‚“。プロファイルを有効ã«ã—ã¦ã€'{0}' ã‚’å†èµ·å‹•ã—ã€ãƒ—ロファイルを共有ã—ã¦ãã ã•ã„。スタートアップã®æ”¹å–„ã®ãŸã‚ã«å‚考ã«ã•ã›ã¦ã„ãŸã ãã¾ã™ã€‚" + "slow.detail": "スタートアップãŒé…ã‹ã£ãŸã¨ã®ã“ã¨ã€ç”³ã—訳ã”ã–ã„ã¾ã›ã‚“。プロファイルを有効ã«ã—ã¦ã€'{0}' ã‚’å†èµ·å‹•ã—ã€ãƒ—ロファイルを共有ã—ã¦ãã ã•ã„。スタートアップã®æ”¹å–„ã®ãŸã‚ã«å‚考ã«ã•ã›ã¦ã„ãŸã ãã¾ã™ã€‚", + "prof.message": "プロファイルãŒæ­£å¸¸ã«ä½œæˆã•ã‚Œã¾ã—ãŸã€‚", + "prof.detail": "案件を作æˆã—ã€æ‰‹å‹•ã§æ¬¡ã®ãƒ•ã‚¡ã‚¤ãƒ«ã‚’添付ã—ã¦ãã ã•ã„:\\n{0}", + "prof.restartAndFileIssue": "å•é¡Œã‚’作æˆã—ã¦å†èµ·å‹•", + "prof.restart": "å†èµ·å‹•", + "prof.thanks": "ã”å”力ã„ãŸã ãã€ã‚ã‚ŠãŒã¨ã†ã”ã–ã„ã¾ã™ã€‚", + "prof.detail.restart": "'{0}' を引ã続ã使用ã™ã‚‹ã«ã¯ã€æœ€å¾Œã®å†èµ·å‹•ãŒå¿…è¦ã§ã™ã€‚ 改ã‚ã¦ã‚ãªãŸã®è²¢çŒ®ã«æ„Ÿè¬ã—ã¾ã™ã€‚" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json b/i18n/jpn/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json index 0a35cdb1be9..dba4d278b14 100644 --- a/i18n/jpn/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json @@ -4,6 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "errorInvalidConfiguration": "設定を書ãè¾¼ã‚ã¾ã›ã‚“。ファイル内ã®ã‚¨ãƒ©ãƒ¼/警告を修正ã—ã¦ã‹ã‚‰ã‚‚ã†ä¸€åº¦ãŠè©¦ã—ãã ã•ã„。", "editTtile": "編集", "replaceDefaultValue": "設定を置æ›", "copyDefaultValue": "設定ã«ã‚³ãƒ”ー", diff --git a/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json b/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json index b650b0b0eb3..d45b8437459 100644 --- a/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "toggleGitViewlet": "Git を表示", + "installAdditionalSCMProviders": "ãã®ä»–ã® SCM プロãƒã‚¤ãƒ€ãƒ¼ã‚’インストール...", "source control": "ソース管ç†", "toggleSCMViewlet": "SCM を表示", "view": "表示" diff --git a/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json b/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json index d53de2c62b0..d93c7d2fb84 100644 --- a/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "installAdditionalSCMProviders": "ãã®ä»–ã® SCM プロãƒã‚¤ãƒ€ãƒ¼ã‚’インストール...", "switch provider": "SCM プロãƒã‚¤ãƒ€ãƒ¼ã®åˆ‡ã‚Šæ›¿ãˆ..." } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index c0432625724..f7db07a2e2d 100644 --- a/i18n/jpn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,5 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0}, tasks" + "entryAriaLabel": "{0}, tasks", + "workspace": "ワークスペースã‹ã‚‰", + "extension": "拡張機能ã‹ã‚‰" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json index 37bbf2ce2e0..1e77cbdffdf 100644 --- a/i18n/jpn/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json @@ -5,6 +5,6 @@ // Do not edit this file. It is machine generated. { "tasksAriaLabel": "å†é–‹ã™ã‚‹ã‚¿ã‚¹ã‚¯ã®åå‰ã‚’入力ã—ã¾ã™", - "noTasksMatching": "No tasks matching", + "noTasksMatching": "一致ã™ã‚‹ã‚¿ã‚¹ã‚¯ãŒã‚ã‚Šã¾ã›ã‚“", "noTasksFound": "å†é–‹ã™ã‚‹ã‚¿ã‚¹ã‚¯ã¯ã‚ã‚Šã¾ã›ã‚“" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json index 99543dd018a..5a397f34e03 100644 --- a/i18n/jpn/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json @@ -5,6 +5,6 @@ // Do not edit this file. It is machine generated. { "tasksAriaLabel": "実行ã™ã‚‹ã‚¿ã‚¹ã‚¯ã®åå‰ã‚’入力ã—ã¾ã™", - "noTasksMatching": "No tasks matching", + "noTasksMatching": "一致ã™ã‚‹ã‚¿ã‚¹ã‚¯ãŒã‚ã‚Šã¾ã›ã‚“", "noTasksFound": "タスクãŒè¦‹ã¤ã‹ã‚Šã¾ã›ã‚“" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json index 12b9c699bf2..440b92fd91d 100644 --- a/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json @@ -6,5 +6,6 @@ { "TerminalTaskSystem.unknownError": "タスクã®å®Ÿè¡Œä¸­ã«ä¸æ˜Žãªã‚¨ãƒ©ãƒ¼ãŒç™ºç”Ÿã—ã¾ã—ãŸã€‚詳細ã«ã¤ã„ã¦ã¯ã€ã‚¿ã‚¹ã‚¯å‡ºåŠ›ãƒ­ã‚°ã‚’å‚ç…§ã—ã¦ãã ã•ã„。", "TerminalTaskSystem.terminalName": "タスク - {0}", - "TerminalTaskSystem": "UNC ドライブã§ã‚·ã‚§ãƒ« コマンドを実行ã§ãã¾ã›ã‚“。" + "TerminalTaskSystem": "UNC ドライブã§ã‚·ã‚§ãƒ« コマンドを実行ã§ãã¾ã›ã‚“。", + "unkownProblemMatcher": "å•é¡Œãƒžãƒƒãƒãƒ£ãƒ¼ {0} ã¯è§£æ±ºã§ãã¾ã›ã‚“ã§ã—ãŸã€‚マッãƒãƒ£ãƒ¼ã¯ç„¡è¦–ã•ã‚Œã¾ã™" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json index 6f9be6076a6..0cc1f921982 100644 --- a/i18n/jpn/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json @@ -7,5 +7,6 @@ "TaskRunnerSystem.unknownError": "タスクã®å®Ÿè¡Œä¸­ã«ä¸æ˜Žãªã‚¨ãƒ©ãƒ¼ãŒç™ºç”Ÿã—ã¾ã—ãŸã€‚詳細ã«ã¤ã„ã¦ã¯ã€ã‚¿ã‚¹ã‚¯å‡ºåŠ›ãƒ­ã‚°ã‚’å‚ç…§ã—ã¦ãã ã•ã„。", "TaskRunnerSystem.watchingBuildTaskFinished": "\nビルド タスクã®ã‚¦ã‚©ãƒƒãƒãŒçµ‚了ã—ã¾ã—ãŸã€‚", "TaskRunnerSystem.childProcessError": "Failed to launch external program {0} {1}.", - "TaskRunnerSystem.cancelRequested": "\nユーザーè¦æ±‚ã”ã¨ã«ã‚¿ã‚¹ã‚¯ '{0}' ãŒçµ‚了ã—ã¾ã—ãŸã€‚" + "TaskRunnerSystem.cancelRequested": "\nユーザーè¦æ±‚ã”ã¨ã«ã‚¿ã‚¹ã‚¯ '{0}' ãŒçµ‚了ã—ã¾ã—ãŸã€‚", + "unkownProblemMatcher": "å•é¡Œãƒžãƒƒãƒãƒ£ãƒ¼ {0} ã¯è§£æ±ºã§ãã¾ã›ã‚“ã§ã—ãŸã€‚マッãƒãƒ£ãƒ¼ã¯ç„¡è¦–ã•ã‚Œã¾ã™" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json b/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json index 799b12a797b..e7930c9cd7a 100644 --- a/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json @@ -26,5 +26,7 @@ "workbench.action.terminal.scrollUp": "上ã«ã‚¹ã‚¯ãƒ­ãƒ¼ãƒ« (è¡Œ)", "workbench.action.terminal.scrollUpPage": "スクロール アップ (ページ)", "workbench.action.terminal.scrollToTop": "一番上ã«ã‚¹ã‚¯ãƒ­ãƒ¼ãƒ«", - "workbench.action.terminal.clear": "クリア" + "workbench.action.terminal.clear": "クリア", + "workbench.action.terminal.allowWorkspaceShell": "ワークスペースã§ã‚·ã‚§ãƒ«ã‚’構æˆã™ã‚‹ã“ã¨ã‚’許å¯ã™ã‚‹", + "workbench.action.terminal.disallowWorkspaceShell": "ワークスペースã§ã‚·ã‚§ãƒ«ã‚’構æˆã™ã‚‹ã“ã¨ã‚’許å¯ã—ãªã„" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json b/i18n/jpn/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json index 89ac9d8c928..7592dde26b5 100644 --- a/i18n/jpn/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json @@ -6,6 +6,7 @@ { "selectTheme.label": "é…色テーマ", "installColorThemes": "ãã®ä»–ã®é…色テーマをインストール...", + "themes.selectTheme": "é…色テーマã®é¸æŠž (上/下キーã§ãƒ—レビューå¯èƒ½)", "selectIconTheme.label": "ファイル アイコンã®ãƒ†ãƒ¼ãƒž", "installIconThemes": "ãã®ä»–ã®ãƒ•ã‚¡ã‚¤ãƒ« アイコンã®ãƒ†ãƒ¼ãƒžã‚’インストール...", "noIconThemeLabel": "ãªã—", diff --git a/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json index 587eecb5f9d..950f340d9ae 100644 --- a/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -11,18 +11,25 @@ "welcomePage.openFolder": "フォルダーを開ã...", "welcomePage.cloneGitRepository": "Git リãƒã‚¸ãƒˆãƒªã‚’複製...", "welcomePage.recent": "最近", + "welcomePage.moreRecent": "ãã®ä»–", "welcomePage.noRecentFolders": "最近使用ã—ãŸãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ãªã—", "welcomePage.help": "ヘルプ", + "welcomePage.keybindingsCheatsheet": "å°åˆ·å¯èƒ½ãªã‚­ãƒ¼ãƒœãƒ¼ãƒ‰ã®ãƒãƒ¼ãƒˆã‚·ãƒ¼ãƒˆ", "welcomePage.introductoryVideos": "紹介ビデオ", "welcomePage.productDocumentation": "製å“ドキュメント", "welcomePage.gitHubRepository": "GitHub リãƒã‚¸ãƒˆãƒª", "welcomePage.stackOverflow": "Stack Overflow", "welcomePage.showOnStartup": "起動時ã«ã‚¦ã‚§ãƒ«ã‚«ãƒ  ページを表示", "welcomePage.customize": "カスタマイズã™ã‚‹", + "welcomePage.installExtensionPacks": "ツールã¨è¨€èªž", + "welcomePage.installExtensionPacksDescription": "{0} 㨠{1} ã®ã‚µãƒãƒ¼ãƒˆã‚’インストールã™ã‚‹ ", + "welcomePage.moreExtensions": "ãã®ä»–", "welcomePage.installKeymapDescription": "キーボード ショートカットをインストールã—ã¾ã™", + "welcomePage.installKeymapExtension": "{0} 㨠{1} ã®ã‚­ãƒ¼ãƒœãƒ¼ãƒ‰ ショートカットをインストール", "welcomePage.others": "ãã®ä»–", "welcomePage.colorTheme": "é…色テーマ", "welcomePage.colorThemeDescription": "エディターã¨ã‚³ãƒ¼ãƒ‰ã®å¤–観を自由ã«è¨­å®šã—ã¾ã™", + "welcomePage.learn": "å­¦ã¶", "welcomePage.showCommands": "ã™ã¹ã¦ã®ã‚³ãƒžãƒ³ãƒ‰ã®æ¤œç´¢ã¨å®Ÿè¡Œ", "welcomePage.showCommandsDescription": "コントロール パãƒãƒ«ã‹ã‚‰ã‚³ãƒžãƒ³ãƒ‰ã‚’検索ã—ã¦ã™ã°ã‚„ãアクセスã—ã¾ã™ ({0})", "welcomePage.interfaceOverview": "インターフェイスã®æ¦‚è¦", diff --git a/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 07b2eb85861..eba406025bb 100644 --- a/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -5,11 +5,27 @@ // Do not edit this file. It is machine generated. { "welcomePage": "よã†ã“ã", + "welcomePage.javaScript": "JavaScript", + "welcomePage.typeScript": "TypeScript", + "welcomePage.python": "Python", + "welcomePage.php": "PHP", + "welcomePage.docker": "Docker", + "welcomePage.vim": "Vim", + "welcomePage.sublime": "Sublime", + "welcomePage.atom": "Atom", + "welcomePage.extensionPackAlreadyInstalled": "{0} ã®ã‚µãƒãƒ¼ãƒˆã¯æ—¢ã«ã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã¦ã„ã¾ã™ã€‚", + "welcomePage.willReloadAfterInstallingExtensionPack": "{0} ã®ã‚µãƒãƒ¼ãƒˆã‚’インストールã—ãŸå¾Œã€ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ãŒå†åº¦èª­ã¿è¾¼ã¾ã‚Œã¾ã™ã€‚", + "welcomePage.installingExtensionPack": "{0} ã®ã‚µãƒãƒ¼ãƒˆã‚’インストール...", + "welcomePage.extensionPackNotFound": "ID {1} ã®ã‚µãƒãƒ¼ãƒˆ {0} ã¯è¦‹ã¤ã‹ã‚Šã¾ã›ã‚“ã§ã—ãŸã€‚", "welcomePage.keymapAlreadyInstalled": "キーボード ショートカット {0} ã¯æ—¢ã«ã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã¦ã„ã¾ã™ã€‚", "welcomePage.willReloadAfterInstallingKeymap": "キーボード ショートカット {0} をインストールã—ãŸå¾Œã€ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ãŒå†åº¦èª­ã¿è¾¼ã¾ã‚Œã¾ã™ã€‚", "welcomePage.installingKeymap": "{0} ã®ã‚­ãƒ¼ãƒœãƒ¼ãƒ‰ ショートカットをインストールã—ã¦ã„ã¾ã™...", "welcomePage.keymapNotFound": "ID {1} ã®ã‚­ãƒ¼ãƒœãƒ¼ãƒ‰ ショートカット {0} ã¯è¦‹ã¤ã‹ã‚Šã¾ã›ã‚“ã§ã—ãŸã€‚", "welcome.title": "よã†ã“ã", + "welcomePage.extensionListSeparator": ",", + "welcomePage.installedExtension": "{0} (インストール済ã¿) ", "ok": "OK", - "cancel": "キャンセル" + "cancel": "キャンセル", + "welcomePage.quickLinkBackground": "ウェルカム ページã®ã‚¯ã‚¤ãƒƒã‚¯ リンクã®èƒŒæ™¯è‰²ã€‚", + "welcomePage.quickLinkHoverBackground": "ウェルカム ページã®ã‚¯ã‚¤ãƒƒã‚¯ リンクã®ãƒ›ãƒãƒ¼èƒŒæ™¯è‰²ã€‚" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json b/i18n/jpn/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json index 0c7056bc9fc..81d7a645e32 100644 --- a/i18n/jpn/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json +++ b/i18n/jpn/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json @@ -6,6 +6,7 @@ { "open": "設定を開ã", "close": "é–‰ã˜ã‚‹", + "saveAndRetry": "設定をä¿å­˜ã—ã¦å†è©¦è¡Œ", "errorUnknownKey": "構æˆãƒ•ã‚¡ã‚¤ãƒ«ã«æ›¸ãè¾¼ã‚ã¾ã›ã‚“ (ä¸æ˜Žãªã‚­ãƒ¼)", "errorInvalidTarget": "構æˆãƒ•ã‚¡ã‚¤ãƒ«ã«æ›¸ãè¾¼ã‚ã¾ã›ã‚“ (無効ãªã‚¿ãƒ¼ã‚²ãƒƒãƒˆ)", "errorNoWorkspaceOpened": "é–‹ã„ã¦ã„るフォルダーãŒãªã„ãŸã‚ã€è¨­å®šã‚’書ãè¾¼ã‚ã¾ã›ã‚“。最åˆã«ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã‚’é–‹ã„ã¦ã‹ã‚‰ã€ã‚‚ã†ä¸€åº¦ãŠè©¦ã—ãã ã•ã„。", diff --git a/i18n/kor/extensions/markdown/out/extension.i18n.json b/i18n/kor/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/kor/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/kor/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/kor/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/kor/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/kor/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/kor/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/kor/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/kor/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/kor/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/kor/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/kor/extensions/merge-conflict/package.i18n.json b/i18n/kor/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/kor/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/kor/extensions/npm/package.i18n.json b/i18n/kor/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/kor/extensions/npm/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/kor/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/kor/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index def2cd28d67..4266985efc9 100644 --- a/i18n/kor/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/kor/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,8 +6,6 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "ì´ë¯¸ì§€ê°€ 너무 커서 íŽ¸ì§‘ê¸°ì— í‘œì‹œí•  수 없습니다. ", - "resourceOpenExternalButton": "ì´ë¯¸ì§€ 열기", - "resourceOpenExternalText": " 외부 í”„ë¡œê·¸ëž¨ì„ ì‚¬ìš©í• ê¹Œìš”?", "nativeBinaryError": "파ì¼ì´ ì´ì§„ì´ê±°ë‚˜ 매우 í¬ê±°ë‚˜ 지ì›ë˜ì§€ 않는 í…스트 ì¸ì½”ë”©ì„ ì‚¬ìš©í•˜ê¸° ë•Œë¬¸ì— íŽ¸ì§‘ê¸°ì—ì„œ 표시ë˜ì§€ 않습니다.", "sizeB": "{0}B", "sizeKB": "{0}KB", diff --git a/i18n/kor/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/kor/src/vs/editor/common/config/commonEditorConfig.i18n.json index 18538323353..18aff6704be 100644 --- a/i18n/kor/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/kor/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -40,7 +40,6 @@ "formatOnType": "ìž…ë ¥ 후 편집기ì—ì„œ ìžë™ìœ¼ë¡œ ì¤„ì˜ ì„œì‹ì„ 지정할지 여부를 제어합니다.", "formatOnPaste": "ë¶™ì—¬ë„£ì€ ì½˜í…ì¸ ì˜ ì„œì‹ì„ 편집기ì—ì„œ ìžë™ìœ¼ë¡œ 지정할지 여부를 제어합니다. í¬ë§·í„°ëŠ” 반드시 사용할 수 있어야 하며 문서ì—ì„œ ë²”ìœ„ì˜ ì„œì‹ì„ 지정할 수 있어야 합니다.", "suggestOnTriggerCharacters": "트리거 문ìžë¥¼ 입력할 ë•Œ ì œì•ˆì„ ìžë™ìœ¼ë¡œ 표시할지 여부를 제어합니다.", - "acceptSuggestionOnEnter": "'Tab' 키 ì™¸ì— 'Enter' í‚¤ì— ëŒ€í•œ ì œì•ˆë„ í—ˆìš©í• ì§€ë¥¼ 제어합니다. 새 ì¤„ì„ ì‚½ìž…í•˜ëŠ” ë™ìž‘ê³¼ ì œì•ˆì„ í—ˆìš©í•˜ëŠ” ë™ìž‘ ê°„ì˜ ëª¨í˜¸í•¨ì„ ì—†ì•¨ 수 있습니다.", "acceptSuggestionOnCommitCharacter": "커밋 문ìžì— 대한 ì œì•ˆì„ í—ˆìš©í• ì§€ë¥¼ 제어합니다. 예를 들어 JavaScriptì—서는 세미콜론(';')ì´ ì œì•ˆì„ í—ˆìš©í•˜ê³  해당 문ìžë¥¼ 입력하는 커밋 문ìžì¼ 수 있습니다.", "snippetSuggestions": "코드 ì¡°ê°ì´ 다른 추천과 함께 표시ë˜ëŠ”지 여부 ë° ì •ë ¬ ë°©ë²•ì„ ì œì–´í•©ë‹ˆë‹¤.", "emptySelectionClipboard": "ì„ íƒ ì˜ì—­ ì—†ì´ í˜„ìž¬ 줄 복사 여부를 제어합니다.", diff --git a/i18n/kor/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/kor/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..eb7148607bd --- /dev/null +++ b/i18n/kor/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "'{0}'ì— ëŒ€í•œ ì •ì˜ë¥¼ ì°¾ì„ ìˆ˜ 없습니다.", + "generic.noResults": "ì •ì˜ë¥¼ ì°¾ì„ ìˆ˜ ì—†ìŒ", + "meta.title": "– {0} ì •ì˜", + "actions.goToDecl.label": "ì •ì˜ë¡œ ì´ë™", + "actions.goToDeclToSide.label": "측면ì—ì„œ ì •ì˜ ì—´ê¸°", + "actions.previewDecl.label": "ì •ì˜ í”¼í‚¹(Peeking)", + "goToImplementation.noResultWord": "'{0}'ì— ëŒ€í•œ êµ¬í˜„ì„ ì°¾ì„ ìˆ˜ 없습니다.", + "goToImplementation.generic.noResults": "êµ¬í˜„ì„ ì°¾ì„ ìˆ˜ 없습니다.", + "meta.implementations.title": " – {0} ê°œ 구현", + "actions.goToImplementation.label": "구현으로 ì´ë™", + "actions.peekImplementation.label": "구현 미리 보기", + "goToTypeDefinition.noResultWord": "'{0}'ì— ëŒ€í•œ í˜•ì‹ ì •ì˜ë¥¼ ì°¾ì„ ìˆ˜ 없습니다.", + "goToTypeDefinition.generic.noResults": "í˜•ì‹ ì •ì˜ë¥¼ ì°¾ì„ ìˆ˜ 없습니다.", + "meta.typeDefinitions.title": "– {0} í˜•ì‹ ì •ì˜", + "actions.goToTypeDefinition.label": "í˜•ì‹ ì •ì˜ë¡œ ì´ë™", + "actions.peekTypeDefinition.label": "í˜•ì‹ ì •ì˜ ë¯¸ë¦¬ 보기" +} \ No newline at end of file diff --git a/i18n/kor/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/kor/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..57b4929798f --- /dev/null +++ b/i18n/kor/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "{0}ê°œ ì •ì˜ë¥¼ 표시하려면 í´ë¦­í•˜ì„¸ìš”." +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/kor/src/vs/workbench/electron-browser/main.contribution.i18n.json index 603999dbae9..4c30f4bc75c 100644 --- a/i18n/kor/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/kor/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -7,6 +7,7 @@ "view": "보기", "help": "ë„움ë§", "file": "파ì¼", + "developer": "개발ìž", "showEditorTabs": "ì—´ë ¤ 있는 편집기를 탭ì—ì„œ 표시할지 여부를 제어합니다.", "editorTabCloseButton": "íŽ¸ì§‘ê¸°ì˜ íƒ­ 닫기 ë‹¨ì¶”ì˜ ìœ„ì¹˜ë¥¼ 제어하거나 'off'ë¡œ ì„¤ì •ëœ ê²½ìš° ì´ ë‹¨ì¶”ë¥¼ 사용하지 ì•Šë„ë¡ ì„¤ì •í•©ë‹ˆë‹¤.", "showIcons": "열린 편집기를 ì•„ì´ì½˜ê³¼ 함께 표시할지 여부를 제어합니다. ì´ë¥¼ 위해서는 ì•„ì´ì½˜ í…Œë§ˆë„ ì‚¬ìš©í•˜ë„ë¡ ì„¤ì •í•´ì•¼ 합니다.", diff --git a/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 8b6ad71cd4e..86d18d9fce3 100644 --- a/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "disableOtherKeymapsConfirmation": "키 ë°”ì¸ë”© ê°„ 충ëŒì„ 피하기 위해 다른 키 ë§µì„ ì‚¬ìš©í•˜ì§€ ì•Šë„ë¡ ì„¤ì •í• ê¹Œìš”?", + "yes": "예", + "no": "아니요" +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/kor/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index f9b799b1655..fe8ef9500ce 100644 --- a/i18n/kor/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,7 +16,6 @@ "associations": "파ì¼ê³¼ ì–¸ì–´ì˜ ì—°ê²°ì„ êµ¬ì„±í•˜ì„¸ìš”(예: \"*.extension\": \"html\"). ì´ëŸ¬í•œ êµ¬ì„±ì€ ì„¤ì¹˜ëœ ì–¸ì–´ì˜ ê¸°ë³¸ 연결보다 ìš°ì„  순위가 높습니다.", "encoding": "파ì¼ì„ ì½ê³  쓸 ë•Œ 사용할 기본 ë¬¸ìž ì§‘í•© ì¸ì½”딩입니다.", "autoGuessEncoding": "사용하ë„ë¡ ì„¤ì •í•˜ëŠ” 경우 파ì¼ì„ ì—´ ë•Œ ë¬¸ìž ì§‘í•© ì¸ì½”ë”©ì„ ì¶”ì¸¡í•©ë‹ˆë‹¤.", - "eol": "줄 바꿈 문ìžì˜ 기본 ë입니다.", "trimTrailingWhitespace": "사용하ë„ë¡ ì„¤ì •ë˜ë©´ 파ì¼ì„ 저장할 ë•Œ 후행 ê³µë°±ì´ ìž˜ë¦½ë‹ˆë‹¤.", "insertFinalNewline": "사용하ë„ë¡ ì„¤ì •ë˜ë©´ 저장할 ë•Œ íŒŒì¼ ëì— ë§ˆì§€ë§‰ ì¤„ë°”ê¿ˆì„ ì‚½ìž…í•©ë‹ˆë‹¤.", "files.autoSave.off": "ë”í‹° 파ì¼ì´ ìžë™ìœ¼ë¡œ 저장ë˜ì§€ 않습니다.", diff --git a/i18n/kor/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/kor/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index 4b931297269..ef1cdc9bc09 100644 --- a/i18n/kor/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -5,5 +5,9 @@ // Do not edit this file. It is machine generated. { "slow": "ëŠë¦° 시작 ê°ì§€ë¨", - "slow.detail": "방금 ëŠë¦¬ê²Œ 시작ë˜ì—ˆìŠµë‹ˆë‹¤. 프로파ì¼ë§ì„ 사용하ë„ë¡ ì„¤ì •í•œ ìƒíƒœë¡œ '{0}'ì„(를) 다시 시작하세요. í”„ë¡œí•„ì„ ê³µìœ í•´ 주시면 다시 빠르게 ì‹œìž‘ë  ìˆ˜ 있ë„ë¡ ìµœì„ ì„ ë‹¤í•˜ê² ìŠµë‹ˆë‹¤." + "slow.detail": "방금 ëŠë¦¬ê²Œ 시작ë˜ì—ˆìŠµë‹ˆë‹¤. 프로파ì¼ë§ì„ 사용하ë„ë¡ ì„¤ì •í•œ ìƒíƒœë¡œ '{0}'ì„(를) 다시 시작하세요. í”„ë¡œí•„ì„ ê³µìœ í•´ 주시면 다시 빠르게 ì‹œìž‘ë  ìˆ˜ 있ë„ë¡ ìµœì„ ì„ ë‹¤í•˜ê² ìŠµë‹ˆë‹¤.", + "prof.message": "í”„ë¡œí•„ì„ ë§Œë“¤ì—ˆìŠµë‹ˆë‹¤.", + "prof.detail": "문제를 ë°œìƒì‹œí‚¤ê³  ë‹¤ìŒ íŒŒì¼ì„ 수ë™ìœ¼ë¡œ 첨부하세요.\n{0}", + "prof.restartAndFileIssue": "문제 만들기 ë° ë‹¤ì‹œ 시작", + "prof.restart": "다시 시작" } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/kor/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index cb5666d331a..a436e5a707b 100644 --- a/i18n/kor/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -5,6 +5,11 @@ // Do not edit this file. It is machine generated. { "welcomePage": "시작", + "welcomePage.typeScript": "TypeScript", + "welcomePage.php": "PHP", + "welcomePage.vim": "Vim", + "welcomePage.sublime": "Sublime", + "welcomePage.atom": "Atom", "welcomePage.keymapAlreadyInstalled": "{0} 바로 가기 키가 ì´ë¯¸ 설치ë˜ì–´ 있습니다.", "welcomePage.willReloadAfterInstallingKeymap": "{0} 바로 가기 키를 설치한 후 ì°½ì´ ë‹¤ì‹œ 로드ë©ë‹ˆë‹¤.", "welcomePage.installingKeymap": "{0} 바로 가기 키를 설치하는 중...", diff --git a/i18n/ptb/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json b/i18n/ptb/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json new file mode 100644 index 00000000000..74a80b4280d --- /dev/null +++ b/i18n/ptb/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json @@ -0,0 +1,36 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "activeEditorShort": "e.g. meuArquivo.txt", + "activeEditorMedium": "e.g. minhaPasta/meuArquivo.txt", + "activeEditorLong": "e.g. /Usuarios/Desenvolvimento/meuProjeto/minhaPasta/meuArquivo.txt", + "rootName": "e.g. meuProjeto", + "rootPath": "e.g. /Usuarios/Desenvolvimento/meuProjeto", + "appName": "e.g. VS Code", + "dirty": "Um indicador de alteração se o editor ativo foi alterado", + "separator": "um separador condicional (' - ') que somente é mostrado quando envolvido por variáveis com valores", + "assocLabelFile": "Arquivos com Extensão", + "assocDescriptionFile": "Mapear todos arquivos que correspondem ao padrão global no seu nome de arquivo à linguagem com o identificador dado", + "assocLabelPath": "Arquivos com Caminho", + "assocDescriptionPath": "Mapear todos os arquivos que correspondem ao caminho absoluto global no seu caminho à linguagem com o identificador dado", + "fileLabel": "Arquivos por Extensão", + "fileDescription": "Combina todos os arquivos de uma extensão de arquivo específica.", + "filesLabel": "Arquivos com Várias Extensões", + "filesDescription": "Combina todos os arquivos com qualquer uma das extensões de arquivo.", + "derivedLabel": "Arquivos com Irmãos por Nome", + "derivedDescription": "Combina arquivos que têm irmãos com o mesmo nome, mas uma extensão diferente.", + "topFolderLabel": "Pasta por Nome (Nível Superior)", + "topFolderDescription": "Combina uma pasta de nível superior com um nome específico.", + "topFoldersLabel": "Pastas com Vários Nomes (Nível Superior)", + "topFoldersDescription": "Combina várias pastas de nível superior.", + "folderLabel": "Pasta por Nome (Qualquer Local)", + "folderDescription": "Combina uma pasta com um nome específico em qualquer local.", + "falseDescription": "Desabilita o padrão.", + "trueDescription": "Habilita o padrão.", + "siblingsDescription": "Combina arquivos que têm irmãos com o mesmo nome, mas uma extensão diferente.", + "languageSpecificEditorSettings": "Configurações do editor especificas para a linguagem", + "languageSpecificEditorSettingsDescription": "Sobrescrever as configurações do editor para a linguagem" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/css/client/out/cssMain.i18n.json b/i18n/ptb/extensions/css/client/out/cssMain.i18n.json new file mode 100644 index 00000000000..a649796227b --- /dev/null +++ b/i18n/ptb/extensions/css/client/out/cssMain.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "cssserver.name": "Servidor de linguagem CSS" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/css/package.i18n.json b/i18n/ptb/extensions/css/package.i18n.json new file mode 100644 index 00000000000..de011d44dce --- /dev/null +++ b/i18n/ptb/extensions/css/package.i18n.json @@ -0,0 +1,67 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "css.lint.argumentsInColorFunction.desc": "Número inválido de parâmetros", + "css.lint.boxModel.desc": "Não use largura ou altura ao usar preenchimento ou borda", + "css.lint.compatibleVendorPrefixes.desc": "Ao usar um prefixo específico de fornecedor, certifique-se de também incluir todas as outras propriedades específicas do fornecedor", + "css.lint.duplicateProperties.desc": "Não use as definições de estilo duplicadas", + "css.lint.emptyRules.desc": "Não use conjuntos de regra em branco", + "css.lint.float.desc": "Evite usar 'float'. Floats levam a CSS frágil, que é fácil de quebrar se um aspecto do layout for alterado.", + "css.lint.fontFaceProperties.desc": "A regra @font-face deve definir propriedades 'src' e 'font-family'", + "css.lint.hexColorLength.desc": "Cores hexadecimais devem consistir em três ou seis números hexadecimais", + "css.lint.idSelector.desc": "Seletores não devem conter IDs, pois essas regras estão firmemente acopladas ao HTML.", + "css.lint.ieHack.desc": "IE hacks somente são necessários ao dar suporte ao IE7 e mais antigos", + "css.lint.important.desc": "Evite usar !important. Esta é uma indicação de que a especificidade do CSS inteiro saiu de controle e precisa ser fatorada novamente.", + "css.lint.importStatement.desc": "Instruções de importação não carregam em paralelo", + "css.lint.propertyIgnoredDueToDisplay.desc": "Propriedade ignorada devido à exibição. Por exemplo, com 'display: inline', as propriedades width, height, margin-top, margin-bottom e float não têm efeito", + "css.lint.universalSelector.desc": "O seletor universal (*) é conhecido por ser lento", + "css.lint.unknownProperties.desc": "Propriedade desconhecida.", + "css.lint.unknownVendorSpecificProperties.desc": "Propriedade específica do fornecedor desconhecida.", + "css.lint.vendorPrefix.desc": "Ao usar um prefixo específico do fornecedor, inclua também a propriedade padrão", + "css.lint.zeroUnits.desc": "Nenhuma unidade para zero é necessária", + "css.validate.desc": "Habilita ou desabilita todas as validações", + "less.lint.argumentsInColorFunction.desc": "Número inválido de parâmetros", + "less.lint.boxModel.desc": "Não use largura ou altura ao usar preenchimento ou borda", + "less.lint.compatibleVendorPrefixes.desc": "Ao usar um prefixo específico de fornecedor, certifique-se de também incluir todas as outras propriedades específicas do fornecedor", + "less.lint.duplicateProperties.desc": "Não use as definições de estilo duplicadas", + "less.lint.emptyRules.desc": "Não use conjuntos de regra em branco", + "less.lint.float.desc": "Evite usar 'float'. Floats levam a CSS frágil, que é fácil de quebrar se um aspecto do layout for alterado.", + "less.lint.fontFaceProperties.desc": "A regra @font-face deve definir propriedades 'src' e 'font-family'", + "less.lint.hexColorLength.desc": "Cores hexadecimais devem consistir em três ou seis números hexadecimais", + "less.lint.idSelector.desc": "Seletores não devem conter IDs, pois essas regras estão firmemente acopladas ao HTML.", + "less.lint.ieHack.desc": "IE hacks somente são necessários ao dar suporte ao IE7 e mais antigos", + "less.lint.important.desc": "Evite usar !important. Esta é uma indicação de que a especificidade do CSS inteiro saiu de controle e precisa ser fatorada novamente.", + "less.lint.importStatement.desc": "Instruções de importação não carregam em paralelo", + "less.lint.propertyIgnoredDueToDisplay.desc": "Propriedade ignorada devido à exibição. Por exemplo, com 'display: inline', as propriedades width, height, margin-top, margin-bottom e float não têm efeito", + "less.lint.universalSelector.desc": "O seletor universal (*) é conhecido por ser lento", + "less.lint.unknownProperties.desc": "Propriedade desconhecida.", + "less.lint.unknownVendorSpecificProperties.desc": "Propriedade específica do fornecedor desconhecida.", + "less.lint.vendorPrefix.desc": "Ao usar um prefixo específico do fornecedor, inclua também a propriedade padrão", + "less.lint.zeroUnits.desc": "Nenhuma unidade para zero é necessária", + "less.validate.desc": "Habilita ou desabilita todas as validações", + "scss.lint.argumentsInColorFunction.desc": "Número inválido de parâmetros", + "scss.lint.boxModel.desc": "Não use largura ou altura ao usar preenchimento ou borda", + "scss.lint.compatibleVendorPrefixes.desc": "Ao usar um prefixo específico de fornecedor, certifique-se de também incluir todas as outras propriedades específicas do fornecedor", + "scss.lint.duplicateProperties.desc": "Não use as definições de estilo duplicadas", + "scss.lint.emptyRules.desc": "Não use conjuntos de regra em branco", + "scss.lint.float.desc": "Evite usar 'float'. Floats levam a CSS frágil, que é fácil de quebrar se um aspecto do layout for alterado.", + "scss.lint.fontFaceProperties.desc": "A regra @font-face deve definir propriedades 'src' e 'font-family'", + "scss.lint.hexColorLength.desc": "Cores hexadecimais devem consistir em três ou seis números hexadecimais", + "scss.lint.idSelector.desc": "Seletores não devem conter IDs, pois essas regras estão firmemente acopladas ao HTML.", + "scss.lint.ieHack.desc": "IE hacks somente são necessários ao dar suporte ao IE7 e mais antigos", + "scss.lint.important.desc": "Evite usar !important. Esta é uma indicação de que a especificidade do CSS inteiro saiu de controle e precisa ser fatorada novamente.", + "scss.lint.importStatement.desc": "Instruções de importação não carregam em paralelo", + "scss.lint.propertyIgnoredDueToDisplay.desc": "Propriedade ignorada devido à exibição. Por exemplo, com 'display: inline', as propriedades width, height, margin-top, margin-bottom e float não têm efeito", + "scss.lint.universalSelector.desc": "O seletor universal (*) é conhecido por ser lento", + "scss.lint.unknownProperties.desc": "Propriedade desconhecida.", + "scss.lint.unknownVendorSpecificProperties.desc": "Propriedade específica do fornecedor desconhecida.", + "scss.lint.vendorPrefix.desc": "Ao usar um prefixo específico do fornecedor, inclua também a propriedade padrão", + "scss.lint.zeroUnits.desc": "Nenhuma unidade para zero é necessária", + "scss.validate.desc": "Habilita ou desabilita todas as validações", + "less.colorDecorators.enable.desc": "Habilita ou desabilita decoradores de cores", + "scss.colorDecorators.enable.desc": "Habilita ou desabilita decoradores de cores", + "css.colorDecorators.enable.desc": "Habilita ou desabilita decoradores de cores" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/extension-editing/out/packageDocumentHelper.i18n.json b/i18n/ptb/extensions/extension-editing/out/packageDocumentHelper.i18n.json new file mode 100644 index 00000000000..8505afd6d4a --- /dev/null +++ b/i18n/ptb/extensions/extension-editing/out/packageDocumentHelper.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "languageSpecificEditorSettings": "Configurações do editor especificas para a linguagem", + "languageSpecificEditorSettingsDescription": "Sobrescrever as configurações do editor para a linguagem" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/git/out/askpass-main.i18n.json b/i18n/ptb/extensions/git/out/askpass-main.i18n.json new file mode 100644 index 00000000000..280b14bd0d7 --- /dev/null +++ b/i18n/ptb/extensions/git/out/askpass-main.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "missOrInvalid": "Credenciais ausentes ou inválidas." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/git/out/commands.i18n.json b/i18n/ptb/extensions/git/out/commands.i18n.json new file mode 100644 index 00000000000..ab5667e260b --- /dev/null +++ b/i18n/ptb/extensions/git/out/commands.i18n.json @@ -0,0 +1,43 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tag at": "Etiqueta em {0}", + "remote branch at": "Ramo remoto em {0}", + "repourl": "URL do repositório", + "parent": "Diretório pai", + "cloning": "Clonando repositório do Git...", + "openrepo": "Abrir Repositório", + "proposeopen": "Gostaria de abrir o repositório clonado?", + "confirm revert": "Tem certeza que deseja reverter as alterações selecionadas em {0}?", + "revert": "Reverter as alterações", + "confirm discard": "Tem certeza que deseja descartar as alterações em {0}?", + "confirm discard multiple": "Tem certeza que deseja descartar as alterações em {0} arquivos?", + "discard": "Descartar alterações", + "confirm discard all": "Tem certeza que deseja descartar TODAS as alterações? Isso é IRREVERSÃVEL!", + "discardAll": "Descartar TODAS as alterações", + "no staged changes": "Não há nenhuma modificação escalonada para confirmar.\n\nGostaria de escalonar automaticamente todas as suas alterações e confirmá-las diretamente?", + "yes": "Sim", + "always": "Sempre", + "no changes": "Não há mudanças para confirmar.", + "commit message": "Confirmar mensagem", + "provide commit message": "Por favor, forneça uma mensagem de commit", + "branch name": "Nome do Ramo", + "provide branch name": "Por favor, forneça um nome de ramo", + "no remotes to pull": "O seu repositório não possui remotos configurados para efetuar pull.", + "no remotes to push": "O seu repositório não possui remotos configurados para efetuar push.", + "nobranch": "Por favor, faça checkout em um ramo para fazer push em um remoto.", + "pick remote": "Pegue um remoto para publicar o ramo '{0}':", + "sync is unpredictable": "Esta ação vai fazer push e pull nos commits de e para '{0}'.", + "ok": "OK", + "never again": "Ok, Nunca Mostrar Novamente", + "no remotes to publish": "Seu repositório não possui remotos configurados para publicação.", + "disabled": "Git está desativado ou não é suportado neste espaço de trabalho", + "clean repo": "Por favor, limpe sua árvore de trabalho do repositório antes de fazer check-out.", + "cant push": "Não pode empurrar referências para remoto. Execute 'Pull' primeiro para integrar suas alterações.", + "git error details": "Git: {0}", + "git error": "Erro de Git", + "open git log": "Abrir Histórico do Git" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/git/out/main.i18n.json b/i18n/ptb/extensions/git/out/main.i18n.json new file mode 100644 index 00000000000..ae1dee26032 --- /dev/null +++ b/i18n/ptb/extensions/git/out/main.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "using git": "Usando git {0} de {1}", + "updateGit": "Atualizar o Git", + "neverShowAgain": "Não mostrar novamente", + "git20": "Você parece ter o git {0} instalado. Code funciona melhor com git > = 2" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/git/out/model.i18n.json b/i18n/ptb/extensions/git/out/model.i18n.json new file mode 100644 index 00000000000..717d2b4364a --- /dev/null +++ b/i18n/ptb/extensions/git/out/model.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "open": "Abrir", + "merge changes": "Mesclar Alterações", + "staged changes": "Alterações em Etapas", + "changes": "Alterações", + "ok": "OK", + "neveragain": "Nunca Mostrar Novamente", + "huge": "O repositório git em '{0}' tem muitas atualizações ativas, somente um subconjunto de funcionalidades do Git será habilitado." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/git/out/scmProvider.i18n.json b/i18n/ptb/extensions/git/out/scmProvider.i18n.json new file mode 100644 index 00000000000..490dda3603e --- /dev/null +++ b/i18n/ptb/extensions/git/out/scmProvider.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "commit": "Confirmar" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/git/out/statusbar.i18n.json b/i18n/ptb/extensions/git/out/statusbar.i18n.json new file mode 100644 index 00000000000..0b6ee800ffa --- /dev/null +++ b/i18n/ptb/extensions/git/out/statusbar.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "checkout": "Checkout...", + "sync changes": "Sincronizar alterações", + "publish changes": "Publicar alterações", + "syncing changes": "Sincronizando alterações..." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/git/package.i18n.json b/i18n/ptb/extensions/git/package.i18n.json new file mode 100644 index 00000000000..0c79f1929bb --- /dev/null +++ b/i18n/ptb/extensions/git/package.i18n.json @@ -0,0 +1,48 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "command.clone": "Clonar", + "command.init": "Inicializar Repositório", + "command.refresh": "Atualizar", + "command.openChange": "Abrir alterações", + "command.openFile": "Abrir Arquivo", + "command.stage": "Estagiar Alterações", + "command.stageAll": "Estagiar Todas Alterações", + "command.stageSelectedRanges": "Estagiar Faixas Selecionadas", + "command.revertSelectedRanges": "Reverter Faixas Selecionadas", + "command.unstage": "Desestagiar Alterações", + "command.unstageAll": "Desestagiar Todas Alterações", + "command.unstageSelectedRanges": "Desestagiar Faixas Selecionadas", + "command.clean": "Descartar Alterações", + "command.cleanAll": "Descartar Todas as Alterações", + "command.commit": "Confirmar", + "command.commitStaged": "Confirmar os preparados", + "command.commitStagedSigned": "Confirmar Estagiados (Desconectado)", + "command.commitAll": "Confirmar tudo", + "command.commitAllSigned": "Confirmar Tudo (Desconectado)", + "command.undoCommit": "Desfazer Ultima Confirmação", + "command.checkout": "Fazer checkout para...", + "command.branch": "Criar Ramificação...", + "command.pull": "Efetuar pull", + "command.pullRebase": "Efetuar pull (Rebase)", + "command.push": "Enviar por push", + "command.pushTo": "Enviar por push para...", + "command.sync": "Sincronizar", + "command.publish": "Publicar", + "command.showOutput": "Mostrar Saída do Git", + "config.enabled": "Se o git estiver habilitado", + "config.path": "Caminho para o executável do git", + "config.autorefresh": "Se a atualização automática estiver habilitada", + "config.autofetch": "Se a recuperação automática estiver habilitada", + "config.enableLongCommitWarning": "Se mensagens longas de confirmação devem ter aviso", + "config.confirmSync": "Confirmar antes de sincronizar repositórios git", + "config.countBadge": "Controla o contador de distintivos do git. 'todos' considera todas as alterações. 'rastreado' considera apenas as alterações controladas. 'desligado' desliga o contador.", + "config.checkoutType": "Controla quais tipos de ramos são listados quando executando `Checkout para... `. `todos` mostra todas as referências, `local` mostra apenas os ramos locais, `etiqueta` mostra apenas etiquetas e `remoto` mostra apenas os ramos remotos.", + "config.ignoreLegacyWarning": "Ignora o aviso de Git legado", + "config.ignoreLimitWarning": "Ignora o aviso quando houver muitas alterações em um repositório", + "config.defaultCloneDirectory": "O local padrão onde clonar um repositório git", + "config.enableSmartCommit": "Confirme todas as alterações quando não há modificações escalonadas." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/grunt/out/main.i18n.json b/i18n/ptb/extensions/grunt/out/main.i18n.json new file mode 100644 index 00000000000..909b68937c6 --- /dev/null +++ b/i18n/ptb/extensions/grunt/out/main.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "execFailed": "Auto detecção de Grunt falhou com erro: {0}" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/grunt/package.i18n.json b/i18n/ptb/extensions/grunt/package.i18n.json new file mode 100644 index 00000000000..d79ce76907e --- /dev/null +++ b/i18n/ptb/extensions/grunt/package.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "config.grunt.autoDetect": "Controla se a deteção automática de tarefas do Grunt está ligado ou desligado. Padrão é ligado." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/gulp/out/main.i18n.json b/i18n/ptb/extensions/gulp/out/main.i18n.json new file mode 100644 index 00000000000..51b05e4013e --- /dev/null +++ b/i18n/ptb/extensions/gulp/out/main.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "execFailed": "Auto detecção de gulp falhou com erro: {0}" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/gulp/package.i18n.json b/i18n/ptb/extensions/gulp/package.i18n.json new file mode 100644 index 00000000000..fae292414c2 --- /dev/null +++ b/i18n/ptb/extensions/gulp/package.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "config.gulp.autoDetect": "Controla se a detecção automática de tarefas Gulp está ativada ou desativada. Por padrão, é ativado." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/html/client/out/htmlMain.i18n.json b/i18n/ptb/extensions/html/client/out/htmlMain.i18n.json new file mode 100644 index 00000000000..314d1e5c58a --- /dev/null +++ b/i18n/ptb/extensions/html/client/out/htmlMain.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "htmlserver.name": "Servidor de Linguagem HTML" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/html/package.i18n.json b/i18n/ptb/extensions/html/package.i18n.json new file mode 100644 index 00000000000..2f255a02e7f --- /dev/null +++ b/i18n/ptb/extensions/html/package.i18n.json @@ -0,0 +1,27 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "html.format.enable.desc": "Ativa/desativa o formatador HTML padrão (requer reinicialização)", + "html.format.wrapLineLength.desc": "Quantidade máxima de caracteres por linha (0 = desativar).", + "html.format.unformatted.desc": "Lista de tags, separados por vírgula, que não deveria ser reformatada. o padrão é 'nulo' para todas as tags listadas em https://www.w3.org/TR/html5/dom.html#phrasing-content.", + "html.format.contentUnformatted.desc": "Lista de tags, separada por vírgula, onde o conteúdo não deve ser reformatado. o padrão é 'nulo' para a tag 'pré'.", + "html.format.indentInnerHtml.desc": "Indentar secões e .", + "html.format.preserveNewLines.desc": "Se quebras de linha existentes antes de elementos deveriam ser preservadas. Só funciona antes de elementos, não dentro de rótulos ou para texto.", + "html.format.maxPreserveNewLines.desc": "Número máximo de quebras de linha a serem preservadas em um bloco. Use 'null' para ilimitado.", + "html.format.indentHandlebars.desc": "Formatar e indentar {{#foo}} e {{/ foo}}.", + "html.format.endWithNewline.desc": "Finalizar com uma nova linha.", + "html.format.extraLiners.desc": "Lista de rótulos, separados por vírgulas, que deveriam ter uma quebra de linha extra antes deles. 'null' admite o padrão \"head, body, /html\".", + "html.format.wrapAttributes.desc": "Agrupar atributos.", + "html.format.wrapAttributes.auto": "Agrupar atributos somente quando o tamanho da linha é excedido.", + "html.format.wrapAttributes.force": "Agrupar cada atributo exceto o primeiro.", + "html.format.wrapAttributes.forcealign": "Agrupar cada atributo, exceto o primeiro e manter alinhado.", + "html.format.wrapAttributes.forcemultiline": "Agrupar cada atributo.", + "html.suggest.angular1.desc": "Configura se o suporte da linguagem HTML interna sugere rótulos e propriedades do Angular V1.", + "html.suggest.ionic.desc": "Configura se o suporte da linguagem HTML interna sugere rótulos, propriedades e valores Ionic.", + "html.suggest.html5.desc": "Configura se o suporte da linguagem HTML interna sugere rótulos, propriedades e valores HTML5.", + "html.validate.scripts": "Configura se o suporte da linguagem HTML interna valida scripts embutidos.", + "html.validate.styles": "Configura se o suporte da linguagem HTML interna valida estilos embutidos." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/jake/out/main.i18n.json b/i18n/ptb/extensions/jake/out/main.i18n.json new file mode 100644 index 00000000000..4cfc54e5fef --- /dev/null +++ b/i18n/ptb/extensions/jake/out/main.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "execFailed": "Auto detecção de Jake falhou com erro: {0}" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/jake/package.i18n.json b/i18n/ptb/extensions/jake/package.i18n.json new file mode 100644 index 00000000000..94c08817c8d --- /dev/null +++ b/i18n/ptb/extensions/jake/package.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "config.jake.autoDetect": "Controla se a detecção automática de tarefas Jake está ativada ou desativada. Por padrão, é ativado." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/javascript/out/features/bowerJSONContribution.i18n.json b/i18n/ptb/extensions/javascript/out/features/bowerJSONContribution.i18n.json new file mode 100644 index 00000000000..84b277202e8 --- /dev/null +++ b/i18n/ptb/extensions/javascript/out/features/bowerJSONContribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "json.bower.default": "Bower.json padrão", + "json.bower.error.repoaccess": "Falha na solicitação ao repositório bower: {0}", + "json.bower.latest.version": "último" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/javascript/out/features/packageJSONContribution.i18n.json b/i18n/ptb/extensions/javascript/out/features/packageJSONContribution.i18n.json new file mode 100644 index 00000000000..9917fa36b2e --- /dev/null +++ b/i18n/ptb/extensions/javascript/out/features/packageJSONContribution.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "json.package.default": "Package.json padrão", + "json.npm.error.repoaccess": "Falha na solicitação ao repositório NPM: {0}", + "json.npm.latestversion": "A versão do pacote mais recente no momento", + "json.npm.majorversion": "Combina com a versão principal mais recente (1.x.x)", + "json.npm.minorversion": "Combina a versão secundária mais recente (1.2.x)", + "json.npm.version.hover": "Última versão: {0}" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/json/client/out/jsonMain.i18n.json b/i18n/ptb/extensions/json/client/out/jsonMain.i18n.json new file mode 100644 index 00000000000..4391c95a2ba --- /dev/null +++ b/i18n/ptb/extensions/json/client/out/jsonMain.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "jsonserver.name": "Servidor de linguagem JSON" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/json/package.i18n.json b/i18n/ptb/extensions/json/package.i18n.json new file mode 100644 index 00000000000..9d812f5b253 --- /dev/null +++ b/i18n/ptb/extensions/json/package.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "json.schemas.desc": "Esquemas associadas a arquivos de JSON no projeto atual", + "json.schemas.url.desc": "Um URL para um esquema ou um caminho relativo a um esquema no diretório atual", + "json.schemas.fileMatch.desc": "Uma matriz de padrões de arquivos para correspondência ao resolver arquivos JSON para esquemas.", + "json.schemas.fileMatch.item.desc": "Um padrão de arquivos que pode conter '*' para fazer a correspondência ao resolver arquivos JSON para esquemas.", + "json.schemas.schema.desc": "A definição de esquema para o URL dado. O esquema precisa ser fornecido apenas para evitar acessos ao URL do esquema.", + "json.format.enable.desc": "Habilitar/desabilitar o formatador JSON padrão (requer reinicialização)", + "json.tracing.desc": "Loga a comunicação entre o VS Code e o servidor de linguagem JSON.", + "json.colorDecorators.enable.desc": "Habilita ou desabilita os decoradores de cor" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/markdown/out/extension.i18n.json b/i18n/ptb/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ptb/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ptb/extensions/markdown/out/previewContentProvider.i18n.json b/i18n/ptb/extensions/markdown/out/previewContentProvider.i18n.json new file mode 100644 index 00000000000..f4e956aa5eb --- /dev/null +++ b/i18n/ptb/extensions/markdown/out/previewContentProvider.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "preview.securityMessage.text": "Scripts foram desabilitados neste documento", + "preview.securityMessage.title": "Scripts são desabilitados na pré-visualização de markdown. Altere a configuração de segurança de pré-visualização do Markdown para habilitar scripts", + "preview.securityMessage.label": "Aviso de segurança de scripts desabilitados" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/markdown/out/security.i18n.json b/i18n/ptb/extensions/markdown/out/security.i18n.json new file mode 100644 index 00000000000..6b83ed6faed --- /dev/null +++ b/i18n/ptb/extensions/markdown/out/security.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "preview.showPreviewSecuritySelector.disallowScriptsForWorkspaceTitle": "Desabilitar a execução de scripts em pré-visualização de markdown para este espaço de trabalho", + "preview.showPreviewSecuritySelector.currentSelection": "Configuração atual", + "preview.showPreviewSecuritySelector.allowScriptsForWorkspaceTitle": "Habilitar a execução de scripts em pré-visualizações de markdown para este espaço de trabalho", + "preview.showPreviewSecuritySelector.title": "Alterar configurações de segurança para a pré-visualização do Markdown" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/markdown/package.i18n.json b/i18n/ptb/extensions/markdown/package.i18n.json new file mode 100644 index 00000000000..83c2f99b160 --- /dev/null +++ b/i18n/ptb/extensions/markdown/package.i18n.json @@ -0,0 +1,22 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "markdown.preview.doubleClickToSwitchToEditor.desc": "Duplo clique na pré-visualização markdown para alternar para o editor.", + "markdown.preview.fontFamily.desc": "Controla a família de fonte usada na pré-visualização de markdown.", + "markdown.preview.fontSize.desc": "Controla o tamanho da fonte em pixels usado na pré-visualização de markdown.", + "markdown.preview.lineHeight.desc": "Controla a altura de linha usada na pré-visualização de markdown. Este número é relativo ao tamanho de fonte.", + "markdown.preview.markEditorSelection.desc": "Marca a seleção atual do editor na pré-visualização de markdown.", + "markdown.preview.scrollEditorWithPreview.desc": "Quando a pré-visualização de markdown é rolada, atualiza a exibição do editor.", + "markdown.preview.scrollPreviewWithEditorSelection.desc": "Rola a pré-visualização do markdown para revelar a linha atualmente selecionada do editor.", + "markdown.preview.title": "Abrir a visualização", + "markdown.previewFrontMatter.dec": "Configura como o frontispicio YAML frente questão devem ser processado na pré-visualização de markdown. 'hide' remove o frontispicio. Caso contrário, o frontispicio é tratado como conteúdo de markdown.", + "markdown.previewSide.title": "Abre pré-visualização ao lado", + "markdown.showSource.title": "Exibir Código-Fonte", + "markdown.styles.dec": "Uma lista de URLs ou caminhos locais para folhas de estilo CSS para usar na pré-visualização do markdown. Caminhos relativos são interpretados em relação à pasta aberta no explorer. Se não houver nenhuma pasta aberta, eles são interpretados em relação ao local do arquivo markdown. Todos os ' \\' precisam ser escritos como ' \\ \\ '.", + "markdown.showPreviewSecuritySelector.title": "Alterar as configurações de segurança de pré-visualização do Markdown", + "markdown.preview.enableExperimentalExtensionApi.desc": "[Experimental] Permitir extensões para ampliar a pré-visualização do markdown.", + "markdown.trace.desc": "Habilitar log de depuração para a extensão do markdown." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/ptb/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ptb/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ptb/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/ptb/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ptb/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ptb/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/ptb/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ptb/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ptb/extensions/merge-conflict/package.i18n.json b/i18n/ptb/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ptb/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ptb/extensions/npm/package.i18n.json b/i18n/ptb/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ptb/extensions/npm/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ptb/extensions/php/out/features/validationProvider.i18n.json b/i18n/ptb/extensions/php/out/features/validationProvider.i18n.json new file mode 100644 index 00000000000..9e0ce64f472 --- /dev/null +++ b/i18n/ptb/extensions/php/out/features/validationProvider.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "php.useExecutablePath": "Você permite {0} (definido como uma configuração do espaço de trabalho) a ser executado para lint de arquivos PHP?", + "php.yes": "Permitir", + "php.no": "Não permitir", + "wrongExecutable": "Não é possível validar {0} pois não é um executável php válido. Use a configuração 'php.validate.executablePath' para configurar o executável do PHP.", + "noExecutable": "Não é possível validar porque nenhum executável PHP está definido. Use a configuração 'php.validate.executablePath' para configurar o executável do PHP.", + "unknownReason": "Falha ao executar o php usando o caminho: {0}. O motivo é desconhecido." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/php/package.i18n.json b/i18n/ptb/extensions/php/package.i18n.json new file mode 100644 index 00000000000..7ec916f5dd8 --- /dev/null +++ b/i18n/ptb/extensions/php/package.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "configuration.suggest.basic": "Configura se as sugestões intrínsecas da linguagem PHP estão habilitadas. O suporte sugere globais e variáveis do PHP.", + "configuration.validate.enable": "Habilita/desabilita a validação interna do PHP.", + "configuration.validate.executablePath": "Aponta para o executável do PHP.", + "configuration.validate.run": "Se o linter é executado ao salvar ou ao digitar.", + "configuration.title": "PHP", + "commands.categroy.php": "PHP", + "command.untrustValidationExecutable": "Desabilita a validação de executável do PHP (definida como configuração do espaço de trabalho)" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/features/bufferSyncSupport.i18n.json b/i18n/ptb/extensions/typescript/out/features/bufferSyncSupport.i18n.json new file mode 100644 index 00000000000..1cef0c6e94a --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/features/bufferSyncSupport.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "versionMismatch": "Incompatibilidade de versão! global tsc ({0})! = serviço de linguagem do VS Code ({1}). Erros de compilação inconsistentes podem ocorrer", + "moreInformation": "Mais informações", + "doNotCheckAgain": "Não verificar novamente", + "close": "Fechar", + "updateTscCheck": "Atualizada configuração de usuário 'typescript.check.tscVersion' para false " +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/features/completionItemProvider.i18n.json b/i18n/ptb/extensions/typescript/out/features/completionItemProvider.i18n.json new file mode 100644 index 00000000000..58097d90545 --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/features/completionItemProvider.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "acquiringTypingsLabel": "Adquirindo digitações...", + "acquiringTypingsDetail": "Adquirindo definições de digitações para o Intellisense." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json b/i18n/ptb/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json new file mode 100644 index 00000000000..99716f32145 --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ts-check": "Habilita verificação semântica em um arquivo JavaScript. Deve estar no topo de um arquivo.", + "ts-nocheck": "Desabilita verificação semântica em um arquivo JavaScript. Deve estar no topo de um arquivo.", + "ts-ignore": "Suprime erros de @ts-check na próxima linha de um arquivo." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/features/implementationsCodeLensProvider.i18n.json b/i18n/ptb/extensions/typescript/out/features/implementationsCodeLensProvider.i18n.json new file mode 100644 index 00000000000..ef8dd6423d6 --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/features/implementationsCodeLensProvider.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "oneImplementationLabel": "1 implementação", + "manyImplementationLabel": "{0} implementações", + "implementationsErrorLabel": "Não foi possível determinar implementações" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/features/jsDocCompletionProvider.i18n.json b/i18n/ptb/extensions/typescript/out/features/jsDocCompletionProvider.i18n.json new file mode 100644 index 00000000000..20b08d7679b --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/features/jsDocCompletionProvider.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "typescript.jsDocCompletionItem.documentation": "Comentário JSDoc" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/features/referencesCodeLensProvider.i18n.json b/i18n/ptb/extensions/typescript/out/features/referencesCodeLensProvider.i18n.json new file mode 100644 index 00000000000..1838c3c1621 --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/features/referencesCodeLensProvider.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "oneReferenceLabel": "1 referência", + "manyReferenceLabel": "{0} referências", + "referenceErrorLabel": "Não foi possível determinar as referências" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/typescriptMain.i18n.json b/i18n/ptb/extensions/typescript/out/typescriptMain.i18n.json new file mode 100644 index 00000000000..82e6c288fb1 --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/typescriptMain.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "typescript.projectConfigNoWorkspace": "Favor abrir uma pasta no VS Code para usar um projeto TypeScript ou JavaScript", + "typescript.projectConfigUnsupportedFile": "Não foi possível determinar o projeto TypeScript ou JavaScript. Tipo de arquivo não suportado", + "typescript.projectConfigCouldNotGetInfo": "Não foi possível determinar o projeto TypeScript ou JavaScript", + "typescript.noTypeScriptProjectConfig": "Arquivo não é parte de um projeto TypeScript", + "typescript.noJavaScriptProjectConfig": "Arquivo não é parte de um projeto JavaScript", + "typescript.configureTsconfigQuickPick": "Configurar tsconfig.json", + "typescript.configureJsconfigQuickPick": "Configurar jsconfig.json", + "typescript.projectConfigLearnMore": "Saber Mais" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/typescriptServiceClient.i18n.json b/i18n/ptb/extensions/typescript/out/typescriptServiceClient.i18n.json new file mode 100644 index 00000000000..37527e507b0 --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/typescriptServiceClient.i18n.json @@ -0,0 +1,24 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noServerFound": "O caminho {0} não aponta para uma instalação de tsserver válida. Voltando para a versão do TypeScript empacotada.", + "noBundledServerFound": "O tsserver do VS Code foi excluído por outra aplicação, como por exemplo uma ferramenta de detecção de virus mal-comportada. Favor reinstalar o VS Code.", + "versionNumber.custom": "personalizado", + "serverCouldNotBeStarted": "Servidor de linguagem TypeScript não pôde ser iniciado. Mensagem de erro é: {0}", + "useVSCodeVersionOption": "Usar a Versão do VS Code", + "activeVersion": "Atualmente ativo", + "useWorkspaceVersionOption": "Use a versão de área de trabalho", + "learnMore": "Saiba Mais", + "selectTsVersion": "Selecione a versão do TypeScript usada para os recursos de linguagem JavaScript e TypeScript", + "typescript.openTsServerLog.notSupported": "Logging de TS Server requer TS TS 2.2.2+", + "typescript.openTsServerLog.loggingNotEnabled": "Logging de TS Server está desligado. Por favor configure 'typescript.tsserver.log' e reinicie o TS Server para habilitar o log", + "typescript.openTsServerLog.enableAndReloadOption": "Habilitar logging e reniciar TS server", + "typescript.openTsServerLog.noLogFile": "O TS Server não iniciou o logging.", + "openTsServerLog.openFileFailedFailed": "Não foi possível abrir o arquivo de log do TS Server", + "serverDiedAfterStart": "O serviço de linguagem TypeScript morreu 5 vezes depois que começou. O serviço não será reiniciado.", + "serverDiedReportIssue": "Reportar Problema", + "serverDied": "O serviço TypeScript morreu inesperadamente 5 vezes nos últimos 5 minutos." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/utils/logger.i18n.json b/i18n/ptb/extensions/typescript/out/utils/logger.i18n.json new file mode 100644 index 00000000000..bc738f43d0c --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/utils/logger.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "channelName": "TypeScript" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/utils/projectStatus.i18n.json b/i18n/ptb/extensions/typescript/out/utils/projectStatus.i18n.json new file mode 100644 index 00000000000..5cb18373637 --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/utils/projectStatus.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "hintExclude": "Para habilitar os recursos de linguagem JavaScript/TypeScipt em todo o projeto, excluir pastas com muitos arquivos, como: {0}", + "hintExclude.generic": "Para habilitar os recursos de linguagem JavaScript/TypeScipt em todo o projeto, excluir pastas grandes com arquivos em que você não trabalha.", + "open": "Configurar exclusões", + "large.label": "Configurar exclusões", + "hintExclude.tooltip": "Para habilitar os recursos de linguagem JavaScript/TypeScipt em todo o projeto, excluir pastas grandes com arquivos em que você não trabalha." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/ptb/extensions/typescript/out/utils/typingsStatus.i18n.json new file mode 100644 index 00000000000..ce050eb3d8e --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "installingPackages": "Buscando dados para melhor IntelliSense do TypeScript", + "typesInstallerInitializationFailed.title": "Não foi possível instalar arquivos de digitação para recursos da linguagem JavaScript. Certifique-se que NPM está instalado e está em seu caminho", + "typesInstallerInitializationFailed.moreInformation": "Mais informações", + "typesInstallerInitializationFailed.doNotCheckAgain": "Não verificar novamente", + "typesInstallerInitializationFailed.close": "Fechar" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/package.i18n.json b/i18n/ptb/extensions/typescript/package.i18n.json new file mode 100644 index 00000000000..5e4125ec050 --- /dev/null +++ b/i18n/ptb/extensions/typescript/package.i18n.json @@ -0,0 +1,45 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "typescript.reloadProjects.title": "Recarregar Projeto", + "javascript.reloadProjects.title": "Recarregar Projeto", + "configuration.typescript": "TypeScript", + "typescript.useCodeSnippetsOnMethodSuggest.dec": "Funções completas com a assinatura do parâmetro.", + "typescript.tsdk.desc": "Especifica o caminho da pasta que contém os arquivos tsserver e lib*.d.ts para usar.", + "typescript.disableAutomaticTypeAcquisition": "Desabilita a aquisição automática de tipo. Requer TypeScript > = 2.0.6 e um reinício depois da alteração.", + "typescript.check.tscVersion": "Verifica se um ima instalação global do compilador TypeScript (por exemplo, tsc) difere do serviço de linguagem TypeScript usado.", + "typescript.tsserver.log": "Habilita o log do servidor TS para um arquivo. Este log pode ser usado para diagnosticar problemas do servidor de TS. O log pode conter caminhos de arquivo, código-fonte e outras informações potencialmente confidenciais do seu projeto.", + "typescript.tsserver.trace": "Habilita o rastreamento de mensagens enviadas para o servidor de TS. Este rastreamento pode ser usado para diagnosticar problemas do servidor de TS. O rastreamento pode conter caminhos de arquivo, código-fonte e outras informações potencialmente confidenciais do seu projeto.", + "typescript.tsserver.experimentalAutoBuild": "Habilita auto build experimental. Requer a versão 1.9 dev ou 2.x do tsserver e o reinício do VS Code depois da alteração.", + "typescript.validate.enable": "Habilita/Desabilita a validação TypeScript.", + "typescript.format.enable": "Habilita/Desabilita o formatador padrão TypeScript.", + "javascript.format.enable": "Habilita/Desabilita o formatador padrão JavaScript.", + "format.insertSpaceAfterCommaDelimiter": "Define o tratamento de espaços após um delimitador vírgula.", + "format.insertSpaceAfterSemicolonInForStatements": "Define o tratamento de espaços após um ponto e vírgula para um comando.", + "format.insertSpaceBeforeAndAfterBinaryOperators": "Define o tratamento de espaços após um operador binário.", + "format.insertSpaceAfterKeywordsInControlFlowStatements": "Define o tratamento de espaços após palavras-chave em um comando de controle de fluxo.", + "format.insertSpaceAfterFunctionKeywordForAnonymousFunctions": "Define o tratamento de espaços após uma palavra-chave de função para funções anônimas.", + "format.insertSpaceBeforeFunctionParenthesis": "Define a manipulação de espaços antes de parênteses do argumento de função. Requer TypeScript > = 2.1.5.", + "format.insertSpaceAfterOpeningAndBeforeClosingNonemptyParenthesis": "Define a manipulação de espaços após abrir e antes de fechar parênteses não vazios.", + "format.insertSpaceAfterOpeningAndBeforeClosingNonemptyBrackets": "Define a manipulação de espaços após abrir e antes de fechar colchetes não vazios.", + "format.insertSpaceAfterOpeningAndBeforeClosingNonemptyBraces": "Define a manipulação de espaços após abrir e antes de fechar chaves não vazias. Requer TypeScript >= 2.3.0.", + "format.insertSpaceAfterOpeningAndBeforeClosingTemplateStringBraces": "Define a manipulação de espaços após abrir e antes de fechar chaves de cadeias de caracteres de modelos. Requer TypeScript >= 2.0.6.", + "format.insertSpaceAfterOpeningAndBeforeClosingJsxExpressionBraces": "Define a manipulação de espaços após abrir e antes de fechar chaves de expressões JSX. Requer TypeScript >= 2.0.6.", + "format.placeOpenBraceOnNewLineForFunctions": "Define-se uma chave de abertura é colocada em uma nova linha para funções ou não.", + "format.placeOpenBraceOnNewLineForControlBlocks": "Define-se uma chave de abertura é colocada em uma nova linha para blocos de controle ou não.", + "javascript.validate.enable": "Habilitar/Desabilitar validação JavaScript.", + "typescript.goToProjectConfig.title": "Ir para a Configuração do Projeto", + "javascript.goToProjectConfig.title": "Ir para a Configuração do Projeto", + "javascript.referencesCodeLens.enabled": "Habilitar/desabilitar referências CodeLens em arquivos JavaScript.", + "typescript.referencesCodeLens.enabled": "Habilitar/desabilitar referências CodeLens em arquivos TypeScript. Requer TypeScript > = 2.0.6.", + "typescript.implementationsCodeLens.enabled": "Habilitar/desabilitar implementações CodeLens. Requer TypeScript > = 2.0.6.", + "typescript.openTsServerLog.title": "Abrir arquivo de log do servidor TS", + "typescript.selectTypeScriptVersion.title": "Selecionar a versão do JavaScript", + "jsDocCompletion.enabled": "Habilitar/Desabilitar comentários JSDoc automáticos.", + "javascript.implicitProjectConfig.checkJs": "Habilitar/desabilitar verificação semântica de arquivos JavaScript. Os arquivos existentes jsconfig.json ou tsconfig.json substituem essa configuração. Requer TypeScript > = 2.3.1.", + "typescript.check.npmIsInstalled": "Verificar se NPM está instalado para aquisição automática de digitação", + "javascript.nameSuggestions": "Habilitar/desabilitar incluindo nomes exclusivos do arquivo nas listas de sugestão de JavaScript." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/browser/ui/actionbar/actionbar.i18n.json b/i18n/ptb/src/vs/base/browser/ui/actionbar/actionbar.i18n.json new file mode 100644 index 00000000000..4ecb2c803f4 --- /dev/null +++ b/i18n/ptb/src/vs/base/browser/ui/actionbar/actionbar.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "titleLabel": "{0} ({1})" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/browser/ui/aria/aria.i18n.json b/i18n/ptb/src/vs/base/browser/ui/aria/aria.i18n.json new file mode 100644 index 00000000000..e558eb6187a --- /dev/null +++ b/i18n/ptb/src/vs/base/browser/ui/aria/aria.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "repeated": "{0} (ocorreu novamente)" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/browser/ui/findinput/findInput.i18n.json b/i18n/ptb/src/vs/base/browser/ui/findinput/findInput.i18n.json new file mode 100644 index 00000000000..524ba7bb4a7 --- /dev/null +++ b/i18n/ptb/src/vs/base/browser/ui/findinput/findInput.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defaultLabel": "entrada" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/browser/ui/findinput/findInputCheckboxes.i18n.json b/i18n/ptb/src/vs/base/browser/ui/findinput/findInputCheckboxes.i18n.json new file mode 100644 index 00000000000..1a477ef1e6d --- /dev/null +++ b/i18n/ptb/src/vs/base/browser/ui/findinput/findInputCheckboxes.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "caseDescription": "Diferenciar Maiúsculas de Minúsculas", + "wordsDescription": "Coincidir Palavra Inteira", + "regexDescription": "Usar Expressão Regular" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/browser/ui/inputbox/inputBox.i18n.json b/i18n/ptb/src/vs/base/browser/ui/inputbox/inputBox.i18n.json new file mode 100644 index 00000000000..0b282bdee8a --- /dev/null +++ b/i18n/ptb/src/vs/base/browser/ui/inputbox/inputBox.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "alertErrorMessage": "Erro: {0}", + "alertWarningMessage": "Aviso: {0}", + "alertInfoMessage": "Informações: {0}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/ptb/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json new file mode 100644 index 00000000000..d023184ae70 --- /dev/null +++ b/i18n/ptb/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "imgMeta": "{0}x{1} {2}", + "largeImageError": "A imagem é muito grande para ser exibida no editor.", + "nativeBinaryError": "O arquivo não pode ser exibido no editor porque é binário, muito grande ou usa uma codificação de texto sem suporte.", + "sizeB": "{0}B", + "sizeKB": "{0}KB", + "sizeMB": "{0}MB", + "sizeGB": "{0}GB", + "sizeTB": "{0}TB" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/browser/ui/toolbar/toolbar.i18n.json b/i18n/ptb/src/vs/base/browser/ui/toolbar/toolbar.i18n.json new file mode 100644 index 00000000000..4a046b57296 --- /dev/null +++ b/i18n/ptb/src/vs/base/browser/ui/toolbar/toolbar.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "more": "Mais" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/common/errorMessage.i18n.json b/i18n/ptb/src/vs/base/common/errorMessage.i18n.json new file mode 100644 index 00000000000..257ffd9e14c --- /dev/null +++ b/i18n/ptb/src/vs/base/common/errorMessage.i18n.json @@ -0,0 +1,18 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "message": "{0}. Código de erro: {1}", + "error.permission.verbose": "Permissão Negada (HTTP {0})", + "error.permission": "Permissão Negada", + "error.http.verbose": "{0} (HTTP {1}: {2})", + "error.http": "{0} (HTTP {1})", + "error.connection.unknown.verbose": "Erro de Conexão Desconhecido ({0})", + "error.connection.unknown": "Ocorreu um erro de conexão desconhecido. Você não está mais conectado à Internet ou o servidor que você está conectado está offline.", + "stackTrace.format": "{0}: {1}", + "error.defaultMessage": "Ocorreu um erro desconhecido. Consulte o log para obter mais detalhes.", + "nodeExceptionMessage": "Ocorreu um erro de sistema ({0})", + "error.moreErrors": "{0} ({1} erros no total)" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/common/jsonErrorMessages.i18n.json b/i18n/ptb/src/vs/base/common/jsonErrorMessages.i18n.json new file mode 100644 index 00000000000..d6108586df8 --- /dev/null +++ b/i18n/ptb/src/vs/base/common/jsonErrorMessages.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "error.invalidSymbol": "Símbolo inválido", + "error.invalidNumberFormat": "Formato de número inválido", + "error.propertyNameExpected": "Nome de propriedade esperado", + "error.valueExpected": "Valor esperado", + "error.colonExpected": "Dois-pontos esperados", + "error.commaExpected": "Vírgula esperada", + "error.closeBraceExpected": "Chave de fechamento esperada", + "error.closeBracketExpected": "Colchete de fechamento esperado", + "error.endOfFileExpected": "Fim do arquivo esperado" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/common/processes.i18n.json b/i18n/ptb/src/vs/base/common/processes.i18n.json new file mode 100644 index 00000000000..165322e5952 --- /dev/null +++ b/i18n/ptb/src/vs/base/common/processes.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ExecutableParser.commandMissing": "Erro: informações de executável devem definir um comando do tipo string", + "ExecutableParser.isShellCommand": "Aviso: IsShellCommand deve ser to tipo booleano. Ignorando valor {0}", + "ExecutableParser.args": "Aviso: args deve ser do tipo string[]. Ignorando valor {0}.", + "ExecutableParser.invalidCWD": "Aviso: options.cwd deve ser do tipo string. Ignorando valor {0}." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/common/severity.i18n.json b/i18n/ptb/src/vs/base/common/severity.i18n.json new file mode 100644 index 00000000000..7aff8041180 --- /dev/null +++ b/i18n/ptb/src/vs/base/common/severity.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "sev.error": "Erro", + "sev.warning": "Aviso", + "sev.info": "Informações" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/node/processes.i18n.json b/i18n/ptb/src/vs/base/node/processes.i18n.json new file mode 100644 index 00000000000..3584dc9b15e --- /dev/null +++ b/i18n/ptb/src/vs/base/node/processes.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "TaskRunner.UNC": "Não é possível executar um comando shell em uma unidade UNC." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/node/zip.i18n.json b/i18n/ptb/src/vs/base/node/zip.i18n.json new file mode 100644 index 00000000000..a577f90ea2e --- /dev/null +++ b/i18n/ptb/src/vs/base/node/zip.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "notFound": "{0} não encontrado dentro do zip." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/parts/quickopen/browser/quickOpenModel.i18n.json b/i18n/ptb/src/vs/base/parts/quickopen/browser/quickOpenModel.i18n.json new file mode 100644 index 00000000000..1d0f7ebd47a --- /dev/null +++ b/i18n/ptb/src/vs/base/parts/quickopen/browser/quickOpenModel.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpenAriaLabelEntry": "{0}, seletor", + "quickOpenAriaLabel": "seletor" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/parts/quickopen/browser/quickOpenWidget.i18n.json b/i18n/ptb/src/vs/base/parts/quickopen/browser/quickOpenWidget.i18n.json new file mode 100644 index 00000000000..ca3d8a5266a --- /dev/null +++ b/i18n/ptb/src/vs/base/parts/quickopen/browser/quickOpenWidget.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpenAriaLabel": "Seletor rápido. Digite para filtrar resultados.", + "treeAriaLabel": "Seletor rápido" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/parts/tree/browser/treeDefaults.i18n.json b/i18n/ptb/src/vs/base/parts/tree/browser/treeDefaults.i18n.json new file mode 100644 index 00000000000..5e72c45050c --- /dev/null +++ b/i18n/ptb/src/vs/base/parts/tree/browser/treeDefaults.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "collapse": "Recolher" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/code/electron-main/menus.i18n.json b/i18n/ptb/src/vs/code/electron-main/menus.i18n.json new file mode 100644 index 00000000000..85312962c12 --- /dev/null +++ b/i18n/ptb/src/vs/code/electron-main/menus.i18n.json @@ -0,0 +1,164 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "mFile": "&&Arquivo", + "mEdit": "&&Editar", + "mSelection": "&&Seleção", + "mView": "&&Visualizar", + "mGoto": "&&Ir", + "mDebug": "&&Depurar", + "mWindow": "Janela", + "mHelp": "&&Ajuda", + "miNewWindow": "Nova &&Janela", + "mAbout": "Sobre {0}", + "mServices": "Serviços", + "mHide": "Ocultar {0}", + "mHideOthers": "Ocultar Outros", + "mShowAll": "Mostrar Tudo", + "miQuit": "Sair de {0}", + "miNewFile": "&&Novo Arquivo", + "miOpen": "&&Abrir", + "miOpenFolder": "Abrir &&Pasta", + "miOpenFile": "&&Abrir Arquivo", + "miOpenRecent": "Abrir &&Recente", + "miSave": "&&Salvar", + "miSaveAs": "Salvar &&Como...", + "miSaveAll": "Salvar &&Tudo", + "miAutoSave": "Salvar Automaticamente", + "miRevert": "Re&&verter Arquivo", + "miCloseWindow": "Fe&&char Janela", + "miCloseFolder": "Fechar &&Pasta", + "miCloseEditor": "Fechar &&Editor", + "miExit": "Sai&&r", + "miOpenSettings": "&&Configurações", + "miOpenKeymap": "Atalhos de &&Teclado", + "miOpenKeymapExtensions": "Extensões de &&Mapeamento de Teclado", + "miOpenSnippets": "Trechos de Có&&digo do Usuário", + "miSelectColorTheme": "Cor do T&&ema", + "miSelectIconTheme": "&&Ãcone de Arquivo do Tema", + "miPreferences": "&&Preferências", + "miReopenClosedEditor": "&&Reabrir Editor Fechado", + "miClearRecentOpen": "&&Limpar Arquivos Recentes", + "miUndo": "&&Desfazer", + "miRedo": "&&Refazer", + "miCut": "Cor&&tar", + "miCopy": "&&Copiar", + "miPaste": "Co&&lar", + "miFind": "&&Localizar", + "miReplace": "&&Substituir", + "miFindInFiles": "Localizar &&nos Arquivos", + "miReplaceInFiles": "Substituir &&nos Arquivos", + "miEmmetExpandAbbreviation": "Emmet: E&&xpandir Abreviação", + "miShowEmmetCommands": "E&&mmet...", + "miToggleLineComment": "&&Alternar Comentário de Linha", + "miToggleBlockComment": "Alternar Comentário de &&Bloco", + "miInsertCursorAbove": "&&Inserir cursor acima", + "miInsertCursorBelow": "Inserir cursor a&&baixo", + "miInsertCursorAtEndOfEachLineSelected": "Adicionar C&&ursores ao Final das Linhas", + "miAddSelectionToNextFindMatch": "Adicionar &&próxima ocorrência", + "miAddSelectionToPreviousFindMatch": "Adicionar ocorrência a&&nterior ", + "miSelectHighlights": "Selecionar todas as &&ocorrências", + "miCopyLinesUp": "&&Copiar linha acima", + "miCopyLinesDown": "C&&opiar linha abaixo", + "miMoveLinesUp": "Mo&&ver linha para cima", + "miMoveLinesDown": "Mover &&linha para baixo", + "miSelectAll": "&&Selecionar Tudo", + "miSmartSelectGrow": "&&Expandir seleção", + "miSmartSelectShrink": "&&Reduzir seleção", + "miViewExplorer": "&&Explorador", + "miViewSearch": "&&Pesquisar", + "miViewSCM": "S&&CM", + "miViewDebug": "&&Depurar", + "miViewExtensions": "E&&xtensões", + "miToggleOutput": "&&Saída", + "miToggleDebugConsole": "Con&&sole de Depuração", + "miToggleIntegratedTerminal": "Terminal &&Integrado", + "miMarker": "&&Problemas", + "miAdditionalViews": "&&Visualizações Adicionais", + "miCommandPalette": "&&Paleta de comando", + "miToggleFullScreen": "Alternar &&Tela Inteira", + "miToggleZenMode": "Alternar modo Zen", + "miToggleMenuBar": "Alternar &&Barra de Menus", + "miSplitEditor": "Dividir &&editor", + "miToggleEditorLayout": "Alternar &&Layout do Grupo de Editor", + "miToggleSidebar": "&&Alternar Barra Lateral", + "miMoveSidebarRight": "&&Mover a barra lateral para a direita", + "miMoveSidebarLeft": "&&Mover a barra lateral para a esquerda", + "miTogglePanel": "Alternar &&Painel", + "miHideStatusbar": "&&Ocultar Barra de Status", + "miShowStatusbar": "&&Mostrar Barra de Status", + "miHideActivityBar": "Ocultar Barra de &&Atividades", + "miShowActivityBar": "Mostrar Barra de &&Atividades", + "miToggleWordWrap": "Alternar &&Quebra de Linha", + "miToggleRenderWhitespace": "Alternar &&Renderização de Espaços em Branco", + "miToggleRenderControlCharacters": "Alternar &&Caracteres de Controle", + "miZoomIn": "&&Ampliar", + "miZoomOut": "Red&&uzir", + "miZoomReset": "&&Reinicializar Zoom", + "miBack": "&&Voltar", + "miForward": "&&Avançar", + "miNextEditor": "&&Próximo Editor", + "miPreviousEditor": "&&Editor Anterior", + "miNextEditorInGroup": "&&Próximo Editor Usado no Grupo", + "miPreviousEditorInGroup": "&&Editor Anterior Usado no Grupo", + "miSwitchEditor": "Trocar &&Editor", + "miFocusFirstGroup": "&&Primeiro Grupo", + "miFocusSecondGroup": "&&Segundo Grupo", + "miFocusThirdGroup": "&&Terceiro Grupo", + "miNextGroup": "&&Próximo Grupo", + "miPreviousGroup": "&&Grupo Anterior", + "miSwitchGroup": "Trocar &&Grupo", + "miGotoFile": "Ir para &&Arquivo...", + "miGotoSymbolInFile": "Ir para o &&Símbolo no Arquivo...", + "miGotoSymbolInWorkspace": "Ir para o Símbolo em &&Ãrea de Trabalho", + "miGotoDefinition": "Ir para &&Definição", + "miGotoTypeDefinition": "Ir para a &&definição de tipo", + "miGotoImplementation": "Ir para a &&implementação", + "miGotoLine": "Ir para &&Linha...", + "miStartDebugging": "Iniciar Depuração", + "miStartWithoutDebugging": "Iniciar &&Sem Depuração", + "miStopDebugging": "&&Parar Depuração", + "miRestart Debugging": "&&Reiniciar Depuração", + "miOpenConfigurations": "Abrir &&Configurações", + "miAddConfiguration": "Adicionar Configuração...", + "miStepOver": "Pular &&Sobre", + "miStepInto": "Pular &&Dentro", + "miStepOut": "Pular &&Fora", + "miContinue": "&&Continuar", + "miToggleBreakpoint": "Alternar &&Ponto de Parada", + "miConditionalBreakpoint": "Ponto de Parada &&Condicional...", + "miColumnBreakpoint": "Ponto de Parada de C&&oluna", + "miFunctionBreakpoint": "Ponto de Parada de &&Função...", + "miNewBreakpoint": "&&Novo Ponto de Parada", + "miDisableAllBreakpoints": "Desabilitar T&&odos os Pontos de Parada", + "miRemoveAllBreakpoints": "Remover &&Todos os Pontos de Parada", + "miInstallAdditionalDebuggers": "&&Instalar Depuradores Adicionais...", + "mMinimize": "Minimizar", + "mClose": "Fechar", + "mBringToFront": "Trazer Tudo para a Frente", + "miToggleDevTools": "&&Alternar Ferramentas do Desenvolvedor", + "miAccessibilityOptions": "&&Opções de Acessibilidade", + "miReportIssues": "Relatar &&Problemas", + "miWelcome": "&&Bem-vindo", + "miInteractivePlayground": "Playground &&Interativo", + "miDocumentation": "&&Documentação", + "miReleaseNotes": "&&Notas de Versão", + "miKeyboardShortcuts": "Referência de &&Atalhos de Teclado", + "miIntroductoryVideos": "&&Vídeos Introdutórios", + "miTwitter": "&&Junte-se a nós no Twitter", + "miUserVoice": "&&Pesquisar Solicitações de Recursos", + "miLicense": "&&Exibir Licença", + "miPrivacyStatement": "&&Política de Privacidade", + "miAbout": "&&Sobre", + "miRestartToUpdate": "Reinicie para Atualizar...", + "miCheckingForUpdates": "Verificando Atualizações...", + "miDownloadUpdate": "Baixar Atualização Disponível", + "miDownloadingUpdate": "Baixando Atualização...", + "miInstallingUpdate": "Instalando Atualização...", + "miCheckForUpdates": "Verificar Atualizações...", + "aboutDetail": "\\\\nVersão {0}\\\\nConfirmação {1}\\\\nData {2}\\\\nShell {3}\\\\nRenderizador {4}\\\\nNó {5}", + "okButton": "OK" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/code/electron-main/window.i18n.json b/i18n/ptb/src/vs/code/electron-main/window.i18n.json new file mode 100644 index 00000000000..abee584a9c1 --- /dev/null +++ b/i18n/ptb/src/vs/code/electron-main/window.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "hiddenMenuBar": "Você ainda pode acessar a barra de menu pressionando a tecla * * Alt * *." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/code/electron-main/windows.i18n.json b/i18n/ptb/src/vs/code/electron-main/windows.i18n.json new file mode 100644 index 00000000000..308aed29538 --- /dev/null +++ b/i18n/ptb/src/vs/code/electron-main/windows.i18n.json @@ -0,0 +1,22 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ok": "OK", + "pathNotExistTitle": "O caminho não existe", + "pathNotExistDetail": "O caminho '{0}' não parece mais existir no disco.", + "accessibilityOptionsWindowTitle": "Opções de Acessibilidade", + "reopen": "Reabrir", + "wait": "Continuar Esperando", + "close": "Fechar", + "appStalled": "A janela não está mais respondendo", + "appStalledDetail": "Você pode reabrir, fechar a janela ou continuar esperando.", + "appCrashed": "A janela foi fechada inesperadamente", + "appCrashedDetail": "Pedimos desculpas pelo inconveniente! Você pode reabrir a janela para continuar de onde parou.", + "newWindow": "Nova Janela", + "newWindowDesc": "Abrir uma nova janela", + "recentFolders": "Pastas Recentes", + "folderDesc": "{0} {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/code/node/cliProcessMain.i18n.json b/i18n/ptb/src/vs/code/node/cliProcessMain.i18n.json new file mode 100644 index 00000000000..ee0b74f6e41 --- /dev/null +++ b/i18n/ptb/src/vs/code/node/cliProcessMain.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "notFound": "Extensão '{0}' não encontrada.", + "notInstalled": "Extensão '{0}' não está instalada.", + "useId": "Certifique-se de usar a ID de extensão completa, incluindo o editor, por exemplo: {0}", + "successVsixInstall": "Extensão '{0}' foi instalada com sucesso!", + "alreadyInstalled": "Extensão '{0}' já está instalada.", + "foundExtension": "Encontrado '{0}' na loja VS Code.", + "installing": "Instalando...", + "successInstall": "Extensão '{0}' v {1} foi instalada com sucesso!", + "uninstalling": "Desinstalando {0}...", + "successUninstall": "Extensão '{0}' foi desinstalada com sucesso!" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/ptb/src/vs/editor/common/config/commonEditorConfig.i18n.json new file mode 100644 index 00000000000..8411a930363 --- /dev/null +++ b/i18n/ptb/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -0,0 +1,76 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorConfigurationTitle": "Editor", + "fontFamily": "Controla a família de fontes.", + "fontWeight": "Controla o peso da fonte.", + "fontSize": "Controla o tamanho da fonte em pixels.", + "lineHeight": "Controla a altura da linha. Use 0 para computar a altura da linha a partir do tamanho da fonte.", + "letterSpacing": "Controla o espaçamento da letra em pixels.", + "lineNumbers": "Controla a exibição de números de linha. Valores possíveis são 'on', 'off' e 'relative'. 'relative' mostra a contagem de linhas a partir da posição atual do cursor.", + "rulers": "Colunas nas quais mostrar réguas verticais", + "wordSeparators": "Caracteres que serão usados como separadores de palavras ao fazer navegação relacionada a palavras ou operações", + "tabSize": "O número de espaços equivalentes a uma tabulação. Esta configuração é sobreposta no conteúdo do arquivo quando `editor.detectIndentation` está ligado.", + "tabSize.errorMessage": "Esperado 'número'. Note que o valor \"auto\" foi alterado pela configuração 'editor.detectIndentation'.", + "insertSpaces": "Insere espaços quanto pressionado Tab. Esta configuração é sobrescrita com base no conteúdo do arquivo quando 'editor.detectIndentation' está habilitado.", + "insertSpaces.errorMessage": "Esperado 'booleano'. Note que o valor \"auto\" foi alterado pela configuração 'editor.detectIndentation'.", + "detectIndentation": "Quando um arquivo está sendo aberto, 'editor.tabSize' e 'editor.insertSpace' será detectado com base no conteúdo do arquivo.", + "roundedSelection": "Controla se as seleções têm cantos arredondados", + "scrollBeyondLastLine": "Controla se o editor rolará além da última linha", + "minimap.enabled": "Controla se o mini mapa é exibido", + "minimap.renderCharacters": "Renderizar os caracteres em uma linha (em oposição a blocos de caracteres)", + "minimap.maxColumn": "Limitar o tamanho de um mini-mapa para renderizar no máximo um número determinado de colunas", + "wordWrap.off": "As linhas nunca serão quebradas.", + "wordWrap.on": "As linhas serão quebradas na largura de visualização", + "wordWrap.wordWrapColumn": "As linhas serão quebradas em `editor.wordWrapColumn`.", + "wordWrap.bounded": "As linhas serão quebradas no mínimo entre a largura de visualização e `editor.wordWrapColumn`.", + "wordWrap": "Controla como as linhas devem ser quebradas automaticamente. Pode ser:\n- 'off' (quebra automática de linha desabilitada)\n- 'on' (quebra automática de linha na largura da janela)\n- 'wordWrapColumn' (quebra automática no numero de colunas definido em `editor.wordWrapColumn`) ou\n- 'bounded' (quebra automática em uma dimensão minima da janela e na largura configurada)", + "wordWrapColumn": "Controla a coluna de quebra de linha do editor quando editor.wordWrap` é 'wordWrapColumn' ou 'bounded'.", + "wrappingIndent": "Controla o recuo de linhas quebradas. Pode ser \"none\", \"same\" ou \"indent\".", + "mouseWheelScrollSensitivity": "Um multiplicador a ser usado em \"deltaX\" e \"deltaY\" dos eventos de rolagem do botão de rolagem do mouse", + "quickSuggestions.strings": "Habilitar sugestões rápidas dentro de strings.", + "quickSuggestions.comments": "Habilitar sugestões rápidas dentro de comentários.", + "quickSuggestions.other": "Habilitar sugestões rápidas fora de strings e comentários.", + "quickSuggestions": "Controlar se sugestões devem aparecer automaticamente ao digitar", + "quickSuggestionsDelay": "Controla o atraso em ms após o qual sugestões rápidas serão exibidas", + "parameterHints": "Habilita dicas de parâmetros", + "autoClosingBrackets": "Controla se o editor deve fechar colchetes automaticamente depois de abri-los", + "formatOnType": "Controla se o editor deve formatar automaticamente a linha após a digitação", + "formatOnPaste": "Controla se o editor deve formatar automaticamente o conteúdo colado. Um formatador deve estar disponível e o formatador deve ser capaz de formatar apenas uma parte do documento.", + "suggestOnTriggerCharacters": "Controla se as sugestões devem aparecer automaticamente ao digitar caracteres de gatilho", + "acceptSuggestionOnCommitCharacter": "Controla se as sugestões devem ser aceitas em caracteres de confirmação. Por exemplo, em JavaScript, o ponto-e-vírgula (';') pode ser um caractere de confirmação que aceita uma sugestão e digita esse caractere.", + "snippetSuggestions": "Controla se os snippets são exibidos juntamente com as outras sugestões e como eles são ordenados.", + "emptySelectionClipboard": "Controla se a cópia sem nenhuma seleção copia a linha atual.", + "wordBasedSuggestions": "Controla se o auto-completar deve ser calculado baseado nas palavras no documento.", + "suggestFontSize": "Tamanho da fonte para a ferramenta de sugestão", + "suggestLineHeight": "Altura de linha para a ferramenta de sugestão", + "selectionHighlight": "Controla se o editor deve realçar correspondências semelhantes à seleção", + "occurrencesHighlight": "Controla se o editor deve realçar ocorrências de símbolos semânticos.", + "overviewRulerLanes": "Controla o número de decorações que podem ser exibidas na mesma posição na régua de visão geral", + "overviewRulerBorder": "Controla se deve desenhar uma borda ao redor da régua de visão geral.", + "cursorBlinking": "Controla o estilo de animação do cursor, os valores possíveis são 'blink', 'smooth', 'phase', 'expand' e 'solid'", + "mouseWheelZoom": "Alterar o zoom da fonte editor quando utilizada a roda do mouse e pressionando Ctrl", + "cursorStyle": "Controla o estilo do cursor, os valores aceitos são 'block', 'block-outline', 'line', 'line-thin', 'underline' e 'underline-thin'", + "fontLigatures": "Habilita ligaduras de fontes", + "hideCursorInOverviewRuler": "Controla se o cursor deve ficar oculto na régua de visão geral.", + "renderWhitespace": "Controla como o editor deve rendenizar caracteres de espaços em branco, possibilidades são 'none', 'boundary' e 'all'. A opção 'boundary' não rendeniza espaços simples entre palavras.", + "renderControlCharacters": "Controla se o editor deve renderizar caracteres de controle", + "renderIndentGuides": "Controla se o editor deve renderizar guias de identação", + "renderLineHighlight": "Controla como o editor deve renderizar a linha atual, as possibilidades são 'none', 'gutter', 'line' e 'all'.", + "codeLens": "Controla se o editor exibirá a lente de códigos.", + "folding": "Controla se o editor tem codigo colapsível hablitado", + "showFoldingControls": "Controla se os controles de desdobramento na divisão são ocultas automaticamente.", + "matchBrackets": "Realça colchetes correspondente quando um deles estiver selecionado.", + "glyphMargin": "Controla se o editor deve renderizar a margem vertical de ícones. A margem vertical de ícones é usada primordialmente na depuração", + "useTabStops": "Inserção e deleção de espaço em branco seguem a tabulação", + "trimAutoWhitespace": "Remove espaços em branco inseridos automaticamente no fim da linha", + "stablePeek": "Mantém os editores de visualização abertos mesmo quando clicando seu conteúdo ou teclando Escape.", + "dragAndDrop": "Controla se o editor deve permitir mover seleções via arrastar e soltar.", + "sideBySide": "Controla se o editor de diff mostra as diff lado a lado ou inline.", + "ignoreTrimWhitespace": "Controla se o editor de diff mostra alterações nos espaços iniciais ou finais como diferenças", + "renderIndicators": "Controla se o editor de diff mostra indicadores +/- para alterações adicionadas/removidas", + "selectionClipboard": "Controla se a área primária de transferência Linux deve ser suportada." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/common/config/editorOptions.i18n.json b/i18n/ptb/src/vs/editor/common/config/editorOptions.i18n.json new file mode 100644 index 00000000000..40fed0886cc --- /dev/null +++ b/i18n/ptb/src/vs/editor/common/config/editorOptions.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorViewAccessibleLabel": "Conteúdo do editor" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/common/controller/cursor.i18n.json b/i18n/ptb/src/vs/editor/common/controller/cursor.i18n.json new file mode 100644 index 00000000000..60bcb5f5b5a --- /dev/null +++ b/i18n/ptb/src/vs/editor/common/controller/cursor.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "corrupt.commands": "Exceção inesperada ao executar o comando." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/common/model/textModelWithTokens.i18n.json b/i18n/ptb/src/vs/editor/common/model/textModelWithTokens.i18n.json new file mode 100644 index 00000000000..fc3574b7fde --- /dev/null +++ b/i18n/ptb/src/vs/editor/common/model/textModelWithTokens.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "mode.tokenizationSupportFailed": "O modo falhou ao gerar token da entrada." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/common/modes/modesRegistry.i18n.json b/i18n/ptb/src/vs/editor/common/modes/modesRegistry.i18n.json new file mode 100644 index 00000000000..509203220c8 --- /dev/null +++ b/i18n/ptb/src/vs/editor/common/modes/modesRegistry.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "plainText.alias": "Texto sem formatação" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/common/services/bulkEdit.i18n.json b/i18n/ptb/src/vs/editor/common/services/bulkEdit.i18n.json new file mode 100644 index 00000000000..3fada6ebf53 --- /dev/null +++ b/i18n/ptb/src/vs/editor/common/services/bulkEdit.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "conflict": "Estes arquivos foram alterados nesse meio tempo: {0}", + "summary.0": "Não foram feitas edições", + "summary.nm": "Feitas {0} edições de texto em {1} arquivos", + "summary.n0": "Feitas {0} edições de texto em um arquivo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/common/services/modeServiceImpl.i18n.json b/i18n/ptb/src/vs/editor/common/services/modeServiceImpl.i18n.json new file mode 100644 index 00000000000..85f2d2943f6 --- /dev/null +++ b/i18n/ptb/src/vs/editor/common/services/modeServiceImpl.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.languages": "Contribui às declarações de linguagem.", + "vscode.extension.contributes.languages.id": "ID da linguagem", + "vscode.extension.contributes.languages.aliases": "Aliases de nome para esta linguagem.", + "vscode.extension.contributes.languages.extensions": "Extensões de arquivos associadas a esta linguagem", + "vscode.extension.contributes.languages.filenames": "Nome dos arquivos associados a esta linguagem", + "vscode.extension.contributes.languages.filenamePatterns": "Padrão glob de nomes de arquivos associados a linguagem.", + "vscode.extension.contributes.languages.mimetypes": "Tipos Mime associados à linguagem.", + "vscode.extension.contributes.languages.firstLine": "Uma expressão regular que coincide com a primeira linha de um arquivo da linguaguem.", + "vscode.extension.contributes.languages.configuration": "Um caminho relativo para um arquivo contendo opções de configuração para a linguagem." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/common/services/modelServiceImpl.i18n.json b/i18n/ptb/src/vs/editor/common/services/modelServiceImpl.i18n.json new file mode 100644 index 00000000000..b6c528c5a25 --- /dev/null +++ b/i18n/ptb/src/vs/editor/common/services/modelServiceImpl.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "diagAndSourceMultiline": "[{0}] {1}", + "diagAndSource": "[{0}] {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/common/view/editorColorRegistry.i18n.json b/i18n/ptb/src/vs/editor/common/view/editorColorRegistry.i18n.json new file mode 100644 index 00000000000..8d59b0fcb7d --- /dev/null +++ b/i18n/ptb/src/vs/editor/common/view/editorColorRegistry.i18n.json @@ -0,0 +1,20 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "lineHighlight": "Cor de fundo para a posição do cursor na seleção de linhas.", + "lineHighlightBorderBox": "Cor de fundo para a borda em volta da linha na posição do cursor", + "rangeHighlight": "Cor de fundo dos ranges selecionados, assim como abertura instantânea e descoberta de recursos ", + "caret": "Cor do cursor no editor.", + "editorWhitespaces": "Cor dos caracteres em branco no editor", + "editorIndentGuides": "Cor das guias de indentação do editor.", + "editorLineNumbers": "Cor dos números de linha do editor.", + "editorRuler": "Cor das réguas do editor.", + "editorCodeLensForeground": "Cor do primeiro plano das lentes de código do editor", + "editorBracketMatchBackground": "Cor de fundo atrás do colchetes correspondentes", + "editorBracketMatchBorder": "Cor para as caixas de colchetes correspondentes", + "editorOverviewRulerBorder": "Cor da borda da régua de visão geral.", + "editorGutter": "Cor de fundo da separação do editor.O separador contém os glifos das margens e os números de linha." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/accessibility/browser/accessibility.i18n.json b/i18n/ptb/src/vs/editor/contrib/accessibility/browser/accessibility.i18n.json new file mode 100644 index 00000000000..e045839f7c6 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/accessibility/browser/accessibility.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "introMsg": "Obrigado por testar a opção de acessibilidade do VS Code.", + "status": "Status", + "tabFocusModeOnMsg": "Pressionando Tab no editor corrente irá mover o foco para o próximo elemento focável. Mude este comportamento ao pressionar {0}.", + "tabFocusModeOnMsgNoKb": "Pressionando Tab no editor corrente irá mover o foco para o próximo elemento focável. O comando {0} não pode ser ativado atualmente por uma tecla.", + "tabFocusModeOffMsg": "Pressionando Tab no editor atual irá inserir um caractere Tab. Mude este comportamente ao pressionar {0}.", + "tabFocusModeOffMsgNoKb": "Pressionando Tab no editor atual irá inserir um caractere Tab. O comando {0} não pode ser ativado atualmente por uma tecla.", + "outroMsg": "Você pode ignorar essa dica e retornar ao editor apertando a tecla ESC", + "ShowAccessibilityHelpAction": "Mostrar ajuda de acessibilidade" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/bracketMatching/common/bracketMatching.i18n.json b/i18n/ptb/src/vs/editor/contrib/bracketMatching/common/bracketMatching.i18n.json new file mode 100644 index 00000000000..4af1753636d --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/bracketMatching/common/bracketMatching.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "smartSelect.jumpBracket": "Ir para colchete" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/caretOperations/common/caretOperations.i18n.json b/i18n/ptb/src/vs/editor/contrib/caretOperations/common/caretOperations.i18n.json new file mode 100644 index 00000000000..157105c4a35 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/caretOperations/common/caretOperations.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "caret.moveLeft": "Mover cursor para a esquerda", + "caret.moveRight": "Mover cursor para a direita" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/caretOperations/common/transpose.i18n.json b/i18n/ptb/src/vs/editor/contrib/caretOperations/common/transpose.i18n.json new file mode 100644 index 00000000000..c1d3083b198 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/caretOperations/common/transpose.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "transposeLetters.label": "Transport letras" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/clipboard/browser/clipboard.i18n.json b/i18n/ptb/src/vs/editor/contrib/clipboard/browser/clipboard.i18n.json new file mode 100644 index 00000000000..903f9fc1086 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/clipboard/browser/clipboard.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "actions.clipboard.cutLabel": "Recortar", + "actions.clipboard.copyLabel": "Copiar", + "actions.clipboard.pasteLabel": "Colar", + "actions.clipboard.copyWithSyntaxHighlightingLabel": "Copiar com realce de sintaxe" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/comment/common/comment.i18n.json b/i18n/ptb/src/vs/editor/contrib/comment/common/comment.i18n.json new file mode 100644 index 00000000000..ff1ba569c0c --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/comment/common/comment.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "comment.line": "Alternar Comentário de Linha", + "comment.line.add": "Adicionar Comentário de Linha", + "comment.line.remove": "Remover Comentário de Linha", + "comment.block": "Alternar Comentário de Bloco" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/contextmenu/browser/contextmenu.i18n.json b/i18n/ptb/src/vs/editor/contrib/contextmenu/browser/contextmenu.i18n.json new file mode 100644 index 00000000000..e2b1d946bee --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/contextmenu/browser/contextmenu.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "action.showContextMenu.label": "Mostrar o menu de contexto do editor" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/find/browser/findWidget.i18n.json b/i18n/ptb/src/vs/editor/contrib/find/browser/findWidget.i18n.json new file mode 100644 index 00000000000..473543c0850 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/find/browser/findWidget.i18n.json @@ -0,0 +1,21 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "label.find": "Localizar", + "placeholder.find": "Localizar", + "label.previousMatchButton": "Correspondência anterior", + "label.nextMatchButton": "Próxima correspondência", + "label.toggleSelectionFind": "Localizar na seleção", + "label.closeButton": "Fechar", + "label.replace": "Substituir", + "placeholder.replace": "Substituir", + "label.replaceButton": "Substituir", + "label.replaceAllButton": "Substituir Tudo", + "label.toggleReplaceButton": "Ativar/desativar modo Substituir", + "title.matchesCountLimit": "Somente os primeiros 999 resultados são realçados, mas todas as operações de pesquisa funcionam em todo o texto.", + "label.matchesLocation": "{0} de {1}", + "label.noResults": "Nenhum resultado" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/find/common/findController.i18n.json b/i18n/ptb/src/vs/editor/contrib/find/common/findController.i18n.json new file mode 100644 index 00000000000..07397efa5fe --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/find/common/findController.i18n.json @@ -0,0 +1,19 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "startFindAction": "Localizar", + "findNextMatchAction": "Localizar Próximo", + "findPreviousMatchAction": "Localizar anterior", + "nextSelectionMatchFindAction": "Localizar Próxima Seleção", + "previousSelectionMatchFindAction": "Localizar Seleção Anterior", + "startReplace": "Substituir", + "addSelectionToNextFindMatch": "Adicionar Seleção ao Próximo Localizar Correspondência", + "addSelectionToPreviousFindMatch": "Adicionar Seleção à Correspondência de Localização Anterior", + "moveSelectionToNextFindMatch": "Mover Última Seleção para Próximo Localizar Correspondência", + "moveSelectionToPreviousFindMatch": "Mover Última Seleção para Correspondência de Localização Anterior", + "selectAllOccurencesOfFindMatch": "Selecionar Todas as Ocorrências de Localizar Correspondência", + "changeAll.label": "Alterar todas as ocorrências" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/folding/browser/folding.i18n.json b/i18n/ptb/src/vs/editor/contrib/folding/browser/folding.i18n.json new file mode 100644 index 00000000000..c9d6b88a852 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/folding/browser/folding.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "unfoldAction.label": "Abrir", + "unFoldRecursivelyAction.label": "Abrir recursivamente", + "foldAction.label": "Colapsar", + "foldRecursivelyAction.label": "Colapsar recursivamente", + "foldAllAction.label": "Colapsar tudo", + "unfoldAllAction.label": "Abrir tudo", + "foldLevelAction.label": "Nível de colapsamento {0}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/format/browser/formatActions.i18n.json b/i18n/ptb/src/vs/editor/contrib/format/browser/formatActions.i18n.json new file mode 100644 index 00000000000..4327e5f6744 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/format/browser/formatActions.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "hint11": "1 edição de formatação feita na linha {0}", + "hintn1": "{0} edições de formatação feitas na linha {1}", + "hint1n": "Feita 1 edição de formatação entre as linhas {0} e {1}", + "hintnn": "Feitas {0} edições de formatação entre as linhas {1} e {2}", + "formatDocument.label": "Formatar Documento", + "formatSelection.label": "Formatar Seleção" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/ptb/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..01753366bca --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "Não foi encontrada definição para '{0}'", + "generic.noResults": "Nenhuma definição encontrada", + "meta.title": "- {0} definições", + "actions.goToDecl.label": "Ir para Definição", + "actions.goToDeclToSide.label": "Abrir definição ao lado", + "actions.previewDecl.label": "Inspecionar definição", + "goToImplementation.noResultWord": "Nenhuma implementação encontrada para '{0}'", + "goToImplementation.generic.noResults": "Nenhuma implementação encontrada", + "meta.implementations.title": "– {0} implementações", + "actions.goToImplementation.label": "Ir para a implementação", + "actions.peekImplementation.label": "Inspecionar implementação", + "goToTypeDefinition.noResultWord": "Nenhuma definição encontrada para '{0}'", + "goToTypeDefinition.generic.noResults": "Nenhuma definição de tipo encontrada", + "meta.typeDefinitions.title": "– {0} definições de tipos", + "actions.goToTypeDefinition.label": "Ir para a definição de tipo", + "actions.peekTypeDefinition.label": "Inspecionar definição de tipo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/ptb/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..675cbe29ae1 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "Clique para mostrar {0} definições." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json b/i18n/ptb/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json new file mode 100644 index 00000000000..0ad65de8863 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "title.wo_source": "({0}/{1})", + "markerAction.next.label": "Ir para o Próximo Erro ou Aviso", + "markerAction.previous.label": "Ir para o Erro ou Aviso Anterior", + "editorMarkerNavigationError": "Ferramenta de marcação de edição apresentando error na cor ", + "editorMarkerNavigationWarning": "Ferramenta de marcação de edição apresentando adventência na cor", + "editorMarkerNavigationBackground": "Cor de fundo da ferramenta de marcação de navegação do editor." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/hover/browser/hover.i18n.json b/i18n/ptb/src/vs/editor/contrib/hover/browser/hover.i18n.json new file mode 100644 index 00000000000..196a8fb2bb0 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/hover/browser/hover.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "showHover": "Mostrar Item Flutuante" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/hover/browser/modesContentHover.i18n.json b/i18n/ptb/src/vs/editor/contrib/hover/browser/modesContentHover.i18n.json new file mode 100644 index 00000000000..2c74cf6f1ec --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/hover/browser/modesContentHover.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "modesContentHover.loading": "Carregando..." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.i18n.json b/i18n/ptb/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.i18n.json new file mode 100644 index 00000000000..fbbfbd02161 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "InPlaceReplaceAction.previous.label": "Substituir pelo valor anterior", + "InPlaceReplaceAction.next.label": "Substituir pelo próximo valor" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/indentation/common/indentation.i18n.json b/i18n/ptb/src/vs/editor/contrib/indentation/common/indentation.i18n.json new file mode 100644 index 00000000000..8edeaaf8104 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/indentation/common/indentation.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "indentationToSpaces": "Converter indentação em espaços.", + "indentationToTabs": "Coverter Indentação a Tabulações.", + "configuredTabSize": "Tamanho de Tabulação Configurado", + "selectTabWidth": "Selecione o Tamanho de Tabulação para o Arquivo Atual", + "indentUsingTabs": "Indentar Usando Tabulações", + "indentUsingSpaces": "Indentar Usando Espaços", + "detectIndentation": "Detectar Indentação a Partir do Conteúdo", + "editor.reindentlines": "Reindentar Linhas" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes.i18n.json b/i18n/ptb/src/vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes.i18n.json new file mode 100644 index 00000000000..e715c4d667f --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "inspectTMScopes": "Desenvolvedor: Inspecionar escopos TM", + "inspectTMScopesWidget.loading": "Carregando..." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/linesOperations/common/linesOperations.i18n.json b/i18n/ptb/src/vs/editor/contrib/linesOperations/common/linesOperations.i18n.json new file mode 100644 index 00000000000..8a368ab368d --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/linesOperations/common/linesOperations.i18n.json @@ -0,0 +1,25 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "lines.copyUp": "Copiar linha acima", + "lines.copyDown": "Copiar linha abaixo", + "lines.moveUp": "Mover linha para cima", + "lines.moveDown": "Mover linha para baixo", + "lines.sortAscending": "Classificar Linhas Ascendentemente", + "lines.sortDescending": "Classificar Linhas Descendentemente", + "lines.trimTrailingWhitespace": "Cortar Espaço em Branco à Direita", + "lines.delete": "Excluir linha", + "lines.indent": "Recuar linha", + "lines.outdent": "Recuar linha para a esquerda", + "lines.insertBefore": "Inserir linha acima", + "lines.insertAfter": "Inserir linha abaixo", + "lines.deleteAllLeft": "Excluir tudo à Esquerda", + "lines.deleteAllRight": "Excluir Tudo à Direita", + "lines.joinLines": "Unir Linhas", + "editor.transpose": "Transpor caracteres ao redor do cursor", + "editor.transformToUppercase": "Transformar para maiúsculas", + "editor.transformToLowercase": "Transformar para minúsculas" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/links/browser/links.i18n.json b/i18n/ptb/src/vs/editor/contrib/links/browser/links.i18n.json new file mode 100644 index 00000000000..64628273f2a --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/links/browser/links.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "links.navigate.mac": "Cmd + clique para seguir o link", + "links.navigate": "Ctrl + clique para seguir o link", + "invalid.url": "Desculpe, falha ao abrir este link porque ele não está bem formatado: {0}", + "missing.url": "Desculpe, falha ao abrir este link porque seu destino está faltando.", + "label": "Abrir link" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/multicursor/common/multicursor.i18n.json b/i18n/ptb/src/vs/editor/contrib/multicursor/common/multicursor.i18n.json new file mode 100644 index 00000000000..583be5b3e5c --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/multicursor/common/multicursor.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "mutlicursor.insertAbove": "Inserir cursor acima", + "mutlicursor.insertBelow": "Inserir cursor abaixo", + "mutlicursor.insertAtEndOfEachLineSelected": "Adicionar Cursores ao Final das Linhas" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/parameterHints/browser/parameterHints.i18n.json b/i18n/ptb/src/vs/editor/contrib/parameterHints/browser/parameterHints.i18n.json new file mode 100644 index 00000000000..f0450d3f4de --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/parameterHints/browser/parameterHints.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "parameterHints.trigger.label": "Dicas de parâmetro de gatilho" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.i18n.json b/i18n/ptb/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.i18n.json new file mode 100644 index 00000000000..0f8237adbb3 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "hint": "{0}, dica" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/quickFix/browser/quickFixCommands.i18n.json b/i18n/ptb/src/vs/editor/contrib/quickFix/browser/quickFixCommands.i18n.json new file mode 100644 index 00000000000..01ae8d7aff8 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/quickFix/browser/quickFixCommands.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickFixWithKb": "Mostrar correções ({0})", + "quickFix": "Mostrar correções", + "quickfix.trigger.label": "Correção Rápida" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.i18n.json b/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.i18n.json new file mode 100644 index 00000000000..9d557535df6 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "meta.titleReference": "- {0} referências", + "references.action.label": "Localizar Todas as Referências" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesController.i18n.json b/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesController.i18n.json new file mode 100644 index 00000000000..65217d2ace8 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesController.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "labelLoading": "Carregando..." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json b/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json new file mode 100644 index 00000000000..47c3685850e --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "aria.oneReference": "símbolo em {0} na linha {1} e coluna {2}", + "aria.fileReferences.1": "1 símbolo em {0}", + "aria.fileReferences.N": "{0} símbolos em {1}", + "aria.result.0": "Nenhum resultado encontrado", + "aria.result.1": "Encontrado 1 símbolo em {0}", + "aria.result.n1": "Encontrados {0} símbolos em {1}", + "aria.result.nm": "Encontrados {0} símbolos em {1} arquivos" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json b/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json new file mode 100644 index 00000000000..72f61eeaf83 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json @@ -0,0 +1,27 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "referencesFailre": "Falha ao resolver arquivo.", + "referencesCount": "{0} referências", + "referenceCount": "{0} referência", + "missingPreviewMessage": "nenhuma visualização disponível", + "treeAriaLabel": "Referências", + "noResults": "Nenhum resultado", + "peekView.alternateTitle": "Referências", + "peekViewTitleBackground": "Cor de fundo da área de visualização do título.", + "peekViewTitleForeground": "Cor de visualização do título.", + "peekViewTitleInfoForeground": "Cor da visualização de informações do título.", + "peekViewBorder": "Cor das bordas e seta da área de visualização", + "peekViewResultsBackground": "Cor de fundo da área de visualização da lista de resultados.", + "peekViewResultsMatchForeground": "Cor de primeiro plano para nós de linha na lista de resultados visualizados.", + "peekViewResultsFileForeground": "Cor de primeiro plano para nós de arquivos na lista de resultados visualizados.", + "peekViewResultsSelectionBackground": "Cor de fundo da entrada selecionada na visualização da lista de resultados.", + "peekViewResultsSelectionForeground": "Cor da entrada selecionada na visualização da lista de resultados.", + "peekViewEditorBackground": "Cor de fundo da visualização do editor.", + "peekViewEditorGutterBackground": "Cor de fundo da separação na visualização rápida do editor.", + "peekViewResultsMatchHighlight": "Corresponder cor de realce com visualização da lista de resultados.", + "peekViewEditorMatchHighlight": "Corresponder cor de realce com visualização do editor." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/rename/browser/rename.i18n.json b/i18n/ptb/src/vs/editor/contrib/rename/browser/rename.i18n.json new file mode 100644 index 00000000000..a56535f6241 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/rename/browser/rename.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "no result": "Nenhum resultado.", + "aria": "Renomeado '{0}' para '{1}'com sucesso. Resumo: {2}", + "rename.failed": "Desculpe, falha na execução de renomear.", + "rename.label": "Renomear Símbolo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/rename/browser/renameInputField.i18n.json b/i18n/ptb/src/vs/editor/contrib/rename/browser/renameInputField.i18n.json new file mode 100644 index 00000000000..49eba92fa44 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/rename/browser/renameInputField.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "renameAriaLabel": "Renomear entrada. Digite o novo nome e tecle Enter para gravar." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/smartSelect/common/smartSelect.i18n.json b/i18n/ptb/src/vs/editor/contrib/smartSelect/common/smartSelect.i18n.json new file mode 100644 index 00000000000..89319f9a266 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/smartSelect/common/smartSelect.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "smartSelect.grow": "Expandir seleção", + "smartSelect.shrink": "Reduzir seleção" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/suggest/browser/suggestController.i18n.json b/i18n/ptb/src/vs/editor/contrib/suggest/browser/suggestController.i18n.json new file mode 100644 index 00000000000..b064152c8be --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/suggest/browser/suggestController.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "arai.alert.snippet": "Ao aceitar '{0}' foi inserido o seguinte texto: {1}", + "suggest.trigger.label": "Sugestão de gatilho" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json b/i18n/ptb/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json new file mode 100644 index 00000000000..c9da4793d67 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json @@ -0,0 +1,21 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorSuggestWidgetBackground": "Cor de fundo para a ferramenta de sugestão.", + "editorSuggestWidgetBorder": "Cor da borda para a ferramenta de sugestão.", + "editorSuggestWidgetForeground": "Cor de primeiro plano para a ferramenta de sugestão.", + "editorSuggestWidgetSelectedBackground": "Cor de fundo da entrada selecionada da ferramenta de sugestões.", + "editorSuggestWidgetHighlightForeground": "Cor de realce da correspondência na ferramenta de sugestão.", + "readMore": "Ler Mais...{0}", + "suggestionWithDetailsAriaLabel": "{0}, sugestão, tem detalhes", + "suggestionAriaLabel": "{0}, sugestão", + "readLess": "Ler menos... {0}", + "suggestWidget.loading": "Carregando...", + "suggestWidget.noSuggestions": "Nenhuma sugestão.", + "suggestionAriaAccepted": "{0}, aceito", + "ariaCurrentSuggestionWithDetails": "{0}, sugestão, tem detalhes", + "ariaCurrentSuggestion": "{0}, sugestão" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode.i18n.json b/i18n/ptb/src/vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode.i18n.json new file mode 100644 index 00000000000..0f3dd068095 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggle.tabMovesFocus": "Alterne o uso da tecla Tab para mover o foco" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.i18n.json b/i18n/ptb/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.i18n.json new file mode 100644 index 00000000000..e8556cb38a8 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "wordHighlight": "Cor de fundo de um símbolo durante acesso de leitura, como ao ler uma variável.", + "wordHighlightStrong": "Cor de fundo de um símbolo durante acesso de escrita, como ao escrever uma variável." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.i18n.json b/i18n/ptb/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.i18n.json new file mode 100644 index 00000000000..41ad7313b7d --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "label.close": "Fechar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/electron-browser/textMate/TMSyntax.i18n.json b/i18n/ptb/src/vs/editor/electron-browser/textMate/TMSyntax.i18n.json new file mode 100644 index 00000000000..dfef3cc47a5 --- /dev/null +++ b/i18n/ptb/src/vs/editor/electron-browser/textMate/TMSyntax.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "invalid.language": "Linguagem desconhecida em `contributes.{0}.language`. Valor fornecido: {1}", + "invalid.scopeName": "Esperada uma string em 'contributes.{0}.scopeName'. Valor informado: {1}", + "invalid.path.0": "Esperada uma string em `contributes.{0}.path`. Valor informado: {1}", + "invalid.injectTo": "Valor inválido em `contributes.{0}.injectTo`. Deve ser uma matriz de nomes de escopo de idioma. Valor fornecido: {1}", + "invalid.embeddedLanguages": "Valor inválido em `contributes.{0}.embeddedLanguages`. Deve ser um objeto de mapeamento do nome do escopo para a linguagem. Valor informado: {1}", + "invalid.path.1": "É esperado que `contributes.{0}.path` ({1}) seja incluído na pasta da extensão ({2}). Isto pode tornar a extensão não portável.", + "no-tm-grammar": "Nenhuma gramática TM registrada para este idioma." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json b/i18n/ptb/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json new file mode 100644 index 00000000000..04aa2bc703f --- /dev/null +++ b/i18n/ptb/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "parseErrors": "Erros parseando {0}: {1}", + "schema.openBracket": "O colchete de abertura de caractere ou sequência de caracteres.", + "schema.closeBracket": "O colchete de fechamento de caractere ou sequência de caracteres.", + "schema.comments": "Define o símbolo dos comentários", + "schema.blockComments": "Define como comentários em bloco são marcados.", + "schema.blockComment.begin": "A sequência de caracteres que inicia um comentário em bloco.", + "schema.blockComment.end": "A sequência de caracteres que termina um comentário de bloco.", + "schema.lineComment": "A sequência de caracteres que inicia um comentário de linha.", + "schema.brackets": "Define os símbolos de colchetes que aumentam ou diminuem a indentação.", + "schema.autoClosingPairs": "Define os pares de colchetes. Quando é introduzido um colchete de abertura, o colchete de fechamento é inserido automaticamente.", + "schema.autoClosingPairs.notIn": "Define uma lista de escopos onde os auto pares são desativados.", + "schema.surroundingPairs": "Define os pares de colchetes que podem ser usados para cercar uma seqüência selecionada.", + "schema.wordPattern": "A definição da palavra para a linguagem.", + "schema.wordPattern.pattern": "O padrão RegExp usado para coincidir com as palavras.", + "schema.wordPattern.flags": "Os sinalizadores RegExp usados para coincidir com as palavras.", + "schema.wordPattern.flags.errorMessage": "Deve corresponder ao padrão `/^([gimuy]+)$/`." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/node/textMate/TMGrammars.i18n.json b/i18n/ptb/src/vs/editor/node/textMate/TMGrammars.i18n.json new file mode 100644 index 00000000000..7707ea3401f --- /dev/null +++ b/i18n/ptb/src/vs/editor/node/textMate/TMGrammars.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.grammars": "Contibui aos toquenizadores textmate", + "vscode.extension.contributes.grammars.language": "Identificador da linguagem para qual a sintaxe contribui.", + "vscode.extension.contributes.grammars.scopeName": "Nome do escopo Textmate usado pelo arquivo tmLanguage.", + "vscode.extension.contributes.grammars.path": "Caminho para o arquivo tmLanguage. O caminho é relativo a pasta da extensão e geralmente começa com './syntaxes/'.", + "vscode.extension.contributes.grammars.embeddedLanguages": "Um mapeamento no nome do escopo para o Id da linguagem se esta gramática contenha linguagens embutidas.", + "vscode.extension.contributes.grammars.injectTo": "Lista de nomes de escopos de linguagem aos quais esta gramática é injetada." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/actions/browser/menuItemActionItem.i18n.json b/i18n/ptb/src/vs/platform/actions/browser/menuItemActionItem.i18n.json new file mode 100644 index 00000000000..e64a7d0ed09 --- /dev/null +++ b/i18n/ptb/src/vs/platform/actions/browser/menuItemActionItem.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "titleAndKb": "{0} ({1})" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json b/i18n/ptb/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json new file mode 100644 index 00000000000..a8ef6175a09 --- /dev/null +++ b/i18n/ptb/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json @@ -0,0 +1,41 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "requirearray": "os itens de menu devem ser um array", + "requirestring": "a propriedade `{0}` é obrigatória e deve ser do tipo `string`", + "optstring": "a propriedade `{0}` é opcional ou deve ser do tipo `string`", + "vscode.extension.contributes.menuItem.command": "Identificador do comando para ser executado. O comando deve ser declarado na seção de 'Comandos'", + "vscode.extension.contributes.menuItem.alt": "O identificador de um comando alternativo para executar. O comando deve ser declarado na sessão 'Comandos'", + "vscode.extension.contributes.menuItem.when": "Condição, que deve ser verdadeira, para mostrar esse item", + "vscode.extension.contributes.menuItem.group": "Grupo ao qual pertence este comando", + "vscode.extension.contributes.menus": "Contribui itens de menu ao editor", + "menus.commandPalette": "Paleta de comandos", + "menus.editorTitle": "Meno do título editor", + "menus.editorContext": "Mostrar o menu de contexto do editor", + "menus.explorerContext": "Menu no contexto de explorador de arquivos", + "menus.editorTabContext": "Mostrar o menu de contexto do editor", + "menus.debugCallstackContext": "O menu de contexto de pilha de chamadas de depuração", + "menus.scmTitle": "O menu de título do controle de fonte", + "menus.resourceGroupContext": "O menu de contexto do grupo de recursos de controle de fonte", + "menus.resourceStateContext": "O menu de contexto de estado de recursos do controle de fonte", + "nonempty": "Esperado um valor não vazio", + "opticon": "a propriedade '{0}' é opcional ou pode ser do tipo 'string'", + "requireStringOrObject": "a propriedade '{0}' é obrigatória e deve ser do tipo 'string'", + "requirestrings": "a propriedade `{0}` é obrigatória e deve ser do tipo `string`", + "vscode.extension.contributes.commandType.command": "Indentificador de comando para executar", + "vscode.extension.contributes.commandType.title": "Título para o qual o comando é representado na UI", + "vscode.extension.contributes.commandType.category": "(Opcional) Sequência de categoria será agrupada na interface de usuário", + "vscode.extension.contributes.commandType.icon": "(Opcional) Icone utilizado para representar o comando na interface de usuário. Um arquivo ou configuração do tema.", + "vscode.extension.contributes.commandType.icon.light": "Caminho do Ãcone quando o tema light for utilizado", + "vscode.extension.contributes.commandType.icon.dark": "Caminho do ícone quando o tema dark for utilizado", + "vscode.extension.contributes.commands": "Contribui comandos à paleta de comandos", + "dup": "Comando '{0}' aparece multiplas vezes na sessão 'comandos'\n", + "menuId.invalid": "'{0}' nao é um identificador de menu válido ", + "missing.command": "Identificador do comando para ser executado. O comando deve ser declarado na seção de 'Comandos'", + "missing.altCommand": "Referências ao item de menu no alt-command '{0}' qual nao é definido na sessão 'comandos'", + "dupe.command": "Itens de referencias do mesmo comando como padrão e alt-command", + "nosupport.altCommand": "Desculpe, mas atualmente somente o groupo 'navegação' do menu 'editor/título' suporta alt-commands" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/configuration/common/configurationRegistry.i18n.json b/i18n/ptb/src/vs/platform/configuration/common/configurationRegistry.i18n.json new file mode 100644 index 00000000000..928f36b2ee4 --- /dev/null +++ b/i18n/ptb/src/vs/platform/configuration/common/configurationRegistry.i18n.json @@ -0,0 +1,19 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defaultConfigurations.title": "Sobreposições da Configuração Padrão", + "overrideSettings.description": "Definir que configurações do editor sejam substituídas para idioma {0}.", + "overrideSettings.defaultDescription": "Definir que configurações do editor sejam substituídas para um idioma.", + "vscode.extension.contributes.configuration": "Contribui às definições de configuração.", + "vscode.extension.contributes.configuration.title": "Um resumo das configurações. Este rótulo será usado no arquivo de configurações como um comentário de separação.", + "vscode.extension.contributes.configuration.properties": "Descrição das propriedades de configuração.", + "config.property.languageDefault": "Não é possível registrar '{0}'. Isto corresponde a propriedade padrão '\\\\[.*\\\\]$' para descrever configurações do editor específico de linguagem. Use a contribuição 'configurationDefaults'.", + "config.property.duplicate": "Não é possível registrar '{0}'. Esta propriedade já está registrada.", + "invalid.properties": "'configuration.properties' deve ser um objeto", + "invalid.type": "Se definido, 'configuration.type' deve ser do tipo 'object'", + "invalid.title": "'configuration.title' deve ser um string", + "vscode.extension.contributes.defaultConfiguration": "Contribui às definições de configuração padrão do editor por linguagem." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/environment/node/argv.i18n.json b/i18n/ptb/src/vs/platform/environment/node/argv.i18n.json new file mode 100644 index 00000000000..4cec19113d2 --- /dev/null +++ b/i18n/ptb/src/vs/platform/environment/node/argv.i18n.json @@ -0,0 +1,32 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "gotoValidation": "Argumentos no modo '--goto' deve ser no formato de 'Arquivo(:LINHA(:CARACTERE))'.", + "diff": "Abrir um editor de diff. Requer passar dois caminhos de arquivo como argumentos.", + "goto": "Abra o arquivo no caminho, na linha e caractere (addcionar:linha[:caractere] para o caminho).", + "locale": "Para localização utilize (ex. en-US ou zh-TW).", + "newWindow": "Força uma nova instância do Código.", + "performance": "Comece com o 'Desenvolvedor: Desempenho de inicialização' comando habilitado.", + "prof-startup": "Rodar o CPU profiler durante a inicialização", + "reuseWindow": "Forçar a abertura de um arquivo ou pasta na última janela ativa", + "userDataDir": "Especifica o diretório que os dados do usuário serão mantidos, útil quando estiver rodando como root.", + "verbose": "Imprimir a saída detalhada (Implica -- esperar).", + "wait": "Aguarde a janela ser fechada antes de retornar.", + "extensionHomePath": "Defina o caminho raíz para as extensões.", + "listExtensions": "Lista de extensões instaladas", + "showVersions": "Exibir versões de extensões instaladas, quando estiver usando --list-extension", + "installExtension": "Instala uma extensão.", + "uninstallExtension": "Desinstala uma extensão.", + "experimentalApis": "Permite recursos de api propostos para uma extensão.", + "disableExtensions": "Desabilita todas as extensões instaladas.", + "disableGPU": "Desabilita aceleração de hardware da GPU.", + "version": "Versão de impressão", + "help": "Uso de impressão.", + "usage": "Uso", + "options": "opções", + "paths": "caminhos", + "optionsUpperCase": "Opções" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/extensionManagement/common/extensionEnablementService.i18n.json b/i18n/ptb/src/vs/platform/extensionManagement/common/extensionEnablementService.i18n.json new file mode 100644 index 00000000000..52f37b66ccd --- /dev/null +++ b/i18n/ptb/src/vs/platform/extensionManagement/common/extensionEnablementService.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noWorkspace": "Não há espaço de trabalho." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/extensionManagement/common/extensionManagement.i18n.json b/i18n/ptb/src/vs/platform/extensionManagement/common/extensionManagement.i18n.json new file mode 100644 index 00000000000..33ea8261326 --- /dev/null +++ b/i18n/ptb/src/vs/platform/extensionManagement/common/extensionManagement.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "extensions": "Extensões", + "preferences": "Preferências" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/extensionManagement/node/extensionGalleryService.i18n.json b/i18n/ptb/src/vs/platform/extensionManagement/node/extensionGalleryService.i18n.json new file mode 100644 index 00000000000..76dc4cf48f3 --- /dev/null +++ b/i18n/ptb/src/vs/platform/extensionManagement/node/extensionGalleryService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "notFound": "Extensão não encontrada", + "noCompatible": "Não foi possível econtrar uma versão de {0} com esta versão do Code." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/extensionManagement/node/extensionManagementService.i18n.json b/i18n/ptb/src/vs/platform/extensionManagement/node/extensionManagementService.i18n.json new file mode 100644 index 00000000000..a6c5a37ab05 --- /dev/null +++ b/i18n/ptb/src/vs/platform/extensionManagement/node/extensionManagementService.i18n.json @@ -0,0 +1,22 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "invalidManifest": "Extensão inválida: pacote.json nao é um arquivo JSON válido", + "restartCode": "Por favor reinicie Code antes de reinstalar {0}.", + "installDependeciesConfirmation": "A instalação de '{0}' também inclui suas dependências. Gostaria de continuar?", + "install": "Sim", + "doNotInstall": "Não", + "uninstallDependeciesConfirmation": "Gostaria de desinstalar '{0}' somente, ou suas dependências também?", + "uninstallOnly": "Apenas", + "uninstallAll": "Todos", + "cancel": "Cancelar", + "uninstallConfirmation": "Tem certeza que deseja desinstalar '{0}'?", + "ok": "OK", + "singleDependentError": "Não foi possível desinstalar a extensão '{0}'. A extensão '{1}' depende dela.", + "twoDependentsError": "Não foi possível desinstalar a extensão '{0}'. As extensões '{1}' e '{2}' dependem dela.", + "multipleDependentsError": "Não foi possível desinstalar a extensão '{0}'. As extensões '{1}' e '{2}' e outras dependem dela.", + "notExists": "Não foi possível encontrar a extensão" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/extensions/common/abstractExtensionService.i18n.json b/i18n/ptb/src/vs/platform/extensions/common/abstractExtensionService.i18n.json new file mode 100644 index 00000000000..d521fce97ff --- /dev/null +++ b/i18n/ptb/src/vs/platform/extensions/common/abstractExtensionService.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "unknownDep": "Extensão '{1}' falhou ao ativar. Motivo: dependência desconhecida '{0}'.", + "failedDep1": "Extensão '{1}' falhou ao ativar. Motivo: a dependência '{0}' falhou ao ativar.", + "failedDep2": "Extensão '{0}' falhou ao ativar. Motivo: mais de 10 níveis de dependências (provavelmente um laço de dependência).", + "activationError": "Ativação da extensão `{0}` falhou: {1}." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/extensions/common/extensionsRegistry.i18n.json b/i18n/ptb/src/vs/platform/extensions/common/extensionsRegistry.i18n.json new file mode 100644 index 00000000000..649e13b03b1 --- /dev/null +++ b/i18n/ptb/src/vs/platform/extensions/common/extensionsRegistry.i18n.json @@ -0,0 +1,24 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.engines.vscode": "Para extensões do VS Code, especifica a versão do VS Code que a extensão é compatível. Não pode ser *. Por exemplo: ^0.10.5 indica compatibilidade com uma versão mínima de 0.10.5 para o VS Code.", + "vscode.extension.publisher": "O editor da extensão do VS Code.", + "vscode.extension.displayName": "O nome de exibição para a extensão do VS Code.", + "vscode.extension.categories": "As categorias usadas pela galeria do VS Code para categorizar a extensão.", + "vscode.extension.galleryBanner": "Banner usado na loja VS Code.", + "vscode.extension.galleryBanner.color": "A cor do banner usado no cabeçalho de página da loja VS Code.", + "vscode.extension.galleryBanner.theme": "A cor do tema usada para o fonte usado no banner.", + "vscode.extension.contributes": "Todas as contribuições da extensão VS Code representadas por este pacote.", + "vscode.extension.preview": "Configura a extensão para ser marcada como pré-visualização na Loja.", + "vscode.extension.activationEvents": "Eventos de ativação para a extensão VS Code.", + "vscode.extension.badges": "Matriz de emblemas a mostrar na barra lateral da página da extensão na Loja.", + "vscode.extension.badges.url": "URL da imagem do emblema.", + "vscode.extension.badges.href": "Link do emblema.", + "vscode.extension.badges.description": "Descrição do emblema.", + "vscode.extension.extensionDependencies": "Dependências para outras extensões. O identificador de uma extensão sempre é ${publisher}. ${nome}. Por exemplo: vscode.csharp.", + "vscode.extension.scripts.prepublish": "Script a ser executado antes do pacote ser publicado como uma extensão VS Code.", + "vscode.extension.icon": "O caminho para um ícone de 128x128 pixels." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/extensions/node/extensionValidator.i18n.json b/i18n/ptb/src/vs/platform/extensions/node/extensionValidator.i18n.json new file mode 100644 index 00000000000..fe37dd1820f --- /dev/null +++ b/i18n/ptb/src/vs/platform/extensions/node/extensionValidator.i18n.json @@ -0,0 +1,24 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "versionSyntax": "Não foi possível analisar o valor de 'engines.vscode' {0}. Por favor, utilize, por exemplo: ^ 0.10.0, ^ 1.2.3, ^ 0.11.0, ^ 0.10.x, etc.", + "versionSpecificity1": "Versão especificada em 'engines.vscode' ({0}) não é específica o suficiente. Para versões do vscode anteriores a 1.0.0, por favor defina no mínimo a versão principal e secundária desejada. Por exemplo, ^ 0.10.0, 0.10.x, 0.11.0, etc.", + "versionSpecificity2": "Versão especificada em 'engines.vscode' ({0}) não é específica o suficiente. Para as versões do vscode posteriores a 1.0.0, por favor defina no mínimo a versão principal do desejado. Por exemplo, ^ 1.10.0, 1.10.x 1. XX, 2.x.x, etc.", + "versionMismatch": "Extensão não é compatível com Code {0}. A extensão requer: {1}.", + "extensionDescription.empty": "Descrição de extensão vazia obtida", + "extensionDescription.publisher": "a propriedade `{0}` é obrigatória e deve ser do tipo `string`", + "extensionDescription.name": "a propriedade `{0}` é obrigatória e deve ser do tipo `string`", + "extensionDescription.version": "a propriedade `{0}` é obrigatória e deve ser do tipo `string`", + "extensionDescription.engines": "a propriedade `{0}` é obrigatória e deve ser do tipo `object`", + "extensionDescription.engines.vscode": "a propriedade `{0}` é obrigatória e deve ser do tipo `string`", + "extensionDescription.extensionDependencies": "a propriedade `{0}` pode ser omitida ou deve ser do tipo `string[]`", + "extensionDescription.activationEvents1": "a propriedade `{0}` pode ser omitida ou deve ser do tipo `string[]`", + "extensionDescription.activationEvents2": "Propriedades '{0}' e '{1}' devem ser especificadas ou devem ambas ser omitidas", + "extensionDescription.main1": "a propriedade `{0}` é opcional ou pode ser do tipo `string`", + "extensionDescription.main2": "Esperado 'main' ({0}) ser incluído dentro da pasta da extensão ({1}). Isto pode fazer a extensão não-portável.", + "extensionDescription.main3": "propriedades '{0}' e '{1}' devem ser especificadas ou devem ambas ser omitidas", + "notSemver": "Versão da extensão não é compatível a semver" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/integrity/node/integrityServiceImpl.i18n.json b/i18n/ptb/src/vs/platform/integrity/node/integrityServiceImpl.i18n.json new file mode 100644 index 00000000000..d252527ac15 --- /dev/null +++ b/i18n/ptb/src/vs/platform/integrity/node/integrityServiceImpl.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "integrity.ok": "OK", + "integrity.dontShowAgain": "Não mostrar novamente", + "integrity.moreInfo": "Mais informações", + "integrity.prompt": "Sua instalação de {0} parece estar corrompida. Favor reinstalar." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/jsonschemas/common/jsonValidationExtensionPoint.i18n.json b/i18n/ptb/src/vs/platform/jsonschemas/common/jsonValidationExtensionPoint.i18n.json new file mode 100644 index 00000000000..47ff1ba6bad --- /dev/null +++ b/i18n/ptb/src/vs/platform/jsonschemas/common/jsonValidationExtensionPoint.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "contributes.jsonValidation": "Contribui à configuração do schema json.", + "contributes.jsonValidation.fileMatch": "O padrão de arquivo a corresponder, por exemplo \"package.json\" ou \"*.launch\".", + "contributes.jsonValidation.url": "Um esquema de URL ('http:', 'https:') ou caminho relativo à pasta de extensão('./').", + "invalid.jsonValidation": "'configuration.jsonValidation' deve ser uma matriz", + "invalid.fileMatch": "'configuration.jsonValidation.fileMatch' deve ser definido", + "invalid.url": "'configuration.jsonValidation.url' deve ser uma URL ou caminho relativo", + "invalid.url.fileschema": "'configuration.jsonValidation.url' é uma URL relativa inválida: {0}", + "invalid.url.schema": "'configuration.jsonValidation.url' deve começar com ' http:', ' https: 'ou'. /' para os esquemas de referência localizados na extensão" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/keybinding/common/abstractKeybindingService.i18n.json b/i18n/ptb/src/vs/platform/keybinding/common/abstractKeybindingService.i18n.json new file mode 100644 index 00000000000..59961c4476a --- /dev/null +++ b/i18n/ptb/src/vs/platform/keybinding/common/abstractKeybindingService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "first.chord": "({0}) foi pressionado. Aguardando segunda tecla de pressionamento simultâneo...", + "missing.chord": "A combinação de chave ({0}, {1}) não é um comando." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/keybinding/common/keybindingLabels.i18n.json b/i18n/ptb/src/vs/platform/keybinding/common/keybindingLabels.i18n.json new file mode 100644 index 00000000000..bf2baf83906 --- /dev/null +++ b/i18n/ptb/src/vs/platform/keybinding/common/keybindingLabels.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ctrlKey": "Ctrl", + "shiftKey": "Shift", + "altKey": "Alt", + "windowsKey": "Windows", + "ctrlKey.long": "Controle", + "shiftKey.long": "Shift", + "altKey.long": "Alt", + "cmdKey.long": "Comando", + "windowsKey.long": "Windows" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/markers/common/problemMatcher.i18n.json b/i18n/ptb/src/vs/platform/markers/common/problemMatcher.i18n.json new file mode 100644 index 00000000000..29df9e58b2b --- /dev/null +++ b/i18n/ptb/src/vs/platform/markers/common/problemMatcher.i18n.json @@ -0,0 +1,61 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ProblemPatternParser.loopProperty.notLast": "A propriedade loop só é suportada na última linha correspondente.", + "ProblemPatternParser.problemPattern.missingRegExp": "Está faltando uma expressão regular a problema padrão.", + "ProblemPatternParser.problemPattern.missingProperty": "O problema padrão é inválido. Ele deve ter ao menos um arquivo, mensagem e linha ou local de grupo de correspondência.", + "ProblemPatternParser.invalidRegexp": "Erro: a cadeia de caracteres {0} não é uma expressão regular válida.\n", + "ProblemPatternSchema.regexp": "A expressão regular para procurar um erro, aviso ou informação na saída.", + "ProblemPatternSchema.file": "O índice do grupo de correspondência do arquivo. Se omitido, será usado 1.", + "ProblemPatternSchema.location": "O índice de grupo de correspondência da localização do problema. Padrões de localização válidos são: (linha), (linha, coluna) e (startLine, startColumn, endLine, endColumn). Se omitido (linha, coluna) é assumido.", + "ProblemPatternSchema.line": "O índice de grupo de correspondência da linha do problema. O padrão é 2", + "ProblemPatternSchema.column": "O índice de grupo de correspondência de caractere da linha do problema. O padrão é 3", + "ProblemPatternSchema.endLine": "O índice de grupo de correspondência de linha final do problema. O padrão é indefinido", + "ProblemPatternSchema.endColumn": "O índice de grupo de correspondência de caráter final de linha do problema. O padrão é indefinido", + "ProblemPatternSchema.severity": "O índice de grupo de correspondência da gravidade do problema. O padrão é indefinido", + "ProblemPatternSchema.code": "O índice de grupo de correspondência do código do problema. O padrão é indefinido", + "ProblemPatternSchema.message": "O índice de grupo de correspondência da mensagem. Se omitido o padrão é 4 se o local for especificado. Caso contrário o padrão é 5.", + "ProblemPatternSchema.loop": "Em um loop de correspondência multi linha indica se este padrão é executado em um loop enquanto houver correspondências. Somente pode ser especificado no último padrão em um padrão de linha múltiplas.", + "NamedProblemPatternSchema.name": "O nome do modelo de problema.", + "NamedMultiLineProblemPatternSchema.name": "O nome do modelo de problema multi-linhas.", + "NamedMultiLineProblemPatternSchema.patterns": "Os padrões atuais.", + "ProblemPatternExtPoint": "Contribui aos modelos de problema", + "ProblemPatternRegistry.error": "Modelo de problema inválido. O modelo será ignorado.", + "ProblemMatcherParser.noProblemMatcher": "Erro: a descrição não pode ser convertida em uma correspondência de problema:\n{0}\n\n", + "ProblemMatcherParser.noProblemPattern": "Erro: a descrição nao define um padrão de problema válido: {0}\n", + "ProblemMatcherParser.noOwner": "Erro: a descriçao não define um proprietário:\n{0}\n", + "ProblemMatcherParser.noFileLocation": "Erro: a descrição não define uma localização de arquivo:\n{0}\n", + "ProblemMatcherParser.unknownSeverity": "Info: severidade {0} desconhecida. Valores válidos são erro, aviso e info.\n", + "ProblemMatcherParser.noDefinedPatter": "Erro: o padrão com o identificador {0} não existe.", + "ProblemMatcherParser.noIdentifier": "Erro: a propriedade padrão se refere a um identificador vazio.", + "ProblemMatcherParser.noValidIdentifier": "Erro: a propriedade padrão {0} não é uma variável de padrões válida.", + "ProblemMatcherParser.problemPattern.watchingMatcher": "Um problema de correspondência deve obrigatoriamente definir padrão inicial e um padrão final para monitoramento.", + "ProblemMatcherParser.invalidRegexp": "Erro: a cadeia de caracteres {0} não é uma expressão regular válida.\n", + "WatchingPatternSchema.regexp": "A expressão regular para detectar o início ou o fim de uma tarefa em segundo plano.", + "WatchingPatternSchema.file": "O índice do grupo de correspondência do arquivo. Pode ser omitido.", + "PatternTypeSchema.name": "O nome de um padrão pré-definido ou contribuído.", + "PatternTypeSchema.description": "Um padrão de problema ou o nome de um padrão de problema pré-definido ou contribuído. Pode ser omitido se base for especificada.", + "ProblemMatcherSchema.base": "O nome de uma correspondência de problema base a ser utilizado.", + "ProblemMatcherSchema.owner": "O proprietário de um problema dentro do código. Pode ser omitido se base for especificada. Default para 'externo' se omitido e base não for especificada.", + "ProblemMatcherSchema.severity": "A severidade padrão para captura de problemas. É utilizada se o padrão não definir um grupo correspondente para severidade.", + "ProblemMatcherSchema.applyTo": "Controla se um problema reportado em um documento de texto é aplicado somente para aberto, fechado ou todos os documentos.", + "ProblemMatcherSchema.fileLocation": "Define como os nomes de arquivos reportados em um padrão de problema devem ser interpretados.", + "ProblemMatcherSchema.background": "Padrões para monitorar o início e o término de um pesquisador ativo em uma tarefa em segundo plano.", + "ProblemMatcherSchema.background.activeOnStart": "Se configurado para verdadeiro, o monitor em segundo plano está em modo ativo quando a tarefa inicia. Isto é igual a emissão de uma linha que corresponde ao beginPattern", + "ProblemMatcherSchema.background.beginsPattern": "Se houver correspondência na saída o início de uma tarefa em segundo plano é sinalizada.", + "ProblemMatcherSchema.background.endsPattern": "Se houver correspondência na saída o final de uma tarefa em segundo plano é sinalizada.", + "ProblemMatcherSchema.watching.deprecated": "A propriedade watching foi descontinuada. Use background no lugar dela.", + "ProblemMatcherSchema.watching": "Padrões para monitorar o início e o término de um pesquisador observando.", + "ProblemMatcherSchema.watching.activeOnStart": "Se configurado para verdadeiro, o monitoramento está em modo ativo quando a tarefa inicia. Isto é igual a emissão de uma linha que corresponde ao beginPattern", + "ProblemMatcherSchema.watching.beginsPattern": "Se houver correspondência na saída o início de uma tarefa observada é sinalizada.", + "ProblemMatcherSchema.watching.endsPattern": "Se houver correspondência na saída o final de uma tarefa observada é sinalizada.", + "LegacyProblemMatcherSchema.watchedBegin.deprecated": "Esta propriedade está descontinuada. Ao invés, use a propriedade de observação.", + "LegacyProblemMatcherSchema.watchedBegin": "Uma expressão regular sinalizando que uma tarefa observada é ativada através da observação.", + "LegacyProblemMatcherSchema.watchedEnd.deprecated": "Esta propriedade está descontinuada. Ao invés, use a propriedade de observação.", + "LegacyProblemMatcherSchema.watchedEnd": "Uma expressão regular sinalizando que uma tarefa observada terminou a execução.", + "NamedProblemMatcherSchema.name": "O nome do correspondente do problema.", + "ProblemMatcherExtPoint": "Contribui aos correspondentes de problema" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/message/common/message.i18n.json b/i18n/ptb/src/vs/platform/message/common/message.i18n.json new file mode 100644 index 00000000000..620c63edd07 --- /dev/null +++ b/i18n/ptb/src/vs/platform/message/common/message.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "close": "Fechar", + "later": "Mais tarde", + "cancel": "Cancelar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/request/node/request.i18n.json b/i18n/ptb/src/vs/platform/request/node/request.i18n.json new file mode 100644 index 00000000000..1f7fd75e5aa --- /dev/null +++ b/i18n/ptb/src/vs/platform/request/node/request.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "httpConfigurationTitle": "HTTP", + "proxy": "As configurações de proxy a usar. Se não forem configuradas, serão obtidas das variáveis de ambiente http_proxy e https_proxy", + "strictSSL": "Se o certificado do servidor de proxy deve ser verificado contra a lista de autoridades de certificação fornecida.", + "proxyAuthorization": "O valor para enviar como o cabeçalho de 'autorização Proxy' para cada solicitação de rede." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/telemetry/common/telemetryService.i18n.json b/i18n/ptb/src/vs/platform/telemetry/common/telemetryService.i18n.json new file mode 100644 index 00000000000..a1d67b82fb7 --- /dev/null +++ b/i18n/ptb/src/vs/platform/telemetry/common/telemetryService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "telemetryConfigurationTitle": "Telemetria", + "telemetry.enableTelemetry": "Permitir que os dados de uso e erros sejam enviados à Microsoft." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/ptb/src/vs/platform/theme/common/colorRegistry.i18n.json new file mode 100644 index 00000000000..64d68304f98 --- /dev/null +++ b/i18n/ptb/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -0,0 +1,78 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "invalid.color": "Formato inválido de cor. Use #RGB, #RGBA, #RRGGBB ou #RRGGBBAA", + "schema.colors": "Cores usadas no workbench.", + "foreground": "Cor de primeiro plano geral. Essa cor é só usada se não for substituída por um componente.", + "errorForeground": "Cor de primeiro plano geral para mensagens de erro. Essa cor é só usada se não for substituída por um componente.", + "descriptionForeground": "Cor de primeiro plano para a descrição do texto provendo informação adicional, por exemplo para uma etiqueta.", + "focusBorder": "Cor geral da borda para elementos focalizados. Essa cor é usada somente se não for substituída por um componente.", + "contrastBorder": "Uma borda extra em torno de elementos para separá-los dos outros de maior contraste.", + "activeContrastBorder": "Uma borda extra em torno de elementos ativos para separá-los dos outros de maior contraste.", + "selectionBackground": "A cor de fundo das seleções de texto na bancada de trabalho (por exemplo, para campos de entrada ou áreas de texto). Note que isto não se aplica a seleções dentro do editor e do terminal.", + "textSeparatorForeground": "Cor para separadores de texto.", + "textLinkForeground": "Cor de primeiro plano para links no texto.", + "textLinkActiveForeground": "Cor de primeiro plano para links ativos no texto.", + "textPreformatForeground": "Cor de primeiro plano para segmentos de texto pré-formatados.", + "textBlockQuoteBackground": "Cor de fundo para blocos de citações no texto.", + "textBlockQuoteBorder": "Cor da borda para blocos de citações no texto.", + "textCodeBlockBackground": "Cor de fundo para blocos de código no texto.", + "widgetShadow": "Cor de sombra ferramentas como localizar/substituir dentro do editor.", + "inputBoxBackground": "Cor de fundo da caixa de entrada.", + "inputBoxForeground": "Cor de primeiro plano da caixa de entrada.", + "inputBoxBorder": "Borda da caixa de entrada.", + "inputBoxActiveOptionBorder": "Cor da borda das opções ativas em campos de entrada.", + "inputPlaceholderForeground": "Cor de primeiro plano da caixa de entrada para o texto de espaço reservado.", + "inputValidationInfoBackground": "Cor de fundo de validação de entrada para a severidade de informações.", + "inputValidationInfoBorder": "Cor da borda de validação de entrada para a severidade de informações.", + "inputValidationWarningBackground": "Cor de fundo de validação de entrada para avisos.", + "inputValidationWarningBorder": "Cor da borda de validação para a severidade de avisos.", + "inputValidationErrorBackground": "Cor de fundo de validação de entrada para a severidade do erro.", + "inputValidationErrorBorder": "Cor da borda de validação de entrada para a severidade do erro.", + "dropdownBackground": "Cor de fundo do menu suspenso.", + "dropdownForeground": "Cor de primeiro plano do menu suspenso.", + "dropdownBorder": "Borda do menu suspenso.", + "listFocusBackground": "Cor de fundo para o item focalizado de Lista/árvore quando a lista/árvore está ativa. Uma árvore/lista de ativa tem o foco do teclado, uma inativa não.", + "listFocusForeground": "Cor de fundo da Lista/árvore para o item focalizado quando a lista/árvore está ativa. Uma árvore/lista ativa tem o foco do teclado, uma inativa não.", + "listActiveSelectionBackground": "Cor de fundo para o item selecionado de Lista/árvore quando a lista/árvore está ativa. Uma lista/árvore ativa tem o foco do teclado, uma inativa não.", + "listActiveSelectionForeground": "Cor de primeiro plano para o item selecionado de Lista/árvore quando a lista/árvore está ativa. Uma lista/árvore ativa tem o foco do teclado, uma inativa não.", + "listInactiveSelectionBackground": "Cor de fundo para o item selecionado de Lista/árvore quando a lista/árvore está inativa. Uma lista/árvore ativa tem o foco do teclado, uma inativa não.", + "listInactiveSelectionForeground": "Cor de primeiro plano para Lista/árvore para o item selecionado quando a lista/árvore está inativa. Uma árvore/lista ativa tem o foco do teclado, um inativo não.", + "listHoverBackground": "Cor de fundo de Lista/árvore quando pairando sobre itens usando o mouse.", + "listHoverForeground": "Primeiro plano da Lista/Ãrvoce quando passar sobre itens usando o mouse.", + "listDropBackground": "Cor de fundo ao arrastar e soltar de Lista/árvore quando movendo itens usando o mouse.", + "highlight": "Cor de primeiro plano de Lista/árvore de destaques de correspondências ao pesquisar na árvore/lista.", + "pickerGroupForeground": "Seletor rápido de cor para rótulos de agrupamento.", + "pickerGroupBorder": "Seletor rápido de cor para bordas de agrupamentos.", + "buttonForeground": "Cor de primeiro plano do botão.", + "buttonBackground": "Cor de fundo do botão.", + "buttonHoverBackground": "Cor de fundo de botão quando flutuar sobre ele.", + "badgeBackground": "Cor de fundo do distintivo. Distintivos são rótulos de pequenas informações, por exemplo, para a contagem de resultados de pesquisa.", + "badgeForeground": "Cor de primeiro plano do distintivo. Distintivos são rótulos de pequenas informações, por exemplo, para a contagem de resultados de pesquisa.", + "scrollbarShadow": "Sombra da barra de rolagem para indicar que a visualização está sendo rolada.", + "scrollbarSliderBackground": "Cor de fundo do controle deslizante.", + "scrollbarSliderHoverBackground": "Cor de fundo de controle deslizante quando estiver flutuando sobre ele.", + "scrollbarSliderActiveBackground": "Cor de fundo de controle deslizante quando ativo.", + "progressBarBackground": "Cor de fundo da barra de progresso que pode ser mostrada em operações de execução demorada.", + "editorBackground": "Cor de plano de fundo do editor.", + "editorForeground": "Cor de primeiro plano padrão do editor.", + "editorWidgetBackground": "Cor de plano de fundo das ferramentas de edição, como pesquisar/substituir.", + "editorWidgetBorder": "Cor da borda da ferramenta editor.", + "editorSelection": "Cor de seleção do editor.", + "editorInactiveSelection": "Cor de seleção em um editor inativo.", + "editorSelectionHighlight": "Cor de regiões com o mesmo conteúdo da seleção.", + "editorFindMatch": "Cor da correspondência de pesquisa atual.", + "findMatchHighlight": "Cor dos outros resultados de pesquisa.", + "findRangeHighlight": "Cor da faixa que limita a pesquisa.", + "hoverHighlight": "Realçar abaixo da palavra onde é mostrado item flutuante", + "hoverBackground": "Cor de fundo para o item flutuante do editor", + "hoverBorder": "Cor da borda para o item flutuante do editor.", + "activeLinkForeground": "Cor dos links ativos.", + "diffEditorInserted": "Cor de fundo para texto que foi inserido.", + "diffEditorRemoved": "Cor de fundo para texto que foi removido.", + "diffEditorInsertedOutline": "Cor de contorno para o texto que foi inserido.", + "diffEditorRemovedOutline": "Cor de contorno para o texto que foi removido." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/api/electron-browser/mainThreadExtensionService.i18n.json b/i18n/ptb/src/vs/workbench/api/electron-browser/mainThreadExtensionService.i18n.json new file mode 100644 index 00000000000..d45294dd317 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/api/electron-browser/mainThreadExtensionService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "overwritingExtension": "Sobrescrevendo extensão {0} por {1}.", + "extensionUnderDevelopment": "Carregando extensão de desenvolvimento em {0}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/api/electron-browser/mainThreadMessageService.i18n.json b/i18n/ptb/src/vs/workbench/api/electron-browser/mainThreadMessageService.i18n.json new file mode 100644 index 00000000000..0feb87677bb --- /dev/null +++ b/i18n/ptb/src/vs/workbench/api/electron-browser/mainThreadMessageService.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "close": "Fechar", + "cancel": "Cancelar", + "ok": "OK" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/api/node/extHostDiagnostics.i18n.json b/i18n/ptb/src/vs/workbench/api/node/extHostDiagnostics.i18n.json new file mode 100644 index 00000000000..867922ab8d2 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/api/node/extHostDiagnostics.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "limitHit": "Não apresentando {0} erros e avisos a mais." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/api/node/extHostTreeViews.i18n.json b/i18n/ptb/src/vs/workbench/api/node/extHostTreeViews.i18n.json new file mode 100644 index 00000000000..d5ca67a9353 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/api/node/extHostTreeViews.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "treeView.notRegistered": "Nenhuma visualização de árvore com id '{0}' registrado.", + "treeItem.notFound": "Nenhum item de árvore com id '{0}' encontrado.", + "treeView.duplicateElement": "Elemento {0} já está registrado" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/actions/configureLocale.i18n.json b/i18n/ptb/src/vs/workbench/browser/actions/configureLocale.i18n.json new file mode 100644 index 00000000000..80686b2c898 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/actions/configureLocale.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "configureLocale": "Configurar Idioma", + "displayLanguage": "Define o idioma de exibição do VSCode.", + "doc": "Veja {0} para obter uma lista dos idiomas suportados.", + "restart": "Modificar o valor requer reinicialização do VSCode.", + "fail.createSettings": "Não foi possível criar '{0}' ({1}).", + "JsonSchema.locale": "O idioma da interface do usuário a ser usada." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/actions/fileActions.i18n.json b/i18n/ptb/src/vs/workbench/browser/actions/fileActions.i18n.json new file mode 100644 index 00000000000..9da2e4e11c7 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/actions/fileActions.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openFolder": "Abrir Pasta...", + "openFileFolder": "Abrir..." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/actions/toggleActivityBarVisibility.i18n.json b/i18n/ptb/src/vs/workbench/browser/actions/toggleActivityBarVisibility.i18n.json new file mode 100644 index 00000000000..02e74f2918f --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/actions/toggleActivityBarVisibility.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleActivityBar": "Alternar Visibilidade da Barra de Atividades", + "view": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/actions/toggleEditorLayout.i18n.json b/i18n/ptb/src/vs/workbench/browser/actions/toggleEditorLayout.i18n.json new file mode 100644 index 00000000000..4cdb847aaca --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/actions/toggleEditorLayout.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleEditorGroupLayout": "Alternar Layout Vertical/Horizontal do Grupo de Editor", + "horizontalLayout": "Layout do Grupo de Editor Horizontal", + "verticalLayout": "Layout do Grupo de Editor Vertical", + "view": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/actions/toggleSidebarPosition.i18n.json b/i18n/ptb/src/vs/workbench/browser/actions/toggleSidebarPosition.i18n.json new file mode 100644 index 00000000000..ee4fc530361 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/actions/toggleSidebarPosition.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleLocation": "Alternar Localização da Barra Lateral", + "view": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/actions/toggleSidebarVisibility.i18n.json b/i18n/ptb/src/vs/workbench/browser/actions/toggleSidebarVisibility.i18n.json new file mode 100644 index 00000000000..5143e35479c --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/actions/toggleSidebarVisibility.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleSidebar": "Alternar Localização da Barra Lateral", + "view": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/actions/toggleStatusbarVisibility.i18n.json b/i18n/ptb/src/vs/workbench/browser/actions/toggleStatusbarVisibility.i18n.json new file mode 100644 index 00000000000..5376fb36c3a --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/actions/toggleStatusbarVisibility.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleStatusbar": "Alternar Visibilidade da Barra de Status", + "view": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/actions/toggleZenMode.i18n.json b/i18n/ptb/src/vs/workbench/browser/actions/toggleZenMode.i18n.json new file mode 100644 index 00000000000..b0a635982f2 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/actions/toggleZenMode.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleZenMode": "Alternar Modo Zen", + "view": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/activitybar/activitybarActions.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/activitybar/activitybarActions.i18n.json new file mode 100644 index 00000000000..8dab311a65f --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/activitybar/activitybarActions.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "removeFromActivityBar": "Remover da Barra de Atividades", + "keepInActivityBar": "Manter na Barra de Atividades", + "titleKeybinding": "{0} ({1})", + "additionalViews": "Visualizações Adicionais", + "numberBadge": "{0} ({1})", + "manageExtension": "Gerenciar Extensão", + "toggle": "Alternar Visualização Fixa" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json new file mode 100644 index 00000000000..5f8a7bb47de --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "hideActivitBar": "Ocultar a Barra de Atividades", + "activityBarAriaLabel": "Chave do Modo de exibição Ativo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/compositePart.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/compositePart.i18n.json new file mode 100644 index 00000000000..e12e6d4b90e --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/compositePart.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ariaCompositeToolbarLabel": "{0} ações ", + "titleTooltip": "{0} ({1})" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/binaryDiffEditor.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/binaryDiffEditor.i18n.json new file mode 100644 index 00000000000..a38af02d663 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/binaryDiffEditor.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "metadataDiff": "{0} ↔ {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/binaryEditor.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/binaryEditor.i18n.json new file mode 100644 index 00000000000..53321246ac7 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/binaryEditor.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "binaryEditor": "Visualizador binário" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/editor.contribution.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/editor.contribution.i18n.json new file mode 100644 index 00000000000..dbfae18a9bf --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/editor.contribution.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "textEditor": "Editor de texto", + "textDiffEditor": "Editor de Diferentes Textos", + "binaryDiffEditor": "Editor de Diferença Binária", + "sideBySideEditor": "Editor Lado a lado", + "groupOnePicker": "Mostrar editores no primeiro grupo", + "groupTwoPicker": "Mostrar editores no segundo grupo", + "groupThreePicker": "Mostrar editores no terceiro grupo", + "allEditorsPicker": "Mostrar todos editores abertos", + "view": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/editorActions.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorActions.i18n.json new file mode 100644 index 00000000000..ae6f9ae84b7 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorActions.i18n.json @@ -0,0 +1,55 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "splitEditor": "Dividir editor", + "joinTwoGroups": "Juntar editores de dois grupos", + "navigateEditorGroups": "Navegar entre grupos de editores", + "focusActiveEditorGroup": "Focalizar grupo de editores ativo", + "focusFirstEditorGroup": "Focalizar o primeiro grupo de editores", + "focusSecondEditorGroup": "Focalizar o segundo grupo de editores", + "focusThirdEditorGroup": "Focalizar o terceiro grupo de editores", + "focusPreviousGroup": "Focalizar grupo anterior", + "focusNextGroup": "Focalizar próximo grupo", + "openToSide": "Aberto para o lado", + "closeEditor": "Fechar editor", + "revertAndCloseActiveEditor": "Reverter e fechar editor", + "closeEditorsToTheLeft": "Fechar editores à esquerda ", + "closeEditorsToTheRight": "Fechar editores à direita", + "closeAllEditors": "Fechar todos editores", + "closeEditorsInOtherGroups": "Fechar editores nos outros grupos", + "closeOtherEditorsInGroup": "Fechar outros editores", + "closeEditorsInGroup": "Fechar todos editores no grupo", + "moveActiveGroupLeft": "Mover grupo de editores para esquerda", + "moveActiveGroupRight": "Mover grupo de editores para direita", + "minimizeOtherEditorGroups": "Minimizar outros grupos de editores", + "evenEditorGroups": "Igualar larguras de grupos de editores", + "maximizeEditor": "Maximizar grupo de editor e ocultar barra lateral", + "keepEditor": "Manter editor", + "openNextEditor": "Abrir próximo editor", + "openPreviousEditor": "Abrir editor anterior", + "nextEditorInGroup": "Abrir próximo editor no grupo", + "openPreviousEditorInGroup": "Abrir editor anterior no grupo", + "navigateNext": "Avançar", + "navigatePrevious": "Voltar", + "reopenClosedEditor": "Reabrir Editor Fechado", + "clearRecentFiles": "Limpar arquivos recentes", + "showEditorsInFirstGroup": "Mostrar editores no primeiro grupo", + "showEditorsInSecondGroup": "Mostrar editores no segundo grupo", + "showEditorsInThirdGroup": "Mostrar editores no terceiro grupo", + "showEditorsInGroup": "Mostrar editores no grupo", + "showAllEditors": "Mostrar todos editores", + "openPreviousRecentlyUsedEditorInGroup": "Abrir o Editor Anterior Recentemente Usado no Grupo", + "openNextRecentlyUsedEditorInGroup": "Abrir o Próximo Editor Recentemente Usado no Grupo", + "navigateEditorHistoryByInput": "Abrir o Editor Anterior do Histórico", + "openNextRecentlyUsedEditor": "Abrir o Próximo Editor Recentemente Utilizado", + "openPreviousRecentlyUsedEditor": "Abrir o Editor Anterior Recentemente Utilizado", + "clearEditorHistory": "Limpar Histórico do Editor", + "focusLastEditorInStack": "Abrir Último Editor do Grupo", + "moveEditorLeft": "Mover Editor para Esquerda", + "moveEditorRight": "Mover Editor para Direita", + "moveEditorToPreviousGroup": "Mover Editor para o Grupo Anterior", + "moveEditorToNextGroup": "Mover o Editor para o Próximo Grupo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/editorCommands.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorCommands.i18n.json new file mode 100644 index 00000000000..f42c45c02f5 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorCommands.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorCommand.activeEditorMove.description": "Mover o editor ativo por guias ou grupos", + "editorCommand.activeEditorMove.arg.name": "Argumento de movimento do editor ativo", + "editorCommand.activeEditorMove.arg.description": "Propriedades do argumento: \n\t\t\t\t\t\t- 'para': sequência de valor fornecendo para onde mover.\n\t\t\t\t\t\t- 'por': sequência de valor, fornecendo a unidade para o movimento. Por guia ou por grupo.\n\t\t\t\t\t\t- 'valor': valor numérico, fornecendo quantas posições ou uma posição absoluta para mover.\n\t\t\t\t\t", + "commandDeprecated": "Comando **{0}** foi removido. Você pode usar **{1}** em vez disso", + "openKeybindings": "Configurar os atalhos de teclado" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/editorPart.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorPart.i18n.json new file mode 100644 index 00000000000..c6a90d88542 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorPart.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "groupOneVertical": "Esquerda", + "groupTwoVertical": "Centro", + "groupThreeVertical": "Direita", + "groupOneHorizontal": "Topo", + "groupTwoHorizontal": "Centro", + "groupThreeHorizontal": "Baixo", + "editorOpenError": "Não foi possível abrir '{0}': {1}." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/editorPicker.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorPicker.i18n.json new file mode 100644 index 00000000000..e17bc940565 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorPicker.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, seletor de grupo editor", + "groupLabel": "Grupo: {0}", + "noResultsFoundInGroup": "Não foi encontrado nennhum editor aberto no grupo", + "noOpenedEditors": "Lista de editores abertos está atualmente vazia no grupo", + "noResultsFound": "Não foi encontrado editor correspondente aberto", + "noOpenedEditorsAllGroups": "A lista de editores abertos está atualmente vazia" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json new file mode 100644 index 00000000000..c2057c183a1 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json @@ -0,0 +1,49 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "singleSelectionRange": "Ln {0}, {1} Col ({2} selecionado)", + "singleSelection": "Ln {0}, {1} Col", + "multiSelectionRange": "{0} seleções ({1} caracteres selecionados)", + "multiSelection": "{0} seleções", + "endOfLineLineFeed": "LF", + "endOfLineCarriageReturnLineFeed": "CRLF", + "tabFocusModeEnabled": "Tabulação move o foco", + "disableTabMode": "Desativar o modo de acessibilidade", + "gotoLine": "Ir para linha", + "indentation": "Indentação", + "selectEncoding": "Selecionar a codificação", + "selectEOL": "Selecionar a sequência de fim de linha", + "selectLanguageMode": "Selecionar modo de idioma", + "fileInfo": "Informações do arquivo", + "spacesSize": "Espaços: {0}", + "tabSize": "Tamanho de Tabulação: {0}", + "showLanguageExtensions": "Pesquisar extensões na loja para '{0}'...", + "changeMode": "Alterar o modo de linguagem", + "noEditor": "Nenhum editor de texto ativo neste momento", + "languageDescription": "({0}) - linguagem configurada", + "languageDescriptionConfigured": "({0})", + "languagesPicks": "linguagens (identificador)", + "configureModeSettings": "Configurar '{0}' configurações baseadas em linguagem...", + "configureAssociationsExt": "Configurar a associação de arquivo para '{0}'...", + "autoDetect": "Detecção automática", + "pickLanguage": "Selecionar o modo do idioma", + "currentAssociation": "Associação atual", + "pickLanguageToConfigure": "Selecionar o modo de linguagem para associar a '{0}'", + "changeIndentation": "Alterar a indentação", + "noWritableCodeEditor": "O editor de código ativo é somente leitura.", + "indentView": "alterar visualização", + "indentConvert": "converter arquivo", + "pickAction": "Selecionar ação", + "changeEndOfLine": "Alterar sequência de final de linha", + "pickEndOfLine": "Selecionar sequência de final de linha", + "changeEncoding": "Alterar a codificação do arquivo", + "noFileEditor": "Nenhum arquivo ativo neste momento", + "saveWithEncoding": "Salvar com codificação", + "reopenWithEncoding": "Reabrir com codificação", + "guessedEncoding": "Adivinhado a partir do conteúdo", + "pickEncodingForReopen": "Selecione a codificaçãodo arquivo para reabrir o arquivo.", + "pickEncodingForSave": "Selecione a codificação do arquivo para Salvar Com" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/tabsTitleControl.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/tabsTitleControl.i18n.json new file mode 100644 index 00000000000..9001e58fa99 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/tabsTitleControl.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "araLabelTabActions": "Ações de tablulação" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/textDiffEditor.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/textDiffEditor.i18n.json new file mode 100644 index 00000000000..8af2aff62d5 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/textDiffEditor.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "textDiffEditor": "Editor de Diferentes Textos", + "readonlyEditorWithInputAriaLabel": "{0}. Editor de comparação de texto somente leitura.", + "readonlyEditorAriaLabel": "Editor de comparação de texto somente leitura.", + "editableEditorWithInputAriaLabel": "{0}. Editor de comparação de arquivos texto.", + "editableEditorAriaLabel": "Editor de comparação de arquivos texto.", + "navigate.next.label": "Próxima Alteração", + "navigate.prev.label": "Alteração Anterior", + "inlineDiffLabel": "Alternar para exibição embutida", + "sideBySideDiffLabel": "Alternar para exibição lado a lado" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/textEditor.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/textEditor.i18n.json new file mode 100644 index 00000000000..eb58230b854 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/textEditor.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorLabelWithGroup": "{0}, Grupo {1}." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/textResourceEditor.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/textResourceEditor.i18n.json new file mode 100644 index 00000000000..77f89efba5f --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/textResourceEditor.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "textEditor": "Editor de texto", + "readonlyEditorWithInputAriaLabel": "{0}. Editor de texto somente leitura.", + "readonlyEditorAriaLabel": "Editor de texto somente leitura.", + "untitledFileEditorWithInputAriaLabel": "{0}. Editor de texto de arquivo sem nome.", + "untitledFileEditorAriaLabel": "Editor de texto de arquivo sem nome." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/titleControl.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/titleControl.i18n.json new file mode 100644 index 00000000000..bf8307cd384 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/titleControl.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "close": "Fechar", + "closeOthers": "Fechar Outros", + "closeRight": "Fechar à direita", + "closeAll": "Fechar todos", + "keepOpen": "Manter aberto", + "showOpenedEditors": "Mostrar editores abertos", + "araLabelEditorActions": "Ações de editor" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/panel/panelActions.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/panel/panelActions.i18n.json new file mode 100644 index 00000000000..1f98f38c47e --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/panel/panelActions.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "panelActionTooltip": "{0} ({1})", + "closePanel": "Fechar Painel", + "togglePanel": "Alternar Painel", + "focusPanel": "Foco no Painel", + "toggleMaximizedPanel": "Alternar Painel Maximizado", + "maximizePanel": "Maximizar Tamanho do Painel", + "minimizePanel": "Restaurar tamanho do Painel", + "view": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/panel/panelPart.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/panel/panelPart.i18n.json new file mode 100644 index 00000000000..48a7b1b2f76 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/panel/panelPart.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "panelSwitcherBarAriaLabel": "Chave do Painel Ativo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/quickopen/quickOpenController.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/quickopen/quickOpenController.i18n.json new file mode 100644 index 00000000000..c98dd22d95d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/quickopen/quickOpenController.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "inputModeEntryDescription": "{0} (Pressione 'Enter' para confirmar ou 'Esc' para cancelar)", + "inputModeEntry": "Pressione 'Enter' para confirmar o texto digitado ou 'Esc' para cancelar", + "emptyPicks": "Não há entradas a serem escolhidas", + "quickOpenInput": "Digite '?' para obter ajuda sobre as ações que você pode realizar a partir daqui", + "historyMatches": "aberto recentemente", + "noResultsFound1": "Nenhum resultado encontrado", + "canNotRunPlaceholder": "Esse manipulador de abertura rápida não pode ser usado no contexto atual", + "entryAriaLabel": "{0}, recentemente aberto", + "removeFromEditorHistory": "Remover do Histórico", + "pickHistory": "Selecionar uma entrada do editor para remover do histórico" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/quickopen/quickopen.contribution.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/quickopen/quickopen.contribution.i18n.json new file mode 100644 index 00000000000..57f5524e1be --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/quickopen/quickopen.contribution.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpen": "Ir para o Arquivo...", + "quickNavigateNext": "Navegar ao próximo em modo de abertura rápida", + "quickNavigatePrevious": "Navegar ao anterior em modo de abertura rápida", + "quickSelectNext": "Selecionar próximo em modo de abertura rápida", + "quickSelectPrevious": "Selecionar anterior em modo de abertura rápida" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/sidebar/sidebarPart.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/sidebar/sidebarPart.i18n.json new file mode 100644 index 00000000000..89806e051ea --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/sidebar/sidebarPart.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "focusSideBar": "Foco na Barra Lateral", + "viewCategory": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/statusbar/statusbarPart.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/statusbar/statusbarPart.i18n.json new file mode 100644 index 00000000000..4a2adabf5a6 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/statusbar/statusbarPart.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "canNotRun": "O comando '{0}' não está habilitado e não pode ser executado.", + "manageExtension": "Gerenciar Extensão" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/titlebar/titlebarPart.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/titlebar/titlebarPart.i18n.json new file mode 100644 index 00000000000..1c3db4d572b --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/titlebar/titlebarPart.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "patchedWindowTitle": "[Sem Suporte]", + "devExtensionWindowTitlePrefix": "[Host de Desenvolvimento de Extensão]" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/quickopen.i18n.json b/i18n/ptb/src/vs/workbench/browser/quickopen.i18n.json new file mode 100644 index 00000000000..26c5e14f367 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/quickopen.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultsMatching": "Nenhum resultado encontrado", + "noResultsFound2": "Nenhum resultado encontrado", + "entryAriaLabel": "{0}, comando", + "noCommands": "Não há comandos correspondentes" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/viewlet.i18n.json b/i18n/ptb/src/vs/workbench/browser/viewlet.i18n.json new file mode 100644 index 00000000000..34655b736ba --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/viewlet.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "collapse": "Recolher tudo", + "viewToolbarAriaLabel": "{0} ações " +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/common/theme.i18n.json b/i18n/ptb/src/vs/workbench/common/theme.i18n.json new file mode 100644 index 00000000000..bfe4c0ef017 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/common/theme.i18n.json @@ -0,0 +1,44 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tabActiveBackground": "Cor de fundo da guia ativa. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", + "tabInactiveBackground": "Cor de fundo da guia inativa. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", + "tabBorder": "Borda para separar uma guia das outras. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", + "tabActiveEditorGroupActiveForeground": "Cor de primeiro plano da guia ativa em um grupo ativo. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", + "tabInactiveEditorGroupActiveForeground": "Cor de primeiro plano da guia inativa em um grupo ativo. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", + "editorGroupBackground": "Cor de fundo de um grupo de editor. Grupos de editor são os recipientes dos editores. A cor de fundo é mostrada ao arrastar o editor de grupos ao redor.", + "tabsContainerBackground": "Cor de fundo do cabeçalho do título do grupo de editor quando as guias são habilitadas. Grupos de editor são os recipientes dos editores.", + "editorGroupHeaderBackground": "Cor de fundo do título do cabeçalho do grupo de editor quando as guias são desabilitadas. Grupos de editor são os recipientes dos editores.", + "editorGroupBorder": "Cor para separar múltiplos grupos de editor de outro. Grupos de editor são os recipientes dos editores.", + "editorDragAndDropBackground": "Cor de fundo ao arrastar editores. A cor deve ter transparência para que o conteúdo do editor ainda possa ser visto.", + "panelBackground": "Cor de fundo do painel. Os painéis são mostrados abaixo da área do editor e contém visualizações como saída e terminal integrado.", + "panelBorder": "Cor da borda do painel no topo separando do editor. Os painéis são mostrados abaixo da área do editor e contém visualizações como saída e terminal integrado.", + "panelActiveTitleForeground": "Cor do título para o painel ativo. Os painéis são mostrados abaixo da área do editor e contém visualizações como saída e terminal integrado.", + "panelInactiveTitleForeground": "Cor do título para o painel inativo. Os painéis são mostrados abaixo da área do editor e contém visualizações como saída e terminal integrado.", + "panelActiveTitleBorder": "Cor da borda para o título do painel ativo. Os painéis são mostrados abaixo da área do editor e contém visualizações como saída e terminal integrado.", + "statusBarForeground": "Cor do primeiro plano da barra de status. A barra de status é mostrada na parte inferior da janela.", + "statusBarBackground": "Cor de fundo da barra de status padrão. A barra de status é mostrada na parte inferior da janela.", + "statusBarNoFolderBackground": "Cor de fundo da barra de status quando nenhuma pasta está aberta. A barra de status é mostrada na parte inferior da janela.", + "statusBarItemActiveBackground": "Cor de fundo do item da barra de status quando você clicado. A barra de status é mostrada na parte inferior da janela.", + "statusBarItemHoverBackground": "Cor de fundo do item da barra de status quando estiver passando sobre ele. A barra de status é mostrada na parte inferior da janela.", + "statusBarProminentItemBackground": "Cor de fundo de itens proeminentes da barra de status. Itens proeminentes destacam-se outras entradas da barra de status para indicar a importância. A barra de status é mostrada na parte inferior da janela.", + "statusBarProminentItemHoverBackground": "Cor de fundo dos itens proeminentes de barra de status quando estiver passando sobre eles. Itens proeminentes destacam-se outras entradas de barra de status para indicar a importância. A barra de status é mostrada na parte inferior da janela.", + "activityBarBackground": "Cor de fundo da barra de atividades. Barra de atividade está visível à esquerda ou à direita e permite alternar entre as visualizações da barra lateral.", + "activityBarForeground": "Cor de primeiro plano da barra de atividades (por exemplo, usada para os ícones). A barra de atividades está visível à esquerda ou à direita e permite alternar entre as visualizações da barra lateral.", + "activityBarDragAndDropBackground": "Cor de feedback de arrastar e soltar para os itens da barra de atividades. A cor deve ter transparência para que as entradas de bar de atividade ainda possam brilhar. A barra de atividade está visível à esquerda ou à direita e permite para alternar entre as visualizações da barra lateral.", + "activityBarBadgeBackground": "Cor de fundo da notificação de atividade. A barra de atividade está visível à esquerda ou à direita e permite alternar entre as visualizações da barra lateral.", + "activityBarBadgeForeground": "Cor de primeiro plano da notificação de atividade. A barra de atividade está visível à esquerda ou à direita e permite alternar entre as visualizações da barra lateral.", + "sideBarBackground": "Cor de fundo da barra lateral. A barra lateral é o recipiente para visualizações como explorador e pesquisa.", + "sideBarForeground": "Cor de primeiro plano da barra lateral. A barra lateral é o recipiente para visualizações como o explorador e a busca.", + "sideBarTitleForeground": "Cor de primeiro plano do título da barra lateral. A barra lateral é o recipiente para visualizações como explorador e pesquisa.", + "sideBarSectionHeaderBackground": "Cor de fundo do cabeçalho de seção lateral. A barra lateral é o recipiente para visões como explorador e pesquisa.", + "titleBarActiveForeground": "Cor da barra de título do primeiro plano quando a janela está ativa. Observe que essa cor atualmente somente é suportada no macOS.", + "titleBarInactiveForeground": "Cor de primeiro plano da barra de título quando a janela está inativa. Observe que essa cor atualmente somente é suportada no macOS.", + "titleBarActiveBackground": "Cor de fundo da barra de título quando a janela está ativa. Observe que essa cor atualmente somente é suportada no macOS.", + "titleBarInactiveBackground": "Cor de fundo de barra de título quando a janela está inativa. Observe que essa cor é atualmente somente suportada no macOS.", + "notificationsForeground": "Cor do primeiro plano de notificações. Notificações deslizam na parte superior da janela.", + "notificationsBackground": "Cor de fundo de notificações. Notificações deslizam na parte superior da janela." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/electron-browser/actions.i18n.json b/i18n/ptb/src/vs/workbench/electron-browser/actions.i18n.json new file mode 100644 index 00000000000..d829a3c8cad --- /dev/null +++ b/i18n/ptb/src/vs/workbench/electron-browser/actions.i18n.json @@ -0,0 +1,41 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "closeActiveEditor": "Fechar Editor", + "closeWindow": "Fechar Janela", + "switchWindow": "Alternar Janela", + "switchWindowPlaceHolder": "Selecionar uma janela", + "current": "Janela Atual", + "closeFolder": "Fechar Pasta", + "noFolderOpened": "Não há nenhuma pasta aberta nesta instância para ser fechada.", + "newWindow": "Nova Janela", + "toggleFullScreen": "Alternar Tela Inteira", + "toggleMenuBar": "Alternar Barra de Menus", + "toggleDevTools": "Alternar Ferramentas do Desenvolvedor", + "zoomIn": "Ampliar", + "zoomOut": "Reduzir", + "zoomReset": "Reinicializar Zoom", + "appPerf": "Desempenho de inicialização", + "reloadWindow": "Recarregar Janela", + "openRecent": "Abrir Recente", + "folders": "pastas", + "files": "arquivos", + "openRecentPlaceHolderMac": "Selecionar um caminho (Pressione a tecla Cmd para abrir em uma nova janela)", + "openRecentPlaceHolder": "Selecionar um caminho para abrir (Pressione a tecla Cmd para abrir em uma nova janela)", + "closeMessages": "Fechar mensagens de notificação", + "reportIssues": "Reportar Problemas", + "reportPerformanceIssue": "Reportar Problema de Desempenho", + "keybindingsReference": "Referência de Atalhos de Teclado", + "openDocumentationUrl": "Documentação", + "openIntroductoryVideosUrl": "Vídeos Introdutórios", + "toggleSharedProcess": "Alternar processo compartilhado", + "navigateLeft": "Mover para a Visualizção à Esquerda", + "navigateRight": "Mover para a Visualização à Direita", + "navigateUp": "Mover para a Visualização Acima", + "navigateDown": "Mover para a Visualização Abaixo", + "increaseViewSize": "Aumentar o Tamanho da Visualização Atual", + "decreaseViewSize": "Diminuir o Tamanho da Visualização Atual" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/electron-browser/commands.i18n.json b/i18n/ptb/src/vs/workbench/electron-browser/commands.i18n.json new file mode 100644 index 00000000000..3a1051dcfda --- /dev/null +++ b/i18n/ptb/src/vs/workbench/electron-browser/commands.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "diffLeftRightLabel": "{0} ⟷ {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/electron-browser/crashReporter.i18n.json b/i18n/ptb/src/vs/workbench/electron-browser/crashReporter.i18n.json new file mode 100644 index 00000000000..10b7a7ff108 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/electron-browser/crashReporter.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "telemetryConfigurationTitle": "Telemetria", + "telemetry.enableCrashReporting": "Ativar o envio de relatórios de incidentes à Microsoft.\nEsta opção requer reinicialização para ser efetivada." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/electron-browser/extensionHost.i18n.json b/i18n/ptb/src/vs/workbench/electron-browser/extensionHost.i18n.json new file mode 100644 index 00000000000..e5a7ab81686 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/electron-browser/extensionHost.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "extensionHostProcess.startupFailDebug": "O host de extensão não iniciou em 10 segundos, ele pode ser interrompido na primeira linha e precisa de um depurador para continuar.", + "extensionHostProcess.startupFail": "Host de extensão não começou em 10 segundos, isso pode ser um problema.", + "extensionHostProcess.error": "Erro do host de extensão: {0}", + "extensionHostProcess.crash": "Host de extensão foi encerrado inesperadamente. Por favor recarregar a janela para recuperar." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/ptb/src/vs/workbench/electron-browser/main.contribution.i18n.json new file mode 100644 index 00000000000..3b9050de1af --- /dev/null +++ b/i18n/ptb/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -0,0 +1,62 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "view": "Exibir", + "help": "Ajuda", + "file": "Arquivo", + "developer": "Desenvolvedor", + "showEditorTabs": "Controla se os editores abertos devem ou não serem exibidos em abas.", + "editorTabCloseButton": "Controla a posição dos botões de fechar das abas do editor ou os desabilita quando configurados para 'desligado'.", + "showIcons": "Controla se os editores abertos devem ou não ser exibidos com um ícone. Requer um tema de ícone para ser habilitado. ", + "enablePreview": "Controla se os editores abertos são exibidos como visualização. Editores de visualização são reutilizados até que eles sejam preservados (por exemplo, através de um duplo clique ou edição).", + "enablePreviewFromQuickOpen": "Controla se os editores abertos da Abertura Rápida são exibidos como visualização. Os editores de visualização são reutilizados até serem preservados (por exemplo, através de um duplo clique ou edição).", + "editorOpenPositioning": "Controla onde os editores serão abertos. Escolha 'esquerda' ou 'direita' para abrir os editores à esquerda ou à direita do \neditor ativo. Selecione 'primeiro' ou 'último' para abrir os editores independentemente do atual.", + "revealIfOpen": "Controla se um editor é exibido em qualquer um dos grupos, se aberto. Se desabilitado, um editor será aberto preferencialmente no grupo de editores ativo. Se habilitado, um editor já aberto será exibido no grupo de editores ativo, ao invés de ser aberto novamente. Note que há alguns casos onde esta configuração é ignorada, por exemplo, quando for forçada a abertura de um editor em um grupo específico ou ao lado do grupo atualmente ativo.", + "closeOnFocusLost": "Controla se Abertura Rápida deve fechar automaticamente caso perca o foco.", + "openDefaultSettings": "Controla se a abertura de configurações também abre um editor mostrando todas as configurações padrão.", + "sideBarLocation": "Controla a localização da barra lateral. Ele pode ser exibido à esquerda ou à direita da área de trabalho.", + "statusBarVisibility": "Controla a visibilidade da barra de status na parte inferior da área de trabalho.", + "activityBarVisibility": "Controla a visibilidade da barra de atividades na área de trabalho.", + "closeOnFileDelete": "Controla se os editores que mostram um arquivo devem fechar automaticamente quanto o arquivo é apagado ou renomeado por algum outro processo. Desativar isso manterá o editor aberto como sujo neste evento. Note que apagar do aplicativo sempre fechará o editor e os arquivos sujos nunca fecharão para preservar seus dados.", + "swipeToNavigate": "Navegue entre arquivos abertos usando o deslizamento horizontal de três dedos.", + "workbenchConfigurationTitle": "Ãrea de Trabalho", + "window.openFilesInNewWindow.on": "Arquivos serão abertos em uma nova janela", + "window.openFilesInNewWindow.off": "Arquivos serão abertos em uma nova janela com a pasta de arquivos aberta ou com a última janela ativa.", + "window.openFilesInNewWindow.default": "Os arquivos serão abertos na janela com a pasta de arquivos aberta ou a última janela ativa, a menos que seja aberto através do dock ou do finder (somente macOS)", + "openFilesInNewWindow": "Controla se os arquivos devem ser abertos em uma nova janela\n- padrão: os arquivos serão abertos em uma nova janela com a pasta de arquivos aberta ou na última janela ativa, a menos que seja aberta através do dock ou do finder (apenas macOS)\n- ligado: os arquivos serão abertos em uma nova janela\n- desligado: os arquivos serão abertos em uma janela com a pasta de arquivos aberta ou a última janela ativa\nNota que ainda podem haver casos em que esta configuração será ignorada (por exemplo, quando estiver usando as opções de linha de comando -new-window ou -reuse-window).", + "window.openFoldersInNewWindow.on": "As pastas serão abertas em uma nova janela", + "window.openFoldersInNewWindow.off": "As pastas substituirão a última janela ativa", + "window.openFoldersInNewWindow.default": "As pastas serão abertas em uma nova janela, a menos que uma pasta seja selecionada dentro do aplicativo (por exemplo, através do menu Arquivo)", + "openFoldersInNewWindow": "Controla se as pastas devem ser abertas em uma nova janela ou substituir a última janela ativa\n- padrão: as pastas serão abertas em uma nova janela, a menos que seja selecionada dentro do aplicativo (por exemplo, através do menu Arquivo)\n- ligado: as pastas serão abertas em uma nova janela\n- desligado: as pastas substituirão a última janela ativa\nNote que ainda podem haver casos em que esta configuração será ignorada (por exemplo, quando estiver usando as opções de linha de comando -new-window ou -reuse-window).", + "window.reopenFolders.none": "Nunca reabra uma pasta.", + "window.reopenFolders.one": "Reabrir a última pasta ativa.", + "window.reopenFolders.all": "Reabrir todas as pastas da última sessão.", + "reopenFolders": "Controla como as pastas são reabertas depois de um reinício. Escolha 'nenhum' para nunca reabrir uma pasta, 'uma' para reabrir a última pasta que você trabalhou ou 'todas' para reabrir todas as pastas da sua última sessão.", + "restoreFullscreen": "Controla se uma janela deve ser restaurada em modo de tela cheia se ela foi finalizada em modo de tela cheia.", + "zoomLevel": "Ajusta o nível de zoom da janela. O tamanho original é 0 e cada aumento (por exemplo, 1) ou redução (por exemplo, -1) representa um zoom 20% maior ou menor. Você também pode digitar decimais para ajustar o nível de zoom com uma granularidade mais fina.", + "title": "Controla o título da janela com base no editor ativo. As variáveis são substituídas com base no contexto:\n$ {ActiveEditorShort}: por exemplo, meuArquivo.txt\n$ {ActiveEditorMedium}: por exemplo, minhaPasta / meuArquivo.txt\n$ {ActiveEditorLong}: por exemplo, /Usuários/Desenvolvimento/meuProjeto/minhaPasta/meuArquivo.txt\n$ {RootName}: por exemplo, meuProjeto\n$ {RootPath}: por exemplo, /Usuários/Desenvolvimento/meuProjeto\n$ {AppName}: por exemplo, VS Code\n$ {Dirty}: um indicador sujo se o editor ativo for sujo\n$ {Separator}: um separador condicional (\"-\") que só aparece quando for rodeado por variáveis com valores", + "window.newWindowDimensions.default": "Abrir novas janelas no centro da tela.", + "window.newWindowDimensions.inherit": "Abrir novas janelas com a mesma dimensão da última janela ativa.", + "window.newWindowDimensions.maximized": "Abrir novas janelas maximizadas.", + "window.newWindowDimensions.fullscreen": "Abrir novas janelas em modo de tela cheia.", + "newWindowDimensions": "Controla as dimensões ao abrir uma nova janela quando pelo menos uma janela já está aberta. Por padrão, uma nova janela será aberta no centro da tela com pequena dimensão. Quando definido como 'inherit', a janela vai ter as mesmas dimensões que a última janela que estava ativa. Quando definido como 'maximized', a janela abrirá maximizada e em tela cheia se configurado para 'fullscreen'. Observe que essa configuração não tem um impacto sobre a primeira janela que é aberta. A primeira janela sempre irá restaurar o tamanho e a localização como você deixou antes de fechar.", + "window.menuBarVisibility.default": "O menu está oculto apenas em modo de tela cheia.", + "window.menuBarVisibility.visible": "O menu está sempre visivel mesmo quando em modo de tela cheia.", + "window.menuBarVisibility.toggle": "O menu está oculto, mas pode ser mostrado através da tecla Alt.", + "window.menuBarVisibility.hidden": "O menu está sempre oculto.", + "menuBarVisibility": "Controla a visibilidade da barra de menu. Uma configuração 'alternar' significa que a barra de menus está oculta e pressionar a tecla Alt irá mostrá-la. Por padrão, a barra de menu será visível, a menos que a janela esteja em modo de tela cheia.", + "enableMenuBarMnemonics": "Se habilitado, os menus principais podem ser abertos através de atalhos de tecla Alt. Desativar mnemônicos permite vincular esses atalhos de tecla Alt para comandos do editor.", + "autoDetectHighContrast": "Se habilitado, irá mudar automaticamente para o tema de alto contraste se o Windows estiver utilizando um tema de alto contraste, e para o tema escuro ao mudar de um tema de alto contraste do Windows.", + "titleBarStyle": "Ajusta a aparência da barra de título da janela. As alterações exigem um reinício completo.", + "window.nativeTabs": "Habilita as abas da janela do macOS Sierra. Note que as alterações exigem um reinício completo e que as abas nativas desabilitarão um estilo de barra de título customizado, se configurado.", + "windowConfigurationTitle": "Janela", + "zenModeConfigurationTitle": "Modo Zen", + "zenMode.fullScreen": "Controla se a ativação do modo Zen também coloca o espaço de trabalho em modo de tela cheia.", + "zenMode.hideTabs": "Controla se a ativação do modo Zen também oculta as abas do espaço de trabalho.", + "zenMode.hideStatusBar": "Controla se a ativação do modo Zen também oculta a barra de status no rodapé do espaço de trabalho.", + "zenMode.hideActivityBar": "Controla se a ativação do modo Zen também oculta a barra de atividades à esquerda do espaço de trabalho.", + "zenMode.restore": "Controla se uma janela deve ser restaurada para o modo zen se ela foi finalizada no modo zen." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/electron-browser/main.i18n.json b/i18n/ptb/src/vs/workbench/electron-browser/main.i18n.json new file mode 100644 index 00000000000..056d426d27d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/electron-browser/main.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "loaderError": "Falha ao carregar o arquivo necessário. Você não está mais conectado à Internet ou o servidor que você está conectado está offline. Atualize o navegador e tente novamente.", + "loaderErrorNative": "Falha ao carregar um arquivo necessário. Reinicie o aplicativo para tentar novamente. Detalhes: {0}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/electron-browser/shell.i18n.json b/i18n/ptb/src/vs/workbench/electron-browser/shell.i18n.json new file mode 100644 index 00000000000..951a140a2ea --- /dev/null +++ b/i18n/ptb/src/vs/workbench/electron-browser/shell.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "runningAsRoot": "Não é recomendado executar Code como 'root'." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/electron-browser/window.i18n.json b/i18n/ptb/src/vs/workbench/electron-browser/window.i18n.json new file mode 100644 index 00000000000..50118b77afe --- /dev/null +++ b/i18n/ptb/src/vs/workbench/electron-browser/window.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "undo": "Desfazer", + "redo": "Refazer", + "cut": "Recortar", + "copy": "Copiar", + "paste": "Colar", + "selectAll": "Selecionar Tudo", + "confirmOpen": "Tem certeza de que deseja abrir '{0}' pastas?", + "confirmOpenButton": "&&Abrir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/node/extensionHostMain.i18n.json b/i18n/ptb/src/vs/workbench/node/extensionHostMain.i18n.json new file mode 100644 index 00000000000..f0596b25871 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/node/extensionHostMain.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "extensionTestError": "Caminho {0} não aponta para um executor de testes com extensão válida." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/node/extensionPoints.i18n.json b/i18n/ptb/src/vs/workbench/node/extensionPoints.i18n.json new file mode 100644 index 00000000000..18d7b3f26c8 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/node/extensionPoints.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "jsonParseFail": "Falha ao analisar {0}: {1}.", + "fileReadFail": "Não foi possível ler o arquivo {0}: {1}.", + "jsonsParseFail": "Falha ao analisar {0} ou {1}: {2}.", + "missingNLSKey": "Não foi possível encontrar a mensagem para a chave {0}." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/cli/electron-browser/cli.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/cli/electron-browser/cli.contribution.i18n.json new file mode 100644 index 00000000000..69df9b15d87 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/cli/electron-browser/cli.contribution.i18n.json @@ -0,0 +1,18 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "install": "Instalar o comando '{0}' em PATH", + "not available": "Este comando não está disponível", + "successIn": "Comando shell '{0}' instalado com sucesso em PATH.", + "warnEscalation": "O código solicitará com 'osascript' pelos privilégios de Administrador para instalar o comando shell.", + "ok": "OK", + "cantCreateBinFolder": "Não é possível criar '/usr/local/bin'.", + "cancel2": "Cancelar", + "aborted": "Abortado", + "uninstall": "Desinstalar o comando '{0}' de PATH", + "successFrom": "Comando shell '{0}' desinstalado com sucesso de PATH.", + "shellCommand": "Comando shell" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json new file mode 100644 index 00000000000..18ee740ae31 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "workbench.action.inspectKeyMap": "Desenvolvedor: Inspecionar Mapeamentos de Chave" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderControlCharacter.i18n.json b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderControlCharacter.i18n.json new file mode 100644 index 00000000000..217bdf1c04e --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderControlCharacter.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleRenderControlCharacters": "Alternar caracteres de controle" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderWhitespace.i18n.json b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderWhitespace.i18n.json new file mode 100644 index 00000000000..453104fcc6d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderWhitespace.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleRenderWhitespace": "Alternar Espaço em Branco Renderizado" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json new file mode 100644 index 00000000000..058048058af --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggle.wordwrap": "Visualizar: Alternar Quebra de Linha", + "wordWrap.notInDiffEditor": "Não pode alternar quebra de linha em um editor diff.", + "unwrapMinified": "Desabilitar empacotamento para este arquivo", + "wrapMinified": "Habilitar empacotamento para este arquivo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/wordWrapMigration.i18n.json b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/wordWrapMigration.i18n.json new file mode 100644 index 00000000000..12f93be687c --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/wordWrapMigration.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "wordWrapMigration.ok": "OK", + "wordWrapMigration.dontShowAgain": "Não mostrar novamente", + "wordWrapMigration.openSettings": "Abrir configurações", + "wordWrapMigration.prompt": "A configuração `editor.wrappingColumn` foi descontinuada e substituída pela configuração `editor.wordWrap`" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/browser/breakpointWidget.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/browser/breakpointWidget.i18n.json new file mode 100644 index 00000000000..3d748795633 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/browser/breakpointWidget.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "breakpointWidgetExpressionPlaceholder": "Parar quando a expressão for avaliada como true. 'Enter' para aceitar, 'esc' para cancelar.", + "breakpointWidgetAriaLabel": "O programa só vai parar aqui se esta condição for verdadeira. Pressione Enter para aceitar ou Escape para cancelar.", + "breakpointWidgetHitCountPlaceholder": "Parar quando contagem de ocorrências condição for alcançada. 'Enter' para aceitar, 'esc' para cancelar.", + "breakpointWidgetHitCountAriaLabel": "O programa só vai parar aqui, se a contagem de ocorrências for alcançada. Pressione Enter para aceitar ou Escape para cancelar.", + "expression": "Expressão", + "hitCount": "Contagem de ocorrências" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/browser/debugActionItems.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugActionItems.i18n.json new file mode 100644 index 00000000000..32a88b85efd --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugActionItems.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "addConfiguration": "Adicionar Configuração...", + "noConfigurations": "Sem configurações" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/browser/debugActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugActions.i18n.json new file mode 100644 index 00000000000..1bc052297a1 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugActions.i18n.json @@ -0,0 +1,49 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openLaunchJson": "Abrir {0}", + "launchJsonNeedsConfigurtion": "Configurar ou corrigir 'launch.json'", + "noFolderDebugConfig": "Primeiro abra uma pasta para fazer uma configuração de depuração avançada.", + "startDebug": "Iniciar Depuração", + "startWithoutDebugging": "Iniciar Sem Depuração", + "selectAndStartDebugging": "Selecionar e Iniciar a Depuração", + "restartDebug": "Reiniciar", + "reconnectDebug": "Reconectar", + "stepOverDebug": "Pular Sobre", + "stepIntoDebug": "Pular Dentro", + "stepOutDebug": "Pular Fora", + "stopDebug": "Parar", + "disconnectDebug": "Desconectar", + "continueDebug": "Continuar", + "pauseDebug": "Pausa", + "restartFrame": "Reiniciar o Frame", + "removeBreakpoint": "Remover Ponto de Parada", + "removeAllBreakpoints": "Remover Todos os Pontos de Parada", + "enableBreakpoint": "Habilitar ponto de Parada", + "disableBreakpoint": "Desativar Ponto de Parada", + "enableAllBreakpoints": "Habilitar Todos os Pontos de Parada", + "disableAllBreakpoints": "Desabilitar Todos Pontos de Parada", + "activateBreakpoints": "Ativar Pontos de Parada", + "deactivateBreakpoints": "Desativar Pontos de Parada", + "reapplyAllBreakpoints": "Reaplicar Todos os Pontos de Parada", + "addFunctionBreakpoint": "Adicionar Ponto de Parada de Função", + "renameFunctionBreakpoint": "Renomeie o Ponto de Parada de Função", + "addConditionalBreakpoint": "Adicionar Ponto de Parada Condicional...", + "editConditionalBreakpoint": "Editar o Ponto de Parada...", + "setValue": "Definir Valor", + "addWatchExpression": "Adicionar Expressão", + "editWatchExpression": "Editar expressão", + "addToWatchExpressions": "Adicionar ao monitoramento", + "removeWatchExpression": "Remover Expressão", + "removeAllWatchExpressions": "Remover Todas as Expressões", + "clearRepl": "Limpar console", + "debugConsoleAction": "Console do Depurador", + "unreadOutput": "Nova Saída no Console de Depuração", + "debugFocusConsole": "Foco no Console de Depuração", + "focusProcess": "Foco no Processo", + "stepBackDebug": "Passo para trás", + "reverseContinue": "Reverter" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/browser/debugActionsWidget.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugActionsWidget.i18n.json new file mode 100644 index 00000000000..421e5b19c79 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugActionsWidget.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "debugToolBarBackground": "Cor de fundo da barra de ferramentas de depuração." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/browser/debugContentProvider.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugContentProvider.i18n.json new file mode 100644 index 00000000000..d8aa95c869a --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugContentProvider.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "unable": "Não é possível resolver o recurso sem uma sessão de depuração" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/browser/debugEditorActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugEditorActions.i18n.json new file mode 100644 index 00000000000..ef74c88413d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugEditorActions.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleBreakpointAction": "Depurar: Alternar Ponto de Parada", + "columnBreakpointAction": "Depurar: Ponto de Interrupção de Coluna", + "columnBreakpoint": "Adicionar Ponto de Interrupção de Coluna", + "conditionalBreakpointEditorAction": "Depurar: Adicionar Ponto de Interrupção Condicional...", + "runToCursor": "Executar até o Cursor", + "debugEvaluate": "Depurar: Avaliar", + "debugAddToWatch": "Depurar: Adicionar ao monitoramento", + "showDebugHover": "Mostrar Item Flutuante" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/browser/debugEditorModelManager.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugEditorModelManager.i18n.json new file mode 100644 index 00000000000..f30b378456b --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugEditorModelManager.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "breakpointDisabledHover": "Ponto de Parada Desativado", + "breakpointUnverifieddHover": "Ponto de Parada Não Verificado", + "breakpointDirtydHover": "Ponto de parada não verificado. O arquivo foi modificado, por favor reinicie a sessão de depuração.", + "breakpointUnsupported": "Pontos de parada condicionais não são suportados por esse tipo de depurador" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/browser/debugQuickOpen.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugQuickOpen.i18n.json new file mode 100644 index 00000000000..01955c44965 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugQuickOpen.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "depurar {0}", + "debugAriaLabel": "Digite um nome de uma configuração de lançamento para ser executado.", + "noConfigurationsMatching": "Não há configurações de depuração correspondentes", + "noConfigurationsFound": "Configurações de depuração não encontradas. Por favor, crie um arquivo 'launch.json'." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/browser/exceptionWidget.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/browser/exceptionWidget.i18n.json new file mode 100644 index 00000000000..a8802c13164 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/browser/exceptionWidget.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "debugExceptionWidgetBorder": "Cor da borda da ferramenta de exceção.", + "debugExceptionWidgetBackground": "Cor de fundo da ferramenta de exceção.", + "exceptionThrownWithId": "Ocorreu exceção: {0}", + "exceptionThrown": "Ocorreu exceção." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/browser/linkDetector.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/browser/linkDetector.i18n.json new file mode 100644 index 00000000000..8c7a8761f41 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/browser/linkDetector.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "fileLinkMac": "Clique para seguir (Cmd + clique abre ao lado)", + "fileLink": "Clique para seguir (Cmd + clique abre ao lado)" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/common/debug.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/common/debug.i18n.json new file mode 100644 index 00000000000..3476b79d9e1 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/common/debug.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "internalConsoleOptions": "Controla o comportamento do console depuração interna." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/common/debugModel.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/common/debugModel.i18n.json new file mode 100644 index 00000000000..fa2f5e8ada5 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/common/debugModel.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "notAvailable": "não disponível", + "startDebugFirst": "Por favor, inicie uma sessão de depuração para avaliar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/common/debugSource.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/common/debugSource.i18n.json new file mode 100644 index 00000000000..0e10c85d818 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/common/debugSource.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "unknownSource": "Fonte desconhecida" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debug.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debug.contribution.i18n.json new file mode 100644 index 00000000000..05a7ccfe827 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debug.contribution.i18n.json @@ -0,0 +1,20 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleDebugViewlet": "Visualizar Depurador", + "toggleDebugPanel": "Console do Depurador", + "debug": "Depurar", + "debugPanel": "Console do Depurador", + "view": "Exibir", + "debugCategory": "Depurar", + "debugCommands": "Configuração do Depurador", + "debugConfigurationTitle": "Depurar", + "allowBreakpointsEverywhere": "Permite definir um ponto de interrupção em qualquer arquivo.", + "openExplorerOnEnd": "Automaticamente abre a visualização do explorador no final de uma sessão de depuração", + "inlineValues": "Mostrar valores de variáveis em linha no editor durante a depuração", + "hideActionBar": "Controlar se a barra de ação flutuante do depurador deve ser ocultada", + "launch": "Configuração global do lançamento do depurador. Deve ser usado como uma alternativa para o arquivo 'launch.json' que é compartilhado entre os espaços de trabalho" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json new file mode 100644 index 00000000000..85b353a37fe --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noFolderDebugConfig": "Primeiro abra uma pasta para fazer uma configuração de depuração avançada." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugConfigurationManager.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugConfigurationManager.i18n.json new file mode 100644 index 00000000000..ada60277e7b --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugConfigurationManager.i18n.json @@ -0,0 +1,38 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.debuggers": "Contribui adaptadores de depuração.", + "vscode.extension.contributes.debuggers.type": "Identificador único para esse adaptador de depuração.", + "vscode.extension.contributes.debuggers.label": "Nome de exibição para esse adaptador de depuração.", + "vscode.extension.contributes.debuggers.program": "Caminho para o programa adaptador de depuração. O caminho pode ser absoluto ou relativo à pasta de extensão.", + "vscode.extension.contributes.debuggers.args": "Argumentos opcionais a serem informados para o adaptador.", + "vscode.extension.contributes.debuggers.runtime": "Runtime opcional no caso do atributo do programa não ser um executável, mas requerer um runtime.", + "vscode.extension.contributes.debuggers.runtimeArgs": "Argumentos opcionais do runtime.", + "vscode.extension.contributes.debuggers.variables": "Mapeamento de variáveis interativas (por exemplo ${action.pickProcess}) em 'launch.json' para um comando.", + "vscode.extension.contributes.debuggers.initialConfigurations": "Configurações para gerar o 'launch.json' inicial.", + "vscode.extension.contributes.debuggers.languages": "Lista de idiomas para os quais a extensão de depuração pode ser considerada o \"depurador padrão\".", + "vscode.extension.contributes.debuggers.adapterExecutableCommand": "Se especificado VS Code chamará este comando para determinar o caminho do executável do adaptador de depuração e os argumentos para passar.", + "vscode.extension.contributes.debuggers.startSessionCommand": "Se especificado VS Code chamará este comando para as ações de \"depurar\" ou \"executar\" direcionadas para esta extensão.", + "vscode.extension.contributes.debuggers.configurationSnippets": "Trechos de código para adicionar novas configurações em 'launch.json'.", + "vscode.extension.contributes.debuggers.configurationAttributes": "Configurações de esquema JSON para validar 'launch.json'.", + "vscode.extension.contributes.debuggers.windows": "Configurações específicas do Windows.", + "vscode.extension.contributes.debuggers.windows.runtime": "Runtime usado para Windows.", + "vscode.extension.contributes.debuggers.osx": "Configurações específicas do OS X.", + "vscode.extension.contributes.debuggers.osx.runtime": "Runtime usado para o OS X.", + "vscode.extension.contributes.debuggers.linux": "Configurações específicas do Linux.", + "vscode.extension.contributes.debuggers.linux.runtime": "Runtime usado para o Linux.", + "vscode.extension.contributes.breakpoints": "Contribui aos pontos de interrupção.", + "vscode.extension.contributes.breakpoints.language": "Permitir pontos de parada para este idioma.", + "app.launch.json.title": "Executar", + "app.launch.json.version": "Versão deste formato de arquivo.", + "app.launch.json.configurations": "Lista de configurações. Adicionar novas configurações ou editar as existentes usando o IntelliSense.", + "app.launch.json.compounds": "Lista de compostos. Cada composto faz referência a várias configurações que vão ser executadas juntas.", + "app.launch.json.compound.name": "Nome do composto. Aparece no menu drop-down da configuração de execução.", + "app.launch.json.compounds.configurations": "Nomes das configurações que serão iniciadas como parte deste composto.", + "debugNoType": "'type' do adaptador de depuração não pode ser omitido e deve ser do tipo 'string'.", + "DebugConfig.failed": "Não é possível criar o arquivo 'launch.json' dentro da pasta '.vscode' ({0}).", + "selectDebug": "Selecione o ambiente" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.i18n.json new file mode 100644 index 00000000000..1424499bfcc --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.i18n.json @@ -0,0 +1,20 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "removeBreakpoints": "Remover pontos de interrupção", + "removeBreakpointOnColumn": "Remover ponto de interrupção na coluna {0}", + "removeLineBreakpoint": "Remover ponto de interrupção de linha", + "editBreakpoints": "Editar pontos de interrupção", + "editBreakpointOnColumn": "Editar o ponto de interrupção na coluna {0}", + "editLineBrekapoint": "Editar o ponto de interrupção de linha", + "enableDisableBreakpoints": "Habilitar/Desabilitar pontos de interrupção", + "disableColumnBreakpoint": "Desabilitar ponto de interrupção na coluna {0}", + "disableBreakpointOnLine": "Desabilitar ponto de interrupção de linha", + "enableBreakpoints": "Habilitar o ponto de interrupção na coluna {0}", + "enableBreakpointOnLine": "Habilitar o ponto de interrupção de linha", + "addBreakpoint": "Adicionar ponto de interrupção", + "addConfiguration": "Adicionar Configuração..." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugHover.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugHover.i18n.json new file mode 100644 index 00000000000..1853865a1ec --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugHover.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "treeAriaLabel": "Depurar passando o mouse por cima" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json new file mode 100644 index 00000000000..6dc0bc48afb --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json @@ -0,0 +1,25 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "snapshotObj": "Apenas valores primitivos são mostrados para este objeto.", + "debuggingStarted": "Depuração Iniciada.", + "debuggingPaused": "Depuração pausada, razão {0}, {1} {2}", + "debuggingStopped": "Depuração parada.", + "breakpointAdded": "Adicionado ponto de interrupção, linha {0}, arquivo {1}", + "breakpointRemoved": "Ponto de interrupção removido, linha {0}, arquivo {1}", + "compoundMustHaveConfigurations": "Composição deve ter o atributo \"configurations\" definido para iniciar várias configurações.", + "configMissing": "Configuração '{0}' não tem 'launch.json'.", + "debugTypeNotSupported": "Tipo de depuração configurado '{0}' não é suportado.", + "debugTypeMissing": "Falta a propriedade 'type' para a configuração de lançamento escolhida.", + "preLaunchTaskErrors": "Erros de build foram detectados durante a preLaunchTask '{0}'.", + "preLaunchTaskError": "Erro de build foi detectado durante a preLaunchTask '{0}'.", + "preLaunchTaskExitCode": "A preLaunchTask '{0}' encerrada com código de saída {1}.", + "debugAnyway": "Depurar mesmo assim", + "noFolderWorkspaceDebugError": "O arquivo ativo não pode ser depurado. Certifique-se de que ele está salvo no disco e que tem uma extensão de depuração instalada para esse tipo de arquivo.", + "NewLaunchConfig": "Por favor, configure o arquivo de configuração de lançamento para seu aplicativo. {0}", + "DebugTaskNotFound": "Não foi possível encontrar o preLaunchTask '{0}'.", + "differentTaskRunning": "Há uma tarefa {0} sendo executada. Não pode executar a tarefa de pré-lançamento {1}." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugViewer.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugViewer.i18n.json new file mode 100644 index 00000000000..ae47cc6a47d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugViewer.i18n.json @@ -0,0 +1,28 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "process": "Processar", + "paused": "Em pausa", + "running": "Em execução", + "thread": "Thread", + "pausedOn": "Pausado em {0}", + "loadMoreStackFrames": "Carregar mais segmentos de pilha", + "threadAriaLabel": "Thread {0}, pilha de chamadas, depuração", + "stackFrameAriaLabel": "Segmento de Pilha {0} linha {1} {2}, pilha de chamadas, depuração", + "variableValueAriaLabel": "Digite o novo valor da variável", + "variableScopeAriaLabel": "Escopo {0}, variáveis, depuração", + "variableAriaLabel": "{0} valor {1}, variáveis, depuração", + "watchExpressionPlaceholder": "Expressão para monitorar", + "watchExpressionInputAriaLabel": "Digitar expressão a monitorar", + "watchExpressionAriaLabel": "{0} valor {1}, monitorar, depuração", + "watchVariableAriaLabel": "{0} valor {1}, monitorar, depuração", + "functionBreakpointPlaceholder": "Função de parada", + "functionBreakPointInputAriaLabel": "Digitar Ponto de Parada de Função", + "functionBreakpointsNotSupported": "Pontos de parada de função não são suportados por este tipo de depuração", + "breakpointAriaLabel": "Ponto de parada linha {0} {1}, pontos de parada, depuração", + "functionBreakpointAriaLabel": "Ponto de parada de função {0}, pontos de parada, depuração", + "exceptionBreakpointAriaLabel": "Ponto de parada de exceção {0}, pontos de parada, depuração" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json new file mode 100644 index 00000000000..d14c4338ceb --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json @@ -0,0 +1,20 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "variablesSection": "Seção de variáveis", + "variables": "Variáveis", + "variablesAriaTreeLabel": "Variáveis de Depuração", + "expressionsSection": "Seção de Expressões", + "watch": "Monitoramento", + "watchAriaTreeLabel": "Depurar Expressões Monitoradas", + "callstackSection": "Seção de Pilha de Chamada", + "debugStopped": "Pausado em {0}", + "callStack": "Pilha de Chamadas", + "callStackAriaLabel": "Depurar a Pilha de Chamadas", + "breakpointsSection": "Seção de Pontos de Parada", + "breakpoints": "Pontos de Parada", + "breakpointsAriaTreeLabel": "Depurar os Pontos de Parada" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json new file mode 100644 index 00000000000..227ca95927f --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "copyValue": "Copiar valor", + "copy": "Copiar", + "copyAll": "Copiar todos", + "copyStackTrace": "Copiar Pilha de Chamadas" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.i18n.json new file mode 100644 index 00000000000..0ce97a8f796 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "moreInfo": "Mais Informações", + "unableToLaunchDebugAdapter": "Não é possível executar o adaptador de depuração de '{0}'.", + "unableToLaunchDebugAdapterNoArgs": "Não é possível executar o adaptador de depuração.", + "stoppingDebugAdapter": "{0}. Parando o adaptador de depuração.", + "debugAdapterCrash": "Processo do adaptador de depuração foi finalizado inesperadamente" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/repl.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/repl.i18n.json new file mode 100644 index 00000000000..73f6f0be4c4 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/repl.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "replAriaLabel": "Ler o Painel de Impressão Eval", + "actions.repl.historyPrevious": "História anterior", + "actions.repl.historyNext": "Próxima história", + "actions.repl.acceptInput": "REPL Aceitar Entrada" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/replViewer.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/replViewer.i18n.json new file mode 100644 index 00000000000..4afd6d64d82 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/replViewer.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "stateCapture": "Estado do objeto é capturado na primeira avaliação", + "replVariableAriaLabel": "Variável {0} tem valor {1}, ler a impressão do valor do loop, depurar", + "replExpressionAriaLabel": "Expressão {0} tem valor {1}, ler o laço de avaliação de impressão, depurar", + "replValueOutputAriaLabel": " impressão da avaliação do laço de leitura, depurar", + "replKeyValueOutputAriaLabel": "Variável de saída {0} tem valor {1}, ler o loop de avaliação de impressão, depurar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json new file mode 100644 index 00000000000..b191a0de856 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "statusBarDebuggingBackground": "Cor de fundo da barra de status quando um programa está sendo depurado. A barra de status é mostrada na parte inferior da janela" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/terminalSupport.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/terminalSupport.i18n.json new file mode 100644 index 00000000000..898a18605fb --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/terminalSupport.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "debug.terminal.title": "depurado", + "debug.terminal.not.available.error": "Terminal integrado não disponível" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json new file mode 100644 index 00000000000..f0551dfe57b --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json @@ -0,0 +1,20 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "debugAdapterBinNotFound": "Executável do adaptador de depuração '{0}' não existe.", + "debugAdapterCannotDetermineExecutable": "Não é possível determinar o executável para o adaptador de depuração '{0}'.", + "debugType": "Tipo de configuração.", + "debugTypeNotRecognised": "O tipo de depuração não é reconhecido. Certifique-se de que você tem uma extensão de depuração correspondente instalada e que ela está habilitada.", + "node2NotSupported": "\"node2\" não é mais suportado, use \"node\" ao invés e defina o atributo \"protocol\" para \"inspector\".", + "debugName": "Nome da configuração; aparece no menu drop-down da configuração de lançamento. ", + "debugRequest": "Requer o tipo de configuração. Pode ser \"launch\" ou \"attach\".", + "debugServer": "Somente para o desenvolvimento de extensão de depuração: se uma porta é especificada, o VS Code tenta se conectar a um adaptador de depuração executando em modo de servidor", + "debugPrelaunchTask": "Tarefa para ser executada antes de começar a sessão de depuração.", + "debugWindowsConfiguration": "Atributos de configuração de lançamento específicos do Windows.", + "debugOSXConfiguration": "Atributos de configuração de lançamento específicos do OS X.", + "debugLinuxConfiguration": "Atributos de configuração de lançamento específicos do Linux.", + "deprecatedVariables": "'env.', 'config.' e 'command.' foram descontinuados, use ' env:', ' config:' e ' command:' em vez disso." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/browser/actions/showEmmetCommands.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/browser/actions/showEmmetCommands.i18n.json new file mode 100644 index 00000000000..1e3a1c0f277 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/browser/actions/showEmmetCommands.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "showEmmetCommands": "Mostrar Comandos do Emmet" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/balance.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/balance.i18n.json new file mode 100644 index 00000000000..1dc5e1e3b69 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/balance.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "balanceInward": "Emmet: Saldo (interno)", + "balanceOutward": "Emmet: Saldo (externo)" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json new file mode 100644 index 00000000000..cccc82d8a01 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "previousEditPoint": "Emmet: Ponto de edição anterior", + "nextEditPoint": "Emmet: Ponto próxima edição" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json new file mode 100644 index 00000000000..b4a6a03e213 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "evaluateMathExpression": "Emmet: Avaliar a expressão matemática" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.i18n.json new file mode 100644 index 00000000000..5a5dd3cc3e8 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "expandAbbreviationAction": "Emmet: Expandir Abreviação" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json new file mode 100644 index 00000000000..306332a4af2 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "incrementNumberByOneTenth": "Emmet: Incremento de 0.1", + "incrementNumberByOne": "Emmet: Incremento de 1", + "incrementNumberByTen": "Emmet: Incremento de 10", + "decrementNumberByOneTenth": "Emmet: Decréscimo por 0.1", + "decrementNumberByOne": "Emmet: Decréscimo por 1", + "decrementNumberByTen": "Emmet: Decréscimo por 10" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/matchingPair.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/matchingPair.i18n.json new file mode 100644 index 00000000000..6a742c4d5f9 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/matchingPair.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "matchingPair": "Emmet: Ir para o par de correspondência" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/mergeLines.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/mergeLines.i18n.json new file mode 100644 index 00000000000..22ed3f5f533 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/mergeLines.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "mergeLines": "Emmet: Mesclar linhas" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/reflectCssValue.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/reflectCssValue.i18n.json new file mode 100644 index 00000000000..bc0eefc2e00 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/reflectCssValue.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "reflectCSSValue": "Emmet: Refletir valor CSS" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json new file mode 100644 index 00000000000..a30414b08d2 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "removeTag": "Emmet: Remover Rótulo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/selectItem.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/selectItem.i18n.json new file mode 100644 index 00000000000..1343e2d6b36 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/selectItem.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "selectPreviousItem": "Emmet: Selecione o Item anterior", + "selectNextItem": "Emmet: Selecione o próximo Item" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json new file mode 100644 index 00000000000..ea04346ea7c --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "splitJoinTag": "Emmet: Dividir/Juntar Rótulo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/toggleComment.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/toggleComment.i18n.json new file mode 100644 index 00000000000..366cb874a0c --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/toggleComment.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleComment": "Emmet: Alternar Comentário" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json new file mode 100644 index 00000000000..1eff88ade9d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "updateImageSize": "Emmet: Atualizar o Tamanho da Imagem" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json new file mode 100644 index 00000000000..963a85e1671 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "updateTag": "Emmet: Atualizar Rótulo", + "enterTag": "Insira o Rótulo", + "tag": "Rótulo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json new file mode 100644 index 00000000000..501253b7dcb --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "wrapWithAbbreviationAction": "Emmet: Envelope com a abreviatura", + "enterAbbreviation": "Digite a abreviação", + "abbreviation": "Abreviação" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json new file mode 100644 index 00000000000..1caebe040f5 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "emmetConfigurationTitle": "Emmet", + "triggerExpansionOnTab": "Quando habilitado, abreviações emmet são expandidas ao pressionar TAB.", + "emmetPreferences": "Preferências usadas para modificar o comportamento de algumas ações e resolvedores de Emmet.", + "emmetSyntaxProfiles": "Definir o perfil para a sintaxe especificada ou usar seu próprio perfil com regras específicas.", + "emmetExclude": "Uma matriz de línguagens onde abreviaturas emmet não devem ser expandidas.", + "emmetExtensionsPath": "Caminho para uma pasta contendo perfis emmet, trechos e preferências" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/execution/electron-browser/terminal.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/execution/electron-browser/terminal.contribution.i18n.json new file mode 100644 index 00000000000..95274daf750 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/execution/electron-browser/terminal.contribution.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminalConfigurationTitle": "Terminal Externo", + "terminal.external.windowsExec": "Personalizar qual terminal executar no Windows.", + "terminal.external.osxExec": "Personalizar qual aplicativo de terminal executar no OS X.", + "terminal.external.linuxExec": "Personalizar qual terminal executar no Linux.", + "globalConsoleActionWin": "Abrir Novo Prompt de Comando", + "globalConsoleActionMacLinux": "Abrir Novo Terminal", + "scopedConsoleActionWin": "Abrir no Prompt de Comando", + "scopedConsoleActionMacLinux": "Abrir no Terminal" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/execution/electron-browser/terminalService.i18n.json b/i18n/ptb/src/vs/workbench/parts/execution/electron-browser/terminalService.i18n.json new file mode 100644 index 00000000000..fde640b09c5 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/execution/electron-browser/terminalService.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "console.title": "Console VS Code", + "mac.terminal.script.failed": "Script '{0}' falhou com código de saída {1}", + "mac.terminal.type.not.supported": "'{0}' não suportado", + "press.any.key": "Pressione qualquer tecla para continuar...", + "linux.term.failed": "'{0}' falhou com código de saída {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json new file mode 100644 index 00000000000..d79e3c4ca0a --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.view": "Contribui ao modo de exibição personalizado", + "vscode.extension.contributes.view.id": "Identificação única usada para identificar a vista criada por vscode.workspace.createTreeView", + "vscode.extension.contributes.view.label": "Sequência de caracteres legível usada para processar a visualização", + "vscode.extension.contributes.view.icon": "Caminho para o ícone da visualização", + "vscode.extension.contributes.views": "Contribui com visualizações personalizadas", + "showViewlet": "Mostrar {0}", + "view": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorerActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorerActions.i18n.json new file mode 100644 index 00000000000..37735d10007 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorerActions.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "refresh": "Atualizar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorerService.i18n.json b/i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorerService.i18n.json new file mode 100644 index 00000000000..7b7f16b3812 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorerService.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "treeExplorer.noMatchingProviderId": "Não há TreeExplorerNodeProvider com id {providerId} registrado." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/explorers/browser/views/treeExplorerView.i18n.json b/i18n/ptb/src/vs/workbench/parts/explorers/browser/views/treeExplorerView.i18n.json new file mode 100644 index 00000000000..0e7f5f9cd92 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/explorers/browser/views/treeExplorerView.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "treeExplorerViewlet.tree": "Seção do Explorador da Ãrvore" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/browser/dependenciesViewer.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/browser/dependenciesViewer.i18n.json new file mode 100644 index 00000000000..0ebd24a9fd8 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/browser/dependenciesViewer.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "error": "Erro", + "Unknown Dependency": "Dependência Desconhecida:" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json new file mode 100644 index 00000000000..1a3b9d4cd09 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json @@ -0,0 +1,39 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "name": "Nome da extensão", + "extension id": "Identificador da extensão", + "publisher": "Nome do editor", + "install count": "Quantidade de Instalações", + "rating": "Avaliação", + "license": "Licença", + "details": "Detalhes", + "contributions": "Contribuições", + "changelog": "Registro de Alterações", + "dependencies": "Dependências", + "noReadme": "README não disponível.", + "noChangelog": "Registro de Alterações não disponível.", + "noContributions": "Sem Contribuições", + "noDependencies": "Sem Dependências", + "settings": "Configurações ({0})", + "setting name": "Nome", + "description": "Descrição", + "default": "Valor padrão", + "debuggers": "Depuradores ({0})", + "debugger name": "Nome", + "themes": "Temas ({0})", + "JSON Validation": "Validação JSON ({0})", + "commands": "Comandos ({0})", + "command name": "Nome", + "keyboard shortcuts": "Atalhos de Teclado", + "menuContexts": "Contextos de Menu", + "languages": "Linguagens ({0})", + "language id": "ID", + "language name": "Nome", + "file extensions": "Extensões de Arquivo", + "grammar": "Gramática", + "snippets": "Trechos" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json new file mode 100644 index 00000000000..e2ff606a7c9 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json @@ -0,0 +1,55 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "installAction": "Instalar", + "installing": "Instalando", + "uninstallAction": "Desinstalar", + "Uninstalling": "Desinstalando", + "updateAction": "Atualizar", + "updateTo": "Atualizar para {0}", + "enableForWorkspaceAction.label": "Habilitar (Espaço de Trabalho)", + "enableAlwaysAction.label": "Habilitar (Sempre)", + "disableForWorkspaceAction.label": "Desabilitar (Espaço de Trabalho)", + "disableAlwaysAction.label": "Desabilitar (Sempre)", + "ManageExtensionAction.uninstallingTooltip": "Desinstalando", + "enableForWorkspaceAction": "Espaço de trabalho", + "enableGloballyAction": "Sempre", + "enableAction": "Habilitar", + "disableForWorkspaceAction": "Espaço de trabalho", + "disableGloballyAction": "Sempre", + "disableAction": "Desabilitar", + "checkForUpdates": "Verificar Atualizações", + "updateAll": "Atualizar Todas as Extensões", + "reloadAction": "Recarregar", + "postUpdateTooltip": "Recarregar para atualizar", + "postUpdateMessage": "Recarregar esta janela para ativar a extensão atualizada '{0}'?", + "postEnableTooltip": "Recarregar para ativar", + "postEnableMessage": "Recarregar esta janela para ativar a extensão '{0}'?", + "postDisableTooltip": "Recarregar para desativar", + "postDisableMessage": "Recarregar esta janela para desativar a extensão '{0}'?", + "postUninstallTooltip": "Recarregar para desativar", + "postUninstallMessage": "Recarregar esta janela para desativar a extensão desinstalada '{0}'?", + "reload": "&&Recarregar Janela", + "toggleExtensionsViewlet": "Mostrar Extensões", + "installExtensions": "Instalar Extensões", + "showInstalledExtensions": "Mostrar Extensões Instaladas", + "showDisabledExtensions": "Mostrar Extensões Desabilitadas", + "clearExtensionsInput": "Limpar Entrada de Extensões", + "showOutdatedExtensions": "Mostrar Extensões Desatualizadas", + "showPopularExtensions": "Mostrar Extensões Populares", + "showRecommendedExtensions": "Mostrar Extensões Recomendadas", + "showWorkspaceRecommendedExtensions": "Mostrar Extensões Recomendadas para o Espaço de Trabalho", + "showRecommendedKeymapExtensions": "Mostrar Mapeamentos de Teclado Recomendados", + "showRecommendedKeymapExtensionsShort": "Mapeamentos de Teclado", + "configureWorkspaceRecommendedExtensions": "Configurar Extensões Recomendadas (Espaço de Trabalho)", + "ConfigureWorkspaceRecommendations.noWorkspace": "As recomendações somente estão disponíveis em uma pasta do espaço de trabalho.", + "OpenExtensionsFile.failed": "Não foi possível criar o arquivo 'extensions.json' na pasta '.vscode' ({0}).", + "builtin": "Intrínseco", + "disableAll": "Desabilitar Todas as Extensões Instaladas", + "disableAllWorkspace": "Desabilitar Todas as Extensões Instaladas para este Espaço de Trabalho", + "enableAll": "Habilitar Todas as Extensões Instaladas", + "enableAllWorkspace": "Habilitar Todas as Extensões Instaladas para este Espaço de Trabalho" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionsQuickOpen.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionsQuickOpen.i18n.json new file mode 100644 index 00000000000..666a6692179 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionsQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "manage": "Pressione Enter para gerenciar suas extensões.", + "searchFor": "Pressione Enter para pesquisar por '{0}' na Loja.", + "noExtensionsToInstall": "Digite um nome de extensão" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/common/extensionsFileTemplate.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/common/extensionsFileTemplate.i18n.json new file mode 100644 index 00000000000..b90c0d5ac64 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/common/extensionsFileTemplate.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "app.extensions.json.title": "Extensões", + "app.extensions.json.recommendations": "Lista de recomendações de extensões. O identificador de uma extensão é sempre ' ${publisher}. ${nome}'. Por exemplo: 'vscode.csharp'.", + "app.extension.identifier.errorMessage": "Formato esperado '${editor}.${nome}'. Exemplo: 'vscode.csharp'." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/common/extensionsInput.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/common/extensionsInput.i18n.json new file mode 100644 index 00000000000..333627e9619 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/common/extensionsInput.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "extensionsInputName": "Extensão: {0}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json new file mode 100644 index 00000000000..663560d4d78 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "reallyRecommended2": "A extensão {0} é recomendada para este tipo de arquivo.", + "showRecommendations": "Mostrar Recomendações", + "neverShowAgain": "Não mostrar novamente", + "close": "Fechar", + "workspaceRecommended": "Este espaço de trabalho possui recomendações de extensão.", + "ignoreExtensionRecommendations": "Deseja ignorar todas as recomendações de extensão?", + "ignoreAll": "Sim, Ignorar Tudo", + "no": "Não", + "cancel": "Cancelar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json new file mode 100644 index 00000000000..76bf0379481 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "extensionsCommands": "Gerenciar Extensões", + "galleryExtensionsCommands": "Instalar Extensões da Galeria", + "extension": "Extensão", + "extensions": "Extensões", + "view": "Exibir", + "extensionsConfigurationTitle": "Extensões", + "extensionsAutoUpdate": "Atualizar extensões automaticamente", + "extensionsIgnoreRecommendations": "Ignorar recomendações de extensão" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsActions.i18n.json new file mode 100644 index 00000000000..731e4ef9491 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsActions.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openExtensionsFolder": "Abrir a Pasta de Extensões", + "installVSIX": "Instalar do VSIX...", + "InstallVSIXAction.success": "A extensão foi instalada com sucesso. Reinicie para habilitá-la.", + "InstallVSIXAction.reloadNow": "Recarregar Agora" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json new file mode 100644 index 00000000000..0cde76b12d8 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "disableOtherKeymapsConfirmation": "Desabilitar outros mapeamentos de teclado para evitar conflitos entre mapeamentos de teclado?", + "yes": "Sim", + "no": "Não" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.i18n.json new file mode 100644 index 00000000000..a35f8bbe6c6 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "searchExtensions": "Pesquisar Extensões na Loja", + "extensions": "Extensões", + "sort by installs": "Ordenar por: Quantidade de Instalações", + "sort by rating": "Ordenar por: Avaliação", + "sort by name": "Ordenar por: Nome", + "no extensions found": "Nenhuma extensão encontrada.", + "suggestProxyError": "A Loja retornou 'ECONNREFUSED'. Por favor, verifique a configuração de 'http.proxy'.", + "outdatedExtensions": "{0} Extensões Desatualizadas" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.i18n.json new file mode 100644 index 00000000000..f0313c20343 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "enableDependeciesConfirmation": "Habilitando '{0}' também habilita suas dependências. Gostaria de continuar?", + "enable": "Sim", + "doNotEnable": "Não", + "disableDependeciesConfirmation": "Gostaria de desabilitar somente '{0}', ou as suas dependências também?", + "disableOnly": "Apenas", + "disableAll": "Todos", + "cancel": "Cancelar", + "singleDependentError": "Não é possível desabilitar a extensão '{0}'. A extensão '{1}' depende dela.", + "twoDependentsError": "Não é possível desabilitar a extensão '{0}'. As extensões '{1}' e '{2}' dependem dela.", + "multipleDependentsError": "Não é possível desabilitar a extensão '{0}'. As extensões '{1}', '{2}' e outras dependem dela." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/feedback/electron-browser/feedback.i18n.json b/i18n/ptb/src/vs/workbench/parts/feedback/electron-browser/feedback.i18n.json new file mode 100644 index 00000000000..5d3c22c39a8 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/feedback/electron-browser/feedback.i18n.json @@ -0,0 +1,25 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "sendFeedback": "Tweetar Feedback", + "label.sendASmile": "Tweete feedback para nós", + "patchedVersion1": "Sua instalação está corrompida.", + "patchedVersion2": "Por favor especificar isso ao enviar um bug.", + "sentiment": "Como foi sua experiência?", + "smileCaption": "Feliz", + "frownCaption": "Triste", + "other ways to contact us": "Outras maneiras de nos contatar", + "submit a bug": "Submeter um bug", + "request a missing feature": "Solicitar um recurso ausente", + "tell us why?": "Diga-nos porquê?", + "commentsHeader": "Comentários", + "tweet": "Tweetar", + "character left": "caractere à esquerda", + "characters left": "caracteres à esquerda", + "feedbackSending": "Enviando", + "feedbackSent": "Obrigado", + "feedbackSendingError": "Tentar novamente" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/editors/binaryFileEditor.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/editors/binaryFileEditor.i18n.json new file mode 100644 index 00000000000..9c33fd25246 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/editors/binaryFileEditor.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "binaryFileEditor": "Visualizador de Arquivo Binário" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/editors/textFileEditor.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/editors/textFileEditor.i18n.json new file mode 100644 index 00000000000..792781bc8c7 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/editors/textFileEditor.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "textFileEditor": "Editor de Arquivo de Texto", + "createFile": "Criar arquivo", + "fileEditorWithInputAriaLabel": "{0}. Editor de Arquivo de Texto.", + "fileEditorAriaLabel": "Editor de Arquivo de Texto" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/fileActions.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/fileActions.contribution.i18n.json new file mode 100644 index 00000000000..f203671c230 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/fileActions.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "filesCategory": "Arquivos", + "revealInSideBar": "Revelar na Barra Lateral", + "acceptLocalChanges": "Usar mudanças locais e sobrescrever o conteúdo do disco", + "revertLocalChanges": "Descartar mudanças locais e reverter para conteúdo do disco" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/fileActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/fileActions.i18n.json new file mode 100644 index 00000000000..161e7a9a16c --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/fileActions.i18n.json @@ -0,0 +1,73 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "retry": "Tentar novamente", + "rename": "Renomear", + "newFile": "Novo Arquivo", + "newFolder": "Nova Pasta", + "openFolderFirst": "Abrir uma pasta primeiro para criar arquivos ou pastas dentro dele.", + "newUntitledFile": "Novo Arquivo Sem Título", + "createNewFile": "Novo Arquivo", + "createNewFolder": "Nova Pasta", + "deleteButtonLabelRecycleBin": "&&Mover para Lixeira", + "deleteButtonLabelTrash": "&&Mover para o Lixo", + "deleteButtonLabel": "&&Excluir", + "dirtyMessageFolderOneDelete": "Você está excluindo uma pasta com alterações não salvas em 1 arquivo. Você quer continuar?", + "dirtyMessageFolderDelete": "Você está excluindo uma pasta com alterações não salvas em {0} arquivos. Você quer continuar?", + "dirtyMessageFileDelete": "Você está excluindo um arquivo com alterações não salvas. Você quer continuar?", + "dirtyWarning": "Suas alterações serão perdidas se você não salvá-las.", + "confirmMoveTrashMessageFolder": "Tem certeza de que deseja excluir '{0}' e seu conteúdo?", + "confirmMoveTrashMessageFile": "Tem certeza de que deseja excluir '{0}'?", + "undoBin": "Você pode restaurar da lixeira.", + "undoTrash": "Você pode restaurar a partir do lixo.", + "confirmDeleteMessageFolder": "Tem certeza de que deseja excluir permanentemente '{0}' e seu conteúdo?", + "confirmDeleteMessageFile": "Tem certeza de que deseja excluir permanentemente '{0}'?", + "irreversible": "Esta ação é irreversível!", + "permDelete": "Excluir permanentemente", + "delete": "Excluir", + "importFiles": "Importar Arquivos", + "confirmOverwrite": "Um arquivo ou pasta com o mesmo nome já existe na pasta de destino. Você quer substituí-lo?", + "replaceButtonLabel": "&&Substituir", + "copyFile": "Copiar", + "pasteFile": "Colar", + "duplicateFile": "Duplicar", + "openToSide": "Aberto para o lado", + "compareSource": "Selecione para comparar", + "globalCompareFile": "Compare o Arquivo Ativo Com...", + "pickHistory": "Selecione um arquivo previamente aberto para comparar com", + "unableToFileToCompare": "O arquivo selecionado não pode ser comparado com '{0}'.", + "openFileToCompare": "Abrir um arquivo primeiro para compará-lo com outro arquivo.", + "compareWith": "Comparar com '{0}'", + "compareFiles": "Comparar Arquivos", + "refresh": "Atualizar", + "save": "Salvar", + "saveAs": "Salvar como...", + "saveAll": "Salvar Todos", + "saveAllInGroup": "Salvar Todos no Grupo", + "saveFiles": "Salvar Arquivos Sujos", + "revert": "Reverter Arquivo", + "focusOpenEditors": "Foco na Visualização dos Editores Abertos", + "focusFilesExplorer": "Foco no Explorador de Arquivos", + "showInExplorer": "Revelar o Arquivo Ativo na Barra Lateral", + "openFileToShow": "Abrir um arquivo primeiro para mostrá-lo no explorer", + "collapseExplorerFolders": "Esconder Pastas no Explorador", + "refreshExplorer": "Atualizar Explorador", + "openFile": "Abrir arquivo...", + "openFileInNewWindow": "Abrir o Arquivo Ativo em uma Nova Janela", + "openFileToShowInNewWindow": "Abrir um arquivo primeiro para abrir em uma nova janela", + "revealInWindows": "Revelar no Explorer", + "revealInMac": "Revelar no Finder", + "openContainer": "Abrir a Pasta", + "revealActiveFileInWindows": "Revelar Arquivo Ativo no Windows Explorer", + "revealActiveFileInMac": "Revelar Arquivo Ativo no Finder", + "openActiveFileContainer": "Abrir a Pasta do Arquivo Ativo.", + "copyPath": "Copiar Caminho", + "copyPathOfActive": "Copiar Caminho do Arquivo Ativo", + "emptyFileNameError": "Um nome de arquivo ou pasta deve ser fornecido.", + "fileNameExistsError": "Um arquivo ou pasta **{0}** já existe neste local. Escolha um nome diferente.", + "invalidFileNameError": "O nome **{0}** não é válido como um nome de arquivo ou pasta. Por favor, escolha um nome diferente.", + "filePathTooLongError": "O nome **{0}** resulta em um caminho muito longo. Escolha um nome mais curto." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/fileCommands.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/fileCommands.i18n.json new file mode 100644 index 00000000000..2e61a1656c8 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/fileCommands.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openFileToCopy": "Abrir um arquivo primeiro para copiar seu caminho", + "openFileToReveal": "Abrir um arquivo primeiro para revelar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/files.contribution.i18n.json new file mode 100644 index 00000000000..ddbc9408f54 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -0,0 +1,40 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "showExplorerViewlet": "Mostrar Explorer", + "explore": "Explorador", + "view": "Exibir", + "textFileEditor": "Editor de Arquivo de Texto", + "binaryFileEditor": "Editor de Arquivo Binário", + "filesConfigurationTitle": "Arquivos", + "exclude": "Configure os padrões glob para excluir arquivos e pastas.", + "files.exclude.boolean": "O padrão glob com o qual combinar os caminhos de arquivo. Defina para verdadeiro ou falso para habilitar ou desabilitar o padrão.", + "files.exclude.when": "Verificação adicional nos irmãos de um arquivo correspondente. Use $(basename) como variável para o nome do arquivo correspondente.", + "associations": "Configurar as associações de arquivo para linguagens (por exemplo, \"* Extension\": \"html\"). Estas têm precedência sobre as associações padrão das linguagens instaladas.", + "encoding": "A codificação padrão do conjunto de caracteres para ser usada ao ler e gravar arquivos.", + "autoGuessEncoding": "Quando habilitado, tentará adivinhar a codificação do conjunto de caracteres ao abrir arquivos", + "trimTrailingWhitespace": "Quando habilitado, removerá espaços em branco à direita ao salvar um arquivo.", + "insertFinalNewline": "Quando habilitado, inseririrá uma nova linha no final do arquivo quando salvá-lo.", + "files.autoSave.off": "Um arquivo sujo nunca é automaticamente salvo.", + "files.autoSave.afterDelay": "Um arquivo sujo é salvo automaticamente após configurado em 'files.autoSaveDelay'.", + "files.autoSave.onFocusChange": "Um arquivo sujo é salvo automaticamente quando o editor perde o foco.", + "files.autoSave.onWindowChange": "Um arquivo sujo é salvo automaticamente quando a janela perde o foco.", + "autoSave": "Controla o auto-salvamento de arquivos sujos. Aceita os valores: '{0}', '{1}', '{2}' (editor perde o foco), '{3}' (janela perde o foco). Se definido como '{4}', você pode configurar o atraso em 'files.autoSaveDelay'.", + "autoSaveDelay": "Controla o atraso em milissegundos depois que um arquivo sujo é salvo automaticamente. Só se aplica quando 'files.autoSave' for definida como '{0}'", + "watcherExclude": "Configure padrões glob de caminhos de arquivo para excluir do monitoramento de arquivos. Alterar essa configuração requer uma reinicialização. Quando você tiver consumo Code muito alto de cpu na inicialização, você pode excluir pastas grandes para reduzir a carga inicial.", + "hotExit.off": "Desabilitar a saída à quente.", + "hotExit.onExit": "Saída à quente será acionada quando o aplicativo for fechado, ou seja, quando a última janela é fechada no Windows/Linux ou quando o comando workbench.action.quit é acionado (paleta de comandos, keybinding, menu). Todas as janelas com backups serão restauradas na próxima execução.", + "hotExit.onExitAndWindowClose": "Saída à quente será acionada quando o aplicativo for fechado, ou seja, quando a última janela é fechada no Windows/Linux ou quando o comando workbench.action.quit é acionado (paleta de comando, keybinding, menu), e também para qualquer janela com uma pasta aberta independentemente se é a última janela. Todas as janelas sem pastas abertas serão restauradas na próxima execução. Para restaurar as janelas de pastas como eram antes do desligamento configure \"window.reopenFolders\" para \"todos\".", + "hotExit": "Controla se os arquivos não salvos são lembrados entre as sessões, permitindo salvar alerta ao sair do editor seja ignorada.", + "defaultLanguage": "O modo de linguagem padrão que é atribuída para novos arquivos.", + "editorConfigurationTitle": "Editor", + "formatOnSave": "Formata um arquivo no salvamento. Um formatador deve estar disponível, o arquivo não deve ser salvo automaticamente e editor não deve ser desligado.", + "explorerConfigurationTitle": "Explorador de arquivos", + "openEditorsVisible": "Número de editores mostrado no painel Abrir Editores. Configurá-lo para 0 irá ocultar o painel.", + "dynamicHeight": "Controla se a altura da seção de editores abertos deve adaptar-se dinamicamente para o número de elementos ou não.", + "autoReveal": "Controla se o explorador deve automaticamente revelar e selecionar arquivos ao abri-los.", + "enableDragAndDrop": "Controla se o explorador deve permitir mover arquivos e pastas através de arrastar e soltar." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/saveErrorHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/saveErrorHandler.i18n.json new file mode 100644 index 00000000000..30a0a48f866 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/saveErrorHandler.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "discard": "Descartar", + "overwrite": "Sobrescrever", + "retry": "Tentar novamente", + "readonlySaveError": "Falha ao salvar '{0}': O arquivo está protegido contra gravação. Selecione 'Substituir' para remover a proteção.", + "genericSaveError": "Erro ao salvar '{0}': {1}", + "staleSaveError": "Falha ao salvar '{0}': O conteúdo no disco é mais recente. Clique em **Comparar** para comparar a sua versão com a do disco.", + "compareChanges": "Comparar", + "saveConflictDiffLabel": "{0} (no disco) ↔ {1} (em {2}) - Resolver conflitos de salvamento", + "userGuide": "Use as ações na barra de ferramentas do editor para **desfazer** suas alterações ou **substituir** o conteúdo no disco com as suas alterações" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json new file mode 100644 index 00000000000..58da5446b25 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "explorerSection": "Seção de Explorador de Arquivos", + "noWorkspace": "Nenhuma Pasta Aberta", + "noWorkspaceHelp": "Você ainda não abriu uma pasta.", + "openFolder": "Abrir Pasta" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/views/explorerView.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/views/explorerView.i18n.json new file mode 100644 index 00000000000..4753a88bd4c --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/views/explorerView.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "explorerSection": "Seção de Explorador de Arquivos", + "treeAriaLabel": "Explorador de Arquivos" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/views/explorerViewer.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/views/explorerViewer.i18n.json new file mode 100644 index 00000000000..c670883e6ac --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/views/explorerViewer.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "fileInputAriaLabel": "Digite o Nome do arquivo. Pressione Enter para confirmar ou Escape para cancelar.", + "filesExplorerViewerAriaLabel": "{0}, Explorador de Arquivos", + "confirmOverwriteMessage": "'{0}' já existe na pasta de destino. Deseja substituí-lo?", + "irreversible": "Esta ação é irreversível!", + "replaceButtonLabel": "&&Substituir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json new file mode 100644 index 00000000000..4db9c1f34d8 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openEditosrSection": "Abrir Seção de Editores", + "openEditors": "Abrir Editores", + "treeAriaLabel": "Abrir Editores: Lista de Arquivos Ativos", + "dirtyCounter": "{0} não salvos" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsViewer.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsViewer.i18n.json new file mode 100644 index 00000000000..dbef8f2ddb5 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsViewer.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorGroupAriaLabel": "{0}, Agrupar Editor", + "openEditorAriaLabel": "{0}, Abrir Editor", + "saveAll": "Salvar Todos", + "closeAll": "Fechar todos", + "close": "Fechar", + "closeOthers": "Fechar Outros" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/common/dirtyFilesTracker.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/common/dirtyFilesTracker.i18n.json new file mode 100644 index 00000000000..9e75b7b2a89 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/common/dirtyFilesTracker.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "dirtyFiles": "{0} arquivos não salvos" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json new file mode 100644 index 00000000000..f29992f5d95 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "orphanedFile": "{0} (excluído do disco)" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/html/browser/html.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/html/browser/html.contribution.i18n.json new file mode 100644 index 00000000000..f9530b0f6f6 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/html/browser/html.contribution.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "html.editor.label": "Visualização Html" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/html/browser/htmlPreviewPart.i18n.json b/i18n/ptb/src/vs/workbench/parts/html/browser/htmlPreviewPart.i18n.json new file mode 100644 index 00000000000..8df4c48f58c --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/html/browser/htmlPreviewPart.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "html.voidInput": "Entrada inválida do editor." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/html/browser/webview.i18n.json b/i18n/ptb/src/vs/workbench/parts/html/browser/webview.i18n.json new file mode 100644 index 00000000000..2ef4463deb9 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/html/browser/webview.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "devtools.webview": "Desenvolvedor: Ferramentas Webview" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/markers/common/messages.i18n.json b/i18n/ptb/src/vs/workbench/parts/markers/common/messages.i18n.json new file mode 100644 index 00000000000..8576955d609 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/markers/common/messages.i18n.json @@ -0,0 +1,39 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "viewCategory": "Exibir", + "problems.view.show.label": "Mostrar Problemas", + "problems.panel.configuration.title": "Visualização de Problemas", + "problems.panel.configuration.autoreveal": "Controla se a visaulização de problemas evela os arquivos automaticamente ao abri-los", + "markers.panel.title.problems": "Problemas", + "markers.panel.aria.label.problems.tree": "Problemas agrupados por arquivos", + "markers.panel.no.problems.build": "Nenhum problema foi detectado na área de trabalho até agora.", + "markers.panel.no.problems.filters": "Nenhum resultado encontrado com os critérios de filtro fornecidos", + "markers.panel.action.filter": "Problemas de Filtro", + "markers.panel.filter.placeholder": "Filtrar por tipo ou texto", + "markers.panel.filter.errors": "erros", + "markers.panel.filter.warnings": "avisos", + "markers.panel.filter.infos": "informações", + "markers.panel.single.error.label": "1 Erro", + "markers.panel.multiple.errors.label": "{0} Erros", + "markers.panel.single.warning.label": "1 Aviso", + "markers.panel.multiple.warnings.label": "{0} Avisos", + "markers.panel.single.info.label": "1 Informação", + "markers.panel.multiple.infos.label": "{0} Informações", + "markers.panel.single.unknown.label": "1 Desconhecido", + "markers.panel.multiple.unknowns.label": "{0} Desconhecidos", + "markers.panel.at.ln.col.number": "({0}, {1})", + "problems.tree.aria.label.resource": "{0} com {1} problemas", + "problems.tree.aria.label.error.marker": "Erro gerado por {0}: {1} na linha {2} e caractere {3}", + "problems.tree.aria.label.error.marker.nosource": "Erro: {0} na linha {1} e caractere {2}", + "problems.tree.aria.label.warning.marker": "Aviso gerado por {0}: {1} na linha {2} e caractere {3}", + "problems.tree.aria.label.warning.marker.nosource": "Aviso: {0} na linha {1} e caractere {2}", + "problems.tree.aria.label.info.marker": "Informação gerada por {0}: {1} na linha {2} e caractere {3}", + "problems.tree.aria.label.info.marker.nosource": "Informação: {0} na linha {1} e caractere {2}", + "problems.tree.aria.label.marker": "Problema gerado por {0}: {1} na linha {2} e caractere {3}", + "problems.tree.aria.label.marker.nosource": "Problema: {0} na linha {1} e caractere {2}", + "errors.warnings.show.label": "Mostrar Erros e Avisos" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/markers/electron-browser/markersElectronContributions.i18n.json b/i18n/ptb/src/vs/workbench/parts/markers/electron-browser/markersElectronContributions.i18n.json new file mode 100644 index 00000000000..027c80cca30 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/markers/electron-browser/markersElectronContributions.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "copyMarker": "Copiar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/nps/electron-browser/nps.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/nps/electron-browser/nps.contribution.i18n.json new file mode 100644 index 00000000000..1ec18c632a4 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/nps/electron-browser/nps.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "surveyQuestion": "Você deseja responder a uma pequena pesquisa?", + "takeSurvey": "Responder a pesquisa", + "remindLater": "Lembrar mais tarde", + "neverAgain": "Não mostrar novamente" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/output/browser/output.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/output/browser/output.contribution.i18n.json new file mode 100644 index 00000000000..e36bdadf4e9 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/output/browser/output.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "output": "Saída", + "viewCategory": "Exibir", + "clearOutput.label": "Limpar saída" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/output/browser/outputActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/output/browser/outputActions.i18n.json new file mode 100644 index 00000000000..00bca0dc309 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/output/browser/outputActions.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleOutput": "Alternar Saída", + "clearOutput": "Limpar saída", + "toggleOutputScrollLock": "Alternar Scroll Lock de Saída", + "switchToOutput.label": "Mudar para Saída" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/output/browser/outputPanel.i18n.json b/i18n/ptb/src/vs/workbench/parts/output/browser/outputPanel.i18n.json new file mode 100644 index 00000000000..ec28fd7b2a3 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/output/browser/outputPanel.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "outputPanelWithInputAriaLabel": "{0}, Painel de saída", + "outputPanelAriaLabel": "Painel de saída" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/output/common/output.i18n.json b/i18n/ptb/src/vs/workbench/parts/output/common/output.i18n.json new file mode 100644 index 00000000000..a083a6e7d9d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/output/common/output.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "output": "Saída", + "channel": "para '{0}'" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json new file mode 100644 index 00000000000..5fda62eb168 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "slow": "Inicialização lenta detectada", + "slow.detail": "Pena que você teve uma inicialização lenta. Por favor reinicie '{0}' com perfil de desempenho habilitado, compartilhe os perfis conosco e nós trabalharemos duro para fazer com que a inicialização fique perfeita novamente.", + "prof.message": "Perfis criados com sucesso.", + "prof.detail": "Por favor, crie um problema e anexe manualmente os seguintes arquivos:\n{0}", + "prof.restartAndFileIssue": "Criar Problema e Reiniciar", + "prof.restart": "Reiniciar", + "prof.thanks": "Obrigado por nos ajudar.", + "prof.detail.restart": "É necessário um reinício final para continuar a usar '{0}'. Novamente, obrigado pela sua contribuição." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingWidgets.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingWidgets.i18n.json new file mode 100644 index 00000000000..279307d4b87 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingWidgets.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defineKeybinding.initial": "Pressionar a combinação de teclas desejada e ENTER. ESCAPE para cancelar.", + "defineKeybinding.chordsTo": "Acorde para" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json new file mode 100644 index 00000000000..1cb6541687c --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json @@ -0,0 +1,35 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "keybindingsInputName": "Atalhos de Teclado", + "SearchKeybindings.AriaLabel": "Pesquisar keybindings", + "SearchKeybindings.Placeholder": "Pesquisar keybindings", + "sortByPrecedene": "Ordenar por precedência", + "header-message": "Para personalizações avançadas abrir e editar", + "keybindings-file-name": "keybindings.json", + "keybindingsLabel": "Keybindings", + "changeLabel": "Alterar Keybinding", + "addLabel": "Adicionar Keybinding", + "removeLabel": "Remover Keybinding", + "resetLabel": "Redefinir Keybinding", + "showConflictsLabel": "Mostrar Conflitos", + "copyLabel": "Copiar", + "error": "Erro '{0}' enquanto edita keybinding. Por favor, abra o arquivo 'keybindings.json' e verifique.", + "command": "Comando", + "keybinding": "KeyBinding", + "source": "Fonte", + "when": "Quando", + "editKeybindingLabelWithKey": "Alterar Keybinding {0}", + "editKeybindingLabel": "Alterar Keybinding", + "addKeybindingLabelWithKey": "Adicionar Keybinding {0}", + "addKeybindingLabel": "Adicionar Keybinding", + "commandAriaLabel": "Comando é {0}.", + "keybindingAriaLabel": "KeyBinding é {0}.", + "noKeybinding": "Nenhum Keybinding atribuído.", + "sourceAriaLabel": "Fonte é {0}.", + "whenAriaLabel": "Quando é {0}.", + "noWhen": "Sem contexto Quando." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json new file mode 100644 index 00000000000..15fd432f9fa --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defineKeybinding.start": "Definir Keybinding", + "defineKeybinding.kbLayoutInfoMessage": "Para o seu layout de teclado atual pressionar", + "defineKeybinding.kbLayoutErrorMessage": "Você não será capaz de produzir esta combinação de teclas sob seu layout de teclado atual." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferences.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferences.contribution.i18n.json new file mode 100644 index 00000000000..40e6d0841da --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferences.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defaultPreferencesEditor": "Editor de Preferências Padrão", + "keybindingsEditor": "Editor de Keybindings", + "preferences": "Preferências" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json new file mode 100644 index 00000000000..461e0fb96f7 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openGlobalSettings": "Abra as Configurações de Usuário", + "openGlobalKeybindings": "Abrir Atalhos de Teclado", + "openGlobalKeybindingsFile": "Abrir Arquivo de Atalhos de Teclado", + "openWorkspaceSettings": "Abrir as configurações do espaço de trabalho", + "configureLanguageBasedSettings": "Definir Configurações Específicas de Linguagem...", + "languageDescriptionConfigured": "({0})", + "pickLanguage": "Selecionar Linguagem" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesEditor.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesEditor.i18n.json new file mode 100644 index 00000000000..e3ef1e68a73 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesEditor.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "settingsEditorName": "Configurações Padrão", + "SearchSettingsWidget.AriaLabel": "Configurações de Pesquisa", + "SearchSettingsWidget.Placeholder": "Configurações de Pesquisa", + "totalSettingsMessage": "Total {0} Configurações", + "noSettingsFound": "Nenhum resultado", + "oneSettingFound": "1 Configuração correspondente", + "settingsFound": "{0} Configurações correspondentes", + "preferencesAriaLabel": "Preferências padrão. Editor de texto somente leitura." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json new file mode 100644 index 00000000000..e35427eb2df --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "errorInvalidConfiguration": "Não é possível gravar em configurações. Corrija erros/avisos no arquivo e tente novamente.", + "editTtile": "Editar", + "replaceDefaultValue": "Substituir nas Configurações", + "copyDefaultValue": "Copiar para Configurações", + "unsupportedPHPExecutablePathSetting": "Essa configuração deve ser uma Configuração de Usuário. Para configurar o PHP para o espaço de trabalho, abra um arquivo PHP e clique em 'Caminho do PHP' na barra de status.", + "unsupportedWorkspaceSetting": "Essa configuração deve ser uma Configuração de Usuário." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesService.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesService.i18n.json new file mode 100644 index 00000000000..3d94af63615 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesService.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openFolderFirst": "Abrir uma pasta primeiro para criar configurações de espaço de trabalho", + "emptyKeybindingsHeader": "Coloque suas chaves de ligações neste arquivo para substituir os padrões", + "defaultKeybindings": "Keybindings Padrão", + "emptySettingsHeader": "Colocar suas configurações nesse arquivo para sobrecrever as configurações padrão", + "emptySettingsHeader1": "Colocar as suas configurações nesse arquivo para sobrescrever as configurações e usuário padrão.", + "fail.createSettings": "Não foi possível criar '{0}' ({1})." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesWidgets.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesWidgets.i18n.json new file mode 100644 index 00000000000..556ef65c079 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesWidgets.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "settingsSwitcherBarAriaLabel": "Chave de Configurações", + "userSettings": "Configurações de Usuário", + "workspaceSettings": "Configurações de Espaço de Trabalho" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.i18n.json new file mode 100644 index 00000000000..68e05e00daf --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "default": "Valor padrão", + "user": "Usuário", + "meta": "meta", + "option": "opção" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/common/preferencesModels.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/common/preferencesModels.i18n.json new file mode 100644 index 00000000000..6427118b75b --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/common/preferencesModels.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "commonlyUsed": "Comumente Utilizado", + "defaultKeybindingsHeader": "Substituir as chaves de ligações, colocando-os em seu arquivo de chave ligações." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json new file mode 100644 index 00000000000..7b246da25ad --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "showTriggerActions": "Mostrar todos os comandos", + "showCommands.label": "Paleta de comandos...", + "entryAriaLabelWithKey": "{0}, {1}, comandos", + "entryAriaLabel": "{0}, comandos", + "canNotRun": "O comando '{0}' não pode ser executado a partir daqui.", + "actionNotEnabled": "O comando '{0}' não está habilitado no contexto atual.", + "commandLabel": "{0}: {1}", + "cat.title": "{0}: {1}", + "noCommandsMatching": "Não há comandos correspondentes" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/quickopen/browser/gotoLineHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/gotoLineHandler.i18n.json new file mode 100644 index 00000000000..3f922e6deca --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/gotoLineHandler.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "gotoLine": "Ir para linha...", + "gotoLineLabelEmptyWithLimit": "Digite um número de linha entre 1 e {0} para navegar para lá", + "gotoLineLabelEmpty": "Digite um número de linha para navegar para lá", + "gotoLineColumnLabel": "Ir para linha {0} e caractere {1}", + "gotoLineLabel": "Ir para linha {0}", + "gotoLineHandlerAriaLabel": "Digite um número de linha para navegar.", + "cannotRunGotoLine": "Abrir um arquivo de texto primeiro para ir a uma linha" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/quickopen/browser/gotoSymbolHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/gotoSymbolHandler.i18n.json new file mode 100644 index 00000000000..5e56bdc5890 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/gotoSymbolHandler.i18n.json @@ -0,0 +1,34 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "gotoSymbol": "Ir para o Símbolo no Arquivo...", + "symbols": "símbolos ({0})", + "method": "métodos ({0})", + "function": "funções ({0})", + "_constructor": "construtores ({0})", + "variable": "variáveis ({0})", + "class": "classes ({0})", + "interface": "interfaces ({0})", + "namespace": "namespaces ({0})", + "package": "pacotes ({0})", + "modules": "módulos ({0})", + "property": "propriedades ({0})", + "enum": "enumerações ({0})", + "string": "cadeias de caracteres ({0})", + "rule": "regras ({0})", + "file": "arquivos ({0})", + "array": "matrizes ({0})", + "number": "números ({0})", + "boolean": "booleanos ({0})", + "object": "objetos ({0})", + "key": "chaves ({0})", + "entryAriaLabel": "{0}, símbolos", + "noSymbolsMatching": "Não há símbolos correspondentes", + "noSymbolsFound": "Nenhum símbolo encontrado", + "gotoSymbolHandlerAriaLabel": "Tipo para reduzir os símbolos do editor ativo atual.", + "cannotRunGotoSymbolInFile": "Não há informações de símbolo para o arquivo", + "cannotRunGotoSymbol": "Abrir um arquivo de texto primeiro para ir a um símbolo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/quickopen/browser/helpHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/helpHandler.i18n.json new file mode 100644 index 00000000000..0a2fc637f73 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/helpHandler.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, ajuda do seletor", + "globalCommands": "comandos globais", + "editorCommands": "comandos do editor" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.i18n.json new file mode 100644 index 00000000000..e3c6204b605 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "commandsHandlerDescriptionDefault": "Exibir e executar comandos", + "gotoLineDescriptionMac": "Ir para linha", + "gotoLineDescriptionWin": "Ir para linha", + "gotoSymbolDescription": "Ir para o Símbolo no Arquivo", + "gotoSymbolDescriptionScoped": "Ir para o Símbolo no Arquivo Por Categoria", + "helpDescription": "Mostrar ajuda", + "viewPickerDescription": "Abrir Visualização" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/quickopen/browser/viewPickerHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/viewPickerHandler.i18n.json new file mode 100644 index 00000000000..38804354794 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/viewPickerHandler.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, visualizar seletor", + "views": "Modos de exibição", + "panels": "Painéis", + "terminals": "Terminal", + "terminalTitle": "{0}: {1}", + "channels": "Saída", + "openView": "Abrir Visualização", + "quickOpenView": "Abrir Visualização Rápida" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json new file mode 100644 index 00000000000..1b5369ebeea --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleGitViewlet": "Mostrar Git", + "installAdditionalSCMProviders": "Instalar provedores de SCM adicionais...", + "source control": "Controle de código-fonte", + "toggleSCMViewlet": "Mostrar SCM", + "view": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmActivity.i18n.json b/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmActivity.i18n.json new file mode 100644 index 00000000000..7846e2b872d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmActivity.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "scmPendingChangesBadge": "{0} alterações pendentes" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json b/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json new file mode 100644 index 00000000000..5b93869e8d8 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "installAdditionalSCMProviders": "Instalar provedores de SCM adicionais...", + "switch provider": "Mudar Provedor SCM..." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmViewlet.i18n.json b/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmViewlet.i18n.json new file mode 100644 index 00000000000..c14da801978 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmViewlet.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "commitMessage": "Mensagem (tecle {0} para confirmar)", + "source control": "Controle de código-fonte", + "viewletTitle": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/search/browser/openAnythingHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/search/browser/openAnythingHandler.i18n.json new file mode 100644 index 00000000000..8d523511515 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/search/browser/openAnythingHandler.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "fileAndTypeResults": "resultados do arquivo e símbolo", + "fileResults": "resultados do arquivo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/search/browser/openFileHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/search/browser/openFileHandler.i18n.json new file mode 100644 index 00000000000..016a91f2c32 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/search/browser/openFileHandler.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, seletor de arquivo", + "searchResults": "resultados da pesquisa" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/search/browser/openSymbolHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/search/browser/openSymbolHandler.i18n.json new file mode 100644 index 00000000000..ede0a0c718d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/search/browser/openSymbolHandler.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, selecionador de símbolos", + "symbols": "resultados de símbolo", + "noSymbolsMatching": "Não há símbolos correspondentes", + "noSymbolsWithoutInput": "Digitar para pesquisar símbolos" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/search/browser/patternInputWidget.i18n.json b/i18n/ptb/src/vs/workbench/parts/search/browser/patternInputWidget.i18n.json new file mode 100644 index 00000000000..68c8c0ad6b7 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/search/browser/patternInputWidget.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defaultLabel": "entrada", + "patternDescription": "Use Padrões Glob", + "patternHelpInclude": "O padrão para combinações. Por exemplo, **\\*\\*/*.js** para corresponder a todos os arquivos JavaScript ou **myFolder/\\*\\*** para corresponder a essa pasta com todas pastas aninhadas.\n\n**Referência**:\n**\\*** corresponde a 0 ou mais caracteres\n**?** corresponde a 1 caractere\n**\\*\\*** corresponde a zero ou mais diretórios\n**[a-z]** corresponde a um intervalo de caracteres\n**{a, b}** corresponde a qualquer um dos padrões)", + "useIgnoreFilesDescription": "Usar Ignorar Arquivos", + "useExcludeSettingsDescription": "Usar Configurações de Exclusão" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/search/browser/replaceService.i18n.json b/i18n/ptb/src/vs/workbench/parts/search/browser/replaceService.i18n.json new file mode 100644 index 00000000000..05d7f4e4cd0 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/search/browser/replaceService.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "fileReplaceChanges": "{0} ↔ {1} (Substituir Preview)" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/search/browser/search.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/search/browser/search.contribution.i18n.json new file mode 100644 index 00000000000..b14e20a1487 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/search/browser/search.contribution.i18n.json @@ -0,0 +1,22 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "showTriggerActions": "Ir para Símbolo no Espaço de Trabalho...", + "name": "Pesquisar", + "showSearchViewlet": "Mostrar Busca", + "view": "Exibir", + "findInFiles": "Localizar nos Arquivos", + "openAnythingHandlerDescription": "Ir para o Arquivo", + "openSymbolDescriptionNormal": "Ir para o Símbolo em Ãrea de Trabalho", + "searchOutputChannelTitle": "Pesquisar", + "searchConfigurationTitle": "Pesquisar", + "exclude": "Configure os padrões glob para excluir arquivos e pastas nas pesquisas. Herda todos os padrões glob da configuração files.exclude.", + "exclude.boolean": "O padrão glob com o qual combinar os caminhos de arquivo. Defina para verdadeiro ou falso para habilitar ou desabilitar o padrão.", + "exclude.when": "Verificação adicional nos irmãos de um arquivo correspondente. Use $(basename) como variável para o nome do arquivo correspondente.", + "useRipgrep": "Controla se deve utilizar ripgrep na pesquisa de texto", + "useIgnoreFilesByDefault": "Controla se deve utilizar arquivos .gitignore e .ignore por padrão ao fazer pesquisas em um novo espaço de trabalho.", + "search.quickOpen.includeSymbols": "Configurar para incluir resultados de uma pesquisa símbolo global nos resultados do arquivo para Abertura Rápida." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/search/browser/searchActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/search/browser/searchActions.i18n.json new file mode 100644 index 00000000000..94f7c40e782 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/search/browser/searchActions.i18n.json @@ -0,0 +1,21 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "nextSearchTerm": "Mostrar o Próximo Termo de Pesquisa", + "previousSearchTerm": "Mostrar Termo de Pesquisa Anterior", + "focusNextInputBox": "Focalizar a Próxima Caixa de Entrada", + "focusPreviousInputBox": "Focalizar a Caixa de Entrada Anterior", + "replaceInFiles": "Substituir nos Arquivos", + "findInFolder": "Encontrar na pasta", + "RefreshAction.label": "Atualizar", + "ClearSearchResultsAction.label": "Limpar os Resultados da Pesquisa", + "FocusNextSearchResult.label": "Focalizar o Próximo Resultado da Pesquisa", + "FocusPreviousSearchResult.label": "Focalizar o Resultado da Pesquisa Anterior", + "RemoveAction.label": "Remover", + "file.replaceAll.label": "Substituir Tudo", + "match.replace.label": "Substituir", + "ConfigureGlobalExclusionsAction.label": "Abrir configurações" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json b/i18n/ptb/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json new file mode 100644 index 00000000000..3edda1861fb --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "searchMatches": "{0} correspondências encontradas", + "searchMatch": "{0} correspondência encontrada", + "fileMatchAriaLabel": "{0} correspondências no arquivo {1} da pasta {2}, Resultado da pesquisa", + "replacePreviewResultAria": "Substitua o termo {0} pelo termo {1} na coluna posição {2} correspondente ao texto {3}", + "searchResultAria": "Encontrado o termo {0} na posição da coluna {1} correspondente ao texto {2}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/search/browser/searchViewlet.i18n.json b/i18n/ptb/src/vs/workbench/parts/search/browser/searchViewlet.i18n.json new file mode 100644 index 00000000000..4ceea616010 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/search/browser/searchViewlet.i18n.json @@ -0,0 +1,50 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "moreSearch": "Alternar Detalhes da Pesquisa", + "searchScope.includes": "arquivos a serem incluídos", + "label.includes": "Pesquisa Padrões de Inclusão", + "searchScope.excludes": "arquivos a serem excluídos", + "label.excludes": "Pesquisa de Padrões de Exclusão", + "global.searchScope.folders": "arquivos excluídos pelas configurações", + "label.global.excludes": "Configurado pesquisa padrões de exclusão", + "replaceAll.confirmation.title": "Substituir Tudo", + "replaceAll.confirm.button": "Substituir", + "replaceAll.occurrence.file.message": "Substituída {0} ocorrência no arquivo {1} com '{2}'.", + "removeAll.occurrence.file.message": "Substituída {0} ocorrência no arquivo {1}'.", + "replaceAll.occurrence.files.message": "Substituída {0} ocorrência no arquivo {1} com '{2}'.", + "removeAll.occurrence.files.message": "Substituída {0} ocorrência nos arquivos {1}", + "replaceAll.occurrences.file.message": "Substituídas {0} ocorrências no arquivo {1} com '{2}'.", + "removeAll.occurrences.file.message": "Substituídas {0} ocorrências nos arquivo {1}.", + "replaceAll.occurrences.files.message": "Substituídas {0} ocorrências nos arquivos {1} com '{2}'.", + "removeAll.occurrences.files.message": "Substituídas {0} ocorrências nos arquivos {1}.", + "removeAll.occurrence.file.confirmation.message": "Substituir {0} ocorrências no arquivo {1} com '{2}'?", + "replaceAll.occurrence.file.confirmation.message": "Substituir {0} ocorrência no arquivo {1}?", + "removeAll.occurrence.files.confirmation.message": "Substituir {0} ocorrência nos arquivos {1} com '{2}'?", + "replaceAll.occurrence.files.confirmation.message": "Substituir {0} ocorrência nos arquivos {1}?", + "removeAll.occurrences.file.confirmation.message": "Substituir {0} ocorrências no arquivo {1} com '{2}'?", + "replaceAll.occurrences.file.confirmation.message": "Substituir {0} ocorrências no arquivo {1}?", + "removeAll.occurrences.files.confirmation.message": "Substituir {0} ocorrências nos arquivos {1} com '{2}'?", + "replaceAll.occurrences.files.confirmation.message": "Substituir {0} ocorrências nos arquivos {1}?", + "treeAriaLabel": "Resultados da Pesquisa", + "globLabel": "{0} quando {1}", + "searchMaxResultsWarning": "O conjunto de resultados contém apenas um subconjunto de todas as correspondências. Seja mais específico na sua pesquisa para diminuir o número de resultados.", + "searchCanceled": "Pesquisa foi cancelada antes de qualquer resultado ser encontrado - ", + "noResultsIncludesExcludes": "Nenhum resultado encontrado em '{0}' excluindo '{1}' - ", + "noResultsIncludes": "Nenhum resultado encontrado em '{0}' -", + "noResultsExcludes": "Nenhum resultado encontrado excluindo '{0}' -", + "noResultsFound": "Nenhum resultado encontrado. Analise as configurações para exclusões configuradas - ", + "rerunSearch.message": "Pesquisar novamente", + "rerunSearchInAll.message": "Pesquisar novamente em todos os arquivos", + "openSettings.message": "Abrir configurações", + "ariaSearchResultsStatus": "Pesquisa retornou {0} resultados em {1} arquivos", + "search.file.result": "{0} resultado no arquivo {1}", + "search.files.result": "{0} resultado nos arquivos {1}", + "search.file.results": "{0} resultados no arquivo {1}", + "search.files.results": "{0} resultados nos arquivos {1}", + "searchWithoutFolder": "Você ainda não abriu uma pasta. Somente arquivos abertos são pesquisados - ", + "openFolder": "Abrir Pasta" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/search/browser/searchWidget.i18n.json b/i18n/ptb/src/vs/workbench/parts/search/browser/searchWidget.i18n.json new file mode 100644 index 00000000000..41178af28cc --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/search/browser/searchWidget.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "search.action.replaceAll.disabled.label": "Substituir Todos (Submeter Pesquisa para Habilitar)", + "search.action.replaceAll.enabled.label": "Substituir Tudo", + "search.replace.toggle.button.title": "Alternar Substituir", + "label.Search": "Pesquisar: Digite o termo de pesquisa e pressione Enter para pesquisar ou Escape para cancelar", + "search.placeHolder": "Pesquisar", + "label.Replace": "Substituir: Digite o termo a ser substituído e pressione Enter para visualizar ou Escape para cancelar", + "search.replace.placeHolder": "Substituir", + "regexp.validationFailure": "A expressão corresponde a tudo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json new file mode 100644 index 00000000000..0f8e6360187 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.snippets": "Contribui aos trechos de código.", + "vscode.extension.contributes.snippets-language": "Identificador de linguagem para o qual este trecho de código contribui.", + "vscode.extension.contributes.snippets-path": "Caminho do arquivo de trechos de código. O caminho é relativo à pasta de extensão e normalmente começa com '. /snippets/'.", + "invalid.language": "Linguagem desconhecida em `contributes.{0}.language`. Valor fornecido: {1}", + "invalid.path.0": "Esperada uma string em `contributes.{0}.path`. Valor informado: {1}", + "invalid.path.1": "É esperado que `contributes.{0}.path` ({1}) seja incluído na pasta da extensão ({2}). Isto pode tornar a extensão não portável." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/insertSnippet.i18n.json b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/insertSnippet.i18n.json new file mode 100644 index 00000000000..6c34a620b89 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/insertSnippet.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "snippet.suggestions.label": "Inserir trecho de código" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json new file mode 100644 index 00000000000..05f799f7b6a --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openSnippet.label": "Abrir trechos de código do usuário", + "openSnippet.pickLanguage": "Selecionar Idioma para o Trecho", + "openSnippet.errorOnCreate": "Não é possível criar {0}", + "preferences": "Preferências", + "snippetSchema.json.default": "Trecho de código vazio", + "snippetSchema.json": "Configuração do trecho do usuário", + "snippetSchema.json.prefix": "O prefixo usado ao selecionar o trecho no intelliSense", + "snippetSchema.json.body": "O conteúdo do trecho de código. Use '${id}', '${id: rótulo}', '${1:label}' para variáveis e '$0', '$1' para posições do cursor", + "snippetSchema.json.description": "A descrição do trecho." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/snippetsService.i18n.json b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/snippetsService.i18n.json new file mode 100644 index 00000000000..a4a18c1e970 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/snippetsService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "detail.userSnippet": "Trecho de código do usuário", + "snippetSuggest.longLabel": "{0}, {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/tabCompletion.i18n.json b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/tabCompletion.i18n.json new file mode 100644 index 00000000000..adfb9a4190d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/tabCompletion.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tabCompletion": "Inserir trechos de código quando seu prefixo corresponder. Funciona melhor quando 'quickSuggestions' não está habilitado." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json new file mode 100644 index 00000000000..be3fefb5d3d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, tarefas", + "workspace": "Do espaço de trabalho", + "extension": "De extensões" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json new file mode 100644 index 00000000000..4009d3b8154 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksAriaLabel": "Digite o nome de uma tarefa para reiniciar", + "noTasksMatching": "Não há tarefas correspondentes", + "noTasksFound": "Não há tarefa para ser reiniciada" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json new file mode 100644 index 00000000000..6b4d6134384 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksAriaLabel": "Digite o nome de uma tarefa para executar", + "noTasksMatching": "Não há tarefas correspondentes", + "noTasksFound": "Não há tarefas encontradas" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.i18n.json new file mode 100644 index 00000000000..9c5ee4b4b59 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksAriaLabel": "Digite o nome de uma tarefa para finalizar", + "noTasksMatching": "Não há tarefas correspondentes", + "noTasksFound": "Nenhuma tarefa para finalizar encontrada" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json new file mode 100644 index 00000000000..2de0b161ac8 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ConfigurationParser.invalidCWD": "Aviso: options.cwd deve ser do tipo string. Ignorando valor {0}\n", + "ConfigurationParser.noShell": "Aviso: A configuração do shell somente é suportada quando estiver executando tarefas no terminal.", + "ConfigurationParser.noargs": "Erro: Argumentos do comando devem ser uma matriz de strings. Valor informado é:\n{0}", + "ConfigurationParser.noName": "Erro: Problem Matcher no escopo declarado deve ter um nome:\n{0}\n", + "ConfigurationParser.unknownMatcherKind": "Aviso: a correspondência de problema definido é desconhecido. Tipos suportados são string | ProblemMatcher | (string | ProblemMatcher)[].\n{0}\n", + "ConfigurationParser.invalidVaraibleReference": "Erro: ProblemMatcher inválido referência: {0}\n", + "ConfigurationParser.noTaskName": "Erro: tarefas devem fornecer uma propriedade taskName. A tarefa será ignorada.\n{0}\n", + "taskConfiguration.shellArgs": "Aviso: a tarefa '{0}' é um comando do shell e o nome de comando ou um dos seus argumentos tem espaços sem escape. Para garantir a linha de comando correta por favor mesclar argumentos no comando.", + "taskConfiguration.noCommandOrDependsOn": "Erro: a tarefa '{0}' também não especifica um comando ou uma propriedade dependsOn. A tarefa será ignorada. Sua definição é: {1}", + "taskConfiguration.noCommand": "Erro: a tarefa '{0}' não define um comando. A tarefa será ignorada. Sua definição é: {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/common/taskTemplates.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/common/taskTemplates.i18n.json new file mode 100644 index 00000000000..268871153e3 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/common/taskTemplates.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tsc.config": "Compila um projeto TypeScript", + "tsc.watch": "Compila um projeto TypeScript em mode de monitoramento", + "dotnetCore": "Executa comando de compilação do .NET Core", + "msbuild": "Executa a compilação destino", + "externalCommand": "Exemplo para executar um comando externo arbitrário", + "Maven": "Executa comandos comuns específicos" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json new file mode 100644 index 00000000000..92ae501cdc8 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json @@ -0,0 +1,38 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "JsonSchema.options": "Opções de comando adicionais", + "JsonSchema.options.cwd": "O diretório de trabalho atual do programa executado ou do script. Se omitido raiz de espaço de trabalho atual do código é usado.", + "JsonSchema.options.env": "O ambiente do programa executado ou comando shell. Se omitido o ambiente do processo pai é usado.", + "JsonSchema.shell.executable": "O shell a ser usado.", + "JsonSchema.shell.args": "Os argumentos shell.", + "JsonSchema.command": "O comando a ser executado. Pode ser um programa externo ou um comando shell.", + "JsonSchema.tasks.args": "Argumentos passados para o comando quando esta tarefa é invocada.", + "JsonSchema.tasks.taskName": "Nome da tarefa", + "JsonSchema.tasks.windows": "Configuração de comando específica do Windows", + "JsonSchema.tasks.mac": "Configuração de comando específica do Mac", + "JsonSchema.tasks.linux": "Configuração de comando específica do Linux", + "JsonSchema.tasks.suppressTaskName": "Controla se o nome de tarefa é adicionado como um argumento para o comando. Se omitido o valor definido globalmente é usado.", + "JsonSchema.tasks.showOutput": "Controla se a saída da execução de tarefas é mostrada ou não. Se omitido o valor definido globalmente é usado.", + "JsonSchema.echoCommand": "Controla se o comando executado é enviado para a saída. O padrão é false.", + "JsonSchema.tasks.watching.deprecation": "Descontinuado. Use isBackground.", + "JsonSchema.tasks.watching": "Se a tarefa executada é mantida viva e está monitorando o sistema de arquivos.", + "JsonSchema.tasks.background": "Se a tarefa executada é mantida viva e é executado em segundo plano.", + "JsonSchema.tasks.promptOnClose": "Se o usuário é solicitado quando VS Code fecha com uma tarefa sendo executada.", + "JsonSchema.tasks.build": "Esta tarefa é mapeada para o comando de compilação padrão do código.", + "JsonSchema.tasks.test": "Esta tarefa é mapeada para o comando de teste padrão do código.", + "JsonSchema.tasks.matchers": "O problema matcher(s) a seu utilizado. Pode ser uma sequência de caracteres ou uma definição de problem matcher ou uma matriz de sequências de caracteres e problem matchers.", + "JsonSchema.args": "Argumentos adicionais passados para o comando.", + "JsonSchema.showOutput": "Controla se a saída da execução de tarefas é mostrada ou não. Se omitido 'sempre' é usado.", + "JsonSchema.watching.deprecation": "Descontinuado. Use isBackground.", + "JsonSchema.watching": "Se a tarefa executada é mantida viva e está monitorando o sistema de arquivos.", + "JsonSchema.background": "Se a tarefa executada é mantida viva e é executado em segundo plano.", + "JsonSchema.promptOnClose": "Se o usuário é solicitado quando VS Code fecha com uma tarefa de segundo plano em execução.", + "JsonSchema.suppressTaskName": "Controla se o nome de tarefa é adicionado como um argumento para o comando. O padrão é false.", + "JsonSchema.taskSelector": "Prefixo para indicar que um argumento é tarefa.", + "JsonSchema.matchers": "A correspondência de problemas a ser utilizada. Pode ser uma sequência de caracteres ou uma definição de correspondência de problemas ou uma matriz de sequências de caracteres e correspondência de problemas.", + "JsonSchema.tasks": "As configurações de tarefa. Normalmente são ampliações de tarefas já definidas na execução de tarefa externa." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json new file mode 100644 index 00000000000..dc0695101b0 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "JsonSchema.version": "Número da versão do config", + "JsonSchema.windows": "Configuração de comando específica do Windows", + "JsonSchema.mac": "Configuração de comando específica do Mac", + "JsonSchema.linux": "Configuração de comando específica do Linux", + "JsonSchema.shell": "Especifica se o comando é um comando shell ou um programa externo. O padrão é falso se omitido." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json new file mode 100644 index 00000000000..3130e474d7e --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "JsonSchema.version": "Número da versão do config", + "JsonSchema.windows": "Configuração de comando específica do Windows", + "JsonSchema.mac": "Configuração de comando específica do Mac", + "JsonSchema.linux": "Configuração de comando específica do Linux", + "JsonSchema.shell": "Especifica se o comando é um comando shell ou um programa externo. O padrão é falso se omitido.", + "JsonSchema.tasks.dependsOn.string": "Outra tarefa da qual esta tarefa depende.", + "JsonSchema.tasks.dependsOn.array": "A outra tarefa que esta tarefa depende." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json new file mode 100644 index 00000000000..a07be4d2850 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json @@ -0,0 +1,47 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksCategory": "Tarefas", + "ConfigureTaskRunnerAction.noWorkspace": "Tarefas somente estão disponíveis em uma pasta da área de trabalho.", + "ConfigureTaskRunnerAction.quickPick.template": "Selecione um gerenciador de tarefa", + "ConfigureTaskRunnerAction.autoDetecting": "Tarefas de auto detecção para {0}", + "ConfigureTaskRunnerAction.autoDetect": "A tarefa de sistema de auto detecção falhou. Usando o modelo padrão. Consulte a saída da tarefa para detalhes.", + "ConfigureTaskRunnerAction.autoDetectError": "A tarefa de sistema de auto detecção produziu erros. Consulte a saída da tarefa para detalhes.", + "ConfigureTaskRunnerAction.failed": "Não é possível criar o arquivo 'tasks.json' na pasta '.vscode'. Consulte a saída da tarefa para detalhes.", + "ConfigureTaskRunnerAction.label": "Configure o gerenciador de tarefas", + "ConfigureBuildTaskAction.label": "Configurar Tarefa de Compilação", + "CloseMessageAction.label": "Fechar", + "ShowTerminalAction.label": "Terminal Visualização", + "problems": "Problemas", + "manyMarkers": "99+", + "tasks": "Tarefas", + "TaskSystem.noHotSwap": "Alterar o mecanismo de execução de tarefa requer reiniciar o VS Code. A alteração será ignorada.", + "TaskService.noBuildTask": "Nenhuma tarefa de compilação definida. Marque uma tarefa com 'isBuildCommand' no arquivo tasks.json.", + "TaskService.noTestTask": "Nenhuma tarefa de teste definida. Marque uma tarefa com 'isTestCommand' no arquivo tasks.json.", + "TaskServer.noTask": "Tarefa {0} requisitada para execução não encontrada.", + "TaskSystem.activeSame": "A tarefa já está ativa e em modo de monitoramento. Para terminar a tarefa, use `F1 > terminar tarefa`", + "TaskSystem.active": "Já existe uma tarefa sendo executada. Finalize-a antes de executar outra tarefa.", + "TaskSystem.restartFailed": "Falha ao finalizar e reiniciar a tarefa {0}", + "TaskSystem.configurationErrors": "Erro: A configuração da tarefa informada possui erros de validação e não pode ser utilizada. Por favor, corrija os erros primeiro.", + "TaskSystem.invalidTaskJson": "Erro: O conteúdo do arquivo tasks.json possui erros de sintaxe. Por favor, corrija-os antes de executar uma tarefa.\n", + "TaskSystem.runningTask": "Há uma tarefa sendo executada. Deseja finalizá-la?", + "TaskSystem.terminateTask": "&&Finalizar Tarefa", + "TaskSystem.noProcess": "A tarefa executada não existe mais. Se a tarefa produziu processos em background, finalizar o VS Code pode resultar em processos órfãos. Para evitar isso inicie o último processo em background com uma flag de espera.", + "TaskSystem.exitAnyways": "&&Sair de qualquer maneira", + "TerminateAction.label": "Finalizar a tarefa sendo executada", + "TaskSystem.unknownError": "Ocorreu um erro enquanto a tarefa estava sendo executada. Verifique o log de tarefas para detalhes.", + "TaskService.noWorkspace": "Tarefas somente estão disponíveis em uma pasta da área de trabalho.", + "TerminateAction.noProcess": "O processo executado não existe mais. Se a tarefa produziu processos em background, finalizar o VS Code pode resultar em processos órfãos.", + "TerminateAction.failed": "Falha ao finalizar a tarefa sendo executada", + "ShowLogAction.label": "Visualizar o Log de Tarefas", + "RunTaskAction.label": "Executar Tarefa", + "RestartTaskAction.label": "Reiniciar Tarefa", + "BuildAction.label": "Executar Tarefa de compilação", + "TestAction.label": "Executar Tarefa de Teste", + "quickOpen.task": "Executar Tarefa", + "quickOpen.terminateTask": "Finalizar Tarefa", + "quickOpen.restartTask": "Reiniciar Tarefa" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json new file mode 100644 index 00000000000..f21b7eebc35 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "TerminalTaskSystem.unknownError": "Um erro desconhecido ocorreu durante a execução de uma tarefa. Consulte o log de saída de tarefa para obter detalhes.", + "TerminalTaskSystem.terminalName": "Tarefa - {0}", + "TerminalTaskSystem": "Não é possível executar um comando shell em uma unidade UNC.", + "unkownProblemMatcher": "Problem matcher {0} não pode ser resolvido. O matcher será ignorado" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/node/processRunnerDetector.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/node/processRunnerDetector.i18n.json new file mode 100644 index 00000000000..a4f13c42f7c --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/node/processRunnerDetector.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "TaskSystemDetector.noGulpTasks": "Executando gulp..-tarefas-simples não listam nenhuma tarefa. Você executou a instalação do npm?", + "TaskSystemDetector.noJakeTasks": "Executando jake..-tarefas não listam nenhuma tarefa. Você instalou o npm?", + "TaskSystemDetector.noGulpProgram": "Gulp não está instalado no seu sistema. Execute npm install -g gulp para instalá-lo.", + "TaskSystemDetector.noJakeProgram": "Jake não está instalado no seu sistema. Execute npm install -g jake para instalá-lo.", + "TaskSystemDetector.noGruntProgram": "Grunhido não está instalado no seu sistema. Execute npm install -g grunt para instalá-lo.", + "TaskSystemDetector.noProgram": "Programa {0} não foi encontrado. Mensagem é {1}", + "TaskSystemDetector.buildTaskDetected": "Tarefa de construção chamada '{0}' detectada.", + "TaskSystemDetector.testTaskDetected": "Tarefa de teste chamada '{0}' detectada." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json new file mode 100644 index 00000000000..72848a8cde1 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "TaskRunnerSystem.unknownError": "Um erro desconhecido ocorreu durante a execução de uma tarefa. Consulte o log de saída de tarefa para obter detalhes.", + "TaskRunnerSystem.watchingBuildTaskFinished": "\nTarefas de compilação de monitoramento terminaram.", + "TaskRunnerSystem.childProcessError": "Falha ao iniciar o programa externo {0} {1}.", + "TaskRunnerSystem.cancelRequested": "\nA tarefa '{0}' foi finalizada por solicitação do usuário.", + "unkownProblemMatcher": "Problema matcher {0} não pode ser resolvido. O matcher será ignorado" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.i18n.json new file mode 100644 index 00000000000..de21ec3dca1 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.i18n.json @@ -0,0 +1,30 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminalIntegratedConfigurationTitle": "Terminal Integrado", + "terminal.integrated.shell.linux": "O caminho do shell que o terminal usa no Linux.", + "terminal.integrated.shellArgs.linux": "Os argumentos de linha de comando a serem usados no terminal do Linux.", + "terminal.integrated.shell.osx": "O caminho do shell que o terminal usa no OS X.", + "terminal.integrated.shellArgs.osx": "Os argumentos de linha de comando a serem usados no terminal do OS X.", + "terminal.integrated.shell.windows": "O caminho do shell que o terminal usa no Windows. Quando usar um shell fornecido com o Windows (cmd, PowerShell ou Bash no Ubuntu), prefira utilizar C:\\Windows\\sysnative ao invés de C:\\Windows\\System32 para usar as versões de 64 bits.", + "terminal.integrated.shellArgs.windows": "Os argumentos de linha de comando a serem utilizados no terminal do Windows.", + "terminal.integrated.rightClickCopyPaste": "Quando configurado, isto evitará que o menu de contexto apareça quando pressionado o botão direito do mouse dentro do terminal, em vez disso vai copiar quando há uma seleção e colar quando não há nenhuma seleção.", + "terminal.integrated.fontFamily": "Controla a família de fontes do terminal, este padrão é o valor do editor.fontFamily.", + "terminal.integrated.fontLigatures": "Controla se as ligações de fonte são habilitadas no terminal.", + "terminal.integrated.fontSize": "Controla o tamanho da fonte em pixels do terminal.", + "terminal.integrated.lineHeight": "Controles a altura da linha do terminal, este número é multiplicada pelo tamanho da fonte terminal para obter a altura real da linha em pixels.", + "terminal.integrated.enableBold": "Se habilitar o texto em negrito dentro do terminal requer suporte do terminal shell.", + "terminal.integrated.cursorBlinking": "Controla se o cursor do terminal pisca.", + "terminal.integrated.cursorStyle": "Controla o estilo do cursor do terminal.", + "terminal.integrated.scrollback": "Controla a quantidade máxima de linhas que o terminal mantém em seu buffer.", + "terminal.integrated.setLocaleVariables": "Controla se as variáveis locais são definidas na inicialização do terminal, este padrão é verdadeiro no OS X e falso em outras plataformas.", + "terminal.integrated.cwd": "Um caminho de início explícito onde o terminal será lançado, isso é usado como o diretório de trabalho atual (cwd) para o processo shell. Isto pode ser particularmente útil em configurações de espaço de trabalho se o diretório raiz não é um cwd conveniente.", + "terminal.integrated.confirmOnExit": "Confirmar na saída se ainda houverem sessões de terminal ativas.", + "terminal.integrated.commandsToSkipShell": "Um conjunto de IDs de comando, cujas combinações de teclas não serão enviadas para o shell e sempre serão tratadas por código. Isto permite o uso de combinações de teclas que normalmente seriam consumidas pelo shell para agir da mesma forma quando o terminal não é focado, por exemplo ctrl+p para Execução Rápida.", + "terminal": "Terminal", + "terminalCategory": "Terminal", + "viewCategory": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json new file mode 100644 index 00000000000..e63bd5db0a0 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json @@ -0,0 +1,32 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "workbench.action.terminal.toggleTerminal": "Alternar Terminal Integrado", + "workbench.action.terminal.kill": "Finalizar a Instância de Terminal Ativa", + "workbench.action.terminal.kill.short": "Encerrar Terminal", + "workbench.action.terminal.copySelection": "Copiar Seleção", + "workbench.action.terminal.new": "Criar Novo Terminal Integrado", + "workbench.action.terminal.new.short": "Novo Terminal", + "workbench.action.terminal.focus": "Focalizar Terminal", + "workbench.action.terminal.focusNext": "Focalizar Próximo Terminal", + "workbench.action.terminal.focusAtIndex": "Focalizar Terminal {0}", + "workbench.action.terminal.focusPrevious": "Focalizar Terminal Anterior", + "workbench.action.terminal.paste": "Colar no Terminal Ativo", + "workbench.action.terminal.DefaultShell": "Selecionar Shell Padrão", + "workbench.action.terminal.runSelectedText": "Executar Texto Selecionado no Terminal Ativo", + "workbench.action.terminal.runActiveFile": "Executar Arquivo Ativo no Terminal Ativo", + "workbench.action.terminal.runActiveFile.noFile": "Apenas arquivos em disco podem ser executados no terminal", + "workbench.action.terminal.switchTerminalInstance": "Trocar a instância de Terminal", + "workbench.action.terminal.scrollDown": "Rolar para Baixo (Linha)", + "workbench.action.terminal.scrollDownPage": "Rolar para Baixo (Página)", + "workbench.action.terminal.scrollToBottom": "Rolar para baixo", + "workbench.action.terminal.scrollUp": "Rolar para Cima (Linha)", + "workbench.action.terminal.scrollUpPage": "Rolar para Cima (Página)", + "workbench.action.terminal.scrollToTop": "Rolar para cima", + "workbench.action.terminal.clear": "Limpar", + "workbench.action.terminal.allowWorkspaceShell": "Permitir a Configuração de Shell da Ãrea de Trabalho", + "workbench.action.terminal.disallowWorkspaceShell": "Não Permitir a Configuração de Shell da Ãrea de Trabalho" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json new file mode 100644 index 00000000000..495bd79c4bb --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminal.background": "A cor de fundo do terminal, isso permite colorir o terminal com uma cor diferente do painel.", + "terminal.foreground": "A cor de primeiro plano do terminal.", + "terminal.ansiColor": "'{0}' cor ansi no terminal." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.i18n.json b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.i18n.json new file mode 100644 index 00000000000..b2b9a9a9843 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminal.integrated.allowWorkspaceShell": "Você permite {0} (definido como uma configuração de espaço de trabalho) a ser executado no terminal?", + "allow": "Permitir", + "disallow": "Não permitir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json new file mode 100644 index 00000000000..13b6933b1b9 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminal.integrated.copySelection.noSelection": "Não é possível copiar seleção do terminal quando o terminal não tem foco", + "terminal.integrated.exitedWithCode": "O processo terminal encerrado com código de saída: {0}", + "terminal.integrated.waitOnExit": "Pressione qualquer tecla para fechar o terminal", + "terminal.integrated.launchFailed": "O comando de processo de terminal '{0}{1}' falhou ao ser iniciado (código de saída: {2})" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.i18n.json new file mode 100644 index 00000000000..fd175c5ad29 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminalLinkHandler.followLinkCmd": "Cmd + clique para seguir o link", + "terminalLinkHandler.followLinkCtrl": "Ctrl + clique para seguir o link" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.i18n.json b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.i18n.json new file mode 100644 index 00000000000..5e811b86100 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "copy": "Copiar", + "createNewTerminal": "Novo Terminal", + "paste": "Colar", + "clear": "Limpar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalService.i18n.json b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalService.i18n.json new file mode 100644 index 00000000000..08ec4bd9777 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalService.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminal.integrated.chooseWindowsShellInfo": "Você pode alterar o terminal shell padrão selecionando o botão Personalizar.", + "customize": "Personalizar", + "cancel": "Cancelar", + "never again": "Ok, Nunca Mostrar Novamente", + "terminal.integrated.chooseWindowsShell": "Selecione o seu terminal shell preferido, você pode alterar isso mais tarde em suas configurações", + "terminalService.terminalCloseConfirmationSingular": "Há uma sessão ativa de terminal, você quer finalizá-la?", + "terminalService.terminalCloseConfirmationPlural": "Existem {0} sessões ativas de terminal, você quer finalizá-las?", + "yes": "Sim" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json new file mode 100644 index 00000000000..9968bf0b9b1 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json @@ -0,0 +1,19 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "selectTheme.label": "Tema de Cores", + "installColorThemes": "Instalar temas de cor adicionais...", + "themes.selectTheme": "Selecione o tema de cor (teclas cima/baixo para visualização)", + "selectIconTheme.label": "Arquivo de Ãcone do Tema", + "installIconThemes": "Instalar Temas de Ãcones de Arquivos Adicionais...", + "noIconThemeLabel": "Nenhum", + "noIconThemeDesc": "Desabilitar ícones de arquivos", + "problemChangingIconTheme": "Problema configurando tema de ícones: {0}", + "themes.selectIconTheme": "Selecionar Tema de Ãcones de Arquivos", + "generateColorTheme.label": "Gerar Tema de Cores a Partir das Configurações Atuais", + "preferences": "Preferências", + "developer": "Desenvolvedor" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/trust/electron-browser/unsupportedWorkspaceSettings.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/trust/electron-browser/unsupportedWorkspaceSettings.contribution.i18n.json new file mode 100644 index 00000000000..1fc9c8fe3a4 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/trust/electron-browser/unsupportedWorkspaceSettings.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "unsupportedWorkspaceSettings": "Esta área de trabalho contém configurações que só podem ser definidas nas configurações do usuário. ({0})", + "openWorkspaceSettings": "Abrir as configurações do espaço de trabalho", + "openDocumentation": "Saiba Mais", + "ignore": "Ignorar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/update/electron-browser/releaseNotesInput.i18n.json b/i18n/ptb/src/vs/workbench/parts/update/electron-browser/releaseNotesInput.i18n.json new file mode 100644 index 00000000000..213c54a3d24 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/update/electron-browser/releaseNotesInput.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "releaseNotesInputName": "Notas da Versão: {0}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/update/electron-browser/update.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/update/electron-browser/update.contribution.i18n.json new file mode 100644 index 00000000000..3634d3c2f2a --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/update/electron-browser/update.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "release notes": "Notas da versão", + "updateConfigurationTitle": "Atualizar", + "updateChannel": "Configurar se você recebe atualizações automáticas de um canal de atualização. Requer uma reinicialização depois da mudança." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/update/electron-browser/update.i18n.json b/i18n/ptb/src/vs/workbench/parts/update/electron-browser/update.i18n.json new file mode 100644 index 00000000000..4199be74572 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/update/electron-browser/update.i18n.json @@ -0,0 +1,19 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "updateNow": "Atualizar Agora", + "later": "Mais tarde", + "unassigned": "Não atribuído", + "releaseNotes": "Notas da Versão", + "showReleaseNotes": "Mostrar Notas da Versão", + "downloadNow": "Baixar agora", + "read the release notes": "Bem-vindo a {0} v{1}! Gostaria de ler as Notas da Versão?", + "licenseChanged": "Nossos termos de licença mudaram, favor revisá-los.", + "license": "Ler Licença", + "updateAvailable": "{0} será atualizado após reiniciar.", + "thereIsUpdateAvailable": "Há uma atualização disponível.", + "noUpdatesAvailable": "Não há nenhuma atualização disponível." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json b/i18n/ptb/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json new file mode 100644 index 00000000000..dea49eef8d5 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json @@ -0,0 +1,24 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "watermark.showCommands": "Mostrar todos os comandos", + "watermark.quickOpen": "Ir para o Arquivo", + "watermark.openFile": "Abrir Arquivo", + "watermark.openFolder": "Abrir Pasta", + "watermark.openFileFolder": "Abrir Arquivo ou Pasta", + "watermark.openRecent": "Abrir Recente", + "watermark.newUntitledFile": "Novo Arquivo Sem Título", + "watermark.toggleTerminal": "Alternar Terminal", + "watermark.findInFiles": "Localizar nos Arquivos", + "watermark.startDebugging": "Iniciar Depuração", + "watermark.selectTheme": "Mudar Tema", + "watermark.selectKeymap": "Mudar Mapa de Teclas", + "watermark.keybindingsReference": "Referência de Teclado", + "watermark.openGlobalKeybindings": "Atalhos de Teclado", + "watermark.unboundCommand": "não vinculado", + "workbenchConfigurationTitle": "Ãrea de Trabalho", + "tips.enabled": "Quando habilitado, mostrará as dicas de marca d'água quando nenhum editor estiver aberto." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.i18n.json b/i18n/ptb/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.i18n.json new file mode 100644 index 00000000000..93d7a695382 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "welcomeOverlay.explorer": "Explorador de arquivos", + "welcomeOverlay.search": "Pesquisar em arquivos", + "welcomeOverlay.git": "Gerenciamento de código fonte", + "welcomeOverlay.debug": "Executar e depurar", + "welcomeOverlay.extensions": "Gerenciar extensões", + "welcomeOverlay.problems": "Visualizar erros e avisos", + "welcomeOverlay.commandPalette": "Encontrar e executar todos os comandos", + "welcomeOverlay": "Visão geral da Interface do usuário", + "hideWelcomeOverlay": "Esconder a visão geral da Interface", + "help": "Ajuda" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json new file mode 100644 index 00000000000..a0b426025a4 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -0,0 +1,44 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "welcomePage.vscode": "Visual Studio Code", + "welcomePage.editingEvolved": "Edição evoluiu", + "welcomePage.start": "Início", + "welcomePage.newFile": "Novo arquivo", + "welcomePage.openFolder": "Abrir pasta...", + "welcomePage.cloneGitRepository": "Clonar repositório Git...", + "welcomePage.recent": "Recente", + "welcomePage.moreRecent": "Mais...", + "welcomePage.noRecentFolders": "Não há pastas recentes", + "welcomePage.help": "Ajuda", + "welcomePage.keybindingsCheatsheet": "Folha de dicas de teclado para impressão", + "welcomePage.introductoryVideos": "Vídeos introdutórios", + "welcomePage.productDocumentation": "Documentação do produto", + "welcomePage.gitHubRepository": "Repositório GitHub", + "welcomePage.stackOverflow": "Stack Overflow", + "welcomePage.showOnStartup": "Mostrar a página de boas-vindas na inicialização", + "welcomePage.customize": "Personalizar", + "welcomePage.installExtensionPacks": "Ferramentas e linguagens", + "welcomePage.installExtensionPacksDescription": "Instalar o suporte para {0} e {1}", + "welcomePage.moreExtensions": "mais", + "welcomePage.installKeymapDescription": "Instalar atalhos de teclado", + "welcomePage.installKeymapExtension": "Instalar os atalhos de teclado de {0} e {1}", + "welcomePage.others": "outros", + "welcomePage.colorTheme": "Tema de cores", + "welcomePage.colorThemeDescription": "Fazer o editor e seu código parecer do jeito que você gosta", + "welcomePage.learn": "Aprender", + "welcomePage.showCommands": "Encontrar e executar todos os comandos", + "welcomePage.showCommandsDescription": "Comandos de rápido acesso e de pesquisar do painel de controle ({0})", + "welcomePage.interfaceOverview": "Visão geral da interface", + "welcomePage.interfaceOverviewDescription": "Obter uma sobreposição visual, destacando os principais componentes da interface do usuário", + "welcomePage.interactivePlayground": "Playground interativo", + "welcomePage.interactivePlaygroundDescription": "Experimente as características essenciais do editor em um curto passo-a-passo", + "welcomePage.quickLinks": "Links rápidos", + "welcomePage.keybindingsReference": "Referência de atalhos de teclado", + "welcomePage.keybindingsReferenceDescription": "Um PDF para impressão com os atalhos de teclado mais comuns", + "welcomePage.configureSettings": "Configurar definições", + "welcomePage.configureSettingsDescription": "Desbloquear o poder completo do VS Coda ajustando as configurações" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json new file mode 100644 index 00000000000..7012e078815 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "workbenchConfigurationTitle": "Ãrea de Trabalho", + "welcomePage.enabled": "Quando habilitado, irá mostrar a página de boas-vindas na inicialização.", + "help": "Ajuda" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json new file mode 100644 index 00000000000..29755259794 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -0,0 +1,31 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "welcomePage": "Bem-vindo", + "welcomePage.javaScript": "JavaScript", + "welcomePage.typeScript": "TypeScript", + "welcomePage.python": "Python", + "welcomePage.php": "PHP", + "welcomePage.docker": "Docker", + "welcomePage.vim": "Vim", + "welcomePage.sublime": "Sublime", + "welcomePage.atom": "Atom", + "welcomePage.extensionPackAlreadyInstalled": "Suporte para {0} já está instalado.", + "welcomePage.willReloadAfterInstallingExtensionPack": "A janela irá recarregar depois de instalar o suporte para {0}.", + "welcomePage.installingExtensionPack": "Instalar o suporte para {0}...", + "welcomePage.extensionPackNotFound": "Suporte para {0} com o id {1} não pôde ser encontrado.", + "welcomePage.keymapAlreadyInstalled": "Os atalhos de teclado de {0} já estão instalados.", + "welcomePage.willReloadAfterInstallingKeymap": "A janela irá recarregar depois de instalar os {0} atalhos de teclado.", + "welcomePage.installingKeymap": "Instalando os {0} atalhos de teclado...", + "welcomePage.keymapNotFound": "Os {0} atalhos de teclado com o id {1} não podem ser encontrados.", + "welcome.title": "Bem-vindo", + "welcomePage.extensionListSeparator": ", ", + "welcomePage.installedExtension": "{0} (instalado)", + "ok": "OK", + "cancel": "Cancelar", + "welcomePage.quickLinkBackground": "Cor de fundo para as ligações rápidas na página de boas-vindas.", + "welcomePage.quickLinkHoverBackground": "Passar sobre a cor de fundo para as ligações rápidas na página de boas-vindas." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/editor/editorWalkThrough.i18n.json b/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/editor/editorWalkThrough.i18n.json new file mode 100644 index 00000000000..9c7c7f681fa --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/editor/editorWalkThrough.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorWalkThrough": "Playground Interativo", + "editorWalkThrough.title": "Playground Interativo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThrough.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThrough.contribution.i18n.json new file mode 100644 index 00000000000..a789ae1c81f --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThrough.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "walkThrough.editor.label": "Playground Interativo", + "help": "Ajuda", + "interactivePlayground": "Playground Interativo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughActions.i18n.json new file mode 100644 index 00000000000..697623110b0 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughActions.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorWalkThrough.arrowUp": "Rolar para Cima (Linha)", + "editorWalkThrough.arrowDown": "Rolar para Baixo (Linha)", + "editorWalkThrough.pageUp": "Rolar para Cima (Página)", + "editorWalkThrough.pageDown": "Rolar para Baixo (Página)" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json b/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json new file mode 100644 index 00000000000..4131ebae487 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "walkThrough.unboundCommand": "não vinculado", + "walkThrough.gitNotFound": "Parece que o Git não está instalado no seu sistema.", + "walkThrough.embeddedEditorBackground": "Cor de fundo para os editores incorporados no Playground Interativo." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json b/i18n/ptb/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json new file mode 100644 index 00000000000..188ab8da37e --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "open": "Abrir configurações", + "close": "Fechar", + "saveAndRetry": "Salvar as configurações e tentar novamente", + "errorUnknownKey": "Não é possível gravar no arquivo de configuração (chave desconhecida)", + "errorInvalidTarget": "Não é possível gravar no arquivo de configuração (destino inválido)", + "errorNoWorkspaceOpened": "Não é possível gravar em configurações porque nenhuma pasta está aberta. Por favor, abra uma pasta primeiro e tente novamente.", + "errorInvalidConfiguration": "Não é possível gravar em configurações. Por favor abra **User Settings** para corrigir erros/avisos no arquivo e tente novamente.", + "errorInvalidConfigurationWorkspace": "Não é possível gravar em configurações. Por favor abra **Workspace Settings** para corrigir erros/avisos no arquivo e tente novamente.", + "errorConfigurationFileDirty": "Não é possível gravar em configurações, porque o arquivo foi alterado. Por favor, salve o arquivo **User Settings** e tente novamente.", + "errorConfigurationFileDirtyWorkspace": "Não é possível gravar em configurações, porque o arquivo foi alterado. Por favor, salve o arquivo **Workspace Settings** e tente novamente." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/editor/browser/editorService.i18n.json b/i18n/ptb/src/vs/workbench/services/editor/browser/editorService.i18n.json new file mode 100644 index 00000000000..50e968f8ee3 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/editor/browser/editorService.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "compareLabels": "{0} ↔ {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/files/electron-browser/fileService.i18n.json b/i18n/ptb/src/vs/workbench/services/files/electron-browser/fileService.i18n.json new file mode 100644 index 00000000000..49e9152a1db --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/files/electron-browser/fileService.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "netVersionError": "O Microsoft .NET Framework 4.5 é necessário. Por favor siga o link para instalá-lo.", + "installNet": "Baixar o .NET Framework 4.5", + "neverShowAgain": "Não mostrar novamente", + "trashFailed": "Falha em mover '{0}' para a lixeira" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/files/node/fileService.i18n.json b/i18n/ptb/src/vs/workbench/services/files/node/fileService.i18n.json new file mode 100644 index 00000000000..b84feecdb4f --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/files/node/fileService.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "fileInvalidPath": "Recurso de arquivo inválido ({0})", + "fileIsDirectoryError": "Arquivo é diretório ({0})", + "fileBinaryError": "Arquivo parece ser binário e não pode ser aberto como texto", + "fileNotFoundError": "Arquivo não encontrado ({0})", + "unableToMoveCopyError": "Não é possível mover/copiar. Arquivo poderia substituir a pasta em que está contida.", + "foldersCopyError": "Pastas não podem ser copiadas para a área de trabalho. Por favor selecione arquivos individuais para serem copiados.", + "fileReadOnlyError": "Arquivo é Somente Leitura" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/keybinding/common/keybindingEditing.i18n.json b/i18n/ptb/src/vs/workbench/services/keybinding/common/keybindingEditing.i18n.json new file mode 100644 index 00000000000..daa32f59ee9 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/keybinding/common/keybindingEditing.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "errorKeybindingsFileDirty": "Não é possível gravar porque o arquivo está sujo. Por favor, salve o arquivo **Keybindings** e tente novamente.", + "parseErrors": "Não é possível gravar as combinações de teclas. Por favor abra o **arquivo Keybindings** para corrigir erros/avisos no arquivo e tente novamente.", + "errorInvalidConfiguration": "Não é possível gravar as combinações de teclas. **Arquivo Keybindings** tem um objeto que não é do tipo Matriz. Por favor, abra o arquivo para limpar e tentar novamente.", + "emptyKeybindingsHeader": "Coloque suas combinações de teclas neste arquivo para substituir os padrões" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/keybinding/electron-browser/keybindingService.i18n.json b/i18n/ptb/src/vs/workbench/services/keybinding/electron-browser/keybindingService.i18n.json new file mode 100644 index 00000000000..2fac75a5675 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/keybinding/electron-browser/keybindingService.i18n.json @@ -0,0 +1,26 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "nonempty": "Esperado um valor não vazio", + "requirestring": "a propriedade `{0}` é obrigatória e deve ser do tipo `string`", + "optstring": "a propriedade `{0}` é opcional ou pode ser do tipo `string`", + "vscode.extension.contributes.keybindings.command": "Identificador do comando a ser executado quando keybinding é acionado.", + "vscode.extension.contributes.keybindings.key": "Tecla ou sequência de teclas (teclas separadas com o sinal de adição e sequências com espaço, por exemplo Ctrl+O e Ctrl+L L para um acorde", + "vscode.extension.contributes.keybindings.mac": "Chave específica Mac ou sequência de teclas.", + "vscode.extension.contributes.keybindings.linux": "Chave específica Linux ou sequência de teclas.", + "vscode.extension.contributes.keybindings.win": "Chave específica Windows ou sequência de teclas.", + "vscode.extension.contributes.keybindings.when": "Condição quando a chave está ativa.", + "vscode.extension.contributes.keybindings": "Contribui para Atalhos de Teclado.", + "invalid.keybindings": "Inválido `contributes.{0}`: {1}", + "unboundCommands": "Aqui estão outros comandos disponíveis: ", + "keybindings.json.title": "Configuração de combinações de teclas", + "keybindings.json.key": "Tecla ou sequência de teclas (separados por espaço)", + "keybindings.json.command": "Nome do comando a ser executado", + "keybindings.json.when": "Condição quando a chave está ativa.", + "keybindings.json.args": "Argumentos a serem passados para o comando para executar.", + "keyboardConfigurationTitle": "Teclado", + "dispatch": "Controla a lógica de expedição para pressionamentos de teclas para usar `keydown.code` (recomendado) ou 'keydown.keyCode'." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/message/browser/messageList.i18n.json b/i18n/ptb/src/vs/workbench/services/message/browser/messageList.i18n.json new file mode 100644 index 00000000000..267b62d179d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/message/browser/messageList.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "alertErrorMessage": "Erro: {0}", + "alertWarningMessage": "Aviso: {0}", + "alertInfoMessage": "Informações: {0}", + "error": "Erro", + "warning": "Aviso", + "info": "Informações", + "close": "Fechar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/message/electron-browser/messageService.i18n.json b/i18n/ptb/src/vs/workbench/services/message/electron-browser/messageService.i18n.json new file mode 100644 index 00000000000..cecec4b4c3a --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/message/electron-browser/messageService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "yesButton": "&&Sim", + "cancelButton": "Cancelar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/mode/common/workbenchModeService.i18n.json b/i18n/ptb/src/vs/workbench/services/mode/common/workbenchModeService.i18n.json new file mode 100644 index 00000000000..91df655432d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/mode/common/workbenchModeService.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "invalid": "Inválido 'contributes.{0}`. Matriz esperada.", + "invalid.empty": "Valor em branco para` contributes.{0}`", + "require.id": "a propriedade `{0}` é obrigatória e deve ser do tipo `string`", + "opt.extensions": "a propriedade `{0}` pode ser omitida e deve ser do tipo `string[]`", + "opt.filenames": "a propriedade `{0}` pode ser omitida e deve ser do tipo `string[]`", + "opt.firstLine": "a propriedade `{0}` pode ser omitida e deve ser do tipo `string`", + "opt.configuration": "a propriedade `{0}` pode ser omitida e deve ser do tipo `string`", + "opt.aliases": "a propriedade `{0}` pode ser omitida e deve ser do tipo `string[]`", + "opt.mimetypes": "a propriedade `{0}` pode ser omitida e deve ser do tipo `string[]`" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/textfile/common/textFileEditorModel.i18n.json b/i18n/ptb/src/vs/workbench/services/textfile/common/textFileEditorModel.i18n.json new file mode 100644 index 00000000000..7eed5484379 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/textfile/common/textFileEditorModel.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "saveFileFirst": "O arquivo está alterado. Por favor, salvá-lo primeiro antes reabri-lo com outra codificação.", + "genericSaveError": "Erro ao salvar '{0}': {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/textfile/common/textFileService.i18n.json b/i18n/ptb/src/vs/workbench/services/textfile/common/textFileService.i18n.json new file mode 100644 index 00000000000..9fe74ad26f3 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/textfile/common/textFileService.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "files.backup.failSave": "Arquivos não poderiam ser backupeados (erro: {0}), tente salvar seus arquivos para sair." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/textfile/electron-browser/textFileService.i18n.json b/i18n/ptb/src/vs/workbench/services/textfile/electron-browser/textFileService.i18n.json new file mode 100644 index 00000000000..491b19e87c4 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/textfile/electron-browser/textFileService.i18n.json @@ -0,0 +1,18 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "saveChangesMessage": "Você quer salvar as alterações feitas para {0}?", + "saveChangesMessages": "Você quer salvar as alterações para os seguintes {0} arquivos?", + "moreFile": "... 1 arquivo adicional não está mostrado", + "moreFiles": "... {0} arquivos adicionais não estão mostrados", + "saveAll": "&&Salvar tudo", + "save": "&&Salvar", + "dontSave": "&&Não Salvar", + "cancel": "Cancelar", + "saveChangesDetail": "Suas alterações serão perdidas se você não salvá-las.", + "allFiles": "Todos os arquivos", + "noExt": "Sem extensão" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/themes/common/colorThemeSchema.i18n.json b/i18n/ptb/src/vs/workbench/services/themes/common/colorThemeSchema.i18n.json new file mode 100644 index 00000000000..02e2bc18273 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/themes/common/colorThemeSchema.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "schema.colors": "Cores para o realce de sintaxe", + "schema.properties.name": "Descrição da regra", + "schema.fontStyle": "Estilo da fonte da regra: um estilo ou uma combinação de 'itálico', 'negrito' e 'sublinhado'", + "schema.tokenColors.path": "Caminho para um arquivo tmTheme (relativo ao arquivo atual)" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/themes/common/fileIconThemeSchema.i18n.json b/i18n/ptb/src/vs/workbench/services/themes/common/fileIconThemeSchema.i18n.json new file mode 100644 index 00000000000..3cf20c82de2 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/themes/common/fileIconThemeSchema.i18n.json @@ -0,0 +1,37 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "schema.folderExpanded": "O ícone de pasta para pastas expandidas. O ícone da pasta expandido é opcional. Se não definido, o ícone definido para a pasta será mostrado.", + "schema.folder": "O ícone de pasta para pastas colapsadas, e se folderExpanded não estiver definido, também para pastas expandidas.", + "schema.file": "O ícone de arquivo padrão, indicado para todos os arquivos que não correspondem a qualquer extensão, nome de arquivo ou idioma.", + "schema.folderNames": "Associa os nomes de pasta à ícones. A chave do objeto é o nome da pasta, não incluindo quaisquer segmentos de caminho. Nenhum padrão ou curinga são permitidos. O nome da pasta de correspondência diferencia maiusculas de minúsculas.", + "schema.folderName": "A ID da definição do ícone para associação.", + "schema.folderNamesExpanded": "Associa os nomes de pasta a ícones para pastas expandidas. A chave do objeto é o nome da pasta, não incluindo quaisquer segmentos do caminho. Padrões ou curingas não são permitidas. A correspondência do nome de pastas não diferencia maiusculas de minúsculas.", + "schema.folderNameExpanded": "A ID da definição do ícone para a associação.", + "schema.fileExtensions": "Associa as extensões de arquivo aos ícones. A chave do objeto é o nome da extensão do arquivo. O nome da extensão é o último segmento de um nome de arquivo após o último ponto (não incluindo o ponto). As extensões não diferenciam maiúsculas de minúsculas.", + "schema.fileExtension": "A ID da definição do ícone para a associação.", + "schema.fileNames": "Associa os nomes de arquivo à ícones. A chave do objeto é o nome completo do arquivo, mas não incluindo quaisquer segmentos do caminho. O nome do arquivo pode incluir pontos e uma extensão de arquivo. Nenhum padrão ou curinga é permitido. A correspondência de nome de arquivo não diferencia maiúsculas de minúsculas.", + "schema.fileName": "A ID da definição do ícone para a associação.", + "schema.languageIds": "Associa idiomas a ícones. A chave do objeto é o id de idioma definido no ponto de contribuição de linguagem.", + "schema.languageId": "O ID da definição do ícone para a associação.", + "schema.fonts": "Fontes que são usadas nas definições de ícone.", + "schema.id": "O ID da fonte.", + "schema.src": "A localização da fonte.", + "schema.font-path": "O caminho do fonte, relativo ao arquivo de tema de ícone atual.", + "schema.font-format": "O formato da fonte.", + "schema.font-weight": "O peso da fonte.", + "schema.font-sstyle": "O estilo da fonte.", + "schema.font-size": "O tamanho padrão da fonte.", + "schema.iconDefinitions": "Descrição de todos os ícones que podem ser usados quando associar arquivos de ícones.", + "schema.iconDefinition": "Uma definição de ícone. A chave do objeto é o ID da definição.", + "schema.iconPath": "Ao usar um SVG ou PNG: O caminho para a imagem. O caminho é relativo ao arquivo de configuração do ícone.", + "schema.fontCharacter": "Ao usar uma fonte glyph: O caractere na fonte para usar.", + "schema.fontColor": "Ao usar uma fonte glyph: A cor a ser utilizada.", + "schema.fontSize": "Quando estiver utilizando uma fonte: O tamanho da fonte em porcentagem para a fonte de texto. Se não for definido, o padrão é o tamanho na definição de fonte.", + "schema.fontId": "Quando estiver utilizando uma fonte: A identificação da fonte. Se não for definido, o padrão é a primeira definição de fonte.", + "schema.light": "Associações opcionais para ícones de arquivo em temas de cor clara.", + "schema.highContrast": "Associações opcionais para ícones de arquivo em temas de alto contraste." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/themes/electron-browser/colorThemeData.i18n.json b/i18n/ptb/src/vs/workbench/services/themes/electron-browser/colorThemeData.i18n.json new file mode 100644 index 00000000000..4ef6944ba73 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/themes/electron-browser/colorThemeData.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "error.cannotparsejson": "Problemas ao analisar o arquivo de tema JSON: {0}", + "error.invalidformat.colors": "Problema ao analisar o arquivo de tema de cor: {0}. A propriedade 'colors' não é do tipo 'object'.", + "error.invalidformat.tokenColors": "Problema ao analisar o arquivo de tema de cor: {0}. A propriedade 'tokenColors' deve ser também uma matriz especificando as cores ou um caminho para um arquivo de texto de tema correspondente", + "error.plist.invalidformat": "Problema ao analisar o arquivo tmTheme: {0}. 'settings' não é uma matriz.", + "error.cannotparse": "Problemas ao analisar o arquivo tmTheme: {0}", + "error.cannotload": "Problemas ao carregar o arquivo tmTheme {0}: {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json b/i18n/ptb/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json new file mode 100644 index 00000000000..caeea848338 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json @@ -0,0 +1,32 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.themes": "Contribui com temas de cores do textmate.", + "vscode.extension.contributes.themes.id": "ID do tema do ícone conforme usado em configurações do usuário.", + "vscode.extension.contributes.themes.label": "Etiqueta da cor do tema como mostrado na interface do usuário.", + "vscode.extension.contributes.themes.uiTheme": "Tema base de definição das cores do editor: 'vs' é o tema de cor clara, 'vs-dark' é o tema de cor escura. 'hc preto' é o tema escuro de alto contraste.", + "vscode.extension.contributes.themes.path": "Caminho do arquivo tmTheme. O caminho é relativo à pasta de extensão e é normalmente './themes/themeFile.tmTheme'.", + "vscode.extension.contributes.iconThemes": "Contribui com temas de ícones de arquivo.", + "vscode.extension.contributes.iconThemes.id": "ID do tema do ícone como usado em configurações do usuário.", + "vscode.extension.contributes.iconThemes.label": "Etiqueta do tema do ícone como mostrado na interface do usuário.", + "vscode.extension.contributes.iconThemes.path": "Caminho do arquivo de definição do tema do ícone. O caminho é relativo à pasta de extensão e é normalmente './icons/awesome-icon-theme.json'.", + "migration.completed": "Foram adicionadas novas configurações de tema para as configurações de usuário. Backup está disponível em {0}.", + "error.cannotloadtheme": "Não é possível carregar {0}: {1}", + "reqarray": "Ponto de extensão '{0}' deve ser uma matriz.", + "reqpath": "Esperada uma string em `contributes.{0}.path`. Valor informado: {1}", + "invalid.path.1": "É esperado que `contributes.{0}.path` ({1}) seja incluído na pasta da extensão ({2}). Isto pode tornar a extensão não portável.", + "reqid": "Esperada sequência em 'contributes.{0}.ID'. Valor fornecido: {1}", + "error.cannotloadicontheme": "Não é possível carregar {0}", + "error.cannotparseicontheme": "Problemas de análise do arquivo de ícones: {0}", + "colorTheme": "Especifica o tema de cores usado no espaço de trabalho.", + "colorThemeError": "Tema é desconhecido ou não está instalado.", + "iconTheme": "Especifica o tema de ícone usado no espaço de trabalho.", + "noIconThemeDesc": "Nenhum arquivo de ícones", + "iconThemeError": "Arquivo de tema de ícones é desconhecido ou não está instalado.", + "workbenchColors": "Substitui as cores do tema do tema de cores atualmente selecionado.", + "workbenchColors.deprecated": "A configuração não é mais experimental e foi renomeada para 'workbench.colorCustomizations'", + "workbenchColors.deprecatedDescription": "Use 'workbench.colorCustomizations'" +} \ No newline at end of file diff --git a/i18n/rus/extensions/markdown/out/extension.i18n.json b/i18n/rus/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/rus/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/rus/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/rus/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/rus/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/rus/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/rus/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/rus/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/rus/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/rus/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/rus/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/rus/extensions/merge-conflict/package.i18n.json b/i18n/rus/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/rus/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/rus/extensions/npm/package.i18n.json b/i18n/rus/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/rus/extensions/npm/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/rus/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/rus/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index af5b0c29d70..32fb4e4b4cd 100644 --- a/i18n/rus/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/rus/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,8 +6,6 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "Изображение Ñлишком велико Ð´Ð»Ñ Ð¾Ñ‚Ð¾Ð±Ñ€Ð°Ð¶ÐµÐ½Ð¸Ñ Ð² редакторе. ", - "resourceOpenExternalButton": "Открыть изображение", - "resourceOpenExternalText": " Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ внешней программы?", "nativeBinaryError": "Файл не будет отображен в редакторе, так как он двоичный, очень большой или иÑпользует неподдерживаемую кодировку текÑта.", "sizeB": "{0} Б", "sizeKB": "{0} КБ", diff --git a/i18n/rus/src/vs/code/electron-main/menus.i18n.json b/i18n/rus/src/vs/code/electron-main/menus.i18n.json index 2caee2db03b..68b593f2118 100644 --- a/i18n/rus/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/rus/src/vs/code/electron-main/menus.i18n.json @@ -14,6 +14,7 @@ "mHelp": "&&Справка", "miNewWindow": "&&Ðовое окно", "mAbout": "О программе {0}", + "mServices": "Службы", "mHide": "Скрыть {0}", "mHideOthers": "Скрыть другие", "mShowAll": "Показать вÑе", @@ -69,6 +70,7 @@ "miSmartSelectShrink": "&&Сжать выделение", "miViewExplorer": "Проводник", "miViewSearch": "ПоиÑк", + "miViewSCM": "S&&CM", "miViewDebug": "Отладка", "miViewExtensions": "Р&&аÑширениÑ", "miToggleOutput": "Вывод", diff --git a/i18n/rus/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/rus/src/vs/editor/common/config/commonEditorConfig.i18n.json index 9b6838aa665..53078d0a5b6 100644 --- a/i18n/rus/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/rus/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -40,7 +40,6 @@ "formatOnType": "УправлÑет параметром, определÑющим, должен ли редактор автоматичеÑки форматировать Ñтроку поÑле ввода.", "formatOnPaste": "ОпределÑет, будет ли редактор автоматичеÑки форматировать вÑтавленное Ñодержимое. Модуль Ñ„Ð¾Ñ€Ð¼Ð°Ñ‚Ð¸Ñ€Ð¾Ð²Ð°Ð½Ð¸Ñ Ð´Ð¾Ð»Ð¶ÐµÐ½ быть доÑтупен и иметь возможноÑÑ‚ÑŒ форматировать диапазон в документе.", "suggestOnTriggerCharacters": "ОпределÑет, должны ли при вводе триггерных Ñимволов автоматичеÑки отображатьÑÑ Ð¿Ñ€ÐµÐ´Ð»Ð¾Ð¶ÐµÐ½Ð¸Ñ.", - "acceptSuggestionOnEnter": "ОпределÑет, будут ли Ð¿Ñ€ÐµÐ´Ð»Ð¾Ð¶ÐµÐ½Ð¸Ñ Ð¿Ñ€Ð¸Ð½Ð¸Ð¼Ð°Ñ‚ÑŒÑÑ ÐºÐ»Ð°Ð²Ð¸ÑˆÐµÐ¹ ВВОД в дополнение к клавише TAB. Это помогает избежать неоднозначноÑти между вÑтавкой новых Ñтрок и принÑтием предложений.", "acceptSuggestionOnCommitCharacter": "ОпределÑет, будут ли Ð¿Ñ€ÐµÐ´Ð»Ð¾Ð¶ÐµÐ½Ð¸Ñ Ð¿Ñ€Ð¸Ð½Ð¸Ð¼Ð°Ñ‚ÑŒÑÑ Ñимволами фикÑации. Ðапример, в JavaScript точка Ñ Ð·Ð°Ð¿Ñтой (\";\") может быть Ñимволом фикÑации, принимающим предложение и вводÑщим данный Ñимвол.", "snippetSuggestions": "УправлÑет отображением фрагментов вмеÑте Ñ Ð´Ñ€ÑƒÐ³Ð¸Ð¼Ð¸ предложениÑми и их Ñортировкой.", "emptySelectionClipboard": "УправлÑет тем, копируетÑÑ Ð»Ð¸ Ñ‚ÐµÐºÑƒÑ‰Ð°Ñ Ñтрока при копировании без выделениÑ.", diff --git a/i18n/rus/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/rus/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..e61942e5d18 --- /dev/null +++ b/i18n/rus/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "Определение Ð´Ð»Ñ \"{0}\" не найдено.", + "generic.noResults": "ÐžÐ¿Ñ€ÐµÐ´ÐµÐ»ÐµÐ½Ð¸Ñ Ð½Ðµ найдены.", + "meta.title": " — Ð¾Ð¿Ñ€ÐµÐ´ÐµÐ»ÐµÐ½Ð¸Ñ {0}", + "actions.goToDecl.label": "Перейти к определению", + "actions.goToDeclToSide.label": "Открыть определение Ñбоку", + "actions.previewDecl.label": "Показать определение", + "goToImplementation.noResultWord": "Ðе найдена Ñ€ÐµÐ°Ð»Ð¸Ð·Ð°Ñ†Ð¸Ñ Ð´Ð»Ñ \"{0}\".", + "goToImplementation.generic.noResults": "Ðе найдена реализациÑ.", + "meta.implementations.title": "— {0} реализаций", + "actions.goToImplementation.label": "Перейти к реализации", + "actions.peekImplementation.label": "Показать реализацию", + "goToTypeDefinition.noResultWord": "Ðе найдено определение типа Ð´Ð»Ñ \"{0}\".", + "goToTypeDefinition.generic.noResults": "Ðе найдено определение типа.", + "meta.typeDefinitions.title": "— {0} определений типов", + "actions.goToTypeDefinition.label": "Перейти к определению типа", + "actions.peekTypeDefinition.label": "Показать определение типа" +} \ No newline at end of file diff --git a/i18n/rus/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/rus/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..a403ef380f2 --- /dev/null +++ b/i18n/rus/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "Щелкните, чтобы отобразить Ð¾Ð¿Ñ€ÐµÐ´ÐµÐ»ÐµÐ½Ð¸Ñ ({0})." +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/rus/src/vs/workbench/electron-browser/main.contribution.i18n.json index ff2b65c8fab..f2bd599c1b9 100644 --- a/i18n/rus/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/rus/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -7,6 +7,7 @@ "view": "ПроÑмотреть", "help": "Справка", "file": "Файл", + "developer": "Разработчик", "showEditorTabs": "ОпределÑет, должны ли открытые редакторы отображатьÑÑ Ð½Ð° вкладках или нет.", "editorTabCloseButton": "ОпределÑет положение кнопок Ð·Ð°ÐºÑ€Ñ‹Ñ‚Ð¸Ñ Ð²ÐºÐ»Ð°Ð´Ð¾Ðº редактора или отключает их, еÑли задано значение off.", "showIcons": "ОпределÑет, должны ли открытые редакторы отображатьÑÑ Ñо значком. Требует включить тему значков.", diff --git a/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 8b6ad71cd4e..906d10fee6b 100644 --- a/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "disableOtherKeymapsConfirmation": "Отключить другие раÑкладки клавиатуры, чтобы избежать конфликта между наÑтраиваемыми ÑочетаниÑми клавиш?", + "yes": "Да", + "no": "Ðет" +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/rus/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 952d7106938..6c404cd1796 100644 --- a/i18n/rus/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,7 +16,6 @@ "associations": "ÐаÑтройте ÑопоÑÑ‚Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ñ„Ð°Ð¹Ð»Ð¾Ð² Ñ Ñзыками (например, \"*.extension\": \"html\"). У них будет приоритет перед заданными по умолчанию ÑопоÑтавлениÑми уÑтановленных Ñзыков.", "encoding": "Кодировка набора Ñимволов по умолчанию, иÑÐ¿Ð¾Ð»ÑŒÐ·ÑƒÐµÐ¼Ð°Ñ Ð¿Ñ€Ð¸ чтении и запиÑи файлов", "autoGuessEncoding": "ЕÑли параметр включен, производитÑÑ Ð¿Ð¾Ð¿Ñ‹Ñ‚ÐºÐ° определить кодировку набора Ñимволов при открытии файлов", - "eol": "Символ конца Ñтроки по умолчанию.", "trimTrailingWhitespace": "ЕÑли Ñтот параметр включен, при Ñохранении файла будут удалены концевые пробелы.", "insertFinalNewline": "ЕÑли Ñтот параметр включен, при Ñохранении файла в его конец вÑтавлÑетÑÑ Ñ„Ð¸Ð½Ð°Ð»ÑŒÐ½Ð°Ñ Ð½Ð¾Ð²Ð°Ñ Ñтрока.", "files.autoSave.off": "\"ГрÑзный\" файл не ÑохранÑетÑÑ Ð°Ð²Ñ‚Ð¾Ð¼Ð°Ñ‚Ð¸Ñ‡ÐµÑки.", diff --git a/i18n/rus/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/rus/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index ef99a2ea9f3..5ac046256bd 100644 --- a/i18n/rus/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -5,5 +5,9 @@ // Do not edit this file. It is machine generated. { "slow": "Обнаружен замедленный запуÑк.", - "slow.detail": "Сожалеем, что у Ð²Ð°Ñ Ð¿Ñ€Ð¾Ð¸Ð·Ð¾ÑˆÐµÐ» замедленный запуÑк. ПерезапуÑтите \"{0}\" Ñ Ð²ÐºÐ»ÑŽÑ‡ÐµÐ½Ð½Ñ‹Ð¼ профилированием и отправьте профили нам, чтобы мы могли уÑкорить загрузку." + "slow.detail": "Сожалеем, что у Ð²Ð°Ñ Ð¿Ñ€Ð¾Ð¸Ð·Ð¾ÑˆÐµÐ» замедленный запуÑк. ПерезапуÑтите \"{0}\" Ñ Ð²ÐºÐ»ÑŽÑ‡ÐµÐ½Ð½Ñ‹Ð¼ профилированием и отправьте профили нам, чтобы мы могли уÑкорить загрузку.", + "prof.message": "Профили уÑпешно Ñозданы.", + "prof.detail": "Создайте проблему и вручную вложите Ñледующие файлы:\n{0}", + "prof.restartAndFileIssue": "Создать проблему и выполнить перезапуÑк", + "prof.restart": "ПерезапуÑтить" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/rus/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 901720ad5dd..1365e07209b 100644 --- a/i18n/rus/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -5,6 +5,11 @@ // Do not edit this file. It is machine generated. { "welcomePage": "Добро пожаловать", + "welcomePage.typeScript": "TypeScript", + "welcomePage.php": "PHP", + "welcomePage.vim": "Vim", + "welcomePage.sublime": "Sublime", + "welcomePage.atom": "Atom", "welcomePage.keymapAlreadyInstalled": "Ð¡Ð¾Ñ‡ÐµÑ‚Ð°Ð½Ð¸Ñ ÐºÐ»Ð°Ð²Ð¸Ñˆ {0} уже уÑтановлены.", "welcomePage.willReloadAfterInstallingKeymap": "Окно перезагрузитÑÑ Ð¿Ð¾Ñле уÑтановки Ñочетаний клавиш {0}.", "welcomePage.installingKeymap": "УÑтанавливаютÑÑ ÑÐ¾Ñ‡ÐµÑ‚Ð°Ð½Ð¸Ñ ÐºÐ»Ð°Ð²Ð¸Ñˆ {0}...", -- GitLab From 84ced6126ea370a757fbff264f106af319029257 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 25 May 2017 08:05:53 +0200 Subject: [PATCH 0036/1347] theming - remove hardcoded list color in keybindings editor --- .../browser/media/keybindingsEditor.css | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/src/vs/workbench/parts/preferences/browser/media/keybindingsEditor.css b/src/vs/workbench/parts/preferences/browser/media/keybindingsEditor.css index 29b4fe0a8d1..9932877ef4d 100644 --- a/src/vs/workbench/parts/preferences/browser/media/keybindingsEditor.css +++ b/src/vs/workbench/parts/preferences/browser/media/keybindingsEditor.css @@ -68,20 +68,6 @@ display: flex; } -.keybindings-editor > .keybindings-body .keybindings-list-container .monaco-list-row.keybindings-list-header.focused, -.keybindings-editor > .keybindings-body .keybindings-list-container .monaco-list-row.keybindings-list-header.selected, -.keybindings-editor > .keybindings-body .keybindings-list-container .monaco-list-row.keybindings-list-header:hover, -.keybindings-editor > .keybindings-body > .keybindings-list-container .monaco-list-row.keybindings-list-header, -.keybindings-editor > .keybindings-body > .keybindings-list-container .monaco-list-row.even:not(.focused):not(.selected):not(:hover), -.keybindings-editor > .keybindings-body > .keybindings-list-container .monaco-list:not(:focus) .monaco-list-row.focused.even:not(.selected):not(:hover), -.keybindings-editor > .keybindings-body > .keybindings-list-container .monaco-list:not(.focused) .monaco-list-row.focused.even:not(.selected):not(:hover) { - background-color: rgba(130, 130, 130, 0.04); -} - -.keybindings-editor > .keybindings-body > .keybindings-list-container .monaco-list-row:hover { - background-color: rgba(128, 128, 128, 0.15); -} - .keybindings-editor > .keybindings-body .keybindings-list-container .monaco-list-row > .header { text-align: left; font-weight: bold; -- GitLab From 145310aea5e41c6af8de4aaf7910bdb90f0e4fea Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 08:44:16 +0200 Subject: [PATCH 0037/1347] [lua] update grammar --- extensions/lua/syntaxes/lua.json | 148 ++++++++++++++---- .../lua/test/colorize-results/test_lua.json | 32 +--- 2 files changed, 123 insertions(+), 57 deletions(-) diff --git a/extensions/lua/syntaxes/lua.json b/extensions/lua/syntaxes/lua.json index 0bde9524ea4..a4da3a43c6a 100644 --- a/extensions/lua/syntaxes/lua.json +++ b/extensions/lua/syntaxes/lua.json @@ -1,39 +1,61 @@ { "comment": "Lua Syntax: version 0.8", "fileTypes": [ - "lua" + "lua", + "p8", + "rockspec", + "luacheckrc", + "lakefile" ], - "firstLineMatch": "\\A#!.*?\\blua\\b", + "firstLineMatch": "\\A#!.*?\\blua(\\d+(\\.\\d+)?)?\\b|\\A--\\s+-\\*-\\s*lua\\s*-\\*-", "keyEquivalent": "^~L", "name": "Lua", "patterns": [ { - "captures": { + "begin": "\\b((local\\b)\\s+)?(function)\\s*(\\s+[a-zA-Z_][a-zA-Z0-9_]*(\\.[a-zA-Z_][a-zA-Z0-9_]*)*(:[a-zA-Z_][a-zA-Z0-9_]*)?\\s*)?(\\()", + "beginCaptures": { "1": { - "name": "keyword.control.lua" - }, - "2": { - "name": "entity.name.function.scope.lua" + "name": "storage.modifier.local.lua" }, "3": { - "name": "entity.name.function.lua" + "name": "keyword.control.lua" }, "4": { - "name": "punctuation.definition.parameters.begin.lua" + "name": "entity.name.function.lua" }, "5": { - "name": "variable.parameter.function.lua" - }, - "6": { + "name": "punctuation.definition.parameters.begin.lua" + } + }, + "end": "\\)", + "endCaptures": { + "0": { "name": "punctuation.definition.parameters.end.lua" } }, - "match": "\\b(function)(?:\\s+([a-zA-Z_.:]+[.:])?([a-zA-Z_]\\w*)\\s*)?(\\()([^)]*)(\\))", - "name": "meta.function.lua" + "name": "meta.function.lua", + "patterns": [ + { + "match": "[a-zA-Z_][a-zA-Z0-9_]*", + "name": "variable.parameter.function.lua" + } + ] + }, + { + "match": "(? Date: Thu, 25 May 2017 09:18:28 +0200 Subject: [PATCH 0038/1347] Allow to contribute actions to other quick open handlers (fixes #27197) --- src/vs/workbench/parts/tasks/browser/quickOpen.ts | 6 +++--- .../tasks/electron-browser/media/configure-inverse.svg | 1 + .../parts/tasks/electron-browser/media/configure.svg | 1 + .../tasks/electron-browser/media/task.contribution.css | 9 +++++++++ 4 files changed, 14 insertions(+), 3 deletions(-) create mode 100644 src/vs/workbench/parts/tasks/electron-browser/media/configure-inverse.svg create mode 100644 src/vs/workbench/parts/tasks/electron-browser/media/configure.svg diff --git a/src/vs/workbench/parts/tasks/browser/quickOpen.ts b/src/vs/workbench/parts/tasks/browser/quickOpen.ts index 754d5756a22..6c9afcd0b74 100644 --- a/src/vs/workbench/parts/tasks/browser/quickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/quickOpen.ts @@ -15,7 +15,7 @@ import { IQuickOpenService } from 'vs/platform/quickOpen/common/quickOpen'; import { Task, TaskSourceKind } from 'vs/workbench/parts/tasks/common/tasks'; import { ITaskService } from 'vs/workbench/parts/tasks/common/taskService'; -import { ActionBarContributor } from 'vs/workbench/browser/actionBarRegistry'; +import { ActionBarContributor, ContributableActionProvider } from 'vs/workbench/browser/actionBarRegistry'; export class TaskEntry extends Model.QuickOpenEntry { @@ -105,7 +105,7 @@ export abstract class QuickOpenHandler extends Quickopen.QuickOpenHandler { entries.push(this.createEntry(this.taskService, task, highlights)); } } - return new Model.QuickOpenModel(entries); + return new Model.QuickOpenModel(entries, new ContributableActionProvider()); }); } @@ -131,7 +131,7 @@ class CustomizeTaskAction extends Action { } public updateClass(): void { - this.class = 'quick-open-sidebyside-vertical'; + this.class = 'quick-open-task-configure'; } public run(context: any): TPromise { diff --git a/src/vs/workbench/parts/tasks/electron-browser/media/configure-inverse.svg b/src/vs/workbench/parts/tasks/electron-browser/media/configure-inverse.svg new file mode 100644 index 00000000000..61baaea2b8b --- /dev/null +++ b/src/vs/workbench/parts/tasks/electron-browser/media/configure-inverse.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/vs/workbench/parts/tasks/electron-browser/media/configure.svg b/src/vs/workbench/parts/tasks/electron-browser/media/configure.svg new file mode 100644 index 00000000000..3dec2ba50fd --- /dev/null +++ b/src/vs/workbench/parts/tasks/electron-browser/media/configure.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/vs/workbench/parts/tasks/electron-browser/media/task.contribution.css b/src/vs/workbench/parts/tasks/electron-browser/media/task.contribution.css index 6b1d8221b62..f8b7e9e67e5 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/media/task.contribution.css +++ b/src/vs/workbench/parts/tasks/electron-browser/media/task.contribution.css @@ -60,4 +60,13 @@ .task-statusbar-item-label > .task-statusbar-item-label-info { -webkit-mask: url('status-info.svg') no-repeat 50% 50%; -webkit-mask-size: 11px; +} + +.monaco-workbench .quick-open-task-configure { + background-image: url('configure.svg'); +} + +.vs-dark .monaco-workbench .quick-open-task-configure, +.hc-black .monaco-workbench .quick-open-task-configure { + background-image: url('configure-inverse.svg'); } \ No newline at end of file -- GitLab From 561110831b9d64440b27091f996cacd85b009a39 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 25 May 2017 09:44:01 +0200 Subject: [PATCH 0039/1347] How to configure a window (also for reload case)? (fixes #27192) --- src/vs/code/electron-main/menus.ts | 20 +++++- src/vs/code/electron-main/window.ts | 10 +-- src/vs/code/electron-main/windows.ts | 84 +---------------------- src/vs/code/node/keyboard.ts | 70 +++++++++++++++++++ src/vs/workbench/electron-browser/main.ts | 10 ++- 5 files changed, 100 insertions(+), 94 deletions(-) create mode 100644 src/vs/code/node/keyboard.ts diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index 91ccab243c9..249722e754c 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -9,7 +9,7 @@ import * as nls from 'vs/nls'; import { isMacintosh, isLinux, isWindows, language } from 'vs/base/common/platform'; import * as arrays from 'vs/base/common/arrays'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; -import { ipcMain as ipc, app, shell, dialog, Menu, MenuItem } from 'electron'; +import { ipcMain as ipc, app, shell, dialog, Menu, MenuItem, BrowserWindow } from 'electron'; import { OpenContext } from 'vs/code/common/windows'; import { IWindowsMainService } from 'vs/code/electron-main/windows'; import { VSCodeWindow } from 'vs/code/electron-main/window'; @@ -908,7 +908,7 @@ export class VSCodeMenu { label: this.mnemonicLabel(nls.localize({ key: 'miAccessibilityOptions', comment: ['&& denotes a mnemonic'] }, "Accessibility &&Options")), accelerator: null, click: () => { - this.windowsService.openAccessibilityOptions(); + this.openAccessibilityOptions(); } }, false)); @@ -974,6 +974,22 @@ export class VSCodeMenu { } } + private openAccessibilityOptions(): void { + let win = new BrowserWindow({ + alwaysOnTop: true, + skipTaskbar: true, + resizable: false, + width: 450, + height: 300, + show: true, + title: nls.localize('accessibilityOptionsWindowTitle', "Accessibility Options") + }); + + win.setMenuBarVisibility(false); + + win.loadURL('chrome://accessibility'); + } + private getUpdateMenuItems(): Electron.MenuItem[] { switch (this.updateService.state) { case UpdateState.Uninitialized: diff --git a/src/vs/code/electron-main/window.ts b/src/vs/code/electron-main/window.ts index 7cd1f647083..4b1840c8642 100644 --- a/src/vs/code/electron-main/window.ts +++ b/src/vs/code/electron-main/window.ts @@ -22,7 +22,7 @@ import product from 'vs/platform/node/product'; import { getCommonHTTPHeaders } from 'vs/platform/environment/node/http'; import { IWindowSettings, MenuBarVisibility } from 'vs/platform/windows/common/windows'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; - +import { KeyboardLayoutMonitor } from "vs/code/node/keyboard"; export interface IWindowState { width?: number; @@ -82,10 +82,7 @@ export interface IWindowConfiguration extends ParsedArgs { * The physical keyboard is of ISO type (on OSX). */ isISOKeyboard?: boolean; - /** - * Accessibility support is enabled. - */ - accessibilitySupportEnabled?: boolean; + zoomLevel?: number; fullscreen?: boolean; highContrast?: boolean; @@ -558,6 +555,9 @@ export class VSCodeWindow { windowConfiguration.highContrast = platform.isWindows && systemPreferences.isInvertedColorScheme() && (!windowConfig || windowConfig.autoDetectHighContrast); windowConfiguration.accessibilitySupport = app.isAccessibilitySupportEnabled(); + // Set Keyboard Config + windowConfiguration.isISOKeyboard = KeyboardLayoutMonitor.INSTANCE.isISOKeyboard(); + // Theme windowConfiguration.baseTheme = this.getBaseTheme(); windowConfiguration.backgroundColor = this.getBackgroundColor(); diff --git a/src/vs/code/electron-main/windows.ts b/src/vs/code/electron-main/windows.ts index 72d1091e196..b4324486c62 100644 --- a/src/vs/code/electron-main/windows.ts +++ b/src/vs/code/electron-main/windows.ts @@ -31,8 +31,7 @@ import product from 'vs/platform/node/product'; import { OpenContext } from 'vs/code/common/windows'; import { ITelemetryService, ITelemetryData } from 'vs/platform/telemetry/common/telemetry'; import { isParent, isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; -import * as nativeKeymap from 'native-keymap'; -import { IDisposable } from 'vs/base/common/lifecycle'; +import { KeyboardLayoutMonitor } from "vs/code/node/keyboard"; enum WindowError { UNRESPONSIVE, @@ -107,7 +106,6 @@ export interface IWindowsMainService { openFileFolderPicker(forceNewWindow?: boolean, data?: ITelemetryData): void; openFilePicker(forceNewWindow?: boolean, path?: string, window?: VSCodeWindow, data?: ITelemetryData): void; openFolderPicker(forceNewWindow?: boolean, window?: VSCodeWindow, data?: ITelemetryData): void; - openAccessibilityOptions(): void; focusLastActive(cli: ParsedArgs, context: OpenContext): VSCodeWindow; getLastActiveWindow(): VSCodeWindow; findWindow(workspacePath: string, filePath?: string, extensionDevelopmentPath?: string): VSCodeWindow; @@ -343,6 +341,7 @@ export class WindowsManager implements IWindowsMainService { } private onBroadcast(event: string, payload: any): void { + // Theme changes if (event === 'vscode:changeColorTheme' && typeof payload === 'string') { @@ -737,8 +736,6 @@ export class WindowsManager implements IWindowsMainService { configuration.filesToCreate = filesToCreate; configuration.filesToDiff = filesToDiff; configuration.nodeCachedDataDir = this.environmentService.nodeCachedDataDir; - configuration.isISOKeyboard = KeyboardLayoutMonitor.INSTANCE.isISOKeyboard(); - configuration.accessibilitySupportEnabled = app.isAccessibilitySupportEnabled(); return configuration; } @@ -1028,22 +1025,6 @@ export class WindowsManager implements IWindowsMainService { this.doPickAndOpen({ pickFolders: true, forceNewWindow, window }, 'openFolder', data); } - public openAccessibilityOptions(): void { - let win = new BrowserWindow({ - alwaysOnTop: true, - skipTaskbar: true, - resizable: false, - width: 450, - height: 300, - show: true, - title: nls.localize('accessibilityOptionsWindowTitle', "Accessibility Options") - }); - - win.setMenuBarVisibility(false); - - win.loadURL('chrome://accessibility'); - } - private doPickAndOpen(options: INativeOpenDialogOptions, eventName: string, data?: ITelemetryData): void { this.getFileOrFolderPaths(options, (paths: string[]) => { const nOfPaths = paths ? paths.length : 0; @@ -1338,63 +1319,4 @@ export class WindowsManager implements IWindowsMainService { }, 10 /* delay to unwind callback stack (IPC) */); } } -} - -class KeyboardLayoutMonitor { - - public static INSTANCE = new KeyboardLayoutMonitor(); - - private _emitter: Emitter; - private _registered: boolean; - private _isISOKeyboard: boolean; - - private constructor() { - this._emitter = new Emitter(); - this._registered = false; - this._isISOKeyboard = this._readIsISOKeyboard(); - } - - public onDidChangeKeyboardLayout(callback: (isISOKeyboard: boolean) => void): IDisposable { - if (!this._registered) { - this._registered = true; - - nativeKeymap.onDidChangeKeyboardLayout(() => { - this._emitter.fire(this._isISOKeyboard); - }); - - if (platform.isMacintosh) { - // See https://github.com/Microsoft/vscode/issues/24153 - // On OSX, on ISO keyboards, Chromium swaps the scan codes - // of IntlBackslash and Backquote. - // - // The C++ methods can give the current keyboard type (ISO or not) - // only after a NSEvent was handled. - // - // We therefore poll. - setInterval(() => { - let newValue = this._readIsISOKeyboard(); - if (this._isISOKeyboard === newValue) { - // no change - return; - } - - this._isISOKeyboard = newValue; - this._emitter.fire(this._isISOKeyboard); - - }, 3000); - } - } - return this._emitter.event(callback); - } - - private _readIsISOKeyboard(): boolean { - if (platform.isMacintosh) { - return nativeKeymap.isISOKeyboard(); - } - return false; - } - - public isISOKeyboard(): boolean { - return this._isISOKeyboard; - } -} +} \ No newline at end of file diff --git a/src/vs/code/node/keyboard.ts b/src/vs/code/node/keyboard.ts new file mode 100644 index 00000000000..d2f968371ef --- /dev/null +++ b/src/vs/code/node/keyboard.ts @@ -0,0 +1,70 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +'use strict'; + +import * as nativeKeymap from 'native-keymap'; +import { IDisposable } from 'vs/base/common/lifecycle'; +import { isMacintosh } from "vs/base/common/platform"; +import { Emitter } from "vs/base/common/event"; + +export class KeyboardLayoutMonitor { + + public static readonly INSTANCE = new KeyboardLayoutMonitor(); + + private _emitter: Emitter; + private _registered: boolean; + private _isISOKeyboard: boolean; + + private constructor() { + this._emitter = new Emitter(); + this._registered = false; + this._isISOKeyboard = this._readIsISOKeyboard(); + } + + public onDidChangeKeyboardLayout(callback: (isISOKeyboard: boolean) => void): IDisposable { + if (!this._registered) { + this._registered = true; + + nativeKeymap.onDidChangeKeyboardLayout(() => { + this._emitter.fire(this._isISOKeyboard); + }); + + if (isMacintosh) { + // See https://github.com/Microsoft/vscode/issues/24153 + // On OSX, on ISO keyboards, Chromium swaps the scan codes + // of IntlBackslash and Backquote. + // + // The C++ methods can give the current keyboard type (ISO or not) + // only after a NSEvent was handled. + // + // We therefore poll. + setInterval(() => { + let newValue = this._readIsISOKeyboard(); + if (this._isISOKeyboard === newValue) { + // no change + return; + } + + this._isISOKeyboard = newValue; + this._emitter.fire(this._isISOKeyboard); + + }, 3000); + } + } + return this._emitter.event(callback); + } + + private _readIsISOKeyboard(): boolean { + if (isMacintosh) { + return nativeKeymap.isISOKeyboard(); + } + return false; + } + + public isISOKeyboard(): boolean { + return this._isISOKeyboard; + } +} diff --git a/src/vs/workbench/electron-browser/main.ts b/src/vs/workbench/electron-browser/main.ts index fb179f3196c..b20a6fd422a 100644 --- a/src/vs/workbench/electron-browser/main.ts +++ b/src/vs/workbench/electron-browser/main.ts @@ -42,10 +42,7 @@ export interface IWindowConfiguration extends ParsedArgs, IOpenFileRequest { */ isISOKeyboard?: boolean; - /** - * Accessibility support is enabled. - */ - accessibilitySupportEnabled?: boolean; + accessibilitySupport?: boolean; appRoot: string; execPath: string; @@ -62,15 +59,16 @@ export function startup(configuration: IWindowConfiguration): TPromise { // Ensure others can listen to zoom level changes browser.setZoomFactor(webFrame.getZoomFactor()); + // See https://github.com/Microsoft/vscode/issues/26151 // Can be trusted because we are not setting it ourselves. - browser.setZoomLevel(webFrame.getZoomLevel(), /*isTrusted*/true); + browser.setZoomLevel(webFrame.getZoomLevel(), true /* isTrusted */); browser.setFullscreen(!!configuration.fullscreen); KeyboardMapperFactory.INSTANCE._onKeyboardLayoutChanged(configuration.isISOKeyboard); - browser.setAccessibilitySupport(configuration.accessibilitySupportEnabled ? platform.AccessibilitySupport.Enabled : platform.AccessibilitySupport.Disabled); + browser.setAccessibilitySupport(configuration.accessibilitySupport ? platform.AccessibilitySupport.Enabled : platform.AccessibilitySupport.Disabled); // Setup Intl comparer.setFileNameComparer(new Intl.Collator(undefined, { numeric: true, sensitivity: 'base' })); -- GitLab From 1d0b00c60ebd2e3513332d5abf5d274bef96fa66 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 25 May 2017 09:53:23 +0200 Subject: [PATCH 0040/1347] linting: convert double quote imports to single quote --- extensions/typescript/src/utils/logger.ts | 2 +- extensions/typescript/src/utils/plugins.ts | 2 +- extensions/typescript/src/utils/telemetry.ts | 2 +- src/vs/base/browser/ui/countBadge/countBadge.ts | 4 ++-- .../base/browser/ui/progressbar/progressbar.ts | 4 ++-- src/vs/base/test/common/json.test.ts | 2 +- src/vs/code/electron-main/window.ts | 2 +- src/vs/code/electron-main/windows.ts | 2 +- src/vs/code/node/keyboard.ts | 4 ++-- .../editor/browser/controller/textAreaHandler.ts | 12 ++++++------ .../editor/browser/controller/textAreaInput.ts | 4 ++-- src/vs/editor/browser/view/viewController.ts | 2 +- src/vs/editor/browser/view/viewImpl.ts | 2 +- .../viewParts/editorScrollbar/editorScrollbar.ts | 2 +- .../editor/browser/viewParts/minimap/minimap.ts | 4 ++-- .../scrollDecoration/scrollDecoration.ts | 4 ++-- src/vs/editor/browser/widget/diffEditorWidget.ts | 2 +- src/vs/editor/common/commonCodeEditor.ts | 4 ++-- src/vs/editor/common/config/fontInfo.ts | 2 +- src/vs/editor/common/controller/accGenerator.ts | 2 +- src/vs/editor/common/controller/coreCommands.ts | 6 +++--- src/vs/editor/common/controller/cursor.ts | 2 +- src/vs/editor/common/controller/cursorCommon.ts | 2 +- .../common/controller/cursorDeleteOperations.ts | 2 +- .../common/controller/cursorTypeOperations.ts | 2 +- .../common/controller/cursorWordOperations.ts | 2 +- src/vs/editor/common/model/textModel.ts | 2 +- src/vs/editor/common/model/textModelSearch.ts | 2 +- .../editor/common/services/modelServiceImpl.ts | 2 +- src/vs/editor/common/standalone/themes.ts | 4 ++-- src/vs/editor/common/view/viewEvents.ts | 2 +- src/vs/editor/common/viewLayout/viewLayout.ts | 2 +- .../common/viewModel/splitLinesCollection.ts | 2 +- src/vs/editor/common/viewModel/viewModel.ts | 6 +++--- src/vs/editor/common/viewModel/viewModelImpl.ts | 2 +- .../bracketMatching/common/bracketMatching.ts | 6 +++--- .../editor/contrib/codelens/browser/codelens.ts | 8 ++++---- .../test/common/lineCommentCommand.test.ts | 6 +++--- src/vs/editor/contrib/dnd/browser/dnd.ts | 2 +- .../editor/contrib/find/common/findController.ts | 2 +- .../contrib/find/common/findDecorations.ts | 2 +- .../contrib/folding/common/foldingModel.ts | 2 +- .../browser/goToDeclarationMouse.ts | 2 +- .../contrib/hover/browser/modesContentHover.ts | 2 +- .../inPlaceReplace/common/inPlaceReplace.ts | 2 +- .../linesOperations/common/linesOperations.ts | 2 +- .../test/common/linesOperations.test.ts | 6 +++--- src/vs/editor/contrib/links/browser/links.ts | 4 ++-- .../contrib/quickOpen/browser/editorQuickOpen.ts | 2 +- .../referenceSearch/browser/referencesWidget.ts | 4 ++-- .../contrib/snippet/browser/snippetSession.ts | 2 +- .../test/browser/snippetController2.old.test.ts | 4 ++-- .../test/browser/snippetController2.test.ts | 2 +- .../snippet/test/browser/snippetSession.test.ts | 2 +- .../wordHighlighter/common/wordHighlighter.ts | 2 +- .../wordOperations/common/wordOperations.ts | 6 +++--- .../test/common/wordOperations.test.ts | 2 +- .../contrib/zoneWidget/browser/zoneWidget.ts | 2 +- src/vs/editor/editor.main.ts | 2 +- .../browser/controller/textAreaState.test.ts | 2 +- .../test/common/commands/commandTestUtils.ts | 2 +- .../test/common/commands/sideEditing.test.ts | 2 +- .../common/config/commonEditorConfig.test.ts | 4 ++-- .../editor/test/common/controller/cursor.test.ts | 10 +++++----- .../common/controller/cursorMoveCommand.test.ts | 2 +- .../test/common/mocks/testConfiguration.ts | 2 +- .../test/common/model/textModelSearch.test.ts | 4 ++-- src/vs/workbench/browser/parts/compositePart.ts | 2 +- .../browser/parts/editor/editorGroupsControl.ts | 2 +- .../browser/parts/editor/webviewEditor.ts | 8 ++++---- .../browser/parts/statusbar/statusbarPart.ts | 2 +- .../workbench/common/editor/rangeDecorations.ts | 2 +- src/vs/workbench/electron-browser/workbench.ts | 8 ++++---- src/vs/workbench/node/extensionPoints.ts | 2 +- .../parts/debug/browser/debugActionItems.ts | 2 +- .../parts/debug/browser/exceptionWidget.ts | 6 +++--- .../electron-browser/debugEditorContribution.ts | 2 +- .../parts/debug/electron-browser/debugHover.ts | 2 +- .../electron-browser/statusbarColorProvider.ts | 2 +- .../actions/expandAbbreviation.ts | 2 +- .../emmet/electron-browser/editorAccessor.ts | 2 +- .../extensions/browser/extensionsActions.ts | 6 +++--- .../parts/feedback/electron-browser/feedback.ts | 6 +++--- .../electron-browser/feedbackStatusbarItem.ts | 2 +- .../parts/files/browser/views/openEditorsView.ts | 2 +- .../parts/markers/browser/markersTreeViewer.ts | 6 +++--- .../preferences/browser/keybindingWidgets.ts | 2 +- .../preferences/browser/keybindingsEditor.ts | 2 +- .../preferences/browser/preferencesEditor.ts | 4 ++-- .../preferences/browser/preferencesRenderers.ts | 2 +- .../preferences/browser/preferencesWidgets.ts | 2 +- .../parts/quickopen/browser/commandsHandler.ts | 2 +- .../scm/electron-browser/dirtydiffDecorator.ts | 10 +++++----- .../parts/search/browser/openFileHandler.ts | 2 +- .../parts/search/browser/searchResultsView.ts | 4 ++-- .../parts/search/browser/searchViewlet.ts | 2 +- src/vs/workbench/parts/search/common/search.ts | 8 ++++---- .../workbench/parts/search/common/searchModel.ts | 2 +- .../snippets/electron-browser/TMSnippets.ts | 2 +- .../electron-browser/terminal.contribution.ts | 2 +- .../electron-browser/terminalConfigHelper.ts | 2 +- .../electron-browser/terminalInstance.ts | 4 ++-- .../terminalConfigHelper.test.ts | 2 +- .../electron-browser/releaseNotesEditor.ts | 2 +- .../editor/test/browser/editorService.test.ts | 2 +- .../themes/electron-browser/colorThemeData.ts | 2 +- .../electron-browser/workbenchThemeService.ts | 2 +- .../test/browser/parts/editor/baseEditor.test.ts | 2 +- .../test/common/editor/editorDiffModel.test.ts | 16 ++++++++-------- 109 files changed, 177 insertions(+), 177 deletions(-) diff --git a/extensions/typescript/src/utils/logger.ts b/extensions/typescript/src/utils/logger.ts index 7f82fb28c96..8e31d66d858 100644 --- a/extensions/typescript/src/utils/logger.ts +++ b/extensions/typescript/src/utils/logger.ts @@ -3,7 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import { OutputChannel, window } from "vscode"; +import { OutputChannel, window } from 'vscode'; import * as is from './is'; import * as nls from 'vscode-nls'; diff --git a/extensions/typescript/src/utils/plugins.ts b/extensions/typescript/src/utils/plugins.ts index 49f0d93b4b6..23342cc8b31 100644 --- a/extensions/typescript/src/utils/plugins.ts +++ b/extensions/typescript/src/utils/plugins.ts @@ -3,7 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import { extensions } from "vscode"; +import { extensions } from 'vscode'; export interface TypeScriptServerPlugin { diff --git a/extensions/typescript/src/utils/telemetry.ts b/extensions/typescript/src/utils/telemetry.ts index 5162a0c24d5..b687b11b4ac 100644 --- a/extensions/typescript/src/utils/telemetry.ts +++ b/extensions/typescript/src/utils/telemetry.ts @@ -5,7 +5,7 @@ import * as path from 'path'; import VsCodeTelemetryReporter from 'vscode-extension-telemetry'; -import { Disposable } from "vscode"; +import { Disposable } from 'vscode'; interface IPackageInfo { diff --git a/src/vs/base/browser/ui/countBadge/countBadge.ts b/src/vs/base/browser/ui/countBadge/countBadge.ts index a7fa56efce8..8ff58693925 100644 --- a/src/vs/base/browser/ui/countBadge/countBadge.ts +++ b/src/vs/base/browser/ui/countBadge/countBadge.ts @@ -8,8 +8,8 @@ import 'vs/css!./countBadge'; import { $, append } from 'vs/base/browser/dom'; import { format } from 'vs/base/common/strings'; -import { Color } from "vs/base/common/color"; -import { mixin } from "vs/base/common/objects"; +import { Color } from 'vs/base/common/color'; +import { mixin } from 'vs/base/common/objects'; export interface ICountBadgeOptions extends ICountBadgetyles { count?: number; diff --git a/src/vs/base/browser/ui/progressbar/progressbar.ts b/src/vs/base/browser/ui/progressbar/progressbar.ts index 1287112824b..ea34e06e1cb 100644 --- a/src/vs/base/browser/ui/progressbar/progressbar.ts +++ b/src/vs/base/browser/ui/progressbar/progressbar.ts @@ -11,8 +11,8 @@ import assert = require('vs/base/common/assert'); import { Builder, $ } from 'vs/base/browser/builder'; import DOM = require('vs/base/browser/dom'); import { IDisposable, dispose } from 'vs/base/common/lifecycle'; -import { Color } from "vs/base/common/color"; -import { mixin } from "vs/base/common/objects"; +import { Color } from 'vs/base/common/color'; +import { mixin } from 'vs/base/common/objects'; const css_done = 'done'; const css_active = 'active'; diff --git a/src/vs/base/test/common/json.test.ts b/src/vs/base/test/common/json.test.ts index 42a0804c113..fe129f08808 100644 --- a/src/vs/base/test/common/json.test.ts +++ b/src/vs/base/test/common/json.test.ts @@ -8,7 +8,7 @@ import * as assert from 'assert'; import { SyntaxKind, createScanner, parse, getLocation, Node, ParseError, parseTree, ParseErrorCode, ParseOptions, Segment, findNodeAtLocation, getNodeValue, ScanError } from 'vs/base/common/json'; -import { getParseErrorMessage } from "vs/base/common/jsonErrorMessages"; +import { getParseErrorMessage } from 'vs/base/common/jsonErrorMessages'; function assertKinds(text: string, ...kinds: SyntaxKind[]): void { var scanner = createScanner(text); diff --git a/src/vs/code/electron-main/window.ts b/src/vs/code/electron-main/window.ts index 4b1840c8642..91d560b50fd 100644 --- a/src/vs/code/electron-main/window.ts +++ b/src/vs/code/electron-main/window.ts @@ -22,7 +22,7 @@ import product from 'vs/platform/node/product'; import { getCommonHTTPHeaders } from 'vs/platform/environment/node/http'; import { IWindowSettings, MenuBarVisibility } from 'vs/platform/windows/common/windows'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; -import { KeyboardLayoutMonitor } from "vs/code/node/keyboard"; +import { KeyboardLayoutMonitor } from 'vs/code/node/keyboard'; export interface IWindowState { width?: number; diff --git a/src/vs/code/electron-main/windows.ts b/src/vs/code/electron-main/windows.ts index b4324486c62..cc0800f25e6 100644 --- a/src/vs/code/electron-main/windows.ts +++ b/src/vs/code/electron-main/windows.ts @@ -31,7 +31,7 @@ import product from 'vs/platform/node/product'; import { OpenContext } from 'vs/code/common/windows'; import { ITelemetryService, ITelemetryData } from 'vs/platform/telemetry/common/telemetry'; import { isParent, isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; -import { KeyboardLayoutMonitor } from "vs/code/node/keyboard"; +import { KeyboardLayoutMonitor } from 'vs/code/node/keyboard'; enum WindowError { UNRESPONSIVE, diff --git a/src/vs/code/node/keyboard.ts b/src/vs/code/node/keyboard.ts index d2f968371ef..16979fc90c0 100644 --- a/src/vs/code/node/keyboard.ts +++ b/src/vs/code/node/keyboard.ts @@ -7,8 +7,8 @@ import * as nativeKeymap from 'native-keymap'; import { IDisposable } from 'vs/base/common/lifecycle'; -import { isMacintosh } from "vs/base/common/platform"; -import { Emitter } from "vs/base/common/event"; +import { isMacintosh } from 'vs/base/common/platform'; +import { Emitter } from 'vs/base/common/event'; export class KeyboardLayoutMonitor { diff --git a/src/vs/editor/browser/controller/textAreaHandler.ts b/src/vs/editor/browser/controller/textAreaHandler.ts index f9ae737307e..e927fcb4ab1 100644 --- a/src/vs/editor/browser/controller/textAreaHandler.ts +++ b/src/vs/editor/browser/controller/textAreaHandler.ts @@ -18,12 +18,12 @@ import { HorizontalRange, RenderingContext, RestrictedRenderingContext } from 'v import * as viewEvents from 'vs/editor/common/view/viewEvents'; import { FastDomNode, createFastDomNode } from 'vs/base/browser/fastDomNode'; import { ViewController } from 'vs/editor/browser/view/viewController'; -import { EndOfLinePreference } from "vs/editor/common/editorCommon"; -import { IKeyboardEvent } from "vs/base/browser/keyboardEvent"; -import { PartFingerprints, PartFingerprint, ViewPart } from "vs/editor/browser/view/viewPart"; -import { Margin } from "vs/editor/browser/viewParts/margin/margin"; -import { LineNumbersOverlay } from "vs/editor/browser/viewParts/lineNumbers/lineNumbers"; -import { BareFontInfo } from "vs/editor/common/config/fontInfo"; +import { EndOfLinePreference } from 'vs/editor/common/editorCommon'; +import { IKeyboardEvent } from 'vs/base/browser/keyboardEvent'; +import { PartFingerprints, PartFingerprint, ViewPart } from 'vs/editor/browser/view/viewPart'; +import { Margin } from 'vs/editor/browser/viewParts/margin/margin'; +import { LineNumbersOverlay } from 'vs/editor/browser/viewParts/lineNumbers/lineNumbers'; +import { BareFontInfo } from 'vs/editor/common/config/fontInfo'; export interface ITextAreaHandlerHelper { visibleRangeForPositionRelativeToEditor(lineNumber: number, column: number): HorizontalRange; diff --git a/src/vs/editor/browser/controller/textAreaInput.ts b/src/vs/editor/browser/controller/textAreaInput.ts index 757bbf1dd41..e1f99b036e8 100644 --- a/src/vs/editor/browser/controller/textAreaInput.ts +++ b/src/vs/editor/browser/controller/textAreaInput.ts @@ -13,8 +13,8 @@ import { ITypeData, TextAreaState, ITextAreaWrapper } from 'vs/editor/browser/co import * as browser from 'vs/base/browser/browser'; import * as platform from 'vs/base/common/platform'; import * as dom from 'vs/base/browser/dom'; -import { IKeyboardEvent } from "vs/base/browser/keyboardEvent"; -import { FastDomNode } from "vs/base/browser/fastDomNode"; +import { IKeyboardEvent } from 'vs/base/browser/keyboardEvent'; +import { FastDomNode } from 'vs/base/browser/fastDomNode'; export interface ICompositionData { data: string; diff --git a/src/vs/editor/browser/view/viewController.ts b/src/vs/editor/browser/view/viewController.ts index e05ca74ea60..51beeeade27 100644 --- a/src/vs/editor/browser/view/viewController.ts +++ b/src/vs/editor/browser/view/viewController.ts @@ -12,7 +12,7 @@ import { ICommandService } from 'vs/platform/commands/common/commands'; import { IViewModel } from 'vs/editor/common/viewModel/viewModel'; import { ViewOutgoingEvents } from 'vs/editor/browser/view/viewOutgoingEvents'; import { CoreNavigationCommands, CoreEditorCommand } from 'vs/editor/common/controller/coreCommands'; -import { Configuration } from "vs/editor/browser/config/configuration"; +import { Configuration } from 'vs/editor/browser/config/configuration'; export interface ExecCoreEditorCommandFunc { (editorCommand: CoreEditorCommand, args: any): void; diff --git a/src/vs/editor/browser/view/viewImpl.ts b/src/vs/editor/browser/view/viewImpl.ts index 927c1d19486..2ac56ac2773 100644 --- a/src/vs/editor/browser/view/viewImpl.ts +++ b/src/vs/editor/browser/view/viewImpl.ts @@ -48,7 +48,7 @@ import { EditorScrollbar } from 'vs/editor/browser/viewParts/editorScrollbar/edi import { Minimap } from 'vs/editor/browser/viewParts/minimap/minimap'; import * as viewEvents from 'vs/editor/common/view/viewEvents'; import { IThemeService, getThemeTypeSelector } from 'vs/platform/theme/common/themeService'; -import { Cursor } from "vs/editor/common/controller/cursor"; +import { Cursor } from 'vs/editor/common/controller/cursor'; export interface IContentWidgetData { widget: editorBrowser.IContentWidget; diff --git a/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.ts b/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.ts index 11d53265128..89aee09559d 100644 --- a/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.ts +++ b/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.ts @@ -13,7 +13,7 @@ import { ViewContext } from 'vs/editor/common/view/viewContext'; import * as viewEvents from 'vs/editor/common/view/viewEvents'; import { RenderingContext, RestrictedRenderingContext } from 'vs/editor/common/view/renderingContext'; import { FastDomNode, createFastDomNode } from 'vs/base/browser/fastDomNode'; -import { getThemeTypeSelector } from "vs/platform/theme/common/themeService"; +import { getThemeTypeSelector } from 'vs/platform/theme/common/themeService'; export class EditorScrollbar extends ViewPart { diff --git a/src/vs/editor/browser/viewParts/minimap/minimap.ts b/src/vs/editor/browser/viewParts/minimap/minimap.ts index 9c922137ede..46d8dde55d5 100644 --- a/src/vs/editor/browser/viewParts/minimap/minimap.ts +++ b/src/vs/editor/browser/viewParts/minimap/minimap.ts @@ -25,8 +25,8 @@ import { RGBA } from 'vs/base/common/color'; import * as viewEvents from 'vs/editor/common/view/viewEvents'; import { GlobalMouseMoveMonitor, IStandardMouseMoveEventData, standardMouseMoveMerger } from 'vs/base/browser/globalMouseMoveMonitor'; import * as platform from 'vs/base/common/platform'; -import { registerThemingParticipant } from "vs/platform/theme/common/themeService"; -import { scrollbarSliderBackground, scrollbarSliderHoverBackground, scrollbarSliderActiveBackground, scrollbarShadow } from "vs/platform/theme/common/colorRegistry"; +import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; +import { scrollbarSliderBackground, scrollbarSliderHoverBackground, scrollbarSliderActiveBackground, scrollbarShadow } from 'vs/platform/theme/common/colorRegistry'; const enum RenderMinimap { None = 0, diff --git a/src/vs/editor/browser/viewParts/scrollDecoration/scrollDecoration.ts b/src/vs/editor/browser/viewParts/scrollDecoration/scrollDecoration.ts index 92134f722a1..e4086a1e00a 100644 --- a/src/vs/editor/browser/viewParts/scrollDecoration/scrollDecoration.ts +++ b/src/vs/editor/browser/viewParts/scrollDecoration/scrollDecoration.ts @@ -11,8 +11,8 @@ import { ViewPart } from 'vs/editor/browser/view/viewPart'; import { ViewContext } from 'vs/editor/common/view/viewContext'; import { RenderingContext, RestrictedRenderingContext } from 'vs/editor/common/view/renderingContext'; import * as viewEvents from 'vs/editor/common/view/viewEvents'; -import { registerThemingParticipant } from "vs/platform/theme/common/themeService"; -import { scrollbarShadow } from "vs/platform/theme/common/colorRegistry"; +import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; +import { scrollbarShadow } from 'vs/platform/theme/common/colorRegistry'; export class ScrollDecorationViewPart extends ViewPart { diff --git a/src/vs/editor/browser/widget/diffEditorWidget.ts b/src/vs/editor/browser/widget/diffEditorWidget.ts index c655b958451..556c843ce15 100644 --- a/src/vs/editor/browser/widget/diffEditorWidget.ts +++ b/src/vs/editor/browser/widget/diffEditorWidget.ts @@ -36,7 +36,7 @@ import { scrollbarShadow, diffInserted, diffRemoved, defaultInsertColor, default import { Color } from 'vs/base/common/color'; import { OverviewRulerZone } from 'vs/editor/common/view/overviewZoneManager'; import { IEditorWhitespace } from 'vs/editor/common/viewLayout/whitespaceComputer'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; interface IEditorDiffDecorations { decorations: editorCommon.IModelDeltaDecoration[]; diff --git a/src/vs/editor/common/commonCodeEditor.ts b/src/vs/editor/common/commonCodeEditor.ts index d8b808d3f06..c5285a83724 100644 --- a/src/vs/editor/common/commonCodeEditor.ts +++ b/src/vs/editor/common/commonCodeEditor.ts @@ -28,8 +28,8 @@ import { import * as editorOptions from 'vs/editor/common/config/editorOptions'; import { ICursorPositionChangedEvent, ICursorSelectionChangedEvent } from 'vs/editor/common/controller/cursorEvents'; import { EditorContextKeys } from 'vs/editor/common/editorContextKeys'; -import { CommonEditorRegistry } from "vs/editor/common/editorCommonExtensions"; -import { VerticalRevealType } from "vs/editor/common/view/viewEvents"; +import { CommonEditorRegistry } from 'vs/editor/common/editorCommonExtensions'; +import { VerticalRevealType } from 'vs/editor/common/view/viewEvents'; let EDITOR_ID = 0; diff --git a/src/vs/editor/common/config/fontInfo.ts b/src/vs/editor/common/config/fontInfo.ts index 7740776bebf..9ab9a11d2a9 100644 --- a/src/vs/editor/common/config/fontInfo.ts +++ b/src/vs/editor/common/config/fontInfo.ts @@ -6,7 +6,7 @@ import * as platform from 'vs/base/common/platform'; import { EditorZoom } from 'vs/editor/common/config/editorZoom'; -import { EDITOR_FONT_DEFAULTS } from "vs/editor/common/config/editorOptions"; +import { EDITOR_FONT_DEFAULTS } from 'vs/editor/common/config/editorOptions'; /** * Determined from empirical observations. diff --git a/src/vs/editor/common/controller/accGenerator.ts b/src/vs/editor/common/controller/accGenerator.ts index 6f6bb813e6b..ca556f79d2d 100644 --- a/src/vs/editor/common/controller/accGenerator.ts +++ b/src/vs/editor/common/controller/accGenerator.ts @@ -8,7 +8,7 @@ import { Position } from 'vs/editor/common/core/position'; import * as nls from 'vs/nls'; import { Range } from 'vs/editor/common/core/range'; -import { IModel } from "vs/editor/common/editorCommon"; +import { IModel } from 'vs/editor/common/editorCommon'; import { Selection } from 'vs/editor/common/core/selection'; export class ScreenReaderMessageGenerator { diff --git a/src/vs/editor/common/controller/coreCommands.ts b/src/vs/editor/common/controller/coreCommands.ts index 639022470cd..e0a3cd88f63 100644 --- a/src/vs/editor/common/controller/coreCommands.ts +++ b/src/vs/editor/common/controller/coreCommands.ts @@ -23,9 +23,9 @@ import { ContextKeyExpr } from 'vs/platform/contextkey/common/contextkey'; import * as types from 'vs/base/common/types'; import { ICommandHandlerDescription } from 'vs/platform/commands/common/commands'; import { IEditorService } from 'vs/platform/editor/common/editor'; -import { TypeOperations } from "vs/editor/common/controller/cursorTypeOperations"; -import { DeleteOperations } from "vs/editor/common/controller/cursorDeleteOperations"; -import { VerticalRevealType } from "vs/editor/common/view/viewEvents"; +import { TypeOperations } from 'vs/editor/common/controller/cursorTypeOperations'; +import { DeleteOperations } from 'vs/editor/common/controller/cursorDeleteOperations'; +import { VerticalRevealType } from 'vs/editor/common/view/viewEvents'; const CORE_WEIGHT = KeybindingsRegistry.WEIGHT.editorCore(); diff --git a/src/vs/editor/common/controller/cursor.ts b/src/vs/editor/common/controller/cursor.ts index 305894d79b6..0c203347cce 100644 --- a/src/vs/editor/common/controller/cursor.ts +++ b/src/vs/editor/common/controller/cursor.ts @@ -18,7 +18,7 @@ import { DeleteOperations } from 'vs/editor/common/controller/cursorDeleteOperat import { TypeOperations } from 'vs/editor/common/controller/cursorTypeOperations'; import { TextModelEventType, ModelRawContentChangedEvent, RawContentChangedType } from 'vs/editor/common/model/textModelEvents'; import { CursorChangeReason } from 'vs/editor/common/controller/cursorEvents'; -import { IViewModel } from "vs/editor/common/viewModel/viewModel"; +import { IViewModel } from 'vs/editor/common/viewModel/viewModel'; import * as viewEvents from 'vs/editor/common/view/viewEvents'; import Event, { Emitter } from 'vs/base/common/event'; // import { ScreenReaderMessageGenerator } from "vs/editor/common/controller/accGenerator"; diff --git a/src/vs/editor/common/controller/cursorCommon.ts b/src/vs/editor/common/controller/cursorCommon.ts index e82708d17da..55e00ad1e43 100644 --- a/src/vs/editor/common/controller/cursorCommon.ts +++ b/src/vs/editor/common/controller/cursorCommon.ts @@ -18,7 +18,7 @@ import { IAutoClosingPair } from 'vs/editor/common/modes/languageConfiguration'; import { IConfigurationChangedEvent } from 'vs/editor/common/config/editorOptions'; import { IViewModel } from 'vs/editor/common/viewModel/viewModel'; import { CursorChangeReason } from 'vs/editor/common/controller/cursorEvents'; -import { VerticalRevealType } from "vs/editor/common/view/viewEvents"; +import { VerticalRevealType } from 'vs/editor/common/view/viewEvents'; export interface IColumnSelectData { toViewLineNumber: number; diff --git a/src/vs/editor/common/controller/cursorDeleteOperations.ts b/src/vs/editor/common/controller/cursorDeleteOperations.ts index c968bb49f76..7951ab91b83 100644 --- a/src/vs/editor/common/controller/cursorDeleteOperations.ts +++ b/src/vs/editor/common/controller/cursorDeleteOperations.ts @@ -10,7 +10,7 @@ import { Range } from 'vs/editor/common/core/range'; import { Selection } from 'vs/editor/common/core/selection'; import { MoveOperations } from 'vs/editor/common/controller/cursorMoveOperations'; import * as strings from 'vs/base/common/strings'; -import { ICommand } from "vs/editor/common/editorCommon"; +import { ICommand } from 'vs/editor/common/editorCommon'; export class DeleteOperations { diff --git a/src/vs/editor/common/controller/cursorTypeOperations.ts b/src/vs/editor/common/controller/cursorTypeOperations.ts index cb2b2184669..6abac0a543e 100644 --- a/src/vs/editor/common/controller/cursorTypeOperations.ts +++ b/src/vs/editor/common/controller/cursorTypeOperations.ts @@ -16,7 +16,7 @@ import { LanguageConfigurationRegistry } from 'vs/editor/common/modes/languageCo import { IndentAction } from 'vs/editor/common/modes/languageConfiguration'; import { SurroundSelectionCommand } from 'vs/editor/common/commands/surroundSelectionCommand'; import { IElectricAction } from 'vs/editor/common/modes/supports/electricCharacter'; -import { getMapForWordSeparators, WordCharacterClass } from "vs/editor/common/controller/wordCharacterClassifier"; +import { getMapForWordSeparators, WordCharacterClass } from 'vs/editor/common/controller/wordCharacterClassifier'; export class TypeOperations { diff --git a/src/vs/editor/common/controller/cursorWordOperations.ts b/src/vs/editor/common/controller/cursorWordOperations.ts index 305cfe68392..3666961a2a2 100644 --- a/src/vs/editor/common/controller/cursorWordOperations.ts +++ b/src/vs/editor/common/controller/cursorWordOperations.ts @@ -6,7 +6,7 @@ import { SingleCursorState, CursorConfiguration, ICursorSimpleModel } from 'vs/editor/common/controller/cursorCommon'; import { Position } from 'vs/editor/common/core/position'; -import { WordCharacterClassifier, WordCharacterClass, getMapForWordSeparators } from "vs/editor/common/controller/wordCharacterClassifier"; +import { WordCharacterClassifier, WordCharacterClass, getMapForWordSeparators } from 'vs/editor/common/controller/wordCharacterClassifier'; import * as strings from 'vs/base/common/strings'; import { Range } from 'vs/editor/common/core/range'; import { Selection } from 'vs/editor/common/core/selection'; diff --git a/src/vs/editor/common/model/textModel.ts b/src/vs/editor/common/model/textModel.ts index 0d7ec1065b4..d15842430f3 100644 --- a/src/vs/editor/common/model/textModel.ts +++ b/src/vs/editor/common/model/textModel.ts @@ -11,7 +11,7 @@ import { Range, IRange } from 'vs/editor/common/core/range'; import * as editorCommon from 'vs/editor/common/editorCommon'; import { ModelLine } from 'vs/editor/common/model/modelLine'; import { guessIndentation } from 'vs/editor/common/model/indentationGuesser'; -import { EDITOR_MODEL_DEFAULTS } from "vs/editor/common/config/editorOptions"; +import { EDITOR_MODEL_DEFAULTS } from 'vs/editor/common/config/editorOptions'; import { PrefixSumComputer } from 'vs/editor/common/viewModel/prefixSumComputer'; import { IndentRange, computeRanges } from 'vs/editor/common/model/indentRanges'; import { TextModelSearch, SearchParams } from 'vs/editor/common/model/textModelSearch'; diff --git a/src/vs/editor/common/model/textModelSearch.ts b/src/vs/editor/common/model/textModelSearch.ts index d19ad9e608c..af265935776 100644 --- a/src/vs/editor/common/model/textModelSearch.ts +++ b/src/vs/editor/common/model/textModelSearch.ts @@ -10,7 +10,7 @@ import { Range } from 'vs/editor/common/core/range'; import { FindMatch, EndOfLinePreference } from 'vs/editor/common/editorCommon'; import { CharCode } from 'vs/base/common/charCode'; import { TextModel } from 'vs/editor/common/model/textModel'; -import { getMapForWordSeparators, WordCharacterClassifier, WordCharacterClass } from "vs/editor/common/controller/wordCharacterClassifier"; +import { getMapForWordSeparators, WordCharacterClassifier, WordCharacterClass } from 'vs/editor/common/controller/wordCharacterClassifier'; const LIMIT_FIND_COUNT = 999; diff --git a/src/vs/editor/common/services/modelServiceImpl.ts b/src/vs/editor/common/services/modelServiceImpl.ts index 5fee6ded32a..5bcb68eba4b 100644 --- a/src/vs/editor/common/services/modelServiceImpl.ts +++ b/src/vs/editor/common/services/modelServiceImpl.ts @@ -21,7 +21,7 @@ import { IMode, LanguageIdentifier } from 'vs/editor/common/modes'; import { IModelService } from 'vs/editor/common/services/modelService'; import * as platform from 'vs/base/common/platform'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { EDITOR_MODEL_DEFAULTS } from "vs/editor/common/config/editorOptions"; +import { EDITOR_MODEL_DEFAULTS } from 'vs/editor/common/config/editorOptions'; import { PLAINTEXT_LANGUAGE_IDENTIFIER } from 'vs/editor/common/modes/modesRegistry'; import { IRawTextSource, TextSource, RawTextSource } from 'vs/editor/common/model/textSource'; import * as textModelEvents from 'vs/editor/common/model/textModelEvents'; diff --git a/src/vs/editor/common/standalone/themes.ts b/src/vs/editor/common/standalone/themes.ts index a97a9fab1ee..8093472bba8 100644 --- a/src/vs/editor/common/standalone/themes.ts +++ b/src/vs/editor/common/standalone/themes.ts @@ -6,8 +6,8 @@ 'use strict'; import { IStandaloneThemeData } from 'vs/editor/common/services/standaloneThemeService'; -import { editorBackground, editorForeground, editorSelectionHighlight, editorInactiveSelection } from "vs/platform/theme/common/colorRegistry"; -import { editorIndentGuides } from "vs/editor/common/view/editorColorRegistry"; +import { editorBackground, editorForeground, editorSelectionHighlight, editorInactiveSelection } from 'vs/platform/theme/common/colorRegistry'; +import { editorIndentGuides } from 'vs/editor/common/view/editorColorRegistry'; /* -------------------------------- Begin vs theme -------------------------------- */ export const vs: IStandaloneThemeData = { diff --git a/src/vs/editor/common/view/viewEvents.ts b/src/vs/editor/common/view/viewEvents.ts index f6696746fbf..72fc6b41fbe 100644 --- a/src/vs/editor/common/view/viewEvents.ts +++ b/src/vs/editor/common/view/viewEvents.ts @@ -9,7 +9,7 @@ import { Selection } from 'vs/editor/common/core/selection'; import { ScrollEvent } from 'vs/base/common/scrollable'; import { IConfigurationChangedEvent } from 'vs/editor/common/config/editorOptions'; import * as errors from 'vs/base/common/errors'; -import { IDisposable, Disposable } from "vs/base/common/lifecycle"; +import { IDisposable, Disposable } from 'vs/base/common/lifecycle'; export const enum ViewEventType { ViewConfigurationChanged = 1, diff --git a/src/vs/editor/common/viewLayout/viewLayout.ts b/src/vs/editor/common/viewLayout/viewLayout.ts index e6a9d763d29..4af8cbd5235 100644 --- a/src/vs/editor/common/viewLayout/viewLayout.ts +++ b/src/vs/editor/common/viewLayout/viewLayout.ts @@ -12,7 +12,7 @@ import { IViewLayout, IViewWhitespaceViewportData, Viewport } from 'vs/editor/co import { IPartialViewLinesViewportData } from 'vs/editor/common/viewLayout/viewLinesViewportData'; import { IEditorWhitespace } from 'vs/editor/common/viewLayout/whitespaceComputer'; import Event from 'vs/base/common/event'; -import { IConfigurationChangedEvent } from "vs/editor/common/config/editorOptions"; +import { IConfigurationChangedEvent } from 'vs/editor/common/config/editorOptions'; export class ViewLayout extends Disposable implements IViewLayout { diff --git a/src/vs/editor/common/viewModel/splitLinesCollection.ts b/src/vs/editor/common/viewModel/splitLinesCollection.ts index 72caeb160e8..7c40b262f09 100644 --- a/src/vs/editor/common/viewModel/splitLinesCollection.ts +++ b/src/vs/editor/common/viewModel/splitLinesCollection.ts @@ -12,7 +12,7 @@ import { PrefixSumComputerWithCache } from 'vs/editor/common/viewModel/prefixSum import { ViewLineData } from 'vs/editor/common/viewModel/viewModel'; import * as viewEvents from 'vs/editor/common/view/viewEvents'; import { WrappingIndent } from 'vs/editor/common/config/editorOptions'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export class OutputPosition { _outputPositionBrand: void; diff --git a/src/vs/editor/common/viewModel/viewModel.ts b/src/vs/editor/common/viewModel/viewModel.ts index ffb43fadd6a..6372d3a1415 100644 --- a/src/vs/editor/common/viewModel/viewModel.ts +++ b/src/vs/editor/common/viewModel/viewModel.ts @@ -11,9 +11,9 @@ import { Range } from 'vs/editor/common/core/range'; import { Selection } from 'vs/editor/common/core/selection'; import { ViewEvent, IViewEventListener } from 'vs/editor/common/view/viewEvents'; import { IDisposable } from 'vs/base/common/lifecycle'; -import { Scrollable } from "vs/base/common/scrollable"; -import { IPartialViewLinesViewportData } from "vs/editor/common/viewLayout/viewLinesViewportData"; -import { IEditorWhitespace } from "vs/editor/common/viewLayout/whitespaceComputer"; +import { Scrollable } from 'vs/base/common/scrollable'; +import { IPartialViewLinesViewportData } from 'vs/editor/common/viewLayout/viewLinesViewportData'; +import { IEditorWhitespace } from 'vs/editor/common/viewLayout/whitespaceComputer'; export interface IViewWhitespaceViewportData { readonly id: number; diff --git a/src/vs/editor/common/viewModel/viewModelImpl.ts b/src/vs/editor/common/viewModel/viewModelImpl.ts index be7b24bb828..a7a7297e881 100644 --- a/src/vs/editor/common/viewModel/viewModelImpl.ts +++ b/src/vs/editor/common/viewModel/viewModelImpl.ts @@ -19,7 +19,7 @@ import * as viewEvents from 'vs/editor/common/view/viewEvents'; import { MinimapTokensColorTracker } from 'vs/editor/common/view/minimapCharRenderer'; import * as textModelEvents from 'vs/editor/common/model/textModelEvents'; import { IConfigurationChangedEvent } from 'vs/editor/common/config/editorOptions'; -import { CharacterHardWrappingLineMapperFactory } from "vs/editor/common/viewModel/characterHardWrappingLineMapper"; +import { CharacterHardWrappingLineMapperFactory } from 'vs/editor/common/viewModel/characterHardWrappingLineMapper'; import { ViewLayout } from 'vs/editor/common/viewLayout/viewLayout'; export class CoordinatesConverter implements ICoordinatesConverter { diff --git a/src/vs/editor/contrib/bracketMatching/common/bracketMatching.ts b/src/vs/editor/contrib/bracketMatching/common/bracketMatching.ts index a3443fa79fd..7b79df152e7 100644 --- a/src/vs/editor/contrib/bracketMatching/common/bracketMatching.ts +++ b/src/vs/editor/contrib/bracketMatching/common/bracketMatching.ts @@ -14,9 +14,9 @@ import { RunOnceScheduler } from 'vs/base/common/async'; import * as editorCommon from 'vs/editor/common/editorCommon'; import { editorAction, commonEditorContribution, ServicesAccessor, EditorAction } from 'vs/editor/common/editorCommonExtensions'; import { EditorContextKeys } from 'vs/editor/common/editorContextKeys'; -import { registerThemingParticipant } from "vs/platform/theme/common/themeService"; -import { editorBracketMatchBackground, editorBracketMatchBorder } from "vs/editor/common/view/editorColorRegistry"; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; +import { editorBracketMatchBackground, editorBracketMatchBorder } from 'vs/editor/common/view/editorColorRegistry'; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; @editorAction class SelectBracketAction extends EditorAction { diff --git a/src/vs/editor/contrib/codelens/browser/codelens.ts b/src/vs/editor/contrib/codelens/browser/codelens.ts index 84fcda05eb1..2c7e6ff341c 100644 --- a/src/vs/editor/contrib/codelens/browser/codelens.ts +++ b/src/vs/editor/contrib/codelens/browser/codelens.ts @@ -22,10 +22,10 @@ import * as editorBrowser from 'vs/editor/browser/editorBrowser'; import { editorContribution } from 'vs/editor/browser/editorBrowserExtensions'; import { ICodeLensData, getCodeLensData } from '../common/codelens'; import { IConfigurationChangedEvent } from 'vs/editor/common/config/editorOptions'; -import { editorCodeLensForeground } from "vs/editor/common/view/editorColorRegistry"; -import { registerThemingParticipant } from "vs/platform/theme/common/themeService"; -import { editorActiveLinkForeground } from "vs/platform/theme/common/colorRegistry"; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { editorCodeLensForeground } from 'vs/editor/common/view/editorColorRegistry'; +import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; +import { editorActiveLinkForeground } from 'vs/platform/theme/common/colorRegistry'; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; class CodeLensViewZone implements editorBrowser.IViewZone { diff --git a/src/vs/editor/contrib/comment/test/common/lineCommentCommand.test.ts b/src/vs/editor/contrib/comment/test/common/lineCommentCommand.test.ts index 1326d8bda33..64d900f1dd7 100644 --- a/src/vs/editor/contrib/comment/test/common/lineCommentCommand.test.ts +++ b/src/vs/editor/contrib/comment/test/common/lineCommentCommand.test.ts @@ -12,9 +12,9 @@ import { CommentMode } from 'vs/editor/test/common/commentMode'; import * as modes from 'vs/editor/common/modes'; import { NULL_STATE } from 'vs/editor/common/modes/nullMode'; import { TokenizationResult2 } from 'vs/editor/common/core/token'; -import { MockMode } from "vs/editor/test/common/mocks/mockMode"; -import { CommentRule } from "vs/editor/common/modes/languageConfiguration"; -import { LanguageConfigurationRegistry } from "vs/editor/common/modes/languageConfigurationRegistry"; +import { MockMode } from 'vs/editor/test/common/mocks/mockMode'; +import { CommentRule } from 'vs/editor/common/modes/languageConfiguration'; +import { LanguageConfigurationRegistry } from 'vs/editor/common/modes/languageConfigurationRegistry'; suite('Editor Contrib - Line Comment Command', () => { diff --git a/src/vs/editor/contrib/dnd/browser/dnd.ts b/src/vs/editor/contrib/dnd/browser/dnd.ts index e305c8af11a..7628350f4e2 100644 --- a/src/vs/editor/contrib/dnd/browser/dnd.ts +++ b/src/vs/editor/contrib/dnd/browser/dnd.ts @@ -17,7 +17,7 @@ import { Position } from 'vs/editor/common/core/position'; import { Range } from 'vs/editor/common/core/range'; import { Selection } from 'vs/editor/common/core/selection'; import { DragAndDropCommand } from '../common/dragAndDropCommand'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; @editorContribution export class DragAndDropController implements editorCommon.IEditorContribution { diff --git a/src/vs/editor/contrib/find/common/findController.ts b/src/vs/editor/contrib/find/common/findController.ts index e0657d80c73..4536b2b5b6f 100644 --- a/src/vs/editor/contrib/find/common/findController.ts +++ b/src/vs/editor/contrib/find/common/findController.ts @@ -21,7 +21,7 @@ import { RunOnceScheduler, Delayer } from 'vs/base/common/async'; import { CursorChangeReason, ICursorSelectionChangedEvent } from 'vs/editor/common/controller/cursorEvents'; import { EditorContextKeys } from 'vs/editor/common/editorContextKeys'; import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export const enum FindStartFocusAction { NoFocusChange, diff --git a/src/vs/editor/contrib/find/common/findDecorations.ts b/src/vs/editor/contrib/find/common/findDecorations.ts index 2a80081cf0a..4cf3d631284 100644 --- a/src/vs/editor/contrib/find/common/findDecorations.ts +++ b/src/vs/editor/contrib/find/common/findDecorations.ts @@ -8,7 +8,7 @@ import { IDisposable } from 'vs/base/common/lifecycle'; import * as editorCommon from 'vs/editor/common/editorCommon'; import { Position } from 'vs/editor/common/core/position'; import { Range } from 'vs/editor/common/core/range'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export class FindDecorations implements IDisposable { diff --git a/src/vs/editor/contrib/folding/common/foldingModel.ts b/src/vs/editor/contrib/folding/common/foldingModel.ts index 128f450b087..8ebd2424cc7 100644 --- a/src/vs/editor/contrib/folding/common/foldingModel.ts +++ b/src/vs/editor/contrib/folding/common/foldingModel.ts @@ -5,7 +5,7 @@ import * as editorCommon from 'vs/editor/common/editorCommon'; import { Range } from 'vs/editor/common/core/range'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export interface IFoldingRange { startLineNumber: number; diff --git a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts index a29f1511b44..124e4229c3d 100644 --- a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts +++ b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts @@ -24,7 +24,7 @@ import { registerThemingParticipant } from 'vs/platform/theme/common/themeServic import { editorActiveLinkForeground } from 'vs/platform/theme/common/colorRegistry'; import { EditorState, CodeEditorStateFlag } from 'vs/editor/common/core/editorState'; import { DefinitionAction, DefinitionActionConfig } from './goToDeclarationCommands'; -import { ClickLinkGesture, ClickLinkMouseEvent, ClickLinkKeyboardEvent } from "vs/editor/contrib/goToDeclaration/browser/clickLinkGesture"; +import { ClickLinkGesture, ClickLinkMouseEvent, ClickLinkKeyboardEvent } from 'vs/editor/contrib/goToDeclaration/browser/clickLinkGesture'; @editorContribution class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorContribution { diff --git a/src/vs/editor/contrib/hover/browser/modesContentHover.ts b/src/vs/editor/contrib/hover/browser/modesContentHover.ts index 636180c1a66..0814b278789 100644 --- a/src/vs/editor/contrib/hover/browser/modesContentHover.ts +++ b/src/vs/editor/contrib/hover/browser/modesContentHover.ts @@ -22,7 +22,7 @@ import { getHover } from '../common/hover'; import { HoverOperation, IHoverComputer } from './hoverOperation'; import { ContentHoverWidget } from './hoverWidgets'; import { textToMarkedString, MarkedString } from 'vs/base/common/htmlContent'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; class ModesContentComputer implements IHoverComputer { diff --git a/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.ts b/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.ts index 874af70feda..030eff62c25 100644 --- a/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.ts +++ b/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.ts @@ -18,7 +18,7 @@ import { InPlaceReplaceCommand } from './inPlaceReplaceCommand'; import { EditorState, CodeEditorStateFlag } from 'vs/editor/common/core/editorState'; import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; import { editorBracketMatchBorder } from 'vs/editor/common/view/editorColorRegistry'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; @commonEditorContribution class InPlaceReplaceController implements IEditorContribution { diff --git a/src/vs/editor/contrib/linesOperations/common/linesOperations.ts b/src/vs/editor/contrib/linesOperations/common/linesOperations.ts index 4bc4b88d0fa..a41829a885b 100644 --- a/src/vs/editor/contrib/linesOperations/common/linesOperations.ts +++ b/src/vs/editor/contrib/linesOperations/common/linesOperations.ts @@ -19,7 +19,7 @@ import { CopyLinesCommand } from './copyLinesCommand'; import { DeleteLinesCommand } from './deleteLinesCommand'; import { MoveLinesCommand } from './moveLinesCommand'; import { TypeOperations } from 'vs/editor/common/controller/cursorTypeOperations'; -import { CoreEditingCommands } from "vs/editor/common/controller/coreCommands"; +import { CoreEditingCommands } from 'vs/editor/common/controller/coreCommands'; // copy lines diff --git a/src/vs/editor/contrib/linesOperations/test/common/linesOperations.test.ts b/src/vs/editor/contrib/linesOperations/test/common/linesOperations.test.ts index 4a56e203f65..64c67e2cb9a 100644 --- a/src/vs/editor/contrib/linesOperations/test/common/linesOperations.test.ts +++ b/src/vs/editor/contrib/linesOperations/test/common/linesOperations.test.ts @@ -10,9 +10,9 @@ import { Position } from 'vs/editor/common/core/position'; import { Handler, IModel, DefaultEndOfLine } from 'vs/editor/common/editorCommon'; import { withMockCodeEditor } from 'vs/editor/test/common/mocks/mockCodeEditor'; import { DeleteAllLeftAction, JoinLinesAction, TransposeAction, UpperCaseAction, LowerCaseAction, DeleteAllRightAction, InsertLineBeforeAction, InsertLineAfterAction, IndentLinesAction } from 'vs/editor/contrib/linesOperations/common/linesOperations'; -import { Cursor } from "vs/editor/common/controller/cursor"; -import { Model } from "vs/editor/common/model/model"; -import { CoreEditingCommands } from "vs/editor/common/controller/coreCommands"; +import { Cursor } from 'vs/editor/common/controller/cursor'; +import { Model } from 'vs/editor/common/model/model'; +import { CoreEditingCommands } from 'vs/editor/common/controller/coreCommands'; suite('Editor Contrib - Line Operations', () => { suite('DeleteAllLeftAction', () => { diff --git a/src/vs/editor/contrib/links/browser/links.ts b/src/vs/editor/contrib/links/browser/links.ts index 356f9bf6843..d25c7a9a3ad 100644 --- a/src/vs/editor/contrib/links/browser/links.ts +++ b/src/vs/editor/contrib/links/browser/links.ts @@ -24,8 +24,8 @@ import { editorContribution } from 'vs/editor/browser/editorBrowserExtensions'; import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; import { editorActiveLinkForeground } from 'vs/platform/theme/common/colorRegistry'; import { Position } from 'vs/editor/common/core/position'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; -import { ClickLinkGesture, ClickLinkMouseEvent, ClickLinkKeyboardEvent } from "vs/editor/contrib/goToDeclaration/browser/clickLinkGesture"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; +import { ClickLinkGesture, ClickLinkMouseEvent, ClickLinkKeyboardEvent } from 'vs/editor/contrib/goToDeclaration/browser/clickLinkGesture'; const HOVER_MESSAGE_GENERAL_META = ( platform.isMacintosh diff --git a/src/vs/editor/contrib/quickOpen/browser/editorQuickOpen.ts b/src/vs/editor/contrib/quickOpen/browser/editorQuickOpen.ts index 3b088852ed4..6117ad98768 100644 --- a/src/vs/editor/contrib/quickOpen/browser/editorQuickOpen.ts +++ b/src/vs/editor/contrib/quickOpen/browser/editorQuickOpen.ts @@ -14,7 +14,7 @@ import { Selection } from 'vs/editor/common/core/selection'; import { IActionOptions, EditorAction } from 'vs/editor/common/editorCommonExtensions'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { Range } from 'vs/editor/common/core/range'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export interface IQuickOpenControllerOpts { inputAriaLabel: string; diff --git a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts index a7175ad5a1f..959c2bc8939 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts +++ b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts @@ -43,8 +43,8 @@ import { registerThemingParticipant, ITheme, IThemeService } from 'vs/platform/t import { attachListStyler, attachBadgeStyler } from 'vs/platform/theme/common/styler'; import { IModelDecorationsChangedEvent } from 'vs/editor/common/model/textModelEvents'; import { IEditorOptions } from 'vs/editor/common/config/editorOptions'; -import { IEnvironmentService } from "vs/platform/environment/common/environment"; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { IEnvironmentService } from 'vs/platform/environment/common/environment'; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; class DecorationsManager implements IDisposable { diff --git a/src/vs/editor/contrib/snippet/browser/snippetSession.ts b/src/vs/editor/contrib/snippet/browser/snippetSession.ts index b5938e3c7e4..2a38815488c 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetSession.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetSession.ts @@ -16,7 +16,7 @@ import { IPosition } from 'vs/editor/common/core/position'; import { groupBy } from 'vs/base/common/arrays'; import { dispose } from 'vs/base/common/lifecycle'; import { EditorSnippetVariableResolver } from "./snippetVariables"; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export class OneSnippet { diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetController2.old.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetController2.old.test.ts index 9e15e0bed55..1efa1b1a8c1 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetController2.old.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetController2.old.test.ts @@ -10,8 +10,8 @@ import { Selection } from 'vs/editor/common/core/selection'; import { SnippetController2 } from 'vs/editor/contrib/snippet/browser/snippetController2'; import { MockCodeEditor, withMockCodeEditor } from 'vs/editor/test/common/mocks/mockCodeEditor'; import { Cursor } from 'vs/editor/common/controller/cursor'; -import { IContextKeyService } from "vs/platform/contextkey/common/contextkey"; -import { ICommonCodeEditor } from "vs/editor/common/editorCommon"; +import { IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; +import { ICommonCodeEditor } from 'vs/editor/common/editorCommon'; class TestSnippetController extends SnippetController2 { diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts index 04a866727d3..6c30a179315 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts @@ -9,7 +9,7 @@ import { Selection } from 'vs/editor/common/core/selection'; import { SnippetController2 } from 'vs/editor/contrib/snippet/browser/snippetController2'; import { ICommonCodeEditor } from 'vs/editor/common/editorCommon'; import { mockCodeEditor } from 'vs/editor/test/common/mocks/mockCodeEditor'; -import { Model } from "vs/editor/common/model/model"; +import { Model } from 'vs/editor/common/model/model'; import { MockContextKeyService } from 'vs/platform/keybinding/test/common/mockKeybindingService'; suite('SnippetController2', function () { diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts index 5eb6c7cba93..100b9c0dbd8 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts @@ -11,7 +11,7 @@ import { IPosition, Position } from 'vs/editor/common/core/position'; import { SnippetSession } from 'vs/editor/contrib/snippet/browser/snippetSession'; import { ICommonCodeEditor } from 'vs/editor/common/editorCommon'; import { mockCodeEditor } from 'vs/editor/test/common/mocks/mockCodeEditor'; -import { Model } from "vs/editor/common/model/model"; +import { Model } from 'vs/editor/common/model/model'; suite('SnippetSession', function () { diff --git a/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.ts b/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.ts index b3fcd42202a..896e593b005 100644 --- a/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.ts +++ b/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.ts @@ -18,7 +18,7 @@ import { Position } from 'vs/editor/common/core/position'; import { registerColor, editorSelectionHighlight, activeContrastBorder } from 'vs/platform/theme/common/colorRegistry'; import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; import { CursorChangeReason, ICursorPositionChangedEvent } from 'vs/editor/common/controller/cursorEvents'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export const editorWordHighlight = registerColor('editor.wordHighlightBackground', { dark: '#575757B8', light: '#57575740', hc: null }, nls.localize('wordHighlight', 'Background color of a symbol during read-access, like reading a variable.')); export const editorWordHighlightStrong = registerColor('editor.wordHighlightStrongBackground', { dark: '#004972B8', light: '#0e639c40', hc: null }, nls.localize('wordHighlightStrong', 'Background color of a symbol during write-access, like writing to a variable.')); diff --git a/src/vs/editor/contrib/wordOperations/common/wordOperations.ts b/src/vs/editor/contrib/wordOperations/common/wordOperations.ts index 469e9446eb2..a2da8517ce5 100644 --- a/src/vs/editor/contrib/wordOperations/common/wordOperations.ts +++ b/src/vs/editor/contrib/wordOperations/common/wordOperations.ts @@ -14,9 +14,9 @@ import { Position } from 'vs/editor/common/core/position'; import { Range } from 'vs/editor/common/core/range'; import { WordNavigationType, WordOperations } from 'vs/editor/common/controller/cursorWordOperations'; import { ReplaceCommand } from 'vs/editor/common/commands/replaceCommand'; -import { getMapForWordSeparators, WordCharacterClassifier } from "vs/editor/common/controller/wordCharacterClassifier"; -import { CursorState } from "vs/editor/common/controller/cursorCommon"; -import { CursorChangeReason } from "vs/editor/common/controller/cursorEvents"; +import { getMapForWordSeparators, WordCharacterClassifier } from 'vs/editor/common/controller/wordCharacterClassifier'; +import { CursorState } from 'vs/editor/common/controller/cursorCommon'; +import { CursorChangeReason } from 'vs/editor/common/controller/cursorEvents'; export interface MoveWordOptions extends ICommandOptions { inSelectionMode: boolean; diff --git a/src/vs/editor/contrib/wordOperations/test/common/wordOperations.test.ts b/src/vs/editor/contrib/wordOperations/test/common/wordOperations.test.ts index d67a436a400..40c303f0bec 100644 --- a/src/vs/editor/contrib/wordOperations/test/common/wordOperations.test.ts +++ b/src/vs/editor/contrib/wordOperations/test/common/wordOperations.test.ts @@ -17,7 +17,7 @@ import { DeleteWordLeft, DeleteWordStartLeft, DeleteWordEndLeft, DeleteWordRight, DeleteWordStartRight, DeleteWordEndRight } from 'vs/editor/contrib/wordOperations/common/wordOperations'; -import { EditorCommand } from "vs/editor/common/editorCommonExtensions"; +import { EditorCommand } from 'vs/editor/common/editorCommonExtensions'; suite('WordOperations', () => { diff --git a/src/vs/editor/contrib/zoneWidget/browser/zoneWidget.ts b/src/vs/editor/contrib/zoneWidget/browser/zoneWidget.ts index e0de87646d8..dc599a468bf 100644 --- a/src/vs/editor/contrib/zoneWidget/browser/zoneWidget.ts +++ b/src/vs/editor/contrib/zoneWidget/browser/zoneWidget.ts @@ -16,7 +16,7 @@ import { ICodeEditor, IOverlayWidget, IOverlayWidgetPosition, IViewZone, IViewZo import { Color, RGBA } from 'vs/base/common/color'; import { EditorLayoutInfo } from 'vs/editor/common/config/editorOptions'; import { Position, IPosition } from 'vs/editor/common/core/position'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export interface IOptions { showFrame?: boolean; diff --git a/src/vs/editor/editor.main.ts b/src/vs/editor/editor.main.ts index 8e3a8c151dd..667a3004499 100644 --- a/src/vs/editor/editor.main.ts +++ b/src/vs/editor/editor.main.ts @@ -14,7 +14,7 @@ import 'vs/editor/contrib/inspectTokens/browser/inspectTokens'; import { createMonacoBaseAPI } from 'vs/editor/common/standalone/standaloneBase'; import { createMonacoEditorAPI } from 'vs/editor/browser/standalone/standaloneEditor'; import { createMonacoLanguagesAPI } from 'vs/editor/browser/standalone/standaloneLanguages'; -import { EDITOR_DEFAULTS, WrappingIndent } from "vs/editor/common/config/editorOptions"; +import { EDITOR_DEFAULTS, WrappingIndent } from 'vs/editor/common/config/editorOptions'; // Set defaults for standalone editor (EDITOR_DEFAULTS).wrappingIndent = WrappingIndent.None; diff --git a/src/vs/editor/test/browser/controller/textAreaState.test.ts b/src/vs/editor/test/browser/controller/textAreaState.test.ts index 9170690d5ec..59552e7542e 100644 --- a/src/vs/editor/test/browser/controller/textAreaState.test.ts +++ b/src/vs/editor/test/browser/controller/textAreaState.test.ts @@ -9,7 +9,7 @@ import { ISimpleModel, TextAreaState, ITextAreaWrapper, PagedScreenReaderStrateg import { Range } from 'vs/editor/common/core/range'; import { EndOfLinePreference } from 'vs/editor/common/editorCommon'; import { Disposable } from 'vs/base/common/lifecycle'; -import { Model } from "vs/editor/common/model/model"; +import { Model } from 'vs/editor/common/model/model'; import { Selection } from 'vs/editor/common/core/selection'; export class MockTextAreaWrapper extends Disposable implements ITextAreaWrapper { diff --git a/src/vs/editor/test/common/commands/commandTestUtils.ts b/src/vs/editor/test/common/commands/commandTestUtils.ts index b753b8a063a..184f5e8d99b 100644 --- a/src/vs/editor/test/common/commands/commandTestUtils.ts +++ b/src/vs/editor/test/common/commands/commandTestUtils.ts @@ -10,7 +10,7 @@ import { Selection } from 'vs/editor/common/core/selection'; import * as editorCommon from 'vs/editor/common/editorCommon'; import { Model } from 'vs/editor/common/model/model'; import { LanguageIdentifier } from 'vs/editor/common/modes'; -import { withMockCodeEditor } from "vs/editor/test/common/mocks/mockCodeEditor"; +import { withMockCodeEditor } from 'vs/editor/test/common/mocks/mockCodeEditor'; export function testCommand( lines: string[], diff --git a/src/vs/editor/test/common/commands/sideEditing.test.ts b/src/vs/editor/test/common/commands/sideEditing.test.ts index 2fa3ea6035f..af17bee84a2 100644 --- a/src/vs/editor/test/common/commands/sideEditing.test.ts +++ b/src/vs/editor/test/common/commands/sideEditing.test.ts @@ -11,7 +11,7 @@ import { Range } from 'vs/editor/common/core/range'; import { Selection } from 'vs/editor/common/core/selection'; import { IIdentifiedSingleEditOperation } from 'vs/editor/common/editorCommon'; import { ILineEdit, ModelLine, LineMarker, MarkersTracker } from 'vs/editor/common/model/modelLine'; -import { withMockCodeEditor } from "vs/editor/test/common/mocks/mockCodeEditor"; +import { withMockCodeEditor } from 'vs/editor/test/common/mocks/mockCodeEditor'; const NO_TAB_SIZE = 0; diff --git a/src/vs/editor/test/common/config/commonEditorConfig.test.ts b/src/vs/editor/test/common/config/commonEditorConfig.test.ts index 6abc5412b03..c07e1240c1f 100644 --- a/src/vs/editor/test/common/config/commonEditorConfig.test.ts +++ b/src/vs/editor/test/common/config/commonEditorConfig.test.ts @@ -7,8 +7,8 @@ import * as assert from 'assert'; import { EditorZoom } from 'vs/editor/common/config/editorZoom'; import { TestConfiguration } from 'vs/editor/test/common/mocks/testConfiguration'; -import { IEnvConfiguration } from "vs/editor/common/config/commonEditorConfig"; -import { AccessibilitySupport } from "vs/base/common/platform"; +import { IEnvConfiguration } from 'vs/editor/common/config/commonEditorConfig'; +import { AccessibilitySupport } from 'vs/base/common/platform'; suite('Common Editor Config', () => { test('Zoom Level', () => { diff --git a/src/vs/editor/test/common/controller/cursor.test.ts b/src/vs/editor/test/common/controller/cursor.test.ts index 833bd813b47..b3d15acc035 100644 --- a/src/vs/editor/test/common/controller/cursor.test.ts +++ b/src/vs/editor/test/common/controller/cursor.test.ts @@ -23,15 +23,15 @@ import { MockMode } from 'vs/editor/test/common/mocks/mockMode'; import { LanguageIdentifier } from 'vs/editor/common/modes'; import { IEditorOptions } from 'vs/editor/common/config/editorOptions'; import { CoreNavigationCommands, CoreEditingCommands } from 'vs/editor/common/controller/coreCommands'; -import { withMockCodeEditor, MockCodeEditor } from "vs/editor/test/common/mocks/mockCodeEditor"; -import { TextModel } from "vs/editor/common/model/textModel"; -import { ViewModel } from "vs/editor/common/viewModel/viewModelImpl"; +import { withMockCodeEditor, MockCodeEditor } from 'vs/editor/test/common/mocks/mockCodeEditor'; +import { TextModel } from 'vs/editor/common/model/textModel'; +import { ViewModel } from 'vs/editor/common/viewModel/viewModelImpl'; import * as viewEvents from 'vs/editor/common/view/viewEvents'; -import { ScreenReaderMessageGenerator } from "vs/editor/common/controller/accGenerator"; +import { ScreenReaderMessageGenerator } from 'vs/editor/common/controller/accGenerator'; import { CursorWordLeft, CursorWordLeftSelect, CursorWordRight, CursorWordRightSelect } from 'vs/editor/contrib/wordOperations/common/wordOperations'; -import { EditorCommand } from "vs/editor/common/editorCommonExtensions"; +import { EditorCommand } from 'vs/editor/common/editorCommonExtensions'; let H = Handler; // --------- utils diff --git a/src/vs/editor/test/common/controller/cursorMoveCommand.test.ts b/src/vs/editor/test/common/controller/cursorMoveCommand.test.ts index 1b4ae6b014d..2b9ac20069d 100644 --- a/src/vs/editor/test/common/controller/cursorMoveCommand.test.ts +++ b/src/vs/editor/test/common/controller/cursorMoveCommand.test.ts @@ -13,7 +13,7 @@ import { CursorMove } from 'vs/editor/common/controller/cursorMoveCommands'; import { Range } from 'vs/editor/common/core/range'; import { Selection } from 'vs/editor/common/core/selection'; import { CoreNavigationCommands } from 'vs/editor/common/controller/coreCommands'; -import { ViewModel } from "vs/editor/common/viewModel/viewModelImpl"; +import { ViewModel } from 'vs/editor/common/viewModel/viewModelImpl'; suite('Cursor move command test', () => { diff --git a/src/vs/editor/test/common/mocks/testConfiguration.ts b/src/vs/editor/test/common/mocks/testConfiguration.ts index edddfa74fdd..a8778a6f055 100644 --- a/src/vs/editor/test/common/mocks/testConfiguration.ts +++ b/src/vs/editor/test/common/mocks/testConfiguration.ts @@ -7,7 +7,7 @@ import { CommonEditorConfiguration, IEnvConfiguration } from 'vs/editor/common/config/commonEditorConfig'; import { IEditorOptions } from 'vs/editor/common/config/editorOptions'; import { FontInfo, BareFontInfo } from 'vs/editor/common/config/fontInfo'; -import { AccessibilitySupport } from "vs/base/common/platform"; +import { AccessibilitySupport } from 'vs/base/common/platform'; export class TestConfiguration extends CommonEditorConfiguration { diff --git a/src/vs/editor/test/common/model/textModelSearch.test.ts b/src/vs/editor/test/common/model/textModelSearch.test.ts index 4102cfad4fe..274ce45b934 100644 --- a/src/vs/editor/test/common/model/textModelSearch.test.ts +++ b/src/vs/editor/test/common/model/textModelSearch.test.ts @@ -10,8 +10,8 @@ import { FindMatch, EndOfLineSequence } from 'vs/editor/common/editorCommon'; import { Range } from 'vs/editor/common/core/range'; import { TextModel } from 'vs/editor/common/model/textModel'; import { TextModelSearch, SearchParams, SearchData } from 'vs/editor/common/model/textModelSearch'; -import { getMapForWordSeparators } from "vs/editor/common/controller/wordCharacterClassifier"; -import { USUAL_WORD_SEPARATORS } from "vs/editor/common/model/wordHelper"; +import { getMapForWordSeparators } from 'vs/editor/common/controller/wordCharacterClassifier'; +import { USUAL_WORD_SEPARATORS } from 'vs/editor/common/model/wordHelper'; // --------- Find suite('TextModelSearch', () => { diff --git a/src/vs/workbench/browser/parts/compositePart.ts b/src/vs/workbench/browser/parts/compositePart.ts index bb92039a1f0..5c23e84ef0f 100644 --- a/src/vs/workbench/browser/parts/compositePart.ts +++ b/src/vs/workbench/browser/parts/compositePart.ts @@ -36,7 +36,7 @@ import { IProgressService } from 'vs/platform/progress/common/progress'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { IThemeService } from 'vs/platform/theme/common/themeService'; -import { attachProgressBarStyler } from "vs/platform/theme/common/styler"; +import { attachProgressBarStyler } from 'vs/platform/theme/common/styler'; export interface ICompositeTitleLabel { diff --git a/src/vs/workbench/browser/parts/editor/editorGroupsControl.ts b/src/vs/workbench/browser/parts/editor/editorGroupsControl.ts index 05bf24ac197..4bc4a3b143a 100644 --- a/src/vs/workbench/browser/parts/editor/editorGroupsControl.ts +++ b/src/vs/workbench/browser/parts/editor/editorGroupsControl.ts @@ -36,7 +36,7 @@ import { getCodeEditor } from 'vs/editor/common/services/codeEditorService'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { editorBackground, contrastBorder, activeContrastBorder } from 'vs/platform/theme/common/colorRegistry'; import { Themable, EDITOR_GROUP_HEADER_TABS_BACKGROUND, EDITOR_GROUP_HEADER_NO_TABS_BACKGROUND, EDITOR_GROUP_BORDER, EDITOR_DRAG_AND_DROP_BACKGROUND, EDITOR_GROUP_BACKGROUND, EDITOR_GROUP_HEADER_TABS_BORDER } from 'vs/workbench/common/theme'; -import { attachProgressBarStyler } from "vs/platform/theme/common/styler"; +import { attachProgressBarStyler } from 'vs/platform/theme/common/styler'; export enum Rochade { NONE, diff --git a/src/vs/workbench/browser/parts/editor/webviewEditor.ts b/src/vs/workbench/browser/parts/editor/webviewEditor.ts index cf852a3d1a5..50f792c3e9d 100644 --- a/src/vs/workbench/browser/parts/editor/webviewEditor.ts +++ b/src/vs/workbench/browser/parts/editor/webviewEditor.ts @@ -5,10 +5,10 @@ 'use strict'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IThemeService } from 'vs/platform/theme/common/themeService'; -import { BaseEditor } from "vs/workbench/browser/parts/editor/baseEditor"; -import URI from "vs/base/common/uri"; -import { IStorageService } from "vs/platform/storage/common/storage"; -import { Scope } from "vs/workbench/common/memento"; +import { BaseEditor } from 'vs/workbench/browser/parts/editor/baseEditor'; +import URI from 'vs/base/common/uri'; +import { IStorageService } from 'vs/platform/storage/common/storage'; +import { Scope } from 'vs/workbench/common/memento'; export interface HtmlPreviewEditorViewState { scrollYPercentage: number; diff --git a/src/vs/workbench/browser/parts/statusbar/statusbarPart.ts b/src/vs/workbench/browser/parts/statusbar/statusbarPart.ts index fd2fd574fb4..b7909865487 100644 --- a/src/vs/workbench/browser/parts/statusbar/statusbarPart.ts +++ b/src/vs/workbench/browser/parts/statusbar/statusbarPart.ts @@ -30,7 +30,7 @@ import { IThemeService, registerThemingParticipant, ITheme, ICssStyleCollector } import { STATUS_BAR_BACKGROUND, STATUS_BAR_FOREGROUND, STATUS_BAR_NO_FOLDER_BACKGROUND, STATUS_BAR_ITEM_HOVER_BACKGROUND, STATUS_BAR_ITEM_ACTIVE_BACKGROUND, STATUS_BAR_PROMINENT_ITEM_BACKGROUND, STATUS_BAR_PROMINENT_ITEM_HOVER_BACKGROUND, STATUS_BAR_BORDER, STATUS_BAR_NO_FOLDER_FOREGROUND } from 'vs/workbench/common/theme'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { contrastBorder } from 'vs/platform/theme/common/colorRegistry'; -import { isThemeColor } from "vs/editor/common/editorCommon"; +import { isThemeColor } from 'vs/editor/common/editorCommon'; import { Color } from 'vs/base/common/color'; export class StatusbarPart extends Part implements IStatusbarService { diff --git a/src/vs/workbench/common/editor/rangeDecorations.ts b/src/vs/workbench/common/editor/rangeDecorations.ts index 7c8678ab24c..70a95b14274 100644 --- a/src/vs/workbench/common/editor/rangeDecorations.ts +++ b/src/vs/workbench/common/editor/rangeDecorations.ts @@ -12,7 +12,7 @@ import { toResource } from 'vs/workbench/common/editor'; import { isEqual } from 'vs/platform/files/common/files'; import { IRange } from 'vs/editor/common/core/range'; import { CursorChangeReason, ICursorPositionChangedEvent } from 'vs/editor/common/controller/cursorEvents'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export interface IRangeHighlightDecoration { resource: URI; diff --git a/src/vs/workbench/electron-browser/workbench.ts b/src/vs/workbench/electron-browser/workbench.ts index 86c445e811c..5a2a8efaff7 100644 --- a/src/vs/workbench/electron-browser/workbench.ts +++ b/src/vs/workbench/electron-browser/workbench.ts @@ -7,6 +7,7 @@ import 'vs/css!./media/workbench'; +import { localize } from 'vs/nls'; import { TPromise, ValueCallback } from 'vs/base/common/winjs.base'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import Event, { Emitter, chain } from 'vs/base/common/event'; @@ -91,11 +92,10 @@ import { IContextMenuService } from 'vs/platform/contextview/browser/contextView import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IWindowConfiguration } from 'vs/workbench/electron-browser/common'; -import { localize } from "vs/nls"; -import { IWorkbenchActionRegistry, Extensions } from "vs/workbench/common/actionRegistry"; +import { IWorkbenchActionRegistry, Extensions } from 'vs/workbench/common/actionRegistry'; import { OpenRecentAction, ToggleDevToolsAction, ReloadWindowAction } from "vs/workbench/electron-browser/actions"; -import { KeyMod } from "vs/base/common/keyCodes"; -import { KeyCode } from "vs/editor/common/standalone/standaloneBase"; +import { KeyMod } from 'vs/base/common/keyCodes'; +import { KeyCode } from 'vs/editor/common/standalone/standaloneBase'; export const MessagesVisibleContext = new RawContextKey('globalMessageVisible', false); export const EditorsVisibleContext = new RawContextKey('editorIsOpen', false); diff --git a/src/vs/workbench/node/extensionPoints.ts b/src/vs/workbench/node/extensionPoints.ts index bcb6fc2206d..c1b76d345ec 100644 --- a/src/vs/workbench/node/extensionPoints.ts +++ b/src/vs/workbench/node/extensionPoints.ts @@ -18,7 +18,7 @@ import Types = require('vs/base/common/types'); import { isValidExtensionDescription } from 'vs/platform/extensions/node/extensionValidator'; import * as semver from 'semver'; import { getIdAndVersionFromLocalExtensionId } from 'vs/platform/extensionManagement/common/extensionManagementUtil'; -import { getParseErrorMessage } from "vs/base/common/jsonErrorMessages"; +import { getParseErrorMessage } from 'vs/base/common/jsonErrorMessages'; const MANIFEST_FILE = 'package.json'; diff --git a/src/vs/workbench/parts/debug/browser/debugActionItems.ts b/src/vs/workbench/parts/debug/browser/debugActionItems.ts index edb07e3d969..50d19edfefb 100644 --- a/src/vs/workbench/parts/debug/browser/debugActionItems.ts +++ b/src/vs/workbench/parts/debug/browser/debugActionItems.ts @@ -19,7 +19,7 @@ import { IDebugService } from 'vs/workbench/parts/debug/common/debug'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { attachSelectBoxStyler, attachStylerCallback } from 'vs/platform/theme/common/styler'; import { SIDE_BAR_BACKGROUND } from 'vs/workbench/common/theme'; -import { selectBorder } from "vs/platform/theme/common/colorRegistry"; +import { selectBorder } from 'vs/platform/theme/common/colorRegistry'; const $ = dom.$; diff --git a/src/vs/workbench/parts/debug/browser/exceptionWidget.ts b/src/vs/workbench/parts/debug/browser/exceptionWidget.ts index a54e0e1ff20..70004ffb526 100644 --- a/src/vs/workbench/parts/debug/browser/exceptionWidget.ts +++ b/src/vs/workbench/parts/debug/browser/exceptionWidget.ts @@ -11,9 +11,9 @@ import { ICodeEditor } from 'vs/editor/browser/editorBrowser'; import { IContextViewService } from 'vs/platform/contextview/browser/contextView'; import { IDebugService, IExceptionInfo } from 'vs/workbench/parts/debug/common/debug'; import { RunOnceScheduler } from 'vs/base/common/async'; -import { IThemeService, ITheme } from "vs/platform/theme/common/themeService"; -import { Color } from "vs/base/common/color"; -import { registerColor } from "vs/platform/theme/common/colorRegistry"; +import { IThemeService, ITheme } from 'vs/platform/theme/common/themeService'; +import { Color } from 'vs/base/common/color'; +import { registerColor } from 'vs/platform/theme/common/colorRegistry'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { LinkDetector } from 'vs/workbench/parts/debug/browser/linkDetector'; const $ = dom.$; diff --git a/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.ts b/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.ts index f0e0ed7a9bd..95e12911dcf 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.ts @@ -37,7 +37,7 @@ import { FloatingClickWidget } from 'vs/workbench/parts/preferences/browser/pref import { IListService } from 'vs/platform/list/browser/listService'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { Position } from 'vs/editor/common/core/position'; -import { CoreEditingCommands } from "vs/editor/common/controller/coreCommands"; +import { CoreEditingCommands } from 'vs/editor/common/controller/coreCommands'; const HOVER_DELAY = 300; const LAUNCH_JSON_REGEX = /launch\.json$/; diff --git a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts index 4e5b9be2e79..ce54f235ae5 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts @@ -23,7 +23,7 @@ import { VariablesRenderer, renderExpressionValue, VariablesDataSource } from 'v import { IListService } from 'vs/platform/list/browser/listService'; import { attachListStyler, attachStylerCallback } from 'vs/platform/theme/common/styler'; import { IThemeService } from 'vs/platform/theme/common/themeService'; -import { editorHoverBackground, editorHoverBorder } from "vs/platform/theme/common/colorRegistry"; +import { editorHoverBackground, editorHoverBorder } from 'vs/platform/theme/common/colorRegistry'; const $ = dom.$; const MAX_ELEMENTS_SHOWN = 18; diff --git a/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.ts b/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.ts index fe69b0ad530..78ba083f9a0 100644 --- a/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.ts +++ b/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.ts @@ -11,7 +11,7 @@ import { IPartService, Parts } from 'vs/workbench/services/part/common/partServi import { IDebugService, State } from 'vs/workbench/parts/debug/common/debug'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { STATUS_BAR_NO_FOLDER_BACKGROUND, STATUS_BAR_NO_FOLDER_FOREGROUND, STATUS_BAR_BACKGROUND, Themable, STATUS_BAR_FOREGROUND } from 'vs/workbench/common/theme'; -import { addClass, removeClass } from "vs/base/browser/dom"; +import { addClass, removeClass } from 'vs/base/browser/dom'; // colors for theming diff --git a/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.ts b/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.ts index f1db99bf647..f046995c799 100644 --- a/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.ts +++ b/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.ts @@ -11,7 +11,7 @@ import { BasicEmmetEditorAction } from 'vs/workbench/parts/emmet/electron-browse import { editorAction } from 'vs/editor/common/editorCommonExtensions'; import { ICommonCodeEditor } from 'vs/editor/common/editorCommon'; import { EditorContextKeys } from 'vs/editor/common/editorContextKeys'; -import { CoreEditingCommands } from "vs/editor/common/controller/coreCommands"; +import { CoreEditingCommands } from 'vs/editor/common/controller/coreCommands'; import { KeyCode } from 'vs/base/common/keyCodes'; import { ContextKeyExpr } from 'vs/platform/contextkey/common/contextkey'; diff --git a/src/vs/workbench/parts/emmet/electron-browser/editorAccessor.ts b/src/vs/workbench/parts/emmet/electron-browser/editorAccessor.ts index 38cb77ea2fd..26f7cf390e7 100644 --- a/src/vs/workbench/parts/emmet/electron-browser/editorAccessor.ts +++ b/src/vs/workbench/parts/emmet/electron-browser/editorAccessor.ts @@ -11,7 +11,7 @@ import { Range } from 'vs/editor/common/core/range'; import { SnippetController2 } from 'vs/editor/contrib/snippet/browser/snippetController2'; import { LanguageId, LanguageIdentifier } from 'vs/editor/common/modes'; import { Position } from 'vs/editor/common/core/position'; -import { CoreEditingCommands } from "vs/editor/common/controller/coreCommands"; +import { CoreEditingCommands } from 'vs/editor/common/controller/coreCommands'; import { SnippetParser, walk, Placeholder, Variable, Text, Marker } from 'vs/editor/contrib/snippet/browser/snippetParser'; import emmet = require('emmet'); diff --git a/src/vs/workbench/parts/extensions/browser/extensionsActions.ts b/src/vs/workbench/parts/extensions/browser/extensionsActions.ts index f2cf8c9cacd..b922ba26c25 100644 --- a/src/vs/workbench/parts/extensions/browser/extensionsActions.ts +++ b/src/vs/workbench/parts/extensions/browser/extensionsActions.ts @@ -32,9 +32,9 @@ import { IExtensionService, IExtensionDescription } from 'vs/platform/extensions import URI from 'vs/base/common/uri'; import { CommandsRegistry } from 'vs/platform/commands/common/commands'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { registerThemingParticipant, ITheme, ICssStyleCollector } from "vs/platform/theme/common/themeService"; -import { buttonBackground, buttonForeground, buttonHoverBackground, contrastBorder, registerColor, foreground } from "vs/platform/theme/common/colorRegistry"; -import { Color } from "vs/base/common/color"; +import { registerThemingParticipant, ITheme, ICssStyleCollector } from 'vs/platform/theme/common/themeService'; +import { buttonBackground, buttonForeground, buttonHoverBackground, contrastBorder, registerColor, foreground } from 'vs/platform/theme/common/colorRegistry'; +import { Color } from 'vs/base/common/color'; export class InstallAction extends Action { diff --git a/src/vs/workbench/parts/feedback/electron-browser/feedback.ts b/src/vs/workbench/parts/feedback/electron-browser/feedback.ts index 310eb5f0d97..ec3746121ea 100644 --- a/src/vs/workbench/parts/feedback/electron-browser/feedback.ts +++ b/src/vs/workbench/parts/feedback/electron-browser/feedback.ts @@ -17,9 +17,9 @@ import * as dom from 'vs/base/browser/dom'; import { ICommandService } from 'vs/platform/commands/common/commands'; import * as errors from 'vs/base/common/errors'; import { IIntegrityService } from 'vs/platform/integrity/common/integrity'; -import { IThemeService, registerThemingParticipant, ITheme, ICssStyleCollector } from "vs/platform/theme/common/themeService"; -import { attachStylerCallback } from "vs/platform/theme/common/styler"; -import { editorWidgetBackground, widgetShadow, inputBorder, inputForeground, inputBackground, inputActiveOptionBorder, editorBackground, buttonBackground, contrastBorder } from "vs/platform/theme/common/colorRegistry"; +import { IThemeService, registerThemingParticipant, ITheme, ICssStyleCollector } from 'vs/platform/theme/common/themeService'; +import { attachStylerCallback } from 'vs/platform/theme/common/styler'; +import { editorWidgetBackground, widgetShadow, inputBorder, inputForeground, inputBackground, inputActiveOptionBorder, editorBackground, buttonBackground, contrastBorder } from 'vs/platform/theme/common/colorRegistry'; export interface IFeedback { feedback: string; diff --git a/src/vs/workbench/parts/feedback/electron-browser/feedbackStatusbarItem.ts b/src/vs/workbench/parts/feedback/electron-browser/feedbackStatusbarItem.ts index b4763f543e6..b124264626e 100644 --- a/src/vs/workbench/parts/feedback/electron-browser/feedbackStatusbarItem.ts +++ b/src/vs/workbench/parts/feedback/electron-browser/feedbackStatusbarItem.ts @@ -13,7 +13,7 @@ import { IInstantiationService } from 'vs/platform/instantiation/common/instanti import product from 'vs/platform/node/product'; import { Themable, STATUS_BAR_FOREGROUND, STATUS_BAR_NO_FOLDER_FOREGROUND } from 'vs/workbench/common/theme'; import { IThemeService } from 'vs/platform/theme/common/themeService'; -import { IWorkspaceContextService } from "vs/platform/workspace/common/workspace"; +import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; class TwitterFeedbackService implements IFeedbackService { diff --git a/src/vs/workbench/parts/files/browser/views/openEditorsView.ts b/src/vs/workbench/parts/files/browser/views/openEditorsView.ts index 4b3e4ee2778..3af3b297057 100644 --- a/src/vs/workbench/parts/files/browser/views/openEditorsView.ts +++ b/src/vs/workbench/parts/files/browser/views/openEditorsView.ts @@ -33,7 +33,7 @@ import { IListService } from 'vs/platform/list/browser/listService'; import { EditorGroup } from 'vs/workbench/common/editor/editorStacksModel'; import { attachListStyler, attachStylerCallback } from 'vs/platform/theme/common/styler'; import { IThemeService } from 'vs/platform/theme/common/themeService'; -import { badgeBackground, badgeForeground, contrastBorder } from "vs/platform/theme/common/colorRegistry"; +import { badgeBackground, badgeForeground, contrastBorder } from 'vs/platform/theme/common/colorRegistry'; const $ = dom.$; diff --git a/src/vs/workbench/parts/markers/browser/markersTreeViewer.ts b/src/vs/workbench/parts/markers/browser/markersTreeViewer.ts index b0f736e5e51..c78dfb63b68 100644 --- a/src/vs/workbench/parts/markers/browser/markersTreeViewer.ts +++ b/src/vs/workbench/parts/markers/browser/markersTreeViewer.ts @@ -18,9 +18,9 @@ import { IMarker } from 'vs/platform/markers/common/markers'; import { MarkersModel, Resource, Marker } from 'vs/workbench/parts/markers/common/markersModel'; import Messages from 'vs/workbench/parts/markers/common/messages'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; -import { attachBadgeStyler } from "vs/platform/theme/common/styler"; -import { IThemeService } from "vs/platform/theme/common/themeService"; -import { IDisposable } from "vs/base/common/lifecycle"; +import { attachBadgeStyler } from 'vs/platform/theme/common/styler'; +import { IThemeService } from 'vs/platform/theme/common/themeService'; +import { IDisposable } from 'vs/base/common/lifecycle'; interface IAnyResourceTemplateData { count: CountBadge; diff --git a/src/vs/workbench/parts/preferences/browser/keybindingWidgets.ts b/src/vs/workbench/parts/preferences/browser/keybindingWidgets.ts index 67c6fca57ae..65043dc7561 100644 --- a/src/vs/workbench/parts/preferences/browser/keybindingWidgets.ts +++ b/src/vs/workbench/parts/preferences/browser/keybindingWidgets.ts @@ -23,7 +23,7 @@ import { IInstantiationService } from 'vs/platform/instantiation/common/instanti import { ICodeEditor, IOverlayWidget, IOverlayWidgetPosition } from 'vs/editor/browser/editorBrowser'; import { attachInputBoxStyler, attachStylerCallback } from 'vs/platform/theme/common/styler'; import { IThemeService } from 'vs/platform/theme/common/themeService'; -import { editorWidgetBackground, widgetShadow } from "vs/platform/theme/common/colorRegistry"; +import { editorWidgetBackground, widgetShadow } from 'vs/platform/theme/common/colorRegistry'; class KeybindingInputWidget extends Widget { diff --git a/src/vs/workbench/parts/preferences/browser/keybindingsEditor.ts b/src/vs/workbench/parts/preferences/browser/keybindingsEditor.ts index ca94ecd2c2b..16fedab3623 100644 --- a/src/vs/workbench/parts/preferences/browser/keybindingsEditor.ts +++ b/src/vs/workbench/parts/preferences/browser/keybindingsEditor.ts @@ -39,7 +39,7 @@ import { IChoiceService, IMessageService, Severity } from 'vs/platform/message/c import { StandardKeyboardEvent } from 'vs/base/browser/keyboardEvent'; import { KeyCode, ResolvedKeybinding } from 'vs/base/common/keyCodes'; import { attachListStyler } from 'vs/platform/theme/common/styler'; -import { listHighlightForeground } from "vs/platform/theme/common/colorRegistry"; +import { listHighlightForeground } from 'vs/platform/theme/common/colorRegistry'; let $ = DOM.$; diff --git a/src/vs/workbench/parts/preferences/browser/preferencesEditor.ts b/src/vs/workbench/parts/preferences/browser/preferencesEditor.ts index 0aae0f5f0ff..ca535cf3de0 100644 --- a/src/vs/workbench/parts/preferences/browser/preferencesEditor.ts +++ b/src/vs/workbench/parts/preferences/browser/preferencesEditor.ts @@ -53,8 +53,8 @@ import { FindController } from 'vs/editor/contrib/find/browser/find'; import { SelectionHighlighter } from 'vs/editor/contrib/find/common/findController'; import { IEditorOptions } from 'vs/editor/common/config/editorOptions'; import { KeybindingsRegistry } from 'vs/platform/keybinding/common/keybindingsRegistry'; -import { attachStylerCallback } from "vs/platform/theme/common/styler"; -import { scrollbarShadow } from "vs/platform/theme/common/colorRegistry"; +import { attachStylerCallback } from 'vs/platform/theme/common/styler'; +import { scrollbarShadow } from 'vs/platform/theme/common/colorRegistry'; export class PreferencesEditorInput extends SideBySideEditorInput { public static ID: string = 'workbench.editorinputs.preferencesEditorInput'; diff --git a/src/vs/workbench/parts/preferences/browser/preferencesRenderers.ts b/src/vs/workbench/parts/preferences/browser/preferencesRenderers.ts index bd29a6a03df..81941633f5d 100644 --- a/src/vs/workbench/parts/preferences/browser/preferencesRenderers.ts +++ b/src/vs/workbench/parts/preferences/browser/preferencesRenderers.ts @@ -32,7 +32,7 @@ import { IWorkspaceConfigurationService } from 'vs/workbench/services/configurat import { IMessageService, Severity } from 'vs/platform/message/common/message'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; import { ICursorPositionChangedEvent } from 'vs/editor/common/controller/cursorEvents'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export interface IPreferencesRenderer extends IDisposable { preferencesModel: IPreferencesEditorModel; diff --git a/src/vs/workbench/parts/preferences/browser/preferencesWidgets.ts b/src/vs/workbench/parts/preferences/browser/preferencesWidgets.ts index 1f802861a31..52f1edebae3 100644 --- a/src/vs/workbench/parts/preferences/browser/preferencesWidgets.ts +++ b/src/vs/workbench/parts/preferences/browser/preferencesWidgets.ts @@ -27,7 +27,7 @@ import { attachInputBoxStyler, attachStylerCallback } from 'vs/platform/theme/co import { IThemeService } from 'vs/platform/theme/common/themeService'; import { Position } from 'vs/editor/common/core/position'; import { ICursorPositionChangedEvent } from 'vs/editor/common/controller/cursorEvents'; -import { buttonBackground, buttonForeground, badgeForeground, badgeBackground, contrastBorder, errorForeground } from "vs/platform/theme/common/colorRegistry"; +import { buttonBackground, buttonForeground, badgeForeground, badgeBackground, contrastBorder, errorForeground } from 'vs/platform/theme/common/colorRegistry'; export class SettingsGroupTitleWidget extends Widget implements IViewZone { diff --git a/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts b/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts index 5435cc3a698..260ab6e1a64 100644 --- a/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts +++ b/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts @@ -28,7 +28,7 @@ import { IMessageService, Severity, IMessageWithAction } from 'vs/platform/messa import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { IQuickOpenService } from 'vs/platform/quickOpen/common/quickOpen'; -import { editorAction, EditorAction } from "vs/editor/common/editorCommonExtensions"; +import { editorAction, EditorAction } from 'vs/editor/common/editorCommonExtensions'; export const ALL_COMMANDS_PREFIX = '>'; export const EDITOR_COMMANDS_PREFIX = '$'; diff --git a/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.ts b/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.ts index eaca7cc45e5..8561d451305 100644 --- a/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.ts +++ b/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.ts @@ -22,11 +22,11 @@ import { IEditorWorkerService } from 'vs/editor/common/services/editorWorkerServ import URI from 'vs/base/common/uri'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { ISCMService } from 'vs/workbench/services/scm/common/scm'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; -import { registerThemingParticipant, ITheme, ICssStyleCollector } from "vs/platform/theme/common/themeService"; -import { registerColor } from "vs/platform/theme/common/colorRegistry"; -import { localize } from "vs/nls"; -import { Color } from "vs/base/common/color"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; +import { registerThemingParticipant, ITheme, ICssStyleCollector } from 'vs/platform/theme/common/themeService'; +import { registerColor } from 'vs/platform/theme/common/colorRegistry'; +import { localize } from 'vs/nls'; +import { Color } from 'vs/base/common/color'; class DirtyDiffModelDecorator { diff --git a/src/vs/workbench/parts/search/browser/openFileHandler.ts b/src/vs/workbench/parts/search/browser/openFileHandler.ts index 28c61bbc3d4..1ff6554fa37 100644 --- a/src/vs/workbench/parts/search/browser/openFileHandler.ts +++ b/src/vs/workbench/parts/search/browser/openFileHandler.ts @@ -31,7 +31,7 @@ import { IQueryOptions, ISearchService, ISearchStats, ISearchQuery } from 'vs/pl import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { IRange } from 'vs/editor/common/core/range'; -import { getOutOfWorkspaceEditorResources } from "vs/workbench/parts/search/common/search"; +import { getOutOfWorkspaceEditorResources } from 'vs/workbench/parts/search/common/search'; export class FileQuickOpenModel extends QuickOpenModel { diff --git a/src/vs/workbench/parts/search/browser/searchResultsView.ts b/src/vs/workbench/parts/search/browser/searchResultsView.ts index 48452fee61f..c9d95f8e9ab 100644 --- a/src/vs/workbench/parts/search/browser/searchResultsView.ts +++ b/src/vs/workbench/parts/search/browser/searchResultsView.ts @@ -19,8 +19,8 @@ import { Range } from 'vs/editor/common/core/range'; import { SearchViewlet } from 'vs/workbench/parts/search/browser/searchViewlet'; import { RemoveAction, ReplaceAllAction, ReplaceAction } from 'vs/workbench/parts/search/browser/searchActions'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; -import { attachBadgeStyler } from "vs/platform/theme/common/styler"; -import { IThemeService } from "vs/platform/theme/common/themeService"; +import { attachBadgeStyler } from 'vs/platform/theme/common/styler'; +import { IThemeService } from 'vs/platform/theme/common/themeService'; export class SearchDataSource implements IDataSource { diff --git a/src/vs/workbench/parts/search/browser/searchViewlet.ts b/src/vs/workbench/parts/search/browser/searchViewlet.ts index ed2a0c9f953..04837eb7f6e 100644 --- a/src/vs/workbench/parts/search/browser/searchViewlet.ts +++ b/src/vs/workbench/parts/search/browser/searchViewlet.ts @@ -60,7 +60,7 @@ import FileResultsNavigation from 'vs/workbench/browser/fileResultsNavigation'; import { attachListStyler } from 'vs/platform/theme/common/styler'; import { IOutputService } from 'vs/workbench/parts/output/common/output'; import { Color } from 'vs/base/common/color'; -import { getOutOfWorkspaceEditorResources } from "vs/workbench/parts/search/common/search"; +import { getOutOfWorkspaceEditorResources } from 'vs/workbench/parts/search/common/search'; export class SearchViewlet extends Viewlet { diff --git a/src/vs/workbench/parts/search/common/search.ts b/src/vs/workbench/parts/search/common/search.ts index 19cd463c846..a6f98af6b22 100644 --- a/src/vs/workbench/parts/search/common/search.ts +++ b/src/vs/workbench/parts/search/common/search.ts @@ -12,10 +12,10 @@ import { CommonEditorRegistry } from 'vs/editor/common/editorCommonExtensions'; import { ISearchConfiguration } from 'vs/platform/search/common/search'; import glob = require('vs/base/common/glob'); import { SymbolInformation } from 'vs/editor/common/modes'; -import { IEditorGroupService } from "vs/workbench/services/group/common/groupService"; -import { IWorkspaceContextService } from "vs/platform/workspace/common/workspace"; -import URI from "vs/base/common/uri"; -import { toResource } from "vs/workbench/common/editor"; +import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; +import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import URI from 'vs/base/common/uri'; +import { toResource } from 'vs/workbench/common/editor'; export interface IWorkspaceSymbolProvider { provideWorkspaceSymbols(search: string): TPromise; diff --git a/src/vs/workbench/parts/search/common/searchModel.ts b/src/vs/workbench/parts/search/common/searchModel.ts index 87dae50f90e..114d6657c1a 100644 --- a/src/vs/workbench/parts/search/common/searchModel.ts +++ b/src/vs/workbench/parts/search/common/searchModel.ts @@ -24,7 +24,7 @@ import { IModelService } from 'vs/editor/common/services/modelService'; import { IReplaceService } from 'vs/workbench/parts/search/common/replace'; import { IProgressRunner } from 'vs/platform/progress/common/progress'; import { RangeHighlightDecorations } from 'vs/workbench/common/editor/rangeDecorations'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export class Match { diff --git a/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.ts b/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.ts index ae83175077b..dcdfe17498a 100644 --- a/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.ts +++ b/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.ts @@ -16,7 +16,7 @@ import { IModeService } from 'vs/editor/common/services/modeService'; import { languagesExtPoint } from 'vs/editor/common/services/modeServiceImpl'; import { LanguageIdentifier } from 'vs/editor/common/modes'; import { SnippetParser, Marker, Placeholder, Variable, Text, walk } from 'vs/editor/contrib/snippet/browser/snippetParser'; -import { EditorSnippetVariableResolver } from "vs/editor/contrib/snippet/browser/snippetVariables"; +import { EditorSnippetVariableResolver } from 'vs/editor/contrib/snippet/browser/snippetVariables'; interface ISnippetsExtensionPoint { language: string; diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts index c4e3fc01471..17e931a643b 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts @@ -27,7 +27,7 @@ import { ToggleTabFocusModeAction } from 'vs/editor/contrib/toggleTabFocusMode/c import { registerSingleton } from 'vs/platform/instantiation/common/extensions'; import { KeybindingsRegistry } from 'vs/platform/keybinding/common/keybindingsRegistry'; import { OpenNextRecentlyUsedEditorInGroupAction, OpenPreviousRecentlyUsedEditorInGroupAction, FocusActiveGroupAction, FocusFirstGroupAction, FocusSecondGroupAction, FocusThirdGroupAction } from 'vs/workbench/browser/parts/editor/editorActions'; -import { EDITOR_FONT_DEFAULTS } from "vs/editor/common/config/editorOptions"; +import { EDITOR_FONT_DEFAULTS } from 'vs/editor/common/config/editorOptions'; import { registerColors } from './terminalColorRegistry'; let configurationRegistry = Registry.as(Extensions.Configuration); diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.ts index 236474f7366..fda8ca9b994 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.ts @@ -5,7 +5,7 @@ import * as nls from 'vs/nls'; import * as platform from 'vs/base/common/platform'; -import { EDITOR_FONT_DEFAULTS, IEditorOptions } from "vs/editor/common/config/editorOptions"; +import { EDITOR_FONT_DEFAULTS, IEditorOptions } from 'vs/editor/common/config/editorOptions'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { IWorkspaceConfigurationService } from 'vs/workbench/services/configuration/common/configuration'; import { IChoiceService } from 'vs/platform/message/common/message'; diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index 8d7d30b7099..5247bd40e71 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -29,8 +29,8 @@ import { TabFocus } from 'vs/editor/common/config/commonEditorConfig'; import { TerminalConfigHelper } from 'vs/workbench/parts/terminal/electron-browser/terminalConfigHelper'; import { TerminalLinkHandler } from 'vs/workbench/parts/terminal/electron-browser/terminalLinkHandler'; import { TerminalWidgetManager } from 'vs/workbench/parts/terminal/browser/terminalWidgetManager'; -import { registerThemingParticipant, ITheme, ICssStyleCollector } from "vs/platform/theme/common/themeService"; -import { scrollbarSliderBackground, scrollbarSliderHoverBackground, scrollbarSliderActiveBackground } from "vs/platform/theme/common/colorRegistry"; +import { registerThemingParticipant, ITheme, ICssStyleCollector } from 'vs/platform/theme/common/themeService'; +import { scrollbarSliderBackground, scrollbarSliderHoverBackground, scrollbarSliderActiveBackground } from 'vs/platform/theme/common/colorRegistry'; /** The amount of time to consider terminal errors to be related to the launch */ const LAUNCHING_DURATION = 500; diff --git a/src/vs/workbench/parts/terminal/test/electron-browser/terminalConfigHelper.test.ts b/src/vs/workbench/parts/terminal/test/electron-browser/terminalConfigHelper.test.ts index 285bc9025ad..2e0b9c5831d 100644 --- a/src/vs/workbench/parts/terminal/test/electron-browser/terminalConfigHelper.test.ts +++ b/src/vs/workbench/parts/terminal/test/electron-browser/terminalConfigHelper.test.ts @@ -10,7 +10,7 @@ import { IConfigurationService, getConfigurationValue } from 'vs/platform/config import { Platform } from 'vs/base/common/platform'; import { TPromise } from 'vs/base/common/winjs.base'; import { TerminalConfigHelper } from 'vs/workbench/parts/terminal/electron-browser/terminalConfigHelper'; -import { EDITOR_FONT_DEFAULTS } from "vs/editor/common/config/editorOptions"; +import { EDITOR_FONT_DEFAULTS } from 'vs/editor/common/config/editorOptions'; class MockConfigurationService implements IConfigurationService { diff --git a/src/vs/workbench/parts/update/electron-browser/releaseNotesEditor.ts b/src/vs/workbench/parts/update/electron-browser/releaseNotesEditor.ts index 466aa77c62d..7f9174f7ca6 100644 --- a/src/vs/workbench/parts/update/electron-browser/releaseNotesEditor.ts +++ b/src/vs/workbench/parts/update/electron-browser/releaseNotesEditor.ts @@ -20,7 +20,7 @@ import { IModeService } from 'vs/editor/common/services/modeService'; import { tokenizeToString } from 'vs/editor/common/modes/textToHtmlTokenizer'; import { IPartService, Parts } from 'vs/workbench/services/part/common/partService'; import { WebviewEditor } from 'vs/workbench/browser/parts/editor/webviewEditor'; -import { IStorageService } from "vs/platform/storage/common/storage"; +import { IStorageService } from 'vs/platform/storage/common/storage'; function renderBody(body: string): string { return ` diff --git a/src/vs/workbench/services/editor/test/browser/editorService.test.ts b/src/vs/workbench/services/editor/test/browser/editorService.test.ts index e1f4057853f..4dd5a44fe16 100644 --- a/src/vs/workbench/services/editor/test/browser/editorService.test.ts +++ b/src/vs/workbench/services/editor/test/browser/editorService.test.ts @@ -16,7 +16,7 @@ import { FileEditorInput } from 'vs/workbench/parts/files/common/editors/fileEdi import { workbenchInstantiationService, TestThemeService } from 'vs/workbench/test/workbenchTestServices'; import { DelegatingWorkbenchEditorService, WorkbenchEditorService, IEditorPart } from 'vs/workbench/services/editor/browser/editorService'; import { UntitledEditorInput } from 'vs/workbench/common/editor/untitledEditorInput'; -import { ResourceEditorInput } from "vs/workbench/common/editor/resourceEditorInput"; +import { ResourceEditorInput } from 'vs/workbench/common/editor/resourceEditorInput'; let activeEditor: BaseEditor = { getSelection: function () { diff --git a/src/vs/workbench/services/themes/electron-browser/colorThemeData.ts b/src/vs/workbench/services/themes/electron-browser/colorThemeData.ts index aa101644f89..f182c1494c8 100644 --- a/src/vs/workbench/services/themes/electron-browser/colorThemeData.ts +++ b/src/vs/workbench/services/themes/electron-browser/colorThemeData.ts @@ -20,7 +20,7 @@ import { Extensions, IColorRegistry, ColorIdentifier, editorBackground, editorFo import { ThemeType } from 'vs/platform/theme/common/themeService'; import { Registry } from 'vs/platform/platform'; import { WorkbenchThemeService, IColorCustomizations } from "vs/workbench/services/themes/electron-browser/workbenchThemeService"; -import { getParseErrorMessage } from "vs/base/common/jsonErrorMessages"; +import { getParseErrorMessage } from 'vs/base/common/jsonErrorMessages'; let colorRegistry = Registry.as(Extensions.ColorContribution); diff --git a/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.ts b/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.ts index 72ad60ffe23..6e41871b060 100644 --- a/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.ts +++ b/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.ts @@ -39,7 +39,7 @@ import pfs = require('vs/base/node/pfs'); import colorThemeSchema = require('vs/workbench/services/themes/common/colorThemeSchema'); import fileIconThemeSchema = require('vs/workbench/services/themes/common/fileIconThemeSchema'); import { IDisposable } from 'vs/base/common/lifecycle'; -import { getParseErrorMessage } from "vs/base/common/jsonErrorMessages"; +import { getParseErrorMessage } from 'vs/base/common/jsonErrorMessages'; // implementation diff --git a/src/vs/workbench/test/browser/parts/editor/baseEditor.test.ts b/src/vs/workbench/test/browser/parts/editor/baseEditor.test.ts index cbdc5139462..4050b580de0 100644 --- a/src/vs/workbench/test/browser/parts/editor/baseEditor.test.ts +++ b/src/vs/workbench/test/browser/parts/editor/baseEditor.test.ts @@ -16,7 +16,7 @@ import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { NullTelemetryService } from 'vs/platform/telemetry/common/telemetryUtils'; import { PLAINTEXT_MODE_ID } from 'vs/editor/common/modes/modesRegistry'; import { workbenchInstantiationService, TestThemeService } from 'vs/workbench/test/workbenchTestServices'; -import { ResourceEditorInput } from "vs/workbench/common/editor/resourceEditorInput"; +import { ResourceEditorInput } from 'vs/workbench/common/editor/resourceEditorInput'; const NullThemeService = new TestThemeService(); diff --git a/src/vs/workbench/test/common/editor/editorDiffModel.test.ts b/src/vs/workbench/test/common/editor/editorDiffModel.test.ts index 2f5901c6e88..2db61acaf4e 100644 --- a/src/vs/workbench/test/common/editor/editorDiffModel.test.ts +++ b/src/vs/workbench/test/common/editor/editorDiffModel.test.ts @@ -12,15 +12,15 @@ import { TextDiffEditorModel } from 'vs/workbench/common/editor/textDiffEditorMo import { DiffEditorInput } from 'vs/workbench/common/editor/diffEditorInput'; import { IModelService } from 'vs/editor/common/services/modelService'; import { IModeService } from 'vs/editor/common/services/modeService'; -import { ResourceEditorInput } from "vs/workbench/common/editor/resourceEditorInput"; -import URI from "vs/base/common/uri"; -import { ITextModelResolverService } from "vs/editor/common/services/resolverService"; -import { ITextFileService } from "vs/workbench/services/textfile/common/textfiles"; -import { IUntitledEditorService } from "vs/workbench/services/untitled/common/untitledEditorService"; -import { TestTextFileService, workbenchInstantiationService } from "vs/workbench/test/workbenchTestServices"; +import { ResourceEditorInput } from 'vs/workbench/common/editor/resourceEditorInput'; +import URI from 'vs/base/common/uri'; +import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; +import { IUntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; +import { TestTextFileService, workbenchInstantiationService } from 'vs/workbench/test/workbenchTestServices'; import { TPromise } from "vs/base/common/winjs.base"; -import { IModel } from "vs/editor/common/editorCommon"; -import { IInstantiationService } from "vs/platform/instantiation/common/instantiation"; +import { IModel } from 'vs/editor/common/editorCommon'; +import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; class MyEditorModel extends EditorModel { } class MyTextEditorModel extends BaseTextEditorModel { } -- GitLab From 5ec01d95545c7ddf236424046477b36ec2511998 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 25 May 2017 10:44:49 +0200 Subject: [PATCH 0041/1347] a18y: avoid duplicate events when navigating trees (for #26730) --- src/vs/base/parts/tree/browser/treeView.ts | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/src/vs/base/parts/tree/browser/treeView.ts b/src/vs/base/parts/tree/browser/treeView.ts index 117e60db01d..3e27c21e709 100644 --- a/src/vs/base/parts/tree/browser/treeView.ts +++ b/src/vs/base/parts/tree/browser/treeView.ts @@ -197,22 +197,18 @@ export class ViewItem implements IViewItem { // ARIA this.element.setAttribute('role', 'treeitem'); + const ariaLabel = this.context.accessibilityProvider.getAriaLabel(this.context.tree, this.model.getElement()); + if (ariaLabel) { + this.element.setAttribute('aria-label', ariaLabel); + } if (this.model.hasTrait('focused')) { const base64Id = strings.safeBtoa(this.model.id); - const ariaLabel = this.context.accessibilityProvider.getAriaLabel(this.context.tree, this.model.getElement()); this.element.setAttribute('aria-selected', 'true'); this.element.setAttribute('id', base64Id); - if (ariaLabel) { - this.element.setAttribute('aria-label', ariaLabel); - } else { - this.element.setAttribute('aria-labelledby', base64Id); // force screen reader to compute label from children (helps NVDA at least) - } } else { this.element.setAttribute('aria-selected', 'false'); this.element.removeAttribute('id'); - this.element.removeAttribute('aria-label'); - this.element.removeAttribute('aria-labelledby'); } if (this.model.hasChildren()) { this.element.setAttribute('aria-expanded', String(!!this.model.isExpanded())); -- GitLab From 847fde97f99cec8f17c4f7f1f19d1f6f05f2bea7 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 25 May 2017 12:06:05 +0200 Subject: [PATCH 0042/1347] clean up unused code --- src/vs/workbench/electron-browser/shell.ts | 23 +++------------------- 1 file changed, 3 insertions(+), 20 deletions(-) diff --git a/src/vs/workbench/electron-browser/shell.ts b/src/vs/workbench/electron-browser/shell.ts index bec5d37606b..da3ce116627 100644 --- a/src/vs/workbench/electron-browser/shell.ts +++ b/src/vs/workbench/electron-browser/shell.ts @@ -62,7 +62,7 @@ import { IContextViewService } from 'vs/platform/contextview/browser/contextView import { ILifecycleService } from 'vs/platform/lifecycle/common/lifecycle'; import { IMarkerService } from 'vs/platform/markers/common/markers'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; -import { IMessageService, IChoiceService, Severity, CloseAction } from 'vs/platform/message/common/message'; +import { IMessageService, IChoiceService, Severity } from 'vs/platform/message/common/message'; import { ChoiceChannel } from 'vs/platform/message/common/messageIpc'; import { ISearchService } from 'vs/platform/search/common/search'; import { IThreadService } from 'vs/workbench/services/thread/common/threadService'; @@ -87,7 +87,6 @@ import { URLChannelClient } from 'vs/platform/url/common/urlIpc'; import { IURLService } from 'vs/platform/url/common/url'; import { IBackupService } from 'vs/platform/backup/common/backup'; import { BackupChannelClient } from 'vs/platform/backup/common/backupIpc'; -import { ReportPerformanceIssueAction } from 'vs/workbench/electron-browser/actions'; import { ExtensionHostProcessWorker } from 'vs/workbench/electron-browser/extensionHost'; import { ITimerService } from 'vs/workbench/services/timer/common/timerService'; import { remote, ipcRenderer as ipc } from 'electron'; @@ -198,7 +197,7 @@ export class WorkbenchShell { onWorkbenchStarted: (info: IWorkbenchStartedInfo) => { // run workbench started logic - this.onWorkbenchStarted(instantiationService, info); + this.onWorkbenchStarted(info); // start cached data manager instantiationService.createInstance(NodeCachedDataManager); @@ -221,7 +220,7 @@ export class WorkbenchShell { return workbenchContainer; } - private onWorkbenchStarted(instantiationService: IInstantiationService, info: IWorkbenchStartedInfo): void { + private onWorkbenchStarted(info: IWorkbenchStartedInfo): void { // Telemetry: workspace info const { filesToOpen, filesToCreate, filesToDiff } = this.options; @@ -248,12 +247,6 @@ export class WorkbenchShell { this.timerService.restoreViewletDuration = info.restoreViewletDuration; this.extensionService.onReady().done(() => { this.telemetryService.publicLog('startupTime', this.timerService.startupMetrics); - - // Check for negative performance numbers (insiders only) - // TODO@Ben remove me - if (product.quality !== 'stable' && this.timerService.startupMetrics.ellapsed < 0) { - this.handleNegativePerformanceNumbers(instantiationService, this.timerService.startupMetrics.ellapsed); - } }); // Telemetry: workspace tags @@ -266,16 +259,6 @@ export class WorkbenchShell { } } - private handleNegativePerformanceNumbers(i: IInstantiationService, time: number): void { - this.messageService.show(Severity.Warning, { - message: `Something went wrong measuring startup performance numbers (ellapsed: ${time}ms). We would like to learn more about this issue.`, - actions: [ - i.createInstance(ReportPerformanceIssueAction, ReportPerformanceIssueAction.ID, ReportPerformanceIssueAction.LABEL), - CloseAction - ] - }); - } - private initServiceCollection(container: HTMLElement): [IInstantiationService, ServiceCollection] { const disposables = new Disposables(); -- GitLab From 4486772abae3463ec6f9ed95556b69e297f00bc1 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 25 May 2017 12:16:33 +0200 Subject: [PATCH 0043/1347] Uncaught TypeError: Cannot read property 'isActive' of undefined (fixes #27257) --- src/vs/workbench/browser/parts/editor/tabsTitleControl.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts b/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts index 39993429952..de3fda8a4d5 100644 --- a/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts +++ b/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts @@ -212,7 +212,7 @@ export class TabsTitleControl extends TitleControl { private updateDropFeedback(element: HTMLElement, isDND: boolean, index?: number): void { const isTab = (typeof index === 'number'); - const isActiveTab = isTab && this.context.isActive(this.context.getEditor(index)); + const isActiveTab = isTab && this.context && this.context.isActive(this.context.getEditor(index)); // Background const noDNDBackgroundColor = isTab ? this.getColor(isActiveTab ? TAB_ACTIVE_BACKGROUND : TAB_INACTIVE_BACKGROUND) : null; -- GitLab From 39e6e908588a83c996d4ae3bfb457e17f87971c3 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 25 May 2017 12:21:18 +0200 Subject: [PATCH 0044/1347] theming - fix color clash when dragging over selected or focused item --- src/vs/base/parts/tree/browser/treeView.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/base/parts/tree/browser/treeView.ts b/src/vs/base/parts/tree/browser/treeView.ts index 3e27c21e709..fbbef901f54 100644 --- a/src/vs/base/parts/tree/browser/treeView.ts +++ b/src/vs/base/parts/tree/browser/treeView.ts @@ -602,7 +602,7 @@ export class TreeView extends HeightMap { if (styles.listDropBackground) { content.push(` .monaco-tree.monaco-tree-instance-${this.instance} .monaco-tree-wrapper.drop-target, - .monaco-tree.monaco-tree-instance-${this.instance} .monaco-tree-rows > .monaco-tree-row.drop-target { background-color: ${styles.listDropBackground} !important; } + .monaco-tree.monaco-tree-instance-${this.instance} .monaco-tree-rows > .monaco-tree-row.drop-target { background-color: ${styles.listDropBackground} !important; color: inherit !important; } `); } -- GitLab From 817d11bd5005d8c5d40731229765b4a6c573b793 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 09:24:50 +0200 Subject: [PATCH 0045/1347] [docker] update grammar --- build/npm/update-grammar.js | 30 ++++++++++++------- extensions/docker/package.json | 2 +- .../docker/syntaxes/docker.tmLanguage.json | 7 +++-- 3 files changed, 26 insertions(+), 13 deletions(-) diff --git a/build/npm/update-grammar.js b/build/npm/update-grammar.js index 4b0408b89b2..dbb12cdcb44 100644 --- a/build/npm/update-grammar.js +++ b/build/npm/update-grammar.js @@ -25,19 +25,28 @@ function getOptions(urlString) { } } -function download(url) { -return new Promise((c, e) => { - var content = ''; - var request = https.get(getOptions(url), function (response) { +function download(url, redirectCount) { + return new Promise((c, e) => { + var content = ''; + https.get(getOptions(url), function (response) { response.on('data', function (data) { content += data.toString(); }).on('end', function () { + let count = redirectCount || 0; + if (count < 5 && response.statusCode >= 300 && response.statusCode <= 303 || response.statusCode === 307) { + let location = response.headers['location']; + if (location) { + console.log("Redirected " + url + " to " + location); + download(location, count+1).then(c, e); + return; + } + } c(content); }); }).on('error', function (err) { e(err.message); }); -}); + }); } function getCommitSha(repoId, repoPath) { @@ -46,14 +55,15 @@ function getCommitSha(repoId, repoPath) { try { let lastCommit = JSON.parse(content)[0]; return Promise.resolve({ - commitSha : lastCommit.sha, - commitDate : lastCommit.commit.author.date + commitSha: lastCommit.sha, + commitDate: lastCommit.commit.author.date }); } catch (e) { + console.error("Failed extracting the SHA: " + content); return Promise.resolve(null); } }, function () { - console.err('Failed loading ' + commitInfo); + console.error('Failed loading ' + commitInfo); return Promise.resolve(null); }); } @@ -97,7 +107,7 @@ exports.update = function (repoId, repoPath, dest, modifyGrammar) { } if (path.basename(process.argv[1]) === 'update-grammar.js') { - for (var i = 3; i < process.argv.length; i+=2) { - exports.update(process.argv[2], process.argv[i], process.argv[i+1]); + for (var i = 3; i < process.argv.length; i += 2) { + exports.update(process.argv[2], process.argv[i], process.argv[i + 1]); } } diff --git a/extensions/docker/package.json b/extensions/docker/package.json index 0da40007bc6..e58f0826419 100644 --- a/extensions/docker/package.json +++ b/extensions/docker/package.json @@ -4,7 +4,7 @@ "publisher": "vscode", "engines": { "vscode": "*" }, "scripts": { - "update-grammar": "node ../../build/npm/update-grammar.js docker/docker contrib/syntax/textmate/Docker.tmbundle/Syntaxes/Dockerfile.tmLanguage ./syntaxes/docker.tmLanguage.json" + "update-grammar": "node ../../build/npm/update-grammar.js moby/moby contrib/syntax/textmate/Docker.tmbundle/Syntaxes/Dockerfile.tmLanguage ./syntaxes/docker.tmLanguage.json" }, "contributes": { "languages": [{ diff --git a/extensions/docker/syntaxes/docker.tmLanguage.json b/extensions/docker/syntaxes/docker.tmLanguage.json index caab35092b0..8be1c94055d 100644 --- a/extensions/docker/syntaxes/docker.tmLanguage.json +++ b/extensions/docker/syntaxes/docker.tmLanguage.json @@ -8,9 +8,12 @@ "captures": { "1": { "name": "keyword.other.special-method.dockerfile" + }, + "2": { + "name": "keyword.other.special-method.dockerfile" } }, - "match": "\\s*(?:(FROM|AS))\\s" + "match": "^\\s*\\b(FROM)\\b.*?\\b(AS)\\b" }, { "captures": { @@ -94,5 +97,5 @@ ], "scopeName": "source.dockerfile", "uuid": "a39d8795-59d2-49af-aa00-fe74ee29576e", - "version": "https://github.com/moby/moby/commit/4cb71f80823af345d063cf0ad657e73ce9caa75f" + "version": "https://github.com/moby/moby/commit/8523e9d108a0e98865673701a7bd0a7929c5260b" } \ No newline at end of file -- GitLab From dba4da9cba830bfd8a940829199c22970da40879 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 09:35:58 +0200 Subject: [PATCH 0046/1347] [scss] update grammar --- extensions/scss/syntaxes/scss.json | 29 +- .../test-cssvariables_scss.json | 12 +- .../scss/test/colorize-results/test_scss.json | 536 +++++++++--------- 3 files changed, 277 insertions(+), 300 deletions(-) diff --git a/extensions/scss/syntaxes/scss.json b/extensions/scss/syntaxes/scss.json index 1f09bd75e56..252cb843115 100644 --- a/extensions/scss/syntaxes/scss.json +++ b/extensions/scss/syntaxes/scss.json @@ -890,15 +890,6 @@ } ] }, - "constant_hex": { - "captures": { - "1": { - "name": "punctuation.definition.constant.scss" - } - }, - "match": "(#)([0-9a-fA-F]{3}|[0-9a-fA-F]{6})\\b", - "name": "constant.numeric.color.hex-value.scss" - }, "constant_important": { "match": "!important", "name": "keyword.other.important.scss" @@ -907,10 +898,6 @@ "match": "\\b(\\+|-|\\*|/)\\b", "name": "support.constant.mathematical-symbols.scss" }, - "constant_number": { - "match": "(\\b([0-9]+(\\.[0-9]+)?)|\\B\\.[0-9]+)(?=\\s*(ch|cm|deg|dpi|dpcm|dppx|em|ex|grad|in|mm|mozmm|ms|pc|pt|px|rad|rem|turn|s|vh|vmin|vmax|vw|\\b))", - "name": "constant.numeric.scss" - }, "constant_optional": { "match": "!optional", "name": "keyword.other.optional.scss" @@ -937,10 +924,6 @@ } ] }, - "constant_unit": { - "match": "(?<=[\\d])(ch|cm|deg|dpi|dpcm|dppx|em|ex|grad|in|mm|mozmm|ms|pc|pt|px|rad|rem|turn|s|vh|vmin|vmax|vw)\\b|%", - "name": "keyword.other.unit.scss" - }, "flow_control": { "patterns": [ { @@ -1242,9 +1225,6 @@ { "include": "#constant_sass_functions" }, - { - "include": "#constant_hex" - }, { "include": "#constant_important" }, @@ -1255,10 +1235,7 @@ "include": "#constant_optional" }, { - "include": "#constant_unit" - }, - { - "include": "#constant_number" + "include": "source.css#numeric-values" }, { "include": "source.css#property-keywords" @@ -1543,7 +1520,7 @@ }, { "match": "\\d+", - "name": "constant.numeric.scss" + "name": "constant.numeric.css" }, { "match": "(?<=\\d)n\\b|\\b(n|even|odd)\\b", @@ -1698,5 +1675,5 @@ "name": "variable.scss" } }, - "version": "https://github.com/atom/language-sass/commit/f477576a0ff819657495142f7e64e577a837fadb" + "version": "https://github.com/atom/language-sass/commit/8b8b7b52655ab5cf4dbe597443abe4b078bb6953" } \ No newline at end of file diff --git a/extensions/scss/test/colorize-results/test-cssvariables_scss.json b/extensions/scss/test/colorize-results/test-cssvariables_scss.json index ff30ea6b973..e51a05d345f 100644 --- a/extensions/scss/test/colorize-results/test-cssvariables_scss.json +++ b/extensions/scss/test/colorize-results/test-cssvariables_scss.json @@ -89,7 +89,7 @@ }, { "c": "6", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -100,7 +100,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -177,7 +177,7 @@ }, { "c": "4", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -397,7 +397,7 @@ }, { "c": "4", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -496,7 +496,7 @@ }, { "c": "5", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -507,7 +507,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", diff --git a/extensions/scss/test/colorize-results/test_scss.json b/extensions/scss/test/colorize-results/test_scss.json index 4f699f59ebf..ffcdbc7f034 100644 --- a/extensions/scss/test/colorize-results/test_scss.json +++ b/extensions/scss/test/colorize-results/test_scss.json @@ -287,7 +287,7 @@ }, { "c": "97", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -298,7 +298,7 @@ }, { "c": "%", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -430,7 +430,7 @@ }, { "c": "2", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -441,7 +441,7 @@ }, { "c": "em", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.em.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -705,7 +705,7 @@ }, { "c": "3", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -716,7 +716,7 @@ }, { "c": "em", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.em.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -1332,7 +1332,7 @@ }, { "c": "2", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -1343,7 +1343,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -1365,7 +1365,7 @@ }, { "c": "3", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -1376,7 +1376,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -1486,7 +1486,7 @@ }, { "c": "30", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -1497,7 +1497,7 @@ }, { "c": "em", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.em.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -1849,7 +1849,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -1937,7 +1937,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -1948,7 +1948,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -2157,7 +2157,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -2278,7 +2278,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -2839,7 +2839,7 @@ }, { "c": "5", - "t": "source.css.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -2850,7 +2850,7 @@ }, { "c": "em", - "t": "source.css.scss meta.set.variable.scss keyword.other.unit.scss", + "t": "source.css.scss meta.set.variable.scss constant.numeric.css keyword.other.unit.em.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -3059,7 +3059,7 @@ }, { "c": "6", - "t": "source.css.scss meta.property-list.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -3070,7 +3070,7 @@ }, { "c": "em", - "t": "source.css.scss meta.property-list.scss meta.set.variable.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css keyword.other.unit.em.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -3202,7 +3202,7 @@ }, { "c": "12", - "t": "source.css.scss meta.property-list.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -3213,7 +3213,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.set.variable.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -3279,7 +3279,7 @@ }, { "c": "30", - "t": "source.css.scss meta.property-list.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -3290,7 +3290,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.set.variable.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -3862,7 +3862,7 @@ }, { "c": "100", - "t": "source.css.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -3895,7 +3895,7 @@ }, { "c": "100", - "t": "source.css.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -3928,7 +3928,7 @@ }, { "c": "225", - "t": "source.css.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -3961,7 +3961,7 @@ }, { "c": "0.25", - "t": "source.css.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -4137,7 +4137,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -4148,7 +4148,7 @@ }, { "c": "em", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.em.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -4192,7 +4192,7 @@ }, { "c": "2", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -4203,7 +4203,7 @@ }, { "c": "em", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.em.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -4258,7 +4258,7 @@ }, { "c": "3", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -4324,24 +4324,24 @@ }, { "c": "#", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "010203", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -4379,24 +4379,24 @@ }, { "c": "#", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "040506", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -4577,7 +4577,7 @@ }, { "c": "3", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -4588,7 +4588,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -4632,7 +4632,7 @@ }, { "c": "4", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -4643,7 +4643,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -4764,7 +4764,7 @@ }, { "c": "5", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss string.quoted.double.scss variable.interpolation.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss string.quoted.double.scss variable.interpolation.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -4808,7 +4808,7 @@ }, { "c": "10", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss string.quoted.double.scss variable.interpolation.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss string.quoted.double.scss variable.interpolation.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -4929,7 +4929,7 @@ }, { "c": "0", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -4962,7 +4962,7 @@ }, { "c": "100", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -4973,7 +4973,7 @@ }, { "c": "%", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -5006,7 +5006,7 @@ }, { "c": "50", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -5017,7 +5017,7 @@ }, { "c": "%", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -5149,7 +5149,7 @@ }, { "c": "0", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -5215,7 +5215,7 @@ }, { "c": "100", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -5226,7 +5226,7 @@ }, { "c": "%", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -5292,7 +5292,7 @@ }, { "c": "50", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -5303,7 +5303,7 @@ }, { "c": "%", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -5413,7 +5413,7 @@ }, { "c": "40", - "t": "source.css.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -5424,7 +5424,7 @@ }, { "c": "px", - "t": "source.css.scss meta.set.variable.scss keyword.other.unit.scss", + "t": "source.css.scss meta.set.variable.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -5479,7 +5479,7 @@ }, { "c": "10", - "t": "source.css.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -5490,7 +5490,7 @@ }, { "c": "px", - "t": "source.css.scss meta.set.variable.scss keyword.other.unit.scss", + "t": "source.css.scss meta.set.variable.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -5798,7 +5798,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.at-rule.return.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.at-rule.return.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -5996,7 +5996,7 @@ }, { "c": "5", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -6722,7 +6722,7 @@ }, { "c": "300", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -6733,7 +6733,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -6975,7 +6975,7 @@ }, { "c": "500", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -6986,7 +6986,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -7162,7 +7162,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -7173,7 +7173,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -7195,24 +7195,24 @@ }, { "c": "#", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "f00", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -7272,24 +7272,24 @@ }, { "c": "#", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "fdd", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -7459,7 +7459,7 @@ }, { "c": "3", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -7470,7 +7470,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -7756,7 +7756,7 @@ }, { "c": "2", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -7767,7 +7767,7 @@ }, { "c": "em", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.em.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -8438,7 +8438,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -8449,7 +8449,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -8823,7 +8823,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -8834,7 +8834,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -9274,7 +9274,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -9318,7 +9318,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -9362,7 +9362,7 @@ }, { "c": "2", - "t": "source.css.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -9439,7 +9439,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -9450,7 +9450,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -9560,7 +9560,7 @@ }, { "c": "5", - "t": "source.css.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -9604,7 +9604,7 @@ }, { "c": "3", - "t": "source.css.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -9681,7 +9681,7 @@ }, { "c": "2", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -9692,7 +9692,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -9857,7 +9857,7 @@ }, { "c": "3", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -9868,7 +9868,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -10495,7 +10495,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.for.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.for.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -10539,7 +10539,7 @@ }, { "c": "3", - "t": "source.css.scss meta.at-rule.for.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.for.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -10704,7 +10704,7 @@ }, { "c": "2", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -10715,7 +10715,7 @@ }, { "c": "em", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.em.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -11298,7 +11298,7 @@ }, { "c": "6", - "t": "source.css.scss meta.at-rule.each.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -11397,7 +11397,7 @@ }, { "c": "0", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -11562,7 +11562,7 @@ }, { "c": "2", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -11573,7 +11573,7 @@ }, { "c": "em", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.em.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -11749,7 +11749,7 @@ }, { "c": "2", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -12035,7 +12035,7 @@ }, { "c": "0", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.for.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.for.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -12387,7 +12387,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -12475,7 +12475,7 @@ }, { "c": "100", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -12486,7 +12486,7 @@ }, { "c": "%", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -12970,7 +12970,7 @@ }, { "c": "20", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -12981,7 +12981,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -13135,24 +13135,24 @@ }, { "c": "#", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "ff0000", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -13333,7 +13333,7 @@ }, { "c": "4", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -13344,7 +13344,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -13520,7 +13520,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.at-rule.mixin.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.at-rule.mixin.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -13531,7 +13531,7 @@ }, { "c": "in", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.at-rule.mixin.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.at-rule.mixin.scss constant.numeric.css keyword.other.unit.in.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -14455,7 +14455,7 @@ }, { "c": "0", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -14466,7 +14466,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -14488,7 +14488,7 @@ }, { "c": "4", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -14499,7 +14499,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -14521,7 +14521,7 @@ }, { "c": "5", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -14532,7 +14532,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -14554,24 +14554,24 @@ }, { "c": "#", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "666", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -14587,7 +14587,7 @@ }, { "c": "2", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -14598,7 +14598,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -14620,7 +14620,7 @@ }, { "c": "6", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -14631,7 +14631,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -14653,7 +14653,7 @@ }, { "c": "10", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -14664,7 +14664,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -14686,24 +14686,24 @@ }, { "c": "#", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "999", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -15148,24 +15148,24 @@ }, { "c": "#", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "ff0000", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -15181,24 +15181,24 @@ }, { "c": "#", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "00ff00", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -15214,24 +15214,24 @@ }, { "c": "#", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "0000ff", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -16479,7 +16479,7 @@ }, { "c": "4", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -16490,7 +16490,7 @@ }, { "c": "cm", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.cm.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -16556,7 +16556,7 @@ }, { "c": "3", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -16567,7 +16567,7 @@ }, { "c": "cm", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.cm.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -16798,7 +16798,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -16809,7 +16809,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -17084,7 +17084,7 @@ }, { "c": "0", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -17128,24 +17128,24 @@ }, { "c": "#", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "123", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -17205,7 +17205,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -17656,7 +17656,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -17667,7 +17667,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -17777,7 +17777,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -17788,7 +17788,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -18470,7 +18470,7 @@ }, { "c": "0", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -18569,7 +18569,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -18701,7 +18701,7 @@ }, { "c": "2", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -18811,7 +18811,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -19009,7 +19009,7 @@ }, { "c": "0", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -19141,7 +19141,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -19328,7 +19328,7 @@ }, { "c": "0", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -19460,7 +19460,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -19647,7 +19647,7 @@ }, { "c": "0", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -19757,7 +19757,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -19966,7 +19966,7 @@ }, { "c": "0", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -20098,7 +20098,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", -- GitLab From 175cece493096b00983e88f5c2a7e40220dffd33 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 10:36:09 +0200 Subject: [PATCH 0047/1347] [ini] add update script --- extensions/ini/package.json | 11 +- extensions/ini/syntaxes/ini.tmLanguage.json | 114 +++++++++++ extensions/ini/syntaxes/properties.plist | 181 ------------------ .../ini/test/colorize-results/test_ini.json | 54 +++--- 4 files changed, 148 insertions(+), 212 deletions(-) create mode 100644 extensions/ini/syntaxes/ini.tmLanguage.json delete mode 100644 extensions/ini/syntaxes/properties.plist diff --git a/extensions/ini/package.json b/extensions/ini/package.json index b6a9b6c37d0..bfb7bb52215 100644 --- a/extensions/ini/package.json +++ b/extensions/ini/package.json @@ -3,6 +3,9 @@ "version": "0.1.0", "publisher": "vscode", "engines": { "vscode": "*" }, + "scripts": { + "update-grammar": "node ../../build/npm/update-grammar.js textmate/ini.tmbundle Syntaxes/Ini.plist ./syntaxes/ini.tmLanguage.json" + }, "contributes": { "languages": [{ "id": "ini", @@ -19,12 +22,12 @@ }], "grammars": [{ "language": "ini", - "scopeName": "source.properties", - "path": "./syntaxes/properties.plist" + "scopeName": "source.ini", + "path": "./syntaxes/ini.tmLanguage.json" },{ "language": "properties", - "scopeName": "source.properties", - "path": "./syntaxes/properties.plist" + "scopeName": "source.ini", + "path": "./syntaxes/ini.tmLanguage.json" }] } } diff --git a/extensions/ini/syntaxes/ini.tmLanguage.json b/extensions/ini/syntaxes/ini.tmLanguage.json new file mode 100644 index 00000000000..e8f1a0ef9b3 --- /dev/null +++ b/extensions/ini/syntaxes/ini.tmLanguage.json @@ -0,0 +1,114 @@ +{ + "fileTypes": [ + "ini", + "conf" + ], + "keyEquivalent": "^~I", + "name": "Ini", + "patterns": [ + { + "begin": "(^[ \\t]+)?(?=#)", + "beginCaptures": { + "1": { + "name": "punctuation.whitespace.comment.leading.ini" + } + }, + "end": "(?!\\G)", + "patterns": [ + { + "begin": "#", + "beginCaptures": { + "0": { + "name": "punctuation.definition.comment.ini" + } + }, + "end": "\\n", + "name": "comment.line.number-sign.ini" + } + ] + }, + { + "begin": "(^[ \\t]+)?(?=;)", + "beginCaptures": { + "1": { + "name": "punctuation.whitespace.comment.leading.ini" + } + }, + "end": "(?!\\G)", + "patterns": [ + { + "begin": ";", + "beginCaptures": { + "0": { + "name": "punctuation.definition.comment.ini" + } + }, + "end": "\\n", + "name": "comment.line.semicolon.ini" + } + ] + }, + { + "captures": { + "1": { + "name": "keyword.other.definition.ini" + }, + "2": { + "name": "punctuation.separator.key-value.ini" + } + }, + "match": "\\b([a-zA-Z0-9_.-]+)\\b\\s*(=)" + }, + { + "captures": { + "1": { + "name": "punctuation.definition.entity.ini" + }, + "3": { + "name": "punctuation.definition.entity.ini" + } + }, + "match": "^(\\[)(.*?)(\\])", + "name": "entity.name.section.group-title.ini" + }, + { + "begin": "'", + "beginCaptures": { + "0": { + "name": "punctuation.definition.string.begin.ini" + } + }, + "end": "'", + "endCaptures": { + "0": { + "name": "punctuation.definition.string.end.ini" + } + }, + "name": "string.quoted.single.ini", + "patterns": [ + { + "match": "\\\\.", + "name": "constant.character.escape.ini" + } + ] + }, + { + "begin": "\"", + "beginCaptures": { + "0": { + "name": "punctuation.definition.string.begin.ini" + } + }, + "end": "\"", + "endCaptures": { + "0": { + "name": "punctuation.definition.string.end.ini" + } + }, + "name": "string.quoted.double.ini" + } + ], + "scopeName": "source.ini", + "uuid": "77DC23B6-8A90-11D9-BAA4-000A9584EC8C", + "version": "https://github.com/textmate/ini.tmbundle/commit/2af0cbb0704940f967152616f2f1ff0aae6287a6" +} \ No newline at end of file diff --git a/extensions/ini/syntaxes/properties.plist b/extensions/ini/syntaxes/properties.plist deleted file mode 100644 index 11436566bd5..00000000000 --- a/extensions/ini/syntaxes/properties.plist +++ /dev/null @@ -1,181 +0,0 @@ - - - - - fileTypes - - ini - conf - - keyEquivalent - ^~I - name - Ini - patterns - - - begin - (^[ \t]+)?(?=#) - beginCaptures - - 1 - - name - punctuation.whitespace.comment.leading.ini - - - end - (?!\G) - patterns - - - begin - # - beginCaptures - - 0 - - name - punctuation.definition.comment.ini - - - end - \n - name - comment.line.number-sign.ini - - - - - begin - (^[ \t]+)?(?=;) - beginCaptures - - 1 - - name - punctuation.whitespace.comment.leading.ini - - - end - (?!\G) - patterns - - - begin - ; - beginCaptures - - 0 - - name - punctuation.definition.comment.ini - - - end - \n - name - comment.line.semicolon.ini - - - - - captures - - 1 - - name - keyword.other.definition.ini - - 2 - - name - punctuation.separator.key-value.ini - - - match - \b([a-zA-Z0-9_.-]+)\b\s*(=) - - - captures - - 1 - - name - punctuation.definition.entity.ini - - 3 - - name - punctuation.definition.entity.ini - - - match - ^(\[)(.*?)(\]) - name - entity.name.section.group-title.ini - - - begin - ' - beginCaptures - - 0 - - name - punctuation.definition.string.begin.ini - - - end - ' - endCaptures - - 0 - - name - punctuation.definition.string.end.ini - - - name - string.quoted.single.ini - patterns - - - match - \\. - name - constant.character.escape.ini - - - - - begin - " - beginCaptures - - 0 - - name - punctuation.definition.string.begin.ini - - - end - " - endCaptures - - 0 - - name - punctuation.definition.string.end.ini - - - name - string.quoted.double.ini - - - scopeName - source.properties - uuid - 77DC23B6-8A90-11D9-BAA4-000A9584EC8C - - \ No newline at end of file diff --git a/extensions/ini/test/colorize-results/test_ini.json b/extensions/ini/test/colorize-results/test_ini.json index f30cdc53892..5b001c68246 100644 --- a/extensions/ini/test/colorize-results/test_ini.json +++ b/extensions/ini/test/colorize-results/test_ini.json @@ -1,7 +1,7 @@ [ { "c": ";", - "t": "source.properties comment.line.semicolon.ini punctuation.definition.comment.ini", + "t": "source.ini comment.line.semicolon.ini punctuation.definition.comment.ini", "r": { "dark_plus": "comment: #608B4E", "light_plus": "comment: #008000", @@ -12,7 +12,7 @@ }, { "c": " last modified 1 April 2001 by John Doe", - "t": "source.properties comment.line.semicolon.ini", + "t": "source.ini comment.line.semicolon.ini", "r": { "dark_plus": "comment: #608B4E", "light_plus": "comment: #008000", @@ -23,7 +23,7 @@ }, { "c": "[", - "t": "source.properties entity.name.section.group-title.ini punctuation.definition.entity.ini", + "t": "source.ini entity.name.section.group-title.ini punctuation.definition.entity.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -34,7 +34,7 @@ }, { "c": "owner", - "t": "source.properties entity.name.section.group-title.ini", + "t": "source.ini entity.name.section.group-title.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -45,7 +45,7 @@ }, { "c": "]", - "t": "source.properties entity.name.section.group-title.ini punctuation.definition.entity.ini", + "t": "source.ini entity.name.section.group-title.ini punctuation.definition.entity.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -56,7 +56,7 @@ }, { "c": "name", - "t": "source.properties keyword.other.definition.ini", + "t": "source.ini keyword.other.definition.ini", "r": { "dark_plus": "keyword: #569CD6", "light_plus": "keyword: #0000FF", @@ -67,7 +67,7 @@ }, { "c": "=", - "t": "source.properties punctuation.separator.key-value.ini", + "t": "source.ini punctuation.separator.key-value.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -78,7 +78,7 @@ }, { "c": "John Doe", - "t": "source.properties", + "t": "source.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -89,7 +89,7 @@ }, { "c": "organization", - "t": "source.properties keyword.other.definition.ini", + "t": "source.ini keyword.other.definition.ini", "r": { "dark_plus": "keyword: #569CD6", "light_plus": "keyword: #0000FF", @@ -100,7 +100,7 @@ }, { "c": "=", - "t": "source.properties punctuation.separator.key-value.ini", + "t": "source.ini punctuation.separator.key-value.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -111,7 +111,7 @@ }, { "c": "Acme Widgets Inc.", - "t": "source.properties", + "t": "source.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -122,7 +122,7 @@ }, { "c": "[", - "t": "source.properties entity.name.section.group-title.ini punctuation.definition.entity.ini", + "t": "source.ini entity.name.section.group-title.ini punctuation.definition.entity.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -133,7 +133,7 @@ }, { "c": "database", - "t": "source.properties entity.name.section.group-title.ini", + "t": "source.ini entity.name.section.group-title.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -144,7 +144,7 @@ }, { "c": "]", - "t": "source.properties entity.name.section.group-title.ini punctuation.definition.entity.ini", + "t": "source.ini entity.name.section.group-title.ini punctuation.definition.entity.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -155,7 +155,7 @@ }, { "c": ";", - "t": "source.properties comment.line.semicolon.ini punctuation.definition.comment.ini", + "t": "source.ini comment.line.semicolon.ini punctuation.definition.comment.ini", "r": { "dark_plus": "comment: #608B4E", "light_plus": "comment: #008000", @@ -166,7 +166,7 @@ }, { "c": " use IP address in case network name resolution is not working", - "t": "source.properties comment.line.semicolon.ini", + "t": "source.ini comment.line.semicolon.ini", "r": { "dark_plus": "comment: #608B4E", "light_plus": "comment: #008000", @@ -177,7 +177,7 @@ }, { "c": "server", - "t": "source.properties keyword.other.definition.ini", + "t": "source.ini keyword.other.definition.ini", "r": { "dark_plus": "keyword: #569CD6", "light_plus": "keyword: #0000FF", @@ -188,7 +188,7 @@ }, { "c": "=", - "t": "source.properties punctuation.separator.key-value.ini", + "t": "source.ini punctuation.separator.key-value.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -199,7 +199,7 @@ }, { "c": "192.0.2.62", - "t": "source.properties", + "t": "source.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -210,7 +210,7 @@ }, { "c": "port", - "t": "source.properties keyword.other.definition.ini", + "t": "source.ini keyword.other.definition.ini", "r": { "dark_plus": "keyword: #569CD6", "light_plus": "keyword: #0000FF", @@ -221,7 +221,7 @@ }, { "c": "=", - "t": "source.properties punctuation.separator.key-value.ini", + "t": "source.ini punctuation.separator.key-value.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -232,7 +232,7 @@ }, { "c": "143", - "t": "source.properties", + "t": "source.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -243,7 +243,7 @@ }, { "c": "file", - "t": "source.properties keyword.other.definition.ini", + "t": "source.ini keyword.other.definition.ini", "r": { "dark_plus": "keyword: #569CD6", "light_plus": "keyword: #0000FF", @@ -254,7 +254,7 @@ }, { "c": "=", - "t": "source.properties punctuation.separator.key-value.ini", + "t": "source.ini punctuation.separator.key-value.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -265,7 +265,7 @@ }, { "c": "\"", - "t": "source.properties string.quoted.double.ini punctuation.definition.string.begin.ini", + "t": "source.ini string.quoted.double.ini punctuation.definition.string.begin.ini", "r": { "dark_plus": "string: #CE9178", "light_plus": "string: #A31515", @@ -276,7 +276,7 @@ }, { "c": "payroll.dat", - "t": "source.properties string.quoted.double.ini", + "t": "source.ini string.quoted.double.ini", "r": { "dark_plus": "string: #CE9178", "light_plus": "string: #A31515", @@ -287,7 +287,7 @@ }, { "c": "\"", - "t": "source.properties string.quoted.double.ini punctuation.definition.string.end.ini", + "t": "source.ini string.quoted.double.ini punctuation.definition.string.end.ini", "r": { "dark_plus": "string: #CE9178", "light_plus": "string: #A31515", -- GitLab From 3cdc7b7472bcdbb0feef079368afba1b238a7750 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 11:27:32 +0200 Subject: [PATCH 0048/1347] update all grammars script --- build/npm/update-all-grammars.js | 74 ++++++++++++++++++++++++++++++ extensions/typescript/package.json | 2 +- package.json | 3 +- 3 files changed, 77 insertions(+), 2 deletions(-) create mode 100644 build/npm/update-all-grammars.js diff --git a/build/npm/update-all-grammars.js b/build/npm/update-all-grammars.js new file mode 100644 index 00000000000..252b0f4edcb --- /dev/null +++ b/build/npm/update-all-grammars.js @@ -0,0 +1,74 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +const cp = require('child_process'); +const npm = process.platform === 'win32' ? 'npm.cmd' : 'npm'; +const integrationTests = process.platform === 'win32' ? '.\test-integration.bat' : './test-integration.sh'; + +function updateGrammar(location) { + const result = cp.spawnSync(npm, ['run', 'update-grammar'], { + cwd: location, + stdio: 'inherit' + }); + + if (result.error || result.status !== 0) { + process.exit(1); + } +} + +const extensions = [ + // 'bat' Grammar no longer available + 'clojure', + 'coffeescript', + 'cpp', + 'csharp', + 'css', + 'diff', + 'docker', + 'fsharp', + 'gitsyntax', + 'go', + 'groovy', + 'handlebars', + 'hlsl', + 'html', + 'ini', + 'java', + // 'javascript', updated through JavaScript + // 'json', customized + 'less', + 'lua', + 'make', + 'markdown', + 'objective-c', + 'perl', + 'php', + // 'powershell', grammar not ready yet, @daviwil will ping when ready + 'pug', + 'python', + 'r', + 'razor', + 'ruby', + 'rust', + 'scss', + 'shaderlab', + 'shellscript', + // 'sql', customized, PRs pending + 'swift', + 'typescript', + 'vb', + 'xml', + 'yaml' +]; + +extensions.forEach(extension => updateGrammar(`extensions/${extension}`)); + +// run integration tests + +if (process.platform === 'win32') { + cp.spawn('.\scripts\test-integration.bat', [], { env: process.env, stdio: 'inherit' }); +} else { + cp.spawn('/bin/bash', ['./scripts/test-integration.sh'], { env: process.env, stdio: 'inherit' }); +} \ No newline at end of file diff --git a/extensions/typescript/package.json b/extensions/typescript/package.json index a24c0c10519..461cb773a4d 100644 --- a/extensions/typescript/package.json +++ b/extensions/typescript/package.json @@ -21,7 +21,7 @@ }, "scripts": { "vscode:prepublish": "node ../../node_modules/gulp/bin/gulp.js --gulpfile ../../build/gulpfile.extensions.js compile-extension:typescript ./tsconfig.json", - "update-grammars": "node ./build/update-grammars.js" + "update-grammar": "node ./build/update-grammars.js" }, "activationEvents": [ "onLanguage:javascript", diff --git a/package.json b/package.json index 236e9d787e5..c31f58f40c9 100644 --- a/package.json +++ b/package.json @@ -18,7 +18,8 @@ "monaco-editor-test": "mocha --only-monaco-editor", "precommit": "node build/gulpfile.hygiene.js", "gulp": "gulp --max_old_space_size=4096", - "7z": "7z" + "7z": "7z", + "update-grammars": "node build/npm/update-all-grammars.js" }, "dependencies": { "applicationinsights": "0.17.1", -- GitLab From c96342e995e652d3b6bcc07237ca9c4953ce6a94 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 11:27:46 +0200 Subject: [PATCH 0049/1347] [clojure] update grammar --- .../clojure/syntaxes/clojure.tmLanguage.json | 25 +++++-------------- 1 file changed, 6 insertions(+), 19 deletions(-) diff --git a/extensions/clojure/syntaxes/clojure.tmLanguage.json b/extensions/clojure/syntaxes/clojure.tmLanguage.json index 6e2d50b5ea5..881ce191e1c 100644 --- a/extensions/clojure/syntaxes/clojure.tmLanguage.json +++ b/extensions/clojure/syntaxes/clojure.tmLanguage.json @@ -64,14 +64,11 @@ }, { "include": "#symbol" - }, - { - "include": "#whitespace" } ], "repository": { "comment": { - "begin": ";", + "begin": "(? Date: Thu, 25 May 2017 11:27:59 +0200 Subject: [PATCH 0050/1347] [cpp] update grammar --- extensions/cpp/syntaxes/c++.json | 5 +- .../cpp/test/colorize-results/test_cc.json | 118 +++++++++++++++++- 2 files changed, 118 insertions(+), 5 deletions(-) diff --git a/extensions/cpp/syntaxes/c++.json b/extensions/cpp/syntaxes/c++.json index 0d20c95fb60..7ec3054f58b 100644 --- a/extensions/cpp/syntaxes/c++.json +++ b/extensions/cpp/syntaxes/c++.json @@ -425,6 +425,9 @@ { "match": "\\\\x\\h+", "name": "constant.character.escape.cpp" + }, + { + "include": "source.c#string_placeholder" } ] }, @@ -455,5 +458,5 @@ ] } }, - "version": "https://github.com/atom/language-c/commit/a74c2f967d73e802a67fa6e971a8e8dedf076597" + "version": "https://github.com/atom/language-c/commit/3a269f88b12e512fb9495dc006a1dabf325d3d7f" } \ No newline at end of file diff --git a/extensions/cpp/test/colorize-results/test_cc.json b/extensions/cpp/test/colorize-results/test_cc.json index 3f7be3caeb8..845a693b3ab 100644 --- a/extensions/cpp/test/colorize-results/test_cc.json +++ b/extensions/cpp/test/colorize-results/test_cc.json @@ -110,7 +110,29 @@ } }, { - "c": "num_candidate_ret=%d:", + "c": "num_candidate_ret=", + "t": "source.cpp meta.function.c string.quoted.double.cpp", + "r": { + "dark_plus": "string: #CE9178", + "light_plus": "string: #A31515", + "dark_vs": "string: #CE9178", + "light_vs": "string: #A31515", + "hc_black": "string: #CE9178" + } + }, + { + "c": "%d", + "t": "source.cpp meta.function.c string.quoted.double.cpp constant.other.placeholder.c", + "r": { + "dark_plus": "string: #CE9178", + "light_plus": "string: #A31515", + "dark_vs": "string: #CE9178", + "light_vs": "string: #A31515", + "hc_black": "string: #CE9178" + } + }, + { + "c": ":", "t": "source.cpp meta.function.c string.quoted.double.cpp", "r": { "dark_plus": "string: #CE9178", @@ -407,7 +429,18 @@ } }, { - "c": "%d,", + "c": "%d", + "t": "source.cpp meta.function.c string.quoted.double.cpp constant.other.placeholder.c", + "r": { + "dark_plus": "string: #CE9178", + "light_plus": "string: #A31515", + "dark_vs": "string: #CE9178", + "light_vs": "string: #A31515", + "hc_black": "string: #CE9178" + } + }, + { + "c": ",", "t": "source.cpp meta.function.c string.quoted.double.cpp", "r": { "dark_plus": "string: #CE9178", @@ -1375,7 +1408,29 @@ } }, { - "c": "STYLE=Keramik;TITLE=%s;THEME=%s", + "c": "STYLE=Keramik;TITLE=", + "t": "source.cpp meta.block.c string.quoted.double.cpp", + "r": { + "dark_plus": "string: #CE9178", + "light_plus": "string: #A31515", + "dark_vs": "string: #CE9178", + "light_vs": "string: #A31515", + "hc_black": "string: #CE9178" + } + }, + { + "c": "%s", + "t": "source.cpp meta.block.c string.quoted.double.cpp constant.other.placeholder.c", + "r": { + "dark_plus": "string: #CE9178", + "light_plus": "string: #A31515", + "dark_vs": "string: #CE9178", + "light_vs": "string: #A31515", + "hc_black": "string: #CE9178" + } + }, + { + "c": ";THEME=", "t": "source.cpp meta.block.c string.quoted.double.cpp", "r": { "dark_plus": "string: #CE9178", @@ -1385,6 +1440,17 @@ "hc_black": "string: #CE9178" } }, + { + "c": "%s", + "t": "source.cpp meta.block.c string.quoted.double.cpp constant.other.placeholder.c", + "r": { + "dark_plus": "string: #CE9178", + "light_plus": "string: #A31515", + "dark_vs": "string: #CE9178", + "light_vs": "string: #A31515", + "hc_black": "string: #CE9178" + } + }, { "c": "\"", "t": "source.cpp meta.block.c string.quoted.double.cpp punctuation.definition.string.end.cpp", @@ -1705,7 +1771,51 @@ } }, { - "c": "movw $0x38, %ax; ltr %ax", + "c": "movw $0x38, ", + "t": "source.cpp meta.block.c meta.function-call.c string.quoted.double.cpp", + "r": { + "dark_plus": "string: #CE9178", + "light_plus": "string: #A31515", + "dark_vs": "string: #CE9178", + "light_vs": "string: #A31515", + "hc_black": "string: #CE9178" + } + }, + { + "c": "%a", + "t": "source.cpp meta.block.c meta.function-call.c string.quoted.double.cpp constant.other.placeholder.c", + "r": { + "dark_plus": "string: #CE9178", + "light_plus": "string: #A31515", + "dark_vs": "string: #CE9178", + "light_vs": "string: #A31515", + "hc_black": "string: #CE9178" + } + }, + { + "c": "x; ltr ", + "t": "source.cpp meta.block.c meta.function-call.c string.quoted.double.cpp", + "r": { + "dark_plus": "string: #CE9178", + "light_plus": "string: #A31515", + "dark_vs": "string: #CE9178", + "light_vs": "string: #A31515", + "hc_black": "string: #CE9178" + } + }, + { + "c": "%a", + "t": "source.cpp meta.block.c meta.function-call.c string.quoted.double.cpp constant.other.placeholder.c", + "r": { + "dark_plus": "string: #CE9178", + "light_plus": "string: #A31515", + "dark_vs": "string: #CE9178", + "light_vs": "string: #A31515", + "hc_black": "string: #CE9178" + } + }, + { + "c": "x", "t": "source.cpp meta.block.c meta.function-call.c string.quoted.double.cpp", "r": { "dark_plus": "string: #CE9178", -- GitLab From 1913a5cebd98a42aa89c5b54ecd2072daea0bb59 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 11:28:13 +0200 Subject: [PATCH 0051/1347] [css] update grammar --- extensions/css/syntaxes/css.tmLanguage.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/extensions/css/syntaxes/css.tmLanguage.json b/extensions/css/syntaxes/css.tmLanguage.json index 072b9cd3051..700b6dd3140 100644 --- a/extensions/css/syntaxes/css.tmLanguage.json +++ b/extensions/css/syntaxes/css.tmLanguage.json @@ -1328,7 +1328,7 @@ "name": "keyword.other.unit.${2:/downcase}.css" } }, - "match": "(?xi) (? Date: Thu, 25 May 2017 11:28:39 +0200 Subject: [PATCH 0052/1347] [typescript] update grammar --- .../syntaxes/JavaScript.tmLanguage.json | 181 ++++++++++------- .../test/colorize-results/test_jsx.json | 10 +- .../syntaxes/TypeScript.tmLanguage.json | 183 +++++++++++------- .../syntaxes/TypeScriptReact.tmLanguage.json | 181 ++++++++++------- 4 files changed, 330 insertions(+), 225 deletions(-) diff --git a/extensions/javascript/syntaxes/JavaScript.tmLanguage.json b/extensions/javascript/syntaxes/JavaScript.tmLanguage.json index ec077b65656..d7aabe6479b 100644 --- a/extensions/javascript/syntaxes/JavaScript.tmLanguage.json +++ b/extensions/javascript/syntaxes/JavaScript.tmLanguage.json @@ -74,7 +74,7 @@ "name": "storage.type.js" } }, - "end": "(?=$|;|}|(\\s+(of|in)\\s+))", + "end": "(?=$|^|;|}|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#destructuring-variable" @@ -103,7 +103,7 @@ "name": "meta.definition.variable.js entity.name.function.js" } }, - "end": "(?=$|[;,=}]|(\\s+(of|in)\\s+))", + "end": "(?=$|^|[;,=}]|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#var-single-variable-type-annotation" @@ -118,7 +118,7 @@ "name": "meta.definition.variable.js variable.other.constant.js" } }, - "end": "(?=$|[;,=}]|(\\s+(of|in)\\s+))", + "end": "(?=$|^|[;,=}]|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#var-single-variable-type-annotation" @@ -133,7 +133,7 @@ "name": "meta.definition.variable.js variable.other.readwrite.js" } }, - "end": "(?=$|[;,=}]|(\\s+(of|in)\\s+))", + "end": "(?=$|^|[;,=}]|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#var-single-variable-type-annotation" @@ -160,7 +160,7 @@ { "name": "meta.object-binding-pattern-variable.js", "begin": "(?])|(?<=[\\}>\\]\\)]|[_$[:alpha:]])\\s*(?=\\{)", + "end": "(?=$|^|[,);\\}\\]]|//)|(?==[^>])|(?<=[\\}>\\]\\)]|[_$[:alpha:]])\\s*(?=\\{)", "patterns": [ { "include": "#comment" @@ -2019,7 +2062,7 @@ "name": "punctuation.definition.typeparameters.begin.js" } }, - "end": "(?=$)|(>)", + "end": "(>)", "endCaptures": { "1": { "name": "punctuation.definition.typeparameters.end.js" @@ -2054,7 +2097,7 @@ "name": "keyword.operator.assignment.js" } }, - "end": "(?=$|[,);}\\]])", + "end": "(?=$|^|[,);}\\]])", "patterns": [ { "include": "#expression" @@ -2693,7 +2736,7 @@ "name": "keyword.control.as.js" } }, - "end": "(?=$|[;,:})\\]])", + "end": "(?=$|^|[;,:})\\]])", "patterns": [ { "include": "#type" @@ -2778,7 +2821,7 @@ }, { "name": "meta.arrow.js", - "begin": "(?x) (?:\n (? is on new line\n (\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n ) |\n (\n [<]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=>] # < typeparam extends \n ) |\n # arrow function possible to detect only with => on same line\n (\n (<([^<>=]|=[^<]|\\<([^=<>]|=[^<])+\\>)+>\\s*)? # typeparameters\n \\(([^()]|\\([^()]*\\))*\\) # parameteres\n (\\s*:\\s*(.)*)? # return type\n \\s*=> # arrow operator\n )\n )\n)", + "begin": "(?x) (?:\n (? is on new line\n (\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n ) |\n (\n [<]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=>] # < typeparam extends \n ) |\n # arrow function possible to detect only with => on same line\n (\n (<([^<>=]|=[^<]|\\<([^=<>]|=[^<])+\\>)+>\\s*)? # typeparameters\n \\(([^()]|\\([^()]*\\))*\\) # parameteres\n (\\s*:\\s*(.)*)? # return type\n \\s*=> # arrow operator\n )\n )\n)", "beginCaptures": { "1": { "name": "storage.modifier.async.js" @@ -3358,25 +3401,17 @@ } }, { - "begin": "(^[ \\t]+)?(?=//)", + "begin": "(^[ \\t]+)?(//)", "beginCaptures": { "1": { "name": "punctuation.whitespace.comment.leading.js" + }, + "2": { + "name": "comment.line.double-slash.js punctuation.definition.comment.js" } }, - "end": "(?=$)", - "patterns": [ - { - "name": "comment.line.double-slash.js", - "begin": "//", - "beginCaptures": { - "0": { - "name": "punctuation.definition.comment.js" - } - }, - "end": "(?=$)" - } - ] + "end": "(?=^)", + "contentName": "comment.line.double-slash.tsx" } ] }, @@ -3388,7 +3423,7 @@ "name": "punctuation.definition.comment.js" } }, - "end": "(?=$)", + "end": "(?=^)", "patterns": [ { "name": "meta.tag.js", @@ -4188,5 +4223,5 @@ ] } }, - "version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/cb1af7953db224204607cbe22d3a45aa0f77a4c1" + "version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/8c967fe7553297bfad672b7417d78e357c8fe724" } \ No newline at end of file diff --git a/extensions/javascript/test/colorize-results/test_jsx.json b/extensions/javascript/test/colorize-results/test_jsx.json index 7a9eb1f5ca0..55e2c440d3b 100644 --- a/extensions/javascript/test/colorize-results/test_jsx.json +++ b/extensions/javascript/test/colorize-results/test_jsx.json @@ -529,7 +529,7 @@ }, { "c": " Prevent following the link.", - "t": "source.js meta.var.expr.js meta.objectliteral.js meta.object.member.js meta.function.expression.js meta.block.js comment.line.double-slash.js", + "t": "source.js meta.var.expr.js meta.objectliteral.js meta.object.member.js meta.function.expression.js meta.block.js comment.line.double-slash.tsx", "r": { "dark_plus": "comment: #608B4E", "light_plus": "comment: #008000", @@ -628,7 +628,7 @@ }, { "c": " Invert the chosen default.", - "t": "source.js meta.var.expr.js meta.objectliteral.js meta.object.member.js meta.function.expression.js meta.block.js comment.line.double-slash.js", + "t": "source.js meta.var.expr.js meta.objectliteral.js meta.object.member.js meta.function.expression.js meta.block.js comment.line.double-slash.tsx", "r": { "dark_plus": "comment: #608B4E", "light_plus": "comment: #008000", @@ -661,7 +661,7 @@ }, { "c": " This will trigger an intelligent re-render of the component.", - "t": "source.js meta.var.expr.js meta.objectliteral.js meta.object.member.js meta.function.expression.js meta.block.js comment.line.double-slash.js", + "t": "source.js meta.var.expr.js meta.objectliteral.js meta.object.member.js meta.function.expression.js meta.block.js comment.line.double-slash.tsx", "r": { "dark_plus": "comment: #608B4E", "light_plus": "comment: #008000", @@ -1046,7 +1046,7 @@ }, { "c": " Default to the default message.", - "t": "source.js meta.var.expr.js meta.objectliteral.js meta.object.member.js meta.function.expression.js meta.block.js comment.line.double-slash.js", + "t": "source.js meta.var.expr.js meta.objectliteral.js meta.object.member.js meta.function.expression.js meta.block.js comment.line.double-slash.tsx", "r": { "dark_plus": "comment: #608B4E", "light_plus": "comment: #008000", @@ -1222,7 +1222,7 @@ }, { "c": " If toggled, show the alternate message.", - "t": "source.js meta.var.expr.js meta.objectliteral.js meta.object.member.js meta.function.expression.js meta.block.js comment.line.double-slash.js", + "t": "source.js meta.var.expr.js meta.objectliteral.js meta.object.member.js meta.function.expression.js meta.block.js comment.line.double-slash.tsx", "r": { "dark_plus": "comment: #608B4E", "light_plus": "comment: #008000", diff --git a/extensions/typescript/syntaxes/TypeScript.tmLanguage.json b/extensions/typescript/syntaxes/TypeScript.tmLanguage.json index b80d24f1c23..7c581f92aea 100644 --- a/extensions/typescript/syntaxes/TypeScript.tmLanguage.json +++ b/extensions/typescript/syntaxes/TypeScript.tmLanguage.json @@ -71,7 +71,7 @@ "name": "storage.type.ts" } }, - "end": "(?=$|;|}|(\\s+(of|in)\\s+))", + "end": "(?=$|^|;|}|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#destructuring-variable" @@ -100,7 +100,7 @@ "name": "meta.definition.variable.ts entity.name.function.ts" } }, - "end": "(?=$|[;,=}]|(\\s+(of|in)\\s+))", + "end": "(?=$|^|[;,=}]|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#var-single-variable-type-annotation" @@ -115,7 +115,7 @@ "name": "meta.definition.variable.ts variable.other.constant.ts" } }, - "end": "(?=$|[;,=}]|(\\s+(of|in)\\s+))", + "end": "(?=$|^|[;,=}]|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#var-single-variable-type-annotation" @@ -130,7 +130,7 @@ "name": "meta.definition.variable.ts variable.other.readwrite.ts" } }, - "end": "(?=$|[;,=}]|(\\s+(of|in)\\s+))", + "end": "(?=$|^|[;,=}]|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#var-single-variable-type-annotation" @@ -157,7 +157,7 @@ { "name": "meta.object-binding-pattern-variable.ts", "begin": "(?])|(?<=[\\}>\\]\\)]|[_$[:alpha:]])\\s*(?=\\{)", + "end": "(?=$|^|[,);\\}\\]]|//)|(?==[^>])|(?<=[\\}>\\]\\)]|[_$[:alpha:]])\\s*(?=\\{)", "patterns": [ { "include": "#comment" @@ -2013,7 +2056,7 @@ "name": "punctuation.definition.typeparameters.begin.ts" } }, - "end": "(?=$)|(>)", + "end": "(>)", "endCaptures": { "1": { "name": "punctuation.definition.typeparameters.end.ts" @@ -2048,7 +2091,7 @@ "name": "keyword.operator.assignment.ts" } }, - "end": "(?=$|[,);}\\]])", + "end": "(?=$|^|[,);}\\]])", "patterns": [ { "include": "#expression" @@ -2487,7 +2530,7 @@ "patterns": [ { "name": "cast.expr.ts", - "begin": "(?:(?<=return|throw|yield|await|default|[=(,:>*]))\\s*(<)(?!*?]))\\s*(<)(?! is on new line\n (\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n ) |\n (\n [<]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=>] # < typeparam extends \n ) |\n # arrow function possible to detect only with => on same line\n (\n (<([^<>=]|=[^<]|\\<([^=<>]|=[^<])+\\>)+>\\s*)? # typeparameters\n \\(([^()]|\\([^()]*\\))*\\) # parameteres\n (\\s*:\\s*(.)*)? # return type\n \\s*=> # arrow operator\n )\n )\n)", + "begin": "(?x) (?:\n (? is on new line\n (\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n ) |\n (\n [<]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=>] # < typeparam extends \n ) |\n # arrow function possible to detect only with => on same line\n (\n (<([^<>=]|=[^<]|\\<([^=<>]|=[^<])+\\>)+>\\s*)? # typeparameters\n \\(([^()]|\\([^()]*\\))*\\) # parameteres\n (\\s*:\\s*(.)*)? # return type\n \\s*=> # arrow operator\n )\n )\n)", "beginCaptures": { "1": { "name": "storage.modifier.async.ts" @@ -3389,25 +3432,17 @@ } }, { - "begin": "(^[ \\t]+)?(?=//)", + "begin": "(^[ \\t]+)?(//)", "beginCaptures": { "1": { "name": "punctuation.whitespace.comment.leading.ts" + }, + "2": { + "name": "comment.line.double-slash.ts punctuation.definition.comment.ts" } }, - "end": "(?=$)", - "patterns": [ - { - "name": "comment.line.double-slash.ts", - "begin": "//", - "beginCaptures": { - "0": { - "name": "punctuation.definition.comment.ts" - } - }, - "end": "(?=$)" - } - ] + "end": "(?=^)", + "contentName": "comment.line.double-slash.ts" } ] }, @@ -3419,7 +3454,7 @@ "name": "punctuation.definition.comment.ts" } }, - "end": "(?=$)", + "end": "(?=^)", "patterns": [ { "name": "meta.tag.ts", @@ -3923,5 +3958,5 @@ ] } }, - "version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/9f6676aa2ddb75cb5a9dbe1f59024069e839d986" + "version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/8c967fe7553297bfad672b7417d78e357c8fe724" } \ No newline at end of file diff --git a/extensions/typescript/syntaxes/TypeScriptReact.tmLanguage.json b/extensions/typescript/syntaxes/TypeScriptReact.tmLanguage.json index c20889881a1..b2c49cbf7f4 100644 --- a/extensions/typescript/syntaxes/TypeScriptReact.tmLanguage.json +++ b/extensions/typescript/syntaxes/TypeScriptReact.tmLanguage.json @@ -71,7 +71,7 @@ "name": "storage.type.tsx" } }, - "end": "(?=$|;|}|(\\s+(of|in)\\s+))", + "end": "(?=$|^|;|}|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#destructuring-variable" @@ -100,7 +100,7 @@ "name": "meta.definition.variable.tsx entity.name.function.tsx" } }, - "end": "(?=$|[;,=}]|(\\s+(of|in)\\s+))", + "end": "(?=$|^|[;,=}]|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#var-single-variable-type-annotation" @@ -115,7 +115,7 @@ "name": "meta.definition.variable.tsx variable.other.constant.tsx" } }, - "end": "(?=$|[;,=}]|(\\s+(of|in)\\s+))", + "end": "(?=$|^|[;,=}]|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#var-single-variable-type-annotation" @@ -130,7 +130,7 @@ "name": "meta.definition.variable.tsx variable.other.readwrite.tsx" } }, - "end": "(?=$|[;,=}]|(\\s+(of|in)\\s+))", + "end": "(?=$|^|[;,=}]|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#var-single-variable-type-annotation" @@ -157,7 +157,7 @@ { "name": "meta.object-binding-pattern-variable.tsx", "begin": "(?])|(?<=[\\}>\\]\\)]|[_$[:alpha:]])\\s*(?=\\{)", + "end": "(?=$|^|[,);\\}\\]]|//)|(?==[^>])|(?<=[\\}>\\]\\)]|[_$[:alpha:]])\\s*(?=\\{)", "patterns": [ { "include": "#comment" @@ -2016,7 +2059,7 @@ "name": "punctuation.definition.typeparameters.begin.tsx" } }, - "end": "(?=$)|(>)", + "end": "(>)", "endCaptures": { "1": { "name": "punctuation.definition.typeparameters.end.tsx" @@ -2051,7 +2094,7 @@ "name": "keyword.operator.assignment.tsx" } }, - "end": "(?=$|[,);}\\]])", + "end": "(?=$|^|[,);}\\]])", "patterns": [ { "include": "#expression" @@ -2690,7 +2733,7 @@ "name": "keyword.control.as.tsx" } }, - "end": "(?=$|[;,:})\\]])", + "end": "(?=$|^|[;,:})\\]])", "patterns": [ { "include": "#type" @@ -2775,7 +2818,7 @@ }, { "name": "meta.arrow.tsx", - "begin": "(?x) (?:\n (? is on new line\n (\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n ) |\n (\n [<]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=>] # < typeparam extends \n ) |\n # arrow function possible to detect only with => on same line\n (\n (<([^<>=]|=[^<]|\\<([^=<>]|=[^<])+\\>)+>\\s*)? # typeparameters\n \\(([^()]|\\([^()]*\\))*\\) # parameteres\n (\\s*:\\s*(.)*)? # return type\n \\s*=> # arrow operator\n )\n )\n)", + "begin": "(?x) (?:\n (? is on new line\n (\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n ) |\n (\n [<]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=>] # < typeparam extends \n ) |\n # arrow function possible to detect only with => on same line\n (\n (<([^<>=]|=[^<]|\\<([^=<>]|=[^<])+\\>)+>\\s*)? # typeparameters\n \\(([^()]|\\([^()]*\\))*\\) # parameteres\n (\\s*:\\s*(.)*)? # return type\n \\s*=> # arrow operator\n )\n )\n)", "beginCaptures": { "1": { "name": "storage.modifier.async.tsx" @@ -3355,25 +3398,17 @@ } }, { - "begin": "(^[ \\t]+)?(?=//)", + "begin": "(^[ \\t]+)?(//)", "beginCaptures": { "1": { "name": "punctuation.whitespace.comment.leading.tsx" + }, + "2": { + "name": "comment.line.double-slash.tsx punctuation.definition.comment.tsx" } }, - "end": "(?=$)", - "patterns": [ - { - "name": "comment.line.double-slash.tsx", - "begin": "//", - "beginCaptures": { - "0": { - "name": "punctuation.definition.comment.tsx" - } - }, - "end": "(?=$)" - } - ] + "end": "(?=^)", + "contentName": "comment.line.double-slash.tsx" } ] }, @@ -3385,7 +3420,7 @@ "name": "punctuation.definition.comment.tsx" } }, - "end": "(?=$)", + "end": "(?=^)", "patterns": [ { "name": "meta.tag.tsx", @@ -4185,5 +4220,5 @@ ] } }, - "version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/cb1af7953db224204607cbe22d3a45aa0f77a4c1" + "version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/8c967fe7553297bfad672b7417d78e357c8fe724" } \ No newline at end of file -- GitLab From 422ff199cadcb99a60790dc64ce0d64a44090197 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 11:28:58 +0200 Subject: [PATCH 0053/1347] [less] update grammar --- extensions/less/syntaxes/less.tmLanguage.json | 17 +- .../test/colorize-results/14119_less.json | 13 +- .../test-cssvariables_less.json | 28 +- .../less/test/colorize-results/test_less.json | 280 ++++++++++++++++-- 4 files changed, 293 insertions(+), 45 deletions(-) diff --git a/extensions/less/syntaxes/less.tmLanguage.json b/extensions/less/syntaxes/less.tmLanguage.json index 902eb4e8d01..cd25b2a89b5 100644 --- a/extensions/less/syntaxes/less.tmLanguage.json +++ b/extensions/less/syntaxes/less.tmLanguage.json @@ -146,12 +146,7 @@ "name": "comment.block.css" }, { - "match": "[+-]?\\d*\\.?\\d+", - "name": "constant.numeric.css" - }, - { - "match": "(?<=[\\d])(ch|cm|deg|dpi|dpcm|dppx|em|ex|grad|in|mm|ms|pc|pt|px|rad|rem|turn|s|vh|vmin|vw)\\b|%", - "name": "keyword.other.unit.css" + "include": "source.css#numeric-values" }, { "captures": { @@ -281,13 +276,13 @@ ] }, { + "match": "(@|\\-\\-)[\\w-]+(?=\\s*)", + "name": "variable.other.less", "captures": { "1": { "name": "punctuation.definition.variable.less" } - }, - "match": "(?:@|\\-\\-)[a-zA-Z0-9_-][\\w-]*(?=\\s*)", - "name": "variable.other.less" + } }, { "include": "#variable_interpolation" @@ -516,7 +511,7 @@ "include": "#strings" }, { - "match": "(\\b|\\.{0,2}/).*\\b", + "match": "(\\b|\\.{0,2}/)[^)]*\\b", "name": "string.url.css" } ] @@ -546,5 +541,5 @@ "name": "support.function.any-method.builtin.less" } }, - "version": "https://github.com/atom/language-less/commit/7d70b66aa9c853d59e27cce25b5bc25cb067e75a" + "version": "https://github.com/atom/language-less/commit/4661d870784f725599e438bf683553cc6cf0f4ed" } \ No newline at end of file diff --git a/extensions/less/test/colorize-results/14119_less.json b/extensions/less/test/colorize-results/14119_less.json index 6e89b6a4587..0c83af45331 100644 --- a/extensions/less/test/colorize-results/14119_less.json +++ b/extensions/less/test/colorize-results/14119_less.json @@ -33,7 +33,18 @@ } }, { - "c": "@hm", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "hm", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", diff --git a/extensions/less/test/colorize-results/test-cssvariables_less.json b/extensions/less/test/colorize-results/test-cssvariables_less.json index bca9cd3c3a9..1c9b8658a0a 100644 --- a/extensions/less/test/colorize-results/test-cssvariables_less.json +++ b/extensions/less/test/colorize-results/test-cssvariables_less.json @@ -55,7 +55,18 @@ } }, { - "c": "--spacing-unit", + "c": "--", + "t": "source.css.less meta.property-list.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "spacing-unit", "t": "source.css.less meta.property-list.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -100,7 +111,7 @@ }, { "c": "px", - "t": "source.css.less meta.property-list.css meta.property-value.css keyword.other.unit.css", + "t": "source.css.less meta.property-list.css meta.property-value.css constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -132,7 +143,18 @@ } }, { - "c": "--cell-padding", + "c": "--", + "t": "source.css.less meta.property-list.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "cell-padding", "t": "source.css.less meta.property-list.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", diff --git a/extensions/less/test/colorize-results/test_less.json b/extensions/less/test/colorize-results/test_less.json index 4cc47220238..d6b39257feb 100644 --- a/extensions/less/test/colorize-results/test_less.json +++ b/extensions/less/test/colorize-results/test_less.json @@ -308,7 +308,18 @@ } }, { - "c": "@base", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "base", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -385,7 +396,18 @@ } }, { - "c": "@style", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "style", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -418,7 +440,18 @@ } }, { - "c": "@c", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "c", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -506,7 +539,18 @@ } }, { - "c": "@c", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "c", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -594,7 +638,18 @@ } }, { - "c": "@style", + "c": "@", + "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "style", "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -616,7 +671,18 @@ } }, { - "c": "@c", + "c": "@", + "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "c", "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -671,7 +737,18 @@ } }, { - "c": "@style", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "style", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -704,7 +781,18 @@ } }, { - "c": "@alpha", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "alpha", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -749,7 +837,7 @@ }, { "c": "%", - "t": "source.css.less keyword.other.unit.css", + "t": "source.css.less constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -836,7 +924,18 @@ } }, { - "c": "@alpha", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "alpha", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -913,7 +1012,18 @@ } }, { - "c": "@style", + "c": "@", + "t": "source.css.less meta.property-list.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "style", "t": "source.css.less meta.property-list.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -1232,7 +1342,18 @@ } }, { - "c": "@base", + "c": "@", + "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "base", "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -1277,7 +1398,7 @@ }, { "c": "%", - "t": "source.css.less meta.property-list.css meta.property-value.css keyword.other.unit.css", + "t": "source.css.less meta.property-list.css meta.property-value.css constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -1375,7 +1496,18 @@ } }, { - "c": "@base", + "c": "@", + "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "base", "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -1420,7 +1552,7 @@ }, { "c": "%", - "t": "source.css.less meta.property-list.css meta.property-value.css keyword.other.unit.css", + "t": "source.css.less meta.property-list.css meta.property-value.css constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -1585,7 +1717,7 @@ }, { "c": "px", - "t": "source.css.less meta.property-list.css meta.property-list.css keyword.other.unit.css", + "t": "source.css.less meta.property-list.css meta.property-list.css constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -1640,7 +1772,7 @@ }, { "c": "%", - "t": "source.css.less meta.property-list.css meta.property-list.css keyword.other.unit.css", + "t": "source.css.less meta.property-list.css meta.property-list.css constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -1849,7 +1981,7 @@ }, { "c": "px", - "t": "source.css.less meta.property-list.css meta.property-list.css meta.property-value.css keyword.other.unit.css", + "t": "source.css.less meta.property-list.css meta.property-list.css meta.property-value.css constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -2058,7 +2190,7 @@ }, { "c": "px", - "t": "source.css.less meta.property-list.css meta.property-list.css meta.property-value.css keyword.other.unit.css", + "t": "source.css.less meta.property-list.css meta.property-list.css meta.property-value.css constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -2311,7 +2443,7 @@ }, { "c": "px", - "t": "source.css.less meta.property-list.css meta.property-list.css meta.property-list.css meta.property-list.css meta.property-value.css keyword.other.unit.css", + "t": "source.css.less meta.property-list.css meta.property-list.css meta.property-list.css meta.property-list.css meta.property-value.css constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -2398,7 +2530,18 @@ } }, { - "c": "@the-border", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "the-border", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -2443,7 +2586,7 @@ }, { "c": "px", - "t": "source.css.less keyword.other.unit.css", + "t": "source.css.less constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -2464,7 +2607,18 @@ } }, { - "c": "@base-color", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "base-color", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -2519,7 +2673,18 @@ } }, { - "c": "@red", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "red", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -2673,7 +2838,18 @@ } }, { - "c": "@base-color", + "c": "@", + "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "base-color", "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -2794,7 +2970,18 @@ } }, { - "c": "@the-border", + "c": "@", + "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "the-border", "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -2871,7 +3058,18 @@ } }, { - "c": "@the-border", + "c": "@", + "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "the-border", "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -3058,7 +3256,18 @@ } }, { - "c": "@base-color", + "c": "@", + "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "base-color", "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -3201,7 +3410,18 @@ } }, { - "c": "@red", + "c": "@", + "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "red", "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -3246,7 +3466,7 @@ }, { "c": "%", - "t": "source.css.less meta.property-list.css meta.property-value.css keyword.other.unit.css", + "t": "source.css.less meta.property-list.css meta.property-value.css constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", -- GitLab From 567bbbc6add42129df944ba91feac01a86860b54 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 11:29:12 +0200 Subject: [PATCH 0054/1347] [php] update grammar --- extensions/php/syntaxes/php.tmLanguage.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/extensions/php/syntaxes/php.tmLanguage.json b/extensions/php/syntaxes/php.tmLanguage.json index d7e3a548ade..8e69579120b 100644 --- a/extensions/php/syntaxes/php.tmLanguage.json +++ b/extensions/php/syntaxes/php.tmLanguage.json @@ -2071,7 +2071,7 @@ "patterns": [ { "comment": "PHPDocumentor only recognises lines with an asterisk as the first non-whitespaces character", - "match": "^(?!\\s*\\*).*$\\n?", + "match": "^(?!\\s*\\*).*?(?:(?=\\*\\/)|$\\n?)", "name": "invalid.illegal.missing-asterisk.phpdoc.php" }, { @@ -2975,5 +2975,5 @@ ] } }, - "version": "https://github.com/atom/language-php/commit/22047c19f52f686de471d0deccae0cb1332997b6" + "version": "https://github.com/atom/language-php/commit/c523a19f849b97f6499eae6accf80564aa190c0e" } \ No newline at end of file -- GitLab From 6f274872ac46a58606eff6a646a98bf91cff6b82 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 12:26:41 +0200 Subject: [PATCH 0055/1347] Add information_for_contributors to grammars --- build/npm/update-all-grammars.js | 1 - build/npm/update-grammar.js | 16 ++++++++++++++-- .../clojure/syntaxes/clojure.tmLanguage.json | 8 ++++++-- .../syntaxes/coffeescript.tmLanguage.json | 8 ++++++-- extensions/cpp/syntaxes/c++.json | 8 ++++++-- extensions/cpp/syntaxes/c.json | 8 ++++++-- .../csharp/syntaxes/csharp.tmLanguage.json | 8 ++++++-- extensions/css/syntaxes/css.tmLanguage.json | 8 ++++++-- extensions/diff/syntaxes/diff.tmLanguage.json | 8 ++++++-- .../docker/syntaxes/docker.tmLanguage.json | 8 ++++++-- extensions/fsharp/syntaxes/fsharp.json | 8 ++++++-- .../syntaxes/git-commit.tmLanguage.json | 8 ++++++-- .../syntaxes/git-rebase.tmLanguage.json | 8 ++++++-- extensions/go/syntaxes/go.json | 8 ++++++-- .../groovy/syntaxes/groovy.tmLanguage.json | 8 ++++++-- .../syntaxes/Handlebars.tmLanguage.json | 8 ++++++-- extensions/hlsl/syntaxes/hlsl.json | 8 ++++++-- extensions/html/syntaxes/html.json | 8 ++++++-- extensions/ini/syntaxes/ini.tmLanguage.json | 8 ++++++-- extensions/java/syntaxes/java.tmLanguage.json | 8 ++++++-- .../syntaxes/JavaScript.tmLanguage.json | 8 ++++++-- extensions/less/syntaxes/less.tmLanguage.json | 8 ++++++-- extensions/lua/syntaxes/lua.json | 8 ++++++-- extensions/make/syntaxes/Makefile.json | 8 ++++++-- .../syntaxes/objective-c++.tmLanguage.json | 5 +++++ .../syntaxes/objective-c.tmLanguage.json | 8 ++++++-- extensions/perl/syntaxes/perl.tmLanguage.json | 8 ++++++-- extensions/perl/syntaxes/perl6.tmLanguage.json | 8 ++++++-- extensions/php/syntaxes/php.tmLanguage.json | 8 ++++++-- extensions/pug/syntaxes/pug.tmLanguage.json | 8 ++++++-- .../python/syntaxes/MagicPython.tmLanguage.json | 8 ++++++-- .../python/syntaxes/MagicRegExp.tmLanguage.json | 8 ++++++-- extensions/r/syntaxes/r.tmLanguage.json | 8 ++++++-- extensions/razor/syntaxes/cshtml.json | 8 ++++++-- extensions/ruby/syntaxes/ruby.tmLanguage.json | 8 ++++++-- extensions/rust/syntaxes/rust.tmLanguage.json | 8 ++++++-- extensions/scss/syntaxes/scss.json | 8 ++++++-- extensions/shaderlab/syntaxes/shaderlab.json | 8 ++++++-- .../syntaxes/Shell-Unix-Bash.tmLanguage.json | 8 ++++++-- extensions/swift/syntaxes/swift.tmLanguage.json | 8 ++++++-- .../syntaxes/TypeScript.tmLanguage.json | 8 ++++++-- .../syntaxes/TypeScriptReact.tmLanguage.json | 8 ++++++-- .../vb/syntaxes/asp-vb-net.tmlanguage.json | 8 ++++++-- extensions/xml/syntaxes/xml.json | 8 ++++++-- extensions/xml/syntaxes/xsl.json | 8 ++++++-- extensions/yaml/syntaxes/yaml.json | 8 ++++++-- 46 files changed, 277 insertions(+), 89 deletions(-) diff --git a/build/npm/update-all-grammars.js b/build/npm/update-all-grammars.js index 252b0f4edcb..88b890af730 100644 --- a/build/npm/update-all-grammars.js +++ b/build/npm/update-all-grammars.js @@ -5,7 +5,6 @@ const cp = require('child_process'); const npm = process.platform === 'win32' ? 'npm.cmd' : 'npm'; -const integrationTests = process.platform === 'win32' ? '.\test-integration.bat' : './test-integration.sh'; function updateGrammar(location) { const result = cp.spawnSync(npm, ['run', 'update-grammar'], { diff --git a/build/npm/update-grammar.js b/build/npm/update-grammar.js index dbb12cdcb44..fca60d83242 100644 --- a/build/npm/update-grammar.js +++ b/build/npm/update-grammar.js @@ -88,11 +88,23 @@ exports.update = function (repoId, repoPath, dest, modifyGrammar) { modifyGrammar(grammar); } return getCommitSha(repoId, repoPath).then(function (info) { + let result = { + information_for_contributors: [ + 'This file has been converted from https://github.com/' + repoId + '/blob/master/' + repoPath, + 'If you want to provide a fix or improvement, please create a pull request against the original repository.', + 'Once accepted there, we are happy to receive an update request.' + ] + }; + if (info) { - grammar.version = 'https://github.com/' + repoId + '/commit/' + info.commitSha; + result.version = 'https://github.com/' + repoId + '/commit/' + info.commitSha; + } + for (let key in grammar) { + result[key] = grammar[key]; } + try { - fs.writeFileSync(dest, JSON.stringify(grammar, null, '\t')); + fs.writeFileSync(dest, JSON.stringify(result, null, '\t')); if (info) { console.log('Updated ' + path.basename(dest) + ' to ' + repoId + '@' + info.commitSha.substr(0, 7) + ' (' + info.commitDate.substr(0, 10) + ')'); } else { diff --git a/extensions/clojure/syntaxes/clojure.tmLanguage.json b/extensions/clojure/syntaxes/clojure.tmLanguage.json index 881ce191e1c..437a0c5b5e1 100644 --- a/extensions/clojure/syntaxes/clojure.tmLanguage.json +++ b/extensions/clojure/syntaxes/clojure.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-clojure/blob/master/grammars/clojure.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "source.clojure", "fileTypes": [ "boot", @@ -440,6 +445,5 @@ } ] } - }, - "version": "https://github.com/atom/language-clojure/commit/70e83b27444da31d6367a0aa447a216836eafc05" + } } \ No newline at end of file diff --git a/extensions/coffeescript/syntaxes/coffeescript.tmLanguage.json b/extensions/coffeescript/syntaxes/coffeescript.tmLanguage.json index d7c22867d76..dae1d795f45 100644 --- a/extensions/coffeescript/syntaxes/coffeescript.tmLanguage.json +++ b/extensions/coffeescript/syntaxes/coffeescript.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-coffee-script/blob/master/grammars/coffeescript.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "source.coffee", "name": "CoffeeScript", "fileTypes": [ @@ -686,6 +691,5 @@ } ] } - }, - "version": "https://github.com/atom/language-coffee-script/commit/49c117b24096a369f92dfce180b61bd1f0425a29" + } } \ No newline at end of file diff --git a/extensions/cpp/syntaxes/c++.json b/extensions/cpp/syntaxes/c++.json index 7ec3054f58b..bc627e3a036 100644 --- a/extensions/cpp/syntaxes/c++.json +++ b/extensions/cpp/syntaxes/c++.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-c/blob/master/grammars/c%2B%2B.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "source.cpp", "fileTypes": [ "cc", @@ -457,6 +462,5 @@ } ] } - }, - "version": "https://github.com/atom/language-c/commit/3a269f88b12e512fb9495dc006a1dabf325d3d7f" + } } \ No newline at end of file diff --git a/extensions/cpp/syntaxes/c.json b/extensions/cpp/syntaxes/c.json index 6cc84cff24d..022f588cf28 100644 --- a/extensions/cpp/syntaxes/c.json +++ b/extensions/cpp/syntaxes/c.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-c/blob/master/grammars/c.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "source.c", "fileTypes": [ "c", @@ -1950,6 +1955,5 @@ } ] } - }, - "version": "https://github.com/atom/language-c/commit/1d137279178d06e7f7500800ebc36155e130172e" + } } \ No newline at end of file diff --git a/extensions/csharp/syntaxes/csharp.tmLanguage.json b/extensions/csharp/syntaxes/csharp.tmLanguage.json index eae75041576..3f81563c5bb 100644 --- a/extensions/csharp/syntaxes/csharp.tmLanguage.json +++ b/extensions/csharp/syntaxes/csharp.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/dotnet/csharp-tmLanguage/blob/master/grammars/csharp.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "name": "C#", "scopeName": "source.cs", "fileTypes": [ @@ -4186,6 +4191,5 @@ } } } - }, - "version": "https://github.com/dotnet/csharp-tmLanguage/commit/4d0e50c51f336645c98689737db1be321d212d3d" + } } \ No newline at end of file diff --git a/extensions/css/syntaxes/css.tmLanguage.json b/extensions/css/syntaxes/css.tmLanguage.json index 700b6dd3140..dae4475161a 100644 --- a/extensions/css/syntaxes/css.tmLanguage.json +++ b/extensions/css/syntaxes/css.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-css/blob/master/grammars/css.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "source.css", "name": "CSS", "fileTypes": [ @@ -1796,6 +1801,5 @@ } ] } - }, - "version": "https://github.com/atom/language-css/commit/23dcdee3372050eb3f07374fbe9188884bd545d1" + } } \ No newline at end of file diff --git a/extensions/diff/syntaxes/diff.tmLanguage.json b/extensions/diff/syntaxes/diff.tmLanguage.json index ac16f416a64..e259c46be42 100644 --- a/extensions/diff/syntaxes/diff.tmLanguage.json +++ b/extensions/diff/syntaxes/diff.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/diff.tmbundle/blob/master/Syntaxes/Diff.plist", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "patch", "diff", @@ -158,6 +163,5 @@ } ], "scopeName": "source.diff", - "uuid": "7E848FF4-708E-11D9-97B4-0011242E4184", - "version": "https://github.com/textmate/diff.tmbundle/commit/0593bb775eab1824af97ef2172fd38822abd97d7" + "uuid": "7E848FF4-708E-11D9-97B4-0011242E4184" } \ No newline at end of file diff --git a/extensions/docker/syntaxes/docker.tmLanguage.json b/extensions/docker/syntaxes/docker.tmLanguage.json index 8be1c94055d..d8c2d0fd766 100644 --- a/extensions/docker/syntaxes/docker.tmLanguage.json +++ b/extensions/docker/syntaxes/docker.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/moby/moby/blob/master/contrib/syntax/textmate/Docker.tmbundle/Syntaxes/Dockerfile.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "Dockerfile" ], @@ -96,6 +101,5 @@ } ], "scopeName": "source.dockerfile", - "uuid": "a39d8795-59d2-49af-aa00-fe74ee29576e", - "version": "https://github.com/moby/moby/commit/8523e9d108a0e98865673701a7bd0a7929c5260b" + "uuid": "a39d8795-59d2-49af-aa00-fe74ee29576e" } \ No newline at end of file diff --git a/extensions/fsharp/syntaxes/fsharp.json b/extensions/fsharp/syntaxes/fsharp.json index 7ef61094dd1..f7abe7e8a52 100644 --- a/extensions/fsharp/syntaxes/fsharp.json +++ b/extensions/fsharp/syntaxes/fsharp.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/ionide/ionide-fsgrammar/blob/master/grammar/fsharp.json", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "name": "fsharp", "scopeName": "source.fsharp", "fileTypes": [ @@ -456,6 +461,5 @@ } ] } - }, - "version": "https://github.com/ionide/ionide-fsgrammar/commit/f2e3c30f0ebfcc89fb78ad908701159f20516812" + } } \ No newline at end of file diff --git a/extensions/gitsyntax/syntaxes/git-commit.tmLanguage.json b/extensions/gitsyntax/syntaxes/git-commit.tmLanguage.json index 5f5db8762fa..ffe1561f727 100644 --- a/extensions/gitsyntax/syntaxes/git-commit.tmLanguage.json +++ b/extensions/gitsyntax/syntaxes/git-commit.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/git.tmbundle/blob/master/Syntaxes/Git%20Commit%20Message.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "COMMIT_EDITMSG", "MERGE_MSG" @@ -138,6 +143,5 @@ } }, "scopeName": "text.git-commit", - "uuid": "BFE83C06-8508-44BE-A975-95A57BF619A7", - "version": "https://github.com/textmate/git.tmbundle/commit/93897a78c6e52bef13dadc0d4091d203c5facb40" + "uuid": "BFE83C06-8508-44BE-A975-95A57BF619A7" } \ No newline at end of file diff --git a/extensions/gitsyntax/syntaxes/git-rebase.tmLanguage.json b/extensions/gitsyntax/syntaxes/git-rebase.tmLanguage.json index c8bf731d9cb..15bac0d8d09 100644 --- a/extensions/gitsyntax/syntaxes/git-rebase.tmLanguage.json +++ b/extensions/gitsyntax/syntaxes/git-rebase.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/git.tmbundle/blob/master/Syntaxes/Git%20Rebase%20Message.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "git-rebase-todo" ], @@ -30,6 +35,5 @@ } ], "scopeName": "text.git-rebase", - "uuid": "7F1CC209-5F6D-486A-8180-09FA282381A1", - "version": "https://github.com/textmate/git.tmbundle/commit/d1db42c2d71948662098183a6df519fb53a7a15b" + "uuid": "7F1CC209-5F6D-486A-8180-09FA282381A1" } \ No newline at end of file diff --git a/extensions/go/syntaxes/go.json b/extensions/go/syntaxes/go.json index 53908a80bac..098c8710482 100644 --- a/extensions/go/syntaxes/go.json +++ b/extensions/go/syntaxes/go.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-go/blob/master/grammars/go.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "source.go", "name": "Go", "comment": "Go language", @@ -624,6 +629,5 @@ } ] } - }, - "version": "https://github.com/atom/language-go/commit/c1fe618ccf2dcd17118c5600c49b1c539f26d5c5" + } } \ No newline at end of file diff --git a/extensions/groovy/syntaxes/groovy.tmLanguage.json b/extensions/groovy/syntaxes/groovy.tmLanguage.json index 8850454840e..3dc8af7d0a1 100644 --- a/extensions/groovy/syntaxes/groovy.tmLanguage.json +++ b/extensions/groovy/syntaxes/groovy.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/groovy.tmbundle/blob/master/Syntaxes/Groovy.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "groovy", "gvy" @@ -1381,6 +1386,5 @@ } }, "scopeName": "source.groovy", - "uuid": "B3A64888-EBBB-4436-8D9E-F1169C5D7613", - "version": "https://github.com/textmate/groovy.tmbundle/commit/85d8f7c97ae473ccb9473f6c8d27e4ec957f4be1" + "uuid": "B3A64888-EBBB-4436-8D9E-F1169C5D7613" } \ No newline at end of file diff --git a/extensions/handlebars/syntaxes/Handlebars.tmLanguage.json b/extensions/handlebars/syntaxes/Handlebars.tmLanguage.json index 9e3579d90c2..e915b691d7f 100644 --- a/extensions/handlebars/syntaxes/Handlebars.tmLanguage.json +++ b/extensions/handlebars/syntaxes/Handlebars.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/daaain/Handlebars/blob/master/grammars/Handlebars.json", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "name": "Handlebars", "repository": { "html_tags": { @@ -849,6 +854,5 @@ "template", "tmpl" ], - "uuid": "70E91676-DE0A-4266-A2B9-3AD2E535E484", - "version": "https://github.com/daaain/Handlebars/commit/4e8244410815da73f93375532939d48bd5a9bb93" + "uuid": "70E91676-DE0A-4266-A2B9-3AD2E535E484" } \ No newline at end of file diff --git a/extensions/hlsl/syntaxes/hlsl.json b/extensions/hlsl/syntaxes/hlsl.json index 91dcf2b2520..20565922c53 100644 --- a/extensions/hlsl/syntaxes/hlsl.json +++ b/extensions/hlsl/syntaxes/hlsl.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/tgjones/shaders-tmLanguage/blob/master/grammars/hlsl.json", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "source.hlsl", "name": "HLSL", "fileTypes": [ @@ -213,6 +218,5 @@ } ] } - ], - "version": "https://github.com/tgjones/shaders-tmLanguage/commit/cd1ef40f549f9ce2b9e6b73498688de114a85382" + ] } \ No newline at end of file diff --git a/extensions/html/syntaxes/html.json b/extensions/html/syntaxes/html.json index cc2d9fd17ea..4192c824703 100644 --- a/extensions/html/syntaxes/html.json +++ b/extensions/html/syntaxes/html.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/html.tmbundle/blob/master/Syntaxes/HTML.plist", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "html", "htm", @@ -742,6 +747,5 @@ } }, "scopeName": "text.html.basic", - "uuid": "17994EC8-6B1D-11D9-AC3A-000D93589AF6", - "version": "https://github.com/textmate/html.tmbundle/commit/a723f08ebd49c67c22aca08dd8f17d0bf836ec93" + "uuid": "17994EC8-6B1D-11D9-AC3A-000D93589AF6" } \ No newline at end of file diff --git a/extensions/ini/syntaxes/ini.tmLanguage.json b/extensions/ini/syntaxes/ini.tmLanguage.json index e8f1a0ef9b3..34679c1bee0 100644 --- a/extensions/ini/syntaxes/ini.tmLanguage.json +++ b/extensions/ini/syntaxes/ini.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/ini.tmbundle/blob/master/Syntaxes/Ini.plist", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "ini", "conf" @@ -109,6 +114,5 @@ } ], "scopeName": "source.ini", - "uuid": "77DC23B6-8A90-11D9-BAA4-000A9584EC8C", - "version": "https://github.com/textmate/ini.tmbundle/commit/2af0cbb0704940f967152616f2f1ff0aae6287a6" + "uuid": "77DC23B6-8A90-11D9-BAA4-000A9584EC8C" } \ No newline at end of file diff --git a/extensions/java/syntaxes/java.tmLanguage.json b/extensions/java/syntaxes/java.tmLanguage.json index 5d0513d49b0..654bf8e2ba8 100644 --- a/extensions/java/syntaxes/java.tmLanguage.json +++ b/extensions/java/syntaxes/java.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-java/blob/master/grammars/java.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "source.java", "name": "Java", "fileTypes": [ @@ -1360,6 +1365,5 @@ } ] } - }, - "version": "https://github.com/atom/language-java/commit/0e0ec7966059e3e363868311b3d855014bca95dd" + } } \ No newline at end of file diff --git a/extensions/javascript/syntaxes/JavaScript.tmLanguage.json b/extensions/javascript/syntaxes/JavaScript.tmLanguage.json index d7aabe6479b..8856e46770c 100644 --- a/extensions/javascript/syntaxes/JavaScript.tmLanguage.json +++ b/extensions/javascript/syntaxes/JavaScript.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/Microsoft/TypeScript-TmLanguage/blob/master/TypeScriptReact.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "name": "JavaScript (with React support)", "scopeName": "source.js", "fileTypes": [ @@ -4222,6 +4227,5 @@ } ] } - }, - "version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/8c967fe7553297bfad672b7417d78e357c8fe724" + } } \ No newline at end of file diff --git a/extensions/less/syntaxes/less.tmLanguage.json b/extensions/less/syntaxes/less.tmLanguage.json index cd25b2a89b5..cd1543fd7d3 100644 --- a/extensions/less/syntaxes/less.tmLanguage.json +++ b/extensions/less/syntaxes/less.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-less/blob/master/grammars/less.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "name": "Less", "scopeName": "source.css.less", "fileTypes": [ @@ -540,6 +545,5 @@ "match": "\\b(abs|acos|alpha|argb|asin|atan|average|blue|calc|ceil|color|contrast|convert|convert|cos|darken|data-uri|desaturate|difference|e|escape|exclusion|extract|fade|fadein|fadeout|floor|format|green|greyscale|hardlight|hsl|hsla|hsv|hsva|hsvhue|hsvsaturation|hsvvalue|hue|length|lighten|lightness|luma|max|min|mix|mod|multiply|negation|overlay|percentage|pi|pow|red|replace|round|saturate|saturation|screen|sin|softlight|spin|sqrt|tan|unit)\\b", "name": "support.function.any-method.builtin.less" } - }, - "version": "https://github.com/atom/language-less/commit/4661d870784f725599e438bf683553cc6cf0f4ed" + } } \ No newline at end of file diff --git a/extensions/lua/syntaxes/lua.json b/extensions/lua/syntaxes/lua.json index a4da3a43c6a..efea9819bde 100644 --- a/extensions/lua/syntaxes/lua.json +++ b/extensions/lua/syntaxes/lua.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/lua.tmbundle/blob/master/Syntaxes/Lua.plist", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "comment": "Lua Syntax: version 0.8", "fileTypes": [ "lua", @@ -275,6 +280,5 @@ } }, "scopeName": "source.lua", - "uuid": "93E017CC-6F27-11D9-90EB-000D93589AF7", - "version": "https://github.com/textmate/lua.tmbundle/commit/3a97f1b46804a3de99d4d2909e14450299462f2d" + "uuid": "93E017CC-6F27-11D9-90EB-000D93589AF7" } \ No newline at end of file diff --git a/extensions/make/syntaxes/Makefile.json b/extensions/make/syntaxes/Makefile.json index 2264321c9c8..1562efc5c17 100644 --- a/extensions/make/syntaxes/Makefile.json +++ b/extensions/make/syntaxes/Makefile.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/make.tmbundle/blob/master/Syntaxes/Makefile.plist", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "Makefile", "makefile", @@ -470,6 +475,5 @@ } }, "scopeName": "source.makefile", - "uuid": "FF1825E8-6B1C-11D9-B883-000D93589AF6", - "version": "https://github.com/textmate/make.tmbundle/commit/1a1827da81e20fdce56e2658451340c070ca44b7" + "uuid": "FF1825E8-6B1C-11D9-B883-000D93589AF6" } \ No newline at end of file diff --git a/extensions/objective-c/syntaxes/objective-c++.tmLanguage.json b/extensions/objective-c/syntaxes/objective-c++.tmLanguage.json index 26550c61e1b..2b46507a2fb 100644 --- a/extensions/objective-c/syntaxes/objective-c++.tmLanguage.json +++ b/extensions/objective-c/syntaxes/objective-c++.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-objective-c/blob/master/grammars/objective-c++.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "source.objcpp", "fileTypes": [ "mm", diff --git a/extensions/objective-c/syntaxes/objective-c.tmLanguage.json b/extensions/objective-c/syntaxes/objective-c.tmLanguage.json index 2037028b0c3..a07e0ba7f43 100644 --- a/extensions/objective-c/syntaxes/objective-c.tmLanguage.json +++ b/extensions/objective-c/syntaxes/objective-c.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-objective-c/blob/master/grammars/objective-c.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "source.objc", "fileTypes": [ "m", @@ -993,6 +998,5 @@ } ] } - }, - "version": "https://github.com/atom/language-objective-c/commit/0727e04544f3414c1c339cf15a39a05ea3938cb4" + } } \ No newline at end of file diff --git a/extensions/perl/syntaxes/perl.tmLanguage.json b/extensions/perl/syntaxes/perl.tmLanguage.json index 612c4796cbe..4c4209c317b 100644 --- a/extensions/perl/syntaxes/perl.tmLanguage.json +++ b/extensions/perl/syntaxes/perl.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/perl.tmbundle/blob/master/Syntaxes/Perl.plist", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "comment": "\n\tTODO:\tInclude RegExp syntax\n", "fileTypes": [ "pl", @@ -2541,6 +2546,5 @@ } }, "scopeName": "source.perl", - "uuid": "EDBFE125-6B1C-11D9-9189-000D93589AF6", - "version": "https://github.com/textmate/perl.tmbundle/commit/c0b7a4bd65882380522d82a60b536479a62b07c3" + "uuid": "EDBFE125-6B1C-11D9-9189-000D93589AF6" } \ No newline at end of file diff --git a/extensions/perl/syntaxes/perl6.tmLanguage.json b/extensions/perl/syntaxes/perl6.tmLanguage.json index a3024a11ae7..9ddfdf42509 100644 --- a/extensions/perl/syntaxes/perl6.tmLanguage.json +++ b/extensions/perl/syntaxes/perl6.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/perl.tmbundle/blob/master/Syntaxes/Perl%206.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "p6", "pl6", @@ -314,6 +319,5 @@ } }, "scopeName": "source.perl.6", - "uuid": "E685440C-0E20-4424-9693-864D5240A269", - "version": "https://github.com/textmate/perl.tmbundle/commit/d9841a0878239fa43f88c640f8d458590f97e8f5" + "uuid": "E685440C-0E20-4424-9693-864D5240A269" } \ No newline at end of file diff --git a/extensions/php/syntaxes/php.tmLanguage.json b/extensions/php/syntaxes/php.tmLanguage.json index 8e69579120b..b815d80e072 100644 --- a/extensions/php/syntaxes/php.tmLanguage.json +++ b/extensions/php/syntaxes/php.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-php/blob/master/grammars/php.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "text.html.php", "name": "PHP", "fileTypes": [ @@ -2974,6 +2979,5 @@ } ] } - }, - "version": "https://github.com/atom/language-php/commit/c523a19f849b97f6499eae6accf80564aa190c0e" + } } \ No newline at end of file diff --git a/extensions/pug/syntaxes/pug.tmLanguage.json b/extensions/pug/syntaxes/pug.tmLanguage.json index 808be9e6db8..8a3d17a81dc 100644 --- a/extensions/pug/syntaxes/pug.tmLanguage.json +++ b/extensions/pug/syntaxes/pug.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/davidrios/jade-tmbundle/blob/master/Syntaxes/Jade.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "jade" ], @@ -981,6 +986,5 @@ } }, "scopeName": "text.jade", - "uuid": "eee6ba25-6ac2-4f7e-9c70-cddf2bd3448b", - "version": "https://github.com/davidrios/jade-tmbundle/commit/f311a516bb29296fcebfdc7da8149b1c79dfb0a1" + "uuid": "eee6ba25-6ac2-4f7e-9c70-cddf2bd3448b" } \ No newline at end of file diff --git a/extensions/python/syntaxes/MagicPython.tmLanguage.json b/extensions/python/syntaxes/MagicPython.tmLanguage.json index f9d673e6273..29e51b920fa 100644 --- a/extensions/python/syntaxes/MagicPython.tmLanguage.json +++ b/extensions/python/syntaxes/MagicPython.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/MagicStack/MagicPython/blob/master/grammars/MagicPython.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "name": "MagicPython", "scopeName": "source.python", "fileTypes": [ @@ -5230,6 +5235,5 @@ } ] } - }, - "version": "https://github.com/MagicStack/MagicPython/commit/976e59dcb78cb577e79c8f2117216c06718337e0" + } } \ No newline at end of file diff --git a/extensions/python/syntaxes/MagicRegExp.tmLanguage.json b/extensions/python/syntaxes/MagicRegExp.tmLanguage.json index b5795a7b89f..34d1a973578 100644 --- a/extensions/python/syntaxes/MagicRegExp.tmLanguage.json +++ b/extensions/python/syntaxes/MagicRegExp.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/MagicStack/MagicPython/blob/master/grammars/MagicRegExp.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "name": "MagicRegExp", "scopeName": "source.regexp.python", "fileTypes": [ @@ -460,6 +465,5 @@ } ] } - }, - "version": "https://github.com/MagicStack/MagicPython/commit/df5bb18c64252f2e7b1aa87e2ed124666d314f1d" + } } \ No newline at end of file diff --git a/extensions/r/syntaxes/r.tmLanguage.json b/extensions/r/syntaxes/r.tmLanguage.json index 829be8d0d2b..025877c7ab4 100644 --- a/extensions/r/syntaxes/r.tmLanguage.json +++ b/extensions/r/syntaxes/r.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/r.tmbundle/blob/master/Syntaxes/R.plist", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "R", "r", @@ -199,6 +204,5 @@ } ], "scopeName": "source.r", - "uuid": "B2E6B78D-6E70-11D9-A369-000D93B3A10E", - "version": "https://github.com/textmate/r.tmbundle/commit/6b04ff3424f3f1cdfe64a9cfb71d8765959be250" + "uuid": "B2E6B78D-6E70-11D9-A369-000D93B3A10E" } \ No newline at end of file diff --git a/extensions/razor/syntaxes/cshtml.json b/extensions/razor/syntaxes/cshtml.json index 402915e8c9f..180ad0e68dd 100644 --- a/extensions/razor/syntaxes/cshtml.json +++ b/extensions/razor/syntaxes/cshtml.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/demyte/language-cshtml/blob/master/grammars/cshtml.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "name": "ASP.NET Razor", "scopeName": "text.html.cshtml", "fileTypes": [ @@ -148,6 +153,5 @@ "end": "\\*@", "name": "comment.block.cshtml" } - }, - "version": "https://github.com/demyte/language-cshtml/commit/a49735dc7aef56ae772a3bcfd8e42c89895dcff4" + } } \ No newline at end of file diff --git a/extensions/ruby/syntaxes/ruby.tmLanguage.json b/extensions/ruby/syntaxes/ruby.tmLanguage.json index dce58f758b1..a6e0c01b7b9 100644 --- a/extensions/ruby/syntaxes/ruby.tmLanguage.json +++ b/extensions/ruby/syntaxes/ruby.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/ruby.tmbundle/blob/master/Syntaxes/Ruby.plist", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "comment": "\n\tTODO: unresolved issues\n\n\ttext:\n\t\"p <", "name": "comment.block.xml" } - }, - "version": "https://github.com/atom/language-xml/commit/ac6bc8ef6a9c79ac3c7e31615bc18436b0c815ab" + } } \ No newline at end of file diff --git a/extensions/xml/syntaxes/xsl.json b/extensions/xml/syntaxes/xsl.json index 8b715b599f9..2193c1a9570 100644 --- a/extensions/xml/syntaxes/xsl.json +++ b/extensions/xml/syntaxes/xsl.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-xml/blob/master/grammars/xsl.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "text.xml.xsl", "name": "XSL", "fileTypes": [ @@ -88,6 +93,5 @@ }, "name": "string.quoted.single.xml" } - }, - "version": "https://github.com/atom/language-xml/commit/507de2ee7daca60cf02e9e21fbeb92bbae73e280" + } } \ No newline at end of file diff --git a/extensions/yaml/syntaxes/yaml.json b/extensions/yaml/syntaxes/yaml.json index 55939b86d8d..82cd7d840db 100644 --- a/extensions/yaml/syntaxes/yaml.json +++ b/extensions/yaml/syntaxes/yaml.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/yaml.tmbundle/blob/master/Syntaxes/YAML.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "yaml", "yml", @@ -624,6 +629,5 @@ } }, "scopeName": "source.yaml", - "uuid": "686AD6AE-33F3-4493-9512-9E9FC1D5417F", - "version": "https://github.com/textmate/yaml.tmbundle/commit/efc96efafe5e48480cf55a2ed124b388cbea4440" + "uuid": "686AD6AE-33F3-4493-9512-9E9FC1D5417F" } \ No newline at end of file -- GitLab From f33b73f8e064df35930bc5be8da658f8570587eb Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 13:03:01 +0200 Subject: [PATCH 0056/1347] Possible bugs around non-invoking usage of `isEmpty`. Fixes #27201 --- src/vs/editor/contrib/folding/browser/folding.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vs/editor/contrib/folding/browser/folding.ts b/src/vs/editor/contrib/folding/browser/folding.ts index 9f644ccd761..74df9c51570 100644 --- a/src/vs/editor/contrib/folding/browser/folding.ts +++ b/src/vs/editor/contrib/folding/browser/folding.ts @@ -287,7 +287,7 @@ export class FoldingController implements IFoldingController { return; } let range = e.target.range; - if (!range || !range.isEmpty) { + if (!range) { return; } if (!e.event.leftButton) { @@ -303,7 +303,7 @@ export class FoldingController implements IFoldingController { break; case MouseTargetType.CONTENT_EMPTY: case MouseTargetType.CONTENT_TEXT: - if (range.isEmpty && range.startColumn === model.getLineMaxColumn(range.startLineNumber)) { + if (range.startColumn === model.getLineMaxColumn(range.startLineNumber)) { break; } return; @@ -322,7 +322,7 @@ export class FoldingController implements IFoldingController { let iconClicked = this.mouseDownInfo.iconClicked; let range = e.target.range; - if (!range || !range.isEmpty || range.startLineNumber !== lineNumber) { + if (!range || range.startLineNumber !== lineNumber) { return; } -- GitLab From 409a694c2def2a0d630b0ecf948bc14bbd42f590 Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Thu, 25 May 2017 07:03:56 -0700 Subject: [PATCH 0057/1347] Fix failing ripgrep test --- .../services/search/test/node/ripgrepTextSearch.test.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts b/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts index 2f377d82d27..1ee3f9a6a83 100644 --- a/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts +++ b/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts @@ -70,7 +70,7 @@ suite('RipgrepParser', () => { assert.deepEqual(results[0], { numMatches: 2, - path: path.join(rootFolder, 'a.txt'), + path: path.resolve(rootFolder, 'a.txt'), lineMatches: [ { lineNumber: 0, -- GitLab From 953acb6d7881fdf8b71ffa64ad7a981c68f1931e Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Thu, 25 May 2017 17:15:23 +0200 Subject: [PATCH 0058/1347] Fixes Microsoft/monaco-editor#278 --- src/vs/editor/editor.main.ts | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/src/vs/editor/editor.main.ts b/src/vs/editor/editor.main.ts index 667a3004499..012e073ff51 100644 --- a/src/vs/editor/editor.main.ts +++ b/src/vs/editor/editor.main.ts @@ -21,10 +21,17 @@ import { EDITOR_DEFAULTS, WrappingIndent } from 'vs/editor/common/config/editorO (EDITOR_DEFAULTS.contribInfo).folding = false; (EDITOR_DEFAULTS.viewInfo).glyphMargin = false; +let base = createMonacoBaseAPI(); +for (let prop in base) { + if (base.hasOwnProperty(prop)) { + exports[prop] = base[prop]; + } +} +exports.editor = createMonacoEditorAPI(); +exports.languages = createMonacoLanguagesAPI(); + var global: any = self; -global.monaco = createMonacoBaseAPI(); -global.monaco.editor = createMonacoEditorAPI(); -global.monaco.languages = createMonacoLanguagesAPI(); +global.monaco = exports; if (typeof global.require !== 'undefined' && typeof global.require.config === 'function') { global.require.config({ -- GitLab From fe1d9cb797d644c43935069bdf99bd9f72c6f8f6 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Thu, 25 May 2017 08:44:07 -0700 Subject: [PATCH 0059/1347] Move terminal.foreground defaults to JS Fixes #27230 --- .../parts/terminal/electron-browser/media/terminal.css | 3 --- .../terminal/electron-browser/terminalColorRegistry.ts | 6 +++++- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css b/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css index f35dde259bf..5a7d34f9e18 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css +++ b/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css @@ -9,12 +9,9 @@ display: flex; flex-direction: column; background-color: transparent!important; - color: #333; -webkit-user-select: initial; position: relative; } -.vs-dark .monaco-workbench .panel.integrated-terminal { color: #CCC; } -.hc-black .monaco-workbench .panel.integrated-terminal { color: #FFF; } .monaco-workbench .panel.integrated-terminal .terminal-outer-container { height: 100%; diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.ts index 27f3f23c8ba..ae1d524a912 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.ts @@ -14,7 +14,11 @@ import { registerColor, ColorIdentifier } from 'vs/platform/theme/common/colorRe export const ansiColorIdentifiers: ColorIdentifier[] = []; export const TERMINAL_BACKGROUND_COLOR = registerColor('terminal.background', null, nls.localize('terminal.background', 'The background color of the terminal, this allows coloring the terminal differently to the panel.')); -export const TERMINAL_FOREGROUND_COLOR = registerColor('terminal.foreground', null, nls.localize('terminal.foreground', 'The foreground color of the terminal.')); +export const TERMINAL_FOREGROUND_COLOR = registerColor('terminal.foreground', { + light: '#333333', + dark: '#CCCCCC', + hc: 'FFFFFF' +}, nls.localize('terminal.foreground', 'The foreground color of the terminal.')); const ansiColorMap = { 'terminal.ansiBlack': { -- GitLab From 306de468b0016acde9d86baa6846dbf02e30dcb3 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Thu, 25 May 2017 08:44:54 -0700 Subject: [PATCH 0060/1347] Remove deprecated css property --- .../parts/terminal/electron-browser/media/terminal.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css b/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css index 5a7d34f9e18..f2cc6747e2c 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css +++ b/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css @@ -9,7 +9,7 @@ display: flex; flex-direction: column; background-color: transparent!important; - -webkit-user-select: initial; + user-select: initial; position: relative; } -- GitLab From 4c9e59f6926532b69b7db374c8fcfa4cb05ae1ce Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 25 May 2017 09:09:41 -0700 Subject: [PATCH 0061/1347] More welcome page colors (#25798) --- .../electron-browser/vs_code_welcome_page.ts | 38 +++++----- .../page/electron-browser/welcomePage.css | 69 +------------------ .../page/electron-browser/welcomePage.ts | 26 ++++++- 3 files changed, 47 insertions(+), 86 deletions(-) diff --git a/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.ts b/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.ts index cc27fe4978c..767ee36747a 100644 --- a/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.ts +++ b/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.ts @@ -14,13 +14,13 @@ export default () => `
-

${escape(localize('welcomePage.vscode', "Visual Studio Code"))}

-

${escape(localize('welcomePage.editingEvolved', "Editing evolved"))}

+

${escape(localize('welcomePage.vscode', "Visual Studio Code"))}

+

${escape(localize('welcomePage.editingEvolved', "Editing evolved"))}

-

${escape(localize('welcomePage.start', "Start"))}

+

${escape(localize('welcomePage.start', "Start"))}

-

${escape(localize('welcomePage.recent', "Recent"))}

+

${escape(localize('welcomePage.recent', "Recent"))}

-

${escape(localize('welcomePage.noRecentFolders', "No recent folders"))}

+

${escape(localize('welcomePage.noRecentFolders', "No recent folders"))}

-

+

-

${escape(localize('welcomePage.customize', "Customize"))}

+

${escape(localize('welcomePage.customize', "Customize"))}

    -
  • -
  • -
  • +
-

${escape(localize('welcomePage.learn', "Learn"))}

+

${escape(localize('welcomePage.learn', "Learn"))}

    -
  • -
  • -
  • +
  • +
  • +
diff --git a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.css b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.css index 982a72d9d1b..a3c2fa3e686 100644 --- a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.css +++ b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.css @@ -16,9 +16,6 @@ max-width: 1200px; font-size: 10px; } -.vs .monaco-workbench > .part.editor > .content .welcomePage { - color: #6C6C6C; -} .monaco-workbench > .part.editor > .content .welcomePage .row { display: flex; @@ -41,66 +38,36 @@ } .monaco-workbench > .part.editor > .content .welcomePage a { - color: #2e70c0; text-decoration: none; } -.vs-dark .monaco-workbench > .part.editor > .content .welcomePage a { - color: #4080D0; -} - .monaco-workbench > .part.editor > .content .welcomePage a:focus { outline: 1px solid -webkit-focus-ring-color; outline-offset: -1px; } -.monaco-workbench > .part.editor > .content .welcomePage a:hover { - color: #6ea0dc; -} - -.hc-black .monaco-workbench > .part.editor > .content .welcomePage a { - color: #0b9eff; -} - -.hc-black .monaco-workbench > .part.editor > .content .welcomePage a:hover { - color: #f38518; -} - .monaco-workbench > .part.editor > .content .welcomePage h1 { padding: 0; margin: 0; border: none; font-weight: normal; - color: rgba(0,0,0,.8); font-size: 3.6em; white-space: nowrap; } -.vs-dark .monaco-workbench > .part.editor > .content .welcomePage h1 { - color: rgba(255,255,255,.76); -} - -.hc-black .monaco-workbench > .part.editor > .content .welcomePage h1 { - color: white; -} - .monaco-workbench > .part.editor > .content .welcomePage .title { margin-top: 1em; margin-bottom: 1em; flex: 1 100%; } + .monaco-workbench > .part.editor > .content .welcomePage .subtitle { margin-top: .8em; font-size: 2.6em; - color: rgba(0,0,0,.53); display: block; } -.vs-dark .monaco-workbench > .part.editor > .content .welcomePage .subtitle { - color: rgba(255,255,255,.46); -} .hc-black .monaco-workbench > .part.editor > .content .welcomePage .subtitle { - color: white; font-weight: 200; } @@ -150,22 +117,6 @@ } .monaco-workbench > .part.editor > .content .welcomePage .splash .recent .path { padding-left: 1em; - color: rgba(255,255,255,.46); -} - -.monaco-workbench > .part.editor > .content .welcomePage .splash .recent .none, -.monaco-workbench > .part.editor > .content .welcomePage .splash .recent .path { - color: rgba(0,0,0,.53); -} - -.vs-dark .monaco-workbench > .part.editor > .content .welcomePage .splash .recent .none, -.vs-dark .monaco-workbench > .part.editor > .content .welcomePage .splash .recent .path { - color: rgba(255,255,255,.46); -} - -.hc-black .monaco-workbench > .part.editor > .content .welcomePage .splash .recent .none, -.hc-black .monaco-workbench > .part.editor > .content .welcomePage .splash .recent .path { - color: white; } .monaco-workbench > .part.editor > .content .welcomePage .splash .title, @@ -207,41 +158,27 @@ margin-bottom: .25em; } -.vs .monaco-workbench > .part.editor > .content .welcomePage .commands li button h3 { - color: #2c2c2c; -} - .monaco-workbench > .part.editor > .content .welcomePage .commands li button { - color: #6c6c6c; border: none; } -.vs-dark .monaco-workbench > .part.editor > .content .welcomePage .commands li button > h3 { - color: #ccc; -} - .hc-black .monaco-workbench > .part.editor > .content .welcomePage .commands li button > h3 { font-weight: bold; } -.vs-dark .monaco-workbench > .part.editor > .content .welcomePage .commands li button { - color: #828282; -} - .monaco-workbench > .part.editor > .content .welcomePage .commands li button:focus { outline-style: solid; outline-width: 1px; } .hc-black .monaco-workbench > .part.editor > .content .welcomePage .commands li button { - color: white; - border-color: #f38518; border-width: 1px; border-style: solid; } .hc-black .monaco-workbench > .part.editor > .content .welcomePage .commands li button:hover { - outline: 1px dashed #f38518; + outline-width: 1px; + outline-style: dashed; outline-offset: -5px; } diff --git a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts index 874bc17d8dd..86dde1dd27d 100644 --- a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts +++ b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts @@ -35,7 +35,7 @@ import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { tildify } from 'vs/base/common/labels'; import { isLinux } from 'vs/base/common/platform'; import { IThemeService, registerThemingParticipant } from 'vs/platform/theme/common/themeService'; -import { registerColor } from 'vs/platform/theme/common/colorRegistry'; +import { registerColor, textLinkForeground, foreground, contrastBorder, activeContrastBorder } from 'vs/platform/theme/common/colorRegistry'; import { getExtraColor } from 'vs/workbench/parts/welcome/walkThrough/node/walkThroughUtils'; used(); @@ -240,6 +240,7 @@ class WelcomePage { const span = document.createElement('span'); span.classList.add('path'); + span.classList.add('detail'); span.innerText = tildify(parentFolder, this.environmentService.userHome); span.title = folder; li.appendChild(span); @@ -446,10 +447,21 @@ class WelcomePage { // theming +const caption = registerColor('welcomePage.caption', { dark: '#FFFFFFC2', light: '#000000D4', hc: foreground }, localize('welcomePage.caption', 'Caption color on the Welcome page.')); +const detail = registerColor('welcomePage.detail', { dark: '#FFFFFF76', light: '#00000088', hc: foreground }, localize('welcomePage.detail', 'Detail color on the Welcome page.')); + const quickLinkBackground = registerColor('welcomePage.quickLinkBackground', { dark: null, light: null, hc: null }, localize('welcomePage.quickLinkBackground', 'Background color for the quick links on the Welcome page.')); const quickLinkHoverBackground = registerColor('welcomePage.quickLinkHoverBackground', { dark: null, light: null, hc: null }, localize('welcomePage.quickLinkHoverBackground', 'Hover background color for the quick links on the Welcome page.')); registerThemingParticipant((theme, collector) => { + const captionColor = theme.getColor(caption); + if (captionColor) { + collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .caption { color: ${captionColor}; }`); + } + const detailColor = theme.getColor(detail); + if (detailColor) { + collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .detail { color: ${detailColor}; }`); + } const color = getExtraColor(theme, quickLinkBackground, { dark: 'rgba(0, 0, 0, .2)', extra_dark: 'rgba(200, 235, 255, .042)', light: 'rgba(0,0,0,.04)', hc: 'black' }); if (color) { collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .commands li button { background: ${color}; }`); @@ -458,4 +470,16 @@ registerThemingParticipant((theme, collector) => { if (hover) { collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .commands li button:hover { background: ${hover}; }`); } + const link = theme.getColor(textLinkForeground); + if (link) { + collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage a { color: ${link}; }`); + } + const border = theme.getColor(contrastBorder); + if (border) { + collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .commands li button { border-color: ${border}; }`); + } + const activeBorder = theme.getColor(activeContrastBorder); + if (activeBorder) { + collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .commands li button:hover { outline-color: ${activeBorder}; }`); + } }); -- GitLab From 485629d4163c898324c6ef7434c86097a9d4bfb1 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 25 May 2017 09:49:50 -0700 Subject: [PATCH 0062/1347] Playground colors (#25798) --- .../electron-browser/walkThroughPart.css | 30 ++----------------- .../electron-browser/walkThroughPart.ts | 23 +++++++++++++- 2 files changed, 24 insertions(+), 29 deletions(-) diff --git a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.css b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.css index baaf1f3ceed..305fece6c6b 100644 --- a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.css +++ b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.css @@ -17,7 +17,6 @@ } .monaco-workbench > .part.editor > .content .walkThroughContent a { - color: #4080D0; text-decoration: none; } @@ -69,7 +68,6 @@ } .monaco-workbench > .part.editor > .content .walkThroughContent a:hover { - color: #4080D0; text-decoration: underline; } @@ -106,36 +104,11 @@ line-height: 19px; } -/*.monaco-workbench.mac > .part.editor > .content .walkThroughContent code, -.monaco-workbench.mac > .part.editor > .content .walkThroughContent .shortcut { - font-size: 12px; - line-height: 18px; -}*/ - -.vs .monaco-workbench > .part.editor > .content .walkThroughContent code, -.vs .monaco-workbench > .part.editor > .content .walkThroughContent .shortcut { - color: #A31515; -} - -.vs-dark .monaco-workbench > .part.editor > .content .walkThroughContent code, -.vs-dark .monaco-workbench > .part.editor > .content .walkThroughContent .shortcut { - color: #D7BA7D; -} - .monaco-workbench > .part.editor > .content .walkThroughContent blockquote { margin: 0 7px 0 5px; padding: 0 16px 0 10px; border-left: 5px solid; } -.vs .monaco-workbench > .part.editor > .content .walkThroughContent blockquote, -.vs-dark .monaco-workbench > .part.editor > .content .walkThroughContent blockquote { - background: rgba(127, 127, 127, 0.1); - border-color: rgba(0, 122, 204, 0.5); -} -.hc-black .monaco-workbench > .part.editor > .content .walkThroughContent blockquote { - background: transparent; - border-color: #fff; -} .monaco-workbench > .part.editor > .content .walkThroughContent .monaco-tokenized-source { white-space: pre; @@ -162,5 +135,6 @@ } .hc-black .monaco-workbench > .part.editor > .content .walkThroughContent .monaco-editor { - border: 1px white solid + border-width: 1px; + border-style: solid; } diff --git a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts index 2fcbace413f..f22fa7e0702 100644 --- a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts +++ b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts @@ -38,7 +38,7 @@ import { IPartService } from 'vs/workbench/services/part/common/partService'; import { IEditorOptions } from 'vs/editor/common/config/editorOptions'; import { IMessageService, Severity } from 'vs/platform/message/common/message'; import { IThemeService, registerThemingParticipant } from 'vs/platform/theme/common/themeService'; -import { registerColor } from 'vs/platform/theme/common/colorRegistry'; +import { registerColor, textLinkForeground, textPreformatForeground, contrastBorder, textBlockQuoteBackground, textBlockQuoteBorder } from 'vs/platform/theme/common/colorRegistry'; import { getExtraColor } from 'vs/workbench/parts/welcome/walkThrough/node/walkThroughUtils'; export const WALK_THROUGH_FOCUS = new RawContextKey('interactivePlaygroundFocus', false); @@ -534,4 +534,25 @@ registerThemingParticipant((theme, collector) => { collector.addRule(`.monaco-workbench > .part.editor > .content .walkThroughContent .monaco-editor-background, .monaco-workbench > .part.editor > .content .walkThroughContent .margin-view-overlays { background: ${color}; }`); } + const link = theme.getColor(textLinkForeground); + if (link) { + collector.addRule(`.monaco-workbench > .part.editor > .content .walkThroughContent a { color: ${link}; }`); + } + const shortcut = theme.getColor(textPreformatForeground); + if (shortcut) { + collector.addRule(`.monaco-workbench > .part.editor > .content .walkThroughContent code, + .monaco-workbench > .part.editor > .content .walkThroughContent .shortcut { color: ${shortcut}; }`); + } + const border = theme.getColor(contrastBorder); + if (border) { + collector.addRule(`.monaco-workbench > .part.editor > .content .walkThroughContent .monaco-editor { border-color: ${border}; }`); + } + const quoteBackground = theme.getColor(textBlockQuoteBackground); + if (quoteBackground) { + collector.addRule(`.monaco-workbench > .part.editor > .content .walkThroughContent blockquote { background: ${quoteBackground}; }`); + } + const quoteBorder = theme.getColor(textBlockQuoteBorder); + if (quoteBorder) { + collector.addRule(`.monaco-workbench > .part.editor > .content .walkThroughContent blockquote { border-color: ${quoteBorder}; }`); + } }); \ No newline at end of file -- GitLab From 9b02670f995e53f6478e4d3a800128f2325dc22d Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 25 May 2017 10:25:46 -0700 Subject: [PATCH 0063/1347] Overlay color (#25798) --- .../overlay/browser/welcomeOverlay.css | 15 ------------- .../welcome/overlay/browser/welcomeOverlay.ts | 22 +++++++++++++++++++ 2 files changed, 22 insertions(+), 15 deletions(-) diff --git a/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.css b/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.css index 6aa8c04e789..50cf77eafad 100644 --- a/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.css +++ b/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.css @@ -10,15 +10,10 @@ height: 100%; width: 100%; z-index: 9999; - background: rgba(0,0,0,0.52); font-size: 10px; transition: font-size .25s; } -.vs .monaco-workbench > .welcomeOverlay { - background: rgba(255,255,255,.52); -} - #workbench\.parts\.editor { transition: filter .25s, opacity .2s; } @@ -40,15 +35,6 @@ font-size: 1.6em; } -.monaco-workbench > .welcomeOverlay > .key { - color: #000; -} - -.vs-dark .monaco-workbench > .welcomeOverlay > .key, -.hc-black .monaco-workbench > .welcomeOverlay > .key { - color: #FFF; -} - .monaco-workbench > .welcomeOverlay > .key > .label { padding: 0 1ex; } @@ -56,7 +42,6 @@ .monaco-workbench > .welcomeOverlay > .key > .shortcut { letter-spacing: 0.15em; font-size: 0.8125em; - color: #d7ba7d; font-family: "Lucida Grande", sans-serif; } diff --git a/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.ts b/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.ts index 8a3bb16246a..d5a435aac22 100644 --- a/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.ts +++ b/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.ts @@ -22,6 +22,8 @@ import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { RawContextKey, IContextKey, IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; import { KeyCode } from 'vs/base/common/keyCodes'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; +import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; +import { registerColor, textPreformatForeground } from 'vs/platform/theme/common/colorRegistry'; interface Key { id: string; @@ -233,3 +235,23 @@ Registry.as(Extensions.WorkbenchActions) Registry.as(Extensions.WorkbenchActions) .registerWorkbenchAction(new SyncActionDescriptor(HideWelcomeOverlayAction, HideWelcomeOverlayAction.ID, HideWelcomeOverlayAction.LABEL, { primary: KeyCode.Escape }, OVERLAY_VISIBLE), 'Help: Hide Interface Overview', localize('help', "Help")); + +// theming + +const foreground = registerColor('welcomeOverlay.foreground', { dark: '#fff', light: '#000', hc: '#fff' }, localize('welcomeOverlay.foreground', 'Foreground color for the Interface Overview.')); +const background = registerColor('welcomeOverlay.background', { dark: '#00000085', light: '#FFFFFF85', hc: '#00000085' }, localize('welcomeOverlay.background', 'Background color for the Interface Overview.')); + +registerThemingParticipant((theme, collector) => { + const key = theme.getColor(foreground); + if (key) { + collector.addRule(`.monaco-workbench > .welcomeOverlay > .key { color: ${key}; }`); + } + const backgroundColor = theme.getColor(background); + if (backgroundColor) { + collector.addRule(`.monaco-workbench > .welcomeOverlay { background: ${backgroundColor}; }`); + } + const shortcut = theme.getColor(textPreformatForeground); + if (shortcut) { + collector.addRule(`.monaco-workbench > .welcomeOverlay > .key > .shortcut { color: ${shortcut}; }`); + } +}); -- GitLab From f479fcd2e5f39b0706533382e1d96e1bbcede7c3 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Thu, 25 May 2017 11:07:55 -0700 Subject: [PATCH 0064/1347] Add null check in terminalPanel click listener Fixes #27256 --- .../parts/terminal/electron-browser/terminalPanel.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts index ec880bdd12c..4b5a29f34c4 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts @@ -197,11 +197,12 @@ export class TerminalPanel extends Panel { this._cancelContextMenu = false; })); this._register(dom.addDisposableListener(this._parentDomElement, 'click', (event) => { - if (this._terminalService.terminalInstances.length === 0) { + if (event.which === 3) { return; } - if (event.which !== 3) { + const instance = this._terminalService.getActiveInstance(); + if (instance) { this._terminalService.getActiveInstance().focus(); } })); -- GitLab From 796f945a2dd1bdb51846d12dfd2ba0d5f2108caf Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Thu, 25 May 2017 11:11:40 -0700 Subject: [PATCH 0065/1347] Add null check to terminal link handler Fixes #27247 --- .../terminal/electron-browser/terminalLinkHandler.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.ts index 49df15b331a..16047707ea7 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.ts @@ -226,12 +226,15 @@ export class TerminalLinkHandler { private _resolvePath(link: string): TPromise { link = this._preprocessPath(link); - if (!link) { return TPromise.as(void 0); } const linkUrl = this.extractLinkUrl(link); + if (!linkUrl) { + return TPromise.as(void 0); + } + // Open an editor if the path exists return pfs.fileExists(linkUrl).then(isFile => { if (!isFile) { @@ -292,6 +295,9 @@ export class TerminalLinkHandler { */ public extractLinkUrl(link: string): string { const matches: string[] = this._localLinkRegex.exec(link); + if (!matches) { + return null; + } return matches[1]; } } -- GitLab From d8c1adbd2ef48623709c6c8f227f39f70ba5923e Mon Sep 17 00:00:00 2001 From: rebornix Date: Thu, 25 May 2017 11:25:34 -0700 Subject: [PATCH 0066/1347] Fix #27265. False positve --- src/vs/editor/contrib/find/common/findController.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/vs/editor/contrib/find/common/findController.ts b/src/vs/editor/contrib/find/common/findController.ts index 4536b2b5b6f..a5dae70a8dc 100644 --- a/src/vs/editor/contrib/find/common/findController.ts +++ b/src/vs/editor/contrib/find/common/findController.ts @@ -508,13 +508,13 @@ export class StartFindReplaceAction extends EditorAction { let controller = CommonFindController.get(editor); let currentSelection = editor.getSelection(); // we only seed search string from selection when the current selection is single line and not empty. - let seedSearchStringFromSelection = currentSelection.isEmpty() || - currentSelection.startLineNumber !== currentSelection.endLineNumber; + let seedSearchStringFromSelection = !currentSelection.isEmpty() && + currentSelection.startLineNumber === currentSelection.endLineNumber; let oldSearchString = controller.getState().searchString; // if the existing search string in find widget is empty and we don't seed search string from selection, it means the Find Input // is still empty, so we should focus the Find Input instead of Replace Input. - let shouldFocus = !oldSearchString && seedSearchStringFromSelection ? - FindStartFocusAction.FocusFindInput : FindStartFocusAction.FocusReplaceInput; + let shouldFocus = (!!oldSearchString || seedSearchStringFromSelection) ? + FindStartFocusAction.FocusReplaceInput : FindStartFocusAction.FocusFindInput; if (controller) { controller.start({ -- GitLab From 391f7421450567de4abeb4119b98babd7df41efa Mon Sep 17 00:00:00 2001 From: Ramya Rao Date: Thu, 25 May 2017 13:10:39 -0700 Subject: [PATCH 0067/1347] Start crash reporter inside child processes (#27180) * Use service to get crash reporter start options * some refactorings and fixes * Move crashesDirectory to the main payload from extra bag --- src/bootstrap.js | 12 +++ src/typings/electron.d.ts | 7 ++ .../electron-browser/crashReporter.ts | 71 --------------- .../electron-browser/extensionHost.ts | 12 ++- src/vs/workbench/electron-browser/shell.ts | 32 ++----- .../common/crashReporterService.ts | 43 +++++++++ .../electron-browser/crashReporterService.ts | 91 +++++++++++++++++++ 7 files changed, 171 insertions(+), 97 deletions(-) delete mode 100644 src/vs/workbench/electron-browser/crashReporter.ts create mode 100644 src/vs/workbench/services/crashReporter/common/crashReporterService.ts create mode 100644 src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts diff --git a/src/bootstrap.js b/src/bootstrap.js index 022aa50b6a3..3f94abadd31 100644 --- a/src/bootstrap.js +++ b/src/bootstrap.js @@ -126,4 +126,16 @@ if (process.env['VSCODE_PARENT_PID']) { } } +const crashReporterOptionsRaw = process.env['CRASH_REPORTER_START_OPTIONS']; +if (typeof crashReporterOptionsRaw === 'string') { + try { + const crashReporterOptions = JSON.parse(crashReporterOptionsRaw); + if (crashReporterOptions) { + process.crashReporter.start(crashReporterOptions); + } + } catch (error) { + console.error(error); + } +} + require('./bootstrap-amd').bootstrap(process.env['AMD_ENTRYPOINT']); \ No newline at end of file diff --git a/src/typings/electron.d.ts b/src/typings/electron.d.ts index 5a1f5ea3430..05aab3a8161 100644 --- a/src/typings/electron.d.ts +++ b/src/typings/electron.d.ts @@ -2066,6 +2066,13 @@ declare namespace Electron { * Only string properties are sent correctly, nested objects are not supported. */ extra?: { [prop: string]: string }; + + /** + * Path to a folder where the crashes will be temporarily stored by the electron crash reporter + * Applies only to child processes that need crash reporting. + * Electron figures out the crashesDirectory on its own for Main and Renderer process + */ + crashesDirectory?: string; } interface CrashReport { diff --git a/src/vs/workbench/electron-browser/crashReporter.ts b/src/vs/workbench/electron-browser/crashReporter.ts deleted file mode 100644 index 119229bc2d4..00000000000 --- a/src/vs/workbench/electron-browser/crashReporter.ts +++ /dev/null @@ -1,71 +0,0 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ -'use strict'; - -import nls = require('vs/nls'); -import { onUnexpectedError } from 'vs/base/common/errors'; -import { assign, clone } from 'vs/base/common/objects'; -import { IConfigurationRegistry, Extensions } from 'vs/platform/configuration/common/configurationRegistry'; -import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { IWindowsService } from 'vs/platform/windows/common/windows'; -import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; -import { Registry } from 'vs/platform/platform'; -import { crashReporter } from 'electron'; -import product from 'vs/platform/node/product'; -import pkg from 'vs/platform/node/package'; - -const TELEMETRY_SECTION_ID = 'telemetry'; - -interface ICrashReporterConfig { - enableCrashReporter: boolean; -} - -const configurationRegistry = Registry.as(Extensions.Configuration); -configurationRegistry.registerConfiguration({ - 'id': TELEMETRY_SECTION_ID, - 'order': 110, - title: nls.localize('telemetryConfigurationTitle', "Telemetry"), - 'type': 'object', - 'properties': { - 'telemetry.enableCrashReporter': { - 'type': 'boolean', - 'description': nls.localize('telemetry.enableCrashReporting', "Enable crash reports to be sent to Microsoft.\nThis option requires restart to take effect."), - 'default': true - } - } -}); - -export class CrashReporter { - - constructor( - configuration: Electron.CrashReporterStartOptions, - @ITelemetryService telemetryService: ITelemetryService, - @IWindowsService windowsService: IWindowsService, - @IConfigurationService configurationService: IConfigurationService - ) { - const config = configurationService.getConfiguration(TELEMETRY_SECTION_ID); - - if (!config.enableCrashReporter) { - return; - } - - telemetryService.getTelemetryInfo() - .then(info => ({ - vscode_sessionId: info.sessionId, - vscode_version: pkg.version, - vscode_commit: product.commit, - vscode_machineId: info.machineId - })) - .then(extra => assign(configuration, { extra })) - .then(configuration => { - // start crash reporter right here - crashReporter.start(clone(configuration)); - - // TODO: start crash reporter in the main process - return windowsService.startCrashReporter(configuration); - }) - .done(null, onUnexpectedError); - } -} \ No newline at end of file diff --git a/src/vs/workbench/electron-browser/extensionHost.ts b/src/vs/workbench/electron-browser/extensionHost.ts index e8f82622b43..2431281d98e 100644 --- a/src/vs/workbench/electron-browser/extensionHost.ts +++ b/src/vs/workbench/electron-browser/extensionHost.ts @@ -32,6 +32,7 @@ import Event, { Emitter } from 'vs/base/common/event'; import { IInitData } from 'vs/workbench/api/node/extHost.protocol'; import { MainProcessExtensionService } from 'vs/workbench/api/electron-browser/mainThreadExtensionService'; import { IWorkspaceConfigurationService } from 'vs/workbench/services/configuration/common/configuration'; +import { ICrashReporterService } from 'vs/workbench/services/crashReporter/common/crashReporterService'; export const EXTENSION_LOG_BROADCAST_CHANNEL = 'vscode:extensionLog'; export const EXTENSION_ATTACH_BROADCAST_CHANNEL = 'vscode:extensionAttach'; @@ -92,7 +93,9 @@ export class ExtensionHostProcessWorker { @IInstantiationService private instantiationService: IInstantiationService, @IEnvironmentService private environmentService: IEnvironmentService, @IWorkspaceConfigurationService private configurationService: IWorkspaceConfigurationService, - @ITelemetryService private telemetryService: ITelemetryService + @ITelemetryService private telemetryService: ITelemetryService, + @ICrashReporterService private crashReporterService: ICrashReporterService + ) { // handle extension host lifecycle a bit special when we know we are developing an extension that runs inside this.isExtensionDevelopmentHost = environmentService.isExtensionDevelopment; @@ -111,7 +114,7 @@ export class ExtensionHostProcessWorker { const [server, hook] = <[Server, string]>data[0]; const port = data[1]; - let opts = { + const opts = { env: objects.mixin(objects.clone(process.env), { AMD_ENTRYPOINT: 'vs/workbench/node/extensionHostProcess', PIPE_LOGGING: 'true', @@ -130,6 +133,11 @@ export class ExtensionHostProcessWorker { : undefined }; + const crashReporterOptions = this.crashReporterService.getChildProcessStartOptions('extensionHost'); + if (crashReporterOptions) { + opts.env.CRASH_REPORTER_START_OPTIONS = JSON.stringify(crashReporterOptions); + } + // Run Extension Host as fork of current process this.extensionHostProcess = fork(URI.parse(require.toUrl('bootstrap')).fsPath, ['--type=extensionHost'], opts); diff --git a/src/vs/workbench/electron-browser/shell.ts b/src/vs/workbench/electron-browser/shell.ts index da3ce116627..66e974a00c7 100644 --- a/src/vs/workbench/electron-browser/shell.ts +++ b/src/vs/workbench/electron-browser/shell.ts @@ -73,7 +73,8 @@ import { IExtensionService } from 'vs/platform/extensions/common/extensions'; import { WorkbenchModeServiceImpl } from 'vs/workbench/services/mode/common/workbenchModeService'; import { IModeService } from 'vs/editor/common/services/modeService'; import { IUntitledEditorService, UntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; -import { CrashReporter } from 'vs/workbench/electron-browser/crashReporter'; +import { ICrashReporterService, NullCrashReporterService } from 'vs/workbench/services/crashReporter/common/crashReporterService'; +import { CrashReporterService } from 'vs/workbench/services/crashReporter/electron-browser/crashReporterService'; import { NodeCachedDataManager } from 'vs/workbench/electron-browser/nodeCachedDataManager'; import { getDelayedChannel } from 'vs/base/parts/ipc/common/ipc'; import { connect as connectNet } from 'vs/base/parts/ipc/node/ipc.net'; @@ -168,29 +169,6 @@ export class WorkbenchShell { // Instantiation service with services const [instantiationService, serviceCollection] = this.initServiceCollection(parent.getHTMLElement()); - //crash reporting - if (product.crashReporter && product.hockeyApp) { - let submitURL: string; - - if (platform.isWindows) { - submitURL = product.hockeyApp[`win32-${process.arch}`]; - } else if (platform.isMacintosh) { - submitURL = product.hockeyApp.darwin; - } else if (platform.isLinux) { - submitURL = product.hockeyApp[`linux-${process.arch}`]; - } - - if (submitURL) { - const opts: Electron.CrashReporterStartOptions = { - companyName: product.crashReporter.companyName, - productName: product.crashReporter.productName, - submitURL - }; - - instantiationService.createInstance(CrashReporter, opts); - } - } - // Workbench this.workbench = instantiationService.createInstance(Workbench, parent.getHTMLElement(), workbenchContainer.getHTMLElement(), this.options, serviceCollection); this.workbench.startup({ @@ -333,6 +311,12 @@ export class WorkbenchShell { serviceCollection.set(ITelemetryService, this.telemetryService); disposables.add(configurationTelemetry(this.telemetryService, this.configurationService)); + let crashReporterService = NullCrashReporterService; + if (product.crashReporter && product.hockeyApp) { + crashReporterService = instantiationService.createInstance(CrashReporterService); + } + serviceCollection.set(ICrashReporterService, crashReporterService); + this.messageService = instantiationService.createInstance(MessageService, container); serviceCollection.set(IMessageService, this.messageService); serviceCollection.set(IChoiceService, this.messageService); diff --git a/src/vs/workbench/services/crashReporter/common/crashReporterService.ts b/src/vs/workbench/services/crashReporter/common/crashReporterService.ts new file mode 100644 index 00000000000..4ce3933901d --- /dev/null +++ b/src/vs/workbench/services/crashReporter/common/crashReporterService.ts @@ -0,0 +1,43 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +'use strict'; + +import nls = require('vs/nls'); +import { IConfigurationRegistry, Extensions } from 'vs/platform/configuration/common/configurationRegistry'; +import { Registry } from 'vs/platform/platform'; +import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; + +export const ICrashReporterService = createDecorator('crashReporterService'); + +export const TELEMETRY_SECTION_ID = 'telemetry'; + +export interface ICrashReporterConfig { + enableCrashReporter: boolean; +} + +const configurationRegistry = Registry.as(Extensions.Configuration); +configurationRegistry.registerConfiguration({ + 'id': TELEMETRY_SECTION_ID, + 'order': 110, + title: nls.localize('telemetryConfigurationTitle', "Telemetry"), + 'type': 'object', + 'properties': { + 'telemetry.enableCrashReporter': { + 'type': 'boolean', + 'description': nls.localize('telemetry.enableCrashReporting', "Enable crash reports to be sent to Microsoft.\nThis option requires restart to take effect."), + 'default': true + } + } +}); + +export interface ICrashReporterService { + _serviceBrand: any; + getChildProcessStartOptions(processName: string): Electron.CrashReporterStartOptions; +} + +export const NullCrashReporterService: ICrashReporterService = { + _serviceBrand: undefined, + getChildProcessStartOptions(processName: string) { return undefined; } +}; \ No newline at end of file diff --git a/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts b/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts new file mode 100644 index 00000000000..58cca417c6b --- /dev/null +++ b/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts @@ -0,0 +1,91 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +'use strict'; + +import { onUnexpectedError } from 'vs/base/common/errors'; +import { assign, clone } from 'vs/base/common/objects'; +import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; +import { IWindowsService } from 'vs/platform/windows/common/windows'; +import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; +import { crashReporter } from 'electron'; +import product from 'vs/platform/node/product'; +import pkg from 'vs/platform/node/package'; +import * as os from 'os'; +import { ICrashReporterService, TELEMETRY_SECTION_ID, ICrashReporterConfig } from "vs/workbench/services/crashReporter/common/crashReporterService"; +import { isWindows, isMacintosh, isLinux } from "vs/base/common/platform"; + +export class CrashReporterService implements ICrashReporterService { + + public _serviceBrand: any; + + private options: Electron.CrashReporterStartOptions; + + constructor( + @ITelemetryService private telemetryService: ITelemetryService, + @IWindowsService private windowsService: IWindowsService, + @IConfigurationService configurationService: IConfigurationService + ) { + const config = configurationService.getConfiguration(TELEMETRY_SECTION_ID); + if (config.enableCrashReporter) { + this.startCrashReporter(); + } + } + + private startCrashReporter(): void { + + // base options + this.options = { + companyName: product.crashReporter.companyName, + productName: product.crashReporter.productName, + submitURL: this.getSubmitURL() + }; + + // mixin telemetry info and product info + this.telemetryService.getTelemetryInfo() + .then(info => { + assign(this.options, { + extra: { + vscode_sessionId: info.sessionId, + vscode_version: pkg.version, + vscode_commit: product.commit, + vscode_machineId: info.machineId + } + }); + + // start crash reporter right here + crashReporter.start(clone(this.options)); + + // start crash reporter in the main process + return this.windowsService.startCrashReporter(this.options); + }) + .done(null, onUnexpectedError); + } + + private getSubmitURL(): string { + let submitURL: string; + if (isWindows) { + submitURL = product.hockeyApp[`win32-${process.arch}`]; + } else if (isMacintosh) { + submitURL = product.hockeyApp.darwin; + } else if (isLinux) { + submitURL = product.hockeyApp[`linux-${process.arch}`]; + } + + return submitURL; + } + + public getChildProcessStartOptions(name: string): Electron.CrashReporterStartOptions { + + // Experimental attempt on Mac only for now + if (isMacintosh) { + const childProcessOptions = clone(this.options); + childProcessOptions.extra.processName = name; + childProcessOptions.crashesDirectory = os.tmpdir(); + return childProcessOptions; + } + + return void 0; + } +} \ No newline at end of file -- GitLab From 92be0f0723b79f984bf5ad2102fb9dcd074ab894 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Thu, 25 May 2017 13:18:23 -0700 Subject: [PATCH 0068/1347] Fixes #27287 --- .../parts/emmet/electron-browser/actions/expandAbbreviation.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.ts b/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.ts index f046995c799..26125b52a0f 100644 --- a/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.ts +++ b/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.ts @@ -33,7 +33,7 @@ class ExpandAbbreviationAction extends BasicEmmetEditorAction { EditorContextKeys.hasSingleSelection, EditorContextKeys.tabDoesNotMoveFocus, ContextKeyExpr.has('config.emmet.triggerExpansionOnTab'), - ContextKeyExpr.not('config.emmet.suggestExpandedAbbreviation') + ContextKeyExpr.not('config.emmet.useModules') ) } ); -- GitLab From e129461990c0527125264b0e4c24d97693239fab Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 22:40:41 +0200 Subject: [PATCH 0069/1347] [seti] Update to jesseweed/seti-ui@f78d623 (2017-05-11) --- extensions/theme-seti/icons/seti.woff | Bin 30512 -> 30516 bytes .../theme-seti/icons/vs-seti-icon-theme.json | 496 ++++++++++-------- 2 files changed, 281 insertions(+), 215 deletions(-) diff --git a/extensions/theme-seti/icons/seti.woff b/extensions/theme-seti/icons/seti.woff index d1411ae52218317ccb3d374bfa42e106da8ef2fa..5dd4c46c58c12024e051f21d7b8f946184a7f638 100644 GIT binary patch delta 30249 zcmV)EK)}DS?g6y!0Tg#nMn(Vu00000cQgPC00000wk(kpK7T|YV{Kt@0004m0007_ z000O$@Ff;YXKZ<9000Ci003=_005&b)jrC{Xk}q!0042c0000k0000s4T~ioXlP|& z004310000S0000a2fPI+Xl-0043z0002+0002+ z)}8~*ZDDwD05<@05C8xG9{>OVAOcVd5pH2^WdHzkFaQ7n9smFV=H5yf%y4gWbN~Q! zPyhe|;{X5zF9PoGZIcKAL4SV5IDvtcfr05K(;fx}h8_sb_<+HXkqIcuz{<>k6$GTY zrZ6}>V0=)^`~t|00+T?EAOZkRjSR2=0C=43)CW>jK^R5hGcbTiPLc!x0f_mdU${LsTu0k04YFn&=SNUX@*#MMSpBO+>J%|lert+ zkH^ZQJ#pPn+}z%VYfRVhcRac#g}w1mOeKvwq=$1EWRgWTIpLZ`E_virKp{okqnHv( zDWjbGR8YwSs;H)hhtyIRe(QNe1C2D%9NtAMk7=Ww4xWS)PkF|3I_aXD9$wHJ^wG~i zxDN7?A%+=YlrhGc;C~g9Ofk(2v&`|DH_WrZB1VQ5}yX#T*^yvoqL+R(hl(EOpHd99&& zouPTXq4^_2^9GAvHyYa8WN2@*p}j4J_O=?@``FOlHq&=dqTSHm4nupN7~1>P(B5Z; z_C7bXx6`8kRezVEbKQo{^%y$$!qB;1L+APoo$EJrZotsFK||+WT6BNNP-ECoW5iHn z)S^9OhI-?MdJ~3vuMG7j4fUoB^`;H=W(@Ua4fW;>^w`ZugZ>aaqQ188=-hrXs z2SdG&hI*e2^*$TweKFKKG}QZQsCQ(jcWkJ4VyJg&sCQ=3chtF|_JyJLrJ?qfq4u?* z_BTWA?}pkx47Gn6YX36S{%xpzV_g3QhNxOC004NLl)VX@Bu9BCnh}u^k#}b0Sy^{g zc2#vx_kZ+JXOCv4TQg`hqZu)Sq|t$d#taq+O9sSYFv7yJ#cg9`%a#q63=0p|*j&aB z42z5wY(48)EEv4@^1zFY%|0-;*@quKz*c#`FRHo+_Q89aet*&F_x66qqux<6nvSMBWI8!a22GL< z)8Sy3Oa^I&KOTWg>LgAR{8nscEQzI1KgD=7o$UXl@Z_-YWA1auiX6A*OFuGm7hc@J zjQmKXL1YTXgmKw&9yF~mb%h8_x0W5P7`9QVnmv=5%&2>1oxCxPtA=9)KBH1M
S zmw%DlgxFkTq#Df3g;vZa%|rY0~&_64keHmNrR)Br$YO(SMnahuL(P6k}QRlaF1ydhJ?vL)tpldiiEG z_M!L8Bx)vpo*(FS4&eEDr}`|^7p`nC5h+HjEmwN}%1w40SIbfCH$6n{p3 zJi=ifPbV;(Nhy|v?Cy;xh{aqErjveeIvJ?(PoQ=Ec<=0J(pP84SPbuw$`~YUU0nqI zu|rbqgp@p~8{)!%u~!A$b?y`Qo1tV5V`NR&%W*^ZT$6KRkqtAt(Q#yA_WZI=$@#JF zJC?5Nq%ggsFn%CHQH|Z$(n}$ifq&2)kLzBndp6}n6Z$nPl=vTXT>TzNEN0G5mN@%n zWFFccbfCX7ht9+Pq<_vr?Hc$ZlXN%*by##7Y83Q9)*y2|7*Bd|Xn!*8gWm1X ztU)i80-;bkH=Tfb?dc8u{4qk0G0Qc=rLC-AakeX~BM?@9+&fT>XnU|3nl)w?rhWKi zEvehQ`fNY-YKiTei5FXC!KLo$&BH5acbi3ZiMd@$YS1>r(w(dsRN;n=!82D&0e8~M za<)`ydMW4}6S=4!@J*w;9)G=hXn>YLrxVA`t64oPj8j)^o*1NM%fqG{b9rKx_EPO< zwBOX8(Ec-tNR9NNH&lZ*NT(-3A{uNuoXgKH>0z_i*;o}&W+&( zta=yg&>u}C8n_`oE`#f#Hhp+7*ti%j@JZ3@57Jn4dLyXIFdL*$*M5=C$E)z5iJ%2& zMWH35-Z)hio>xiz453lk5Cx(?*de`+h|@kaF~fWIdn{mJ#}1rd)nm|rfHJDnwAOP# zxO15usn$If2o`UJd4HN++-cOAewkHsNjKI(xX}gJMc>z1`=B5^&AbZWBz%(w;jAv&jyD|F&ojGCNM-l*o*YDEY? z0{OuH88>ZRXWmo0H*a3N(W^QZbEyffqTCC(W$B!oCV>)^fHU!-y`axwsbVqcRG)#@ z&`Sb*1EXmcrhm7Xggb)hCTcvR?08o7!Fyy*Gk{wV>3|Q3t-v%&cEzM(SPdxAt6-a; zurM7Vp@#Tb+PZb2v)*oRwjLE0^sPa4hq}zPs1Z3Z{2Dkjk0vqb%K+p%Q<|^` z7`lZlrhmnFsQ!jh{UwF^E8=M%j(@4UbFi3hoXJlZfn~*B8m5)7S?Uj>#Ji#n4_Mt; zZTXJjq~wXF({pRh|Mv-NO zXWMZUcrCx|H~Wne0Dj#;lUfyGTw@-KD&yw;ghMQT3x#i z?hEod9dns&q#)#NK4?N@WKclcb^$%7%a+?x0HmV>3X52;IE!2XK-; zV1H%Fy|cT%MuIm3jQUIvr_DyMYyac8^TN+i_VXZ{u1NFhMC!Z-V%ZB&B|+FZ2U*nJ z@&RE`?=YvKZN+9_m$-Zi`IGhyXM-o!@;@oan{#tFFW1WLsBEu1$on_tx^rAwJao5u z2Q5c#GfH#t&2G*(sA^Ja#9dwN{!`P7D1T@mxW}^lZR`rwADi?qwFBBw?FN+EVh>cV z6NHq?3m`bcHUfZLU{5H(3gt5Zcq)jAmb|N=s(_vW)7?O`o(=I1H6rzw}W-Bj`- zK?&Jr>?US0qb4O_MkQjZ9}chsTB6PUVH*dx)IfLFR?e_AVt@$S;QLG9`iE^0!V>Fc zSI%xt#pNDYmh2>XJCF3^=E-U{`+t>6p_7&ulUvFioqp-K$*RX^x2n^NqS5RwC{rnu z+k2sfSM19>JIvO#7JS(uL-eV0JSqhRj|Tm%1_TiPC?yY5PJi~bUNv#bwlD0rCR|oat(|Cm>0i{4si)gg~R}E4m z4P_1IkR4QiRUHe@>L*3 zO9CKU2tI&%nQh8AOqdt+rKAQEZti;tGuwwYPaOC3P8Zk(mCl*r>Ju$6W87=x;EO&* z^@^znR%klXkgfqGJXd#p0xq%SfTPW81|tV`hnaZ^&>2(C3;2wT1AmX0PPxS35T#Ye zVg7T>G{~*c@(nAlHv*FqE(l!;gEjD9QLh~J%u3B^_WX@eT)D=P(n$~cFD23j^j-!xqPyHn3;MPO&({a%Ztp*bzwZ=Gk-(Ahg{P8Kc>G6{-rsW zd;vC1BIMgx^arRKA{yD3efr0QodJ0AYi|(-FLiTivb%5Rl7HRK)<1OpJ1@JQyn?cm zU~qr=mpCsKWzO}N{4m$QOb(@M@4fcn>9v=1{6}Goeh3*|zo$sW99a+N!Vj<%2rA&{ z$sBki+3%?{^M5J<{VTqUx2PW&u8|tO9kkmDt^@id*K#8^tc|#cI(D}9yn9}9vKPrD z3YujbnKA)d&dc0)rQSTwb8a#~NhBH+2P(BZPDE_S<@)ONw`S#99(5}f8xSc^%h00* zfKzz3Q(b+=`qR1o%#H2HN8e)DiB$qcAdHyqsT7VtZ+|;7SoXPBYW3FpqiCG3)H;?M z@y5ZH1ioT>VNF^fBb4lqNf~(BgWB8C7H<&1>m%rm9Wa0E#3!9`4?iG0pUi!b>WGd) z`h6_n0iTGAdDujq$3u#^0A-0qBC!BE>_MW8YldPzr!van4G?4ul}pEmf~ez%>74ke zAGAzpyMN#!L1%^!thg`*tMQUq2;G*<*LCPj({USt69Q=G_A-br^`XG7CArVQ%IE=? zz5}PZV}bGbem4O>1vimFRt>)2O#}dVN1xvWzA*bA4&InVoi+7Jp7;S*xX2sv3QKU) z{-2&JI1m*MSHg3hM(zLQvFavJ(lUhiJvZq{ReyPuu6gC%%AvhV!Rsa5F$3(ntz7}5 z{QnEPCPgw#hU4M5n2s-f0T^}kV6m+rYss`@H;od2tidusR`*1Gxx29jcEWR|o07@e zU;w`#8y`MAK0@`w7mmh34Y+49@o_Qmh_ z%d98=GhKV}%F4=k?{9f|dB08H&@3&4Hh;z7B}xGP0Dg?rrwRSi!@u&@5B}_#UiY52 z?@n&Go_yz(KTW=Mym8Bscg#L=%_ScM#82yLmupX-+qn4;7^cZ^u0KN+m)ZlAU~n_g z%R(8lV!t%v1Yqcyip8mOO7Z6>Krq0@Z(KHTQb)R6w>r`2^4?Q_b)8p&T96fcp&2uLyJ^Hbr0bifVmoX0qnF`%n^SwhuhCf49=wS=I6mz3_RAF%;wax?ttUm*yn{k z`p5fYsF5}h!^K|-{>U51L$lky=YQ|hlaEe6I-PxBy3g_cRQdB;5uYzyc!E(6soYej zzct#2Qj@)~)NmfBQ8umHfx;?OgYk|rVE2XJ$506L<`i-JDo|c@xjfY)#(wx&8(F_~ z8)GRCxno8~sqW>2UK~WR*<7hs!cM7{JKpSXYdOG_jJZir)>+;GZ@kp3Reu{L_7{J? zaZPU(VCydMaSFB~iohuVRHp#l%O$XVUR^R_8%{F=#G@M-pt8vDOzKo~ur}SA6lPlM zGCiNY4?R^>suvw#=4^XgTdD6))u=L9*Om-G1Y-%SMCc)LgcFkf4Cgs+RAjzW*jWsX1BG;f@UL(R1k+cdQ+E z=k<#}{5KZ*x*y1>(NBB}JhofP8s4N;=(JfKt#6hLrkeurJO1bB7buv6RQ zfIW*#IOG`p7p;R{7SvE7!FANeOljLZ8VU^`<11TDuB_>Sm#(?t@Q~~1S(-SG&bKC; zhbPyGZoOvEA4;q`PprV~9S>Lf&3ZT)?i|~k6j89;y*8tIqju%O#?0vFG@*GImrrDt z^tl{^V2-n|KmOo@kAKtn@i)KuahiVgru*)@>7xwZ*nPKrWDgtAPqT9{!pq3q7h{yl zIfUvjBC}X&7)z$iN54U69r~aNX54ml(Q9n>uIrDAwZMzQ<=!*8;EGSJ1R0Yb2*&jN z)q1J56t)`O17}C8X~-OZ>EKnDpFe%})SZ5@wmB=C#A!xBTYvkW`W)BJT&mCauT2JC z4e8Hfb^*i4a?XUtBlLMAoUFN2 zZ66GNe!n@l8vYMzOndcUn_MwzF2#;a{k)b$r(G$YvfW+_+~h#j_h&z|*VH+=SYk`i zVy+nrO-nV+B!BIGHtv!VDYX$JldRn@P21#KvoF(~7u-906yBdX`}(%$ozC-?M_T~G3^50sd`Q#_bG2*@LP4~ZvY`*%{voGIw$$uQAf1|lt3HZ1+orAAL znX?`PUta>R|499^o3dN7dv-TQ`Db6Vv-6#eXZ+041Aj~G@r!4!U1j8!M;@7db!TV) zen-I{aj16*EijAP5$}(uS<+215Ig$r*<0WGR&w!y*+(9G?6KKL?z`_k=FYx4`zp!5 za@UvczWYm$Jb32JgV*fc>l5sQsuxgt2}&=UmbxU#WYQ-e{^A!Oewch^cKC~5B>zf2 z^o1|N`+tWYnmzu|{PVuv9b`w*!vhSJSzk{3Q}V5gpMSXb$xrqk`Y-IrW6cLYf7@-J zf3Ue<{&VbAPrUrn0!>!UY1C2mwdRda!O3l{urWJMys=WmXP zZStNPa%c`7!8C=mTVMM|+ZOl{%;5O8+a6eJlIv$5X|&BC2m}Evjh?fq zLP1b9Gx$XUu-bTt&}|Nm-3Bb|*x-~>(*Sh920&Try^PalNr*9HUd6S#5$ATvt=0an zUjLe@8({Mt9@X66q|zkcFbx4v;$cD$>3nrvjpcx56Ny zY|I4Qld1Ti5yMTtQLFv6$$;{69##C`rV-JxPeix4DEYfiwu7xOqu(Nj(C zFWg)*H}9E>4&ZdlmWpWt&lK}mW;U3Djapc+9SR@}i_SwbM+rQDuF108O{yLPdVio> z2*7NaM@*c)3Yr+1zVC2qnt<;(IB#ctDGyx1Drq?gYCb2xKuoJut_7~y>z?W?>FkOZ zo_N|*Pd`76~kN+y++$8uX!uHQGh(#oAA6-zEl0$(WoZPbbeJKSEwaeuBK7+)v(um{#=*cA!LX+K3CmzBjbC@+qXEaPw(BKgqfp*X%m4fTBx0*x=%@XUF?c26A?B~})UmET*7+SMhXO8E< z?`@6?f+>K%f}9%E^IVZ|mr$w;;Kh#XTGU_?2)b@k*5Rf>0YXtrP=8Vb6vqj7IeC}R z1>@8%$&Ll4A#$W?dPw#Kum#Ho8Qv)Cyj(eZezR#1E2>SsD{AE7}c!? z=Ygqvx*=R4be*s7UUir;P$onFdLW{dCB?cI>%4fqU$2_7S6(U^(hrZg0&F(i!ljny zcs^KU*EVpr(9>N4YJZ7UHaN~P2nTeInjGq1!EW*Gj$q_1^S&^l9EYOpc@{G%4;Wh;)Vl5Lx=8@kNd^4xyd;D7}4b-80YPUJXd6YL#hEVQ`J zbg)w*bOoVO>N@KP)1qKExpbk@1HlbYQ`eycYGr}#*QpaSoPVVwbXH}YbJw%=`j(eC zd3Y*vbSPtiE7@&MRvn$m+{qJ%^Vq0*qGE8%?Y7|Tf$6E9&S;?HBe`JA3=_K(RI_oR zqh&UsNv=TCoAWBrHqI#Zn5;%|%d`C$T6z~hSW8mM8)4t|E-=Ck7<}Ox7EaH=*TfV; zfFn8|(0OG|&wt<&I@)pJ3x;!joFWD4qrXh`l*@4Li(0CKfCYi+qWU(Y4$vMOy81Zu z2eXAvsZ=4bIrpc3%Lc&1tKh*mv{z`a)gI8^t$k3_x|4LcNY>ygYJ%Fjh>&zqag(^{ zO?c-h&J|1>BG%erYY8GIvJ3QW-eKh8jJ{{=_TESfu{^q&2+gn z`-Ba>7soani=Ybe9;ftws1QE zr~nZ{1%HQ4CzP{a&-yDzTQrN`(TK~mb7-~yLsY=k;8#qZ#jeARTsADd;)Aj}l`j$x z{IdM}(+7%=qx+A-0-bc+yyw8XCH$N`H8MehyR~e|l9XAYB?V4dJB_28<>i)d zxV9{ec2j4h8|zCG%QgJyR20{|a)0c_mQ3Et4piC)i$;+~l!i&SQLMMh zE1)+}51)g1fQq;Q52%+=?m2tdm~Dbw)U^Z1ZnGhBdGPWCa0}+E%!%s|aL=?Kd!)0D zu{Cf$tOrXfdi+my5ZbwZnPe64tIu)2D~)sqi;Ta zcYkLooxShvpMJ;r)t^3n!|9U;R!`o2^+t11qB-2h)pr8MT-MHNFGPf?qOXe(^*q8b zZGV?XQBhcMQhOomL@Xp%ktB6Vr$3meNw34CI~>e2*Q9C_crNfmDhxhR_Xb}{zG5<~ zDM8C6Xf)?HXWddv$*0ra)3$VG8=>UB&wo=eNaQDUFf93?MFlgZD0OPS2|$5SHvlWi z=!s>pP}e*eo(1FIKL_?G@_osPzIp%*h{Gj!f@u{fG-)wl(9(>WNuxR}%AIC!ZBSfM zl!x_Bwge*&5(r{e(rr$sp3yIbPU_hVti2ccQB*E5lT}XYUI%SkBAHM4V1QgfKMBW`16OlHDxjo-;0OaS0SB{m)EHr`Zjj8QNApO?-c&afL1ZxA zA#z9`Wiqi`3#6RuUJy6c)RrSdX@4?5i?d1+M7j8C$+hO)_ejP1gp?&s-NS z1RwaFpCw--%#v26EOft`WgU2sC%{936)53QxmJSth2SwG&J1S9VC3CM2Y=seuqcOt z#CTZ31LEaq5#osP#MdJZRc(PswWM9K9LvdzkQpX-@}OL4S8A?Yx0uht(J|cwnK9Qa zEAf*M+`n7O?bJ_|<21tb%~&oH5BeiD zBZ35Foc1R}%z@gQvhVMZ{eP(6FdH<9x`w_)xMpCl+Xb;m&$k%W-Iu->`YdgAwy!*D zV>k+Mi6z;GKkUdGsoRZ+P2QW_lzyeo0rQ984&A8y66nMB?l5TfjtGk}BZw^Da>ouBT7T0C#OiU+fWwiL z(%8?>pkHHG1NW~1cU^&=(LnosDvI$DG6V;t!o&p#I_9VqeTknC#IBMF8*L>}>M+1> z@(uPlN>=AJKm_R%pyHj^Eiw5xVJn0__N+VE?;m?QyZSM~9;ftiMmn#5@^MO@fWP+Z zIvbBaMu`c3&zZf45Px_-e)FYR&!EJZBCGCr-D4MWTI-pcTry%04KmB3q!G zFlt-Cspj*0gJ}j-3*Wa!(=9a9F;Z>iZdI-u4tO@{t2s#JuGI&S0f5J15zs~7OJ4|@ zq4N$x4)Um5ZKokXT&D!a zkC|Z2I&lSo3&Z@JrVZK)py)(Xm$&L=z$=LxQ27wC7)WW}t)F)PMsoq*I2 zvw6t`#%0{bT5xWq<9Eb{_rR7@d?*WO(6|vd(;Z2(@Sz zvppwMkxc>g3OQ%W^Te>Zi<7{hRi2jeh4U;=`YEATgI#7$eq{WtE5L-8>rof%dk~qH z&P#zg7Kgf%o%PYncqwTBsk0_s+npIrLo{V~ttnV!J?jOg?udw;Iehmm9(|V!Zpzwa z34h5}pKJM|UJi2RN0wdkb?e^d^2zquGr#0l64L}H(VO}g%@xzA8Qo${gz}uHJ7yHP z$(`n2UYbY00g|$zU9O$hZpK(&sf`o=*q~8wm2`ZHW)7M<_re$z%`ojs$vMzrbrR>; z)X}s*XU~YvM;&zkLZ*kw0IUmhpZqi({C`~&v>Hq}*N=nOjC9%o#0i91)PRlwbp>+` zm8IlH-AMro(Hc0k#PZ!F@O}pnjAIeD$_eH48&Ce-1Hd*nY>dyG0A*%zZ!OL)X2Aa_ zh$k5LvyqUyrM=hrh@U4E`LsU zwo854m(VN2Qk%XdYqvMr?b+{=FU_{e2k$!Zh8L5;?204gUh}<6^VK(|!djhPduV;|qNg2;FmHJF_^G2u zPMkctd)3L87fbZ2BRhad6*|3`H%%+5J#t&tXstC`G`Q;I)-lgCx379mGaB4@B*E0POh^C`gDFUm2maHem=&}RfGXPPMEO-eeElh)1?0ei zlc#;t6R zdHK)%_(`%BnVn62`_QSEpI0ESSzLA5$)m->CatqWz%zad#|$&{7mGLW2h8O>n3>Fj zoQo51c%E5?juT9+!cT~;_OkvJK9*=f6lY2iNCAY#ly$JVs9=M6%10l`2iz6|X?Tbo zG?U#Z9e*2pMkq|(XRKANH1(ACDxJn!vl0pi{GKkTSgKgzxVP;HwtDVNNw;K~*oN(z zwRNc%CL1-REhEuiMs7>)-Z>fgg26Kkig)E+TMX_KNKQhBMpk&Tcg|C4f?y-<~^V z>3QIlt2k$k%zCN06|I5~fQRaVx&ZnZcpH`|u zl<3g*mKaR>BeG8_fNFG9CXdK)(SS-T9ir93ki>9a2#2OW9%NhT;tA*}F!=}V9}X`l zEPvg=wK6gua|~|c%7$XtpqW|~HB}UIZb2v0WKR@u;#Z}`frvzLApmpklT;L;Ig#Cq zt|R#F?avCcd0O1O253-lIuGxz@`JGv*aX!8XcRIuc-9s;G<>K~m-SQ>7KL*<&yg4w z3IXi*#a=fICIfY&!Gy=1={y5-{}K3rY=5Zuo{IW+RH78dkufklns8Ms>}fR?*x+Ie z-Jxgmn~bDERRwQmZ`8~-U`8J6~|Um$M8#*(J`7q08R!c!fhKgCwHU5XobMlWq)B@ z0r#&NQPb%7xWEFOgz2>WsJVg+5e~YRUO(IkL{0A0+HL9(0KvfF%-l&a8!)ttn$(TJ zdcSazk`tRIt_ou=JjT+QlVrl?hRrO`P_an6-Hg^EF#wVtujw)s&3-$=lm&pz(z7Ku zbRk?&+ktRA6R0WB#6y%}kW&}SvVSIcYUkoSv7AhK=D;~^rCZ<@0sT5| zZMz5qlc#3N;XXW`eH8;*lmZBL0JWV-dOX!x9m>+A2hB@Y>wb_#F4U7^a>fePn{MQo zK!z=Dgp3%v6p<4rmO*sOiR)!=_FwM)CVPc#8=mWI)!}w-FAV%z8kUxG;C~5WGqQzc zNv9T+;vlrZ{ii@$0VAeQo-r`n41>m)p~`e*g<_tb3fx@anm^!bwgIEyGA@XOb4;qG z9s+ngJqs`s!*4LIP*mz3wj4a0qdP#bB?t@>VoIOSgl8MRAw$ctJu8IMURyx*eQA49 zBF)Gbjsz~AR3bAHY}UkCLVrOpaD(X|95{qYBti*YC6-F_{S+n1!m~Kjh`A2|t{kx# zR1)LR41e+TVN8Dqsl?X6_h_$P*jAn5t(h@_n?|M=r(SGf2jICt26kj7vgCW@S7&d& z<(mt<`w#TPS^yRi^GxFT+OVl2bmK*q^GKOIR4_SrNw~lel`UT6w11J?u3u^&_m^xl z%4=TfZDF}uZZvAe?N5Em800dvleAh7oaMnrZ{>8omB;i0-*{@#;`|EJ4-X71X(YYO zS-N_#8=ZjWilk$kK{V+PnuWo^aQn(`pJ2}gHa*c!XxC}CYA?|KoE##j$gSkZ$?M32 zKsffo0rE=X|iMrpx-9^9Rf$Y3in1=}={s_J1(V1w$*-#j40And5}X zrJRnvr5{AhtDwHByQmIRc?wxiCFx_ZOeLJ+;?i`o!Fz;BFqm_mK}Q^4t1 z7jT??vAKmnY@*tmb#S%kbljJsH^zv=WHBIYzOWOg^W(V_+@<3ULSIP$0JaDKcq1!O z)L!_}OThgo2!DqxnSfcS0ouE2_-QK2o^VVTQF&13G?a#p{Ym{Q7rJA|^j_-clF2mk z9b8BysIo<%vivoooX8;P8By#=!ULbM%F5+dT3K6jGLr&q06PL0DK`SpI|~4=yi#Yr zZa8XU$~;;Mb(#{swvquC0F{#-rh`!$gp?XGa#Dkd*?-%?vsjo{3_q^x3vN204YeRT z&X;ghW=e>4AS>-O{gP*bwWh=cW#$<)8H)GEO6e57?c?97L=kcbTS8~ZGkOxd@y<4=M(CR zveAI&5PzEb(qp)&z`X`;rb{lN2Xx;FyrtYSTl4~rG4DYpRb5J`KW98lT$_8yyCl)! zsV=9f0Y=uA(D3InTv!kqWtRAyu2I$yFoMi*L;0)Bj{~AR&!#p5o<_hNfd3}Koc%@& z_Ym?$Wk0Z_FsnDOY!};bb6GXK92|Sq3`$ftO@H36nLy`4Ux&V1h59-&X_eZe6-%!| z@hf#`H<(Xff;D%%7G^wxJD~U!TJ@alGqqF#I>2;rAi7!P1(Z5Eh#Tl?X2+!Lfbr%m zsySekWfBso9W%_pwTy%H?WNo-K|77WsR4)%5*@pW>De7-9+klJq_|oMS##j(Y6YK; zj(@q7)rA>;LkAPi!eXhLLZxs7Un6Yj_9oQjGN_(j_2B4-$W)kc9!TxZ%|KUCUZ}oK zi6wO1sQONckbfq)Fw;rGFbx~6EGadHM~@8UUalIG+7z=ZB9#!+8!3x^m?XtKO>lqa zd>%R%saoZt&SOA+RCGHDPO&Ax6UXQhaDM?RF0ERi;W0W1%)(K*>FPGaueWfbl5P)k z7w3iu4ZKDJyB7K+O5Oaqa!i9UV|M`PiI~23mc@ya54J(=K~#Z3`gUR#QB;zf>xc7P zIKCm=(CWbfBZ#|p=sLd5^Zf9IPPf<)8)jifoeSf9;2KS%8wZ9gMLjEYMX*_Bhkw^M z)%nEsFL6pj{{fgmuJxdIVwG((S|=Xm`=2`=>3{c^ueP_3Z@1M8>0SE#z;_*fetYjz z3qPpOt=9J6wDDDy+RtC4pJ6)YVUZ*njsf|y@f4%OB)@$lzw@DwzUQ6S=Zri!d-+2T zku>cM=USBp;P3Ozin=}P7&{z9A%me?^9zCUBHQ8XL`00&Yuep|U?0;ZAE{ADi zm~|_+ODO|eC_S!Mqm43f*2r>sxC2&nOc}GA*cs{i~!07pkMh>7w2|4w=(8&6Cj!mM$#fUX9~6hScJaZC|`yc_wWf0 zZ>cx~I$mph0;kdmJ&rR8tbd?44Ue&IwJ;m?byKe`A6yxLF$?yOy90Ks)1LAC|jVg3kasutL01}!Ohik2Kr+ecHp?`?Qa1-&DEv3GT=tiaA}xg>sn8 zJ)U49444E3LlBbSa+L9WVb%~p!+csa9!}@xV$QR(e!7ROFu@B&ce+EBp;^#wl>&s5 z4ExiCY1Aulm5`FvRDV&*@pPmfm0?1;DwQmjzD%a-M#aLAkt|UJ6FBc;+YyjgfGLxs zWDqA!(x8KMFElxi%+Lv@tzD3HX=GM>ZR|EcOu&gDIw1l$!Xc^~?YII2tYS0fCem_5 zfb0>9z{^)%6Bn#Feuk@$fB>y-R+b{4Nm~ZO1=mq)Qau7PP=D_(S8CwJeg>VXY35-S z{0K-de6^k6Ag0{-AOOq^OD4-@$lW>1DNGif3OAa#9vvTOLM5csrCSro6LDt>#sSJa zY!t>14--ZrtQiMH18!Qho?md>gh>j~Tt6SSG*Hgw&BN^AofF}TcY%W;=H9c{mvH4Y)*!ESR{ zBP@^o3it`bNSiq6gEU95#KYC=Ca9yBJ@YtXJ4Ndl5YO{zGquupHuH@ZVGd3hfriRl z>;%XC>K#=O)eHNv!mkpLQm|N8lBWSvxQ)Dmyqf$nd4CuA4e}oHzmkuU-zC3CK1KeN z{2BR6@>TM; zd+Gb=`+w<&=!fa=&`0R+(vQF?9W=o9o)^gmIIMI{5ZfNnS$Uq;68d2p1B4igO5 z4lh%4c7Vi(PzV(1C?dp=Kqt0OJxW)g&8&<-qz6Mr?vN2DQVqVA<)7_ny)PHd0d41|k{v<~PmY*jOEd zBE@9>U@Q+L2X2$9+sI6OFIgQI<;!s& z8-LiFf@R1iXs^&Hs2hR>;X^2b8xcW^JEJj4M!js8O!NtASba@ul=|)l~a7lBo@Grz%rp&(eD(TOq0zq zUa~nXhH~*meICGzx~2Mr*B&LC-*XIal7GkorxC|K!6Wm}avMJ#kyy4mXHz?&}v~<{C9Ow)6PUEd{GTl-I_DfUpEvjf78cSwIlB#(VLONhD z3Ltt?n!3uPXfS5NnKht5ktxrB*%B`Vh3vgc=Z`I@;NpkUuQQ-rv#+C_04qiSOMlKD z60Fb}c{flXV>X5doYFD&vx}JwC%{XSQ(#u~BNCjxgIh8IiNf`pc|b`AI02eXsK#4> zNs&*Ycb?sd`Hde$GdUYzHkCZgkvV}$`a1f08JRjT#2Q$roADwSLHswr2@qYM{hiQn zr|O2Uf^VN7+j#rg|E|;D5ibOGd4ERULdnYj)ZY&!IH&YDJnB)dL;cpb+q2_mP5@cp zCr&Z)e%iR_CHOQ#jNONmRKBeAtA)i9VQLhIV}a21GwgXMdxZi%KvQkD63I1V!Nd%Wh;Hu|ZWS zOZsr3-o%2ylcB3qj)uQi(-#u7hzDSsQw-pl3Uu)%>%eh-7?Y~$NybiLU~-46ijc=( zK;-NiDqR~G*RwHsQOen8bAJbiCxXEuXCDOj#=gL39{T3PT;)aT$2qwJhxJ`33%K%K ze+;gGqUNK5iBIA%KPcXU{#K^g9eS=aos6M@v$sop&g_*f5I6%M{Hs77NXi}p$cYj} zyU;Vg2sit$FZeN?epNBLny4{MCwh$PyNZo|3!eCv6I8#3k~8p-m4DgVSr7-fd6O}t zw9D8EV@~A%9bBDYkTbxG)Rhh#XBr=GgISi0(-etUEMip`CC+8cDe zXs>TQa@9S*_{yS3$yG;pAGqf#^4ZPfsz3+M9b4a9Z-ILYIJkdSX;{jJQ+Vx5vU}To zcU^tgeYbsxx%tc?le_Pp{UP~Q{@8+}%~(aPd@K!xBygG9E`MS&rLTS2EgzbF`}xka zHb{Ee2FqrDcVnPNVs4H z_!;?*6L;LG6c~I8<|MmWdhC$pSDmn&-LQNxjiSr1 zNPhGuZok05hJTv7NkYq^;hJ05TA{e@dehv`Q(_0{r?gb7Xbo*uMS%A`;9zp&20)upaq3A^I*`+3cuuFI5yFO$I&KT{-Jym#f5t{8U zau4x}uQKlAo)?xcTD}=tL2zs(XQHt_?3;z@2To#ICT4=WQPKskAv`;3w5!GWL*r&Q zUQVZ*M}KtOAI?fma3W8-j1%c3V0UEh8-Z|m+RcUNbd09qacZZQ!72C*vxQOMBKJ*$ zo1D45if0C9DC1JP6WOlLxvX9qCkcA8r1iDK+9~Zvka=OOwT|)av4UYmX}-UW%DF3z zkY}~CeiAMA$Jn7bv8<-k*nC)lSphv#O0|kBa(~rLaP$uol^tCt@Psj~vj>Fr*%v-C2%WUfimkt?=uuSg&wfi8Tu-&c3i*J={9H3O^C2YFFz z>)T^q;6nTHFjKFoY|p=|Z@fr`_x#B_$xEL6i{+K`@BGa5=idpYtGB$ewtW3}W*=Nx zp|AbU+RBrkefi7Z`OdXZ5AJ$7{CnrxHGkUw*dJYxaBT-!C7sO zCanX`?285IIi1$ZO0)21U+7$lhh4^`_Ve2BA;a&MMtj)_0L$Y-rI*C%-UO`LS${0_x$Xw<{ql)f(CB?qtaAx$`{x2smX8TC~3S1LC%+MDYibqz*DxT)WgAe zos7Fv+;(if1WW}QMW%M+Q7MQMr2fTloQ%LgO_0sQqqAOrR49Ym6AQjSe=ZOjp^{|w z7D;1tfF0EJs;QRB%o3--O+N#}0DstK7+me-8QY3!3j>(ABVAnXVy3<@On&8bacx%BP*%6NeHUsdS>XD`mCcvk$Srs z$Pz{iBnf?+`!x?ES-AZUPFy|=&(Wz>b6gWVYGmRx0`9a(smR@G%XJLT3V$WokSEEz zayL%^?*im7p~6in`Dt$If#l6+n$%_u$$Z1d{S6%EKEWfHAfrO3y?OG1NjvaNl3&*DO z*|O;l1-U}o$~TMQd`fS=FGK{a3gfM#dCvNL75*1NFe)80U88z8;D0_3b%W~(U=3Th z95uBo%xoPxwsX9bM?zYR>q4@CEwvjhc!O^0h3)|1YT7Kyer}`Nyd}(z_ z2xc=~vJ$V&K2Aurf^%Y)p}WZg0K80Gtb))GMw`@JN5WH_NT+9d_NvWR>z$Q2VWtet zz|HGnr(g$$I0pk3+zn@m?Z029o<~ ze^<4fVm^lp3ct78<(`#k!03$&HOY!o7hqg5$h?;mqmGLN?uc4H>M4J@P(m@9UfO>M zj{)F%#|Biqgqdu17Mh+ptY<+_L{`TFgrHX{v2RnyA~cAX;#RwVFcp3(gIY6kq~|-H zB6~EYG#d9osdS5CP&uF+)Y{&#nJY3L9j$_Dgf93{#{o0+hL%DbZJ8)C`%*y_HYsAJ^L;v*F;5pvq6eGF?4@acps-0(k`4#Qam@B zXKogzn0+YhWZP74yNB}L8l}sh;(gr6MliP=h5^+x8H!3qS+lad0_MPMx`3vjF}~?p zyf^zdC#mFlL+}zK&Xb=O=GQo*cUhdQfPv9BmX;5lTJh6d(i|<0ZrLRdtew-TBu#0; zICj9U@l@j0%{qVe9)_{IlTz2WJK4ey9-v>)eo=e3_S^FvoK(;`+uM?4VHQ+W8ja1~ zHe?H6nWcLxjq$?qe79Cy(2&mI{RjhN3(u3pSZbYiltaT66hh_t0Wd@FyEES?7BO#} zsfD@)9-j1Zhu?)$!z)u&cy(=HTBRnER&kTBKNjTS1{c&rLfF^!9W;G z86}eAPB?$evSG-b{NNR*uBbagmJIvAQnfWQIqoNd>mO-k`WATQ_01~{hvN!uoAdg? zr&~TJT)IBPpxMusQymhXrJY?l%Bnh3->9u1xcgBdc+tBEkrNjKPw zxnV+8%!Qrmvse?Fg*oBYss6Ac#ciR7=y;u7!?LTP$QF{!Y zdx(EX5HU5?l6B_kfO{Jr7L(p|o=O6lTZ&ex z9Y--IMW!l?Fd2KKxxcjuY6T`5(!qSq7AnskfW#NPL$^1`=E>f%m~I{-m%faSk|Z8) zCgTbH)EV0-MJ3Z}E~$(It6pp^H7s4N4k>^BlAEH)|=!jICf}>Yl^85U&VhM--<4Ai^V3aMYzxIB{5b0EujR&YNuf{_kVv z9#}NWeT=B+dTC?Q)QP_=XbRBPw+{GDy-K>5``p7tzW(K1QmMJY5*R(n!O1&ZzuKP= zatBs*DF-m2-YXcpp#~x35*N_eo3wvWMF_NL*d&+`(DNy75jO6t9lA>J_m|%$&nCb7 z2xZSA-+uHt&w2FxweXMq+{d5&9il($(eFIxr=Rn#>t^<~dp?FRLp!KV0kypVS6r%C zx=K1#D*}guqbiqOO)5RnN(pAvFDXL?C{uz2^oIr0USv=etVE>KP&RRmMi~vQ8M*VTG=ocv-$4wN{CPot` z{jtg-z`2D{Z?w5e)a?MhjfJ}Nbn%4gsIO=tF6K?fpx5v;c+zk(>JNYEzto1~@zMTf z)%5IYDYOJ(E_ewk-0JncqZQydPksw0K2XmiU=NZH0GL8RCP*bo1+110#lu$m|P78(G+Z@CO_rY66~~ ze*{y<7^o#>A-N7}6X7aDnS9waSqKO+a!E@MI247dd=hFJAq{Yt`B{QQO~4WMW)=yk zDu6(74TARov5Ij8F0CdKcY3)TBfL^77o|4HXB#ZgPHA^)KdyhhL3+cJZ31 zHKIjlFSM{&SvY?WsA8lGK178QIn_Fuc7d&Rry$Bxb+ku6AR1X#jh8aq6Uwh`)`{pv zc^=a=01%DS%|y!8TAqg)fR;h6)y%34U}bG+M`;>4dD!|8w|(iFAd1Xy>Grq=6j*vd zZA{Ox0K3ti zJ@xXkUy(u6JUe@wU=p6to8>rhG9zpWw)AQ@&*FiJS!pCb5Sa!yq_kuXg72O=C2}Ey zAJdJJfk|iGZGHAlc#(ev$6Zk-Z(#iB(PheQtL)3%v4N8Gc1}31lP6mV$fmV_ z(!h?X)O&wHV)A}-V8yO9bHi;fwOzvn`6SdG)O3f|w=4!7QgLnD%i{neg5^Q#oGN9d zeo(UIgS7!;gQjqOvveTvL$k{zC3!EgN`@KLqTFwB(7a};mIPou1G6mBo@xDsuxoA> zXCaUkGnRQzoG67Q>2IZ#01zdU+!T&wld(}VWZ8fHHx1tH=%Dm!rLjD6+=`!d+;r(Qb1~|s{4dU0u`j=$Y=`uAbSM-I?jFRo9{`u$s$o&8B$6b|+8~HR=RipKiUR+#0k*s8HFRdBJ*f#R1 znmbEHTzARwThQuEu)DK*^YWD#v|YJdMu2n53g^;u;6Q|Y;4-fS8QtY_GDieXeyD%u zj@)=NHSHKp10Pr@ZuMlf^R^Dz*d(Zy`Un6e>6X^=*82MPn8fX_iYFv!oAmqWFTKD; z2tGVi%jztUNKS;K!f~(^Y_A+_9bQ}sEw;T$zKzv}c!~Ic_$%>`;$H!(F6(kh7KoL| zhdUCvZKTS`3NTn;%*ZwvwiI+?R)>GqDkHCvR$HfU7sY;HICcxlQI|+%q0W;SBcnoR zEs3D3A{7H7>^e5wu>3IZY~57Fe00 zD~=0}>+X)aoHtVfTkZo;jOj2^aK@;2Gn^na32x$!oDQ+TNe`VIMYJA}lCXbHIwVVe zOcoJ>$tPnDghC+^IzBE}XUk>I!3nt|mL-=~!h&(e=aY?qJq03NV}S6fMrN1GV`XS| zw@gIlMcVvo&S4sl21mIJ%HeW3WwvgEg&0tQXO8H0$~>ddVSxn0Sr7`!l#o@1!0$$h zkBaNDjWZne=sAX0HP;{+kL+KV+0``{+l%H}WuC(Sy#=)XtU>;NC|B<9hG(C$4 z2cZN3!@zUm4lx9$>yU<|ixz*7Bd8JRT?1KOXpcbbfND~supFN<#1Ghlch>2Xxum=r zpju-OLFS02s49O9D)DTr*2uy^FYC*RN}bq07|}y%Aa$)UyU!>m*ENr{>Z(vXB#r~( zFtY{=73@cndM&YB_aACRPpLFeAE{g_>z0r#z?%JF%JQa;ieP2=w|#WwQU`yRxrAMoE$rnmjz}zKNF#kf z%A;fxC;xCQfMH{}Ego3OG@^|{Me@8>jWaUu1Jg{JCbR>OC~Vxsj}}+$(2$?)VCBoP z-DK%RMk<-e9jPEpwQUC>X({4fd)URa`jB1KwuR|UK3;~%kAPhJuoh)aRB=la5(zY2 z4EguQb0U8`iWi&+bhKRZ{#`O9L#)aQ8MsT`fmAbFL4;J@FVl5G z9OgaVeUPFO0r3h}>uh0shHCsRQF3K_efhwa;~Z!my71$hO*bUt ztr;98e>n&@SBVYZdazZsWfFHY08)L)&pT@y2i9%NSha&~uWp>cMZUiD7Fx|X*=QU% zc%n0h5`6Kbc;3of%~*4xVw}0Q@5I%s7rGfqqw#z@Y^DdorZ-@WxOoRaa_W5Es^(Fo zoRxoCnq0vu9aj(lLW-r0Oom}QDyu^#@`o$s z+e)mBGTqk557Fd|$RY}l+%_Oj`SjuL=3KvJ#i%hAwe+Bw98K1)YAL;N*TU(YsvGS7 z7HNg_blM)wt+h!sI5hS11MO4M`BlHB!uyqqIN_A8zh4EGZEWL_P%*!8zxGjkipGD6 zo_;^VbiJA;mGaj6;e^}9ayYg8ek>+?u1}}hdwV~?Fc?%$0QqzTd`@gF$h<^T?*c87 zQ%R7+Tu%BvlA_6$n*Lxe#*=Pz>e6Ioer|XRIUHVw=py+jJ*~;{edb~H{EKOGa&b#v zICRtPH*FrKm&0zc~B%Eih{5j#W1CD+9wqsVaf%$SVAUVATK#{A$3HuKoH zO(%4-axJT{f9QlOhxhL#UOQh%Sq$;=@xWVM^#ZxL`(-ikg5a&q{jYYf3p{@@*!?oT z#W}(5U-5M#lGZ)pe3`xozW?>Wd*~rLH^{1eU2(G#JYx?zKUPlQ)uA#A0I%VDucK;UPb|J-Cm2L>^x_rH|G-QLlo z;;!9CpM6$r?tVpSVELck9BhBCo>@D+c4hssO7o;u*@kbDR>-8fCYpH)s>mmdP|@WoDSYTC#~afj@!ZL(qoOu^XluPQ zx@)+(=8`E^Z#$&?!6tuny_BZ!-P&~%4@QA2_h_H01(H$cDz}!X;Ik;IeZ^C1nZf=h zDz>4@^_`jO*%Y(wbCzH-Z;9D{gS}^~%com@>_)e&Zw>};dY@+>KlZb)z9ZERc1~rU z-9FdJHfl&$PgjS{wf4@nLC{3C536@mzEbbkU$8p2BqF~xNA7?0ORu?p_mggz)Iwi= z>-^EP&wup|Z5ll5({H@(nwzue1&Oqbom-#0{aiiq5<>&7%Wy^QzTkOhUzD`_;Z;2k zNSgLa?bwNC9wNx0xiS3JBn{#QyPtb<>#d|q?!=70vd5h5Em4g%!wc^@#{a)V+TJlZ=R3GZd{W;=eyC$Z!v9H7}j^w_2fy-CE?v7WoctqnQ-j&5Zyl z>Qb8e?vu$uN5Rsg|KyC2^vxCzj%s188jz)_A}^$lgeEeR)#EFO7mk6}g@#O?-5C zust7b9V>P^ZF1bNpH3F$oXpMNe(a1Z<%(tZlvp4yp;mRgKxopNN#{UTx8061YE74=;NLkUi!^aQYskZmE2h z>ck0y9Kuo#LAiU)7CA$b%h|fXqQE-G6&n-Yf0+U{+$-GC;FW$}@?{v0G8<6!M`8oE zLO_3BW{|?gXlS<{EGNMrEE>&V*;*t|&RLAR#x!+7{`aXuT7Xga$YvzR^V)5b*bPo{ zDqQlWMOM^mQA%d2IeFdapmGcMwjJ{IYGF`yauoACc=hwPY&%-4JBtpN4%JORwdKR` zl2Y5(t`i2*C8x_K>!;~@9apV4R)RIUv@m~;){D`yV>hT>fg+Pi*!`;y9@MFqc}a~% zPX~k3aVwr2R*U3Z1Zwk$*N8pDLamdx2(Q~A$4)19VhwIn0Ppn>gCzrdo`&9U*7TzG znpR@##gJ^i{dkNYQ)hpm?n<8ZdnTLWeOY9E@z%?i#h+ci{QcvXFaO)+%kuIo|Kfix z{ED;m@=^M|qLW`NpCrz5E1k;e%1=Qr4SRi)BSw+Tj4={-QRuMWHN$ec9TjPLa7obD z&`q58%L_>TSuv7nx2~t%Y0h`((D<^b37KMK#FKUoymXba9>E-2Tg4O&z@!?JPb#bKSnSr7S z6(pAuRjhe;Cy}kLIpTV8a;JFT>Zwzz(_3Brk`=_K?@pFnl7hQ`a;x-`mT0ed&Vd_V#TL#KL5iqH;sIF3NvZsu|3t zU53I;t63e1OXDi}WbMwZG68R_@7v`l#yd03XLvi}xyO4)jN0sxN4op|&7+5lhPd4g zmGAFu5s1_GIs5BU1*(E4z$CeynNx$2e6tjwNJEwa+$$~@Vz z+m(}*^JK@~L3-^Cm3u4is(iTe>B@hve5>*=!WJDd5!Z?rikFI?68DM!EIuNBSA0=? zT|6WHNgBB=uaTEH-|b=f4*4GWJMszn$MUb`*X1+v@8x&p_elfHsU?5aQGGR0$J9x6 zTAfw5sGnC4s&}YgQ;(?+sE??Rt52yX)ECs()HCYu)xTLSt7ENM*I74OKWV+zy2rZL zdW-d-^$F{@t>3dgV|~GT+WK4T8@6vBw$IrY?2GoV+V8PHVgI)M$M%=)uiAfSf5ZN^ zCYMI9=mUC9U#D->KcRnb*RRy~>9^^}^vCok^k?*+>;I*{WfZBf$Sj$4vuOrqV$Pcv znpd0GoBPaL%!B4(^HK9z^QY$P=5NjaHQ#gQot|^hIp$pJT<_fM+~K^!d4qG0^MLbi z=Y!5~I*&U~IbU-A!uf0G8RuE&ADw@8zU%zEYrBCvPa^4vyW@Y};GTD1vs{TH2S~3as&z>&26LBO46q z^zCAbM`s2YlxQ$b)55@8$Y=NKcj{zX8(fIC(WETsD8hf_^9-SE-ANxM&L(DSGz4J` z2Q4@HlSb)S6X_6549g@37Rs#p$fV$F#xv?s7v->_>j*(aXjaxo_GX_{V0jmMCQ1ZM z^U;*Lg_W3C_Ng7?Dcj9^&@jkI-Xzfc|qO5D*c3>S7u)$MU}4KI!;Hsx|rmXd>dbp7l4X`z|1ijFkq*n zDK(#d8yGcWV7UA`&rqj>|^OU4C?(-~^X zWSN|%TodW2o&5$kZ#14}U7~MR&yci2pYeB&h~NR3FT&P&rzAEO7D|tXuAdG8L{H5d z=7oXaF8Ubb9K5+GaIYyfeLAE*_P6V1Jn9ZJ8c=H31QQI;?QfA5n9{uL66G+a)I%Ou zgrI+;g2bd4W<%<^>7$SZrb(ShMZRF4C_N(Uw_L0nmSz(sHJ3@ll4qyT;GRB_h?rddb#K^U_6rh3vK zKZvAJHXEi%F)fkNVJaF1FzgrGeJ+y8m0E$^pYt*<=L?Wuu!NBVTVR2ggM|;%8{ZAnax#$jsbr7&mrAfka;#LW~^U6_tp)EqNSv8=FZ) zs1c+$L>IUOgMlsP@n}F36OYNMNrv}W$@K1To#62;==M2}4`vUC)sf)d+nM9e5D{rI zW6Ep;rn$dG#HGIW$xx>w9p>HhT`B7lYfDg-w~TS`{hrU@{Dh5?k~HjQsAF=_?Vc$-Lo1_1Mtgzyw& zz;IpE_~|x1bWFFVQ5%pb(wHp#~gn2a&;AZv^U+tCfjBkF!`x+LVOw-A2<(*lByAy4_O zpOgM2BV{nuec(jmK>))UjETRX-nzgWfTr1=5Rd51GUSh@L6?*%4Hz*9FCU{G816xx zDcGLL4cbY~>=Lt2kCICwhagrygvh{Y^RWdh9an#I{;;c<n+dmfR)_ zYbqi{Jhrg4+odyt1bN)3Qy`_n#wl+E(OncDbEFs27mJcX&gi+qLK-&W?IS6w^rR5^ z!*q(}OF(g{5}rh&4iF<9A`+V}M3TP)A4XXc^)#s|M#_x$Z8?n?z>Rk9&~qG1EFsNV z@S2{Bgc)Rw^PYb%K-@A}RzI?_lYb{&D#>EBfNSQX>6Uwg;%dr|=;b4#2aDW^TCr+taBJsA#y`CUBDRFdFcB}zJDI~~J>d@_v(JtD+|Ww*ga zd{5?l>eeaxYLysJbtrh|iTmcI#tqtRa$-{exnbeC1;Y>XRt^wa2}VI%yaW5nu^GFU!$XtSrechHN#Kml)2qWJ}!knj;^svb8qB9C2KwK6j z$by(bn$XK1A#4NrbvAfY{1?y5y)eLF26}&XPsI{Nt0NTM?D49LRCsl z8zaCEQy#(zf2|y6Fv2QdFGP(SO-&M?Q`+)W1UL|-p9ZtB@H1kaqfUhQ@ILT^dYOMv z4%p%C=&Urqh)QlyE>7ZNlr)K6W2-+!dx>7D5Vw(jurc1RFHt76^u-&5ZT|{WxS*!W z1A>$nHLEM$K@V|V(n2owD$JY$(xjz~YaynJ_}yhF%^)SM0_aOSQ?k<)KJj5-JokMF ze)$#ZiDjhcT6T_NZbm)D^Hhp3z!ZO@K0V?>QT!(%+L#qTff!w$Z#~9W5eFFzgPH}# zqf55XNVJ{qWp6{9$uI(~jb%O z+!!G`&Bo*vqLiJG4=z|4W8l@?9+614Hk_#M0p8X1Vpo4Bk+$h_tt|&R zwXW;g4tU7L1GLC37-6jLe6la>$k=*Lff31;3WKDbI8~82y~2q}U>r1&S=FfY2cXa< zF_ISp$XiClatbrdxWsYxbw!V^3=lsiJ1pJk;yAvJRENd$Uz54n(XmGzbZC4L(nf@z zqmLv`G+0$}ogE8k4#+HhvOTu65Q!+l79beo$ZK^l3;{+6R-5HP7?ET*#6+>g?xf|L zfFvrU2{qc2OK2K@X1XX=G#4e%dJumJbY4v+tix?)g=A|I2R0E>a*YDVM#tH zM$tSmzSh2$DvpR$!ofxo=7?*nBu2Ql5Q#=suXO2XwaT^`GDk>1Dia}`+YzP(%sR|) zSa^^U7zE>3#XB|l5=yMp9luHgTxWv-Q^_@`JOeY3T@Nxfjc>C(PZP&hWqa9n2JjJ@nZZ~KiH)>269f_!`xkZ8B9nEXFuFDz7vYixEc z44EL7a7!mH#;itNPHJ01Cu2%MSR3dX6u?q{G@Jnd$OO#|L?j}8!AI2t%yP~1nr0wT zD>4po1&MnDqlubmbA&L1Qn)E~JkRh{IzYFQK+F!vDhxHdF^Dx0=m=zyWG_L&FG3_W zSNLL|&;|u<7V9Fd0dmzLZS62}0r4k2Gm1&7fTGZpFmQqDO>_-xlq;2x^E5{T;RH^9 zjQAN;Cm^nsoKeYxWr6ZG=jy|EGO#yo@`tJAbB>_yb0DE@c_bpN2qr8t`EjjgtBIk_ zFlIJKVS@|VJw!P^00qI4hEf%LBAK>UAas>m<_XZ#2GAUw-DR-?7uA7DE=zl@w3PS! zhrN&Gi?n7g1}t>no12})b4tXHp~r-OC}>yqEdsU3BvLjzWia1J15@`%Rq4`$1oH`A z0pOb>;S~&~SWhy_nkDuf3XC6_oQ&+nPVbNYo5e01kiS!L5Z5QVRr)_}XZfh;@0GMc z+6ZzsyByb0qGOcB1ZEK+(;#YG#o)W0ftqc!3|_`ezk}fNQn@u z1iH4GJIPY0fIKM8LU&$zNv&N4h>Hx@i_Ko~a|fgOV*RFOkkr=fy3uxn5yweXnQ??h}=VLY}fn+TV+w=2DfUP^i$f5{3vqR=$98=6V7FSx#w%o#PhL@ zm@zU_t4`E#>uDIc0jgx!Q84PaEj!wL^XAR1Rcg>}XF928&24N4sTY&W7^P> zuU0H~J<`DL>DZymmD}hv;(A!k@AQHQ-C9rmnkHKyBn!;-_Tpk<6;;wo3utkBL3KMf`LF8xN`3UAeEP;~u040=7Y-D7 zzu`X~D8v_cfBj?X?jzFLd(L}RP}YtUY1j0-ZC`ZBRKEEB3un$;5SKpx`Fq8+^#8k} ze&2n&pAhP7Ajad!3vFKGpp?du%|DFDcmbiI;_qW6?f?niTyWbHD z-|2o;G`4sDhg{kH+UCDriGMt#P|f`pDo-JL3Q(d51MTkD3|be}mJKFh)GjWrgUqaI zKCnyt?k+JCf)HnUI@s($?h<0=QBjApxj34Vt^)KogQ;TKcSoHNBP^nJbg#ZWrfEDZ zk;WJy4C||t8EPtj9sB=$#Z8(H)S<}##yaY1&hX()M zCw>nSjs7k_KVE)*Ldb8BRD0mO7au7RQApwH-I#%qJ)jYPk6CNEO1w&KyeViRUcD@u zzUl>okeu1uRl?|vcaH6bt?FxAO_~VlxfHtO;-(4*`6e`VJEQ zocqoN{&(xG7cP8f_xFYLH~p2KN^~uhqDhXZScFl3sY7qm%TiCJbSISpE((^E6NNBP zmdSY)-Am;^`6s)#l732d1d^XrIe5^Ee@+*}d6QgW+m%N{vW<&zO8*=5+dE2hzu3?_ zC%Gihc!PB1^RWb)-LBHrE}8;d&W4>@z!mjnveH6|loBV$gf|NJNeod=Z(ePj}ERnNe+%WcjA^87b`G4gDm zyjlC*_)t&}x0c-iw0-ulk@HLKlRDy-K31BO?v z0(hKbU}Rum0OBW%TYKX9ZN4&aGrs_eFkJQd;DSsuUuNC}q&OIuKs*3R918sa0C=2Z zU}Rume!&0)EE_;1^JNA`22@ZE06xS5?|7VJU|?WienB2)*+9HJA+_|tw06S^K==`# zodEsjYYCG;av*;P@CbkjatYK51PVS1U<&371`C!9Gz@SIjttffN)3Pws142y@D2zL zA`X-f7!SA-0uv4sR1^Xf^c8*;%oc_g>K8y4To-s3`WSo|t{EyBiW*ED)Ey`v#voK6 zlpwGn=p#TU5+_V2W+#Rx(kLh>rYSrrb}6nY+$%CH5-eKUEnqHYE`Tn$FXAu^Fs3oO zGek4iG%7a^H<~y`IF30GIcz!nIwCrJI^a8OJOn(RJitAoJ;pv@KG013O-ZR-;8T2t8~7Yw z;7fdkukj7O#dr7~Kj26FgrD&Xe#LM29e?0Y{Dr@ARs|#(V>UJ8Ur*&7+5&m zghxO`!h{XBvywZfiSaO&JV|BChBu_k#%{>7Cg^`!EJM$|gD3X>kji4bz1Adh5IOKN%2 z@w_DGN${BWE`@cK%$JcrC8?tIXNPGWD$;7J{JBF~1>u#8jPzKN_tsYwv@)@74AH7oCc$!??<2pPHl2vd&(uI?tu1eNsA&005*My}mhHXk}q!004310000k0000s4Hx7RXlP|& z0043n0000O0000a2fGAZXl-004480002!0002! zo@LC2ZDDwD05<@0C;$Ke9{>OVAOcJZ5pH2^WdHzkNB{r<9smFV=H5yf%y4gWbN~Q! zXaE2L#Q*>U|B8h3s*?x-L4Ur_IDvtcfq_AUX%CR>fzXT(7z`Pi7#NrsSeY5Hf`ByF z6b6R}j1MZAUjVsLU=pYiL;wKFdkWJ40C=43)CW>jK^R5hGce>JlA|C9qU0PUiR7Sy zlB1F{M)u}nW+&M9U6&zK-|ON1-KPfX)c`3#a?l*aA!(9Wct>m`+<%Ql_mjzt?#E;K z(Vn>OCmtRj!!@RB_&pw7lfvG3D5jD|IvL?y7TM&G8|3hWJf4zI0fiJ%ObMlwQBDPw zRPl^zYIsg9b>a1bdK!31Bd>T(Q}`4uw9-a<*xx}XU3Ak!FMaff*8qbIh3hbH7-5t# z#+l$Ple}Y!X=a#Zj(>R;SY(N1-t&Qvtgy-_KC{L;8*H-0HaqOH$36!f@`bM)aU4GV z38$QK&IOlTam@|4+;JcNPLd3*$)@Km5jQGFEBJOG&CoX8P_)v>V#nVQ6osp}k#(_I6wJ|LHMwuGi4H zK11jF4V@b>bboHp(77Q)=Y|cPdt=f25krkpLya**jd6?iOc?6DHPo9l)O%;BH)W_d zZKyY6s5fhYCmsJCdSw`8cdY^e9%Q164G-bX{d6+^vML%mOidY=vT)(rL5 z4fQq*^)?OlwhZ;Q4fS>m^>z*Q_6+s*4fPHT^$rd7zJD0%eKpiOGSoXZ)H^ZMJ2lih zGt@gb)Vna$yEN3hvgkYK+EDw(Q2W+U`_54N-cb9Sq4sw}?H`8PKMl2i8EXGF)P6AT z{{pd~OGS8`l)Vd>B}a88m=Tc?k?+i#&ztxCsC#c!S9MkOeO9ZxtJIB}Zgq=pBw7z7 z)TXgOAb(jPSr{4N#Vs>!0xxIzOT&4%y^tQ=l{<+5z?pz|1rWgwd=JzHI0ZwNFhBU#VYA+ z(0;cgg-^tw+ZptC|0d)95i*{QXWL{pJw%30l7EiU(Qt=MhiQg?9)U~hBu*3j)!ock z5=)`}x|8v2y7!mDlf$kbbDuj_JFM%^pxOaep5}qYYOE6v7ZP5>9*-fEt?Yi#~@<(~2-SC7?nV-6rEuGvo zbxE0~t3F((cW6?xw5j$iO^arutUKt+*=UeWpl_h7CgVYWgQ)JCO-I8lQGFX{X_GWa z5<};7JG03sn~jq0M0N+sC$3q&W-YreZGRnYy?V16`_Ox45;YS)&-e8^`|{AS4Lb@4 z4bRI*y zeC1v5`pO3$`SlMj+OVJgtya^vwHuWzbfCH$6h?kB#$le!rZAjIDVAN?+Z|63i+@56 zX464`HXW+*PoQ;!c=zmhI#6dPSPbuw$`~YUU0nqIu}xC!gp@p^8{+(svDXFMb?z4r znxSM4V`NR&%W*^ZT$6KRkqtAt-f?7N_WiO>$+?N{JC?5Nq-%OdVEjOYq8hutrI$i3 z1ED(}*S%QxY|4oy^s84W@jvXi`hP`9EN0G6lsNlVWFFiacA&p>m%}rUo&Nb(lx)k| z+_$xpQX9FWDoKesNS%VbwU^4B)q3LV@^KP4F4SJ~*2!)z+vnfok-G6yQzi^b$ zqs(%RaOprcs5o1d)iDUGKk4tQMzlTL49yxdyQY2UL@lY?y!v84^=gUjn~4`&Wx=KH z>CHncXLg$1>JoE%l+>VYhNU}MGpNE18^af_mICgimE~-y()3c8b4=u-y3aR_-g@-< zkpZ&=I-NLfUd`%Z*Eo5_=6~^FTDClFx>3jzv$R)fKd1ec_O$jNNknR70KK6av_U$3 z2@=s@vr!>GJEV`zUS|_kK&hdu5REB{*g~CPr)B934>hq%CbKczU@}EvMM;_sK^skH zBP=pKLg3Uo8GtrhXE5v1WE;D^Nj6a?M~hAdQBC0DiRxXf!(cp>sDI!___z$NhuRF_ z!Jy+}xWFgf{$QBKqSGHkT}Ih3g}M&9X)#`151I(G0JSKzWZa*ms=`H;)ZYjim5op! z2E%RA?}#`ZKoc{(=b+C526}AYxm7)e84yrLb(+@t4hVNHv%}T8#{$9P17V(K7q%O9 zre9{&oKhbiNEqWBWPj7qc@$Bd8>aB2MJP9P9pr_Dpkv{F;kqa435;MlrOvNJIiWE8 zgc>^6C1^^%>UJt+!K6+FC_E!DbVu55;#pq6&N({UzXV#B`K*=(HQ|Gn;e=W>ICMVk zv^LtUf15{J93CH=lIh%uphYyUf@0;vr7I2|sIc6M+|ZXxt$#d;V$&6lJk#C})o7jl zJwGCGJ&ts0vjEh%1@|F3r;aOh;#!QFoKoJX=GJOO2tNY(!2X#uZCz*Hb9y&!Ubx)O39X{s3%F(JoSP$lZsI_phT~NZi2$XbcBQ&;&*B5*7?qQyS>?Z zLRiqZ2Gt$vGSi|)M}4Me2jvgjn+YRdw(Qukl}O&Qb}F1^UMS1&+qK) zkjiAaxnW%}#%I@u*AIu+zxamodzL5U;hS$JmHC^=^*8SrO`MHInL;bk(aH z&jxV(%YVJ?{oUEd>HN46SXS(%VOj~BrNJ;tyesPPfYpuFmhTu&N}g^yeYd|Mme<{$ z(}dUZP^=8yo-DOQll;r!o3~@Xm!A`v*yWW6j@eyrX5Ft*YeALbI>?_x-;yY zK3#m!{H^E=1NnAuT-n#jSKY|A{CN5DXB%f%UhyKg9OtQ( zSX8oy&q%R-e#eblwXhYgT>nzZ$w3k}11jZLpvv}&U4Lc6aU#>B-3y>mZ4ogC#DDUd zFo^Ap6VcLL+i#s|y3h@j_9Hg`OA+a25Oz=I08djcZ@Ho5MS>Et#n=tZVn$6$z>G@7 zR6p!v`?N$W>|q-Rx70v$*H*@`G-iMZ+hF@kVERXG5W*7cXV0GBoQlgm&@9;r@@^jK z$IKJeZ2qg2u1;EBOl~T7bo%9ECV#6Qo8PQXFN#LMet!ULNrAxJuWMB^}WoTw?t8b(|(+aCAaat;+ zVcwkojWAhf%a41N-_AshMSra>5D(J_Yq)ZHz4A)WOU&gfL5h|HK(-KU0QEB4lyR6a zFBnKk4JO>&_Y!8d4{jbm=INatunQ`k)1%d=TcF0c*T}&ZeVXbOQxB}rbfh6&14?+V z?)n5wV#xtRo7W6R_UjHa^Aeylri>Tx85sv2F`aUW!68bkj>G(yn15-ITcPC}R$Olc zCM8@Dx)cU$V85b%IqI90n$zt28{@cgwIijIAUc4{9b3ptW9czZn`qD0eiX)XR16RN z#V~!LN3m0p2O$0;Y6ReK+DBNnKtjVQYtU_~&Z*)Vo&uqpOdBX0_z&skXbN|nkgxWQ znz6OfPgYE9oWC<^WPkMg$03}?J{eKwr%;Lpg>AG`04Z9AT!!ZgEX}dV+cUdv5kUPXT3FJbhogp|kl{c5d4tNAEm_ zH>KqA>DD1;>OE9>oS81~W?rrf<7uB6@&n}3eETuzuOC5nHGk+UfM1~8Q6Y!`5rHfM zrkxfb7>RdZohiBts95)VIE4Cxt{bbK+(sR$pfey*at$|P!`g_uQOC~K?zs5M6a7dg zQP3>g$XW?dWM1aJEA{3vo^z7{Vjl?Ov<$85 z0#Jl!JJr<}tbaeB>o45cihR`bhMia?5K6*`>7GpC2(;Xh!LrZ2Qmel{7)O(QrPi_B zh&T4PByb1Y3v1GX@uFl;FP4EbJ*>SO_2LEr>^z3v*alU!PJGgt^zjQqK;Yxg3b*e7;4uPtj0@bSLn86zOF-OnvUBDoDcvsx0gYTs1F5pEXjQaGhPq4 z^c^_O9SbJ%54s8147iC5vTE>yZXy6oJ9=>w_`&Rd+JAi#b=K57dHRQ3;Ub5_D=fiH z`+s<@;D10GI9v(ObsDw*m&dA`KuOCG-uK<4BUR;5x{AuXm4myLg7-@pU=BEPOS=L_ z`TrM=OuES^8BIo$?rd`D2SA!5`@35TK9)>7cGD;U_!uk$d~}c3mwOv)FlRkix+$5i z4TtdW6O%)SCWonh==_m5=p$TYOqh0e3UDzFO@BK)+m1uuYx`xdx%S{>ZEI_dZEsJG z9h)rVl>P<%KeVdWgckfTXgll59nzKLSbpZbfAxj@`uqlXow+f(`eya*qJMorf{Vw_ z9K9F*J9_5W#fuj|dG;(|#X_&z3w-Zu5g<~079jno)Gl$j{cQ1=AN2VpI-D=R>s?>^ zL4W_4^~`^yYj>}#tW0)a%gf7qZThBWX(6;J28~?;AO=uitiDa@mmmGrcYgS-r~AE& z@7|eScP;tuYk!t}`&i?q!|$1Y?CMMQ07#hD(=OMZU+B2v4;0gMRLq}|@)7NVJFwds z%*(D)WZk{eXtRMWXUZ?8&Z&uCoB+W9eSf=g+0aQH>2lrbMB~f*&w1JNV6@HLUAwIA z&HlyaLBsutU!}v!zP4Mowogr-clyZ5%Wa-JN$H7C1T9aB!>1~Z4ZoxbQw&(7aVJ1Pi^UwVAal5VM`Ca$jkn(cKhX(TYciWt%eoDYbAMx( zqtU-(WN!?$s0}1-@hZXV8S>3}_7OavdNX3>g*i>o1A(5k z4d~tj<2_h2-E|R-3ZIG6X}t~8@C{Z)XFJHU-8=!z%;qX4j(0*o$~K=*ld$%Jh<%?!|oZe)OvBEvJOQ_Vr!^lDO= zX|2cfeEvbSR8gtk?Ep(=TU+9MC&Io_K$^XT{`n7>BhLlddnuw3r6AO6@P7k7d-&>i zQJpJh1)U2W+JO#UV3^S^JS=**&v#uuQaPZ~!Z{`S0PG>p88 zG(p|2{_|^I#X*8(d9b?mwxgGghs&wCZ22HT0h?DX-%Wl00XwNVS<~T;4DInt>6f;x zZFl?4ix>Vk5&F6x$fz+$e18ipwp+>?-n7-#X|pbha4 zw#fkpb}#YLXS1nxjrLaU1KNkQKSo}f#e1OQ61M0J3gA2$pa{X#8xO_`sud^=_`*od zRb>#1o;!q^8v)#`zaVXZslh}G{FqD&wl~=IXO5-?omCQ>EJT-$3x6T)cJ{DNqBO^- zK>izKm@25#?XMCA-BF_~{A&|>*35Ng)~u41=3Ct1<%*T;Pf|N72}C}Yh;m_b>7*j@ zK;9e?0aoF<;TeN{5%)RJU@zXNRs_t69YIRjD8_fTqqQAJ$-YaL*B}6bf^B zAeRD|0389E1kI+-UVjVHZsj6?spXj^gV)SbAP?pkd=RwPG>IfHv+NQBjn%2i6ppi6 zt-Y@y$)mckO<}LNwsd`<)ZF8QNnnyXH4R<2Ef!fO*ehxRUDYGLmG7YMj&UJ<4hkZV z0^bURFaim^z#NvoL#?l_W0yWC4!{3lBIBJLOnxYs(8sFvQfnz}HG2Eb zj91f;IsVfAD=$BH>deX8{qEZ4ylfJu83k?a`|5K{JAJ7>Ke#p-$~MrG8+sU)$c^yWbJO8XW3ff>CO- zs2%aaWR@kpBm=Rd@1MW(o$n+U9-4pb$tRzje}C-$`|oG&{A=^Ck^HN7e)-;ezx?>a zr%yk8^)4^l&yFDS0!1XVft(Fy)&X>MQo9PS>@I9` zlYb=Li89|K<*a~Th;as!4GM~8I*Uf=qu^`lhzFI{&q#X}>von^WRO_0u)i1h~tBw?ks z!BU&1kap|q-)!3gzk+$1+;Yo9YfWlXC)?|`E(Wv787B`$lKaANv?Kb6CTexX4^g9LE)h&EY-M(t_U;#f6h-HNr zGtDq0bwK%jf&YubKxV@k=$D1|*?*=0j-ck@bL!=3 z9LKkva$KhCrh>%uEW9*?Vbe6@3h*`jA}!qqCG&an16%4<)U2E z!L0c87`pH<@Lw+*UUB@|6R*C;^Yi@fGtYU>>AQ1od8cC^rgEb6@BhWF1$~rj1MPrz zwRSRRDZ;=+nJ4b$Z*m}>C12qu9I%zmlOzZ0R2t+JIG~*DA*Fy z8rI2Vyv@>tbq6Y#y`#o-jD8Cc+(op1I)Mvk$_c4_tSAx%C|6FdB!#&grx{SASSl+5 z73$*r-c6h+3{ZcA7WD+KgbofVA_a&5k`>~EhZkXGD42E7`;nnPB!3a@dz#{;O{V%LpX=jBF#G3BAT%ztuR*P;fK0hhW-S%;ejKq5jdK}ikJH7DHVwJCZ%0rC7WHR(`1R_dV(p~prop;~t*Q=)NmzPS0^uxoh0Dqkgw{WTDIi3$1*|iOf zsCv3fU|M384UTab;lP}uCWrc0uv>f^&?9+A(HAC^;|S{Ru$W1C;0OmW*#;DN56~b+ z=!YuhN?bCfY{gMkvMtkfLzg)RJa-T_xSpl?y4*G$CvqIK3HpvP7FqyHb-GxsxXj=dn@sM8)8i+iStueY2B&ozXzYM*`qvW|-KWpqfp(I%;MUn&b*p zy*aM}yylEjkI8Bjw>;aAp`~~7{k0^eyb%su?>r;ifPcXku3=#a3w|c15CRO*xqudx zH9dn%=xE1rKsv4M?P^29JOG~j%v+0mrFmuV0)L=vqO)u#t!hQx*&2+gn{{tI(G4v?; zNCf?7`_%C>yJW52{mL~r_wCSR6iVtiJ27lvF@G5A6lP|q8}i40#I}Xo31A8kA(R8% zbV51*x7lFjNQ-9idm3?>b`Gu%egp{>rjeLDi(Q8sxolW^#fQo2RK7$!u+KKk6_)~q z0l30#9Nm8w7R*V<&HD~~0!PWob0Xj}vRBKNEZ}!mXi0%#eW!6`v%K8$4Pa7Tqn%Y_ z3V)(z!~CgKp!SXRrK#l_esnU5YhD>BpCyxbvVE2I{%)h2MwEt0uhCs^l~-WiKs|g8 z>H#X^20Wl%LV^D6;##%|a#7dzq1PcBAwdQ!PXM=IPESFLM}T`~gV-aTb@X|H@ga|Y z_{JC8Hypd-IhSveA_7OX>WB z@BYkt&aM9Jsq0Ri*tdG(-m5m6ixSPz9wxpWFy^v$M!O3Urt*p}LI;KCXV(56i=w>a zV5D~Gej*l5Ya(cAr#j0?P$fT^0$yZHgH6_e)34b%1 z^Bc2XDW>EzY5%zgbY>f&S?6d=r2Iqiz6NlF{SKprNjQ zCOiYme{dG`QRMrQ6Mc0bC=iEB?gXq{aw+sKcc2>J=WU-E;sbg2-U9O@HKwKEY&S zxfVz{*S#Qas_>s9LuoQUi?d1+M7jAG0_IlQhB<*H|u+Gk*qS6{$jkGD!#1 z5$1{QrZo(<$(}cMlnt9iT|-|fTr;rO?Jhc2e2Y=tebsM6pQWwN*0Yb;=q3bQVoCPV zk2>;tDmW(F3ESClEJK=(XG|>Jb02{Q=jWbt)mhTAa`Qq7s2F3eX^DIzw_`_dliyBm zNWWU=fcZl(hi+7UC4cl`duJ3h`-g?am=Q#lZ@Ci(6s_q5V)dA3z~M+rY3%t5>DSp+ zz}suUU00xIG?@K972U~UG6Dmn-1l7&bj;)H4kUg<5W7mIYX+F(D?I!J~i@ZW4oEQcLjYJ0+{Oc;~DhDu03rFMuoSFxKQx$R7 z;Vc8Hg`Wq;vjeE6W2D;3+^T#)9Pn(4{Bz;`QC~m?03M5lqaAH8y$fcB&O1Pz^$OA5 zifuTo2~-kn)_;9RF%J#KiqUr20VxN7gI-ykU3;uK%%fhlorVB$of0TNW`Z{B#1#ZC z40D*8Hq2fCMaP@Eyjd>;UP;`D0!WHP;P@W21b|(g3YaE3p=F{=o!#~@2n!>jWCmDK zYFU6fq4x9>!N0VLXnv$@8!p;#BLK1}4BM+`-UZW?V1MO=kOo0BXBf^pHPhp@(9)%C z2PNAOdwIg2*BaVHyG%O<{a!e4yUM_fH*vl|zhky9W?oKMcY@jpNd0Kx=1pK+W<5}u zqXgswKgr{OCZ{*7zMOf7pc~#5^+Fn8Tex)N6hPE7iS6*gdzf@I=@gRoUuwH`4!dl08ny zNw%2lkApsMX(Me4tyrhs{vt)aTN+Jw=pt5?lt!iT091CO+~T9@aI&qEufUqqU*VO0 zI%srC^^9F$Znf?mU-G-AYo2GlTST=2!+#4!C4Xu}a(?H93v?8>B1}UU=F{^hF)uL@ zNZ04@B{$^ef71{33|kUrb}Y9YJ@e2DFI>tO+RvEsb!k22>5}O7$>@XgryhBPY(4U~ zXV3on*|YyAXe@93k8j5RcIU@8>Hnq)n7!ZYlO0U5?>_#vw>?h2{fP%2_ymm}yZYkA ztA8J3kDa@C@!VsJF;40K4t=w%9n{XDy_=ws5{e8jY*N-K!ge@|b}%D$IuqFpK(CMm zQ!bL{3KJ)RL91LgWeW>WJ^i%MtHBO4r!Skl=n7Eb<$BZu{T@W7rSno?PQ=09bbEb# z4=*JRAa&NXXS;KwX^5umtu+OUtQWn))PEfjvD1g{y~(5RbHPkmJ1imD>PszO)XPE6 z{K&FPzHZ&uTt3l0bNZM4N@AK|B>FS|g1KTEHKW&E6QMlo>5dr%ZgRW18zb@PH$hT1 zw9B(HFSj|YM9YCBwm_-ff7*JPG*HBqXuGgIupb)KrK}#&( zO#<)t0KqsGVXK@_PQUrgKRg6%bHhge%yF2^Ebgzx*@X=FAEg|=+{=j%IEz0GoRG0& z=iSJ6O~;J@APBmZg9gAO{k9WmIa@cVzAM zM!P-#ee&h`7Wwd<$KP@{8P2abOztC}ZNZ6+)^E)(lKYeS2k*Q3p$Ewa=8uuuu3vPM z?E_gGYFBF4C_RpvWVHaLb@DyIIMgZq3F$0SUR1gfI>2Tf6{woP_XK(xpnuaUNk)^w zZf)6qzQ6r~gYEk8#;dMRg|#}n=HUA9$DeyN!rbclQzwrcK7QiJ&Xp%#-Cd$r9^M8- zs?h0$ylGld?eSZ(Mr*CnqQR9X4jlDNbL+~NG^645hp%qM+&XvkCJg;ZbN`7i09CZniSjFd^xBg^3&_5GCrFVwk>e_2h%|AqXomc<-Pk){uYmwR6)VB_v zeD!hihQ(EvojB56=%jUa5O~JV;F#emhDETih}4+PagMR?rs_SmpSfak6Q!B4K z$1Dy!TuP?L(5}50c+6g-ZE3%xJ+1wBvXA^Yc`x~6@-+E0`48kXIA0HR)ry>0WkeO} zc+mM&^!HM4m5UM$+U_!p>0nIuNCi-hj>@nS87{0)skb8);{}W~DhlDy3?{?uK)QGW zS_(|cLj8xs3x5-qZs2+%8BaJmH*xhxchsPnS~)gT6tmEv(^;}B3K)=Ase>RQQQQ@P zIrm5^icmphcfIQfzWaO8dRC+k7BxVHf}uFPyUL-)MyN0~HUJuh3=N)j01O&FRH)1P z$_tCaIV*BkMqPyf_WEMC8-~-Ny3ugTbObFj%jhveOiY!a z#UnknJe?3ae-M~c$m?ax)+NiM6rE+t?U=VhP+HxiE2(4nCClg-%^(0Hg9!?@4KpWq zqpr~kfq$#Zu5kt2zh*>DqvPWu6fhE|)AFO{3Nl1E=vsRHP$v*Ixm|0wsY3t+3k+>L zDP~NDmQjG7H_Q_&o> zBTOX$*epF;asxxzFl~pz@l2qmKobvAhE7ghEPuNR{^(!@=A?Imo|^;b zwAI`Kvk2(dacf)MFfe&)rX23W7>t7ozIoW7MTAONGo8(^qJEJW&xtp7_)epj;v4=DZIeV1+I$(u4WrB z3NGV!(l4jkP9f-ON{kPuV)awa_6@C_MSj_p|? zoc7uRs_#qNixO!@zHlUP@uU)&kzn&CMt=zfLB|cI<#6B-CXomwbd`K7&BrK8l7(k6 z(ug@J0j{pGn8Z{IhDD(vaQYA~5df*g*1+#*w_ey*o#L&TF@>8(rWdDPY+(oBxj+VX zWG1rYd*s*VZ@=kV3%vVJ^rKn;8WHn<;$r>WOcA=tA`^V9R31(+S(qeTgo%?aUVr2o zl3T7_Y9I5LY%|JhUg=$7xms>CYTa9(^Q;NTWoRd9wH`Rj!;SvRsd_7q>4(1goNkNr zD@;G!H?*XY^fPDas^Ly_9GWYVj%^0fbTDjo4Q}q`N-(L-FhUrqpl*MxYITSt-692P zFZxrse?+RX+0}V;Dvi6nPJ(XY1b?v31e=8m&2S0DLZeTxp%_V4d9Ug=qi?j(*-p1c zxr_cyLIbbS@B;isqtwk`Dkn6UFm@YE+=%JBXIY#$`EU!yix@7TAm2{RZWNW|=K7&L z7mjZTH?;b2zzE`=9lDNh^E^LvzSHY&hz+xAMxFDMeCPsn@5O;3OHtnnU4Id5mf4~8 zO?5u8{Y$ur(0>B!mTP_JomfST$LqwSeD8Y)nE3bp_*#4G*j8J;k^ZIc4}H(!m$!Gn zweXAj-fC_AT^rw3sl6O+`dOx977IzD(FC+No6OL|LGoKS^4lNz_y^v5ZO+KU^H&4& zN`vpd<&C@brk`Xl(B7#1k$?85$S2Y5u7Z6@+$4oBb#F~0fV;^UFzW=f$cm&A^zF$a ziigF(G-4)v@o$WySQtgP*HDQwdZUWdXi>KHBKin+v=6r~tZ6hZa%Z71TC<4~kRtl7 z+`?+nq&nRn$cCzEu`IPoQ!r=)wT`=RUd{USq<-aegO%dvH*&q^T7S;b{q?vUrio$J zt=ul9Ou%gPxL%Dm%7D8f%jMxVC?764s8}AO=g!CUDHFJg%`Jyhf>tGRE#bvr3pnGZ zWid0gFytqw2TFy2rUqkG`7syc6P#Na^SB9W#wM7PgnoYmuH(AC+$dj$div0DAWTl9*3Hk07?iC3?ph#p{d!>ZMefdi?TmK6_Newj?UUNKRNiiaEAK_OfIPS$1`|am zQw-*UN>KO+=qiS}r;}m<#t86p;o6T!vqD`ISTP%9`bVluqrXSlKfjQHwiWhwF*!23YB(h6!#s((jd(CWSAN{w>o=a7h-W*$~c zgo5L$&FIXA12^XT4>VjjYME}%B;~+nN+(O{xs*9z zqf1VS>VF}$KCg(D&Z-;h3EU8qKbhk;blrkVY)PFOT;{dqxJRCky5Gzi2Vt66*liAL zgyo4}0XtzBX%iinXsQKEJY1y;gen*F7aoJg1qzxl08i)AW@@GHZRQ&-!W?vZ!VHzU z*ba{Q)!V8ds^|Ck?$-!NDQK)`ljo9~$t~nHeFqY+JMM$0q@_S>XOv`71Nm2T1ry^QYAE9jN<41FHG zfj*z!NPmRBkiM9{gx*f?q<7JK=ugp$^tJS->3#HP=o{&q=+Dy!=r7ZU=_B+}`fmCg z^nbVM2kB$6OFIgQI-+#)< z02|n!fo902sIO2ds2hR?;Ug%58;(GWJL3sS#{FzG=s>-OKEeBmj?B7bk^pBc>N-m0 z0L~>ot~!-tW3Ncuh9p zRI)=hCH#U9JiGS+rF>-kqru|9K&Vd|ADASw1FFDYX-dA0>#nF$mduPKRlYw$I-oGR zOgE%7brlP2FlNG;HA>vbl&3*$iMwDz_TQ)TCy|U?`lIw4z&GUl8>lBhi+>TolJiFd z>*|cWAE<#bpTGl7>d0SqFdBCptTZ_ZYDGUR!RR}<^@ItALRA1j}&ySrx&f)m+ zlZ-q@8y8=RPb1_QTLakP-Y|bZRO>OSH5O64X|@;2<16lzCGLvj$4aNve$Y7DhZ z5Vh#FjO@o{!t{~-H5KUMP1b?q{17Gv(i4oGL~^~&RYk~?Fd%Y% zHI=Td3-V%2z>#wPIe$!0rzC>GB4-{3^Txi&=N{VTLtN$d=*Kv@4Ttr8C=0m4Reut$ zfTHFTf{9PzFh4Bbf%aCW*d2NfY?Dl&f%A7ue9ru}Ef6>ZApGk<9!Sa_0mz9GM0?OP zzXUh?&#(9ioqi3Qpw~o=VMzQ*s_$Sz7Wp_6bhI;EDG6q)5P(gAWAT&l?KS9o`I8HdHfI%FRYgi8AqiZjmVbp$XY`Ht-1L$8cV6zyYD1vm z8!Vgu@y#D40Xb~;!&dIKcRAkM*;#Eru0NN1i*P#|1v#4zCdEqeg?kYQ5++>(KO^6D z;*J}Y0>km@7Bp~_o{GE?;KkrrZ{TDl!*h?=oMbmjj~%r9suPy8>z4PYQFQqg$&dZi zt>+o&P=9kLNoYAVT=T#+Rw!<{)-*4z%h^vqt)*H;YiO&=i?O>2#RxZ{Q2TitA``WM zNiAY(OQ3BFTOFZ!#rzU5*9je!+wF4DkQ>&lTidL`zhC^t4{U6#ZETRc<~QCpnUMDl zF55C|(fp@24_qLxi>u^`_C_lVx~sK~t&Q5oJAa>k|Hh}jaQp4_;PSWnTk{Xb)iY{y7s#MUl1=v(p-t7^Jj#iQUAkSY?#>eQdhV{JQ2zV=Vztp=kw1f1 ze2sA**S1@}X!&Mn1;NpkoQcNzXkd0tKX4M$GBKOcjglT%4dK~Qqh0NuJ2+|f;^lO< zd4E{PeW0w=1S9f{%Q%rv0(wX0z7YtAr@dT=PRD2(9;bF{8JvR6Fk8S(vTp911~)l# z`xVa&%uvRqbUU(LopV{eG)@xc$&xnE4rwQ~mm%{4Bm^)9_YqPstXnGfu~2yKE@OqlLk{&IQc+gq4AtSw*r-T8-CR_GhQ zySDPo=U)Bl_r7=SGs8Py4gbA&?SE?Re|l!Bb(A0J2S1bl@JD|B+H>z?r1Ss%#6q9^ zIsLraH%2NizK{c!MT2RvC7O&tFZJEH{oGFCt=)9jO)F-Sua_fp9EEf7oSAYQLcUAu{}4X>V;D!1B1OLZorJ8$_7lW`7-O7p!7| z&1kl_nkw5}23jmNQDL(NZu6l+tr)hz^(ZQUgB&G|7cR(R`GI2VLv%c4yOVk}oUD^c zZ-(0o70VcuqfumP*A10MGezp(9ZixkD5xp2d3bczAB?+7q4vds?-$PnLL*e5cXt6M zdI#8kU9Xxd-Fu!mUEJI+Fn6A(UYyjKQ(36GRY@qY~QFx9{t(xPSU{NEJ@?u9dN=5EgTdrexR(~i#hde{xm%Dia zco!g-yDXgtB|!kmsqS+4Pf$!@7r>(lwMAfnngd!d0~4T)pVx|PIRqOPw#TI=4=n@$ zCanV=f`>U#z(i`wvIV`Q69v-H<$;^ENrT_WswGndQn!dnBdG2ni(=^1X6U~X$|;Wv zpBZ)Z2~=7-qE(gz1Aj2h2zs5^%t#F^DqRbD67V`R{cv~Q#UQKawHIrz)Lw`CyF|NT zJ>_mv0sKPM1Ia7$p4GC`q}bSPZ*h2G6Fh=JUgbLN7XdUCNK;ul9d)<|$7cP3lI(2? za)r8;Z+1t@%~Wg%G>d>$p}%!pZh&nRn;XSn9X#_ zO1w7zBq7y`>4Nwex|=)%z{|vhYlMa{+N9<>5}x8jIz8RDS8cXh@2tcLGi7K7Ze9;N zUAAuoNKJqScYj1`b99Fy$g{1K;pPRn?Sj6%QZL&e$f5H!XXr+D`7p=^!Lh|S5Wm?? zL?jrPJEuxc)$$0Jff?KhOx@YdGm62ky%xq!>vfA*>IRwYCNrWVd7$=jR4Ktlt}sma z-CgZ=wM+v>Z_-tvW(-|`az!WeZd_L#7YW=EXZ^UZsO&yESAYO`F?ZN(3_^AwP&B&3S?|6#r(Uj6?GJr{? zTNItj0p&2Q?G2l`BID7KDol;g1sm!(poZSkvdX>aaXq5KGh**kYC{>`e(}L2E(8oN z?x&?km49rlTrz!88<&^M4c`nhzcM{s54T3n9dR}2+?UdRvYtk+O*qiil z%Af@(jdwwo$W(e2_U2+YlVZ;V`Q z>TUO6-e041`O|!Wn`8*)mcuZhdL~0r$tY`9mRCR>m`xYZ6g0*+J&X6}|LP=_JZ}hI zV#ImoGs65jXY@{slNC@f`o_}o!ILX~noF9a#?dXi~1%-0G3(0yIKw} zoD{n$_cS2#J_C&eUSFE*_o^rfPY+ zQdD?lip#`in1YnW>1ayc#w%$gObb+kC4WE$aY|+w$}K@R7*w~=BkVRW)A^uOcJiI| zi3^AJH@!frB|I<^p#6_5bLqQEyJT42jK`~KyhO~@QXAPh$ zm6Cl^8w3Rv!~rHY*~uBkVu0G3dgvOKNljsq`&yL8nzPyH3eCV>?_%h9~lt?}!9+ml5@w2*f!a4eo%!3>n6TBaGGS2D_UZCRD{- z>@E6(_D4~BKJ31-#a<7+#c$j-g#=&yDsg|GdTRd3&wS?IM;`fuKOpCBxn+JU931ZK zko*u?IZSpAJ#~2d&>=wGhn_fuk1BxJCjFXrMtiw-k9ME-7LdYsf*gKZdj`zFI{6WD z5BWv%Zt}b2ljINSCOt>b)0fh_=xgX3=mYd&`YZHN`s?)H(D%{bK&G(RwP}Ei66Aji zx1a!V#D#=tC^7qEVK6aNv)COqn-)7Q#G?bqG%!YosZ{Bp*g{xMg2^HRjNxRp4-^LQ zc5~onyI;VD0^2}Q%@!*mr+qm*LU7N)Y*9{PY?)zR&uo+kl@6WacBvT7QTwI>zZ+%? zeP86p@A0_7?hnjkSy%?N&T9R`09AjEr$U{+UL?h+%hbvxT+_5jJ5o?K<%_&Ag%%Mp zz^m{^fEEMfAXM@grWvah!XsRLRjgq_x~10Bs`Rs7hDa9hX;)6w)+b|JjiXY}SlTR} zk7^V8Iue+q23_14fNC6}bGR?3xYoiW(PlD9NL*}?w@PrsBHG8@X9op0&pLmLJm zM-fTQ(qhZlq}TuhTB)+3p}SS*P8Zs1k2YtRHKdMp#@Rr|ic)Wo-Bh4Nu}rnIRUtrN zF&9atshI73lY5)f7GEa)sqBnr2jF)sV=Om<7Kt7@lf`f%WB3^Nvdv`BIWX#G^rOO# z(>n9@N^E-oE-EtwemX9{pk9B*gz_2s5l^@)ZOhbIrztQ-Bw?DP>z986a8m+S(&MPA zfQ54gYThuY#LXl)djhwT)7g9ALx383NH^e<($ASN&tcBLAC6N?|2n9)sE1iUEE2f4 ztOr1PGJ6k@;Z&sa0R*AiCkRG!ch523ouoX*`C97N7QW4 zsUe2zjHUsk0IZLtq?PJoC+=@?{$G$I54`cGE}kBDlE&6bXO2)r4-6=(lEG8R`Y&hi=jkh9%Is#QxA5=;)4X9sp53269ynB2(4@ z9T|@B%e7KFgQ^lMw0f2i;IfOsU?r*r!Uj{ziD_FP<6`CjoihU;+6LAPo?&}o$(z*b zAS%!uz}$e;Qu!84bI)5VNuaYvh8x7_`(N-*V3)n<P@1y&s}pl#?%kbbTyX;B=8C zhAn)|f8c*K5_U;KHSChh9)n?oq0mn*J|p}@)q!i0sh+E?#VK2(nDq8B^ke7BQ+-=R zN*fC-sIdpMPvjX-N-Ub+gd z&i33CYQg^Qeggxrp(-{xR{U0J?QW+|)V4^)u4lV8a)wE0)5U%S*>Fm}zSAC zez5uxKuhFy$!pEv@VFA%(8){f^gb^Re9QLk+AfL$aV?6{+kRM4st?**R==5VuWTAD zz^#89m%FCRELXU;X}fo}m)IvPKL|bQ|IMI%(EJ~Z0>JmUDtcGzQc>tGSNXl3q5oB_ zhd!uXrCqPx0zLN{?ac}w{igP@VpZ1nZCF_+?Sf7gP$kW9p%pGe1!FmbUg-~t@6a=o z1bREk0P+m6|0ZhpG9guFlyVP^2a|qx&`p2wIBtlLHqom(9ZXa<6~)Nig5bvt0O z6QS-rTRZ{qhH{VL!rWv6I0l{uPZ~|fgAx62wb5j9WUyH^J-b>8EkPI>6Di#4wf!R% zP$|!R8B+jMY`UzoE066E+T@VL%@N2DS$Jx}oH$1@L=M~A^lAM_E}F-w1L zz6!`6RCxa~{V1W{yuOSdPr+;ya9GG=-XC}~4PzZ{vht!A1A zxlitMA{fsIa6sFujlM%WT;>Gf`&#X~?^M38u2WE$K6KqYe!eE0N8kqa68gl?3Ks6>BgZ%dzl3*O{k z!*N%X$y*pda%7ou+ba7qcWmyM{q5t9>*UFS1Z2};$J1T~6lq|`U?BQIV)8+AXvMBH zbHi;fwOzvn`6SdG)^vx~4_FL3q~hAPm&XA{M#{s~Ia$g|gP>%~higN|hE3u6W@%sG zhh`7VFvjUkbbC0*?r#@XT1|eQ~@LmZX0m ztpvcVndBy*2AfQbnjy>XziRMlNBgB$D^29#V^;j4W2RdlxjnbIK*t!aSpueBcJpxtE>X>6)A9Z0)_=7fXzQA-EN#a zang)I|#3K!6qp0|NU9rgNc9GneM8ttUTWFpYQ$u_usU7 zITm*&XJs@ur=M_MJO@xk$n7n2M39|bZmV%*^yJ^w7?N9Wp{AW6Ht>OK;#N;rJ8$o# z#VQG^l|F24l5S}&Z*6Ywj!E3kR6HR;+oa#ee*Oh6!s)S6XIY&k63K~hR5%V+g59;l zt)t6pWJ7;dJeF@`wIyC6-Y@=A{Db%xfXK_bT#*H0#>lUf$WtR#Mpl5qMhkgy*|4Rc z6SF$B7B5#b@-VrJ*|L}eF))BnR?fOaS_*ZZ#26M0vX<27cGu`3g1{Loifj=Ei7KPa zy6pXye|H!&tlJrLYF&)s8W-dK2wJbi*d`S!;eUUV{nR-rIA^yz>T(WD2_AX?CNZYN zNT(U2zRz%i5KSzXos!cbHhM~DeL5Nf^$7b#w7&jzNp-v7J2}_2@ZL4>Z-=kD5r!BUluiFU81TCx;>BWJ9HwJ&08-HK!y=9i)jj$!`c; zPN?v#rV8jpy9Nk$`i9}duf!%)|;wf0$Lb^H(u!(`)40yE)pd!$XjO+tuV}q;M95YykPe6R}NN!UW;b(<%+@#9mfGy4%;{;!8Z0 zXkq)c;Mg(182vsYV46^R%^)Mu?>9)L>7-Dz_qd20lg&^HSIE;B>C;&_J{Hn=&a0b~q{vZmMsj1NjaFx=y0$Sv)xisR|hOo|ABhAUO4gG$dWL{DXfKL5)D~ z8pzl}djw*rRFfKoZON43dO#K&VT7fGi^{734mbAL&-6@ORqXaTCRQ8pzv=1q)kLLE z>>rNkp)`@YR+!l{%E@)jBdxkF)F~3j0a2LQfQ1V3BT2oHSg!l`H5yN@X(D8@+LQ9p zO+;K1k;RHrpsre+&Yt=X- z^FA=mq-jDs@UU*>CVsTMZignQ*BtBsIJTRt>}8~qX}BX5gsHaeAS8b+Mbv8#yI`vi z+EoD15_^-6mmvZ!u#E|8SU2%akR~J&h+VL7V>~Caqj<@QFpid63saX&$q>6!LI&i5+ z0gUQ+ezd%a9M*c%TI_$150N{o(`7FW+(y-r;2-O7tLbJYh&Rq&Jafvd>O+e`eOjE~ z1iB1XI+R@7-CRAi<2Z*}M{fDi?WP-&@zxBElfN8<+v`MzZ#&$o+A@i|8Nj8!9M+rAT5uUzV8 zB#p+4?Xa013Y*@5@!l34fWoN@d8?X7k#g2*X>u8NbX-9o94VGI7M_RgsH}#;!$f0< zaBirLb|aggFv-;sTh8v<$TM+o@2B2>{k8ugN){J?^2V!v?sXkg`%*QlRmswseQb+P zI37jft5I$?lG=YYH>InqZ@%%u4d-4{uP$7Fg_X6d3we>$EbAcFM1F{D(xu9XGx1?U z9C+^g`x50#p6!>h!|TB|#dIRN{NZxBx)L{|Or16IgT$N>Sw!Kn+Xv(+pFP^$Ug)>1 z7&Wz`mL4>dISplB(0F1P1}QojW&OY28UQbKh!=GU0C;PDtthx zh?7U@`Ug~C*~T_lB{aYOfc8;qi{^@+{s7VyyqYGJ^0o)ygxkh)I8FQkY^r&#Pp8`Z zd*Hw$7*zIvVmboWCbn4R93Q(26dGMq&?CZn*|-VYo!KX`)8G&XM23Eiw*%PN2De|N&=!w2^guU#ypEQWabSm3R% zdx2b@eOU~=Ab4Bz;H%j+fhPvDFXLOB6U_dSuN#rH?g{71^hNOfuLs`457Qan>@1#I zY`5v9b0PJDQvv;WsTLGG4f@>+FUN%0N)wgC zVvm1N<$!A`23j1MLLjZ_ccQSoi`K_LKgtYBO(>BU$ z)w9{__>;Qe)!Qi<0AEC0Pp7v1$TiphwN8KaiN#H^#aFCXYbxqT&g^x<5}ihD(I+Kt z51N~G@@RUS^<#%?sb9aX-hSQzZ+}{y<2GN-tDD6>m@L=jY#ppv00@Ue7y&wwPZ({Y z%av&O&~eVYphM!h(^W@BZTQgEW@mKwaC^fgQ>@;0NcqRjt#h6${p4W)V5YT=^R9o9 zUi^-fUc_5;a?Oe5jp4CF(>NE+>_yYHcHTQZh&`pAb^I`bP3U?lvF|(WD28r_?fogJ2SD$Cv9nbJepg=3zuE!DQYNbKC%X-&U7TxBS?R zZre|^S+%TzyzWmmOm%=y^cJwAX4U_L_N!V6W!Z@RyP_h#TyF?#q9zw~;Qn z3mktr)+XCuq8e+43f^~)2b}LmLVZ-QfMCQUXq+Fw{|AwbXtd^tSeM0re^ij+9@c7J zI_>YYLJ_;Q$c-)X9o$AUDR!G%0n*K-H1*k2$zeyq(xd<6jF9xrmJg3=VXYdFrKut> zq>h9pGL!X_YlxeZfqD>iej9(sZ@lH@gEc>tGH|N4N7jyIR(DT6fA!|wJ}0-!G_B4) zzY<{?6&r!ditNsn!A+x^cVgojAExLQO`4{gU-!z_+YP^#7=M4fQngNW^m4@26#E<3 zKL|R*Mo2jhWa%itgfZ~u9L;1rCpTm*GWu_c-v{}L^~qrevDriH*fM|2Fc1-zmy6Zn zXMXbPe#7_OZf~pGI&{lUiYAUd>HN@3c=%R0<&6tX6N3 z|K>PLk=IyKo~IU&SRk#)^*m|f4HFOJgSm406GWk`-PD_ZqOVhgrHKwf5mZCu^ZZar8{fVo|5GljGOiSCijNRH>#yC$(4oa|Y+*bmH#S}jV+Of{#k868$`;og3Ve7#y2RGl2f zOAlZ9ydB$)mg|4cvcsiPb<9WcCX}Vs=Rhx~qV1q6#jHC5( zwCdOmYFD7hq!M=j%EO0s>SbP1quJBJ;B4HACr8yXITwN2KIS!I4>6&e*kvc*(;>%B zCw5{DZdU-}^$?3H1ACFC-f!0Qvi6!*V(aCQY`%lIv>$&_*I%w}Bl4`@GuagHt0L=* zw_Um<{`AtN@1MMM>0d8hl9yij=Xc{*Tu(0_q2J3o`Ni@nqAa)4shq9+1oYCd*Ecz0 zwaLsF1Hb@<9s6A~EZOb2NXvsOg1&}sV*CSMKFmUtEZoHd*noWZZrJOxE2~&6q3BCL7rJk z_S~meSDy*i^Y_L_x82vpk(TEMiWn+LE+(qj@a{<>TU~X`_2T3%@xJvlXH=)RzWyaE zh|k`WthgivXMcRF^pfPhB=O`qFYp%b+W6weO-q0E*PJ=i=}GIgXO&U*M$Z}#wzh*xBjV!vF*E!7C(_UrcLbgn96OIPBn=|1)$IlXI+YJ7`s~Q& zaG@sCyA8SOl}oJ5o>VQe(&EY@*|EEo)0GQk$KFYL?G2UtD(|j*sPd`Gf3JM2^3TE+ z9WfDCix-NQik}eoi~lS>EPh9PQG8uIBmRF;8o4X4k{3De_YwI{`Cj?k@=5te@~`CA zmlpo)^AzAYkk`Kg7viZH`X_7-#%)ew{L&3 zZ?k{Ney{y;`?u^rvcGJ9)&5)i8}_#~xiorBAJQB88hwNQF@1-ArM_RkT|cfrsz0tj zt^Z8_Fa0f}NQFga#cY~wGcXf#!MxDC+PvP}Z{BJiGLM*#n9rI&F<&=-WB#xCp0num zoWsru=W6F#=O*V)=M~NyoO_)Io%eq@A8>xddBXXO^CjocoxgIPah`Sl!TBfWyUxG4 zwi~#MB$AG~r`+q@3+{{Dm$|QU?{VMgzQuj3`*!zH_kHfi+^5|C=6==vTlbspKf3?N z{hnt5S?ajh?T!t$#j|e5?9Quc7Y1npjoi$oFC9TiS74Wc?8x*jqkH?~X`g>%hVc=* zW!-6mghxSl%!x(!P!*(a>chqq_vjn0LplZ0U<_aiGM)iKZ%UY_NEY2aIY3)->;QJS zyb!L*OVvEaX3B_<4qMvEyPof+UsqQS(bg@Lz_&+pgo)XB6qxDah4 zrYz_v(uML2A-&y6A7$hwW@j|Sz!*;6X!IwI(y^wYLskVW6FR$J%qxjZ3chAMA3f@# z95!?vq1Xsf&H9Kf?2`&C??TT6-2XHmO{rU0iHRkG6US4wo9AUXa4LVGyQooE%9@O) zbbN(PpKgJ5oQx6KPT~iH&94X(-`SmF%LaEuFyM3qb0}*VU{#P5;`lhu7e~d}aar~c zbW%56fIr}x$+SPnOm{eixlg}+Z2qH?=%~m?#n9BL9izOU?qHRELeDEvD3Gd8*YBL9 zqg`Dfj&c`Ykr#lfjs<`2l>yInI+{}R>9>JdBLarYuk#Ese$=ep>9B4<++3Z5F3P(A zft?KT&v=rjJ#kr^=n z@kQ7=@05d$g@w|iq3fqZfXY+zhIwHixQjmKI0tPm3*2i;O`m@bsgM2Lx*3nU!;B`B z8a4rg;ko@C(gIWB%Px%^=9GHK^NQd~RD+ll!)!=BH+>YP0GrflsK^)W(@2lV`Yjjh zhNamArsh&~Sn})?8r0LLA>y9yj%dEHd&9Gl@r7BJ3%@euOu0-%zd%guDzy@8sJy=k zip(?6QJ;ok%2R(tm-bBoa}M1+A%^sfoQA%ijru%M7-K|RV{eAod_3anG1RMah=~-Y z*=`>kP7SKlWRh!`b#xyCLpI-3Pa5P0ku=KY(=;ijCCWKW#S)CLU+ng|5GhxtMXYMh z%eb63MSj5wW)5V51zrx>JW6j^GU6eiK7o?~+>a8jG_QZ0SIcBN1qSZ4C9^Wf7JPuz z2+ie63*9ZoIcaMys5a??SG!jT#{B`a(VaV}qMd_8R*^QC*RjbpDZ9_bj=2T^iGXqA zlqdjrKvRgBqr0N=aqW*3ml{T&)y>T912bvn{v3eQSYJfHAg(MD=- z87ed$G^WE+>UFYw1o8qO;G{kxh#EAfye|ybU`Y3`=MVuj1yCWlA=*-s$}Ta$2pR^k zh`ThuvBazuJjS~;1ZV*8D@h1XF$Y|Hh#EiLrH6lx>DDxB0}@3V%)(#J4JP4)M^@WgFccF?T-NaFqu*txNmi|l;fcxENGTV z?~Z>E3soQ=E8oe7omK3R(su)cOk*Zu(_wkt?IYob1jAG}CYbpto0r`_ktR6EOi>At z<|pq0DrEruO0t5U(Va9j4a*3WN*afCOF1kgJZOS*%r(i_I>wU31EAYhq2r2t2vs;W z#2^`f8X+bS{Y(msrlLN~&4}h47$%UnIg5W-dOC@gI!-L6{RVZR(*-=sWDLfGtT7s7 zM>iagsQbC;l8~p~LI_L?2s(x@<+pxL`j?E9!BF>s`G^Mr6l^di`ht4v0(S+PW_Lm~ zqPNSCKVpL}DN~v-B9JmDemI!o9@LqF?U~%5oz%=O5&QHwxg>Ik!ODja8JJQg8sdM- z3{cuc)%Co?v^w13B3Y=9H7LW(8$*ardMfj9e@Mhfa$?t@>N&U(-9Z5m5CL#KskMkD z7!zp#0gUJtgq`XBV2JjRRfjB!-2ubSnX$Z2NXK8RMWMplPZ%L=+qU$&(n%tc#FDNC zSdbD3UufCBW!o1K`1=Y(AG?khSP?cc zg+rJ5*n*Xgs~JbZ)qqk!kfim#1V%x$390l@@A}Ol$q!2g?bc*Fma=?TtVVWdr`Y>uCGE(S5#8iJf@L>>I z3`boUBW1?>whX5L5Jo$9=sAuhRsi=Pcumhm;vmp7c+Z!5X=SpkWP~_naTg-6$zrrD zV;dh$x7_O#SKMZg$t|Jd6^5h1nS=C|R|1jrg{+r&97qhj5~tAz-;~kIijiKligp-H zLf94`#TK+K+lIS%p5p!I@(h2C;ZyT3)g03V_u*&($sa8#evhxW`D=^Y@;)IR7oTJ_ zNIb;sBTpzR5#sH1s+H7?6I{WejQqp*`mETH>OJ)5ix8PiGtU4O%J!+dfI*oE(WufF z+`&4UW?3&5;&Vd0M@YJkLnF8V5IRFo{VWTGr+tZWIyw5D>0La* zqa;DSN|fV_?Q~2N@@h36^r#RImE8sv@jaRHsat30kCT#jYHe=5vemn#+@Cy#m48D#W>LVUskf+$WD3^RYYWSC=}oc?yT{0$5^ z8vSMQO)mFLcUfo3#=L<>KZPC|MnsWMa_8u%MML=uC@+9MTaH!s0T*F%cZIkF5~BP5 zJbhf4^NU5D;t>ZKGvJVAYxzms&$v9lLK4ZCOJ7 z%o#-(`9>1v%vyia!y>zj&M1fgaY>Y5Ghz=1FcMP!9nt-r@i65fobZ>+c?N$Wtn>9k)VR^qB=I?=El)*& zMN;}{5E~0WBQ`neM2HU^0N|*Xi89mW9q6nyKZmMpP%cj5VwNr1p9Eq(C@VcWmRBV15ZebdlhDZ=*c1xYg`L4RYdPD z#?%W^(kg!uP?$3%J6+)u9R|j8--qCrU!9YEwa1 zYdfQ_5Lnzn%1DSvCL&57Ty5I{rpB|?ib!ZKqlkYri@^wHDwPSR$nX?`%4I5`KS`l3 zGtMuWl~TJ(yQa+aQDq>JC1NE^iTez~j!5%cOAE+^B5g)zI&nyXUU-cpAYz~~af_51 zWUZ3W&_UA3aJvE`hz8X~I!l&=2&nV!O4Y5!)F|TU;RcZ?Q-ThHv<}(pXMvkAFIukj z=pKI-O9CUSD`pKG9M=6v1>givIaMpJxx}(`%Ie}mU^ykZn=p>7l<2hzb~VxjGEi}7 zka9#sOjHCyRxXc?4@pnM8_@W>bwSh^Av(%gGV2;u`$)>_CJ~Ys1C(1vL~;roW?Z5;`X9<5Ue)KgD@h=Zit9tiQP%dH-U@1Bq#>QlN)Fnf9ARX@EsAY)1q#IHXq~ma# zSs~e)#DR@GO0GBH_$W$c`6x{X;5_0J<7@3}sp5!+N;ud^0*|=1N@9d-3z2A`8%URq zR;z5AA#;TEqcRb~xgB9z!0rTx!@`4*s2sYQNl=7Ex|kO(vI9SmRSF~kUUsm|SUt_zi6j?%k{&`uu#-{qOP3mf8gRYDPBmVE9i)gOea=lEI8^kc2aR= zNoou>DNLymX);k6lVpYsPGK#^Go!Kh90V*?N~;>P>_`OGDg=R6@ks+kQ45zR!vXs{ z0FpP6F8v5pClnB{NMKZJ(l|7lkZYx%0E2@=WwC|sLk&2r-AUpC@|JEy5=yMq9luHw ze_UsS0IcL1RFQ!h$gT&On#Q-;o+rk!RoPy)ok4sI0ZGGQ=^A4R;K3j`tv!e2s0*(N zT#mA#B!`FtJ?L$}5yM&viCln7q5=}_wiT2AXY8e=Dp8Hiu7x2J#1d}l#Kquh)Yzo9 zC3G@a3c}hz*Pxh{qUj6(#3+b25Rr)Ve+3^E48Y}@`Iq+fzf24uss|U z2Ip~8>Uf^vsdRvDMSb^FKvp4fF2@lI0R|)~;#h2jveO|IBB{Ar7yE=ZM$l%lF47vH zrybJP4kNe_ebO_dn4}6u6q*tSZUB%RYPO98QwcdwJQ@fmaAL&Ipwa+QEmSzte^oX7 z1R8mpF-zb(8Q7aP`NP!m1xHZ#Igrq{JQ5LB1QQmBCb(9!)x;2wm@}KButA0F9-_1! z0MlSeL#YZrkxW}F5W31O^907z2H+-~-Bqy$7uA7DE=zl@w3PS#hy9P`3%uPqkRZtv zZ()8C^OT4kLyrkjoUZI!gwZ0Ce@NNvl)-!>4NTo5Ri#T062vEX1%Pi3m`@OxVm--d zla@GeC@_Cyax%gpJH0>rZyvjFNd9)kL0q5cR_Xt^o#iD`0!I@dZ3H=+U5;xgQG&|C z0P_ft>5xMm2Gfc7=Bv)%Emog%j1HW-b5+sV=>7D1@2u<9PpqX*5-gs4e_mQEPMzM^ zw$3%&R<%PG+?!^f7pJbc;u$}2P}D%B%PX7P%gf#NPE_~eg+?vX+IDKw-GzRzyw)49 z!9`B@Yw$g%hLz)$8@LkoFJS-e0Q4jl^MIYG1Ran_&?vzK4x+ja(&&aICIfx3pF@NJ z;85l{R(!dk%mpXQ(B1JVf5C;&aAaEors6ViK_(a1i+G8Y2$4#lYwNj_tb_^(tkNuX z7p0ff+EsvA$#ApS?iD|MI9e<=Z)^rhZNomQpFNn~s&D5`HvIRo2z+7)XE+$q{C9Sl8nzxwSDE(y7J?%a39)#B>!o;&xZ&wpM8_uv2hugLBD@1K1_{7B^> zX5)xDdO2oeUJq_8deu;_1!i45Ft1sf;kt?m_*ZO;K&xAQDC|f%&O)CyR2i-C1OGl;yh0W zn;pnqLd-k>D>$2rqbcbslt5rmX)ODmQhQ>AMbwV&)py6l#={bEk&zOyzB-wsN7J$Y z&sW@}=|CNcfBbK3qQ=UWznN||&#VS27&K9;Vs+bXEDQN8keZa3ePkKl9ElrOr;L=Y zP$d%!YE6v-JS2yD3RVul+|??|x49A-HbOQNh~v}Wdh!Wq@ZWjzcOlW}@AC5#<>x1b z{02$22QPT>u@V`I6t14d3=r=Dm3_=w%T?l4YU|BGe-rWQWdZbcz*3MidxuIG#rCeT z-LO@CW2Z@ske*MWOK#g%;UM3J=F|5IF*|;Y`nDp)atGj8beFYd&gEGy`13Z|J(W4m z&Jndz*{PhZJY0FS^6tv7RDQMcL7=W8#C20}0b7H)s?KXTm6fE_bchHWBCmNw&JX|g zMx3%Yed#QefGN;cq;Ibw*VH2`3zdz@kk#Q`x2n(~B{x{^c3dL2n&ra=wgVH{&RzoO z3pSX z89*7l8XOwl9cCT69!MUD9;6@KAv7fhB|s%wC3+>sCLAW3Com^!C!#0NDJCigD$XlZ zELtpRk}z5@gfSj6GBdn1PBfx7hBy*9zBvXth&kjsbUKufJc6#qU8w4YX6#~q_mVX~Eclj2c zhhbnCc+2c)b~cu?{~wGa2vn%iV2%ZjvBU{3;396oCESRca2Yq_7Tk*4a69h6owy5k z;~w0L`*1%Vz=L=Q591L$ipTIcp1_lM3Qyx1tne(J!+-O50ax%MUc$?G1+U^YypA{U zCf>r^cn9y|J-m+(a240^AwI&#_ynKgGklIO@Fl*&*Z2nC;yZkgAMhi7!q4~xzv4Ii zjz91x{=yo6L!yO(2BAZb0R|h4u$bWB5pW$5j5Mod2$qE8sg_wAU$?R)Tep5kQM7F5 zYQ=+$0e`Aea-_v+Scf58Rs*TA_4`$J|E8oD{~c9o!~0rUug0bFR(F|=ca8F{GrdqD z2*q6H7WzoHb4{JhHeJ#bA}N{5-Iem8(WRf_1=1$@c-~AKZpfOwi5Jh7HLGYs5@e^E zV)U^gw#KD-C%2|FHC+KfvFf}_%ig5**}f_1kbm2w-izK}Y5FL&rPIY&uKSo>s`_lh zVvuUI()HCKCp#Y`k7R8#Q1oLK1MRCJm2=ZOA4#7WYcr=P3*OpHvZuZ7qiv;lgxM=K37o!ezI~YUJ9h!bSw$Re_>C4uemg2OmT+b{?YN zkV+!tz6m)5N=-PVq2N4ICz4dDiN0_RRm|<71WrqqmbfcMQN^;@%WbMzNh=#B8P%|0 zO3ApMYaWV*RdH!*xbR4ahC?ishSQ6hsc&ef^5<)?aUG Date: Thu, 25 May 2017 22:57:35 +0200 Subject: [PATCH 0070/1347] [seti] add information_for_contributors --- extensions/theme-seti/build/update-icon-theme.js | 8 ++++++++ extensions/theme-seti/icons/vs-seti-icon-theme.json | 8 ++++++++ 2 files changed, 16 insertions(+) diff --git a/extensions/theme-seti/build/update-icon-theme.js b/extensions/theme-seti/build/update-icon-theme.js index 7f44c3ac245..a2a2bbd840c 100644 --- a/extensions/theme-seti/build/update-icon-theme.js +++ b/extensions/theme-seti/build/update-icon-theme.js @@ -212,6 +212,14 @@ exports.update = function () { } var res = { + information_for_contributors: [ + 'This file has been generated from data in https://github.com/jesseweed/seti-ui:', + '- icon definitions: styles/_fonts/seti.less', + '- icon colors: styles/ui-variables.less', + '- file associations: styles/icons/mapping.less', + 'If you want to provide a fix or improvement, please create a pull request against the jesseweed/seti-ui repository.', + 'Once accepted there, we are happy to receive an update request.', + ], fonts: [{ id: "seti", src: [{ "path": "./seti.woff", "format": "woff" }], diff --git a/extensions/theme-seti/icons/vs-seti-icon-theme.json b/extensions/theme-seti/icons/vs-seti-icon-theme.json index b26e557e5d3..46e757af3f6 100644 --- a/extensions/theme-seti/icons/vs-seti-icon-theme.json +++ b/extensions/theme-seti/icons/vs-seti-icon-theme.json @@ -1,4 +1,12 @@ { + "information_for_contributors": [ + "This file has been generated from data in https://github.com/jesseweed/seti-ui:", + "- icon definitions: styles/_fonts/seti.less", + "- icon colors: styles/ui-variables.less", + "- file associations: styles/icons/mapping.less", + "If you want to provide a fix or improvement, please create a pull request against the jesseweed/seti-ui repository.", + "Once accepted there, we are happy to receive an update request." + ], "fonts": [ { "id": "seti", -- GitLab From b6cb1b7a47f1dfbb312445b5ce4868a611b2e7be Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Thu, 25 May 2017 14:32:00 -0700 Subject: [PATCH 0071/1347] Comments --- src/vs/editor/contrib/suggest/browser/suggestWidget.ts | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index c27e0dbaa95..c5559659a7f 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -953,11 +953,14 @@ export class SuggestWidget implements IContentWidget, IDelegate if (hasClass(this.element, 'docs-side')) { if (this.details.element.offsetHeight > this.listElement.offsetHeight) { + + // Fix for #26416 + // Docs is bigger than list and widget is above cursor, apply margin-top so that list appears right above cursor if (hasClass(this.element, 'widget-above')) { - // Docs is bigger than list and widget is above cursor, apply margin-top so that list appears right above cursor this.listElement.style.marginTop = `${this.details.element.offsetHeight - this.listElement.offsetHeight}px`; } + // Fix for #26244 if (hasClass(this.element, 'list-right')) { addClass(this.listElement, 'empty-left-border'); removeClass(this.listElement, 'empty-right-border'); @@ -970,6 +973,7 @@ export class SuggestWidget implements IContentWidget, IDelegate removeClass(this.details.element, 'empty-right-border'); return; } else { + // Fix for #26244 if (hasClass(this.element, 'list-right')) { addClass(this.details.element, 'empty-right-border'); removeClass(this.details.element, 'empty-left-border'); @@ -983,6 +987,7 @@ export class SuggestWidget implements IContentWidget, IDelegate } } + // Reset margin-top that was set as Fix for #26416 this.listElement.style.marginTop = '0px'; } -- GitLab From f17f097cc9e8a158a9d0af02e66a24addf7295e1 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 25 May 2017 14:31:52 -0700 Subject: [PATCH 0072/1347] Extract merge-conflict colors as workbench colors (#27299) --- .../merge-conflict/src/mergeDecorator.ts | 28 ++++++++----------- src/vs/platform/theme/common/colorRegistry.ts | 18 ++++++++++++ 2 files changed, 29 insertions(+), 17 deletions(-) diff --git a/extensions/merge-conflict/src/mergeDecorator.ts b/extensions/merge-conflict/src/mergeDecorator.ts index f6d0135aad9..39888f727e6 100644 --- a/extensions/merge-conflict/src/mergeDecorator.ts +++ b/extensions/merge-conflict/src/mergeDecorator.ts @@ -13,9 +13,6 @@ export default class MergeDectorator implements vscode.Disposable { private decorationUsesWholeLine: boolean = true; // Useful for debugging, set to false to see exact match ranges - // TODO: Move to config? - private currentColorRgb = `32,200,94`; - private incomingColorRgb = `24,134,255`; private config: interfaces.IExtensionConfiguration; private tracker: interfaces.IDocumentMergeConflictTracker; @@ -69,21 +66,19 @@ export default class MergeDectorator implements vscode.Disposable { // Create decorators if (config.enableDecorations || config.enableEditorOverview) { this.decorations['current.content'] = vscode.window.createTextEditorDecorationType( - this.generateBlockRenderOptions(this.currentColorRgb, config) + this.generateBlockRenderOptions('merge.currentContentBackground', 'overviewRuler.currentContentForeground', config) ); this.decorations['incoming.content'] = vscode.window.createTextEditorDecorationType( - this.generateBlockRenderOptions(this.incomingColorRgb, config) + this.generateBlockRenderOptions('merge.incomingContentBackground', 'overviewRuler.incomingContentForeground', config) ); } if (config.enableDecorations) { this.decorations['current.header'] = vscode.window.createTextEditorDecorationType({ - // backgroundColor: 'rgba(255, 0, 0, 0.01)', - // border: '2px solid red', isWholeLine: this.decorationUsesWholeLine, - backgroundColor: `rgba(${this.currentColorRgb}, 1.0)`, - color: 'white', + backgroundColor: new vscode.ThemeColor('merge.currentHeaderBackground'), + color: new vscode.ThemeColor('editor.foreground'), after: { contentText: ' ' + localize('currentChange', '(Current change)'), color: 'rgba(0, 0, 0, 0.7)' @@ -91,14 +86,13 @@ export default class MergeDectorator implements vscode.Disposable { }); this.decorations['splitter'] = vscode.window.createTextEditorDecorationType({ - backgroundColor: 'rgba(0, 0, 0, 0.25)', - color: 'white', + color: new vscode.ThemeColor('editor.foreground'), isWholeLine: this.decorationUsesWholeLine, }); this.decorations['incoming.header'] = vscode.window.createTextEditorDecorationType({ - backgroundColor: `rgba(${this.incomingColorRgb}, 1.0)`, - color: 'white', + backgroundColor: new vscode.ThemeColor('merge.incomingHeaderBackground'), + color: new vscode.ThemeColor('editor.foreground'), isWholeLine: this.decorationUsesWholeLine, after: { contentText: ' ' + localize('incomingChange', '(Incoming change)'), @@ -118,17 +112,17 @@ export default class MergeDectorator implements vscode.Disposable { this.decorations = {}; } - private generateBlockRenderOptions(color: string, config: interfaces.IExtensionConfiguration): vscode.DecorationRenderOptions { + private generateBlockRenderOptions(backgroundColor: string, overviewRulerColor: string, config: interfaces.IExtensionConfiguration): vscode.DecorationRenderOptions { - let renderOptions: any = {}; + let renderOptions: vscode.DecorationRenderOptions = {}; if (config.enableDecorations) { - renderOptions.backgroundColor = `rgba(${color}, 0.2)`; + renderOptions.backgroundColor = new vscode.ThemeColor(backgroundColor); renderOptions.isWholeLine = this.decorationUsesWholeLine; } if (config.enableEditorOverview) { - renderOptions.overviewRulerColor = `rgba(${color}, 0.5)`; + renderOptions.overviewRulerColor = new vscode.ThemeColor(overviewRulerColor); renderOptions.overviewRulerLane = vscode.OverviewRulerLane.Full; } diff --git a/src/vs/platform/theme/common/colorRegistry.ts b/src/vs/platform/theme/common/colorRegistry.ts index bc3da9fed16..b908d663df3 100644 --- a/src/vs/platform/theme/common/colorRegistry.ts +++ b/src/vs/platform/theme/common/colorRegistry.ts @@ -254,6 +254,24 @@ export const diffRemoved = registerColor('diffEditor.removedTextBackground', { d export const diffInsertedOutline = registerColor('diffEditor.insertedTextBorder', { dark: null, light: null, hc: '#33ff2eff' }, nls.localize('diffEditorInsertedOutline', 'Outline color for the text that got inserted.')); export const diffRemovedOutline = registerColor('diffEditor.removedTextBorder', { dark: null, light: null, hc: '#FF008F' }, nls.localize('diffEditorRemovedOutline', 'Outline color for text that got removed.')); +/** + * Merge-conflict colors + */ + +const headerTransparency = 1; +const currentBaseColor = Color.fromHex('#20C85E').transparent(headerTransparency); +const incomingBaseColor = Color.fromHex('#1886FF').transparent(headerTransparency); +const contentTransparency = 0.2; +const rulerTransparency = 0.5; + +export const mergeCurrentHeaderBackground = registerColor('merge.currentHeaderBackground', { dark: currentBaseColor, light: currentBaseColor, hc: currentBaseColor }, nls.localize('mergeCurrentHeaderBackground', 'Current header background in inline merge-conflict.')); +export const mergeCurrentContentBackground = registerColor('merge.currentContentBackground', { dark: transparent(mergeCurrentHeaderBackground, contentTransparency), light: transparent(mergeCurrentHeaderBackground, contentTransparency), hc: transparent(mergeCurrentHeaderBackground, contentTransparency) }, nls.localize('mergeCurrentContentBackground', 'Current content background in inline merge-conflict.')); +export const mergeIncomingHeaderBackground = registerColor('merge.incomingHeaderBackground', { dark: incomingBaseColor, light: incomingBaseColor, hc: incomingBaseColor }, nls.localize('mergeIncomingHeaderBackground', 'Incoming header background in inline merge-conflict.')); +export const mergeIncomingContentBackground = registerColor('merge.incomingContentBackground', { dark: transparent(mergeIncomingHeaderBackground, contentTransparency), light: transparent(mergeIncomingHeaderBackground, contentTransparency), hc: transparent(mergeIncomingHeaderBackground, contentTransparency) }, nls.localize('mergeIncomingContentBackground', 'Incoming content background in inline merge-conflict.')); + +export const overviewRulerCurrentContentForeground = registerColor('overviewRuler.currentContentForeground', { dark: transparent(mergeCurrentHeaderBackground, rulerTransparency), light: transparent(mergeCurrentHeaderBackground, rulerTransparency), hc: transparent(mergeCurrentHeaderBackground, rulerTransparency) }, nls.localize('overviewRulerCurrentContentForeground', 'Current overview ruler foreground for inline merge-conflict.')); +export const overviewRulerIncomingContentForeground = registerColor('overviewRuler.incomingContentForeground', { dark: transparent(mergeIncomingHeaderBackground, rulerTransparency), light: transparent(mergeIncomingHeaderBackground, rulerTransparency), hc: transparent(mergeIncomingHeaderBackground, rulerTransparency) }, nls.localize('overviewRulerIncomingContentForeground', 'Incoming overview ruler foreground for inline merge-conflict.')); + // ----- color functions export function darken(colorValue: ColorValue, factor: number): ColorFunction { -- GitLab From 9f48af79ad996dfa6ab3a9ec9b67a79c5919ee8b Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 25 May 2017 14:40:05 -0700 Subject: [PATCH 0073/1347] Tune merge-conflict colors (#27299) --- src/vs/platform/theme/common/colorRegistry.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/vs/platform/theme/common/colorRegistry.ts b/src/vs/platform/theme/common/colorRegistry.ts index b908d663df3..5f3a474f034 100644 --- a/src/vs/platform/theme/common/colorRegistry.ts +++ b/src/vs/platform/theme/common/colorRegistry.ts @@ -258,11 +258,11 @@ export const diffRemovedOutline = registerColor('diffEditor.removedTextBorder', * Merge-conflict colors */ -const headerTransparency = 1; -const currentBaseColor = Color.fromHex('#20C85E').transparent(headerTransparency); -const incomingBaseColor = Color.fromHex('#1886FF').transparent(headerTransparency); -const contentTransparency = 0.2; -const rulerTransparency = 0.5; +const headerTransparency = 0.5; +const currentBaseColor = Color.fromHex('#40C8AE').transparent(headerTransparency); +const incomingBaseColor = Color.fromHex('#40A6FF').transparent(headerTransparency); +const contentTransparency = 0.4; +const rulerTransparency = 1; export const mergeCurrentHeaderBackground = registerColor('merge.currentHeaderBackground', { dark: currentBaseColor, light: currentBaseColor, hc: currentBaseColor }, nls.localize('mergeCurrentHeaderBackground', 'Current header background in inline merge-conflict.')); export const mergeCurrentContentBackground = registerColor('merge.currentContentBackground', { dark: transparent(mergeCurrentHeaderBackground, contentTransparency), light: transparent(mergeCurrentHeaderBackground, contentTransparency), hc: transparent(mergeCurrentHeaderBackground, contentTransparency) }, nls.localize('mergeCurrentContentBackground', 'Current content background in inline merge-conflict.')); -- GitLab From 6d00bd977be02b60d2c7f1f333fc7d9270ef3c0b Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Thu, 25 May 2017 15:18:05 -0700 Subject: [PATCH 0074/1347] Add TSC Task Provider (#27093) * extract standardLanguageDescriptions to constant * Remove client variable * Move VersionStatus into a class * Add TSC Task Provider Fixes #26079 Adds a task provider for building typescript projects. * Make ts loading lazy --- extensions/typescript/package.json | 5 +- .../src/features/jsDocCompletionProvider.ts | 6 +- .../typescript/src/features/taskProvider.ts | 110 ++++++++++++++++++ extensions/typescript/src/typescriptMain.ts | 109 +++++++++++------ .../typescript/src/typescriptServiceClient.ts | 10 +- .../typescript/src/utils/versionStatus.ts | 69 ++++++----- src/vs/workbench/api/node/extHostTask.ts | 2 +- 7 files changed, 235 insertions(+), 76 deletions(-) create mode 100644 extensions/typescript/src/features/taskProvider.ts diff --git a/extensions/typescript/package.json b/extensions/typescript/package.json index 461cb773a4d..b039fac9631 100644 --- a/extensions/typescript/package.json +++ b/extensions/typescript/package.json @@ -34,7 +34,10 @@ "onCommand:typescript.selectTypeScriptVersion", "onCommand:javascript.goToProjectConfig", "onCommand:typescript.goToProjectConfig", - "onCommand:typescript.openTsServerLog" + "onCommand:typescript.openTsServerLog", + "onCommand:workbench.action.tasks.runTask", + "onCommand:workbench.action.tasks.build", + "onCommand:workbench.action.tasks.test" ], "main": "./out/typescriptMain", "contributes": { diff --git a/extensions/typescript/src/features/jsDocCompletionProvider.ts b/extensions/typescript/src/features/jsDocCompletionProvider.ts index da02e942bfc..502cf89c42c 100644 --- a/extensions/typescript/src/features/jsDocCompletionProvider.ts +++ b/extensions/typescript/src/features/jsDocCompletionProvider.ts @@ -88,7 +88,7 @@ export class TryCompleteJsDocCommand { static COMMAND_NAME = '_typeScript.tryCompleteJsDoc'; constructor( - private client: ITypescriptServiceClient + private lazyClient: () => ITypescriptServiceClient ) { } /** @@ -96,7 +96,7 @@ export class TryCompleteJsDocCommand { * if possible, otherwise falling back to a default comment format. */ public tryCompleteJsDoc(resource: Uri, start: Position, shouldGetJSDocFromTSServer: boolean): Thenable { - const file = this.client.normalizePath(resource); + const file = this.lazyClient().normalizePath(resource); if (!file) { return Promise.resolve(false); } @@ -126,7 +126,7 @@ export class TryCompleteJsDocCommand { offset: position.character + 1 }; return Promise.race([ - this.client.execute('docCommentTemplate', args), + this.lazyClient().execute('docCommentTemplate', args), new Promise((_, reject) => setTimeout(reject, 250)) ]).then((res: DocCommandTemplateResponse) => { if (!res || !res.body) { diff --git a/extensions/typescript/src/features/taskProvider.ts b/extensions/typescript/src/features/taskProvider.ts new file mode 100644 index 00000000000..76528021983 --- /dev/null +++ b/extensions/typescript/src/features/taskProvider.ts @@ -0,0 +1,110 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +'use strict'; + +import * as fs from 'fs'; +import * as path from 'path'; +import * as vscode from 'vscode'; + +import * as Proto from '../protocol'; +import TypeScriptServiceClient from '../typescriptServiceClient'; + + +const exists = (file: string): Promise => + new Promise((resolve, _reject) => { + fs.exists(file, (value: boolean) => { + resolve(value); + }); + }); + +export default class TypeScriptTaskProvider implements vscode.TaskProvider { + + public constructor( + private readonly lazyClient: () => TypeScriptServiceClient + ) { } + + async provideTasks(token: vscode.CancellationToken): Promise { + const rootPath = vscode.workspace.rootPath; + if (!rootPath) { + return []; + } + + const projects = (await this.getConfigForActiveFile(token)).concat(await this.getConfigsForWorkspace()); + const command = await this.getCommand(); + + return projects + .filter((x, i) => projects.indexOf(x) === i) + .map(configFile => { + const configFileName = path.relative(rootPath, configFile); + const buildTask = new vscode.ShellTask(`tsc: build ${configFileName}`, `${command} -p ${configFile}`, '$tsc'); + buildTask.group = vscode.TaskGroup.Build; + return buildTask; + }); + } + + + private async getConfigForActiveFile(token: vscode.CancellationToken): Promise { + const editor = vscode.window.activeTextEditor; + if (editor) { + if (path.basename(editor.document.fileName).match(/^tsconfig\.(.\.)?json$/)) { + return [editor.document.fileName]; + } + } + + const file = this.getActiveTypeScriptFile(); + if (!file) { + return []; + } + + const res: Proto.ProjectInfoResponse = await this.lazyClient().execute( + 'projectInfo', + { file, needFileNameList: false } as protocol.ProjectInfoRequestArgs, + token); + + if (!res || !res.body) { + return []; + } + + const { configFileName } = res.body; + if (configFileName && configFileName.indexOf('/dev/null/') !== 0) { + return [configFileName]; + } + return []; + } + + private async getConfigsForWorkspace(): Promise { + if (!vscode.workspace.rootPath) { + return []; + } + const rootTsConfig = path.join(vscode.workspace.rootPath, 'tsconfig.json'); + if (!await exists(rootTsConfig)) { + return []; + } + return [rootTsConfig]; + } + + private async getCommand(): Promise { + const platform = process.platform; + if (platform === 'win32' && await exists(path.join(vscode.workspace.rootPath!, 'node_modules', '.bin', 'tsc.cmd'))) { + return path.join('.', 'node_modules', '.bin', 'tsc.cmd'); + } else if ((platform === 'linux' || platform === 'darwin') && await exists(path.join(vscode.workspace.rootPath!, 'node_modules', '.bin', 'tsc'))) { + return path.join('.', 'node_modules', '.bin', 'tsc'); + } else { + return 'tsc'; + } + } + + private getActiveTypeScriptFile(): string | null { + const editor = vscode.window.activeTextEditor; + if (editor) { + const document = editor.document; + if (document && (document.languageId === 'typescript' || document.languageId === 'typescriptreact')) { + return this.lazyClient().normalizePath(document.uri); + } + } + return null; + } +} \ No newline at end of file diff --git a/extensions/typescript/src/typescriptMain.ts b/extensions/typescript/src/typescriptMain.ts index 9949d0db9d2..07a666936b9 100644 --- a/extensions/typescript/src/typescriptMain.ts +++ b/extensions/typescript/src/typescriptMain.ts @@ -41,13 +41,14 @@ import CodeActionProvider from './features/codeActionProvider'; import ReferenceCodeLensProvider from './features/referencesCodeLensProvider'; import { JsDocCompletionProvider, TryCompleteJsDocCommand } from './features/jsDocCompletionProvider'; import { DirectiveCommentCompletionProvider } from './features/directiveCommentCompletionProvider'; +import TypeScriptTaskProvider from './features/taskProvider'; import ImplementationCodeLensProvider from './features/implementationsCodeLensProvider'; import * as BuildStatus from './utils/buildStatus'; import * as ProjectStatus from './utils/projectStatus'; import TypingsStatus, { AtaProgressReporter } from './utils/typingsStatus'; -import * as VersionStatus from './utils/versionStatus'; +import VersionStatus from './utils/versionStatus'; import { getContributedTypeScriptServerPlugins, TypeScriptServerPlugin } from "./utils/plugins"; interface LanguageDescription { @@ -67,72 +68,100 @@ interface ProjectConfigMessageItem extends MessageItem { id: ProjectConfigAction; } +const MODE_ID_TS = 'typescript'; +const MODE_ID_TSX = 'typescriptreact'; +const MODE_ID_JS = 'javascript'; +const MODE_ID_JSX = 'javascriptreact'; + +const standardLanguageDescriptions: LanguageDescription[] = [ + { + id: 'typescript', + diagnosticSource: 'ts', + modeIds: [MODE_ID_TS, MODE_ID_TSX], + configFile: 'tsconfig.json' + }, { + id: 'javascript', + diagnosticSource: 'js', + modeIds: [MODE_ID_JS, MODE_ID_JSX], + configFile: 'jsconfig.json' + } +]; export function activate(context: ExtensionContext): void { - const MODE_ID_TS = 'typescript'; - const MODE_ID_TSX = 'typescriptreact'; - const MODE_ID_JS = 'javascript'; - const MODE_ID_JSX = 'javascriptreact'; - const plugins = getContributedTypeScriptServerPlugins(); - const clientHost = new TypeScriptServiceClientHost([ - { - id: 'typescript', - diagnosticSource: 'ts', - modeIds: [MODE_ID_TS, MODE_ID_TSX], - configFile: 'tsconfig.json' - }, - { - id: 'javascript', - diagnosticSource: 'js', - modeIds: [MODE_ID_JS, MODE_ID_JSX], - configFile: 'jsconfig.json' - } - ], context.storagePath, context.globalState, context.workspaceState, plugins); - context.subscriptions.push(clientHost); - const client = clientHost.serviceClient; + const lazyClientHost = (() => { + let clientHost: TypeScriptServiceClientHost | undefined; + return () => { + if (!clientHost) { + clientHost = new TypeScriptServiceClientHost(standardLanguageDescriptions, context.storagePath, context.globalState, context.workspaceState, plugins); + context.subscriptions.push(clientHost); + + const host = clientHost; + clientHost.serviceClient.onReady().then(() => { + context.subscriptions.push(ProjectStatus.create(host.serviceClient, + path => new Promise(resolve => setTimeout(() => resolve(host.handles(path)), 750)), + context.workspaceState)); + }, () => { + // Nothing to do here. The client did show a message; + }); + } + return clientHost; + }; + })(); + context.subscriptions.push(commands.registerCommand('typescript.reloadProjects', () => { - clientHost.reloadProjects(); + lazyClientHost().reloadProjects(); })); context.subscriptions.push(commands.registerCommand('javascript.reloadProjects', () => { - clientHost.reloadProjects(); + lazyClientHost().reloadProjects(); })); context.subscriptions.push(commands.registerCommand('typescript.selectTypeScriptVersion', () => { - client.onVersionStatusClicked(); + lazyClientHost().serviceClient.onVersionStatusClicked(); })); context.subscriptions.push(commands.registerCommand('typescript.openTsServerLog', () => { - client.openTsServerLogFile(); + lazyClientHost().serviceClient.openTsServerLogFile(); })); context.subscriptions.push(commands.registerCommand('typescript.restartTsServer', () => { - client.restartTsServer(); + lazyClientHost().serviceClient.restartTsServer(); })); + context.subscriptions.push(workspace.registerTaskProvider(new TypeScriptTaskProvider(() => lazyClientHost().serviceClient))); + const goToProjectConfig = (isTypeScript: boolean) => { const editor = window.activeTextEditor; if (editor) { - clientHost.goToProjectConfig(isTypeScript, editor.document.uri); + lazyClientHost().goToProjectConfig(isTypeScript, editor.document.uri); } }; context.subscriptions.push(commands.registerCommand('typescript.goToProjectConfig', goToProjectConfig.bind(null, true))); context.subscriptions.push(commands.registerCommand('javascript.goToProjectConfig', goToProjectConfig.bind(null, false))); - const jsDocCompletionCommand = new TryCompleteJsDocCommand(client); + const jsDocCompletionCommand = new TryCompleteJsDocCommand(() => lazyClientHost().serviceClient); context.subscriptions.push(commands.registerCommand(TryCompleteJsDocCommand.COMMAND_NAME, jsDocCompletionCommand.tryCompleteJsDoc, jsDocCompletionCommand)); - window.onDidChangeActiveTextEditor(VersionStatus.showHideStatus, null, context.subscriptions); - client.onReady().then(() => { - context.subscriptions.push(ProjectStatus.create(client, - path => new Promise(resolve => setTimeout(() => resolve(clientHost.handles(path)), 750)), - context.workspaceState)); - }, () => { - // Nothing to do here. The client did show a message; - }); + const supportedLanguage = [].concat.apply([], standardLanguageDescriptions.map(x => x.modeIds).concat(plugins.map(x => x.languages))); + function didOpenTextDocument(textDocument: TextDocument): boolean { + if (supportedLanguage.indexOf(textDocument.languageId) >= 0) { + openListener.dispose(); + // Force activation + void lazyClientHost(); + return true; + } + return false; + }; + const openListener = workspace.onDidOpenTextDocument(didOpenTextDocument); + for (let textDocument of workspace.textDocuments) { + if (didOpenTextDocument(textDocument)) { + break; + } + } + BuildStatus.update({ queueLength: 0 }); } @@ -423,6 +452,7 @@ class TypeScriptServiceClientHost implements ITypescriptServiceClientHost { private languages: LanguageProvider[] = []; private languagePerId: ObjectMap; private readonly disposables: Disposable[] = []; + private readonly versionStatus: VersionStatus; constructor( descriptions: LanguageDescription[], @@ -446,7 +476,10 @@ class TypeScriptServiceClientHost implements ITypescriptServiceClientHost { configFileWatcher.onDidDelete(handleProjectCreateOrDelete, this, this.disposables); configFileWatcher.onDidChange(handleProjectChange, this, this.disposables); - this.client = new TypeScriptServiceClient(this, storagePath, globalState, workspaceState, plugins, this.disposables); + this.versionStatus = new VersionStatus(); + this.disposables.push(this.versionStatus); + + this.client = new TypeScriptServiceClient(this, storagePath, globalState, workspaceState, this.versionStatus, plugins, this.disposables); this.languagePerId = Object.create(null); for (const description of descriptions) { const manager = new LanguageProvider(this.client, description); diff --git a/extensions/typescript/src/typescriptServiceClient.ts b/extensions/typescript/src/typescriptServiceClient.ts index cf2b7c3be6f..5e22350feb0 100644 --- a/extensions/typescript/src/typescriptServiceClient.ts +++ b/extensions/typescript/src/typescriptServiceClient.ts @@ -18,7 +18,7 @@ import { ITypescriptServiceClient, ITypescriptServiceClientHost, API } from './t import { TypeScriptServerPlugin } from './utils/plugins'; import Logger from './utils/logger'; -import * as VersionStatus from './utils/versionStatus'; +import VersionStatus from './utils/versionStatus'; import * as is from './utils/is'; import * as nls from 'vscode-nls'; @@ -141,7 +141,9 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient host: ITypescriptServiceClientHost, storagePath: string | undefined, globalState: Memento, - private workspaceState: Memento, + private readonly workspaceState: Memento, + private readonly versionStatus: VersionStatus, + private plugins: TypeScriptServerPlugin[], disposables: Disposable[] ) { @@ -404,8 +406,8 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient const label = version || localize('versionNumber.custom', 'custom'); const tooltip = modulePath; this.modulePath = modulePath; - VersionStatus.showHideStatus(); - VersionStatus.setInfo(label, tooltip); + this.versionStatus.showHideStatus(); + this.versionStatus.setInfo(label, tooltip); // This is backwards compatibility code to move the setting from the local // store into the workspace setting file. diff --git a/extensions/typescript/src/utils/versionStatus.ts b/extensions/typescript/src/utils/versionStatus.ts index e92b87d0f24..21f3a1c34f1 100644 --- a/extensions/typescript/src/utils/versionStatus.ts +++ b/extensions/typescript/src/utils/versionStatus.ts @@ -3,42 +3,53 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import vscode = require('vscode'); +import * as vscode from 'vscode'; -const versionBarEntry = vscode.window.createStatusBarItem(vscode.StatusBarAlignment.Right, Number.MIN_VALUE); -export function showHideStatus() { - if (!versionBarEntry) { - return; - } - if (!vscode.window.activeTextEditor) { - versionBarEntry.hide(); - return; - } +export default class VersionStatus extends vscode.Disposable { + onChangeEditorSub: any; + private versionBarEntry: vscode.StatusBarItem; - let doc = vscode.window.activeTextEditor.document; - if (vscode.languages.match('typescript', doc) || vscode.languages.match('typescriptreact', doc)) { - versionBarEntry.show(); - return; - } + constructor() { + super(() => this.dispose()); + + this.versionBarEntry = vscode.window.createStatusBarItem(vscode.StatusBarAlignment.Right, Number.MIN_VALUE); - if (!vscode.window.activeTextEditor.viewColumn) { - // viewColumn is undefined for the debug/output panel, but we still want - // to show the version info - return; + this.onChangeEditorSub = vscode.window.onDidChangeActiveTextEditor(this.showHideStatus, this); } - versionBarEntry.hide(); -} + dispose() { + this.versionBarEntry.dispose(); + this.onChangeEditorSub.dispose(); + } -export function disposeStatus() { - if (versionBarEntry) { - versionBarEntry.dispose(); + showHideStatus() { + if (!this.versionBarEntry) { + return; + } + if (!vscode.window.activeTextEditor) { + this.versionBarEntry.hide(); + return; + } + + let doc = vscode.window.activeTextEditor.document; + if (vscode.languages.match('typescript', doc) || vscode.languages.match('typescriptreact', doc)) { + this.versionBarEntry.show(); + return; + } + + if (!vscode.window.activeTextEditor.viewColumn) { + // viewColumn is undefined for the debug/output panel, but we still want + // to show the version info + return; + } + + this.versionBarEntry.hide(); } -} -export function setInfo(message: string, tooltip: string) { - versionBarEntry.text = message; - versionBarEntry.tooltip = tooltip; - versionBarEntry.command = 'typescript.selectTypeScriptVersion'; + public setInfo(message: string, tooltip: string) { + this.versionBarEntry.text = message; + this.versionBarEntry.tooltip = tooltip; + this.versionBarEntry.command = 'typescript.selectTypeScriptVersion'; + } } diff --git a/src/vs/workbench/api/node/extHostTask.ts b/src/vs/workbench/api/node/extHostTask.ts index f1c5a8065b8..65e818dafc3 100644 --- a/src/vs/workbench/api/node/extHostTask.ts +++ b/src/vs/workbench/api/node/extHostTask.ts @@ -163,7 +163,7 @@ namespace ProblemMatcher { if (values === void 0 || values === null) { return undefined; } - let result: (string | Problems.ProblemMatcher)[]; + let result: (string | Problems.ProblemMatcher)[] = []; for (let value of values) { let converted = typeof value === 'string' ? value : fromSingle(value); if (converted) { -- GitLab From 3dfc44a3fa8a3a2b5fa0500fe8075bf66bae6b21 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Fri, 26 May 2017 00:18:20 +0200 Subject: [PATCH 0075/1347] Decoration text after decoration wrongly positioned. Fixes #27288 --- src/vs/editor/browser/services/codeEditorServiceImpl.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/editor/browser/services/codeEditorServiceImpl.ts b/src/vs/editor/browser/services/codeEditorServiceImpl.ts index 26bc62e9e6a..d824627e4ec 100644 --- a/src/vs/editor/browser/services/codeEditorServiceImpl.ts +++ b/src/vs/editor/browser/services/codeEditorServiceImpl.ts @@ -151,7 +151,7 @@ class DecorationTypeOptionsProvider implements IModelDecorationOptionsProvider { this.className = createCSSRules(ModelDecorationCSSRuleType.ClassName); this.inlineClassName = createCSSRules(ModelDecorationCSSRuleType.InlineClassName); this.beforeContentClassName = createCSSRules(ModelDecorationCSSRuleType.BeforeContentClassName); - this.beforeContentClassName = createCSSRules(ModelDecorationCSSRuleType.AfterContentClassName); + this.afterContentClassName = createCSSRules(ModelDecorationCSSRuleType.AfterContentClassName); this.glyphMarginClassName = createCSSRules(ModelDecorationCSSRuleType.GlyphMarginClassName); let options = providerArgs.options; -- GitLab From 4ce3a1e6ac1ea6a00ddaff5c8ffdfd25e30f4f03 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 24 May 2017 15:27:48 -0700 Subject: [PATCH 0076/1347] Move VersionStatus into a class --- extensions/typescript/src/typescriptMain.ts | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/extensions/typescript/src/typescriptMain.ts b/extensions/typescript/src/typescriptMain.ts index 07a666936b9..18bc57678ff 100644 --- a/extensions/typescript/src/typescriptMain.ts +++ b/extensions/typescript/src/typescriptMain.ts @@ -90,6 +90,7 @@ const standardLanguageDescriptions: LanguageDescription[] = [ export function activate(context: ExtensionContext): void { const plugins = getContributedTypeScriptServerPlugins(); +<<<<<<< HEAD const lazyClientHost = (() => { let clientHost: TypeScriptServiceClientHost | undefined; return () => { @@ -110,6 +111,10 @@ export function activate(context: ExtensionContext): void { }; })(); +======= + const clientHost = new TypeScriptServiceClientHost(standardLanguageDescriptions, context.storagePath, context.globalState, context.workspaceState, plugins); + context.subscriptions.push(clientHost); +>>>>>>> a0b779f... Move VersionStatus into a class context.subscriptions.push(commands.registerCommand('typescript.reloadProjects', () => { lazyClientHost().reloadProjects(); @@ -145,6 +150,7 @@ export function activate(context: ExtensionContext): void { const jsDocCompletionCommand = new TryCompleteJsDocCommand(() => lazyClientHost().serviceClient); context.subscriptions.push(commands.registerCommand(TryCompleteJsDocCommand.COMMAND_NAME, jsDocCompletionCommand.tryCompleteJsDoc, jsDocCompletionCommand)); +<<<<<<< HEAD const supportedLanguage = [].concat.apply([], standardLanguageDescriptions.map(x => x.modeIds).concat(plugins.map(x => x.languages))); function didOpenTextDocument(textDocument: TextDocument): boolean { if (supportedLanguage.indexOf(textDocument.languageId) >= 0) { @@ -162,6 +168,15 @@ export function activate(context: ExtensionContext): void { } } +======= + clientHost.serviceClient.onReady().then(() => { + context.subscriptions.push(ProjectStatus.create(clientHost.serviceClient, + path => new Promise(resolve => setTimeout(() => resolve(clientHost.handles(path)), 750)), + context.workspaceState)); + }, () => { + // Nothing to do here. The client did show a message; + }); +>>>>>>> a0b779f... Move VersionStatus into a class BuildStatus.update({ queueLength: 0 }); } -- GitLab From fe69f9ac3b5d2f476a08275884d9c12b05859bb6 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Thu, 25 May 2017 15:30:19 -0700 Subject: [PATCH 0077/1347] Actually save the file this time :'( --- extensions/typescript/src/typescriptMain.ts | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/extensions/typescript/src/typescriptMain.ts b/extensions/typescript/src/typescriptMain.ts index 18bc57678ff..07a666936b9 100644 --- a/extensions/typescript/src/typescriptMain.ts +++ b/extensions/typescript/src/typescriptMain.ts @@ -90,7 +90,6 @@ const standardLanguageDescriptions: LanguageDescription[] = [ export function activate(context: ExtensionContext): void { const plugins = getContributedTypeScriptServerPlugins(); -<<<<<<< HEAD const lazyClientHost = (() => { let clientHost: TypeScriptServiceClientHost | undefined; return () => { @@ -111,10 +110,6 @@ export function activate(context: ExtensionContext): void { }; })(); -======= - const clientHost = new TypeScriptServiceClientHost(standardLanguageDescriptions, context.storagePath, context.globalState, context.workspaceState, plugins); - context.subscriptions.push(clientHost); ->>>>>>> a0b779f... Move VersionStatus into a class context.subscriptions.push(commands.registerCommand('typescript.reloadProjects', () => { lazyClientHost().reloadProjects(); @@ -150,7 +145,6 @@ export function activate(context: ExtensionContext): void { const jsDocCompletionCommand = new TryCompleteJsDocCommand(() => lazyClientHost().serviceClient); context.subscriptions.push(commands.registerCommand(TryCompleteJsDocCommand.COMMAND_NAME, jsDocCompletionCommand.tryCompleteJsDoc, jsDocCompletionCommand)); -<<<<<<< HEAD const supportedLanguage = [].concat.apply([], standardLanguageDescriptions.map(x => x.modeIds).concat(plugins.map(x => x.languages))); function didOpenTextDocument(textDocument: TextDocument): boolean { if (supportedLanguage.indexOf(textDocument.languageId) >= 0) { @@ -168,15 +162,6 @@ export function activate(context: ExtensionContext): void { } } -======= - clientHost.serviceClient.onReady().then(() => { - context.subscriptions.push(ProjectStatus.create(clientHost.serviceClient, - path => new Promise(resolve => setTimeout(() => resolve(clientHost.handles(path)), 750)), - context.workspaceState)); - }, () => { - // Nothing to do here. The client did show a message; - }); ->>>>>>> a0b779f... Move VersionStatus into a class BuildStatus.update({ queueLength: 0 }); } -- GitLab From 042217fcbadfb003e04b3076e0e43e051f65bcac Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Thu, 25 May 2017 16:03:38 -0700 Subject: [PATCH 0078/1347] Fix #26708 - use StringDecoder to handle data chunks that split multibyte characters --- .../services/search/node/ripgrepTextSearch.ts | 16 +++++++-- .../test/node/ripgrepTextSearch.test.ts | 36 +++++++++++++++---- 2 files changed, 42 insertions(+), 10 deletions(-) diff --git a/src/vs/workbench/services/search/node/ripgrepTextSearch.ts b/src/vs/workbench/services/search/node/ripgrepTextSearch.ts index 829406f52fe..03aaa15bb75 100644 --- a/src/vs/workbench/services/search/node/ripgrepTextSearch.ts +++ b/src/vs/workbench/services/search/node/ripgrepTextSearch.ts @@ -6,6 +6,7 @@ import { EventEmitter } from 'events'; import * as path from 'path'; +import { StringDecoder, NodeStringDecoder } from 'string_decoder'; import * as cp from 'child_process'; import { rgPath } from 'vscode-ripgrep'; @@ -174,11 +175,13 @@ export class RipgrepParser extends EventEmitter { private fileMatch: FileMatch; private remainder: string; private isDone: boolean; + private stringDecoder: NodeStringDecoder; private numResults = 0; constructor(private maxResults: number, private rootFolder: string) { super(); + this.stringDecoder = new StringDecoder(); } public cancel(): void { @@ -186,16 +189,23 @@ export class RipgrepParser extends EventEmitter { } public flush(): void { + this.handleDecodedData(this.stringDecoder.end()); + if (this.fileMatch) { this.onResult(); } } - public handleData(data: string | Buffer): void { + public handleData(data: Buffer | string): void { + const dataStr = typeof data === 'string' ? data : this.stringDecoder.write(data); + this.handleDecodedData(dataStr); + } + + private handleDecodedData(decodedData: string): void { // If the previous data chunk didn't end in a newline, prepend it to this chunk const dataStr = this.remainder ? - this.remainder + data.toString() : - data.toString(); + this.remainder + decodedData : + decodedData; const dataLines: string[] = dataStr.split(/\r\n|\n/); this.remainder = dataLines[dataLines.length - 1] ? dataLines.pop() : null; diff --git a/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts b/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts index 1ee3f9a6a83..9ff4208d109 100644 --- a/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts +++ b/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts @@ -33,7 +33,11 @@ suite('RipgrepParser', () => { return matchLine; } - function parseInput(inputChunks: string[]): ISerializedFileMatch[] { + function parseInputStrings(inputChunks: string[]): ISerializedFileMatch[] { + return parseInput(inputChunks.map(chunk => new Buffer(chunk))); + } + + function parseInput(inputChunks: Buffer[]): ISerializedFileMatch[] { const matches: ISerializedFileMatch[] = []; const rgp = new RipgrepParser(1e6, rootFolder); rgp.on('result', (match: ISerializedFileMatch) => { @@ -65,7 +69,7 @@ suite('RipgrepParser', () => { [getFileLine('a.txt'), getMatchLine(1, ['before', 'match', 'after']), getMatchLine(2, ['before', 'match', 'after']), fileSectionEnd].join('\n') ]; - const results = parseInput(input); + const results = parseInputStrings(input); assert.equal(results.length, 1); assert.deepEqual(results[0], { @@ -93,7 +97,7 @@ suite('RipgrepParser', () => { [getFileLine('c.txt'), getMatchLine(1, ['before', 'match', 'after']), getMatchLine(2, ['before', 'match', 'after']), fileSectionEnd].join('\n') ]; - const results = parseInput(input); + const results = parseInputStrings(input); assert.equal(results.length, 3); results.forEach(fileResult => assert.equal(fileResult.numMatches, 2)); }); @@ -116,7 +120,7 @@ suite('RipgrepParser', () => { test('Parses multiple chunks broken at each line', () => { const input = singleLineChunks.map(chunk => chunk + '\n'); - const results = parseInput(input); + const results = parseInputStrings(input); assert.equal(results.length, 3); results.forEach(fileResult => assert.equal(fileResult.numMatches, 2)); }); @@ -126,7 +130,7 @@ suite('RipgrepParser', () => { .map(chunk => chunk + '\n') .map(halve)); - const results = parseInput(input); + const results = parseInputStrings(input); assert.equal(results.length, 3); results.forEach(fileResult => assert.equal(fileResult.numMatches, 2)); }); @@ -136,7 +140,7 @@ suite('RipgrepParser', () => { .map(chunk => chunk + '\n') .map(arrayOfChars)); - const results = parseInput(input); + const results = parseInputStrings(input); assert.equal(results.length, 3); results.forEach(fileResult => assert.equal(fileResult.numMatches, 2)); }); @@ -145,8 +149,26 @@ suite('RipgrepParser', () => { const input = singleLineChunks .map(chunk => '\n' + chunk); - const results = parseInput(input); + const results = parseInputStrings(input); assert.equal(results.length, 3); results.forEach(fileResult => assert.equal(fileResult.numMatches, 2)); }); + + test('Parses chunks broken in the middle of a multibyte character', () => { + const multibyteStr = 'æ¼¢'; + const multibyteBuf = new Buffer(multibyteStr); + const text = getFileLine('foo/bar') + '\n' + getMatchLine(0, ['before', 'match', 'after']) + '\n'; + + // Split the multibyte char into two pieces and divide between the two buffers + const beforeIndex = 24; + const inputBufs = [ + Buffer.concat([new Buffer(text.substr(0, beforeIndex)), multibyteBuf.slice(0, 2)]), + Buffer.concat([multibyteBuf.slice(2), new Buffer(text.substr(beforeIndex))]) + ]; + + const results = parseInput(inputBufs); + assert.equal(results.length, 1); + assert.equal(results[0].lineMatches.length, 1); + assert.deepEqual(results[0].lineMatches[0].offsetAndLengths, [[7, 5]]); + }); }); \ No newline at end of file -- GitLab From 1119064b34f376a7560a3a1ccfe43d8d156bf2e1 Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Thu, 25 May 2017 16:15:19 -0700 Subject: [PATCH 0079/1347] Add Unit Test launch config (not sure why it was deleted?) --- .vscode/launch.json | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/.vscode/launch.json b/.vscode/launch.json index d56ca22e59d..fa30207ce2b 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -146,6 +146,32 @@ "outFiles": [ "${workspaceRoot}/extensions/node_modules/typescript/lib/**/*.js" ] + }, + { + "type": "node", + "request": "launch", + "name": "Unit Tests", + "protocol": "legacy", + "program": "${workspaceRoot}/node_modules/mocha/bin/_mocha", + "runtimeExecutable": "${workspaceRoot}/.build/electron/Code - OSS.app/Contents/MacOS/Electron", + "windows": { + "runtimeExecutable": "${workspaceRoot}/.build/electron/Code - OSS.exe" + }, + "linux": { + "runtimeExecutable": "${workspaceRoot}/.build/electron/code-oss" + }, + "stopOnEntry": false, + "args": [ + "--timeout", + "2000" + ], + "cwd": "${workspaceRoot}", + "env": { + "ELECTRON_RUN_AS_NODE": "true" + }, + "outFiles": [ + "${workspaceRoot}/out/**/*.js" + ] } ], "compounds": [ -- GitLab From 3b48123e2e3183ce64041e050f777e543961798c Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Thu, 25 May 2017 16:17:37 -0700 Subject: [PATCH 0080/1347] sourceMaps is enabled by default, remove from launch configs --- .vscode/launch.json | 9 --------- 1 file changed, 9 deletions(-) diff --git a/.vscode/launch.json b/.vscode/launch.json index fa30207ce2b..39b72b995a8 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -18,7 +18,6 @@ "name": "Attach to Extension Host", "protocol": "legacy", "port": 5870, - "sourceMaps": true, "restart": true, "outFiles": [ "${workspaceRoot}/out/**/*.js" @@ -30,7 +29,6 @@ "name": "Attach to Shared Process", "protocol": "legacy", "port": 5871, - "sourceMaps": true, "outFiles": [ "${workspaceRoot}/out/**/*.js" ] @@ -41,7 +39,6 @@ "protocol": "legacy", "name": "Attach to Search process", "port": 7890, - "sourceMaps": true, "outFiles": [ "${workspaceRoot}/out/**/*.js" ] @@ -52,7 +49,6 @@ "name": "Attach to CLI Process", "protocol": "legacy", "port": 5874, - "sourceMaps": true, "outFiles": [ "${workspaceRoot}/out/**/*.js" ] @@ -63,7 +59,6 @@ "name": "Attach to Main Process", "protocol": "legacy", "port": 5875, - "sourceMaps": true, "outFiles": [ "${workspaceRoot}/out/**/*.js" ] @@ -78,7 +73,6 @@ "--extensionDevelopmentPath=${workspaceRoot}/extensions/vscode-api-tests", "--extensionTestsPath=${workspaceRoot}/extensions/vscode-api-tests/out" ], - "sourceMaps": true, "outFiles": [ "${workspaceRoot}/out/**/*.js" ] @@ -93,7 +87,6 @@ "--extensionDevelopmentPath=${workspaceRoot}/extensions/vscode-colorize-tests", "--extensionTestsPath=${workspaceRoot}/extensions/vscode-colorize-tests/out" ], - "sourceMaps": true, "outFiles": [ "${workspaceRoot}/out/**/*.js" ] @@ -131,7 +124,6 @@ "program": "${workspaceRoot}/extensions/git/node_modules/mocha/bin/_mocha", "stopOnEntry": false, "cwd": "${workspaceRoot}/extensions/git", - "sourceMaps": true, "outFiles": [ "${workspaceRoot}/extensions/git/out/**/*.js" ] @@ -141,7 +133,6 @@ "type": "node", "request": "attach", "port": 5859, - "sourceMaps": true, "protocol": "legacy", "outFiles": [ "${workspaceRoot}/extensions/node_modules/typescript/lib/**/*.js" -- GitLab From 867468a559f55277b443f66a28fe5317f9b76652 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 25 May 2017 16:17:21 -0700 Subject: [PATCH 0081/1347] Use 'descriptionForeground' (#27289) --- extensions/merge-conflict/src/mergeDecorator.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/extensions/merge-conflict/src/mergeDecorator.ts b/extensions/merge-conflict/src/mergeDecorator.ts index 39888f727e6..be9e733a562 100644 --- a/extensions/merge-conflict/src/mergeDecorator.ts +++ b/extensions/merge-conflict/src/mergeDecorator.ts @@ -81,7 +81,7 @@ export default class MergeDectorator implements vscode.Disposable { color: new vscode.ThemeColor('editor.foreground'), after: { contentText: ' ' + localize('currentChange', '(Current change)'), - color: 'rgba(0, 0, 0, 0.7)' + color: new vscode.ThemeColor('descriptionForeground') } }); @@ -96,7 +96,7 @@ export default class MergeDectorator implements vscode.Disposable { isWholeLine: this.decorationUsesWholeLine, after: { contentText: ' ' + localize('incomingChange', '(Incoming change)'), - color: 'rgba(0, 0, 0, 0.7)' + color: new vscode.ThemeColor('descriptionForeground') } }); } -- GitLab From ce18dd018de6f920c1d11fef76deb9e217e60b3e Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Thu, 25 May 2017 16:27:55 -0700 Subject: [PATCH 0082/1347] Safer change for #25422 --- src/vs/workbench/services/search/node/ripgrepTextSearch.ts | 2 +- .../services/search/test/node/ripgrepTextSearch.test.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/services/search/node/ripgrepTextSearch.ts b/src/vs/workbench/services/search/node/ripgrepTextSearch.ts index 03aaa15bb75..b7f3b7ad4dc 100644 --- a/src/vs/workbench/services/search/node/ripgrepTextSearch.ts +++ b/src/vs/workbench/services/search/node/ripgrepTextSearch.ts @@ -235,7 +235,7 @@ export class RipgrepParser extends EventEmitter { this.onResult(); } - this.fileMatch = new FileMatch(path.resolve(this.rootFolder, r[1])); + this.fileMatch = new FileMatch(path.isAbsolute(r[1]) ? r[1] : path.join(this.rootFolder, r[1])); } else { // Line is empty (or malformed) } diff --git a/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts b/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts index 9ff4208d109..87a27629eaf 100644 --- a/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts +++ b/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts @@ -74,7 +74,7 @@ suite('RipgrepParser', () => { assert.deepEqual(results[0], { numMatches: 2, - path: path.resolve(rootFolder, 'a.txt'), + path: path.join(rootFolder, 'a.txt'), lineMatches: [ { lineNumber: 0, -- GitLab From 370049325180aff3a4ec3b1f2f44aca4d22add03 Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Thu, 25 May 2017 17:47:01 -0700 Subject: [PATCH 0083/1347] node-debug2@1.13.0 --- build/gulpfile.vscode.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index 15d2edd0323..cf894772b6a 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -43,7 +43,7 @@ const nodeModules = ['electron', 'original-fs'] const builtInExtensions = [ { name: 'ms-vscode.node-debug', version: '1.13.6' }, - { name: 'ms-vscode.node-debug2', version: '1.12.4' } + { name: 'ms-vscode.node-debug2', version: '1.13.0' } ]; const vscodeEntryPoints = _.flatten([ -- GitLab From 770206ab9c6357943a2145bd3ea49b667f3ff539 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Thu, 25 May 2017 21:23:47 -0700 Subject: [PATCH 0084/1347] Pickup all TSConfigs in Workspace for TSC Build Task (#27306) Follow up on #26079 Allows us to pick up all tsconfig files in a workspace for the build tasks --- .../typescript/src/features/taskProvider.ts | 51 +++++++++------- .../typescript/src/utils/tsconfigProvider.ts | 58 +++++++++++++++++++ 2 files changed, 88 insertions(+), 21 deletions(-) create mode 100644 extensions/typescript/src/utils/tsconfigProvider.ts diff --git a/extensions/typescript/src/features/taskProvider.ts b/extensions/typescript/src/features/taskProvider.ts index 76528021983..ba53903e447 100644 --- a/extensions/typescript/src/features/taskProvider.ts +++ b/extensions/typescript/src/features/taskProvider.ts @@ -11,6 +11,7 @@ import * as vscode from 'vscode'; import * as Proto from '../protocol'; import TypeScriptServiceClient from '../typescriptServiceClient'; +import TsConfigProvider from "../utils/tsconfigProvider"; const exists = (file: string): Promise => @@ -21,32 +22,47 @@ const exists = (file: string): Promise => }); export default class TypeScriptTaskProvider implements vscode.TaskProvider { + private readonly tsconfigProvider: TsConfigProvider; public constructor( private readonly lazyClient: () => TypeScriptServiceClient - ) { } + ) { + this.tsconfigProvider = new TsConfigProvider(); + } + + dispose() { + this.tsconfigProvider.dispose(); + } - async provideTasks(token: vscode.CancellationToken): Promise { + public async provideTasks(token: vscode.CancellationToken): Promise { const rootPath = vscode.workspace.rootPath; if (!rootPath) { return []; } - const projects = (await this.getConfigForActiveFile(token)).concat(await this.getConfigsForWorkspace()); const command = await this.getCommand(); + const projects = await this.getAllTsConfigs(token); - return projects - .filter((x, i) => projects.indexOf(x) === i) - .map(configFile => { - const configFileName = path.relative(rootPath, configFile); - const buildTask = new vscode.ShellTask(`tsc: build ${configFileName}`, `${command} -p ${configFile}`, '$tsc'); - buildTask.group = vscode.TaskGroup.Build; - return buildTask; - }); + return projects.map(configFile => { + const configFileName = path.relative(rootPath, configFile); + const buildTask = new vscode.ShellTask(`tsc: build ${configFileName}`, `${command} -p ${configFile}`, '$tsc'); + buildTask.group = vscode.TaskGroup.Build; + return buildTask; + }); } + private async getAllTsConfigs(token: vscode.CancellationToken): Promise { + const out: string[] = []; + const configs = (await this.getTsConfigForActiveFile(token)).concat(await this.getTsConfigsInWorkspace()); + for (const config of configs) { + if (await exists(config)) { + out.push(config); + } + } + return out; + } - private async getConfigForActiveFile(token: vscode.CancellationToken): Promise { + private async getTsConfigForActiveFile(token: vscode.CancellationToken): Promise { const editor = vscode.window.activeTextEditor; if (editor) { if (path.basename(editor.document.fileName).match(/^tsconfig\.(.\.)?json$/)) { @@ -75,15 +91,8 @@ export default class TypeScriptTaskProvider implements vscode.TaskProvider { return []; } - private async getConfigsForWorkspace(): Promise { - if (!vscode.workspace.rootPath) { - return []; - } - const rootTsConfig = path.join(vscode.workspace.rootPath, 'tsconfig.json'); - if (!await exists(rootTsConfig)) { - return []; - } - return [rootTsConfig]; + private async getTsConfigsInWorkspace(): Promise { + return Array.from(await this.tsconfigProvider.getConfigsForWorkspace()); } private async getCommand(): Promise { diff --git a/extensions/typescript/src/utils/tsconfigProvider.ts b/extensions/typescript/src/utils/tsconfigProvider.ts new file mode 100644 index 00000000000..e85ca24bbff --- /dev/null +++ b/extensions/typescript/src/utils/tsconfigProvider.ts @@ -0,0 +1,58 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +import * as vscode from 'vscode'; + +export default class TsConfigProvider extends vscode.Disposable { + private readonly tsconfigs = new Set(); + + private activated: boolean = false; + private disposables: vscode.Disposable[] = []; + + constructor() { + super(() => this.dispose()); + } + + dispose(): void { + this.disposables.forEach(d => d.dispose()); + } + + public async getConfigsForWorkspace(): Promise> { + if (!vscode.workspace.rootPath) { + return []; + } + await this.ensureActivated(); + return this.tsconfigs; + } + + private async ensureActivated() { + if (this.activated) { + return this; + } + this.activated = true; + + for (const config of await TsConfigProvider.loadWorkspaceTsconfigs()) { + this.tsconfigs.add(config.fsPath); + } + + const configFileWatcher = vscode.workspace.createFileSystemWatcher('**/tsconfig*.json'); + this.disposables.push(configFileWatcher); + configFileWatcher.onDidCreate(this.handleProjectCreate, this, this.disposables); + configFileWatcher.onDidDelete(this.handleProjectDelete, this, this.disposables); + + return this; + } + + private static loadWorkspaceTsconfigs() { + return vscode.workspace.findFiles('**/tsconfig*.json', '**/node_modules/**'); + } + + private handleProjectCreate(e: vscode.Uri) { + this.tsconfigs.add(e.fsPath); + } + + private handleProjectDelete(e: vscode.Uri) { + this.tsconfigs.delete(e.fsPath); + } +} -- GitLab From 01e289eac392c7a2e45da386e3ce3333db327916 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Thu, 25 May 2017 23:50:49 -0700 Subject: [PATCH 0085/1347] Select single words in property value --- extensions/emmet/src/selectItemHTML.ts | 65 +++++++++++++++-- extensions/emmet/src/selectItemStylesheet.ts | 75 ++++++++++++++++--- extensions/emmet/src/util.ts | 76 ++++++++++++++++++++ 3 files changed, 200 insertions(+), 16 deletions(-) diff --git a/extensions/emmet/src/selectItemHTML.ts b/extensions/emmet/src/selectItemHTML.ts index 79d0a585e0a..2c0be704ead 100644 --- a/extensions/emmet/src/selectItemHTML.ts +++ b/extensions/emmet/src/selectItemHTML.ts @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ import * as vscode from 'vscode'; -import { getNode, getDeepestNode } from './util'; +import { getNode, getDeepestNode, findNextWord, findPrevWord } from './util'; import Node from '@emmetio/node'; export function nextItemHTML(selection: vscode.Selection, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { @@ -99,10 +99,40 @@ function getNextAttribute(selection: vscode.Selection, document: vscode.TextDocu return new vscode.Selection(document.positionAt(attr.start), document.positionAt(attr.end)); } - if ((attr.value.start !== attr.value.end) && ((selectionStart === attr.start && selectionEnd === attr.end) || selectionEnd < attr.end - 1)) { - // select attr value + if (attr.value.start === attr.value.end) { + // No attr value to select + continue; + } + + if ((selectionStart === attr.start && selectionEnd === attr.end) || selectionEnd < attr.value.start) { + // cursor is in attr name, so select full attr value return new vscode.Selection(document.positionAt(attr.value.start), document.positionAt(attr.value.end)); } + + // Fetch the next word in the attr value + + if (attr.value.toString().indexOf(' ') === -1) { + // attr value does not have space, so no next word to find + continue; + } + + let pos = undefined; + if (selectionStart === attr.value.start && selectionEnd === attr.value.end) { + pos = -1; + } + if (pos === undefined && selectionEnd < attr.end) { + pos = selectionEnd - attr.value.start - 1; + } + + if (pos !== undefined) { + let [newSelectionStart, newSelectionEnd] = findNextWord(attr.value.toString(), pos); + if (newSelectionStart >= 0 && newSelectionEnd >= 0) { + newSelectionStart += attr.value.start; + newSelectionEnd += attr.value.start; + return new vscode.Selection(document.positionAt(newSelectionStart), document.positionAt(newSelectionEnd)); + } + } + } } @@ -113,18 +143,39 @@ function getPrevAttribute(selection: vscode.Selection, document: vscode.TextDocu } let selectionStart = document.offsetAt(selection.anchor); + let selectionEnd = document.offsetAt(selection.active); for (let i = node.attributes.length - 1; i >= 0; i--) { let attr = node.attributes[i]; - if (selectionStart > attr.value.start) { - // select attr value - return new vscode.Selection(document.positionAt(attr.value.start), document.positionAt(attr.value.end)); + if (selectionStart <= attr.start) { + continue; } - if (selectionStart > attr.start) { + if (attr.value.start === attr.value.end || selectionStart < attr.value.start) { // select full attr return new vscode.Selection(document.positionAt(attr.start), document.positionAt(attr.end)); } + + if (selectionStart === attr.value.start) { + if (selectionEnd >= attr.value.end) { + // select full attr + return new vscode.Selection(document.positionAt(attr.start), document.positionAt(attr.end)); + } + // select attr value + return new vscode.Selection(document.positionAt(attr.value.start), document.positionAt(attr.value.end)); + } + + // Fetch the prev word in the attr value + + let pos = selectionStart > attr.value.end ? attr.value.toString().length : selectionStart - attr.value.start; + let [newSelectionStart, newSelectionEnd] = findPrevWord(attr.value.toString(), pos); + if (newSelectionStart >= 0 && newSelectionEnd >= 0) { + newSelectionStart += attr.value.start; + newSelectionEnd += attr.value.start; + return new vscode.Selection(document.positionAt(newSelectionStart), document.positionAt(newSelectionEnd)); + } + + } } \ No newline at end of file diff --git a/extensions/emmet/src/selectItemStylesheet.ts b/extensions/emmet/src/selectItemStylesheet.ts index d0167a2d8b9..e3144cbf666 100644 --- a/extensions/emmet/src/selectItemStylesheet.ts +++ b/extensions/emmet/src/selectItemStylesheet.ts @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ import * as vscode from 'vscode'; -import { getNode, getDeepestNode } from './util'; +import { getNode, getDeepestNode, findNextWord, findPrevWord } from './util'; import Node from '@emmetio/node'; export function nextItemStylesheet(selection: vscode.Selection, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { @@ -12,9 +12,17 @@ export function nextItemStylesheet(selection: vscode.Selection, editor: vscode.T let endOffset = editor.document.offsetAt(selection.active); let currentNode = getNode(rootNode, endOffset, true); - // Full property is selected, so select property value next + // Full property is selected, so select full property value next if (currentNode.type === 'property' && startOffset === currentNode.start && endOffset === currentNode.end) { - return getSelectionFromNode(currentNode, editor.document, true); + return getSelectionFromProperty(currentNode, editor.document, startOffset, endOffset, true, 'next'); + } + + // Part or whole of propertyValue is selected, so select the next word in the propertyValue + if (currentNode.type === 'property' && startOffset >= currentNode.valueToken.start && endOffset <= currentNode.valueToken.end) { + let singlePropertyValue = getSelectionFromProperty(currentNode, editor.document, startOffset, endOffset, false, 'next'); + if (singlePropertyValue) { + return singlePropertyValue; + } } // Cursor is in the selector or in a property @@ -41,13 +49,27 @@ export function nextItemStylesheet(selection: vscode.Selection, editor: vscode.T export function prevItemStylesheet(selection: vscode.Selection, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { let startOffset = editor.document.offsetAt(selection.anchor); + let endOffset = editor.document.offsetAt(selection.active); let currentNode = getNode(rootNode, startOffset); if (!currentNode) { currentNode = rootNode; } + // Full property value is selected, so select the whole property next + if (currentNode.type === 'property' && startOffset === currentNode.valueToken.start && endOffset === currentNode.valueToken.end) { + return getSelectionFromNode(currentNode, editor.document); + } + + // Part of propertyValue is selected, so select the prev word in the propertyValue + if (currentNode.type === 'property' && startOffset >= currentNode.valueToken.start && endOffset <= currentNode.valueToken.end) { + let singlePropertyValue = getSelectionFromProperty(currentNode, editor.document, startOffset, endOffset, false, 'prev'); + if (singlePropertyValue) { + return singlePropertyValue; + } + } + if (currentNode.type === 'property' || !currentNode.firstChild || (currentNode.type === 'rule' && startOffset <= currentNode.firstChild.start)) { - return getSelectionFromNode(currentNode, editor.document);; + return getSelectionFromNode(currentNode, editor.document); } // Select the child that appears just before the cursor @@ -57,23 +79,58 @@ export function prevItemStylesheet(selection: vscode.Selection, editor: vscode.T } prevNode = getDeepestNode(prevNode); - return getSelectionFromNode(prevNode, editor.document, true); + return getSelectionFromProperty(prevNode, editor.document, startOffset, endOffset, false, 'prev'); } -function getSelectionFromNode(node: Node, document: vscode.TextDocument, selectPropertyValue: boolean = false): vscode.Selection { +function getSelectionFromNode(node: Node, document: vscode.TextDocument): vscode.Selection { if (!node) { return; } let nodeToSelect = node.type === 'rule' ? node.selectorToken : node; + return new vscode.Selection(document.positionAt(nodeToSelect.start), document.positionAt(nodeToSelect.end)); +} + + +function getSelectionFromProperty(node: Node, document: vscode.TextDocument, selectionStart: number, selectionEnd: number, selectFullValue: boolean, direction: string): vscode.Selection { + if (!node || node.type !== 'property') { + return; + } + + let propertyValue = node.valueToken.stream.substring(node.valueToken.start, node.valueToken.end); + selectFullValue = selectFullValue || (direction === 'prev' && selectionStart === node.valueToken.start && selectionEnd < node.valueToken.end); + + if (selectFullValue) { + return new vscode.Selection(document.positionAt(node.valueToken.start), document.positionAt(node.valueToken.end)); + } + + let pos; + if (direction === 'prev') { + if (selectionStart === node.valueToken.start) { + return; + } + pos = selectionStart > node.valueToken.end ? propertyValue.length : selectionStart - node.valueToken.start; + } + + if (direction === 'next') { + if (selectionEnd === node.valueToken.end && (selectionStart > node.valueToken.start || propertyValue.indexOf(' ') === -1)) { + return; + } + pos = selectionEnd === node.valueToken.end ? -1 : selectionEnd - node.valueToken.start - 1; + } - let selectionStart = (node.type === 'property' && selectPropertyValue) ? node.valueToken.start : nodeToSelect.start; - let selectionEnd = (node.type === 'property' && selectPropertyValue) ? node.valueToken.end : nodeToSelect.end; - return new vscode.Selection(document.positionAt(selectionStart), document.positionAt(selectionEnd)); + let [newSelectionStart, newSelectionEnd] = direction === 'prev' ? findPrevWord(propertyValue, pos) : findNextWord(propertyValue, pos); + if (!newSelectionStart && !newSelectionEnd) { + return; + } + + newSelectionStart += node.valueToken.start; + newSelectionEnd += node.valueToken.start; + return new vscode.Selection(document.positionAt(newSelectionStart), document.positionAt(newSelectionEnd)); } diff --git a/extensions/emmet/src/util.ts b/extensions/emmet/src/util.ts index 3b495069d1e..81085e5b6d6 100644 --- a/extensions/emmet/src/util.ts +++ b/extensions/emmet/src/util.ts @@ -136,4 +136,80 @@ export function getDeepestNode(node: Node): Node { } return getDeepestNode(node.children[node.children.length - 1]); +} + +export function findNextWord(propertyValue: string, pos: number): [number, number] { + + let foundSpace = pos === -1; + let foundStart = false; + let foundEnd = false; + + let newSelectionStart; + let newSelectionEnd; + while (pos < propertyValue.length - 1) { + pos++; + if (!foundSpace) { + if (propertyValue[pos] === ' ') { + foundSpace = true; + } + continue; + } + if (foundSpace && !foundStart && propertyValue[pos] === ' ') { + continue; + } + if (!foundStart) { + newSelectionStart = pos; + foundStart = true; + continue; + } + if (propertyValue[pos] === ' ') { + newSelectionEnd = pos; + foundEnd = true; + break; + } + } + + if (foundStart && !foundEnd) { + newSelectionEnd = propertyValue.length; + } + + return [newSelectionStart, newSelectionEnd]; +} + +export function findPrevWord(propertyValue: string, pos: number): [number, number] { + + let foundSpace = pos === propertyValue.length; + let foundStart = false; + let foundEnd = false; + + let newSelectionStart; + let newSelectionEnd; + while (pos > -1) { + pos--; + if (!foundSpace) { + if (propertyValue[pos] === ' ') { + foundSpace = true; + } + continue; + } + if (foundSpace && !foundEnd && propertyValue[pos] === ' ') { + continue; + } + if (!foundEnd) { + newSelectionEnd = pos + 1; + foundEnd = true; + continue; + } + if (propertyValue[pos] === ' ') { + newSelectionStart = pos + 1; + foundStart = true; + break; + } + } + + if (foundEnd && !foundStart) { + newSelectionStart = 0; + } + + return [newSelectionStart, newSelectionEnd]; } \ No newline at end of file -- GitLab From b96478ebcc790c03c27e1ee36ee6dbc23c882231 Mon Sep 17 00:00:00 2001 From: Maik Riechert Date: Wed, 3 May 2017 22:53:26 +0100 Subject: [PATCH 0086/1347] add git delete branch command --- extensions/git/package.json | 9 ++++++++ extensions/git/package.nls.json | 1 + extensions/git/src/commands.ts | 39 +++++++++++++++++++++++++++++++++ extensions/git/src/git.ts | 5 +++++ extensions/git/src/model.ts | 7 +++++- 5 files changed, 60 insertions(+), 1 deletion(-) diff --git a/extensions/git/package.json b/extensions/git/package.json index 2a47e2dc209..0ea489cc812 100644 --- a/extensions/git/package.json +++ b/extensions/git/package.json @@ -172,6 +172,11 @@ "title": "%command.branch%", "category": "Git" }, + { + "command": "git.deleteBranch", + "title": "%command.deleteBranch%", + "category": "Git" + }, { "command": "git.pull", "title": "%command.pull%", @@ -298,6 +303,10 @@ "command": "git.branch", "when": "config.git.enabled && scmProvider == git && gitState == idle" }, + { + "command": "git.deleteBranch", + "when": "config.git.enabled && scmProvider == git && gitState == idle" + }, { "command": "git.pull", "when": "config.git.enabled && scmProvider == git && gitState == idle" diff --git a/extensions/git/package.nls.json b/extensions/git/package.nls.json index efdde34dd7a..e02a5ed2310 100644 --- a/extensions/git/package.nls.json +++ b/extensions/git/package.nls.json @@ -21,6 +21,7 @@ "command.undoCommit": "Undo Last Commit", "command.checkout": "Checkout to...", "command.branch": "Create Branch...", + "command.deleteBranch": "Delete Branch...", "command.pull": "Pull", "command.pullRebase": "Pull (Rebase)", "command.push": "Push", diff --git a/extensions/git/src/commands.ts b/extensions/git/src/commands.ts index 24f9c35129a..15532bfc28b 100644 --- a/extensions/git/src/commands.ts +++ b/extensions/git/src/commands.ts @@ -60,6 +60,26 @@ class CheckoutRemoteHeadItem extends CheckoutItem { } } +class BranchDeleteItem implements QuickPickItem { + + protected get shortCommit(): string { return (this.ref.commit || '').substr(0, 8); } + protected get treeish(): string | undefined { return this.ref.name; } + get label(): string { return this.ref.name || this.shortCommit; } + get description(): string { return this.shortCommit; } + + constructor(protected ref: Ref) { } + + async run(model: Model): Promise { + const ref = this.treeish; + + if (!ref) { + return; + } + + await model.deleteBranch(ref); + } +} + interface Command { commandId: string; key: string; @@ -699,6 +719,25 @@ export class CommandCenter { await this.model.branch(name); } + @command('git.deleteBranch') + async deleteBranch(branchName: string): Promise { + if (typeof branchName === 'string') { + return await this.model.deleteBranch(branchName); + } + const currentHead = this.model.HEAD && this.model.HEAD.name; + const heads = this.model.refs.filter(ref => ref.type === RefType.Head && ref.name !== currentHead) + .map(ref => new BranchDeleteItem(ref)); + + const placeHolder = 'Select a branch to delete'; + const choice = await window.showQuickPick(heads, { placeHolder }); + + if (!choice) { + return; + } + + await choice.run(this.model); + } + @command('git.pull') async pull(): Promise { const remotes = this.model.remotes; diff --git a/extensions/git/src/git.ts b/extensions/git/src/git.ts index 751fbccc15e..edba69ad2ed 100644 --- a/extensions/git/src/git.ts +++ b/extensions/git/src/git.ts @@ -650,6 +650,11 @@ export class Repository { await this.run(args); } + async deleteBranch(name: string): Promise { + const args = ['branch', '-d', name]; + await this.run(args); + } + async clean(paths: string[]): Promise { const pathsByGroup = groupBy(paths, p => path.dirname(p)); const groups = Object.keys(pathsByGroup).map(k => pathsByGroup[k]); diff --git a/extensions/git/src/model.ts b/extensions/git/src/model.ts index 3e8377e93eb..1ce7f8287a9 100644 --- a/extensions/git/src/model.ts +++ b/extensions/git/src/model.ts @@ -210,7 +210,8 @@ export enum Operation { Init = 1 << 12, Show = 1 << 13, Stage = 1 << 14, - GetCommitTemplate = 1 << 15 + GetCommitTemplate = 1 << 15, + DeleteBranch = 1 << 16 } // function getOperationName(operation: Operation): string { @@ -453,6 +454,10 @@ export class Model implements Disposable { await this.run(Operation.Branch, () => this.repository.branch(name, true)); } + async deleteBranch(name: string): Promise { + await this.run(Operation.DeleteBranch, () => this.repository.deleteBranch(name)); + } + async checkout(treeish: string): Promise { await this.run(Operation.Checkout, () => this.repository.checkout(treeish, [])); } -- GitLab From b348a0b780bb1879db84022fc58875000e12bc89 Mon Sep 17 00:00:00 2001 From: Maik Riechert Date: Sat, 6 May 2017 16:23:50 +0100 Subject: [PATCH 0087/1347] handle git branch delete error ("not fully merged") --- extensions/git/src/commands.ts | 59 +++++++++++++++++++++------------- extensions/git/src/git.ts | 9 ++++-- extensions/git/src/model.ts | 4 +-- 3 files changed, 45 insertions(+), 27 deletions(-) diff --git a/extensions/git/src/commands.ts b/extensions/git/src/commands.ts index 15532bfc28b..e8c155102a3 100644 --- a/extensions/git/src/commands.ts +++ b/extensions/git/src/commands.ts @@ -62,21 +62,18 @@ class CheckoutRemoteHeadItem extends CheckoutItem { class BranchDeleteItem implements QuickPickItem { - protected get shortCommit(): string { return (this.ref.commit || '').substr(0, 8); } - protected get treeish(): string | undefined { return this.ref.name; } - get label(): string { return this.ref.name || this.shortCommit; } + private get shortCommit(): string { return (this.ref.commit || '').substr(0, 8); } + get branchName(): string | undefined { return this.ref.name; } + get label(): string { return this.branchName || ''; } get description(): string { return this.shortCommit; } - constructor(protected ref: Ref) { } - - async run(model: Model): Promise { - const ref = this.treeish; + constructor(private ref: Ref) { } - if (!ref) { + async run(model: Model, force?: boolean): Promise { + if (!this.branchName) { return; } - - await model.deleteBranch(ref); + await model.deleteBranch(this.branchName, force); } } @@ -720,22 +717,40 @@ export class CommandCenter { } @command('git.deleteBranch') - async deleteBranch(branchName: string): Promise { - if (typeof branchName === 'string') { - return await this.model.deleteBranch(branchName); - } - const currentHead = this.model.HEAD && this.model.HEAD.name; - const heads = this.model.refs.filter(ref => ref.type === RefType.Head && ref.name !== currentHead) - .map(ref => new BranchDeleteItem(ref)); + async deleteBranch(name: string, force?: boolean): Promise { + let run: (force?: boolean) => Promise; + if (typeof name === 'string') { + run = force => this.model.deleteBranch(name, force); + } else { + const currentHead = this.model.HEAD && this.model.HEAD.name; + const heads = this.model.refs.filter(ref => ref.type === RefType.Head && ref.name !== currentHead) + .map(ref => new BranchDeleteItem(ref)); - const placeHolder = 'Select a branch to delete'; - const choice = await window.showQuickPick(heads, { placeHolder }); + const placeHolder = 'Select a branch to delete'; + const choice = await window.showQuickPick(heads, { placeHolder }); - if (!choice) { - return; + if (!choice) { + return; + } + name = choice.branchName || ''; + run = force => choice.run(this.model, force); } - await choice.run(this.model); + try { + await run(force); + } catch (err) { + if (err.gitErrorCode !== GitErrorCodes.BranchNotFullyMerged) { + throw err; + } + + const message = localize('confirm force delete branch', "The branch '{0}' is not fully merged. Delete anyway?", name); + const yes = localize('delete branch', "Delete Branch"); + const pick = await window.showWarningMessage(message, yes); + + if (pick === yes) { + await run(true); + } + } } @command('git.pull') diff --git a/extensions/git/src/git.ts b/extensions/git/src/git.ts index edba69ad2ed..9ef482def93 100644 --- a/extensions/git/src/git.ts +++ b/extensions/git/src/git.ts @@ -273,7 +273,8 @@ export const GitErrorCodes = { CantCreatePipe: 'CantCreatePipe', CantAccessRemote: 'CantAccessRemote', RepositoryNotFound: 'RepositoryNotFound', - RepositoryIsLocked: 'RepositoryIsLocked' + RepositoryIsLocked: 'RepositoryIsLocked', + BranchNotFullyMerged: 'BranchNotFullyMerged' }; function getGitErrorCode(stderr: string): string | undefined { @@ -291,6 +292,8 @@ function getGitErrorCode(stderr: string): string | undefined { return GitErrorCodes.RepositoryNotFound; } else if (/unable to access/.test(stderr)) { return GitErrorCodes.CantAccessRemote; + } else if (/branch '.+' is not fully merged/.test(stderr)) { + return GitErrorCodes.BranchNotFullyMerged; } return void 0; @@ -650,8 +653,8 @@ export class Repository { await this.run(args); } - async deleteBranch(name: string): Promise { - const args = ['branch', '-d', name]; + async deleteBranch(name: string, force?: boolean): Promise { + const args = ['branch', force ? '-D' : '-d', name]; await this.run(args); } diff --git a/extensions/git/src/model.ts b/extensions/git/src/model.ts index 1ce7f8287a9..aba4a4251d6 100644 --- a/extensions/git/src/model.ts +++ b/extensions/git/src/model.ts @@ -454,8 +454,8 @@ export class Model implements Disposable { await this.run(Operation.Branch, () => this.repository.branch(name, true)); } - async deleteBranch(name: string): Promise { - await this.run(Operation.DeleteBranch, () => this.repository.deleteBranch(name)); + async deleteBranch(name: string, force?: boolean): Promise { + await this.run(Operation.DeleteBranch, () => this.repository.deleteBranch(name, force)); } async checkout(treeish: string): Promise { -- GitLab From 3df1eca296aa247dd5687f352df0cf6478a3b94c Mon Sep 17 00:00:00 2001 From: Maik Riechert Date: Sat, 6 May 2017 16:55:38 +0100 Subject: [PATCH 0088/1347] localize --- extensions/git/src/commands.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/extensions/git/src/commands.ts b/extensions/git/src/commands.ts index e8c155102a3..3ede435fff3 100644 --- a/extensions/git/src/commands.ts +++ b/extensions/git/src/commands.ts @@ -726,13 +726,13 @@ export class CommandCenter { const heads = this.model.refs.filter(ref => ref.type === RefType.Head && ref.name !== currentHead) .map(ref => new BranchDeleteItem(ref)); - const placeHolder = 'Select a branch to delete'; + const placeHolder = localize('select branch to delete', 'Select a branch to delete'); const choice = await window.showQuickPick(heads, { placeHolder }); - if (!choice) { + if (!choice || !choice.branchName) { return; } - name = choice.branchName || ''; + name = choice.branchName; run = force => choice.run(this.model, force); } -- GitLab From 4fc88f02f0ec346215dca2fea3eb8d3ea10f3a78 Mon Sep 17 00:00:00 2001 From: Amy Qiu Date: Thu, 18 May 2017 13:00:04 -0700 Subject: [PATCH 0089/1347] Fix #26821 Memento - Search now remembers if you cleared your input before shutdown --- src/vs/workbench/parts/search/browser/searchViewlet.ts | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/vs/workbench/parts/search/browser/searchViewlet.ts b/src/vs/workbench/parts/search/browser/searchViewlet.ts index 8b693080d26..1010cbcaf5b 100644 --- a/src/vs/workbench/parts/search/browser/searchViewlet.ts +++ b/src/vs/workbench/parts/search/browser/searchViewlet.ts @@ -1348,6 +1348,13 @@ export class SearchViewlet extends Viewlet { ]; } + public shutdown(): void { + this.viewletSettings['query.contentPattern'] = this.searchWidget.searchInput.getValue(); + this.saveMemento(); + + super.shutdown(); + } + public dispose(): void { this.isDisposed = true; -- GitLab From 41320ccf9e1d473fa26d39a13ee7508918817442 Mon Sep 17 00:00:00 2001 From: Amy Qiu Date: Thu, 18 May 2017 14:09:32 -0700 Subject: [PATCH 0090/1347] Fix saveMemento --- src/vs/workbench/parts/search/browser/searchViewlet.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/src/vs/workbench/parts/search/browser/searchViewlet.ts b/src/vs/workbench/parts/search/browser/searchViewlet.ts index 1010cbcaf5b..deb804b45b1 100644 --- a/src/vs/workbench/parts/search/browser/searchViewlet.ts +++ b/src/vs/workbench/parts/search/browser/searchViewlet.ts @@ -1350,7 +1350,6 @@ export class SearchViewlet extends Viewlet { public shutdown(): void { this.viewletSettings['query.contentPattern'] = this.searchWidget.searchInput.getValue(); - this.saveMemento(); super.shutdown(); } -- GitLab From d82706abf28670120a85e5c64cbda9a65939bf1b Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 24 May 2017 13:02:51 +0200 Subject: [PATCH 0091/1347] theming: extension buttons --- .../extensions/browser/extensionsActions.ts | 66 +++++++++++++++++-- .../browser/media/extensionActions.css | 59 ----------------- 2 files changed, 62 insertions(+), 63 deletions(-) diff --git a/src/vs/workbench/parts/extensions/browser/extensionsActions.ts b/src/vs/workbench/parts/extensions/browser/extensionsActions.ts index 47ccf37113e..3b557abaf33 100644 --- a/src/vs/workbench/parts/extensions/browser/extensionsActions.ts +++ b/src/vs/workbench/parts/extensions/browser/extensionsActions.ts @@ -32,13 +32,16 @@ import { IExtensionService, IExtensionDescription } from 'vs/platform/extensions import URI from 'vs/base/common/uri'; import { CommandsRegistry } from 'vs/platform/commands/common/commands'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; +import { registerThemingParticipant, ITheme, ICssStyleCollector } from "vs/platform/theme/common/themeService"; +import { buttonBackground, buttonForeground, buttonHoverBackground, contrastBorder, registerColor } from "vs/platform/theme/common/colorRegistry"; +import { Color } from "vs/base/common/color"; export class InstallAction extends Action { private static InstallLabel = localize('installAction', "Install"); private static InstallingLabel = localize('installing', "Installing"); - private static Class = 'extension-action install'; + private static Class = 'extension-action prominent install'; private static InstallingClass = 'extension-action install installing'; private disposables: IDisposable[] = []; @@ -153,7 +156,7 @@ export class UninstallAction extends Action { export class CombinedInstallAction extends Action { - private static NoExtensionClass = 'extension-action install no-extension'; + private static NoExtensionClass = 'extension-action prominent install no-extension'; private installAction: InstallAction; private uninstallAction: UninstallAction; private disposables: IDisposable[] = []; @@ -224,7 +227,7 @@ export class CombinedInstallAction extends Action { export class UpdateAction extends Action { - private static EnabledClass = 'extension-action update'; + private static EnabledClass = 'extension-action prominent update'; private static DisabledClass = `${UpdateAction.EnabledClass} disabled`; private static Label = localize('updateAction', "Update"); @@ -477,7 +480,7 @@ export class EnableGloballyAction extends Action implements IExtensionAction { export class EnableAction extends Action { static ID = 'extensions.enable'; - private static EnabledClass = 'extension-action enable'; + private static EnabledClass = 'extension-action prominent enable'; private static DisabledClass = `${EnableAction.EnabledClass} disabled`; private disposables: IDisposable[] = []; @@ -1385,3 +1388,58 @@ CommandsRegistry.registerCommand('workbench.extensions.action.showLanguageExtens viewlet.focus(); }); }); + +export const extensionButtonProminentBackground = registerColor('extensionButton.prominentBackground', { + dark: '#327e36', + light: '#327e36', + hc: null +}, localize('extensionButtonProminentBackground', "Button background color for actions extension that stand out (e.g. install button).")); + +export const extensionButtonProminentForeground = registerColor('extensionButton.prominentForeground', { + dark: Color.white, + light: Color.white, + hc: null +}, localize('extensionButtonProminentForeground', "Button foreground color for actions extension that stand out (e.g. install button).")); + +export const extensionButtonProminentHoverBackground = registerColor('extensionButton.prominentHoverBackground', { + dark: '#28632b', + light: '#28632b', + hc: null +}, localize('extensionButtonProminentHoverBackground', "Button background hover color for actions extension that stand out (e.g. install button).")); + +registerThemingParticipant((theme: ITheme, collector: ICssStyleCollector) => { + const buttonBackgroundColor = theme.getColor(buttonBackground); + if (buttonBackgroundColor) { + collector.addRule(`.monaco-action-bar .action-item .action-label.extension-action { background-color: ${buttonBackgroundColor}; }`); + } + + const buttonForegroundColor = theme.getColor(buttonForeground); + if (buttonForegroundColor) { + collector.addRule(`.monaco-action-bar .action-item .action-label.extension-action { color: ${buttonForegroundColor}; }`); + } + + const buttonHoverBackgroundColor = theme.getColor(buttonHoverBackground); + if (buttonHoverBackgroundColor) { + collector.addRule(`.monaco-action-bar .action-item:hover .action-label.extension-action { background-color: ${buttonHoverBackgroundColor}; }`); + } + + const contrastBorderColor = theme.getColor(contrastBorder); + if (contrastBorderColor) { + collector.addRule(`.monaco-action-bar .action-item .action-label.extension-action { border: 1px solid ${contrastBorderColor}; }`); + } + + const extensionButtonProminentBackgroundColor = theme.getColor(extensionButtonProminentBackground); + if (extensionButtonProminentBackground) { + collector.addRule(`.monaco-action-bar .action-item .action-label.extension-action.prominent { background-color: ${extensionButtonProminentBackgroundColor}; }`); + } + + const extensionButtonProminentForegroundColor = theme.getColor(extensionButtonProminentForeground); + if (extensionButtonProminentForeground) { + collector.addRule(`.monaco-action-bar .action-item .action-label.extension-action.prominent { color: ${extensionButtonProminentForegroundColor}; }`); + } + + const extensionButtonProminentHoverBackgroundColor = theme.getColor(extensionButtonProminentHoverBackground); + if (extensionButtonProminentHoverBackground) { + collector.addRule(`.monaco-action-bar .action-item:hover .action-label.extension-action.prominent { background-color: ${extensionButtonProminentHoverBackgroundColor}; }`); + } +}); \ No newline at end of file diff --git a/src/vs/workbench/parts/extensions/browser/media/extensionActions.css b/src/vs/workbench/parts/extensions/browser/media/extensionActions.css index 5a51986dce8..e80db60cdef 100644 --- a/src/vs/workbench/parts/extensions/browser/media/extensionActions.css +++ b/src/vs/workbench/parts/extensions/browser/media/extensionActions.css @@ -4,69 +4,10 @@ *--------------------------------------------------------------------------------------------*/ .monaco-action-bar .action-item .action-label.extension-action { - border: 1px solid #CCC; - color: #6C6C6C; - background-color: #E2E2E2; padding: 0 5px; line-height: initial; } -.monaco-action-bar .action-item:not(.disabled):hover .action-label.extension-action { - background-color: #D9D9D9; -} - -.monaco-action-bar .action-item:not(.disabled):active .action-label.extension-action { - background-color: #C9C9C9; -} - -.vs-dark .monaco-action-bar .action-item .action-label.extension-action { - border: 1px solid #545454; - color: #CCC; - background-color: #3A3A3A; -} - -.vs-dark .monaco-action-bar .action-item:not(.disabled):hover .action-label.extension-action { - background-color: #464646; -} - -.vs-dark .monaco-action-bar .action-item:not(.disabled):active .action-label.extension-action { - background-color: #505050; -} - -.monaco-action-bar .action-item .action-label.extension-action.install, -.monaco-action-bar .action-item .action-label.extension-action.enable, -.monaco-action-bar .action-item .action-label.extension-action.update { - color: white; - background-color: #327e36; - border-color: #519A55; -} - -.monaco-action-bar .action-item:not(.disabled):hover .action-label.extension-action.install, -.monaco-action-bar .action-item:not(.disabled):hover .action-label.extension-action.enable, -.monaco-action-bar .action-item:not(.disabled):hover .action-label.extension-action.update { - background-color: #478E4B; -} - -.monaco-action-bar .action-item:not(.disabled):active .action-label.extension-action.install, -.monaco-action-bar .action-item:not(.disabled):active .action-label.extension-action.enable, -.monaco-action-bar .action-item:not(.disabled):active .action-label.extension-action.update { - background-color: #6DA770; -} - -.monaco-action-bar .action-item .action-label.extension-action.reload { - color: white; - background-color: #007ACC; - border-color: #3F8BCE; -} - -.monaco-action-bar .action-item:not(.disabled):hover .action-label.extension-action.reload { - background-color: #2584C4; -} - -.monaco-action-bar .action-item:not(.disabled):active .action-label.extension-action.reload { - background-color: #4294CC -} - .monaco-action-bar .action-item .action-label.clear-extensions { background: url('clear.svg') center center no-repeat; } -- GitLab From 9e0a6c00cdd8e6bf2ce298adc2b154a8fcefcfce Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 24 May 2017 13:12:13 +0200 Subject: [PATCH 0092/1347] Add tests for PagedScreenReaderStrategy --- .../browser/controller/textAreaState.test.ts | 87 ++++++++++++++++++- 1 file changed, 86 insertions(+), 1 deletion(-) diff --git a/src/vs/editor/test/browser/controller/textAreaState.test.ts b/src/vs/editor/test/browser/controller/textAreaState.test.ts index 2423f8d3836..1d2c76be87d 100644 --- a/src/vs/editor/test/browser/controller/textAreaState.test.ts +++ b/src/vs/editor/test/browser/controller/textAreaState.test.ts @@ -5,10 +5,12 @@ 'use strict'; import * as assert from 'assert'; -import { ISimpleModel, TextAreaState, ITextAreaWrapper } from 'vs/editor/browser/controller/textAreaState'; +import { ISimpleModel, TextAreaState, ITextAreaWrapper, PagedScreenReaderStrategy } from 'vs/editor/browser/controller/textAreaState'; import { Range } from 'vs/editor/common/core/range'; import { EndOfLinePreference } from 'vs/editor/common/editorCommon'; import { Disposable } from 'vs/base/common/lifecycle'; +import { Model } from "vs/editor/common/model/model"; +import { Selection } from 'vs/editor/common/core/selection'; export class MockTextAreaWrapper extends Disposable implements ITextAreaWrapper { @@ -488,6 +490,89 @@ suite('TextAreaState', () => { '⌨ï¸', 0 ); }); + + suite('PagedScreenReaderStrategy', () => { + + function testPagedScreenReaderStrategy(lines: string[], selection: Selection, expected: TextAreaState): void { + const model = Model.createFromString(lines.join('\n')); + const actual = PagedScreenReaderStrategy.fromEditorSelection(TextAreaState.EMPTY, model, selection); + assert.ok(actual.equals(expected), actual); + model.dispose(); + } + + test('simple', () => { + testPagedScreenReaderStrategy( + [ + 'Hello world!' + ], + new Selection(1, 13, 1, 13), + new TextAreaState('Hello world!', 12, 12) + ); + + testPagedScreenReaderStrategy( + [ + 'Hello world!' + ], + new Selection(1, 1, 1, 1), + new TextAreaState('Hello world!', 0, 0) + ); + + testPagedScreenReaderStrategy( + [ + 'Hello world!' + ], + new Selection(1, 1, 1, 6), + new TextAreaState('Hello world!', 0, 5) + ); + }); + + test('multiline', () => { + testPagedScreenReaderStrategy( + [ + 'Hello world!', + 'How are you?' + ], + new Selection(1, 1, 1, 1), + new TextAreaState('Hello world!\nHow are you?', 0, 0) + ); + + testPagedScreenReaderStrategy( + [ + 'Hello world!', + 'How are you?' + ], + new Selection(2, 1, 2, 1), + new TextAreaState('Hello world!\nHow are you?', 13, 13) + ); + }); + + test('page', () => { + testPagedScreenReaderStrategy( + [ + 'L1\nL2\nL3\nL4\nL5\nL6\nL7\nL8\nL9\nL10\nL11\nL12\nL13\nL14\nL15\nL16\nL17\nL18\nL19\nL20\nL21' + ], + new Selection(1, 1, 1, 1), + new TextAreaState('L1\nL2\nL3\nL4\nL5\nL6\nL7\nL8\nL9\nL10', 0, 0) + ); + + testPagedScreenReaderStrategy( + [ + 'L1\nL2\nL3\nL4\nL5\nL6\nL7\nL8\nL9\nL10\nL11\nL12\nL13\nL14\nL15\nL16\nL17\nL18\nL19\nL20\nL21' + ], + new Selection(11, 1, 11, 1), + new TextAreaState('L11\nL12\nL13\nL14\nL15\nL16\nL17\nL18\nL19\nL20', 0, 0) + ); + + testPagedScreenReaderStrategy( + [ + 'L1\nL2\nL3\nL4\nL5\nL6\nL7\nL8\nL9\nL10\nL11\nL12\nL13\nL14\nL15\nL16\nL17\nL18\nL19\nL20\nL21' + ], + new Selection(12, 1, 12, 1), + new TextAreaState('L11\nL12\nL13\nL14\nL15\nL16\nL17\nL18\nL19\nL20', 4, 4) + ); + }); + + }); }); class SimpleModel implements ISimpleModel { -- GitLab From 7a0fec4abf7da4182333f6e769e80587593cc672 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 24 May 2017 13:14:25 +0200 Subject: [PATCH 0093/1347] Add trailing new line to current page (if there is one) --- .../editor/browser/controller/textAreaState.ts | 3 +-- .../browser/controller/textAreaState.test.ts | 16 ++++++++++++---- 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/src/vs/editor/browser/controller/textAreaState.ts b/src/vs/editor/browser/controller/textAreaState.ts index 41581a76cda..d398f510147 100644 --- a/src/vs/editor/browser/controller/textAreaState.ts +++ b/src/vs/editor/browser/controller/textAreaState.ts @@ -6,7 +6,6 @@ import { Range } from 'vs/editor/common/core/range'; import { EndOfLinePreference } from 'vs/editor/common/editorCommon'; -import { Constants } from 'vs/editor/common/core/uint'; import * as strings from 'vs/base/common/strings'; export interface ITextAreaWrapper { @@ -206,7 +205,7 @@ export class PagedScreenReaderStrategy { let offset = page * PagedScreenReaderStrategy._LINES_PER_PAGE; let startLineNumber = offset + 1; let endLineNumber = offset + PagedScreenReaderStrategy._LINES_PER_PAGE; - return new Range(startLineNumber, 1, endLineNumber, Constants.MAX_SAFE_SMALL_INTEGER); + return new Range(startLineNumber, 1, endLineNumber + 1, 1); } public static fromEditorSelection(previousState: TextAreaState, model: ISimpleModel, selection: Range): TextAreaState { diff --git a/src/vs/editor/test/browser/controller/textAreaState.test.ts b/src/vs/editor/test/browser/controller/textAreaState.test.ts index 1d2c76be87d..9170690d5ec 100644 --- a/src/vs/editor/test/browser/controller/textAreaState.test.ts +++ b/src/vs/editor/test/browser/controller/textAreaState.test.ts @@ -496,7 +496,7 @@ suite('TextAreaState', () => { function testPagedScreenReaderStrategy(lines: string[], selection: Selection, expected: TextAreaState): void { const model = Model.createFromString(lines.join('\n')); const actual = PagedScreenReaderStrategy.fromEditorSelection(TextAreaState.EMPTY, model, selection); - assert.ok(actual.equals(expected), actual); + assert.ok(actual.equals(expected)); model.dispose(); } @@ -552,7 +552,7 @@ suite('TextAreaState', () => { 'L1\nL2\nL3\nL4\nL5\nL6\nL7\nL8\nL9\nL10\nL11\nL12\nL13\nL14\nL15\nL16\nL17\nL18\nL19\nL20\nL21' ], new Selection(1, 1, 1, 1), - new TextAreaState('L1\nL2\nL3\nL4\nL5\nL6\nL7\nL8\nL9\nL10', 0, 0) + new TextAreaState('L1\nL2\nL3\nL4\nL5\nL6\nL7\nL8\nL9\nL10\n', 0, 0) ); testPagedScreenReaderStrategy( @@ -560,7 +560,7 @@ suite('TextAreaState', () => { 'L1\nL2\nL3\nL4\nL5\nL6\nL7\nL8\nL9\nL10\nL11\nL12\nL13\nL14\nL15\nL16\nL17\nL18\nL19\nL20\nL21' ], new Selection(11, 1, 11, 1), - new TextAreaState('L11\nL12\nL13\nL14\nL15\nL16\nL17\nL18\nL19\nL20', 0, 0) + new TextAreaState('L11\nL12\nL13\nL14\nL15\nL16\nL17\nL18\nL19\nL20\n', 0, 0) ); testPagedScreenReaderStrategy( @@ -568,7 +568,15 @@ suite('TextAreaState', () => { 'L1\nL2\nL3\nL4\nL5\nL6\nL7\nL8\nL9\nL10\nL11\nL12\nL13\nL14\nL15\nL16\nL17\nL18\nL19\nL20\nL21' ], new Selection(12, 1, 12, 1), - new TextAreaState('L11\nL12\nL13\nL14\nL15\nL16\nL17\nL18\nL19\nL20', 4, 4) + new TextAreaState('L11\nL12\nL13\nL14\nL15\nL16\nL17\nL18\nL19\nL20\n', 4, 4) + ); + + testPagedScreenReaderStrategy( + [ + 'L1\nL2\nL3\nL4\nL5\nL6\nL7\nL8\nL9\nL10\nL11\nL12\nL13\nL14\nL15\nL16\nL17\nL18\nL19\nL20\nL21' + ], + new Selection(21, 1, 21, 1), + new TextAreaState('L21', 0, 0) ); }); -- GitLab From 6cf1e118ae2722785ace9b192f4222ecb0857cec Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 24 May 2017 13:19:01 +0200 Subject: [PATCH 0094/1347] use process.hrtime for tick timers --- src/vs/base/node/startupTimers.d.ts | 6 +++--- src/vs/base/node/startupTimers.js | 16 +++++----------- .../electron-browser/bootstrap/index.js | 2 -- src/vs/workbench/electron-browser/shell.ts | 7 +------ 4 files changed, 9 insertions(+), 22 deletions(-) diff --git a/src/vs/base/node/startupTimers.d.ts b/src/vs/base/node/startupTimers.d.ts index c91175b0262..5a04270f4b6 100644 --- a/src/vs/base/node/startupTimers.d.ts +++ b/src/vs/base/node/startupTimers.d.ts @@ -26,13 +26,13 @@ declare interface TickController { stop(stopped?: number): void; } -export function startTimer(name: string, started?: number): TickController; +export function startTimer(name: string): TickController; -export function stopTimer(name: string, stopped?: number); +export function stopTimer(name: string); export function ticks(): Tick[]; -export function tick(name:string):Tick; +export function tick(name: string): Tick; export function setProfileList(names: string[]): void; diff --git a/src/vs/base/node/startupTimers.js b/src/vs/base/node/startupTimers.js index 45637a77b58..7fc81812efc 100644 --- a/src/vs/base/node/startupTimers.js +++ b/src/vs/base/node/startupTimers.js @@ -31,7 +31,7 @@ define([], function () { this.name = name; this.started = started; this.stopped = stopped; - this.duration = stopped - started; + this.duration = Math.round(((stopped[0] * 1.e9 + stopped[1]) - (started[0] * 1e9 + started[1])) / 1.e6); this.profile = profile; } Tick.compareByStart = function (a, b) { @@ -55,17 +55,14 @@ define([], function () { var _ticks = global._perfTicks; var _toBeProfiled = global._perfToBeProfiled; - function startTimer(name, started) { - if (typeof started !== 'number') { - started = Date.now(); - } + function startTimer(name) { if (_starts.has(name)) { throw new Error("${name}" + " already exists"); } if (_toBeProfiled.has(name)) { requireProfiler().startProfiling(name, true); } - _starts.set(name, { name: name, started: started }); + _starts.set(name, { name: name, started: process.hrtime() }); var stop = stopTimer.bind(undefined, name); return { stop: stop, @@ -76,14 +73,11 @@ define([], function () { }; } - function stopTimer(name, stopped) { - if (typeof stopped !== 'number') { - stopped = Date.now(); - } + function stopTimer(name) { var profile = _toBeProfiled.has(name) ? requireProfiler().stopProfiling(name) : undefined; var start = _starts.get(name); if (start !== undefined) { - var tick = new Tick(start.name, start.started, stopped, profile); + var tick = new Tick(start.name, start.started, process.hrtime(), profile); _ticks.set(name, tick); _starts.delete(name); } diff --git a/src/vs/workbench/electron-browser/bootstrap/index.js b/src/vs/workbench/electron-browser/bootstrap/index.js index 2b20efb7bbc..c01da62847a 100644 --- a/src/vs/workbench/electron-browser/bootstrap/index.js +++ b/src/vs/workbench/electron-browser/bootstrap/index.js @@ -192,8 +192,6 @@ function main() { beforeLoadWorkbenchMain: Date.now() }; - startTimer('elapsed:overall', configuration.perfStartTime); - const workbenchMainTimer = startTimer('load:workbench.main') require([ 'vs/workbench/electron-browser/workbench.main', diff --git a/src/vs/workbench/electron-browser/shell.ts b/src/vs/workbench/electron-browser/shell.ts index ac4b1759dde..bec5d37606b 100644 --- a/src/vs/workbench/electron-browser/shell.ts +++ b/src/vs/workbench/electron-browser/shell.ts @@ -59,7 +59,7 @@ import { IInstantiationService } from 'vs/platform/instantiation/common/instanti import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; import { InstantiationService } from 'vs/platform/instantiation/common/instantiationService'; import { IContextViewService } from 'vs/platform/contextview/browser/contextView'; -import { ILifecycleService, StartupKind } from 'vs/platform/lifecycle/common/lifecycle'; +import { ILifecycleService } from 'vs/platform/lifecycle/common/lifecycle'; import { IMarkerService } from 'vs/platform/markers/common/markers'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { IMessageService, IChoiceService, Severity, CloseAction } from 'vs/platform/message/common/message'; @@ -101,7 +101,6 @@ import { IWorkbenchThemeService } from 'vs/workbench/services/themes/common/work import { WorkbenchThemeService } from 'vs/workbench/services/themes/electron-browser/workbenchThemeService'; import { registerThemingParticipant, ITheme, ICssStyleCollector } from 'vs/platform/theme/common/themeService'; import { foreground, selectionBackground, focusBorder, scrollbarShadow, scrollbarSliderActiveBackground, scrollbarSliderBackground, scrollbarSliderHoverBackground, listHighlightForeground, inputPlaceholderForeground } from 'vs/platform/theme/common/colorRegistry'; -import { stopTimer } from 'vs/base/node/startupTimers'; /** * Services that we require for the Shell @@ -243,10 +242,6 @@ export class WorkbenchShell { startupKind: this.lifecycleService.startupKind }); - if (this.lifecycleService.startupKind === StartupKind.NewWindow) { - stopTimer('elapsed:overall'); - } - // Telemetry: startup metrics this.timerService.workbenchStarted = Date.now(); this.timerService.restoreEditorsDuration = info.restoreEditorsDuration; -- GitLab From 77b02e2c8101611c0299bf901a7e8644d06bf7b9 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 24 May 2017 15:27:05 +0200 Subject: [PATCH 0095/1347] use getAccessibilitySupport for F8, fixes #18366 --- src/vs/editor/contrib/gotoError/browser/gotoError.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/vs/editor/contrib/gotoError/browser/gotoError.ts b/src/vs/editor/contrib/gotoError/browser/gotoError.ts index 89fb5203c60..cf7c1658777 100644 --- a/src/vs/editor/contrib/gotoError/browser/gotoError.ts +++ b/src/vs/editor/contrib/gotoError/browser/gotoError.ts @@ -27,6 +27,8 @@ import { registerColor } from 'vs/platform/theme/common/colorRegistry'; import { IThemeService, ITheme } from 'vs/platform/theme/common/themeService'; import { Color } from 'vs/base/common/color'; import { EditorContextKeys } from 'vs/editor/common/editorContextKeys'; +import { getAccessibilitySupport } from 'vs/base/browser/browser'; +import { AccessibilitySupport } from 'vs/base/common/platform'; class MarkerModel { @@ -276,7 +278,9 @@ class MarkerNavigationWidget extends ZoneWidget { public show(where: Position, heightInLines: number): void { super.show(where, heightInLines); - this.focus(); + if (getAccessibilitySupport() !== AccessibilitySupport.Disabled) { + this.focus(); + } } private _wireModelAndView(): void { -- GitLab From fff0136ca6ef81de2bb5b1d96d7735bb1c837579 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 24 May 2017 15:36:37 +0200 Subject: [PATCH 0096/1347] don't double print messages from the extension service --- .../workbench/api/electron-browser/mainThreadExtensionService.ts | 1 - src/vs/workbench/api/node/extHost.protocol.ts | 1 - 2 files changed, 2 deletions(-) diff --git a/src/vs/workbench/api/electron-browser/mainThreadExtensionService.ts b/src/vs/workbench/api/electron-browser/mainThreadExtensionService.ts index 4bbea670cc2..14b8d69f5dc 100644 --- a/src/vs/workbench/api/electron-browser/mainThreadExtensionService.ts +++ b/src/vs/workbench/api/electron-browser/mainThreadExtensionService.ts @@ -135,7 +135,6 @@ export class MainProcessExtensionService extends AbstractExtensionService { throw ni(); } } -- GitLab From a0a1b9e0d606a2b20844a32e73899bfc340b562c Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Wed, 24 May 2017 15:54:47 +0200 Subject: [PATCH 0097/1347] fixes #26184 --- extensions/git/src/commands.ts | 2 +- src/vs/base/browser/ui/list/listWidget.ts | 23 +++++++++++++++++++ .../parts/scm/electron-browser/scmViewlet.ts | 17 +++++++++++++- 3 files changed, 40 insertions(+), 2 deletions(-) diff --git a/extensions/git/src/commands.ts b/extensions/git/src/commands.ts index 3ede435fff3..eed354dd8a4 100644 --- a/extensions/git/src/commands.ts +++ b/extensions/git/src/commands.ts @@ -149,7 +149,7 @@ export class CommandCenter { return await commands.executeCommand('vscode.open', right); } - return await commands.executeCommand('vscode.diff', left, right, title); + return await commands.executeCommand('vscode.diff', left, right, title, { preview: true }); } private getLeftResource(resource: Resource): Uri | undefined { diff --git a/src/vs/base/browser/ui/list/listWidget.ts b/src/vs/base/browser/ui/list/listWidget.ts index 5643cc768a9..d8f833da540 100644 --- a/src/vs/base/browser/ui/list/listWidget.ts +++ b/src/vs/base/browser/ui/list/listWidget.ts @@ -321,6 +321,7 @@ class MouseController implements IDisposable { this.disposables = []; this.disposables.push(view.addListener('mousedown', e => this.onMouseDown(e))); this.disposables.push(view.addListener('click', e => this.onPointer(e))); + this.disposables.push(view.addListener('dblclick', e => this.onDoubleClick(e))); this.disposables.push(view.addListener(TouchEventType.Tap, e => this.onPointer(e))); } @@ -362,6 +363,19 @@ class MouseController implements IDisposable { this.list.open(focus); } + private onDoubleClick(e: IListMouseEvent): void { + e.preventDefault(); + e.stopPropagation(); + + if (isSelectionChangeEvent(e)) { + return; + } + + const focus = this.list.getFocus(); + this.list.setSelection(focus); + this.list.pin(focus); + } + private changeSelection(e: IListMouseEvent, reference: number | undefined): void { const focus = e.index; @@ -574,6 +588,11 @@ export class List implements ISpliceable, IDisposable { return mapEvent(this._onOpen.event, indexes => this.toListEvent({ indexes })); } + private _onPin = new Emitter(); + @memoize get onPin(): Event> { + return mapEvent(this._onPin.event, indexes => this.toListEvent({ indexes })); + } + private _onDOMFocus = new Emitter(); get onDOMFocus(): Event { return this._onDOMFocus.event; } @@ -813,6 +832,10 @@ export class List implements ISpliceable, IDisposable { this._onOpen.fire(indexes); } + pin(indexes: number[]): void { + this._onPin.fire(indexes); + } + style(styles: IListStyles): void { const content: string[] = []; diff --git a/src/vs/workbench/parts/scm/electron-browser/scmViewlet.ts b/src/vs/workbench/parts/scm/electron-browser/scmViewlet.ts index f395ebd5eed..1d4064b4fb3 100644 --- a/src/vs/workbench/parts/scm/electron-browser/scmViewlet.ts +++ b/src/vs/workbench/parts/scm/electron-browser/scmViewlet.ts @@ -25,6 +25,8 @@ import { VIEWLET_ID } from 'vs/workbench/parts/scm/common/scm'; import { FileLabel } from 'vs/workbench/browser/labels'; import { CountBadge } from 'vs/base/browser/ui/countBadge/countBadge'; import { ISCMService, ISCMProvider, ISCMResourceGroup, ISCMResource } from 'vs/workbench/services/scm/common/scm'; +import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; +import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { IContextViewService, IContextMenuService } from 'vs/platform/contextview/browser/contextView'; import { IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; @@ -243,7 +245,9 @@ export class SCMViewlet extends Viewlet { @IThemeService protected themeService: IThemeService, @IMenuService private menuService: IMenuService, @IModelService private modelService: IModelService, - @ICommandService private commandService: ICommandService + @ICommandService private commandService: ICommandService, + @IEditorGroupService private groupService: IEditorGroupService, + @IWorkbenchEditorService private editorService: IWorkbenchEditorService ) { super(VIEWLET_ID, telemetryService, themeService); @@ -320,6 +324,11 @@ export class SCMViewlet extends Viewlet { .filter(e => !!e && isSCMResource(e)) .on(this.open, this, this.disposables); + chain(this.list.onPin) + .map(e => e.elements[0]) + .filter(e => !!e && isSCMResource(e)) + .on(this.pin, this, this.disposables); + this.list.onContextMenu(this.onListContextMenu, this, this.disposables); this.disposables.push(this.list); @@ -406,6 +415,12 @@ export class SCMViewlet extends Viewlet { .done(undefined, onUnexpectedError); } + private pin(): void { + const activeEditor = this.editorService.getActiveEditor(); + const activeEditorInput = this.editorService.getActiveEditorInput(); + this.groupService.pinEditor(activeEditor.position, activeEditorInput); + } + getTitle(): string { const title = localize('source control', "Source Control"); const providerLabel = this.scmService.activeProvider && this.scmService.activeProvider.label; -- GitLab From 7131a14238e363ce2df6e60e6a0f02c0543a2487 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 24 May 2017 17:06:53 +0200 Subject: [PATCH 0098/1347] Revert "allow offsets for fuzzyScore, towards #26096" This reverts commit 093eac502f5546171f0f57aecfc9aa1c28bfa413. --- src/vs/base/common/filters.ts | 74 ++++++++++++------------- src/vs/base/test/common/filters.test.ts | 7 --- 2 files changed, 37 insertions(+), 44 deletions(-) diff --git a/src/vs/base/common/filters.ts b/src/vs/base/common/filters.ts index 8719c8c662a..19056d36a50 100644 --- a/src/vs/base/common/filters.ts +++ b/src/vs/base/common/filters.ts @@ -450,7 +450,7 @@ _seps[':'] = true; const enum Arrow { Top = 0b1, Diag = 0b10, Left = 0b100 } -export function fuzzyScore(pattern: string, word: string, patternOffset: number = 0, wordOffset: number = 0): [number, number[]] { +export function fuzzyScore(pattern: string, word: string): [number, number[]] { const patternLen = pattern.length > 100 ? 100 : pattern.length; const wordLen = word.length > 100 ? 100 : word.length; @@ -465,16 +465,16 @@ export function fuzzyScore(pattern: string, word: string, patternOffset: number const lowPattern = pattern.toLowerCase(); const lowWord = word.toLowerCase(); - let patternPos = patternOffset; - let wordPos = wordOffset; + let i = 0; + let j = 0; - while (patternPos < patternLen && wordPos < wordLen) { - if (lowPattern[patternPos] === lowWord[wordPos]) { - patternPos += 1; + while (i < patternLen && j < wordLen) { + if (lowPattern[i] === lowWord[j]) { + i += 1; } - wordPos += 1; + j += 1; } - if (patternPos !== patternLen) { + if (i !== patternLen) { // no simple matches found -> return early return undefined; } @@ -482,24 +482,24 @@ export function fuzzyScore(pattern: string, word: string, patternOffset: number // keep track of the maximum score let maxScore = -1; - for (patternPos = patternOffset + 1; patternPos <= patternLen; patternPos++) { + for (i = 1; i <= patternLen; i++) { let lastLowWordChar = ''; - for (wordPos = wordOffset + 1; wordPos <= wordLen; wordPos++) { + for (j = 1; j <= wordLen; j++) { let score = -1; - let lowWordChar = lowWord[wordPos - 1]; - if (lowPattern[patternPos - 1] === lowWordChar) { + let lowWordChar = lowWord[j - 1]; + if (lowPattern[i - 1] === lowWordChar) { - if (wordPos === wordOffset + 1) { - if (pattern[patternPos - 1] === word[wordPos - 1]) { + if (j === 1) { + if (pattern[i - 1] === word[j - 1]) { score = 7; } else { score = 5; } - } else if (lowWordChar !== word[wordPos - 1]) { - if (pattern[patternPos - 1] === word[wordPos - 1]) { + } else if (lowWordChar !== word[j - 1]) { + if (pattern[i - 1] === word[j - 1]) { score = 7; } else { score = 5; @@ -512,38 +512,38 @@ export function fuzzyScore(pattern: string, word: string, patternOffset: number } } - _scores[patternPos][wordPos] = score; + _scores[i][j] = score; if (score > maxScore) { maxScore = score; } - let diag = _table[patternPos - 1][wordPos - 1] + (score > 1 ? 1 : score); - let top = _table[patternPos - 1][wordPos] + -1; - let left = _table[patternPos][wordPos - 1] + -1; + let diag = _table[i - 1][j - 1] + (score > 1 ? 1 : score); + let top = _table[i - 1][j] + -1; + let left = _table[i][j - 1] + -1; if (left >= top) { // left or diag if (left > diag) { - _table[patternPos][wordPos] = left; - _arrows[patternPos][wordPos] = Arrow.Left; + _table[i][j] = left; + _arrows[i][j] = Arrow.Left; } else if (left === diag) { - _table[patternPos][wordPos] = left; - _arrows[patternPos][wordPos] = Arrow.Left | Arrow.Diag; + _table[i][j] = left; + _arrows[i][j] = Arrow.Left | Arrow.Diag; } else { - _table[patternPos][wordPos] = diag; - _arrows[patternPos][wordPos] = Arrow.Diag; + _table[i][j] = diag; + _arrows[i][j] = Arrow.Diag; } } else { // top or diag if (top > diag) { - _table[patternPos][wordPos] = top; - _arrows[patternPos][wordPos] = Arrow.Top; + _table[i][j] = top; + _arrows[i][j] = Arrow.Top; } else if (top === diag) { - _table[patternPos][wordPos] = top; - _arrows[patternPos][wordPos] = Arrow.Top | Arrow.Diag; + _table[i][j] = top; + _arrows[i][j] = Arrow.Top | Arrow.Diag; } else { - _table[patternPos][wordPos] = diag; - _arrows[patternPos][wordPos] = Arrow.Diag; + _table[i][j] = diag; + _arrows[i][j] = Arrow.Diag; } } @@ -562,7 +562,7 @@ export function fuzzyScore(pattern: string, word: string, patternOffset: number } let bucket: [number, number[]][] = []; - findAllMatches(patternLen, patternLen, patternOffset, wordLen, wordOffset, 0, [], bucket, false); + findAllMatches(patternLen, patternLen, wordLen, 0, [], bucket, false); if (bucket.length === 0) { return undefined; @@ -580,7 +580,7 @@ export function fuzzyScore(pattern: string, word: string, patternOffset: number return topMatch; } -function findAllMatches(patternLen: number, patternPos: number, patternOffset: number, wordPos: number, wordOffset: number, total: number, matches: number[], bucket: [number, number[]][], lastMatched: boolean): void { +function findAllMatches(patternLen: number, patternPos: number, wordPos: number, total: number, matches: number[], bucket: [number, number[]][], lastMatched: boolean): void { if (bucket.length >= 10) { return; @@ -588,7 +588,7 @@ function findAllMatches(patternLen: number, patternPos: number, patternOffset: n let simpleMatchCount = 0; - while (patternPos > patternOffset && wordPos > wordOffset) { + while (patternPos > 0 && wordPos > 0) { let score = _scores[patternPos][wordPos]; let arrow = _arrows[patternPos][wordPos]; @@ -609,8 +609,8 @@ function findAllMatches(patternLen: number, patternPos: number, patternOffset: n if (arrow & Arrow.Left) { // left findAllMatches( - patternLen, patternPos, patternOffset, - wordPos - 1, wordOffset, + patternLen, patternPos, + wordPos - 1, matches.length !== 0 ? total - 1 : total, matches.slice(0), bucket, lastMatched ); diff --git a/src/vs/base/test/common/filters.test.ts b/src/vs/base/test/common/filters.test.ts index 797df43d1a2..ed8f708e757 100644 --- a/src/vs/base/test/common/filters.test.ts +++ b/src/vs/base/test/common/filters.test.ts @@ -325,13 +325,6 @@ suite('Filters', () => { assertMatches('f', ':foo', ':^foo', fuzzyScore); }); - test('fuzzyScore with offset', function () { - const matches = fuzzyScore('bc', 'abc', 0, 1); - assert.ok(matches); - const [, range] = matches; - assert.deepEqual(range, [1, 2]); - }); - function assertTopScore(filter: typeof fuzzyScore, pattern: string, expected: number, ...words: string[]) { let topScore = -(100 * 10); let topIdx = 0; -- GitLab From 16ece8e0c977b4c1d4e78d008c138eb91119f6c1 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 24 May 2017 17:31:02 +0200 Subject: [PATCH 0099/1347] make fuzzy match skip leading whitespace in pattern, fixes #26096 --- src/vs/base/common/filters.ts | 92 +++++++++++++++---------- src/vs/base/test/common/filters.test.ts | 14 +++- 2 files changed, 68 insertions(+), 38 deletions(-) diff --git a/src/vs/base/common/filters.ts b/src/vs/base/common/filters.ts index 19056d36a50..cb219b5c31b 100644 --- a/src/vs/base/common/filters.ts +++ b/src/vs/base/common/filters.ts @@ -448,6 +448,10 @@ _seps['\''] = true; _seps['"'] = true; _seps[':'] = true; +const _ws: { [ch: string]: boolean } = Object.create(null); +_ws[' '] = true; +_ws['\t'] = true; + const enum Arrow { Top = 0b1, Diag = 0b10, Left = 0b100 } export function fuzzyScore(pattern: string, word: string): [number, number[]] { @@ -455,7 +459,20 @@ export function fuzzyScore(pattern: string, word: string): [number, number[]] { const patternLen = pattern.length > 100 ? 100 : pattern.length; const wordLen = word.length > 100 ? 100 : word.length; - if (patternLen === 0) { + // Check for leading whitespace in the pattern and + // start matching just after that position. This is + // like `pattern = pattern.rtrim()` but doesn't create + // a new string + let patternStartPos = 0; + for (const ch of pattern) { + if (_ws[ch]) { + patternStartPos += 1; + } else { + break; + } + } + + if (patternLen === patternStartPos) { return [-1, []]; } @@ -465,16 +482,17 @@ export function fuzzyScore(pattern: string, word: string): [number, number[]] { const lowPattern = pattern.toLowerCase(); const lowWord = word.toLowerCase(); - let i = 0; - let j = 0; - while (i < patternLen && j < wordLen) { - if (lowPattern[i] === lowWord[j]) { - i += 1; + let patternPos = patternStartPos; + let wordPos = 0; + + while (patternPos < patternLen && wordPos < wordLen) { + if (lowPattern[patternPos] === lowWord[wordPos]) { + patternPos += 1; } - j += 1; + wordPos += 1; } - if (i !== patternLen) { + if (patternPos !== patternLen) { // no simple matches found -> return early return undefined; } @@ -482,24 +500,24 @@ export function fuzzyScore(pattern: string, word: string): [number, number[]] { // keep track of the maximum score let maxScore = -1; - for (i = 1; i <= patternLen; i++) { + for (patternPos = patternStartPos + 1; patternPos <= patternLen; patternPos++) { let lastLowWordChar = ''; - for (j = 1; j <= wordLen; j++) { + for (wordPos = 1; wordPos <= wordLen; wordPos++) { let score = -1; - let lowWordChar = lowWord[j - 1]; - if (lowPattern[i - 1] === lowWordChar) { + let lowWordChar = lowWord[wordPos - 1]; + if (lowPattern[patternPos - 1] === lowWordChar) { - if (j === 1) { - if (pattern[i - 1] === word[j - 1]) { + if (wordPos === 1) { + if (pattern[patternPos - 1] === word[wordPos - 1]) { score = 7; } else { score = 5; } - } else if (lowWordChar !== word[j - 1]) { - if (pattern[i - 1] === word[j - 1]) { + } else if (lowWordChar !== word[wordPos - 1]) { + if (pattern[patternPos - 1] === word[wordPos - 1]) { score = 7; } else { score = 5; @@ -512,38 +530,38 @@ export function fuzzyScore(pattern: string, word: string): [number, number[]] { } } - _scores[i][j] = score; + _scores[patternPos][wordPos] = score; if (score > maxScore) { maxScore = score; } - let diag = _table[i - 1][j - 1] + (score > 1 ? 1 : score); - let top = _table[i - 1][j] + -1; - let left = _table[i][j - 1] + -1; + let diag = _table[patternPos - 1][wordPos - 1] + (score > 1 ? 1 : score); + let top = _table[patternPos - 1][wordPos] + -1; + let left = _table[patternPos][wordPos - 1] + -1; if (left >= top) { // left or diag if (left > diag) { - _table[i][j] = left; - _arrows[i][j] = Arrow.Left; + _table[patternPos][wordPos] = left; + _arrows[patternPos][wordPos] = Arrow.Left; } else if (left === diag) { - _table[i][j] = left; - _arrows[i][j] = Arrow.Left | Arrow.Diag; + _table[patternPos][wordPos] = left; + _arrows[patternPos][wordPos] = Arrow.Left | Arrow.Diag; } else { - _table[i][j] = diag; - _arrows[i][j] = Arrow.Diag; + _table[patternPos][wordPos] = diag; + _arrows[patternPos][wordPos] = Arrow.Diag; } } else { // top or diag if (top > diag) { - _table[i][j] = top; - _arrows[i][j] = Arrow.Top; + _table[patternPos][wordPos] = top; + _arrows[patternPos][wordPos] = Arrow.Top; } else if (top === diag) { - _table[i][j] = top; - _arrows[i][j] = Arrow.Top | Arrow.Diag; + _table[patternPos][wordPos] = top; + _arrows[patternPos][wordPos] = Arrow.Top | Arrow.Diag; } else { - _table[i][j] = diag; - _arrows[i][j] = Arrow.Diag; + _table[patternPos][wordPos] = diag; + _arrows[patternPos][wordPos] = Arrow.Diag; } } @@ -562,7 +580,7 @@ export function fuzzyScore(pattern: string, word: string): [number, number[]] { } let bucket: [number, number[]][] = []; - findAllMatches(patternLen, patternLen, wordLen, 0, [], bucket, false); + findAllMatches(patternLen, patternLen, patternStartPos, wordLen, 0, [], bucket, false); if (bucket.length === 0) { return undefined; @@ -580,7 +598,7 @@ export function fuzzyScore(pattern: string, word: string): [number, number[]] { return topMatch; } -function findAllMatches(patternLen: number, patternPos: number, wordPos: number, total: number, matches: number[], bucket: [number, number[]][], lastMatched: boolean): void { +function findAllMatches(patternLen: number, patternPos: number, patternStartPos: number, wordPos: number, total: number, matches: number[], bucket: [number, number[]][], lastMatched: boolean): void { if (bucket.length >= 10) { return; @@ -588,7 +606,7 @@ function findAllMatches(patternLen: number, patternPos: number, wordPos: number, let simpleMatchCount = 0; - while (patternPos > 0 && wordPos > 0) { + while (patternPos > patternStartPos && wordPos > 0) { let score = _scores[patternPos][wordPos]; let arrow = _arrows[patternPos][wordPos]; @@ -609,7 +627,7 @@ function findAllMatches(patternLen: number, patternPos: number, wordPos: number, if (arrow & Arrow.Left) { // left findAllMatches( - patternLen, patternPos, + patternLen, patternPos, patternStartPos, wordPos - 1, matches.length !== 0 ? total - 1 : total, matches.slice(0), bucket, lastMatched @@ -635,7 +653,7 @@ function findAllMatches(patternLen: number, patternPos: number, wordPos: number, } } - if (matches.length !== patternLen) { + if (matches.length !== patternLen - patternStartPos) { // doesn't cover whole pattern return undefined; } diff --git a/src/vs/base/test/common/filters.test.ts b/src/vs/base/test/common/filters.test.ts index ed8f708e757..4753059f57c 100644 --- a/src/vs/base/test/common/filters.test.ts +++ b/src/vs/base/test/common/filters.test.ts @@ -195,7 +195,7 @@ suite('Filters', () => { function assertMatches(pattern: string, word: string, decoratedWord: string, filter: typeof fuzzyScore) { let r = filter(pattern, word); - assert.ok(Boolean(r) === Boolean(decoratedWord)); + assert.ok(!decoratedWord === (!r || r[1].length === 0)); if (r) { const [, matches] = r; let pos = 0; @@ -325,6 +325,18 @@ suite('Filters', () => { assertMatches('f', ':foo', ':^foo', fuzzyScore); }); + test('Vscode 1.12 no longer obeys \'sortText\' in completion items (from language server), #26096', function () { + assertMatches(' ', ' group', undefined, fuzzyScore); + assertMatches(' g', ' group', ' ^group', fuzzyScore); + assertMatches('g', ' group', ' ^group', fuzzyScore); + assertMatches('g g', ' groupGroup', undefined, fuzzyScore); + assertMatches('g g', ' group Group', ' ^group^ ^Group', fuzzyScore); + assertMatches(' g g', ' group Group', ' ^group^ ^Group', fuzzyScore); + assertMatches('zz', 'zzGroup', '^z^zGroup', fuzzyScore); + assertMatches('zzg', 'zzGroup', '^z^z^Group', fuzzyScore); + assertMatches('g', 'zzGroup', 'zz^Group', fuzzyScore); + }); + function assertTopScore(filter: typeof fuzzyScore, pattern: string, expected: number, ...words: string[]) { let topScore = -(100 * 10); let topIdx = 0; -- GitLab From fb0c96d37b281e0d86305148ce8f490e2f2e9187 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 24 May 2017 17:59:05 +0200 Subject: [PATCH 0100/1347] don't score when the word is the empty word, #26096 --- src/vs/base/common/filters.ts | 2 +- .../suggest/browser/completionModel.ts | 10 ++++++- .../test/browser/completionModel.test.ts | 28 ++++++++++++++++++- 3 files changed, 37 insertions(+), 3 deletions(-) diff --git a/src/vs/base/common/filters.ts b/src/vs/base/common/filters.ts index cb219b5c31b..d4b186650cc 100644 --- a/src/vs/base/common/filters.ts +++ b/src/vs/base/common/filters.ts @@ -473,7 +473,7 @@ export function fuzzyScore(pattern: string, word: string): [number, number[]] { } if (patternLen === patternStartPos) { - return [-1, []]; + return [-100, []]; } if (patternLen > wordLen) { diff --git a/src/vs/editor/contrib/suggest/browser/completionModel.ts b/src/vs/editor/contrib/suggest/browser/completionModel.ts index e3bc875458f..7bae1f39781 100644 --- a/src/vs/editor/contrib/suggest/browser/completionModel.ts +++ b/src/vs/editor/contrib/suggest/browser/completionModel.ts @@ -124,7 +124,15 @@ export class CompletionModel { word = wordLen === 0 ? '' : leadingLineContent.slice(-wordLen); } - if (typeof suggestion.filterText === 'string') { + if (wordLen === 0) { + // when there is nothing to score against, don't + // event try to do. Use a const rank and rely on + // the fallback-sort using the initial sort order. + // use a score of `-100` because that is out of the + // bound of values `fuzzyScore` will return + item.score = -100; + + } else if (typeof suggestion.filterText === 'string') { // when there is a `filterText` it must match the `word`. // if it matches we check with the label to compute highlights // and if that doesn't yield a result we have no highlights, diff --git a/src/vs/editor/contrib/suggest/test/browser/completionModel.test.ts b/src/vs/editor/contrib/suggest/test/browser/completionModel.test.ts index af82d02dca0..fd3f85b3235 100644 --- a/src/vs/editor/contrib/suggest/test/browser/completionModel.test.ts +++ b/src/vs/editor/contrib/suggest/test/browser/completionModel.test.ts @@ -6,7 +6,7 @@ import * as assert from 'assert'; import { ISuggestion, ISuggestResult, ISuggestSupport, SuggestionType } from 'vs/editor/common/modes'; -import { ISuggestionItem } from 'vs/editor/contrib/suggest/browser/suggest'; +import { ISuggestionItem, getSuggestionComparator } from 'vs/editor/contrib/suggest/browser/suggest'; import { CompletionModel } from 'vs/editor/contrib/suggest/browser/completionModel'; import { IPosition } from 'vs/editor/common/core/position'; import { TPromise } from "vs/base/common/winjs.base"; @@ -202,4 +202,30 @@ suite('CompletionModel', function () { }; assert.equal(model.items.length, 1); }); + + test('Vscode 1.12 no longer obeys \'sortText\' in completion items (from language server), #26096', function () { + + const item1 = createSuggestItem('<- groups', 2, 'property', false, { lineNumber: 1, column: 3 }); + item1.suggestion.filterText = ' groups'; + item1.suggestion.sortText = '00002'; + + const item2 = createSuggestItem('source', 0, 'property', false, { lineNumber: 1, column: 3 }); + item2.suggestion.filterText = 'source'; + item2.suggestion.sortText = '00001'; + + const items = [item1, item2].sort(getSuggestionComparator('inline')); + + model = new CompletionModel(items, 3, { + leadingLineContent: ' ', + characterCountDelta: 0 + }); + + assert.equal(model.items.length, 2); + + const [first, second] = model.items; + assert.equal(first.suggestion.label, 'source'); + assert.equal(second.suggestion.label, '<- groups'); + + }); + }); -- GitLab From 76a5c5249f29e0d29898b3f0900147afe6449b2f Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Wed, 24 May 2017 18:02:57 +0200 Subject: [PATCH 0101/1347] Fix extension actions tests --- .../test/electron-browser/extensionsActions.test.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/vs/workbench/parts/extensions/test/electron-browser/extensionsActions.test.ts b/src/vs/workbench/parts/extensions/test/electron-browser/extensionsActions.test.ts index f0ae1aaabe1..0f50eb3a0e5 100644 --- a/src/vs/workbench/parts/extensions/test/electron-browser/extensionsActions.test.ts +++ b/src/vs/workbench/parts/extensions/test/electron-browser/extensionsActions.test.ts @@ -99,7 +99,7 @@ suite('ExtensionsActions Test', () => { testObject.extension = paged.firstPage[0]; assert.ok(!testObject.enabled); assert.equal('Install', testObject.label); - assert.equal('extension-action install', testObject.class); + assert.equal('extension-action prominent install', testObject.class); done(); }); }); @@ -233,7 +233,7 @@ suite('ExtensionsActions Test', () => { const testObject: ExtensionsActions.CombinedInstallAction = instantiationService.createInstance(ExtensionsActions.CombinedInstallAction); assert.ok(!testObject.enabled); - assert.equal('extension-action install no-extension', testObject.class); + assert.equal('extension-action prominent install no-extension', testObject.class); }); test('Test CombinedInstallAction when extension is system extension', (done) => { @@ -244,7 +244,7 @@ suite('ExtensionsActions Test', () => { instantiationService.get(IExtensionsWorkbenchService).queryLocal().done(extensions => { testObject.extension = extensions[0]; assert.ok(!testObject.enabled); - assert.equal('extension-action install no-extension', testObject.class); + assert.equal('extension-action prominent install no-extension', testObject.class); done(); }); }); @@ -259,7 +259,7 @@ suite('ExtensionsActions Test', () => { testObject.extension = paged.firstPage[0]; assert.ok(testObject.enabled); assert.equal('Install', testObject.label); - assert.equal('extension-action install', testObject.class); + assert.equal('extension-action prominent install', testObject.class); done(); }); }); -- GitLab From d0e70aca3eef34037fdec72440c3f46f6a089043 Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Wed, 24 May 2017 11:04:57 -0700 Subject: [PATCH 0102/1347] Tweak error message for extension table in github issues --- src/vs/workbench/electron-browser/actions.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/electron-browser/actions.ts b/src/vs/workbench/electron-browser/actions.ts index b5b380afb6a..98e0d84f20c 100644 --- a/src/vs/workbench/electron-browser/actions.ts +++ b/src/vs/workbench/electron-browser/actions.ts @@ -739,7 +739,7 @@ ${tableHeader}\n${table}; // 2000 chars is browsers de-facto limit for URLs, 400 chars are allowed for other string parts of the issue URL // http://stackoverflow.com/questions/417142/what-is-the-maximum-length-of-a-url-in-different-browsers if (encodeURIComponent(extensionTable).length > 1600) { - return 'the listing exceeds the lower minimum of browsers\' URL characters limit'; + return 'the listing length exceeds browsers\' URL characters limit'; } return extensionTable; -- GitLab From a6b7efe17f56ae26076cd7b7ee95830d5b24d3d2 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 24 May 2017 20:18:03 +0200 Subject: [PATCH 0103/1347] theming :lipstick: --- .../base/browser/ui/findinput/findInput.css | 26 ------------------- .../parts/debug/browser/debugActionItems.ts | 4 +-- .../debug/browser/media/breakpointWidget.css | 4 --- .../debug/browser/media/debugViewlet.css | 15 ----------- .../extensions/browser/extensionsActions.ts | 7 ++++- .../browser/media/extensionActions.css | 1 - .../preferences/browser/keybindingsEditor.ts | 12 +++++++-- .../browser/media/keybindingsEditor.css | 10 ------- 8 files changed, 18 insertions(+), 61 deletions(-) diff --git a/src/vs/base/browser/ui/findinput/findInput.css b/src/vs/base/browser/ui/findinput/findInput.css index 413c2dcafb3..b785b4fa4cc 100644 --- a/src/vs/base/browser/ui/findinput/findInput.css +++ b/src/vs/base/browser/ui/findinput/findInput.css @@ -28,28 +28,6 @@ right: 2px; } -.monaco-findInput > .controls > .matchCount { - margin-left: 2px; - float: left; - overflow: hidden; - max-width: 30px; - min-width: 20px; - text-align: center; - - border-radius: 5px; - padding: 0 4px; - - -webkit-box-sizing: border-box; - -o-box-sizing: border-box; - -moz-box-sizing: border-box; - -ms-box-sizing: border-box; - box-sizing: border-box; -} - -.vs .monaco-findInput > .controls > .matchCount { - background: #ddd; -} - .vs .monaco-findInput.disabled { background-color: #E1E1E1; } @@ -59,10 +37,6 @@ background-color: #333; } -.vs-dark .monaco-findInput > .controls > .matchCount { - background: #555; -} - /* Highlighting */ .monaco-findInput.highlight-0 .controls { animation: monaco-findInput-highlight-0 100ms linear 0s; diff --git a/src/vs/workbench/parts/debug/browser/debugActionItems.ts b/src/vs/workbench/parts/debug/browser/debugActionItems.ts index 8f83bebe2da..edb07e3d969 100644 --- a/src/vs/workbench/parts/debug/browser/debugActionItems.ts +++ b/src/vs/workbench/parts/debug/browser/debugActionItems.ts @@ -117,8 +117,8 @@ export class StartDebugActionItem extends EventEmitter implements IActionItem { } })); this.toDispose.push(attachStylerCallback(this.themeService, { selectBorder }, colors => { - this.container.style.borderColor = colors.selectBorder; - selectBoxContainer.style.borderLeftColor = colors.selectBorder; + this.container.style.border = colors.selectBorder ? `1px solid ${colors.selectBorder}` : null; + selectBoxContainer.style.borderLeft = colors.selectBorder ? `1px solid ${colors.selectBorder}` : null; })); this.updateOptions(); diff --git a/src/vs/workbench/parts/debug/browser/media/breakpointWidget.css b/src/vs/workbench/parts/debug/browser/media/breakpointWidget.css index ad120c2ab7f..8d190b91ca0 100644 --- a/src/vs/workbench/parts/debug/browser/media/breakpointWidget.css +++ b/src/vs/workbench/parts/debug/browser/media/breakpointWidget.css @@ -16,10 +16,6 @@ padding: 0 10px; } -.monaco-editor .zone-widget .zone-widget-container.breakpoint-widget .breakpoint-select-container .select-box { - border-color: rgba(128, 128, 128, 0.35); -} - .monaco-editor .zone-widget .zone-widget-container.breakpoint-widget .inputBoxContainer { flex: 1; } diff --git a/src/vs/workbench/parts/debug/browser/media/debugViewlet.css b/src/vs/workbench/parts/debug/browser/media/debugViewlet.css index feff9b7cff6..b0d6b4510a1 100644 --- a/src/vs/workbench/parts/debug/browser/media/debugViewlet.css +++ b/src/vs/workbench/parts/debug/browser/media/debugViewlet.css @@ -57,7 +57,6 @@ margin-right: 0.3em; height: 20px; flex-shrink: 1; - border: 1px solid #dddddd; margin-top: 7px; } @@ -65,11 +64,6 @@ border-radius: 4px; } -.vs-dark .monaco-workbench > .part > .title > .title-actions .start-debug-action-item, -.hc-black .monaco-workbench > .part > .title > .title-actions .start-debug-action-item { - border-color: #3c3c3c; -} - .monaco-workbench > .part > .title > .title-actions .start-debug-action-item .icon { height: 20px; width: 20px; @@ -84,15 +78,6 @@ background: url('continue-inverse.svg') center center no-repeat; } -.monaco-workbench > .part > .title > .title-actions .start-debug-action-item .configuration { - border-left: 1px solid #dddddd; -} - -.vs-dark .monaco-workbench > .part > .title > .title-actions .start-debug-action-item .configuration, -.hc-black .monaco-workbench > .part > .title > .title-actions .start-debug-action-item .configuration { - border-color: #3c3c3c; -} - .monaco-workbench .monaco-action-bar .start-debug-action-item .configuration .select-box { border: none; margin-top: 0px; diff --git a/src/vs/workbench/parts/extensions/browser/extensionsActions.ts b/src/vs/workbench/parts/extensions/browser/extensionsActions.ts index 3b557abaf33..f2cf8c9cacd 100644 --- a/src/vs/workbench/parts/extensions/browser/extensionsActions.ts +++ b/src/vs/workbench/parts/extensions/browser/extensionsActions.ts @@ -33,7 +33,7 @@ import URI from 'vs/base/common/uri'; import { CommandsRegistry } from 'vs/platform/commands/common/commands'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { registerThemingParticipant, ITheme, ICssStyleCollector } from "vs/platform/theme/common/themeService"; -import { buttonBackground, buttonForeground, buttonHoverBackground, contrastBorder, registerColor } from "vs/platform/theme/common/colorRegistry"; +import { buttonBackground, buttonForeground, buttonHoverBackground, contrastBorder, registerColor, foreground } from "vs/platform/theme/common/colorRegistry"; import { Color } from "vs/base/common/color"; export class InstallAction extends Action { @@ -1408,6 +1408,11 @@ export const extensionButtonProminentHoverBackground = registerColor('extensionB }, localize('extensionButtonProminentHoverBackground', "Button background hover color for actions extension that stand out (e.g. install button).")); registerThemingParticipant((theme: ITheme, collector: ICssStyleCollector) => { + const foregroundColor = theme.getColor(foreground); + if (foregroundColor) { + collector.addRule(`.monaco-action-bar .action-item .action-label.extension-action.built-in-status { border-color: ${foregroundColor}; }`); + } + const buttonBackgroundColor = theme.getColor(buttonBackground); if (buttonBackgroundColor) { collector.addRule(`.monaco-action-bar .action-item .action-label.extension-action { background-color: ${buttonBackgroundColor}; }`); diff --git a/src/vs/workbench/parts/extensions/browser/media/extensionActions.css b/src/vs/workbench/parts/extensions/browser/media/extensionActions.css index e80db60cdef..c9b9d8508a2 100644 --- a/src/vs/workbench/parts/extensions/browser/media/extensionActions.css +++ b/src/vs/workbench/parts/extensions/browser/media/extensionActions.css @@ -36,7 +36,6 @@ .monaco-action-bar .action-item .action-label.extension-action.built-in-status { border-radius: 4px; - border-color: #c1c1c1; color: inherit; background-color: transparent; opacity: 0.9; diff --git a/src/vs/workbench/parts/preferences/browser/keybindingsEditor.ts b/src/vs/workbench/parts/preferences/browser/keybindingsEditor.ts index 2b8adf6502f..ca94ecd2c2b 100644 --- a/src/vs/workbench/parts/preferences/browser/keybindingsEditor.ts +++ b/src/vs/workbench/parts/preferences/browser/keybindingsEditor.ts @@ -33,12 +33,13 @@ import { IKeybindingEditingService } from 'vs/workbench/services/keybinding/comm import { IListService } from 'vs/platform/list/browser/listService'; import { List } from 'vs/base/browser/ui/list/listWidget'; import { IDelegate, IRenderer, IListContextMenuEvent, IListEvent } from 'vs/base/browser/ui/list/list'; -import { IThemeService } from 'vs/platform/theme/common/themeService'; +import { IThemeService, registerThemingParticipant, ITheme, ICssStyleCollector } from 'vs/platform/theme/common/themeService'; import { IContextKeyService, IContextKey } from 'vs/platform/contextkey/common/contextkey'; import { IChoiceService, IMessageService, Severity } from 'vs/platform/message/common/message'; import { StandardKeyboardEvent } from 'vs/base/browser/keyboardEvent'; import { KeyCode, ResolvedKeybinding } from 'vs/base/common/keyCodes'; import { attachListStyler } from 'vs/platform/theme/common/styler'; +import { listHighlightForeground } from "vs/platform/theme/common/colorRegistry"; let $ = DOM.$; @@ -797,4 +798,11 @@ class WhenColumn extends Column { private getAriaLabel(keybindingItemEntry: IKeybindingItemEntry): string { return keybindingItemEntry.keybindingItem.when ? localize('whenAriaLabel', "When is {0}.", keybindingItemEntry.keybindingItem.when) : localize('noWhen', "No when context."); } -} \ No newline at end of file +} + +registerThemingParticipant((theme: ITheme, collector: ICssStyleCollector) => { + const listHighlightForegroundColor = theme.getColor(listHighlightForeground); + if (listHighlightForegroundColor) { + collector.addRule(`.keybindings-editor > .keybindings-body > .keybindings-list-container .monaco-list-row > .column .highlight { color: ${listHighlightForegroundColor}; }`); + } +}); \ No newline at end of file diff --git a/src/vs/workbench/parts/preferences/browser/media/keybindingsEditor.css b/src/vs/workbench/parts/preferences/browser/media/keybindingsEditor.css index 27a753c86bd..29b4fe0a8d1 100644 --- a/src/vs/workbench/parts/preferences/browser/media/keybindingsEditor.css +++ b/src/vs/workbench/parts/preferences/browser/media/keybindingsEditor.css @@ -148,19 +148,9 @@ } .keybindings-editor > .keybindings-body > .keybindings-list-container .monaco-list-row > .column .highlight { - color: #007ACC; font-weight: bold; } -.keybindings-editor > .keybindings-body > .keybindings-list-container .monaco-list:focus .monaco-list-row.selected > .column .highlight { - color: #1b3c53; -} - -.vs-dark .keybindings-editor > .keybindings-body > .keybindings-list-container .monaco-list:focus .monaco-list-row.selected > .column .highlight, -.hc-black .keybindings-editor > .keybindings-body > .keybindings-list-container .monaco-list:focus .monaco-list-row.selected > .column .highlight { - color: #049aff; -} - .keybindings-editor > .keybindings-body > .keybindings-list-container .monaco-list-row > .column .monaco-action-bar { display: none; flex: 1; -- GitLab From b648308eb340729c76fa570a857488ad4e1baeee Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Wed, 24 May 2017 11:25:31 -0700 Subject: [PATCH 0104/1347] Fixes #26886 --- .../editor/contrib/suggest/browser/media/suggest.css | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/vs/editor/contrib/suggest/browser/media/suggest.css b/src/vs/editor/contrib/suggest/browser/media/suggest.css index fe64def759b..08b4e45593d 100644 --- a/src/vs/editor/contrib/suggest/browser/media/suggest.css +++ b/src/vs/editor/contrib/suggest/browser/media/suggest.css @@ -34,12 +34,18 @@ .monaco-editor .suggest-widget.docs-side > .tree, .monaco-editor .suggest-widget.docs-side > .details { - width: 328px; + /* subtract 2px for border, and another 2 for the Chromium zoom issue + where the children get slightly bigger width than what is set + which makes the docs go below the list */ + width: calc(50% - 4px); } .monaco-editor.hc-black .suggest-widget.docs-side > .tree, .monaco-editor.hc-black .suggest-widget.docs-side > .details { - width: 326px; + /* subtract 4px for border, and another 2 for the Chromium zoom issue + where the children get slightly bigger width than what is set + which makes the docs go below the list */ + width: calc(50% - 6px); } /* Styles for Message element for when widget is loading or is empty */ -- GitLab From e4e9bf96216f0166758b7d062a8b9bd99d1a0909 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Wed, 24 May 2017 11:39:04 -0700 Subject: [PATCH 0105/1347] Enable needs-more-info bot plugin --- .github/needs_more_info.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/needs_more_info.yml b/.github/needs_more_info.yml index 0e246fd554a..934e98898d4 100644 --- a/.github/needs_more_info.yml +++ b/.github/needs_more_info.yml @@ -1,6 +1,6 @@ { daysUntilClose: 7, needsMoreInfoLabel: 'needs more info', - perform: false, + perform: true, closeComment: 'This issue has been closed automatically because it needs more information and has not had recent activity. Please refer to our [guidelines](https://github.com/Microsoft/vscode/blob/master/CONTRIBUTING.md) for filing issues. Thank you for your contributions.' } -- GitLab From 06fdcf1962924c3a6e00f531d8004cdaeb13f5d5 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Wed, 24 May 2017 11:56:54 -0700 Subject: [PATCH 0106/1347] Fixes #27169 --- src/vs/editor/contrib/suggest/browser/suggestWidget.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index 168d22bc846..56871ef9504 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -599,12 +599,14 @@ export class SuggestWidget implements IContentWidget, IDelegate this.messageElement.textContent = SuggestWidget.LOADING_MESSAGE; hide(this.listElement, this.details.element); show(this.messageElement); + removeClass(this.element, 'docs-side'); this.show(); break; case State.Empty: this.messageElement.textContent = SuggestWidget.NO_SUGGESTIONS_MESSAGE; hide(this.listElement, this.details.element); show(this.messageElement); + removeClass(this.element, 'docs-side'); this.show(); break; case State.Open: -- GitLab From 26aaf73ff9604d3e303c8ef401fe46bb7f463049 Mon Sep 17 00:00:00 2001 From: Amy Qiu Date: Wed, 24 May 2017 12:49:23 -0700 Subject: [PATCH 0107/1347] Add mementos to shutdown --- .../parts/search/browser/searchViewlet.ts | 35 +++++++++++-------- 1 file changed, 21 insertions(+), 14 deletions(-) diff --git a/src/vs/workbench/parts/search/browser/searchViewlet.ts b/src/vs/workbench/parts/search/browser/searchViewlet.ts index deb804b45b1..ed2a0c9f953 100644 --- a/src/vs/workbench/parts/search/browser/searchViewlet.ts +++ b/src/vs/workbench/parts/search/browser/searchViewlet.ts @@ -903,23 +903,10 @@ export class SearchViewlet extends Viewlet { const isCaseSensitive = this.searchWidget.searchInput.getCaseSensitive(); const contentPattern = this.searchWidget.searchInput.getValue(); const patternExcludes = this.inputPatternExclusions.getValue().trim(); - const exclusionsUsePattern = this.inputPatternExclusions.isGlobPattern(); const patternIncludes = this.inputPatternIncludes.getValue().trim(); - const includesUsePattern = this.inputPatternIncludes.isGlobPattern(); const useIgnoreFiles = this.inputPatternExclusions.useIgnoreFiles(); const useExcludeSettings = this.inputPatternExclusions.useExcludeSettings(); - // store memento - this.viewletSettings['query.contentPattern'] = contentPattern; - this.viewletSettings['query.regex'] = isRegex; - this.viewletSettings['query.wholeWords'] = isWholeWords; - this.viewletSettings['query.caseSensitive'] = isCaseSensitive; - this.viewletSettings['query.folderExclusions'] = patternExcludes; - this.viewletSettings['query.exclusionsUsePattern'] = exclusionsUsePattern; - this.viewletSettings['query.folderIncludes'] = patternIncludes; - this.viewletSettings['query.includesUsePattern'] = includesUsePattern; - this.viewletSettings['query.useIgnoreFiles'] = useIgnoreFiles; - if (!rerunQuery) { return; } @@ -1349,7 +1336,27 @@ export class SearchViewlet extends Viewlet { } public shutdown(): void { - this.viewletSettings['query.contentPattern'] = this.searchWidget.searchInput.getValue(); + const isRegex = this.searchWidget.searchInput.getRegex(); + const isWholeWords = this.searchWidget.searchInput.getWholeWords(); + const isCaseSensitive = this.searchWidget.searchInput.getCaseSensitive(); + const contentPattern = this.searchWidget.searchInput.getValue(); + const patternExcludes = this.inputPatternExclusions.getValue().trim(); + const exclusionsUsePattern = this.inputPatternExclusions.isGlobPattern(); + const patternIncludes = this.inputPatternIncludes.getValue().trim(); + const includesUsePattern = this.inputPatternIncludes.isGlobPattern(); + const useIgnoreFiles = this.inputPatternExclusions.useIgnoreFiles(); + + // store memento + this.viewletSettings['query.contentPattern'] = contentPattern; + this.viewletSettings['query.regex'] = isRegex; + this.viewletSettings['query.wholeWords'] = isWholeWords; + this.viewletSettings['query.caseSensitive'] = isCaseSensitive; + this.viewletSettings['query.folderExclusions'] = patternExcludes; + this.viewletSettings['query.exclusionsUsePattern'] = exclusionsUsePattern; + this.viewletSettings['query.folderIncludes'] = patternIncludes; + this.viewletSettings['query.includesUsePattern'] = includesUsePattern; + this.viewletSettings['query.useIgnoreFiles'] = useIgnoreFiles; + this.viewletSettings['query.contentPattern'] = contentPattern; super.shutdown(); } -- GitLab From d3cf7e5fd8cd4db834e1ea19dc0ceee80cded539 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Wed, 24 May 2017 10:50:28 -0700 Subject: [PATCH 0108/1347] Move terminalProcess to node/ Part of #27182 --- .../parts/terminal/electron-browser/terminalInstance.ts | 4 ++-- .../terminal/{electron-browser => node}/terminalProcess.js | 0 2 files changed, 2 insertions(+), 2 deletions(-) rename src/vs/workbench/parts/terminal/{electron-browser => node}/terminalProcess.js (100%) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index fe48ea264ff..c7bb9a07131 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -473,9 +473,9 @@ export class TerminalInstance implements ITerminalInstance { } const env = TerminalInstance.createTerminalEnv(process.env, shell, this._getCwd(shell, workspace), locale, this._cols, this._rows); this._title = shell.name || ''; - this._process = cp.fork('./terminalProcess', [], { + this._process = cp.fork('../node/terminalProcess', [], { env: env, - cwd: URI.parse(path.dirname(require.toUrl('./terminalProcess'))).fsPath + cwd: URI.parse(path.dirname(require.toUrl('../node/terminalProcess'))).fsPath }); if (!shell.name) { // Only listen for process title changes when a name is not provided diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalProcess.js b/src/vs/workbench/parts/terminal/node/terminalProcess.js similarity index 100% rename from src/vs/workbench/parts/terminal/electron-browser/terminalProcess.js rename to src/vs/workbench/parts/terminal/node/terminalProcess.js -- GitLab From e0277260b09596f086158bfe91d942137f700390 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Wed, 24 May 2017 13:34:44 -0700 Subject: [PATCH 0109/1347] Add node-pty typings back --- src/typings/node-pty.d.ts | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 src/typings/node-pty.d.ts diff --git a/src/typings/node-pty.d.ts b/src/typings/node-pty.d.ts new file mode 100644 index 00000000000..e09b1eb47e5 --- /dev/null +++ b/src/typings/node-pty.d.ts @@ -0,0 +1,27 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +declare module 'node-pty' { + export function fork(file: string, args: string[], options: any): Terminal; + export function spawn(file: string, args: string[], options: any): Terminal; + export function createTerminal(file: string, args: string[], options: any): Terminal; + + export interface Terminal { + pid: number; + + /** + * The title of the active process. + */ + process: string; + + on(event: string, callback: (data: any) => void): void; + + resize(columns: number, rows: number): void; + + write(data: string): void; + + kill(): void; + } +} \ No newline at end of file -- GitLab From ed9cdf55b0c9e327ab634cc3e09c97b63671af03 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Wed, 24 May 2017 13:37:43 -0700 Subject: [PATCH 0110/1347] Fork terminalProcess using amd, convert to TS Fixes #27182 --- src/vs/workbench/buildfile.js | 4 ++- .../electron-browser/terminalInstance.ts | 5 +-- ...{terminalProcess.js => terminalProcess.ts} | 35 +++++++++++++------ 3 files changed, 30 insertions(+), 14 deletions(-) rename src/vs/workbench/parts/terminal/node/{terminalProcess.js => terminalProcess.ts} (83%) diff --git a/src/vs/workbench/buildfile.js b/src/vs/workbench/buildfile.js index dfb1ee2b600..b4102009d69 100644 --- a/src/vs/workbench/buildfile.js +++ b/src/vs/workbench/buildfile.js @@ -25,7 +25,9 @@ exports.collectModules = function (excludes) { createModuleDescription('vs/workbench/services/search/node/worker/searchWorkerApp', []), createModuleDescription('vs/workbench/services/files/node/watcher/unix/watcherApp', []), - createModuleDescription('vs/workbench/node/extensionHostProcess', []) + createModuleDescription('vs/workbench/node/extensionHostProcess', []), + + createModuleDescription('vs/workbench/parts/terminal/node/terminalProcess', []) ]; return modules; diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index c7bb9a07131..07f8b6b53cb 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -473,8 +473,8 @@ export class TerminalInstance implements ITerminalInstance { } const env = TerminalInstance.createTerminalEnv(process.env, shell, this._getCwd(shell, workspace), locale, this._cols, this._rows); this._title = shell.name || ''; - this._process = cp.fork('../node/terminalProcess', [], { - env: env, + this._process = cp.fork(URI.parse(require.toUrl('bootstrap')).fsPath, ['--type=terminal'], { + env, cwd: URI.parse(path.dirname(require.toUrl('../node/terminalProcess'))).fsPath }); if (!shell.name) { @@ -622,6 +622,7 @@ export class TerminalInstance implements ITerminalInstance { env['PTYCOLS'] = cols.toString(); env['PTYROWS'] = rows.toString(); } + env['AMD_ENTRYPOINT'] = 'vs/workbench/parts/terminal/node/terminalProcess'; return env; } diff --git a/src/vs/workbench/parts/terminal/node/terminalProcess.js b/src/vs/workbench/parts/terminal/node/terminalProcess.ts similarity index 83% rename from src/vs/workbench/parts/terminal/node/terminalProcess.js rename to src/vs/workbench/parts/terminal/node/terminalProcess.ts index 8cfea5673f1..12642b21a41 100644 --- a/src/vs/workbench/parts/terminal/node/terminalProcess.js +++ b/src/vs/workbench/parts/terminal/node/terminalProcess.ts @@ -3,21 +3,23 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -var fs = require('fs'); -var os = require('os'); -var path = require('path'); -var ptyJs = require('node-pty'); +import * as fs from 'fs'; +fs.writeFileSync('/home/daniel/testing-terminal-1', 'foo'); +import * as os from 'os'; +import * as path from 'path'; +import * as ptyJs from 'node-pty'; + +fs.writeFileSync('/home/daniel/testing-terminal-2', 'foo'); // The pty process needs to be run in its own child process to get around maxing out CPU on Mac, // see https://github.com/electron/electron/issues/38 - -var name; +var shellName: string; if (os.platform() === 'win32') { - name = path.basename(process.env.PTYSHELL); + shellName = path.basename(process.env.PTYSHELL); } else { // Using 'xterm-256color' here helps ensure that the majority of Linux distributions will use a // color prompt as defined in the default ~/.bashrc file. - name = 'xterm-256color'; + shellName = 'xterm-256color'; } var shell = process.env.PTYSHELL; var args = getArgs(); @@ -29,16 +31,26 @@ var currentTitle = ''; setupPlanB(process.env.PTYPID); cleanEnv(); -var options = { - name: name, - cwd: cwd +interface IOptions { + name: string; + cwd: string; + cols?: number; + rows?: number; +} + +var options: IOptions = { + name: shellName, + cwd }; if (cols && rows) { options.cols = parseInt(cols, 10); options.rows = parseInt(rows, 10); } +fs.writeFileSync('/home/daniel/testing-terminal-3', 'foo'); var ptyProcess = ptyJs.fork(shell, args, options); + +fs.writeFileSync('/home/daniel/testing-terminal-4', 'foo'); var closeTimeout; var exitCode; @@ -93,6 +105,7 @@ function getArgs() { function cleanEnv() { var keys = [ + 'AMD_ENTRYPOINT', 'ELECTRON_RUN_AS_NODE', 'PTYCWD', 'PTYPID', -- GitLab From 8178df7a1f82013ba0b61d9bfd5cf5686e918435 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 24 May 2017 13:39:32 -0700 Subject: [PATCH 0111/1347] Fix ts/js code lens for trailing special character. Fixes #27211 --- extensions/typescript/src/features/baseCodeLensProvider.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/typescript/src/features/baseCodeLensProvider.ts b/extensions/typescript/src/features/baseCodeLensProvider.ts index 9d2c4bfb768..98e4de9cc1c 100644 --- a/extensions/typescript/src/features/baseCodeLensProvider.ts +++ b/extensions/typescript/src/features/baseCodeLensProvider.ts @@ -108,7 +108,7 @@ export abstract class TypeScriptBaseCodeLensProvider implements CodeLensProvider const text = document.getText(range); - const identifierMatch = new RegExp(`^(.*?(\\b|\\W))${(item.text || '').replace(/[-[\]{}()*+?.,\\^$|#\s]/g, '\\$&')}\\b`, 'gm'); + const identifierMatch = new RegExp(`^(.*?(\\b|\\W))${(item.text || '').replace(/[-[\]{}()*+?.,\\^$|#\s]/g, '\\$&')}(\\b|\\W)`, 'gm'); const match = identifierMatch.exec(text); const prefixLength = match ? match.index + match[1].length : 0; const startOffset = document.offsetAt(new Position(range.start.line, range.start.character)) + prefixLength; -- GitLab From 84f154b7945b0430ea2ae68e844b554b8df16383 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 24 May 2017 13:54:05 -0700 Subject: [PATCH 0112/1347] Fix 27195 Make sure we handle the case of `/**/` properly in json files --- extensions/json/syntaxes/JSON.tmLanguage | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/json/syntaxes/JSON.tmLanguage b/extensions/json/syntaxes/JSON.tmLanguage index 9d6a24cc16a..507eb03ec93 100644 --- a/extensions/json/syntaxes/JSON.tmLanguage +++ b/extensions/json/syntaxes/JSON.tmLanguage @@ -98,7 +98,7 @@ begin - /\*\* + /\*\*(?!/) captures 0 -- GitLab From b14bde0c6aaa8ccf3f925542f3a18d55c5a9e3df Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Wed, 24 May 2017 13:55:34 -0700 Subject: [PATCH 0113/1347] Remove debug logs --- src/vs/workbench/parts/terminal/node/terminalProcess.ts | 6 ------ 1 file changed, 6 deletions(-) diff --git a/src/vs/workbench/parts/terminal/node/terminalProcess.ts b/src/vs/workbench/parts/terminal/node/terminalProcess.ts index 12642b21a41..3a2b00a4a70 100644 --- a/src/vs/workbench/parts/terminal/node/terminalProcess.ts +++ b/src/vs/workbench/parts/terminal/node/terminalProcess.ts @@ -3,14 +3,10 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import * as fs from 'fs'; -fs.writeFileSync('/home/daniel/testing-terminal-1', 'foo'); - import * as os from 'os'; import * as path from 'path'; import * as ptyJs from 'node-pty'; -fs.writeFileSync('/home/daniel/testing-terminal-2', 'foo'); // The pty process needs to be run in its own child process to get around maxing out CPU on Mac, // see https://github.com/electron/electron/issues/38 var shellName: string; @@ -47,10 +43,8 @@ if (cols && rows) { options.rows = parseInt(rows, 10); } -fs.writeFileSync('/home/daniel/testing-terminal-3', 'foo'); var ptyProcess = ptyJs.fork(shell, args, options); -fs.writeFileSync('/home/daniel/testing-terminal-4', 'foo'); var closeTimeout; var exitCode; -- GitLab From 64e1c20856ca08c8b754d0675692e70c7ea2edf0 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Tue, 23 May 2017 21:00:41 +0200 Subject: [PATCH 0114/1347] Kimbie builtin theme has dark curly braces. Fixes #27121 --- .../theme-kimbie-dark/themes/kimbie-dark-color-theme.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/theme-kimbie-dark/themes/kimbie-dark-color-theme.json b/extensions/theme-kimbie-dark/themes/kimbie-dark-color-theme.json index 2d5e0fadb31..7de6b3fd42e 100644 --- a/extensions/theme-kimbie-dark/themes/kimbie-dark-color-theme.json +++ b/extensions/theme-kimbie-dark/themes/kimbie-dark-color-theme.json @@ -369,7 +369,7 @@ "variable.interpolation" ], "settings": { - "foreground": "#18401e" + "foreground": "#088649" } }, { -- GitLab From e1e5bf41b35614c0c536878db951af70eb9c7d56 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Wed, 24 May 2017 22:56:13 +0200 Subject: [PATCH 0115/1347] Allow decorations to use theme colors. For #26974 --- src/vs/base/browser/dom.ts | 5 +- .../browser/services/codeEditorServiceImpl.ts | 480 +++++++++--------- .../browser/standalone/standaloneServices.ts | 5 +- .../overviewRuler/decorationsOverviewRuler.ts | 15 +- src/vs/editor/common/editorCommon.ts | 38 +- .../common/model/textModelWithDecorations.ts | 6 +- .../services/decorationRenderOptions.test.ts | 84 ++- src/vs/monaco.d.ts | 16 +- src/vs/platform/theme/common/themeService.ts | 6 +- src/vs/vscode.d.ts | 32 +- src/vs/workbench/api/node/extHost.api.impl.ts | 1 + src/vs/workbench/api/node/extHostTypes.ts | 7 + .../workbench/test/workbenchTestServices.ts | 36 +- 13 files changed, 442 insertions(+), 289 deletions(-) diff --git a/src/vs/base/browser/dom.ts b/src/vs/base/browser/dom.ts index 21698e938db..228550b57af 100644 --- a/src/vs/base/browser/dom.ts +++ b/src/vs/base/browser/dom.ts @@ -710,7 +710,7 @@ export function createCSSRule(selector: string, cssText: string, style: HTMLStyl return; } - (style.sheet).insertRule(selector + '{' + cssText + '}', 0); + (style.sheet).insertRule(selector + '{' + cssText + '}', 0); } export function getCSSRule(selector: string, style: HTMLStyleElement = sharedStyle): any { @@ -739,8 +739,7 @@ export function removeCSSRulesContainingSelector(ruleName: string, style = share let toDelete: number[] = []; for (let i = 0; i < rules.length; i++) { let rule = rules[i]; - let normalizedSelectorText = rule.selectorText.replace(/::/gi, ':'); - if (normalizedSelectorText.indexOf(ruleName) !== -1) { + if (rule.selectorText.indexOf(ruleName) !== -1) { toDelete.push(i); } } diff --git a/src/vs/editor/browser/services/codeEditorServiceImpl.ts b/src/vs/editor/browser/services/codeEditorServiceImpl.ts index fa45f009cf8..703e6e4f0ee 100644 --- a/src/vs/editor/browser/services/codeEditorServiceImpl.ts +++ b/src/vs/editor/browser/services/codeEditorServiceImpl.ts @@ -4,36 +4,43 @@ *--------------------------------------------------------------------------------------------*/ 'use strict'; -import * as objects from 'vs/base/common/objects'; -import { parse, stringify } from 'vs/base/common/marshalling'; import * as strings from 'vs/base/common/strings'; import URI from 'vs/base/common/uri'; import * as dom from 'vs/base/browser/dom'; import { IDecorationRenderOptions, IModelDecorationOptions, IModelDecorationOverviewRulerOptions, IThemeDecorationRenderOptions, - IContentDecorationRenderOptions, OverviewRulerLane, TrackedRangeStickiness + IContentDecorationRenderOptions, OverviewRulerLane, TrackedRangeStickiness, ThemeColor, isThemeColor } from 'vs/editor/common/editorCommon'; import { AbstractCodeEditorService } from 'vs/editor/common/services/abstractCodeEditorService'; -import { IDisposable, toDisposable } from 'vs/base/common/lifecycle'; +import { IDisposable, dispose as disposeAll } from 'vs/base/common/lifecycle'; +import { IThemeService, ITheme } from 'vs/platform/theme/common/themeService'; export class CodeEditorServiceImpl extends AbstractCodeEditorService { private _styleSheet: HTMLStyleElement; private _decorationOptionProviders: { [key: string]: IModelDecorationOptionsProvider }; + private _themeService: IThemeService; - constructor(styleSheet = dom.createStyleSheet()) { + constructor( @IThemeService themeService: IThemeService, styleSheet = dom.createStyleSheet()) { super(); this._styleSheet = styleSheet; this._decorationOptionProviders = Object.create(null); + this._themeService = themeService; } public registerDecorationType(key: string, options: IDecorationRenderOptions, parentTypeKey?: string): void { let provider = this._decorationOptionProviders[key]; if (!provider) { + let providerArgs: ProviderArguments = { + styleSheet: this._styleSheet, + key: key, + parentTypeKey: parentTypeKey, + options: options + }; if (!parentTypeKey) { - provider = new DecorationTypeOptionsProvider(this._styleSheet, key, options); + provider = new DecorationTypeOptionsProvider(this._themeService, providerArgs); } else { - provider = new DecorationSubTypeOptionsProvider(this._styleSheet, key, parentTypeKey, options); + provider = new DecorationSubTypeOptionsProvider(this._themeService, providerArgs); } this._decorationOptionProviders[key] = provider; } @@ -71,67 +78,52 @@ class DecorationSubTypeOptionsProvider implements IModelDecorationOptionsProvide public refCount: number; - private _disposable: IDisposable; private _parentTypeKey: string; - private _beforeContentClassName: string; - private _afterContentClassName: string; + private _beforeContentRules: DecorationCSSRules; + private _afterContentRules: DecorationCSSRules; - constructor(styleSheet: HTMLStyleElement, key: string, parentTypeKey: string, options: IDecorationRenderOptions) { - this._parentTypeKey = parentTypeKey; + constructor(themeService: IThemeService, providerArgs: ProviderArguments) { + this._parentTypeKey = providerArgs.parentTypeKey; this.refCount = 0; - let themedOpts = getThemedRenderOptions(options); - - this._beforeContentClassName = DecorationRenderHelper.createCSSRules( - styleSheet, - key, - parentTypeKey, - ModelDecorationCSSRuleType.BeforeContentClassName, - { - light: DecorationRenderHelper.getCSSTextForModelDecorationContentClassName(themedOpts.light.before), - dark: DecorationRenderHelper.getCSSTextForModelDecorationContentClassName(themedOpts.dark.before) - } - ); - - this._afterContentClassName = DecorationRenderHelper.createCSSRules( - styleSheet, - key, - parentTypeKey, - ModelDecorationCSSRuleType.AfterContentClassName, - { - light: DecorationRenderHelper.getCSSTextForModelDecorationContentClassName(themedOpts.light.after), - dark: DecorationRenderHelper.getCSSTextForModelDecorationContentClassName(themedOpts.dark.after) - } - ); - if (this._beforeContentClassName || this._afterContentClassName) { - this._disposable = toDisposable(() => { - dom.removeCSSRulesContainingSelector(CSSNameHelper.getDeletionSubstring(key), styleSheet); - }); - } + this._beforeContentRules = new DecorationCSSRules(ModelDecorationCSSRuleType.BeforeContentClassName, providerArgs, themeService); + this._afterContentRules = new DecorationCSSRules(ModelDecorationCSSRuleType.AfterContentClassName, providerArgs, themeService); } public getOptions(codeEditorService: AbstractCodeEditorService, writable: boolean): IModelDecorationOptions { let options = codeEditorService.resolveDecorationOptions(this._parentTypeKey, true); - if (this._beforeContentClassName) { - options.beforeContentClassName = this._beforeContentClassName; + if (this._beforeContentRules) { + options.beforeContentClassName = this._beforeContentRules.className; } - if (this._afterContentClassName) { - options.afterContentClassName = this._afterContentClassName; + if (this._afterContentRules) { + options.afterContentClassName = this._afterContentRules.className; } return options; } public dispose(): void { - if (this._disposable) { - this._disposable.dispose(); - delete this._disposable; + if (this._beforeContentRules) { + this._beforeContentRules.dispose(); + this._beforeContentRules = null; + } + if (this._afterContentRules) { + this._afterContentRules.dispose(); + this._afterContentRules = null; } } } +interface ProviderArguments { + styleSheet: HTMLStyleElement; + key: string; + parentTypeKey?: string; + options: IDecorationRenderOptions; +} + + class DecorationTypeOptionsProvider implements IModelDecorationOptionsProvider { - private _disposable: IDisposable; + private _disposables: IDisposable[]; public refCount: number; public className: string; @@ -143,82 +135,40 @@ class DecorationTypeOptionsProvider implements IModelDecorationOptionsProvider { public overviewRuler: IModelDecorationOverviewRulerOptions; public stickiness: TrackedRangeStickiness; - constructor(styleSheet: HTMLStyleElement, key: string, options: IDecorationRenderOptions) { + constructor(themeService: IThemeService, providerArgs: ProviderArguments) { this.refCount = 0; + this._disposables = []; - let themedOpts = getThemedRenderOptions(options); - - this.className = DecorationRenderHelper.createCSSRules( - styleSheet, - key, - null, - ModelDecorationCSSRuleType.ClassName, - { - light: DecorationRenderHelper.getCSSTextForModelDecorationClassName(themedOpts.light), - dark: DecorationRenderHelper.getCSSTextForModelDecorationClassName(themedOpts.dark) - } - ); - - this.inlineClassName = DecorationRenderHelper.createCSSRules( - styleSheet, - key, - null, - ModelDecorationCSSRuleType.InlineClassName, - { - light: DecorationRenderHelper.getCSSTextForModelDecorationInlineClassName(themedOpts.light), - dark: DecorationRenderHelper.getCSSTextForModelDecorationInlineClassName(themedOpts.dark) - } - ); - - this.beforeContentClassName = DecorationRenderHelper.createCSSRules( - styleSheet, - key, - null, - ModelDecorationCSSRuleType.BeforeContentClassName, - { - light: DecorationRenderHelper.getCSSTextForModelDecorationContentClassName(themedOpts.light.before), - dark: DecorationRenderHelper.getCSSTextForModelDecorationContentClassName(themedOpts.dark.before) - } - ); - - this.afterContentClassName = DecorationRenderHelper.createCSSRules( - styleSheet, - key, - null, - ModelDecorationCSSRuleType.AfterContentClassName, - { - light: DecorationRenderHelper.getCSSTextForModelDecorationContentClassName(themedOpts.light.after), - dark: DecorationRenderHelper.getCSSTextForModelDecorationContentClassName(themedOpts.dark.after) - } - ); - - this.glyphMarginClassName = DecorationRenderHelper.createCSSRules( - styleSheet, - key, - null, - ModelDecorationCSSRuleType.GlyphMarginClassName, - { - light: DecorationRenderHelper.getCSSTextForModelDecorationGlyphMarginClassName(themedOpts.light), - dark: DecorationRenderHelper.getCSSTextForModelDecorationGlyphMarginClassName(themedOpts.dark) + let createCSSRules = (type: ModelDecorationCSSRuleType) => { + let rules = new DecorationCSSRules(type, providerArgs, themeService); + if (rules.hasContent) { + this._disposables.push(rules); + return rules.className; } - ); + return void 0; + }; + + this.className = createCSSRules(ModelDecorationCSSRuleType.ClassName); + this.inlineClassName = createCSSRules(ModelDecorationCSSRuleType.InlineClassName); + this.beforeContentClassName = createCSSRules(ModelDecorationCSSRuleType.BeforeContentClassName); + this.beforeContentClassName = createCSSRules(ModelDecorationCSSRuleType.AfterContentClassName); + this.glyphMarginClassName = createCSSRules(ModelDecorationCSSRuleType.GlyphMarginClassName); + let options = providerArgs.options; this.isWholeLine = Boolean(options.isWholeLine); + let lightOverviewRulerColor = options.light && options.light.overviewRulerColor || options.overviewRulerColor; + let darkOverviewRulerColor = options.dark && options.dark.overviewRulerColor || options.overviewRulerColor; if ( - typeof themedOpts.light.overviewRulerColor !== 'undefined' - || typeof themedOpts.dark.overviewRulerColor !== 'undefined' + typeof lightOverviewRulerColor !== 'undefined' + || typeof darkOverviewRulerColor !== 'undefined' ) { this.overviewRuler = { - color: themedOpts.light.overviewRulerColor || themedOpts.dark.overviewRulerColor, - darkColor: themedOpts.dark.overviewRulerColor || themedOpts.light.overviewRulerColor, + color: lightOverviewRulerColor || darkOverviewRulerColor, + darkColor: darkOverviewRulerColor || lightOverviewRulerColor, position: options.overviewRulerLane || OverviewRulerLane.Center }; } - - this._disposable = toDisposable(() => { - dom.removeCSSRulesContainingSelector(CSSNameHelper.getDeletionSubstring(key), styleSheet); - }); } public getOptions(codeEditorService: AbstractCodeEditorService, writable: boolean): IModelDecorationOptions { @@ -238,51 +188,162 @@ class DecorationTypeOptionsProvider implements IModelDecorationOptionsProvider { } public dispose(): void { - if (this._disposable) { - this._disposable.dispose(); - delete this._disposable; - } + this._disposables = disposeAll(this._disposables); } } -class DecorationRenderHelper { - private static _CSS_MAP = { - color: 'color:{0} !important;', - backgroundColor: 'background-color:{0};', - - outline: 'outline:{0};', - outlineColor: 'outline-color:{0};', - outlineStyle: 'outline-style:{0};', - outlineWidth: 'outline-width:{0};', - - border: 'border:{0};', - borderColor: 'border-color:{0};', - borderRadius: 'border-radius:{0};', - borderSpacing: 'border-spacing:{0};', - borderStyle: 'border-style:{0};', - borderWidth: 'border-width:{0};', - - textDecoration: 'text-decoration:{0};', - cursor: 'cursor:{0};', - letterSpacing: 'letter-spacing:{0};', - - gutterIconPath: 'background:url(\'{0}\') center center no-repeat;', - gutterIconSize: 'background-size:{0};', - - contentText: 'content:\'{0}\';', - contentIconPath: 'content:url(\'{0}\');', - margin: 'margin:{0};', - width: 'width:{0};', - height: 'height:{0};' - }; + +const _CSS_MAP = { + color: 'color:{0} !important;', + backgroundColor: 'background-color:{0};', + + outline: 'outline:{0};', + outlineColor: 'outline-color:{0};', + outlineStyle: 'outline-style:{0};', + outlineWidth: 'outline-width:{0};', + + border: 'border:{0};', + borderColor: 'border-color:{0};', + borderRadius: 'border-radius:{0};', + borderSpacing: 'border-spacing:{0};', + borderStyle: 'border-style:{0};', + borderWidth: 'border-width:{0};', + + textDecoration: 'text-decoration:{0};', + cursor: 'cursor:{0};', + letterSpacing: 'letter-spacing:{0};', + + gutterIconPath: 'background:url(\'{0}\') center center no-repeat;', + gutterIconSize: 'background-size:{0};', + + contentText: 'content:\'{0}\';', + contentIconPath: 'content:url(\'{0}\');', + margin: 'margin:{0};', + width: 'width:{0};', + height: 'height:{0};' +}; + + +class DecorationCSSRules { + + private _theme: ITheme; + private _className: string; + private _unThemedSelector: string; + private _hasContent: boolean; + private _ruleType: ModelDecorationCSSRuleType; + private _themeListener: IDisposable; + private _providerArgs: ProviderArguments; + private _usesThemeColors: boolean; + + public constructor(ruleType: ModelDecorationCSSRuleType, providerArgs: ProviderArguments, themeService: IThemeService) { + this._theme = themeService.getTheme(); + this._ruleType = ruleType; + this._providerArgs = providerArgs; + this._usesThemeColors = false; + this._hasContent = false; + + let className = CSSNameHelper.getClassName(this._providerArgs.key, ruleType); + if (this._providerArgs.parentTypeKey) { + className = className + ' ' + CSSNameHelper.getClassName(this._providerArgs.parentTypeKey, ruleType); + } + this._className = className; + + this._unThemedSelector = CSSNameHelper.getSelector(this._providerArgs.key, this._providerArgs.parentTypeKey, ruleType); + + this._buildCSS(); + + if (this._usesThemeColors) { + this._themeListener = themeService.onThemeChange(theme => { + this._theme = themeService.getTheme(); + this._removeCSS(); + this._buildCSS(); + }); + } + } + + public dispose() { + if (this._hasContent) { + this._removeCSS(); + this._hasContent = false; + } + if (this._themeListener) { + this._themeListener.dispose(); + this._themeListener = null; + } + } + + public get hasContent(): boolean { + return this._hasContent; + } + + public get className(): string { + return this._className; + } + + private _buildCSS(): void { + let options = this._providerArgs.options; + let unthemedCSS, lightCSS, darkCSS: string; + switch (this._ruleType) { + case ModelDecorationCSSRuleType.ClassName: + unthemedCSS = this.getCSSTextForModelDecorationClassName(options); + lightCSS = this.getCSSTextForModelDecorationClassName(options.light); + darkCSS = this.getCSSTextForModelDecorationClassName(options.dark); + break; + case ModelDecorationCSSRuleType.InlineClassName: + unthemedCSS = this.getCSSTextForModelDecorationInlineClassName(options); + lightCSS = this.getCSSTextForModelDecorationInlineClassName(options.light); + darkCSS = this.getCSSTextForModelDecorationInlineClassName(options.dark); + break; + case ModelDecorationCSSRuleType.GlyphMarginClassName: + unthemedCSS = this.getCSSTextForModelDecorationGlyphMarginClassName(options); + lightCSS = this.getCSSTextForModelDecorationGlyphMarginClassName(options.light); + darkCSS = this.getCSSTextForModelDecorationGlyphMarginClassName(options.dark); + break; + case ModelDecorationCSSRuleType.BeforeContentClassName: + unthemedCSS = this.getCSSTextForModelDecorationContentClassName(options.before); + lightCSS = this.getCSSTextForModelDecorationContentClassName(options.light && options.light.before); + darkCSS = this.getCSSTextForModelDecorationContentClassName(options.dark && options.dark.before); + break; + case ModelDecorationCSSRuleType.AfterContentClassName: + unthemedCSS = this.getCSSTextForModelDecorationContentClassName(options.after); + lightCSS = this.getCSSTextForModelDecorationContentClassName(options.light && options.light.after); + darkCSS = this.getCSSTextForModelDecorationContentClassName(options.dark && options.dark.after); + break; + default: + throw new Error('Unknown rule type: ' + this._ruleType); + } + let sheet = this._providerArgs.styleSheet.sheet; + + let hasContent = false; + if (unthemedCSS.length > 0) { + sheet.insertRule(`${this._unThemedSelector} {${unthemedCSS}}`); + hasContent = true; + } + if (lightCSS.length > 0) { + sheet.insertRule(`.vs${this._unThemedSelector} {${lightCSS}}`); + hasContent = true; + } + if (darkCSS.length > 0) { + sheet.insertRule(`.vs-dark${this._unThemedSelector}, .hc-black${this._unThemedSelector} {${darkCSS}}`); + hasContent = true; + } + this._hasContent = hasContent; + } + + private _removeCSS(): void { + dom.removeCSSRulesContainingSelector(this._unThemedSelector, this._providerArgs.styleSheet); + } /** * Build the CSS for decorations styled via `className`. */ - public static getCSSTextForModelDecorationClassName(opts: IThemeDecorationRenderOptions): string { + private getCSSTextForModelDecorationClassName(opts: IThemeDecorationRenderOptions): string { + if (!opts) { + return ''; + } let cssTextArr: string[] = []; - DecorationRenderHelper.collectCSSText(opts, ['backgroundColor', 'outline', 'outlineColor', 'outlineStyle', 'outlineWidth'], cssTextArr); - DecorationRenderHelper.collectBorderSettingsCSSText(opts, cssTextArr); + this.collectCSSText(opts, ['backgroundColor', 'outline', 'outlineColor', 'outlineStyle', 'outlineWidth'], cssTextArr); + this.collectBorderSettingsCSSText(opts, cssTextArr); return cssTextArr.join(''); } @@ -290,33 +351,39 @@ class DecorationRenderHelper { /** * Build the CSS for decorations styled via `inlineClassName`. */ - public static getCSSTextForModelDecorationInlineClassName(opts: IThemeDecorationRenderOptions): string { + private getCSSTextForModelDecorationInlineClassName(opts: IThemeDecorationRenderOptions): string { + if (!opts) { + return ''; + } let cssTextArr: string[] = []; - DecorationRenderHelper.collectCSSText(opts, ['textDecoration', 'cursor', 'color', 'letterSpacing'], cssTextArr); + this.collectCSSText(opts, ['textDecoration', 'cursor', 'color', 'letterSpacing'], cssTextArr); return cssTextArr.join(''); } /** * Build the CSS for decorations styled before or after content. */ - public static getCSSTextForModelDecorationContentClassName(opts: IContentDecorationRenderOptions): string { + private getCSSTextForModelDecorationContentClassName(opts: IContentDecorationRenderOptions): string { + if (!opts) { + return ''; + } let cssTextArr: string[] = []; if (typeof opts !== 'undefined') { - DecorationRenderHelper.collectBorderSettingsCSSText(opts, cssTextArr); + this.collectBorderSettingsCSSText(opts, cssTextArr); if (typeof opts.contentIconPath === 'string') { - cssTextArr.push(strings.format(this._CSS_MAP.contentIconPath, URI.file(opts.contentIconPath).toString().replace(/'/g, '%27'))); + cssTextArr.push(strings.format(_CSS_MAP.contentIconPath, URI.file(opts.contentIconPath).toString().replace(/'/g, '%27'))); } else if (opts.contentIconPath instanceof URI) { - cssTextArr.push(strings.format(this._CSS_MAP.contentIconPath, opts.contentIconPath.toString(true).replace(/'/g, '%27'))); + cssTextArr.push(strings.format(_CSS_MAP.contentIconPath, opts.contentIconPath.toString(true).replace(/'/g, '%27'))); } if (typeof opts.contentText === 'string') { const truncated = opts.contentText.match(/^.*$/m)[0]; // only take first line const escaped = truncated.replace(/['\\]/g, '\\$&'); - cssTextArr.push(strings.format(this._CSS_MAP.contentText, escaped)); + cssTextArr.push(strings.format(_CSS_MAP.contentText, escaped)); } - DecorationRenderHelper.collectCSSText(opts, ['textDecoration', 'color', 'backgroundColor', 'margin'], cssTextArr); - if (DecorationRenderHelper.collectCSSText(opts, ['width', 'height'], cssTextArr)) { + this.collectCSSText(opts, ['textDecoration', 'color', 'backgroundColor', 'margin'], cssTextArr); + if (this.collectCSSText(opts, ['width', 'height'], cssTextArr)) { cssTextArr.push('display:inline-block;'); } } @@ -327,17 +394,20 @@ class DecorationRenderHelper { /** * Build the CSS for decorations styled via `glpyhMarginClassName`. */ - public static getCSSTextForModelDecorationGlyphMarginClassName(opts: IThemeDecorationRenderOptions): string { + private getCSSTextForModelDecorationGlyphMarginClassName(opts: IThemeDecorationRenderOptions): string { + if (!opts) { + return ''; + } let cssTextArr = []; if (typeof opts.gutterIconPath !== 'undefined') { if (typeof opts.gutterIconPath === 'string') { - cssTextArr.push(strings.format(this._CSS_MAP.gutterIconPath, URI.file(opts.gutterIconPath).toString())); + cssTextArr.push(strings.format(_CSS_MAP.gutterIconPath, URI.file(opts.gutterIconPath).toString())); } else { - cssTextArr.push(strings.format(this._CSS_MAP.gutterIconPath, opts.gutterIconPath.toString(true).replace(/'/g, '%27'))); + cssTextArr.push(strings.format(_CSS_MAP.gutterIconPath, opts.gutterIconPath.toString(true).replace(/'/g, '%27'))); } if (typeof opts.gutterIconSize !== 'undefined') { - cssTextArr.push(strings.format(this._CSS_MAP.gutterIconSize, opts.gutterIconSize)); + cssTextArr.push(strings.format(_CSS_MAP.gutterIconSize, opts.gutterIconSize)); } } @@ -346,59 +416,38 @@ class DecorationRenderHelper { private static border_rules = ['border', 'borderRadius', 'borderColor', 'borderSpacing', 'borderStyle', 'borderWidth']; - public static collectBorderSettingsCSSText(opts: any, cssTextArr: string[]): boolean { - if (DecorationRenderHelper.collectCSSText(opts, DecorationRenderHelper.border_rules, cssTextArr)) { + private collectBorderSettingsCSSText(opts: any, cssTextArr: string[]): boolean { + if (this.collectCSSText(opts, DecorationCSSRules.border_rules, cssTextArr)) { cssTextArr.push(strings.format('box-sizing: border-box;')); return true; } return false; } - private static collectCSSText(opts: any, properties: string[], cssTextArr: string[]): boolean { + private collectCSSText(opts: any, properties: string[], cssTextArr: string[]): boolean { let lenBefore = cssTextArr.length; for (let property of properties) { - if (typeof opts[property] !== 'undefined') { - cssTextArr.push(strings.format(this._CSS_MAP[property], opts[property])); + let value = this.resolveValue(opts[property]); + if (typeof value === 'string') { + cssTextArr.push(strings.format(_CSS_MAP[property], value)); } } return cssTextArr.length !== lenBefore; } - /** - * Create CSS rules for `cssTexts` with the generated class names from `ruleType` - */ - public static createCSSRules(styleSheet: HTMLStyleElement, key: string, parentKey: string, ruleType: ModelDecorationCSSRuleType, cssTexts: { light: string, dark: string }): string { - function createCSSSelector(themeType: ThemeType, cssText: string) { - let selector = CSSNameHelper.getSelector(themeType, key, parentKey, ruleType); - dom.createCSSRule(selector, cssText, styleSheet); - } - - let hasContent = false; - if (cssTexts.light.length > 0) { - createCSSSelector(ThemeType.Light, cssTexts.light); - hasContent = true; - } - if (cssTexts.dark.length > 0) { - createCSSSelector(ThemeType.Dark, cssTexts.dark); - createCSSSelector(ThemeType.HighContrastBlack, cssTexts.dark); - hasContent = true; - } - if (hasContent) { - let className = CSSNameHelper.getClassName(key, ruleType); - if (parentKey) { - className = className + ' ' + CSSNameHelper.getClassName(parentKey, ruleType); + private resolveValue(value: string | ThemeColor): string { + if (isThemeColor(value)) { + this._usesThemeColors = true; + let color = this._theme.getColor(value.id); + if (color) { + return color.toString(); } - return className; + return void 0; } - return void 0; + return value; } } -const enum ThemeType { - Light = 0, - Dark = 1, - HighContrastBlack = 2 -} const enum ModelDecorationCSSRuleType { ClassName = 0, InlineClassName = 1, @@ -409,22 +458,12 @@ const enum ModelDecorationCSSRuleType { class CSSNameHelper { - private static _getSelectorPrefixOf(theme: ThemeType): string { - if (theme === ThemeType.Light) { - return '.monaco-editor.vs'; - } - if (theme === ThemeType.Dark) { - return '.monaco-editor.vs-dark'; - } - return '.monaco-editor.hc-black'; - } - public static getClassName(key: string, type: ModelDecorationCSSRuleType): string { return 'ced-' + key + '-' + type; } - public static getSelector(themeType: ThemeType, key: string, parentKey: string, ruleType: ModelDecorationCSSRuleType): string { - let selector = this._getSelectorPrefixOf(themeType) + ' .' + this.getClassName(key, ruleType); + public static getSelector(key: string, parentKey: string, ruleType: ModelDecorationCSSRuleType): string { + let selector = '.monaco-editor .' + this.getClassName(key, ruleType); if (parentKey) { selector = selector + '.' + this.getClassName(parentKey, ruleType); } @@ -435,27 +474,4 @@ class CSSNameHelper { } return selector; } - - public static getDeletionSubstring(key: string): string { - return '.ced-' + key + '-'; - } -} - -// ---- Normalize decoration render options per theme -function getThemedRenderOptions(opts: { light?: T, dark?: T }): { light?: T, dark?: T } { - // TODO@alex,joh - not really how/what deep clone is being used - // for here but it will break the URI TODO@martin - - // let light = objects.deepClone(opts); - let light = parse(stringify(opts)); - objects.mixin(light, opts.light); - - // let dark = objects.deepClone(opts); - let dark = parse(stringify(opts)); - objects.mixin(dark, opts.dark); - - return { - light: light, - dark: dark - }; } diff --git a/src/vs/editor/browser/standalone/standaloneServices.ts b/src/vs/editor/browser/standalone/standaloneServices.ts index 1ce2c0d30b3..550b5294605 100644 --- a/src/vs/editor/browser/standalone/standaloneServices.ts +++ b/src/vs/editor/browser/standalone/standaloneServices.ts @@ -133,13 +133,14 @@ export module StaticServices { export const editorWorkerService = define(IEditorWorkerService, (o) => new EditorWorkerServiceImpl(modelService.get(o), configurationService.get(o), modeService.get(o))); - export const codeEditorService = define(ICodeEditorService, () => new CodeEditorServiceImpl()); + export const standaloneThemeService = define(IStandaloneThemeService, () => new StandaloneThemeServiceImpl()); + + export const codeEditorService = define(ICodeEditorService, (o) => new CodeEditorServiceImpl(standaloneThemeService.get(o))); export const progressService = define(IProgressService, () => new SimpleProgressService()); export const storageService = define(IStorageService, () => NullStorageService); - export const standaloneThemeService = define(IStandaloneThemeService, () => new StandaloneThemeServiceImpl()); } export class DynamicStandaloneServices extends Disposable { diff --git a/src/vs/editor/browser/viewParts/overviewRuler/decorationsOverviewRuler.ts b/src/vs/editor/browser/viewParts/overviewRuler/decorationsOverviewRuler.ts index 6f9f3e03b55..46c6d71d941 100644 --- a/src/vs/editor/browser/viewParts/overviewRuler/decorationsOverviewRuler.ts +++ b/src/vs/editor/browser/viewParts/overviewRuler/decorationsOverviewRuler.ts @@ -15,6 +15,7 @@ import { IDisposable } from 'vs/base/common/lifecycle'; import * as viewEvents from 'vs/editor/common/view/viewEvents'; import { OverviewRulerZone } from 'vs/editor/common/view/overviewZoneManager'; import { editorOverviewRulerBorder, editorCursor } from 'vs/editor/common/view/editorColorRegistry'; +import { Color } from 'vs/base/common/color'; export class DecorationsOverviewRuler extends ViewPart { @@ -186,15 +187,23 @@ export class DecorationsOverviewRuler extends ViewPart { dec.range.endLineNumber, overviewRuler.position, 0, - overviewRuler.color, - overviewRuler.darkColor, - overviewRuler.hcColor + this.resolveRulerColor(overviewRuler.color), + this.resolveRulerColor(overviewRuler.darkColor), + this.resolveRulerColor(overviewRuler.hcColor) )); } return zones; } + private resolveRulerColor(color: string | editorCommon.ThemeColor): string { + if (editorCommon.isThemeColor(color)) { + let c = this._context.theme.getColor(color.id) || Color.transparent; + return c.toString(); + } + return color; + } + private _createZonesFromCursors(): OverviewRulerZone[] { let zones: OverviewRulerZone[] = []; diff --git a/src/vs/editor/common/editorCommon.ts b/src/vs/editor/common/editorCommon.ts index 9a0674a5f28..058ea7e3653 100644 --- a/src/vs/editor/common/editorCommon.ts +++ b/src/vs/editor/common/editorCommon.ts @@ -41,19 +41,19 @@ export enum OverviewRulerLane { export interface IModelDecorationOverviewRulerOptions { /** * CSS color to render in the overview ruler. - * e.g.: rgba(100, 100, 100, 0.5) + * e.g.: rgba(100, 100, 100, 0.5) or a color from the color registry */ - color: string; + color: string | ThemeColor; /** * CSS color to render in the overview ruler. - * e.g.: rgba(100, 100, 100, 0.5) + * e.g.: rgba(100, 100, 100, 0.5) or a color from the color registry */ - darkColor: string; + darkColor: string | ThemeColor; /** * CSS color to render in the overview ruler. - * e.g.: rgba(100, 100, 100, 0.5) + * e.g.: rgba(100, 100, 100, 0.5) or a color from the color registry */ - hcColor?: string; + hcColor?: string | ThemeColor; /** * The position in the overview ruler. */ @@ -1621,19 +1621,30 @@ export interface IEditorContribution { restoreViewState?(state: any): void; } +export interface ThemeColor { + id: string; +} + +/** + * @internal + */ +export function isThemeColor(o): o is ThemeColor { + return o && typeof o.id === 'string'; +} + /** * @internal */ export interface IThemeDecorationRenderOptions { - backgroundColor?: string; + backgroundColor?: string | ThemeColor; outline?: string; - outlineColor?: string; + outlineColor?: string | ThemeColor; outlineStyle?: string; outlineWidth?: string; border?: string; - borderColor?: string; + borderColor?: string | ThemeColor; borderRadius?: string; borderSpacing?: string; borderStyle?: string; @@ -1641,13 +1652,13 @@ export interface IThemeDecorationRenderOptions { textDecoration?: string; cursor?: string; - color?: string; + color?: string | ThemeColor; letterSpacing?: string; gutterIconPath?: string | URI; gutterIconSize?: string; - overviewRulerColor?: string; + overviewRulerColor?: string | ThemeColor; before?: IContentDecorationRenderOptions; after?: IContentDecorationRenderOptions; @@ -1661,9 +1672,10 @@ export interface IContentDecorationRenderOptions { contentIconPath?: string | URI; border?: string; + borderColor?: string | ThemeColor; textDecoration?: string; - color?: string; - backgroundColor?: string; + color?: string | ThemeColor; + backgroundColor?: string | ThemeColor; margin?: string; width?: string; diff --git a/src/vs/editor/common/model/textModelWithDecorations.ts b/src/vs/editor/common/model/textModelWithDecorations.ts index 3e36eeedda6..84380b69ef3 100644 --- a/src/vs/editor/common/model/textModelWithDecorations.ts +++ b/src/vs/editor/common/model/textModelWithDecorations.ts @@ -840,9 +840,9 @@ function cleanClassName(className: string): string { } export class ModelDecorationOverviewRulerOptions implements editorCommon.IModelDecorationOverviewRulerOptions { - readonly color: string; - readonly darkColor: string; - readonly hcColor: string; + readonly color: string | editorCommon.ThemeColor; + readonly darkColor: string | editorCommon.ThemeColor; + readonly hcColor: string | editorCommon.ThemeColor; readonly position: editorCommon.OverviewRulerLane; constructor(options: editorCommon.IModelDecorationOverviewRulerOptions) { diff --git a/src/vs/editor/test/browser/services/decorationRenderOptions.test.ts b/src/vs/editor/test/browser/services/decorationRenderOptions.test.ts index 2dbd09ac1c0..d68266803a7 100644 --- a/src/vs/editor/test/browser/services/decorationRenderOptions.test.ts +++ b/src/vs/editor/test/browser/services/decorationRenderOptions.test.ts @@ -9,6 +9,9 @@ import URI from 'vs/base/common/uri'; import * as dom from 'vs/base/browser/dom'; import { CodeEditorServiceImpl } from 'vs/editor/browser/services/codeEditorServiceImpl'; import { IDecorationRenderOptions } from 'vs/editor/common/editorCommon'; +import { TestThemeService, TestTheme } from 'vs/workbench/test/workbenchTestServices'; + +const themeServiceMock = new TestThemeService(); suite('Decoration Render Options', () => { var options: IDecorationRenderOptions = { @@ -18,12 +21,12 @@ suite('Decoration Render Options', () => { borderColor: 'yellow' }; test('register and resolve decoration type', () => { - var s = new CodeEditorServiceImpl(); + var s = new CodeEditorServiceImpl(themeServiceMock); s.registerDecorationType('example', options); assert.notEqual(s.resolveDecorationOptions('example', false), undefined); }); test('remove decoration type', () => { - var s = new CodeEditorServiceImpl(); + var s = new CodeEditorServiceImpl(themeServiceMock); s.registerDecorationType('example', options); assert.notEqual(s.resolveDecorationOptions('example', false), undefined); s.removeDecorationType('example'); @@ -39,7 +42,7 @@ suite('Decoration Render Options', () => { test('css properties', () => { var styleSheet = dom.createStyleSheet(); - var s = new CodeEditorServiceImpl(styleSheet); + var s = new CodeEditorServiceImpl(themeServiceMock, styleSheet); s.registerDecorationType('example', options); var sheet = readStyleSheet(styleSheet); assert( @@ -50,11 +53,76 @@ suite('Decoration Render Options', () => { assert(sheet.indexOf('background-color: red;') > 0); }); + test('theme color', () => { + var options: IDecorationRenderOptions = { + backgroundColor: { id: 'editorBackground' }, + borderColor: { id: 'editorBorder' }, + }; + var colors: { [key: string]: string } = { + editorBackground: '#FF0000' + }; + + var styleSheet = dom.createStyleSheet(); + let themeService = new TestThemeService(new TestTheme(colors)); + var s = new CodeEditorServiceImpl(themeService, styleSheet); + s.registerDecorationType('example', options); + var sheet = readStyleSheet(styleSheet); + assert.equal(sheet, '.monaco-editor .ced-example-0 { background-color: rgb(255, 0, 0); }'); + + colors = { + editorBackground: '#EE0000', + editorBorder: '#00FFFF' + }; + themeService.setTheme(new TestTheme(colors)); + sheet = readStyleSheet(styleSheet); + assert.equal(sheet, '.monaco-editor .ced-example-0 { background-color: rgb(238, 0, 0); border-color: rgb(0, 255, 255); box-sizing: border-box; }'); + + s.removeDecorationType('example'); + sheet = readStyleSheet(styleSheet); + assert.equal(sheet, ''); + + }); + + test('theme overrides', () => { + var options: IDecorationRenderOptions = { + color: { id: 'editorBackground' }, + light: { + color: '#FF00FF' + }, + dark: { + color: '#000000', + after: { + color: { id: 'infoForeground' } + } + } + }; + var colors: { [key: string]: string } = { + editorBackground: '#FF0000', + infoForeground: '#444444' + }; + + var styleSheet = dom.createStyleSheet(); + let themeService = new TestThemeService(new TestTheme(colors)); + var s = new CodeEditorServiceImpl(themeService, styleSheet); + s.registerDecorationType('example', options); + var sheet = readStyleSheet(styleSheet); + let expected = + '.vs-dark.monaco-editor .ced-example-4::after, .hc-black.monaco-editor .ced-example-4::after { color: rgb(68, 68, 68) !important; }\n' + + '.vs-dark.monaco-editor .ced-example-1, .hc-black.monaco-editor .ced-example-1 { color: rgb(0, 0, 0) !important; }\n' + + '.vs.monaco-editor .ced-example-1 { color: rgb(255, 0, 255) !important; }\n' + + '.monaco-editor .ced-example-1 { color: rgb(255, 0, 0) !important; }'; + assert.equal(sheet, expected); + + s.removeDecorationType('example'); + sheet = readStyleSheet(styleSheet); + assert.equal(sheet, ''); + }); + test('css properties, gutterIconPaths', () => { var styleSheet = dom.createStyleSheet(); // unix file path (used as string) - var s = new CodeEditorServiceImpl(styleSheet); + var s = new CodeEditorServiceImpl(themeServiceMock, styleSheet); s.registerDecorationType('example', { gutterIconPath: '/Users/foo/bar.png' }); var sheet = readStyleSheet(styleSheet);//.innerHTML || styleSheet.sheet.toString(); assert( @@ -63,7 +131,7 @@ suite('Decoration Render Options', () => { ); // windows file path (used as string) - s = new CodeEditorServiceImpl(styleSheet); + s = new CodeEditorServiceImpl(themeServiceMock, styleSheet); s.registerDecorationType('example', { gutterIconPath: 'c:\\files\\miles\\more.png' }); sheet = readStyleSheet(styleSheet); // TODO@Alex test fails @@ -73,7 +141,7 @@ suite('Decoration Render Options', () => { // ); // URI, only minimal encoding - s = new CodeEditorServiceImpl(styleSheet); + s = new CodeEditorServiceImpl(themeServiceMock, styleSheet); s.registerDecorationType('example', { gutterIconPath: URI.parse('data:image/svg+xml;base64,PHN2ZyB4b+') }); sheet = readStyleSheet(styleSheet); assert( @@ -82,7 +150,7 @@ suite('Decoration Render Options', () => { ); // single quote must always be escaped/encoded - s = new CodeEditorServiceImpl(styleSheet); + s = new CodeEditorServiceImpl(themeServiceMock, styleSheet); s.registerDecorationType('example', { gutterIconPath: '/Users/foo/b\'ar.png' }); sheet = readStyleSheet(styleSheet); assert( @@ -90,7 +158,7 @@ suite('Decoration Render Options', () => { || sheet.indexOf('background: url("file:///Users/foo/b%27ar.png") center center no-repeat;') > 0 ); - s = new CodeEditorServiceImpl(styleSheet); + s = new CodeEditorServiceImpl(themeServiceMock, styleSheet); s.registerDecorationType('example', { gutterIconPath: URI.parse('http://test/pa\'th') }); sheet = readStyleSheet(styleSheet); assert( diff --git a/src/vs/monaco.d.ts b/src/vs/monaco.d.ts index cee64b0706f..707cb1047fa 100644 --- a/src/vs/monaco.d.ts +++ b/src/vs/monaco.d.ts @@ -1068,19 +1068,19 @@ declare module monaco.editor { export interface IModelDecorationOverviewRulerOptions { /** * CSS color to render in the overview ruler. - * e.g.: rgba(100, 100, 100, 0.5) + * e.g.: rgba(100, 100, 100, 0.5) or a color from the color registry */ - color: string; + color: string | ThemeColor; /** * CSS color to render in the overview ruler. - * e.g.: rgba(100, 100, 100, 0.5) + * e.g.: rgba(100, 100, 100, 0.5) or a color from the color registry */ - darkColor: string; + darkColor: string | ThemeColor; /** * CSS color to render in the overview ruler. - * e.g.: rgba(100, 100, 100, 0.5) + * e.g.: rgba(100, 100, 100, 0.5) or a color from the color registry */ - hcColor?: string; + hcColor?: string | ThemeColor; /** * The position in the overview ruler. */ @@ -2158,6 +2158,10 @@ declare module monaco.editor { restoreViewState?(state: any): void; } + export interface ThemeColor { + id: string; + } + export interface ICommonCodeEditor extends IEditor { /** * An event emitted when the content of the current model has changed. diff --git a/src/vs/platform/theme/common/themeService.ts b/src/vs/platform/theme/common/themeService.ts index 64e028e6215..10305538863 100644 --- a/src/vs/platform/theme/common/themeService.ts +++ b/src/vs/platform/theme/common/themeService.ts @@ -14,9 +14,9 @@ import Event, { Emitter } from 'vs/base/common/event'; export let IThemeService = createDecorator('themeService'); // base themes -export const DARK = 'dark'; -export const LIGHT = 'light'; -export const HIGH_CONTRAST = 'hc'; +export const DARK: ThemeType = 'dark'; +export const LIGHT: ThemeType = 'light'; +export const HIGH_CONTRAST: ThemeType = 'hc'; export type ThemeType = 'light' | 'dark' | 'hc'; export function getThemeTypeSelector(type: ThemeType): string { diff --git a/src/vs/vscode.d.ts b/src/vs/vscode.d.ts index 190042afeea..4850740fec1 100644 --- a/src/vs/vscode.d.ts +++ b/src/vs/vscode.d.ts @@ -721,14 +721,28 @@ declare module 'vscode' { preview?: boolean; } + /** + * A reference to one of the workbench colors as defined in https://code.visualstudio.com/docs/getstarted/theme-color-reference. + * Using a theme color is preferred over a custom color as it gives theme authors and users the possibility to change the color. + */ + export class ThemeColor { + + /** + * Creates a reference to a theme color. + * @param id of the color. The available colors are listed in https://code.visualstudio.com/docs/getstarted/theme-color-reference. + */ + constructor(id: string); + } + /** * Represents theme specific rendering styles for a [text editor decoration](#TextEditorDecorationType). */ export interface ThemableDecorationRenderOptions { /** * Background color of the decoration. Use rgba() and define transparent background colors to play well with other decorations. + * Alternativly a color from the color registry an be [referenced](#ColorIdentifier). */ - backgroundColor?: string; + backgroundColor?: string | ThemeColor; /** * CSS styling property that will be applied to text enclosed by a decoration. @@ -739,7 +753,7 @@ declare module 'vscode' { * CSS styling property that will be applied to text enclosed by a decoration. * Better use 'outline' for setting one or more of the individual outline properties. */ - outlineColor?: string; + outlineColor?: string | ThemeColor; /** * CSS styling property that will be applied to text enclosed by a decoration. @@ -762,7 +776,7 @@ declare module 'vscode' { * CSS styling property that will be applied to text enclosed by a decoration. * Better use 'border' for setting one or more of the individual border properties. */ - borderColor?: string; + borderColor?: string | ThemeColor; /** * CSS styling property that will be applied to text enclosed by a decoration. @@ -801,7 +815,7 @@ declare module 'vscode' { /** * CSS styling property that will be applied to text enclosed by a decoration. */ - color?: string; + color?: string | ThemeColor; /** * CSS styling property that will be applied to text enclosed by a decoration. @@ -823,7 +837,7 @@ declare module 'vscode' { /** * The color of the decoration in the overview ruler. Use rgba() and define transparent colors to play well with other decorations. */ - overviewRulerColor?: string; + overviewRulerColor?: string | ThemeColor; /** * Defines the rendering options of the attachment that is inserted before the decorated text @@ -850,6 +864,10 @@ declare module 'vscode' { * CSS styling property that will be applied to the decoration attachment. */ border?: string; + /** + * CSS styling property that will be applied to text enclosed by a decoration. + */ + borderColor?: string | ThemeColor; /** * CSS styling property that will be applied to the decoration attachment. */ @@ -857,11 +875,11 @@ declare module 'vscode' { /** * CSS styling property that will be applied to the decoration attachment. */ - color?: string; + color?: string | ThemeColor; /** * CSS styling property that will be applied to the decoration attachment. */ - backgroundColor?: string; + backgroundColor?: string | ThemeColor; /** * CSS styling property that will be applied to the decoration attachment. */ diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index 6aebd241572..eb5b38f2391 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -534,6 +534,7 @@ export function createApiFactory( WorkspaceEdit: extHostTypes.WorkspaceEdit, ProgressLocation: extHostTypes.ProgressLocation, TreeItemCollapsibleState: extHostTypes.TreeItemCollapsibleState, + ThemeColor: extHostTypes.ThemeColor, // functions FileLocationKind: extHostTypes.FileLocationKind, ApplyToKind: extHostTypes.ApplyToKind, diff --git a/src/vs/workbench/api/node/extHostTypes.ts b/src/vs/workbench/api/node/extHostTypes.ts index 1c10cc26251..20b0d2a1aff 100644 --- a/src/vs/workbench/api/node/extHostTypes.ts +++ b/src/vs/workbench/api/node/extHostTypes.ts @@ -1270,3 +1270,10 @@ export enum TreeItemCollapsibleState { Collapsed = 1, Expanded = 2 } + +export class ThemeColor { + id: string; + constructor(id: string) { + this.id = id; + } +} \ No newline at end of file diff --git a/src/vs/workbench/test/workbenchTestServices.ts b/src/vs/workbench/test/workbenchTestServices.ts index bc6e0f5e11d..899b03112be 100644 --- a/src/vs/workbench/test/workbenchTestServices.ts +++ b/src/vs/workbench/test/workbenchTestServices.ts @@ -50,8 +50,7 @@ import { IWindowsService, IWindowService } from 'vs/platform/windows/common/wind import { TestWorkspace } from 'vs/platform/workspace/test/common/testWorkspace'; import { RawTextSource, IRawTextSource } from 'vs/editor/common/model/textSource'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; -import { IThemeService, ITheme, IThemingParticipant, ThemeType } from 'vs/platform/theme/common/themeService'; -import { IDisposable } from 'vs/base/common/lifecycle'; +import { IThemeService, ITheme, DARK } from 'vs/platform/theme/common/themeService'; import { Color } from 'vs/base/common/color'; import { isLinux } from 'vs/base/common/platform'; @@ -1000,10 +999,16 @@ export class TestWindowsService implements IWindowsService { } export class TestTheme implements ITheme { - type: ThemeType; + + constructor(private colors: { [id: string]: string; } = {}, public type = DARK) { + } getColor(color: string, useDefault?: boolean): Color { - throw new Error('Method not implemented.'); + let value = this.colors[color]; + if (value) { + return Color.fromHex(value); + } + return void 0; } defines(color: string): boolean { @@ -1011,17 +1016,30 @@ export class TestTheme implements ITheme { } } -const testTheme = new TestTheme(); - export class TestThemeService implements IThemeService { _serviceBrand: any; + _theme: ITheme; + _onThemeChange = new Emitter(); + + constructor(theme = new TestTheme()) { + this._theme = theme; + } getTheme(): ITheme { - return testTheme; + return this._theme; + } + + setTheme(theme: ITheme) { + this._theme = theme; + this.fireThemeChange(); + } + + fireThemeChange() { + this._onThemeChange.fire(this._theme); } - onThemeChange(participant: IThemingParticipant): IDisposable { - return { dispose: () => { } }; + public get onThemeChange(): Event { + return this._onThemeChange.event; } } -- GitLab From 55de700961a17cb052553a4dada4d45aa80fec7a Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Wed, 24 May 2017 13:59:47 -0700 Subject: [PATCH 0116/1347] Fix #25422 - also search external files --- src/vs/workbench/services/search/node/ripgrepTextSearch.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/services/search/node/ripgrepTextSearch.ts b/src/vs/workbench/services/search/node/ripgrepTextSearch.ts index 50cd95218a9..829406f52fe 100644 --- a/src/vs/workbench/services/search/node/ripgrepTextSearch.ts +++ b/src/vs/workbench/services/search/node/ripgrepTextSearch.ts @@ -225,7 +225,7 @@ export class RipgrepParser extends EventEmitter { this.onResult(); } - this.fileMatch = new FileMatch(path.join(this.rootFolder, r[1])); + this.fileMatch = new FileMatch(path.resolve(this.rootFolder, r[1])); } else { // Line is empty (or malformed) } @@ -461,6 +461,8 @@ function getRgArgs(config: IRawSearch): { args: string[], siblingClauses: glob.I args.push('./'); } + args.push(...config.extraFiles); + return { args, siblingClauses }; } -- GitLab From fab8dabc0dbfcef191291b9648fda27d9c2afdcf Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Wed, 24 May 2017 14:00:58 -0700 Subject: [PATCH 0117/1347] Clean up var name --- src/vs/workbench/parts/terminal/node/terminalProcess.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/terminal/node/terminalProcess.ts b/src/vs/workbench/parts/terminal/node/terminalProcess.ts index 3a2b00a4a70..ab1589b4dcf 100644 --- a/src/vs/workbench/parts/terminal/node/terminalProcess.ts +++ b/src/vs/workbench/parts/terminal/node/terminalProcess.ts @@ -5,7 +5,7 @@ import * as os from 'os'; import * as path from 'path'; -import * as ptyJs from 'node-pty'; +import * as pty from 'node-pty'; // The pty process needs to be run in its own child process to get around maxing out CPU on Mac, // see https://github.com/electron/electron/issues/38 @@ -43,7 +43,7 @@ if (cols && rows) { options.rows = parseInt(rows, 10); } -var ptyProcess = ptyJs.fork(shell, args, options); +var ptyProcess = pty.fork(shell, args, options); var closeTimeout; var exitCode; -- GitLab From 3c52e0de45d83440a06a042a28b611bd3478a50a Mon Sep 17 00:00:00 2001 From: rebornix Date: Wed, 10 May 2017 14:57:21 -0700 Subject: [PATCH 0118/1347] draft version --- .../contrib/find/browser/findWidget.css | 34 ++++++++---- .../editor/contrib/find/browser/findWidget.ts | 53 +++++++++++++++++-- 2 files changed, 73 insertions(+), 14 deletions(-) diff --git a/src/vs/editor/contrib/find/browser/findWidget.css b/src/vs/editor/contrib/find/browser/findWidget.css index 74d52635a45..f5b3f333204 100644 --- a/src/vs/editor/contrib/find/browser/findWidget.css +++ b/src/vs/editor/contrib/find/browser/findWidget.css @@ -51,7 +51,9 @@ height: 64px; /* find input height + replace input height */ } .monaco-editor .find-widget.replaceToggled > .replace-part { - display: inline-block; + display: flex; + display: -webkit-flex; + align-items: center; } .monaco-editor .find-widget.visible, @@ -81,6 +83,9 @@ .monaco-editor .find-widget > .replace-part { margin: 4px 0 0 17px; font-size: 12px; + display: flex; + display: -webkit-flex; + align-items: center; } .monaco-editor .find-widget > .find-part .monaco-inputbox, @@ -95,8 +100,9 @@ } .monaco-editor .find-widget .monaco-findInput { - display: inline-block; vertical-align: middle; + display: flex; + flex:1; } .monaco-editor .find-widget .matchesCount { @@ -111,6 +117,7 @@ } .monaco-editor .find-widget .button { + min-width: 20px; width: 20px; height: 20px; display: inline-block; @@ -227,7 +234,8 @@ } .monaco-editor .find-widget > .replace-part > .replace-input { - display: inline-block; + display: flex; + flex:1; vertical-align: middle; } @@ -242,12 +250,9 @@ } /* NARROW (SMALLER THAN REDUCED) */ -.monaco-editor .find-widget.narrow-find-widget > .find-part .monaco-findInput, -.monaco-editor .find-widget.narrow-find-widget > .replace-part .replace-input { - width: 171px !important; -} -.monaco-editor .find-widget.narrow-find-widget > .find-part .monaco-inputbox > .wrapper > .input { - width: 105px !important; +.monaco-editor .find-widget.narrow-find-widget > .find-part, +.monaco-editor .find-widget.narrow-find-widget > .replace-part { + width: 240px !important; } /* COLLAPSED (SMALLER THAN NARROW) */ @@ -258,10 +263,14 @@ .monaco-editor .find-widget.collapsed-find-widget > .find-part .monaco-findInput .controls { display:none; } +.monaco-editor .find-widget.collapsed-find-widget > .find-part, +.monaco-editor .find-widget.collapsed-find-widget > .replace-part { + max-width: 94px !important; +} .monaco-editor .find-widget.collapsed-find-widget > .find-part .monaco-findInput, .monaco-editor .find-widget.collapsed-find-widget > .replace-part .replace-input, .monaco-editor .find-widget.collapsed-find-widget > .find-part .monaco-inputbox > .wrapper > .input { - width: 71px !important; + max-width: 71px !important; } .monaco-editor .findMatch { @@ -275,6 +284,11 @@ animation-name: inherit !important; } +.monaco-editor .find-widget .monaco-sash { + background: grey; + margin-left: -4px; +} + .monaco-editor.hc-black .find-widget .previous, .monaco-editor.vs-dark .find-widget .previous { background-image: url('images/previous-inverse.svg'); diff --git a/src/vs/editor/contrib/find/browser/findWidget.ts b/src/vs/editor/contrib/find/browser/findWidget.ts index 145453e625e..a36edf38b05 100644 --- a/src/vs/editor/contrib/find/browser/findWidget.ts +++ b/src/vs/editor/contrib/find/browser/findWidget.ts @@ -16,6 +16,7 @@ import { IContextViewProvider } from 'vs/base/browser/ui/contextview/contextview import { FindInput, IFindInputStyles } from 'vs/base/browser/ui/findinput/findInput'; import { IMessage as InputBoxMessage, InputBox } from 'vs/base/browser/ui/inputbox/inputBox'; import { Widget } from 'vs/base/browser/ui/widget'; +import { Sash, IHorizontalSashLayoutProvider, ISashEvent } from 'vs/base/browser/ui/sash/sash'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { ICodeEditor, IOverlayWidget, IOverlayWidgetPosition, IViewZone, OverlayWidgetPositionPreference } from 'vs/editor/browser/editorBrowser'; import { FIND_IDS, MATCHES_LIMIT } from 'vs/editor/contrib/find/common/findModel'; @@ -68,7 +69,9 @@ export class FindWidgetViewZone implements IViewZone { } } -export class FindWidget extends Widget implements IOverlayWidget { + +export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSashLayoutProvider { + private static ID = 'editor.contrib.findWidget'; private static PART_WIDTH = 275; @@ -104,6 +107,8 @@ export class FindWidget extends Widget implements IOverlayWidget { private _viewZone: FindWidgetViewZone; private _viewZoneId: number; + private _resizeSash: Sash; + constructor( codeEditor: ICodeEditor, controller: IFindController, @@ -126,6 +131,26 @@ export class FindWidget extends Widget implements IOverlayWidget { this._register(this._state.addChangeListener((e) => this._onStateChanged(e))); this._buildDomNode(); + this._resizeSash = new Sash(this._domNode, this, { orientation: 0}); + let data: { startX: number; }; + let originalWidth = 411; + this._register(this._resizeSash.addListener('start', (e: ISashEvent) => { + data = { + startX: e.startX, + }; + originalWidth = dom.getTotalWidth(this._domNode); + })); + + this._register(this._resizeSash.addListener('end', () => { + data = undefined; + })); + + this._register(this._resizeSash.addListener('change', (evt: ISashEvent) => { + if (data) { + this._domNode.style.width = `${originalWidth + data.startX - evt.currentX}px`; + this._findInput.setWidth(FindWidget.FIND_INPUT_AREA_WIDTH + Math.max(0, data.startX - evt.currentX)); + } + })); this._updateButtons(); let checkEditorWidth = () => { @@ -134,18 +159,27 @@ export class FindWidget extends Widget implements IOverlayWidget { let collapsedFindWidget = false; let reducedFindWidget = false; let narrowFindWidget = false; - if (WIDGET_FIXED_WIDTH + 28 >= editorWidth + 50) { + let widgetWidth = Math.max(411, dom.getTotalWidth(this._domNode)) - 69; + if (widgetWidth + 28 >= editorWidth + 50) { collapsedFindWidget = true; } - if (WIDGET_FIXED_WIDTH + 28 >= editorWidth) { + if (widgetWidth + 28 >= editorWidth) { narrowFindWidget = true; } - if (WIDGET_FIXED_WIDTH + MAX_MATCHES_COUNT_WIDTH + 28 + minimapWidth >= editorWidth) { + if (widgetWidth + MAX_MATCHES_COUNT_WIDTH + 28 + minimapWidth >= editorWidth) { reducedFindWidget = true; } dom.toggleClass(this._domNode, 'collapsed-find-widget', collapsedFindWidget); dom.toggleClass(this._domNode, 'reduced-find-widget', reducedFindWidget); dom.toggleClass(this._domNode, 'narrow-find-widget', narrowFindWidget); + if (collapsedFindWidget) { + this._domNode.style.maxWidth = '111px'; + } else if (narrowFindWidget) { + this._domNode.style.maxWidth = '257px'; + } else { + this._domNode.style.maxWidth = `${editorWidth - 28 - minimapWidth - 15}px`; + } + }; checkEditorWidth(); @@ -552,6 +586,17 @@ export class FindWidget extends Widget implements IOverlayWidget { } } + // ----- sash + public getHorizontalSashTop(sash: Sash): number { + return 0; + } + public getHorizontalSashLeft?(sash: Sash): number { + return 0; + } + public getHorizontalSashWidth?(sash: Sash): number { + return 500; + } + // ----- initialization private _keybindingLabelFor(actionId: string): string { -- GitLab From df32b3f94785e2c0ecaa26063bac9ff3b0076eb2 Mon Sep 17 00:00:00 2001 From: rebornix Date: Thu, 11 May 2017 15:11:28 -0700 Subject: [PATCH 0119/1347] Flex Box --- .../contrib/find/browser/findWidget.css | 27 +++++++++++++------ .../editor/contrib/find/browser/findWidget.ts | 25 +++++++++++++---- 2 files changed, 39 insertions(+), 13 deletions(-) diff --git a/src/vs/editor/contrib/find/browser/findWidget.css b/src/vs/editor/contrib/find/browser/findWidget.css index f5b3f333204..e974c6a83c7 100644 --- a/src/vs/editor/contrib/find/browser/findWidget.css +++ b/src/vs/editor/contrib/find/browser/findWidget.css @@ -93,6 +93,10 @@ height: 25px; } +.monaco-editor .find-widget > .find-part .monaco-inputbox > .wrapper > .input { + width: 100% !important; + padding-right: 66px; +} .monaco-editor .find-widget > .find-part .monaco-inputbox > .wrapper > .input, .monaco-editor .find-widget > .replace-part .monaco-inputbox > .wrapper > .input { padding-top: 2px; @@ -106,7 +110,9 @@ } .monaco-editor .find-widget .matchesCount { - display: inline-block; + display: flex; + display: -webkit-flex; + flex: initial; margin: 0 1px 0 3px; padding: 2px 2px 0 2px; height: 25px; @@ -120,8 +126,9 @@ min-width: 20px; width: 20px; height: 20px; - display: inline-block; - vertical-align: middle; + display: flex; + display: -webkit-flex; + flex: initial; margin-left: 3px; background-position: center center; background-repeat: no-repeat; @@ -250,10 +257,10 @@ } /* NARROW (SMALLER THAN REDUCED) */ -.monaco-editor .find-widget.narrow-find-widget > .find-part, +/*.monaco-editor .find-widget.narrow-find-widget > .find-part, .monaco-editor .find-widget.narrow-find-widget > .replace-part { width: 240px !important; -} +}*/ /* COLLAPSED (SMALLER THAN NARROW) */ .monaco-editor .find-widget.collapsed-find-widget .button.previous, @@ -263,7 +270,11 @@ .monaco-editor .find-widget.collapsed-find-widget > .find-part .monaco-findInput .controls { display:none; } -.monaco-editor .find-widget.collapsed-find-widget > .find-part, + +.monaco-editor .find-widget.collapsed-find-widget > .find-part .monaco-inputbox > .wrapper > .input { + padding-right: 0px; +} +/*.monaco-editor .find-widget.collapsed-find-widget > .find-part, .monaco-editor .find-widget.collapsed-find-widget > .replace-part { max-width: 94px !important; } @@ -271,7 +282,7 @@ .monaco-editor .find-widget.collapsed-find-widget > .replace-part .replace-input, .monaco-editor .find-widget.collapsed-find-widget > .find-part .monaco-inputbox > .wrapper > .input { max-width: 71px !important; -} +}*/ .monaco-editor .findMatch { -webkit-animation-duration: 0; @@ -286,7 +297,7 @@ .monaco-editor .find-widget .monaco-sash { background: grey; - margin-left: -4px; + margin-left: -4px; } .monaco-editor.hc-black .find-widget .previous, diff --git a/src/vs/editor/contrib/find/browser/findWidget.ts b/src/vs/editor/contrib/find/browser/findWidget.ts index a36edf38b05..297d4fe6155 100644 --- a/src/vs/editor/contrib/find/browser/findWidget.ts +++ b/src/vs/editor/contrib/find/browser/findWidget.ts @@ -50,7 +50,6 @@ const NLS_MATCHES_LOCATION = nls.localize('label.matchesLocation', "{0} of {1}") const NLS_NO_RESULTS = nls.localize('label.noResults', "No Results"); let MAX_MATCHES_COUNT_WIDTH = 69; -const WIDGET_FIXED_WIDTH = 411 - 69; export class FindWidgetViewZone implements IViewZone { @@ -131,7 +130,7 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas this._register(this._state.addChangeListener((e) => this._onStateChanged(e))); this._buildDomNode(); - this._resizeSash = new Sash(this._domNode, this, { orientation: 0}); + this._resizeSash = new Sash(this._domNode, this, { orientation: 0 }); let data: { startX: number; }; let originalWidth = 411; this._register(this._resizeSash.addListener('start', (e: ISashEvent) => { @@ -147,8 +146,24 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas this._register(this._resizeSash.addListener('change', (evt: ISashEvent) => { if (data) { - this._domNode.style.width = `${originalWidth + data.startX - evt.currentX}px`; - this._findInput.setWidth(FindWidget.FIND_INPUT_AREA_WIDTH + Math.max(0, data.startX - evt.currentX)); + let reducedFindWidget = false; + let narrowFindWidget = false; + let collapsedFindWidget = false; + let width = originalWidth + data.startX - evt.currentX; + if (width < 411) { + reducedFindWidget = true; + } + if (width < 411 - 69) { + narrowFindWidget = true; + } + if (width < 265) { + collapsedFindWidget = true; + } + dom.toggleClass(this._domNode, 'collapsed-find-widget', collapsedFindWidget); + dom.toggleClass(this._domNode, 'narrow-find-widget', narrowFindWidget); + dom.toggleClass(this._domNode, 'reduced-find-widget', reducedFindWidget); + this._domNode.style.width = `${width}px`; + // this._findInput.setWidth(FindWidget.FIND_INPUT_AREA_WIDTH + Math.max(0, data.startX - evt.currentX)); } })); this._updateButtons(); @@ -170,8 +185,8 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas reducedFindWidget = true; } dom.toggleClass(this._domNode, 'collapsed-find-widget', collapsedFindWidget); - dom.toggleClass(this._domNode, 'reduced-find-widget', reducedFindWidget); dom.toggleClass(this._domNode, 'narrow-find-widget', narrowFindWidget); + dom.toggleClass(this._domNode, 'reduced-find-widget', reducedFindWidget); if (collapsedFindWidget) { this._domNode.style.maxWidth = '111px'; } else if (narrowFindWidget) { -- GitLab From 0ca5f1c77ac526476f6f13309a45a3ff885a5bc0 Mon Sep 17 00:00:00 2001 From: rebornix Date: Wed, 24 May 2017 14:44:40 -0700 Subject: [PATCH 0120/1347] make input box responsive when widget or editor resizes --- .../contrib/find/browser/findWidget.css | 30 ++-- .../editor/contrib/find/browser/findWidget.ts | 155 ++++++++++-------- 2 files changed, 95 insertions(+), 90 deletions(-) diff --git a/src/vs/editor/contrib/find/browser/findWidget.css b/src/vs/editor/contrib/find/browser/findWidget.css index e974c6a83c7..0fdd4694549 100644 --- a/src/vs/editor/contrib/find/browser/findWidget.css +++ b/src/vs/editor/contrib/find/browser/findWidget.css @@ -106,6 +106,7 @@ .monaco-editor .find-widget .monaco-findInput { vertical-align: middle; display: flex; + display: -webkit-flex; flex:1; } @@ -242,12 +243,9 @@ .monaco-editor .find-widget > .replace-part > .replace-input { display: flex; - flex:1; + display: -webkit-flex; vertical-align: middle; -} - -.monaco-editor .find-widget > .replace-part > .replace-input > .monaco-inputbox { - width: 100%; + width: auto !important; } /* REDUCED */ @@ -257,12 +255,15 @@ } /* NARROW (SMALLER THAN REDUCED) */ -/*.monaco-editor .find-widget.narrow-find-widget > .find-part, -.monaco-editor .find-widget.narrow-find-widget > .replace-part { - width: 240px !important; -}*/ +.monaco-editor .find-widget.narrow-find-widget { + max-width: 257px !important; +} /* COLLAPSED (SMALLER THAN NARROW) */ +.monaco-editor .find-widget.collapsed-find-widget { + max-width: 111px !important; +} + .monaco-editor .find-widget.collapsed-find-widget .button.previous, .monaco-editor .find-widget.collapsed-find-widget .button.next, .monaco-editor .find-widget.collapsed-find-widget .button.replace, @@ -274,15 +275,6 @@ .monaco-editor .find-widget.collapsed-find-widget > .find-part .monaco-inputbox > .wrapper > .input { padding-right: 0px; } -/*.monaco-editor .find-widget.collapsed-find-widget > .find-part, -.monaco-editor .find-widget.collapsed-find-widget > .replace-part { - max-width: 94px !important; -} -.monaco-editor .find-widget.collapsed-find-widget > .find-part .monaco-findInput, -.monaco-editor .find-widget.collapsed-find-widget > .replace-part .replace-input, -.monaco-editor .find-widget.collapsed-find-widget > .find-part .monaco-inputbox > .wrapper > .input { - max-width: 71px !important; -}*/ .monaco-editor .findMatch { -webkit-animation-duration: 0; @@ -296,7 +288,7 @@ } .monaco-editor .find-widget .monaco-sash { - background: grey; + width: 2px !important; margin-left: -4px; } diff --git a/src/vs/editor/contrib/find/browser/findWidget.ts b/src/vs/editor/contrib/find/browser/findWidget.ts index 297d4fe6155..74454a278ec 100644 --- a/src/vs/editor/contrib/find/browser/findWidget.ts +++ b/src/vs/editor/contrib/find/browser/findWidget.ts @@ -16,7 +16,7 @@ import { IContextViewProvider } from 'vs/base/browser/ui/contextview/contextview import { FindInput, IFindInputStyles } from 'vs/base/browser/ui/findinput/findInput'; import { IMessage as InputBoxMessage, InputBox } from 'vs/base/browser/ui/inputbox/inputBox'; import { Widget } from 'vs/base/browser/ui/widget'; -import { Sash, IHorizontalSashLayoutProvider, ISashEvent } from 'vs/base/browser/ui/sash/sash'; +import { Sash, IHorizontalSashLayoutProvider, ISashEvent, Orientation } from 'vs/base/browser/ui/sash/sash'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { ICodeEditor, IOverlayWidget, IOverlayWidgetPosition, IViewZone, OverlayWidgetPositionPreference } from 'vs/editor/browser/editorBrowser'; import { FIND_IDS, MATCHES_LIMIT } from 'vs/editor/contrib/find/common/findModel'; @@ -29,6 +29,7 @@ import { Color } from 'vs/base/common/color'; import { IConfigurationChangedEvent } from 'vs/editor/common/config/editorOptions'; import { editorFindRangeHighlight, editorFindMatch, editorFindMatchHighlight, activeContrastBorder, contrastBorder, inputBackground, editorWidgetBackground, inputActiveOptionBorder, widgetShadow, inputForeground, inputBorder, inputValidationInfoBackground, inputValidationInfoBorder, inputValidationWarningBackground, inputValidationWarningBorder, inputValidationErrorBackground, inputValidationErrorBorder, errorForeground } from 'vs/platform/theme/common/colorRegistry'; + export interface IFindController { replace(): void; replaceAll(): void; @@ -49,10 +50,19 @@ const NLS_MATCHES_COUNT_LIMIT_TITLE = nls.localize('title.matchesCountLimit', "O const NLS_MATCHES_LOCATION = nls.localize('label.matchesLocation', "{0} of {1}"); const NLS_NO_RESULTS = nls.localize('label.noResults', "No Results"); +const FIND_WIDGET_INITIAL_WIDTH = 411; +const PART_WIDTH = 275; +const FIND_INPUT_AREA_WIDTH = PART_WIDTH - 54; +const REPLACE_INPUT_AREA_WIDTH = FIND_INPUT_AREA_WIDTH; + let MAX_MATCHES_COUNT_WIDTH = 69; +let FIND_ALL_CONTROLS_WIDTH = 17/** Find Input margin-left */ + (MAX_MATCHES_COUNT_WIDTH + 3 + 1) /** Match Results */ + 23 /** Button */ * 4 + 2/** sash */; + +const FIND_INPUT_AREA_HEIGHT = 34; // The height of Find Widget when Replace Input is not visible. +const FIND_REPLACE_AREA_HEIGHT = 64; // The height of Find Widget when Replace Input is visible. -export class FindWidgetViewZone implements IViewZone { +export class FindWidgetViewZone implements IViewZone { public afterLineNumber: number; public heightInPx: number; public suppressMouseDown: boolean; @@ -61,24 +71,15 @@ export class FindWidgetViewZone implements IViewZone { constructor(afterLineNumber: number) { this.afterLineNumber = afterLineNumber; - this.heightInPx = 34; + this.heightInPx = FIND_INPUT_AREA_HEIGHT; this.suppressMouseDown = false; this.domNode = document.createElement('div'); this.domNode.className = 'dock-find-viewzone'; } } - export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSashLayoutProvider { - - - private static ID = 'editor.contrib.findWidget'; - private static PART_WIDTH = 275; - private static FIND_INPUT_AREA_WIDTH = FindWidget.PART_WIDTH - 54; - private static REPLACE_INPUT_AREA_WIDTH = FindWidget.FIND_INPUT_AREA_WIDTH; - private static FIND_INPUT_AREA_HEIGHT = 34; // The height of Find Widget when Replace Input is not visible. - private static FIND_REPLACE_AREA_HEIGHT = 64; // The height of Find Widget when Replace Input is visible. - + private static ID = 'editor.contrib.findWidget';; private _codeEditor: ICodeEditor; private _state: FindReplaceState; private _controller: IFindController; @@ -128,44 +129,7 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas this._isReplaceVisible = false; this._register(this._state.addChangeListener((e) => this._onStateChanged(e))); - this._buildDomNode(); - this._resizeSash = new Sash(this._domNode, this, { orientation: 0 }); - let data: { startX: number; }; - let originalWidth = 411; - this._register(this._resizeSash.addListener('start', (e: ISashEvent) => { - data = { - startX: e.startX, - }; - originalWidth = dom.getTotalWidth(this._domNode); - })); - - this._register(this._resizeSash.addListener('end', () => { - data = undefined; - })); - - this._register(this._resizeSash.addListener('change', (evt: ISashEvent) => { - if (data) { - let reducedFindWidget = false; - let narrowFindWidget = false; - let collapsedFindWidget = false; - let width = originalWidth + data.startX - evt.currentX; - if (width < 411) { - reducedFindWidget = true; - } - if (width < 411 - 69) { - narrowFindWidget = true; - } - if (width < 265) { - collapsedFindWidget = true; - } - dom.toggleClass(this._domNode, 'collapsed-find-widget', collapsedFindWidget); - dom.toggleClass(this._domNode, 'narrow-find-widget', narrowFindWidget); - dom.toggleClass(this._domNode, 'reduced-find-widget', reducedFindWidget); - this._domNode.style.width = `${width}px`; - // this._findInput.setWidth(FindWidget.FIND_INPUT_AREA_WIDTH + Math.max(0, data.startX - evt.currentX)); - } - })); this._updateButtons(); let checkEditorWidth = () => { @@ -174,27 +138,38 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas let collapsedFindWidget = false; let reducedFindWidget = false; let narrowFindWidget = false; - let widgetWidth = Math.max(411, dom.getTotalWidth(this._domNode)) - 69; - if (widgetWidth + 28 >= editorWidth + 50) { - collapsedFindWidget = true; + let widgetWidth = dom.getTotalWidth(this._domNode); + + if (widgetWidth > FIND_WIDGET_INITIAL_WIDTH) { + // as the widget is resized by users, we may need to change the max width of the widget as the editor width changes. + this._domNode.style.maxWidth = `${editorWidth - 28 - minimapWidth - 15}px`; + this._replaceInputBox.inputElement.style.width = `${dom.getTotalWidth(this._findInput.inputBox.inputElement)}px`; + return; + } + + if (FIND_WIDGET_INITIAL_WIDTH + 28 + minimapWidth >= editorWidth) { + reducedFindWidget = true; } - if (widgetWidth + 28 >= editorWidth) { + if (FIND_WIDGET_INITIAL_WIDTH + 28 + minimapWidth - MAX_MATCHES_COUNT_WIDTH >= editorWidth) { narrowFindWidget = true; } - if (widgetWidth + MAX_MATCHES_COUNT_WIDTH + 28 + minimapWidth >= editorWidth) { - reducedFindWidget = true; + if (FIND_WIDGET_INITIAL_WIDTH + 28 + minimapWidth - MAX_MATCHES_COUNT_WIDTH >= editorWidth + 50) { + collapsedFindWidget = true; } dom.toggleClass(this._domNode, 'collapsed-find-widget', collapsedFindWidget); dom.toggleClass(this._domNode, 'narrow-find-widget', narrowFindWidget); dom.toggleClass(this._domNode, 'reduced-find-widget', reducedFindWidget); - if (collapsedFindWidget) { - this._domNode.style.maxWidth = '111px'; - } else if (narrowFindWidget) { - this._domNode.style.maxWidth = '257px'; - } else { + + if (!narrowFindWidget && !collapsedFindWidget) { + // the minimal left offset of findwidget is 15px. this._domNode.style.maxWidth = `${editorWidth - 28 - minimapWidth - 15}px`; } + let findInputWidth = dom.getTotalWidth(this._findInput.inputBox.inputElement); + if (findInputWidth > 0) { + this._replaceInputBox.inputElement.style.width = `${findInputWidth}px`; + } + }; checkEditorWidth(); @@ -467,9 +442,9 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas this._codeEditor.changeViewZones((accessor) => { if (this._state.isReplaceRevealed) { - this._viewZone.heightInPx = FindWidget.FIND_REPLACE_AREA_HEIGHT; + this._viewZone.heightInPx = FIND_REPLACE_AREA_HEIGHT; } else { - this._viewZone.heightInPx = FindWidget.FIND_INPUT_AREA_HEIGHT; + this._viewZone.heightInPx = FIND_INPUT_AREA_HEIGHT; } this._viewZoneId = accessor.addZone(this._viewZone); @@ -483,19 +458,19 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas } this._codeEditor.changeViewZones((accessor) => { - let scrollAdjustment = FindWidget.FIND_INPUT_AREA_HEIGHT; + let scrollAdjustment = FIND_INPUT_AREA_HEIGHT; if (this._viewZoneId !== undefined) { if (this._state.isReplaceRevealed) { - this._viewZone.heightInPx = FindWidget.FIND_REPLACE_AREA_HEIGHT; - scrollAdjustment = FindWidget.FIND_REPLACE_AREA_HEIGHT - FindWidget.FIND_INPUT_AREA_HEIGHT; + this._viewZone.heightInPx = FIND_REPLACE_AREA_HEIGHT; + scrollAdjustment = FIND_REPLACE_AREA_HEIGHT - FIND_INPUT_AREA_HEIGHT; } else { - this._viewZone.heightInPx = FindWidget.FIND_INPUT_AREA_HEIGHT; - scrollAdjustment = FindWidget.FIND_INPUT_AREA_HEIGHT - FindWidget.FIND_REPLACE_AREA_HEIGHT; + this._viewZone.heightInPx = FIND_INPUT_AREA_HEIGHT; + scrollAdjustment = FIND_INPUT_AREA_HEIGHT - FIND_REPLACE_AREA_HEIGHT; } accessor.removeZone(this._viewZoneId); } else { - this._viewZone.heightInPx = FindWidget.FIND_INPUT_AREA_HEIGHT; + this._viewZone.heightInPx = FIND_INPUT_AREA_HEIGHT; } this._viewZoneId = accessor.addZone(this._viewZone); this._codeEditor.setScrollTop(this._codeEditor.getScrollTop() + scrollAdjustment); @@ -625,7 +600,7 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas private _buildFindPart(): HTMLElement { // Find input this._findInput = this._register(new FindInput(null, this._contextViewProvider, { - width: FindWidget.FIND_INPUT_AREA_WIDTH, + width: FIND_INPUT_AREA_WIDTH, label: NLS_FIND_INPUT_LABEL, placeholder: NLS_FIND_INPUT_PLACEHOLDER, appendCaseSensitiveLabel: this._keybindingLabelFor(FIND_IDS.ToggleCaseSensitiveCommand), @@ -751,7 +726,7 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas // Replace input let replaceInput = document.createElement('div'); replaceInput.className = 'replace-input'; - replaceInput.style.width = FindWidget.REPLACE_INPUT_AREA_WIDTH + 'px'; + replaceInput.style.width = REPLACE_INPUT_AREA_WIDTH + 'px'; this._replaceInputBox = this._register(new InputBox(replaceInput, null, { ariaLabel: NLS_REPLACE_INPUT_LABEL, placeholder: NLS_REPLACE_INPUT_PLACEHOLDER @@ -809,6 +784,9 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas className: 'toggle left', onTrigger: () => { this._state.change({ isReplaceRevealed: !this._isReplaceVisible }, false); + if (this._isReplaceVisible) { + this._replaceInputBox.width = this._findInput.inputBox.width; + } this._showViewZone(); }, onKeyDown: (e) => { } @@ -825,6 +803,36 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas this._domNode.appendChild(this._toggleReplaceBtn.domNode); this._domNode.appendChild(findPart); this._domNode.appendChild(replacePart); + + this._buildSash(); + } + + private _buildSash() { + this._resizeSash = new Sash(this._domNode, this, { orientation: Orientation.VERTICAL }); + let originalWidth = FIND_WIDGET_INITIAL_WIDTH; + + this._register(this._resizeSash.addListener('start', (e: ISashEvent) => { + originalWidth = dom.getTotalWidth(this._domNode); + })); + + this._register(this._resizeSash.addListener('change', (evt: ISashEvent) => { + let width = originalWidth + evt.startX - evt.currentX; + + if (width < FIND_WIDGET_INITIAL_WIDTH) { + // narrow down the find widget should be handled by CSS. + return; + } + + let inputBoxWidth = width - FIND_ALL_CONTROLS_WIDTH; + let maxWidth = parseFloat(dom.getComputedStyle(this._domNode).maxWidth) || 0; + if (width > maxWidth) { + return; + } + this._domNode.style.width = `${width}px`; + if (this._isReplaceVisible) { + this._replaceInputBox.width = inputBoxWidth; + } + })); } } @@ -1009,5 +1017,10 @@ registerThemingParticipant((theme, collector) => { if (error) { collector.addRule(`.monaco-editor .find-widget.no-results .matchesCount { color: ${error}; }`); } + + let border = theme.getColor('panel.border'); + if (border) { + collector.addRule(`.monaco-editor .find-widget .monaco-sash { background-color: ${border}; width: 2px !important; margin-left: -4px;}`); + } }); -- GitLab From 3ef1b64d4b49cd9f9b59bc7fafd95053baeab51f Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Wed, 24 May 2017 23:49:51 +0200 Subject: [PATCH 0121/1347] Allow extensions to use theme colors in status bar --- src/vs/platform/statusbar/common/statusbar.ts | 3 ++- src/vs/vscode.d.ts | 2 +- .../electron-browser/mainThreadStatusBar.ts | 3 ++- src/vs/workbench/api/node/extHost.protocol.ts | 2 +- src/vs/workbench/api/node/extHostStatusBar.ts | 8 ++++---- .../browser/parts/statusbar/statusbarPart.ts | 18 +++++++++++++++--- 6 files changed, 25 insertions(+), 11 deletions(-) diff --git a/src/vs/platform/statusbar/common/statusbar.ts b/src/vs/platform/statusbar/common/statusbar.ts index 6e45f806115..d42f792b801 100644 --- a/src/vs/platform/statusbar/common/statusbar.ts +++ b/src/vs/platform/statusbar/common/statusbar.ts @@ -7,6 +7,7 @@ import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; import { IDisposable } from 'vs/base/common/lifecycle'; +import { ThemeColor } from 'vs/editor/common/editorCommon'; export var IStatusbarService = createDecorator('statusbarService'); @@ -34,7 +35,7 @@ export interface IStatusbarEntry { /** * An optional color to use for the entry */ - color?: string; + color?: string | ThemeColor; /** * An optional id of a command that is known to the workbench to execute on click diff --git a/src/vs/vscode.d.ts b/src/vs/vscode.d.ts index 4850740fec1..35a6a58cc03 100644 --- a/src/vs/vscode.d.ts +++ b/src/vs/vscode.d.ts @@ -3301,7 +3301,7 @@ declare module 'vscode' { /** * The foreground color for this entry. */ - color: string | undefined; + color: string | ThemeColor | undefined; /** * The identifier of a command to run on click. The command must be diff --git a/src/vs/workbench/api/electron-browser/mainThreadStatusBar.ts b/src/vs/workbench/api/electron-browser/mainThreadStatusBar.ts index d64d9d3ac2b..d16e17cda09 100644 --- a/src/vs/workbench/api/electron-browser/mainThreadStatusBar.ts +++ b/src/vs/workbench/api/electron-browser/mainThreadStatusBar.ts @@ -7,6 +7,7 @@ import { IStatusbarService, StatusbarAlignment as MainThreadStatusBarAlignment } from 'vs/platform/statusbar/common/statusbar'; import { IDisposable } from 'vs/base/common/lifecycle'; import { MainThreadStatusBarShape } from '../node/extHost.protocol'; +import { ThemeColor } from 'vs/editor/common/editorCommon'; export class MainThreadStatusBar extends MainThreadStatusBarShape { private mapIdToDisposable: { [id: number]: IDisposable }; @@ -18,7 +19,7 @@ export class MainThreadStatusBar extends MainThreadStatusBarShape { this.mapIdToDisposable = Object.create(null); } - $setEntry(id: number, extensionId: string, text: string, tooltip: string, command: string, color: string, alignment: MainThreadStatusBarAlignment, priority: number): void { + $setEntry(id: number, extensionId: string, text: string, tooltip: string, command: string, color: string | ThemeColor, alignment: MainThreadStatusBarAlignment, priority: number): void { // Dispose any old this.$dispose(id); diff --git a/src/vs/workbench/api/node/extHost.protocol.ts b/src/vs/workbench/api/node/extHost.protocol.ts index 1dbe9058048..f9c02d01d8c 100644 --- a/src/vs/workbench/api/node/extHost.protocol.ts +++ b/src/vs/workbench/api/node/extHost.protocol.ts @@ -277,7 +277,7 @@ export abstract class MainThreadQuickOpenShape { } export abstract class MainThreadStatusBarShape { - $setEntry(id: number, extensionId: string, text: string, tooltip: string, command: string, color: string, alignment: MainThreadStatusBarAlignment, priority: number): void { throw ni(); } + $setEntry(id: number, extensionId: string, text: string, tooltip: string, command: string, color: string | editorCommon.ThemeColor, alignment: MainThreadStatusBarAlignment, priority: number): void { throw ni(); } $dispose(id: number) { throw ni(); } } diff --git a/src/vs/workbench/api/node/extHostStatusBar.ts b/src/vs/workbench/api/node/extHostStatusBar.ts index 97c917caf51..6e91e7dbf9a 100644 --- a/src/vs/workbench/api/node/extHostStatusBar.ts +++ b/src/vs/workbench/api/node/extHostStatusBar.ts @@ -6,7 +6,7 @@ import { IThreadService } from 'vs/workbench/services/thread/common/threadService'; import { StatusbarAlignment as MainThreadStatusBarAlignment } from 'vs/platform/statusbar/common/statusbar'; -import { StatusBarAlignment as ExtHostStatusBarAlignment, Disposable } from './extHostTypes'; +import { StatusBarAlignment as ExtHostStatusBarAlignment, Disposable, ThemeColor } from './extHostTypes'; import { StatusBarItem, StatusBarAlignment } from 'vscode'; import { MainContext, MainThreadStatusBarShape } from './extHost.protocol'; @@ -21,7 +21,7 @@ export class ExtHostStatusBarEntry implements StatusBarItem { private _text: string; private _tooltip: string; - private _color: string; + private _color: string | ThemeColor; private _command: string; private _timeoutHandle: number; @@ -57,7 +57,7 @@ export class ExtHostStatusBarEntry implements StatusBarItem { return this._tooltip; } - public get color(): string { + public get color(): string | ThemeColor { return this._color; } @@ -75,7 +75,7 @@ export class ExtHostStatusBarEntry implements StatusBarItem { this.update(); } - public set color(color: string) { + public set color(color: string | ThemeColor) { this._color = color; this.update(); } diff --git a/src/vs/workbench/browser/parts/statusbar/statusbarPart.ts b/src/vs/workbench/browser/parts/statusbar/statusbarPart.ts index 123f0f5d26e..fd2fd574fb4 100644 --- a/src/vs/workbench/browser/parts/statusbar/statusbarPart.ts +++ b/src/vs/workbench/browser/parts/statusbar/statusbarPart.ts @@ -30,6 +30,8 @@ import { IThemeService, registerThemingParticipant, ITheme, ICssStyleCollector } import { STATUS_BAR_BACKGROUND, STATUS_BAR_FOREGROUND, STATUS_BAR_NO_FOLDER_BACKGROUND, STATUS_BAR_ITEM_HOVER_BACKGROUND, STATUS_BAR_ITEM_ACTIVE_BACKGROUND, STATUS_BAR_PROMINENT_ITEM_BACKGROUND, STATUS_BAR_PROMINENT_ITEM_HOVER_BACKGROUND, STATUS_BAR_BORDER, STATUS_BAR_NO_FOLDER_FOREGROUND } from 'vs/workbench/common/theme'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { contrastBorder } from 'vs/platform/theme/common/colorRegistry'; +import { isThemeColor } from "vs/editor/common/editorCommon"; +import { Color } from 'vs/base/common/color'; export class StatusbarPart extends Part implements IStatusbarService { @@ -217,7 +219,8 @@ class StatusBarEntryItem implements IStatusbarItem { @IMessageService private messageService: IMessageService, @ITelemetryService private telemetryService: ITelemetryService, @IContextMenuService private contextMenuService: IContextMenuService, - @IWorkbenchEditorService private editorService: IWorkbenchEditorService + @IWorkbenchEditorService private editorService: IWorkbenchEditorService, + @IThemeService private themeService: IThemeService ) { this.entry = entry; @@ -249,8 +252,17 @@ class StatusBarEntryItem implements IStatusbarItem { } // Color - if (this.entry.color) { - $(textContainer).color(this.entry.color); + let color = this.entry.color; + if (color) { + if (isThemeColor(color)) { + let colorId = color.id; + color = (this.themeService.getTheme().getColor(colorId) || Color.transparent).toString(); + toDispose.push(this.themeService.onThemeChange(theme => { + let colorValue = (this.themeService.getTheme().getColor(colorId) || Color.transparent).toString(); + $(textContainer).color(colorValue); + })); + } + $(textContainer).color(color); } // Context Menu -- GitLab From 43003d7ff65cdf8a5de2d69360c69d61d9ef96d7 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Wed, 24 May 2017 23:50:40 +0200 Subject: [PATCH 0122/1347] Fix deprecation warning on StyleSheet.insertRule --- src/vs/editor/browser/services/codeEditorServiceImpl.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vs/editor/browser/services/codeEditorServiceImpl.ts b/src/vs/editor/browser/services/codeEditorServiceImpl.ts index 703e6e4f0ee..26bc62e9e6a 100644 --- a/src/vs/editor/browser/services/codeEditorServiceImpl.ts +++ b/src/vs/editor/browser/services/codeEditorServiceImpl.ts @@ -316,15 +316,15 @@ class DecorationCSSRules { let hasContent = false; if (unthemedCSS.length > 0) { - sheet.insertRule(`${this._unThemedSelector} {${unthemedCSS}}`); + sheet.insertRule(`${this._unThemedSelector} {${unthemedCSS}}`, 0); hasContent = true; } if (lightCSS.length > 0) { - sheet.insertRule(`.vs${this._unThemedSelector} {${lightCSS}}`); + sheet.insertRule(`.vs${this._unThemedSelector} {${lightCSS}}`, 0); hasContent = true; } if (darkCSS.length > 0) { - sheet.insertRule(`.vs-dark${this._unThemedSelector}, .hc-black${this._unThemedSelector} {${darkCSS}}`); + sheet.insertRule(`.vs-dark${this._unThemedSelector}, .hc-black${this._unThemedSelector} {${darkCSS}}`, 0); hasContent = true; } this._hasContent = hasContent; -- GitLab From 59e7fbc25eabf4143c29d9df575fce1875e10e70 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 24 May 2017 15:03:40 -0700 Subject: [PATCH 0123/1347] use alwaysStrict in TS extension --- extensions/typescript/src/features/baseCodeLensProvider.ts | 2 -- extensions/typescript/src/features/bufferSyncSupport.ts | 1 - extensions/typescript/src/features/codeActionProvider.ts | 2 -- extensions/typescript/src/features/completionItemProvider.ts | 2 -- extensions/typescript/src/features/definitionProvider.ts | 2 -- extensions/typescript/src/features/definitionProviderBase.ts | 2 -- .../src/features/directiveCommentCompletionProvider.ts | 2 -- .../typescript/src/features/documentHighlightProvider.ts | 2 -- extensions/typescript/src/features/documentSymbolProvider.ts | 2 -- extensions/typescript/src/features/formattingProvider.ts | 2 -- extensions/typescript/src/features/hoverProvider.ts | 2 -- extensions/typescript/src/features/implementationProvider.ts | 2 -- .../src/features/implementationsCodeLensProvider.ts | 2 -- extensions/typescript/src/features/jsDocCompletionProvider.ts | 2 -- extensions/typescript/src/features/previewer.ts | 2 -- extensions/typescript/src/features/referenceProvider.ts | 2 -- .../typescript/src/features/referencesCodeLensProvider.ts | 2 -- extensions/typescript/src/features/renameProvider.ts | 2 -- extensions/typescript/src/features/signatureHelpProvider.ts | 2 -- extensions/typescript/src/features/typeDefinitionProvider.ts | 2 -- extensions/typescript/src/features/workspaceSymbolProvider.ts | 2 -- extensions/typescript/src/protocol.const.ts | 2 -- extensions/typescript/src/typescriptMain.ts | 1 - extensions/typescript/src/typescriptService.ts | 1 - extensions/typescript/src/typescriptServiceClient.ts | 2 -- extensions/typescript/src/utils/async.ts | 2 -- extensions/typescript/src/utils/buildStatus.ts | 2 -- extensions/typescript/src/utils/electron.ts | 2 -- extensions/typescript/src/utils/is.ts | 2 -- extensions/typescript/src/utils/logger.ts | 2 -- extensions/typescript/src/utils/plugins.ts | 1 - extensions/typescript/src/utils/projectStatus.ts | 2 -- extensions/typescript/src/utils/telemetry.ts | 2 -- extensions/typescript/src/utils/tracer.ts | 2 -- extensions/typescript/src/utils/typingsStatus.ts | 2 -- extensions/typescript/src/utils/versionStatus.ts | 2 -- extensions/typescript/src/utils/wireProtocol.ts | 2 -- extensions/typescript/tsconfig.json | 4 +++- 38 files changed, 3 insertions(+), 71 deletions(-) diff --git a/extensions/typescript/src/features/baseCodeLensProvider.ts b/extensions/typescript/src/features/baseCodeLensProvider.ts index 98e4de9cc1c..20952150c4b 100644 --- a/extensions/typescript/src/features/baseCodeLensProvider.ts +++ b/extensions/typescript/src/features/baseCodeLensProvider.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { CodeLensProvider, CodeLens, CancellationToken, TextDocument, Range, Uri, Position, Event, EventEmitter, ProviderResult, } from 'vscode'; import * as Proto from '../protocol'; diff --git a/extensions/typescript/src/features/bufferSyncSupport.ts b/extensions/typescript/src/features/bufferSyncSupport.ts index dfb32d759da..f2b11faebef 100644 --- a/extensions/typescript/src/features/bufferSyncSupport.ts +++ b/extensions/typescript/src/features/bufferSyncSupport.ts @@ -2,7 +2,6 @@ * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; import * as cp from 'child_process'; import * as fs from 'fs'; diff --git a/extensions/typescript/src/features/codeActionProvider.ts b/extensions/typescript/src/features/codeActionProvider.ts index 0a9d297987c..8f0dd56f01d 100644 --- a/extensions/typescript/src/features/codeActionProvider.ts +++ b/extensions/typescript/src/features/codeActionProvider.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { CodeActionProvider, TextDocument, Range, CancellationToken, CodeActionContext, Command, commands, Uri, workspace, WorkspaceEdit, TextEdit, FormattingOptions, window, ProviderResult } from 'vscode'; import * as Proto from '../protocol'; diff --git a/extensions/typescript/src/features/completionItemProvider.ts b/extensions/typescript/src/features/completionItemProvider.ts index 618c84174bc..5f0740be10c 100644 --- a/extensions/typescript/src/features/completionItemProvider.ts +++ b/extensions/typescript/src/features/completionItemProvider.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { CompletionItem, TextDocument, Position, CompletionItemKind, CompletionItemProvider, CancellationToken, TextEdit, Range, SnippetString, workspace, ProviderResult } from 'vscode'; import { ITypescriptServiceClient } from '../typescriptService'; diff --git a/extensions/typescript/src/features/definitionProvider.ts b/extensions/typescript/src/features/definitionProvider.ts index ee364a63614..2713fc603db 100644 --- a/extensions/typescript/src/features/definitionProvider.ts +++ b/extensions/typescript/src/features/definitionProvider.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { DefinitionProvider, TextDocument, Position, CancellationToken, Definition } from 'vscode'; import { ITypescriptServiceClient } from '../typescriptService'; diff --git a/extensions/typescript/src/features/definitionProviderBase.ts b/extensions/typescript/src/features/definitionProviderBase.ts index 3cf66901015..b405d28fbaf 100644 --- a/extensions/typescript/src/features/definitionProviderBase.ts +++ b/extensions/typescript/src/features/definitionProviderBase.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { TextDocument, Position, Range, CancellationToken, Location } from 'vscode'; import * as Proto from '../protocol'; diff --git a/extensions/typescript/src/features/directiveCommentCompletionProvider.ts b/extensions/typescript/src/features/directiveCommentCompletionProvider.ts index a334e8c2f7b..6dd8aa8418d 100644 --- a/extensions/typescript/src/features/directiveCommentCompletionProvider.ts +++ b/extensions/typescript/src/features/directiveCommentCompletionProvider.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { Position, CompletionItemProvider, CompletionItemKind, TextDocument, CancellationToken, CompletionItem, ProviderResult, Range } from 'vscode'; import { ITypescriptServiceClient } from '../typescriptService'; diff --git a/extensions/typescript/src/features/documentHighlightProvider.ts b/extensions/typescript/src/features/documentHighlightProvider.ts index afffc9fa60c..f0140953d92 100644 --- a/extensions/typescript/src/features/documentHighlightProvider.ts +++ b/extensions/typescript/src/features/documentHighlightProvider.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { DocumentHighlightProvider, DocumentHighlight, DocumentHighlightKind, TextDocument, Position, Range, CancellationToken } from 'vscode'; import * as Proto from '../protocol'; diff --git a/extensions/typescript/src/features/documentSymbolProvider.ts b/extensions/typescript/src/features/documentSymbolProvider.ts index 5d4a8595a37..aa6a4e5ab7f 100644 --- a/extensions/typescript/src/features/documentSymbolProvider.ts +++ b/extensions/typescript/src/features/documentSymbolProvider.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { DocumentSymbolProvider, SymbolInformation, SymbolKind, TextDocument, Range, Location, CancellationToken, Uri } from 'vscode'; import * as Proto from '../protocol'; diff --git a/extensions/typescript/src/features/formattingProvider.ts b/extensions/typescript/src/features/formattingProvider.ts index 77f6971201e..40b5522d0fa 100644 --- a/extensions/typescript/src/features/formattingProvider.ts +++ b/extensions/typescript/src/features/formattingProvider.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { workspace as Workspace, DocumentRangeFormattingEditProvider, OnTypeFormattingEditProvider, FormattingOptions, TextDocument, Position, Range, CancellationToken, TextEdit, WorkspaceConfiguration } from 'vscode'; import * as Proto from '../protocol'; diff --git a/extensions/typescript/src/features/hoverProvider.ts b/extensions/typescript/src/features/hoverProvider.ts index 75d36131baf..e726ff1dc34 100644 --- a/extensions/typescript/src/features/hoverProvider.ts +++ b/extensions/typescript/src/features/hoverProvider.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { HoverProvider, Hover, TextDocument, Position, Range, CancellationToken } from 'vscode'; import * as Proto from '../protocol'; diff --git a/extensions/typescript/src/features/implementationProvider.ts b/extensions/typescript/src/features/implementationProvider.ts index 452afad1033..ab4d5b8c45b 100644 --- a/extensions/typescript/src/features/implementationProvider.ts +++ b/extensions/typescript/src/features/implementationProvider.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { ImplementationProvider, TextDocument, Position, CancellationToken, Definition } from 'vscode'; import { ITypescriptServiceClient } from '../typescriptService'; diff --git a/extensions/typescript/src/features/implementationsCodeLensProvider.ts b/extensions/typescript/src/features/implementationsCodeLensProvider.ts index 793176bb4f6..30daa644a4e 100644 --- a/extensions/typescript/src/features/implementationsCodeLensProvider.ts +++ b/extensions/typescript/src/features/implementationsCodeLensProvider.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { CodeLens, CancellationToken, TextDocument, Range, Location, ProviderResult, workspace } from 'vscode'; import * as Proto from '../protocol'; import * as PConst from '../protocol.const'; diff --git a/extensions/typescript/src/features/jsDocCompletionProvider.ts b/extensions/typescript/src/features/jsDocCompletionProvider.ts index fc8e88d5df2..da02e942bfc 100644 --- a/extensions/typescript/src/features/jsDocCompletionProvider.ts +++ b/extensions/typescript/src/features/jsDocCompletionProvider.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { Position, Range, CompletionItemProvider, CompletionItemKind, TextDocument, CancellationToken, CompletionItem, window, Uri, ProviderResult, TextEditor, SnippetString, workspace } from 'vscode'; import { ITypescriptServiceClient } from '../typescriptService'; diff --git a/extensions/typescript/src/features/previewer.ts b/extensions/typescript/src/features/previewer.ts index d02ab69550b..c418e92d59a 100644 --- a/extensions/typescript/src/features/previewer.ts +++ b/extensions/typescript/src/features/previewer.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import * as Proto from '../protocol'; export function plain(parts: Proto.SymbolDisplayPart[]): string { diff --git a/extensions/typescript/src/features/referenceProvider.ts b/extensions/typescript/src/features/referenceProvider.ts index 56aac3a0cd8..47921d128ea 100644 --- a/extensions/typescript/src/features/referenceProvider.ts +++ b/extensions/typescript/src/features/referenceProvider.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { ReferenceProvider, Location, TextDocument, Position, Range, CancellationToken } from 'vscode'; import * as Proto from '../protocol'; diff --git a/extensions/typescript/src/features/referencesCodeLensProvider.ts b/extensions/typescript/src/features/referencesCodeLensProvider.ts index 46ecf347e72..5576bfc4825 100644 --- a/extensions/typescript/src/features/referencesCodeLensProvider.ts +++ b/extensions/typescript/src/features/referencesCodeLensProvider.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { CodeLens, CancellationToken, TextDocument, Range, Location, ProviderResult, workspace } from 'vscode'; import * as Proto from '../protocol'; import * as PConst from '../protocol.const'; diff --git a/extensions/typescript/src/features/renameProvider.ts b/extensions/typescript/src/features/renameProvider.ts index da279ab5596..39c85f307a7 100644 --- a/extensions/typescript/src/features/renameProvider.ts +++ b/extensions/typescript/src/features/renameProvider.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { RenameProvider, WorkspaceEdit, TextDocument, Position, Range, CancellationToken } from 'vscode'; import * as Proto from '../protocol'; diff --git a/extensions/typescript/src/features/signatureHelpProvider.ts b/extensions/typescript/src/features/signatureHelpProvider.ts index b8247e03154..0a794878624 100644 --- a/extensions/typescript/src/features/signatureHelpProvider.ts +++ b/extensions/typescript/src/features/signatureHelpProvider.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { SignatureHelpProvider, SignatureHelp, SignatureInformation, ParameterInformation, TextDocument, Position, CancellationToken } from 'vscode'; import * as Previewer from './previewer'; diff --git a/extensions/typescript/src/features/typeDefinitionProvider.ts b/extensions/typescript/src/features/typeDefinitionProvider.ts index edaccf0bf33..d107f67580a 100644 --- a/extensions/typescript/src/features/typeDefinitionProvider.ts +++ b/extensions/typescript/src/features/typeDefinitionProvider.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { TypeDefinitionProvider, TextDocument, Position, CancellationToken, Definition } from 'vscode'; import { ITypescriptServiceClient } from '../typescriptService'; diff --git a/extensions/typescript/src/features/workspaceSymbolProvider.ts b/extensions/typescript/src/features/workspaceSymbolProvider.ts index 8593c4a8955..016ac8726b3 100644 --- a/extensions/typescript/src/features/workspaceSymbolProvider.ts +++ b/extensions/typescript/src/features/workspaceSymbolProvider.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { workspace, window, Uri, WorkspaceSymbolProvider, SymbolInformation, SymbolKind, Range, Location, CancellationToken } from 'vscode'; import * as Proto from '../protocol'; diff --git a/extensions/typescript/src/protocol.const.ts b/extensions/typescript/src/protocol.const.ts index 6990868683d..822e05d2b21 100644 --- a/extensions/typescript/src/protocol.const.ts +++ b/extensions/typescript/src/protocol.const.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - export class Kind { public static readonly alias = 'alias'; public static readonly callSignature = 'call'; diff --git a/extensions/typescript/src/typescriptMain.ts b/extensions/typescript/src/typescriptMain.ts index 037ae6f8464..45ba3a85290 100644 --- a/extensions/typescript/src/typescriptMain.ts +++ b/extensions/typescript/src/typescriptMain.ts @@ -7,7 +7,6 @@ * Includes code from typescript-sublime-plugin project, obtained from * https://github.com/Microsoft/TypeScript-Sublime-Plugin/blob/master/TypeScript%20Indent.tmPreferences * ------------------------------------------------------------------------------------------ */ -'use strict'; import { env, languages, commands, workspace, window, ExtensionContext, Memento, IndentAction, Diagnostic, DiagnosticCollection, Range, Disposable, Uri, MessageItem, TextEditor, DiagnosticSeverity, TextDocument, SnippetString } from 'vscode'; diff --git a/extensions/typescript/src/typescriptService.ts b/extensions/typescript/src/typescriptService.ts index bfc410c6cba..8b15cc79f7b 100644 --- a/extensions/typescript/src/typescriptService.ts +++ b/extensions/typescript/src/typescriptService.ts @@ -3,7 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; import { CancellationToken, Uri, Event } from 'vscode'; import * as Proto from './protocol'; diff --git a/extensions/typescript/src/typescriptServiceClient.ts b/extensions/typescript/src/typescriptServiceClient.ts index f5a92dbd4cd..cf2b7c3be6f 100644 --- a/extensions/typescript/src/typescriptServiceClient.ts +++ b/extensions/typescript/src/typescriptServiceClient.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import * as cp from 'child_process'; import * as path from 'path'; import * as fs from 'fs'; diff --git a/extensions/typescript/src/utils/async.ts b/extensions/typescript/src/utils/async.ts index fb260bde50b..f87754e69e8 100644 --- a/extensions/typescript/src/utils/async.ts +++ b/extensions/typescript/src/utils/async.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - export interface ITask { (): T; } diff --git a/extensions/typescript/src/utils/buildStatus.ts b/extensions/typescript/src/utils/buildStatus.ts index cf640508af3..ced56fd43b9 100644 --- a/extensions/typescript/src/utils/buildStatus.ts +++ b/extensions/typescript/src/utils/buildStatus.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import vscode = require('vscode'); const statusItem: vscode.StatusBarItem = vscode.window.createStatusBarItem(vscode.StatusBarAlignment.Left, Number.MIN_VALUE); diff --git a/extensions/typescript/src/utils/electron.ts b/extensions/typescript/src/utils/electron.ts index 51c44519891..4418ca51dbd 100644 --- a/extensions/typescript/src/utils/electron.ts +++ b/extensions/typescript/src/utils/electron.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import path = require('path'); import os = require('os'); import net = require('net'); diff --git a/extensions/typescript/src/utils/is.ts b/extensions/typescript/src/utils/is.ts index 78ef8c734cd..fc6fd6ad286 100644 --- a/extensions/typescript/src/utils/is.ts +++ b/extensions/typescript/src/utils/is.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - const toString = Object.prototype.toString; export function defined(value: any): boolean { diff --git a/extensions/typescript/src/utils/logger.ts b/extensions/typescript/src/utils/logger.ts index 577314c351d..7f82fb28c96 100644 --- a/extensions/typescript/src/utils/logger.ts +++ b/extensions/typescript/src/utils/logger.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { OutputChannel, window } from "vscode"; import * as is from './is'; diff --git a/extensions/typescript/src/utils/plugins.ts b/extensions/typescript/src/utils/plugins.ts index 24fb56e99b7..49f0d93b4b6 100644 --- a/extensions/typescript/src/utils/plugins.ts +++ b/extensions/typescript/src/utils/plugins.ts @@ -2,7 +2,6 @@ * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; import { extensions } from "vscode"; diff --git a/extensions/typescript/src/utils/projectStatus.ts b/extensions/typescript/src/utils/projectStatus.ts index f6042d29449..8c9911531eb 100644 --- a/extensions/typescript/src/utils/projectStatus.ts +++ b/extensions/typescript/src/utils/projectStatus.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import * as vscode from 'vscode'; import { ITypescriptServiceClient } from '../typescriptService'; import { loadMessageBundle } from 'vscode-nls'; diff --git a/extensions/typescript/src/utils/telemetry.ts b/extensions/typescript/src/utils/telemetry.ts index 17c43339a9e..5162a0c24d5 100644 --- a/extensions/typescript/src/utils/telemetry.ts +++ b/extensions/typescript/src/utils/telemetry.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import * as path from 'path'; import VsCodeTelemetryReporter from 'vscode-extension-telemetry'; import { Disposable } from "vscode"; diff --git a/extensions/typescript/src/utils/tracer.ts b/extensions/typescript/src/utils/tracer.ts index 078d2e6f45a..fe16a13d61a 100644 --- a/extensions/typescript/src/utils/tracer.ts +++ b/extensions/typescript/src/utils/tracer.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { workspace } from 'vscode'; import * as Proto from '../protocol'; diff --git a/extensions/typescript/src/utils/typingsStatus.ts b/extensions/typescript/src/utils/typingsStatus.ts index 4798046abf6..44f90ec15c1 100644 --- a/extensions/typescript/src/utils/typingsStatus.ts +++ b/extensions/typescript/src/utils/typingsStatus.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import { MessageItem, workspace, Disposable, ProgressLocation, window, commands, Uri } from 'vscode'; import { ITypescriptServiceClient } from '../typescriptService'; import { loadMessageBundle } from 'vscode-nls'; diff --git a/extensions/typescript/src/utils/versionStatus.ts b/extensions/typescript/src/utils/versionStatus.ts index 358d3a9b103..e92b87d0f24 100644 --- a/extensions/typescript/src/utils/versionStatus.ts +++ b/extensions/typescript/src/utils/versionStatus.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import vscode = require('vscode'); const versionBarEntry = vscode.window.createStatusBarItem(vscode.StatusBarAlignment.Right, Number.MIN_VALUE); diff --git a/extensions/typescript/src/utils/wireProtocol.ts b/extensions/typescript/src/utils/wireProtocol.ts index 218d461f853..ad5d464304d 100644 --- a/extensions/typescript/src/utils/wireProtocol.ts +++ b/extensions/typescript/src/utils/wireProtocol.ts @@ -3,8 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -'use strict'; - import stream = require('stream'); const DefaultSize: number = 8192; diff --git a/extensions/typescript/tsconfig.json b/extensions/typescript/tsconfig.json index 3112725c103..da4f1bb399b 100644 --- a/extensions/typescript/tsconfig.json +++ b/extensions/typescript/tsconfig.json @@ -11,7 +11,9 @@ "noImplicitAny": true, "noImplicitReturns": true, "noUnusedLocals": true, - "noUnusedParameters": true + "noUnusedParameters": true, + "strict": true, + "alwaysStrict": true }, "include": [ "src/**/*" -- GitLab From 2890b5d8ab3d3a9fe9dd3401ebc9f14c9fa89319 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 24 May 2017 15:07:43 -0700 Subject: [PATCH 0124/1347] Add restart TSServer command. Fixes #22335 --- extensions/typescript/package.json | 5 +++++ extensions/typescript/package.nls.json | 1 + extensions/typescript/src/typescriptMain.ts | 4 ++++ 3 files changed, 10 insertions(+) diff --git a/extensions/typescript/package.json b/extensions/typescript/package.json index cb4fa518bf0..a24c0c10519 100644 --- a/extensions/typescript/package.json +++ b/extensions/typescript/package.json @@ -345,6 +345,11 @@ "command": "typescript.openTsServerLog", "title": "%typescript.openTsServerLog.title%", "category": "TypeScript" + }, + { + "command": "typescript.restartTsServer", + "title": "%typescript.restartTsServer%", + "category": "TypeScript" } ], "menus": { diff --git a/extensions/typescript/package.nls.json b/extensions/typescript/package.nls.json index faa59a26d7f..821257b38a1 100644 --- a/extensions/typescript/package.nls.json +++ b/extensions/typescript/package.nls.json @@ -32,6 +32,7 @@ "typescript.referencesCodeLens.enabled": "Enable/disable references CodeLens in TypeScript files. Requires TypeScript >= 2.0.6.", "typescript.implementationsCodeLens.enabled": "Enable/disable implementations CodeLens. Requires TypeScript >= 2.2.0.", "typescript.openTsServerLog.title": "Open TS Server log", + "typescript.restartTsServer": "Restart TS server", "typescript.selectTypeScriptVersion.title": "Select TypeScript Version", "jsDocCompletion.enabled": "Enable/disable auto JSDoc comments", "javascript.implicitProjectConfig.checkJs": "Enable/disable semantic checking of JavaScript files. Existing jsconfig.json or tsconfig.json files override this setting. Requires TypeScript >=2.3.1.", diff --git a/extensions/typescript/src/typescriptMain.ts b/extensions/typescript/src/typescriptMain.ts index 45ba3a85290..9949d0db9d2 100644 --- a/extensions/typescript/src/typescriptMain.ts +++ b/extensions/typescript/src/typescriptMain.ts @@ -109,6 +109,10 @@ export function activate(context: ExtensionContext): void { client.openTsServerLogFile(); })); + context.subscriptions.push(commands.registerCommand('typescript.restartTsServer', () => { + client.restartTsServer(); + })); + const goToProjectConfig = (isTypeScript: boolean) => { const editor = window.activeTextEditor; if (editor) { -- GitLab From d21ff22a1fbceae4b04c517e0cb49c679242154b Mon Sep 17 00:00:00 2001 From: rebornix Date: Wed, 24 May 2017 15:11:57 -0700 Subject: [PATCH 0125/1347] Fix #27144. We just need to listen to scrollTop change for FindWidget --- src/vs/editor/contrib/find/browser/findWidget.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/vs/editor/contrib/find/browser/findWidget.ts b/src/vs/editor/contrib/find/browser/findWidget.ts index 74454a278ec..78e442c6992 100644 --- a/src/vs/editor/contrib/find/browser/findWidget.ts +++ b/src/vs/editor/contrib/find/browser/findWidget.ts @@ -235,7 +235,9 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas })); this._register(this._codeEditor.onDidScrollChange((e) => { - this._layoutViewZone(); + if (e.scrollTopChanged) { + this._layoutViewZone(); + } })); } -- GitLab From 3aade944ae7ff0bc62183614f547477fa1722d8c Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 24 May 2017 16:43:49 +0200 Subject: [PATCH 0126/1347] Introduce `multicursorModifier` editor options --- .../common/config/commonEditorConfig.ts | 6 ++++ src/vs/editor/common/config/editorOptions.ts | 34 +++++++++++++++++++ src/vs/monaco.d.ts | 7 ++++ 3 files changed, 47 insertions(+) diff --git a/src/vs/editor/common/config/commonEditorConfig.ts b/src/vs/editor/common/config/commonEditorConfig.ts index 6fca4c237d0..bf24f6608be 100644 --- a/src/vs/editor/common/config/commonEditorConfig.ts +++ b/src/vs/editor/common/config/commonEditorConfig.ts @@ -321,6 +321,12 @@ const editorConfiguration: IConfigurationNode = { 'default': EDITOR_DEFAULTS.viewInfo.scrollbar.mouseWheelScrollSensitivity, 'description': nls.localize('mouseWheelScrollSensitivity', "A multiplier to be used on the `deltaX` and `deltaY` of mouse wheel scroll events") }, + 'editor.multicursorModifier': { + 'type': 'string', + 'enum': (platform.isMacintosh ? ['cmd', 'alt'] : ['ctrl', 'alt']), + 'default': 'alt', + 'description': nls.localize('multicursorModifier', "The modifier to be used to add multiple cursors with the mouse.") + }, 'editor.quickSuggestions': { 'anyOf': [ { diff --git a/src/vs/editor/common/config/editorOptions.ts b/src/vs/editor/common/config/editorOptions.ts index 59056ff8227..720302d227e 100644 --- a/src/vs/editor/common/config/editorOptions.ts +++ b/src/vs/editor/common/config/editorOptions.ts @@ -331,6 +331,11 @@ export interface IEditorOptions { * Defaults to 1. */ mouseWheelScrollSensitivity?: number; + /** + * The modifier to be used to add multiple cursors with the mouse. + * Defaults to 'alt' + */ + multicursorModifier?: 'cmd' | 'ctrl' | 'alt'; /** * Enable quick suggestions (shadow suggestions) * Defaults to true. @@ -783,6 +788,7 @@ export interface IValidatedEditorOptions { readonly dragAndDrop: boolean; readonly emptySelectionClipboard: boolean; readonly useTabStops: boolean; + readonly multicursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; readonly viewInfo: InternalEditorViewOptions; readonly contribInfo: EditorContribOptions; @@ -803,6 +809,7 @@ export class InternalEditorOptions { * @internal */ readonly accessibilitySupport: platform.AccessibilitySupport; + readonly multicursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; // ---- cursor options readonly wordSeparators: string; @@ -829,6 +836,7 @@ export class InternalEditorOptions { lineHeight: number; readOnly: boolean; accessibilitySupport: platform.AccessibilitySupport; + multicursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; wordSeparators: string; autoClosingBrackets: boolean; useTabStops: boolean; @@ -847,6 +855,7 @@ export class InternalEditorOptions { this.lineHeight = source.lineHeight | 0; this.readOnly = source.readOnly; this.accessibilitySupport = source.accessibilitySupport; + this.multicursorModifier = source.multicursorModifier; this.wordSeparators = source.wordSeparators; this.autoClosingBrackets = source.autoClosingBrackets; this.useTabStops = source.useTabStops; @@ -871,6 +880,7 @@ export class InternalEditorOptions { && this.lineHeight === other.lineHeight && this.readOnly === other.readOnly && this.accessibilitySupport === other.accessibilitySupport + && this.multicursorModifier === other.multicursorModifier && this.wordSeparators === other.wordSeparators && this.autoClosingBrackets === other.autoClosingBrackets && this.useTabStops === other.useTabStops @@ -896,6 +906,7 @@ export class InternalEditorOptions { lineHeight: (this.lineHeight !== newOpts.lineHeight), readOnly: (this.readOnly !== newOpts.readOnly), accessibilitySupport: (this.accessibilitySupport !== newOpts.accessibilitySupport), + multicursorModifier: (this.multicursorModifier !== newOpts.multicursorModifier), wordSeparators: (this.wordSeparators !== newOpts.wordSeparators), autoClosingBrackets: (this.autoClosingBrackets !== newOpts.autoClosingBrackets), useTabStops: (this.useTabStops !== newOpts.useTabStops), @@ -1233,6 +1244,7 @@ export interface IConfigurationChangedEvent { readonly lineHeight: boolean; readonly readOnly: boolean; readonly accessibilitySupport: boolean; + readonly multicursorModifier: boolean; readonly wordSeparators: boolean; readonly autoClosingBrackets: boolean; readonly useTabStops: boolean; @@ -1386,6 +1398,24 @@ export class EditorOptionsValidator { const viewInfo = this._sanitizeViewInfo(opts, defaults.viewInfo); const contribInfo = this._sanitizeContribInfo(opts, defaults.contribInfo); + let configuredMulticursorModifier: 'altKey' | 'metaKey' | 'ctrlKey'; + if (typeof opts.multicursorModifier === 'string') { + if (platform.isMacintosh) { + if (opts.multicursorModifier === 'cmd') { + configuredMulticursorModifier = 'metaKey'; + } else { + configuredMulticursorModifier = 'altKey'; + } + } else { + if (opts.multicursorModifier === 'ctrl') { + configuredMulticursorModifier = 'ctrlKey'; + } else { + configuredMulticursorModifier = 'altKey'; + } + } + } + const multicursorModifier = _stringSet<'altKey' | 'metaKey' | 'ctrlKey'>(configuredMulticursorModifier, defaults.multicursorModifier, ['altKey', 'metaKey', 'ctrlKey']); + return { inDiffEditor: _boolean(opts.inDiffEditor, defaults.inDiffEditor), wordSeparators: _string(opts.wordSeparators, defaults.wordSeparators), @@ -1406,6 +1436,7 @@ export class EditorOptionsValidator { dragAndDrop: _boolean(opts.dragAndDrop, defaults.dragAndDrop), emptySelectionClipboard: _boolean(opts.emptySelectionClipboard, defaults.emptySelectionClipboard), useTabStops: _boolean(opts.useTabStops, defaults.useTabStops), + multicursorModifier: multicursorModifier, viewInfo: viewInfo, contribInfo: contribInfo, }; @@ -1629,6 +1660,7 @@ export class InternalEditorOptionsFactory { dragAndDrop: opts.dragAndDrop, emptySelectionClipboard: opts.emptySelectionClipboard, useTabStops: opts.useTabStops, + multicursorModifier: opts.multicursorModifier, viewInfo: { extraEditorClassName: opts.viewInfo.extraEditorClassName, @@ -1805,6 +1837,7 @@ export class InternalEditorOptionsFactory { lineHeight: env.fontInfo.lineHeight, readOnly: opts.readOnly, accessibilitySupport: env.accessibilitySupport, + multicursorModifier: opts.multicursorModifier, wordSeparators: opts.wordSeparators, autoClosingBrackets: opts.autoClosingBrackets, useTabStops: opts.useTabStops, @@ -2023,6 +2056,7 @@ export const EDITOR_DEFAULTS: IValidatedEditorOptions = { dragAndDrop: false, emptySelectionClipboard: true, useTabStops: true, + multicursorModifier: 'altKey', viewInfo: { extraEditorClassName: '', diff --git a/src/vs/monaco.d.ts b/src/vs/monaco.d.ts index 707cb1047fa..7f3c80b83fa 100644 --- a/src/vs/monaco.d.ts +++ b/src/vs/monaco.d.ts @@ -2876,6 +2876,11 @@ declare module monaco.editor { * Defaults to 1. */ mouseWheelScrollSensitivity?: number; + /** + * The modifier to be used to add multiple cursors with the mouse. + * Defaults to 'alt' + */ + multicursorModifier?: 'cmd' | 'ctrl' | 'alt'; /** * Enable quick suggestions (shadow suggestions) * Defaults to true. @@ -3257,6 +3262,7 @@ declare module monaco.editor { readonly editorClassName: string; readonly lineHeight: number; readonly readOnly: boolean; + readonly multicursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; readonly wordSeparators: string; readonly autoClosingBrackets: boolean; readonly useTabStops: boolean; @@ -3388,6 +3394,7 @@ declare module monaco.editor { readonly lineHeight: boolean; readonly readOnly: boolean; readonly accessibilitySupport: boolean; + readonly multicursorModifier: boolean; readonly wordSeparators: boolean; readonly autoClosingBrackets: boolean; readonly useTabStops: boolean; -- GitLab From 434d941e639acab3e0c6f867cb144d69dc2dd980 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 24 May 2017 17:35:55 +0200 Subject: [PATCH 0127/1347] Encapsulate trigger modifier logic in goToDeclarationMouse --- .../browser/goToDeclarationMouse.ts | 81 +++++++++++++------ 1 file changed, 58 insertions(+), 23 deletions(-) diff --git a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts index 05aecd1ec0f..15ccefb5d73 100644 --- a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts +++ b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts @@ -30,6 +30,40 @@ import { editorActiveLinkForeground } from 'vs/platform/theme/common/colorRegist import { EditorState, CodeEditorStateFlag } from 'vs/editor/common/core/editorState'; import { DefinitionAction, DefinitionActionConfig } from './goToDeclarationCommands'; +/** + * An event that encapsulates the various trigger modifiers logic needed for go to definition. + */ +class MyMouseEvent { + + public readonly target: IMouseTarget; + public readonly hasTriggerModifier: boolean; + public readonly hasSideBySideModifier: boolean; + public readonly isSingleMouseDown: boolean; + + constructor(source: IEditorMouseEvent) { + this.target = source.target; + this.hasTriggerModifier = !!source.event[GotoDefinitionWithMouseEditorContribution.TRIGGER_MODIFIER]; + this.hasSideBySideModifier = source.event.altKey; + this.isSingleMouseDown = (browser.isIE || source.event.detail <= 1); // IE does not support event.detail properly + } +} + +/** + * An event that encapsulates the various trigger modifiers logic needed for go to definition. + */ +class MyKeyboardEvent { + + public readonly keyCodeIsTriggerKey: boolean; + public readonly keyCodeIsSideBySideKey: boolean; + public readonly hasTriggerModifier: boolean; + + constructor(source: IKeyboardEvent) { + this.keyCodeIsTriggerKey = (source.keyCode === GotoDefinitionWithMouseEditorContribution.TRIGGER_KEY_VALUE); + this.keyCodeIsSideBySideKey = (source.keyCode === GotoDefinitionWithMouseEditorContribution.TRIGGER_SIDEBYSIDE_KEY_VALUE); + this.hasTriggerModifier = !!source[GotoDefinitionWithMouseEditorContribution.TRIGGER_MODIFIER]; + } +} + @editorContribution class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorContribution { @@ -44,7 +78,7 @@ class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorC private decorations: string[]; private currentWordUnderMouse: editorCommon.IWordAtPosition; private throttler: Throttler; - private lastMouseMoveEvent: IEditorMouseEvent; + private lastMouseMoveEvent: MyMouseEvent; private hasTriggerKeyOnMouseDown: boolean; constructor( @@ -57,12 +91,12 @@ class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorC this.editor = editor; this.throttler = new Throttler(); - this.toUnhook.push(this.editor.onMouseDown((e: IEditorMouseEvent) => this.onEditorMouseDown(e))); - this.toUnhook.push(this.editor.onMouseUp((e: IEditorMouseEvent) => this.onEditorMouseUp(e))); - this.toUnhook.push(this.editor.onMouseMove((e: IEditorMouseEvent) => this.onEditorMouseMove(e))); + this.toUnhook.push(this.editor.onMouseDown((e: IEditorMouseEvent) => this.onEditorMouseDown(new MyMouseEvent(e)))); + this.toUnhook.push(this.editor.onMouseUp((e: IEditorMouseEvent) => this.onEditorMouseUp(new MyMouseEvent(e)))); + this.toUnhook.push(this.editor.onMouseMove((e: IEditorMouseEvent) => this.onEditorMouseMove(new MyMouseEvent(e)))); this.toUnhook.push(this.editor.onMouseDrag(() => this.resetHandler())); - this.toUnhook.push(this.editor.onKeyDown((e: IKeyboardEvent) => this.onEditorKeyDown(e))); - this.toUnhook.push(this.editor.onKeyUp((e: IKeyboardEvent) => this.onEditorKeyUp(e))); + this.toUnhook.push(this.editor.onKeyDown((e: IKeyboardEvent) => this.onEditorKeyDown(new MyKeyboardEvent(e)))); + this.toUnhook.push(this.editor.onKeyUp((e: IKeyboardEvent) => this.onEditorKeyUp(new MyKeyboardEvent(e)))); this.toUnhook.push(this.editor.onDidChangeCursorSelection((e) => this.onDidChangeCursorSelection(e))); this.toUnhook.push(this.editor.onDidChangeModel((e) => this.resetHandler())); @@ -80,13 +114,13 @@ class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorC } } - private onEditorMouseMove(mouseEvent: IEditorMouseEvent, withKey?: IKeyboardEvent): void { + private onEditorMouseMove(mouseEvent: MyMouseEvent): void { this.lastMouseMoveEvent = mouseEvent; - this.startFindDefinition(mouseEvent, withKey); + this.startFindDefinition(mouseEvent); } - private startFindDefinition(mouseEvent: IEditorMouseEvent, withKey?: IKeyboardEvent): void { + private startFindDefinition(mouseEvent: MyMouseEvent, withKey?: MyKeyboardEvent): void { if (!this.isEnabled(mouseEvent, withKey)) { this.currentWordUnderMouse = null; this.removeDecorations(); @@ -196,15 +230,16 @@ class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorC } } - private onEditorKeyDown(e: IKeyboardEvent): void { + private onEditorKeyDown(e: MyKeyboardEvent): void { if ( - this.lastMouseMoveEvent && ( - e.keyCode === GotoDefinitionWithMouseEditorContribution.TRIGGER_KEY_VALUE || // User just pressed Ctrl/Cmd (normal goto definition) - e.keyCode === GotoDefinitionWithMouseEditorContribution.TRIGGER_SIDEBYSIDE_KEY_VALUE && e[GotoDefinitionWithMouseEditorContribution.TRIGGER_MODIFIER] // User pressed Ctrl/Cmd+Alt (goto definition to the side) + this.lastMouseMoveEvent + && ( + e.keyCodeIsTriggerKey // User just pressed Ctrl/Cmd (normal goto definition) + || (e.keyCodeIsSideBySideKey && e.hasTriggerModifier) // User pressed Ctrl/Cmd+Alt (goto definition to the side) ) ) { this.startFindDefinition(this.lastMouseMoveEvent, e); - } else if (e[GotoDefinitionWithMouseEditorContribution.TRIGGER_MODIFIER]) { + } else if (e.hasTriggerModifier) { this.removeDecorations(); // remove decorations if user holds another key with ctrl/cmd to prevent accident goto declaration } } @@ -215,17 +250,17 @@ class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorC this.removeDecorations(); } - private onEditorMouseDown(mouseEvent: IEditorMouseEvent): void { + private onEditorMouseDown(mouseEvent: MyMouseEvent): void { // We need to record if we had the trigger key on mouse down because someone might select something in the editor // holding the mouse down and then while mouse is down start to press Ctrl/Cmd to start a copy operation and then // release the mouse button without wanting to do the navigation. // With this flag we prevent goto definition if the mouse was down before the trigger key was pressed. - this.hasTriggerKeyOnMouseDown = !!mouseEvent.event[GotoDefinitionWithMouseEditorContribution.TRIGGER_MODIFIER]; + this.hasTriggerKeyOnMouseDown = mouseEvent.hasTriggerModifier; } - private onEditorMouseUp(mouseEvent: IEditorMouseEvent): void { + private onEditorMouseUp(mouseEvent: MyMouseEvent): void { if (this.isEnabled(mouseEvent) && this.hasTriggerKeyOnMouseDown) { - this.gotoDefinition(mouseEvent.target, mouseEvent.event.altKey).done(() => { + this.gotoDefinition(mouseEvent.target, mouseEvent.hasSideBySideModifier).done(() => { this.removeDecorations(); }, (error: Error) => { this.removeDecorations(); @@ -234,18 +269,18 @@ class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorC } } - private onEditorKeyUp(e: IKeyboardEvent): void { - if (e.keyCode === GotoDefinitionWithMouseEditorContribution.TRIGGER_KEY_VALUE) { + private onEditorKeyUp(e: MyKeyboardEvent): void { + if (e.keyCodeIsTriggerKey) { this.removeDecorations(); this.currentWordUnderMouse = null; } } - private isEnabled(mouseEvent: IEditorMouseEvent, withKey?: IKeyboardEvent): boolean { + private isEnabled(mouseEvent: MyMouseEvent, withKey?: MyKeyboardEvent): boolean { return this.editor.getModel() && - (browser.isIE || mouseEvent.event.detail <= 1) && // IE does not support event.detail properly + mouseEvent.isSingleMouseDown && mouseEvent.target.type === MouseTargetType.CONTENT_TEXT && - (mouseEvent.event[GotoDefinitionWithMouseEditorContribution.TRIGGER_MODIFIER] || (withKey && withKey.keyCode === GotoDefinitionWithMouseEditorContribution.TRIGGER_KEY_VALUE)) && + (mouseEvent.hasTriggerModifier || (withKey && withKey.keyCodeIsTriggerKey)) && DefinitionProviderRegistry.has(this.editor.getModel()); } -- GitLab From 7bb5e4a68200b70e6ea7e259fff907b9d9fd9944 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 24 May 2017 17:40:31 +0200 Subject: [PATCH 0128/1347] Group method logically --- .../browser/goToDeclarationMouse.ts | 50 +++++++++---------- 1 file changed, 25 insertions(+), 25 deletions(-) diff --git a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts index 15ccefb5d73..e4d9aa7b6f4 100644 --- a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts +++ b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts @@ -91,12 +91,12 @@ class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorC this.editor = editor; this.throttler = new Throttler(); + this.toUnhook.push(this.editor.onMouseMove((e: IEditorMouseEvent) => this.onEditorMouseMove(new MyMouseEvent(e)))); this.toUnhook.push(this.editor.onMouseDown((e: IEditorMouseEvent) => this.onEditorMouseDown(new MyMouseEvent(e)))); this.toUnhook.push(this.editor.onMouseUp((e: IEditorMouseEvent) => this.onEditorMouseUp(new MyMouseEvent(e)))); - this.toUnhook.push(this.editor.onMouseMove((e: IEditorMouseEvent) => this.onEditorMouseMove(new MyMouseEvent(e)))); - this.toUnhook.push(this.editor.onMouseDrag(() => this.resetHandler())); this.toUnhook.push(this.editor.onKeyDown((e: IKeyboardEvent) => this.onEditorKeyDown(new MyKeyboardEvent(e)))); this.toUnhook.push(this.editor.onKeyUp((e: IKeyboardEvent) => this.onEditorKeyUp(new MyKeyboardEvent(e)))); + this.toUnhook.push(this.editor.onMouseDrag(() => this.resetHandler())); this.toUnhook.push(this.editor.onDidChangeCursorSelection((e) => this.onDidChangeCursorSelection(e))); this.toUnhook.push(this.editor.onDidChangeModel((e) => this.resetHandler())); @@ -114,12 +114,6 @@ class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorC } } - private onEditorMouseMove(mouseEvent: MyMouseEvent): void { - this.lastMouseMoveEvent = mouseEvent; - - this.startFindDefinition(mouseEvent); - } - private startFindDefinition(mouseEvent: MyMouseEvent, withKey?: MyKeyboardEvent): void { if (!this.isEnabled(mouseEvent, withKey)) { this.currentWordUnderMouse = null; @@ -230,24 +224,10 @@ class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorC } } - private onEditorKeyDown(e: MyKeyboardEvent): void { - if ( - this.lastMouseMoveEvent - && ( - e.keyCodeIsTriggerKey // User just pressed Ctrl/Cmd (normal goto definition) - || (e.keyCodeIsSideBySideKey && e.hasTriggerModifier) // User pressed Ctrl/Cmd+Alt (goto definition to the side) - ) - ) { - this.startFindDefinition(this.lastMouseMoveEvent, e); - } else if (e.hasTriggerModifier) { - this.removeDecorations(); // remove decorations if user holds another key with ctrl/cmd to prevent accident goto declaration - } - } + private onEditorMouseMove(mouseEvent: MyMouseEvent): void { + this.lastMouseMoveEvent = mouseEvent; - private resetHandler(): void { - this.lastMouseMoveEvent = null; - this.hasTriggerKeyOnMouseDown = false; - this.removeDecorations(); + this.startFindDefinition(mouseEvent); } private onEditorMouseDown(mouseEvent: MyMouseEvent): void { @@ -269,6 +249,20 @@ class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorC } } + private onEditorKeyDown(e: MyKeyboardEvent): void { + if ( + this.lastMouseMoveEvent + && ( + e.keyCodeIsTriggerKey // User just pressed Ctrl/Cmd (normal goto definition) + || (e.keyCodeIsSideBySideKey && e.hasTriggerModifier) // User pressed Ctrl/Cmd+Alt (goto definition to the side) + ) + ) { + this.startFindDefinition(this.lastMouseMoveEvent, e); + } else if (e.hasTriggerModifier) { + this.removeDecorations(); // remove decorations if user holds another key with ctrl/cmd to prevent accident goto declaration + } + } + private onEditorKeyUp(e: MyKeyboardEvent): void { if (e.keyCodeIsTriggerKey) { this.removeDecorations(); @@ -276,6 +270,12 @@ class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorC } } + private resetHandler(): void { + this.lastMouseMoveEvent = null; + this.hasTriggerKeyOnMouseDown = false; + this.removeDecorations(); + } + private isEnabled(mouseEvent: MyMouseEvent, withKey?: MyKeyboardEvent): boolean { return this.editor.getModel() && mouseEvent.isSingleMouseDown && -- GitLab From cc270a155da6278f971881d584ee173cef824d4c Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 24 May 2017 19:36:56 +0200 Subject: [PATCH 0129/1347] Encapsulate opening a link gesture in LinkGesture --- .../browser/goToDeclarationMouse.ts | 194 +++++++++++------- 1 file changed, 118 insertions(+), 76 deletions(-) diff --git a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts index e4d9aa7b6f4..9bc13d23c2b 100644 --- a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts +++ b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts @@ -22,13 +22,14 @@ import { Location, DefinitionProviderRegistry } from 'vs/editor/common/modes'; import { ICodeEditor, IEditorMouseEvent, IMouseTarget, MouseTargetType } from 'vs/editor/browser/editorBrowser'; import { editorContribution } from 'vs/editor/browser/editorBrowserExtensions'; import { getDefinitionsAtPosition } from './goToDeclaration'; -import { IDisposable, dispose } from 'vs/base/common/lifecycle'; +import { IDisposable, dispose, Disposable } from 'vs/base/common/lifecycle'; import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; import { ICursorSelectionChangedEvent } from 'vs/editor/common/controller/cursorEvents'; import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; import { editorActiveLinkForeground } from 'vs/platform/theme/common/colorRegistry'; import { EditorState, CodeEditorStateFlag } from 'vs/editor/common/core/editorState'; import { DefinitionAction, DefinitionActionConfig } from './goToDeclarationCommands'; +import Event, { Emitter } from 'vs/base/common/event'; /** * An event that encapsulates the various trigger modifiers logic needed for go to definition. @@ -38,13 +39,13 @@ class MyMouseEvent { public readonly target: IMouseTarget; public readonly hasTriggerModifier: boolean; public readonly hasSideBySideModifier: boolean; - public readonly isSingleMouseDown: boolean; + public readonly isNoneOrSingleMouseDown: boolean; constructor(source: IEditorMouseEvent) { this.target = source.target; this.hasTriggerModifier = !!source.event[GotoDefinitionWithMouseEditorContribution.TRIGGER_MODIFIER]; this.hasSideBySideModifier = source.event.altKey; - this.isSingleMouseDown = (browser.isIE || source.event.detail <= 1); // IE does not support event.detail properly + this.isNoneOrSingleMouseDown = (browser.isIE || source.event.detail <= 1); // IE does not support event.detail properly } } @@ -64,6 +65,99 @@ class MyKeyboardEvent { } } +class LinkGesture extends Disposable { + + private readonly editor: ICodeEditor; + + private lastMouseMoveEvent: MyMouseEvent; + private hasTriggerKeyOnMouseDown: boolean; + + private readonly _onMouseMoveOrRelevantKeyDown: Emitter<[MyMouseEvent, MyKeyboardEvent]> = this._register(new Emitter<[MyMouseEvent, MyKeyboardEvent]>()); + public readonly onMouseMoveOrRelevantKeyDown: Event<[MyMouseEvent, MyKeyboardEvent]> = this._onMouseMoveOrRelevantKeyDown.event; + + private readonly _onExecute: Emitter = this._register(new Emitter()); + public readonly onExecute: Event = this._onExecute.event; + + private readonly _onCancel: Emitter = this._register(new Emitter()); + public readonly onCancel: Event = this._onCancel.event; + + constructor(editor: ICodeEditor) { + super(); + + this.editor = editor; + this.lastMouseMoveEvent = null; + this.hasTriggerKeyOnMouseDown = false; + + this._register(this.editor.onMouseMove((e: IEditorMouseEvent) => this.onEditorMouseMove(new MyMouseEvent(e)))); + this._register(this.editor.onMouseDown((e: IEditorMouseEvent) => this.onEditorMouseDown(new MyMouseEvent(e)))); + this._register(this.editor.onMouseUp((e: IEditorMouseEvent) => this.onEditorMouseUp(new MyMouseEvent(e)))); + this._register(this.editor.onKeyDown((e: IKeyboardEvent) => this.onEditorKeyDown(new MyKeyboardEvent(e)))); + this._register(this.editor.onKeyUp((e: IKeyboardEvent) => this.onEditorKeyUp(new MyKeyboardEvent(e)))); + this._register(this.editor.onMouseDrag(() => this.resetHandler())); + + this._register(this.editor.onDidChangeCursorSelection((e) => this.onDidChangeCursorSelection(e))); + this._register(this.editor.onDidChangeModel((e) => this.resetHandler())); + this._register(this.editor.onDidChangeModelContent(() => this.resetHandler())); + this._register(this.editor.onDidScrollChange((e) => { + if (e.scrollTopChanged || e.scrollLeftChanged) { + this.resetHandler(); + } + })); + } + + private onDidChangeCursorSelection(e: ICursorSelectionChangedEvent): void { + if (e.selection && e.selection.startColumn !== e.selection.endColumn) { + this.resetHandler(); // immediately stop this feature if the user starts to select (https://github.com/Microsoft/vscode/issues/7827) + } + } + + private onEditorMouseMove(mouseEvent: MyMouseEvent): void { + this.lastMouseMoveEvent = mouseEvent; + + this._onMouseMoveOrRelevantKeyDown.fire([mouseEvent, null]); + } + + private onEditorMouseDown(mouseEvent: MyMouseEvent): void { + // We need to record if we had the trigger key on mouse down because someone might select something in the editor + // holding the mouse down and then while mouse is down start to press Ctrl/Cmd to start a copy operation and then + // release the mouse button without wanting to do the navigation. + // With this flag we prevent goto definition if the mouse was down before the trigger key was pressed. + this.hasTriggerKeyOnMouseDown = mouseEvent.hasTriggerModifier; + } + + private onEditorMouseUp(mouseEvent: MyMouseEvent): void { + if (this.hasTriggerKeyOnMouseDown) { + this._onExecute.fire(mouseEvent); + } + } + + private onEditorKeyDown(e: MyKeyboardEvent): void { + if ( + this.lastMouseMoveEvent + && ( + e.keyCodeIsTriggerKey // User just pressed Ctrl/Cmd (normal goto definition) + || (e.keyCodeIsSideBySideKey && e.hasTriggerModifier) // User pressed Ctrl/Cmd+Alt (goto definition to the side) + ) + ) { + this._onMouseMoveOrRelevantKeyDown.fire([this.lastMouseMoveEvent, e]); + } else if (e.hasTriggerModifier) { + this._onCancel.fire(); // remove decorations if user holds another key with ctrl/cmd to prevent accident goto declaration + } + } + + private onEditorKeyUp(e: MyKeyboardEvent): void { + if (e.keyCodeIsTriggerKey) { + this._onCancel.fire(); + } + } + + private resetHandler(): void { + this.lastMouseMoveEvent = null; + this.hasTriggerKeyOnMouseDown = false; + this._onCancel.fire(); + } +} + @editorContribution class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorContribution { @@ -78,8 +172,6 @@ class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorC private decorations: string[]; private currentWordUnderMouse: editorCommon.IWordAtPosition; private throttler: Throttler; - private lastMouseMoveEvent: MyMouseEvent; - private hasTriggerKeyOnMouseDown: boolean; constructor( editor: ICodeEditor, @@ -91,27 +183,29 @@ class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorC this.editor = editor; this.throttler = new Throttler(); - this.toUnhook.push(this.editor.onMouseMove((e: IEditorMouseEvent) => this.onEditorMouseMove(new MyMouseEvent(e)))); - this.toUnhook.push(this.editor.onMouseDown((e: IEditorMouseEvent) => this.onEditorMouseDown(new MyMouseEvent(e)))); - this.toUnhook.push(this.editor.onMouseUp((e: IEditorMouseEvent) => this.onEditorMouseUp(new MyMouseEvent(e)))); - this.toUnhook.push(this.editor.onKeyDown((e: IKeyboardEvent) => this.onEditorKeyDown(new MyKeyboardEvent(e)))); - this.toUnhook.push(this.editor.onKeyUp((e: IKeyboardEvent) => this.onEditorKeyUp(new MyKeyboardEvent(e)))); - this.toUnhook.push(this.editor.onMouseDrag(() => this.resetHandler())); - - this.toUnhook.push(this.editor.onDidChangeCursorSelection((e) => this.onDidChangeCursorSelection(e))); - this.toUnhook.push(this.editor.onDidChangeModel((e) => this.resetHandler())); - this.toUnhook.push(this.editor.onDidChangeModelContent(() => this.resetHandler())); - this.toUnhook.push(this.editor.onDidScrollChange((e) => { - if (e.scrollTopChanged || e.scrollLeftChanged) { - this.resetHandler(); + let linkGesture = new LinkGesture(editor); + this.toUnhook.push(linkGesture); + + this.toUnhook.push(linkGesture.onMouseMoveOrRelevantKeyDown(([mouseEvent, keyboardEvent]) => { + this.startFindDefinition(mouseEvent, keyboardEvent); + })); + + this.toUnhook.push(linkGesture.onExecute((mouseEvent: MyMouseEvent) => { + if (this.isEnabled(mouseEvent)) { + this.gotoDefinition(mouseEvent.target, mouseEvent.hasSideBySideModifier).done(() => { + this.removeDecorations(); + }, (error: Error) => { + this.removeDecorations(); + onUnexpectedError(error); + }); } })); - } - private onDidChangeCursorSelection(e: ICursorSelectionChangedEvent): void { - if (e.selection && e.selection.startColumn !== e.selection.endColumn) { - this.resetHandler(); // immediately stop this feature if the user starts to select (https://github.com/Microsoft/vscode/issues/7827) - } + this.toUnhook.push(linkGesture.onCancel(() => { + this.removeDecorations(); + this.currentWordUnderMouse = null; + })); + } private startFindDefinition(mouseEvent: MyMouseEvent, withKey?: MyKeyboardEvent): void { @@ -224,61 +318,9 @@ class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorC } } - private onEditorMouseMove(mouseEvent: MyMouseEvent): void { - this.lastMouseMoveEvent = mouseEvent; - - this.startFindDefinition(mouseEvent); - } - - private onEditorMouseDown(mouseEvent: MyMouseEvent): void { - // We need to record if we had the trigger key on mouse down because someone might select something in the editor - // holding the mouse down and then while mouse is down start to press Ctrl/Cmd to start a copy operation and then - // release the mouse button without wanting to do the navigation. - // With this flag we prevent goto definition if the mouse was down before the trigger key was pressed. - this.hasTriggerKeyOnMouseDown = mouseEvent.hasTriggerModifier; - } - - private onEditorMouseUp(mouseEvent: MyMouseEvent): void { - if (this.isEnabled(mouseEvent) && this.hasTriggerKeyOnMouseDown) { - this.gotoDefinition(mouseEvent.target, mouseEvent.hasSideBySideModifier).done(() => { - this.removeDecorations(); - }, (error: Error) => { - this.removeDecorations(); - onUnexpectedError(error); - }); - } - } - - private onEditorKeyDown(e: MyKeyboardEvent): void { - if ( - this.lastMouseMoveEvent - && ( - e.keyCodeIsTriggerKey // User just pressed Ctrl/Cmd (normal goto definition) - || (e.keyCodeIsSideBySideKey && e.hasTriggerModifier) // User pressed Ctrl/Cmd+Alt (goto definition to the side) - ) - ) { - this.startFindDefinition(this.lastMouseMoveEvent, e); - } else if (e.hasTriggerModifier) { - this.removeDecorations(); // remove decorations if user holds another key with ctrl/cmd to prevent accident goto declaration - } - } - - private onEditorKeyUp(e: MyKeyboardEvent): void { - if (e.keyCodeIsTriggerKey) { - this.removeDecorations(); - this.currentWordUnderMouse = null; - } - } - - private resetHandler(): void { - this.lastMouseMoveEvent = null; - this.hasTriggerKeyOnMouseDown = false; - this.removeDecorations(); - } - private isEnabled(mouseEvent: MyMouseEvent, withKey?: MyKeyboardEvent): boolean { return this.editor.getModel() && - mouseEvent.isSingleMouseDown && + mouseEvent.isNoneOrSingleMouseDown && mouseEvent.target.type === MouseTargetType.CONTENT_TEXT && (mouseEvent.hasTriggerModifier || (withKey && withKey.keyCodeIsTriggerKey)) && DefinitionProviderRegistry.has(this.editor.getModel()); -- GitLab From 647f1d5fc9be786719e723abf4f34c82bcaf4087 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 24 May 2017 20:34:46 +0200 Subject: [PATCH 0130/1347] Extract clicking link logic to its own file --- .../browser/clickLinkGesture.ts | 158 ++++++++++++++++++ .../browser/goToDeclarationMouse.ts | 150 ++--------------- 2 files changed, 170 insertions(+), 138 deletions(-) create mode 100644 src/vs/editor/contrib/goToDeclaration/browser/clickLinkGesture.ts diff --git a/src/vs/editor/contrib/goToDeclaration/browser/clickLinkGesture.ts b/src/vs/editor/contrib/goToDeclaration/browser/clickLinkGesture.ts new file mode 100644 index 00000000000..bec68dcf19a --- /dev/null +++ b/src/vs/editor/contrib/goToDeclaration/browser/clickLinkGesture.ts @@ -0,0 +1,158 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +'use strict'; + +import 'vs/css!./goToDeclarationMouse'; +import { KeyCode } from 'vs/base/common/keyCodes'; +import * as browser from 'vs/base/browser/browser'; +import { IKeyboardEvent } from 'vs/base/browser/keyboardEvent'; +import { ICodeEditor, IEditorMouseEvent, IMouseTarget } from 'vs/editor/browser/editorBrowser'; +import { Disposable } from 'vs/base/common/lifecycle'; +import { ICursorSelectionChangedEvent } from 'vs/editor/common/controller/cursorEvents'; +import Event, { Emitter } from 'vs/base/common/event'; + +/** + * An event that encapsulates the various trigger modifiers logic needed for go to definition. + */ +export class ClickLinkMouseEvent { + + public readonly target: IMouseTarget; + public readonly hasTriggerModifier: boolean; + public readonly hasSideBySideModifier: boolean; + public readonly isNoneOrSingleMouseDown: boolean; + + constructor(source: IEditorMouseEvent, opts: ClickLinkOptions) { + this.target = source.target; + this.hasTriggerModifier = !!source.event[opts.triggerModifier]; + this.hasSideBySideModifier = source.event.altKey; + this.isNoneOrSingleMouseDown = (browser.isIE || source.event.detail <= 1); // IE does not support event.detail properly + } +} + +/** + * An event that encapsulates the various trigger modifiers logic needed for go to definition. + */ +export class ClickLinkKeyboardEvent { + + public readonly keyCodeIsTriggerKey: boolean; + public readonly keyCodeIsSideBySideKey: boolean; + public readonly hasTriggerModifier: boolean; + + constructor(source: IKeyboardEvent, opts: ClickLinkOptions) { + this.keyCodeIsTriggerKey = (source.keyCode === opts.triggerKey); + this.keyCodeIsSideBySideKey = (source.keyCode === opts.triggerSideBySideKey); + this.hasTriggerModifier = !!source[opts.triggerModifier]; + } +} + +export class ClickLinkOptions { + + public readonly triggerKey: KeyCode; + public readonly triggerModifier: 'ctrlKey' | 'shiftKey' | 'altKey' | 'metaKey'; + public readonly triggerSideBySideKey: KeyCode; + + constructor(triggerKey: KeyCode, triggerModifier: 'ctrlKey' | 'shiftKey' | 'altKey' | 'metaKey', triggerSideBySideKey: KeyCode) { + this.triggerKey = triggerKey; + this.triggerModifier = triggerModifier; + this.triggerSideBySideKey = triggerSideBySideKey; + } +} + +export class ClickLinkGesture extends Disposable { + + private readonly _onMouseMoveOrRelevantKeyDown: Emitter<[ClickLinkMouseEvent, ClickLinkKeyboardEvent]> = this._register(new Emitter<[ClickLinkMouseEvent, ClickLinkKeyboardEvent]>()); + public readonly onMouseMoveOrRelevantKeyDown: Event<[ClickLinkMouseEvent, ClickLinkKeyboardEvent]> = this._onMouseMoveOrRelevantKeyDown.event; + + private readonly _onExecute: Emitter = this._register(new Emitter()); + public readonly onExecute: Event = this._onExecute.event; + + private readonly _onCancel: Emitter = this._register(new Emitter()); + public readonly onCancel: Event = this._onCancel.event; + + private readonly _editor: ICodeEditor; + private readonly _opts: ClickLinkOptions; + + private lastMouseMoveEvent: ClickLinkMouseEvent; + private hasTriggerKeyOnMouseDown: boolean; + + constructor(editor: ICodeEditor, opts: ClickLinkOptions) { + super(); + + this._editor = editor; + this._opts = opts; + + this.lastMouseMoveEvent = null; + this.hasTriggerKeyOnMouseDown = false; + + this._register(this._editor.onMouseMove((e: IEditorMouseEvent) => this.onEditorMouseMove(new ClickLinkMouseEvent(e, this._opts)))); + this._register(this._editor.onMouseDown((e: IEditorMouseEvent) => this.onEditorMouseDown(new ClickLinkMouseEvent(e, this._opts)))); + this._register(this._editor.onMouseUp((e: IEditorMouseEvent) => this.onEditorMouseUp(new ClickLinkMouseEvent(e, this._opts)))); + this._register(this._editor.onKeyDown((e: IKeyboardEvent) => this.onEditorKeyDown(new ClickLinkKeyboardEvent(e, this._opts)))); + this._register(this._editor.onKeyUp((e: IKeyboardEvent) => this.onEditorKeyUp(new ClickLinkKeyboardEvent(e, this._opts)))); + this._register(this._editor.onMouseDrag(() => this.resetHandler())); + + this._register(this._editor.onDidChangeCursorSelection((e) => this.onDidChangeCursorSelection(e))); + this._register(this._editor.onDidChangeModel((e) => this.resetHandler())); + this._register(this._editor.onDidChangeModelContent(() => this.resetHandler())); + this._register(this._editor.onDidScrollChange((e) => { + if (e.scrollTopChanged || e.scrollLeftChanged) { + this.resetHandler(); + } + })); + } + + private onDidChangeCursorSelection(e: ICursorSelectionChangedEvent): void { + if (e.selection && e.selection.startColumn !== e.selection.endColumn) { + this.resetHandler(); // immediately stop this feature if the user starts to select (https://github.com/Microsoft/vscode/issues/7827) + } + } + + private onEditorMouseMove(mouseEvent: ClickLinkMouseEvent): void { + this.lastMouseMoveEvent = mouseEvent; + + this._onMouseMoveOrRelevantKeyDown.fire([mouseEvent, null]); + } + + private onEditorMouseDown(mouseEvent: ClickLinkMouseEvent): void { + // We need to record if we had the trigger key on mouse down because someone might select something in the editor + // holding the mouse down and then while mouse is down start to press Ctrl/Cmd to start a copy operation and then + // release the mouse button without wanting to do the navigation. + // With this flag we prevent goto definition if the mouse was down before the trigger key was pressed. + this.hasTriggerKeyOnMouseDown = mouseEvent.hasTriggerModifier; + } + + private onEditorMouseUp(mouseEvent: ClickLinkMouseEvent): void { + if (this.hasTriggerKeyOnMouseDown) { + this._onExecute.fire(mouseEvent); + } + } + + private onEditorKeyDown(e: ClickLinkKeyboardEvent): void { + if ( + this.lastMouseMoveEvent + && ( + e.keyCodeIsTriggerKey // User just pressed Ctrl/Cmd (normal goto definition) + || (e.keyCodeIsSideBySideKey && e.hasTriggerModifier) // User pressed Ctrl/Cmd+Alt (goto definition to the side) + ) + ) { + this._onMouseMoveOrRelevantKeyDown.fire([this.lastMouseMoveEvent, e]); + } else if (e.hasTriggerModifier) { + this._onCancel.fire(); // remove decorations if user holds another key with ctrl/cmd to prevent accident goto declaration + } + } + + private onEditorKeyUp(e: ClickLinkKeyboardEvent): void { + if (e.keyCodeIsTriggerKey) { + this._onCancel.fire(); + } + } + + private resetHandler(): void { + this.lastMouseMoveEvent = null; + this.hasTriggerKeyOnMouseDown = false; + this._onCancel.fire(); + } +} diff --git a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts index 9bc13d23c2b..e063801f2d9 100644 --- a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts +++ b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts @@ -13,156 +13,26 @@ import { MarkedString } from 'vs/base/common/htmlContent'; import { KeyCode } from 'vs/base/common/keyCodes'; import * as platform from 'vs/base/common/platform'; import { TPromise } from 'vs/base/common/winjs.base'; -import * as browser from 'vs/base/browser/browser'; -import { IKeyboardEvent } from 'vs/base/browser/keyboardEvent'; import { IModeService } from 'vs/editor/common/services/modeService'; import { Range } from 'vs/editor/common/core/range'; import * as editorCommon from 'vs/editor/common/editorCommon'; import { Location, DefinitionProviderRegistry } from 'vs/editor/common/modes'; -import { ICodeEditor, IEditorMouseEvent, IMouseTarget, MouseTargetType } from 'vs/editor/browser/editorBrowser'; +import { ICodeEditor, IMouseTarget, MouseTargetType } from 'vs/editor/browser/editorBrowser'; import { editorContribution } from 'vs/editor/browser/editorBrowserExtensions'; import { getDefinitionsAtPosition } from './goToDeclaration'; -import { IDisposable, dispose, Disposable } from 'vs/base/common/lifecycle'; +import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; -import { ICursorSelectionChangedEvent } from 'vs/editor/common/controller/cursorEvents'; import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; import { editorActiveLinkForeground } from 'vs/platform/theme/common/colorRegistry'; import { EditorState, CodeEditorStateFlag } from 'vs/editor/common/core/editorState'; import { DefinitionAction, DefinitionActionConfig } from './goToDeclarationCommands'; -import Event, { Emitter } from 'vs/base/common/event'; - -/** - * An event that encapsulates the various trigger modifiers logic needed for go to definition. - */ -class MyMouseEvent { - - public readonly target: IMouseTarget; - public readonly hasTriggerModifier: boolean; - public readonly hasSideBySideModifier: boolean; - public readonly isNoneOrSingleMouseDown: boolean; - - constructor(source: IEditorMouseEvent) { - this.target = source.target; - this.hasTriggerModifier = !!source.event[GotoDefinitionWithMouseEditorContribution.TRIGGER_MODIFIER]; - this.hasSideBySideModifier = source.event.altKey; - this.isNoneOrSingleMouseDown = (browser.isIE || source.event.detail <= 1); // IE does not support event.detail properly - } -} - -/** - * An event that encapsulates the various trigger modifiers logic needed for go to definition. - */ -class MyKeyboardEvent { - - public readonly keyCodeIsTriggerKey: boolean; - public readonly keyCodeIsSideBySideKey: boolean; - public readonly hasTriggerModifier: boolean; - - constructor(source: IKeyboardEvent) { - this.keyCodeIsTriggerKey = (source.keyCode === GotoDefinitionWithMouseEditorContribution.TRIGGER_KEY_VALUE); - this.keyCodeIsSideBySideKey = (source.keyCode === GotoDefinitionWithMouseEditorContribution.TRIGGER_SIDEBYSIDE_KEY_VALUE); - this.hasTriggerModifier = !!source[GotoDefinitionWithMouseEditorContribution.TRIGGER_MODIFIER]; - } -} - -class LinkGesture extends Disposable { - - private readonly editor: ICodeEditor; - - private lastMouseMoveEvent: MyMouseEvent; - private hasTriggerKeyOnMouseDown: boolean; - - private readonly _onMouseMoveOrRelevantKeyDown: Emitter<[MyMouseEvent, MyKeyboardEvent]> = this._register(new Emitter<[MyMouseEvent, MyKeyboardEvent]>()); - public readonly onMouseMoveOrRelevantKeyDown: Event<[MyMouseEvent, MyKeyboardEvent]> = this._onMouseMoveOrRelevantKeyDown.event; - - private readonly _onExecute: Emitter = this._register(new Emitter()); - public readonly onExecute: Event = this._onExecute.event; - - private readonly _onCancel: Emitter = this._register(new Emitter()); - public readonly onCancel: Event = this._onCancel.event; - - constructor(editor: ICodeEditor) { - super(); - - this.editor = editor; - this.lastMouseMoveEvent = null; - this.hasTriggerKeyOnMouseDown = false; - - this._register(this.editor.onMouseMove((e: IEditorMouseEvent) => this.onEditorMouseMove(new MyMouseEvent(e)))); - this._register(this.editor.onMouseDown((e: IEditorMouseEvent) => this.onEditorMouseDown(new MyMouseEvent(e)))); - this._register(this.editor.onMouseUp((e: IEditorMouseEvent) => this.onEditorMouseUp(new MyMouseEvent(e)))); - this._register(this.editor.onKeyDown((e: IKeyboardEvent) => this.onEditorKeyDown(new MyKeyboardEvent(e)))); - this._register(this.editor.onKeyUp((e: IKeyboardEvent) => this.onEditorKeyUp(new MyKeyboardEvent(e)))); - this._register(this.editor.onMouseDrag(() => this.resetHandler())); - - this._register(this.editor.onDidChangeCursorSelection((e) => this.onDidChangeCursorSelection(e))); - this._register(this.editor.onDidChangeModel((e) => this.resetHandler())); - this._register(this.editor.onDidChangeModelContent(() => this.resetHandler())); - this._register(this.editor.onDidScrollChange((e) => { - if (e.scrollTopChanged || e.scrollLeftChanged) { - this.resetHandler(); - } - })); - } - - private onDidChangeCursorSelection(e: ICursorSelectionChangedEvent): void { - if (e.selection && e.selection.startColumn !== e.selection.endColumn) { - this.resetHandler(); // immediately stop this feature if the user starts to select (https://github.com/Microsoft/vscode/issues/7827) - } - } - - private onEditorMouseMove(mouseEvent: MyMouseEvent): void { - this.lastMouseMoveEvent = mouseEvent; - - this._onMouseMoveOrRelevantKeyDown.fire([mouseEvent, null]); - } - - private onEditorMouseDown(mouseEvent: MyMouseEvent): void { - // We need to record if we had the trigger key on mouse down because someone might select something in the editor - // holding the mouse down and then while mouse is down start to press Ctrl/Cmd to start a copy operation and then - // release the mouse button without wanting to do the navigation. - // With this flag we prevent goto definition if the mouse was down before the trigger key was pressed. - this.hasTriggerKeyOnMouseDown = mouseEvent.hasTriggerModifier; - } - - private onEditorMouseUp(mouseEvent: MyMouseEvent): void { - if (this.hasTriggerKeyOnMouseDown) { - this._onExecute.fire(mouseEvent); - } - } - - private onEditorKeyDown(e: MyKeyboardEvent): void { - if ( - this.lastMouseMoveEvent - && ( - e.keyCodeIsTriggerKey // User just pressed Ctrl/Cmd (normal goto definition) - || (e.keyCodeIsSideBySideKey && e.hasTriggerModifier) // User pressed Ctrl/Cmd+Alt (goto definition to the side) - ) - ) { - this._onMouseMoveOrRelevantKeyDown.fire([this.lastMouseMoveEvent, e]); - } else if (e.hasTriggerModifier) { - this._onCancel.fire(); // remove decorations if user holds another key with ctrl/cmd to prevent accident goto declaration - } - } - - private onEditorKeyUp(e: MyKeyboardEvent): void { - if (e.keyCodeIsTriggerKey) { - this._onCancel.fire(); - } - } - - private resetHandler(): void { - this.lastMouseMoveEvent = null; - this.hasTriggerKeyOnMouseDown = false; - this._onCancel.fire(); - } -} +import { ClickLinkGesture, ClickLinkOptions, ClickLinkMouseEvent, ClickLinkKeyboardEvent } from "vs/editor/contrib/goToDeclaration/browser/clickLinkGesture"; @editorContribution class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorContribution { private static ID = 'editor.contrib.gotodefinitionwithmouse'; - static TRIGGER_MODIFIER = platform.isMacintosh ? 'metaKey' : 'ctrlKey'; + static TRIGGER_MODIFIER: 'metaKey' | 'ctrlKey' = platform.isMacintosh ? 'metaKey' : 'ctrlKey'; static TRIGGER_SIDEBYSIDE_KEY_VALUE = KeyCode.Alt; static TRIGGER_KEY_VALUE = platform.isMacintosh ? KeyCode.Meta : KeyCode.Ctrl; static MAX_SOURCE_PREVIEW_LINES = 8; @@ -183,14 +53,18 @@ class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorC this.editor = editor; this.throttler = new Throttler(); - let linkGesture = new LinkGesture(editor); + let linkGesture = new ClickLinkGesture(editor, new ClickLinkOptions( + GotoDefinitionWithMouseEditorContribution.TRIGGER_KEY_VALUE, + GotoDefinitionWithMouseEditorContribution.TRIGGER_MODIFIER, + GotoDefinitionWithMouseEditorContribution.TRIGGER_SIDEBYSIDE_KEY_VALUE + )); this.toUnhook.push(linkGesture); this.toUnhook.push(linkGesture.onMouseMoveOrRelevantKeyDown(([mouseEvent, keyboardEvent]) => { this.startFindDefinition(mouseEvent, keyboardEvent); })); - this.toUnhook.push(linkGesture.onExecute((mouseEvent: MyMouseEvent) => { + this.toUnhook.push(linkGesture.onExecute((mouseEvent: ClickLinkMouseEvent) => { if (this.isEnabled(mouseEvent)) { this.gotoDefinition(mouseEvent.target, mouseEvent.hasSideBySideModifier).done(() => { this.removeDecorations(); @@ -208,7 +82,7 @@ class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorC } - private startFindDefinition(mouseEvent: MyMouseEvent, withKey?: MyKeyboardEvent): void { + private startFindDefinition(mouseEvent: ClickLinkMouseEvent, withKey?: ClickLinkKeyboardEvent): void { if (!this.isEnabled(mouseEvent, withKey)) { this.currentWordUnderMouse = null; this.removeDecorations(); @@ -318,7 +192,7 @@ class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorC } } - private isEnabled(mouseEvent: MyMouseEvent, withKey?: MyKeyboardEvent): boolean { + private isEnabled(mouseEvent: ClickLinkMouseEvent, withKey?: ClickLinkKeyboardEvent): boolean { return this.editor.getModel() && mouseEvent.isNoneOrSingleMouseDown && mouseEvent.target.type === MouseTargetType.CONTENT_TEXT && -- GitLab From bf4d419b797f2783578bc793f50a2c2caa508cfb Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 24 May 2017 22:32:38 +0200 Subject: [PATCH 0131/1347] Fixes #6910: Left mouse button up when selecting text with CTRL pressed causes to follow link --- src/vs/editor/contrib/links/browser/links.ts | 60 ++++++++++---------- 1 file changed, 30 insertions(+), 30 deletions(-) diff --git a/src/vs/editor/contrib/links/browser/links.ts b/src/vs/editor/contrib/links/browser/links.ts index 44f1d2fb3bd..c14eaf2d911 100644 --- a/src/vs/editor/contrib/links/browser/links.ts +++ b/src/vs/editor/contrib/links/browser/links.ts @@ -12,14 +12,13 @@ import { KeyCode } from 'vs/base/common/keyCodes'; import * as platform from 'vs/base/common/platform'; import Severity from 'vs/base/common/severity'; import { TPromise } from 'vs/base/common/winjs.base'; -import { IKeyboardEvent } from 'vs/base/browser/keyboardEvent'; import { IMessageService } from 'vs/platform/message/common/message'; import { IOpenerService } from 'vs/platform/opener/common/opener'; import * as editorCommon from 'vs/editor/common/editorCommon'; import { editorAction, ServicesAccessor, EditorAction } from 'vs/editor/common/editorCommonExtensions'; import { LinkProviderRegistry } from 'vs/editor/common/modes'; import { IEditorWorkerService } from 'vs/editor/common/services/editorWorkerService'; -import { IEditorMouseEvent, ICodeEditor, MouseTargetType } from 'vs/editor/browser/editorBrowser'; +import { ICodeEditor, MouseTargetType } from 'vs/editor/browser/editorBrowser'; import { getLinks, Link } from 'vs/editor/contrib/links/common/links'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { editorContribution } from 'vs/editor/browser/editorBrowserExtensions'; @@ -27,6 +26,7 @@ import { registerThemingParticipant } from 'vs/platform/theme/common/themeServic import { editorActiveLinkForeground } from 'vs/platform/theme/common/colorRegistry'; import { Position } from 'vs/editor/common/core/position'; import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ClickLinkGesture, ClickLinkOptions, ClickLinkMouseEvent, ClickLinkKeyboardEvent } from "vs/editor/contrib/goToDeclaration/browser/clickLinkGesture"; const HOVER_MESSAGE_GENERAL = ( platform.isMacintosh @@ -67,7 +67,7 @@ class LinkOccurence { public decorationId: string; public link: Link; - constructor(link: Link, decorationId: string/*, changeAccessor:editorCommon.IModelDecorationsChangeAccessor*/) { + constructor(link: Link, decorationId: string) { this.link = link; this.decorationId = decorationId; } @@ -92,14 +92,13 @@ class LinkDetector implements editorCommon.IEditorContribution { static RECOMPUTE_TIME = 1000; // ms static TRIGGER_KEY_VALUE = platform.isMacintosh ? KeyCode.Meta : KeyCode.Ctrl; - static TRIGGER_MODIFIER = platform.isMacintosh ? 'metaKey' : 'ctrlKey'; + static TRIGGER_MODIFIER: 'metaKey' | 'ctrlKey' = platform.isMacintosh ? 'metaKey' : 'ctrlKey'; private editor: ICodeEditor; private listenersToRemove: IDisposable[]; private timeoutPromise: TPromise; private computePromise: TPromise; private activeLinkDecorationId: string; - private lastMouseEvent: IEditorMouseEvent; private openerService: IOpenerService; private messageService: IMessageService; private editorWorkerService: IEditorWorkerService; @@ -116,14 +115,28 @@ class LinkDetector implements editorCommon.IEditorContribution { this.messageService = messageService; this.editorWorkerService = editorWorkerService; this.listenersToRemove = []; + + let clickLinkGesture = new ClickLinkGesture(editor, new ClickLinkOptions( + LinkDetector.TRIGGER_KEY_VALUE, + LinkDetector.TRIGGER_MODIFIER, + KeyCode.Alt + )); + this.listenersToRemove.push(clickLinkGesture); + this.listenersToRemove.push(clickLinkGesture.onMouseMoveOrRelevantKeyDown(([mouseEvent, keyboardEvent]) => { + this._onEditorMouseMove(mouseEvent, keyboardEvent); + })); + this.listenersToRemove.push(clickLinkGesture.onExecute((e) => { + this.onEditorMouseUp(e); + })); + this.listenersToRemove.push(clickLinkGesture.onCancel((e) => { + this.cleanUpActiveLinkDecoration(); + })); + this.listenersToRemove.push(editor.onDidChangeModelContent((e) => this.onChange())); this.listenersToRemove.push(editor.onDidChangeModel((e) => this.onModelChanged())); this.listenersToRemove.push(editor.onDidChangeModelLanguage((e) => this.onModelModeChanged())); this.listenersToRemove.push(LinkProviderRegistry.onDidChange((e) => this.onModelModeChanged())); - this.listenersToRemove.push(this.editor.onMouseUp((e: IEditorMouseEvent) => this.onEditorMouseUp(e))); - this.listenersToRemove.push(this.editor.onMouseMove((e: IEditorMouseEvent) => this.onEditorMouseMove(e))); - this.listenersToRemove.push(this.editor.onKeyDown((e: IKeyboardEvent) => this.onEditorKeyDown(e))); - this.listenersToRemove.push(this.editor.onKeyUp((e: IKeyboardEvent) => this.onEditorKeyUp(e))); + this.timeoutPromise = null; this.computePromise = null; this.currentOccurences = {}; @@ -140,7 +153,6 @@ class LinkDetector implements editorCommon.IEditorContribution { } private onModelChanged(): void { - this.lastMouseEvent = null; this.currentOccurences = {}; this.activeLinkDecorationId = null; this.stop(); @@ -206,21 +218,7 @@ class LinkDetector implements editorCommon.IEditorContribution { }); } - private onEditorKeyDown(e: IKeyboardEvent): void { - if (e.keyCode === LinkDetector.TRIGGER_KEY_VALUE && this.lastMouseEvent) { - this.onEditorMouseMove(this.lastMouseEvent, e); - } - } - - private onEditorKeyUp(e: IKeyboardEvent): void { - if (e.keyCode === LinkDetector.TRIGGER_KEY_VALUE) { - this.cleanUpActiveLinkDecoration(); - } - } - - private onEditorMouseMove(mouseEvent: IEditorMouseEvent, withKey?: IKeyboardEvent): void { - this.lastMouseEvent = mouseEvent; - + private _onEditorMouseMove(mouseEvent: ClickLinkMouseEvent, withKey?: ClickLinkKeyboardEvent): void { if (this.isEnabled(mouseEvent, withKey)) { this.cleanUpActiveLinkDecoration(); // always remove previous link decoration as their can only be one var occurence = this.getLinkOccurence(mouseEvent.target.position); @@ -248,7 +246,7 @@ class LinkDetector implements editorCommon.IEditorContribution { } } - private onEditorMouseUp(mouseEvent: IEditorMouseEvent): void { + private onEditorMouseUp(mouseEvent: ClickLinkMouseEvent): void { if (!this.isEnabled(mouseEvent)) { return; } @@ -256,7 +254,7 @@ class LinkDetector implements editorCommon.IEditorContribution { if (!occurence) { return; } - this.openLinkOccurence(occurence, mouseEvent.event.altKey); + this.openLinkOccurence(occurence, mouseEvent.hasSideBySideModifier); } public openLinkOccurence(occurence: LinkOccurence, openToSide: boolean): void { @@ -302,9 +300,11 @@ class LinkDetector implements editorCommon.IEditorContribution { return null; } - private isEnabled(mouseEvent: IEditorMouseEvent, withKey?: IKeyboardEvent): boolean { - return mouseEvent.target.type === MouseTargetType.CONTENT_TEXT && - (mouseEvent.event[LinkDetector.TRIGGER_MODIFIER] || (withKey && withKey.keyCode === LinkDetector.TRIGGER_KEY_VALUE)); + private isEnabled(mouseEvent: ClickLinkMouseEvent, withKey?: ClickLinkKeyboardEvent): boolean { + return ( + mouseEvent.target.type === MouseTargetType.CONTENT_TEXT + && (mouseEvent.hasTriggerModifier || (withKey && withKey.keyCodeIsTriggerKey)) + ); } private stop(): void { -- GitLab From 17ea00ea442b951f9b1b6bd910d4dd70a2b7022d Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Thu, 25 May 2017 00:00:54 +0200 Subject: [PATCH 0132/1347] Implement editor.multicursorModifier --- src/vs/editor/browser/view/viewController.ts | 99 +++++++++---------- src/vs/editor/browser/view/viewImpl.ts | 2 +- .../browser/clickLinkGesture.ts | 63 ++++++++++-- .../browser/goToDeclarationMouse.ts | 13 +-- src/vs/editor/contrib/hover/browser/hover.ts | 3 +- src/vs/editor/contrib/links/browser/links.ts | 11 +-- 6 files changed, 110 insertions(+), 81 deletions(-) diff --git a/src/vs/editor/browser/view/viewController.ts b/src/vs/editor/browser/view/viewController.ts index f37a97d9344..e05ca74ea60 100644 --- a/src/vs/editor/browser/view/viewController.ts +++ b/src/vs/editor/browser/view/viewController.ts @@ -12,6 +12,7 @@ import { ICommandService } from 'vs/platform/commands/common/commands'; import { IViewModel } from 'vs/editor/common/viewModel/viewModel'; import { ViewOutgoingEvents } from 'vs/editor/browser/view/viewOutgoingEvents'; import { CoreNavigationCommands, CoreEditorCommand } from 'vs/editor/common/controller/coreCommands'; +import { Configuration } from "vs/editor/browser/config/configuration"; export interface ExecCoreEditorCommandFunc { (editorCommand: CoreEditorCommand, args: any): void; @@ -35,17 +36,20 @@ export interface IMouseDispatchData { export class ViewController { + private readonly configuration: Configuration; private readonly viewModel: IViewModel; private readonly _execCoreEditorCommandFunc: ExecCoreEditorCommandFunc; private readonly outgoingEvents: ViewOutgoingEvents; private readonly commandService: ICommandService; constructor( + configuration: Configuration, viewModel: IViewModel, execCommandFunc: ExecCoreEditorCommandFunc, outgoingEvents: ViewOutgoingEvents, commandService: ICommandService ) { + this.configuration = configuration; this.viewModel = viewModel; this._execCoreEditorCommandFunc = execCommandFunc; this.outgoingEvents = outgoingEvents; @@ -97,10 +101,34 @@ export class ViewController { return viewPosition; } + private _hasMulticursorModifier(data: IMouseDispatchData): boolean { + switch (this.configuration.editor.multicursorModifier) { + case 'altKey': + return data.altKey; + case 'ctrlKey': + return data.ctrlKey; + case 'metaKey': + return data.metaKey; + } + return false; + } + + private _hasNonMulticursorModifier(data: IMouseDispatchData): boolean { + switch (this.configuration.editor.multicursorModifier) { + case 'altKey': + return data.ctrlKey || data.metaKey; + case 'ctrlKey': + return data.altKey || data.metaKey; + case 'metaKey': + return data.ctrlKey || data.altKey; + } + return false; + } + public dispatchMouse(data: IMouseDispatchData): void { if (data.startedOnLineNumbers) { // If the dragging started on the gutter, then have operations work on the entire line - if (data.altKey) { + if (this._hasMulticursorModifier(data)) { if (data.inSelectionMode) { this.lastCursorLineSelect(data.position); } else { @@ -116,7 +144,7 @@ export class ViewController { } else if (data.mouseDownCount >= 4) { this.selectAll(); } else if (data.mouseDownCount === 3) { - if (data.altKey) { + if (this._hasMulticursorModifier(data)) { if (data.inSelectionMode) { this.lastCursorLineSelectDrag(data.position); } else { @@ -130,7 +158,7 @@ export class ViewController { } } } else if (data.mouseDownCount === 2) { - if (data.altKey) { + if (this._hasMulticursorModifier(data)) { this.lastCursorWordSelect(data.position); } else { if (data.inSelectionMode) { @@ -140,8 +168,8 @@ export class ViewController { } } } else { - if (data.altKey) { - if (!data.ctrlKey && !data.metaKey) { + if (this._hasMulticursorModifier(data)) { + if (!this._hasNonMulticursorModifier(data)) { if (data.shiftKey) { this.columnSelect(data.position, data.mouseColumn); } else { @@ -163,20 +191,20 @@ export class ViewController { } } - public moveTo(viewPosition: Position): void { + private _usualArgs(viewPosition: Position) { viewPosition = this._validateViewColumn(viewPosition); - this._execMouseCommand(CoreNavigationCommands.MoveTo, { + return { position: this.convertViewToModelPosition(viewPosition), viewPosition: viewPosition - }); + }; + } + + public moveTo(viewPosition: Position): void { + this._execMouseCommand(CoreNavigationCommands.MoveTo, this._usualArgs(viewPosition)); } private moveToSelect(viewPosition: Position): void { - viewPosition = this._validateViewColumn(viewPosition); - this._execMouseCommand(CoreNavigationCommands.MoveToSelect, { - position: this.convertViewToModelPosition(viewPosition), - viewPosition: viewPosition - }); + this._execMouseCommand(CoreNavigationCommands.MoveToSelect, this._usualArgs(viewPosition)); } private columnSelect(viewPosition: Position, mouseColumn: number): void { @@ -198,64 +226,35 @@ export class ViewController { } private lastCursorMoveToSelect(viewPosition: Position): void { - viewPosition = this._validateViewColumn(viewPosition); - this._execMouseCommand(CoreNavigationCommands.LastCursorMoveToSelect, { - position: this.convertViewToModelPosition(viewPosition), - viewPosition: viewPosition - }); + this._execMouseCommand(CoreNavigationCommands.LastCursorMoveToSelect, this._usualArgs(viewPosition)); } private wordSelect(viewPosition: Position): void { - viewPosition = this._validateViewColumn(viewPosition); - this._execMouseCommand(CoreNavigationCommands.WordSelect, { - position: this.convertViewToModelPosition(viewPosition) - }); + this._execMouseCommand(CoreNavigationCommands.WordSelect, this._usualArgs(viewPosition)); } private wordSelectDrag(viewPosition: Position): void { - viewPosition = this._validateViewColumn(viewPosition); - this._execMouseCommand(CoreNavigationCommands.WordSelectDrag, { - position: this.convertViewToModelPosition(viewPosition) - }); + this._execMouseCommand(CoreNavigationCommands.WordSelectDrag, this._usualArgs(viewPosition)); } private lastCursorWordSelect(viewPosition: Position): void { - viewPosition = this._validateViewColumn(viewPosition); - this._execMouseCommand(CoreNavigationCommands.LastCursorWordSelect, { - position: this.convertViewToModelPosition(viewPosition) - }); + this._execMouseCommand(CoreNavigationCommands.LastCursorWordSelect, this._usualArgs(viewPosition)); } private lineSelect(viewPosition: Position): void { - viewPosition = this._validateViewColumn(viewPosition); - this._execMouseCommand(CoreNavigationCommands.LineSelect, { - position: this.convertViewToModelPosition(viewPosition), - viewPosition: viewPosition - }); + this._execMouseCommand(CoreNavigationCommands.LineSelect, this._usualArgs(viewPosition)); } private lineSelectDrag(viewPosition: Position): void { - viewPosition = this._validateViewColumn(viewPosition); - this._execMouseCommand(CoreNavigationCommands.LineSelectDrag, { - position: this.convertViewToModelPosition(viewPosition), - viewPosition: viewPosition - }); + this._execMouseCommand(CoreNavigationCommands.LineSelectDrag, this._usualArgs(viewPosition)); } private lastCursorLineSelect(viewPosition: Position): void { - viewPosition = this._validateViewColumn(viewPosition); - this._execMouseCommand(CoreNavigationCommands.LastCursorLineSelect, { - position: this.convertViewToModelPosition(viewPosition), - viewPosition: viewPosition - }); + this._execMouseCommand(CoreNavigationCommands.LastCursorLineSelect, this._usualArgs(viewPosition)); } private lastCursorLineSelectDrag(viewPosition: Position): void { - viewPosition = this._validateViewColumn(viewPosition); - this._execMouseCommand(CoreNavigationCommands.LastCursorLineSelectDrag, { - position: this.convertViewToModelPosition(viewPosition), - viewPosition: viewPosition - }); + this._execMouseCommand(CoreNavigationCommands.LastCursorLineSelectDrag, this._usualArgs(viewPosition)); } private selectAll(): void { diff --git a/src/vs/editor/browser/view/viewImpl.ts b/src/vs/editor/browser/view/viewImpl.ts index 321c4719a6d..927c1d19486 100644 --- a/src/vs/editor/browser/view/viewImpl.ts +++ b/src/vs/editor/browser/view/viewImpl.ts @@ -105,7 +105,7 @@ export class View extends ViewEventHandler { this._renderAnimationFrame = null; this.outgoingEvents = new ViewOutgoingEvents(model); - let viewController = new ViewController(model, execCoreEditorCommandFunc, this.outgoingEvents, commandService); + let viewController = new ViewController(configuration, model, execCoreEditorCommandFunc, this.outgoingEvents, commandService); // The event dispatcher will always go through _renderOnce before dispatching any events this.eventDispatcher = new ViewEventDispatcher((callback: () => void) => this._renderOnce(callback)); diff --git a/src/vs/editor/contrib/goToDeclaration/browser/clickLinkGesture.ts b/src/vs/editor/contrib/goToDeclaration/browser/clickLinkGesture.ts index bec68dcf19a..79d1043cf50 100644 --- a/src/vs/editor/contrib/goToDeclaration/browser/clickLinkGesture.ts +++ b/src/vs/editor/contrib/goToDeclaration/browser/clickLinkGesture.ts @@ -13,6 +13,11 @@ import { ICodeEditor, IEditorMouseEvent, IMouseTarget } from 'vs/editor/browser/ import { Disposable } from 'vs/base/common/lifecycle'; import { ICursorSelectionChangedEvent } from 'vs/editor/common/controller/cursorEvents'; import Event, { Emitter } from 'vs/base/common/event'; +import * as platform from 'vs/base/common/platform'; + +function hasModifier(e: { ctrlKey: boolean; shiftKey: boolean; altKey: boolean; metaKey: boolean }, modifier: 'ctrlKey' | 'shiftKey' | 'altKey' | 'metaKey'): boolean { + return !!e[modifier]; +} /** * An event that encapsulates the various trigger modifiers logic needed for go to definition. @@ -26,8 +31,8 @@ export class ClickLinkMouseEvent { constructor(source: IEditorMouseEvent, opts: ClickLinkOptions) { this.target = source.target; - this.hasTriggerModifier = !!source.event[opts.triggerModifier]; - this.hasSideBySideModifier = source.event.altKey; + this.hasTriggerModifier = hasModifier(source.event, opts.triggerModifier); + this.hasSideBySideModifier = hasModifier(source.event, opts.triggerSideBySideModifier); this.isNoneOrSingleMouseDown = (browser.isIE || source.event.detail <= 1); // IE does not support event.detail properly } } @@ -44,7 +49,7 @@ export class ClickLinkKeyboardEvent { constructor(source: IKeyboardEvent, opts: ClickLinkOptions) { this.keyCodeIsTriggerKey = (source.keyCode === opts.triggerKey); this.keyCodeIsSideBySideKey = (source.keyCode === opts.triggerSideBySideKey); - this.hasTriggerModifier = !!source[opts.triggerModifier]; + this.hasTriggerModifier = hasModifier(source, opts.triggerModifier); } } @@ -53,14 +58,44 @@ export class ClickLinkOptions { public readonly triggerKey: KeyCode; public readonly triggerModifier: 'ctrlKey' | 'shiftKey' | 'altKey' | 'metaKey'; public readonly triggerSideBySideKey: KeyCode; - - constructor(triggerKey: KeyCode, triggerModifier: 'ctrlKey' | 'shiftKey' | 'altKey' | 'metaKey', triggerSideBySideKey: KeyCode) { + public readonly triggerSideBySideModifier: 'ctrlKey' | 'shiftKey' | 'altKey' | 'metaKey'; + + constructor( + triggerKey: KeyCode, + triggerModifier: 'ctrlKey' | 'shiftKey' | 'altKey' | 'metaKey', + triggerSideBySideKey: KeyCode, + triggerSideBySideModifier: 'ctrlKey' | 'shiftKey' | 'altKey' | 'metaKey' + ) { this.triggerKey = triggerKey; this.triggerModifier = triggerModifier; this.triggerSideBySideKey = triggerSideBySideKey; + this.triggerSideBySideModifier = triggerSideBySideModifier; + } + + public equals(other: ClickLinkOptions): boolean { + return ( + this.triggerKey === other.triggerKey + && this.triggerModifier === other.triggerModifier + && this.triggerSideBySideKey === other.triggerSideBySideKey + && this.triggerSideBySideModifier === other.triggerSideBySideModifier + ); } } +function createOptions(multicursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'): ClickLinkOptions { + if (multicursorModifier === 'altKey') { + if (platform.isMacintosh) { + return new ClickLinkOptions(KeyCode.Meta, 'metaKey', KeyCode.Alt, 'altKey'); + } + return new ClickLinkOptions(KeyCode.Ctrl, 'ctrlKey', KeyCode.Alt, 'altKey'); + } + + if (platform.isMacintosh) { + return new ClickLinkOptions(KeyCode.Alt, 'altKey', KeyCode.Meta, 'metaKey'); + } + return new ClickLinkOptions(KeyCode.Alt, 'altKey', KeyCode.Ctrl, 'ctrlKey'); +} + export class ClickLinkGesture extends Disposable { private readonly _onMouseMoveOrRelevantKeyDown: Emitter<[ClickLinkMouseEvent, ClickLinkKeyboardEvent]> = this._register(new Emitter<[ClickLinkMouseEvent, ClickLinkKeyboardEvent]>()); @@ -73,20 +108,32 @@ export class ClickLinkGesture extends Disposable { public readonly onCancel: Event = this._onCancel.event; private readonly _editor: ICodeEditor; - private readonly _opts: ClickLinkOptions; + private _opts: ClickLinkOptions; private lastMouseMoveEvent: ClickLinkMouseEvent; private hasTriggerKeyOnMouseDown: boolean; - constructor(editor: ICodeEditor, opts: ClickLinkOptions) { + constructor(editor: ICodeEditor) { super(); this._editor = editor; - this._opts = opts; + this._opts = createOptions(this._editor.getConfiguration().multicursorModifier); this.lastMouseMoveEvent = null; this.hasTriggerKeyOnMouseDown = false; + this._register(this._editor.onDidChangeConfiguration((e) => { + if (e.multicursorModifier) { + const newOpts = createOptions(this._editor.getConfiguration().multicursorModifier); + if (this._opts.equals(newOpts)) { + return; + } + this._opts = newOpts; + this.lastMouseMoveEvent = null; + this.hasTriggerKeyOnMouseDown = false; + this._onCancel.fire(); + } + })); this._register(this._editor.onMouseMove((e: IEditorMouseEvent) => this.onEditorMouseMove(new ClickLinkMouseEvent(e, this._opts)))); this._register(this._editor.onMouseDown((e: IEditorMouseEvent) => this.onEditorMouseDown(new ClickLinkMouseEvent(e, this._opts)))); this._register(this._editor.onMouseUp((e: IEditorMouseEvent) => this.onEditorMouseUp(new ClickLinkMouseEvent(e, this._opts)))); diff --git a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts index e063801f2d9..a29f1511b44 100644 --- a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts +++ b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts @@ -10,8 +10,6 @@ import * as nls from 'vs/nls'; import { Throttler } from 'vs/base/common/async'; import { onUnexpectedError } from 'vs/base/common/errors'; import { MarkedString } from 'vs/base/common/htmlContent'; -import { KeyCode } from 'vs/base/common/keyCodes'; -import * as platform from 'vs/base/common/platform'; import { TPromise } from 'vs/base/common/winjs.base'; import { IModeService } from 'vs/editor/common/services/modeService'; import { Range } from 'vs/editor/common/core/range'; @@ -26,15 +24,12 @@ import { registerThemingParticipant } from 'vs/platform/theme/common/themeServic import { editorActiveLinkForeground } from 'vs/platform/theme/common/colorRegistry'; import { EditorState, CodeEditorStateFlag } from 'vs/editor/common/core/editorState'; import { DefinitionAction, DefinitionActionConfig } from './goToDeclarationCommands'; -import { ClickLinkGesture, ClickLinkOptions, ClickLinkMouseEvent, ClickLinkKeyboardEvent } from "vs/editor/contrib/goToDeclaration/browser/clickLinkGesture"; +import { ClickLinkGesture, ClickLinkMouseEvent, ClickLinkKeyboardEvent } from "vs/editor/contrib/goToDeclaration/browser/clickLinkGesture"; @editorContribution class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorContribution { private static ID = 'editor.contrib.gotodefinitionwithmouse'; - static TRIGGER_MODIFIER: 'metaKey' | 'ctrlKey' = platform.isMacintosh ? 'metaKey' : 'ctrlKey'; - static TRIGGER_SIDEBYSIDE_KEY_VALUE = KeyCode.Alt; - static TRIGGER_KEY_VALUE = platform.isMacintosh ? KeyCode.Meta : KeyCode.Ctrl; static MAX_SOURCE_PREVIEW_LINES = 8; private editor: ICodeEditor; @@ -53,11 +48,7 @@ class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorC this.editor = editor; this.throttler = new Throttler(); - let linkGesture = new ClickLinkGesture(editor, new ClickLinkOptions( - GotoDefinitionWithMouseEditorContribution.TRIGGER_KEY_VALUE, - GotoDefinitionWithMouseEditorContribution.TRIGGER_MODIFIER, - GotoDefinitionWithMouseEditorContribution.TRIGGER_SIDEBYSIDE_KEY_VALUE - )); + let linkGesture = new ClickLinkGesture(editor); this.toUnhook.push(linkGesture); this.toUnhook.push(linkGesture.onMouseMoveOrRelevantKeyDown(([mouseEvent, keyboardEvent]) => { diff --git a/src/vs/editor/contrib/hover/browser/hover.ts b/src/vs/editor/contrib/hover/browser/hover.ts index 7660cff426e..b0229e73f1b 100644 --- a/src/vs/editor/contrib/hover/browser/hover.ts +++ b/src/vs/editor/contrib/hover/browser/hover.ts @@ -112,8 +112,7 @@ export class ModesHoverController implements editorCommon.IEditorContribution { } private _onKeyDown(e: IKeyboardEvent): void { - var stopKey = platform.isMacintosh ? KeyCode.Meta : KeyCode.Ctrl; - if (e.keyCode !== stopKey) { + if (e.keyCode !== KeyCode.Ctrl && e.keyCode !== KeyCode.Alt && e.keyCode !== KeyCode.Meta) { // Do not hide hover when Ctrl/Meta is pressed this._hideWidgets(); } diff --git a/src/vs/editor/contrib/links/browser/links.ts b/src/vs/editor/contrib/links/browser/links.ts index c14eaf2d911..58808a66a34 100644 --- a/src/vs/editor/contrib/links/browser/links.ts +++ b/src/vs/editor/contrib/links/browser/links.ts @@ -8,7 +8,6 @@ import 'vs/css!./links'; import * as nls from 'vs/nls'; import { onUnexpectedError } from 'vs/base/common/errors'; -import { KeyCode } from 'vs/base/common/keyCodes'; import * as platform from 'vs/base/common/platform'; import Severity from 'vs/base/common/severity'; import { TPromise } from 'vs/base/common/winjs.base'; @@ -26,7 +25,7 @@ import { registerThemingParticipant } from 'vs/platform/theme/common/themeServic import { editorActiveLinkForeground } from 'vs/platform/theme/common/colorRegistry'; import { Position } from 'vs/editor/common/core/position'; import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; -import { ClickLinkGesture, ClickLinkOptions, ClickLinkMouseEvent, ClickLinkKeyboardEvent } from "vs/editor/contrib/goToDeclaration/browser/clickLinkGesture"; +import { ClickLinkGesture, ClickLinkMouseEvent, ClickLinkKeyboardEvent } from "vs/editor/contrib/goToDeclaration/browser/clickLinkGesture"; const HOVER_MESSAGE_GENERAL = ( platform.isMacintosh @@ -91,8 +90,6 @@ class LinkDetector implements editorCommon.IEditorContribution { } static RECOMPUTE_TIME = 1000; // ms - static TRIGGER_KEY_VALUE = platform.isMacintosh ? KeyCode.Meta : KeyCode.Ctrl; - static TRIGGER_MODIFIER: 'metaKey' | 'ctrlKey' = platform.isMacintosh ? 'metaKey' : 'ctrlKey'; private editor: ICodeEditor; private listenersToRemove: IDisposable[]; @@ -116,11 +113,7 @@ class LinkDetector implements editorCommon.IEditorContribution { this.editorWorkerService = editorWorkerService; this.listenersToRemove = []; - let clickLinkGesture = new ClickLinkGesture(editor, new ClickLinkOptions( - LinkDetector.TRIGGER_KEY_VALUE, - LinkDetector.TRIGGER_MODIFIER, - KeyCode.Alt - )); + let clickLinkGesture = new ClickLinkGesture(editor); this.listenersToRemove.push(clickLinkGesture); this.listenersToRemove.push(clickLinkGesture.onMouseMoveOrRelevantKeyDown(([mouseEvent, keyboardEvent]) => { this._onEditorMouseMove(mouseEvent, keyboardEvent); -- GitLab From eae2a774cca75fc73e7b57f886d946ad79d37315 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Thu, 25 May 2017 00:27:30 +0200 Subject: [PATCH 0133/1347] Show correct link hover when links open with Alt --- src/vs/editor/contrib/links/browser/links.ts | 67 +++++++++++++------- 1 file changed, 43 insertions(+), 24 deletions(-) diff --git a/src/vs/editor/contrib/links/browser/links.ts b/src/vs/editor/contrib/links/browser/links.ts index 58808a66a34..356f9bf6843 100644 --- a/src/vs/editor/contrib/links/browser/links.ts +++ b/src/vs/editor/contrib/links/browser/links.ts @@ -27,15 +27,40 @@ import { Position } from 'vs/editor/common/core/position'; import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; import { ClickLinkGesture, ClickLinkMouseEvent, ClickLinkKeyboardEvent } from "vs/editor/contrib/goToDeclaration/browser/clickLinkGesture"; -const HOVER_MESSAGE_GENERAL = ( +const HOVER_MESSAGE_GENERAL_META = ( platform.isMacintosh ? nls.localize('links.navigate.mac', "Cmd + click to follow link") : nls.localize('links.navigate', "Ctrl + click to follow link") ); +const HOVER_MESSAGE_GENERAL_ALT = nls.localize('links.navigate.al', "Alt + click to follow link"); + +const decoration = { + meta: ModelDecorationOptions.register({ + stickiness: editorCommon.TrackedRangeStickiness.NeverGrowsWhenTypingAtEdges, + inlineClassName: 'detected-link', + hoverMessage: HOVER_MESSAGE_GENERAL_META + }), + metaActive: ModelDecorationOptions.register({ + stickiness: editorCommon.TrackedRangeStickiness.NeverGrowsWhenTypingAtEdges, + inlineClassName: 'detected-link-active', + hoverMessage: HOVER_MESSAGE_GENERAL_META + }), + alt: ModelDecorationOptions.register({ + stickiness: editorCommon.TrackedRangeStickiness.NeverGrowsWhenTypingAtEdges, + inlineClassName: 'detected-link', + hoverMessage: HOVER_MESSAGE_GENERAL_ALT + }), + altActive: ModelDecorationOptions.register({ + stickiness: editorCommon.TrackedRangeStickiness.NeverGrowsWhenTypingAtEdges, + inlineClassName: 'detected-link-active', + hoverMessage: HOVER_MESSAGE_GENERAL_ALT + }), +}; + class LinkOccurence { - public static decoration(link: Link): editorCommon.IModelDeltaDecoration { + public static decoration(link: Link, useMetaKey: boolean): editorCommon.IModelDeltaDecoration { return { range: { startLineNumber: link.range.startLineNumber, @@ -43,24 +68,15 @@ class LinkOccurence { endLineNumber: link.range.endLineNumber, endColumn: link.range.endColumn }, - options: LinkOccurence._getOptions(false) + options: LinkOccurence._getOptions(useMetaKey, false) }; } - private static _LINK_DECORATION = ModelDecorationOptions.register({ - stickiness: editorCommon.TrackedRangeStickiness.NeverGrowsWhenTypingAtEdges, - inlineClassName: 'detected-link', - hoverMessage: HOVER_MESSAGE_GENERAL - }); - - private static _ACTIVE_LINK_DECORATION = ModelDecorationOptions.register({ - stickiness: editorCommon.TrackedRangeStickiness.NeverGrowsWhenTypingAtEdges, - inlineClassName: 'detected-link-active', - hoverMessage: HOVER_MESSAGE_GENERAL - }); - - private static _getOptions(isActive: boolean): ModelDecorationOptions { - return (isActive ? this._ACTIVE_LINK_DECORATION : this._LINK_DECORATION); + private static _getOptions(useMetaKey: boolean, isActive: boolean): ModelDecorationOptions { + if (useMetaKey) { + return (isActive ? decoration.metaActive : decoration.meta); + } + return (isActive ? decoration.altActive : decoration.alt); } public decorationId: string; @@ -71,12 +87,12 @@ class LinkOccurence { this.decorationId = decorationId; } - public activate(changeAccessor: editorCommon.IModelDecorationsChangeAccessor): void { - changeAccessor.changeDecorationOptions(this.decorationId, LinkOccurence._getOptions(true)); + public activate(changeAccessor: editorCommon.IModelDecorationsChangeAccessor, useMetaKey: boolean): void { + changeAccessor.changeDecorationOptions(this.decorationId, LinkOccurence._getOptions(useMetaKey, true)); } - public deactivate(changeAccessor: editorCommon.IModelDecorationsChangeAccessor): void { - changeAccessor.changeDecorationOptions(this.decorationId, LinkOccurence._getOptions(false)); + public deactivate(changeAccessor: editorCommon.IModelDecorationsChangeAccessor, useMetaKey: boolean): void { + changeAccessor.changeDecorationOptions(this.decorationId, LinkOccurence._getOptions(useMetaKey, false)); } } @@ -183,6 +199,7 @@ class LinkDetector implements editorCommon.IEditorContribution { } private updateDecorations(links: Link[]): void { + const useMetaKey = (this.editor.getConfiguration().multicursorModifier === 'altKey'); this.editor.changeDecorations((changeAccessor: editorCommon.IModelDecorationsChangeAccessor) => { var oldDecorations: string[] = []; let keys = Object.keys(this.currentOccurences); @@ -196,7 +213,7 @@ class LinkDetector implements editorCommon.IEditorContribution { if (links) { // Not sure why this is sometimes null for (var i = 0; i < links.length; i++) { - newDecorations.push(LinkOccurence.decoration(links[i])); + newDecorations.push(LinkOccurence.decoration(links[i], useMetaKey)); } } @@ -212,12 +229,13 @@ class LinkDetector implements editorCommon.IEditorContribution { } private _onEditorMouseMove(mouseEvent: ClickLinkMouseEvent, withKey?: ClickLinkKeyboardEvent): void { + const useMetaKey = (this.editor.getConfiguration().multicursorModifier === 'altKey'); if (this.isEnabled(mouseEvent, withKey)) { this.cleanUpActiveLinkDecoration(); // always remove previous link decoration as their can only be one var occurence = this.getLinkOccurence(mouseEvent.target.position); if (occurence) { this.editor.changeDecorations((changeAccessor) => { - occurence.activate(changeAccessor); + occurence.activate(changeAccessor, useMetaKey); this.activeLinkDecorationId = occurence.decorationId; }); } @@ -227,11 +245,12 @@ class LinkDetector implements editorCommon.IEditorContribution { } private cleanUpActiveLinkDecoration(): void { + const useMetaKey = (this.editor.getConfiguration().multicursorModifier === 'altKey'); if (this.activeLinkDecorationId) { var occurence = this.currentOccurences[this.activeLinkDecorationId]; if (occurence) { this.editor.changeDecorations((changeAccessor) => { - occurence.deactivate(changeAccessor); + occurence.deactivate(changeAccessor, useMetaKey); }); } -- GitLab From dfff4c5e8e461d48c57a6ce380de8bd72fae1eb6 Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Wed, 24 May 2017 15:46:59 -0700 Subject: [PATCH 0134/1347] Fix #26634 - if a `./` include pattern contains glob characters, ignore the `./` --- .../search/browser/patternInputWidget.ts | 39 +++++++++++++------ 1 file changed, 27 insertions(+), 12 deletions(-) diff --git a/src/vs/workbench/parts/search/browser/patternInputWidget.ts b/src/vs/workbench/parts/search/browser/patternInputWidget.ts index 75bef0a6f43..0657073ca2f 100644 --- a/src/vs/workbench/parts/search/browser/patternInputWidget.ts +++ b/src/vs/workbench/parts/search/browser/patternInputWidget.ts @@ -110,8 +110,6 @@ export class PatternInputWidget extends Widget { return {}; } - const isSearchPath = segment => segment.match(/^\.\//); - let exprSegments: string[]; let searchPaths: string[]; if (isGlobPattern) { @@ -119,21 +117,17 @@ export class PatternInputWidget extends Widget { .map(s => s.trim()) .filter(s => !!s.length); - const groups = collections.groupBy(segments, - segment => isSearchPath(segment) ? 'searchPaths' : 'exprSegments'); - searchPaths = groups.searchPaths || []; - exprSegments = groups.exprSegments || []; + const groups = this.groupByPathsAndExprSegments(segments); + searchPaths = groups.searchPaths; + exprSegments = groups.exprSegments; } else { const segments = pattern.split(',') .map(s => strings.trim(s.trim(), '/')) .filter(s => !!s.length); - const groups = collections.groupBy(segments, - segment => isSearchPath(segment) ? 'searchPaths' : 'exprSegments'); - searchPaths = groups.searchPaths || []; - exprSegments = groups.exprSegments || []; - - exprSegments = exprSegments + const groups = this.groupByPathsAndExprSegments(segments); + searchPaths = groups.searchPaths; + exprSegments = groups.exprSegments .map(p => { if (p[0] === '.') { p = '*' + p; // convert ".js" to "*.js" @@ -147,6 +141,27 @@ export class PatternInputWidget extends Widget { return { expression, searchPaths }; } + private groupByPathsAndExprSegments(segments: string[]) { + const isSearchPath = segment => segment.match(/^\.\//); + + const groups = collections.groupBy(segments, + segment => isSearchPath(segment) ? 'searchPaths' : 'exprSegments'); + groups.searchPaths = groups.searchPaths || []; + groups.exprSegments = groups.exprSegments || []; + + // If a ./searchPath has a glob character, remove ./ and use it as an expression segment + groups.searchPaths = groups.searchPaths.filter(searchPath => { + if (searchPath.match(/[\*\{\}\(\)\[\]\?]/)) { + groups.exprSegments.push(strings.ltrim(searchPath, './')); + return false; + } + + return true; + }); + + return groups; + } + public select(): void { this.inputBox.select(); } -- GitLab From 2dcccf7cc8f730c0a31ddf7114923adb44bf07d2 Mon Sep 17 00:00:00 2001 From: rebornix Date: Wed, 24 May 2017 16:17:47 -0700 Subject: [PATCH 0135/1347] Fix #25783. Middle click pastes in Find Widget on Linux --- src/vs/base/browser/ui/findinput/findInput.ts | 5 +++++ src/vs/editor/contrib/find/browser/findWidget.ts | 12 ++++++++++++ 2 files changed, 17 insertions(+) diff --git a/src/vs/base/browser/ui/findinput/findInput.ts b/src/vs/base/browser/ui/findinput/findInput.ts index 2d38be64dc9..2d447646974 100644 --- a/src/vs/base/browser/ui/findinput/findInput.ts +++ b/src/vs/base/browser/ui/findinput/findInput.ts @@ -13,6 +13,7 @@ import { IContextViewProvider } from 'vs/base/browser/ui/contextview/contextview import { Widget } from 'vs/base/browser/ui/widget'; import Event, { Emitter } from 'vs/base/common/event'; import { IKeyboardEvent } from 'vs/base/browser/keyboardEvent'; +import { IMouseEvent } from 'vs/base/browser/mouseEvent'; import { KeyCode } from 'vs/base/common/keyCodes'; import { CaseSensitiveCheckbox, WholeWordsCheckbox, RegexCheckbox } from 'vs/base/browser/ui/findinput/findInputCheckboxes'; import { Color } from 'vs/base/common/color'; @@ -69,6 +70,9 @@ export class FindInput extends Widget { private _onKeyDown = this._register(new Emitter()); public onKeyDown: Event = this._onKeyDown.event; + private _onMouseDown = this._register(new Emitter()); + public onMouseDown: Event = this._onMouseDown.event; + private _onInput = this._register(new Emitter()); public onInput: Event = this._onInput.event; @@ -113,6 +117,7 @@ export class FindInput extends Widget { this.onkeydown(this.inputBox.inputElement, (e) => this._onKeyDown.fire(e)); this.onkeyup(this.inputBox.inputElement, (e) => this._onKeyUp.fire(e)); this.oninput(this.inputBox.inputElement, (e) => this._onInput.fire()); + this.onmousedown(this.inputBox.inputElement, (e) => this._onMouseDown.fire(e)); } public enable(): void { diff --git a/src/vs/editor/contrib/find/browser/findWidget.ts b/src/vs/editor/contrib/find/browser/findWidget.ts index 78e442c6992..409caf8fb73 100644 --- a/src/vs/editor/contrib/find/browser/findWidget.ts +++ b/src/vs/editor/contrib/find/browser/findWidget.ts @@ -9,9 +9,11 @@ import 'vs/css!./findWidget'; import * as nls from 'vs/nls'; import { onUnexpectedError } from 'vs/base/common/errors'; import { KeyCode, KeyMod } from 'vs/base/common/keyCodes'; +import * as platform from 'vs/base/common/platform'; import * as strings from 'vs/base/common/strings'; import * as dom from 'vs/base/browser/dom'; import { IKeyboardEvent } from 'vs/base/browser/keyboardEvent'; +import { IMouseEvent } from 'vs/base/browser/mouseEvent'; import { IContextViewProvider } from 'vs/base/browser/ui/contextview/contextview'; import { FindInput, IFindInputStyles } from 'vs/base/browser/ui/findinput/findInput'; import { IMessage as InputBoxMessage, InputBox } from 'vs/base/browser/ui/inputbox/inputBox'; @@ -514,6 +516,13 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas this._findInput.highlightFindOptions(); } + private _onFindInputMouseDown(e: IMouseEvent): void { + // on linux, middle key does pasting. + if (e.middleButton) { + e.stopPropagation(); + } + } + private _onFindInputKeyDown(e: IKeyboardEvent): void { if (e.equals(KeyCode.Enter)) { @@ -647,6 +656,9 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas } } })); + if (platform.isLinux) { + this._register(this._findInput.onMouseDown((e) => this._onFindInputMouseDown(e))); + } this._matchesCount = document.createElement('div'); this._matchesCount.className = 'matchesCount'; -- GitLab From 6d3e6cd313040668e136b6088a4e6133d0ada861 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Wed, 24 May 2017 20:04:00 -0700 Subject: [PATCH 0136/1347] Clean up termianl imports --- .../electron-browser/terminal.contribution.ts | 4 +- .../electron-browser/terminalActions.ts | 4 +- .../electron-browser/terminalColorRegistry.ts | 2 +- .../electron-browser/terminalInstance.ts | 46 +++++++++---------- .../electron-browser/terminalPanel.ts | 26 +++++------ 5 files changed, 41 insertions(+), 41 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts index 6becf5badb0..c4e3fc01471 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts @@ -7,9 +7,10 @@ import 'vs/css!./media/scrollbar'; import 'vs/css!./media/terminal'; import 'vs/css!./media/xterm'; import 'vs/css!./media/widgets'; +import * as debugActions from 'vs/workbench/parts/debug/browser/debugActions'; +import * as nls from 'vs/nls'; import * as panel from 'vs/workbench/browser/panel'; import * as platform from 'vs/base/common/platform'; -import nls = require('vs/nls'); import { Extensions, IConfigurationRegistry } from 'vs/platform/configuration/common/configurationRegistry'; import { GlobalQuickOpenAction } from 'vs/workbench/browser/parts/quickopen/quickopen.contribution'; import { ITerminalService, KEYBINDING_CONTEXT_TERMINAL_FOCUS, KEYBINDING_CONTEXT_TERMINAL_TEXT_SELECTED, TERMINAL_PANEL_ID, TERMINAL_DEFAULT_RIGHT_CLICK_COPY_PASTE, TerminalCursorStyle } from 'vs/workbench/parts/terminal/common/terminal'; @@ -24,7 +25,6 @@ import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; import { TerminalService } from 'vs/workbench/parts/terminal/electron-browser/terminalService'; import { ToggleTabFocusModeAction } from 'vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode'; import { registerSingleton } from 'vs/platform/instantiation/common/extensions'; -import debugActions = require('vs/workbench/parts/debug/browser/debugActions'); import { KeybindingsRegistry } from 'vs/platform/keybinding/common/keybindingsRegistry'; import { OpenNextRecentlyUsedEditorInGroupAction, OpenPreviousRecentlyUsedEditorInGroupAction, FocusActiveGroupAction, FocusFirstGroupAction, FocusSecondGroupAction, FocusThirdGroupAction } from 'vs/workbench/browser/parts/editor/editorActions'; import { EDITOR_FONT_DEFAULTS } from "vs/editor/common/config/editorOptions"; diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts index 58cd361fd34..3b62f9642ed 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts @@ -3,8 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import nls = require('vs/nls'); -import os = require('os'); +import * as nls from 'vs/nls'; +import * as os from 'os'; import { Action, IAction } from 'vs/base/common/actions'; import { EndOfLinePreference } from 'vs/editor/common/editorCommon'; import { ICodeEditorService } from 'vs/editor/common/services/codeEditorService'; diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.ts index 727078be3bc..27f3f23c8ba 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.ts @@ -3,7 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import nls = require('vs/nls'); +import * as nls from 'vs/nls'; import { registerColor, ColorIdentifier } from 'vs/platform/theme/common/colorRegistry'; diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index 07f8b6b53cb..8d7d30b7099 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -3,15 +3,15 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ +import * as cp from 'child_process'; +import * as os from 'os'; import * as path from 'path'; -import DOM = require('vs/base/browser/dom'); +import * as lifecycle from 'vs/base/common/lifecycle'; +import * as nls from 'vs/nls'; +import * as platform from 'vs/base/common/platform'; +import * as dom from 'vs/base/browser/dom'; import Event, { Emitter } from 'vs/base/common/event'; -import URI from 'vs/base/common/uri'; -import cp = require('child_process'); -import lifecycle = require('vs/base/common/lifecycle'); -import nls = require('vs/nls'); -import os = require('os'); -import platform = require('vs/base/common/platform'); +import Uri from 'vs/base/common/uri'; import xterm = require('xterm'); import { Dimension } from 'vs/base/browser/builder'; import { IContextKeyService, IContextKey } from 'vs/platform/contextkey/common/contextkey'; @@ -39,7 +39,7 @@ class StandardTerminalProcessFactory implements ITerminalProcessFactory { public create(env: { [key: string]: string }): cp.ChildProcess { return cp.fork('./terminalProcess', [], { env, - cwd: URI.parse(path.dirname(require.toUrl('./terminalProcess'))).fsPath + cwd: Uri.parse(path.dirname(require.toUrl('./terminalProcess'))).fsPath }); } } @@ -217,7 +217,7 @@ export class TerminalInstance implements ITerminalInstance { this._container = container; this._wrapperElement = document.createElement('div'); - DOM.addClass(this._wrapperElement, 'terminal-wrapper'); + dom.addClass(this._wrapperElement, 'terminal-wrapper'); this._xtermElement = document.createElement('div'); this._xterm.open(this._xtermElement, false); @@ -242,7 +242,7 @@ export class TerminalInstance implements ITerminalInstance { } return undefined; }); - this._instanceDisposables.push(DOM.addDisposableListener(this._xterm.element, 'mouseup', (event: KeyboardEvent) => { + this._instanceDisposables.push(dom.addDisposableListener(this._xterm.element, 'mouseup', (event: KeyboardEvent) => { // Wait until mouseup has propogated through the DOM before evaluating the new selection // state. setTimeout(() => { @@ -251,7 +251,7 @@ export class TerminalInstance implements ITerminalInstance { })); // xterm.js currently drops selection on keyup as we need to handle this case. - this._instanceDisposables.push(DOM.addDisposableListener(this._xterm.element, 'keyup', (event: KeyboardEvent) => { + this._instanceDisposables.push(dom.addDisposableListener(this._xterm.element, 'keyup', (event: KeyboardEvent) => { // Wait until keyup has propogated through the DOM before evaluating the new selection // state. setTimeout(() => { @@ -262,10 +262,10 @@ export class TerminalInstance implements ITerminalInstance { const xtermHelper: HTMLElement = this._xterm.element.querySelector('.xterm-helpers'); const focusTrap: HTMLElement = document.createElement('div'); focusTrap.setAttribute('tabindex', '0'); - DOM.addClass(focusTrap, 'focus-trap'); - this._instanceDisposables.push(DOM.addDisposableListener(focusTrap, 'focus', (event: FocusEvent) => { + dom.addClass(focusTrap, 'focus-trap'); + this._instanceDisposables.push(dom.addDisposableListener(focusTrap, 'focus', (event: FocusEvent) => { let currentElement = focusTrap; - while (!DOM.hasClass(currentElement, 'part')) { + while (!dom.hasClass(currentElement, 'part')) { currentElement = currentElement.parentElement; } const hidePanelElement = currentElement.querySelector('.hide-panel-action'); @@ -273,17 +273,17 @@ export class TerminalInstance implements ITerminalInstance { })); xtermHelper.insertBefore(focusTrap, this._xterm.textarea); - this._instanceDisposables.push(DOM.addDisposableListener(this._xterm.textarea, 'focus', (event: KeyboardEvent) => { + this._instanceDisposables.push(dom.addDisposableListener(this._xterm.textarea, 'focus', (event: KeyboardEvent) => { this._terminalFocusContextKey.set(true); })); - this._instanceDisposables.push(DOM.addDisposableListener(this._xterm.textarea, 'blur', (event: KeyboardEvent) => { + this._instanceDisposables.push(dom.addDisposableListener(this._xterm.textarea, 'blur', (event: KeyboardEvent) => { this._terminalFocusContextKey.reset(); this._refreshSelectionContextKey(); })); - this._instanceDisposables.push(DOM.addDisposableListener(this._xterm.element, 'focus', (event: KeyboardEvent) => { + this._instanceDisposables.push(dom.addDisposableListener(this._xterm.element, 'focus', (event: KeyboardEvent) => { this._terminalFocusContextKey.set(true); })); - this._instanceDisposables.push(DOM.addDisposableListener(this._xterm.element, 'blur', (event: KeyboardEvent) => { + this._instanceDisposables.push(dom.addDisposableListener(this._xterm.element, 'blur', (event: KeyboardEvent) => { this._terminalFocusContextKey.reset(); this._refreshSelectionContextKey(); })); @@ -336,7 +336,7 @@ export class TerminalInstance implements ITerminalInstance { this._linkHandler.dispose(); } if (this._xterm && this._xterm.element) { - this._hadFocusOnExit = DOM.hasClass(this._xterm.element, 'focus'); + this._hadFocusOnExit = dom.hasClass(this._xterm.element, 'focus'); } if (this._wrapperElement) { this._container.removeChild(this._wrapperElement); @@ -389,7 +389,7 @@ export class TerminalInstance implements ITerminalInstance { public setVisible(visible: boolean): void { this._isVisible = visible; if (this._wrapperElement) { - DOM.toggleClass(this._wrapperElement, 'active', visible); + dom.toggleClass(this._wrapperElement, 'active', visible); } if (visible && this._xterm) { // Trigger a manual scroll event which will sync the viewport and scroll bar. This is @@ -473,9 +473,9 @@ export class TerminalInstance implements ITerminalInstance { } const env = TerminalInstance.createTerminalEnv(process.env, shell, this._getCwd(shell, workspace), locale, this._cols, this._rows); this._title = shell.name || ''; - this._process = cp.fork(URI.parse(require.toUrl('bootstrap')).fsPath, ['--type=terminal'], { + this._process = cp.fork(Uri.parse(require.toUrl('bootstrap')).fsPath, ['--type=terminal'], { env, - cwd: URI.parse(path.dirname(require.toUrl('../node/terminalProcess'))).fsPath + cwd: Uri.parse(path.dirname(require.toUrl('../node/terminalProcess'))).fsPath }); if (!shell.name) { // Only listen for process title changes when a name is not provided @@ -559,7 +559,7 @@ export class TerminalInstance implements ITerminalInstance { } private _attachPressAnyKeyToCloseListener() { - this._processDisposables.push(DOM.addDisposableListener(this._xterm.textarea, 'keypress', (event: KeyboardEvent) => { + this._processDisposables.push(dom.addDisposableListener(this._xterm.textarea, 'keypress', (event: KeyboardEvent) => { this.dispose(); event.preventDefault(); })); diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts index 81ed253bd42..ec880bdd12c 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts @@ -3,9 +3,9 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import DOM = require('vs/base/browser/dom'); -import nls = require('vs/nls'); -import platform = require('vs/base/common/platform'); +import * as dom from 'vs/base/browser/dom'; +import * as nls from 'vs/nls'; +import * as platform from 'vs/base/common/platform'; import { Action, IAction } from 'vs/base/common/actions'; import { Builder, Dimension } from 'vs/base/browser/builder'; import { IActionItem, Separator } from 'vs/base/browser/ui/actionbar/actionbar'; @@ -51,12 +51,12 @@ export class TerminalPanel extends Panel { public create(parent: Builder): TPromise { super.create(parent); this._parentDomElement = parent.getHTMLElement(); - DOM.addClass(this._parentDomElement, 'integrated-terminal'); + dom.addClass(this._parentDomElement, 'integrated-terminal'); this._themeStyleElement = document.createElement('style'); this._fontStyleElement = document.createElement('style'); this._terminalContainer = document.createElement('div'); - DOM.addClass(this._terminalContainer, 'terminal-outer-container'); + dom.addClass(this._terminalContainer, 'terminal-outer-container'); this._parentDomElement.appendChild(this._themeStyleElement); this._parentDomElement.appendChild(this._fontStyleElement); this._parentDomElement.appendChild(this._terminalContainer); @@ -152,7 +152,7 @@ export class TerminalPanel extends Panel { } private _attachEventListeners(): void { - this._register(DOM.addDisposableListener(this._parentDomElement, 'mousedown', (event: MouseEvent) => { + this._register(dom.addDisposableListener(this._parentDomElement, 'mousedown', (event: MouseEvent) => { if (this._terminalService.terminalInstances.length === 0) { return; } @@ -183,7 +183,7 @@ export class TerminalPanel extends Panel { } } })); - this._register(DOM.addDisposableListener(this._parentDomElement, 'contextmenu', (event: MouseEvent) => { + this._register(dom.addDisposableListener(this._parentDomElement, 'contextmenu', (event: MouseEvent) => { if (!this._cancelContextMenu) { const standardEvent = new StandardMouseEvent(event); let anchor: { x: number, y: number } = { x: standardEvent.posx, y: standardEvent.posy }; @@ -196,7 +196,7 @@ export class TerminalPanel extends Panel { } this._cancelContextMenu = false; })); - this._register(DOM.addDisposableListener(this._parentDomElement, 'click', (event) => { + this._register(dom.addDisposableListener(this._parentDomElement, 'click', (event) => { if (this._terminalService.terminalInstances.length === 0) { return; } @@ -205,14 +205,14 @@ export class TerminalPanel extends Panel { this._terminalService.getActiveInstance().focus(); } })); - this._register(DOM.addDisposableListener(this._parentDomElement, 'keyup', (event: KeyboardEvent) => { + this._register(dom.addDisposableListener(this._parentDomElement, 'keyup', (event: KeyboardEvent) => { if (event.keyCode === 27) { // Keep terminal open on escape event.stopPropagation(); } })); - this._register(DOM.addDisposableListener(this._parentDomElement, DOM.EventType.DROP, (e: DragEvent) => { - if (e.target === this._parentDomElement || DOM.isAncestor(e.target as HTMLElement, this._parentDomElement)) { + this._register(dom.addDisposableListener(this._parentDomElement, dom.EventType.DROP, (e: DragEvent) => { + if (e.target === this._parentDomElement || dom.isAncestor(e.target as HTMLElement, this._parentDomElement)) { if (!e.dataTransfer) { return; } @@ -269,8 +269,8 @@ export class TerminalPanel extends Panel { return; } let newFont = this._terminalService.configHelper.getFont(); - DOM.toggleClass(this._parentDomElement, 'enable-ligatures', this._terminalService.configHelper.config.fontLigatures); - DOM.toggleClass(this._parentDomElement, 'disable-bold', !this._terminalService.configHelper.config.enableBold); + dom.toggleClass(this._parentDomElement, 'enable-ligatures', this._terminalService.configHelper.config.fontLigatures); + dom.toggleClass(this._parentDomElement, 'disable-bold', !this._terminalService.configHelper.config.enableBold); if (!this._font || this._fontsDiffer(this._font, newFont)) { this._fontStyleElement.innerHTML = '.monaco-workbench .panel.integrated-terminal .xterm {' + `font-family: ${newFont.fontFamily};` + -- GitLab From 31875b67cc33f19b1b1ff8a8a1ced71c325e1684 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Wed, 24 May 2017 22:33:35 -0700 Subject: [PATCH 0137/1347] Reverting prev fix as it adds gap between docs and list --- .../editor/contrib/suggest/browser/media/suggest.css | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/src/vs/editor/contrib/suggest/browser/media/suggest.css b/src/vs/editor/contrib/suggest/browser/media/suggest.css index 08b4e45593d..fe64def759b 100644 --- a/src/vs/editor/contrib/suggest/browser/media/suggest.css +++ b/src/vs/editor/contrib/suggest/browser/media/suggest.css @@ -34,18 +34,12 @@ .monaco-editor .suggest-widget.docs-side > .tree, .monaco-editor .suggest-widget.docs-side > .details { - /* subtract 2px for border, and another 2 for the Chromium zoom issue - where the children get slightly bigger width than what is set - which makes the docs go below the list */ - width: calc(50% - 4px); + width: 328px; } .monaco-editor.hc-black .suggest-widget.docs-side > .tree, .monaco-editor.hc-black .suggest-widget.docs-side > .details { - /* subtract 4px for border, and another 2 for the Chromium zoom issue - where the children get slightly bigger width than what is set - which makes the docs go below the list */ - width: calc(50% - 6px); + width: 326px; } /* Styles for Message element for when widget is loading or is empty */ -- GitLab From c96f85a6d22fc33cf86ac17ed4ba2f79b98ece53 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Wed, 24 May 2017 22:48:10 -0700 Subject: [PATCH 0138/1347] Fixes #26244 prevent double border --- .../contrib/suggest/browser/media/suggest.css | 30 +++++++++---- .../contrib/suggest/browser/suggestWidget.ts | 42 +++++++++++++++---- 2 files changed, 58 insertions(+), 14 deletions(-) diff --git a/src/vs/editor/contrib/suggest/browser/media/suggest.css b/src/vs/editor/contrib/suggest/browser/media/suggest.css index fe64def759b..7ca54b83969 100644 --- a/src/vs/editor/contrib/suggest/browser/media/suggest.css +++ b/src/vs/editor/contrib/suggest/browser/media/suggest.css @@ -34,7 +34,17 @@ .monaco-editor .suggest-widget.docs-side > .tree, .monaco-editor .suggest-widget.docs-side > .details { - width: 328px; + /* subtract 2px for border, and another 2 for the Chromium zoom issue + where the children get slightly bigger width than what is set + which makes the docs go below the list */ + width: calc(50% - 4px); + float: left; + +} + +.monaco-editor .suggest-widget.docs-side.list-right > .tree, +.monaco-editor .suggest-widget.docs-side.list-right > .details { + float: right; } .monaco-editor.hc-black .suggest-widget.docs-side > .tree, @@ -42,6 +52,14 @@ width: 326px; } +.monaco-editor .suggest-widget.docs-side .empty-left-border { + border-left-width: 0px; +} + +.monaco-editor .suggest-widget.docs-side .empty-right-border { + border-right-width: 0px; +} + /* Styles for Message element for when widget is loading or is empty */ .monaco-editor .suggest-widget > .message { padding-left: 22px; @@ -58,13 +76,7 @@ height: 100%; } -.monaco-editor .suggest-widget.docs-side > .tree { - float: left; -} -.monaco-editor .suggest-widget.docs-side.list-right > .tree { - float: right -} /** Styles for each row in the list element **/ @@ -207,6 +219,10 @@ display: none; } +.monaco-editor .suggest-widget.docs-below .details { + border-top-width: 0px; +} + .monaco-editor .suggest-widget .details > .monaco-scrollable-element { flex: 1; } diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index 56871ef9504..c27e0dbaa95 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -948,14 +948,42 @@ export class SuggestWidget implements IContentWidget, IDelegate } private adjustListPosition(): void { - if (hasClass(this.element, 'widget-above') - && hasClass(this.element, 'docs-side') - && this.details.element.offsetHeight > this.listElement.offsetHeight) { - // Docs is bigger than list and widget is above cursor, apply margin-top so that list appears right above cursor - this.listElement.style.marginTop = `${this.details.element.offsetHeight - this.listElement.offsetHeight}px`; - } else { - this.listElement.style.marginTop = '0px'; + + + if (hasClass(this.element, 'docs-side')) { + + if (this.details.element.offsetHeight > this.listElement.offsetHeight) { + if (hasClass(this.element, 'widget-above')) { + // Docs is bigger than list and widget is above cursor, apply margin-top so that list appears right above cursor + this.listElement.style.marginTop = `${this.details.element.offsetHeight - this.listElement.offsetHeight}px`; + } + + if (hasClass(this.element, 'list-right')) { + addClass(this.listElement, 'empty-left-border'); + removeClass(this.listElement, 'empty-right-border'); + } else { + addClass(this.listElement, 'empty-right-border'); + removeClass(this.listElement, 'empty-left-border'); + } + + removeClass(this.details.element, 'empty-left-border'); + removeClass(this.details.element, 'empty-right-border'); + return; + } else { + if (hasClass(this.element, 'list-right')) { + addClass(this.details.element, 'empty-right-border'); + removeClass(this.details.element, 'empty-left-border'); + } else { + addClass(this.details.element, 'empty-left-border'); + removeClass(this.details.element, 'empty-right-border'); + } + + removeClass(this.listElement, 'empty-right-border'); + removeClass(this.listElement, 'empty-left-border'); + } } + + this.listElement.style.marginTop = '0px'; } private renderDetails(): void { -- GitLab From 819467443ca071ace3a0e1036bb67e10b9f68488 Mon Sep 17 00:00:00 2001 From: Daniel Ye Date: Wed, 24 May 2017 22:56:48 -0700 Subject: [PATCH 0139/1347] 2017-05-24. Merged in translations from transifex. --- build/win32/i18n/messages.pt-br.isl | 8 + .../out/settingsDocumentHelper.i18n.json | 2 +- i18n/chs/extensions/gulp/out/main.i18n.json | 2 +- i18n/chs/extensions/jake/out/main.i18n.json | 4 +- i18n/chs/extensions/jake/package.i18n.json | 4 +- .../markdown/out/extension.i18n.json | 6 + .../out/codelensProvider.i18n.json | 6 + .../out/commandHandler.i18n.json | 6 + .../out/mergeDecorator.i18n.json | 6 + .../merge-conflict/package.i18n.json | 6 + i18n/chs/extensions/npm/package.i18n.json | 6 + .../resourceviewer/resourceViewer.i18n.json | 2 - .../src/vs/code/electron-main/menus.i18n.json | 4 +- .../config/commonEditorConfig.i18n.json | 6 +- .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../indentation/common/indentation.i18n.json | 2 +- .../suggest/browser/suggestWidget.i18n.json | 2 +- .../common/configurationRegistry.i18n.json | 2 +- .../markers/common/problemMatcher.i18n.json | 7 + .../api/node/extHostTreeViews.i18n.json | 6 +- .../src/vs/workbench/common/theme.i18n.json | 1 + .../main.contribution.i18n.json | 1 + .../inspectKeybindings.i18n.json | 2 +- .../electron-browser/toggleWordWrap.i18n.json | 2 +- .../parts/debug/node/debugAdapter.i18n.json | 1 + .../actions/evaluateMath.i18n.json | 2 +- .../actions/incrementDecrement.i18n.json | 12 +- .../actions/removeTag.i18n.json | 2 +- .../actions/splitJoinTag.i18n.json | 2 +- .../actions/updateImageSize.i18n.json | 2 +- .../actions/updateTag.i18n.json | 6 +- .../actions/wrapWithAbbreviation.i18n.json | 2 +- .../emmet.contribution.i18n.json | 6 +- .../treeExplorer.contribution.i18n.json | 4 +- .../extensionsUtils.i18n.json | 6 +- .../browser/files.contribution.i18n.json | 1 - .../common/editors/fileEditorInput.i18n.json | 2 +- .../performance.contribution.i18n.json | 8 +- .../browser/keybindingsEditor.i18n.json | 4 +- .../browser/preferencesActions.i18n.json | 2 +- .../scm.contribution.i18n.json | 3 +- .../scm/electron-browser/scmMenus.i18n.json | 3 +- .../electron-browser/TMSnippets.i18n.json | 2 +- .../parts/tasks/browser/quickOpen.i18n.json | 4 +- .../terminalTaskSystem.i18n.json | 3 +- .../tasks/node/processTaskSystem.i18n.json | 3 +- .../electron-browser/watermark.i18n.json | 2 +- .../vs_code_welcome_page.i18n.json | 7 +- .../electron-browser/welcomePage.i18n.json | 14 ++ .../workbenchThemeService.i18n.json | 12 +- .../markdown/out/extension.i18n.json | 6 + .../out/codelensProvider.i18n.json | 6 + .../out/commandHandler.i18n.json | 6 + .../out/mergeDecorator.i18n.json | 6 + .../merge-conflict/package.i18n.json | 6 + i18n/cht/extensions/npm/package.i18n.json | 6 + .../resourceviewer/resourceViewer.i18n.json | 2 - .../src/vs/code/electron-main/menus.i18n.json | 1 + .../config/commonEditorConfig.i18n.json | 1 - .../common/view/editorColorRegistry.i18n.json | 3 + .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../api/node/extHostTreeViews.i18n.json | 4 +- .../src/vs/workbench/common/theme.i18n.json | 1 + .../main.contribution.i18n.json | 1 + .../extensionsUtils.i18n.json | 6 +- .../browser/files.contribution.i18n.json | 1 - .../performance.contribution.i18n.json | 6 +- .../scm.contribution.i18n.json | 1 + .../scm/electron-browser/scmMenus.i18n.json | 1 + .../parts/tasks/browser/quickOpen.i18n.json | 4 +- .../themes.contribution.i18n.json | 1 + .../vs_code_welcome_page.i18n.json | 3 + .../electron-browser/welcomePage.i18n.json | 13 +- .../walkThroughPart.i18n.json | 3 +- i18n/deu/extensions/git/out/main.i18n.json | 2 +- .../markdown/out/extension.i18n.json | 6 + .../out/codelensProvider.i18n.json | 6 + .../out/commandHandler.i18n.json | 6 + .../out/mergeDecorator.i18n.json | 6 + .../merge-conflict/package.i18n.json | 6 + i18n/deu/extensions/npm/package.i18n.json | 6 + .../resourceviewer/resourceViewer.i18n.json | 2 - .../config/commonEditorConfig.i18n.json | 1 - .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../main.contribution.i18n.json | 1 + .../extensionsUtils.i18n.json | 6 +- .../browser/files.contribution.i18n.json | 1 - .../performance.contribution.i18n.json | 6 +- .../electron-browser/welcomePage.i18n.json | 5 + i18n/esn/extensions/jake/out/main.i18n.json | 4 +- i18n/esn/extensions/jake/package.i18n.json | 4 +- .../markdown/out/extension.i18n.json | 6 + .../out/codelensProvider.i18n.json | 6 + .../out/commandHandler.i18n.json | 6 + .../out/mergeDecorator.i18n.json | 6 + .../merge-conflict/package.i18n.json | 6 + i18n/esn/extensions/npm/package.i18n.json | 6 + .../resourceviewer/resourceViewer.i18n.json | 2 - .../config/commonEditorConfig.i18n.json | 3 +- .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../suggest/browser/suggestWidget.i18n.json | 1 + ...guageConfigurationExtensionPoint.i18n.json | 6 +- .../markers/common/problemMatcher.i18n.json | 7 + .../theme/common/colorRegistry.i18n.json | 3 + .../api/node/extHostTreeViews.i18n.json | 6 +- .../src/vs/workbench/common/theme.i18n.json | 1 + .../main.contribution.i18n.json | 1 + .../parts/debug/node/debugAdapter.i18n.json | 1 + .../extensionsUtils.i18n.json | 6 +- .../browser/files.contribution.i18n.json | 1 - .../performance.contribution.i18n.json | 8 +- .../scm.contribution.i18n.json | 1 + .../scm/electron-browser/scmMenus.i18n.json | 1 + .../parts/tasks/browser/quickOpen.i18n.json | 4 +- .../terminalTaskSystem.i18n.json | 3 +- .../tasks/node/processTaskSystem.i18n.json | 3 +- .../vs_code_welcome_page.i18n.json | 5 + .../electron-browser/welcomePage.i18n.json | 14 ++ .../markdown/out/extension.i18n.json | 6 + .../out/codelensProvider.i18n.json | 6 + .../out/commandHandler.i18n.json | 6 + .../out/mergeDecorator.i18n.json | 6 + .../merge-conflict/package.i18n.json | 6 + i18n/fra/extensions/npm/package.i18n.json | 6 + .../resourceviewer/resourceViewer.i18n.json | 2 - .../config/commonEditorConfig.i18n.json | 1 - .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../main.contribution.i18n.json | 1 + .../extensionsUtils.i18n.json | 6 +- .../browser/files.contribution.i18n.json | 1 - .../performance.contribution.i18n.json | 6 +- .../electron-browser/welcomePage.i18n.json | 5 + .../markdown/out/extension.i18n.json | 6 + .../out/codelensProvider.i18n.json | 6 + .../out/commandHandler.i18n.json | 6 + .../out/mergeDecorator.i18n.json | 6 + .../merge-conflict/package.i18n.json | 6 + i18n/ita/extensions/npm/package.i18n.json | 6 + .../resourceviewer/resourceViewer.i18n.json | 2 - .../config/commonEditorConfig.i18n.json | 2 +- .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../markers/common/problemMatcher.i18n.json | 7 + .../main.contribution.i18n.json | 1 + .../extensionsUtils.i18n.json | 6 +- .../browser/files.contribution.i18n.json | 1 - .../performance.contribution.i18n.json | 6 +- .../electron-browser/welcomePage.i18n.json | 5 + i18n/jpn/extensions/jake/out/main.i18n.json | 4 +- i18n/jpn/extensions/jake/package.i18n.json | 4 +- .../markdown/out/extension.i18n.json | 6 + .../out/codelensProvider.i18n.json | 6 + .../out/commandHandler.i18n.json | 6 + .../out/mergeDecorator.i18n.json | 6 + .../merge-conflict/package.i18n.json | 6 + i18n/jpn/extensions/npm/package.i18n.json | 6 + .../extensions/typescript/package.i18n.json | 5 +- .../resourceviewer/resourceViewer.i18n.json | 2 - .../config/commonEditorConfig.i18n.json | 2 +- .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../suggest/browser/suggestWidget.i18n.json | 1 + ...guageConfigurationExtensionPoint.i18n.json | 1 + .../markers/common/problemMatcher.i18n.json | 7 + .../theme/common/colorRegistry.i18n.json | 1 + .../api/node/extHostTreeViews.i18n.json | 6 +- .../src/vs/workbench/common/theme.i18n.json | 1 + .../main.contribution.i18n.json | 1 + .../electronDebugActions.i18n.json | 1 + .../parts/debug/node/debugAdapter.i18n.json | 1 + .../extensionsUtils.i18n.json | 6 +- .../browser/files.contribution.i18n.json | 3 +- .../performance.contribution.i18n.json | 8 +- .../browser/preferencesRenderers.i18n.json | 1 + .../scm.contribution.i18n.json | 1 + .../scm/electron-browser/scmMenus.i18n.json | 1 + .../parts/tasks/browser/quickOpen.i18n.json | 4 +- .../tasks/browser/restartQuickOpen.i18n.json | 2 +- .../tasks/browser/taskQuickOpen.i18n.json | 2 +- .../terminalTaskSystem.i18n.json | 3 +- .../tasks/node/processTaskSystem.i18n.json | 3 +- .../terminalActions.i18n.json | 4 +- .../themes.contribution.i18n.json | 1 + .../vs_code_welcome_page.i18n.json | 7 + .../electron-browser/welcomePage.i18n.json | 18 +- .../configurationEditingService.i18n.json | 1 + .../markdown/out/extension.i18n.json | 6 + .../out/codelensProvider.i18n.json | 6 + .../out/commandHandler.i18n.json | 6 + .../out/mergeDecorator.i18n.json | 6 + .../merge-conflict/package.i18n.json | 6 + i18n/kor/extensions/npm/package.i18n.json | 6 + .../resourceviewer/resourceViewer.i18n.json | 2 - .../config/commonEditorConfig.i18n.json | 1 - .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../main.contribution.i18n.json | 1 + .../extensionsUtils.i18n.json | 6 +- .../browser/files.contribution.i18n.json | 1 - .../performance.contribution.i18n.json | 6 +- .../electron-browser/welcomePage.i18n.json | 5 + .../out/settingsDocumentHelper.i18n.json | 36 ++++ .../css/client/out/cssMain.i18n.json | 8 + i18n/ptb/extensions/css/package.i18n.json | 67 +++++++ .../out/packageDocumentHelper.i18n.json | 9 + .../extensions/git/out/askpass-main.i18n.json | 8 + .../ptb/extensions/git/out/commands.i18n.json | 43 +++++ i18n/ptb/extensions/git/out/main.i18n.json | 11 ++ i18n/ptb/extensions/git/out/model.i18n.json | 14 ++ .../extensions/git/out/scmProvider.i18n.json | 8 + .../extensions/git/out/statusbar.i18n.json | 11 ++ i18n/ptb/extensions/git/package.i18n.json | 48 +++++ i18n/ptb/extensions/grunt/out/main.i18n.json | 8 + i18n/ptb/extensions/grunt/package.i18n.json | 8 + i18n/ptb/extensions/gulp/out/main.i18n.json | 8 + i18n/ptb/extensions/gulp/package.i18n.json | 8 + .../html/client/out/htmlMain.i18n.json | 8 + i18n/ptb/extensions/html/package.i18n.json | 27 +++ i18n/ptb/extensions/jake/out/main.i18n.json | 8 + i18n/ptb/extensions/jake/package.i18n.json | 8 + .../features/bowerJSONContribution.i18n.json | 10 ++ .../packageJSONContribution.i18n.json | 13 ++ .../json/client/out/jsonMain.i18n.json | 8 + i18n/ptb/extensions/json/package.i18n.json | 15 ++ .../markdown/out/extension.i18n.json | 6 + .../out/previewContentProvider.i18n.json | 10 ++ .../markdown/out/security.i18n.json | 11 ++ .../ptb/extensions/markdown/package.i18n.json | 22 +++ .../out/codelensProvider.i18n.json | 6 + .../out/commandHandler.i18n.json | 6 + .../out/mergeDecorator.i18n.json | 6 + .../merge-conflict/package.i18n.json | 6 + i18n/ptb/extensions/npm/package.i18n.json | 6 + .../out/features/validationProvider.i18n.json | 13 ++ i18n/ptb/extensions/php/package.i18n.json | 14 ++ .../out/features/bufferSyncSupport.i18n.json | 12 ++ .../features/completionItemProvider.i18n.json | 9 + ...rectiveCommentCompletionProvider.i18n.json | 10 ++ .../implementationsCodeLensProvider.i18n.json | 10 ++ .../jsDocCompletionProvider.i18n.json | 8 + .../referencesCodeLensProvider.i18n.json | 10 ++ .../typescript/out/typescriptMain.i18n.json | 15 ++ .../out/typescriptServiceClient.i18n.json | 24 +++ .../typescript/out/utils/logger.i18n.json | 8 + .../out/utils/projectStatus.i18n.json | 12 ++ .../out/utils/typingsStatus.i18n.json | 12 ++ .../extensions/typescript/package.i18n.json | 45 +++++ .../browser/ui/actionbar/actionbar.i18n.json | 8 + .../vs/base/browser/ui/aria/aria.i18n.json | 8 + .../browser/ui/findinput/findInput.i18n.json | 8 + .../findinput/findInputCheckboxes.i18n.json | 10 ++ .../browser/ui/inputbox/inputBox.i18n.json | 10 ++ .../resourceviewer/resourceViewer.i18n.json | 15 ++ .../base/browser/ui/toolbar/toolbar.i18n.json | 8 + .../src/vs/base/common/errorMessage.i18n.json | 18 ++ .../base/common/jsonErrorMessages.i18n.json | 16 ++ .../src/vs/base/common/processes.i18n.json | 11 ++ .../ptb/src/vs/base/common/severity.i18n.json | 10 ++ i18n/ptb/src/vs/base/node/processes.i18n.json | 8 + i18n/ptb/src/vs/base/node/zip.i18n.json | 8 + .../browser/quickOpenModel.i18n.json | 9 + .../browser/quickOpenWidget.i18n.json | 9 + .../parts/tree/browser/treeDefaults.i18n.json | 8 + .../src/vs/code/electron-main/menus.i18n.json | 164 ++++++++++++++++++ .../vs/code/electron-main/window.i18n.json | 8 + .../vs/code/electron-main/windows.i18n.json | 22 +++ .../src/vs/code/node/cliProcessMain.i18n.json | 17 ++ .../config/commonEditorConfig.i18n.json | 76 ++++++++ .../common/config/editorOptions.i18n.json | 8 + .../editor/common/controller/cursor.i18n.json | 8 + .../model/textModelWithTokens.i18n.json | 8 + .../common/modes/modesRegistry.i18n.json | 8 + .../editor/common/services/bulkEdit.i18n.json | 11 ++ .../common/services/modeServiceImpl.i18n.json | 16 ++ .../services/modelServiceImpl.i18n.json | 9 + .../common/view/editorColorRegistry.i18n.json | 20 +++ .../browser/accessibility.i18n.json | 15 ++ .../common/bracketMatching.i18n.json | 8 + .../common/caretOperations.i18n.json | 9 + .../common/transpose.i18n.json | 8 + .../clipboard/browser/clipboard.i18n.json | 11 ++ .../contrib/comment/common/comment.i18n.json | 11 ++ .../contextmenu/browser/contextmenu.i18n.json | 8 + .../contrib/find/browser/findWidget.i18n.json | 21 +++ .../find/common/findController.i18n.json | 19 ++ .../contrib/folding/browser/folding.i18n.json | 14 ++ .../format/browser/formatActions.i18n.json | 13 ++ .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../gotoError/browser/gotoError.i18n.json | 13 ++ .../contrib/hover/browser/hover.i18n.json | 8 + .../hover/browser/modesContentHover.i18n.json | 8 + .../common/inPlaceReplace.i18n.json | 9 + .../indentation/common/indentation.i18n.json | 15 ++ .../inspectTMScopes.i18n.json | 9 + .../common/linesOperations.i18n.json | 25 +++ .../contrib/links/browser/links.i18n.json | 12 ++ .../multicursor/common/multicursor.i18n.json | 10 ++ .../browser/parameterHints.i18n.json | 8 + .../browser/parameterHintsWidget.i18n.json | 8 + .../browser/quickFixCommands.i18n.json | 10 ++ .../browser/referenceSearch.i18n.json | 9 + .../browser/referencesController.i18n.json | 8 + .../browser/referencesModel.i18n.json | 14 ++ .../browser/referencesWidget.i18n.json | 27 +++ .../contrib/rename/browser/rename.i18n.json | 11 ++ .../rename/browser/renameInputField.i18n.json | 8 + .../smartSelect/common/smartSelect.i18n.json | 9 + .../browser/suggestController.i18n.json | 9 + .../suggest/browser/suggestWidget.i18n.json | 21 +++ .../common/toggleTabFocusMode.i18n.json | 8 + .../common/wordHighlighter.i18n.json | 9 + .../browser/peekViewWidget.i18n.json | 8 + .../textMate/TMSyntax.i18n.json | 14 ++ ...guageConfigurationExtensionPoint.i18n.json | 23 +++ .../editor/node/textMate/TMGrammars.i18n.json | 13 ++ .../browser/menuItemActionItem.i18n.json | 8 + .../menusExtensionPoint.i18n.json | 41 +++++ .../common/configurationRegistry.i18n.json | 19 ++ .../platform/environment/node/argv.i18n.json | 32 ++++ .../extensionEnablementService.i18n.json | 8 + .../common/extensionManagement.i18n.json | 9 + .../node/extensionGalleryService.i18n.json | 9 + .../node/extensionManagementService.i18n.json | 22 +++ .../common/abstractExtensionService.i18n.json | 11 ++ .../common/extensionsRegistry.i18n.json | 24 +++ .../node/extensionValidator.i18n.json | 24 +++ .../node/integrityServiceImpl.i18n.json | 11 ++ .../jsonValidationExtensionPoint.i18n.json | 15 ++ .../abstractKeybindingService.i18n.json | 9 + .../common/keybindingLabels.i18n.json | 16 ++ .../markers/common/problemMatcher.i18n.json | 61 +++++++ .../platform/message/common/message.i18n.json | 10 ++ .../platform/request/node/request.i18n.json | 11 ++ .../common/telemetryService.i18n.json | 9 + .../theme/common/colorRegistry.i18n.json | 78 +++++++++ .../mainThreadExtensionService.i18n.json | 9 + .../mainThreadMessageService.i18n.json | 10 ++ .../api/node/extHostDiagnostics.i18n.json | 8 + .../api/node/extHostTreeViews.i18n.json | 10 ++ .../browser/actions/configureLocale.i18n.json | 13 ++ .../browser/actions/fileActions.i18n.json | 9 + .../toggleActivityBarVisibility.i18n.json | 9 + .../actions/toggleEditorLayout.i18n.json | 11 ++ .../actions/toggleSidebarPosition.i18n.json | 9 + .../actions/toggleSidebarVisibility.i18n.json | 9 + .../toggleStatusbarVisibility.i18n.json | 9 + .../browser/actions/toggleZenMode.i18n.json | 9 + .../activitybar/activitybarActions.i18n.json | 14 ++ .../activitybar/activitybarPart.i18n.json | 9 + .../browser/parts/compositePart.i18n.json | 9 + .../parts/editor/binaryDiffEditor.i18n.json | 8 + .../parts/editor/binaryEditor.i18n.json | 8 + .../editor/editor.contribution.i18n.json | 16 ++ .../parts/editor/editorActions.i18n.json | 55 ++++++ .../parts/editor/editorCommands.i18n.json | 12 ++ .../browser/parts/editor/editorPart.i18n.json | 14 ++ .../parts/editor/editorPicker.i18n.json | 13 ++ .../parts/editor/editorStatus.i18n.json | 49 ++++++ .../parts/editor/tabsTitleControl.i18n.json | 8 + .../parts/editor/textDiffEditor.i18n.json | 16 ++ .../browser/parts/editor/textEditor.i18n.json | 8 + .../parts/editor/textResourceEditor.i18n.json | 12 ++ .../parts/editor/titleControl.i18n.json | 14 ++ .../parts/panel/panelActions.i18n.json | 15 ++ .../browser/parts/panel/panelPart.i18n.json | 8 + .../quickopen/quickOpenController.i18n.json | 17 ++ .../quickopen.contribution.i18n.json | 12 ++ .../parts/sidebar/sidebarPart.i18n.json | 9 + .../parts/statusbar/statusbarPart.i18n.json | 9 + .../parts/titlebar/titlebarPart.i18n.json | 9 + .../vs/workbench/browser/quickopen.i18n.json | 11 ++ .../vs/workbench/browser/viewlet.i18n.json | 9 + .../src/vs/workbench/common/theme.i18n.json | 44 +++++ .../electron-browser/actions.i18n.json | 41 +++++ .../electron-browser/commands.i18n.json | 8 + .../electron-browser/crashReporter.i18n.json | 9 + .../electron-browser/extensionHost.i18n.json | 11 ++ .../main.contribution.i18n.json | 62 +++++++ .../workbench/electron-browser/main.i18n.json | 9 + .../electron-browser/shell.i18n.json | 8 + .../electron-browser/window.i18n.json | 15 ++ .../node/extensionHostMain.i18n.json | 8 + .../workbench/node/extensionPoints.i18n.json | 11 ++ .../cli.contribution.i18n.json | 18 ++ .../inspectKeybindings.i18n.json | 8 + .../toggleRenderControlCharacter.i18n.json | 8 + .../toggleRenderWhitespace.i18n.json | 8 + .../electron-browser/toggleWordWrap.i18n.json | 11 ++ .../wordWrapMigration.i18n.json | 11 ++ .../debug/browser/breakpointWidget.i18n.json | 13 ++ .../debug/browser/debugActionItems.i18n.json | 9 + .../debug/browser/debugActions.i18n.json | 49 ++++++ .../browser/debugActionsWidget.i18n.json | 8 + .../browser/debugContentProvider.i18n.json | 8 + .../browser/debugEditorActions.i18n.json | 15 ++ .../browser/debugEditorModelManager.i18n.json | 11 ++ .../debug/browser/debugQuickOpen.i18n.json | 11 ++ .../debug/browser/exceptionWidget.i18n.json | 11 ++ .../debug/browser/linkDetector.i18n.json | 9 + .../parts/debug/common/debug.i18n.json | 8 + .../parts/debug/common/debugModel.i18n.json | 9 + .../parts/debug/common/debugSource.i18n.json | 8 + .../debug.contribution.i18n.json | 20 +++ .../electron-browser/debugCommands.i18n.json | 8 + .../debugConfigurationManager.i18n.json | 38 ++++ .../debugEditorContribution.i18n.json | 20 +++ .../electron-browser/debugHover.i18n.json | 8 + .../electron-browser/debugService.i18n.json | 25 +++ .../electron-browser/debugViewer.i18n.json | 28 +++ .../electron-browser/debugViews.i18n.json | 20 +++ .../electronDebugActions.i18n.json | 11 ++ .../rawDebugSession.i18n.json | 12 ++ .../debug/electron-browser/repl.i18n.json | 11 ++ .../electron-browser/replViewer.i18n.json | 12 ++ .../statusbarColorProvider.i18n.json | 8 + .../terminalSupport.i18n.json | 9 + .../parts/debug/node/debugAdapter.i18n.json | 20 +++ .../actions/showEmmetCommands.i18n.json | 8 + .../actions/balance.i18n.json | 9 + .../actions/editPoints.i18n.json | 9 + .../actions/evaluateMath.i18n.json | 8 + .../actions/expandAbbreviation.i18n.json | 8 + .../actions/incrementDecrement.i18n.json | 13 ++ .../actions/matchingPair.i18n.json | 8 + .../actions/mergeLines.i18n.json | 8 + .../actions/reflectCssValue.i18n.json | 8 + .../actions/removeTag.i18n.json | 8 + .../actions/selectItem.i18n.json | 9 + .../actions/splitJoinTag.i18n.json | 8 + .../actions/toggleComment.i18n.json | 8 + .../actions/updateImageSize.i18n.json | 8 + .../actions/updateTag.i18n.json | 10 ++ .../actions/wrapWithAbbreviation.i18n.json | 10 ++ .../emmet.contribution.i18n.json | 13 ++ .../terminal.contribution.i18n.json | 15 ++ .../terminalService.i18n.json | 12 ++ .../treeExplorer.contribution.i18n.json | 14 ++ .../browser/treeExplorerActions.i18n.json | 8 + .../browser/treeExplorerService.i18n.json | 8 + .../browser/views/treeExplorerView.i18n.json | 8 + .../browser/dependenciesViewer.i18n.json | 9 + .../browser/extensionEditor.i18n.json | 39 +++++ .../browser/extensionsActions.i18n.json | 55 ++++++ .../browser/extensionsQuickOpen.i18n.json | 10 ++ .../common/extensionsFileTemplate.i18n.json | 10 ++ .../common/extensionsInput.i18n.json | 8 + .../extensionTipsService.i18n.json | 16 ++ .../extensions.contribution.i18n.json | 15 ++ .../extensionsActions.i18n.json | 11 ++ .../extensionsUtils.i18n.json | 10 ++ .../extensionsViewlet.i18n.json | 15 ++ .../node/extensionsWorkbenchService.i18n.json | 17 ++ .../electron-browser/feedback.i18n.json | 25 +++ .../editors/binaryFileEditor.i18n.json | 8 + .../browser/editors/textFileEditor.i18n.json | 11 ++ .../fileActions.contribution.i18n.json | 11 ++ .../parts/files/browser/fileActions.i18n.json | 73 ++++++++ .../files/browser/fileCommands.i18n.json | 9 + .../browser/files.contribution.i18n.json | 40 +++++ .../files/browser/saveErrorHandler.i18n.json | 16 ++ .../files/browser/views/emptyView.i18n.json | 11 ++ .../browser/views/explorerView.i18n.json | 9 + .../browser/views/explorerViewer.i18n.json | 12 ++ .../browser/views/openEditorsView.i18n.json | 11 ++ .../browser/views/openEditorsViewer.i18n.json | 13 ++ .../files/common/dirtyFilesTracker.i18n.json | 8 + .../common/editors/fileEditorInput.i18n.json | 8 + .../html/browser/html.contribution.i18n.json | 8 + .../html/browser/htmlPreviewPart.i18n.json | 8 + .../parts/html/browser/webview.i18n.json | 8 + .../parts/markers/common/messages.i18n.json | 39 +++++ .../markersElectronContributions.i18n.json | 8 + .../nps.contribution.i18n.json | 11 ++ .../browser/output.contribution.i18n.json | 10 ++ .../output/browser/outputActions.i18n.json | 11 ++ .../output/browser/outputPanel.i18n.json | 9 + .../parts/output/common/output.i18n.json | 9 + .../performance.contribution.i18n.json | 15 ++ .../browser/keybindingWidgets.i18n.json | 9 + .../browser/keybindingsEditor.i18n.json | 35 ++++ .../keybindingsEditorContribution.i18n.json | 10 ++ .../preferences.contribution.i18n.json | 10 ++ .../browser/preferencesActions.i18n.json | 14 ++ .../browser/preferencesEditor.i18n.json | 15 ++ .../browser/preferencesRenderers.i18n.json | 13 ++ .../browser/preferencesService.i18n.json | 13 ++ .../browser/preferencesWidgets.i18n.json | 10 ++ .../common/keybindingsEditorModel.i18n.json | 11 ++ .../common/preferencesModels.i18n.json | 9 + .../browser/commandsHandler.i18n.json | 16 ++ .../browser/gotoLineHandler.i18n.json | 14 ++ .../browser/gotoSymbolHandler.i18n.json | 34 ++++ .../quickopen/browser/helpHandler.i18n.json | 10 ++ .../browser/quickopen.contribution.i18n.json | 14 ++ .../browser/viewPickerHandler.i18n.json | 15 ++ .../scm.contribution.i18n.json | 12 ++ .../electron-browser/scmActivity.i18n.json | 8 + .../scm/electron-browser/scmMenus.i18n.json | 9 + .../scm/electron-browser/scmViewlet.i18n.json | 10 ++ .../browser/openAnythingHandler.i18n.json | 9 + .../search/browser/openFileHandler.i18n.json | 9 + .../browser/openSymbolHandler.i18n.json | 11 ++ .../browser/patternInputWidget.i18n.json | 12 ++ .../search/browser/replaceService.i18n.json | 8 + .../browser/search.contribution.i18n.json | 22 +++ .../search/browser/searchActions.i18n.json | 21 +++ .../browser/searchResultsView.i18n.json | 12 ++ .../search/browser/searchViewlet.i18n.json | 50 ++++++ .../search/browser/searchWidget.i18n.json | 15 ++ .../electron-browser/TMSnippets.i18n.json | 13 ++ .../electron-browser/insertSnippet.i18n.json | 8 + .../snippets.contribution.i18n.json | 16 ++ .../snippetsService.i18n.json | 9 + .../electron-browser/tabCompletion.i18n.json | 8 + .../parts/tasks/browser/quickOpen.i18n.json | 10 ++ .../tasks/browser/restartQuickOpen.i18n.json | 10 ++ .../tasks/browser/taskQuickOpen.i18n.json | 10 ++ .../browser/terminateQuickOpen.i18n.json | 10 ++ .../tasks/common/taskConfiguration.i18n.json | 17 ++ .../tasks/common/taskTemplates.i18n.json | 13 ++ .../jsonSchemaCommon.i18n.json | 38 ++++ .../electron-browser/jsonSchema_v1.i18n.json | 12 ++ .../electron-browser/jsonSchema_v2.i18n.json | 14 ++ .../task.contribution.i18n.json | 47 +++++ .../terminalTaskSystem.i18n.json | 11 ++ .../node/processRunnerDetector.i18n.json | 15 ++ .../tasks/node/processTaskSystem.i18n.json | 12 ++ .../terminal.contribution.i18n.json | 30 ++++ .../terminalActions.i18n.json | 32 ++++ .../terminalColorRegistry.i18n.json | 10 ++ .../terminalConfigHelper.i18n.json | 10 ++ .../terminalInstance.i18n.json | 11 ++ .../terminalLinkHandler.i18n.json | 9 + .../electron-browser/terminalPanel.i18n.json | 11 ++ .../terminalService.i18n.json | 15 ++ .../themes.contribution.i18n.json | 19 ++ ...edWorkspaceSettings.contribution.i18n.json | 11 ++ .../releaseNotesInput.i18n.json | 8 + .../update.contribution.i18n.json | 10 ++ .../update/electron-browser/update.i18n.json | 19 ++ .../electron-browser/watermark.i18n.json | 24 +++ .../overlay/browser/welcomeOverlay.i18n.json | 17 ++ .../vs_code_welcome_page.i18n.json | 44 +++++ .../welcomePage.contribution.i18n.json | 10 ++ .../electron-browser/welcomePage.i18n.json | 31 ++++ .../editor/editorWalkThrough.i18n.json | 9 + .../walkThrough.contribution.i18n.json | 10 ++ .../walkThroughActions.i18n.json | 11 ++ .../walkThroughPart.i18n.json | 10 ++ .../configurationEditingService.i18n.json | 17 ++ .../editor/browser/editorService.i18n.json | 8 + .../electron-browser/fileService.i18n.json | 11 ++ .../services/files/node/fileService.i18n.json | 14 ++ .../common/keybindingEditing.i18n.json | 11 ++ .../keybindingService.i18n.json | 26 +++ .../message/browser/messageList.i18n.json | 14 ++ .../electron-browser/messageService.i18n.json | 9 + .../common/workbenchModeService.i18n.json | 16 ++ .../common/textFileEditorModel.i18n.json | 9 + .../textfile/common/textFileService.i18n.json | 8 + .../textFileService.i18n.json | 18 ++ .../themes/common/colorThemeSchema.i18n.json | 11 ++ .../common/fileIconThemeSchema.i18n.json | 37 ++++ .../electron-browser/colorThemeData.i18n.json | 13 ++ .../workbenchThemeService.i18n.json | 32 ++++ .../markdown/out/extension.i18n.json | 6 + .../out/codelensProvider.i18n.json | 6 + .../out/commandHandler.i18n.json | 6 + .../out/mergeDecorator.i18n.json | 6 + .../merge-conflict/package.i18n.json | 6 + i18n/rus/extensions/npm/package.i18n.json | 6 + .../resourceviewer/resourceViewer.i18n.json | 2 - .../src/vs/code/electron-main/menus.i18n.json | 2 + .../config/commonEditorConfig.i18n.json | 1 - .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../main.contribution.i18n.json | 1 + .../extensionsUtils.i18n.json | 6 +- .../browser/files.contribution.i18n.json | 1 - .../performance.contribution.i18n.json | 6 +- .../electron-browser/welcomePage.i18n.json | 5 + 587 files changed, 6511 insertions(+), 128 deletions(-) create mode 100644 build/win32/i18n/messages.pt-br.isl create mode 100644 i18n/chs/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/chs/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/chs/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/chs/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/chs/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/chs/extensions/npm/package.i18n.json create mode 100644 i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json create mode 100644 i18n/cht/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/cht/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/cht/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/cht/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/cht/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/cht/extensions/npm/package.i18n.json create mode 100644 i18n/cht/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/cht/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json create mode 100644 i18n/deu/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/deu/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/deu/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/deu/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/deu/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/deu/extensions/npm/package.i18n.json create mode 100644 i18n/deu/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/deu/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json create mode 100644 i18n/esn/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/esn/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/esn/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/esn/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/esn/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/esn/extensions/npm/package.i18n.json create mode 100644 i18n/esn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/esn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json create mode 100644 i18n/fra/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/fra/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/fra/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/fra/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/fra/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/fra/extensions/npm/package.i18n.json create mode 100644 i18n/fra/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/fra/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json create mode 100644 i18n/ita/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/ita/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/ita/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/ita/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/ita/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/ita/extensions/npm/package.i18n.json create mode 100644 i18n/ita/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/ita/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json create mode 100644 i18n/jpn/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/jpn/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/jpn/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/jpn/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/jpn/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/jpn/extensions/npm/package.i18n.json create mode 100644 i18n/jpn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/jpn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json create mode 100644 i18n/kor/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/kor/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/kor/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/kor/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/kor/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/kor/extensions/npm/package.i18n.json create mode 100644 i18n/kor/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/kor/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json create mode 100644 i18n/ptb/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json create mode 100644 i18n/ptb/extensions/css/client/out/cssMain.i18n.json create mode 100644 i18n/ptb/extensions/css/package.i18n.json create mode 100644 i18n/ptb/extensions/extension-editing/out/packageDocumentHelper.i18n.json create mode 100644 i18n/ptb/extensions/git/out/askpass-main.i18n.json create mode 100644 i18n/ptb/extensions/git/out/commands.i18n.json create mode 100644 i18n/ptb/extensions/git/out/main.i18n.json create mode 100644 i18n/ptb/extensions/git/out/model.i18n.json create mode 100644 i18n/ptb/extensions/git/out/scmProvider.i18n.json create mode 100644 i18n/ptb/extensions/git/out/statusbar.i18n.json create mode 100644 i18n/ptb/extensions/git/package.i18n.json create mode 100644 i18n/ptb/extensions/grunt/out/main.i18n.json create mode 100644 i18n/ptb/extensions/grunt/package.i18n.json create mode 100644 i18n/ptb/extensions/gulp/out/main.i18n.json create mode 100644 i18n/ptb/extensions/gulp/package.i18n.json create mode 100644 i18n/ptb/extensions/html/client/out/htmlMain.i18n.json create mode 100644 i18n/ptb/extensions/html/package.i18n.json create mode 100644 i18n/ptb/extensions/jake/out/main.i18n.json create mode 100644 i18n/ptb/extensions/jake/package.i18n.json create mode 100644 i18n/ptb/extensions/javascript/out/features/bowerJSONContribution.i18n.json create mode 100644 i18n/ptb/extensions/javascript/out/features/packageJSONContribution.i18n.json create mode 100644 i18n/ptb/extensions/json/client/out/jsonMain.i18n.json create mode 100644 i18n/ptb/extensions/json/package.i18n.json create mode 100644 i18n/ptb/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/ptb/extensions/markdown/out/previewContentProvider.i18n.json create mode 100644 i18n/ptb/extensions/markdown/out/security.i18n.json create mode 100644 i18n/ptb/extensions/markdown/package.i18n.json create mode 100644 i18n/ptb/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/ptb/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/ptb/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/ptb/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/ptb/extensions/npm/package.i18n.json create mode 100644 i18n/ptb/extensions/php/out/features/validationProvider.i18n.json create mode 100644 i18n/ptb/extensions/php/package.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/features/bufferSyncSupport.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/features/completionItemProvider.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/features/implementationsCodeLensProvider.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/features/jsDocCompletionProvider.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/features/referencesCodeLensProvider.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/typescriptMain.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/typescriptServiceClient.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/utils/logger.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/utils/projectStatus.i18n.json create mode 100644 i18n/ptb/extensions/typescript/out/utils/typingsStatus.i18n.json create mode 100644 i18n/ptb/extensions/typescript/package.i18n.json create mode 100644 i18n/ptb/src/vs/base/browser/ui/actionbar/actionbar.i18n.json create mode 100644 i18n/ptb/src/vs/base/browser/ui/aria/aria.i18n.json create mode 100644 i18n/ptb/src/vs/base/browser/ui/findinput/findInput.i18n.json create mode 100644 i18n/ptb/src/vs/base/browser/ui/findinput/findInputCheckboxes.i18n.json create mode 100644 i18n/ptb/src/vs/base/browser/ui/inputbox/inputBox.i18n.json create mode 100644 i18n/ptb/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json create mode 100644 i18n/ptb/src/vs/base/browser/ui/toolbar/toolbar.i18n.json create mode 100644 i18n/ptb/src/vs/base/common/errorMessage.i18n.json create mode 100644 i18n/ptb/src/vs/base/common/jsonErrorMessages.i18n.json create mode 100644 i18n/ptb/src/vs/base/common/processes.i18n.json create mode 100644 i18n/ptb/src/vs/base/common/severity.i18n.json create mode 100644 i18n/ptb/src/vs/base/node/processes.i18n.json create mode 100644 i18n/ptb/src/vs/base/node/zip.i18n.json create mode 100644 i18n/ptb/src/vs/base/parts/quickopen/browser/quickOpenModel.i18n.json create mode 100644 i18n/ptb/src/vs/base/parts/quickopen/browser/quickOpenWidget.i18n.json create mode 100644 i18n/ptb/src/vs/base/parts/tree/browser/treeDefaults.i18n.json create mode 100644 i18n/ptb/src/vs/code/electron-main/menus.i18n.json create mode 100644 i18n/ptb/src/vs/code/electron-main/window.i18n.json create mode 100644 i18n/ptb/src/vs/code/electron-main/windows.i18n.json create mode 100644 i18n/ptb/src/vs/code/node/cliProcessMain.i18n.json create mode 100644 i18n/ptb/src/vs/editor/common/config/commonEditorConfig.i18n.json create mode 100644 i18n/ptb/src/vs/editor/common/config/editorOptions.i18n.json create mode 100644 i18n/ptb/src/vs/editor/common/controller/cursor.i18n.json create mode 100644 i18n/ptb/src/vs/editor/common/model/textModelWithTokens.i18n.json create mode 100644 i18n/ptb/src/vs/editor/common/modes/modesRegistry.i18n.json create mode 100644 i18n/ptb/src/vs/editor/common/services/bulkEdit.i18n.json create mode 100644 i18n/ptb/src/vs/editor/common/services/modeServiceImpl.i18n.json create mode 100644 i18n/ptb/src/vs/editor/common/services/modelServiceImpl.i18n.json create mode 100644 i18n/ptb/src/vs/editor/common/view/editorColorRegistry.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/accessibility/browser/accessibility.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/bracketMatching/common/bracketMatching.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/caretOperations/common/caretOperations.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/caretOperations/common/transpose.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/clipboard/browser/clipboard.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/comment/common/comment.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/contextmenu/browser/contextmenu.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/find/browser/findWidget.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/find/common/findController.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/folding/browser/folding.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/format/browser/formatActions.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/hover/browser/hover.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/hover/browser/modesContentHover.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/indentation/common/indentation.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/linesOperations/common/linesOperations.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/links/browser/links.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/multicursor/common/multicursor.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/parameterHints/browser/parameterHints.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/quickFix/browser/quickFixCommands.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesController.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/rename/browser/rename.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/rename/browser/renameInputField.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/smartSelect/common/smartSelect.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/suggest/browser/suggestController.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.i18n.json create mode 100644 i18n/ptb/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.i18n.json create mode 100644 i18n/ptb/src/vs/editor/electron-browser/textMate/TMSyntax.i18n.json create mode 100644 i18n/ptb/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json create mode 100644 i18n/ptb/src/vs/editor/node/textMate/TMGrammars.i18n.json create mode 100644 i18n/ptb/src/vs/platform/actions/browser/menuItemActionItem.i18n.json create mode 100644 i18n/ptb/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json create mode 100644 i18n/ptb/src/vs/platform/configuration/common/configurationRegistry.i18n.json create mode 100644 i18n/ptb/src/vs/platform/environment/node/argv.i18n.json create mode 100644 i18n/ptb/src/vs/platform/extensionManagement/common/extensionEnablementService.i18n.json create mode 100644 i18n/ptb/src/vs/platform/extensionManagement/common/extensionManagement.i18n.json create mode 100644 i18n/ptb/src/vs/platform/extensionManagement/node/extensionGalleryService.i18n.json create mode 100644 i18n/ptb/src/vs/platform/extensionManagement/node/extensionManagementService.i18n.json create mode 100644 i18n/ptb/src/vs/platform/extensions/common/abstractExtensionService.i18n.json create mode 100644 i18n/ptb/src/vs/platform/extensions/common/extensionsRegistry.i18n.json create mode 100644 i18n/ptb/src/vs/platform/extensions/node/extensionValidator.i18n.json create mode 100644 i18n/ptb/src/vs/platform/integrity/node/integrityServiceImpl.i18n.json create mode 100644 i18n/ptb/src/vs/platform/jsonschemas/common/jsonValidationExtensionPoint.i18n.json create mode 100644 i18n/ptb/src/vs/platform/keybinding/common/abstractKeybindingService.i18n.json create mode 100644 i18n/ptb/src/vs/platform/keybinding/common/keybindingLabels.i18n.json create mode 100644 i18n/ptb/src/vs/platform/markers/common/problemMatcher.i18n.json create mode 100644 i18n/ptb/src/vs/platform/message/common/message.i18n.json create mode 100644 i18n/ptb/src/vs/platform/request/node/request.i18n.json create mode 100644 i18n/ptb/src/vs/platform/telemetry/common/telemetryService.i18n.json create mode 100644 i18n/ptb/src/vs/platform/theme/common/colorRegistry.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/api/electron-browser/mainThreadExtensionService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/api/electron-browser/mainThreadMessageService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/api/node/extHostDiagnostics.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/api/node/extHostTreeViews.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/actions/configureLocale.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/actions/fileActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/actions/toggleActivityBarVisibility.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/actions/toggleEditorLayout.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/actions/toggleSidebarPosition.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/actions/toggleSidebarVisibility.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/actions/toggleStatusbarVisibility.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/actions/toggleZenMode.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/activitybar/activitybarActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/compositePart.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/binaryDiffEditor.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/binaryEditor.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/editor.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/editorActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/editorCommands.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/editorPart.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/editorPicker.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/tabsTitleControl.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/textDiffEditor.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/textEditor.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/textResourceEditor.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/editor/titleControl.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/panel/panelActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/panel/panelPart.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/quickopen/quickOpenController.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/quickopen/quickopen.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/sidebar/sidebarPart.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/statusbar/statusbarPart.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/titlebar/titlebarPart.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/quickopen.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/viewlet.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/common/theme.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/electron-browser/actions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/electron-browser/commands.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/electron-browser/crashReporter.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/electron-browser/extensionHost.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/electron-browser/main.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/electron-browser/main.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/electron-browser/shell.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/electron-browser/window.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/node/extensionHostMain.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/node/extensionPoints.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/cli/electron-browser/cli.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderControlCharacter.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderWhitespace.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/wordWrapMigration.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/browser/breakpointWidget.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/browser/debugActionItems.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/browser/debugActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/browser/debugActionsWidget.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/browser/debugContentProvider.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/browser/debugEditorActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/browser/debugEditorModelManager.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/browser/debugQuickOpen.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/browser/exceptionWidget.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/browser/linkDetector.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/common/debug.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/common/debugModel.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/common/debugSource.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debug.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugConfigurationManager.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugHover.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugViewer.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/repl.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/replViewer.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/electron-browser/terminalSupport.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/browser/actions/showEmmetCommands.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/balance.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/matchingPair.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/mergeLines.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/reflectCssValue.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/selectItem.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/toggleComment.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/execution/electron-browser/terminal.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/execution/electron-browser/terminalService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorerActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorerService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/explorers/browser/views/treeExplorerView.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/browser/dependenciesViewer.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionsQuickOpen.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/common/extensionsFileTemplate.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/common/extensionsInput.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/feedback/electron-browser/feedback.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/editors/binaryFileEditor.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/editors/textFileEditor.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/fileActions.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/fileActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/fileCommands.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/files.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/saveErrorHandler.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/views/explorerView.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/views/explorerViewer.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsViewer.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/common/dirtyFilesTracker.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/html/browser/html.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/html/browser/htmlPreviewPart.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/html/browser/webview.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/markers/common/messages.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/markers/electron-browser/markersElectronContributions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/nps/electron-browser/nps.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/output/browser/output.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/output/browser/outputActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/output/browser/outputPanel.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/output/common/output.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingWidgets.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/browser/preferences.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesEditor.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesWidgets.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/preferences/common/preferencesModels.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/quickopen/browser/gotoLineHandler.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/quickopen/browser/gotoSymbolHandler.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/quickopen/browser/helpHandler.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/quickopen/browser/viewPickerHandler.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmActivity.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmViewlet.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/search/browser/openAnythingHandler.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/search/browser/openFileHandler.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/search/browser/openSymbolHandler.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/search/browser/patternInputWidget.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/search/browser/replaceService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/search/browser/search.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/search/browser/searchActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/search/browser/searchViewlet.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/search/browser/searchWidget.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/insertSnippet.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/snippetsService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/tabCompletion.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/common/taskTemplates.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/node/processRunnerDetector.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/trust/electron-browser/unsupportedWorkspaceSettings.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/update/electron-browser/releaseNotesInput.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/update/electron-browser/update.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/update/electron-browser/update.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/editor/editorWalkThrough.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThrough.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughActions.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/editor/browser/editorService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/files/electron-browser/fileService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/files/node/fileService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/keybinding/common/keybindingEditing.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/keybinding/electron-browser/keybindingService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/message/browser/messageList.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/message/electron-browser/messageService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/mode/common/workbenchModeService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/textfile/common/textFileEditorModel.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/textfile/common/textFileService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/textfile/electron-browser/textFileService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/themes/common/colorThemeSchema.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/themes/common/fileIconThemeSchema.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/themes/electron-browser/colorThemeData.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json create mode 100644 i18n/rus/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/rus/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/rus/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/rus/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/rus/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/rus/extensions/npm/package.i18n.json create mode 100644 i18n/rus/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/rus/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json diff --git a/build/win32/i18n/messages.pt-br.isl b/build/win32/i18n/messages.pt-br.isl new file mode 100644 index 00000000000..7021e814e8f --- /dev/null +++ b/build/win32/i18n/messages.pt-br.isl @@ -0,0 +1,8 @@ +[CustomMessages] +AddContextMenuFiles=Adicione a ação "Abrir com %1" ao menu de contexto de arquivo do Windows Explorer +AddContextMenuFolders=Adicione a ação "Abrir com %1" ao menu de contexto de diretório do Windows Explorer +AssociateWithFiles=Registre %1 como um editor para tipos de arquivos suportados +AddToPath=Adicione em PATH (disponível após reiniciar) +RunAfter=Executar %1 após a instalação +Other=Outros: +SourceFile=Arquivo Fonte %1 \ No newline at end of file diff --git a/i18n/chs/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json b/i18n/chs/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json index 6ad910135a0..f40aa81fa48 100644 --- a/i18n/chs/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json +++ b/i18n/chs/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json @@ -5,7 +5,7 @@ // Do not edit this file. It is machine generated. { "activeEditorShort": "例如 myFile.txt", - "activeEditorMedium": "e.g. myFolder/myFile.txt", + "activeEditorMedium": "例如 myFolder/myFile.txt", "activeEditorLong": "例如 /Users/Development/myProject/myFolder/myFile.txt", "rootName": "例如 myProject", "rootPath": "例如 /Users/Development/myProject", diff --git a/i18n/chs/extensions/gulp/out/main.i18n.json b/i18n/chs/extensions/gulp/out/main.i18n.json index 500082cf82f..bda8a250c25 100644 --- a/i18n/chs/extensions/gulp/out/main.i18n.json +++ b/i18n/chs/extensions/gulp/out/main.i18n.json @@ -4,5 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "execFailed": "自动检测 gulp 失败,错误为: {0}" + "execFailed": "自动检测 gulp 失败,错误:{0}" } \ No newline at end of file diff --git a/i18n/chs/extensions/jake/out/main.i18n.json b/i18n/chs/extensions/jake/out/main.i18n.json index 8b6ad71cd4e..d2f56bdda98 100644 --- a/i18n/chs/extensions/jake/out/main.i18n.json +++ b/i18n/chs/extensions/jake/out/main.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "execFailed": "自动检测 Jake 失败,错误:{0}" +} \ No newline at end of file diff --git a/i18n/chs/extensions/jake/package.i18n.json b/i18n/chs/extensions/jake/package.i18n.json index 8b6ad71cd4e..46f020cf890 100644 --- a/i18n/chs/extensions/jake/package.i18n.json +++ b/i18n/chs/extensions/jake/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.jake.autoDetect": "控制自动检测 Jake 任务是å¦æ‰“开。默认开å¯ã€‚" +} \ No newline at end of file diff --git a/i18n/chs/extensions/markdown/out/extension.i18n.json b/i18n/chs/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/chs/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/chs/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/chs/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/chs/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/chs/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/chs/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/chs/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/chs/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/chs/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/chs/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/chs/extensions/merge-conflict/package.i18n.json b/i18n/chs/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/chs/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/chs/extensions/npm/package.i18n.json b/i18n/chs/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/chs/extensions/npm/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/chs/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/chs/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index 7b395b9c15a..4e5bf82d935 100644 --- a/i18n/chs/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/chs/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,8 +6,6 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "图åƒå¤ªå¤§ï¼Œæ— æ³•åœ¨ç¼–辑器中显示。 ", - "resourceOpenExternalButton": "打开图片", - "resourceOpenExternalText": " 是å¦ä½¿ç”¨å¤–部程åº?", "nativeBinaryError": "文件将ä¸åœ¨ç¼–辑器中显示,因为它是二进制文件ã€éžå¸¸å¤§æˆ–使用ä¸æ”¯æŒçš„文本编ç ã€‚", "sizeB": "{0} B", "sizeKB": "{0} KB", diff --git a/i18n/chs/src/vs/code/electron-main/menus.i18n.json b/i18n/chs/src/vs/code/electron-main/menus.i18n.json index 16b5dc1479a..4f7e61e056c 100644 --- a/i18n/chs/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/chs/src/vs/code/electron-main/menus.i18n.json @@ -146,7 +146,7 @@ "miInteractivePlayground": "交互å¼æ¼”练场(&&I)", "miDocumentation": "文档(&&D)", "miReleaseNotes": "å‘行说明(&&R)", - "miKeyboardShortcuts": "键盘快æ·æ–¹å¼å‚考(&&K)", + "miKeyboardShortcuts": "å¿«æ·é”®å‚考(&&K)", "miIntroductoryVideos": "介ç»æ€§è§†é¢‘(&&V)", "miTwitter": "在 Twitter 上加入我们(&&J)", "miUserVoice": "æœç´¢åŠŸèƒ½è¯·æ±‚(&&S)", @@ -159,6 +159,6 @@ "miDownloadingUpdate": "正在下载更新...", "miInstallingUpdate": "正在安装更新...", "miCheckForUpdates": "检查更新...", - "aboutDetail": "\n版本 {0}\næ交 {1}\n日期 {2}\nShell {3}\n呈现器 {4}\nNode {5}", + "aboutDetail": "\n版本 {0}\næ交 {1}\n日期 {2}\nShell {3}\n渲染器 {4}\nNode {5}", "okButton": "确定" } \ No newline at end of file diff --git a/i18n/chs/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/chs/src/vs/editor/common/config/commonEditorConfig.i18n.json index ad55e59f4eb..5c4e0b1ea13 100644 --- a/i18n/chs/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/chs/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -14,7 +14,7 @@ "rulers": "显示垂直标尺的列", "wordSeparators": "执行文字相关的导航或æ“作时将用作文字分隔符的字符", "tabSize": "一个制表符等于的空格数。该设置在 `editor.detectIndentation` å¯ç”¨æ—¶æ ¹æ®æ–‡ä»¶å†…容进行é‡å†™ã€‚", - "tabSize.errorMessage": "应为 \\\\\"number\\\\\"。注æ„,值\\\\\"auto\\\\\"已由 \\\\\"editor.detectIndentation\\\\\" 设置替æ¢ã€‚", + "tabSize.errorMessage": "应为“numberâ€ã€‚注æ„,值“autoâ€å·²ç”±â€œeditor.detectIndentationâ€è®¾ç½®æ›¿æ¢ã€‚", "insertSpaces": "按 \"Tab\" æ—¶æ’入空格。该设置在 `editor.detectIndentation` å¯ç”¨æ—¶æ ¹æ®æ–‡ä»¶å†…容进行é‡å†™ã€‚", "insertSpaces.errorMessage": "应为 \"boolean\"。注æ„,值 \"auto\" 已由 \"editor.detectIndentation\" 设置替æ¢ã€‚", "detectIndentation": "当打开文件时,将基于文件内容检测 \"editor.tabSize\" å’Œ \"editor.insertSpaces\"。", @@ -29,7 +29,7 @@ "wordWrap.bounded": "将在最å°è§†åŒºå’Œ \"editor.wordWrapColumn\" 处æ¢è¡Œã€‚", "wordWrap": "控制折行方å¼ã€‚å¯ä»¥é€‰æ‹©ï¼š - “off†(ç¦ç”¨æŠ˜è¡Œï¼‰ï¼Œ - “on†(视区折行), - “wordWrapColumnâ€ï¼ˆåœ¨â€œeditor.wordWrapColumnâ€å¤„折行)或 - “boundedâ€ï¼ˆåœ¨è§†åŒºä¸Žâ€œeditor.wordWrapColumnâ€ä¸¤è€…的较å°è€…处折行)。", "wordWrapColumn": "在 \"editor.wordWrap\" 为 \"wordWrapColumn\" 或 \"bounded\" 时控制编辑器列的æ¢è¡Œã€‚", - "wrappingIndent": "控制æ¢è¡Œçš„行的缩进。å¯ä»¥æ˜¯\\\\\"none\\\\\"〠\\\\\"same\\\\\" 或 \\\\\"indent\\\\\"。", + "wrappingIndent": "控制折行的缩进。å¯ä»¥æ˜¯â€œnoneâ€ã€â€œsameâ€æˆ–“indentâ€ã€‚", "mouseWheelScrollSensitivity": "è¦å¯¹é¼ æ ‡æ»šè½®æ»šåŠ¨äº‹ä»¶çš„ \"deltaX\" å’Œ \"deltaY\" 使用的乘数 ", "quickSuggestions.strings": "在字符串内å¯ç”¨å¿«é€Ÿå»ºè®®ã€‚", "quickSuggestions.comments": "在注释内å¯ç”¨å¿«é€Ÿå»ºè®®ã€‚", @@ -41,7 +41,6 @@ "formatOnType": "控制编辑器是å¦åº”在键入åŽè‡ªåŠ¨è®¾ç½®è¡Œçš„æ ¼å¼", "formatOnPaste": "控制编辑器是å¦åº”自动设置粘贴内容的格å¼ã€‚æ ¼å¼åŒ–程åºå¿…é¡»å¯ç”¨å¹¶ä¸”能设置文档中æŸä¸€èŒƒå›´çš„æ ¼å¼ã€‚", "suggestOnTriggerCharacters": "控制键入触å‘器字符时是å¦åº”自动显示建议", - "acceptSuggestionOnEnter": "控制除了 \"Tab\" 键以外,是å¦è¿˜åº”在é‡åˆ° \"Enter\" 键时接å—建议。帮助é¿å…“æ’入新行â€æˆ–“接å—建议â€ä¹‹é—´å‡ºçŽ°æ­§ä¹‰ã€‚", "acceptSuggestionOnCommitCharacter": "控制是å¦åº”在é‡åˆ°æ交字符时接å—建议。例如,在 JavaScript 中,分å·(\";\")å¯ä»¥ä¸ºæ交字符,å¯æŽ¥å—建议并键入该字符。", "snippetSuggestions": "控制是å¦å°†ä»£ç æ®µä¸Žå…¶ä»–建议一起显示以åŠå®ƒä»¬çš„排åºæ–¹å¼ã€‚", "emptySelectionClipboard": "控制没有选择内容的å¤åˆ¶æ˜¯å¦å¤åˆ¶å½“å‰è¡Œã€‚", @@ -63,6 +62,7 @@ "renderLineHighlight": "控制编辑器应如何呈现当å‰è¡Œçªå‡ºæ˜¾ç¤ºï¼Œå¯èƒ½ä¸ºâ€œæ— â€ã€â€œè£…订线â€ã€â€œçº¿â€å’Œâ€œå…¨éƒ¨â€ã€‚", "codeLens": "控制编辑器是å¦æ˜¾ç¤ºä»£ç æ»¤é•œ", "folding": "控制编辑器是å¦å¯ç”¨ä»£ç æŠ˜å åŠŸèƒ½", + "showFoldingControls": "控制是å¦è‡ªåŠ¨éšè—导航线上的折å æŽ§ä»¶ã€‚", "matchBrackets": "当选择其中一项时,将çªå‡ºæ˜¾ç¤ºåŒ¹é…的括å·ã€‚", "glyphMargin": "控制编辑器是å¦åº”呈现垂直字形边è·ã€‚字形边è·æœ€å¸¸ç”¨äºŽè°ƒè¯•ã€‚", "useTabStops": "在制表ä½åŽæ’入和删除空格", diff --git a/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..e788771d2f2 --- /dev/null +++ b/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "未找到“{0}â€çš„任何定义", + "generic.noResults": "找ä¸åˆ°å®šä¹‰", + "meta.title": " – {0} 定义", + "actions.goToDecl.label": "转到定义", + "actions.goToDeclToSide.label": "打开侧边的定义", + "actions.previewDecl.label": "查看定义", + "goToImplementation.noResultWord": "未找到“{0}â€çš„实现", + "goToImplementation.generic.noResults": "未找到实现", + "meta.implementations.title": "– {0} 个实现", + "actions.goToImplementation.label": "转到实现", + "actions.peekImplementation.label": "速览实现", + "goToTypeDefinition.noResultWord": "未找到“{0}â€çš„类型定义", + "goToTypeDefinition.generic.noResults": "未找到类型定义", + "meta.typeDefinitions.title": " – {0} 个类型定义", + "actions.goToTypeDefinition.label": "转到类型定义", + "actions.peekTypeDefinition.label": "快速查看类型定义" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..ab0b4761cf9 --- /dev/null +++ b/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "å•å‡»æ˜¾ç¤º {0} 个定义。" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/editor/contrib/indentation/common/indentation.i18n.json b/i18n/chs/src/vs/editor/contrib/indentation/common/indentation.i18n.json index 76fa4543d53..5bd5906da32 100644 --- a/i18n/chs/src/vs/editor/contrib/indentation/common/indentation.i18n.json +++ b/i18n/chs/src/vs/editor/contrib/indentation/common/indentation.i18n.json @@ -8,7 +8,7 @@ "indentationToTabs": "将缩进转æ¢ä¸ºåˆ¶è¡¨ç¬¦", "configuredTabSize": "å·²é…置制表符大å°", "selectTabWidth": "选择当å‰æ–‡ä»¶çš„制表符大å°", - "indentUsingTabs": "使用 \\\\\"Tab\\\\\" 缩进", + "indentUsingTabs": "使用“Tabâ€ç¼©è¿›", "indentUsingSpaces": "使用空格缩进", "detectIndentation": "检查内容中的缩进", "editor.reindentlines": "é‡æ–°ç¼©è¿›è¡Œ" diff --git a/i18n/chs/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json b/i18n/chs/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json index 4e1a0a30e42..ec34ba659f1 100644 --- a/i18n/chs/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json +++ b/i18n/chs/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json @@ -9,7 +9,7 @@ "editorSuggestWidgetForeground": "建议å°ç»„件的å‰æ™¯é¢œè‰²ã€‚", "editorSuggestWidgetSelectedBackground": "建议å°ç»„件中被选择æ¡ç›®çš„背景颜色。", "editorSuggestWidgetHighlightForeground": "建议å°ç»„件中匹é…内容的高亮颜色。", - "readMore": "阅读更多...{0}", + "readMore": "阅读详细信æ¯...{0}", "suggestionWithDetailsAriaLabel": "{0}(建议)具有详细信æ¯", "suggestionAriaLabel": "{0},建议", "readLess": "阅读简略信æ¯...{0}", diff --git a/i18n/chs/src/vs/platform/configuration/common/configurationRegistry.i18n.json b/i18n/chs/src/vs/platform/configuration/common/configurationRegistry.i18n.json index ea616506b8e..781727fae4d 100644 --- a/i18n/chs/src/vs/platform/configuration/common/configurationRegistry.i18n.json +++ b/i18n/chs/src/vs/platform/configuration/common/configurationRegistry.i18n.json @@ -10,7 +10,7 @@ "vscode.extension.contributes.configuration": "用于é…置字符串。", "vscode.extension.contributes.configuration.title": "设置摘è¦ã€‚此标签将在设置文件中用作分隔注释。", "vscode.extension.contributes.configuration.properties": "é…置属性的æ述。", - "config.property.languageDefault": "无法注册“{0}â€ã€‚这符åˆå±žæ€§æ¨¡å¼ \"\\\\[.*\\\\]$\",å¯ç”¨äºŽæ述特定语言编辑器设置。请使用 \"configurationDefaults\"。", + "config.property.languageDefault": "无法注册“{0}â€ã€‚其符åˆæè¿°ç‰¹å®šè¯­è¨€ç¼–è¾‘å™¨è®¾ç½®çš„è¡¨è¾¾å¼ \"\\\\[.*\\\\]$\"。请使用 \"configurationDefaults\"。", "config.property.duplicate": "无法注册“{0}â€ã€‚此属性已注册。", "invalid.properties": "configuration.properties 必须是对象", "invalid.type": "如果进行设置,\"configuration.type\" 必须设置为对象", diff --git a/i18n/chs/src/vs/platform/markers/common/problemMatcher.i18n.json b/i18n/chs/src/vs/platform/markers/common/problemMatcher.i18n.json index 7dc0d66e0aa..b9fc2ddbbde 100644 --- a/i18n/chs/src/vs/platform/markers/common/problemMatcher.i18n.json +++ b/i18n/chs/src/vs/platform/markers/common/problemMatcher.i18n.json @@ -34,6 +34,7 @@ "ProblemMatcherParser.noValidIdentifier": "错误: 模å¼å±žæ€§ {0} 是无效的模å¼å˜é‡å。", "ProblemMatcherParser.problemPattern.watchingMatcher": "问题匹é…程åºå¿…须定义监视的开始模å¼å’Œç»“æŸæ¨¡å¼ã€‚", "ProblemMatcherParser.invalidRegexp": "错误: 字符串 {0} ä¸æ˜¯æœ‰æ•ˆçš„正则表达å¼ã€‚\n", + "WatchingPatternSchema.regexp": "用于检测åŽå°ä»»åŠ¡å¼€å§‹æˆ–结æŸçš„正则表达å¼ã€‚", "WatchingPatternSchema.file": "文件å的匹é…组索引。å¯ä»¥çœç•¥ã€‚", "PatternTypeSchema.name": "所æ供或预定义模å¼çš„å称", "PatternTypeSchema.description": "问题模å¼æˆ–者所æ供或预定义问题模å¼çš„å称。如果已指定基准,则å¯ä»¥çœç•¥ã€‚", @@ -42,6 +43,12 @@ "ProblemMatcherSchema.severity": "æ•èŽ·é—®é¢˜çš„默认严é‡æ€§ã€‚如果模å¼æœªå®šä¹‰ä¸¥é‡æ€§çš„匹é…组,则使用。", "ProblemMatcherSchema.applyTo": "控制文本文档上报告的问题是å¦ä»…应用于打开ã€å…³é—­æˆ–所有文档。", "ProblemMatcherSchema.fileLocation": "定义应如何解释问题模å¼ä¸­æŠ¥å‘Šçš„文件å。", + "ProblemMatcherSchema.background": "用于跟踪在åŽå°ä»»åŠ¡ä¸Šæ¿€æ´»çš„匹é…程åºçš„开始和结æŸçš„模å¼ã€‚", + "ProblemMatcherSchema.background.activeOnStart": "如果设置为 true,则会在任务开始时激活åŽå°ç›‘控。这相当于å‘出与 beginPattern 匹é…的行。", + "ProblemMatcherSchema.background.beginsPattern": "如果在输出内匹é…,则会å‘出åŽå°ä»»åŠ¡å¼€å§‹çš„ä¿¡å·ã€‚", + "ProblemMatcherSchema.background.endsPattern": "如果在输出内匹é…,则会å‘出åŽå°ä»»åŠ¡ç»“æŸçš„ä¿¡å·ã€‚", + "ProblemMatcherSchema.watching.deprecated": "“watchingâ€å±žæ€§å·²è¢«å¼ƒç”¨ã€‚请改用“backgroundâ€ã€‚", + "ProblemMatcherSchema.watching": "用于跟踪监视匹é…程åºå¼€å§‹å’Œç»“æŸçš„模å¼ã€‚", "ProblemMatcherSchema.watching.activeOnStart": "如果设置为 true,则当任务开始时观察程åºå¤„于活动模å¼ã€‚这相当于å‘出与 beginPattern 匹é…的行。", "ProblemMatcherSchema.watching.beginsPattern": "如果在输出内匹é…,则在监视任务开始时会å‘出信å·ã€‚", "ProblemMatcherSchema.watching.endsPattern": "如果在输出内匹é…,则在监视任务结æŸæ—¶ä¼šå‘出信å·ã€‚", diff --git a/i18n/chs/src/vs/workbench/api/node/extHostTreeViews.i18n.json b/i18n/chs/src/vs/workbench/api/node/extHostTreeViews.i18n.json index 8b6ad71cd4e..7bfb0b886de 100644 --- a/i18n/chs/src/vs/workbench/api/node/extHostTreeViews.i18n.json +++ b/i18n/chs/src/vs/workbench/api/node/extHostTreeViews.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "treeView.notRegistered": "没有注册 ID 为“{0}â€çš„树形图。", + "treeItem.notFound": "没有在树中找到 ID 为“{0}â€çš„项目。", + "treeView.duplicateElement": "已注册元素 {0}。" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/common/theme.i18n.json b/i18n/chs/src/vs/workbench/common/theme.i18n.json index 64c51b8e74c..0f3e7eb1bf9 100644 --- a/i18n/chs/src/vs/workbench/common/theme.i18n.json +++ b/i18n/chs/src/vs/workbench/common/theme.i18n.json @@ -32,6 +32,7 @@ "activityBarBadgeBackground": "活动通知徽章背景色。活动æ æ˜¾ç¤ºåœ¨æœ€å·¦ä¾§æˆ–最å³ä¾§ï¼Œå¹¶å…许在侧边æ çš„视图间切æ¢ã€‚", "activityBarBadgeForeground": "活动通知徽章å‰æ™¯è‰²ã€‚活动æ æ˜¾ç¤ºåœ¨æœ€å·¦ä¾§æˆ–最å³ä¾§ï¼Œå¹¶å…许在侧边æ çš„视图间切æ¢ã€‚", "sideBarBackground": "侧边æ èƒŒæ™¯è‰²ã€‚侧边æ æ˜¯èµ„æºç®¡ç†å™¨å’Œæœç´¢ç­‰è§†å›¾çš„容器。", + "sideBarForeground": "侧边æ å‰æ™¯è‰²ã€‚侧边æ æ˜¯èµ„æºç®¡ç†å™¨å’Œæœç´¢ç­‰è§†å›¾çš„容器。", "sideBarTitleForeground": "侧边æ æ ‡é¢˜å‰æ™¯è‰²ã€‚侧边æ æ˜¯èµ„æºç®¡ç†å™¨å’Œæœç´¢ç­‰è§†å›¾çš„容器。", "sideBarSectionHeaderBackground": "侧边æ èŠ‚标题的背景颜色。侧边æ æ˜¯èµ„æºç®¡ç†å™¨å’Œæœç´¢ç­‰è§†å›¾çš„容器。", "titleBarActiveForeground": "窗å£å¤„于活动状æ€æ—¶çš„标题æ å‰æ™¯è‰²ã€‚请注æ„,该颜色当å‰ä»…在 macOS 上å—支æŒã€‚", diff --git a/i18n/chs/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/chs/src/vs/workbench/electron-browser/main.contribution.i18n.json index 375f183373b..6997449c1ce 100644 --- a/i18n/chs/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/chs/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -7,6 +7,7 @@ "view": "查看", "help": "帮助", "file": "文件", + "developer": "å¼€å‘者", "showEditorTabs": "控制打开的编辑器是å¦æ˜¾ç¤ºåœ¨é€‰é¡¹å¡ä¸­ã€‚", "editorTabCloseButton": "控制编辑器的选项å¡å…³é—­æŒ‰é’®çš„ä½ç½®ï¼Œæˆ–当设置为 \"off\" æ—¶ç¦ç”¨å…³é—­å®ƒä»¬ã€‚", "showIcons": "控制打开的编辑器是å¦éšå›¾æ ‡ä¸€èµ·æ˜¾ç¤ºã€‚这还需å¯ç”¨å›¾æ ‡ä¸»é¢˜ã€‚", diff --git a/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json b/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json index a188f9c1e90..b163a2de99e 100644 --- a/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json @@ -4,5 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "workbench.action.inspectKeyMap": "å¼€å‘者:检查键映射" + "workbench.action.inspectKeyMap": "å¼€å‘者: 检查键映射" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json b/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json index 8d541bedfe0..a7b3e519e7d 100644 --- a/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json @@ -6,6 +6,6 @@ { "toggle.wordwrap": "查看: 切æ¢è‡ªåŠ¨æ¢è¡Œ", "wordWrap.notInDiffEditor": "ä¸èƒ½åœ¨å·®å¼‚编辑器中切æ¢è‡ªåŠ¨æ¢è¡Œã€‚", - "unwrapMinified": "为此文件ç¦ç”¨æ¢è¡Œ", + "unwrapMinified": "为此文件ç¦ç”¨æŠ˜è¡Œ", "wrapMinified": "为此文件å¯ç”¨æ¢è¡Œ" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json b/i18n/chs/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json index c322b5a660a..54243f83ce3 100644 --- a/i18n/chs/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json @@ -7,6 +7,7 @@ "debugAdapterBinNotFound": "调试适é…器å¯æ‰§è¡Œçš„“{0}â€ä¸å­˜åœ¨ã€‚", "debugAdapterCannotDetermineExecutable": "无法确定调试适é…器“{0}â€çš„å¯æ‰§è¡Œæ–‡ä»¶ã€‚", "debugType": "é…置类型。", + "debugTypeNotRecognised": "无法识别此调试类型。确ä¿å·²ç»å®‰è£…并å¯ç”¨ç›¸åº”的调试扩展。", "node2NotSupported": "ä¸å†æ”¯æŒ \"node2\",改用 \"node\",并将 \"protocol\" 属性设为 \"inspector\"。", "debugName": "é…ç½®å称;在å¯åŠ¨é…置下拉èœå•ä¸­æ˜¾ç¤ºã€‚", "debugRequest": "请求é…置类型。å¯ä»¥æ˜¯â€œå¯åŠ¨â€æˆ–“附加â€ã€‚", diff --git a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json index 0598c67b46e..f4159d50b0e 100644 --- a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json @@ -4,5 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "evaluateMathExpression": "Emmet: 评估数学表达å¼" + "evaluateMathExpression": "Emmet: 求数学表达å¼çš„值" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json index 403f855e5eb..81f7dcfcab1 100644 --- a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json @@ -4,10 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "incrementNumberByOneTenth": "Emmet: 以 0.1 为增é‡", - "incrementNumberByOne": "Emmet: 以 1 为增é‡", - "incrementNumberByTen": "Emmet: 以 10 为增é‡", - "decrementNumberByOneTenth": "Emmet: 以 0.1 为å‡é‡", - "decrementNumberByOne": "Emmet: 以 1 为å‡é‡", - "decrementNumberByTen": "Emmet: 以 10 为å‡é‡" + "incrementNumberByOneTenth": "Emmet: 增加 0.1", + "incrementNumberByOne": "Emmet: 增加 1", + "incrementNumberByTen": "Emmet: 增加 10", + "decrementNumberByOneTenth": "Emmet: å‡å°‘ 0.1", + "decrementNumberByOne": "Emmet: å‡å°‘ 1", + "decrementNumberByTen": "Emmet: å‡å°‘ 10" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json index b58d42bcafe..545f1c107e7 100644 --- a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json @@ -4,5 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "removeTag": "Emmet: 删除标记" + "removeTag": "Emmet: 删除标签" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json index 5796a0dcab8..53e4eaafbd9 100644 --- a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json @@ -4,5 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "splitJoinTag": "Emmet: 分离/è”接标记" + "splitJoinTag": "Emmet: 分离/è”接标签" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json index c5d6fd7b350..d68725525c8 100644 --- a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json @@ -4,5 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "updateImageSize": "Emmet: 更新映åƒå¤§å°" + "updateImageSize": "Emmet: 更新图åƒå¤§å°" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json index 486e5397c4b..8bf2821c120 100644 --- a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "updateTag": "Emmet: 更新标记", - "enterTag": "输入标记", - "tag": "标记" + "updateTag": "Emmet: 更新标签", + "enterTag": "输入标签", + "tag": "标签" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json index dbca7bf9016..21f0c06d363 100644 --- a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "wrapWithAbbreviationAction": "Emmet: 使用缩写进行包装", + "wrapWithAbbreviationAction": "Emmet: 使用缩写进行包围", "enterAbbreviation": "输入缩写", "abbreviation": "缩写" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json index 6a402e79e1e..0701c9f4ae6 100644 --- a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json @@ -6,8 +6,8 @@ { "emmetConfigurationTitle": "Emmet", "triggerExpansionOnTab": "å¯ç”¨åŽï¼ŒæŒ‰ TAB 键时,将展开 Emmet 缩写。", - "emmetPreferences": "用于修改 Emmet çš„æŸäº›æ“作和解决程åºçš„首选项。", + "emmetPreferences": "用于修改 Emmet æŸäº›æ“作和解æžç¨‹åºçš„行为的首选项。", "emmetSyntaxProfiles": "为指定的语法定义é…置文件或使用带有特定规则的é…置文件。", - "emmetExclude": "emmet 缩写ä¸åº”在其中展开的语言数组。", - "emmetExtensionsPath": "è½¬è‡³åŒ…å« Emmet é…置文件ã€ç‰‡æ®µå’Œé¦–选项的文件的路径" + "emmetExclude": "ä¸åº”展开 Emmet 缩写的语言数组。", + "emmetExtensionsPath": "åŒ…å« Emmet é…置文件ã€ä»£ç æ®µå’Œé¦–选项的文件夹路径" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json b/i18n/chs/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json index 5d52f90d627..076eadb1e72 100644 --- a/i18n/chs/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json @@ -4,11 +4,11 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "vscode.extension.contributes.view": "贡献自定义视图", + "vscode.extension.contributes.view": "添加自定义视图", "vscode.extension.contributes.view.id": "用于标识通过 vscode.workspace.createTreeView 创建的视图的唯一 ID", "vscode.extension.contributes.view.label": "用于呈现视图的人类å¯è¯»çš„字符串", "vscode.extension.contributes.view.icon": "视图图标的路径", - "vscode.extension.contributes.views": "贡献自定义视图", + "vscode.extension.contributes.views": "添加自定义视图", "showViewlet": "显示 {0}", "view": "查看" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/chs/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 8b6ad71cd4e..5a4bf096f38 100644 --- a/i18n/chs/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "disableOtherKeymapsConfirmation": "是å¦ç¦ç”¨å…¶ä»–键映射以é¿å…键绑定之间的冲çª?", + "yes": "是", + "no": "å¦" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/chs/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index ba343731820..5813db26a24 100644 --- a/i18n/chs/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,7 +16,6 @@ "associations": "é…置语言的文件关è”(如: \"*.extension\": \"html\")。这些关è”的优先级高于已安装语言的默认关è”。", "encoding": "读å–和编写文件时将使用的默认字符集编ç ã€‚", "autoGuessEncoding": "å¯ç”¨æ—¶ï¼Œä¼šåœ¨æ‰“开文件时å°è¯•çŒœæµ‹å­—符集编ç ", - "eol": "默认行尾字符。", "trimTrailingWhitespace": "å¯ç”¨åŽï¼Œå°†åœ¨ä¿å­˜æ–‡ä»¶æ—¶å‰ªè£å°¾éšç©ºæ ¼ã€‚", "insertFinalNewline": "å¯ç”¨åŽï¼Œä¿å­˜æ–‡ä»¶æ—¶åœ¨æ–‡ä»¶æœ«å°¾æ’入一个最终新行。", "files.autoSave.off": "æ°¸ä¸è‡ªåŠ¨ä¿å­˜æ›´æ–°åŽçš„文件。", diff --git a/i18n/chs/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json b/i18n/chs/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json index f4fa6caa5bc..9745dba4538 100644 --- a/i18n/chs/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json @@ -4,5 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "orphanedFile": "{0} (deleted from disk)" + "orphanedFile": "{0} (ç£ç›˜ä¸Šå·²åˆ é™¤)" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/chs/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index dbd6be98f3e..bb7e4ea7afa 100644 --- a/i18n/chs/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -5,5 +5,11 @@ // Do not edit this file. It is machine generated. { "slow": "检测到å¯åŠ¨ç¼“æ…¢", - "slow.detail": "抱歉,出现了å¯åŠ¨ç¼“慢的情况。请é‡å¯â€œ{0}â€å¹¶å¯ç”¨åˆ†æžï¼Œå°†åˆ†æžæ–‡ä»¶ä¸Žæˆ‘们共享,我们会努力æ高å¯åŠ¨é€Ÿåº¦ã€‚" + "slow.detail": "抱歉,出现了å¯åŠ¨ç¼“慢的情况。请é‡å¯â€œ{0}â€å¹¶å¯ç”¨åˆ†æžï¼Œå°†åˆ†æžæ–‡ä»¶ä¸Žæˆ‘们共享,我们会努力æ高å¯åŠ¨é€Ÿåº¦ã€‚", + "prof.message": "å·²æˆåŠŸåˆ›å»ºæ述文件。", + "prof.detail": "请创建问题并手动附加以下文件:\n{0}", + "prof.restartAndFileIssue": "创建问题并é‡å¯", + "prof.restart": "é‡å¯", + "prof.thanks": "感谢您的帮助。", + "prof.detail.restart": "需è¦é‡æ–°å¯åŠ¨æ‰èƒ½ç»§ç»­ä½¿ç”¨â€œ{0}â€ã€‚å†æ¬¡æ„Ÿè°¢æ‚¨çš„贡献。" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json b/i18n/chs/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json index d4d305eba54..3461ec0a523 100644 --- a/i18n/chs/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json @@ -4,11 +4,11 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "keybindingsInputName": "键盘快æ·é”®", + "keybindingsInputName": "键盘快æ·æ–¹å¼", "SearchKeybindings.AriaLabel": "æœç´¢é”®ç»‘定", "SearchKeybindings.Placeholder": "æœç´¢é”®ç»‘定", "sortByPrecedene": "按优先级排åº", - "header-message": "用于高级自定义打开和编辑", + "header-message": "高级自定义请打开和编辑", "keybindings-file-name": "keybindings.json", "keybindingsLabel": "键绑定", "changeLabel": "更改键绑定", diff --git a/i18n/chs/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json b/i18n/chs/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json index 058e01cd6bf..72a81c0af68 100644 --- a/i18n/chs/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json @@ -6,7 +6,7 @@ { "openGlobalSettings": "打开用户设置", "openGlobalKeybindings": "打开键盘快æ·æ–¹å¼", - "openGlobalKeybindingsFile": "打开键盘快æ·é”®æ–‡ä»¶", + "openGlobalKeybindingsFile": "打开键盘快æ·æ–¹å¼æ–‡ä»¶", "openWorkspaceSettings": "打开工作区设置", "configureLanguageBasedSettings": "é…置语言特定的设置...", "languageDescriptionConfigured": "({0})", diff --git a/i18n/chs/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json b/i18n/chs/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json index ab4166d5cd7..8ea8ff4f96e 100644 --- a/i18n/chs/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json @@ -4,7 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "toggleGitViewlet": "显示 GIT", + "toggleGitViewlet": "显示 Git", + "installAdditionalSCMProviders": "安装其他 SCM æ供程åº...", "source control": "æºä»£ç ç®¡ç†", "toggleSCMViewlet": "显示 SCM", "view": "查看" diff --git a/i18n/chs/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json b/i18n/chs/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json index f03d74e8c9d..89c41c7a05b 100644 --- a/i18n/chs/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "switch provider": "åˆ‡æ¢ SCM æ供程åº..." + "installAdditionalSCMProviders": "安装其他 SCM æ供程åº...", + "switch provider": "切æ¢æºä»£ç ç®¡ç†ç³»ç»Ÿ..." } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json b/i18n/chs/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json index 0c4154de4e5..340ee7fc03e 100644 --- a/i18n/chs/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "vscode.extension.contributes.snippets": "贡献代ç æ®µã€‚", + "vscode.extension.contributes.snippets": "添加代ç æ®µã€‚", "vscode.extension.contributes.snippets-language": "此代ç ç‰‡æ®µå‚与的语言标识符。", "vscode.extension.contributes.snippets-path": "代ç ç‰‡æ®µæ–‡ä»¶çš„路径。该路径相对于扩展文件夹,通常以 \"./snippets/\" 开头。", "invalid.language": "“contributes.{0}.languageâ€ä¸­å­˜åœ¨æœªçŸ¥çš„语言。æ供的值: {1}", diff --git a/i18n/chs/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/chs/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index bf5eec2631c..48bcbb508c2 100644 --- a/i18n/chs/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,5 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0},任务" + "entryAriaLabel": "{0},任务", + "workspace": "æ¥è‡ªå·¥ä½œåŒº", + "extension": "æ¥è‡ªæ‰©å±•" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json b/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json index 2132313f0b6..f5f009904e1 100644 --- a/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json @@ -6,5 +6,6 @@ { "TerminalTaskSystem.unknownError": "在执行任务时å‘生未知错误。请å‚è§ä»»åŠ¡è¾“出日志了解详细信æ¯ã€‚", "TerminalTaskSystem.terminalName": "任务 - {0}", - "TerminalTaskSystem": "无法对 UNC 驱动器执行 shell 命令。" + "TerminalTaskSystem": "无法对 UNC 驱动器执行 shell 命令。", + "unkownProblemMatcher": "无法解æžé—®é¢˜åŒ¹é…ç¨‹åº {0}。此匹é…程åºå°†è¢«å¿½ç•¥" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json b/i18n/chs/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json index aa659de1014..5b8a86d9c21 100644 --- a/i18n/chs/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json @@ -7,5 +7,6 @@ "TaskRunnerSystem.unknownError": "在执行任务时å‘生未知错误。请å‚è§ä»»åŠ¡è¾“出日志了解详细信æ¯ã€‚", "TaskRunnerSystem.watchingBuildTaskFinished": "\n监视生æˆä»»åŠ¡å·²å®Œæˆ", "TaskRunnerSystem.childProcessError": "Failed to launch external program {0} {1}.", - "TaskRunnerSystem.cancelRequested": "\n已根æ®ç”¨æˆ·è¯·æ±‚终止了任务'{0}' " + "TaskRunnerSystem.cancelRequested": "\n已根æ®ç”¨æˆ·è¯·æ±‚终止了任务'{0}' ", + "unkownProblemMatcher": "无法解æžé—®é¢˜åŒ¹é…ç¨‹åº {0}。此匹é…程åºå°†è¢«å¿½ç•¥" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json b/i18n/chs/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json index 082e49f08bc..076dd52ebbb 100644 --- a/i18n/chs/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json @@ -17,7 +17,7 @@ "watermark.selectTheme": "更改主题", "watermark.selectKeymap": "更改键映射", "watermark.keybindingsReference": "键盘å‚考", - "watermark.openGlobalKeybindings": "键盘快æ·é”®", + "watermark.openGlobalKeybindings": "键盘快æ·æ–¹å¼(&&K)", "watermark.unboundCommand": "未绑定", "workbenchConfigurationTitle": "工作å°", "tips.enabled": "å¯ç”¨åŽï¼Œå½“没有打开编辑器时将显示水å°æ示。" diff --git a/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json index 3b9d1ffa9ca..3503db3576a 100644 --- a/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -9,18 +9,23 @@ "welcomePage.start": "开始", "welcomePage.newFile": "新建文件", "welcomePage.openFolder": "打开文件夹...", - "welcomePage.cloneGitRepository": "克隆 GIT 存储库...", + "welcomePage.cloneGitRepository": "克隆 Git 存储库...", "welcomePage.recent": "最近", "welcomePage.moreRecent": "更多...", "welcomePage.noRecentFolders": "无最近使用文件夹", "welcomePage.help": "帮助", + "welcomePage.keybindingsCheatsheet": "å¯æ‰“å°çš„键盘速查表", "welcomePage.introductoryVideos": "入门视频", "welcomePage.productDocumentation": "产å“文档", "welcomePage.gitHubRepository": "GitHub 存储库", "welcomePage.stackOverflow": "Stack Overflow", "welcomePage.showOnStartup": "å¯åŠ¨æ—¶æ˜¾ç¤ºæ¬¢è¿Žé¡µ", "welcomePage.customize": "自定义", + "welcomePage.installExtensionPacks": "工具和语言", + "welcomePage.installExtensionPacksDescription": "安装对 {0} å’Œ {1} 的支æŒ", + "welcomePage.moreExtensions": "更多", "welcomePage.installKeymapDescription": "安装键盘快æ·æ–¹å¼", + "welcomePage.installKeymapExtension": "安装 {0} å’Œ {1} 的键盘快æ·æ–¹å¼", "welcomePage.others": "其他", "welcomePage.colorTheme": "颜色主题", "welcomePage.colorThemeDescription": "使编辑器和代ç å‘ˆçŽ°ä½ å–œæ¬¢çš„外观", diff --git a/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index de7e3aa24d5..07f438f169e 100644 --- a/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -5,11 +5,25 @@ // Do not edit this file. It is machine generated. { "welcomePage": "欢迎使用", + "welcomePage.javaScript": "JavaScript", + "welcomePage.typeScript": "TypeScript", + "welcomePage.python": "Python", + "welcomePage.php": "PHP", + "welcomePage.docker": "Docker", + "welcomePage.vim": "Vim", + "welcomePage.sublime": "Sublime", + "welcomePage.atom": "Atom", + "welcomePage.extensionPackAlreadyInstalled": "已安装对 {0} 的支æŒã€‚", + "welcomePage.willReloadAfterInstallingExtensionPack": "安装对 {0} 的支æŒåŽï¼Œå°†é‡è½½çª—å£ã€‚", + "welcomePage.installingExtensionPack": "正在安装对 {0} 的支æŒ...", + "welcomePage.extensionPackNotFound": "找ä¸åˆ°å¯¹ {0} (ID: {1}) 的支æŒã€‚", "welcomePage.keymapAlreadyInstalled": "已安装 {0} 键盘快æ·æ–¹å¼ã€‚", "welcomePage.willReloadAfterInstallingKeymap": "安装 {0} 键盘快æ·æ–¹å¼åŽï¼Œå°†é‡è½½çª—å£ã€‚", "welcomePage.installingKeymap": "正在安装 {0} 键盘快æ·æ–¹å¼...", "welcomePage.keymapNotFound": "找ä¸åˆ° ID 为 {1} çš„ {0} 键盘快æ·æ–¹å¼ã€‚", "welcome.title": "欢迎使用", + "welcomePage.extensionListSeparator": ",", + "welcomePage.installedExtension": "{0}(已安装)", "ok": "确定", "cancel": "å–消", "welcomePage.quickLinkBackground": "欢迎页快速链接的背景颜色。", diff --git a/i18n/chs/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json b/i18n/chs/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json index 69e35ac02d6..4abe2dbd4b8 100644 --- a/i18n/chs/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json +++ b/i18n/chs/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json @@ -14,18 +14,18 @@ "vscode.extension.contributes.iconThemes.label": "UI 中显示的图标主题的标签。", "vscode.extension.contributes.iconThemes.path": "图标主题定义文件的路径。该路径相对于扩展文件夹,通常是 \"./icons/awesome-icon-theme.json\"。", "migration.completed": "å·²å‘用户设置添加了新的主题设置。{0} 中å¯å¤‡ä»½ã€‚", - "error.cannotloadtheme": "Unable to load {0}: {1}", - "reqarray": "Extension point `{0}` must be an array.", + "error.cannotloadtheme": "无法加载 {0}: {1}", + "reqarray": "扩展点“{0}â€å¿…须是一个数组。", "reqpath": "“contributes.{0}.pathâ€ä¸­åº”为字符串。æ供的值: {1}", "invalid.path.1": "“contributes.{0}.pathâ€({1})应包å«åœ¨æ‰©å±•çš„文件夹({2})内。这å¯èƒ½ä¼šä½¿æ‰©å±•ä¸å¯ç§»æ¤ã€‚", "reqid": "“contributes.{0}.idâ€ä¸­åº”为字符串。æ供的值: {1}", "error.cannotloadicontheme": "Unable to load {0}", "error.cannotparseicontheme": "Problems parsing file icons file: {0}", - "colorTheme": "Specifies the color theme used in the workbench.", - "colorThemeError": "Theme is unknown or not installed.", - "iconTheme": "Specifies the icon theme used in the workbench.", + "colorTheme": "指定工作å°ä¸­ä½¿ç”¨çš„颜色主题。", + "colorThemeError": "主题未知或未安装。", + "iconTheme": "指定在工作å°ä¸­ä½¿ç”¨çš„图标主题。", "noIconThemeDesc": "No file icons", - "iconThemeError": "File icon theme is unknown or not installed.", + "iconThemeError": "文件图标主题未知或未安装。", "workbenchColors": "覆盖当å‰æ‰€é€‰é¢œè‰²ä¸»é¢˜çš„颜色。", "workbenchColors.deprecated": "该设置ä¸å†æ˜¯å®žéªŒæ€§è®¾ç½®ï¼Œå¹¶å·²é‡å‘½å为“workbench.colorCustomizationsâ€", "workbenchColors.deprecatedDescription": "改用“workbench.colorCustomizationsâ€" diff --git a/i18n/cht/extensions/markdown/out/extension.i18n.json b/i18n/cht/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/cht/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/cht/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/cht/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/cht/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/cht/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/cht/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/cht/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/cht/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/cht/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/cht/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/cht/extensions/merge-conflict/package.i18n.json b/i18n/cht/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/cht/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/cht/extensions/npm/package.i18n.json b/i18n/cht/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/cht/extensions/npm/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/cht/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/cht/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index da6b8c6d2c0..c01f13f3bcb 100644 --- a/i18n/cht/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/cht/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,8 +6,6 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "因為影åƒå¤ªå¤§ï¼Œæ‰€ä»¥ç„¡æ³•åœ¨ç·¨è¼¯å™¨ä¸­é¡¯ç¤ºã€‚", - "resourceOpenExternalButton": "é–‹å•Ÿå½±åƒ", - "resourceOpenExternalText": " è¦ä½¿ç”¨å¤–部程å¼å—Ž?", "nativeBinaryError": "檔案為二進ä½æª”ã€éžå¸¸å¤§æˆ–使用ä¸æ”¯æ´çš„文字編碼,因此將ä¸æœƒé¡¯ç¤ºæ–¼ç·¨è¼¯å™¨ä¸­ã€‚", "sizeB": "{0}B", "sizeKB": "{0}KB", diff --git a/i18n/cht/src/vs/code/electron-main/menus.i18n.json b/i18n/cht/src/vs/code/electron-main/menus.i18n.json index a1fa3f356dd..5961aa8e789 100644 --- a/i18n/cht/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/cht/src/vs/code/electron-main/menus.i18n.json @@ -14,6 +14,7 @@ "mHelp": "說明 (&&H)", "miNewWindow": "開新視窗(&&W)", "mAbout": "關於 {0}", + "mServices": "æœå‹™", "mHide": "éš±è— {0}", "mHideOthers": "éš±è—其他", "mShowAll": "全部顯示", diff --git a/i18n/cht/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/cht/src/vs/editor/common/config/commonEditorConfig.i18n.json index ec8f05fe340..f06682edb16 100644 --- a/i18n/cht/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/cht/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -40,7 +40,6 @@ "formatOnType": "控制編輯器是å¦æ‡‰åœ¨è¼¸å…¥ä¸€è¡Œå¾Œè‡ªå‹•æ ¼å¼åŒ–", "formatOnPaste": "控制編輯器是å¦æ‡‰è‡ªå‹•è¨­å®šè²¼ä¸Šçš„內容格å¼ã€‚æ ¼å¼å™¨å¿…é ˆå¯ä¾›ä½¿ç”¨ï¼Œè€Œä¸”æ ¼å¼å™¨æ‡‰è©²èƒ½å¤ è¨­å®šæ–‡ä»¶ä¸­ä¸€å€‹ç¯„åœçš„æ ¼å¼ã€‚", "suggestOnTriggerCharacters": "控制輸入觸發字元時,是å¦æ‡‰è‡ªå‹•é¡¯ç¤ºå»ºè­°", - "acceptSuggestionOnEnter": "控制除了 'Tab' 外,是å¦ä¹Ÿè—‰ç”±æŒ‰ä¸‹ 'Enter' 接å—建議。如此å¯é¿å…æ··æ·†è¦æ’入新行或接å—建議。", "acceptSuggestionOnCommitCharacter": "控制èªå¯å­—元是å¦æ‡‰æŽ¥å—建議。例如在 JavaScript 中,分號 (';') å¯ä»¥æ˜¯æŽ¥å—建議並éµå…¥è©²å­—元的èªå¯å­—元。", "snippetSuggestions": "控制程å¼ç¢¼ç‰‡æ®µæ˜¯å¦éš¨å…¶ä»–建議顯示,以åŠå…¶æŽ’åºæ–¹å¼ã€‚", "emptySelectionClipboard": "控制複製時ä¸é¸å–任何項目是å¦æœƒè¤‡è£½ç›®å‰ç¨‹å¼è¡Œã€‚", diff --git a/i18n/cht/src/vs/editor/common/view/editorColorRegistry.i18n.json b/i18n/cht/src/vs/editor/common/view/editorColorRegistry.i18n.json index 7b011979df9..b08c173b100 100644 --- a/i18n/cht/src/vs/editor/common/view/editorColorRegistry.i18n.json +++ b/i18n/cht/src/vs/editor/common/view/editorColorRegistry.i18n.json @@ -7,6 +7,9 @@ "lineHighlight": "ç›®å‰æ¸¸æ¨™ä½ç½®è¡Œçš„å白顯示背景色彩。", "lineHighlightBorderBox": "ç›®å‰æ¸¸æ¨™ä½ç½®è¡Œä¹‹å‘¨åœæ¡†ç·šçš„背景色彩。", "rangeHighlight": "å白顯示範åœçš„背景色彩,例如 Quick Open 與尋找功能。", + "caret": "編輯器游標的色彩。", + "editorWhitespaces": "編輯器中空白字元的色彩。", + "editorIndentGuides": "編輯器縮排輔助線的色彩。", "editorLineNumbers": "編輯器行號的色彩。", "editorRuler": "編輯器尺è¦çš„色彩", "editorCodeLensForeground": "編輯器程å¼ç¢¼æ¿¾é¡çš„å‰æ™¯è‰²å½©", diff --git a/i18n/cht/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/cht/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..26ea0a1761c --- /dev/null +++ b/i18n/cht/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "找ä¸åˆ° '{0}' 的定義", + "generic.noResults": "找ä¸åˆ°ä»»ä½•å®šç¾©", + "meta.title": " - {0} 個定義", + "actions.goToDecl.label": "移至定義", + "actions.goToDeclToSide.label": "在一å´é–‹å•Ÿå®šç¾©", + "actions.previewDecl.label": "é è¦½å®šç¾©", + "goToImplementation.noResultWord": "找ä¸åˆ° '{0}' 的任何實作", + "goToImplementation.generic.noResults": "找ä¸åˆ°ä»»ä½•å¯¦ä½œ", + "meta.implementations.title": " – {0} 個實作", + "actions.goToImplementation.label": "å‰å¾€å¯¦ä½œ", + "actions.peekImplementation.label": "é è¦½å¯¦ä½œ", + "goToTypeDefinition.noResultWord": "找ä¸åˆ° '{0}' 的任何類型定義", + "goToTypeDefinition.generic.noResults": "找ä¸åˆ°ä»»ä½•é¡žåž‹å®šç¾©", + "meta.typeDefinitions.title": " – {0} 個定義", + "actions.goToTypeDefinition.label": "移至類型定義", + "actions.peekTypeDefinition.label": "é è¦½é¡žåž‹å®šç¾©" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/cht/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..24cf4f7503f --- /dev/null +++ b/i18n/cht/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "按一下以顯示 {0} 項定義。" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/api/node/extHostTreeViews.i18n.json b/i18n/cht/src/vs/workbench/api/node/extHostTreeViews.i18n.json index 8b6ad71cd4e..028bfb1a1d0 100644 --- a/i18n/cht/src/vs/workbench/api/node/extHostTreeViews.i18n.json +++ b/i18n/cht/src/vs/workbench/api/node/extHostTreeViews.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "treeView.duplicateElement": "元件{0}已被註冊" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/common/theme.i18n.json b/i18n/cht/src/vs/workbench/common/theme.i18n.json index 2d8bce1a636..72a8d8abb7e 100644 --- a/i18n/cht/src/vs/workbench/common/theme.i18n.json +++ b/i18n/cht/src/vs/workbench/common/theme.i18n.json @@ -29,6 +29,7 @@ "activityBarBadgeBackground": "活動通知徽章的背景色彩。此活動列會顯示在最左å´æˆ–最å³å´ï¼Œè®“您å¯ä»¥åˆ‡æ›æè¦æ¬„ä½çš„ä¸åŒæª¢è¦–。", "activityBarBadgeForeground": "活動通知徽章的å‰èƒŒæ™¯è‰²å½©ã€‚此活動列會顯示在最左å´æˆ–最å³å´ï¼Œè®“您å¯ä»¥åˆ‡æ›æè¦æ¬„ä½çš„ä¸åŒæª¢è¦–。", "sideBarBackground": "æè¦æ¬„ä½çš„背景色彩。æè¦æ¬„ä½æ˜¯æª¢è¦– (例如 Explorer 與æœå°‹) 的容器。", + "sideBarForeground": "å´æ¬„çš„å‰æ™¯é¡è‰².å´æ¬„包å«Explorer與æœå°‹.", "sideBarTitleForeground": "æè¦æ¬„ä½æ¨™é¡Œçš„å‰æ™¯è‰²å½©ã€‚æè¦æ¬„ä½æ˜¯æª¢è¦– (例如 Explorer 與æœå°‹) 的容器。", "sideBarSectionHeaderBackground": "æè¦æ¬„ä½å€æ®µæ¨™é ­çš„背景色彩。æè¦æ¬„ä½æ˜¯æª¢è¦– (例如 Explorer 與æœå°‹) 的容器。", "titleBarActiveForeground": "作用中視窗之標題列的å‰æ™¯ã€‚請注æ„,目å‰åªæœ‰ macOS 支æ´æ­¤è‰²å½©ã€‚", diff --git a/i18n/cht/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/cht/src/vs/workbench/electron-browser/main.contribution.i18n.json index c1874024aee..bced8b136e5 100644 --- a/i18n/cht/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/cht/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -7,6 +7,7 @@ "view": "檢視", "help": "說明", "file": "檔案", + "developer": "開發人員", "showEditorTabs": "控制已開啟的編輯器是å¦æ‡‰é¡¯ç¤ºåœ¨ç´¢å¼•æ¨™ç±¤ä¸­ã€‚", "editorTabCloseButton": "控制編輯器的索引標籤關閉按鈕ä½ç½®ï¼Œæˆ–在設為 'off' 時將其åœç”¨ã€‚", "showIcons": "控制開啟的編輯器是å¦æ­é…圖示顯示。這需è¦åŒæ™‚啟用圖示佈景主題。", diff --git a/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 8b6ad71cd4e..49a87dcf222 100644 --- a/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "disableOtherKeymapsConfirmation": "è¦åœç”¨å…¶ä»–按éµå°æ‡‰ï¼Œä»¥é¿å…按éµç¹«çµé—œä¿‚發生è¡çªå—Ž?", + "yes": "是", + "no": "å¦" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/cht/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 07e8bfd5963..5b044579208 100644 --- a/i18n/cht/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,7 +16,6 @@ "associations": "將檔案關è¯è¨­å®šç‚ºèªžè¨€ (例如 \"*.extension\": \"html\")。這些語言優先於已安è£èªžè¨€çš„é è¨­é—œè¯ã€‚", "encoding": "讀å–與寫入檔案時è¦ä½¿ç”¨çš„é è¨­å­—元集編碼。", "autoGuessEncoding": "如有啟用,將會在開啟檔案時,嘗試猜測字元集編碼", - "eol": "é è¨­è¡Œå°¾å­—元。", "trimTrailingWhitespace": "若啟用,將在儲存檔案時修剪尾端空白。", "insertFinalNewline": "啟用時,請在儲存檔案時在其çµå°¾æ’入最後一個新行。", "files.autoSave.off": "已變更的檔案一律ä¸æœƒè‡ªå‹•å„²å­˜ã€‚", diff --git a/i18n/cht/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/cht/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index 1c615781faa..f36b3a04dba 100644 --- a/i18n/cht/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -5,5 +5,9 @@ // Do not edit this file. It is machine generated. { "slow": "åµæ¸¬åˆ°å•Ÿå‹•é€Ÿåº¦æ…¢", - "slow.detail": "抱歉! å…ˆå‰çš„啟動速度éŽæ…¢ã€‚è«‹é‡æ–°å•Ÿå‹• '{0}' 並啟用剖æžåŠŸèƒ½ï¼ŒåŒæ™‚將設定檔æ供給我們,我們將努力æå‡å•Ÿå‹•çš„å“質。" + "slow.detail": "抱歉! å…ˆå‰çš„啟動速度éŽæ…¢ã€‚è«‹é‡æ–°å•Ÿå‹• '{0}' 並啟用剖æžåŠŸèƒ½ï¼ŒåŒæ™‚將設定檔æ供給我們,我們將努力æå‡å•Ÿå‹•çš„å“質。", + "prof.message": "å·²æˆåŠŸå»ºç«‹è¨­å®šæª”。", + "prof.detail": "請建立å•é¡Œï¼Œä¸¦æ‰‹å‹•é™„加下列檔案:\n{0}", + "prof.restartAndFileIssue": "建立å•é¡Œä¸¦é‡æ–°å•Ÿå‹•", + "prof.restart": "é‡æ–°å•Ÿå‹•" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json b/i18n/cht/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json index c0bccd6864c..cafed393010 100644 --- a/i18n/cht/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "toggleGitViewlet": "顯示 Git", + "installAdditionalSCMProviders": "安è£é¡å¤–SCMæ供者...", "source control": "原始檔控制", "toggleSCMViewlet": "顯示 SCM", "view": "檢視" diff --git a/i18n/cht/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json b/i18n/cht/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json index d1872f571b1..5450727934a 100644 --- a/i18n/cht/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "installAdditionalSCMProviders": "安è£é¡å¤–SCMæ供者...", "switch provider": "åˆ‡æ› SCM æ供者..." } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/cht/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index e35a0884650..c9f6c178105 100644 --- a/i18n/cht/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,5 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0},工作" + "entryAriaLabel": "{0},工作", + "workspace": "從工作å€", + "extension": "從擴充功能" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json b/i18n/cht/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json index 877f81d59fd..ae636e70679 100644 --- a/i18n/cht/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json @@ -6,6 +6,7 @@ { "selectTheme.label": "色彩佈景主題", "installColorThemes": "安è£å…¶ä»–的色彩佈景主題...", + "themes.selectTheme": "é¸å–色彩主題(上/下éµé è¦½)", "selectIconTheme.label": "檔案圖示佈景主題", "installIconThemes": "安è£å…¶ä»–的檔案圖示主題...", "noIconThemeLabel": "ç„¡", diff --git a/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json index 00a45ea1dc0..9a00f615c32 100644 --- a/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -11,6 +11,7 @@ "welcomePage.openFolder": "開啟資料夾...", "welcomePage.cloneGitRepository": "複製 Git 存放庫...", "welcomePage.recent": "最近使用", + "welcomePage.moreRecent": "更多...", "welcomePage.noRecentFolders": "沒有最近使用的資料夾", "welcomePage.help": "說明", "welcomePage.introductoryVideos": "簡介影片", @@ -19,10 +20,12 @@ "welcomePage.stackOverflow": "Stack Overflow", "welcomePage.showOnStartup": "啟動時顯示歡迎é é¢", "welcomePage.customize": "自訂", + "welcomePage.moreExtensions": "更多", "welcomePage.installKeymapDescription": "安è£éµç›¤å¿«é€Ÿéµ", "welcomePage.others": "其他", "welcomePage.colorTheme": "彩色佈景主題", "welcomePage.colorThemeDescription": "將編輯器åŠæ‚¨çš„程å¼ç¢¼è¨­å®šæˆæ‚¨å–œæ„›çš„外觀", + "welcomePage.learn": "深入了解", "welcomePage.showCommands": "尋找åŠåŸ·è¡Œæ‰€æœ‰å‘½ä»¤", "welcomePage.showCommandsDescription": "從控制å°å¿«é€Ÿå­˜å–åŠæœå°‹å‘½ä»¤ ({0})", "welcomePage.interfaceOverview": "介é¢æ¦‚觀", diff --git a/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 02eb36873b6..dfce04ba61a 100644 --- a/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -5,11 +5,22 @@ // Do not edit this file. It is machine generated. { "welcomePage": "歡迎使用", + "welcomePage.javaScript": "JavaScript", + "welcomePage.typeScript": "TypeScript", + "welcomePage.python": "Python", + "welcomePage.php": "PHP", + "welcomePage.docker": "Docker", + "welcomePage.vim": "活力", + "welcomePage.sublime": "壯麗", + "welcomePage.atom": "Atom", "welcomePage.keymapAlreadyInstalled": "å·²å®‰è£ {0} éµç›¤å¿«é€Ÿéµã€‚", "welcomePage.willReloadAfterInstallingKeymap": "{0} éµç›¤å¿«é€Ÿéµå®‰è£å®Œæˆå¾Œï¼Œå°‡æœƒé‡æ–°è¼‰å…¥æ­¤è¦–窗。", "welcomePage.installingKeymap": "æ­£åœ¨å®‰è£ {0} éµç›¤å¿«é€Ÿéµ...", "welcomePage.keymapNotFound": "找ä¸åˆ°è­˜åˆ¥ç¢¼ç‚º {1} çš„ {0} éµç›¤å¿«é€Ÿéµã€‚", "welcome.title": "歡迎使用", + "welcomePage.extensionListSeparator": ",", + "welcomePage.installedExtension": "{0}(已安è£)", "ok": "確定", - "cancel": "å–消" + "cancel": "å–消", + "welcomePage.quickLinkBackground": "起始é é¢é€£çµçš„背景色彩." } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json b/i18n/cht/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json index 62ddb9869c6..920973ad063 100644 --- a/i18n/cht/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json @@ -5,5 +5,6 @@ // Do not edit this file. It is machine generated. { "walkThrough.unboundCommand": "未繫çµ", - "walkThrough.gitNotFound": "æ‚¨çš„ç³»çµ±ä¸Šä¼¼ä¹Žæœªå®‰è£ Git。" + "walkThrough.gitNotFound": "æ‚¨çš„ç³»çµ±ä¸Šä¼¼ä¹Žæœªå®‰è£ Git。", + "walkThrough.embeddedEditorBackground": "編輯器互動å€å¡Šçš„背景色彩." } \ No newline at end of file diff --git a/i18n/deu/extensions/git/out/main.i18n.json b/i18n/deu/extensions/git/out/main.i18n.json index 6cf07d1824f..58ab0b365d0 100644 --- a/i18n/deu/extensions/git/out/main.i18n.json +++ b/i18n/deu/extensions/git/out/main.i18n.json @@ -7,5 +7,5 @@ "using git": "Verwenden von Git {0} von {1}", "updateGit": "Git aktualisieren", "neverShowAgain": "Nicht mehr anzeigen", - "git20": "Sie haben anscheinend Git {0} installiert. Der Code funktioniert am besten mit Git 2 oder älter" + "git20": "Sie haben anscheinend Git {0} installiert. Code funktioniert am besten mit Git 2 oder neuer" } \ No newline at end of file diff --git a/i18n/deu/extensions/markdown/out/extension.i18n.json b/i18n/deu/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/deu/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/deu/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/deu/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/deu/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/deu/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/deu/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/deu/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/deu/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/deu/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/deu/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/deu/extensions/merge-conflict/package.i18n.json b/i18n/deu/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/deu/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/deu/extensions/npm/package.i18n.json b/i18n/deu/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/deu/extensions/npm/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/deu/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/deu/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index a2b0a61e0fa..24c2e906e90 100644 --- a/i18n/deu/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/deu/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,8 +6,6 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "Das Bild ist zu groß für den Editor. ", - "resourceOpenExternalButton": "Bild öffnen", - "resourceOpenExternalText": " mit externem Programm?", "nativeBinaryError": "Die Datei wird nicht im Editor angezeigt, weil sie binär oder sehr groß ist oder eine nicht unterstützte Textcodierung verwendet.", "sizeB": "{0} B", "sizeKB": "{0} KB", diff --git a/i18n/deu/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/deu/src/vs/editor/common/config/commonEditorConfig.i18n.json index 2fe70e62eed..a01ec274ece 100644 --- a/i18n/deu/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/deu/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -40,7 +40,6 @@ "formatOnType": "Steuert, ob der Editor Zeilen automatisch nach der Eingabe formatiert.", "formatOnPaste": "Steuert, ob der Editor den eingefügten Inhalt automatisch formatiert.", "suggestOnTriggerCharacters": "Steuert, ob Vorschläge automatisch bei der Eingabe von Triggerzeichen angezeigt werden.", - "acceptSuggestionOnEnter": "Steuert, ob Vorschläge über die Eingabetaste (zusätzlich zur TAB-Taste) angenommen werden sollen. Vermeidet Mehrdeutigkeit zwischen dem Einfügen neuer Zeilen oder dem Annehmen von Vorschlägen.", "acceptSuggestionOnCommitCharacter": "Steuert, ob Vorschläge über Commitzeichen angenommen werden sollen. In JavaScript kann ein Semikolon (\";\") beispielsweise ein Commitzeichen sein, das einen Vorschlag annimmt und dieses Zeichen eingibt.", "snippetSuggestions": "Steuert, ob Codeausschnitte mit anderen Vorschlägen angezeigt und wie diese sortiert werden.", "emptySelectionClipboard": "Steuert, ob ein Kopiervorgang ohne Auswahl die aktuelle Zeile kopiert.", diff --git a/i18n/deu/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/deu/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..ffee2c2fa36 --- /dev/null +++ b/i18n/deu/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "Keine Definition gefunden für \"{0}\".", + "generic.noResults": "Keine Definition gefunden", + "meta.title": " – {0} Definitionen", + "actions.goToDecl.label": "Gehe zu Definition", + "actions.goToDeclToSide.label": "Definition an der Seite öffnen", + "actions.previewDecl.label": "Peek-Definition", + "goToImplementation.noResultWord": "Keine Implementierung gefunden für \"{0}\"", + "goToImplementation.generic.noResults": "Keine Implementierung gefunden", + "meta.implementations.title": "{0} Implementierungen", + "actions.goToImplementation.label": "Zur Implementierung wechseln", + "actions.peekImplementation.label": "Vorschau der Implementierung anzeigen", + "goToTypeDefinition.noResultWord": "Keine Typendefinition gefunden für \"{0}\"", + "goToTypeDefinition.generic.noResults": "Keine Typendefinition gefunden", + "meta.typeDefinitions.title": "{0} Typdefinitionen", + "actions.goToTypeDefinition.label": "Zur Typdefinition wechseln", + "actions.peekTypeDefinition.label": "Vorschau der Typdefinition anzeigen" +} \ No newline at end of file diff --git a/i18n/deu/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/deu/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..2d5f00609a8 --- /dev/null +++ b/i18n/deu/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "Klicken Sie, um {0} Definitionen anzuzeigen." +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/deu/src/vs/workbench/electron-browser/main.contribution.i18n.json index e519ed643e2..15f166829b2 100644 --- a/i18n/deu/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/deu/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -7,6 +7,7 @@ "view": "Anzeigen", "help": "Hilfe", "file": "Datei", + "developer": "Entwickler", "showEditorTabs": "Steuert, ob geöffnete Editoren auf Registerkarten angezeigt werden sollen.", "editorTabCloseButton": "Steuert die Position der Schließen-Schaltflächen der Editor-Registerkarten oder deaktiviert sie bei der Einstellung \"off\".", "showIcons": "Steuert, ob geöffnete Editoren mit einem Symbol angezeigt werden sollen. Hierzu muss auch ein Symboldesign aktiviert werden.", diff --git a/i18n/deu/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/deu/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 8b6ad71cd4e..5c79e379437 100644 --- a/i18n/deu/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "disableOtherKeymapsConfirmation": "Andere Tastenzuordnungen deaktivieren, um Konflikte zwischen Tastenzuordnungen zu vermeiden?", + "yes": "Ja", + "no": "Nein" +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/deu/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 8880b15033b..8153f54254b 100644 --- a/i18n/deu/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,7 +16,6 @@ "associations": "Konfigurieren Sie Dateizuordnungen zu Sprachen (beispielsweise \"*.extension\": \"html\"). Diese besitzen Vorrang vor den Standardzuordnungen der installierten Sprachen.", "encoding": "Die Standardzeichensatz-Codierung, die beim Lesen und Schreiben von Dateien verwendet werden soll.", "autoGuessEncoding": "Ist diese Option aktiviert, wird beim Öffnen von Dateien versucht, die Zeichensatzcodierung automatisch zu ermitteln.", - "eol": "Das Zeilenende-Standardzeichen.", "trimTrailingWhitespace": "Bei Aktivierung werden nachgestellte Leerzeichen beim Speichern einer Datei gekürzt.", "insertFinalNewline": "Bei Aktivierung wird beim Speichern einer Datei eine abschließende neue Zeile am Dateiende eingefügt.", "files.autoSave.off": "Eine geänderte Datei wird nie automatisch gespeichert.", diff --git a/i18n/deu/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/deu/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index 96d83227f67..687359bd486 100644 --- a/i18n/deu/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -5,5 +5,9 @@ // Do not edit this file. It is machine generated. { "slow": "Langsamer Start erkannt", - "slow.detail": "Es tut uns leid, dass Ihr Start so langsam war. Starten Sie \"{0}\" mit aktivierter Profilerstellung neu, geben Sie die Profile für uns frei, und wir tun unser Bestes, damit der Start bald wieder perfekt funktioniert." + "slow.detail": "Es tut uns leid, dass Ihr Start so langsam war. Starten Sie \"{0}\" mit aktivierter Profilerstellung neu, geben Sie die Profile für uns frei, und wir tun unser Bestes, damit der Start bald wieder perfekt funktioniert.", + "prof.message": "Profile wurden erfolgreich erstellt.", + "prof.detail": "Erstellen Sie ein Problem, und fügen Sie die folgenden Dateien manuell an:\n{0}", + "prof.restartAndFileIssue": "Problem erstellen und neu starten", + "prof.restart": "Neu starten" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 1bc33347222..5693a1f5b13 100644 --- a/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -5,6 +5,11 @@ // Do not edit this file. It is machine generated. { "welcomePage": "Willkommen", + "welcomePage.typeScript": "TypeScript", + "welcomePage.php": "PHP", + "welcomePage.vim": "Vim", + "welcomePage.sublime": "Sublime", + "welcomePage.atom": "Atom", "welcomePage.keymapAlreadyInstalled": "Die {0} Tastenkombinationen sind bereits installiert.", "welcomePage.willReloadAfterInstallingKeymap": "Das Fenster wird nach der Installation der {0}-Tastaturbefehle neu geladen.", "welcomePage.installingKeymap": "Die {0}-Tastenkombinationen werden installiert...", diff --git a/i18n/esn/extensions/jake/out/main.i18n.json b/i18n/esn/extensions/jake/out/main.i18n.json index 8b6ad71cd4e..1b387f27070 100644 --- a/i18n/esn/extensions/jake/out/main.i18n.json +++ b/i18n/esn/extensions/jake/out/main.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "execFailed": "La detección automática de Jake falló con el error: {0}" +} \ No newline at end of file diff --git a/i18n/esn/extensions/jake/package.i18n.json b/i18n/esn/extensions/jake/package.i18n.json index 8b6ad71cd4e..c22d4c52c92 100644 --- a/i18n/esn/extensions/jake/package.i18n.json +++ b/i18n/esn/extensions/jake/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.jake.autoDetect": "Controla si la detección automática de tareas Jake estan activada/desactivada. El valor predeterminado es \"activada\"." +} \ No newline at end of file diff --git a/i18n/esn/extensions/markdown/out/extension.i18n.json b/i18n/esn/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/esn/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/esn/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/esn/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/esn/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/esn/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/esn/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/esn/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/esn/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/esn/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/esn/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/esn/extensions/merge-conflict/package.i18n.json b/i18n/esn/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/esn/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/esn/extensions/npm/package.i18n.json b/i18n/esn/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/esn/extensions/npm/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/esn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/esn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index f7060053115..8029ab0b3bd 100644 --- a/i18n/esn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/esn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,8 +6,6 @@ { "imgMeta": "{0} x {1} {2}", "largeImageError": "La imagen es muy grande para mostrar en el editor", - "resourceOpenExternalButton": "Abrir imagen", - "resourceOpenExternalText": "usar programa externo?", "nativeBinaryError": "El archivo no se mostrará en el editor porque es binario, muy grande o usa una codificación de texto no compatible.", "sizeB": "{0} B", "sizeKB": "{0} KB", diff --git a/i18n/esn/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/esn/src/vs/editor/common/config/commonEditorConfig.i18n.json index deeb605c6a6..8fe058e55ce 100644 --- a/i18n/esn/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/esn/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -9,6 +9,7 @@ "fontWeight": "Controla el grosor de la fuente.", "fontSize": "Controla el tamaño de fuente en píxeles.", "lineHeight": "Controla la altura de línea. Utilice 0 para calcular el valor de lineHeight a partir de fontSize.", + "letterSpacing": "Controla el espacio entre letras en pixels.", "lineNumbers": "Controla la presentación de los números de línea. Los valores posibles son \"on\", \"off\" y \"relative\". \"relative\" muestra el número de líneas desde la posición actual del cursor.", "rulers": "Columnas en las que mostrar reglas verticales", "wordSeparators": "Caracteres que se usarán como separadores de palabras al realizar operaciones o navegaciones relacionadas con palabras.", @@ -40,7 +41,6 @@ "formatOnType": "Controla si el editor debe dar formato automáticamente a la línea después de escribirla", "formatOnPaste": "Controla si el editor debe formatear automáticamente el contenido pegado. Debe haber disponible un formateador capaz de aplicar formato a un intervalo dentro de un documento.", "suggestOnTriggerCharacters": "Controla si las sugerencias deben aparecer de forma automática al escribir caracteres desencadenadores", - "acceptSuggestionOnEnter": "Controla si las sugerencias deben aceptarse en \"Entrar\" (además de \"TAB\"). Ayuda a evitar la ambigüedad entre insertar nuevas líneas o aceptar sugerencias.", "acceptSuggestionOnCommitCharacter": "Controla si se deben aceptar sugerencias en los caracteres de confirmación. Por ejemplo, en Javascript, el punto y coma (\";\") puede ser un carácter de confirmación que acepta una sugerencia y escribe ese carácter.", "snippetSuggestions": "Controla si se muestran los fragmentos de código con otras sugerencias y cómo se ordenan.", "emptySelectionClipboard": "Controla si al copiar sin selección se copia la línea actual.", @@ -62,6 +62,7 @@ "renderLineHighlight": "Controla cómo el editor debe presentar el resaltado de línea. Las posibilidades son \"ninguno\", \"margen\", \"línea\" y \"todo\".", "codeLens": "Controla si el editor muestra lentes de código", "folding": "Controla si el editor tiene habilitado el plegado de código.", + "showFoldingControls": "Controla cuándo los controles de plegado del margen son ocultados automáticamente.", "matchBrackets": "Resaltar corchetes coincidentes cuando se seleccione uno de ellos.", "glyphMargin": "Controla si el editor debe representar el margen de glifo vertical. El margen de glifo se usa, principalmente, para depuración.", "useTabStops": "La inserción y eliminación del espacio en blanco sigue a las tabulaciones.", diff --git a/i18n/esn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/esn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..d9243b76135 --- /dev/null +++ b/i18n/esn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "No se encontró ninguna definición para \"{0}\"", + "generic.noResults": "No se encontró ninguna definición", + "meta.title": " – {0} definiciones", + "actions.goToDecl.label": "Ir a definición", + "actions.goToDeclToSide.label": "Abrir definición en el lateral", + "actions.previewDecl.label": "Ver la definición", + "goToImplementation.noResultWord": "No se encontró ninguna implementación para \"{0}\"", + "goToImplementation.generic.noResults": "No se encontró ninguna implementación", + "meta.implementations.title": "{0} implementaciones", + "actions.goToImplementation.label": "Ir a implementación", + "actions.peekImplementation.label": "Inspeccionar implementación", + "goToTypeDefinition.noResultWord": "No se encontró ninguna definición de tipo para \"{0}\"", + "goToTypeDefinition.generic.noResults": "No se encontró ninguna definición de tipo", + "meta.typeDefinitions.title": " – {0} definiciones de tipo", + "actions.goToTypeDefinition.label": "Ir a la definición de tipo", + "actions.peekTypeDefinition.label": "Inspeccionar definición de tipo" +} \ No newline at end of file diff --git a/i18n/esn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/esn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..d35f93e7fae --- /dev/null +++ b/i18n/esn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "Haga clic para mostrar {0} definiciones." +} \ No newline at end of file diff --git a/i18n/esn/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json b/i18n/esn/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json index f9d2c2d5f09..bf3d8015426 100644 --- a/i18n/esn/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json +++ b/i18n/esn/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json @@ -12,6 +12,7 @@ "readMore": "Leer más...{0}", "suggestionWithDetailsAriaLabel": "{0}, sugerencia, con detalles", "suggestionAriaLabel": "{0}, sugerencia", + "readLess": "Leer menos...{0}", "suggestWidget.loading": "Cargando...", "suggestWidget.noSuggestions": "No hay sugerencias.", "suggestionAriaAccepted": "{0}, aceptada", diff --git a/i18n/esn/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json b/i18n/esn/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json index df256b0ca88..43ec87cbde1 100644 --- a/i18n/esn/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json +++ b/i18n/esn/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json @@ -15,5 +15,9 @@ "schema.brackets": "Define los corchetes que aumentan o reducen la sangría.", "schema.autoClosingPairs": "Define el par de corchetes. Cuando se escribe un corchete de apertura, se inserta automáticamente el corchete de cierre.", "schema.autoClosingPairs.notIn": "Define una lista de ámbitos donde los pares automáticos están deshabilitados.", - "schema.surroundingPairs": "Define los pares de corchetes que se pueden usar para encerrar una cadena seleccionada." + "schema.surroundingPairs": "Define los pares de corchetes que se pueden usar para encerrar una cadena seleccionada.", + "schema.wordPattern": " La definición de la palabra en el idioma.", + "schema.wordPattern.pattern": "El patrón de expresión regular utilizado para localizar palabras.", + "schema.wordPattern.flags": "Los flags de expresión regular utilizados para localizar palabras.", + "schema.wordPattern.flags.errorMessage": "Debe coincidir con el patrón `/^([gimuy]+)$/`." } \ No newline at end of file diff --git a/i18n/esn/src/vs/platform/markers/common/problemMatcher.i18n.json b/i18n/esn/src/vs/platform/markers/common/problemMatcher.i18n.json index 967ffc75983..1c9dfefb5cb 100644 --- a/i18n/esn/src/vs/platform/markers/common/problemMatcher.i18n.json +++ b/i18n/esn/src/vs/platform/markers/common/problemMatcher.i18n.json @@ -34,6 +34,7 @@ "ProblemMatcherParser.noValidIdentifier": "Error: La propiedad pattern {0} no es un nombre de variable de patrón válido.", "ProblemMatcherParser.problemPattern.watchingMatcher": "Un buscador de coincidencias de problemas debe definir tanto un patrón de inicio como un patrón de finalización para la inspección.", "ProblemMatcherParser.invalidRegexp": "Error: La cadena {0} no es una expresión regular válida.\n", + "WatchingPatternSchema.regexp": "Expresión regular para detectar el principio o el final de una tarea en segundo plano.", "WatchingPatternSchema.file": "Ãndice de grupo de coincidencias del nombre de archivo. Se puede omitir.", "PatternTypeSchema.name": "Nombre de un patrón aportado o predefinido", "PatternTypeSchema.description": "Patrón de problema o nombre de un patrón de problema que se ha aportado o predefinido. Se puede omitir si se especifica la base.", @@ -42,6 +43,12 @@ "ProblemMatcherSchema.severity": "Gravedad predeterminada para los problemas de capturas. Se usa si el patrón no define un grupo de coincidencias para \"severity\".", "ProblemMatcherSchema.applyTo": "Controla si un problema notificado en un documento de texto se aplica solamente a los documentos abiertos, cerrados o a todos los documentos.", "ProblemMatcherSchema.fileLocation": "Define cómo deben interpretarse los nombres de archivo notificados en un patrón de problema.", + "ProblemMatcherSchema.background": "Patrones para hacer seguimiento del comienzo y el final en un comprobador activo de la tarea en segundo plano.", + "ProblemMatcherSchema.background.activeOnStart": "Si se establece en True, el monitor está en modo activo cuando la tarea empieza. Esto es equivalente a emitir una línea que coincide con beginPattern", + "ProblemMatcherSchema.background.beginsPattern": "Si se encuentran coincidencias en la salida, se señala el inicio de una tarea en segundo plano.", + "ProblemMatcherSchema.background.endsPattern": "Si se encuentran coincidencias en la salida, se señala el fin de una tarea en segundo plano.", + "ProblemMatcherSchema.watching.deprecated": "Esta propiedad está en desuso. Use la propiedad en segundo plano.", + "ProblemMatcherSchema.watching": "Patrones para hacer un seguimiento del comienzo y el final de un patrón de supervisión.", "ProblemMatcherSchema.watching.activeOnStart": "Si se establece en true, el monitor está en modo activo cuando la tarea empieza. Esto es equivalente a emitir una línea que coincide con beginPattern", "ProblemMatcherSchema.watching.beginsPattern": "Si se encuentran coincidencias en la salida, se señala el inicio de una tarea de inspección.", "ProblemMatcherSchema.watching.endsPattern": "Si se encuentran coincidencias en la salida, se señala el fin de una tarea de inspección", diff --git a/i18n/esn/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/esn/src/vs/platform/theme/common/colorRegistry.i18n.json index 85f87911be1..889a845a813 100644 --- a/i18n/esn/src/vs/platform/theme/common/colorRegistry.i18n.json +++ b/i18n/esn/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -36,11 +36,13 @@ "dropdownForeground": "Primer plano de lista desplegable.", "dropdownBorder": "Borde de lista desplegable.", "listFocusBackground": "Color de fondo de la lista o el árbol del elemento con el foco cuando la lista o el árbol están activos. Una lista o un árbol tienen el foco del teclado cuando están activos, cuando están inactivos no.", + "listFocusForeground": "Color de fondo de la lista o el árbol del elemento con el foco cuando la lista o el árbol están activos. Una lista o un árbol tienen el foco del teclado cuando están activos, cuando están inactivos no.", "listActiveSelectionBackground": "Color de fondo de la lista o el árbol del elemento seleccionado cuando la lista o el árbol están activos. Una lista o un árbol tienen el foco del teclado cuando están activos, cuando están inactivos no.", "listActiveSelectionForeground": "Color de primer plano de la lista o el árbol del elemento con el foco cuando la lista o el árbol están activos. Una lista o un árbol tienen el foco del teclado cuando están activos, cuando están inactivos no.", "listInactiveSelectionBackground": "Color de fondo de la lista o el árbol del elemento seleccionado cuando la lista o el árbol están inactivos. Una lista o un árbol tienen el foco del teclado cuando están activos, cuando están inactivos no.", "listInactiveSelectionForeground": "Color de primer plano de la lista o el árbol del elemento con el foco cuando la lista o el árbol esta inactiva. Una lista o un árbol tiene el foco del teclado cuando está activo, cuando esta inactiva no.", "listHoverBackground": "Fondo de la lista o el árbol al mantener el mouse sobre los elementos.", + "listHoverForeground": "Color de primer plano de la lista o el árbol al pasar por encima de los elementos con el ratón.", "listDropBackground": "Fondo de arrastrar y colocar la lista o el árbol al mover los elementos con el mouse.", "highlight": "Color de primer plano de la lista o el árbol de las coincidencias resaltadas al buscar dentro de la lista o el ábol.", "pickerGroupForeground": "Selector de color rápido para la agrupación de etiquetas.", @@ -58,6 +60,7 @@ "editorBackground": "Color de fondo del editor.", "editorForeground": "Color de primer plano predeterminado del editor.", "editorWidgetBackground": "Color de fondo del editor de widgets como buscar/reemplazar", + "editorWidgetBorder": "Color de borde del editor de widget.", "editorSelection": "Color de la selección del editor.", "editorInactiveSelection": "Color de la selección en un editor inactivo.", "editorSelectionHighlight": "Color de las regiones con el mismo contenido que la selección.", diff --git a/i18n/esn/src/vs/workbench/api/node/extHostTreeViews.i18n.json b/i18n/esn/src/vs/workbench/api/node/extHostTreeViews.i18n.json index 8b6ad71cd4e..1127a4ec4f8 100644 --- a/i18n/esn/src/vs/workbench/api/node/extHostTreeViews.i18n.json +++ b/i18n/esn/src/vs/workbench/api/node/extHostTreeViews.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "treeView.notRegistered": "No se ha registrado ninga vista del árbol con id '{0}'.", + "treeItem.notFound": "No se encontró ningún item del árbol con id '{0}'.", + "treeView.duplicateElement": "El elemento '{0}' ya está registrado" +} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/common/theme.i18n.json b/i18n/esn/src/vs/workbench/common/theme.i18n.json index 97f9736e665..40dfe03ebb6 100644 --- a/i18n/esn/src/vs/workbench/common/theme.i18n.json +++ b/i18n/esn/src/vs/workbench/common/theme.i18n.json @@ -32,6 +32,7 @@ "activityBarBadgeBackground": "Color de fondo de distintivo de notificación de actividad. La barra de actividad se muestra en el extremo izquierdo o derecho y permite cambiar entre vistas de la barra lateral.", "activityBarBadgeForeground": "Color de primer plano de distintivo de notificación de actividad. La barra de actividad se muestra en el extremo izquierdo o derecho y permite cambiar entre vistas de la barra lateral.", "sideBarBackground": "Color de fondo de la barra lateral, que es el contenedor de vistas como Explorador y Búsqueda.", + "sideBarForeground": "Color de primer plano de la barra lateral, que es el contenedor de vistas como Explorador y Búsqueda.", "sideBarTitleForeground": "Color de primer plano del título de la barra lateral, que es el contenedor de vistas como Explorador y Búsqueda.", "sideBarSectionHeaderBackground": "Color de fondo del encabezado de sección de la barra lateral, que es el contenedor de vistas como Explorador y Búsqueda.", "titleBarActiveForeground": "Color de primer plano de la barra de título cuando la ventana está activa. Tenga en cuenta que, actualmente, este clor solo se admite en macOS.", diff --git a/i18n/esn/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/esn/src/vs/workbench/electron-browser/main.contribution.i18n.json index cbf9d0deef3..543d5451907 100644 --- a/i18n/esn/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/esn/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -7,6 +7,7 @@ "view": "Ver", "help": "Ayuda", "file": "Archivo", + "developer": "Desarrollador", "showEditorTabs": "Controla si los editores abiertos se deben mostrar o no en pestañas.", "editorTabCloseButton": "Controla la posición de los botones de cierre de pestañas del editor o los deshabilita si se establece en \"off\".", "showIcons": "Controla si los editores abiertos deben mostrarse o no con un icono. Requiere que también se habilite un tema de icono.", diff --git a/i18n/esn/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json b/i18n/esn/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json index cb1c2139583..00a55728fff 100644 --- a/i18n/esn/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json @@ -7,6 +7,7 @@ "debugAdapterBinNotFound": "El ejecutable del adaptador de depuración \"{0}\" no existe.", "debugAdapterCannotDetermineExecutable": "No se puede determinar el ejecutable para el adaptador de depuración \"{0}\".", "debugType": "Tipo de configuración.", + "debugTypeNotRecognised": "Este tipo de depuración no se reconoce. Compruebe que tiene instalada la correspondiente extensión de depuración y que está habilitada.", "node2NotSupported": "\"node2\" ya no se admite; use \"node\" en su lugar y establezca el atributo \"protocol\" en \"inspector\".", "debugName": "Nombre de la configuración. Aparece en el menú desplegable de la configuración de inicio.", "debugRequest": "Tipo de solicitud de la configuración. Puede ser \"launch\" o \"attach\".", diff --git a/i18n/esn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/esn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 8b6ad71cd4e..2b42d7a0c5b 100644 --- a/i18n/esn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "disableOtherKeymapsConfirmation": "¿Quiere deshabilitar otras asignaciones de teclado para evitar conflictos entre los enlaces de teclado?", + "yes": "Sí", + "no": "No" +} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/esn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 9b8bcb5fdf1..ef718dc3ee1 100644 --- a/i18n/esn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,7 +16,6 @@ "associations": "Configure asociaciones de archivo para los lenguajes (por ejemplo, \"*.extension\": \"html\"). Estas asociaciones tienen prioridad sobre las asociaciones predeterminadas de los lenguajes instalados.", "encoding": "La codificación del juego de caracteres predeterminada que debe utilizarse al leer y escribir archivos.", "autoGuessEncoding": "Si está opción está habilitada, se intentará adivinar la codificación del juego de caracteres al abrir los archivos", - "eol": "Carácter predeterminado de final de línea.", "trimTrailingWhitespace": "Si se habilita, se recortará el espacio final cuando se guarde un archivo.", "insertFinalNewline": "Si se habilita, inserte una nueva línea final al final del archivo cuando lo guarde.", "files.autoSave.off": "Un archivo con modificaciones no se guarda nunca automáticamente.", diff --git a/i18n/esn/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/esn/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index 712641fcab1..81f5a667ca8 100644 --- a/i18n/esn/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -5,5 +5,11 @@ // Do not edit this file. It is machine generated. { "slow": "Inicio lento detectado", - "slow.detail": "Lamentamos que haya tenido un inicio lento. Reinicie \"{0}\" con la generación de perfiles habilitada, comparta los perfiles con nosotros y trabajaremos a fondo para que vuelva a disfrutar de un inicio increíble." + "slow.detail": "Lamentamos que haya tenido un inicio lento. Reinicie \"{0}\" con la generación de perfiles habilitada, comparta los perfiles con nosotros y trabajaremos a fondo para que vuelva a disfrutar de un inicio increíble.", + "prof.message": "Los perfiles se crearon correctamente.", + "prof.detail": "Cree un problema y asóciele manualmente los siguientes archivos: {0}", + "prof.restartAndFileIssue": "Crear problema y reiniciar", + "prof.restart": "Reiniciar", + "prof.thanks": "Gracias por ayudarnos.", + "prof.detail.restart": "Se necesita un reinicio final para continuar utilizando '{0}'. De nuevo, gracias por su aportación." } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json b/i18n/esn/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json index 2d44f58d514..a77a2211780 100644 --- a/i18n/esn/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "toggleGitViewlet": "Mostrar GIT", + "installAdditionalSCMProviders": "Instalar proveedores adicionales de SCM...", "source control": "Control de código fuente", "toggleSCMViewlet": "Mostrar SCM", "view": "Ver" diff --git a/i18n/esn/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json b/i18n/esn/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json index 58e5c2559c8..048db5a28d0 100644 --- a/i18n/esn/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "installAdditionalSCMProviders": "Instalar proveedores adicionales de SCM...", "switch provider": "Cambiar proveedor de SCM..." } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/esn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index e5995f59713..30e2262eef7 100644 --- a/i18n/esn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,5 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0}, tareas" + "entryAriaLabel": "{0}, tareas", + "workspace": "De área de trabajo", + "extension": "De extensiones" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json b/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json index 930b60298c1..58c4eca7cfe 100644 --- a/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json @@ -6,5 +6,6 @@ { "TerminalTaskSystem.unknownError": "Error desconocido durante la ejecución de una tarea. Vea el registro de resultados de la tarea para obtener más detalles.", "TerminalTaskSystem.terminalName": "Tarea - {0}", - "TerminalTaskSystem": "No se puede ejecutar un comando shell en una unidad UNC." + "TerminalTaskSystem": "No se puede ejecutar un comando shell en una unidad UNC.", + "unkownProblemMatcher": "No puede resolver el comprobador de problemas {0}. Será omitido." } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json b/i18n/esn/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json index 651c8b00513..b300e0e061a 100644 --- a/i18n/esn/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json @@ -7,5 +7,6 @@ "TaskRunnerSystem.unknownError": "Error desconocido durante la ejecución de una tarea. Vea el registro de resultados de la tarea para obtener más detalles.", "TaskRunnerSystem.watchingBuildTaskFinished": "La inspección de las tareas de compilación ha finalizado.", "TaskRunnerSystem.childProcessError": "Failed to launch external program {0} {1}.", - "TaskRunnerSystem.cancelRequested": "La tarea '{0}' se finalizó por solicitud del usuario." + "TaskRunnerSystem.cancelRequested": "La tarea '{0}' se finalizó por solicitud del usuario.", + "unkownProblemMatcher": "No puede resolver el comprobador de problemas {0}. Será omitido" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json index 9591e0b1673..2438b3e1709 100644 --- a/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -14,13 +14,18 @@ "welcomePage.moreRecent": "Más...", "welcomePage.noRecentFolders": "No hay ninguna carpeta reciente", "welcomePage.help": "Ayuda", + "welcomePage.keybindingsCheatsheet": "Hoja imprimible con ayudas de teclado", "welcomePage.introductoryVideos": "Vídeos de introducción", "welcomePage.productDocumentation": "Documentación del producto", "welcomePage.gitHubRepository": "Repositorio de GitHub", "welcomePage.stackOverflow": "Stack Overflow", "welcomePage.showOnStartup": "Mostrar página principal al inicio", "welcomePage.customize": "Personalizar", + "welcomePage.installExtensionPacks": "Herramientas y lenguajes", + "welcomePage.installExtensionPacksDescription": "Instalar soporte para {0} y {1}", + "welcomePage.moreExtensions": "más", "welcomePage.installKeymapDescription": "Instalar los métodos abreviados de teclado", + "welcomePage.installKeymapExtension": "Instalar los métodos abreviados de teclado de {0} y {1}", "welcomePage.others": "otros", "welcomePage.colorTheme": "Tema de color", "welcomePage.colorThemeDescription": "Modifique a su gusto la apariencia del editor y el código", diff --git a/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 28283fba5c3..57b34bdf736 100644 --- a/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -5,11 +5,25 @@ // Do not edit this file. It is machine generated. { "welcomePage": "Bienvenido", + "welcomePage.javaScript": "JavaScript", + "welcomePage.typeScript": "TypeScript", + "welcomePage.python": "Python", + "welcomePage.php": "PHP", + "welcomePage.docker": "Docker", + "welcomePage.vim": "Vim", + "welcomePage.sublime": "Sublime", + "welcomePage.atom": "Atom", + "welcomePage.extensionPackAlreadyInstalled": "El soporte para '{0}' ya está instalado.", + "welcomePage.willReloadAfterInstallingExtensionPack": "La ventana se volverá a cargar después de instalar el soporte para {0}.", + "welcomePage.installingExtensionPack": "Instalando soporte para {0}...", + "welcomePage.extensionPackNotFound": "No se pudo encontrar el soporte para {0} con id {1}.", "welcomePage.keymapAlreadyInstalled": "Los métodos abreviados de teclado {0} ya están instalados.", "welcomePage.willReloadAfterInstallingKeymap": "La ventana se volverá a cargar después de instalar los métodos abreviados de teclado {0}.", "welcomePage.installingKeymap": "Instalando los métodos abreviados de teclado de {0}...", "welcomePage.keymapNotFound": "No se pudieron encontrar los métodos abreviados de teclado {0} con el identificador {1}.", "welcome.title": "Bienvenido", + "welcomePage.extensionListSeparator": ", ", + "welcomePage.installedExtension": "{0} (instalado)", "ok": "Aceptar", "cancel": "Cancelar", "welcomePage.quickLinkBackground": "Color de fondo de los vínculos rápidos en la página principal.", diff --git a/i18n/fra/extensions/markdown/out/extension.i18n.json b/i18n/fra/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/fra/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/fra/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/fra/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/fra/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/fra/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/fra/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/fra/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/fra/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/fra/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/fra/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/fra/extensions/merge-conflict/package.i18n.json b/i18n/fra/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/fra/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/fra/extensions/npm/package.i18n.json b/i18n/fra/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/fra/extensions/npm/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/fra/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/fra/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index d6968482f68..b6faf1c8af7 100644 --- a/i18n/fra/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/fra/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,8 +6,6 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "L'image est trop grande pour être affichée dans l'éditeur. ", - "resourceOpenExternalButton": "Ouvrir l'image", - "resourceOpenExternalText": " en utilisant un programme externe ?", "nativeBinaryError": "Impossible d'afficher le fichier dans l'éditeur : soit il est binaire, soit il est très volumineux, soit il utilise un encodage de texte non pris en charge.", "sizeB": "{0} o", "sizeKB": "{0} Ko", diff --git a/i18n/fra/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/fra/src/vs/editor/common/config/commonEditorConfig.i18n.json index afe0864b817..16acf6481b0 100644 --- a/i18n/fra/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/fra/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -41,7 +41,6 @@ "formatOnType": "Contrôle si l'éditeur doit automatiquement mettre en forme la ligne après la saisie", "formatOnPaste": "Contrôle si l'éditeur doit automatiquement mettre en forme le contenu collé. Un formateur doit être disponible et doit pouvoir mettre en forme une plage dans un document.", "suggestOnTriggerCharacters": "Contrôle si les suggestions doivent s'afficher automatiquement durant la saisie de caractères de déclenchement", - "acceptSuggestionOnEnter": "Contrôle si les suggestions peuvent être acceptées avec Entrée (en plus de Tab). Cela permet d'éviter toute ambiguïté entre l'insertion de nouvelles lignes et l'acceptation de suggestions.", "acceptSuggestionOnCommitCharacter": "Contrôle si les suggestions doivent être acceptées avec des caractères de validation. Par exemple, en JavaScript, le point-virgule (';') peut être un caractère de validation qui permet d'accepter une suggestion et de taper ce caractère.", "snippetSuggestions": "Contrôle si les extraits de code s'affichent en même temps que d'autres suggestions, ainsi que leur mode de tri.", "emptySelectionClipboard": "Contrôle si la copie sans sélection permet de copier la ligne actuelle.", diff --git a/i18n/fra/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/fra/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..0488ff48354 --- /dev/null +++ b/i18n/fra/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "Définition introuvable pour '{0}'", + "generic.noResults": "Définition introuvable", + "meta.title": " – {0} définitions", + "actions.goToDecl.label": "Atteindre la définition", + "actions.goToDeclToSide.label": "Ouvrir la définition sur le côté", + "actions.previewDecl.label": "Apercu de définition", + "goToImplementation.noResultWord": "Implémentation introuvable pour '{0}'", + "goToImplementation.generic.noResults": "Implémentation introuvable", + "meta.implementations.title": "– Implémentations {0}", + "actions.goToImplementation.label": "Accéder à l'implémentation", + "actions.peekImplementation.label": "Aperçu de l'implémentation", + "goToTypeDefinition.noResultWord": "Définition de type introuvable pour '{0}'", + "goToTypeDefinition.generic.noResults": "Définition de type introuvable", + "meta.typeDefinitions.title": " – Définitions de type {0}", + "actions.goToTypeDefinition.label": "Atteindre la définition de type", + "actions.peekTypeDefinition.label": "Aperçu de la définition du type" +} \ No newline at end of file diff --git a/i18n/fra/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/fra/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..247bd9d24da --- /dev/null +++ b/i18n/fra/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "Cliquez pour afficher {0} définitions." +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/fra/src/vs/workbench/electron-browser/main.contribution.i18n.json index 7d14c23b2b5..d1fbda145ce 100644 --- a/i18n/fra/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/fra/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -7,6 +7,7 @@ "view": "Affichage", "help": "Aide", "file": "Fichier", + "developer": "Développeur", "showEditorTabs": "Contrôle si les éditeurs ouverts doivent s'afficher ou non sous des onglets.", "editorTabCloseButton": "Contrôle la position des boutons de fermeture des onglets de l'éditeur, ou les désactive quand le paramètre a la valeur 'off'.", "showIcons": "Contrôle si les éditeurs ouverts doivent s'afficher ou non avec une icône. Cela implique notamment l'activation d'un thème d'icône.", diff --git a/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 8b6ad71cd4e..5ddc77dfc5a 100644 --- a/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "disableOtherKeymapsConfirmation": "Désactiver les autres mappages de touches pour éviter les conflits de combinaisons de touches ?", + "yes": "Oui", + "no": "Non" +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/fra/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 8d72ad31935..6f916235625 100644 --- a/i18n/fra/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,7 +16,6 @@ "associations": "Configurez les associations entre les fichiers et les langages (par exemple, \"*.extension\": \"html\"). Celles-ci ont priorité sur les associations par défaut des langages installés.", "encoding": "Encodage du jeu de caractères par défaut à utiliser durant la lecture et l'écriture des fichiers.", "autoGuessEncoding": "Quand cette option est activée, tente de deviner l'encodage du jeu de caractères à l'ouverture des fichiers", - "eol": "Caractère de fin de ligne par défaut.", "trimTrailingWhitespace": "Si l'option est activée, l'espace blanc de fin est supprimé au moment de l'enregistrement d'un fichier.", "insertFinalNewline": "Quand l'option est activée, une nouvelle ligne finale est insérée à la fin du fichier au moment de son enregistrement.", "files.autoSave.off": "Un fichier dont l'intégrité est compromise n'est jamais enregistré automatiquement.", diff --git a/i18n/fra/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/fra/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index fb432045fcc..56c9603dba7 100644 --- a/i18n/fra/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -5,5 +5,9 @@ // Do not edit this file. It is machine generated. { "slow": "Démarrage lent détecté", - "slow.detail": "Le démarrage a été très lent. Redémarrez '{0}' en ayant activé le profilage, partagez les profils avec nous, et nous ferons en sorte que le démarrage retrouve sa rapidité d'exécution." + "slow.detail": "Le démarrage a été très lent. Redémarrez '{0}' en ayant activé le profilage, partagez les profils avec nous, et nous ferons en sorte que le démarrage retrouve sa rapidité d'exécution.", + "prof.message": "Création réussie des profils.", + "prof.detail": "Créez un problème et joignez manuellement les fichiers suivants :\n{0}", + "prof.restartAndFileIssue": "Créer le problème et redémarrer", + "prof.restart": "Redémarrer" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/fra/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 915c12960a0..66bb9f2ab66 100644 --- a/i18n/fra/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -5,6 +5,11 @@ // Do not edit this file. It is machine generated. { "welcomePage": "Bienvenue", + "welcomePage.typeScript": "TypeScript", + "welcomePage.php": "PHP", + "welcomePage.vim": "Vim", + "welcomePage.sublime": "Sublime", + "welcomePage.atom": "Atom", "welcomePage.keymapAlreadyInstalled": "Les raccourcis clavier {0} sont déjà installés.", "welcomePage.willReloadAfterInstallingKeymap": "La fenêtre se recharge après l'installation des raccourcis clavier {0}.", "welcomePage.installingKeymap": "Installation des raccourcis clavier de {0}...", diff --git a/i18n/ita/extensions/markdown/out/extension.i18n.json b/i18n/ita/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ita/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ita/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/ita/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ita/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ita/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/ita/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ita/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ita/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/ita/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ita/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ita/extensions/merge-conflict/package.i18n.json b/i18n/ita/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ita/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ita/extensions/npm/package.i18n.json b/i18n/ita/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ita/extensions/npm/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ita/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/ita/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index 0ccb13bf8a7..c64a07b4379 100644 --- a/i18n/ita/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/ita/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,8 +6,6 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "L'immagine è troppo grande per essere visualizzata nell'editor", - "resourceOpenExternalButton": "Apri immagine", - "resourceOpenExternalText": " con il programma esterno?", "nativeBinaryError": "Il file non verrà visualizzato nell'editor perché è binario, è molto grande o usa una codifica testo non supportata.", "sizeB": "{0} B", "sizeKB": "{0} KB", diff --git a/i18n/ita/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/ita/src/vs/editor/common/config/commonEditorConfig.i18n.json index 59f730fe1dc..06ec2510c3a 100644 --- a/i18n/ita/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/ita/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -41,7 +41,6 @@ "formatOnType": "Controlla se l'editor deve formattare automaticamente la riga dopo la digitazione", "formatOnPaste": "Controlla se l'editor deve formattare automaticamente il contenuto incollato. Deve essere disponibile un formattatore che deve essere in grado di formattare un intervallo in un documento.", "suggestOnTriggerCharacters": "Controlla se i suggerimenti devono essere visualizzati automaticamente durante la digitazione dei caratteri trigger", - "acceptSuggestionOnEnter": "Controlla se i suggerimenti devono essere accettati con 'INVIO' in aggiunta a 'TAB'. In questo modo è possibile evitare ambiguità tra l'inserimento di nuove righe e l'accettazione di suggerimenti.", "acceptSuggestionOnCommitCharacter": "Controlla se accettare i suggerimenti con i caratteri di commit. Ad esempio, in JavaScript il punto e virgola (';') può essere un carattere di commit che accetta un suggerimento e digita tale carattere.", "snippetSuggestions": "Controlla se i frammenti di codice sono visualizzati con altri suggerimenti e il modo in cui sono ordinati.", "emptySelectionClipboard": "Consente di controllare se, quando si copia senza aver effettuato una selezione, viene copiata la riga corrente.", @@ -63,6 +62,7 @@ "renderLineHighlight": "Consente di controllare in che modo l'editor deve eseguire il rendering dell'evidenziazione di riga corrente. Le opzioni possibili sono 'none', 'gutter', 'line' e 'all'.", "codeLens": "Controlla se nell'editor sono visualizzate le finestre di CodeLens", "folding": "Controlla se per l'editor è abilitata la riduzione del codice", + "showFoldingControls": "Controlla se i controlli di riduzione sul margine della barra di scorrimento sono automaticamente nascosti.", "matchBrackets": "Evidenzia le parentesi corrispondenti quando se ne seleziona una.", "glyphMargin": "Controlla se l'editor deve eseguire il rendering del margine verticale del glifo. Il margine del glifo viene usato principalmente per il debug.", "useTabStops": "Inserimento ed eliminazione dello spazio vuoto dopo le tabulazioni", diff --git a/i18n/ita/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/ita/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..9df481ec1b5 --- /dev/null +++ b/i18n/ita/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "Non è stata trovata alcuna definizione per '{0}'", + "generic.noResults": "Non è stata trovata alcuna definizione", + "meta.title": " - Definizioni di {0}", + "actions.goToDecl.label": "Vai alla definizione", + "actions.goToDeclToSide.label": "Apri definizione lateralmente", + "actions.previewDecl.label": "Visualizza la definizione", + "goToImplementation.noResultWord": "Non sono state trovate implementazioni per '{0}'", + "goToImplementation.generic.noResults": "Non sono state trovate implementazioni", + "meta.implementations.title": "- {0} implementazioni", + "actions.goToImplementation.label": "Vai all'implementazione", + "actions.peekImplementation.label": "Anteprima implementazione", + "goToTypeDefinition.noResultWord": "Non sono state trovate definizioni di tipi per '{0}'", + "goToTypeDefinition.generic.noResults": "Non sono state trovate definizioni di tipi", + "meta.typeDefinitions.title": " - {0} definizioni di tipo", + "actions.goToTypeDefinition.label": "Vai alla definizione di tipo", + "actions.peekTypeDefinition.label": "Anteprima definizione di tipo" +} \ No newline at end of file diff --git a/i18n/ita/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/ita/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..fa526a1f9e6 --- /dev/null +++ b/i18n/ita/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "Fare clic per visualizzare {0} definizioni." +} \ No newline at end of file diff --git a/i18n/ita/src/vs/platform/markers/common/problemMatcher.i18n.json b/i18n/ita/src/vs/platform/markers/common/problemMatcher.i18n.json index a2611139aec..87b88acd388 100644 --- a/i18n/ita/src/vs/platform/markers/common/problemMatcher.i18n.json +++ b/i18n/ita/src/vs/platform/markers/common/problemMatcher.i18n.json @@ -34,6 +34,7 @@ "ProblemMatcherParser.noValidIdentifier": "Errore: la proprietà {0} del criterio non è un nome di variabile criterio valido.", "ProblemMatcherParser.problemPattern.watchingMatcher": "Un matcher problemi deve definire un criterio di inizio e un criterio di fine per il controllo.", "ProblemMatcherParser.invalidRegexp": "Errore: la stringa {0} non è un'espressione regolare valida.\n", + "WatchingPatternSchema.regexp": "L'espressione regolare per rilevare l'inizio o la fine di un'attività in background.", "WatchingPatternSchema.file": "Indice del gruppo di corrispondenze del nome file. Può essere omesso.", "PatternTypeSchema.name": "Nome di un criterio predefinito o aggiunto come contributo", "PatternTypeSchema.description": "Criterio di problema o nome di un criterio di problema predefinito o aggiunto come contributo. Può essere omesso se si specifica base.", @@ -42,6 +43,12 @@ "ProblemMatcherSchema.severity": "Gravità predefinita per i problemi di acquisizione. Viene usato se il criterio non definisce un gruppo di corrispondenze per la gravità.", "ProblemMatcherSchema.applyTo": "Controlla se un problema segnalato in un documento di testo è valido solo per i documenti aperti o chiusi oppure per tutti i documenti.", "ProblemMatcherSchema.fileLocation": "Consente di definire come interpretare i nomi file indicati in un criterio di problema.", + "ProblemMatcherSchema.background": "Criteri per tenere traccia dell'inizio e della fine di un matcher attivo su un'attività in background.", + "ProblemMatcherSchema.background.activeOnStart": "Se impostato a true, il monitor in backbround è in modalità attiva quando l'attività inizia. Equivale a inviare una riga che corrisponde al beginPattern", + "ProblemMatcherSchema.background.beginsPattern": "Se corrisponde nell'output, viene segnalato l'avvio di un'attività in background.", + "ProblemMatcherSchema.background.endsPattern": "Se corrisponde nell'output, viene segnalata la fine di un'attività in background.", + "ProblemMatcherSchema.watching.deprecated": "La proprietà watching è deprecata. In alternativa, utilizzare background (sfondo).", + "ProblemMatcherSchema.watching": "Criteri per tenere traccia dell'inizio e della fine di un matcher watching.", "ProblemMatcherSchema.watching.activeOnStart": "Se impostato su true, indica che il watcher è in modalità attiva all'avvio dell'attività. Equivale a inviare una riga che corrisponde al criterio di avvio", "ProblemMatcherSchema.watching.beginsPattern": "Se corrisponde nell'output, viene segnalato l'avvio di un'attività di controllo.", "ProblemMatcherSchema.watching.endsPattern": "Se corrisponde nell'output, viene segnalata la fine di un'attività di controllo.", diff --git a/i18n/ita/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/ita/src/vs/workbench/electron-browser/main.contribution.i18n.json index c034a8cc727..b13e3a07bdd 100644 --- a/i18n/ita/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/ita/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -7,6 +7,7 @@ "view": "Visualizza", "help": "Guida", "file": "File", + "developer": "Sviluppatore", "showEditorTabs": "Controlla se visualizzare o meno gli editor aperti in schede.", "editorTabCloseButton": "Controlla la posizione dei pulsanti di chiusura delle schede dell'editor oppure li disabilita quando è impostata su 'off'.", "showIcons": "Controlla se visualizzare o meno un'icona per gli editor aperti. Richiede l'abilitazione anche di un tema dell'icona.", diff --git a/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 8b6ad71cd4e..6c3f2e984e8 100644 --- a/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "disableOtherKeymapsConfirmation": "Disabilitare altre mappature tastiera per evitare conflitti tra tasti di scelta rapida?", + "yes": "Sì", + "no": "No" +} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/ita/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 5f1557087a0..a3c0e1da94b 100644 --- a/i18n/ita/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,7 +16,6 @@ "associations": "Consente di configurare le associazioni tra file e linguaggi, ad esempio \"*.extension\": \"html\". Queste hanno la precedenza sulle associazioni predefinite dei linguaggi installate.", "encoding": "Codifica del set di caratteri predefinita da usare durante la lettura e la scrittura di file.", "autoGuessEncoding": "Quando questa opzione è abilitata, la codifica del set di caratteri viene ipotizzata all'apertura dei file", - "eol": "Carattere di fine riga predefinito.", "trimTrailingWhitespace": "Se è abilitato, taglierà lo spazio vuoto quando si salva un file.", "insertFinalNewline": "Se è abilitato, inserisce un carattere di nuova riga finale alla fine del file durante il salvataggio.", "files.autoSave.off": "Un file dirty non viene mai salvato automaticamente.", diff --git a/i18n/ita/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/ita/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index 18ae03ff77a..158ed123e7a 100644 --- a/i18n/ita/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -5,5 +5,9 @@ // Do not edit this file. It is machine generated. { "slow": "È stato rilevato un rallentamento all'avvio", - "slow.detail": "È stato appena rilevato un rallentamento all'avvio. Per consentire a Microsoft di analizzare e risolvere il problema, riavviare '{0}' con la profilatura abilitata e condividere i profili." + "slow.detail": "È stato appena rilevato un rallentamento all'avvio. Per consentire a Microsoft di analizzare e risolvere il problema, riavviare '{0}' con la profilatura abilitata e condividere i profili.", + "prof.message": "I profili sono stati creati.", + "prof.detail": "Creare un problema e allegare manualmente i file seguenti:\n{0}", + "prof.restartAndFileIssue": "Crea problema e riavvia", + "prof.restart": "Riavvia" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/ita/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index d2d18b208df..01f19048853 100644 --- a/i18n/ita/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -5,6 +5,11 @@ // Do not edit this file. It is machine generated. { "welcomePage": "Benvenuti", + "welcomePage.typeScript": "TypeScript", + "welcomePage.php": "PHP", + "welcomePage.vim": "Vim", + "welcomePage.sublime": "Sublime", + "welcomePage.atom": "Atom", "welcomePage.keymapAlreadyInstalled": "I tasti di scelta rapida di {0} sono già installati.", "welcomePage.willReloadAfterInstallingKeymap": "La finestra verrà ricaricata dopo l'installazione dei tasti di scelta rapida di {0}.", "welcomePage.installingKeymap": "Installazione dei tasti di scelta rapida di {0}...", diff --git a/i18n/jpn/extensions/jake/out/main.i18n.json b/i18n/jpn/extensions/jake/out/main.i18n.json index 8b6ad71cd4e..0f77342ecbc 100644 --- a/i18n/jpn/extensions/jake/out/main.i18n.json +++ b/i18n/jpn/extensions/jake/out/main.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "execFailed": "Jake ã®ã‚¨ãƒ©ãƒ¼ã«ã‚ˆã‚‹å¤±æ•—を自動検出: {0}" +} \ No newline at end of file diff --git a/i18n/jpn/extensions/jake/package.i18n.json b/i18n/jpn/extensions/jake/package.i18n.json index 8b6ad71cd4e..def0eab1b4c 100644 --- a/i18n/jpn/extensions/jake/package.i18n.json +++ b/i18n/jpn/extensions/jake/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.jake.autoDetect": "Jake タスクã®è‡ªå‹•æ¤œå‡ºã‚’オンã«ã™ã‚‹ã‹ã‚ªãƒ•ã«ã™ã‚‹ã‹ã‚’制御ã—ã¾ã™ã€‚既定ã¯ã‚ªãƒ³ã§ã™ã€‚" +} \ No newline at end of file diff --git a/i18n/jpn/extensions/markdown/out/extension.i18n.json b/i18n/jpn/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/jpn/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/jpn/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/jpn/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/jpn/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/jpn/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/jpn/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/jpn/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/jpn/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/jpn/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/jpn/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/jpn/extensions/merge-conflict/package.i18n.json b/i18n/jpn/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/jpn/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/jpn/extensions/npm/package.i18n.json b/i18n/jpn/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/jpn/extensions/npm/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/jpn/extensions/typescript/package.i18n.json b/i18n/jpn/extensions/typescript/package.i18n.json index e30965564d0..d3f776eaa11 100644 --- a/i18n/jpn/extensions/typescript/package.i18n.json +++ b/i18n/jpn/extensions/typescript/package.i18n.json @@ -33,10 +33,13 @@ "javascript.validate.enable": "JavaScript ã®æ¤œè¨¼ã‚’有効/無効ã«ã—ã¾ã™ã€‚", "typescript.goToProjectConfig.title": "プロジェクト構æˆã«ç§»å‹•", "javascript.goToProjectConfig.title": "プロジェクト構æˆã«ç§»å‹•", + "javascript.referencesCodeLens.enabled": "JavaScript ファイル内㧠CodeLens ã®å‚照を有効/無効ã«ã—ã¾ã™ã€‚", + "typescript.referencesCodeLens.enabled": "TypeScript ファイル内㧠CodeLens ã®å‚照を有効/無効ã«ã—ã¾ã™ã€‚TypeScript 2.0.6 以上ãŒå¿…è¦ã§ã™ã€‚", "typescript.implementationsCodeLens.enabled": "CodeLens ã®å®Ÿè£…を有効/無効ã«ã—ã¾ã™ã€‚TypeScript 2.2.0 以上ãŒå¿…è¦ã§ã™ã€‚", "typescript.openTsServerLog.title": "TS サーãƒãƒ¼ã®ãƒ­ã‚°ã‚’é–‹ã", "typescript.selectTypeScriptVersion.title": "TypeScript ã®ãƒãƒ¼ã‚¸ãƒ§ãƒ³ã®é¸æŠž", "jsDocCompletion.enabled": " 自動 JSDoc コメントを有効/無効ã«ã—ã¾ã™", "javascript.implicitProjectConfig.checkJs": "JavaScript ファイルã®ã‚»ãƒžãƒ³ãƒ†ã‚£ãƒƒã‚¯ ãƒã‚§ãƒƒã‚¯ã‚’有効/無効ã«ã—ã¾ã™ã€‚既存㮠jsconfi.json ã‚„ tsconfi.json ファイルã®è¨­å®šã¯ã“れより優先ã•ã‚Œã¾ã™ã€‚TypeScript 㯠2.3.1 以上ã§ã‚ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™ã€‚", - "typescript.check.npmIsInstalled": "型定義ã®è‡ªå‹•å–å¾—ã« NPM ãŒã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã¦ã„ã‚‹ã‹ã©ã†ã‹ã‚’確èªã™ã‚‹" + "typescript.check.npmIsInstalled": "型定義ã®è‡ªå‹•å–å¾—ã« NPM ãŒã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã¦ã„ã‚‹ã‹ã©ã†ã‹ã‚’確èªã™ã‚‹", + "javascript.nameSuggestions": "JavaScript ã®å€™è£œãƒªã‚¹ãƒˆå†…ã§ãƒ•ã‚¡ã‚¤ãƒ«ã‹ã‚‰ä¸€æ„ã®åå‰ã‚’å«ã‚€ã‹ã©ã†ã‹ã‚’有効/無効ã«ã—ã¾ã™ã€‚" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/jpn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index ea2e47d9813..e70844baf7b 100644 --- a/i18n/jpn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/jpn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,8 +6,6 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "イメージãŒå¤§ãã™ãŽã¦ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã«è¡¨ç¤ºã§ãã¾ã›ã‚“。", - "resourceOpenExternalButton": "イメージを開ã", - "resourceOpenExternalText": " 外部プログラムを使用ã—ã¦ã„ã¾ã™ã‹?", "nativeBinaryError": "ã“ã®ãƒ•ã‚¡ã‚¤ãƒ«ã¯ãƒã‚¤ãƒŠãƒªã‹ã€éžå¸¸ã«å¤§ãã„ã‹ã€ã¾ãŸã¯ã‚µãƒãƒ¼ãƒˆã•ã‚Œã¦ã„ãªã„テキスト エンコードを使用ã—ã¦ã„ã‚‹ãŸã‚ã€ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã«è¡¨ç¤ºã•ã‚Œã¾ã›ã‚“。", "sizeB": "{0}B", "sizeKB": "{0}KB", diff --git a/i18n/jpn/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/jpn/src/vs/editor/common/config/commonEditorConfig.i18n.json index da6b50dacf0..8ce8d297e00 100644 --- a/i18n/jpn/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/jpn/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -41,7 +41,6 @@ "formatOnType": "エディターã§å…¥åŠ›å¾Œã«è‡ªå‹•çš„ã«è¡Œã®æ›¸å¼è¨­å®šã‚’è¡Œã†ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™", "formatOnPaste": "貼り付ã‘ãŸå†…容ãŒã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã«ã‚ˆã‚Šè‡ªå‹•çš„ã«ãƒ•ã‚©ãƒ¼ãƒžãƒƒãƒˆã•ã‚Œã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚フォーマッタを使用å¯èƒ½ã«ã™ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™ã€‚ã¾ãŸã€ãƒ•ã‚©ãƒ¼ãƒžãƒƒã‚¿ãŒãƒ‰ã‚­ãƒ¥ãƒ¡ãƒ³ãƒˆå†…ã®ç¯„囲をフォーマットã§ããªã‘ã‚Œã°ãªã‚Šã¾ã›ã‚“。", "suggestOnTriggerCharacters": "トリガー文字ã®å…¥åŠ›æ™‚ã«å€™è£œãŒè‡ªå‹•çš„ã«è¡¨ç¤ºã•ã‚Œã‚‹ã‚ˆã†ã«ã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™", - "acceptSuggestionOnEnter": "'Tab' キーã«åŠ ãˆã¦ 'Enter' キーã§å€™è£œã‚’å—ã‘入れるã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚改行ã®æŒ¿å…¥ã‚„候補ã®å映ã®é–“ã§ã‚ã„ã¾ã„ã•ã‚’解消ã™ã‚‹ã®ã«å½¹ç«‹ã¡ã¾ã™ã€‚", "acceptSuggestionOnCommitCharacter": "コミット文字ã§å€™è£œã‚’å—ã‘入れるã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚ãŸã¨ãˆã°ã€JavaScript ã§ã¯ã‚»ãƒŸã‚³ãƒ­ãƒ³ (';') をコミット文字ã«ã—ã¦ã€å€™è£œã‚’å—ã‘入れã¦ãã®æ–‡å­—を入力ã™ã‚‹ã“ã¨ãŒã§ãã¾ã™ã€‚", "snippetSuggestions": "ä»–ã®ä¿®æ­£å€™è£œã¨ä¸€ç·’ã«ã‚¹ãƒ‹ãƒšãƒƒãƒˆã‚’表示ã™ã‚‹ã‹ã©ã†ã‹ã€ãŠã‚ˆã³ãã®ä¸¦ã³æ›¿ãˆã®æ–¹æ³•ã‚’制御ã—ã¾ã™ã€‚", "emptySelectionClipboard": "é¸æŠžç¯„囲を指定ã—ãªã„ã§ã‚³ãƒ”ーã™ã‚‹å ´åˆã«ç¾åœ¨ã®è¡Œã‚’コピーã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚", @@ -63,6 +62,7 @@ "renderLineHighlight": "エディターãŒç¾åœ¨ã®è¡Œã‚’ã©ã®ã‚ˆã†ã«å¼·èª¿è¡¨ç¤ºã™ã‚‹ã‹ã‚’制御ã—ã¾ã™ã€‚考ãˆã‚‰ã‚Œã‚‹å€¤ã¯ 'none'ã€'gutter'ã€'line'ã€'all' ã§ã™ã€‚", "codeLens": "エディター㧠CodeLens を表示ã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã™ã‚‹", "folding": "エディターã§ã‚³ãƒ¼ãƒ‰ã®æŠ˜ã‚ŠãŸãŸã¿ã‚’有効ã«ã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™", + "showFoldingControls": "余白上ã®æŠ˜ã‚ŠãŸãŸã¿ã‚³ãƒ³ãƒˆãƒ­ãƒ¼ãƒ«ã‚’自動的ã«éžè¡¨ç¤ºã«ã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ 。", "matchBrackets": "ã‹ã£ã“ã‚’é¸æŠžã™ã‚‹ã¨ã€å¯¾å¿œã™ã‚‹ã‹ã£ã“を強調表示ã—ã¾ã™ã€‚", "glyphMargin": "エディターã§ç¸¦ã®ã‚°ãƒªãƒ•ä½™ç™½ãŒè¡¨ç¤ºã•ã‚Œã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚ã»ã¨ã‚“ã©ã®å ´åˆã€ã‚°ãƒªãƒ•ä½™ç™½ã¯ãƒ‡ãƒãƒƒã‚°ã«ä½¿ç”¨ã•ã‚Œã¾ã™ã€‚", "useTabStops": "空白ã®æŒ¿å…¥ã‚„削除ã¯ã‚¿ãƒ–ä½ç½®ã«å¾“ã£ã¦è¡Œã‚ã‚Œã¾ã™", diff --git a/i18n/jpn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/jpn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..624f9b7af70 --- /dev/null +++ b/i18n/jpn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "'{0}' ã®å®šç¾©ã¯è¦‹ã¤ã‹ã‚Šã¾ã›ã‚“", + "generic.noResults": "定義ãŒè¦‹ã¤ã‹ã‚Šã¾ã›ã‚“", + "meta.title": " – {0} 個ã®å®šç¾©", + "actions.goToDecl.label": "定義ã¸ç§»å‹•", + "actions.goToDeclToSide.label": "定義を横ã«é–‹ã", + "actions.previewDecl.label": "定義をã“ã“ã«è¡¨ç¤º", + "goToImplementation.noResultWord": "'{0}' ã®å®Ÿè£…ãŒè¦‹ã¤ã‹ã‚Šã¾ã›ã‚“", + "goToImplementation.generic.noResults": "実装ãŒè¦‹ã¤ã‹ã‚Šã¾ã›ã‚“", + "meta.implementations.title": "– {0} 個ã®å®Ÿè£…", + "actions.goToImplementation.label": "実装ã«ç§»å‹•", + "actions.peekImplementation.label": "実装ã®ãƒ—レビュー", + "goToTypeDefinition.noResultWord": "'{0}' ã®åž‹å®šç¾©ãŒè¦‹ã¤ã‹ã‚Šã¾ã›ã‚“", + "goToTypeDefinition.generic.noResults": "型定義ãŒè¦‹ã¤ã‹ã‚Šã¾ã›ã‚“", + "meta.typeDefinitions.title": " – {0} 個ã®åž‹å®šç¾©", + "actions.goToTypeDefinition.label": "型定義ã¸ç§»å‹•", + "actions.peekTypeDefinition.label": "型定義を表示" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/jpn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..f918ba9f96d --- /dev/null +++ b/i18n/jpn/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "クリックã—ã¦ã€{0} ã®å®šç¾©ã‚’表示ã—ã¾ã™ã€‚" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json b/i18n/jpn/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json index b5c107a4338..65e2583d291 100644 --- a/i18n/jpn/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json +++ b/i18n/jpn/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json @@ -12,6 +12,7 @@ "readMore": "詳細を表示...{0}", "suggestionWithDetailsAriaLabel": "{0}ã€å€™è£œã€è©³ç´°ã‚ã‚Š", "suggestionAriaLabel": "{0}ã€å€™è£œ", + "readLess": "詳細を隠ã™...{0}", "suggestWidget.loading": "読ã¿è¾¼ã‚“ã§ã„ã¾ã™...", "suggestWidget.noSuggestions": "候補ã¯ã‚ã‚Šã¾ã›ã‚“。", "suggestionAriaAccepted": "{0}ã€å—ã‘入れ済ã¿", diff --git a/i18n/jpn/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json b/i18n/jpn/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json index 991783c6602..7f3e60f73e4 100644 --- a/i18n/jpn/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json +++ b/i18n/jpn/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json @@ -16,6 +16,7 @@ "schema.autoClosingPairs": "角ã‹ã£ã“ã®ãƒšã‚¢ã‚’定義ã—ã¾ã™ã€‚左角ã‹ã£ã“ãŒå…¥åŠ›ã•ã‚Œã‚‹ã¨ã€å³è§’ã‹ã£ã“ãŒè‡ªå‹•çš„ã«æŒ¿å…¥ã•ã‚Œã¾ã™ã€‚", "schema.autoClosingPairs.notIn": "自動ペアãŒç„¡åŠ¹ãªã‚¹ã‚³ãƒ¼ãƒ—ã®ä¸€è¦§ã‚’定義ã—ã¾ã™ã€‚", "schema.surroundingPairs": "é¸æŠžæ–‡å­—列を囲むã¨ãã«ä½¿ç”¨ã§ãる角ã‹ã£ã“ã®ãƒšã‚¢ã‚’定義ã—ã¾ã™ã€‚", + "schema.wordPattern": "言語ã®ãŸã‚ã®å˜èªžã®å®šç¾©ã€‚", "schema.wordPattern.pattern": "言葉ã®ç…§åˆã«ä½¿ç”¨ã™ã‚‹æ­£è¦è¡¨ç¾ãƒ‘ターン。", "schema.wordPattern.flags": "言葉ã®ç…§åˆã«ä½¿ç”¨ã™ã‚‹æ­£è¦è¡¨ç¾ãƒ•ãƒ©ã‚°ã€‚", "schema.wordPattern.flags.errorMessage": "`/^([gimuy]+)$/` パターンã«ä¸€è‡´ã™ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™ã€‚" diff --git a/i18n/jpn/src/vs/platform/markers/common/problemMatcher.i18n.json b/i18n/jpn/src/vs/platform/markers/common/problemMatcher.i18n.json index 2bbfe1d0b1d..df4f3d19acd 100644 --- a/i18n/jpn/src/vs/platform/markers/common/problemMatcher.i18n.json +++ b/i18n/jpn/src/vs/platform/markers/common/problemMatcher.i18n.json @@ -34,6 +34,7 @@ "ProblemMatcherParser.noValidIdentifier": "エラー: パターン プロパティ {0} ã¯æœ‰åŠ¹ãªãƒ‘ターン変数åã§ã¯ã‚ã‚Šã¾ã›ã‚“。", "ProblemMatcherParser.problemPattern.watchingMatcher": "å•é¡Œãƒžãƒƒãƒãƒ£ãƒ¼ã¯ã€ã‚¦ã‚©ãƒƒãƒå¯¾è±¡ã®é–‹å§‹ãƒ‘ターンã¨çµ‚了パターンã®ä¸¡æ–¹ã‚’定義ã™ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™ã€‚", "ProblemMatcherParser.invalidRegexp": "エラー: 文字列 {0} ã¯ã€æœ‰åŠ¹ãªæ­£è¦è¡¨ç¾ã§ã¯ã‚ã‚Šã¾ã›ã‚“。\n", + "WatchingPatternSchema.regexp": "ãƒãƒƒã‚¯ã‚°ãƒ©ã‚¦ãƒ³ãƒ‰ タスクã®é–‹å§‹ã¾ãŸã¯çµ‚了を検出ã™ã‚‹æ­£è¦è¡¨ç¾ã€‚", "WatchingPatternSchema.file": "ファイルåã®ä¸€è‡´ã‚°ãƒ«ãƒ¼ãƒ— インデックス。çœç•¥ã§ãã¾ã™ã€‚", "PatternTypeSchema.name": "æä¾›ã•ã‚ŒãŸã‹äº‹å‰å®šç¾©ã•ã‚ŒãŸå•é¡Œãƒ‘ターンã®åå‰", "PatternTypeSchema.description": "A problem pattern or the name of a contributed or predefined problem pattern. Can be omitted if base is specified.", @@ -42,6 +43,12 @@ "ProblemMatcherSchema.severity": "キャプãƒãƒ£ã•ã‚ŒãŸå•é¡Œã®æ—¢å®šã®é‡å¤§åº¦ã€‚パターンãŒé‡è¦åº¦ã®ä¸€è‡´ã‚°ãƒ«ãƒ¼ãƒ—を定義ã—ã¦ã„ãªã„å ´åˆã«ä½¿ç”¨ã•ã‚Œã¾ã™ã€‚", "ProblemMatcherSchema.applyTo": "テキスト ドキュメントã§å ±å‘Šã•ã‚ŒãŸå•é¡ŒãŒã€é–‹ã„ã¦ã„るドキュメントã®ã¿ã€é–‰ã˜ã‚‰ã‚ŒãŸãƒ‰ã‚­ãƒ¥ãƒ¡ãƒ³ãƒˆã®ã¿ã€ã™ã¹ã¦ã®ãƒ‰ã‚­ãƒ¥ãƒ¡ãƒ³ãƒˆã®ã„ãšã‚Œã«é©ç”¨ã•ã‚Œã‚‹ã‹ã‚’制御ã—ã¾ã™ã€‚", "ProblemMatcherSchema.fileLocation": "å•é¡Œãƒ‘ターンã§å ±å‘Šã•ã‚ŒãŸãƒ•ã‚¡ã‚¤ãƒ«åを解釈ã™ã‚‹æ–¹æ³•ã‚’定義ã—ã¾ã™ã€‚", + "ProblemMatcherSchema.background": "ãƒãƒƒã‚¯ã‚°ãƒ©ã‚¦ãƒ³ãƒ‰ タスクã§ã‚¢ã‚¯ãƒ†ã‚£ãƒ–ãªãƒžãƒƒãƒãƒ£ãƒ¼ã®é–‹å§‹ã¨çµ‚了を追跡ã™ã‚‹ãƒ‘ターン。", + "ProblemMatcherSchema.background.activeOnStart": "true ã«è¨­å®šã™ã‚‹ã¨ã€ã‚¿ã‚¹ã‚¯ã®é–‹å§‹æ™‚ã«ãƒãƒƒã‚¯ã‚°ãƒ©ã‚¦ãƒ³ãƒ‰ モニターãŒã‚¢ã‚¯ãƒ†ã‚£ãƒ– モードã«ãªã‚Šã¾ã™ã€‚ã“れ㯠beginPattern ã¨ä¸€è‡´ã™ã‚‹è¡Œã®ç™ºè¡Œã¨åŒç­‰ã§ã™ã€‚", + "ProblemMatcherSchema.background.beginsPattern": "出力内ã§ä¸€è‡´ã™ã‚‹ã¨ã€ãƒãƒƒã‚¯ã‚°ãƒ©ã‚¦ãƒ³ãƒ‰ タスクã®é–‹å§‹ãŒé€šçŸ¥ã•ã‚Œã¾ã™ã€‚", + "ProblemMatcherSchema.background.endsPattern": "出力内ã§ä¸€è‡´ã™ã‚‹ã¨ã€ãƒãƒƒã‚¯ã‚°ãƒ©ã‚¦ãƒ³ãƒ‰ タスクã®çµ‚了ãŒé€šçŸ¥ã•ã‚Œã¾ã™ã€‚", + "ProblemMatcherSchema.watching.deprecated": "watching プロパティã¯ä½¿ç”¨ã•ã‚Œãªããªã‚Šã¾ã—ãŸã€‚代ã‚ã‚Šã« background ã‚’ã”使用ãã ã•ã„。", + "ProblemMatcherSchema.watching": "監視パターンã®é–‹å§‹ã¨çµ‚了を追跡ã™ã‚‹ãƒžãƒƒãƒãƒ£ãƒ¼ã€‚", "ProblemMatcherSchema.watching.activeOnStart": "true ã«è¨­å®šã™ã‚‹ã¨ã€ã‚¿ã‚¹ã‚¯ã®é–‹å§‹æ™‚ã«ã‚¦ã‚©ãƒƒãƒãƒ£ãƒ¼ãŒã‚¢ã‚¯ãƒ†ã‚£ãƒ– モードã«ãªã‚Šã¾ã™ã€‚ã“れ㯠beginPattern ã¨ä¸€è‡´ã™ã‚‹è¡Œã®ç™ºè¡Œã¨åŒç­‰ã§ã™ã€‚", "ProblemMatcherSchema.watching.beginsPattern": "出力内ã§ä¸€è‡´ã™ã‚‹ã¨ã€ã‚¦ã‚©ãƒƒãƒä¸­ã®ã‚¿ã‚¹ã‚¯ã®é–‹å§‹ãŒé€šçŸ¥ã•ã‚Œã¾ã™ã€‚", "ProblemMatcherSchema.watching.endsPattern": "出力内ã§ä¸€è‡´ã™ã‚‹ã¨ã€ã‚¦ã‚©ãƒƒãƒä¸­ã®ã‚¿ã‚¹ã‚¯ã®çµ‚了ãŒé€šçŸ¥ã•ã‚Œã¾ã™ã€‚", diff --git a/i18n/jpn/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/jpn/src/vs/platform/theme/common/colorRegistry.i18n.json index 8da89f6115c..9872f49057d 100644 --- a/i18n/jpn/src/vs/platform/theme/common/colorRegistry.i18n.json +++ b/i18n/jpn/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -60,6 +60,7 @@ "editorBackground": "エディターã®èƒŒæ™¯è‰²ã€‚", "editorForeground": "エディターã®æ—¢å®šã®å‰æ™¯è‰²ã€‚", "editorWidgetBackground": "検索/ç½®æ›çª“ãªã©ã€ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ ウィジェットã®èƒŒæ™¯è‰²ã€‚", + "editorWidgetBorder": "エディター ウィジェットã®å¢ƒç•Œç·šã®è‰²ã€‚", "editorSelection": "エディターã®é¸æŠžç¯„囲ã®è‰²ã€‚", "editorInactiveSelection": "éžã‚¢ã‚¯ãƒ†ã‚£ãƒ–ãªã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã®é¸æŠžç¯„囲ã®è‰²ã€‚", "editorSelectionHighlight": "é¸æŠžç¯„囲ã¨åŒã˜ã‚³ãƒ³ãƒ†ãƒ³ãƒ„ã®é ˜åŸŸã®è‰²ã€‚", diff --git a/i18n/jpn/src/vs/workbench/api/node/extHostTreeViews.i18n.json b/i18n/jpn/src/vs/workbench/api/node/extHostTreeViews.i18n.json index 8b6ad71cd4e..74c5f0eabd7 100644 --- a/i18n/jpn/src/vs/workbench/api/node/extHostTreeViews.i18n.json +++ b/i18n/jpn/src/vs/workbench/api/node/extHostTreeViews.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "treeView.notRegistered": "ID '{0}' ã®ãƒ„リー ビューã¯ç™»éŒ²ã•ã‚Œã¦ã„ã¾ã›ã‚“。", + "treeItem.notFound": "ID '{0}' ã®ãƒ„リー項目ã¯è¦‹ã¤ã‹ã‚Šã¾ã›ã‚“ã§ã—ãŸã€‚", + "treeView.duplicateElement": " {0} è¦ç´ ã¯æ—¢ã«ç™»éŒ²ã•ã‚Œã¦ã„ã¾ã™ã€‚" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/common/theme.i18n.json b/i18n/jpn/src/vs/workbench/common/theme.i18n.json index b361c556bdc..d183c267924 100644 --- a/i18n/jpn/src/vs/workbench/common/theme.i18n.json +++ b/i18n/jpn/src/vs/workbench/common/theme.i18n.json @@ -32,6 +32,7 @@ "activityBarBadgeBackground": "アクティビティ通知ãƒãƒƒã‚¸ã®èƒŒæ™¯è‰²ã€‚アクティビティ ãƒãƒ¼ã¯å·¦ç«¯ã¾ãŸã¯å³ç«¯ã«è¡¨ç¤ºã•ã‚Œã€ã‚µã‚¤ãƒ‰ ãƒãƒ¼ã®è¡¨ç¤ºã‚’切り替ãˆã‚‹ã“ã¨ãŒã§ãã¾ã™ã€‚", "activityBarBadgeForeground": "アクティビティ通知ãƒãƒƒã‚¸ã®å‰æ™¯è‰²ã€‚アクティビティ ãƒãƒ¼ã¯å·¦ç«¯ã¾ãŸã¯å³ç«¯ã«è¡¨ç¤ºã•ã‚Œã€ã‚µã‚¤ãƒ‰ ãƒãƒ¼ã®è¡¨ç¤ºã‚’切り替ãˆã‚‹ã“ã¨ãŒã§ãã¾ã™ã€‚", "sideBarBackground": "サイド ãƒãƒ¼ã®èƒŒæ™¯è‰²ã€‚サイド ãƒãƒ¼ã¯ã€ã‚¨ã‚¯ã‚¹ãƒ—ローラーや検索ãªã©ã®ãƒ“ューãŒå…¥ã‚‹ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", + "sideBarForeground": "サイド ãƒãƒ¼ã®å‰æ™¯è‰²ã€‚サイド ãƒãƒ¼ã¯ã€ã‚¨ã‚¯ã‚¹ãƒ—ローラーや検索ãªã©ã®ãƒ“ューãŒå…¥ã‚‹ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", "sideBarTitleForeground": "サイド ãƒãƒ¼ã®ã‚¿ã‚¤ãƒˆãƒ«ã®å‰æ™¯è‰²ã€‚サイド ãƒãƒ¼ã¯ã€ã‚¨ã‚¯ã‚¹ãƒ—ローラーや検索ãªã©ã®ãƒ“ューãŒå…¥ã‚‹ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", "sideBarSectionHeaderBackground": "サイド ãƒãƒ¼ã®ã‚»ã‚¯ã‚·ãƒ§ãƒ³ ヘッダーã®èƒŒæ™¯è‰²ã€‚サイド ãƒãƒ¼ã¯ã€ã‚¨ã‚¯ã‚¹ãƒ—ローラーや検索ãªã©ã®ãƒ“ューãŒå…¥ã‚‹ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", "titleBarActiveForeground": "ウィンドウãŒã‚¢ã‚¯ãƒ†ã‚£ãƒ–ãªå ´åˆã®ã‚¿ã‚¤ãƒˆãƒ« ãƒãƒ¼ã®å‰æ™¯ã€‚ç¾åœ¨ã€ã“ã®è‰²ã¯ macOS ã§ã®ã¿ã‚µãƒãƒ¼ãƒˆã•ã‚Œã¦ã„ã‚‹ã®ã§ã”注æ„ãã ã•ã„。", diff --git a/i18n/jpn/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/jpn/src/vs/workbench/electron-browser/main.contribution.i18n.json index e69cb0fb627..d813d5f6c23 100644 --- a/i18n/jpn/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/jpn/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -7,6 +7,7 @@ "view": "表示", "help": "ヘルプ", "file": "ファイル", + "developer": "開発者", "showEditorTabs": "é–‹ã„ã¦ã„るエディターをタブã«è¡¨ç¤ºã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚", "editorTabCloseButton": "エディター タブã®é–‰ã˜ã‚‹ãƒœã‚¿ãƒ³ã®ä½ç½®ã‚’制御ã™ã‚‹ã‹ã€[off] ã«è¨­å®šã—ãŸå ´åˆã«ç„¡åŠ¹ã«ã—ã¾ã™ã€‚", "showIcons": "é–‹ã„ã¦ã„るエディターをアイコンã§è¡¨ç¤ºã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚ã“ã‚Œã«ã¯ã€ã‚¢ã‚¤ã‚³ãƒ³ã®ãƒ†ãƒ¼ãƒžã‚’有効ã«ã™ã‚‹å¿…è¦ã‚‚ã‚ã‚Šã¾ã™ã€‚", diff --git a/i18n/jpn/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json b/i18n/jpn/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json index e57fd60ee0d..8943a8809bd 100644 --- a/i18n/jpn/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json @@ -6,5 +6,6 @@ { "copyValue": "値ã®ã‚³ãƒ”ー", "copy": "コピー", + "copyAll": "ã™ã¹ã¦ã‚³ãƒ”ー", "copyStackTrace": "呼ã³å‡ºã—履歴ã®ã‚³ãƒ”ー" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json b/i18n/jpn/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json index af68e40b4ae..d63fe387f50 100644 --- a/i18n/jpn/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json @@ -7,6 +7,7 @@ "debugAdapterBinNotFound": "デãƒãƒƒã‚° アダプターã®å®Ÿè¡Œå¯èƒ½ãƒ•ã‚¡ã‚¤ãƒ« '{0}' ãŒã‚ã‚Šã¾ã›ã‚“。", "debugAdapterCannotDetermineExecutable": "デãƒãƒƒã‚° アダプター '{0}' ã®å®Ÿè¡Œå¯èƒ½ãƒ•ã‚¡ã‚¤ãƒ«ã‚’判別ã§ãã¾ã›ã‚“。", "debugType": "構æˆã®ç¨®é¡žã€‚", + "debugTypeNotRecognised": "デãƒãƒƒã‚°ã®ç¨®é¡žã¯èªè­˜ã•ã‚Œã¾ã›ã‚“ã§ã—ãŸã€‚対応ã™ã‚‹ãƒ‡ãƒãƒƒã‚°ã®æ‹¡å¼µæ©Ÿèƒ½ãŒã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã¦ãŠã‚Šã€æœ‰åŠ¹ã«ãªã£ã¦ã„ã‚‹ã“ã¨ã‚’確èªã—ã¦ãã ã•ã„。", "node2NotSupported": "\"node2\" ã¯ã‚µãƒãƒ¼ãƒˆã•ã‚Œã¦ã„ã¾ã›ã‚“。代ã‚ã‚Šã« \"node\" を使用ã—ã€\"protocol\" 属性を \"inspector\" ã«è¨­å®šã—ã¦ãã ã•ã„。", "debugName": "構æˆã®åå‰ã€‚起動構æˆã®ãƒ‰ãƒ­ãƒƒãƒ—ダウン メニューã«è¡¨ç¤ºã•ã‚Œã¾ã™ã€‚", "debugRequest": "構æˆã®è¦æ±‚ã®ç¨®é¡žã€‚\"launch\" ã¾ãŸã¯ \"attach\" ã§ã™ã€‚", diff --git a/i18n/jpn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/jpn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 8b6ad71cd4e..e5b2af33ec3 100644 --- a/i18n/jpn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "disableOtherKeymapsConfirmation": "キーãƒã‚¤ãƒ³ãƒ‰é–“ã®ç«¶åˆã‚’回é¿ã™ã‚‹ãŸã‚ã«ã€ä»–ã®ã‚­ãƒ¼ãƒžãƒƒãƒ—を無効ã«ã—ã¾ã™ã‹?", + "yes": "ã¯ã„", + "no": "ã„ã„ãˆ" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/jpn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 15c3aee15db..9356fa119aa 100644 --- a/i18n/jpn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,7 +16,6 @@ "associations": "言語ã«å¯¾ã™ã‚‹ãƒ•ã‚¡ã‚¤ãƒ«ã®é–¢é€£ä»˜ã‘ (例 \"*.extension\": \"html\") を構æˆã—ã¾ã™ã€‚ã“れらã®é–¢é€£ä»˜ã‘ã¯ã€ã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã¦ã„る言語ã®æ—¢å®šã®é–¢é€£ä»˜ã‘より優先ã•ã‚Œã¾ã™ã€‚", "encoding": "ファイルã®èª­ã¿å–ã‚Š/書ãè¾¼ã¿ã§ä½¿ç”¨ã™ã‚‹æ—¢å®šã®æ–‡å­—セット エンコーディング。", "autoGuessEncoding": "有効ãªå ´åˆã€ãƒ•ã‚¡ã‚¤ãƒ«ã‚’é–‹ãã¨ãã«æ–‡å­—セット エンコードを推測ã—ã¾ã™", - "eol": "既定ã®æ”¹è¡Œæ–‡å­—。", "trimTrailingWhitespace": "有効ã«ã™ã‚‹ã¨ã€ãƒ•ã‚¡ã‚¤ãƒ«ã®ä¿å­˜æ™‚ã«æœ«å°¾ã®ç©ºç™½ã‚’トリミングã—ã¾ã™ã€‚", "insertFinalNewline": "有効ã«ã™ã‚‹ã¨ã€ãƒ•ã‚¡ã‚¤ãƒ«ã®ä¿å­˜æ™‚ã«æœ€æ–°ã®è¡Œã‚’末尾ã«æŒ¿å…¥ã—ã¾ã™ã€‚", "files.autoSave.off": "ダーティ ファイルを自動的ã«ä¿å­˜ã™ã‚‹ã“ã¨ã¯ã—ã¾ã›ã‚“。", @@ -27,6 +26,8 @@ "autoSaveDelay": "ダーティ ファイルã®è‡ªå‹•ä¿å­˜ã®é…延をミリ秒å˜ä½ã§åˆ¶å¾¡ã—ã¾ã™ã€‚'files.autoSave' ㌠'{0}' ã«è¨­å®šã•ã‚Œã¦ã„ã‚‹å ´åˆã®ã¿é©ç”¨ã•ã‚Œã¾ã™", "watcherExclude": "ファイル モニタリングã‹ã‚‰é™¤å¤–ã™ã‚‹ãƒ•ã‚¡ã‚¤ãƒ« パス㮠glob パターンを構æˆã—ã¾ã™ã€‚ã“ã®è¨­å®šã‚’変更ã™ã‚‹ã¨ã€å†èµ·å‹•ãŒå¿…è¦ã«ãªã‚Šã¾ã™ã€‚始動時㫠Code ãŒæ¶ˆè²»ã™ã‚‹ CPU 時間ãŒå¤šã„å ´åˆã¯ã€å¤§è¦æ¨¡ãªãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã‚’除外ã—ã¦åˆæœŸãƒ­ãƒ¼ãƒ‰ã‚’減らã›ã¾ã™ã€‚", "hotExit.off": "Hot Exit を無効ã«ã—ã¾ã™ã€‚", + "hotExit.onExit": "アプリケーションãŒé–‰ã˜ã‚‹ã¨ (Windows/Linux ã§æœ€å¾Œã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ãŒé–‰ã˜ã‚‹ã¨ãã€ã¾ãŸã¯ workbench.action.quit コマンドãŒãƒˆãƒªã‚¬ãƒ¼ã•ã‚Œã‚‹ã¨ã (コマンド パレットã€ã‚­ãƒ¼ ãƒã‚¤ãƒ³ãƒ‰ã€ãƒ¡ãƒ‹ãƒ¥ãƒ¼))ã€Hot Exit ãŒãƒˆãƒªã‚¬ãƒ¼ã•ã‚Œã¾ã™ã€‚ãƒãƒƒã‚¯ã‚¢ãƒƒãƒ—ã•ã‚Œã¦ã„ã‚‹ã™ã¹ã¦ã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã¯ã€æ¬¡ã®èµ·å‹•æ™‚ã«å¾©å…ƒã•ã‚Œã¾ã™ã€‚", + "hotExit.onExitAndWindowClose": "アプリケーションãŒé–‰ã˜ã‚‹ã¨ (Windows/Linux ã§æœ€å¾Œã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ãŒé–‰ã˜ã‚‹ã¨ãã€ã¾ãŸã¯ workbench.action.quit コマンドãŒãƒˆãƒªã‚¬ãƒ¼ã™ã‚‹ã¨ã (コマンド パレットã€ã‚­ãƒ¼ ãƒã‚¤ãƒ³ãƒ‰ã€ãƒ¡ãƒ‹ãƒ¥ãƒ¼))ã€Hot Exit ãŒãƒˆãƒªã‚¬ãƒ¼ã•ã‚Œã¾ã™ã€‚ã¾ãŸã€ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ãŒé–‹ã‹ã‚Œã¦ã„るウィンドウã«ã¤ã„ã¦ã‚‚ã€ãã‚ŒãŒæœ€å¾Œã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã‹ã©ã†ã‹ã«é–¢ä¿‚ãªãã€Hot Exit ãŒãƒˆãƒªã‚¬ãƒ¼ã•ã‚Œã¾ã™ã€‚フォルダーãŒé–‹ã‹ã‚Œã¦ã„ãªã„ウィンドウã¯ã™ã¹ã¦ã€æ¬¡å›žã®èµ·å‹•æ™‚ã«å¾©å…ƒã•ã‚Œã¾ã™ã€‚フォルダーã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã‚’シャットダウンå‰ã¨åŒã˜çŠ¶æ…‹ã«å¾©å…ƒã™ã‚‹ã«ã¯ã€\"window.reopenFolders\" ã‚’ \"all\" ã«è¨­å®šã—ã¾ã™ã€‚", "hotExit": "エディターを終了ã™ã‚‹ã¨ãã«ä¿å­˜ã‚’確èªã™ã‚‹ãƒ€ã‚¤ã‚¢ãƒ­ã‚°ã‚’çœç•¥ã—ã€ä¿å­˜ã•ã‚Œã¦ã„ãªã„ファイルをセッション後もä¿æŒã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚", "defaultLanguage": "æ–°ã—ã„ファイルã«å‰²ã‚Šå½“ã¦ã‚‰ã‚Œã‚‹æ—¢å®šã®è¨€èªžãƒ¢ãƒ¼ãƒ‰ã€‚", "editorConfigurationTitle": "エディター", diff --git a/i18n/jpn/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/jpn/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index a71fcb6fc94..e14e57a90eb 100644 --- a/i18n/jpn/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -5,5 +5,11 @@ // Do not edit this file. It is machine generated. { "slow": "スタートアップã®é…延ãŒæ¤œå‡ºã•ã‚Œã¾ã—ãŸ", - "slow.detail": "スタートアップãŒé…ã‹ã£ãŸã¨ã®ã“ã¨ã€ç”³ã—訳ã”ã–ã„ã¾ã›ã‚“。プロファイルを有効ã«ã—ã¦ã€'{0}' ã‚’å†èµ·å‹•ã—ã€ãƒ—ロファイルを共有ã—ã¦ãã ã•ã„。スタートアップã®æ”¹å–„ã®ãŸã‚ã«å‚考ã«ã•ã›ã¦ã„ãŸã ãã¾ã™ã€‚" + "slow.detail": "スタートアップãŒé…ã‹ã£ãŸã¨ã®ã“ã¨ã€ç”³ã—訳ã”ã–ã„ã¾ã›ã‚“。プロファイルを有効ã«ã—ã¦ã€'{0}' ã‚’å†èµ·å‹•ã—ã€ãƒ—ロファイルを共有ã—ã¦ãã ã•ã„。スタートアップã®æ”¹å–„ã®ãŸã‚ã«å‚考ã«ã•ã›ã¦ã„ãŸã ãã¾ã™ã€‚", + "prof.message": "プロファイルãŒæ­£å¸¸ã«ä½œæˆã•ã‚Œã¾ã—ãŸã€‚", + "prof.detail": "案件を作æˆã—ã€æ‰‹å‹•ã§æ¬¡ã®ãƒ•ã‚¡ã‚¤ãƒ«ã‚’添付ã—ã¦ãã ã•ã„:\\n{0}", + "prof.restartAndFileIssue": "å•é¡Œã‚’作æˆã—ã¦å†èµ·å‹•", + "prof.restart": "å†èµ·å‹•", + "prof.thanks": "ã”å”力ã„ãŸã ãã€ã‚ã‚ŠãŒã¨ã†ã”ã–ã„ã¾ã™ã€‚", + "prof.detail.restart": "'{0}' を引ã続ã使用ã™ã‚‹ã«ã¯ã€æœ€å¾Œã®å†èµ·å‹•ãŒå¿…è¦ã§ã™ã€‚ 改ã‚ã¦ã‚ãªãŸã®è²¢çŒ®ã«æ„Ÿè¬ã—ã¾ã™ã€‚" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json b/i18n/jpn/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json index 0a35cdb1be9..dba4d278b14 100644 --- a/i18n/jpn/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json @@ -4,6 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "errorInvalidConfiguration": "設定を書ãè¾¼ã‚ã¾ã›ã‚“。ファイル内ã®ã‚¨ãƒ©ãƒ¼/警告を修正ã—ã¦ã‹ã‚‰ã‚‚ã†ä¸€åº¦ãŠè©¦ã—ãã ã•ã„。", "editTtile": "編集", "replaceDefaultValue": "設定を置æ›", "copyDefaultValue": "設定ã«ã‚³ãƒ”ー", diff --git a/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json b/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json index b650b0b0eb3..d45b8437459 100644 --- a/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "toggleGitViewlet": "Git を表示", + "installAdditionalSCMProviders": "ãã®ä»–ã® SCM プロãƒã‚¤ãƒ€ãƒ¼ã‚’インストール...", "source control": "ソース管ç†", "toggleSCMViewlet": "SCM を表示", "view": "表示" diff --git a/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json b/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json index d53de2c62b0..d93c7d2fb84 100644 --- a/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "installAdditionalSCMProviders": "ãã®ä»–ã® SCM プロãƒã‚¤ãƒ€ãƒ¼ã‚’インストール...", "switch provider": "SCM プロãƒã‚¤ãƒ€ãƒ¼ã®åˆ‡ã‚Šæ›¿ãˆ..." } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index c0432625724..f7db07a2e2d 100644 --- a/i18n/jpn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,5 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0}, tasks" + "entryAriaLabel": "{0}, tasks", + "workspace": "ワークスペースã‹ã‚‰", + "extension": "拡張機能ã‹ã‚‰" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json index 37bbf2ce2e0..1e77cbdffdf 100644 --- a/i18n/jpn/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json @@ -5,6 +5,6 @@ // Do not edit this file. It is machine generated. { "tasksAriaLabel": "å†é–‹ã™ã‚‹ã‚¿ã‚¹ã‚¯ã®åå‰ã‚’入力ã—ã¾ã™", - "noTasksMatching": "No tasks matching", + "noTasksMatching": "一致ã™ã‚‹ã‚¿ã‚¹ã‚¯ãŒã‚ã‚Šã¾ã›ã‚“", "noTasksFound": "å†é–‹ã™ã‚‹ã‚¿ã‚¹ã‚¯ã¯ã‚ã‚Šã¾ã›ã‚“" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json index 99543dd018a..5a397f34e03 100644 --- a/i18n/jpn/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json @@ -5,6 +5,6 @@ // Do not edit this file. It is machine generated. { "tasksAriaLabel": "実行ã™ã‚‹ã‚¿ã‚¹ã‚¯ã®åå‰ã‚’入力ã—ã¾ã™", - "noTasksMatching": "No tasks matching", + "noTasksMatching": "一致ã™ã‚‹ã‚¿ã‚¹ã‚¯ãŒã‚ã‚Šã¾ã›ã‚“", "noTasksFound": "タスクãŒè¦‹ã¤ã‹ã‚Šã¾ã›ã‚“" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json index 12b9c699bf2..440b92fd91d 100644 --- a/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json @@ -6,5 +6,6 @@ { "TerminalTaskSystem.unknownError": "タスクã®å®Ÿè¡Œä¸­ã«ä¸æ˜Žãªã‚¨ãƒ©ãƒ¼ãŒç™ºç”Ÿã—ã¾ã—ãŸã€‚詳細ã«ã¤ã„ã¦ã¯ã€ã‚¿ã‚¹ã‚¯å‡ºåŠ›ãƒ­ã‚°ã‚’å‚ç…§ã—ã¦ãã ã•ã„。", "TerminalTaskSystem.terminalName": "タスク - {0}", - "TerminalTaskSystem": "UNC ドライブã§ã‚·ã‚§ãƒ« コマンドを実行ã§ãã¾ã›ã‚“。" + "TerminalTaskSystem": "UNC ドライブã§ã‚·ã‚§ãƒ« コマンドを実行ã§ãã¾ã›ã‚“。", + "unkownProblemMatcher": "å•é¡Œãƒžãƒƒãƒãƒ£ãƒ¼ {0} ã¯è§£æ±ºã§ãã¾ã›ã‚“ã§ã—ãŸã€‚マッãƒãƒ£ãƒ¼ã¯ç„¡è¦–ã•ã‚Œã¾ã™" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json index 6f9be6076a6..0cc1f921982 100644 --- a/i18n/jpn/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json @@ -7,5 +7,6 @@ "TaskRunnerSystem.unknownError": "タスクã®å®Ÿè¡Œä¸­ã«ä¸æ˜Žãªã‚¨ãƒ©ãƒ¼ãŒç™ºç”Ÿã—ã¾ã—ãŸã€‚詳細ã«ã¤ã„ã¦ã¯ã€ã‚¿ã‚¹ã‚¯å‡ºåŠ›ãƒ­ã‚°ã‚’å‚ç…§ã—ã¦ãã ã•ã„。", "TaskRunnerSystem.watchingBuildTaskFinished": "\nビルド タスクã®ã‚¦ã‚©ãƒƒãƒãŒçµ‚了ã—ã¾ã—ãŸã€‚", "TaskRunnerSystem.childProcessError": "Failed to launch external program {0} {1}.", - "TaskRunnerSystem.cancelRequested": "\nユーザーè¦æ±‚ã”ã¨ã«ã‚¿ã‚¹ã‚¯ '{0}' ãŒçµ‚了ã—ã¾ã—ãŸã€‚" + "TaskRunnerSystem.cancelRequested": "\nユーザーè¦æ±‚ã”ã¨ã«ã‚¿ã‚¹ã‚¯ '{0}' ãŒçµ‚了ã—ã¾ã—ãŸã€‚", + "unkownProblemMatcher": "å•é¡Œãƒžãƒƒãƒãƒ£ãƒ¼ {0} ã¯è§£æ±ºã§ãã¾ã›ã‚“ã§ã—ãŸã€‚マッãƒãƒ£ãƒ¼ã¯ç„¡è¦–ã•ã‚Œã¾ã™" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json b/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json index 799b12a797b..e7930c9cd7a 100644 --- a/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json @@ -26,5 +26,7 @@ "workbench.action.terminal.scrollUp": "上ã«ã‚¹ã‚¯ãƒ­ãƒ¼ãƒ« (è¡Œ)", "workbench.action.terminal.scrollUpPage": "スクロール アップ (ページ)", "workbench.action.terminal.scrollToTop": "一番上ã«ã‚¹ã‚¯ãƒ­ãƒ¼ãƒ«", - "workbench.action.terminal.clear": "クリア" + "workbench.action.terminal.clear": "クリア", + "workbench.action.terminal.allowWorkspaceShell": "ワークスペースã§ã‚·ã‚§ãƒ«ã‚’構æˆã™ã‚‹ã“ã¨ã‚’許å¯ã™ã‚‹", + "workbench.action.terminal.disallowWorkspaceShell": "ワークスペースã§ã‚·ã‚§ãƒ«ã‚’構æˆã™ã‚‹ã“ã¨ã‚’許å¯ã—ãªã„" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json b/i18n/jpn/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json index 89ac9d8c928..7592dde26b5 100644 --- a/i18n/jpn/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json @@ -6,6 +6,7 @@ { "selectTheme.label": "é…色テーマ", "installColorThemes": "ãã®ä»–ã®é…色テーマをインストール...", + "themes.selectTheme": "é…色テーマã®é¸æŠž (上/下キーã§ãƒ—レビューå¯èƒ½)", "selectIconTheme.label": "ファイル アイコンã®ãƒ†ãƒ¼ãƒž", "installIconThemes": "ãã®ä»–ã®ãƒ•ã‚¡ã‚¤ãƒ« アイコンã®ãƒ†ãƒ¼ãƒžã‚’インストール...", "noIconThemeLabel": "ãªã—", diff --git a/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json index 587eecb5f9d..950f340d9ae 100644 --- a/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -11,18 +11,25 @@ "welcomePage.openFolder": "フォルダーを開ã...", "welcomePage.cloneGitRepository": "Git リãƒã‚¸ãƒˆãƒªã‚’複製...", "welcomePage.recent": "最近", + "welcomePage.moreRecent": "ãã®ä»–", "welcomePage.noRecentFolders": "最近使用ã—ãŸãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ãªã—", "welcomePage.help": "ヘルプ", + "welcomePage.keybindingsCheatsheet": "å°åˆ·å¯èƒ½ãªã‚­ãƒ¼ãƒœãƒ¼ãƒ‰ã®ãƒãƒ¼ãƒˆã‚·ãƒ¼ãƒˆ", "welcomePage.introductoryVideos": "紹介ビデオ", "welcomePage.productDocumentation": "製å“ドキュメント", "welcomePage.gitHubRepository": "GitHub リãƒã‚¸ãƒˆãƒª", "welcomePage.stackOverflow": "Stack Overflow", "welcomePage.showOnStartup": "起動時ã«ã‚¦ã‚§ãƒ«ã‚«ãƒ  ページを表示", "welcomePage.customize": "カスタマイズã™ã‚‹", + "welcomePage.installExtensionPacks": "ツールã¨è¨€èªž", + "welcomePage.installExtensionPacksDescription": "{0} 㨠{1} ã®ã‚µãƒãƒ¼ãƒˆã‚’インストールã™ã‚‹ ", + "welcomePage.moreExtensions": "ãã®ä»–", "welcomePage.installKeymapDescription": "キーボード ショートカットをインストールã—ã¾ã™", + "welcomePage.installKeymapExtension": "{0} 㨠{1} ã®ã‚­ãƒ¼ãƒœãƒ¼ãƒ‰ ショートカットをインストール", "welcomePage.others": "ãã®ä»–", "welcomePage.colorTheme": "é…色テーマ", "welcomePage.colorThemeDescription": "エディターã¨ã‚³ãƒ¼ãƒ‰ã®å¤–観を自由ã«è¨­å®šã—ã¾ã™", + "welcomePage.learn": "å­¦ã¶", "welcomePage.showCommands": "ã™ã¹ã¦ã®ã‚³ãƒžãƒ³ãƒ‰ã®æ¤œç´¢ã¨å®Ÿè¡Œ", "welcomePage.showCommandsDescription": "コントロール パãƒãƒ«ã‹ã‚‰ã‚³ãƒžãƒ³ãƒ‰ã‚’検索ã—ã¦ã™ã°ã‚„ãアクセスã—ã¾ã™ ({0})", "welcomePage.interfaceOverview": "インターフェイスã®æ¦‚è¦", diff --git a/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 07b2eb85861..eba406025bb 100644 --- a/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -5,11 +5,27 @@ // Do not edit this file. It is machine generated. { "welcomePage": "よã†ã“ã", + "welcomePage.javaScript": "JavaScript", + "welcomePage.typeScript": "TypeScript", + "welcomePage.python": "Python", + "welcomePage.php": "PHP", + "welcomePage.docker": "Docker", + "welcomePage.vim": "Vim", + "welcomePage.sublime": "Sublime", + "welcomePage.atom": "Atom", + "welcomePage.extensionPackAlreadyInstalled": "{0} ã®ã‚µãƒãƒ¼ãƒˆã¯æ—¢ã«ã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã¦ã„ã¾ã™ã€‚", + "welcomePage.willReloadAfterInstallingExtensionPack": "{0} ã®ã‚µãƒãƒ¼ãƒˆã‚’インストールã—ãŸå¾Œã€ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ãŒå†åº¦èª­ã¿è¾¼ã¾ã‚Œã¾ã™ã€‚", + "welcomePage.installingExtensionPack": "{0} ã®ã‚µãƒãƒ¼ãƒˆã‚’インストール...", + "welcomePage.extensionPackNotFound": "ID {1} ã®ã‚µãƒãƒ¼ãƒˆ {0} ã¯è¦‹ã¤ã‹ã‚Šã¾ã›ã‚“ã§ã—ãŸã€‚", "welcomePage.keymapAlreadyInstalled": "キーボード ショートカット {0} ã¯æ—¢ã«ã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã¦ã„ã¾ã™ã€‚", "welcomePage.willReloadAfterInstallingKeymap": "キーボード ショートカット {0} をインストールã—ãŸå¾Œã€ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ãŒå†åº¦èª­ã¿è¾¼ã¾ã‚Œã¾ã™ã€‚", "welcomePage.installingKeymap": "{0} ã®ã‚­ãƒ¼ãƒœãƒ¼ãƒ‰ ショートカットをインストールã—ã¦ã„ã¾ã™...", "welcomePage.keymapNotFound": "ID {1} ã®ã‚­ãƒ¼ãƒœãƒ¼ãƒ‰ ショートカット {0} ã¯è¦‹ã¤ã‹ã‚Šã¾ã›ã‚“ã§ã—ãŸã€‚", "welcome.title": "よã†ã“ã", + "welcomePage.extensionListSeparator": ",", + "welcomePage.installedExtension": "{0} (インストール済ã¿) ", "ok": "OK", - "cancel": "キャンセル" + "cancel": "キャンセル", + "welcomePage.quickLinkBackground": "ウェルカム ページã®ã‚¯ã‚¤ãƒƒã‚¯ リンクã®èƒŒæ™¯è‰²ã€‚", + "welcomePage.quickLinkHoverBackground": "ウェルカム ページã®ã‚¯ã‚¤ãƒƒã‚¯ リンクã®ãƒ›ãƒãƒ¼èƒŒæ™¯è‰²ã€‚" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json b/i18n/jpn/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json index 0c7056bc9fc..81d7a645e32 100644 --- a/i18n/jpn/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json +++ b/i18n/jpn/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json @@ -6,6 +6,7 @@ { "open": "設定を開ã", "close": "é–‰ã˜ã‚‹", + "saveAndRetry": "設定をä¿å­˜ã—ã¦å†è©¦è¡Œ", "errorUnknownKey": "構æˆãƒ•ã‚¡ã‚¤ãƒ«ã«æ›¸ãè¾¼ã‚ã¾ã›ã‚“ (ä¸æ˜Žãªã‚­ãƒ¼)", "errorInvalidTarget": "構æˆãƒ•ã‚¡ã‚¤ãƒ«ã«æ›¸ãè¾¼ã‚ã¾ã›ã‚“ (無効ãªã‚¿ãƒ¼ã‚²ãƒƒãƒˆ)", "errorNoWorkspaceOpened": "é–‹ã„ã¦ã„るフォルダーãŒãªã„ãŸã‚ã€è¨­å®šã‚’書ãè¾¼ã‚ã¾ã›ã‚“。最åˆã«ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã‚’é–‹ã„ã¦ã‹ã‚‰ã€ã‚‚ã†ä¸€åº¦ãŠè©¦ã—ãã ã•ã„。", diff --git a/i18n/kor/extensions/markdown/out/extension.i18n.json b/i18n/kor/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/kor/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/kor/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/kor/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/kor/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/kor/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/kor/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/kor/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/kor/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/kor/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/kor/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/kor/extensions/merge-conflict/package.i18n.json b/i18n/kor/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/kor/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/kor/extensions/npm/package.i18n.json b/i18n/kor/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/kor/extensions/npm/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/kor/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/kor/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index def2cd28d67..4266985efc9 100644 --- a/i18n/kor/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/kor/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,8 +6,6 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "ì´ë¯¸ì§€ê°€ 너무 커서 íŽ¸ì§‘ê¸°ì— í‘œì‹œí•  수 없습니다. ", - "resourceOpenExternalButton": "ì´ë¯¸ì§€ 열기", - "resourceOpenExternalText": " 외부 í”„ë¡œê·¸ëž¨ì„ ì‚¬ìš©í• ê¹Œìš”?", "nativeBinaryError": "파ì¼ì´ ì´ì§„ì´ê±°ë‚˜ 매우 í¬ê±°ë‚˜ 지ì›ë˜ì§€ 않는 í…스트 ì¸ì½”ë”©ì„ ì‚¬ìš©í•˜ê¸° ë•Œë¬¸ì— íŽ¸ì§‘ê¸°ì—ì„œ 표시ë˜ì§€ 않습니다.", "sizeB": "{0}B", "sizeKB": "{0}KB", diff --git a/i18n/kor/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/kor/src/vs/editor/common/config/commonEditorConfig.i18n.json index 18538323353..18aff6704be 100644 --- a/i18n/kor/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/kor/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -40,7 +40,6 @@ "formatOnType": "ìž…ë ¥ 후 편집기ì—ì„œ ìžë™ìœ¼ë¡œ ì¤„ì˜ ì„œì‹ì„ 지정할지 여부를 제어합니다.", "formatOnPaste": "ë¶™ì—¬ë„£ì€ ì½˜í…ì¸ ì˜ ì„œì‹ì„ 편집기ì—ì„œ ìžë™ìœ¼ë¡œ 지정할지 여부를 제어합니다. í¬ë§·í„°ëŠ” 반드시 사용할 수 있어야 하며 문서ì—ì„œ ë²”ìœ„ì˜ ì„œì‹ì„ 지정할 수 있어야 합니다.", "suggestOnTriggerCharacters": "트리거 문ìžë¥¼ 입력할 ë•Œ ì œì•ˆì„ ìžë™ìœ¼ë¡œ 표시할지 여부를 제어합니다.", - "acceptSuggestionOnEnter": "'Tab' 키 ì™¸ì— 'Enter' í‚¤ì— ëŒ€í•œ ì œì•ˆë„ í—ˆìš©í• ì§€ë¥¼ 제어합니다. 새 ì¤„ì„ ì‚½ìž…í•˜ëŠ” ë™ìž‘ê³¼ ì œì•ˆì„ í—ˆìš©í•˜ëŠ” ë™ìž‘ ê°„ì˜ ëª¨í˜¸í•¨ì„ ì—†ì•¨ 수 있습니다.", "acceptSuggestionOnCommitCharacter": "커밋 문ìžì— 대한 ì œì•ˆì„ í—ˆìš©í• ì§€ë¥¼ 제어합니다. 예를 들어 JavaScriptì—서는 세미콜론(';')ì´ ì œì•ˆì„ í—ˆìš©í•˜ê³  해당 문ìžë¥¼ 입력하는 커밋 문ìžì¼ 수 있습니다.", "snippetSuggestions": "코드 ì¡°ê°ì´ 다른 추천과 함께 표시ë˜ëŠ”지 여부 ë° ì •ë ¬ ë°©ë²•ì„ ì œì–´í•©ë‹ˆë‹¤.", "emptySelectionClipboard": "ì„ íƒ ì˜ì—­ ì—†ì´ í˜„ìž¬ 줄 복사 여부를 제어합니다.", diff --git a/i18n/kor/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/kor/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..eb7148607bd --- /dev/null +++ b/i18n/kor/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "'{0}'ì— ëŒ€í•œ ì •ì˜ë¥¼ ì°¾ì„ ìˆ˜ 없습니다.", + "generic.noResults": "ì •ì˜ë¥¼ ì°¾ì„ ìˆ˜ ì—†ìŒ", + "meta.title": "– {0} ì •ì˜", + "actions.goToDecl.label": "ì •ì˜ë¡œ ì´ë™", + "actions.goToDeclToSide.label": "측면ì—ì„œ ì •ì˜ ì—´ê¸°", + "actions.previewDecl.label": "ì •ì˜ í”¼í‚¹(Peeking)", + "goToImplementation.noResultWord": "'{0}'ì— ëŒ€í•œ êµ¬í˜„ì„ ì°¾ì„ ìˆ˜ 없습니다.", + "goToImplementation.generic.noResults": "êµ¬í˜„ì„ ì°¾ì„ ìˆ˜ 없습니다.", + "meta.implementations.title": " – {0} ê°œ 구현", + "actions.goToImplementation.label": "구현으로 ì´ë™", + "actions.peekImplementation.label": "구현 미리 보기", + "goToTypeDefinition.noResultWord": "'{0}'ì— ëŒ€í•œ í˜•ì‹ ì •ì˜ë¥¼ ì°¾ì„ ìˆ˜ 없습니다.", + "goToTypeDefinition.generic.noResults": "í˜•ì‹ ì •ì˜ë¥¼ ì°¾ì„ ìˆ˜ 없습니다.", + "meta.typeDefinitions.title": "– {0} í˜•ì‹ ì •ì˜", + "actions.goToTypeDefinition.label": "í˜•ì‹ ì •ì˜ë¡œ ì´ë™", + "actions.peekTypeDefinition.label": "í˜•ì‹ ì •ì˜ ë¯¸ë¦¬ 보기" +} \ No newline at end of file diff --git a/i18n/kor/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/kor/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..57b4929798f --- /dev/null +++ b/i18n/kor/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "{0}ê°œ ì •ì˜ë¥¼ 표시하려면 í´ë¦­í•˜ì„¸ìš”." +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/kor/src/vs/workbench/electron-browser/main.contribution.i18n.json index 603999dbae9..4c30f4bc75c 100644 --- a/i18n/kor/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/kor/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -7,6 +7,7 @@ "view": "보기", "help": "ë„움ë§", "file": "파ì¼", + "developer": "개발ìž", "showEditorTabs": "ì—´ë ¤ 있는 편집기를 탭ì—ì„œ 표시할지 여부를 제어합니다.", "editorTabCloseButton": "íŽ¸ì§‘ê¸°ì˜ íƒ­ 닫기 ë‹¨ì¶”ì˜ ìœ„ì¹˜ë¥¼ 제어하거나 'off'ë¡œ ì„¤ì •ëœ ê²½ìš° ì´ ë‹¨ì¶”ë¥¼ 사용하지 ì•Šë„ë¡ ì„¤ì •í•©ë‹ˆë‹¤.", "showIcons": "열린 편집기를 ì•„ì´ì½˜ê³¼ 함께 표시할지 여부를 제어합니다. ì´ë¥¼ 위해서는 ì•„ì´ì½˜ í…Œë§ˆë„ ì‚¬ìš©í•˜ë„ë¡ ì„¤ì •í•´ì•¼ 합니다.", diff --git a/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 8b6ad71cd4e..86d18d9fce3 100644 --- a/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "disableOtherKeymapsConfirmation": "키 ë°”ì¸ë”© ê°„ 충ëŒì„ 피하기 위해 다른 키 ë§µì„ ì‚¬ìš©í•˜ì§€ ì•Šë„ë¡ ì„¤ì •í• ê¹Œìš”?", + "yes": "예", + "no": "아니요" +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/kor/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index f9b799b1655..fe8ef9500ce 100644 --- a/i18n/kor/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,7 +16,6 @@ "associations": "파ì¼ê³¼ ì–¸ì–´ì˜ ì—°ê²°ì„ êµ¬ì„±í•˜ì„¸ìš”(예: \"*.extension\": \"html\"). ì´ëŸ¬í•œ êµ¬ì„±ì€ ì„¤ì¹˜ëœ ì–¸ì–´ì˜ ê¸°ë³¸ 연결보다 ìš°ì„  순위가 높습니다.", "encoding": "파ì¼ì„ ì½ê³  쓸 ë•Œ 사용할 기본 ë¬¸ìž ì§‘í•© ì¸ì½”딩입니다.", "autoGuessEncoding": "사용하ë„ë¡ ì„¤ì •í•˜ëŠ” 경우 파ì¼ì„ ì—´ ë•Œ ë¬¸ìž ì§‘í•© ì¸ì½”ë”©ì„ ì¶”ì¸¡í•©ë‹ˆë‹¤.", - "eol": "줄 바꿈 문ìžì˜ 기본 ë입니다.", "trimTrailingWhitespace": "사용하ë„ë¡ ì„¤ì •ë˜ë©´ 파ì¼ì„ 저장할 ë•Œ 후행 ê³µë°±ì´ ìž˜ë¦½ë‹ˆë‹¤.", "insertFinalNewline": "사용하ë„ë¡ ì„¤ì •ë˜ë©´ 저장할 ë•Œ íŒŒì¼ ëì— ë§ˆì§€ë§‰ ì¤„ë°”ê¿ˆì„ ì‚½ìž…í•©ë‹ˆë‹¤.", "files.autoSave.off": "ë”í‹° 파ì¼ì´ ìžë™ìœ¼ë¡œ 저장ë˜ì§€ 않습니다.", diff --git a/i18n/kor/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/kor/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index 4b931297269..ef1cdc9bc09 100644 --- a/i18n/kor/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -5,5 +5,9 @@ // Do not edit this file. It is machine generated. { "slow": "ëŠë¦° 시작 ê°ì§€ë¨", - "slow.detail": "방금 ëŠë¦¬ê²Œ 시작ë˜ì—ˆìŠµë‹ˆë‹¤. 프로파ì¼ë§ì„ 사용하ë„ë¡ ì„¤ì •í•œ ìƒíƒœë¡œ '{0}'ì„(를) 다시 시작하세요. í”„ë¡œí•„ì„ ê³µìœ í•´ 주시면 다시 빠르게 ì‹œìž‘ë  ìˆ˜ 있ë„ë¡ ìµœì„ ì„ ë‹¤í•˜ê² ìŠµë‹ˆë‹¤." + "slow.detail": "방금 ëŠë¦¬ê²Œ 시작ë˜ì—ˆìŠµë‹ˆë‹¤. 프로파ì¼ë§ì„ 사용하ë„ë¡ ì„¤ì •í•œ ìƒíƒœë¡œ '{0}'ì„(를) 다시 시작하세요. í”„ë¡œí•„ì„ ê³µìœ í•´ 주시면 다시 빠르게 ì‹œìž‘ë  ìˆ˜ 있ë„ë¡ ìµœì„ ì„ ë‹¤í•˜ê² ìŠµë‹ˆë‹¤.", + "prof.message": "í”„ë¡œí•„ì„ ë§Œë“¤ì—ˆìŠµë‹ˆë‹¤.", + "prof.detail": "문제를 ë°œìƒì‹œí‚¤ê³  ë‹¤ìŒ íŒŒì¼ì„ 수ë™ìœ¼ë¡œ 첨부하세요.\n{0}", + "prof.restartAndFileIssue": "문제 만들기 ë° ë‹¤ì‹œ 시작", + "prof.restart": "다시 시작" } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/kor/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index cb5666d331a..a436e5a707b 100644 --- a/i18n/kor/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -5,6 +5,11 @@ // Do not edit this file. It is machine generated. { "welcomePage": "시작", + "welcomePage.typeScript": "TypeScript", + "welcomePage.php": "PHP", + "welcomePage.vim": "Vim", + "welcomePage.sublime": "Sublime", + "welcomePage.atom": "Atom", "welcomePage.keymapAlreadyInstalled": "{0} 바로 가기 키가 ì´ë¯¸ 설치ë˜ì–´ 있습니다.", "welcomePage.willReloadAfterInstallingKeymap": "{0} 바로 가기 키를 설치한 후 ì°½ì´ ë‹¤ì‹œ 로드ë©ë‹ˆë‹¤.", "welcomePage.installingKeymap": "{0} 바로 가기 키를 설치하는 중...", diff --git a/i18n/ptb/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json b/i18n/ptb/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json new file mode 100644 index 00000000000..74a80b4280d --- /dev/null +++ b/i18n/ptb/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json @@ -0,0 +1,36 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "activeEditorShort": "e.g. meuArquivo.txt", + "activeEditorMedium": "e.g. minhaPasta/meuArquivo.txt", + "activeEditorLong": "e.g. /Usuarios/Desenvolvimento/meuProjeto/minhaPasta/meuArquivo.txt", + "rootName": "e.g. meuProjeto", + "rootPath": "e.g. /Usuarios/Desenvolvimento/meuProjeto", + "appName": "e.g. VS Code", + "dirty": "Um indicador de alteração se o editor ativo foi alterado", + "separator": "um separador condicional (' - ') que somente é mostrado quando envolvido por variáveis com valores", + "assocLabelFile": "Arquivos com Extensão", + "assocDescriptionFile": "Mapear todos arquivos que correspondem ao padrão global no seu nome de arquivo à linguagem com o identificador dado", + "assocLabelPath": "Arquivos com Caminho", + "assocDescriptionPath": "Mapear todos os arquivos que correspondem ao caminho absoluto global no seu caminho à linguagem com o identificador dado", + "fileLabel": "Arquivos por Extensão", + "fileDescription": "Combina todos os arquivos de uma extensão de arquivo específica.", + "filesLabel": "Arquivos com Várias Extensões", + "filesDescription": "Combina todos os arquivos com qualquer uma das extensões de arquivo.", + "derivedLabel": "Arquivos com Irmãos por Nome", + "derivedDescription": "Combina arquivos que têm irmãos com o mesmo nome, mas uma extensão diferente.", + "topFolderLabel": "Pasta por Nome (Nível Superior)", + "topFolderDescription": "Combina uma pasta de nível superior com um nome específico.", + "topFoldersLabel": "Pastas com Vários Nomes (Nível Superior)", + "topFoldersDescription": "Combina várias pastas de nível superior.", + "folderLabel": "Pasta por Nome (Qualquer Local)", + "folderDescription": "Combina uma pasta com um nome específico em qualquer local.", + "falseDescription": "Desabilita o padrão.", + "trueDescription": "Habilita o padrão.", + "siblingsDescription": "Combina arquivos que têm irmãos com o mesmo nome, mas uma extensão diferente.", + "languageSpecificEditorSettings": "Configurações do editor especificas para a linguagem", + "languageSpecificEditorSettingsDescription": "Sobrescrever as configurações do editor para a linguagem" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/css/client/out/cssMain.i18n.json b/i18n/ptb/extensions/css/client/out/cssMain.i18n.json new file mode 100644 index 00000000000..a649796227b --- /dev/null +++ b/i18n/ptb/extensions/css/client/out/cssMain.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "cssserver.name": "Servidor de linguagem CSS" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/css/package.i18n.json b/i18n/ptb/extensions/css/package.i18n.json new file mode 100644 index 00000000000..de011d44dce --- /dev/null +++ b/i18n/ptb/extensions/css/package.i18n.json @@ -0,0 +1,67 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "css.lint.argumentsInColorFunction.desc": "Número inválido de parâmetros", + "css.lint.boxModel.desc": "Não use largura ou altura ao usar preenchimento ou borda", + "css.lint.compatibleVendorPrefixes.desc": "Ao usar um prefixo específico de fornecedor, certifique-se de também incluir todas as outras propriedades específicas do fornecedor", + "css.lint.duplicateProperties.desc": "Não use as definições de estilo duplicadas", + "css.lint.emptyRules.desc": "Não use conjuntos de regra em branco", + "css.lint.float.desc": "Evite usar 'float'. Floats levam a CSS frágil, que é fácil de quebrar se um aspecto do layout for alterado.", + "css.lint.fontFaceProperties.desc": "A regra @font-face deve definir propriedades 'src' e 'font-family'", + "css.lint.hexColorLength.desc": "Cores hexadecimais devem consistir em três ou seis números hexadecimais", + "css.lint.idSelector.desc": "Seletores não devem conter IDs, pois essas regras estão firmemente acopladas ao HTML.", + "css.lint.ieHack.desc": "IE hacks somente são necessários ao dar suporte ao IE7 e mais antigos", + "css.lint.important.desc": "Evite usar !important. Esta é uma indicação de que a especificidade do CSS inteiro saiu de controle e precisa ser fatorada novamente.", + "css.lint.importStatement.desc": "Instruções de importação não carregam em paralelo", + "css.lint.propertyIgnoredDueToDisplay.desc": "Propriedade ignorada devido à exibição. Por exemplo, com 'display: inline', as propriedades width, height, margin-top, margin-bottom e float não têm efeito", + "css.lint.universalSelector.desc": "O seletor universal (*) é conhecido por ser lento", + "css.lint.unknownProperties.desc": "Propriedade desconhecida.", + "css.lint.unknownVendorSpecificProperties.desc": "Propriedade específica do fornecedor desconhecida.", + "css.lint.vendorPrefix.desc": "Ao usar um prefixo específico do fornecedor, inclua também a propriedade padrão", + "css.lint.zeroUnits.desc": "Nenhuma unidade para zero é necessária", + "css.validate.desc": "Habilita ou desabilita todas as validações", + "less.lint.argumentsInColorFunction.desc": "Número inválido de parâmetros", + "less.lint.boxModel.desc": "Não use largura ou altura ao usar preenchimento ou borda", + "less.lint.compatibleVendorPrefixes.desc": "Ao usar um prefixo específico de fornecedor, certifique-se de também incluir todas as outras propriedades específicas do fornecedor", + "less.lint.duplicateProperties.desc": "Não use as definições de estilo duplicadas", + "less.lint.emptyRules.desc": "Não use conjuntos de regra em branco", + "less.lint.float.desc": "Evite usar 'float'. Floats levam a CSS frágil, que é fácil de quebrar se um aspecto do layout for alterado.", + "less.lint.fontFaceProperties.desc": "A regra @font-face deve definir propriedades 'src' e 'font-family'", + "less.lint.hexColorLength.desc": "Cores hexadecimais devem consistir em três ou seis números hexadecimais", + "less.lint.idSelector.desc": "Seletores não devem conter IDs, pois essas regras estão firmemente acopladas ao HTML.", + "less.lint.ieHack.desc": "IE hacks somente são necessários ao dar suporte ao IE7 e mais antigos", + "less.lint.important.desc": "Evite usar !important. Esta é uma indicação de que a especificidade do CSS inteiro saiu de controle e precisa ser fatorada novamente.", + "less.lint.importStatement.desc": "Instruções de importação não carregam em paralelo", + "less.lint.propertyIgnoredDueToDisplay.desc": "Propriedade ignorada devido à exibição. Por exemplo, com 'display: inline', as propriedades width, height, margin-top, margin-bottom e float não têm efeito", + "less.lint.universalSelector.desc": "O seletor universal (*) é conhecido por ser lento", + "less.lint.unknownProperties.desc": "Propriedade desconhecida.", + "less.lint.unknownVendorSpecificProperties.desc": "Propriedade específica do fornecedor desconhecida.", + "less.lint.vendorPrefix.desc": "Ao usar um prefixo específico do fornecedor, inclua também a propriedade padrão", + "less.lint.zeroUnits.desc": "Nenhuma unidade para zero é necessária", + "less.validate.desc": "Habilita ou desabilita todas as validações", + "scss.lint.argumentsInColorFunction.desc": "Número inválido de parâmetros", + "scss.lint.boxModel.desc": "Não use largura ou altura ao usar preenchimento ou borda", + "scss.lint.compatibleVendorPrefixes.desc": "Ao usar um prefixo específico de fornecedor, certifique-se de também incluir todas as outras propriedades específicas do fornecedor", + "scss.lint.duplicateProperties.desc": "Não use as definições de estilo duplicadas", + "scss.lint.emptyRules.desc": "Não use conjuntos de regra em branco", + "scss.lint.float.desc": "Evite usar 'float'. Floats levam a CSS frágil, que é fácil de quebrar se um aspecto do layout for alterado.", + "scss.lint.fontFaceProperties.desc": "A regra @font-face deve definir propriedades 'src' e 'font-family'", + "scss.lint.hexColorLength.desc": "Cores hexadecimais devem consistir em três ou seis números hexadecimais", + "scss.lint.idSelector.desc": "Seletores não devem conter IDs, pois essas regras estão firmemente acopladas ao HTML.", + "scss.lint.ieHack.desc": "IE hacks somente são necessários ao dar suporte ao IE7 e mais antigos", + "scss.lint.important.desc": "Evite usar !important. Esta é uma indicação de que a especificidade do CSS inteiro saiu de controle e precisa ser fatorada novamente.", + "scss.lint.importStatement.desc": "Instruções de importação não carregam em paralelo", + "scss.lint.propertyIgnoredDueToDisplay.desc": "Propriedade ignorada devido à exibição. Por exemplo, com 'display: inline', as propriedades width, height, margin-top, margin-bottom e float não têm efeito", + "scss.lint.universalSelector.desc": "O seletor universal (*) é conhecido por ser lento", + "scss.lint.unknownProperties.desc": "Propriedade desconhecida.", + "scss.lint.unknownVendorSpecificProperties.desc": "Propriedade específica do fornecedor desconhecida.", + "scss.lint.vendorPrefix.desc": "Ao usar um prefixo específico do fornecedor, inclua também a propriedade padrão", + "scss.lint.zeroUnits.desc": "Nenhuma unidade para zero é necessária", + "scss.validate.desc": "Habilita ou desabilita todas as validações", + "less.colorDecorators.enable.desc": "Habilita ou desabilita decoradores de cores", + "scss.colorDecorators.enable.desc": "Habilita ou desabilita decoradores de cores", + "css.colorDecorators.enable.desc": "Habilita ou desabilita decoradores de cores" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/extension-editing/out/packageDocumentHelper.i18n.json b/i18n/ptb/extensions/extension-editing/out/packageDocumentHelper.i18n.json new file mode 100644 index 00000000000..8505afd6d4a --- /dev/null +++ b/i18n/ptb/extensions/extension-editing/out/packageDocumentHelper.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "languageSpecificEditorSettings": "Configurações do editor especificas para a linguagem", + "languageSpecificEditorSettingsDescription": "Sobrescrever as configurações do editor para a linguagem" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/git/out/askpass-main.i18n.json b/i18n/ptb/extensions/git/out/askpass-main.i18n.json new file mode 100644 index 00000000000..280b14bd0d7 --- /dev/null +++ b/i18n/ptb/extensions/git/out/askpass-main.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "missOrInvalid": "Credenciais ausentes ou inválidas." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/git/out/commands.i18n.json b/i18n/ptb/extensions/git/out/commands.i18n.json new file mode 100644 index 00000000000..ab5667e260b --- /dev/null +++ b/i18n/ptb/extensions/git/out/commands.i18n.json @@ -0,0 +1,43 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tag at": "Etiqueta em {0}", + "remote branch at": "Ramo remoto em {0}", + "repourl": "URL do repositório", + "parent": "Diretório pai", + "cloning": "Clonando repositório do Git...", + "openrepo": "Abrir Repositório", + "proposeopen": "Gostaria de abrir o repositório clonado?", + "confirm revert": "Tem certeza que deseja reverter as alterações selecionadas em {0}?", + "revert": "Reverter as alterações", + "confirm discard": "Tem certeza que deseja descartar as alterações em {0}?", + "confirm discard multiple": "Tem certeza que deseja descartar as alterações em {0} arquivos?", + "discard": "Descartar alterações", + "confirm discard all": "Tem certeza que deseja descartar TODAS as alterações? Isso é IRREVERSÃVEL!", + "discardAll": "Descartar TODAS as alterações", + "no staged changes": "Não há nenhuma modificação escalonada para confirmar.\n\nGostaria de escalonar automaticamente todas as suas alterações e confirmá-las diretamente?", + "yes": "Sim", + "always": "Sempre", + "no changes": "Não há mudanças para confirmar.", + "commit message": "Confirmar mensagem", + "provide commit message": "Por favor, forneça uma mensagem de commit", + "branch name": "Nome do Ramo", + "provide branch name": "Por favor, forneça um nome de ramo", + "no remotes to pull": "O seu repositório não possui remotos configurados para efetuar pull.", + "no remotes to push": "O seu repositório não possui remotos configurados para efetuar push.", + "nobranch": "Por favor, faça checkout em um ramo para fazer push em um remoto.", + "pick remote": "Pegue um remoto para publicar o ramo '{0}':", + "sync is unpredictable": "Esta ação vai fazer push e pull nos commits de e para '{0}'.", + "ok": "OK", + "never again": "Ok, Nunca Mostrar Novamente", + "no remotes to publish": "Seu repositório não possui remotos configurados para publicação.", + "disabled": "Git está desativado ou não é suportado neste espaço de trabalho", + "clean repo": "Por favor, limpe sua árvore de trabalho do repositório antes de fazer check-out.", + "cant push": "Não pode empurrar referências para remoto. Execute 'Pull' primeiro para integrar suas alterações.", + "git error details": "Git: {0}", + "git error": "Erro de Git", + "open git log": "Abrir Histórico do Git" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/git/out/main.i18n.json b/i18n/ptb/extensions/git/out/main.i18n.json new file mode 100644 index 00000000000..ae1dee26032 --- /dev/null +++ b/i18n/ptb/extensions/git/out/main.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "using git": "Usando git {0} de {1}", + "updateGit": "Atualizar o Git", + "neverShowAgain": "Não mostrar novamente", + "git20": "Você parece ter o git {0} instalado. Code funciona melhor com git > = 2" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/git/out/model.i18n.json b/i18n/ptb/extensions/git/out/model.i18n.json new file mode 100644 index 00000000000..717d2b4364a --- /dev/null +++ b/i18n/ptb/extensions/git/out/model.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "open": "Abrir", + "merge changes": "Mesclar Alterações", + "staged changes": "Alterações em Etapas", + "changes": "Alterações", + "ok": "OK", + "neveragain": "Nunca Mostrar Novamente", + "huge": "O repositório git em '{0}' tem muitas atualizações ativas, somente um subconjunto de funcionalidades do Git será habilitado." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/git/out/scmProvider.i18n.json b/i18n/ptb/extensions/git/out/scmProvider.i18n.json new file mode 100644 index 00000000000..490dda3603e --- /dev/null +++ b/i18n/ptb/extensions/git/out/scmProvider.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "commit": "Confirmar" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/git/out/statusbar.i18n.json b/i18n/ptb/extensions/git/out/statusbar.i18n.json new file mode 100644 index 00000000000..0b6ee800ffa --- /dev/null +++ b/i18n/ptb/extensions/git/out/statusbar.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "checkout": "Checkout...", + "sync changes": "Sincronizar alterações", + "publish changes": "Publicar alterações", + "syncing changes": "Sincronizando alterações..." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/git/package.i18n.json b/i18n/ptb/extensions/git/package.i18n.json new file mode 100644 index 00000000000..0c79f1929bb --- /dev/null +++ b/i18n/ptb/extensions/git/package.i18n.json @@ -0,0 +1,48 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "command.clone": "Clonar", + "command.init": "Inicializar Repositório", + "command.refresh": "Atualizar", + "command.openChange": "Abrir alterações", + "command.openFile": "Abrir Arquivo", + "command.stage": "Estagiar Alterações", + "command.stageAll": "Estagiar Todas Alterações", + "command.stageSelectedRanges": "Estagiar Faixas Selecionadas", + "command.revertSelectedRanges": "Reverter Faixas Selecionadas", + "command.unstage": "Desestagiar Alterações", + "command.unstageAll": "Desestagiar Todas Alterações", + "command.unstageSelectedRanges": "Desestagiar Faixas Selecionadas", + "command.clean": "Descartar Alterações", + "command.cleanAll": "Descartar Todas as Alterações", + "command.commit": "Confirmar", + "command.commitStaged": "Confirmar os preparados", + "command.commitStagedSigned": "Confirmar Estagiados (Desconectado)", + "command.commitAll": "Confirmar tudo", + "command.commitAllSigned": "Confirmar Tudo (Desconectado)", + "command.undoCommit": "Desfazer Ultima Confirmação", + "command.checkout": "Fazer checkout para...", + "command.branch": "Criar Ramificação...", + "command.pull": "Efetuar pull", + "command.pullRebase": "Efetuar pull (Rebase)", + "command.push": "Enviar por push", + "command.pushTo": "Enviar por push para...", + "command.sync": "Sincronizar", + "command.publish": "Publicar", + "command.showOutput": "Mostrar Saída do Git", + "config.enabled": "Se o git estiver habilitado", + "config.path": "Caminho para o executável do git", + "config.autorefresh": "Se a atualização automática estiver habilitada", + "config.autofetch": "Se a recuperação automática estiver habilitada", + "config.enableLongCommitWarning": "Se mensagens longas de confirmação devem ter aviso", + "config.confirmSync": "Confirmar antes de sincronizar repositórios git", + "config.countBadge": "Controla o contador de distintivos do git. 'todos' considera todas as alterações. 'rastreado' considera apenas as alterações controladas. 'desligado' desliga o contador.", + "config.checkoutType": "Controla quais tipos de ramos são listados quando executando `Checkout para... `. `todos` mostra todas as referências, `local` mostra apenas os ramos locais, `etiqueta` mostra apenas etiquetas e `remoto` mostra apenas os ramos remotos.", + "config.ignoreLegacyWarning": "Ignora o aviso de Git legado", + "config.ignoreLimitWarning": "Ignora o aviso quando houver muitas alterações em um repositório", + "config.defaultCloneDirectory": "O local padrão onde clonar um repositório git", + "config.enableSmartCommit": "Confirme todas as alterações quando não há modificações escalonadas." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/grunt/out/main.i18n.json b/i18n/ptb/extensions/grunt/out/main.i18n.json new file mode 100644 index 00000000000..909b68937c6 --- /dev/null +++ b/i18n/ptb/extensions/grunt/out/main.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "execFailed": "Auto detecção de Grunt falhou com erro: {0}" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/grunt/package.i18n.json b/i18n/ptb/extensions/grunt/package.i18n.json new file mode 100644 index 00000000000..d79ce76907e --- /dev/null +++ b/i18n/ptb/extensions/grunt/package.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "config.grunt.autoDetect": "Controla se a deteção automática de tarefas do Grunt está ligado ou desligado. Padrão é ligado." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/gulp/out/main.i18n.json b/i18n/ptb/extensions/gulp/out/main.i18n.json new file mode 100644 index 00000000000..51b05e4013e --- /dev/null +++ b/i18n/ptb/extensions/gulp/out/main.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "execFailed": "Auto detecção de gulp falhou com erro: {0}" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/gulp/package.i18n.json b/i18n/ptb/extensions/gulp/package.i18n.json new file mode 100644 index 00000000000..fae292414c2 --- /dev/null +++ b/i18n/ptb/extensions/gulp/package.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "config.gulp.autoDetect": "Controla se a detecção automática de tarefas Gulp está ativada ou desativada. Por padrão, é ativado." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/html/client/out/htmlMain.i18n.json b/i18n/ptb/extensions/html/client/out/htmlMain.i18n.json new file mode 100644 index 00000000000..314d1e5c58a --- /dev/null +++ b/i18n/ptb/extensions/html/client/out/htmlMain.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "htmlserver.name": "Servidor de Linguagem HTML" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/html/package.i18n.json b/i18n/ptb/extensions/html/package.i18n.json new file mode 100644 index 00000000000..2f255a02e7f --- /dev/null +++ b/i18n/ptb/extensions/html/package.i18n.json @@ -0,0 +1,27 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "html.format.enable.desc": "Ativa/desativa o formatador HTML padrão (requer reinicialização)", + "html.format.wrapLineLength.desc": "Quantidade máxima de caracteres por linha (0 = desativar).", + "html.format.unformatted.desc": "Lista de tags, separados por vírgula, que não deveria ser reformatada. o padrão é 'nulo' para todas as tags listadas em https://www.w3.org/TR/html5/dom.html#phrasing-content.", + "html.format.contentUnformatted.desc": "Lista de tags, separada por vírgula, onde o conteúdo não deve ser reformatado. o padrão é 'nulo' para a tag 'pré'.", + "html.format.indentInnerHtml.desc": "Indentar secões e .", + "html.format.preserveNewLines.desc": "Se quebras de linha existentes antes de elementos deveriam ser preservadas. Só funciona antes de elementos, não dentro de rótulos ou para texto.", + "html.format.maxPreserveNewLines.desc": "Número máximo de quebras de linha a serem preservadas em um bloco. Use 'null' para ilimitado.", + "html.format.indentHandlebars.desc": "Formatar e indentar {{#foo}} e {{/ foo}}.", + "html.format.endWithNewline.desc": "Finalizar com uma nova linha.", + "html.format.extraLiners.desc": "Lista de rótulos, separados por vírgulas, que deveriam ter uma quebra de linha extra antes deles. 'null' admite o padrão \"head, body, /html\".", + "html.format.wrapAttributes.desc": "Agrupar atributos.", + "html.format.wrapAttributes.auto": "Agrupar atributos somente quando o tamanho da linha é excedido.", + "html.format.wrapAttributes.force": "Agrupar cada atributo exceto o primeiro.", + "html.format.wrapAttributes.forcealign": "Agrupar cada atributo, exceto o primeiro e manter alinhado.", + "html.format.wrapAttributes.forcemultiline": "Agrupar cada atributo.", + "html.suggest.angular1.desc": "Configura se o suporte da linguagem HTML interna sugere rótulos e propriedades do Angular V1.", + "html.suggest.ionic.desc": "Configura se o suporte da linguagem HTML interna sugere rótulos, propriedades e valores Ionic.", + "html.suggest.html5.desc": "Configura se o suporte da linguagem HTML interna sugere rótulos, propriedades e valores HTML5.", + "html.validate.scripts": "Configura se o suporte da linguagem HTML interna valida scripts embutidos.", + "html.validate.styles": "Configura se o suporte da linguagem HTML interna valida estilos embutidos." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/jake/out/main.i18n.json b/i18n/ptb/extensions/jake/out/main.i18n.json new file mode 100644 index 00000000000..4cfc54e5fef --- /dev/null +++ b/i18n/ptb/extensions/jake/out/main.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "execFailed": "Auto detecção de Jake falhou com erro: {0}" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/jake/package.i18n.json b/i18n/ptb/extensions/jake/package.i18n.json new file mode 100644 index 00000000000..94c08817c8d --- /dev/null +++ b/i18n/ptb/extensions/jake/package.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "config.jake.autoDetect": "Controla se a detecção automática de tarefas Jake está ativada ou desativada. Por padrão, é ativado." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/javascript/out/features/bowerJSONContribution.i18n.json b/i18n/ptb/extensions/javascript/out/features/bowerJSONContribution.i18n.json new file mode 100644 index 00000000000..84b277202e8 --- /dev/null +++ b/i18n/ptb/extensions/javascript/out/features/bowerJSONContribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "json.bower.default": "Bower.json padrão", + "json.bower.error.repoaccess": "Falha na solicitação ao repositório bower: {0}", + "json.bower.latest.version": "último" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/javascript/out/features/packageJSONContribution.i18n.json b/i18n/ptb/extensions/javascript/out/features/packageJSONContribution.i18n.json new file mode 100644 index 00000000000..9917fa36b2e --- /dev/null +++ b/i18n/ptb/extensions/javascript/out/features/packageJSONContribution.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "json.package.default": "Package.json padrão", + "json.npm.error.repoaccess": "Falha na solicitação ao repositório NPM: {0}", + "json.npm.latestversion": "A versão do pacote mais recente no momento", + "json.npm.majorversion": "Combina com a versão principal mais recente (1.x.x)", + "json.npm.minorversion": "Combina a versão secundária mais recente (1.2.x)", + "json.npm.version.hover": "Última versão: {0}" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/json/client/out/jsonMain.i18n.json b/i18n/ptb/extensions/json/client/out/jsonMain.i18n.json new file mode 100644 index 00000000000..4391c95a2ba --- /dev/null +++ b/i18n/ptb/extensions/json/client/out/jsonMain.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "jsonserver.name": "Servidor de linguagem JSON" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/json/package.i18n.json b/i18n/ptb/extensions/json/package.i18n.json new file mode 100644 index 00000000000..9d812f5b253 --- /dev/null +++ b/i18n/ptb/extensions/json/package.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "json.schemas.desc": "Esquemas associadas a arquivos de JSON no projeto atual", + "json.schemas.url.desc": "Um URL para um esquema ou um caminho relativo a um esquema no diretório atual", + "json.schemas.fileMatch.desc": "Uma matriz de padrões de arquivos para correspondência ao resolver arquivos JSON para esquemas.", + "json.schemas.fileMatch.item.desc": "Um padrão de arquivos que pode conter '*' para fazer a correspondência ao resolver arquivos JSON para esquemas.", + "json.schemas.schema.desc": "A definição de esquema para o URL dado. O esquema precisa ser fornecido apenas para evitar acessos ao URL do esquema.", + "json.format.enable.desc": "Habilitar/desabilitar o formatador JSON padrão (requer reinicialização)", + "json.tracing.desc": "Loga a comunicação entre o VS Code e o servidor de linguagem JSON.", + "json.colorDecorators.enable.desc": "Habilita ou desabilita os decoradores de cor" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/markdown/out/extension.i18n.json b/i18n/ptb/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ptb/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ptb/extensions/markdown/out/previewContentProvider.i18n.json b/i18n/ptb/extensions/markdown/out/previewContentProvider.i18n.json new file mode 100644 index 00000000000..f4e956aa5eb --- /dev/null +++ b/i18n/ptb/extensions/markdown/out/previewContentProvider.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "preview.securityMessage.text": "Scripts foram desabilitados neste documento", + "preview.securityMessage.title": "Scripts são desabilitados na pré-visualização de markdown. Altere a configuração de segurança de pré-visualização do Markdown para habilitar scripts", + "preview.securityMessage.label": "Aviso de segurança de scripts desabilitados" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/markdown/out/security.i18n.json b/i18n/ptb/extensions/markdown/out/security.i18n.json new file mode 100644 index 00000000000..6b83ed6faed --- /dev/null +++ b/i18n/ptb/extensions/markdown/out/security.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "preview.showPreviewSecuritySelector.disallowScriptsForWorkspaceTitle": "Desabilitar a execução de scripts em pré-visualização de markdown para este espaço de trabalho", + "preview.showPreviewSecuritySelector.currentSelection": "Configuração atual", + "preview.showPreviewSecuritySelector.allowScriptsForWorkspaceTitle": "Habilitar a execução de scripts em pré-visualizações de markdown para este espaço de trabalho", + "preview.showPreviewSecuritySelector.title": "Alterar configurações de segurança para a pré-visualização do Markdown" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/markdown/package.i18n.json b/i18n/ptb/extensions/markdown/package.i18n.json new file mode 100644 index 00000000000..83c2f99b160 --- /dev/null +++ b/i18n/ptb/extensions/markdown/package.i18n.json @@ -0,0 +1,22 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "markdown.preview.doubleClickToSwitchToEditor.desc": "Duplo clique na pré-visualização markdown para alternar para o editor.", + "markdown.preview.fontFamily.desc": "Controla a família de fonte usada na pré-visualização de markdown.", + "markdown.preview.fontSize.desc": "Controla o tamanho da fonte em pixels usado na pré-visualização de markdown.", + "markdown.preview.lineHeight.desc": "Controla a altura de linha usada na pré-visualização de markdown. Este número é relativo ao tamanho de fonte.", + "markdown.preview.markEditorSelection.desc": "Marca a seleção atual do editor na pré-visualização de markdown.", + "markdown.preview.scrollEditorWithPreview.desc": "Quando a pré-visualização de markdown é rolada, atualiza a exibição do editor.", + "markdown.preview.scrollPreviewWithEditorSelection.desc": "Rola a pré-visualização do markdown para revelar a linha atualmente selecionada do editor.", + "markdown.preview.title": "Abrir a visualização", + "markdown.previewFrontMatter.dec": "Configura como o frontispicio YAML frente questão devem ser processado na pré-visualização de markdown. 'hide' remove o frontispicio. Caso contrário, o frontispicio é tratado como conteúdo de markdown.", + "markdown.previewSide.title": "Abre pré-visualização ao lado", + "markdown.showSource.title": "Exibir Código-Fonte", + "markdown.styles.dec": "Uma lista de URLs ou caminhos locais para folhas de estilo CSS para usar na pré-visualização do markdown. Caminhos relativos são interpretados em relação à pasta aberta no explorer. Se não houver nenhuma pasta aberta, eles são interpretados em relação ao local do arquivo markdown. Todos os ' \\' precisam ser escritos como ' \\ \\ '.", + "markdown.showPreviewSecuritySelector.title": "Alterar as configurações de segurança de pré-visualização do Markdown", + "markdown.preview.enableExperimentalExtensionApi.desc": "[Experimental] Permitir extensões para ampliar a pré-visualização do markdown.", + "markdown.trace.desc": "Habilitar log de depuração para a extensão do markdown." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/ptb/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ptb/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ptb/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/ptb/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ptb/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ptb/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/ptb/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ptb/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ptb/extensions/merge-conflict/package.i18n.json b/i18n/ptb/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ptb/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ptb/extensions/npm/package.i18n.json b/i18n/ptb/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ptb/extensions/npm/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ptb/extensions/php/out/features/validationProvider.i18n.json b/i18n/ptb/extensions/php/out/features/validationProvider.i18n.json new file mode 100644 index 00000000000..9e0ce64f472 --- /dev/null +++ b/i18n/ptb/extensions/php/out/features/validationProvider.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "php.useExecutablePath": "Você permite {0} (definido como uma configuração do espaço de trabalho) a ser executado para lint de arquivos PHP?", + "php.yes": "Permitir", + "php.no": "Não permitir", + "wrongExecutable": "Não é possível validar {0} pois não é um executável php válido. Use a configuração 'php.validate.executablePath' para configurar o executável do PHP.", + "noExecutable": "Não é possível validar porque nenhum executável PHP está definido. Use a configuração 'php.validate.executablePath' para configurar o executável do PHP.", + "unknownReason": "Falha ao executar o php usando o caminho: {0}. O motivo é desconhecido." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/php/package.i18n.json b/i18n/ptb/extensions/php/package.i18n.json new file mode 100644 index 00000000000..7ec916f5dd8 --- /dev/null +++ b/i18n/ptb/extensions/php/package.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "configuration.suggest.basic": "Configura se as sugestões intrínsecas da linguagem PHP estão habilitadas. O suporte sugere globais e variáveis do PHP.", + "configuration.validate.enable": "Habilita/desabilita a validação interna do PHP.", + "configuration.validate.executablePath": "Aponta para o executável do PHP.", + "configuration.validate.run": "Se o linter é executado ao salvar ou ao digitar.", + "configuration.title": "PHP", + "commands.categroy.php": "PHP", + "command.untrustValidationExecutable": "Desabilita a validação de executável do PHP (definida como configuração do espaço de trabalho)" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/features/bufferSyncSupport.i18n.json b/i18n/ptb/extensions/typescript/out/features/bufferSyncSupport.i18n.json new file mode 100644 index 00000000000..1cef0c6e94a --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/features/bufferSyncSupport.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "versionMismatch": "Incompatibilidade de versão! global tsc ({0})! = serviço de linguagem do VS Code ({1}). Erros de compilação inconsistentes podem ocorrer", + "moreInformation": "Mais informações", + "doNotCheckAgain": "Não verificar novamente", + "close": "Fechar", + "updateTscCheck": "Atualizada configuração de usuário 'typescript.check.tscVersion' para false " +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/features/completionItemProvider.i18n.json b/i18n/ptb/extensions/typescript/out/features/completionItemProvider.i18n.json new file mode 100644 index 00000000000..58097d90545 --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/features/completionItemProvider.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "acquiringTypingsLabel": "Adquirindo digitações...", + "acquiringTypingsDetail": "Adquirindo definições de digitações para o Intellisense." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json b/i18n/ptb/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json new file mode 100644 index 00000000000..99716f32145 --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ts-check": "Habilita verificação semântica em um arquivo JavaScript. Deve estar no topo de um arquivo.", + "ts-nocheck": "Desabilita verificação semântica em um arquivo JavaScript. Deve estar no topo de um arquivo.", + "ts-ignore": "Suprime erros de @ts-check na próxima linha de um arquivo." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/features/implementationsCodeLensProvider.i18n.json b/i18n/ptb/extensions/typescript/out/features/implementationsCodeLensProvider.i18n.json new file mode 100644 index 00000000000..ef8dd6423d6 --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/features/implementationsCodeLensProvider.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "oneImplementationLabel": "1 implementação", + "manyImplementationLabel": "{0} implementações", + "implementationsErrorLabel": "Não foi possível determinar implementações" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/features/jsDocCompletionProvider.i18n.json b/i18n/ptb/extensions/typescript/out/features/jsDocCompletionProvider.i18n.json new file mode 100644 index 00000000000..20b08d7679b --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/features/jsDocCompletionProvider.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "typescript.jsDocCompletionItem.documentation": "Comentário JSDoc" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/features/referencesCodeLensProvider.i18n.json b/i18n/ptb/extensions/typescript/out/features/referencesCodeLensProvider.i18n.json new file mode 100644 index 00000000000..1838c3c1621 --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/features/referencesCodeLensProvider.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "oneReferenceLabel": "1 referência", + "manyReferenceLabel": "{0} referências", + "referenceErrorLabel": "Não foi possível determinar as referências" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/typescriptMain.i18n.json b/i18n/ptb/extensions/typescript/out/typescriptMain.i18n.json new file mode 100644 index 00000000000..82e6c288fb1 --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/typescriptMain.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "typescript.projectConfigNoWorkspace": "Favor abrir uma pasta no VS Code para usar um projeto TypeScript ou JavaScript", + "typescript.projectConfigUnsupportedFile": "Não foi possível determinar o projeto TypeScript ou JavaScript. Tipo de arquivo não suportado", + "typescript.projectConfigCouldNotGetInfo": "Não foi possível determinar o projeto TypeScript ou JavaScript", + "typescript.noTypeScriptProjectConfig": "Arquivo não é parte de um projeto TypeScript", + "typescript.noJavaScriptProjectConfig": "Arquivo não é parte de um projeto JavaScript", + "typescript.configureTsconfigQuickPick": "Configurar tsconfig.json", + "typescript.configureJsconfigQuickPick": "Configurar jsconfig.json", + "typescript.projectConfigLearnMore": "Saber Mais" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/typescriptServiceClient.i18n.json b/i18n/ptb/extensions/typescript/out/typescriptServiceClient.i18n.json new file mode 100644 index 00000000000..37527e507b0 --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/typescriptServiceClient.i18n.json @@ -0,0 +1,24 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noServerFound": "O caminho {0} não aponta para uma instalação de tsserver válida. Voltando para a versão do TypeScript empacotada.", + "noBundledServerFound": "O tsserver do VS Code foi excluído por outra aplicação, como por exemplo uma ferramenta de detecção de virus mal-comportada. Favor reinstalar o VS Code.", + "versionNumber.custom": "personalizado", + "serverCouldNotBeStarted": "Servidor de linguagem TypeScript não pôde ser iniciado. Mensagem de erro é: {0}", + "useVSCodeVersionOption": "Usar a Versão do VS Code", + "activeVersion": "Atualmente ativo", + "useWorkspaceVersionOption": "Use a versão de área de trabalho", + "learnMore": "Saiba Mais", + "selectTsVersion": "Selecione a versão do TypeScript usada para os recursos de linguagem JavaScript e TypeScript", + "typescript.openTsServerLog.notSupported": "Logging de TS Server requer TS TS 2.2.2+", + "typescript.openTsServerLog.loggingNotEnabled": "Logging de TS Server está desligado. Por favor configure 'typescript.tsserver.log' e reinicie o TS Server para habilitar o log", + "typescript.openTsServerLog.enableAndReloadOption": "Habilitar logging e reniciar TS server", + "typescript.openTsServerLog.noLogFile": "O TS Server não iniciou o logging.", + "openTsServerLog.openFileFailedFailed": "Não foi possível abrir o arquivo de log do TS Server", + "serverDiedAfterStart": "O serviço de linguagem TypeScript morreu 5 vezes depois que começou. O serviço não será reiniciado.", + "serverDiedReportIssue": "Reportar Problema", + "serverDied": "O serviço TypeScript morreu inesperadamente 5 vezes nos últimos 5 minutos." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/utils/logger.i18n.json b/i18n/ptb/extensions/typescript/out/utils/logger.i18n.json new file mode 100644 index 00000000000..bc738f43d0c --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/utils/logger.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "channelName": "TypeScript" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/utils/projectStatus.i18n.json b/i18n/ptb/extensions/typescript/out/utils/projectStatus.i18n.json new file mode 100644 index 00000000000..5cb18373637 --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/utils/projectStatus.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "hintExclude": "Para habilitar os recursos de linguagem JavaScript/TypeScipt em todo o projeto, excluir pastas com muitos arquivos, como: {0}", + "hintExclude.generic": "Para habilitar os recursos de linguagem JavaScript/TypeScipt em todo o projeto, excluir pastas grandes com arquivos em que você não trabalha.", + "open": "Configurar exclusões", + "large.label": "Configurar exclusões", + "hintExclude.tooltip": "Para habilitar os recursos de linguagem JavaScript/TypeScipt em todo o projeto, excluir pastas grandes com arquivos em que você não trabalha." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/ptb/extensions/typescript/out/utils/typingsStatus.i18n.json new file mode 100644 index 00000000000..ce050eb3d8e --- /dev/null +++ b/i18n/ptb/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "installingPackages": "Buscando dados para melhor IntelliSense do TypeScript", + "typesInstallerInitializationFailed.title": "Não foi possível instalar arquivos de digitação para recursos da linguagem JavaScript. Certifique-se que NPM está instalado e está em seu caminho", + "typesInstallerInitializationFailed.moreInformation": "Mais informações", + "typesInstallerInitializationFailed.doNotCheckAgain": "Não verificar novamente", + "typesInstallerInitializationFailed.close": "Fechar" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/package.i18n.json b/i18n/ptb/extensions/typescript/package.i18n.json new file mode 100644 index 00000000000..5e4125ec050 --- /dev/null +++ b/i18n/ptb/extensions/typescript/package.i18n.json @@ -0,0 +1,45 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "typescript.reloadProjects.title": "Recarregar Projeto", + "javascript.reloadProjects.title": "Recarregar Projeto", + "configuration.typescript": "TypeScript", + "typescript.useCodeSnippetsOnMethodSuggest.dec": "Funções completas com a assinatura do parâmetro.", + "typescript.tsdk.desc": "Especifica o caminho da pasta que contém os arquivos tsserver e lib*.d.ts para usar.", + "typescript.disableAutomaticTypeAcquisition": "Desabilita a aquisição automática de tipo. Requer TypeScript > = 2.0.6 e um reinício depois da alteração.", + "typescript.check.tscVersion": "Verifica se um ima instalação global do compilador TypeScript (por exemplo, tsc) difere do serviço de linguagem TypeScript usado.", + "typescript.tsserver.log": "Habilita o log do servidor TS para um arquivo. Este log pode ser usado para diagnosticar problemas do servidor de TS. O log pode conter caminhos de arquivo, código-fonte e outras informações potencialmente confidenciais do seu projeto.", + "typescript.tsserver.trace": "Habilita o rastreamento de mensagens enviadas para o servidor de TS. Este rastreamento pode ser usado para diagnosticar problemas do servidor de TS. O rastreamento pode conter caminhos de arquivo, código-fonte e outras informações potencialmente confidenciais do seu projeto.", + "typescript.tsserver.experimentalAutoBuild": "Habilita auto build experimental. Requer a versão 1.9 dev ou 2.x do tsserver e o reinício do VS Code depois da alteração.", + "typescript.validate.enable": "Habilita/Desabilita a validação TypeScript.", + "typescript.format.enable": "Habilita/Desabilita o formatador padrão TypeScript.", + "javascript.format.enable": "Habilita/Desabilita o formatador padrão JavaScript.", + "format.insertSpaceAfterCommaDelimiter": "Define o tratamento de espaços após um delimitador vírgula.", + "format.insertSpaceAfterSemicolonInForStatements": "Define o tratamento de espaços após um ponto e vírgula para um comando.", + "format.insertSpaceBeforeAndAfterBinaryOperators": "Define o tratamento de espaços após um operador binário.", + "format.insertSpaceAfterKeywordsInControlFlowStatements": "Define o tratamento de espaços após palavras-chave em um comando de controle de fluxo.", + "format.insertSpaceAfterFunctionKeywordForAnonymousFunctions": "Define o tratamento de espaços após uma palavra-chave de função para funções anônimas.", + "format.insertSpaceBeforeFunctionParenthesis": "Define a manipulação de espaços antes de parênteses do argumento de função. Requer TypeScript > = 2.1.5.", + "format.insertSpaceAfterOpeningAndBeforeClosingNonemptyParenthesis": "Define a manipulação de espaços após abrir e antes de fechar parênteses não vazios.", + "format.insertSpaceAfterOpeningAndBeforeClosingNonemptyBrackets": "Define a manipulação de espaços após abrir e antes de fechar colchetes não vazios.", + "format.insertSpaceAfterOpeningAndBeforeClosingNonemptyBraces": "Define a manipulação de espaços após abrir e antes de fechar chaves não vazias. Requer TypeScript >= 2.3.0.", + "format.insertSpaceAfterOpeningAndBeforeClosingTemplateStringBraces": "Define a manipulação de espaços após abrir e antes de fechar chaves de cadeias de caracteres de modelos. Requer TypeScript >= 2.0.6.", + "format.insertSpaceAfterOpeningAndBeforeClosingJsxExpressionBraces": "Define a manipulação de espaços após abrir e antes de fechar chaves de expressões JSX. Requer TypeScript >= 2.0.6.", + "format.placeOpenBraceOnNewLineForFunctions": "Define-se uma chave de abertura é colocada em uma nova linha para funções ou não.", + "format.placeOpenBraceOnNewLineForControlBlocks": "Define-se uma chave de abertura é colocada em uma nova linha para blocos de controle ou não.", + "javascript.validate.enable": "Habilitar/Desabilitar validação JavaScript.", + "typescript.goToProjectConfig.title": "Ir para a Configuração do Projeto", + "javascript.goToProjectConfig.title": "Ir para a Configuração do Projeto", + "javascript.referencesCodeLens.enabled": "Habilitar/desabilitar referências CodeLens em arquivos JavaScript.", + "typescript.referencesCodeLens.enabled": "Habilitar/desabilitar referências CodeLens em arquivos TypeScript. Requer TypeScript > = 2.0.6.", + "typescript.implementationsCodeLens.enabled": "Habilitar/desabilitar implementações CodeLens. Requer TypeScript > = 2.0.6.", + "typescript.openTsServerLog.title": "Abrir arquivo de log do servidor TS", + "typescript.selectTypeScriptVersion.title": "Selecionar a versão do JavaScript", + "jsDocCompletion.enabled": "Habilitar/Desabilitar comentários JSDoc automáticos.", + "javascript.implicitProjectConfig.checkJs": "Habilitar/desabilitar verificação semântica de arquivos JavaScript. Os arquivos existentes jsconfig.json ou tsconfig.json substituem essa configuração. Requer TypeScript > = 2.3.1.", + "typescript.check.npmIsInstalled": "Verificar se NPM está instalado para aquisição automática de digitação", + "javascript.nameSuggestions": "Habilitar/desabilitar incluindo nomes exclusivos do arquivo nas listas de sugestão de JavaScript." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/browser/ui/actionbar/actionbar.i18n.json b/i18n/ptb/src/vs/base/browser/ui/actionbar/actionbar.i18n.json new file mode 100644 index 00000000000..4ecb2c803f4 --- /dev/null +++ b/i18n/ptb/src/vs/base/browser/ui/actionbar/actionbar.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "titleLabel": "{0} ({1})" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/browser/ui/aria/aria.i18n.json b/i18n/ptb/src/vs/base/browser/ui/aria/aria.i18n.json new file mode 100644 index 00000000000..e558eb6187a --- /dev/null +++ b/i18n/ptb/src/vs/base/browser/ui/aria/aria.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "repeated": "{0} (ocorreu novamente)" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/browser/ui/findinput/findInput.i18n.json b/i18n/ptb/src/vs/base/browser/ui/findinput/findInput.i18n.json new file mode 100644 index 00000000000..524ba7bb4a7 --- /dev/null +++ b/i18n/ptb/src/vs/base/browser/ui/findinput/findInput.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defaultLabel": "entrada" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/browser/ui/findinput/findInputCheckboxes.i18n.json b/i18n/ptb/src/vs/base/browser/ui/findinput/findInputCheckboxes.i18n.json new file mode 100644 index 00000000000..1a477ef1e6d --- /dev/null +++ b/i18n/ptb/src/vs/base/browser/ui/findinput/findInputCheckboxes.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "caseDescription": "Diferenciar Maiúsculas de Minúsculas", + "wordsDescription": "Coincidir Palavra Inteira", + "regexDescription": "Usar Expressão Regular" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/browser/ui/inputbox/inputBox.i18n.json b/i18n/ptb/src/vs/base/browser/ui/inputbox/inputBox.i18n.json new file mode 100644 index 00000000000..0b282bdee8a --- /dev/null +++ b/i18n/ptb/src/vs/base/browser/ui/inputbox/inputBox.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "alertErrorMessage": "Erro: {0}", + "alertWarningMessage": "Aviso: {0}", + "alertInfoMessage": "Informações: {0}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/ptb/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json new file mode 100644 index 00000000000..d023184ae70 --- /dev/null +++ b/i18n/ptb/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "imgMeta": "{0}x{1} {2}", + "largeImageError": "A imagem é muito grande para ser exibida no editor.", + "nativeBinaryError": "O arquivo não pode ser exibido no editor porque é binário, muito grande ou usa uma codificação de texto sem suporte.", + "sizeB": "{0}B", + "sizeKB": "{0}KB", + "sizeMB": "{0}MB", + "sizeGB": "{0}GB", + "sizeTB": "{0}TB" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/browser/ui/toolbar/toolbar.i18n.json b/i18n/ptb/src/vs/base/browser/ui/toolbar/toolbar.i18n.json new file mode 100644 index 00000000000..4a046b57296 --- /dev/null +++ b/i18n/ptb/src/vs/base/browser/ui/toolbar/toolbar.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "more": "Mais" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/common/errorMessage.i18n.json b/i18n/ptb/src/vs/base/common/errorMessage.i18n.json new file mode 100644 index 00000000000..257ffd9e14c --- /dev/null +++ b/i18n/ptb/src/vs/base/common/errorMessage.i18n.json @@ -0,0 +1,18 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "message": "{0}. Código de erro: {1}", + "error.permission.verbose": "Permissão Negada (HTTP {0})", + "error.permission": "Permissão Negada", + "error.http.verbose": "{0} (HTTP {1}: {2})", + "error.http": "{0} (HTTP {1})", + "error.connection.unknown.verbose": "Erro de Conexão Desconhecido ({0})", + "error.connection.unknown": "Ocorreu um erro de conexão desconhecido. Você não está mais conectado à Internet ou o servidor que você está conectado está offline.", + "stackTrace.format": "{0}: {1}", + "error.defaultMessage": "Ocorreu um erro desconhecido. Consulte o log para obter mais detalhes.", + "nodeExceptionMessage": "Ocorreu um erro de sistema ({0})", + "error.moreErrors": "{0} ({1} erros no total)" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/common/jsonErrorMessages.i18n.json b/i18n/ptb/src/vs/base/common/jsonErrorMessages.i18n.json new file mode 100644 index 00000000000..d6108586df8 --- /dev/null +++ b/i18n/ptb/src/vs/base/common/jsonErrorMessages.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "error.invalidSymbol": "Símbolo inválido", + "error.invalidNumberFormat": "Formato de número inválido", + "error.propertyNameExpected": "Nome de propriedade esperado", + "error.valueExpected": "Valor esperado", + "error.colonExpected": "Dois-pontos esperados", + "error.commaExpected": "Vírgula esperada", + "error.closeBraceExpected": "Chave de fechamento esperada", + "error.closeBracketExpected": "Colchete de fechamento esperado", + "error.endOfFileExpected": "Fim do arquivo esperado" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/common/processes.i18n.json b/i18n/ptb/src/vs/base/common/processes.i18n.json new file mode 100644 index 00000000000..165322e5952 --- /dev/null +++ b/i18n/ptb/src/vs/base/common/processes.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ExecutableParser.commandMissing": "Erro: informações de executável devem definir um comando do tipo string", + "ExecutableParser.isShellCommand": "Aviso: IsShellCommand deve ser to tipo booleano. Ignorando valor {0}", + "ExecutableParser.args": "Aviso: args deve ser do tipo string[]. Ignorando valor {0}.", + "ExecutableParser.invalidCWD": "Aviso: options.cwd deve ser do tipo string. Ignorando valor {0}." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/common/severity.i18n.json b/i18n/ptb/src/vs/base/common/severity.i18n.json new file mode 100644 index 00000000000..7aff8041180 --- /dev/null +++ b/i18n/ptb/src/vs/base/common/severity.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "sev.error": "Erro", + "sev.warning": "Aviso", + "sev.info": "Informações" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/node/processes.i18n.json b/i18n/ptb/src/vs/base/node/processes.i18n.json new file mode 100644 index 00000000000..3584dc9b15e --- /dev/null +++ b/i18n/ptb/src/vs/base/node/processes.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "TaskRunner.UNC": "Não é possível executar um comando shell em uma unidade UNC." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/node/zip.i18n.json b/i18n/ptb/src/vs/base/node/zip.i18n.json new file mode 100644 index 00000000000..a577f90ea2e --- /dev/null +++ b/i18n/ptb/src/vs/base/node/zip.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "notFound": "{0} não encontrado dentro do zip." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/parts/quickopen/browser/quickOpenModel.i18n.json b/i18n/ptb/src/vs/base/parts/quickopen/browser/quickOpenModel.i18n.json new file mode 100644 index 00000000000..1d0f7ebd47a --- /dev/null +++ b/i18n/ptb/src/vs/base/parts/quickopen/browser/quickOpenModel.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpenAriaLabelEntry": "{0}, seletor", + "quickOpenAriaLabel": "seletor" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/parts/quickopen/browser/quickOpenWidget.i18n.json b/i18n/ptb/src/vs/base/parts/quickopen/browser/quickOpenWidget.i18n.json new file mode 100644 index 00000000000..ca3d8a5266a --- /dev/null +++ b/i18n/ptb/src/vs/base/parts/quickopen/browser/quickOpenWidget.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpenAriaLabel": "Seletor rápido. Digite para filtrar resultados.", + "treeAriaLabel": "Seletor rápido" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/parts/tree/browser/treeDefaults.i18n.json b/i18n/ptb/src/vs/base/parts/tree/browser/treeDefaults.i18n.json new file mode 100644 index 00000000000..5e72c45050c --- /dev/null +++ b/i18n/ptb/src/vs/base/parts/tree/browser/treeDefaults.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "collapse": "Recolher" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/code/electron-main/menus.i18n.json b/i18n/ptb/src/vs/code/electron-main/menus.i18n.json new file mode 100644 index 00000000000..85312962c12 --- /dev/null +++ b/i18n/ptb/src/vs/code/electron-main/menus.i18n.json @@ -0,0 +1,164 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "mFile": "&&Arquivo", + "mEdit": "&&Editar", + "mSelection": "&&Seleção", + "mView": "&&Visualizar", + "mGoto": "&&Ir", + "mDebug": "&&Depurar", + "mWindow": "Janela", + "mHelp": "&&Ajuda", + "miNewWindow": "Nova &&Janela", + "mAbout": "Sobre {0}", + "mServices": "Serviços", + "mHide": "Ocultar {0}", + "mHideOthers": "Ocultar Outros", + "mShowAll": "Mostrar Tudo", + "miQuit": "Sair de {0}", + "miNewFile": "&&Novo Arquivo", + "miOpen": "&&Abrir", + "miOpenFolder": "Abrir &&Pasta", + "miOpenFile": "&&Abrir Arquivo", + "miOpenRecent": "Abrir &&Recente", + "miSave": "&&Salvar", + "miSaveAs": "Salvar &&Como...", + "miSaveAll": "Salvar &&Tudo", + "miAutoSave": "Salvar Automaticamente", + "miRevert": "Re&&verter Arquivo", + "miCloseWindow": "Fe&&char Janela", + "miCloseFolder": "Fechar &&Pasta", + "miCloseEditor": "Fechar &&Editor", + "miExit": "Sai&&r", + "miOpenSettings": "&&Configurações", + "miOpenKeymap": "Atalhos de &&Teclado", + "miOpenKeymapExtensions": "Extensões de &&Mapeamento de Teclado", + "miOpenSnippets": "Trechos de Có&&digo do Usuário", + "miSelectColorTheme": "Cor do T&&ema", + "miSelectIconTheme": "&&Ãcone de Arquivo do Tema", + "miPreferences": "&&Preferências", + "miReopenClosedEditor": "&&Reabrir Editor Fechado", + "miClearRecentOpen": "&&Limpar Arquivos Recentes", + "miUndo": "&&Desfazer", + "miRedo": "&&Refazer", + "miCut": "Cor&&tar", + "miCopy": "&&Copiar", + "miPaste": "Co&&lar", + "miFind": "&&Localizar", + "miReplace": "&&Substituir", + "miFindInFiles": "Localizar &&nos Arquivos", + "miReplaceInFiles": "Substituir &&nos Arquivos", + "miEmmetExpandAbbreviation": "Emmet: E&&xpandir Abreviação", + "miShowEmmetCommands": "E&&mmet...", + "miToggleLineComment": "&&Alternar Comentário de Linha", + "miToggleBlockComment": "Alternar Comentário de &&Bloco", + "miInsertCursorAbove": "&&Inserir cursor acima", + "miInsertCursorBelow": "Inserir cursor a&&baixo", + "miInsertCursorAtEndOfEachLineSelected": "Adicionar C&&ursores ao Final das Linhas", + "miAddSelectionToNextFindMatch": "Adicionar &&próxima ocorrência", + "miAddSelectionToPreviousFindMatch": "Adicionar ocorrência a&&nterior ", + "miSelectHighlights": "Selecionar todas as &&ocorrências", + "miCopyLinesUp": "&&Copiar linha acima", + "miCopyLinesDown": "C&&opiar linha abaixo", + "miMoveLinesUp": "Mo&&ver linha para cima", + "miMoveLinesDown": "Mover &&linha para baixo", + "miSelectAll": "&&Selecionar Tudo", + "miSmartSelectGrow": "&&Expandir seleção", + "miSmartSelectShrink": "&&Reduzir seleção", + "miViewExplorer": "&&Explorador", + "miViewSearch": "&&Pesquisar", + "miViewSCM": "S&&CM", + "miViewDebug": "&&Depurar", + "miViewExtensions": "E&&xtensões", + "miToggleOutput": "&&Saída", + "miToggleDebugConsole": "Con&&sole de Depuração", + "miToggleIntegratedTerminal": "Terminal &&Integrado", + "miMarker": "&&Problemas", + "miAdditionalViews": "&&Visualizações Adicionais", + "miCommandPalette": "&&Paleta de comando", + "miToggleFullScreen": "Alternar &&Tela Inteira", + "miToggleZenMode": "Alternar modo Zen", + "miToggleMenuBar": "Alternar &&Barra de Menus", + "miSplitEditor": "Dividir &&editor", + "miToggleEditorLayout": "Alternar &&Layout do Grupo de Editor", + "miToggleSidebar": "&&Alternar Barra Lateral", + "miMoveSidebarRight": "&&Mover a barra lateral para a direita", + "miMoveSidebarLeft": "&&Mover a barra lateral para a esquerda", + "miTogglePanel": "Alternar &&Painel", + "miHideStatusbar": "&&Ocultar Barra de Status", + "miShowStatusbar": "&&Mostrar Barra de Status", + "miHideActivityBar": "Ocultar Barra de &&Atividades", + "miShowActivityBar": "Mostrar Barra de &&Atividades", + "miToggleWordWrap": "Alternar &&Quebra de Linha", + "miToggleRenderWhitespace": "Alternar &&Renderização de Espaços em Branco", + "miToggleRenderControlCharacters": "Alternar &&Caracteres de Controle", + "miZoomIn": "&&Ampliar", + "miZoomOut": "Red&&uzir", + "miZoomReset": "&&Reinicializar Zoom", + "miBack": "&&Voltar", + "miForward": "&&Avançar", + "miNextEditor": "&&Próximo Editor", + "miPreviousEditor": "&&Editor Anterior", + "miNextEditorInGroup": "&&Próximo Editor Usado no Grupo", + "miPreviousEditorInGroup": "&&Editor Anterior Usado no Grupo", + "miSwitchEditor": "Trocar &&Editor", + "miFocusFirstGroup": "&&Primeiro Grupo", + "miFocusSecondGroup": "&&Segundo Grupo", + "miFocusThirdGroup": "&&Terceiro Grupo", + "miNextGroup": "&&Próximo Grupo", + "miPreviousGroup": "&&Grupo Anterior", + "miSwitchGroup": "Trocar &&Grupo", + "miGotoFile": "Ir para &&Arquivo...", + "miGotoSymbolInFile": "Ir para o &&Símbolo no Arquivo...", + "miGotoSymbolInWorkspace": "Ir para o Símbolo em &&Ãrea de Trabalho", + "miGotoDefinition": "Ir para &&Definição", + "miGotoTypeDefinition": "Ir para a &&definição de tipo", + "miGotoImplementation": "Ir para a &&implementação", + "miGotoLine": "Ir para &&Linha...", + "miStartDebugging": "Iniciar Depuração", + "miStartWithoutDebugging": "Iniciar &&Sem Depuração", + "miStopDebugging": "&&Parar Depuração", + "miRestart Debugging": "&&Reiniciar Depuração", + "miOpenConfigurations": "Abrir &&Configurações", + "miAddConfiguration": "Adicionar Configuração...", + "miStepOver": "Pular &&Sobre", + "miStepInto": "Pular &&Dentro", + "miStepOut": "Pular &&Fora", + "miContinue": "&&Continuar", + "miToggleBreakpoint": "Alternar &&Ponto de Parada", + "miConditionalBreakpoint": "Ponto de Parada &&Condicional...", + "miColumnBreakpoint": "Ponto de Parada de C&&oluna", + "miFunctionBreakpoint": "Ponto de Parada de &&Função...", + "miNewBreakpoint": "&&Novo Ponto de Parada", + "miDisableAllBreakpoints": "Desabilitar T&&odos os Pontos de Parada", + "miRemoveAllBreakpoints": "Remover &&Todos os Pontos de Parada", + "miInstallAdditionalDebuggers": "&&Instalar Depuradores Adicionais...", + "mMinimize": "Minimizar", + "mClose": "Fechar", + "mBringToFront": "Trazer Tudo para a Frente", + "miToggleDevTools": "&&Alternar Ferramentas do Desenvolvedor", + "miAccessibilityOptions": "&&Opções de Acessibilidade", + "miReportIssues": "Relatar &&Problemas", + "miWelcome": "&&Bem-vindo", + "miInteractivePlayground": "Playground &&Interativo", + "miDocumentation": "&&Documentação", + "miReleaseNotes": "&&Notas de Versão", + "miKeyboardShortcuts": "Referência de &&Atalhos de Teclado", + "miIntroductoryVideos": "&&Vídeos Introdutórios", + "miTwitter": "&&Junte-se a nós no Twitter", + "miUserVoice": "&&Pesquisar Solicitações de Recursos", + "miLicense": "&&Exibir Licença", + "miPrivacyStatement": "&&Política de Privacidade", + "miAbout": "&&Sobre", + "miRestartToUpdate": "Reinicie para Atualizar...", + "miCheckingForUpdates": "Verificando Atualizações...", + "miDownloadUpdate": "Baixar Atualização Disponível", + "miDownloadingUpdate": "Baixando Atualização...", + "miInstallingUpdate": "Instalando Atualização...", + "miCheckForUpdates": "Verificar Atualizações...", + "aboutDetail": "\\\\nVersão {0}\\\\nConfirmação {1}\\\\nData {2}\\\\nShell {3}\\\\nRenderizador {4}\\\\nNó {5}", + "okButton": "OK" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/code/electron-main/window.i18n.json b/i18n/ptb/src/vs/code/electron-main/window.i18n.json new file mode 100644 index 00000000000..abee584a9c1 --- /dev/null +++ b/i18n/ptb/src/vs/code/electron-main/window.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "hiddenMenuBar": "Você ainda pode acessar a barra de menu pressionando a tecla * * Alt * *." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/code/electron-main/windows.i18n.json b/i18n/ptb/src/vs/code/electron-main/windows.i18n.json new file mode 100644 index 00000000000..308aed29538 --- /dev/null +++ b/i18n/ptb/src/vs/code/electron-main/windows.i18n.json @@ -0,0 +1,22 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ok": "OK", + "pathNotExistTitle": "O caminho não existe", + "pathNotExistDetail": "O caminho '{0}' não parece mais existir no disco.", + "accessibilityOptionsWindowTitle": "Opções de Acessibilidade", + "reopen": "Reabrir", + "wait": "Continuar Esperando", + "close": "Fechar", + "appStalled": "A janela não está mais respondendo", + "appStalledDetail": "Você pode reabrir, fechar a janela ou continuar esperando.", + "appCrashed": "A janela foi fechada inesperadamente", + "appCrashedDetail": "Pedimos desculpas pelo inconveniente! Você pode reabrir a janela para continuar de onde parou.", + "newWindow": "Nova Janela", + "newWindowDesc": "Abrir uma nova janela", + "recentFolders": "Pastas Recentes", + "folderDesc": "{0} {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/code/node/cliProcessMain.i18n.json b/i18n/ptb/src/vs/code/node/cliProcessMain.i18n.json new file mode 100644 index 00000000000..ee0b74f6e41 --- /dev/null +++ b/i18n/ptb/src/vs/code/node/cliProcessMain.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "notFound": "Extensão '{0}' não encontrada.", + "notInstalled": "Extensão '{0}' não está instalada.", + "useId": "Certifique-se de usar a ID de extensão completa, incluindo o editor, por exemplo: {0}", + "successVsixInstall": "Extensão '{0}' foi instalada com sucesso!", + "alreadyInstalled": "Extensão '{0}' já está instalada.", + "foundExtension": "Encontrado '{0}' na loja VS Code.", + "installing": "Instalando...", + "successInstall": "Extensão '{0}' v {1} foi instalada com sucesso!", + "uninstalling": "Desinstalando {0}...", + "successUninstall": "Extensão '{0}' foi desinstalada com sucesso!" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/ptb/src/vs/editor/common/config/commonEditorConfig.i18n.json new file mode 100644 index 00000000000..8411a930363 --- /dev/null +++ b/i18n/ptb/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -0,0 +1,76 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorConfigurationTitle": "Editor", + "fontFamily": "Controla a família de fontes.", + "fontWeight": "Controla o peso da fonte.", + "fontSize": "Controla o tamanho da fonte em pixels.", + "lineHeight": "Controla a altura da linha. Use 0 para computar a altura da linha a partir do tamanho da fonte.", + "letterSpacing": "Controla o espaçamento da letra em pixels.", + "lineNumbers": "Controla a exibição de números de linha. Valores possíveis são 'on', 'off' e 'relative'. 'relative' mostra a contagem de linhas a partir da posição atual do cursor.", + "rulers": "Colunas nas quais mostrar réguas verticais", + "wordSeparators": "Caracteres que serão usados como separadores de palavras ao fazer navegação relacionada a palavras ou operações", + "tabSize": "O número de espaços equivalentes a uma tabulação. Esta configuração é sobreposta no conteúdo do arquivo quando `editor.detectIndentation` está ligado.", + "tabSize.errorMessage": "Esperado 'número'. Note que o valor \"auto\" foi alterado pela configuração 'editor.detectIndentation'.", + "insertSpaces": "Insere espaços quanto pressionado Tab. Esta configuração é sobrescrita com base no conteúdo do arquivo quando 'editor.detectIndentation' está habilitado.", + "insertSpaces.errorMessage": "Esperado 'booleano'. Note que o valor \"auto\" foi alterado pela configuração 'editor.detectIndentation'.", + "detectIndentation": "Quando um arquivo está sendo aberto, 'editor.tabSize' e 'editor.insertSpace' será detectado com base no conteúdo do arquivo.", + "roundedSelection": "Controla se as seleções têm cantos arredondados", + "scrollBeyondLastLine": "Controla se o editor rolará além da última linha", + "minimap.enabled": "Controla se o mini mapa é exibido", + "minimap.renderCharacters": "Renderizar os caracteres em uma linha (em oposição a blocos de caracteres)", + "minimap.maxColumn": "Limitar o tamanho de um mini-mapa para renderizar no máximo um número determinado de colunas", + "wordWrap.off": "As linhas nunca serão quebradas.", + "wordWrap.on": "As linhas serão quebradas na largura de visualização", + "wordWrap.wordWrapColumn": "As linhas serão quebradas em `editor.wordWrapColumn`.", + "wordWrap.bounded": "As linhas serão quebradas no mínimo entre a largura de visualização e `editor.wordWrapColumn`.", + "wordWrap": "Controla como as linhas devem ser quebradas automaticamente. Pode ser:\n- 'off' (quebra automática de linha desabilitada)\n- 'on' (quebra automática de linha na largura da janela)\n- 'wordWrapColumn' (quebra automática no numero de colunas definido em `editor.wordWrapColumn`) ou\n- 'bounded' (quebra automática em uma dimensão minima da janela e na largura configurada)", + "wordWrapColumn": "Controla a coluna de quebra de linha do editor quando editor.wordWrap` é 'wordWrapColumn' ou 'bounded'.", + "wrappingIndent": "Controla o recuo de linhas quebradas. Pode ser \"none\", \"same\" ou \"indent\".", + "mouseWheelScrollSensitivity": "Um multiplicador a ser usado em \"deltaX\" e \"deltaY\" dos eventos de rolagem do botão de rolagem do mouse", + "quickSuggestions.strings": "Habilitar sugestões rápidas dentro de strings.", + "quickSuggestions.comments": "Habilitar sugestões rápidas dentro de comentários.", + "quickSuggestions.other": "Habilitar sugestões rápidas fora de strings e comentários.", + "quickSuggestions": "Controlar se sugestões devem aparecer automaticamente ao digitar", + "quickSuggestionsDelay": "Controla o atraso em ms após o qual sugestões rápidas serão exibidas", + "parameterHints": "Habilita dicas de parâmetros", + "autoClosingBrackets": "Controla se o editor deve fechar colchetes automaticamente depois de abri-los", + "formatOnType": "Controla se o editor deve formatar automaticamente a linha após a digitação", + "formatOnPaste": "Controla se o editor deve formatar automaticamente o conteúdo colado. Um formatador deve estar disponível e o formatador deve ser capaz de formatar apenas uma parte do documento.", + "suggestOnTriggerCharacters": "Controla se as sugestões devem aparecer automaticamente ao digitar caracteres de gatilho", + "acceptSuggestionOnCommitCharacter": "Controla se as sugestões devem ser aceitas em caracteres de confirmação. Por exemplo, em JavaScript, o ponto-e-vírgula (';') pode ser um caractere de confirmação que aceita uma sugestão e digita esse caractere.", + "snippetSuggestions": "Controla se os snippets são exibidos juntamente com as outras sugestões e como eles são ordenados.", + "emptySelectionClipboard": "Controla se a cópia sem nenhuma seleção copia a linha atual.", + "wordBasedSuggestions": "Controla se o auto-completar deve ser calculado baseado nas palavras no documento.", + "suggestFontSize": "Tamanho da fonte para a ferramenta de sugestão", + "suggestLineHeight": "Altura de linha para a ferramenta de sugestão", + "selectionHighlight": "Controla se o editor deve realçar correspondências semelhantes à seleção", + "occurrencesHighlight": "Controla se o editor deve realçar ocorrências de símbolos semânticos.", + "overviewRulerLanes": "Controla o número de decorações que podem ser exibidas na mesma posição na régua de visão geral", + "overviewRulerBorder": "Controla se deve desenhar uma borda ao redor da régua de visão geral.", + "cursorBlinking": "Controla o estilo de animação do cursor, os valores possíveis são 'blink', 'smooth', 'phase', 'expand' e 'solid'", + "mouseWheelZoom": "Alterar o zoom da fonte editor quando utilizada a roda do mouse e pressionando Ctrl", + "cursorStyle": "Controla o estilo do cursor, os valores aceitos são 'block', 'block-outline', 'line', 'line-thin', 'underline' e 'underline-thin'", + "fontLigatures": "Habilita ligaduras de fontes", + "hideCursorInOverviewRuler": "Controla se o cursor deve ficar oculto na régua de visão geral.", + "renderWhitespace": "Controla como o editor deve rendenizar caracteres de espaços em branco, possibilidades são 'none', 'boundary' e 'all'. A opção 'boundary' não rendeniza espaços simples entre palavras.", + "renderControlCharacters": "Controla se o editor deve renderizar caracteres de controle", + "renderIndentGuides": "Controla se o editor deve renderizar guias de identação", + "renderLineHighlight": "Controla como o editor deve renderizar a linha atual, as possibilidades são 'none', 'gutter', 'line' e 'all'.", + "codeLens": "Controla se o editor exibirá a lente de códigos.", + "folding": "Controla se o editor tem codigo colapsível hablitado", + "showFoldingControls": "Controla se os controles de desdobramento na divisão são ocultas automaticamente.", + "matchBrackets": "Realça colchetes correspondente quando um deles estiver selecionado.", + "glyphMargin": "Controla se o editor deve renderizar a margem vertical de ícones. A margem vertical de ícones é usada primordialmente na depuração", + "useTabStops": "Inserção e deleção de espaço em branco seguem a tabulação", + "trimAutoWhitespace": "Remove espaços em branco inseridos automaticamente no fim da linha", + "stablePeek": "Mantém os editores de visualização abertos mesmo quando clicando seu conteúdo ou teclando Escape.", + "dragAndDrop": "Controla se o editor deve permitir mover seleções via arrastar e soltar.", + "sideBySide": "Controla se o editor de diff mostra as diff lado a lado ou inline.", + "ignoreTrimWhitespace": "Controla se o editor de diff mostra alterações nos espaços iniciais ou finais como diferenças", + "renderIndicators": "Controla se o editor de diff mostra indicadores +/- para alterações adicionadas/removidas", + "selectionClipboard": "Controla se a área primária de transferência Linux deve ser suportada." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/common/config/editorOptions.i18n.json b/i18n/ptb/src/vs/editor/common/config/editorOptions.i18n.json new file mode 100644 index 00000000000..40fed0886cc --- /dev/null +++ b/i18n/ptb/src/vs/editor/common/config/editorOptions.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorViewAccessibleLabel": "Conteúdo do editor" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/common/controller/cursor.i18n.json b/i18n/ptb/src/vs/editor/common/controller/cursor.i18n.json new file mode 100644 index 00000000000..60bcb5f5b5a --- /dev/null +++ b/i18n/ptb/src/vs/editor/common/controller/cursor.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "corrupt.commands": "Exceção inesperada ao executar o comando." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/common/model/textModelWithTokens.i18n.json b/i18n/ptb/src/vs/editor/common/model/textModelWithTokens.i18n.json new file mode 100644 index 00000000000..fc3574b7fde --- /dev/null +++ b/i18n/ptb/src/vs/editor/common/model/textModelWithTokens.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "mode.tokenizationSupportFailed": "O modo falhou ao gerar token da entrada." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/common/modes/modesRegistry.i18n.json b/i18n/ptb/src/vs/editor/common/modes/modesRegistry.i18n.json new file mode 100644 index 00000000000..509203220c8 --- /dev/null +++ b/i18n/ptb/src/vs/editor/common/modes/modesRegistry.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "plainText.alias": "Texto sem formatação" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/common/services/bulkEdit.i18n.json b/i18n/ptb/src/vs/editor/common/services/bulkEdit.i18n.json new file mode 100644 index 00000000000..3fada6ebf53 --- /dev/null +++ b/i18n/ptb/src/vs/editor/common/services/bulkEdit.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "conflict": "Estes arquivos foram alterados nesse meio tempo: {0}", + "summary.0": "Não foram feitas edições", + "summary.nm": "Feitas {0} edições de texto em {1} arquivos", + "summary.n0": "Feitas {0} edições de texto em um arquivo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/common/services/modeServiceImpl.i18n.json b/i18n/ptb/src/vs/editor/common/services/modeServiceImpl.i18n.json new file mode 100644 index 00000000000..85f2d2943f6 --- /dev/null +++ b/i18n/ptb/src/vs/editor/common/services/modeServiceImpl.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.languages": "Contribui às declarações de linguagem.", + "vscode.extension.contributes.languages.id": "ID da linguagem", + "vscode.extension.contributes.languages.aliases": "Aliases de nome para esta linguagem.", + "vscode.extension.contributes.languages.extensions": "Extensões de arquivos associadas a esta linguagem", + "vscode.extension.contributes.languages.filenames": "Nome dos arquivos associados a esta linguagem", + "vscode.extension.contributes.languages.filenamePatterns": "Padrão glob de nomes de arquivos associados a linguagem.", + "vscode.extension.contributes.languages.mimetypes": "Tipos Mime associados à linguagem.", + "vscode.extension.contributes.languages.firstLine": "Uma expressão regular que coincide com a primeira linha de um arquivo da linguaguem.", + "vscode.extension.contributes.languages.configuration": "Um caminho relativo para um arquivo contendo opções de configuração para a linguagem." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/common/services/modelServiceImpl.i18n.json b/i18n/ptb/src/vs/editor/common/services/modelServiceImpl.i18n.json new file mode 100644 index 00000000000..b6c528c5a25 --- /dev/null +++ b/i18n/ptb/src/vs/editor/common/services/modelServiceImpl.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "diagAndSourceMultiline": "[{0}] {1}", + "diagAndSource": "[{0}] {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/common/view/editorColorRegistry.i18n.json b/i18n/ptb/src/vs/editor/common/view/editorColorRegistry.i18n.json new file mode 100644 index 00000000000..8d59b0fcb7d --- /dev/null +++ b/i18n/ptb/src/vs/editor/common/view/editorColorRegistry.i18n.json @@ -0,0 +1,20 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "lineHighlight": "Cor de fundo para a posição do cursor na seleção de linhas.", + "lineHighlightBorderBox": "Cor de fundo para a borda em volta da linha na posição do cursor", + "rangeHighlight": "Cor de fundo dos ranges selecionados, assim como abertura instantânea e descoberta de recursos ", + "caret": "Cor do cursor no editor.", + "editorWhitespaces": "Cor dos caracteres em branco no editor", + "editorIndentGuides": "Cor das guias de indentação do editor.", + "editorLineNumbers": "Cor dos números de linha do editor.", + "editorRuler": "Cor das réguas do editor.", + "editorCodeLensForeground": "Cor do primeiro plano das lentes de código do editor", + "editorBracketMatchBackground": "Cor de fundo atrás do colchetes correspondentes", + "editorBracketMatchBorder": "Cor para as caixas de colchetes correspondentes", + "editorOverviewRulerBorder": "Cor da borda da régua de visão geral.", + "editorGutter": "Cor de fundo da separação do editor.O separador contém os glifos das margens e os números de linha." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/accessibility/browser/accessibility.i18n.json b/i18n/ptb/src/vs/editor/contrib/accessibility/browser/accessibility.i18n.json new file mode 100644 index 00000000000..e045839f7c6 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/accessibility/browser/accessibility.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "introMsg": "Obrigado por testar a opção de acessibilidade do VS Code.", + "status": "Status", + "tabFocusModeOnMsg": "Pressionando Tab no editor corrente irá mover o foco para o próximo elemento focável. Mude este comportamento ao pressionar {0}.", + "tabFocusModeOnMsgNoKb": "Pressionando Tab no editor corrente irá mover o foco para o próximo elemento focável. O comando {0} não pode ser ativado atualmente por uma tecla.", + "tabFocusModeOffMsg": "Pressionando Tab no editor atual irá inserir um caractere Tab. Mude este comportamente ao pressionar {0}.", + "tabFocusModeOffMsgNoKb": "Pressionando Tab no editor atual irá inserir um caractere Tab. O comando {0} não pode ser ativado atualmente por uma tecla.", + "outroMsg": "Você pode ignorar essa dica e retornar ao editor apertando a tecla ESC", + "ShowAccessibilityHelpAction": "Mostrar ajuda de acessibilidade" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/bracketMatching/common/bracketMatching.i18n.json b/i18n/ptb/src/vs/editor/contrib/bracketMatching/common/bracketMatching.i18n.json new file mode 100644 index 00000000000..4af1753636d --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/bracketMatching/common/bracketMatching.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "smartSelect.jumpBracket": "Ir para colchete" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/caretOperations/common/caretOperations.i18n.json b/i18n/ptb/src/vs/editor/contrib/caretOperations/common/caretOperations.i18n.json new file mode 100644 index 00000000000..157105c4a35 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/caretOperations/common/caretOperations.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "caret.moveLeft": "Mover cursor para a esquerda", + "caret.moveRight": "Mover cursor para a direita" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/caretOperations/common/transpose.i18n.json b/i18n/ptb/src/vs/editor/contrib/caretOperations/common/transpose.i18n.json new file mode 100644 index 00000000000..c1d3083b198 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/caretOperations/common/transpose.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "transposeLetters.label": "Transport letras" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/clipboard/browser/clipboard.i18n.json b/i18n/ptb/src/vs/editor/contrib/clipboard/browser/clipboard.i18n.json new file mode 100644 index 00000000000..903f9fc1086 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/clipboard/browser/clipboard.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "actions.clipboard.cutLabel": "Recortar", + "actions.clipboard.copyLabel": "Copiar", + "actions.clipboard.pasteLabel": "Colar", + "actions.clipboard.copyWithSyntaxHighlightingLabel": "Copiar com realce de sintaxe" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/comment/common/comment.i18n.json b/i18n/ptb/src/vs/editor/contrib/comment/common/comment.i18n.json new file mode 100644 index 00000000000..ff1ba569c0c --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/comment/common/comment.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "comment.line": "Alternar Comentário de Linha", + "comment.line.add": "Adicionar Comentário de Linha", + "comment.line.remove": "Remover Comentário de Linha", + "comment.block": "Alternar Comentário de Bloco" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/contextmenu/browser/contextmenu.i18n.json b/i18n/ptb/src/vs/editor/contrib/contextmenu/browser/contextmenu.i18n.json new file mode 100644 index 00000000000..e2b1d946bee --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/contextmenu/browser/contextmenu.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "action.showContextMenu.label": "Mostrar o menu de contexto do editor" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/find/browser/findWidget.i18n.json b/i18n/ptb/src/vs/editor/contrib/find/browser/findWidget.i18n.json new file mode 100644 index 00000000000..473543c0850 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/find/browser/findWidget.i18n.json @@ -0,0 +1,21 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "label.find": "Localizar", + "placeholder.find": "Localizar", + "label.previousMatchButton": "Correspondência anterior", + "label.nextMatchButton": "Próxima correspondência", + "label.toggleSelectionFind": "Localizar na seleção", + "label.closeButton": "Fechar", + "label.replace": "Substituir", + "placeholder.replace": "Substituir", + "label.replaceButton": "Substituir", + "label.replaceAllButton": "Substituir Tudo", + "label.toggleReplaceButton": "Ativar/desativar modo Substituir", + "title.matchesCountLimit": "Somente os primeiros 999 resultados são realçados, mas todas as operações de pesquisa funcionam em todo o texto.", + "label.matchesLocation": "{0} de {1}", + "label.noResults": "Nenhum resultado" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/find/common/findController.i18n.json b/i18n/ptb/src/vs/editor/contrib/find/common/findController.i18n.json new file mode 100644 index 00000000000..07397efa5fe --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/find/common/findController.i18n.json @@ -0,0 +1,19 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "startFindAction": "Localizar", + "findNextMatchAction": "Localizar Próximo", + "findPreviousMatchAction": "Localizar anterior", + "nextSelectionMatchFindAction": "Localizar Próxima Seleção", + "previousSelectionMatchFindAction": "Localizar Seleção Anterior", + "startReplace": "Substituir", + "addSelectionToNextFindMatch": "Adicionar Seleção ao Próximo Localizar Correspondência", + "addSelectionToPreviousFindMatch": "Adicionar Seleção à Correspondência de Localização Anterior", + "moveSelectionToNextFindMatch": "Mover Última Seleção para Próximo Localizar Correspondência", + "moveSelectionToPreviousFindMatch": "Mover Última Seleção para Correspondência de Localização Anterior", + "selectAllOccurencesOfFindMatch": "Selecionar Todas as Ocorrências de Localizar Correspondência", + "changeAll.label": "Alterar todas as ocorrências" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/folding/browser/folding.i18n.json b/i18n/ptb/src/vs/editor/contrib/folding/browser/folding.i18n.json new file mode 100644 index 00000000000..c9d6b88a852 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/folding/browser/folding.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "unfoldAction.label": "Abrir", + "unFoldRecursivelyAction.label": "Abrir recursivamente", + "foldAction.label": "Colapsar", + "foldRecursivelyAction.label": "Colapsar recursivamente", + "foldAllAction.label": "Colapsar tudo", + "unfoldAllAction.label": "Abrir tudo", + "foldLevelAction.label": "Nível de colapsamento {0}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/format/browser/formatActions.i18n.json b/i18n/ptb/src/vs/editor/contrib/format/browser/formatActions.i18n.json new file mode 100644 index 00000000000..4327e5f6744 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/format/browser/formatActions.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "hint11": "1 edição de formatação feita na linha {0}", + "hintn1": "{0} edições de formatação feitas na linha {1}", + "hint1n": "Feita 1 edição de formatação entre as linhas {0} e {1}", + "hintnn": "Feitas {0} edições de formatação entre as linhas {1} e {2}", + "formatDocument.label": "Formatar Documento", + "formatSelection.label": "Formatar Seleção" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/ptb/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..01753366bca --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "Não foi encontrada definição para '{0}'", + "generic.noResults": "Nenhuma definição encontrada", + "meta.title": "- {0} definições", + "actions.goToDecl.label": "Ir para Definição", + "actions.goToDeclToSide.label": "Abrir definição ao lado", + "actions.previewDecl.label": "Inspecionar definição", + "goToImplementation.noResultWord": "Nenhuma implementação encontrada para '{0}'", + "goToImplementation.generic.noResults": "Nenhuma implementação encontrada", + "meta.implementations.title": "– {0} implementações", + "actions.goToImplementation.label": "Ir para a implementação", + "actions.peekImplementation.label": "Inspecionar implementação", + "goToTypeDefinition.noResultWord": "Nenhuma definição encontrada para '{0}'", + "goToTypeDefinition.generic.noResults": "Nenhuma definição de tipo encontrada", + "meta.typeDefinitions.title": "– {0} definições de tipos", + "actions.goToTypeDefinition.label": "Ir para a definição de tipo", + "actions.peekTypeDefinition.label": "Inspecionar definição de tipo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/ptb/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..675cbe29ae1 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "Clique para mostrar {0} definições." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json b/i18n/ptb/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json new file mode 100644 index 00000000000..0ad65de8863 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "title.wo_source": "({0}/{1})", + "markerAction.next.label": "Ir para o Próximo Erro ou Aviso", + "markerAction.previous.label": "Ir para o Erro ou Aviso Anterior", + "editorMarkerNavigationError": "Ferramenta de marcação de edição apresentando error na cor ", + "editorMarkerNavigationWarning": "Ferramenta de marcação de edição apresentando adventência na cor", + "editorMarkerNavigationBackground": "Cor de fundo da ferramenta de marcação de navegação do editor." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/hover/browser/hover.i18n.json b/i18n/ptb/src/vs/editor/contrib/hover/browser/hover.i18n.json new file mode 100644 index 00000000000..196a8fb2bb0 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/hover/browser/hover.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "showHover": "Mostrar Item Flutuante" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/hover/browser/modesContentHover.i18n.json b/i18n/ptb/src/vs/editor/contrib/hover/browser/modesContentHover.i18n.json new file mode 100644 index 00000000000..2c74cf6f1ec --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/hover/browser/modesContentHover.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "modesContentHover.loading": "Carregando..." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.i18n.json b/i18n/ptb/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.i18n.json new file mode 100644 index 00000000000..fbbfbd02161 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "InPlaceReplaceAction.previous.label": "Substituir pelo valor anterior", + "InPlaceReplaceAction.next.label": "Substituir pelo próximo valor" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/indentation/common/indentation.i18n.json b/i18n/ptb/src/vs/editor/contrib/indentation/common/indentation.i18n.json new file mode 100644 index 00000000000..8edeaaf8104 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/indentation/common/indentation.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "indentationToSpaces": "Converter indentação em espaços.", + "indentationToTabs": "Coverter Indentação a Tabulações.", + "configuredTabSize": "Tamanho de Tabulação Configurado", + "selectTabWidth": "Selecione o Tamanho de Tabulação para o Arquivo Atual", + "indentUsingTabs": "Indentar Usando Tabulações", + "indentUsingSpaces": "Indentar Usando Espaços", + "detectIndentation": "Detectar Indentação a Partir do Conteúdo", + "editor.reindentlines": "Reindentar Linhas" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes.i18n.json b/i18n/ptb/src/vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes.i18n.json new file mode 100644 index 00000000000..e715c4d667f --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "inspectTMScopes": "Desenvolvedor: Inspecionar escopos TM", + "inspectTMScopesWidget.loading": "Carregando..." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/linesOperations/common/linesOperations.i18n.json b/i18n/ptb/src/vs/editor/contrib/linesOperations/common/linesOperations.i18n.json new file mode 100644 index 00000000000..8a368ab368d --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/linesOperations/common/linesOperations.i18n.json @@ -0,0 +1,25 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "lines.copyUp": "Copiar linha acima", + "lines.copyDown": "Copiar linha abaixo", + "lines.moveUp": "Mover linha para cima", + "lines.moveDown": "Mover linha para baixo", + "lines.sortAscending": "Classificar Linhas Ascendentemente", + "lines.sortDescending": "Classificar Linhas Descendentemente", + "lines.trimTrailingWhitespace": "Cortar Espaço em Branco à Direita", + "lines.delete": "Excluir linha", + "lines.indent": "Recuar linha", + "lines.outdent": "Recuar linha para a esquerda", + "lines.insertBefore": "Inserir linha acima", + "lines.insertAfter": "Inserir linha abaixo", + "lines.deleteAllLeft": "Excluir tudo à Esquerda", + "lines.deleteAllRight": "Excluir Tudo à Direita", + "lines.joinLines": "Unir Linhas", + "editor.transpose": "Transpor caracteres ao redor do cursor", + "editor.transformToUppercase": "Transformar para maiúsculas", + "editor.transformToLowercase": "Transformar para minúsculas" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/links/browser/links.i18n.json b/i18n/ptb/src/vs/editor/contrib/links/browser/links.i18n.json new file mode 100644 index 00000000000..64628273f2a --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/links/browser/links.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "links.navigate.mac": "Cmd + clique para seguir o link", + "links.navigate": "Ctrl + clique para seguir o link", + "invalid.url": "Desculpe, falha ao abrir este link porque ele não está bem formatado: {0}", + "missing.url": "Desculpe, falha ao abrir este link porque seu destino está faltando.", + "label": "Abrir link" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/multicursor/common/multicursor.i18n.json b/i18n/ptb/src/vs/editor/contrib/multicursor/common/multicursor.i18n.json new file mode 100644 index 00000000000..583be5b3e5c --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/multicursor/common/multicursor.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "mutlicursor.insertAbove": "Inserir cursor acima", + "mutlicursor.insertBelow": "Inserir cursor abaixo", + "mutlicursor.insertAtEndOfEachLineSelected": "Adicionar Cursores ao Final das Linhas" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/parameterHints/browser/parameterHints.i18n.json b/i18n/ptb/src/vs/editor/contrib/parameterHints/browser/parameterHints.i18n.json new file mode 100644 index 00000000000..f0450d3f4de --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/parameterHints/browser/parameterHints.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "parameterHints.trigger.label": "Dicas de parâmetro de gatilho" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.i18n.json b/i18n/ptb/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.i18n.json new file mode 100644 index 00000000000..0f8237adbb3 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "hint": "{0}, dica" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/quickFix/browser/quickFixCommands.i18n.json b/i18n/ptb/src/vs/editor/contrib/quickFix/browser/quickFixCommands.i18n.json new file mode 100644 index 00000000000..01ae8d7aff8 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/quickFix/browser/quickFixCommands.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickFixWithKb": "Mostrar correções ({0})", + "quickFix": "Mostrar correções", + "quickfix.trigger.label": "Correção Rápida" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.i18n.json b/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.i18n.json new file mode 100644 index 00000000000..9d557535df6 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "meta.titleReference": "- {0} referências", + "references.action.label": "Localizar Todas as Referências" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesController.i18n.json b/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesController.i18n.json new file mode 100644 index 00000000000..65217d2ace8 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesController.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "labelLoading": "Carregando..." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json b/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json new file mode 100644 index 00000000000..47c3685850e --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "aria.oneReference": "símbolo em {0} na linha {1} e coluna {2}", + "aria.fileReferences.1": "1 símbolo em {0}", + "aria.fileReferences.N": "{0} símbolos em {1}", + "aria.result.0": "Nenhum resultado encontrado", + "aria.result.1": "Encontrado 1 símbolo em {0}", + "aria.result.n1": "Encontrados {0} símbolos em {1}", + "aria.result.nm": "Encontrados {0} símbolos em {1} arquivos" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json b/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json new file mode 100644 index 00000000000..72f61eeaf83 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json @@ -0,0 +1,27 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "referencesFailre": "Falha ao resolver arquivo.", + "referencesCount": "{0} referências", + "referenceCount": "{0} referência", + "missingPreviewMessage": "nenhuma visualização disponível", + "treeAriaLabel": "Referências", + "noResults": "Nenhum resultado", + "peekView.alternateTitle": "Referências", + "peekViewTitleBackground": "Cor de fundo da área de visualização do título.", + "peekViewTitleForeground": "Cor de visualização do título.", + "peekViewTitleInfoForeground": "Cor da visualização de informações do título.", + "peekViewBorder": "Cor das bordas e seta da área de visualização", + "peekViewResultsBackground": "Cor de fundo da área de visualização da lista de resultados.", + "peekViewResultsMatchForeground": "Cor de primeiro plano para nós de linha na lista de resultados visualizados.", + "peekViewResultsFileForeground": "Cor de primeiro plano para nós de arquivos na lista de resultados visualizados.", + "peekViewResultsSelectionBackground": "Cor de fundo da entrada selecionada na visualização da lista de resultados.", + "peekViewResultsSelectionForeground": "Cor da entrada selecionada na visualização da lista de resultados.", + "peekViewEditorBackground": "Cor de fundo da visualização do editor.", + "peekViewEditorGutterBackground": "Cor de fundo da separação na visualização rápida do editor.", + "peekViewResultsMatchHighlight": "Corresponder cor de realce com visualização da lista de resultados.", + "peekViewEditorMatchHighlight": "Corresponder cor de realce com visualização do editor." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/rename/browser/rename.i18n.json b/i18n/ptb/src/vs/editor/contrib/rename/browser/rename.i18n.json new file mode 100644 index 00000000000..a56535f6241 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/rename/browser/rename.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "no result": "Nenhum resultado.", + "aria": "Renomeado '{0}' para '{1}'com sucesso. Resumo: {2}", + "rename.failed": "Desculpe, falha na execução de renomear.", + "rename.label": "Renomear Símbolo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/rename/browser/renameInputField.i18n.json b/i18n/ptb/src/vs/editor/contrib/rename/browser/renameInputField.i18n.json new file mode 100644 index 00000000000..49eba92fa44 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/rename/browser/renameInputField.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "renameAriaLabel": "Renomear entrada. Digite o novo nome e tecle Enter para gravar." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/smartSelect/common/smartSelect.i18n.json b/i18n/ptb/src/vs/editor/contrib/smartSelect/common/smartSelect.i18n.json new file mode 100644 index 00000000000..89319f9a266 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/smartSelect/common/smartSelect.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "smartSelect.grow": "Expandir seleção", + "smartSelect.shrink": "Reduzir seleção" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/suggest/browser/suggestController.i18n.json b/i18n/ptb/src/vs/editor/contrib/suggest/browser/suggestController.i18n.json new file mode 100644 index 00000000000..b064152c8be --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/suggest/browser/suggestController.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "arai.alert.snippet": "Ao aceitar '{0}' foi inserido o seguinte texto: {1}", + "suggest.trigger.label": "Sugestão de gatilho" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json b/i18n/ptb/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json new file mode 100644 index 00000000000..c9da4793d67 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json @@ -0,0 +1,21 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorSuggestWidgetBackground": "Cor de fundo para a ferramenta de sugestão.", + "editorSuggestWidgetBorder": "Cor da borda para a ferramenta de sugestão.", + "editorSuggestWidgetForeground": "Cor de primeiro plano para a ferramenta de sugestão.", + "editorSuggestWidgetSelectedBackground": "Cor de fundo da entrada selecionada da ferramenta de sugestões.", + "editorSuggestWidgetHighlightForeground": "Cor de realce da correspondência na ferramenta de sugestão.", + "readMore": "Ler Mais...{0}", + "suggestionWithDetailsAriaLabel": "{0}, sugestão, tem detalhes", + "suggestionAriaLabel": "{0}, sugestão", + "readLess": "Ler menos... {0}", + "suggestWidget.loading": "Carregando...", + "suggestWidget.noSuggestions": "Nenhuma sugestão.", + "suggestionAriaAccepted": "{0}, aceito", + "ariaCurrentSuggestionWithDetails": "{0}, sugestão, tem detalhes", + "ariaCurrentSuggestion": "{0}, sugestão" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode.i18n.json b/i18n/ptb/src/vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode.i18n.json new file mode 100644 index 00000000000..0f3dd068095 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggle.tabMovesFocus": "Alterne o uso da tecla Tab para mover o foco" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.i18n.json b/i18n/ptb/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.i18n.json new file mode 100644 index 00000000000..e8556cb38a8 --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "wordHighlight": "Cor de fundo de um símbolo durante acesso de leitura, como ao ler uma variável.", + "wordHighlightStrong": "Cor de fundo de um símbolo durante acesso de escrita, como ao escrever uma variável." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.i18n.json b/i18n/ptb/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.i18n.json new file mode 100644 index 00000000000..41ad7313b7d --- /dev/null +++ b/i18n/ptb/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "label.close": "Fechar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/electron-browser/textMate/TMSyntax.i18n.json b/i18n/ptb/src/vs/editor/electron-browser/textMate/TMSyntax.i18n.json new file mode 100644 index 00000000000..dfef3cc47a5 --- /dev/null +++ b/i18n/ptb/src/vs/editor/electron-browser/textMate/TMSyntax.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "invalid.language": "Linguagem desconhecida em `contributes.{0}.language`. Valor fornecido: {1}", + "invalid.scopeName": "Esperada uma string em 'contributes.{0}.scopeName'. Valor informado: {1}", + "invalid.path.0": "Esperada uma string em `contributes.{0}.path`. Valor informado: {1}", + "invalid.injectTo": "Valor inválido em `contributes.{0}.injectTo`. Deve ser uma matriz de nomes de escopo de idioma. Valor fornecido: {1}", + "invalid.embeddedLanguages": "Valor inválido em `contributes.{0}.embeddedLanguages`. Deve ser um objeto de mapeamento do nome do escopo para a linguagem. Valor informado: {1}", + "invalid.path.1": "É esperado que `contributes.{0}.path` ({1}) seja incluído na pasta da extensão ({2}). Isto pode tornar a extensão não portável.", + "no-tm-grammar": "Nenhuma gramática TM registrada para este idioma." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json b/i18n/ptb/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json new file mode 100644 index 00000000000..04aa2bc703f --- /dev/null +++ b/i18n/ptb/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "parseErrors": "Erros parseando {0}: {1}", + "schema.openBracket": "O colchete de abertura de caractere ou sequência de caracteres.", + "schema.closeBracket": "O colchete de fechamento de caractere ou sequência de caracteres.", + "schema.comments": "Define o símbolo dos comentários", + "schema.blockComments": "Define como comentários em bloco são marcados.", + "schema.blockComment.begin": "A sequência de caracteres que inicia um comentário em bloco.", + "schema.blockComment.end": "A sequência de caracteres que termina um comentário de bloco.", + "schema.lineComment": "A sequência de caracteres que inicia um comentário de linha.", + "schema.brackets": "Define os símbolos de colchetes que aumentam ou diminuem a indentação.", + "schema.autoClosingPairs": "Define os pares de colchetes. Quando é introduzido um colchete de abertura, o colchete de fechamento é inserido automaticamente.", + "schema.autoClosingPairs.notIn": "Define uma lista de escopos onde os auto pares são desativados.", + "schema.surroundingPairs": "Define os pares de colchetes que podem ser usados para cercar uma seqüência selecionada.", + "schema.wordPattern": "A definição da palavra para a linguagem.", + "schema.wordPattern.pattern": "O padrão RegExp usado para coincidir com as palavras.", + "schema.wordPattern.flags": "Os sinalizadores RegExp usados para coincidir com as palavras.", + "schema.wordPattern.flags.errorMessage": "Deve corresponder ao padrão `/^([gimuy]+)$/`." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/node/textMate/TMGrammars.i18n.json b/i18n/ptb/src/vs/editor/node/textMate/TMGrammars.i18n.json new file mode 100644 index 00000000000..7707ea3401f --- /dev/null +++ b/i18n/ptb/src/vs/editor/node/textMate/TMGrammars.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.grammars": "Contibui aos toquenizadores textmate", + "vscode.extension.contributes.grammars.language": "Identificador da linguagem para qual a sintaxe contribui.", + "vscode.extension.contributes.grammars.scopeName": "Nome do escopo Textmate usado pelo arquivo tmLanguage.", + "vscode.extension.contributes.grammars.path": "Caminho para o arquivo tmLanguage. O caminho é relativo a pasta da extensão e geralmente começa com './syntaxes/'.", + "vscode.extension.contributes.grammars.embeddedLanguages": "Um mapeamento no nome do escopo para o Id da linguagem se esta gramática contenha linguagens embutidas.", + "vscode.extension.contributes.grammars.injectTo": "Lista de nomes de escopos de linguagem aos quais esta gramática é injetada." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/actions/browser/menuItemActionItem.i18n.json b/i18n/ptb/src/vs/platform/actions/browser/menuItemActionItem.i18n.json new file mode 100644 index 00000000000..e64a7d0ed09 --- /dev/null +++ b/i18n/ptb/src/vs/platform/actions/browser/menuItemActionItem.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "titleAndKb": "{0} ({1})" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json b/i18n/ptb/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json new file mode 100644 index 00000000000..a8ef6175a09 --- /dev/null +++ b/i18n/ptb/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json @@ -0,0 +1,41 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "requirearray": "os itens de menu devem ser um array", + "requirestring": "a propriedade `{0}` é obrigatória e deve ser do tipo `string`", + "optstring": "a propriedade `{0}` é opcional ou deve ser do tipo `string`", + "vscode.extension.contributes.menuItem.command": "Identificador do comando para ser executado. O comando deve ser declarado na seção de 'Comandos'", + "vscode.extension.contributes.menuItem.alt": "O identificador de um comando alternativo para executar. O comando deve ser declarado na sessão 'Comandos'", + "vscode.extension.contributes.menuItem.when": "Condição, que deve ser verdadeira, para mostrar esse item", + "vscode.extension.contributes.menuItem.group": "Grupo ao qual pertence este comando", + "vscode.extension.contributes.menus": "Contribui itens de menu ao editor", + "menus.commandPalette": "Paleta de comandos", + "menus.editorTitle": "Meno do título editor", + "menus.editorContext": "Mostrar o menu de contexto do editor", + "menus.explorerContext": "Menu no contexto de explorador de arquivos", + "menus.editorTabContext": "Mostrar o menu de contexto do editor", + "menus.debugCallstackContext": "O menu de contexto de pilha de chamadas de depuração", + "menus.scmTitle": "O menu de título do controle de fonte", + "menus.resourceGroupContext": "O menu de contexto do grupo de recursos de controle de fonte", + "menus.resourceStateContext": "O menu de contexto de estado de recursos do controle de fonte", + "nonempty": "Esperado um valor não vazio", + "opticon": "a propriedade '{0}' é opcional ou pode ser do tipo 'string'", + "requireStringOrObject": "a propriedade '{0}' é obrigatória e deve ser do tipo 'string'", + "requirestrings": "a propriedade `{0}` é obrigatória e deve ser do tipo `string`", + "vscode.extension.contributes.commandType.command": "Indentificador de comando para executar", + "vscode.extension.contributes.commandType.title": "Título para o qual o comando é representado na UI", + "vscode.extension.contributes.commandType.category": "(Opcional) Sequência de categoria será agrupada na interface de usuário", + "vscode.extension.contributes.commandType.icon": "(Opcional) Icone utilizado para representar o comando na interface de usuário. Um arquivo ou configuração do tema.", + "vscode.extension.contributes.commandType.icon.light": "Caminho do Ãcone quando o tema light for utilizado", + "vscode.extension.contributes.commandType.icon.dark": "Caminho do ícone quando o tema dark for utilizado", + "vscode.extension.contributes.commands": "Contribui comandos à paleta de comandos", + "dup": "Comando '{0}' aparece multiplas vezes na sessão 'comandos'\n", + "menuId.invalid": "'{0}' nao é um identificador de menu válido ", + "missing.command": "Identificador do comando para ser executado. O comando deve ser declarado na seção de 'Comandos'", + "missing.altCommand": "Referências ao item de menu no alt-command '{0}' qual nao é definido na sessão 'comandos'", + "dupe.command": "Itens de referencias do mesmo comando como padrão e alt-command", + "nosupport.altCommand": "Desculpe, mas atualmente somente o groupo 'navegação' do menu 'editor/título' suporta alt-commands" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/configuration/common/configurationRegistry.i18n.json b/i18n/ptb/src/vs/platform/configuration/common/configurationRegistry.i18n.json new file mode 100644 index 00000000000..928f36b2ee4 --- /dev/null +++ b/i18n/ptb/src/vs/platform/configuration/common/configurationRegistry.i18n.json @@ -0,0 +1,19 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defaultConfigurations.title": "Sobreposições da Configuração Padrão", + "overrideSettings.description": "Definir que configurações do editor sejam substituídas para idioma {0}.", + "overrideSettings.defaultDescription": "Definir que configurações do editor sejam substituídas para um idioma.", + "vscode.extension.contributes.configuration": "Contribui às definições de configuração.", + "vscode.extension.contributes.configuration.title": "Um resumo das configurações. Este rótulo será usado no arquivo de configurações como um comentário de separação.", + "vscode.extension.contributes.configuration.properties": "Descrição das propriedades de configuração.", + "config.property.languageDefault": "Não é possível registrar '{0}'. Isto corresponde a propriedade padrão '\\\\[.*\\\\]$' para descrever configurações do editor específico de linguagem. Use a contribuição 'configurationDefaults'.", + "config.property.duplicate": "Não é possível registrar '{0}'. Esta propriedade já está registrada.", + "invalid.properties": "'configuration.properties' deve ser um objeto", + "invalid.type": "Se definido, 'configuration.type' deve ser do tipo 'object'", + "invalid.title": "'configuration.title' deve ser um string", + "vscode.extension.contributes.defaultConfiguration": "Contribui às definições de configuração padrão do editor por linguagem." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/environment/node/argv.i18n.json b/i18n/ptb/src/vs/platform/environment/node/argv.i18n.json new file mode 100644 index 00000000000..4cec19113d2 --- /dev/null +++ b/i18n/ptb/src/vs/platform/environment/node/argv.i18n.json @@ -0,0 +1,32 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "gotoValidation": "Argumentos no modo '--goto' deve ser no formato de 'Arquivo(:LINHA(:CARACTERE))'.", + "diff": "Abrir um editor de diff. Requer passar dois caminhos de arquivo como argumentos.", + "goto": "Abra o arquivo no caminho, na linha e caractere (addcionar:linha[:caractere] para o caminho).", + "locale": "Para localização utilize (ex. en-US ou zh-TW).", + "newWindow": "Força uma nova instância do Código.", + "performance": "Comece com o 'Desenvolvedor: Desempenho de inicialização' comando habilitado.", + "prof-startup": "Rodar o CPU profiler durante a inicialização", + "reuseWindow": "Forçar a abertura de um arquivo ou pasta na última janela ativa", + "userDataDir": "Especifica o diretório que os dados do usuário serão mantidos, útil quando estiver rodando como root.", + "verbose": "Imprimir a saída detalhada (Implica -- esperar).", + "wait": "Aguarde a janela ser fechada antes de retornar.", + "extensionHomePath": "Defina o caminho raíz para as extensões.", + "listExtensions": "Lista de extensões instaladas", + "showVersions": "Exibir versões de extensões instaladas, quando estiver usando --list-extension", + "installExtension": "Instala uma extensão.", + "uninstallExtension": "Desinstala uma extensão.", + "experimentalApis": "Permite recursos de api propostos para uma extensão.", + "disableExtensions": "Desabilita todas as extensões instaladas.", + "disableGPU": "Desabilita aceleração de hardware da GPU.", + "version": "Versão de impressão", + "help": "Uso de impressão.", + "usage": "Uso", + "options": "opções", + "paths": "caminhos", + "optionsUpperCase": "Opções" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/extensionManagement/common/extensionEnablementService.i18n.json b/i18n/ptb/src/vs/platform/extensionManagement/common/extensionEnablementService.i18n.json new file mode 100644 index 00000000000..52f37b66ccd --- /dev/null +++ b/i18n/ptb/src/vs/platform/extensionManagement/common/extensionEnablementService.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noWorkspace": "Não há espaço de trabalho." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/extensionManagement/common/extensionManagement.i18n.json b/i18n/ptb/src/vs/platform/extensionManagement/common/extensionManagement.i18n.json new file mode 100644 index 00000000000..33ea8261326 --- /dev/null +++ b/i18n/ptb/src/vs/platform/extensionManagement/common/extensionManagement.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "extensions": "Extensões", + "preferences": "Preferências" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/extensionManagement/node/extensionGalleryService.i18n.json b/i18n/ptb/src/vs/platform/extensionManagement/node/extensionGalleryService.i18n.json new file mode 100644 index 00000000000..76dc4cf48f3 --- /dev/null +++ b/i18n/ptb/src/vs/platform/extensionManagement/node/extensionGalleryService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "notFound": "Extensão não encontrada", + "noCompatible": "Não foi possível econtrar uma versão de {0} com esta versão do Code." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/extensionManagement/node/extensionManagementService.i18n.json b/i18n/ptb/src/vs/platform/extensionManagement/node/extensionManagementService.i18n.json new file mode 100644 index 00000000000..a6c5a37ab05 --- /dev/null +++ b/i18n/ptb/src/vs/platform/extensionManagement/node/extensionManagementService.i18n.json @@ -0,0 +1,22 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "invalidManifest": "Extensão inválida: pacote.json nao é um arquivo JSON válido", + "restartCode": "Por favor reinicie Code antes de reinstalar {0}.", + "installDependeciesConfirmation": "A instalação de '{0}' também inclui suas dependências. Gostaria de continuar?", + "install": "Sim", + "doNotInstall": "Não", + "uninstallDependeciesConfirmation": "Gostaria de desinstalar '{0}' somente, ou suas dependências também?", + "uninstallOnly": "Apenas", + "uninstallAll": "Todos", + "cancel": "Cancelar", + "uninstallConfirmation": "Tem certeza que deseja desinstalar '{0}'?", + "ok": "OK", + "singleDependentError": "Não foi possível desinstalar a extensão '{0}'. A extensão '{1}' depende dela.", + "twoDependentsError": "Não foi possível desinstalar a extensão '{0}'. As extensões '{1}' e '{2}' dependem dela.", + "multipleDependentsError": "Não foi possível desinstalar a extensão '{0}'. As extensões '{1}' e '{2}' e outras dependem dela.", + "notExists": "Não foi possível encontrar a extensão" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/extensions/common/abstractExtensionService.i18n.json b/i18n/ptb/src/vs/platform/extensions/common/abstractExtensionService.i18n.json new file mode 100644 index 00000000000..d521fce97ff --- /dev/null +++ b/i18n/ptb/src/vs/platform/extensions/common/abstractExtensionService.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "unknownDep": "Extensão '{1}' falhou ao ativar. Motivo: dependência desconhecida '{0}'.", + "failedDep1": "Extensão '{1}' falhou ao ativar. Motivo: a dependência '{0}' falhou ao ativar.", + "failedDep2": "Extensão '{0}' falhou ao ativar. Motivo: mais de 10 níveis de dependências (provavelmente um laço de dependência).", + "activationError": "Ativação da extensão `{0}` falhou: {1}." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/extensions/common/extensionsRegistry.i18n.json b/i18n/ptb/src/vs/platform/extensions/common/extensionsRegistry.i18n.json new file mode 100644 index 00000000000..649e13b03b1 --- /dev/null +++ b/i18n/ptb/src/vs/platform/extensions/common/extensionsRegistry.i18n.json @@ -0,0 +1,24 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.engines.vscode": "Para extensões do VS Code, especifica a versão do VS Code que a extensão é compatível. Não pode ser *. Por exemplo: ^0.10.5 indica compatibilidade com uma versão mínima de 0.10.5 para o VS Code.", + "vscode.extension.publisher": "O editor da extensão do VS Code.", + "vscode.extension.displayName": "O nome de exibição para a extensão do VS Code.", + "vscode.extension.categories": "As categorias usadas pela galeria do VS Code para categorizar a extensão.", + "vscode.extension.galleryBanner": "Banner usado na loja VS Code.", + "vscode.extension.galleryBanner.color": "A cor do banner usado no cabeçalho de página da loja VS Code.", + "vscode.extension.galleryBanner.theme": "A cor do tema usada para o fonte usado no banner.", + "vscode.extension.contributes": "Todas as contribuições da extensão VS Code representadas por este pacote.", + "vscode.extension.preview": "Configura a extensão para ser marcada como pré-visualização na Loja.", + "vscode.extension.activationEvents": "Eventos de ativação para a extensão VS Code.", + "vscode.extension.badges": "Matriz de emblemas a mostrar na barra lateral da página da extensão na Loja.", + "vscode.extension.badges.url": "URL da imagem do emblema.", + "vscode.extension.badges.href": "Link do emblema.", + "vscode.extension.badges.description": "Descrição do emblema.", + "vscode.extension.extensionDependencies": "Dependências para outras extensões. O identificador de uma extensão sempre é ${publisher}. ${nome}. Por exemplo: vscode.csharp.", + "vscode.extension.scripts.prepublish": "Script a ser executado antes do pacote ser publicado como uma extensão VS Code.", + "vscode.extension.icon": "O caminho para um ícone de 128x128 pixels." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/extensions/node/extensionValidator.i18n.json b/i18n/ptb/src/vs/platform/extensions/node/extensionValidator.i18n.json new file mode 100644 index 00000000000..fe37dd1820f --- /dev/null +++ b/i18n/ptb/src/vs/platform/extensions/node/extensionValidator.i18n.json @@ -0,0 +1,24 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "versionSyntax": "Não foi possível analisar o valor de 'engines.vscode' {0}. Por favor, utilize, por exemplo: ^ 0.10.0, ^ 1.2.3, ^ 0.11.0, ^ 0.10.x, etc.", + "versionSpecificity1": "Versão especificada em 'engines.vscode' ({0}) não é específica o suficiente. Para versões do vscode anteriores a 1.0.0, por favor defina no mínimo a versão principal e secundária desejada. Por exemplo, ^ 0.10.0, 0.10.x, 0.11.0, etc.", + "versionSpecificity2": "Versão especificada em 'engines.vscode' ({0}) não é específica o suficiente. Para as versões do vscode posteriores a 1.0.0, por favor defina no mínimo a versão principal do desejado. Por exemplo, ^ 1.10.0, 1.10.x 1. XX, 2.x.x, etc.", + "versionMismatch": "Extensão não é compatível com Code {0}. A extensão requer: {1}.", + "extensionDescription.empty": "Descrição de extensão vazia obtida", + "extensionDescription.publisher": "a propriedade `{0}` é obrigatória e deve ser do tipo `string`", + "extensionDescription.name": "a propriedade `{0}` é obrigatória e deve ser do tipo `string`", + "extensionDescription.version": "a propriedade `{0}` é obrigatória e deve ser do tipo `string`", + "extensionDescription.engines": "a propriedade `{0}` é obrigatória e deve ser do tipo `object`", + "extensionDescription.engines.vscode": "a propriedade `{0}` é obrigatória e deve ser do tipo `string`", + "extensionDescription.extensionDependencies": "a propriedade `{0}` pode ser omitida ou deve ser do tipo `string[]`", + "extensionDescription.activationEvents1": "a propriedade `{0}` pode ser omitida ou deve ser do tipo `string[]`", + "extensionDescription.activationEvents2": "Propriedades '{0}' e '{1}' devem ser especificadas ou devem ambas ser omitidas", + "extensionDescription.main1": "a propriedade `{0}` é opcional ou pode ser do tipo `string`", + "extensionDescription.main2": "Esperado 'main' ({0}) ser incluído dentro da pasta da extensão ({1}). Isto pode fazer a extensão não-portável.", + "extensionDescription.main3": "propriedades '{0}' e '{1}' devem ser especificadas ou devem ambas ser omitidas", + "notSemver": "Versão da extensão não é compatível a semver" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/integrity/node/integrityServiceImpl.i18n.json b/i18n/ptb/src/vs/platform/integrity/node/integrityServiceImpl.i18n.json new file mode 100644 index 00000000000..d252527ac15 --- /dev/null +++ b/i18n/ptb/src/vs/platform/integrity/node/integrityServiceImpl.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "integrity.ok": "OK", + "integrity.dontShowAgain": "Não mostrar novamente", + "integrity.moreInfo": "Mais informações", + "integrity.prompt": "Sua instalação de {0} parece estar corrompida. Favor reinstalar." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/jsonschemas/common/jsonValidationExtensionPoint.i18n.json b/i18n/ptb/src/vs/platform/jsonschemas/common/jsonValidationExtensionPoint.i18n.json new file mode 100644 index 00000000000..47ff1ba6bad --- /dev/null +++ b/i18n/ptb/src/vs/platform/jsonschemas/common/jsonValidationExtensionPoint.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "contributes.jsonValidation": "Contribui à configuração do schema json.", + "contributes.jsonValidation.fileMatch": "O padrão de arquivo a corresponder, por exemplo \"package.json\" ou \"*.launch\".", + "contributes.jsonValidation.url": "Um esquema de URL ('http:', 'https:') ou caminho relativo à pasta de extensão('./').", + "invalid.jsonValidation": "'configuration.jsonValidation' deve ser uma matriz", + "invalid.fileMatch": "'configuration.jsonValidation.fileMatch' deve ser definido", + "invalid.url": "'configuration.jsonValidation.url' deve ser uma URL ou caminho relativo", + "invalid.url.fileschema": "'configuration.jsonValidation.url' é uma URL relativa inválida: {0}", + "invalid.url.schema": "'configuration.jsonValidation.url' deve começar com ' http:', ' https: 'ou'. /' para os esquemas de referência localizados na extensão" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/keybinding/common/abstractKeybindingService.i18n.json b/i18n/ptb/src/vs/platform/keybinding/common/abstractKeybindingService.i18n.json new file mode 100644 index 00000000000..59961c4476a --- /dev/null +++ b/i18n/ptb/src/vs/platform/keybinding/common/abstractKeybindingService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "first.chord": "({0}) foi pressionado. Aguardando segunda tecla de pressionamento simultâneo...", + "missing.chord": "A combinação de chave ({0}, {1}) não é um comando." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/keybinding/common/keybindingLabels.i18n.json b/i18n/ptb/src/vs/platform/keybinding/common/keybindingLabels.i18n.json new file mode 100644 index 00000000000..bf2baf83906 --- /dev/null +++ b/i18n/ptb/src/vs/platform/keybinding/common/keybindingLabels.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ctrlKey": "Ctrl", + "shiftKey": "Shift", + "altKey": "Alt", + "windowsKey": "Windows", + "ctrlKey.long": "Controle", + "shiftKey.long": "Shift", + "altKey.long": "Alt", + "cmdKey.long": "Comando", + "windowsKey.long": "Windows" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/markers/common/problemMatcher.i18n.json b/i18n/ptb/src/vs/platform/markers/common/problemMatcher.i18n.json new file mode 100644 index 00000000000..29df9e58b2b --- /dev/null +++ b/i18n/ptb/src/vs/platform/markers/common/problemMatcher.i18n.json @@ -0,0 +1,61 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ProblemPatternParser.loopProperty.notLast": "A propriedade loop só é suportada na última linha correspondente.", + "ProblemPatternParser.problemPattern.missingRegExp": "Está faltando uma expressão regular a problema padrão.", + "ProblemPatternParser.problemPattern.missingProperty": "O problema padrão é inválido. Ele deve ter ao menos um arquivo, mensagem e linha ou local de grupo de correspondência.", + "ProblemPatternParser.invalidRegexp": "Erro: a cadeia de caracteres {0} não é uma expressão regular válida.\n", + "ProblemPatternSchema.regexp": "A expressão regular para procurar um erro, aviso ou informação na saída.", + "ProblemPatternSchema.file": "O índice do grupo de correspondência do arquivo. Se omitido, será usado 1.", + "ProblemPatternSchema.location": "O índice de grupo de correspondência da localização do problema. Padrões de localização válidos são: (linha), (linha, coluna) e (startLine, startColumn, endLine, endColumn). Se omitido (linha, coluna) é assumido.", + "ProblemPatternSchema.line": "O índice de grupo de correspondência da linha do problema. O padrão é 2", + "ProblemPatternSchema.column": "O índice de grupo de correspondência de caractere da linha do problema. O padrão é 3", + "ProblemPatternSchema.endLine": "O índice de grupo de correspondência de linha final do problema. O padrão é indefinido", + "ProblemPatternSchema.endColumn": "O índice de grupo de correspondência de caráter final de linha do problema. O padrão é indefinido", + "ProblemPatternSchema.severity": "O índice de grupo de correspondência da gravidade do problema. O padrão é indefinido", + "ProblemPatternSchema.code": "O índice de grupo de correspondência do código do problema. O padrão é indefinido", + "ProblemPatternSchema.message": "O índice de grupo de correspondência da mensagem. Se omitido o padrão é 4 se o local for especificado. Caso contrário o padrão é 5.", + "ProblemPatternSchema.loop": "Em um loop de correspondência multi linha indica se este padrão é executado em um loop enquanto houver correspondências. Somente pode ser especificado no último padrão em um padrão de linha múltiplas.", + "NamedProblemPatternSchema.name": "O nome do modelo de problema.", + "NamedMultiLineProblemPatternSchema.name": "O nome do modelo de problema multi-linhas.", + "NamedMultiLineProblemPatternSchema.patterns": "Os padrões atuais.", + "ProblemPatternExtPoint": "Contribui aos modelos de problema", + "ProblemPatternRegistry.error": "Modelo de problema inválido. O modelo será ignorado.", + "ProblemMatcherParser.noProblemMatcher": "Erro: a descrição não pode ser convertida em uma correspondência de problema:\n{0}\n\n", + "ProblemMatcherParser.noProblemPattern": "Erro: a descrição nao define um padrão de problema válido: {0}\n", + "ProblemMatcherParser.noOwner": "Erro: a descriçao não define um proprietário:\n{0}\n", + "ProblemMatcherParser.noFileLocation": "Erro: a descrição não define uma localização de arquivo:\n{0}\n", + "ProblemMatcherParser.unknownSeverity": "Info: severidade {0} desconhecida. Valores válidos são erro, aviso e info.\n", + "ProblemMatcherParser.noDefinedPatter": "Erro: o padrão com o identificador {0} não existe.", + "ProblemMatcherParser.noIdentifier": "Erro: a propriedade padrão se refere a um identificador vazio.", + "ProblemMatcherParser.noValidIdentifier": "Erro: a propriedade padrão {0} não é uma variável de padrões válida.", + "ProblemMatcherParser.problemPattern.watchingMatcher": "Um problema de correspondência deve obrigatoriamente definir padrão inicial e um padrão final para monitoramento.", + "ProblemMatcherParser.invalidRegexp": "Erro: a cadeia de caracteres {0} não é uma expressão regular válida.\n", + "WatchingPatternSchema.regexp": "A expressão regular para detectar o início ou o fim de uma tarefa em segundo plano.", + "WatchingPatternSchema.file": "O índice do grupo de correspondência do arquivo. Pode ser omitido.", + "PatternTypeSchema.name": "O nome de um padrão pré-definido ou contribuído.", + "PatternTypeSchema.description": "Um padrão de problema ou o nome de um padrão de problema pré-definido ou contribuído. Pode ser omitido se base for especificada.", + "ProblemMatcherSchema.base": "O nome de uma correspondência de problema base a ser utilizado.", + "ProblemMatcherSchema.owner": "O proprietário de um problema dentro do código. Pode ser omitido se base for especificada. Default para 'externo' se omitido e base não for especificada.", + "ProblemMatcherSchema.severity": "A severidade padrão para captura de problemas. É utilizada se o padrão não definir um grupo correspondente para severidade.", + "ProblemMatcherSchema.applyTo": "Controla se um problema reportado em um documento de texto é aplicado somente para aberto, fechado ou todos os documentos.", + "ProblemMatcherSchema.fileLocation": "Define como os nomes de arquivos reportados em um padrão de problema devem ser interpretados.", + "ProblemMatcherSchema.background": "Padrões para monitorar o início e o término de um pesquisador ativo em uma tarefa em segundo plano.", + "ProblemMatcherSchema.background.activeOnStart": "Se configurado para verdadeiro, o monitor em segundo plano está em modo ativo quando a tarefa inicia. Isto é igual a emissão de uma linha que corresponde ao beginPattern", + "ProblemMatcherSchema.background.beginsPattern": "Se houver correspondência na saída o início de uma tarefa em segundo plano é sinalizada.", + "ProblemMatcherSchema.background.endsPattern": "Se houver correspondência na saída o final de uma tarefa em segundo plano é sinalizada.", + "ProblemMatcherSchema.watching.deprecated": "A propriedade watching foi descontinuada. Use background no lugar dela.", + "ProblemMatcherSchema.watching": "Padrões para monitorar o início e o término de um pesquisador observando.", + "ProblemMatcherSchema.watching.activeOnStart": "Se configurado para verdadeiro, o monitoramento está em modo ativo quando a tarefa inicia. Isto é igual a emissão de uma linha que corresponde ao beginPattern", + "ProblemMatcherSchema.watching.beginsPattern": "Se houver correspondência na saída o início de uma tarefa observada é sinalizada.", + "ProblemMatcherSchema.watching.endsPattern": "Se houver correspondência na saída o final de uma tarefa observada é sinalizada.", + "LegacyProblemMatcherSchema.watchedBegin.deprecated": "Esta propriedade está descontinuada. Ao invés, use a propriedade de observação.", + "LegacyProblemMatcherSchema.watchedBegin": "Uma expressão regular sinalizando que uma tarefa observada é ativada através da observação.", + "LegacyProblemMatcherSchema.watchedEnd.deprecated": "Esta propriedade está descontinuada. Ao invés, use a propriedade de observação.", + "LegacyProblemMatcherSchema.watchedEnd": "Uma expressão regular sinalizando que uma tarefa observada terminou a execução.", + "NamedProblemMatcherSchema.name": "O nome do correspondente do problema.", + "ProblemMatcherExtPoint": "Contribui aos correspondentes de problema" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/message/common/message.i18n.json b/i18n/ptb/src/vs/platform/message/common/message.i18n.json new file mode 100644 index 00000000000..620c63edd07 --- /dev/null +++ b/i18n/ptb/src/vs/platform/message/common/message.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "close": "Fechar", + "later": "Mais tarde", + "cancel": "Cancelar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/request/node/request.i18n.json b/i18n/ptb/src/vs/platform/request/node/request.i18n.json new file mode 100644 index 00000000000..1f7fd75e5aa --- /dev/null +++ b/i18n/ptb/src/vs/platform/request/node/request.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "httpConfigurationTitle": "HTTP", + "proxy": "As configurações de proxy a usar. Se não forem configuradas, serão obtidas das variáveis de ambiente http_proxy e https_proxy", + "strictSSL": "Se o certificado do servidor de proxy deve ser verificado contra a lista de autoridades de certificação fornecida.", + "proxyAuthorization": "O valor para enviar como o cabeçalho de 'autorização Proxy' para cada solicitação de rede." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/telemetry/common/telemetryService.i18n.json b/i18n/ptb/src/vs/platform/telemetry/common/telemetryService.i18n.json new file mode 100644 index 00000000000..a1d67b82fb7 --- /dev/null +++ b/i18n/ptb/src/vs/platform/telemetry/common/telemetryService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "telemetryConfigurationTitle": "Telemetria", + "telemetry.enableTelemetry": "Permitir que os dados de uso e erros sejam enviados à Microsoft." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/ptb/src/vs/platform/theme/common/colorRegistry.i18n.json new file mode 100644 index 00000000000..64d68304f98 --- /dev/null +++ b/i18n/ptb/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -0,0 +1,78 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "invalid.color": "Formato inválido de cor. Use #RGB, #RGBA, #RRGGBB ou #RRGGBBAA", + "schema.colors": "Cores usadas no workbench.", + "foreground": "Cor de primeiro plano geral. Essa cor é só usada se não for substituída por um componente.", + "errorForeground": "Cor de primeiro plano geral para mensagens de erro. Essa cor é só usada se não for substituída por um componente.", + "descriptionForeground": "Cor de primeiro plano para a descrição do texto provendo informação adicional, por exemplo para uma etiqueta.", + "focusBorder": "Cor geral da borda para elementos focalizados. Essa cor é usada somente se não for substituída por um componente.", + "contrastBorder": "Uma borda extra em torno de elementos para separá-los dos outros de maior contraste.", + "activeContrastBorder": "Uma borda extra em torno de elementos ativos para separá-los dos outros de maior contraste.", + "selectionBackground": "A cor de fundo das seleções de texto na bancada de trabalho (por exemplo, para campos de entrada ou áreas de texto). Note que isto não se aplica a seleções dentro do editor e do terminal.", + "textSeparatorForeground": "Cor para separadores de texto.", + "textLinkForeground": "Cor de primeiro plano para links no texto.", + "textLinkActiveForeground": "Cor de primeiro plano para links ativos no texto.", + "textPreformatForeground": "Cor de primeiro plano para segmentos de texto pré-formatados.", + "textBlockQuoteBackground": "Cor de fundo para blocos de citações no texto.", + "textBlockQuoteBorder": "Cor da borda para blocos de citações no texto.", + "textCodeBlockBackground": "Cor de fundo para blocos de código no texto.", + "widgetShadow": "Cor de sombra ferramentas como localizar/substituir dentro do editor.", + "inputBoxBackground": "Cor de fundo da caixa de entrada.", + "inputBoxForeground": "Cor de primeiro plano da caixa de entrada.", + "inputBoxBorder": "Borda da caixa de entrada.", + "inputBoxActiveOptionBorder": "Cor da borda das opções ativas em campos de entrada.", + "inputPlaceholderForeground": "Cor de primeiro plano da caixa de entrada para o texto de espaço reservado.", + "inputValidationInfoBackground": "Cor de fundo de validação de entrada para a severidade de informações.", + "inputValidationInfoBorder": "Cor da borda de validação de entrada para a severidade de informações.", + "inputValidationWarningBackground": "Cor de fundo de validação de entrada para avisos.", + "inputValidationWarningBorder": "Cor da borda de validação para a severidade de avisos.", + "inputValidationErrorBackground": "Cor de fundo de validação de entrada para a severidade do erro.", + "inputValidationErrorBorder": "Cor da borda de validação de entrada para a severidade do erro.", + "dropdownBackground": "Cor de fundo do menu suspenso.", + "dropdownForeground": "Cor de primeiro plano do menu suspenso.", + "dropdownBorder": "Borda do menu suspenso.", + "listFocusBackground": "Cor de fundo para o item focalizado de Lista/árvore quando a lista/árvore está ativa. Uma árvore/lista de ativa tem o foco do teclado, uma inativa não.", + "listFocusForeground": "Cor de fundo da Lista/árvore para o item focalizado quando a lista/árvore está ativa. Uma árvore/lista ativa tem o foco do teclado, uma inativa não.", + "listActiveSelectionBackground": "Cor de fundo para o item selecionado de Lista/árvore quando a lista/árvore está ativa. Uma lista/árvore ativa tem o foco do teclado, uma inativa não.", + "listActiveSelectionForeground": "Cor de primeiro plano para o item selecionado de Lista/árvore quando a lista/árvore está ativa. Uma lista/árvore ativa tem o foco do teclado, uma inativa não.", + "listInactiveSelectionBackground": "Cor de fundo para o item selecionado de Lista/árvore quando a lista/árvore está inativa. Uma lista/árvore ativa tem o foco do teclado, uma inativa não.", + "listInactiveSelectionForeground": "Cor de primeiro plano para Lista/árvore para o item selecionado quando a lista/árvore está inativa. Uma árvore/lista ativa tem o foco do teclado, um inativo não.", + "listHoverBackground": "Cor de fundo de Lista/árvore quando pairando sobre itens usando o mouse.", + "listHoverForeground": "Primeiro plano da Lista/Ãrvoce quando passar sobre itens usando o mouse.", + "listDropBackground": "Cor de fundo ao arrastar e soltar de Lista/árvore quando movendo itens usando o mouse.", + "highlight": "Cor de primeiro plano de Lista/árvore de destaques de correspondências ao pesquisar na árvore/lista.", + "pickerGroupForeground": "Seletor rápido de cor para rótulos de agrupamento.", + "pickerGroupBorder": "Seletor rápido de cor para bordas de agrupamentos.", + "buttonForeground": "Cor de primeiro plano do botão.", + "buttonBackground": "Cor de fundo do botão.", + "buttonHoverBackground": "Cor de fundo de botão quando flutuar sobre ele.", + "badgeBackground": "Cor de fundo do distintivo. Distintivos são rótulos de pequenas informações, por exemplo, para a contagem de resultados de pesquisa.", + "badgeForeground": "Cor de primeiro plano do distintivo. Distintivos são rótulos de pequenas informações, por exemplo, para a contagem de resultados de pesquisa.", + "scrollbarShadow": "Sombra da barra de rolagem para indicar que a visualização está sendo rolada.", + "scrollbarSliderBackground": "Cor de fundo do controle deslizante.", + "scrollbarSliderHoverBackground": "Cor de fundo de controle deslizante quando estiver flutuando sobre ele.", + "scrollbarSliderActiveBackground": "Cor de fundo de controle deslizante quando ativo.", + "progressBarBackground": "Cor de fundo da barra de progresso que pode ser mostrada em operações de execução demorada.", + "editorBackground": "Cor de plano de fundo do editor.", + "editorForeground": "Cor de primeiro plano padrão do editor.", + "editorWidgetBackground": "Cor de plano de fundo das ferramentas de edição, como pesquisar/substituir.", + "editorWidgetBorder": "Cor da borda da ferramenta editor.", + "editorSelection": "Cor de seleção do editor.", + "editorInactiveSelection": "Cor de seleção em um editor inativo.", + "editorSelectionHighlight": "Cor de regiões com o mesmo conteúdo da seleção.", + "editorFindMatch": "Cor da correspondência de pesquisa atual.", + "findMatchHighlight": "Cor dos outros resultados de pesquisa.", + "findRangeHighlight": "Cor da faixa que limita a pesquisa.", + "hoverHighlight": "Realçar abaixo da palavra onde é mostrado item flutuante", + "hoverBackground": "Cor de fundo para o item flutuante do editor", + "hoverBorder": "Cor da borda para o item flutuante do editor.", + "activeLinkForeground": "Cor dos links ativos.", + "diffEditorInserted": "Cor de fundo para texto que foi inserido.", + "diffEditorRemoved": "Cor de fundo para texto que foi removido.", + "diffEditorInsertedOutline": "Cor de contorno para o texto que foi inserido.", + "diffEditorRemovedOutline": "Cor de contorno para o texto que foi removido." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/api/electron-browser/mainThreadExtensionService.i18n.json b/i18n/ptb/src/vs/workbench/api/electron-browser/mainThreadExtensionService.i18n.json new file mode 100644 index 00000000000..d45294dd317 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/api/electron-browser/mainThreadExtensionService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "overwritingExtension": "Sobrescrevendo extensão {0} por {1}.", + "extensionUnderDevelopment": "Carregando extensão de desenvolvimento em {0}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/api/electron-browser/mainThreadMessageService.i18n.json b/i18n/ptb/src/vs/workbench/api/electron-browser/mainThreadMessageService.i18n.json new file mode 100644 index 00000000000..0feb87677bb --- /dev/null +++ b/i18n/ptb/src/vs/workbench/api/electron-browser/mainThreadMessageService.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "close": "Fechar", + "cancel": "Cancelar", + "ok": "OK" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/api/node/extHostDiagnostics.i18n.json b/i18n/ptb/src/vs/workbench/api/node/extHostDiagnostics.i18n.json new file mode 100644 index 00000000000..867922ab8d2 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/api/node/extHostDiagnostics.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "limitHit": "Não apresentando {0} erros e avisos a mais." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/api/node/extHostTreeViews.i18n.json b/i18n/ptb/src/vs/workbench/api/node/extHostTreeViews.i18n.json new file mode 100644 index 00000000000..d5ca67a9353 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/api/node/extHostTreeViews.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "treeView.notRegistered": "Nenhuma visualização de árvore com id '{0}' registrado.", + "treeItem.notFound": "Nenhum item de árvore com id '{0}' encontrado.", + "treeView.duplicateElement": "Elemento {0} já está registrado" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/actions/configureLocale.i18n.json b/i18n/ptb/src/vs/workbench/browser/actions/configureLocale.i18n.json new file mode 100644 index 00000000000..80686b2c898 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/actions/configureLocale.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "configureLocale": "Configurar Idioma", + "displayLanguage": "Define o idioma de exibição do VSCode.", + "doc": "Veja {0} para obter uma lista dos idiomas suportados.", + "restart": "Modificar o valor requer reinicialização do VSCode.", + "fail.createSettings": "Não foi possível criar '{0}' ({1}).", + "JsonSchema.locale": "O idioma da interface do usuário a ser usada." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/actions/fileActions.i18n.json b/i18n/ptb/src/vs/workbench/browser/actions/fileActions.i18n.json new file mode 100644 index 00000000000..9da2e4e11c7 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/actions/fileActions.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openFolder": "Abrir Pasta...", + "openFileFolder": "Abrir..." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/actions/toggleActivityBarVisibility.i18n.json b/i18n/ptb/src/vs/workbench/browser/actions/toggleActivityBarVisibility.i18n.json new file mode 100644 index 00000000000..02e74f2918f --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/actions/toggleActivityBarVisibility.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleActivityBar": "Alternar Visibilidade da Barra de Atividades", + "view": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/actions/toggleEditorLayout.i18n.json b/i18n/ptb/src/vs/workbench/browser/actions/toggleEditorLayout.i18n.json new file mode 100644 index 00000000000..4cdb847aaca --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/actions/toggleEditorLayout.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleEditorGroupLayout": "Alternar Layout Vertical/Horizontal do Grupo de Editor", + "horizontalLayout": "Layout do Grupo de Editor Horizontal", + "verticalLayout": "Layout do Grupo de Editor Vertical", + "view": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/actions/toggleSidebarPosition.i18n.json b/i18n/ptb/src/vs/workbench/browser/actions/toggleSidebarPosition.i18n.json new file mode 100644 index 00000000000..ee4fc530361 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/actions/toggleSidebarPosition.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleLocation": "Alternar Localização da Barra Lateral", + "view": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/actions/toggleSidebarVisibility.i18n.json b/i18n/ptb/src/vs/workbench/browser/actions/toggleSidebarVisibility.i18n.json new file mode 100644 index 00000000000..5143e35479c --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/actions/toggleSidebarVisibility.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleSidebar": "Alternar Localização da Barra Lateral", + "view": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/actions/toggleStatusbarVisibility.i18n.json b/i18n/ptb/src/vs/workbench/browser/actions/toggleStatusbarVisibility.i18n.json new file mode 100644 index 00000000000..5376fb36c3a --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/actions/toggleStatusbarVisibility.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleStatusbar": "Alternar Visibilidade da Barra de Status", + "view": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/actions/toggleZenMode.i18n.json b/i18n/ptb/src/vs/workbench/browser/actions/toggleZenMode.i18n.json new file mode 100644 index 00000000000..b0a635982f2 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/actions/toggleZenMode.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleZenMode": "Alternar Modo Zen", + "view": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/activitybar/activitybarActions.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/activitybar/activitybarActions.i18n.json new file mode 100644 index 00000000000..8dab311a65f --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/activitybar/activitybarActions.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "removeFromActivityBar": "Remover da Barra de Atividades", + "keepInActivityBar": "Manter na Barra de Atividades", + "titleKeybinding": "{0} ({1})", + "additionalViews": "Visualizações Adicionais", + "numberBadge": "{0} ({1})", + "manageExtension": "Gerenciar Extensão", + "toggle": "Alternar Visualização Fixa" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json new file mode 100644 index 00000000000..5f8a7bb47de --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "hideActivitBar": "Ocultar a Barra de Atividades", + "activityBarAriaLabel": "Chave do Modo de exibição Ativo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/compositePart.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/compositePart.i18n.json new file mode 100644 index 00000000000..e12e6d4b90e --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/compositePart.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ariaCompositeToolbarLabel": "{0} ações ", + "titleTooltip": "{0} ({1})" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/binaryDiffEditor.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/binaryDiffEditor.i18n.json new file mode 100644 index 00000000000..a38af02d663 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/binaryDiffEditor.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "metadataDiff": "{0} ↔ {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/binaryEditor.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/binaryEditor.i18n.json new file mode 100644 index 00000000000..53321246ac7 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/binaryEditor.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "binaryEditor": "Visualizador binário" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/editor.contribution.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/editor.contribution.i18n.json new file mode 100644 index 00000000000..dbfae18a9bf --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/editor.contribution.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "textEditor": "Editor de texto", + "textDiffEditor": "Editor de Diferentes Textos", + "binaryDiffEditor": "Editor de Diferença Binária", + "sideBySideEditor": "Editor Lado a lado", + "groupOnePicker": "Mostrar editores no primeiro grupo", + "groupTwoPicker": "Mostrar editores no segundo grupo", + "groupThreePicker": "Mostrar editores no terceiro grupo", + "allEditorsPicker": "Mostrar todos editores abertos", + "view": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/editorActions.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorActions.i18n.json new file mode 100644 index 00000000000..ae6f9ae84b7 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorActions.i18n.json @@ -0,0 +1,55 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "splitEditor": "Dividir editor", + "joinTwoGroups": "Juntar editores de dois grupos", + "navigateEditorGroups": "Navegar entre grupos de editores", + "focusActiveEditorGroup": "Focalizar grupo de editores ativo", + "focusFirstEditorGroup": "Focalizar o primeiro grupo de editores", + "focusSecondEditorGroup": "Focalizar o segundo grupo de editores", + "focusThirdEditorGroup": "Focalizar o terceiro grupo de editores", + "focusPreviousGroup": "Focalizar grupo anterior", + "focusNextGroup": "Focalizar próximo grupo", + "openToSide": "Aberto para o lado", + "closeEditor": "Fechar editor", + "revertAndCloseActiveEditor": "Reverter e fechar editor", + "closeEditorsToTheLeft": "Fechar editores à esquerda ", + "closeEditorsToTheRight": "Fechar editores à direita", + "closeAllEditors": "Fechar todos editores", + "closeEditorsInOtherGroups": "Fechar editores nos outros grupos", + "closeOtherEditorsInGroup": "Fechar outros editores", + "closeEditorsInGroup": "Fechar todos editores no grupo", + "moveActiveGroupLeft": "Mover grupo de editores para esquerda", + "moveActiveGroupRight": "Mover grupo de editores para direita", + "minimizeOtherEditorGroups": "Minimizar outros grupos de editores", + "evenEditorGroups": "Igualar larguras de grupos de editores", + "maximizeEditor": "Maximizar grupo de editor e ocultar barra lateral", + "keepEditor": "Manter editor", + "openNextEditor": "Abrir próximo editor", + "openPreviousEditor": "Abrir editor anterior", + "nextEditorInGroup": "Abrir próximo editor no grupo", + "openPreviousEditorInGroup": "Abrir editor anterior no grupo", + "navigateNext": "Avançar", + "navigatePrevious": "Voltar", + "reopenClosedEditor": "Reabrir Editor Fechado", + "clearRecentFiles": "Limpar arquivos recentes", + "showEditorsInFirstGroup": "Mostrar editores no primeiro grupo", + "showEditorsInSecondGroup": "Mostrar editores no segundo grupo", + "showEditorsInThirdGroup": "Mostrar editores no terceiro grupo", + "showEditorsInGroup": "Mostrar editores no grupo", + "showAllEditors": "Mostrar todos editores", + "openPreviousRecentlyUsedEditorInGroup": "Abrir o Editor Anterior Recentemente Usado no Grupo", + "openNextRecentlyUsedEditorInGroup": "Abrir o Próximo Editor Recentemente Usado no Grupo", + "navigateEditorHistoryByInput": "Abrir o Editor Anterior do Histórico", + "openNextRecentlyUsedEditor": "Abrir o Próximo Editor Recentemente Utilizado", + "openPreviousRecentlyUsedEditor": "Abrir o Editor Anterior Recentemente Utilizado", + "clearEditorHistory": "Limpar Histórico do Editor", + "focusLastEditorInStack": "Abrir Último Editor do Grupo", + "moveEditorLeft": "Mover Editor para Esquerda", + "moveEditorRight": "Mover Editor para Direita", + "moveEditorToPreviousGroup": "Mover Editor para o Grupo Anterior", + "moveEditorToNextGroup": "Mover o Editor para o Próximo Grupo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/editorCommands.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorCommands.i18n.json new file mode 100644 index 00000000000..f42c45c02f5 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorCommands.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorCommand.activeEditorMove.description": "Mover o editor ativo por guias ou grupos", + "editorCommand.activeEditorMove.arg.name": "Argumento de movimento do editor ativo", + "editorCommand.activeEditorMove.arg.description": "Propriedades do argumento: \n\t\t\t\t\t\t- 'para': sequência de valor fornecendo para onde mover.\n\t\t\t\t\t\t- 'por': sequência de valor, fornecendo a unidade para o movimento. Por guia ou por grupo.\n\t\t\t\t\t\t- 'valor': valor numérico, fornecendo quantas posições ou uma posição absoluta para mover.\n\t\t\t\t\t", + "commandDeprecated": "Comando **{0}** foi removido. Você pode usar **{1}** em vez disso", + "openKeybindings": "Configurar os atalhos de teclado" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/editorPart.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorPart.i18n.json new file mode 100644 index 00000000000..c6a90d88542 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorPart.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "groupOneVertical": "Esquerda", + "groupTwoVertical": "Centro", + "groupThreeVertical": "Direita", + "groupOneHorizontal": "Topo", + "groupTwoHorizontal": "Centro", + "groupThreeHorizontal": "Baixo", + "editorOpenError": "Não foi possível abrir '{0}': {1}." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/editorPicker.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorPicker.i18n.json new file mode 100644 index 00000000000..e17bc940565 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorPicker.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, seletor de grupo editor", + "groupLabel": "Grupo: {0}", + "noResultsFoundInGroup": "Não foi encontrado nennhum editor aberto no grupo", + "noOpenedEditors": "Lista de editores abertos está atualmente vazia no grupo", + "noResultsFound": "Não foi encontrado editor correspondente aberto", + "noOpenedEditorsAllGroups": "A lista de editores abertos está atualmente vazia" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json new file mode 100644 index 00000000000..c2057c183a1 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json @@ -0,0 +1,49 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "singleSelectionRange": "Ln {0}, {1} Col ({2} selecionado)", + "singleSelection": "Ln {0}, {1} Col", + "multiSelectionRange": "{0} seleções ({1} caracteres selecionados)", + "multiSelection": "{0} seleções", + "endOfLineLineFeed": "LF", + "endOfLineCarriageReturnLineFeed": "CRLF", + "tabFocusModeEnabled": "Tabulação move o foco", + "disableTabMode": "Desativar o modo de acessibilidade", + "gotoLine": "Ir para linha", + "indentation": "Indentação", + "selectEncoding": "Selecionar a codificação", + "selectEOL": "Selecionar a sequência de fim de linha", + "selectLanguageMode": "Selecionar modo de idioma", + "fileInfo": "Informações do arquivo", + "spacesSize": "Espaços: {0}", + "tabSize": "Tamanho de Tabulação: {0}", + "showLanguageExtensions": "Pesquisar extensões na loja para '{0}'...", + "changeMode": "Alterar o modo de linguagem", + "noEditor": "Nenhum editor de texto ativo neste momento", + "languageDescription": "({0}) - linguagem configurada", + "languageDescriptionConfigured": "({0})", + "languagesPicks": "linguagens (identificador)", + "configureModeSettings": "Configurar '{0}' configurações baseadas em linguagem...", + "configureAssociationsExt": "Configurar a associação de arquivo para '{0}'...", + "autoDetect": "Detecção automática", + "pickLanguage": "Selecionar o modo do idioma", + "currentAssociation": "Associação atual", + "pickLanguageToConfigure": "Selecionar o modo de linguagem para associar a '{0}'", + "changeIndentation": "Alterar a indentação", + "noWritableCodeEditor": "O editor de código ativo é somente leitura.", + "indentView": "alterar visualização", + "indentConvert": "converter arquivo", + "pickAction": "Selecionar ação", + "changeEndOfLine": "Alterar sequência de final de linha", + "pickEndOfLine": "Selecionar sequência de final de linha", + "changeEncoding": "Alterar a codificação do arquivo", + "noFileEditor": "Nenhum arquivo ativo neste momento", + "saveWithEncoding": "Salvar com codificação", + "reopenWithEncoding": "Reabrir com codificação", + "guessedEncoding": "Adivinhado a partir do conteúdo", + "pickEncodingForReopen": "Selecione a codificaçãodo arquivo para reabrir o arquivo.", + "pickEncodingForSave": "Selecione a codificação do arquivo para Salvar Com" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/tabsTitleControl.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/tabsTitleControl.i18n.json new file mode 100644 index 00000000000..9001e58fa99 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/tabsTitleControl.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "araLabelTabActions": "Ações de tablulação" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/textDiffEditor.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/textDiffEditor.i18n.json new file mode 100644 index 00000000000..8af2aff62d5 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/textDiffEditor.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "textDiffEditor": "Editor de Diferentes Textos", + "readonlyEditorWithInputAriaLabel": "{0}. Editor de comparação de texto somente leitura.", + "readonlyEditorAriaLabel": "Editor de comparação de texto somente leitura.", + "editableEditorWithInputAriaLabel": "{0}. Editor de comparação de arquivos texto.", + "editableEditorAriaLabel": "Editor de comparação de arquivos texto.", + "navigate.next.label": "Próxima Alteração", + "navigate.prev.label": "Alteração Anterior", + "inlineDiffLabel": "Alternar para exibição embutida", + "sideBySideDiffLabel": "Alternar para exibição lado a lado" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/textEditor.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/textEditor.i18n.json new file mode 100644 index 00000000000..eb58230b854 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/textEditor.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorLabelWithGroup": "{0}, Grupo {1}." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/textResourceEditor.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/textResourceEditor.i18n.json new file mode 100644 index 00000000000..77f89efba5f --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/textResourceEditor.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "textEditor": "Editor de texto", + "readonlyEditorWithInputAriaLabel": "{0}. Editor de texto somente leitura.", + "readonlyEditorAriaLabel": "Editor de texto somente leitura.", + "untitledFileEditorWithInputAriaLabel": "{0}. Editor de texto de arquivo sem nome.", + "untitledFileEditorAriaLabel": "Editor de texto de arquivo sem nome." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/titleControl.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/titleControl.i18n.json new file mode 100644 index 00000000000..bf8307cd384 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/titleControl.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "close": "Fechar", + "closeOthers": "Fechar Outros", + "closeRight": "Fechar à direita", + "closeAll": "Fechar todos", + "keepOpen": "Manter aberto", + "showOpenedEditors": "Mostrar editores abertos", + "araLabelEditorActions": "Ações de editor" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/panel/panelActions.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/panel/panelActions.i18n.json new file mode 100644 index 00000000000..1f98f38c47e --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/panel/panelActions.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "panelActionTooltip": "{0} ({1})", + "closePanel": "Fechar Painel", + "togglePanel": "Alternar Painel", + "focusPanel": "Foco no Painel", + "toggleMaximizedPanel": "Alternar Painel Maximizado", + "maximizePanel": "Maximizar Tamanho do Painel", + "minimizePanel": "Restaurar tamanho do Painel", + "view": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/panel/panelPart.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/panel/panelPart.i18n.json new file mode 100644 index 00000000000..48a7b1b2f76 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/panel/panelPart.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "panelSwitcherBarAriaLabel": "Chave do Painel Ativo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/quickopen/quickOpenController.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/quickopen/quickOpenController.i18n.json new file mode 100644 index 00000000000..c98dd22d95d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/quickopen/quickOpenController.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "inputModeEntryDescription": "{0} (Pressione 'Enter' para confirmar ou 'Esc' para cancelar)", + "inputModeEntry": "Pressione 'Enter' para confirmar o texto digitado ou 'Esc' para cancelar", + "emptyPicks": "Não há entradas a serem escolhidas", + "quickOpenInput": "Digite '?' para obter ajuda sobre as ações que você pode realizar a partir daqui", + "historyMatches": "aberto recentemente", + "noResultsFound1": "Nenhum resultado encontrado", + "canNotRunPlaceholder": "Esse manipulador de abertura rápida não pode ser usado no contexto atual", + "entryAriaLabel": "{0}, recentemente aberto", + "removeFromEditorHistory": "Remover do Histórico", + "pickHistory": "Selecionar uma entrada do editor para remover do histórico" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/quickopen/quickopen.contribution.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/quickopen/quickopen.contribution.i18n.json new file mode 100644 index 00000000000..57f5524e1be --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/quickopen/quickopen.contribution.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpen": "Ir para o Arquivo...", + "quickNavigateNext": "Navegar ao próximo em modo de abertura rápida", + "quickNavigatePrevious": "Navegar ao anterior em modo de abertura rápida", + "quickSelectNext": "Selecionar próximo em modo de abertura rápida", + "quickSelectPrevious": "Selecionar anterior em modo de abertura rápida" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/sidebar/sidebarPart.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/sidebar/sidebarPart.i18n.json new file mode 100644 index 00000000000..89806e051ea --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/sidebar/sidebarPart.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "focusSideBar": "Foco na Barra Lateral", + "viewCategory": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/statusbar/statusbarPart.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/statusbar/statusbarPart.i18n.json new file mode 100644 index 00000000000..4a2adabf5a6 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/statusbar/statusbarPart.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "canNotRun": "O comando '{0}' não está habilitado e não pode ser executado.", + "manageExtension": "Gerenciar Extensão" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/titlebar/titlebarPart.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/titlebar/titlebarPart.i18n.json new file mode 100644 index 00000000000..1c3db4d572b --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/titlebar/titlebarPart.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "patchedWindowTitle": "[Sem Suporte]", + "devExtensionWindowTitlePrefix": "[Host de Desenvolvimento de Extensão]" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/quickopen.i18n.json b/i18n/ptb/src/vs/workbench/browser/quickopen.i18n.json new file mode 100644 index 00000000000..26c5e14f367 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/quickopen.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultsMatching": "Nenhum resultado encontrado", + "noResultsFound2": "Nenhum resultado encontrado", + "entryAriaLabel": "{0}, comando", + "noCommands": "Não há comandos correspondentes" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/viewlet.i18n.json b/i18n/ptb/src/vs/workbench/browser/viewlet.i18n.json new file mode 100644 index 00000000000..34655b736ba --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/viewlet.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "collapse": "Recolher tudo", + "viewToolbarAriaLabel": "{0} ações " +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/common/theme.i18n.json b/i18n/ptb/src/vs/workbench/common/theme.i18n.json new file mode 100644 index 00000000000..bfe4c0ef017 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/common/theme.i18n.json @@ -0,0 +1,44 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tabActiveBackground": "Cor de fundo da guia ativa. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", + "tabInactiveBackground": "Cor de fundo da guia inativa. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", + "tabBorder": "Borda para separar uma guia das outras. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", + "tabActiveEditorGroupActiveForeground": "Cor de primeiro plano da guia ativa em um grupo ativo. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", + "tabInactiveEditorGroupActiveForeground": "Cor de primeiro plano da guia inativa em um grupo ativo. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", + "editorGroupBackground": "Cor de fundo de um grupo de editor. Grupos de editor são os recipientes dos editores. A cor de fundo é mostrada ao arrastar o editor de grupos ao redor.", + "tabsContainerBackground": "Cor de fundo do cabeçalho do título do grupo de editor quando as guias são habilitadas. Grupos de editor são os recipientes dos editores.", + "editorGroupHeaderBackground": "Cor de fundo do título do cabeçalho do grupo de editor quando as guias são desabilitadas. Grupos de editor são os recipientes dos editores.", + "editorGroupBorder": "Cor para separar múltiplos grupos de editor de outro. Grupos de editor são os recipientes dos editores.", + "editorDragAndDropBackground": "Cor de fundo ao arrastar editores. A cor deve ter transparência para que o conteúdo do editor ainda possa ser visto.", + "panelBackground": "Cor de fundo do painel. Os painéis são mostrados abaixo da área do editor e contém visualizações como saída e terminal integrado.", + "panelBorder": "Cor da borda do painel no topo separando do editor. Os painéis são mostrados abaixo da área do editor e contém visualizações como saída e terminal integrado.", + "panelActiveTitleForeground": "Cor do título para o painel ativo. Os painéis são mostrados abaixo da área do editor e contém visualizações como saída e terminal integrado.", + "panelInactiveTitleForeground": "Cor do título para o painel inativo. Os painéis são mostrados abaixo da área do editor e contém visualizações como saída e terminal integrado.", + "panelActiveTitleBorder": "Cor da borda para o título do painel ativo. Os painéis são mostrados abaixo da área do editor e contém visualizações como saída e terminal integrado.", + "statusBarForeground": "Cor do primeiro plano da barra de status. A barra de status é mostrada na parte inferior da janela.", + "statusBarBackground": "Cor de fundo da barra de status padrão. A barra de status é mostrada na parte inferior da janela.", + "statusBarNoFolderBackground": "Cor de fundo da barra de status quando nenhuma pasta está aberta. A barra de status é mostrada na parte inferior da janela.", + "statusBarItemActiveBackground": "Cor de fundo do item da barra de status quando você clicado. A barra de status é mostrada na parte inferior da janela.", + "statusBarItemHoverBackground": "Cor de fundo do item da barra de status quando estiver passando sobre ele. A barra de status é mostrada na parte inferior da janela.", + "statusBarProminentItemBackground": "Cor de fundo de itens proeminentes da barra de status. Itens proeminentes destacam-se outras entradas da barra de status para indicar a importância. A barra de status é mostrada na parte inferior da janela.", + "statusBarProminentItemHoverBackground": "Cor de fundo dos itens proeminentes de barra de status quando estiver passando sobre eles. Itens proeminentes destacam-se outras entradas de barra de status para indicar a importância. A barra de status é mostrada na parte inferior da janela.", + "activityBarBackground": "Cor de fundo da barra de atividades. Barra de atividade está visível à esquerda ou à direita e permite alternar entre as visualizações da barra lateral.", + "activityBarForeground": "Cor de primeiro plano da barra de atividades (por exemplo, usada para os ícones). A barra de atividades está visível à esquerda ou à direita e permite alternar entre as visualizações da barra lateral.", + "activityBarDragAndDropBackground": "Cor de feedback de arrastar e soltar para os itens da barra de atividades. A cor deve ter transparência para que as entradas de bar de atividade ainda possam brilhar. A barra de atividade está visível à esquerda ou à direita e permite para alternar entre as visualizações da barra lateral.", + "activityBarBadgeBackground": "Cor de fundo da notificação de atividade. A barra de atividade está visível à esquerda ou à direita e permite alternar entre as visualizações da barra lateral.", + "activityBarBadgeForeground": "Cor de primeiro plano da notificação de atividade. A barra de atividade está visível à esquerda ou à direita e permite alternar entre as visualizações da barra lateral.", + "sideBarBackground": "Cor de fundo da barra lateral. A barra lateral é o recipiente para visualizações como explorador e pesquisa.", + "sideBarForeground": "Cor de primeiro plano da barra lateral. A barra lateral é o recipiente para visualizações como o explorador e a busca.", + "sideBarTitleForeground": "Cor de primeiro plano do título da barra lateral. A barra lateral é o recipiente para visualizações como explorador e pesquisa.", + "sideBarSectionHeaderBackground": "Cor de fundo do cabeçalho de seção lateral. A barra lateral é o recipiente para visões como explorador e pesquisa.", + "titleBarActiveForeground": "Cor da barra de título do primeiro plano quando a janela está ativa. Observe que essa cor atualmente somente é suportada no macOS.", + "titleBarInactiveForeground": "Cor de primeiro plano da barra de título quando a janela está inativa. Observe que essa cor atualmente somente é suportada no macOS.", + "titleBarActiveBackground": "Cor de fundo da barra de título quando a janela está ativa. Observe que essa cor atualmente somente é suportada no macOS.", + "titleBarInactiveBackground": "Cor de fundo de barra de título quando a janela está inativa. Observe que essa cor é atualmente somente suportada no macOS.", + "notificationsForeground": "Cor do primeiro plano de notificações. Notificações deslizam na parte superior da janela.", + "notificationsBackground": "Cor de fundo de notificações. Notificações deslizam na parte superior da janela." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/electron-browser/actions.i18n.json b/i18n/ptb/src/vs/workbench/electron-browser/actions.i18n.json new file mode 100644 index 00000000000..d829a3c8cad --- /dev/null +++ b/i18n/ptb/src/vs/workbench/electron-browser/actions.i18n.json @@ -0,0 +1,41 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "closeActiveEditor": "Fechar Editor", + "closeWindow": "Fechar Janela", + "switchWindow": "Alternar Janela", + "switchWindowPlaceHolder": "Selecionar uma janela", + "current": "Janela Atual", + "closeFolder": "Fechar Pasta", + "noFolderOpened": "Não há nenhuma pasta aberta nesta instância para ser fechada.", + "newWindow": "Nova Janela", + "toggleFullScreen": "Alternar Tela Inteira", + "toggleMenuBar": "Alternar Barra de Menus", + "toggleDevTools": "Alternar Ferramentas do Desenvolvedor", + "zoomIn": "Ampliar", + "zoomOut": "Reduzir", + "zoomReset": "Reinicializar Zoom", + "appPerf": "Desempenho de inicialização", + "reloadWindow": "Recarregar Janela", + "openRecent": "Abrir Recente", + "folders": "pastas", + "files": "arquivos", + "openRecentPlaceHolderMac": "Selecionar um caminho (Pressione a tecla Cmd para abrir em uma nova janela)", + "openRecentPlaceHolder": "Selecionar um caminho para abrir (Pressione a tecla Cmd para abrir em uma nova janela)", + "closeMessages": "Fechar mensagens de notificação", + "reportIssues": "Reportar Problemas", + "reportPerformanceIssue": "Reportar Problema de Desempenho", + "keybindingsReference": "Referência de Atalhos de Teclado", + "openDocumentationUrl": "Documentação", + "openIntroductoryVideosUrl": "Vídeos Introdutórios", + "toggleSharedProcess": "Alternar processo compartilhado", + "navigateLeft": "Mover para a Visualizção à Esquerda", + "navigateRight": "Mover para a Visualização à Direita", + "navigateUp": "Mover para a Visualização Acima", + "navigateDown": "Mover para a Visualização Abaixo", + "increaseViewSize": "Aumentar o Tamanho da Visualização Atual", + "decreaseViewSize": "Diminuir o Tamanho da Visualização Atual" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/electron-browser/commands.i18n.json b/i18n/ptb/src/vs/workbench/electron-browser/commands.i18n.json new file mode 100644 index 00000000000..3a1051dcfda --- /dev/null +++ b/i18n/ptb/src/vs/workbench/electron-browser/commands.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "diffLeftRightLabel": "{0} ⟷ {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/electron-browser/crashReporter.i18n.json b/i18n/ptb/src/vs/workbench/electron-browser/crashReporter.i18n.json new file mode 100644 index 00000000000..10b7a7ff108 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/electron-browser/crashReporter.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "telemetryConfigurationTitle": "Telemetria", + "telemetry.enableCrashReporting": "Ativar o envio de relatórios de incidentes à Microsoft.\nEsta opção requer reinicialização para ser efetivada." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/electron-browser/extensionHost.i18n.json b/i18n/ptb/src/vs/workbench/electron-browser/extensionHost.i18n.json new file mode 100644 index 00000000000..e5a7ab81686 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/electron-browser/extensionHost.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "extensionHostProcess.startupFailDebug": "O host de extensão não iniciou em 10 segundos, ele pode ser interrompido na primeira linha e precisa de um depurador para continuar.", + "extensionHostProcess.startupFail": "Host de extensão não começou em 10 segundos, isso pode ser um problema.", + "extensionHostProcess.error": "Erro do host de extensão: {0}", + "extensionHostProcess.crash": "Host de extensão foi encerrado inesperadamente. Por favor recarregar a janela para recuperar." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/ptb/src/vs/workbench/electron-browser/main.contribution.i18n.json new file mode 100644 index 00000000000..3b9050de1af --- /dev/null +++ b/i18n/ptb/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -0,0 +1,62 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "view": "Exibir", + "help": "Ajuda", + "file": "Arquivo", + "developer": "Desenvolvedor", + "showEditorTabs": "Controla se os editores abertos devem ou não serem exibidos em abas.", + "editorTabCloseButton": "Controla a posição dos botões de fechar das abas do editor ou os desabilita quando configurados para 'desligado'.", + "showIcons": "Controla se os editores abertos devem ou não ser exibidos com um ícone. Requer um tema de ícone para ser habilitado. ", + "enablePreview": "Controla se os editores abertos são exibidos como visualização. Editores de visualização são reutilizados até que eles sejam preservados (por exemplo, através de um duplo clique ou edição).", + "enablePreviewFromQuickOpen": "Controla se os editores abertos da Abertura Rápida são exibidos como visualização. Os editores de visualização são reutilizados até serem preservados (por exemplo, através de um duplo clique ou edição).", + "editorOpenPositioning": "Controla onde os editores serão abertos. Escolha 'esquerda' ou 'direita' para abrir os editores à esquerda ou à direita do \neditor ativo. Selecione 'primeiro' ou 'último' para abrir os editores independentemente do atual.", + "revealIfOpen": "Controla se um editor é exibido em qualquer um dos grupos, se aberto. Se desabilitado, um editor será aberto preferencialmente no grupo de editores ativo. Se habilitado, um editor já aberto será exibido no grupo de editores ativo, ao invés de ser aberto novamente. Note que há alguns casos onde esta configuração é ignorada, por exemplo, quando for forçada a abertura de um editor em um grupo específico ou ao lado do grupo atualmente ativo.", + "closeOnFocusLost": "Controla se Abertura Rápida deve fechar automaticamente caso perca o foco.", + "openDefaultSettings": "Controla se a abertura de configurações também abre um editor mostrando todas as configurações padrão.", + "sideBarLocation": "Controla a localização da barra lateral. Ele pode ser exibido à esquerda ou à direita da área de trabalho.", + "statusBarVisibility": "Controla a visibilidade da barra de status na parte inferior da área de trabalho.", + "activityBarVisibility": "Controla a visibilidade da barra de atividades na área de trabalho.", + "closeOnFileDelete": "Controla se os editores que mostram um arquivo devem fechar automaticamente quanto o arquivo é apagado ou renomeado por algum outro processo. Desativar isso manterá o editor aberto como sujo neste evento. Note que apagar do aplicativo sempre fechará o editor e os arquivos sujos nunca fecharão para preservar seus dados.", + "swipeToNavigate": "Navegue entre arquivos abertos usando o deslizamento horizontal de três dedos.", + "workbenchConfigurationTitle": "Ãrea de Trabalho", + "window.openFilesInNewWindow.on": "Arquivos serão abertos em uma nova janela", + "window.openFilesInNewWindow.off": "Arquivos serão abertos em uma nova janela com a pasta de arquivos aberta ou com a última janela ativa.", + "window.openFilesInNewWindow.default": "Os arquivos serão abertos na janela com a pasta de arquivos aberta ou a última janela ativa, a menos que seja aberto através do dock ou do finder (somente macOS)", + "openFilesInNewWindow": "Controla se os arquivos devem ser abertos em uma nova janela\n- padrão: os arquivos serão abertos em uma nova janela com a pasta de arquivos aberta ou na última janela ativa, a menos que seja aberta através do dock ou do finder (apenas macOS)\n- ligado: os arquivos serão abertos em uma nova janela\n- desligado: os arquivos serão abertos em uma janela com a pasta de arquivos aberta ou a última janela ativa\nNota que ainda podem haver casos em que esta configuração será ignorada (por exemplo, quando estiver usando as opções de linha de comando -new-window ou -reuse-window).", + "window.openFoldersInNewWindow.on": "As pastas serão abertas em uma nova janela", + "window.openFoldersInNewWindow.off": "As pastas substituirão a última janela ativa", + "window.openFoldersInNewWindow.default": "As pastas serão abertas em uma nova janela, a menos que uma pasta seja selecionada dentro do aplicativo (por exemplo, através do menu Arquivo)", + "openFoldersInNewWindow": "Controla se as pastas devem ser abertas em uma nova janela ou substituir a última janela ativa\n- padrão: as pastas serão abertas em uma nova janela, a menos que seja selecionada dentro do aplicativo (por exemplo, através do menu Arquivo)\n- ligado: as pastas serão abertas em uma nova janela\n- desligado: as pastas substituirão a última janela ativa\nNote que ainda podem haver casos em que esta configuração será ignorada (por exemplo, quando estiver usando as opções de linha de comando -new-window ou -reuse-window).", + "window.reopenFolders.none": "Nunca reabra uma pasta.", + "window.reopenFolders.one": "Reabrir a última pasta ativa.", + "window.reopenFolders.all": "Reabrir todas as pastas da última sessão.", + "reopenFolders": "Controla como as pastas são reabertas depois de um reinício. Escolha 'nenhum' para nunca reabrir uma pasta, 'uma' para reabrir a última pasta que você trabalhou ou 'todas' para reabrir todas as pastas da sua última sessão.", + "restoreFullscreen": "Controla se uma janela deve ser restaurada em modo de tela cheia se ela foi finalizada em modo de tela cheia.", + "zoomLevel": "Ajusta o nível de zoom da janela. O tamanho original é 0 e cada aumento (por exemplo, 1) ou redução (por exemplo, -1) representa um zoom 20% maior ou menor. Você também pode digitar decimais para ajustar o nível de zoom com uma granularidade mais fina.", + "title": "Controla o título da janela com base no editor ativo. As variáveis são substituídas com base no contexto:\n$ {ActiveEditorShort}: por exemplo, meuArquivo.txt\n$ {ActiveEditorMedium}: por exemplo, minhaPasta / meuArquivo.txt\n$ {ActiveEditorLong}: por exemplo, /Usuários/Desenvolvimento/meuProjeto/minhaPasta/meuArquivo.txt\n$ {RootName}: por exemplo, meuProjeto\n$ {RootPath}: por exemplo, /Usuários/Desenvolvimento/meuProjeto\n$ {AppName}: por exemplo, VS Code\n$ {Dirty}: um indicador sujo se o editor ativo for sujo\n$ {Separator}: um separador condicional (\"-\") que só aparece quando for rodeado por variáveis com valores", + "window.newWindowDimensions.default": "Abrir novas janelas no centro da tela.", + "window.newWindowDimensions.inherit": "Abrir novas janelas com a mesma dimensão da última janela ativa.", + "window.newWindowDimensions.maximized": "Abrir novas janelas maximizadas.", + "window.newWindowDimensions.fullscreen": "Abrir novas janelas em modo de tela cheia.", + "newWindowDimensions": "Controla as dimensões ao abrir uma nova janela quando pelo menos uma janela já está aberta. Por padrão, uma nova janela será aberta no centro da tela com pequena dimensão. Quando definido como 'inherit', a janela vai ter as mesmas dimensões que a última janela que estava ativa. Quando definido como 'maximized', a janela abrirá maximizada e em tela cheia se configurado para 'fullscreen'. Observe que essa configuração não tem um impacto sobre a primeira janela que é aberta. A primeira janela sempre irá restaurar o tamanho e a localização como você deixou antes de fechar.", + "window.menuBarVisibility.default": "O menu está oculto apenas em modo de tela cheia.", + "window.menuBarVisibility.visible": "O menu está sempre visivel mesmo quando em modo de tela cheia.", + "window.menuBarVisibility.toggle": "O menu está oculto, mas pode ser mostrado através da tecla Alt.", + "window.menuBarVisibility.hidden": "O menu está sempre oculto.", + "menuBarVisibility": "Controla a visibilidade da barra de menu. Uma configuração 'alternar' significa que a barra de menus está oculta e pressionar a tecla Alt irá mostrá-la. Por padrão, a barra de menu será visível, a menos que a janela esteja em modo de tela cheia.", + "enableMenuBarMnemonics": "Se habilitado, os menus principais podem ser abertos através de atalhos de tecla Alt. Desativar mnemônicos permite vincular esses atalhos de tecla Alt para comandos do editor.", + "autoDetectHighContrast": "Se habilitado, irá mudar automaticamente para o tema de alto contraste se o Windows estiver utilizando um tema de alto contraste, e para o tema escuro ao mudar de um tema de alto contraste do Windows.", + "titleBarStyle": "Ajusta a aparência da barra de título da janela. As alterações exigem um reinício completo.", + "window.nativeTabs": "Habilita as abas da janela do macOS Sierra. Note que as alterações exigem um reinício completo e que as abas nativas desabilitarão um estilo de barra de título customizado, se configurado.", + "windowConfigurationTitle": "Janela", + "zenModeConfigurationTitle": "Modo Zen", + "zenMode.fullScreen": "Controla se a ativação do modo Zen também coloca o espaço de trabalho em modo de tela cheia.", + "zenMode.hideTabs": "Controla se a ativação do modo Zen também oculta as abas do espaço de trabalho.", + "zenMode.hideStatusBar": "Controla se a ativação do modo Zen também oculta a barra de status no rodapé do espaço de trabalho.", + "zenMode.hideActivityBar": "Controla se a ativação do modo Zen também oculta a barra de atividades à esquerda do espaço de trabalho.", + "zenMode.restore": "Controla se uma janela deve ser restaurada para o modo zen se ela foi finalizada no modo zen." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/electron-browser/main.i18n.json b/i18n/ptb/src/vs/workbench/electron-browser/main.i18n.json new file mode 100644 index 00000000000..056d426d27d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/electron-browser/main.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "loaderError": "Falha ao carregar o arquivo necessário. Você não está mais conectado à Internet ou o servidor que você está conectado está offline. Atualize o navegador e tente novamente.", + "loaderErrorNative": "Falha ao carregar um arquivo necessário. Reinicie o aplicativo para tentar novamente. Detalhes: {0}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/electron-browser/shell.i18n.json b/i18n/ptb/src/vs/workbench/electron-browser/shell.i18n.json new file mode 100644 index 00000000000..951a140a2ea --- /dev/null +++ b/i18n/ptb/src/vs/workbench/electron-browser/shell.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "runningAsRoot": "Não é recomendado executar Code como 'root'." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/electron-browser/window.i18n.json b/i18n/ptb/src/vs/workbench/electron-browser/window.i18n.json new file mode 100644 index 00000000000..50118b77afe --- /dev/null +++ b/i18n/ptb/src/vs/workbench/electron-browser/window.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "undo": "Desfazer", + "redo": "Refazer", + "cut": "Recortar", + "copy": "Copiar", + "paste": "Colar", + "selectAll": "Selecionar Tudo", + "confirmOpen": "Tem certeza de que deseja abrir '{0}' pastas?", + "confirmOpenButton": "&&Abrir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/node/extensionHostMain.i18n.json b/i18n/ptb/src/vs/workbench/node/extensionHostMain.i18n.json new file mode 100644 index 00000000000..f0596b25871 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/node/extensionHostMain.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "extensionTestError": "Caminho {0} não aponta para um executor de testes com extensão válida." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/node/extensionPoints.i18n.json b/i18n/ptb/src/vs/workbench/node/extensionPoints.i18n.json new file mode 100644 index 00000000000..18d7b3f26c8 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/node/extensionPoints.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "jsonParseFail": "Falha ao analisar {0}: {1}.", + "fileReadFail": "Não foi possível ler o arquivo {0}: {1}.", + "jsonsParseFail": "Falha ao analisar {0} ou {1}: {2}.", + "missingNLSKey": "Não foi possível encontrar a mensagem para a chave {0}." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/cli/electron-browser/cli.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/cli/electron-browser/cli.contribution.i18n.json new file mode 100644 index 00000000000..69df9b15d87 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/cli/electron-browser/cli.contribution.i18n.json @@ -0,0 +1,18 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "install": "Instalar o comando '{0}' em PATH", + "not available": "Este comando não está disponível", + "successIn": "Comando shell '{0}' instalado com sucesso em PATH.", + "warnEscalation": "O código solicitará com 'osascript' pelos privilégios de Administrador para instalar o comando shell.", + "ok": "OK", + "cantCreateBinFolder": "Não é possível criar '/usr/local/bin'.", + "cancel2": "Cancelar", + "aborted": "Abortado", + "uninstall": "Desinstalar o comando '{0}' de PATH", + "successFrom": "Comando shell '{0}' desinstalado com sucesso de PATH.", + "shellCommand": "Comando shell" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json new file mode 100644 index 00000000000..18ee740ae31 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "workbench.action.inspectKeyMap": "Desenvolvedor: Inspecionar Mapeamentos de Chave" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderControlCharacter.i18n.json b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderControlCharacter.i18n.json new file mode 100644 index 00000000000..217bdf1c04e --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderControlCharacter.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleRenderControlCharacters": "Alternar caracteres de controle" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderWhitespace.i18n.json b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderWhitespace.i18n.json new file mode 100644 index 00000000000..453104fcc6d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderWhitespace.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleRenderWhitespace": "Alternar Espaço em Branco Renderizado" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json new file mode 100644 index 00000000000..058048058af --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggle.wordwrap": "Visualizar: Alternar Quebra de Linha", + "wordWrap.notInDiffEditor": "Não pode alternar quebra de linha em um editor diff.", + "unwrapMinified": "Desabilitar empacotamento para este arquivo", + "wrapMinified": "Habilitar empacotamento para este arquivo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/wordWrapMigration.i18n.json b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/wordWrapMigration.i18n.json new file mode 100644 index 00000000000..12f93be687c --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/wordWrapMigration.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "wordWrapMigration.ok": "OK", + "wordWrapMigration.dontShowAgain": "Não mostrar novamente", + "wordWrapMigration.openSettings": "Abrir configurações", + "wordWrapMigration.prompt": "A configuração `editor.wrappingColumn` foi descontinuada e substituída pela configuração `editor.wordWrap`" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/browser/breakpointWidget.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/browser/breakpointWidget.i18n.json new file mode 100644 index 00000000000..3d748795633 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/browser/breakpointWidget.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "breakpointWidgetExpressionPlaceholder": "Parar quando a expressão for avaliada como true. 'Enter' para aceitar, 'esc' para cancelar.", + "breakpointWidgetAriaLabel": "O programa só vai parar aqui se esta condição for verdadeira. Pressione Enter para aceitar ou Escape para cancelar.", + "breakpointWidgetHitCountPlaceholder": "Parar quando contagem de ocorrências condição for alcançada. 'Enter' para aceitar, 'esc' para cancelar.", + "breakpointWidgetHitCountAriaLabel": "O programa só vai parar aqui, se a contagem de ocorrências for alcançada. Pressione Enter para aceitar ou Escape para cancelar.", + "expression": "Expressão", + "hitCount": "Contagem de ocorrências" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/browser/debugActionItems.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugActionItems.i18n.json new file mode 100644 index 00000000000..32a88b85efd --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugActionItems.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "addConfiguration": "Adicionar Configuração...", + "noConfigurations": "Sem configurações" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/browser/debugActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugActions.i18n.json new file mode 100644 index 00000000000..1bc052297a1 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugActions.i18n.json @@ -0,0 +1,49 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openLaunchJson": "Abrir {0}", + "launchJsonNeedsConfigurtion": "Configurar ou corrigir 'launch.json'", + "noFolderDebugConfig": "Primeiro abra uma pasta para fazer uma configuração de depuração avançada.", + "startDebug": "Iniciar Depuração", + "startWithoutDebugging": "Iniciar Sem Depuração", + "selectAndStartDebugging": "Selecionar e Iniciar a Depuração", + "restartDebug": "Reiniciar", + "reconnectDebug": "Reconectar", + "stepOverDebug": "Pular Sobre", + "stepIntoDebug": "Pular Dentro", + "stepOutDebug": "Pular Fora", + "stopDebug": "Parar", + "disconnectDebug": "Desconectar", + "continueDebug": "Continuar", + "pauseDebug": "Pausa", + "restartFrame": "Reiniciar o Frame", + "removeBreakpoint": "Remover Ponto de Parada", + "removeAllBreakpoints": "Remover Todos os Pontos de Parada", + "enableBreakpoint": "Habilitar ponto de Parada", + "disableBreakpoint": "Desativar Ponto de Parada", + "enableAllBreakpoints": "Habilitar Todos os Pontos de Parada", + "disableAllBreakpoints": "Desabilitar Todos Pontos de Parada", + "activateBreakpoints": "Ativar Pontos de Parada", + "deactivateBreakpoints": "Desativar Pontos de Parada", + "reapplyAllBreakpoints": "Reaplicar Todos os Pontos de Parada", + "addFunctionBreakpoint": "Adicionar Ponto de Parada de Função", + "renameFunctionBreakpoint": "Renomeie o Ponto de Parada de Função", + "addConditionalBreakpoint": "Adicionar Ponto de Parada Condicional...", + "editConditionalBreakpoint": "Editar o Ponto de Parada...", + "setValue": "Definir Valor", + "addWatchExpression": "Adicionar Expressão", + "editWatchExpression": "Editar expressão", + "addToWatchExpressions": "Adicionar ao monitoramento", + "removeWatchExpression": "Remover Expressão", + "removeAllWatchExpressions": "Remover Todas as Expressões", + "clearRepl": "Limpar console", + "debugConsoleAction": "Console do Depurador", + "unreadOutput": "Nova Saída no Console de Depuração", + "debugFocusConsole": "Foco no Console de Depuração", + "focusProcess": "Foco no Processo", + "stepBackDebug": "Passo para trás", + "reverseContinue": "Reverter" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/browser/debugActionsWidget.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugActionsWidget.i18n.json new file mode 100644 index 00000000000..421e5b19c79 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugActionsWidget.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "debugToolBarBackground": "Cor de fundo da barra de ferramentas de depuração." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/browser/debugContentProvider.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugContentProvider.i18n.json new file mode 100644 index 00000000000..d8aa95c869a --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugContentProvider.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "unable": "Não é possível resolver o recurso sem uma sessão de depuração" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/browser/debugEditorActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugEditorActions.i18n.json new file mode 100644 index 00000000000..ef74c88413d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugEditorActions.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleBreakpointAction": "Depurar: Alternar Ponto de Parada", + "columnBreakpointAction": "Depurar: Ponto de Interrupção de Coluna", + "columnBreakpoint": "Adicionar Ponto de Interrupção de Coluna", + "conditionalBreakpointEditorAction": "Depurar: Adicionar Ponto de Interrupção Condicional...", + "runToCursor": "Executar até o Cursor", + "debugEvaluate": "Depurar: Avaliar", + "debugAddToWatch": "Depurar: Adicionar ao monitoramento", + "showDebugHover": "Mostrar Item Flutuante" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/browser/debugEditorModelManager.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugEditorModelManager.i18n.json new file mode 100644 index 00000000000..f30b378456b --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugEditorModelManager.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "breakpointDisabledHover": "Ponto de Parada Desativado", + "breakpointUnverifieddHover": "Ponto de Parada Não Verificado", + "breakpointDirtydHover": "Ponto de parada não verificado. O arquivo foi modificado, por favor reinicie a sessão de depuração.", + "breakpointUnsupported": "Pontos de parada condicionais não são suportados por esse tipo de depurador" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/browser/debugQuickOpen.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugQuickOpen.i18n.json new file mode 100644 index 00000000000..01955c44965 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/browser/debugQuickOpen.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "depurar {0}", + "debugAriaLabel": "Digite um nome de uma configuração de lançamento para ser executado.", + "noConfigurationsMatching": "Não há configurações de depuração correspondentes", + "noConfigurationsFound": "Configurações de depuração não encontradas. Por favor, crie um arquivo 'launch.json'." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/browser/exceptionWidget.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/browser/exceptionWidget.i18n.json new file mode 100644 index 00000000000..a8802c13164 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/browser/exceptionWidget.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "debugExceptionWidgetBorder": "Cor da borda da ferramenta de exceção.", + "debugExceptionWidgetBackground": "Cor de fundo da ferramenta de exceção.", + "exceptionThrownWithId": "Ocorreu exceção: {0}", + "exceptionThrown": "Ocorreu exceção." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/browser/linkDetector.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/browser/linkDetector.i18n.json new file mode 100644 index 00000000000..8c7a8761f41 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/browser/linkDetector.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "fileLinkMac": "Clique para seguir (Cmd + clique abre ao lado)", + "fileLink": "Clique para seguir (Cmd + clique abre ao lado)" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/common/debug.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/common/debug.i18n.json new file mode 100644 index 00000000000..3476b79d9e1 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/common/debug.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "internalConsoleOptions": "Controla o comportamento do console depuração interna." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/common/debugModel.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/common/debugModel.i18n.json new file mode 100644 index 00000000000..fa2f5e8ada5 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/common/debugModel.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "notAvailable": "não disponível", + "startDebugFirst": "Por favor, inicie uma sessão de depuração para avaliar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/common/debugSource.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/common/debugSource.i18n.json new file mode 100644 index 00000000000..0e10c85d818 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/common/debugSource.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "unknownSource": "Fonte desconhecida" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debug.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debug.contribution.i18n.json new file mode 100644 index 00000000000..05a7ccfe827 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debug.contribution.i18n.json @@ -0,0 +1,20 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleDebugViewlet": "Visualizar Depurador", + "toggleDebugPanel": "Console do Depurador", + "debug": "Depurar", + "debugPanel": "Console do Depurador", + "view": "Exibir", + "debugCategory": "Depurar", + "debugCommands": "Configuração do Depurador", + "debugConfigurationTitle": "Depurar", + "allowBreakpointsEverywhere": "Permite definir um ponto de interrupção em qualquer arquivo.", + "openExplorerOnEnd": "Automaticamente abre a visualização do explorador no final de uma sessão de depuração", + "inlineValues": "Mostrar valores de variáveis em linha no editor durante a depuração", + "hideActionBar": "Controlar se a barra de ação flutuante do depurador deve ser ocultada", + "launch": "Configuração global do lançamento do depurador. Deve ser usado como uma alternativa para o arquivo 'launch.json' que é compartilhado entre os espaços de trabalho" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json new file mode 100644 index 00000000000..85b353a37fe --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noFolderDebugConfig": "Primeiro abra uma pasta para fazer uma configuração de depuração avançada." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugConfigurationManager.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugConfigurationManager.i18n.json new file mode 100644 index 00000000000..ada60277e7b --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugConfigurationManager.i18n.json @@ -0,0 +1,38 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.debuggers": "Contribui adaptadores de depuração.", + "vscode.extension.contributes.debuggers.type": "Identificador único para esse adaptador de depuração.", + "vscode.extension.contributes.debuggers.label": "Nome de exibição para esse adaptador de depuração.", + "vscode.extension.contributes.debuggers.program": "Caminho para o programa adaptador de depuração. O caminho pode ser absoluto ou relativo à pasta de extensão.", + "vscode.extension.contributes.debuggers.args": "Argumentos opcionais a serem informados para o adaptador.", + "vscode.extension.contributes.debuggers.runtime": "Runtime opcional no caso do atributo do programa não ser um executável, mas requerer um runtime.", + "vscode.extension.contributes.debuggers.runtimeArgs": "Argumentos opcionais do runtime.", + "vscode.extension.contributes.debuggers.variables": "Mapeamento de variáveis interativas (por exemplo ${action.pickProcess}) em 'launch.json' para um comando.", + "vscode.extension.contributes.debuggers.initialConfigurations": "Configurações para gerar o 'launch.json' inicial.", + "vscode.extension.contributes.debuggers.languages": "Lista de idiomas para os quais a extensão de depuração pode ser considerada o \"depurador padrão\".", + "vscode.extension.contributes.debuggers.adapterExecutableCommand": "Se especificado VS Code chamará este comando para determinar o caminho do executável do adaptador de depuração e os argumentos para passar.", + "vscode.extension.contributes.debuggers.startSessionCommand": "Se especificado VS Code chamará este comando para as ações de \"depurar\" ou \"executar\" direcionadas para esta extensão.", + "vscode.extension.contributes.debuggers.configurationSnippets": "Trechos de código para adicionar novas configurações em 'launch.json'.", + "vscode.extension.contributes.debuggers.configurationAttributes": "Configurações de esquema JSON para validar 'launch.json'.", + "vscode.extension.contributes.debuggers.windows": "Configurações específicas do Windows.", + "vscode.extension.contributes.debuggers.windows.runtime": "Runtime usado para Windows.", + "vscode.extension.contributes.debuggers.osx": "Configurações específicas do OS X.", + "vscode.extension.contributes.debuggers.osx.runtime": "Runtime usado para o OS X.", + "vscode.extension.contributes.debuggers.linux": "Configurações específicas do Linux.", + "vscode.extension.contributes.debuggers.linux.runtime": "Runtime usado para o Linux.", + "vscode.extension.contributes.breakpoints": "Contribui aos pontos de interrupção.", + "vscode.extension.contributes.breakpoints.language": "Permitir pontos de parada para este idioma.", + "app.launch.json.title": "Executar", + "app.launch.json.version": "Versão deste formato de arquivo.", + "app.launch.json.configurations": "Lista de configurações. Adicionar novas configurações ou editar as existentes usando o IntelliSense.", + "app.launch.json.compounds": "Lista de compostos. Cada composto faz referência a várias configurações que vão ser executadas juntas.", + "app.launch.json.compound.name": "Nome do composto. Aparece no menu drop-down da configuração de execução.", + "app.launch.json.compounds.configurations": "Nomes das configurações que serão iniciadas como parte deste composto.", + "debugNoType": "'type' do adaptador de depuração não pode ser omitido e deve ser do tipo 'string'.", + "DebugConfig.failed": "Não é possível criar o arquivo 'launch.json' dentro da pasta '.vscode' ({0}).", + "selectDebug": "Selecione o ambiente" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.i18n.json new file mode 100644 index 00000000000..1424499bfcc --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.i18n.json @@ -0,0 +1,20 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "removeBreakpoints": "Remover pontos de interrupção", + "removeBreakpointOnColumn": "Remover ponto de interrupção na coluna {0}", + "removeLineBreakpoint": "Remover ponto de interrupção de linha", + "editBreakpoints": "Editar pontos de interrupção", + "editBreakpointOnColumn": "Editar o ponto de interrupção na coluna {0}", + "editLineBrekapoint": "Editar o ponto de interrupção de linha", + "enableDisableBreakpoints": "Habilitar/Desabilitar pontos de interrupção", + "disableColumnBreakpoint": "Desabilitar ponto de interrupção na coluna {0}", + "disableBreakpointOnLine": "Desabilitar ponto de interrupção de linha", + "enableBreakpoints": "Habilitar o ponto de interrupção na coluna {0}", + "enableBreakpointOnLine": "Habilitar o ponto de interrupção de linha", + "addBreakpoint": "Adicionar ponto de interrupção", + "addConfiguration": "Adicionar Configuração..." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugHover.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugHover.i18n.json new file mode 100644 index 00000000000..1853865a1ec --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugHover.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "treeAriaLabel": "Depurar passando o mouse por cima" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json new file mode 100644 index 00000000000..6dc0bc48afb --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json @@ -0,0 +1,25 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "snapshotObj": "Apenas valores primitivos são mostrados para este objeto.", + "debuggingStarted": "Depuração Iniciada.", + "debuggingPaused": "Depuração pausada, razão {0}, {1} {2}", + "debuggingStopped": "Depuração parada.", + "breakpointAdded": "Adicionado ponto de interrupção, linha {0}, arquivo {1}", + "breakpointRemoved": "Ponto de interrupção removido, linha {0}, arquivo {1}", + "compoundMustHaveConfigurations": "Composição deve ter o atributo \"configurations\" definido para iniciar várias configurações.", + "configMissing": "Configuração '{0}' não tem 'launch.json'.", + "debugTypeNotSupported": "Tipo de depuração configurado '{0}' não é suportado.", + "debugTypeMissing": "Falta a propriedade 'type' para a configuração de lançamento escolhida.", + "preLaunchTaskErrors": "Erros de build foram detectados durante a preLaunchTask '{0}'.", + "preLaunchTaskError": "Erro de build foi detectado durante a preLaunchTask '{0}'.", + "preLaunchTaskExitCode": "A preLaunchTask '{0}' encerrada com código de saída {1}.", + "debugAnyway": "Depurar mesmo assim", + "noFolderWorkspaceDebugError": "O arquivo ativo não pode ser depurado. Certifique-se de que ele está salvo no disco e que tem uma extensão de depuração instalada para esse tipo de arquivo.", + "NewLaunchConfig": "Por favor, configure o arquivo de configuração de lançamento para seu aplicativo. {0}", + "DebugTaskNotFound": "Não foi possível encontrar o preLaunchTask '{0}'.", + "differentTaskRunning": "Há uma tarefa {0} sendo executada. Não pode executar a tarefa de pré-lançamento {1}." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugViewer.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugViewer.i18n.json new file mode 100644 index 00000000000..ae47cc6a47d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugViewer.i18n.json @@ -0,0 +1,28 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "process": "Processar", + "paused": "Em pausa", + "running": "Em execução", + "thread": "Thread", + "pausedOn": "Pausado em {0}", + "loadMoreStackFrames": "Carregar mais segmentos de pilha", + "threadAriaLabel": "Thread {0}, pilha de chamadas, depuração", + "stackFrameAriaLabel": "Segmento de Pilha {0} linha {1} {2}, pilha de chamadas, depuração", + "variableValueAriaLabel": "Digite o novo valor da variável", + "variableScopeAriaLabel": "Escopo {0}, variáveis, depuração", + "variableAriaLabel": "{0} valor {1}, variáveis, depuração", + "watchExpressionPlaceholder": "Expressão para monitorar", + "watchExpressionInputAriaLabel": "Digitar expressão a monitorar", + "watchExpressionAriaLabel": "{0} valor {1}, monitorar, depuração", + "watchVariableAriaLabel": "{0} valor {1}, monitorar, depuração", + "functionBreakpointPlaceholder": "Função de parada", + "functionBreakPointInputAriaLabel": "Digitar Ponto de Parada de Função", + "functionBreakpointsNotSupported": "Pontos de parada de função não são suportados por este tipo de depuração", + "breakpointAriaLabel": "Ponto de parada linha {0} {1}, pontos de parada, depuração", + "functionBreakpointAriaLabel": "Ponto de parada de função {0}, pontos de parada, depuração", + "exceptionBreakpointAriaLabel": "Ponto de parada de exceção {0}, pontos de parada, depuração" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json new file mode 100644 index 00000000000..d14c4338ceb --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json @@ -0,0 +1,20 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "variablesSection": "Seção de variáveis", + "variables": "Variáveis", + "variablesAriaTreeLabel": "Variáveis de Depuração", + "expressionsSection": "Seção de Expressões", + "watch": "Monitoramento", + "watchAriaTreeLabel": "Depurar Expressões Monitoradas", + "callstackSection": "Seção de Pilha de Chamada", + "debugStopped": "Pausado em {0}", + "callStack": "Pilha de Chamadas", + "callStackAriaLabel": "Depurar a Pilha de Chamadas", + "breakpointsSection": "Seção de Pontos de Parada", + "breakpoints": "Pontos de Parada", + "breakpointsAriaTreeLabel": "Depurar os Pontos de Parada" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json new file mode 100644 index 00000000000..227ca95927f --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "copyValue": "Copiar valor", + "copy": "Copiar", + "copyAll": "Copiar todos", + "copyStackTrace": "Copiar Pilha de Chamadas" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.i18n.json new file mode 100644 index 00000000000..0ce97a8f796 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "moreInfo": "Mais Informações", + "unableToLaunchDebugAdapter": "Não é possível executar o adaptador de depuração de '{0}'.", + "unableToLaunchDebugAdapterNoArgs": "Não é possível executar o adaptador de depuração.", + "stoppingDebugAdapter": "{0}. Parando o adaptador de depuração.", + "debugAdapterCrash": "Processo do adaptador de depuração foi finalizado inesperadamente" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/repl.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/repl.i18n.json new file mode 100644 index 00000000000..73f6f0be4c4 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/repl.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "replAriaLabel": "Ler o Painel de Impressão Eval", + "actions.repl.historyPrevious": "História anterior", + "actions.repl.historyNext": "Próxima história", + "actions.repl.acceptInput": "REPL Aceitar Entrada" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/replViewer.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/replViewer.i18n.json new file mode 100644 index 00000000000..4afd6d64d82 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/replViewer.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "stateCapture": "Estado do objeto é capturado na primeira avaliação", + "replVariableAriaLabel": "Variável {0} tem valor {1}, ler a impressão do valor do loop, depurar", + "replExpressionAriaLabel": "Expressão {0} tem valor {1}, ler o laço de avaliação de impressão, depurar", + "replValueOutputAriaLabel": " impressão da avaliação do laço de leitura, depurar", + "replKeyValueOutputAriaLabel": "Variável de saída {0} tem valor {1}, ler o loop de avaliação de impressão, depurar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json new file mode 100644 index 00000000000..b191a0de856 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "statusBarDebuggingBackground": "Cor de fundo da barra de status quando um programa está sendo depurado. A barra de status é mostrada na parte inferior da janela" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/terminalSupport.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/terminalSupport.i18n.json new file mode 100644 index 00000000000..898a18605fb --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/terminalSupport.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "debug.terminal.title": "depurado", + "debug.terminal.not.available.error": "Terminal integrado não disponível" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json new file mode 100644 index 00000000000..f0551dfe57b --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json @@ -0,0 +1,20 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "debugAdapterBinNotFound": "Executável do adaptador de depuração '{0}' não existe.", + "debugAdapterCannotDetermineExecutable": "Não é possível determinar o executável para o adaptador de depuração '{0}'.", + "debugType": "Tipo de configuração.", + "debugTypeNotRecognised": "O tipo de depuração não é reconhecido. Certifique-se de que você tem uma extensão de depuração correspondente instalada e que ela está habilitada.", + "node2NotSupported": "\"node2\" não é mais suportado, use \"node\" ao invés e defina o atributo \"protocol\" para \"inspector\".", + "debugName": "Nome da configuração; aparece no menu drop-down da configuração de lançamento. ", + "debugRequest": "Requer o tipo de configuração. Pode ser \"launch\" ou \"attach\".", + "debugServer": "Somente para o desenvolvimento de extensão de depuração: se uma porta é especificada, o VS Code tenta se conectar a um adaptador de depuração executando em modo de servidor", + "debugPrelaunchTask": "Tarefa para ser executada antes de começar a sessão de depuração.", + "debugWindowsConfiguration": "Atributos de configuração de lançamento específicos do Windows.", + "debugOSXConfiguration": "Atributos de configuração de lançamento específicos do OS X.", + "debugLinuxConfiguration": "Atributos de configuração de lançamento específicos do Linux.", + "deprecatedVariables": "'env.', 'config.' e 'command.' foram descontinuados, use ' env:', ' config:' e ' command:' em vez disso." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/browser/actions/showEmmetCommands.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/browser/actions/showEmmetCommands.i18n.json new file mode 100644 index 00000000000..1e3a1c0f277 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/browser/actions/showEmmetCommands.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "showEmmetCommands": "Mostrar Comandos do Emmet" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/balance.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/balance.i18n.json new file mode 100644 index 00000000000..1dc5e1e3b69 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/balance.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "balanceInward": "Emmet: Saldo (interno)", + "balanceOutward": "Emmet: Saldo (externo)" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json new file mode 100644 index 00000000000..cccc82d8a01 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "previousEditPoint": "Emmet: Ponto de edição anterior", + "nextEditPoint": "Emmet: Ponto próxima edição" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json new file mode 100644 index 00000000000..b4a6a03e213 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "evaluateMathExpression": "Emmet: Avaliar a expressão matemática" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.i18n.json new file mode 100644 index 00000000000..5a5dd3cc3e8 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "expandAbbreviationAction": "Emmet: Expandir Abreviação" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json new file mode 100644 index 00000000000..306332a4af2 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "incrementNumberByOneTenth": "Emmet: Incremento de 0.1", + "incrementNumberByOne": "Emmet: Incremento de 1", + "incrementNumberByTen": "Emmet: Incremento de 10", + "decrementNumberByOneTenth": "Emmet: Decréscimo por 0.1", + "decrementNumberByOne": "Emmet: Decréscimo por 1", + "decrementNumberByTen": "Emmet: Decréscimo por 10" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/matchingPair.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/matchingPair.i18n.json new file mode 100644 index 00000000000..6a742c4d5f9 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/matchingPair.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "matchingPair": "Emmet: Ir para o par de correspondência" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/mergeLines.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/mergeLines.i18n.json new file mode 100644 index 00000000000..22ed3f5f533 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/mergeLines.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "mergeLines": "Emmet: Mesclar linhas" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/reflectCssValue.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/reflectCssValue.i18n.json new file mode 100644 index 00000000000..bc0eefc2e00 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/reflectCssValue.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "reflectCSSValue": "Emmet: Refletir valor CSS" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json new file mode 100644 index 00000000000..a30414b08d2 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "removeTag": "Emmet: Remover Rótulo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/selectItem.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/selectItem.i18n.json new file mode 100644 index 00000000000..1343e2d6b36 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/selectItem.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "selectPreviousItem": "Emmet: Selecione o Item anterior", + "selectNextItem": "Emmet: Selecione o próximo Item" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json new file mode 100644 index 00000000000..ea04346ea7c --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "splitJoinTag": "Emmet: Dividir/Juntar Rótulo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/toggleComment.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/toggleComment.i18n.json new file mode 100644 index 00000000000..366cb874a0c --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/toggleComment.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleComment": "Emmet: Alternar Comentário" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json new file mode 100644 index 00000000000..1eff88ade9d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "updateImageSize": "Emmet: Atualizar o Tamanho da Imagem" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json new file mode 100644 index 00000000000..963a85e1671 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "updateTag": "Emmet: Atualizar Rótulo", + "enterTag": "Insira o Rótulo", + "tag": "Rótulo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json new file mode 100644 index 00000000000..501253b7dcb --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "wrapWithAbbreviationAction": "Emmet: Envelope com a abreviatura", + "enterAbbreviation": "Digite a abreviação", + "abbreviation": "Abreviação" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json new file mode 100644 index 00000000000..1caebe040f5 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "emmetConfigurationTitle": "Emmet", + "triggerExpansionOnTab": "Quando habilitado, abreviações emmet são expandidas ao pressionar TAB.", + "emmetPreferences": "Preferências usadas para modificar o comportamento de algumas ações e resolvedores de Emmet.", + "emmetSyntaxProfiles": "Definir o perfil para a sintaxe especificada ou usar seu próprio perfil com regras específicas.", + "emmetExclude": "Uma matriz de línguagens onde abreviaturas emmet não devem ser expandidas.", + "emmetExtensionsPath": "Caminho para uma pasta contendo perfis emmet, trechos e preferências" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/execution/electron-browser/terminal.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/execution/electron-browser/terminal.contribution.i18n.json new file mode 100644 index 00000000000..95274daf750 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/execution/electron-browser/terminal.contribution.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminalConfigurationTitle": "Terminal Externo", + "terminal.external.windowsExec": "Personalizar qual terminal executar no Windows.", + "terminal.external.osxExec": "Personalizar qual aplicativo de terminal executar no OS X.", + "terminal.external.linuxExec": "Personalizar qual terminal executar no Linux.", + "globalConsoleActionWin": "Abrir Novo Prompt de Comando", + "globalConsoleActionMacLinux": "Abrir Novo Terminal", + "scopedConsoleActionWin": "Abrir no Prompt de Comando", + "scopedConsoleActionMacLinux": "Abrir no Terminal" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/execution/electron-browser/terminalService.i18n.json b/i18n/ptb/src/vs/workbench/parts/execution/electron-browser/terminalService.i18n.json new file mode 100644 index 00000000000..fde640b09c5 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/execution/electron-browser/terminalService.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "console.title": "Console VS Code", + "mac.terminal.script.failed": "Script '{0}' falhou com código de saída {1}", + "mac.terminal.type.not.supported": "'{0}' não suportado", + "press.any.key": "Pressione qualquer tecla para continuar...", + "linux.term.failed": "'{0}' falhou com código de saída {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json new file mode 100644 index 00000000000..d79e3c4ca0a --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.view": "Contribui ao modo de exibição personalizado", + "vscode.extension.contributes.view.id": "Identificação única usada para identificar a vista criada por vscode.workspace.createTreeView", + "vscode.extension.contributes.view.label": "Sequência de caracteres legível usada para processar a visualização", + "vscode.extension.contributes.view.icon": "Caminho para o ícone da visualização", + "vscode.extension.contributes.views": "Contribui com visualizações personalizadas", + "showViewlet": "Mostrar {0}", + "view": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorerActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorerActions.i18n.json new file mode 100644 index 00000000000..37735d10007 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorerActions.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "refresh": "Atualizar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorerService.i18n.json b/i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorerService.i18n.json new file mode 100644 index 00000000000..7b7f16b3812 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/explorers/browser/treeExplorerService.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "treeExplorer.noMatchingProviderId": "Não há TreeExplorerNodeProvider com id {providerId} registrado." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/explorers/browser/views/treeExplorerView.i18n.json b/i18n/ptb/src/vs/workbench/parts/explorers/browser/views/treeExplorerView.i18n.json new file mode 100644 index 00000000000..0e7f5f9cd92 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/explorers/browser/views/treeExplorerView.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "treeExplorerViewlet.tree": "Seção do Explorador da Ãrvore" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/browser/dependenciesViewer.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/browser/dependenciesViewer.i18n.json new file mode 100644 index 00000000000..0ebd24a9fd8 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/browser/dependenciesViewer.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "error": "Erro", + "Unknown Dependency": "Dependência Desconhecida:" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json new file mode 100644 index 00000000000..1a3b9d4cd09 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json @@ -0,0 +1,39 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "name": "Nome da extensão", + "extension id": "Identificador da extensão", + "publisher": "Nome do editor", + "install count": "Quantidade de Instalações", + "rating": "Avaliação", + "license": "Licença", + "details": "Detalhes", + "contributions": "Contribuições", + "changelog": "Registro de Alterações", + "dependencies": "Dependências", + "noReadme": "README não disponível.", + "noChangelog": "Registro de Alterações não disponível.", + "noContributions": "Sem Contribuições", + "noDependencies": "Sem Dependências", + "settings": "Configurações ({0})", + "setting name": "Nome", + "description": "Descrição", + "default": "Valor padrão", + "debuggers": "Depuradores ({0})", + "debugger name": "Nome", + "themes": "Temas ({0})", + "JSON Validation": "Validação JSON ({0})", + "commands": "Comandos ({0})", + "command name": "Nome", + "keyboard shortcuts": "Atalhos de Teclado", + "menuContexts": "Contextos de Menu", + "languages": "Linguagens ({0})", + "language id": "ID", + "language name": "Nome", + "file extensions": "Extensões de Arquivo", + "grammar": "Gramática", + "snippets": "Trechos" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json new file mode 100644 index 00000000000..e2ff606a7c9 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json @@ -0,0 +1,55 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "installAction": "Instalar", + "installing": "Instalando", + "uninstallAction": "Desinstalar", + "Uninstalling": "Desinstalando", + "updateAction": "Atualizar", + "updateTo": "Atualizar para {0}", + "enableForWorkspaceAction.label": "Habilitar (Espaço de Trabalho)", + "enableAlwaysAction.label": "Habilitar (Sempre)", + "disableForWorkspaceAction.label": "Desabilitar (Espaço de Trabalho)", + "disableAlwaysAction.label": "Desabilitar (Sempre)", + "ManageExtensionAction.uninstallingTooltip": "Desinstalando", + "enableForWorkspaceAction": "Espaço de trabalho", + "enableGloballyAction": "Sempre", + "enableAction": "Habilitar", + "disableForWorkspaceAction": "Espaço de trabalho", + "disableGloballyAction": "Sempre", + "disableAction": "Desabilitar", + "checkForUpdates": "Verificar Atualizações", + "updateAll": "Atualizar Todas as Extensões", + "reloadAction": "Recarregar", + "postUpdateTooltip": "Recarregar para atualizar", + "postUpdateMessage": "Recarregar esta janela para ativar a extensão atualizada '{0}'?", + "postEnableTooltip": "Recarregar para ativar", + "postEnableMessage": "Recarregar esta janela para ativar a extensão '{0}'?", + "postDisableTooltip": "Recarregar para desativar", + "postDisableMessage": "Recarregar esta janela para desativar a extensão '{0}'?", + "postUninstallTooltip": "Recarregar para desativar", + "postUninstallMessage": "Recarregar esta janela para desativar a extensão desinstalada '{0}'?", + "reload": "&&Recarregar Janela", + "toggleExtensionsViewlet": "Mostrar Extensões", + "installExtensions": "Instalar Extensões", + "showInstalledExtensions": "Mostrar Extensões Instaladas", + "showDisabledExtensions": "Mostrar Extensões Desabilitadas", + "clearExtensionsInput": "Limpar Entrada de Extensões", + "showOutdatedExtensions": "Mostrar Extensões Desatualizadas", + "showPopularExtensions": "Mostrar Extensões Populares", + "showRecommendedExtensions": "Mostrar Extensões Recomendadas", + "showWorkspaceRecommendedExtensions": "Mostrar Extensões Recomendadas para o Espaço de Trabalho", + "showRecommendedKeymapExtensions": "Mostrar Mapeamentos de Teclado Recomendados", + "showRecommendedKeymapExtensionsShort": "Mapeamentos de Teclado", + "configureWorkspaceRecommendedExtensions": "Configurar Extensões Recomendadas (Espaço de Trabalho)", + "ConfigureWorkspaceRecommendations.noWorkspace": "As recomendações somente estão disponíveis em uma pasta do espaço de trabalho.", + "OpenExtensionsFile.failed": "Não foi possível criar o arquivo 'extensions.json' na pasta '.vscode' ({0}).", + "builtin": "Intrínseco", + "disableAll": "Desabilitar Todas as Extensões Instaladas", + "disableAllWorkspace": "Desabilitar Todas as Extensões Instaladas para este Espaço de Trabalho", + "enableAll": "Habilitar Todas as Extensões Instaladas", + "enableAllWorkspace": "Habilitar Todas as Extensões Instaladas para este Espaço de Trabalho" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionsQuickOpen.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionsQuickOpen.i18n.json new file mode 100644 index 00000000000..666a6692179 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionsQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "manage": "Pressione Enter para gerenciar suas extensões.", + "searchFor": "Pressione Enter para pesquisar por '{0}' na Loja.", + "noExtensionsToInstall": "Digite um nome de extensão" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/common/extensionsFileTemplate.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/common/extensionsFileTemplate.i18n.json new file mode 100644 index 00000000000..b90c0d5ac64 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/common/extensionsFileTemplate.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "app.extensions.json.title": "Extensões", + "app.extensions.json.recommendations": "Lista de recomendações de extensões. O identificador de uma extensão é sempre ' ${publisher}. ${nome}'. Por exemplo: 'vscode.csharp'.", + "app.extension.identifier.errorMessage": "Formato esperado '${editor}.${nome}'. Exemplo: 'vscode.csharp'." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/common/extensionsInput.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/common/extensionsInput.i18n.json new file mode 100644 index 00000000000..333627e9619 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/common/extensionsInput.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "extensionsInputName": "Extensão: {0}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json new file mode 100644 index 00000000000..663560d4d78 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "reallyRecommended2": "A extensão {0} é recomendada para este tipo de arquivo.", + "showRecommendations": "Mostrar Recomendações", + "neverShowAgain": "Não mostrar novamente", + "close": "Fechar", + "workspaceRecommended": "Este espaço de trabalho possui recomendações de extensão.", + "ignoreExtensionRecommendations": "Deseja ignorar todas as recomendações de extensão?", + "ignoreAll": "Sim, Ignorar Tudo", + "no": "Não", + "cancel": "Cancelar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json new file mode 100644 index 00000000000..76bf0379481 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "extensionsCommands": "Gerenciar Extensões", + "galleryExtensionsCommands": "Instalar Extensões da Galeria", + "extension": "Extensão", + "extensions": "Extensões", + "view": "Exibir", + "extensionsConfigurationTitle": "Extensões", + "extensionsAutoUpdate": "Atualizar extensões automaticamente", + "extensionsIgnoreRecommendations": "Ignorar recomendações de extensão" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsActions.i18n.json new file mode 100644 index 00000000000..731e4ef9491 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsActions.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openExtensionsFolder": "Abrir a Pasta de Extensões", + "installVSIX": "Instalar do VSIX...", + "InstallVSIXAction.success": "A extensão foi instalada com sucesso. Reinicie para habilitá-la.", + "InstallVSIXAction.reloadNow": "Recarregar Agora" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json new file mode 100644 index 00000000000..0cde76b12d8 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "disableOtherKeymapsConfirmation": "Desabilitar outros mapeamentos de teclado para evitar conflitos entre mapeamentos de teclado?", + "yes": "Sim", + "no": "Não" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.i18n.json new file mode 100644 index 00000000000..a35f8bbe6c6 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "searchExtensions": "Pesquisar Extensões na Loja", + "extensions": "Extensões", + "sort by installs": "Ordenar por: Quantidade de Instalações", + "sort by rating": "Ordenar por: Avaliação", + "sort by name": "Ordenar por: Nome", + "no extensions found": "Nenhuma extensão encontrada.", + "suggestProxyError": "A Loja retornou 'ECONNREFUSED'. Por favor, verifique a configuração de 'http.proxy'.", + "outdatedExtensions": "{0} Extensões Desatualizadas" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.i18n.json new file mode 100644 index 00000000000..f0313c20343 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "enableDependeciesConfirmation": "Habilitando '{0}' também habilita suas dependências. Gostaria de continuar?", + "enable": "Sim", + "doNotEnable": "Não", + "disableDependeciesConfirmation": "Gostaria de desabilitar somente '{0}', ou as suas dependências também?", + "disableOnly": "Apenas", + "disableAll": "Todos", + "cancel": "Cancelar", + "singleDependentError": "Não é possível desabilitar a extensão '{0}'. A extensão '{1}' depende dela.", + "twoDependentsError": "Não é possível desabilitar a extensão '{0}'. As extensões '{1}' e '{2}' dependem dela.", + "multipleDependentsError": "Não é possível desabilitar a extensão '{0}'. As extensões '{1}', '{2}' e outras dependem dela." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/feedback/electron-browser/feedback.i18n.json b/i18n/ptb/src/vs/workbench/parts/feedback/electron-browser/feedback.i18n.json new file mode 100644 index 00000000000..5d3c22c39a8 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/feedback/electron-browser/feedback.i18n.json @@ -0,0 +1,25 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "sendFeedback": "Tweetar Feedback", + "label.sendASmile": "Tweete feedback para nós", + "patchedVersion1": "Sua instalação está corrompida.", + "patchedVersion2": "Por favor especificar isso ao enviar um bug.", + "sentiment": "Como foi sua experiência?", + "smileCaption": "Feliz", + "frownCaption": "Triste", + "other ways to contact us": "Outras maneiras de nos contatar", + "submit a bug": "Submeter um bug", + "request a missing feature": "Solicitar um recurso ausente", + "tell us why?": "Diga-nos porquê?", + "commentsHeader": "Comentários", + "tweet": "Tweetar", + "character left": "caractere à esquerda", + "characters left": "caracteres à esquerda", + "feedbackSending": "Enviando", + "feedbackSent": "Obrigado", + "feedbackSendingError": "Tentar novamente" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/editors/binaryFileEditor.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/editors/binaryFileEditor.i18n.json new file mode 100644 index 00000000000..9c33fd25246 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/editors/binaryFileEditor.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "binaryFileEditor": "Visualizador de Arquivo Binário" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/editors/textFileEditor.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/editors/textFileEditor.i18n.json new file mode 100644 index 00000000000..792781bc8c7 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/editors/textFileEditor.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "textFileEditor": "Editor de Arquivo de Texto", + "createFile": "Criar arquivo", + "fileEditorWithInputAriaLabel": "{0}. Editor de Arquivo de Texto.", + "fileEditorAriaLabel": "Editor de Arquivo de Texto" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/fileActions.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/fileActions.contribution.i18n.json new file mode 100644 index 00000000000..f203671c230 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/fileActions.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "filesCategory": "Arquivos", + "revealInSideBar": "Revelar na Barra Lateral", + "acceptLocalChanges": "Usar mudanças locais e sobrescrever o conteúdo do disco", + "revertLocalChanges": "Descartar mudanças locais e reverter para conteúdo do disco" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/fileActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/fileActions.i18n.json new file mode 100644 index 00000000000..161e7a9a16c --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/fileActions.i18n.json @@ -0,0 +1,73 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "retry": "Tentar novamente", + "rename": "Renomear", + "newFile": "Novo Arquivo", + "newFolder": "Nova Pasta", + "openFolderFirst": "Abrir uma pasta primeiro para criar arquivos ou pastas dentro dele.", + "newUntitledFile": "Novo Arquivo Sem Título", + "createNewFile": "Novo Arquivo", + "createNewFolder": "Nova Pasta", + "deleteButtonLabelRecycleBin": "&&Mover para Lixeira", + "deleteButtonLabelTrash": "&&Mover para o Lixo", + "deleteButtonLabel": "&&Excluir", + "dirtyMessageFolderOneDelete": "Você está excluindo uma pasta com alterações não salvas em 1 arquivo. Você quer continuar?", + "dirtyMessageFolderDelete": "Você está excluindo uma pasta com alterações não salvas em {0} arquivos. Você quer continuar?", + "dirtyMessageFileDelete": "Você está excluindo um arquivo com alterações não salvas. Você quer continuar?", + "dirtyWarning": "Suas alterações serão perdidas se você não salvá-las.", + "confirmMoveTrashMessageFolder": "Tem certeza de que deseja excluir '{0}' e seu conteúdo?", + "confirmMoveTrashMessageFile": "Tem certeza de que deseja excluir '{0}'?", + "undoBin": "Você pode restaurar da lixeira.", + "undoTrash": "Você pode restaurar a partir do lixo.", + "confirmDeleteMessageFolder": "Tem certeza de que deseja excluir permanentemente '{0}' e seu conteúdo?", + "confirmDeleteMessageFile": "Tem certeza de que deseja excluir permanentemente '{0}'?", + "irreversible": "Esta ação é irreversível!", + "permDelete": "Excluir permanentemente", + "delete": "Excluir", + "importFiles": "Importar Arquivos", + "confirmOverwrite": "Um arquivo ou pasta com o mesmo nome já existe na pasta de destino. Você quer substituí-lo?", + "replaceButtonLabel": "&&Substituir", + "copyFile": "Copiar", + "pasteFile": "Colar", + "duplicateFile": "Duplicar", + "openToSide": "Aberto para o lado", + "compareSource": "Selecione para comparar", + "globalCompareFile": "Compare o Arquivo Ativo Com...", + "pickHistory": "Selecione um arquivo previamente aberto para comparar com", + "unableToFileToCompare": "O arquivo selecionado não pode ser comparado com '{0}'.", + "openFileToCompare": "Abrir um arquivo primeiro para compará-lo com outro arquivo.", + "compareWith": "Comparar com '{0}'", + "compareFiles": "Comparar Arquivos", + "refresh": "Atualizar", + "save": "Salvar", + "saveAs": "Salvar como...", + "saveAll": "Salvar Todos", + "saveAllInGroup": "Salvar Todos no Grupo", + "saveFiles": "Salvar Arquivos Sujos", + "revert": "Reverter Arquivo", + "focusOpenEditors": "Foco na Visualização dos Editores Abertos", + "focusFilesExplorer": "Foco no Explorador de Arquivos", + "showInExplorer": "Revelar o Arquivo Ativo na Barra Lateral", + "openFileToShow": "Abrir um arquivo primeiro para mostrá-lo no explorer", + "collapseExplorerFolders": "Esconder Pastas no Explorador", + "refreshExplorer": "Atualizar Explorador", + "openFile": "Abrir arquivo...", + "openFileInNewWindow": "Abrir o Arquivo Ativo em uma Nova Janela", + "openFileToShowInNewWindow": "Abrir um arquivo primeiro para abrir em uma nova janela", + "revealInWindows": "Revelar no Explorer", + "revealInMac": "Revelar no Finder", + "openContainer": "Abrir a Pasta", + "revealActiveFileInWindows": "Revelar Arquivo Ativo no Windows Explorer", + "revealActiveFileInMac": "Revelar Arquivo Ativo no Finder", + "openActiveFileContainer": "Abrir a Pasta do Arquivo Ativo.", + "copyPath": "Copiar Caminho", + "copyPathOfActive": "Copiar Caminho do Arquivo Ativo", + "emptyFileNameError": "Um nome de arquivo ou pasta deve ser fornecido.", + "fileNameExistsError": "Um arquivo ou pasta **{0}** já existe neste local. Escolha um nome diferente.", + "invalidFileNameError": "O nome **{0}** não é válido como um nome de arquivo ou pasta. Por favor, escolha um nome diferente.", + "filePathTooLongError": "O nome **{0}** resulta em um caminho muito longo. Escolha um nome mais curto." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/fileCommands.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/fileCommands.i18n.json new file mode 100644 index 00000000000..2e61a1656c8 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/fileCommands.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openFileToCopy": "Abrir um arquivo primeiro para copiar seu caminho", + "openFileToReveal": "Abrir um arquivo primeiro para revelar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/files.contribution.i18n.json new file mode 100644 index 00000000000..ddbc9408f54 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -0,0 +1,40 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "showExplorerViewlet": "Mostrar Explorer", + "explore": "Explorador", + "view": "Exibir", + "textFileEditor": "Editor de Arquivo de Texto", + "binaryFileEditor": "Editor de Arquivo Binário", + "filesConfigurationTitle": "Arquivos", + "exclude": "Configure os padrões glob para excluir arquivos e pastas.", + "files.exclude.boolean": "O padrão glob com o qual combinar os caminhos de arquivo. Defina para verdadeiro ou falso para habilitar ou desabilitar o padrão.", + "files.exclude.when": "Verificação adicional nos irmãos de um arquivo correspondente. Use $(basename) como variável para o nome do arquivo correspondente.", + "associations": "Configurar as associações de arquivo para linguagens (por exemplo, \"* Extension\": \"html\"). Estas têm precedência sobre as associações padrão das linguagens instaladas.", + "encoding": "A codificação padrão do conjunto de caracteres para ser usada ao ler e gravar arquivos.", + "autoGuessEncoding": "Quando habilitado, tentará adivinhar a codificação do conjunto de caracteres ao abrir arquivos", + "trimTrailingWhitespace": "Quando habilitado, removerá espaços em branco à direita ao salvar um arquivo.", + "insertFinalNewline": "Quando habilitado, inseririrá uma nova linha no final do arquivo quando salvá-lo.", + "files.autoSave.off": "Um arquivo sujo nunca é automaticamente salvo.", + "files.autoSave.afterDelay": "Um arquivo sujo é salvo automaticamente após configurado em 'files.autoSaveDelay'.", + "files.autoSave.onFocusChange": "Um arquivo sujo é salvo automaticamente quando o editor perde o foco.", + "files.autoSave.onWindowChange": "Um arquivo sujo é salvo automaticamente quando a janela perde o foco.", + "autoSave": "Controla o auto-salvamento de arquivos sujos. Aceita os valores: '{0}', '{1}', '{2}' (editor perde o foco), '{3}' (janela perde o foco). Se definido como '{4}', você pode configurar o atraso em 'files.autoSaveDelay'.", + "autoSaveDelay": "Controla o atraso em milissegundos depois que um arquivo sujo é salvo automaticamente. Só se aplica quando 'files.autoSave' for definida como '{0}'", + "watcherExclude": "Configure padrões glob de caminhos de arquivo para excluir do monitoramento de arquivos. Alterar essa configuração requer uma reinicialização. Quando você tiver consumo Code muito alto de cpu na inicialização, você pode excluir pastas grandes para reduzir a carga inicial.", + "hotExit.off": "Desabilitar a saída à quente.", + "hotExit.onExit": "Saída à quente será acionada quando o aplicativo for fechado, ou seja, quando a última janela é fechada no Windows/Linux ou quando o comando workbench.action.quit é acionado (paleta de comandos, keybinding, menu). Todas as janelas com backups serão restauradas na próxima execução.", + "hotExit.onExitAndWindowClose": "Saída à quente será acionada quando o aplicativo for fechado, ou seja, quando a última janela é fechada no Windows/Linux ou quando o comando workbench.action.quit é acionado (paleta de comando, keybinding, menu), e também para qualquer janela com uma pasta aberta independentemente se é a última janela. Todas as janelas sem pastas abertas serão restauradas na próxima execução. Para restaurar as janelas de pastas como eram antes do desligamento configure \"window.reopenFolders\" para \"todos\".", + "hotExit": "Controla se os arquivos não salvos são lembrados entre as sessões, permitindo salvar alerta ao sair do editor seja ignorada.", + "defaultLanguage": "O modo de linguagem padrão que é atribuída para novos arquivos.", + "editorConfigurationTitle": "Editor", + "formatOnSave": "Formata um arquivo no salvamento. Um formatador deve estar disponível, o arquivo não deve ser salvo automaticamente e editor não deve ser desligado.", + "explorerConfigurationTitle": "Explorador de arquivos", + "openEditorsVisible": "Número de editores mostrado no painel Abrir Editores. Configurá-lo para 0 irá ocultar o painel.", + "dynamicHeight": "Controla se a altura da seção de editores abertos deve adaptar-se dinamicamente para o número de elementos ou não.", + "autoReveal": "Controla se o explorador deve automaticamente revelar e selecionar arquivos ao abri-los.", + "enableDragAndDrop": "Controla se o explorador deve permitir mover arquivos e pastas através de arrastar e soltar." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/saveErrorHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/saveErrorHandler.i18n.json new file mode 100644 index 00000000000..30a0a48f866 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/saveErrorHandler.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "discard": "Descartar", + "overwrite": "Sobrescrever", + "retry": "Tentar novamente", + "readonlySaveError": "Falha ao salvar '{0}': O arquivo está protegido contra gravação. Selecione 'Substituir' para remover a proteção.", + "genericSaveError": "Erro ao salvar '{0}': {1}", + "staleSaveError": "Falha ao salvar '{0}': O conteúdo no disco é mais recente. Clique em **Comparar** para comparar a sua versão com a do disco.", + "compareChanges": "Comparar", + "saveConflictDiffLabel": "{0} (no disco) ↔ {1} (em {2}) - Resolver conflitos de salvamento", + "userGuide": "Use as ações na barra de ferramentas do editor para **desfazer** suas alterações ou **substituir** o conteúdo no disco com as suas alterações" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json new file mode 100644 index 00000000000..58da5446b25 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "explorerSection": "Seção de Explorador de Arquivos", + "noWorkspace": "Nenhuma Pasta Aberta", + "noWorkspaceHelp": "Você ainda não abriu uma pasta.", + "openFolder": "Abrir Pasta" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/views/explorerView.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/views/explorerView.i18n.json new file mode 100644 index 00000000000..4753a88bd4c --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/views/explorerView.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "explorerSection": "Seção de Explorador de Arquivos", + "treeAriaLabel": "Explorador de Arquivos" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/views/explorerViewer.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/views/explorerViewer.i18n.json new file mode 100644 index 00000000000..c670883e6ac --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/views/explorerViewer.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "fileInputAriaLabel": "Digite o Nome do arquivo. Pressione Enter para confirmar ou Escape para cancelar.", + "filesExplorerViewerAriaLabel": "{0}, Explorador de Arquivos", + "confirmOverwriteMessage": "'{0}' já existe na pasta de destino. Deseja substituí-lo?", + "irreversible": "Esta ação é irreversível!", + "replaceButtonLabel": "&&Substituir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json new file mode 100644 index 00000000000..4db9c1f34d8 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openEditosrSection": "Abrir Seção de Editores", + "openEditors": "Abrir Editores", + "treeAriaLabel": "Abrir Editores: Lista de Arquivos Ativos", + "dirtyCounter": "{0} não salvos" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsViewer.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsViewer.i18n.json new file mode 100644 index 00000000000..dbef8f2ddb5 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsViewer.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorGroupAriaLabel": "{0}, Agrupar Editor", + "openEditorAriaLabel": "{0}, Abrir Editor", + "saveAll": "Salvar Todos", + "closeAll": "Fechar todos", + "close": "Fechar", + "closeOthers": "Fechar Outros" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/common/dirtyFilesTracker.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/common/dirtyFilesTracker.i18n.json new file mode 100644 index 00000000000..9e75b7b2a89 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/common/dirtyFilesTracker.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "dirtyFiles": "{0} arquivos não salvos" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json new file mode 100644 index 00000000000..f29992f5d95 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "orphanedFile": "{0} (excluído do disco)" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/html/browser/html.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/html/browser/html.contribution.i18n.json new file mode 100644 index 00000000000..f9530b0f6f6 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/html/browser/html.contribution.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "html.editor.label": "Visualização Html" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/html/browser/htmlPreviewPart.i18n.json b/i18n/ptb/src/vs/workbench/parts/html/browser/htmlPreviewPart.i18n.json new file mode 100644 index 00000000000..8df4c48f58c --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/html/browser/htmlPreviewPart.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "html.voidInput": "Entrada inválida do editor." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/html/browser/webview.i18n.json b/i18n/ptb/src/vs/workbench/parts/html/browser/webview.i18n.json new file mode 100644 index 00000000000..2ef4463deb9 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/html/browser/webview.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "devtools.webview": "Desenvolvedor: Ferramentas Webview" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/markers/common/messages.i18n.json b/i18n/ptb/src/vs/workbench/parts/markers/common/messages.i18n.json new file mode 100644 index 00000000000..8576955d609 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/markers/common/messages.i18n.json @@ -0,0 +1,39 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "viewCategory": "Exibir", + "problems.view.show.label": "Mostrar Problemas", + "problems.panel.configuration.title": "Visualização de Problemas", + "problems.panel.configuration.autoreveal": "Controla se a visaulização de problemas evela os arquivos automaticamente ao abri-los", + "markers.panel.title.problems": "Problemas", + "markers.panel.aria.label.problems.tree": "Problemas agrupados por arquivos", + "markers.panel.no.problems.build": "Nenhum problema foi detectado na área de trabalho até agora.", + "markers.panel.no.problems.filters": "Nenhum resultado encontrado com os critérios de filtro fornecidos", + "markers.panel.action.filter": "Problemas de Filtro", + "markers.panel.filter.placeholder": "Filtrar por tipo ou texto", + "markers.panel.filter.errors": "erros", + "markers.panel.filter.warnings": "avisos", + "markers.panel.filter.infos": "informações", + "markers.panel.single.error.label": "1 Erro", + "markers.panel.multiple.errors.label": "{0} Erros", + "markers.panel.single.warning.label": "1 Aviso", + "markers.panel.multiple.warnings.label": "{0} Avisos", + "markers.panel.single.info.label": "1 Informação", + "markers.panel.multiple.infos.label": "{0} Informações", + "markers.panel.single.unknown.label": "1 Desconhecido", + "markers.panel.multiple.unknowns.label": "{0} Desconhecidos", + "markers.panel.at.ln.col.number": "({0}, {1})", + "problems.tree.aria.label.resource": "{0} com {1} problemas", + "problems.tree.aria.label.error.marker": "Erro gerado por {0}: {1} na linha {2} e caractere {3}", + "problems.tree.aria.label.error.marker.nosource": "Erro: {0} na linha {1} e caractere {2}", + "problems.tree.aria.label.warning.marker": "Aviso gerado por {0}: {1} na linha {2} e caractere {3}", + "problems.tree.aria.label.warning.marker.nosource": "Aviso: {0} na linha {1} e caractere {2}", + "problems.tree.aria.label.info.marker": "Informação gerada por {0}: {1} na linha {2} e caractere {3}", + "problems.tree.aria.label.info.marker.nosource": "Informação: {0} na linha {1} e caractere {2}", + "problems.tree.aria.label.marker": "Problema gerado por {0}: {1} na linha {2} e caractere {3}", + "problems.tree.aria.label.marker.nosource": "Problema: {0} na linha {1} e caractere {2}", + "errors.warnings.show.label": "Mostrar Erros e Avisos" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/markers/electron-browser/markersElectronContributions.i18n.json b/i18n/ptb/src/vs/workbench/parts/markers/electron-browser/markersElectronContributions.i18n.json new file mode 100644 index 00000000000..027c80cca30 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/markers/electron-browser/markersElectronContributions.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "copyMarker": "Copiar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/nps/electron-browser/nps.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/nps/electron-browser/nps.contribution.i18n.json new file mode 100644 index 00000000000..1ec18c632a4 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/nps/electron-browser/nps.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "surveyQuestion": "Você deseja responder a uma pequena pesquisa?", + "takeSurvey": "Responder a pesquisa", + "remindLater": "Lembrar mais tarde", + "neverAgain": "Não mostrar novamente" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/output/browser/output.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/output/browser/output.contribution.i18n.json new file mode 100644 index 00000000000..e36bdadf4e9 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/output/browser/output.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "output": "Saída", + "viewCategory": "Exibir", + "clearOutput.label": "Limpar saída" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/output/browser/outputActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/output/browser/outputActions.i18n.json new file mode 100644 index 00000000000..00bca0dc309 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/output/browser/outputActions.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleOutput": "Alternar Saída", + "clearOutput": "Limpar saída", + "toggleOutputScrollLock": "Alternar Scroll Lock de Saída", + "switchToOutput.label": "Mudar para Saída" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/output/browser/outputPanel.i18n.json b/i18n/ptb/src/vs/workbench/parts/output/browser/outputPanel.i18n.json new file mode 100644 index 00000000000..ec28fd7b2a3 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/output/browser/outputPanel.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "outputPanelWithInputAriaLabel": "{0}, Painel de saída", + "outputPanelAriaLabel": "Painel de saída" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/output/common/output.i18n.json b/i18n/ptb/src/vs/workbench/parts/output/common/output.i18n.json new file mode 100644 index 00000000000..a083a6e7d9d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/output/common/output.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "output": "Saída", + "channel": "para '{0}'" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json new file mode 100644 index 00000000000..5fda62eb168 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "slow": "Inicialização lenta detectada", + "slow.detail": "Pena que você teve uma inicialização lenta. Por favor reinicie '{0}' com perfil de desempenho habilitado, compartilhe os perfis conosco e nós trabalharemos duro para fazer com que a inicialização fique perfeita novamente.", + "prof.message": "Perfis criados com sucesso.", + "prof.detail": "Por favor, crie um problema e anexe manualmente os seguintes arquivos:\n{0}", + "prof.restartAndFileIssue": "Criar Problema e Reiniciar", + "prof.restart": "Reiniciar", + "prof.thanks": "Obrigado por nos ajudar.", + "prof.detail.restart": "É necessário um reinício final para continuar a usar '{0}'. Novamente, obrigado pela sua contribuição." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingWidgets.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingWidgets.i18n.json new file mode 100644 index 00000000000..279307d4b87 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingWidgets.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defineKeybinding.initial": "Pressionar a combinação de teclas desejada e ENTER. ESCAPE para cancelar.", + "defineKeybinding.chordsTo": "Acorde para" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json new file mode 100644 index 00000000000..1cb6541687c --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json @@ -0,0 +1,35 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "keybindingsInputName": "Atalhos de Teclado", + "SearchKeybindings.AriaLabel": "Pesquisar keybindings", + "SearchKeybindings.Placeholder": "Pesquisar keybindings", + "sortByPrecedene": "Ordenar por precedência", + "header-message": "Para personalizações avançadas abrir e editar", + "keybindings-file-name": "keybindings.json", + "keybindingsLabel": "Keybindings", + "changeLabel": "Alterar Keybinding", + "addLabel": "Adicionar Keybinding", + "removeLabel": "Remover Keybinding", + "resetLabel": "Redefinir Keybinding", + "showConflictsLabel": "Mostrar Conflitos", + "copyLabel": "Copiar", + "error": "Erro '{0}' enquanto edita keybinding. Por favor, abra o arquivo 'keybindings.json' e verifique.", + "command": "Comando", + "keybinding": "KeyBinding", + "source": "Fonte", + "when": "Quando", + "editKeybindingLabelWithKey": "Alterar Keybinding {0}", + "editKeybindingLabel": "Alterar Keybinding", + "addKeybindingLabelWithKey": "Adicionar Keybinding {0}", + "addKeybindingLabel": "Adicionar Keybinding", + "commandAriaLabel": "Comando é {0}.", + "keybindingAriaLabel": "KeyBinding é {0}.", + "noKeybinding": "Nenhum Keybinding atribuído.", + "sourceAriaLabel": "Fonte é {0}.", + "whenAriaLabel": "Quando é {0}.", + "noWhen": "Sem contexto Quando." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json new file mode 100644 index 00000000000..15fd432f9fa --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defineKeybinding.start": "Definir Keybinding", + "defineKeybinding.kbLayoutInfoMessage": "Para o seu layout de teclado atual pressionar", + "defineKeybinding.kbLayoutErrorMessage": "Você não será capaz de produzir esta combinação de teclas sob seu layout de teclado atual." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferences.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferences.contribution.i18n.json new file mode 100644 index 00000000000..40e6d0841da --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferences.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defaultPreferencesEditor": "Editor de Preferências Padrão", + "keybindingsEditor": "Editor de Keybindings", + "preferences": "Preferências" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json new file mode 100644 index 00000000000..461e0fb96f7 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openGlobalSettings": "Abra as Configurações de Usuário", + "openGlobalKeybindings": "Abrir Atalhos de Teclado", + "openGlobalKeybindingsFile": "Abrir Arquivo de Atalhos de Teclado", + "openWorkspaceSettings": "Abrir as configurações do espaço de trabalho", + "configureLanguageBasedSettings": "Definir Configurações Específicas de Linguagem...", + "languageDescriptionConfigured": "({0})", + "pickLanguage": "Selecionar Linguagem" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesEditor.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesEditor.i18n.json new file mode 100644 index 00000000000..e3ef1e68a73 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesEditor.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "settingsEditorName": "Configurações Padrão", + "SearchSettingsWidget.AriaLabel": "Configurações de Pesquisa", + "SearchSettingsWidget.Placeholder": "Configurações de Pesquisa", + "totalSettingsMessage": "Total {0} Configurações", + "noSettingsFound": "Nenhum resultado", + "oneSettingFound": "1 Configuração correspondente", + "settingsFound": "{0} Configurações correspondentes", + "preferencesAriaLabel": "Preferências padrão. Editor de texto somente leitura." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json new file mode 100644 index 00000000000..e35427eb2df --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "errorInvalidConfiguration": "Não é possível gravar em configurações. Corrija erros/avisos no arquivo e tente novamente.", + "editTtile": "Editar", + "replaceDefaultValue": "Substituir nas Configurações", + "copyDefaultValue": "Copiar para Configurações", + "unsupportedPHPExecutablePathSetting": "Essa configuração deve ser uma Configuração de Usuário. Para configurar o PHP para o espaço de trabalho, abra um arquivo PHP e clique em 'Caminho do PHP' na barra de status.", + "unsupportedWorkspaceSetting": "Essa configuração deve ser uma Configuração de Usuário." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesService.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesService.i18n.json new file mode 100644 index 00000000000..3d94af63615 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesService.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openFolderFirst": "Abrir uma pasta primeiro para criar configurações de espaço de trabalho", + "emptyKeybindingsHeader": "Coloque suas chaves de ligações neste arquivo para substituir os padrões", + "defaultKeybindings": "Keybindings Padrão", + "emptySettingsHeader": "Colocar suas configurações nesse arquivo para sobrecrever as configurações padrão", + "emptySettingsHeader1": "Colocar as suas configurações nesse arquivo para sobrescrever as configurações e usuário padrão.", + "fail.createSettings": "Não foi possível criar '{0}' ({1})." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesWidgets.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesWidgets.i18n.json new file mode 100644 index 00000000000..556ef65c079 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/browser/preferencesWidgets.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "settingsSwitcherBarAriaLabel": "Chave de Configurações", + "userSettings": "Configurações de Usuário", + "workspaceSettings": "Configurações de Espaço de Trabalho" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.i18n.json new file mode 100644 index 00000000000..68e05e00daf --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "default": "Valor padrão", + "user": "Usuário", + "meta": "meta", + "option": "opção" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/common/preferencesModels.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/common/preferencesModels.i18n.json new file mode 100644 index 00000000000..6427118b75b --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/preferences/common/preferencesModels.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "commonlyUsed": "Comumente Utilizado", + "defaultKeybindingsHeader": "Substituir as chaves de ligações, colocando-os em seu arquivo de chave ligações." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json new file mode 100644 index 00000000000..7b246da25ad --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "showTriggerActions": "Mostrar todos os comandos", + "showCommands.label": "Paleta de comandos...", + "entryAriaLabelWithKey": "{0}, {1}, comandos", + "entryAriaLabel": "{0}, comandos", + "canNotRun": "O comando '{0}' não pode ser executado a partir daqui.", + "actionNotEnabled": "O comando '{0}' não está habilitado no contexto atual.", + "commandLabel": "{0}: {1}", + "cat.title": "{0}: {1}", + "noCommandsMatching": "Não há comandos correspondentes" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/quickopen/browser/gotoLineHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/gotoLineHandler.i18n.json new file mode 100644 index 00000000000..3f922e6deca --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/gotoLineHandler.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "gotoLine": "Ir para linha...", + "gotoLineLabelEmptyWithLimit": "Digite um número de linha entre 1 e {0} para navegar para lá", + "gotoLineLabelEmpty": "Digite um número de linha para navegar para lá", + "gotoLineColumnLabel": "Ir para linha {0} e caractere {1}", + "gotoLineLabel": "Ir para linha {0}", + "gotoLineHandlerAriaLabel": "Digite um número de linha para navegar.", + "cannotRunGotoLine": "Abrir um arquivo de texto primeiro para ir a uma linha" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/quickopen/browser/gotoSymbolHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/gotoSymbolHandler.i18n.json new file mode 100644 index 00000000000..5e56bdc5890 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/gotoSymbolHandler.i18n.json @@ -0,0 +1,34 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "gotoSymbol": "Ir para o Símbolo no Arquivo...", + "symbols": "símbolos ({0})", + "method": "métodos ({0})", + "function": "funções ({0})", + "_constructor": "construtores ({0})", + "variable": "variáveis ({0})", + "class": "classes ({0})", + "interface": "interfaces ({0})", + "namespace": "namespaces ({0})", + "package": "pacotes ({0})", + "modules": "módulos ({0})", + "property": "propriedades ({0})", + "enum": "enumerações ({0})", + "string": "cadeias de caracteres ({0})", + "rule": "regras ({0})", + "file": "arquivos ({0})", + "array": "matrizes ({0})", + "number": "números ({0})", + "boolean": "booleanos ({0})", + "object": "objetos ({0})", + "key": "chaves ({0})", + "entryAriaLabel": "{0}, símbolos", + "noSymbolsMatching": "Não há símbolos correspondentes", + "noSymbolsFound": "Nenhum símbolo encontrado", + "gotoSymbolHandlerAriaLabel": "Tipo para reduzir os símbolos do editor ativo atual.", + "cannotRunGotoSymbolInFile": "Não há informações de símbolo para o arquivo", + "cannotRunGotoSymbol": "Abrir um arquivo de texto primeiro para ir a um símbolo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/quickopen/browser/helpHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/helpHandler.i18n.json new file mode 100644 index 00000000000..0a2fc637f73 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/helpHandler.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, ajuda do seletor", + "globalCommands": "comandos globais", + "editorCommands": "comandos do editor" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.i18n.json new file mode 100644 index 00000000000..e3c6204b605 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "commandsHandlerDescriptionDefault": "Exibir e executar comandos", + "gotoLineDescriptionMac": "Ir para linha", + "gotoLineDescriptionWin": "Ir para linha", + "gotoSymbolDescription": "Ir para o Símbolo no Arquivo", + "gotoSymbolDescriptionScoped": "Ir para o Símbolo no Arquivo Por Categoria", + "helpDescription": "Mostrar ajuda", + "viewPickerDescription": "Abrir Visualização" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/quickopen/browser/viewPickerHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/viewPickerHandler.i18n.json new file mode 100644 index 00000000000..38804354794 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/viewPickerHandler.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, visualizar seletor", + "views": "Modos de exibição", + "panels": "Painéis", + "terminals": "Terminal", + "terminalTitle": "{0}: {1}", + "channels": "Saída", + "openView": "Abrir Visualização", + "quickOpenView": "Abrir Visualização Rápida" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json new file mode 100644 index 00000000000..1b5369ebeea --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleGitViewlet": "Mostrar Git", + "installAdditionalSCMProviders": "Instalar provedores de SCM adicionais...", + "source control": "Controle de código-fonte", + "toggleSCMViewlet": "Mostrar SCM", + "view": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmActivity.i18n.json b/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmActivity.i18n.json new file mode 100644 index 00000000000..7846e2b872d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmActivity.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "scmPendingChangesBadge": "{0} alterações pendentes" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json b/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json new file mode 100644 index 00000000000..5b93869e8d8 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "installAdditionalSCMProviders": "Instalar provedores de SCM adicionais...", + "switch provider": "Mudar Provedor SCM..." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmViewlet.i18n.json b/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmViewlet.i18n.json new file mode 100644 index 00000000000..c14da801978 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/scmViewlet.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "commitMessage": "Mensagem (tecle {0} para confirmar)", + "source control": "Controle de código-fonte", + "viewletTitle": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/search/browser/openAnythingHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/search/browser/openAnythingHandler.i18n.json new file mode 100644 index 00000000000..8d523511515 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/search/browser/openAnythingHandler.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "fileAndTypeResults": "resultados do arquivo e símbolo", + "fileResults": "resultados do arquivo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/search/browser/openFileHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/search/browser/openFileHandler.i18n.json new file mode 100644 index 00000000000..016a91f2c32 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/search/browser/openFileHandler.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, seletor de arquivo", + "searchResults": "resultados da pesquisa" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/search/browser/openSymbolHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/search/browser/openSymbolHandler.i18n.json new file mode 100644 index 00000000000..ede0a0c718d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/search/browser/openSymbolHandler.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, selecionador de símbolos", + "symbols": "resultados de símbolo", + "noSymbolsMatching": "Não há símbolos correspondentes", + "noSymbolsWithoutInput": "Digitar para pesquisar símbolos" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/search/browser/patternInputWidget.i18n.json b/i18n/ptb/src/vs/workbench/parts/search/browser/patternInputWidget.i18n.json new file mode 100644 index 00000000000..68c8c0ad6b7 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/search/browser/patternInputWidget.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defaultLabel": "entrada", + "patternDescription": "Use Padrões Glob", + "patternHelpInclude": "O padrão para combinações. Por exemplo, **\\*\\*/*.js** para corresponder a todos os arquivos JavaScript ou **myFolder/\\*\\*** para corresponder a essa pasta com todas pastas aninhadas.\n\n**Referência**:\n**\\*** corresponde a 0 ou mais caracteres\n**?** corresponde a 1 caractere\n**\\*\\*** corresponde a zero ou mais diretórios\n**[a-z]** corresponde a um intervalo de caracteres\n**{a, b}** corresponde a qualquer um dos padrões)", + "useIgnoreFilesDescription": "Usar Ignorar Arquivos", + "useExcludeSettingsDescription": "Usar Configurações de Exclusão" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/search/browser/replaceService.i18n.json b/i18n/ptb/src/vs/workbench/parts/search/browser/replaceService.i18n.json new file mode 100644 index 00000000000..05d7f4e4cd0 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/search/browser/replaceService.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "fileReplaceChanges": "{0} ↔ {1} (Substituir Preview)" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/search/browser/search.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/search/browser/search.contribution.i18n.json new file mode 100644 index 00000000000..b14e20a1487 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/search/browser/search.contribution.i18n.json @@ -0,0 +1,22 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "showTriggerActions": "Ir para Símbolo no Espaço de Trabalho...", + "name": "Pesquisar", + "showSearchViewlet": "Mostrar Busca", + "view": "Exibir", + "findInFiles": "Localizar nos Arquivos", + "openAnythingHandlerDescription": "Ir para o Arquivo", + "openSymbolDescriptionNormal": "Ir para o Símbolo em Ãrea de Trabalho", + "searchOutputChannelTitle": "Pesquisar", + "searchConfigurationTitle": "Pesquisar", + "exclude": "Configure os padrões glob para excluir arquivos e pastas nas pesquisas. Herda todos os padrões glob da configuração files.exclude.", + "exclude.boolean": "O padrão glob com o qual combinar os caminhos de arquivo. Defina para verdadeiro ou falso para habilitar ou desabilitar o padrão.", + "exclude.when": "Verificação adicional nos irmãos de um arquivo correspondente. Use $(basename) como variável para o nome do arquivo correspondente.", + "useRipgrep": "Controla se deve utilizar ripgrep na pesquisa de texto", + "useIgnoreFilesByDefault": "Controla se deve utilizar arquivos .gitignore e .ignore por padrão ao fazer pesquisas em um novo espaço de trabalho.", + "search.quickOpen.includeSymbols": "Configurar para incluir resultados de uma pesquisa símbolo global nos resultados do arquivo para Abertura Rápida." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/search/browser/searchActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/search/browser/searchActions.i18n.json new file mode 100644 index 00000000000..94f7c40e782 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/search/browser/searchActions.i18n.json @@ -0,0 +1,21 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "nextSearchTerm": "Mostrar o Próximo Termo de Pesquisa", + "previousSearchTerm": "Mostrar Termo de Pesquisa Anterior", + "focusNextInputBox": "Focalizar a Próxima Caixa de Entrada", + "focusPreviousInputBox": "Focalizar a Caixa de Entrada Anterior", + "replaceInFiles": "Substituir nos Arquivos", + "findInFolder": "Encontrar na pasta", + "RefreshAction.label": "Atualizar", + "ClearSearchResultsAction.label": "Limpar os Resultados da Pesquisa", + "FocusNextSearchResult.label": "Focalizar o Próximo Resultado da Pesquisa", + "FocusPreviousSearchResult.label": "Focalizar o Resultado da Pesquisa Anterior", + "RemoveAction.label": "Remover", + "file.replaceAll.label": "Substituir Tudo", + "match.replace.label": "Substituir", + "ConfigureGlobalExclusionsAction.label": "Abrir configurações" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json b/i18n/ptb/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json new file mode 100644 index 00000000000..3edda1861fb --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "searchMatches": "{0} correspondências encontradas", + "searchMatch": "{0} correspondência encontrada", + "fileMatchAriaLabel": "{0} correspondências no arquivo {1} da pasta {2}, Resultado da pesquisa", + "replacePreviewResultAria": "Substitua o termo {0} pelo termo {1} na coluna posição {2} correspondente ao texto {3}", + "searchResultAria": "Encontrado o termo {0} na posição da coluna {1} correspondente ao texto {2}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/search/browser/searchViewlet.i18n.json b/i18n/ptb/src/vs/workbench/parts/search/browser/searchViewlet.i18n.json new file mode 100644 index 00000000000..4ceea616010 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/search/browser/searchViewlet.i18n.json @@ -0,0 +1,50 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "moreSearch": "Alternar Detalhes da Pesquisa", + "searchScope.includes": "arquivos a serem incluídos", + "label.includes": "Pesquisa Padrões de Inclusão", + "searchScope.excludes": "arquivos a serem excluídos", + "label.excludes": "Pesquisa de Padrões de Exclusão", + "global.searchScope.folders": "arquivos excluídos pelas configurações", + "label.global.excludes": "Configurado pesquisa padrões de exclusão", + "replaceAll.confirmation.title": "Substituir Tudo", + "replaceAll.confirm.button": "Substituir", + "replaceAll.occurrence.file.message": "Substituída {0} ocorrência no arquivo {1} com '{2}'.", + "removeAll.occurrence.file.message": "Substituída {0} ocorrência no arquivo {1}'.", + "replaceAll.occurrence.files.message": "Substituída {0} ocorrência no arquivo {1} com '{2}'.", + "removeAll.occurrence.files.message": "Substituída {0} ocorrência nos arquivos {1}", + "replaceAll.occurrences.file.message": "Substituídas {0} ocorrências no arquivo {1} com '{2}'.", + "removeAll.occurrences.file.message": "Substituídas {0} ocorrências nos arquivo {1}.", + "replaceAll.occurrences.files.message": "Substituídas {0} ocorrências nos arquivos {1} com '{2}'.", + "removeAll.occurrences.files.message": "Substituídas {0} ocorrências nos arquivos {1}.", + "removeAll.occurrence.file.confirmation.message": "Substituir {0} ocorrências no arquivo {1} com '{2}'?", + "replaceAll.occurrence.file.confirmation.message": "Substituir {0} ocorrência no arquivo {1}?", + "removeAll.occurrence.files.confirmation.message": "Substituir {0} ocorrência nos arquivos {1} com '{2}'?", + "replaceAll.occurrence.files.confirmation.message": "Substituir {0} ocorrência nos arquivos {1}?", + "removeAll.occurrences.file.confirmation.message": "Substituir {0} ocorrências no arquivo {1} com '{2}'?", + "replaceAll.occurrences.file.confirmation.message": "Substituir {0} ocorrências no arquivo {1}?", + "removeAll.occurrences.files.confirmation.message": "Substituir {0} ocorrências nos arquivos {1} com '{2}'?", + "replaceAll.occurrences.files.confirmation.message": "Substituir {0} ocorrências nos arquivos {1}?", + "treeAriaLabel": "Resultados da Pesquisa", + "globLabel": "{0} quando {1}", + "searchMaxResultsWarning": "O conjunto de resultados contém apenas um subconjunto de todas as correspondências. Seja mais específico na sua pesquisa para diminuir o número de resultados.", + "searchCanceled": "Pesquisa foi cancelada antes de qualquer resultado ser encontrado - ", + "noResultsIncludesExcludes": "Nenhum resultado encontrado em '{0}' excluindo '{1}' - ", + "noResultsIncludes": "Nenhum resultado encontrado em '{0}' -", + "noResultsExcludes": "Nenhum resultado encontrado excluindo '{0}' -", + "noResultsFound": "Nenhum resultado encontrado. Analise as configurações para exclusões configuradas - ", + "rerunSearch.message": "Pesquisar novamente", + "rerunSearchInAll.message": "Pesquisar novamente em todos os arquivos", + "openSettings.message": "Abrir configurações", + "ariaSearchResultsStatus": "Pesquisa retornou {0} resultados em {1} arquivos", + "search.file.result": "{0} resultado no arquivo {1}", + "search.files.result": "{0} resultado nos arquivos {1}", + "search.file.results": "{0} resultados no arquivo {1}", + "search.files.results": "{0} resultados nos arquivos {1}", + "searchWithoutFolder": "Você ainda não abriu uma pasta. Somente arquivos abertos são pesquisados - ", + "openFolder": "Abrir Pasta" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/search/browser/searchWidget.i18n.json b/i18n/ptb/src/vs/workbench/parts/search/browser/searchWidget.i18n.json new file mode 100644 index 00000000000..41178af28cc --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/search/browser/searchWidget.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "search.action.replaceAll.disabled.label": "Substituir Todos (Submeter Pesquisa para Habilitar)", + "search.action.replaceAll.enabled.label": "Substituir Tudo", + "search.replace.toggle.button.title": "Alternar Substituir", + "label.Search": "Pesquisar: Digite o termo de pesquisa e pressione Enter para pesquisar ou Escape para cancelar", + "search.placeHolder": "Pesquisar", + "label.Replace": "Substituir: Digite o termo a ser substituído e pressione Enter para visualizar ou Escape para cancelar", + "search.replace.placeHolder": "Substituir", + "regexp.validationFailure": "A expressão corresponde a tudo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json new file mode 100644 index 00000000000..0f8e6360187 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.snippets": "Contribui aos trechos de código.", + "vscode.extension.contributes.snippets-language": "Identificador de linguagem para o qual este trecho de código contribui.", + "vscode.extension.contributes.snippets-path": "Caminho do arquivo de trechos de código. O caminho é relativo à pasta de extensão e normalmente começa com '. /snippets/'.", + "invalid.language": "Linguagem desconhecida em `contributes.{0}.language`. Valor fornecido: {1}", + "invalid.path.0": "Esperada uma string em `contributes.{0}.path`. Valor informado: {1}", + "invalid.path.1": "É esperado que `contributes.{0}.path` ({1}) seja incluído na pasta da extensão ({2}). Isto pode tornar a extensão não portável." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/insertSnippet.i18n.json b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/insertSnippet.i18n.json new file mode 100644 index 00000000000..6c34a620b89 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/insertSnippet.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "snippet.suggestions.label": "Inserir trecho de código" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json new file mode 100644 index 00000000000..05f799f7b6a --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openSnippet.label": "Abrir trechos de código do usuário", + "openSnippet.pickLanguage": "Selecionar Idioma para o Trecho", + "openSnippet.errorOnCreate": "Não é possível criar {0}", + "preferences": "Preferências", + "snippetSchema.json.default": "Trecho de código vazio", + "snippetSchema.json": "Configuração do trecho do usuário", + "snippetSchema.json.prefix": "O prefixo usado ao selecionar o trecho no intelliSense", + "snippetSchema.json.body": "O conteúdo do trecho de código. Use '${id}', '${id: rótulo}', '${1:label}' para variáveis e '$0', '$1' para posições do cursor", + "snippetSchema.json.description": "A descrição do trecho." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/snippetsService.i18n.json b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/snippetsService.i18n.json new file mode 100644 index 00000000000..a4a18c1e970 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/snippetsService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "detail.userSnippet": "Trecho de código do usuário", + "snippetSuggest.longLabel": "{0}, {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/tabCompletion.i18n.json b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/tabCompletion.i18n.json new file mode 100644 index 00000000000..adfb9a4190d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/tabCompletion.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tabCompletion": "Inserir trechos de código quando seu prefixo corresponder. Funciona melhor quando 'quickSuggestions' não está habilitado." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json new file mode 100644 index 00000000000..be3fefb5d3d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, tarefas", + "workspace": "Do espaço de trabalho", + "extension": "De extensões" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json new file mode 100644 index 00000000000..4009d3b8154 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksAriaLabel": "Digite o nome de uma tarefa para reiniciar", + "noTasksMatching": "Não há tarefas correspondentes", + "noTasksFound": "Não há tarefa para ser reiniciada" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json new file mode 100644 index 00000000000..6b4d6134384 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksAriaLabel": "Digite o nome de uma tarefa para executar", + "noTasksMatching": "Não há tarefas correspondentes", + "noTasksFound": "Não há tarefas encontradas" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.i18n.json new file mode 100644 index 00000000000..9c5ee4b4b59 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksAriaLabel": "Digite o nome de uma tarefa para finalizar", + "noTasksMatching": "Não há tarefas correspondentes", + "noTasksFound": "Nenhuma tarefa para finalizar encontrada" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json new file mode 100644 index 00000000000..2de0b161ac8 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ConfigurationParser.invalidCWD": "Aviso: options.cwd deve ser do tipo string. Ignorando valor {0}\n", + "ConfigurationParser.noShell": "Aviso: A configuração do shell somente é suportada quando estiver executando tarefas no terminal.", + "ConfigurationParser.noargs": "Erro: Argumentos do comando devem ser uma matriz de strings. Valor informado é:\n{0}", + "ConfigurationParser.noName": "Erro: Problem Matcher no escopo declarado deve ter um nome:\n{0}\n", + "ConfigurationParser.unknownMatcherKind": "Aviso: a correspondência de problema definido é desconhecido. Tipos suportados são string | ProblemMatcher | (string | ProblemMatcher)[].\n{0}\n", + "ConfigurationParser.invalidVaraibleReference": "Erro: ProblemMatcher inválido referência: {0}\n", + "ConfigurationParser.noTaskName": "Erro: tarefas devem fornecer uma propriedade taskName. A tarefa será ignorada.\n{0}\n", + "taskConfiguration.shellArgs": "Aviso: a tarefa '{0}' é um comando do shell e o nome de comando ou um dos seus argumentos tem espaços sem escape. Para garantir a linha de comando correta por favor mesclar argumentos no comando.", + "taskConfiguration.noCommandOrDependsOn": "Erro: a tarefa '{0}' também não especifica um comando ou uma propriedade dependsOn. A tarefa será ignorada. Sua definição é: {1}", + "taskConfiguration.noCommand": "Erro: a tarefa '{0}' não define um comando. A tarefa será ignorada. Sua definição é: {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/common/taskTemplates.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/common/taskTemplates.i18n.json new file mode 100644 index 00000000000..268871153e3 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/common/taskTemplates.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tsc.config": "Compila um projeto TypeScript", + "tsc.watch": "Compila um projeto TypeScript em mode de monitoramento", + "dotnetCore": "Executa comando de compilação do .NET Core", + "msbuild": "Executa a compilação destino", + "externalCommand": "Exemplo para executar um comando externo arbitrário", + "Maven": "Executa comandos comuns específicos" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json new file mode 100644 index 00000000000..92ae501cdc8 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json @@ -0,0 +1,38 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "JsonSchema.options": "Opções de comando adicionais", + "JsonSchema.options.cwd": "O diretório de trabalho atual do programa executado ou do script. Se omitido raiz de espaço de trabalho atual do código é usado.", + "JsonSchema.options.env": "O ambiente do programa executado ou comando shell. Se omitido o ambiente do processo pai é usado.", + "JsonSchema.shell.executable": "O shell a ser usado.", + "JsonSchema.shell.args": "Os argumentos shell.", + "JsonSchema.command": "O comando a ser executado. Pode ser um programa externo ou um comando shell.", + "JsonSchema.tasks.args": "Argumentos passados para o comando quando esta tarefa é invocada.", + "JsonSchema.tasks.taskName": "Nome da tarefa", + "JsonSchema.tasks.windows": "Configuração de comando específica do Windows", + "JsonSchema.tasks.mac": "Configuração de comando específica do Mac", + "JsonSchema.tasks.linux": "Configuração de comando específica do Linux", + "JsonSchema.tasks.suppressTaskName": "Controla se o nome de tarefa é adicionado como um argumento para o comando. Se omitido o valor definido globalmente é usado.", + "JsonSchema.tasks.showOutput": "Controla se a saída da execução de tarefas é mostrada ou não. Se omitido o valor definido globalmente é usado.", + "JsonSchema.echoCommand": "Controla se o comando executado é enviado para a saída. O padrão é false.", + "JsonSchema.tasks.watching.deprecation": "Descontinuado. Use isBackground.", + "JsonSchema.tasks.watching": "Se a tarefa executada é mantida viva e está monitorando o sistema de arquivos.", + "JsonSchema.tasks.background": "Se a tarefa executada é mantida viva e é executado em segundo plano.", + "JsonSchema.tasks.promptOnClose": "Se o usuário é solicitado quando VS Code fecha com uma tarefa sendo executada.", + "JsonSchema.tasks.build": "Esta tarefa é mapeada para o comando de compilação padrão do código.", + "JsonSchema.tasks.test": "Esta tarefa é mapeada para o comando de teste padrão do código.", + "JsonSchema.tasks.matchers": "O problema matcher(s) a seu utilizado. Pode ser uma sequência de caracteres ou uma definição de problem matcher ou uma matriz de sequências de caracteres e problem matchers.", + "JsonSchema.args": "Argumentos adicionais passados para o comando.", + "JsonSchema.showOutput": "Controla se a saída da execução de tarefas é mostrada ou não. Se omitido 'sempre' é usado.", + "JsonSchema.watching.deprecation": "Descontinuado. Use isBackground.", + "JsonSchema.watching": "Se a tarefa executada é mantida viva e está monitorando o sistema de arquivos.", + "JsonSchema.background": "Se a tarefa executada é mantida viva e é executado em segundo plano.", + "JsonSchema.promptOnClose": "Se o usuário é solicitado quando VS Code fecha com uma tarefa de segundo plano em execução.", + "JsonSchema.suppressTaskName": "Controla se o nome de tarefa é adicionado como um argumento para o comando. O padrão é false.", + "JsonSchema.taskSelector": "Prefixo para indicar que um argumento é tarefa.", + "JsonSchema.matchers": "A correspondência de problemas a ser utilizada. Pode ser uma sequência de caracteres ou uma definição de correspondência de problemas ou uma matriz de sequências de caracteres e correspondência de problemas.", + "JsonSchema.tasks": "As configurações de tarefa. Normalmente são ampliações de tarefas já definidas na execução de tarefa externa." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json new file mode 100644 index 00000000000..dc0695101b0 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "JsonSchema.version": "Número da versão do config", + "JsonSchema.windows": "Configuração de comando específica do Windows", + "JsonSchema.mac": "Configuração de comando específica do Mac", + "JsonSchema.linux": "Configuração de comando específica do Linux", + "JsonSchema.shell": "Especifica se o comando é um comando shell ou um programa externo. O padrão é falso se omitido." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json new file mode 100644 index 00000000000..3130e474d7e --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "JsonSchema.version": "Número da versão do config", + "JsonSchema.windows": "Configuração de comando específica do Windows", + "JsonSchema.mac": "Configuração de comando específica do Mac", + "JsonSchema.linux": "Configuração de comando específica do Linux", + "JsonSchema.shell": "Especifica se o comando é um comando shell ou um programa externo. O padrão é falso se omitido.", + "JsonSchema.tasks.dependsOn.string": "Outra tarefa da qual esta tarefa depende.", + "JsonSchema.tasks.dependsOn.array": "A outra tarefa que esta tarefa depende." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json new file mode 100644 index 00000000000..a07be4d2850 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json @@ -0,0 +1,47 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksCategory": "Tarefas", + "ConfigureTaskRunnerAction.noWorkspace": "Tarefas somente estão disponíveis em uma pasta da área de trabalho.", + "ConfigureTaskRunnerAction.quickPick.template": "Selecione um gerenciador de tarefa", + "ConfigureTaskRunnerAction.autoDetecting": "Tarefas de auto detecção para {0}", + "ConfigureTaskRunnerAction.autoDetect": "A tarefa de sistema de auto detecção falhou. Usando o modelo padrão. Consulte a saída da tarefa para detalhes.", + "ConfigureTaskRunnerAction.autoDetectError": "A tarefa de sistema de auto detecção produziu erros. Consulte a saída da tarefa para detalhes.", + "ConfigureTaskRunnerAction.failed": "Não é possível criar o arquivo 'tasks.json' na pasta '.vscode'. Consulte a saída da tarefa para detalhes.", + "ConfigureTaskRunnerAction.label": "Configure o gerenciador de tarefas", + "ConfigureBuildTaskAction.label": "Configurar Tarefa de Compilação", + "CloseMessageAction.label": "Fechar", + "ShowTerminalAction.label": "Terminal Visualização", + "problems": "Problemas", + "manyMarkers": "99+", + "tasks": "Tarefas", + "TaskSystem.noHotSwap": "Alterar o mecanismo de execução de tarefa requer reiniciar o VS Code. A alteração será ignorada.", + "TaskService.noBuildTask": "Nenhuma tarefa de compilação definida. Marque uma tarefa com 'isBuildCommand' no arquivo tasks.json.", + "TaskService.noTestTask": "Nenhuma tarefa de teste definida. Marque uma tarefa com 'isTestCommand' no arquivo tasks.json.", + "TaskServer.noTask": "Tarefa {0} requisitada para execução não encontrada.", + "TaskSystem.activeSame": "A tarefa já está ativa e em modo de monitoramento. Para terminar a tarefa, use `F1 > terminar tarefa`", + "TaskSystem.active": "Já existe uma tarefa sendo executada. Finalize-a antes de executar outra tarefa.", + "TaskSystem.restartFailed": "Falha ao finalizar e reiniciar a tarefa {0}", + "TaskSystem.configurationErrors": "Erro: A configuração da tarefa informada possui erros de validação e não pode ser utilizada. Por favor, corrija os erros primeiro.", + "TaskSystem.invalidTaskJson": "Erro: O conteúdo do arquivo tasks.json possui erros de sintaxe. Por favor, corrija-os antes de executar uma tarefa.\n", + "TaskSystem.runningTask": "Há uma tarefa sendo executada. Deseja finalizá-la?", + "TaskSystem.terminateTask": "&&Finalizar Tarefa", + "TaskSystem.noProcess": "A tarefa executada não existe mais. Se a tarefa produziu processos em background, finalizar o VS Code pode resultar em processos órfãos. Para evitar isso inicie o último processo em background com uma flag de espera.", + "TaskSystem.exitAnyways": "&&Sair de qualquer maneira", + "TerminateAction.label": "Finalizar a tarefa sendo executada", + "TaskSystem.unknownError": "Ocorreu um erro enquanto a tarefa estava sendo executada. Verifique o log de tarefas para detalhes.", + "TaskService.noWorkspace": "Tarefas somente estão disponíveis em uma pasta da área de trabalho.", + "TerminateAction.noProcess": "O processo executado não existe mais. Se a tarefa produziu processos em background, finalizar o VS Code pode resultar em processos órfãos.", + "TerminateAction.failed": "Falha ao finalizar a tarefa sendo executada", + "ShowLogAction.label": "Visualizar o Log de Tarefas", + "RunTaskAction.label": "Executar Tarefa", + "RestartTaskAction.label": "Reiniciar Tarefa", + "BuildAction.label": "Executar Tarefa de compilação", + "TestAction.label": "Executar Tarefa de Teste", + "quickOpen.task": "Executar Tarefa", + "quickOpen.terminateTask": "Finalizar Tarefa", + "quickOpen.restartTask": "Reiniciar Tarefa" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json new file mode 100644 index 00000000000..f21b7eebc35 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "TerminalTaskSystem.unknownError": "Um erro desconhecido ocorreu durante a execução de uma tarefa. Consulte o log de saída de tarefa para obter detalhes.", + "TerminalTaskSystem.terminalName": "Tarefa - {0}", + "TerminalTaskSystem": "Não é possível executar um comando shell em uma unidade UNC.", + "unkownProblemMatcher": "Problem matcher {0} não pode ser resolvido. O matcher será ignorado" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/node/processRunnerDetector.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/node/processRunnerDetector.i18n.json new file mode 100644 index 00000000000..a4f13c42f7c --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/node/processRunnerDetector.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "TaskSystemDetector.noGulpTasks": "Executando gulp..-tarefas-simples não listam nenhuma tarefa. Você executou a instalação do npm?", + "TaskSystemDetector.noJakeTasks": "Executando jake..-tarefas não listam nenhuma tarefa. Você instalou o npm?", + "TaskSystemDetector.noGulpProgram": "Gulp não está instalado no seu sistema. Execute npm install -g gulp para instalá-lo.", + "TaskSystemDetector.noJakeProgram": "Jake não está instalado no seu sistema. Execute npm install -g jake para instalá-lo.", + "TaskSystemDetector.noGruntProgram": "Grunhido não está instalado no seu sistema. Execute npm install -g grunt para instalá-lo.", + "TaskSystemDetector.noProgram": "Programa {0} não foi encontrado. Mensagem é {1}", + "TaskSystemDetector.buildTaskDetected": "Tarefa de construção chamada '{0}' detectada.", + "TaskSystemDetector.testTaskDetected": "Tarefa de teste chamada '{0}' detectada." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json new file mode 100644 index 00000000000..72848a8cde1 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "TaskRunnerSystem.unknownError": "Um erro desconhecido ocorreu durante a execução de uma tarefa. Consulte o log de saída de tarefa para obter detalhes.", + "TaskRunnerSystem.watchingBuildTaskFinished": "\nTarefas de compilação de monitoramento terminaram.", + "TaskRunnerSystem.childProcessError": "Falha ao iniciar o programa externo {0} {1}.", + "TaskRunnerSystem.cancelRequested": "\nA tarefa '{0}' foi finalizada por solicitação do usuário.", + "unkownProblemMatcher": "Problema matcher {0} não pode ser resolvido. O matcher será ignorado" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.i18n.json new file mode 100644 index 00000000000..de21ec3dca1 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.i18n.json @@ -0,0 +1,30 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminalIntegratedConfigurationTitle": "Terminal Integrado", + "terminal.integrated.shell.linux": "O caminho do shell que o terminal usa no Linux.", + "terminal.integrated.shellArgs.linux": "Os argumentos de linha de comando a serem usados no terminal do Linux.", + "terminal.integrated.shell.osx": "O caminho do shell que o terminal usa no OS X.", + "terminal.integrated.shellArgs.osx": "Os argumentos de linha de comando a serem usados no terminal do OS X.", + "terminal.integrated.shell.windows": "O caminho do shell que o terminal usa no Windows. Quando usar um shell fornecido com o Windows (cmd, PowerShell ou Bash no Ubuntu), prefira utilizar C:\\Windows\\sysnative ao invés de C:\\Windows\\System32 para usar as versões de 64 bits.", + "terminal.integrated.shellArgs.windows": "Os argumentos de linha de comando a serem utilizados no terminal do Windows.", + "terminal.integrated.rightClickCopyPaste": "Quando configurado, isto evitará que o menu de contexto apareça quando pressionado o botão direito do mouse dentro do terminal, em vez disso vai copiar quando há uma seleção e colar quando não há nenhuma seleção.", + "terminal.integrated.fontFamily": "Controla a família de fontes do terminal, este padrão é o valor do editor.fontFamily.", + "terminal.integrated.fontLigatures": "Controla se as ligações de fonte são habilitadas no terminal.", + "terminal.integrated.fontSize": "Controla o tamanho da fonte em pixels do terminal.", + "terminal.integrated.lineHeight": "Controles a altura da linha do terminal, este número é multiplicada pelo tamanho da fonte terminal para obter a altura real da linha em pixels.", + "terminal.integrated.enableBold": "Se habilitar o texto em negrito dentro do terminal requer suporte do terminal shell.", + "terminal.integrated.cursorBlinking": "Controla se o cursor do terminal pisca.", + "terminal.integrated.cursorStyle": "Controla o estilo do cursor do terminal.", + "terminal.integrated.scrollback": "Controla a quantidade máxima de linhas que o terminal mantém em seu buffer.", + "terminal.integrated.setLocaleVariables": "Controla se as variáveis locais são definidas na inicialização do terminal, este padrão é verdadeiro no OS X e falso em outras plataformas.", + "terminal.integrated.cwd": "Um caminho de início explícito onde o terminal será lançado, isso é usado como o diretório de trabalho atual (cwd) para o processo shell. Isto pode ser particularmente útil em configurações de espaço de trabalho se o diretório raiz não é um cwd conveniente.", + "terminal.integrated.confirmOnExit": "Confirmar na saída se ainda houverem sessões de terminal ativas.", + "terminal.integrated.commandsToSkipShell": "Um conjunto de IDs de comando, cujas combinações de teclas não serão enviadas para o shell e sempre serão tratadas por código. Isto permite o uso de combinações de teclas que normalmente seriam consumidas pelo shell para agir da mesma forma quando o terminal não é focado, por exemplo ctrl+p para Execução Rápida.", + "terminal": "Terminal", + "terminalCategory": "Terminal", + "viewCategory": "Exibir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json new file mode 100644 index 00000000000..e63bd5db0a0 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json @@ -0,0 +1,32 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "workbench.action.terminal.toggleTerminal": "Alternar Terminal Integrado", + "workbench.action.terminal.kill": "Finalizar a Instância de Terminal Ativa", + "workbench.action.terminal.kill.short": "Encerrar Terminal", + "workbench.action.terminal.copySelection": "Copiar Seleção", + "workbench.action.terminal.new": "Criar Novo Terminal Integrado", + "workbench.action.terminal.new.short": "Novo Terminal", + "workbench.action.terminal.focus": "Focalizar Terminal", + "workbench.action.terminal.focusNext": "Focalizar Próximo Terminal", + "workbench.action.terminal.focusAtIndex": "Focalizar Terminal {0}", + "workbench.action.terminal.focusPrevious": "Focalizar Terminal Anterior", + "workbench.action.terminal.paste": "Colar no Terminal Ativo", + "workbench.action.terminal.DefaultShell": "Selecionar Shell Padrão", + "workbench.action.terminal.runSelectedText": "Executar Texto Selecionado no Terminal Ativo", + "workbench.action.terminal.runActiveFile": "Executar Arquivo Ativo no Terminal Ativo", + "workbench.action.terminal.runActiveFile.noFile": "Apenas arquivos em disco podem ser executados no terminal", + "workbench.action.terminal.switchTerminalInstance": "Trocar a instância de Terminal", + "workbench.action.terminal.scrollDown": "Rolar para Baixo (Linha)", + "workbench.action.terminal.scrollDownPage": "Rolar para Baixo (Página)", + "workbench.action.terminal.scrollToBottom": "Rolar para baixo", + "workbench.action.terminal.scrollUp": "Rolar para Cima (Linha)", + "workbench.action.terminal.scrollUpPage": "Rolar para Cima (Página)", + "workbench.action.terminal.scrollToTop": "Rolar para cima", + "workbench.action.terminal.clear": "Limpar", + "workbench.action.terminal.allowWorkspaceShell": "Permitir a Configuração de Shell da Ãrea de Trabalho", + "workbench.action.terminal.disallowWorkspaceShell": "Não Permitir a Configuração de Shell da Ãrea de Trabalho" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json new file mode 100644 index 00000000000..495bd79c4bb --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminal.background": "A cor de fundo do terminal, isso permite colorir o terminal com uma cor diferente do painel.", + "terminal.foreground": "A cor de primeiro plano do terminal.", + "terminal.ansiColor": "'{0}' cor ansi no terminal." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.i18n.json b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.i18n.json new file mode 100644 index 00000000000..b2b9a9a9843 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminal.integrated.allowWorkspaceShell": "Você permite {0} (definido como uma configuração de espaço de trabalho) a ser executado no terminal?", + "allow": "Permitir", + "disallow": "Não permitir" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json new file mode 100644 index 00000000000..13b6933b1b9 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminal.integrated.copySelection.noSelection": "Não é possível copiar seleção do terminal quando o terminal não tem foco", + "terminal.integrated.exitedWithCode": "O processo terminal encerrado com código de saída: {0}", + "terminal.integrated.waitOnExit": "Pressione qualquer tecla para fechar o terminal", + "terminal.integrated.launchFailed": "O comando de processo de terminal '{0}{1}' falhou ao ser iniciado (código de saída: {2})" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.i18n.json new file mode 100644 index 00000000000..fd175c5ad29 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminalLinkHandler.followLinkCmd": "Cmd + clique para seguir o link", + "terminalLinkHandler.followLinkCtrl": "Ctrl + clique para seguir o link" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.i18n.json b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.i18n.json new file mode 100644 index 00000000000..5e811b86100 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "copy": "Copiar", + "createNewTerminal": "Novo Terminal", + "paste": "Colar", + "clear": "Limpar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalService.i18n.json b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalService.i18n.json new file mode 100644 index 00000000000..08ec4bd9777 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalService.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminal.integrated.chooseWindowsShellInfo": "Você pode alterar o terminal shell padrão selecionando o botão Personalizar.", + "customize": "Personalizar", + "cancel": "Cancelar", + "never again": "Ok, Nunca Mostrar Novamente", + "terminal.integrated.chooseWindowsShell": "Selecione o seu terminal shell preferido, você pode alterar isso mais tarde em suas configurações", + "terminalService.terminalCloseConfirmationSingular": "Há uma sessão ativa de terminal, você quer finalizá-la?", + "terminalService.terminalCloseConfirmationPlural": "Existem {0} sessões ativas de terminal, você quer finalizá-las?", + "yes": "Sim" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json new file mode 100644 index 00000000000..9968bf0b9b1 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json @@ -0,0 +1,19 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "selectTheme.label": "Tema de Cores", + "installColorThemes": "Instalar temas de cor adicionais...", + "themes.selectTheme": "Selecione o tema de cor (teclas cima/baixo para visualização)", + "selectIconTheme.label": "Arquivo de Ãcone do Tema", + "installIconThemes": "Instalar Temas de Ãcones de Arquivos Adicionais...", + "noIconThemeLabel": "Nenhum", + "noIconThemeDesc": "Desabilitar ícones de arquivos", + "problemChangingIconTheme": "Problema configurando tema de ícones: {0}", + "themes.selectIconTheme": "Selecionar Tema de Ãcones de Arquivos", + "generateColorTheme.label": "Gerar Tema de Cores a Partir das Configurações Atuais", + "preferences": "Preferências", + "developer": "Desenvolvedor" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/trust/electron-browser/unsupportedWorkspaceSettings.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/trust/electron-browser/unsupportedWorkspaceSettings.contribution.i18n.json new file mode 100644 index 00000000000..1fc9c8fe3a4 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/trust/electron-browser/unsupportedWorkspaceSettings.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "unsupportedWorkspaceSettings": "Esta área de trabalho contém configurações que só podem ser definidas nas configurações do usuário. ({0})", + "openWorkspaceSettings": "Abrir as configurações do espaço de trabalho", + "openDocumentation": "Saiba Mais", + "ignore": "Ignorar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/update/electron-browser/releaseNotesInput.i18n.json b/i18n/ptb/src/vs/workbench/parts/update/electron-browser/releaseNotesInput.i18n.json new file mode 100644 index 00000000000..213c54a3d24 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/update/electron-browser/releaseNotesInput.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "releaseNotesInputName": "Notas da Versão: {0}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/update/electron-browser/update.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/update/electron-browser/update.contribution.i18n.json new file mode 100644 index 00000000000..3634d3c2f2a --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/update/electron-browser/update.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "release notes": "Notas da versão", + "updateConfigurationTitle": "Atualizar", + "updateChannel": "Configurar se você recebe atualizações automáticas de um canal de atualização. Requer uma reinicialização depois da mudança." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/update/electron-browser/update.i18n.json b/i18n/ptb/src/vs/workbench/parts/update/electron-browser/update.i18n.json new file mode 100644 index 00000000000..4199be74572 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/update/electron-browser/update.i18n.json @@ -0,0 +1,19 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "updateNow": "Atualizar Agora", + "later": "Mais tarde", + "unassigned": "Não atribuído", + "releaseNotes": "Notas da Versão", + "showReleaseNotes": "Mostrar Notas da Versão", + "downloadNow": "Baixar agora", + "read the release notes": "Bem-vindo a {0} v{1}! Gostaria de ler as Notas da Versão?", + "licenseChanged": "Nossos termos de licença mudaram, favor revisá-los.", + "license": "Ler Licença", + "updateAvailable": "{0} será atualizado após reiniciar.", + "thereIsUpdateAvailable": "Há uma atualização disponível.", + "noUpdatesAvailable": "Não há nenhuma atualização disponível." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json b/i18n/ptb/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json new file mode 100644 index 00000000000..dea49eef8d5 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json @@ -0,0 +1,24 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "watermark.showCommands": "Mostrar todos os comandos", + "watermark.quickOpen": "Ir para o Arquivo", + "watermark.openFile": "Abrir Arquivo", + "watermark.openFolder": "Abrir Pasta", + "watermark.openFileFolder": "Abrir Arquivo ou Pasta", + "watermark.openRecent": "Abrir Recente", + "watermark.newUntitledFile": "Novo Arquivo Sem Título", + "watermark.toggleTerminal": "Alternar Terminal", + "watermark.findInFiles": "Localizar nos Arquivos", + "watermark.startDebugging": "Iniciar Depuração", + "watermark.selectTheme": "Mudar Tema", + "watermark.selectKeymap": "Mudar Mapa de Teclas", + "watermark.keybindingsReference": "Referência de Teclado", + "watermark.openGlobalKeybindings": "Atalhos de Teclado", + "watermark.unboundCommand": "não vinculado", + "workbenchConfigurationTitle": "Ãrea de Trabalho", + "tips.enabled": "Quando habilitado, mostrará as dicas de marca d'água quando nenhum editor estiver aberto." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.i18n.json b/i18n/ptb/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.i18n.json new file mode 100644 index 00000000000..93d7a695382 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "welcomeOverlay.explorer": "Explorador de arquivos", + "welcomeOverlay.search": "Pesquisar em arquivos", + "welcomeOverlay.git": "Gerenciamento de código fonte", + "welcomeOverlay.debug": "Executar e depurar", + "welcomeOverlay.extensions": "Gerenciar extensões", + "welcomeOverlay.problems": "Visualizar erros e avisos", + "welcomeOverlay.commandPalette": "Encontrar e executar todos os comandos", + "welcomeOverlay": "Visão geral da Interface do usuário", + "hideWelcomeOverlay": "Esconder a visão geral da Interface", + "help": "Ajuda" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json new file mode 100644 index 00000000000..a0b426025a4 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -0,0 +1,44 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "welcomePage.vscode": "Visual Studio Code", + "welcomePage.editingEvolved": "Edição evoluiu", + "welcomePage.start": "Início", + "welcomePage.newFile": "Novo arquivo", + "welcomePage.openFolder": "Abrir pasta...", + "welcomePage.cloneGitRepository": "Clonar repositório Git...", + "welcomePage.recent": "Recente", + "welcomePage.moreRecent": "Mais...", + "welcomePage.noRecentFolders": "Não há pastas recentes", + "welcomePage.help": "Ajuda", + "welcomePage.keybindingsCheatsheet": "Folha de dicas de teclado para impressão", + "welcomePage.introductoryVideos": "Vídeos introdutórios", + "welcomePage.productDocumentation": "Documentação do produto", + "welcomePage.gitHubRepository": "Repositório GitHub", + "welcomePage.stackOverflow": "Stack Overflow", + "welcomePage.showOnStartup": "Mostrar a página de boas-vindas na inicialização", + "welcomePage.customize": "Personalizar", + "welcomePage.installExtensionPacks": "Ferramentas e linguagens", + "welcomePage.installExtensionPacksDescription": "Instalar o suporte para {0} e {1}", + "welcomePage.moreExtensions": "mais", + "welcomePage.installKeymapDescription": "Instalar atalhos de teclado", + "welcomePage.installKeymapExtension": "Instalar os atalhos de teclado de {0} e {1}", + "welcomePage.others": "outros", + "welcomePage.colorTheme": "Tema de cores", + "welcomePage.colorThemeDescription": "Fazer o editor e seu código parecer do jeito que você gosta", + "welcomePage.learn": "Aprender", + "welcomePage.showCommands": "Encontrar e executar todos os comandos", + "welcomePage.showCommandsDescription": "Comandos de rápido acesso e de pesquisar do painel de controle ({0})", + "welcomePage.interfaceOverview": "Visão geral da interface", + "welcomePage.interfaceOverviewDescription": "Obter uma sobreposição visual, destacando os principais componentes da interface do usuário", + "welcomePage.interactivePlayground": "Playground interativo", + "welcomePage.interactivePlaygroundDescription": "Experimente as características essenciais do editor em um curto passo-a-passo", + "welcomePage.quickLinks": "Links rápidos", + "welcomePage.keybindingsReference": "Referência de atalhos de teclado", + "welcomePage.keybindingsReferenceDescription": "Um PDF para impressão com os atalhos de teclado mais comuns", + "welcomePage.configureSettings": "Configurar definições", + "welcomePage.configureSettingsDescription": "Desbloquear o poder completo do VS Coda ajustando as configurações" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json new file mode 100644 index 00000000000..7012e078815 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "workbenchConfigurationTitle": "Ãrea de Trabalho", + "welcomePage.enabled": "Quando habilitado, irá mostrar a página de boas-vindas na inicialização.", + "help": "Ajuda" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json new file mode 100644 index 00000000000..29755259794 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -0,0 +1,31 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "welcomePage": "Bem-vindo", + "welcomePage.javaScript": "JavaScript", + "welcomePage.typeScript": "TypeScript", + "welcomePage.python": "Python", + "welcomePage.php": "PHP", + "welcomePage.docker": "Docker", + "welcomePage.vim": "Vim", + "welcomePage.sublime": "Sublime", + "welcomePage.atom": "Atom", + "welcomePage.extensionPackAlreadyInstalled": "Suporte para {0} já está instalado.", + "welcomePage.willReloadAfterInstallingExtensionPack": "A janela irá recarregar depois de instalar o suporte para {0}.", + "welcomePage.installingExtensionPack": "Instalar o suporte para {0}...", + "welcomePage.extensionPackNotFound": "Suporte para {0} com o id {1} não pôde ser encontrado.", + "welcomePage.keymapAlreadyInstalled": "Os atalhos de teclado de {0} já estão instalados.", + "welcomePage.willReloadAfterInstallingKeymap": "A janela irá recarregar depois de instalar os {0} atalhos de teclado.", + "welcomePage.installingKeymap": "Instalando os {0} atalhos de teclado...", + "welcomePage.keymapNotFound": "Os {0} atalhos de teclado com o id {1} não podem ser encontrados.", + "welcome.title": "Bem-vindo", + "welcomePage.extensionListSeparator": ", ", + "welcomePage.installedExtension": "{0} (instalado)", + "ok": "OK", + "cancel": "Cancelar", + "welcomePage.quickLinkBackground": "Cor de fundo para as ligações rápidas na página de boas-vindas.", + "welcomePage.quickLinkHoverBackground": "Passar sobre a cor de fundo para as ligações rápidas na página de boas-vindas." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/editor/editorWalkThrough.i18n.json b/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/editor/editorWalkThrough.i18n.json new file mode 100644 index 00000000000..9c7c7f681fa --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/editor/editorWalkThrough.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorWalkThrough": "Playground Interativo", + "editorWalkThrough.title": "Playground Interativo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThrough.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThrough.contribution.i18n.json new file mode 100644 index 00000000000..a789ae1c81f --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThrough.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "walkThrough.editor.label": "Playground Interativo", + "help": "Ajuda", + "interactivePlayground": "Playground Interativo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughActions.i18n.json new file mode 100644 index 00000000000..697623110b0 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughActions.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorWalkThrough.arrowUp": "Rolar para Cima (Linha)", + "editorWalkThrough.arrowDown": "Rolar para Baixo (Linha)", + "editorWalkThrough.pageUp": "Rolar para Cima (Página)", + "editorWalkThrough.pageDown": "Rolar para Baixo (Página)" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json b/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json new file mode 100644 index 00000000000..4131ebae487 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "walkThrough.unboundCommand": "não vinculado", + "walkThrough.gitNotFound": "Parece que o Git não está instalado no seu sistema.", + "walkThrough.embeddedEditorBackground": "Cor de fundo para os editores incorporados no Playground Interativo." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json b/i18n/ptb/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json new file mode 100644 index 00000000000..188ab8da37e --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "open": "Abrir configurações", + "close": "Fechar", + "saveAndRetry": "Salvar as configurações e tentar novamente", + "errorUnknownKey": "Não é possível gravar no arquivo de configuração (chave desconhecida)", + "errorInvalidTarget": "Não é possível gravar no arquivo de configuração (destino inválido)", + "errorNoWorkspaceOpened": "Não é possível gravar em configurações porque nenhuma pasta está aberta. Por favor, abra uma pasta primeiro e tente novamente.", + "errorInvalidConfiguration": "Não é possível gravar em configurações. Por favor abra **User Settings** para corrigir erros/avisos no arquivo e tente novamente.", + "errorInvalidConfigurationWorkspace": "Não é possível gravar em configurações. Por favor abra **Workspace Settings** para corrigir erros/avisos no arquivo e tente novamente.", + "errorConfigurationFileDirty": "Não é possível gravar em configurações, porque o arquivo foi alterado. Por favor, salve o arquivo **User Settings** e tente novamente.", + "errorConfigurationFileDirtyWorkspace": "Não é possível gravar em configurações, porque o arquivo foi alterado. Por favor, salve o arquivo **Workspace Settings** e tente novamente." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/editor/browser/editorService.i18n.json b/i18n/ptb/src/vs/workbench/services/editor/browser/editorService.i18n.json new file mode 100644 index 00000000000..50e968f8ee3 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/editor/browser/editorService.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "compareLabels": "{0} ↔ {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/files/electron-browser/fileService.i18n.json b/i18n/ptb/src/vs/workbench/services/files/electron-browser/fileService.i18n.json new file mode 100644 index 00000000000..49e9152a1db --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/files/electron-browser/fileService.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "netVersionError": "O Microsoft .NET Framework 4.5 é necessário. Por favor siga o link para instalá-lo.", + "installNet": "Baixar o .NET Framework 4.5", + "neverShowAgain": "Não mostrar novamente", + "trashFailed": "Falha em mover '{0}' para a lixeira" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/files/node/fileService.i18n.json b/i18n/ptb/src/vs/workbench/services/files/node/fileService.i18n.json new file mode 100644 index 00000000000..b84feecdb4f --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/files/node/fileService.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "fileInvalidPath": "Recurso de arquivo inválido ({0})", + "fileIsDirectoryError": "Arquivo é diretório ({0})", + "fileBinaryError": "Arquivo parece ser binário e não pode ser aberto como texto", + "fileNotFoundError": "Arquivo não encontrado ({0})", + "unableToMoveCopyError": "Não é possível mover/copiar. Arquivo poderia substituir a pasta em que está contida.", + "foldersCopyError": "Pastas não podem ser copiadas para a área de trabalho. Por favor selecione arquivos individuais para serem copiados.", + "fileReadOnlyError": "Arquivo é Somente Leitura" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/keybinding/common/keybindingEditing.i18n.json b/i18n/ptb/src/vs/workbench/services/keybinding/common/keybindingEditing.i18n.json new file mode 100644 index 00000000000..daa32f59ee9 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/keybinding/common/keybindingEditing.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "errorKeybindingsFileDirty": "Não é possível gravar porque o arquivo está sujo. Por favor, salve o arquivo **Keybindings** e tente novamente.", + "parseErrors": "Não é possível gravar as combinações de teclas. Por favor abra o **arquivo Keybindings** para corrigir erros/avisos no arquivo e tente novamente.", + "errorInvalidConfiguration": "Não é possível gravar as combinações de teclas. **Arquivo Keybindings** tem um objeto que não é do tipo Matriz. Por favor, abra o arquivo para limpar e tentar novamente.", + "emptyKeybindingsHeader": "Coloque suas combinações de teclas neste arquivo para substituir os padrões" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/keybinding/electron-browser/keybindingService.i18n.json b/i18n/ptb/src/vs/workbench/services/keybinding/electron-browser/keybindingService.i18n.json new file mode 100644 index 00000000000..2fac75a5675 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/keybinding/electron-browser/keybindingService.i18n.json @@ -0,0 +1,26 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "nonempty": "Esperado um valor não vazio", + "requirestring": "a propriedade `{0}` é obrigatória e deve ser do tipo `string`", + "optstring": "a propriedade `{0}` é opcional ou pode ser do tipo `string`", + "vscode.extension.contributes.keybindings.command": "Identificador do comando a ser executado quando keybinding é acionado.", + "vscode.extension.contributes.keybindings.key": "Tecla ou sequência de teclas (teclas separadas com o sinal de adição e sequências com espaço, por exemplo Ctrl+O e Ctrl+L L para um acorde", + "vscode.extension.contributes.keybindings.mac": "Chave específica Mac ou sequência de teclas.", + "vscode.extension.contributes.keybindings.linux": "Chave específica Linux ou sequência de teclas.", + "vscode.extension.contributes.keybindings.win": "Chave específica Windows ou sequência de teclas.", + "vscode.extension.contributes.keybindings.when": "Condição quando a chave está ativa.", + "vscode.extension.contributes.keybindings": "Contribui para Atalhos de Teclado.", + "invalid.keybindings": "Inválido `contributes.{0}`: {1}", + "unboundCommands": "Aqui estão outros comandos disponíveis: ", + "keybindings.json.title": "Configuração de combinações de teclas", + "keybindings.json.key": "Tecla ou sequência de teclas (separados por espaço)", + "keybindings.json.command": "Nome do comando a ser executado", + "keybindings.json.when": "Condição quando a chave está ativa.", + "keybindings.json.args": "Argumentos a serem passados para o comando para executar.", + "keyboardConfigurationTitle": "Teclado", + "dispatch": "Controla a lógica de expedição para pressionamentos de teclas para usar `keydown.code` (recomendado) ou 'keydown.keyCode'." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/message/browser/messageList.i18n.json b/i18n/ptb/src/vs/workbench/services/message/browser/messageList.i18n.json new file mode 100644 index 00000000000..267b62d179d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/message/browser/messageList.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "alertErrorMessage": "Erro: {0}", + "alertWarningMessage": "Aviso: {0}", + "alertInfoMessage": "Informações: {0}", + "error": "Erro", + "warning": "Aviso", + "info": "Informações", + "close": "Fechar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/message/electron-browser/messageService.i18n.json b/i18n/ptb/src/vs/workbench/services/message/electron-browser/messageService.i18n.json new file mode 100644 index 00000000000..cecec4b4c3a --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/message/electron-browser/messageService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "yesButton": "&&Sim", + "cancelButton": "Cancelar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/mode/common/workbenchModeService.i18n.json b/i18n/ptb/src/vs/workbench/services/mode/common/workbenchModeService.i18n.json new file mode 100644 index 00000000000..91df655432d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/mode/common/workbenchModeService.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "invalid": "Inválido 'contributes.{0}`. Matriz esperada.", + "invalid.empty": "Valor em branco para` contributes.{0}`", + "require.id": "a propriedade `{0}` é obrigatória e deve ser do tipo `string`", + "opt.extensions": "a propriedade `{0}` pode ser omitida e deve ser do tipo `string[]`", + "opt.filenames": "a propriedade `{0}` pode ser omitida e deve ser do tipo `string[]`", + "opt.firstLine": "a propriedade `{0}` pode ser omitida e deve ser do tipo `string`", + "opt.configuration": "a propriedade `{0}` pode ser omitida e deve ser do tipo `string`", + "opt.aliases": "a propriedade `{0}` pode ser omitida e deve ser do tipo `string[]`", + "opt.mimetypes": "a propriedade `{0}` pode ser omitida e deve ser do tipo `string[]`" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/textfile/common/textFileEditorModel.i18n.json b/i18n/ptb/src/vs/workbench/services/textfile/common/textFileEditorModel.i18n.json new file mode 100644 index 00000000000..7eed5484379 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/textfile/common/textFileEditorModel.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "saveFileFirst": "O arquivo está alterado. Por favor, salvá-lo primeiro antes reabri-lo com outra codificação.", + "genericSaveError": "Erro ao salvar '{0}': {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/textfile/common/textFileService.i18n.json b/i18n/ptb/src/vs/workbench/services/textfile/common/textFileService.i18n.json new file mode 100644 index 00000000000..9fe74ad26f3 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/textfile/common/textFileService.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "files.backup.failSave": "Arquivos não poderiam ser backupeados (erro: {0}), tente salvar seus arquivos para sair." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/textfile/electron-browser/textFileService.i18n.json b/i18n/ptb/src/vs/workbench/services/textfile/electron-browser/textFileService.i18n.json new file mode 100644 index 00000000000..491b19e87c4 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/textfile/electron-browser/textFileService.i18n.json @@ -0,0 +1,18 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "saveChangesMessage": "Você quer salvar as alterações feitas para {0}?", + "saveChangesMessages": "Você quer salvar as alterações para os seguintes {0} arquivos?", + "moreFile": "... 1 arquivo adicional não está mostrado", + "moreFiles": "... {0} arquivos adicionais não estão mostrados", + "saveAll": "&&Salvar tudo", + "save": "&&Salvar", + "dontSave": "&&Não Salvar", + "cancel": "Cancelar", + "saveChangesDetail": "Suas alterações serão perdidas se você não salvá-las.", + "allFiles": "Todos os arquivos", + "noExt": "Sem extensão" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/themes/common/colorThemeSchema.i18n.json b/i18n/ptb/src/vs/workbench/services/themes/common/colorThemeSchema.i18n.json new file mode 100644 index 00000000000..02e2bc18273 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/themes/common/colorThemeSchema.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "schema.colors": "Cores para o realce de sintaxe", + "schema.properties.name": "Descrição da regra", + "schema.fontStyle": "Estilo da fonte da regra: um estilo ou uma combinação de 'itálico', 'negrito' e 'sublinhado'", + "schema.tokenColors.path": "Caminho para um arquivo tmTheme (relativo ao arquivo atual)" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/themes/common/fileIconThemeSchema.i18n.json b/i18n/ptb/src/vs/workbench/services/themes/common/fileIconThemeSchema.i18n.json new file mode 100644 index 00000000000..3cf20c82de2 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/themes/common/fileIconThemeSchema.i18n.json @@ -0,0 +1,37 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "schema.folderExpanded": "O ícone de pasta para pastas expandidas. O ícone da pasta expandido é opcional. Se não definido, o ícone definido para a pasta será mostrado.", + "schema.folder": "O ícone de pasta para pastas colapsadas, e se folderExpanded não estiver definido, também para pastas expandidas.", + "schema.file": "O ícone de arquivo padrão, indicado para todos os arquivos que não correspondem a qualquer extensão, nome de arquivo ou idioma.", + "schema.folderNames": "Associa os nomes de pasta à ícones. A chave do objeto é o nome da pasta, não incluindo quaisquer segmentos de caminho. Nenhum padrão ou curinga são permitidos. O nome da pasta de correspondência diferencia maiusculas de minúsculas.", + "schema.folderName": "A ID da definição do ícone para associação.", + "schema.folderNamesExpanded": "Associa os nomes de pasta a ícones para pastas expandidas. A chave do objeto é o nome da pasta, não incluindo quaisquer segmentos do caminho. Padrões ou curingas não são permitidas. A correspondência do nome de pastas não diferencia maiusculas de minúsculas.", + "schema.folderNameExpanded": "A ID da definição do ícone para a associação.", + "schema.fileExtensions": "Associa as extensões de arquivo aos ícones. A chave do objeto é o nome da extensão do arquivo. O nome da extensão é o último segmento de um nome de arquivo após o último ponto (não incluindo o ponto). As extensões não diferenciam maiúsculas de minúsculas.", + "schema.fileExtension": "A ID da definição do ícone para a associação.", + "schema.fileNames": "Associa os nomes de arquivo à ícones. A chave do objeto é o nome completo do arquivo, mas não incluindo quaisquer segmentos do caminho. O nome do arquivo pode incluir pontos e uma extensão de arquivo. Nenhum padrão ou curinga é permitido. A correspondência de nome de arquivo não diferencia maiúsculas de minúsculas.", + "schema.fileName": "A ID da definição do ícone para a associação.", + "schema.languageIds": "Associa idiomas a ícones. A chave do objeto é o id de idioma definido no ponto de contribuição de linguagem.", + "schema.languageId": "O ID da definição do ícone para a associação.", + "schema.fonts": "Fontes que são usadas nas definições de ícone.", + "schema.id": "O ID da fonte.", + "schema.src": "A localização da fonte.", + "schema.font-path": "O caminho do fonte, relativo ao arquivo de tema de ícone atual.", + "schema.font-format": "O formato da fonte.", + "schema.font-weight": "O peso da fonte.", + "schema.font-sstyle": "O estilo da fonte.", + "schema.font-size": "O tamanho padrão da fonte.", + "schema.iconDefinitions": "Descrição de todos os ícones que podem ser usados quando associar arquivos de ícones.", + "schema.iconDefinition": "Uma definição de ícone. A chave do objeto é o ID da definição.", + "schema.iconPath": "Ao usar um SVG ou PNG: O caminho para a imagem. O caminho é relativo ao arquivo de configuração do ícone.", + "schema.fontCharacter": "Ao usar uma fonte glyph: O caractere na fonte para usar.", + "schema.fontColor": "Ao usar uma fonte glyph: A cor a ser utilizada.", + "schema.fontSize": "Quando estiver utilizando uma fonte: O tamanho da fonte em porcentagem para a fonte de texto. Se não for definido, o padrão é o tamanho na definição de fonte.", + "schema.fontId": "Quando estiver utilizando uma fonte: A identificação da fonte. Se não for definido, o padrão é a primeira definição de fonte.", + "schema.light": "Associações opcionais para ícones de arquivo em temas de cor clara.", + "schema.highContrast": "Associações opcionais para ícones de arquivo em temas de alto contraste." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/themes/electron-browser/colorThemeData.i18n.json b/i18n/ptb/src/vs/workbench/services/themes/electron-browser/colorThemeData.i18n.json new file mode 100644 index 00000000000..4ef6944ba73 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/themes/electron-browser/colorThemeData.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "error.cannotparsejson": "Problemas ao analisar o arquivo de tema JSON: {0}", + "error.invalidformat.colors": "Problema ao analisar o arquivo de tema de cor: {0}. A propriedade 'colors' não é do tipo 'object'.", + "error.invalidformat.tokenColors": "Problema ao analisar o arquivo de tema de cor: {0}. A propriedade 'tokenColors' deve ser também uma matriz especificando as cores ou um caminho para um arquivo de texto de tema correspondente", + "error.plist.invalidformat": "Problema ao analisar o arquivo tmTheme: {0}. 'settings' não é uma matriz.", + "error.cannotparse": "Problemas ao analisar o arquivo tmTheme: {0}", + "error.cannotload": "Problemas ao carregar o arquivo tmTheme {0}: {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json b/i18n/ptb/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json new file mode 100644 index 00000000000..caeea848338 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json @@ -0,0 +1,32 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.themes": "Contribui com temas de cores do textmate.", + "vscode.extension.contributes.themes.id": "ID do tema do ícone conforme usado em configurações do usuário.", + "vscode.extension.contributes.themes.label": "Etiqueta da cor do tema como mostrado na interface do usuário.", + "vscode.extension.contributes.themes.uiTheme": "Tema base de definição das cores do editor: 'vs' é o tema de cor clara, 'vs-dark' é o tema de cor escura. 'hc preto' é o tema escuro de alto contraste.", + "vscode.extension.contributes.themes.path": "Caminho do arquivo tmTheme. O caminho é relativo à pasta de extensão e é normalmente './themes/themeFile.tmTheme'.", + "vscode.extension.contributes.iconThemes": "Contribui com temas de ícones de arquivo.", + "vscode.extension.contributes.iconThemes.id": "ID do tema do ícone como usado em configurações do usuário.", + "vscode.extension.contributes.iconThemes.label": "Etiqueta do tema do ícone como mostrado na interface do usuário.", + "vscode.extension.contributes.iconThemes.path": "Caminho do arquivo de definição do tema do ícone. O caminho é relativo à pasta de extensão e é normalmente './icons/awesome-icon-theme.json'.", + "migration.completed": "Foram adicionadas novas configurações de tema para as configurações de usuário. Backup está disponível em {0}.", + "error.cannotloadtheme": "Não é possível carregar {0}: {1}", + "reqarray": "Ponto de extensão '{0}' deve ser uma matriz.", + "reqpath": "Esperada uma string em `contributes.{0}.path`. Valor informado: {1}", + "invalid.path.1": "É esperado que `contributes.{0}.path` ({1}) seja incluído na pasta da extensão ({2}). Isto pode tornar a extensão não portável.", + "reqid": "Esperada sequência em 'contributes.{0}.ID'. Valor fornecido: {1}", + "error.cannotloadicontheme": "Não é possível carregar {0}", + "error.cannotparseicontheme": "Problemas de análise do arquivo de ícones: {0}", + "colorTheme": "Especifica o tema de cores usado no espaço de trabalho.", + "colorThemeError": "Tema é desconhecido ou não está instalado.", + "iconTheme": "Especifica o tema de ícone usado no espaço de trabalho.", + "noIconThemeDesc": "Nenhum arquivo de ícones", + "iconThemeError": "Arquivo de tema de ícones é desconhecido ou não está instalado.", + "workbenchColors": "Substitui as cores do tema do tema de cores atualmente selecionado.", + "workbenchColors.deprecated": "A configuração não é mais experimental e foi renomeada para 'workbench.colorCustomizations'", + "workbenchColors.deprecatedDescription": "Use 'workbench.colorCustomizations'" +} \ No newline at end of file diff --git a/i18n/rus/extensions/markdown/out/extension.i18n.json b/i18n/rus/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/rus/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/rus/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/rus/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/rus/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/rus/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/rus/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/rus/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/rus/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/rus/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/rus/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/rus/extensions/merge-conflict/package.i18n.json b/i18n/rus/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/rus/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/rus/extensions/npm/package.i18n.json b/i18n/rus/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/rus/extensions/npm/package.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/rus/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/rus/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index af5b0c29d70..32fb4e4b4cd 100644 --- a/i18n/rus/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/rus/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,8 +6,6 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "Изображение Ñлишком велико Ð´Ð»Ñ Ð¾Ñ‚Ð¾Ð±Ñ€Ð°Ð¶ÐµÐ½Ð¸Ñ Ð² редакторе. ", - "resourceOpenExternalButton": "Открыть изображение", - "resourceOpenExternalText": " Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ внешней программы?", "nativeBinaryError": "Файл не будет отображен в редакторе, так как он двоичный, очень большой или иÑпользует неподдерживаемую кодировку текÑта.", "sizeB": "{0} Б", "sizeKB": "{0} КБ", diff --git a/i18n/rus/src/vs/code/electron-main/menus.i18n.json b/i18n/rus/src/vs/code/electron-main/menus.i18n.json index 2caee2db03b..68b593f2118 100644 --- a/i18n/rus/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/rus/src/vs/code/electron-main/menus.i18n.json @@ -14,6 +14,7 @@ "mHelp": "&&Справка", "miNewWindow": "&&Ðовое окно", "mAbout": "О программе {0}", + "mServices": "Службы", "mHide": "Скрыть {0}", "mHideOthers": "Скрыть другие", "mShowAll": "Показать вÑе", @@ -69,6 +70,7 @@ "miSmartSelectShrink": "&&Сжать выделение", "miViewExplorer": "Проводник", "miViewSearch": "ПоиÑк", + "miViewSCM": "S&&CM", "miViewDebug": "Отладка", "miViewExtensions": "Р&&аÑширениÑ", "miToggleOutput": "Вывод", diff --git a/i18n/rus/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/rus/src/vs/editor/common/config/commonEditorConfig.i18n.json index 9b6838aa665..53078d0a5b6 100644 --- a/i18n/rus/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/rus/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -40,7 +40,6 @@ "formatOnType": "УправлÑет параметром, определÑющим, должен ли редактор автоматичеÑки форматировать Ñтроку поÑле ввода.", "formatOnPaste": "ОпределÑет, будет ли редактор автоматичеÑки форматировать вÑтавленное Ñодержимое. Модуль Ñ„Ð¾Ñ€Ð¼Ð°Ñ‚Ð¸Ñ€Ð¾Ð²Ð°Ð½Ð¸Ñ Ð´Ð¾Ð»Ð¶ÐµÐ½ быть доÑтупен и иметь возможноÑÑ‚ÑŒ форматировать диапазон в документе.", "suggestOnTriggerCharacters": "ОпределÑет, должны ли при вводе триггерных Ñимволов автоматичеÑки отображатьÑÑ Ð¿Ñ€ÐµÐ´Ð»Ð¾Ð¶ÐµÐ½Ð¸Ñ.", - "acceptSuggestionOnEnter": "ОпределÑет, будут ли Ð¿Ñ€ÐµÐ´Ð»Ð¾Ð¶ÐµÐ½Ð¸Ñ Ð¿Ñ€Ð¸Ð½Ð¸Ð¼Ð°Ñ‚ÑŒÑÑ ÐºÐ»Ð°Ð²Ð¸ÑˆÐµÐ¹ ВВОД в дополнение к клавише TAB. Это помогает избежать неоднозначноÑти между вÑтавкой новых Ñтрок и принÑтием предложений.", "acceptSuggestionOnCommitCharacter": "ОпределÑет, будут ли Ð¿Ñ€ÐµÐ´Ð»Ð¾Ð¶ÐµÐ½Ð¸Ñ Ð¿Ñ€Ð¸Ð½Ð¸Ð¼Ð°Ñ‚ÑŒÑÑ Ñимволами фикÑации. Ðапример, в JavaScript точка Ñ Ð·Ð°Ð¿Ñтой (\";\") может быть Ñимволом фикÑации, принимающим предложение и вводÑщим данный Ñимвол.", "snippetSuggestions": "УправлÑет отображением фрагментов вмеÑте Ñ Ð´Ñ€ÑƒÐ³Ð¸Ð¼Ð¸ предложениÑми и их Ñортировкой.", "emptySelectionClipboard": "УправлÑет тем, копируетÑÑ Ð»Ð¸ Ñ‚ÐµÐºÑƒÑ‰Ð°Ñ Ñтрока при копировании без выделениÑ.", diff --git a/i18n/rus/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/rus/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..e61942e5d18 --- /dev/null +++ b/i18n/rus/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "Определение Ð´Ð»Ñ \"{0}\" не найдено.", + "generic.noResults": "ÐžÐ¿Ñ€ÐµÐ´ÐµÐ»ÐµÐ½Ð¸Ñ Ð½Ðµ найдены.", + "meta.title": " — Ð¾Ð¿Ñ€ÐµÐ´ÐµÐ»ÐµÐ½Ð¸Ñ {0}", + "actions.goToDecl.label": "Перейти к определению", + "actions.goToDeclToSide.label": "Открыть определение Ñбоку", + "actions.previewDecl.label": "Показать определение", + "goToImplementation.noResultWord": "Ðе найдена Ñ€ÐµÐ°Ð»Ð¸Ð·Ð°Ñ†Ð¸Ñ Ð´Ð»Ñ \"{0}\".", + "goToImplementation.generic.noResults": "Ðе найдена реализациÑ.", + "meta.implementations.title": "— {0} реализаций", + "actions.goToImplementation.label": "Перейти к реализации", + "actions.peekImplementation.label": "Показать реализацию", + "goToTypeDefinition.noResultWord": "Ðе найдено определение типа Ð´Ð»Ñ \"{0}\".", + "goToTypeDefinition.generic.noResults": "Ðе найдено определение типа.", + "meta.typeDefinitions.title": "— {0} определений типов", + "actions.goToTypeDefinition.label": "Перейти к определению типа", + "actions.peekTypeDefinition.label": "Показать определение типа" +} \ No newline at end of file diff --git a/i18n/rus/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/rus/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..a403ef380f2 --- /dev/null +++ b/i18n/rus/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "Щелкните, чтобы отобразить Ð¾Ð¿Ñ€ÐµÐ´ÐµÐ»ÐµÐ½Ð¸Ñ ({0})." +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/rus/src/vs/workbench/electron-browser/main.contribution.i18n.json index ff2b65c8fab..f2bd599c1b9 100644 --- a/i18n/rus/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/rus/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -7,6 +7,7 @@ "view": "ПроÑмотреть", "help": "Справка", "file": "Файл", + "developer": "Разработчик", "showEditorTabs": "ОпределÑет, должны ли открытые редакторы отображатьÑÑ Ð½Ð° вкладках или нет.", "editorTabCloseButton": "ОпределÑет положение кнопок Ð·Ð°ÐºÑ€Ñ‹Ñ‚Ð¸Ñ Ð²ÐºÐ»Ð°Ð´Ð¾Ðº редактора или отключает их, еÑли задано значение off.", "showIcons": "ОпределÑет, должны ли открытые редакторы отображатьÑÑ Ñо значком. Требует включить тему значков.", diff --git a/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 8b6ad71cd4e..906d10fee6b 100644 --- a/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "disableOtherKeymapsConfirmation": "Отключить другие раÑкладки клавиатуры, чтобы избежать конфликта между наÑтраиваемыми ÑочетаниÑми клавиш?", + "yes": "Да", + "no": "Ðет" +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/rus/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 952d7106938..6c404cd1796 100644 --- a/i18n/rus/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,7 +16,6 @@ "associations": "ÐаÑтройте ÑопоÑÑ‚Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ñ„Ð°Ð¹Ð»Ð¾Ð² Ñ Ñзыками (например, \"*.extension\": \"html\"). У них будет приоритет перед заданными по умолчанию ÑопоÑтавлениÑми уÑтановленных Ñзыков.", "encoding": "Кодировка набора Ñимволов по умолчанию, иÑÐ¿Ð¾Ð»ÑŒÐ·ÑƒÐµÐ¼Ð°Ñ Ð¿Ñ€Ð¸ чтении и запиÑи файлов", "autoGuessEncoding": "ЕÑли параметр включен, производитÑÑ Ð¿Ð¾Ð¿Ñ‹Ñ‚ÐºÐ° определить кодировку набора Ñимволов при открытии файлов", - "eol": "Символ конца Ñтроки по умолчанию.", "trimTrailingWhitespace": "ЕÑли Ñтот параметр включен, при Ñохранении файла будут удалены концевые пробелы.", "insertFinalNewline": "ЕÑли Ñтот параметр включен, при Ñохранении файла в его конец вÑтавлÑетÑÑ Ñ„Ð¸Ð½Ð°Ð»ÑŒÐ½Ð°Ñ Ð½Ð¾Ð²Ð°Ñ Ñтрока.", "files.autoSave.off": "\"ГрÑзный\" файл не ÑохранÑетÑÑ Ð°Ð²Ñ‚Ð¾Ð¼Ð°Ñ‚Ð¸Ñ‡ÐµÑки.", diff --git a/i18n/rus/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/rus/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index ef99a2ea9f3..5ac046256bd 100644 --- a/i18n/rus/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -5,5 +5,9 @@ // Do not edit this file. It is machine generated. { "slow": "Обнаружен замедленный запуÑк.", - "slow.detail": "Сожалеем, что у Ð²Ð°Ñ Ð¿Ñ€Ð¾Ð¸Ð·Ð¾ÑˆÐµÐ» замедленный запуÑк. ПерезапуÑтите \"{0}\" Ñ Ð²ÐºÐ»ÑŽÑ‡ÐµÐ½Ð½Ñ‹Ð¼ профилированием и отправьте профили нам, чтобы мы могли уÑкорить загрузку." + "slow.detail": "Сожалеем, что у Ð²Ð°Ñ Ð¿Ñ€Ð¾Ð¸Ð·Ð¾ÑˆÐµÐ» замедленный запуÑк. ПерезапуÑтите \"{0}\" Ñ Ð²ÐºÐ»ÑŽÑ‡ÐµÐ½Ð½Ñ‹Ð¼ профилированием и отправьте профили нам, чтобы мы могли уÑкорить загрузку.", + "prof.message": "Профили уÑпешно Ñозданы.", + "prof.detail": "Создайте проблему и вручную вложите Ñледующие файлы:\n{0}", + "prof.restartAndFileIssue": "Создать проблему и выполнить перезапуÑк", + "prof.restart": "ПерезапуÑтить" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/rus/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 901720ad5dd..1365e07209b 100644 --- a/i18n/rus/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -5,6 +5,11 @@ // Do not edit this file. It is machine generated. { "welcomePage": "Добро пожаловать", + "welcomePage.typeScript": "TypeScript", + "welcomePage.php": "PHP", + "welcomePage.vim": "Vim", + "welcomePage.sublime": "Sublime", + "welcomePage.atom": "Atom", "welcomePage.keymapAlreadyInstalled": "Ð¡Ð¾Ñ‡ÐµÑ‚Ð°Ð½Ð¸Ñ ÐºÐ»Ð°Ð²Ð¸Ñˆ {0} уже уÑтановлены.", "welcomePage.willReloadAfterInstallingKeymap": "Окно перезагрузитÑÑ Ð¿Ð¾Ñле уÑтановки Ñочетаний клавиш {0}.", "welcomePage.installingKeymap": "УÑтанавливаютÑÑ ÑÐ¾Ñ‡ÐµÑ‚Ð°Ð½Ð¸Ñ ÐºÐ»Ð°Ð²Ð¸Ñˆ {0}...", -- GitLab From fc59debe991a0d6ed546d02a47a97d1a312ccc47 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 25 May 2017 08:05:53 +0200 Subject: [PATCH 0140/1347] theming - remove hardcoded list color in keybindings editor --- .../browser/media/keybindingsEditor.css | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/src/vs/workbench/parts/preferences/browser/media/keybindingsEditor.css b/src/vs/workbench/parts/preferences/browser/media/keybindingsEditor.css index 29b4fe0a8d1..9932877ef4d 100644 --- a/src/vs/workbench/parts/preferences/browser/media/keybindingsEditor.css +++ b/src/vs/workbench/parts/preferences/browser/media/keybindingsEditor.css @@ -68,20 +68,6 @@ display: flex; } -.keybindings-editor > .keybindings-body .keybindings-list-container .monaco-list-row.keybindings-list-header.focused, -.keybindings-editor > .keybindings-body .keybindings-list-container .monaco-list-row.keybindings-list-header.selected, -.keybindings-editor > .keybindings-body .keybindings-list-container .monaco-list-row.keybindings-list-header:hover, -.keybindings-editor > .keybindings-body > .keybindings-list-container .monaco-list-row.keybindings-list-header, -.keybindings-editor > .keybindings-body > .keybindings-list-container .monaco-list-row.even:not(.focused):not(.selected):not(:hover), -.keybindings-editor > .keybindings-body > .keybindings-list-container .monaco-list:not(:focus) .monaco-list-row.focused.even:not(.selected):not(:hover), -.keybindings-editor > .keybindings-body > .keybindings-list-container .monaco-list:not(.focused) .monaco-list-row.focused.even:not(.selected):not(:hover) { - background-color: rgba(130, 130, 130, 0.04); -} - -.keybindings-editor > .keybindings-body > .keybindings-list-container .monaco-list-row:hover { - background-color: rgba(128, 128, 128, 0.15); -} - .keybindings-editor > .keybindings-body .keybindings-list-container .monaco-list-row > .header { text-align: left; font-weight: bold; -- GitLab From 27625c21a2036f243ffcb1bc74f080513c9f4341 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 08:44:16 +0200 Subject: [PATCH 0141/1347] [lua] update grammar --- extensions/lua/syntaxes/lua.json | 148 ++++++++++++++---- .../lua/test/colorize-results/test_lua.json | 32 +--- 2 files changed, 123 insertions(+), 57 deletions(-) diff --git a/extensions/lua/syntaxes/lua.json b/extensions/lua/syntaxes/lua.json index 0bde9524ea4..a4da3a43c6a 100644 --- a/extensions/lua/syntaxes/lua.json +++ b/extensions/lua/syntaxes/lua.json @@ -1,39 +1,61 @@ { "comment": "Lua Syntax: version 0.8", "fileTypes": [ - "lua" + "lua", + "p8", + "rockspec", + "luacheckrc", + "lakefile" ], - "firstLineMatch": "\\A#!.*?\\blua\\b", + "firstLineMatch": "\\A#!.*?\\blua(\\d+(\\.\\d+)?)?\\b|\\A--\\s+-\\*-\\s*lua\\s*-\\*-", "keyEquivalent": "^~L", "name": "Lua", "patterns": [ { - "captures": { + "begin": "\\b((local\\b)\\s+)?(function)\\s*(\\s+[a-zA-Z_][a-zA-Z0-9_]*(\\.[a-zA-Z_][a-zA-Z0-9_]*)*(:[a-zA-Z_][a-zA-Z0-9_]*)?\\s*)?(\\()", + "beginCaptures": { "1": { - "name": "keyword.control.lua" - }, - "2": { - "name": "entity.name.function.scope.lua" + "name": "storage.modifier.local.lua" }, "3": { - "name": "entity.name.function.lua" + "name": "keyword.control.lua" }, "4": { - "name": "punctuation.definition.parameters.begin.lua" + "name": "entity.name.function.lua" }, "5": { - "name": "variable.parameter.function.lua" - }, - "6": { + "name": "punctuation.definition.parameters.begin.lua" + } + }, + "end": "\\)", + "endCaptures": { + "0": { "name": "punctuation.definition.parameters.end.lua" } }, - "match": "\\b(function)(?:\\s+([a-zA-Z_.:]+[.:])?([a-zA-Z_]\\w*)\\s*)?(\\()([^)]*)(\\))", - "name": "meta.function.lua" + "name": "meta.function.lua", + "patterns": [ + { + "match": "[a-zA-Z_][a-zA-Z0-9_]*", + "name": "variable.parameter.function.lua" + } + ] + }, + { + "match": "(? Date: Thu, 25 May 2017 09:44:01 +0200 Subject: [PATCH 0142/1347] How to configure a window (also for reload case)? (fixes #27192) --- src/vs/code/electron-main/menus.ts | 20 +++++- src/vs/code/electron-main/window.ts | 10 +-- src/vs/code/electron-main/windows.ts | 84 +---------------------- src/vs/code/node/keyboard.ts | 70 +++++++++++++++++++ src/vs/workbench/electron-browser/main.ts | 10 ++- 5 files changed, 100 insertions(+), 94 deletions(-) create mode 100644 src/vs/code/node/keyboard.ts diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index 91ccab243c9..249722e754c 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -9,7 +9,7 @@ import * as nls from 'vs/nls'; import { isMacintosh, isLinux, isWindows, language } from 'vs/base/common/platform'; import * as arrays from 'vs/base/common/arrays'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; -import { ipcMain as ipc, app, shell, dialog, Menu, MenuItem } from 'electron'; +import { ipcMain as ipc, app, shell, dialog, Menu, MenuItem, BrowserWindow } from 'electron'; import { OpenContext } from 'vs/code/common/windows'; import { IWindowsMainService } from 'vs/code/electron-main/windows'; import { VSCodeWindow } from 'vs/code/electron-main/window'; @@ -908,7 +908,7 @@ export class VSCodeMenu { label: this.mnemonicLabel(nls.localize({ key: 'miAccessibilityOptions', comment: ['&& denotes a mnemonic'] }, "Accessibility &&Options")), accelerator: null, click: () => { - this.windowsService.openAccessibilityOptions(); + this.openAccessibilityOptions(); } }, false)); @@ -974,6 +974,22 @@ export class VSCodeMenu { } } + private openAccessibilityOptions(): void { + let win = new BrowserWindow({ + alwaysOnTop: true, + skipTaskbar: true, + resizable: false, + width: 450, + height: 300, + show: true, + title: nls.localize('accessibilityOptionsWindowTitle', "Accessibility Options") + }); + + win.setMenuBarVisibility(false); + + win.loadURL('chrome://accessibility'); + } + private getUpdateMenuItems(): Electron.MenuItem[] { switch (this.updateService.state) { case UpdateState.Uninitialized: diff --git a/src/vs/code/electron-main/window.ts b/src/vs/code/electron-main/window.ts index 7cd1f647083..4b1840c8642 100644 --- a/src/vs/code/electron-main/window.ts +++ b/src/vs/code/electron-main/window.ts @@ -22,7 +22,7 @@ import product from 'vs/platform/node/product'; import { getCommonHTTPHeaders } from 'vs/platform/environment/node/http'; import { IWindowSettings, MenuBarVisibility } from 'vs/platform/windows/common/windows'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; - +import { KeyboardLayoutMonitor } from "vs/code/node/keyboard"; export interface IWindowState { width?: number; @@ -82,10 +82,7 @@ export interface IWindowConfiguration extends ParsedArgs { * The physical keyboard is of ISO type (on OSX). */ isISOKeyboard?: boolean; - /** - * Accessibility support is enabled. - */ - accessibilitySupportEnabled?: boolean; + zoomLevel?: number; fullscreen?: boolean; highContrast?: boolean; @@ -558,6 +555,9 @@ export class VSCodeWindow { windowConfiguration.highContrast = platform.isWindows && systemPreferences.isInvertedColorScheme() && (!windowConfig || windowConfig.autoDetectHighContrast); windowConfiguration.accessibilitySupport = app.isAccessibilitySupportEnabled(); + // Set Keyboard Config + windowConfiguration.isISOKeyboard = KeyboardLayoutMonitor.INSTANCE.isISOKeyboard(); + // Theme windowConfiguration.baseTheme = this.getBaseTheme(); windowConfiguration.backgroundColor = this.getBackgroundColor(); diff --git a/src/vs/code/electron-main/windows.ts b/src/vs/code/electron-main/windows.ts index 72d1091e196..b4324486c62 100644 --- a/src/vs/code/electron-main/windows.ts +++ b/src/vs/code/electron-main/windows.ts @@ -31,8 +31,7 @@ import product from 'vs/platform/node/product'; import { OpenContext } from 'vs/code/common/windows'; import { ITelemetryService, ITelemetryData } from 'vs/platform/telemetry/common/telemetry'; import { isParent, isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; -import * as nativeKeymap from 'native-keymap'; -import { IDisposable } from 'vs/base/common/lifecycle'; +import { KeyboardLayoutMonitor } from "vs/code/node/keyboard"; enum WindowError { UNRESPONSIVE, @@ -107,7 +106,6 @@ export interface IWindowsMainService { openFileFolderPicker(forceNewWindow?: boolean, data?: ITelemetryData): void; openFilePicker(forceNewWindow?: boolean, path?: string, window?: VSCodeWindow, data?: ITelemetryData): void; openFolderPicker(forceNewWindow?: boolean, window?: VSCodeWindow, data?: ITelemetryData): void; - openAccessibilityOptions(): void; focusLastActive(cli: ParsedArgs, context: OpenContext): VSCodeWindow; getLastActiveWindow(): VSCodeWindow; findWindow(workspacePath: string, filePath?: string, extensionDevelopmentPath?: string): VSCodeWindow; @@ -343,6 +341,7 @@ export class WindowsManager implements IWindowsMainService { } private onBroadcast(event: string, payload: any): void { + // Theme changes if (event === 'vscode:changeColorTheme' && typeof payload === 'string') { @@ -737,8 +736,6 @@ export class WindowsManager implements IWindowsMainService { configuration.filesToCreate = filesToCreate; configuration.filesToDiff = filesToDiff; configuration.nodeCachedDataDir = this.environmentService.nodeCachedDataDir; - configuration.isISOKeyboard = KeyboardLayoutMonitor.INSTANCE.isISOKeyboard(); - configuration.accessibilitySupportEnabled = app.isAccessibilitySupportEnabled(); return configuration; } @@ -1028,22 +1025,6 @@ export class WindowsManager implements IWindowsMainService { this.doPickAndOpen({ pickFolders: true, forceNewWindow, window }, 'openFolder', data); } - public openAccessibilityOptions(): void { - let win = new BrowserWindow({ - alwaysOnTop: true, - skipTaskbar: true, - resizable: false, - width: 450, - height: 300, - show: true, - title: nls.localize('accessibilityOptionsWindowTitle', "Accessibility Options") - }); - - win.setMenuBarVisibility(false); - - win.loadURL('chrome://accessibility'); - } - private doPickAndOpen(options: INativeOpenDialogOptions, eventName: string, data?: ITelemetryData): void { this.getFileOrFolderPaths(options, (paths: string[]) => { const nOfPaths = paths ? paths.length : 0; @@ -1338,63 +1319,4 @@ export class WindowsManager implements IWindowsMainService { }, 10 /* delay to unwind callback stack (IPC) */); } } -} - -class KeyboardLayoutMonitor { - - public static INSTANCE = new KeyboardLayoutMonitor(); - - private _emitter: Emitter; - private _registered: boolean; - private _isISOKeyboard: boolean; - - private constructor() { - this._emitter = new Emitter(); - this._registered = false; - this._isISOKeyboard = this._readIsISOKeyboard(); - } - - public onDidChangeKeyboardLayout(callback: (isISOKeyboard: boolean) => void): IDisposable { - if (!this._registered) { - this._registered = true; - - nativeKeymap.onDidChangeKeyboardLayout(() => { - this._emitter.fire(this._isISOKeyboard); - }); - - if (platform.isMacintosh) { - // See https://github.com/Microsoft/vscode/issues/24153 - // On OSX, on ISO keyboards, Chromium swaps the scan codes - // of IntlBackslash and Backquote. - // - // The C++ methods can give the current keyboard type (ISO or not) - // only after a NSEvent was handled. - // - // We therefore poll. - setInterval(() => { - let newValue = this._readIsISOKeyboard(); - if (this._isISOKeyboard === newValue) { - // no change - return; - } - - this._isISOKeyboard = newValue; - this._emitter.fire(this._isISOKeyboard); - - }, 3000); - } - } - return this._emitter.event(callback); - } - - private _readIsISOKeyboard(): boolean { - if (platform.isMacintosh) { - return nativeKeymap.isISOKeyboard(); - } - return false; - } - - public isISOKeyboard(): boolean { - return this._isISOKeyboard; - } -} +} \ No newline at end of file diff --git a/src/vs/code/node/keyboard.ts b/src/vs/code/node/keyboard.ts new file mode 100644 index 00000000000..d2f968371ef --- /dev/null +++ b/src/vs/code/node/keyboard.ts @@ -0,0 +1,70 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +'use strict'; + +import * as nativeKeymap from 'native-keymap'; +import { IDisposable } from 'vs/base/common/lifecycle'; +import { isMacintosh } from "vs/base/common/platform"; +import { Emitter } from "vs/base/common/event"; + +export class KeyboardLayoutMonitor { + + public static readonly INSTANCE = new KeyboardLayoutMonitor(); + + private _emitter: Emitter; + private _registered: boolean; + private _isISOKeyboard: boolean; + + private constructor() { + this._emitter = new Emitter(); + this._registered = false; + this._isISOKeyboard = this._readIsISOKeyboard(); + } + + public onDidChangeKeyboardLayout(callback: (isISOKeyboard: boolean) => void): IDisposable { + if (!this._registered) { + this._registered = true; + + nativeKeymap.onDidChangeKeyboardLayout(() => { + this._emitter.fire(this._isISOKeyboard); + }); + + if (isMacintosh) { + // See https://github.com/Microsoft/vscode/issues/24153 + // On OSX, on ISO keyboards, Chromium swaps the scan codes + // of IntlBackslash and Backquote. + // + // The C++ methods can give the current keyboard type (ISO or not) + // only after a NSEvent was handled. + // + // We therefore poll. + setInterval(() => { + let newValue = this._readIsISOKeyboard(); + if (this._isISOKeyboard === newValue) { + // no change + return; + } + + this._isISOKeyboard = newValue; + this._emitter.fire(this._isISOKeyboard); + + }, 3000); + } + } + return this._emitter.event(callback); + } + + private _readIsISOKeyboard(): boolean { + if (isMacintosh) { + return nativeKeymap.isISOKeyboard(); + } + return false; + } + + public isISOKeyboard(): boolean { + return this._isISOKeyboard; + } +} diff --git a/src/vs/workbench/electron-browser/main.ts b/src/vs/workbench/electron-browser/main.ts index fb179f3196c..b20a6fd422a 100644 --- a/src/vs/workbench/electron-browser/main.ts +++ b/src/vs/workbench/electron-browser/main.ts @@ -42,10 +42,7 @@ export interface IWindowConfiguration extends ParsedArgs, IOpenFileRequest { */ isISOKeyboard?: boolean; - /** - * Accessibility support is enabled. - */ - accessibilitySupportEnabled?: boolean; + accessibilitySupport?: boolean; appRoot: string; execPath: string; @@ -62,15 +59,16 @@ export function startup(configuration: IWindowConfiguration): TPromise { // Ensure others can listen to zoom level changes browser.setZoomFactor(webFrame.getZoomFactor()); + // See https://github.com/Microsoft/vscode/issues/26151 // Can be trusted because we are not setting it ourselves. - browser.setZoomLevel(webFrame.getZoomLevel(), /*isTrusted*/true); + browser.setZoomLevel(webFrame.getZoomLevel(), true /* isTrusted */); browser.setFullscreen(!!configuration.fullscreen); KeyboardMapperFactory.INSTANCE._onKeyboardLayoutChanged(configuration.isISOKeyboard); - browser.setAccessibilitySupport(configuration.accessibilitySupportEnabled ? platform.AccessibilitySupport.Enabled : platform.AccessibilitySupport.Disabled); + browser.setAccessibilitySupport(configuration.accessibilitySupport ? platform.AccessibilitySupport.Enabled : platform.AccessibilitySupport.Disabled); // Setup Intl comparer.setFileNameComparer(new Intl.Collator(undefined, { numeric: true, sensitivity: 'base' })); -- GitLab From a9486e406f22836b9ca6fac6c113ea9116f70cbc Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 25 May 2017 09:53:23 +0200 Subject: [PATCH 0143/1347] linting: convert double quote imports to single quote --- extensions/typescript/src/utils/logger.ts | 2 +- extensions/typescript/src/utils/plugins.ts | 2 +- extensions/typescript/src/utils/telemetry.ts | 2 +- src/vs/base/browser/ui/countBadge/countBadge.ts | 4 ++-- .../base/browser/ui/progressbar/progressbar.ts | 4 ++-- src/vs/base/test/common/json.test.ts | 2 +- src/vs/code/electron-main/window.ts | 2 +- src/vs/code/electron-main/windows.ts | 2 +- src/vs/code/node/keyboard.ts | 4 ++-- .../editor/browser/controller/textAreaHandler.ts | 12 ++++++------ .../editor/browser/controller/textAreaInput.ts | 4 ++-- src/vs/editor/browser/view/viewController.ts | 2 +- src/vs/editor/browser/view/viewImpl.ts | 2 +- .../viewParts/editorScrollbar/editorScrollbar.ts | 2 +- .../editor/browser/viewParts/minimap/minimap.ts | 4 ++-- .../scrollDecoration/scrollDecoration.ts | 4 ++-- src/vs/editor/browser/widget/diffEditorWidget.ts | 2 +- src/vs/editor/common/commonCodeEditor.ts | 4 ++-- src/vs/editor/common/config/fontInfo.ts | 2 +- src/vs/editor/common/controller/accGenerator.ts | 2 +- src/vs/editor/common/controller/coreCommands.ts | 6 +++--- src/vs/editor/common/controller/cursor.ts | 2 +- src/vs/editor/common/controller/cursorCommon.ts | 2 +- .../common/controller/cursorDeleteOperations.ts | 2 +- .../common/controller/cursorTypeOperations.ts | 2 +- .../common/controller/cursorWordOperations.ts | 2 +- src/vs/editor/common/model/textModel.ts | 2 +- src/vs/editor/common/model/textModelSearch.ts | 2 +- .../editor/common/services/modelServiceImpl.ts | 2 +- src/vs/editor/common/standalone/themes.ts | 4 ++-- src/vs/editor/common/view/viewEvents.ts | 2 +- src/vs/editor/common/viewLayout/viewLayout.ts | 2 +- .../common/viewModel/splitLinesCollection.ts | 2 +- src/vs/editor/common/viewModel/viewModel.ts | 6 +++--- src/vs/editor/common/viewModel/viewModelImpl.ts | 2 +- .../bracketMatching/common/bracketMatching.ts | 6 +++--- .../editor/contrib/codelens/browser/codelens.ts | 8 ++++---- .../test/common/lineCommentCommand.test.ts | 6 +++--- src/vs/editor/contrib/dnd/browser/dnd.ts | 2 +- .../editor/contrib/find/common/findController.ts | 2 +- .../contrib/find/common/findDecorations.ts | 2 +- .../contrib/folding/common/foldingModel.ts | 2 +- .../browser/goToDeclarationMouse.ts | 2 +- .../contrib/hover/browser/modesContentHover.ts | 2 +- .../inPlaceReplace/common/inPlaceReplace.ts | 2 +- .../linesOperations/common/linesOperations.ts | 2 +- .../test/common/linesOperations.test.ts | 6 +++--- src/vs/editor/contrib/links/browser/links.ts | 4 ++-- .../contrib/quickOpen/browser/editorQuickOpen.ts | 2 +- .../referenceSearch/browser/referencesWidget.ts | 4 ++-- .../contrib/snippet/browser/snippetSession.ts | 2 +- .../test/browser/snippetController2.old.test.ts | 4 ++-- .../test/browser/snippetController2.test.ts | 2 +- .../snippet/test/browser/snippetSession.test.ts | 2 +- .../wordHighlighter/common/wordHighlighter.ts | 2 +- .../wordOperations/common/wordOperations.ts | 6 +++--- .../test/common/wordOperations.test.ts | 2 +- .../contrib/zoneWidget/browser/zoneWidget.ts | 2 +- src/vs/editor/editor.main.ts | 2 +- .../browser/controller/textAreaState.test.ts | 2 +- .../test/common/commands/commandTestUtils.ts | 2 +- .../test/common/commands/sideEditing.test.ts | 2 +- .../common/config/commonEditorConfig.test.ts | 4 ++-- .../editor/test/common/controller/cursor.test.ts | 10 +++++----- .../common/controller/cursorMoveCommand.test.ts | 2 +- .../test/common/mocks/testConfiguration.ts | 2 +- .../test/common/model/textModelSearch.test.ts | 4 ++-- src/vs/workbench/browser/parts/compositePart.ts | 2 +- .../browser/parts/editor/editorGroupsControl.ts | 2 +- .../browser/parts/editor/webviewEditor.ts | 8 ++++---- .../browser/parts/statusbar/statusbarPart.ts | 2 +- .../workbench/common/editor/rangeDecorations.ts | 2 +- src/vs/workbench/electron-browser/workbench.ts | 8 ++++---- src/vs/workbench/node/extensionPoints.ts | 2 +- .../parts/debug/browser/debugActionItems.ts | 2 +- .../parts/debug/browser/exceptionWidget.ts | 6 +++--- .../electron-browser/debugEditorContribution.ts | 2 +- .../parts/debug/electron-browser/debugHover.ts | 2 +- .../electron-browser/statusbarColorProvider.ts | 2 +- .../actions/expandAbbreviation.ts | 2 +- .../emmet/electron-browser/editorAccessor.ts | 2 +- .../extensions/browser/extensionsActions.ts | 6 +++--- .../parts/feedback/electron-browser/feedback.ts | 6 +++--- .../electron-browser/feedbackStatusbarItem.ts | 2 +- .../parts/files/browser/views/openEditorsView.ts | 2 +- .../parts/markers/browser/markersTreeViewer.ts | 6 +++--- .../preferences/browser/keybindingWidgets.ts | 2 +- .../preferences/browser/keybindingsEditor.ts | 2 +- .../preferences/browser/preferencesEditor.ts | 4 ++-- .../preferences/browser/preferencesRenderers.ts | 2 +- .../preferences/browser/preferencesWidgets.ts | 2 +- .../parts/quickopen/browser/commandsHandler.ts | 2 +- .../scm/electron-browser/dirtydiffDecorator.ts | 10 +++++----- .../parts/search/browser/openFileHandler.ts | 2 +- .../parts/search/browser/searchResultsView.ts | 4 ++-- .../parts/search/browser/searchViewlet.ts | 2 +- src/vs/workbench/parts/search/common/search.ts | 8 ++++---- .../workbench/parts/search/common/searchModel.ts | 2 +- .../snippets/electron-browser/TMSnippets.ts | 2 +- .../electron-browser/terminal.contribution.ts | 2 +- .../electron-browser/terminalConfigHelper.ts | 2 +- .../electron-browser/terminalInstance.ts | 4 ++-- .../terminalConfigHelper.test.ts | 2 +- .../electron-browser/releaseNotesEditor.ts | 2 +- .../editor/test/browser/editorService.test.ts | 2 +- .../themes/electron-browser/colorThemeData.ts | 2 +- .../electron-browser/workbenchThemeService.ts | 2 +- .../test/browser/parts/editor/baseEditor.test.ts | 2 +- .../test/common/editor/editorDiffModel.test.ts | 16 ++++++++-------- 109 files changed, 177 insertions(+), 177 deletions(-) diff --git a/extensions/typescript/src/utils/logger.ts b/extensions/typescript/src/utils/logger.ts index 7f82fb28c96..8e31d66d858 100644 --- a/extensions/typescript/src/utils/logger.ts +++ b/extensions/typescript/src/utils/logger.ts @@ -3,7 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import { OutputChannel, window } from "vscode"; +import { OutputChannel, window } from 'vscode'; import * as is from './is'; import * as nls from 'vscode-nls'; diff --git a/extensions/typescript/src/utils/plugins.ts b/extensions/typescript/src/utils/plugins.ts index 49f0d93b4b6..23342cc8b31 100644 --- a/extensions/typescript/src/utils/plugins.ts +++ b/extensions/typescript/src/utils/plugins.ts @@ -3,7 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import { extensions } from "vscode"; +import { extensions } from 'vscode'; export interface TypeScriptServerPlugin { diff --git a/extensions/typescript/src/utils/telemetry.ts b/extensions/typescript/src/utils/telemetry.ts index 5162a0c24d5..b687b11b4ac 100644 --- a/extensions/typescript/src/utils/telemetry.ts +++ b/extensions/typescript/src/utils/telemetry.ts @@ -5,7 +5,7 @@ import * as path from 'path'; import VsCodeTelemetryReporter from 'vscode-extension-telemetry'; -import { Disposable } from "vscode"; +import { Disposable } from 'vscode'; interface IPackageInfo { diff --git a/src/vs/base/browser/ui/countBadge/countBadge.ts b/src/vs/base/browser/ui/countBadge/countBadge.ts index a7fa56efce8..8ff58693925 100644 --- a/src/vs/base/browser/ui/countBadge/countBadge.ts +++ b/src/vs/base/browser/ui/countBadge/countBadge.ts @@ -8,8 +8,8 @@ import 'vs/css!./countBadge'; import { $, append } from 'vs/base/browser/dom'; import { format } from 'vs/base/common/strings'; -import { Color } from "vs/base/common/color"; -import { mixin } from "vs/base/common/objects"; +import { Color } from 'vs/base/common/color'; +import { mixin } from 'vs/base/common/objects'; export interface ICountBadgeOptions extends ICountBadgetyles { count?: number; diff --git a/src/vs/base/browser/ui/progressbar/progressbar.ts b/src/vs/base/browser/ui/progressbar/progressbar.ts index 1287112824b..ea34e06e1cb 100644 --- a/src/vs/base/browser/ui/progressbar/progressbar.ts +++ b/src/vs/base/browser/ui/progressbar/progressbar.ts @@ -11,8 +11,8 @@ import assert = require('vs/base/common/assert'); import { Builder, $ } from 'vs/base/browser/builder'; import DOM = require('vs/base/browser/dom'); import { IDisposable, dispose } from 'vs/base/common/lifecycle'; -import { Color } from "vs/base/common/color"; -import { mixin } from "vs/base/common/objects"; +import { Color } from 'vs/base/common/color'; +import { mixin } from 'vs/base/common/objects'; const css_done = 'done'; const css_active = 'active'; diff --git a/src/vs/base/test/common/json.test.ts b/src/vs/base/test/common/json.test.ts index 42a0804c113..fe129f08808 100644 --- a/src/vs/base/test/common/json.test.ts +++ b/src/vs/base/test/common/json.test.ts @@ -8,7 +8,7 @@ import * as assert from 'assert'; import { SyntaxKind, createScanner, parse, getLocation, Node, ParseError, parseTree, ParseErrorCode, ParseOptions, Segment, findNodeAtLocation, getNodeValue, ScanError } from 'vs/base/common/json'; -import { getParseErrorMessage } from "vs/base/common/jsonErrorMessages"; +import { getParseErrorMessage } from 'vs/base/common/jsonErrorMessages'; function assertKinds(text: string, ...kinds: SyntaxKind[]): void { var scanner = createScanner(text); diff --git a/src/vs/code/electron-main/window.ts b/src/vs/code/electron-main/window.ts index 4b1840c8642..91d560b50fd 100644 --- a/src/vs/code/electron-main/window.ts +++ b/src/vs/code/electron-main/window.ts @@ -22,7 +22,7 @@ import product from 'vs/platform/node/product'; import { getCommonHTTPHeaders } from 'vs/platform/environment/node/http'; import { IWindowSettings, MenuBarVisibility } from 'vs/platform/windows/common/windows'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; -import { KeyboardLayoutMonitor } from "vs/code/node/keyboard"; +import { KeyboardLayoutMonitor } from 'vs/code/node/keyboard'; export interface IWindowState { width?: number; diff --git a/src/vs/code/electron-main/windows.ts b/src/vs/code/electron-main/windows.ts index b4324486c62..cc0800f25e6 100644 --- a/src/vs/code/electron-main/windows.ts +++ b/src/vs/code/electron-main/windows.ts @@ -31,7 +31,7 @@ import product from 'vs/platform/node/product'; import { OpenContext } from 'vs/code/common/windows'; import { ITelemetryService, ITelemetryData } from 'vs/platform/telemetry/common/telemetry'; import { isParent, isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; -import { KeyboardLayoutMonitor } from "vs/code/node/keyboard"; +import { KeyboardLayoutMonitor } from 'vs/code/node/keyboard'; enum WindowError { UNRESPONSIVE, diff --git a/src/vs/code/node/keyboard.ts b/src/vs/code/node/keyboard.ts index d2f968371ef..16979fc90c0 100644 --- a/src/vs/code/node/keyboard.ts +++ b/src/vs/code/node/keyboard.ts @@ -7,8 +7,8 @@ import * as nativeKeymap from 'native-keymap'; import { IDisposable } from 'vs/base/common/lifecycle'; -import { isMacintosh } from "vs/base/common/platform"; -import { Emitter } from "vs/base/common/event"; +import { isMacintosh } from 'vs/base/common/platform'; +import { Emitter } from 'vs/base/common/event'; export class KeyboardLayoutMonitor { diff --git a/src/vs/editor/browser/controller/textAreaHandler.ts b/src/vs/editor/browser/controller/textAreaHandler.ts index f9ae737307e..e927fcb4ab1 100644 --- a/src/vs/editor/browser/controller/textAreaHandler.ts +++ b/src/vs/editor/browser/controller/textAreaHandler.ts @@ -18,12 +18,12 @@ import { HorizontalRange, RenderingContext, RestrictedRenderingContext } from 'v import * as viewEvents from 'vs/editor/common/view/viewEvents'; import { FastDomNode, createFastDomNode } from 'vs/base/browser/fastDomNode'; import { ViewController } from 'vs/editor/browser/view/viewController'; -import { EndOfLinePreference } from "vs/editor/common/editorCommon"; -import { IKeyboardEvent } from "vs/base/browser/keyboardEvent"; -import { PartFingerprints, PartFingerprint, ViewPart } from "vs/editor/browser/view/viewPart"; -import { Margin } from "vs/editor/browser/viewParts/margin/margin"; -import { LineNumbersOverlay } from "vs/editor/browser/viewParts/lineNumbers/lineNumbers"; -import { BareFontInfo } from "vs/editor/common/config/fontInfo"; +import { EndOfLinePreference } from 'vs/editor/common/editorCommon'; +import { IKeyboardEvent } from 'vs/base/browser/keyboardEvent'; +import { PartFingerprints, PartFingerprint, ViewPart } from 'vs/editor/browser/view/viewPart'; +import { Margin } from 'vs/editor/browser/viewParts/margin/margin'; +import { LineNumbersOverlay } from 'vs/editor/browser/viewParts/lineNumbers/lineNumbers'; +import { BareFontInfo } from 'vs/editor/common/config/fontInfo'; export interface ITextAreaHandlerHelper { visibleRangeForPositionRelativeToEditor(lineNumber: number, column: number): HorizontalRange; diff --git a/src/vs/editor/browser/controller/textAreaInput.ts b/src/vs/editor/browser/controller/textAreaInput.ts index 757bbf1dd41..e1f99b036e8 100644 --- a/src/vs/editor/browser/controller/textAreaInput.ts +++ b/src/vs/editor/browser/controller/textAreaInput.ts @@ -13,8 +13,8 @@ import { ITypeData, TextAreaState, ITextAreaWrapper } from 'vs/editor/browser/co import * as browser from 'vs/base/browser/browser'; import * as platform from 'vs/base/common/platform'; import * as dom from 'vs/base/browser/dom'; -import { IKeyboardEvent } from "vs/base/browser/keyboardEvent"; -import { FastDomNode } from "vs/base/browser/fastDomNode"; +import { IKeyboardEvent } from 'vs/base/browser/keyboardEvent'; +import { FastDomNode } from 'vs/base/browser/fastDomNode'; export interface ICompositionData { data: string; diff --git a/src/vs/editor/browser/view/viewController.ts b/src/vs/editor/browser/view/viewController.ts index e05ca74ea60..51beeeade27 100644 --- a/src/vs/editor/browser/view/viewController.ts +++ b/src/vs/editor/browser/view/viewController.ts @@ -12,7 +12,7 @@ import { ICommandService } from 'vs/platform/commands/common/commands'; import { IViewModel } from 'vs/editor/common/viewModel/viewModel'; import { ViewOutgoingEvents } from 'vs/editor/browser/view/viewOutgoingEvents'; import { CoreNavigationCommands, CoreEditorCommand } from 'vs/editor/common/controller/coreCommands'; -import { Configuration } from "vs/editor/browser/config/configuration"; +import { Configuration } from 'vs/editor/browser/config/configuration'; export interface ExecCoreEditorCommandFunc { (editorCommand: CoreEditorCommand, args: any): void; diff --git a/src/vs/editor/browser/view/viewImpl.ts b/src/vs/editor/browser/view/viewImpl.ts index 927c1d19486..2ac56ac2773 100644 --- a/src/vs/editor/browser/view/viewImpl.ts +++ b/src/vs/editor/browser/view/viewImpl.ts @@ -48,7 +48,7 @@ import { EditorScrollbar } from 'vs/editor/browser/viewParts/editorScrollbar/edi import { Minimap } from 'vs/editor/browser/viewParts/minimap/minimap'; import * as viewEvents from 'vs/editor/common/view/viewEvents'; import { IThemeService, getThemeTypeSelector } from 'vs/platform/theme/common/themeService'; -import { Cursor } from "vs/editor/common/controller/cursor"; +import { Cursor } from 'vs/editor/common/controller/cursor'; export interface IContentWidgetData { widget: editorBrowser.IContentWidget; diff --git a/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.ts b/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.ts index 11d53265128..89aee09559d 100644 --- a/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.ts +++ b/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.ts @@ -13,7 +13,7 @@ import { ViewContext } from 'vs/editor/common/view/viewContext'; import * as viewEvents from 'vs/editor/common/view/viewEvents'; import { RenderingContext, RestrictedRenderingContext } from 'vs/editor/common/view/renderingContext'; import { FastDomNode, createFastDomNode } from 'vs/base/browser/fastDomNode'; -import { getThemeTypeSelector } from "vs/platform/theme/common/themeService"; +import { getThemeTypeSelector } from 'vs/platform/theme/common/themeService'; export class EditorScrollbar extends ViewPart { diff --git a/src/vs/editor/browser/viewParts/minimap/minimap.ts b/src/vs/editor/browser/viewParts/minimap/minimap.ts index 9c922137ede..46d8dde55d5 100644 --- a/src/vs/editor/browser/viewParts/minimap/minimap.ts +++ b/src/vs/editor/browser/viewParts/minimap/minimap.ts @@ -25,8 +25,8 @@ import { RGBA } from 'vs/base/common/color'; import * as viewEvents from 'vs/editor/common/view/viewEvents'; import { GlobalMouseMoveMonitor, IStandardMouseMoveEventData, standardMouseMoveMerger } from 'vs/base/browser/globalMouseMoveMonitor'; import * as platform from 'vs/base/common/platform'; -import { registerThemingParticipant } from "vs/platform/theme/common/themeService"; -import { scrollbarSliderBackground, scrollbarSliderHoverBackground, scrollbarSliderActiveBackground, scrollbarShadow } from "vs/platform/theme/common/colorRegistry"; +import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; +import { scrollbarSliderBackground, scrollbarSliderHoverBackground, scrollbarSliderActiveBackground, scrollbarShadow } from 'vs/platform/theme/common/colorRegistry'; const enum RenderMinimap { None = 0, diff --git a/src/vs/editor/browser/viewParts/scrollDecoration/scrollDecoration.ts b/src/vs/editor/browser/viewParts/scrollDecoration/scrollDecoration.ts index 92134f722a1..e4086a1e00a 100644 --- a/src/vs/editor/browser/viewParts/scrollDecoration/scrollDecoration.ts +++ b/src/vs/editor/browser/viewParts/scrollDecoration/scrollDecoration.ts @@ -11,8 +11,8 @@ import { ViewPart } from 'vs/editor/browser/view/viewPart'; import { ViewContext } from 'vs/editor/common/view/viewContext'; import { RenderingContext, RestrictedRenderingContext } from 'vs/editor/common/view/renderingContext'; import * as viewEvents from 'vs/editor/common/view/viewEvents'; -import { registerThemingParticipant } from "vs/platform/theme/common/themeService"; -import { scrollbarShadow } from "vs/platform/theme/common/colorRegistry"; +import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; +import { scrollbarShadow } from 'vs/platform/theme/common/colorRegistry'; export class ScrollDecorationViewPart extends ViewPart { diff --git a/src/vs/editor/browser/widget/diffEditorWidget.ts b/src/vs/editor/browser/widget/diffEditorWidget.ts index c655b958451..556c843ce15 100644 --- a/src/vs/editor/browser/widget/diffEditorWidget.ts +++ b/src/vs/editor/browser/widget/diffEditorWidget.ts @@ -36,7 +36,7 @@ import { scrollbarShadow, diffInserted, diffRemoved, defaultInsertColor, default import { Color } from 'vs/base/common/color'; import { OverviewRulerZone } from 'vs/editor/common/view/overviewZoneManager'; import { IEditorWhitespace } from 'vs/editor/common/viewLayout/whitespaceComputer'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; interface IEditorDiffDecorations { decorations: editorCommon.IModelDeltaDecoration[]; diff --git a/src/vs/editor/common/commonCodeEditor.ts b/src/vs/editor/common/commonCodeEditor.ts index d8b808d3f06..c5285a83724 100644 --- a/src/vs/editor/common/commonCodeEditor.ts +++ b/src/vs/editor/common/commonCodeEditor.ts @@ -28,8 +28,8 @@ import { import * as editorOptions from 'vs/editor/common/config/editorOptions'; import { ICursorPositionChangedEvent, ICursorSelectionChangedEvent } from 'vs/editor/common/controller/cursorEvents'; import { EditorContextKeys } from 'vs/editor/common/editorContextKeys'; -import { CommonEditorRegistry } from "vs/editor/common/editorCommonExtensions"; -import { VerticalRevealType } from "vs/editor/common/view/viewEvents"; +import { CommonEditorRegistry } from 'vs/editor/common/editorCommonExtensions'; +import { VerticalRevealType } from 'vs/editor/common/view/viewEvents'; let EDITOR_ID = 0; diff --git a/src/vs/editor/common/config/fontInfo.ts b/src/vs/editor/common/config/fontInfo.ts index 7740776bebf..9ab9a11d2a9 100644 --- a/src/vs/editor/common/config/fontInfo.ts +++ b/src/vs/editor/common/config/fontInfo.ts @@ -6,7 +6,7 @@ import * as platform from 'vs/base/common/platform'; import { EditorZoom } from 'vs/editor/common/config/editorZoom'; -import { EDITOR_FONT_DEFAULTS } from "vs/editor/common/config/editorOptions"; +import { EDITOR_FONT_DEFAULTS } from 'vs/editor/common/config/editorOptions'; /** * Determined from empirical observations. diff --git a/src/vs/editor/common/controller/accGenerator.ts b/src/vs/editor/common/controller/accGenerator.ts index 6f6bb813e6b..ca556f79d2d 100644 --- a/src/vs/editor/common/controller/accGenerator.ts +++ b/src/vs/editor/common/controller/accGenerator.ts @@ -8,7 +8,7 @@ import { Position } from 'vs/editor/common/core/position'; import * as nls from 'vs/nls'; import { Range } from 'vs/editor/common/core/range'; -import { IModel } from "vs/editor/common/editorCommon"; +import { IModel } from 'vs/editor/common/editorCommon'; import { Selection } from 'vs/editor/common/core/selection'; export class ScreenReaderMessageGenerator { diff --git a/src/vs/editor/common/controller/coreCommands.ts b/src/vs/editor/common/controller/coreCommands.ts index 639022470cd..e0a3cd88f63 100644 --- a/src/vs/editor/common/controller/coreCommands.ts +++ b/src/vs/editor/common/controller/coreCommands.ts @@ -23,9 +23,9 @@ import { ContextKeyExpr } from 'vs/platform/contextkey/common/contextkey'; import * as types from 'vs/base/common/types'; import { ICommandHandlerDescription } from 'vs/platform/commands/common/commands'; import { IEditorService } from 'vs/platform/editor/common/editor'; -import { TypeOperations } from "vs/editor/common/controller/cursorTypeOperations"; -import { DeleteOperations } from "vs/editor/common/controller/cursorDeleteOperations"; -import { VerticalRevealType } from "vs/editor/common/view/viewEvents"; +import { TypeOperations } from 'vs/editor/common/controller/cursorTypeOperations'; +import { DeleteOperations } from 'vs/editor/common/controller/cursorDeleteOperations'; +import { VerticalRevealType } from 'vs/editor/common/view/viewEvents'; const CORE_WEIGHT = KeybindingsRegistry.WEIGHT.editorCore(); diff --git a/src/vs/editor/common/controller/cursor.ts b/src/vs/editor/common/controller/cursor.ts index 305894d79b6..0c203347cce 100644 --- a/src/vs/editor/common/controller/cursor.ts +++ b/src/vs/editor/common/controller/cursor.ts @@ -18,7 +18,7 @@ import { DeleteOperations } from 'vs/editor/common/controller/cursorDeleteOperat import { TypeOperations } from 'vs/editor/common/controller/cursorTypeOperations'; import { TextModelEventType, ModelRawContentChangedEvent, RawContentChangedType } from 'vs/editor/common/model/textModelEvents'; import { CursorChangeReason } from 'vs/editor/common/controller/cursorEvents'; -import { IViewModel } from "vs/editor/common/viewModel/viewModel"; +import { IViewModel } from 'vs/editor/common/viewModel/viewModel'; import * as viewEvents from 'vs/editor/common/view/viewEvents'; import Event, { Emitter } from 'vs/base/common/event'; // import { ScreenReaderMessageGenerator } from "vs/editor/common/controller/accGenerator"; diff --git a/src/vs/editor/common/controller/cursorCommon.ts b/src/vs/editor/common/controller/cursorCommon.ts index e82708d17da..55e00ad1e43 100644 --- a/src/vs/editor/common/controller/cursorCommon.ts +++ b/src/vs/editor/common/controller/cursorCommon.ts @@ -18,7 +18,7 @@ import { IAutoClosingPair } from 'vs/editor/common/modes/languageConfiguration'; import { IConfigurationChangedEvent } from 'vs/editor/common/config/editorOptions'; import { IViewModel } from 'vs/editor/common/viewModel/viewModel'; import { CursorChangeReason } from 'vs/editor/common/controller/cursorEvents'; -import { VerticalRevealType } from "vs/editor/common/view/viewEvents"; +import { VerticalRevealType } from 'vs/editor/common/view/viewEvents'; export interface IColumnSelectData { toViewLineNumber: number; diff --git a/src/vs/editor/common/controller/cursorDeleteOperations.ts b/src/vs/editor/common/controller/cursorDeleteOperations.ts index c968bb49f76..7951ab91b83 100644 --- a/src/vs/editor/common/controller/cursorDeleteOperations.ts +++ b/src/vs/editor/common/controller/cursorDeleteOperations.ts @@ -10,7 +10,7 @@ import { Range } from 'vs/editor/common/core/range'; import { Selection } from 'vs/editor/common/core/selection'; import { MoveOperations } from 'vs/editor/common/controller/cursorMoveOperations'; import * as strings from 'vs/base/common/strings'; -import { ICommand } from "vs/editor/common/editorCommon"; +import { ICommand } from 'vs/editor/common/editorCommon'; export class DeleteOperations { diff --git a/src/vs/editor/common/controller/cursorTypeOperations.ts b/src/vs/editor/common/controller/cursorTypeOperations.ts index cb2b2184669..6abac0a543e 100644 --- a/src/vs/editor/common/controller/cursorTypeOperations.ts +++ b/src/vs/editor/common/controller/cursorTypeOperations.ts @@ -16,7 +16,7 @@ import { LanguageConfigurationRegistry } from 'vs/editor/common/modes/languageCo import { IndentAction } from 'vs/editor/common/modes/languageConfiguration'; import { SurroundSelectionCommand } from 'vs/editor/common/commands/surroundSelectionCommand'; import { IElectricAction } from 'vs/editor/common/modes/supports/electricCharacter'; -import { getMapForWordSeparators, WordCharacterClass } from "vs/editor/common/controller/wordCharacterClassifier"; +import { getMapForWordSeparators, WordCharacterClass } from 'vs/editor/common/controller/wordCharacterClassifier'; export class TypeOperations { diff --git a/src/vs/editor/common/controller/cursorWordOperations.ts b/src/vs/editor/common/controller/cursorWordOperations.ts index 305cfe68392..3666961a2a2 100644 --- a/src/vs/editor/common/controller/cursorWordOperations.ts +++ b/src/vs/editor/common/controller/cursorWordOperations.ts @@ -6,7 +6,7 @@ import { SingleCursorState, CursorConfiguration, ICursorSimpleModel } from 'vs/editor/common/controller/cursorCommon'; import { Position } from 'vs/editor/common/core/position'; -import { WordCharacterClassifier, WordCharacterClass, getMapForWordSeparators } from "vs/editor/common/controller/wordCharacterClassifier"; +import { WordCharacterClassifier, WordCharacterClass, getMapForWordSeparators } from 'vs/editor/common/controller/wordCharacterClassifier'; import * as strings from 'vs/base/common/strings'; import { Range } from 'vs/editor/common/core/range'; import { Selection } from 'vs/editor/common/core/selection'; diff --git a/src/vs/editor/common/model/textModel.ts b/src/vs/editor/common/model/textModel.ts index 0d7ec1065b4..d15842430f3 100644 --- a/src/vs/editor/common/model/textModel.ts +++ b/src/vs/editor/common/model/textModel.ts @@ -11,7 +11,7 @@ import { Range, IRange } from 'vs/editor/common/core/range'; import * as editorCommon from 'vs/editor/common/editorCommon'; import { ModelLine } from 'vs/editor/common/model/modelLine'; import { guessIndentation } from 'vs/editor/common/model/indentationGuesser'; -import { EDITOR_MODEL_DEFAULTS } from "vs/editor/common/config/editorOptions"; +import { EDITOR_MODEL_DEFAULTS } from 'vs/editor/common/config/editorOptions'; import { PrefixSumComputer } from 'vs/editor/common/viewModel/prefixSumComputer'; import { IndentRange, computeRanges } from 'vs/editor/common/model/indentRanges'; import { TextModelSearch, SearchParams } from 'vs/editor/common/model/textModelSearch'; diff --git a/src/vs/editor/common/model/textModelSearch.ts b/src/vs/editor/common/model/textModelSearch.ts index d19ad9e608c..af265935776 100644 --- a/src/vs/editor/common/model/textModelSearch.ts +++ b/src/vs/editor/common/model/textModelSearch.ts @@ -10,7 +10,7 @@ import { Range } from 'vs/editor/common/core/range'; import { FindMatch, EndOfLinePreference } from 'vs/editor/common/editorCommon'; import { CharCode } from 'vs/base/common/charCode'; import { TextModel } from 'vs/editor/common/model/textModel'; -import { getMapForWordSeparators, WordCharacterClassifier, WordCharacterClass } from "vs/editor/common/controller/wordCharacterClassifier"; +import { getMapForWordSeparators, WordCharacterClassifier, WordCharacterClass } from 'vs/editor/common/controller/wordCharacterClassifier'; const LIMIT_FIND_COUNT = 999; diff --git a/src/vs/editor/common/services/modelServiceImpl.ts b/src/vs/editor/common/services/modelServiceImpl.ts index 5fee6ded32a..5bcb68eba4b 100644 --- a/src/vs/editor/common/services/modelServiceImpl.ts +++ b/src/vs/editor/common/services/modelServiceImpl.ts @@ -21,7 +21,7 @@ import { IMode, LanguageIdentifier } from 'vs/editor/common/modes'; import { IModelService } from 'vs/editor/common/services/modelService'; import * as platform from 'vs/base/common/platform'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { EDITOR_MODEL_DEFAULTS } from "vs/editor/common/config/editorOptions"; +import { EDITOR_MODEL_DEFAULTS } from 'vs/editor/common/config/editorOptions'; import { PLAINTEXT_LANGUAGE_IDENTIFIER } from 'vs/editor/common/modes/modesRegistry'; import { IRawTextSource, TextSource, RawTextSource } from 'vs/editor/common/model/textSource'; import * as textModelEvents from 'vs/editor/common/model/textModelEvents'; diff --git a/src/vs/editor/common/standalone/themes.ts b/src/vs/editor/common/standalone/themes.ts index a97a9fab1ee..8093472bba8 100644 --- a/src/vs/editor/common/standalone/themes.ts +++ b/src/vs/editor/common/standalone/themes.ts @@ -6,8 +6,8 @@ 'use strict'; import { IStandaloneThemeData } from 'vs/editor/common/services/standaloneThemeService'; -import { editorBackground, editorForeground, editorSelectionHighlight, editorInactiveSelection } from "vs/platform/theme/common/colorRegistry"; -import { editorIndentGuides } from "vs/editor/common/view/editorColorRegistry"; +import { editorBackground, editorForeground, editorSelectionHighlight, editorInactiveSelection } from 'vs/platform/theme/common/colorRegistry'; +import { editorIndentGuides } from 'vs/editor/common/view/editorColorRegistry'; /* -------------------------------- Begin vs theme -------------------------------- */ export const vs: IStandaloneThemeData = { diff --git a/src/vs/editor/common/view/viewEvents.ts b/src/vs/editor/common/view/viewEvents.ts index f6696746fbf..72fc6b41fbe 100644 --- a/src/vs/editor/common/view/viewEvents.ts +++ b/src/vs/editor/common/view/viewEvents.ts @@ -9,7 +9,7 @@ import { Selection } from 'vs/editor/common/core/selection'; import { ScrollEvent } from 'vs/base/common/scrollable'; import { IConfigurationChangedEvent } from 'vs/editor/common/config/editorOptions'; import * as errors from 'vs/base/common/errors'; -import { IDisposable, Disposable } from "vs/base/common/lifecycle"; +import { IDisposable, Disposable } from 'vs/base/common/lifecycle'; export const enum ViewEventType { ViewConfigurationChanged = 1, diff --git a/src/vs/editor/common/viewLayout/viewLayout.ts b/src/vs/editor/common/viewLayout/viewLayout.ts index e6a9d763d29..4af8cbd5235 100644 --- a/src/vs/editor/common/viewLayout/viewLayout.ts +++ b/src/vs/editor/common/viewLayout/viewLayout.ts @@ -12,7 +12,7 @@ import { IViewLayout, IViewWhitespaceViewportData, Viewport } from 'vs/editor/co import { IPartialViewLinesViewportData } from 'vs/editor/common/viewLayout/viewLinesViewportData'; import { IEditorWhitespace } from 'vs/editor/common/viewLayout/whitespaceComputer'; import Event from 'vs/base/common/event'; -import { IConfigurationChangedEvent } from "vs/editor/common/config/editorOptions"; +import { IConfigurationChangedEvent } from 'vs/editor/common/config/editorOptions'; export class ViewLayout extends Disposable implements IViewLayout { diff --git a/src/vs/editor/common/viewModel/splitLinesCollection.ts b/src/vs/editor/common/viewModel/splitLinesCollection.ts index 72caeb160e8..7c40b262f09 100644 --- a/src/vs/editor/common/viewModel/splitLinesCollection.ts +++ b/src/vs/editor/common/viewModel/splitLinesCollection.ts @@ -12,7 +12,7 @@ import { PrefixSumComputerWithCache } from 'vs/editor/common/viewModel/prefixSum import { ViewLineData } from 'vs/editor/common/viewModel/viewModel'; import * as viewEvents from 'vs/editor/common/view/viewEvents'; import { WrappingIndent } from 'vs/editor/common/config/editorOptions'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export class OutputPosition { _outputPositionBrand: void; diff --git a/src/vs/editor/common/viewModel/viewModel.ts b/src/vs/editor/common/viewModel/viewModel.ts index ffb43fadd6a..6372d3a1415 100644 --- a/src/vs/editor/common/viewModel/viewModel.ts +++ b/src/vs/editor/common/viewModel/viewModel.ts @@ -11,9 +11,9 @@ import { Range } from 'vs/editor/common/core/range'; import { Selection } from 'vs/editor/common/core/selection'; import { ViewEvent, IViewEventListener } from 'vs/editor/common/view/viewEvents'; import { IDisposable } from 'vs/base/common/lifecycle'; -import { Scrollable } from "vs/base/common/scrollable"; -import { IPartialViewLinesViewportData } from "vs/editor/common/viewLayout/viewLinesViewportData"; -import { IEditorWhitespace } from "vs/editor/common/viewLayout/whitespaceComputer"; +import { Scrollable } from 'vs/base/common/scrollable'; +import { IPartialViewLinesViewportData } from 'vs/editor/common/viewLayout/viewLinesViewportData'; +import { IEditorWhitespace } from 'vs/editor/common/viewLayout/whitespaceComputer'; export interface IViewWhitespaceViewportData { readonly id: number; diff --git a/src/vs/editor/common/viewModel/viewModelImpl.ts b/src/vs/editor/common/viewModel/viewModelImpl.ts index be7b24bb828..a7a7297e881 100644 --- a/src/vs/editor/common/viewModel/viewModelImpl.ts +++ b/src/vs/editor/common/viewModel/viewModelImpl.ts @@ -19,7 +19,7 @@ import * as viewEvents from 'vs/editor/common/view/viewEvents'; import { MinimapTokensColorTracker } from 'vs/editor/common/view/minimapCharRenderer'; import * as textModelEvents from 'vs/editor/common/model/textModelEvents'; import { IConfigurationChangedEvent } from 'vs/editor/common/config/editorOptions'; -import { CharacterHardWrappingLineMapperFactory } from "vs/editor/common/viewModel/characterHardWrappingLineMapper"; +import { CharacterHardWrappingLineMapperFactory } from 'vs/editor/common/viewModel/characterHardWrappingLineMapper'; import { ViewLayout } from 'vs/editor/common/viewLayout/viewLayout'; export class CoordinatesConverter implements ICoordinatesConverter { diff --git a/src/vs/editor/contrib/bracketMatching/common/bracketMatching.ts b/src/vs/editor/contrib/bracketMatching/common/bracketMatching.ts index a3443fa79fd..7b79df152e7 100644 --- a/src/vs/editor/contrib/bracketMatching/common/bracketMatching.ts +++ b/src/vs/editor/contrib/bracketMatching/common/bracketMatching.ts @@ -14,9 +14,9 @@ import { RunOnceScheduler } from 'vs/base/common/async'; import * as editorCommon from 'vs/editor/common/editorCommon'; import { editorAction, commonEditorContribution, ServicesAccessor, EditorAction } from 'vs/editor/common/editorCommonExtensions'; import { EditorContextKeys } from 'vs/editor/common/editorContextKeys'; -import { registerThemingParticipant } from "vs/platform/theme/common/themeService"; -import { editorBracketMatchBackground, editorBracketMatchBorder } from "vs/editor/common/view/editorColorRegistry"; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; +import { editorBracketMatchBackground, editorBracketMatchBorder } from 'vs/editor/common/view/editorColorRegistry'; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; @editorAction class SelectBracketAction extends EditorAction { diff --git a/src/vs/editor/contrib/codelens/browser/codelens.ts b/src/vs/editor/contrib/codelens/browser/codelens.ts index 84fcda05eb1..2c7e6ff341c 100644 --- a/src/vs/editor/contrib/codelens/browser/codelens.ts +++ b/src/vs/editor/contrib/codelens/browser/codelens.ts @@ -22,10 +22,10 @@ import * as editorBrowser from 'vs/editor/browser/editorBrowser'; import { editorContribution } from 'vs/editor/browser/editorBrowserExtensions'; import { ICodeLensData, getCodeLensData } from '../common/codelens'; import { IConfigurationChangedEvent } from 'vs/editor/common/config/editorOptions'; -import { editorCodeLensForeground } from "vs/editor/common/view/editorColorRegistry"; -import { registerThemingParticipant } from "vs/platform/theme/common/themeService"; -import { editorActiveLinkForeground } from "vs/platform/theme/common/colorRegistry"; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { editorCodeLensForeground } from 'vs/editor/common/view/editorColorRegistry'; +import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; +import { editorActiveLinkForeground } from 'vs/platform/theme/common/colorRegistry'; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; class CodeLensViewZone implements editorBrowser.IViewZone { diff --git a/src/vs/editor/contrib/comment/test/common/lineCommentCommand.test.ts b/src/vs/editor/contrib/comment/test/common/lineCommentCommand.test.ts index 1326d8bda33..64d900f1dd7 100644 --- a/src/vs/editor/contrib/comment/test/common/lineCommentCommand.test.ts +++ b/src/vs/editor/contrib/comment/test/common/lineCommentCommand.test.ts @@ -12,9 +12,9 @@ import { CommentMode } from 'vs/editor/test/common/commentMode'; import * as modes from 'vs/editor/common/modes'; import { NULL_STATE } from 'vs/editor/common/modes/nullMode'; import { TokenizationResult2 } from 'vs/editor/common/core/token'; -import { MockMode } from "vs/editor/test/common/mocks/mockMode"; -import { CommentRule } from "vs/editor/common/modes/languageConfiguration"; -import { LanguageConfigurationRegistry } from "vs/editor/common/modes/languageConfigurationRegistry"; +import { MockMode } from 'vs/editor/test/common/mocks/mockMode'; +import { CommentRule } from 'vs/editor/common/modes/languageConfiguration'; +import { LanguageConfigurationRegistry } from 'vs/editor/common/modes/languageConfigurationRegistry'; suite('Editor Contrib - Line Comment Command', () => { diff --git a/src/vs/editor/contrib/dnd/browser/dnd.ts b/src/vs/editor/contrib/dnd/browser/dnd.ts index e305c8af11a..7628350f4e2 100644 --- a/src/vs/editor/contrib/dnd/browser/dnd.ts +++ b/src/vs/editor/contrib/dnd/browser/dnd.ts @@ -17,7 +17,7 @@ import { Position } from 'vs/editor/common/core/position'; import { Range } from 'vs/editor/common/core/range'; import { Selection } from 'vs/editor/common/core/selection'; import { DragAndDropCommand } from '../common/dragAndDropCommand'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; @editorContribution export class DragAndDropController implements editorCommon.IEditorContribution { diff --git a/src/vs/editor/contrib/find/common/findController.ts b/src/vs/editor/contrib/find/common/findController.ts index e0657d80c73..4536b2b5b6f 100644 --- a/src/vs/editor/contrib/find/common/findController.ts +++ b/src/vs/editor/contrib/find/common/findController.ts @@ -21,7 +21,7 @@ import { RunOnceScheduler, Delayer } from 'vs/base/common/async'; import { CursorChangeReason, ICursorSelectionChangedEvent } from 'vs/editor/common/controller/cursorEvents'; import { EditorContextKeys } from 'vs/editor/common/editorContextKeys'; import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export const enum FindStartFocusAction { NoFocusChange, diff --git a/src/vs/editor/contrib/find/common/findDecorations.ts b/src/vs/editor/contrib/find/common/findDecorations.ts index 2a80081cf0a..4cf3d631284 100644 --- a/src/vs/editor/contrib/find/common/findDecorations.ts +++ b/src/vs/editor/contrib/find/common/findDecorations.ts @@ -8,7 +8,7 @@ import { IDisposable } from 'vs/base/common/lifecycle'; import * as editorCommon from 'vs/editor/common/editorCommon'; import { Position } from 'vs/editor/common/core/position'; import { Range } from 'vs/editor/common/core/range'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export class FindDecorations implements IDisposable { diff --git a/src/vs/editor/contrib/folding/common/foldingModel.ts b/src/vs/editor/contrib/folding/common/foldingModel.ts index 128f450b087..8ebd2424cc7 100644 --- a/src/vs/editor/contrib/folding/common/foldingModel.ts +++ b/src/vs/editor/contrib/folding/common/foldingModel.ts @@ -5,7 +5,7 @@ import * as editorCommon from 'vs/editor/common/editorCommon'; import { Range } from 'vs/editor/common/core/range'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export interface IFoldingRange { startLineNumber: number; diff --git a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts index a29f1511b44..124e4229c3d 100644 --- a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts +++ b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts @@ -24,7 +24,7 @@ import { registerThemingParticipant } from 'vs/platform/theme/common/themeServic import { editorActiveLinkForeground } from 'vs/platform/theme/common/colorRegistry'; import { EditorState, CodeEditorStateFlag } from 'vs/editor/common/core/editorState'; import { DefinitionAction, DefinitionActionConfig } from './goToDeclarationCommands'; -import { ClickLinkGesture, ClickLinkMouseEvent, ClickLinkKeyboardEvent } from "vs/editor/contrib/goToDeclaration/browser/clickLinkGesture"; +import { ClickLinkGesture, ClickLinkMouseEvent, ClickLinkKeyboardEvent } from 'vs/editor/contrib/goToDeclaration/browser/clickLinkGesture'; @editorContribution class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorContribution { diff --git a/src/vs/editor/contrib/hover/browser/modesContentHover.ts b/src/vs/editor/contrib/hover/browser/modesContentHover.ts index 636180c1a66..0814b278789 100644 --- a/src/vs/editor/contrib/hover/browser/modesContentHover.ts +++ b/src/vs/editor/contrib/hover/browser/modesContentHover.ts @@ -22,7 +22,7 @@ import { getHover } from '../common/hover'; import { HoverOperation, IHoverComputer } from './hoverOperation'; import { ContentHoverWidget } from './hoverWidgets'; import { textToMarkedString, MarkedString } from 'vs/base/common/htmlContent'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; class ModesContentComputer implements IHoverComputer { diff --git a/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.ts b/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.ts index 874af70feda..030eff62c25 100644 --- a/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.ts +++ b/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.ts @@ -18,7 +18,7 @@ import { InPlaceReplaceCommand } from './inPlaceReplaceCommand'; import { EditorState, CodeEditorStateFlag } from 'vs/editor/common/core/editorState'; import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; import { editorBracketMatchBorder } from 'vs/editor/common/view/editorColorRegistry'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; @commonEditorContribution class InPlaceReplaceController implements IEditorContribution { diff --git a/src/vs/editor/contrib/linesOperations/common/linesOperations.ts b/src/vs/editor/contrib/linesOperations/common/linesOperations.ts index 4bc4b88d0fa..a41829a885b 100644 --- a/src/vs/editor/contrib/linesOperations/common/linesOperations.ts +++ b/src/vs/editor/contrib/linesOperations/common/linesOperations.ts @@ -19,7 +19,7 @@ import { CopyLinesCommand } from './copyLinesCommand'; import { DeleteLinesCommand } from './deleteLinesCommand'; import { MoveLinesCommand } from './moveLinesCommand'; import { TypeOperations } from 'vs/editor/common/controller/cursorTypeOperations'; -import { CoreEditingCommands } from "vs/editor/common/controller/coreCommands"; +import { CoreEditingCommands } from 'vs/editor/common/controller/coreCommands'; // copy lines diff --git a/src/vs/editor/contrib/linesOperations/test/common/linesOperations.test.ts b/src/vs/editor/contrib/linesOperations/test/common/linesOperations.test.ts index 4a56e203f65..64c67e2cb9a 100644 --- a/src/vs/editor/contrib/linesOperations/test/common/linesOperations.test.ts +++ b/src/vs/editor/contrib/linesOperations/test/common/linesOperations.test.ts @@ -10,9 +10,9 @@ import { Position } from 'vs/editor/common/core/position'; import { Handler, IModel, DefaultEndOfLine } from 'vs/editor/common/editorCommon'; import { withMockCodeEditor } from 'vs/editor/test/common/mocks/mockCodeEditor'; import { DeleteAllLeftAction, JoinLinesAction, TransposeAction, UpperCaseAction, LowerCaseAction, DeleteAllRightAction, InsertLineBeforeAction, InsertLineAfterAction, IndentLinesAction } from 'vs/editor/contrib/linesOperations/common/linesOperations'; -import { Cursor } from "vs/editor/common/controller/cursor"; -import { Model } from "vs/editor/common/model/model"; -import { CoreEditingCommands } from "vs/editor/common/controller/coreCommands"; +import { Cursor } from 'vs/editor/common/controller/cursor'; +import { Model } from 'vs/editor/common/model/model'; +import { CoreEditingCommands } from 'vs/editor/common/controller/coreCommands'; suite('Editor Contrib - Line Operations', () => { suite('DeleteAllLeftAction', () => { diff --git a/src/vs/editor/contrib/links/browser/links.ts b/src/vs/editor/contrib/links/browser/links.ts index 356f9bf6843..d25c7a9a3ad 100644 --- a/src/vs/editor/contrib/links/browser/links.ts +++ b/src/vs/editor/contrib/links/browser/links.ts @@ -24,8 +24,8 @@ import { editorContribution } from 'vs/editor/browser/editorBrowserExtensions'; import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; import { editorActiveLinkForeground } from 'vs/platform/theme/common/colorRegistry'; import { Position } from 'vs/editor/common/core/position'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; -import { ClickLinkGesture, ClickLinkMouseEvent, ClickLinkKeyboardEvent } from "vs/editor/contrib/goToDeclaration/browser/clickLinkGesture"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; +import { ClickLinkGesture, ClickLinkMouseEvent, ClickLinkKeyboardEvent } from 'vs/editor/contrib/goToDeclaration/browser/clickLinkGesture'; const HOVER_MESSAGE_GENERAL_META = ( platform.isMacintosh diff --git a/src/vs/editor/contrib/quickOpen/browser/editorQuickOpen.ts b/src/vs/editor/contrib/quickOpen/browser/editorQuickOpen.ts index 3b088852ed4..6117ad98768 100644 --- a/src/vs/editor/contrib/quickOpen/browser/editorQuickOpen.ts +++ b/src/vs/editor/contrib/quickOpen/browser/editorQuickOpen.ts @@ -14,7 +14,7 @@ import { Selection } from 'vs/editor/common/core/selection'; import { IActionOptions, EditorAction } from 'vs/editor/common/editorCommonExtensions'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { Range } from 'vs/editor/common/core/range'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export interface IQuickOpenControllerOpts { inputAriaLabel: string; diff --git a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts index a7175ad5a1f..959c2bc8939 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts +++ b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts @@ -43,8 +43,8 @@ import { registerThemingParticipant, ITheme, IThemeService } from 'vs/platform/t import { attachListStyler, attachBadgeStyler } from 'vs/platform/theme/common/styler'; import { IModelDecorationsChangedEvent } from 'vs/editor/common/model/textModelEvents'; import { IEditorOptions } from 'vs/editor/common/config/editorOptions'; -import { IEnvironmentService } from "vs/platform/environment/common/environment"; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { IEnvironmentService } from 'vs/platform/environment/common/environment'; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; class DecorationsManager implements IDisposable { diff --git a/src/vs/editor/contrib/snippet/browser/snippetSession.ts b/src/vs/editor/contrib/snippet/browser/snippetSession.ts index b5938e3c7e4..2a38815488c 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetSession.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetSession.ts @@ -16,7 +16,7 @@ import { IPosition } from 'vs/editor/common/core/position'; import { groupBy } from 'vs/base/common/arrays'; import { dispose } from 'vs/base/common/lifecycle'; import { EditorSnippetVariableResolver } from "./snippetVariables"; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export class OneSnippet { diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetController2.old.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetController2.old.test.ts index 9e15e0bed55..1efa1b1a8c1 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetController2.old.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetController2.old.test.ts @@ -10,8 +10,8 @@ import { Selection } from 'vs/editor/common/core/selection'; import { SnippetController2 } from 'vs/editor/contrib/snippet/browser/snippetController2'; import { MockCodeEditor, withMockCodeEditor } from 'vs/editor/test/common/mocks/mockCodeEditor'; import { Cursor } from 'vs/editor/common/controller/cursor'; -import { IContextKeyService } from "vs/platform/contextkey/common/contextkey"; -import { ICommonCodeEditor } from "vs/editor/common/editorCommon"; +import { IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; +import { ICommonCodeEditor } from 'vs/editor/common/editorCommon'; class TestSnippetController extends SnippetController2 { diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts index 04a866727d3..6c30a179315 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts @@ -9,7 +9,7 @@ import { Selection } from 'vs/editor/common/core/selection'; import { SnippetController2 } from 'vs/editor/contrib/snippet/browser/snippetController2'; import { ICommonCodeEditor } from 'vs/editor/common/editorCommon'; import { mockCodeEditor } from 'vs/editor/test/common/mocks/mockCodeEditor'; -import { Model } from "vs/editor/common/model/model"; +import { Model } from 'vs/editor/common/model/model'; import { MockContextKeyService } from 'vs/platform/keybinding/test/common/mockKeybindingService'; suite('SnippetController2', function () { diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts index 5eb6c7cba93..100b9c0dbd8 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts @@ -11,7 +11,7 @@ import { IPosition, Position } from 'vs/editor/common/core/position'; import { SnippetSession } from 'vs/editor/contrib/snippet/browser/snippetSession'; import { ICommonCodeEditor } from 'vs/editor/common/editorCommon'; import { mockCodeEditor } from 'vs/editor/test/common/mocks/mockCodeEditor'; -import { Model } from "vs/editor/common/model/model"; +import { Model } from 'vs/editor/common/model/model'; suite('SnippetSession', function () { diff --git a/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.ts b/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.ts index b3fcd42202a..896e593b005 100644 --- a/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.ts +++ b/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.ts @@ -18,7 +18,7 @@ import { Position } from 'vs/editor/common/core/position'; import { registerColor, editorSelectionHighlight, activeContrastBorder } from 'vs/platform/theme/common/colorRegistry'; import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; import { CursorChangeReason, ICursorPositionChangedEvent } from 'vs/editor/common/controller/cursorEvents'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export const editorWordHighlight = registerColor('editor.wordHighlightBackground', { dark: '#575757B8', light: '#57575740', hc: null }, nls.localize('wordHighlight', 'Background color of a symbol during read-access, like reading a variable.')); export const editorWordHighlightStrong = registerColor('editor.wordHighlightStrongBackground', { dark: '#004972B8', light: '#0e639c40', hc: null }, nls.localize('wordHighlightStrong', 'Background color of a symbol during write-access, like writing to a variable.')); diff --git a/src/vs/editor/contrib/wordOperations/common/wordOperations.ts b/src/vs/editor/contrib/wordOperations/common/wordOperations.ts index 469e9446eb2..a2da8517ce5 100644 --- a/src/vs/editor/contrib/wordOperations/common/wordOperations.ts +++ b/src/vs/editor/contrib/wordOperations/common/wordOperations.ts @@ -14,9 +14,9 @@ import { Position } from 'vs/editor/common/core/position'; import { Range } from 'vs/editor/common/core/range'; import { WordNavigationType, WordOperations } from 'vs/editor/common/controller/cursorWordOperations'; import { ReplaceCommand } from 'vs/editor/common/commands/replaceCommand'; -import { getMapForWordSeparators, WordCharacterClassifier } from "vs/editor/common/controller/wordCharacterClassifier"; -import { CursorState } from "vs/editor/common/controller/cursorCommon"; -import { CursorChangeReason } from "vs/editor/common/controller/cursorEvents"; +import { getMapForWordSeparators, WordCharacterClassifier } from 'vs/editor/common/controller/wordCharacterClassifier'; +import { CursorState } from 'vs/editor/common/controller/cursorCommon'; +import { CursorChangeReason } from 'vs/editor/common/controller/cursorEvents'; export interface MoveWordOptions extends ICommandOptions { inSelectionMode: boolean; diff --git a/src/vs/editor/contrib/wordOperations/test/common/wordOperations.test.ts b/src/vs/editor/contrib/wordOperations/test/common/wordOperations.test.ts index d67a436a400..40c303f0bec 100644 --- a/src/vs/editor/contrib/wordOperations/test/common/wordOperations.test.ts +++ b/src/vs/editor/contrib/wordOperations/test/common/wordOperations.test.ts @@ -17,7 +17,7 @@ import { DeleteWordLeft, DeleteWordStartLeft, DeleteWordEndLeft, DeleteWordRight, DeleteWordStartRight, DeleteWordEndRight } from 'vs/editor/contrib/wordOperations/common/wordOperations'; -import { EditorCommand } from "vs/editor/common/editorCommonExtensions"; +import { EditorCommand } from 'vs/editor/common/editorCommonExtensions'; suite('WordOperations', () => { diff --git a/src/vs/editor/contrib/zoneWidget/browser/zoneWidget.ts b/src/vs/editor/contrib/zoneWidget/browser/zoneWidget.ts index e0de87646d8..dc599a468bf 100644 --- a/src/vs/editor/contrib/zoneWidget/browser/zoneWidget.ts +++ b/src/vs/editor/contrib/zoneWidget/browser/zoneWidget.ts @@ -16,7 +16,7 @@ import { ICodeEditor, IOverlayWidget, IOverlayWidgetPosition, IViewZone, IViewZo import { Color, RGBA } from 'vs/base/common/color'; import { EditorLayoutInfo } from 'vs/editor/common/config/editorOptions'; import { Position, IPosition } from 'vs/editor/common/core/position'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export interface IOptions { showFrame?: boolean; diff --git a/src/vs/editor/editor.main.ts b/src/vs/editor/editor.main.ts index 8e3a8c151dd..667a3004499 100644 --- a/src/vs/editor/editor.main.ts +++ b/src/vs/editor/editor.main.ts @@ -14,7 +14,7 @@ import 'vs/editor/contrib/inspectTokens/browser/inspectTokens'; import { createMonacoBaseAPI } from 'vs/editor/common/standalone/standaloneBase'; import { createMonacoEditorAPI } from 'vs/editor/browser/standalone/standaloneEditor'; import { createMonacoLanguagesAPI } from 'vs/editor/browser/standalone/standaloneLanguages'; -import { EDITOR_DEFAULTS, WrappingIndent } from "vs/editor/common/config/editorOptions"; +import { EDITOR_DEFAULTS, WrappingIndent } from 'vs/editor/common/config/editorOptions'; // Set defaults for standalone editor (EDITOR_DEFAULTS).wrappingIndent = WrappingIndent.None; diff --git a/src/vs/editor/test/browser/controller/textAreaState.test.ts b/src/vs/editor/test/browser/controller/textAreaState.test.ts index 9170690d5ec..59552e7542e 100644 --- a/src/vs/editor/test/browser/controller/textAreaState.test.ts +++ b/src/vs/editor/test/browser/controller/textAreaState.test.ts @@ -9,7 +9,7 @@ import { ISimpleModel, TextAreaState, ITextAreaWrapper, PagedScreenReaderStrateg import { Range } from 'vs/editor/common/core/range'; import { EndOfLinePreference } from 'vs/editor/common/editorCommon'; import { Disposable } from 'vs/base/common/lifecycle'; -import { Model } from "vs/editor/common/model/model"; +import { Model } from 'vs/editor/common/model/model'; import { Selection } from 'vs/editor/common/core/selection'; export class MockTextAreaWrapper extends Disposable implements ITextAreaWrapper { diff --git a/src/vs/editor/test/common/commands/commandTestUtils.ts b/src/vs/editor/test/common/commands/commandTestUtils.ts index b753b8a063a..184f5e8d99b 100644 --- a/src/vs/editor/test/common/commands/commandTestUtils.ts +++ b/src/vs/editor/test/common/commands/commandTestUtils.ts @@ -10,7 +10,7 @@ import { Selection } from 'vs/editor/common/core/selection'; import * as editorCommon from 'vs/editor/common/editorCommon'; import { Model } from 'vs/editor/common/model/model'; import { LanguageIdentifier } from 'vs/editor/common/modes'; -import { withMockCodeEditor } from "vs/editor/test/common/mocks/mockCodeEditor"; +import { withMockCodeEditor } from 'vs/editor/test/common/mocks/mockCodeEditor'; export function testCommand( lines: string[], diff --git a/src/vs/editor/test/common/commands/sideEditing.test.ts b/src/vs/editor/test/common/commands/sideEditing.test.ts index 2fa3ea6035f..af17bee84a2 100644 --- a/src/vs/editor/test/common/commands/sideEditing.test.ts +++ b/src/vs/editor/test/common/commands/sideEditing.test.ts @@ -11,7 +11,7 @@ import { Range } from 'vs/editor/common/core/range'; import { Selection } from 'vs/editor/common/core/selection'; import { IIdentifiedSingleEditOperation } from 'vs/editor/common/editorCommon'; import { ILineEdit, ModelLine, LineMarker, MarkersTracker } from 'vs/editor/common/model/modelLine'; -import { withMockCodeEditor } from "vs/editor/test/common/mocks/mockCodeEditor"; +import { withMockCodeEditor } from 'vs/editor/test/common/mocks/mockCodeEditor'; const NO_TAB_SIZE = 0; diff --git a/src/vs/editor/test/common/config/commonEditorConfig.test.ts b/src/vs/editor/test/common/config/commonEditorConfig.test.ts index 6abc5412b03..c07e1240c1f 100644 --- a/src/vs/editor/test/common/config/commonEditorConfig.test.ts +++ b/src/vs/editor/test/common/config/commonEditorConfig.test.ts @@ -7,8 +7,8 @@ import * as assert from 'assert'; import { EditorZoom } from 'vs/editor/common/config/editorZoom'; import { TestConfiguration } from 'vs/editor/test/common/mocks/testConfiguration'; -import { IEnvConfiguration } from "vs/editor/common/config/commonEditorConfig"; -import { AccessibilitySupport } from "vs/base/common/platform"; +import { IEnvConfiguration } from 'vs/editor/common/config/commonEditorConfig'; +import { AccessibilitySupport } from 'vs/base/common/platform'; suite('Common Editor Config', () => { test('Zoom Level', () => { diff --git a/src/vs/editor/test/common/controller/cursor.test.ts b/src/vs/editor/test/common/controller/cursor.test.ts index 833bd813b47..b3d15acc035 100644 --- a/src/vs/editor/test/common/controller/cursor.test.ts +++ b/src/vs/editor/test/common/controller/cursor.test.ts @@ -23,15 +23,15 @@ import { MockMode } from 'vs/editor/test/common/mocks/mockMode'; import { LanguageIdentifier } from 'vs/editor/common/modes'; import { IEditorOptions } from 'vs/editor/common/config/editorOptions'; import { CoreNavigationCommands, CoreEditingCommands } from 'vs/editor/common/controller/coreCommands'; -import { withMockCodeEditor, MockCodeEditor } from "vs/editor/test/common/mocks/mockCodeEditor"; -import { TextModel } from "vs/editor/common/model/textModel"; -import { ViewModel } from "vs/editor/common/viewModel/viewModelImpl"; +import { withMockCodeEditor, MockCodeEditor } from 'vs/editor/test/common/mocks/mockCodeEditor'; +import { TextModel } from 'vs/editor/common/model/textModel'; +import { ViewModel } from 'vs/editor/common/viewModel/viewModelImpl'; import * as viewEvents from 'vs/editor/common/view/viewEvents'; -import { ScreenReaderMessageGenerator } from "vs/editor/common/controller/accGenerator"; +import { ScreenReaderMessageGenerator } from 'vs/editor/common/controller/accGenerator'; import { CursorWordLeft, CursorWordLeftSelect, CursorWordRight, CursorWordRightSelect } from 'vs/editor/contrib/wordOperations/common/wordOperations'; -import { EditorCommand } from "vs/editor/common/editorCommonExtensions"; +import { EditorCommand } from 'vs/editor/common/editorCommonExtensions'; let H = Handler; // --------- utils diff --git a/src/vs/editor/test/common/controller/cursorMoveCommand.test.ts b/src/vs/editor/test/common/controller/cursorMoveCommand.test.ts index 1b4ae6b014d..2b9ac20069d 100644 --- a/src/vs/editor/test/common/controller/cursorMoveCommand.test.ts +++ b/src/vs/editor/test/common/controller/cursorMoveCommand.test.ts @@ -13,7 +13,7 @@ import { CursorMove } from 'vs/editor/common/controller/cursorMoveCommands'; import { Range } from 'vs/editor/common/core/range'; import { Selection } from 'vs/editor/common/core/selection'; import { CoreNavigationCommands } from 'vs/editor/common/controller/coreCommands'; -import { ViewModel } from "vs/editor/common/viewModel/viewModelImpl"; +import { ViewModel } from 'vs/editor/common/viewModel/viewModelImpl'; suite('Cursor move command test', () => { diff --git a/src/vs/editor/test/common/mocks/testConfiguration.ts b/src/vs/editor/test/common/mocks/testConfiguration.ts index edddfa74fdd..a8778a6f055 100644 --- a/src/vs/editor/test/common/mocks/testConfiguration.ts +++ b/src/vs/editor/test/common/mocks/testConfiguration.ts @@ -7,7 +7,7 @@ import { CommonEditorConfiguration, IEnvConfiguration } from 'vs/editor/common/config/commonEditorConfig'; import { IEditorOptions } from 'vs/editor/common/config/editorOptions'; import { FontInfo, BareFontInfo } from 'vs/editor/common/config/fontInfo'; -import { AccessibilitySupport } from "vs/base/common/platform"; +import { AccessibilitySupport } from 'vs/base/common/platform'; export class TestConfiguration extends CommonEditorConfiguration { diff --git a/src/vs/editor/test/common/model/textModelSearch.test.ts b/src/vs/editor/test/common/model/textModelSearch.test.ts index 4102cfad4fe..274ce45b934 100644 --- a/src/vs/editor/test/common/model/textModelSearch.test.ts +++ b/src/vs/editor/test/common/model/textModelSearch.test.ts @@ -10,8 +10,8 @@ import { FindMatch, EndOfLineSequence } from 'vs/editor/common/editorCommon'; import { Range } from 'vs/editor/common/core/range'; import { TextModel } from 'vs/editor/common/model/textModel'; import { TextModelSearch, SearchParams, SearchData } from 'vs/editor/common/model/textModelSearch'; -import { getMapForWordSeparators } from "vs/editor/common/controller/wordCharacterClassifier"; -import { USUAL_WORD_SEPARATORS } from "vs/editor/common/model/wordHelper"; +import { getMapForWordSeparators } from 'vs/editor/common/controller/wordCharacterClassifier'; +import { USUAL_WORD_SEPARATORS } from 'vs/editor/common/model/wordHelper'; // --------- Find suite('TextModelSearch', () => { diff --git a/src/vs/workbench/browser/parts/compositePart.ts b/src/vs/workbench/browser/parts/compositePart.ts index bb92039a1f0..5c23e84ef0f 100644 --- a/src/vs/workbench/browser/parts/compositePart.ts +++ b/src/vs/workbench/browser/parts/compositePart.ts @@ -36,7 +36,7 @@ import { IProgressService } from 'vs/platform/progress/common/progress'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { IThemeService } from 'vs/platform/theme/common/themeService'; -import { attachProgressBarStyler } from "vs/platform/theme/common/styler"; +import { attachProgressBarStyler } from 'vs/platform/theme/common/styler'; export interface ICompositeTitleLabel { diff --git a/src/vs/workbench/browser/parts/editor/editorGroupsControl.ts b/src/vs/workbench/browser/parts/editor/editorGroupsControl.ts index 05bf24ac197..4bc4a3b143a 100644 --- a/src/vs/workbench/browser/parts/editor/editorGroupsControl.ts +++ b/src/vs/workbench/browser/parts/editor/editorGroupsControl.ts @@ -36,7 +36,7 @@ import { getCodeEditor } from 'vs/editor/common/services/codeEditorService'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { editorBackground, contrastBorder, activeContrastBorder } from 'vs/platform/theme/common/colorRegistry'; import { Themable, EDITOR_GROUP_HEADER_TABS_BACKGROUND, EDITOR_GROUP_HEADER_NO_TABS_BACKGROUND, EDITOR_GROUP_BORDER, EDITOR_DRAG_AND_DROP_BACKGROUND, EDITOR_GROUP_BACKGROUND, EDITOR_GROUP_HEADER_TABS_BORDER } from 'vs/workbench/common/theme'; -import { attachProgressBarStyler } from "vs/platform/theme/common/styler"; +import { attachProgressBarStyler } from 'vs/platform/theme/common/styler'; export enum Rochade { NONE, diff --git a/src/vs/workbench/browser/parts/editor/webviewEditor.ts b/src/vs/workbench/browser/parts/editor/webviewEditor.ts index cf852a3d1a5..50f792c3e9d 100644 --- a/src/vs/workbench/browser/parts/editor/webviewEditor.ts +++ b/src/vs/workbench/browser/parts/editor/webviewEditor.ts @@ -5,10 +5,10 @@ 'use strict'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IThemeService } from 'vs/platform/theme/common/themeService'; -import { BaseEditor } from "vs/workbench/browser/parts/editor/baseEditor"; -import URI from "vs/base/common/uri"; -import { IStorageService } from "vs/platform/storage/common/storage"; -import { Scope } from "vs/workbench/common/memento"; +import { BaseEditor } from 'vs/workbench/browser/parts/editor/baseEditor'; +import URI from 'vs/base/common/uri'; +import { IStorageService } from 'vs/platform/storage/common/storage'; +import { Scope } from 'vs/workbench/common/memento'; export interface HtmlPreviewEditorViewState { scrollYPercentage: number; diff --git a/src/vs/workbench/browser/parts/statusbar/statusbarPart.ts b/src/vs/workbench/browser/parts/statusbar/statusbarPart.ts index fd2fd574fb4..b7909865487 100644 --- a/src/vs/workbench/browser/parts/statusbar/statusbarPart.ts +++ b/src/vs/workbench/browser/parts/statusbar/statusbarPart.ts @@ -30,7 +30,7 @@ import { IThemeService, registerThemingParticipant, ITheme, ICssStyleCollector } import { STATUS_BAR_BACKGROUND, STATUS_BAR_FOREGROUND, STATUS_BAR_NO_FOLDER_BACKGROUND, STATUS_BAR_ITEM_HOVER_BACKGROUND, STATUS_BAR_ITEM_ACTIVE_BACKGROUND, STATUS_BAR_PROMINENT_ITEM_BACKGROUND, STATUS_BAR_PROMINENT_ITEM_HOVER_BACKGROUND, STATUS_BAR_BORDER, STATUS_BAR_NO_FOLDER_FOREGROUND } from 'vs/workbench/common/theme'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { contrastBorder } from 'vs/platform/theme/common/colorRegistry'; -import { isThemeColor } from "vs/editor/common/editorCommon"; +import { isThemeColor } from 'vs/editor/common/editorCommon'; import { Color } from 'vs/base/common/color'; export class StatusbarPart extends Part implements IStatusbarService { diff --git a/src/vs/workbench/common/editor/rangeDecorations.ts b/src/vs/workbench/common/editor/rangeDecorations.ts index 7c8678ab24c..70a95b14274 100644 --- a/src/vs/workbench/common/editor/rangeDecorations.ts +++ b/src/vs/workbench/common/editor/rangeDecorations.ts @@ -12,7 +12,7 @@ import { toResource } from 'vs/workbench/common/editor'; import { isEqual } from 'vs/platform/files/common/files'; import { IRange } from 'vs/editor/common/core/range'; import { CursorChangeReason, ICursorPositionChangedEvent } from 'vs/editor/common/controller/cursorEvents'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export interface IRangeHighlightDecoration { resource: URI; diff --git a/src/vs/workbench/electron-browser/workbench.ts b/src/vs/workbench/electron-browser/workbench.ts index 86c445e811c..5a2a8efaff7 100644 --- a/src/vs/workbench/electron-browser/workbench.ts +++ b/src/vs/workbench/electron-browser/workbench.ts @@ -7,6 +7,7 @@ import 'vs/css!./media/workbench'; +import { localize } from 'vs/nls'; import { TPromise, ValueCallback } from 'vs/base/common/winjs.base'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import Event, { Emitter, chain } from 'vs/base/common/event'; @@ -91,11 +92,10 @@ import { IContextMenuService } from 'vs/platform/contextview/browser/contextView import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IWindowConfiguration } from 'vs/workbench/electron-browser/common'; -import { localize } from "vs/nls"; -import { IWorkbenchActionRegistry, Extensions } from "vs/workbench/common/actionRegistry"; +import { IWorkbenchActionRegistry, Extensions } from 'vs/workbench/common/actionRegistry'; import { OpenRecentAction, ToggleDevToolsAction, ReloadWindowAction } from "vs/workbench/electron-browser/actions"; -import { KeyMod } from "vs/base/common/keyCodes"; -import { KeyCode } from "vs/editor/common/standalone/standaloneBase"; +import { KeyMod } from 'vs/base/common/keyCodes'; +import { KeyCode } from 'vs/editor/common/standalone/standaloneBase'; export const MessagesVisibleContext = new RawContextKey('globalMessageVisible', false); export const EditorsVisibleContext = new RawContextKey('editorIsOpen', false); diff --git a/src/vs/workbench/node/extensionPoints.ts b/src/vs/workbench/node/extensionPoints.ts index bcb6fc2206d..c1b76d345ec 100644 --- a/src/vs/workbench/node/extensionPoints.ts +++ b/src/vs/workbench/node/extensionPoints.ts @@ -18,7 +18,7 @@ import Types = require('vs/base/common/types'); import { isValidExtensionDescription } from 'vs/platform/extensions/node/extensionValidator'; import * as semver from 'semver'; import { getIdAndVersionFromLocalExtensionId } from 'vs/platform/extensionManagement/common/extensionManagementUtil'; -import { getParseErrorMessage } from "vs/base/common/jsonErrorMessages"; +import { getParseErrorMessage } from 'vs/base/common/jsonErrorMessages'; const MANIFEST_FILE = 'package.json'; diff --git a/src/vs/workbench/parts/debug/browser/debugActionItems.ts b/src/vs/workbench/parts/debug/browser/debugActionItems.ts index edb07e3d969..50d19edfefb 100644 --- a/src/vs/workbench/parts/debug/browser/debugActionItems.ts +++ b/src/vs/workbench/parts/debug/browser/debugActionItems.ts @@ -19,7 +19,7 @@ import { IDebugService } from 'vs/workbench/parts/debug/common/debug'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { attachSelectBoxStyler, attachStylerCallback } from 'vs/platform/theme/common/styler'; import { SIDE_BAR_BACKGROUND } from 'vs/workbench/common/theme'; -import { selectBorder } from "vs/platform/theme/common/colorRegistry"; +import { selectBorder } from 'vs/platform/theme/common/colorRegistry'; const $ = dom.$; diff --git a/src/vs/workbench/parts/debug/browser/exceptionWidget.ts b/src/vs/workbench/parts/debug/browser/exceptionWidget.ts index a54e0e1ff20..70004ffb526 100644 --- a/src/vs/workbench/parts/debug/browser/exceptionWidget.ts +++ b/src/vs/workbench/parts/debug/browser/exceptionWidget.ts @@ -11,9 +11,9 @@ import { ICodeEditor } from 'vs/editor/browser/editorBrowser'; import { IContextViewService } from 'vs/platform/contextview/browser/contextView'; import { IDebugService, IExceptionInfo } from 'vs/workbench/parts/debug/common/debug'; import { RunOnceScheduler } from 'vs/base/common/async'; -import { IThemeService, ITheme } from "vs/platform/theme/common/themeService"; -import { Color } from "vs/base/common/color"; -import { registerColor } from "vs/platform/theme/common/colorRegistry"; +import { IThemeService, ITheme } from 'vs/platform/theme/common/themeService'; +import { Color } from 'vs/base/common/color'; +import { registerColor } from 'vs/platform/theme/common/colorRegistry'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { LinkDetector } from 'vs/workbench/parts/debug/browser/linkDetector'; const $ = dom.$; diff --git a/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.ts b/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.ts index f0e0ed7a9bd..95e12911dcf 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.ts @@ -37,7 +37,7 @@ import { FloatingClickWidget } from 'vs/workbench/parts/preferences/browser/pref import { IListService } from 'vs/platform/list/browser/listService'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { Position } from 'vs/editor/common/core/position'; -import { CoreEditingCommands } from "vs/editor/common/controller/coreCommands"; +import { CoreEditingCommands } from 'vs/editor/common/controller/coreCommands'; const HOVER_DELAY = 300; const LAUNCH_JSON_REGEX = /launch\.json$/; diff --git a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts index 4e5b9be2e79..ce54f235ae5 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts @@ -23,7 +23,7 @@ import { VariablesRenderer, renderExpressionValue, VariablesDataSource } from 'v import { IListService } from 'vs/platform/list/browser/listService'; import { attachListStyler, attachStylerCallback } from 'vs/platform/theme/common/styler'; import { IThemeService } from 'vs/platform/theme/common/themeService'; -import { editorHoverBackground, editorHoverBorder } from "vs/platform/theme/common/colorRegistry"; +import { editorHoverBackground, editorHoverBorder } from 'vs/platform/theme/common/colorRegistry'; const $ = dom.$; const MAX_ELEMENTS_SHOWN = 18; diff --git a/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.ts b/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.ts index fe69b0ad530..78ba083f9a0 100644 --- a/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.ts +++ b/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.ts @@ -11,7 +11,7 @@ import { IPartService, Parts } from 'vs/workbench/services/part/common/partServi import { IDebugService, State } from 'vs/workbench/parts/debug/common/debug'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { STATUS_BAR_NO_FOLDER_BACKGROUND, STATUS_BAR_NO_FOLDER_FOREGROUND, STATUS_BAR_BACKGROUND, Themable, STATUS_BAR_FOREGROUND } from 'vs/workbench/common/theme'; -import { addClass, removeClass } from "vs/base/browser/dom"; +import { addClass, removeClass } from 'vs/base/browser/dom'; // colors for theming diff --git a/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.ts b/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.ts index f1db99bf647..f046995c799 100644 --- a/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.ts +++ b/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.ts @@ -11,7 +11,7 @@ import { BasicEmmetEditorAction } from 'vs/workbench/parts/emmet/electron-browse import { editorAction } from 'vs/editor/common/editorCommonExtensions'; import { ICommonCodeEditor } from 'vs/editor/common/editorCommon'; import { EditorContextKeys } from 'vs/editor/common/editorContextKeys'; -import { CoreEditingCommands } from "vs/editor/common/controller/coreCommands"; +import { CoreEditingCommands } from 'vs/editor/common/controller/coreCommands'; import { KeyCode } from 'vs/base/common/keyCodes'; import { ContextKeyExpr } from 'vs/platform/contextkey/common/contextkey'; diff --git a/src/vs/workbench/parts/emmet/electron-browser/editorAccessor.ts b/src/vs/workbench/parts/emmet/electron-browser/editorAccessor.ts index 38cb77ea2fd..26f7cf390e7 100644 --- a/src/vs/workbench/parts/emmet/electron-browser/editorAccessor.ts +++ b/src/vs/workbench/parts/emmet/electron-browser/editorAccessor.ts @@ -11,7 +11,7 @@ import { Range } from 'vs/editor/common/core/range'; import { SnippetController2 } from 'vs/editor/contrib/snippet/browser/snippetController2'; import { LanguageId, LanguageIdentifier } from 'vs/editor/common/modes'; import { Position } from 'vs/editor/common/core/position'; -import { CoreEditingCommands } from "vs/editor/common/controller/coreCommands"; +import { CoreEditingCommands } from 'vs/editor/common/controller/coreCommands'; import { SnippetParser, walk, Placeholder, Variable, Text, Marker } from 'vs/editor/contrib/snippet/browser/snippetParser'; import emmet = require('emmet'); diff --git a/src/vs/workbench/parts/extensions/browser/extensionsActions.ts b/src/vs/workbench/parts/extensions/browser/extensionsActions.ts index f2cf8c9cacd..b922ba26c25 100644 --- a/src/vs/workbench/parts/extensions/browser/extensionsActions.ts +++ b/src/vs/workbench/parts/extensions/browser/extensionsActions.ts @@ -32,9 +32,9 @@ import { IExtensionService, IExtensionDescription } from 'vs/platform/extensions import URI from 'vs/base/common/uri'; import { CommandsRegistry } from 'vs/platform/commands/common/commands'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { registerThemingParticipant, ITheme, ICssStyleCollector } from "vs/platform/theme/common/themeService"; -import { buttonBackground, buttonForeground, buttonHoverBackground, contrastBorder, registerColor, foreground } from "vs/platform/theme/common/colorRegistry"; -import { Color } from "vs/base/common/color"; +import { registerThemingParticipant, ITheme, ICssStyleCollector } from 'vs/platform/theme/common/themeService'; +import { buttonBackground, buttonForeground, buttonHoverBackground, contrastBorder, registerColor, foreground } from 'vs/platform/theme/common/colorRegistry'; +import { Color } from 'vs/base/common/color'; export class InstallAction extends Action { diff --git a/src/vs/workbench/parts/feedback/electron-browser/feedback.ts b/src/vs/workbench/parts/feedback/electron-browser/feedback.ts index 310eb5f0d97..ec3746121ea 100644 --- a/src/vs/workbench/parts/feedback/electron-browser/feedback.ts +++ b/src/vs/workbench/parts/feedback/electron-browser/feedback.ts @@ -17,9 +17,9 @@ import * as dom from 'vs/base/browser/dom'; import { ICommandService } from 'vs/platform/commands/common/commands'; import * as errors from 'vs/base/common/errors'; import { IIntegrityService } from 'vs/platform/integrity/common/integrity'; -import { IThemeService, registerThemingParticipant, ITheme, ICssStyleCollector } from "vs/platform/theme/common/themeService"; -import { attachStylerCallback } from "vs/platform/theme/common/styler"; -import { editorWidgetBackground, widgetShadow, inputBorder, inputForeground, inputBackground, inputActiveOptionBorder, editorBackground, buttonBackground, contrastBorder } from "vs/platform/theme/common/colorRegistry"; +import { IThemeService, registerThemingParticipant, ITheme, ICssStyleCollector } from 'vs/platform/theme/common/themeService'; +import { attachStylerCallback } from 'vs/platform/theme/common/styler'; +import { editorWidgetBackground, widgetShadow, inputBorder, inputForeground, inputBackground, inputActiveOptionBorder, editorBackground, buttonBackground, contrastBorder } from 'vs/platform/theme/common/colorRegistry'; export interface IFeedback { feedback: string; diff --git a/src/vs/workbench/parts/feedback/electron-browser/feedbackStatusbarItem.ts b/src/vs/workbench/parts/feedback/electron-browser/feedbackStatusbarItem.ts index b4763f543e6..b124264626e 100644 --- a/src/vs/workbench/parts/feedback/electron-browser/feedbackStatusbarItem.ts +++ b/src/vs/workbench/parts/feedback/electron-browser/feedbackStatusbarItem.ts @@ -13,7 +13,7 @@ import { IInstantiationService } from 'vs/platform/instantiation/common/instanti import product from 'vs/platform/node/product'; import { Themable, STATUS_BAR_FOREGROUND, STATUS_BAR_NO_FOLDER_FOREGROUND } from 'vs/workbench/common/theme'; import { IThemeService } from 'vs/platform/theme/common/themeService'; -import { IWorkspaceContextService } from "vs/platform/workspace/common/workspace"; +import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; class TwitterFeedbackService implements IFeedbackService { diff --git a/src/vs/workbench/parts/files/browser/views/openEditorsView.ts b/src/vs/workbench/parts/files/browser/views/openEditorsView.ts index 4b3e4ee2778..3af3b297057 100644 --- a/src/vs/workbench/parts/files/browser/views/openEditorsView.ts +++ b/src/vs/workbench/parts/files/browser/views/openEditorsView.ts @@ -33,7 +33,7 @@ import { IListService } from 'vs/platform/list/browser/listService'; import { EditorGroup } from 'vs/workbench/common/editor/editorStacksModel'; import { attachListStyler, attachStylerCallback } from 'vs/platform/theme/common/styler'; import { IThemeService } from 'vs/platform/theme/common/themeService'; -import { badgeBackground, badgeForeground, contrastBorder } from "vs/platform/theme/common/colorRegistry"; +import { badgeBackground, badgeForeground, contrastBorder } from 'vs/platform/theme/common/colorRegistry'; const $ = dom.$; diff --git a/src/vs/workbench/parts/markers/browser/markersTreeViewer.ts b/src/vs/workbench/parts/markers/browser/markersTreeViewer.ts index b0f736e5e51..c78dfb63b68 100644 --- a/src/vs/workbench/parts/markers/browser/markersTreeViewer.ts +++ b/src/vs/workbench/parts/markers/browser/markersTreeViewer.ts @@ -18,9 +18,9 @@ import { IMarker } from 'vs/platform/markers/common/markers'; import { MarkersModel, Resource, Marker } from 'vs/workbench/parts/markers/common/markersModel'; import Messages from 'vs/workbench/parts/markers/common/messages'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; -import { attachBadgeStyler } from "vs/platform/theme/common/styler"; -import { IThemeService } from "vs/platform/theme/common/themeService"; -import { IDisposable } from "vs/base/common/lifecycle"; +import { attachBadgeStyler } from 'vs/platform/theme/common/styler'; +import { IThemeService } from 'vs/platform/theme/common/themeService'; +import { IDisposable } from 'vs/base/common/lifecycle'; interface IAnyResourceTemplateData { count: CountBadge; diff --git a/src/vs/workbench/parts/preferences/browser/keybindingWidgets.ts b/src/vs/workbench/parts/preferences/browser/keybindingWidgets.ts index 67c6fca57ae..65043dc7561 100644 --- a/src/vs/workbench/parts/preferences/browser/keybindingWidgets.ts +++ b/src/vs/workbench/parts/preferences/browser/keybindingWidgets.ts @@ -23,7 +23,7 @@ import { IInstantiationService } from 'vs/platform/instantiation/common/instanti import { ICodeEditor, IOverlayWidget, IOverlayWidgetPosition } from 'vs/editor/browser/editorBrowser'; import { attachInputBoxStyler, attachStylerCallback } from 'vs/platform/theme/common/styler'; import { IThemeService } from 'vs/platform/theme/common/themeService'; -import { editorWidgetBackground, widgetShadow } from "vs/platform/theme/common/colorRegistry"; +import { editorWidgetBackground, widgetShadow } from 'vs/platform/theme/common/colorRegistry'; class KeybindingInputWidget extends Widget { diff --git a/src/vs/workbench/parts/preferences/browser/keybindingsEditor.ts b/src/vs/workbench/parts/preferences/browser/keybindingsEditor.ts index ca94ecd2c2b..16fedab3623 100644 --- a/src/vs/workbench/parts/preferences/browser/keybindingsEditor.ts +++ b/src/vs/workbench/parts/preferences/browser/keybindingsEditor.ts @@ -39,7 +39,7 @@ import { IChoiceService, IMessageService, Severity } from 'vs/platform/message/c import { StandardKeyboardEvent } from 'vs/base/browser/keyboardEvent'; import { KeyCode, ResolvedKeybinding } from 'vs/base/common/keyCodes'; import { attachListStyler } from 'vs/platform/theme/common/styler'; -import { listHighlightForeground } from "vs/platform/theme/common/colorRegistry"; +import { listHighlightForeground } from 'vs/platform/theme/common/colorRegistry'; let $ = DOM.$; diff --git a/src/vs/workbench/parts/preferences/browser/preferencesEditor.ts b/src/vs/workbench/parts/preferences/browser/preferencesEditor.ts index 0aae0f5f0ff..ca535cf3de0 100644 --- a/src/vs/workbench/parts/preferences/browser/preferencesEditor.ts +++ b/src/vs/workbench/parts/preferences/browser/preferencesEditor.ts @@ -53,8 +53,8 @@ import { FindController } from 'vs/editor/contrib/find/browser/find'; import { SelectionHighlighter } from 'vs/editor/contrib/find/common/findController'; import { IEditorOptions } from 'vs/editor/common/config/editorOptions'; import { KeybindingsRegistry } from 'vs/platform/keybinding/common/keybindingsRegistry'; -import { attachStylerCallback } from "vs/platform/theme/common/styler"; -import { scrollbarShadow } from "vs/platform/theme/common/colorRegistry"; +import { attachStylerCallback } from 'vs/platform/theme/common/styler'; +import { scrollbarShadow } from 'vs/platform/theme/common/colorRegistry'; export class PreferencesEditorInput extends SideBySideEditorInput { public static ID: string = 'workbench.editorinputs.preferencesEditorInput'; diff --git a/src/vs/workbench/parts/preferences/browser/preferencesRenderers.ts b/src/vs/workbench/parts/preferences/browser/preferencesRenderers.ts index bd29a6a03df..81941633f5d 100644 --- a/src/vs/workbench/parts/preferences/browser/preferencesRenderers.ts +++ b/src/vs/workbench/parts/preferences/browser/preferencesRenderers.ts @@ -32,7 +32,7 @@ import { IWorkspaceConfigurationService } from 'vs/workbench/services/configurat import { IMessageService, Severity } from 'vs/platform/message/common/message'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; import { ICursorPositionChangedEvent } from 'vs/editor/common/controller/cursorEvents'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export interface IPreferencesRenderer extends IDisposable { preferencesModel: IPreferencesEditorModel; diff --git a/src/vs/workbench/parts/preferences/browser/preferencesWidgets.ts b/src/vs/workbench/parts/preferences/browser/preferencesWidgets.ts index 1f802861a31..52f1edebae3 100644 --- a/src/vs/workbench/parts/preferences/browser/preferencesWidgets.ts +++ b/src/vs/workbench/parts/preferences/browser/preferencesWidgets.ts @@ -27,7 +27,7 @@ import { attachInputBoxStyler, attachStylerCallback } from 'vs/platform/theme/co import { IThemeService } from 'vs/platform/theme/common/themeService'; import { Position } from 'vs/editor/common/core/position'; import { ICursorPositionChangedEvent } from 'vs/editor/common/controller/cursorEvents'; -import { buttonBackground, buttonForeground, badgeForeground, badgeBackground, contrastBorder, errorForeground } from "vs/platform/theme/common/colorRegistry"; +import { buttonBackground, buttonForeground, badgeForeground, badgeBackground, contrastBorder, errorForeground } from 'vs/platform/theme/common/colorRegistry'; export class SettingsGroupTitleWidget extends Widget implements IViewZone { diff --git a/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts b/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts index 5435cc3a698..260ab6e1a64 100644 --- a/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts +++ b/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts @@ -28,7 +28,7 @@ import { IMessageService, Severity, IMessageWithAction } from 'vs/platform/messa import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { IQuickOpenService } from 'vs/platform/quickOpen/common/quickOpen'; -import { editorAction, EditorAction } from "vs/editor/common/editorCommonExtensions"; +import { editorAction, EditorAction } from 'vs/editor/common/editorCommonExtensions'; export const ALL_COMMANDS_PREFIX = '>'; export const EDITOR_COMMANDS_PREFIX = '$'; diff --git a/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.ts b/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.ts index eaca7cc45e5..8561d451305 100644 --- a/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.ts +++ b/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.ts @@ -22,11 +22,11 @@ import { IEditorWorkerService } from 'vs/editor/common/services/editorWorkerServ import URI from 'vs/base/common/uri'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { ISCMService } from 'vs/workbench/services/scm/common/scm'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; -import { registerThemingParticipant, ITheme, ICssStyleCollector } from "vs/platform/theme/common/themeService"; -import { registerColor } from "vs/platform/theme/common/colorRegistry"; -import { localize } from "vs/nls"; -import { Color } from "vs/base/common/color"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; +import { registerThemingParticipant, ITheme, ICssStyleCollector } from 'vs/platform/theme/common/themeService'; +import { registerColor } from 'vs/platform/theme/common/colorRegistry'; +import { localize } from 'vs/nls'; +import { Color } from 'vs/base/common/color'; class DirtyDiffModelDecorator { diff --git a/src/vs/workbench/parts/search/browser/openFileHandler.ts b/src/vs/workbench/parts/search/browser/openFileHandler.ts index 28c61bbc3d4..1ff6554fa37 100644 --- a/src/vs/workbench/parts/search/browser/openFileHandler.ts +++ b/src/vs/workbench/parts/search/browser/openFileHandler.ts @@ -31,7 +31,7 @@ import { IQueryOptions, ISearchService, ISearchStats, ISearchQuery } from 'vs/pl import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { IRange } from 'vs/editor/common/core/range'; -import { getOutOfWorkspaceEditorResources } from "vs/workbench/parts/search/common/search"; +import { getOutOfWorkspaceEditorResources } from 'vs/workbench/parts/search/common/search'; export class FileQuickOpenModel extends QuickOpenModel { diff --git a/src/vs/workbench/parts/search/browser/searchResultsView.ts b/src/vs/workbench/parts/search/browser/searchResultsView.ts index 48452fee61f..c9d95f8e9ab 100644 --- a/src/vs/workbench/parts/search/browser/searchResultsView.ts +++ b/src/vs/workbench/parts/search/browser/searchResultsView.ts @@ -19,8 +19,8 @@ import { Range } from 'vs/editor/common/core/range'; import { SearchViewlet } from 'vs/workbench/parts/search/browser/searchViewlet'; import { RemoveAction, ReplaceAllAction, ReplaceAction } from 'vs/workbench/parts/search/browser/searchActions'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; -import { attachBadgeStyler } from "vs/platform/theme/common/styler"; -import { IThemeService } from "vs/platform/theme/common/themeService"; +import { attachBadgeStyler } from 'vs/platform/theme/common/styler'; +import { IThemeService } from 'vs/platform/theme/common/themeService'; export class SearchDataSource implements IDataSource { diff --git a/src/vs/workbench/parts/search/browser/searchViewlet.ts b/src/vs/workbench/parts/search/browser/searchViewlet.ts index ed2a0c9f953..04837eb7f6e 100644 --- a/src/vs/workbench/parts/search/browser/searchViewlet.ts +++ b/src/vs/workbench/parts/search/browser/searchViewlet.ts @@ -60,7 +60,7 @@ import FileResultsNavigation from 'vs/workbench/browser/fileResultsNavigation'; import { attachListStyler } from 'vs/platform/theme/common/styler'; import { IOutputService } from 'vs/workbench/parts/output/common/output'; import { Color } from 'vs/base/common/color'; -import { getOutOfWorkspaceEditorResources } from "vs/workbench/parts/search/common/search"; +import { getOutOfWorkspaceEditorResources } from 'vs/workbench/parts/search/common/search'; export class SearchViewlet extends Viewlet { diff --git a/src/vs/workbench/parts/search/common/search.ts b/src/vs/workbench/parts/search/common/search.ts index 19cd463c846..a6f98af6b22 100644 --- a/src/vs/workbench/parts/search/common/search.ts +++ b/src/vs/workbench/parts/search/common/search.ts @@ -12,10 +12,10 @@ import { CommonEditorRegistry } from 'vs/editor/common/editorCommonExtensions'; import { ISearchConfiguration } from 'vs/platform/search/common/search'; import glob = require('vs/base/common/glob'); import { SymbolInformation } from 'vs/editor/common/modes'; -import { IEditorGroupService } from "vs/workbench/services/group/common/groupService"; -import { IWorkspaceContextService } from "vs/platform/workspace/common/workspace"; -import URI from "vs/base/common/uri"; -import { toResource } from "vs/workbench/common/editor"; +import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; +import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import URI from 'vs/base/common/uri'; +import { toResource } from 'vs/workbench/common/editor'; export interface IWorkspaceSymbolProvider { provideWorkspaceSymbols(search: string): TPromise; diff --git a/src/vs/workbench/parts/search/common/searchModel.ts b/src/vs/workbench/parts/search/common/searchModel.ts index 87dae50f90e..114d6657c1a 100644 --- a/src/vs/workbench/parts/search/common/searchModel.ts +++ b/src/vs/workbench/parts/search/common/searchModel.ts @@ -24,7 +24,7 @@ import { IModelService } from 'vs/editor/common/services/modelService'; import { IReplaceService } from 'vs/workbench/parts/search/common/replace'; import { IProgressRunner } from 'vs/platform/progress/common/progress'; import { RangeHighlightDecorations } from 'vs/workbench/common/editor/rangeDecorations'; -import { ModelDecorationOptions } from "vs/editor/common/model/textModelWithDecorations"; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; export class Match { diff --git a/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.ts b/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.ts index ae83175077b..dcdfe17498a 100644 --- a/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.ts +++ b/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.ts @@ -16,7 +16,7 @@ import { IModeService } from 'vs/editor/common/services/modeService'; import { languagesExtPoint } from 'vs/editor/common/services/modeServiceImpl'; import { LanguageIdentifier } from 'vs/editor/common/modes'; import { SnippetParser, Marker, Placeholder, Variable, Text, walk } from 'vs/editor/contrib/snippet/browser/snippetParser'; -import { EditorSnippetVariableResolver } from "vs/editor/contrib/snippet/browser/snippetVariables"; +import { EditorSnippetVariableResolver } from 'vs/editor/contrib/snippet/browser/snippetVariables'; interface ISnippetsExtensionPoint { language: string; diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts index c4e3fc01471..17e931a643b 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts @@ -27,7 +27,7 @@ import { ToggleTabFocusModeAction } from 'vs/editor/contrib/toggleTabFocusMode/c import { registerSingleton } from 'vs/platform/instantiation/common/extensions'; import { KeybindingsRegistry } from 'vs/platform/keybinding/common/keybindingsRegistry'; import { OpenNextRecentlyUsedEditorInGroupAction, OpenPreviousRecentlyUsedEditorInGroupAction, FocusActiveGroupAction, FocusFirstGroupAction, FocusSecondGroupAction, FocusThirdGroupAction } from 'vs/workbench/browser/parts/editor/editorActions'; -import { EDITOR_FONT_DEFAULTS } from "vs/editor/common/config/editorOptions"; +import { EDITOR_FONT_DEFAULTS } from 'vs/editor/common/config/editorOptions'; import { registerColors } from './terminalColorRegistry'; let configurationRegistry = Registry.as(Extensions.Configuration); diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.ts index 236474f7366..fda8ca9b994 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.ts @@ -5,7 +5,7 @@ import * as nls from 'vs/nls'; import * as platform from 'vs/base/common/platform'; -import { EDITOR_FONT_DEFAULTS, IEditorOptions } from "vs/editor/common/config/editorOptions"; +import { EDITOR_FONT_DEFAULTS, IEditorOptions } from 'vs/editor/common/config/editorOptions'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { IWorkspaceConfigurationService } from 'vs/workbench/services/configuration/common/configuration'; import { IChoiceService } from 'vs/platform/message/common/message'; diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index 8d7d30b7099..5247bd40e71 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -29,8 +29,8 @@ import { TabFocus } from 'vs/editor/common/config/commonEditorConfig'; import { TerminalConfigHelper } from 'vs/workbench/parts/terminal/electron-browser/terminalConfigHelper'; import { TerminalLinkHandler } from 'vs/workbench/parts/terminal/electron-browser/terminalLinkHandler'; import { TerminalWidgetManager } from 'vs/workbench/parts/terminal/browser/terminalWidgetManager'; -import { registerThemingParticipant, ITheme, ICssStyleCollector } from "vs/platform/theme/common/themeService"; -import { scrollbarSliderBackground, scrollbarSliderHoverBackground, scrollbarSliderActiveBackground } from "vs/platform/theme/common/colorRegistry"; +import { registerThemingParticipant, ITheme, ICssStyleCollector } from 'vs/platform/theme/common/themeService'; +import { scrollbarSliderBackground, scrollbarSliderHoverBackground, scrollbarSliderActiveBackground } from 'vs/platform/theme/common/colorRegistry'; /** The amount of time to consider terminal errors to be related to the launch */ const LAUNCHING_DURATION = 500; diff --git a/src/vs/workbench/parts/terminal/test/electron-browser/terminalConfigHelper.test.ts b/src/vs/workbench/parts/terminal/test/electron-browser/terminalConfigHelper.test.ts index 285bc9025ad..2e0b9c5831d 100644 --- a/src/vs/workbench/parts/terminal/test/electron-browser/terminalConfigHelper.test.ts +++ b/src/vs/workbench/parts/terminal/test/electron-browser/terminalConfigHelper.test.ts @@ -10,7 +10,7 @@ import { IConfigurationService, getConfigurationValue } from 'vs/platform/config import { Platform } from 'vs/base/common/platform'; import { TPromise } from 'vs/base/common/winjs.base'; import { TerminalConfigHelper } from 'vs/workbench/parts/terminal/electron-browser/terminalConfigHelper'; -import { EDITOR_FONT_DEFAULTS } from "vs/editor/common/config/editorOptions"; +import { EDITOR_FONT_DEFAULTS } from 'vs/editor/common/config/editorOptions'; class MockConfigurationService implements IConfigurationService { diff --git a/src/vs/workbench/parts/update/electron-browser/releaseNotesEditor.ts b/src/vs/workbench/parts/update/electron-browser/releaseNotesEditor.ts index 466aa77c62d..7f9174f7ca6 100644 --- a/src/vs/workbench/parts/update/electron-browser/releaseNotesEditor.ts +++ b/src/vs/workbench/parts/update/electron-browser/releaseNotesEditor.ts @@ -20,7 +20,7 @@ import { IModeService } from 'vs/editor/common/services/modeService'; import { tokenizeToString } from 'vs/editor/common/modes/textToHtmlTokenizer'; import { IPartService, Parts } from 'vs/workbench/services/part/common/partService'; import { WebviewEditor } from 'vs/workbench/browser/parts/editor/webviewEditor'; -import { IStorageService } from "vs/platform/storage/common/storage"; +import { IStorageService } from 'vs/platform/storage/common/storage'; function renderBody(body: string): string { return ` diff --git a/src/vs/workbench/services/editor/test/browser/editorService.test.ts b/src/vs/workbench/services/editor/test/browser/editorService.test.ts index e1f4057853f..4dd5a44fe16 100644 --- a/src/vs/workbench/services/editor/test/browser/editorService.test.ts +++ b/src/vs/workbench/services/editor/test/browser/editorService.test.ts @@ -16,7 +16,7 @@ import { FileEditorInput } from 'vs/workbench/parts/files/common/editors/fileEdi import { workbenchInstantiationService, TestThemeService } from 'vs/workbench/test/workbenchTestServices'; import { DelegatingWorkbenchEditorService, WorkbenchEditorService, IEditorPart } from 'vs/workbench/services/editor/browser/editorService'; import { UntitledEditorInput } from 'vs/workbench/common/editor/untitledEditorInput'; -import { ResourceEditorInput } from "vs/workbench/common/editor/resourceEditorInput"; +import { ResourceEditorInput } from 'vs/workbench/common/editor/resourceEditorInput'; let activeEditor: BaseEditor = { getSelection: function () { diff --git a/src/vs/workbench/services/themes/electron-browser/colorThemeData.ts b/src/vs/workbench/services/themes/electron-browser/colorThemeData.ts index aa101644f89..f182c1494c8 100644 --- a/src/vs/workbench/services/themes/electron-browser/colorThemeData.ts +++ b/src/vs/workbench/services/themes/electron-browser/colorThemeData.ts @@ -20,7 +20,7 @@ import { Extensions, IColorRegistry, ColorIdentifier, editorBackground, editorFo import { ThemeType } from 'vs/platform/theme/common/themeService'; import { Registry } from 'vs/platform/platform'; import { WorkbenchThemeService, IColorCustomizations } from "vs/workbench/services/themes/electron-browser/workbenchThemeService"; -import { getParseErrorMessage } from "vs/base/common/jsonErrorMessages"; +import { getParseErrorMessage } from 'vs/base/common/jsonErrorMessages'; let colorRegistry = Registry.as(Extensions.ColorContribution); diff --git a/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.ts b/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.ts index 72ad60ffe23..6e41871b060 100644 --- a/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.ts +++ b/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.ts @@ -39,7 +39,7 @@ import pfs = require('vs/base/node/pfs'); import colorThemeSchema = require('vs/workbench/services/themes/common/colorThemeSchema'); import fileIconThemeSchema = require('vs/workbench/services/themes/common/fileIconThemeSchema'); import { IDisposable } from 'vs/base/common/lifecycle'; -import { getParseErrorMessage } from "vs/base/common/jsonErrorMessages"; +import { getParseErrorMessage } from 'vs/base/common/jsonErrorMessages'; // implementation diff --git a/src/vs/workbench/test/browser/parts/editor/baseEditor.test.ts b/src/vs/workbench/test/browser/parts/editor/baseEditor.test.ts index cbdc5139462..4050b580de0 100644 --- a/src/vs/workbench/test/browser/parts/editor/baseEditor.test.ts +++ b/src/vs/workbench/test/browser/parts/editor/baseEditor.test.ts @@ -16,7 +16,7 @@ import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { NullTelemetryService } from 'vs/platform/telemetry/common/telemetryUtils'; import { PLAINTEXT_MODE_ID } from 'vs/editor/common/modes/modesRegistry'; import { workbenchInstantiationService, TestThemeService } from 'vs/workbench/test/workbenchTestServices'; -import { ResourceEditorInput } from "vs/workbench/common/editor/resourceEditorInput"; +import { ResourceEditorInput } from 'vs/workbench/common/editor/resourceEditorInput'; const NullThemeService = new TestThemeService(); diff --git a/src/vs/workbench/test/common/editor/editorDiffModel.test.ts b/src/vs/workbench/test/common/editor/editorDiffModel.test.ts index 2f5901c6e88..2db61acaf4e 100644 --- a/src/vs/workbench/test/common/editor/editorDiffModel.test.ts +++ b/src/vs/workbench/test/common/editor/editorDiffModel.test.ts @@ -12,15 +12,15 @@ import { TextDiffEditorModel } from 'vs/workbench/common/editor/textDiffEditorMo import { DiffEditorInput } from 'vs/workbench/common/editor/diffEditorInput'; import { IModelService } from 'vs/editor/common/services/modelService'; import { IModeService } from 'vs/editor/common/services/modeService'; -import { ResourceEditorInput } from "vs/workbench/common/editor/resourceEditorInput"; -import URI from "vs/base/common/uri"; -import { ITextModelResolverService } from "vs/editor/common/services/resolverService"; -import { ITextFileService } from "vs/workbench/services/textfile/common/textfiles"; -import { IUntitledEditorService } from "vs/workbench/services/untitled/common/untitledEditorService"; -import { TestTextFileService, workbenchInstantiationService } from "vs/workbench/test/workbenchTestServices"; +import { ResourceEditorInput } from 'vs/workbench/common/editor/resourceEditorInput'; +import URI from 'vs/base/common/uri'; +import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; +import { IUntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; +import { TestTextFileService, workbenchInstantiationService } from 'vs/workbench/test/workbenchTestServices'; import { TPromise } from "vs/base/common/winjs.base"; -import { IModel } from "vs/editor/common/editorCommon"; -import { IInstantiationService } from "vs/platform/instantiation/common/instantiation"; +import { IModel } from 'vs/editor/common/editorCommon'; +import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; class MyEditorModel extends EditorModel { } class MyTextEditorModel extends BaseTextEditorModel { } -- GitLab From 03284d80534cf2bc57b777f47783a1475608cd6b Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 25 May 2017 10:44:49 +0200 Subject: [PATCH 0144/1347] a18y: avoid duplicate events when navigating trees (for #26730) --- src/vs/base/parts/tree/browser/treeView.ts | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/src/vs/base/parts/tree/browser/treeView.ts b/src/vs/base/parts/tree/browser/treeView.ts index 117e60db01d..3e27c21e709 100644 --- a/src/vs/base/parts/tree/browser/treeView.ts +++ b/src/vs/base/parts/tree/browser/treeView.ts @@ -197,22 +197,18 @@ export class ViewItem implements IViewItem { // ARIA this.element.setAttribute('role', 'treeitem'); + const ariaLabel = this.context.accessibilityProvider.getAriaLabel(this.context.tree, this.model.getElement()); + if (ariaLabel) { + this.element.setAttribute('aria-label', ariaLabel); + } if (this.model.hasTrait('focused')) { const base64Id = strings.safeBtoa(this.model.id); - const ariaLabel = this.context.accessibilityProvider.getAriaLabel(this.context.tree, this.model.getElement()); this.element.setAttribute('aria-selected', 'true'); this.element.setAttribute('id', base64Id); - if (ariaLabel) { - this.element.setAttribute('aria-label', ariaLabel); - } else { - this.element.setAttribute('aria-labelledby', base64Id); // force screen reader to compute label from children (helps NVDA at least) - } } else { this.element.setAttribute('aria-selected', 'false'); this.element.removeAttribute('id'); - this.element.removeAttribute('aria-label'); - this.element.removeAttribute('aria-labelledby'); } if (this.model.hasChildren()) { this.element.setAttribute('aria-expanded', String(!!this.model.isExpanded())); -- GitLab From e4d9b4d9ed6959c200e464f33cb9b6c00cda52f8 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 25 May 2017 12:06:05 +0200 Subject: [PATCH 0145/1347] clean up unused code --- src/vs/workbench/electron-browser/shell.ts | 23 +++------------------- 1 file changed, 3 insertions(+), 20 deletions(-) diff --git a/src/vs/workbench/electron-browser/shell.ts b/src/vs/workbench/electron-browser/shell.ts index bec5d37606b..da3ce116627 100644 --- a/src/vs/workbench/electron-browser/shell.ts +++ b/src/vs/workbench/electron-browser/shell.ts @@ -62,7 +62,7 @@ import { IContextViewService } from 'vs/platform/contextview/browser/contextView import { ILifecycleService } from 'vs/platform/lifecycle/common/lifecycle'; import { IMarkerService } from 'vs/platform/markers/common/markers'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; -import { IMessageService, IChoiceService, Severity, CloseAction } from 'vs/platform/message/common/message'; +import { IMessageService, IChoiceService, Severity } from 'vs/platform/message/common/message'; import { ChoiceChannel } from 'vs/platform/message/common/messageIpc'; import { ISearchService } from 'vs/platform/search/common/search'; import { IThreadService } from 'vs/workbench/services/thread/common/threadService'; @@ -87,7 +87,6 @@ import { URLChannelClient } from 'vs/platform/url/common/urlIpc'; import { IURLService } from 'vs/platform/url/common/url'; import { IBackupService } from 'vs/platform/backup/common/backup'; import { BackupChannelClient } from 'vs/platform/backup/common/backupIpc'; -import { ReportPerformanceIssueAction } from 'vs/workbench/electron-browser/actions'; import { ExtensionHostProcessWorker } from 'vs/workbench/electron-browser/extensionHost'; import { ITimerService } from 'vs/workbench/services/timer/common/timerService'; import { remote, ipcRenderer as ipc } from 'electron'; @@ -198,7 +197,7 @@ export class WorkbenchShell { onWorkbenchStarted: (info: IWorkbenchStartedInfo) => { // run workbench started logic - this.onWorkbenchStarted(instantiationService, info); + this.onWorkbenchStarted(info); // start cached data manager instantiationService.createInstance(NodeCachedDataManager); @@ -221,7 +220,7 @@ export class WorkbenchShell { return workbenchContainer; } - private onWorkbenchStarted(instantiationService: IInstantiationService, info: IWorkbenchStartedInfo): void { + private onWorkbenchStarted(info: IWorkbenchStartedInfo): void { // Telemetry: workspace info const { filesToOpen, filesToCreate, filesToDiff } = this.options; @@ -248,12 +247,6 @@ export class WorkbenchShell { this.timerService.restoreViewletDuration = info.restoreViewletDuration; this.extensionService.onReady().done(() => { this.telemetryService.publicLog('startupTime', this.timerService.startupMetrics); - - // Check for negative performance numbers (insiders only) - // TODO@Ben remove me - if (product.quality !== 'stable' && this.timerService.startupMetrics.ellapsed < 0) { - this.handleNegativePerformanceNumbers(instantiationService, this.timerService.startupMetrics.ellapsed); - } }); // Telemetry: workspace tags @@ -266,16 +259,6 @@ export class WorkbenchShell { } } - private handleNegativePerformanceNumbers(i: IInstantiationService, time: number): void { - this.messageService.show(Severity.Warning, { - message: `Something went wrong measuring startup performance numbers (ellapsed: ${time}ms). We would like to learn more about this issue.`, - actions: [ - i.createInstance(ReportPerformanceIssueAction, ReportPerformanceIssueAction.ID, ReportPerformanceIssueAction.LABEL), - CloseAction - ] - }); - } - private initServiceCollection(container: HTMLElement): [IInstantiationService, ServiceCollection] { const disposables = new Disposables(); -- GitLab From 8ee8d60b837b978c807a06a3800bfacd4fba53b0 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 25 May 2017 12:16:33 +0200 Subject: [PATCH 0146/1347] Uncaught TypeError: Cannot read property 'isActive' of undefined (fixes #27257) --- src/vs/workbench/browser/parts/editor/tabsTitleControl.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts b/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts index 39993429952..de3fda8a4d5 100644 --- a/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts +++ b/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts @@ -212,7 +212,7 @@ export class TabsTitleControl extends TitleControl { private updateDropFeedback(element: HTMLElement, isDND: boolean, index?: number): void { const isTab = (typeof index === 'number'); - const isActiveTab = isTab && this.context.isActive(this.context.getEditor(index)); + const isActiveTab = isTab && this.context && this.context.isActive(this.context.getEditor(index)); // Background const noDNDBackgroundColor = isTab ? this.getColor(isActiveTab ? TAB_ACTIVE_BACKGROUND : TAB_INACTIVE_BACKGROUND) : null; -- GitLab From 51a10b5ebe173ff28ef55f4dde9579778dc42295 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 25 May 2017 12:21:18 +0200 Subject: [PATCH 0147/1347] theming - fix color clash when dragging over selected or focused item --- src/vs/base/parts/tree/browser/treeView.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/base/parts/tree/browser/treeView.ts b/src/vs/base/parts/tree/browser/treeView.ts index 3e27c21e709..fbbef901f54 100644 --- a/src/vs/base/parts/tree/browser/treeView.ts +++ b/src/vs/base/parts/tree/browser/treeView.ts @@ -602,7 +602,7 @@ export class TreeView extends HeightMap { if (styles.listDropBackground) { content.push(` .monaco-tree.monaco-tree-instance-${this.instance} .monaco-tree-wrapper.drop-target, - .monaco-tree.monaco-tree-instance-${this.instance} .monaco-tree-rows > .monaco-tree-row.drop-target { background-color: ${styles.listDropBackground} !important; } + .monaco-tree.monaco-tree-instance-${this.instance} .monaco-tree-rows > .monaco-tree-row.drop-target { background-color: ${styles.listDropBackground} !important; color: inherit !important; } `); } -- GitLab From d264b70f2015d7469385bd156a57dd8663921dbb Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 09:24:50 +0200 Subject: [PATCH 0148/1347] [docker] update grammar --- build/npm/update-grammar.js | 30 ++++++++++++------- extensions/docker/package.json | 2 +- .../docker/syntaxes/docker.tmLanguage.json | 7 +++-- 3 files changed, 26 insertions(+), 13 deletions(-) diff --git a/build/npm/update-grammar.js b/build/npm/update-grammar.js index 4b0408b89b2..dbb12cdcb44 100644 --- a/build/npm/update-grammar.js +++ b/build/npm/update-grammar.js @@ -25,19 +25,28 @@ function getOptions(urlString) { } } -function download(url) { -return new Promise((c, e) => { - var content = ''; - var request = https.get(getOptions(url), function (response) { +function download(url, redirectCount) { + return new Promise((c, e) => { + var content = ''; + https.get(getOptions(url), function (response) { response.on('data', function (data) { content += data.toString(); }).on('end', function () { + let count = redirectCount || 0; + if (count < 5 && response.statusCode >= 300 && response.statusCode <= 303 || response.statusCode === 307) { + let location = response.headers['location']; + if (location) { + console.log("Redirected " + url + " to " + location); + download(location, count+1).then(c, e); + return; + } + } c(content); }); }).on('error', function (err) { e(err.message); }); -}); + }); } function getCommitSha(repoId, repoPath) { @@ -46,14 +55,15 @@ function getCommitSha(repoId, repoPath) { try { let lastCommit = JSON.parse(content)[0]; return Promise.resolve({ - commitSha : lastCommit.sha, - commitDate : lastCommit.commit.author.date + commitSha: lastCommit.sha, + commitDate: lastCommit.commit.author.date }); } catch (e) { + console.error("Failed extracting the SHA: " + content); return Promise.resolve(null); } }, function () { - console.err('Failed loading ' + commitInfo); + console.error('Failed loading ' + commitInfo); return Promise.resolve(null); }); } @@ -97,7 +107,7 @@ exports.update = function (repoId, repoPath, dest, modifyGrammar) { } if (path.basename(process.argv[1]) === 'update-grammar.js') { - for (var i = 3; i < process.argv.length; i+=2) { - exports.update(process.argv[2], process.argv[i], process.argv[i+1]); + for (var i = 3; i < process.argv.length; i += 2) { + exports.update(process.argv[2], process.argv[i], process.argv[i + 1]); } } diff --git a/extensions/docker/package.json b/extensions/docker/package.json index 0da40007bc6..e58f0826419 100644 --- a/extensions/docker/package.json +++ b/extensions/docker/package.json @@ -4,7 +4,7 @@ "publisher": "vscode", "engines": { "vscode": "*" }, "scripts": { - "update-grammar": "node ../../build/npm/update-grammar.js docker/docker contrib/syntax/textmate/Docker.tmbundle/Syntaxes/Dockerfile.tmLanguage ./syntaxes/docker.tmLanguage.json" + "update-grammar": "node ../../build/npm/update-grammar.js moby/moby contrib/syntax/textmate/Docker.tmbundle/Syntaxes/Dockerfile.tmLanguage ./syntaxes/docker.tmLanguage.json" }, "contributes": { "languages": [{ diff --git a/extensions/docker/syntaxes/docker.tmLanguage.json b/extensions/docker/syntaxes/docker.tmLanguage.json index caab35092b0..8be1c94055d 100644 --- a/extensions/docker/syntaxes/docker.tmLanguage.json +++ b/extensions/docker/syntaxes/docker.tmLanguage.json @@ -8,9 +8,12 @@ "captures": { "1": { "name": "keyword.other.special-method.dockerfile" + }, + "2": { + "name": "keyword.other.special-method.dockerfile" } }, - "match": "\\s*(?:(FROM|AS))\\s" + "match": "^\\s*\\b(FROM)\\b.*?\\b(AS)\\b" }, { "captures": { @@ -94,5 +97,5 @@ ], "scopeName": "source.dockerfile", "uuid": "a39d8795-59d2-49af-aa00-fe74ee29576e", - "version": "https://github.com/moby/moby/commit/4cb71f80823af345d063cf0ad657e73ce9caa75f" + "version": "https://github.com/moby/moby/commit/8523e9d108a0e98865673701a7bd0a7929c5260b" } \ No newline at end of file -- GitLab From 2d811977f822871792e603718edd5f34f2fde4f7 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 09:35:58 +0200 Subject: [PATCH 0149/1347] [scss] update grammar --- extensions/scss/syntaxes/scss.json | 29 +- .../test-cssvariables_scss.json | 12 +- .../scss/test/colorize-results/test_scss.json | 536 +++++++++--------- 3 files changed, 277 insertions(+), 300 deletions(-) diff --git a/extensions/scss/syntaxes/scss.json b/extensions/scss/syntaxes/scss.json index 1f09bd75e56..252cb843115 100644 --- a/extensions/scss/syntaxes/scss.json +++ b/extensions/scss/syntaxes/scss.json @@ -890,15 +890,6 @@ } ] }, - "constant_hex": { - "captures": { - "1": { - "name": "punctuation.definition.constant.scss" - } - }, - "match": "(#)([0-9a-fA-F]{3}|[0-9a-fA-F]{6})\\b", - "name": "constant.numeric.color.hex-value.scss" - }, "constant_important": { "match": "!important", "name": "keyword.other.important.scss" @@ -907,10 +898,6 @@ "match": "\\b(\\+|-|\\*|/)\\b", "name": "support.constant.mathematical-symbols.scss" }, - "constant_number": { - "match": "(\\b([0-9]+(\\.[0-9]+)?)|\\B\\.[0-9]+)(?=\\s*(ch|cm|deg|dpi|dpcm|dppx|em|ex|grad|in|mm|mozmm|ms|pc|pt|px|rad|rem|turn|s|vh|vmin|vmax|vw|\\b))", - "name": "constant.numeric.scss" - }, "constant_optional": { "match": "!optional", "name": "keyword.other.optional.scss" @@ -937,10 +924,6 @@ } ] }, - "constant_unit": { - "match": "(?<=[\\d])(ch|cm|deg|dpi|dpcm|dppx|em|ex|grad|in|mm|mozmm|ms|pc|pt|px|rad|rem|turn|s|vh|vmin|vmax|vw)\\b|%", - "name": "keyword.other.unit.scss" - }, "flow_control": { "patterns": [ { @@ -1242,9 +1225,6 @@ { "include": "#constant_sass_functions" }, - { - "include": "#constant_hex" - }, { "include": "#constant_important" }, @@ -1255,10 +1235,7 @@ "include": "#constant_optional" }, { - "include": "#constant_unit" - }, - { - "include": "#constant_number" + "include": "source.css#numeric-values" }, { "include": "source.css#property-keywords" @@ -1543,7 +1520,7 @@ }, { "match": "\\d+", - "name": "constant.numeric.scss" + "name": "constant.numeric.css" }, { "match": "(?<=\\d)n\\b|\\b(n|even|odd)\\b", @@ -1698,5 +1675,5 @@ "name": "variable.scss" } }, - "version": "https://github.com/atom/language-sass/commit/f477576a0ff819657495142f7e64e577a837fadb" + "version": "https://github.com/atom/language-sass/commit/8b8b7b52655ab5cf4dbe597443abe4b078bb6953" } \ No newline at end of file diff --git a/extensions/scss/test/colorize-results/test-cssvariables_scss.json b/extensions/scss/test/colorize-results/test-cssvariables_scss.json index ff30ea6b973..e51a05d345f 100644 --- a/extensions/scss/test/colorize-results/test-cssvariables_scss.json +++ b/extensions/scss/test/colorize-results/test-cssvariables_scss.json @@ -89,7 +89,7 @@ }, { "c": "6", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -100,7 +100,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -177,7 +177,7 @@ }, { "c": "4", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -397,7 +397,7 @@ }, { "c": "4", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -496,7 +496,7 @@ }, { "c": "5", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -507,7 +507,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", diff --git a/extensions/scss/test/colorize-results/test_scss.json b/extensions/scss/test/colorize-results/test_scss.json index 4f699f59ebf..ffcdbc7f034 100644 --- a/extensions/scss/test/colorize-results/test_scss.json +++ b/extensions/scss/test/colorize-results/test_scss.json @@ -287,7 +287,7 @@ }, { "c": "97", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -298,7 +298,7 @@ }, { "c": "%", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -430,7 +430,7 @@ }, { "c": "2", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -441,7 +441,7 @@ }, { "c": "em", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.em.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -705,7 +705,7 @@ }, { "c": "3", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -716,7 +716,7 @@ }, { "c": "em", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.em.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -1332,7 +1332,7 @@ }, { "c": "2", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -1343,7 +1343,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -1365,7 +1365,7 @@ }, { "c": "3", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -1376,7 +1376,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -1486,7 +1486,7 @@ }, { "c": "30", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -1497,7 +1497,7 @@ }, { "c": "em", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.em.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -1849,7 +1849,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -1937,7 +1937,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -1948,7 +1948,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -2157,7 +2157,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -2278,7 +2278,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -2839,7 +2839,7 @@ }, { "c": "5", - "t": "source.css.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -2850,7 +2850,7 @@ }, { "c": "em", - "t": "source.css.scss meta.set.variable.scss keyword.other.unit.scss", + "t": "source.css.scss meta.set.variable.scss constant.numeric.css keyword.other.unit.em.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -3059,7 +3059,7 @@ }, { "c": "6", - "t": "source.css.scss meta.property-list.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -3070,7 +3070,7 @@ }, { "c": "em", - "t": "source.css.scss meta.property-list.scss meta.set.variable.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css keyword.other.unit.em.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -3202,7 +3202,7 @@ }, { "c": "12", - "t": "source.css.scss meta.property-list.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -3213,7 +3213,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.set.variable.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -3279,7 +3279,7 @@ }, { "c": "30", - "t": "source.css.scss meta.property-list.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -3290,7 +3290,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.set.variable.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -3862,7 +3862,7 @@ }, { "c": "100", - "t": "source.css.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -3895,7 +3895,7 @@ }, { "c": "100", - "t": "source.css.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -3928,7 +3928,7 @@ }, { "c": "225", - "t": "source.css.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -3961,7 +3961,7 @@ }, { "c": "0.25", - "t": "source.css.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -4137,7 +4137,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -4148,7 +4148,7 @@ }, { "c": "em", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.em.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -4192,7 +4192,7 @@ }, { "c": "2", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -4203,7 +4203,7 @@ }, { "c": "em", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.em.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -4258,7 +4258,7 @@ }, { "c": "3", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -4324,24 +4324,24 @@ }, { "c": "#", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "010203", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -4379,24 +4379,24 @@ }, { "c": "#", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "040506", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -4577,7 +4577,7 @@ }, { "c": "3", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -4588,7 +4588,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -4632,7 +4632,7 @@ }, { "c": "4", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -4643,7 +4643,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -4764,7 +4764,7 @@ }, { "c": "5", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss string.quoted.double.scss variable.interpolation.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss string.quoted.double.scss variable.interpolation.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -4808,7 +4808,7 @@ }, { "c": "10", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss string.quoted.double.scss variable.interpolation.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss string.quoted.double.scss variable.interpolation.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -4929,7 +4929,7 @@ }, { "c": "0", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -4962,7 +4962,7 @@ }, { "c": "100", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -4973,7 +4973,7 @@ }, { "c": "%", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -5006,7 +5006,7 @@ }, { "c": "50", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -5017,7 +5017,7 @@ }, { "c": "%", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -5149,7 +5149,7 @@ }, { "c": "0", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -5215,7 +5215,7 @@ }, { "c": "100", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -5226,7 +5226,7 @@ }, { "c": "%", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -5292,7 +5292,7 @@ }, { "c": "50", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -5303,7 +5303,7 @@ }, { "c": "%", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -5413,7 +5413,7 @@ }, { "c": "40", - "t": "source.css.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -5424,7 +5424,7 @@ }, { "c": "px", - "t": "source.css.scss meta.set.variable.scss keyword.other.unit.scss", + "t": "source.css.scss meta.set.variable.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -5479,7 +5479,7 @@ }, { "c": "10", - "t": "source.css.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -5490,7 +5490,7 @@ }, { "c": "px", - "t": "source.css.scss meta.set.variable.scss keyword.other.unit.scss", + "t": "source.css.scss meta.set.variable.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -5798,7 +5798,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.at-rule.return.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.at-rule.return.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -5996,7 +5996,7 @@ }, { "c": "5", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -6722,7 +6722,7 @@ }, { "c": "300", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -6733,7 +6733,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -6975,7 +6975,7 @@ }, { "c": "500", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -6986,7 +6986,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -7162,7 +7162,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -7173,7 +7173,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -7195,24 +7195,24 @@ }, { "c": "#", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "f00", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -7272,24 +7272,24 @@ }, { "c": "#", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "fdd", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -7459,7 +7459,7 @@ }, { "c": "3", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -7470,7 +7470,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -7756,7 +7756,7 @@ }, { "c": "2", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -7767,7 +7767,7 @@ }, { "c": "em", - "t": "source.css.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.em.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -8438,7 +8438,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -8449,7 +8449,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -8823,7 +8823,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -8834,7 +8834,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -9274,7 +9274,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -9318,7 +9318,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -9362,7 +9362,7 @@ }, { "c": "2", - "t": "source.css.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -9439,7 +9439,7 @@ }, { "c": "1", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -9450,7 +9450,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -9560,7 +9560,7 @@ }, { "c": "5", - "t": "source.css.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -9604,7 +9604,7 @@ }, { "c": "3", - "t": "source.css.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -9681,7 +9681,7 @@ }, { "c": "2", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -9692,7 +9692,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -9857,7 +9857,7 @@ }, { "c": "3", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -9868,7 +9868,7 @@ }, { "c": "px", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -10495,7 +10495,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.for.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.for.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -10539,7 +10539,7 @@ }, { "c": "3", - "t": "source.css.scss meta.at-rule.for.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.for.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -10704,7 +10704,7 @@ }, { "c": "2", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -10715,7 +10715,7 @@ }, { "c": "em", - "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.em.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -11298,7 +11298,7 @@ }, { "c": "6", - "t": "source.css.scss meta.at-rule.each.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -11397,7 +11397,7 @@ }, { "c": "0", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -11562,7 +11562,7 @@ }, { "c": "2", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -11573,7 +11573,7 @@ }, { "c": "em", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.em.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -11749,7 +11749,7 @@ }, { "c": "2", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -12035,7 +12035,7 @@ }, { "c": "0", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.for.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.for.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -12387,7 +12387,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.at-rule.if.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -12475,7 +12475,7 @@ }, { "c": "100", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -12486,7 +12486,7 @@ }, { "c": "%", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -12970,7 +12970,7 @@ }, { "c": "20", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -12981,7 +12981,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -13135,24 +13135,24 @@ }, { "c": "#", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "ff0000", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -13333,7 +13333,7 @@ }, { "c": "4", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -13344,7 +13344,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -13520,7 +13520,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.at-rule.mixin.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.at-rule.mixin.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -13531,7 +13531,7 @@ }, { "c": "in", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.at-rule.mixin.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.at-rule.mixin.scss constant.numeric.css keyword.other.unit.in.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -14455,7 +14455,7 @@ }, { "c": "0", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -14466,7 +14466,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -14488,7 +14488,7 @@ }, { "c": "4", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -14499,7 +14499,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -14521,7 +14521,7 @@ }, { "c": "5", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -14532,7 +14532,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -14554,24 +14554,24 @@ }, { "c": "#", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "666", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -14587,7 +14587,7 @@ }, { "c": "2", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -14598,7 +14598,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -14620,7 +14620,7 @@ }, { "c": "6", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -14631,7 +14631,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -14653,7 +14653,7 @@ }, { "c": "10", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -14664,7 +14664,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -14686,24 +14686,24 @@ }, { "c": "#", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "999", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.include.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -15148,24 +15148,24 @@ }, { "c": "#", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "ff0000", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -15181,24 +15181,24 @@ }, { "c": "#", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "00ff00", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -15214,24 +15214,24 @@ }, { "c": "#", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "0000ff", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -16479,7 +16479,7 @@ }, { "c": "4", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -16490,7 +16490,7 @@ }, { "c": "cm", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.cm.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -16556,7 +16556,7 @@ }, { "c": "3", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -16567,7 +16567,7 @@ }, { "c": "cm", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.cm.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -16798,7 +16798,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -16809,7 +16809,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -17084,7 +17084,7 @@ }, { "c": "0", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.set.variable.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -17128,24 +17128,24 @@ }, { "c": "#", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss punctuation.definition.constant.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css punctuation.definition.constant.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { "c": "123", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.color.hex-value.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.other.color.rgb-value.hex.css", "r": { - "dark_plus": "constant.numeric: #B5CEA8", - "light_plus": "constant.numeric: #09885A", - "dark_vs": "constant.numeric: #B5CEA8", - "light_vs": "constant.numeric: #09885A", - "hc_black": "constant.numeric: #B5CEA8" + "dark_plus": "constant.other.color.rgb-value: #CE9178", + "light_plus": "constant.other.color.rgb-value: #0451A5", + "dark_vs": "default: #D4D4D4", + "light_vs": "constant.other.color.rgb-value: #0451A5", + "hc_black": "constant.other.color.rgb-value: #CE9178" } }, { @@ -17205,7 +17205,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -17656,7 +17656,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -17667,7 +17667,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -17777,7 +17777,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -17788,7 +17788,7 @@ }, { "c": "px", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss keyword.other.unit.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -18470,7 +18470,7 @@ }, { "c": "0", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -18569,7 +18569,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -18701,7 +18701,7 @@ }, { "c": "2", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -18811,7 +18811,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -19009,7 +19009,7 @@ }, { "c": "0", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -19141,7 +19141,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -19328,7 +19328,7 @@ }, { "c": "0", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -19460,7 +19460,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -19647,7 +19647,7 @@ }, { "c": "0", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -19757,7 +19757,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.property-list.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -19966,7 +19966,7 @@ }, { "c": "0", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", @@ -20098,7 +20098,7 @@ }, { "c": "1", - "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.scss", + "t": "source.css.scss meta.at-rule.each.scss meta.at-rule.while.scss meta.property-list.scss meta.at-rule.keyframes.scss meta.property-list.scss meta.property-value.scss constant.numeric.css", "r": { "dark_plus": "constant.numeric: #B5CEA8", "light_plus": "constant.numeric: #09885A", -- GitLab From d57a3ab57e274b315b16545bae70da5db37c1ce2 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 10:36:09 +0200 Subject: [PATCH 0150/1347] [ini] add update script --- extensions/ini/package.json | 11 +- extensions/ini/syntaxes/ini.tmLanguage.json | 114 +++++++++++ extensions/ini/syntaxes/properties.plist | 181 ------------------ .../ini/test/colorize-results/test_ini.json | 54 +++--- 4 files changed, 148 insertions(+), 212 deletions(-) create mode 100644 extensions/ini/syntaxes/ini.tmLanguage.json delete mode 100644 extensions/ini/syntaxes/properties.plist diff --git a/extensions/ini/package.json b/extensions/ini/package.json index b6a9b6c37d0..bfb7bb52215 100644 --- a/extensions/ini/package.json +++ b/extensions/ini/package.json @@ -3,6 +3,9 @@ "version": "0.1.0", "publisher": "vscode", "engines": { "vscode": "*" }, + "scripts": { + "update-grammar": "node ../../build/npm/update-grammar.js textmate/ini.tmbundle Syntaxes/Ini.plist ./syntaxes/ini.tmLanguage.json" + }, "contributes": { "languages": [{ "id": "ini", @@ -19,12 +22,12 @@ }], "grammars": [{ "language": "ini", - "scopeName": "source.properties", - "path": "./syntaxes/properties.plist" + "scopeName": "source.ini", + "path": "./syntaxes/ini.tmLanguage.json" },{ "language": "properties", - "scopeName": "source.properties", - "path": "./syntaxes/properties.plist" + "scopeName": "source.ini", + "path": "./syntaxes/ini.tmLanguage.json" }] } } diff --git a/extensions/ini/syntaxes/ini.tmLanguage.json b/extensions/ini/syntaxes/ini.tmLanguage.json new file mode 100644 index 00000000000..e8f1a0ef9b3 --- /dev/null +++ b/extensions/ini/syntaxes/ini.tmLanguage.json @@ -0,0 +1,114 @@ +{ + "fileTypes": [ + "ini", + "conf" + ], + "keyEquivalent": "^~I", + "name": "Ini", + "patterns": [ + { + "begin": "(^[ \\t]+)?(?=#)", + "beginCaptures": { + "1": { + "name": "punctuation.whitespace.comment.leading.ini" + } + }, + "end": "(?!\\G)", + "patterns": [ + { + "begin": "#", + "beginCaptures": { + "0": { + "name": "punctuation.definition.comment.ini" + } + }, + "end": "\\n", + "name": "comment.line.number-sign.ini" + } + ] + }, + { + "begin": "(^[ \\t]+)?(?=;)", + "beginCaptures": { + "1": { + "name": "punctuation.whitespace.comment.leading.ini" + } + }, + "end": "(?!\\G)", + "patterns": [ + { + "begin": ";", + "beginCaptures": { + "0": { + "name": "punctuation.definition.comment.ini" + } + }, + "end": "\\n", + "name": "comment.line.semicolon.ini" + } + ] + }, + { + "captures": { + "1": { + "name": "keyword.other.definition.ini" + }, + "2": { + "name": "punctuation.separator.key-value.ini" + } + }, + "match": "\\b([a-zA-Z0-9_.-]+)\\b\\s*(=)" + }, + { + "captures": { + "1": { + "name": "punctuation.definition.entity.ini" + }, + "3": { + "name": "punctuation.definition.entity.ini" + } + }, + "match": "^(\\[)(.*?)(\\])", + "name": "entity.name.section.group-title.ini" + }, + { + "begin": "'", + "beginCaptures": { + "0": { + "name": "punctuation.definition.string.begin.ini" + } + }, + "end": "'", + "endCaptures": { + "0": { + "name": "punctuation.definition.string.end.ini" + } + }, + "name": "string.quoted.single.ini", + "patterns": [ + { + "match": "\\\\.", + "name": "constant.character.escape.ini" + } + ] + }, + { + "begin": "\"", + "beginCaptures": { + "0": { + "name": "punctuation.definition.string.begin.ini" + } + }, + "end": "\"", + "endCaptures": { + "0": { + "name": "punctuation.definition.string.end.ini" + } + }, + "name": "string.quoted.double.ini" + } + ], + "scopeName": "source.ini", + "uuid": "77DC23B6-8A90-11D9-BAA4-000A9584EC8C", + "version": "https://github.com/textmate/ini.tmbundle/commit/2af0cbb0704940f967152616f2f1ff0aae6287a6" +} \ No newline at end of file diff --git a/extensions/ini/syntaxes/properties.plist b/extensions/ini/syntaxes/properties.plist deleted file mode 100644 index 11436566bd5..00000000000 --- a/extensions/ini/syntaxes/properties.plist +++ /dev/null @@ -1,181 +0,0 @@ - - - - - fileTypes - - ini - conf - - keyEquivalent - ^~I - name - Ini - patterns - - - begin - (^[ \t]+)?(?=#) - beginCaptures - - 1 - - name - punctuation.whitespace.comment.leading.ini - - - end - (?!\G) - patterns - - - begin - # - beginCaptures - - 0 - - name - punctuation.definition.comment.ini - - - end - \n - name - comment.line.number-sign.ini - - - - - begin - (^[ \t]+)?(?=;) - beginCaptures - - 1 - - name - punctuation.whitespace.comment.leading.ini - - - end - (?!\G) - patterns - - - begin - ; - beginCaptures - - 0 - - name - punctuation.definition.comment.ini - - - end - \n - name - comment.line.semicolon.ini - - - - - captures - - 1 - - name - keyword.other.definition.ini - - 2 - - name - punctuation.separator.key-value.ini - - - match - \b([a-zA-Z0-9_.-]+)\b\s*(=) - - - captures - - 1 - - name - punctuation.definition.entity.ini - - 3 - - name - punctuation.definition.entity.ini - - - match - ^(\[)(.*?)(\]) - name - entity.name.section.group-title.ini - - - begin - ' - beginCaptures - - 0 - - name - punctuation.definition.string.begin.ini - - - end - ' - endCaptures - - 0 - - name - punctuation.definition.string.end.ini - - - name - string.quoted.single.ini - patterns - - - match - \\. - name - constant.character.escape.ini - - - - - begin - " - beginCaptures - - 0 - - name - punctuation.definition.string.begin.ini - - - end - " - endCaptures - - 0 - - name - punctuation.definition.string.end.ini - - - name - string.quoted.double.ini - - - scopeName - source.properties - uuid - 77DC23B6-8A90-11D9-BAA4-000A9584EC8C - - \ No newline at end of file diff --git a/extensions/ini/test/colorize-results/test_ini.json b/extensions/ini/test/colorize-results/test_ini.json index f30cdc53892..5b001c68246 100644 --- a/extensions/ini/test/colorize-results/test_ini.json +++ b/extensions/ini/test/colorize-results/test_ini.json @@ -1,7 +1,7 @@ [ { "c": ";", - "t": "source.properties comment.line.semicolon.ini punctuation.definition.comment.ini", + "t": "source.ini comment.line.semicolon.ini punctuation.definition.comment.ini", "r": { "dark_plus": "comment: #608B4E", "light_plus": "comment: #008000", @@ -12,7 +12,7 @@ }, { "c": " last modified 1 April 2001 by John Doe", - "t": "source.properties comment.line.semicolon.ini", + "t": "source.ini comment.line.semicolon.ini", "r": { "dark_plus": "comment: #608B4E", "light_plus": "comment: #008000", @@ -23,7 +23,7 @@ }, { "c": "[", - "t": "source.properties entity.name.section.group-title.ini punctuation.definition.entity.ini", + "t": "source.ini entity.name.section.group-title.ini punctuation.definition.entity.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -34,7 +34,7 @@ }, { "c": "owner", - "t": "source.properties entity.name.section.group-title.ini", + "t": "source.ini entity.name.section.group-title.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -45,7 +45,7 @@ }, { "c": "]", - "t": "source.properties entity.name.section.group-title.ini punctuation.definition.entity.ini", + "t": "source.ini entity.name.section.group-title.ini punctuation.definition.entity.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -56,7 +56,7 @@ }, { "c": "name", - "t": "source.properties keyword.other.definition.ini", + "t": "source.ini keyword.other.definition.ini", "r": { "dark_plus": "keyword: #569CD6", "light_plus": "keyword: #0000FF", @@ -67,7 +67,7 @@ }, { "c": "=", - "t": "source.properties punctuation.separator.key-value.ini", + "t": "source.ini punctuation.separator.key-value.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -78,7 +78,7 @@ }, { "c": "John Doe", - "t": "source.properties", + "t": "source.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -89,7 +89,7 @@ }, { "c": "organization", - "t": "source.properties keyword.other.definition.ini", + "t": "source.ini keyword.other.definition.ini", "r": { "dark_plus": "keyword: #569CD6", "light_plus": "keyword: #0000FF", @@ -100,7 +100,7 @@ }, { "c": "=", - "t": "source.properties punctuation.separator.key-value.ini", + "t": "source.ini punctuation.separator.key-value.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -111,7 +111,7 @@ }, { "c": "Acme Widgets Inc.", - "t": "source.properties", + "t": "source.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -122,7 +122,7 @@ }, { "c": "[", - "t": "source.properties entity.name.section.group-title.ini punctuation.definition.entity.ini", + "t": "source.ini entity.name.section.group-title.ini punctuation.definition.entity.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -133,7 +133,7 @@ }, { "c": "database", - "t": "source.properties entity.name.section.group-title.ini", + "t": "source.ini entity.name.section.group-title.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -144,7 +144,7 @@ }, { "c": "]", - "t": "source.properties entity.name.section.group-title.ini punctuation.definition.entity.ini", + "t": "source.ini entity.name.section.group-title.ini punctuation.definition.entity.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -155,7 +155,7 @@ }, { "c": ";", - "t": "source.properties comment.line.semicolon.ini punctuation.definition.comment.ini", + "t": "source.ini comment.line.semicolon.ini punctuation.definition.comment.ini", "r": { "dark_plus": "comment: #608B4E", "light_plus": "comment: #008000", @@ -166,7 +166,7 @@ }, { "c": " use IP address in case network name resolution is not working", - "t": "source.properties comment.line.semicolon.ini", + "t": "source.ini comment.line.semicolon.ini", "r": { "dark_plus": "comment: #608B4E", "light_plus": "comment: #008000", @@ -177,7 +177,7 @@ }, { "c": "server", - "t": "source.properties keyword.other.definition.ini", + "t": "source.ini keyword.other.definition.ini", "r": { "dark_plus": "keyword: #569CD6", "light_plus": "keyword: #0000FF", @@ -188,7 +188,7 @@ }, { "c": "=", - "t": "source.properties punctuation.separator.key-value.ini", + "t": "source.ini punctuation.separator.key-value.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -199,7 +199,7 @@ }, { "c": "192.0.2.62", - "t": "source.properties", + "t": "source.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -210,7 +210,7 @@ }, { "c": "port", - "t": "source.properties keyword.other.definition.ini", + "t": "source.ini keyword.other.definition.ini", "r": { "dark_plus": "keyword: #569CD6", "light_plus": "keyword: #0000FF", @@ -221,7 +221,7 @@ }, { "c": "=", - "t": "source.properties punctuation.separator.key-value.ini", + "t": "source.ini punctuation.separator.key-value.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -232,7 +232,7 @@ }, { "c": "143", - "t": "source.properties", + "t": "source.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -243,7 +243,7 @@ }, { "c": "file", - "t": "source.properties keyword.other.definition.ini", + "t": "source.ini keyword.other.definition.ini", "r": { "dark_plus": "keyword: #569CD6", "light_plus": "keyword: #0000FF", @@ -254,7 +254,7 @@ }, { "c": "=", - "t": "source.properties punctuation.separator.key-value.ini", + "t": "source.ini punctuation.separator.key-value.ini", "r": { "dark_plus": "default: #D4D4D4", "light_plus": "default: #000000", @@ -265,7 +265,7 @@ }, { "c": "\"", - "t": "source.properties string.quoted.double.ini punctuation.definition.string.begin.ini", + "t": "source.ini string.quoted.double.ini punctuation.definition.string.begin.ini", "r": { "dark_plus": "string: #CE9178", "light_plus": "string: #A31515", @@ -276,7 +276,7 @@ }, { "c": "payroll.dat", - "t": "source.properties string.quoted.double.ini", + "t": "source.ini string.quoted.double.ini", "r": { "dark_plus": "string: #CE9178", "light_plus": "string: #A31515", @@ -287,7 +287,7 @@ }, { "c": "\"", - "t": "source.properties string.quoted.double.ini punctuation.definition.string.end.ini", + "t": "source.ini string.quoted.double.ini punctuation.definition.string.end.ini", "r": { "dark_plus": "string: #CE9178", "light_plus": "string: #A31515", -- GitLab From 984750930c8623f1a31c653495919a66cde5f216 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 11:27:32 +0200 Subject: [PATCH 0151/1347] update all grammars script --- build/npm/update-all-grammars.js | 74 ++++++++++++++++++++++++++++++ extensions/typescript/package.json | 2 +- package.json | 3 +- 3 files changed, 77 insertions(+), 2 deletions(-) create mode 100644 build/npm/update-all-grammars.js diff --git a/build/npm/update-all-grammars.js b/build/npm/update-all-grammars.js new file mode 100644 index 00000000000..252b0f4edcb --- /dev/null +++ b/build/npm/update-all-grammars.js @@ -0,0 +1,74 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +const cp = require('child_process'); +const npm = process.platform === 'win32' ? 'npm.cmd' : 'npm'; +const integrationTests = process.platform === 'win32' ? '.\test-integration.bat' : './test-integration.sh'; + +function updateGrammar(location) { + const result = cp.spawnSync(npm, ['run', 'update-grammar'], { + cwd: location, + stdio: 'inherit' + }); + + if (result.error || result.status !== 0) { + process.exit(1); + } +} + +const extensions = [ + // 'bat' Grammar no longer available + 'clojure', + 'coffeescript', + 'cpp', + 'csharp', + 'css', + 'diff', + 'docker', + 'fsharp', + 'gitsyntax', + 'go', + 'groovy', + 'handlebars', + 'hlsl', + 'html', + 'ini', + 'java', + // 'javascript', updated through JavaScript + // 'json', customized + 'less', + 'lua', + 'make', + 'markdown', + 'objective-c', + 'perl', + 'php', + // 'powershell', grammar not ready yet, @daviwil will ping when ready + 'pug', + 'python', + 'r', + 'razor', + 'ruby', + 'rust', + 'scss', + 'shaderlab', + 'shellscript', + // 'sql', customized, PRs pending + 'swift', + 'typescript', + 'vb', + 'xml', + 'yaml' +]; + +extensions.forEach(extension => updateGrammar(`extensions/${extension}`)); + +// run integration tests + +if (process.platform === 'win32') { + cp.spawn('.\scripts\test-integration.bat', [], { env: process.env, stdio: 'inherit' }); +} else { + cp.spawn('/bin/bash', ['./scripts/test-integration.sh'], { env: process.env, stdio: 'inherit' }); +} \ No newline at end of file diff --git a/extensions/typescript/package.json b/extensions/typescript/package.json index a24c0c10519..461cb773a4d 100644 --- a/extensions/typescript/package.json +++ b/extensions/typescript/package.json @@ -21,7 +21,7 @@ }, "scripts": { "vscode:prepublish": "node ../../node_modules/gulp/bin/gulp.js --gulpfile ../../build/gulpfile.extensions.js compile-extension:typescript ./tsconfig.json", - "update-grammars": "node ./build/update-grammars.js" + "update-grammar": "node ./build/update-grammars.js" }, "activationEvents": [ "onLanguage:javascript", diff --git a/package.json b/package.json index 236e9d787e5..c31f58f40c9 100644 --- a/package.json +++ b/package.json @@ -18,7 +18,8 @@ "monaco-editor-test": "mocha --only-monaco-editor", "precommit": "node build/gulpfile.hygiene.js", "gulp": "gulp --max_old_space_size=4096", - "7z": "7z" + "7z": "7z", + "update-grammars": "node build/npm/update-all-grammars.js" }, "dependencies": { "applicationinsights": "0.17.1", -- GitLab From b135eef9926bcac95f84c1b63ac43e9ff6038918 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 11:27:46 +0200 Subject: [PATCH 0152/1347] [clojure] update grammar --- .../clojure/syntaxes/clojure.tmLanguage.json | 25 +++++-------------- 1 file changed, 6 insertions(+), 19 deletions(-) diff --git a/extensions/clojure/syntaxes/clojure.tmLanguage.json b/extensions/clojure/syntaxes/clojure.tmLanguage.json index 6e2d50b5ea5..881ce191e1c 100644 --- a/extensions/clojure/syntaxes/clojure.tmLanguage.json +++ b/extensions/clojure/syntaxes/clojure.tmLanguage.json @@ -64,14 +64,11 @@ }, { "include": "#symbol" - }, - { - "include": "#whitespace" } ], "repository": { "comment": { - "begin": ";", + "begin": "(? Date: Thu, 25 May 2017 11:27:59 +0200 Subject: [PATCH 0153/1347] [cpp] update grammar --- extensions/cpp/syntaxes/c++.json | 5 +- .../cpp/test/colorize-results/test_cc.json | 118 +++++++++++++++++- 2 files changed, 118 insertions(+), 5 deletions(-) diff --git a/extensions/cpp/syntaxes/c++.json b/extensions/cpp/syntaxes/c++.json index 0d20c95fb60..7ec3054f58b 100644 --- a/extensions/cpp/syntaxes/c++.json +++ b/extensions/cpp/syntaxes/c++.json @@ -425,6 +425,9 @@ { "match": "\\\\x\\h+", "name": "constant.character.escape.cpp" + }, + { + "include": "source.c#string_placeholder" } ] }, @@ -455,5 +458,5 @@ ] } }, - "version": "https://github.com/atom/language-c/commit/a74c2f967d73e802a67fa6e971a8e8dedf076597" + "version": "https://github.com/atom/language-c/commit/3a269f88b12e512fb9495dc006a1dabf325d3d7f" } \ No newline at end of file diff --git a/extensions/cpp/test/colorize-results/test_cc.json b/extensions/cpp/test/colorize-results/test_cc.json index 3f7be3caeb8..845a693b3ab 100644 --- a/extensions/cpp/test/colorize-results/test_cc.json +++ b/extensions/cpp/test/colorize-results/test_cc.json @@ -110,7 +110,29 @@ } }, { - "c": "num_candidate_ret=%d:", + "c": "num_candidate_ret=", + "t": "source.cpp meta.function.c string.quoted.double.cpp", + "r": { + "dark_plus": "string: #CE9178", + "light_plus": "string: #A31515", + "dark_vs": "string: #CE9178", + "light_vs": "string: #A31515", + "hc_black": "string: #CE9178" + } + }, + { + "c": "%d", + "t": "source.cpp meta.function.c string.quoted.double.cpp constant.other.placeholder.c", + "r": { + "dark_plus": "string: #CE9178", + "light_plus": "string: #A31515", + "dark_vs": "string: #CE9178", + "light_vs": "string: #A31515", + "hc_black": "string: #CE9178" + } + }, + { + "c": ":", "t": "source.cpp meta.function.c string.quoted.double.cpp", "r": { "dark_plus": "string: #CE9178", @@ -407,7 +429,18 @@ } }, { - "c": "%d,", + "c": "%d", + "t": "source.cpp meta.function.c string.quoted.double.cpp constant.other.placeholder.c", + "r": { + "dark_plus": "string: #CE9178", + "light_plus": "string: #A31515", + "dark_vs": "string: #CE9178", + "light_vs": "string: #A31515", + "hc_black": "string: #CE9178" + } + }, + { + "c": ",", "t": "source.cpp meta.function.c string.quoted.double.cpp", "r": { "dark_plus": "string: #CE9178", @@ -1375,7 +1408,29 @@ } }, { - "c": "STYLE=Keramik;TITLE=%s;THEME=%s", + "c": "STYLE=Keramik;TITLE=", + "t": "source.cpp meta.block.c string.quoted.double.cpp", + "r": { + "dark_plus": "string: #CE9178", + "light_plus": "string: #A31515", + "dark_vs": "string: #CE9178", + "light_vs": "string: #A31515", + "hc_black": "string: #CE9178" + } + }, + { + "c": "%s", + "t": "source.cpp meta.block.c string.quoted.double.cpp constant.other.placeholder.c", + "r": { + "dark_plus": "string: #CE9178", + "light_plus": "string: #A31515", + "dark_vs": "string: #CE9178", + "light_vs": "string: #A31515", + "hc_black": "string: #CE9178" + } + }, + { + "c": ";THEME=", "t": "source.cpp meta.block.c string.quoted.double.cpp", "r": { "dark_plus": "string: #CE9178", @@ -1385,6 +1440,17 @@ "hc_black": "string: #CE9178" } }, + { + "c": "%s", + "t": "source.cpp meta.block.c string.quoted.double.cpp constant.other.placeholder.c", + "r": { + "dark_plus": "string: #CE9178", + "light_plus": "string: #A31515", + "dark_vs": "string: #CE9178", + "light_vs": "string: #A31515", + "hc_black": "string: #CE9178" + } + }, { "c": "\"", "t": "source.cpp meta.block.c string.quoted.double.cpp punctuation.definition.string.end.cpp", @@ -1705,7 +1771,51 @@ } }, { - "c": "movw $0x38, %ax; ltr %ax", + "c": "movw $0x38, ", + "t": "source.cpp meta.block.c meta.function-call.c string.quoted.double.cpp", + "r": { + "dark_plus": "string: #CE9178", + "light_plus": "string: #A31515", + "dark_vs": "string: #CE9178", + "light_vs": "string: #A31515", + "hc_black": "string: #CE9178" + } + }, + { + "c": "%a", + "t": "source.cpp meta.block.c meta.function-call.c string.quoted.double.cpp constant.other.placeholder.c", + "r": { + "dark_plus": "string: #CE9178", + "light_plus": "string: #A31515", + "dark_vs": "string: #CE9178", + "light_vs": "string: #A31515", + "hc_black": "string: #CE9178" + } + }, + { + "c": "x; ltr ", + "t": "source.cpp meta.block.c meta.function-call.c string.quoted.double.cpp", + "r": { + "dark_plus": "string: #CE9178", + "light_plus": "string: #A31515", + "dark_vs": "string: #CE9178", + "light_vs": "string: #A31515", + "hc_black": "string: #CE9178" + } + }, + { + "c": "%a", + "t": "source.cpp meta.block.c meta.function-call.c string.quoted.double.cpp constant.other.placeholder.c", + "r": { + "dark_plus": "string: #CE9178", + "light_plus": "string: #A31515", + "dark_vs": "string: #CE9178", + "light_vs": "string: #A31515", + "hc_black": "string: #CE9178" + } + }, + { + "c": "x", "t": "source.cpp meta.block.c meta.function-call.c string.quoted.double.cpp", "r": { "dark_plus": "string: #CE9178", -- GitLab From 3785324cc135d0fb4738f88d0840770d7cc931b0 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 11:28:13 +0200 Subject: [PATCH 0154/1347] [css] update grammar --- extensions/css/syntaxes/css.tmLanguage.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/extensions/css/syntaxes/css.tmLanguage.json b/extensions/css/syntaxes/css.tmLanguage.json index 072b9cd3051..700b6dd3140 100644 --- a/extensions/css/syntaxes/css.tmLanguage.json +++ b/extensions/css/syntaxes/css.tmLanguage.json @@ -1328,7 +1328,7 @@ "name": "keyword.other.unit.${2:/downcase}.css" } }, - "match": "(?xi) (? Date: Thu, 25 May 2017 11:28:39 +0200 Subject: [PATCH 0155/1347] [typescript] update grammar --- .../syntaxes/JavaScript.tmLanguage.json | 181 ++++++++++------- .../test/colorize-results/test_jsx.json | 10 +- .../syntaxes/TypeScript.tmLanguage.json | 183 +++++++++++------- .../syntaxes/TypeScriptReact.tmLanguage.json | 181 ++++++++++------- 4 files changed, 330 insertions(+), 225 deletions(-) diff --git a/extensions/javascript/syntaxes/JavaScript.tmLanguage.json b/extensions/javascript/syntaxes/JavaScript.tmLanguage.json index ec077b65656..d7aabe6479b 100644 --- a/extensions/javascript/syntaxes/JavaScript.tmLanguage.json +++ b/extensions/javascript/syntaxes/JavaScript.tmLanguage.json @@ -74,7 +74,7 @@ "name": "storage.type.js" } }, - "end": "(?=$|;|}|(\\s+(of|in)\\s+))", + "end": "(?=$|^|;|}|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#destructuring-variable" @@ -103,7 +103,7 @@ "name": "meta.definition.variable.js entity.name.function.js" } }, - "end": "(?=$|[;,=}]|(\\s+(of|in)\\s+))", + "end": "(?=$|^|[;,=}]|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#var-single-variable-type-annotation" @@ -118,7 +118,7 @@ "name": "meta.definition.variable.js variable.other.constant.js" } }, - "end": "(?=$|[;,=}]|(\\s+(of|in)\\s+))", + "end": "(?=$|^|[;,=}]|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#var-single-variable-type-annotation" @@ -133,7 +133,7 @@ "name": "meta.definition.variable.js variable.other.readwrite.js" } }, - "end": "(?=$|[;,=}]|(\\s+(of|in)\\s+))", + "end": "(?=$|^|[;,=}]|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#var-single-variable-type-annotation" @@ -160,7 +160,7 @@ { "name": "meta.object-binding-pattern-variable.js", "begin": "(?])|(?<=[\\}>\\]\\)]|[_$[:alpha:]])\\s*(?=\\{)", + "end": "(?=$|^|[,);\\}\\]]|//)|(?==[^>])|(?<=[\\}>\\]\\)]|[_$[:alpha:]])\\s*(?=\\{)", "patterns": [ { "include": "#comment" @@ -2019,7 +2062,7 @@ "name": "punctuation.definition.typeparameters.begin.js" } }, - "end": "(?=$)|(>)", + "end": "(>)", "endCaptures": { "1": { "name": "punctuation.definition.typeparameters.end.js" @@ -2054,7 +2097,7 @@ "name": "keyword.operator.assignment.js" } }, - "end": "(?=$|[,);}\\]])", + "end": "(?=$|^|[,);}\\]])", "patterns": [ { "include": "#expression" @@ -2693,7 +2736,7 @@ "name": "keyword.control.as.js" } }, - "end": "(?=$|[;,:})\\]])", + "end": "(?=$|^|[;,:})\\]])", "patterns": [ { "include": "#type" @@ -2778,7 +2821,7 @@ }, { "name": "meta.arrow.js", - "begin": "(?x) (?:\n (? is on new line\n (\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n ) |\n (\n [<]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=>] # < typeparam extends \n ) |\n # arrow function possible to detect only with => on same line\n (\n (<([^<>=]|=[^<]|\\<([^=<>]|=[^<])+\\>)+>\\s*)? # typeparameters\n \\(([^()]|\\([^()]*\\))*\\) # parameteres\n (\\s*:\\s*(.)*)? # return type\n \\s*=> # arrow operator\n )\n )\n)", + "begin": "(?x) (?:\n (? is on new line\n (\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n ) |\n (\n [<]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=>] # < typeparam extends \n ) |\n # arrow function possible to detect only with => on same line\n (\n (<([^<>=]|=[^<]|\\<([^=<>]|=[^<])+\\>)+>\\s*)? # typeparameters\n \\(([^()]|\\([^()]*\\))*\\) # parameteres\n (\\s*:\\s*(.)*)? # return type\n \\s*=> # arrow operator\n )\n )\n)", "beginCaptures": { "1": { "name": "storage.modifier.async.js" @@ -3358,25 +3401,17 @@ } }, { - "begin": "(^[ \\t]+)?(?=//)", + "begin": "(^[ \\t]+)?(//)", "beginCaptures": { "1": { "name": "punctuation.whitespace.comment.leading.js" + }, + "2": { + "name": "comment.line.double-slash.js punctuation.definition.comment.js" } }, - "end": "(?=$)", - "patterns": [ - { - "name": "comment.line.double-slash.js", - "begin": "//", - "beginCaptures": { - "0": { - "name": "punctuation.definition.comment.js" - } - }, - "end": "(?=$)" - } - ] + "end": "(?=^)", + "contentName": "comment.line.double-slash.tsx" } ] }, @@ -3388,7 +3423,7 @@ "name": "punctuation.definition.comment.js" } }, - "end": "(?=$)", + "end": "(?=^)", "patterns": [ { "name": "meta.tag.js", @@ -4188,5 +4223,5 @@ ] } }, - "version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/cb1af7953db224204607cbe22d3a45aa0f77a4c1" + "version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/8c967fe7553297bfad672b7417d78e357c8fe724" } \ No newline at end of file diff --git a/extensions/javascript/test/colorize-results/test_jsx.json b/extensions/javascript/test/colorize-results/test_jsx.json index 7a9eb1f5ca0..55e2c440d3b 100644 --- a/extensions/javascript/test/colorize-results/test_jsx.json +++ b/extensions/javascript/test/colorize-results/test_jsx.json @@ -529,7 +529,7 @@ }, { "c": " Prevent following the link.", - "t": "source.js meta.var.expr.js meta.objectliteral.js meta.object.member.js meta.function.expression.js meta.block.js comment.line.double-slash.js", + "t": "source.js meta.var.expr.js meta.objectliteral.js meta.object.member.js meta.function.expression.js meta.block.js comment.line.double-slash.tsx", "r": { "dark_plus": "comment: #608B4E", "light_plus": "comment: #008000", @@ -628,7 +628,7 @@ }, { "c": " Invert the chosen default.", - "t": "source.js meta.var.expr.js meta.objectliteral.js meta.object.member.js meta.function.expression.js meta.block.js comment.line.double-slash.js", + "t": "source.js meta.var.expr.js meta.objectliteral.js meta.object.member.js meta.function.expression.js meta.block.js comment.line.double-slash.tsx", "r": { "dark_plus": "comment: #608B4E", "light_plus": "comment: #008000", @@ -661,7 +661,7 @@ }, { "c": " This will trigger an intelligent re-render of the component.", - "t": "source.js meta.var.expr.js meta.objectliteral.js meta.object.member.js meta.function.expression.js meta.block.js comment.line.double-slash.js", + "t": "source.js meta.var.expr.js meta.objectliteral.js meta.object.member.js meta.function.expression.js meta.block.js comment.line.double-slash.tsx", "r": { "dark_plus": "comment: #608B4E", "light_plus": "comment: #008000", @@ -1046,7 +1046,7 @@ }, { "c": " Default to the default message.", - "t": "source.js meta.var.expr.js meta.objectliteral.js meta.object.member.js meta.function.expression.js meta.block.js comment.line.double-slash.js", + "t": "source.js meta.var.expr.js meta.objectliteral.js meta.object.member.js meta.function.expression.js meta.block.js comment.line.double-slash.tsx", "r": { "dark_plus": "comment: #608B4E", "light_plus": "comment: #008000", @@ -1222,7 +1222,7 @@ }, { "c": " If toggled, show the alternate message.", - "t": "source.js meta.var.expr.js meta.objectliteral.js meta.object.member.js meta.function.expression.js meta.block.js comment.line.double-slash.js", + "t": "source.js meta.var.expr.js meta.objectliteral.js meta.object.member.js meta.function.expression.js meta.block.js comment.line.double-slash.tsx", "r": { "dark_plus": "comment: #608B4E", "light_plus": "comment: #008000", diff --git a/extensions/typescript/syntaxes/TypeScript.tmLanguage.json b/extensions/typescript/syntaxes/TypeScript.tmLanguage.json index b80d24f1c23..7c581f92aea 100644 --- a/extensions/typescript/syntaxes/TypeScript.tmLanguage.json +++ b/extensions/typescript/syntaxes/TypeScript.tmLanguage.json @@ -71,7 +71,7 @@ "name": "storage.type.ts" } }, - "end": "(?=$|;|}|(\\s+(of|in)\\s+))", + "end": "(?=$|^|;|}|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#destructuring-variable" @@ -100,7 +100,7 @@ "name": "meta.definition.variable.ts entity.name.function.ts" } }, - "end": "(?=$|[;,=}]|(\\s+(of|in)\\s+))", + "end": "(?=$|^|[;,=}]|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#var-single-variable-type-annotation" @@ -115,7 +115,7 @@ "name": "meta.definition.variable.ts variable.other.constant.ts" } }, - "end": "(?=$|[;,=}]|(\\s+(of|in)\\s+))", + "end": "(?=$|^|[;,=}]|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#var-single-variable-type-annotation" @@ -130,7 +130,7 @@ "name": "meta.definition.variable.ts variable.other.readwrite.ts" } }, - "end": "(?=$|[;,=}]|(\\s+(of|in)\\s+))", + "end": "(?=$|^|[;,=}]|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#var-single-variable-type-annotation" @@ -157,7 +157,7 @@ { "name": "meta.object-binding-pattern-variable.ts", "begin": "(?])|(?<=[\\}>\\]\\)]|[_$[:alpha:]])\\s*(?=\\{)", + "end": "(?=$|^|[,);\\}\\]]|//)|(?==[^>])|(?<=[\\}>\\]\\)]|[_$[:alpha:]])\\s*(?=\\{)", "patterns": [ { "include": "#comment" @@ -2013,7 +2056,7 @@ "name": "punctuation.definition.typeparameters.begin.ts" } }, - "end": "(?=$)|(>)", + "end": "(>)", "endCaptures": { "1": { "name": "punctuation.definition.typeparameters.end.ts" @@ -2048,7 +2091,7 @@ "name": "keyword.operator.assignment.ts" } }, - "end": "(?=$|[,);}\\]])", + "end": "(?=$|^|[,);}\\]])", "patterns": [ { "include": "#expression" @@ -2487,7 +2530,7 @@ "patterns": [ { "name": "cast.expr.ts", - "begin": "(?:(?<=return|throw|yield|await|default|[=(,:>*]))\\s*(<)(?!*?]))\\s*(<)(?! is on new line\n (\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n ) |\n (\n [<]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=>] # < typeparam extends \n ) |\n # arrow function possible to detect only with => on same line\n (\n (<([^<>=]|=[^<]|\\<([^=<>]|=[^<])+\\>)+>\\s*)? # typeparameters\n \\(([^()]|\\([^()]*\\))*\\) # parameteres\n (\\s*:\\s*(.)*)? # return type\n \\s*=> # arrow operator\n )\n )\n)", + "begin": "(?x) (?:\n (? is on new line\n (\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n ) |\n (\n [<]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=>] # < typeparam extends \n ) |\n # arrow function possible to detect only with => on same line\n (\n (<([^<>=]|=[^<]|\\<([^=<>]|=[^<])+\\>)+>\\s*)? # typeparameters\n \\(([^()]|\\([^()]*\\))*\\) # parameteres\n (\\s*:\\s*(.)*)? # return type\n \\s*=> # arrow operator\n )\n )\n)", "beginCaptures": { "1": { "name": "storage.modifier.async.ts" @@ -3389,25 +3432,17 @@ } }, { - "begin": "(^[ \\t]+)?(?=//)", + "begin": "(^[ \\t]+)?(//)", "beginCaptures": { "1": { "name": "punctuation.whitespace.comment.leading.ts" + }, + "2": { + "name": "comment.line.double-slash.ts punctuation.definition.comment.ts" } }, - "end": "(?=$)", - "patterns": [ - { - "name": "comment.line.double-slash.ts", - "begin": "//", - "beginCaptures": { - "0": { - "name": "punctuation.definition.comment.ts" - } - }, - "end": "(?=$)" - } - ] + "end": "(?=^)", + "contentName": "comment.line.double-slash.ts" } ] }, @@ -3419,7 +3454,7 @@ "name": "punctuation.definition.comment.ts" } }, - "end": "(?=$)", + "end": "(?=^)", "patterns": [ { "name": "meta.tag.ts", @@ -3923,5 +3958,5 @@ ] } }, - "version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/9f6676aa2ddb75cb5a9dbe1f59024069e839d986" + "version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/8c967fe7553297bfad672b7417d78e357c8fe724" } \ No newline at end of file diff --git a/extensions/typescript/syntaxes/TypeScriptReact.tmLanguage.json b/extensions/typescript/syntaxes/TypeScriptReact.tmLanguage.json index c20889881a1..b2c49cbf7f4 100644 --- a/extensions/typescript/syntaxes/TypeScriptReact.tmLanguage.json +++ b/extensions/typescript/syntaxes/TypeScriptReact.tmLanguage.json @@ -71,7 +71,7 @@ "name": "storage.type.tsx" } }, - "end": "(?=$|;|}|(\\s+(of|in)\\s+))", + "end": "(?=$|^|;|}|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#destructuring-variable" @@ -100,7 +100,7 @@ "name": "meta.definition.variable.tsx entity.name.function.tsx" } }, - "end": "(?=$|[;,=}]|(\\s+(of|in)\\s+))", + "end": "(?=$|^|[;,=}]|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#var-single-variable-type-annotation" @@ -115,7 +115,7 @@ "name": "meta.definition.variable.tsx variable.other.constant.tsx" } }, - "end": "(?=$|[;,=}]|(\\s+(of|in)\\s+))", + "end": "(?=$|^|[;,=}]|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#var-single-variable-type-annotation" @@ -130,7 +130,7 @@ "name": "meta.definition.variable.tsx variable.other.readwrite.tsx" } }, - "end": "(?=$|[;,=}]|(\\s+(of|in)\\s+))", + "end": "(?=$|^|[;,=}]|(\\s+(of|in)\\s+))", "patterns": [ { "include": "#var-single-variable-type-annotation" @@ -157,7 +157,7 @@ { "name": "meta.object-binding-pattern-variable.tsx", "begin": "(?])|(?<=[\\}>\\]\\)]|[_$[:alpha:]])\\s*(?=\\{)", + "end": "(?=$|^|[,);\\}\\]]|//)|(?==[^>])|(?<=[\\}>\\]\\)]|[_$[:alpha:]])\\s*(?=\\{)", "patterns": [ { "include": "#comment" @@ -2016,7 +2059,7 @@ "name": "punctuation.definition.typeparameters.begin.tsx" } }, - "end": "(?=$)|(>)", + "end": "(>)", "endCaptures": { "1": { "name": "punctuation.definition.typeparameters.end.tsx" @@ -2051,7 +2094,7 @@ "name": "keyword.operator.assignment.tsx" } }, - "end": "(?=$|[,);}\\]])", + "end": "(?=$|^|[,);}\\]])", "patterns": [ { "include": "#expression" @@ -2690,7 +2733,7 @@ "name": "keyword.control.as.tsx" } }, - "end": "(?=$|[;,:})\\]])", + "end": "(?=$|^|[;,:})\\]])", "patterns": [ { "include": "#type" @@ -2775,7 +2818,7 @@ }, { "name": "meta.arrow.tsx", - "begin": "(?x) (?:\n (? is on new line\n (\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n ) |\n (\n [<]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=>] # < typeparam extends \n ) |\n # arrow function possible to detect only with => on same line\n (\n (<([^<>=]|=[^<]|\\<([^=<>]|=[^<])+\\>)+>\\s*)? # typeparameters\n \\(([^()]|\\([^()]*\\))*\\) # parameteres\n (\\s*:\\s*(.)*)? # return type\n \\s*=> # arrow operator\n )\n )\n)", + "begin": "(?x) (?:\n (? is on new line\n (\n [(]\\s*\n (\n ([)]\\s*:) | # ():\n ((\\.\\.\\.\\s*)?[_$[:alpha:]][_$[:alnum:]]*\\s*:) # [(]param: | [(]...param:\n )\n ) |\n (\n [<]\\s*[_$[:alpha:]][_$[:alnum:]]*\\s+extends\\s*[^=>] # < typeparam extends \n ) |\n # arrow function possible to detect only with => on same line\n (\n (<([^<>=]|=[^<]|\\<([^=<>]|=[^<])+\\>)+>\\s*)? # typeparameters\n \\(([^()]|\\([^()]*\\))*\\) # parameteres\n (\\s*:\\s*(.)*)? # return type\n \\s*=> # arrow operator\n )\n )\n)", "beginCaptures": { "1": { "name": "storage.modifier.async.tsx" @@ -3355,25 +3398,17 @@ } }, { - "begin": "(^[ \\t]+)?(?=//)", + "begin": "(^[ \\t]+)?(//)", "beginCaptures": { "1": { "name": "punctuation.whitespace.comment.leading.tsx" + }, + "2": { + "name": "comment.line.double-slash.tsx punctuation.definition.comment.tsx" } }, - "end": "(?=$)", - "patterns": [ - { - "name": "comment.line.double-slash.tsx", - "begin": "//", - "beginCaptures": { - "0": { - "name": "punctuation.definition.comment.tsx" - } - }, - "end": "(?=$)" - } - ] + "end": "(?=^)", + "contentName": "comment.line.double-slash.tsx" } ] }, @@ -3385,7 +3420,7 @@ "name": "punctuation.definition.comment.tsx" } }, - "end": "(?=$)", + "end": "(?=^)", "patterns": [ { "name": "meta.tag.tsx", @@ -4185,5 +4220,5 @@ ] } }, - "version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/cb1af7953db224204607cbe22d3a45aa0f77a4c1" + "version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/8c967fe7553297bfad672b7417d78e357c8fe724" } \ No newline at end of file -- GitLab From 7c55d50e827d57fc421ab0940bf9cc32852167c5 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 11:28:58 +0200 Subject: [PATCH 0156/1347] [less] update grammar --- extensions/less/syntaxes/less.tmLanguage.json | 17 +- .../test/colorize-results/14119_less.json | 13 +- .../test-cssvariables_less.json | 28 +- .../less/test/colorize-results/test_less.json | 280 ++++++++++++++++-- 4 files changed, 293 insertions(+), 45 deletions(-) diff --git a/extensions/less/syntaxes/less.tmLanguage.json b/extensions/less/syntaxes/less.tmLanguage.json index 902eb4e8d01..cd25b2a89b5 100644 --- a/extensions/less/syntaxes/less.tmLanguage.json +++ b/extensions/less/syntaxes/less.tmLanguage.json @@ -146,12 +146,7 @@ "name": "comment.block.css" }, { - "match": "[+-]?\\d*\\.?\\d+", - "name": "constant.numeric.css" - }, - { - "match": "(?<=[\\d])(ch|cm|deg|dpi|dpcm|dppx|em|ex|grad|in|mm|ms|pc|pt|px|rad|rem|turn|s|vh|vmin|vw)\\b|%", - "name": "keyword.other.unit.css" + "include": "source.css#numeric-values" }, { "captures": { @@ -281,13 +276,13 @@ ] }, { + "match": "(@|\\-\\-)[\\w-]+(?=\\s*)", + "name": "variable.other.less", "captures": { "1": { "name": "punctuation.definition.variable.less" } - }, - "match": "(?:@|\\-\\-)[a-zA-Z0-9_-][\\w-]*(?=\\s*)", - "name": "variable.other.less" + } }, { "include": "#variable_interpolation" @@ -516,7 +511,7 @@ "include": "#strings" }, { - "match": "(\\b|\\.{0,2}/).*\\b", + "match": "(\\b|\\.{0,2}/)[^)]*\\b", "name": "string.url.css" } ] @@ -546,5 +541,5 @@ "name": "support.function.any-method.builtin.less" } }, - "version": "https://github.com/atom/language-less/commit/7d70b66aa9c853d59e27cce25b5bc25cb067e75a" + "version": "https://github.com/atom/language-less/commit/4661d870784f725599e438bf683553cc6cf0f4ed" } \ No newline at end of file diff --git a/extensions/less/test/colorize-results/14119_less.json b/extensions/less/test/colorize-results/14119_less.json index 6e89b6a4587..0c83af45331 100644 --- a/extensions/less/test/colorize-results/14119_less.json +++ b/extensions/less/test/colorize-results/14119_less.json @@ -33,7 +33,18 @@ } }, { - "c": "@hm", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "hm", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", diff --git a/extensions/less/test/colorize-results/test-cssvariables_less.json b/extensions/less/test/colorize-results/test-cssvariables_less.json index bca9cd3c3a9..1c9b8658a0a 100644 --- a/extensions/less/test/colorize-results/test-cssvariables_less.json +++ b/extensions/less/test/colorize-results/test-cssvariables_less.json @@ -55,7 +55,18 @@ } }, { - "c": "--spacing-unit", + "c": "--", + "t": "source.css.less meta.property-list.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "spacing-unit", "t": "source.css.less meta.property-list.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -100,7 +111,7 @@ }, { "c": "px", - "t": "source.css.less meta.property-list.css meta.property-value.css keyword.other.unit.css", + "t": "source.css.less meta.property-list.css meta.property-value.css constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -132,7 +143,18 @@ } }, { - "c": "--cell-padding", + "c": "--", + "t": "source.css.less meta.property-list.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "cell-padding", "t": "source.css.less meta.property-list.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", diff --git a/extensions/less/test/colorize-results/test_less.json b/extensions/less/test/colorize-results/test_less.json index 4cc47220238..d6b39257feb 100644 --- a/extensions/less/test/colorize-results/test_less.json +++ b/extensions/less/test/colorize-results/test_less.json @@ -308,7 +308,18 @@ } }, { - "c": "@base", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "base", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -385,7 +396,18 @@ } }, { - "c": "@style", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "style", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -418,7 +440,18 @@ } }, { - "c": "@c", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "c", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -506,7 +539,18 @@ } }, { - "c": "@c", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "c", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -594,7 +638,18 @@ } }, { - "c": "@style", + "c": "@", + "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "style", "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -616,7 +671,18 @@ } }, { - "c": "@c", + "c": "@", + "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "c", "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -671,7 +737,18 @@ } }, { - "c": "@style", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "style", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -704,7 +781,18 @@ } }, { - "c": "@alpha", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "alpha", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -749,7 +837,7 @@ }, { "c": "%", - "t": "source.css.less keyword.other.unit.css", + "t": "source.css.less constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -836,7 +924,18 @@ } }, { - "c": "@alpha", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "alpha", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -913,7 +1012,18 @@ } }, { - "c": "@style", + "c": "@", + "t": "source.css.less meta.property-list.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "style", "t": "source.css.less meta.property-list.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -1232,7 +1342,18 @@ } }, { - "c": "@base", + "c": "@", + "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "base", "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -1277,7 +1398,7 @@ }, { "c": "%", - "t": "source.css.less meta.property-list.css meta.property-value.css keyword.other.unit.css", + "t": "source.css.less meta.property-list.css meta.property-value.css constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -1375,7 +1496,18 @@ } }, { - "c": "@base", + "c": "@", + "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "base", "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -1420,7 +1552,7 @@ }, { "c": "%", - "t": "source.css.less meta.property-list.css meta.property-value.css keyword.other.unit.css", + "t": "source.css.less meta.property-list.css meta.property-value.css constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -1585,7 +1717,7 @@ }, { "c": "px", - "t": "source.css.less meta.property-list.css meta.property-list.css keyword.other.unit.css", + "t": "source.css.less meta.property-list.css meta.property-list.css constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -1640,7 +1772,7 @@ }, { "c": "%", - "t": "source.css.less meta.property-list.css meta.property-list.css keyword.other.unit.css", + "t": "source.css.less meta.property-list.css meta.property-list.css constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -1849,7 +1981,7 @@ }, { "c": "px", - "t": "source.css.less meta.property-list.css meta.property-list.css meta.property-value.css keyword.other.unit.css", + "t": "source.css.less meta.property-list.css meta.property-list.css meta.property-value.css constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -2058,7 +2190,7 @@ }, { "c": "px", - "t": "source.css.less meta.property-list.css meta.property-list.css meta.property-value.css keyword.other.unit.css", + "t": "source.css.less meta.property-list.css meta.property-list.css meta.property-value.css constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -2311,7 +2443,7 @@ }, { "c": "px", - "t": "source.css.less meta.property-list.css meta.property-list.css meta.property-list.css meta.property-list.css meta.property-value.css keyword.other.unit.css", + "t": "source.css.less meta.property-list.css meta.property-list.css meta.property-list.css meta.property-list.css meta.property-value.css constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -2398,7 +2530,18 @@ } }, { - "c": "@the-border", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "the-border", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -2443,7 +2586,7 @@ }, { "c": "px", - "t": "source.css.less keyword.other.unit.css", + "t": "source.css.less constant.numeric.css keyword.other.unit.px.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", @@ -2464,7 +2607,18 @@ } }, { - "c": "@base-color", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "base-color", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -2519,7 +2673,18 @@ } }, { - "c": "@red", + "c": "@", + "t": "source.css.less variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "red", "t": "source.css.less variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -2673,7 +2838,18 @@ } }, { - "c": "@base-color", + "c": "@", + "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "base-color", "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -2794,7 +2970,18 @@ } }, { - "c": "@the-border", + "c": "@", + "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "the-border", "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -2871,7 +3058,18 @@ } }, { - "c": "@the-border", + "c": "@", + "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "the-border", "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -3058,7 +3256,18 @@ } }, { - "c": "@base-color", + "c": "@", + "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "base-color", "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -3201,7 +3410,18 @@ } }, { - "c": "@red", + "c": "@", + "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less punctuation.definition.variable.less", + "r": { + "dark_plus": "variable.other.less: #9CDCFE", + "light_plus": "variable.other.less: #FF0000", + "dark_vs": "variable.other.less: #9CDCFE", + "light_vs": "variable.other.less: #FF0000", + "hc_black": "variable.other.less: #D4D4D4" + } + }, + { + "c": "red", "t": "source.css.less meta.property-list.css meta.property-value.css variable.other.less", "r": { "dark_plus": "variable.other.less: #9CDCFE", @@ -3246,7 +3466,7 @@ }, { "c": "%", - "t": "source.css.less meta.property-list.css meta.property-value.css keyword.other.unit.css", + "t": "source.css.less meta.property-list.css meta.property-value.css constant.numeric.css keyword.other.unit.percentage.css", "r": { "dark_plus": "keyword.other.unit: #B5CEA8", "light_plus": "keyword.other.unit: #09885A", -- GitLab From a90342f431ec777932e5ea9665da3a8efc47c055 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 11:29:12 +0200 Subject: [PATCH 0157/1347] [php] update grammar --- extensions/php/syntaxes/php.tmLanguage.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/extensions/php/syntaxes/php.tmLanguage.json b/extensions/php/syntaxes/php.tmLanguage.json index d7e3a548ade..8e69579120b 100644 --- a/extensions/php/syntaxes/php.tmLanguage.json +++ b/extensions/php/syntaxes/php.tmLanguage.json @@ -2071,7 +2071,7 @@ "patterns": [ { "comment": "PHPDocumentor only recognises lines with an asterisk as the first non-whitespaces character", - "match": "^(?!\\s*\\*).*$\\n?", + "match": "^(?!\\s*\\*).*?(?:(?=\\*\\/)|$\\n?)", "name": "invalid.illegal.missing-asterisk.phpdoc.php" }, { @@ -2975,5 +2975,5 @@ ] } }, - "version": "https://github.com/atom/language-php/commit/22047c19f52f686de471d0deccae0cb1332997b6" + "version": "https://github.com/atom/language-php/commit/c523a19f849b97f6499eae6accf80564aa190c0e" } \ No newline at end of file -- GitLab From f9084bb2446eb5c42289dd64d4b3b6f92c4d9228 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 12:26:41 +0200 Subject: [PATCH 0158/1347] Add information_for_contributors to grammars --- build/npm/update-all-grammars.js | 1 - build/npm/update-grammar.js | 16 ++++++++++++++-- .../clojure/syntaxes/clojure.tmLanguage.json | 8 ++++++-- .../syntaxes/coffeescript.tmLanguage.json | 8 ++++++-- extensions/cpp/syntaxes/c++.json | 8 ++++++-- extensions/cpp/syntaxes/c.json | 8 ++++++-- .../csharp/syntaxes/csharp.tmLanguage.json | 8 ++++++-- extensions/css/syntaxes/css.tmLanguage.json | 8 ++++++-- extensions/diff/syntaxes/diff.tmLanguage.json | 8 ++++++-- .../docker/syntaxes/docker.tmLanguage.json | 8 ++++++-- extensions/fsharp/syntaxes/fsharp.json | 8 ++++++-- .../syntaxes/git-commit.tmLanguage.json | 8 ++++++-- .../syntaxes/git-rebase.tmLanguage.json | 8 ++++++-- extensions/go/syntaxes/go.json | 8 ++++++-- .../groovy/syntaxes/groovy.tmLanguage.json | 8 ++++++-- .../syntaxes/Handlebars.tmLanguage.json | 8 ++++++-- extensions/hlsl/syntaxes/hlsl.json | 8 ++++++-- extensions/html/syntaxes/html.json | 8 ++++++-- extensions/ini/syntaxes/ini.tmLanguage.json | 8 ++++++-- extensions/java/syntaxes/java.tmLanguage.json | 8 ++++++-- .../syntaxes/JavaScript.tmLanguage.json | 8 ++++++-- extensions/less/syntaxes/less.tmLanguage.json | 8 ++++++-- extensions/lua/syntaxes/lua.json | 8 ++++++-- extensions/make/syntaxes/Makefile.json | 8 ++++++-- .../syntaxes/objective-c++.tmLanguage.json | 5 +++++ .../syntaxes/objective-c.tmLanguage.json | 8 ++++++-- extensions/perl/syntaxes/perl.tmLanguage.json | 8 ++++++-- extensions/perl/syntaxes/perl6.tmLanguage.json | 8 ++++++-- extensions/php/syntaxes/php.tmLanguage.json | 8 ++++++-- extensions/pug/syntaxes/pug.tmLanguage.json | 8 ++++++-- .../python/syntaxes/MagicPython.tmLanguage.json | 8 ++++++-- .../python/syntaxes/MagicRegExp.tmLanguage.json | 8 ++++++-- extensions/r/syntaxes/r.tmLanguage.json | 8 ++++++-- extensions/razor/syntaxes/cshtml.json | 8 ++++++-- extensions/ruby/syntaxes/ruby.tmLanguage.json | 8 ++++++-- extensions/rust/syntaxes/rust.tmLanguage.json | 8 ++++++-- extensions/scss/syntaxes/scss.json | 8 ++++++-- extensions/shaderlab/syntaxes/shaderlab.json | 8 ++++++-- .../syntaxes/Shell-Unix-Bash.tmLanguage.json | 8 ++++++-- extensions/swift/syntaxes/swift.tmLanguage.json | 8 ++++++-- .../syntaxes/TypeScript.tmLanguage.json | 8 ++++++-- .../syntaxes/TypeScriptReact.tmLanguage.json | 8 ++++++-- .../vb/syntaxes/asp-vb-net.tmlanguage.json | 8 ++++++-- extensions/xml/syntaxes/xml.json | 8 ++++++-- extensions/xml/syntaxes/xsl.json | 8 ++++++-- extensions/yaml/syntaxes/yaml.json | 8 ++++++-- 46 files changed, 277 insertions(+), 89 deletions(-) diff --git a/build/npm/update-all-grammars.js b/build/npm/update-all-grammars.js index 252b0f4edcb..88b890af730 100644 --- a/build/npm/update-all-grammars.js +++ b/build/npm/update-all-grammars.js @@ -5,7 +5,6 @@ const cp = require('child_process'); const npm = process.platform === 'win32' ? 'npm.cmd' : 'npm'; -const integrationTests = process.platform === 'win32' ? '.\test-integration.bat' : './test-integration.sh'; function updateGrammar(location) { const result = cp.spawnSync(npm, ['run', 'update-grammar'], { diff --git a/build/npm/update-grammar.js b/build/npm/update-grammar.js index dbb12cdcb44..fca60d83242 100644 --- a/build/npm/update-grammar.js +++ b/build/npm/update-grammar.js @@ -88,11 +88,23 @@ exports.update = function (repoId, repoPath, dest, modifyGrammar) { modifyGrammar(grammar); } return getCommitSha(repoId, repoPath).then(function (info) { + let result = { + information_for_contributors: [ + 'This file has been converted from https://github.com/' + repoId + '/blob/master/' + repoPath, + 'If you want to provide a fix or improvement, please create a pull request against the original repository.', + 'Once accepted there, we are happy to receive an update request.' + ] + }; + if (info) { - grammar.version = 'https://github.com/' + repoId + '/commit/' + info.commitSha; + result.version = 'https://github.com/' + repoId + '/commit/' + info.commitSha; + } + for (let key in grammar) { + result[key] = grammar[key]; } + try { - fs.writeFileSync(dest, JSON.stringify(grammar, null, '\t')); + fs.writeFileSync(dest, JSON.stringify(result, null, '\t')); if (info) { console.log('Updated ' + path.basename(dest) + ' to ' + repoId + '@' + info.commitSha.substr(0, 7) + ' (' + info.commitDate.substr(0, 10) + ')'); } else { diff --git a/extensions/clojure/syntaxes/clojure.tmLanguage.json b/extensions/clojure/syntaxes/clojure.tmLanguage.json index 881ce191e1c..437a0c5b5e1 100644 --- a/extensions/clojure/syntaxes/clojure.tmLanguage.json +++ b/extensions/clojure/syntaxes/clojure.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-clojure/blob/master/grammars/clojure.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "source.clojure", "fileTypes": [ "boot", @@ -440,6 +445,5 @@ } ] } - }, - "version": "https://github.com/atom/language-clojure/commit/70e83b27444da31d6367a0aa447a216836eafc05" + } } \ No newline at end of file diff --git a/extensions/coffeescript/syntaxes/coffeescript.tmLanguage.json b/extensions/coffeescript/syntaxes/coffeescript.tmLanguage.json index d7c22867d76..dae1d795f45 100644 --- a/extensions/coffeescript/syntaxes/coffeescript.tmLanguage.json +++ b/extensions/coffeescript/syntaxes/coffeescript.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-coffee-script/blob/master/grammars/coffeescript.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "source.coffee", "name": "CoffeeScript", "fileTypes": [ @@ -686,6 +691,5 @@ } ] } - }, - "version": "https://github.com/atom/language-coffee-script/commit/49c117b24096a369f92dfce180b61bd1f0425a29" + } } \ No newline at end of file diff --git a/extensions/cpp/syntaxes/c++.json b/extensions/cpp/syntaxes/c++.json index 7ec3054f58b..bc627e3a036 100644 --- a/extensions/cpp/syntaxes/c++.json +++ b/extensions/cpp/syntaxes/c++.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-c/blob/master/grammars/c%2B%2B.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "source.cpp", "fileTypes": [ "cc", @@ -457,6 +462,5 @@ } ] } - }, - "version": "https://github.com/atom/language-c/commit/3a269f88b12e512fb9495dc006a1dabf325d3d7f" + } } \ No newline at end of file diff --git a/extensions/cpp/syntaxes/c.json b/extensions/cpp/syntaxes/c.json index 6cc84cff24d..022f588cf28 100644 --- a/extensions/cpp/syntaxes/c.json +++ b/extensions/cpp/syntaxes/c.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-c/blob/master/grammars/c.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "source.c", "fileTypes": [ "c", @@ -1950,6 +1955,5 @@ } ] } - }, - "version": "https://github.com/atom/language-c/commit/1d137279178d06e7f7500800ebc36155e130172e" + } } \ No newline at end of file diff --git a/extensions/csharp/syntaxes/csharp.tmLanguage.json b/extensions/csharp/syntaxes/csharp.tmLanguage.json index eae75041576..3f81563c5bb 100644 --- a/extensions/csharp/syntaxes/csharp.tmLanguage.json +++ b/extensions/csharp/syntaxes/csharp.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/dotnet/csharp-tmLanguage/blob/master/grammars/csharp.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "name": "C#", "scopeName": "source.cs", "fileTypes": [ @@ -4186,6 +4191,5 @@ } } } - }, - "version": "https://github.com/dotnet/csharp-tmLanguage/commit/4d0e50c51f336645c98689737db1be321d212d3d" + } } \ No newline at end of file diff --git a/extensions/css/syntaxes/css.tmLanguage.json b/extensions/css/syntaxes/css.tmLanguage.json index 700b6dd3140..dae4475161a 100644 --- a/extensions/css/syntaxes/css.tmLanguage.json +++ b/extensions/css/syntaxes/css.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-css/blob/master/grammars/css.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "source.css", "name": "CSS", "fileTypes": [ @@ -1796,6 +1801,5 @@ } ] } - }, - "version": "https://github.com/atom/language-css/commit/23dcdee3372050eb3f07374fbe9188884bd545d1" + } } \ No newline at end of file diff --git a/extensions/diff/syntaxes/diff.tmLanguage.json b/extensions/diff/syntaxes/diff.tmLanguage.json index ac16f416a64..e259c46be42 100644 --- a/extensions/diff/syntaxes/diff.tmLanguage.json +++ b/extensions/diff/syntaxes/diff.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/diff.tmbundle/blob/master/Syntaxes/Diff.plist", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "patch", "diff", @@ -158,6 +163,5 @@ } ], "scopeName": "source.diff", - "uuid": "7E848FF4-708E-11D9-97B4-0011242E4184", - "version": "https://github.com/textmate/diff.tmbundle/commit/0593bb775eab1824af97ef2172fd38822abd97d7" + "uuid": "7E848FF4-708E-11D9-97B4-0011242E4184" } \ No newline at end of file diff --git a/extensions/docker/syntaxes/docker.tmLanguage.json b/extensions/docker/syntaxes/docker.tmLanguage.json index 8be1c94055d..d8c2d0fd766 100644 --- a/extensions/docker/syntaxes/docker.tmLanguage.json +++ b/extensions/docker/syntaxes/docker.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/moby/moby/blob/master/contrib/syntax/textmate/Docker.tmbundle/Syntaxes/Dockerfile.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "Dockerfile" ], @@ -96,6 +101,5 @@ } ], "scopeName": "source.dockerfile", - "uuid": "a39d8795-59d2-49af-aa00-fe74ee29576e", - "version": "https://github.com/moby/moby/commit/8523e9d108a0e98865673701a7bd0a7929c5260b" + "uuid": "a39d8795-59d2-49af-aa00-fe74ee29576e" } \ No newline at end of file diff --git a/extensions/fsharp/syntaxes/fsharp.json b/extensions/fsharp/syntaxes/fsharp.json index 7ef61094dd1..f7abe7e8a52 100644 --- a/extensions/fsharp/syntaxes/fsharp.json +++ b/extensions/fsharp/syntaxes/fsharp.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/ionide/ionide-fsgrammar/blob/master/grammar/fsharp.json", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "name": "fsharp", "scopeName": "source.fsharp", "fileTypes": [ @@ -456,6 +461,5 @@ } ] } - }, - "version": "https://github.com/ionide/ionide-fsgrammar/commit/f2e3c30f0ebfcc89fb78ad908701159f20516812" + } } \ No newline at end of file diff --git a/extensions/gitsyntax/syntaxes/git-commit.tmLanguage.json b/extensions/gitsyntax/syntaxes/git-commit.tmLanguage.json index 5f5db8762fa..ffe1561f727 100644 --- a/extensions/gitsyntax/syntaxes/git-commit.tmLanguage.json +++ b/extensions/gitsyntax/syntaxes/git-commit.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/git.tmbundle/blob/master/Syntaxes/Git%20Commit%20Message.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "COMMIT_EDITMSG", "MERGE_MSG" @@ -138,6 +143,5 @@ } }, "scopeName": "text.git-commit", - "uuid": "BFE83C06-8508-44BE-A975-95A57BF619A7", - "version": "https://github.com/textmate/git.tmbundle/commit/93897a78c6e52bef13dadc0d4091d203c5facb40" + "uuid": "BFE83C06-8508-44BE-A975-95A57BF619A7" } \ No newline at end of file diff --git a/extensions/gitsyntax/syntaxes/git-rebase.tmLanguage.json b/extensions/gitsyntax/syntaxes/git-rebase.tmLanguage.json index c8bf731d9cb..15bac0d8d09 100644 --- a/extensions/gitsyntax/syntaxes/git-rebase.tmLanguage.json +++ b/extensions/gitsyntax/syntaxes/git-rebase.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/git.tmbundle/blob/master/Syntaxes/Git%20Rebase%20Message.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "git-rebase-todo" ], @@ -30,6 +35,5 @@ } ], "scopeName": "text.git-rebase", - "uuid": "7F1CC209-5F6D-486A-8180-09FA282381A1", - "version": "https://github.com/textmate/git.tmbundle/commit/d1db42c2d71948662098183a6df519fb53a7a15b" + "uuid": "7F1CC209-5F6D-486A-8180-09FA282381A1" } \ No newline at end of file diff --git a/extensions/go/syntaxes/go.json b/extensions/go/syntaxes/go.json index 53908a80bac..098c8710482 100644 --- a/extensions/go/syntaxes/go.json +++ b/extensions/go/syntaxes/go.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-go/blob/master/grammars/go.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "source.go", "name": "Go", "comment": "Go language", @@ -624,6 +629,5 @@ } ] } - }, - "version": "https://github.com/atom/language-go/commit/c1fe618ccf2dcd17118c5600c49b1c539f26d5c5" + } } \ No newline at end of file diff --git a/extensions/groovy/syntaxes/groovy.tmLanguage.json b/extensions/groovy/syntaxes/groovy.tmLanguage.json index 8850454840e..3dc8af7d0a1 100644 --- a/extensions/groovy/syntaxes/groovy.tmLanguage.json +++ b/extensions/groovy/syntaxes/groovy.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/groovy.tmbundle/blob/master/Syntaxes/Groovy.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "groovy", "gvy" @@ -1381,6 +1386,5 @@ } }, "scopeName": "source.groovy", - "uuid": "B3A64888-EBBB-4436-8D9E-F1169C5D7613", - "version": "https://github.com/textmate/groovy.tmbundle/commit/85d8f7c97ae473ccb9473f6c8d27e4ec957f4be1" + "uuid": "B3A64888-EBBB-4436-8D9E-F1169C5D7613" } \ No newline at end of file diff --git a/extensions/handlebars/syntaxes/Handlebars.tmLanguage.json b/extensions/handlebars/syntaxes/Handlebars.tmLanguage.json index 9e3579d90c2..e915b691d7f 100644 --- a/extensions/handlebars/syntaxes/Handlebars.tmLanguage.json +++ b/extensions/handlebars/syntaxes/Handlebars.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/daaain/Handlebars/blob/master/grammars/Handlebars.json", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "name": "Handlebars", "repository": { "html_tags": { @@ -849,6 +854,5 @@ "template", "tmpl" ], - "uuid": "70E91676-DE0A-4266-A2B9-3AD2E535E484", - "version": "https://github.com/daaain/Handlebars/commit/4e8244410815da73f93375532939d48bd5a9bb93" + "uuid": "70E91676-DE0A-4266-A2B9-3AD2E535E484" } \ No newline at end of file diff --git a/extensions/hlsl/syntaxes/hlsl.json b/extensions/hlsl/syntaxes/hlsl.json index 91dcf2b2520..20565922c53 100644 --- a/extensions/hlsl/syntaxes/hlsl.json +++ b/extensions/hlsl/syntaxes/hlsl.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/tgjones/shaders-tmLanguage/blob/master/grammars/hlsl.json", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "source.hlsl", "name": "HLSL", "fileTypes": [ @@ -213,6 +218,5 @@ } ] } - ], - "version": "https://github.com/tgjones/shaders-tmLanguage/commit/cd1ef40f549f9ce2b9e6b73498688de114a85382" + ] } \ No newline at end of file diff --git a/extensions/html/syntaxes/html.json b/extensions/html/syntaxes/html.json index cc2d9fd17ea..4192c824703 100644 --- a/extensions/html/syntaxes/html.json +++ b/extensions/html/syntaxes/html.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/html.tmbundle/blob/master/Syntaxes/HTML.plist", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "html", "htm", @@ -742,6 +747,5 @@ } }, "scopeName": "text.html.basic", - "uuid": "17994EC8-6B1D-11D9-AC3A-000D93589AF6", - "version": "https://github.com/textmate/html.tmbundle/commit/a723f08ebd49c67c22aca08dd8f17d0bf836ec93" + "uuid": "17994EC8-6B1D-11D9-AC3A-000D93589AF6" } \ No newline at end of file diff --git a/extensions/ini/syntaxes/ini.tmLanguage.json b/extensions/ini/syntaxes/ini.tmLanguage.json index e8f1a0ef9b3..34679c1bee0 100644 --- a/extensions/ini/syntaxes/ini.tmLanguage.json +++ b/extensions/ini/syntaxes/ini.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/ini.tmbundle/blob/master/Syntaxes/Ini.plist", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "ini", "conf" @@ -109,6 +114,5 @@ } ], "scopeName": "source.ini", - "uuid": "77DC23B6-8A90-11D9-BAA4-000A9584EC8C", - "version": "https://github.com/textmate/ini.tmbundle/commit/2af0cbb0704940f967152616f2f1ff0aae6287a6" + "uuid": "77DC23B6-8A90-11D9-BAA4-000A9584EC8C" } \ No newline at end of file diff --git a/extensions/java/syntaxes/java.tmLanguage.json b/extensions/java/syntaxes/java.tmLanguage.json index 5d0513d49b0..654bf8e2ba8 100644 --- a/extensions/java/syntaxes/java.tmLanguage.json +++ b/extensions/java/syntaxes/java.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-java/blob/master/grammars/java.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "source.java", "name": "Java", "fileTypes": [ @@ -1360,6 +1365,5 @@ } ] } - }, - "version": "https://github.com/atom/language-java/commit/0e0ec7966059e3e363868311b3d855014bca95dd" + } } \ No newline at end of file diff --git a/extensions/javascript/syntaxes/JavaScript.tmLanguage.json b/extensions/javascript/syntaxes/JavaScript.tmLanguage.json index d7aabe6479b..8856e46770c 100644 --- a/extensions/javascript/syntaxes/JavaScript.tmLanguage.json +++ b/extensions/javascript/syntaxes/JavaScript.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/Microsoft/TypeScript-TmLanguage/blob/master/TypeScriptReact.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "name": "JavaScript (with React support)", "scopeName": "source.js", "fileTypes": [ @@ -4222,6 +4227,5 @@ } ] } - }, - "version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/8c967fe7553297bfad672b7417d78e357c8fe724" + } } \ No newline at end of file diff --git a/extensions/less/syntaxes/less.tmLanguage.json b/extensions/less/syntaxes/less.tmLanguage.json index cd25b2a89b5..cd1543fd7d3 100644 --- a/extensions/less/syntaxes/less.tmLanguage.json +++ b/extensions/less/syntaxes/less.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-less/blob/master/grammars/less.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "name": "Less", "scopeName": "source.css.less", "fileTypes": [ @@ -540,6 +545,5 @@ "match": "\\b(abs|acos|alpha|argb|asin|atan|average|blue|calc|ceil|color|contrast|convert|convert|cos|darken|data-uri|desaturate|difference|e|escape|exclusion|extract|fade|fadein|fadeout|floor|format|green|greyscale|hardlight|hsl|hsla|hsv|hsva|hsvhue|hsvsaturation|hsvvalue|hue|length|lighten|lightness|luma|max|min|mix|mod|multiply|negation|overlay|percentage|pi|pow|red|replace|round|saturate|saturation|screen|sin|softlight|spin|sqrt|tan|unit)\\b", "name": "support.function.any-method.builtin.less" } - }, - "version": "https://github.com/atom/language-less/commit/4661d870784f725599e438bf683553cc6cf0f4ed" + } } \ No newline at end of file diff --git a/extensions/lua/syntaxes/lua.json b/extensions/lua/syntaxes/lua.json index a4da3a43c6a..efea9819bde 100644 --- a/extensions/lua/syntaxes/lua.json +++ b/extensions/lua/syntaxes/lua.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/lua.tmbundle/blob/master/Syntaxes/Lua.plist", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "comment": "Lua Syntax: version 0.8", "fileTypes": [ "lua", @@ -275,6 +280,5 @@ } }, "scopeName": "source.lua", - "uuid": "93E017CC-6F27-11D9-90EB-000D93589AF7", - "version": "https://github.com/textmate/lua.tmbundle/commit/3a97f1b46804a3de99d4d2909e14450299462f2d" + "uuid": "93E017CC-6F27-11D9-90EB-000D93589AF7" } \ No newline at end of file diff --git a/extensions/make/syntaxes/Makefile.json b/extensions/make/syntaxes/Makefile.json index 2264321c9c8..1562efc5c17 100644 --- a/extensions/make/syntaxes/Makefile.json +++ b/extensions/make/syntaxes/Makefile.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/make.tmbundle/blob/master/Syntaxes/Makefile.plist", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "Makefile", "makefile", @@ -470,6 +475,5 @@ } }, "scopeName": "source.makefile", - "uuid": "FF1825E8-6B1C-11D9-B883-000D93589AF6", - "version": "https://github.com/textmate/make.tmbundle/commit/1a1827da81e20fdce56e2658451340c070ca44b7" + "uuid": "FF1825E8-6B1C-11D9-B883-000D93589AF6" } \ No newline at end of file diff --git a/extensions/objective-c/syntaxes/objective-c++.tmLanguage.json b/extensions/objective-c/syntaxes/objective-c++.tmLanguage.json index 26550c61e1b..2b46507a2fb 100644 --- a/extensions/objective-c/syntaxes/objective-c++.tmLanguage.json +++ b/extensions/objective-c/syntaxes/objective-c++.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-objective-c/blob/master/grammars/objective-c++.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "source.objcpp", "fileTypes": [ "mm", diff --git a/extensions/objective-c/syntaxes/objective-c.tmLanguage.json b/extensions/objective-c/syntaxes/objective-c.tmLanguage.json index 2037028b0c3..a07e0ba7f43 100644 --- a/extensions/objective-c/syntaxes/objective-c.tmLanguage.json +++ b/extensions/objective-c/syntaxes/objective-c.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-objective-c/blob/master/grammars/objective-c.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "source.objc", "fileTypes": [ "m", @@ -993,6 +998,5 @@ } ] } - }, - "version": "https://github.com/atom/language-objective-c/commit/0727e04544f3414c1c339cf15a39a05ea3938cb4" + } } \ No newline at end of file diff --git a/extensions/perl/syntaxes/perl.tmLanguage.json b/extensions/perl/syntaxes/perl.tmLanguage.json index 612c4796cbe..4c4209c317b 100644 --- a/extensions/perl/syntaxes/perl.tmLanguage.json +++ b/extensions/perl/syntaxes/perl.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/perl.tmbundle/blob/master/Syntaxes/Perl.plist", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "comment": "\n\tTODO:\tInclude RegExp syntax\n", "fileTypes": [ "pl", @@ -2541,6 +2546,5 @@ } }, "scopeName": "source.perl", - "uuid": "EDBFE125-6B1C-11D9-9189-000D93589AF6", - "version": "https://github.com/textmate/perl.tmbundle/commit/c0b7a4bd65882380522d82a60b536479a62b07c3" + "uuid": "EDBFE125-6B1C-11D9-9189-000D93589AF6" } \ No newline at end of file diff --git a/extensions/perl/syntaxes/perl6.tmLanguage.json b/extensions/perl/syntaxes/perl6.tmLanguage.json index a3024a11ae7..9ddfdf42509 100644 --- a/extensions/perl/syntaxes/perl6.tmLanguage.json +++ b/extensions/perl/syntaxes/perl6.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/perl.tmbundle/blob/master/Syntaxes/Perl%206.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "p6", "pl6", @@ -314,6 +319,5 @@ } }, "scopeName": "source.perl.6", - "uuid": "E685440C-0E20-4424-9693-864D5240A269", - "version": "https://github.com/textmate/perl.tmbundle/commit/d9841a0878239fa43f88c640f8d458590f97e8f5" + "uuid": "E685440C-0E20-4424-9693-864D5240A269" } \ No newline at end of file diff --git a/extensions/php/syntaxes/php.tmLanguage.json b/extensions/php/syntaxes/php.tmLanguage.json index 8e69579120b..b815d80e072 100644 --- a/extensions/php/syntaxes/php.tmLanguage.json +++ b/extensions/php/syntaxes/php.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-php/blob/master/grammars/php.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "text.html.php", "name": "PHP", "fileTypes": [ @@ -2974,6 +2979,5 @@ } ] } - }, - "version": "https://github.com/atom/language-php/commit/c523a19f849b97f6499eae6accf80564aa190c0e" + } } \ No newline at end of file diff --git a/extensions/pug/syntaxes/pug.tmLanguage.json b/extensions/pug/syntaxes/pug.tmLanguage.json index 808be9e6db8..8a3d17a81dc 100644 --- a/extensions/pug/syntaxes/pug.tmLanguage.json +++ b/extensions/pug/syntaxes/pug.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/davidrios/jade-tmbundle/blob/master/Syntaxes/Jade.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "jade" ], @@ -981,6 +986,5 @@ } }, "scopeName": "text.jade", - "uuid": "eee6ba25-6ac2-4f7e-9c70-cddf2bd3448b", - "version": "https://github.com/davidrios/jade-tmbundle/commit/f311a516bb29296fcebfdc7da8149b1c79dfb0a1" + "uuid": "eee6ba25-6ac2-4f7e-9c70-cddf2bd3448b" } \ No newline at end of file diff --git a/extensions/python/syntaxes/MagicPython.tmLanguage.json b/extensions/python/syntaxes/MagicPython.tmLanguage.json index f9d673e6273..29e51b920fa 100644 --- a/extensions/python/syntaxes/MagicPython.tmLanguage.json +++ b/extensions/python/syntaxes/MagicPython.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/MagicStack/MagicPython/blob/master/grammars/MagicPython.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "name": "MagicPython", "scopeName": "source.python", "fileTypes": [ @@ -5230,6 +5235,5 @@ } ] } - }, - "version": "https://github.com/MagicStack/MagicPython/commit/976e59dcb78cb577e79c8f2117216c06718337e0" + } } \ No newline at end of file diff --git a/extensions/python/syntaxes/MagicRegExp.tmLanguage.json b/extensions/python/syntaxes/MagicRegExp.tmLanguage.json index b5795a7b89f..34d1a973578 100644 --- a/extensions/python/syntaxes/MagicRegExp.tmLanguage.json +++ b/extensions/python/syntaxes/MagicRegExp.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/MagicStack/MagicPython/blob/master/grammars/MagicRegExp.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "name": "MagicRegExp", "scopeName": "source.regexp.python", "fileTypes": [ @@ -460,6 +465,5 @@ } ] } - }, - "version": "https://github.com/MagicStack/MagicPython/commit/df5bb18c64252f2e7b1aa87e2ed124666d314f1d" + } } \ No newline at end of file diff --git a/extensions/r/syntaxes/r.tmLanguage.json b/extensions/r/syntaxes/r.tmLanguage.json index 829be8d0d2b..025877c7ab4 100644 --- a/extensions/r/syntaxes/r.tmLanguage.json +++ b/extensions/r/syntaxes/r.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/r.tmbundle/blob/master/Syntaxes/R.plist", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "R", "r", @@ -199,6 +204,5 @@ } ], "scopeName": "source.r", - "uuid": "B2E6B78D-6E70-11D9-A369-000D93B3A10E", - "version": "https://github.com/textmate/r.tmbundle/commit/6b04ff3424f3f1cdfe64a9cfb71d8765959be250" + "uuid": "B2E6B78D-6E70-11D9-A369-000D93B3A10E" } \ No newline at end of file diff --git a/extensions/razor/syntaxes/cshtml.json b/extensions/razor/syntaxes/cshtml.json index 402915e8c9f..180ad0e68dd 100644 --- a/extensions/razor/syntaxes/cshtml.json +++ b/extensions/razor/syntaxes/cshtml.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/demyte/language-cshtml/blob/master/grammars/cshtml.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "name": "ASP.NET Razor", "scopeName": "text.html.cshtml", "fileTypes": [ @@ -148,6 +153,5 @@ "end": "\\*@", "name": "comment.block.cshtml" } - }, - "version": "https://github.com/demyte/language-cshtml/commit/a49735dc7aef56ae772a3bcfd8e42c89895dcff4" + } } \ No newline at end of file diff --git a/extensions/ruby/syntaxes/ruby.tmLanguage.json b/extensions/ruby/syntaxes/ruby.tmLanguage.json index dce58f758b1..a6e0c01b7b9 100644 --- a/extensions/ruby/syntaxes/ruby.tmLanguage.json +++ b/extensions/ruby/syntaxes/ruby.tmLanguage.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/ruby.tmbundle/blob/master/Syntaxes/Ruby.plist", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "comment": "\n\tTODO: unresolved issues\n\n\ttext:\n\t\"p <", "name": "comment.block.xml" } - }, - "version": "https://github.com/atom/language-xml/commit/ac6bc8ef6a9c79ac3c7e31615bc18436b0c815ab" + } } \ No newline at end of file diff --git a/extensions/xml/syntaxes/xsl.json b/extensions/xml/syntaxes/xsl.json index 8b715b599f9..2193c1a9570 100644 --- a/extensions/xml/syntaxes/xsl.json +++ b/extensions/xml/syntaxes/xsl.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/atom/language-xml/blob/master/grammars/xsl.cson", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "scopeName": "text.xml.xsl", "name": "XSL", "fileTypes": [ @@ -88,6 +93,5 @@ }, "name": "string.quoted.single.xml" } - }, - "version": "https://github.com/atom/language-xml/commit/507de2ee7daca60cf02e9e21fbeb92bbae73e280" + } } \ No newline at end of file diff --git a/extensions/yaml/syntaxes/yaml.json b/extensions/yaml/syntaxes/yaml.json index 55939b86d8d..82cd7d840db 100644 --- a/extensions/yaml/syntaxes/yaml.json +++ b/extensions/yaml/syntaxes/yaml.json @@ -1,4 +1,9 @@ { + "information_for_contributors": [ + "This file has been converted from https://github.com/textmate/yaml.tmbundle/blob/master/Syntaxes/YAML.tmLanguage", + "If you want to provide a fix or improvement, please create a pull request against the original repository.", + "Once accepted there, we are happy to receive an update request." + ], "fileTypes": [ "yaml", "yml", @@ -624,6 +629,5 @@ } }, "scopeName": "source.yaml", - "uuid": "686AD6AE-33F3-4493-9512-9E9FC1D5417F", - "version": "https://github.com/textmate/yaml.tmbundle/commit/efc96efafe5e48480cf55a2ed124b388cbea4440" + "uuid": "686AD6AE-33F3-4493-9512-9E9FC1D5417F" } \ No newline at end of file -- GitLab From fa35c9a9424d5417f67db142274ea7b20c0944bf Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 13:03:01 +0200 Subject: [PATCH 0159/1347] Possible bugs around non-invoking usage of `isEmpty`. Fixes #27201 --- src/vs/editor/contrib/folding/browser/folding.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vs/editor/contrib/folding/browser/folding.ts b/src/vs/editor/contrib/folding/browser/folding.ts index 9f644ccd761..74df9c51570 100644 --- a/src/vs/editor/contrib/folding/browser/folding.ts +++ b/src/vs/editor/contrib/folding/browser/folding.ts @@ -287,7 +287,7 @@ export class FoldingController implements IFoldingController { return; } let range = e.target.range; - if (!range || !range.isEmpty) { + if (!range) { return; } if (!e.event.leftButton) { @@ -303,7 +303,7 @@ export class FoldingController implements IFoldingController { break; case MouseTargetType.CONTENT_EMPTY: case MouseTargetType.CONTENT_TEXT: - if (range.isEmpty && range.startColumn === model.getLineMaxColumn(range.startLineNumber)) { + if (range.startColumn === model.getLineMaxColumn(range.startLineNumber)) { break; } return; @@ -322,7 +322,7 @@ export class FoldingController implements IFoldingController { let iconClicked = this.mouseDownInfo.iconClicked; let range = e.target.range; - if (!range || !range.isEmpty || range.startLineNumber !== lineNumber) { + if (!range || range.startLineNumber !== lineNumber) { return; } -- GitLab From 656bde928aabfec81fea9ae735d5dde13eaa59c5 Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Thu, 25 May 2017 07:03:56 -0700 Subject: [PATCH 0160/1347] Fix failing ripgrep test --- .../services/search/test/node/ripgrepTextSearch.test.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts b/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts index 2f377d82d27..1ee3f9a6a83 100644 --- a/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts +++ b/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts @@ -70,7 +70,7 @@ suite('RipgrepParser', () => { assert.deepEqual(results[0], { numMatches: 2, - path: path.join(rootFolder, 'a.txt'), + path: path.resolve(rootFolder, 'a.txt'), lineMatches: [ { lineNumber: 0, -- GitLab From 8fcb57e8b6f02e1c977ee620473e976550969144 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Thu, 25 May 2017 17:15:23 +0200 Subject: [PATCH 0161/1347] Fixes Microsoft/monaco-editor#278 --- src/vs/editor/editor.main.ts | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/src/vs/editor/editor.main.ts b/src/vs/editor/editor.main.ts index 667a3004499..012e073ff51 100644 --- a/src/vs/editor/editor.main.ts +++ b/src/vs/editor/editor.main.ts @@ -21,10 +21,17 @@ import { EDITOR_DEFAULTS, WrappingIndent } from 'vs/editor/common/config/editorO (EDITOR_DEFAULTS.contribInfo).folding = false; (EDITOR_DEFAULTS.viewInfo).glyphMargin = false; +let base = createMonacoBaseAPI(); +for (let prop in base) { + if (base.hasOwnProperty(prop)) { + exports[prop] = base[prop]; + } +} +exports.editor = createMonacoEditorAPI(); +exports.languages = createMonacoLanguagesAPI(); + var global: any = self; -global.monaco = createMonacoBaseAPI(); -global.monaco.editor = createMonacoEditorAPI(); -global.monaco.languages = createMonacoLanguagesAPI(); +global.monaco = exports; if (typeof global.require !== 'undefined' && typeof global.require.config === 'function') { global.require.config({ -- GitLab From 735d7d07b3113e7f09f7624d4b12199c6e3a0445 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Thu, 25 May 2017 08:44:07 -0700 Subject: [PATCH 0162/1347] Move terminal.foreground defaults to JS Fixes #27230 --- .../parts/terminal/electron-browser/media/terminal.css | 3 --- .../terminal/electron-browser/terminalColorRegistry.ts | 6 +++++- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css b/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css index f35dde259bf..5a7d34f9e18 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css +++ b/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css @@ -9,12 +9,9 @@ display: flex; flex-direction: column; background-color: transparent!important; - color: #333; -webkit-user-select: initial; position: relative; } -.vs-dark .monaco-workbench .panel.integrated-terminal { color: #CCC; } -.hc-black .monaco-workbench .panel.integrated-terminal { color: #FFF; } .monaco-workbench .panel.integrated-terminal .terminal-outer-container { height: 100%; diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.ts index 27f3f23c8ba..ae1d524a912 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.ts @@ -14,7 +14,11 @@ import { registerColor, ColorIdentifier } from 'vs/platform/theme/common/colorRe export const ansiColorIdentifiers: ColorIdentifier[] = []; export const TERMINAL_BACKGROUND_COLOR = registerColor('terminal.background', null, nls.localize('terminal.background', 'The background color of the terminal, this allows coloring the terminal differently to the panel.')); -export const TERMINAL_FOREGROUND_COLOR = registerColor('terminal.foreground', null, nls.localize('terminal.foreground', 'The foreground color of the terminal.')); +export const TERMINAL_FOREGROUND_COLOR = registerColor('terminal.foreground', { + light: '#333333', + dark: '#CCCCCC', + hc: 'FFFFFF' +}, nls.localize('terminal.foreground', 'The foreground color of the terminal.')); const ansiColorMap = { 'terminal.ansiBlack': { -- GitLab From 3356f28259ca3f95c2b8112b875a3fe79aa18a15 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Thu, 25 May 2017 08:44:54 -0700 Subject: [PATCH 0163/1347] Remove deprecated css property --- .../parts/terminal/electron-browser/media/terminal.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css b/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css index 5a7d34f9e18..f2cc6747e2c 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css +++ b/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css @@ -9,7 +9,7 @@ display: flex; flex-direction: column; background-color: transparent!important; - -webkit-user-select: initial; + user-select: initial; position: relative; } -- GitLab From d0de62ea2b7158b2c5882928c7d079b4fafd1b56 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 25 May 2017 09:09:41 -0700 Subject: [PATCH 0164/1347] More welcome page colors (#25798) --- .../electron-browser/vs_code_welcome_page.ts | 38 +++++----- .../page/electron-browser/welcomePage.css | 69 +------------------ .../page/electron-browser/welcomePage.ts | 26 ++++++- 3 files changed, 47 insertions(+), 86 deletions(-) diff --git a/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.ts b/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.ts index cc27fe4978c..767ee36747a 100644 --- a/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.ts +++ b/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.ts @@ -14,13 +14,13 @@ export default () => `
-

${escape(localize('welcomePage.vscode', "Visual Studio Code"))}

-

${escape(localize('welcomePage.editingEvolved', "Editing evolved"))}

+

${escape(localize('welcomePage.vscode', "Visual Studio Code"))}

+

${escape(localize('welcomePage.editingEvolved', "Editing evolved"))}

-

${escape(localize('welcomePage.start', "Start"))}

+

${escape(localize('welcomePage.start', "Start"))}

-

${escape(localize('welcomePage.recent', "Recent"))}

+

${escape(localize('welcomePage.recent', "Recent"))}

-

${escape(localize('welcomePage.noRecentFolders', "No recent folders"))}

+

${escape(localize('welcomePage.noRecentFolders', "No recent folders"))}

-

+

-

${escape(localize('welcomePage.customize', "Customize"))}

+

${escape(localize('welcomePage.customize', "Customize"))}

    -
  • -
  • -
  • +
-

${escape(localize('welcomePage.learn', "Learn"))}

+

${escape(localize('welcomePage.learn', "Learn"))}

    -
  • -
  • -
  • +
  • +
  • +
diff --git a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.css b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.css index 982a72d9d1b..a3c2fa3e686 100644 --- a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.css +++ b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.css @@ -16,9 +16,6 @@ max-width: 1200px; font-size: 10px; } -.vs .monaco-workbench > .part.editor > .content .welcomePage { - color: #6C6C6C; -} .monaco-workbench > .part.editor > .content .welcomePage .row { display: flex; @@ -41,66 +38,36 @@ } .monaco-workbench > .part.editor > .content .welcomePage a { - color: #2e70c0; text-decoration: none; } -.vs-dark .monaco-workbench > .part.editor > .content .welcomePage a { - color: #4080D0; -} - .monaco-workbench > .part.editor > .content .welcomePage a:focus { outline: 1px solid -webkit-focus-ring-color; outline-offset: -1px; } -.monaco-workbench > .part.editor > .content .welcomePage a:hover { - color: #6ea0dc; -} - -.hc-black .monaco-workbench > .part.editor > .content .welcomePage a { - color: #0b9eff; -} - -.hc-black .monaco-workbench > .part.editor > .content .welcomePage a:hover { - color: #f38518; -} - .monaco-workbench > .part.editor > .content .welcomePage h1 { padding: 0; margin: 0; border: none; font-weight: normal; - color: rgba(0,0,0,.8); font-size: 3.6em; white-space: nowrap; } -.vs-dark .monaco-workbench > .part.editor > .content .welcomePage h1 { - color: rgba(255,255,255,.76); -} - -.hc-black .monaco-workbench > .part.editor > .content .welcomePage h1 { - color: white; -} - .monaco-workbench > .part.editor > .content .welcomePage .title { margin-top: 1em; margin-bottom: 1em; flex: 1 100%; } + .monaco-workbench > .part.editor > .content .welcomePage .subtitle { margin-top: .8em; font-size: 2.6em; - color: rgba(0,0,0,.53); display: block; } -.vs-dark .monaco-workbench > .part.editor > .content .welcomePage .subtitle { - color: rgba(255,255,255,.46); -} .hc-black .monaco-workbench > .part.editor > .content .welcomePage .subtitle { - color: white; font-weight: 200; } @@ -150,22 +117,6 @@ } .monaco-workbench > .part.editor > .content .welcomePage .splash .recent .path { padding-left: 1em; - color: rgba(255,255,255,.46); -} - -.monaco-workbench > .part.editor > .content .welcomePage .splash .recent .none, -.monaco-workbench > .part.editor > .content .welcomePage .splash .recent .path { - color: rgba(0,0,0,.53); -} - -.vs-dark .monaco-workbench > .part.editor > .content .welcomePage .splash .recent .none, -.vs-dark .monaco-workbench > .part.editor > .content .welcomePage .splash .recent .path { - color: rgba(255,255,255,.46); -} - -.hc-black .monaco-workbench > .part.editor > .content .welcomePage .splash .recent .none, -.hc-black .monaco-workbench > .part.editor > .content .welcomePage .splash .recent .path { - color: white; } .monaco-workbench > .part.editor > .content .welcomePage .splash .title, @@ -207,41 +158,27 @@ margin-bottom: .25em; } -.vs .monaco-workbench > .part.editor > .content .welcomePage .commands li button h3 { - color: #2c2c2c; -} - .monaco-workbench > .part.editor > .content .welcomePage .commands li button { - color: #6c6c6c; border: none; } -.vs-dark .monaco-workbench > .part.editor > .content .welcomePage .commands li button > h3 { - color: #ccc; -} - .hc-black .monaco-workbench > .part.editor > .content .welcomePage .commands li button > h3 { font-weight: bold; } -.vs-dark .monaco-workbench > .part.editor > .content .welcomePage .commands li button { - color: #828282; -} - .monaco-workbench > .part.editor > .content .welcomePage .commands li button:focus { outline-style: solid; outline-width: 1px; } .hc-black .monaco-workbench > .part.editor > .content .welcomePage .commands li button { - color: white; - border-color: #f38518; border-width: 1px; border-style: solid; } .hc-black .monaco-workbench > .part.editor > .content .welcomePage .commands li button:hover { - outline: 1px dashed #f38518; + outline-width: 1px; + outline-style: dashed; outline-offset: -5px; } diff --git a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts index 874bc17d8dd..86dde1dd27d 100644 --- a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts +++ b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts @@ -35,7 +35,7 @@ import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { tildify } from 'vs/base/common/labels'; import { isLinux } from 'vs/base/common/platform'; import { IThemeService, registerThemingParticipant } from 'vs/platform/theme/common/themeService'; -import { registerColor } from 'vs/platform/theme/common/colorRegistry'; +import { registerColor, textLinkForeground, foreground, contrastBorder, activeContrastBorder } from 'vs/platform/theme/common/colorRegistry'; import { getExtraColor } from 'vs/workbench/parts/welcome/walkThrough/node/walkThroughUtils'; used(); @@ -240,6 +240,7 @@ class WelcomePage { const span = document.createElement('span'); span.classList.add('path'); + span.classList.add('detail'); span.innerText = tildify(parentFolder, this.environmentService.userHome); span.title = folder; li.appendChild(span); @@ -446,10 +447,21 @@ class WelcomePage { // theming +const caption = registerColor('welcomePage.caption', { dark: '#FFFFFFC2', light: '#000000D4', hc: foreground }, localize('welcomePage.caption', 'Caption color on the Welcome page.')); +const detail = registerColor('welcomePage.detail', { dark: '#FFFFFF76', light: '#00000088', hc: foreground }, localize('welcomePage.detail', 'Detail color on the Welcome page.')); + const quickLinkBackground = registerColor('welcomePage.quickLinkBackground', { dark: null, light: null, hc: null }, localize('welcomePage.quickLinkBackground', 'Background color for the quick links on the Welcome page.')); const quickLinkHoverBackground = registerColor('welcomePage.quickLinkHoverBackground', { dark: null, light: null, hc: null }, localize('welcomePage.quickLinkHoverBackground', 'Hover background color for the quick links on the Welcome page.')); registerThemingParticipant((theme, collector) => { + const captionColor = theme.getColor(caption); + if (captionColor) { + collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .caption { color: ${captionColor}; }`); + } + const detailColor = theme.getColor(detail); + if (detailColor) { + collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .detail { color: ${detailColor}; }`); + } const color = getExtraColor(theme, quickLinkBackground, { dark: 'rgba(0, 0, 0, .2)', extra_dark: 'rgba(200, 235, 255, .042)', light: 'rgba(0,0,0,.04)', hc: 'black' }); if (color) { collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .commands li button { background: ${color}; }`); @@ -458,4 +470,16 @@ registerThemingParticipant((theme, collector) => { if (hover) { collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .commands li button:hover { background: ${hover}; }`); } + const link = theme.getColor(textLinkForeground); + if (link) { + collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage a { color: ${link}; }`); + } + const border = theme.getColor(contrastBorder); + if (border) { + collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .commands li button { border-color: ${border}; }`); + } + const activeBorder = theme.getColor(activeContrastBorder); + if (activeBorder) { + collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .commands li button:hover { outline-color: ${activeBorder}; }`); + } }); -- GitLab From 60a5167e093ae2a95defac1a6c77976986ac7467 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 25 May 2017 09:49:50 -0700 Subject: [PATCH 0165/1347] Playground colors (#25798) --- .../electron-browser/walkThroughPart.css | 30 ++----------------- .../electron-browser/walkThroughPart.ts | 23 +++++++++++++- 2 files changed, 24 insertions(+), 29 deletions(-) diff --git a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.css b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.css index baaf1f3ceed..305fece6c6b 100644 --- a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.css +++ b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.css @@ -17,7 +17,6 @@ } .monaco-workbench > .part.editor > .content .walkThroughContent a { - color: #4080D0; text-decoration: none; } @@ -69,7 +68,6 @@ } .monaco-workbench > .part.editor > .content .walkThroughContent a:hover { - color: #4080D0; text-decoration: underline; } @@ -106,36 +104,11 @@ line-height: 19px; } -/*.monaco-workbench.mac > .part.editor > .content .walkThroughContent code, -.monaco-workbench.mac > .part.editor > .content .walkThroughContent .shortcut { - font-size: 12px; - line-height: 18px; -}*/ - -.vs .monaco-workbench > .part.editor > .content .walkThroughContent code, -.vs .monaco-workbench > .part.editor > .content .walkThroughContent .shortcut { - color: #A31515; -} - -.vs-dark .monaco-workbench > .part.editor > .content .walkThroughContent code, -.vs-dark .monaco-workbench > .part.editor > .content .walkThroughContent .shortcut { - color: #D7BA7D; -} - .monaco-workbench > .part.editor > .content .walkThroughContent blockquote { margin: 0 7px 0 5px; padding: 0 16px 0 10px; border-left: 5px solid; } -.vs .monaco-workbench > .part.editor > .content .walkThroughContent blockquote, -.vs-dark .monaco-workbench > .part.editor > .content .walkThroughContent blockquote { - background: rgba(127, 127, 127, 0.1); - border-color: rgba(0, 122, 204, 0.5); -} -.hc-black .monaco-workbench > .part.editor > .content .walkThroughContent blockquote { - background: transparent; - border-color: #fff; -} .monaco-workbench > .part.editor > .content .walkThroughContent .monaco-tokenized-source { white-space: pre; @@ -162,5 +135,6 @@ } .hc-black .monaco-workbench > .part.editor > .content .walkThroughContent .monaco-editor { - border: 1px white solid + border-width: 1px; + border-style: solid; } diff --git a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts index 2fcbace413f..f22fa7e0702 100644 --- a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts +++ b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts @@ -38,7 +38,7 @@ import { IPartService } from 'vs/workbench/services/part/common/partService'; import { IEditorOptions } from 'vs/editor/common/config/editorOptions'; import { IMessageService, Severity } from 'vs/platform/message/common/message'; import { IThemeService, registerThemingParticipant } from 'vs/platform/theme/common/themeService'; -import { registerColor } from 'vs/platform/theme/common/colorRegistry'; +import { registerColor, textLinkForeground, textPreformatForeground, contrastBorder, textBlockQuoteBackground, textBlockQuoteBorder } from 'vs/platform/theme/common/colorRegistry'; import { getExtraColor } from 'vs/workbench/parts/welcome/walkThrough/node/walkThroughUtils'; export const WALK_THROUGH_FOCUS = new RawContextKey('interactivePlaygroundFocus', false); @@ -534,4 +534,25 @@ registerThemingParticipant((theme, collector) => { collector.addRule(`.monaco-workbench > .part.editor > .content .walkThroughContent .monaco-editor-background, .monaco-workbench > .part.editor > .content .walkThroughContent .margin-view-overlays { background: ${color}; }`); } + const link = theme.getColor(textLinkForeground); + if (link) { + collector.addRule(`.monaco-workbench > .part.editor > .content .walkThroughContent a { color: ${link}; }`); + } + const shortcut = theme.getColor(textPreformatForeground); + if (shortcut) { + collector.addRule(`.monaco-workbench > .part.editor > .content .walkThroughContent code, + .monaco-workbench > .part.editor > .content .walkThroughContent .shortcut { color: ${shortcut}; }`); + } + const border = theme.getColor(contrastBorder); + if (border) { + collector.addRule(`.monaco-workbench > .part.editor > .content .walkThroughContent .monaco-editor { border-color: ${border}; }`); + } + const quoteBackground = theme.getColor(textBlockQuoteBackground); + if (quoteBackground) { + collector.addRule(`.monaco-workbench > .part.editor > .content .walkThroughContent blockquote { background: ${quoteBackground}; }`); + } + const quoteBorder = theme.getColor(textBlockQuoteBorder); + if (quoteBorder) { + collector.addRule(`.monaco-workbench > .part.editor > .content .walkThroughContent blockquote { border-color: ${quoteBorder}; }`); + } }); \ No newline at end of file -- GitLab From fb5eab501353456adc7523b3582ca3c0535d3466 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 25 May 2017 10:25:46 -0700 Subject: [PATCH 0166/1347] Overlay color (#25798) --- .../overlay/browser/welcomeOverlay.css | 15 ------------- .../welcome/overlay/browser/welcomeOverlay.ts | 22 +++++++++++++++++++ 2 files changed, 22 insertions(+), 15 deletions(-) diff --git a/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.css b/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.css index 6aa8c04e789..50cf77eafad 100644 --- a/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.css +++ b/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.css @@ -10,15 +10,10 @@ height: 100%; width: 100%; z-index: 9999; - background: rgba(0,0,0,0.52); font-size: 10px; transition: font-size .25s; } -.vs .monaco-workbench > .welcomeOverlay { - background: rgba(255,255,255,.52); -} - #workbench\.parts\.editor { transition: filter .25s, opacity .2s; } @@ -40,15 +35,6 @@ font-size: 1.6em; } -.monaco-workbench > .welcomeOverlay > .key { - color: #000; -} - -.vs-dark .monaco-workbench > .welcomeOverlay > .key, -.hc-black .monaco-workbench > .welcomeOverlay > .key { - color: #FFF; -} - .monaco-workbench > .welcomeOverlay > .key > .label { padding: 0 1ex; } @@ -56,7 +42,6 @@ .monaco-workbench > .welcomeOverlay > .key > .shortcut { letter-spacing: 0.15em; font-size: 0.8125em; - color: #d7ba7d; font-family: "Lucida Grande", sans-serif; } diff --git a/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.ts b/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.ts index 8a3bb16246a..d5a435aac22 100644 --- a/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.ts +++ b/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.ts @@ -22,6 +22,8 @@ import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { RawContextKey, IContextKey, IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; import { KeyCode } from 'vs/base/common/keyCodes'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; +import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; +import { registerColor, textPreformatForeground } from 'vs/platform/theme/common/colorRegistry'; interface Key { id: string; @@ -233,3 +235,23 @@ Registry.as(Extensions.WorkbenchActions) Registry.as(Extensions.WorkbenchActions) .registerWorkbenchAction(new SyncActionDescriptor(HideWelcomeOverlayAction, HideWelcomeOverlayAction.ID, HideWelcomeOverlayAction.LABEL, { primary: KeyCode.Escape }, OVERLAY_VISIBLE), 'Help: Hide Interface Overview', localize('help', "Help")); + +// theming + +const foreground = registerColor('welcomeOverlay.foreground', { dark: '#fff', light: '#000', hc: '#fff' }, localize('welcomeOverlay.foreground', 'Foreground color for the Interface Overview.')); +const background = registerColor('welcomeOverlay.background', { dark: '#00000085', light: '#FFFFFF85', hc: '#00000085' }, localize('welcomeOverlay.background', 'Background color for the Interface Overview.')); + +registerThemingParticipant((theme, collector) => { + const key = theme.getColor(foreground); + if (key) { + collector.addRule(`.monaco-workbench > .welcomeOverlay > .key { color: ${key}; }`); + } + const backgroundColor = theme.getColor(background); + if (backgroundColor) { + collector.addRule(`.monaco-workbench > .welcomeOverlay { background: ${backgroundColor}; }`); + } + const shortcut = theme.getColor(textPreformatForeground); + if (shortcut) { + collector.addRule(`.monaco-workbench > .welcomeOverlay > .key > .shortcut { color: ${shortcut}; }`); + } +}); -- GitLab From dbeb66f8fd416f58d4a3b7b5d76f84c1d5b56811 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Thu, 25 May 2017 11:07:55 -0700 Subject: [PATCH 0167/1347] Add null check in terminalPanel click listener Fixes #27256 --- .../parts/terminal/electron-browser/terminalPanel.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts index ec880bdd12c..4b5a29f34c4 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts @@ -197,11 +197,12 @@ export class TerminalPanel extends Panel { this._cancelContextMenu = false; })); this._register(dom.addDisposableListener(this._parentDomElement, 'click', (event) => { - if (this._terminalService.terminalInstances.length === 0) { + if (event.which === 3) { return; } - if (event.which !== 3) { + const instance = this._terminalService.getActiveInstance(); + if (instance) { this._terminalService.getActiveInstance().focus(); } })); -- GitLab From f0ebd2b48287f0cdbe6f93a93c7af4009afae2d0 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Thu, 25 May 2017 11:11:40 -0700 Subject: [PATCH 0168/1347] Add null check to terminal link handler Fixes #27247 --- .../terminal/electron-browser/terminalLinkHandler.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.ts index 49df15b331a..16047707ea7 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.ts @@ -226,12 +226,15 @@ export class TerminalLinkHandler { private _resolvePath(link: string): TPromise { link = this._preprocessPath(link); - if (!link) { return TPromise.as(void 0); } const linkUrl = this.extractLinkUrl(link); + if (!linkUrl) { + return TPromise.as(void 0); + } + // Open an editor if the path exists return pfs.fileExists(linkUrl).then(isFile => { if (!isFile) { @@ -292,6 +295,9 @@ export class TerminalLinkHandler { */ public extractLinkUrl(link: string): string { const matches: string[] = this._localLinkRegex.exec(link); + if (!matches) { + return null; + } return matches[1]; } } -- GitLab From f962f52cd4c13c1dea6572a496b96bf628ca7d56 Mon Sep 17 00:00:00 2001 From: rebornix Date: Thu, 25 May 2017 11:25:34 -0700 Subject: [PATCH 0169/1347] Fix #27265. False positve --- src/vs/editor/contrib/find/common/findController.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/vs/editor/contrib/find/common/findController.ts b/src/vs/editor/contrib/find/common/findController.ts index 4536b2b5b6f..a5dae70a8dc 100644 --- a/src/vs/editor/contrib/find/common/findController.ts +++ b/src/vs/editor/contrib/find/common/findController.ts @@ -508,13 +508,13 @@ export class StartFindReplaceAction extends EditorAction { let controller = CommonFindController.get(editor); let currentSelection = editor.getSelection(); // we only seed search string from selection when the current selection is single line and not empty. - let seedSearchStringFromSelection = currentSelection.isEmpty() || - currentSelection.startLineNumber !== currentSelection.endLineNumber; + let seedSearchStringFromSelection = !currentSelection.isEmpty() && + currentSelection.startLineNumber === currentSelection.endLineNumber; let oldSearchString = controller.getState().searchString; // if the existing search string in find widget is empty and we don't seed search string from selection, it means the Find Input // is still empty, so we should focus the Find Input instead of Replace Input. - let shouldFocus = !oldSearchString && seedSearchStringFromSelection ? - FindStartFocusAction.FocusFindInput : FindStartFocusAction.FocusReplaceInput; + let shouldFocus = (!!oldSearchString || seedSearchStringFromSelection) ? + FindStartFocusAction.FocusReplaceInput : FindStartFocusAction.FocusFindInput; if (controller) { controller.start({ -- GitLab From 29a7a86c3afcc98ad4f96e4b6193cf41877131bc Mon Sep 17 00:00:00 2001 From: Ramya Rao Date: Thu, 25 May 2017 13:10:39 -0700 Subject: [PATCH 0170/1347] Start crash reporter inside child processes (#27180) * Use service to get crash reporter start options * some refactorings and fixes * Move crashesDirectory to the main payload from extra bag --- src/bootstrap.js | 12 +++ src/typings/electron.d.ts | 7 ++ .../electron-browser/crashReporter.ts | 71 --------------- .../electron-browser/extensionHost.ts | 12 ++- src/vs/workbench/electron-browser/shell.ts | 32 ++----- .../common/crashReporterService.ts | 43 +++++++++ .../electron-browser/crashReporterService.ts | 91 +++++++++++++++++++ 7 files changed, 171 insertions(+), 97 deletions(-) delete mode 100644 src/vs/workbench/electron-browser/crashReporter.ts create mode 100644 src/vs/workbench/services/crashReporter/common/crashReporterService.ts create mode 100644 src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts diff --git a/src/bootstrap.js b/src/bootstrap.js index 022aa50b6a3..3f94abadd31 100644 --- a/src/bootstrap.js +++ b/src/bootstrap.js @@ -126,4 +126,16 @@ if (process.env['VSCODE_PARENT_PID']) { } } +const crashReporterOptionsRaw = process.env['CRASH_REPORTER_START_OPTIONS']; +if (typeof crashReporterOptionsRaw === 'string') { + try { + const crashReporterOptions = JSON.parse(crashReporterOptionsRaw); + if (crashReporterOptions) { + process.crashReporter.start(crashReporterOptions); + } + } catch (error) { + console.error(error); + } +} + require('./bootstrap-amd').bootstrap(process.env['AMD_ENTRYPOINT']); \ No newline at end of file diff --git a/src/typings/electron.d.ts b/src/typings/electron.d.ts index 5a1f5ea3430..05aab3a8161 100644 --- a/src/typings/electron.d.ts +++ b/src/typings/electron.d.ts @@ -2066,6 +2066,13 @@ declare namespace Electron { * Only string properties are sent correctly, nested objects are not supported. */ extra?: { [prop: string]: string }; + + /** + * Path to a folder where the crashes will be temporarily stored by the electron crash reporter + * Applies only to child processes that need crash reporting. + * Electron figures out the crashesDirectory on its own for Main and Renderer process + */ + crashesDirectory?: string; } interface CrashReport { diff --git a/src/vs/workbench/electron-browser/crashReporter.ts b/src/vs/workbench/electron-browser/crashReporter.ts deleted file mode 100644 index 119229bc2d4..00000000000 --- a/src/vs/workbench/electron-browser/crashReporter.ts +++ /dev/null @@ -1,71 +0,0 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ -'use strict'; - -import nls = require('vs/nls'); -import { onUnexpectedError } from 'vs/base/common/errors'; -import { assign, clone } from 'vs/base/common/objects'; -import { IConfigurationRegistry, Extensions } from 'vs/platform/configuration/common/configurationRegistry'; -import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { IWindowsService } from 'vs/platform/windows/common/windows'; -import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; -import { Registry } from 'vs/platform/platform'; -import { crashReporter } from 'electron'; -import product from 'vs/platform/node/product'; -import pkg from 'vs/platform/node/package'; - -const TELEMETRY_SECTION_ID = 'telemetry'; - -interface ICrashReporterConfig { - enableCrashReporter: boolean; -} - -const configurationRegistry = Registry.as(Extensions.Configuration); -configurationRegistry.registerConfiguration({ - 'id': TELEMETRY_SECTION_ID, - 'order': 110, - title: nls.localize('telemetryConfigurationTitle', "Telemetry"), - 'type': 'object', - 'properties': { - 'telemetry.enableCrashReporter': { - 'type': 'boolean', - 'description': nls.localize('telemetry.enableCrashReporting', "Enable crash reports to be sent to Microsoft.\nThis option requires restart to take effect."), - 'default': true - } - } -}); - -export class CrashReporter { - - constructor( - configuration: Electron.CrashReporterStartOptions, - @ITelemetryService telemetryService: ITelemetryService, - @IWindowsService windowsService: IWindowsService, - @IConfigurationService configurationService: IConfigurationService - ) { - const config = configurationService.getConfiguration(TELEMETRY_SECTION_ID); - - if (!config.enableCrashReporter) { - return; - } - - telemetryService.getTelemetryInfo() - .then(info => ({ - vscode_sessionId: info.sessionId, - vscode_version: pkg.version, - vscode_commit: product.commit, - vscode_machineId: info.machineId - })) - .then(extra => assign(configuration, { extra })) - .then(configuration => { - // start crash reporter right here - crashReporter.start(clone(configuration)); - - // TODO: start crash reporter in the main process - return windowsService.startCrashReporter(configuration); - }) - .done(null, onUnexpectedError); - } -} \ No newline at end of file diff --git a/src/vs/workbench/electron-browser/extensionHost.ts b/src/vs/workbench/electron-browser/extensionHost.ts index e8f82622b43..2431281d98e 100644 --- a/src/vs/workbench/electron-browser/extensionHost.ts +++ b/src/vs/workbench/electron-browser/extensionHost.ts @@ -32,6 +32,7 @@ import Event, { Emitter } from 'vs/base/common/event'; import { IInitData } from 'vs/workbench/api/node/extHost.protocol'; import { MainProcessExtensionService } from 'vs/workbench/api/electron-browser/mainThreadExtensionService'; import { IWorkspaceConfigurationService } from 'vs/workbench/services/configuration/common/configuration'; +import { ICrashReporterService } from 'vs/workbench/services/crashReporter/common/crashReporterService'; export const EXTENSION_LOG_BROADCAST_CHANNEL = 'vscode:extensionLog'; export const EXTENSION_ATTACH_BROADCAST_CHANNEL = 'vscode:extensionAttach'; @@ -92,7 +93,9 @@ export class ExtensionHostProcessWorker { @IInstantiationService private instantiationService: IInstantiationService, @IEnvironmentService private environmentService: IEnvironmentService, @IWorkspaceConfigurationService private configurationService: IWorkspaceConfigurationService, - @ITelemetryService private telemetryService: ITelemetryService + @ITelemetryService private telemetryService: ITelemetryService, + @ICrashReporterService private crashReporterService: ICrashReporterService + ) { // handle extension host lifecycle a bit special when we know we are developing an extension that runs inside this.isExtensionDevelopmentHost = environmentService.isExtensionDevelopment; @@ -111,7 +114,7 @@ export class ExtensionHostProcessWorker { const [server, hook] = <[Server, string]>data[0]; const port = data[1]; - let opts = { + const opts = { env: objects.mixin(objects.clone(process.env), { AMD_ENTRYPOINT: 'vs/workbench/node/extensionHostProcess', PIPE_LOGGING: 'true', @@ -130,6 +133,11 @@ export class ExtensionHostProcessWorker { : undefined }; + const crashReporterOptions = this.crashReporterService.getChildProcessStartOptions('extensionHost'); + if (crashReporterOptions) { + opts.env.CRASH_REPORTER_START_OPTIONS = JSON.stringify(crashReporterOptions); + } + // Run Extension Host as fork of current process this.extensionHostProcess = fork(URI.parse(require.toUrl('bootstrap')).fsPath, ['--type=extensionHost'], opts); diff --git a/src/vs/workbench/electron-browser/shell.ts b/src/vs/workbench/electron-browser/shell.ts index da3ce116627..66e974a00c7 100644 --- a/src/vs/workbench/electron-browser/shell.ts +++ b/src/vs/workbench/electron-browser/shell.ts @@ -73,7 +73,8 @@ import { IExtensionService } from 'vs/platform/extensions/common/extensions'; import { WorkbenchModeServiceImpl } from 'vs/workbench/services/mode/common/workbenchModeService'; import { IModeService } from 'vs/editor/common/services/modeService'; import { IUntitledEditorService, UntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; -import { CrashReporter } from 'vs/workbench/electron-browser/crashReporter'; +import { ICrashReporterService, NullCrashReporterService } from 'vs/workbench/services/crashReporter/common/crashReporterService'; +import { CrashReporterService } from 'vs/workbench/services/crashReporter/electron-browser/crashReporterService'; import { NodeCachedDataManager } from 'vs/workbench/electron-browser/nodeCachedDataManager'; import { getDelayedChannel } from 'vs/base/parts/ipc/common/ipc'; import { connect as connectNet } from 'vs/base/parts/ipc/node/ipc.net'; @@ -168,29 +169,6 @@ export class WorkbenchShell { // Instantiation service with services const [instantiationService, serviceCollection] = this.initServiceCollection(parent.getHTMLElement()); - //crash reporting - if (product.crashReporter && product.hockeyApp) { - let submitURL: string; - - if (platform.isWindows) { - submitURL = product.hockeyApp[`win32-${process.arch}`]; - } else if (platform.isMacintosh) { - submitURL = product.hockeyApp.darwin; - } else if (platform.isLinux) { - submitURL = product.hockeyApp[`linux-${process.arch}`]; - } - - if (submitURL) { - const opts: Electron.CrashReporterStartOptions = { - companyName: product.crashReporter.companyName, - productName: product.crashReporter.productName, - submitURL - }; - - instantiationService.createInstance(CrashReporter, opts); - } - } - // Workbench this.workbench = instantiationService.createInstance(Workbench, parent.getHTMLElement(), workbenchContainer.getHTMLElement(), this.options, serviceCollection); this.workbench.startup({ @@ -333,6 +311,12 @@ export class WorkbenchShell { serviceCollection.set(ITelemetryService, this.telemetryService); disposables.add(configurationTelemetry(this.telemetryService, this.configurationService)); + let crashReporterService = NullCrashReporterService; + if (product.crashReporter && product.hockeyApp) { + crashReporterService = instantiationService.createInstance(CrashReporterService); + } + serviceCollection.set(ICrashReporterService, crashReporterService); + this.messageService = instantiationService.createInstance(MessageService, container); serviceCollection.set(IMessageService, this.messageService); serviceCollection.set(IChoiceService, this.messageService); diff --git a/src/vs/workbench/services/crashReporter/common/crashReporterService.ts b/src/vs/workbench/services/crashReporter/common/crashReporterService.ts new file mode 100644 index 00000000000..4ce3933901d --- /dev/null +++ b/src/vs/workbench/services/crashReporter/common/crashReporterService.ts @@ -0,0 +1,43 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +'use strict'; + +import nls = require('vs/nls'); +import { IConfigurationRegistry, Extensions } from 'vs/platform/configuration/common/configurationRegistry'; +import { Registry } from 'vs/platform/platform'; +import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; + +export const ICrashReporterService = createDecorator('crashReporterService'); + +export const TELEMETRY_SECTION_ID = 'telemetry'; + +export interface ICrashReporterConfig { + enableCrashReporter: boolean; +} + +const configurationRegistry = Registry.as(Extensions.Configuration); +configurationRegistry.registerConfiguration({ + 'id': TELEMETRY_SECTION_ID, + 'order': 110, + title: nls.localize('telemetryConfigurationTitle', "Telemetry"), + 'type': 'object', + 'properties': { + 'telemetry.enableCrashReporter': { + 'type': 'boolean', + 'description': nls.localize('telemetry.enableCrashReporting', "Enable crash reports to be sent to Microsoft.\nThis option requires restart to take effect."), + 'default': true + } + } +}); + +export interface ICrashReporterService { + _serviceBrand: any; + getChildProcessStartOptions(processName: string): Electron.CrashReporterStartOptions; +} + +export const NullCrashReporterService: ICrashReporterService = { + _serviceBrand: undefined, + getChildProcessStartOptions(processName: string) { return undefined; } +}; \ No newline at end of file diff --git a/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts b/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts new file mode 100644 index 00000000000..58cca417c6b --- /dev/null +++ b/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts @@ -0,0 +1,91 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +'use strict'; + +import { onUnexpectedError } from 'vs/base/common/errors'; +import { assign, clone } from 'vs/base/common/objects'; +import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; +import { IWindowsService } from 'vs/platform/windows/common/windows'; +import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; +import { crashReporter } from 'electron'; +import product from 'vs/platform/node/product'; +import pkg from 'vs/platform/node/package'; +import * as os from 'os'; +import { ICrashReporterService, TELEMETRY_SECTION_ID, ICrashReporterConfig } from "vs/workbench/services/crashReporter/common/crashReporterService"; +import { isWindows, isMacintosh, isLinux } from "vs/base/common/platform"; + +export class CrashReporterService implements ICrashReporterService { + + public _serviceBrand: any; + + private options: Electron.CrashReporterStartOptions; + + constructor( + @ITelemetryService private telemetryService: ITelemetryService, + @IWindowsService private windowsService: IWindowsService, + @IConfigurationService configurationService: IConfigurationService + ) { + const config = configurationService.getConfiguration(TELEMETRY_SECTION_ID); + if (config.enableCrashReporter) { + this.startCrashReporter(); + } + } + + private startCrashReporter(): void { + + // base options + this.options = { + companyName: product.crashReporter.companyName, + productName: product.crashReporter.productName, + submitURL: this.getSubmitURL() + }; + + // mixin telemetry info and product info + this.telemetryService.getTelemetryInfo() + .then(info => { + assign(this.options, { + extra: { + vscode_sessionId: info.sessionId, + vscode_version: pkg.version, + vscode_commit: product.commit, + vscode_machineId: info.machineId + } + }); + + // start crash reporter right here + crashReporter.start(clone(this.options)); + + // start crash reporter in the main process + return this.windowsService.startCrashReporter(this.options); + }) + .done(null, onUnexpectedError); + } + + private getSubmitURL(): string { + let submitURL: string; + if (isWindows) { + submitURL = product.hockeyApp[`win32-${process.arch}`]; + } else if (isMacintosh) { + submitURL = product.hockeyApp.darwin; + } else if (isLinux) { + submitURL = product.hockeyApp[`linux-${process.arch}`]; + } + + return submitURL; + } + + public getChildProcessStartOptions(name: string): Electron.CrashReporterStartOptions { + + // Experimental attempt on Mac only for now + if (isMacintosh) { + const childProcessOptions = clone(this.options); + childProcessOptions.extra.processName = name; + childProcessOptions.crashesDirectory = os.tmpdir(); + return childProcessOptions; + } + + return void 0; + } +} \ No newline at end of file -- GitLab From 0dd3f6b7bddfca066152e380c21764787a326296 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Thu, 25 May 2017 13:18:23 -0700 Subject: [PATCH 0171/1347] Fixes #27287 --- .../parts/emmet/electron-browser/actions/expandAbbreviation.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.ts b/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.ts index f046995c799..26125b52a0f 100644 --- a/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.ts +++ b/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.ts @@ -33,7 +33,7 @@ class ExpandAbbreviationAction extends BasicEmmetEditorAction { EditorContextKeys.hasSingleSelection, EditorContextKeys.tabDoesNotMoveFocus, ContextKeyExpr.has('config.emmet.triggerExpansionOnTab'), - ContextKeyExpr.not('config.emmet.suggestExpandedAbbreviation') + ContextKeyExpr.not('config.emmet.useModules') ) } ); -- GitLab From 23f76d4e468bd9aa6fea291fc23a38049a7c9d8c Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 25 May 2017 22:40:41 +0200 Subject: [PATCH 0172/1347] [seti] Update to jesseweed/seti-ui@f78d623 (2017-05-11) --- extensions/theme-seti/icons/seti.woff | Bin 30512 -> 30516 bytes .../theme-seti/icons/vs-seti-icon-theme.json | 496 ++++++++++-------- 2 files changed, 281 insertions(+), 215 deletions(-) diff --git a/extensions/theme-seti/icons/seti.woff b/extensions/theme-seti/icons/seti.woff index d1411ae52218317ccb3d374bfa42e106da8ef2fa..5dd4c46c58c12024e051f21d7b8f946184a7f638 100644 GIT binary patch delta 30249 zcmV)EK)}DS?g6y!0Tg#nMn(Vu00000cQgPC00000wk(kpK7T|YV{Kt@0004m0007_ z000O$@Ff;YXKZ<9000Ci003=_005&b)jrC{Xk}q!0042c0000k0000s4T~ioXlP|& z004310000S0000a2fPI+Xl-0043z0002+0002+ z)}8~*ZDDwD05<@05C8xG9{>OVAOcVd5pH2^WdHzkFaQ7n9smFV=H5yf%y4gWbN~Q! zPyhe|;{X5zF9PoGZIcKAL4SV5IDvtcfr05K(;fx}h8_sb_<+HXkqIcuz{<>k6$GTY zrZ6}>V0=)^`~t|00+T?EAOZkRjSR2=0C=43)CW>jK^R5hGcbTiPLc!x0f_mdU${LsTu0k04YFn&=SNUX@*#MMSpBO+>J%|lert+ zkH^ZQJ#pPn+}z%VYfRVhcRac#g}w1mOeKvwq=$1EWRgWTIpLZ`E_virKp{okqnHv( zDWjbGR8YwSs;H)hhtyIRe(QNe1C2D%9NtAMk7=Ww4xWS)PkF|3I_aXD9$wHJ^wG~i zxDN7?A%+=YlrhGc;C~g9Ofk(2v&`|DH_WrZB1VQ5}yX#T*^yvoqL+R(hl(EOpHd99&& zouPTXq4^_2^9GAvHyYa8WN2@*p}j4J_O=?@``FOlHq&=dqTSHm4nupN7~1>P(B5Z; z_C7bXx6`8kRezVEbKQo{^%y$$!qB;1L+APoo$EJrZotsFK||+WT6BNNP-ECoW5iHn z)S^9OhI-?MdJ~3vuMG7j4fUoB^`;H=W(@Ua4fW;>^w`ZugZ>aaqQ188=-hrXs z2SdG&hI*e2^*$TweKFKKG}QZQsCQ(jcWkJ4VyJg&sCQ=3chtF|_JyJLrJ?qfq4u?* z_BTWA?}pkx47Gn6YX36S{%xpzV_g3QhNxOC004NLl)VX@Bu9BCnh}u^k#}b0Sy^{g zc2#vx_kZ+JXOCv4TQg`hqZu)Sq|t$d#taq+O9sSYFv7yJ#cg9`%a#q63=0p|*j&aB z42z5wY(48)EEv4@^1zFY%|0-;*@quKz*c#`FRHo+_Q89aet*&F_x66qqux<6nvSMBWI8!a22GL< z)8Sy3Oa^I&KOTWg>LgAR{8nscEQzI1KgD=7o$UXl@Z_-YWA1auiX6A*OFuGm7hc@J zjQmKXL1YTXgmKw&9yF~mb%h8_x0W5P7`9QVnmv=5%&2>1oxCxPtA=9)KBH1M
S zmw%DlgxFkTq#Df3g;vZa%|rY0~&_64keHmNrR)Br$YO(SMnahuL(P6k}QRlaF1ydhJ?vL)tpldiiEG z_M!L8Bx)vpo*(FS4&eEDr}`|^7p`nC5h+HjEmwN}%1w40SIbfCH$6n{p3 zJi=ifPbV;(Nhy|v?Cy;xh{aqErjveeIvJ?(PoQ=Ec<=0J(pP84SPbuw$`~YUU0nqI zu|rbqgp@p~8{)!%u~!A$b?y`Qo1tV5V`NR&%W*^ZT$6KRkqtAt(Q#yA_WZI=$@#JF zJC?5Nq%ggsFn%CHQH|Z$(n}$ifq&2)kLzBndp6}n6Z$nPl=vTXT>TzNEN0G5mN@%n zWFFccbfCX7ht9+Pq<_vr?Hc$ZlXN%*by##7Y83Q9)*y2|7*Bd|Xn!*8gWm1X ztU)i80-;bkH=Tfb?dc8u{4qk0G0Qc=rLC-AakeX~BM?@9+&fT>XnU|3nl)w?rhWKi zEvehQ`fNY-YKiTei5FXC!KLo$&BH5acbi3ZiMd@$YS1>r(w(dsRN;n=!82D&0e8~M za<)`ydMW4}6S=4!@J*w;9)G=hXn>YLrxVA`t64oPj8j)^o*1NM%fqG{b9rKx_EPO< zwBOX8(Ec-tNR9NNH&lZ*NT(-3A{uNuoXgKH>0z_i*;o}&W+&( zta=yg&>u}C8n_`oE`#f#Hhp+7*ti%j@JZ3@57Jn4dLyXIFdL*$*M5=C$E)z5iJ%2& zMWH35-Z)hio>xiz453lk5Cx(?*de`+h|@kaF~fWIdn{mJ#}1rd)nm|rfHJDnwAOP# zxO15usn$If2o`UJd4HN++-cOAewkHsNjKI(xX}gJMc>z1`=B5^&AbZWBz%(w;jAv&jyD|F&ojGCNM-l*o*YDEY? z0{OuH88>ZRXWmo0H*a3N(W^QZbEyffqTCC(W$B!oCV>)^fHU!-y`axwsbVqcRG)#@ z&`Sb*1EXmcrhm7Xggb)hCTcvR?08o7!Fyy*Gk{wV>3|Q3t-v%&cEzM(SPdxAt6-a; zurM7Vp@#Tb+PZb2v)*oRwjLE0^sPa4hq}zPs1Z3Z{2Dkjk0vqb%K+p%Q<|^` z7`lZlrhmnFsQ!jh{UwF^E8=M%j(@4UbFi3hoXJlZfn~*B8m5)7S?Uj>#Ji#n4_Mt; zZTXJjq~wXF({pRh|Mv-NO zXWMZUcrCx|H~Wne0Dj#;lUfyGTw@-KD&yw;ghMQT3x#i z?hEod9dns&q#)#NK4?N@WKclcb^$%7%a+?x0HmV>3X52;IE!2XK-; zV1H%Fy|cT%MuIm3jQUIvr_DyMYyac8^TN+i_VXZ{u1NFhMC!Z-V%ZB&B|+FZ2U*nJ z@&RE`?=YvKZN+9_m$-Zi`IGhyXM-o!@;@oan{#tFFW1WLsBEu1$on_tx^rAwJao5u z2Q5c#GfH#t&2G*(sA^Ja#9dwN{!`P7D1T@mxW}^lZR`rwADi?qwFBBw?FN+EVh>cV z6NHq?3m`bcHUfZLU{5H(3gt5Zcq)jAmb|N=s(_vW)7?O`o(=I1H6rzw}W-Bj`- zK?&Jr>?US0qb4O_MkQjZ9}chsTB6PUVH*dx)IfLFR?e_AVt@$S;QLG9`iE^0!V>Fc zSI%xt#pNDYmh2>XJCF3^=E-U{`+t>6p_7&ulUvFioqp-K$*RX^x2n^NqS5RwC{rnu z+k2sfSM19>JIvO#7JS(uL-eV0JSqhRj|Tm%1_TiPC?yY5PJi~bUNv#bwlD0rCR|oat(|Cm>0i{4si)gg~R}E4m z4P_1IkR4QiRUHe@>L*3 zO9CKU2tI&%nQh8AOqdt+rKAQEZti;tGuwwYPaOC3P8Zk(mCl*r>Ju$6W87=x;EO&* z^@^znR%klXkgfqGJXd#p0xq%SfTPW81|tV`hnaZ^&>2(C3;2wT1AmX0PPxS35T#Ye zVg7T>G{~*c@(nAlHv*FqE(l!;gEjD9QLh~J%u3B^_WX@eT)D=P(n$~cFD23j^j-!xqPyHn3;MPO&({a%Ztp*bzwZ=Gk-(Ahg{P8Kc>G6{-rsW zd;vC1BIMgx^arRKA{yD3efr0QodJ0AYi|(-FLiTivb%5Rl7HRK)<1OpJ1@JQyn?cm zU~qr=mpCsKWzO}N{4m$QOb(@M@4fcn>9v=1{6}Goeh3*|zo$sW99a+N!Vj<%2rA&{ z$sBki+3%?{^M5J<{VTqUx2PW&u8|tO9kkmDt^@id*K#8^tc|#cI(D}9yn9}9vKPrD z3YujbnKA)d&dc0)rQSTwb8a#~NhBH+2P(BZPDE_S<@)ONw`S#99(5}f8xSc^%h00* zfKzz3Q(b+=`qR1o%#H2HN8e)DiB$qcAdHyqsT7VtZ+|;7SoXPBYW3FpqiCG3)H;?M z@y5ZH1ioT>VNF^fBb4lqNf~(BgWB8C7H<&1>m%rm9Wa0E#3!9`4?iG0pUi!b>WGd) z`h6_n0iTGAdDujq$3u#^0A-0qBC!BE>_MW8YldPzr!van4G?4ul}pEmf~ez%>74ke zAGAzpyMN#!L1%^!thg`*tMQUq2;G*<*LCPj({USt69Q=G_A-br^`XG7CArVQ%IE=? zz5}PZV}bGbem4O>1vimFRt>)2O#}dVN1xvWzA*bA4&InVoi+7Jp7;S*xX2sv3QKU) z{-2&JI1m*MSHg3hM(zLQvFavJ(lUhiJvZq{ReyPuu6gC%%AvhV!Rsa5F$3(ntz7}5 z{QnEPCPgw#hU4M5n2s-f0T^}kV6m+rYss`@H;od2tidusR`*1Gxx29jcEWR|o07@e zU;w`#8y`MAK0@`w7mmh34Y+49@o_Qmh_ z%d98=GhKV}%F4=k?{9f|dB08H&@3&4Hh;z7B}xGP0Dg?rrwRSi!@u&@5B}_#UiY52 z?@n&Go_yz(KTW=Mym8Bscg#L=%_ScM#82yLmupX-+qn4;7^cZ^u0KN+m)ZlAU~n_g z%R(8lV!t%v1Yqcyip8mOO7Z6>Krq0@Z(KHTQb)R6w>r`2^4?Q_b)8p&T96fcp&2uLyJ^Hbr0bifVmoX0qnF`%n^SwhuhCf49=wS=I6mz3_RAF%;wax?ttUm*yn{k z`p5fYsF5}h!^K|-{>U51L$lky=YQ|hlaEe6I-PxBy3g_cRQdB;5uYzyc!E(6soYej zzct#2Qj@)~)NmfBQ8umHfx;?OgYk|rVE2XJ$506L<`i-JDo|c@xjfY)#(wx&8(F_~ z8)GRCxno8~sqW>2UK~WR*<7hs!cM7{JKpSXYdOG_jJZir)>+;GZ@kp3Reu{L_7{J? zaZPU(VCydMaSFB~iohuVRHp#l%O$XVUR^R_8%{F=#G@M-pt8vDOzKo~ur}SA6lPlM zGCiNY4?R^>suvw#=4^XgTdD6))u=L9*Om-G1Y-%SMCc)LgcFkf4Cgs+RAjzW*jWsX1BG;f@UL(R1k+cdQ+E z=k<#}{5KZ*x*y1>(NBB}JhofP8s4N;=(JfKt#6hLrkeurJO1bB7buv6RQ zfIW*#IOG`p7p;R{7SvE7!FANeOljLZ8VU^`<11TDuB_>Sm#(?t@Q~~1S(-SG&bKC; zhbPyGZoOvEA4;q`PprV~9S>Lf&3ZT)?i|~k6j89;y*8tIqju%O#?0vFG@*GImrrDt z^tl{^V2-n|KmOo@kAKtn@i)KuahiVgru*)@>7xwZ*nPKrWDgtAPqT9{!pq3q7h{yl zIfUvjBC}X&7)z$iN54U69r~aNX54ml(Q9n>uIrDAwZMzQ<=!*8;EGSJ1R0Yb2*&jN z)q1J56t)`O17}C8X~-OZ>EKnDpFe%})SZ5@wmB=C#A!xBTYvkW`W)BJT&mCauT2JC z4e8Hfb^*i4a?XUtBlLMAoUFN2 zZ66GNe!n@l8vYMzOndcUn_MwzF2#;a{k)b$r(G$YvfW+_+~h#j_h&z|*VH+=SYk`i zVy+nrO-nV+B!BIGHtv!VDYX$JldRn@P21#KvoF(~7u-906yBdX`}(%$ozC-?M_T~G3^50sd`Q#_bG2*@LP4~ZvY`*%{voGIw$$uQAf1|lt3HZ1+orAAL znX?`PUta>R|499^o3dN7dv-TQ`Db6Vv-6#eXZ+041Aj~G@r!4!U1j8!M;@7db!TV) zen-I{aj16*EijAP5$}(uS<+215Ig$r*<0WGR&w!y*+(9G?6KKL?z`_k=FYx4`zp!5 za@UvczWYm$Jb32JgV*fc>l5sQsuxgt2}&=UmbxU#WYQ-e{^A!Oewch^cKC~5B>zf2 z^o1|N`+tWYnmzu|{PVuv9b`w*!vhSJSzk{3Q}V5gpMSXb$xrqk`Y-IrW6cLYf7@-J zf3Ue<{&VbAPrUrn0!>!UY1C2mwdRda!O3l{urWJMys=WmXP zZStNPa%c`7!8C=mTVMM|+ZOl{%;5O8+a6eJlIv$5X|&BC2m}Evjh?fq zLP1b9Gx$XUu-bTt&}|Nm-3Bb|*x-~>(*Sh920&Try^PalNr*9HUd6S#5$ATvt=0an zUjLe@8({Mt9@X66q|zkcFbx4v;$cD$>3nrvjpcx56Ny zY|I4Qld1Ti5yMTtQLFv6$$;{69##C`rV-JxPeix4DEYfiwu7xOqu(Nj(C zFWg)*H}9E>4&ZdlmWpWt&lK}mW;U3Djapc+9SR@}i_SwbM+rQDuF108O{yLPdVio> z2*7NaM@*c)3Yr+1zVC2qnt<;(IB#ctDGyx1Drq?gYCb2xKuoJut_7~y>z?W?>FkOZ zo_N|*Pd`76~kN+y++$8uX!uHQGh(#oAA6-zEl0$(WoZPbbeJKSEwaeuBK7+)v(um{#=*cA!LX+K3CmzBjbC@+qXEaPw(BKgqfp*X%m4fTBx0*x=%@XUF?c26A?B~})UmET*7+SMhXO8E< z?`@6?f+>K%f}9%E^IVZ|mr$w;;Kh#XTGU_?2)b@k*5Rf>0YXtrP=8Vb6vqj7IeC}R z1>@8%$&Ll4A#$W?dPw#Kum#Ho8Qv)Cyj(eZezR#1E2>SsD{AE7}c!? z=Ygqvx*=R4be*s7UUir;P$onFdLW{dCB?cI>%4fqU$2_7S6(U^(hrZg0&F(i!ljny zcs^KU*EVpr(9>N4YJZ7UHaN~P2nTeInjGq1!EW*Gj$q_1^S&^l9EYOpc@{G%4;Wh;)Vl5Lx=8@kNd^4xyd;D7}4b-80YPUJXd6YL#hEVQ`J zbg)w*bOoVO>N@KP)1qKExpbk@1HlbYQ`eycYGr}#*QpaSoPVVwbXH}YbJw%=`j(eC zd3Y*vbSPtiE7@&MRvn$m+{qJ%^Vq0*qGE8%?Y7|Tf$6E9&S;?HBe`JA3=_K(RI_oR zqh&UsNv=TCoAWBrHqI#Zn5;%|%d`C$T6z~hSW8mM8)4t|E-=Ck7<}Ox7EaH=*TfV; zfFn8|(0OG|&wt<&I@)pJ3x;!joFWD4qrXh`l*@4Li(0CKfCYi+qWU(Y4$vMOy81Zu z2eXAvsZ=4bIrpc3%Lc&1tKh*mv{z`a)gI8^t$k3_x|4LcNY>ygYJ%Fjh>&zqag(^{ zO?c-h&J|1>BG%erYY8GIvJ3QW-eKh8jJ{{=_TESfu{^q&2+gn z`-Ba>7soani=Ybe9;ftws1QE zr~nZ{1%HQ4CzP{a&-yDzTQrN`(TK~mb7-~yLsY=k;8#qZ#jeARTsADd;)Aj}l`j$x z{IdM}(+7%=qx+A-0-bc+yyw8XCH$N`H8MehyR~e|l9XAYB?V4dJB_28<>i)d zxV9{ec2j4h8|zCG%QgJyR20{|a)0c_mQ3Et4piC)i$;+~l!i&SQLMMh zE1)+}51)g1fQq;Q52%+=?m2tdm~Dbw)U^Z1ZnGhBdGPWCa0}+E%!%s|aL=?Kd!)0D zu{Cf$tOrXfdi+my5ZbwZnPe64tIu)2D~)sqi;Ta zcYkLooxShvpMJ;r)t^3n!|9U;R!`o2^+t11qB-2h)pr8MT-MHNFGPf?qOXe(^*q8b zZGV?XQBhcMQhOomL@Xp%ktB6Vr$3meNw34CI~>e2*Q9C_crNfmDhxhR_Xb}{zG5<~ zDM8C6Xf)?HXWddv$*0ra)3$VG8=>UB&wo=eNaQDUFf93?MFlgZD0OPS2|$5SHvlWi z=!s>pP}e*eo(1FIKL_?G@_osPzIp%*h{Gj!f@u{fG-)wl(9(>WNuxR}%AIC!ZBSfM zl!x_Bwge*&5(r{e(rr$sp3yIbPU_hVti2ccQB*E5lT}XYUI%SkBAHM4V1QgfKMBW`16OlHDxjo-;0OaS0SB{m)EHr`Zjj8QNApO?-c&afL1ZxA zA#z9`Wiqi`3#6RuUJy6c)RrSdX@4?5i?d1+M7j8C$+hO)_ejP1gp?&s-NS z1RwaFpCw--%#v26EOft`WgU2sC%{936)53QxmJSth2SwG&J1S9VC3CM2Y=seuqcOt z#CTZ31LEaq5#osP#MdJZRc(PswWM9K9LvdzkQpX-@}OL4S8A?Yx0uht(J|cwnK9Qa zEAf*M+`n7O?bJ_|<21tb%~&oH5BeiD zBZ35Foc1R}%z@gQvhVMZ{eP(6FdH<9x`w_)xMpCl+Xb;m&$k%W-Iu->`YdgAwy!*D zV>k+Mi6z;GKkUdGsoRZ+P2QW_lzyeo0rQ984&A8y66nMB?l5TfjtGk}BZw^Da>ouBT7T0C#OiU+fWwiL z(%8?>pkHHG1NW~1cU^&=(LnosDvI$DG6V;t!o&p#I_9VqeTknC#IBMF8*L>}>M+1> z@(uPlN>=AJKm_R%pyHj^Eiw5xVJn0__N+VE?;m?QyZSM~9;ftiMmn#5@^MO@fWP+Z zIvbBaMu`c3&zZf45Px_-e)FYR&!EJZBCGCr-D4MWTI-pcTry%04KmB3q!G zFlt-Cspj*0gJ}j-3*Wa!(=9a9F;Z>iZdI-u4tO@{t2s#JuGI&S0f5J15zs~7OJ4|@ zq4N$x4)Um5ZKokXT&D!a zkC|Z2I&lSo3&Z@JrVZK)py)(Xm$&L=z$=LxQ27wC7)WW}t)F)PMsoq*I2 zvw6t`#%0{bT5xWq<9Eb{_rR7@d?*WO(6|vd(;Z2(@Sz zvppwMkxc>g3OQ%W^Te>Zi<7{hRi2jeh4U;=`YEATgI#7$eq{WtE5L-8>rof%dk~qH z&P#zg7Kgf%o%PYncqwTBsk0_s+npIrLo{V~ttnV!J?jOg?udw;Iehmm9(|V!Zpzwa z34h5}pKJM|UJi2RN0wdkb?e^d^2zquGr#0l64L}H(VO}g%@xzA8Qo${gz}uHJ7yHP z$(`n2UYbY00g|$zU9O$hZpK(&sf`o=*q~8wm2`ZHW)7M<_re$z%`ojs$vMzrbrR>; z)X}s*XU~YvM;&zkLZ*kw0IUmhpZqi({C`~&v>Hq}*N=nOjC9%o#0i91)PRlwbp>+` zm8IlH-AMro(Hc0k#PZ!F@O}pnjAIeD$_eH48&Ce-1Hd*nY>dyG0A*%zZ!OL)X2Aa_ zh$k5LvyqUyrM=hrh@U4E`LsU zwo854m(VN2Qk%XdYqvMr?b+{=FU_{e2k$!Zh8L5;?204gUh}<6^VK(|!djhPduV;|qNg2;FmHJF_^G2u zPMkctd)3L87fbZ2BRhad6*|3`H%%+5J#t&tXstC`G`Q;I)-lgCx379mGaB4@B*E0POh^C`gDFUm2maHem=&}RfGXPPMEO-eeElh)1?0ei zlc#;t6R zdHK)%_(`%BnVn62`_QSEpI0ESSzLA5$)m->CatqWz%zad#|$&{7mGLW2h8O>n3>Fj zoQo51c%E5?juT9+!cT~;_OkvJK9*=f6lY2iNCAY#ly$JVs9=M6%10l`2iz6|X?Tbo zG?U#Z9e*2pMkq|(XRKANH1(ACDxJn!vl0pi{GKkTSgKgzxVP;HwtDVNNw;K~*oN(z zwRNc%CL1-REhEuiMs7>)-Z>fgg26Kkig)E+TMX_KNKQhBMpk&Tcg|C4f?y-<~^V z>3QIlt2k$k%zCN06|I5~fQRaVx&ZnZcpH`|u zl<3g*mKaR>BeG8_fNFG9CXdK)(SS-T9ir93ki>9a2#2OW9%NhT;tA*}F!=}V9}X`l zEPvg=wK6gua|~|c%7$XtpqW|~HB}UIZb2v0WKR@u;#Z}`frvzLApmpklT;L;Ig#Cq zt|R#F?avCcd0O1O253-lIuGxz@`JGv*aX!8XcRIuc-9s;G<>K~m-SQ>7KL*<&yg4w z3IXi*#a=fICIfY&!Gy=1={y5-{}K3rY=5Zuo{IW+RH78dkufklns8Ms>}fR?*x+Ie z-Jxgmn~bDERRwQmZ`8~-U`8J6~|Um$M8#*(J`7q08R!c!fhKgCwHU5XobMlWq)B@ z0r#&NQPb%7xWEFOgz2>WsJVg+5e~YRUO(IkL{0A0+HL9(0KvfF%-l&a8!)ttn$(TJ zdcSazk`tRIt_ou=JjT+QlVrl?hRrO`P_an6-Hg^EF#wVtujw)s&3-$=lm&pz(z7Ku zbRk?&+ktRA6R0WB#6y%}kW&}SvVSIcYUkoSv7AhK=D;~^rCZ<@0sT5| zZMz5qlc#3N;XXW`eH8;*lmZBL0JWV-dOX!x9m>+A2hB@Y>wb_#F4U7^a>fePn{MQo zK!z=Dgp3%v6p<4rmO*sOiR)!=_FwM)CVPc#8=mWI)!}w-FAV%z8kUxG;C~5WGqQzc zNv9T+;vlrZ{ii@$0VAeQo-r`n41>m)p~`e*g<_tb3fx@anm^!bwgIEyGA@XOb4;qG z9s+ngJqs`s!*4LIP*mz3wj4a0qdP#bB?t@>VoIOSgl8MRAw$ctJu8IMURyx*eQA49 zBF)Gbjsz~AR3bAHY}UkCLVrOpaD(X|95{qYBti*YC6-F_{S+n1!m~Kjh`A2|t{kx# zR1)LR41e+TVN8Dqsl?X6_h_$P*jAn5t(h@_n?|M=r(SGf2jICt26kj7vgCW@S7&d& z<(mt<`w#TPS^yRi^GxFT+OVl2bmK*q^GKOIR4_SrNw~lel`UT6w11J?u3u^&_m^xl z%4=TfZDF}uZZvAe?N5Em800dvleAh7oaMnrZ{>8omB;i0-*{@#;`|EJ4-X71X(YYO zS-N_#8=ZjWilk$kK{V+PnuWo^aQn(`pJ2}gHa*c!XxC}CYA?|KoE##j$gSkZ$?M32 zKsffo0rE=X|iMrpx-9^9Rf$Y3in1=}={s_J1(V1w$*-#j40And5}X zrJRnvr5{AhtDwHByQmIRc?wxiCFx_ZOeLJ+;?i`o!Fz;BFqm_mK}Q^4t1 z7jT??vAKmnY@*tmb#S%kbljJsH^zv=WHBIYzOWOg^W(V_+@<3ULSIP$0JaDKcq1!O z)L!_}OThgo2!DqxnSfcS0ouE2_-QK2o^VVTQF&13G?a#p{Ym{Q7rJA|^j_-clF2mk z9b8BysIo<%vivoooX8;P8By#=!ULbM%F5+dT3K6jGLr&q06PL0DK`SpI|~4=yi#Yr zZa8XU$~;;Mb(#{swvquC0F{#-rh`!$gp?XGa#Dkd*?-%?vsjo{3_q^x3vN204YeRT z&X;ghW=e>4AS>-O{gP*bwWh=cW#$<)8H)GEO6e57?c?97L=kcbTS8~ZGkOxd@y<4=M(CR zveAI&5PzEb(qp)&z`X`;rb{lN2Xx;FyrtYSTl4~rG4DYpRb5J`KW98lT$_8yyCl)! zsV=9f0Y=uA(D3InTv!kqWtRAyu2I$yFoMi*L;0)Bj{~AR&!#p5o<_hNfd3}Koc%@& z_Ym?$Wk0Z_FsnDOY!};bb6GXK92|Sq3`$ftO@H36nLy`4Ux&V1h59-&X_eZe6-%!| z@hf#`H<(Xff;D%%7G^wxJD~U!TJ@alGqqF#I>2;rAi7!P1(Z5Eh#Tl?X2+!Lfbr%m zsySekWfBso9W%_pwTy%H?WNo-K|77WsR4)%5*@pW>De7-9+klJq_|oMS##j(Y6YK; zj(@q7)rA>;LkAPi!eXhLLZxs7Un6Yj_9oQjGN_(j_2B4-$W)kc9!TxZ%|KUCUZ}oK zi6wO1sQONckbfq)Fw;rGFbx~6EGadHM~@8UUalIG+7z=ZB9#!+8!3x^m?XtKO>lqa zd>%R%saoZt&SOA+RCGHDPO&Ax6UXQhaDM?RF0ERi;W0W1%)(K*>FPGaueWfbl5P)k z7w3iu4ZKDJyB7K+O5Oaqa!i9UV|M`PiI~23mc@ya54J(=K~#Z3`gUR#QB;zf>xc7P zIKCm=(CWbfBZ#|p=sLd5^Zf9IPPf<)8)jifoeSf9;2KS%8wZ9gMLjEYMX*_Bhkw^M z)%nEsFL6pj{{fgmuJxdIVwG((S|=Xm`=2`=>3{c^ueP_3Z@1M8>0SE#z;_*fetYjz z3qPpOt=9J6wDDDy+RtC4pJ6)YVUZ*njsf|y@f4%OB)@$lzw@DwzUQ6S=Zri!d-+2T zku>cM=USBp;P3Ozin=}P7&{z9A%me?^9zCUBHQ8XL`00&Yuep|U?0;ZAE{ADi zm~|_+ODO|eC_S!Mqm43f*2r>sxC2&nOc}GA*cs{i~!07pkMh>7w2|4w=(8&6Cj!mM$#fUX9~6hScJaZC|`yc_wWf0 zZ>cx~I$mph0;kdmJ&rR8tbd?44Ue&IwJ;m?byKe`A6yxLF$?yOy90Ks)1LAC|jVg3kasutL01}!Ohik2Kr+ecHp?`?Qa1-&DEv3GT=tiaA}xg>sn8 zJ)U49444E3LlBbSa+L9WVb%~p!+csa9!}@xV$QR(e!7ROFu@B&ce+EBp;^#wl>&s5 z4ExiCY1Aulm5`FvRDV&*@pPmfm0?1;DwQmjzD%a-M#aLAkt|UJ6FBc;+YyjgfGLxs zWDqA!(x8KMFElxi%+Lv@tzD3HX=GM>ZR|EcOu&gDIw1l$!Xc^~?YII2tYS0fCem_5 zfb0>9z{^)%6Bn#Feuk@$fB>y-R+b{4Nm~ZO1=mq)Qau7PP=D_(S8CwJeg>VXY35-S z{0K-de6^k6Ag0{-AOOq^OD4-@$lW>1DNGif3OAa#9vvTOLM5csrCSro6LDt>#sSJa zY!t>14--ZrtQiMH18!Qho?md>gh>j~Tt6SSG*Hgw&BN^AofF}TcY%W;=H9c{mvH4Y)*!ESR{ zBP@^o3it`bNSiq6gEU95#KYC=Ca9yBJ@YtXJ4Ndl5YO{zGquupHuH@ZVGd3hfriRl z>;%XC>K#=O)eHNv!mkpLQm|N8lBWSvxQ)Dmyqf$nd4CuA4e}oHzmkuU-zC3CK1KeN z{2BR6@>TM; zd+Gb=`+w<&=!fa=&`0R+(vQF?9W=o9o)^gmIIMI{5ZfNnS$Uq;68d2p1B4igO5 z4lh%4c7Vi(PzV(1C?dp=Kqt0OJxW)g&8&<-qz6Mr?vN2DQVqVA<)7_ny)PHd0d41|k{v<~PmY*jOEd zBE@9>U@Q+L2X2$9+sI6OFIgQI<;!s& z8-LiFf@R1iXs^&Hs2hR>;X^2b8xcW^JEJj4M!js8O!NtASba@ul=|)l~a7lBo@Grz%rp&(eD(TOq0zq zUa~nXhH~*meICGzx~2Mr*B&LC-*XIal7GkorxC|K!6Wm}avMJ#kyy4mXHz?&}v~<{C9Ow)6PUEd{GTl-I_DfUpEvjf78cSwIlB#(VLONhD z3Ltt?n!3uPXfS5NnKht5ktxrB*%B`Vh3vgc=Z`I@;NpkUuQQ-rv#+C_04qiSOMlKD z60Fb}c{flXV>X5doYFD&vx}JwC%{XSQ(#u~BNCjxgIh8IiNf`pc|b`AI02eXsK#4> zNs&*Ycb?sd`Hde$GdUYzHkCZgkvV}$`a1f08JRjT#2Q$roADwSLHswr2@qYM{hiQn zr|O2Uf^VN7+j#rg|E|;D5ibOGd4ERULdnYj)ZY&!IH&YDJnB)dL;cpb+q2_mP5@cp zCr&Z)e%iR_CHOQ#jNONmRKBeAtA)i9VQLhIV}a21GwgXMdxZi%KvQkD63I1V!Nd%Wh;Hu|ZWS zOZsr3-o%2ylcB3qj)uQi(-#u7hzDSsQw-pl3Uu)%>%eh-7?Y~$NybiLU~-46ijc=( zK;-NiDqR~G*RwHsQOen8bAJbiCxXEuXCDOj#=gL39{T3PT;)aT$2qwJhxJ`33%K%K ze+;gGqUNK5iBIA%KPcXU{#K^g9eS=aos6M@v$sop&g_*f5I6%M{Hs77NXi}p$cYj} zyU;Vg2sit$FZeN?epNBLny4{MCwh$PyNZo|3!eCv6I8#3k~8p-m4DgVSr7-fd6O}t zw9D8EV@~A%9bBDYkTbxG)Rhh#XBr=GgISi0(-etUEMip`CC+8cDe zXs>TQa@9S*_{yS3$yG;pAGqf#^4ZPfsz3+M9b4a9Z-ILYIJkdSX;{jJQ+Vx5vU}To zcU^tgeYbsxx%tc?le_Pp{UP~Q{@8+}%~(aPd@K!xBygG9E`MS&rLTS2EgzbF`}xka zHb{Ee2FqrDcVnPNVs4H z_!;?*6L;LG6c~I8<|MmWdhC$pSDmn&-LQNxjiSr1 zNPhGuZok05hJTv7NkYq^;hJ05TA{e@dehv`Q(_0{r?gb7Xbo*uMS%A`;9zp&20)upaq3A^I*`+3cuuFI5yFO$I&KT{-Jym#f5t{8U zau4x}uQKlAo)?xcTD}=tL2zs(XQHt_?3;z@2To#ICT4=WQPKskAv`;3w5!GWL*r&Q zUQVZ*M}KtOAI?fma3W8-j1%c3V0UEh8-Z|m+RcUNbd09qacZZQ!72C*vxQOMBKJ*$ zo1D45if0C9DC1JP6WOlLxvX9qCkcA8r1iDK+9~Zvka=OOwT|)av4UYmX}-UW%DF3z zkY}~CeiAMA$Jn7bv8<-k*nC)lSphv#O0|kBa(~rLaP$uol^tCt@Psj~vj>Fr*%v-C2%WUfimkt?=uuSg&wfi8Tu-&c3i*J={9H3O^C2YFFz z>)T^q;6nTHFjKFoY|p=|Z@fr`_x#B_$xEL6i{+K`@BGa5=idpYtGB$ewtW3}W*=Nx zp|AbU+RBrkefi7Z`OdXZ5AJ$7{CnrxHGkUw*dJYxaBT-!C7sO zCanX`?285IIi1$ZO0)21U+7$lhh4^`_Ve2BA;a&MMtj)_0L$Y-rI*C%-UO`LS${0_x$Xw<{ql)f(CB?qtaAx$`{x2smX8TC~3S1LC%+MDYibqz*DxT)WgAe zos7Fv+;(if1WW}QMW%M+Q7MQMr2fTloQ%LgO_0sQqqAOrR49Ym6AQjSe=ZOjp^{|w z7D;1tfF0EJs;QRB%o3--O+N#}0DstK7+me-8QY3!3j>(ABVAnXVy3<@On&8bacx%BP*%6NeHUsdS>XD`mCcvk$Srs z$Pz{iBnf?+`!x?ES-AZUPFy|=&(Wz>b6gWVYGmRx0`9a(smR@G%XJLT3V$WokSEEz zayL%^?*im7p~6in`Dt$If#l6+n$%_u$$Z1d{S6%EKEWfHAfrO3y?OG1NjvaNl3&*DO z*|O;l1-U}o$~TMQd`fS=FGK{a3gfM#dCvNL75*1NFe)80U88z8;D0_3b%W~(U=3Th z95uBo%xoPxwsX9bM?zYR>q4@CEwvjhc!O^0h3)|1YT7Kyer}`Nyd}(z_ z2xc=~vJ$V&K2Aurf^%Y)p}WZg0K80Gtb))GMw`@JN5WH_NT+9d_NvWR>z$Q2VWtet zz|HGnr(g$$I0pk3+zn@m?Z029o<~ ze^<4fVm^lp3ct78<(`#k!03$&HOY!o7hqg5$h?;mqmGLN?uc4H>M4J@P(m@9UfO>M zj{)F%#|Biqgqdu17Mh+ptY<+_L{`TFgrHX{v2RnyA~cAX;#RwVFcp3(gIY6kq~|-H zB6~EYG#d9osdS5CP&uF+)Y{&#nJY3L9j$_Dgf93{#{o0+hL%DbZJ8)C`%*y_HYsAJ^L;v*F;5pvq6eGF?4@acps-0(k`4#Qam@B zXKogzn0+YhWZP74yNB}L8l}sh;(gr6MliP=h5^+x8H!3qS+lad0_MPMx`3vjF}~?p zyf^zdC#mFlL+}zK&Xb=O=GQo*cUhdQfPv9BmX;5lTJh6d(i|<0ZrLRdtew-TBu#0; zICj9U@l@j0%{qVe9)_{IlTz2WJK4ey9-v>)eo=e3_S^FvoK(;`+uM?4VHQ+W8ja1~ zHe?H6nWcLxjq$?qe79Cy(2&mI{RjhN3(u3pSZbYiltaT66hh_t0Wd@FyEES?7BO#} zsfD@)9-j1Zhu?)$!z)u&cy(=HTBRnER&kTBKNjTS1{c&rLfF^!9W;G z86}eAPB?$evSG-b{NNR*uBbagmJIvAQnfWQIqoNd>mO-k`WATQ_01~{hvN!uoAdg? zr&~TJT)IBPpxMusQymhXrJY?l%Bnh3->9u1xcgBdc+tBEkrNjKPw zxnV+8%!Qrmvse?Fg*oBYss6Ac#ciR7=y;u7!?LTP$QF{!Y zdx(EX5HU5?l6B_kfO{Jr7L(p|o=O6lTZ&ex z9Y--IMW!l?Fd2KKxxcjuY6T`5(!qSq7AnskfW#NPL$^1`=E>f%m~I{-m%faSk|Z8) zCgTbH)EV0-MJ3Z}E~$(It6pp^H7s4N4k>^BlAEH)|=!jICf}>Yl^85U&VhM--<4Ai^V3aMYzxIB{5b0EujR&YNuf{_kVv z9#}NWeT=B+dTC?Q)QP_=XbRBPw+{GDy-K>5``p7tzW(K1QmMJY5*R(n!O1&ZzuKP= zatBs*DF-m2-YXcpp#~x35*N_eo3wvWMF_NL*d&+`(DNy75jO6t9lA>J_m|%$&nCb7 z2xZSA-+uHt&w2FxweXMq+{d5&9il($(eFIxr=Rn#>t^<~dp?FRLp!KV0kypVS6r%C zx=K1#D*}guqbiqOO)5RnN(pAvFDXL?C{uz2^oIr0USv=etVE>KP&RRmMi~vQ8M*VTG=ocv-$4wN{CPot` z{jtg-z`2D{Z?w5e)a?MhjfJ}Nbn%4gsIO=tF6K?fpx5v;c+zk(>JNYEzto1~@zMTf z)%5IYDYOJ(E_ewk-0JncqZQydPksw0K2XmiU=NZH0GL8RCP*bo1+110#lu$m|P78(G+Z@CO_rY66~~ ze*{y<7^o#>A-N7}6X7aDnS9waSqKO+a!E@MI247dd=hFJAq{Yt`B{QQO~4WMW)=yk zDu6(74TARov5Ij8F0CdKcY3)TBfL^77o|4HXB#ZgPHA^)KdyhhL3+cJZ31 zHKIjlFSM{&SvY?WsA8lGK178QIn_Fuc7d&Rry$Bxb+ku6AR1X#jh8aq6Uwh`)`{pv zc^=a=01%DS%|y!8TAqg)fR;h6)y%34U}bG+M`;>4dD!|8w|(iFAd1Xy>Grq=6j*vd zZA{Ox0K3ti zJ@xXkUy(u6JUe@wU=p6to8>rhG9zpWw)AQ@&*FiJS!pCb5Sa!yq_kuXg72O=C2}Ey zAJdJJfk|iGZGHAlc#(ev$6Zk-Z(#iB(PheQtL)3%v4N8Gc1}31lP6mV$fmV_ z(!h?X)O&wHV)A}-V8yO9bHi;fwOzvn`6SdG)O3f|w=4!7QgLnD%i{neg5^Q#oGN9d zeo(UIgS7!;gQjqOvveTvL$k{zC3!EgN`@KLqTFwB(7a};mIPou1G6mBo@xDsuxoA> zXCaUkGnRQzoG67Q>2IZ#01zdU+!T&wld(}VWZ8fHHx1tH=%Dm!rLjD6+=`!d+;r(Qb1~|s{4dU0u`j=$Y=`uAbSM-I?jFRo9{`u$s$o&8B$6b|+8~HR=RipKiUR+#0k*s8HFRdBJ*f#R1 znmbEHTzARwThQuEu)DK*^YWD#v|YJdMu2n53g^;u;6Q|Y;4-fS8QtY_GDieXeyD%u zj@)=NHSHKp10Pr@ZuMlf^R^Dz*d(Zy`Un6e>6X^=*82MPn8fX_iYFv!oAmqWFTKD; z2tGVi%jztUNKS;K!f~(^Y_A+_9bQ}sEw;T$zKzv}c!~Ic_$%>`;$H!(F6(kh7KoL| zhdUCvZKTS`3NTn;%*ZwvwiI+?R)>GqDkHCvR$HfU7sY;HICcxlQI|+%q0W;SBcnoR zEs3D3A{7H7>^e5wu>3IZY~57Fe00 zD~=0}>+X)aoHtVfTkZo;jOj2^aK@;2Gn^na32x$!oDQ+TNe`VIMYJA}lCXbHIwVVe zOcoJ>$tPnDghC+^IzBE}XUk>I!3nt|mL-=~!h&(e=aY?qJq03NV}S6fMrN1GV`XS| zw@gIlMcVvo&S4sl21mIJ%HeW3WwvgEg&0tQXO8H0$~>ddVSxn0Sr7`!l#o@1!0$$h zkBaNDjWZne=sAX0HP;{+kL+KV+0``{+l%H}WuC(Sy#=)XtU>;NC|B<9hG(C$4 z2cZN3!@zUm4lx9$>yU<|ixz*7Bd8JRT?1KOXpcbbfND~supFN<#1Ghlch>2Xxum=r zpju-OLFS02s49O9D)DTr*2uy^FYC*RN}bq07|}y%Aa$)UyU!>m*ENr{>Z(vXB#r~( zFtY{=73@cndM&YB_aACRPpLFeAE{g_>z0r#z?%JF%JQa;ieP2=w|#WwQU`yRxrAMoE$rnmjz}zKNF#kf z%A;fxC;xCQfMH{}Ego3OG@^|{Me@8>jWaUu1Jg{JCbR>OC~Vxsj}}+$(2$?)VCBoP z-DK%RMk<-e9jPEpwQUC>X({4fd)URa`jB1KwuR|UK3;~%kAPhJuoh)aRB=la5(zY2 z4EguQb0U8`iWi&+bhKRZ{#`O9L#)aQ8MsT`fmAbFL4;J@FVl5G z9OgaVeUPFO0r3h}>uh0shHCsRQF3K_efhwa;~Z!my71$hO*bUt ztr;98e>n&@SBVYZdazZsWfFHY08)L)&pT@y2i9%NSha&~uWp>cMZUiD7Fx|X*=QU% zc%n0h5`6Kbc;3of%~*4xVw}0Q@5I%s7rGfqqw#z@Y^DdorZ-@WxOoRaa_W5Es^(Fo zoRxoCnq0vu9aj(lLW-r0Oom}QDyu^#@`o$s z+e)mBGTqk557Fd|$RY}l+%_Oj`SjuL=3KvJ#i%hAwe+Bw98K1)YAL;N*TU(YsvGS7 z7HNg_blM)wt+h!sI5hS11MO4M`BlHB!uyqqIN_A8zh4EGZEWL_P%*!8zxGjkipGD6 zo_;^VbiJA;mGaj6;e^}9ayYg8ek>+?u1}}hdwV~?Fc?%$0QqzTd`@gF$h<^T?*c87 zQ%R7+Tu%BvlA_6$n*Lxe#*=Pz>e6Ioer|XRIUHVw=py+jJ*~;{edb~H{EKOGa&b#v zICRtPH*FrKm&0zc~B%Eih{5j#W1CD+9wqsVaf%$SVAUVATK#{A$3HuKoH zO(%4-axJT{f9QlOhxhL#UOQh%Sq$;=@xWVM^#ZxL`(-ikg5a&q{jYYf3p{@@*!?oT z#W}(5U-5M#lGZ)pe3`xozW?>Wd*~rLH^{1eU2(G#JYx?zKUPlQ)uA#A0I%VDucK;UPb|J-Cm2L>^x_rH|G-QLlo z;;!9CpM6$r?tVpSVELck9BhBCo>@D+c4hssO7o;u*@kbDR>-8fCYpH)s>mmdP|@WoDSYTC#~afj@!ZL(qoOu^XluPQ zx@)+(=8`E^Z#$&?!6tuny_BZ!-P&~%4@QA2_h_H01(H$cDz}!X;Ik;IeZ^C1nZf=h zDz>4@^_`jO*%Y(wbCzH-Z;9D{gS}^~%com@>_)e&Zw>};dY@+>KlZb)z9ZERc1~rU z-9FdJHfl&$PgjS{wf4@nLC{3C536@mzEbbkU$8p2BqF~xNA7?0ORu?p_mggz)Iwi= z>-^EP&wup|Z5ll5({H@(nwzue1&Oqbom-#0{aiiq5<>&7%Wy^QzTkOhUzD`_;Z;2k zNSgLa?bwNC9wNx0xiS3JBn{#QyPtb<>#d|q?!=70vd5h5Em4g%!wc^@#{a)V+TJlZ=R3GZd{W;=eyC$Z!v9H7}j^w_2fy-CE?v7WoctqnQ-j&5Zyl z>Qb8e?vu$uN5Rsg|KyC2^vxCzj%s188jz)_A}^$lgeEeR)#EFO7mk6}g@#O?-5C zust7b9V>P^ZF1bNpH3F$oXpMNe(a1Z<%(tZlvp4yp;mRgKxopNN#{UTx8061YE74=;NLkUi!^aQYskZmE2h z>ck0y9Kuo#LAiU)7CA$b%h|fXqQE-G6&n-Yf0+U{+$-GC;FW$}@?{v0G8<6!M`8oE zLO_3BW{|?gXlS<{EGNMrEE>&V*;*t|&RLAR#x!+7{`aXuT7Xga$YvzR^V)5b*bPo{ zDqQlWMOM^mQA%d2IeFdapmGcMwjJ{IYGF`yauoACc=hwPY&%-4JBtpN4%JORwdKR` zl2Y5(t`i2*C8x_K>!;~@9apV4R)RIUv@m~;){D`yV>hT>fg+Pi*!`;y9@MFqc}a~% zPX~k3aVwr2R*U3Z1Zwk$*N8pDLamdx2(Q~A$4)19VhwIn0Ppn>gCzrdo`&9U*7TzG znpR@##gJ^i{dkNYQ)hpm?n<8ZdnTLWeOY9E@z%?i#h+ci{QcvXFaO)+%kuIo|Kfix z{ED;m@=^M|qLW`NpCrz5E1k;e%1=Qr4SRi)BSw+Tj4={-QRuMWHN$ec9TjPLa7obD z&`q58%L_>TSuv7nx2~t%Y0h`((D<^b37KMK#FKUoymXba9>E-2Tg4O&z@!?JPb#bKSnSr7S z6(pAuRjhe;Cy}kLIpTV8a;JFT>Zwzz(_3Brk`=_K?@pFnl7hQ`a;x-`mT0ed&Vd_V#TL#KL5iqH;sIF3NvZsu|3t zU53I;t63e1OXDi}WbMwZG68R_@7v`l#yd03XLvi}xyO4)jN0sxN4op|&7+5lhPd4g zmGAFu5s1_GIs5BU1*(E4z$CeynNx$2e6tjwNJEwa+$$~@Vz z+m(}*^JK@~L3-^Cm3u4is(iTe>B@hve5>*=!WJDd5!Z?rikFI?68DM!EIuNBSA0=? zT|6WHNgBB=uaTEH-|b=f4*4GWJMszn$MUb`*X1+v@8x&p_elfHsU?5aQGGR0$J9x6 zTAfw5sGnC4s&}YgQ;(?+sE??Rt52yX)ECs()HCYu)xTLSt7ENM*I74OKWV+zy2rZL zdW-d-^$F{@t>3dgV|~GT+WK4T8@6vBw$IrY?2GoV+V8PHVgI)M$M%=)uiAfSf5ZN^ zCYMI9=mUC9U#D->KcRnb*RRy~>9^^}^vCok^k?*+>;I*{WfZBf$Sj$4vuOrqV$Pcv znpd0GoBPaL%!B4(^HK9z^QY$P=5NjaHQ#gQot|^hIp$pJT<_fM+~K^!d4qG0^MLbi z=Y!5~I*&U~IbU-A!uf0G8RuE&ADw@8zU%zEYrBCvPa^4vyW@Y};GTD1vs{TH2S~3as&z>&26LBO46q z^zCAbM`s2YlxQ$b)55@8$Y=NKcj{zX8(fIC(WETsD8hf_^9-SE-ANxM&L(DSGz4J` z2Q4@HlSb)S6X_6549g@37Rs#p$fV$F#xv?s7v->_>j*(aXjaxo_GX_{V0jmMCQ1ZM z^U;*Lg_W3C_Ng7?Dcj9^&@jkI-Xzfc|qO5D*c3>S7u)$MU}4KI!;Hsx|rmXd>dbp7l4X`z|1ijFkq*n zDK(#d8yGcWV7UA`&rqj>|^OU4C?(-~^X zWSN|%TodW2o&5$kZ#14}U7~MR&yci2pYeB&h~NR3FT&P&rzAEO7D|tXuAdG8L{H5d z=7oXaF8Ubb9K5+GaIYyfeLAE*_P6V1Jn9ZJ8c=H31QQI;?QfA5n9{uL66G+a)I%Ou zgrI+;g2bd4W<%<^>7$SZrb(ShMZRF4C_N(Uw_L0nmSz(sHJ3@ll4qyT;GRB_h?rddb#K^U_6rh3vK zKZvAJHXEi%F)fkNVJaF1FzgrGeJ+y8m0E$^pYt*<=L?Wuu!NBVTVR2ggM|;%8{ZAnax#$jsbr7&mrAfka;#LW~^U6_tp)EqNSv8=FZ) zs1c+$L>IUOgMlsP@n}F36OYNMNrv}W$@K1To#62;==M2}4`vUC)sf)d+nM9e5D{rI zW6Ep;rn$dG#HGIW$xx>w9p>HhT`B7lYfDg-w~TS`{hrU@{Dh5?k~HjQsAF=_?Vc$-Lo1_1Mtgzyw& zz;IpE_~|x1bWFFVQ5%pb(wHp#~gn2a&;AZv^U+tCfjBkF!`x+LVOw-A2<(*lByAy4_O zpOgM2BV{nuec(jmK>))UjETRX-nzgWfTr1=5Rd51GUSh@L6?*%4Hz*9FCU{G816xx zDcGLL4cbY~>=Lt2kCICwhagrygvh{Y^RWdh9an#I{;;c<n+dmfR)_ zYbqi{Jhrg4+odyt1bN)3Qy`_n#wl+E(OncDbEFs27mJcX&gi+qLK-&W?IS6w^rR5^ z!*q(}OF(g{5}rh&4iF<9A`+V}M3TP)A4XXc^)#s|M#_x$Z8?n?z>Rk9&~qG1EFsNV z@S2{Bgc)Rw^PYb%K-@A}RzI?_lYb{&D#>EBfNSQX>6Uwg;%dr|=;b4#2aDW^TCr+taBJsA#y`CUBDRFdFcB}zJDI~~J>d@_v(JtD+|Ww*ga zd{5?l>eeaxYLysJbtrh|iTmcI#tqtRa$-{exnbeC1;Y>XRt^wa2}VI%yaW5nu^GFU!$XtSrechHN#Kml)2qWJ}!knj;^svb8qB9C2KwK6j z$by(bn$XK1A#4NrbvAfY{1?y5y)eLF26}&XPsI{Nt0NTM?D49LRCsl z8zaCEQy#(zf2|y6Fv2QdFGP(SO-&M?Q`+)W1UL|-p9ZtB@H1kaqfUhQ@ILT^dYOMv z4%p%C=&Urqh)QlyE>7ZNlr)K6W2-+!dx>7D5Vw(jurc1RFHt76^u-&5ZT|{WxS*!W z1A>$nHLEM$K@V|V(n2owD$JY$(xjz~YaynJ_}yhF%^)SM0_aOSQ?k<)KJj5-JokMF ze)$#ZiDjhcT6T_NZbm)D^Hhp3z!ZO@K0V?>QT!(%+L#qTff!w$Z#~9W5eFFzgPH}# zqf55XNVJ{qWp6{9$uI(~jb%O z+!!G`&Bo*vqLiJG4=z|4W8l@?9+614Hk_#M0p8X1Vpo4Bk+$h_tt|&R zwXW;g4tU7L1GLC37-6jLe6la>$k=*Lff31;3WKDbI8~82y~2q}U>r1&S=FfY2cXa< zF_ISp$XiClatbrdxWsYxbw!V^3=lsiJ1pJk;yAvJRENd$Uz54n(XmGzbZC4L(nf@z zqmLv`G+0$}ogE8k4#+HhvOTu65Q!+l79beo$ZK^l3;{+6R-5HP7?ET*#6+>g?xf|L zfFvrU2{qc2OK2K@X1XX=G#4e%dJumJbY4v+tix?)g=A|I2R0E>a*YDVM#tH zM$tSmzSh2$DvpR$!ofxo=7?*nBu2Ql5Q#=suXO2XwaT^`GDk>1Dia}`+YzP(%sR|) zSa^^U7zE>3#XB|l5=yMp9luHgTxWv-Q^_@`JOeY3T@Nxfjc>C(PZP&hWqa9n2JjJ@nZZ~KiH)>269f_!`xkZ8B9nEXFuFDz7vYixEc z44EL7a7!mH#;itNPHJ01Cu2%MSR3dX6u?q{G@Jnd$OO#|L?j}8!AI2t%yP~1nr0wT zD>4po1&MnDqlubmbA&L1Qn)E~JkRh{IzYFQK+F!vDhxHdF^Dx0=m=zyWG_L&FG3_W zSNLL|&;|u<7V9Fd0dmzLZS62}0r4k2Gm1&7fTGZpFmQqDO>_-xlq;2x^E5{T;RH^9 zjQAN;Cm^nsoKeYxWr6ZG=jy|EGO#yo@`tJAbB>_yb0DE@c_bpN2qr8t`EjjgtBIk_ zFlIJKVS@|VJw!P^00qI4hEf%LBAK>UAas>m<_XZ#2GAUw-DR-?7uA7DE=zl@w3PS! zhrN&Gi?n7g1}t>no12})b4tXHp~r-OC}>yqEdsU3BvLjzWia1J15@`%Rq4`$1oH`A z0pOb>;S~&~SWhy_nkDuf3XC6_oQ&+nPVbNYo5e01kiS!L5Z5QVRr)_}XZfh;@0GMc z+6ZzsyByb0qGOcB1ZEK+(;#YG#o)W0ftqc!3|_`ezk}fNQn@u z1iH4GJIPY0fIKM8LU&$zNv&N4h>Hx@i_Ko~a|fgOV*RFOkkr=fy3uxn5yweXnQ??h}=VLY}fn+TV+w=2DfUP^i$f5{3vqR=$98=6V7FSx#w%o#PhL@ zm@zU_t4`E#>uDIc0jgx!Q84PaEj!wL^XAR1Rcg>}XF928&24N4sTY&W7^P> zuU0H~J<`DL>DZymmD}hv;(A!k@AQHQ-C9rmnkHKyBn!;-_Tpk<6;;wo3utkBL3KMf`LF8xN`3UAeEP;~u040=7Y-D7 zzu`X~D8v_cfBj?X?jzFLd(L}RP}YtUY1j0-ZC`ZBRKEEB3un$;5SKpx`Fq8+^#8k} ze&2n&pAhP7Ajad!3vFKGpp?du%|DFDcmbiI;_qW6?f?niTyWbHD z-|2o;G`4sDhg{kH+UCDriGMt#P|f`pDo-JL3Q(d51MTkD3|be}mJKFh)GjWrgUqaI zKCnyt?k+JCf)HnUI@s($?h<0=QBjApxj34Vt^)KogQ;TKcSoHNBP^nJbg#ZWrfEDZ zk;WJy4C||t8EPtj9sB=$#Z8(H)S<}##yaY1&hX()M zCw>nSjs7k_KVE)*Ldb8BRD0mO7au7RQApwH-I#%qJ)jYPk6CNEO1w&KyeViRUcD@u zzUl>okeu1uRl?|vcaH6bt?FxAO_~VlxfHtO;-(4*`6e`VJEQ zocqoN{&(xG7cP8f_xFYLH~p2KN^~uhqDhXZScFl3sY7qm%TiCJbSISpE((^E6NNBP zmdSY)-Am;^`6s)#l732d1d^XrIe5^Ee@+*}d6QgW+m%N{vW<&zO8*=5+dE2hzu3?_ zC%Gihc!PB1^RWb)-LBHrE}8;d&W4>@z!mjnveH6|loBV$gf|NJNeod=Z(ePj}ERnNe+%WcjA^87b`G4gDm zyjlC*_)t&}x0c-iw0-ulk@HLKlRDy-K31BO?v z0(hKbU}Rum0OBW%TYKX9ZN4&aGrs_eFkJQd;DSsuUuNC}q&OIuKs*3R918sa0C=2Z zU}Rume!&0)EE_;1^JNA`22@ZE06xS5?|7VJU|?WienB2)*+9HJA+_|tw06S^K==`# zodEsjYYCG;av*;P@CbkjatYK51PVS1U<&371`C!9Gz@SIjttffN)3Pws142y@D2zL zA`X-f7!SA-0uv4sR1^Xf^c8*;%oc_g>K8y4To-s3`WSo|t{EyBiW*ED)Ey`v#voK6 zlpwGn=p#TU5+_V2W+#Rx(kLh>rYSrrb}6nY+$%CH5-eKUEnqHYE`Tn$FXAu^Fs3oO zGek4iG%7a^H<~y`IF30GIcz!nIwCrJI^a8OJOn(RJitAoJ;pv@KG013O-ZR-;8T2t8~7Yw z;7fdkukj7O#dr7~Kj26FgrD&Xe#LM29e?0Y{Dr@ARs|#(V>UJ8Ur*&7+5&m zghxO`!h{XBvywZfiSaO&JV|BChBu_k#%{>7Cg^`!EJM$|gD3X>kji4bz1Adh5IOKN%2 z@w_DGN${BWE`@cK%$JcrC8?tIXNPGWD$;7J{JBF~1>u#8jPzKN_tsYwv@)@74AH7oCc$!??<2pPHl2vd&(uI?tu1eNsA&005*My}mhHXk}q!004310000k0000s4Hx7RXlP|& z0043n0000O0000a2fGAZXl-004480002!0002! zo@LC2ZDDwD05<@0C;$Ke9{>OVAOcJZ5pH2^WdHzkNB{r<9smFV=H5yf%y4gWbN~Q! zXaE2L#Q*>U|B8h3s*?x-L4Ur_IDvtcfq_AUX%CR>fzXT(7z`Pi7#NrsSeY5Hf`ByF z6b6R}j1MZAUjVsLU=pYiL;wKFdkWJ40C=43)CW>jK^R5hGce>JlA|C9qU0PUiR7Sy zlB1F{M)u}nW+&M9U6&zK-|ON1-KPfX)c`3#a?l*aA!(9Wct>m`+<%Ql_mjzt?#E;K z(Vn>OCmtRj!!@RB_&pw7lfvG3D5jD|IvL?y7TM&G8|3hWJf4zI0fiJ%ObMlwQBDPw zRPl^zYIsg9b>a1bdK!31Bd>T(Q}`4uw9-a<*xx}XU3Ak!FMaff*8qbIh3hbH7-5t# z#+l$Ple}Y!X=a#Zj(>R;SY(N1-t&Qvtgy-_KC{L;8*H-0HaqOH$36!f@`bM)aU4GV z38$QK&IOlTam@|4+;JcNPLd3*$)@Km5jQGFEBJOG&CoX8P_)v>V#nVQ6osp}k#(_I6wJ|LHMwuGi4H zK11jF4V@b>bboHp(77Q)=Y|cPdt=f25krkpLya**jd6?iOc?6DHPo9l)O%;BH)W_d zZKyY6s5fhYCmsJCdSw`8cdY^e9%Q164G-bX{d6+^vML%mOidY=vT)(rL5 z4fQq*^)?OlwhZ;Q4fS>m^>z*Q_6+s*4fPHT^$rd7zJD0%eKpiOGSoXZ)H^ZMJ2lih zGt@gb)Vna$yEN3hvgkYK+EDw(Q2W+U`_54N-cb9Sq4sw}?H`8PKMl2i8EXGF)P6AT z{{pd~OGS8`l)Vd>B}a88m=Tc?k?+i#&ztxCsC#c!S9MkOeO9ZxtJIB}Zgq=pBw7z7 z)TXgOAb(jPSr{4N#Vs>!0xxIzOT&4%y^tQ=l{<+5z?pz|1rWgwd=JzHI0ZwNFhBU#VYA+ z(0;cgg-^tw+ZptC|0d)95i*{QXWL{pJw%30l7EiU(Qt=MhiQg?9)U~hBu*3j)!ock z5=)`}x|8v2y7!mDlf$kbbDuj_JFM%^pxOaep5}qYYOE6v7ZP5>9*-fEt?Yi#~@<(~2-SC7?nV-6rEuGvo zbxE0~t3F((cW6?xw5j$iO^arutUKt+*=UeWpl_h7CgVYWgQ)JCO-I8lQGFX{X_GWa z5<};7JG03sn~jq0M0N+sC$3q&W-YreZGRnYy?V16`_Ox45;YS)&-e8^`|{AS4Lb@4 z4bRI*y zeC1v5`pO3$`SlMj+OVJgtya^vwHuWzbfCH$6h?kB#$le!rZAjIDVAN?+Z|63i+@56 zX464`HXW+*PoQ;!c=zmhI#6dPSPbuw$`~YUU0nqIu}xC!gp@p^8{+(svDXFMb?z4r znxSM4V`NR&%W*^ZT$6KRkqtAt-f?7N_WiO>$+?N{JC?5Nq-%OdVEjOYq8hutrI$i3 z1ED(}*S%QxY|4oy^s84W@jvXi`hP`9EN0G6lsNlVWFFiacA&p>m%}rUo&Nb(lx)k| z+_$xpQX9FWDoKesNS%VbwU^4B)q3LV@^KP4F4SJ~*2!)z+vnfok-G6yQzi^b$ zqs(%RaOprcs5o1d)iDUGKk4tQMzlTL49yxdyQY2UL@lY?y!v84^=gUjn~4`&Wx=KH z>CHncXLg$1>JoE%l+>VYhNU}MGpNE18^af_mICgimE~-y()3c8b4=u-y3aR_-g@-< zkpZ&=I-NLfUd`%Z*Eo5_=6~^FTDClFx>3jzv$R)fKd1ec_O$jNNknR70KK6av_U$3 z2@=s@vr!>GJEV`zUS|_kK&hdu5REB{*g~CPr)B934>hq%CbKczU@}EvMM;_sK^skH zBP=pKLg3Uo8GtrhXE5v1WE;D^Nj6a?M~hAdQBC0DiRxXf!(cp>sDI!___z$NhuRF_ z!Jy+}xWFgf{$QBKqSGHkT}Ih3g}M&9X)#`151I(G0JSKzWZa*ms=`H;)ZYjim5op! z2E%RA?}#`ZKoc{(=b+C526}AYxm7)e84yrLb(+@t4hVNHv%}T8#{$9P17V(K7q%O9 zre9{&oKhbiNEqWBWPj7qc@$Bd8>aB2MJP9P9pr_Dpkv{F;kqa435;MlrOvNJIiWE8 zgc>^6C1^^%>UJt+!K6+FC_E!DbVu55;#pq6&N({UzXV#B`K*=(HQ|Gn;e=W>ICMVk zv^LtUf15{J93CH=lIh%uphYyUf@0;vr7I2|sIc6M+|ZXxt$#d;V$&6lJk#C})o7jl zJwGCGJ&ts0vjEh%1@|F3r;aOh;#!QFoKoJX=GJOO2tNY(!2X#uZCz*Hb9y&!Ubx)O39X{s3%F(JoSP$lZsI_phT~NZi2$XbcBQ&;&*B5*7?qQyS>?Z zLRiqZ2Gt$vGSi|)M}4Me2jvgjn+YRdw(Qukl}O&Qb}F1^UMS1&+qK) zkjiAaxnW%}#%I@u*AIu+zxamodzL5U;hS$JmHC^=^*8SrO`MHInL;bk(aH z&jxV(%YVJ?{oUEd>HN46SXS(%VOj~BrNJ;tyesPPfYpuFmhTu&N}g^yeYd|Mme<{$ z(}dUZP^=8yo-DOQll;r!o3~@Xm!A`v*yWW6j@eyrX5Ft*YeALbI>?_x-;yY zK3#m!{H^E=1NnAuT-n#jSKY|A{CN5DXB%f%UhyKg9OtQ( zSX8oy&q%R-e#eblwXhYgT>nzZ$w3k}11jZLpvv}&U4Lc6aU#>B-3y>mZ4ogC#DDUd zFo^Ap6VcLL+i#s|y3h@j_9Hg`OA+a25Oz=I08djcZ@Ho5MS>Et#n=tZVn$6$z>G@7 zR6p!v`?N$W>|q-Rx70v$*H*@`G-iMZ+hF@kVERXG5W*7cXV0GBoQlgm&@9;r@@^jK z$IKJeZ2qg2u1;EBOl~T7bo%9ECV#6Qo8PQXFN#LMet!ULNrAxJuWMB^}WoTw?t8b(|(+aCAaat;+ zVcwkojWAhf%a41N-_AshMSra>5D(J_Yq)ZHz4A)WOU&gfL5h|HK(-KU0QEB4lyR6a zFBnKk4JO>&_Y!8d4{jbm=INatunQ`k)1%d=TcF0c*T}&ZeVXbOQxB}rbfh6&14?+V z?)n5wV#xtRo7W6R_UjHa^Aeylri>Tx85sv2F`aUW!68bkj>G(yn15-ITcPC}R$Olc zCM8@Dx)cU$V85b%IqI90n$zt28{@cgwIijIAUc4{9b3ptW9czZn`qD0eiX)XR16RN z#V~!LN3m0p2O$0;Y6ReK+DBNnKtjVQYtU_~&Z*)Vo&uqpOdBX0_z&skXbN|nkgxWQ znz6OfPgYE9oWC<^WPkMg$03}?J{eKwr%;Lpg>AG`04Z9AT!!ZgEX}dV+cUdv5kUPXT3FJbhogp|kl{c5d4tNAEm_ zH>KqA>DD1;>OE9>oS81~W?rrf<7uB6@&n}3eETuzuOC5nHGk+UfM1~8Q6Y!`5rHfM zrkxfb7>RdZohiBts95)VIE4Cxt{bbK+(sR$pfey*at$|P!`g_uQOC~K?zs5M6a7dg zQP3>g$XW?dWM1aJEA{3vo^z7{Vjl?Ov<$85 z0#Jl!JJr<}tbaeB>o45cihR`bhMia?5K6*`>7GpC2(;Xh!LrZ2Qmel{7)O(QrPi_B zh&T4PByb1Y3v1GX@uFl;FP4EbJ*>SO_2LEr>^z3v*alU!PJGgt^zjQqK;Yxg3b*e7;4uPtj0@bSLn86zOF-OnvUBDoDcvsx0gYTs1F5pEXjQaGhPq4 z^c^_O9SbJ%54s8147iC5vTE>yZXy6oJ9=>w_`&Rd+JAi#b=K57dHRQ3;Ub5_D=fiH z`+s<@;D10GI9v(ObsDw*m&dA`KuOCG-uK<4BUR;5x{AuXm4myLg7-@pU=BEPOS=L_ z`TrM=OuES^8BIo$?rd`D2SA!5`@35TK9)>7cGD;U_!uk$d~}c3mwOv)FlRkix+$5i z4TtdW6O%)SCWonh==_m5=p$TYOqh0e3UDzFO@BK)+m1uuYx`xdx%S{>ZEI_dZEsJG z9h)rVl>P<%KeVdWgckfTXgll59nzKLSbpZbfAxj@`uqlXow+f(`eya*qJMorf{Vw_ z9K9F*J9_5W#fuj|dG;(|#X_&z3w-Zu5g<~079jno)Gl$j{cQ1=AN2VpI-D=R>s?>^ zL4W_4^~`^yYj>}#tW0)a%gf7qZThBWX(6;J28~?;AO=uitiDa@mmmGrcYgS-r~AE& z@7|eScP;tuYk!t}`&i?q!|$1Y?CMMQ07#hD(=OMZU+B2v4;0gMRLq}|@)7NVJFwds z%*(D)WZk{eXtRMWXUZ?8&Z&uCoB+W9eSf=g+0aQH>2lrbMB~f*&w1JNV6@HLUAwIA z&HlyaLBsutU!}v!zP4Mowogr-clyZ5%Wa-JN$H7C1T9aB!>1~Z4ZoxbQw&(7aVJ1Pi^UwVAal5VM`Ca$jkn(cKhX(TYciWt%eoDYbAMx( zqtU-(WN!?$s0}1-@hZXV8S>3}_7OavdNX3>g*i>o1A(5k z4d~tj<2_h2-E|R-3ZIG6X}t~8@C{Z)XFJHU-8=!z%;qX4j(0*o$~K=*ld$%Jh<%?!|oZe)OvBEvJOQ_Vr!^lDO= zX|2cfeEvbSR8gtk?Ep(=TU+9MC&Io_K$^XT{`n7>BhLlddnuw3r6AO6@P7k7d-&>i zQJpJh1)U2W+JO#UV3^S^JS=**&v#uuQaPZ~!Z{`S0PG>p88 zG(p|2{_|^I#X*8(d9b?mwxgGghs&wCZ22HT0h?DX-%Wl00XwNVS<~T;4DInt>6f;x zZFl?4ix>Vk5&F6x$fz+$e18ipwp+>?-n7-#X|pbha4 zw#fkpb}#YLXS1nxjrLaU1KNkQKSo}f#e1OQ61M0J3gA2$pa{X#8xO_`sud^=_`*od zRb>#1o;!q^8v)#`zaVXZslh}G{FqD&wl~=IXO5-?omCQ>EJT-$3x6T)cJ{DNqBO^- zK>izKm@25#?XMCA-BF_~{A&|>*35Ng)~u41=3Ct1<%*T;Pf|N72}C}Yh;m_b>7*j@ zK;9e?0aoF<;TeN{5%)RJU@zXNRs_t69YIRjD8_fTqqQAJ$-YaL*B}6bf^B zAeRD|0389E1kI+-UVjVHZsj6?spXj^gV)SbAP?pkd=RwPG>IfHv+NQBjn%2i6ppi6 zt-Y@y$)mckO<}LNwsd`<)ZF8QNnnyXH4R<2Ef!fO*ehxRUDYGLmG7YMj&UJ<4hkZV z0^bURFaim^z#NvoL#?l_W0yWC4!{3lBIBJLOnxYs(8sFvQfnz}HG2Eb zj91f;IsVfAD=$BH>deX8{qEZ4ylfJu83k?a`|5K{JAJ7>Ke#p-$~MrG8+sU)$c^yWbJO8XW3ff>CO- zs2%aaWR@kpBm=Rd@1MW(o$n+U9-4pb$tRzje}C-$`|oG&{A=^Ck^HN7e)-;ezx?>a zr%yk8^)4^l&yFDS0!1XVft(Fy)&X>MQo9PS>@I9` zlYb=Li89|K<*a~Th;as!4GM~8I*Uf=qu^`lhzFI{&q#X}>von^WRO_0u)i1h~tBw?ks z!BU&1kap|q-)!3gzk+$1+;Yo9YfWlXC)?|`E(Wv787B`$lKaANv?Kb6CTexX4^g9LE)h&EY-M(t_U;#f6h-HNr zGtDq0bwK%jf&YubKxV@k=$D1|*?*=0j-ck@bL!=3 z9LKkva$KhCrh>%uEW9*?Vbe6@3h*`jA}!qqCG&an16%4<)U2E z!L0c87`pH<@Lw+*UUB@|6R*C;^Yi@fGtYU>>AQ1od8cC^rgEb6@BhWF1$~rj1MPrz zwRSRRDZ;=+nJ4b$Z*m}>C12qu9I%zmlOzZ0R2t+JIG~*DA*Fy z8rI2Vyv@>tbq6Y#y`#o-jD8Cc+(op1I)Mvk$_c4_tSAx%C|6FdB!#&grx{SASSl+5 z73$*r-c6h+3{ZcA7WD+KgbofVA_a&5k`>~EhZkXGD42E7`;nnPB!3a@dz#{;O{V%LpX=jBF#G3BAT%ztuR*P;fK0hhW-S%;ejKq5jdK}ikJH7DHVwJCZ%0rC7WHR(`1R_dV(p~prop;~t*Q=)NmzPS0^uxoh0Dqkgw{WTDIi3$1*|iOf zsCv3fU|M384UTab;lP}uCWrc0uv>f^&?9+A(HAC^;|S{Ru$W1C;0OmW*#;DN56~b+ z=!YuhN?bCfY{gMkvMtkfLzg)RJa-T_xSpl?y4*G$CvqIK3HpvP7FqyHb-GxsxXj=dn@sM8)8i+iStueY2B&ozXzYM*`qvW|-KWpqfp(I%;MUn&b*p zy*aM}yylEjkI8Bjw>;aAp`~~7{k0^eyb%su?>r;ifPcXku3=#a3w|c15CRO*xqudx zH9dn%=xE1rKsv4M?P^29JOG~j%v+0mrFmuV0)L=vqO)u#t!hQx*&2+gn{{tI(G4v?; zNCf?7`_%C>yJW52{mL~r_wCSR6iVtiJ27lvF@G5A6lP|q8}i40#I}Xo31A8kA(R8% zbV51*x7lFjNQ-9idm3?>b`Gu%egp{>rjeLDi(Q8sxolW^#fQo2RK7$!u+KKk6_)~q z0l30#9Nm8w7R*V<&HD~~0!PWob0Xj}vRBKNEZ}!mXi0%#eW!6`v%K8$4Pa7Tqn%Y_ z3V)(z!~CgKp!SXRrK#l_esnU5YhD>BpCyxbvVE2I{%)h2MwEt0uhCs^l~-WiKs|g8 z>H#X^20Wl%LV^D6;##%|a#7dzq1PcBAwdQ!PXM=IPESFLM}T`~gV-aTb@X|H@ga|Y z_{JC8Hypd-IhSveA_7OX>WB z@BYkt&aM9Jsq0Ri*tdG(-m5m6ixSPz9wxpWFy^v$M!O3Urt*p}LI;KCXV(56i=w>a zV5D~Gej*l5Ya(cAr#j0?P$fT^0$yZHgH6_e)34b%1 z^Bc2XDW>EzY5%zgbY>f&S?6d=r2Iqiz6NlF{SKprNjQ zCOiYme{dG`QRMrQ6Mc0bC=iEB?gXq{aw+sKcc2>J=WU-E;sbg2-U9O@HKwKEY&S zxfVz{*S#Qas_>s9LuoQUi?d1+M7jAG0_IlQhB<*H|u+Gk*qS6{$jkGD!#1 z5$1{QrZo(<$(}cMlnt9iT|-|fTr;rO?Jhc2e2Y=tebsM6pQWwN*0Yb;=q3bQVoCPV zk2>;tDmW(F3ESClEJK=(XG|>Jb02{Q=jWbt)mhTAa`Qq7s2F3eX^DIzw_`_dliyBm zNWWU=fcZl(hi+7UC4cl`duJ3h`-g?am=Q#lZ@Ci(6s_q5V)dA3z~M+rY3%t5>DSp+ zz}suUU00xIG?@K972U~UG6Dmn-1l7&bj;)H4kUg<5W7mIYX+F(D?I!J~i@ZW4oEQcLjYJ0+{Oc;~DhDu03rFMuoSFxKQx$R7 z;Vc8Hg`Wq;vjeE6W2D;3+^T#)9Pn(4{Bz;`QC~m?03M5lqaAH8y$fcB&O1Pz^$OA5 zifuTo2~-kn)_;9RF%J#KiqUr20VxN7gI-ykU3;uK%%fhlorVB$of0TNW`Z{B#1#ZC z40D*8Hq2fCMaP@Eyjd>;UP;`D0!WHP;P@W21b|(g3YaE3p=F{=o!#~@2n!>jWCmDK zYFU6fq4x9>!N0VLXnv$@8!p;#BLK1}4BM+`-UZW?V1MO=kOo0BXBf^pHPhp@(9)%C z2PNAOdwIg2*BaVHyG%O<{a!e4yUM_fH*vl|zhky9W?oKMcY@jpNd0Kx=1pK+W<5}u zqXgswKgr{OCZ{*7zMOf7pc~#5^+Fn8Tex)N6hPE7iS6*gdzf@I=@gRoUuwH`4!dl08ny zNw%2lkApsMX(Me4tyrhs{vt)aTN+Jw=pt5?lt!iT091CO+~T9@aI&qEufUqqU*VO0 zI%srC^^9F$Znf?mU-G-AYo2GlTST=2!+#4!C4Xu}a(?H93v?8>B1}UU=F{^hF)uL@ zNZ04@B{$^ef71{33|kUrb}Y9YJ@e2DFI>tO+RvEsb!k22>5}O7$>@XgryhBPY(4U~ zXV3on*|YyAXe@93k8j5RcIU@8>Hnq)n7!ZYlO0U5?>_#vw>?h2{fP%2_ymm}yZYkA ztA8J3kDa@C@!VsJF;40K4t=w%9n{XDy_=ws5{e8jY*N-K!ge@|b}%D$IuqFpK(CMm zQ!bL{3KJ)RL91LgWeW>WJ^i%MtHBO4r!Skl=n7Eb<$BZu{T@W7rSno?PQ=09bbEb# z4=*JRAa&NXXS;KwX^5umtu+OUtQWn))PEfjvD1g{y~(5RbHPkmJ1imD>PszO)XPE6 z{K&FPzHZ&uTt3l0bNZM4N@AK|B>FS|g1KTEHKW&E6QMlo>5dr%ZgRW18zb@PH$hT1 zw9B(HFSj|YM9YCBwm_-ff7*JPG*HBqXuGgIupb)KrK}#&( zO#<)t0KqsGVXK@_PQUrgKRg6%bHhge%yF2^Ebgzx*@X=FAEg|=+{=j%IEz0GoRG0& z=iSJ6O~;J@APBmZg9gAO{k9WmIa@cVzAM zM!P-#ee&h`7Wwd<$KP@{8P2abOztC}ZNZ6+)^E)(lKYeS2k*Q3p$Ewa=8uuuu3vPM z?E_gGYFBF4C_RpvWVHaLb@DyIIMgZq3F$0SUR1gfI>2Tf6{woP_XK(xpnuaUNk)^w zZf)6qzQ6r~gYEk8#;dMRg|#}n=HUA9$DeyN!rbclQzwrcK7QiJ&Xp%#-Cd$r9^M8- zs?h0$ylGld?eSZ(Mr*CnqQR9X4jlDNbL+~NG^645hp%qM+&XvkCJg;ZbN`7i09CZniSjFd^xBg^3&_5GCrFVwk>e_2h%|AqXomc<-Pk){uYmwR6)VB_v zeD!hihQ(EvojB56=%jUa5O~JV;F#emhDETih}4+PagMR?rs_SmpSfak6Q!B4K z$1Dy!TuP?L(5}50c+6g-ZE3%xJ+1wBvXA^Yc`x~6@-+E0`48kXIA0HR)ry>0WkeO} zc+mM&^!HM4m5UM$+U_!p>0nIuNCi-hj>@nS87{0)skb8);{}W~DhlDy3?{?uK)QGW zS_(|cLj8xs3x5-qZs2+%8BaJmH*xhxchsPnS~)gT6tmEv(^;}B3K)=Ase>RQQQQ@P zIrm5^icmphcfIQfzWaO8dRC+k7BxVHf}uFPyUL-)MyN0~HUJuh3=N)j01O&FRH)1P z$_tCaIV*BkMqPyf_WEMC8-~-Ny3ugTbObFj%jhveOiY!a z#UnknJe?3ae-M~c$m?ax)+NiM6rE+t?U=VhP+HxiE2(4nCClg-%^(0Hg9!?@4KpWq zqpr~kfq$#Zu5kt2zh*>DqvPWu6fhE|)AFO{3Nl1E=vsRHP$v*Ixm|0wsY3t+3k+>L zDP~NDmQjG7H_Q_&o> zBTOX$*epF;asxxzFl~pz@l2qmKobvAhE7ghEPuNR{^(!@=A?Imo|^;b zwAI`Kvk2(dacf)MFfe&)rX23W7>t7ozIoW7MTAONGo8(^qJEJW&xtp7_)epj;v4=DZIeV1+I$(u4WrB z3NGV!(l4jkP9f-ON{kPuV)awa_6@C_MSj_p|? zoc7uRs_#qNixO!@zHlUP@uU)&kzn&CMt=zfLB|cI<#6B-CXomwbd`K7&BrK8l7(k6 z(ug@J0j{pGn8Z{IhDD(vaQYA~5df*g*1+#*w_ey*o#L&TF@>8(rWdDPY+(oBxj+VX zWG1rYd*s*VZ@=kV3%vVJ^rKn;8WHn<;$r>WOcA=tA`^V9R31(+S(qeTgo%?aUVr2o zl3T7_Y9I5LY%|JhUg=$7xms>CYTa9(^Q;NTWoRd9wH`Rj!;SvRsd_7q>4(1goNkNr zD@;G!H?*XY^fPDas^Ly_9GWYVj%^0fbTDjo4Q}q`N-(L-FhUrqpl*MxYITSt-692P zFZxrse?+RX+0}V;Dvi6nPJ(XY1b?v31e=8m&2S0DLZeTxp%_V4d9Ug=qi?j(*-p1c zxr_cyLIbbS@B;isqtwk`Dkn6UFm@YE+=%JBXIY#$`EU!yix@7TAm2{RZWNW|=K7&L z7mjZTH?;b2zzE`=9lDNh^E^LvzSHY&hz+xAMxFDMeCPsn@5O;3OHtnnU4Id5mf4~8 zO?5u8{Y$ur(0>B!mTP_JomfST$LqwSeD8Y)nE3bp_*#4G*j8J;k^ZIc4}H(!m$!Gn zweXAj-fC_AT^rw3sl6O+`dOx977IzD(FC+No6OL|LGoKS^4lNz_y^v5ZO+KU^H&4& zN`vpd<&C@brk`Xl(B7#1k$?85$S2Y5u7Z6@+$4oBb#F~0fV;^UFzW=f$cm&A^zF$a ziigF(G-4)v@o$WySQtgP*HDQwdZUWdXi>KHBKin+v=6r~tZ6hZa%Z71TC<4~kRtl7 z+`?+nq&nRn$cCzEu`IPoQ!r=)wT`=RUd{USq<-aegO%dvH*&q^T7S;b{q?vUrio$J zt=ul9Ou%gPxL%Dm%7D8f%jMxVC?764s8}AO=g!CUDHFJg%`Jyhf>tGRE#bvr3pnGZ zWid0gFytqw2TFy2rUqkG`7syc6P#Na^SB9W#wM7PgnoYmuH(AC+$dj$div0DAWTl9*3Hk07?iC3?ph#p{d!>ZMefdi?TmK6_Newj?UUNKRNiiaEAK_OfIPS$1`|am zQw-*UN>KO+=qiS}r;}m<#t86p;o6T!vqD`ISTP%9`bVluqrXSlKfjQHwiWhwF*!23YB(h6!#s((jd(CWSAN{w>o=a7h-W*$~c zgo5L$&FIXA12^XT4>VjjYME}%B;~+nN+(O{xs*9z zqf1VS>VF}$KCg(D&Z-;h3EU8qKbhk;blrkVY)PFOT;{dqxJRCky5Gzi2Vt66*liAL zgyo4}0XtzBX%iinXsQKEJY1y;gen*F7aoJg1qzxl08i)AW@@GHZRQ&-!W?vZ!VHzU z*ba{Q)!V8ds^|Ck?$-!NDQK)`ljo9~$t~nHeFqY+JMM$0q@_S>XOv`71Nm2T1ry^QYAE9jN<41FHG zfj*z!NPmRBkiM9{gx*f?q<7JK=ugp$^tJS->3#HP=o{&q=+Dy!=r7ZU=_B+}`fmCg z^nbVM2kB$6OFIgQI-+#)< z02|n!fo902sIO2ds2hR?;Ug%58;(GWJL3sS#{FzG=s>-OKEeBmj?B7bk^pBc>N-m0 z0L~>ot~!-tW3Ncuh9p zRI)=hCH#U9JiGS+rF>-kqru|9K&Vd|ADASw1FFDYX-dA0>#nF$mduPKRlYw$I-oGR zOgE%7brlP2FlNG;HA>vbl&3*$iMwDz_TQ)TCy|U?`lIw4z&GUl8>lBhi+>TolJiFd z>*|cWAE<#bpTGl7>d0SqFdBCptTZ_ZYDGUR!RR}<^@ItALRA1j}&ySrx&f)m+ zlZ-q@8y8=RPb1_QTLakP-Y|bZRO>OSH5O64X|@;2<16lzCGLvj$4aNve$Y7DhZ z5Vh#FjO@o{!t{~-H5KUMP1b?q{17Gv(i4oGL~^~&RYk~?Fd%Y% zHI=Td3-V%2z>#wPIe$!0rzC>GB4-{3^Txi&=N{VTLtN$d=*Kv@4Ttr8C=0m4Reut$ zfTHFTf{9PzFh4Bbf%aCW*d2NfY?Dl&f%A7ue9ru}Ef6>ZApGk<9!Sa_0mz9GM0?OP zzXUh?&#(9ioqi3Qpw~o=VMzQ*s_$Sz7Wp_6bhI;EDG6q)5P(gAWAT&l?KS9o`I8HdHfI%FRYgi8AqiZjmVbp$XY`Ht-1L$8cV6zyYD1vm z8!Vgu@y#D40Xb~;!&dIKcRAkM*;#Eru0NN1i*P#|1v#4zCdEqeg?kYQ5++>(KO^6D z;*J}Y0>km@7Bp~_o{GE?;KkrrZ{TDl!*h?=oMbmjj~%r9suPy8>z4PYQFQqg$&dZi zt>+o&P=9kLNoYAVT=T#+Rw!<{)-*4z%h^vqt)*H;YiO&=i?O>2#RxZ{Q2TitA``WM zNiAY(OQ3BFTOFZ!#rzU5*9je!+wF4DkQ>&lTidL`zhC^t4{U6#ZETRc<~QCpnUMDl zF55C|(fp@24_qLxi>u^`_C_lVx~sK~t&Q5oJAa>k|Hh}jaQp4_;PSWnTk{Xb)iY{y7s#MUl1=v(p-t7^Jj#iQUAkSY?#>eQdhV{JQ2zV=Vztp=kw1f1 ze2sA**S1@}X!&Mn1;NpkoQcNzXkd0tKX4M$GBKOcjglT%4dK~Qqh0NuJ2+|f;^lO< zd4E{PeW0w=1S9f{%Q%rv0(wX0z7YtAr@dT=PRD2(9;bF{8JvR6Fk8S(vTp911~)l# z`xVa&%uvRqbUU(LopV{eG)@xc$&xnE4rwQ~mm%{4Bm^)9_YqPstXnGfu~2yKE@OqlLk{&IQc+gq4AtSw*r-T8-CR_GhQ zySDPo=U)Bl_r7=SGs8Py4gbA&?SE?Re|l!Bb(A0J2S1bl@JD|B+H>z?r1Ss%#6q9^ zIsLraH%2NizK{c!MT2RvC7O&tFZJEH{oGFCt=)9jO)F-Sua_fp9EEf7oSAYQLcUAu{}4X>V;D!1B1OLZorJ8$_7lW`7-O7p!7| z&1kl_nkw5}23jmNQDL(NZu6l+tr)hz^(ZQUgB&G|7cR(R`GI2VLv%c4yOVk}oUD^c zZ-(0o70VcuqfumP*A10MGezp(9ZixkD5xp2d3bczAB?+7q4vds?-$PnLL*e5cXt6M zdI#8kU9Xxd-Fu!mUEJI+Fn6A(UYyjKQ(36GRY@qY~QFx9{t(xPSU{NEJ@?u9dN=5EgTdrexR(~i#hde{xm%Dia zco!g-yDXgtB|!kmsqS+4Pf$!@7r>(lwMAfnngd!d0~4T)pVx|PIRqOPw#TI=4=n@$ zCanV=f`>U#z(i`wvIV`Q69v-H<$;^ENrT_WswGndQn!dnBdG2ni(=^1X6U~X$|;Wv zpBZ)Z2~=7-qE(gz1Aj2h2zs5^%t#F^DqRbD67V`R{cv~Q#UQKawHIrz)Lw`CyF|NT zJ>_mv0sKPM1Ia7$p4GC`q}bSPZ*h2G6Fh=JUgbLN7XdUCNK;ul9d)<|$7cP3lI(2? za)r8;Z+1t@%~Wg%G>d>$p}%!pZh&nRn;XSn9X#_ zO1w7zBq7y`>4Nwex|=)%z{|vhYlMa{+N9<>5}x8jIz8RDS8cXh@2tcLGi7K7Ze9;N zUAAuoNKJqScYj1`b99Fy$g{1K;pPRn?Sj6%QZL&e$f5H!XXr+D`7p=^!Lh|S5Wm?? zL?jrPJEuxc)$$0Jff?KhOx@YdGm62ky%xq!>vfA*>IRwYCNrWVd7$=jR4Ktlt}sma z-CgZ=wM+v>Z_-tvW(-|`az!WeZd_L#7YW=EXZ^UZsO&yESAYO`F?ZN(3_^AwP&B&3S?|6#r(Uj6?GJr{? zTNItj0p&2Q?G2l`BID7KDol;g1sm!(poZSkvdX>aaXq5KGh**kYC{>`e(}L2E(8oN z?x&?km49rlTrz!88<&^M4c`nhzcM{s54T3n9dR}2+?UdRvYtk+O*qiil z%Af@(jdwwo$W(e2_U2+YlVZ;V`Q z>TUO6-e041`O|!Wn`8*)mcuZhdL~0r$tY`9mRCR>m`xYZ6g0*+J&X6}|LP=_JZ}hI zV#ImoGs65jXY@{slNC@f`o_}o!ILX~noF9a#?dXi~1%-0G3(0yIKw} zoD{n$_cS2#J_C&eUSFE*_o^rfPY+ zQdD?lip#`in1YnW>1ayc#w%$gObb+kC4WE$aY|+w$}K@R7*w~=BkVRW)A^uOcJiI| zi3^AJH@!frB|I<^p#6_5bLqQEyJT42jK`~KyhO~@QXAPh$ zm6Cl^8w3Rv!~rHY*~uBkVu0G3dgvOKNljsq`&yL8nzPyH3eCV>?_%h9~lt?}!9+ml5@w2*f!a4eo%!3>n6TBaGGS2D_UZCRD{- z>@E6(_D4~BKJ31-#a<7+#c$j-g#=&yDsg|GdTRd3&wS?IM;`fuKOpCBxn+JU931ZK zko*u?IZSpAJ#~2d&>=wGhn_fuk1BxJCjFXrMtiw-k9ME-7LdYsf*gKZdj`zFI{6WD z5BWv%Zt}b2ljINSCOt>b)0fh_=xgX3=mYd&`YZHN`s?)H(D%{bK&G(RwP}Ei66Aji zx1a!V#D#=tC^7qEVK6aNv)COqn-)7Q#G?bqG%!YosZ{Bp*g{xMg2^HRjNxRp4-^LQ zc5~onyI;VD0^2}Q%@!*mr+qm*LU7N)Y*9{PY?)zR&uo+kl@6WacBvT7QTwI>zZ+%? zeP86p@A0_7?hnjkSy%?N&T9R`09AjEr$U{+UL?h+%hbvxT+_5jJ5o?K<%_&Ag%%Mp zz^m{^fEEMfAXM@grWvah!XsRLRjgq_x~10Bs`Rs7hDa9hX;)6w)+b|JjiXY}SlTR} zk7^V8Iue+q23_14fNC6}bGR?3xYoiW(PlD9NL*}?w@PrsBHG8@X9op0&pLmLJm zM-fTQ(qhZlq}TuhTB)+3p}SS*P8Zs1k2YtRHKdMp#@Rr|ic)Wo-Bh4Nu}rnIRUtrN zF&9atshI73lY5)f7GEa)sqBnr2jF)sV=Om<7Kt7@lf`f%WB3^Nvdv`BIWX#G^rOO# z(>n9@N^E-oE-EtwemX9{pk9B*gz_2s5l^@)ZOhbIrztQ-Bw?DP>z986a8m+S(&MPA zfQ54gYThuY#LXl)djhwT)7g9ALx383NH^e<($ASN&tcBLAC6N?|2n9)sE1iUEE2f4 ztOr1PGJ6k@;Z&sa0R*AiCkRG!ch523ouoX*`C97N7QW4 zsUe2zjHUsk0IZLtq?PJoC+=@?{$G$I54`cGE}kBDlE&6bXO2)r4-6=(lEG8R`Y&hi=jkh9%Is#QxA5=;)4X9sp53269ynB2(4@ z9T|@B%e7KFgQ^lMw0f2i;IfOsU?r*r!Uj{ziD_FP<6`CjoihU;+6LAPo?&}o$(z*b zAS%!uz}$e;Qu!84bI)5VNuaYvh8x7_`(N-*V3)n<P@1y&s}pl#?%kbbTyX;B=8C zhAn)|f8c*K5_U;KHSChh9)n?oq0mn*J|p}@)q!i0sh+E?#VK2(nDq8B^ke7BQ+-=R zN*fC-sIdpMPvjX-N-Ub+gd z&i33CYQg^Qeggxrp(-{xR{U0J?QW+|)V4^)u4lV8a)wE0)5U%S*>Fm}zSAC zez5uxKuhFy$!pEv@VFA%(8){f^gb^Re9QLk+AfL$aV?6{+kRM4st?**R==5VuWTAD zz^#89m%FCRELXU;X}fo}m)IvPKL|bQ|IMI%(EJ~Z0>JmUDtcGzQc>tGSNXl3q5oB_ zhd!uXrCqPx0zLN{?ac}w{igP@VpZ1nZCF_+?Sf7gP$kW9p%pGe1!FmbUg-~t@6a=o z1bREk0P+m6|0ZhpG9guFlyVP^2a|qx&`p2wIBtlLHqom(9ZXa<6~)Nig5bvt0O z6QS-rTRZ{qhH{VL!rWv6I0l{uPZ~|fgAx62wb5j9WUyH^J-b>8EkPI>6Di#4wf!R% zP$|!R8B+jMY`UzoE066E+T@VL%@N2DS$Jx}oH$1@L=M~A^lAM_E}F-w1L zz6!`6RCxa~{V1W{yuOSdPr+;ya9GG=-XC}~4PzZ{vht!A1A zxlitMA{fsIa6sFujlM%WT;>Gf`&#X~?^M38u2WE$K6KqYe!eE0N8kqa68gl?3Ks6>BgZ%dzl3*O{k z!*N%X$y*pda%7ou+ba7qcWmyM{q5t9>*UFS1Z2};$J1T~6lq|`U?BQIV)8+AXvMBH zbHi;fwOzvn`6SdG)^vx~4_FL3q~hAPm&XA{M#{s~Ia$g|gP>%~higN|hE3u6W@%sG zhh`7VFvjUkbbC0*?r#@XT1|eQ~@LmZX0m ztpvcVndBy*2AfQbnjy>XziRMlNBgB$D^29#V^;j4W2RdlxjnbIK*t!aSpueBcJpxtE>X>6)A9Z0)_=7fXzQA-EN#a zang)I|#3K!6qp0|NU9rgNc9GneM8ttUTWFpYQ$u_usU7 zITm*&XJs@ur=M_MJO@xk$n7n2M39|bZmV%*^yJ^w7?N9Wp{AW6Ht>OK;#N;rJ8$o# z#VQG^l|F24l5S}&Z*6Ywj!E3kR6HR;+oa#ee*Oh6!s)S6XIY&k63K~hR5%V+g59;l zt)t6pWJ7;dJeF@`wIyC6-Y@=A{Db%xfXK_bT#*H0#>lUf$WtR#Mpl5qMhkgy*|4Rc z6SF$B7B5#b@-VrJ*|L}eF))BnR?fOaS_*ZZ#26M0vX<27cGu`3g1{Loifj=Ei7KPa zy6pXye|H!&tlJrLYF&)s8W-dK2wJbi*d`S!;eUUV{nR-rIA^yz>T(WD2_AX?CNZYN zNT(U2zRz%i5KSzXos!cbHhM~DeL5Nf^$7b#w7&jzNp-v7J2}_2@ZL4>Z-=kD5r!BUluiFU81TCx;>BWJ9HwJ&08-HK!y=9i)jj$!`c; zPN?v#rV8jpy9Nk$`i9}duf!%)|;wf0$Lb^H(u!(`)40yE)pd!$XjO+tuV}q;M95YykPe6R}NN!UW;b(<%+@#9mfGy4%;{;!8Z0 zXkq)c;Mg(182vsYV46^R%^)Mu?>9)L>7-Dz_qd20lg&^HSIE;B>C;&_J{Hn=&a0b~q{vZmMsj1NjaFx=y0$Sv)xisR|hOo|ABhAUO4gG$dWL{DXfKL5)D~ z8pzl}djw*rRFfKoZON43dO#K&VT7fGi^{734mbAL&-6@ORqXaTCRQ8pzv=1q)kLLE z>>rNkp)`@YR+!l{%E@)jBdxkF)F~3j0a2LQfQ1V3BT2oHSg!l`H5yN@X(D8@+LQ9p zO+;K1k;RHrpsre+&Yt=X- z^FA=mq-jDs@UU*>CVsTMZignQ*BtBsIJTRt>}8~qX}BX5gsHaeAS8b+Mbv8#yI`vi z+EoD15_^-6mmvZ!u#E|8SU2%akR~J&h+VL7V>~Caqj<@QFpid63saX&$q>6!LI&i5+ z0gUQ+ezd%a9M*c%TI_$150N{o(`7FW+(y-r;2-O7tLbJYh&Rq&Jafvd>O+e`eOjE~ z1iB1XI+R@7-CRAi<2Z*}M{fDi?WP-&@zxBElfN8<+v`MzZ#&$o+A@i|8Nj8!9M+rAT5uUzV8 zB#p+4?Xa013Y*@5@!l34fWoN@d8?X7k#g2*X>u8NbX-9o94VGI7M_RgsH}#;!$f0< zaBirLb|aggFv-;sTh8v<$TM+o@2B2>{k8ugN){J?^2V!v?sXkg`%*QlRmswseQb+P zI37jft5I$?lG=YYH>InqZ@%%u4d-4{uP$7Fg_X6d3we>$EbAcFM1F{D(xu9XGx1?U z9C+^g`x50#p6!>h!|TB|#dIRN{NZxBx)L{|Or16IgT$N>Sw!Kn+Xv(+pFP^$Ug)>1 z7&Wz`mL4>dISplB(0F1P1}QojW&OY28UQbKh!=GU0C;PDtthx zh?7U@`Ug~C*~T_lB{aYOfc8;qi{^@+{s7VyyqYGJ^0o)ygxkh)I8FQkY^r&#Pp8`Z zd*Hw$7*zIvVmboWCbn4R93Q(26dGMq&?CZn*|-VYo!KX`)8G&XM23Eiw*%PN2De|N&=!w2^guU#ypEQWabSm3R% zdx2b@eOU~=Ab4Bz;H%j+fhPvDFXLOB6U_dSuN#rH?g{71^hNOfuLs`457Qan>@1#I zY`5v9b0PJDQvv;WsTLGG4f@>+FUN%0N)wgC zVvm1N<$!A`23j1MLLjZ_ccQSoi`K_LKgtYBO(>BU$ z)w9{__>;Qe)!Qi<0AEC0Pp7v1$TiphwN8KaiN#H^#aFCXYbxqT&g^x<5}ihD(I+Kt z51N~G@@RUS^<#%?sb9aX-hSQzZ+}{y<2GN-tDD6>m@L=jY#ppv00@Ue7y&wwPZ({Y z%av&O&~eVYphM!h(^W@BZTQgEW@mKwaC^fgQ>@;0NcqRjt#h6${p4W)V5YT=^R9o9 zUi^-fUc_5;a?Oe5jp4CF(>NE+>_yYHcHTQZh&`pAb^I`bP3U?lvF|(WD28r_?fogJ2SD$Cv9nbJepg=3zuE!DQYNbKC%X-&U7TxBS?R zZre|^S+%TzyzWmmOm%=y^cJwAX4U_L_N!V6W!Z@RyP_h#TyF?#q9zw~;Qn z3mktr)+XCuq8e+43f^~)2b}LmLVZ-QfMCQUXq+Fw{|AwbXtd^tSeM0re^ij+9@c7J zI_>YYLJ_;Q$c-)X9o$AUDR!G%0n*K-H1*k2$zeyq(xd<6jF9xrmJg3=VXYdFrKut> zq>h9pGL!X_YlxeZfqD>iej9(sZ@lH@gEc>tGH|N4N7jyIR(DT6fA!|wJ}0-!G_B4) zzY<{?6&r!ditNsn!A+x^cVgojAExLQO`4{gU-!z_+YP^#7=M4fQngNW^m4@26#E<3 zKL|R*Mo2jhWa%itgfZ~u9L;1rCpTm*GWu_c-v{}L^~qrevDriH*fM|2Fc1-zmy6Zn zXMXbPe#7_OZf~pGI&{lUiYAUd>HN@3c=%R0<&6tX6N3 z|K>PLk=IyKo~IU&SRk#)^*m|f4HFOJgSm406GWk`-PD_ZqOVhgrHKwf5mZCu^ZZar8{fVo|5GljGOiSCijNRH>#yC$(4oa|Y+*bmH#S}jV+Of{#k868$`;og3Ve7#y2RGl2f zOAlZ9ydB$)mg|4cvcsiPb<9WcCX}Vs=Rhx~qV1q6#jHC5( zwCdOmYFD7hq!M=j%EO0s>SbP1quJBJ;B4HACr8yXITwN2KIS!I4>6&e*kvc*(;>%B zCw5{DZdU-}^$?3H1ACFC-f!0Qvi6!*V(aCQY`%lIv>$&_*I%w}Bl4`@GuagHt0L=* zw_Um<{`AtN@1MMM>0d8hl9yij=Xc{*Tu(0_q2J3o`Ni@nqAa)4shq9+1oYCd*Ecz0 zwaLsF1Hb@<9s6A~EZOb2NXvsOg1&}sV*CSMKFmUtEZoHd*noWZZrJOxE2~&6q3BCL7rJk z_S~meSDy*i^Y_L_x82vpk(TEMiWn+LE+(qj@a{<>TU~X`_2T3%@xJvlXH=)RzWyaE zh|k`WthgivXMcRF^pfPhB=O`qFYp%b+W6weO-q0E*PJ=i=}GIgXO&U*M$Z}#wzh*xBjV!vF*E!7C(_UrcLbgn96OIPBn=|1)$IlXI+YJ7`s~Q& zaG@sCyA8SOl}oJ5o>VQe(&EY@*|EEo)0GQk$KFYL?G2UtD(|j*sPd`Gf3JM2^3TE+ z9WfDCix-NQik}eoi~lS>EPh9PQG8uIBmRF;8o4X4k{3De_YwI{`Cj?k@=5te@~`CA zmlpo)^AzAYkk`Kg7viZH`X_7-#%)ew{L&3 zZ?k{Ney{y;`?u^rvcGJ9)&5)i8}_#~xiorBAJQB88hwNQF@1-ArM_RkT|cfrsz0tj zt^Z8_Fa0f}NQFga#cY~wGcXf#!MxDC+PvP}Z{BJiGLM*#n9rI&F<&=-WB#xCp0num zoWsru=W6F#=O*V)=M~NyoO_)Io%eq@A8>xddBXXO^CjocoxgIPah`Sl!TBfWyUxG4 zwi~#MB$AG~r`+q@3+{{Dm$|QU?{VMgzQuj3`*!zH_kHfi+^5|C=6==vTlbspKf3?N z{hnt5S?ajh?T!t$#j|e5?9Quc7Y1npjoi$oFC9TiS74Wc?8x*jqkH?~X`g>%hVc=* zW!-6mghxSl%!x(!P!*(a>chqq_vjn0LplZ0U<_aiGM)iKZ%UY_NEY2aIY3)->;QJS zyb!L*OVvEaX3B_<4qMvEyPof+UsqQS(bg@Lz_&+pgo)XB6qxDah4 zrYz_v(uML2A-&y6A7$hwW@j|Sz!*;6X!IwI(y^wYLskVW6FR$J%qxjZ3chAMA3f@# z95!?vq1Xsf&H9Kf?2`&C??TT6-2XHmO{rU0iHRkG6US4wo9AUXa4LVGyQooE%9@O) zbbN(PpKgJ5oQx6KPT~iH&94X(-`SmF%LaEuFyM3qb0}*VU{#P5;`lhu7e~d}aar~c zbW%56fIr}x$+SPnOm{eixlg}+Z2qH?=%~m?#n9BL9izOU?qHRELeDEvD3Gd8*YBL9 zqg`Dfj&c`Ykr#lfjs<`2l>yInI+{}R>9>JdBLarYuk#Ese$=ep>9B4<++3Z5F3P(A zft?KT&v=rjJ#kr^=n z@kQ7=@05d$g@w|iq3fqZfXY+zhIwHixQjmKI0tPm3*2i;O`m@bsgM2Lx*3nU!;B`B z8a4rg;ko@C(gIWB%Px%^=9GHK^NQd~RD+ll!)!=BH+>YP0GrflsK^)W(@2lV`Yjjh zhNamArsh&~Sn})?8r0LLA>y9yj%dEHd&9Gl@r7BJ3%@euOu0-%zd%guDzy@8sJy=k zip(?6QJ;ok%2R(tm-bBoa}M1+A%^sfoQA%ijru%M7-K|RV{eAod_3anG1RMah=~-Y z*=`>kP7SKlWRh!`b#xyCLpI-3Pa5P0ku=KY(=;ijCCWKW#S)CLU+ng|5GhxtMXYMh z%eb63MSj5wW)5V51zrx>JW6j^GU6eiK7o?~+>a8jG_QZ0SIcBN1qSZ4C9^Wf7JPuz z2+ie63*9ZoIcaMys5a??SG!jT#{B`a(VaV}qMd_8R*^QC*RjbpDZ9_bj=2T^iGXqA zlqdjrKvRgBqr0N=aqW*3ml{T&)y>T912bvn{v3eQSYJfHAg(MD=- z87ed$G^WE+>UFYw1o8qO;G{kxh#EAfye|ybU`Y3`=MVuj1yCWlA=*-s$}Ta$2pR^k zh`ThuvBazuJjS~;1ZV*8D@h1XF$Y|Hh#EiLrH6lx>DDxB0}@3V%)(#J4JP4)M^@WgFccF?T-NaFqu*txNmi|l;fcxENGTV z?~Z>E3soQ=E8oe7omK3R(su)cOk*Zu(_wkt?IYob1jAG}CYbpto0r`_ktR6EOi>At z<|pq0DrEruO0t5U(Va9j4a*3WN*afCOF1kgJZOS*%r(i_I>wU31EAYhq2r2t2vs;W z#2^`f8X+bS{Y(msrlLN~&4}h47$%UnIg5W-dOC@gI!-L6{RVZR(*-=sWDLfGtT7s7 zM>iagsQbC;l8~p~LI_L?2s(x@<+pxL`j?E9!BF>s`G^Mr6l^di`ht4v0(S+PW_Lm~ zqPNSCKVpL}DN~v-B9JmDemI!o9@LqF?U~%5oz%=O5&QHwxg>Ik!ODja8JJQg8sdM- z3{cuc)%Co?v^w13B3Y=9H7LW(8$*ardMfj9e@Mhfa$?t@>N&U(-9Z5m5CL#KskMkD z7!zp#0gUJtgq`XBV2JjRRfjB!-2ubSnX$Z2NXK8RMWMplPZ%L=+qU$&(n%tc#FDNC zSdbD3UufCBW!o1K`1=Y(AG?khSP?cc zg+rJ5*n*Xgs~JbZ)qqk!kfim#1V%x$390l@@A}Ol$q!2g?bc*Fma=?TtVVWdr`Y>uCGE(S5#8iJf@L>>I z3`boUBW1?>whX5L5Jo$9=sAuhRsi=Pcumhm;vmp7c+Z!5X=SpkWP~_naTg-6$zrrD zV;dh$x7_O#SKMZg$t|Jd6^5h1nS=C|R|1jrg{+r&97qhj5~tAz-;~kIijiKligp-H zLf94`#TK+K+lIS%p5p!I@(h2C;ZyT3)g03V_u*&($sa8#evhxW`D=^Y@;)IR7oTJ_ zNIb;sBTpzR5#sH1s+H7?6I{WejQqp*`mETH>OJ)5ix8PiGtU4O%J!+dfI*oE(WufF z+`&4UW?3&5;&Vd0M@YJkLnF8V5IRFo{VWTGr+tZWIyw5D>0La* zqa;DSN|fV_?Q~2N@@h36^r#RImE8sv@jaRHsat30kCT#jYHe=5vemn#+@Cy#m48D#W>LVUskf+$WD3^RYYWSC=}oc?yT{0$5^ z8vSMQO)mFLcUfo3#=L<>KZPC|MnsWMa_8u%MML=uC@+9MTaH!s0T*F%cZIkF5~BP5 zJbhf4^NU5D;t>ZKGvJVAYxzms&$v9lLK4ZCOJ7 z%o#-(`9>1v%vyia!y>zj&M1fgaY>Y5Ghz=1FcMP!9nt-r@i65fobZ>+c?N$Wtn>9k)VR^qB=I?=El)*& zMN;}{5E~0WBQ`neM2HU^0N|*Xi89mW9q6nyKZmMpP%cj5VwNr1p9Eq(C@VcWmRBV15ZebdlhDZ=*c1xYg`L4RYdPD z#?%W^(kg!uP?$3%J6+)u9R|j8--qCrU!9YEwa1 zYdfQ_5Lnzn%1DSvCL&57Ty5I{rpB|?ib!ZKqlkYri@^wHDwPSR$nX?`%4I5`KS`l3 zGtMuWl~TJ(yQa+aQDq>JC1NE^iTez~j!5%cOAE+^B5g)zI&nyXUU-cpAYz~~af_51 zWUZ3W&_UA3aJvE`hz8X~I!l&=2&nV!O4Y5!)F|TU;RcZ?Q-ThHv<}(pXMvkAFIukj z=pKI-O9CUSD`pKG9M=6v1>givIaMpJxx}(`%Ie}mU^ykZn=p>7l<2hzb~VxjGEi}7 zka9#sOjHCyRxXc?4@pnM8_@W>bwSh^Av(%gGV2;u`$)>_CJ~Ys1C(1vL~;roW?Z5;`X9<5Ue)KgD@h=Zit9tiQP%dH-U@1Bq#>QlN)Fnf9ARX@EsAY)1q#IHXq~ma# zSs~e)#DR@GO0GBH_$W$c`6x{X;5_0J<7@3}sp5!+N;ud^0*|=1N@9d-3z2A`8%URq zR;z5AA#;TEqcRb~xgB9z!0rTx!@`4*s2sYQNl=7Ex|kO(vI9SmRSF~kUUsm|SUt_zi6j?%k{&`uu#-{qOP3mf8gRYDPBmVE9i)gOea=lEI8^kc2aR= zNoou>DNLymX);k6lVpYsPGK#^Go!Kh90V*?N~;>P>_`OGDg=R6@ks+kQ45zR!vXs{ z0FpP6F8v5pClnB{NMKZJ(l|7lkZYx%0E2@=WwC|sLk&2r-AUpC@|JEy5=yMq9luHw ze_UsS0IcL1RFQ!h$gT&On#Q-;o+rk!RoPy)ok4sI0ZGGQ=^A4R;K3j`tv!e2s0*(N zT#mA#B!`FtJ?L$}5yM&viCln7q5=}_wiT2AXY8e=Dp8Hiu7x2J#1d}l#Kquh)Yzo9 zC3G@a3c}hz*Pxh{qUj6(#3+b25Rr)Ve+3^E48Y}@`Iq+fzf24uss|U z2Ip~8>Uf^vsdRvDMSb^FKvp4fF2@lI0R|)~;#h2jveO|IBB{Ar7yE=ZM$l%lF47vH zrybJP4kNe_ebO_dn4}6u6q*tSZUB%RYPO98QwcdwJQ@fmaAL&Ipwa+QEmSzte^oX7 z1R8mpF-zb(8Q7aP`NP!m1xHZ#Igrq{JQ5LB1QQmBCb(9!)x;2wm@}KButA0F9-_1! z0MlSeL#YZrkxW}F5W31O^907z2H+-~-Bqy$7uA7DE=zl@w3PS#hy9P`3%uPqkRZtv zZ()8C^OT4kLyrkjoUZI!gwZ0Ce@NNvl)-!>4NTo5Ri#T062vEX1%Pi3m`@OxVm--d zla@GeC@_Cyax%gpJH0>rZyvjFNd9)kL0q5cR_Xt^o#iD`0!I@dZ3H=+U5;xgQG&|C z0P_ft>5xMm2Gfc7=Bv)%Emog%j1HW-b5+sV=>7D1@2u<9PpqX*5-gs4e_mQEPMzM^ zw$3%&R<%PG+?!^f7pJbc;u$}2P}D%B%PX7P%gf#NPE_~eg+?vX+IDKw-GzRzyw)49 z!9`B@Yw$g%hLz)$8@LkoFJS-e0Q4jl^MIYG1Ran_&?vzK4x+ja(&&aICIfx3pF@NJ z;85l{R(!dk%mpXQ(B1JVf5C;&aAaEors6ViK_(a1i+G8Y2$4#lYwNj_tb_^(tkNuX z7p0ff+EsvA$#ApS?iD|MI9e<=Z)^rhZNomQpFNn~s&D5`HvIRo2z+7)XE+$q{C9Sl8nzxwSDE(y7J?%a39)#B>!o;&xZ&wpM8_uv2hugLBD@1K1_{7B^> zX5)xDdO2oeUJq_8deu;_1!i45Ft1sf;kt?m_*ZO;K&xAQDC|f%&O)CyR2i-C1OGl;yh0W zn;pnqLd-k>D>$2rqbcbslt5rmX)ODmQhQ>AMbwV&)py6l#={bEk&zOyzB-wsN7J$Y z&sW@}=|CNcfBbK3qQ=UWznN||&#VS27&K9;Vs+bXEDQN8keZa3ePkKl9ElrOr;L=Y zP$d%!YE6v-JS2yD3RVul+|??|x49A-HbOQNh~v}Wdh!Wq@ZWjzcOlW}@AC5#<>x1b z{02$22QPT>u@V`I6t14d3=r=Dm3_=w%T?l4YU|BGe-rWQWdZbcz*3MidxuIG#rCeT z-LO@CW2Z@ske*MWOK#g%;UM3J=F|5IF*|;Y`nDp)atGj8beFYd&gEGy`13Z|J(W4m z&Jndz*{PhZJY0FS^6tv7RDQMcL7=W8#C20}0b7H)s?KXTm6fE_bchHWBCmNw&JX|g zMx3%Yed#QefGN;cq;Ibw*VH2`3zdz@kk#Q`x2n(~B{x{^c3dL2n&ra=wgVH{&RzoO z3pSX z89*7l8XOwl9cCT69!MUD9;6@KAv7fhB|s%wC3+>sCLAW3Com^!C!#0NDJCigD$XlZ zELtpRk}z5@gfSj6GBdn1PBfx7hBy*9zBvXth&kjsbUKufJc6#qU8w4YX6#~q_mVX~Eclj2c zhhbnCc+2c)b~cu?{~wGa2vn%iV2%ZjvBU{3;396oCESRca2Yq_7Tk*4a69h6owy5k z;~w0L`*1%Vz=L=Q591L$ipTIcp1_lM3Qyx1tne(J!+-O50ax%MUc$?G1+U^YypA{U zCf>r^cn9y|J-m+(a240^AwI&#_ynKgGklIO@Fl*&*Z2nC;yZkgAMhi7!q4~xzv4Ii zjz91x{=yo6L!yO(2BAZb0R|h4u$bWB5pW$5j5Mod2$qE8sg_wAU$?R)Tep5kQM7F5 zYQ=+$0e`Aea-_v+Scf58Rs*TA_4`$J|E8oD{~c9o!~0rUug0bFR(F|=ca8F{GrdqD z2*q6H7WzoHb4{JhHeJ#bA}N{5-Iem8(WRf_1=1$@c-~AKZpfOwi5Jh7HLGYs5@e^E zV)U^gw#KD-C%2|FHC+KfvFf}_%ig5**}f_1kbm2w-izK}Y5FL&rPIY&uKSo>s`_lh zVvuUI()HCKCp#Y`k7R8#Q1oLK1MRCJm2=ZOA4#7WYcr=P3*OpHvZuZ7qiv;lgxM=K37o!ezI~YUJ9h!bSw$Re_>C4uemg2OmT+b{?YN zkV+!tz6m)5N=-PVq2N4ICz4dDiN0_RRm|<71WrqqmbfcMQN^;@%WbMzNh=#B8P%|0 zO3ApMYaWV*RdH!*xbR4ahC?ishSQ6hsc&ef^5<)?aUG Date: Thu, 25 May 2017 22:57:35 +0200 Subject: [PATCH 0173/1347] [seti] add information_for_contributors --- extensions/theme-seti/build/update-icon-theme.js | 8 ++++++++ extensions/theme-seti/icons/vs-seti-icon-theme.json | 8 ++++++++ 2 files changed, 16 insertions(+) diff --git a/extensions/theme-seti/build/update-icon-theme.js b/extensions/theme-seti/build/update-icon-theme.js index 7f44c3ac245..a2a2bbd840c 100644 --- a/extensions/theme-seti/build/update-icon-theme.js +++ b/extensions/theme-seti/build/update-icon-theme.js @@ -212,6 +212,14 @@ exports.update = function () { } var res = { + information_for_contributors: [ + 'This file has been generated from data in https://github.com/jesseweed/seti-ui:', + '- icon definitions: styles/_fonts/seti.less', + '- icon colors: styles/ui-variables.less', + '- file associations: styles/icons/mapping.less', + 'If you want to provide a fix or improvement, please create a pull request against the jesseweed/seti-ui repository.', + 'Once accepted there, we are happy to receive an update request.', + ], fonts: [{ id: "seti", src: [{ "path": "./seti.woff", "format": "woff" }], diff --git a/extensions/theme-seti/icons/vs-seti-icon-theme.json b/extensions/theme-seti/icons/vs-seti-icon-theme.json index b26e557e5d3..46e757af3f6 100644 --- a/extensions/theme-seti/icons/vs-seti-icon-theme.json +++ b/extensions/theme-seti/icons/vs-seti-icon-theme.json @@ -1,4 +1,12 @@ { + "information_for_contributors": [ + "This file has been generated from data in https://github.com/jesseweed/seti-ui:", + "- icon definitions: styles/_fonts/seti.less", + "- icon colors: styles/ui-variables.less", + "- file associations: styles/icons/mapping.less", + "If you want to provide a fix or improvement, please create a pull request against the jesseweed/seti-ui repository.", + "Once accepted there, we are happy to receive an update request." + ], "fonts": [ { "id": "seti", -- GitLab From acadd61cc39d97b30642cf05bc7d475dfbd35225 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Thu, 25 May 2017 14:32:00 -0700 Subject: [PATCH 0174/1347] Comments --- src/vs/editor/contrib/suggest/browser/suggestWidget.ts | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index c27e0dbaa95..c5559659a7f 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -953,11 +953,14 @@ export class SuggestWidget implements IContentWidget, IDelegate if (hasClass(this.element, 'docs-side')) { if (this.details.element.offsetHeight > this.listElement.offsetHeight) { + + // Fix for #26416 + // Docs is bigger than list and widget is above cursor, apply margin-top so that list appears right above cursor if (hasClass(this.element, 'widget-above')) { - // Docs is bigger than list and widget is above cursor, apply margin-top so that list appears right above cursor this.listElement.style.marginTop = `${this.details.element.offsetHeight - this.listElement.offsetHeight}px`; } + // Fix for #26244 if (hasClass(this.element, 'list-right')) { addClass(this.listElement, 'empty-left-border'); removeClass(this.listElement, 'empty-right-border'); @@ -970,6 +973,7 @@ export class SuggestWidget implements IContentWidget, IDelegate removeClass(this.details.element, 'empty-right-border'); return; } else { + // Fix for #26244 if (hasClass(this.element, 'list-right')) { addClass(this.details.element, 'empty-right-border'); removeClass(this.details.element, 'empty-left-border'); @@ -983,6 +987,7 @@ export class SuggestWidget implements IContentWidget, IDelegate } } + // Reset margin-top that was set as Fix for #26416 this.listElement.style.marginTop = '0px'; } -- GitLab From 2b7cf864395e501b95f285e3a3449e204e07eb3d Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 25 May 2017 14:31:52 -0700 Subject: [PATCH 0175/1347] Extract merge-conflict colors as workbench colors (#27299) --- .../merge-conflict/src/mergeDecorator.ts | 28 ++++++++----------- src/vs/platform/theme/common/colorRegistry.ts | 18 ++++++++++++ 2 files changed, 29 insertions(+), 17 deletions(-) diff --git a/extensions/merge-conflict/src/mergeDecorator.ts b/extensions/merge-conflict/src/mergeDecorator.ts index f6d0135aad9..39888f727e6 100644 --- a/extensions/merge-conflict/src/mergeDecorator.ts +++ b/extensions/merge-conflict/src/mergeDecorator.ts @@ -13,9 +13,6 @@ export default class MergeDectorator implements vscode.Disposable { private decorationUsesWholeLine: boolean = true; // Useful for debugging, set to false to see exact match ranges - // TODO: Move to config? - private currentColorRgb = `32,200,94`; - private incomingColorRgb = `24,134,255`; private config: interfaces.IExtensionConfiguration; private tracker: interfaces.IDocumentMergeConflictTracker; @@ -69,21 +66,19 @@ export default class MergeDectorator implements vscode.Disposable { // Create decorators if (config.enableDecorations || config.enableEditorOverview) { this.decorations['current.content'] = vscode.window.createTextEditorDecorationType( - this.generateBlockRenderOptions(this.currentColorRgb, config) + this.generateBlockRenderOptions('merge.currentContentBackground', 'overviewRuler.currentContentForeground', config) ); this.decorations['incoming.content'] = vscode.window.createTextEditorDecorationType( - this.generateBlockRenderOptions(this.incomingColorRgb, config) + this.generateBlockRenderOptions('merge.incomingContentBackground', 'overviewRuler.incomingContentForeground', config) ); } if (config.enableDecorations) { this.decorations['current.header'] = vscode.window.createTextEditorDecorationType({ - // backgroundColor: 'rgba(255, 0, 0, 0.01)', - // border: '2px solid red', isWholeLine: this.decorationUsesWholeLine, - backgroundColor: `rgba(${this.currentColorRgb}, 1.0)`, - color: 'white', + backgroundColor: new vscode.ThemeColor('merge.currentHeaderBackground'), + color: new vscode.ThemeColor('editor.foreground'), after: { contentText: ' ' + localize('currentChange', '(Current change)'), color: 'rgba(0, 0, 0, 0.7)' @@ -91,14 +86,13 @@ export default class MergeDectorator implements vscode.Disposable { }); this.decorations['splitter'] = vscode.window.createTextEditorDecorationType({ - backgroundColor: 'rgba(0, 0, 0, 0.25)', - color: 'white', + color: new vscode.ThemeColor('editor.foreground'), isWholeLine: this.decorationUsesWholeLine, }); this.decorations['incoming.header'] = vscode.window.createTextEditorDecorationType({ - backgroundColor: `rgba(${this.incomingColorRgb}, 1.0)`, - color: 'white', + backgroundColor: new vscode.ThemeColor('merge.incomingHeaderBackground'), + color: new vscode.ThemeColor('editor.foreground'), isWholeLine: this.decorationUsesWholeLine, after: { contentText: ' ' + localize('incomingChange', '(Incoming change)'), @@ -118,17 +112,17 @@ export default class MergeDectorator implements vscode.Disposable { this.decorations = {}; } - private generateBlockRenderOptions(color: string, config: interfaces.IExtensionConfiguration): vscode.DecorationRenderOptions { + private generateBlockRenderOptions(backgroundColor: string, overviewRulerColor: string, config: interfaces.IExtensionConfiguration): vscode.DecorationRenderOptions { - let renderOptions: any = {}; + let renderOptions: vscode.DecorationRenderOptions = {}; if (config.enableDecorations) { - renderOptions.backgroundColor = `rgba(${color}, 0.2)`; + renderOptions.backgroundColor = new vscode.ThemeColor(backgroundColor); renderOptions.isWholeLine = this.decorationUsesWholeLine; } if (config.enableEditorOverview) { - renderOptions.overviewRulerColor = `rgba(${color}, 0.5)`; + renderOptions.overviewRulerColor = new vscode.ThemeColor(overviewRulerColor); renderOptions.overviewRulerLane = vscode.OverviewRulerLane.Full; } diff --git a/src/vs/platform/theme/common/colorRegistry.ts b/src/vs/platform/theme/common/colorRegistry.ts index bc3da9fed16..b908d663df3 100644 --- a/src/vs/platform/theme/common/colorRegistry.ts +++ b/src/vs/platform/theme/common/colorRegistry.ts @@ -254,6 +254,24 @@ export const diffRemoved = registerColor('diffEditor.removedTextBackground', { d export const diffInsertedOutline = registerColor('diffEditor.insertedTextBorder', { dark: null, light: null, hc: '#33ff2eff' }, nls.localize('diffEditorInsertedOutline', 'Outline color for the text that got inserted.')); export const diffRemovedOutline = registerColor('diffEditor.removedTextBorder', { dark: null, light: null, hc: '#FF008F' }, nls.localize('diffEditorRemovedOutline', 'Outline color for text that got removed.')); +/** + * Merge-conflict colors + */ + +const headerTransparency = 1; +const currentBaseColor = Color.fromHex('#20C85E').transparent(headerTransparency); +const incomingBaseColor = Color.fromHex('#1886FF').transparent(headerTransparency); +const contentTransparency = 0.2; +const rulerTransparency = 0.5; + +export const mergeCurrentHeaderBackground = registerColor('merge.currentHeaderBackground', { dark: currentBaseColor, light: currentBaseColor, hc: currentBaseColor }, nls.localize('mergeCurrentHeaderBackground', 'Current header background in inline merge-conflict.')); +export const mergeCurrentContentBackground = registerColor('merge.currentContentBackground', { dark: transparent(mergeCurrentHeaderBackground, contentTransparency), light: transparent(mergeCurrentHeaderBackground, contentTransparency), hc: transparent(mergeCurrentHeaderBackground, contentTransparency) }, nls.localize('mergeCurrentContentBackground', 'Current content background in inline merge-conflict.')); +export const mergeIncomingHeaderBackground = registerColor('merge.incomingHeaderBackground', { dark: incomingBaseColor, light: incomingBaseColor, hc: incomingBaseColor }, nls.localize('mergeIncomingHeaderBackground', 'Incoming header background in inline merge-conflict.')); +export const mergeIncomingContentBackground = registerColor('merge.incomingContentBackground', { dark: transparent(mergeIncomingHeaderBackground, contentTransparency), light: transparent(mergeIncomingHeaderBackground, contentTransparency), hc: transparent(mergeIncomingHeaderBackground, contentTransparency) }, nls.localize('mergeIncomingContentBackground', 'Incoming content background in inline merge-conflict.')); + +export const overviewRulerCurrentContentForeground = registerColor('overviewRuler.currentContentForeground', { dark: transparent(mergeCurrentHeaderBackground, rulerTransparency), light: transparent(mergeCurrentHeaderBackground, rulerTransparency), hc: transparent(mergeCurrentHeaderBackground, rulerTransparency) }, nls.localize('overviewRulerCurrentContentForeground', 'Current overview ruler foreground for inline merge-conflict.')); +export const overviewRulerIncomingContentForeground = registerColor('overviewRuler.incomingContentForeground', { dark: transparent(mergeIncomingHeaderBackground, rulerTransparency), light: transparent(mergeIncomingHeaderBackground, rulerTransparency), hc: transparent(mergeIncomingHeaderBackground, rulerTransparency) }, nls.localize('overviewRulerIncomingContentForeground', 'Incoming overview ruler foreground for inline merge-conflict.')); + // ----- color functions export function darken(colorValue: ColorValue, factor: number): ColorFunction { -- GitLab From 5860e3dcad744cde8156f55ad8726d862f9c5498 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 25 May 2017 14:40:05 -0700 Subject: [PATCH 0176/1347] Tune merge-conflict colors (#27299) --- src/vs/platform/theme/common/colorRegistry.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/vs/platform/theme/common/colorRegistry.ts b/src/vs/platform/theme/common/colorRegistry.ts index b908d663df3..5f3a474f034 100644 --- a/src/vs/platform/theme/common/colorRegistry.ts +++ b/src/vs/platform/theme/common/colorRegistry.ts @@ -258,11 +258,11 @@ export const diffRemovedOutline = registerColor('diffEditor.removedTextBorder', * Merge-conflict colors */ -const headerTransparency = 1; -const currentBaseColor = Color.fromHex('#20C85E').transparent(headerTransparency); -const incomingBaseColor = Color.fromHex('#1886FF').transparent(headerTransparency); -const contentTransparency = 0.2; -const rulerTransparency = 0.5; +const headerTransparency = 0.5; +const currentBaseColor = Color.fromHex('#40C8AE').transparent(headerTransparency); +const incomingBaseColor = Color.fromHex('#40A6FF').transparent(headerTransparency); +const contentTransparency = 0.4; +const rulerTransparency = 1; export const mergeCurrentHeaderBackground = registerColor('merge.currentHeaderBackground', { dark: currentBaseColor, light: currentBaseColor, hc: currentBaseColor }, nls.localize('mergeCurrentHeaderBackground', 'Current header background in inline merge-conflict.')); export const mergeCurrentContentBackground = registerColor('merge.currentContentBackground', { dark: transparent(mergeCurrentHeaderBackground, contentTransparency), light: transparent(mergeCurrentHeaderBackground, contentTransparency), hc: transparent(mergeCurrentHeaderBackground, contentTransparency) }, nls.localize('mergeCurrentContentBackground', 'Current content background in inline merge-conflict.')); -- GitLab From 64d676ccf7d0062e18ca6bfa113bef8efbd6d58f Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Thu, 25 May 2017 15:18:05 -0700 Subject: [PATCH 0177/1347] Add TSC Task Provider (#27093) * extract standardLanguageDescriptions to constant * Remove client variable * Move VersionStatus into a class * Add TSC Task Provider Fixes #26079 Adds a task provider for building typescript projects. * Make ts loading lazy --- extensions/typescript/package.json | 5 +- .../src/features/jsDocCompletionProvider.ts | 6 +- .../typescript/src/features/taskProvider.ts | 110 ++++++++++++++++++ extensions/typescript/src/typescriptMain.ts | 109 +++++++++++------ .../typescript/src/typescriptServiceClient.ts | 10 +- .../typescript/src/utils/versionStatus.ts | 69 ++++++----- src/vs/workbench/api/node/extHostTask.ts | 2 +- 7 files changed, 235 insertions(+), 76 deletions(-) create mode 100644 extensions/typescript/src/features/taskProvider.ts diff --git a/extensions/typescript/package.json b/extensions/typescript/package.json index 461cb773a4d..b039fac9631 100644 --- a/extensions/typescript/package.json +++ b/extensions/typescript/package.json @@ -34,7 +34,10 @@ "onCommand:typescript.selectTypeScriptVersion", "onCommand:javascript.goToProjectConfig", "onCommand:typescript.goToProjectConfig", - "onCommand:typescript.openTsServerLog" + "onCommand:typescript.openTsServerLog", + "onCommand:workbench.action.tasks.runTask", + "onCommand:workbench.action.tasks.build", + "onCommand:workbench.action.tasks.test" ], "main": "./out/typescriptMain", "contributes": { diff --git a/extensions/typescript/src/features/jsDocCompletionProvider.ts b/extensions/typescript/src/features/jsDocCompletionProvider.ts index da02e942bfc..502cf89c42c 100644 --- a/extensions/typescript/src/features/jsDocCompletionProvider.ts +++ b/extensions/typescript/src/features/jsDocCompletionProvider.ts @@ -88,7 +88,7 @@ export class TryCompleteJsDocCommand { static COMMAND_NAME = '_typeScript.tryCompleteJsDoc'; constructor( - private client: ITypescriptServiceClient + private lazyClient: () => ITypescriptServiceClient ) { } /** @@ -96,7 +96,7 @@ export class TryCompleteJsDocCommand { * if possible, otherwise falling back to a default comment format. */ public tryCompleteJsDoc(resource: Uri, start: Position, shouldGetJSDocFromTSServer: boolean): Thenable { - const file = this.client.normalizePath(resource); + const file = this.lazyClient().normalizePath(resource); if (!file) { return Promise.resolve(false); } @@ -126,7 +126,7 @@ export class TryCompleteJsDocCommand { offset: position.character + 1 }; return Promise.race([ - this.client.execute('docCommentTemplate', args), + this.lazyClient().execute('docCommentTemplate', args), new Promise((_, reject) => setTimeout(reject, 250)) ]).then((res: DocCommandTemplateResponse) => { if (!res || !res.body) { diff --git a/extensions/typescript/src/features/taskProvider.ts b/extensions/typescript/src/features/taskProvider.ts new file mode 100644 index 00000000000..76528021983 --- /dev/null +++ b/extensions/typescript/src/features/taskProvider.ts @@ -0,0 +1,110 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +'use strict'; + +import * as fs from 'fs'; +import * as path from 'path'; +import * as vscode from 'vscode'; + +import * as Proto from '../protocol'; +import TypeScriptServiceClient from '../typescriptServiceClient'; + + +const exists = (file: string): Promise => + new Promise((resolve, _reject) => { + fs.exists(file, (value: boolean) => { + resolve(value); + }); + }); + +export default class TypeScriptTaskProvider implements vscode.TaskProvider { + + public constructor( + private readonly lazyClient: () => TypeScriptServiceClient + ) { } + + async provideTasks(token: vscode.CancellationToken): Promise { + const rootPath = vscode.workspace.rootPath; + if (!rootPath) { + return []; + } + + const projects = (await this.getConfigForActiveFile(token)).concat(await this.getConfigsForWorkspace()); + const command = await this.getCommand(); + + return projects + .filter((x, i) => projects.indexOf(x) === i) + .map(configFile => { + const configFileName = path.relative(rootPath, configFile); + const buildTask = new vscode.ShellTask(`tsc: build ${configFileName}`, `${command} -p ${configFile}`, '$tsc'); + buildTask.group = vscode.TaskGroup.Build; + return buildTask; + }); + } + + + private async getConfigForActiveFile(token: vscode.CancellationToken): Promise { + const editor = vscode.window.activeTextEditor; + if (editor) { + if (path.basename(editor.document.fileName).match(/^tsconfig\.(.\.)?json$/)) { + return [editor.document.fileName]; + } + } + + const file = this.getActiveTypeScriptFile(); + if (!file) { + return []; + } + + const res: Proto.ProjectInfoResponse = await this.lazyClient().execute( + 'projectInfo', + { file, needFileNameList: false } as protocol.ProjectInfoRequestArgs, + token); + + if (!res || !res.body) { + return []; + } + + const { configFileName } = res.body; + if (configFileName && configFileName.indexOf('/dev/null/') !== 0) { + return [configFileName]; + } + return []; + } + + private async getConfigsForWorkspace(): Promise { + if (!vscode.workspace.rootPath) { + return []; + } + const rootTsConfig = path.join(vscode.workspace.rootPath, 'tsconfig.json'); + if (!await exists(rootTsConfig)) { + return []; + } + return [rootTsConfig]; + } + + private async getCommand(): Promise { + const platform = process.platform; + if (platform === 'win32' && await exists(path.join(vscode.workspace.rootPath!, 'node_modules', '.bin', 'tsc.cmd'))) { + return path.join('.', 'node_modules', '.bin', 'tsc.cmd'); + } else if ((platform === 'linux' || platform === 'darwin') && await exists(path.join(vscode.workspace.rootPath!, 'node_modules', '.bin', 'tsc'))) { + return path.join('.', 'node_modules', '.bin', 'tsc'); + } else { + return 'tsc'; + } + } + + private getActiveTypeScriptFile(): string | null { + const editor = vscode.window.activeTextEditor; + if (editor) { + const document = editor.document; + if (document && (document.languageId === 'typescript' || document.languageId === 'typescriptreact')) { + return this.lazyClient().normalizePath(document.uri); + } + } + return null; + } +} \ No newline at end of file diff --git a/extensions/typescript/src/typescriptMain.ts b/extensions/typescript/src/typescriptMain.ts index 9949d0db9d2..07a666936b9 100644 --- a/extensions/typescript/src/typescriptMain.ts +++ b/extensions/typescript/src/typescriptMain.ts @@ -41,13 +41,14 @@ import CodeActionProvider from './features/codeActionProvider'; import ReferenceCodeLensProvider from './features/referencesCodeLensProvider'; import { JsDocCompletionProvider, TryCompleteJsDocCommand } from './features/jsDocCompletionProvider'; import { DirectiveCommentCompletionProvider } from './features/directiveCommentCompletionProvider'; +import TypeScriptTaskProvider from './features/taskProvider'; import ImplementationCodeLensProvider from './features/implementationsCodeLensProvider'; import * as BuildStatus from './utils/buildStatus'; import * as ProjectStatus from './utils/projectStatus'; import TypingsStatus, { AtaProgressReporter } from './utils/typingsStatus'; -import * as VersionStatus from './utils/versionStatus'; +import VersionStatus from './utils/versionStatus'; import { getContributedTypeScriptServerPlugins, TypeScriptServerPlugin } from "./utils/plugins"; interface LanguageDescription { @@ -67,72 +68,100 @@ interface ProjectConfigMessageItem extends MessageItem { id: ProjectConfigAction; } +const MODE_ID_TS = 'typescript'; +const MODE_ID_TSX = 'typescriptreact'; +const MODE_ID_JS = 'javascript'; +const MODE_ID_JSX = 'javascriptreact'; + +const standardLanguageDescriptions: LanguageDescription[] = [ + { + id: 'typescript', + diagnosticSource: 'ts', + modeIds: [MODE_ID_TS, MODE_ID_TSX], + configFile: 'tsconfig.json' + }, { + id: 'javascript', + diagnosticSource: 'js', + modeIds: [MODE_ID_JS, MODE_ID_JSX], + configFile: 'jsconfig.json' + } +]; export function activate(context: ExtensionContext): void { - const MODE_ID_TS = 'typescript'; - const MODE_ID_TSX = 'typescriptreact'; - const MODE_ID_JS = 'javascript'; - const MODE_ID_JSX = 'javascriptreact'; - const plugins = getContributedTypeScriptServerPlugins(); - const clientHost = new TypeScriptServiceClientHost([ - { - id: 'typescript', - diagnosticSource: 'ts', - modeIds: [MODE_ID_TS, MODE_ID_TSX], - configFile: 'tsconfig.json' - }, - { - id: 'javascript', - diagnosticSource: 'js', - modeIds: [MODE_ID_JS, MODE_ID_JSX], - configFile: 'jsconfig.json' - } - ], context.storagePath, context.globalState, context.workspaceState, plugins); - context.subscriptions.push(clientHost); - const client = clientHost.serviceClient; + const lazyClientHost = (() => { + let clientHost: TypeScriptServiceClientHost | undefined; + return () => { + if (!clientHost) { + clientHost = new TypeScriptServiceClientHost(standardLanguageDescriptions, context.storagePath, context.globalState, context.workspaceState, plugins); + context.subscriptions.push(clientHost); + + const host = clientHost; + clientHost.serviceClient.onReady().then(() => { + context.subscriptions.push(ProjectStatus.create(host.serviceClient, + path => new Promise(resolve => setTimeout(() => resolve(host.handles(path)), 750)), + context.workspaceState)); + }, () => { + // Nothing to do here. The client did show a message; + }); + } + return clientHost; + }; + })(); + context.subscriptions.push(commands.registerCommand('typescript.reloadProjects', () => { - clientHost.reloadProjects(); + lazyClientHost().reloadProjects(); })); context.subscriptions.push(commands.registerCommand('javascript.reloadProjects', () => { - clientHost.reloadProjects(); + lazyClientHost().reloadProjects(); })); context.subscriptions.push(commands.registerCommand('typescript.selectTypeScriptVersion', () => { - client.onVersionStatusClicked(); + lazyClientHost().serviceClient.onVersionStatusClicked(); })); context.subscriptions.push(commands.registerCommand('typescript.openTsServerLog', () => { - client.openTsServerLogFile(); + lazyClientHost().serviceClient.openTsServerLogFile(); })); context.subscriptions.push(commands.registerCommand('typescript.restartTsServer', () => { - client.restartTsServer(); + lazyClientHost().serviceClient.restartTsServer(); })); + context.subscriptions.push(workspace.registerTaskProvider(new TypeScriptTaskProvider(() => lazyClientHost().serviceClient))); + const goToProjectConfig = (isTypeScript: boolean) => { const editor = window.activeTextEditor; if (editor) { - clientHost.goToProjectConfig(isTypeScript, editor.document.uri); + lazyClientHost().goToProjectConfig(isTypeScript, editor.document.uri); } }; context.subscriptions.push(commands.registerCommand('typescript.goToProjectConfig', goToProjectConfig.bind(null, true))); context.subscriptions.push(commands.registerCommand('javascript.goToProjectConfig', goToProjectConfig.bind(null, false))); - const jsDocCompletionCommand = new TryCompleteJsDocCommand(client); + const jsDocCompletionCommand = new TryCompleteJsDocCommand(() => lazyClientHost().serviceClient); context.subscriptions.push(commands.registerCommand(TryCompleteJsDocCommand.COMMAND_NAME, jsDocCompletionCommand.tryCompleteJsDoc, jsDocCompletionCommand)); - window.onDidChangeActiveTextEditor(VersionStatus.showHideStatus, null, context.subscriptions); - client.onReady().then(() => { - context.subscriptions.push(ProjectStatus.create(client, - path => new Promise(resolve => setTimeout(() => resolve(clientHost.handles(path)), 750)), - context.workspaceState)); - }, () => { - // Nothing to do here. The client did show a message; - }); + const supportedLanguage = [].concat.apply([], standardLanguageDescriptions.map(x => x.modeIds).concat(plugins.map(x => x.languages))); + function didOpenTextDocument(textDocument: TextDocument): boolean { + if (supportedLanguage.indexOf(textDocument.languageId) >= 0) { + openListener.dispose(); + // Force activation + void lazyClientHost(); + return true; + } + return false; + }; + const openListener = workspace.onDidOpenTextDocument(didOpenTextDocument); + for (let textDocument of workspace.textDocuments) { + if (didOpenTextDocument(textDocument)) { + break; + } + } + BuildStatus.update({ queueLength: 0 }); } @@ -423,6 +452,7 @@ class TypeScriptServiceClientHost implements ITypescriptServiceClientHost { private languages: LanguageProvider[] = []; private languagePerId: ObjectMap; private readonly disposables: Disposable[] = []; + private readonly versionStatus: VersionStatus; constructor( descriptions: LanguageDescription[], @@ -446,7 +476,10 @@ class TypeScriptServiceClientHost implements ITypescriptServiceClientHost { configFileWatcher.onDidDelete(handleProjectCreateOrDelete, this, this.disposables); configFileWatcher.onDidChange(handleProjectChange, this, this.disposables); - this.client = new TypeScriptServiceClient(this, storagePath, globalState, workspaceState, plugins, this.disposables); + this.versionStatus = new VersionStatus(); + this.disposables.push(this.versionStatus); + + this.client = new TypeScriptServiceClient(this, storagePath, globalState, workspaceState, this.versionStatus, plugins, this.disposables); this.languagePerId = Object.create(null); for (const description of descriptions) { const manager = new LanguageProvider(this.client, description); diff --git a/extensions/typescript/src/typescriptServiceClient.ts b/extensions/typescript/src/typescriptServiceClient.ts index cf2b7c3be6f..5e22350feb0 100644 --- a/extensions/typescript/src/typescriptServiceClient.ts +++ b/extensions/typescript/src/typescriptServiceClient.ts @@ -18,7 +18,7 @@ import { ITypescriptServiceClient, ITypescriptServiceClientHost, API } from './t import { TypeScriptServerPlugin } from './utils/plugins'; import Logger from './utils/logger'; -import * as VersionStatus from './utils/versionStatus'; +import VersionStatus from './utils/versionStatus'; import * as is from './utils/is'; import * as nls from 'vscode-nls'; @@ -141,7 +141,9 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient host: ITypescriptServiceClientHost, storagePath: string | undefined, globalState: Memento, - private workspaceState: Memento, + private readonly workspaceState: Memento, + private readonly versionStatus: VersionStatus, + private plugins: TypeScriptServerPlugin[], disposables: Disposable[] ) { @@ -404,8 +406,8 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient const label = version || localize('versionNumber.custom', 'custom'); const tooltip = modulePath; this.modulePath = modulePath; - VersionStatus.showHideStatus(); - VersionStatus.setInfo(label, tooltip); + this.versionStatus.showHideStatus(); + this.versionStatus.setInfo(label, tooltip); // This is backwards compatibility code to move the setting from the local // store into the workspace setting file. diff --git a/extensions/typescript/src/utils/versionStatus.ts b/extensions/typescript/src/utils/versionStatus.ts index e92b87d0f24..21f3a1c34f1 100644 --- a/extensions/typescript/src/utils/versionStatus.ts +++ b/extensions/typescript/src/utils/versionStatus.ts @@ -3,42 +3,53 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import vscode = require('vscode'); +import * as vscode from 'vscode'; -const versionBarEntry = vscode.window.createStatusBarItem(vscode.StatusBarAlignment.Right, Number.MIN_VALUE); -export function showHideStatus() { - if (!versionBarEntry) { - return; - } - if (!vscode.window.activeTextEditor) { - versionBarEntry.hide(); - return; - } +export default class VersionStatus extends vscode.Disposable { + onChangeEditorSub: any; + private versionBarEntry: vscode.StatusBarItem; - let doc = vscode.window.activeTextEditor.document; - if (vscode.languages.match('typescript', doc) || vscode.languages.match('typescriptreact', doc)) { - versionBarEntry.show(); - return; - } + constructor() { + super(() => this.dispose()); + + this.versionBarEntry = vscode.window.createStatusBarItem(vscode.StatusBarAlignment.Right, Number.MIN_VALUE); - if (!vscode.window.activeTextEditor.viewColumn) { - // viewColumn is undefined for the debug/output panel, but we still want - // to show the version info - return; + this.onChangeEditorSub = vscode.window.onDidChangeActiveTextEditor(this.showHideStatus, this); } - versionBarEntry.hide(); -} + dispose() { + this.versionBarEntry.dispose(); + this.onChangeEditorSub.dispose(); + } -export function disposeStatus() { - if (versionBarEntry) { - versionBarEntry.dispose(); + showHideStatus() { + if (!this.versionBarEntry) { + return; + } + if (!vscode.window.activeTextEditor) { + this.versionBarEntry.hide(); + return; + } + + let doc = vscode.window.activeTextEditor.document; + if (vscode.languages.match('typescript', doc) || vscode.languages.match('typescriptreact', doc)) { + this.versionBarEntry.show(); + return; + } + + if (!vscode.window.activeTextEditor.viewColumn) { + // viewColumn is undefined for the debug/output panel, but we still want + // to show the version info + return; + } + + this.versionBarEntry.hide(); } -} -export function setInfo(message: string, tooltip: string) { - versionBarEntry.text = message; - versionBarEntry.tooltip = tooltip; - versionBarEntry.command = 'typescript.selectTypeScriptVersion'; + public setInfo(message: string, tooltip: string) { + this.versionBarEntry.text = message; + this.versionBarEntry.tooltip = tooltip; + this.versionBarEntry.command = 'typescript.selectTypeScriptVersion'; + } } diff --git a/src/vs/workbench/api/node/extHostTask.ts b/src/vs/workbench/api/node/extHostTask.ts index 5f23efc8f80..aa6497bc410 100644 --- a/src/vs/workbench/api/node/extHostTask.ts +++ b/src/vs/workbench/api/node/extHostTask.ts @@ -163,7 +163,7 @@ namespace ProblemMatcher { if (values === void 0 || values === null) { return undefined; } - let result: (string | Problems.ProblemMatcher)[]; + let result: (string | Problems.ProblemMatcher)[] = []; for (let value of values) { let converted = typeof value === 'string' ? value : fromSingle(value); if (converted) { -- GitLab From 416861268af5c06b56a6ca880020097ab0bbc11b Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Fri, 26 May 2017 00:18:20 +0200 Subject: [PATCH 0178/1347] Decoration text after decoration wrongly positioned. Fixes #27288 --- src/vs/editor/browser/services/codeEditorServiceImpl.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/editor/browser/services/codeEditorServiceImpl.ts b/src/vs/editor/browser/services/codeEditorServiceImpl.ts index 26bc62e9e6a..d824627e4ec 100644 --- a/src/vs/editor/browser/services/codeEditorServiceImpl.ts +++ b/src/vs/editor/browser/services/codeEditorServiceImpl.ts @@ -151,7 +151,7 @@ class DecorationTypeOptionsProvider implements IModelDecorationOptionsProvider { this.className = createCSSRules(ModelDecorationCSSRuleType.ClassName); this.inlineClassName = createCSSRules(ModelDecorationCSSRuleType.InlineClassName); this.beforeContentClassName = createCSSRules(ModelDecorationCSSRuleType.BeforeContentClassName); - this.beforeContentClassName = createCSSRules(ModelDecorationCSSRuleType.AfterContentClassName); + this.afterContentClassName = createCSSRules(ModelDecorationCSSRuleType.AfterContentClassName); this.glyphMarginClassName = createCSSRules(ModelDecorationCSSRuleType.GlyphMarginClassName); let options = providerArgs.options; -- GitLab From 2db5b3a43cabdbcbcfba8cff6ee65273eb1998c6 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 24 May 2017 15:27:48 -0700 Subject: [PATCH 0179/1347] Move VersionStatus into a class --- extensions/typescript/src/typescriptMain.ts | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/extensions/typescript/src/typescriptMain.ts b/extensions/typescript/src/typescriptMain.ts index 07a666936b9..18bc57678ff 100644 --- a/extensions/typescript/src/typescriptMain.ts +++ b/extensions/typescript/src/typescriptMain.ts @@ -90,6 +90,7 @@ const standardLanguageDescriptions: LanguageDescription[] = [ export function activate(context: ExtensionContext): void { const plugins = getContributedTypeScriptServerPlugins(); +<<<<<<< HEAD const lazyClientHost = (() => { let clientHost: TypeScriptServiceClientHost | undefined; return () => { @@ -110,6 +111,10 @@ export function activate(context: ExtensionContext): void { }; })(); +======= + const clientHost = new TypeScriptServiceClientHost(standardLanguageDescriptions, context.storagePath, context.globalState, context.workspaceState, plugins); + context.subscriptions.push(clientHost); +>>>>>>> a0b779f... Move VersionStatus into a class context.subscriptions.push(commands.registerCommand('typescript.reloadProjects', () => { lazyClientHost().reloadProjects(); @@ -145,6 +150,7 @@ export function activate(context: ExtensionContext): void { const jsDocCompletionCommand = new TryCompleteJsDocCommand(() => lazyClientHost().serviceClient); context.subscriptions.push(commands.registerCommand(TryCompleteJsDocCommand.COMMAND_NAME, jsDocCompletionCommand.tryCompleteJsDoc, jsDocCompletionCommand)); +<<<<<<< HEAD const supportedLanguage = [].concat.apply([], standardLanguageDescriptions.map(x => x.modeIds).concat(plugins.map(x => x.languages))); function didOpenTextDocument(textDocument: TextDocument): boolean { if (supportedLanguage.indexOf(textDocument.languageId) >= 0) { @@ -162,6 +168,15 @@ export function activate(context: ExtensionContext): void { } } +======= + clientHost.serviceClient.onReady().then(() => { + context.subscriptions.push(ProjectStatus.create(clientHost.serviceClient, + path => new Promise(resolve => setTimeout(() => resolve(clientHost.handles(path)), 750)), + context.workspaceState)); + }, () => { + // Nothing to do here. The client did show a message; + }); +>>>>>>> a0b779f... Move VersionStatus into a class BuildStatus.update({ queueLength: 0 }); } -- GitLab From 68dbf58ff72b9dc136aaf1b7faddd99f75e21c48 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Thu, 25 May 2017 15:30:19 -0700 Subject: [PATCH 0180/1347] Actually save the file this time :'( --- extensions/typescript/src/typescriptMain.ts | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/extensions/typescript/src/typescriptMain.ts b/extensions/typescript/src/typescriptMain.ts index 18bc57678ff..07a666936b9 100644 --- a/extensions/typescript/src/typescriptMain.ts +++ b/extensions/typescript/src/typescriptMain.ts @@ -90,7 +90,6 @@ const standardLanguageDescriptions: LanguageDescription[] = [ export function activate(context: ExtensionContext): void { const plugins = getContributedTypeScriptServerPlugins(); -<<<<<<< HEAD const lazyClientHost = (() => { let clientHost: TypeScriptServiceClientHost | undefined; return () => { @@ -111,10 +110,6 @@ export function activate(context: ExtensionContext): void { }; })(); -======= - const clientHost = new TypeScriptServiceClientHost(standardLanguageDescriptions, context.storagePath, context.globalState, context.workspaceState, plugins); - context.subscriptions.push(clientHost); ->>>>>>> a0b779f... Move VersionStatus into a class context.subscriptions.push(commands.registerCommand('typescript.reloadProjects', () => { lazyClientHost().reloadProjects(); @@ -150,7 +145,6 @@ export function activate(context: ExtensionContext): void { const jsDocCompletionCommand = new TryCompleteJsDocCommand(() => lazyClientHost().serviceClient); context.subscriptions.push(commands.registerCommand(TryCompleteJsDocCommand.COMMAND_NAME, jsDocCompletionCommand.tryCompleteJsDoc, jsDocCompletionCommand)); -<<<<<<< HEAD const supportedLanguage = [].concat.apply([], standardLanguageDescriptions.map(x => x.modeIds).concat(plugins.map(x => x.languages))); function didOpenTextDocument(textDocument: TextDocument): boolean { if (supportedLanguage.indexOf(textDocument.languageId) >= 0) { @@ -168,15 +162,6 @@ export function activate(context: ExtensionContext): void { } } -======= - clientHost.serviceClient.onReady().then(() => { - context.subscriptions.push(ProjectStatus.create(clientHost.serviceClient, - path => new Promise(resolve => setTimeout(() => resolve(clientHost.handles(path)), 750)), - context.workspaceState)); - }, () => { - // Nothing to do here. The client did show a message; - }); ->>>>>>> a0b779f... Move VersionStatus into a class BuildStatus.update({ queueLength: 0 }); } -- GitLab From 065b600fe726a4e8e1e183eb2e39dbd4565173a9 Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Thu, 25 May 2017 16:03:38 -0700 Subject: [PATCH 0181/1347] Fix #26708 - use StringDecoder to handle data chunks that split multibyte characters --- .../services/search/node/ripgrepTextSearch.ts | 16 +++++++-- .../test/node/ripgrepTextSearch.test.ts | 36 +++++++++++++++---- 2 files changed, 42 insertions(+), 10 deletions(-) diff --git a/src/vs/workbench/services/search/node/ripgrepTextSearch.ts b/src/vs/workbench/services/search/node/ripgrepTextSearch.ts index 829406f52fe..03aaa15bb75 100644 --- a/src/vs/workbench/services/search/node/ripgrepTextSearch.ts +++ b/src/vs/workbench/services/search/node/ripgrepTextSearch.ts @@ -6,6 +6,7 @@ import { EventEmitter } from 'events'; import * as path from 'path'; +import { StringDecoder, NodeStringDecoder } from 'string_decoder'; import * as cp from 'child_process'; import { rgPath } from 'vscode-ripgrep'; @@ -174,11 +175,13 @@ export class RipgrepParser extends EventEmitter { private fileMatch: FileMatch; private remainder: string; private isDone: boolean; + private stringDecoder: NodeStringDecoder; private numResults = 0; constructor(private maxResults: number, private rootFolder: string) { super(); + this.stringDecoder = new StringDecoder(); } public cancel(): void { @@ -186,16 +189,23 @@ export class RipgrepParser extends EventEmitter { } public flush(): void { + this.handleDecodedData(this.stringDecoder.end()); + if (this.fileMatch) { this.onResult(); } } - public handleData(data: string | Buffer): void { + public handleData(data: Buffer | string): void { + const dataStr = typeof data === 'string' ? data : this.stringDecoder.write(data); + this.handleDecodedData(dataStr); + } + + private handleDecodedData(decodedData: string): void { // If the previous data chunk didn't end in a newline, prepend it to this chunk const dataStr = this.remainder ? - this.remainder + data.toString() : - data.toString(); + this.remainder + decodedData : + decodedData; const dataLines: string[] = dataStr.split(/\r\n|\n/); this.remainder = dataLines[dataLines.length - 1] ? dataLines.pop() : null; diff --git a/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts b/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts index 1ee3f9a6a83..9ff4208d109 100644 --- a/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts +++ b/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts @@ -33,7 +33,11 @@ suite('RipgrepParser', () => { return matchLine; } - function parseInput(inputChunks: string[]): ISerializedFileMatch[] { + function parseInputStrings(inputChunks: string[]): ISerializedFileMatch[] { + return parseInput(inputChunks.map(chunk => new Buffer(chunk))); + } + + function parseInput(inputChunks: Buffer[]): ISerializedFileMatch[] { const matches: ISerializedFileMatch[] = []; const rgp = new RipgrepParser(1e6, rootFolder); rgp.on('result', (match: ISerializedFileMatch) => { @@ -65,7 +69,7 @@ suite('RipgrepParser', () => { [getFileLine('a.txt'), getMatchLine(1, ['before', 'match', 'after']), getMatchLine(2, ['before', 'match', 'after']), fileSectionEnd].join('\n') ]; - const results = parseInput(input); + const results = parseInputStrings(input); assert.equal(results.length, 1); assert.deepEqual(results[0], { @@ -93,7 +97,7 @@ suite('RipgrepParser', () => { [getFileLine('c.txt'), getMatchLine(1, ['before', 'match', 'after']), getMatchLine(2, ['before', 'match', 'after']), fileSectionEnd].join('\n') ]; - const results = parseInput(input); + const results = parseInputStrings(input); assert.equal(results.length, 3); results.forEach(fileResult => assert.equal(fileResult.numMatches, 2)); }); @@ -116,7 +120,7 @@ suite('RipgrepParser', () => { test('Parses multiple chunks broken at each line', () => { const input = singleLineChunks.map(chunk => chunk + '\n'); - const results = parseInput(input); + const results = parseInputStrings(input); assert.equal(results.length, 3); results.forEach(fileResult => assert.equal(fileResult.numMatches, 2)); }); @@ -126,7 +130,7 @@ suite('RipgrepParser', () => { .map(chunk => chunk + '\n') .map(halve)); - const results = parseInput(input); + const results = parseInputStrings(input); assert.equal(results.length, 3); results.forEach(fileResult => assert.equal(fileResult.numMatches, 2)); }); @@ -136,7 +140,7 @@ suite('RipgrepParser', () => { .map(chunk => chunk + '\n') .map(arrayOfChars)); - const results = parseInput(input); + const results = parseInputStrings(input); assert.equal(results.length, 3); results.forEach(fileResult => assert.equal(fileResult.numMatches, 2)); }); @@ -145,8 +149,26 @@ suite('RipgrepParser', () => { const input = singleLineChunks .map(chunk => '\n' + chunk); - const results = parseInput(input); + const results = parseInputStrings(input); assert.equal(results.length, 3); results.forEach(fileResult => assert.equal(fileResult.numMatches, 2)); }); + + test('Parses chunks broken in the middle of a multibyte character', () => { + const multibyteStr = 'æ¼¢'; + const multibyteBuf = new Buffer(multibyteStr); + const text = getFileLine('foo/bar') + '\n' + getMatchLine(0, ['before', 'match', 'after']) + '\n'; + + // Split the multibyte char into two pieces and divide between the two buffers + const beforeIndex = 24; + const inputBufs = [ + Buffer.concat([new Buffer(text.substr(0, beforeIndex)), multibyteBuf.slice(0, 2)]), + Buffer.concat([multibyteBuf.slice(2), new Buffer(text.substr(beforeIndex))]) + ]; + + const results = parseInput(inputBufs); + assert.equal(results.length, 1); + assert.equal(results[0].lineMatches.length, 1); + assert.deepEqual(results[0].lineMatches[0].offsetAndLengths, [[7, 5]]); + }); }); \ No newline at end of file -- GitLab From 018f6ac2a610685b40770ebcbc39087fb609d07e Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Thu, 25 May 2017 16:15:19 -0700 Subject: [PATCH 0182/1347] Add Unit Test launch config (not sure why it was deleted?) --- .vscode/launch.json | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/.vscode/launch.json b/.vscode/launch.json index d56ca22e59d..fa30207ce2b 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -146,6 +146,32 @@ "outFiles": [ "${workspaceRoot}/extensions/node_modules/typescript/lib/**/*.js" ] + }, + { + "type": "node", + "request": "launch", + "name": "Unit Tests", + "protocol": "legacy", + "program": "${workspaceRoot}/node_modules/mocha/bin/_mocha", + "runtimeExecutable": "${workspaceRoot}/.build/electron/Code - OSS.app/Contents/MacOS/Electron", + "windows": { + "runtimeExecutable": "${workspaceRoot}/.build/electron/Code - OSS.exe" + }, + "linux": { + "runtimeExecutable": "${workspaceRoot}/.build/electron/code-oss" + }, + "stopOnEntry": false, + "args": [ + "--timeout", + "2000" + ], + "cwd": "${workspaceRoot}", + "env": { + "ELECTRON_RUN_AS_NODE": "true" + }, + "outFiles": [ + "${workspaceRoot}/out/**/*.js" + ] } ], "compounds": [ -- GitLab From 665dbb442e970564c8d3771ee4653b8961dfc765 Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Thu, 25 May 2017 16:17:37 -0700 Subject: [PATCH 0183/1347] sourceMaps is enabled by default, remove from launch configs --- .vscode/launch.json | 9 --------- 1 file changed, 9 deletions(-) diff --git a/.vscode/launch.json b/.vscode/launch.json index fa30207ce2b..39b72b995a8 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -18,7 +18,6 @@ "name": "Attach to Extension Host", "protocol": "legacy", "port": 5870, - "sourceMaps": true, "restart": true, "outFiles": [ "${workspaceRoot}/out/**/*.js" @@ -30,7 +29,6 @@ "name": "Attach to Shared Process", "protocol": "legacy", "port": 5871, - "sourceMaps": true, "outFiles": [ "${workspaceRoot}/out/**/*.js" ] @@ -41,7 +39,6 @@ "protocol": "legacy", "name": "Attach to Search process", "port": 7890, - "sourceMaps": true, "outFiles": [ "${workspaceRoot}/out/**/*.js" ] @@ -52,7 +49,6 @@ "name": "Attach to CLI Process", "protocol": "legacy", "port": 5874, - "sourceMaps": true, "outFiles": [ "${workspaceRoot}/out/**/*.js" ] @@ -63,7 +59,6 @@ "name": "Attach to Main Process", "protocol": "legacy", "port": 5875, - "sourceMaps": true, "outFiles": [ "${workspaceRoot}/out/**/*.js" ] @@ -78,7 +73,6 @@ "--extensionDevelopmentPath=${workspaceRoot}/extensions/vscode-api-tests", "--extensionTestsPath=${workspaceRoot}/extensions/vscode-api-tests/out" ], - "sourceMaps": true, "outFiles": [ "${workspaceRoot}/out/**/*.js" ] @@ -93,7 +87,6 @@ "--extensionDevelopmentPath=${workspaceRoot}/extensions/vscode-colorize-tests", "--extensionTestsPath=${workspaceRoot}/extensions/vscode-colorize-tests/out" ], - "sourceMaps": true, "outFiles": [ "${workspaceRoot}/out/**/*.js" ] @@ -131,7 +124,6 @@ "program": "${workspaceRoot}/extensions/git/node_modules/mocha/bin/_mocha", "stopOnEntry": false, "cwd": "${workspaceRoot}/extensions/git", - "sourceMaps": true, "outFiles": [ "${workspaceRoot}/extensions/git/out/**/*.js" ] @@ -141,7 +133,6 @@ "type": "node", "request": "attach", "port": 5859, - "sourceMaps": true, "protocol": "legacy", "outFiles": [ "${workspaceRoot}/extensions/node_modules/typescript/lib/**/*.js" -- GitLab From c81df3a4f446dbcd5d0b7c03bbabe581455b46b6 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 25 May 2017 16:17:21 -0700 Subject: [PATCH 0184/1347] Use 'descriptionForeground' (#27289) --- extensions/merge-conflict/src/mergeDecorator.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/extensions/merge-conflict/src/mergeDecorator.ts b/extensions/merge-conflict/src/mergeDecorator.ts index 39888f727e6..be9e733a562 100644 --- a/extensions/merge-conflict/src/mergeDecorator.ts +++ b/extensions/merge-conflict/src/mergeDecorator.ts @@ -81,7 +81,7 @@ export default class MergeDectorator implements vscode.Disposable { color: new vscode.ThemeColor('editor.foreground'), after: { contentText: ' ' + localize('currentChange', '(Current change)'), - color: 'rgba(0, 0, 0, 0.7)' + color: new vscode.ThemeColor('descriptionForeground') } }); @@ -96,7 +96,7 @@ export default class MergeDectorator implements vscode.Disposable { isWholeLine: this.decorationUsesWholeLine, after: { contentText: ' ' + localize('incomingChange', '(Incoming change)'), - color: 'rgba(0, 0, 0, 0.7)' + color: new vscode.ThemeColor('descriptionForeground') } }); } -- GitLab From b117a11c0db5743c35d111a607c1a53f05573503 Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Thu, 25 May 2017 16:27:55 -0700 Subject: [PATCH 0185/1347] Safer change for #25422 --- src/vs/workbench/services/search/node/ripgrepTextSearch.ts | 2 +- .../services/search/test/node/ripgrepTextSearch.test.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/services/search/node/ripgrepTextSearch.ts b/src/vs/workbench/services/search/node/ripgrepTextSearch.ts index 03aaa15bb75..b7f3b7ad4dc 100644 --- a/src/vs/workbench/services/search/node/ripgrepTextSearch.ts +++ b/src/vs/workbench/services/search/node/ripgrepTextSearch.ts @@ -235,7 +235,7 @@ export class RipgrepParser extends EventEmitter { this.onResult(); } - this.fileMatch = new FileMatch(path.resolve(this.rootFolder, r[1])); + this.fileMatch = new FileMatch(path.isAbsolute(r[1]) ? r[1] : path.join(this.rootFolder, r[1])); } else { // Line is empty (or malformed) } diff --git a/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts b/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts index 9ff4208d109..87a27629eaf 100644 --- a/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts +++ b/src/vs/workbench/services/search/test/node/ripgrepTextSearch.test.ts @@ -74,7 +74,7 @@ suite('RipgrepParser', () => { assert.deepEqual(results[0], { numMatches: 2, - path: path.resolve(rootFolder, 'a.txt'), + path: path.join(rootFolder, 'a.txt'), lineMatches: [ { lineNumber: 0, -- GitLab From c79c2fe9fb57aecdd1cbe468b6b9cda2b9daf7fb Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Thu, 25 May 2017 17:47:01 -0700 Subject: [PATCH 0186/1347] node-debug2@1.13.0 --- build/gulpfile.vscode.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index 15d2edd0323..cf894772b6a 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -43,7 +43,7 @@ const nodeModules = ['electron', 'original-fs'] const builtInExtensions = [ { name: 'ms-vscode.node-debug', version: '1.13.6' }, - { name: 'ms-vscode.node-debug2', version: '1.12.4' } + { name: 'ms-vscode.node-debug2', version: '1.13.0' } ]; const vscodeEntryPoints = _.flatten([ -- GitLab From 71aeb83f8a5ece369534350157fed381d03c6eb1 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Thu, 25 May 2017 21:23:47 -0700 Subject: [PATCH 0187/1347] Pickup all TSConfigs in Workspace for TSC Build Task (#27306) Follow up on #26079 Allows us to pick up all tsconfig files in a workspace for the build tasks --- .../typescript/src/features/taskProvider.ts | 51 +++++++++------- .../typescript/src/utils/tsconfigProvider.ts | 58 +++++++++++++++++++ 2 files changed, 88 insertions(+), 21 deletions(-) create mode 100644 extensions/typescript/src/utils/tsconfigProvider.ts diff --git a/extensions/typescript/src/features/taskProvider.ts b/extensions/typescript/src/features/taskProvider.ts index 76528021983..ba53903e447 100644 --- a/extensions/typescript/src/features/taskProvider.ts +++ b/extensions/typescript/src/features/taskProvider.ts @@ -11,6 +11,7 @@ import * as vscode from 'vscode'; import * as Proto from '../protocol'; import TypeScriptServiceClient from '../typescriptServiceClient'; +import TsConfigProvider from "../utils/tsconfigProvider"; const exists = (file: string): Promise => @@ -21,32 +22,47 @@ const exists = (file: string): Promise => }); export default class TypeScriptTaskProvider implements vscode.TaskProvider { + private readonly tsconfigProvider: TsConfigProvider; public constructor( private readonly lazyClient: () => TypeScriptServiceClient - ) { } + ) { + this.tsconfigProvider = new TsConfigProvider(); + } + + dispose() { + this.tsconfigProvider.dispose(); + } - async provideTasks(token: vscode.CancellationToken): Promise { + public async provideTasks(token: vscode.CancellationToken): Promise { const rootPath = vscode.workspace.rootPath; if (!rootPath) { return []; } - const projects = (await this.getConfigForActiveFile(token)).concat(await this.getConfigsForWorkspace()); const command = await this.getCommand(); + const projects = await this.getAllTsConfigs(token); - return projects - .filter((x, i) => projects.indexOf(x) === i) - .map(configFile => { - const configFileName = path.relative(rootPath, configFile); - const buildTask = new vscode.ShellTask(`tsc: build ${configFileName}`, `${command} -p ${configFile}`, '$tsc'); - buildTask.group = vscode.TaskGroup.Build; - return buildTask; - }); + return projects.map(configFile => { + const configFileName = path.relative(rootPath, configFile); + const buildTask = new vscode.ShellTask(`tsc: build ${configFileName}`, `${command} -p ${configFile}`, '$tsc'); + buildTask.group = vscode.TaskGroup.Build; + return buildTask; + }); } + private async getAllTsConfigs(token: vscode.CancellationToken): Promise { + const out: string[] = []; + const configs = (await this.getTsConfigForActiveFile(token)).concat(await this.getTsConfigsInWorkspace()); + for (const config of configs) { + if (await exists(config)) { + out.push(config); + } + } + return out; + } - private async getConfigForActiveFile(token: vscode.CancellationToken): Promise { + private async getTsConfigForActiveFile(token: vscode.CancellationToken): Promise { const editor = vscode.window.activeTextEditor; if (editor) { if (path.basename(editor.document.fileName).match(/^tsconfig\.(.\.)?json$/)) { @@ -75,15 +91,8 @@ export default class TypeScriptTaskProvider implements vscode.TaskProvider { return []; } - private async getConfigsForWorkspace(): Promise { - if (!vscode.workspace.rootPath) { - return []; - } - const rootTsConfig = path.join(vscode.workspace.rootPath, 'tsconfig.json'); - if (!await exists(rootTsConfig)) { - return []; - } - return [rootTsConfig]; + private async getTsConfigsInWorkspace(): Promise { + return Array.from(await this.tsconfigProvider.getConfigsForWorkspace()); } private async getCommand(): Promise { diff --git a/extensions/typescript/src/utils/tsconfigProvider.ts b/extensions/typescript/src/utils/tsconfigProvider.ts new file mode 100644 index 00000000000..e85ca24bbff --- /dev/null +++ b/extensions/typescript/src/utils/tsconfigProvider.ts @@ -0,0 +1,58 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +import * as vscode from 'vscode'; + +export default class TsConfigProvider extends vscode.Disposable { + private readonly tsconfigs = new Set(); + + private activated: boolean = false; + private disposables: vscode.Disposable[] = []; + + constructor() { + super(() => this.dispose()); + } + + dispose(): void { + this.disposables.forEach(d => d.dispose()); + } + + public async getConfigsForWorkspace(): Promise> { + if (!vscode.workspace.rootPath) { + return []; + } + await this.ensureActivated(); + return this.tsconfigs; + } + + private async ensureActivated() { + if (this.activated) { + return this; + } + this.activated = true; + + for (const config of await TsConfigProvider.loadWorkspaceTsconfigs()) { + this.tsconfigs.add(config.fsPath); + } + + const configFileWatcher = vscode.workspace.createFileSystemWatcher('**/tsconfig*.json'); + this.disposables.push(configFileWatcher); + configFileWatcher.onDidCreate(this.handleProjectCreate, this, this.disposables); + configFileWatcher.onDidDelete(this.handleProjectDelete, this, this.disposables); + + return this; + } + + private static loadWorkspaceTsconfigs() { + return vscode.workspace.findFiles('**/tsconfig*.json', '**/node_modules/**'); + } + + private handleProjectCreate(e: vscode.Uri) { + this.tsconfigs.add(e.fsPath); + } + + private handleProjectDelete(e: vscode.Uri) { + this.tsconfigs.delete(e.fsPath); + } +} -- GitLab From 5be2260d22aa832ab53ae9196c513553b410bef3 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Thu, 25 May 2017 23:50:49 -0700 Subject: [PATCH 0188/1347] Select single words in property value --- extensions/emmet/src/selectItemHTML.ts | 65 +++++++++++++++-- extensions/emmet/src/selectItemStylesheet.ts | 75 ++++++++++++++++--- extensions/emmet/src/util.ts | 76 ++++++++++++++++++++ 3 files changed, 200 insertions(+), 16 deletions(-) diff --git a/extensions/emmet/src/selectItemHTML.ts b/extensions/emmet/src/selectItemHTML.ts index 79d0a585e0a..2c0be704ead 100644 --- a/extensions/emmet/src/selectItemHTML.ts +++ b/extensions/emmet/src/selectItemHTML.ts @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ import * as vscode from 'vscode'; -import { getNode, getDeepestNode } from './util'; +import { getNode, getDeepestNode, findNextWord, findPrevWord } from './util'; import Node from '@emmetio/node'; export function nextItemHTML(selection: vscode.Selection, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { @@ -99,10 +99,40 @@ function getNextAttribute(selection: vscode.Selection, document: vscode.TextDocu return new vscode.Selection(document.positionAt(attr.start), document.positionAt(attr.end)); } - if ((attr.value.start !== attr.value.end) && ((selectionStart === attr.start && selectionEnd === attr.end) || selectionEnd < attr.end - 1)) { - // select attr value + if (attr.value.start === attr.value.end) { + // No attr value to select + continue; + } + + if ((selectionStart === attr.start && selectionEnd === attr.end) || selectionEnd < attr.value.start) { + // cursor is in attr name, so select full attr value return new vscode.Selection(document.positionAt(attr.value.start), document.positionAt(attr.value.end)); } + + // Fetch the next word in the attr value + + if (attr.value.toString().indexOf(' ') === -1) { + // attr value does not have space, so no next word to find + continue; + } + + let pos = undefined; + if (selectionStart === attr.value.start && selectionEnd === attr.value.end) { + pos = -1; + } + if (pos === undefined && selectionEnd < attr.end) { + pos = selectionEnd - attr.value.start - 1; + } + + if (pos !== undefined) { + let [newSelectionStart, newSelectionEnd] = findNextWord(attr.value.toString(), pos); + if (newSelectionStart >= 0 && newSelectionEnd >= 0) { + newSelectionStart += attr.value.start; + newSelectionEnd += attr.value.start; + return new vscode.Selection(document.positionAt(newSelectionStart), document.positionAt(newSelectionEnd)); + } + } + } } @@ -113,18 +143,39 @@ function getPrevAttribute(selection: vscode.Selection, document: vscode.TextDocu } let selectionStart = document.offsetAt(selection.anchor); + let selectionEnd = document.offsetAt(selection.active); for (let i = node.attributes.length - 1; i >= 0; i--) { let attr = node.attributes[i]; - if (selectionStart > attr.value.start) { - // select attr value - return new vscode.Selection(document.positionAt(attr.value.start), document.positionAt(attr.value.end)); + if (selectionStart <= attr.start) { + continue; } - if (selectionStart > attr.start) { + if (attr.value.start === attr.value.end || selectionStart < attr.value.start) { // select full attr return new vscode.Selection(document.positionAt(attr.start), document.positionAt(attr.end)); } + + if (selectionStart === attr.value.start) { + if (selectionEnd >= attr.value.end) { + // select full attr + return new vscode.Selection(document.positionAt(attr.start), document.positionAt(attr.end)); + } + // select attr value + return new vscode.Selection(document.positionAt(attr.value.start), document.positionAt(attr.value.end)); + } + + // Fetch the prev word in the attr value + + let pos = selectionStart > attr.value.end ? attr.value.toString().length : selectionStart - attr.value.start; + let [newSelectionStart, newSelectionEnd] = findPrevWord(attr.value.toString(), pos); + if (newSelectionStart >= 0 && newSelectionEnd >= 0) { + newSelectionStart += attr.value.start; + newSelectionEnd += attr.value.start; + return new vscode.Selection(document.positionAt(newSelectionStart), document.positionAt(newSelectionEnd)); + } + + } } \ No newline at end of file diff --git a/extensions/emmet/src/selectItemStylesheet.ts b/extensions/emmet/src/selectItemStylesheet.ts index d0167a2d8b9..e3144cbf666 100644 --- a/extensions/emmet/src/selectItemStylesheet.ts +++ b/extensions/emmet/src/selectItemStylesheet.ts @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ import * as vscode from 'vscode'; -import { getNode, getDeepestNode } from './util'; +import { getNode, getDeepestNode, findNextWord, findPrevWord } from './util'; import Node from '@emmetio/node'; export function nextItemStylesheet(selection: vscode.Selection, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { @@ -12,9 +12,17 @@ export function nextItemStylesheet(selection: vscode.Selection, editor: vscode.T let endOffset = editor.document.offsetAt(selection.active); let currentNode = getNode(rootNode, endOffset, true); - // Full property is selected, so select property value next + // Full property is selected, so select full property value next if (currentNode.type === 'property' && startOffset === currentNode.start && endOffset === currentNode.end) { - return getSelectionFromNode(currentNode, editor.document, true); + return getSelectionFromProperty(currentNode, editor.document, startOffset, endOffset, true, 'next'); + } + + // Part or whole of propertyValue is selected, so select the next word in the propertyValue + if (currentNode.type === 'property' && startOffset >= currentNode.valueToken.start && endOffset <= currentNode.valueToken.end) { + let singlePropertyValue = getSelectionFromProperty(currentNode, editor.document, startOffset, endOffset, false, 'next'); + if (singlePropertyValue) { + return singlePropertyValue; + } } // Cursor is in the selector or in a property @@ -41,13 +49,27 @@ export function nextItemStylesheet(selection: vscode.Selection, editor: vscode.T export function prevItemStylesheet(selection: vscode.Selection, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { let startOffset = editor.document.offsetAt(selection.anchor); + let endOffset = editor.document.offsetAt(selection.active); let currentNode = getNode(rootNode, startOffset); if (!currentNode) { currentNode = rootNode; } + // Full property value is selected, so select the whole property next + if (currentNode.type === 'property' && startOffset === currentNode.valueToken.start && endOffset === currentNode.valueToken.end) { + return getSelectionFromNode(currentNode, editor.document); + } + + // Part of propertyValue is selected, so select the prev word in the propertyValue + if (currentNode.type === 'property' && startOffset >= currentNode.valueToken.start && endOffset <= currentNode.valueToken.end) { + let singlePropertyValue = getSelectionFromProperty(currentNode, editor.document, startOffset, endOffset, false, 'prev'); + if (singlePropertyValue) { + return singlePropertyValue; + } + } + if (currentNode.type === 'property' || !currentNode.firstChild || (currentNode.type === 'rule' && startOffset <= currentNode.firstChild.start)) { - return getSelectionFromNode(currentNode, editor.document);; + return getSelectionFromNode(currentNode, editor.document); } // Select the child that appears just before the cursor @@ -57,23 +79,58 @@ export function prevItemStylesheet(selection: vscode.Selection, editor: vscode.T } prevNode = getDeepestNode(prevNode); - return getSelectionFromNode(prevNode, editor.document, true); + return getSelectionFromProperty(prevNode, editor.document, startOffset, endOffset, false, 'prev'); } -function getSelectionFromNode(node: Node, document: vscode.TextDocument, selectPropertyValue: boolean = false): vscode.Selection { +function getSelectionFromNode(node: Node, document: vscode.TextDocument): vscode.Selection { if (!node) { return; } let nodeToSelect = node.type === 'rule' ? node.selectorToken : node; + return new vscode.Selection(document.positionAt(nodeToSelect.start), document.positionAt(nodeToSelect.end)); +} + + +function getSelectionFromProperty(node: Node, document: vscode.TextDocument, selectionStart: number, selectionEnd: number, selectFullValue: boolean, direction: string): vscode.Selection { + if (!node || node.type !== 'property') { + return; + } + + let propertyValue = node.valueToken.stream.substring(node.valueToken.start, node.valueToken.end); + selectFullValue = selectFullValue || (direction === 'prev' && selectionStart === node.valueToken.start && selectionEnd < node.valueToken.end); + + if (selectFullValue) { + return new vscode.Selection(document.positionAt(node.valueToken.start), document.positionAt(node.valueToken.end)); + } + + let pos; + if (direction === 'prev') { + if (selectionStart === node.valueToken.start) { + return; + } + pos = selectionStart > node.valueToken.end ? propertyValue.length : selectionStart - node.valueToken.start; + } + + if (direction === 'next') { + if (selectionEnd === node.valueToken.end && (selectionStart > node.valueToken.start || propertyValue.indexOf(' ') === -1)) { + return; + } + pos = selectionEnd === node.valueToken.end ? -1 : selectionEnd - node.valueToken.start - 1; + } - let selectionStart = (node.type === 'property' && selectPropertyValue) ? node.valueToken.start : nodeToSelect.start; - let selectionEnd = (node.type === 'property' && selectPropertyValue) ? node.valueToken.end : nodeToSelect.end; - return new vscode.Selection(document.positionAt(selectionStart), document.positionAt(selectionEnd)); + let [newSelectionStart, newSelectionEnd] = direction === 'prev' ? findPrevWord(propertyValue, pos) : findNextWord(propertyValue, pos); + if (!newSelectionStart && !newSelectionEnd) { + return; + } + + newSelectionStart += node.valueToken.start; + newSelectionEnd += node.valueToken.start; + return new vscode.Selection(document.positionAt(newSelectionStart), document.positionAt(newSelectionEnd)); } diff --git a/extensions/emmet/src/util.ts b/extensions/emmet/src/util.ts index 3b495069d1e..81085e5b6d6 100644 --- a/extensions/emmet/src/util.ts +++ b/extensions/emmet/src/util.ts @@ -136,4 +136,80 @@ export function getDeepestNode(node: Node): Node { } return getDeepestNode(node.children[node.children.length - 1]); +} + +export function findNextWord(propertyValue: string, pos: number): [number, number] { + + let foundSpace = pos === -1; + let foundStart = false; + let foundEnd = false; + + let newSelectionStart; + let newSelectionEnd; + while (pos < propertyValue.length - 1) { + pos++; + if (!foundSpace) { + if (propertyValue[pos] === ' ') { + foundSpace = true; + } + continue; + } + if (foundSpace && !foundStart && propertyValue[pos] === ' ') { + continue; + } + if (!foundStart) { + newSelectionStart = pos; + foundStart = true; + continue; + } + if (propertyValue[pos] === ' ') { + newSelectionEnd = pos; + foundEnd = true; + break; + } + } + + if (foundStart && !foundEnd) { + newSelectionEnd = propertyValue.length; + } + + return [newSelectionStart, newSelectionEnd]; +} + +export function findPrevWord(propertyValue: string, pos: number): [number, number] { + + let foundSpace = pos === propertyValue.length; + let foundStart = false; + let foundEnd = false; + + let newSelectionStart; + let newSelectionEnd; + while (pos > -1) { + pos--; + if (!foundSpace) { + if (propertyValue[pos] === ' ') { + foundSpace = true; + } + continue; + } + if (foundSpace && !foundEnd && propertyValue[pos] === ' ') { + continue; + } + if (!foundEnd) { + newSelectionEnd = pos + 1; + foundEnd = true; + continue; + } + if (propertyValue[pos] === ' ') { + newSelectionStart = pos + 1; + foundStart = true; + break; + } + } + + if (foundEnd && !foundStart) { + newSelectionStart = 0; + } + + return [newSelectionStart, newSelectionEnd]; } \ No newline at end of file -- GitLab From 0fbbc8eb0c0e88c55474eb07ac31759d0b5255ec Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 26 May 2017 10:17:58 +0200 Subject: [PATCH 0189/1347] fix #27245 --- src/vs/vscode.d.ts | 4 +++- src/vs/workbench/api/node/extHostDocumentData.ts | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/vs/vscode.d.ts b/src/vs/vscode.d.ts index 35a6a58cc03..296649cd8f9 100644 --- a/src/vs/vscode.d.ts +++ b/src/vs/vscode.d.ts @@ -201,7 +201,9 @@ declare module 'vscode' { * Get a word-range at the given position. By default words are defined by * common separators, like space, -, _, etc. In addition, per languge custom * [word definitions](#LanguageConfiguration.wordPattern) can be defined. It - * is also possible to provide a custom regular expression. + * is also possible to provide a custom regular expression. *Note* that a + * custom regular expression must not match the empty string and that it will + * be ignored if it does. * * The position will be [adjusted](#TextDocument.validatePosition). * diff --git a/src/vs/workbench/api/node/extHostDocumentData.ts b/src/vs/workbench/api/node/extHostDocumentData.ts index 96cb2aec92d..e52493a31e0 100644 --- a/src/vs/workbench/api/node/extHostDocumentData.ts +++ b/src/vs/workbench/api/node/extHostDocumentData.ts @@ -243,6 +243,7 @@ export class ExtHostDocumentData extends MirrorModel { private _getWordRangeAtPosition(_position: vscode.Position, regexp?: RegExp): vscode.Range { let position = this._validatePosition(_position); if (!regexp || regExpLeadsToEndlessLoop(regexp)) { + console.warn(`[getWordRangeAtPosition]: ignoring custom regexp '${regexp.source}' because it matches the empty string.`); regexp = getWordDefinitionFor(this._languageId); } let wordAtText = getWordAtText( -- GitLab From de6e586588f7701cadb966a70d2452700b5b3858 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 26 May 2017 10:27:58 +0200 Subject: [PATCH 0190/1347] fix #27277 --- src/vs/vscode.d.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/vs/vscode.d.ts b/src/vs/vscode.d.ts index 296649cd8f9..e9645e8147d 100644 --- a/src/vs/vscode.d.ts +++ b/src/vs/vscode.d.ts @@ -4680,6 +4680,8 @@ declare module 'vscode' { * A glob pattern that filters the file events must be provided. Optionally, flags to ignore certain * kinds of events can be provided. To stop listening to events the watcher must be disposed. * + * *Note* that only files within the current [workspace](#workspace.rootPath) can be watched. + * * @param globPattern A glob pattern that is applied to the names of created, changed, and deleted files. * @param ignoreCreateEvents Ignore when files have been created. * @param ignoreChangeEvents Ignore when files have been changed. -- GitLab From 929ac9047d0c4f17a944d59f5f845de0fe75f0dc Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Fri, 26 May 2017 10:36:52 +0200 Subject: [PATCH 0191/1347] Updated tasks tests with respect to new Express eslint config. Code cleanup. --- test/smoke/.vscode/launch.json | 26 --------------- test/smoke/.vscode/tasks.json | 10 ------ test/smoke/src/areas/tasks.ts | 11 ++++--- test/smoke/src/main.js | 1 - test/smoke/src/mocha-runner.js | 2 +- test/smoke/src/test.ts | 36 +++++++++++++++++++++ test/smoke/src/tests.ts | 36 --------------------- test/smoke/src/tests/configuration-views.ts | 4 +-- test/smoke/src/tests/css.ts | 4 +-- test/smoke/src/tests/data-loss.ts | 4 +-- test/smoke/src/tests/data-migration.ts | 5 +-- test/smoke/src/tests/explorer.ts | 5 +-- test/smoke/src/tests/extensions.ts | 19 +++++++++-- test/smoke/src/tests/git.ts | 4 +-- test/smoke/src/tests/integrated-terminal.ts | 4 +-- test/smoke/src/tests/javascript-debug.ts | 4 +-- test/smoke/src/tests/javascript.ts | 4 +-- test/smoke/src/tests/localization.ts | 4 +-- test/smoke/src/tests/search.ts | 4 +-- test/smoke/src/tests/statusbar.ts | 4 +-- test/smoke/src/tests/tasks.ts | 12 +++---- 21 files changed, 91 insertions(+), 112 deletions(-) delete mode 100644 test/smoke/.vscode/launch.json delete mode 100644 test/smoke/.vscode/tasks.json create mode 100644 test/smoke/src/test.ts delete mode 100644 test/smoke/src/tests.ts diff --git a/test/smoke/.vscode/launch.json b/test/smoke/.vscode/launch.json deleted file mode 100644 index 25b4e7e4c0e..00000000000 --- a/test/smoke/.vscode/launch.json +++ /dev/null @@ -1,26 +0,0 @@ -{ - // Use IntelliSense to learn about possible Node.js debug attributes. - // Hover to view descriptions of existing attributes. - // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 - "version": "0.2.0", - "configurations": [ - { - "type": "node", - "request": "launch", - "name": "Mocha Tests", - "program": "${workspaceRoot}/node_modules/mocha/bin/_mocha", - "args": [ - "-u", - "tdd", - "--timeout", - "999999", - "--colors", - "${workspaceRoot}/out/tests.js" - ], - "outFiles": [ "${workspaceRoot}/out/**/*.js" ], - "internalConsoleOptions": "openOnSessionStart", - "sourceMaps": true, - "cwd": "${workspaceRoot}" - } - ] -} \ No newline at end of file diff --git a/test/smoke/.vscode/tasks.json b/test/smoke/.vscode/tasks.json deleted file mode 100644 index 926b1ddcd18..00000000000 --- a/test/smoke/.vscode/tasks.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - // See https://go.microsoft.com/fwlink/?LinkId=733558 - // for the documentation about the tasks.json format - "version": "0.1.0", - "command": "tsc", - "isShellCommand": true, - "args": ["-p", "."], - "showOutput": "silent", - "problemMatcher": "$tsc" -} \ No newline at end of file diff --git a/test/smoke/src/areas/tasks.ts b/test/smoke/src/areas/tasks.ts index d83cc173efa..e0774854f3a 100644 --- a/test/smoke/src/areas/tasks.ts +++ b/test/smoke/src/areas/tasks.ts @@ -15,8 +15,9 @@ export class Tasks { // noop } - public build(): Promise { - return this.spectron.command('workbench.action.tasks.build'); + public async build(): Promise { + await this.spectron.command('workbench.action.tasks.build'); + return this.spectron.wait(); // wait for build to finish } public openProblemsView(): Promise { @@ -25,12 +26,12 @@ export class Tasks { public async firstOutputLineEndsWith(fileName: string): Promise { const firstLine = await this.spectron.waitFor(this.spectron.client.getText, `${this.outputViewSelector}>:nth-child(2)`); - + return firstLine.endsWith(fileName); } public getOutputResult(): Promise { - return this.spectron.waitFor(this.spectron.client.getText, `${this.outputViewSelector}>:nth-child(10) span.mtk1`); + return this.spectron.waitFor(this.spectron.client.getText, `${this.outputViewSelector}>:nth-child(5) span.mtk1`); } public selectOutputViewType(type: string): Promise { @@ -41,7 +42,7 @@ export class Tasks { return this.spectron.client.getValue(`${this.workbenchPanelSelector} .select-box`); } - public getProblemsViewFirstElementName(): Promise { + public getProblemsViewFirstElementName(): Promise { return this.spectron.waitFor(this.spectron.client.getText, `${this.problemsViewSelector} .label-name`); } diff --git a/test/smoke/src/main.js b/test/smoke/src/main.js index 8df41b5c73c..a6acc9a7d89 100644 --- a/test/smoke/src/main.js +++ b/test/smoke/src/main.js @@ -53,7 +53,6 @@ else if (os === 'win32') os = 'win'; var promises = []; try { - // promises.push(execute('npm install'), process.cwd()); promises.push(getKeybindings(`${keybindingsUrl}/doc.keybindings.${os}.json`, `${tempFolder}/keybindings.json`)); promises.push(cleanOrClone(testRepoUrl, testRepoLocalDir)); diff --git a/test/smoke/src/mocha-runner.js b/test/smoke/src/mocha-runner.js index 8ea1dd905aa..39a91bcdbab 100644 --- a/test/smoke/src/mocha-runner.js +++ b/test/smoke/src/mocha-runner.js @@ -14,7 +14,7 @@ var mocha = new Mocha({ useColors: true }); -mocha.addFile(path.join(process.cwd(), 'out/tests.js')); +mocha.addFile(path.join(process.cwd(), 'out/test.js')); mocha.run((failures) => { process.on('exit', () => { process.exit(failures); diff --git a/test/smoke/src/test.ts b/test/smoke/src/test.ts new file mode 100644 index 00000000000..70cc2f5d322 --- /dev/null +++ b/test/smoke/src/test.ts @@ -0,0 +1,36 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { testDataLoss } from "./tests/data-loss"; +import { testDataMigration } from "./tests/data-migration"; +import { testExplorer } from "./tests/explorer"; +import { testConfigViews } from "./tests/configuration-views"; +import { testSearch } from "./tests/search"; +import { testCSS } from "./tests/css"; +import { testJavaScript } from "./tests/javascript"; +import { testJavaScriptDebug } from "./tests/javascript-debug"; +import { testGit } from "./tests/git"; +import { testIntegratedTerminal } from "./tests/integrated-terminal"; +import { testStatusbar } from "./tests/statusbar"; +import { testTasks } from "./tests/tasks"; +import { testExtensions } from "./tests/extensions"; +import { testLocalization } from "./tests/localization"; + +describe('Smoke Test Suite', async () => { + testDataMigration(); + testDataLoss(); + testExplorer(); + testConfigViews(); + testSearch(); + testCSS(); + testJavaScript(); + testJavaScriptDebug(); + testGit(); + testIntegratedTerminal(); + testStatusbar(); + testTasks(); + testExtensions(); + testLocalization(); +}); \ No newline at end of file diff --git a/test/smoke/src/tests.ts b/test/smoke/src/tests.ts deleted file mode 100644 index 17ca694e209..00000000000 --- a/test/smoke/src/tests.ts +++ /dev/null @@ -1,36 +0,0 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ - -import { dataLoss } from "./tests/data-loss"; -import { dataMigration } from "./tests/data-migration"; -import { explorer } from "./tests/explorer"; -import { configurationViews } from "./tests/configuration-views"; -import { search } from "./tests/search"; -import { css } from "./tests/css"; -import { javascript } from "./tests/javascript"; -import { javascriptDebug } from "./tests/javascript-debug"; -import { test_git } from "./tests/git"; -import { integratedTerminal } from "./tests/integrated-terminal"; -import { statusBar } from "./tests/statusbar"; -import { tasks } from "./tests/tasks"; -import { extensions } from "./tests/extensions"; -import { localization } from "./tests/localization"; - -describe('Smoke Test Suite', function () { - dataMigration(); - dataLoss(); - explorer(); - configurationViews(); - search(); - css(); - javascript(); - javascriptDebug(); - test_git(); - integratedTerminal(); - statusBar(); - tasks(); - extensions(); - localization(); -}); \ No newline at end of file diff --git a/test/smoke/src/tests/configuration-views.ts b/test/smoke/src/tests/configuration-views.ts index 2f61f3337fb..e1241b6bfb5 100644 --- a/test/smoke/src/tests/configuration-views.ts +++ b/test/smoke/src/tests/configuration-views.ts @@ -12,8 +12,8 @@ import { ConfigurationView, ActivityBarPosition } from "../areas/configuration-v let app: SpectronApplication; let common: CommonActions; -export function configurationViews() { - context('Configuration and views', function () { +export function testConfigViews() { + context('Configuration and views', () => { let configView: ConfigurationView; beforeEach(async function () { diff --git a/test/smoke/src/tests/css.ts b/test/smoke/src/tests/css.ts index 01a0bddbe25..d91513f5431 100644 --- a/test/smoke/src/tests/css.ts +++ b/test/smoke/src/tests/css.ts @@ -12,8 +12,8 @@ import { CSS, CSSProblem } from '../areas/css'; let app: SpectronApplication; let common: CommonActions; -export function css() { - context('CSS', function () { +export function testCSS() { + context('CSS', () => { let css: CSS; beforeEach(async function () { diff --git a/test/smoke/src/tests/data-loss.ts b/test/smoke/src/tests/data-loss.ts index 4be1635cfce..e1498299e8e 100644 --- a/test/smoke/src/tests/data-loss.ts +++ b/test/smoke/src/tests/data-loss.ts @@ -13,8 +13,8 @@ let app: SpectronApplication; let common: CommonActions; let dl: DataLoss; -export function dataLoss() { - context('Data Loss', function () { +export function testDataLoss() { + context('Data Loss', () => { beforeEach(async function () { app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH], [`--user-data-dir=${USER_DIR}`]); diff --git a/test/smoke/src/tests/data-migration.ts b/test/smoke/src/tests/data-migration.ts index 0dba58deccb..4b8e627bcfe 100644 --- a/test/smoke/src/tests/data-migration.ts +++ b/test/smoke/src/tests/data-migration.ts @@ -11,11 +11,12 @@ import { CommonActions } from '../areas/common'; let app: SpectronApplication; let common: CommonActions; -export function dataMigration() { +export function testDataMigration() { if (!STABLE_PATH) { return; } - context('Data Migration', function () { + + context('Data Migration', () => { afterEach(async function () { await app.stop(); diff --git a/test/smoke/src/tests/explorer.ts b/test/smoke/src/tests/explorer.ts index 83c2d114196..d1a4570f003 100644 --- a/test/smoke/src/tests/explorer.ts +++ b/test/smoke/src/tests/explorer.ts @@ -11,8 +11,9 @@ import { CommonActions } from '../areas/common'; let app: SpectronApplication; let common: CommonActions; -export function explorer() { - context('Explorer', function () { +export function testExplorer() { + context('Explorer', () => { + beforeEach(async function () { app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); common = new CommonActions(app); diff --git a/test/smoke/src/tests/extensions.ts b/test/smoke/src/tests/extensions.ts index a545dd7c674..9e563f2f3c1 100644 --- a/test/smoke/src/tests/extensions.ts +++ b/test/smoke/src/tests/extensions.ts @@ -9,11 +9,18 @@ import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH, EXTENSIONS_DIR } from import { CommonActions } from '../areas/common'; import { Extensions } from "../areas/extensions"; +var dns = require('dns'); + let app: SpectronApplication; let common: CommonActions; -export function extensions() { - context('Extensions', function () { +export async function testExtensions() { + const network = await networkAttached(); + if (!network) { + return; + } + + context('Extensions', () => { let extensions: Extensions; beforeEach(async function () { @@ -54,4 +61,12 @@ export function extensions() { assert.ok(x); }); }); +} + +function networkAttached(): Promise { + return new Promise((res, rej) => { + dns.resolve('marketplace.visualstudio.com', (err) => { + err ? res(false) : res(true); + }); + }); } \ No newline at end of file diff --git a/test/smoke/src/tests/git.ts b/test/smoke/src/tests/git.ts index 11d568c7f8b..cb5e71e7fa3 100644 --- a/test/smoke/src/tests/git.ts +++ b/test/smoke/src/tests/git.ts @@ -12,8 +12,8 @@ import { Git } from "../areas/git"; let app: SpectronApplication; let common: CommonActions; -export function test_git() { - context('Git', function () { +export function testGit() { + context('Git', () => { let git: Git; beforeEach(async function () { diff --git a/test/smoke/src/tests/integrated-terminal.ts b/test/smoke/src/tests/integrated-terminal.ts index 95925d03f96..c05a84e0b2a 100644 --- a/test/smoke/src/tests/integrated-terminal.ts +++ b/test/smoke/src/tests/integrated-terminal.ts @@ -12,8 +12,8 @@ import { IntegratedTerminal } from "../areas/integrated-terminal"; let app: SpectronApplication; let common: CommonActions; -export function integratedTerminal() { - context('Integrated Terminal', function () { +export function testIntegratedTerminal() { + context('Integrated Terminal', () => { let terminal: IntegratedTerminal; beforeEach(async function () { diff --git a/test/smoke/src/tests/javascript-debug.ts b/test/smoke/src/tests/javascript-debug.ts index 7f85ee4f49c..801543f539a 100644 --- a/test/smoke/src/tests/javascript-debug.ts +++ b/test/smoke/src/tests/javascript-debug.ts @@ -12,8 +12,8 @@ import { JavaScriptDebug } from "../areas/javascript-debug"; let app: SpectronApplication; let common: CommonActions; -export function javascriptDebug() { - context('Debugging JavaScript', function () { +export function testJavaScriptDebug() { + context('Debugging JavaScript', () => { let jsDebug: JavaScriptDebug; beforeEach(async function () { diff --git a/test/smoke/src/tests/javascript.ts b/test/smoke/src/tests/javascript.ts index 2d82fde2d4b..490677f1f29 100644 --- a/test/smoke/src/tests/javascript.ts +++ b/test/smoke/src/tests/javascript.ts @@ -12,8 +12,8 @@ import { JavaScript } from "../areas/javascript"; let app: SpectronApplication; let common: CommonActions; -export function javascript() { - context('JavaScript', function () { +export function testJavaScript() { + context('JavaScript', () => { let js: JavaScript; beforeEach(async function () { diff --git a/test/smoke/src/tests/localization.ts b/test/smoke/src/tests/localization.ts index 35a72186e82..3ac81ae2f75 100644 --- a/test/smoke/src/tests/localization.ts +++ b/test/smoke/src/tests/localization.ts @@ -12,8 +12,8 @@ import { Localization, ViewletType } from "../areas/localization"; let app: SpectronApplication; let common: CommonActions; -export function localization() { - context('Localization', function () { +export function testLocalization() { + context('Localization', () => { afterEach(async function () { return await app.stop(); }); diff --git a/test/smoke/src/tests/search.ts b/test/smoke/src/tests/search.ts index 8ab012c9b08..ea2041d3af0 100644 --- a/test/smoke/src/tests/search.ts +++ b/test/smoke/src/tests/search.ts @@ -12,8 +12,8 @@ import { Search } from "../areas/search"; let app: SpectronApplication; let common: CommonActions; -export function search() { - context('Search', function () { +export function testSearch() { + context('Search', () => { let search: Search; beforeEach(async function () { diff --git a/test/smoke/src/tests/statusbar.ts b/test/smoke/src/tests/statusbar.ts index 6fbcf6472c4..86a315daebc 100644 --- a/test/smoke/src/tests/statusbar.ts +++ b/test/smoke/src/tests/statusbar.ts @@ -12,8 +12,8 @@ import { StatusBarElement, StatusBar } from "../areas/statusBar"; let app: SpectronApplication; let common: CommonActions; -export function statusBar() { - context('Status Bar', function () { +export function testStatusbar() { + context('Status Bar', () => { let statusBar: StatusBar; beforeEach(async function () { diff --git a/test/smoke/src/tests/tasks.ts b/test/smoke/src/tests/tasks.ts index c020aceac0c..bbe36ef3968 100644 --- a/test/smoke/src/tests/tasks.ts +++ b/test/smoke/src/tests/tasks.ts @@ -10,8 +10,8 @@ import { Tasks } from "../areas/tasks"; let app: SpectronApplication; -export function tasks() { - context('Tasks', function () { +export function testTasks() { + context('Tasks', () => { let tasks: Tasks; beforeEach(async function () { @@ -24,15 +24,14 @@ export function tasks() { return await app.stop(); }); - it('verifies that build task produces 6 errors', async function () { + it('verifies that eslint task results in 1 problem', async function () { await tasks.build(); const res = await tasks.getOutputResult(); - assert.equal(res, '✖ 6 problems (6 errors, 0 warnings)'); + assert.equal(res, '✖ 1 problem (0 errors, 1 warning)'); }); it(`is able to select 'Git' output`, async function () { await tasks.build(); - await app.wait(); await tasks.selectOutputViewType('Git'); const viewType = await tasks.getOutputViewType(); assert.equal(viewType, 'Git'); @@ -45,12 +44,11 @@ export function tasks() { it(`verifies build errors are reflected in 'Problems View'`, async function () { await tasks.build(); - await app.wait(); await tasks.openProblemsView(); const problemName = await tasks.getProblemsViewFirstElementName(); assert.equal(problemName, 'index.js'); const problemsCount = await tasks.getProblemsViewFirstElementCount(); - assert.equal(problemsCount, '6'); + assert.equal(problemsCount, '1'); }); }); } \ No newline at end of file -- GitLab From e14e783ca890d389a2db4eb22a043aeb10201cd5 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 26 May 2017 11:00:10 +0200 Subject: [PATCH 0192/1347] followup fix from fix #27245 --- src/vs/workbench/api/node/extHostDocumentData.ts | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/api/node/extHostDocumentData.ts b/src/vs/workbench/api/node/extHostDocumentData.ts index e52493a31e0..be60815d553 100644 --- a/src/vs/workbench/api/node/extHostDocumentData.ts +++ b/src/vs/workbench/api/node/extHostDocumentData.ts @@ -242,10 +242,17 @@ export class ExtHostDocumentData extends MirrorModel { private _getWordRangeAtPosition(_position: vscode.Position, regexp?: RegExp): vscode.Range { let position = this._validatePosition(_position); - if (!regexp || regExpLeadsToEndlessLoop(regexp)) { - console.warn(`[getWordRangeAtPosition]: ignoring custom regexp '${regexp.source}' because it matches the empty string.`); + + if (!regexp) { + // use default when custom-regexp isn't provided + regexp = getWordDefinitionFor(this._languageId); + + } else if (regExpLeadsToEndlessLoop(regexp)) { + // use default when custom-regexp is bad regexp = getWordDefinitionFor(this._languageId); + console.warn(`[getWordRangeAtPosition]: ignoring custom regexp '${regexp.source}' because it matches the empty string.`); } + let wordAtText = getWordAtText( position.character + 1, ensureValidWordDefinition(regexp), -- GitLab From 7e68adad6427a6e9745a9e43af5bf17a3f3b0a7b Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 26 May 2017 11:07:17 +0200 Subject: [PATCH 0193/1347] simplify tests, fix tests, promise ftw --- .../vscode-api-tests/src/languages.test.ts | 33 +++++++------------ .../workbench/api/node/extHostDocumentData.ts | 2 +- 2 files changed, 13 insertions(+), 22 deletions(-) diff --git a/extensions/vscode-api-tests/src/languages.test.ts b/extensions/vscode-api-tests/src/languages.test.ts index d4a0c80130e..321b1b772f2 100644 --- a/extensions/vscode-api-tests/src/languages.test.ts +++ b/extensions/vscode-api-tests/src/languages.test.ts @@ -14,7 +14,7 @@ import { suite('languages namespace tests', () => { - test('diagnostics & CodeActionProvider', function (done) { + test('diagnostics & CodeActionProvider', function () { class D2 extends Diagnostic { customProp = { complex() { } }; @@ -54,20 +54,15 @@ suite('languages namespace tests', () => { let r4 = languages.createDiagnosticCollection(); r4.set(uri, [diag2]); - workspace.openTextDocument(uri).then(doc => { + return workspace.openTextDocument(uri).then(doc => { return commands.executeCommand('vscode.executeCodeActionProvider', uri, new Range(0, 0, 0, 10)); }).then(commands => { - try { - assert.ok(ran); - Disposable.from(r1, r2, r3, r4).dispose(); - done(); - } catch (e) { - done(e); - } - }, done); + assert.ok(ran); + Disposable.from(r1, r2, r3, r4).dispose(); + }); }); - test('completions with document filters', function (done) { + test('completions with document filters', function () { let ran = false; let uri = Uri.file(join(workspace.rootPath || '', './bower.json')); @@ -82,17 +77,13 @@ suite('languages namespace tests', () => { } }); - workspace.openTextDocument(uri).then(doc => { + return workspace.openTextDocument(uri).then(doc => { return commands.executeCommand('vscode.executeCompletionItemProvider', uri, new Position(1, 0)); }).then((result: CompletionList) => { - try { - assert.equal(result.items[0].label, 'foo'); - assert.ok(ran); - Disposable.from(r1).dispose(); - done(); - } catch (e) { - done(e); - } - }, done); + r1.dispose(); + assert.ok(ran); + console.log(result.items); + assert.equal(result.items[0].label, 'foo'); + }); }); }); diff --git a/src/vs/workbench/api/node/extHostDocumentData.ts b/src/vs/workbench/api/node/extHostDocumentData.ts index be60815d553..edb38779935 100644 --- a/src/vs/workbench/api/node/extHostDocumentData.ts +++ b/src/vs/workbench/api/node/extHostDocumentData.ts @@ -249,8 +249,8 @@ export class ExtHostDocumentData extends MirrorModel { } else if (regExpLeadsToEndlessLoop(regexp)) { // use default when custom-regexp is bad - regexp = getWordDefinitionFor(this._languageId); console.warn(`[getWordRangeAtPosition]: ignoring custom regexp '${regexp.source}' because it matches the empty string.`); + regexp = getWordDefinitionFor(this._languageId); } let wordAtText = getWordAtText( -- GitLab From d3ba078be9c1afa09be4d73201da3534d37f1762 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Fri, 26 May 2017 11:18:40 +0200 Subject: [PATCH 0194/1347] Code sanity. --- test/smoke/src/main.js | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/test/smoke/src/main.js b/test/smoke/src/main.js index a6acc9a7d89..85e3778d1a7 100644 --- a/test/smoke/src/main.js +++ b/test/smoke/src/main.js @@ -10,7 +10,7 @@ var git = require('simple-git')(); var child_process = require('child_process'); var path = require('path'); -var tempFolder = `test_data`; +var tempFolder = 'test_data'; var testRepoUrl = 'https://github.com/Microsoft/vscode-smoketest-express'; var testRepoLocalDir = path.join(process.cwd(), `${tempFolder}/vscode-smoketest-express`); var keybindingsUrl = 'https://raw.githubusercontent.com/Microsoft/vscode-docs/master/scripts/keybindings'; @@ -41,10 +41,10 @@ if (!binaryExists(program.latest) || (program.stable && !binaryExists(program.st } // Setting up environment variables -process.env['VSCODE_LATEST_PATH'] = program.latest; -if (program.stable) process.env['VSCODE_STABLE_PATH'] = program.stable; -process.env['SMOKETEST_REPO'] = testRepoLocalDir; -if (program.stable && program.stable.toLowerCase().startsWith('insiders')) process.env['VSCODE_EDITION'] = 'insiders'; +process.env.VSCODE_LATEST_PATH = program.latest; +if (program.stable) process.env.VSCODE_STABLE_PATH = program.stable; +process.env.SMOKETEST_REPO = testRepoLocalDir; +if (program.stable && program.stable.toLowerCase().startsWith('insiders')) process.env.VSCODE_EDITION = 'insiders'; // Setting up 'vscode-smoketest-express' project var os = process.platform; @@ -112,7 +112,7 @@ function cleanOrClone(repo, dir) { function execute(cmd, dir) { return new Promise((res, rej) => { console.log(`Running ${cmd}...`); - var output = child_process.exec(cmd, { cwd: dir, stdio: [0, 1, 2] }, (error, stdout, stderr) => { + child_process.exec(cmd, { cwd: dir, stdio: [0, 1, 2] }, (error, stdout, stderr) => { if (error) rej(error); if (stderr) console.error(stderr); console.log(stdout); -- GitLab From b2b81e4f3eb16074407f86340554d58e71a3f1b6 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 26 May 2017 11:31:28 +0200 Subject: [PATCH 0195/1347] fix #27231 --- .../api/electron-browser/mainThreadDocuments.ts | 6 +++--- src/vs/workbench/api/node/extHost.protocol.ts | 3 +-- src/vs/workbench/api/node/extHostDocuments.ts | 17 ++++++++--------- 3 files changed, 12 insertions(+), 14 deletions(-) diff --git a/src/vs/workbench/api/electron-browser/mainThreadDocuments.ts b/src/vs/workbench/api/electron-browser/mainThreadDocuments.ts index 120beef086f..13e61675fa4 100644 --- a/src/vs/workbench/api/electron-browser/mainThreadDocuments.ts +++ b/src/vs/workbench/api/electron-browser/mainThreadDocuments.ts @@ -123,12 +123,12 @@ export class MainThreadDocuments extends MainThreadDocumentsShape { })); this._toDispose.push(textFileService.models.onModelReverted(e => { if (this._shouldHandleFileEvent(e)) { - this._proxy.$acceptModelReverted(e.resource.toString()); + this._proxy.$acceptDirtyStateChanged(e.resource.toString(), false); } })); this._toDispose.push(textFileService.models.onModelDirty(e => { if (this._shouldHandleFileEvent(e)) { - this._proxy.$acceptModelDirty(e.resource.toString()); + this._proxy.$acceptDirtyStateChanged(e.resource.toString(), true); } })); @@ -240,7 +240,7 @@ export class MainThreadDocuments extends MainThreadDocumentsShape { if (!this._modelIsSynced[input.getResource().toString()]) { throw new Error(`expected URI ${input.getResource().toString()} to have come to LIFE`); } - return this._proxy.$acceptModelDirty(input.getResource().toString()); // mark as dirty + return this._proxy.$acceptDirtyStateChanged(input.getResource().toString(), true); // mark as dirty }).then(() => { return input.getResource(); }); diff --git a/src/vs/workbench/api/node/extHost.protocol.ts b/src/vs/workbench/api/node/extHost.protocol.ts index f9c02d01d8c..b168ae2ddac 100644 --- a/src/vs/workbench/api/node/extHost.protocol.ts +++ b/src/vs/workbench/api/node/extHost.protocol.ts @@ -371,8 +371,7 @@ export abstract class ExtHostDocumentsShape { $provideTextDocumentContent(handle: number, uri: URI): TPromise { throw ni(); } $acceptModelModeChanged(strURL: string, oldModeId: string, newModeId: string): void { throw ni(); } $acceptModelSaved(strURL: string): void { throw ni(); } - $acceptModelDirty(strURL: string): void { throw ni(); } - $acceptModelReverted(strURL: string): void { throw ni(); } + $acceptDirtyStateChanged(strURL: string, isDirty: boolean): void { throw ni(); } $acceptModelChanged(strURL: string, e: IModelChangedEvent, isDirty: boolean): void { throw ni(); } } diff --git a/src/vs/workbench/api/node/extHostDocuments.ts b/src/vs/workbench/api/node/extHostDocuments.ts index 918efad51f3..eacff1334c5 100644 --- a/src/vs/workbench/api/node/extHostDocuments.ts +++ b/src/vs/workbench/api/node/extHostDocuments.ts @@ -171,18 +171,17 @@ export class ExtHostDocuments extends ExtHostDocumentsShape { public $acceptModelSaved(strURL: string): void { let data = this._documentsAndEditors.getDocument(strURL); - data._acceptIsDirty(false); + this.$acceptDirtyStateChanged(strURL, false); this._onDidSaveDocument.fire(data.document); } - public $acceptModelDirty(strURL: string): void { - let document = this._documentsAndEditors.getDocument(strURL); - document._acceptIsDirty(true); - } - - public $acceptModelReverted(strURL: string): void { - let document = this._documentsAndEditors.getDocument(strURL); - document._acceptIsDirty(false); + public $acceptDirtyStateChanged(strURL: string, isDirty: boolean): void { + let data = this._documentsAndEditors.getDocument(strURL); + data._acceptIsDirty(isDirty); + this._onDidChangeDocument.fire({ + document: data.document, + contentChanges: [] + }); } public $acceptModelChanged(strURL: string, events: IModelChangedEvent, isDirty: boolean): void { -- GitLab From 3022b4cde49d380f1f4d609b567b152fdf7c80f0 Mon Sep 17 00:00:00 2001 From: YukiUeda Date: Fri, 26 May 2017 19:18:05 +0900 Subject: [PATCH 0196/1347] support %%(fix #26825) --- extensions/bat/syntaxes/Batch File.tmLanguage | 22 +++++++++---------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/extensions/bat/syntaxes/Batch File.tmLanguage b/extensions/bat/syntaxes/Batch File.tmLanguage index 49909636404..7f0a1061423 100644 --- a/extensions/bat/syntaxes/Batch File.tmLanguage +++ b/extensions/bat/syntaxes/Batch File.tmLanguage @@ -74,13 +74,18 @@ 1 name - variable.parameter.loop.begin.shell + variable.other.parsetime.begin.shell + + 2 + + name + variable.other.parsetime.end.shell name - variable.parameter.loop.dosbatch + variable.other.parsetime.dosbatch match - (?i)(%%)(~(?:f|d|p|n|x|s|a|t|z|\$[^:]*:)*)?[a-z] + (%)[^%]+(%)|(%%)[^%]+(%%) captures @@ -88,18 +93,13 @@ 1 name - variable.other.parsetime.begin.shell - - 2 - - name - variable.other.parsetime.end.shell + variable.parameter.loop.begin.shell name - variable.other.parsetime.dosbatch + variable.parameter.loop.dosbatch match - (%)[^%]+(%) + (?i)(%%)(~(?:f|d|p|n|x|s|a|t|z|\$[^:]*:)*)?[a-z] captures -- GitLab From e81c07d7c23145ea726a4534b46fed0539b9b7df Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 26 May 2017 12:28:31 +0200 Subject: [PATCH 0197/1347] snippets - fix leaking listeners that break subsequent snippet insertion --- .../contrib/snippet/browser/snippetController2.ts | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/src/vs/editor/contrib/snippet/browser/snippetController2.ts b/src/vs/editor/contrib/snippet/browser/snippetController2.ts index 3983e58599e..73946415785 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetController2.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetController2.ts @@ -62,12 +62,16 @@ export class SnippetController2 { if (!this._snippet) { // create a new session this._snippet = new SnippetSession(this._editor); + this._snippet.insert(template, overwriteBefore, overwriteAfter); + this._snippetListener = [ + this._editor.onDidChangeModel(() => this.cancel()), + this._editor.onDidChangeCursorSelection(() => this._updateState()) + ]; + } else { + // only insert the snippet when a session + // is already active + this._snippet.insert(template, overwriteBefore, overwriteAfter); } - this._snippet.insert(template, overwriteBefore, overwriteAfter); - this._snippetListener = [ - this._editor.onDidChangeModel(() => this.cancel()), - this._editor.onDidChangeCursorSelection(() => this._updateState()) - ]; if (undoStopAfter) { this._editor.getModel().pushStackElement(); } -- GitLab From 8973edf9cc024896eceda82630ce3660083285bc Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Mon, 22 May 2017 13:56:23 +0200 Subject: [PATCH 0198/1347] Added smoke test source code. --- smoketest/.gitignore | 7 + smoketest/.vscode/launch.json | 26 + smoketest/.vscode/tasks.json | 10 + smoketest/CONTRIBUTING.md | 12 + smoketest/README.md | 10 + smoketest/package.json | 19 + smoketest/scripts/run.ps1 | 43 ++ smoketest/scripts/run.sh | 43 ++ smoketest/src/areas/common.ts | 163 +++++ smoketest/src/areas/configuration-views.ts | 62 ++ smoketest/src/areas/css.ts | 62 ++ smoketest/src/areas/data-loss.ts | 26 + smoketest/src/areas/extensions.ts | 49 ++ smoketest/src/areas/first-experience.ts | 21 + smoketest/src/areas/git.ts | 69 ++ smoketest/src/areas/integrated-terminal.ts | 38 + smoketest/src/areas/javascript-debug.ts | 42 ++ smoketest/src/areas/javascript.ts | 73 ++ smoketest/src/areas/localization.ts | 55 ++ smoketest/src/areas/search.ts | 50 ++ smoketest/src/areas/statusbar.ts | 99 +++ smoketest/src/areas/tasks.ts | 50 ++ smoketest/src/helpers/screenshot.ts | 48 ++ smoketest/src/helpers/utilities.ts | 37 + smoketest/src/main.ts | 771 +++++++++++++++++++++ smoketest/src/spectron/application.ts | 156 +++++ smoketest/src/spectron/client.ts | 127 ++++ smoketest/tsconfig.json | 21 + vscode-smoketest-express | 1 + 29 files changed, 2190 insertions(+) create mode 100644 smoketest/.gitignore create mode 100644 smoketest/.vscode/launch.json create mode 100644 smoketest/.vscode/tasks.json create mode 100644 smoketest/CONTRIBUTING.md create mode 100644 smoketest/README.md create mode 100644 smoketest/package.json create mode 100644 smoketest/scripts/run.ps1 create mode 100644 smoketest/scripts/run.sh create mode 100644 smoketest/src/areas/common.ts create mode 100644 smoketest/src/areas/configuration-views.ts create mode 100644 smoketest/src/areas/css.ts create mode 100644 smoketest/src/areas/data-loss.ts create mode 100644 smoketest/src/areas/extensions.ts create mode 100644 smoketest/src/areas/first-experience.ts create mode 100644 smoketest/src/areas/git.ts create mode 100644 smoketest/src/areas/integrated-terminal.ts create mode 100644 smoketest/src/areas/javascript-debug.ts create mode 100644 smoketest/src/areas/javascript.ts create mode 100644 smoketest/src/areas/localization.ts create mode 100644 smoketest/src/areas/search.ts create mode 100644 smoketest/src/areas/statusbar.ts create mode 100644 smoketest/src/areas/tasks.ts create mode 100644 smoketest/src/helpers/screenshot.ts create mode 100644 smoketest/src/helpers/utilities.ts create mode 100644 smoketest/src/main.ts create mode 100644 smoketest/src/spectron/application.ts create mode 100644 smoketest/src/spectron/client.ts create mode 100644 smoketest/tsconfig.json create mode 160000 vscode-smoketest-express diff --git a/smoketest/.gitignore b/smoketest/.gitignore new file mode 100644 index 00000000000..532798d3ea9 --- /dev/null +++ b/smoketest/.gitignore @@ -0,0 +1,7 @@ +.DS_Store +npm-debug.log +Thumbs.db +node_modules/ +out/ +keybindings.*.json +test_data/ \ No newline at end of file diff --git a/smoketest/.vscode/launch.json b/smoketest/.vscode/launch.json new file mode 100644 index 00000000000..2de33bbb20b --- /dev/null +++ b/smoketest/.vscode/launch.json @@ -0,0 +1,26 @@ +{ + // Use IntelliSense to learn about possible Node.js debug attributes. + // Hover to view descriptions of existing attributes. + // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 + "version": "0.2.0", + "configurations": [ + { + "type": "node", + "request": "launch", + "name": "Mocha Tests", + "program": "${workspaceRoot}/node_modules/mocha/bin/_mocha", + "args": [ + "-u", + "tdd", + "--timeout", + "999999", + "--colors", + "${workspaceRoot}/out/main.js" + ], + "outFiles": [ "${workspaceRoot}/out/**/*.js" ], + "internalConsoleOptions": "openOnSessionStart", + "sourceMaps": true, + "cwd": "${workspaceRoot}" + } + ] +} \ No newline at end of file diff --git a/smoketest/.vscode/tasks.json b/smoketest/.vscode/tasks.json new file mode 100644 index 00000000000..926b1ddcd18 --- /dev/null +++ b/smoketest/.vscode/tasks.json @@ -0,0 +1,10 @@ +{ + // See https://go.microsoft.com/fwlink/?LinkId=733558 + // for the documentation about the tasks.json format + "version": "0.1.0", + "command": "tsc", + "isShellCommand": true, + "args": ["-p", "."], + "showOutput": "silent", + "problemMatcher": "$tsc" +} \ No newline at end of file diff --git a/smoketest/CONTRIBUTING.md b/smoketest/CONTRIBUTING.md new file mode 100644 index 00000000000..c15016dc1ad --- /dev/null +++ b/smoketest/CONTRIBUTING.md @@ -0,0 +1,12 @@ +# Architecture +* `main.ts` contains the main smoke test suite. It includes all tests separated into mocha `describe()` groups that represent each of the areas of [Smoke Test document](https://github.com/Microsoft/vscode/wiki/Smoke-Test). + +* `./areas/` folder contains a `.ts` file per each area of the document. E.g. `'Search'` area goes under `'search.ts'`. Every area file contains a list of methods with the name that represents the action that can be performed in the corresponding test. This reduces the amount of test suite code and means that if the UI changes, the fix need only be applied in one place. The name of the method reflects the action the tester would do if he would perform the test manually. See [Selenium Page Objects Wiki](https://github.com/SeleniumHQ/selenium/wiki/PageObjects) and [Selenium Bot Style Tests Wiki](https://github.com/SeleniumHQ/selenium/wiki/Bot-Style-Tests) for a good explanation of the implementation. Every smoke test area contains methods that are used in a bot-style approach in `main.ts`. +* `./spectron/` wraps the Spectron, with WebDriverIO API wrapped in `client.ts` and instance of Spectron Application is wrapped in `application.ts`. +* `./scripts/` contains scripts to run the smoke test. + +# Adding new area +To contribute a new smoke test area, add `${area}.ts` file under `./areas`. This has to follow the bot-style approach described in the links mentioned above. Methods should be calling WebDriverIO API through `SpectronClient` class. If there is no existing WebDriverIO method, add it to the class. + +# Adding new test +To add new test area or test, `main.ts` should be updated. The same instruction-style principle needs to be followed with the called area method names that reflect manual tester's actions. \ No newline at end of file diff --git a/smoketest/README.md b/smoketest/README.md new file mode 100644 index 00000000000..318ddb07517 --- /dev/null +++ b/smoketest/README.md @@ -0,0 +1,10 @@ +# VS Code Smoke Testing +This repository contains the smoke test automation code with Spectron for Visual Studio Code. + +The following command is used to run the tests: `.\scripts\run.ps1 -latest "path\to\Code.exe"` on Windows (from PowerShell) and `./scripts/run.sh path/to/binary` on Unix system. + +If you want to include 'Data Migration' area tests use `.\scripts\run.ps1 -latest "path\to\Code.exe" -stable "path\to\CurrentStable.exe"` and `./scripts/run.sh path/to/binary path/to/currentStable` respectively. + +# Contributing + +This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments. diff --git a/smoketest/package.json b/smoketest/package.json new file mode 100644 index 00000000000..a5c3a78273b --- /dev/null +++ b/smoketest/package.json @@ -0,0 +1,19 @@ +{ + "name": "code-oss-dev-smoke-test", + "version": "0.1.0", + "main": "./out/main.js", + "scripts": { + "test": "mocha -u tdd --timeout 360000 --retries 2 --slow 50000 --colors ./out/main.js 2> test_data/errors.log" + }, + "devDependencies": { + "@types/mocha": "^2.2.41", + "@types/node": "^6.0.70", + "@types/webdriverio": "^4.6.1", + "@types/electron": "^1.4.37", + "@types/rimraf": "^0.0.28", + "mocha": "^3.2.0", + "spectron": "^3.6.4", + "typescript": "^2.2.2", + "rimraf": "^2.6.1" + } +} diff --git a/smoketest/scripts/run.ps1 b/smoketest/scripts/run.ps1 new file mode 100644 index 00000000000..d6368da6890 --- /dev/null +++ b/smoketest/scripts/run.ps1 @@ -0,0 +1,43 @@ +Param( + [Parameter(Position=0,mandatory=$true)] + [string] $latest, + [Parameter(Position=1,mandatory=$false)] + [string] $stable +) + +# Setup sample repository for the smoke test +Set-Location .. +if (-Not (Test-Path vscode-smoketest-express)) { + git clone https://github.com/Microsoft/vscode-smoketest-express.git + Set-Location ./vscode-smoketest-express +} else { + Set-Location ./vscode-smoketest-express + git fetch origin master + git reset --hard FETCH_HEAD + git clean -fd +} +npm install + +# Setup the test directory for running +Set-Location ..\smoketest +if (-Not (Test-Path node_modules)) { + npm install +} + +# Configure environment variables +$env:VSCODE_LATEST_PATH = $latest +$env:VSCODE_STABLE_PATH = $stable +$env:SMOKETEST_REPO = "..\vscode-smoketest-express" + +if ($latest.Contains('Insiders')) { + $env:VSCODE_EDITION = 'insiders' +} + +# Retrieve key bindings config file for Windows +$testDirectory = (Resolve-Path .\).Path +$client = New-Object System.Net.WebClient +$client.DownloadFile("https://raw.githubusercontent.com/Microsoft/vscode-docs/master/scripts/keybindings/doc.keybindings.win.json","$testDirectory\test_data\keybindings.win32.json") + +# Compile and launch the smoke test +tsc +npm test \ No newline at end of file diff --git a/smoketest/scripts/run.sh b/smoketest/scripts/run.sh new file mode 100644 index 00000000000..fc103a55539 --- /dev/null +++ b/smoketest/scripts/run.sh @@ -0,0 +1,43 @@ +#!/usr/bin/env bash +if [[ "$#" -ne 1 ]]; then + echo "Usage: ./scripts/run.sh path/to/binary" + echo "To perform data migration tests, use: ./scripts/run.sh path/to/latest_binary path/to/stable_binary" + exit 1 +fi + +# Cloning sample repository for the smoke test +cd .. +if ! [ -d vscode-smoketest-express ]; then + git clone https://github.com/Microsoft/vscode-smoketest-express.git + cd vscode-smoketest-express +else + cd vscode-smoketest-express + git fetch origin master + git reset --hard FETCH_HEAD + git clean -fd +fi +npm install + +# Install Node modules for Spectron +cd ../vscode-smoketest +test -d node_modules || npm install + +# Configuration +export VSCODE_LATEST_PATH="$1" +export VSCODE_STABLE_PATH="$2" +export SMOKETEST_REPO="../vscode-smoketest-express" +mkdir -p test_data + +if [[ $1 == *"Insiders"* || $1 == *"insiders"* ]]; then + export VSCODE_EDITION="insiders" +fi + +if [[ "$OSTYPE" == "darwin"* ]]; then + curl "https://raw.githubusercontent.com/Microsoft/vscode-docs/master/scripts/keybindings/doc.keybindings.osx.json" -o "test_data/keybindings.darwin.json" # Download OS X keybindings +else + wget https://raw.githubusercontent.com/Microsoft/vscode-docs/master/scripts/keybindings/doc.keybindings.linux.json -O test_data/keybindings.linux.json # Download Linux keybindings +fi + +# Compile and launch the smoke test +tsc +exec npm test diff --git a/smoketest/src/areas/common.ts b/smoketest/src/areas/common.ts new file mode 100644 index 00000000000..c955c206eea --- /dev/null +++ b/smoketest/src/areas/common.ts @@ -0,0 +1,163 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from "../spectron/application"; +import { Util } from '../helpers/utilities'; + +/** + * Contains methods that are commonly used across test areas. + */ +export class CommonActions { + private util: Util; + + constructor(private spectron: SpectronApplication) { + this.util = new Util(); + } + + public async getWindowTitle(): Promise { + return this.spectron.client.getTitle(); + } + + public enter(): Promise { + return this.spectron.client.keys(['Enter', 'NULL']); + } + + public async addSetting(setting: string, value: string): Promise { + await this.spectron.command('workbench.action.openGlobalSettings'); + await this.spectron.wait(); + await this.spectron.client.leftClick('.editable-preferences-editor-container .view-lines', 1, 1, false); + await this.spectron.client.keys(['ArrowDown', 'NULL', 'ArrowDown', 'NULL'], false); + await this.spectron.wait(); + await this.spectron.client.keys(`"${setting}": "${value}"`); + await this.spectron.wait(); + return this.saveOpenedFile(); + } + + public async newUntitledFile(): Promise { + await this.spectron.command('workbench.action.files.newUntitledFile'); + return this.spectron.wait(); + } + + public closeTab(): Promise { + return this.spectron.client.keys(['Control', 'w', 'NULL']); + } + + public async getTab(tabName: string, active?: boolean): Promise { + let tabSelector = active ? '.tab.active' : 'div'; + let el = await this.spectron.client.element(`.tabs-container ${tabSelector}[aria-label="${tabName}, tab"]`); + if (el.status === 0) { + return el; + } + + return undefined; + } + + public selectTab(tabName: string): Promise { + return this.spectron.client.click(`.tabs-container div[aria-label="${tabName}, tab"]`); + } + + public async openFirstMatchFile(fileName: string): Promise { + await this.openQuickOpen(); + await this.type(fileName); + await this.spectron.wait(); + await this.enter(); + return this.spectron.wait(); + } + + public saveOpenedFile(): Promise { + return this.spectron.command('workbench.action.files.save'); + } + + public type(text: string): Promise { + let spectron = this.spectron; + + return new Promise(function (res) { + let textSplit = text.split(' '); + + async function type(i: number) { + if (!textSplit[i] || textSplit[i].length <= 0) { + return res(); + } + + const toType = textSplit[i + 1] ? `${textSplit[i]} ` : textSplit[i]; + await spectron.client.keys(toType, false); + await spectron.client.keys(['NULL']); + await type(i + 1); + } + + return type(0); + }); + } + + public showCommands(): Promise { + return this.spectron.command('workbench.action.showCommands'); + } + + public openQuickOpen(): Promise { + return this.spectron.command('workbench.action.quickOpen'); + } + + public closeQuickOpen(): Promise { + return this.spectron.command('workbench.action.closeQuickOpen'); + } + + public selectNextQuickOpenElement(): Promise { + return this.spectron.client.keys(['ArrowDown', 'NULL']); + } + + public async getQuickOpenElements(): Promise { + const elements = await this.spectron.waitFor(this.spectron.client.elements, 'div[aria-label="Quick Picker"] .monaco-tree-rows.show-twisties .monaco-tree-row'); + return elements.value.length; + } + + public async openFile(fileName: string, explorer?: boolean): Promise { + let selector = `div[class="monaco-icon-label file-icon ${fileName}-name-file-icon ${this.getExtensionSelector(fileName)}`; + if (explorer) { + selector += ' explorer-item'; + } + selector += '"]'; + + await this.spectron.waitFor(this.spectron.client.doubleClick, selector); + return this.spectron.wait(); + } + + public getExtensionSelector(fileName: string): string { + const extension = fileName.split('.')[1]; + if (extension === 'js') { + return 'js-ext-file-icon javascript-lang-file-icon'; + } else if (extension === 'json') { + return 'json-ext-file-icon json-lang-file-icon'; + } else if (extension === 'md') { + return 'md-ext-file-icon markdown-lang-file-icon'; + } + + throw new Error('No class defined for this file extension'); + } + + public async getEditorFirstLinePlainText(): Promise { + try { + const span = await this.spectron.client.getText('.view-lines span span'); + if (Array.isArray(span)) { + return span[0]; + } + + return span; + } catch (e) { + return undefined; + } + } + + public removeFile(filePath: string): void { + this.util.removeFile(filePath); + } + + public removeDirectory(directory: string): Promise { + try { + return this.util.rimraf(directory); + } catch (e) { + throw new Error(`Failed to remove ${directory} with an error: ${e}`); + } + } +} \ No newline at end of file diff --git a/smoketest/src/areas/configuration-views.ts b/smoketest/src/areas/configuration-views.ts new file mode 100644 index 00000000000..1291469c849 --- /dev/null +++ b/smoketest/src/areas/configuration-views.ts @@ -0,0 +1,62 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; + +export enum ActivityBarPosition { + LEFT = 0, + RIGHT = 1 +}; + +export class ConfigurationView { + // Stores key binding defined for the toggle of activity bar position + private keybinding: string[]; + + constructor(private spectron: SpectronApplication) { + // noop + } + + public getEditorLineNumbers(): any { + return this.spectron.client.elements('.line-numbers'); + } + + public enterKeybindingsView(): any { + return this.spectron.command('workbench.action.openGlobalKeybindings'); + } + + public selectFirstKeybindingsMatch(): any { + return this.spectron.waitFor(this.spectron.client.click, 'div[aria-label="Keybindings"] .monaco-list-row.keybinding-item'); + } + + public changeKeybinding(): any { + return this.spectron.command('editor.action.defineKeybinding'); + } + + public enterBinding(keys: string[]): any { + this.keybinding = keys; + return this.spectron.client.keys(keys); + } + + public toggleActivityBarPosition(): any { + return this.spectron.client.keys(this.keybinding); + } + + public async getActivityBar(position: ActivityBarPosition) { + let positionClass: string; + + if (position === ActivityBarPosition.LEFT) { + positionClass = 'left'; + } else if (position === ActivityBarPosition.RIGHT) { + positionClass = 'right'; + } else { + throw new Error('No such position for activity bar defined.'); + } + try { + return await this.spectron.waitFor(this.spectron.client.getHTML, `.part.activitybar.${positionClass}`); + } catch (e) { + return undefined; + }; + } +} \ No newline at end of file diff --git a/smoketest/src/areas/css.ts b/smoketest/src/areas/css.ts new file mode 100644 index 00000000000..3388ab4e465 --- /dev/null +++ b/smoketest/src/areas/css.ts @@ -0,0 +1,62 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; + +export enum CSSProblem { + WARNING = 0, + ERROR = 1 +}; + +export class CSS { + + constructor(private spectron: SpectronApplication) { + // noop + } + + public openQuickOutline(): any { + return this.spectron.command('workbench.action.gotoSymbol'); + } + + public toggleProblemsView(): any { + return this.spectron.command('workbench.actions.view.problems'); + } + + public async getEditorProblem(problemType: CSSProblem): Promise { + let selector; + if (problemType === CSSProblem.WARNING) { + selector = 'greensquiggly'; + } else if (problemType === CSSProblem.ERROR) { + selector = 'redsquiggly'; + } else { + throw new Error('No such problem type defined.'); + } + + let el = await this.spectron.client.element(`.view-overlays .cdr.${selector}`); + if (el.status === 0) { + return el; + } + + return undefined; + } + + public async getProblemsViewsProblem(problemType: CSSProblem): Promise { + let selector; + if (problemType === CSSProblem.WARNING) { + selector = 'warning'; + } else if (problemType === CSSProblem.ERROR) { + selector = 'error'; + } else { + throw new Error('No such problem type defined.'); + } + + let el = await this.spectron.client.element(`div[aria-label="Problems grouped by files"] .icon.${selector}`); + if (el.status === 0) { + return el; + } + + return undefined; + } +} \ No newline at end of file diff --git a/smoketest/src/areas/data-loss.ts b/smoketest/src/areas/data-loss.ts new file mode 100644 index 00000000000..dc1ecf93730 --- /dev/null +++ b/smoketest/src/areas/data-loss.ts @@ -0,0 +1,26 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from "../spectron/application"; + +export class DataLoss { + + constructor(private spectron: SpectronApplication) { + } + + public openExplorerViewlet(): Promise { + return this.spectron.command('workbench.view.explorer'); + } + + public async verifyTabIsDirty(tabName: string, active?: boolean): Promise { + let activeSelector = active ? '.active' : ''; + let el = await this.spectron.client.element(`.tabs-container .tab.dirty${activeSelector}[aria-label="${tabName}, tab"]`); + if (el.status === 0) { + return el; + } + + return undefined; + } +} \ No newline at end of file diff --git a/smoketest/src/areas/extensions.ts b/smoketest/src/areas/extensions.ts new file mode 100644 index 00000000000..4edec9d06ef --- /dev/null +++ b/smoketest/src/areas/extensions.ts @@ -0,0 +1,49 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; +import { CommonActions } from "./common"; + +export class Extensions { + + private readonly extensionsViewletSelector = 'div[id="workbench.view.extensions"]'; + + constructor(private spectron: SpectronApplication, private common: CommonActions) { + } + + public async openExtensionsViewlet(): Promise { + await this.spectron.command('workbench.view.extensions'); + return this.spectron.wait(); + } + + public async searchForExtension(name: string): Promise { + const searchBoxSelector = `${this.extensionsViewletSelector} .search-box`; + + await this.spectron.client.clearElement(searchBoxSelector); + await this.spectron.client.click(searchBoxSelector, false); + await this.spectron.client.keys(name); + return this.spectron.client.keys(['NULL', 'Enter', 'NULL']); + } + + public installFirstResult(): Promise { + return this.spectron.client.click(`${this.extensionsViewletSelector} .monaco-list-rows>:nth-child(1) .extension .extension-action.install`); + } + + public getFirstReloadText(): Promise { + return this.spectron.waitFor(this.spectron.client.getText, `${this.extensionsViewletSelector} .monaco-list-rows>:nth-child(1) .extension .extension-action.reload`); + } + + public async selectMinimalIconsTheme(): Promise { + await this.common.showCommands(); + await this.common.type('File Icon Theme'); + await this.spectron.wait(); + await this.common.enter(); + return this.spectron.client.keys(['ArrowDown', 'NULL', 'Enter', 'NULL']); + } + + public async verifyFolderIconAppearance(): Promise { + return this.spectron.waitFor(this.spectron.client.getHTML, 'style[class="contributedIconTheme"]'); + } +} \ No newline at end of file diff --git a/smoketest/src/areas/first-experience.ts b/smoketest/src/areas/first-experience.ts new file mode 100644 index 00000000000..e9141bda899 --- /dev/null +++ b/smoketest/src/areas/first-experience.ts @@ -0,0 +1,21 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from "../spectron/application"; + +export class FirstExperience { + constructor(private spectron: SpectronApplication) { + // noop + } + + public async getWelcomeTab(): Promise { + let el = await this.spectron.client.element('.vs_code_welcome_page-name-file-icon'); + if (el.status === 0) { + return el; + } + + return undefined; + } +} \ No newline at end of file diff --git a/smoketest/src/areas/git.ts b/smoketest/src/areas/git.ts new file mode 100644 index 00000000000..8228771a7d7 --- /dev/null +++ b/smoketest/src/areas/git.ts @@ -0,0 +1,69 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; +import { CommonActions } from "./common"; + +export class Git { + private readonly bodyVarSelector = '.view-lines>:nth-child(6) .mtk11'; + + constructor(private spectron: SpectronApplication, private commonActions: CommonActions) { + // noop + } + + public openGitViewlet(): Promise { + return this.spectron.command('workbench.view.git'); + } + + public getScmIconChanges(): Promise { + return this.spectron.waitFor(this.spectron.client.getText, 'div[id="workbench.parts.activitybar"] .badge.scm-viewlet-label .badge-content'); + } + + public async verifyScmChange(fileName: string): Promise { + let el = await this.spectron.client.element(`div[class="monaco-icon-label file-icon ${fileName}-name-file-icon ${this.commonActions.getExtensionSelector(fileName)}"]`); + if (el.status === 0) { + return el; + } + + return undefined; + } + + public getOriginalAppJsBodyVarName(): Promise { + return this.spectron.waitFor(this.spectron.client.getText, `.editor.original ${this.bodyVarSelector}`); + } + + public getModifiedAppJsBodyVarName(): Promise { + return this.spectron.waitFor(this.spectron.client.getText, `.editor.modified ${this.bodyVarSelector}`); + } + + public async stageFile(fileName: string): Promise { + await this.spectron.client.moveToObject(`div[class="monaco-icon-label file-icon ${fileName}-name-file-icon ${this.commonActions.getExtensionSelector(fileName)}"`); + await this.spectron.client.click('.action-label.icon.contrib-cmd-icon-4'); + return this.spectron.wait(); + } + + public async unstageFile(fileName: string): Promise { + await this.spectron.client.moveToObject(`div[class="monaco-icon-label file-icon ${fileName}-name-file-icon ${this.commonActions.getExtensionSelector(fileName)}"`); + await this.spectron.client.click('.action-label.icon.contrib-cmd-icon-6'); + return this.spectron.wait(); + } + + public getStagedCount(): Promise { + return this.spectron.waitFor(this.spectron.client.getText, '.scm-status.show-file-icons .monaco-list-rows>:nth-child(1) .monaco-count-badge'); + } + + public focusOnCommitBox(): Promise { + return this.spectron.client.click('div[id="workbench.view.scm"] textarea'); + } + + public async pressCommit(): Promise { + await this.spectron.client.click('.action-label.icon.contrib-cmd-icon-10'); + return this.spectron.wait(); + } + + public getOutgoingChanges(): Promise { + return this.spectron.client.getText('a[title="Synchronize changes"]'); + } +} \ No newline at end of file diff --git a/smoketest/src/areas/integrated-terminal.ts b/smoketest/src/areas/integrated-terminal.ts new file mode 100644 index 00000000000..b066db8adf7 --- /dev/null +++ b/smoketest/src/areas/integrated-terminal.ts @@ -0,0 +1,38 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; +import { CommonActions } from "./common"; + +export class IntegratedTerminal { + + constructor(private spectron: SpectronApplication) { + // noop + } + + public async openTerminal(commonActions: CommonActions): Promise { + // Backquote dispatching does not work in OS X + if (process.platform === 'darwin') { + await commonActions.showCommands(); + await commonActions.type('Toggle Integrated Terminal'); + return commonActions.enter(); + } + + return this.spectron.command('workbench.action.terminal.toggleTerminal'); + } + + public async getCommandOutput(command: string): Promise { + const selector = 'div[id="workbench.panel.terminal"] .xterm-rows'; + let readRow = process.platform === 'win32' ? 5 : 2; + let output: string = await this.spectron.client.getText(`${selector}>:nth-child(${readRow})`); + + // If ended up on the wrong line, it could be terminal's restored session (e.g. on OS X) + if (output.trim().endsWith(command)) { + output = await this.spectron.client.getText(`${selector}>:nth-child(${readRow+1})`); // try next line + } + + return output.trim(); // remove many   tags + } +} \ No newline at end of file diff --git a/smoketest/src/areas/javascript-debug.ts b/smoketest/src/areas/javascript-debug.ts new file mode 100644 index 00000000000..948594945d7 --- /dev/null +++ b/smoketest/src/areas/javascript-debug.ts @@ -0,0 +1,42 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; + +export class JavaScriptDebug { + private readonly sidebarSelector = '.margin-view-overlays'; + + constructor(private spectron: SpectronApplication) { + // noop + } + + public openDebugViewlet(): Promise { + return this.spectron.command('workbench.view.debug'); + } + + public async pressConfigureLaunchJson(): Promise { + await this.spectron.waitFor(this.spectron.client.click, 'ul[aria-label="Debug actions"] .action-label.icon.debug-action.configure'); + await this.spectron.wait(); + await this.spectron.client.keys(['ArrowDown', 'NULL', 'Enter']); + return this.spectron.wait(); + } + + public getProgramConfigValue(): Promise { + return this.spectron.client.getText('.view-lines>:nth-child(11) .mtk7'); + } + + public setBreakpointOnLine(lineNumber: number): Promise { + return this.spectron.client.leftClick(`${this.sidebarSelector}>:nth-child(${lineNumber})`, 5, 5); + } + + public async verifyBreakpointOnLine(lineNumber: number): Promise { + let el = await this.spectron.client.element(`${this.sidebarSelector}>:nth-child(${lineNumber}) .cgmr.debug-breakpoint-glyph`); + if (el.status === 0) { + return el; + } + + return undefined; + } +} \ No newline at end of file diff --git a/smoketest/src/areas/javascript.ts b/smoketest/src/areas/javascript.ts new file mode 100644 index 00000000000..a2f2644c86f --- /dev/null +++ b/smoketest/src/areas/javascript.ts @@ -0,0 +1,73 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; + +export class JavaScript { + private readonly appVarSelector = '.view-lines>:nth-child(7) .mtk11'; + private readonly firstCommentSelector = '.margin-view-overlays>:nth-child(3)'; + private readonly expressVarSelector = '.view-lines>:nth-child(11) .mtk10'; + + constructor(private spectron: SpectronApplication) { + // noop + } + + public openQuickOutline(): Promise { + return this.spectron.command('workbench.action.gotoSymbol'); + } + + public async findAppReferences(): Promise { + await this.spectron.client.click(this.appVarSelector, false); + return this.spectron.command('editor.action.referenceSearch.trigger'); + } + + public async getTitleReferencesCount(): Promise { + const meta = await this.spectron.client.getText('.reference-zone-widget.results-loaded .peekview-title .meta'); + + return meta.match(/\d+/)[0]; + } + + public async getTreeReferencesCount(): Promise { + const treeElems = await this.spectron.client.elements('.reference-zone-widget.results-loaded .ref-tree.inline .show-twisties .monaco-tree-row'); + return treeElems.value.length; + } + + public async renameApp(newValue: string): Promise { + await this.spectron.client.click(this.appVarSelector); + await this.spectron.command('editor.action.rename'); + await this.spectron.wait(); + return this.spectron.client.keys(newValue, false); + } + + public async getNewAppName(): Promise { + return this.spectron.client.getText(this.appVarSelector); + } + + public async toggleFirstCommentFold(): Promise { + return this.spectron.client.click(`${this.firstCommentSelector} .cldr.folding`); + } + + public async getFirstCommentFoldedIcon(): Promise { + return this.spectron.client.getHTML(`${this.firstCommentSelector} .cldr.folding.collapsed`); + } + + public async getNextLineNumberAfterFold(): Promise { + return this.spectron.client.getText(`.margin-view-overlays>:nth-child(4) .line-numbers`) + } + + public async goToExpressDefinition(): Promise { + await this.spectron.client.click(this.expressVarSelector); + return this.spectron.command('editor.action.goToDeclaration'); + } + + public async peekExpressDefinition(): Promise { + await this.spectron.client.click(this.expressVarSelector); + return this.spectron.command('editor.action.previewDeclaration'); + } + + public async getPeekExpressResultName(): Promise { + return this.spectron.client.getText('.reference-zone-widget.results-loaded .filename'); + } +} \ No newline at end of file diff --git a/smoketest/src/areas/localization.ts b/smoketest/src/areas/localization.ts new file mode 100644 index 00000000000..4ad30cdeb88 --- /dev/null +++ b/smoketest/src/areas/localization.ts @@ -0,0 +1,55 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; + +export enum ViewletType { + SEARCH = 0, + SCM = 1, + DEBUG = 2, + EXTENSIONS = 3 +} + +export class Localization { + + constructor(private spectron: SpectronApplication) { + // noop + } + + public async getOpenEditorsText(): Promise { + const explorerTitles = await this.spectron.client.getText('div[id="workbench.view.explorer"] .title span'); + return explorerTitles[0]; + } + + public openViewlet(type: ViewletType): Promise { + let command; + + switch (type) { + case ViewletType.SEARCH: + command = 'workbench.view.search'; + break; + case ViewletType.SCM: + command = 'workbench.view.scm'; + break; + case ViewletType.DEBUG: + command = 'workbench.view.debug'; + break; + case ViewletType.EXTENSIONS: + command = 'workbench.view.extensions'; + break; + } + + return this.spectron.command(command, false); + } + + public getOpenedViewletTitle(): Promise { + return this.spectron.client.getText('div[id="workbench.parts.sidebar"] .title-label span'); + } + + public getExtensionsSearchPlaceholder(): Promise { + return this.spectron.client.getAttribute('div[id="workbench.view.extensions"] .search-box', 'placeholder'); + } + +} \ No newline at end of file diff --git a/smoketest/src/areas/search.ts b/smoketest/src/areas/search.ts new file mode 100644 index 00000000000..5477a5f25d9 --- /dev/null +++ b/smoketest/src/areas/search.ts @@ -0,0 +1,50 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; + +export class Search { + + constructor(private spectron: SpectronApplication) { + // noop + } + + public openSearchViewlet(): Promise { + return this.spectron.command('workbench.view.search'); + } + + public async searchFor(text: string): Promise { + await this.spectron.client.keys(text); + return this.spectron.client.keys(['NULL', 'Enter', 'NULL'], false); + } + + public setReplaceText(text: string): any { + return this.spectron.client.setValue('.viewlet .input[title="Replace"]', text); + } + + public replaceFirstMatch(): any { + return this.spectron.client.click('.monaco-tree-rows.show-twisties .action-label.icon.action-replace-all'); + } + + public getResultText(): any { + return this.spectron.waitFor(this.spectron.client.getText, '.search-viewlet .message>p'); + } + + public toggleSearchDetails(): any { + return this.spectron.client.click('.query-details .more'); + } + + public toggleReplace(): any { + return this.spectron.client.click('.monaco-button.toggle-replace-button.collapse'); + } + + public hoverOverResultCount(): any { + return this.spectron.waitFor(this.spectron.client.moveToObject, '.monaco-count-badge'); + } + + public dismissResult(): any { + return this.spectron.client.click('.action-label.icon.action-remove') + } +} \ No newline at end of file diff --git a/smoketest/src/areas/statusbar.ts b/smoketest/src/areas/statusbar.ts new file mode 100644 index 00000000000..93b73495183 --- /dev/null +++ b/smoketest/src/areas/statusbar.ts @@ -0,0 +1,99 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; + +export enum StatusBarElement { + BRANCH_STATUS = 0, + SYNC_STATUS = 1, + PROBLEMS_STATUS = 2, + SELECTION_STATUS = 3, + INDENTATION_STATUS = 4, + ENCODING_STATUS = 5, + EOL_STATUS = 6, + LANGUAGE_STATUS = 7, + FEEDBACK_ICON = 8 +} + +export class StatusBar { + + private selectorsMap: Map; + private readonly mainSelector = 'div[id="workbench.parts.statusbar"]'; + + constructor(private spectron: SpectronApplication) { + this.populateSelectorsMap(); + } + + public async isVisible(element: StatusBarElement): Promise { + const selector = this.selectorsMap.get(element); + if (!selector) { + throw new Error('No such element in the status bar defined.'); + } + + return this.spectron.client.isVisible(selector); + } + + public async clickOn(element: StatusBarElement): Promise { + const selector = this.selectorsMap.get(element); + if (!selector) { + throw new Error('No such element in the status bar defined.'); + } + + return this.spectron.client.click(selector); + } + + public async getProblemsView(): Promise { + let el = await this.spectron.client.element('div[id="workbench.panel.markers"]'); + if (el.status === 0) { + return el; + } + + return undefined; + } + + public async getFeedbackView(): Promise { + let el = await this.spectron.client.element('.feedback-form'); + if (el.status === 0) { + return el; + } + + return undefined; + } + + public isQuickOpenWidgetVisible(): Promise { + return this.spectron.client.isVisible('.quick-open-widget'); + } + + public async getEditorHighlightedLine(lineNumber: number): Promise { + let el = await this.spectron.client.element(`.monaco-editor .view-overlays>:nth-child(${lineNumber}) .current-line`); + if (el.status === 0) { + return el; + } + + return undefined; + } + + public async getEOLMode(): Promise { + const selector = this.selectorsMap.get(StatusBarElement.EOL_STATUS); + if (!selector) { + throw new Error('No such element in the status bar defined.'); + } + + return this.spectron.client.getText(selector); + } + + private populateSelectorsMap(): void { + this.selectorsMap = new Map(); + this.selectorsMap.set(StatusBarElement.BRANCH_STATUS, `${this.mainSelector} .octicon.octicon-git-branch`); + this.selectorsMap.set(StatusBarElement.SYNC_STATUS, `${this.mainSelector} .octicon.octicon-sync`); + this.selectorsMap.set(StatusBarElement.PROBLEMS_STATUS, `${this.mainSelector} .task-statusbar-item[title="Problems"]`); + this.selectorsMap.set(StatusBarElement.SELECTION_STATUS, `${this.mainSelector} .editor-status-selection`); + this.selectorsMap.set(StatusBarElement.INDENTATION_STATUS, `${this.mainSelector} .editor-status-indentation`); + this.selectorsMap.set(StatusBarElement.ENCODING_STATUS, `${this.mainSelector} .editor-status-encoding`); + this.selectorsMap.set(StatusBarElement.EOL_STATUS, `${this.mainSelector} .editor-status-eol`); + this.selectorsMap.set(StatusBarElement.LANGUAGE_STATUS, `${this.mainSelector} .editor-status-mode`); + this.selectorsMap.set(StatusBarElement.FEEDBACK_ICON, `${this.mainSelector} .dropdown.send-feedback`); + } +} \ No newline at end of file diff --git a/smoketest/src/areas/tasks.ts b/smoketest/src/areas/tasks.ts new file mode 100644 index 00000000000..e46c2961df5 --- /dev/null +++ b/smoketest/src/areas/tasks.ts @@ -0,0 +1,50 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from '../spectron/application'; + +export class Tasks { + + private readonly outputViewSelector = 'div[id="workbench.panel.output"] .view-lines'; + private readonly workbenchPanelSelector = 'div[id="workbench.parts.panel"]'; + private readonly problemsViewSelector = 'div[id="workbench.panel.markers"] .monaco-tree-row.expanded'; + + constructor(private spectron: SpectronApplication) { + // noop + } + + public build(): Promise { + return this.spectron.command('workbench.action.tasks.build'); + } + + public openProblemsView(): Promise { + return this.spectron.command('workbench.actions.view.problems'); + } + + public async firstOutputLineEndsWith(fileName: string): Promise { + const firstLine = await this.spectron.waitFor(this.spectron.client.getText, `${this.outputViewSelector}>:nth-child(2)`); + return firstLine.endsWith(fileName); + } + + public getOutputResult(): Promise { + return this.spectron.waitFor(this.spectron.client.getText, `${this.outputViewSelector}>:nth-child(10) span.mtk1`); + } + + public selectOutputViewType(type: string): Promise { + return this.spectron.client.selectByValue(`${this.workbenchPanelSelector} .select-box`, type); + } + + public getOutputViewType(): Promise { + return this.spectron.client.getValue(`${this.workbenchPanelSelector} .select-box`); + } + + public getProblemsViewFirstElementName(): Promise { + return this.spectron.waitFor(this.spectron.client.getText, `${this.problemsViewSelector} .label-name`); + } + + public getProblemsViewFirstElementCount(): Promise { + return this.spectron.waitFor(this.spectron.client.getText, `${this.problemsViewSelector} .monaco-count-badge`); + } +} \ No newline at end of file diff --git a/smoketest/src/helpers/screenshot.ts b/smoketest/src/helpers/screenshot.ts new file mode 100644 index 00000000000..649c38493e4 --- /dev/null +++ b/smoketest/src/helpers/screenshot.ts @@ -0,0 +1,48 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { SpectronApplication } from "../spectron/application"; +var fs = require('fs'); + +const __testTime = new Date().toISOString(); + +export class Screenshot { + private index: number = 0; + private testPath: string; + + constructor(private spectron: SpectronApplication, testName: string) { + const testTime = this.sanitizeFolderName(__testTime); + testName = this.sanitizeFolderName(testName); + + this.testPath = `test_data/screenshots/${testTime}/${testName}`; + this.createFolder(this.testPath); + } + + public capture(): Promise { + return new Promise(async (res, rej) => { + const image: Electron.NativeImage = await this.spectron.app.browserWindow.capturePage(); + fs.writeFile(`${this.testPath}/${this.index}.png`, image, (err) => { + if (err) { + rej(err); + } + }); + this.index++; + res(); + }); + } + + private createFolder(name: string) { + name.split('/').forEach((folderName, i, fullPath) => { + const folder = fullPath.slice(0, i + 1).join('/'); + if (!fs.existsSync(folder)) { + fs.mkdirSync(folder); + } + }); + } + + private sanitizeFolderName(name: string): string { + return name.replace(/[&*:\/]/g, ''); + } +} \ No newline at end of file diff --git a/smoketest/src/helpers/utilities.ts b/smoketest/src/helpers/utilities.ts new file mode 100644 index 00000000000..2a52a4fe7df --- /dev/null +++ b/smoketest/src/helpers/utilities.ts @@ -0,0 +1,37 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +var fs = require('fs'); +var rimraf = require('rimraf'); + +/** + * Contains methods that are commonly used across test areas. + */ +export class Util { + constructor() { + // noop + } + + public removeFile(filePath: string): void { + try { + fs.unlinkSync(`${filePath}`); + } catch (e) { + if (e.code !== 'ENOENT') { + throw e; + } + } + } + + public rimraf(directory: string): Promise { + return new Promise((res, rej) => { + rimraf(directory, (err) => { + if (err) { + rej(err); + } + res(); + }); + }); + } +} \ No newline at end of file diff --git a/smoketest/src/main.ts b/smoketest/src/main.ts new file mode 100644 index 00000000000..9da55ce546a --- /dev/null +++ b/smoketest/src/main.ts @@ -0,0 +1,771 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; +import { SpectronApplication } from "./spectron/application"; +import { CommonActions } from './areas/common'; +import { FirstExperience } from './areas/first-experience'; +import { ConfigurationView, ActivityBarPosition } from './areas/configuration-views'; +import { Search } from './areas/search'; +import { CSS, CSSProblem } from './areas/css'; +import { JavaScript } from './areas/javascript'; +import { JavaScriptDebug } from './areas/javascript-debug'; +import { Git } from './areas/git'; +import { IntegratedTerminal } from './areas/integrated-terminal'; +import { StatusBar, StatusBarElement } from './areas/statusBar'; +import { DataLoss } from './areas/data-loss'; +import { Tasks } from './areas/tasks'; +import { Extensions } from './areas/extensions'; +import { Localization, ViewletType } from "./areas/localization"; + +describe('Smoke Test Suite', function () { + const latestPath = process.env.VSCODE_LATEST_PATH; + const stablePath = process.env.VSCODE_STABLE_PATH; + const insiders = process.env.VSCODE_EDITION; + const workspacePath = process.env.SMOKETEST_REPO; + const tempUserDir = 'test_data/temp_user_dir'; + const tempExtensionsDir = 'test_data/temp_extensions_dir'; + + let app: SpectronApplication; + let common: CommonActions; + this.retries(2); + + if (stablePath) { + context('Data Migration', function () { + + afterEach(async function () { + await app.stop(); + return await common.removeDirectory(tempUserDir) + }); + + function setupSpectron(context: Mocha.ITestCallbackContext, appPath: string, workspace?: string[]): void { + app = new SpectronApplication(appPath, context.test.fullTitle(), context.test.currentRetry(), workspace, [`--user-data-dir=${tempUserDir}`]); + common = new CommonActions(app); + } + + it('checks if the Untitled file is restored migrating from stable to latest', async function () { + const textToType = 'Very dirty file'; + + // Setting up stable version + setupSpectron(this, stablePath); + await app.start(); + + await common.newUntitledFile(); + await common.type(textToType); + await app.stop(); + + await app.wait(); // wait until all resources are released (e.g. locked local storage) + + // Checking latest version for the restored state + setupSpectron(this, latestPath); + await app.start(); + + assert.ok(await common.getTab('Untitled-1')); + await common.selectTab('Untitled-1'); + const editorText = await common.getEditorFirstLinePlainText(); + assert.equal(editorText, textToType); + }); + + it('checks if the newly created dirty file is restored migrating from stable to latest', async function () { + const fileName = 'test_data/plainFile', + firstTextPart = 'This is going to be an unsaved file', secondTextPart = '_that is dirty.'; + + // Setting up stable version + setupSpectron(this, stablePath, [fileName]); + await common.removeFile(`${fileName}`); + await app.start(); + + await common.type(firstTextPart); + await common.saveOpenedFile(); + await app.wait(); + await common.type(secondTextPart); + + await app.stop(); + await app.wait(); // wait until all resources are released (e.g. locked local storage) + + // Checking latest version for the restored state + setupSpectron(this, latestPath); + await app.start(); + assert.ok(await common.getTab(fileName.split('/')[1])); + await common.selectTab(fileName.split('/')[1]); + const editorText = await common.getEditorFirstLinePlainText(); + assert.equal(editorText, firstTextPart.concat(secondTextPart)); + + // Cleanup + await common.removeFile(`${fileName}`); + }); + + it('cheks if opened tabs are restored migrating from stable to latest', async function () { + const fileName1 = 'app.js', fileName2 = 'jsconfig.json', fileName3 = 'readme.md'; + setupSpectron(this, stablePath, [workspacePath]); + await app.start(); + await common.openFile(fileName1, true); + await common.openFile(fileName2, true); + await common.openFile(fileName3, true); + await app.stop(); + + setupSpectron(this, latestPath, [workspacePath]); + await app.start(); + assert.ok(await common.getTab(fileName1)); + assert.ok(await common.getTab(fileName2)); + assert.ok(await common.getTab(fileName3)); + }); + }); + } + + context('Data Loss', function () { + let dataLoss: DataLoss; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath], [`--user-data-dir=${tempUserDir}`]); + common = new CommonActions(app); + dataLoss = new DataLoss(app); + await common.removeDirectory(tempUserDir); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it(`verifies that 'hot exit' works for dirty files`, async function () { + const textToType = 'Hello, Code!', fileName = 'readme.md', untitled = 'Untitled-1'; + await common.newUntitledFile(); + await common.type(textToType); + await dataLoss.openExplorerViewlet(); + await common.openFile(fileName, true); + await common.type(textToType); + + await app.stop(); + await app.start(); + + // check tab presence + assert.ok(await common.getTab(untitled)); + assert.ok(await common.getTab(fileName, true)); + // check if they marked as dirty (icon) and active tab is the last opened + assert.ok(await dataLoss.verifyTabIsDirty(untitled)); + assert.ok(await dataLoss.verifyTabIsDirty(fileName, true)); + }); + + it(`verifies that contents of the dirty files are restored after 'hot exit'`, async function () { + // make one dirty file, + // create one untitled file + const textToType = 'Hello, Code!'; + + // create one untitled file + await common.newUntitledFile(); + await app.wait(); + await common.type(textToType); + + // make one dirty file, + await common.openFile('readme.md', true); + await app.wait(); + await common.type(textToType); + + await app.stop(); + await app.start(); + + // check their contents + let fileDirt = await common.getEditorFirstLinePlainText(); + assert.equal(fileDirt, 'Hello, Code'); // ignore '!' as it is a separate , first part is enough + await common.selectTab('Untitled-1'); + fileDirt = await common.getEditorFirstLinePlainText(); + assert.equal(fileDirt, textToType); + }); + }); + + context('First User Experience', function () { + let experience: FirstExperience; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), undefined, [`--user-data-dir=${tempUserDir}`, `--excludeSwitches=load-component-extension`]); + common = new CommonActions(app); + experience = new FirstExperience(app); + + await common.removeDirectory(tempUserDir); + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it(`verifies if title is set correctly on the clean user-directory startup`, async function () { + const title = await common.getWindowTitle(); + + let expectedTitle = 'Welcome'; + if (process.platform !== 'darwin') { + expectedTitle += ' — Visual Studio Code'; + if (insiders) expectedTitle += ' - Insiders'; + } + + assert.equal(title, expectedTitle); + }); + + it(`verifies if 'Welcome page' tab is presented on the clean user-directory startup`, async function () { + assert.ok(await experience.getWelcomeTab()); + }); + }); + + context('Explorer', function () { + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); + common = new CommonActions(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('quick open search produces correct result', async function () { + await common.openQuickOpen(); + await common.type('.js'); + await app.wait(); + const elCount = await common.getQuickOpenElements(); + assert.equal(elCount, 7); + }); + + it('quick open respects fuzzy matching', async function () { + await common.openQuickOpen(); + await common.type('a.s'); + await app.wait(); + const elCount = await common.getQuickOpenElements(); + assert.equal(elCount, 3); + }); + }); + + context('Configuration and views', function () { + let configView: ConfigurationView; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); + common = new CommonActions(app); + configView = new ConfigurationView(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('turns off editor line numbers and verifies the live change', async function () { + await common.newUntitledFile(); + await app.wait(); + let elements = await configView.getEditorLineNumbers(); + assert.equal(elements.value.length, 1); + await common.addSetting('editor.lineNumbers', 'off'); + await app.wait(); + elements = await configView.getEditorLineNumbers(); + assert.equal(elements.value.length, 0); + }); + + it(`changes 'workbench.action.toggleSidebarPosition' command key binding and verifies it`, async function () { + await configView.enterKeybindingsView() + await common.type('workbench.action.toggleSidebarPosition'); + await app.wait(); + await configView.selectFirstKeybindingsMatch(); + await configView.changeKeybinding(); + await configView.enterBinding(['Control', 'u', 'NULL']); + await common.enter(); + let html = await configView.getActivityBar(ActivityBarPosition.RIGHT); + assert.equal(html, undefined);; + await app.wait(); + await configView.toggleActivityBarPosition(); + html = await configView.getActivityBar(ActivityBarPosition.RIGHT); + assert.ok(html); + }); + }); + + context('Search', function () { + let search: Search; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); + common = new CommonActions(app); + search = new Search(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('searches for body & checks for correct result number', async function () { + const s = search; + await s.openSearchViewlet(); + await s.searchFor('body'); + const result = await s.getResultText(); + assert.equal(result, '7 results in 4 files'); + }); + + it('searches only for *.js files & checks for correct result number', async function () { + const s = search; + await s.openSearchViewlet(); + await s.searchFor('body'); + await s.toggleSearchDetails(); + await s.searchFor('*.js'); + const results = await s.getResultText(); + assert.equal(results, '4 results in 1 file'); + }); + + it('dismisses result & checks for correct result number', async function () { + const s = search; + await s.openSearchViewlet() + await s.searchFor('body'); + await s.hoverOverResultCount(); + await s.dismissResult(); + await app.wait(); + const result = await s.getResultText(); + assert.equal(result, '3 results in 3 files') + }); + + it('replaces first search result with a replace term', async function () { + const s = search; + await s.openSearchViewlet() + await s.searchFor('body'); + await s.toggleReplace(); + await s.setReplaceText('ydob'); + await s.hoverOverResultCount(); + await s.replaceFirstMatch(); + await app.wait(); + await common.saveOpenedFile(); + const result = await s.getResultText(); + assert.equal(result, '3 results in 3 files'); + }); + }); + + context('CSS', function () { + let css: CSS; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); + common = new CommonActions(app); + css = new CSS(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('verifies quick outline', async function () { + await common.openFirstMatchFile('style.css'); + await css.openQuickOutline(); + await app.wait(); + const count = await common.getQuickOpenElements(); + assert.equal(count, 2); + }); + + it('verifies warnings for the empty rule', async function () { + await common.openFirstMatchFile('style.css'); + await common.type('.foo{}'); + await app.wait(); + let warning = await css.getEditorProblem(CSSProblem.WARNING); + assert.ok(warning); + await css.toggleProblemsView(); + warning = await css.getProblemsViewsProblem(CSSProblem.WARNING); + assert.ok(warning); + }); + + it('verifies that warning becomes an error once setting changed', async function () { + await common.addSetting('css.lint.emptyRules', 'error'); + await common.openFirstMatchFile('style.css'); + await common.type('.foo{}'); + await app.wait(); + let error = await css.getEditorProblem(CSSProblem.ERROR); + assert.ok(error); + await css.toggleProblemsView(); + error = await css.getProblemsViewsProblem(CSSProblem.ERROR); + assert.ok(error); + }); + }); + + context('JavaScript', function () { + let js: JavaScript; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); + common = new CommonActions(app); + js = new JavaScript(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('shows correct quick outline', async function () { + await common.openFirstMatchFile('bin/www'); + await js.openQuickOutline(); + await app.wait(); + const symbols = await common.getQuickOpenElements(); + assert.equal(symbols, 12); + }); + + it(`finds 'All References' to 'app'`, async function () { + await common.openFirstMatchFile('bin/www'); + await app.wait(); + await js.findAppReferences(); + const titleCount = await js.getTitleReferencesCount(); + assert.equal(titleCount, 3); + const treeCount = await js.getTreeReferencesCount(); + assert.equal(treeCount, 3); + }); + + it(`renames local 'app' variable`, async function () { + await common.openFirstMatchFile('bin/www'); + + const newVarName = 'newApp'; + await js.renameApp(newVarName); + await common.enter(); + const newName = await js.getNewAppName(); + assert.equal(newName, newVarName); + }); + + it('folds/unfolds the code correctly', async function () { + await common.openFirstMatchFile('bin/www'); + // Fold + await js.toggleFirstCommentFold(); + const foldedIcon = await js.getFirstCommentFoldedIcon(); + assert.ok(foldedIcon); + let nextLineNumber = await js.getNextLineNumberAfterFold(); + assert.equal(nextLineNumber, 7); + // Unfold + await js.toggleFirstCommentFold(); + nextLineNumber = await js.getNextLineNumberAfterFold(); + assert.equal(nextLineNumber, 4); + }); + + it(`verifies that 'Go To Definition' works`, async function () { + await common.openFirstMatchFile('app.js'); + await js.goToExpressDefinition(); + await app.wait(); + assert.ok(await common.getTab('index.d.ts')); + }); + + it(`verifies that 'Peek Definition' works`, async function () { + await common.openFirstMatchFile('app.js'); + await js.peekExpressDefinition(); + const definitionFilename = await js.getPeekExpressResultName(); + assert.equal(definitionFilename, 'index.d.ts'); + }); + }); + + context('Debugging JavaScript', function () { + let jsDebug: JavaScriptDebug; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); + common = new CommonActions(app); + jsDebug = new JavaScriptDebug(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('autodetects program attribute for launch.json', async function () { + await jsDebug.openDebugViewlet(); + await jsDebug.pressConfigureLaunchJson(); + const value = await jsDebug.getProgramConfigValue(); + process.platform === 'win32' ? assert.equal(value, '"${workspaceRoot}\\\\bin\\\\www"') : assert.equal(value, '"${workspaceRoot}/bin/www"'); + }); + + it(`can set a breakpoint and verify if it's set`, async function () { + await common.openFirstMatchFile('index.js'); + await jsDebug.setBreakpointOnLine(6); + const breakpoint = await jsDebug.verifyBreakpointOnLine(6); + assert.ok(breakpoint); + }); + }); + + context('Git', function () { + let git: Git; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); + common = new CommonActions(app); + git = new Git(app, common); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('verifies current changes are picked up by Git viewlet', async function () { + const changesCount = await git.getScmIconChanges(); + assert.equal(changesCount, 2); + await git.openGitViewlet(); + assert.ok(await git.verifyScmChange('app.js')); + assert.ok(await git.verifyScmChange('launch.json')); + }); + + it(`verifies 'app.js' diff viewer changes`, async function () { + await git.openGitViewlet(); + await common.openFile('app.js'); + const original = await git.getOriginalAppJsBodyVarName(); + assert.equal(original, 'bodyParser'); + const modified = await git.getModifiedAppJsBodyVarName(); + assert.equal(modified, 'ydobParser'); + }); + + it(`stages 'app.js' changes and checks stage count`, async function () { + await git.openGitViewlet(); + await app.wait(); + await git.stageFile('app.js'); + const stagedCount = await git.getStagedCount(); + assert.equal(stagedCount, 1); + + // Return back to unstaged state + await git.unstageFile('app.js'); + }); + + it(`stages, commits change to 'app.js' locally and verifies outgoing change`, async function () { + await git.openGitViewlet(); + await app.wait(); + await git.stageFile('app.js'); + await git.focusOnCommitBox(); + await common.type('Test commit'); + await git.pressCommit(); + const changes = await git.getOutgoingChanges(); + assert.equal(changes, ' 0↓ 1↑'); + }); + }); + + context('Integrated Terminal', function () { + let terminal: IntegratedTerminal; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); + common = new CommonActions(app); + terminal = new IntegratedTerminal(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it(`opens terminal, runs 'echo' and verifies the output`, async function () { + const command = 'echo test'; + await terminal.openTerminal(common); + await app.wait(); + await common.type(command); + await common.enter(); + await app.wait(); + // Default Powershell terminal adds 3 header rows at the top, whereas bash does not. + let output = await terminal.getCommandOutput(command); + assert.equal(output, 'test'); + }); + }); + + context('Status Bar', function () { + let statusBar: StatusBar; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); + common = new CommonActions(app); + statusBar = new StatusBar(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('verifies presence of all default status bar elements', async function () { + await app.wait(); + assert.ok(await statusBar.isVisible(StatusBarElement.BRANCH_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.FEEDBACK_ICON)); + assert.ok(await statusBar.isVisible(StatusBarElement.SYNC_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.PROBLEMS_STATUS)); + + await common.openFirstMatchFile('app.js'); + assert.ok(await statusBar.isVisible(StatusBarElement.ENCODING_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.EOL_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.INDENTATION_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.LANGUAGE_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.SELECTION_STATUS)); + }); + + it(`verifies that 'quick open' opens when clicking on 'Branch', 'Indentation Status, 'Encoding', 'EOL' and 'Language' status elements`, async function () { + await app.wait(); + await statusBar.clickOn(StatusBarElement.BRANCH_STATUS); + assert.ok(await statusBar.isQuickOpenWidgetVisible()); + await common.closeQuickOpen(); + + await common.openFirstMatchFile('app.js'); + await statusBar.clickOn(StatusBarElement.INDENTATION_STATUS); + assert.ok(await statusBar.isQuickOpenWidgetVisible()); + await common.closeQuickOpen(); + await statusBar.clickOn(StatusBarElement.ENCODING_STATUS); + assert.ok(await statusBar.isQuickOpenWidgetVisible()); + await common.closeQuickOpen(); + await statusBar.clickOn(StatusBarElement.EOL_STATUS); + assert.ok(await statusBar.isQuickOpenWidgetVisible()); + await common.closeQuickOpen(); + await statusBar.clickOn(StatusBarElement.LANGUAGE_STATUS); + assert.ok(await statusBar.isQuickOpenWidgetVisible()); + await common.closeQuickOpen(); + }); + + it(`verifies that 'Problems View' appears when clicking on 'Problems' status element`, async function () { + await statusBar.clickOn(StatusBarElement.PROBLEMS_STATUS); + assert.ok(await statusBar.getProblemsView()); + }); + + it(`verifies that 'Tweet us feedback' pop-up appears when clicking on 'Feedback' icon`, async function () { + await statusBar.clickOn(StatusBarElement.FEEDBACK_ICON); + assert.ok(await statusBar.getFeedbackView()); + }); + + it(`checks if 'Go to Line' works if called from the status bar`, async function () { + await common.openFirstMatchFile('app.js'); + await statusBar.clickOn(StatusBarElement.SELECTION_STATUS); + const lineNumber = 15; + await common.type(lineNumber.toString()); + await common.enter(); + assert.ok(await statusBar.getEditorHighlightedLine(lineNumber)); + }); + + it(`verifies if changing EOL is reflected in the status bar`, async function () { + await common.openFirstMatchFile('app.js'); + await statusBar.clickOn(StatusBarElement.EOL_STATUS); + await common.selectNextQuickOpenElement(); + await common.enter(); + const currentEOL = await statusBar.getEOLMode(); + assert.equal(currentEOL, 'CRLF'); + }); + }); + + context('Tasks', function () { + let tasks: Tasks; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); + tasks = new Tasks(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('verifies that build task produces 6 errors', async function () { + await tasks.build(); + const res = await tasks.getOutputResult(); + assert.equal(res, '✖ 6 problems (6 errors, 0 warnings)'); + }); + + it(`is able to select 'Git' output`, async function () { + await tasks.build(); + await app.wait(); + await tasks.selectOutputViewType('Git'); + const viewType = await tasks.getOutputViewType(); + assert.equal(viewType, 'Git'); + }); + + it('ensures that build task produces errors in index.js', async function () { + await tasks.build(); + assert.ok(await tasks.firstOutputLineEndsWith('index.js')); + }); + + it(`verifies build errors are reflected in 'Problems View'`, async function () { + await tasks.build(); + await app.wait(); + await tasks.openProblemsView(); + const problemName = await tasks.getProblemsViewFirstElementName(); + assert.equal(problemName, 'index.js'); + const problemsCount = await tasks.getProblemsViewFirstElementCount(); + assert.equal(problemsCount, '6'); + }); + }); + + context('Extensions', function () { + let extensions: Extensions; + + beforeEach(async function () { + app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath], [`--extensions-dir=${tempExtensionsDir}`]); + common = new CommonActions(app); + extensions = new Extensions(app, common); + await common.removeDirectory(tempExtensionsDir); + + return await app.start(); + }); + afterEach(async function () { + await app.stop(); + return await common.removeDirectory(tempExtensionsDir); + }); + + it(`installs 'vscode-icons' extension and verifies reload is prompted`, async function () { + await extensions.openExtensionsViewlet(); + await extensions.searchForExtension('vscode-icons'); + await app.wait(); + await extensions.installFirstResult(); + await app.wait(); + assert.ok(await extensions.getFirstReloadText()); + }); + + it(`installs an extension and checks if it works on restart`, async function () { + await extensions.openExtensionsViewlet(); + await extensions.searchForExtension('vscode-icons'); + await app.wait(); + await extensions.installFirstResult(); + await app.wait(); + await extensions.getFirstReloadText(); + + await app.stop(); + await app.wait(); // wait until all resources are released (e.g. locked local storage) + await app.start(); + await extensions.selectMinimalIconsTheme(); + const x = await extensions.verifyFolderIconAppearance(); + assert.ok(x); + }); + }); + + context('Localization', function () { + afterEach(async function () { + return await app.stop(); + }); + + it(`starts with 'DE' locale and verifies title and viewlets text is in German`, async function () { + app = new SpectronApplication(latestPath, this.test.fullTitle(), this.test.currentRetry(), [workspacePath, '--locale=DE'], [`--user-data-dir=${tempUserDir}`]); + common = new CommonActions(app); + const locale = new Localization(app); + common.removeDirectory(tempUserDir); + + await app.start(); + + let expectedTitle = 'Willkommen — vscode-smoketest-express'; + if (process.platform !== 'darwin') { + expectedTitle += ' — Visual Studio Code'; + if (insiders) expectedTitle += ' - Insiders'; + } + assert.equal(await common.getWindowTitle(), expectedTitle); + + let text = await locale.getOpenEditorsText(); + assert.equal(text.toLowerCase(), 'geöffnete editoren'); + + await locale.openViewlet(ViewletType.SEARCH); + text = await locale.getOpenedViewletTitle() + assert.equal(text.toLowerCase(), 'suchen'); + + await locale.openViewlet(ViewletType.SCM); + text = await locale.getOpenedViewletTitle(); + assert.equal(text.toLowerCase(), 'quellcodeverwaltung: git'); + + await locale.openViewlet(ViewletType.DEBUG); + text = await locale.getOpenedViewletTitle(); + assert.equal(text.toLowerCase(), 'debuggen'); + + await locale.openViewlet(ViewletType.EXTENSIONS); + text = await locale.getExtensionsSearchPlaceholder(); + assert.equal(text.toLowerCase(), 'nach extensions in marketplace suchen'); + }); + }); + +}); \ No newline at end of file diff --git a/smoketest/src/spectron/application.ts b/smoketest/src/spectron/application.ts new file mode 100644 index 00000000000..5e45474768c --- /dev/null +++ b/smoketest/src/spectron/application.ts @@ -0,0 +1,156 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { Application } from 'spectron'; +import { SpectronClient } from './client'; +import { Screenshot } from "../helpers/screenshot"; +var fs = require('fs'); + +/** + * Wraps Spectron's Application instance with its used methods. + */ +export class SpectronApplication { + public client: SpectronClient; + + private spectron: Application; + private readonly pollTrials = 5; + private readonly pollTimeout = 3; // in secs + private keybindings: any[]; + private screenshot: Screenshot; + + constructor(electronPath: string, testName: string, private testRetry: number, args?: string[], chromeDriverArgs?: string[]) { + if (!args) { + args = []; + } + + this.spectron = new Application({ + path: electronPath, + args: args.concat(['--skip-getting-started']), // prevent 'Getting Started' web page from opening on clean user-data-dir + chromeDriverArgs: chromeDriverArgs + }); + this.screenshot = new Screenshot(this, testName); + this.client = new SpectronClient(this.spectron, this.screenshot); + this.testRetry += 1; // avoid multiplication by 0 for wait times + this.retrieveKeybindings(); + } + + public get app(): Application { + return this.spectron; + } + + public async start(): Promise { + try { + await this.spectron.start(); + await this.focusOnWindow(1); // focuses on main renderer window + return this.checkWindowReady(); + } catch (err) { + throw err; + } + } + + public async stop(): Promise { + if (this.spectron && this.spectron.isRunning()) { + return await this.spectron.stop(); + } + } + + public waitFor(func: (...args: any[]) => any, args: any): Promise { + return this.callClientAPI(func, args, 0); + } + + public wait(): Promise { + return new Promise(resolve => setTimeout(resolve, this.testRetry * this.pollTimeout * 1000)); + } + + public focusOnWindow(index: number): Promise { + return this.client.windowByIndex(index); + } + + private checkWindowReady(): Promise { + return this.waitFor(this.spectron.client.getHTML, '[id="workbench.main.container"]'); + } + + private retrieveKeybindings() { + const os = process.platform; + fs.readFile(`test_data/keybindings.${os}.json`, (err, data) => { + if (err) { + throw err; + } + + this.keybindings = JSON.parse(data); + }); + } + + private callClientAPI(func: (...args: any[]) => Promise, args: any, trial: number): Promise { + if (trial > this.pollTrials) { + return Promise.reject(`Could not retrieve the element in ${this.testRetry * this.pollTrials * this.pollTimeout} seconds.`); + } + + return new Promise(async (res, rej) => { + let resolved = false, capture = false; + + const tryCall = async (resolve: any, reject: any): Promise => { + await this.wait(); + try { + const result = await this.callClientAPI(func, args, ++trial); + res(result); + } catch (error) { + rej(error); + } + } + + try { + const result = await func.call(this.client, args, capture); + if (!resolved && result === '') { + resolved = true; + await tryCall(res, rej); + } else if (!resolved) { + resolved = true; + await this.screenshot.capture(); + res(result); + } + } catch (e) { + if (!resolved) { + resolved = true; + await tryCall(res, rej); + } + } + }); + } + + /** + * Retrieves the command from keybindings file and executes it with WebdriverIO client API + * @param command command (e.g. 'workbench.action.files.newUntitledFile') + */ + public command(command: string, capture?: boolean): Promise { + const binding = this.keybindings.find(x => x['command'] == command); + const keys: string = binding.key; + let keysToPress: string[] = []; + + const chords = keys.split(' '); + chords.forEach((chord) => { + const keys = chord.split('+'); + keys.forEach((key) => keysToPress.push(this.transliterate(key))); + keysToPress.push('NULL'); + }); + + return this.client.keys(keysToPress, capture); + } + + /** + * Transliterates key names from keybindings file to WebdriverIO keyboard actions defined in: + * https://w3c.github.io/webdriver/webdriver-spec.html#keyboard-actions + */ + private transliterate(key: string): string { + switch (key) { + case 'ctrl': + return 'Control'; + case 'cmd': + return 'Meta'; + default: + return key.length === 1 ? key : key.charAt(0).toUpperCase() + key.slice(1); + }; + } +} diff --git a/smoketest/src/spectron/client.ts b/smoketest/src/spectron/client.ts new file mode 100644 index 00000000000..9376bd3e100 --- /dev/null +++ b/smoketest/src/spectron/client.ts @@ -0,0 +1,127 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { Application } from 'spectron'; +import { Screenshot } from '../helpers/screenshot'; + +/** + * Abstracts the Spectron's WebdriverIO managed client property on the created Application instances. + */ +export class SpectronClient { + + constructor(private spectron: Application, private shot: Screenshot) { + // noop + } + + public windowByIndex(index: number): Promise { + return this.spectron.client.windowByIndex(index); + } + + public async keys(keys: string[] | string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.keys(keys); + } + + public async getText(selector: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.getText(selector); + } + + public async getHTML(selector: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.getHTML(selector); + } + + public async click(selector: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.click(selector); + } + + public async doubleClick(selector: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.doubleClick(selector); + } + + public async leftClick(selector: string, xoffset: number, yoffset: number, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.leftClick(selector, xoffset, yoffset); + } + + public async rightClick(selector: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.rightClick(selector); + } + + public async moveToObject(selector: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.moveToObject(selector); + } + + public async setValue(selector: string, text: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.setValue(selector, text); + } + + public async elements(selector: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.elements(selector); + } + + public async element(selector: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.element(selector); + } + + public async dragAndDrop(sourceElem: string, destinationElem: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.dragAndDrop(sourceElem, destinationElem); + } + + public async selectByValue(selector: string, value: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.selectByValue(selector, value); + } + + public async getValue(selector: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.getValue(selector); + } + + public async getAttribute(selector: string, attribute: string, capture: boolean = true): Promise { + await this.execute(capture); + return Promise.resolve(this.spectron.client.getAttribute(selector, attribute)); + } + + public clearElement(selector: string): any { + return this.spectron.client.clearElement(selector); + } + + public buttonDown(): any { + return this.spectron.client.buttonDown(); + } + + public buttonUp(): any { + return this.spectron.client.buttonUp(); + } + + public async isVisible(selector: string, capture: boolean = true): Promise { + await this.execute(capture); + return this.spectron.client.isVisible(selector); + } + + public getTitle(): string { + return this.spectron.client.getTitle(); + } + + private async execute(capture: boolean): Promise { + if (capture) { + try { + await this.shot.capture(); + } catch (e) { + throw new Error(`Screenshot could not be captured: ${e}`); + } + } + } +} \ No newline at end of file diff --git a/smoketest/tsconfig.json b/smoketest/tsconfig.json new file mode 100644 index 00000000000..1b0b03c2d67 --- /dev/null +++ b/smoketest/tsconfig.json @@ -0,0 +1,21 @@ +{ + "compilerOptions": { + "module": "commonjs", + "noImplicitAny": false, + "removeComments": false, + "preserveConstEnums": true, + "target": "es2016", + "strictNullChecks": true, + "noUnusedParameters": false, + "noUnusedLocals": true, + "outDir": "out", + "sourceMap": true, + "lib": [ + "es2016", + "dom" + ] + }, + "exclude": [ + "node_modules" + ] +} \ No newline at end of file diff --git a/vscode-smoketest-express b/vscode-smoketest-express new file mode 160000 index 00000000000..636dd7a2ff7 --- /dev/null +++ b/vscode-smoketest-express @@ -0,0 +1 @@ +Subproject commit 636dd7a2ff71d266c0e015411b47cf5c3a25be5a -- GitLab From 7e6fb9ffab12a7605ae7ad1ba4320aa5d22101cd Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Mon, 22 May 2017 15:28:29 +0200 Subject: [PATCH 0199/1347] Moved to test directory. --- {smoketest => test/smoke}/.gitignore | 0 {smoketest => test/smoke}/.vscode/launch.json | 0 {smoketest => test/smoke}/.vscode/tasks.json | 0 {smoketest => test/smoke}/CONTRIBUTING.md | 0 {smoketest => test/smoke}/README.md | 0 {smoketest => test/smoke}/package.json | 0 {smoketest => test/smoke}/scripts/run.ps1 | 11 +++++------ {smoketest => test/smoke}/scripts/run.sh | 0 {smoketest => test/smoke}/src/areas/common.ts | 0 .../smoke}/src/areas/configuration-views.ts | 0 {smoketest => test/smoke}/src/areas/css.ts | 0 {smoketest => test/smoke}/src/areas/data-loss.ts | 0 {smoketest => test/smoke}/src/areas/extensions.ts | 0 .../smoke}/src/areas/first-experience.ts | 0 {smoketest => test/smoke}/src/areas/git.ts | 0 .../smoke}/src/areas/integrated-terminal.ts | 0 .../smoke}/src/areas/javascript-debug.ts | 0 {smoketest => test/smoke}/src/areas/javascript.ts | 0 {smoketest => test/smoke}/src/areas/localization.ts | 0 {smoketest => test/smoke}/src/areas/search.ts | 0 {smoketest => test/smoke}/src/areas/statusbar.ts | 0 {smoketest => test/smoke}/src/areas/tasks.ts | 0 {smoketest => test/smoke}/src/helpers/screenshot.ts | 0 {smoketest => test/smoke}/src/helpers/utilities.ts | 0 {smoketest => test/smoke}/src/main.ts | 0 {smoketest => test/smoke}/src/spectron/application.ts | 0 {smoketest => test/smoke}/src/spectron/client.ts | 0 {smoketest => test/smoke}/tsconfig.json | 0 28 files changed, 5 insertions(+), 6 deletions(-) rename {smoketest => test/smoke}/.gitignore (100%) rename {smoketest => test/smoke}/.vscode/launch.json (100%) rename {smoketest => test/smoke}/.vscode/tasks.json (100%) rename {smoketest => test/smoke}/CONTRIBUTING.md (100%) rename {smoketest => test/smoke}/README.md (100%) rename {smoketest => test/smoke}/package.json (100%) rename {smoketest => test/smoke}/scripts/run.ps1 (84%) rename {smoketest => test/smoke}/scripts/run.sh (100%) rename {smoketest => test/smoke}/src/areas/common.ts (100%) rename {smoketest => test/smoke}/src/areas/configuration-views.ts (100%) rename {smoketest => test/smoke}/src/areas/css.ts (100%) rename {smoketest => test/smoke}/src/areas/data-loss.ts (100%) rename {smoketest => test/smoke}/src/areas/extensions.ts (100%) rename {smoketest => test/smoke}/src/areas/first-experience.ts (100%) rename {smoketest => test/smoke}/src/areas/git.ts (100%) rename {smoketest => test/smoke}/src/areas/integrated-terminal.ts (100%) rename {smoketest => test/smoke}/src/areas/javascript-debug.ts (100%) rename {smoketest => test/smoke}/src/areas/javascript.ts (100%) rename {smoketest => test/smoke}/src/areas/localization.ts (100%) rename {smoketest => test/smoke}/src/areas/search.ts (100%) rename {smoketest => test/smoke}/src/areas/statusbar.ts (100%) rename {smoketest => test/smoke}/src/areas/tasks.ts (100%) rename {smoketest => test/smoke}/src/helpers/screenshot.ts (100%) rename {smoketest => test/smoke}/src/helpers/utilities.ts (100%) rename {smoketest => test/smoke}/src/main.ts (100%) rename {smoketest => test/smoke}/src/spectron/application.ts (100%) rename {smoketest => test/smoke}/src/spectron/client.ts (100%) rename {smoketest => test/smoke}/tsconfig.json (100%) diff --git a/smoketest/.gitignore b/test/smoke/.gitignore similarity index 100% rename from smoketest/.gitignore rename to test/smoke/.gitignore diff --git a/smoketest/.vscode/launch.json b/test/smoke/.vscode/launch.json similarity index 100% rename from smoketest/.vscode/launch.json rename to test/smoke/.vscode/launch.json diff --git a/smoketest/.vscode/tasks.json b/test/smoke/.vscode/tasks.json similarity index 100% rename from smoketest/.vscode/tasks.json rename to test/smoke/.vscode/tasks.json diff --git a/smoketest/CONTRIBUTING.md b/test/smoke/CONTRIBUTING.md similarity index 100% rename from smoketest/CONTRIBUTING.md rename to test/smoke/CONTRIBUTING.md diff --git a/smoketest/README.md b/test/smoke/README.md similarity index 100% rename from smoketest/README.md rename to test/smoke/README.md diff --git a/smoketest/package.json b/test/smoke/package.json similarity index 100% rename from smoketest/package.json rename to test/smoke/package.json diff --git a/smoketest/scripts/run.ps1 b/test/smoke/scripts/run.ps1 similarity index 84% rename from smoketest/scripts/run.ps1 rename to test/smoke/scripts/run.ps1 index d6368da6890..a7e29482a78 100644 --- a/smoketest/scripts/run.ps1 +++ b/test/smoke/scripts/run.ps1 @@ -1,10 +1,9 @@ Param( [Parameter(Position=0,mandatory=$true)] - [string] $latest, - [Parameter(Position=1,mandatory=$false)] - [string] $stable + [string]$arch ) + # Setup sample repository for the smoke test Set-Location .. if (-Not (Test-Path vscode-smoketest-express)) { @@ -19,14 +18,14 @@ if (-Not (Test-Path vscode-smoketest-express)) { npm install # Setup the test directory for running -Set-Location ..\smoketest +Set-Location ..\smoke if (-Not (Test-Path node_modules)) { npm install } # Configure environment variables -$env:VSCODE_LATEST_PATH = $latest -$env:VSCODE_STABLE_PATH = $stable +$env:VSCODE_LATEST_PATH = "$Root\VSCode-win32-$arch" +# $env:VSCODE_STABLE_PATH = $stable $env:SMOKETEST_REPO = "..\vscode-smoketest-express" if ($latest.Contains('Insiders')) { diff --git a/smoketest/scripts/run.sh b/test/smoke/scripts/run.sh similarity index 100% rename from smoketest/scripts/run.sh rename to test/smoke/scripts/run.sh diff --git a/smoketest/src/areas/common.ts b/test/smoke/src/areas/common.ts similarity index 100% rename from smoketest/src/areas/common.ts rename to test/smoke/src/areas/common.ts diff --git a/smoketest/src/areas/configuration-views.ts b/test/smoke/src/areas/configuration-views.ts similarity index 100% rename from smoketest/src/areas/configuration-views.ts rename to test/smoke/src/areas/configuration-views.ts diff --git a/smoketest/src/areas/css.ts b/test/smoke/src/areas/css.ts similarity index 100% rename from smoketest/src/areas/css.ts rename to test/smoke/src/areas/css.ts diff --git a/smoketest/src/areas/data-loss.ts b/test/smoke/src/areas/data-loss.ts similarity index 100% rename from smoketest/src/areas/data-loss.ts rename to test/smoke/src/areas/data-loss.ts diff --git a/smoketest/src/areas/extensions.ts b/test/smoke/src/areas/extensions.ts similarity index 100% rename from smoketest/src/areas/extensions.ts rename to test/smoke/src/areas/extensions.ts diff --git a/smoketest/src/areas/first-experience.ts b/test/smoke/src/areas/first-experience.ts similarity index 100% rename from smoketest/src/areas/first-experience.ts rename to test/smoke/src/areas/first-experience.ts diff --git a/smoketest/src/areas/git.ts b/test/smoke/src/areas/git.ts similarity index 100% rename from smoketest/src/areas/git.ts rename to test/smoke/src/areas/git.ts diff --git a/smoketest/src/areas/integrated-terminal.ts b/test/smoke/src/areas/integrated-terminal.ts similarity index 100% rename from smoketest/src/areas/integrated-terminal.ts rename to test/smoke/src/areas/integrated-terminal.ts diff --git a/smoketest/src/areas/javascript-debug.ts b/test/smoke/src/areas/javascript-debug.ts similarity index 100% rename from smoketest/src/areas/javascript-debug.ts rename to test/smoke/src/areas/javascript-debug.ts diff --git a/smoketest/src/areas/javascript.ts b/test/smoke/src/areas/javascript.ts similarity index 100% rename from smoketest/src/areas/javascript.ts rename to test/smoke/src/areas/javascript.ts diff --git a/smoketest/src/areas/localization.ts b/test/smoke/src/areas/localization.ts similarity index 100% rename from smoketest/src/areas/localization.ts rename to test/smoke/src/areas/localization.ts diff --git a/smoketest/src/areas/search.ts b/test/smoke/src/areas/search.ts similarity index 100% rename from smoketest/src/areas/search.ts rename to test/smoke/src/areas/search.ts diff --git a/smoketest/src/areas/statusbar.ts b/test/smoke/src/areas/statusbar.ts similarity index 100% rename from smoketest/src/areas/statusbar.ts rename to test/smoke/src/areas/statusbar.ts diff --git a/smoketest/src/areas/tasks.ts b/test/smoke/src/areas/tasks.ts similarity index 100% rename from smoketest/src/areas/tasks.ts rename to test/smoke/src/areas/tasks.ts diff --git a/smoketest/src/helpers/screenshot.ts b/test/smoke/src/helpers/screenshot.ts similarity index 100% rename from smoketest/src/helpers/screenshot.ts rename to test/smoke/src/helpers/screenshot.ts diff --git a/smoketest/src/helpers/utilities.ts b/test/smoke/src/helpers/utilities.ts similarity index 100% rename from smoketest/src/helpers/utilities.ts rename to test/smoke/src/helpers/utilities.ts diff --git a/smoketest/src/main.ts b/test/smoke/src/main.ts similarity index 100% rename from smoketest/src/main.ts rename to test/smoke/src/main.ts diff --git a/smoketest/src/spectron/application.ts b/test/smoke/src/spectron/application.ts similarity index 100% rename from smoketest/src/spectron/application.ts rename to test/smoke/src/spectron/application.ts diff --git a/smoketest/src/spectron/client.ts b/test/smoke/src/spectron/client.ts similarity index 100% rename from smoketest/src/spectron/client.ts rename to test/smoke/src/spectron/client.ts diff --git a/smoketest/tsconfig.json b/test/smoke/tsconfig.json similarity index 100% rename from smoketest/tsconfig.json rename to test/smoke/tsconfig.json -- GitLab From 75621d237d1e1760015e82c8a74c1fce55108540 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Mon, 22 May 2017 16:04:33 +0200 Subject: [PATCH 0200/1347] Corrected path to binary. --- test/smoke/scripts/run.ps1 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/smoke/scripts/run.ps1 b/test/smoke/scripts/run.ps1 index a7e29482a78..23da3827cbe 100644 --- a/test/smoke/scripts/run.ps1 +++ b/test/smoke/scripts/run.ps1 @@ -24,11 +24,11 @@ if (-Not (Test-Path node_modules)) { } # Configure environment variables -$env:VSCODE_LATEST_PATH = "$Root\VSCode-win32-$arch" +$env:VSCODE_LATEST_PATH = "$Root\VSCode-win32-$arch\Code - OSS.exe" # $env:VSCODE_STABLE_PATH = $stable $env:SMOKETEST_REPO = "..\vscode-smoketest-express" -if ($latest.Contains('Insiders')) { +if ($env:VSCODE_LATEST_PATH.Contains('Insiders')) { $env:VSCODE_EDITION = 'insiders' } -- GitLab From 29c5b3bbda4556f3a6c0f4bd98bb653c0c00656d Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Mon, 22 May 2017 16:08:39 +0200 Subject: [PATCH 0201/1347] Changed executable name. --- test/smoke/scripts/run.ps1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/smoke/scripts/run.ps1 b/test/smoke/scripts/run.ps1 index 23da3827cbe..a2b8c047113 100644 --- a/test/smoke/scripts/run.ps1 +++ b/test/smoke/scripts/run.ps1 @@ -24,7 +24,7 @@ if (-Not (Test-Path node_modules)) { } # Configure environment variables -$env:VSCODE_LATEST_PATH = "$Root\VSCode-win32-$arch\Code - OSS.exe" +$env:VSCODE_LATEST_PATH = "$Root\VSCode-win32-$arch\Code - Insiders.exe" # $env:VSCODE_STABLE_PATH = $stable $env:SMOKETEST_REPO = "..\vscode-smoketest-express" -- GitLab From c50481255f9878ed29684107759b0c1ba64d01b2 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Mon, 22 May 2017 16:52:50 +0200 Subject: [PATCH 0202/1347] Testing build definition. --- test/smoke/scripts/run.ps1 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/test/smoke/scripts/run.ps1 b/test/smoke/scripts/run.ps1 index a2b8c047113..5883ce0dbe8 100644 --- a/test/smoke/scripts/run.ps1 +++ b/test/smoke/scripts/run.ps1 @@ -17,6 +17,8 @@ if (-Not (Test-Path vscode-smoketest-express)) { } npm install +Write-Output "My path: " + $(pwd) + # Setup the test directory for running Set-Location ..\smoke if (-Not (Test-Path node_modules)) { @@ -24,7 +26,7 @@ if (-Not (Test-Path node_modules)) { } # Configure environment variables -$env:VSCODE_LATEST_PATH = "$Root\VSCode-win32-$arch\Code - Insiders.exe" +$env:VSCODE_LATEST_PATH = "$(pwd)\..\VSCode-win32-$arch\Code - Insiders.exe" # $env:VSCODE_STABLE_PATH = $stable $env:SMOKETEST_REPO = "..\vscode-smoketest-express" -- GitLab From 9b73f62ce3ab21195734262ca56875c66f726fdc Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 24 May 2017 16:36:35 +0200 Subject: [PATCH 0203/1347] Updated the way to run the smoke test. --- test/smoke/.vscode/launch.json | 2 +- test/smoke/CONTRIBUTING.md | 4 +- test/smoke/README.md | 4 +- test/smoke/package.json | 9 +- test/smoke/scripts/run.ps1 | 44 ------ test/smoke/scripts/run.sh | 43 ------ test/smoke/src/areas/common.ts | 12 +- test/smoke/src/areas/css.ts | 4 +- test/smoke/src/areas/data-loss.ts | 2 +- test/smoke/src/areas/extensions.ts | 2 +- test/smoke/src/areas/first-experience.ts | 2 +- test/smoke/src/areas/integrated-terminal.ts | 1 + test/smoke/src/areas/javascript-debug.ts | 2 +- test/smoke/src/areas/statusbar.ts | 6 +- test/smoke/src/areas/tasks.ts | 3 +- test/smoke/src/main.js | 163 ++++++++++++++++++++ test/smoke/src/mocha-runner.js | 21 +++ test/smoke/src/spectron/application.ts | 13 +- test/smoke/src/spectron/client.ts | 2 +- test/smoke/src/{main.ts => tests.ts} | 96 ++++++------ test/smoke/tsconfig.json | 2 +- vscode-smoketest-express | 1 - 22 files changed, 272 insertions(+), 166 deletions(-) delete mode 100644 test/smoke/scripts/run.ps1 delete mode 100644 test/smoke/scripts/run.sh create mode 100644 test/smoke/src/main.js create mode 100644 test/smoke/src/mocha-runner.js rename test/smoke/src/{main.ts => tests.ts} (93%) delete mode 160000 vscode-smoketest-express diff --git a/test/smoke/.vscode/launch.json b/test/smoke/.vscode/launch.json index 2de33bbb20b..25b4e7e4c0e 100644 --- a/test/smoke/.vscode/launch.json +++ b/test/smoke/.vscode/launch.json @@ -15,7 +15,7 @@ "--timeout", "999999", "--colors", - "${workspaceRoot}/out/main.js" + "${workspaceRoot}/out/tests.js" ], "outFiles": [ "${workspaceRoot}/out/**/*.js" ], "internalConsoleOptions": "openOnSessionStart", diff --git a/test/smoke/CONTRIBUTING.md b/test/smoke/CONTRIBUTING.md index c15016dc1ad..8aaef8a7875 100644 --- a/test/smoke/CONTRIBUTING.md +++ b/test/smoke/CONTRIBUTING.md @@ -1,5 +1,7 @@ # Architecture -* `main.ts` contains the main smoke test suite. It includes all tests separated into mocha `describe()` groups that represent each of the areas of [Smoke Test document](https://github.com/Microsoft/vscode/wiki/Smoke-Test). +* `main.js` is used to prepare all smoke test dependencies (fetching key bindings and 'Express' repository, running `npm install` there). +* `mocha-runner.js` launches Mocha programmatically. It is spawned in Node environment from main.js to ensure that it is possible to listen on `stderr`s (primary `process.stderr` is not readable otherwise). This is accomplished because WebDriverIO command deprecation warnings need to be redirected to a separate log. Those warnings are coming from WebDriverIO because ChromeDriver has not migrated from JsonWire to W3C WebDriver protocol. +* `tests.ts` contains the main smoke test suite. It includes all tests separated into mocha `describe()` groups that represent each of the areas of [Smoke Test document](https://github.com/Microsoft/vscode/wiki/Smoke-Test). * `./areas/` folder contains a `.ts` file per each area of the document. E.g. `'Search'` area goes under `'search.ts'`. Every area file contains a list of methods with the name that represents the action that can be performed in the corresponding test. This reduces the amount of test suite code and means that if the UI changes, the fix need only be applied in one place. The name of the method reflects the action the tester would do if he would perform the test manually. See [Selenium Page Objects Wiki](https://github.com/SeleniumHQ/selenium/wiki/PageObjects) and [Selenium Bot Style Tests Wiki](https://github.com/SeleniumHQ/selenium/wiki/Bot-Style-Tests) for a good explanation of the implementation. Every smoke test area contains methods that are used in a bot-style approach in `main.ts`. * `./spectron/` wraps the Spectron, with WebDriverIO API wrapped in `client.ts` and instance of Spectron Application is wrapped in `application.ts`. diff --git a/test/smoke/README.md b/test/smoke/README.md index 318ddb07517..501ec51f087 100644 --- a/test/smoke/README.md +++ b/test/smoke/README.md @@ -1,9 +1,9 @@ # VS Code Smoke Testing This repository contains the smoke test automation code with Spectron for Visual Studio Code. -The following command is used to run the tests: `.\scripts\run.ps1 -latest "path\to\Code.exe"` on Windows (from PowerShell) and `./scripts/run.sh path/to/binary` on Unix system. +The following command is used to run the tests: `npm test -- --latest "path/to/binary"`. -If you want to include 'Data Migration' area tests use `.\scripts\run.ps1 -latest "path\to\Code.exe" -stable "path\to\CurrentStable.exe"` and `./scripts/run.sh path/to/binary path/to/currentStable` respectively. +If you want to include 'Data Migration' area tests use `npm test -- --latest path/to/binary --stable path/to/currentStable` respectively. # Contributing diff --git a/test/smoke/package.json b/test/smoke/package.json index a5c3a78273b..4f637a5adf7 100644 --- a/test/smoke/package.json +++ b/test/smoke/package.json @@ -1,9 +1,10 @@ { "name": "code-oss-dev-smoke-test", "version": "0.1.0", - "main": "./out/main.js", + "main": "./src/main.js", "scripts": { - "test": "mocha -u tdd --timeout 360000 --retries 2 --slow 50000 --colors ./out/main.js 2> test_data/errors.log" + "pretest": "tsc", + "test": "node src/main.js" }, "devDependencies": { "@types/mocha": "^2.2.41", @@ -14,6 +15,8 @@ "mocha": "^3.2.0", "spectron": "^3.6.4", "typescript": "^2.2.2", - "rimraf": "^2.6.1" + "rimraf": "^2.6.1", + "commander": "^2.9.0", + "simple-git": "^1.73.0" } } diff --git a/test/smoke/scripts/run.ps1 b/test/smoke/scripts/run.ps1 deleted file mode 100644 index 5883ce0dbe8..00000000000 --- a/test/smoke/scripts/run.ps1 +++ /dev/null @@ -1,44 +0,0 @@ -Param( - [Parameter(Position=0,mandatory=$true)] - [string]$arch -) - - -# Setup sample repository for the smoke test -Set-Location .. -if (-Not (Test-Path vscode-smoketest-express)) { - git clone https://github.com/Microsoft/vscode-smoketest-express.git - Set-Location ./vscode-smoketest-express -} else { - Set-Location ./vscode-smoketest-express - git fetch origin master - git reset --hard FETCH_HEAD - git clean -fd -} -npm install - -Write-Output "My path: " + $(pwd) - -# Setup the test directory for running -Set-Location ..\smoke -if (-Not (Test-Path node_modules)) { - npm install -} - -# Configure environment variables -$env:VSCODE_LATEST_PATH = "$(pwd)\..\VSCode-win32-$arch\Code - Insiders.exe" -# $env:VSCODE_STABLE_PATH = $stable -$env:SMOKETEST_REPO = "..\vscode-smoketest-express" - -if ($env:VSCODE_LATEST_PATH.Contains('Insiders')) { - $env:VSCODE_EDITION = 'insiders' -} - -# Retrieve key bindings config file for Windows -$testDirectory = (Resolve-Path .\).Path -$client = New-Object System.Net.WebClient -$client.DownloadFile("https://raw.githubusercontent.com/Microsoft/vscode-docs/master/scripts/keybindings/doc.keybindings.win.json","$testDirectory\test_data\keybindings.win32.json") - -# Compile and launch the smoke test -tsc -npm test \ No newline at end of file diff --git a/test/smoke/scripts/run.sh b/test/smoke/scripts/run.sh deleted file mode 100644 index fc103a55539..00000000000 --- a/test/smoke/scripts/run.sh +++ /dev/null @@ -1,43 +0,0 @@ -#!/usr/bin/env bash -if [[ "$#" -ne 1 ]]; then - echo "Usage: ./scripts/run.sh path/to/binary" - echo "To perform data migration tests, use: ./scripts/run.sh path/to/latest_binary path/to/stable_binary" - exit 1 -fi - -# Cloning sample repository for the smoke test -cd .. -if ! [ -d vscode-smoketest-express ]; then - git clone https://github.com/Microsoft/vscode-smoketest-express.git - cd vscode-smoketest-express -else - cd vscode-smoketest-express - git fetch origin master - git reset --hard FETCH_HEAD - git clean -fd -fi -npm install - -# Install Node modules for Spectron -cd ../vscode-smoketest -test -d node_modules || npm install - -# Configuration -export VSCODE_LATEST_PATH="$1" -export VSCODE_STABLE_PATH="$2" -export SMOKETEST_REPO="../vscode-smoketest-express" -mkdir -p test_data - -if [[ $1 == *"Insiders"* || $1 == *"insiders"* ]]; then - export VSCODE_EDITION="insiders" -fi - -if [[ "$OSTYPE" == "darwin"* ]]; then - curl "https://raw.githubusercontent.com/Microsoft/vscode-docs/master/scripts/keybindings/doc.keybindings.osx.json" -o "test_data/keybindings.darwin.json" # Download OS X keybindings -else - wget https://raw.githubusercontent.com/Microsoft/vscode-docs/master/scripts/keybindings/doc.keybindings.linux.json -O test_data/keybindings.linux.json # Download Linux keybindings -fi - -# Compile and launch the smoke test -tsc -exec npm test diff --git a/test/smoke/src/areas/common.ts b/test/smoke/src/areas/common.ts index c955c206eea..33127905ec6 100644 --- a/test/smoke/src/areas/common.ts +++ b/test/smoke/src/areas/common.ts @@ -19,7 +19,7 @@ export class CommonActions { public async getWindowTitle(): Promise { return this.spectron.client.getTitle(); } - + public enter(): Promise { return this.spectron.client.keys(['Enter', 'NULL']); } @@ -34,7 +34,7 @@ export class CommonActions { await this.spectron.wait(); return this.saveOpenedFile(); } - + public async newUntitledFile(): Promise { await this.spectron.command('workbench.action.files.newUntitledFile'); return this.spectron.wait(); @@ -50,7 +50,7 @@ export class CommonActions { if (el.status === 0) { return el; } - + return undefined; } @@ -118,7 +118,7 @@ export class CommonActions { selector += ' explorer-item'; } selector += '"]'; - + await this.spectron.waitFor(this.spectron.client.doubleClick, selector); return this.spectron.wait(); } @@ -132,7 +132,7 @@ export class CommonActions { } else if (extension === 'md') { return 'md-ext-file-icon markdown-lang-file-icon'; } - + throw new Error('No class defined for this file extension'); } @@ -142,7 +142,7 @@ export class CommonActions { if (Array.isArray(span)) { return span[0]; } - + return span; } catch (e) { return undefined; diff --git a/test/smoke/src/areas/css.ts b/test/smoke/src/areas/css.ts index 3388ab4e465..d2cbd62b0a8 100644 --- a/test/smoke/src/areas/css.ts +++ b/test/smoke/src/areas/css.ts @@ -11,7 +11,7 @@ export enum CSSProblem { }; export class CSS { - + constructor(private spectron: SpectronApplication) { // noop } @@ -56,7 +56,7 @@ export class CSS { if (el.status === 0) { return el; } - + return undefined; } } \ No newline at end of file diff --git a/test/smoke/src/areas/data-loss.ts b/test/smoke/src/areas/data-loss.ts index dc1ecf93730..5988ce6f7f8 100644 --- a/test/smoke/src/areas/data-loss.ts +++ b/test/smoke/src/areas/data-loss.ts @@ -20,7 +20,7 @@ export class DataLoss { if (el.status === 0) { return el; } - + return undefined; } } \ No newline at end of file diff --git a/test/smoke/src/areas/extensions.ts b/test/smoke/src/areas/extensions.ts index 4edec9d06ef..bc4e2743e44 100644 --- a/test/smoke/src/areas/extensions.ts +++ b/test/smoke/src/areas/extensions.ts @@ -7,7 +7,7 @@ import { SpectronApplication } from '../spectron/application'; import { CommonActions } from "./common"; export class Extensions { - + private readonly extensionsViewletSelector = 'div[id="workbench.view.extensions"]'; constructor(private spectron: SpectronApplication, private common: CommonActions) { diff --git a/test/smoke/src/areas/first-experience.ts b/test/smoke/src/areas/first-experience.ts index e9141bda899..2d6e9c30eaa 100644 --- a/test/smoke/src/areas/first-experience.ts +++ b/test/smoke/src/areas/first-experience.ts @@ -15,7 +15,7 @@ export class FirstExperience { if (el.status === 0) { return el; } - + return undefined; } } \ No newline at end of file diff --git a/test/smoke/src/areas/integrated-terminal.ts b/test/smoke/src/areas/integrated-terminal.ts index b066db8adf7..c41f2946d4d 100644 --- a/test/smoke/src/areas/integrated-terminal.ts +++ b/test/smoke/src/areas/integrated-terminal.ts @@ -25,6 +25,7 @@ export class IntegratedTerminal { public async getCommandOutput(command: string): Promise { const selector = 'div[id="workbench.panel.terminal"] .xterm-rows'; + // Default Powershell terminal adds 3 header rows at the top, whereas bash does not. let readRow = process.platform === 'win32' ? 5 : 2; let output: string = await this.spectron.client.getText(`${selector}>:nth-child(${readRow})`); diff --git a/test/smoke/src/areas/javascript-debug.ts b/test/smoke/src/areas/javascript-debug.ts index 948594945d7..ff39a985d66 100644 --- a/test/smoke/src/areas/javascript-debug.ts +++ b/test/smoke/src/areas/javascript-debug.ts @@ -36,7 +36,7 @@ export class JavaScriptDebug { if (el.status === 0) { return el; } - + return undefined; } } \ No newline at end of file diff --git a/test/smoke/src/areas/statusbar.ts b/test/smoke/src/areas/statusbar.ts index 93b73495183..8e330c8e121 100644 --- a/test/smoke/src/areas/statusbar.ts +++ b/test/smoke/src/areas/statusbar.ts @@ -49,7 +49,7 @@ export class StatusBar { if (el.status === 0) { return el; } - + return undefined; } @@ -58,7 +58,7 @@ export class StatusBar { if (el.status === 0) { return el; } - + return undefined; } @@ -71,7 +71,7 @@ export class StatusBar { if (el.status === 0) { return el; } - + return undefined; } diff --git a/test/smoke/src/areas/tasks.ts b/test/smoke/src/areas/tasks.ts index e46c2961df5..d83cc173efa 100644 --- a/test/smoke/src/areas/tasks.ts +++ b/test/smoke/src/areas/tasks.ts @@ -25,6 +25,7 @@ export class Tasks { public async firstOutputLineEndsWith(fileName: string): Promise { const firstLine = await this.spectron.waitFor(this.spectron.client.getText, `${this.outputViewSelector}>:nth-child(2)`); + return firstLine.endsWith(fileName); } @@ -40,7 +41,7 @@ export class Tasks { return this.spectron.client.getValue(`${this.workbenchPanelSelector} .select-box`); } - public getProblemsViewFirstElementName(): Promise { + public getProblemsViewFirstElementName(): Promise { return this.spectron.waitFor(this.spectron.client.getText, `${this.problemsViewSelector} .label-name`); } diff --git a/test/smoke/src/main.js b/test/smoke/src/main.js new file mode 100644 index 00000000000..8df41b5c73c --- /dev/null +++ b/test/smoke/src/main.js @@ -0,0 +1,163 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +var fs = require('fs'); +var https = require('https'); +var program = require('commander'); +var git = require('simple-git')(); +var child_process = require('child_process'); +var path = require('path'); + +var tempFolder = `test_data`; +var testRepoUrl = 'https://github.com/Microsoft/vscode-smoketest-express'; +var testRepoLocalDir = path.join(process.cwd(), `${tempFolder}/vscode-smoketest-express`); +var keybindingsUrl = 'https://raw.githubusercontent.com/Microsoft/vscode-docs/master/scripts/keybindings'; + +program + .option('-l, --latest ', 'path to the latest VS Code to test') + .option('-s, --stable [file path]', 'path to the stable VS Code to be used in data migration tests'); + +program.on('--help', () => { + console.log(' Examples:'); + console.log(''); + console.log(' $ npm test -- --latest path/to/binary'); + console.log(' $ npm test -- -l path/to/binary'); + console.log(''); + console.log(' $ npm test -- --latest path/to/latest/binary --stable path/to/stable/binary'); + console.log(' $ npm test -- -l path/to/latest/binary -s path/to/stable/binary'); + console.log(''); +}); +program.parse(process.argv); + +if (!program.latest) { + console.error('You must specify the binary to run the smoke test against'); + process.exit(1); +} +if (!binaryExists(program.latest) || (program.stable && !binaryExists(program.stable))) { + console.error('The file path to electron binary does not exist or permissions do not allow to execute it. Please check the path provided.'); + process.exit(1); +} + +// Setting up environment variables +process.env['VSCODE_LATEST_PATH'] = program.latest; +if (program.stable) process.env['VSCODE_STABLE_PATH'] = program.stable; +process.env['SMOKETEST_REPO'] = testRepoLocalDir; +if (program.stable && program.stable.toLowerCase().startsWith('insiders')) process.env['VSCODE_EDITION'] = 'insiders'; + +// Setting up 'vscode-smoketest-express' project +var os = process.platform; +if (os === 'darwin') os = 'osx'; +else if (os === 'win32') os = 'win'; +var promises = []; + +try { + // promises.push(execute('npm install'), process.cwd()); + promises.push(getKeybindings(`${keybindingsUrl}/doc.keybindings.${os}.json`, `${tempFolder}/keybindings.json`)); + promises.push(cleanOrClone(testRepoUrl, testRepoLocalDir)); + + Promise.all(promises).then(() => { execute('npm install', testRepoLocalDir).then(() => runTests()); }); +} catch (e) { + throw new Error('Error caught running the smoke test: ' + e); +} + + +function runTests() { + console.log('Running tests...') + const spawn = require('child_process').spawn; + var proc = spawn(process.execPath, [ + 'src/mocha-runner.js' + ]); + proc.stdout.on('data', data => { + console.log(data.toString()); + }); + proc.stderr.on('data', data => { + var date = new Date().toLocaleString(); + fs.appendFile(`${tempFolder}/errors.log`, `${date}: ${data.toString()}`, (err) => { + if (err) throw new Error(`Could not write stderr to errors.log with the following error: ${err}`); + }); + }); +} + +function cleanOrClone(repo, dir) { + console.log('Cleaning or cloning test project repository...'); + return new Promise((res, rej) => { + if (!folderExists(dir)) { + git.clone(repo, dir, () => { + console.log('Test repository successfully cloned.'); + res(); + }); + } else { + git.cwd(dir); + git.fetch((err) => { + if (err) rej(err); + resetAndClean(); + }); + } + + var resetAndClean = () => { + git.reset(['FETCH_HEAD', '--hard'], (err) => { + if (err) rej(err); + + git.clean('f', ['-d'], (err) => { + if (err) rej(err); + console.log('Test project was successfully reset to initial state.'); + res(); + }); + }); + } + }); +} + +function execute(cmd, dir) { + return new Promise((res, rej) => { + console.log(`Running ${cmd}...`); + var output = child_process.exec(cmd, { cwd: dir, stdio: [0, 1, 2] }, (error, stdout, stderr) => { + if (error) rej(error); + if (stderr) console.error(stderr); + console.log(stdout); + res(); + }); + }); +} + +function getKeybindings(url, location) { + console.log(`Fetching keybindings from ${url}...`); + return new Promise((resolve, reject) => { + https.get(url, (res) => { + if (res.statusCode != 200) { + reject(`Failed to obtain key bindings with response code: ${res.statusCode}`); + } + + var buffer = []; + res.on('data', (chunk) => buffer.push(chunk)); + res.on('end', () => { + fs.writeFile(location, Buffer.concat(buffer), 'utf8', () => { + console.log('Keybindings were successfully fetched.'); + resolve(); + }); + }); + }).on('error', (e) => { + reject(`Failed to obtain key bindings with an error: ${e}`); + }); + }); +} + +function folderExists(folder) { + try { + fs.accessSync(folder, 'rw'); + return true; + } catch (e) { + return false; + } +} + +function binaryExists(filePath) { + try { + fs.accessSync(filePath, 'x'); + return true; + } catch (e) { + return false; + } +} \ No newline at end of file diff --git a/test/smoke/src/mocha-runner.js b/test/smoke/src/mocha-runner.js new file mode 100644 index 00000000000..2a08adca647 --- /dev/null +++ b/test/smoke/src/mocha-runner.js @@ -0,0 +1,21 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +var Mocha = require('mocha'); +var path = require('path'); + +var mocha = new Mocha({ + timeout: 360000, + retries: 2, + slow: 50000, + useColors: true +}); + +mocha.addFile(path.join(process.cwd(), 'out/tests.js')); +mocha.run((failures) => { + process.on('exit', () => { + process.exit(failures); + }); +}); \ No newline at end of file diff --git a/test/smoke/src/spectron/application.ts b/test/smoke/src/spectron/application.ts index 5e45474768c..d1027a1ef70 100644 --- a/test/smoke/src/spectron/application.ts +++ b/test/smoke/src/spectron/application.ts @@ -7,6 +7,7 @@ import { Application } from 'spectron'; import { SpectronClient } from './client'; import { Screenshot } from "../helpers/screenshot"; var fs = require('fs'); +var path = require('path'); /** * Wraps Spectron's Application instance with its used methods. @@ -16,7 +17,7 @@ export class SpectronApplication { private spectron: Application; private readonly pollTrials = 5; - private readonly pollTimeout = 3; // in secs + private readonly pollTimeout = 3; // in secs private keybindings: any[]; private screenshot: Screenshot; @@ -73,13 +74,15 @@ export class SpectronApplication { } private retrieveKeybindings() { - const os = process.platform; - fs.readFile(`test_data/keybindings.${os}.json`, (err, data) => { + fs.readFile(path.join(process.cwd(), `test_data/keybindings.json`), 'utf8', (err, data) => { if (err) { throw err; } - - this.keybindings = JSON.parse(data); + try { + this.keybindings = JSON.parse(data); + } catch (e) { + throw new Error(`Error parsing keybindings JSON: ${e}`); + } }); } diff --git a/test/smoke/src/spectron/client.ts b/test/smoke/src/spectron/client.ts index 9376bd3e100..6a9003199dc 100644 --- a/test/smoke/src/spectron/client.ts +++ b/test/smoke/src/spectron/client.ts @@ -7,7 +7,7 @@ import { Application } from 'spectron'; import { Screenshot } from '../helpers/screenshot'; /** - * Abstracts the Spectron's WebdriverIO managed client property on the created Application instances. + * Abstracts the Spectron's WebdriverIO managed client property on the created Application instances. */ export class SpectronClient { diff --git a/test/smoke/src/main.ts b/test/smoke/src/tests.ts similarity index 93% rename from test/smoke/src/main.ts rename to test/smoke/src/tests.ts index 9da55ce546a..35d6d1f79ac 100644 --- a/test/smoke/src/main.ts +++ b/test/smoke/src/tests.ts @@ -6,7 +6,7 @@ import * as assert from 'assert'; import { SpectronApplication } from "./spectron/application"; import { CommonActions } from './areas/common'; -import { FirstExperience } from './areas/first-experience'; +// import { FirstExperience } from './areas/first-experience'; import { ConfigurationView, ActivityBarPosition } from './areas/configuration-views'; import { Search } from './areas/search'; import { CSS, CSSProblem } from './areas/css'; @@ -23,14 +23,13 @@ import { Localization, ViewletType } from "./areas/localization"; describe('Smoke Test Suite', function () { const latestPath = process.env.VSCODE_LATEST_PATH; const stablePath = process.env.VSCODE_STABLE_PATH; - const insiders = process.env.VSCODE_EDITION; + // const insiders = process.env.VSCODE_EDITION; const workspacePath = process.env.SMOKETEST_REPO; const tempUserDir = 'test_data/temp_user_dir'; const tempExtensionsDir = 'test_data/temp_extensions_dir'; let app: SpectronApplication; let common: CommonActions; - this.retries(2); if (stablePath) { context('Data Migration', function () { @@ -176,37 +175,38 @@ describe('Smoke Test Suite', function () { }); }); - context('First User Experience', function () { - let experience: FirstExperience; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), undefined, [`--user-data-dir=${tempUserDir}`, `--excludeSwitches=load-component-extension`]); - common = new CommonActions(app); - experience = new FirstExperience(app); - - await common.removeDirectory(tempUserDir); - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it(`verifies if title is set correctly on the clean user-directory startup`, async function () { - const title = await common.getWindowTitle(); - - let expectedTitle = 'Welcome'; - if (process.platform !== 'darwin') { - expectedTitle += ' — Visual Studio Code'; - if (insiders) expectedTitle += ' - Insiders'; - } - - assert.equal(title, expectedTitle); - }); - - it(`verifies if 'Welcome page' tab is presented on the clean user-directory startup`, async function () { - assert.ok(await experience.getWelcomeTab()); - }); - }); + // Do not run until experiments are finished over the first-time startup behaviour. + // context('First User Experience', function () { + // let experience: FirstExperience; + + // beforeEach(async function () { + // app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), undefined, [`--user-data-dir=${tempUserDir}`, `--excludeSwitches=load-component-extension`]); + // common = new CommonActions(app); + // experience = new FirstExperience(app); + + // await common.removeDirectory(tempUserDir); + // return await app.start(); + // }); + // afterEach(async function () { + // return await app.stop(); + // }); + + // it(`verifies if title is set correctly on the clean user-directory startup`, async function () { + // const title = await common.getWindowTitle(); + + // let expectedTitle = 'Welcome'; + // if (process.platform !== 'darwin') { + // expectedTitle += ' — Visual Studio Code'; + // if (insiders) expectedTitle += ' - Insiders'; + // } + + // assert.equal(title, expectedTitle); + // }); + + // it(`verifies if 'Welcome page' tab is presented on the clean user-directory startup`, async function () { + // assert.ok(await experience.getWelcomeTab()); + // }); + // }); context('Explorer', function () { beforeEach(async function () { @@ -557,7 +557,6 @@ describe('Smoke Test Suite', function () { await common.type(command); await common.enter(); await app.wait(); - // Default Powershell terminal adds 3 header rows at the top, whereas bash does not. let output = await terminal.getCommandOutput(command); assert.equal(output, 'test'); }); @@ -660,7 +659,7 @@ describe('Smoke Test Suite', function () { const res = await tasks.getOutputResult(); assert.equal(res, '✖ 6 problems (6 errors, 0 warnings)'); }); - + it(`is able to select 'Git' output`, async function () { await tasks.build(); await app.wait(); @@ -674,7 +673,7 @@ describe('Smoke Test Suite', function () { assert.ok(await tasks.firstOutputLineEndsWith('index.js')); }); - it(`verifies build errors are reflected in 'Problems View'`, async function () { + it(`verifies build errors are reflected in 'Problems View'`, async function () { await tasks.build(); await app.wait(); await tasks.openProblemsView(); @@ -717,9 +716,9 @@ describe('Smoke Test Suite', function () { await extensions.installFirstResult(); await app.wait(); await extensions.getFirstReloadText(); - + await app.stop(); - await app.wait(); // wait until all resources are released (e.g. locked local storage) + await app.wait(); // wait until all resources are released (e.g. locked local storage) await app.start(); await extensions.selectMinimalIconsTheme(); const x = await extensions.verifyFolderIconAppearance(); @@ -739,13 +738,14 @@ describe('Smoke Test Suite', function () { common.removeDirectory(tempUserDir); await app.start(); - - let expectedTitle = 'Willkommen — vscode-smoketest-express'; - if (process.platform !== 'darwin') { - expectedTitle += ' — Visual Studio Code'; - if (insiders) expectedTitle += ' - Insiders'; - } - assert.equal(await common.getWindowTitle(), expectedTitle); + + // Do not run until experiments are finished over the first-time startup behaviour. + // let expectedTitle = 'Willkommen — vscode-smoketest-express'; + // if (process.platform !== 'darwin') { + // expectedTitle += ' — Visual Studio Code'; + // if (insiders) expectedTitle += ' - Insiders'; + // } + // assert.equal(await common.getWindowTitle(), expectedTitle); let text = await locale.getOpenEditorsText(); assert.equal(text.toLowerCase(), 'geöffnete editoren'); @@ -764,8 +764,8 @@ describe('Smoke Test Suite', function () { await locale.openViewlet(ViewletType.EXTENSIONS); text = await locale.getExtensionsSearchPlaceholder(); - assert.equal(text.toLowerCase(), 'nach extensions in marketplace suchen'); + assert.equal(text.toLowerCase(), 'nach erweiterungen im marketplace suchen'); }); }); - + }); \ No newline at end of file diff --git a/test/smoke/tsconfig.json b/test/smoke/tsconfig.json index 1b0b03c2d67..733c1107e83 100644 --- a/test/smoke/tsconfig.json +++ b/test/smoke/tsconfig.json @@ -18,4 +18,4 @@ "exclude": [ "node_modules" ] -} \ No newline at end of file +} diff --git a/vscode-smoketest-express b/vscode-smoketest-express deleted file mode 160000 index 636dd7a2ff7..00000000000 --- a/vscode-smoketest-express +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 636dd7a2ff71d266c0e015411b47cf5c3a25be5a -- GitLab From c925cfb72ce64af9856e447ef8559e7d928963cb Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 24 May 2017 17:37:22 +0200 Subject: [PATCH 0204/1347] Modularised tests. --- test/smoke/src/mocha-runner.js | 1 + test/smoke/src/spectron/application.ts | 8 +- test/smoke/src/tests.ts | 791 +------------------- test/smoke/src/tests/configuration-views.ts | 57 ++ test/smoke/src/tests/css.ts | 61 ++ test/smoke/src/tests/data-loss.ts | 76 ++ test/smoke/src/tests/data-migration.ts | 98 +++ test/smoke/src/tests/explorer.ts | 42 ++ test/smoke/src/tests/extensions.ts | 57 ++ test/smoke/src/tests/git.ts | 69 ++ test/smoke/src/tests/integrated-terminal.ts | 41 + test/smoke/src/tests/javascript-debug.ts | 44 ++ test/smoke/src/tests/javascript.ts | 86 +++ test/smoke/src/tests/localization.ts | 49 ++ test/smoke/src/tests/search.ts | 73 ++ test/smoke/src/tests/statusbar.ts | 94 +++ test/smoke/src/tests/tasks.ts | 56 ++ 17 files changed, 939 insertions(+), 764 deletions(-) create mode 100644 test/smoke/src/tests/configuration-views.ts create mode 100644 test/smoke/src/tests/css.ts create mode 100644 test/smoke/src/tests/data-loss.ts create mode 100644 test/smoke/src/tests/data-migration.ts create mode 100644 test/smoke/src/tests/explorer.ts create mode 100644 test/smoke/src/tests/extensions.ts create mode 100644 test/smoke/src/tests/git.ts create mode 100644 test/smoke/src/tests/integrated-terminal.ts create mode 100644 test/smoke/src/tests/javascript-debug.ts create mode 100644 test/smoke/src/tests/javascript.ts create mode 100644 test/smoke/src/tests/localization.ts create mode 100644 test/smoke/src/tests/search.ts create mode 100644 test/smoke/src/tests/statusbar.ts create mode 100644 test/smoke/src/tests/tasks.ts diff --git a/test/smoke/src/mocha-runner.js b/test/smoke/src/mocha-runner.js index 2a08adca647..8ea1dd905aa 100644 --- a/test/smoke/src/mocha-runner.js +++ b/test/smoke/src/mocha-runner.js @@ -5,6 +5,7 @@ var Mocha = require('mocha'); var path = require('path'); +var fs = require('fs'); var mocha = new Mocha({ timeout: 360000, diff --git a/test/smoke/src/spectron/application.ts b/test/smoke/src/spectron/application.ts index d1027a1ef70..0c8896bcc8d 100644 --- a/test/smoke/src/spectron/application.ts +++ b/test/smoke/src/spectron/application.ts @@ -9,6 +9,12 @@ import { Screenshot } from "../helpers/screenshot"; var fs = require('fs'); var path = require('path'); +export const LATEST_PATH = process.env.VSCODE_LATEST_PATH; +export const STABLE_PATH = process.env.VSCODE_STABLE_PATH; +export const WORKSPACE_PATH = process.env.SMOKETEST_REPO; +export const USER_DIR = 'test_data/temp_user_dir'; +export const EXTENSIONS_DIR = 'test_data/temp_extensions_dir'; + /** * Wraps Spectron's Application instance with its used methods. */ @@ -17,7 +23,7 @@ export class SpectronApplication { private spectron: Application; private readonly pollTrials = 5; - private readonly pollTimeout = 3; // in secs + private readonly pollTimeout = 3; // in secs private keybindings: any[]; private screenshot: Screenshot; diff --git a/test/smoke/src/tests.ts b/test/smoke/src/tests.ts index 35d6d1f79ac..17ca694e209 100644 --- a/test/smoke/src/tests.ts +++ b/test/smoke/src/tests.ts @@ -3,769 +3,34 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import * as assert from 'assert'; -import { SpectronApplication } from "./spectron/application"; -import { CommonActions } from './areas/common'; -// import { FirstExperience } from './areas/first-experience'; -import { ConfigurationView, ActivityBarPosition } from './areas/configuration-views'; -import { Search } from './areas/search'; -import { CSS, CSSProblem } from './areas/css'; -import { JavaScript } from './areas/javascript'; -import { JavaScriptDebug } from './areas/javascript-debug'; -import { Git } from './areas/git'; -import { IntegratedTerminal } from './areas/integrated-terminal'; -import { StatusBar, StatusBarElement } from './areas/statusBar'; -import { DataLoss } from './areas/data-loss'; -import { Tasks } from './areas/tasks'; -import { Extensions } from './areas/extensions'; -import { Localization, ViewletType } from "./areas/localization"; +import { dataLoss } from "./tests/data-loss"; +import { dataMigration } from "./tests/data-migration"; +import { explorer } from "./tests/explorer"; +import { configurationViews } from "./tests/configuration-views"; +import { search } from "./tests/search"; +import { css } from "./tests/css"; +import { javascript } from "./tests/javascript"; +import { javascriptDebug } from "./tests/javascript-debug"; +import { test_git } from "./tests/git"; +import { integratedTerminal } from "./tests/integrated-terminal"; +import { statusBar } from "./tests/statusbar"; +import { tasks } from "./tests/tasks"; +import { extensions } from "./tests/extensions"; +import { localization } from "./tests/localization"; describe('Smoke Test Suite', function () { - const latestPath = process.env.VSCODE_LATEST_PATH; - const stablePath = process.env.VSCODE_STABLE_PATH; - // const insiders = process.env.VSCODE_EDITION; - const workspacePath = process.env.SMOKETEST_REPO; - const tempUserDir = 'test_data/temp_user_dir'; - const tempExtensionsDir = 'test_data/temp_extensions_dir'; - - let app: SpectronApplication; - let common: CommonActions; - - if (stablePath) { - context('Data Migration', function () { - - afterEach(async function () { - await app.stop(); - return await common.removeDirectory(tempUserDir) - }); - - function setupSpectron(context: Mocha.ITestCallbackContext, appPath: string, workspace?: string[]): void { - app = new SpectronApplication(appPath, context.test.fullTitle(), context.test.currentRetry(), workspace, [`--user-data-dir=${tempUserDir}`]); - common = new CommonActions(app); - } - - it('checks if the Untitled file is restored migrating from stable to latest', async function () { - const textToType = 'Very dirty file'; - - // Setting up stable version - setupSpectron(this, stablePath); - await app.start(); - - await common.newUntitledFile(); - await common.type(textToType); - await app.stop(); - - await app.wait(); // wait until all resources are released (e.g. locked local storage) - - // Checking latest version for the restored state - setupSpectron(this, latestPath); - await app.start(); - - assert.ok(await common.getTab('Untitled-1')); - await common.selectTab('Untitled-1'); - const editorText = await common.getEditorFirstLinePlainText(); - assert.equal(editorText, textToType); - }); - - it('checks if the newly created dirty file is restored migrating from stable to latest', async function () { - const fileName = 'test_data/plainFile', - firstTextPart = 'This is going to be an unsaved file', secondTextPart = '_that is dirty.'; - - // Setting up stable version - setupSpectron(this, stablePath, [fileName]); - await common.removeFile(`${fileName}`); - await app.start(); - - await common.type(firstTextPart); - await common.saveOpenedFile(); - await app.wait(); - await common.type(secondTextPart); - - await app.stop(); - await app.wait(); // wait until all resources are released (e.g. locked local storage) - - // Checking latest version for the restored state - setupSpectron(this, latestPath); - await app.start(); - assert.ok(await common.getTab(fileName.split('/')[1])); - await common.selectTab(fileName.split('/')[1]); - const editorText = await common.getEditorFirstLinePlainText(); - assert.equal(editorText, firstTextPart.concat(secondTextPart)); - - // Cleanup - await common.removeFile(`${fileName}`); - }); - - it('cheks if opened tabs are restored migrating from stable to latest', async function () { - const fileName1 = 'app.js', fileName2 = 'jsconfig.json', fileName3 = 'readme.md'; - setupSpectron(this, stablePath, [workspacePath]); - await app.start(); - await common.openFile(fileName1, true); - await common.openFile(fileName2, true); - await common.openFile(fileName3, true); - await app.stop(); - - setupSpectron(this, latestPath, [workspacePath]); - await app.start(); - assert.ok(await common.getTab(fileName1)); - assert.ok(await common.getTab(fileName2)); - assert.ok(await common.getTab(fileName3)); - }); - }); - } - - context('Data Loss', function () { - let dataLoss: DataLoss; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath], [`--user-data-dir=${tempUserDir}`]); - common = new CommonActions(app); - dataLoss = new DataLoss(app); - await common.removeDirectory(tempUserDir); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it(`verifies that 'hot exit' works for dirty files`, async function () { - const textToType = 'Hello, Code!', fileName = 'readme.md', untitled = 'Untitled-1'; - await common.newUntitledFile(); - await common.type(textToType); - await dataLoss.openExplorerViewlet(); - await common.openFile(fileName, true); - await common.type(textToType); - - await app.stop(); - await app.start(); - - // check tab presence - assert.ok(await common.getTab(untitled)); - assert.ok(await common.getTab(fileName, true)); - // check if they marked as dirty (icon) and active tab is the last opened - assert.ok(await dataLoss.verifyTabIsDirty(untitled)); - assert.ok(await dataLoss.verifyTabIsDirty(fileName, true)); - }); - - it(`verifies that contents of the dirty files are restored after 'hot exit'`, async function () { - // make one dirty file, - // create one untitled file - const textToType = 'Hello, Code!'; - - // create one untitled file - await common.newUntitledFile(); - await app.wait(); - await common.type(textToType); - - // make one dirty file, - await common.openFile('readme.md', true); - await app.wait(); - await common.type(textToType); - - await app.stop(); - await app.start(); - - // check their contents - let fileDirt = await common.getEditorFirstLinePlainText(); - assert.equal(fileDirt, 'Hello, Code'); // ignore '!' as it is a separate , first part is enough - await common.selectTab('Untitled-1'); - fileDirt = await common.getEditorFirstLinePlainText(); - assert.equal(fileDirt, textToType); - }); - }); - - // Do not run until experiments are finished over the first-time startup behaviour. - // context('First User Experience', function () { - // let experience: FirstExperience; - - // beforeEach(async function () { - // app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), undefined, [`--user-data-dir=${tempUserDir}`, `--excludeSwitches=load-component-extension`]); - // common = new CommonActions(app); - // experience = new FirstExperience(app); - - // await common.removeDirectory(tempUserDir); - // return await app.start(); - // }); - // afterEach(async function () { - // return await app.stop(); - // }); - - // it(`verifies if title is set correctly on the clean user-directory startup`, async function () { - // const title = await common.getWindowTitle(); - - // let expectedTitle = 'Welcome'; - // if (process.platform !== 'darwin') { - // expectedTitle += ' — Visual Studio Code'; - // if (insiders) expectedTitle += ' - Insiders'; - // } - - // assert.equal(title, expectedTitle); - // }); - - // it(`verifies if 'Welcome page' tab is presented on the clean user-directory startup`, async function () { - // assert.ok(await experience.getWelcomeTab()); - // }); - // }); - - context('Explorer', function () { - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); - common = new CommonActions(app); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it('quick open search produces correct result', async function () { - await common.openQuickOpen(); - await common.type('.js'); - await app.wait(); - const elCount = await common.getQuickOpenElements(); - assert.equal(elCount, 7); - }); - - it('quick open respects fuzzy matching', async function () { - await common.openQuickOpen(); - await common.type('a.s'); - await app.wait(); - const elCount = await common.getQuickOpenElements(); - assert.equal(elCount, 3); - }); - }); - - context('Configuration and views', function () { - let configView: ConfigurationView; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); - common = new CommonActions(app); - configView = new ConfigurationView(app); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it('turns off editor line numbers and verifies the live change', async function () { - await common.newUntitledFile(); - await app.wait(); - let elements = await configView.getEditorLineNumbers(); - assert.equal(elements.value.length, 1); - await common.addSetting('editor.lineNumbers', 'off'); - await app.wait(); - elements = await configView.getEditorLineNumbers(); - assert.equal(elements.value.length, 0); - }); - - it(`changes 'workbench.action.toggleSidebarPosition' command key binding and verifies it`, async function () { - await configView.enterKeybindingsView() - await common.type('workbench.action.toggleSidebarPosition'); - await app.wait(); - await configView.selectFirstKeybindingsMatch(); - await configView.changeKeybinding(); - await configView.enterBinding(['Control', 'u', 'NULL']); - await common.enter(); - let html = await configView.getActivityBar(ActivityBarPosition.RIGHT); - assert.equal(html, undefined);; - await app.wait(); - await configView.toggleActivityBarPosition(); - html = await configView.getActivityBar(ActivityBarPosition.RIGHT); - assert.ok(html); - }); - }); - - context('Search', function () { - let search: Search; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); - common = new CommonActions(app); - search = new Search(app); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it('searches for body & checks for correct result number', async function () { - const s = search; - await s.openSearchViewlet(); - await s.searchFor('body'); - const result = await s.getResultText(); - assert.equal(result, '7 results in 4 files'); - }); - - it('searches only for *.js files & checks for correct result number', async function () { - const s = search; - await s.openSearchViewlet(); - await s.searchFor('body'); - await s.toggleSearchDetails(); - await s.searchFor('*.js'); - const results = await s.getResultText(); - assert.equal(results, '4 results in 1 file'); - }); - - it('dismisses result & checks for correct result number', async function () { - const s = search; - await s.openSearchViewlet() - await s.searchFor('body'); - await s.hoverOverResultCount(); - await s.dismissResult(); - await app.wait(); - const result = await s.getResultText(); - assert.equal(result, '3 results in 3 files') - }); - - it('replaces first search result with a replace term', async function () { - const s = search; - await s.openSearchViewlet() - await s.searchFor('body'); - await s.toggleReplace(); - await s.setReplaceText('ydob'); - await s.hoverOverResultCount(); - await s.replaceFirstMatch(); - await app.wait(); - await common.saveOpenedFile(); - const result = await s.getResultText(); - assert.equal(result, '3 results in 3 files'); - }); - }); - - context('CSS', function () { - let css: CSS; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); - common = new CommonActions(app); - css = new CSS(app); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it('verifies quick outline', async function () { - await common.openFirstMatchFile('style.css'); - await css.openQuickOutline(); - await app.wait(); - const count = await common.getQuickOpenElements(); - assert.equal(count, 2); - }); - - it('verifies warnings for the empty rule', async function () { - await common.openFirstMatchFile('style.css'); - await common.type('.foo{}'); - await app.wait(); - let warning = await css.getEditorProblem(CSSProblem.WARNING); - assert.ok(warning); - await css.toggleProblemsView(); - warning = await css.getProblemsViewsProblem(CSSProblem.WARNING); - assert.ok(warning); - }); - - it('verifies that warning becomes an error once setting changed', async function () { - await common.addSetting('css.lint.emptyRules', 'error'); - await common.openFirstMatchFile('style.css'); - await common.type('.foo{}'); - await app.wait(); - let error = await css.getEditorProblem(CSSProblem.ERROR); - assert.ok(error); - await css.toggleProblemsView(); - error = await css.getProblemsViewsProblem(CSSProblem.ERROR); - assert.ok(error); - }); - }); - - context('JavaScript', function () { - let js: JavaScript; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); - common = new CommonActions(app); - js = new JavaScript(app); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it('shows correct quick outline', async function () { - await common.openFirstMatchFile('bin/www'); - await js.openQuickOutline(); - await app.wait(); - const symbols = await common.getQuickOpenElements(); - assert.equal(symbols, 12); - }); - - it(`finds 'All References' to 'app'`, async function () { - await common.openFirstMatchFile('bin/www'); - await app.wait(); - await js.findAppReferences(); - const titleCount = await js.getTitleReferencesCount(); - assert.equal(titleCount, 3); - const treeCount = await js.getTreeReferencesCount(); - assert.equal(treeCount, 3); - }); - - it(`renames local 'app' variable`, async function () { - await common.openFirstMatchFile('bin/www'); - - const newVarName = 'newApp'; - await js.renameApp(newVarName); - await common.enter(); - const newName = await js.getNewAppName(); - assert.equal(newName, newVarName); - }); - - it('folds/unfolds the code correctly', async function () { - await common.openFirstMatchFile('bin/www'); - // Fold - await js.toggleFirstCommentFold(); - const foldedIcon = await js.getFirstCommentFoldedIcon(); - assert.ok(foldedIcon); - let nextLineNumber = await js.getNextLineNumberAfterFold(); - assert.equal(nextLineNumber, 7); - // Unfold - await js.toggleFirstCommentFold(); - nextLineNumber = await js.getNextLineNumberAfterFold(); - assert.equal(nextLineNumber, 4); - }); - - it(`verifies that 'Go To Definition' works`, async function () { - await common.openFirstMatchFile('app.js'); - await js.goToExpressDefinition(); - await app.wait(); - assert.ok(await common.getTab('index.d.ts')); - }); - - it(`verifies that 'Peek Definition' works`, async function () { - await common.openFirstMatchFile('app.js'); - await js.peekExpressDefinition(); - const definitionFilename = await js.getPeekExpressResultName(); - assert.equal(definitionFilename, 'index.d.ts'); - }); - }); - - context('Debugging JavaScript', function () { - let jsDebug: JavaScriptDebug; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); - common = new CommonActions(app); - jsDebug = new JavaScriptDebug(app); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it('autodetects program attribute for launch.json', async function () { - await jsDebug.openDebugViewlet(); - await jsDebug.pressConfigureLaunchJson(); - const value = await jsDebug.getProgramConfigValue(); - process.platform === 'win32' ? assert.equal(value, '"${workspaceRoot}\\\\bin\\\\www"') : assert.equal(value, '"${workspaceRoot}/bin/www"'); - }); - - it(`can set a breakpoint and verify if it's set`, async function () { - await common.openFirstMatchFile('index.js'); - await jsDebug.setBreakpointOnLine(6); - const breakpoint = await jsDebug.verifyBreakpointOnLine(6); - assert.ok(breakpoint); - }); - }); - - context('Git', function () { - let git: Git; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); - common = new CommonActions(app); - git = new Git(app, common); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it('verifies current changes are picked up by Git viewlet', async function () { - const changesCount = await git.getScmIconChanges(); - assert.equal(changesCount, 2); - await git.openGitViewlet(); - assert.ok(await git.verifyScmChange('app.js')); - assert.ok(await git.verifyScmChange('launch.json')); - }); - - it(`verifies 'app.js' diff viewer changes`, async function () { - await git.openGitViewlet(); - await common.openFile('app.js'); - const original = await git.getOriginalAppJsBodyVarName(); - assert.equal(original, 'bodyParser'); - const modified = await git.getModifiedAppJsBodyVarName(); - assert.equal(modified, 'ydobParser'); - }); - - it(`stages 'app.js' changes and checks stage count`, async function () { - await git.openGitViewlet(); - await app.wait(); - await git.stageFile('app.js'); - const stagedCount = await git.getStagedCount(); - assert.equal(stagedCount, 1); - - // Return back to unstaged state - await git.unstageFile('app.js'); - }); - - it(`stages, commits change to 'app.js' locally and verifies outgoing change`, async function () { - await git.openGitViewlet(); - await app.wait(); - await git.stageFile('app.js'); - await git.focusOnCommitBox(); - await common.type('Test commit'); - await git.pressCommit(); - const changes = await git.getOutgoingChanges(); - assert.equal(changes, ' 0↓ 1↑'); - }); - }); - - context('Integrated Terminal', function () { - let terminal: IntegratedTerminal; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); - common = new CommonActions(app); - terminal = new IntegratedTerminal(app); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it(`opens terminal, runs 'echo' and verifies the output`, async function () { - const command = 'echo test'; - await terminal.openTerminal(common); - await app.wait(); - await common.type(command); - await common.enter(); - await app.wait(); - let output = await terminal.getCommandOutput(command); - assert.equal(output, 'test'); - }); - }); - - context('Status Bar', function () { - let statusBar: StatusBar; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); - common = new CommonActions(app); - statusBar = new StatusBar(app); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it('verifies presence of all default status bar elements', async function () { - await app.wait(); - assert.ok(await statusBar.isVisible(StatusBarElement.BRANCH_STATUS)); - assert.ok(await statusBar.isVisible(StatusBarElement.FEEDBACK_ICON)); - assert.ok(await statusBar.isVisible(StatusBarElement.SYNC_STATUS)); - assert.ok(await statusBar.isVisible(StatusBarElement.PROBLEMS_STATUS)); - - await common.openFirstMatchFile('app.js'); - assert.ok(await statusBar.isVisible(StatusBarElement.ENCODING_STATUS)); - assert.ok(await statusBar.isVisible(StatusBarElement.EOL_STATUS)); - assert.ok(await statusBar.isVisible(StatusBarElement.INDENTATION_STATUS)); - assert.ok(await statusBar.isVisible(StatusBarElement.LANGUAGE_STATUS)); - assert.ok(await statusBar.isVisible(StatusBarElement.SELECTION_STATUS)); - }); - - it(`verifies that 'quick open' opens when clicking on 'Branch', 'Indentation Status, 'Encoding', 'EOL' and 'Language' status elements`, async function () { - await app.wait(); - await statusBar.clickOn(StatusBarElement.BRANCH_STATUS); - assert.ok(await statusBar.isQuickOpenWidgetVisible()); - await common.closeQuickOpen(); - - await common.openFirstMatchFile('app.js'); - await statusBar.clickOn(StatusBarElement.INDENTATION_STATUS); - assert.ok(await statusBar.isQuickOpenWidgetVisible()); - await common.closeQuickOpen(); - await statusBar.clickOn(StatusBarElement.ENCODING_STATUS); - assert.ok(await statusBar.isQuickOpenWidgetVisible()); - await common.closeQuickOpen(); - await statusBar.clickOn(StatusBarElement.EOL_STATUS); - assert.ok(await statusBar.isQuickOpenWidgetVisible()); - await common.closeQuickOpen(); - await statusBar.clickOn(StatusBarElement.LANGUAGE_STATUS); - assert.ok(await statusBar.isQuickOpenWidgetVisible()); - await common.closeQuickOpen(); - }); - - it(`verifies that 'Problems View' appears when clicking on 'Problems' status element`, async function () { - await statusBar.clickOn(StatusBarElement.PROBLEMS_STATUS); - assert.ok(await statusBar.getProblemsView()); - }); - - it(`verifies that 'Tweet us feedback' pop-up appears when clicking on 'Feedback' icon`, async function () { - await statusBar.clickOn(StatusBarElement.FEEDBACK_ICON); - assert.ok(await statusBar.getFeedbackView()); - }); - - it(`checks if 'Go to Line' works if called from the status bar`, async function () { - await common.openFirstMatchFile('app.js'); - await statusBar.clickOn(StatusBarElement.SELECTION_STATUS); - const lineNumber = 15; - await common.type(lineNumber.toString()); - await common.enter(); - assert.ok(await statusBar.getEditorHighlightedLine(lineNumber)); - }); - - it(`verifies if changing EOL is reflected in the status bar`, async function () { - await common.openFirstMatchFile('app.js'); - await statusBar.clickOn(StatusBarElement.EOL_STATUS); - await common.selectNextQuickOpenElement(); - await common.enter(); - const currentEOL = await statusBar.getEOLMode(); - assert.equal(currentEOL, 'CRLF'); - }); - }); - - context('Tasks', function () { - let tasks: Tasks; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath]); - tasks = new Tasks(app); - - return await app.start(); - }); - afterEach(async function () { - return await app.stop(); - }); - - it('verifies that build task produces 6 errors', async function () { - await tasks.build(); - const res = await tasks.getOutputResult(); - assert.equal(res, '✖ 6 problems (6 errors, 0 warnings)'); - }); - - it(`is able to select 'Git' output`, async function () { - await tasks.build(); - await app.wait(); - await tasks.selectOutputViewType('Git'); - const viewType = await tasks.getOutputViewType(); - assert.equal(viewType, 'Git'); - }); - - it('ensures that build task produces errors in index.js', async function () { - await tasks.build(); - assert.ok(await tasks.firstOutputLineEndsWith('index.js')); - }); - - it(`verifies build errors are reflected in 'Problems View'`, async function () { - await tasks.build(); - await app.wait(); - await tasks.openProblemsView(); - const problemName = await tasks.getProblemsViewFirstElementName(); - assert.equal(problemName, 'index.js'); - const problemsCount = await tasks.getProblemsViewFirstElementCount(); - assert.equal(problemsCount, '6'); - }); - }); - - context('Extensions', function () { - let extensions: Extensions; - - beforeEach(async function () { - app = new SpectronApplication(latestPath, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [workspacePath], [`--extensions-dir=${tempExtensionsDir}`]); - common = new CommonActions(app); - extensions = new Extensions(app, common); - await common.removeDirectory(tempExtensionsDir); - - return await app.start(); - }); - afterEach(async function () { - await app.stop(); - return await common.removeDirectory(tempExtensionsDir); - }); - - it(`installs 'vscode-icons' extension and verifies reload is prompted`, async function () { - await extensions.openExtensionsViewlet(); - await extensions.searchForExtension('vscode-icons'); - await app.wait(); - await extensions.installFirstResult(); - await app.wait(); - assert.ok(await extensions.getFirstReloadText()); - }); - - it(`installs an extension and checks if it works on restart`, async function () { - await extensions.openExtensionsViewlet(); - await extensions.searchForExtension('vscode-icons'); - await app.wait(); - await extensions.installFirstResult(); - await app.wait(); - await extensions.getFirstReloadText(); - - await app.stop(); - await app.wait(); // wait until all resources are released (e.g. locked local storage) - await app.start(); - await extensions.selectMinimalIconsTheme(); - const x = await extensions.verifyFolderIconAppearance(); - assert.ok(x); - }); - }); - - context('Localization', function () { - afterEach(async function () { - return await app.stop(); - }); - - it(`starts with 'DE' locale and verifies title and viewlets text is in German`, async function () { - app = new SpectronApplication(latestPath, this.test.fullTitle(), this.test.currentRetry(), [workspacePath, '--locale=DE'], [`--user-data-dir=${tempUserDir}`]); - common = new CommonActions(app); - const locale = new Localization(app); - common.removeDirectory(tempUserDir); - - await app.start(); - - // Do not run until experiments are finished over the first-time startup behaviour. - // let expectedTitle = 'Willkommen — vscode-smoketest-express'; - // if (process.platform !== 'darwin') { - // expectedTitle += ' — Visual Studio Code'; - // if (insiders) expectedTitle += ' - Insiders'; - // } - // assert.equal(await common.getWindowTitle(), expectedTitle); - - let text = await locale.getOpenEditorsText(); - assert.equal(text.toLowerCase(), 'geöffnete editoren'); - - await locale.openViewlet(ViewletType.SEARCH); - text = await locale.getOpenedViewletTitle() - assert.equal(text.toLowerCase(), 'suchen'); - - await locale.openViewlet(ViewletType.SCM); - text = await locale.getOpenedViewletTitle(); - assert.equal(text.toLowerCase(), 'quellcodeverwaltung: git'); - - await locale.openViewlet(ViewletType.DEBUG); - text = await locale.getOpenedViewletTitle(); - assert.equal(text.toLowerCase(), 'debuggen'); - - await locale.openViewlet(ViewletType.EXTENSIONS); - text = await locale.getExtensionsSearchPlaceholder(); - assert.equal(text.toLowerCase(), 'nach erweiterungen im marketplace suchen'); - }); - }); - + dataMigration(); + dataLoss(); + explorer(); + configurationViews(); + search(); + css(); + javascript(); + javascriptDebug(); + test_git(); + integratedTerminal(); + statusBar(); + tasks(); + extensions(); + localization(); }); \ No newline at end of file diff --git a/test/smoke/src/tests/configuration-views.ts b/test/smoke/src/tests/configuration-views.ts new file mode 100644 index 00000000000..2f61f3337fb --- /dev/null +++ b/test/smoke/src/tests/configuration-views.ts @@ -0,0 +1,57 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { ConfigurationView, ActivityBarPosition } from "../areas/configuration-views"; + +let app: SpectronApplication; +let common: CommonActions; + +export function configurationViews() { + context('Configuration and views', function () { + let configView: ConfigurationView; + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); + common = new CommonActions(app); + configView = new ConfigurationView(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('turns off editor line numbers and verifies the live change', async function () { + await common.newUntitledFile(); + await app.wait(); + let elements = await configView.getEditorLineNumbers(); + assert.equal(elements.value.length, 1); + await common.addSetting('editor.lineNumbers', 'off'); + await app.wait(); + elements = await configView.getEditorLineNumbers(); + assert.equal(elements.value.length, 0); + }); + + it(`changes 'workbench.action.toggleSidebarPosition' command key binding and verifies it`, async function () { + await configView.enterKeybindingsView(); + await common.type('workbench.action.toggleSidebarPosition'); + await app.wait(); + await configView.selectFirstKeybindingsMatch(); + await configView.changeKeybinding(); + await configView.enterBinding(['Control', 'u', 'NULL']); + await common.enter(); + let html = await configView.getActivityBar(ActivityBarPosition.RIGHT); + assert.equal(html, undefined);; + await app.wait(); + await configView.toggleActivityBarPosition(); + html = await configView.getActivityBar(ActivityBarPosition.RIGHT); + assert.ok(html); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/css.ts b/test/smoke/src/tests/css.ts new file mode 100644 index 00000000000..01a0bddbe25 --- /dev/null +++ b/test/smoke/src/tests/css.ts @@ -0,0 +1,61 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { CSS, CSSProblem } from '../areas/css'; + +let app: SpectronApplication; +let common: CommonActions; + +export function css() { + context('CSS', function () { + let css: CSS; + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); + common = new CommonActions(app); + css = new CSS(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('verifies quick outline', async function () { + await common.openFirstMatchFile('style.css'); + await css.openQuickOutline(); + await app.wait(); + const count = await common.getQuickOpenElements(); + assert.equal(count, 2); + }); + + it('verifies warnings for the empty rule', async function () { + await common.openFirstMatchFile('style.css'); + await common.type('.foo{}'); + await app.wait(); + let warning = await css.getEditorProblem(CSSProblem.WARNING); + assert.ok(warning); + await css.toggleProblemsView(); + warning = await css.getProblemsViewsProblem(CSSProblem.WARNING); + assert.ok(warning); + }); + + it('verifies that warning becomes an error once setting changed', async function () { + await common.addSetting('css.lint.emptyRules', 'error'); + await common.openFirstMatchFile('style.css'); + await common.type('.foo{}'); + await app.wait(); + let error = await css.getEditorProblem(CSSProblem.ERROR); + assert.ok(error); + await css.toggleProblemsView(); + error = await css.getProblemsViewsProblem(CSSProblem.ERROR); + assert.ok(error); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/data-loss.ts b/test/smoke/src/tests/data-loss.ts new file mode 100644 index 00000000000..4be1635cfce --- /dev/null +++ b/test/smoke/src/tests/data-loss.ts @@ -0,0 +1,76 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, USER_DIR, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { DataLoss } from "../areas/data-loss"; + +let app: SpectronApplication; +let common: CommonActions; +let dl: DataLoss; + +export function dataLoss() { + context('Data Loss', function () { + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH], [`--user-data-dir=${USER_DIR}`]); + common = new CommonActions(app); + dl = new DataLoss(app); + await common.removeDirectory(USER_DIR); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it(`verifies that 'hot exit' works for dirty files`, async function () { + const textToType = 'Hello, Code!', fileName = 'readme.md', untitled = 'Untitled-1'; + await common.newUntitledFile(); + await common.type(textToType); + await dl.openExplorerViewlet(); + await common.openFile(fileName, true); + await common.type(textToType); + + await app.stop(); + await app.start(); + + // check tab presence + assert.ok(await common.getTab(untitled)); + assert.ok(await common.getTab(fileName, true)); + // check if they marked as dirty (icon) and active tab is the last opened + assert.ok(await dl.verifyTabIsDirty(untitled)); + assert.ok(await dl.verifyTabIsDirty(fileName, true)); + }); + + it(`verifies that contents of the dirty files are restored after 'hot exit'`, async function () { + // make one dirty file, + // create one untitled file + const textToType = 'Hello, Code!'; + + // create one untitled file + await common.newUntitledFile(); + await app.wait(); + await common.type(textToType); + + // make one dirty file, + await common.openFile('readme.md', true); + await app.wait(); + await common.type(textToType); + + await app.stop(); + await app.start(); + + // check their contents + let fileDirt = await common.getEditorFirstLinePlainText(); + assert.equal(fileDirt, 'Hello, Code'); // ignore '!' as it is a separate , first part is enough + await common.selectTab('Untitled-1'); + fileDirt = await common.getEditorFirstLinePlainText(); + assert.equal(fileDirt, textToType); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/data-migration.ts b/test/smoke/src/tests/data-migration.ts new file mode 100644 index 00000000000..0dba58deccb --- /dev/null +++ b/test/smoke/src/tests/data-migration.ts @@ -0,0 +1,98 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, USER_DIR, STABLE_PATH, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; + +let app: SpectronApplication; +let common: CommonActions; + +export function dataMigration() { + if (!STABLE_PATH) { + return; + } + context('Data Migration', function () { + + afterEach(async function () { + await app.stop(); + return await common.removeDirectory(USER_DIR) + }); + + function setupSpectron(context: Mocha.ITestCallbackContext, appPath: string, workspace?: string[]): void { + app = new SpectronApplication(appPath, context.test.fullTitle(), context.test.currentRetry(), workspace, [`--user-data-dir=${USER_DIR}`]); + common = new CommonActions(app); + } + + it('checks if the Untitled file is restored migrating from stable to latest', async function () { + const textToType = 'Very dirty file'; + + // Setting up stable version + setupSpectron(this, STABLE_PATH); + await app.start(); + + await common.newUntitledFile(); + await common.type(textToType); + await app.stop(); + + await app.wait(); // wait until all resources are released (e.g. locked local storage) + + // Checking latest version for the restored state + setupSpectron(this, LATEST_PATH); + await app.start(); + + assert.ok(await common.getTab('Untitled-1')); + await common.selectTab('Untitled-1'); + const editorText = await common.getEditorFirstLinePlainText(); + assert.equal(editorText, textToType); + }); + + it('checks if the newly created dirty file is restored migrating from stable to latest', async function () { + const fileName = 'test_data/plainFile', + firstTextPart = 'This is going to be an unsaved file', secondTextPart = '_that is dirty.'; + + // Setting up stable version + setupSpectron(this, STABLE_PATH, [fileName]); + await common.removeFile(`${fileName}`); + await app.start(); + + await common.type(firstTextPart); + await common.saveOpenedFile(); + await app.wait(); + await common.type(secondTextPart); + + await app.stop(); + await app.wait(); // wait until all resources are released (e.g. locked local storage) + + // Checking latest version for the restored state + setupSpectron(this, LATEST_PATH); + await app.start(); + assert.ok(await common.getTab(fileName.split('/')[1])); + await common.selectTab(fileName.split('/')[1]); + const editorText = await common.getEditorFirstLinePlainText(); + assert.equal(editorText, firstTextPart.concat(secondTextPart)); + + // Cleanup + await common.removeFile(`${fileName}`); + }); + + it('cheks if opened tabs are restored migrating from stable to latest', async function () { + const fileName1 = 'app.js', fileName2 = 'jsconfig.json', fileName3 = 'readme.md'; + setupSpectron(this, STABLE_PATH, [WORKSPACE_PATH]); + await app.start(); + await common.openFile(fileName1, true); + await common.openFile(fileName2, true); + await common.openFile(fileName3, true); + await app.stop(); + + setupSpectron(this, LATEST_PATH, [WORKSPACE_PATH]); + await app.start(); + assert.ok(await common.getTab(fileName1)); + assert.ok(await common.getTab(fileName2)); + assert.ok(await common.getTab(fileName3)); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/explorer.ts b/test/smoke/src/tests/explorer.ts new file mode 100644 index 00000000000..83c2d114196 --- /dev/null +++ b/test/smoke/src/tests/explorer.ts @@ -0,0 +1,42 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; + +let app: SpectronApplication; +let common: CommonActions; + +export function explorer() { + context('Explorer', function () { + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); + common = new CommonActions(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('quick open search produces correct result', async function () { + await common.openQuickOpen(); + await common.type('.js'); + await app.wait(); + const elCount = await common.getQuickOpenElements(); + assert.equal(elCount, 7); + }); + + it('quick open respects fuzzy matching', async function () { + await common.openQuickOpen(); + await common.type('a.s'); + await app.wait(); + const elCount = await common.getQuickOpenElements(); + assert.equal(elCount, 3); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/extensions.ts b/test/smoke/src/tests/extensions.ts new file mode 100644 index 00000000000..a545dd7c674 --- /dev/null +++ b/test/smoke/src/tests/extensions.ts @@ -0,0 +1,57 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH, EXTENSIONS_DIR } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { Extensions } from "../areas/extensions"; + +let app: SpectronApplication; +let common: CommonActions; + +export function extensions() { + context('Extensions', function () { + let extensions: Extensions; + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH], [`--extensions-dir=${EXTENSIONS_DIR}`]); + common = new CommonActions(app); + extensions = new Extensions(app, common); + await common.removeDirectory(EXTENSIONS_DIR); + + return await app.start(); + }); + afterEach(async function () { + await app.stop(); + return await common.removeDirectory(EXTENSIONS_DIR); + }); + + it(`installs 'vscode-icons' extension and verifies reload is prompted`, async function () { + await extensions.openExtensionsViewlet(); + await extensions.searchForExtension('vscode-icons'); + await app.wait(); + await extensions.installFirstResult(); + await app.wait(); + assert.ok(await extensions.getFirstReloadText()); + }); + + it(`installs an extension and checks if it works on restart`, async function () { + await extensions.openExtensionsViewlet(); + await extensions.searchForExtension('vscode-icons'); + await app.wait(); + await extensions.installFirstResult(); + await app.wait(); + await extensions.getFirstReloadText(); + + await app.stop(); + await app.wait(); // wait until all resources are released (e.g. locked local storage) + await app.start(); + await extensions.selectMinimalIconsTheme(); + const x = await extensions.verifyFolderIconAppearance(); + assert.ok(x); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/git.ts b/test/smoke/src/tests/git.ts new file mode 100644 index 00000000000..11d568c7f8b --- /dev/null +++ b/test/smoke/src/tests/git.ts @@ -0,0 +1,69 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { Git } from "../areas/git"; + +let app: SpectronApplication; +let common: CommonActions; + +export function test_git() { + context('Git', function () { + let git: Git; + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); + common = new CommonActions(app); + git = new Git(app, common); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('verifies current changes are picked up by Git viewlet', async function () { + const changesCount = await git.getScmIconChanges(); + assert.equal(changesCount, 2); + await git.openGitViewlet(); + assert.ok(await git.verifyScmChange('app.js')); + assert.ok(await git.verifyScmChange('launch.json')); + }); + + it(`verifies 'app.js' diff viewer changes`, async function () { + await git.openGitViewlet(); + await common.openFile('app.js'); + const original = await git.getOriginalAppJsBodyVarName(); + assert.equal(original, 'bodyParser'); + const modified = await git.getModifiedAppJsBodyVarName(); + assert.equal(modified, 'ydobParser'); + }); + + it(`stages 'app.js' changes and checks stage count`, async function () { + await git.openGitViewlet(); + await app.wait(); + await git.stageFile('app.js'); + const stagedCount = await git.getStagedCount(); + assert.equal(stagedCount, 1); + + // Return back to unstaged state + await git.unstageFile('app.js'); + }); + + it(`stages, commits change to 'app.js' locally and verifies outgoing change`, async function () { + await git.openGitViewlet(); + await app.wait(); + await git.stageFile('app.js'); + await git.focusOnCommitBox(); + await common.type('Test commit'); + await git.pressCommit(); + const changes = await git.getOutgoingChanges(); + assert.equal(changes, ' 0↓ 1↑'); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/integrated-terminal.ts b/test/smoke/src/tests/integrated-terminal.ts new file mode 100644 index 00000000000..95925d03f96 --- /dev/null +++ b/test/smoke/src/tests/integrated-terminal.ts @@ -0,0 +1,41 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { IntegratedTerminal } from "../areas/integrated-terminal"; + +let app: SpectronApplication; +let common: CommonActions; + +export function integratedTerminal() { + context('Integrated Terminal', function () { + let terminal: IntegratedTerminal; + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); + common = new CommonActions(app); + terminal = new IntegratedTerminal(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it(`opens terminal, runs 'echo' and verifies the output`, async function () { + const command = 'echo test'; + await terminal.openTerminal(common); + await app.wait(); + await common.type(command); + await common.enter(); + await app.wait(); + let output = await terminal.getCommandOutput(command); + assert.equal(output, 'test'); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/javascript-debug.ts b/test/smoke/src/tests/javascript-debug.ts new file mode 100644 index 00000000000..7f85ee4f49c --- /dev/null +++ b/test/smoke/src/tests/javascript-debug.ts @@ -0,0 +1,44 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { JavaScriptDebug } from "../areas/javascript-debug"; + +let app: SpectronApplication; +let common: CommonActions; + +export function javascriptDebug() { + context('Debugging JavaScript', function () { + let jsDebug: JavaScriptDebug; + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); + common = new CommonActions(app); + jsDebug = new JavaScriptDebug(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('autodetects program attribute for launch.json', async function () { + await jsDebug.openDebugViewlet(); + await jsDebug.pressConfigureLaunchJson(); + const value = await jsDebug.getProgramConfigValue(); + process.platform === 'win32' ? assert.equal(value, '"${workspaceRoot}\\\\bin\\\\www"') : assert.equal(value, '"${workspaceRoot}/bin/www"'); + }); + + it(`can set a breakpoint and verify if it's set`, async function () { + await common.openFirstMatchFile('index.js'); + await jsDebug.setBreakpointOnLine(6); + const breakpoint = await jsDebug.verifyBreakpointOnLine(6); + assert.ok(breakpoint); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/javascript.ts b/test/smoke/src/tests/javascript.ts new file mode 100644 index 00000000000..2d82fde2d4b --- /dev/null +++ b/test/smoke/src/tests/javascript.ts @@ -0,0 +1,86 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { JavaScript } from "../areas/javascript"; + +let app: SpectronApplication; +let common: CommonActions; + +export function javascript() { + context('JavaScript', function () { + let js: JavaScript; + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); + common = new CommonActions(app); + js = new JavaScript(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('shows correct quick outline', async function () { + await common.openFirstMatchFile('bin/www'); + await js.openQuickOutline(); + await app.wait(); + const symbols = await common.getQuickOpenElements(); + assert.equal(symbols, 12); + }); + + it(`finds 'All References' to 'app'`, async function () { + await common.openFirstMatchFile('bin/www'); + await app.wait(); + await js.findAppReferences(); + const titleCount = await js.getTitleReferencesCount(); + assert.equal(titleCount, 3); + const treeCount = await js.getTreeReferencesCount(); + assert.equal(treeCount, 3); + }); + + it(`renames local 'app' variable`, async function () { + await common.openFirstMatchFile('bin/www'); + + const newVarName = 'newApp'; + await js.renameApp(newVarName); + await common.enter(); + const newName = await js.getNewAppName(); + assert.equal(newName, newVarName); + }); + + it('folds/unfolds the code correctly', async function () { + await common.openFirstMatchFile('bin/www'); + // Fold + await js.toggleFirstCommentFold(); + const foldedIcon = await js.getFirstCommentFoldedIcon(); + assert.ok(foldedIcon); + let nextLineNumber = await js.getNextLineNumberAfterFold(); + assert.equal(nextLineNumber, 7); + // Unfold + await js.toggleFirstCommentFold(); + nextLineNumber = await js.getNextLineNumberAfterFold(); + assert.equal(nextLineNumber, 4); + }); + + it(`verifies that 'Go To Definition' works`, async function () { + await common.openFirstMatchFile('app.js'); + await js.goToExpressDefinition(); + await app.wait(); + assert.ok(await common.getTab('index.d.ts')); + }); + + it(`verifies that 'Peek Definition' works`, async function () { + await common.openFirstMatchFile('app.js'); + await js.peekExpressDefinition(); + const definitionFilename = await js.getPeekExpressResultName(); + assert.equal(definitionFilename, 'index.d.ts'); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/localization.ts b/test/smoke/src/tests/localization.ts new file mode 100644 index 00000000000..35a72186e82 --- /dev/null +++ b/test/smoke/src/tests/localization.ts @@ -0,0 +1,49 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH, USER_DIR } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { Localization, ViewletType } from "../areas/localization"; + +let app: SpectronApplication; +let common: CommonActions; + +export function localization() { + context('Localization', function () { + afterEach(async function () { + return await app.stop(); + }); + + it(`starts with 'DE' locale and verifies title and viewlets text is in German`, async function () { + app = new SpectronApplication(LATEST_PATH, this.test.fullTitle(), this.test.currentRetry(), [WORKSPACE_PATH, '--locale=DE'], [`--user-data-dir=${USER_DIR}`]); + common = new CommonActions(app); + const locale = new Localization(app); + common.removeDirectory(USER_DIR); + + await app.start(); + + let text = await locale.getOpenEditorsText(); + assert.equal(text.toLowerCase(), 'geöffnete editoren'); + + await locale.openViewlet(ViewletType.SEARCH); + text = await locale.getOpenedViewletTitle(); + assert.equal(text.toLowerCase(), 'suchen'); + + await locale.openViewlet(ViewletType.SCM); + text = await locale.getOpenedViewletTitle(); + assert.equal(text.toLowerCase(), 'quellcodeverwaltung: git'); + + await locale.openViewlet(ViewletType.DEBUG); + text = await locale.getOpenedViewletTitle(); + assert.equal(text.toLowerCase(), 'debuggen'); + + await locale.openViewlet(ViewletType.EXTENSIONS); + text = await locale.getExtensionsSearchPlaceholder(); + assert.equal(text.toLowerCase(), 'nach erweiterungen im marketplace suchen'); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/search.ts b/test/smoke/src/tests/search.ts new file mode 100644 index 00000000000..8ab012c9b08 --- /dev/null +++ b/test/smoke/src/tests/search.ts @@ -0,0 +1,73 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { Search } from "../areas/search"; + +let app: SpectronApplication; +let common: CommonActions; + +export function search() { + context('Search', function () { + let search: Search; + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); + common = new CommonActions(app); + search = new Search(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('searches for body & checks for correct result number', async function () { + const s = search; + await s.openSearchViewlet(); + await s.searchFor('body'); + const result = await s.getResultText(); + assert.equal(result, '7 results in 4 files'); + }); + + it('searches only for *.js files & checks for correct result number', async function () { + const s = search; + await s.openSearchViewlet(); + await s.searchFor('body'); + await s.toggleSearchDetails(); + await s.searchFor('*.js'); + const results = await s.getResultText(); + assert.equal(results, '4 results in 1 file'); + }); + + it('dismisses result & checks for correct result number', async function () { + const s = search; + await s.openSearchViewlet(); + await s.searchFor('body'); + await s.hoverOverResultCount(); + await s.dismissResult(); + await app.wait(); + const result = await s.getResultText(); + assert.equal(result, '3 results in 3 files'); + }); + + it('replaces first search result with a replace term', async function () { + const s = search; + await s.openSearchViewlet(); + await s.searchFor('body'); + await s.toggleReplace(); + await s.setReplaceText('ydob'); + await s.hoverOverResultCount(); + await s.replaceFirstMatch(); + await app.wait(); + await common.saveOpenedFile(); + const result = await s.getResultText(); + assert.equal(result, '3 results in 3 files'); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/statusbar.ts b/test/smoke/src/tests/statusbar.ts new file mode 100644 index 00000000000..6fbcf6472c4 --- /dev/null +++ b/test/smoke/src/tests/statusbar.ts @@ -0,0 +1,94 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { CommonActions } from '../areas/common'; +import { StatusBarElement, StatusBar } from "../areas/statusBar"; + +let app: SpectronApplication; +let common: CommonActions; + +export function statusBar() { + context('Status Bar', function () { + let statusBar: StatusBar; + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); + common = new CommonActions(app); + statusBar = new StatusBar(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('verifies presence of all default status bar elements', async function () { + await app.wait(); + assert.ok(await statusBar.isVisible(StatusBarElement.BRANCH_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.FEEDBACK_ICON)); + assert.ok(await statusBar.isVisible(StatusBarElement.SYNC_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.PROBLEMS_STATUS)); + + await common.openFirstMatchFile('app.js'); + assert.ok(await statusBar.isVisible(StatusBarElement.ENCODING_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.EOL_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.INDENTATION_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.LANGUAGE_STATUS)); + assert.ok(await statusBar.isVisible(StatusBarElement.SELECTION_STATUS)); + }); + + it(`verifies that 'quick open' opens when clicking on 'Branch', 'Indentation Status, 'Encoding', 'EOL' and 'Language' status elements`, async function () { + await app.wait(); + await statusBar.clickOn(StatusBarElement.BRANCH_STATUS); + assert.ok(await statusBar.isQuickOpenWidgetVisible()); + await common.closeQuickOpen(); + + await common.openFirstMatchFile('app.js'); + await statusBar.clickOn(StatusBarElement.INDENTATION_STATUS); + assert.ok(await statusBar.isQuickOpenWidgetVisible()); + await common.closeQuickOpen(); + await statusBar.clickOn(StatusBarElement.ENCODING_STATUS); + assert.ok(await statusBar.isQuickOpenWidgetVisible()); + await common.closeQuickOpen(); + await statusBar.clickOn(StatusBarElement.EOL_STATUS); + assert.ok(await statusBar.isQuickOpenWidgetVisible()); + await common.closeQuickOpen(); + await statusBar.clickOn(StatusBarElement.LANGUAGE_STATUS); + assert.ok(await statusBar.isQuickOpenWidgetVisible()); + await common.closeQuickOpen(); + }); + + it(`verifies that 'Problems View' appears when clicking on 'Problems' status element`, async function () { + await statusBar.clickOn(StatusBarElement.PROBLEMS_STATUS); + assert.ok(await statusBar.getProblemsView()); + }); + + it(`verifies that 'Tweet us feedback' pop-up appears when clicking on 'Feedback' icon`, async function () { + await statusBar.clickOn(StatusBarElement.FEEDBACK_ICON); + assert.ok(await statusBar.getFeedbackView()); + }); + + it(`checks if 'Go to Line' works if called from the status bar`, async function () { + await common.openFirstMatchFile('app.js'); + await statusBar.clickOn(StatusBarElement.SELECTION_STATUS); + const lineNumber = 15; + await common.type(lineNumber.toString()); + await common.enter(); + assert.ok(await statusBar.getEditorHighlightedLine(lineNumber)); + }); + + it(`verifies if changing EOL is reflected in the status bar`, async function () { + await common.openFirstMatchFile('app.js'); + await statusBar.clickOn(StatusBarElement.EOL_STATUS); + await common.selectNextQuickOpenElement(); + await common.enter(); + const currentEOL = await statusBar.getEOLMode(); + assert.equal(currentEOL, 'CRLF'); + }); + }); +} \ No newline at end of file diff --git a/test/smoke/src/tests/tasks.ts b/test/smoke/src/tests/tasks.ts new file mode 100644 index 00000000000..c020aceac0c --- /dev/null +++ b/test/smoke/src/tests/tasks.ts @@ -0,0 +1,56 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as assert from 'assert'; + +import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { Tasks } from "../areas/tasks"; + +let app: SpectronApplication; + +export function tasks() { + context('Tasks', function () { + let tasks: Tasks; + + beforeEach(async function () { + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); + tasks = new Tasks(app); + + return await app.start(); + }); + afterEach(async function () { + return await app.stop(); + }); + + it('verifies that build task produces 6 errors', async function () { + await tasks.build(); + const res = await tasks.getOutputResult(); + assert.equal(res, '✖ 6 problems (6 errors, 0 warnings)'); + }); + + it(`is able to select 'Git' output`, async function () { + await tasks.build(); + await app.wait(); + await tasks.selectOutputViewType('Git'); + const viewType = await tasks.getOutputViewType(); + assert.equal(viewType, 'Git'); + }); + + it('ensures that build task produces errors in index.js', async function () { + await tasks.build(); + assert.ok(await tasks.firstOutputLineEndsWith('index.js')); + }); + + it(`verifies build errors are reflected in 'Problems View'`, async function () { + await tasks.build(); + await app.wait(); + await tasks.openProblemsView(); + const problemName = await tasks.getProblemsViewFirstElementName(); + assert.equal(problemName, 'index.js'); + const problemsCount = await tasks.getProblemsViewFirstElementCount(); + assert.equal(problemsCount, '6'); + }); + }); +} \ No newline at end of file -- GitLab From 0335ea84d637f9ef5657a6f3051c5e9be823b08d Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Fri, 26 May 2017 10:36:52 +0200 Subject: [PATCH 0205/1347] Updated tasks tests with respect to new Express eslint config. Code cleanup. --- test/smoke/.vscode/launch.json | 26 --------------- test/smoke/.vscode/tasks.json | 10 ------ test/smoke/src/areas/tasks.ts | 11 ++++--- test/smoke/src/main.js | 1 - test/smoke/src/mocha-runner.js | 2 +- test/smoke/src/test.ts | 36 +++++++++++++++++++++ test/smoke/src/tests.ts | 36 --------------------- test/smoke/src/tests/configuration-views.ts | 4 +-- test/smoke/src/tests/css.ts | 4 +-- test/smoke/src/tests/data-loss.ts | 4 +-- test/smoke/src/tests/data-migration.ts | 5 +-- test/smoke/src/tests/explorer.ts | 5 +-- test/smoke/src/tests/extensions.ts | 19 +++++++++-- test/smoke/src/tests/git.ts | 4 +-- test/smoke/src/tests/integrated-terminal.ts | 4 +-- test/smoke/src/tests/javascript-debug.ts | 4 +-- test/smoke/src/tests/javascript.ts | 4 +-- test/smoke/src/tests/localization.ts | 4 +-- test/smoke/src/tests/search.ts | 4 +-- test/smoke/src/tests/statusbar.ts | 4 +-- test/smoke/src/tests/tasks.ts | 12 +++---- 21 files changed, 91 insertions(+), 112 deletions(-) delete mode 100644 test/smoke/.vscode/launch.json delete mode 100644 test/smoke/.vscode/tasks.json create mode 100644 test/smoke/src/test.ts delete mode 100644 test/smoke/src/tests.ts diff --git a/test/smoke/.vscode/launch.json b/test/smoke/.vscode/launch.json deleted file mode 100644 index 25b4e7e4c0e..00000000000 --- a/test/smoke/.vscode/launch.json +++ /dev/null @@ -1,26 +0,0 @@ -{ - // Use IntelliSense to learn about possible Node.js debug attributes. - // Hover to view descriptions of existing attributes. - // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 - "version": "0.2.0", - "configurations": [ - { - "type": "node", - "request": "launch", - "name": "Mocha Tests", - "program": "${workspaceRoot}/node_modules/mocha/bin/_mocha", - "args": [ - "-u", - "tdd", - "--timeout", - "999999", - "--colors", - "${workspaceRoot}/out/tests.js" - ], - "outFiles": [ "${workspaceRoot}/out/**/*.js" ], - "internalConsoleOptions": "openOnSessionStart", - "sourceMaps": true, - "cwd": "${workspaceRoot}" - } - ] -} \ No newline at end of file diff --git a/test/smoke/.vscode/tasks.json b/test/smoke/.vscode/tasks.json deleted file mode 100644 index 926b1ddcd18..00000000000 --- a/test/smoke/.vscode/tasks.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - // See https://go.microsoft.com/fwlink/?LinkId=733558 - // for the documentation about the tasks.json format - "version": "0.1.0", - "command": "tsc", - "isShellCommand": true, - "args": ["-p", "."], - "showOutput": "silent", - "problemMatcher": "$tsc" -} \ No newline at end of file diff --git a/test/smoke/src/areas/tasks.ts b/test/smoke/src/areas/tasks.ts index d83cc173efa..e0774854f3a 100644 --- a/test/smoke/src/areas/tasks.ts +++ b/test/smoke/src/areas/tasks.ts @@ -15,8 +15,9 @@ export class Tasks { // noop } - public build(): Promise { - return this.spectron.command('workbench.action.tasks.build'); + public async build(): Promise { + await this.spectron.command('workbench.action.tasks.build'); + return this.spectron.wait(); // wait for build to finish } public openProblemsView(): Promise { @@ -25,12 +26,12 @@ export class Tasks { public async firstOutputLineEndsWith(fileName: string): Promise { const firstLine = await this.spectron.waitFor(this.spectron.client.getText, `${this.outputViewSelector}>:nth-child(2)`); - + return firstLine.endsWith(fileName); } public getOutputResult(): Promise { - return this.spectron.waitFor(this.spectron.client.getText, `${this.outputViewSelector}>:nth-child(10) span.mtk1`); + return this.spectron.waitFor(this.spectron.client.getText, `${this.outputViewSelector}>:nth-child(5) span.mtk1`); } public selectOutputViewType(type: string): Promise { @@ -41,7 +42,7 @@ export class Tasks { return this.spectron.client.getValue(`${this.workbenchPanelSelector} .select-box`); } - public getProblemsViewFirstElementName(): Promise { + public getProblemsViewFirstElementName(): Promise { return this.spectron.waitFor(this.spectron.client.getText, `${this.problemsViewSelector} .label-name`); } diff --git a/test/smoke/src/main.js b/test/smoke/src/main.js index 8df41b5c73c..a6acc9a7d89 100644 --- a/test/smoke/src/main.js +++ b/test/smoke/src/main.js @@ -53,7 +53,6 @@ else if (os === 'win32') os = 'win'; var promises = []; try { - // promises.push(execute('npm install'), process.cwd()); promises.push(getKeybindings(`${keybindingsUrl}/doc.keybindings.${os}.json`, `${tempFolder}/keybindings.json`)); promises.push(cleanOrClone(testRepoUrl, testRepoLocalDir)); diff --git a/test/smoke/src/mocha-runner.js b/test/smoke/src/mocha-runner.js index 8ea1dd905aa..39a91bcdbab 100644 --- a/test/smoke/src/mocha-runner.js +++ b/test/smoke/src/mocha-runner.js @@ -14,7 +14,7 @@ var mocha = new Mocha({ useColors: true }); -mocha.addFile(path.join(process.cwd(), 'out/tests.js')); +mocha.addFile(path.join(process.cwd(), 'out/test.js')); mocha.run((failures) => { process.on('exit', () => { process.exit(failures); diff --git a/test/smoke/src/test.ts b/test/smoke/src/test.ts new file mode 100644 index 00000000000..70cc2f5d322 --- /dev/null +++ b/test/smoke/src/test.ts @@ -0,0 +1,36 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { testDataLoss } from "./tests/data-loss"; +import { testDataMigration } from "./tests/data-migration"; +import { testExplorer } from "./tests/explorer"; +import { testConfigViews } from "./tests/configuration-views"; +import { testSearch } from "./tests/search"; +import { testCSS } from "./tests/css"; +import { testJavaScript } from "./tests/javascript"; +import { testJavaScriptDebug } from "./tests/javascript-debug"; +import { testGit } from "./tests/git"; +import { testIntegratedTerminal } from "./tests/integrated-terminal"; +import { testStatusbar } from "./tests/statusbar"; +import { testTasks } from "./tests/tasks"; +import { testExtensions } from "./tests/extensions"; +import { testLocalization } from "./tests/localization"; + +describe('Smoke Test Suite', async () => { + testDataMigration(); + testDataLoss(); + testExplorer(); + testConfigViews(); + testSearch(); + testCSS(); + testJavaScript(); + testJavaScriptDebug(); + testGit(); + testIntegratedTerminal(); + testStatusbar(); + testTasks(); + testExtensions(); + testLocalization(); +}); \ No newline at end of file diff --git a/test/smoke/src/tests.ts b/test/smoke/src/tests.ts deleted file mode 100644 index 17ca694e209..00000000000 --- a/test/smoke/src/tests.ts +++ /dev/null @@ -1,36 +0,0 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ - -import { dataLoss } from "./tests/data-loss"; -import { dataMigration } from "./tests/data-migration"; -import { explorer } from "./tests/explorer"; -import { configurationViews } from "./tests/configuration-views"; -import { search } from "./tests/search"; -import { css } from "./tests/css"; -import { javascript } from "./tests/javascript"; -import { javascriptDebug } from "./tests/javascript-debug"; -import { test_git } from "./tests/git"; -import { integratedTerminal } from "./tests/integrated-terminal"; -import { statusBar } from "./tests/statusbar"; -import { tasks } from "./tests/tasks"; -import { extensions } from "./tests/extensions"; -import { localization } from "./tests/localization"; - -describe('Smoke Test Suite', function () { - dataMigration(); - dataLoss(); - explorer(); - configurationViews(); - search(); - css(); - javascript(); - javascriptDebug(); - test_git(); - integratedTerminal(); - statusBar(); - tasks(); - extensions(); - localization(); -}); \ No newline at end of file diff --git a/test/smoke/src/tests/configuration-views.ts b/test/smoke/src/tests/configuration-views.ts index 2f61f3337fb..e1241b6bfb5 100644 --- a/test/smoke/src/tests/configuration-views.ts +++ b/test/smoke/src/tests/configuration-views.ts @@ -12,8 +12,8 @@ import { ConfigurationView, ActivityBarPosition } from "../areas/configuration-v let app: SpectronApplication; let common: CommonActions; -export function configurationViews() { - context('Configuration and views', function () { +export function testConfigViews() { + context('Configuration and views', () => { let configView: ConfigurationView; beforeEach(async function () { diff --git a/test/smoke/src/tests/css.ts b/test/smoke/src/tests/css.ts index 01a0bddbe25..d91513f5431 100644 --- a/test/smoke/src/tests/css.ts +++ b/test/smoke/src/tests/css.ts @@ -12,8 +12,8 @@ import { CSS, CSSProblem } from '../areas/css'; let app: SpectronApplication; let common: CommonActions; -export function css() { - context('CSS', function () { +export function testCSS() { + context('CSS', () => { let css: CSS; beforeEach(async function () { diff --git a/test/smoke/src/tests/data-loss.ts b/test/smoke/src/tests/data-loss.ts index 4be1635cfce..e1498299e8e 100644 --- a/test/smoke/src/tests/data-loss.ts +++ b/test/smoke/src/tests/data-loss.ts @@ -13,8 +13,8 @@ let app: SpectronApplication; let common: CommonActions; let dl: DataLoss; -export function dataLoss() { - context('Data Loss', function () { +export function testDataLoss() { + context('Data Loss', () => { beforeEach(async function () { app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH], [`--user-data-dir=${USER_DIR}`]); diff --git a/test/smoke/src/tests/data-migration.ts b/test/smoke/src/tests/data-migration.ts index 0dba58deccb..4b8e627bcfe 100644 --- a/test/smoke/src/tests/data-migration.ts +++ b/test/smoke/src/tests/data-migration.ts @@ -11,11 +11,12 @@ import { CommonActions } from '../areas/common'; let app: SpectronApplication; let common: CommonActions; -export function dataMigration() { +export function testDataMigration() { if (!STABLE_PATH) { return; } - context('Data Migration', function () { + + context('Data Migration', () => { afterEach(async function () { await app.stop(); diff --git a/test/smoke/src/tests/explorer.ts b/test/smoke/src/tests/explorer.ts index 83c2d114196..d1a4570f003 100644 --- a/test/smoke/src/tests/explorer.ts +++ b/test/smoke/src/tests/explorer.ts @@ -11,8 +11,9 @@ import { CommonActions } from '../areas/common'; let app: SpectronApplication; let common: CommonActions; -export function explorer() { - context('Explorer', function () { +export function testExplorer() { + context('Explorer', () => { + beforeEach(async function () { app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH]); common = new CommonActions(app); diff --git a/test/smoke/src/tests/extensions.ts b/test/smoke/src/tests/extensions.ts index a545dd7c674..9e563f2f3c1 100644 --- a/test/smoke/src/tests/extensions.ts +++ b/test/smoke/src/tests/extensions.ts @@ -9,11 +9,18 @@ import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH, EXTENSIONS_DIR } from import { CommonActions } from '../areas/common'; import { Extensions } from "../areas/extensions"; +var dns = require('dns'); + let app: SpectronApplication; let common: CommonActions; -export function extensions() { - context('Extensions', function () { +export async function testExtensions() { + const network = await networkAttached(); + if (!network) { + return; + } + + context('Extensions', () => { let extensions: Extensions; beforeEach(async function () { @@ -54,4 +61,12 @@ export function extensions() { assert.ok(x); }); }); +} + +function networkAttached(): Promise { + return new Promise((res, rej) => { + dns.resolve('marketplace.visualstudio.com', (err) => { + err ? res(false) : res(true); + }); + }); } \ No newline at end of file diff --git a/test/smoke/src/tests/git.ts b/test/smoke/src/tests/git.ts index 11d568c7f8b..cb5e71e7fa3 100644 --- a/test/smoke/src/tests/git.ts +++ b/test/smoke/src/tests/git.ts @@ -12,8 +12,8 @@ import { Git } from "../areas/git"; let app: SpectronApplication; let common: CommonActions; -export function test_git() { - context('Git', function () { +export function testGit() { + context('Git', () => { let git: Git; beforeEach(async function () { diff --git a/test/smoke/src/tests/integrated-terminal.ts b/test/smoke/src/tests/integrated-terminal.ts index 95925d03f96..c05a84e0b2a 100644 --- a/test/smoke/src/tests/integrated-terminal.ts +++ b/test/smoke/src/tests/integrated-terminal.ts @@ -12,8 +12,8 @@ import { IntegratedTerminal } from "../areas/integrated-terminal"; let app: SpectronApplication; let common: CommonActions; -export function integratedTerminal() { - context('Integrated Terminal', function () { +export function testIntegratedTerminal() { + context('Integrated Terminal', () => { let terminal: IntegratedTerminal; beforeEach(async function () { diff --git a/test/smoke/src/tests/javascript-debug.ts b/test/smoke/src/tests/javascript-debug.ts index 7f85ee4f49c..801543f539a 100644 --- a/test/smoke/src/tests/javascript-debug.ts +++ b/test/smoke/src/tests/javascript-debug.ts @@ -12,8 +12,8 @@ import { JavaScriptDebug } from "../areas/javascript-debug"; let app: SpectronApplication; let common: CommonActions; -export function javascriptDebug() { - context('Debugging JavaScript', function () { +export function testJavaScriptDebug() { + context('Debugging JavaScript', () => { let jsDebug: JavaScriptDebug; beforeEach(async function () { diff --git a/test/smoke/src/tests/javascript.ts b/test/smoke/src/tests/javascript.ts index 2d82fde2d4b..490677f1f29 100644 --- a/test/smoke/src/tests/javascript.ts +++ b/test/smoke/src/tests/javascript.ts @@ -12,8 +12,8 @@ import { JavaScript } from "../areas/javascript"; let app: SpectronApplication; let common: CommonActions; -export function javascript() { - context('JavaScript', function () { +export function testJavaScript() { + context('JavaScript', () => { let js: JavaScript; beforeEach(async function () { diff --git a/test/smoke/src/tests/localization.ts b/test/smoke/src/tests/localization.ts index 35a72186e82..3ac81ae2f75 100644 --- a/test/smoke/src/tests/localization.ts +++ b/test/smoke/src/tests/localization.ts @@ -12,8 +12,8 @@ import { Localization, ViewletType } from "../areas/localization"; let app: SpectronApplication; let common: CommonActions; -export function localization() { - context('Localization', function () { +export function testLocalization() { + context('Localization', () => { afterEach(async function () { return await app.stop(); }); diff --git a/test/smoke/src/tests/search.ts b/test/smoke/src/tests/search.ts index 8ab012c9b08..ea2041d3af0 100644 --- a/test/smoke/src/tests/search.ts +++ b/test/smoke/src/tests/search.ts @@ -12,8 +12,8 @@ import { Search } from "../areas/search"; let app: SpectronApplication; let common: CommonActions; -export function search() { - context('Search', function () { +export function testSearch() { + context('Search', () => { let search: Search; beforeEach(async function () { diff --git a/test/smoke/src/tests/statusbar.ts b/test/smoke/src/tests/statusbar.ts index 6fbcf6472c4..86a315daebc 100644 --- a/test/smoke/src/tests/statusbar.ts +++ b/test/smoke/src/tests/statusbar.ts @@ -12,8 +12,8 @@ import { StatusBarElement, StatusBar } from "../areas/statusBar"; let app: SpectronApplication; let common: CommonActions; -export function statusBar() { - context('Status Bar', function () { +export function testStatusbar() { + context('Status Bar', () => { let statusBar: StatusBar; beforeEach(async function () { diff --git a/test/smoke/src/tests/tasks.ts b/test/smoke/src/tests/tasks.ts index c020aceac0c..bbe36ef3968 100644 --- a/test/smoke/src/tests/tasks.ts +++ b/test/smoke/src/tests/tasks.ts @@ -10,8 +10,8 @@ import { Tasks } from "../areas/tasks"; let app: SpectronApplication; -export function tasks() { - context('Tasks', function () { +export function testTasks() { + context('Tasks', () => { let tasks: Tasks; beforeEach(async function () { @@ -24,15 +24,14 @@ export function tasks() { return await app.stop(); }); - it('verifies that build task produces 6 errors', async function () { + it('verifies that eslint task results in 1 problem', async function () { await tasks.build(); const res = await tasks.getOutputResult(); - assert.equal(res, '✖ 6 problems (6 errors, 0 warnings)'); + assert.equal(res, '✖ 1 problem (0 errors, 1 warning)'); }); it(`is able to select 'Git' output`, async function () { await tasks.build(); - await app.wait(); await tasks.selectOutputViewType('Git'); const viewType = await tasks.getOutputViewType(); assert.equal(viewType, 'Git'); @@ -45,12 +44,11 @@ export function tasks() { it(`verifies build errors are reflected in 'Problems View'`, async function () { await tasks.build(); - await app.wait(); await tasks.openProblemsView(); const problemName = await tasks.getProblemsViewFirstElementName(); assert.equal(problemName, 'index.js'); const problemsCount = await tasks.getProblemsViewFirstElementCount(); - assert.equal(problemsCount, '6'); + assert.equal(problemsCount, '1'); }); }); } \ No newline at end of file -- GitLab From bc4688051382b91880f653099a64846f19d39f8c Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Fri, 26 May 2017 11:18:40 +0200 Subject: [PATCH 0206/1347] Code sanity. --- test/smoke/src/main.js | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/test/smoke/src/main.js b/test/smoke/src/main.js index a6acc9a7d89..85e3778d1a7 100644 --- a/test/smoke/src/main.js +++ b/test/smoke/src/main.js @@ -10,7 +10,7 @@ var git = require('simple-git')(); var child_process = require('child_process'); var path = require('path'); -var tempFolder = `test_data`; +var tempFolder = 'test_data'; var testRepoUrl = 'https://github.com/Microsoft/vscode-smoketest-express'; var testRepoLocalDir = path.join(process.cwd(), `${tempFolder}/vscode-smoketest-express`); var keybindingsUrl = 'https://raw.githubusercontent.com/Microsoft/vscode-docs/master/scripts/keybindings'; @@ -41,10 +41,10 @@ if (!binaryExists(program.latest) || (program.stable && !binaryExists(program.st } // Setting up environment variables -process.env['VSCODE_LATEST_PATH'] = program.latest; -if (program.stable) process.env['VSCODE_STABLE_PATH'] = program.stable; -process.env['SMOKETEST_REPO'] = testRepoLocalDir; -if (program.stable && program.stable.toLowerCase().startsWith('insiders')) process.env['VSCODE_EDITION'] = 'insiders'; +process.env.VSCODE_LATEST_PATH = program.latest; +if (program.stable) process.env.VSCODE_STABLE_PATH = program.stable; +process.env.SMOKETEST_REPO = testRepoLocalDir; +if (program.stable && program.stable.toLowerCase().startsWith('insiders')) process.env.VSCODE_EDITION = 'insiders'; // Setting up 'vscode-smoketest-express' project var os = process.platform; @@ -112,7 +112,7 @@ function cleanOrClone(repo, dir) { function execute(cmd, dir) { return new Promise((res, rej) => { console.log(`Running ${cmd}...`); - var output = child_process.exec(cmd, { cwd: dir, stdio: [0, 1, 2] }, (error, stdout, stderr) => { + child_process.exec(cmd, { cwd: dir, stdio: [0, 1, 2] }, (error, stdout, stderr) => { if (error) rej(error); if (stderr) console.error(stderr); console.log(stdout); -- GitLab From e030a071355c05735d3ab248bb3f795219ec4e40 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Fri, 26 May 2017 14:52:06 +0200 Subject: [PATCH 0207/1347] Support customiying tasks --- src/vs/workbench/api/node/extHostTask.ts | 18 ++- .../parts/tasks/browser/quickOpen.ts | 14 +- .../parts/tasks/common/taskConfiguration.ts | 105 ++++++++----- .../parts/tasks/common/taskService.ts | 2 + .../parts/tasks/common/taskTemplates.ts | 139 +++--------------- src/vs/workbench/parts/tasks/common/tasks.ts | 61 +++++--- .../tasks/electron-browser/jsonSchema_v2.ts | 9 ++ .../electron-browser/task.contribution.ts | 83 ++++++----- .../electron-browser/terminalTaskSystem.ts | 16 +- .../parts/tasks/node/processTaskSystem.ts | 4 +- .../tasks/test/node/configuration.test.ts | 16 +- 11 files changed, 228 insertions(+), 239 deletions(-) diff --git a/src/vs/workbench/api/node/extHostTask.ts b/src/vs/workbench/api/node/extHostTask.ts index aa6497bc410..656f57739d7 100644 --- a/src/vs/workbench/api/node/extHostTask.ts +++ b/src/vs/workbench/api/node/extHostTask.ts @@ -230,7 +230,10 @@ namespace Strings { } namespace CommandOptions { - export function from(value: { cwd?: string; env?: { [key: string]: string; } }): TaskSystem.CommandOptions { + function isShellOptions(value: any): value is vscode.ShellOptions { + return value && typeof value.executable === 'string'; + } + export function from(value: vscode.ShellOptions | vscode.ProcessOptions): TaskSystem.CommandOptions { if (value === void 0 || value === null) { return undefined; } @@ -248,14 +251,17 @@ namespace CommandOptions { } }); } + if (isShellOptions(value)) { + result.shell = ShellConfiguration.from(value); + } return result; } } namespace ShellConfiguration { - export function from(value: { executable?: string, args?: string[] }): boolean | TaskSystem.ShellConfiguration { - if (value === void 0 || value === null || typeof value.executable !== 'string') { - return true; + export function from(value: { executable?: string, args?: string[] }): TaskSystem.ShellConfiguration { + if (value === void 0 || value === null || !value.executable) { + return undefined; } let result: TaskSystem.ShellConfiguration = { @@ -323,7 +329,7 @@ namespace Tasks { let result: TaskSystem.CommandConfiguration = { name: value.process, args: Strings.from(value.args), - isShellCommand: false, + type: TaskSystem.CommandType.Process, terminal: TerminalBehaviour.from(value.terminal) }; if (value.options) { @@ -338,7 +344,7 @@ namespace Tasks { } let result: TaskSystem.CommandConfiguration = { name: value.commandLine, - isShellCommand: ShellConfiguration.from(value.options), + type: TaskSystem.CommandType.Shell, terminal: TerminalBehaviour.from(value.terminal) }; if (value.options) { diff --git a/src/vs/workbench/parts/tasks/browser/quickOpen.ts b/src/vs/workbench/parts/tasks/browser/quickOpen.ts index 6c9afcd0b74..e282ee68321 100644 --- a/src/vs/workbench/parts/tasks/browser/quickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/quickOpen.ts @@ -97,10 +97,10 @@ export abstract class QuickOpenHandler extends Quickopen.QuickOpenHandler { if (task._source.kind === TaskSourceKind.Workspace && groupWorkspace) { groupWorkspace = false; hadWorkspace = true; - entries.push(new TaskGroupEntry(this.createEntry(this.taskService, task, highlights), nls.localize('workspace', 'From Workspace'), false)); + entries.push(new TaskGroupEntry(this.createEntry(this.taskService, task, highlights), nls.localize('configured', 'Configured Tasks'), false)); } else if (task._source.kind === TaskSourceKind.Extension && groupExtension) { groupExtension = false; - entries.push(new TaskGroupEntry(this.createEntry(this.taskService, task, highlights), nls.localize('extension', 'From Extensions'), hadWorkspace)); + entries.push(new TaskGroupEntry(this.createEntry(this.taskService, task, highlights), nls.localize('detected', 'Detected Tasks'), hadWorkspace)); } else { entries.push(this.createEntry(this.taskService, task, highlights)); } @@ -125,7 +125,7 @@ class CustomizeTaskAction extends Action { private static ID = 'workbench.action.tasks.customizeTask'; private static LABEL = nls.localize('customizeTask', "Customize Task"); - constructor() { + constructor(private taskService: ITaskService, private task: Task) { super(CustomizeTaskAction.ID, CustomizeTaskAction.LABEL); this.updateClass(); } @@ -134,14 +134,14 @@ class CustomizeTaskAction extends Action { this.class = 'quick-open-task-configure'; } - public run(context: any): TPromise { - return TPromise.as(false); + public run(context: any): TPromise { + return this.taskService.customize(this.task, true).then(_ => false, _ => false); } } export class QuickOpenActionContributor extends ActionBarContributor { - constructor() { + constructor( @ITaskService private taskService: ITaskService) { super(); } @@ -156,7 +156,7 @@ export class QuickOpenActionContributor extends ActionBarContributor { const entry = this.getEntry(context); if (entry && entry.task._source.kind === TaskSourceKind.Extension) { - actions.push(new CustomizeTaskAction()); + actions.push(new CustomizeTaskAction(this.taskService, entry.task)); } return actions; } diff --git a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts index b06f6c15bf3..9af9833e240 100644 --- a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts +++ b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts @@ -11,7 +11,6 @@ import { IStringDictionary } from 'vs/base/common/collections'; import * as Platform from 'vs/base/common/platform'; import * as Types from 'vs/base/common/types'; import * as UUID from 'vs/base/common/uuid'; -import { Config as ProcessConfig } from 'vs/base/common/processes'; import { ValidationStatus, IProblemReporter as IProblemReporterBase } from 'vs/base/common/parsers'; import { @@ -32,7 +31,37 @@ export class ProblemHandling { public static clean: string = 'cleanMatcherMatchers'; } +export interface ShellConfiguration { + executable: string; + args?: string[]; +} + +export interface CommandOptions { + /** + * The current working directory of the executed program or shell. + * If omitted VSCode's current workspace root is used. + */ + cwd?: string; + + /** + * The additional environment of the executed program or shell. If omitted + * the parent process' environment is used. + */ + env?: IStringDictionary; + + /** + * The shell configuration; + */ + shell?: ShellConfiguration; +} + export interface PlatformTaskDescription { + + /** + * Whether the task is a shell task or a process task. + */ + type?: string; + /** * The command to be executed. Can be an external program or a shell * command. @@ -40,17 +69,18 @@ export interface PlatformTaskDescription { command?: string; /** + * @deprecated use the task type instead. * Specifies whether the command is a shell command and therefore must * be executed in a shell interpreter (e.g. cmd.exe, bash, ...). * * Defaults to false if omitted. */ - isShellCommand?: boolean; + isShellCommand?: boolean | ShellConfiguration; /** * The command options used when the command is executed. Can be omitted. */ - options?: ProcessConfig.CommandOptions; + options?: CommandOptions; /** * The arguments passed to the command or additional arguments passed to the @@ -166,7 +196,7 @@ export interface BaseTaskRunnerConfiguration { /** * The command options used when the command is executed. Can be omitted. */ - options?: ProcessConfig.CommandOptions; + options?: CommandOptions; /** * The arguments passed to the command. Can be omitted. @@ -308,7 +338,7 @@ interface ParseContext { } namespace CommandOptions { - export function from(this: void, options: ProcessConfig.CommandOptions, context: ParseContext): Tasks.CommandOptions { + export function from(this: void, options: CommandOptions, context: ParseContext): Tasks.CommandOptions { let result: Tasks.CommandOptions = {}; if (options.cwd !== void 0) { if (Types.isString(options.cwd)) { @@ -320,11 +350,12 @@ namespace CommandOptions { if (options.env !== void 0) { result.env = Objects.clone(options.env); } + result.shell = ShellConfiguration.from(options.shell, context); return isEmpty(result) ? undefined : result; } export function isEmpty(value: Tasks.CommandOptions): boolean { - return !value || value.cwd === void 0 && value.env === void 0; + return !value || value.cwd === void 0 && value.env === void 0 && value.shell === void 0; } export function merge(target: Tasks.CommandOptions, source: Tasks.CommandOptions): Tasks.CommandOptions { @@ -343,6 +374,7 @@ namespace CommandOptions { Object.keys(source.env).forEach(key => env[key = source.env[key]]); target.env = env; } + target.shell = ShellConfiguration.merge(target.shell, source.shell); return target; } @@ -356,6 +388,7 @@ namespace CommandOptions { if (value.cwd === void 0) { value.cwd = '${workspaceRoot}'; } + ShellConfiguration.fillDefaults(value.shell); return value; } @@ -364,14 +397,10 @@ namespace CommandOptions { if (value.env) { Object.freeze(value.env); } + ShellConfiguration.freeze(value.shell); } } -interface ShellConfiguration { - executable: string; - args?: string[]; -} - namespace ShellConfiguration { export function is(value: any): value is ShellConfiguration { let candidate: ShellConfiguration = value; @@ -424,9 +453,10 @@ namespace CommandConfiguration { interface BaseCommandConfiguationShape { command?: string; + type?: string; isShellCommand?: boolean | ShellConfiguration; args?: string[]; - options?: ProcessConfig.CommandOptions; + options?: CommandOptions; echoCommand?: boolean; showOutput?: string; terminal?: TerminalBehavior; @@ -524,21 +554,20 @@ namespace CommandConfiguration { function fromBase(this: void, config: BaseCommandConfiguationShape, context: ParseContext): Tasks.CommandConfiguration { let result: Tasks.CommandConfiguration = { name: undefined, - isShellCommand: undefined, + type: undefined, terminal: undefined }; if (Types.isString(config.command)) { result.name = config.command; } - if (Types.isBoolean(config.isShellCommand)) { - result.isShellCommand = config.isShellCommand; - } else if (ShellConfiguration.is(config.isShellCommand)) { - result.isShellCommand = ShellConfiguration.from(config.isShellCommand, context); - if (!context.isTermnial) { - context.problemReporter.warn(nls.localize('ConfigurationParser.noShell', 'Warning: shell configuration is only supported when executing tasks in the terminal.')); - } + if (Types.isString(config.type)) { + result.type = Tasks.CommandType.fromString(config.type); + } + let isShellConfiguration = ShellConfiguration.is(config.isShellCommand); + if (Types.isBoolean(config.isShellCommand) || isShellConfiguration) { + result.type = Tasks.CommandType.Shell; } else if (config.isShellCommand !== void 0) { - result.isShellCommand = !!config.isShellCommand; + result.type = !!config.isShellCommand ? Tasks.CommandType.Shell : Tasks.CommandType.Process; } if (config.args !== void 0) { if (Types.isStringArray(config.args)) { @@ -549,6 +578,12 @@ namespace CommandConfiguration { } if (config.options !== void 0) { result.options = CommandOptions.from(config.options, context); + if (result.options && result.options.shell === void 0 && isShellConfiguration) { + result.options.shell = ShellConfiguration.from(config.isShellCommand as ShellConfiguration, context); + if (!context.isTermnial) { + context.problemReporter.warn(nls.localize('ConfigurationParser.noShell', 'Warning: shell configuration is only supported when executing tasks in the terminal.')); + } + } } let terminal = TerminalBehavior.from(config, context); if (terminal) { @@ -561,13 +596,13 @@ namespace CommandConfiguration { } export function isEmpty(value: Tasks.CommandConfiguration): boolean { - return !value || value.name === void 0 && value.isShellCommand === void 0 && value.args === void 0 && CommandOptions.isEmpty(value.options) && value.terminal === void 0; + return !value || value.name === void 0 && value.type === void 0 && value.args === void 0 && CommandOptions.isEmpty(value.options) && value.terminal === void 0; } export function onlyTerminalBehaviour(value: Tasks.CommandConfiguration): boolean { return value && - value.terminal && (value.terminal.echo !== void 0 || value.terminal.reveal === void 0) && - value.name === void 0 && value.isShellCommand === void 0 && value.args === void 0 && CommandOptions.isEmpty(value.options); + value.terminal && (value.terminal.echo !== void 0 || value.terminal.reveal !== void 0) && + value.name === void 0 && value.type === void 0 && value.args === void 0 && CommandOptions.isEmpty(value.options); } export function merge(target: Tasks.CommandConfiguration, source: Tasks.CommandConfiguration): Tasks.CommandConfiguration { @@ -578,15 +613,10 @@ namespace CommandConfiguration { return source; } mergeProperty(target, source, 'name'); + mergeProperty(target, source, 'type'); // Merge isShellCommand - if (target.isShellCommand === void 0) { - target.isShellCommand = source.isShellCommand; - } if (Types.isBoolean(target.isShellCommand) && Types.isBoolean(source.isShellCommand)) { - mergeProperty(target, source, 'isShellCommand'); - } else if (ShellConfiguration.is(target.isShellCommand) && ShellConfiguration.is(source.isShellCommand)) { - ShellConfiguration.merge(target.isShellCommand, source.isShellCommand); - } else if (Types.isBoolean(target.isShellCommand) && ShellConfiguration.is(source.isShellCommand)) { - target.isShellCommand = source.isShellCommand; + if (target.type === void 0) { + target.type = source.type; } target.terminal = TerminalBehavior.merge(target.terminal, source.terminal); @@ -606,8 +636,8 @@ namespace CommandConfiguration { if (!value || Object.isFrozen(value)) { return; } - if (value.name !== void 0 && value.isShellCommand === void 0) { - value.isShellCommand = false; + if (value.name !== void 0 && value.type === void 0) { + value.type = Tasks.CommandType.Process; } value.terminal = TerminalBehavior.fillDefault(value.terminal); if (value.args === void 0) { @@ -629,9 +659,6 @@ namespace CommandConfiguration { if (value.terminal) { TerminalBehavior.freeze(value.terminal); } - if (ShellConfiguration.is(value.isShellCommand)) { - ShellConfiguration.freeze(value.isShellCommand); - } } } @@ -751,7 +778,7 @@ namespace TaskDescription { let command: Tasks.CommandConfiguration = externalTask.command !== void 0 ? CommandConfiguration.from(externalTask, context) : externalTask.echoCommand !== void 0 - ? { name: undefined, isShellCommand: undefined, terminal: CommandConfiguration.TerminalBehavior.from(externalTask, context) } + ? { name: undefined, type: undefined, terminal: CommandConfiguration.TerminalBehavior.from(externalTask, context) } : undefined; let identifer = Types.isString(externalTask.identifier) ? externalTask.identifier : taskName; let task: Tasks.Task = { @@ -797,7 +824,7 @@ namespace TaskDescription { } fillDefaults(task); let addTask: boolean = true; - if (context.isTermnial && task.command && task.command.name && task.command.isShellCommand && task.command.args && task.command.args.length > 0) { + if (context.isTermnial && task.command && task.command.name && task.command.type === Tasks.CommandType.Shell && task.command.args && task.command.args.length > 0) { if (hasUnescapedSpaces(task.command.name) || task.command.args.some(hasUnescapedSpaces)) { context.problemReporter.warn(nls.localize('taskConfiguration.shellArgs', 'Warning: the task \'{0}\' is a shell command and either the command name or one of its arguments has unescaped spaces. To ensure correct command line quoting please merge args into the command.', task.name)); } diff --git a/src/vs/workbench/parts/tasks/common/taskService.ts b/src/vs/workbench/parts/tasks/common/taskService.ts index 53f92ee18ee..63b2da04137 100644 --- a/src/vs/workbench/parts/tasks/common/taskService.ts +++ b/src/vs/workbench/parts/tasks/common/taskService.ts @@ -43,6 +43,8 @@ export interface ITaskService extends IEventEmitter { terminateAll(): TPromise; tasks(): TPromise; + customize(task: Task, openConfig?: boolean): TPromise; + registerTaskProvider(handle: number, taskProvider: ITaskProvider): void; unregisterTaskProvider(handle: number): boolean; } \ No newline at end of file diff --git a/src/vs/workbench/parts/tasks/common/taskTemplates.ts b/src/vs/workbench/parts/tasks/common/taskTemplates.ts index 0d7253582b8..ca345475266 100644 --- a/src/vs/workbench/parts/tasks/common/taskTemplates.ts +++ b/src/vs/workbench/parts/tasks/common/taskTemplates.ts @@ -14,104 +14,6 @@ export interface TaskEntry extends IPickOpenEntry { content: string; } -const gulp: TaskEntry = { - id: 'gulp', - label: 'Gulp', - autoDetect: true, - content: [ - '{', - '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', - '\t// for the documentation about the tasks.json format', - '\t"version": "2.0.0",', - '\t"command": "gulp --no-color",', - '\t"isShellCommand": true,', - '}' - ].join('\n') -}; - -const grunt: TaskEntry = { - id: 'grunt', - label: 'Grunt', - autoDetect: true, - content: [ - '{', - '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', - '\t// for the documentation about the tasks.json format', - '\t"version": "2.0.0",', - '\t"command": "grunt --no-color",', - '\t"isShellCommand": true,', - '}' - ].join('\n') -}; - -const npm: TaskEntry = { - id: 'npm', - label: 'npm', - sort: 'NPM', - autoDetect: false, - content: [ - '{', - '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', - '\t// for the documentation about the tasks.json format', - '\t"version": "2.0.0",', - '\t"tasks": [', - '\t\t{', - '\t\t\t"taskName": "install",', - '\t\t\t"command": "npm install",', - '\t\t\t"isShellCommand": true,', - '\t\t},', - '\t\t{', - '\t\t\t"taskName": "update",', - '\t\t\t"command": "npm update",', - '\t\t\t"isShellCommand": true,', - '\t\t},', - '\t\t{', - '\t\t\t"taskName": "test",', - '\t\t\t"command": "npm run test",', - '\t\t\t"isShellCommand": true,', - '\t\t}', - '\t]', - '}' - ].join('\n') -}; - -const tscConfig: TaskEntry = { - id: 'tsc.config', - label: 'TypeScript - tsconfig.json', - autoDetect: false, - description: nls.localize('tsc.config', 'Compiles a TypeScript project'), - content: [ - '{', - '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', - '\t// for the documentation about the tasks.json format', - '\t"version": "2.0.0",', - '\t"command": "tsc -p .",', - '\t"isShellCommand": true,', - '\t"showOutput": "silent",', - '\t"problemMatcher": "$tsc"', - '}' - ].join('\n') -}; - -const tscWatch: TaskEntry = { - id: 'tsc.watch', - label: 'TypeScript - Watch Mode', - autoDetect: false, - description: nls.localize('tsc.watch', 'Compiles a TypeScript project in watch mode'), - content: [ - '{', - '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', - '\t// for the documentation about the tasks.json format', - '\t"version": "2.0.0",', - '\t"command": "tsc -w -p .",', - '\t"isShellCommand": true,', - '\t"showOutput": "silent",', - '\t"isBackground": true,', - '\t"problemMatcher": "$tsc-watch"', - '}' - ].join('\n') -}; - const dotnetBuild: TaskEntry = { id: 'dotnetCore', label: '.NET Core', @@ -122,16 +24,16 @@ const dotnetBuild: TaskEntry = { '{', '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', '\t// for the documentation about the tasks.json format', - '\t"version": "0.1.0",', - '\t"command": "dotnet",', - '\t"isShellCommand": true,', - '\t"args": [],', + '\t"version": "2.0.0",', '\t"tasks": [', '\t\t{', '\t\t\t"taskName": "build",', - '\t\t\t"args": [ ],', - '\t\t\t"isBuildCommand": true,', - '\t\t\t"showOutput": "silent",', + '\t\t\t"command": "dotnet",', + '\t\t\t"isShellCommand": true,', + '\t\t\t"group": "build",', + '\t\t\t"terminal": {', + '\t\t\t\t"reveal": "silent"', + '\t\t\t},', '\t\t\t"problemMatcher": "$msCompile"', '\t\t}', '\t]', @@ -149,18 +51,20 @@ const msbuild: TaskEntry = { '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', '\t// for the documentation about the tasks.json format', '\t"version": "2.0.0",', - '\t"command": "msbuild",', - '\t"args": [', - '\t\t// Ask msbuild to generate full paths for file names.', - '\t\t"/property:GenerateFullPaths=true"', - '\t],', - '\t"taskSelector": "/t:",', - '\t"showOutput": "silent",', '\t"tasks": [', '\t\t{', '\t\t\t"taskName": "build",', - '\t\t\t// Show the output window only if unrecognized errors occur.', - '\t\t\t"showOutput": "silent",', + '\t\t\t"command": "msbuild",', + '\t\t\t"args": [', + '\t\t\t\t// Ask msbuild to generate full paths for file names.', + '\t\t\t\t"/property:GenerateFullPaths=true",', + '\t\t\t\t"/t:build"', + '\t\t\t],', + '\t\t\t"group": "build",', + '\t\t\t"terminal": {', + '\t\t\t\t// Reveal the terminal only if unrecognized errors occur.', + '\t\t\t\t"reveal": "silent"', + '\t\t\t},', '\t\t\t// Use the standard MS compiler pattern to detect errors, warnings and infos', '\t\t\t"problemMatcher": "$msCompile"', '\t\t}', @@ -201,26 +105,25 @@ const maven: TaskEntry = { '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', '\t// for the documentation about the tasks.json format', '\t"version": "2.0.0",', - '\t"showOutput": "always",', '\t"tasks": [', '\t\t{', '\t\t\t"taskName": "verify",', '\t\t\t"command": "mvn -B verify",', '\t\t\t"isShellCommand": true,', - '\t\t\t"isBuildCommand": true', + '\t\t\t"group": "build"', '\t\t},', '\t\t{', '\t\t\t"taskName": "test",', '\t\t\t"command": "mvn -B test",', '\t\t\t"isShellCommand": true,', - '\t\t\t"isTestCommand": true', + '\t\t\t"group": "test"', '\t\t}', '\t]', '}' ].join('\n') }; -export let templates: TaskEntry[] = [gulp, grunt, tscConfig, tscWatch, dotnetBuild, msbuild, npm, maven].sort((a, b) => { +export let templates: TaskEntry[] = [dotnetBuild, msbuild, maven].sort((a, b) => { return (a.sort || a.label).localeCompare(b.sort || b.label); }); templates.push(command); diff --git a/src/vs/workbench/parts/tasks/common/tasks.ts b/src/vs/workbench/parts/tasks/common/tasks.ts index 4b3031da91f..c3e90f83fb6 100644 --- a/src/vs/workbench/parts/tasks/common/tasks.ts +++ b/src/vs/workbench/parts/tasks/common/tasks.ts @@ -9,20 +9,6 @@ import * as Types from 'vs/base/common/types'; import { IExtensionDescription } from 'vs/platform/extensions/common/extensions'; import { ProblemMatcher } from 'vs/platform/markers/common/problemMatcher'; -export interface CommandOptions { - /** - * The current working directory of the executed program or shell. - * If omitted VSCode's current workspace root is used. - */ - cwd?: string; - - /** - * The environment of the executed program or shell. If omitted - * the parent process' environment is used. - */ - env?: { [key: string]: string; }; -} - export interface ShellConfiguration { /** * The shell executable. @@ -41,6 +27,26 @@ export namespace ShellConfiguration { } } +export interface CommandOptions { + + /** + * The shell to use if the task is a shell command. + */ + shell?: ShellConfiguration; + + /** + * The current working directory of the executed program or shell. + * If omitted VSCode's current workspace root is used. + */ + cwd?: string; + + /** + * The environment of the executed program or shell. If omitted + * the parent process' environment is used. + */ + env?: { [key: string]: string; }; +} + export enum RevealKind { /** * Always brings the terminal to front if the task is executed. @@ -87,16 +93,35 @@ export interface TerminalBehavior { echo: boolean; } +export enum CommandType { + Shell = 1, + Process = 2 +} + +export namespace CommandType { + export function fromString(value: string): CommandType { + switch (value.toLowerCase()) { + case 'shell': + return CommandType.Shell; + case 'process': + return CommandType.Process; + default: + return CommandType.Process; + } + } +} + export interface CommandConfiguration { + /** - * The command to execute + * The task type */ - name: string; + type: CommandType; /** - * Whether the command is a shell command or not + * The command to execute */ - isShellCommand: boolean | ShellConfiguration; + name: string; /** * Additional command options. diff --git a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts index 4ece04baf2e..2efb28f4d6a 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts @@ -104,6 +104,13 @@ const group: IJSONSchema = { description: nls.localize('JsonSchema.tasks.group', 'Defines to which execution group this task belongs to. If omitted the task belongs to no group') }; +const taskType: IJSONSchema = { + type: 'string', + enum: ['shell', 'process'], + default: 'process', + description: nls.localize('JsonSchema.tasks.type', 'Defines whether the task is run as a process or as a command inside a shell. Default is process') +}; + schema.definitions = Objects.deepClone(commonSchema.definitions); let definitions = schema.definitions; definitions.commandConfiguration.properties.isShellCommand = Objects.deepClone(shellCommand); @@ -113,6 +120,8 @@ definitions.showOutputType.deprecationMessage = nls.localize('JsonSchema.tasks.s definitions.taskDescription.properties.echoCommand.deprecationMessage = nls.localize('JsonSchema.tasks.echoCommand.deprecated', 'The property echoCommand is deprecated. Use the terminal property instead.'); definitions.taskDescription.properties.isBuildCommand.deprecationMessage = nls.localize('JsonSchema.tasks.isBuildCommand.deprecated', 'The property isBuildCommand is deprecated. Use the group property instead.'); definitions.taskDescription.properties.isTestCommand.deprecationMessage = nls.localize('JsonSchema.tasks.isTestCommand.deprecated', 'The property isTestCommand is deprecated. Use the group property instead.'); +definitions.taskDescription.properties.type = taskType; +definitions.taskDescription.properties.isShellCommand.deprecationMessage = nls.localize('JsonSchema.tasks.isShellCommand.deprecated', 'The property isShellCommand is deprecated. Use the type property instead.'); definitions.taskDescription.properties.terminal = terminal; definitions.taskDescription.properties.group = group; definitions.taskRunnerConfiguration.properties.isShellCommand = Objects.deepClone(shellCommand); diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index 98b390f2f21..49c14ca2110 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -61,6 +61,7 @@ import Constants from 'vs/workbench/parts/markers/common/constants'; import { IPartService } from 'vs/workbench/services/part/common/partService'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; import { IConfigurationResolverService } from 'vs/workbench/services/configurationResolver/common/configurationResolver'; +import { IConfigurationEditingService, ConfigurationTarget } from 'vs/workbench/services/configuration/common/configurationEditing'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; @@ -118,40 +119,13 @@ abstract class OpenTaskConfigurationAction extends Action { if (!selection) { return undefined; } - let contentPromise: TPromise; - if (selection.autoDetect) { - contentPromise = this.extensionService.activateByEvent('onCommand:workbench.action.tasks.runTask').then(() => { - return this.taskService.tasks().then((tasks) => { - let tasksToInsert: Task[] = tasks.filter((task) => { - return task.identifier && task.identifier.indexOf(selection.id) === 0 && task.identifier[selection.id.length] === '.' && task.group !== void 0; - }); - if (tasksToInsert.length === 0) { - return selection.content; - } - let config: TaskConfig.ExternalTaskRunnerConfiguration = { - version: '2.0.0', - tasks: tasksToInsert.map((task) => { return { taskName: task.name }; }) - }; - let content = JSON.stringify(config, null, '\t'); - content = [ - '{', - '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', - '\t// for the documentation about the tasks.json format', - ].join('\n') + content.substr(1); - return content; - }); - }); - } else { - contentPromise = TPromise.as(selection.content); + let content = selection.content; + let editorConfig = this.configurationService.getConfiguration(); + if (editorConfig.editor.insertSpaces) { + content = content.replace(/(\n)(\t+)/g, (_, s1, s2) => s1 + strings.repeat(' ', s2.length * editorConfig.editor.tabSize)); } - return contentPromise.then(content => { - let editorConfig = this.configurationService.getConfiguration(); - if (editorConfig.editor.insertSpaces) { - content = content.replace(/(\n)(\t+)/g, (_, s1, s2) => s1 + strings.repeat(' ', s2.length * editorConfig.editor.tabSize)); - } - configFileCreated = true; - return this.fileService.createFile(this.contextService.toResource('.vscode/tasks.json'), content); - }); + configFileCreated = true; + return this.fileService.createFile(this.contextService.toResource('.vscode/tasks.json'), content); }); }).then((stat) => { if (!stat) { @@ -187,7 +161,6 @@ class ConfigureTaskRunnerAction extends OpenTaskConfigurationAction { outputService, messageService, quickOpenService, environmentService, configurationResolverService, extensionService); } - } class ConfigureBuildTaskAction extends OpenTaskConfigurationAction { @@ -503,6 +476,7 @@ class TaskService extends EventEmitter implements ITaskService { private modeService: IModeService; private configurationService: IConfigurationService; + private configurationEditingService: IConfigurationEditingService; private markerService: IMarkerService; private outputService: IOutputService; private messageService: IMessageService; @@ -526,6 +500,7 @@ class TaskService extends EventEmitter implements ITaskService { private _outputChannel: IOutputChannel; constructor( @IModeService modeService: IModeService, @IConfigurationService configurationService: IConfigurationService, + @IConfigurationEditingService configurationEditingService: IConfigurationEditingService, @IMarkerService markerService: IMarkerService, @IOutputService outputService: IOutputService, @IMessageService messageService: IMessageService, @IWorkbenchEditorService editorService: IWorkbenchEditorService, @IFileService fileService: IFileService, @IWorkspaceContextService contextService: IWorkspaceContextService, @@ -542,6 +517,7 @@ class TaskService extends EventEmitter implements ITaskService { super(); this.modeService = modeService; this.configurationService = configurationService; + this.configurationEditingService = configurationEditingService; this.markerService = markerService; this.outputService = outputService; this.messageService = messageService; @@ -723,6 +699,43 @@ class TaskService extends EventEmitter implements ITaskService { }); } + public customize(task: Task, openConfig: boolean = false): TPromise { + if (task._source.kind !== TaskSourceKind.Extension) { + return TPromise.as(undefined); + } + let configuration = this.getConfiguration(); + if (configuration.hasParseErrors) { + this.messageService.show(Severity.Warning, nls.localize('customizeParseErrors', 'The current task configuration has errors. Please fix the errors first before customizing a task.')); + return TPromise.as(undefined); + } + let fileConfig = configuration.config; + let customize = { taskName: task.name }; + if (!fileConfig) { + fileConfig = { + version: '2.0.0', + tasks: [customize] + }; + } else { + if (Array.isArray(fileConfig.tasks)) { + fileConfig.tasks.push(customize); + } else { + fileConfig.tasks = [customize]; + } + }; + return this.configurationEditingService.writeConfiguration(ConfigurationTarget.WORKSPACE, { key: 'tasks', value: fileConfig }).then(() => { + if (openConfig) { + let resource = this.contextService.toResource('.vscode/tasks.json'); + this.editorService.openEditor({ + resource: resource, + options: { + forceOpen: true, + pinned: false + } + }, false); + } + }); + } + private createRunnableTask(sets: TaskSet[], group: TaskGroup): { task: Task; resolver: ITaskResolver } { let uuidMap: IStringDictionary = Object.create(null); let identifierMap: IStringDictionary = Object.create(null); @@ -740,6 +753,8 @@ class TaskService extends EventEmitter implements ITaskService { if (primaryTasks.length === 0) { return undefined; } + // check for a WORKSPACE build task and use that onemptied.apply + let resolver: ITaskResolver = { resolve: (id: string) => { let result = uuidMap[id]; diff --git a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts index 504d0114385..bf6065aa66a 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts @@ -33,7 +33,7 @@ import { IConfigurationResolverService } from 'vs/workbench/services/configurati import { ITerminalService, ITerminalInstance, IShellLaunchConfig } from 'vs/workbench/parts/terminal/common/terminal'; import { IOutputService, IOutputChannel } from 'vs/workbench/parts/output/common/output'; import { StartStopProblemCollector, WatchingProblemCollector, ProblemCollectorEvents } from 'vs/workbench/parts/tasks/common/problemCollectors'; -import { Task, RevealKind, CommandOptions, ShellConfiguration } from 'vs/workbench/parts/tasks/common/tasks'; +import { Task, RevealKind, CommandOptions, ShellConfiguration, CommandType } from 'vs/workbench/parts/tasks/common/tasks'; import { ITaskSystem, ITaskSummary, ITaskExecuteResult, TaskExecuteKind, TaskError, TaskErrors, ITaskResolver, TelemetryEvent, Triggers, TaskSystemEvents, TaskEvent, TaskType @@ -368,17 +368,19 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { let terminalName = nls.localize('TerminalTaskSystem.terminalName', 'Task - {0}', task.name); let waitOnExit = task.command.terminal.reveal !== RevealKind.Never || !task.isBackground; let shellLaunchConfig: IShellLaunchConfig = undefined; - if (task.command.isShellCommand) { + let isShellCommand = task.command.type === CommandType.Shell; + if (isShellCommand) { if (Platform.isWindows && ((options.cwd && TPath.isUNC(options.cwd)) || (!options.cwd && TPath.isUNC(process.cwd())))) { throw new TaskError(Severity.Error, nls.localize('TerminalTaskSystem', 'Can\'t execute a shell command on an UNC drive.'), TaskErrors.UnknownError); } shellLaunchConfig = { name: terminalName, executable: null, args: null, waitOnExit }; let shellSpecified: boolean = false; - if (ShellConfiguration.is(task.command.isShellCommand)) { - shellLaunchConfig.executable = task.command.isShellCommand.executable; + let shellOptions: ShellConfiguration = task.command.options && task.command.options.shell; + if (shellOptions && shellOptions.executable) { + shellLaunchConfig.executable = shellOptions.executable; shellSpecified = true; - if (task.command.isShellCommand.args) { - shellLaunchConfig.args = task.command.isShellCommand.args.slice(); + if (shellOptions.args) { + shellLaunchConfig.args = shellOptions.args.slice(); } else { shellLaunchConfig.args = []; } @@ -422,7 +424,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { let cwd = options && options.cwd ? options.cwd : process.cwd(); // On Windows executed process must be described absolute. Since we allowed command without an // absolute path (e.g. "command": "node") we need to find the executable in the CWD or PATH. - let executable = Platform.isWindows && !task.command.isShellCommand ? this.findExecutable(command, cwd) : command; + let executable = Platform.isWindows && !isShellCommand ? this.findExecutable(command, cwd) : command; shellLaunchConfig = { name: terminalName, executable: executable, diff --git a/src/vs/workbench/parts/tasks/node/processTaskSystem.ts b/src/vs/workbench/parts/tasks/node/processTaskSystem.ts index 848368e6dc4..2a1fcb76e73 100644 --- a/src/vs/workbench/parts/tasks/node/processTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/node/processTaskSystem.ts @@ -29,7 +29,7 @@ import { StartStopProblemCollector, WatchingProblemCollector, ProblemCollectorEv import { ITaskSystem, ITaskSummary, ITaskExecuteResult, TaskExecuteKind, TaskError, TaskErrors, TelemetryEvent, Triggers, TaskSystemEvents, TaskEvent, TaskType } from 'vs/workbench/parts/tasks/common/taskSystem'; -import { Task, CommandOptions, RevealKind, CommandConfiguration } from 'vs/workbench/parts/tasks/common/tasks'; +import { Task, CommandOptions, RevealKind, CommandConfiguration, CommandType } from 'vs/workbench/parts/tasks/common/tasks'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; @@ -175,7 +175,7 @@ export class ProcessTaskSystem extends EventEmitter implements ITaskSystem { } args = this.resolveVariables(args); let command: string = this.resolveVariable(commandConfig.name); - this.childProcess = new LineProcess(command, args, !!commandConfig.isShellCommand, this.resolveOptions(commandConfig.options)); + this.childProcess = new LineProcess(command, args, commandConfig.type === CommandType.Shell, this.resolveOptions(commandConfig.options)); telemetryEvent.command = this.childProcess.getSanitizedCommand(); // we have no problem matchers defined. So show the output log let reveal = task.command.terminal.reveal; diff --git a/src/vs/workbench/parts/tasks/test/node/configuration.test.ts b/src/vs/workbench/parts/tasks/test/node/configuration.test.ts index 091899e941a..03610ad7ecc 100644 --- a/src/vs/workbench/parts/tasks/test/node/configuration.test.ts +++ b/src/vs/workbench/parts/tasks/test/node/configuration.test.ts @@ -96,7 +96,7 @@ class CommandConfigurationBuilder { this.terminalBuilder = new TerminalBehaviorBuilder(this); this.result = { name: command, - isShellCommand: false, + type: Tasks.CommandType.Process, args: [], options: { cwd: '${workspaceRoot}' @@ -110,8 +110,8 @@ class CommandConfigurationBuilder { return this; } - public shell(value: boolean): CommandConfigurationBuilder { - this.result.isShellCommand = value; + public type(value: Tasks.CommandType): CommandConfigurationBuilder { + this.result.type = value; return this; } @@ -433,7 +433,7 @@ function assertCommandConfiguration(actual: Tasks.CommandConfiguration, expected if (actual && expected) { assertTerminalBehavior(actual.terminal, expected.terminal); assert.strictEqual(actual.name, expected.name, 'name'); - assert.strictEqual(actual.isShellCommand, expected.isShellCommand, 'isShellCommand'); + assert.strictEqual(actual.type, expected.type, 'task type'); assert.deepEqual(actual.args, expected.args, 'args'); assert.strictEqual(typeof actual.options, typeof expected.options); if (actual.options && expected.options) { @@ -531,7 +531,7 @@ suite('Tasks Configuration parsing tests', () => { group(Tasks.TaskGroup.Build). suppressTaskName(true). command(). - shell(true); + type(Tasks.CommandType.Shell); testConfiguration( { version: '0.1.0', @@ -730,7 +730,7 @@ suite('Tasks Configuration parsing tests', () => { group(Tasks.TaskGroup.Build). suppressTaskName(true). command(). - shell(true); + type(Tasks.CommandType.Shell); let external: ExternalTaskRunnerConfiguration = { version: '0.1.0', command: 'tsc', @@ -1280,7 +1280,7 @@ suite('Tasks Configuration parsing tests', () => { }; let builder = new ConfiguationBuilder(); builder.task('taskNameOne', 'tsc').suppressTaskName(true).command(). - shell(true).args(['arg']).options({ cwd: 'cwd', env: { env: 'env' } }); + type(Tasks.CommandType.Shell).args(['arg']).options({ cwd: 'cwd', env: { env: 'env' } }); testConfiguration(external, builder); }); @@ -1355,7 +1355,7 @@ suite('Tasks Configuration parsing tests', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('taskNameOne', 'tsc').command().shell(false); + builder.task('taskNameOne', 'tsc').command().type(Tasks.CommandType.Process); testConfiguration(external, builder); }); }); -- GitLab From abb10a8520e38b4f81ace849a3c6e43a9a6b9c0f Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Fri, 26 May 2017 14:57:53 +0200 Subject: [PATCH 0208/1347] Allowed async for smoke test folder. --- tslint.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tslint.json b/tslint.json index 9c0f132b77e..b61b70ab046 100644 --- a/tslint.json +++ b/tslint.json @@ -66,7 +66,8 @@ "node", "electron-main", "electron-browser", - "extensions" + "extensions", + "smoke" ] ] } -- GitLab From 447622435ae4745a0a4b9b7033e178d399c82b88 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Fri, 26 May 2017 15:17:19 +0200 Subject: [PATCH 0209/1347] Remove ProblemMatchers from API. --- src/vs/vscode.d.ts | 215 +----------------- src/vs/workbench/api/node/extHost.api.impl.ts | 2 - src/vs/workbench/api/node/extHostTask.ts | 8 +- src/vs/workbench/api/node/extHostTypes.ts | 20 +- .../workbench/parts/tasks/common/task.api.ts | 213 +++++++++++++++++ 5 files changed, 231 insertions(+), 227 deletions(-) create mode 100644 src/vs/workbench/parts/tasks/common/task.api.ts diff --git a/src/vs/vscode.d.ts b/src/vs/vscode.d.ts index e9645e8147d..f9587fccbe0 100644 --- a/src/vs/vscode.d.ts +++ b/src/vs/vscode.d.ts @@ -3509,215 +3509,6 @@ declare module 'vscode' { update(key: string, value: any): Thenable; } - /** - * Defines a problem pattern - */ - export interface ProblemPattern { - - /** - * The regular expression to find a problem in the console output of an - * executed task. - */ - regexp: RegExp; - - /** - * The match group index of the filename. - * - * Defaults to 1 if omitted. - */ - file?: number; - - /** - * The match group index of the problems's location. Valid location - * patterns are: (line), (line,column) and (startLine,startColumn,endLine,endColumn). - * If omitted the line and colum properties are used. - */ - location?: number; - - /** - * The match group index of the problem's line in the source file. - * - * Defaults to 2 if omitted. - */ - line?: number; - - /** - * The match group index of the problem's character in the source file. - * - * Defaults to 3 if omitted. - */ - character?: number; - - /** - * The match group index of the problem's end line in the source file. - * - * Defaults to undefined. No end line is captured. - */ - endLine?: number; - - /** - * The match group index of the problem's end character in the source file. - * - * Defaults to undefined. No end column is captured. - */ - endCharacter?: number; - - /** - * The match group index of the problem's severity. - * - * Defaults to undefined. In this case the problem matcher's severity - * is used. - */ - severity?: number; - - /** - * The match group index of the problems's code. - * - * Defaults to undefined. No code is captured. - */ - code?: number; - - /** - * The match group index of the message. If omitted it defaults - * to 4 if location is specified. Otherwise it defaults to 5. - */ - message?: number; - - /** - * Specifies if the last pattern in a multi line problem matcher should - * loop as long as it does match a line consequently. Only valid on the - * last problem pattern in a multi line problem matcher. - */ - loop?: boolean; - } - - /** - * A multi line problem pattern. - */ - export type MultiLineProblemPattern = ProblemPattern[]; - - /** - * The way how the file location is interpreted - */ - export enum FileLocationKind { - /** - * VS Code should decide based on whether the file path found in the - * output is absolute or relative. A relative file path will be treated - * relative to the workspace root. - */ - Auto = 1, - - /** - * Always treat the file path relative. - */ - Relative = 2, - - /** - * Always treat the file path absolute. - */ - Absolute = 3 - } - - /** - * Controls to which kind of documents problems are applied. - */ - export enum ApplyToKind { - /** - * Problems are applied to all documents. - */ - AllDocuments = 1, - - /** - * Problems are applied to open documents only. - */ - OpenDocuments = 2, - - - /** - * Problems are applied to closed documents only. - */ - ClosedDocuments = 3 - } - - - /** - * A background monitor pattern - */ - export interface BackgroundPattern { - /** - * The actual regular expression - */ - regexp: RegExp; - - /** - * The match group index of the filename. If provided the expression - * is matched for that file only. - */ - file?: number; - } - - /** - * A description to control the activity of a problem matcher - * watching a background task. - */ - export interface BackgroundMonitor { - /** - * If set to true the monitor is in active mode when the task - * starts. This is equals of issuing a line that matches the - * beginPattern. - */ - activeOnStart?: boolean; - - /** - * If matched in the output the start of a background activity is signaled. - */ - beginsPattern: RegExp | BackgroundPattern; - - /** - * If matched in the output the end of a background activity is signaled. - */ - endsPattern: RegExp | BackgroundPattern; - } - - /** - * Defines a problem matcher - */ - export interface ProblemMatcher { - /** - * The owner of a problem. Defaults to a generated id - * if omitted. - */ - owner?: string; - - /** - * The type of documents problems detected by this matcher - * apply to. Default to `ApplyToKind.AllDocuments` if omitted. - */ - applyTo?: ApplyToKind; - - /** - * How a file location recognized by a matcher should be interpreted. If omitted the file location - * if `FileLocationKind.Auto`. - */ - fileLocation?: FileLocationKind | string; - - /** - * The actual pattern used by the problem matcher. - */ - pattern: ProblemPattern | MultiLineProblemPattern; - - /** - * The default severity of a detected problem in the output. Used - * if the `ProblemPattern` doesn't define a severity match group. - */ - severity?: DiagnosticSeverity; - - /** - * A background monitor for tasks that are running in the background. - */ - backgound?: BackgroundMonitor; - } - /** * Controls the behaviour of the terminal's visibility. */ @@ -3797,7 +3588,7 @@ declare module 'vscode' { /** * The ProblemMatchers type definition. */ - export type ProblemMatchers = string | ProblemMatcher | (string | ProblemMatcher)[]; + export type ProblemMatchers = string | string[]; /** * A task that starts an external process. @@ -3881,7 +3672,7 @@ declare module 'vscode' { * The problem matchers attached to the task. Defaults to an empty * array. */ - problemMatchers: (string | ProblemMatcher)[]; + problemMatchers: string[]; } export type ShellOptions = { @@ -4001,7 +3792,7 @@ declare module 'vscode' { * The problem matchers attached to the task. Defaults to an empty * array. */ - problemMatchers: (string | ProblemMatcher)[]; + problemMatchers: string[]; } export type Task = ProcessTask | ShellTask; diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index eb5b38f2391..80ab4b01781 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -536,8 +536,6 @@ export function createApiFactory( TreeItemCollapsibleState: extHostTypes.TreeItemCollapsibleState, ThemeColor: extHostTypes.ThemeColor, // functions - FileLocationKind: extHostTypes.FileLocationKind, - ApplyToKind: extHostTypes.ApplyToKind, RevealKind: extHostTypes.RevealKind, TaskGroup: extHostTypes.TaskGroup, ShellTask: extHostTypes.ShellTask, diff --git a/src/vs/workbench/api/node/extHostTask.ts b/src/vs/workbench/api/node/extHostTask.ts index 65e818dafc3..19b3bcaae5d 100644 --- a/src/vs/workbench/api/node/extHostTask.ts +++ b/src/vs/workbench/api/node/extHostTask.ts @@ -8,13 +8,11 @@ import { TPromise } from 'vs/base/common/winjs.base'; import * as UUID from 'vs/base/common/uuid'; import { asWinJsPromise } from 'vs/base/common/async'; -import * as Problems from 'vs/platform/markers/common/problemMatcher'; import { IExtensionDescription } from 'vs/platform/extensions/common/extensions'; import * as TaskSystem from 'vs/workbench/parts/tasks/common/tasks'; import { IThreadService } from 'vs/workbench/services/thread/common/threadService'; import { MainContext, MainThreadTaskShape, ExtHostTaskShape } from 'vs/workbench/api/node/extHost.protocol'; -import { fromDiagnosticSeverity } from 'vs/workbench/api/node/extHostTypeConverters'; import * as types from 'vs/workbench/api/node/extHostTypes'; import * as vscode from 'vscode'; @@ -23,6 +21,7 @@ interface StringMap { [key: string]: V; } +/* namespace ProblemPattern { export function from(value: vscode.ProblemPattern | vscode.MultiLineProblemPattern): Problems.ProblemPattern | Problems.MultiLineProblemPattern { if (value === void 0 || value === null) { @@ -144,7 +143,7 @@ namespace WatchingPattern { } } -namespace WathingMatcher { +namespace BackgroundMonitor { export function from(value: vscode.BackgroundMonitor): Problems.WatchingMatcher { if (value === void 0 || value === null) { return undefined; @@ -190,6 +189,7 @@ namespace ProblemMatcher { return result; } } +*/ namespace RevealKind { export function from(value: vscode.RevealKind): TaskSystem.ShowOutput { @@ -314,7 +314,7 @@ namespace Tasks { showOutput: behaviour.showOutput, isBackground: !!task.isBackground, suppressTaskName: true, - problemMatchers: ProblemMatcher.from(task.problemMatchers) + problemMatchers: task.problemMatchers.slice() }; return result; } diff --git a/src/vs/workbench/api/node/extHostTypes.ts b/src/vs/workbench/api/node/extHostTypes.ts index 20b0d2a1aff..d78f0d8d75e 100644 --- a/src/vs/workbench/api/node/extHostTypes.ts +++ b/src/vs/workbench/api/node/extHostTypes.ts @@ -1018,12 +1018,12 @@ export enum RevealKind { export class BaseTask { private _name: string; - private _problemMatchers: (string | vscode.ProblemMatcher)[]; + private _problemMatchers: string[]; private _identifier: string; private _isBackground: boolean; private _terminal: vscode.TerminalBehaviour; - constructor(name: string, problemMatchers: (string | vscode.ProblemMatcher)[]) { + constructor(name: string, problemMatchers: string[]) { if (typeof name !== 'string') { throw illegalArgument('name'); } @@ -1074,11 +1074,11 @@ export class BaseTask { this._terminal = value; } - get problemMatchers(): (string | vscode.ProblemMatcher)[] { + get problemMatchers(): string[] { return this._problemMatchers; } - set problemMatchers(value: (string | vscode.ProblemMatcher)[]) { + set problemMatchers(value: string[]) { if (!Array.isArray(value)) { value = []; } @@ -1086,12 +1086,14 @@ export class BaseTask { } } +/* namespace ProblemMatcher { export function is(value: any): value is vscode.ProblemMatcher { let candidate: vscode.ProblemMatcher = value; return candidate && !!candidate.pattern; } } +*/ namespace ShellOptions { export function is(value: any): value is vscode.ShellOptions { @@ -1144,7 +1146,7 @@ export class ProcessTask extends BaseTask { args = arg3 || []; if (arg4) { - if (Array.isArray(arg4) || typeof arg4 === 'string' || ProblemMatcher.is(arg4)) { + if (Array.isArray(arg4) || typeof arg4 === 'string') { problemMatchers = arg4; } else { options = arg4; @@ -1153,8 +1155,8 @@ export class ProcessTask extends BaseTask { if (arg5 && !problemMatchers) { problemMatchers = arg5; } - let pm: (string | vscode.ProblemMatcher)[]; - if (problemMatchers && (typeof problemMatchers === 'string' || ProblemMatcher.is(problemMatchers))) { + let pm: string[]; + if (problemMatchers && (typeof problemMatchers === 'string')) { pm = [problemMatchers]; } else if (Array.isArray(problemMatchers)) { pm = problemMatchers; @@ -1217,13 +1219,13 @@ export class ShellTask extends BaseTask implements vscode.ShellTask { throw illegalArgument('commandLine'); } let options: vscode.ShellOptions = undefined; - let pm: (string | vscode.ProblemMatcher)[]; + let pm: string[]; if (ShellOptions.is(optionsOrProblemMatchers)) { options = optionsOrProblemMatchers; } else { problemMatchers = optionsOrProblemMatchers; } - if (problemMatchers && (typeof problemMatchers === 'string' || ProblemMatcher.is(problemMatchers))) { + if (problemMatchers && (typeof problemMatchers === 'string')) { pm = [problemMatchers]; } else if (Array.isArray(problemMatchers)) { pm = problemMatchers; diff --git a/src/vs/workbench/parts/tasks/common/task.api.ts b/src/vs/workbench/parts/tasks/common/task.api.ts new file mode 100644 index 00000000000..212047ae084 --- /dev/null +++ b/src/vs/workbench/parts/tasks/common/task.api.ts @@ -0,0 +1,213 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +/** + * Defines a problem pattern + */ +export interface ProblemPattern { + + /** + * The regular expression to find a problem in the console output of an + * executed task. + */ + regexp: RegExp; + + /** + * The match group index of the filename. + * + * Defaults to 1 if omitted. + */ + file?: number; + + /** + * The match group index of the problems's location. Valid location + * patterns are: (line), (line,column) and (startLine,startColumn,endLine,endColumn). + * If omitted the line and colum properties are used. + */ + location?: number; + + /** + * The match group index of the problem's line in the source file. + * + * Defaults to 2 if omitted. + */ + line?: number; + + /** + * The match group index of the problem's character in the source file. + * + * Defaults to 3 if omitted. + */ + character?: number; + + /** + * The match group index of the problem's end line in the source file. + * + * Defaults to undefined. No end line is captured. + */ + endLine?: number; + + /** + * The match group index of the problem's end character in the source file. + * + * Defaults to undefined. No end column is captured. + */ + endCharacter?: number; + + /** + * The match group index of the problem's severity. + * + * Defaults to undefined. In this case the problem matcher's severity + * is used. + */ + severity?: number; + + /** + * The match group index of the problems's code. + * + * Defaults to undefined. No code is captured. + */ + code?: number; + + /** + * The match group index of the message. If omitted it defaults + * to 4 if location is specified. Otherwise it defaults to 5. + */ + message?: number; + + /** + * Specifies if the last pattern in a multi line problem matcher should + * loop as long as it does match a line consequently. Only valid on the + * last problem pattern in a multi line problem matcher. + */ + loop?: boolean; +} + +/** + * A multi line problem pattern. + */ +export type MultiLineProblemPattern = ProblemPattern[]; + +/** + * The way how the file location is interpreted + */ +export enum FileLocationKind { + /** + * VS Code should decide based on whether the file path found in the + * output is absolute or relative. A relative file path will be treated + * relative to the workspace root. + */ + Auto = 1, + + /** + * Always treat the file path relative. + */ + Relative = 2, + + /** + * Always treat the file path absolute. + */ + Absolute = 3 +} + +/** + * Controls to which kind of documents problems are applied. + */ +export enum ApplyToKind { + /** + * Problems are applied to all documents. + */ + AllDocuments = 1, + + /** + * Problems are applied to open documents only. + */ + OpenDocuments = 2, + + + /** + * Problems are applied to closed documents only. + */ + ClosedDocuments = 3 +} + + +/** + * A background monitor pattern + */ +export interface BackgroundPattern { + /** + * The actual regular expression + */ + regexp: RegExp; + + /** + * The match group index of the filename. If provided the expression + * is matched for that file only. + */ + file?: number; +} + +/** + * A description to control the activity of a problem matcher + * watching a background task. + */ +export interface BackgroundMonitor { + /** + * If set to true the monitor is in active mode when the task + * starts. This is equals of issuing a line that matches the + * beginPattern. + */ + activeOnStart?: boolean; + + /** + * If matched in the output the start of a background activity is signaled. + */ + beginsPattern: RegExp | BackgroundPattern; + + /** + * If matched in the output the end of a background activity is signaled. + */ + endsPattern: RegExp | BackgroundPattern; +} + +/** + * Defines a problem matcher + */ +export interface ProblemMatcher { + /** + * The owner of a problem. Defaults to a generated id + * if omitted. + */ + owner?: string; + + /** + * The type of documents problems detected by this matcher + * apply to. Default to `ApplyToKind.AllDocuments` if omitted. + */ + applyTo?: ApplyToKind; + + /** + * How a file location recognized by a matcher should be interpreted. If omitted the file location + * if `FileLocationKind.Auto`. + */ + fileLocation?: FileLocationKind | string; + + /** + * The actual pattern used by the problem matcher. + */ + pattern: ProblemPattern | MultiLineProblemPattern; + + /** + * The default severity of a detected problem in the output. Used + * if the `ProblemPattern` doesn't define a severity match group. + */ + severity?: any; + + /** + * A background monitor for tasks that are running in the background. + */ + backgound?: BackgroundMonitor; +} \ No newline at end of file -- GitLab From 201ea1922ec96aeb1e1fbe3fd838df4dd53a5127 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 26 May 2017 15:29:02 +0200 Subject: [PATCH 0210/1347] snippets - fix test failures because 'deleteLeft' is gone --- .../contrib/snippet/test/browser/snippetController2.test.ts | 2 +- .../editor/contrib/snippet/test/browser/snippetSession.test.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts index 6c30a179315..b862a3dba92 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts @@ -131,7 +131,7 @@ suite('SnippetController2', function () { assertContextKeys(contextKeys, true, false, true); assertSelections(editor, new Selection(1, 1, 1, 7), new Selection(2, 5, 2, 11)); - editor.trigger('test', 'deleteLeft', {}); + editor.trigger('test', 'cut', {}); assertContextKeys(contextKeys, true, false, true); assertSelections(editor, new Selection(1, 1, 1, 1), new Selection(2, 5, 2, 5)); diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts index 100b9c0dbd8..d6a999e751e 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts @@ -388,7 +388,7 @@ suite('SnippetSession', function () { session.next(); assertSelections(editor, new Selection(1, 9, 1, 15)); - editor.trigger('test', 'deleteLeft', {}); + editor.trigger('test', 'cut', {}); assertSelections(editor, new Selection(1, 9, 1, 9)); editor.trigger('test', 'type', { text: 'XXX' }); -- GitLab From 4c71f96c8c518202a0cf57e1624b5f879dc77193 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Fri, 26 May 2017 16:11:25 +0200 Subject: [PATCH 0211/1347] More work on the task v2 json schema --- .../electron-browser/jsonSchemaCommon.ts | 1 + .../tasks/electron-browser/jsonSchema_v2.ts | 83 ++++++++++--------- 2 files changed, 46 insertions(+), 38 deletions(-) diff --git a/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.ts b/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.ts index 12350a98ac8..51b794a250a 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.ts @@ -57,6 +57,7 @@ const schema: IJSONSchema = { shellConfiguration: { type: 'object', additionalProperties: false, + description: nls.localize('JsonSchema.shellConfiguration', 'Configures the shell to be used.'), properties: { executable: { type: 'string', diff --git a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts index 2efb28f4d6a..b184d7ee3ff 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts @@ -10,41 +10,6 @@ import { IJSONSchema } from 'vs/base/common/jsonSchema'; import commonSchema from './jsonSchemaCommon'; -const schema: IJSONSchema = { - oneOf: [ - { - 'allOf': [ - { - 'type': 'object', - 'required': ['version'], - 'properties': { - 'version': { - 'type': 'string', - 'enum': ['2.0.0'], - 'description': nls.localize('JsonSchema.version', 'The config\'s version number') - }, - 'windows': { - '$ref': '#/definitions/taskRunnerConfiguration', - 'description': nls.localize('JsonSchema.windows', 'Windows specific command configuration') - }, - 'osx': { - '$ref': '#/definitions/taskRunnerConfiguration', - 'description': nls.localize('JsonSchema.mac', 'Mac specific command configuration') - }, - 'linux': { - '$ref': '#/definitions/taskRunnerConfiguration', - 'description': nls.localize('JsonSchema.linux', 'Linux specific command configuration') - } - } - }, - { - '$ref': '#/definitions/taskRunnerConfiguration' - } - ] - } - ] -}; - const shellCommand: IJSONSchema = { anyOf: [ { @@ -55,7 +20,8 @@ const shellCommand: IJSONSchema = { { $ref: '#definitions/shellConfiguration' } - ] + ], + deprecationMessage: nls.localize('JsonSchema.tasks.isShellCommand.deprecated', 'The property isShellCommand is deprecated. Use the type property and the shell property in the options instead.') }; const dependsOn: IJSONSchema = { @@ -111,6 +77,43 @@ const taskType: IJSONSchema = { description: nls.localize('JsonSchema.tasks.type', 'Defines whether the task is run as a process or as a command inside a shell. Default is process') }; +const version: IJSONSchema = { + type: 'string', + enum: ['2.0.0'], + description: nls.localize('JsonSchema.version', 'The config\'s version number') +}; + +const schema: IJSONSchema = { + oneOf: [ + { + 'allOf': [ + { + type: 'object', + required: ['version'], + properties: { + version: Objects.deepClone(version), + windows: { + '$ref': '#/definitions/taskRunnerConfiguration', + 'description': nls.localize('JsonSchema.windows', 'Windows specific command configuration') + }, + osx: { + '$ref': '#/definitions/taskRunnerConfiguration', + 'description': nls.localize('JsonSchema.mac', 'Mac specific command configuration') + }, + linux: { + '$ref': '#/definitions/taskRunnerConfiguration', + 'description': nls.localize('JsonSchema.linux', 'Linux specific command configuration') + } + } + }, + { + $ref: '#/definitions/taskRunnerConfiguration' + } + ] + } + ] +}; + schema.definitions = Objects.deepClone(commonSchema.definitions); let definitions = schema.definitions; definitions.commandConfiguration.properties.isShellCommand = Objects.deepClone(shellCommand); @@ -120,11 +123,15 @@ definitions.showOutputType.deprecationMessage = nls.localize('JsonSchema.tasks.s definitions.taskDescription.properties.echoCommand.deprecationMessage = nls.localize('JsonSchema.tasks.echoCommand.deprecated', 'The property echoCommand is deprecated. Use the terminal property instead.'); definitions.taskDescription.properties.isBuildCommand.deprecationMessage = nls.localize('JsonSchema.tasks.isBuildCommand.deprecated', 'The property isBuildCommand is deprecated. Use the group property instead.'); definitions.taskDescription.properties.isTestCommand.deprecationMessage = nls.localize('JsonSchema.tasks.isTestCommand.deprecated', 'The property isTestCommand is deprecated. Use the group property instead.'); -definitions.taskDescription.properties.type = taskType; -definitions.taskDescription.properties.isShellCommand.deprecationMessage = nls.localize('JsonSchema.tasks.isShellCommand.deprecated', 'The property isShellCommand is deprecated. Use the type property instead.'); +definitions.taskDescription.properties.type = Objects.deepClone(taskType); definitions.taskDescription.properties.terminal = terminal; definitions.taskDescription.properties.group = group; +definitions.options.properties.shell = { + $ref: '#/definitions/shellConfiguration' +}; definitions.taskRunnerConfiguration.properties.isShellCommand = Objects.deepClone(shellCommand); +definitions.taskRunnerConfiguration.properties.type = Objects.deepClone(taskType); +definitions.taskRunnerConfiguration.properties.version = Objects.deepClone(version); Object.getOwnPropertyNames(definitions).forEach(key => { let newKey = key + '2'; -- GitLab From c29241c9603a23522033d2d919220e59adbf3df2 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Fri, 26 May 2017 17:25:03 +0200 Subject: [PATCH 0212/1347] [bat] add test for #26825 --- .../bat/test/colorize-fixtures/test.bat | 8 +- .../bat/test/colorize-results/test_bat.json | 85 ++++--------------- 2 files changed, 17 insertions(+), 76 deletions(-) diff --git a/extensions/bat/test/colorize-fixtures/test.bat b/extensions/bat/test/colorize-fixtures/test.bat index f5ae5d25119..3e215fc5efc 100644 --- a/extensions/bat/test/colorize-fixtures/test.bat +++ b/extensions/bat/test/colorize-fixtures/test.bat @@ -16,13 +16,9 @@ if not exist out node .\node_modules\gulp\bin\gulp.js compile :: Configuration set NODE_ENV=development -set VSCODE_DEV=1 -set ELECTRON_DEFAULT_ERROR_MODE=1 -set ELECTRON_ENABLE_LOGGING=1 -set ELECTRON_ENABLE_STACK_DUMPING=1 -:: Launch Code -.\.build\electron\electron.exe . %* +call echo %%LINE:rem +=%% + popd endlocal \ No newline at end of file diff --git a/extensions/bat/test/colorize-results/test_bat.json b/extensions/bat/test/colorize-results/test_bat.json index d909fe69bef..d0f381fc7f3 100644 --- a/extensions/bat/test/colorize-results/test_bat.json +++ b/extensions/bat/test/colorize-results/test_bat.json @@ -264,62 +264,18 @@ } }, { - "c": "set", - "t": "source.dosbatch keyword.command.dosbatch", - "r": { - "dark_plus": "keyword: #569CD6", - "light_plus": "keyword: #0000FF", - "dark_vs": "keyword: #569CD6", - "light_vs": "keyword: #0000FF", - "hc_black": "keyword: #569CD6" - } - }, - { - "c": " VSCODE_DEV=1", - "t": "source.dosbatch", - "r": { - "dark_plus": "default: #D4D4D4", - "light_plus": "default: #000000", - "dark_vs": "default: #D4D4D4", - "light_vs": "default: #000000", - "hc_black": "default: #FFFFFF" - } - }, - { - "c": "set", - "t": "source.dosbatch keyword.command.dosbatch", - "r": { - "dark_plus": "keyword: #569CD6", - "light_plus": "keyword: #0000FF", - "dark_vs": "keyword: #569CD6", - "light_vs": "keyword: #0000FF", - "hc_black": "keyword: #569CD6" - } - }, - { - "c": " ELECTRON_DEFAULT_ERROR_MODE=1", - "t": "source.dosbatch", - "r": { - "dark_plus": "default: #D4D4D4", - "light_plus": "default: #000000", - "dark_vs": "default: #D4D4D4", - "light_vs": "default: #000000", - "hc_black": "default: #FFFFFF" - } - }, - { - "c": "set", - "t": "source.dosbatch keyword.command.dosbatch", + "c": "call", + "t": "source.dosbatch keyword.control.statement.dosbatch", "r": { - "dark_plus": "keyword: #569CD6", - "light_plus": "keyword: #0000FF", - "dark_vs": "keyword: #569CD6", - "light_vs": "keyword: #0000FF", - "hc_black": "keyword: #569CD6" + "dark_plus": "keyword.control: #C586C0", + "light_plus": "keyword.control: #AF00DB", + "dark_vs": "keyword.control: #569CD6", + "light_vs": "keyword.control: #0000FF", + "hc_black": "keyword.control: #C586C0" } }, { - "c": " ELECTRON_ENABLE_LOGGING=1", + "c": " ", "t": "source.dosbatch", "r": { "dark_plus": "default: #D4D4D4", @@ -330,7 +286,7 @@ } }, { - "c": "set", + "c": "echo", "t": "source.dosbatch keyword.command.dosbatch", "r": { "dark_plus": "keyword: #569CD6", @@ -341,7 +297,7 @@ } }, { - "c": " ELECTRON_ENABLE_STACK_DUMPING=1", + "c": " ", "t": "source.dosbatch", "r": { "dark_plus": "default: #D4D4D4", @@ -352,25 +308,14 @@ } }, { - "c": ":: Launch Code", - "t": "source.dosbatch comment.line.colons.dosbatch", + "c": "%%LINE:rem +=%%", + "t": "source.dosbatch variable.other.parsetime.dosbatch", "r": { - "dark_plus": "comment: #608B4E", - "light_plus": "comment: #008000", - "dark_vs": "comment: #608B4E", - "light_vs": "comment: #008000", - "hc_black": "comment: #7CA668" - } - }, - { - "c": ".\\.build\\electron\\electron.exe . %*", - "t": "source.dosbatch", - "r": { - "dark_plus": "default: #D4D4D4", - "light_plus": "default: #000000", + "dark_plus": "variable: #9CDCFE", + "light_plus": "variable: #001080", "dark_vs": "default: #D4D4D4", "light_vs": "default: #000000", - "hc_black": "default: #FFFFFF" + "hc_black": "variable: #9CDCFE" } }, { -- GitLab From dfd358082f4f03d6439e65fb130eb77988ad53ef Mon Sep 17 00:00:00 2001 From: Nick Snyder Date: Fri, 26 May 2017 08:57:47 -0700 Subject: [PATCH 0213/1347] Handle progress results in quick open controller (#27152) --- .../parts/quickopen/quickOpenController.ts | 5 +- src/vs/workbench/browser/quickopen.ts | 4 +- .../search/browser/openAnythingHandler.ts | 47 ++++++++++++------- 3 files changed, 36 insertions(+), 20 deletions(-) diff --git a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts index e86aa2e27e3..59e116b11d4 100644 --- a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts +++ b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts @@ -774,7 +774,7 @@ export class QuickOpenController extends Component implements IQuickOpenService } // Get results - return resolvedHandler.getResults(value).then(result => { + const handleResult = (result) => { if (this.currentResultToken === currentResultToken) { // now is the time to show the input if we did not have set it before @@ -787,7 +787,8 @@ export class QuickOpenController extends Component implements IQuickOpenService const handlerResults = (result && result.entries) || []; this.mergeResults(quickOpenModel, handlerResults, resolvedHandler.getGroupLabel()); } - }); + }; + return resolvedHandler.getResults(value).then(handleResult, undefined, handleResult); }); } diff --git a/src/vs/workbench/browser/quickopen.ts b/src/vs/workbench/browser/quickopen.ts index ebb31e7a833..551ffbd9808 100644 --- a/src/vs/workbench/browser/quickopen.ts +++ b/src/vs/workbench/browser/quickopen.ts @@ -5,7 +5,7 @@ 'use strict'; import nls = require('vs/nls'); -import { TPromise } from 'vs/base/common/winjs.base'; +import { PPromise, TPromise } from 'vs/base/common/winjs.base'; import * as objects from 'vs/base/common/objects'; import filters = require('vs/base/common/filters'); import arrays = require('vs/base/common/arrays'); @@ -34,7 +34,7 @@ export class QuickOpenHandler { * As such, returning the same model instance across multiple searches will yield best * results in terms of performance when many items are shown. */ - public getResults(searchValue: string): TPromise> { + public getResults(searchValue: string): PPromise, IModel> { return TPromise.as(null); } diff --git a/src/vs/workbench/parts/search/browser/openAnythingHandler.ts b/src/vs/workbench/parts/search/browser/openAnythingHandler.ts index cc77586caa2..7ac06c931f6 100644 --- a/src/vs/workbench/parts/search/browser/openAnythingHandler.ts +++ b/src/vs/workbench/parts/search/browser/openAnythingHandler.ts @@ -7,7 +7,7 @@ import * as arrays from 'vs/base/common/arrays'; import * as objects from 'vs/base/common/objects'; -import { TPromise } from 'vs/base/common/winjs.base'; +import { PPromise, TPromise } from 'vs/base/common/winjs.base'; import nls = require('vs/nls'); import { ThrottledDelayer } from 'vs/base/common/async'; import types = require('vs/base/common/types'); @@ -91,7 +91,7 @@ export class OpenAnythingHandler extends QuickOpenHandler { private openSymbolHandler: OpenSymbolHandler; private openFileHandler: OpenFileHandler; private searchDelayer: ThrottledDelayer; - private pendingSearch: TPromise; + private pendingSearch: PPromise; private isClosed: boolean; private scorerCache: { [key: string]: number }; private includeSymbols: boolean; @@ -135,7 +135,7 @@ export class OpenAnythingHandler extends QuickOpenHandler { }); } - public getResults(searchValue: string): TPromise { + public getResults(searchValue: string): PPromise { const startTime = Date.now(); this.cancelPendingSearch(); @@ -166,21 +166,21 @@ export class OpenAnythingHandler extends QuickOpenHandler { // Symbol Results (unless disabled or a range or absolute path is specified) if (this.includeSymbols && !searchWithRange) { resultPromises.push(this.openSymbolHandler.getResults(searchValue)); - } else { - resultPromises.push(TPromise.as(new QuickOpenModel())); // We need this empty promise because we are using the throttler below! } // Join and sort unified - this.pendingSearch = TPromise.join(resultPromises).then(results => { + const handleResults = (results: (QuickOpenModel | FileQuickOpenModel)[]) => { this.pendingSearch = null; // If the quick open widget has been closed meanwhile, ignore the result if (this.isClosed) { - return TPromise.as(new QuickOpenModel()); + return new QuickOpenModel(); } // Combine file results and symbol results (if any) - const mergedResults = [...results[0].entries, ...results[1].entries]; + const mergedResults: QuickOpenEntry[] = results.reduce((entries: QuickOpenEntry[], model: QuickOpenModel) => { + return entries.concat(model.entries); + }, []); // Sort const unsortedResultTime = Date.now(); @@ -200,10 +200,11 @@ export class OpenAnythingHandler extends QuickOpenHandler { }); let fileSearchStats: ISearchStats; - if (results[0] instanceof FileQuickOpenModel) { - fileSearchStats = (results[0]).stats; - } else if (results[1] instanceof FileQuickOpenModel) { - fileSearchStats = (results[1]).stats; + for (const result of results) { + if (result instanceof FileQuickOpenModel) { + fileSearchStats = (result).stats; + break; + } } const duration = new Date().getTime() - startTime; @@ -218,10 +219,24 @@ export class OpenAnythingHandler extends QuickOpenHandler { this.telemetryService.publicLog('openAnything', objects.assign(data, { duration })); - return TPromise.as(new QuickOpenModel(viewResults)); - }, (error: Error) => { - this.pendingSearch = null; - this.messageService.show(Severity.Error, error); + return new QuickOpenModel(viewResults); + }; + + this.pendingSearch = new PPromise((complete, error, progress) => { + // When any of the result promises return, forward the result as progress. + resultPromises.map(resultPromise => { + resultPromise.then(result => { + progress(handleResults([result])); + }); + }); + // Complete the promise when all promises have completed. + TPromise.join(resultPromises).then(() => { + // We already sent the results via progress. + complete(new QuickOpenModel()); + }, error => { + this.pendingSearch = null; + this.messageService.show(Severity.Error, error); + }); }); return this.pendingSearch; -- GitLab From 66bc0d13fafadbddb5b26a3bc114bdcc29cfd39c Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Fri, 26 May 2017 09:02:10 -0700 Subject: [PATCH 0214/1347] Update controller, simplify telemetry (#27152) --- .../parts/quickopen/quickOpenController.ts | 19 ++++--- .../search/browser/openAnythingHandler.ts | 52 ++++++++----------- 2 files changed, 34 insertions(+), 37 deletions(-) diff --git a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts index 59e116b11d4..70ab1330732 100644 --- a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts +++ b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts @@ -774,7 +774,8 @@ export class QuickOpenController extends Component implements IQuickOpenService } // Get results - const handleResult = (result) => { + let addedGroupLabel = false; + const handleResult = (result: IModel, last = false) => { if (this.currentResultToken === currentResultToken) { // now is the time to show the input if we did not have set it before @@ -785,10 +786,10 @@ export class QuickOpenController extends Component implements IQuickOpenService // merge history and default handler results const handlerResults = (result && result.entries) || []; - this.mergeResults(quickOpenModel, handlerResults, resolvedHandler.getGroupLabel()); + addedGroupLabel = this.mergeResults(quickOpenModel, handlerResults, !addedGroupLabel ? resolvedHandler.getGroupLabel() : null, last) || addedGroupLabel; } }; - return resolvedHandler.getResults(value).then(handleResult, undefined, handleResult); + return resolvedHandler.getResults(value).then(result => handleResult(result, true), undefined, handleResult); }); } @@ -845,7 +846,7 @@ export class QuickOpenController extends Component implements IQuickOpenService return results.sort((elementA: EditorHistoryEntry, elementB: EditorHistoryEntry) => QuickOpenEntry.compare(elementA, elementB, normalizedSearchValue)); } - private mergeResults(quickOpenModel: QuickOpenModel, handlerResults: QuickOpenEntry[], groupLabel: string): void { + private mergeResults(quickOpenModel: QuickOpenModel, handlerResults: QuickOpenEntry[], groupLabel: string, last: boolean): boolean { // Remove results already showing by checking for a "resource" property const mapEntryToResource = this.mapEntriesToResource(quickOpenModel); @@ -862,17 +863,21 @@ export class QuickOpenController extends Component implements IQuickOpenService // Show additional handler results below any existing results if (additionalHandlerResults.length > 0) { const autoFocusFirstEntry = (quickOpenModel.getEntries().length === 0); // the user might have selected another entry meanwhile in local history (see https://github.com/Microsoft/vscode/issues/20828) - const useTopBorder = quickOpenModel.getEntries().length > 0; - additionalHandlerResults[0] = new QuickOpenEntryGroup(additionalHandlerResults[0], groupLabel, useTopBorder); + if (groupLabel) { + const useTopBorder = quickOpenModel.getEntries().length > 0; + additionalHandlerResults[0] = new QuickOpenEntryGroup(additionalHandlerResults[0], groupLabel, useTopBorder); + } quickOpenModel.addEntries(additionalHandlerResults); this.quickOpenWidget.refresh(quickOpenModel, { autoFocusFirstEntry }); + return !!groupLabel; } // Otherwise if no results are present (even from histoy) indicate this to the user - else if (quickOpenModel.getEntries().length === 0) { + else if (quickOpenModel.getEntries().length === 0 && last) { quickOpenModel.addEntries([new PlaceholderQuickOpenEntry(nls.localize('noResultsFound1', "No results found"))]); this.quickOpenWidget.refresh(quickOpenModel, { autoFocusFirstEntry: true }); } + return false; } private handleSpecificHandler(handlerDescriptor: QuickOpenHandlerDescriptor, value: string, currentResultToken: string): TPromise { diff --git a/src/vs/workbench/parts/search/browser/openAnythingHandler.ts b/src/vs/workbench/parts/search/browser/openAnythingHandler.ts index 7ac06c931f6..113adfd286d 100644 --- a/src/vs/workbench/parts/search/browser/openAnythingHandler.ts +++ b/src/vs/workbench/parts/search/browser/openAnythingHandler.ts @@ -168,8 +168,7 @@ export class OpenAnythingHandler extends QuickOpenHandler { resultPromises.push(this.openSymbolHandler.getResults(searchValue)); } - // Join and sort unified - const handleResults = (results: (QuickOpenModel | FileQuickOpenModel)[]) => { + const handleResult = (result: QuickOpenModel | FileQuickOpenModel) => { this.pendingSearch = null; // If the quick open widget has been closed meanwhile, ignore the result @@ -177,16 +176,13 @@ export class OpenAnythingHandler extends QuickOpenHandler { return new QuickOpenModel(); } - // Combine file results and symbol results (if any) - const mergedResults: QuickOpenEntry[] = results.reduce((entries: QuickOpenEntry[], model: QuickOpenModel) => { - return entries.concat(model.entries); - }, []); + const entries = result.entries; // Sort const unsortedResultTime = Date.now(); const normalizedSearchValue = strings.stripWildcards(searchValue).toLowerCase(); const compare = (elementA: QuickOpenEntry, elementB: QuickOpenEntry) => QuickOpenEntry.compareByScore(elementA, elementB, searchValue, normalizedSearchValue, this.scorerCache); - const viewResults = arrays.top(mergedResults, compare, OpenAnythingHandler.MAX_DISPLAYED_RESULTS); + const viewResults = arrays.top(entries, compare, OpenAnythingHandler.MAX_DISPLAYED_RESULTS); const sortedResultTime = Date.now(); // Apply range and highlights to file entries @@ -199,38 +195,34 @@ export class OpenAnythingHandler extends QuickOpenHandler { } }); - let fileSearchStats: ISearchStats; - for (const result of results) { - if (result instanceof FileQuickOpenModel) { - fileSearchStats = (result).stats; - break; - } - } - - const duration = new Date().getTime() - startTime; - const data = this.createTimerEventData(startTime, { - searchLength: searchValue.length, - unsortedResultTime, - sortedResultTime, - resultCount: mergedResults.length, - symbols: { fromCache: false }, - files: fileSearchStats - }); + // Telemetry + if (result instanceof FileQuickOpenModel) { + const fileSearchStats = (result).stats; + const duration = new Date().getTime() - startTime; + const data = this.createTimerEventData(startTime, { + searchLength: searchValue.length, + unsortedResultTime, + sortedResultTime, + resultCount: entries.length, + symbols: { fromCache: false }, + files: fileSearchStats + }); - this.telemetryService.publicLog('openAnything', objects.assign(data, { duration })); + this.telemetryService.publicLog('openAnything', objects.assign(data, { duration })); + } return new QuickOpenModel(viewResults); }; this.pendingSearch = new PPromise((complete, error, progress) => { // When any of the result promises return, forward the result as progress. - resultPromises.map(resultPromise => { + const processed = resultPromises.map(resultPromise => resultPromise.then(result => { - progress(handleResults([result])); - }); - }); + progress(handleResult(result)); + }) + ); // Complete the promise when all promises have completed. - TPromise.join(resultPromises).then(() => { + TPromise.join(processed).then(() => { // We already sent the results via progress. complete(new QuickOpenModel()); }, error => { -- GitLab From f2cf819a7b0dbea76b304667658026c4e7965e72 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Fri, 26 May 2017 09:38:25 -0700 Subject: [PATCH 0215/1347] Mention keymaps (fixes #24727) --- .../parts/extensions/electron-browser/extensionsUtils.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.ts b/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.ts index bff8aa3754b..c33a4ecd7d4 100644 --- a/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.ts +++ b/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.ts @@ -73,7 +73,7 @@ export class KeymapExtensions implements IWorkbenchContribution { oldKeymaps: oldKeymaps.map(k => k.identifier) }; this.telemetryService.publicLog('disableOtherKeymapsConfirmation', telemetryData); - const message = localize('disableOtherKeymapsConfirmation', "Disable other keymaps to avoid conflicts between keybindings?"); + const message = localize('disableOtherKeymapsConfirmation', "Disable other keymaps ({0}) to avoid conflicts between keybindings?", oldKeymaps.map(k => `'${k.local.manifest.displayName}'`).join(', ')); const options = [ localize('yes', "Yes"), localize('no', "No") -- GitLab From 4ad0fd04f28d3e42fdfa23eb43bb970840bfd195 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 26 May 2017 16:03:36 +0200 Subject: [PATCH 0216/1347] debt - renames --- .../snippet/browser/snippetController2.ts | 2 +- .../contrib/snippet/browser/snippetSession.ts | 2 +- .../test/browser/snippetSession.test.ts | 24 +++++++++---------- 3 files changed, 14 insertions(+), 14 deletions(-) diff --git a/src/vs/editor/contrib/snippet/browser/snippetController2.ts b/src/vs/editor/contrib/snippet/browser/snippetController2.ts index 73946415785..c17c871a823 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetController2.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetController2.ts @@ -90,7 +90,7 @@ export class SnippetController2 { return this.cancel(); } - if (this._snippet.isAtFinalPlaceholder || !this._snippet.isSelectionWithPlaceholders()) { + if (this._snippet.isAtFinalPlaceholder || !this._snippet.isSelectionWithinPlaceholders()) { return this.cancel(); } diff --git a/src/vs/editor/contrib/snippet/browser/snippetSession.ts b/src/vs/editor/contrib/snippet/browser/snippetSession.ts index 2a38815488c..9450bfa8ba3 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetSession.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetSession.ts @@ -321,7 +321,7 @@ export class SnippetSession { return this._snippets[0].hasPlaceholder; } - isSelectionWithPlaceholders(): boolean { + isSelectionWithinPlaceholders(): boolean { const selections = this._editor.getSelections(); if (selections.length < this._snippets.length) { // this means we started snippet mode with N diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts index d6a999e751e..8d5af1eef2e 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts @@ -299,28 +299,28 @@ suite('SnippetSession', function () { assert.equal(model.getValue(), 'foofarboobarfunction foo() {\n foofarboobarconsole.log(a);\n}'); assertSelections(editor, new Selection(1, 1, 1, 4), new Selection(2, 5, 2, 8)); - assert.equal(session.isSelectionWithPlaceholders(), true); + assert.equal(session.isSelectionWithinPlaceholders(), true); editor.setSelections([new Selection(1, 1, 1, 1)]); - assert.equal(session.isSelectionWithPlaceholders(), false); + assert.equal(session.isSelectionWithinPlaceholders(), false); editor.setSelections([new Selection(1, 6, 1, 6), new Selection(2, 10, 2, 10)]); - assert.equal(session.isSelectionWithPlaceholders(), false); // in snippet, outside placeholder + assert.equal(session.isSelectionWithinPlaceholders(), false); // in snippet, outside placeholder editor.setSelections([new Selection(1, 6, 1, 6), new Selection(2, 10, 2, 10), new Selection(1, 1, 1, 1)]); - assert.equal(session.isSelectionWithPlaceholders(), false); // in snippet, outside placeholder + assert.equal(session.isSelectionWithinPlaceholders(), false); // in snippet, outside placeholder editor.setSelections([new Selection(1, 6, 1, 6), new Selection(2, 10, 2, 10), new Selection(2, 20, 2, 21)]); - assert.equal(session.isSelectionWithPlaceholders(), false); + assert.equal(session.isSelectionWithinPlaceholders(), false); // reset selection to placeholder session.next(); - assert.equal(session.isSelectionWithPlaceholders(), true); + assert.equal(session.isSelectionWithinPlaceholders(), true); assertSelections(editor, new Selection(1, 10, 1, 13), new Selection(2, 14, 2, 17)); // reset selection to placeholder session.next(); - assert.equal(session.isSelectionWithPlaceholders(), true); + assert.equal(session.isSelectionWithinPlaceholders(), true); assert.equal(session.isAtFinalPlaceholder, true); assertSelections(editor, new Selection(1, 13, 1, 13), new Selection(2, 17, 2, 17)); }); @@ -354,10 +354,10 @@ suite('SnippetSession', function () { const session = new SnippetSession(editor); session.insert('farboo$0'); assert.equal(session.isAtFinalPlaceholder, true); - assert.equal(session.isSelectionWithPlaceholders(), false); + assert.equal(session.isSelectionWithinPlaceholders(), false); editor.trigger('test', 'type', { text: 'XXX' }); - assert.equal(session.isSelectionWithPlaceholders(), false); + assert.equal(session.isSelectionWithinPlaceholders(), false); }); test('snippets, typing at beginning', function () { @@ -367,12 +367,12 @@ suite('SnippetSession', function () { session.insert('farboo$0'); editor.setSelection(new Selection(1, 2, 1, 2)); - assert.equal(session.isSelectionWithPlaceholders(), false); + assert.equal(session.isSelectionWithinPlaceholders(), false); assert.equal(session.isAtFinalPlaceholder, true); editor.trigger('test', 'type', { text: 'XXX' }); assert.equal(model.getLineContent(1), 'fXXXfarboounction foo() {'); - assert.equal(session.isSelectionWithPlaceholders(), false); + assert.equal(session.isSelectionWithinPlaceholders(), false); session.next(); assertSelections(editor, new Selection(1, 11, 1, 11)); @@ -410,7 +410,7 @@ suite('SnippetSession', function () { assertSelections(editor, new Selection(1, 4, 1, 4), new Selection(2, 8, 2, 8)); session.insert('bar'); - assert.ok(session.isSelectionWithPlaceholders()); + assert.ok(session.isSelectionWithinPlaceholders()); assertSelections(editor, new Selection(1, 7, 1, 7), new Selection(2, 11, 2, 11)); session.next(); -- GitLab From 52cc722dcd00b02e59edc4ea38cc694fc210d34e Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 26 May 2017 17:27:22 +0200 Subject: [PATCH 0217/1347] basic support for nested snippets, #24855 --- .../snippet/browser/snippetController2.ts | 124 +++++++++++++----- .../contrib/snippet/browser/snippetSession.ts | 74 +++++------ .../test/browser/snippetController2.test.ts | 24 +++- .../test/browser/snippetSession.test.ts | 15 --- 4 files changed, 142 insertions(+), 95 deletions(-) diff --git a/src/vs/editor/contrib/snippet/browser/snippetController2.ts b/src/vs/editor/contrib/snippet/browser/snippetController2.ts index c17c871a823..c35e9766a49 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetController2.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetController2.ts @@ -13,6 +13,62 @@ import { SnippetSession } from './snippetSession'; import { EditorContextKeys } from 'vs/editor/common/editorContextKeys'; import { KeyCode, KeyMod } from 'vs/base/common/keyCodes'; +class SnippetSessions { + + private _stack: SnippetSession[] = []; + + add(session: SnippetSession): number { + return this._stack.push(session); + } + + clear(): void { + dispose(this._stack); + this._stack.length = 0; + } + + get empty(): boolean { + return this._stack.length === 0; + } + + get hasPlaceholder(): boolean { + return this._stack.some(s => s.hasPlaceholder); + } + + get isAtFirstPlaceholder(): boolean { + // return !this.empty && this._stack[0].isAtFirstPlaceholder; + return this._stack.every(s => s.isAtFirstPlaceholder); + } + + get isAtFinalPlaceholder(): boolean { + // return !this.empty && this._stack[0].isAtFinalPlaceholder; + return this._stack.every(s => s.isAtFinalPlaceholder); + } + + get isSelectionWithinPlaceholders(): boolean { + return this._stack.some(s => s.isSelectionWithinPlaceholders()); + } + + prev(): void { + for (let i = this._stack.length - 1; i >= 0; i--) { + const snippet = this._stack[i]; + if (!snippet.isAtFirstPlaceholder) { + snippet.prev(); + break; + } + } + } + + next(): void { + for (let i = this._stack.length - 1; i >= 0; i--) { + const snippet = this._stack[i]; + if (!snippet.isAtFinalPlaceholder) { + snippet.next(); + break; + } + } + } +} + @commonEditorContribution export class SnippetController2 { @@ -28,7 +84,8 @@ export class SnippetController2 { private readonly _hasNextTabstop: IContextKey; private readonly _hasPrevTabstop: IContextKey; - private _snippet: SnippetSession; + // private _snippet: SnippetSession; + private _sessions = new SnippetSessions(); private _snippetListener: IDisposable[] = []; constructor( @@ -44,7 +101,7 @@ export class SnippetController2 { this._inSnippet.reset(); this._hasPrevTabstop.reset(); this._hasNextTabstop.reset(); - dispose(this._snippet); + this._sessions.clear(); } getId(): string { @@ -56,47 +113,49 @@ export class SnippetController2 { overwriteBefore: number = 0, overwriteAfter: number = 0, undoStopBefore: boolean = true, undoStopAfter: boolean = true ): void { + + // don't listen while inserting the snippet + // as that is the inflight state causing cancelation + this._snippetListener = dispose(this._snippetListener); + if (undoStopBefore) { this._editor.getModel().pushStackElement(); } - if (!this._snippet) { - // create a new session - this._snippet = new SnippetSession(this._editor); - this._snippet.insert(template, overwriteBefore, overwriteAfter); - this._snippetListener = [ - this._editor.onDidChangeModel(() => this.cancel()), - this._editor.onDidChangeCursorSelection(() => this._updateState()) - ]; - } else { - // only insert the snippet when a session - // is already active - this._snippet.insert(template, overwriteBefore, overwriteAfter); - } + + const snippet = new SnippetSession(this._editor); + snippet.insert(template, overwriteBefore, overwriteAfter); + this._sessions.add(snippet); + if (undoStopAfter) { this._editor.getModel().pushStackElement(); } + + this._snippetListener = [ + this._editor.onDidChangeModel(() => this.cancel()), + this._editor.onDidChangeCursorSelection(() => this._updateState()) + ]; this._updateState(); } private _updateState(): void { - if (!this._snippet) { + if (this._sessions.empty) { // canceled in the meanwhile return; } - if (!this._snippet.hasPlaceholder) { + if (!this._sessions.hasPlaceholder) { // don't listen for selection changes and don't // update context keys when the snippet is plain text return this.cancel(); } - if (this._snippet.isAtFinalPlaceholder || !this._snippet.isSelectionWithinPlaceholders()) { + if (this._sessions.isAtFinalPlaceholder || !this._sessions.isSelectionWithinPlaceholders) { return this.cancel(); } this._inSnippet.set(true); - this._hasPrevTabstop.set(!this._snippet.isAtFirstPlaceholder); - this._hasNextTabstop.set(!this._snippet.isAtFinalPlaceholder); + this._hasPrevTabstop.set(!this._sessions.isAtFirstPlaceholder); + this._hasNextTabstop.set(!this._sessions.isAtFinalPlaceholder); } finish(): void { @@ -106,28 +165,21 @@ export class SnippetController2 { } cancel(): void { - if (this._snippet) { - this._inSnippet.reset(); - this._hasPrevTabstop.reset(); - this._hasNextTabstop.reset(); - dispose(this._snippetListener); - dispose(this._snippet); - this._snippet = undefined; - } + this._inSnippet.reset(); + this._hasPrevTabstop.reset(); + this._hasNextTabstop.reset(); + this._sessions.clear(); + dispose(this._snippetListener); } prev(): void { - if (this._snippet) { - this._snippet.prev(); - this._updateState(); - } + this._sessions.prev(); + this._updateState(); } next(): void { - if (this._snippet) { - this._snippet.next(); - this._updateState(); - } + this._sessions.next(); + this._updateState(); } } diff --git a/src/vs/editor/contrib/snippet/browser/snippetSession.ts b/src/vs/editor/contrib/snippet/browser/snippetSession.ts index 9450bfa8ba3..51567e97c20 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetSession.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetSession.ts @@ -130,11 +130,13 @@ export class OneSnippet { } get isAtFirstPlaceholder() { - return this._placeholderGroupsIdx === 0; + return this._placeholderGroupsIdx === 0 || this._placeholderGroups.length === 0; } get isAtFinalPlaceholder() { - if (this._placeholderGroupsIdx < 0) { + if (this._placeholderGroups.length === 0) { + return true; + } else if (this._placeholderGroupsIdx < 0) { return false; } else { return this._placeholderGroups[this._placeholderGroupsIdx][0].isFinalTabstop; @@ -196,24 +198,35 @@ export class SnippetSession { return selection; } - static makeInsertEditsAndSnippets(editor: ICommonCodeEditor, template: string, overwriteBefore: number = 0, overwriteAfter: number = 0): { edits: IIdentifiedSingleEditOperation[], snippets: OneSnippet[] } { + private readonly _editor: ICommonCodeEditor; + private _snippets: OneSnippet[] = []; + + constructor(editor: ICommonCodeEditor) { + this._editor = editor; + } + + dispose(): void { + dispose(this._snippets); + } + + insert(template: string, overwriteBefore: number = 0, overwriteAfter: number = 0): void { + + const model = this._editor.getModel(); + const edits: IIdentifiedSingleEditOperation[] = []; let delta = 0; - let edits: IIdentifiedSingleEditOperation[] = []; - let snippets: OneSnippet[] = []; - let model = editor.getModel(); // know what text the overwrite[Before|After] extensions // of the primary curser have selected because only when // secondary selections extend to the same text we can grow them - let firstBeforeText = model.getValueInRange(SnippetSession.adjustSelection(model, editor.getSelection(), overwriteBefore, 0)); - let firstAfterText = model.getValueInRange(SnippetSession.adjustSelection(model, editor.getSelection(), 0, overwriteAfter)); + let firstBeforeText = model.getValueInRange(SnippetSession.adjustSelection(model, this._editor.getSelection(), overwriteBefore, 0)); + let firstAfterText = model.getValueInRange(SnippetSession.adjustSelection(model, this._editor.getSelection(), 0, overwriteAfter)); // sort selections by their start position but remeber // the original index. that allows you to create correct // offset-based selection logic without changing the // primary selection - const indexedSelection = editor.getSelections() + const indexedSelection = this._editor.getSelections() .map((selection, idx) => ({ selection, idx })) .sort((a, b) => Range.compareRangesUsingStarts(a.selection, b.selection)); @@ -248,46 +261,18 @@ export class SnippetSession { // that ensures the primiary cursor stays primary despite not being // the one with lowest start position edits[idx] = EditOperation.replaceMove(snippetSelection, snippet.text); - snippets[idx] = new OneSnippet(editor, snippet, offset); - } - - return { edits, snippets }; - } - - private readonly _editor: ICommonCodeEditor; - private _snippets: OneSnippet[]; - - constructor(editor: ICommonCodeEditor) { - this._editor = editor; - } - - dispose(): void { - dispose(this._snippets); - } - - insert(template: string, overwriteBefore: number = 0, overwriteAfter: number = 0): void { - - const model = this._editor.getModel(); - const { edits, snippets } = SnippetSession.makeInsertEditsAndSnippets( - this._editor, template, overwriteBefore, overwriteAfter - ); - - let isNestedInsert = true; - if (!this._snippets) { - // keep snippets around - this._snippets = snippets; - isNestedInsert = false; + this._snippets[idx] = new OneSnippet(this._editor, snippet, offset); } // make insert edit and start with first selections - const newSelections = model.pushEditOperations(this._editor.getSelections(), edits, undoEdits => { - if (!isNestedInsert && this._snippets[0].hasPlaceholder) { + + this._editor.setSelections(model.pushEditOperations(this._editor.getSelections(), edits, undoEdits => { + if (this._snippets[0].hasPlaceholder) { return this._move(true); } else { return undoEdits.map(edit => Selection.fromPositions(edit.range.getEndPosition())); } - }); - this._editor.setSelections(newSelections); + })); } next(): void { @@ -322,6 +307,11 @@ export class SnippetSession { } isSelectionWithinPlaceholders(): boolean { + + if (!this.hasPlaceholder) { + return false; + } + const selections = this._editor.getSelections(); if (selections.length < this._snippets.length) { // this means we started snippet mode with N diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts index b862a3dba92..ce84d8796d8 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts @@ -148,17 +148,37 @@ suite('SnippetController2', function () { // assertContextKeys(contextKeys, false, false, false); }); - test('insert, insert nested', function () { + test('insert, nested snippet', function () { const ctrl = new SnippetController2(editor, contextKeys); ctrl.insert('${1:foobar}$0'); assertContextKeys(contextKeys, true, false, true); assertSelections(editor, new Selection(1, 1, 1, 7), new Selection(2, 5, 2, 11)); - ctrl.insert('farboo'); + ctrl.insert('farboo$1$0'); + assertSelections(editor, new Selection(1, 7, 1, 7), new Selection(2, 11, 2, 11)); + assertContextKeys(contextKeys, true, false, true); + + ctrl.next(); + assertSelections(editor, new Selection(1, 7, 1, 7), new Selection(2, 11, 2, 11)); + assertContextKeys(contextKeys, true, true, true); + + ctrl.next(); + assertSelections(editor, new Selection(1, 7, 1, 7), new Selection(2, 11, 2, 11)); + assertContextKeys(contextKeys, false, false, false); + }); + + test('insert, nested plain text', function () { + const ctrl = new SnippetController2(editor, contextKeys); + ctrl.insert('${1:foobar}$0'); assertContextKeys(contextKeys, true, false, true); + assertSelections(editor, new Selection(1, 1, 1, 7), new Selection(2, 5, 2, 11)); + + ctrl.insert('farboo'); assertSelections(editor, new Selection(1, 7, 1, 7), new Selection(2, 11, 2, 11)); + assertContextKeys(contextKeys, true, false, true); ctrl.next(); + assertSelections(editor, new Selection(1, 7, 1, 7), new Selection(2, 11, 2, 11)); assertContextKeys(contextKeys, false, false, false); }); }); diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts index 8d5af1eef2e..ce807bedad7 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts @@ -403,20 +403,5 @@ suite('SnippetSession', function () { assert.equal(model.getValue(), '@line=1function foo() {\n @line=2console.log(a);\n}'); assertSelections(editor, new Selection(1, 8, 1, 8), new Selection(2, 12, 2, 12)); }); - - test('snippet, insert-nested', function () { - const session = new SnippetSession(editor); - session.insert('foo$1foo$0'); - - assertSelections(editor, new Selection(1, 4, 1, 4), new Selection(2, 8, 2, 8)); - session.insert('bar'); - assert.ok(session.isSelectionWithinPlaceholders()); - assertSelections(editor, new Selection(1, 7, 1, 7), new Selection(2, 11, 2, 11)); - - session.next(); - assertSelections(editor, new Selection(1, 10, 1, 10), new Selection(2, 14, 2, 14)); - assert.ok(session.isAtFinalPlaceholder); - }); - }); -- GitLab From 90a68e55391afc18cc1caffef776280983e14350 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 26 May 2017 17:32:27 +0200 Subject: [PATCH 0218/1347] make SnippetSession single insert again, #24855 --- .../snippet/browser/snippetController2.ts | 4 +- .../contrib/snippet/browser/snippetSession.ts | 20 +++-- .../test/browser/snippetSession.test.ts | 80 +++++++++---------- 3 files changed, 55 insertions(+), 49 deletions(-) diff --git a/src/vs/editor/contrib/snippet/browser/snippetController2.ts b/src/vs/editor/contrib/snippet/browser/snippetController2.ts index c35e9766a49..fbf4764ba64 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetController2.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetController2.ts @@ -122,9 +122,9 @@ export class SnippetController2 { this._editor.getModel().pushStackElement(); } - const snippet = new SnippetSession(this._editor); - snippet.insert(template, overwriteBefore, overwriteAfter); + const snippet = new SnippetSession(this._editor, template, overwriteBefore, overwriteAfter); this._sessions.add(snippet); + snippet.insert(); if (undoStopAfter) { this._editor.getModel().pushStackElement(); diff --git a/src/vs/editor/contrib/snippet/browser/snippetSession.ts b/src/vs/editor/contrib/snippet/browser/snippetSession.ts index 51567e97c20..de1eea466b9 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetSession.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetSession.ts @@ -199,17 +199,23 @@ export class SnippetSession { } private readonly _editor: ICommonCodeEditor; + private readonly _template: string; + private readonly _overwriteBefore: number; + private readonly _overwriteAfter: number; private _snippets: OneSnippet[] = []; - constructor(editor: ICommonCodeEditor) { + constructor(editor: ICommonCodeEditor, template: string, overwriteBefore: number = 0, overwriteAfter: number = 0) { this._editor = editor; + this._template = template; + this._overwriteBefore = overwriteBefore; + this._overwriteAfter = overwriteAfter; } dispose(): void { dispose(this._snippets); } - insert(template: string, overwriteBefore: number = 0, overwriteAfter: number = 0): void { + insert(): void { const model = this._editor.getModel(); const edits: IIdentifiedSingleEditOperation[] = []; @@ -219,8 +225,8 @@ export class SnippetSession { // know what text the overwrite[Before|After] extensions // of the primary curser have selected because only when // secondary selections extend to the same text we can grow them - let firstBeforeText = model.getValueInRange(SnippetSession.adjustSelection(model, this._editor.getSelection(), overwriteBefore, 0)); - let firstAfterText = model.getValueInRange(SnippetSession.adjustSelection(model, this._editor.getSelection(), 0, overwriteAfter)); + let firstBeforeText = model.getValueInRange(SnippetSession.adjustSelection(model, this._editor.getSelection(), this._overwriteBefore, 0)); + let firstAfterText = model.getValueInRange(SnippetSession.adjustSelection(model, this._editor.getSelection(), 0, this._overwriteAfter)); // sort selections by their start position but remeber // the original index. that allows you to create correct @@ -234,8 +240,8 @@ export class SnippetSession { // extend selection with the `overwriteBefore` and `overwriteAfter` and then // compare if this matches the extensions of the primary selection - let extensionBefore = SnippetSession.adjustSelection(model, selection, overwriteBefore, 0); - let extensionAfter = SnippetSession.adjustSelection(model, selection, 0, overwriteAfter); + let extensionBefore = SnippetSession.adjustSelection(model, selection, this._overwriteBefore, 0); + let extensionAfter = SnippetSession.adjustSelection(model, selection, 0, this._overwriteAfter); if (firstBeforeText !== model.getValueInRange(extensionBefore)) { extensionBefore = selection; } @@ -251,7 +257,7 @@ export class SnippetSession { // adjust the template string to match the indentation and // whitespace rules of this insert location (can be different for each cursor) const start = snippetSelection.getStartPosition(); - const adjustedTemplate = SnippetSession.adjustWhitespace(model, start, template); + const adjustedTemplate = SnippetSession.adjustWhitespace(model, start, this._template); const snippet = SnippetParser.parse(adjustedTemplate).resolveVariables(new EditorSnippetVariableResolver(model, snippetSelection)); const offset = model.getOffsetAt(start) + delta; diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts index ce807bedad7..5d5db85fb93 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts @@ -67,8 +67,8 @@ suite('SnippetSession', function () { }); test('text edits & selection', function () { - const session = new SnippetSession(editor); - session.insert('foo${1:bar}foo$0'); + const session = new SnippetSession(editor, 'foo${1:bar}foo$0'); + session.insert(); assert.equal(editor.getModel().getValue(), 'foobarfoofunction foo() {\n foobarfooconsole.log(a);\n}'); assertSelections(editor, new Selection(1, 4, 1, 7), new Selection(2, 8, 2, 11)); @@ -78,17 +78,17 @@ suite('SnippetSession', function () { test('text edit with reversed selection', function () { - const session = new SnippetSession(editor); + const session = new SnippetSession(editor, '${1:bar}$0'); editor.setSelections([new Selection(2, 5, 2, 5), new Selection(1, 1, 1, 1)]); - session.insert('${1:bar}$0'); + session.insert(); assert.equal(model.getValue(), 'barfunction foo() {\n barconsole.log(a);\n}'); assertSelections(editor, new Selection(2, 5, 2, 8), new Selection(1, 1, 1, 4)); }); test('snippets, repeated tabstops', function () { - const session = new SnippetSession(editor); - session.insert('${1:abc}foo${1:abc}$0'); + const session = new SnippetSession(editor, '${1:abc}foo${1:abc}$0'); + session.insert(); assertSelections(editor, new Selection(1, 1, 1, 4), new Selection(1, 7, 1, 10), new Selection(2, 5, 2, 8), new Selection(2, 11, 2, 14), @@ -101,16 +101,16 @@ suite('SnippetSession', function () { }); test('snippets, just text', function () { - const session = new SnippetSession(editor); - session.insert('foobar'); + const session = new SnippetSession(editor, 'foobar'); + session.insert(); assert.equal(model.getValue(), 'foobarfunction foo() {\n foobarconsole.log(a);\n}'); assertSelections(editor, new Selection(1, 7, 1, 7), new Selection(2, 11, 2, 11)); }); test('snippets, selections and new text with newlines', () => { - const session = new SnippetSession(editor); - session.insert('foo\n\t${1:bar}\n$0'); + const session = new SnippetSession(editor, 'foo\n\t${1:bar}\n$0'); + session.insert(); assert.equal(editor.getModel().getValue(), 'foo\n bar\nfunction foo() {\n foo\n bar\n console.log(a);\n}'); @@ -122,8 +122,8 @@ suite('SnippetSession', function () { test('snippets, selections -> next/prev', () => { - const session = new SnippetSession(editor); - session.insert('f$1oo${2:bar}foo$0'); + const session = new SnippetSession(editor, 'f$1oo${2:bar}foo$0'); + session.insert(); // @ $2 assertSelections(editor, new Selection(1, 2, 1, 2), new Selection(2, 6, 2, 6)); @@ -142,8 +142,8 @@ suite('SnippetSession', function () { }); test('snippets, selections & typing', function () { - const session = new SnippetSession(editor); - session.insert('f${1:oo}_$2_$0'); + const session = new SnippetSession(editor, 'f${1:oo}_$2_$0'); + session.insert(); editor.trigger('test', 'type', { text: 'X' }); session.next(); @@ -167,7 +167,7 @@ suite('SnippetSession', function () { model.setValue('foo_bar_foo'); editor.setSelections([new Selection(1, 1, 1, 4), new Selection(1, 9, 1, 12)]); - new SnippetSession(editor).insert('x$0'); + new SnippetSession(editor, 'x$0').insert(); assert.equal(model.getValue(), 'x_bar_x'); assertSelections(editor, new Selection(1, 2, 1, 2), new Selection(1, 8, 1, 8)); }); @@ -176,7 +176,7 @@ suite('SnippetSession', function () { model.setValue('foo_bar_foo'); editor.setSelections([new Selection(1, 1, 1, 4), new Selection(1, 9, 1, 12)]); - new SnippetSession(editor).insert('LONGER$0'); + new SnippetSession(editor, 'LONGER$0').insert(); assert.equal(model.getValue(), 'LONGER_bar_LONGER'); assertSelections(editor, new Selection(1, 7, 1, 7), new Selection(1, 18, 1, 18)); }); @@ -184,8 +184,8 @@ suite('SnippetSession', function () { test('snippets, don\'t grow final tabstop', function () { model.setValue('foo_zzz_foo'); editor.setSelection(new Selection(1, 5, 1, 8)); - const session = new SnippetSession(editor); - session.insert('$1bar$0'); + const session = new SnippetSession(editor, '$1bar$0'); + session.insert(); assertSelections(editor, new Selection(1, 5, 1, 5)); editor.trigger('test', 'type', { text: 'foo-' }); @@ -204,8 +204,8 @@ suite('SnippetSession', function () { test('snippets, don\'t merge touching tabstops 1/2', function () { - const session = new SnippetSession(editor); - session.insert('$1$2$3$0'); + const session = new SnippetSession(editor, '$1$2$3$0'); + session.insert(); assertSelections(editor, new Selection(1, 1, 1, 1), new Selection(2, 5, 2, 5)); session.next(); @@ -242,8 +242,8 @@ suite('SnippetSession', function () { }); test('snippets, don\'t merge touching tabstops 2/2', function () { - const session = new SnippetSession(editor); - session.insert('$1$2$3$0'); + const session = new SnippetSession(editor, '$1$2$3$0'); + session.insert(); assertSelections(editor, new Selection(1, 1, 1, 1), new Selection(2, 5, 2, 5)); editor.trigger('test', 'type', { text: '111' }); @@ -261,8 +261,8 @@ suite('SnippetSession', function () { }); test('snippets, gracefully move over final tabstop', function () { - const session = new SnippetSession(editor); - session.insert('${1}bar$0'); + const session = new SnippetSession(editor, '${1}bar$0'); + session.insert(); assert.equal(session.isAtFinalPlaceholder, false); assertSelections(editor, new Selection(1, 1, 1, 1), new Selection(2, 5, 2, 5)); @@ -277,8 +277,8 @@ suite('SnippetSession', function () { }); test('snippets, overwriting nested placeholder', function () { - const session = new SnippetSession(editor); - session.insert('log(${1:"$2"});$0'); + const session = new SnippetSession(editor, 'log(${1:"$2"});$0'); + session.insert(); assertSelections(editor, new Selection(1, 5, 1, 7), new Selection(2, 9, 2, 11)); editor.trigger('test', 'type', { text: 'XXX' }); @@ -294,8 +294,8 @@ suite('SnippetSession', function () { }); test('snippets, selections and snippet ranges', function () { - const session = new SnippetSession(editor); - session.insert('${1:foo}farboo${2:bar}$0'); + const session = new SnippetSession(editor, '${1:foo}farboo${2:bar}$0'); + session.insert(); assert.equal(model.getValue(), 'foofarboobarfunction foo() {\n foofarboobarconsole.log(a);\n}'); assertSelections(editor, new Selection(1, 1, 1, 4), new Selection(2, 5, 2, 8)); @@ -330,13 +330,13 @@ suite('SnippetSession', function () { model.setValue(''); editor.setSelection(new Selection(1, 1, 1, 1)); - const first = new SnippetSession(editor); - first.insert('foo${2:bar}foo$0'); + const first = new SnippetSession(editor, 'foo${2:bar}foo$0'); + first.insert(); assert.equal(model.getValue(), 'foobarfoo'); assertSelections(editor, new Selection(1, 4, 1, 7)); - const second = new SnippetSession(editor); - second.insert('ba${1:zzzz}$0'); + const second = new SnippetSession(editor, 'ba${1:zzzz}$0'); + second.insert(); assert.equal(model.getValue(), 'foobazzzzfoo'); assertSelections(editor, new Selection(1, 6, 1, 10)); @@ -351,8 +351,8 @@ suite('SnippetSession', function () { test('snippets, typing at final tabstop', function () { - const session = new SnippetSession(editor); - session.insert('farboo$0'); + const session = new SnippetSession(editor, 'farboo$0'); + session.insert(); assert.equal(session.isAtFinalPlaceholder, true); assert.equal(session.isSelectionWithinPlaceholders(), false); @@ -363,8 +363,8 @@ suite('SnippetSession', function () { test('snippets, typing at beginning', function () { editor.setSelection(new Selection(1, 2, 1, 2)); - const session = new SnippetSession(editor); - session.insert('farboo$0'); + const session = new SnippetSession(editor, 'farboo$0'); + session.insert(); editor.setSelection(new Selection(1, 2, 1, 2)); assert.equal(session.isSelectionWithinPlaceholders(), false); @@ -381,8 +381,8 @@ suite('SnippetSession', function () { test('snippets, typing with nested placeholder', function () { editor.setSelection(new Selection(1, 1, 1, 1)); - const session = new SnippetSession(editor); - session.insert('This ${1:is ${2:nested}}.$0'); + const session = new SnippetSession(editor, 'This ${1:is ${2:nested}}.$0'); + session.insert(); assertSelections(editor, new Selection(1, 6, 1, 15)); session.next(); @@ -397,8 +397,8 @@ suite('SnippetSession', function () { }); test('snippets, snippet with variables', function () { - const session = new SnippetSession(editor); - session.insert('@line=$TM_LINE_NUMBER$0'); + const session = new SnippetSession(editor, '@line=$TM_LINE_NUMBER$0'); + session.insert(); assert.equal(model.getValue(), '@line=1function foo() {\n @line=2console.log(a);\n}'); assertSelections(editor, new Selection(1, 8, 1, 8), new Selection(2, 12, 2, 12)); -- GitLab From f8a959aec0cfe896c0e3bf32bf81a1592524d8b3 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 26 May 2017 18:47:47 +0200 Subject: [PATCH 0219/1347] make final tabstops of nested snippets normal tabstop, #24855 --- .../snippet/browser/snippetController2.ts | 10 +++---- .../contrib/snippet/browser/snippetSession.ts | 29 +++++++++++-------- .../test/browser/snippetController2.test.ts | 4 +-- .../test/browser/snippetSession.test.ts | 22 +++++++------- 4 files changed, 34 insertions(+), 31 deletions(-) diff --git a/src/vs/editor/contrib/snippet/browser/snippetController2.ts b/src/vs/editor/contrib/snippet/browser/snippetController2.ts index fbf4764ba64..4c210d851ac 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetController2.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetController2.ts @@ -35,13 +35,11 @@ class SnippetSessions { } get isAtFirstPlaceholder(): boolean { - // return !this.empty && this._stack[0].isAtFirstPlaceholder; return this._stack.every(s => s.isAtFirstPlaceholder); } get isAtFinalPlaceholder(): boolean { - // return !this.empty && this._stack[0].isAtFinalPlaceholder; - return this._stack.every(s => s.isAtFinalPlaceholder); + return !this.empty && this._stack[0].isAtLastPlaceholder; } get isSelectionWithinPlaceholders(): boolean { @@ -61,7 +59,7 @@ class SnippetSessions { next(): void { for (let i = this._stack.length - 1; i >= 0; i--) { const snippet = this._stack[i]; - if (!snippet.isAtFinalPlaceholder) { + if (!snippet.isAtLastPlaceholder) { snippet.next(); break; } @@ -123,8 +121,8 @@ export class SnippetController2 { } const snippet = new SnippetSession(this._editor, template, overwriteBefore, overwriteAfter); - this._sessions.add(snippet); - snippet.insert(); + const newLen = this._sessions.add(snippet); + snippet.insert(newLen > 1); if (undoStopAfter) { this._editor.getModel().pushStackElement(); diff --git a/src/vs/editor/contrib/snippet/browser/snippetSession.ts b/src/vs/editor/contrib/snippet/browser/snippetSession.ts index de1eea466b9..c4fcdaa3e41 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetSession.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetSession.ts @@ -130,17 +130,11 @@ export class OneSnippet { } get isAtFirstPlaceholder() { - return this._placeholderGroupsIdx === 0 || this._placeholderGroups.length === 0; + return this._placeholderGroupsIdx <= 0 || this._placeholderGroups.length === 0; } - get isAtFinalPlaceholder() { - if (this._placeholderGroups.length === 0) { - return true; - } else if (this._placeholderGroupsIdx < 0) { - return false; - } else { - return this._placeholderGroups[this._placeholderGroupsIdx][0].isFinalTabstop; - } + get isAtLastPlaceholder() { + return this._placeholderGroupsIdx === this._placeholderGroups.length - 1; } get hasPlaceholder() { @@ -215,7 +209,7 @@ export class SnippetSession { dispose(this._snippets); } - insert(): void { + insert(ignoreFinalTabstops: boolean = false): void { const model = this._editor.getModel(); const edits: IIdentifiedSingleEditOperation[] = []; @@ -260,6 +254,17 @@ export class SnippetSession { const adjustedTemplate = SnippetSession.adjustWhitespace(model, start, this._template); const snippet = SnippetParser.parse(adjustedTemplate).resolveVariables(new EditorSnippetVariableResolver(model, snippetSelection)); + + // rewrite final-tabstop to some other placeholder because this + // snippet sits inside another snippet + if (ignoreFinalTabstops) { + for (const placeholder of snippet.placeholders) { + if (placeholder.isFinalTabstop) { + placeholder.index = String(snippet.placeholders.length); + } + } + } + const offset = model.getOffsetAt(start) + delta; delta += snippet.text.length - model.getValueLengthInRange(snippetSelection); @@ -304,8 +309,8 @@ export class SnippetSession { return this._snippets[0].isAtFirstPlaceholder; } - get isAtFinalPlaceholder() { - return this._snippets[0].isAtFinalPlaceholder; + get isAtLastPlaceholder() { + return this._snippets[0].isAtLastPlaceholder; } get hasPlaceholder() { diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts index ce84d8796d8..7a485ac4f6b 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts @@ -154,8 +154,8 @@ suite('SnippetController2', function () { assertContextKeys(contextKeys, true, false, true); assertSelections(editor, new Selection(1, 1, 1, 7), new Selection(2, 5, 2, 11)); - ctrl.insert('farboo$1$0'); - assertSelections(editor, new Selection(1, 7, 1, 7), new Selection(2, 11, 2, 11)); + ctrl.insert('far$1boo$0'); + assertSelections(editor, new Selection(1, 4, 1, 4), new Selection(2, 8, 2, 8)); assertContextKeys(contextKeys, true, false, true); ctrl.next(); diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts index 5d5db85fb93..4691eaad476 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts @@ -257,22 +257,22 @@ suite('SnippetSession', function () { editor.trigger('test', 'type', { text: '333' }); session.next(); - assert.equal(session.isAtFinalPlaceholder, true); + assert.equal(session.isAtLastPlaceholder, true); }); test('snippets, gracefully move over final tabstop', function () { const session = new SnippetSession(editor, '${1}bar$0'); session.insert(); - assert.equal(session.isAtFinalPlaceholder, false); + assert.equal(session.isAtLastPlaceholder, false); assertSelections(editor, new Selection(1, 1, 1, 1), new Selection(2, 5, 2, 5)); session.next(); - assert.equal(session.isAtFinalPlaceholder, true); + assert.equal(session.isAtLastPlaceholder, true); assertSelections(editor, new Selection(1, 4, 1, 4), new Selection(2, 8, 2, 8)); session.next(); - assert.equal(session.isAtFinalPlaceholder, true); + assert.equal(session.isAtLastPlaceholder, true); assertSelections(editor, new Selection(1, 4, 1, 4), new Selection(2, 8, 2, 8)); }); @@ -285,11 +285,11 @@ suite('SnippetSession', function () { assert.equal(model.getValue(), 'log(XXX);function foo() {\n log(XXX);console.log(a);\n}'); session.next(); - assert.equal(session.isAtFinalPlaceholder, false); + assert.equal(session.isAtLastPlaceholder, false); // assertSelections(editor, new Selection(1, 7, 1, 7), new Selection(2, 11, 2, 11)); session.next(); - assert.equal(session.isAtFinalPlaceholder, true); + assert.equal(session.isAtLastPlaceholder, true); assertSelections(editor, new Selection(1, 10, 1, 10), new Selection(2, 14, 2, 14)); }); @@ -321,7 +321,7 @@ suite('SnippetSession', function () { // reset selection to placeholder session.next(); assert.equal(session.isSelectionWithinPlaceholders(), true); - assert.equal(session.isAtFinalPlaceholder, true); + assert.equal(session.isAtLastPlaceholder, true); assertSelections(editor, new Selection(1, 13, 1, 13), new Selection(2, 17, 2, 17)); }); @@ -341,11 +341,11 @@ suite('SnippetSession', function () { assertSelections(editor, new Selection(1, 6, 1, 10)); second.next(); - assert.equal(second.isAtFinalPlaceholder, true); + assert.equal(second.isAtLastPlaceholder, true); assertSelections(editor, new Selection(1, 10, 1, 10)); first.next(); - assert.equal(first.isAtFinalPlaceholder, true); + assert.equal(first.isAtLastPlaceholder, true); assertSelections(editor, new Selection(1, 13, 1, 13)); }); @@ -353,7 +353,7 @@ suite('SnippetSession', function () { const session = new SnippetSession(editor, 'farboo$0'); session.insert(); - assert.equal(session.isAtFinalPlaceholder, true); + assert.equal(session.isAtLastPlaceholder, true); assert.equal(session.isSelectionWithinPlaceholders(), false); editor.trigger('test', 'type', { text: 'XXX' }); @@ -368,7 +368,7 @@ suite('SnippetSession', function () { editor.setSelection(new Selection(1, 2, 1, 2)); assert.equal(session.isSelectionWithinPlaceholders(), false); - assert.equal(session.isAtFinalPlaceholder, true); + assert.equal(session.isAtLastPlaceholder, true); editor.trigger('test', 'type', { text: 'XXX' }); assert.equal(model.getLineContent(1), 'fXXXfarboounction foo() {'); -- GitLab From 3e7152fb4d0e69e539329c729f54868f2d605cfd Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 26 May 2017 18:58:47 +0200 Subject: [PATCH 0220/1347] snippets - remove unused css --- src/vs/editor/contrib/snippet/browser/snippetSession.css | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/vs/editor/contrib/snippet/browser/snippetSession.css b/src/vs/editor/contrib/snippet/browser/snippetSession.css index 6f839f10d22..b6c7d72adda 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetSession.css +++ b/src/vs/editor/contrib/snippet/browser/snippetSession.css @@ -3,10 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -.monaco-editor.vs .new-snippet { background-color: rgba(10, 50, 150, 0.1); } -.monaco-editor.vs-dark .new-snippet { background-color: rgba(100, 105, 110, 0.1); } -.monaco-editor.hc-black .new-snippet { background-color: rgba(100, 105, 110, 0.1); } - .monaco-editor.vs .snippet-placeholder { background-color: rgba(10, 50, 100, 0.1); } .monaco-editor.vs-dark .snippet-placeholder { background-color: rgba(124, 124, 124, 0.1); } .monaco-editor.hc-black .snippet-placeholder { background-color: rgba(124, 124, 124, 0.1); } -- GitLab From 0ece9b10815b7014ebcba4838f10c4ace2522eb1 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Fri, 26 May 2017 12:03:17 -0700 Subject: [PATCH 0221/1347] Update markdown extension contributes key names --- extensions/markdown/src/extension.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/extensions/markdown/src/extension.ts b/extensions/markdown/src/extension.ts index 8e459df89a2..4deb344b9f2 100644 --- a/extensions/markdown/src/extension.ts +++ b/extensions/markdown/src/extension.ts @@ -61,7 +61,7 @@ export function activate(context: vscode.ExtensionContext) { continue; } - let styles = contributes['markdown.preview'] && contributes['markdown.preview'].styles; + let styles = contributes['markdown.previewStyles']; if (styles) { if (!Array.isArray(styles)) { styles = [styles]; @@ -75,7 +75,7 @@ export function activate(context: vscode.ExtensionContext) { } } - let scripts = contributes['markdown.preview'] && contributes['markdown.preview'].scripts; + let scripts = contributes['markdown.previewScripts']; if (scripts) { if (!Array.isArray(scripts)) { scripts = [scripts]; -- GitLab From f7288dfcb9eda68e7105e0e683cc52e1ddf55d10 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Fri, 26 May 2017 23:04:48 +0200 Subject: [PATCH 0222/1347] Ugly flicker upon first startup. Fixes #25448 --- src/vs/workbench/electron-browser/bootstrap/index.html | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/electron-browser/bootstrap/index.html b/src/vs/workbench/electron-browser/bootstrap/index.html index 018512e1164..1474a70e097 100644 --- a/src/vs/workbench/electron-browser/bootstrap/index.html +++ b/src/vs/workbench/electron-browser/bootstrap/index.html @@ -30,8 +30,9 @@ if (!backgroundColor) { backgroundColor = baseTheme === 'hc-black' ? '#000000' : (baseTheme === 'vs' ? '#FFFFFF' : '#1E1E1E'); } + let foregroundColor = baseTheme === 'hc-black' ? '#FFFFFF' : (baseTheme === 'vs' ? '#6C6C6C' : '#CCCCCC'); let style = document.createElement('style'); - style.innerHTML = '.monaco-shell { background-color:' + backgroundColor + '; }'; + style.innerHTML = '.monaco-shell { background-color:' + backgroundColor + '; color:' + foregroundColor + '; }'; document.head.appendChild(style); } catch (error) { -- GitLab From 5a83b55b70480eac2bf5d8fca4d628645bd48e02 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Fri, 26 May 2017 13:56:26 -0700 Subject: [PATCH 0223/1347] Fix a few potential issues for tsc task provider --- extensions/typescript/src/features/taskProvider.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/extensions/typescript/src/features/taskProvider.ts b/extensions/typescript/src/features/taskProvider.ts index ba53903e447..de8394594c9 100644 --- a/extensions/typescript/src/features/taskProvider.ts +++ b/extensions/typescript/src/features/taskProvider.ts @@ -45,21 +45,21 @@ export default class TypeScriptTaskProvider implements vscode.TaskProvider { return projects.map(configFile => { const configFileName = path.relative(rootPath, configFile); - const buildTask = new vscode.ShellTask(`tsc: build ${configFileName}`, `${command} -p ${configFile}`, '$tsc'); + const buildTask = new vscode.ShellTask(`tsc: build ${configFileName}`, `${command} -p "${configFile}"`, '$tsc'); buildTask.group = vscode.TaskGroup.Build; return buildTask; }); } private async getAllTsConfigs(token: vscode.CancellationToken): Promise { - const out: string[] = []; + const out = new Set(); const configs = (await this.getTsConfigForActiveFile(token)).concat(await this.getTsConfigsInWorkspace()); for (const config of configs) { if (await exists(config)) { - out.push(config); + out.add(config); } } - return out; + return Array.from(out); } private async getTsConfigForActiveFile(token: vscode.CancellationToken): Promise { -- GitLab From c9a2a5be88f67f0d1a82c5a53cf36891553a9dee Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Fri, 26 May 2017 14:24:15 -0700 Subject: [PATCH 0224/1347] Allow tsc tasks to be disabled using settings. Fixes #27312 --- extensions/typescript/package.json | 9 +++++ extensions/typescript/package.nls.json | 3 +- .../typescript/src/features/taskProvider.ts | 40 ++++++++++++++++++- extensions/typescript/src/typescriptMain.ts | 4 +- 4 files changed, 52 insertions(+), 4 deletions(-) diff --git a/extensions/typescript/package.json b/extensions/typescript/package.json index b039fac9631..cff9784cabe 100644 --- a/extensions/typescript/package.json +++ b/extensions/typescript/package.json @@ -315,6 +315,15 @@ "type": "boolean", "default": true, "description": "%javascript.nameSuggestions%" + }, + "typescript.tsc.autoDetect": { + "type": "string", + "default": "on", + "enum": [ + "on", + "off" + ], + "description": "%typescript.tsc.autoDetect%" } } }, diff --git a/extensions/typescript/package.nls.json b/extensions/typescript/package.nls.json index 821257b38a1..0679841532d 100644 --- a/extensions/typescript/package.nls.json +++ b/extensions/typescript/package.nls.json @@ -37,5 +37,6 @@ "jsDocCompletion.enabled": "Enable/disable auto JSDoc comments", "javascript.implicitProjectConfig.checkJs": "Enable/disable semantic checking of JavaScript files. Existing jsconfig.json or tsconfig.json files override this setting. Requires TypeScript >=2.3.1.", "typescript.check.npmIsInstalled": "Check if NPM is installed for automatic typings acquisition", - "javascript.nameSuggestions": "Enable/disable including unique names from the file in JavaScript suggestion lists." + "javascript.nameSuggestions": "Enable/disable including unique names from the file in JavaScript suggestion lists.", + "typescript.tsc.autoDetect": "Controls whether auto detection of tsc tasks is on or off." } diff --git a/extensions/typescript/src/features/taskProvider.ts b/extensions/typescript/src/features/taskProvider.ts index de8394594c9..4d50b233294 100644 --- a/extensions/typescript/src/features/taskProvider.ts +++ b/extensions/typescript/src/features/taskProvider.ts @@ -21,7 +21,10 @@ const exists = (file: string): Promise => }); }); -export default class TypeScriptTaskProvider implements vscode.TaskProvider { +/** + * Provides tasks for building `tsconfig.json` files in a project. + */ +class TscTaskProvider implements vscode.TaskProvider { private readonly tsconfigProvider: TsConfigProvider; public constructor( @@ -116,4 +119,39 @@ export default class TypeScriptTaskProvider implements vscode.TaskProvider { } return null; } +} + +type AutoDetect = 'on' | 'off'; + +/** + * Manages registrations of TypeScript task provides with VScode. + */ +export default class TypeScriptTaskProviderManager { + private taskProviderSub: vscode.Disposable | undefined = undefined; + private readonly disposables: vscode.Disposable[] = []; + + constructor( + private readonly lazyClient: () => TypeScriptServiceClient + ) { + vscode.workspace.onDidChangeConfiguration(this.onConfigurationChanged, this, this.disposables); + this.onConfigurationChanged(); + } + + dispose() { + if (this.taskProviderSub) { + this.taskProviderSub.dispose(); + this.taskProviderSub = undefined; + } + this.disposables.forEach(x => x.dispose()); + } + + private onConfigurationChanged() { + let autoDetect = vscode.workspace.getConfiguration('typescript.tsc').get('autoDetect'); + if (this.taskProviderSub && autoDetect === 'off') { + this.taskProviderSub.dispose(); + this.taskProviderSub = undefined; + } else if (!this.taskProviderSub && autoDetect === 'on') { + this.taskProviderSub = vscode.workspace.registerTaskProvider(new TscTaskProvider(this.lazyClient)); + } + } } \ No newline at end of file diff --git a/extensions/typescript/src/typescriptMain.ts b/extensions/typescript/src/typescriptMain.ts index 07a666936b9..9c207250932 100644 --- a/extensions/typescript/src/typescriptMain.ts +++ b/extensions/typescript/src/typescriptMain.ts @@ -41,7 +41,7 @@ import CodeActionProvider from './features/codeActionProvider'; import ReferenceCodeLensProvider from './features/referencesCodeLensProvider'; import { JsDocCompletionProvider, TryCompleteJsDocCommand } from './features/jsDocCompletionProvider'; import { DirectiveCommentCompletionProvider } from './features/directiveCommentCompletionProvider'; -import TypeScriptTaskProvider from './features/taskProvider'; +import TypeScriptTaskProviderManager from './features/taskProvider'; import ImplementationCodeLensProvider from './features/implementationsCodeLensProvider'; @@ -131,7 +131,7 @@ export function activate(context: ExtensionContext): void { lazyClientHost().serviceClient.restartTsServer(); })); - context.subscriptions.push(workspace.registerTaskProvider(new TypeScriptTaskProvider(() => lazyClientHost().serviceClient))); + context.subscriptions.push(new TypeScriptTaskProviderManager(() => lazyClientHost().serviceClient)); const goToProjectConfig = (isTypeScript: boolean) => { const editor = window.activeTextEditor; -- GitLab From 23c6f80062af89e8fba66d10e43eccd9d018c3f3 Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Fri, 26 May 2017 14:47:57 -0700 Subject: [PATCH 0225/1347] Fix #26771 - use focus tracker to set search focus context keys --- src/vs/workbench/parts/search/browser/searchViewlet.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/search/browser/searchViewlet.ts b/src/vs/workbench/parts/search/browser/searchViewlet.ts index 04837eb7f6e..97f51caa16c 100644 --- a/src/vs/workbench/parts/search/browser/searchViewlet.ts +++ b/src/vs/workbench/parts/search/browser/searchViewlet.ts @@ -498,7 +498,7 @@ export class SearchViewlet extends Viewlet { } })); - this.toUnbind.push(this.tree.addListener('focus', (event: any) => { + this.toUnbind.push(this.tree.onDOMFocus(e => { const focus = this.tree.getFocus(); this.firstMatchFocussed.set(this.tree.getNavigator().first() === this.tree.getFocus()); this.fileMatchOrMatchFocussed.set(true); -- GitLab From 5b09beb12bcd95f884ec43aaf1f45efcf9bfb7b5 Mon Sep 17 00:00:00 2001 From: kieferrm Date: Fri, 26 May 2017 15:03:50 -0700 Subject: [PATCH 0226/1347] Change default settings. Fixes #26893. --- src/vs/editor/common/config/editorOptions.ts | 8 ++++---- src/vs/workbench/electron-browser/main.contribution.ts | 2 +- .../electron-browser/extensions.contribution.ts | 2 +- .../themes/electron-browser/workbenchThemeService.ts | 3 ++- 4 files changed, 8 insertions(+), 7 deletions(-) diff --git a/src/vs/editor/common/config/editorOptions.ts b/src/vs/editor/common/config/editorOptions.ts index 720302d227e..c6997e43114 100644 --- a/src/vs/editor/common/config/editorOptions.ts +++ b/src/vs/editor/common/config/editorOptions.ts @@ -2053,7 +2053,7 @@ export const EDITOR_DEFAULTS: IValidatedEditorOptions = { wordWrapBreakAfterCharacters: ' \t})]?|&,;¢°′″‰℃ã€ã€‚。、¢,.:;?ï¼ï¼…・・ã‚ゞヽヾーァィゥェォッャュョヮヵヶããƒã…ã‡ã‰ã£ã‚ƒã‚…ょゎゕゖㇰㇱㇲㇳㇴㇵㇶㇷㇸㇹㇺㇻㇼㇽㇾㇿ々〻ァィゥェォャュョッー’â€ã€‰ã€‹ã€ã€ã€‘〕)]ï½ï½£', wordWrapBreakObtrusiveCharacters: '.', autoClosingBrackets: true, - dragAndDrop: false, + dragAndDrop: true, emptySelectionClipboard: true, useTabStops: true, multicursorModifier: 'altKey', @@ -2081,7 +2081,7 @@ export const EDITOR_DEFAULTS: IValidatedEditorOptions = { renderWhitespace: 'none', renderControlCharacters: false, fontLigatures: false, - renderIndentGuides: false, + renderIndentGuides: true, renderLineHighlight: 'line', scrollbar: { vertical: ScrollbarVisibility.Auto, @@ -2098,7 +2098,7 @@ export const EDITOR_DEFAULTS: IValidatedEditorOptions = { mouseWheelScrollSensitivity: 1, }, minimap: { - enabled: false, + enabled: true, renderCharacters: true, maxColumn: 120 }, @@ -2114,7 +2114,7 @@ export const EDITOR_DEFAULTS: IValidatedEditorOptions = { parameterHints: true, iconsInSuggestions: true, formatOnType: false, - formatOnPaste: false, + formatOnPaste: true, suggestOnTriggerCharacters: true, acceptSuggestionOnEnter: 'on', acceptSuggestionOnCommitCharacter: true, diff --git a/src/vs/workbench/electron-browser/main.contribution.ts b/src/vs/workbench/electron-browser/main.contribution.ts index 46b0bce9b76..53ab7b01760 100644 --- a/src/vs/workbench/electron-browser/main.contribution.ts +++ b/src/vs/workbench/electron-browser/main.contribution.ts @@ -182,7 +182,7 @@ let properties: { [path: string]: IJSONSchema; } = { nls.localize({ comment: ['This is the description for a setting. Values surrounded by single quotes are not to be translated.'], key: 'window.openFilesInNewWindow.off' }, "Files will open in the window with the files' folder open or the last active window"), nls.localize({ comment: ['This is the description for a setting. Values surrounded by single quotes are not to be translated.'], key: 'window.openFilesInNewWindow.default' }, "Files will open in the window with the files' folder open or the last active window unless opened via the dock or from finder (macOS only)") ], - 'default': 'default', + 'default': 'off', 'description': nls.localize('openFilesInNewWindow', `Controls if files should open in a new window. diff --git a/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.ts b/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.ts index 7e6ec97a78e..74161d1c27c 100644 --- a/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.ts +++ b/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.ts @@ -171,7 +171,7 @@ Registry.as(ConfigurationExtensions.Configuration) 'extensions.autoUpdate': { type: 'boolean', description: localize('extensionsAutoUpdate', "Automatically update extensions"), - default: false + default: true }, 'extensions.ignoreRecommendations': { type: 'boolean', diff --git a/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.ts b/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.ts index 6e41871b060..4125a7a1ea8 100644 --- a/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.ts +++ b/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.ts @@ -51,6 +51,7 @@ const PERSISTED_THEME_STORAGE_KEY = 'colorThemeData'; const defaultThemeExtensionId = 'vscode-theme-defaults'; const oldDefaultThemeExtensionId = 'vscode-theme-colorful-defaults'; +const DEFAULT_ICON_THEME_SETTING_VALUE = 'vs-seti'; const fileIconsEnabledClass = 'file-icons-enabled'; const themingRegistry = Registry.as(ThemingExtensions.ThemingContribution); @@ -962,7 +963,7 @@ const colorThemeSettingSchema: IJSONSchema = { }; const iconThemeSettingSchema: IJSONSchema = { type: ['string', 'null'], - default: null, + default: DEFAULT_ICON_THEME_SETTING_VALUE, description: nls.localize('iconTheme', "Specifies the icon theme used in the workbench."), enum: [null], enumDescriptions: [nls.localize('noIconThemeDesc', 'No file icons')], -- GitLab From 8853b2db99a8a6f3151a08ecabf7727a8fb568a3 Mon Sep 17 00:00:00 2001 From: kieferrm Date: Fri, 26 May 2017 15:21:14 -0700 Subject: [PATCH 0227/1347] Ajust test to new defaults. See #26893. --- .../test/common/config/commonEditorConfig.test.ts | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/src/vs/editor/test/common/config/commonEditorConfig.test.ts b/src/vs/editor/test/common/config/commonEditorConfig.test.ts index c07e1240c1f..2e2f47b16aa 100644 --- a/src/vs/editor/test/common/config/commonEditorConfig.test.ts +++ b/src/vs/editor/test/common/config/commonEditorConfig.test.ts @@ -89,13 +89,23 @@ suite('Common Editor Config', () => { let config = new TestWrappingConfiguration({ wordWrap: true }); - assertWrapping(config, true, 89); + assertWrapping(config, true, 81); }); test('wordWrap on', () => { let config = new TestWrappingConfiguration({ wordWrap: 'on' }); + assertWrapping(config, true, 81); + }); + + test('wordWrap on without minimap', () => { + let config = new TestWrappingConfiguration({ + wordWrap: 'on', + minimap: { + enabled: false + } + }); assertWrapping(config, true, 89); }); @@ -104,7 +114,7 @@ suite('Common Editor Config', () => { wordWrap: 'on', wordWrapColumn: 10 }); - assertWrapping(config, true, 89); + assertWrapping(config, true, 81); }); test('wordWrap off', () => { -- GitLab From 944d4f1391dab48dec301bbb3a042921688d8cfb Mon Sep 17 00:00:00 2001 From: Daniel Ye Date: Fri, 26 May 2017 19:26:40 -0700 Subject: [PATCH 0228/1347] 2017-05-26. Merged in translation from transifex. --- .../chs/extensions/git/out/commands.i18n.json | 3 +++ i18n/chs/extensions/git/package.i18n.json | 1 + .../out/codelensProvider.i18n.json | 4 +++- .../out/commandHandler.i18n.json | 6 +++++- .../out/mergeDecorator.i18n.json | 4 +++- .../merge-conflict/package.i18n.json | 8 +++++++- i18n/chs/extensions/npm/package.i18n.json | 4 +++- .../out/features/bufferSyncSupport.i18n.json | 2 +- .../extensions/typescript/package.i18n.json | 1 + .../vs/code/electron-main/windows.i18n.json | 1 - .../browser/goToDeclarationCommands.i18n.json | 19 +------------------ .../browser/goToDeclarationMouse.i18n.json | 4 +--- .../electron-browser/workbench.i18n.json | 6 ++++++ .../extensionsUtils.i18n.json | 5 +++-- .../dirtydiffDecorator.i18n.json | 6 ++++++ .../out/codelensProvider.i18n.json | 7 ++++++- .../out/commandHandler.i18n.json | 5 ++++- .../out/mergeDecorator.i18n.json | 5 ++++- .../merge-conflict/package.i18n.json | 15 ++++++++++++++- i18n/cht/extensions/npm/package.i18n.json | 4 +++- .../vs/code/electron-main/windows.i18n.json | 1 - .../electron-browser/workbench.i18n.json | 6 ++++++ .../extensionsUtils.i18n.json | 5 +++-- .../dirtydiffDecorator.i18n.json | 6 ++++++ .../vs/code/electron-main/windows.i18n.json | 1 - .../electron-browser/workbench.i18n.json | 6 ++++++ .../extensionsUtils.i18n.json | 5 +++-- .../dirtydiffDecorator.i18n.json | 6 ++++++ .../esn/extensions/git/out/commands.i18n.json | 3 +++ i18n/esn/extensions/git/package.i18n.json | 1 + .../markdown/out/extension.i18n.json | 4 +++- .../out/codelensProvider.i18n.json | 7 ++++++- .../out/commandHandler.i18n.json | 8 +++++++- .../out/mergeDecorator.i18n.json | 5 ++++- .../merge-conflict/package.i18n.json | 16 +++++++++++++++- i18n/esn/extensions/npm/package.i18n.json | 4 +++- .../extensions/typescript/package.i18n.json | 1 + .../vs/code/electron-main/windows.i18n.json | 1 - .../electron-browser/workbench.i18n.json | 6 ++++++ .../statusbarColorProvider.i18n.json | 3 ++- .../extensionsUtils.i18n.json | 5 +++-- .../browser/files.contribution.i18n.json | 1 + .../dirtydiffDecorator.i18n.json | 6 ++++++ .../vs/code/electron-main/windows.i18n.json | 1 - .../electron-browser/workbench.i18n.json | 6 ++++++ .../extensionsUtils.i18n.json | 5 +++-- .../dirtydiffDecorator.i18n.json | 6 ++++++ .../vs/code/electron-main/windows.i18n.json | 1 - .../electron-browser/workbench.i18n.json | 6 ++++++ .../extensionsUtils.i18n.json | 5 +++-- .../dirtydiffDecorator.i18n.json | 6 ++++++ .../jpn/extensions/git/out/commands.i18n.json | 3 +++ i18n/jpn/extensions/git/package.i18n.json | 1 + .../markdown/out/extension.i18n.json | 4 +++- .../out/codelensProvider.i18n.json | 4 +++- .../out/commandHandler.i18n.json | 6 +++++- .../out/mergeDecorator.i18n.json | 4 +++- .../merge-conflict/package.i18n.json | 8 +++++++- i18n/jpn/extensions/npm/package.i18n.json | 4 +++- .../extensions/typescript/package.i18n.json | 1 + .../resourceviewer/resourceViewer.i18n.json | 1 + .../vs/code/electron-main/windows.i18n.json | 1 - .../common/view/editorColorRegistry.i18n.json | 6 +++++- .../contrib/links/browser/links.i18n.json | 1 + .../electron-browser/workbench.i18n.json | 6 ++++++ .../statusbarColorProvider.i18n.json | 3 ++- .../browser/extensionsActions.i18n.json | 4 ++++ .../extensionsUtils.i18n.json | 5 +++-- .../browser/files.contribution.i18n.json | 1 + .../dirtydiffDecorator.i18n.json | 6 ++++++ .../electron-browser/TMSnippets.i18n.json | 3 ++- .../vs/code/electron-main/windows.i18n.json | 1 - .../electron-browser/workbench.i18n.json | 6 ++++++ .../extensionsUtils.i18n.json | 5 +++-- .../dirtydiffDecorator.i18n.json | 6 ++++++ .../ptb/extensions/git/out/commands.i18n.json | 3 +++ i18n/ptb/extensions/git/package.i18n.json | 1 + .../markdown/out/extension.i18n.json | 4 +++- .../out/codelensProvider.i18n.json | 7 ++++++- .../out/commandHandler.i18n.json | 8 +++++++- .../out/mergeDecorator.i18n.json | 5 ++++- .../merge-conflict/package.i18n.json | 16 +++++++++++++++- i18n/ptb/extensions/npm/package.i18n.json | 4 +++- .../extensions/typescript/package.i18n.json | 1 + .../resourceviewer/resourceViewer.i18n.json | 1 + .../vs/code/electron-main/windows.i18n.json | 1 - .../config/commonEditorConfig.i18n.json | 4 ++++ .../common/view/editorColorRegistry.i18n.json | 6 +++++- .../contrib/links/browser/links.i18n.json | 1 + .../parts/editor/editorStatus.i18n.json | 1 + .../src/vs/workbench/common/theme.i18n.json | 6 ++++++ .../electron-browser/workbench.i18n.json | 6 ++++++ .../statusbarColorProvider.i18n.json | 3 ++- .../emmet.contribution.i18n.json | 3 ++- .../browser/extensionsActions.i18n.json | 9 ++++++++- .../extensionsUtils.i18n.json | 6 ++++-- .../browser/files.contribution.i18n.json | 1 + .../dirtydiffDecorator.i18n.json | 6 ++++++ .../electron-browser/TMSnippets.i18n.json | 3 ++- .../vs/code/electron-main/windows.i18n.json | 1 - .../electron-browser/workbench.i18n.json | 6 ++++++ .../extensionsUtils.i18n.json | 5 +++-- .../dirtydiffDecorator.i18n.json | 6 ++++++ 103 files changed, 378 insertions(+), 89 deletions(-) create mode 100644 i18n/chs/src/vs/workbench/electron-browser/workbench.i18n.json create mode 100644 i18n/chs/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json create mode 100644 i18n/cht/src/vs/workbench/electron-browser/workbench.i18n.json create mode 100644 i18n/cht/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json create mode 100644 i18n/deu/src/vs/workbench/electron-browser/workbench.i18n.json create mode 100644 i18n/deu/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json create mode 100644 i18n/esn/src/vs/workbench/electron-browser/workbench.i18n.json create mode 100644 i18n/esn/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json create mode 100644 i18n/fra/src/vs/workbench/electron-browser/workbench.i18n.json create mode 100644 i18n/fra/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json create mode 100644 i18n/ita/src/vs/workbench/electron-browser/workbench.i18n.json create mode 100644 i18n/ita/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json create mode 100644 i18n/jpn/src/vs/workbench/electron-browser/workbench.i18n.json create mode 100644 i18n/jpn/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json create mode 100644 i18n/kor/src/vs/workbench/electron-browser/workbench.i18n.json create mode 100644 i18n/kor/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/electron-browser/workbench.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json create mode 100644 i18n/rus/src/vs/workbench/electron-browser/workbench.i18n.json create mode 100644 i18n/rus/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json diff --git a/i18n/chs/extensions/git/out/commands.i18n.json b/i18n/chs/extensions/git/out/commands.i18n.json index 3a000b98773..ceede002e08 100644 --- a/i18n/chs/extensions/git/out/commands.i18n.json +++ b/i18n/chs/extensions/git/out/commands.i18n.json @@ -26,6 +26,9 @@ "provide commit message": "请æä¾›æ交消æ¯", "branch name": "分支å称", "provide branch name": "请æ供分支å称", + "select branch to delete": "选择è¦åˆ é™¤çš„分支", + "confirm force delete branch": "“{0}â€åˆ†æ”¯æœªè¢«å®Œå…¨åˆå¹¶ã€‚是å¦ä»è¦åˆ é™¤ï¼Ÿ", + "delete branch": "删除分支", "no remotes to pull": "存储库未é…置任何从其中进行拉å–的远程存储库。", "no remotes to push": "存储库未é…置任何è¦æŽ¨é€åˆ°çš„远程存储库。", "nobranch": "请签出一个分支以推é€åˆ°è¿œç¨‹ã€‚", diff --git a/i18n/chs/extensions/git/package.i18n.json b/i18n/chs/extensions/git/package.i18n.json index bed9f4de89c..9c65f275fd6 100644 --- a/i18n/chs/extensions/git/package.i18n.json +++ b/i18n/chs/extensions/git/package.i18n.json @@ -26,6 +26,7 @@ "command.undoCommit": "撤消上次æ交", "command.checkout": "签出到...", "command.branch": "创建分支...", + "command.deleteBranch": "删除分支...", "command.pull": "拉å–", "command.pullRebase": "拉å–(å˜åŸº)", "command.push": "推é€", diff --git a/i18n/chs/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/chs/extensions/merge-conflict/out/codelensProvider.i18n.json index 8b6ad71cd4e..3590523ef87 100644 --- a/i18n/chs/extensions/merge-conflict/out/codelensProvider.i18n.json +++ b/i18n/chs/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "acceptCurrentChange": "采用当å‰æ›´æ”¹" +} \ No newline at end of file diff --git a/i18n/chs/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/chs/extensions/merge-conflict/out/commandHandler.i18n.json index 8b6ad71cd4e..996cf7276b8 100644 --- a/i18n/chs/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/chs/extensions/merge-conflict/out/commandHandler.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "cursorNotInConflict": "编辑器光标ä¸åœ¨åˆå¹¶å†²çªå†…", + "noConflicts": "没有在此文件中找到åˆå¹¶å†²çª", + "noOtherConflictsInThisFile": "此文件中没有其他åˆå¹¶å†²çªäº†" +} \ No newline at end of file diff --git a/i18n/chs/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/chs/extensions/merge-conflict/out/mergeDecorator.i18n.json index 8b6ad71cd4e..feac7a236d8 100644 --- a/i18n/chs/extensions/merge-conflict/out/mergeDecorator.i18n.json +++ b/i18n/chs/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "currentChange": "(当å‰æ›´æ”¹)" +} \ No newline at end of file diff --git a/i18n/chs/extensions/merge-conflict/package.i18n.json b/i18n/chs/extensions/merge-conflict/package.i18n.json index 8b6ad71cd4e..82e4bc58463 100644 --- a/i18n/chs/extensions/merge-conflict/package.i18n.json +++ b/i18n/chs/extensions/merge-conflict/package.i18n.json @@ -3,4 +3,10 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "command.category": "åˆå¹¶å†²çª", + "command.next": "下一个冲çª", + "command.previous": "上一个冲çª", + "command.compare": "比较当å‰å†²çª", + "config.title": "åˆå¹¶å†²çª" +} \ No newline at end of file diff --git a/i18n/chs/extensions/npm/package.i18n.json b/i18n/chs/extensions/npm/package.i18n.json index 8b6ad71cd4e..6130b12cc05 100644 --- a/i18n/chs/extensions/npm/package.i18n.json +++ b/i18n/chs/extensions/npm/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.npm.autoDetect": "控制自动检测 npm 脚本是å¦æ‰“开。默认开å¯ã€‚" +} \ No newline at end of file diff --git a/i18n/chs/extensions/typescript/out/features/bufferSyncSupport.i18n.json b/i18n/chs/extensions/typescript/out/features/bufferSyncSupport.i18n.json index c885212097a..9dcaf692d8f 100644 --- a/i18n/chs/extensions/typescript/out/features/bufferSyncSupport.i18n.json +++ b/i18n/chs/extensions/typescript/out/features/bufferSyncSupport.i18n.json @@ -6,7 +6,7 @@ { "versionMismatch": "版本ä¸åŒ¹é…! 全局 tsc ({0}) != VS Code 的语言æœåŠ¡({1})。å¯èƒ½å‡ºçŽ°ä¸ä¸€è‡´çš„编译错误", "moreInformation": "详细信æ¯", - "doNotCheckAgain": "ä¸è¦å†æ¬¡æ£€æŸ¥", + "doNotCheckAgain": "ä¸å†æ£€æŸ¥", "close": "关闭", "updateTscCheck": "已将用户设置 \"typescript.check.tscVersion\" 更新为 false" } \ No newline at end of file diff --git a/i18n/chs/extensions/typescript/package.i18n.json b/i18n/chs/extensions/typescript/package.i18n.json index 7d185d9e36e..e9bd0e95be0 100644 --- a/i18n/chs/extensions/typescript/package.i18n.json +++ b/i18n/chs/extensions/typescript/package.i18n.json @@ -37,6 +37,7 @@ "typescript.referencesCodeLens.enabled": "å¯ç”¨/ç¦ç”¨åœ¨ TypeScript 文件中引用 CodeLens。è¦æ±‚ TypeScript >= 2.0.6。", "typescript.implementationsCodeLens.enabled": "å¯ç”¨/ç¦ç”¨å®žçŽ° CodeLens。è¦æ±‚ TypeScript >= 2.2.0。", "typescript.openTsServerLog.title": "打开 TS æœåŠ¡å™¨æ—¥å¿—", + "typescript.restartTsServer": "é‡å¯ TS æœåŠ¡å™¨", "typescript.selectTypeScriptVersion.title": "选择 TypeScript 版本", "jsDocCompletion.enabled": "å¯ç”¨/ç¦ç”¨è‡ªåŠ¨ JSDoc 注释", "javascript.implicitProjectConfig.checkJs": "å¯ç”¨/ç¦ç”¨ JavaScript 文件的语义检查。现有的 jsconfig.json 或\n tsconfig.json 文件会覆盖此设置。è¦æ±‚ TypeScript >=2.3.1。", diff --git a/i18n/chs/src/vs/code/electron-main/windows.i18n.json b/i18n/chs/src/vs/code/electron-main/windows.i18n.json index 6982cf6190c..55246096dd2 100644 --- a/i18n/chs/src/vs/code/electron-main/windows.i18n.json +++ b/i18n/chs/src/vs/code/electron-main/windows.i18n.json @@ -7,7 +7,6 @@ "ok": "确定", "pathNotExistTitle": "路径ä¸å­˜åœ¨", "pathNotExistDetail": "ç£ç›˜ä¸Šä¼¼ä¹Žä¸å†å­˜åœ¨è·¯å¾„“{0}â€ã€‚", - "accessibilityOptionsWindowTitle": "辅助功能选项", "reopen": "é‡æ–°æ‰“å¼€", "wait": "ä¿æŒç­‰å¾…", "close": "关闭", diff --git a/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json index e788771d2f2..8b6ad71cd4e 100644 --- a/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json +++ b/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -3,21 +3,4 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{ - "noResultWord": "未找到“{0}â€çš„任何定义", - "generic.noResults": "找ä¸åˆ°å®šä¹‰", - "meta.title": " – {0} 定义", - "actions.goToDecl.label": "转到定义", - "actions.goToDeclToSide.label": "打开侧边的定义", - "actions.previewDecl.label": "查看定义", - "goToImplementation.noResultWord": "未找到“{0}â€çš„实现", - "goToImplementation.generic.noResults": "未找到实现", - "meta.implementations.title": "– {0} 个实现", - "actions.goToImplementation.label": "转到实现", - "actions.peekImplementation.label": "速览实现", - "goToTypeDefinition.noResultWord": "未找到“{0}â€çš„类型定义", - "goToTypeDefinition.generic.noResults": "未找到类型定义", - "meta.typeDefinitions.title": " – {0} 个类型定义", - "actions.goToTypeDefinition.label": "转到类型定义", - "actions.peekTypeDefinition.label": "快速查看类型定义" -} \ No newline at end of file +{} \ No newline at end of file diff --git a/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json index ab0b4761cf9..8b6ad71cd4e 100644 --- a/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json +++ b/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -3,6 +3,4 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{ - "multipleResults": "å•å‡»æ˜¾ç¤º {0} 个定义。" -} \ No newline at end of file +{} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/chs/src/vs/workbench/electron-browser/workbench.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/chs/src/vs/workbench/electron-browser/workbench.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/chs/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 5a4bf096f38..a8554464048 100644 --- a/i18n/chs/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -4,7 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "disableOtherKeymapsConfirmation": "是å¦ç¦ç”¨å…¶ä»–键映射以é¿å…键绑定之间的冲çª?", "yes": "是", - "no": "å¦" + "no": "å¦", + "uninstall": "å¸è½½", + "later": "ç¨åŽ" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/chs/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/chs/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/cht/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/cht/extensions/merge-conflict/out/codelensProvider.i18n.json index 8b6ad71cd4e..fd3fc4ee512 100644 --- a/i18n/cht/extensions/merge-conflict/out/codelensProvider.i18n.json +++ b/i18n/cht/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -3,4 +3,9 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "acceptCurrentChange": "接å—當å‰è®Šæ›´", + "acceptIncomingChange": "接å—來æºè®Šæ›´", + "acceptBothChanges": "接å—兩者變更", + "compareChanges": "比較變更" +} \ No newline at end of file diff --git a/i18n/cht/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/cht/extensions/merge-conflict/out/commandHandler.i18n.json index 8b6ad71cd4e..b72349a9332 100644 --- a/i18n/cht/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/cht/extensions/merge-conflict/out/commandHandler.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "noConflicts": "檔案內找ä¸åˆ°éœ€è¦åˆä½µè¡çªé …ç›®", + "noOtherConflictsInThisFile": "此檔案內沒有其他的è¡çªåˆä½µé …ç›®" +} \ No newline at end of file diff --git a/i18n/cht/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/cht/extensions/merge-conflict/out/mergeDecorator.i18n.json index 8b6ad71cd4e..1282a1b3de3 100644 --- a/i18n/cht/extensions/merge-conflict/out/mergeDecorator.i18n.json +++ b/i18n/cht/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "currentChange": "(ç›®å‰è®Šæ›´)", + "incomingChange": "(來æºè®Šæ›´)" +} \ No newline at end of file diff --git a/i18n/cht/extensions/merge-conflict/package.i18n.json b/i18n/cht/extensions/merge-conflict/package.i18n.json index 8b6ad71cd4e..1afd0effd3e 100644 --- a/i18n/cht/extensions/merge-conflict/package.i18n.json +++ b/i18n/cht/extensions/merge-conflict/package.i18n.json @@ -3,4 +3,17 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "command.category": "åˆä½µè¡çª", + "command.accept.all-incoming": "接å—所有來æº", + "command.accept.all-both": "接å—兩者", + "command.accept.current": "接å—當å‰é …ç›®", + "command.accept.incoming": "接å—來æº", + "command.accept.selection": "接å—é¸å–é …ç›®", + "command.accept.both": "接å—兩者", + "command.next": "後一個è¡çª", + "command.previous": "å‰ä¸€å€‹è¡çª", + "command.compare": "比較目å‰è¡çª", + "config.title": "åˆä½µè¡çª", + "config.codeLensEnabled": "啟用/åœç”¨ 編輯器CodeLensè¡çªåˆä½µ " +} \ No newline at end of file diff --git a/i18n/cht/extensions/npm/package.i18n.json b/i18n/cht/extensions/npm/package.i18n.json index 8b6ad71cd4e..74cbc6cffe4 100644 --- a/i18n/cht/extensions/npm/package.i18n.json +++ b/i18n/cht/extensions/npm/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.npm.autoDetect": "控制是å¦è‡ªå‹•æª¢æ¸¬npm腳本.é è¨­ç‚ºé–‹å•Ÿ." +} \ No newline at end of file diff --git a/i18n/cht/src/vs/code/electron-main/windows.i18n.json b/i18n/cht/src/vs/code/electron-main/windows.i18n.json index 1a51baff5db..08847b4b8e4 100644 --- a/i18n/cht/src/vs/code/electron-main/windows.i18n.json +++ b/i18n/cht/src/vs/code/electron-main/windows.i18n.json @@ -7,7 +7,6 @@ "ok": "確定", "pathNotExistTitle": "路徑ä¸å­˜åœ¨", "pathNotExistDetail": "ç£ç¢Ÿä¸Šä¼¼ä¹Žå·²æ²’有路徑 '{0}'。", - "accessibilityOptionsWindowTitle": "å”助工具é¸é …", "reopen": "é‡æ–°é–‹å•Ÿ", "wait": "繼續等候", "close": "關閉", diff --git a/i18n/cht/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/cht/src/vs/workbench/electron-browser/workbench.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/cht/src/vs/workbench/electron-browser/workbench.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 49a87dcf222..6394eecabd8 100644 --- a/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -4,7 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "disableOtherKeymapsConfirmation": "è¦åœç”¨å…¶ä»–按éµå°æ‡‰ï¼Œä»¥é¿å…按éµç¹«çµé—œä¿‚發生è¡çªå—Ž?", "yes": "是", - "no": "å¦" + "no": "å¦", + "uninstall": "解除安è£", + "later": "ç¨å¾Œ" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/cht/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/cht/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/deu/src/vs/code/electron-main/windows.i18n.json b/i18n/deu/src/vs/code/electron-main/windows.i18n.json index 19ea01ffe2b..b31c876e930 100644 --- a/i18n/deu/src/vs/code/electron-main/windows.i18n.json +++ b/i18n/deu/src/vs/code/electron-main/windows.i18n.json @@ -7,7 +7,6 @@ "ok": "OK", "pathNotExistTitle": "Der Pfad ist nicht vorhanden.", "pathNotExistDetail": "Der Pfad \"{0}\" scheint auf dem Datenträger nicht mehr vorhanden zu sein.", - "accessibilityOptionsWindowTitle": "Optionen für erleichterte Bedienung", "reopen": "Erneut öffnen", "wait": "Bitte warten.", "close": "Schließen", diff --git a/i18n/deu/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/deu/src/vs/workbench/electron-browser/workbench.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/deu/src/vs/workbench/electron-browser/workbench.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/deu/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 5c79e379437..4769dc3fe1e 100644 --- a/i18n/deu/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -4,7 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "disableOtherKeymapsConfirmation": "Andere Tastenzuordnungen deaktivieren, um Konflikte zwischen Tastenzuordnungen zu vermeiden?", "yes": "Ja", - "no": "Nein" + "no": "Nein", + "uninstall": "Deinstallieren", + "later": "Später" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/deu/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/deu/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/esn/extensions/git/out/commands.i18n.json b/i18n/esn/extensions/git/out/commands.i18n.json index 1897af0ac26..6ace96fe6d2 100644 --- a/i18n/esn/extensions/git/out/commands.i18n.json +++ b/i18n/esn/extensions/git/out/commands.i18n.json @@ -26,6 +26,9 @@ "provide commit message": "Proporcione un mensaje de confirmación", "branch name": "Nombre de rama", "provide branch name": "Especifique un nombre para la rama", + "select branch to delete": "Seleccione una rama para borrar", + "confirm force delete branch": "La rama '{0}' no está completamente fusionada. ¿Borrarla de todas formas?", + "delete branch": "Borrar rama...", "no remotes to pull": "El repositorio no tiene remotos configurados de los que extraer.", "no remotes to push": "El repositorio no tiene remotos configurados en los que insertar.", "nobranch": "Extraiga del repositorio una rama para insertar un remoto.", diff --git a/i18n/esn/extensions/git/package.i18n.json b/i18n/esn/extensions/git/package.i18n.json index 504bfa02569..afda046fe5a 100644 --- a/i18n/esn/extensions/git/package.i18n.json +++ b/i18n/esn/extensions/git/package.i18n.json @@ -26,6 +26,7 @@ "command.undoCommit": "Deshacer última confirmación", "command.checkout": "Desproteger en...", "command.branch": "Crear rama...", + "command.deleteBranch": "Borrar rama...", "command.pull": "Incorporación de cambios", "command.pullRebase": "Incorporación de cambios (fusionar mediante cambio de base)", "command.push": "Insertar", diff --git a/i18n/esn/extensions/markdown/out/extension.i18n.json b/i18n/esn/extensions/markdown/out/extension.i18n.json index 8b6ad71cd4e..360f0b974b7 100644 --- a/i18n/esn/extensions/markdown/out/extension.i18n.json +++ b/i18n/esn/extensions/markdown/out/extension.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "onPreviewStyleLoadError": "No se pudo cargar 'markdown.styles': {0}" +} \ No newline at end of file diff --git a/i18n/esn/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/esn/extensions/merge-conflict/out/codelensProvider.i18n.json index 8b6ad71cd4e..22ca13053b5 100644 --- a/i18n/esn/extensions/merge-conflict/out/codelensProvider.i18n.json +++ b/i18n/esn/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -3,4 +3,9 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "acceptCurrentChange": "Aceptar cambio actual", + "acceptIncomingChange": "Aceptar cambio entrante", + "acceptBothChanges": "Aceptar ambos cambios", + "compareChanges": "Comparar cambios" +} \ No newline at end of file diff --git a/i18n/esn/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/esn/extensions/merge-conflict/out/commandHandler.i18n.json index 8b6ad71cd4e..eb8028b1717 100644 --- a/i18n/esn/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/esn/extensions/merge-conflict/out/commandHandler.i18n.json @@ -3,4 +3,10 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "cursorNotInConflict": "El cursor de edición no se encuentra en un conflicto de fusión", + "compareChangesTitle": "{0}: Cambios actuales \\u2194 Cambios entrantes", + "cursorOnSplitterRange": "El cursor del editor está dentro del separador de conflictos de fusión, muévalo al bloque \"actual\" o al \"entrante\" ", + "noConflicts": "No se encontraron conflictos en este archivo", + "noOtherConflictsInThisFile": "No hay más conflictos en este archivo" +} \ No newline at end of file diff --git a/i18n/esn/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/esn/extensions/merge-conflict/out/mergeDecorator.i18n.json index 8b6ad71cd4e..9cf24c3ecc5 100644 --- a/i18n/esn/extensions/merge-conflict/out/mergeDecorator.i18n.json +++ b/i18n/esn/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "currentChange": "(Cambio actual)", + "incomingChange": "(Cambio entrante)" +} \ No newline at end of file diff --git a/i18n/esn/extensions/merge-conflict/package.i18n.json b/i18n/esn/extensions/merge-conflict/package.i18n.json index 8b6ad71cd4e..880711d45ac 100644 --- a/i18n/esn/extensions/merge-conflict/package.i18n.json +++ b/i18n/esn/extensions/merge-conflict/package.i18n.json @@ -3,4 +3,18 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "command.category": "Fusionar conflicto", + "command.accept.all-incoming": "Aceptar todos los entrantes", + "command.accept.all-both": "Aceptar todos ambos", + "command.accept.current": "Aceptar actual", + "command.accept.incoming": "Aceptar entrante", + "command.accept.selection": "Aceptar selección", + "command.accept.both": "Aceptar ambos", + "command.next": "Siguiente conflicto", + "command.previous": "Conflicto anterior", + "command.compare": "Comparar conflicto actual", + "config.title": "Fusionar conflicto", + "config.codeLensEnabled": "Habilitar/deshabilitar CodeLens de fusionar bloque de conflictos en el editor", + "config.decoratorsEnabled": "Habilitar/deshabilitar decoradores de conflictos de fusión en el editor" +} \ No newline at end of file diff --git a/i18n/esn/extensions/npm/package.i18n.json b/i18n/esn/extensions/npm/package.i18n.json index 8b6ad71cd4e..d71e21915da 100644 --- a/i18n/esn/extensions/npm/package.i18n.json +++ b/i18n/esn/extensions/npm/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.npm.autoDetect": "Controla si la detección automática de scripts npm está activada o desactivada. Por defecto está activada." +} \ No newline at end of file diff --git a/i18n/esn/extensions/typescript/package.i18n.json b/i18n/esn/extensions/typescript/package.i18n.json index 599140da8f5..4ff6892a0a6 100644 --- a/i18n/esn/extensions/typescript/package.i18n.json +++ b/i18n/esn/extensions/typescript/package.i18n.json @@ -37,6 +37,7 @@ "typescript.referencesCodeLens.enabled": "Habilitar/deshabilitar las referencias de CodeLens en los archivos de TypeScript. Requiere TypeScript >= 2.0.6.", "typescript.implementationsCodeLens.enabled": "Habilita o deshabilita implementaciones de CodeLens. Requiere TypeScript >= 2.2.0.", "typescript.openTsServerLog.title": "Abrir registro del servidor de TS", + "typescript.restartTsServer": "Reiniciar servidor TS", "typescript.selectTypeScriptVersion.title": "Seleccionar versión de TypeScript", "jsDocCompletion.enabled": "Habilita o deshabilita comentarios automaticos de JSDoc", "javascript.implicitProjectConfig.checkJs": "Habilita/deshabilita la comprobación semántica de los archivos JavaScript. Los archivos jsconfig.json o tsconfig.json reemplazan esta configuración. Se requiere TypeScript >=2.3.1.", diff --git a/i18n/esn/src/vs/code/electron-main/windows.i18n.json b/i18n/esn/src/vs/code/electron-main/windows.i18n.json index fd891dfad94..80fb2bc32dc 100644 --- a/i18n/esn/src/vs/code/electron-main/windows.i18n.json +++ b/i18n/esn/src/vs/code/electron-main/windows.i18n.json @@ -7,7 +7,6 @@ "ok": "Aceptar", "pathNotExistTitle": "La ruta no existe", "pathNotExistDetail": "Parece que la ruta '{0}' ya no existe en el disco.", - "accessibilityOptionsWindowTitle": "Opciones de accesibilidad", "reopen": "Volver a abrir", "wait": "Siga esperando", "close": "Cerrar", diff --git a/i18n/esn/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/esn/src/vs/workbench/electron-browser/workbench.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/esn/src/vs/workbench/electron-browser/workbench.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json b/i18n/esn/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json index 916ac3e4884..ff677b59a60 100644 --- a/i18n/esn/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "statusBarDebuggingBackground": "Color de fondo de la barra de estado cuando se está depurando un programa. La barra de estado se muestra en la parte inferior de la ventana" + "statusBarDebuggingBackground": "Color de fondo de la barra de estado cuando se está depurando un programa. La barra de estado se muestra en la parte inferior de la ventana", + "statusBarDebuggingForeground": "Color de primer plano de la barra de estado cuando se está depurando un programa. La barra de estado se muestra en la parte inferior de la ventana" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/esn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 2b42d7a0c5b..f9f715ea4a9 100644 --- a/i18n/esn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -4,7 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "disableOtherKeymapsConfirmation": "¿Quiere deshabilitar otras asignaciones de teclado para evitar conflictos entre los enlaces de teclado?", "yes": "Sí", - "no": "No" + "no": "No", + "uninstall": "Desinstalación", + "later": "Más tarde" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/esn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index ef718dc3ee1..923353af133 100644 --- a/i18n/esn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,6 +16,7 @@ "associations": "Configure asociaciones de archivo para los lenguajes (por ejemplo, \"*.extension\": \"html\"). Estas asociaciones tienen prioridad sobre las asociaciones predeterminadas de los lenguajes instalados.", "encoding": "La codificación del juego de caracteres predeterminada que debe utilizarse al leer y escribir archivos.", "autoGuessEncoding": "Si está opción está habilitada, se intentará adivinar la codificación del juego de caracteres al abrir los archivos", + "eol": "Carácter predeterminado de final de línea. Utilice \\n para LF y \\r\\n para CRLF.", "trimTrailingWhitespace": "Si se habilita, se recortará el espacio final cuando se guarde un archivo.", "insertFinalNewline": "Si se habilita, inserte una nueva línea final al final del archivo cuando lo guarde.", "files.autoSave.off": "Un archivo con modificaciones no se guarda nunca automáticamente.", diff --git a/i18n/esn/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/esn/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/esn/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/fra/src/vs/code/electron-main/windows.i18n.json b/i18n/fra/src/vs/code/electron-main/windows.i18n.json index 7893fb77cc3..af0778db015 100644 --- a/i18n/fra/src/vs/code/electron-main/windows.i18n.json +++ b/i18n/fra/src/vs/code/electron-main/windows.i18n.json @@ -7,7 +7,6 @@ "ok": "OK", "pathNotExistTitle": "Le chemin d'accès n'existe pas", "pathNotExistDetail": "Le chemin d'accès '{0}' ne semble plus exister sur le disque.", - "accessibilityOptionsWindowTitle": "Options d'accessibilité", "reopen": "Rouvrir", "wait": "Continuer à attendre", "close": "Fermer", diff --git a/i18n/fra/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/fra/src/vs/workbench/electron-browser/workbench.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/fra/src/vs/workbench/electron-browser/workbench.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 5ddc77dfc5a..8fa1a11d54a 100644 --- a/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -4,7 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "disableOtherKeymapsConfirmation": "Désactiver les autres mappages de touches pour éviter les conflits de combinaisons de touches ?", "yes": "Oui", - "no": "Non" + "no": "Non", + "uninstall": "Désinstaller", + "later": "Plus tard" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/fra/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/fra/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ita/src/vs/code/electron-main/windows.i18n.json b/i18n/ita/src/vs/code/electron-main/windows.i18n.json index 2d2cdf7fee4..6add23a4257 100644 --- a/i18n/ita/src/vs/code/electron-main/windows.i18n.json +++ b/i18n/ita/src/vs/code/electron-main/windows.i18n.json @@ -7,7 +7,6 @@ "ok": "OK", "pathNotExistTitle": "Il percorso non esiste", "pathNotExistDetail": "Il percorso '{0}' sembra non esistere più sul disco.", - "accessibilityOptionsWindowTitle": "Opzioni accessibilità", "reopen": "Riapri", "wait": "Continua ad attendere", "close": "Chiudi", diff --git a/i18n/ita/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/ita/src/vs/workbench/electron-browser/workbench.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ita/src/vs/workbench/electron-browser/workbench.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 6c3f2e984e8..0a6152b0c7b 100644 --- a/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -4,7 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "disableOtherKeymapsConfirmation": "Disabilitare altre mappature tastiera per evitare conflitti tra tasti di scelta rapida?", "yes": "Sì", - "no": "No" + "no": "No", + "uninstall": "Disinstalla", + "later": "In seguito" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/ita/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ita/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/jpn/extensions/git/out/commands.i18n.json b/i18n/jpn/extensions/git/out/commands.i18n.json index 8ecbb563965..9c6bd23d155 100644 --- a/i18n/jpn/extensions/git/out/commands.i18n.json +++ b/i18n/jpn/extensions/git/out/commands.i18n.json @@ -26,6 +26,9 @@ "provide commit message": "コミット メッセージを入力ã—ã¦ãã ã•ã„", "branch name": "ブランãƒå", "provide branch name": "ブランãƒåを指定ã—ã¦ãã ã•ã„", + "select branch to delete": "削除ã™ã‚‹ãƒ–ランãƒã®é¸æŠž", + "confirm force delete branch": "ブランム'{0}' ã¯ãƒžãƒ¼ã‚¸ã•ã‚Œã¦ã„ã¾ã›ã‚“。ãã‚Œã§ã‚‚削除ã—ã¾ã™ã‹ï¼Ÿ", + "delete branch": "ブランãƒã®å‰Šé™¤", "no remotes to pull": "リãƒã‚¸ãƒˆãƒªã«ã¯ã€ãƒ—ル元ã¨ã—ã¦æ§‹æˆã•ã‚Œã¦ã„るリモートãŒã‚ã‚Šã¾ã›ã‚“。", "no remotes to push": "リãƒã‚¸ãƒˆãƒªã«ã¯ã€ãƒ—ッシュ先ã¨ã—ã¦æ§‹æˆã•ã‚Œã¦ã„るリモートãŒã‚ã‚Šã¾ã›ã‚“。", "nobranch": "リモートã«ãƒ—ッシュã™ã‚‹ãƒ–ランãƒã‚’ãƒã‚§ãƒƒã‚¯ã‚¢ã‚¦ãƒˆã—ã¦ãã ã•ã„。", diff --git a/i18n/jpn/extensions/git/package.i18n.json b/i18n/jpn/extensions/git/package.i18n.json index 66c511eaf69..1c27e31a01c 100644 --- a/i18n/jpn/extensions/git/package.i18n.json +++ b/i18n/jpn/extensions/git/package.i18n.json @@ -26,6 +26,7 @@ "command.undoCommit": "å‰å›žã®ã‚³ãƒŸãƒƒãƒˆã‚’å…ƒã«æˆ»ã™", "command.checkout": "ãƒã‚§ãƒƒã‚¯ã‚¢ã‚¦ãƒˆå…ˆ...", "command.branch": "分å²ã®ä½œæˆ...", + "command.deleteBranch": "ブランãƒã®å‰Šé™¤...", "command.pull": "プル", "command.pullRebase": "プル (リベース)", "command.push": "プッシュ", diff --git a/i18n/jpn/extensions/markdown/out/extension.i18n.json b/i18n/jpn/extensions/markdown/out/extension.i18n.json index 8b6ad71cd4e..fd083fda4b6 100644 --- a/i18n/jpn/extensions/markdown/out/extension.i18n.json +++ b/i18n/jpn/extensions/markdown/out/extension.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "onPreviewStyleLoadError": "'markdown.styles' を読ã¿è¾¼ã‚€ã“ã¨ãŒã§ãã¾ã›ã‚“: {0}" +} \ No newline at end of file diff --git a/i18n/jpn/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/jpn/extensions/merge-conflict/out/codelensProvider.i18n.json index 8b6ad71cd4e..104396accee 100644 --- a/i18n/jpn/extensions/merge-conflict/out/codelensProvider.i18n.json +++ b/i18n/jpn/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "compareChanges": "変更ã®æ¯”較" +} \ No newline at end of file diff --git a/i18n/jpn/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/jpn/extensions/merge-conflict/out/commandHandler.i18n.json index 8b6ad71cd4e..6c318704912 100644 --- a/i18n/jpn/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/jpn/extensions/merge-conflict/out/commandHandler.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "cursorNotInConflict": "エディターã®ã‚«ãƒ¼ã‚½ãƒ«ãŒãƒžãƒ¼ã‚¸ã®ç«¶åˆã®ç¯„囲内ã«ã‚ã‚Šã¾ã›ã‚“", + "noConflicts": "ã“ã®ãƒ•ã‚¡ã‚¤ãƒ«ã«ãƒžãƒ¼ã‚¸ã®ç«¶åˆã¯å­˜åœ¨ã—ã¾ã›ã‚“", + "noOtherConflictsInThisFile": "ã“ã®ãƒ•ã‚¡ã‚¤ãƒ«ã«ä»–ã®ãƒžãƒ¼ã‚¸ã®ç«¶åˆã¯å­˜åœ¨ã—ã¾ã›ã‚“" +} \ No newline at end of file diff --git a/i18n/jpn/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/jpn/extensions/merge-conflict/out/mergeDecorator.i18n.json index 8b6ad71cd4e..9da2446076d 100644 --- a/i18n/jpn/extensions/merge-conflict/out/mergeDecorator.i18n.json +++ b/i18n/jpn/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "currentChange": "(ç¾åœ¨ã®å¤‰æ›´)" +} \ No newline at end of file diff --git a/i18n/jpn/extensions/merge-conflict/package.i18n.json b/i18n/jpn/extensions/merge-conflict/package.i18n.json index 8b6ad71cd4e..178880dd69d 100644 --- a/i18n/jpn/extensions/merge-conflict/package.i18n.json +++ b/i18n/jpn/extensions/merge-conflict/package.i18n.json @@ -3,4 +3,10 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "command.category": "マージã®ç«¶åˆ", + "command.next": "次ã®ç«¶åˆ", + "command.previous": "å‰ã®ç«¶åˆ", + "command.compare": "ç¾åœ¨ã®ç«¶åˆã‚’比較", + "config.title": "マージã®ç«¶åˆ" +} \ No newline at end of file diff --git a/i18n/jpn/extensions/npm/package.i18n.json b/i18n/jpn/extensions/npm/package.i18n.json index 8b6ad71cd4e..6a332075fd0 100644 --- a/i18n/jpn/extensions/npm/package.i18n.json +++ b/i18n/jpn/extensions/npm/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.npm.autoDetect": "npm スクリプトã®è‡ªå‹•æ¤œå‡ºã‚’オンã«ã™ã‚‹ã‹ã‚ªãƒ•ã«ã™ã‚‹ã‹ã‚’制御ã—ã¾ã™ã€‚既定ã¯ã‚ªãƒ³ã§ã™ã€‚" +} \ No newline at end of file diff --git a/i18n/jpn/extensions/typescript/package.i18n.json b/i18n/jpn/extensions/typescript/package.i18n.json index d3f776eaa11..1ad434c3205 100644 --- a/i18n/jpn/extensions/typescript/package.i18n.json +++ b/i18n/jpn/extensions/typescript/package.i18n.json @@ -37,6 +37,7 @@ "typescript.referencesCodeLens.enabled": "TypeScript ファイル内㧠CodeLens ã®å‚照を有効/無効ã«ã—ã¾ã™ã€‚TypeScript 2.0.6 以上ãŒå¿…è¦ã§ã™ã€‚", "typescript.implementationsCodeLens.enabled": "CodeLens ã®å®Ÿè£…を有効/無効ã«ã—ã¾ã™ã€‚TypeScript 2.2.0 以上ãŒå¿…è¦ã§ã™ã€‚", "typescript.openTsServerLog.title": "TS サーãƒãƒ¼ã®ãƒ­ã‚°ã‚’é–‹ã", + "typescript.restartTsServer": "TS サーãƒãƒ¼ã‚’å†èµ·å‹•ã™ã‚‹", "typescript.selectTypeScriptVersion.title": "TypeScript ã®ãƒãƒ¼ã‚¸ãƒ§ãƒ³ã®é¸æŠž", "jsDocCompletion.enabled": " 自動 JSDoc コメントを有効/無効ã«ã—ã¾ã™", "javascript.implicitProjectConfig.checkJs": "JavaScript ファイルã®ã‚»ãƒžãƒ³ãƒ†ã‚£ãƒƒã‚¯ ãƒã‚§ãƒƒã‚¯ã‚’有効/無効ã«ã—ã¾ã™ã€‚既存㮠jsconfi.json ã‚„ tsconfi.json ファイルã®è¨­å®šã¯ã“れより優先ã•ã‚Œã¾ã™ã€‚TypeScript 㯠2.3.1 以上ã§ã‚ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™ã€‚", diff --git a/i18n/jpn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/jpn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index e70844baf7b..15d556bd644 100644 --- a/i18n/jpn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/jpn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,6 +6,7 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "イメージãŒå¤§ãã™ãŽã¦ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã«è¡¨ç¤ºã§ãã¾ã›ã‚“。", + "resourceOpenExternalButton": "外部ã®ãƒ—ログラムを使用ã—ã¦ç”»åƒã‚’é–‹ãã¾ã™ã‹?", "nativeBinaryError": "ã“ã®ãƒ•ã‚¡ã‚¤ãƒ«ã¯ãƒã‚¤ãƒŠãƒªã‹ã€éžå¸¸ã«å¤§ãã„ã‹ã€ã¾ãŸã¯ã‚µãƒãƒ¼ãƒˆã•ã‚Œã¦ã„ãªã„テキスト エンコードを使用ã—ã¦ã„ã‚‹ãŸã‚ã€ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã«è¡¨ç¤ºã•ã‚Œã¾ã›ã‚“。", "sizeB": "{0}B", "sizeKB": "{0}KB", diff --git a/i18n/jpn/src/vs/code/electron-main/windows.i18n.json b/i18n/jpn/src/vs/code/electron-main/windows.i18n.json index 6b0480ce2d2..6631797b5a4 100644 --- a/i18n/jpn/src/vs/code/electron-main/windows.i18n.json +++ b/i18n/jpn/src/vs/code/electron-main/windows.i18n.json @@ -7,7 +7,6 @@ "ok": "OK", "pathNotExistTitle": "パスãŒå­˜åœ¨ã—ã¾ã›ã‚“", "pathNotExistDetail": "パス '{0}' ã¯ãƒ‡ã‚£ã‚¹ã‚¯ã«å­˜åœ¨ã—ãªããªã£ãŸã‚ˆã†ã§ã™ã€‚", - "accessibilityOptionsWindowTitle": "ユーザー補助オプション", "reopen": "ã‚‚ã†ä¸€åº¦é–‹ã", "wait": "待機を続ã‘ã‚‹", "close": "é–‰ã˜ã‚‹", diff --git a/i18n/jpn/src/vs/editor/common/view/editorColorRegistry.i18n.json b/i18n/jpn/src/vs/editor/common/view/editorColorRegistry.i18n.json index f364e5e0d14..b380e645e98 100644 --- a/i18n/jpn/src/vs/editor/common/view/editorColorRegistry.i18n.json +++ b/i18n/jpn/src/vs/editor/common/view/editorColorRegistry.i18n.json @@ -16,5 +16,9 @@ "editorBracketMatchBackground": "一致ã™ã‚‹ã‹ã£ã“ã®èƒŒæ™¯è‰²", "editorBracketMatchBorder": "一致ã™ã‚‹ã‹ã£ã“内ã®ãƒœãƒƒã‚¯ã‚¹ã®è‰²", "editorOverviewRulerBorder": "概è¦ãƒ«ãƒ¼ãƒ©ãƒ¼ã®å¢ƒç•Œè‰²ã€‚", - "editorGutter": "エディターã®ä½™ç™½ã®èƒŒæ™¯è‰²ã€‚余白ã«ã¯ã‚°ãƒªãƒ• マージンã¨è¡Œç•ªå·ãŒå«ã¾ã‚Œã¾ã™ã€‚" + "editorGutter": "エディターã®ä½™ç™½ã®èƒŒæ™¯è‰²ã€‚余白ã«ã¯ã‚°ãƒªãƒ• マージンã¨è¡Œç•ªå·ãŒå«ã¾ã‚Œã¾ã™ã€‚", + "errorForeground": "エディターã§ã‚¨ãƒ©ãƒ¼ã‚’示ã™æ³¢ç·šã®å‰æ™¯è‰²ã€‚", + "errorBorder": "エディターã§ã‚¨ãƒ©ãƒ¼ã‚’示ã™æ³¢ç·šã®å¢ƒç•Œç·šã®è‰²ã€‚", + "warningForeground": "エディターã§è­¦å‘Šã‚’示ã™æ³¢ç·šã®å‰æ™¯è‰²ã€‚", + "warningBorder": "エディターã§è­¦å‘Šã‚’示ã™æ³¢ç·šã®å¢ƒç•Œç·šã®è‰²ã€‚" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/editor/contrib/links/browser/links.i18n.json b/i18n/jpn/src/vs/editor/contrib/links/browser/links.i18n.json index 178a2d932ba..67812ff35d1 100644 --- a/i18n/jpn/src/vs/editor/contrib/links/browser/links.i18n.json +++ b/i18n/jpn/src/vs/editor/contrib/links/browser/links.i18n.json @@ -6,6 +6,7 @@ { "links.navigate.mac": "command キーを押ã—ãªãŒã‚‰ã‚¯ãƒªãƒƒã‚¯ã—ã¦ãƒªãƒ³ã‚¯å…ˆã‚’表示", "links.navigate": "Ctrl キーを押ã—ãªãŒã‚‰ã‚¯ãƒªãƒƒã‚¯ã—ã¦ãƒªãƒ³ã‚¯å…ˆã‚’表示", + "links.navigate.al": "Altl キーを押ã—ãªãŒã‚‰ã‚¯ãƒªãƒƒã‚¯ã—ã¦ãƒªãƒ³ã‚¯å…ˆã‚’表示", "invalid.url": "申ã—訳ã‚ã‚Šã¾ã›ã‚“。ã“ã®ãƒªãƒ³ã‚¯ã¯å½¢å¼ãŒæ­£ã—ããªã„ãŸã‚é–‹ãã“ã¨ãŒã§ãã¾ã›ã‚“ã§ã—ãŸ: {0}", "missing.url": "申ã—訳ã‚ã‚Šã¾ã›ã‚“。ã“ã®ãƒªãƒ³ã‚¯ã¯ã‚¿ãƒ¼ã‚²ãƒƒãƒˆãŒå­˜åœ¨ã—ãªã„ãŸã‚é–‹ãã“ã¨ãŒã§ãã¾ã›ã‚“ã§ã—ãŸã€‚", "label": "リンクを開ã" diff --git a/i18n/jpn/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/jpn/src/vs/workbench/electron-browser/workbench.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/jpn/src/vs/workbench/electron-browser/workbench.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json b/i18n/jpn/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json index aa4a05fcb72..ccdb00421dc 100644 --- a/i18n/jpn/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "statusBarDebuggingBackground": "プログラムをデãƒãƒƒã‚°ã—ã¦ã„ã‚‹ã¨ãã®ã‚¹ãƒ†ãƒ¼ã‚¿ã‚¹ ãƒãƒ¼ã®èƒŒæ™¯è‰²ã€‚ステータス ãƒãƒ¼ã¯ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã®ä¸‹éƒ¨ã«è¡¨ç¤ºã•ã‚Œã¾ã™" + "statusBarDebuggingBackground": "プログラムをデãƒãƒƒã‚°ã—ã¦ã„ã‚‹ã¨ãã®ã‚¹ãƒ†ãƒ¼ã‚¿ã‚¹ ãƒãƒ¼ã®èƒŒæ™¯è‰²ã€‚ステータス ãƒãƒ¼ã¯ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã®ä¸‹éƒ¨ã«è¡¨ç¤ºã•ã‚Œã¾ã™", + "statusBarDebuggingForeground": "プログラムをデãƒãƒƒã‚°ã—ã¦ã„ã‚‹ã¨ãã®ã‚¹ãƒ†ãƒ¼ã‚¿ã‚¹ ãƒãƒ¼ã®å‰æ™¯è‰²ã€‚ステータス ãƒãƒ¼ã¯ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã®ä¸‹éƒ¨ã«è¡¨ç¤ºã•ã‚Œã¾ã™" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json b/i18n/jpn/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json index b12d5ba07d8..868785478db 100644 --- a/i18n/jpn/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json @@ -22,6 +22,8 @@ "disableGloballyAction": "常ã«è¡Œã†", "disableAction": "無効ã«ã™ã‚‹", "checkForUpdates": "æ›´æ–°ã®ç¢ºèª", + "enableAutoUpdate": "拡張機能ã®è‡ªå‹•æ›´æ–°ã‚’有効ã«ã™ã‚‹", + "disableAutoUpdate": "拡張機能ã®è‡ªå‹•æ›´æ–°ã‚’無効ã«ã™ã‚‹", "updateAll": "ã™ã¹ã¦ã®æ‹¡å¼µæ©Ÿèƒ½ã‚’æ›´æ–°ã—ã¾ã™", "reloadAction": "å†èª­ã¿è¾¼ã¿", "postUpdateTooltip": "å†åº¦èª­ã¿è¾¼ã‚“ã§æ›´æ–°ã™ã‚‹", @@ -44,6 +46,8 @@ "showWorkspaceRecommendedExtensions": "ワークスペースã®ãŠã™ã™ã‚ã®æ‹¡å¼µæ©Ÿèƒ½ã‚’表示", "showRecommendedKeymapExtensions": "推奨ã®ã‚­ãƒ¼ãƒžãƒƒãƒ—を表示ã™ã‚‹", "showRecommendedKeymapExtensionsShort": "キーマップ", + "showLanguageExtensions": "言語ã®æ‹¡å¼µæ©Ÿèƒ½ã‚’表示", + "showLanguageExtensionsShort": "言語ã®æ‹¡å¼µæ©Ÿèƒ½", "configureWorkspaceRecommendedExtensions": "ãŠå‹§ã‚ã®æ‹¡å¼µæ©Ÿèƒ½ã®æ§‹æˆ (ワークスペース)", "ConfigureWorkspaceRecommendations.noWorkspace": "推奨事項ã¯ãƒ¯ãƒ¼ã‚¯ã‚¹ãƒšãƒ¼ã‚¹ フォルダーã§ã®ã¿åˆ©ç”¨å¯èƒ½ã§ã™ã€‚", "OpenExtensionsFile.failed": "'.vscode' ファルダー ({0}) 内㫠'extensions.json' ファイルを作æˆã§ãã¾ã›ã‚“。", diff --git a/i18n/jpn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/jpn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index e5b2af33ec3..6fd33bfb0e0 100644 --- a/i18n/jpn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -4,7 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "disableOtherKeymapsConfirmation": "キーãƒã‚¤ãƒ³ãƒ‰é–“ã®ç«¶åˆã‚’回é¿ã™ã‚‹ãŸã‚ã«ã€ä»–ã®ã‚­ãƒ¼ãƒžãƒƒãƒ—を無効ã«ã—ã¾ã™ã‹?", "yes": "ã¯ã„", - "no": "ã„ã„ãˆ" + "no": "ã„ã„ãˆ", + "uninstall": "アンインストール", + "later": "後続" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/jpn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 9356fa119aa..a23d7187ba2 100644 --- a/i18n/jpn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,6 +16,7 @@ "associations": "言語ã«å¯¾ã™ã‚‹ãƒ•ã‚¡ã‚¤ãƒ«ã®é–¢é€£ä»˜ã‘ (例 \"*.extension\": \"html\") を構æˆã—ã¾ã™ã€‚ã“れらã®é–¢é€£ä»˜ã‘ã¯ã€ã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã¦ã„る言語ã®æ—¢å®šã®é–¢é€£ä»˜ã‘より優先ã•ã‚Œã¾ã™ã€‚", "encoding": "ファイルã®èª­ã¿å–ã‚Š/書ãè¾¼ã¿ã§ä½¿ç”¨ã™ã‚‹æ—¢å®šã®æ–‡å­—セット エンコーディング。", "autoGuessEncoding": "有効ãªå ´åˆã€ãƒ•ã‚¡ã‚¤ãƒ«ã‚’é–‹ãã¨ãã«æ–‡å­—セット エンコードを推測ã—ã¾ã™", + "eol": "既定ã®æ”¹è¡Œæ–‡å­—。LF ã®å ´åˆã«ã¯ \\n ã‚’ CRLF ã®å ´åˆã«ã¯ \\r\\n を使用ã—ã¦ãã ã•ã„。", "trimTrailingWhitespace": "有効ã«ã™ã‚‹ã¨ã€ãƒ•ã‚¡ã‚¤ãƒ«ã®ä¿å­˜æ™‚ã«æœ«å°¾ã®ç©ºç™½ã‚’トリミングã—ã¾ã™ã€‚", "insertFinalNewline": "有効ã«ã™ã‚‹ã¨ã€ãƒ•ã‚¡ã‚¤ãƒ«ã®ä¿å­˜æ™‚ã«æœ€æ–°ã®è¡Œã‚’末尾ã«æŒ¿å…¥ã—ã¾ã™ã€‚", "files.autoSave.off": "ダーティ ファイルを自動的ã«ä¿å­˜ã™ã‚‹ã“ã¨ã¯ã—ã¾ã›ã‚“。", diff --git a/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json b/i18n/jpn/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json index 54fb4cd8f93..98112fb1164 100644 --- a/i18n/jpn/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json @@ -9,5 +9,6 @@ "vscode.extension.contributes.snippets-path": "スニペット ファイルã®ãƒ‘ス。拡張機能フォルダーã®ç›¸å¯¾ãƒ‘スã§ã‚ã‚Šã€é€šå¸¸ './snippets/' ã§å§‹ã¾ã‚Šã¾ã™ã€‚", "invalid.language": "`contributes.{0}.language` ã§ä¸æ˜Žãªè¨€èªžã§ã™ã€‚æä¾›ã•ã‚ŒãŸå€¤: {1}", "invalid.path.0": "`contributes.{0}.path` ã«æ–‡å­—列ãŒå¿…è¦ã§ã™ã€‚æä¾›ã•ã‚ŒãŸå€¤: {1}", - "invalid.path.1": "拡張機能ã®ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ ({2}) ã®ä¸­ã« `contributes.{0}.path` ({1}) ãŒå«ã¾ã‚Œã¦ã„ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™ã€‚ã“ã‚Œã«ã‚ˆã‚Šæ‹¡å¼µã‚’移æ¤ã§ããªããªã‚‹å¯èƒ½æ€§ãŒã‚ã‚Šã¾ã™ã€‚" + "invalid.path.1": "拡張機能ã®ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ ({2}) ã®ä¸­ã« `contributes.{0}.path` ({1}) ãŒå«ã¾ã‚Œã¦ã„ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™ã€‚ã“ã‚Œã«ã‚ˆã‚Šæ‹¡å¼µã‚’移æ¤ã§ããªããªã‚‹å¯èƒ½æ€§ãŒã‚ã‚Šã¾ã™ã€‚", + "badVariableUse": "スニペット \"{0}\" ã¯ã€ã‚¹ãƒ‹ãƒšãƒƒãƒˆå¤‰æ•°ã¨ã‚¹ãƒ‹ãƒšãƒƒãƒˆ プレースホルダーを混乱ã•ã›ã‚‹å¯èƒ½æ€§ãŒéžå¸¸ã«ã‚ã‚Šã¾ã™ã€‚詳細ã«ã¤ã„ã¦ã¯ https://code.visualstudio.com/docs/editor/userdefinedsnippets#_snippet-syntax ã‚’ã”覧ãã ã•ã„。" } \ No newline at end of file diff --git a/i18n/kor/src/vs/code/electron-main/windows.i18n.json b/i18n/kor/src/vs/code/electron-main/windows.i18n.json index 0756d51cd46..474475abdb1 100644 --- a/i18n/kor/src/vs/code/electron-main/windows.i18n.json +++ b/i18n/kor/src/vs/code/electron-main/windows.i18n.json @@ -7,7 +7,6 @@ "ok": "확ì¸", "pathNotExistTitle": "경로가 없습니다.", "pathNotExistDetail": "'{0}' 경로가 디스í¬ì— ë” ì´ìƒ 없는 것 같습니다.", - "accessibilityOptionsWindowTitle": "접근성 옵션", "reopen": "다시 열기", "wait": "ê³„ì† ëŒ€ê¸°", "close": "닫기", diff --git a/i18n/kor/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/kor/src/vs/workbench/electron-browser/workbench.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/kor/src/vs/workbench/electron-browser/workbench.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 86d18d9fce3..77a77543915 100644 --- a/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -4,7 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "disableOtherKeymapsConfirmation": "키 ë°”ì¸ë”© ê°„ 충ëŒì„ 피하기 위해 다른 키 ë§µì„ ì‚¬ìš©í•˜ì§€ ì•Šë„ë¡ ì„¤ì •í• ê¹Œìš”?", "yes": "예", - "no": "아니요" + "no": "아니요", + "uninstall": "제거", + "later": "나중ì—" } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/kor/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/kor/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ptb/extensions/git/out/commands.i18n.json b/i18n/ptb/extensions/git/out/commands.i18n.json index ab5667e260b..6744be04c88 100644 --- a/i18n/ptb/extensions/git/out/commands.i18n.json +++ b/i18n/ptb/extensions/git/out/commands.i18n.json @@ -26,6 +26,9 @@ "provide commit message": "Por favor, forneça uma mensagem de commit", "branch name": "Nome do Ramo", "provide branch name": "Por favor, forneça um nome de ramo", + "select branch to delete": "Selecione uma ramificação para excluir", + "confirm force delete branch": "A ramificação '{0}' não foi totalmente mesclada. Excluir mesmo assim?", + "delete branch": "Excluir ramificação", "no remotes to pull": "O seu repositório não possui remotos configurados para efetuar pull.", "no remotes to push": "O seu repositório não possui remotos configurados para efetuar push.", "nobranch": "Por favor, faça checkout em um ramo para fazer push em um remoto.", diff --git a/i18n/ptb/extensions/git/package.i18n.json b/i18n/ptb/extensions/git/package.i18n.json index 0c79f1929bb..e3eec31c008 100644 --- a/i18n/ptb/extensions/git/package.i18n.json +++ b/i18n/ptb/extensions/git/package.i18n.json @@ -26,6 +26,7 @@ "command.undoCommit": "Desfazer Ultima Confirmação", "command.checkout": "Fazer checkout para...", "command.branch": "Criar Ramificação...", + "command.deleteBranch": "Excluir Ramificação...", "command.pull": "Efetuar pull", "command.pullRebase": "Efetuar pull (Rebase)", "command.push": "Enviar por push", diff --git a/i18n/ptb/extensions/markdown/out/extension.i18n.json b/i18n/ptb/extensions/markdown/out/extension.i18n.json index 8b6ad71cd4e..0f4d1689d7f 100644 --- a/i18n/ptb/extensions/markdown/out/extension.i18n.json +++ b/i18n/ptb/extensions/markdown/out/extension.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "onPreviewStyleLoadError": "Não foi possível carregar o 'markdown.styles': {0}" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/ptb/extensions/merge-conflict/out/codelensProvider.i18n.json index 8b6ad71cd4e..dd5a316f1a1 100644 --- a/i18n/ptb/extensions/merge-conflict/out/codelensProvider.i18n.json +++ b/i18n/ptb/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -3,4 +3,9 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "acceptCurrentChange": "Aceitar a mudança atual", + "acceptIncomingChange": "Aceitar a mudança de entrada", + "acceptBothChanges": "Aceitar ambas alterações", + "compareChanges": "Comparar alteracões" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/ptb/extensions/merge-conflict/out/commandHandler.i18n.json index 8b6ad71cd4e..ee80b2e1905 100644 --- a/i18n/ptb/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/ptb/extensions/merge-conflict/out/commandHandler.i18n.json @@ -3,4 +3,10 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "cursorNotInConflict": "Cursor do editor não está dentro de um conflito de mesclagem", + "compareChangesTitle": "{0}: Mudanças atuais \\u2194 alterações de entrada ", + "cursorOnSplitterRange": "Cursor do editor está dentro do separador de conflitos de mesclagem, por favor mova-o para o bloco \"atual\" ou \"entrada\"", + "noConflicts": "Nenhum conflito de mesclagem encontrado neste arquivo", + "noOtherConflictsInThisFile": "Não há outros conflitos de mesclagem dentro desse arquivo" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/ptb/extensions/merge-conflict/out/mergeDecorator.i18n.json index 8b6ad71cd4e..a3da6d4660e 100644 --- a/i18n/ptb/extensions/merge-conflict/out/mergeDecorator.i18n.json +++ b/i18n/ptb/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "currentChange": "(Mudança atual)", + "incomingChange": "(Mudança de entrada)" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/merge-conflict/package.i18n.json b/i18n/ptb/extensions/merge-conflict/package.i18n.json index 8b6ad71cd4e..b290f272513 100644 --- a/i18n/ptb/extensions/merge-conflict/package.i18n.json +++ b/i18n/ptb/extensions/merge-conflict/package.i18n.json @@ -3,4 +3,18 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "command.category": "Conflito de Mesclagem", + "command.accept.all-incoming": "Aceitar todas as novas entradas", + "command.accept.all-both": "Aceitar Ambos", + "command.accept.current": "Aceitar a atual", + "command.accept.incoming": "Aceitar as novas entradas", + "command.accept.selection": "Aceitar a seleção", + "command.accept.both": "Aceitar Ambos", + "command.next": "Próximo conflito", + "command.previous": "Conflito anterior", + "command.compare": "Comparar o conflito atual", + "config.title": "Mesclar conflitos", + "config.codeLensEnabled": "Habilitar/Desabilitar o conflito de mesclagem no bloco CodeLens dentro do editor", + "config.decoratorsEnabled": "Habilitar/Desabilitar decoradores de mesclagem de conflitos dentro do editor" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/npm/package.i18n.json b/i18n/ptb/extensions/npm/package.i18n.json index 8b6ad71cd4e..8d33aa31e7f 100644 --- a/i18n/ptb/extensions/npm/package.i18n.json +++ b/i18n/ptb/extensions/npm/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.npm.autoDetect": "Controla se a deteção automática de scripts npm está ligado ou desligado. O padrão é ligado." +} \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/package.i18n.json b/i18n/ptb/extensions/typescript/package.i18n.json index 5e4125ec050..74b4568f8b9 100644 --- a/i18n/ptb/extensions/typescript/package.i18n.json +++ b/i18n/ptb/extensions/typescript/package.i18n.json @@ -37,6 +37,7 @@ "typescript.referencesCodeLens.enabled": "Habilitar/desabilitar referências CodeLens em arquivos TypeScript. Requer TypeScript > = 2.0.6.", "typescript.implementationsCodeLens.enabled": "Habilitar/desabilitar implementações CodeLens. Requer TypeScript > = 2.0.6.", "typescript.openTsServerLog.title": "Abrir arquivo de log do servidor TS", + "typescript.restartTsServer": "Reiniciar o servidor TS", "typescript.selectTypeScriptVersion.title": "Selecionar a versão do JavaScript", "jsDocCompletion.enabled": "Habilitar/Desabilitar comentários JSDoc automáticos.", "javascript.implicitProjectConfig.checkJs": "Habilitar/desabilitar verificação semântica de arquivos JavaScript. Os arquivos existentes jsconfig.json ou tsconfig.json substituem essa configuração. Requer TypeScript > = 2.3.1.", diff --git a/i18n/ptb/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/ptb/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index d023184ae70..ff9f2c98cbb 100644 --- a/i18n/ptb/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/ptb/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,6 +6,7 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "A imagem é muito grande para ser exibida no editor.", + "resourceOpenExternalButton": "Abrir imagem usando um programa externo?", "nativeBinaryError": "O arquivo não pode ser exibido no editor porque é binário, muito grande ou usa uma codificação de texto sem suporte.", "sizeB": "{0}B", "sizeKB": "{0}KB", diff --git a/i18n/ptb/src/vs/code/electron-main/windows.i18n.json b/i18n/ptb/src/vs/code/electron-main/windows.i18n.json index 308aed29538..abf3a42e2eb 100644 --- a/i18n/ptb/src/vs/code/electron-main/windows.i18n.json +++ b/i18n/ptb/src/vs/code/electron-main/windows.i18n.json @@ -7,7 +7,6 @@ "ok": "OK", "pathNotExistTitle": "O caminho não existe", "pathNotExistDetail": "O caminho '{0}' não parece mais existir no disco.", - "accessibilityOptionsWindowTitle": "Opções de Acessibilidade", "reopen": "Reabrir", "wait": "Continuar Esperando", "close": "Fechar", diff --git a/i18n/ptb/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/ptb/src/vs/editor/common/config/commonEditorConfig.i18n.json index 8411a930363..32deba05d12 100644 --- a/i18n/ptb/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/ptb/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -23,6 +23,8 @@ "minimap.enabled": "Controla se o mini mapa é exibido", "minimap.renderCharacters": "Renderizar os caracteres em uma linha (em oposição a blocos de caracteres)", "minimap.maxColumn": "Limitar o tamanho de um mini-mapa para renderizar no máximo um número determinado de colunas", + "find.seedSearchStringFromSelection": "Controla se nós inicializamos a string de pesquisa na Ferramenta de Pesquisa a partir da seleção do editor", + "find.autoFindInSelection": "Controla se a configuração Find in Selection deve estar ativada quando vários caracteres ou linhas de texto estão selecionados no editor", "wordWrap.off": "As linhas nunca serão quebradas.", "wordWrap.on": "As linhas serão quebradas na largura de visualização", "wordWrap.wordWrapColumn": "As linhas serão quebradas em `editor.wordWrapColumn`.", @@ -31,6 +33,7 @@ "wordWrapColumn": "Controla a coluna de quebra de linha do editor quando editor.wordWrap` é 'wordWrapColumn' ou 'bounded'.", "wrappingIndent": "Controla o recuo de linhas quebradas. Pode ser \"none\", \"same\" ou \"indent\".", "mouseWheelScrollSensitivity": "Um multiplicador a ser usado em \"deltaX\" e \"deltaY\" dos eventos de rolagem do botão de rolagem do mouse", + "multicursorModifier": "O modificador a ser utilizado para adicionar vários cursores com o mouse.", "quickSuggestions.strings": "Habilitar sugestões rápidas dentro de strings.", "quickSuggestions.comments": "Habilitar sugestões rápidas dentro de comentários.", "quickSuggestions.other": "Habilitar sugestões rápidas fora de strings e comentários.", @@ -41,6 +44,7 @@ "formatOnType": "Controla se o editor deve formatar automaticamente a linha após a digitação", "formatOnPaste": "Controla se o editor deve formatar automaticamente o conteúdo colado. Um formatador deve estar disponível e o formatador deve ser capaz de formatar apenas uma parte do documento.", "suggestOnTriggerCharacters": "Controla se as sugestões devem aparecer automaticamente ao digitar caracteres de gatilho", + "acceptSuggestionOnEnter": "Controla se as sugestões devem ser aceitas com 'Enter' - em adição a 'Tab'. Ajuda a evitar a ambiguidade entre a inserção de novas linhas ou aceitar sugestões. O valor 'smart' significa apenas aceitar uma sugestão com Enter quando ela fizer uma mudança textual", "acceptSuggestionOnCommitCharacter": "Controla se as sugestões devem ser aceitas em caracteres de confirmação. Por exemplo, em JavaScript, o ponto-e-vírgula (';') pode ser um caractere de confirmação que aceita uma sugestão e digita esse caractere.", "snippetSuggestions": "Controla se os snippets são exibidos juntamente com as outras sugestões e como eles são ordenados.", "emptySelectionClipboard": "Controla se a cópia sem nenhuma seleção copia a linha atual.", diff --git a/i18n/ptb/src/vs/editor/common/view/editorColorRegistry.i18n.json b/i18n/ptb/src/vs/editor/common/view/editorColorRegistry.i18n.json index 8d59b0fcb7d..a1bf17d6ec8 100644 --- a/i18n/ptb/src/vs/editor/common/view/editorColorRegistry.i18n.json +++ b/i18n/ptb/src/vs/editor/common/view/editorColorRegistry.i18n.json @@ -16,5 +16,9 @@ "editorBracketMatchBackground": "Cor de fundo atrás do colchetes correspondentes", "editorBracketMatchBorder": "Cor para as caixas de colchetes correspondentes", "editorOverviewRulerBorder": "Cor da borda da régua de visão geral.", - "editorGutter": "Cor de fundo da separação do editor.O separador contém os glifos das margens e os números de linha." + "editorGutter": "Cor de fundo da separação do editor.O separador contém os glifos das margens e os números de linha.", + "errorForeground": "Cor do primeiro plano das linhas onduladas de erro no editor.", + "errorBorder": "Cor da borda das linhas onduladas de erro no editor.", + "warningForeground": "Cor do primeiro plano de linhas onduladas de aviso no editor.", + "warningBorder": "Cor da borda das linhas onduladas de aviso no editor." } \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/links/browser/links.i18n.json b/i18n/ptb/src/vs/editor/contrib/links/browser/links.i18n.json index 64628273f2a..32cd9d3212a 100644 --- a/i18n/ptb/src/vs/editor/contrib/links/browser/links.i18n.json +++ b/i18n/ptb/src/vs/editor/contrib/links/browser/links.i18n.json @@ -6,6 +6,7 @@ { "links.navigate.mac": "Cmd + clique para seguir o link", "links.navigate": "Ctrl + clique para seguir o link", + "links.navigate.al": "Alt + clique para seguir o link", "invalid.url": "Desculpe, falha ao abrir este link porque ele não está bem formatado: {0}", "missing.url": "Desculpe, falha ao abrir este link porque seu destino está faltando.", "label": "Abrir link" diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json index c2057c183a1..ff6a038e701 100644 --- a/i18n/ptb/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json @@ -11,6 +11,7 @@ "endOfLineLineFeed": "LF", "endOfLineCarriageReturnLineFeed": "CRLF", "tabFocusModeEnabled": "Tabulação move o foco", + "screenReaderDetected": "Leitor de tela detectado", "disableTabMode": "Desativar o modo de acessibilidade", "gotoLine": "Ir para linha", "indentation": "Indentação", diff --git a/i18n/ptb/src/vs/workbench/common/theme.i18n.json b/i18n/ptb/src/vs/workbench/common/theme.i18n.json index bfe4c0ef017..635ace8d708 100644 --- a/i18n/ptb/src/vs/workbench/common/theme.i18n.json +++ b/i18n/ptb/src/vs/workbench/common/theme.i18n.json @@ -11,6 +11,7 @@ "tabInactiveEditorGroupActiveForeground": "Cor de primeiro plano da guia inativa em um grupo ativo. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", "editorGroupBackground": "Cor de fundo de um grupo de editor. Grupos de editor são os recipientes dos editores. A cor de fundo é mostrada ao arrastar o editor de grupos ao redor.", "tabsContainerBackground": "Cor de fundo do cabeçalho do título do grupo de editor quando as guias são habilitadas. Grupos de editor são os recipientes dos editores.", + "tabsContainerBorder": "Cor da borda do cabeçalho do título do grupo de editor quando as guias estão habilitadas. Grupos de editor são os recipientes dos editores.", "editorGroupHeaderBackground": "Cor de fundo do título do cabeçalho do grupo de editor quando as guias são desabilitadas. Grupos de editor são os recipientes dos editores.", "editorGroupBorder": "Cor para separar múltiplos grupos de editor de outro. Grupos de editor são os recipientes dos editores.", "editorDragAndDropBackground": "Cor de fundo ao arrastar editores. A cor deve ter transparência para que o conteúdo do editor ainda possa ser visto.", @@ -21,20 +22,25 @@ "panelActiveTitleBorder": "Cor da borda para o título do painel ativo. Os painéis são mostrados abaixo da área do editor e contém visualizações como saída e terminal integrado.", "statusBarForeground": "Cor do primeiro plano da barra de status. A barra de status é mostrada na parte inferior da janela.", "statusBarBackground": "Cor de fundo da barra de status padrão. A barra de status é mostrada na parte inferior da janela.", + "statusBarBorder": "Cor da borda da barra de status que separa a barra lateral e o editor.A barra de status é mostrada na parte inferior da janela.", "statusBarNoFolderBackground": "Cor de fundo da barra de status quando nenhuma pasta está aberta. A barra de status é mostrada na parte inferior da janela.", + "statusBarNoFolderForeground": "Cor do primeiro plano da barra de status quando nenhuma pasta está aberta. A barra de status é mostrada na parte inferior da janela.", "statusBarItemActiveBackground": "Cor de fundo do item da barra de status quando você clicado. A barra de status é mostrada na parte inferior da janela.", "statusBarItemHoverBackground": "Cor de fundo do item da barra de status quando estiver passando sobre ele. A barra de status é mostrada na parte inferior da janela.", "statusBarProminentItemBackground": "Cor de fundo de itens proeminentes da barra de status. Itens proeminentes destacam-se outras entradas da barra de status para indicar a importância. A barra de status é mostrada na parte inferior da janela.", "statusBarProminentItemHoverBackground": "Cor de fundo dos itens proeminentes de barra de status quando estiver passando sobre eles. Itens proeminentes destacam-se outras entradas de barra de status para indicar a importância. A barra de status é mostrada na parte inferior da janela.", "activityBarBackground": "Cor de fundo da barra de atividades. Barra de atividade está visível à esquerda ou à direita e permite alternar entre as visualizações da barra lateral.", "activityBarForeground": "Cor de primeiro plano da barra de atividades (por exemplo, usada para os ícones). A barra de atividades está visível à esquerda ou à direita e permite alternar entre as visualizações da barra lateral.", + "activityBarBorder": "Cor da borda da barra de atividades separando a barra lateral. A barra de atividade é mostrada à esquerda ou à direita e permite alternar entre as visualizações da barra lateral.", "activityBarDragAndDropBackground": "Cor de feedback de arrastar e soltar para os itens da barra de atividades. A cor deve ter transparência para que as entradas de bar de atividade ainda possam brilhar. A barra de atividade está visível à esquerda ou à direita e permite para alternar entre as visualizações da barra lateral.", "activityBarBadgeBackground": "Cor de fundo da notificação de atividade. A barra de atividade está visível à esquerda ou à direita e permite alternar entre as visualizações da barra lateral.", "activityBarBadgeForeground": "Cor de primeiro plano da notificação de atividade. A barra de atividade está visível à esquerda ou à direita e permite alternar entre as visualizações da barra lateral.", "sideBarBackground": "Cor de fundo da barra lateral. A barra lateral é o recipiente para visualizações como explorador e pesquisa.", "sideBarForeground": "Cor de primeiro plano da barra lateral. A barra lateral é o recipiente para visualizações como o explorador e a busca.", + "sideBarBorder": "Cor da borda da barra lateral separando o editor. A barra lateral é o recipiente para visualizações como explorador e pesquisa.", "sideBarTitleForeground": "Cor de primeiro plano do título da barra lateral. A barra lateral é o recipiente para visualizações como explorador e pesquisa.", "sideBarSectionHeaderBackground": "Cor de fundo do cabeçalho de seção lateral. A barra lateral é o recipiente para visões como explorador e pesquisa.", + "sideBarSectionHeaderForeground": "Cor de primeiro plano do cabeçalho de seção da barra lateral. A barra lateral é o recipiente para visualizações como o explorador e pesquisa.", "titleBarActiveForeground": "Cor da barra de título do primeiro plano quando a janela está ativa. Observe que essa cor atualmente somente é suportada no macOS.", "titleBarInactiveForeground": "Cor de primeiro plano da barra de título quando a janela está inativa. Observe que essa cor atualmente somente é suportada no macOS.", "titleBarActiveBackground": "Cor de fundo da barra de título quando a janela está ativa. Observe que essa cor atualmente somente é suportada no macOS.", diff --git a/i18n/ptb/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/ptb/src/vs/workbench/electron-browser/workbench.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ptb/src/vs/workbench/electron-browser/workbench.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json index b191a0de856..86bf6e71ecc 100644 --- a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "statusBarDebuggingBackground": "Cor de fundo da barra de status quando um programa está sendo depurado. A barra de status é mostrada na parte inferior da janela" + "statusBarDebuggingBackground": "Cor de fundo da barra de status quando um programa está sendo depurado. A barra de status é mostrada na parte inferior da janela", + "statusBarDebuggingForeground": "Cor de primeiro plano da barra de status quando um programa está sendo depurado. A barra de status é mostrada na parte inferior da janela" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json index 1caebe040f5..7f32e3bf156 100644 --- a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json @@ -9,5 +9,6 @@ "emmetPreferences": "Preferências usadas para modificar o comportamento de algumas ações e resolvedores de Emmet.", "emmetSyntaxProfiles": "Definir o perfil para a sintaxe especificada ou usar seu próprio perfil com regras específicas.", "emmetExclude": "Uma matriz de línguagens onde abreviaturas emmet não devem ser expandidas.", - "emmetExtensionsPath": "Caminho para uma pasta contendo perfis emmet, trechos e preferências" + "emmetExtensionsPath": "Caminho para uma pasta contendo perfis emmet, trechos e preferências", + "emmetUseModules": "Use os novos módulos emmet para características emmet ao invés da biblioteca emmet única." } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json index e2ff606a7c9..61966d0e312 100644 --- a/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json @@ -22,6 +22,8 @@ "disableGloballyAction": "Sempre", "disableAction": "Desabilitar", "checkForUpdates": "Verificar Atualizações", + "enableAutoUpdate": "Habilitar Extensões Auto-Atualizáveis", + "disableAutoUpdate": "Desabilitar Extensões Auto-Atualizáveis", "updateAll": "Atualizar Todas as Extensões", "reloadAction": "Recarregar", "postUpdateTooltip": "Recarregar para atualizar", @@ -44,6 +46,8 @@ "showWorkspaceRecommendedExtensions": "Mostrar Extensões Recomendadas para o Espaço de Trabalho", "showRecommendedKeymapExtensions": "Mostrar Mapeamentos de Teclado Recomendados", "showRecommendedKeymapExtensionsShort": "Mapeamentos de Teclado", + "showLanguageExtensions": "Mostrar Extensões de Linguagem", + "showLanguageExtensionsShort": "Extensões de Linguagem", "configureWorkspaceRecommendedExtensions": "Configurar Extensões Recomendadas (Espaço de Trabalho)", "ConfigureWorkspaceRecommendations.noWorkspace": "As recomendações somente estão disponíveis em uma pasta do espaço de trabalho.", "OpenExtensionsFile.failed": "Não foi possível criar o arquivo 'extensions.json' na pasta '.vscode' ({0}).", @@ -51,5 +55,8 @@ "disableAll": "Desabilitar Todas as Extensões Instaladas", "disableAllWorkspace": "Desabilitar Todas as Extensões Instaladas para este Espaço de Trabalho", "enableAll": "Habilitar Todas as Extensões Instaladas", - "enableAllWorkspace": "Habilitar Todas as Extensões Instaladas para este Espaço de Trabalho" + "enableAllWorkspace": "Habilitar Todas as Extensões Instaladas para este Espaço de Trabalho", + "extensionButtonProminentBackground": "Cor de fundo do botão para a ações de extensão que se destacam (por exemplo, o botão de instalar).", + "extensionButtonProminentForeground": "Cor de primeiro plano do botão para a ações de extensão que se destacam (por exemplo, o botão de instalar).", + "extensionButtonProminentHoverBackground": "Cor de fundo ao passar o mouse sobre o botão para a ações de extensão que se destacam (por exemplo, o botão de instalar)." } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 0cde76b12d8..7e8cde2d602 100644 --- a/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -4,7 +4,9 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "disableOtherKeymapsConfirmation": "Desabilitar outros mapeamentos de teclado para evitar conflitos entre mapeamentos de teclado?", "yes": "Sim", - "no": "Não" + "no": "Não", + "betterMergeDisabled": "A extensão Better Merge agora é intrínseca, a extensão instalada foi desabilitada e pode ser desinstalada.", + "uninstall": "Desinstalar", + "later": "Mais tarde" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index ddbc9408f54..f4309c6a9bc 100644 --- a/i18n/ptb/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,6 +16,7 @@ "associations": "Configurar as associações de arquivo para linguagens (por exemplo, \"* Extension\": \"html\"). Estas têm precedência sobre as associações padrão das linguagens instaladas.", "encoding": "A codificação padrão do conjunto de caracteres para ser usada ao ler e gravar arquivos.", "autoGuessEncoding": "Quando habilitado, tentará adivinhar a codificação do conjunto de caracteres ao abrir arquivos", + "eol": "O caractere padrão de fim de linha. Use \\n para LF e \\r\\n para CRLF.", "trimTrailingWhitespace": "Quando habilitado, removerá espaços em branco à direita ao salvar um arquivo.", "insertFinalNewline": "Quando habilitado, inseririrá uma nova linha no final do arquivo quando salvá-lo.", "files.autoSave.off": "Um arquivo sujo nunca é automaticamente salvo.", diff --git a/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json index 0f8e6360187..b98cf8d0937 100644 --- a/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json @@ -9,5 +9,6 @@ "vscode.extension.contributes.snippets-path": "Caminho do arquivo de trechos de código. O caminho é relativo à pasta de extensão e normalmente começa com '. /snippets/'.", "invalid.language": "Linguagem desconhecida em `contributes.{0}.language`. Valor fornecido: {1}", "invalid.path.0": "Esperada uma string em `contributes.{0}.path`. Valor informado: {1}", - "invalid.path.1": "É esperado que `contributes.{0}.path` ({1}) seja incluído na pasta da extensão ({2}). Isto pode tornar a extensão não portável." + "invalid.path.1": "É esperado que `contributes.{0}.path` ({1}) seja incluído na pasta da extensão ({2}). Isto pode tornar a extensão não portável.", + "badVariableUse": "O trecho de código \"{0}\" muito provavelmente confunde as variáveis de trecho de código e espaços reservados do trecho de código. Consulte https://code.visualstudio.com/docs/editor/userdefinedsnippets#_snippet-syntax para obter mais detalhes." } \ No newline at end of file diff --git a/i18n/rus/src/vs/code/electron-main/windows.i18n.json b/i18n/rus/src/vs/code/electron-main/windows.i18n.json index 6a621782e32..b1934cff062 100644 --- a/i18n/rus/src/vs/code/electron-main/windows.i18n.json +++ b/i18n/rus/src/vs/code/electron-main/windows.i18n.json @@ -7,7 +7,6 @@ "ok": "ОК", "pathNotExistTitle": "Путь не ÑущеÑтвует.", "pathNotExistDetail": "Путь \"{0}\" больше не ÑущеÑтвует на диÑке.", - "accessibilityOptionsWindowTitle": "Специальные возможноÑти", "reopen": "Открыть повторно", "wait": "Подождать", "close": "Закрыть", diff --git a/i18n/rus/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/rus/src/vs/workbench/electron-browser/workbench.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/rus/src/vs/workbench/electron-browser/workbench.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 906d10fee6b..82ee62547a4 100644 --- a/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -4,7 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "disableOtherKeymapsConfirmation": "Отключить другие раÑкладки клавиатуры, чтобы избежать конфликта между наÑтраиваемыми ÑочетаниÑми клавиш?", "yes": "Да", - "no": "Ðет" + "no": "Ðет", + "uninstall": "Удаление", + "later": "Позже" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/rus/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/rus/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file -- GitLab From 8c1c1d14df3c2f819078484aeffee37c3f00a7a8 Mon Sep 17 00:00:00 2001 From: Erich Gamma Date: Sun, 28 May 2017 17:29:39 +0200 Subject: [PATCH 0229/1347] Added npm install to the list of discovered npm tasks --- extensions/npm/src/main.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/extensions/npm/src/main.ts b/extensions/npm/src/main.ts index 9308210ede8..9dc734a4ffe 100644 --- a/extensions/npm/src/main.ts +++ b/extensions/npm/src/main.ts @@ -90,6 +90,8 @@ async function getNpmScriptsAsTasks(): Promise { } result.push(task); }); + // add some 'well known' npm tasks + result.push(new vscode.ShellTask(`npm: install`, `npm install`)); return Promise.resolve(result); } catch (e) { return Promise.resolve(emptyTasks); -- GitLab From 4b2a13aae48e8cdc1485c31d1ac4ecfa37094b69 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Mon, 29 May 2017 09:06:04 +0200 Subject: [PATCH 0230/1347] Make the workspace build / test task win over contributed tasks --- .../parts/tasks/common/taskConfiguration.ts | 39 +++++++++++++------ .../electron-browser/task.contribution.ts | 30 +++++++++----- .../tasks/test/node/configuration.test.ts | 25 +++++++++++- 3 files changed, 71 insertions(+), 23 deletions(-) diff --git a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts index 9af9833e240..09fa78dfd77 100644 --- a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts +++ b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts @@ -137,11 +137,18 @@ export interface TaskDescription extends PlatformTaskDescription { promptOnClose?: boolean; /** + * Defines the group the task belongs too. + */ + group?: string; + + /** + * @deprecated Use `group` instead. * Whether this task maps to the default build command. */ isBuildCommand?: boolean; /** + * @deprecated Use `group` instead. * Whether this task maps to the default test command. */ isTestCommand?: boolean; @@ -766,8 +773,8 @@ namespace TaskDescription { } let parsedTasks: Tasks.Task[] = []; let annotatingTasks: Tasks.Task[] = []; - let defaultBuildTask: { task: Tasks.Task; rank: number; } = { task: null, rank: -1 }; - let defaultTestTask: { task: Tasks.Task; rank: number; } = { task: null, rank: -1 }; + let defaultBuildTask: { task: Tasks.Task; rank: number; } = { task: undefined, rank: -1 }; + let defaultTestTask: { task: Tasks.Task; rank: number; } = { task: undefined, rank: -1 }; tasks.forEach((externalTask) => { let taskName = externalTask.taskName; if (!taskName) { @@ -800,6 +807,16 @@ namespace TaskDescription { if (externalTask.promptOnClose !== void 0) { task.promptOnClose = !!externalTask.promptOnClose; } + if (Tasks.TaskGroup.is(externalTask.group)) { + task.group = externalTask.group; + } + if (task.group === void 0) { + if (Types.isBoolean(externalTask.isBuildCommand) && externalTask.isBuildCommand) { + task.group = Tasks.TaskGroup.Build; + } else if (Types.isBoolean(externalTask.isTestCommand && externalTask.isTestCommand)) { + task.group = Tasks.TaskGroup.Test; + } + } if (externalTask.command !== void 0) { // if the task has its own command then we suppress the // task name by default. @@ -848,26 +865,24 @@ namespace TaskDescription { } if (addTask) { parsedTasks.push(task); - if (!Types.isUndefined(externalTask.isBuildCommand) && externalTask.isBuildCommand && defaultBuildTask.rank < 2) { + if (task.group === Tasks.TaskGroup.Build && defaultBuildTask.rank < 2) { defaultBuildTask.task = task; defaultBuildTask.rank = 2; - } else if (taskName === 'build' && defaultBuildTask.rank < 2) { - defaultBuildTask.task = task; - defaultBuildTask.rank = 1; - } - if (!Types.isUndefined(externalTask.isTestCommand) && externalTask.isTestCommand && defaultTestTask.rank < 2) { + } else if (task.group === Tasks.TaskGroup.Test && defaultTestTask.rank < 2) { defaultTestTask.task = task; defaultTestTask.rank = 2; - } else if (taskName === 'test' && defaultTestTask.rank < 2) { + } else if (task.name === 'build' && defaultBuildTask.rank < 1) { + defaultBuildTask.task = task; + defaultBuildTask.rank = 1; + } else if (task.name === 'test' && defaultTestTask.rank < 1) { defaultTestTask.task = task; defaultTestTask.rank = 1; } } }); - if (defaultBuildTask.task) { + if (defaultBuildTask.rank > -1 && defaultBuildTask.rank < 2) { defaultBuildTask.task.group = Tasks.TaskGroup.Build; - } - if (defaultTestTask.task) { + } else if (defaultTestTask.rank > -1 && defaultTestTask.rank < 2) { defaultTestTask.task.group = Tasks.TaskGroup.Test; } return parsedTasks.length === 0 && annotatingTasks.length === 0 ? undefined : { tasks: parsedTasks, annotatingTasks: annotatingTasks }; diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index 49c14ca2110..68b32dfc244 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -740,21 +740,21 @@ class TaskService extends EventEmitter implements ITaskService { let uuidMap: IStringDictionary = Object.create(null); let identifierMap: IStringDictionary = Object.create(null); - let primaryTasks: Task[] = []; + let workspaceTasks: Task[] = []; + let extensionTasks: Task[] = []; sets.forEach((set) => { set.tasks.forEach((task) => { uuidMap[task._id] = task; identifierMap[task.identifier] = task; if (group && task.group === group) { - primaryTasks.push(task); + if (task._source.kind === TaskSourceKind.Workspace) { + workspaceTasks.push(task); + } else { + extensionTasks.push(task); + } } }); }); - if (primaryTasks.length === 0) { - return undefined; - } - // check for a WORKSPACE build task and use that onemptied.apply - let resolver: ITaskResolver = { resolve: (id: string) => { let result = uuidMap[id]; @@ -764,8 +764,18 @@ class TaskService extends EventEmitter implements ITaskService { return identifierMap[id]; } }; - if (primaryTasks.length === 1) { - return { task: primaryTasks[0], resolver }; + if (workspaceTasks.length > 0) { + if (workspaceTasks.length > 1) { + this._outputChannel.append(nls.localize('moreThanOneBuildTask', 'There are many build tasks defined in the tasks.json. Executing the first one.\n')); + } + return { task: workspaceTasks[0], resolver }; + } + if (extensionTasks.length === 0) { + return undefined; + } + + if (extensionTasks.length === 1) { + return { task: extensionTasks[0], resolver }; } else { let id: string = UUID.generateUuid(); let task: Task = { @@ -773,7 +783,7 @@ class TaskService extends EventEmitter implements ITaskService { _source: { kind: TaskSourceKind.Generic }, name: id, identifier: id, - dependsOn: primaryTasks.map(task => task._id), + dependsOn: extensionTasks.map(task => task._id), command: undefined, }; return { task, resolver }; diff --git a/src/vs/workbench/parts/tasks/test/node/configuration.test.ts b/src/vs/workbench/parts/tasks/test/node/configuration.test.ts index 03610ad7ecc..cbccf978e9d 100644 --- a/src/vs/workbench/parts/tasks/test/node/configuration.test.ts +++ b/src/vs/workbench/parts/tasks/test/node/configuration.test.ts @@ -512,7 +512,7 @@ function assertProblemPattern(actual: ProblemPattern, expected: ProblemPattern) assert.strictEqual(actual.loop, expected.loop); } -suite('Tasks Configuration parsing tests', () => { +suite('Tasks version 0.1.0', () => { test('tasks: all default', () => { let builder = new ConfiguationBuilder(); builder.task('tsc', 'tsc'). @@ -1360,6 +1360,29 @@ suite('Tasks Configuration parsing tests', () => { }); }); +suite('Tasks version 2.0.0', () => { + test('Build workspace task', () => { + let external: ExternalTaskRunnerConfiguration = { + version: '2.0.0', + tasks: [ + { + taskName: 'dir', + command: 'dir', + type: 'shell', + group: 'build' + } + ] + }; + let builder = new ConfiguationBuilder(); + builder.task('dir', 'dir'). + suppressTaskName(true). + group(Tasks.TaskGroup.Build). + command().type(Tasks.CommandType.Shell); + testConfiguration(external, builder); + }); + +}); + suite('Bugs / regression tests', () => { test('Bug 19548', () => { if (Platform.isLinux) { -- GitLab From 2fa17a91dab942b8466ed2960b170c67f088ab23 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Mon, 29 May 2017 09:08:57 +0200 Subject: [PATCH 0231/1347] Added script to compile. --- test/smoke/package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/test/smoke/package.json b/test/smoke/package.json index 4f637a5adf7..eb58965b87c 100644 --- a/test/smoke/package.json +++ b/test/smoke/package.json @@ -3,6 +3,7 @@ "version": "0.1.0", "main": "./src/main.js", "scripts": { + "compile": "tsc", "pretest": "tsc", "test": "node src/main.js" }, -- GitLab From 60328f1db18b81ce53a21ecb82e4861fffa41a0e Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Mon, 29 May 2017 09:31:59 +0200 Subject: [PATCH 0232/1347] Revert "theming - remove hardcoded list color in keybindings editor" This reverts commit 84ced6126ea370a757fbff264f106af319029257. --- .../parts/preferences/browser/media/keybindingsEditor.css | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/vs/workbench/parts/preferences/browser/media/keybindingsEditor.css b/src/vs/workbench/parts/preferences/browser/media/keybindingsEditor.css index 9932877ef4d..94a771ce087 100644 --- a/src/vs/workbench/parts/preferences/browser/media/keybindingsEditor.css +++ b/src/vs/workbench/parts/preferences/browser/media/keybindingsEditor.css @@ -68,6 +68,12 @@ display: flex; } +.keybindings-editor > .keybindings-body > .keybindings-list-container .monaco-list-row.even:not(.focused):not(.selected):not(:hover), +.keybindings-editor > .keybindings-body > .keybindings-list-container .monaco-list:not(:focus) .monaco-list-row.focused.even:not(.selected):not(:hover), +.keybindings-editor > .keybindings-body > .keybindings-list-container .monaco-list:not(.focused) .monaco-list-row.focused.even:not(.selected):not(:hover) { + background-color: rgba(130, 130, 130, 0.04); +} + .keybindings-editor > .keybindings-body .keybindings-list-container .monaco-list-row > .header { text-align: left; font-weight: bold; -- GitLab From 3c1f7878b2d3114483d09c5ee8490d3cf27ec0b2 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Mon, 29 May 2017 10:50:34 +0200 Subject: [PATCH 0233/1347] theming - remove panel.background as we currently do not support it end to end --- extensions/theme-abyss/themes/abyss-color-theme.json | 1 - .../theme-quietlight/themes/quietlight-color-theme.json | 1 - .../themes/solarized-dark-color-theme.json | 1 - .../themes/solarized-light-color-theme.json | 1 - src/vs/workbench/browser/parts/panel/panelPart.ts | 6 +++--- src/vs/workbench/common/theme.ts | 6 ------ 6 files changed, 3 insertions(+), 13 deletions(-) diff --git a/extensions/theme-abyss/themes/abyss-color-theme.json b/extensions/theme-abyss/themes/abyss-color-theme.json index b244eb1cd6a..a67dd83b89d 100644 --- a/extensions/theme-abyss/themes/abyss-color-theme.json +++ b/extensions/theme-abyss/themes/abyss-color-theme.json @@ -375,7 +375,6 @@ // "activityBar.dropBackground": "", // Workbench: Panel - // "panel.background": "", "panel.border": "#2b2b4a", // "panelTitle.activeBorder": "", // "panelTitle.activeForeground": "", diff --git a/extensions/theme-quietlight/themes/quietlight-color-theme.json b/extensions/theme-quietlight/themes/quietlight-color-theme.json index db8f30e0db2..3086021874b 100644 --- a/extensions/theme-quietlight/themes/quietlight-color-theme.json +++ b/extensions/theme-quietlight/themes/quietlight-color-theme.json @@ -465,7 +465,6 @@ "editorWhitespace.foreground": "#AAAAAA", "editor.lineHighlightBackground": "#E4F6D4", "editor.selectionBackground": "#C9D0D9", - "panel.background": "#F5F5F5", "sideBar.background": "#F2F2F2", "sideBarSectionHeader.background": "#ede8ef", "editorLineNumber.foreground": "#9DA39A", diff --git a/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json b/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json index c89667099de..10b058c4911 100644 --- a/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json +++ b/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json @@ -419,7 +419,6 @@ // "activityBarBadge.foreground": "", // Workbench: Panel - // "panel.background": "", "panel.border": "#2b2b4a", // "panelTitle.activeBorder": "", // "panelTitle.activeForeground": "", diff --git a/extensions/theme-solarized-light/themes/solarized-light-color-theme.json b/extensions/theme-solarized-light/themes/solarized-light-color-theme.json index 0c3123614c0..cebad7db3b2 100644 --- a/extensions/theme-solarized-light/themes/solarized-light-color-theme.json +++ b/extensions/theme-solarized-light/themes/solarized-light-color-theme.json @@ -419,7 +419,6 @@ // "activityBarBadge.foreground": "", // Workbench: Panel - // "panel.background": "", "panel.border": "#DDD6C1", // "panelTitle.activeBorder": "", // "panelTitle.activeForeground": "", diff --git a/src/vs/workbench/browser/parts/panel/panelPart.ts b/src/vs/workbench/browser/parts/panel/panelPart.ts index f163fd6aa15..33c4fabe884 100644 --- a/src/vs/workbench/browser/parts/panel/panelPart.ts +++ b/src/vs/workbench/browser/parts/panel/panelPart.ts @@ -25,8 +25,8 @@ import { IInstantiationService } from 'vs/platform/instantiation/common/instanti import { ActionsOrientation, ActionBar } from 'vs/base/browser/ui/actionbar/actionbar'; import { ClosePanelAction, PanelAction, ToggleMaximizedPanelAction } from 'vs/workbench/browser/parts/panel/panelActions'; import { IThemeService, registerThemingParticipant, ITheme, ICssStyleCollector } from 'vs/platform/theme/common/themeService'; -import { PANEL_BACKGROUND, PANEL_BORDER, PANEL_ACTIVE_TITLE_FOREGROUND, PANEL_INACTIVE_TITLE_FOREGROUND, PANEL_ACTIVE_TITLE_BORDER } from 'vs/workbench/common/theme'; -import { activeContrastBorder, focusBorder, contrastBorder } from 'vs/platform/theme/common/colorRegistry'; +import { PANEL_BORDER, PANEL_ACTIVE_TITLE_FOREGROUND, PANEL_INACTIVE_TITLE_FOREGROUND, PANEL_ACTIVE_TITLE_BORDER } from 'vs/workbench/common/theme'; +import { activeContrastBorder, focusBorder, contrastBorder, editorBackground } from 'vs/platform/theme/common/colorRegistry'; export class PanelPart extends CompositePart implements IPanelService { @@ -101,7 +101,7 @@ export class PanelPart extends CompositePart implements IPanelService { super.updateStyles(); const container = this.getContainer(); - container.style('background-color', this.getColor(PANEL_BACKGROUND)); + container.style('background-color', this.getColor(editorBackground)); const title = this.getTitleArea(); title.style('border-top-color', this.getColor(PANEL_BORDER) || this.getColor(contrastBorder)); diff --git a/src/vs/workbench/common/theme.ts b/src/vs/workbench/common/theme.ts index ae51ff8ef6d..6a3c745dafb 100644 --- a/src/vs/workbench/common/theme.ts +++ b/src/vs/workbench/common/theme.ts @@ -84,12 +84,6 @@ export const EDITOR_DRAG_AND_DROP_BACKGROUND = registerColor('editorGroup.dropBa // < --- Panels --- > -export const PANEL_BACKGROUND = registerColor('panel.background', { - dark: editorBackground, - light: editorBackground, - hc: editorBackground -}, nls.localize('panelBackground', "Panel background color. Panels are shown below the editor area and contain views like output and integrated terminal.")); - export const PANEL_BORDER = registerColor('panel.border', { dark: Color.fromHex('#808080').transparent(0.35), light: Color.fromHex('#808080').transparent(0.35), -- GitLab From cf4f34d8081746cbd144a6a8a883047f758e5bd2 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Mon, 29 May 2017 11:04:46 +0200 Subject: [PATCH 0234/1347] Extension viewlet high contrast mouse over borders only highlight a single border for top and bottom entries (fixes #15859) --- src/vs/base/browser/ui/list/listWidget.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/base/browser/ui/list/listWidget.ts b/src/vs/base/browser/ui/list/listWidget.ts index d8f833da540..1ed888d7f2a 100644 --- a/src/vs/base/browser/ui/list/listWidget.ts +++ b/src/vs/base/browser/ui/list/listWidget.ts @@ -887,7 +887,7 @@ export class List implements ISpliceable, IDisposable { } if (styles.listSelectionOutline) { - content.push(`.monaco-list.${this.idPrefix} .monaco-list-row.selected { outline: 1px dotted ${styles.listSelectionOutline}; }`); + content.push(`.monaco-list.${this.idPrefix} .monaco-list-row.selected { outline: 1px dotted ${styles.listSelectionOutline}; outline-offset: -1px; }`); } if (styles.listFocusOutline) { -- GitLab From bcf8f556928bf5c49ef94d60ef696dfd64423e54 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Mon, 29 May 2017 11:07:57 +0200 Subject: [PATCH 0235/1347] Search viewlet doesn't get selected text from diff editor (fixes #25293) --- .../workbench/parts/search/browser/searchViewlet.ts | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/search/browser/searchViewlet.ts b/src/vs/workbench/parts/search/browser/searchViewlet.ts index 97f51caa16c..9fe88c72d57 100644 --- a/src/vs/workbench/parts/search/browser/searchViewlet.ts +++ b/src/vs/workbench/parts/search/browser/searchViewlet.ts @@ -9,7 +9,7 @@ import 'vs/css!./media/searchviewlet'; import nls = require('vs/nls'); import { TPromise } from 'vs/base/common/winjs.base'; import { Emitter, debounceEvent } from 'vs/base/common/event'; -import { ICommonCodeEditor, isCommonCodeEditor } from 'vs/editor/common/editorCommon'; +import { ICommonCodeEditor, isCommonCodeEditor, isCommonDiffEditor } from 'vs/editor/common/editorCommon'; import lifecycle = require('vs/base/common/lifecycle'); import errors = require('vs/base/common/errors'); import aria = require('vs/base/browser/ui/aria/aria'); @@ -797,7 +797,15 @@ export class SearchViewlet extends Viewlet { return null; } - let editorControl: any = this.editorService.getActiveEditor().getControl(); + let editorControl = this.editorService.getActiveEditor().getControl(); + if (isCommonDiffEditor(editorControl)) { + if (editorControl.getOriginalEditor().isFocused()) { + editorControl = editorControl.getOriginalEditor(); + } else { + editorControl = editorControl.getModifiedEditor(); + } + } + if (!isCommonCodeEditor(editorControl)) { return null; } -- GitLab From e4080aa0941ed748859a176be39d587b89432d00 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Mon, 29 May 2017 11:21:36 +0200 Subject: [PATCH 0236/1347] Extensions: double-click should open new extension window pinned (fixes #17048) --- src/vs/base/browser/ui/list/listPaging.ts | 4 ++++ .../extensions/electron-browser/extensionsViewlet.ts | 12 ++++++++++++ 2 files changed, 16 insertions(+) diff --git a/src/vs/base/browser/ui/list/listPaging.ts b/src/vs/base/browser/ui/list/listPaging.ts index 70170ab730b..c11ff0e6f8d 100644 --- a/src/vs/base/browser/ui/list/listPaging.ts +++ b/src/vs/base/browser/ui/list/listPaging.ts @@ -85,6 +85,10 @@ export class PagedList { return mapEvent(this.list.onSelectionChange, ({ elements, indexes }) => ({ elements: elements.map(e => this._model.get(e)), indexes })); } + get onPin(): Event> { + return mapEvent(this.list.onPin, ({ elements, indexes }) => ({ elements: elements.map(e => this._model.get(e)), indexes })); + } + get model(): IPagedModel { return this._model; } diff --git a/src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.ts b/src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.ts index 63d676aa2fb..63e301eff01 100644 --- a/src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.ts +++ b/src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.ts @@ -155,6 +155,11 @@ export class ExtensionsViewlet extends Viewlet implements IExtensionsViewlet { .filter(e => !!e) .on(this.openExtension, this, this.disposables); + chain(this.list.onPin) + .map(e => e.elements[0]) + .filter(e => !!e) + .on(this.pin, this, this.disposables); + return TPromise.as(null); } @@ -437,6 +442,13 @@ export class ExtensionsViewlet extends Viewlet implements IExtensionsViewlet { this.extensionsWorkbenchService.open(extension).done(null, err => this.onError(err)); } + private pin(): void { + const activeEditor = this.editorService.getActiveEditor(); + const activeEditorInput = this.editorService.getActiveEditorInput(); + + this.editorInputService.pinEditor(activeEditor.position, activeEditorInput); + } + private onEnter(): void { this.list.setSelection(this.list.getFocus()); } -- GitLab From 43298ba5473ad3282a6e25fb29bc0eaaa4ac808d Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Mon, 29 May 2017 11:36:23 +0200 Subject: [PATCH 0237/1347] macOS: custom titlebar double-click not consistent (fixes #27382) --- src/vs/code/electron-main/window.ts | 27 +++++++++++++++++++ src/vs/platform/windows/common/windows.ts | 2 ++ src/vs/platform/windows/common/windowsIpc.ts | 6 +++++ .../windows/electron-browser/windowService.ts | 4 +++ .../windows/electron-main/windowsService.ts | 10 +++++++ .../browser/parts/titlebar/titlebarPart.ts | 8 +----- .../workbench/test/workbenchTestServices.ts | 7 +++++ 7 files changed, 57 insertions(+), 7 deletions(-) diff --git a/src/vs/code/electron-main/window.ts b/src/vs/code/electron-main/window.ts index 91d560b50fd..b4151b960d3 100644 --- a/src/vs/code/electron-main/window.ts +++ b/src/vs/code/electron-main/window.ts @@ -823,6 +823,33 @@ export class VSCodeWindow { }; } + public onWindowTitleDoubleClick(): void { + + // Respect system settings on mac with regards to title click on windows title + if (platform.isMacintosh) { + const action = systemPreferences.getUserDefault('AppleActionOnDoubleClick', 'string'); + switch (action) { + case 'Minimize': + this.win.minimize(); + break; + case 'None': + break; + case 'Maximize': + default: + this.win.maximize(); + } + } + + // Linux/Windows: just toggle maximize/minimized state + else { + if (this.win.isMaximized()) { + this.win.unmaximize(); + } else { + this.win.maximize(); + } + } + } + public sendWhenReady(channel: string, ...args: any[]): void { this.ready().then(() => { this.send(channel, ...args); diff --git a/src/vs/platform/windows/common/windows.ts b/src/vs/platform/windows/common/windows.ts index d24aafc9bfb..b4ff59ddacf 100644 --- a/src/vs/platform/windows/common/windows.ts +++ b/src/vs/platform/windows/common/windows.ts @@ -37,6 +37,7 @@ export interface IWindowsService { isMaximized(windowId: number): TPromise; maximizeWindow(windowId: number): TPromise; unmaximizeWindow(windowId: number): TPromise; + onWindowTitleDoubleClick(windowId: number): TPromise; setDocumentEdited(windowId: number, flag: boolean): TPromise; quit(): TPromise; relaunch(options: { addArgs?: string[], removeArgs?: string[] }): TPromise; @@ -89,6 +90,7 @@ export interface IWindowService { isMaximized(): TPromise; maximizeWindow(): TPromise; unmaximizeWindow(): TPromise; + onWindowTitleDoubleClick(): TPromise; } export type MenuBarVisibility = 'default' | 'visible' | 'toggle' | 'hidden'; diff --git a/src/vs/platform/windows/common/windowsIpc.ts b/src/vs/platform/windows/common/windowsIpc.ts index 2d9e9d36506..01840d84f1e 100644 --- a/src/vs/platform/windows/common/windowsIpc.ts +++ b/src/vs/platform/windows/common/windowsIpc.ts @@ -31,6 +31,7 @@ export interface IWindowsChannel extends IChannel { call(command: 'isMaximized', arg: number): TPromise; call(command: 'maximizeWindow', arg: number): TPromise; call(command: 'unmaximizeWindow', arg: number): TPromise; + call(command: 'onWindowTitleDoubleClick', arg: number): TPromise; call(command: 'setDocumentEdited', arg: [number, boolean]): TPromise; call(command: 'quit'): TPromise; call(command: 'openWindow', arg: [string[], { forceNewWindow?: boolean, forceReuseWindow?: boolean }]): TPromise; @@ -81,6 +82,7 @@ export class WindowsChannel implements IWindowsChannel { case 'isMaximized': return this.service.isMaximized(arg); case 'maximizeWindow': return this.service.maximizeWindow(arg); case 'unmaximizeWindow': return this.service.unmaximizeWindow(arg); + case 'onWindowTitleDoubleClick': return this.service.onWindowTitleDoubleClick(arg); case 'setDocumentEdited': return this.service.setDocumentEdited(arg[0], arg[1]); case 'openWindow': return this.service.openWindow(arg[0], arg[1]); case 'openNewWindow': return this.service.openNewWindow(); @@ -185,6 +187,10 @@ export class WindowsChannelClient implements IWindowsService { return this.channel.call('unmaximizeWindow', windowId); } + onWindowTitleDoubleClick(windowId: number): TPromise { + return this.channel.call('onWindowTitleDoubleClick', windowId); + } + setDocumentEdited(windowId: number, flag: boolean): TPromise { return this.channel.call('setDocumentEdited', [windowId, flag]); } diff --git a/src/vs/platform/windows/electron-browser/windowService.ts b/src/vs/platform/windows/electron-browser/windowService.ts index c5d2e5c7e8a..1247697fd17 100644 --- a/src/vs/platform/windows/electron-browser/windowService.ts +++ b/src/vs/platform/windows/electron-browser/windowService.ts @@ -90,6 +90,10 @@ export class WindowService implements IWindowService { return this.windowsService.unmaximizeWindow(this.windowId); } + onWindowTitleDoubleClick(): TPromise { + return this.windowsService.onWindowTitleDoubleClick(this.windowId); + } + setDocumentEdited(flag: boolean): TPromise { return this.windowsService.setDocumentEdited(this.windowId, flag); } diff --git a/src/vs/platform/windows/electron-main/windowsService.ts b/src/vs/platform/windows/electron-main/windowsService.ts index f74c4e5af39..5cef01c60f5 100644 --- a/src/vs/platform/windows/electron-main/windowsService.ts +++ b/src/vs/platform/windows/electron-main/windowsService.ts @@ -209,6 +209,16 @@ export class WindowsService implements IWindowsService, IDisposable { return TPromise.as(null); } + onWindowTitleDoubleClick(windowId: number): TPromise { + const vscodeWindow = this.windowsMainService.getWindowById(windowId); + + if (vscodeWindow) { + vscodeWindow.onWindowTitleDoubleClick(); + } + + return TPromise.as(null); + } + setDocumentEdited(windowId: number, flag: boolean): TPromise { const vscodeWindow = this.windowsMainService.getWindowById(windowId); diff --git a/src/vs/workbench/browser/parts/titlebar/titlebarPart.ts b/src/vs/workbench/browser/parts/titlebar/titlebarPart.ts index 1e1aa16a14f..d7aa9318fd6 100644 --- a/src/vs/workbench/browser/parts/titlebar/titlebarPart.ts +++ b/src/vs/workbench/browser/parts/titlebar/titlebarPart.ts @@ -241,13 +241,7 @@ export class TitlebarPart extends Part implements ITitleService { } private onTitleDoubleclick(): void { - this.windowService.isMaximized().then(maximized => { - if (maximized) { - this.windowService.unmaximizeWindow().done(null, errors.onUnexpectedError); - } else { - this.windowService.maximizeWindow().done(null, errors.onUnexpectedError); - } - }, errors.onUnexpectedError); + this.windowService.onWindowTitleDoubleClick().then(null, errors.onUnexpectedError); } private onContextMenu(e: MouseEvent): void { diff --git a/src/vs/workbench/test/workbenchTestServices.ts b/src/vs/workbench/test/workbenchTestServices.ts index 899b03112be..a7f4f1ea918 100644 --- a/src/vs/workbench/test/workbenchTestServices.ts +++ b/src/vs/workbench/test/workbenchTestServices.ts @@ -847,6 +847,10 @@ export class TestWindowService implements IWindowService { unmaximizeWindow(): TPromise { return TPromise.as(void 0); } + + onWindowTitleDoubleClick(): TPromise { + return TPromise.as(void 0); + } } export class TestLifecycleService implements ILifecycleService { @@ -944,6 +948,9 @@ export class TestWindowsService implements IWindowsService { unmaximizeWindow(windowId: number): TPromise { return TPromise.as(void 0); } + onWindowTitleDoubleClick(windowId: number): TPromise { + return TPromise.as(void 0); + } setDocumentEdited(windowId: number, flag: boolean): TPromise { return TPromise.as(void 0); } -- GitLab From a168746445d2a36a073be820acd7b9ec5a28f5ff Mon Sep 17 00:00:00 2001 From: isidor Date: Mon, 29 May 2017 11:49:15 +0200 Subject: [PATCH 0238/1347] debug repl input disable minimap --- src/vs/workbench/parts/debug/electron-browser/repl.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/repl.ts b/src/vs/workbench/parts/debug/electron-browser/repl.ts index cf2e3937375..06e263aff1d 100644 --- a/src/vs/workbench/parts/debug/electron-browser/repl.ts +++ b/src/vs/workbench/parts/debug/electron-browser/repl.ts @@ -281,7 +281,10 @@ export class Repl extends Panel implements IPrivateReplService { scrollBeyondLastLine: false, renderLineHighlight: 'none', fixedOverflowWidgets: true, - acceptSuggestionOnEnter: 'smart' + acceptSuggestionOnEnter: 'smart', + minimap: { + enabled: false + } }; } -- GitLab From a315b7cb724da24533c00769f61c5d0969601d7a Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Mon, 29 May 2017 12:06:06 +0200 Subject: [PATCH 0239/1347] Workbench theme customisation for forground tab colour of inactive group appears to be missing (fixes #27067) --- .../parts/editor/noTabsTitleControl.ts | 20 ++++--------- .../browser/parts/editor/tabsTitleControl.ts | 30 ++----------------- src/vs/workbench/common/theme.ts | 16 ++++++++-- 3 files changed, 23 insertions(+), 43 deletions(-) diff --git a/src/vs/workbench/browser/parts/editor/noTabsTitleControl.ts b/src/vs/workbench/browser/parts/editor/noTabsTitleControl.ts index fa83f95df08..6814ef611b8 100644 --- a/src/vs/workbench/browser/parts/editor/noTabsTitleControl.ts +++ b/src/vs/workbench/browser/parts/editor/noTabsTitleControl.ts @@ -12,7 +12,7 @@ import DOM = require('vs/base/browser/dom'); import { TitleControl } from 'vs/workbench/browser/parts/editor/titleControl'; import { EditorLabel } from 'vs/workbench/browser/labels'; import { Verbosity } from 'vs/platform/editor/common/editor'; -import { TAB_ACTIVE_FOREGROUND } from 'vs/workbench/common/theme'; +import { TAB_ACTIVE_FOREGROUND, TAB_UNFOCUSED_ACTIVE_FOREGROUND } from 'vs/workbench/common/theme'; export class NoTabsTitleControl extends TitleControl { private titleContainer: HTMLElement; @@ -126,19 +126,11 @@ export class NoTabsTitleControl extends TitleControl { } this.editorLabel.setLabel({ name, description, resource }, { title, italic: !isPinned, extraClasses: ['title-label'] }); - this.editorLabel.element.style.color = this.getColor(TAB_ACTIVE_FOREGROUND, (color, theme) => { - if (!isActive) { - if (theme.type === 'dark') { - return color.transparent(0.5); - } - - if (theme.type === 'light') { - return color.transparent(0.7); - } - } - - return color; - }); + if (isActive) { + this.editorLabel.element.style.color = this.getColor(TAB_ACTIVE_FOREGROUND); + } else { + this.editorLabel.element.style.color = this.getColor(TAB_UNFOCUSED_ACTIVE_FOREGROUND); + } // Update Editor Actions Toolbar this.updateEditorActionsToolbar(); diff --git a/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts b/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts index de3fda8a4d5..759efa00c16 100644 --- a/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts +++ b/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts @@ -40,7 +40,7 @@ import { LinkedMap } from 'vs/base/common/map'; import { DelegatingWorkbenchEditorService } from 'vs/workbench/services/editor/browser/editorService'; import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; import { IThemeService, registerThemingParticipant, ITheme, ICssStyleCollector } from 'vs/platform/theme/common/themeService'; -import { TAB_INACTIVE_BACKGROUND, TAB_ACTIVE_BACKGROUND, TAB_ACTIVE_FOREGROUND, TAB_INACTIVE_FOREGROUND, TAB_BORDER, EDITOR_DRAG_AND_DROP_BACKGROUND } from 'vs/workbench/common/theme'; +import { TAB_INACTIVE_BACKGROUND, TAB_ACTIVE_BACKGROUND, TAB_ACTIVE_FOREGROUND, TAB_INACTIVE_FOREGROUND, TAB_BORDER, EDITOR_DRAG_AND_DROP_BACKGROUND, TAB_UNFOCUSED_ACTIVE_FOREGROUND, TAB_UNFOCUSED_INACTIVE_FOREGROUND } from 'vs/workbench/common/theme'; import { activeContrastBorder, contrastBorder } from 'vs/platform/theme/common/colorRegistry'; interface IEditorInputLabel { @@ -291,38 +291,14 @@ export class TabsTitleControl extends TitleControl { DOM.addClass(tabContainer, 'active'); tabContainer.setAttribute('aria-selected', 'true'); tabContainer.style.backgroundColor = this.getColor(TAB_ACTIVE_BACKGROUND); - tabLabel.element.style.color = this.getColor(TAB_ACTIVE_FOREGROUND, (color, theme) => { - if (!isGroupActive) { - if (theme.type === 'dark') { - return color.transparent(0.5); - } - - if (theme.type === 'light') { - return color.transparent(0.7); - } - } - - return color; - }); + tabLabel.element.style.color = this.getColor(isGroupActive ? TAB_ACTIVE_FOREGROUND : TAB_UNFOCUSED_ACTIVE_FOREGROUND); this.activeTab = tabContainer; } else { DOM.removeClass(tabContainer, 'active'); tabContainer.setAttribute('aria-selected', 'false'); tabContainer.style.backgroundColor = this.getColor(TAB_INACTIVE_BACKGROUND); - tabLabel.element.style.color = this.getColor(TAB_INACTIVE_FOREGROUND, (color, theme) => { - if (!isGroupActive) { - if (theme.type === 'dark') { - return color.transparent(0.5); - } - - if (theme.type === 'light') { - return color.transparent(0.5); - } - } - - return color; - }); + tabLabel.element.style.color = this.getColor(isGroupActive ? TAB_INACTIVE_FOREGROUND : TAB_UNFOCUSED_INACTIVE_FOREGROUND); } // Dirty State diff --git a/src/vs/workbench/common/theme.ts b/src/vs/workbench/common/theme.ts index 6a3c745dafb..3b35554eb6e 100644 --- a/src/vs/workbench/common/theme.ts +++ b/src/vs/workbench/common/theme.ts @@ -33,13 +33,25 @@ export const TAB_ACTIVE_FOREGROUND = registerColor('tab.activeForeground', { dark: Color.white, light: '#333333', hc: Color.white -}, nls.localize('tabActiveEditorGroupActiveForeground', "Active tab foreground color in an active group. Tabs are the containers for editors in the editor area. Multiple tabs can be opened in one editor group. There can be multiple editor groups.")); +}, nls.localize('tabActiveForeground', "Active tab foreground color in an active group. Tabs are the containers for editors in the editor area. Multiple tabs can be opened in one editor group. There can be multiple editor groups.")); export const TAB_INACTIVE_FOREGROUND = registerColor('tab.inactiveForeground', { dark: transparent(TAB_ACTIVE_FOREGROUND, 0.5), light: transparent(TAB_ACTIVE_FOREGROUND, 0.5), hc: Color.white -}, nls.localize('tabInactiveEditorGroupActiveForeground', "Inactive tab foreground color in an active group. Tabs are the containers for editors in the editor area. Multiple tabs can be opened in one editor group. There can be multiple editor groups.")); +}, nls.localize('tabInactiveForeground', "Inactive tab foreground color in an active group. Tabs are the containers for editors in the editor area. Multiple tabs can be opened in one editor group. There can be multiple editor groups.")); + +export const TAB_UNFOCUSED_ACTIVE_FOREGROUND = registerColor('tab.unfocusedActiveForeground', { + dark: transparent(TAB_ACTIVE_FOREGROUND, 0.5), + light: transparent(TAB_ACTIVE_FOREGROUND, 0.7), + hc: Color.white +}, nls.localize('tabUnfocusedActiveForeground', "Active tab foreground color in an inactive group. Tabs are the containers for editors in the editor area. Multiple tabs can be opened in one editor group. There can be multiple editor groups.")); + +export const TAB_UNFOCUSED_INACTIVE_FOREGROUND = registerColor('tab.unfocusedInactiveForeground', { + dark: transparent(TAB_INACTIVE_FOREGROUND, 0.5), + light: transparent(TAB_INACTIVE_FOREGROUND, 0.5), + hc: Color.white +}, nls.localize('tabUnfocusedInactiveForeground', "Inactive tab foreground color in an inactive group. Tabs are the containers for editors in the editor area. Multiple tabs can be opened in one editor group. There can be multiple editor groups.")); // < --- Editors --- > -- GitLab From c1e60c7461a1c0bca82c2aa1f8f7418ebe007710 Mon Sep 17 00:00:00 2001 From: isidor Date: Mon, 29 May 2017 12:16:43 +0200 Subject: [PATCH 0240/1347] debug actions widget: default position go back to center for discoverability #2513 --- src/vs/workbench/parts/debug/browser/debugActionsWidget.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/vs/workbench/parts/debug/browser/debugActionsWidget.ts b/src/vs/workbench/parts/debug/browser/debugActionsWidget.ts index dc9a9d0d19d..7afe47c4c78 100644 --- a/src/vs/workbench/parts/debug/browser/debugActionsWidget.ts +++ b/src/vs/workbench/parts/debug/browser/debugActionsWidget.ts @@ -114,8 +114,7 @@ export class DebugActionsWidget extends Themable implements IWorkbenchContributi const mouseClickEvent = new StandardMouseEvent(event); if (mouseClickEvent.detail === 2) { // double click on debug bar centers it again #8250 - const widgetWidth = this.$el.getHTMLElement().clientWidth; - this.setXCoordinate(window.innerWidth - widgetWidth); + this.setXCoordinate(0.5 * window.innerWidth); this.storePosition(); } }); @@ -174,7 +173,7 @@ export class DebugActionsWidget extends Themable implements IWorkbenchContributi return; } if (x === undefined) { - x = parseFloat(this.storageService.get(DEBUG_ACTIONS_WIDGET_POSITION_KEY, StorageScope.WORKSPACE, '1')) * window.innerWidth; + x = parseFloat(this.storageService.get(DEBUG_ACTIONS_WIDGET_POSITION_KEY, StorageScope.WORKSPACE, '0.5')) * window.innerWidth; } const widgetWidth = this.$el.getHTMLElement().clientWidth; -- GitLab From 8f1fe44e86453fa2ef89b82f576f5c46640730d6 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Mon, 29 May 2017 12:17:01 +0200 Subject: [PATCH 0241/1347] Fixes #27426: Add runner information to telemetry --- src/vs/workbench/parts/tasks/common/taskSystem.ts | 2 ++ .../parts/tasks/electron-browser/terminalTaskSystem.ts | 2 ++ src/vs/workbench/parts/tasks/node/processTaskSystem.ts | 1 + 3 files changed, 5 insertions(+) diff --git a/src/vs/workbench/parts/tasks/common/taskSystem.ts b/src/vs/workbench/parts/tasks/common/taskSystem.ts index cca11d1e6a9..30e51e8a2e3 100644 --- a/src/vs/workbench/parts/tasks/common/taskSystem.ts +++ b/src/vs/workbench/parts/tasks/common/taskSystem.ts @@ -37,6 +37,8 @@ export interface TelemetryEvent { // How the task got trigger. Is either shortcut or command trigger: string; + runner: 'terminal' | 'output'; + // The command triggered command: string; diff --git a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts index bf6065aa66a..e374bce4cd9 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts @@ -340,6 +340,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { try { let telemetryEvent: TelemetryEvent = { trigger: trigger, + runner: 'terminal', command: this.getSanitizedCommand(executedCommand), success: true, exitCode: summary.exitCode @@ -352,6 +353,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { try { let telemetryEvent: TelemetryEvent = { trigger: trigger, + runner: 'terminal', command: this.getSanitizedCommand(executedCommand), success: false }; diff --git a/src/vs/workbench/parts/tasks/node/processTaskSystem.ts b/src/vs/workbench/parts/tasks/node/processTaskSystem.ts index 2a1fcb76e73..9f4d55278f5 100644 --- a/src/vs/workbench/parts/tasks/node/processTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/node/processTaskSystem.ts @@ -120,6 +120,7 @@ export class ProcessTaskSystem extends EventEmitter implements ITaskSystem { private executeTask(task: Task, trigger: string = Triggers.command): ITaskExecuteResult { let telemetryEvent: TelemetryEvent = { trigger: trigger, + runner: 'output', command: 'other', success: true }; -- GitLab From 7223e4bfe4892580ef420341a58be5441ed387f7 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Mon, 29 May 2017 12:44:49 +0200 Subject: [PATCH 0242/1347] Added wait time for peek widgets to be loaded. --- test/smoke/src/tests/javascript.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/smoke/src/tests/javascript.ts b/test/smoke/src/tests/javascript.ts index 490677f1f29..3bde32ccc39 100644 --- a/test/smoke/src/tests/javascript.ts +++ b/test/smoke/src/tests/javascript.ts @@ -37,8 +37,8 @@ export function testJavaScript() { it(`finds 'All References' to 'app'`, async function () { await common.openFirstMatchFile('bin/www'); - await app.wait(); await js.findAppReferences(); + await app.wait(); const titleCount = await js.getTitleReferencesCount(); assert.equal(titleCount, 3); const treeCount = await js.getTreeReferencesCount(); @@ -79,6 +79,7 @@ export function testJavaScript() { it(`verifies that 'Peek Definition' works`, async function () { await common.openFirstMatchFile('app.js'); await js.peekExpressDefinition(); + await app.wait(); const definitionFilename = await js.getPeekExpressResultName(); assert.equal(definitionFilename, 'index.d.ts'); }); -- GitLab From 9a55652262ee29c9efaa373fe264a67265521998 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Mon, 29 May 2017 12:52:49 +0200 Subject: [PATCH 0243/1347] Fixes #27338: Let the task framework configure 'Press any key to close the terminal' --- src/vs/workbench/parts/terminal/common/terminal.ts | 4 +++- .../parts/terminal/electron-browser/terminalInstance.ts | 5 ++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/terminal/common/terminal.ts b/src/vs/workbench/parts/terminal/common/terminal.ts index bd7df535e4e..1093b3ee7e0 100644 --- a/src/vs/workbench/parts/terminal/common/terminal.ts +++ b/src/vs/workbench/parts/terminal/common/terminal.ts @@ -109,8 +109,10 @@ export interface IShellLaunchConfig { * shell is being launched by an extension). */ ignoreConfigurationCwd?: boolean; + /** Whether to wait for a key press before closing the terminal. */ - waitOnExit?: boolean; + waitOnExit?: boolean | string; + /** * A string including ANSI escape sequences that will be written to the terminal emulator * _before_ the terminal process has launched, a trailing \n is added at the end of the string. diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index 5247bd40e71..3b320363826 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -529,7 +529,10 @@ export class TerminalInstance implements ITerminalInstance { if (exitCode) { this._xterm.writeln(exitCodeMessage); } - this._xterm.writeln(nls.localize('terminal.integrated.waitOnExit', 'Press any key to close the terminal')); + let message = typeof this._shellLaunchConfig.waitOnExit === 'string' + ? this._shellLaunchConfig.waitOnExit + : nls.localize('terminal.integrated.waitOnExit', 'Press any key to close the terminal'); + this._xterm.writeln(message); // Disable all input if the terminal is exiting and listen for next keypress this._xterm.setOption('disableStdin', true); if (this._xterm.textarea) { -- GitLab From e8271ae2ae426d29ef087af8e64b14f2b678298b Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Mon, 29 May 2017 12:53:24 +0200 Subject: [PATCH 0244/1347] Adopt #27338 --- .../parts/tasks/electron-browser/terminalTaskSystem.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts index e374bce4cd9..04591b40b55 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts @@ -368,7 +368,10 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { let options = this.resolveOptions(task.command.options); let { command, args } = this.resolveCommandAndArgs(task); let terminalName = nls.localize('TerminalTaskSystem.terminalName', 'Task - {0}', task.name); - let waitOnExit = task.command.terminal.reveal !== RevealKind.Never || !task.isBackground; + let waitOnExit: boolean | string = false; + if (task.command.terminal.reveal !== RevealKind.Never || !task.isBackground) { + waitOnExit = nls.localize('reuseTerminal', 'Terminal will be reused by tasks, press any key to close it.'); + }; let shellLaunchConfig: IShellLaunchConfig = undefined; let isShellCommand = task.command.type === CommandType.Shell; if (isShellCommand) { -- GitLab From a41a0c007ff39cf50a2d3d6bea25516edbe7a08e Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Mon, 29 May 2017 13:04:06 +0200 Subject: [PATCH 0245/1347] Intercept child process exit and exit from the main process as well. --- test/smoke/src/main.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/test/smoke/src/main.js b/test/smoke/src/main.js index 85e3778d1a7..ef6d65112e9 100644 --- a/test/smoke/src/main.js +++ b/test/smoke/src/main.js @@ -77,6 +77,9 @@ function runTests() { if (err) throw new Error(`Could not write stderr to errors.log with the following error: ${err}`); }); }); + proc.on('exit', (code) => { + process.exit(code); + }); } function cleanOrClone(repo, dir) { -- GitLab From 365fcece1868764f2a9c771f18dd01ff7072cf79 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Mon, 29 May 2017 13:04:24 +0200 Subject: [PATCH 0246/1347] Fixes #27320 --- .../parts/tasks/browser/quickOpen.ts | 35 +++++++++++-------- 1 file changed, 21 insertions(+), 14 deletions(-) diff --git a/src/vs/workbench/parts/tasks/browser/quickOpen.ts b/src/vs/workbench/parts/tasks/browser/quickOpen.ts index e282ee68321..fe5ec004ee4 100644 --- a/src/vs/workbench/parts/tasks/browser/quickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/quickOpen.ts @@ -125,7 +125,7 @@ class CustomizeTaskAction extends Action { private static ID = 'workbench.action.tasks.customizeTask'; private static LABEL = nls.localize('customizeTask', "Customize Task"); - constructor(private taskService: ITaskService, private task: Task) { + constructor(private taskService: ITaskService, private quickOpenService: IQuickOpenService, private task: Task) { super(CustomizeTaskAction.ID, CustomizeTaskAction.LABEL); this.updateClass(); } @@ -134,37 +134,44 @@ class CustomizeTaskAction extends Action { this.class = 'quick-open-task-configure'; } - public run(context: any): TPromise { - return this.taskService.customize(this.task, true).then(_ => false, _ => false); + public run(context: any): TPromise { + return this.taskService.customize(this.task, true).then(() => { + this.quickOpenService.close(); + }); } } export class QuickOpenActionContributor extends ActionBarContributor { - constructor( @ITaskService private taskService: ITaskService) { + constructor( @ITaskService private taskService: ITaskService, @IQuickOpenService private quickOpenService: IQuickOpenService) { super(); } public hasActions(context: any): boolean { - const entry = this.getEntry(context); + let task = this.getTask(context); - return !!entry; + return !!task; } public getActions(context: any): IAction[] { - const actions: Action[] = []; - - const entry = this.getEntry(context); - if (entry && entry.task._source.kind === TaskSourceKind.Extension) { - actions.push(new CustomizeTaskAction(this.taskService, entry.task)); + let actions: Action[] = []; + let task = this.getTask(context); + if (task && task._source.kind === TaskSourceKind.Extension) { + actions.push(new CustomizeTaskAction(this.taskService, this.quickOpenService, task)); } return actions; } - private getEntry(context: any): TaskEntry { - if (!context || !(context.element instanceof TaskEntry)) { + private getTask(context: any): Task { + if (!context) { return undefined; } - return context.element as TaskEntry; + let element = context.element; + if (element instanceof TaskEntry) { + return element.task; + } else if (element instanceof TaskGroupEntry) { + return (element.getEntry() as TaskEntry).task; + } + return undefined; } } \ No newline at end of file -- GitLab From 7c27e9ba0815db59c765aa2ca2719cb0865c9ab3 Mon Sep 17 00:00:00 2001 From: isidor Date: Mon, 29 May 2017 14:19:33 +0200 Subject: [PATCH 0247/1347] remove variablesDealy setting we used for experimentation fixes #27262 --- src/vs/workbench/parts/debug/common/debug.ts | 1 - .../parts/debug/electron-browser/debug.contribution.ts | 4 ---- .../workbench/parts/debug/electron-browser/debugViews.ts | 8 +++----- 3 files changed, 3 insertions(+), 10 deletions(-) diff --git a/src/vs/workbench/parts/debug/common/debug.ts b/src/vs/workbench/parts/debug/common/debug.ts index 5947fe89104..310e20a0d22 100644 --- a/src/vs/workbench/parts/debug/common/debug.ts +++ b/src/vs/workbench/parts/debug/common/debug.ts @@ -306,7 +306,6 @@ export interface IDebugConfiguration { inlineValues: boolean; hideActionBar: boolean; internalConsoleOptions: string; - variablesDelay: number; } export interface IGlobalConfig { diff --git a/src/vs/workbench/parts/debug/electron-browser/debug.contribution.ts b/src/vs/workbench/parts/debug/electron-browser/debug.contribution.ts index b8faa49a1a1..22c7191e517 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debug.contribution.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debug.contribution.ts @@ -173,10 +173,6 @@ configurationRegistry.registerConfiguration({ default: false }, 'debug.internalConsoleOptions': INTERNAL_CONSOLE_OPTIONS_SCHEMA, - 'debug.variablesDelay': { - type: 'number', - default: 400 - }, 'launch': { type: 'object', description: nls.localize({ comment: ['This is the description for a setting'], key: 'launch' }, "Global debug launch configuration. Should be used as an alternative to 'launch.json' that is shared across workspaces"), diff --git a/src/vs/workbench/parts/debug/electron-browser/debugViews.ts b/src/vs/workbench/parts/debug/electron-browser/debugViews.ts index 63d48fe5694..3d4d2f1838b 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugViews.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugViews.ts @@ -17,7 +17,7 @@ import { IHighlightEvent, ITree } from 'vs/base/parts/tree/browser/tree'; import { Tree } from 'vs/base/parts/tree/browser/treeImpl'; import { CollapsibleState } from 'vs/base/browser/ui/splitview/splitview'; import { CollapsibleViewletView, AdaptiveCollapsibleViewletView, CollapseAction } from 'vs/workbench/browser/viewlet'; -import { IDebugService, State, IDebugConfiguration, IBreakpoint, IExpression, CONTEXT_BREAKPOINTS_FOCUSED, CONTEXT_WATCH_EXPRESSIONS_FOCUSED, CONTEXT_VARIABLES_FOCUSED } from 'vs/workbench/parts/debug/common/debug'; +import { IDebugService, State, IBreakpoint, IExpression, CONTEXT_BREAKPOINTS_FOCUSED, CONTEXT_WATCH_EXPRESSIONS_FOCUSED, CONTEXT_VARIABLES_FOCUSED } from 'vs/workbench/parts/debug/common/debug'; import { Expression, Variable, ExceptionBreakpoint, FunctionBreakpoint, Thread, StackFrame, Breakpoint, ThreadAndProcessIds } from 'vs/workbench/parts/debug/common/debugModel'; import * as viewer from 'vs/workbench/parts/debug/electron-browser/debugViewer'; import { AddWatchExpressionAction, RemoveAllWatchExpressionsAction, AddFunctionBreakpointAction, ToggleBreakpointsActivatedAction, RemoveAllBreakpointsAction } from 'vs/workbench/parts/debug/browser/debugActions'; @@ -26,7 +26,6 @@ import { IInstantiationService } from 'vs/platform/instantiation/common/instanti import { MenuId } from 'vs/platform/actions/common/actions'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IMessageService } from 'vs/platform/message/common/message'; -import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { IContextKeyService, IContextKey } from 'vs/platform/contextkey/common/contextkey'; import { IListService } from 'vs/platform/list/browser/listService'; @@ -60,8 +59,7 @@ export class VariablesView extends CollapsibleViewletView { @IInstantiationService private instantiationService: IInstantiationService, @IContextKeyService contextKeyService: IContextKeyService, @IListService private listService: IListService, - @IThemeService private themeService: IThemeService, - @IConfigurationService private configurationService: IConfigurationService + @IThemeService private themeService: IThemeService ) { super(actionRunner, !!settings[VariablesView.MEMENTO], nls.localize('variablesSection', "Variables Section"), messageService, keybindingService, contextMenuService); @@ -82,7 +80,7 @@ export class VariablesView extends CollapsibleViewletView { } return undefined; }).done(null, errors.onUnexpectedError); - }, this.configurationService.getConfiguration('debug').variablesDelay); + }, 400); } public renderHeader(container: HTMLElement): void { -- GitLab From 7c3f873bed2b3b89ff14882866a3afd656627e8b Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Mon, 29 May 2017 14:31:57 +0200 Subject: [PATCH 0248/1347] update to vscode-textmate@3.1.5 --- npm-shrinkwrap.json | 6 +++--- package.json | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/npm-shrinkwrap.json b/npm-shrinkwrap.json index 678f3be8298..d7f219b1638 100644 --- a/npm-shrinkwrap.json +++ b/npm-shrinkwrap.json @@ -420,9 +420,9 @@ "resolved": "https://registry.npmjs.org/vscode-ripgrep/-/vscode-ripgrep-0.0.12.tgz" }, "vscode-textmate": { - "version": "3.1.4", - "from": "vscode-textmate@3.1.4", - "resolved": "https://registry.npmjs.org/vscode-textmate/-/vscode-textmate-3.1.4.tgz" + "version": "3.1.5", + "from": "vscode-textmate@3.1.5", + "resolved": "https://registry.npmjs.org/vscode-textmate/-/vscode-textmate-3.1.5.tgz" }, "windows-foreground-love": { "version": "0.1.0", diff --git a/package.json b/package.json index c31f58f40c9..bfc4fed8575 100644 --- a/package.json +++ b/package.json @@ -40,7 +40,7 @@ "v8-profiler": "jrieken/v8-profiler#vscode", "vscode-debugprotocol": "1.19.0", "vscode-ripgrep": "0.0.12", - "vscode-textmate": "^3.1.4", + "vscode-textmate": "^3.1.5", "winreg": "1.2.0", "xterm": "Tyriar/xterm.js#vscode-release/1.13", "yauzl": "2.3.1" @@ -124,4 +124,4 @@ "windows-mutex": "^0.2.0", "fsevents": "0.3.8" } -} \ No newline at end of file +} -- GitLab From e58c2abb979281c1f4a6530840e5a4ed0093bfb6 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Mon, 29 May 2017 14:44:01 +0200 Subject: [PATCH 0249/1347] Implements #27399: Separate the task provider name from the task name in the task API --- extensions/grunt/src/main.ts | 4 +- extensions/gulp/src/main.ts | 2 +- extensions/jake/src/main.ts | 2 +- extensions/npm/src/main.ts | 4 +- .../typescript/src/features/taskProvider.ts | 3 +- src/vs/vscode.d.ts | 33 +++++++---- src/vs/workbench/api/node/extHostTask.ts | 6 +- src/vs/workbench/api/node/extHostTypes.ts | 58 +++++++++++-------- .../parts/tasks/browser/quickOpen.ts | 16 ++++- .../parts/tasks/common/taskConfiguration.ts | 1 + src/vs/workbench/parts/tasks/common/tasks.ts | 5 +- .../electron-browser/task.contribution.ts | 2 +- .../tasks/test/node/configuration.test.ts | 2 +- 13 files changed, 88 insertions(+), 50 deletions(-) diff --git a/extensions/grunt/src/main.ts b/extensions/grunt/src/main.ts index ff551f904ec..a90eff6c933 100644 --- a/extensions/grunt/src/main.ts +++ b/extensions/grunt/src/main.ts @@ -139,8 +139,8 @@ async function getGruntTasks(): Promise { if (matches && matches.length === 2) { let taskName = matches[1]; let task = taskName.indexOf(' ') === -1 - ? new vscode.ShellTask(`grunt: ${taskName}`, `${command} ${taskName}`) - : new vscode.ShellTask(`grunt: ${taskName}`, `${command} "${taskName}"`); + ? new vscode.ShellTask(taskName, `${command} ${taskName}`) + : new vscode.ShellTask(taskName, `${command} "${taskName}"`); task.identifier = `grunt.${taskName}`; result.push(task); let lowerCaseTaskName = taskName.toLowerCase(); diff --git a/extensions/gulp/src/main.ts b/extensions/gulp/src/main.ts index 666b66bf120..c75a8ce5d9c 100644 --- a/extensions/gulp/src/main.ts +++ b/extensions/gulp/src/main.ts @@ -114,7 +114,7 @@ async function getGulpTasks(): Promise { if (line.length === 0) { continue; } - let task = new vscode.ShellTask(`gulp: ${line}`, `${gulpCommand} ${line}`); + let task = new vscode.ShellTask(line, `${gulpCommand} ${line}`); task.identifier = `gulp.${line}`; result.push(task); let lowerCaseLine = line.toLowerCase(); diff --git a/extensions/jake/src/main.ts b/extensions/jake/src/main.ts index 93b55873eab..25d93a29780 100644 --- a/extensions/jake/src/main.ts +++ b/extensions/jake/src/main.ts @@ -118,7 +118,7 @@ async function getJakeTasks(): Promise { let matches = regExp.exec(line); if (matches && matches.length === 2) { let taskName = matches[1]; - let task = new vscode.ShellTask(`jake: ${taskName}`, `${jakeCommand} ${taskName}`); + let task = new vscode.ShellTask(taskName, `${jakeCommand} ${taskName}`); task.identifier = `jake.${taskName}`; result.push(task); let lowerCaseLine = line.toLowerCase(); diff --git a/extensions/npm/src/main.ts b/extensions/npm/src/main.ts index 9dc734a4ffe..beeddfa5a86 100644 --- a/extensions/npm/src/main.ts +++ b/extensions/npm/src/main.ts @@ -81,7 +81,7 @@ async function getNpmScriptsAsTasks(): Promise { const result: vscode.Task[] = []; Object.keys(json.scripts).forEach(each => { - const task = new vscode.ShellTask(`npm: run ${each}`, `npm run ${each}`); + const task = new vscode.ShellTask(`run ${each}`, `npm run ${each}`); const lowerCaseTaskName = each.toLowerCase(); if (lowerCaseTaskName === 'build') { task.group = vscode.TaskGroup.Build; @@ -91,7 +91,7 @@ async function getNpmScriptsAsTasks(): Promise { result.push(task); }); // add some 'well known' npm tasks - result.push(new vscode.ShellTask(`npm: install`, `npm install`)); + result.push(new vscode.ShellTask(`install`, `npm install`)); return Promise.resolve(result); } catch (e) { return Promise.resolve(emptyTasks); diff --git a/extensions/typescript/src/features/taskProvider.ts b/extensions/typescript/src/features/taskProvider.ts index 4d50b233294..9cb0a3a64a8 100644 --- a/extensions/typescript/src/features/taskProvider.ts +++ b/extensions/typescript/src/features/taskProvider.ts @@ -48,7 +48,8 @@ class TscTaskProvider implements vscode.TaskProvider { return projects.map(configFile => { const configFileName = path.relative(rootPath, configFile); - const buildTask = new vscode.ShellTask(`tsc: build ${configFileName}`, `${command} -p "${configFile}"`, '$tsc'); + const buildTask = new vscode.ShellTask(`build ${configFileName}`, `${command} -p "${configFile}"`, '$tsc'); + buildTask.source = 'tsc'; buildTask.group = vscode.TaskGroup.Build; return buildTask; }); diff --git a/src/vs/vscode.d.ts b/src/vs/vscode.d.ts index f9587fccbe0..979822a1f4d 100644 --- a/src/vs/vscode.d.ts +++ b/src/vs/vscode.d.ts @@ -3580,11 +3580,6 @@ declare module 'vscode' { export const Test: 'test'; } - /** - * The supported task groups. - */ - export type TaskGroup = 'clean' | 'build' | 'rebuildAll' | 'test'; - /** * The ProblemMatchers type definition. */ @@ -3652,10 +3647,18 @@ declare module 'vscode' { args: string[]; /** - * The task group this tasks belongs to. Defaults to undefined meaning - * that the task doesn't belong to any special group. + * A human-readable string describing the source of this + * shell task, e.g. 'gulp' or 'npm'. */ - group?: TaskGroup; + source: string | undefined; + + /** + * The task group this tasks belongs to. See TaskGroup + * for a predefined set of available groups. + * Defaults to undefined meaning that the task doesn't + * belong to any special group. + */ + group: string | undefined; /** * The process options used when the process is executed. @@ -3772,10 +3775,18 @@ declare module 'vscode' { readonly commandLine: string; /** - * The task group this tasks belongs to. Defaults to undefined meaning - * that the task doesn't belong to any special group. + * A human-readable string describing the source of this + * shell task, e.g. 'gulp' or 'npm'. + */ + source: string | undefined; + + /** + * The task group this tasks belongs to. See TaskGroup + * for a predefined set of available groups. + * Defaults to undefined meaning that the task doesn't + * belong to any special group. */ - group?: TaskGroup; + group: string | undefined; /** * The shell options used when the shell is executed. Defaults to an diff --git a/src/vs/workbench/api/node/extHostTask.ts b/src/vs/workbench/api/node/extHostTask.ts index 04836f73af8..99f5368de6f 100644 --- a/src/vs/workbench/api/node/extHostTask.ts +++ b/src/vs/workbench/api/node/extHostTask.ts @@ -310,7 +310,11 @@ namespace Tasks { } let result: TaskSystem.Task = { _id: uuidMap.getUUID(task.identifier), - _source: { kind: TaskSystem.TaskSourceKind.Extension, detail: extension.id }, + _source: { + kind: TaskSystem.TaskSourceKind.Extension, + label: typeof task.source === 'string' ? task.source : extension.name, + detail: extension.id + }, name: task.name, identifier: task.identifier, group: types.TaskGroup.is(task.group) ? task.group : undefined, diff --git a/src/vs/workbench/api/node/extHostTypes.ts b/src/vs/workbench/api/node/extHostTypes.ts index d78f0d8d75e..87509da1649 100644 --- a/src/vs/workbench/api/node/extHostTypes.ts +++ b/src/vs/workbench/api/node/extHostTypes.ts @@ -1021,6 +1021,8 @@ export class BaseTask { private _problemMatchers: string[]; private _identifier: string; private _isBackground: boolean; + private _source: string; + private _group: string; private _terminal: vscode.TerminalBehaviour; constructor(name: string, problemMatchers: string[]) { @@ -1063,6 +1065,36 @@ export class BaseTask { this._isBackground = value; } + get source(): string { + return this._source; + } + + set source(value: string) { + if (value === void 0 || value === null) { + this._source = undefined; + return; + } + if (typeof value !== 'string' || value.length === 0) { + throw illegalArgument('source must be a string of length > 0'); + } + this._source = value; + } + + get group(): string { + return this._group; + } + + set group(value: string) { + if (value === void 0 || value === null) { + this._group = undefined; + return; + } + if (typeof value !== 'string' || value.length === 0) { + throw illegalArgument('group must be a string of length > 0'); + } + this._group = value; + } + get terminal(): vscode.TerminalBehaviour { return this._terminal; } @@ -1122,7 +1154,7 @@ export namespace TaskGroup { */ export const Test: 'test' = 'test'; - export function is(value: string): value is vscode.TaskGroup { + export function is(value: string): value is string { return value === Clean || value === Build || value === RebuildAll || value === Test; } } @@ -1131,7 +1163,6 @@ export class ProcessTask extends BaseTask { private _process: string; private _args: string[]; - private _group: vscode.TaskGroup; private _options: vscode.ProcessOptions; constructor(name: string, process: string, args?: string[], problemMatchers?: vscode.ProblemMatchers); @@ -1183,17 +1214,6 @@ export class ProcessTask extends BaseTask { this._args = value; } - get group(): vscode.TaskGroup { - return this._group; - } - - set group(value: vscode.TaskGroup) { - if (!TaskGroup.is(value)) { - throw illegalArgument('group'); - } - this._group = value; - } - get options(): vscode.ProcessOptions { return this._options; } @@ -1209,7 +1229,6 @@ export class ProcessTask extends BaseTask { export class ShellTask extends BaseTask implements vscode.ShellTask { private _commandLine: string; - private _group: vscode.TaskGroup; private _options: vscode.ShellOptions; constructor(name: string, commandLine: string, problemMatchers?: vscode.ProblemMatchers); @@ -1240,17 +1259,6 @@ export class ShellTask extends BaseTask implements vscode.ShellTask { return this._commandLine; } - get group(): vscode.TaskGroup { - return this._group; - } - - set group(value: vscode.TaskGroup) { - if (!TaskGroup.is(value)) { - throw illegalArgument('group'); - } - this._group = value; - } - get options(): vscode.ShellOptions { return this._options; } diff --git a/src/vs/workbench/parts/tasks/browser/quickOpen.ts b/src/vs/workbench/parts/tasks/browser/quickOpen.ts index fe5ec004ee4..15432e9c647 100644 --- a/src/vs/workbench/parts/tasks/browser/quickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/quickOpen.ts @@ -19,13 +19,19 @@ import { ActionBarContributor, ContributableActionProvider } from 'vs/workbench/ export class TaskEntry extends Model.QuickOpenEntry { + private _label: string; + constructor(protected taskService: ITaskService, protected _task: Task, highlights: Model.IHighlight[] = []) { super(highlights); - this._task = _task; + if (_task._source.kind === TaskSourceKind.Extension) { + this._label = nls.localize('taskEntry.label', '{0}: {1}', _task._source.label, _task.name); + } else { + this._label = _task.name; + } } public getLabel(): string { - return this._task.name; + return this._label; } public getAriaLabel(): string { @@ -76,6 +82,12 @@ export abstract class QuickOpenHandler extends Quickopen.QuickOpenHandler { let aKind = a._source.kind; let bKind = b._source.kind; if (aKind === bKind) { + if (aKind === TaskSourceKind.Extension) { + let compare = a._source.label.localeCompare(b._source.label); + if (compare !== 0) { + return compare; + } + } return a.name.localeCompare(b.name); } if (aKind === TaskSourceKind.Workspace) { diff --git a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts index 09fa78dfd77..a7ccb15f65e 100644 --- a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts +++ b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts @@ -764,6 +764,7 @@ namespace TaskDescription { export let source: Tasks.TaskSource = { kind: Tasks.TaskSourceKind.Workspace, + label: 'Workspace', detail: '.settins\tasks.json' }; diff --git a/src/vs/workbench/parts/tasks/common/tasks.ts b/src/vs/workbench/parts/tasks/common/tasks.ts index c3e90f83fb6..e7d54343b07 100644 --- a/src/vs/workbench/parts/tasks/common/tasks.ts +++ b/src/vs/workbench/parts/tasks/common/tasks.ts @@ -153,7 +153,7 @@ export namespace TaskGroup { export const Test: 'test' = 'test'; - export function is(value: string): value is TaskGroup { + export function is(value: string): value is string { return value === Clean || value === Build || value === RebuildAll || value === Test; } } @@ -168,6 +168,7 @@ export enum TaskSourceKind { export interface TaskSource { kind: TaskSourceKind; + label: string; detail?: string; } @@ -199,7 +200,7 @@ export interface Task { /** * the task's group; */ - group?: TaskGroup; + group?: string; /** * The command configuration diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index 68b32dfc244..d94812a35bb 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -780,7 +780,7 @@ class TaskService extends EventEmitter implements ITaskService { let id: string = UUID.generateUuid(); let task: Task = { _id: id, - _source: { kind: TaskSourceKind.Generic }, + _source: { kind: TaskSourceKind.Generic, label: 'generic' }, name: id, identifier: id, dependsOn: extensionTasks.map(task => task._id), diff --git a/src/vs/workbench/parts/tasks/test/node/configuration.test.ts b/src/vs/workbench/parts/tasks/test/node/configuration.test.ts index cbccf978e9d..c958d68336b 100644 --- a/src/vs/workbench/parts/tasks/test/node/configuration.test.ts +++ b/src/vs/workbench/parts/tasks/test/node/configuration.test.ts @@ -144,7 +144,7 @@ class TaskBuilder { this.commandBuilder = new CommandConfigurationBuilder(this, command); this.result = { _id: name, - _source: { kind: Tasks.TaskSourceKind.Workspace }, + _source: { kind: Tasks.TaskSourceKind.Workspace, label: 'workspace' }, identifier: name, name: name, command: this.commandBuilder.result, -- GitLab From 632837a8708dbd1859c701b2b3eeda08d3d2eadd Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Mon, 29 May 2017 14:46:27 +0200 Subject: [PATCH 0250/1347] Added debug log to find out where Windows build fails. --- test/smoke/src/areas/git.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/smoke/src/areas/git.ts b/test/smoke/src/areas/git.ts index 8228771a7d7..3c04f448328 100644 --- a/test/smoke/src/areas/git.ts +++ b/test/smoke/src/areas/git.ts @@ -39,6 +39,7 @@ export class Git { } public async stageFile(fileName: string): Promise { + console.log('Stage file' + fileName); await this.spectron.client.moveToObject(`div[class="monaco-icon-label file-icon ${fileName}-name-file-icon ${this.commonActions.getExtensionSelector(fileName)}"`); await this.spectron.client.click('.action-label.icon.contrib-cmd-icon-4'); return this.spectron.wait(); @@ -55,15 +56,18 @@ export class Git { } public focusOnCommitBox(): Promise { + console.log('Focus on commit box'); return this.spectron.client.click('div[id="workbench.view.scm"] textarea'); } public async pressCommit(): Promise { + console.log('Press commit'); await this.spectron.client.click('.action-label.icon.contrib-cmd-icon-10'); return this.spectron.wait(); } public getOutgoingChanges(): Promise { + console.log('Get outgoing code'); return this.spectron.client.getText('a[title="Synchronize changes"]'); } } \ No newline at end of file -- GitLab From bf5bb9de5c0049b72ca3a506917af64241e5dc4a Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Mon, 29 May 2017 14:50:16 +0200 Subject: [PATCH 0251/1347] Implements #27087: Simplify task activation events --- extensions/grunt/package.json | 4 +--- extensions/gulp/package.json | 4 +--- extensions/jake/package.json | 4 +--- extensions/npm/package.json | 4 +--- extensions/typescript/package.json | 4 +--- 5 files changed, 5 insertions(+), 15 deletions(-) diff --git a/extensions/grunt/package.json b/extensions/grunt/package.json index e3338dd8d34..e8bac905a69 100644 --- a/extensions/grunt/package.json +++ b/extensions/grunt/package.json @@ -22,9 +22,7 @@ }, "main": "./out/main", "activationEvents": [ - "onCommand:workbench.action.tasks.runTask", - "onCommand:workbench.action.tasks.build", - "onCommand:workbench.action.tasks.test" + "onCommand:workbench.action.tasks.runTask" ], "contributes": { "configuration": { diff --git a/extensions/gulp/package.json b/extensions/gulp/package.json index 0d1d70f9e1e..5ec491853fe 100644 --- a/extensions/gulp/package.json +++ b/extensions/gulp/package.json @@ -22,9 +22,7 @@ }, "main": "./out/main", "activationEvents": [ - "onCommand:workbench.action.tasks.runTask", - "onCommand:workbench.action.tasks.build", - "onCommand:workbench.action.tasks.test" + "onCommand:workbench.action.tasks.runTask" ], "contributes": { "configuration": { diff --git a/extensions/jake/package.json b/extensions/jake/package.json index dd34c9b2235..ee5a916ade5 100644 --- a/extensions/jake/package.json +++ b/extensions/jake/package.json @@ -22,9 +22,7 @@ }, "main": "./out/main", "activationEvents": [ - "onCommand:workbench.action.tasks.runTask", - "onCommand:workbench.action.tasks.build", - "onCommand:workbench.action.tasks.test" + "onCommand:workbench.action.tasks.runTask" ], "contributes": { "configuration": { diff --git a/extensions/npm/package.json b/extensions/npm/package.json index e6a6a3ec4fa..9d626265d36 100644 --- a/extensions/npm/package.json +++ b/extensions/npm/package.json @@ -23,9 +23,7 @@ }, "main": "./out/main", "activationEvents": [ - "onCommand:workbench.action.tasks.runTask", - "onCommand:workbench.action.tasks.build", - "onCommand:workbench.action.tasks.test" + "onCommand:workbench.action.tasks.runTask" ], "contributes": { "configuration": { diff --git a/extensions/typescript/package.json b/extensions/typescript/package.json index cff9784cabe..11b75cfc26b 100644 --- a/extensions/typescript/package.json +++ b/extensions/typescript/package.json @@ -35,9 +35,7 @@ "onCommand:javascript.goToProjectConfig", "onCommand:typescript.goToProjectConfig", "onCommand:typescript.openTsServerLog", - "onCommand:workbench.action.tasks.runTask", - "onCommand:workbench.action.tasks.build", - "onCommand:workbench.action.tasks.test" + "onCommand:workbench.action.tasks.runTask" ], "main": "./out/typescriptMain", "contributes": { -- GitLab From c25eb69604f19b405d7a28281285be6831e94b76 Mon Sep 17 00:00:00 2001 From: isidor Date: Mon, 29 May 2017 14:58:29 +0200 Subject: [PATCH 0252/1347] show update activity for all platforms but only for insider quality --- .../parts/update/electron-browser/update.contribution.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/update/electron-browser/update.contribution.ts b/src/vs/workbench/parts/update/electron-browser/update.contribution.ts index 39c771ee7c9..26cc50dfe8e 100644 --- a/src/vs/workbench/parts/update/electron-browser/update.contribution.ts +++ b/src/vs/workbench/parts/update/electron-browser/update.contribution.ts @@ -8,7 +8,7 @@ import * as nls from 'vs/nls'; import 'vs/css!./media/update.contribution'; import { Registry } from 'vs/platform/platform'; -import { isMacintosh } from 'vs/base/common/platform'; +import product from 'vs/platform/node/product'; import { IWorkbenchContributionsRegistry, Extensions as WorkbenchExtensions } from 'vs/workbench/common/contributions'; import { ReleaseNotesEditor } from 'vs/workbench/parts/update/electron-browser/releaseNotesEditor'; import { ReleaseNotesInput } from 'vs/workbench/parts/update/electron-browser/releaseNotesInput'; @@ -24,7 +24,7 @@ import { ShowCurrentReleaseNotesAction, ProductContribution, UpdateContribution, Registry.as(WorkbenchExtensions.Workbench) .registerWorkbenchContribution(ProductContribution); -if (isMacintosh) { +if (product.quality === 'insider') { Registry.as(GlobalActivityExtensions) .registerActivity(LightUpdateContribution); } else { -- GitLab From 03fa5a859d5b6da6d70a1cecc2bb6aad5f13bfff Mon Sep 17 00:00:00 2001 From: isidor Date: Mon, 29 May 2017 15:02:48 +0200 Subject: [PATCH 0253/1347] use a wrench icon for the update activity --- .../workbench/parts/update/electron-browser/media/update.svg | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/vs/workbench/parts/update/electron-browser/media/update.svg b/src/vs/workbench/parts/update/electron-browser/media/update.svg index 637b2ad42de..3dec2ba50fd 100644 --- a/src/vs/workbench/parts/update/electron-browser/media/update.svg +++ b/src/vs/workbench/parts/update/electron-browser/media/update.svg @@ -1,3 +1 @@ - - - + \ No newline at end of file -- GitLab From 91988af341f2379c0c0312f433a6ea9f5fce5dc5 Mon Sep 17 00:00:00 2001 From: isidor Date: Mon, 29 May 2017 15:12:55 +0200 Subject: [PATCH 0254/1347] update activity: action labels to better reflect os --- .../parts/update/electron-browser/update.ts | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/update/electron-browser/update.ts b/src/vs/workbench/parts/update/electron-browser/update.ts index ff79f211a37..323a9e07181 100644 --- a/src/vs/workbench/parts/update/electron-browser/update.ts +++ b/src/vs/workbench/parts/update/electron-browser/update.ts @@ -28,7 +28,7 @@ import { IWorkbenchContribution } from 'vs/workbench/common/contributions'; import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage'; import { IUpdateService, State as UpdateState } from 'vs/platform/update/common/update'; import * as semver from 'semver'; -import { OS } from 'vs/base/common/platform'; +import { OS, isLinux, isWindows } from 'vs/base/common/platform'; class ApplyUpdateAction extends Action { constructor( @IUpdateService private updateService: IUpdateService) { @@ -308,7 +308,17 @@ export class LightUpdateContribution implements IGlobalActivity { return [new Action('update.checking', nls.localize('checkingForUpdates', "Checking For Updates..."), undefined, false)]; case UpdateState.UpdateAvailable: - return [new Action('update.installing', nls.localize('installingUpdate', "Installing Update..."), undefined, false)]; + if (isLinux) { + return [new Action('update.linux.available', nls.localize('DownloadUpdate', "Download Available Update"), undefined, true, () => + this.updateService.quitAndInstall() + )]; + } + + const updateAvailableLabel = isWindows + ? nls.localize('DownloadingUpdate', "Downloading Update...") + : nls.localize('InstallingUpdate', "Installing Update..."); + + return [new Action('update.available', updateAvailableLabel, undefined, false)]; case UpdateState.UpdateDownloaded: return [new Action('update.restart', nls.localize('restartToUpdate', "Restart To Update..."), undefined, true, () => -- GitLab From 87adb8d06a9d77794bf10a5b5c57896d01b60206 Mon Sep 17 00:00:00 2001 From: isidor Date: Mon, 29 May 2017 15:30:51 +0200 Subject: [PATCH 0255/1347] add more actions to the update activity --- .../parts/update/electron-browser/update.ts | 33 ++++++++++++------- 1 file changed, 21 insertions(+), 12 deletions(-) diff --git a/src/vs/workbench/parts/update/electron-browser/update.ts b/src/vs/workbench/parts/update/electron-browser/update.ts index 323a9e07181..cfdf028a841 100644 --- a/src/vs/workbench/parts/update/electron-browser/update.ts +++ b/src/vs/workbench/parts/update/electron-browser/update.ts @@ -9,6 +9,7 @@ import nls = require('vs/nls'); import severity from 'vs/base/common/severity'; import { TPromise } from 'vs/base/common/winjs.base'; import { IAction, Action } from 'vs/base/common/actions'; +import { Separator } from 'vs/base/browser/ui/actionbar/actionbar'; import { IMessageService, CloseAction, Severity } from 'vs/platform/message/common/message'; import pkg from 'vs/platform/node/package'; import product from 'vs/platform/node/product'; @@ -300,35 +301,43 @@ export class LightUpdateContribution implements IGlobalActivity { } getActions(): IAction[] { + return [ + new Action('showCommandPalette', nls.localize('commandPalette', "Command Palette..."), undefined, true, () => this.commandService.executeCommand('workbench.action.showCommands')), + new Separator(), + new Action('openKeybindings', nls.localize('settings', "Settings"), null, true, () => this.commandService.executeCommand('workbench.action.openGlobalSettings')), + new Action('openSettings', nls.localize('keyboardShortcuts', "Keyboard Shortcuts"), null, true, () => this.commandService.executeCommand('workbench.action.openGlobalKeybindings')), + new Separator(), + this.getUpdateAction() + ]; + } + + private getUpdateAction(): IAction { switch (this.updateService.state) { case UpdateState.Uninitialized: - return [new Action('update.notavailable', nls.localize('not available', "Updates Not Available"), undefined, false)]; + return new Action('update.notavailable', nls.localize('not available', "Updates Not Available"), undefined, false); case UpdateState.CheckingForUpdate: - return [new Action('update.checking', nls.localize('checkingForUpdates', "Checking For Updates..."), undefined, false)]; + return new Action('update.checking', nls.localize('checkingForUpdates', "Checking For Updates..."), undefined, false); case UpdateState.UpdateAvailable: if (isLinux) { - return [new Action('update.linux.available', nls.localize('DownloadUpdate', "Download Available Update"), undefined, true, () => - this.updateService.quitAndInstall() - )]; + return new Action('update.linux.available', nls.localize('DownloadUpdate', "Download Available Update"), undefined, true, () => + this.updateService.quitAndInstall()); } const updateAvailableLabel = isWindows ? nls.localize('DownloadingUpdate', "Downloading Update...") : nls.localize('InstallingUpdate', "Installing Update..."); - return [new Action('update.available', updateAvailableLabel, undefined, false)]; + return new Action('update.available', updateAvailableLabel, undefined, false); case UpdateState.UpdateDownloaded: - return [new Action('update.restart', nls.localize('restartToUpdate', "Restart To Update..."), undefined, true, () => - this.updateService.quitAndInstall() - )]; + return new Action('update.restart', nls.localize('restartToUpdate', "Restart To Update..."), undefined, true, () => + this.updateService.quitAndInstall()); default: - return [new Action('update.check', nls.localize('checkForUpdates', "Check For Updates..."), undefined, this.updateService.state === UpdateState.Idle, () => - this.updateService.checkForUpdates(true) - )]; + return new Action('update.check', nls.localize('checkForUpdates', "Check For Updates..."), undefined, this.updateService.state === UpdateState.Idle, () => + this.updateService.checkForUpdates(true)); } } } \ No newline at end of file -- GitLab From fdadd0ed5fd39deebe8fb9e0ac5bd6efb4dfb94e Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Mon, 29 May 2017 15:38:55 +0200 Subject: [PATCH 0256/1347] Make identifier computed to better support task customization --- src/vs/vscode.d.ts | 12 ++++++------ src/vs/workbench/api/node/extHostTask.ts | 2 +- src/vs/workbench/api/node/extHostTypes.ts | 9 ++++----- src/vs/workbench/parts/tasks/browser/quickOpen.ts | 8 ++------ src/vs/workbench/parts/tasks/common/tasks.ts | 9 +++++++++ .../parts/tasks/electron-browser/jsonSchema_v2.ts | 12 +++++++++--- .../tasks/electron-browser/task.contribution.ts | 6 ++++-- 7 files changed, 35 insertions(+), 23 deletions(-) diff --git a/src/vs/vscode.d.ts b/src/vs/vscode.d.ts index 979822a1f4d..a2de9d4811a 100644 --- a/src/vs/vscode.d.ts +++ b/src/vs/vscode.d.ts @@ -3626,10 +3626,10 @@ declare module 'vscode' { readonly name: string; /** - * The task's identifier. If omitted the name is - * used as an identifier. + * The task's identifier. If omitted the internal identifier will + * be `${extensionName}:${name}` */ - identifier: string; + identifier: string | undefined; /** * Whether the task is a background task or not. @@ -3759,10 +3759,10 @@ declare module 'vscode' { readonly name: string; /** - * The task's identifier. If omitted the name is - * used as an identifier. + * The task's identifier. If omitted the internal identifier will + * be `${extensionName}:${name}` */ - identifier: string; + identifier: string | undefined; /** * Whether the task is a background task or not. diff --git a/src/vs/workbench/api/node/extHostTask.ts b/src/vs/workbench/api/node/extHostTask.ts index 99f5368de6f..7508d947d45 100644 --- a/src/vs/workbench/api/node/extHostTask.ts +++ b/src/vs/workbench/api/node/extHostTask.ts @@ -316,7 +316,7 @@ namespace Tasks { detail: extension.id }, name: task.name, - identifier: task.identifier, + identifier: task.identifier ? task.identifier : `${extension.id}.${task.name}`, group: types.TaskGroup.is(task.group) ? task.group : undefined, command: command, isBackground: !!task.isBackground, diff --git a/src/vs/workbench/api/node/extHostTypes.ts b/src/vs/workbench/api/node/extHostTypes.ts index 87509da1649..2912a30ef42 100644 --- a/src/vs/workbench/api/node/extHostTypes.ts +++ b/src/vs/workbench/api/node/extHostTypes.ts @@ -1030,7 +1030,6 @@ export class BaseTask { throw illegalArgument('name'); } this._name = name; - this._identifier = name; this._problemMatchers = problemMatchers || []; this._isBackground = false; this._terminal = Object.create(null); @@ -1041,11 +1040,11 @@ export class BaseTask { } set identifier(value: string) { - if (typeof value !== 'string') { - throw illegalArgument('identifier'); + if (value === void 0 || value === null) { + this._identifier = undefined; } - if (value.indexOf(':') !== -1) { - throw illegalArgument('identifier must not contain \':\''); + if (typeof value !== 'string' || value.length === 0) { + throw illegalArgument('identifier must be a string of length > 0'); } this._identifier = value; } diff --git a/src/vs/workbench/parts/tasks/browser/quickOpen.ts b/src/vs/workbench/parts/tasks/browser/quickOpen.ts index 15432e9c647..6f82d048270 100644 --- a/src/vs/workbench/parts/tasks/browser/quickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/quickOpen.ts @@ -13,7 +13,7 @@ import QuickOpen = require('vs/base/parts/quickopen/common/quickOpen'); import Model = require('vs/base/parts/quickopen/browser/quickOpenModel'); import { IQuickOpenService } from 'vs/platform/quickOpen/common/quickOpen'; -import { Task, TaskSourceKind } from 'vs/workbench/parts/tasks/common/tasks'; +import { Task, TaskSourceKind, computeLabel } from 'vs/workbench/parts/tasks/common/tasks'; import { ITaskService } from 'vs/workbench/parts/tasks/common/taskService'; import { ActionBarContributor, ContributableActionProvider } from 'vs/workbench/browser/actionBarRegistry'; @@ -23,11 +23,7 @@ export class TaskEntry extends Model.QuickOpenEntry { constructor(protected taskService: ITaskService, protected _task: Task, highlights: Model.IHighlight[] = []) { super(highlights); - if (_task._source.kind === TaskSourceKind.Extension) { - this._label = nls.localize('taskEntry.label', '{0}: {1}', _task._source.label, _task.name); - } else { - this._label = _task.name; - } + this._label = computeLabel(_task); } public getLabel(): string { diff --git a/src/vs/workbench/parts/tasks/common/tasks.ts b/src/vs/workbench/parts/tasks/common/tasks.ts index e7d54343b07..b798e6314e5 100644 --- a/src/vs/workbench/parts/tasks/common/tasks.ts +++ b/src/vs/workbench/parts/tasks/common/tasks.ts @@ -4,6 +4,7 @@ *--------------------------------------------------------------------------------------------*/ 'use strict'; +import nls = require('vs/nls'); import * as Types from 'vs/base/common/types'; import { IExtensionDescription } from 'vs/platform/extensions/common/extensions'; @@ -248,4 +249,12 @@ export enum ExecutionEngine { export interface TaskSet { tasks: Task[]; extension?: IExtensionDescription; +} + +export function computeLabel(task: Task): string { + if (task._source.kind === TaskSourceKind.Extension) { + return nls.localize('taskEntry.label', '{0}: {1}', task._source.label, task.name); + } else { + return task.name; + } } \ No newline at end of file diff --git a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts index b184d7ee3ff..e12e519fc02 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts @@ -67,20 +67,25 @@ const group: IJSONSchema = { type: 'string', enum: ['none', 'clean', 'build', 'rebuildAll', 'test'], default: 'none', - description: nls.localize('JsonSchema.tasks.group', 'Defines to which execution group this task belongs to. If omitted the task belongs to no group') + description: nls.localize('JsonSchema.tasks.group', 'Defines to which execution group this task belongs to. If omitted the task belongs to no group.') }; const taskType: IJSONSchema = { type: 'string', enum: ['shell', 'process'], default: 'process', - description: nls.localize('JsonSchema.tasks.type', 'Defines whether the task is run as a process or as a command inside a shell. Default is process') + description: nls.localize('JsonSchema.tasks.type', 'Defines whether the task is run as a process or as a command inside a shell. Default is process.') }; const version: IJSONSchema = { type: 'string', enum: ['2.0.0'], - description: nls.localize('JsonSchema.version', 'The config\'s version number') + description: nls.localize('JsonSchema.version', 'The config\'s version number.') +}; + +const identifier: IJSONSchema = { + type: 'string', + description: nls.localize('JsonSchema.tasks.identifier', 'A unique identifier of the task.') }; const schema: IJSONSchema = { @@ -123,6 +128,7 @@ definitions.showOutputType.deprecationMessage = nls.localize('JsonSchema.tasks.s definitions.taskDescription.properties.echoCommand.deprecationMessage = nls.localize('JsonSchema.tasks.echoCommand.deprecated', 'The property echoCommand is deprecated. Use the terminal property instead.'); definitions.taskDescription.properties.isBuildCommand.deprecationMessage = nls.localize('JsonSchema.tasks.isBuildCommand.deprecated', 'The property isBuildCommand is deprecated. Use the group property instead.'); definitions.taskDescription.properties.isTestCommand.deprecationMessage = nls.localize('JsonSchema.tasks.isTestCommand.deprecated', 'The property isTestCommand is deprecated. Use the group property instead.'); +definitions.taskDescription.properties.identifier = identifier; definitions.taskDescription.properties.type = Objects.deepClone(taskType); definitions.taskDescription.properties.terminal = terminal; definitions.taskDescription.properties.group = group; diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index d94812a35bb..411e04c6df5 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -71,7 +71,7 @@ import { Scope, IActionBarRegistry, Extensions as ActionBarExtensions } from 'vs import { ITerminalService } from 'vs/workbench/parts/terminal/common/terminal'; import { ITaskSystem, ITaskResolver, ITaskSummary, ITaskExecuteResult, TaskExecuteKind, TaskError, TaskErrors, TaskSystemEvents } from 'vs/workbench/parts/tasks/common/taskSystem'; -import { Task, TaskSet, TaskGroup, ExecutionEngine, TaskSourceKind } from 'vs/workbench/parts/tasks/common/tasks'; +import { Task, TaskSet, TaskGroup, ExecutionEngine, TaskSourceKind, computeLabel as computeTaskLabel } from 'vs/workbench/parts/tasks/common/tasks'; import { ITaskService, TaskServiceEvents, ITaskProvider } from 'vs/workbench/parts/tasks/common/taskService'; import { templates as taskTemplates } from 'vs/workbench/parts/tasks/common/taskTemplates'; @@ -709,7 +709,7 @@ class TaskService extends EventEmitter implements ITaskService { return TPromise.as(undefined); } let fileConfig = configuration.config; - let customize = { taskName: task.name }; + let customize = { taskName: computeTaskLabel(task), identifier: task.identifier }; if (!fileConfig) { fileConfig = { version: '2.0.0', @@ -931,6 +931,7 @@ class TaskService extends EventEmitter implements ITaskService { let annotatingTask = annotatingTasks.byIdentifier[task.identifier] || annotatingTasks.byName[task.name]; if (annotatingTask) { TaskConfig.mergeTasks(task, annotatingTask); + task.name = annotatingTask.name; task._source.kind = TaskSourceKind.Workspace; continue; } @@ -940,6 +941,7 @@ class TaskService extends EventEmitter implements ITaskService { if (legacyAnnotatingTask) { TaskConfig.mergeTasks(task, legacyAnnotatingTask); task._source.kind = TaskSourceKind.Workspace; + task.name = legacyAnnotatingTask.name; workspaceTasksToDelete.push(legacyAnnotatingTask); continue; } -- GitLab From d9b33cf00ad979aee77a4b714297d9ede80b3547 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Mon, 29 May 2017 15:44:13 +0200 Subject: [PATCH 0257/1347] Attempt to fix git test 'element not visible' error. --- test/smoke/src/areas/git.ts | 5 +---- test/smoke/src/test.ts | 2 +- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/test/smoke/src/areas/git.ts b/test/smoke/src/areas/git.ts index 3c04f448328..58dcd1e9b3e 100644 --- a/test/smoke/src/areas/git.ts +++ b/test/smoke/src/areas/git.ts @@ -39,8 +39,8 @@ export class Git { } public async stageFile(fileName: string): Promise { - console.log('Stage file' + fileName); await this.spectron.client.moveToObject(`div[class="monaco-icon-label file-icon ${fileName}-name-file-icon ${this.commonActions.getExtensionSelector(fileName)}"`); + await this.spectron.wait(); await this.spectron.client.click('.action-label.icon.contrib-cmd-icon-4'); return this.spectron.wait(); } @@ -56,18 +56,15 @@ export class Git { } public focusOnCommitBox(): Promise { - console.log('Focus on commit box'); return this.spectron.client.click('div[id="workbench.view.scm"] textarea'); } public async pressCommit(): Promise { - console.log('Press commit'); await this.spectron.client.click('.action-label.icon.contrib-cmd-icon-10'); return this.spectron.wait(); } public getOutgoingChanges(): Promise { - console.log('Get outgoing code'); return this.spectron.client.getText('a[title="Synchronize changes"]'); } } \ No newline at end of file diff --git a/test/smoke/src/test.ts b/test/smoke/src/test.ts index 70cc2f5d322..998616c0297 100644 --- a/test/smoke/src/test.ts +++ b/test/smoke/src/test.ts @@ -18,7 +18,7 @@ import { testTasks } from "./tests/tasks"; import { testExtensions } from "./tests/extensions"; import { testLocalization } from "./tests/localization"; -describe('Smoke Test Suite', async () => { +describe('Smoke Test Suite', () => { testDataMigration(); testDataLoss(); testExplorer(); -- GitLab From ccd3c1f94e64f7798ddf30d187274bd8905593fd Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Mon, 29 May 2017 15:50:50 +0200 Subject: [PATCH 0258/1347] [c++] grammar in endless loop. Fixes #23850 --- extensions/cpp/OSSREADME.json | 2 +- extensions/cpp/syntaxes/c.json | 22 ++-- .../cpp/test/colorize-fixtures/test-23630.cpp | 3 + .../test/colorize-results/test-23630_cpp.json | 123 ++++++++++++++++++ 4 files changed, 138 insertions(+), 12 deletions(-) create mode 100644 extensions/cpp/test/colorize-fixtures/test-23630.cpp create mode 100644 extensions/cpp/test/colorize-results/test-23630_cpp.json diff --git a/extensions/cpp/OSSREADME.json b/extensions/cpp/OSSREADME.json index 58859a1b776..5137487d2ed 100644 --- a/extensions/cpp/OSSREADME.json +++ b/extensions/cpp/OSSREADME.json @@ -2,7 +2,7 @@ [ { "name": "atom/language-c", - "version": "0.51.3", + "version": "0.0.0", "license": "MIT", "repositoryURL": "https://github.com/atom/language-c", "description": "The files syntaxes/c.json and syntaxes/c++.json were derived from the Atom package https://atom.io/packages/language-c which was originally converted from the C TextMate bundle https://github.com/textmate/c.tmbundle." diff --git a/extensions/cpp/syntaxes/c.json b/extensions/cpp/syntaxes/c.json index 022f588cf28..b83b31ad22e 100644 --- a/extensions/cpp/syntaxes/c.json +++ b/extensions/cpp/syntaxes/c.json @@ -778,7 +778,7 @@ }, "patterns": [ { - "begin": "\\G", + "begin": "\\G(?=.)", "end": "(?=//)|(?=/\\*(?!.*\\\\\\s*\\n))|(? Date: Mon, 29 May 2017 16:07:38 +0200 Subject: [PATCH 0259/1347] node-debug: add 'subtle' value to 'presentationhint' attribute --- src/vs/workbench/parts/debug/common/debugProtocol.d.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/debug/common/debugProtocol.d.ts b/src/vs/workbench/parts/debug/common/debugProtocol.d.ts index b6b16f7ad5b..a8ec4386a55 100644 --- a/src/vs/workbench/parts/debug/common/debugProtocol.d.ts +++ b/src/vs/workbench/parts/debug/common/debugProtocol.d.ts @@ -1123,8 +1123,8 @@ declare module DebugProtocol { endColumn?: number; /** The module associated with this frame, if any. */ moduleId?: number | string; - /** An optional hint for how to present this frame in the UI. A value of 'label' can be used to indicate that the frame is an artificial frame that is used as a visual label or separator. */ - presentationHint?: 'normal' | 'label'; + /** An optional hint for how to present this frame in the UI. A value of 'label' can be used to indicate that the frame is an artificial frame that is used as a visual label or separator. A value of 'subtle' can be used to change the appearance of a frame in a 'subtle' way. */ + presentationHint?: 'normal' | 'label' | 'subtle'; } /** A Scope is a named container for variables. Optionally a scope can map to a source or a range within a source. */ -- GitLab From 862088c2b1b0ba7ebfba1d71fc90f16bd7e94523 Mon Sep 17 00:00:00 2001 From: isidor Date: Mon, 29 May 2017 16:12:40 +0200 Subject: [PATCH 0260/1347] do not use a special badge for update notification --- .../browser/parts/activitybar/activitybarActions.ts | 9 +-------- .../browser/parts/activitybar/media/activityaction.css | 10 ---------- .../workbench/parts/update/electron-browser/update.ts | 6 +++--- .../services/activity/common/activityBarService.ts | 2 -- 4 files changed, 4 insertions(+), 23 deletions(-) diff --git a/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts b/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts index 7711afeab12..cc95a89bdd0 100644 --- a/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts +++ b/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts @@ -13,7 +13,7 @@ import { Builder, $ } from 'vs/base/browser/builder'; import { DelayedDragHandler } from 'vs/base/browser/dnd'; import { Action } from 'vs/base/common/actions'; import { BaseActionItem, Separator, IBaseActionItemOptions } from 'vs/base/browser/ui/actionbar/actionbar'; -import { IActivityBarService, DotBadge, ProgressBadge, TextBadge, NumberBadge, IconBadge, IBadge } from 'vs/workbench/services/activity/common/activityBarService'; +import { IActivityBarService, ProgressBadge, TextBadge, NumberBadge, IconBadge, IBadge } from 'vs/workbench/services/activity/common/activityBarService'; import Event, { Emitter } from 'vs/base/common/event'; import { IContextMenuService } from 'vs/platform/contextview/browser/contextView'; import { ICommandService } from 'vs/platform/commands/common/commands'; @@ -206,13 +206,6 @@ export class ActivityActionItem extends BaseActionItem { this.$badge.show(); } - // Dot - else if (badge instanceof DotBadge) { - this.$badge.addClass('dot-badge'); - this.$badge.title(badge.getDescription()); - this.$badge.show(); - } - // Progress else if (badge instanceof ProgressBadge) { this.$badge.show(); diff --git a/src/vs/workbench/browser/parts/activitybar/media/activityaction.css b/src/vs/workbench/browser/parts/activitybar/media/activityaction.css index 2cc5e0c94bc..f9bb260bdbe 100644 --- a/src/vs/workbench/browser/parts/activitybar/media/activityaction.css +++ b/src/vs/workbench/browser/parts/activitybar/media/activityaction.css @@ -67,16 +67,6 @@ text-align: center; } -.monaco-workbench > .activitybar > .content .monaco-action-bar .badge.dot-badge .badge-content { - box-sizing: border-box; - content: ''; - top: 9px; - width: 11px; - height: 11px; - min-width: inherit; - padding: 0; -} - /* Right aligned */ .monaco-workbench > .activitybar.right > .content .monaco-action-bar .action-label { diff --git a/src/vs/workbench/parts/update/electron-browser/update.ts b/src/vs/workbench/parts/update/electron-browser/update.ts index cfdf028a841..4b8eff773df 100644 --- a/src/vs/workbench/parts/update/electron-browser/update.ts +++ b/src/vs/workbench/parts/update/electron-browser/update.ts @@ -15,7 +15,7 @@ import pkg from 'vs/platform/node/package'; import product from 'vs/platform/node/product'; import URI from 'vs/base/common/uri'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; -import { IActivityBarService, DotBadge } from 'vs/workbench/services/activity/common/activityBarService'; +import { IActivityBarService, TextBadge } from 'vs/workbench/services/activity/common/activityBarService'; import { IInstantiationService, ServicesAccessor } from 'vs/platform/instantiation/common/instantiation'; import { ReleaseNotesInput } from 'vs/workbench/parts/update/electron-browser/releaseNotesInput'; import { IGlobalActivity } from 'vs/workbench/browser/activity'; @@ -280,7 +280,7 @@ export class UpdateContribution implements IWorkbenchContribution { export class LightUpdateContribution implements IGlobalActivity { get id() { return 'vs.update'; } - get name() { return 'VS Code'; } + get name() { return ''; } get cssClass() { return 'update-activity'; } constructor( @@ -293,7 +293,7 @@ export class LightUpdateContribution implements IGlobalActivity { @IActivityBarService activityBarService: IActivityBarService ) { this.updateService.onUpdateReady(() => { - const badge = new DotBadge(() => nls.localize('updateIsReady', "New update available.")); + const badge = new TextBadge('\u21e9', () => nls.localize('updateIsReady', "New update available.")); activityBarService.showGlobalActivity(this.id, badge); }); diff --git a/src/vs/workbench/services/activity/common/activityBarService.ts b/src/vs/workbench/services/activity/common/activityBarService.ts index a07ea58e26a..5c5b18a2105 100644 --- a/src/vs/workbench/services/activity/common/activityBarService.ts +++ b/src/vs/workbench/services/activity/common/activityBarService.ts @@ -24,8 +24,6 @@ export class BaseBadge implements IBadge { } } -export class DotBadge extends BaseBadge { } - export class NumberBadge extends BaseBadge { public number: number; -- GitLab From 109435f8cff94ebe2e8119f1fa6560b1b9c6421e Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Mon, 29 May 2017 16:19:04 +0200 Subject: [PATCH 0261/1347] Fixed path to module. --- test/smoke/src/tests/statusbar.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/smoke/src/tests/statusbar.ts b/test/smoke/src/tests/statusbar.ts index 86a315daebc..63bcb9688b1 100644 --- a/test/smoke/src/tests/statusbar.ts +++ b/test/smoke/src/tests/statusbar.ts @@ -7,7 +7,7 @@ import * as assert from 'assert'; import { SpectronApplication, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; import { CommonActions } from '../areas/common'; -import { StatusBarElement, StatusBar } from "../areas/statusBar"; +import { StatusBarElement, StatusBar } from "../areas/statusbar"; let app: SpectronApplication; let common: CommonActions; -- GitLab From b0b5d17de1ad636aa943002f9ea6e064169b54b7 Mon Sep 17 00:00:00 2001 From: isidor Date: Mon, 29 May 2017 16:39:35 +0200 Subject: [PATCH 0262/1347] debug: suport presentationHint = "subtle" fixes #25162 --- src/vs/workbench/parts/debug/browser/media/debugViewlet.css | 4 ++++ .../workbench/parts/debug/electron-browser/debugViewer.ts | 6 ++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/debug/browser/media/debugViewlet.css b/src/vs/workbench/parts/debug/browser/media/debugViewlet.css index b0d6b4510a1..174bf9f39aa 100644 --- a/src/vs/workbench/parts/debug/browser/media/debugViewlet.css +++ b/src/vs/workbench/parts/debug/browser/media/debugViewlet.css @@ -207,6 +207,10 @@ font-style: italic; } +.debug-viewlet .debug-call-stack .stack-frame.subtle { + font-style: italic; +} + .debug-viewlet .debug-call-stack .stack-frame.label > .file { display: none; } diff --git a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts index 2c8391b709f..ea989342bbb 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts @@ -537,8 +537,10 @@ export class CallStackRenderer implements IRenderer { } private renderStackFrame(stackFrame: debug.IStackFrame, data: IStackFrameTemplateData): void { - stackFrame.source.presenationHint === 'deemphasize' ? dom.addClass(data.stackFrame, 'disabled') : dom.removeClass(data.stackFrame, 'disabled'); - stackFrame.source.presenationHint === 'label' ? dom.addClass(data.stackFrame, 'label') : dom.removeClass(data.stackFrame, 'label'); + dom.toggleClass(data.stackFrame, 'disabled', stackFrame.source.presenationHint === 'deemphasize'); + dom.toggleClass(data.stackFrame, 'label', stackFrame.source.presenationHint === 'label'); + dom.toggleClass(data.stackFrame, 'subtle', stackFrame.source.presenationHint === 'subtle'); + data.file.title = stackFrame.source.raw.path || stackFrame.source.name; if (stackFrame.source.raw.origin) { data.file.title += `\n${stackFrame.source.raw.origin}`; -- GitLab From afa75ce314939793a14081e47ac7e8ca9b03cb78 Mon Sep 17 00:00:00 2001 From: Andre Weinand Date: Mon, 29 May 2017 16:38:58 +0200 Subject: [PATCH 0263/1347] node-debug@1.13.7 (translations) --- build/gulpfile.vscode.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index cf894772b6a..e73e03c311d 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -42,7 +42,7 @@ const nodeModules = ['electron', 'original-fs'] // Build const builtInExtensions = [ - { name: 'ms-vscode.node-debug', version: '1.13.6' }, + { name: 'ms-vscode.node-debug', version: '1.13.7' }, { name: 'ms-vscode.node-debug2', version: '1.13.0' } ]; -- GitLab From 5b7b38d8a5ef6025dea1bc889f3719e5e9cd4ed1 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Mon, 29 May 2017 16:51:26 +0200 Subject: [PATCH 0264/1347] Have Ctrl+A go to line start on OSX (#19644) --- .../editor/common/controller/coreCommands.ts | 40 ++++++++++++++++++- 1 file changed, 39 insertions(+), 1 deletion(-) diff --git a/src/vs/editor/common/controller/coreCommands.ts b/src/vs/editor/common/controller/coreCommands.ts index e0a3cd88f63..b6372c58eb8 100644 --- a/src/vs/editor/common/controller/coreCommands.ts +++ b/src/vs/editor/common/controller/coreCommands.ts @@ -815,10 +815,48 @@ export namespace CoreNavigationCommands { weight: CORE_WEIGHT, kbExpr: EditorContextKeys.textFocus, primary: KeyCode.Home, - mac: { primary: KeyCode.Home, secondary: [KeyMod.CtrlCmd | KeyCode.LeftArrow, KeyMod.WinCtrl | KeyCode.KEY_A] } + mac: { primary: KeyCode.Home, secondary: [KeyMod.CtrlCmd | KeyCode.LeftArrow] } } })); + export const CursorLineStart: CoreEditorCommand = registerEditorCommand(new class extends CoreEditorCommand { + constructor() { + super({ + id: 'cursorLineStart', + precondition: null, + kbOpts: { + weight: CORE_WEIGHT, + kbExpr: EditorContextKeys.textFocus, + primary: 0, + mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_A } + } + }); + } + + public runCoreEditorCommand(cursors: ICursors, args: any): void { + cursors.context.model.pushStackElement(); + cursors.setStates( + args.source, + CursorChangeReason.Explicit, + CursorState.ensureInEditableRange( + cursors.context, + this._exec(cursors.context, cursors.getAll()) + ) + ); + cursors.reveal(true, RevealTarget.Primary); + } + + private _exec(context: CursorContext, cursors: CursorState[]): CursorState[] { + let result: CursorState[] = []; + for (let i = 0, len = cursors.length; i < len; i++) { + const cursor = cursors[i]; + const lineNumber = cursor.modelState.position.lineNumber; + result[i] = CursorState.fromModelState(cursor.modelState.move(false, lineNumber, 1, 0)); + } + return result; + } + }); + export const CursorHomeSelect: CoreEditorCommand = registerEditorCommand(new HomeCommand({ inSelectionMode: true, id: 'cursorHomeSelect', -- GitLab From f43e78769ba24714a2007364d4b8d99dd34a4a85 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Mon, 29 May 2017 16:54:52 +0200 Subject: [PATCH 0265/1347] Have Ctrl+E go to line end on OSX --- .../editor/common/controller/coreCommands.ts | 65 +++++++++++++++---- 1 file changed, 52 insertions(+), 13 deletions(-) diff --git a/src/vs/editor/common/controller/coreCommands.ts b/src/vs/editor/common/controller/coreCommands.ts index b6372c58eb8..3794e7ace13 100644 --- a/src/vs/editor/common/controller/coreCommands.ts +++ b/src/vs/editor/common/controller/coreCommands.ts @@ -819,6 +819,18 @@ export namespace CoreNavigationCommands { } })); + export const CursorHomeSelect: CoreEditorCommand = registerEditorCommand(new HomeCommand({ + inSelectionMode: true, + id: 'cursorHomeSelect', + precondition: null, + kbOpts: { + weight: CORE_WEIGHT, + kbExpr: EditorContextKeys.textFocus, + primary: KeyMod.Shift | KeyCode.Home, + mac: { primary: KeyMod.Shift | KeyCode.Home, secondary: [KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.LeftArrow] } + } + })); + export const CursorLineStart: CoreEditorCommand = registerEditorCommand(new class extends CoreEditorCommand { constructor() { super({ @@ -857,18 +869,6 @@ export namespace CoreNavigationCommands { } }); - export const CursorHomeSelect: CoreEditorCommand = registerEditorCommand(new HomeCommand({ - inSelectionMode: true, - id: 'cursorHomeSelect', - precondition: null, - kbOpts: { - weight: CORE_WEIGHT, - kbExpr: EditorContextKeys.textFocus, - primary: KeyMod.Shift | KeyCode.Home, - mac: { primary: KeyMod.Shift | KeyCode.Home, secondary: [KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.LeftArrow] } - } - })); - class EndCommand extends CoreEditorCommand { private readonly _inSelectionMode: boolean; @@ -900,7 +900,7 @@ export namespace CoreNavigationCommands { weight: CORE_WEIGHT, kbExpr: EditorContextKeys.textFocus, primary: KeyCode.End, - mac: { primary: KeyCode.End, secondary: [KeyMod.CtrlCmd | KeyCode.RightArrow, KeyMod.WinCtrl | KeyCode.KEY_E] } + mac: { primary: KeyCode.End, secondary: [KeyMod.CtrlCmd | KeyCode.RightArrow] } } })); @@ -916,6 +916,45 @@ export namespace CoreNavigationCommands { } })); + export const CursorLineEnd: CoreEditorCommand = registerEditorCommand(new class extends CoreEditorCommand { + constructor() { + super({ + id: 'cursorLineEnd', + precondition: null, + kbOpts: { + weight: CORE_WEIGHT, + kbExpr: EditorContextKeys.textFocus, + primary: 0, + mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_E } + } + }); + } + + public runCoreEditorCommand(cursors: ICursors, args: any): void { + cursors.context.model.pushStackElement(); + cursors.setStates( + args.source, + CursorChangeReason.Explicit, + CursorState.ensureInEditableRange( + cursors.context, + this._exec(cursors.context, cursors.getAll()) + ) + ); + cursors.reveal(true, RevealTarget.Primary); + } + + private _exec(context: CursorContext, cursors: CursorState[]): CursorState[] { + let result: CursorState[] = []; + for (let i = 0, len = cursors.length; i < len; i++) { + const cursor = cursors[i]; + const lineNumber = cursor.modelState.position.lineNumber; + const maxColumn = context.model.getLineMaxColumn(lineNumber); + result[i] = CursorState.fromModelState(cursor.modelState.move(false, lineNumber, maxColumn, 0)); + } + return result; + } + }); + class TopCommand extends CoreEditorCommand { private readonly _inSelectionMode: boolean; -- GitLab From 3214dd602484c208fad3148c86d5d4fd7394b357 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Mon, 29 May 2017 17:05:08 +0200 Subject: [PATCH 0266/1347] [css] update services --- extensions/css/server/npm-shrinkwrap.json | 4 ++-- extensions/css/server/package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/extensions/css/server/npm-shrinkwrap.json b/extensions/css/server/npm-shrinkwrap.json index aebf5bf5121..13f55cd6b28 100644 --- a/extensions/css/server/npm-shrinkwrap.json +++ b/extensions/css/server/npm-shrinkwrap.json @@ -3,9 +3,9 @@ "version": "1.0.0", "dependencies": { "vscode-css-languageservice": { - "version": "2.0.3", + "version": "2.1.0", "from": "vscode-css-languageservice@next", - "resolved": "https://registry.npmjs.org/vscode-css-languageservice/-/vscode-css-languageservice-2.0.3.tgz" + "resolved": "https://registry.npmjs.org/vscode-css-languageservice/-/vscode-css-languageservice-2.1.0.tgz" }, "vscode-jsonrpc": { "version": "3.2.0", diff --git a/extensions/css/server/package.json b/extensions/css/server/package.json index 9e4322d03fe..ba141abd6cd 100644 --- a/extensions/css/server/package.json +++ b/extensions/css/server/package.json @@ -8,7 +8,7 @@ "node": "*" }, "dependencies": { - "vscode-css-languageservice": "^2.0.3", + "vscode-css-languageservice": "^2.1.0", "vscode-languageserver": "^3.2.0" }, "devDependencies": { -- GitLab From 41e7b3f9ac73f2a15195fd6679ecd2324a5e361f Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Mon, 29 May 2017 17:05:18 +0200 Subject: [PATCH 0267/1347] [html] update services --- extensions/html/server/npm-shrinkwrap.json | 15 +++++++++++---- extensions/html/server/package.json | 4 ++-- 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/extensions/html/server/npm-shrinkwrap.json b/extensions/html/server/npm-shrinkwrap.json index 82254c66b11..ee83f51e71e 100644 --- a/extensions/html/server/npm-shrinkwrap.json +++ b/extensions/html/server/npm-shrinkwrap.json @@ -3,14 +3,21 @@ "version": "1.0.0", "dependencies": { "vscode-css-languageservice": { - "version": "2.0.2", + "version": "2.1.0", "from": "vscode-css-languageservice@next", - "resolved": "https://registry.npmjs.org/vscode-css-languageservice/-/vscode-css-languageservice-2.0.2.tgz" + "resolved": "https://registry.npmjs.org/vscode-css-languageservice/-/vscode-css-languageservice-2.1.0.tgz", + "dependencies": { + "vscode-languageserver-types": { + "version": "3.2.0", + "from": "vscode-languageserver-types@>=3.2.0 <4.0.0", + "resolved": "https://registry.npmjs.org/vscode-languageserver-types/-/vscode-languageserver-types-3.2.0.tgz" + } + } }, "vscode-html-languageservice": { - "version": "2.0.4", + "version": "2.0.5", "from": "vscode-html-languageservice@next", - "resolved": "https://registry.npmjs.org/vscode-html-languageservice/-/vscode-html-languageservice-2.0.4.tgz" + "resolved": "https://registry.npmjs.org/vscode-html-languageservice/-/vscode-html-languageservice-2.0.5.tgz" }, "vscode-jsonrpc": { "version": "3.1.0-alpha.1", diff --git a/extensions/html/server/package.json b/extensions/html/server/package.json index a80e9b214ba..5284d547143 100644 --- a/extensions/html/server/package.json +++ b/extensions/html/server/package.json @@ -8,8 +8,8 @@ "node": "*" }, "dependencies": { - "vscode-css-languageservice": "^2.0.2", - "vscode-html-languageservice": "^2.0.4", + "vscode-css-languageservice": "^2.1.0", + "vscode-html-languageservice": "^2.0.5", "vscode-languageserver": "^3.1.0-alpha.1", "vscode-nls": "^2.0.2", "vscode-uri": "^1.0.0" -- GitLab From 64d9133505b6fa46df8f8292e1dbedb811a59e6b Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Mon, 29 May 2017 16:49:19 +0200 Subject: [PATCH 0268/1347] Dispose tree view listeners --- src/vs/workbench/parts/views/browser/treeView.ts | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/views/browser/treeView.ts b/src/vs/workbench/parts/views/browser/treeView.ts index c3f34825494..957f7a6f9b2 100644 --- a/src/vs/workbench/parts/views/browser/treeView.ts +++ b/src/vs/workbench/parts/views/browser/treeView.ts @@ -39,6 +39,7 @@ export class TreeView extends CollapsibleViewletView { private activated: boolean = false; private treeInputPromise: TPromise; + private dataProviderRegisteredListener: IDisposable; private dataProviderElementChangeListener: IDisposable; private disposables: IDisposable[] = []; @@ -136,11 +137,11 @@ export class TreeView extends CollapsibleViewletView { return this.treeInputPromise; } this.treeInputPromise = new TPromise((c, e) => { - const disposable = ViewsRegistry.onTreeViewDataProviderRegistered(id => { + this.dataProviderRegisteredListener = ViewsRegistry.onTreeViewDataProviderRegistered(id => { if (this.id === id) { if (this.listenToDataProvider()) { this.tree.setInput(new Root()).then(() => c(null)); - disposable.dispose(); + this.dataProviderRegisteredListener.dispose(); } } }); @@ -183,6 +184,13 @@ export class TreeView extends CollapsibleViewletView { } dispose(): void { + if (this.dataProviderRegisteredListener) { + this.dataProviderRegisteredListener.dispose(); + } + dispose(this.disposables); + if (this.dataProviderElementChangeListener) { + this.dataProviderElementChangeListener.dispose(); + } dispose(this.disposables); super.dispose(); } -- GitLab From 16255827d87054f34bf6674dbd3a54f9dfe35a01 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Mon, 29 May 2017 17:03:19 +0200 Subject: [PATCH 0269/1347] Explorer viewlet - Dispose listeners - Expand the view if it is only view - Check sash index before disposing --- src/vs/base/browser/ui/splitview/splitview.ts | 6 +- src/vs/workbench/browser/viewlet.ts | 2 + .../parts/files/browser/explorerViewlet.ts | 101 ++++++++++-------- 3 files changed, 61 insertions(+), 48 deletions(-) diff --git a/src/vs/base/browser/ui/splitview/splitview.ts b/src/vs/base/browser/ui/splitview/splitview.ts index 47ae7bc96eb..a328f784bdc 100644 --- a/src/vs/base/browser/ui/splitview/splitview.ts +++ b/src/vs/base/browser/ui/splitview/splitview.ts @@ -611,8 +611,10 @@ export class SplitView implements this.onViewChange(deadView, 0); let sashIndex = Math.max(index - 1, 0); - this.sashes[sashIndex].dispose(); - this.sashes.splice(sashIndex, 1); + if (sashIndex < this.sashes.length) { + this.sashes[sashIndex].dispose(); + this.sashes.splice(sashIndex, 1); + } this.viewChangeListeners[index].dispose(); this.viewChangeListeners.splice(index, 1); diff --git a/src/vs/workbench/browser/viewlet.ts b/src/vs/workbench/browser/viewlet.ts index 56c11d7b11a..0403d96aa35 100644 --- a/src/vs/workbench/browser/viewlet.ts +++ b/src/vs/workbench/browser/viewlet.ts @@ -301,6 +301,8 @@ export interface IViewletView extends IView, IThemable { shutdown(): void; focusBody(): void; isExpanded(): boolean; + expand(): void; + collapse(): void; } /** diff --git a/src/vs/workbench/parts/files/browser/explorerViewlet.ts b/src/vs/workbench/parts/files/browser/explorerViewlet.ts index f0def3cae94..9160ec7459b 100644 --- a/src/vs/workbench/parts/files/browser/explorerViewlet.ts +++ b/src/vs/workbench/parts/files/browser/explorerViewlet.ts @@ -6,7 +6,7 @@ 'use strict'; import 'vs/css!./media/explorerviewlet'; -import { IDisposable } from 'vs/base/common/lifecycle'; +import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { IAction, IActionRunner } from 'vs/base/common/actions'; import { TPromise } from 'vs/base/common/winjs.base'; import { Dimension, Builder } from 'vs/base/browser/builder'; @@ -61,6 +61,7 @@ export class ExplorerViewlet extends Viewlet { private dimension: Dimension; private viewletVisibleContextKey: IContextKey; + private disposables: IDisposable[] = []; constructor( @ITelemetryService telemetryService: ITelemetryService, @@ -71,7 +72,7 @@ export class ExplorerViewlet extends Viewlet { @IConfigurationService private configurationService: IConfigurationService, @IInstantiationService private instantiationService: IInstantiationService, @IContextKeyService contextKeyService: IContextKeyService, - @IThemeService themeService: IThemeService, + @IThemeService themeService: IThemeService ) { super(VIEWLET_ID, telemetryService, themeService); @@ -81,8 +82,9 @@ export class ExplorerViewlet extends Viewlet { this.viewletVisibleContextKey = ExplorerViewletVisibleContext.bindTo(contextKeyService); this.viewletSettings = this.getMemento(storageService, Scope.WORKSPACE); - this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated(e.config)); - ViewsRegistry.onViewsRegistered(viewDescriptors => this.addViews(viewDescriptors.filter(viewDescriptor => ViewLocation.Explorer === viewDescriptor.location))); + + this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated(e.config), this, this.disposables); + ViewsRegistry.onViewsRegistered(viewDescriptors => this.addCustomViews(viewDescriptors.filter(viewDescriptor => ViewLocation.Explorer === viewDescriptor.location), true), this, this.disposables); } public create(parent: Builder): TPromise { @@ -134,11 +136,7 @@ export class ExplorerViewlet extends Viewlet { // custom views for (const view of customViews) { - this.views.push(this.instantiationService.createInstance(view.ctor, view.id, { - name: view.name, - actionRunner: this.getActionRunner(), - collapsed: viewsState[view.id] ? (viewsState[view.id]).collapsed : true - })); + this.addCustomView(view, viewsState[view.id], -1); } for (let i = 0; i < this.views.length; i++) { @@ -150,16 +148,7 @@ export class ExplorerViewlet extends Viewlet { this.lastFocusedView = this.explorerView; return TPromise.join(this.views.map(view => view.create())).then(() => void 0).then(() => { - if (this.views.length === 1) { - this.views[0].hideHeader(); - - } - if (this.dimension) { - this.layout(this.dimension); - } - - // Update title area since the title actions have changed. - this.updateTitleArea(); + this.onViewsUpdated(); return this.setVisible(this.isVisible()).then(() => this.focus()); // Focus the viewlet since that triggers a rerender. }); } @@ -188,47 +177,61 @@ export class ExplorerViewlet extends Viewlet { this.splitView.removeView(this.openEditorsView); this.openEditorsView.dispose(); this.openEditorsView = null; - - if (this.views.length === 1) { - this.views[0].hideHeader(); - } - if (this.dimension) { - this.layout(this.dimension); - } - // Update title area since the title actions have changed. - this.updateTitleArea(); + this.onViewsUpdated(); } } - private addViews(viewDescriptors: IViewDescriptor[]): void { + private addCustomViews(viewDescriptors: IViewDescriptor[], end: boolean): void { if (!this.splitView || !viewDescriptors.length) { return; } const views = []; + const registered = ViewsRegistry.getViews(ViewLocation.Explorer); const viewsState = JSON.parse(this.storageService.get(ExplorerViewlet.EXPLORER_VIEWS_STATE, this.contextService.hasWorkspace() ? StorageScope.WORKSPACE : StorageScope.GLOBAL, '{}')); for (const viewDescriptor of viewDescriptors) { - const view = this.instantiationService.createInstance(viewDescriptor.ctor, viewDescriptor.id, { - name: viewDescriptor.name, - actionRunner: this.getActionRunner(), - collapsed: viewsState[viewDescriptor.id] ? (viewsState[viewDescriptor.id]).collapsed : true - }); + let index = end ? -1 : this.openEditorsView ? registered.indexOf(viewDescriptor) + 2 : registered.indexOf(viewDescriptor) + 1; + const view = this.addCustomView(viewDescriptor, viewsState[viewDescriptor.id], index); views.push(view); - this.views.push(view); attachHeaderViewStyler(view, this.themeService); - this.splitView.addView(view, viewsState[view.id] ? (viewsState[view.id]).size : void 0); + this.splitView.addView(view, viewsState[view.id] ? (viewsState[view.id]).size : void 0, end ? void 0 : index); } TPromise.join(views.map(view => view.create())).then(() => void 0).then(() => { - this.views[0].showHeader(); + this.onViewsUpdated(); + }); + } + + private addCustomView(viewDescriptor: IViewDescriptor, viewState: IViewState, index: number): IViewletView { + const view = this.instantiationService.createInstance(viewDescriptor.ctor, viewDescriptor.id, { + name: viewDescriptor.name, + actionRunner: this.getActionRunner(), + collapsed: viewState ? viewState.collapsed : true + }); + if (index !== -1) { + this.views.splice(index, 0, view); + } else { + this.views.push(view); + } + return view; + } - if (this.dimension) { - this.layout(this.dimension); + private onViewsUpdated(): void { + if (this.views.length > 1) { + this.views[0].showHeader(); + } else { + this.views[0].hideHeader(); + if (!this.views[0].isExpanded()) { + this.views[0].expand(); } + } - // Update title area since the title actions have changed. - this.updateTitleArea(); - }); + if (this.dimension) { + this.layout(this.dimension); + } + + // Update title area since the title actions have changed. + this.updateTitleArea(); } private onConfigurationUpdated(config: IFilesConfiguration): void { @@ -395,15 +398,17 @@ export class ExplorerViewlet extends Viewlet { } public shutdown(): void { + this.saveViewsState(); + this.views.forEach((view) => view.shutdown()); + super.shutdown(); + } + + private saveViewsState(): void { const viewletState = this.views.reduce((result, view) => { result[view.id] = this.getViewState(view); return result; }, {}); this.storageService.store(ExplorerViewlet.EXPLORER_VIEWS_STATE, JSON.stringify(viewletState), this.contextService.hasWorkspace() ? StorageScope.WORKSPACE : StorageScope.GLOBAL); - - this.views.forEach((view) => view.shutdown()); - - super.shutdown(); } private getViewState(view: IViewletView): IViewState { @@ -439,5 +444,9 @@ export class ExplorerViewlet extends Viewlet { this.focusListener.dispose(); this.focusListener = null; } + + this.disposables = dispose(this.disposables); + + super.dispose(); } } \ No newline at end of file -- GitLab From 5199dddb6fbaa0605b3ca2ef8504311d0c55757b Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Mon, 29 May 2017 17:14:31 +0200 Subject: [PATCH 0270/1347] Allowed more time for build task to prevent native dialog popup that blocks the test. Added missing comma in search test. --- test/smoke/src/areas/search.ts | 2 +- test/smoke/src/tests/tasks.ts | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/test/smoke/src/areas/search.ts b/test/smoke/src/areas/search.ts index 5477a5f25d9..8b74c8ffb9a 100644 --- a/test/smoke/src/areas/search.ts +++ b/test/smoke/src/areas/search.ts @@ -45,6 +45,6 @@ export class Search { } public dismissResult(): any { - return this.spectron.client.click('.action-label.icon.action-remove') + return this.spectron.client.click('.action-label.icon.action-remove'); } } \ No newline at end of file diff --git a/test/smoke/src/tests/tasks.ts b/test/smoke/src/tests/tasks.ts index bbe36ef3968..cdf58d6c124 100644 --- a/test/smoke/src/tests/tasks.ts +++ b/test/smoke/src/tests/tasks.ts @@ -32,6 +32,7 @@ export function testTasks() { it(`is able to select 'Git' output`, async function () { await tasks.build(); + await app.wait(); await tasks.selectOutputViewType('Git'); const viewType = await tasks.getOutputViewType(); assert.equal(viewType, 'Git'); -- GitLab From 43786fc1f763232fd81f5a2797fa55aacebd2809 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Mon, 29 May 2017 17:23:34 +0200 Subject: [PATCH 0271/1347] global settings - enable when running "out of dev" and show keybindings --- .../browser/parts/activitybar/activitybarActions.ts | 2 -- .../browser/parts/activitybar/activitybarPart.ts | 10 ++++++---- src/vs/workbench/electron-browser/window.ts | 3 +-- .../parts/files/browser/views/explorerViewer.ts | 7 ++----- .../parts/files/browser/views/openEditorsViewer.ts | 4 +--- .../parts/markers/browser/markersTreeController.ts | 11 +---------- .../parts/preferences/browser/keybindingsEditor.ts | 3 +-- .../parts/terminal/electron-browser/terminalPanel.ts | 5 +---- .../update/electron-browser/update.contribution.ts | 2 +- .../workbench/parts/update/electron-browser/update.ts | 10 +++++++--- src/vs/workbench/parts/views/browser/treeView.ts | 11 +---------- .../electron-browser/contextmenuService.ts | 2 +- 12 files changed, 23 insertions(+), 47 deletions(-) diff --git a/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts b/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts index cc95a89bdd0..287ad54470d 100644 --- a/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts +++ b/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts @@ -504,7 +504,6 @@ export class ViewletOverflowActivityActionItem extends ActivityActionItem { private getBadge: (viewlet: ViewletDescriptor) => IBadge, @IInstantiationService private instantiationService: IInstantiationService, @IViewletService private viewletService: IViewletService, - @IKeybindingService private keybindingService: IKeybindingService, @IContextMenuService private contextMenuService: IContextMenuService, @IThemeService themeService: IThemeService ) { @@ -548,7 +547,6 @@ export class ViewletOverflowActivityActionItem extends ActivityActionItem { this.contextMenuService.showContextMenu({ getAnchor: () => this.builder.getHTMLElement(), getActions: () => TPromise.as(this.actions), - getKeyBinding: (action) => this.keybindingService.lookupKeybinding(action.id), onHide: () => dispose(this.actions) }); } diff --git a/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts b/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts index 4085747c900..4e773ecab38 100644 --- a/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts +++ b/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts @@ -83,12 +83,13 @@ export class ActivitybarPart extends Part implements IActivityBarService { private dimension: Dimension; + private globalActionBar: ActionBar; + private globalActivityIdToActions: { [globalActivityId: string]: GlobalActivityAction; }; + private viewletSwitcherBar: ActionBar; - private activityActionBar: ActionBar; private viewletOverflowAction: ViewletOverflowActivityAction; private viewletOverflowActionItem: ViewletOverflowActivityActionItem; - private globalActivityIdToActions: { [globalActivityId: string]: GlobalActivityAction; }; private viewletIdToActions: { [viewletId: string]: ActivityAction; }; private viewletIdToActionItems: { [viewletId: string]: IActionItem; }; private viewletIdToActivityStack: { [viewletId: string]: IViewletActivity[]; }; @@ -110,6 +111,7 @@ export class ActivitybarPart extends Part implements IActivityBarService { super(id, { hasTitle: false }, themeService); this.globalActivityIdToActions = Object.create(null); + this.viewletIdToActionItems = Object.create(null); this.viewletIdToActions = Object.create(null); this.viewletIdToActivityStack = Object.create(null); @@ -316,7 +318,7 @@ export class ActivitybarPart extends Part implements IActivityBarService { .map(d => this.instantiationService.createInstance(d)) .map(a => new GlobalActivityAction(a)); - this.activityActionBar = new ActionBar(container, { + this.globalActionBar = new ActionBar(container, { actionItemProvider: a => this.instantiationService.createInstance(GlobalActivityActionItem, a), orientation: ActionsOrientation.VERTICAL, ariaLabel: nls.localize('globalActions', "Global Actions"), @@ -325,7 +327,7 @@ export class ActivitybarPart extends Part implements IActivityBarService { actions.forEach(a => { this.globalActivityIdToActions[a.id] = a; - this.activityActionBar.push(a); + this.globalActionBar.push(a); }); } diff --git a/src/vs/workbench/electron-browser/window.ts b/src/vs/workbench/electron-browser/window.ts index be59101349e..e0eb6f23dfe 100644 --- a/src/vs/workbench/electron-browser/window.ts +++ b/src/vs/workbench/electron-browser/window.ts @@ -338,8 +338,7 @@ export class ElectronWindow extends Themable { this.contextMenuService.showContextMenu({ getAnchor: () => target, - getActions: () => TPromise.as(TextInputActions), - getKeyBinding: action => this.keybindingService.lookupKeybinding(action.id) + getActions: () => TPromise.as(TextInputActions) }); } } diff --git a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts index 4494835dff8..ec485a2d391 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts @@ -33,7 +33,6 @@ import { DesktopDragAndDropData, ExternalElementsDragAndDropData } from 'vs/base import { ClickBehavior, DefaultController } from 'vs/base/parts/tree/browser/treeDefaults'; import { FileStat, NewStatPlaceholder } from 'vs/workbench/parts/files/common/explorerViewModel'; import { DragMouseEvent, IMouseEvent } from 'vs/base/browser/mouseEvent'; -import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; import { IPartService } from 'vs/workbench/services/part/common/partService'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; @@ -44,7 +43,7 @@ import { IInstantiationService } from 'vs/platform/instantiation/common/instanti import { IMessageService, IConfirmation, Severity } from 'vs/platform/message/common/message'; import { IProgressService } from 'vs/platform/progress/common/progress'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; -import { ResolvedKeybinding, KeyCode } from 'vs/base/common/keyCodes'; +import { KeyCode } from 'vs/base/common/keyCodes'; import { IKeyboardEvent } from 'vs/base/browser/keyboardEvent'; import { IMenuService, IMenu, MenuId } from 'vs/platform/actions/common/actions'; import { fillInActions } from 'vs/platform/actions/browser/menuItemActionItem'; @@ -396,8 +395,7 @@ export class FileController extends DefaultController { @ITelemetryService private telemetryService: ITelemetryService, @IWorkspaceContextService private contextService: IWorkspaceContextService, @IMenuService menuService: IMenuService, - @IContextKeyService contextKeyService: IContextKeyService, - @IKeybindingService private keybindingService: IKeybindingService + @IContextKeyService contextKeyService: IContextKeyService ) { super({ clickBehavior: ClickBehavior.ON_MOUSE_UP /* do not change to not break DND */, keyboardSupport: false /* handled via IListService */ }); @@ -495,7 +493,6 @@ export class FileController extends DefaultController { }); }, getActionItem: this.state.actionProvider.getActionItem.bind(this.state.actionProvider, tree, stat), - getKeyBinding: (a): ResolvedKeybinding => this.keybindingService.lookupKeybinding(a.id), getActionsContext: (event) => { return { viewletState: this.state, diff --git a/src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts b/src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts index e662f47ce91..0985b01da56 100644 --- a/src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts +++ b/src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts @@ -170,8 +170,7 @@ export class Controller extends DefaultController { @IWorkbenchEditorService private editorService: IWorkbenchEditorService, @IEditorGroupService private editorGroupService: IEditorGroupService, @IContextMenuService private contextMenuService: IContextMenuService, - @ITelemetryService private telemetryService: ITelemetryService, - @IKeybindingService private keybindingService: IKeybindingService + @ITelemetryService private telemetryService: ITelemetryService ) { super({ clickBehavior: ClickBehavior.ON_MOUSE_DOWN, keyboardSupport: false }); } @@ -261,7 +260,6 @@ export class Controller extends DefaultController { this.contextMenuService.showContextMenu({ getAnchor: () => anchor, getActions: () => this.actionProvider.getSecondaryActions(tree, element), - getKeyBinding: (action) => this.keybindingService.lookupKeybinding(action.id), onHide: (wasCancelled?: boolean) => { if (wasCancelled) { tree.DOMFocus(); diff --git a/src/vs/workbench/parts/markers/browser/markersTreeController.ts b/src/vs/workbench/parts/markers/browser/markersTreeController.ts index 0177d325920..9b420131e3c 100644 --- a/src/vs/workbench/parts/markers/browser/markersTreeController.ts +++ b/src/vs/workbench/parts/markers/browser/markersTreeController.ts @@ -13,7 +13,6 @@ import { IContextMenuService } from 'vs/platform/contextview/browser/contextView import { IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; import { IMenuService, IMenu, MenuId } from 'vs/platform/actions/common/actions'; import { IAction } from 'vs/base/common/actions'; -import { ResolvedKeybinding } from 'vs/base/common/keyCodes'; import { ActionItem, Separator } from 'vs/base/browser/ui/actionbar/actionbar'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; @@ -61,17 +60,13 @@ export class Controller extends treedefaults.DefaultController { }, getActionItem: (action) => { - const keybinding = this._keybindingFor(action); + const keybinding = this._keybindingService.lookupKeybinding(action.id); if (keybinding) { return new ActionItem(action, action, { label: true, keybinding: keybinding.getLabel() }); } return null; }, - getKeyBinding: (action): ResolvedKeybinding => { - return this._keybindingFor(action); - }, - onHide: (wasCancelled?: boolean) => { if (wasCancelled) { tree.DOMFocus(); @@ -94,8 +89,4 @@ export class Controller extends treedefaults.DefaultController { result.pop(); // remove last separator return result; } - - private _keybindingFor(action: IAction): ResolvedKeybinding { - return this._keybindingService.lookupKeybinding(action.id); - } } diff --git a/src/vs/workbench/parts/preferences/browser/keybindingsEditor.ts b/src/vs/workbench/parts/preferences/browser/keybindingsEditor.ts index 16fedab3623..f0aa2694035 100644 --- a/src/vs/workbench/parts/preferences/browser/keybindingsEditor.ts +++ b/src/vs/workbench/parts/preferences/browser/keybindingsEditor.ts @@ -444,8 +444,7 @@ export class KeybindingsEditor extends BaseEditor implements IKeybindingsEditor this.createRemoveAction(e.element), this.createResetAction(e.element), new Separator(), - this.createShowConflictsAction(e.element)]), - getKeyBinding: (action) => this.keybindingsService.lookupKeybinding(action.id) + this.createShowConflictsAction(e.element)]) }); } } diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts index 4b5a29f34c4..78364b99abf 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts @@ -12,7 +12,6 @@ import { IActionItem, Separator } from 'vs/base/browser/ui/actionbar/actionbar'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { IContextMenuService } from 'vs/platform/contextview/browser/contextView'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; -import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { ITerminalService, ITerminalFont, TERMINAL_PANEL_ID } from 'vs/workbench/parts/terminal/common/terminal'; import { IThemeService, ITheme } from 'vs/platform/theme/common/themeService'; @@ -40,7 +39,6 @@ export class TerminalPanel extends Panel { @IConfigurationService private _configurationService: IConfigurationService, @IContextMenuService private _contextMenuService: IContextMenuService, @IInstantiationService private _instantiationService: IInstantiationService, - @IKeybindingService private _keybindingService: IKeybindingService, @ITerminalService private _terminalService: ITerminalService, @IThemeService protected themeService: IThemeService, @ITelemetryService telemetryService: ITelemetryService @@ -190,8 +188,7 @@ export class TerminalPanel extends Panel { this._contextMenuService.showContextMenu({ getAnchor: () => anchor, getActions: () => TPromise.as(this._getContextMenuActions()), - getActionsContext: () => this._parentDomElement, - getKeyBinding: (action) => this._keybindingService.lookupKeybinding(action.id) + getActionsContext: () => this._parentDomElement }); } this._cancelContextMenu = false; diff --git a/src/vs/workbench/parts/update/electron-browser/update.contribution.ts b/src/vs/workbench/parts/update/electron-browser/update.contribution.ts index 26cc50dfe8e..64bba795487 100644 --- a/src/vs/workbench/parts/update/electron-browser/update.contribution.ts +++ b/src/vs/workbench/parts/update/electron-browser/update.contribution.ts @@ -24,7 +24,7 @@ import { ShowCurrentReleaseNotesAction, ProductContribution, UpdateContribution, Registry.as(WorkbenchExtensions.Workbench) .registerWorkbenchContribution(ProductContribution); -if (product.quality === 'insider') { +if (product.quality !== 'stable') { Registry.as(GlobalActivityExtensions) .registerActivity(LightUpdateContribution); } else { diff --git a/src/vs/workbench/parts/update/electron-browser/update.ts b/src/vs/workbench/parts/update/electron-browser/update.ts index 4b8eff773df..c68899b0830 100644 --- a/src/vs/workbench/parts/update/electron-browser/update.ts +++ b/src/vs/workbench/parts/update/electron-browser/update.ts @@ -279,6 +279,10 @@ export class UpdateContribution implements IWorkbenchContribution { export class LightUpdateContribution implements IGlobalActivity { + private static readonly showCommandsId = 'workbench.action.showCommands'; + private static readonly openSettingsId = 'workbench.action.openGlobalSettings'; + private static readonly openKeybindingsId = 'workbench.action.openGlobalKeybindings'; + get id() { return 'vs.update'; } get name() { return ''; } get cssClass() { return 'update-activity'; } @@ -302,10 +306,10 @@ export class LightUpdateContribution implements IGlobalActivity { getActions(): IAction[] { return [ - new Action('showCommandPalette', nls.localize('commandPalette', "Command Palette..."), undefined, true, () => this.commandService.executeCommand('workbench.action.showCommands')), + new Action(LightUpdateContribution.showCommandsId, nls.localize('commandPalette', "Command Palette..."), undefined, true, () => this.commandService.executeCommand(LightUpdateContribution.showCommandsId)), new Separator(), - new Action('openKeybindings', nls.localize('settings', "Settings"), null, true, () => this.commandService.executeCommand('workbench.action.openGlobalSettings')), - new Action('openSettings', nls.localize('keyboardShortcuts', "Keyboard Shortcuts"), null, true, () => this.commandService.executeCommand('workbench.action.openGlobalKeybindings')), + new Action(LightUpdateContribution.openSettingsId, nls.localize('settings', "Settings"), null, true, () => this.commandService.executeCommand(LightUpdateContribution.openSettingsId)), + new Action(LightUpdateContribution.openKeybindingsId, nls.localize('keyboardShortcuts', "Keyboard Shortcuts"), null, true, () => this.commandService.executeCommand(LightUpdateContribution.openKeybindingsId)), new Separator(), this.getUpdateAction() ]; diff --git a/src/vs/workbench/parts/views/browser/treeView.ts b/src/vs/workbench/parts/views/browser/treeView.ts index 957f7a6f9b2..cc6c4c38b4e 100644 --- a/src/vs/workbench/parts/views/browser/treeView.ts +++ b/src/vs/workbench/parts/views/browser/treeView.ts @@ -25,7 +25,6 @@ import { createActionItem, fillInActions } from 'vs/platform/actions/browser/men import { IProgressService } from 'vs/platform/progress/common/progress'; import { ITree, IDataSource, IRenderer, ContextMenuEvent } from 'vs/base/parts/tree/browser/tree'; import { IContextKeyService, IContextKey } from 'vs/platform/contextkey/common/contextkey'; -import { ResolvedKeybinding } from 'vs/base/common/keyCodes'; import { ActionItem } from 'vs/base/browser/ui/actionbar/actionbar'; import { ViewsRegistry, ITreeViewDataProvider, IViewOptions, ITreeItem, TreeItemCollapsibleState } from 'vs/workbench/parts/views/browser/views'; import { IExtensionService } from 'vs/platform/extensions/common/extensions'; @@ -326,17 +325,13 @@ class TreeController extends DefaultController { }, getActionItem: (action) => { - const keybinding = this._keybindingFor(action); + const keybinding = this._keybindingService.lookupKeybinding(action.id); if (keybinding) { return new ActionItem(action, action, { label: true, keybinding: keybinding.getLabel() }); } return null; }, - getKeyBinding: (action): ResolvedKeybinding => { - return this._keybindingFor(action); - }, - onHide: (wasCancelled?: boolean) => { if (wasCancelled) { tree.DOMFocus(); @@ -350,10 +345,6 @@ class TreeController extends DefaultController { return true; } - - private _keybindingFor(action: IAction): ResolvedKeybinding { - return this._keybindingService.lookupKeybinding(action.id); - } } class MultipleSelectionActionRunner extends ActionRunner { diff --git a/src/vs/workbench/services/contextview/electron-browser/contextmenuService.ts b/src/vs/workbench/services/contextview/electron-browser/contextmenuService.ts index 0815aae6e33..50e56ffac45 100644 --- a/src/vs/workbench/services/contextview/electron-browser/contextmenuService.ts +++ b/src/vs/workbench/services/contextview/electron-browser/contextmenuService.ts @@ -87,7 +87,7 @@ export class ContextMenuService implements IContextMenuService { } }; - const keybinding = !!delegate.getKeyBinding ? delegate.getKeyBinding(e) : undefined; + const keybinding = !!delegate.getKeyBinding ? delegate.getKeyBinding(e) : this.keybindingService.lookupKeybinding(e.id); if (keybinding) { const electronAccelerator = keybinding.getElectronAccelerator(); if (electronAccelerator) { -- GitLab From a336df99e34f266920f5f4cc677fde810f6b5003 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Mon, 29 May 2017 17:24:43 +0200 Subject: [PATCH 0272/1347] Shutdown glob pattern searching process after 1s of idle time --- src/vs/workbench/node/extensionHostMain.ts | 3 ++- src/vs/workbench/services/search/node/searchService.ts | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/vs/workbench/node/extensionHostMain.ts b/src/vs/workbench/node/extensionHostMain.ts index ae3bd6cb18b..fd41b0c29fe 100644 --- a/src/vs/workbench/node/extensionHostMain.ts +++ b/src/vs/workbench/node/extensionHostMain.ts @@ -130,7 +130,8 @@ export class ExtensionHostMain { // `workspaceGlob` or something along those lines? if (p.indexOf('*') > -1 || p.indexOf('?') > -1) { if (!this._diskSearch) { - this._diskSearch = new DiskSearch(false); + // Shut down this search process after 1s + this._diskSearch = new DiskSearch(false, 1000); } const query: ISearchQuery = { diff --git a/src/vs/workbench/services/search/node/searchService.ts b/src/vs/workbench/services/search/node/searchService.ts index b1317d6b7cc..1c2d62c29d1 100644 --- a/src/vs/workbench/services/search/node/searchService.ts +++ b/src/vs/workbench/services/search/node/searchService.ts @@ -200,12 +200,12 @@ export class DiskSearch { private raw: IRawSearchService; - constructor(verboseLogging: boolean) { + constructor(verboseLogging: boolean, timeout: number = 60 * 60 * 1000) { const client = new Client( uri.parse(require.toUrl('bootstrap')).fsPath, { serverName: 'Search', - timeout: 60 * 60 * 1000, + timeout: timeout, args: ['--type=searchService'], env: { AMD_ENTRYPOINT: 'vs/workbench/services/search/node/searchApp', -- GitLab From 1fc69c89e7a31f0c6fcdf58c2c4a36c9b391fee4 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Mon, 29 May 2017 17:54:39 +0200 Subject: [PATCH 0273/1347] actionBarRegistry.ts => actions.ts --- src/vs/workbench/browser/{actionBarRegistry.ts => actions.ts} | 0 src/vs/workbench/browser/parts/compositePart.ts | 2 +- src/vs/workbench/browser/parts/editor/editor.contribution.ts | 2 +- src/vs/workbench/browser/parts/editor/titleControl.ts | 2 +- src/vs/workbench/browser/parts/panel/panelPart.ts | 2 +- src/vs/workbench/browser/parts/quickopen/quickOpenController.ts | 2 +- src/vs/workbench/browser/parts/sidebar/sidebarPart.ts | 2 +- src/vs/workbench/browser/viewlet.ts | 2 +- src/vs/workbench/electron-browser/workbench.ts | 2 +- src/vs/workbench/parts/debug/electron-browser/debugViews.ts | 2 +- .../parts/execution/electron-browser/terminal.contribution.ts | 2 +- .../workbench/parts/files/browser/fileActions.contribution.ts | 2 +- src/vs/workbench/parts/files/browser/views/explorerView.ts | 2 +- src/vs/workbench/parts/files/browser/views/explorerViewer.ts | 2 +- src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts | 2 +- src/vs/workbench/parts/markers/browser/markersPanel.ts | 2 +- src/vs/workbench/parts/search/browser/search.contribution.ts | 2 +- src/vs/workbench/parts/tasks/browser/quickOpen.ts | 2 +- .../workbench/parts/tasks/electron-browser/task.contribution.ts | 2 +- src/vs/workbench/test/browser/actionRegistry.test.ts | 2 +- 20 files changed, 19 insertions(+), 19 deletions(-) rename src/vs/workbench/browser/{actionBarRegistry.ts => actions.ts} (100%) diff --git a/src/vs/workbench/browser/actionBarRegistry.ts b/src/vs/workbench/browser/actions.ts similarity index 100% rename from src/vs/workbench/browser/actionBarRegistry.ts rename to src/vs/workbench/browser/actions.ts diff --git a/src/vs/workbench/browser/parts/compositePart.ts b/src/vs/workbench/browser/parts/compositePart.ts index 5c23e84ef0f..dea7bce19b3 100644 --- a/src/vs/workbench/browser/parts/compositePart.ts +++ b/src/vs/workbench/browser/parts/compositePart.ts @@ -20,7 +20,7 @@ import errors = require('vs/base/common/errors'); import { CONTEXT as ToolBarContext, ToolBar } from 'vs/base/browser/ui/toolbar/toolbar'; import { IActionItem, ActionsOrientation } from 'vs/base/browser/ui/actionbar/actionbar'; import { ProgressBar } from 'vs/base/browser/ui/progressbar/progressbar'; -import { IActionBarRegistry, Extensions, prepareActions } from 'vs/workbench/browser/actionBarRegistry'; +import { IActionBarRegistry, Extensions, prepareActions } from 'vs/workbench/browser/actions'; import { Action, IAction } from 'vs/base/common/actions'; import { Part, IPartOptions } from 'vs/workbench/browser/part'; import { Composite, CompositeRegistry } from 'vs/workbench/browser/composite'; diff --git a/src/vs/workbench/browser/parts/editor/editor.contribution.ts b/src/vs/workbench/browser/parts/editor/editor.contribution.ts index e8a5d028fd3..7e8aa1bae2b 100644 --- a/src/vs/workbench/browser/parts/editor/editor.contribution.ts +++ b/src/vs/workbench/browser/parts/editor/editor.contribution.ts @@ -23,7 +23,7 @@ import { ITextFileService } from 'vs/workbench/services/textfile/common/textfile import { BinaryResourceDiffEditor } from 'vs/workbench/browser/parts/editor/binaryDiffEditor'; import { ChangeEncodingAction, ChangeEOLAction, ChangeModeAction, EditorStatus } from 'vs/workbench/browser/parts/editor/editorStatus'; import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/workbench/common/actionRegistry'; -import { Scope, IActionBarRegistry, Extensions as ActionBarExtensions, ActionBarContributor } from 'vs/workbench/browser/actionBarRegistry'; +import { Scope, IActionBarRegistry, Extensions as ActionBarExtensions, ActionBarContributor } from 'vs/workbench/browser/actions'; import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; import { SyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import { KeyMod, KeyChord, KeyCode } from 'vs/base/common/keyCodes'; diff --git a/src/vs/workbench/browser/parts/editor/titleControl.ts b/src/vs/workbench/browser/parts/editor/titleControl.ts index acb5d5e3e26..12c13c861ed 100644 --- a/src/vs/workbench/browser/parts/editor/titleControl.ts +++ b/src/vs/workbench/browser/parts/editor/titleControl.ts @@ -8,7 +8,7 @@ import 'vs/css!./media/titlecontrol'; import nls = require('vs/nls'); import { Registry } from 'vs/platform/platform'; -import { Scope, IActionBarRegistry, Extensions, prepareActions } from 'vs/workbench/browser/actionBarRegistry'; +import { Scope, IActionBarRegistry, Extensions, prepareActions } from 'vs/workbench/browser/actions'; import { IAction, Action } from 'vs/base/common/actions'; import errors = require('vs/base/common/errors'); import DOM = require('vs/base/browser/dom'); diff --git a/src/vs/workbench/browser/parts/panel/panelPart.ts b/src/vs/workbench/browser/parts/panel/panelPart.ts index 33c4fabe884..8f535d23acf 100644 --- a/src/vs/workbench/browser/parts/panel/panelPart.ts +++ b/src/vs/workbench/browser/parts/panel/panelPart.ts @@ -10,7 +10,7 @@ import { IAction } from 'vs/base/common/actions'; import Event from 'vs/base/common/event'; import { Builder, $ } from 'vs/base/browser/builder'; import { Registry } from 'vs/platform/platform'; -import { Scope } from 'vs/workbench/browser/actionBarRegistry'; +import { Scope } from 'vs/workbench/browser/actions'; import { IPanel } from 'vs/workbench/common/panel'; import { CompositePart, ICompositeTitleLabel } from 'vs/workbench/browser/parts/compositePart'; import { Panel, PanelRegistry, Extensions as PanelExtensions } from 'vs/workbench/browser/panel'; diff --git a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts index 70ab1330732..32ef0a9c37a 100644 --- a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts +++ b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts @@ -22,7 +22,7 @@ import { CancellationToken } from 'vs/base/common/cancellation'; import { Mode, IEntryRunContext, IAutoFocus, IQuickNavigateConfiguration, IModel } from 'vs/base/parts/quickopen/common/quickOpen'; import { QuickOpenEntry, QuickOpenModel, QuickOpenEntryGroup } from 'vs/base/parts/quickopen/browser/quickOpenModel'; import { QuickOpenWidget, HideReason } from 'vs/base/parts/quickopen/browser/quickOpenWidget'; -import { ContributableActionProvider } from 'vs/workbench/browser/actionBarRegistry'; +import { ContributableActionProvider } from 'vs/workbench/browser/actions'; import labels = require('vs/base/common/labels'); import paths = require('vs/base/common/paths'); import { ITextFileService, AutoSaveMode } from 'vs/workbench/services/textfile/common/textfiles'; diff --git a/src/vs/workbench/browser/parts/sidebar/sidebarPart.ts b/src/vs/workbench/browser/parts/sidebar/sidebarPart.ts index fa5d1156e36..36f23b53283 100644 --- a/src/vs/workbench/browser/parts/sidebar/sidebarPart.ts +++ b/src/vs/workbench/browser/parts/sidebar/sidebarPart.ts @@ -15,7 +15,7 @@ import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; import { IViewletService } from 'vs/workbench/services/viewlet/browser/viewlet'; import { IPartService, Parts, Position as SideBarPosition } from 'vs/workbench/services/part/common/partService'; import { IViewlet } from 'vs/workbench/common/viewlet'; -import { Scope } from 'vs/workbench/browser/actionBarRegistry'; +import { Scope } from 'vs/workbench/browser/actions'; import { IStorageService } from 'vs/platform/storage/common/storage'; import { IContextMenuService } from 'vs/platform/contextview/browser/contextView'; import { IMessageService } from 'vs/platform/message/common/message'; diff --git a/src/vs/workbench/browser/viewlet.ts b/src/vs/workbench/browser/viewlet.ts index 0403d96aa35..5f153eee59c 100644 --- a/src/vs/workbench/browser/viewlet.ts +++ b/src/vs/workbench/browser/viewlet.ts @@ -12,7 +12,7 @@ import { Dimension, Builder, $ } from 'vs/base/browser/builder'; import { IAction, IActionRunner, Action } from 'vs/base/common/actions'; import { IActionItem, ActionsOrientation } from 'vs/base/browser/ui/actionbar/actionbar'; import { ITree, IFocusEvent, ISelectionEvent } from 'vs/base/parts/tree/browser/tree'; -import { prepareActions } from 'vs/workbench/browser/actionBarRegistry'; +import { prepareActions } from 'vs/workbench/browser/actions'; import { ToolBar } from 'vs/base/browser/ui/toolbar/toolbar'; import { DelayedDragHandler } from 'vs/base/browser/dnd'; import { dispose, IDisposable } from 'vs/base/common/lifecycle'; diff --git a/src/vs/workbench/electron-browser/workbench.ts b/src/vs/workbench/electron-browser/workbench.ts index 5a2a8efaff7..b8c52c3c984 100644 --- a/src/vs/workbench/electron-browser/workbench.ts +++ b/src/vs/workbench/electron-browser/workbench.ts @@ -36,7 +36,7 @@ import { PanelPart } from 'vs/workbench/browser/parts/panel/panelPart'; import { StatusbarPart } from 'vs/workbench/browser/parts/statusbar/statusbarPart'; import { TitlebarPart } from 'vs/workbench/browser/parts/titlebar/titlebarPart'; import { WorkbenchLayout } from 'vs/workbench/browser/layout'; -import { IActionBarRegistry, Extensions as ActionBarExtensions } from 'vs/workbench/browser/actionBarRegistry'; +import { IActionBarRegistry, Extensions as ActionBarExtensions } from 'vs/workbench/browser/actions'; import { PanelRegistry, Extensions as PanelExtensions } from 'vs/workbench/browser/panel'; import { QuickOpenController } from 'vs/workbench/browser/parts/quickopen/quickOpenController'; import { getServices } from 'vs/platform/instantiation/common/extensions'; diff --git a/src/vs/workbench/parts/debug/electron-browser/debugViews.ts b/src/vs/workbench/parts/debug/electron-browser/debugViews.ts index 3d4d2f1838b..f70b82840e5 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugViews.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugViews.ts @@ -12,7 +12,7 @@ import { TPromise } from 'vs/base/common/winjs.base'; import * as errors from 'vs/base/common/errors'; import { EventType } from 'vs/base/common/events'; import { IActionRunner, IAction } from 'vs/base/common/actions'; -import { prepareActions } from 'vs/workbench/browser/actionBarRegistry'; +import { prepareActions } from 'vs/workbench/browser/actions'; import { IHighlightEvent, ITree } from 'vs/base/parts/tree/browser/tree'; import { Tree } from 'vs/base/parts/tree/browser/treeImpl'; import { CollapsibleState } from 'vs/base/browser/ui/splitview/splitview'; diff --git a/src/vs/workbench/parts/execution/electron-browser/terminal.contribution.ts b/src/vs/workbench/parts/execution/electron-browser/terminal.contribution.ts index c7b09a28e16..d191c415426 100644 --- a/src/vs/workbench/parts/execution/electron-browser/terminal.contribution.ts +++ b/src/vs/workbench/parts/execution/electron-browser/terminal.contribution.ts @@ -11,7 +11,7 @@ import baseplatform = require('vs/base/common/platform'); import { IAction, Action } from 'vs/base/common/actions'; import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/workbench/common/actionRegistry'; import paths = require('vs/base/common/paths'); -import { Scope, IActionBarRegistry, Extensions as ActionBarExtensions, ActionBarContributor } from 'vs/workbench/browser/actionBarRegistry'; +import { Scope, IActionBarRegistry, Extensions as ActionBarExtensions, ActionBarContributor } from 'vs/workbench/browser/actions'; import uri from 'vs/base/common/uri'; import { explorerItemToFileResource } from 'vs/workbench/parts/files/common/files'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; diff --git a/src/vs/workbench/parts/files/browser/fileActions.contribution.ts b/src/vs/workbench/parts/files/browser/fileActions.contribution.ts index 7c3bd0125d2..6f04409b592 100644 --- a/src/vs/workbench/parts/files/browser/fileActions.contribution.ts +++ b/src/vs/workbench/parts/files/browser/fileActions.contribution.ts @@ -9,7 +9,7 @@ import { Registry } from 'vs/platform/platform'; import { Action, IAction } from 'vs/base/common/actions'; import { isMacintosh } from 'vs/base/common/platform'; import { ActionItem, BaseActionItem, Separator } from 'vs/base/browser/ui/actionbar/actionbar'; -import { Scope, IActionBarRegistry, Extensions as ActionBarExtensions, ActionBarContributor } from 'vs/workbench/browser/actionBarRegistry'; +import { Scope, IActionBarRegistry, Extensions as ActionBarExtensions, ActionBarContributor } from 'vs/workbench/browser/actions'; import { GlobalNewUntitledFileAction, SaveFileAsAction, OpenFileAction, ShowOpenedFileInNewWindow, CopyPathAction, GlobalCopyPathAction, RevealInOSAction, GlobalRevealInOSAction, pasteIntoFocusedFilesExplorerViewItem, FocusOpenEditorsView, FocusFilesExplorer, GlobalCompareResourcesAction, GlobalNewFileAction, GlobalNewFolderAction, RevertFileAction, SaveFilesAction, SaveAllAction, SaveFileAction, MoveFileToTrashAction, TriggerRenameFileAction, PasteFileAction, CopyFileAction, SelectResourceForCompareAction, CompareResourcesAction, NewFolderAction, NewFileAction, OpenToSideAction, ShowActiveFileInExplorer, CollapseExplorerView, RefreshExplorerView } from 'vs/workbench/parts/files/browser/fileActions'; import { revertLocalChangesCommand, acceptLocalChangesCommand, CONFLICT_RESOLUTION_CONTEXT } from 'vs/workbench/parts/files/browser/saveErrorHandler'; import { SyncActionDescriptor, MenuId, MenuRegistry } from 'vs/platform/actions/common/actions'; diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index 5895751dd8b..cad31f52e9f 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -13,7 +13,7 @@ import errors = require('vs/base/common/errors'); import labels = require('vs/base/common/labels'); import paths = require('vs/base/common/paths'); import { Action, IAction } from 'vs/base/common/actions'; -import { prepareActions } from 'vs/workbench/browser/actionBarRegistry'; +import { prepareActions } from 'vs/workbench/browser/actions'; import { ITree } from 'vs/base/parts/tree/browser/tree'; import { Tree } from 'vs/base/parts/tree/browser/treeImpl'; import { IFilesConfiguration, ExplorerFolderContext, FilesExplorerFocussedContext, ExplorerFocussedContext } from 'vs/workbench/parts/files/common/files'; diff --git a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts index ec485a2d391..95f1dc2599c 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts @@ -22,7 +22,7 @@ import { isMacintosh, isLinux } from 'vs/base/common/platform'; import glob = require('vs/base/common/glob'); import { FileLabel, IFileLabelOptions } from 'vs/workbench/browser/labels'; import { IDisposable } from 'vs/base/common/lifecycle'; -import { ContributableActionProvider } from 'vs/workbench/browser/actionBarRegistry'; +import { ContributableActionProvider } from 'vs/workbench/browser/actions'; import { IFilesConfiguration } from 'vs/workbench/parts/files/common/files'; import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; import { IFileOperationResult, FileOperationResult, IFileService, isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; diff --git a/src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts b/src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts index 0985b01da56..f275bfd30a5 100644 --- a/src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts +++ b/src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts @@ -23,7 +23,7 @@ import { IContextMenuService } from 'vs/platform/contextview/browser/contextView import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { IEditorGroup, IEditorStacksModel } from 'vs/workbench/common/editor'; import { OpenEditor } from 'vs/workbench/parts/files/common/explorerViewModel'; -import { ContributableActionProvider } from 'vs/workbench/browser/actionBarRegistry'; +import { ContributableActionProvider } from 'vs/workbench/browser/actions'; import { explorerItemToFileResource } from 'vs/workbench/parts/files/common/files'; import { ITextFileService, AutoSaveMode } from 'vs/workbench/services/textfile/common/textfiles'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; diff --git a/src/vs/workbench/parts/markers/browser/markersPanel.ts b/src/vs/workbench/parts/markers/browser/markersPanel.ts index 615851f727f..f771f5dcaf9 100644 --- a/src/vs/workbench/parts/markers/browser/markersPanel.ts +++ b/src/vs/workbench/parts/markers/browser/markersPanel.ts @@ -32,7 +32,7 @@ import { CollapseAllAction, FilterAction, FilterInputBoxActionItem } from 'vs/wo import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import Messages from 'vs/workbench/parts/markers/common/messages'; import { RangeHighlightDecorations } from 'vs/workbench/common/editor/rangeDecorations'; -import { ContributableActionProvider } from 'vs/workbench/browser/actionBarRegistry'; +import { ContributableActionProvider } from 'vs/workbench/browser/actions'; import { IContextKeyService, IContextKey } from 'vs/platform/contextkey/common/contextkey'; import { IListService } from 'vs/platform/list/browser/listService'; import { IThemeService } from 'vs/platform/theme/common/themeService'; diff --git a/src/vs/workbench/parts/search/browser/search.contribution.ts b/src/vs/workbench/parts/search/browser/search.contribution.ts index 9cede51de89..a03f6572e09 100644 --- a/src/vs/workbench/parts/search/browser/search.contribution.ts +++ b/src/vs/workbench/parts/search/browser/search.contribution.ts @@ -15,7 +15,7 @@ import { IAction } from 'vs/base/common/actions'; import { explorerItemToFileResource } from 'vs/workbench/parts/files/common/files'; import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; import { Separator } from 'vs/base/browser/ui/actionbar/actionbar'; -import { Scope, IActionBarRegistry, Extensions as ActionBarExtensions, ActionBarContributor } from 'vs/workbench/browser/actionBarRegistry'; +import { Scope, IActionBarRegistry, Extensions as ActionBarExtensions, ActionBarContributor } from 'vs/workbench/browser/actions'; import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/workbench/common/actionRegistry'; import { QuickOpenHandlerDescriptor, IQuickOpenRegistry, Extensions as QuickOpenExtensions, QuickOpenAction } from 'vs/workbench/browser/quickopen'; import { KeybindingsRegistry } from 'vs/platform/keybinding/common/keybindingsRegistry'; diff --git a/src/vs/workbench/parts/tasks/browser/quickOpen.ts b/src/vs/workbench/parts/tasks/browser/quickOpen.ts index 6f82d048270..e4208bafd3a 100644 --- a/src/vs/workbench/parts/tasks/browser/quickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/quickOpen.ts @@ -15,7 +15,7 @@ import { IQuickOpenService } from 'vs/platform/quickOpen/common/quickOpen'; import { Task, TaskSourceKind, computeLabel } from 'vs/workbench/parts/tasks/common/tasks'; import { ITaskService } from 'vs/workbench/parts/tasks/common/taskService'; -import { ActionBarContributor, ContributableActionProvider } from 'vs/workbench/browser/actionBarRegistry'; +import { ActionBarContributor, ContributableActionProvider } from 'vs/workbench/browser/actions'; export class TaskEntry extends Model.QuickOpenEntry { diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index 411e04c6df5..c588787f5e7 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -66,7 +66,7 @@ import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; import { IOutputService, IOutputChannelRegistry, Extensions as OutputExt, IOutputChannel } from 'vs/workbench/parts/output/common/output'; -import { Scope, IActionBarRegistry, Extensions as ActionBarExtensions } from 'vs/workbench/browser/actionBarRegistry'; +import { Scope, IActionBarRegistry, Extensions as ActionBarExtensions } from 'vs/workbench/browser/actions'; import { ITerminalService } from 'vs/workbench/parts/terminal/common/terminal'; diff --git a/src/vs/workbench/test/browser/actionRegistry.test.ts b/src/vs/workbench/test/browser/actionRegistry.test.ts index 8fe4f7c8dd8..e9605ceacf6 100644 --- a/src/vs/workbench/test/browser/actionRegistry.test.ts +++ b/src/vs/workbench/test/browser/actionRegistry.test.ts @@ -10,7 +10,7 @@ import * as Platform from 'vs/platform/platform'; import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; import { Separator } from 'vs/base/browser/ui/actionbar/actionbar'; import { Extensions, IWorkbenchActionRegistry } from 'vs/workbench/common/actionRegistry'; -import { prepareActions } from 'vs/workbench/browser/actionBarRegistry'; +import { prepareActions } from 'vs/workbench/browser/actions'; import { Action } from 'vs/base/common/actions'; -- GitLab From 7ad4a225a2bd04e04bd8645568ee52f6e10f48f7 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Mon, 29 May 2017 18:18:04 +0200 Subject: [PATCH 0274/1347] :lipstick: global action --- .../parts/activitybar/activitybarActions.ts | 125 ++++++++++++------ .../parts/activitybar/activitybarPart.ts | 50 ++----- 2 files changed, 90 insertions(+), 85 deletions(-) diff --git a/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts b/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts index 287ad54470d..08a7aea55c4 100644 --- a/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts +++ b/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts @@ -20,28 +20,34 @@ import { ICommandService } from 'vs/platform/commands/common/commands'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { ViewletDescriptor } from 'vs/workbench/browser/viewlet'; -import { IActivity } from 'vs/workbench/browser/activity'; +import { IActivity, IGlobalActivity } from 'vs/workbench/browser/activity'; import { dispose } from 'vs/base/common/lifecycle'; import { IViewletService, } from 'vs/workbench/services/viewlet/browser/viewlet'; import { IPartService, Parts } from 'vs/workbench/services/part/common/partService'; import { IThemeService, ITheme, registerThemingParticipant, ICssStyleCollector } from 'vs/platform/theme/common/themeService'; import { ACTIVITY_BAR_BADGE_FOREGROUND, ACTIVITY_BAR_BADGE_BACKGROUND, ACTIVITY_BAR_DRAG_AND_DROP_BACKGROUND, ACTIVITY_BAR_FOREGROUND } from 'vs/workbench/common/theme'; import { contrastBorder, activeContrastBorder, focusBorder } from 'vs/platform/theme/common/colorRegistry'; +import { StandardMouseEvent } from "vs/base/browser/mouseEvent"; + +export interface IViewletActivity { + badge: IBadge; + clazz: string; +} export class ActivityAction extends Action { private badge: IBadge; private _onDidChangeBadge = new Emitter(); - get activity(): IActivity { - return this._activity; - } - constructor(private _activity: IActivity) { super(_activity.id, _activity.name, _activity.cssClass); this.badge = null; } + public get activity(): IActivity { + return this._activity; + } + public get onDidChangeBadge(): Event { return this._onDidChangeBadge.event; } @@ -108,14 +114,12 @@ export class ViewletActivityAction extends ActivityAction { } export class ActivityActionItem extends BaseActionItem { - + protected $container: Builder; protected $label: Builder; protected $badge: Builder; - private $badgeContent: Builder; - protected get activity(): IActivity { - return (this._action as ActivityAction).activity; - } + private $badgeContent: Builder; + private mouseUpTimeout: number; constructor( action: ActivityAction, @@ -128,6 +132,10 @@ export class ActivityActionItem extends BaseActionItem { action.onDidChangeBadge(this.handleBadgeChangeEvenet, this, this._callOnDispose); } + protected get activity(): IActivity { + return (this._action as ActivityAction).activity; + } + protected updateStyles(): void { const theme = this.themeService.getTheme(); @@ -156,7 +164,27 @@ export class ActivityActionItem extends BaseActionItem { public render(container: HTMLElement): void { super.render(container); - container.title = this.activity.name; + // Make the container tab-able for keyboard navigation + this.$container = $(container).attr({ + tabIndex: '0', + role: 'button', + title: this.activity.name + }); + + // Try hard to prevent keyboard only focus feedback when using mouse + this.$container.on(DOM.EventType.MOUSE_DOWN, () => { + this.$container.addClass('clicked'); + }); + + this.$container.on(DOM.EventType.MOUSE_UP, () => { + if (this.mouseUpTimeout) { + clearTimeout(this.mouseUpTimeout); + } + + this.mouseUpTimeout = setTimeout(() => { + this.$container.removeClass('clicked'); + }, 800); // delayed to prevent focus feedback from showing on mouse up + }); // Label this.$label = $('a.action-label').appendTo(this.builder); @@ -224,6 +252,11 @@ export class ActivityActionItem extends BaseActionItem { public dispose(): void { super.dispose(); + + if (this.mouseUpTimeout) { + clearTimeout(this.mouseUpTimeout); + } + this.$badge.destroy(); } } @@ -234,14 +267,8 @@ export class ViewletActionItem extends ActivityActionItem { private static toggleViewletPinnedAction: ToggleViewletPinnedAction; private static draggedViewlet: ViewletDescriptor; - private $container: Builder; private _keybinding: string; private cssClass: string; - private mouseUpTimeout: number; - - private get viewlet(): ViewletDescriptor { - return this.action.activity as ViewletDescriptor; - } constructor( private action: ViewletActivityAction, @@ -265,6 +292,10 @@ export class ViewletActionItem extends ActivityActionItem { } } + private get viewlet(): ViewletDescriptor { + return this.action.activity as ViewletDescriptor; + } + private getKeybindingLabel(id: string): string { const kb = this.keybindingService.lookupKeybinding(id); if (kb) { @@ -277,27 +308,6 @@ export class ViewletActionItem extends ActivityActionItem { public render(container: HTMLElement): void { super.render(container); - // Make the container tab-able for keyboard navigation - this.$container = $(container).attr({ - tabIndex: '0', - role: 'button' - }); - - // Try hard to prevent keyboard only focus feedback when using mouse - this.$container.on(DOM.EventType.MOUSE_DOWN, () => { - this.$container.addClass('clicked'); - }); - - this.$container.on(DOM.EventType.MOUSE_UP, () => { - if (this.mouseUpTimeout) { - clearTimeout(this.mouseUpTimeout); - } - - this.mouseUpTimeout = setTimeout(() => { - this.$container.removeClass('clicked'); - }, 800); // delayed to prevent focus feedback from showing on mouse up - }); - this.$container.on('contextmenu', e => { DOM.EventHelper.stop(e, true); @@ -465,10 +475,6 @@ export class ViewletActionItem extends ActivityActionItem { ViewletActionItem.clearDraggedViewlet(); - if (this.mouseUpTimeout) { - clearTimeout(this.mouseUpTimeout); - } - this.$label.destroy(); } } @@ -493,7 +499,6 @@ export class ViewletOverflowActivityAction extends ActivityAction { } export class ViewletOverflowActivityActionItem extends ActivityActionItem { - private name: string; private cssClass: string; private actions: OpenViewletAction[]; @@ -647,6 +652,40 @@ export class ToggleViewletPinnedAction extends Action { } } +export class GlobalActivityAction extends ActivityAction { + + constructor(activity: IGlobalActivity) { + super(activity); + } +} + +export class GlobalActivityActionItem extends ActivityActionItem { + + constructor( + action: GlobalActivityAction, + @IThemeService themeService: IThemeService, + @IContextMenuService protected contextMenuService: IContextMenuService + ) { + super(action, { draggable: false }, themeService); + } + + public onClick(e: MouseEvent): void { + const globalAction = this._action as GlobalActivityAction; + const activity = globalAction.activity as IGlobalActivity; + const actions = activity.getActions(); + + const event = new StandardMouseEvent(e); + event.stopPropagation(); + event.preventDefault(); + + this.contextMenuService.showContextMenu({ + getAnchor: () => ({ x: event.posx, y: event.posy }), + getActions: () => TPromise.as(actions), + onHide: () => dispose(actions) + }); + } +} + registerThemingParticipant((theme: ITheme, collector: ICssStyleCollector) => { // Styling with Outline color (e.g. high contrast theme) diff --git a/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts b/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts index 4e773ecab38..75f4d49aa70 100644 --- a/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts +++ b/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts @@ -15,11 +15,11 @@ import { Builder, $, Dimension } from 'vs/base/browser/builder'; import { Action } from 'vs/base/common/actions'; import { ActionsOrientation, ActionBar, IActionItem, Separator } from 'vs/base/browser/ui/actionbar/actionbar'; import { ViewletDescriptor } from 'vs/workbench/browser/viewlet'; -import { IGlobalActivity, GlobalActivityExtensions, IGlobalActivityRegistry } from 'vs/workbench/browser/activity'; +import { GlobalActivityExtensions, IGlobalActivityRegistry } from 'vs/workbench/browser/activity'; import { Registry } from 'vs/platform/platform'; import { Part } from 'vs/workbench/browser/part'; import { IViewlet } from 'vs/workbench/common/viewlet'; -import { ToggleViewletPinnedAction, ViewletActivityAction, ActivityAction, ActivityActionItem, ViewletActionItem, ViewletOverflowActivityAction, ViewletOverflowActivityActionItem } from 'vs/workbench/browser/parts/activitybar/activitybarActions'; +import { ToggleViewletPinnedAction, ViewletActivityAction, ActivityAction, GlobalActivityActionItem, ViewletActionItem, ViewletOverflowActivityAction, ViewletOverflowActivityActionItem, GlobalActivityAction, IViewletActivity } from 'vs/workbench/browser/parts/activitybar/activitybarActions'; import { IViewletService } from 'vs/workbench/services/viewlet/browser/viewlet'; import { IActivityBarService, IBadge } from 'vs/workbench/services/activity/common/activityBarService'; import { IPartService, Position as SideBarPosition } from 'vs/workbench/services/part/common/partService'; @@ -35,45 +35,6 @@ import { IThemeService } from 'vs/platform/theme/common/themeService'; import { ACTIVITY_BAR_BACKGROUND, ACTIVITY_BAR_BORDER } from 'vs/workbench/common/theme'; import { contrastBorder } from 'vs/platform/theme/common/colorRegistry'; -interface IViewletActivity { - badge: IBadge; - clazz: string; -} - -class GlobalActivityAction extends ActivityAction { - - constructor(activity: IGlobalActivity) { - super(activity); - } -} - -class GlobalActivityActionItem extends ActivityActionItem { - - constructor( - action: GlobalActivityAction, - @IThemeService themeService: IThemeService, - @IContextMenuService protected contextMenuService: IContextMenuService - ) { - super(action, { draggable: false }, themeService); - } - - onClick(e: MouseEvent): void { - const globalAction = this._action as GlobalActivityAction; - const activity = globalAction.activity as IGlobalActivity; - const actions = activity.getActions(); - - const event = new StandardMouseEvent(e); - event.stopPropagation(); - event.preventDefault(); - - this.contextMenuService.showContextMenu({ - getAnchor: () => ({ x: event.posx, y: event.posy }), - getActions: () => TPromise.as(actions), - onHide: () => dispose(actions) - }); - } -} - export class ActivitybarPart extends Part implements IActivityBarService { private static readonly ACTIVITY_ACTION_HEIGHT = 50; @@ -170,12 +131,12 @@ export class ActivitybarPart extends Part implements IActivityBarService { } const action = this.globalActivityIdToActions[globalActivityId]; - if (!action) { throw illegalArgument('globalActivityId'); } action.setBadge(badge); + return toDisposable(() => action.setBadge(undefined)); } @@ -574,6 +535,11 @@ export class ActivitybarPart extends Part implements IActivityBarService { this.viewletSwitcherBar = null; } + if (this.globalActionBar) { + this.globalActionBar.dispose(); + this.globalActionBar = null; + } + super.dispose(); } -- GitLab From 2d74e461808de1cd10e62dc550108dbb004daf12 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Mon, 29 May 2017 18:33:45 +0200 Subject: [PATCH 0275/1347] #26948 Provide none collapsible state --- src/vs/vscode.proposed.d.ts | 5 ++++- src/vs/workbench/parts/views/browser/views.ts | 3 ++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/vs/vscode.proposed.d.ts b/src/vs/vscode.proposed.d.ts index cf0218df999..a8877a7c25c 100644 --- a/src/vs/vscode.proposed.d.ts +++ b/src/vs/vscode.proposed.d.ts @@ -71,7 +71,6 @@ declare module 'vscode' { /** * Collapsible state of the tree item. - * Required only when item has children. */ readonly collapsibleState?: TreeItemCollapsibleState; } @@ -80,6 +79,10 @@ declare module 'vscode' { * Collapsible state of the tree item */ export enum TreeItemCollapsibleState { + /** + * Determines an item can be neither collapsed nor expanded. Implies it has no children. + */ + None = 0, /** * Determines an item is collapsed */ diff --git a/src/vs/workbench/parts/views/browser/views.ts b/src/vs/workbench/parts/views/browser/views.ts index 927059f1977..d313003efc2 100644 --- a/src/vs/workbench/parts/views/browser/views.ts +++ b/src/vs/workbench/parts/views/browser/views.ts @@ -21,6 +21,7 @@ export class ViewLocation { } export enum TreeItemCollapsibleState { + None = 0, Collapsed = 1, Expanded = 2 } @@ -48,7 +49,7 @@ export interface IViewDescriptor { readonly ctor: IViewConstructorSignature; readonly order?: number; - + } export interface ITreeItem { -- GitLab From 2ef3274358b105209b905a644ad7739cf647499e Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Mon, 29 May 2017 18:52:09 +0200 Subject: [PATCH 0276/1347] Documentation for context value in tree item --- src/vs/vscode.proposed.d.ts | 27 +++++++++++++++++++++------ 1 file changed, 21 insertions(+), 6 deletions(-) diff --git a/src/vs/vscode.proposed.d.ts b/src/vs/vscode.proposed.d.ts index a8877a7c25c..aac77423afe 100644 --- a/src/vs/vscode.proposed.d.ts +++ b/src/vs/vscode.proposed.d.ts @@ -49,7 +49,7 @@ declare module 'vscode' { export interface TreeItem { /** - * Label of the tree item + * A human-readable string describing this item */ readonly label: string; @@ -60,19 +60,34 @@ declare module 'vscode' { /** * The [command](#Command) which should be run when the tree item - * is open in the Source Control viewlet. + * is selected */ readonly command?: Command; /** - * Context value of the tree node + * [TreeItemCollapsibleState](#TreeItemCollapsibleState) of the tree item. */ - readonly contextValue?: string; + readonly collapsibleState?: TreeItemCollapsibleState; /** - * Collapsible state of the tree item. + * Context value of the tree item. This can be used to contribute item specific actions in the tree. + * For example, a tree item is given a context value as `folder`. When contribution actions to `view/item/context` + * using `menus` extension point, you can specify context value for key `viewItem` in `when` expression like `viewItem == folder`. + * ``` + * "contributes": { + "menus": { + "view/item/context": [ + { + "command": "extension.deleteFolder", + "when": "viewItem == folder" + } + ] + } + } + * ``` + * This will show action `extension.deleteFolder` only for items with `contextValue` is `folder`. */ - readonly collapsibleState?: TreeItemCollapsibleState; + readonly contextValue?: string; } /** -- GitLab From b4918a7c12e3b9d5b7ad8d4f8168a04c587932c7 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Mon, 29 May 2017 18:54:16 +0200 Subject: [PATCH 0277/1347] Fix indentation for example --- src/vs/vscode.proposed.d.ts | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/src/vs/vscode.proposed.d.ts b/src/vs/vscode.proposed.d.ts index aac77423afe..b91a0954050 100644 --- a/src/vs/vscode.proposed.d.ts +++ b/src/vs/vscode.proposed.d.ts @@ -75,15 +75,15 @@ declare module 'vscode' { * using `menus` extension point, you can specify context value for key `viewItem` in `when` expression like `viewItem == folder`. * ``` * "contributes": { - "menus": { - "view/item/context": [ - { - "command": "extension.deleteFolder", - "when": "viewItem == folder" - } - ] - } - } + * "menus": { + * "view/item/context": [ + * { + * "command": "extension.deleteFolder", + * "when": "viewItem == folder" + * } + * ] + * } + * } * ``` * This will show action `extension.deleteFolder` only for items with `contextValue` is `folder`. */ -- GitLab From 09d2e426196bf64a3b7e4ac78432ac6fe19b4596 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Mon, 29 May 2017 19:00:05 +0200 Subject: [PATCH 0278/1347] #26948 Update the doc for view data provider in API --- src/vs/vscode.proposed.d.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/vscode.proposed.d.ts b/src/vs/vscode.proposed.d.ts index b91a0954050..2d7b21802c9 100644 --- a/src/vs/vscode.proposed.d.ts +++ b/src/vs/vscode.proposed.d.ts @@ -14,8 +14,8 @@ declare module 'vscode' { export namespace window { /** - * Register a [TreeDataProvider](#TreeDataProvider) for the registered view `id`. - * @param viewId View id. + * Register a [TreeDataProvider](#TreeDataProvider) for the view contributed using the extension point `views`. + * @param viewId Id of the view contributed using the extension point `views`. * @param treeDataProvider A [TreeDataProvider](#TreeDataProvider) that provides tree data for the view */ export function registerTreeDataProviderForView(viewId: string, treeDataProvider: TreeDataProvider): Disposable; -- GitLab From 9ae89e33030cf232025ede977ca0212c64b8aa55 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Mon, 29 May 2017 19:01:14 +0200 Subject: [PATCH 0279/1347] #26948 Fix the TreeItemCollapsibleState ext host type --- src/vs/workbench/api/node/extHostTypes.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/vs/workbench/api/node/extHostTypes.ts b/src/vs/workbench/api/node/extHostTypes.ts index 2912a30ef42..7548f24f051 100644 --- a/src/vs/workbench/api/node/extHostTypes.ts +++ b/src/vs/workbench/api/node/extHostTypes.ts @@ -1276,6 +1276,7 @@ export enum ProgressLocation { } export enum TreeItemCollapsibleState { + None = 0, Collapsed = 1, Expanded = 2 } -- GitLab From 778c0309390951bc22f1b252265d3fbf30ee1f29 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Mon, 29 May 2017 19:23:06 +0200 Subject: [PATCH 0280/1347] format hygiene --- src/vs/workbench/parts/views/browser/views.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/views/browser/views.ts b/src/vs/workbench/parts/views/browser/views.ts index d313003efc2..d5a69e9827d 100644 --- a/src/vs/workbench/parts/views/browser/views.ts +++ b/src/vs/workbench/parts/views/browser/views.ts @@ -49,7 +49,7 @@ export interface IViewDescriptor { readonly ctor: IViewConstructorSignature; readonly order?: number; - + } export interface ITreeItem { -- GitLab From bc2546f0ac017de1d7238e740f88de4c3967e22c Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Mon, 29 May 2017 19:49:11 +0200 Subject: [PATCH 0281/1347] #26948 Update documentation --- src/vs/platform/extensions/common/extensionsRegistry.ts | 2 +- src/vs/workbench/parts/views/browser/treeView.ts | 2 +- src/vs/workbench/parts/views/browser/viewsExtensionPoint.ts | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/vs/platform/extensions/common/extensionsRegistry.ts b/src/vs/platform/extensions/common/extensionsRegistry.ts index 9c7b05edb71..7edf4f74960 100644 --- a/src/vs/platform/extensions/common/extensionsRegistry.ts +++ b/src/vs/platform/extensions/common/extensionsRegistry.ts @@ -182,7 +182,7 @@ const schema: IJSONSchema = { type: 'array', items: { type: 'string', - defaultSnippets: [{ label: 'onLanguage', body: 'onLanguage:${1:languageId}' }, { label: 'onCommand', body: 'onCommand:${2:commandId}' }, { label: 'onDebug', body: 'onDebug:${3:type}' }, { label: 'workspaceContains', body: 'workspaceContains:${4:fileName}' }], + defaultSnippets: [{ label: 'onLanguage', body: 'onLanguage:${1:languageId}' }, { label: 'onCommand', body: 'onCommand:${2:commandId}' }, { label: 'onDebug', body: 'onDebug:${3:type}' }, { label: 'workspaceContains', body: 'workspaceContains:${4:fileName}' }, { label: 'onView', body: 'onView:${5:viewId}' }], } }, badges: { diff --git a/src/vs/workbench/parts/views/browser/treeView.ts b/src/vs/workbench/parts/views/browser/treeView.ts index cc6c4c38b4e..d642e54a3a7 100644 --- a/src/vs/workbench/parts/views/browser/treeView.ts +++ b/src/vs/workbench/parts/views/browser/treeView.ts @@ -421,7 +421,7 @@ class Menus implements IDisposable { } getResourceContextActions(element: ITreeItem): IAction[] { - return this.getActions(MenuId.ViewItemContext, { key: 'item', value: element.contextValue }).secondary; + return this.getActions(MenuId.ViewItemContext, { key: 'viewItem', value: element.contextValue }).secondary; } private getActions(menuId: MenuId, context: { key: string, value: string }): { primary: IAction[]; secondary: IAction[]; } { diff --git a/src/vs/workbench/parts/views/browser/viewsExtensionPoint.ts b/src/vs/workbench/parts/views/browser/viewsExtensionPoint.ts index da935449c64..e7cc066c06a 100644 --- a/src/vs/workbench/parts/views/browser/viewsExtensionPoint.ts +++ b/src/vs/workbench/parts/views/browser/viewsExtensionPoint.ts @@ -51,7 +51,7 @@ namespace schema { type: 'object', properties: { id: { - description: localize('vscode.extension.contributes.view.id', 'Identifier of the view. Use the same identifier to register a data provider through API.'), + description: localize('vscode.extension.contributes.view.id', 'Identifier of the view. Use this to register a data provider through `vscode.window.registerTreeDataProviderForView` API. Also to trigger activating your extension by registering `onView:${id}` event to `activationEvents`.'), type: 'string' }, name: { @@ -66,7 +66,7 @@ namespace schema { type: 'object', properties: { 'explorer': { - description: localize('views.explorer', "Explorer"), + description: localize('views.explorer', "Explorer View"), type: 'array', items: viewDescriptor } -- GitLab From c44eec97a1e5697936bfa5cab69f6718262f7963 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Mon, 29 May 2017 19:51:50 +0200 Subject: [PATCH 0282/1347] #26948 Update doc --- src/vs/vscode.proposed.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/vscode.proposed.d.ts b/src/vs/vscode.proposed.d.ts index 2d7b21802c9..f571826403c 100644 --- a/src/vs/vscode.proposed.d.ts +++ b/src/vs/vscode.proposed.d.ts @@ -60,7 +60,7 @@ declare module 'vscode' { /** * The [command](#Command) which should be run when the tree item - * is selected + * is selected. This command is called with the model representing this item as first argument. */ readonly command?: Command; -- GitLab From 862ea061a60647817ed39ab8427788d679f1779e Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Mon, 29 May 2017 20:32:43 +0200 Subject: [PATCH 0283/1347] #26948 document view locations in menu entry contributions --- .../actions/electron-browser/menusExtensionPoint.ts | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/vs/platform/actions/electron-browser/menusExtensionPoint.ts b/src/vs/platform/actions/electron-browser/menusExtensionPoint.ts index a9a61d92d57..0e9b8d4f004 100644 --- a/src/vs/platform/actions/electron-browser/menusExtensionPoint.ts +++ b/src/vs/platform/actions/electron-browser/menusExtensionPoint.ts @@ -143,6 +143,16 @@ namespace schema { description: localize('menus.resourceStateContext', "The Source Control resource state context menu"), type: 'array', items: menuItem + }, + 'view/title': { + description: localize('view.viewTitle', "The contributed view title menu"), + type: 'array', + items: menuItem + }, + 'view/item/context': { + description: localize('view.itemContext', "The contributed view item context menu"), + type: 'array', + items: menuItem } } }; -- GitLab From 212e44d89e2000d503c699a0dd45ab05c1429bf2 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Mon, 29 May 2017 22:18:54 +0200 Subject: [PATCH 0284/1347] Minor tweaks to how annotation tasks are merged. --- .../workbench/parts/tasks/common/taskConfiguration.ts | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts index a7ccb15f65e..862419a7fea 100644 --- a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts +++ b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts @@ -835,11 +835,12 @@ namespace TaskDescription { if (problemMatchers) { task.problemMatchers = problemMatchers; } - mergeGlobals(task, globals); if (context.isTermnial && isAnnotating(task)) { + mergeGlobalsIntoAnnnotation(task, globals); annotatingTasks.push(task); return; } + mergeGlobals(task, globals); fillDefaults(task); let addTask: boolean = true; if (context.isTermnial && task.command && task.command.name && task.command.type === Tasks.CommandType.Shell && task.command.args && task.command.args.length > 0) { @@ -886,7 +887,10 @@ namespace TaskDescription { } else if (defaultTestTask.rank > -1 && defaultTestTask.rank < 2) { defaultTestTask.task.group = Tasks.TaskGroup.Test; } - return parsedTasks.length === 0 && annotatingTasks.length === 0 ? undefined : { tasks: parsedTasks, annotatingTasks: annotatingTasks }; + return { + tasks: parsedTasks.length > 0 ? parsedTasks : undefined, + annotatingTasks: annotatingTasks.length > 0 ? annotatingTasks : undefined + }; } export function mergeTasks(target: Tasks.Task[], source: Tasks.Task[]): Tasks.Task[] { @@ -942,6 +946,9 @@ namespace TaskDescription { } } + export function mergeGlobalsIntoAnnnotation(task: Tasks.Task, globals: Globals): void { + } + export function fillDefaults(task: Tasks.Task): void { CommandConfiguration.fillDefaults(task.command); if (task.args === void 0 && task.command === void 0) { -- GitLab From c2a17a7929259d3d2643cb3f98478e994a39605b Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Mon, 29 May 2017 23:09:07 +0200 Subject: [PATCH 0285/1347] Make dependsOn work with labels --- .../electron-browser/task.contribution.ts | 20 +++++++------------ 1 file changed, 7 insertions(+), 13 deletions(-) diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index c588787f5e7..540ff68d8ca 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -686,7 +686,7 @@ class TaskService extends EventEmitter implements ITaskService { toExecute = resolver.resolve(task); } else { requested = task.name; - toExecute = resolver.resolve(task._id); + toExecute = task; } if (!toExecute) { throw new TaskError(Severity.Info, nls.localize('TaskServer.noTask', 'Requested task {0} to execute not found.', requested), TaskErrors.TaskNotFound); @@ -738,6 +738,7 @@ class TaskService extends EventEmitter implements ITaskService { private createRunnableTask(sets: TaskSet[], group: TaskGroup): { task: Task; resolver: ITaskResolver } { let uuidMap: IStringDictionary = Object.create(null); + let labelMap: IStringDictionary = Object.create(null); let identifierMap: IStringDictionary = Object.create(null); let workspaceTasks: Task[] = []; @@ -745,6 +746,7 @@ class TaskService extends EventEmitter implements ITaskService { sets.forEach((set) => { set.tasks.forEach((task) => { uuidMap[task._id] = task; + labelMap[computeTaskLabel(task)] = task; identifierMap[task.identifier] = task; if (group && task.group === group) { if (task._source.kind === TaskSourceKind.Workspace) { @@ -757,11 +759,7 @@ class TaskService extends EventEmitter implements ITaskService { }); let resolver: ITaskResolver = { resolve: (id: string) => { - let result = uuidMap[id]; - if (result) { - return result; - } - return identifierMap[id]; + return uuidMap[id] || labelMap[id] || identifierMap[id]; } }; if (workspaceTasks.length > 0) { @@ -791,22 +789,18 @@ class TaskService extends EventEmitter implements ITaskService { } private createResolver(sets: TaskSet[]): ITaskResolver { - let uuidMap: IStringDictionary = Object.create(null); + let labelMap: IStringDictionary = Object.create(null); let identifierMap: IStringDictionary = Object.create(null); sets.forEach((set) => { set.tasks.forEach((task) => { - uuidMap[task._id] = task; + labelMap[computeTaskLabel(task)] = task; identifierMap[task.identifier] = task; }); }); return { resolve: (id: string) => { - let result = uuidMap[id]; - if (result) { - return result; - } - return identifierMap[id]; + return labelMap[id] || identifierMap[id]; } }; } -- GitLab From b608ce126fbbf54ee35ef624288246b29f8cb063 Mon Sep 17 00:00:00 2001 From: Jeremy Loy Date: Mon, 29 May 2017 23:10:50 -0400 Subject: [PATCH 0286/1347] Added darwinHelpBook and darwinHelpName to build process for MacOS --- build/gulpfile.vscode.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index e73e03c311d..c1501aa6336 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -117,6 +117,8 @@ const config = { darwinIcon: 'resources/darwin/code.icns', darwinBundleIdentifier: product.darwinBundleIdentifier, darwinApplicationCategoryType: 'public.app-category.developer-tools', + darwinHelpBookFolder: 'VS Code HelpBook', + darwinHelpBookName: 'VS Code HelpBook', darwinBundleDocumentTypes: [{ name: product.nameLong + ' document', role: 'Editor', -- GitLab From bf1521ab82fe0d540e89e4e6694af60b08b8bf5d Mon Sep 17 00:00:00 2001 From: Eric Amodio Date: Sat, 27 May 2017 04:45:04 -0400 Subject: [PATCH 0287/1347] =?UTF-8?q?Fixes=20#27364=20-=20title=20showing?= =?UTF-8?q?=20\u2194=20instead=20of=20=E2=9F=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- extensions/merge-conflict/src/commandHandler.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/merge-conflict/src/commandHandler.ts b/extensions/merge-conflict/src/commandHandler.ts index e35f6f3cf08..41982c06307 100644 --- a/extensions/merge-conflict/src/commandHandler.ts +++ b/extensions/merge-conflict/src/commandHandler.ts @@ -90,7 +90,7 @@ export default class CommandHandler implements vscode.Disposable { range = conflict.incoming.content; const rightUri = leftUri.with({ query: JSON.stringify(range) }); - const title = localize('compareChangesTitle', '{0}: Current changes \u2194 Incoming changes', fileName); + const title = localize('compareChangesTitle', '{0}: Current changes ⟷ Incoming changes', fileName); vscode.commands.executeCommand('vscode.diff', leftUri, rightUri, title); } -- GitLab From e5421e3fe6f5ab13f7bfe6349d19d367746ea90f Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Tue, 30 May 2017 08:29:57 +0200 Subject: [PATCH 0288/1347] Move stickiness onto DecorationRenderOptions --- src/vs/editor/common/editorCommon.ts | 2 +- src/vs/vscode.d.ts | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/vs/editor/common/editorCommon.ts b/src/vs/editor/common/editorCommon.ts index 7d437e5736b..e7e36871bf1 100644 --- a/src/vs/editor/common/editorCommon.ts +++ b/src/vs/editor/common/editorCommon.ts @@ -1636,7 +1636,6 @@ export function isThemeColor(o): o is ThemeColor { * @internal */ export interface IThemeDecorationRenderOptions { - stickiness?: TrackedRangeStickiness; backgroundColor?: string | ThemeColor; outline?: string; @@ -1688,6 +1687,7 @@ export interface IContentDecorationRenderOptions { */ export interface IDecorationRenderOptions extends IThemeDecorationRenderOptions { isWholeLine?: boolean; + stickiness?: TrackedRangeStickiness; overviewRulerLane?: OverviewRulerLane; light?: IThemeDecorationRenderOptions; diff --git a/src/vs/vscode.d.ts b/src/vs/vscode.d.ts index 53f8ad3ee63..ca27a99e4ef 100644 --- a/src/vs/vscode.d.ts +++ b/src/vs/vscode.d.ts @@ -750,12 +750,6 @@ declare module 'vscode' { * Represents theme specific rendering styles for a [text editor decoration](#TextEditorDecorationType). */ export interface ThemableDecorationRenderOptions { - /** - * Customize the growing behaviour of the decoration when typing at the edges of the decoration. - * Defaults to TrackedRangeStickiness.AlwaysGrowsWhenTypingAtEdges - */ - stickiness?: TrackedRangeStickiness; - /** * Background color of the decoration. Use rgba() and define transparent background colors to play well with other decorations. * Alternativly a color from the color registry an be [referenced](#ColorIdentifier). @@ -922,6 +916,12 @@ declare module 'vscode' { */ isWholeLine?: boolean; + /** + * Customize the growing behaviour of the decoration when typing at the edges of the decoration. + * Defaults to TrackedRangeStickiness.AlwaysGrowsWhenTypingAtEdges + */ + stickiness?: TrackedRangeStickiness; + /** * The position in the overview ruler where the decoration should be rendered. */ -- GitLab From 081fbf2231cb0fed4bddb53816567a766149590a Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Tue, 30 May 2017 09:49:31 +0200 Subject: [PATCH 0289/1347] Improve naming and doc comments --- src/vs/editor/common/editorCommon.ts | 1 + src/vs/monaco.d.ts | 1 + src/vs/vscode.d.ts | 30 +++++++++++++------ src/vs/workbench/api/node/extHost.api.impl.ts | 2 +- src/vs/workbench/api/node/extHostTypes.ts | 22 ++++++++++++++ 5 files changed, 46 insertions(+), 10 deletions(-) diff --git a/src/vs/editor/common/editorCommon.ts b/src/vs/editor/common/editorCommon.ts index e7e36871bf1..e5e5ef72371 100644 --- a/src/vs/editor/common/editorCommon.ts +++ b/src/vs/editor/common/editorCommon.ts @@ -926,6 +926,7 @@ export interface ITextModelWithMarkers extends ITextModel { /** * Describes the behaviour of decorations when typing/editing near their edges. + * Note: Please do not edit the values, as they very carefully match `DecorationRangeBehaviour` */ export enum TrackedRangeStickiness { AlwaysGrowsWhenTypingAtEdges = 0, diff --git a/src/vs/monaco.d.ts b/src/vs/monaco.d.ts index 7f3c80b83fa..2ae279bad8b 100644 --- a/src/vs/monaco.d.ts +++ b/src/vs/monaco.d.ts @@ -1639,6 +1639,7 @@ declare module monaco.editor { /** * Describes the behaviour of decorations when typing/editing near their edges. + * Note: Please do not edit the values, as they very carefully match `DecorationRangeBehaviour` */ export enum TrackedRangeStickiness { AlwaysGrowsWhenTypingAtEdges = 0, diff --git a/src/vs/vscode.d.ts b/src/vs/vscode.d.ts index ca27a99e4ef..c83e51b96df 100644 --- a/src/vs/vscode.d.ts +++ b/src/vs/vscode.d.ts @@ -701,13 +701,25 @@ declare module 'vscode' { } /** - * Describes the behaviour of decorations when typing/editing near their edges. + * Describes the behaviour of decorations when typing/editing at their edges. */ - export enum TrackedRangeStickiness { - AlwaysGrowsWhenTypingAtEdges = 0, - NeverGrowsWhenTypingAtEdges = 1, - GrowsOnlyWhenTypingBefore = 2, - GrowsOnlyWhenTypingAfter = 3 + export enum DecorationRangeBehaviour { + /** + * The decoration's range will widen when edits occur at the start or end. + */ + OpenOpen = 0, + /** + * The decoration's range will not widen when edits occur at the start of end. + */ + ClosedClosed = 1, + /** + * The decoration's range will widen when edits occur at the start, but not at the end. + */ + OpenClosed = 2, + /** + * The decoration's range will widen when edits occur at the end, but not at the start. + */ + ClosedOpen = 3 } /** @@ -917,10 +929,10 @@ declare module 'vscode' { isWholeLine?: boolean; /** - * Customize the growing behaviour of the decoration when typing at the edges of the decoration. - * Defaults to TrackedRangeStickiness.AlwaysGrowsWhenTypingAtEdges + * Customize the growing behaviour of the decoration when edits occur at the edges of the decoration's range. + * Defaults to `DecorationRangeBehaviour.OpenOpen`. */ - stickiness?: TrackedRangeStickiness; + rangeBehaviour?: DecorationRangeBehaviour; /** * The position in the overview ruler where the decoration should be rendered. diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index 11fda78db64..1c7a6687056 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -529,7 +529,7 @@ export function createApiFactory( TextEditorLineNumbersStyle: extHostTypes.TextEditorLineNumbersStyle, TextEditorRevealType: extHostTypes.TextEditorRevealType, TextEditorSelectionChangeKind: extHostTypes.TextEditorSelectionChangeKind, - TrackedRangeStickiness: EditorCommon.TrackedRangeStickiness, + DecorationRangeBehaviour: extHostTypes.DecorationRangeBehaviour, Uri: URI, ViewColumn: extHostTypes.ViewColumn, WorkspaceEdit: extHostTypes.WorkspaceEdit, diff --git a/src/vs/workbench/api/node/extHostTypes.ts b/src/vs/workbench/api/node/extHostTypes.ts index 7548f24f051..2e90e54aba4 100644 --- a/src/vs/workbench/api/node/extHostTypes.ts +++ b/src/vs/workbench/api/node/extHostTypes.ts @@ -962,6 +962,28 @@ export enum TextEditorSelectionChangeKind { Command = 3 } +/** + * These values match very carefully the values of `TrackedRangeStickiness` + */ +export enum DecorationRangeBehaviour { + /** + * TrackedRangeStickiness.AlwaysGrowsWhenTypingAtEdges + */ + OpenOpen = 0, + /** + * TrackedRangeStickiness.NeverGrowsWhenTypingAtEdges + */ + ClosedClosed = 1, + /** + * TrackedRangeStickiness.GrowsOnlyWhenTypingBefore + */ + OpenClosed = 2, + /** + * TrackedRangeStickiness.GrowsOnlyWhenTypingAfter + */ + ClosedOpen = 3 +} + export namespace TextEditorSelectionChangeKind { export function fromValue(s: string) { switch (s) { -- GitLab From 47a6a7af618803100c28ea04af5e1f02d8bd6d70 Mon Sep 17 00:00:00 2001 From: isidor Date: Tue, 30 May 2017 09:59:16 +0200 Subject: [PATCH 0290/1347] light update contribution not for windows --- .../parts/update/electron-browser/update.contribution.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/update/electron-browser/update.contribution.ts b/src/vs/workbench/parts/update/electron-browser/update.contribution.ts index 64bba795487..7e8681a56ae 100644 --- a/src/vs/workbench/parts/update/electron-browser/update.contribution.ts +++ b/src/vs/workbench/parts/update/electron-browser/update.contribution.ts @@ -8,6 +8,7 @@ import * as nls from 'vs/nls'; import 'vs/css!./media/update.contribution'; import { Registry } from 'vs/platform/platform'; +import { isWindows } from 'vs/base/common/platform'; import product from 'vs/platform/node/product'; import { IWorkbenchContributionsRegistry, Extensions as WorkbenchExtensions } from 'vs/workbench/common/contributions'; import { ReleaseNotesEditor } from 'vs/workbench/parts/update/electron-browser/releaseNotesEditor'; @@ -24,7 +25,7 @@ import { ShowCurrentReleaseNotesAction, ProductContribution, UpdateContribution, Registry.as(WorkbenchExtensions.Workbench) .registerWorkbenchContribution(ProductContribution); -if (product.quality !== 'stable') { +if (product.quality !== 'stable' && !isWindows) { Registry.as(GlobalActivityExtensions) .registerActivity(LightUpdateContribution); } else { -- GitLab From f64bc3f92abd444d38d8c788f45226408eb5a174 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Tue, 30 May 2017 11:01:20 +0200 Subject: [PATCH 0291/1347] Prefer the American English spelling behavior --- .../browser/services/codeEditorServiceImpl.ts | 2 +- src/vs/editor/common/editorCommon.ts | 2 +- src/vs/vscode.d.ts | 14 +++++++------- src/vs/workbench/api/node/extHost.api.impl.ts | 2 +- src/vs/workbench/api/node/extHostTypes.ts | 2 +- 5 files changed, 11 insertions(+), 11 deletions(-) diff --git a/src/vs/editor/browser/services/codeEditorServiceImpl.ts b/src/vs/editor/browser/services/codeEditorServiceImpl.ts index cad86e56150..f19885a1326 100644 --- a/src/vs/editor/browser/services/codeEditorServiceImpl.ts +++ b/src/vs/editor/browser/services/codeEditorServiceImpl.ts @@ -156,7 +156,7 @@ class DecorationTypeOptionsProvider implements IModelDecorationOptionsProvider { let options = providerArgs.options; this.isWholeLine = Boolean(options.isWholeLine); - this.stickiness = options.stickiness; + this.stickiness = options.rangeBehavior; let lightOverviewRulerColor = options.light && options.light.overviewRulerColor || options.overviewRulerColor; let darkOverviewRulerColor = options.dark && options.dark.overviewRulerColor || options.overviewRulerColor; diff --git a/src/vs/editor/common/editorCommon.ts b/src/vs/editor/common/editorCommon.ts index e5e5ef72371..fb5cc8218ac 100644 --- a/src/vs/editor/common/editorCommon.ts +++ b/src/vs/editor/common/editorCommon.ts @@ -1688,7 +1688,7 @@ export interface IContentDecorationRenderOptions { */ export interface IDecorationRenderOptions extends IThemeDecorationRenderOptions { isWholeLine?: boolean; - stickiness?: TrackedRangeStickiness; + rangeBehavior?: TrackedRangeStickiness; overviewRulerLane?: OverviewRulerLane; light?: IThemeDecorationRenderOptions; diff --git a/src/vs/vscode.d.ts b/src/vs/vscode.d.ts index c83e51b96df..905765c2aa0 100644 --- a/src/vs/vscode.d.ts +++ b/src/vs/vscode.d.ts @@ -701,9 +701,9 @@ declare module 'vscode' { } /** - * Describes the behaviour of decorations when typing/editing at their edges. + * Describes the behavior of decorations when typing/editing at their edges. */ - export enum DecorationRangeBehaviour { + export enum DecorationRangeBehavior { /** * The decoration's range will widen when edits occur at the start or end. */ @@ -929,10 +929,10 @@ declare module 'vscode' { isWholeLine?: boolean; /** - * Customize the growing behaviour of the decoration when edits occur at the edges of the decoration's range. - * Defaults to `DecorationRangeBehaviour.OpenOpen`. + * Customize the growing behavior of the decoration when edits occur at the edges of the decoration's range. + * Defaults to `DecorationRangeBehavior.OpenOpen`. */ - rangeBehaviour?: DecorationRangeBehaviour; + rangeBehavior?: DecorationRangeBehavior; /** * The position in the overview ruler where the decoration should be rendered. @@ -1035,7 +1035,7 @@ declare module 'vscode' { * callback executes. * * @param callback A function which can create edits using an [edit-builder](#TextEditorEdit). - * @param options The undo/redo behaviour around this edit. By default, undo stops will be created before and after this edit. + * @param options The undo/redo behavior around this edit. By default, undo stops will be created before and after this edit. * @return A promise that resolves with a value indicating if the edits could be applied. */ edit(callback: (editBuilder: TextEditorEdit) => void, options?: { undoStopBefore: boolean; undoStopAfter: boolean; }): Thenable; @@ -1047,7 +1047,7 @@ declare module 'vscode' { * * @param snippet The snippet to insert in this edit. * @param location Position or range at which to insert the snippet, defaults to the current editor selection or selections. - * @param options The undo/redo behaviour around this edit. By default, undo stops will be created before and after this edit. + * @param options The undo/redo behavior around this edit. By default, undo stops will be created before and after this edit. * @return A promise that resolves with a value indicating if the snippet could be inserted. Note that the promise does not signal * that the snippet is completely filled-in or accepted. */ diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index 1c7a6687056..eda65776c32 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -529,7 +529,7 @@ export function createApiFactory( TextEditorLineNumbersStyle: extHostTypes.TextEditorLineNumbersStyle, TextEditorRevealType: extHostTypes.TextEditorRevealType, TextEditorSelectionChangeKind: extHostTypes.TextEditorSelectionChangeKind, - DecorationRangeBehaviour: extHostTypes.DecorationRangeBehaviour, + DecorationRangeBehavior: extHostTypes.DecorationRangeBehavior, Uri: URI, ViewColumn: extHostTypes.ViewColumn, WorkspaceEdit: extHostTypes.WorkspaceEdit, diff --git a/src/vs/workbench/api/node/extHostTypes.ts b/src/vs/workbench/api/node/extHostTypes.ts index 2e90e54aba4..353765544fd 100644 --- a/src/vs/workbench/api/node/extHostTypes.ts +++ b/src/vs/workbench/api/node/extHostTypes.ts @@ -965,7 +965,7 @@ export enum TextEditorSelectionChangeKind { /** * These values match very carefully the values of `TrackedRangeStickiness` */ -export enum DecorationRangeBehaviour { +export enum DecorationRangeBehavior { /** * TrackedRangeStickiness.AlwaysGrowsWhenTypingAtEdges */ -- GitLab From afe47dc84467b487ce0079ff72f55e7ef4f7ebca Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Tue, 30 May 2017 11:06:29 +0200 Subject: [PATCH 0292/1347] Fix spelling --- src/vs/editor/common/editorCommon.ts | 6 +++--- src/vs/monaco.d.ts | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/vs/editor/common/editorCommon.ts b/src/vs/editor/common/editorCommon.ts index fb5cc8218ac..ce257401e3e 100644 --- a/src/vs/editor/common/editorCommon.ts +++ b/src/vs/editor/common/editorCommon.ts @@ -65,7 +65,7 @@ export interface IModelDecorationOverviewRulerOptions { */ export interface IModelDecorationOptions { /** - * Customize the growing behaviour of the decoration when typing at the edges of the decoration. + * Customize the growing behavior of the decoration when typing at the edges of the decoration. * Defaults to TrackedRangeStickiness.AlwaysGrowsWhenTypingAtEdges */ stickiness?: TrackedRangeStickiness; @@ -925,8 +925,8 @@ export interface ITextModelWithMarkers extends ITextModel { } /** - * Describes the behaviour of decorations when typing/editing near their edges. - * Note: Please do not edit the values, as they very carefully match `DecorationRangeBehaviour` + * Describes the behavior of decorations when typing/editing near their edges. + * Note: Please do not edit the values, as they very carefully match `DecorationRangeBehavior` */ export enum TrackedRangeStickiness { AlwaysGrowsWhenTypingAtEdges = 0, diff --git a/src/vs/monaco.d.ts b/src/vs/monaco.d.ts index 2ae279bad8b..d293d474a24 100644 --- a/src/vs/monaco.d.ts +++ b/src/vs/monaco.d.ts @@ -1092,7 +1092,7 @@ declare module monaco.editor { */ export interface IModelDecorationOptions { /** - * Customize the growing behaviour of the decoration when typing at the edges of the decoration. + * Customize the growing behavior of the decoration when typing at the edges of the decoration. * Defaults to TrackedRangeStickiness.AlwaysGrowsWhenTypingAtEdges */ stickiness?: TrackedRangeStickiness; @@ -1638,8 +1638,8 @@ declare module monaco.editor { } /** - * Describes the behaviour of decorations when typing/editing near their edges. - * Note: Please do not edit the values, as they very carefully match `DecorationRangeBehaviour` + * Describes the behavior of decorations when typing/editing near their edges. + * Note: Please do not edit the values, as they very carefully match `DecorationRangeBehavior` */ export enum TrackedRangeStickiness { AlwaysGrowsWhenTypingAtEdges = 0, -- GitLab From f58278d1a40fdb2b6b4129925ba68a24b1e083d8 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Tue, 30 May 2017 14:31:30 +0200 Subject: [PATCH 0293/1347] Fixes #27545: Task templates contain deprecated properties --- src/vs/workbench/parts/tasks/common/taskTemplates.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/vs/workbench/parts/tasks/common/taskTemplates.ts b/src/vs/workbench/parts/tasks/common/taskTemplates.ts index ca345475266..b88527097ca 100644 --- a/src/vs/workbench/parts/tasks/common/taskTemplates.ts +++ b/src/vs/workbench/parts/tasks/common/taskTemplates.ts @@ -29,7 +29,7 @@ const dotnetBuild: TaskEntry = { '\t\t{', '\t\t\t"taskName": "build",', '\t\t\t"command": "dotnet",', - '\t\t\t"isShellCommand": true,', + '\t\t\t"type": "shell",', '\t\t\t"group": "build",', '\t\t\t"terminal": {', '\t\t\t\t"reveal": "silent"', @@ -87,7 +87,7 @@ const command: TaskEntry = { '\t\t{', '\t\t\t"taskName": "echo",', '\t\t\t"command": "echo Hello",', - '\t\t\t"isShellCommand": true', + '\t\t\t"type": "shell"', '\t\t}', '\t]', '}' @@ -109,13 +109,13 @@ const maven: TaskEntry = { '\t\t{', '\t\t\t"taskName": "verify",', '\t\t\t"command": "mvn -B verify",', - '\t\t\t"isShellCommand": true,', + '\t\t\t"type": "shell",', '\t\t\t"group": "build"', '\t\t},', '\t\t{', '\t\t\t"taskName": "test",', '\t\t\t"command": "mvn -B test",', - '\t\t\t"isShellCommand": true,', + '\t\t\t"type": "shell",', '\t\t\t"group": "test"', '\t\t}', '\t]', -- GitLab From 7f13da53d5c958aab3cc3b47538ff099fef153fb Mon Sep 17 00:00:00 2001 From: isidor Date: Tue, 30 May 2017 12:46:58 +0200 Subject: [PATCH 0294/1347] light update: enable for win --- .../parts/update/electron-browser/update.contribution.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/update/electron-browser/update.contribution.ts b/src/vs/workbench/parts/update/electron-browser/update.contribution.ts index 7e8681a56ae..64bba795487 100644 --- a/src/vs/workbench/parts/update/electron-browser/update.contribution.ts +++ b/src/vs/workbench/parts/update/electron-browser/update.contribution.ts @@ -8,7 +8,6 @@ import * as nls from 'vs/nls'; import 'vs/css!./media/update.contribution'; import { Registry } from 'vs/platform/platform'; -import { isWindows } from 'vs/base/common/platform'; import product from 'vs/platform/node/product'; import { IWorkbenchContributionsRegistry, Extensions as WorkbenchExtensions } from 'vs/workbench/common/contributions'; import { ReleaseNotesEditor } from 'vs/workbench/parts/update/electron-browser/releaseNotesEditor'; @@ -25,7 +24,7 @@ import { ShowCurrentReleaseNotesAction, ProductContribution, UpdateContribution, Registry.as(WorkbenchExtensions.Workbench) .registerWorkbenchContribution(ProductContribution); -if (product.quality !== 'stable' && !isWindows) { +if (product.quality !== 'stable') { Registry.as(GlobalActivityExtensions) .registerActivity(LightUpdateContribution); } else { -- GitLab From 333bebe5e7586a412a48e2231db3a1c1be7e5000 Mon Sep 17 00:00:00 2001 From: isidor Date: Tue, 30 May 2017 12:51:14 +0200 Subject: [PATCH 0295/1347] light update: use number badge --- src/vs/workbench/parts/update/electron-browser/update.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/update/electron-browser/update.ts b/src/vs/workbench/parts/update/electron-browser/update.ts index c68899b0830..9b77ef4c8fb 100644 --- a/src/vs/workbench/parts/update/electron-browser/update.ts +++ b/src/vs/workbench/parts/update/electron-browser/update.ts @@ -15,7 +15,7 @@ import pkg from 'vs/platform/node/package'; import product from 'vs/platform/node/product'; import URI from 'vs/base/common/uri'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; -import { IActivityBarService, TextBadge } from 'vs/workbench/services/activity/common/activityBarService'; +import { IActivityBarService, NumberBadge } from 'vs/workbench/services/activity/common/activityBarService'; import { IInstantiationService, ServicesAccessor } from 'vs/platform/instantiation/common/instantiation'; import { ReleaseNotesInput } from 'vs/workbench/parts/update/electron-browser/releaseNotesInput'; import { IGlobalActivity } from 'vs/workbench/browser/activity'; @@ -297,7 +297,7 @@ export class LightUpdateContribution implements IGlobalActivity { @IActivityBarService activityBarService: IActivityBarService ) { this.updateService.onUpdateReady(() => { - const badge = new TextBadge('\u21e9', () => nls.localize('updateIsReady', "New update available.")); + const badge = new NumberBadge(1, () => nls.localize('updateIsReady', "New update available.")); activityBarService.showGlobalActivity(this.id, badge); }); -- GitLab From 7a7965a93e265d6ae60960f76da5f3209ae11d91 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Tue, 30 May 2017 14:47:40 +0200 Subject: [PATCH 0296/1347] Run over clean extensions directory for data migration tests. Fixes #27537. --- test/smoke/src/areas/common.ts | 14 ++++++++------ test/smoke/src/tests/data-migration.ts | 7 ++++--- 2 files changed, 12 insertions(+), 9 deletions(-) diff --git a/test/smoke/src/areas/common.ts b/test/smoke/src/areas/common.ts index 33127905ec6..96515d7ca49 100644 --- a/test/smoke/src/areas/common.ts +++ b/test/smoke/src/areas/common.ts @@ -19,7 +19,7 @@ export class CommonActions { public async getWindowTitle(): Promise { return this.spectron.client.getTitle(); } - + public enter(): Promise { return this.spectron.client.keys(['Enter', 'NULL']); } @@ -34,7 +34,7 @@ export class CommonActions { await this.spectron.wait(); return this.saveOpenedFile(); } - + public async newUntitledFile(): Promise { await this.spectron.command('workbench.action.files.newUntitledFile'); return this.spectron.wait(); @@ -45,12 +45,14 @@ export class CommonActions { } public async getTab(tabName: string, active?: boolean): Promise { + await this.spectron.command('workbench.action.closeMessages'); // close any notification messages that could overlap tabs + let tabSelector = active ? '.tab.active' : 'div'; let el = await this.spectron.client.element(`.tabs-container ${tabSelector}[aria-label="${tabName}, tab"]`); if (el.status === 0) { return el; } - + return undefined; } @@ -118,7 +120,7 @@ export class CommonActions { selector += ' explorer-item'; } selector += '"]'; - + await this.spectron.waitFor(this.spectron.client.doubleClick, selector); return this.spectron.wait(); } @@ -132,7 +134,7 @@ export class CommonActions { } else if (extension === 'md') { return 'md-ext-file-icon markdown-lang-file-icon'; } - + throw new Error('No class defined for this file extension'); } @@ -142,7 +144,7 @@ export class CommonActions { if (Array.isArray(span)) { return span[0]; } - + return span; } catch (e) { return undefined; diff --git a/test/smoke/src/tests/data-migration.ts b/test/smoke/src/tests/data-migration.ts index 4b8e627bcfe..68c4f698b7e 100644 --- a/test/smoke/src/tests/data-migration.ts +++ b/test/smoke/src/tests/data-migration.ts @@ -5,7 +5,7 @@ import * as assert from 'assert'; -import { SpectronApplication, USER_DIR, STABLE_PATH, LATEST_PATH, WORKSPACE_PATH } from "../spectron/application"; +import { SpectronApplication, USER_DIR, STABLE_PATH, LATEST_PATH, WORKSPACE_PATH, EXTENSIONS_DIR } from "../spectron/application"; import { CommonActions } from '../areas/common'; let app: SpectronApplication; @@ -20,11 +20,12 @@ export function testDataMigration() { afterEach(async function () { await app.stop(); - return await common.removeDirectory(USER_DIR) + await common.removeDirectory(USER_DIR); + return await common.removeDirectory(EXTENSIONS_DIR); }); function setupSpectron(context: Mocha.ITestCallbackContext, appPath: string, workspace?: string[]): void { - app = new SpectronApplication(appPath, context.test.fullTitle(), context.test.currentRetry(), workspace, [`--user-data-dir=${USER_DIR}`]); + app = new SpectronApplication(appPath, context.test.fullTitle(), context.test.currentRetry(), workspace, [`--user-data-dir=${USER_DIR}`, `--extensions-dir=${EXTENSIONS_DIR}`]); common = new CommonActions(app); } -- GitLab From 26d85e8ac7f7e2eb646ddf9c171e471e10ef8deb Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Tue, 30 May 2017 16:55:32 +0200 Subject: [PATCH 0297/1347] Toggle full screen for reading out output console due to editor redrawing div elements. --- test/smoke/src/areas/tasks.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/test/smoke/src/areas/tasks.ts b/test/smoke/src/areas/tasks.ts index e0774854f3a..62eaaed9262 100644 --- a/test/smoke/src/areas/tasks.ts +++ b/test/smoke/src/areas/tasks.ts @@ -25,12 +25,14 @@ export class Tasks { } public async firstOutputLineEndsWith(fileName: string): Promise { + await this.spectron.command('workbench.action.toggleFullScreen'); // toggle full screen to prevent output view to be rendered as wrapped const firstLine = await this.spectron.waitFor(this.spectron.client.getText, `${this.outputViewSelector}>:nth-child(2)`); return firstLine.endsWith(fileName); } - public getOutputResult(): Promise { + public async getOutputResult(): Promise { + await this.spectron.command('workbench.action.toggleFullScreen'); // toggle full screen to prevent output view to be rendered as wrapped return this.spectron.waitFor(this.spectron.client.getText, `${this.outputViewSelector}>:nth-child(5) span.mtk1`); } -- GitLab From 4b995d52ec0b61107e81263f54845b91993cb960 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Tue, 30 May 2017 08:34:00 -0700 Subject: [PATCH 0298/1347] Add null check on extra bag --- .../crashReporter/electron-browser/crashReporterService.ts | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts b/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts index 58cca417c6b..0acfd1793ac 100644 --- a/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts +++ b/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts @@ -81,7 +81,12 @@ export class CrashReporterService implements ICrashReporterService { // Experimental attempt on Mac only for now if (isMacintosh) { const childProcessOptions = clone(this.options); - childProcessOptions.extra.processName = name; + if (childProcessOptions.extra) { + childProcessOptions.extra.processName = name; + } else { + childProcessOptions.extra = { processName: name }; + } + childProcessOptions.crashesDirectory = os.tmpdir(); return childProcessOptions; } -- GitLab From e6217c699a9988a0f2829f68f1643104ce351d47 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Tue, 30 May 2017 18:06:16 +0200 Subject: [PATCH 0299/1347] adopt some new color keys in our built in themes --- extensions/theme-abyss/themes/abyss-color-theme.json | 4 ++++ .../theme-kimbie-dark/themes/kimbie-dark-color-theme.json | 1 + extensions/theme-monokai/themes/monokai-color-theme.json | 1 + .../theme-quietlight/themes/quietlight-color-theme.json | 2 ++ extensions/theme-red/themes/Red-color-theme.json | 6 +++++- .../themes/solarized-dark-color-theme.json | 4 ++++ .../themes/solarized-light-color-theme.json | 6 ++++++ .../themes/tomorrow-night-blue-theme.json | 1 + 8 files changed, 24 insertions(+), 1 deletion(-) diff --git a/extensions/theme-abyss/themes/abyss-color-theme.json b/extensions/theme-abyss/themes/abyss-color-theme.json index a67dd83b89d..5b2c2e1e546 100644 --- a/extensions/theme-abyss/themes/abyss-color-theme.json +++ b/extensions/theme-abyss/themes/abyss-color-theme.json @@ -408,6 +408,10 @@ "pickerGroup.border": "#596F99", "pickerGroup.foreground": "#596F99", + // Workbench: Extensions + "extensionButton.prominentBackground": "#5f8b3b", + "extensionButton.prominentHoverBackground": "#5f8b3bbb", + // Workbench: Terminal "terminal.ansiBlack": "#111111", "terminal.ansiRed": "#ff9da4", diff --git a/extensions/theme-kimbie-dark/themes/kimbie-dark-color-theme.json b/extensions/theme-kimbie-dark/themes/kimbie-dark-color-theme.json index 7de6b3fd42e..f9a84a5c5ee 100644 --- a/extensions/theme-kimbie-dark/themes/kimbie-dark-color-theme.json +++ b/extensions/theme-kimbie-dark/themes/kimbie-dark-color-theme.json @@ -14,6 +14,7 @@ "pickerGroup.foreground": "#e3b583", "pickerGroup.border": "#e3b583", "inputOption.activeBorder": "#a57a4c", + "selection.background": "#84613daa", "editor.selectionBackground": "#84613daa", "editorWidget.background": "#131510", "editorHoverWidget.background": "#221a14", diff --git a/extensions/theme-monokai/themes/monokai-color-theme.json b/extensions/theme-monokai/themes/monokai-color-theme.json index 439bf32d607..fa2146e0a84 100644 --- a/extensions/theme-monokai/themes/monokai-color-theme.json +++ b/extensions/theme-monokai/themes/monokai-color-theme.json @@ -17,6 +17,7 @@ "button.background": "#75715E", "editor.background": "#272822", "editor.foreground": "#f8f8f2", + "selection.background": "#ccccc7", "editor.selectionBackground": "#49483e", "editor.lineHighlightBackground": "#3e3d32", "editorCursor.foreground": "#f8f8f0", diff --git a/extensions/theme-quietlight/themes/quietlight-color-theme.json b/extensions/theme-quietlight/themes/quietlight-color-theme.json index 3086021874b..5ab654716a7 100644 --- a/extensions/theme-quietlight/themes/quietlight-color-theme.json +++ b/extensions/theme-quietlight/themes/quietlight-color-theme.json @@ -461,6 +461,7 @@ "list.activeSelectionBackground": "#c4d9b1", "list.inactiveSelectionBackground": "#d3dbcd", "list.highlightForeground": "#9769dc", + "selection.background": "#C9D0D9", "editor.background": "#F5F5F5", "editorWhitespace.foreground": "#AAAAAA", "editor.lineHighlightBackground": "#E4F6D4", @@ -495,6 +496,7 @@ "inputValidation.warningBorder": "#ffe055", "inputValidation.errorBackground": "#ffeaea", "inputValidation.errorBorder": "#f1897f", + "errorForeground": "#ffeaea", "badge.background": "#705697AA", "progressBar.background": "#705697" } diff --git a/extensions/theme-red/themes/Red-color-theme.json b/extensions/theme-red/themes/Red-color-theme.json index a35bfe0938b..94d2c20ae2b 100644 --- a/extensions/theme-red/themes/Red-color-theme.json +++ b/extensions/theme-red/themes/Red-color-theme.json @@ -11,6 +11,7 @@ "editorGroupHeader.tabsBackground": "#330000", "titleBar.activeBackground": "#770000", "titleBar.inactiveBackground": "#772222", + "selection.background": "#ff777788", // editor "editor.background": "#390000", "editorGroup.border": "#ff666633", @@ -51,7 +52,10 @@ "pickerGroup.foreground": "#cc9999", "pickerGroup.border": "#ff000033", "badge.background": "#cc3333", - "progressBar.background": "#cc3333" + "progressBar.background": "#cc3333", + "errorForeground": "#ffeaea", + "extensionButton.prominentBackground": "#cc3333", + "extensionButton.prominentHoverBackground": "#cc333388" }, "name": "Red" } \ No newline at end of file diff --git a/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json b/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json index 10b058c4911..542de82d4c8 100644 --- a/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json +++ b/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json @@ -301,6 +301,8 @@ // "widget.shadow": "", + "selection.background": "#2AA19899", + "input.background": "#003847", "input.foreground": "#93A1A1", "input.placeholderForeground": "#93A1A1AA", @@ -314,6 +316,8 @@ "inputValidation.errorBackground": "#571b26", "inputValidation.errorBorder": "#a92049", + "errorForeground": "#ffeaea", + "badge.background": "#047aa6", "progressBar.background": "#047aa6", diff --git a/extensions/theme-solarized-light/themes/solarized-light-color-theme.json b/extensions/theme-solarized-light/themes/solarized-light-color-theme.json index cebad7db3b2..cd42bbaa859 100644 --- a/extensions/theme-solarized-light/themes/solarized-light-color-theme.json +++ b/extensions/theme-solarized-light/themes/solarized-light-color-theme.json @@ -323,6 +323,8 @@ "button.background": "#AC9D57", // "button.foreground": "", + "selection.background": "#CCC4B0", + "list.activeSelectionBackground": "#DFCA88", "list.activeSelectionForeground": "#6C6C6C", "list.focusBackground": "#DFCA8866", @@ -453,6 +455,10 @@ "pickerGroup.border": "#2AA19899", "pickerGroup.foreground": "#2AA19899", + // Extensions + "extensionButton.prominentBackground": "#b58900", + "extensionButton.prominentHoverBackground": "#584c27aa", + // Workbench: Terminal // Colors sourced from the official palette http://ethanschoonover.com/solarized "terminal.ansiBlack": "#262626", diff --git a/extensions/theme-tomorrow-night-blue/themes/tomorrow-night-blue-theme.json b/extensions/theme-tomorrow-night-blue/themes/tomorrow-night-blue-theme.json index 319f8be0a61..830caf27cb6 100644 --- a/extensions/theme-tomorrow-night-blue/themes/tomorrow-night-blue-theme.json +++ b/extensions/theme-tomorrow-night-blue/themes/tomorrow-night-blue-theme.json @@ -2,6 +2,7 @@ "type": "dark", "colors": { "focusBorder": "#bbdaff", + "errorForeground": "#a92049", "input.background": "#001733", "dropdown.background": "#001733", "list.focusBackground": "#ffffff60", -- GitLab From 8afd3ffb6591027c1391f2359f1bbc6f092455d4 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Tue, 30 May 2017 21:06:50 +0200 Subject: [PATCH 0300/1347] Fixes #27578: Don't mention VS Code in jsdoc --- src/vs/vscode.d.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/vs/vscode.d.ts b/src/vs/vscode.d.ts index 905765c2aa0..79d24b87499 100644 --- a/src/vs/vscode.d.ts +++ b/src/vs/vscode.d.ts @@ -3577,7 +3577,7 @@ declare module 'vscode' { export interface ProcessOptions { /** * The current working directory of the executed program or shell. - * If omitted VSCode's current workspace root is used. + * If omitted the tools current workspace root is used. */ cwd?: string; @@ -3719,7 +3719,7 @@ declare module 'vscode' { /** * The current working directory of the executed shell. - * If omitted VSCode's current workspace root is used. + * If omitted the tools current workspace root is used. */ cwd?: string; @@ -3732,7 +3732,7 @@ declare module 'vscode' { } | { /** * The current working directory of the executed shell. - * If omitted VSCode's current workspace root is used. + * If omitted the tools current workspace root is used. */ cwd: string; @@ -3745,7 +3745,7 @@ declare module 'vscode' { } | { /** * The current working directory of the executed shell. - * If omitted VSCode's current workspace root is used. + * If omitted the tools current workspace root is used. */ cwd?: string; -- GitLab From 6fb0af28cdd8454439944ac60927232b4dffdc2c Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Tue, 30 May 2017 21:59:20 +0200 Subject: [PATCH 0301/1347] Fixes #27581: Unspecific names: TerminalBehaviour and RevealKind --- src/vs/vscode.d.ts | 34 ++++++++++--------- src/vs/workbench/api/node/extHost.api.impl.ts | 2 +- src/vs/workbench/api/node/extHostTask.ts | 16 ++++----- src/vs/workbench/api/node/extHostTypes.ts | 34 +++++++++---------- 4 files changed, 44 insertions(+), 42 deletions(-) diff --git a/src/vs/vscode.d.ts b/src/vs/vscode.d.ts index 79d24b87499..d7cffd9896a 100644 --- a/src/vs/vscode.d.ts +++ b/src/vs/vscode.d.ts @@ -3540,7 +3540,7 @@ declare module 'vscode' { /** * Controls the behaviour of the terminal's visibility. */ - export enum RevealKind { + export enum TaskRevealKind { /** * Always brings the terminal to front if the task is executed. */ @@ -3559,14 +3559,14 @@ declare module 'vscode' { } /** - * Controls terminal specific behaviour. + * Controls terminal specific behavior. */ - export interface TerminalBehaviour { + export interface TaskTerminalBehavior { /** * Controls whether the terminal executing a task is brought to front or not. * Defaults to `RevealKind.Always`. */ - reveal?: RevealKind; + reveal?: TaskRevealKind; /** * Controls whether the command is echoed in the terminal or not. @@ -3574,7 +3574,7 @@ declare module 'vscode' { echo?: boolean; } - export interface ProcessOptions { + export interface ProcessTaskOptions { /** * The current working directory of the executed program or shell. * If omitted the tools current workspace root is used. @@ -3595,7 +3595,8 @@ declare module 'vscode' { */ export const Clean: 'clean'; /** - * The build task group + * The build task group. If a task is part of the build task group + * it can be executed via the run build short cut. */ export const Build: 'build'; /** @@ -3603,7 +3604,8 @@ declare module 'vscode' { */ export const RebuildAll: 'rebuildAll'; /** - * The test task group + * The test task group. If a task is part of the test task group + * it can be executed via the run test short cut. */ export const Test: 'test'; } @@ -3646,7 +3648,7 @@ declare module 'vscode' { * @param options additional options for the started process. * @param problemMatchers the problem matchers to use. */ - constructor(name: string, process: string, args: string[], options: ProcessOptions, problemMatchers?: ProblemMatchers); + constructor(name: string, process: string, args: string[], options: ProcessTaskOptions, problemMatchers?: ProblemMatchers); /** * The task's name @@ -3692,12 +3694,12 @@ declare module 'vscode' { * The process options used when the process is executed. * Defaults to an empty object literal. */ - options: ProcessOptions; + options: ProcessTaskOptions; /** - * The terminal options. Defaults to an empty object literal. + * The terminal behavior. Defaults to an empty object literal. */ - terminal: TerminalBehaviour; + terminal: TaskTerminalBehavior; /** * The problem matchers attached to the task. Defaults to an empty @@ -3706,7 +3708,7 @@ declare module 'vscode' { problemMatchers: string[]; } - export type ShellOptions = { + export type ShellTaskOptions = { /** * The shell executable. */ @@ -3779,7 +3781,7 @@ declare module 'vscode' { * @param options additional options used when creating the shell. * @param problemMatchers the problem matchers to use. */ - constructor(name: string, commandLine: string, options: ShellOptions, problemMatchers?: ProblemMatchers); + constructor(name: string, commandLine: string, options: ShellTaskOptions, problemMatchers?: ProblemMatchers); /** * The task's name @@ -3820,12 +3822,12 @@ declare module 'vscode' { * The shell options used when the shell is executed. Defaults to an * empty object literal. */ - options: ShellOptions; + options: ShellTaskOptions; /** - * The terminal options. Defaults to an empty object literal. + * The terminal behavior. Defaults to an empty object literal. */ - terminal: TerminalBehaviour; + terminal: TaskTerminalBehavior; /** * The problem matchers attached to the task. Defaults to an empty diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index eda65776c32..1ec2c22afa3 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -537,7 +537,7 @@ export function createApiFactory( TreeItemCollapsibleState: extHostTypes.TreeItemCollapsibleState, ThemeColor: extHostTypes.ThemeColor, // functions - RevealKind: extHostTypes.RevealKind, + TaskRevealKind: extHostTypes.TaskRevealKind, TaskGroup: extHostTypes.TaskGroup, ShellTask: extHostTypes.ShellTask, ProcessTask: extHostTypes.ProcessTask diff --git a/src/vs/workbench/api/node/extHostTask.ts b/src/vs/workbench/api/node/extHostTask.ts index 7508d947d45..239aa99dabc 100644 --- a/src/vs/workbench/api/node/extHostTask.ts +++ b/src/vs/workbench/api/node/extHostTask.ts @@ -191,15 +191,15 @@ namespace ProblemMatcher { } */ -namespace RevealKind { - export function from(value: vscode.RevealKind): TaskSystem.RevealKind { +namespace TaskRevealKind { + export function from(value: vscode.TaskRevealKind): TaskSystem.RevealKind { if (value === void 0 || value === null) { return TaskSystem.RevealKind.Always; } switch (value) { - case types.RevealKind.Silent: + case types.TaskRevealKind.Silent: return TaskSystem.RevealKind.Silent; - case types.RevealKind.Never: + case types.TaskRevealKind.Never: return TaskSystem.RevealKind.Never; } return TaskSystem.RevealKind.Always; @@ -207,11 +207,11 @@ namespace RevealKind { } namespace TerminalBehaviour { - export function from(value: vscode.TerminalBehaviour): TaskSystem.TerminalBehavior { + export function from(value: vscode.TaskTerminalBehavior): TaskSystem.TerminalBehavior { if (value === void 0 || value === null) { return { reveal: TaskSystem.RevealKind.Always, echo: false }; } - return { reveal: RevealKind.from(value.reveal), echo: !!value.echo }; + return { reveal: TaskRevealKind.from(value.reveal), echo: !!value.echo }; } } @@ -230,10 +230,10 @@ namespace Strings { } namespace CommandOptions { - function isShellOptions(value: any): value is vscode.ShellOptions { + function isShellOptions(value: any): value is vscode.ShellTaskOptions { return value && typeof value.executable === 'string'; } - export function from(value: vscode.ShellOptions | vscode.ProcessOptions): TaskSystem.CommandOptions { + export function from(value: vscode.ShellTaskOptions | vscode.ProcessTaskOptions): TaskSystem.CommandOptions { if (value === void 0 || value === null) { return undefined; } diff --git a/src/vs/workbench/api/node/extHostTypes.ts b/src/vs/workbench/api/node/extHostTypes.ts index 353765544fd..7305e672df6 100644 --- a/src/vs/workbench/api/node/extHostTypes.ts +++ b/src/vs/workbench/api/node/extHostTypes.ts @@ -1029,7 +1029,7 @@ export enum ApplyToKind { ClosedDocuments = 3 } -export enum RevealKind { +export enum TaskRevealKind { Always = 1, Silent = 2, @@ -1045,7 +1045,7 @@ export class BaseTask { private _isBackground: boolean; private _source: string; private _group: string; - private _terminal: vscode.TerminalBehaviour; + private _terminal: vscode.TaskTerminalBehavior; constructor(name: string, problemMatchers: string[]) { if (typeof name !== 'string') { @@ -1116,11 +1116,11 @@ export class BaseTask { this._group = value; } - get terminal(): vscode.TerminalBehaviour { + get terminal(): vscode.TaskTerminalBehavior { return this._terminal; } - set terminal(value: vscode.TerminalBehaviour) { + set terminal(value: vscode.TaskTerminalBehavior) { if (value === void 0 || value === null) { value = Object.create(null); } @@ -1149,7 +1149,7 @@ namespace ProblemMatcher { */ namespace ShellOptions { - export function is(value: any): value is vscode.ShellOptions { + export function is(value: any): value is vscode.ShellTaskOptions { return value && ((typeof value.executable === 'string') || (typeof value.cwd === 'string') || !!value.env); } } @@ -1184,16 +1184,16 @@ export class ProcessTask extends BaseTask { private _process: string; private _args: string[]; - private _options: vscode.ProcessOptions; + private _options: vscode.ProcessTaskOptions; constructor(name: string, process: string, args?: string[], problemMatchers?: vscode.ProblemMatchers); - constructor(name: string, process: string, args: string[] | undefined, options: vscode.ProcessOptions, problemMatchers?: vscode.ProblemMatchers); - constructor(name: string, process: string, arg3?: string[], arg4?: vscode.ProcessOptions | vscode.ProblemMatchers, arg5?: vscode.ProblemMatchers) { + constructor(name: string, process: string, args: string[] | undefined, options: vscode.ProcessTaskOptions, problemMatchers?: vscode.ProblemMatchers); + constructor(name: string, process: string, arg3?: string[], arg4?: vscode.ProcessTaskOptions | vscode.ProblemMatchers, arg5?: vscode.ProblemMatchers) { if (typeof process !== 'string') { throw illegalArgument('process'); } let args: string[]; - let options: vscode.ProcessOptions; + let options: vscode.ProcessTaskOptions; let problemMatchers: vscode.ProblemMatchers; args = arg3 || []; @@ -1235,11 +1235,11 @@ export class ProcessTask extends BaseTask { this._args = value; } - get options(): vscode.ProcessOptions { + get options(): vscode.ProcessTaskOptions { return this._options; } - set options(value: vscode.ProcessOptions) { + set options(value: vscode.ProcessTaskOptions) { if (value === void 0 || value === null) { value = Object.create(null); } @@ -1250,15 +1250,15 @@ export class ProcessTask extends BaseTask { export class ShellTask extends BaseTask implements vscode.ShellTask { private _commandLine: string; - private _options: vscode.ShellOptions; + private _options: vscode.ShellTaskOptions; constructor(name: string, commandLine: string, problemMatchers?: vscode.ProblemMatchers); - constructor(name: string, commandLine: string, options: vscode.ShellOptions, problemMatchers?: vscode.ProblemMatchers); - constructor(name: string, commandLine: string, optionsOrProblemMatchers?: vscode.ShellOptions | vscode.ProblemMatchers, problemMatchers?: vscode.ProblemMatchers) { + constructor(name: string, commandLine: string, options: vscode.ShellTaskOptions, problemMatchers?: vscode.ProblemMatchers); + constructor(name: string, commandLine: string, optionsOrProblemMatchers?: vscode.ShellTaskOptions | vscode.ProblemMatchers, problemMatchers?: vscode.ProblemMatchers) { if (typeof commandLine !== 'string') { throw illegalArgument('commandLine'); } - let options: vscode.ShellOptions = undefined; + let options: vscode.ShellTaskOptions = undefined; let pm: string[]; if (ShellOptions.is(optionsOrProblemMatchers)) { options = optionsOrProblemMatchers; @@ -1280,11 +1280,11 @@ export class ShellTask extends BaseTask implements vscode.ShellTask { return this._commandLine; } - get options(): vscode.ShellOptions { + get options(): vscode.ShellTaskOptions { return this._options; } - set options(value: vscode.ShellOptions) { + set options(value: vscode.ShellTaskOptions) { if (value === void 0 || value === null) { value = Object.create(null); } -- GitLab From 4bb81e3099a0dbf1f69d3f729d340e90dfb184c4 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Tue, 30 May 2017 22:03:57 +0200 Subject: [PATCH 0302/1347] Fixes #27348: Task should not be drop if identifier is undefined --- src/vs/workbench/api/node/extHostTask.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/api/node/extHostTask.ts b/src/vs/workbench/api/node/extHostTask.ts index 239aa99dabc..2306007194c 100644 --- a/src/vs/workbench/api/node/extHostTask.ts +++ b/src/vs/workbench/api/node/extHostTask.ts @@ -294,7 +294,7 @@ namespace Tasks { } function fromSingle(task: vscode.Task, extension: IExtensionDescription, uuidMap: UUIDMap): TaskSystem.Task { - if (typeof task.name !== 'string' || typeof task.identifier !== 'string') { + if (typeof task.name !== 'string') { return undefined; } let command: TaskSystem.CommandConfiguration; -- GitLab From cc6fb7c73452e4e4c405bbeee69dad8c9a950b41 Mon Sep 17 00:00:00 2001 From: cleidigh Date: Tue, 30 May 2017 16:24:56 -0400 Subject: [PATCH 0303/1347] Fix current output drop-down selected --- src/vs/workbench/parts/output/browser/outputActions.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/output/browser/outputActions.ts b/src/vs/workbench/parts/output/browser/outputActions.ts index b7e0927a94b..f083d763cbc 100644 --- a/src/vs/workbench/parts/output/browser/outputActions.ts +++ b/src/vs/workbench/parts/output/browser/outputActions.ts @@ -112,7 +112,10 @@ export class SwitchOutputActionItem extends SelectActionItem { ) { super(null, action, [], 0); - this.toDispose.push(this.outputService.onOutputChannel(() => this.setOptions(this.getOptions(), this.getSelected(undefined)))); + this.toDispose.push(this.outputService.onOutputChannel(() => { + const activeChannelIndex = this.getSelected(this.outputService.getActiveChannel().id); + this.setOptions(this.getOptions(), activeChannelIndex); + })); this.toDispose.push(this.outputService.onActiveOutputChannel(activeChannelId => this.setOptions(this.getOptions(), this.getSelected(activeChannelId)))); this.toDispose.push(attachSelectBoxStyler(this.selectBox, themeService)); -- GitLab From a1fd514fa6c7c5ae6218bd40e6e7a519f3053655 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Tue, 30 May 2017 22:39:34 +0200 Subject: [PATCH 0304/1347] Fixes #27589: Inconsistent use of ProblemMatcher --- src/vs/vscode.d.ts | 35 +++++++++++++---------- src/vs/workbench/api/node/extHostTypes.ts | 14 ++++----- 2 files changed, 27 insertions(+), 22 deletions(-) diff --git a/src/vs/vscode.d.ts b/src/vs/vscode.d.ts index d7cffd9896a..82c239860cd 100644 --- a/src/vs/vscode.d.ts +++ b/src/vs/vscode.d.ts @@ -3610,11 +3610,6 @@ declare module 'vscode' { export const Test: 'test'; } - /** - * The ProblemMatchers type definition. - */ - export type ProblemMatchers = string | string[]; - /** * A task that starts an external process. */ @@ -3625,9 +3620,11 @@ declare module 'vscode' { * * @param name the task's name. Is presented in the user interface. * @param process the process to start. - * @param problemMatchers the problem matchers to use. + * @param problemMatchers the names of problem matchers to use, like '$tsc' + * or '$eslint'. Problem matchers can be contributed by an extension using + * the `problemMatchers` extension point. */ - constructor(name: string, process: string, problemMatchers?: ProblemMatchers); + constructor(name: string, process: string, problemMatchers?: string | string[]); /** * Creates a process task. @@ -3635,9 +3632,11 @@ declare module 'vscode' { * @param name the task's name. Is presented in the user interface. * @param process the process to start. * @param args arguments to be passed to the process. - * @param problemMatchers the problem matchers to use. + * @param problemMatchers the names of problem matchers to use, like '$tsc' + * or '$eslint'. Problem matchers can be contributed by an extension using + * the `problemMatchers` extension point. */ - constructor(name: string, process: string, args: string[], problemMatchers?: ProblemMatchers); + constructor(name: string, process: string, args: string[], problemMatchers?: string | string[]); /** * Creates a process task. @@ -3646,9 +3645,11 @@ declare module 'vscode' { * @param process the process to start. * @param args arguments to be passed to the process. * @param options additional options for the started process. - * @param problemMatchers the problem matchers to use. + * @param problemMatchers the names of problem matchers to use, like '$tsc' + * or '$eslint'. Problem matchers can be contributed by an extension using + * the `problemMatchers` extension point. */ - constructor(name: string, process: string, args: string[], options: ProcessTaskOptions, problemMatchers?: ProblemMatchers); + constructor(name: string, process: string, args: string[], options: ProcessTaskOptions, problemMatchers?: string | string[]); /** * The task's name @@ -3769,9 +3770,11 @@ declare module 'vscode' { * * @param name the task's name. Is presented in the user interface. * @param commandLine the command line to execute. - * @param problemMatchers the problem matchers to use. + * @param problemMatchers the names of problem matchers to use, like '$tsc' + * or '$eslint'. Problem matchers can be contributed by an extension using + * the `problemMatchers` extension point. */ - constructor(name: string, commandLine: string, problemMatchers?: ProblemMatchers); + constructor(name: string, commandLine: string, problemMatchers?: string | string[]); /** * Creates a shell task. @@ -3779,9 +3782,11 @@ declare module 'vscode' { * @param name the task's name. Is presented in the user interface. * @param commandLine the command line to execute. * @param options additional options used when creating the shell. - * @param problemMatchers the problem matchers to use. + * @param problemMatchers the names of problem matchers to use, like '$tsc' + * or '$eslint'. Problem matchers can be contributed by an extension using + * the `problemMatchers` extension point. */ - constructor(name: string, commandLine: string, options: ShellTaskOptions, problemMatchers?: ProblemMatchers); + constructor(name: string, commandLine: string, options: ShellTaskOptions, problemMatchers?: string | string[]); /** * The task's name diff --git a/src/vs/workbench/api/node/extHostTypes.ts b/src/vs/workbench/api/node/extHostTypes.ts index 7305e672df6..ef7f35e2a7e 100644 --- a/src/vs/workbench/api/node/extHostTypes.ts +++ b/src/vs/workbench/api/node/extHostTypes.ts @@ -1186,15 +1186,15 @@ export class ProcessTask extends BaseTask { private _args: string[]; private _options: vscode.ProcessTaskOptions; - constructor(name: string, process: string, args?: string[], problemMatchers?: vscode.ProblemMatchers); - constructor(name: string, process: string, args: string[] | undefined, options: vscode.ProcessTaskOptions, problemMatchers?: vscode.ProblemMatchers); - constructor(name: string, process: string, arg3?: string[], arg4?: vscode.ProcessTaskOptions | vscode.ProblemMatchers, arg5?: vscode.ProblemMatchers) { + constructor(name: string, process: string, args?: string[], problemMatchers?: string | string[]); + constructor(name: string, process: string, args: string[] | undefined, options: vscode.ProcessTaskOptions, problemMatchers?: string | string[]); + constructor(name: string, process: string, arg3?: string[], arg4?: vscode.ProcessTaskOptions | string | string[], arg5?: string | string[]) { if (typeof process !== 'string') { throw illegalArgument('process'); } let args: string[]; let options: vscode.ProcessTaskOptions; - let problemMatchers: vscode.ProblemMatchers; + let problemMatchers: string | string[]; args = arg3 || []; if (arg4) { @@ -1252,9 +1252,9 @@ export class ShellTask extends BaseTask implements vscode.ShellTask { private _commandLine: string; private _options: vscode.ShellTaskOptions; - constructor(name: string, commandLine: string, problemMatchers?: vscode.ProblemMatchers); - constructor(name: string, commandLine: string, options: vscode.ShellTaskOptions, problemMatchers?: vscode.ProblemMatchers); - constructor(name: string, commandLine: string, optionsOrProblemMatchers?: vscode.ShellTaskOptions | vscode.ProblemMatchers, problemMatchers?: vscode.ProblemMatchers) { + constructor(name: string, commandLine: string, problemMatchers?: string | string[]); + constructor(name: string, commandLine: string, options: vscode.ShellTaskOptions, problemMatchers?: string | string[]); + constructor(name: string, commandLine: string, optionsOrProblemMatchers?: vscode.ShellTaskOptions | string | string[], problemMatchers?: string | string[]) { if (typeof commandLine !== 'string') { throw illegalArgument('commandLine'); } -- GitLab From b0047344d6eef91dbf8fee72c7a9649d504c6f12 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Tue, 30 May 2017 14:01:56 -0700 Subject: [PATCH 0305/1347] Fix some issues with dnd to the terminal - \, quote chars and space are now escaped. - Paths from the file system are now properly passed through URI, causing \ to be pasted in correctly. Fixes #27511 --- .../electron-browser/terminalPanel.ts | 33 ++++++++++++------- 1 file changed, 22 insertions(+), 11 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts index 78364b99abf..a1a746a7bd2 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts @@ -216,18 +216,19 @@ export class TerminalPanel extends Panel { } // Check if the file was dragged from the tree explorer - const url = e.dataTransfer.getData('URL'); - let filePath = URI.parse(url).path; - - // Check if the file was dragged from the filesystem - if (!filePath && e.dataTransfer.files.length > 0) { - filePath = e.dataTransfer.files[0].path; + let url = e.dataTransfer.getData('URL'); + if (!url && e.dataTransfer.files.length > 0) { + // Check if the file was dragged from the filesystem + url = e.dataTransfer.files[0].path; } - if (filePath) { - const terminal = this._terminalService.getActiveInstance(); - terminal.sendText(this._wrapPathInQuotes(filePath), false); + const filePath = URI.parse(url).path; + if (!filePath) { + return; } + + const terminal = this._terminalService.getActiveInstance(); + terminal.sendText(this._wrapPathInQuotes(filePath), false); } })); } @@ -292,9 +293,19 @@ export class TerminalPanel extends Panel { * Adds quotes to a path if it contains whitespaces */ private _wrapPathInQuotes(path: string) { - if (/\s+/.test(path)) { - return `"${path}"`; + if (platform.isWindows) { + if (/\s+/.test(path)) { + return `"${path}"`; + } + return path; } + const charsToReplace: { a: string, b: string }[] = [ + { a: '\\', b: '\\\\' }, + { a: ' ', b: '\\ ' }, + { a: '\'', b: '\\\'' }, + { a: '"', b: '\\"' } + ]; + charsToReplace.forEach(chars => path = path.replace(chars.a, chars.b)); return path; } } -- GitLab From 1e54bb2bea94d756e8d88d136c4b66cce979aa57 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Tue, 30 May 2017 14:12:03 -0700 Subject: [PATCH 0306/1347] Fixes #27452 Set version, commit in extra bag from the start --- .../electron-browser/crashReporterService.ts | 27 ++++++++----------- 1 file changed, 11 insertions(+), 16 deletions(-) diff --git a/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts b/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts index 0acfd1793ac..792a8672297 100644 --- a/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts +++ b/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts @@ -35,23 +35,23 @@ export class CrashReporterService implements ICrashReporterService { private startCrashReporter(): void { - // base options + // base options with product info this.options = { companyName: product.crashReporter.companyName, productName: product.crashReporter.productName, - submitURL: this.getSubmitURL() + submitURL: this.getSubmitURL(), + extra: { + vscode_version: pkg.version, + vscode_commit: product.commit + } }; - // mixin telemetry info and product info + // mixin telemetry info this.telemetryService.getTelemetryInfo() .then(info => { - assign(this.options, { - extra: { - vscode_sessionId: info.sessionId, - vscode_version: pkg.version, - vscode_commit: product.commit, - vscode_machineId: info.machineId - } + assign(this.options.extra, { + vscode_sessionId: info.sessionId, + vscode_machineId: info.machineId }); // start crash reporter right here @@ -81,12 +81,7 @@ export class CrashReporterService implements ICrashReporterService { // Experimental attempt on Mac only for now if (isMacintosh) { const childProcessOptions = clone(this.options); - if (childProcessOptions.extra) { - childProcessOptions.extra.processName = name; - } else { - childProcessOptions.extra = { processName: name }; - } - + childProcessOptions.extra.processName = name; childProcessOptions.crashesDirectory = os.tmpdir(); return childProcessOptions; } -- GitLab From 85df66dcd6363d232975ac5abaf3c30b8383840f Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Tue, 30 May 2017 14:30:11 -0700 Subject: [PATCH 0307/1347] Style the terminal press any key text Fixes #27398 --- .../parts/terminal/electron-browser/terminalInstance.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index 3b320363826..b236832add4 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -532,6 +532,8 @@ export class TerminalInstance implements ITerminalInstance { let message = typeof this._shellLaunchConfig.waitOnExit === 'string' ? this._shellLaunchConfig.waitOnExit : nls.localize('terminal.integrated.waitOnExit', 'Press any key to close the terminal'); + // Style the message to make it stand out from the rest of the output + message = `\n\x1b[40;37;1m${message}\x1b[0m`; this._xterm.writeln(message); // Disable all input if the terminal is exiting and listen for next keypress this._xterm.setOption('disableStdin', true); -- GitLab From c58feb3fa53b04ef21a349e83d3bf334f5094ac6 Mon Sep 17 00:00:00 2001 From: Dustin Campbell Date: Tue, 30 May 2017 14:59:32 -0700 Subject: [PATCH 0308/1347] Update to latest C# TextMate grammar --- .../csharp/syntaxes/csharp.tmLanguage.json | 90 +++++++++++++------ 1 file changed, 62 insertions(+), 28 deletions(-) diff --git a/extensions/csharp/syntaxes/csharp.tmLanguage.json b/extensions/csharp/syntaxes/csharp.tmLanguage.json index 3f81563c5bb..010852c16e7 100644 --- a/extensions/csharp/syntaxes/csharp.tmLanguage.json +++ b/extensions/csharp/syntaxes/csharp.tmLanguage.json @@ -4,6 +4,7 @@ "If you want to provide a fix or improvement, please create a pull request against the original repository.", "Once accepted there, we are happy to receive an update request." ], + "version": "https://github.com/dotnet/csharp-tmLanguage/commit/9ef19ad34df99e0e5bf3e0a8e8a1733d1f0c4aca", "name": "C#", "scopeName": "source.cs", "fileTypes": [ @@ -314,10 +315,10 @@ "include": "#anonymous-object-creation-expression" }, { - "include": "#member-access-expression" + "include": "#invocation-expression" }, { - "include": "#invocation-expression" + "include": "#member-access-expression" }, { "include": "#element-access-expression" @@ -613,7 +614,7 @@ ] }, "delegate-declaration": { - "begin": "(?x)\n(?:\\b(delegate)\\b)\\s+\n(?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n)\\s+\n(\\g)\\s*\n(<([^<>]+)>)?\\s*\n(?=\\()", + "begin": "(?x)\n(?:\\b(delegate)\\b)\\s+\n(?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)\\s+\n(\\g)\\s*\n(<([^<>]+)>)?\\s*\n(?=\\()", "beginCaptures": { "1": { "name": "keyword.other.delegate.cs" @@ -964,7 +965,7 @@ ] }, "field-declaration": { - "begin": "(?x)\n(?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n)\\s+\n(\\g)\\s* # first field name\n(?!=>|==)(?=,|;|=|$)", + "begin": "(?x)\n(?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)\\s+\n(\\g)\\s* # first field name\n(?!=>|==)(?=,|;|=|$)", "beginCaptures": { "1": { "patterns": [ @@ -998,7 +999,7 @@ ] }, "property-declaration": { - "begin": "(?x)\n(?!.*\\b(?:class|interface|struct|enum|event)\\b)\\s*\n(?\n (?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\\s+\n)\n(?\\g\\s*\\.\\s*)?\n(?\\g)\\s*\n(?=\\{|=>|$)", + "begin": "(?x)\n(?!.*\\b(?:class|interface|struct|enum|event)\\b)\\s*\n(?\n (?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n )\\s+\n)\n(?\\g\\s*\\.\\s*)?\n(?\\g)\\s*\n(?=\\{|=>|$)", "beginCaptures": { "1": { "patterns": [ @@ -1041,7 +1042,7 @@ ] }, "indexer-declaration": { - "begin": "(?x)\n(?\n (?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\\s+\n)\n(?\\g\\s*\\.\\s*)?\n(?this)\\s*\n(?=\\[)", + "begin": "(?x)\n(?\n (?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n )\\s+\n)\n(?\\g\\s*\\.\\s*)?\n(?this)\\s*\n(?=\\[)", "beginCaptures": { "1": { "patterns": [ @@ -1084,7 +1085,7 @@ ] }, "event-declaration": { - "begin": "(?x)\n\\b(event)\\b\\s*\n(?\n (?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\\s+\n)\n(?\\g\\s*\\.\\s*)?\n(?\\g(?:\\s*,\\s*\\g)*)\\s*\n(?=\\{|;|$)", + "begin": "(?x)\n\\b(event)\\b\\s*\n(?\n (?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n )\\s+\n)\n(?\\g\\s*\\.\\s*)?\n(?\\g(?:\\s*,\\s*\\g)*)\\s*\n(?=\\{|;|$)", "beginCaptures": { "1": { "name": "keyword.other.event.cs" @@ -1214,7 +1215,7 @@ ] }, "method-declaration": { - "begin": "(?x)\n(?\n (?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\\s+\n)\n(?\\g\\s*\\.\\s*)?\n(\\g)\\s*\n(<([^<>]+)>)?\\s*\n(?=\\()", + "begin": "(?x)\n(?\n (?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n )\\s+\n)\n(?\\g\\s*\\.\\s*)?\n(\\g)\\s*\n(<([^<>]+)>)?\\s*\n(?=\\()", "beginCaptures": { "1": { "patterns": [ @@ -1350,7 +1351,7 @@ ] }, "operator-declaration": { - "begin": "(?x)\n(?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n)\\s*\n(?(?:\\b(?:operator)))\\s*\n(?(?:\\+|-|\\*|/|%|&|\\||\\^|\\<\\<|\\>\\>|==|!=|\\>|\\<|\\>=|\\<=|!|~|\\+\\+|--|true|false))\\s*\n(?=\\()", + "begin": "(?x)\n(?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)\\s*\n(?(?:\\b(?:operator)))\\s*\n(?(?:\\+|-|\\*|/|%|&|\\||\\^|\\<\\<|\\>\\>|==|!=|\\>|\\<|\\>=|\\<=|!|~|\\+\\+|--|true|false))\\s*\n(?=\\()", "beginCaptures": { "1": { "patterns": [ @@ -1383,7 +1384,7 @@ ] }, "conversion-operator-declaration": { - "begin": "(?x)\n(?(?:\\b(?:explicit|implicit)))\\s*\n(?(?:\\b(?:operator)))\\s*\n(?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n)\\s*\n(?=\\()", + "begin": "(?x)\n(?(?:\\b(?:explicit|implicit)))\\s*\n(?(?:\\b(?:operator)))\\s*\n(?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)\\s*\n(?=\\()", "beginCaptures": { "1": { "patterns": [ @@ -1839,7 +1840,7 @@ }, "patterns": [ { - "match": "(?x)\n(?:\n (\\bvar\\b)|\n (?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n)\\s+\n(\\g)\\s+\n\\b(in)\\b", + "match": "(?x)\n(?:\n (\\bvar\\b)|\n (?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n )\n)\\s+\n(\\g)\\s+\n\\b(in)\\b", "captures": { "1": { "name": "keyword.other.var.cs" @@ -1909,6 +1910,9 @@ }, "end": "(?<=\\})", "patterns": [ + { + "include": "#comment" + }, { "include": "#block" } @@ -1923,6 +1927,9 @@ }, "end": "(?<=\\})", "patterns": [ + { + "include": "#comment" + }, { "include": "#block" } @@ -1952,7 +1959,7 @@ }, "patterns": [ { - "match": "(?x)\n(?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n)\\s*\n(?:\\b(\\g)\\b)?", + "match": "(?x)\n(?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)\\s*\n(?:\\b(\\g)\\b)?", "captures": { "1": { "patterns": [ @@ -1971,6 +1978,9 @@ { "include": "#when-clause" }, + { + "include": "#comment" + }, { "include": "#block" } @@ -1995,6 +2005,9 @@ "patterns": [ { "include": "#expression" + }, + { + "include": "#comment" } ] }, @@ -2109,7 +2122,7 @@ ] }, "local-variable-declaration": { - "begin": "(?x)\n(?:\n (\\bvar\\b)|\n (?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n)\\s+\n(\\g)\\s*\n(?=,|;|=|\\))", + "begin": "(?x)\n(?:\n (\\bvar\\b)|\n (?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n )\n)\\s+\n(\\g)\\s*\n(?=,|;|=|\\))", "beginCaptures": { "1": { "name": "keyword.other.var.cs" @@ -2143,7 +2156,7 @@ ] }, "local-constant-declaration": { - "begin": "(?x)\n(?\\b(?:const)\\b)\\s*\n(?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n)\\s+\n(\\g)\\s*\n(?=,|;|=)", + "begin": "(?x)\n(?\\b(?:const)\\b)\\s*\n(?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)\\s+\n(\\g)\\s*\n(?=,|;|=)", "beginCaptures": { "1": { "name": "storage.modifier.cs" @@ -2233,7 +2246,7 @@ "include": "#tuple-declaration-deconstruction-element-list" }, { - "include": "#declaration-expression" + "include": "#declaration-expression-tuple" }, { "include": "#punctuation-comma" @@ -2269,7 +2282,7 @@ "include": "#tuple-deconstruction-element-list" }, { - "include": "#declaration-expression" + "include": "#declaration-expression-tuple" }, { "include": "#punctuation-comma" @@ -2284,8 +2297,26 @@ } ] }, - "declaration-expression": { - "match": "(?x) # e.g. int x OR var x\n(?:\n \\b(var)\\b|\n (?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n)\\s+\n\\b(\\g)\\b\\s*\n(?=[,)])", + "declaration-expression-local": { + "match": "(?x) # e.g. int x OR var x\n(?:\n \\b(var)\\b|\n (?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n )\n)\\s+\n\\b(\\g)\\b\\s*\n(?=[,)\\]])", + "captures": { + "1": { + "name": "keyword.other.var.cs" + }, + "2": { + "patterns": [ + { + "include": "#type" + } + ] + }, + "7": { + "name": "entity.name.variable.local.cs" + } + } + }, + "declaration-expression-tuple": { + "match": "(?x) # e.g. int x OR var x\n(?:\n \\b(var)\\b|\n (?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n )\n)\\s+\n\\b(\\g)\\b\\s*\n(?=[,)])", "captures": { "1": { "name": "keyword.other.var.cs" @@ -2752,7 +2783,7 @@ "match": "[_[:alpha:]][_[:alnum:]]*" }, "cast-expression": { - "match": "(?x)\n(\\()\\s*\n(?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n)\\s*\n(\\))(?=\\s*[_[:alnum:]\\(])", + "match": "(?x)\n(\\()\\s*\n(?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)\\s*\n(\\))(?=\\s*[_[:alnum:]\\(])", "captures": { "1": { "name": "punctuation.parenthesis.open.cs" @@ -2770,7 +2801,7 @@ } }, "as-expression": { - "match": "(?x)\n(?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n)?", + "match": "(?x)\n(?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)?", "captures": { "1": { "name": "keyword.other.as.cs" @@ -2785,7 +2816,7 @@ } }, "is-expression": { - "match": "(?x)\n(?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n)?", + "match": "(?x)\n(?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)?", "captures": { "1": { "name": "keyword.other.is.cs" @@ -2915,7 +2946,7 @@ ] }, "object-creation-expression-with-parameters": { - "begin": "(?x)\n(new)\\s+\n(?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n)\\s*\n(?=\\()", + "begin": "(?x)\n(new)\\s+\n(?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)\\s*\n(?=\\()", "beginCaptures": { "1": { "name": "keyword.other.new.cs" @@ -2936,7 +2967,7 @@ ] }, "object-creation-expression-with-no-parameters": { - "match": "(?x)\n(new)\\s+\n(?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n)\\s*\n(?=\\{|$)", + "match": "(?x)\n(new)\\s+\n(?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)\\s*\n(?=\\{|$)", "captures": { "1": { "name": "keyword.other.new.cs" @@ -2951,7 +2982,7 @@ } }, "array-creation-expression": { - "begin": "(?x)\n\\b(new)\\b\\s*\n(?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n)?\\s*\n(?=\\[)", + "begin": "(?x)\n\\b(new)\\b\\s*\n(?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)?\\s*\n(?=\\[)", "beginCaptures": { "1": { "name": "keyword.other.new.cs" @@ -3150,13 +3181,16 @@ "name": "storage.modifier.cs", "match": "\\b(ref|out)\\b" }, + { + "include": "#declaration-expression-local" + }, { "include": "#expression" } ] }, "query-expression": { - "begin": "(?x)\n\\b(from)\\b\\s*\n(?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n)?\n\\b(\\g)\\b\\s*\n\\b(in)\\b\\s*", + "begin": "(?x)\n\\b(from)\\b\\s*\n(?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)?\n\\b(\\g)\\b\\s*\n\\b(in)\\b\\s*", "beginCaptures": { "1": { "name": "keyword.query.from.cs" @@ -3248,7 +3282,7 @@ ] }, "join-clause": { - "begin": "(?x)\n\\b(join)\\b\\s*\n(?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n)?\n\\b(\\g)\\b\\s*\n\\b(in)\\b\\s*", + "begin": "(?x)\n\\b(join)\\b\\s*\n(?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)?\n\\b(\\g)\\b\\s*\n\\b(in)\\b\\s*", "beginCaptures": { "1": { "name": "keyword.query.join.cs" @@ -3512,7 +3546,7 @@ ] }, "lambda-parameter": { - "match": "(?x)\n(ref|out)?\\s*\n(?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n)?\n\\b(\\g)\\b\\s*\n(?=[,)])", + "match": "(?x)\n(ref|out)?\\s*\n(?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)?\n\\b(\\g)\\b\\s*\n(?=[,)])", "captures": { "1": { "name": "storage.modifier.cs" @@ -3578,7 +3612,7 @@ ] }, "tuple-element": { - "match": "(?x)\n(?\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* # Are there any more names being dotted into?\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )|\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n)\n(?:\\b(?\\g)\\b)?", + "match": "(?x)\n(?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)\n(?:\\b(?\\g)\\b)?", "captures": { "1": { "patterns": [ -- GitLab From 60a3e8efd1b3c9b3465f2734f019af03cba4a533 Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Tue, 30 May 2017 15:26:28 -0700 Subject: [PATCH 0309/1347] Revert "Improve issue template" This reverts commit 85a56e643b0b126a4bd42b5b438e0dfb984e665e. --- issue_template.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/issue_template.md b/issue_template.md index ad023f7b7c8..81a8470fc44 100644 --- a/issue_template.md +++ b/issue_template.md @@ -6,4 +6,4 @@ Steps to Reproduce: 1. -1. +2. -- GitLab From e8923e9dccc2573aaa02f3b6d2757656356fa785 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Tue, 30 May 2017 15:09:46 -0700 Subject: [PATCH 0310/1347] Pick up ts 2.3.4 --- extensions/npm-shrinkwrap.json | 6 +++--- extensions/package.json | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/extensions/npm-shrinkwrap.json b/extensions/npm-shrinkwrap.json index 42a40f5d35f..c7036103d67 100644 --- a/extensions/npm-shrinkwrap.json +++ b/extensions/npm-shrinkwrap.json @@ -3,9 +3,9 @@ "version": "0.0.1", "dependencies": { "typescript": { - "version": "2.3.3,", - "from": "typescript@typescript@2.3.3", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-2.3.3.tgz" + "version": "2.3.4,", + "from": "typescript@typescript@2.3.4", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-2.3.4.tgz" } } } diff --git a/extensions/package.json b/extensions/package.json index ea392e28559..18e2c7dafbc 100644 --- a/extensions/package.json +++ b/extensions/package.json @@ -3,7 +3,7 @@ "version": "0.0.1", "description": "Dependencies shared by all extensions", "dependencies": { - "typescript": "typescript@2.3.3" + "typescript": "typescript@2.3.4" }, "scripts": { "postinstall": "node ./postinstall" -- GitLab From 3f2ed7f43566022b2c4d2ec6d39ff39fdc5b7601 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Tue, 30 May 2017 15:54:31 -0700 Subject: [PATCH 0311/1347] Use existing colors (#27497) --- .../page/electron-browser/welcomePage.ts | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) diff --git a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts index 86dde1dd27d..6141d64d0bb 100644 --- a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts +++ b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts @@ -35,7 +35,7 @@ import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { tildify } from 'vs/base/common/labels'; import { isLinux } from 'vs/base/common/platform'; import { IThemeService, registerThemingParticipant } from 'vs/platform/theme/common/themeService'; -import { registerColor, textLinkForeground, foreground, contrastBorder, activeContrastBorder } from 'vs/platform/theme/common/colorRegistry'; +import { registerColor, textLinkForeground, foreground, descriptionForeground, contrastBorder, activeContrastBorder } from 'vs/platform/theme/common/colorRegistry'; import { getExtraColor } from 'vs/workbench/parts/welcome/walkThrough/node/walkThroughUtils'; used(); @@ -447,20 +447,17 @@ class WelcomePage { // theming -const caption = registerColor('welcomePage.caption', { dark: '#FFFFFFC2', light: '#000000D4', hc: foreground }, localize('welcomePage.caption', 'Caption color on the Welcome page.')); -const detail = registerColor('welcomePage.detail', { dark: '#FFFFFF76', light: '#00000088', hc: foreground }, localize('welcomePage.detail', 'Detail color on the Welcome page.')); - const quickLinkBackground = registerColor('welcomePage.quickLinkBackground', { dark: null, light: null, hc: null }, localize('welcomePage.quickLinkBackground', 'Background color for the quick links on the Welcome page.')); const quickLinkHoverBackground = registerColor('welcomePage.quickLinkHoverBackground', { dark: null, light: null, hc: null }, localize('welcomePage.quickLinkHoverBackground', 'Hover background color for the quick links on the Welcome page.')); registerThemingParticipant((theme, collector) => { - const captionColor = theme.getColor(caption); - if (captionColor) { - collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .caption { color: ${captionColor}; }`); + const foregroundColor = theme.getColor(foreground); + if (foregroundColor) { + collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .caption { color: ${foregroundColor}; }`); } - const detailColor = theme.getColor(detail); - if (detailColor) { - collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .detail { color: ${detailColor}; }`); + const descriptionColor = theme.getColor(descriptionForeground); + if (descriptionColor) { + collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .detail { color: ${descriptionColor}; }`); } const color = getExtraColor(theme, quickLinkBackground, { dark: 'rgba(0, 0, 0, .2)', extra_dark: 'rgba(200, 235, 255, .042)', light: 'rgba(0,0,0,.04)', hc: 'black' }); if (color) { -- GitLab From 91c7fbe2421e679c69a4ce8c58711635a888f905 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Tue, 30 May 2017 16:36:03 -0700 Subject: [PATCH 0312/1347] Add npm location setting For #24961 Picks up https://github.com/Microsoft/TypeScript/pull/16084/files Allows users to manually set the npm install location --- extensions/typescript/package.json | 8 ++++++++ extensions/typescript/package.nls.json | 1 + extensions/typescript/src/typescriptService.ts | 4 ++++ extensions/typescript/src/typescriptServiceClient.ts | 12 +++++++++++- 4 files changed, 24 insertions(+), 1 deletion(-) diff --git a/extensions/typescript/package.json b/extensions/typescript/package.json index 11b75cfc26b..27869655d20 100644 --- a/extensions/typescript/package.json +++ b/extensions/typescript/package.json @@ -103,6 +103,14 @@ "default": true, "description": "%typescript.check.tscVersion%" }, + "typescript.npm": { + "type": [ + "string", + "null" + ], + "default": null, + "description": "%typescript.npm%" + }, "typescript.check.npmIsInstalled": { "type": "boolean", "default": true, diff --git a/extensions/typescript/package.nls.json b/extensions/typescript/package.nls.json index 0679841532d..6aab169b6fb 100644 --- a/extensions/typescript/package.nls.json +++ b/extensions/typescript/package.nls.json @@ -36,6 +36,7 @@ "typescript.selectTypeScriptVersion.title": "Select TypeScript Version", "jsDocCompletion.enabled": "Enable/disable auto JSDoc comments", "javascript.implicitProjectConfig.checkJs": "Enable/disable semantic checking of JavaScript files. Existing jsconfig.json or tsconfig.json files override this setting. Requires TypeScript >=2.3.1.", + "typescript.npm": "Specifies the path to the NPM install used for automatic typings acquisition. Requires TypeScript >= 2.3.4", "typescript.check.npmIsInstalled": "Check if NPM is installed for automatic typings acquisition", "javascript.nameSuggestions": "Enable/disable including unique names from the file in JavaScript suggestion lists.", "typescript.tsc.autoDetect": "Controls whether auto detection of tsc tasks is on or off." diff --git a/extensions/typescript/src/typescriptService.ts b/extensions/typescript/src/typescriptService.ts index 8b15cc79f7b..dd24447e929 100644 --- a/extensions/typescript/src/typescriptService.ts +++ b/extensions/typescript/src/typescriptService.ts @@ -64,6 +64,10 @@ export class API { public has230Features(): boolean { return semver.gte(this._version, '2.3.0'); } + + public has234Features(): boolean { + return semver.gte(this._version, '2.3.4'); + } } export interface ITypescriptServiceClient { diff --git a/extensions/typescript/src/typescriptServiceClient.ts b/extensions/typescript/src/typescriptServiceClient.ts index 5e22350feb0..d5e718bb34c 100644 --- a/extensions/typescript/src/typescriptServiceClient.ts +++ b/extensions/typescript/src/typescriptServiceClient.ts @@ -110,6 +110,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient private _onReady: { promise: Promise; resolve: () => void; reject: () => void; }; private globalTsdk: string | null; private localTsdk: string | null; + private npmLocation: string | null; private _checkGlobalTSCVersion: boolean; private _experimentalAutoBuild: boolean; private tracer: Tracer; @@ -170,6 +171,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient const configuration = workspace.getConfiguration(); this.globalTsdk = this.extractGlobalTsdk(configuration); this.localTsdk = this.extractLocalTsdk(configuration); + this.npmLocation = configuration.get('typescript.npm', null); this._experimentalAutoBuild = false; // configuration.get('typescript.tsserver.experimentalAutoBuild', false); this._apiVersion = new API('1.0.0'); @@ -183,6 +185,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient let oldglobalTsdk = this.globalTsdk; let oldLocalTsdk = this.localTsdk; let oldCheckJs = this.checkJs; + const oldNpmLocation = this.npmLocation; this.tracer.updateConfiguration(); this.tsServerLogLevel = this.readTsServerLogLevel(); @@ -191,6 +194,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient this.globalTsdk = this.extractGlobalTsdk(configuration); this.localTsdk = this.extractLocalTsdk(configuration); this.checkJs = this.readCheckJs(); + this.npmLocation = configuration.get('typescript.npm', null); if (this.servicePromise && oldCheckJs !== this.checkJs) { this.setCompilerOptionsForInferredProjects(); @@ -198,7 +202,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient if (this.servicePromise === null && (oldglobalTsdk !== this.globalTsdk || oldLocalTsdk !== this.localTsdk)) { this.startService(); - } else if (this.servicePromise !== null && (this.tsServerLogLevel !== oldLoggingLevel || oldglobalTsdk !== this.globalTsdk || oldLocalTsdk !== this.localTsdk)) { + } else if (this.servicePromise !== null && (this.tsServerLogLevel !== oldLoggingLevel || oldglobalTsdk !== this.globalTsdk || oldLocalTsdk !== this.localTsdk || oldNpmLocation !== this.npmLocation)) { this.restartTsServer(); } })); @@ -478,6 +482,12 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient } } + if (this.apiVersion.has234Features()) { + if (this.npmLocation) { + args.push('--npmLocation', `"${this.npmLocation}"`); + } + } + electron.fork(modulePath, args, options, this.logger, (err: any, childProcess: cp.ChildProcess) => { if (err) { this.lastError = err; -- GitLab From 88073e8288d65af77b6f51017e02fdff07649d20 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Tue, 30 May 2017 16:51:15 -0700 Subject: [PATCH 0313/1347] Correctly mark typescript.npm as isExecutable --- extensions/typescript/package.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/extensions/typescript/package.json b/extensions/typescript/package.json index 27869655d20..879cf4ebc01 100644 --- a/extensions/typescript/package.json +++ b/extensions/typescript/package.json @@ -109,7 +109,8 @@ "null" ], "default": null, - "description": "%typescript.npm%" + "description": "%typescript.npm%", + "isExecutable": true }, "typescript.check.npmIsInstalled": { "type": "boolean", -- GitLab From f0cb8bf271b85409ca4ebb3491e84458f465687d Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Tue, 30 May 2017 16:55:03 -0700 Subject: [PATCH 0314/1347] Remove bit about path from npm warning since it may be confusing. Will update documentation --- extensions/typescript/src/utils/typingsStatus.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/typescript/src/utils/typingsStatus.ts b/extensions/typescript/src/utils/typingsStatus.ts index 44f90ec15c1..9bdbd6d1070 100644 --- a/extensions/typescript/src/utils/typingsStatus.ts +++ b/extensions/typescript/src/utils/typingsStatus.ts @@ -106,7 +106,7 @@ export class AtaProgressReporter { window.showWarningMessage( localize( 'typesInstallerInitializationFailed.title', - "Could not install typings files for JavaScript language features. Please ensure that NPM is installed and is in your PATH" + "Could not install typings files for JavaScript language features. Please ensure that NPM is installed" ), { title: localize('typesInstallerInitializationFailed.moreInformation', "More Information"), id: 1 -- GitLab From d4668fce3996fbb784f1fe98926095006349a490 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Tue, 30 May 2017 17:44:30 -0700 Subject: [PATCH 0315/1347] Fixes #27633 and Fixes #27634 --- extensions/emmet/src/editPoint.ts | 4 ++-- .../parts/emmet/electron-browser/actions/editPoints.ts | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/extensions/emmet/src/editPoint.ts b/extensions/emmet/src/editPoint.ts index 757dad1b16a..e7f468f29c7 100644 --- a/extensions/emmet/src/editPoint.ts +++ b/extensions/emmet/src/editPoint.ts @@ -41,13 +41,13 @@ function prevEditPoint(position: vscode.Position, editor: vscode.TextEditor): vs function findEditPoint(lineNum: number, editor: vscode.TextEditor, position: vscode.Position, direction: string): vscode.Selection { let line = editor.document.lineAt(lineNum); + let lineContent = line.text; if (lineNum !== position.line && line.isEmptyOrWhitespace) { - editor.selection = new vscode.Selection(lineNum, 0, lineNum, 0); + editor.selection = new vscode.Selection(lineNum, lineContent.length, lineNum, lineContent.length); return; } - let lineContent = line.text; if (lineNum === position.line && direction === 'prev') { lineContent = lineContent.substr(0, position.character); } diff --git a/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.ts b/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.ts index d74d9e32771..d4d1111fe5c 100644 --- a/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.ts +++ b/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.ts @@ -16,7 +16,7 @@ class PreviousEditPointAction extends BasicEmmetEditorAction { super( 'editor.emmet.action.previousEditPoint', nls.localize('previousEditPoint', "Emmet: Previous Edit Point"), - 'Emmet: Previous Edit Point', + 'Emmet: Go to Previous Edit Point', 'prev_edit_point' ); } @@ -28,7 +28,7 @@ class NextEditPointAction extends BasicEmmetEditorAction { super( 'editor.emmet.action.nextEditPoint', nls.localize('nextEditPoint', "Emmet: Next Edit Point"), - 'Emmet: Next Edit Point', + 'Emmet: Go to Next Edit Point', 'next_edit_point' ); } -- GitLab From 1d93668c0e5e8bf91aa70f92c998bd34d548c2e7 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Tue, 30 May 2017 17:57:46 -0700 Subject: [PATCH 0316/1347] Fixes #27630 --- extensions/emmet/src/toggleComment.ts | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/extensions/emmet/src/toggleComment.ts b/extensions/emmet/src/toggleComment.ts index f87bd831209..17aabeaca44 100644 --- a/extensions/emmet/src/toggleComment.ts +++ b/extensions/emmet/src/toggleComment.ts @@ -60,6 +60,9 @@ export function toggleComment() { function toggleCommentHTML(document: vscode.TextDocument, selection: vscode.Selection, rootNode: Node): [vscode.Range[], vscode.Position, vscode.Position] { let offset = document.offsetAt(selection.start); let nodeToUpdate = getNode(rootNode, offset); + if (!nodeToUpdate) { + return [[], null, null]; + } let rangesToUnComment = getRangesToUnCommentHTML(nodeToUpdate, document); if (nodeToUpdate.type === 'comment') { @@ -101,8 +104,13 @@ function toggleCommentStylesheet(document: vscode.TextDocument, selection: vscod return [rangesToUnComment, null, null]; } + // Find the node that needs to be commented + let nodeToComment = getNode(rootNode, selectionStart, true); + if (!nodeToComment) { + return [[], null, null]; + } + // Uncomment children of current node and then comment the node - let nodeToComment = getNode(rootNode, selectionStart); rangesToUnComment = getRangesToUnCommentStylesheet(rootNode, nodeToComment.start, nodeToComment.end, document, false); let positionForCommentStart = document.positionAt(nodeToComment.start); let positionForCommentEnd = document.positionAt(nodeToComment.end); -- GitLab From 0977276c2b19e38625d30e52cad43a8e4600cc86 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Tue, 30 May 2017 17:58:48 -0700 Subject: [PATCH 0317/1347] Fixes #27623 --- extensions/emmet/src/matchTag.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/emmet/src/matchTag.ts b/extensions/emmet/src/matchTag.ts index e5efc2d8e32..a3e22642226 100644 --- a/extensions/emmet/src/matchTag.ts +++ b/extensions/emmet/src/matchTag.ts @@ -29,7 +29,7 @@ export function matchTag() { } function getUpdatedSelections(editor: vscode.TextEditor, offset: number, rootNode: Node): vscode.Selection { - let currentNode = getNode(rootNode, offset); + let currentNode = getNode(rootNode, offset, true); // If no closing tag or cursor is between open and close tag, then no-op if (!currentNode.close || (currentNode.open.end < offset && currentNode.close.start > offset)) { -- GitLab From 436789a1eb64a1cad70346fe2e155ba5b6c73846 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Tue, 30 May 2017 18:16:10 -0700 Subject: [PATCH 0318/1347] Fixes #27618 --- extensions/emmet/src/extension.ts | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/extensions/emmet/src/extension.ts b/extensions/emmet/src/extension.ts index 15a1bfa4a03..2fb79bdadd3 100644 --- a/extensions/emmet/src/extension.ts +++ b/extensions/emmet/src/extension.ts @@ -22,12 +22,12 @@ interface ISupportedLanguageMode { } const SUPPORTED_LANGUAGE_MODES: ISupportedLanguageMode[] = [ - { id: 'html', triggerCharacters: ['!', '.'] }, - { id: 'jade', triggerCharacters: ['!', '.'] }, - { id: 'slim', triggerCharacters: ['!', '.'] }, - { id: 'haml', triggerCharacters: ['!', '.'] }, - { id: 'xml', triggerCharacters: ['.'] }, - { id: 'xsl', triggerCharacters: ['.'] }, + { id: 'html', triggerCharacters: ['!', '.', '}'] }, + { id: 'jade', triggerCharacters: ['!', '.', '}'] }, + { id: 'slim', triggerCharacters: ['!', '.', '}'] }, + { id: 'haml', triggerCharacters: ['!', '.', '}'] }, + { id: 'xml', triggerCharacters: ['.', '}'] }, + { id: 'xsl', triggerCharacters: ['.', '}'] }, { id: 'css', triggerCharacters: [':'] }, { id: 'scss', triggerCharacters: [':'] }, -- GitLab From 3a6eda74ead5b5b041da0bbc18b70218e8c95bba Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Tue, 30 May 2017 18:21:36 -0700 Subject: [PATCH 0319/1347] Fixes #27609 --- extensions/emmet/src/emmetCompletionProvider.ts | 2 +- .../emmet/electron-browser/actions/expandAbbreviation.ts | 2 +- .../parts/emmet/electron-browser/emmet.contribution.ts | 4 ++-- src/vs/workbench/parts/emmet/electron-browser/emmetActions.ts | 4 ++-- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/extensions/emmet/src/emmetCompletionProvider.ts b/extensions/emmet/src/emmetCompletionProvider.ts index 9fb7bf46af5..8e77e0cec84 100644 --- a/extensions/emmet/src/emmetCompletionProvider.ts +++ b/extensions/emmet/src/emmetCompletionProvider.ts @@ -15,7 +15,7 @@ export class EmmetCompletionItemProvider implements vscode.CompletionItemProvide public provideCompletionItems(document: vscode.TextDocument, position: vscode.Position, token: vscode.CancellationToken): Thenable { - if (!vscode.workspace.getConfiguration('emmet')['useModules']) { + if (!vscode.workspace.getConfiguration('emmet')['useNewEmmet']) { return Promise.resolve(null); } diff --git a/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.ts b/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.ts index 26125b52a0f..05acd8aa045 100644 --- a/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.ts +++ b/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.ts @@ -33,7 +33,7 @@ class ExpandAbbreviationAction extends BasicEmmetEditorAction { EditorContextKeys.hasSingleSelection, EditorContextKeys.tabDoesNotMoveFocus, ContextKeyExpr.has('config.emmet.triggerExpansionOnTab'), - ContextKeyExpr.not('config.emmet.useModules') + ContextKeyExpr.not('config.emmet.useNewEmmet') ) } ); diff --git a/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.ts b/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.ts index 0a177c237f6..e27026f8a0b 100644 --- a/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.ts +++ b/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.ts @@ -60,10 +60,10 @@ configurationRegistry.registerConfiguration({ 'default': null, 'description': nls.localize('emmetExtensionsPath', 'Path to a folder containing emmet profiles, snippets and preferences') }, - 'emmet.useModules': { + 'emmet.useNewEmmet': { 'type': 'boolean', 'default': false, - 'description': nls.localize('emmetUseModules', 'Use the new emmet modules for emmet features than the single emmet library.') + 'description': nls.localize('useNewEmmet', 'Try out the new emmet modules (which will eventually replace the old single emmet library) for all emmet features.') } } }); diff --git a/src/vs/workbench/parts/emmet/electron-browser/emmetActions.ts b/src/vs/workbench/parts/emmet/electron-browser/emmetActions.ts index c2325f2a22f..a313f378b21 100644 --- a/src/vs/workbench/parts/emmet/electron-browser/emmetActions.ts +++ b/src/vs/workbench/parts/emmet/electron-browser/emmetActions.ts @@ -31,7 +31,7 @@ interface IEmmetConfiguration { triggerExpansionOnTab: boolean, excludeLanguages: string[], extensionsPath: string, - useModules: boolean + useNewEmmet: boolean }; } @@ -290,7 +290,7 @@ export abstract class EmmetEditorAction extends EditorAction { const commandService = accessor.get(ICommandService); let mappedCommand = this.actionMap[this.id]; - if (mappedCommand && configurationService.getConfiguration().emmet.useModules) { + if (mappedCommand && configurationService.getConfiguration().emmet.useNewEmmet) { return commandService.executeCommand(mappedCommand); } -- GitLab From f6b27b808b73dbfba232ef1cf34dff956aefd02a Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 31 May 2017 07:41:17 +0200 Subject: [PATCH 0320/1347] theming - guard against missing colors --- .../parts/activitybar/activitybarActions.ts | 29 ++++++------ .../browser/parts/panel/panelPart.ts | 46 +++++++++++-------- .../services/message/browser/messageList.ts | 5 +- 3 files changed, 45 insertions(+), 35 deletions(-) diff --git a/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts b/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts index 08a7aea55c4..ab0ec27b420 100644 --- a/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts +++ b/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts @@ -731,21 +731,22 @@ registerThemingParticipant((theme: ITheme, collector: ICssStyleCollector) => { // Styling without outline color else { const focusBorderColor = theme.getColor(focusBorder); + if (focusBorderColor) { + collector.addRule(` + .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item.active .action-label, + .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item:focus .action-label, + .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item:hover .action-label { + opacity: 1; + } - collector.addRule(` - .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item.active .action-label, - .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item:focus .action-label, - .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item:hover .action-label { - opacity: 1; - } - - .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item .action-label { - opacity: 0.6; - } + .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item .action-label { + opacity: 0.6; + } - .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item:focus:before { - border-left-color: ${focusBorderColor}; - } - `); + .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item:focus:before { + border-left-color: ${focusBorderColor}; + } + `); + } } }); \ No newline at end of file diff --git a/src/vs/workbench/browser/parts/panel/panelPart.ts b/src/vs/workbench/browser/parts/panel/panelPart.ts index 8f535d23acf..1a8f0cf4529 100644 --- a/src/vs/workbench/browser/parts/panel/panelPart.ts +++ b/src/vs/workbench/browser/parts/panel/panelPart.ts @@ -197,32 +197,38 @@ registerThemingParticipant((theme: ITheme, collector: ICssStyleCollector) => { // Title Active const titleActive = theme.getColor(PANEL_ACTIVE_TITLE_FOREGROUND); const titleActiveBorder = theme.getColor(PANEL_ACTIVE_TITLE_BORDER); - collector.addRule(` - .monaco-workbench > .part.panel > .title > .panel-switcher-container > .monaco-action-bar .action-item:hover .action-label, - .monaco-workbench > .part.panel > .title > .panel-switcher-container > .monaco-action-bar .action-item .action-label.checked { - color: ${titleActive}; - border-bottom-color: ${titleActiveBorder}; - } - `); + if (titleActive || titleActiveBorder) { + collector.addRule(` + .monaco-workbench > .part.panel > .title > .panel-switcher-container > .monaco-action-bar .action-item:hover .action-label, + .monaco-workbench > .part.panel > .title > .panel-switcher-container > .monaco-action-bar .action-item .action-label.checked { + color: ${titleActive}; + border-bottom-color: ${titleActiveBorder}; + } + `); + } // Title Inactive const titleInactive = theme.getColor(PANEL_INACTIVE_TITLE_FOREGROUND); - collector.addRule(` - .monaco-workbench > .part.panel > .title > .panel-switcher-container > .monaco-action-bar .action-item .action-label { - color: ${titleInactive}; - } - `); + if (titleInactive) { + collector.addRule(` + .monaco-workbench > .part.panel > .title > .panel-switcher-container > .monaco-action-bar .action-item .action-label { + color: ${titleInactive}; + } + `); + } // Title focus const focusBorderColor = theme.getColor(focusBorder); - collector.addRule(` - .monaco-workbench > .part.panel > .title > .panel-switcher-container > .monaco-action-bar .action-item .action-label:focus { - color: ${titleActive}; - border-bottom-color: ${focusBorderColor} !important; - border-bottom: 1px solid; - outline: none; - } - `); + if (focusBorderColor) { + collector.addRule(` + .monaco-workbench > .part.panel > .title > .panel-switcher-container > .monaco-action-bar .action-item .action-label:focus { + color: ${titleActive}; + border-bottom-color: ${focusBorderColor} !important; + border-bottom: 1px solid; + outline: none; + } + `); + } // Styling with Outline color (e.g. high contrast theme) const outline = theme.getColor(activeContrastBorder); diff --git a/src/vs/workbench/services/message/browser/messageList.ts b/src/vs/workbench/services/message/browser/messageList.ts index 0afb355a590..744b5818055 100644 --- a/src/vs/workbench/services/message/browser/messageList.ts +++ b/src/vs/workbench/services/message/browser/messageList.ts @@ -111,7 +111,10 @@ export class MessageList { this.warningBackground = theme.getColor(inputValidationWarningBorder); this.errorBackground = theme.getColor(inputValidationErrorBorder); - collector.addRule(`.global-message-list li.message-list-entry .actions-container .message-action .action-button:hover { background-color: ${theme.getColor(buttonHoverBackground)} !important; }`); + const buttonHoverBackgroundColor = theme.getColor(buttonHoverBackground); + if (buttonHoverBackgroundColor) { + collector.addRule(`.global-message-list li.message-list-entry .actions-container .message-action .action-button:hover { background-color: ${buttonHoverBackgroundColor} !important; }`); + } this.updateStyles(); })); -- GitLab From e424344c8924f381a76b33f19fada89e432209e9 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Tue, 30 May 2017 23:37:00 -0700 Subject: [PATCH 0321/1347] Fixes #27420 --- extensions/typescript/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/typescript/package.json b/extensions/typescript/package.json index 879cf4ebc01..7d5105c3dca 100644 --- a/extensions/typescript/package.json +++ b/extensions/typescript/package.json @@ -124,7 +124,7 @@ }, "typescript.referencesCodeLens.enabled": { "type": "boolean", - "default": true, + "default": false, "description": "%typescript.referencesCodeLens.enabled%" }, "typescript.implementationsCodeLens.enabled": { -- GitLab From 5dfc0e783e9edcc50a2271c8c315de9e98bd1821 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Tue, 30 May 2017 23:41:42 -0700 Subject: [PATCH 0322/1347] Fixes #27675 --- src/vs/editor/contrib/suggest/browser/media/suggest.css | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/editor/contrib/suggest/browser/media/suggest.css b/src/vs/editor/contrib/suggest/browser/media/suggest.css index 7ca54b83969..41ac9914b31 100644 --- a/src/vs/editor/contrib/suggest/browser/media/suggest.css +++ b/src/vs/editor/contrib/suggest/browser/media/suggest.css @@ -16,14 +16,14 @@ .monaco-editor .suggest-widget > .tree, .monaco-editor .suggest-widget > .details { - width: 428px; + width: calc(100% - 2px); border-style: solid; border-width: 1px; } .monaco-editor.hc-black .suggest-widget > .tree, .monaco-editor.hc-black .suggest-widget > .details { - width: 426px; + width: calc(100% - 4px); border-width: 2px; } -- GitLab From 2cc2594934439ffe46ce251ac22ced64012ae872 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Tue, 30 May 2017 23:50:06 -0700 Subject: [PATCH 0323/1347] Fixes #27673 --- src/vs/editor/contrib/suggest/browser/suggestWidget.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index c5559659a7f..e28154b9f42 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -809,6 +809,9 @@ export class SuggestWidget implements IContentWidget, IDelegate } toggleDetails(): void { + if (!canExpandCompletionItem(this.list.getFocusedElements()[0])) { + return; + } if (this.storageService.getBoolean('expandSuggestionDocs', StorageScope.GLOBAL, expandSuggestionDocsByDefault)) { this.storageService.store('expandSuggestionDocs', false, StorageScope.GLOBAL); -- GitLab From 396bb476981c2548eb93a99fb0aba9e054b5353f Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Tue, 30 May 2017 23:57:49 -0700 Subject: [PATCH 0324/1347] Fixes #27656 --- src/vs/editor/contrib/suggest/browser/suggestWidget.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index e28154b9f42..6cbef7682da 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -563,8 +563,6 @@ export class SuggestWidget implements IContentWidget, IDelegate if (this.storageService.getBoolean('expandSuggestionDocs', StorageScope.GLOBAL, expandSuggestionDocsByDefault)) { this.showDetails(); - - this._ariaAlert(this.details.getAriaLabel()); } else { removeClass(this.element, 'docs-side'); } @@ -845,6 +843,8 @@ export class SuggestWidget implements IContentWidget, IDelegate this.adjustDocsPosition(); this.editor.focus(); + + this._ariaAlert(this.details.getAriaLabel()); } private show(): void { -- GitLab From 770fa41896cf87de9479c11e7f1892444e60899b Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Wed, 31 May 2017 00:09:30 -0700 Subject: [PATCH 0325/1347] Fixes #27651 --- .../contrib/suggest/browser/suggestWidget.ts | 45 ++++++++++--------- 1 file changed, 25 insertions(+), 20 deletions(-) diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index 6cbef7682da..1ebbe971fac 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -694,6 +694,11 @@ export class SuggestWidget implements IContentWidget, IDelegate } else { this.setState(State.Open); } + + // Reset focus border + if (this.detailsBorderColor) { + this.details.element.style.borderColor = this.detailsBorderColor; + } } } @@ -964,29 +969,29 @@ export class SuggestWidget implements IContentWidget, IDelegate } // Fix for #26244 - if (hasClass(this.element, 'list-right')) { - addClass(this.listElement, 'empty-left-border'); - removeClass(this.listElement, 'empty-right-border'); - } else { - addClass(this.listElement, 'empty-right-border'); - removeClass(this.listElement, 'empty-left-border'); - } - - removeClass(this.details.element, 'empty-left-border'); - removeClass(this.details.element, 'empty-right-border'); + // if (hasClass(this.element, 'list-right')) { + // addClass(this.listElement, 'empty-left-border'); + // removeClass(this.listElement, 'empty-right-border'); + // } else { + // addClass(this.listElement, 'empty-right-border'); + // removeClass(this.listElement, 'empty-left-border'); + // } + + // removeClass(this.details.element, 'empty-left-border'); + // removeClass(this.details.element, 'empty-right-border'); return; } else { // Fix for #26244 - if (hasClass(this.element, 'list-right')) { - addClass(this.details.element, 'empty-right-border'); - removeClass(this.details.element, 'empty-left-border'); - } else { - addClass(this.details.element, 'empty-left-border'); - removeClass(this.details.element, 'empty-right-border'); - } - - removeClass(this.listElement, 'empty-right-border'); - removeClass(this.listElement, 'empty-left-border'); + // if (hasClass(this.element, 'list-right')) { + // addClass(this.details.element, 'empty-right-border'); + // removeClass(this.details.element, 'empty-left-border'); + // } else { + // addClass(this.details.element, 'empty-left-border'); + // removeClass(this.details.element, 'empty-right-border'); + // } + + // removeClass(this.listElement, 'empty-right-border'); + // removeClass(this.listElement, 'empty-left-border'); } } -- GitLab From c1d3334fc2eb70b3dd61954561806a890b76ffc4 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 31 May 2017 09:35:07 +0200 Subject: [PATCH 0326/1347] Close any notifications before clicking on the tab. Fixes #27606. --- test/smoke/src/areas/common.ts | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/test/smoke/src/areas/common.ts b/test/smoke/src/areas/common.ts index 96515d7ca49..aaf753bbfda 100644 --- a/test/smoke/src/areas/common.ts +++ b/test/smoke/src/areas/common.ts @@ -45,7 +45,7 @@ export class CommonActions { } public async getTab(tabName: string, active?: boolean): Promise { - await this.spectron.command('workbench.action.closeMessages'); // close any notification messages that could overlap tabs + await this.closeCurrentNotification(); // close any notification messages that could overlap tabs let tabSelector = active ? '.tab.active' : 'div'; let el = await this.spectron.client.element(`.tabs-container ${tabSelector}[aria-label="${tabName}, tab"]`); @@ -56,7 +56,8 @@ export class CommonActions { return undefined; } - public selectTab(tabName: string): Promise { + public async selectTab(tabName: string): Promise { + await this.closeCurrentNotification(); // close any notification messages that could overlap tabs return this.spectron.client.click(`.tabs-container div[aria-label="${tabName}, tab"]`); } @@ -162,4 +163,8 @@ export class CommonActions { throw new Error(`Failed to remove ${directory} with an error: ${e}`); } } + + private closeCurrentNotification(): Promise { + return this.spectron.command('workbench.action.closeMessages'); + } } \ No newline at end of file -- GitLab From e70d11da0b00465dbc8a6d2107ba7f0feb26d77e Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 31 May 2017 09:38:24 +0200 Subject: [PATCH 0327/1347] Triple equals for keybinding find. --- test/smoke/src/spectron/application.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/smoke/src/spectron/application.ts b/test/smoke/src/spectron/application.ts index 0c8896bcc8d..4d64259ae17 100644 --- a/test/smoke/src/spectron/application.ts +++ b/test/smoke/src/spectron/application.ts @@ -134,7 +134,7 @@ export class SpectronApplication { * @param command command (e.g. 'workbench.action.files.newUntitledFile') */ public command(command: string, capture?: boolean): Promise { - const binding = this.keybindings.find(x => x['command'] == command); + const binding = this.keybindings.find(x => x['command'] === command); const keys: string = binding.key; let keysToPress: string[] = []; -- GitLab From ef85e633e6692376ffc1cf821d0afdf3e22ae304 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 31 May 2017 11:01:36 +0200 Subject: [PATCH 0328/1347] fix windows build on appveyor --- appveyor.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/appveyor.yml b/appveyor.yml index c18b32095bf..49e80fed313 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -4,7 +4,7 @@ environment: install: - ps: Install-Product node 7.4.0 x64 - - npm install -g npm --silent + - npm install -g npm@4 --silent - npm install -g gulp mocha --silent build_script: -- GitLab From cc51097a6cc07ea4b558ad905957d6c0e696e015 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 31 May 2017 11:16:20 +0200 Subject: [PATCH 0329/1347] Rename multicursorModifier to multiCursorModifier (#27680) --- src/vs/editor/browser/view/viewController.ts | 4 +-- .../common/config/commonEditorConfig.ts | 4 +-- src/vs/editor/common/config/editorOptions.ts | 32 +++++++++---------- .../browser/clickLinkGesture.ts | 10 +++--- src/vs/editor/contrib/links/browser/links.ts | 6 ++-- src/vs/monaco.d.ts | 6 ++-- 6 files changed, 31 insertions(+), 31 deletions(-) diff --git a/src/vs/editor/browser/view/viewController.ts b/src/vs/editor/browser/view/viewController.ts index 51beeeade27..1ace89fcdac 100644 --- a/src/vs/editor/browser/view/viewController.ts +++ b/src/vs/editor/browser/view/viewController.ts @@ -102,7 +102,7 @@ export class ViewController { } private _hasMulticursorModifier(data: IMouseDispatchData): boolean { - switch (this.configuration.editor.multicursorModifier) { + switch (this.configuration.editor.multiCursorModifier) { case 'altKey': return data.altKey; case 'ctrlKey': @@ -114,7 +114,7 @@ export class ViewController { } private _hasNonMulticursorModifier(data: IMouseDispatchData): boolean { - switch (this.configuration.editor.multicursorModifier) { + switch (this.configuration.editor.multiCursorModifier) { case 'altKey': return data.ctrlKey || data.metaKey; case 'ctrlKey': diff --git a/src/vs/editor/common/config/commonEditorConfig.ts b/src/vs/editor/common/config/commonEditorConfig.ts index bf24f6608be..aff554eab3a 100644 --- a/src/vs/editor/common/config/commonEditorConfig.ts +++ b/src/vs/editor/common/config/commonEditorConfig.ts @@ -321,11 +321,11 @@ const editorConfiguration: IConfigurationNode = { 'default': EDITOR_DEFAULTS.viewInfo.scrollbar.mouseWheelScrollSensitivity, 'description': nls.localize('mouseWheelScrollSensitivity', "A multiplier to be used on the `deltaX` and `deltaY` of mouse wheel scroll events") }, - 'editor.multicursorModifier': { + 'editor.multiCursorModifier': { 'type': 'string', 'enum': (platform.isMacintosh ? ['cmd', 'alt'] : ['ctrl', 'alt']), 'default': 'alt', - 'description': nls.localize('multicursorModifier', "The modifier to be used to add multiple cursors with the mouse.") + 'description': nls.localize('multiCursorModifier', "The modifier to be used to add multiple cursors with the mouse.") }, 'editor.quickSuggestions': { 'anyOf': [ diff --git a/src/vs/editor/common/config/editorOptions.ts b/src/vs/editor/common/config/editorOptions.ts index c6997e43114..d90ca4dea90 100644 --- a/src/vs/editor/common/config/editorOptions.ts +++ b/src/vs/editor/common/config/editorOptions.ts @@ -335,7 +335,7 @@ export interface IEditorOptions { * The modifier to be used to add multiple cursors with the mouse. * Defaults to 'alt' */ - multicursorModifier?: 'cmd' | 'ctrl' | 'alt'; + multiCursorModifier?: 'cmd' | 'ctrl' | 'alt'; /** * Enable quick suggestions (shadow suggestions) * Defaults to true. @@ -788,7 +788,7 @@ export interface IValidatedEditorOptions { readonly dragAndDrop: boolean; readonly emptySelectionClipboard: boolean; readonly useTabStops: boolean; - readonly multicursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; + readonly multiCursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; readonly viewInfo: InternalEditorViewOptions; readonly contribInfo: EditorContribOptions; @@ -809,7 +809,7 @@ export class InternalEditorOptions { * @internal */ readonly accessibilitySupport: platform.AccessibilitySupport; - readonly multicursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; + readonly multiCursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; // ---- cursor options readonly wordSeparators: string; @@ -836,7 +836,7 @@ export class InternalEditorOptions { lineHeight: number; readOnly: boolean; accessibilitySupport: platform.AccessibilitySupport; - multicursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; + multiCursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; wordSeparators: string; autoClosingBrackets: boolean; useTabStops: boolean; @@ -855,7 +855,7 @@ export class InternalEditorOptions { this.lineHeight = source.lineHeight | 0; this.readOnly = source.readOnly; this.accessibilitySupport = source.accessibilitySupport; - this.multicursorModifier = source.multicursorModifier; + this.multiCursorModifier = source.multiCursorModifier; this.wordSeparators = source.wordSeparators; this.autoClosingBrackets = source.autoClosingBrackets; this.useTabStops = source.useTabStops; @@ -880,7 +880,7 @@ export class InternalEditorOptions { && this.lineHeight === other.lineHeight && this.readOnly === other.readOnly && this.accessibilitySupport === other.accessibilitySupport - && this.multicursorModifier === other.multicursorModifier + && this.multiCursorModifier === other.multiCursorModifier && this.wordSeparators === other.wordSeparators && this.autoClosingBrackets === other.autoClosingBrackets && this.useTabStops === other.useTabStops @@ -906,7 +906,7 @@ export class InternalEditorOptions { lineHeight: (this.lineHeight !== newOpts.lineHeight), readOnly: (this.readOnly !== newOpts.readOnly), accessibilitySupport: (this.accessibilitySupport !== newOpts.accessibilitySupport), - multicursorModifier: (this.multicursorModifier !== newOpts.multicursorModifier), + multiCursorModifier: (this.multiCursorModifier !== newOpts.multiCursorModifier), wordSeparators: (this.wordSeparators !== newOpts.wordSeparators), autoClosingBrackets: (this.autoClosingBrackets !== newOpts.autoClosingBrackets), useTabStops: (this.useTabStops !== newOpts.useTabStops), @@ -1244,7 +1244,7 @@ export interface IConfigurationChangedEvent { readonly lineHeight: boolean; readonly readOnly: boolean; readonly accessibilitySupport: boolean; - readonly multicursorModifier: boolean; + readonly multiCursorModifier: boolean; readonly wordSeparators: boolean; readonly autoClosingBrackets: boolean; readonly useTabStops: boolean; @@ -1399,22 +1399,22 @@ export class EditorOptionsValidator { const contribInfo = this._sanitizeContribInfo(opts, defaults.contribInfo); let configuredMulticursorModifier: 'altKey' | 'metaKey' | 'ctrlKey'; - if (typeof opts.multicursorModifier === 'string') { + if (typeof opts.multiCursorModifier === 'string') { if (platform.isMacintosh) { - if (opts.multicursorModifier === 'cmd') { + if (opts.multiCursorModifier === 'cmd') { configuredMulticursorModifier = 'metaKey'; } else { configuredMulticursorModifier = 'altKey'; } } else { - if (opts.multicursorModifier === 'ctrl') { + if (opts.multiCursorModifier === 'ctrl') { configuredMulticursorModifier = 'ctrlKey'; } else { configuredMulticursorModifier = 'altKey'; } } } - const multicursorModifier = _stringSet<'altKey' | 'metaKey' | 'ctrlKey'>(configuredMulticursorModifier, defaults.multicursorModifier, ['altKey', 'metaKey', 'ctrlKey']); + const multiCursorModifier = _stringSet<'altKey' | 'metaKey' | 'ctrlKey'>(configuredMulticursorModifier, defaults.multiCursorModifier, ['altKey', 'metaKey', 'ctrlKey']); return { inDiffEditor: _boolean(opts.inDiffEditor, defaults.inDiffEditor), @@ -1436,7 +1436,7 @@ export class EditorOptionsValidator { dragAndDrop: _boolean(opts.dragAndDrop, defaults.dragAndDrop), emptySelectionClipboard: _boolean(opts.emptySelectionClipboard, defaults.emptySelectionClipboard), useTabStops: _boolean(opts.useTabStops, defaults.useTabStops), - multicursorModifier: multicursorModifier, + multiCursorModifier: multiCursorModifier, viewInfo: viewInfo, contribInfo: contribInfo, }; @@ -1660,7 +1660,7 @@ export class InternalEditorOptionsFactory { dragAndDrop: opts.dragAndDrop, emptySelectionClipboard: opts.emptySelectionClipboard, useTabStops: opts.useTabStops, - multicursorModifier: opts.multicursorModifier, + multiCursorModifier: opts.multiCursorModifier, viewInfo: { extraEditorClassName: opts.viewInfo.extraEditorClassName, @@ -1837,7 +1837,7 @@ export class InternalEditorOptionsFactory { lineHeight: env.fontInfo.lineHeight, readOnly: opts.readOnly, accessibilitySupport: env.accessibilitySupport, - multicursorModifier: opts.multicursorModifier, + multiCursorModifier: opts.multiCursorModifier, wordSeparators: opts.wordSeparators, autoClosingBrackets: opts.autoClosingBrackets, useTabStops: opts.useTabStops, @@ -2056,7 +2056,7 @@ export const EDITOR_DEFAULTS: IValidatedEditorOptions = { dragAndDrop: true, emptySelectionClipboard: true, useTabStops: true, - multicursorModifier: 'altKey', + multiCursorModifier: 'altKey', viewInfo: { extraEditorClassName: '', diff --git a/src/vs/editor/contrib/goToDeclaration/browser/clickLinkGesture.ts b/src/vs/editor/contrib/goToDeclaration/browser/clickLinkGesture.ts index 79d1043cf50..c82f9d3fa7f 100644 --- a/src/vs/editor/contrib/goToDeclaration/browser/clickLinkGesture.ts +++ b/src/vs/editor/contrib/goToDeclaration/browser/clickLinkGesture.ts @@ -82,8 +82,8 @@ export class ClickLinkOptions { } } -function createOptions(multicursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'): ClickLinkOptions { - if (multicursorModifier === 'altKey') { +function createOptions(multiCursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'): ClickLinkOptions { + if (multiCursorModifier === 'altKey') { if (platform.isMacintosh) { return new ClickLinkOptions(KeyCode.Meta, 'metaKey', KeyCode.Alt, 'altKey'); } @@ -117,14 +117,14 @@ export class ClickLinkGesture extends Disposable { super(); this._editor = editor; - this._opts = createOptions(this._editor.getConfiguration().multicursorModifier); + this._opts = createOptions(this._editor.getConfiguration().multiCursorModifier); this.lastMouseMoveEvent = null; this.hasTriggerKeyOnMouseDown = false; this._register(this._editor.onDidChangeConfiguration((e) => { - if (e.multicursorModifier) { - const newOpts = createOptions(this._editor.getConfiguration().multicursorModifier); + if (e.multiCursorModifier) { + const newOpts = createOptions(this._editor.getConfiguration().multiCursorModifier); if (this._opts.equals(newOpts)) { return; } diff --git a/src/vs/editor/contrib/links/browser/links.ts b/src/vs/editor/contrib/links/browser/links.ts index d25c7a9a3ad..c50fc2e0c43 100644 --- a/src/vs/editor/contrib/links/browser/links.ts +++ b/src/vs/editor/contrib/links/browser/links.ts @@ -199,7 +199,7 @@ class LinkDetector implements editorCommon.IEditorContribution { } private updateDecorations(links: Link[]): void { - const useMetaKey = (this.editor.getConfiguration().multicursorModifier === 'altKey'); + const useMetaKey = (this.editor.getConfiguration().multiCursorModifier === 'altKey'); this.editor.changeDecorations((changeAccessor: editorCommon.IModelDecorationsChangeAccessor) => { var oldDecorations: string[] = []; let keys = Object.keys(this.currentOccurences); @@ -229,7 +229,7 @@ class LinkDetector implements editorCommon.IEditorContribution { } private _onEditorMouseMove(mouseEvent: ClickLinkMouseEvent, withKey?: ClickLinkKeyboardEvent): void { - const useMetaKey = (this.editor.getConfiguration().multicursorModifier === 'altKey'); + const useMetaKey = (this.editor.getConfiguration().multiCursorModifier === 'altKey'); if (this.isEnabled(mouseEvent, withKey)) { this.cleanUpActiveLinkDecoration(); // always remove previous link decoration as their can only be one var occurence = this.getLinkOccurence(mouseEvent.target.position); @@ -245,7 +245,7 @@ class LinkDetector implements editorCommon.IEditorContribution { } private cleanUpActiveLinkDecoration(): void { - const useMetaKey = (this.editor.getConfiguration().multicursorModifier === 'altKey'); + const useMetaKey = (this.editor.getConfiguration().multiCursorModifier === 'altKey'); if (this.activeLinkDecorationId) { var occurence = this.currentOccurences[this.activeLinkDecorationId]; if (occurence) { diff --git a/src/vs/monaco.d.ts b/src/vs/monaco.d.ts index d293d474a24..a6e44bb89c0 100644 --- a/src/vs/monaco.d.ts +++ b/src/vs/monaco.d.ts @@ -2881,7 +2881,7 @@ declare module monaco.editor { * The modifier to be used to add multiple cursors with the mouse. * Defaults to 'alt' */ - multicursorModifier?: 'cmd' | 'ctrl' | 'alt'; + multiCursorModifier?: 'cmd' | 'ctrl' | 'alt'; /** * Enable quick suggestions (shadow suggestions) * Defaults to true. @@ -3263,7 +3263,7 @@ declare module monaco.editor { readonly editorClassName: string; readonly lineHeight: number; readonly readOnly: boolean; - readonly multicursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; + readonly multiCursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; readonly wordSeparators: string; readonly autoClosingBrackets: boolean; readonly useTabStops: boolean; @@ -3395,7 +3395,7 @@ declare module monaco.editor { readonly lineHeight: boolean; readonly readOnly: boolean; readonly accessibilitySupport: boolean; - readonly multicursorModifier: boolean; + readonly multiCursorModifier: boolean; readonly wordSeparators: boolean; readonly autoClosingBrackets: boolean; readonly useTabStops: boolean; -- GitLab From b8356584c681dedca400443c8c2140559a6750fa Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 31 May 2017 11:31:22 +0200 Subject: [PATCH 0330/1347] Fixes #27680: multiCursorModifer can be `ctrlCmd` or `alt` --- .../editor/common/config/commonEditorConfig.ts | 8 ++++++-- src/vs/editor/common/config/editorOptions.ts | 16 ++++------------ src/vs/monaco.d.ts | 2 +- 3 files changed, 11 insertions(+), 15 deletions(-) diff --git a/src/vs/editor/common/config/commonEditorConfig.ts b/src/vs/editor/common/config/commonEditorConfig.ts index aff554eab3a..38eb78fc8b9 100644 --- a/src/vs/editor/common/config/commonEditorConfig.ts +++ b/src/vs/editor/common/config/commonEditorConfig.ts @@ -323,9 +323,13 @@ const editorConfiguration: IConfigurationNode = { }, 'editor.multiCursorModifier': { 'type': 'string', - 'enum': (platform.isMacintosh ? ['cmd', 'alt'] : ['ctrl', 'alt']), + 'enum': ['ctrlCmd', 'alt'], + 'enumDescriptions': [ + nls.localize('multiCursorModifier.ctrlCmd', "Maps to `Control` on Windows and Linux and to `Command` on OSX."), + nls.localize('multiCursorModifier.alt', "Maps to `Alt` on Windows and Linux and to `Option` on OSX.") + ], 'default': 'alt', - 'description': nls.localize('multiCursorModifier', "The modifier to be used to add multiple cursors with the mouse.") + 'description': nls.localize('multiCursorModifier', "The modifier to be used to add multiple cursors with the mouse. `ctrlCmd` maps to `Control` on Windows and Linux and to `Command` on OSX") }, 'editor.quickSuggestions': { 'anyOf': [ diff --git a/src/vs/editor/common/config/editorOptions.ts b/src/vs/editor/common/config/editorOptions.ts index d90ca4dea90..24ea09ddf31 100644 --- a/src/vs/editor/common/config/editorOptions.ts +++ b/src/vs/editor/common/config/editorOptions.ts @@ -335,7 +335,7 @@ export interface IEditorOptions { * The modifier to be used to add multiple cursors with the mouse. * Defaults to 'alt' */ - multiCursorModifier?: 'cmd' | 'ctrl' | 'alt'; + multiCursorModifier?: 'ctrlCmd' | 'alt'; /** * Enable quick suggestions (shadow suggestions) * Defaults to true. @@ -1400,18 +1400,10 @@ export class EditorOptionsValidator { let configuredMulticursorModifier: 'altKey' | 'metaKey' | 'ctrlKey'; if (typeof opts.multiCursorModifier === 'string') { - if (platform.isMacintosh) { - if (opts.multiCursorModifier === 'cmd') { - configuredMulticursorModifier = 'metaKey'; - } else { - configuredMulticursorModifier = 'altKey'; - } + if (opts.multiCursorModifier === 'ctrlCmd') { + configuredMulticursorModifier = platform.isMacintosh ? 'metaKey' : 'ctrlKey'; } else { - if (opts.multiCursorModifier === 'ctrl') { - configuredMulticursorModifier = 'ctrlKey'; - } else { - configuredMulticursorModifier = 'altKey'; - } + configuredMulticursorModifier = 'altKey'; } } const multiCursorModifier = _stringSet<'altKey' | 'metaKey' | 'ctrlKey'>(configuredMulticursorModifier, defaults.multiCursorModifier, ['altKey', 'metaKey', 'ctrlKey']); diff --git a/src/vs/monaco.d.ts b/src/vs/monaco.d.ts index a6e44bb89c0..34d430262a6 100644 --- a/src/vs/monaco.d.ts +++ b/src/vs/monaco.d.ts @@ -2881,7 +2881,7 @@ declare module monaco.editor { * The modifier to be used to add multiple cursors with the mouse. * Defaults to 'alt' */ - multiCursorModifier?: 'cmd' | 'ctrl' | 'alt'; + multiCursorModifier?: 'ctrlCmd' | 'alt'; /** * Enable quick suggestions (shadow suggestions) * Defaults to true. -- GitLab From 0e1167e1115fcb5771d64f9359078a14f9d8e1a2 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 31 May 2017 11:50:18 +0200 Subject: [PATCH 0331/1347] fix #27710 --- src/vs/vscode.d.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vs/vscode.d.ts b/src/vs/vscode.d.ts index 82c239860cd..d7682428116 100644 --- a/src/vs/vscode.d.ts +++ b/src/vs/vscode.d.ts @@ -3209,7 +3209,7 @@ declare module 'vscode' { } /** - * Denotes a column in the VS Code window. Columns are + * Denotes a column in the editor window. Columns are * used to show editors side by side. */ export enum ViewColumn { @@ -4528,7 +4528,7 @@ declare module 'vscode' { export function createFileSystemWatcher(globPattern: string, ignoreCreateEvents?: boolean, ignoreChangeEvents?: boolean, ignoreDeleteEvents?: boolean): FileSystemWatcher; /** - * The folder that is open in VS Code. `undefined` when no folder + * The folder that is open in the editor. `undefined` when no folder * has been opened. * * @readonly @@ -5276,7 +5276,7 @@ declare module 'vscode' { * Thenable is a common denominator between ES6 promises, Q, jquery.Deferred, WinJS.Promise, * and others. This API makes no assumption about what promise libary is being used which * enables reusing existing code without migrating to a specific promise implementation. Still, - * we recommend the use of native promises which are available in VS Code. + * we recommend the use of native promises which are available in this editor. */ interface Thenable { /** -- GitLab From e7fd412de4ffe236d87ff7994d5fdcd98e5f742d Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 31 May 2017 12:07:26 +0200 Subject: [PATCH 0332/1347] fix #27541 * return `undefined` when current word or selection is falsy * use editor selection, not snippet selection, when resolving variables --- src/vs/editor/contrib/snippet/browser/snippetSession.ts | 2 +- src/vs/editor/contrib/snippet/browser/snippetVariables.ts | 4 ++-- .../contrib/snippet/test/browser/snippetVariables.test.ts | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/vs/editor/contrib/snippet/browser/snippetSession.ts b/src/vs/editor/contrib/snippet/browser/snippetSession.ts index c4fcdaa3e41..4a5d4cc9e41 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetSession.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetSession.ts @@ -253,7 +253,7 @@ export class SnippetSession { const start = snippetSelection.getStartPosition(); const adjustedTemplate = SnippetSession.adjustWhitespace(model, start, this._template); - const snippet = SnippetParser.parse(adjustedTemplate).resolveVariables(new EditorSnippetVariableResolver(model, snippetSelection)); + const snippet = SnippetParser.parse(adjustedTemplate).resolveVariables(new EditorSnippetVariableResolver(model, selection)); // rewrite final-tabstop to some other placeholder because this // snippet sits inside another snippet diff --git a/src/vs/editor/contrib/snippet/browser/snippetVariables.ts b/src/vs/editor/contrib/snippet/browser/snippetVariables.ts index ab345893eac..2953ee8bfc3 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetVariables.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetVariables.ts @@ -32,7 +32,7 @@ export class EditorSnippetVariableResolver { resolve(name: string): string { if (name === 'SELECTION' || name === 'TM_SELECTED_TEXT') { - return this._model.getValueInRange(this._selection); + return this._model.getValueInRange(this._selection) || undefined; } else if (name === 'TM_CURRENT_LINE') { return this._model.getLineContent(this._selection.positionLineNumber); @@ -42,7 +42,7 @@ export class EditorSnippetVariableResolver { lineNumber: this._selection.positionLineNumber, column: this._selection.positionColumn }); - return info ? info.word : ''; + return info && info.word || undefined; } else if (name === 'TM_LINE_INDEX') { return String(this._selection.positionLineNumber - 1); diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetVariables.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetVariables.test.ts index fa0bb4034f9..926bb6f424e 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetVariables.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetVariables.test.ts @@ -78,12 +78,12 @@ suite('Snippet Variables Resolver', function () { assert.equal(resolver.resolve('TM_LINE_NUMBER'), '1'); resolver = new EditorSnippetVariableResolver(model, new Selection(1, 2, 1, 2)); - assert.equal(resolver.resolve('TM_SELECTED_TEXT'), ''); + assert.equal(resolver.resolve('TM_SELECTED_TEXT'), undefined); assert.equal(resolver.resolve('TM_CURRENT_WORD'), 'this'); resolver = new EditorSnippetVariableResolver(model, new Selection(3, 1, 3, 1)); - assert.equal(resolver.resolve('TM_CURRENT_WORD'), ''); + assert.equal(resolver.resolve('TM_CURRENT_WORD'), undefined); }); -- GitLab From d8135cb714f9eb5093a8a610343c76155f4bf4dd Mon Sep 17 00:00:00 2001 From: isidor Date: Wed, 31 May 2017 12:14:46 +0200 Subject: [PATCH 0333/1347] "Check For Updates" -> "Check for Updates" fixes #27532 --- src/vs/code/electron-main/menus.ts | 2 +- src/vs/workbench/parts/update/electron-browser/update.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index 249722e754c..16f3af28054 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -1023,7 +1023,7 @@ export class VSCodeMenu { default: const result = [new MenuItem({ - label: nls.localize('miCheckForUpdates', "Check For Updates..."), click: () => setTimeout(() => { + label: nls.localize('miCheckForUpdates', "Check for Updates..."), click: () => setTimeout(() => { this.reportMenuActionTelemetry('CheckForUpdate'); this.updateService.checkForUpdates(true); }, 0) diff --git a/src/vs/workbench/parts/update/electron-browser/update.ts b/src/vs/workbench/parts/update/electron-browser/update.ts index 9b77ef4c8fb..e91b4311779 100644 --- a/src/vs/workbench/parts/update/electron-browser/update.ts +++ b/src/vs/workbench/parts/update/electron-browser/update.ts @@ -340,7 +340,7 @@ export class LightUpdateContribution implements IGlobalActivity { this.updateService.quitAndInstall()); default: - return new Action('update.check', nls.localize('checkForUpdates', "Check For Updates..."), undefined, this.updateService.state === UpdateState.Idle, () => + return new Action('update.check', nls.localize('checkForUpdates', "Check for Updates..."), undefined, this.updateService.state === UpdateState.Idle, () => this.updateService.checkForUpdates(true)); } } -- GitLab From a1abe1a386e01ab300a3f84de2181621f1068575 Mon Sep 17 00:00:00 2001 From: isidor Date: Wed, 31 May 2017 12:27:05 +0200 Subject: [PATCH 0334/1347] copy all: remove ansi escape code fixes #27525 --- .../parts/debug/electron-browser/electronDebugActions.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.ts b/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.ts index aef048ce10f..eae64f5c6c4 100644 --- a/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.ts +++ b/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.ts @@ -7,6 +7,7 @@ import * as nls from 'vs/nls'; import { Action } from 'vs/base/common/actions'; import { TPromise } from 'vs/base/common/winjs.base'; import { ITree } from 'vs/base/parts/tree/browser/tree'; +import { removeAnsiEscapeCodes } from 'vs/base/common/strings'; import { Variable } from 'vs/workbench/parts/debug/common/debugModel'; import { IDebugService, IStackFrame } from 'vs/workbench/parts/debug/common/debug'; import { clipboard } from 'electron'; @@ -62,7 +63,7 @@ export class CopyAllAction extends Action { text += navigator.current().toString(); } - clipboard.writeText(text); + clipboard.writeText(removeAnsiEscapeCodes(text)); return TPromise.as(null); } } -- GitLab From 24b543efdfb117e853be224eb7943ae57f93a947 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Tue, 30 May 2017 13:01:48 +0200 Subject: [PATCH 0335/1347] Fix #27507 --- src/vs/vscode.proposed.d.ts | 4 ++-- src/vs/workbench/api/node/extHost.api.impl.ts | 4 ++-- src/vs/workbench/api/node/extHostTreeViews.ts | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/vs/vscode.proposed.d.ts b/src/vs/vscode.proposed.d.ts index f571826403c..f6778e6f60b 100644 --- a/src/vs/vscode.proposed.d.ts +++ b/src/vs/vscode.proposed.d.ts @@ -18,7 +18,7 @@ declare module 'vscode' { * @param viewId Id of the view contributed using the extension point `views`. * @param treeDataProvider A [TreeDataProvider](#TreeDataProvider) that provides tree data for the view */ - export function registerTreeDataProviderForView(viewId: string, treeDataProvider: TreeDataProvider): Disposable; + export function registerTreeDataProvider(viewId: string, treeDataProvider: TreeDataProvider): Disposable; } /** @@ -71,7 +71,7 @@ declare module 'vscode' { /** * Context value of the tree item. This can be used to contribute item specific actions in the tree. - * For example, a tree item is given a context value as `folder`. When contribution actions to `view/item/context` + * For example, a tree item is given a context value as `folder`. When contributing actions to `view/item/context` * using `menus` extension point, you can specify context value for key `viewItem` in `when` expression like `viewItem == folder`. * ``` * "contributes": { diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index 1ec2c22afa3..0d14189f2a5 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -369,8 +369,8 @@ export function createApiFactory( sampleFunction: proposedApiFunction(extension, () => { return extHostMessageService.showMessage(Severity.Info, 'Hello Proposed Api!', {}, []); }), - registerTreeDataProviderForView: proposedApiFunction(extension, (viewId: string, treeDataProvider: vscode.TreeDataProvider): vscode.Disposable => { - return extHostTreeViews.registerTreeDataProviderForView(viewId, treeDataProvider); + registerTreeDataProvider: proposedApiFunction(extension, (viewId: string, treeDataProvider: vscode.TreeDataProvider): vscode.Disposable => { + return extHostTreeViews.registerTreeDataProvider(viewId, treeDataProvider); }) }; diff --git a/src/vs/workbench/api/node/extHostTreeViews.ts b/src/vs/workbench/api/node/extHostTreeViews.ts index b772b894593..524c56baa5a 100644 --- a/src/vs/workbench/api/node/extHostTreeViews.ts +++ b/src/vs/workbench/api/node/extHostTreeViews.ts @@ -39,7 +39,7 @@ export class ExtHostTreeViews extends ExtHostTreeViewsShape { }); } - registerTreeDataProviderForView(id: string, treeDataProvider: vscode.TreeDataProvider): vscode.Disposable { + registerTreeDataProvider(id: string, treeDataProvider: vscode.TreeDataProvider): vscode.Disposable { const treeView = new ExtHostTreeView(id, treeDataProvider, this._proxy); this.treeViews.set(id, treeView); return { -- GitLab From 18d234745970ab9ae8a9888c5d0ab76d190fb24a Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Tue, 30 May 2017 14:06:42 +0200 Subject: [PATCH 0336/1347] Fix #27509 --- src/vs/vscode.proposed.d.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/vscode.proposed.d.ts b/src/vs/vscode.proposed.d.ts index f6778e6f60b..b1195002588 100644 --- a/src/vs/vscode.proposed.d.ts +++ b/src/vs/vscode.proposed.d.ts @@ -31,7 +31,7 @@ declare module 'vscode' { onDidChangeTreeData?: Event; /** - * get [TreeItem](#TreeItem) representation of the `element` + * Get [TreeItem](#TreeItem) representation of the `element` * * @param element The element for which [TreeItem](#TreeItem) representation is asked for. * @return [TreeItem](#TreeItem) representation of the element @@ -39,7 +39,7 @@ declare module 'vscode' { getTreeItem(element: T): TreeItem; /** - * get the children of `element` or root. + * Get the children of `element` or root. * * @param element The element from which the provider gets children for. * @return Children of `element` or root. -- GitLab From 5e6270745037adbe6645900fc412e788bb6bd605 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Tue, 30 May 2017 14:09:14 +0200 Subject: [PATCH 0337/1347] Fix #27512 --- src/vs/vscode.proposed.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/vscode.proposed.d.ts b/src/vs/vscode.proposed.d.ts index b1195002588..ea64b766b66 100644 --- a/src/vs/vscode.proposed.d.ts +++ b/src/vs/vscode.proposed.d.ts @@ -44,7 +44,7 @@ declare module 'vscode' { * @param element The element from which the provider gets children for. * @return Children of `element` or root. */ - getChildren(element?: T): T[] | Thenable; + getChildren(element?: T): ProviderResult; } export interface TreeItem { -- GitLab From 9ddbdd0d9ef7793281b0b95ed126fa44ff94dc1a Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Tue, 30 May 2017 14:26:53 +0200 Subject: [PATCH 0338/1347] Fix #27530 --- src/vs/workbench/api/node/extHostTreeViews.ts | 33 +++++++++++-------- 1 file changed, 20 insertions(+), 13 deletions(-) diff --git a/src/vs/workbench/api/node/extHostTreeViews.ts b/src/vs/workbench/api/node/extHostTreeViews.ts index 524c56baa5a..f050ea1df7f 100644 --- a/src/vs/workbench/api/node/extHostTreeViews.ts +++ b/src/vs/workbench/api/node/extHostTreeViews.ts @@ -130,25 +130,32 @@ class ExtHostTreeView extends Disposable { private processAndMapElements(elements: T[]): TPromise { const treeItemsPromises: TPromise[] = []; for (const element of elements) { - if (this.extChildrenElementsMap.has(element)) { - return TPromise.wrapError(localize('treeView.duplicateElement', 'Element {0} is already registered', element)); - } - const treeItem = this.massageTreeItem(this.dataProvider.getTreeItem(element)); - this.itemHandlesMap.set(element, treeItem.handle); - this.extElementsMap.set(treeItem.handle, element); - if (treeItem.collapsibleState === TreeItemCollapsibleState.Expanded) { - treeItemsPromises.push(this.getChildren(treeItem.handle).then(children => { - treeItem.children = children; - return treeItem; - })); - } else { - treeItemsPromises.push(TPromise.as(treeItem)); + if (element) { + if (this.extChildrenElementsMap.has(element)) { + return TPromise.wrapError(localize('treeView.duplicateElement', 'Element {0} is already registered', element)); + } + const treeItem = this.massageTreeItem(this.dataProvider.getTreeItem(element)); + if (treeItem) { + this.itemHandlesMap.set(element, treeItem.handle); + this.extElementsMap.set(treeItem.handle, element); + if (treeItem.collapsibleState === TreeItemCollapsibleState.Expanded) { + treeItemsPromises.push(this.getChildren(treeItem.handle).then(children => { + treeItem.children = children; + return treeItem; + })); + } else { + treeItemsPromises.push(TPromise.as(treeItem)); + } + } } } return TPromise.join(treeItemsPromises); } private massageTreeItem(extensionTreeItem: vscode.TreeItem): TreeItem { + if (!extensionTreeItem) { + return null; + } const icon = this.getLightIconPath(extensionTreeItem); return { handle: ++this._itemHandlePool, -- GitLab From 82eb47c42dc17d495c77600456b8fc6749601c51 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Tue, 30 May 2017 15:29:42 +0200 Subject: [PATCH 0339/1347] Fix #27535 --- .../electron-browser/mainThreadTreeViews.ts | 3 +- src/vs/workbench/api/node/extHost.protocol.ts | 20 ++------ src/vs/workbench/api/node/extHostTreeViews.ts | 45 ++++++++--------- .../workbench/parts/views/browser/treeView.ts | 9 ++-- src/vs/workbench/parts/views/browser/views.ts | 37 +------------- src/vs/workbench/parts/views/common/views.ts | 48 +++++++++++++++++++ 6 files changed, 81 insertions(+), 81 deletions(-) create mode 100644 src/vs/workbench/parts/views/common/views.ts diff --git a/src/vs/workbench/api/electron-browser/mainThreadTreeViews.ts b/src/vs/workbench/api/electron-browser/mainThreadTreeViews.ts index 186c646eace..6d41b483db6 100644 --- a/src/vs/workbench/api/electron-browser/mainThreadTreeViews.ts +++ b/src/vs/workbench/api/electron-browser/mainThreadTreeViews.ts @@ -9,7 +9,8 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { IThreadService } from 'vs/workbench/services/thread/common/threadService'; import { ExtHostContext, MainThreadTreeViewsShape, ExtHostTreeViewsShape } from '../node/extHost.protocol'; import { IMessageService, Severity } from 'vs/platform/message/common/message'; -import { ViewsRegistry, ITreeViewDataProvider, ITreeItem, TreeItemCollapsibleState } from 'vs/workbench/parts/views/browser/views'; +import { ViewsRegistry } from 'vs/workbench/parts/views/browser/views'; +import { ITreeViewDataProvider, ITreeItem, TreeItemCollapsibleState } from 'vs/workbench/parts/views/common/views'; export class MainThreadTreeViews extends MainThreadTreeViewsShape { diff --git a/src/vs/workbench/api/node/extHost.protocol.ts b/src/vs/workbench/api/node/extHost.protocol.ts index b168ae2ddac..8f6d2c8deb5 100644 --- a/src/vs/workbench/api/node/extHost.protocol.ts +++ b/src/vs/workbench/api/node/extHost.protocol.ts @@ -45,6 +45,8 @@ import { IPosition } from 'vs/editor/common/core/position'; import { IRange } from 'vs/editor/common/core/range'; import { ISelection, Selection } from 'vs/editor/common/core/selection'; +import { ITreeItem } from 'vs/workbench/parts/views/common/views'; + export interface IEnvironment { enableProposedApiForAll: boolean; enableProposedApiFor: string | string[]; @@ -194,14 +196,6 @@ export abstract class MainThreadEditorsShape { $getDiffInformation(id: string): TPromise { throw ni(); } } -export interface TreeItem extends vscode.TreeItem { - handle: number; - commandId?: string; - icon?: string; - iconDark?: string; - children?: TreeItem[]; -} - export abstract class MainThreadTreeViewsShape { $registerView(treeViewId: string): void { throw ni(); } $refresh(treeViewId: string, treeItemHandle?: number): void { throw ni(); } @@ -407,15 +401,9 @@ export abstract class ExtHostDocumentsAndEditorsShape { $acceptDocumentsAndEditorsDelta(delta: IDocumentsAndEditorsDelta): void { throw ni(); } } -export type TreeViewCommandArg = { - treeViewId: string, - treeItemHandle: number -}; - export abstract class ExtHostTreeViewsShape { - $getElements(treeViewId: string): TPromise { throw ni(); } - $getChildren(treeViewId: string, treeItemHandle: number): TPromise { throw ni(); } - $restore(treeViewId: string, treeItems: TreeItem[]): TPromise { throw ni(); } + $getElements(treeViewId: string): TPromise { throw ni(); } + $getChildren(treeViewId: string, treeItemHandle: number): TPromise { throw ni(); } } export abstract class ExtHostExtensionServiceShape { diff --git a/src/vs/workbench/api/node/extHostTreeViews.ts b/src/vs/workbench/api/node/extHostTreeViews.ts index f050ea1df7f..d94eabb4167 100644 --- a/src/vs/workbench/api/node/extHostTreeViews.ts +++ b/src/vs/workbench/api/node/extHostTreeViews.ts @@ -10,11 +10,11 @@ import URI from 'vs/base/common/uri'; import { TPromise } from 'vs/base/common/winjs.base'; import { Disposable } from 'vs/base/common/lifecycle'; import { IThreadService } from 'vs/workbench/services/thread/common/threadService'; -import { MainContext, ExtHostTreeViewsShape, MainThreadTreeViewsShape, TreeItem, TreeViewCommandArg } from './extHost.protocol'; +import { MainContext, ExtHostTreeViewsShape, MainThreadTreeViewsShape } from './extHost.protocol'; +import { ITreeItem, TreeViewItemHandleArg } from 'vs/workbench/parts/views/common/views'; import { TreeItemCollapsibleState } from './extHostTypes'; -import { ExtHostCommands } from 'vs/workbench/api/node/extHostCommands'; +import { ExtHostCommands, CommandsConverter } from 'vs/workbench/api/node/extHostCommands'; import { asWinJsPromise } from 'vs/base/common/async'; -import * as modes from 'vs/editor/common/modes'; type TreeItemHandle = number; @@ -31,7 +31,7 @@ export class ExtHostTreeViews extends ExtHostTreeViewsShape { this._proxy = threadService.get(MainContext.MainThreadTreeViews); commands.registerArgumentProcessor({ processArgument: arg => { - if (arg && arg.treeViewId && arg.treeItemHandle) { + if (arg && arg.$treeViewId && arg.$treeItemHandle) { return this.convertArgument(arg); } return arg; @@ -40,7 +40,7 @@ export class ExtHostTreeViews extends ExtHostTreeViewsShape { } registerTreeDataProvider(id: string, treeDataProvider: vscode.TreeDataProvider): vscode.Disposable { - const treeView = new ExtHostTreeView(id, treeDataProvider, this._proxy); + const treeView = new ExtHostTreeView(id, treeDataProvider, this._proxy, this.commands.converter); this.treeViews.set(id, treeView); return { dispose: () => { @@ -50,28 +50,25 @@ export class ExtHostTreeViews extends ExtHostTreeViewsShape { }; } - $getElements(treeViewId: string): TPromise { + $getElements(treeViewId: string): TPromise { const treeView = this.treeViews.get(treeViewId); if (!treeView) { - return TPromise.wrapError(localize('treeView.notRegistered', 'No tree view with id \'{0}\' registered.', treeViewId)); + return TPromise.wrapError(localize('treeView.notRegistered', 'No tree view with id \'{0}\' registered.', treeViewId)); } return treeView.getTreeItems(); } - $getChildren(treeViewId: string, treeItemHandle?: number): TPromise { + $getChildren(treeViewId: string, treeItemHandle?: number): TPromise { const treeView = this.treeViews.get(treeViewId); if (!treeView) { - return TPromise.wrapError(localize('treeView.notRegistered', 'No tree view with id \'{0}\' registered.', treeViewId)); + return TPromise.wrapError(localize('treeView.notRegistered', 'No tree view with id \'{0}\' registered.', treeViewId)); } return treeView.getChildren(treeItemHandle); } - private convertArgument(arg: TreeViewCommandArg): any { - const treeView = this.treeViews.get(arg.treeViewId); - if (!treeView) { - return TPromise.wrapError(localize('treeView.notRegistered', 'No tree view with id \'{0}\' registered.', arg.treeViewId)); - } - return treeView.getExtensionElement(arg.treeItemHandle); + private convertArgument(arg: TreeViewItemHandleArg): any { + const treeView = this.treeViews.get(arg.$treeViewId); + return treeView ? treeView.getExtensionElement(arg.$treeItemHandle) : null; } } @@ -83,7 +80,7 @@ class ExtHostTreeView extends Disposable { private itemHandlesMap: Map = new Map(); private extChildrenElementsMap: Map = new Map(); - constructor(private viewId: string, private dataProvider: vscode.TreeDataProvider, private proxy: MainThreadTreeViewsShape) { + constructor(private viewId: string, private dataProvider: vscode.TreeDataProvider, private proxy: MainThreadTreeViewsShape, private commands: CommandsConverter, ) { super(); this.proxy.$registerView(viewId); if (dataProvider.onDidChangeTreeData) { @@ -91,7 +88,7 @@ class ExtHostTreeView extends Disposable { } } - getTreeItems(): TPromise { + getTreeItems(): TPromise { this.extChildrenElementsMap.clear(); this.extElementsMap.clear(); this.itemHandlesMap.clear(); @@ -100,12 +97,12 @@ class ExtHostTreeView extends Disposable { .then(elements => this.processAndMapElements(elements)); } - getChildren(treeItemHandle: TreeItemHandle): TPromise { + getChildren(treeItemHandle: TreeItemHandle): TPromise { let extElement = this.getExtensionElement(treeItemHandle); if (extElement) { this.clearChildren(extElement); } else { - return TPromise.wrapError(localize('treeItem.notFound', 'No tree item with id \'{0}\' found.', treeItemHandle)); + return TPromise.wrapError(localize('treeItem.notFound', 'No tree item with id \'{0}\' found.', treeItemHandle)); } return asWinJsPromise(() => this.dataProvider.getChildren(extElement)) @@ -127,12 +124,12 @@ class ExtHostTreeView extends Disposable { } } - private processAndMapElements(elements: T[]): TPromise { - const treeItemsPromises: TPromise[] = []; + private processAndMapElements(elements: T[]): TPromise { + const treeItemsPromises: TPromise[] = []; for (const element of elements) { if (element) { if (this.extChildrenElementsMap.has(element)) { - return TPromise.wrapError(localize('treeView.duplicateElement', 'Element {0} is already registered', element)); + return TPromise.wrapError(localize('treeView.duplicateElement', 'Element {0} is already registered', element)); } const treeItem = this.massageTreeItem(this.dataProvider.getTreeItem(element)); if (treeItem) { @@ -152,7 +149,7 @@ class ExtHostTreeView extends Disposable { return TPromise.join(treeItemsPromises); } - private massageTreeItem(extensionTreeItem: vscode.TreeItem): TreeItem { + private massageTreeItem(extensionTreeItem: vscode.TreeItem): ITreeItem { if (!extensionTreeItem) { return null; } @@ -160,7 +157,7 @@ class ExtHostTreeView extends Disposable { return { handle: ++this._itemHandlePool, label: extensionTreeItem.label, - commandId: extensionTreeItem.command ? extensionTreeItem.command.command : void 0, + command: extensionTreeItem.command ? this.commands.toInternal(extensionTreeItem.command) : void 0, contextValue: extensionTreeItem.contextValue, icon, iconDark: this.getDarkIconPath(extensionTreeItem) || icon, diff --git a/src/vs/workbench/parts/views/browser/treeView.ts b/src/vs/workbench/parts/views/browser/treeView.ts index d642e54a3a7..fd8a1387fce 100644 --- a/src/vs/workbench/parts/views/browser/treeView.ts +++ b/src/vs/workbench/parts/views/browser/treeView.ts @@ -26,7 +26,8 @@ import { IProgressService } from 'vs/platform/progress/common/progress'; import { ITree, IDataSource, IRenderer, ContextMenuEvent } from 'vs/base/parts/tree/browser/tree'; import { IContextKeyService, IContextKey } from 'vs/platform/contextkey/common/contextkey'; import { ActionItem } from 'vs/base/browser/ui/actionbar/actionbar'; -import { ViewsRegistry, ITreeViewDataProvider, IViewOptions, ITreeItem, TreeItemCollapsibleState } from 'vs/workbench/parts/views/browser/views'; +import { ViewsRegistry, IViewOptions } from 'vs/workbench/parts/views/browser/views'; +import { ITreeViewDataProvider, ITreeItem, TreeItemCollapsibleState, TreeViewItemHandleArg } from 'vs/workbench/parts/views/common/views'; import { IExtensionService } from 'vs/platform/extensions/common/extensions'; import { CollapsibleState } from 'vs/base/browser/ui/splitview/splitview'; import { ICommandService } from 'vs/platform/commands/common/commands'; @@ -170,8 +171,8 @@ export class TreeView extends CollapsibleViewletView { private onSelection(): void { const selection: ITreeItem = this.tree.getSelection()[0]; if (selection) { - if (selection.commandId) { - this.commandService.executeCommand(selection.commandId, { treeViewId: this.id, treeItemHandle: selection.handle }); + if (selection.command) { + this.commandService.executeCommand(selection.command.id, ...(selection.command.arguments || [])); } } } @@ -338,7 +339,7 @@ class TreeController extends DefaultController { } }, - getActionsContext: () => ({ treeViewId: this.treeViewId, treeItemHandle: node.handle }), + getActionsContext: () => ({ $treeViewId: this.treeViewId, $treeItemHandle: node.handle }), actionRunner: new MultipleSelectionActionRunner(() => tree.getSelection()) }); diff --git a/src/vs/workbench/parts/views/browser/views.ts b/src/vs/workbench/parts/views/browser/views.ts index d5a69e9827d..7aa26d2466b 100644 --- a/src/vs/workbench/parts/views/browser/views.ts +++ b/src/vs/workbench/parts/views/browser/views.ts @@ -3,10 +3,10 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import { TPromise } from 'vs/base/common/winjs.base'; import Event, { Emitter } from 'vs/base/common/event'; import { IActionRunner } from 'vs/base/common/actions'; import { IViewletView as IView } from 'vs/workbench/browser/viewlet'; +import { ITreeViewDataProvider } from 'vs/workbench/parts/views/common/views'; export class ViewLocation { @@ -20,12 +20,6 @@ export class ViewLocation { } } -export enum TreeItemCollapsibleState { - None = 0, - Collapsed = 1, - Expanded = 2 -} - export interface IViewOptions { name: string; actionRunner: IActionRunner; @@ -52,35 +46,6 @@ export interface IViewDescriptor { } -export interface ITreeItem { - - handle: number; - - label: string; - - icon?: string; - - iconDark?: string; - - contextValue?: string; - - commandId?: string; - - children?: ITreeItem[]; - - collapsibleState?: TreeItemCollapsibleState; -} - -export interface ITreeViewDataProvider { - - onDidChange: Event; - - getElements(): TPromise; - - getChildren(element: ITreeItem): TPromise; - -} - export interface IViewsRegistry { readonly onViewsRegistered: Event; diff --git a/src/vs/workbench/parts/views/common/views.ts b/src/vs/workbench/parts/views/common/views.ts new file mode 100644 index 00000000000..22eac5bfe1b --- /dev/null +++ b/src/vs/workbench/parts/views/common/views.ts @@ -0,0 +1,48 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import { TPromise } from 'vs/base/common/winjs.base'; +import Event from 'vs/base/common/event'; +import { Command } from 'vs/editor/common/modes'; + +export type TreeViewItemHandleArg = { + $treeViewId: string, + $treeItemHandle: number +}; + +export enum TreeItemCollapsibleState { + None = 0, + Collapsed = 1, + Expanded = 2 +} + +export interface ITreeItem { + + handle: number; + + label: string; + + icon?: string; + + iconDark?: string; + + contextValue?: string; + + command?: Command; + + children?: ITreeItem[]; + + collapsibleState?: TreeItemCollapsibleState; +} + +export interface ITreeViewDataProvider { + + onDidChange: Event; + + getElements(): TPromise; + + getChildren(element: ITreeItem): TPromise; + +} \ No newline at end of file -- GitLab From e282c64283e64de7277e34f11ef58aa0d9e11220 Mon Sep 17 00:00:00 2001 From: isidor Date: Wed, 31 May 2017 12:51:00 +0200 Subject: [PATCH 0340/1347] debug actions widget: more precise centering fixes #27566 --- .../workbench/parts/debug/browser/debugActionsWidget.ts | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/vs/workbench/parts/debug/browser/debugActionsWidget.ts b/src/vs/workbench/parts/debug/browser/debugActionsWidget.ts index 7afe47c4c78..44b9db45be3 100644 --- a/src/vs/workbench/parts/debug/browser/debugActionsWidget.ts +++ b/src/vs/workbench/parts/debug/browser/debugActionsWidget.ts @@ -114,7 +114,8 @@ export class DebugActionsWidget extends Themable implements IWorkbenchContributi const mouseClickEvent = new StandardMouseEvent(event); if (mouseClickEvent.detail === 2) { // double click on debug bar centers it again #8250 - this.setXCoordinate(0.5 * window.innerWidth); + const widgetWidth = this.$el.getHTMLElement().clientWidth; + this.setXCoordinate(0.5 * window.innerWidth - 0.5 * widgetWidth); this.storePosition(); } }); @@ -172,11 +173,12 @@ export class DebugActionsWidget extends Themable implements IWorkbenchContributi if (!this.isVisible) { return; } + const widgetWidth = this.$el.getHTMLElement().clientWidth; if (x === undefined) { - x = parseFloat(this.storageService.get(DEBUG_ACTIONS_WIDGET_POSITION_KEY, StorageScope.WORKSPACE, '0.5')) * window.innerWidth; + const positionPercentage = this.storageService.get(DEBUG_ACTIONS_WIDGET_POSITION_KEY, StorageScope.WORKSPACE); + x = positionPercentage !== undefined ? parseFloat(positionPercentage) * window.innerWidth : (0.5 * window.innerWidth - 0.5 * widgetWidth); } - const widgetWidth = this.$el.getHTMLElement().clientWidth; x = Math.max(0, Math.min(x, window.innerWidth - widgetWidth)); // do not allow the widget to overflow on the right this.$el.style('left', `${x}px`); } -- GitLab From 9dea8acdc0577cf5566a52fa3587e259caece12a Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Wed, 31 May 2017 12:51:29 +0200 Subject: [PATCH 0341/1347] Fix #27529 --- src/vs/vscode.proposed.d.ts | 21 ++++++++++++------- src/vs/workbench/api/node/extHost.api.impl.ts | 1 + src/vs/workbench/api/node/extHostTypes.ts | 11 ++++++++++ 3 files changed, 25 insertions(+), 8 deletions(-) diff --git a/src/vs/vscode.proposed.d.ts b/src/vs/vscode.proposed.d.ts index ea64b766b66..7bc2d682391 100644 --- a/src/vs/vscode.proposed.d.ts +++ b/src/vs/vscode.proposed.d.ts @@ -47,27 +47,26 @@ declare module 'vscode' { getChildren(element?: T): ProviderResult; } - export interface TreeItem { + export class TreeItem { /** * A human-readable string describing this item */ - readonly label: string; + label: string; /** * The icon path for the tree item */ - readonly iconPath?: string | Uri | { light: string | Uri; dark: string | Uri }; + iconPath?: string | Uri | { light: string | Uri; dark: string | Uri }; /** - * The [command](#Command) which should be run when the tree item - * is selected. This command is called with the model representing this item as first argument. + * The [command](#Command) which should be run when the tree item is selected. */ - readonly command?: Command; + command?: Command; /** * [TreeItemCollapsibleState](#TreeItemCollapsibleState) of the tree item. */ - readonly collapsibleState?: TreeItemCollapsibleState; + collapsibleState?: TreeItemCollapsibleState; /** * Context value of the tree item. This can be used to contribute item specific actions in the tree. @@ -87,7 +86,13 @@ declare module 'vscode' { * ``` * This will show action `extension.deleteFolder` only for items with `contextValue` is `folder`. */ - readonly contextValue?: string; + contextValue?: string; + + /** + * @param label A human-readable string describing this item + * @param collapsibleState [TreeItemCollapsibleState](#TreeItemCollapsibleState) of the tree item. Default is [TreeItemCollapsibleState.None](#TreeItemCollapsibleState.None) + */ + constructor(label: string, collapsibleState?: TreeItemCollapsibleState); } /** diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index 0d14189f2a5..a859a1369fe 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -535,6 +535,7 @@ export function createApiFactory( WorkspaceEdit: extHostTypes.WorkspaceEdit, ProgressLocation: extHostTypes.ProgressLocation, TreeItemCollapsibleState: extHostTypes.TreeItemCollapsibleState, + TreeItem: extHostTypes.TreeItem, ThemeColor: extHostTypes.ThemeColor, // functions TaskRevealKind: extHostTypes.TaskRevealKind, diff --git a/src/vs/workbench/api/node/extHostTypes.ts b/src/vs/workbench/api/node/extHostTypes.ts index ef7f35e2a7e..e2967887266 100644 --- a/src/vs/workbench/api/node/extHostTypes.ts +++ b/src/vs/workbench/api/node/extHostTypes.ts @@ -1297,6 +1297,17 @@ export enum ProgressLocation { Window = 10, } +export class TreeItem { + + iconPath?: string | Uri | { light: string | Uri; dark: string | Uri }; + command?: vscode.Command; + contextValue?: string; + + constructor(public label: string, public collapsibleState: vscode.TreeItemCollapsibleState = TreeItemCollapsibleState.None) { + } + +} + export enum TreeItemCollapsibleState { None = 0, Collapsed = 1, -- GitLab From 388f4ff36209fe194a1663aec73bc2563dc6e596 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 31 May 2017 12:57:03 +0200 Subject: [PATCH 0342/1347] Fixes #27720. --- src/vs/workbench/parts/debug/browser/linkDetector.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/debug/browser/linkDetector.ts b/src/vs/workbench/parts/debug/browser/linkDetector.ts index d2fd4efab48..f79930d072e 100644 --- a/src/vs/workbench/parts/debug/browser/linkDetector.ts +++ b/src/vs/workbench/parts/debug/browser/linkDetector.ts @@ -48,7 +48,7 @@ export class LinkDetector { let resource: uri = null; try { resource = (match && !strings.startsWith(match[0], 'http')) - && (match[2] || strings.startsWith(match[0], '/') ? uri.file(match[1]) : this.contextService.toResource(match[1])); + && (match[2] || strings.startsWith(match[1], '/') ? uri.file(match[1]) : this.contextService.toResource(match[1])); } catch (e) { } if (!resource) { -- GitLab From b6041fbc206f98726520b5f82b0150ca8e4bd1d8 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 31 May 2017 13:03:27 +0200 Subject: [PATCH 0343/1347] Fixes #27613: symbolic key code names should always get the info message explaining what characters they produce --- .../parts/preferences/browser/keybindingsEditorContribution.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.ts b/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.ts index d5aaccbae45..3f560219cfe 100644 --- a/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.ts +++ b/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.ts @@ -236,6 +236,9 @@ export class KeybindingEditorDecorationsRenderer extends Disposable { if (!resolvedKeybinding.isWYSIWYG()) { return this._createDecoration(false, resolvedKeybinding.getLabel(), model, value); } + if (/abnt_|oem_/.test(value.value)) { + return this._createDecoration(false, resolvedKeybinding.getLabel(), model, value); + } const expectedUserSettingsLabel = resolvedKeybinding.getUserSettingsLabel(); if (!KeybindingEditorDecorationsRenderer._userSettingsFuzzyEquals(value.value, expectedUserSettingsLabel)) { return this._createDecoration(false, resolvedKeybinding.getLabel(), model, value); -- GitLab From c78ebcb2f48347ed20e8a88852207b49fc7ba3ba Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Wed, 31 May 2017 13:06:37 +0200 Subject: [PATCH 0344/1347] Fixes #27548: Annotation tasks break old 0.1.0 task behaviour --- src/vs/workbench/api/node/extHostTask.ts | 14 ++-- .../parts/tasks/browser/quickOpen.ts | 7 +- .../parts/tasks/common/taskConfiguration.ts | 69 +++++++++++---- src/vs/workbench/parts/tasks/common/tasks.ts | 24 +++--- .../tasks/electron-browser/jsonSchema_v1.ts | 45 ++++++---- .../electron-browser/task.contribution.ts | 84 ++++++++++++------- .../tasks/test/node/configuration.test.ts | 1 + 7 files changed, 155 insertions(+), 89 deletions(-) diff --git a/src/vs/workbench/api/node/extHostTask.ts b/src/vs/workbench/api/node/extHostTask.ts index 2306007194c..babbdf49a8a 100644 --- a/src/vs/workbench/api/node/extHostTask.ts +++ b/src/vs/workbench/api/node/extHostTask.ts @@ -4,6 +4,7 @@ *--------------------------------------------------------------------------------------------*/ 'use strict'; +import * as nls from 'vs/nls'; import { TPromise } from 'vs/base/common/winjs.base'; import * as UUID from 'vs/base/common/uuid'; import { asWinJsPromise } from 'vs/base/common/async'; @@ -308,13 +309,16 @@ namespace Tasks { if (command === void 0) { return undefined; } + let source = { + kind: TaskSystem.TaskSourceKind.Extension, + label: typeof task.source === 'string' ? task.source : extension.name, + detail: extension.id + }; + let label = nls.localize('task.label', '{0}: {1}', source.label, task.name); let result: TaskSystem.Task = { _id: uuidMap.getUUID(task.identifier), - _source: { - kind: TaskSystem.TaskSourceKind.Extension, - label: typeof task.source === 'string' ? task.source : extension.name, - detail: extension.id - }, + _source: source, + _label: label, name: task.name, identifier: task.identifier ? task.identifier : `${extension.id}.${task.name}`, group: types.TaskGroup.is(task.group) ? task.group : undefined, diff --git a/src/vs/workbench/parts/tasks/browser/quickOpen.ts b/src/vs/workbench/parts/tasks/browser/quickOpen.ts index e4208bafd3a..2b0eb83c769 100644 --- a/src/vs/workbench/parts/tasks/browser/quickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/quickOpen.ts @@ -13,21 +13,18 @@ import QuickOpen = require('vs/base/parts/quickopen/common/quickOpen'); import Model = require('vs/base/parts/quickopen/browser/quickOpenModel'); import { IQuickOpenService } from 'vs/platform/quickOpen/common/quickOpen'; -import { Task, TaskSourceKind, computeLabel } from 'vs/workbench/parts/tasks/common/tasks'; +import { Task, TaskSourceKind } from 'vs/workbench/parts/tasks/common/tasks'; import { ITaskService } from 'vs/workbench/parts/tasks/common/taskService'; import { ActionBarContributor, ContributableActionProvider } from 'vs/workbench/browser/actions'; export class TaskEntry extends Model.QuickOpenEntry { - private _label: string; - constructor(protected taskService: ITaskService, protected _task: Task, highlights: Model.IHighlight[] = []) { super(highlights); - this._label = computeLabel(_task); } public getLabel(): string { - return this._label; + return this.task._label; } public getAriaLabel(): string { diff --git a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts index 862419a7fea..bf17dd08930 100644 --- a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts +++ b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts @@ -301,6 +301,11 @@ export interface ExternalTaskRunnerConfiguration extends BaseTaskRunnerConfigura _runner?: string; + /** + * Determines the runner to use + */ + runner?: string; + /** * The config's version number */ @@ -341,7 +346,8 @@ function mergeProperty(target: T, source: T, key: K) { interface ParseContext { problemReporter: IProblemReporter; namedProblemMatchers: IStringDictionary; - isTermnial: boolean; + engine: Tasks.ExecutionEngine; + schemaVersion: Tasks.JsonSchemaVersion; } namespace CommandOptions { @@ -587,7 +593,7 @@ namespace CommandConfiguration { result.options = CommandOptions.from(config.options, context); if (result.options && result.options.shell === void 0 && isShellConfiguration) { result.options.shell = ShellConfiguration.from(config.isShellCommand as ShellConfiguration, context); - if (!context.isTermnial) { + if (context.engine !== Tasks.ExecutionEngine.Terminal) { context.problemReporter.warn(nls.localize('ConfigurationParser.noShell', 'Warning: shell configuration is only supported when executing tasks in the terminal.')); } } @@ -776,6 +782,7 @@ namespace TaskDescription { let annotatingTasks: Tasks.Task[] = []; let defaultBuildTask: { task: Tasks.Task; rank: number; } = { task: undefined, rank: -1 }; let defaultTestTask: { task: Tasks.Task; rank: number; } = { task: undefined, rank: -1 }; + let schema2_0_0: boolean = context.schemaVersion === Tasks.JsonSchemaVersion.V2_0_0; tasks.forEach((externalTask) => { let taskName = externalTask.taskName; if (!taskName) { @@ -792,6 +799,7 @@ namespace TaskDescription { let task: Tasks.Task = { _id: UUID.generateUuid(), _source: source, + _label: taskName, name: taskName, identifier: identifer, command @@ -835,7 +843,7 @@ namespace TaskDescription { if (problemMatchers) { task.problemMatchers = problemMatchers; } - if (context.isTermnial && isAnnotating(task)) { + if (schema2_0_0 && isAnnotating(task)) { mergeGlobalsIntoAnnnotation(task, globals); annotatingTasks.push(task); return; @@ -843,15 +851,15 @@ namespace TaskDescription { mergeGlobals(task, globals); fillDefaults(task); let addTask: boolean = true; - if (context.isTermnial && task.command && task.command.name && task.command.type === Tasks.CommandType.Shell && task.command.args && task.command.args.length > 0) { + if (context.engine === Tasks.ExecutionEngine.Terminal && task.command && task.command.name && task.command.type === Tasks.CommandType.Shell && task.command.args && task.command.args.length > 0) { if (hasUnescapedSpaces(task.command.name) || task.command.args.some(hasUnescapedSpaces)) { context.problemReporter.warn(nls.localize('taskConfiguration.shellArgs', 'Warning: the task \'{0}\' is a shell command and either the command name or one of its arguments has unescaped spaces. To ensure correct command line quoting please merge args into the command.', task.name)); } } - if (context.isTermnial) { + if (schema2_0_0) { if ((task.command === void 0 || task.command.name === void 0) && (task.dependsOn === void 0 || task.dependsOn.length === 0)) { context.problemReporter.error(nls.localize( - 'taskConfiguration.noCommandOrDependsOn', 'Error: the task \'{0}\' neither specifies a command or a dependsOn property. The task will be ignored. Its definition is:\n{1}', + 'taskConfiguration.noCommandOrDependsOn', 'Error: the task \'{0}\' neither specifies a command nor a dependsOn property. The task will be ignored. Its definition is:\n{1}', task.name, JSON.stringify(externalTask, undefined, 4) )); addTask = false; @@ -1094,19 +1102,43 @@ namespace Globals { export namespace ExecutionEngine { export function from(config: ExternalTaskRunnerConfiguration): Tasks.ExecutionEngine { - return isTerminalConfig(config) - ? Tasks.ExecutionEngine.Terminal - : isRunnerConfig(config) - ? Tasks.ExecutionEngine.Process - : Tasks.ExecutionEngine.Unknown; + let runner = config.runner || config._runner; + let result: Tasks.ExecutionEngine; + if (runner) { + switch (runner) { + case 'terminal': + result = Tasks.ExecutionEngine.Terminal; + break; + case 'process': + result = Tasks.ExecutionEngine.Process; + break; + } + } + let schemaVersion = JsonSchemaVersion.from(config); + if (schemaVersion === Tasks.JsonSchemaVersion.V0_1_0) { + return result || Tasks.ExecutionEngine.Process; + } else if (schemaVersion === Tasks.JsonSchemaVersion.V2_0_0) { + return Tasks.ExecutionEngine.Terminal; + } else { + throw new Error('Shouldn\'t happen.'); + } } - function isRunnerConfig(config: ExternalTaskRunnerConfiguration): boolean { - return (!config._runner || config._runner === 'program') && (config.version === '0.1.0' || !config.version); - } +} - function isTerminalConfig(config: ExternalTaskRunnerConfiguration): boolean { - return config._runner === 'terminal' || config.version === '2.0.0'; +export namespace JsonSchemaVersion { + + export function from(config: ExternalTaskRunnerConfiguration): Tasks.JsonSchemaVersion { + let version = config.version; + if (!version) { + return Tasks.JsonSchemaVersion.V2_0_0; + } + switch (version) { + case '0.1.0': + return Tasks.JsonSchemaVersion.V0_1_0; + default: + return Tasks.JsonSchemaVersion.V2_0_0; + } } } @@ -1130,13 +1162,15 @@ class ConfigurationParser { public run(fileConfig: ExternalTaskRunnerConfiguration): ParseResult { let engine = ExecutionEngine.from(fileConfig); + let schemaVersion = JsonSchemaVersion.from(fileConfig); if (engine === Tasks.ExecutionEngine.Terminal) { this.problemReporter.clearOutput(); } let context: ParseContext = { problemReporter: this.problemReporter, namedProblemMatchers: undefined, - isTermnial: engine === Tasks.ExecutionEngine.Terminal + engine, + schemaVersion, }; let taskParseResult = this.createTaskRunnerConfiguration(fileConfig, context); return { @@ -1177,6 +1211,7 @@ class ConfigurationParser { let task: Tasks.Task = { _id: UUID.generateUuid(), _source: TaskDescription.source, + _label: globals.command.name, name: globals.command.name, identifier: globals.command.name, group: Tasks.TaskGroup.Build, diff --git a/src/vs/workbench/parts/tasks/common/tasks.ts b/src/vs/workbench/parts/tasks/common/tasks.ts index b798e6314e5..0cc7270b723 100644 --- a/src/vs/workbench/parts/tasks/common/tasks.ts +++ b/src/vs/workbench/parts/tasks/common/tasks.ts @@ -4,7 +4,6 @@ *--------------------------------------------------------------------------------------------*/ 'use strict'; -import nls = require('vs/nls'); import * as Types from 'vs/base/common/types'; import { IExtensionDescription } from 'vs/platform/extensions/common/extensions'; @@ -183,6 +182,11 @@ export interface Task { */ _id: string; + /** + * The cached label. + */ + _label: string; + /** * Indicated the source of the task (e.g tasks.json or extension) */ @@ -241,20 +245,16 @@ export interface Task { } export enum ExecutionEngine { - Unknown = 0, - Terminal = 1, - Process = 2 + Process = 1, + Terminal = 2 +} + +export enum JsonSchemaVersion { + V0_1_0 = 1, + V2_0_0 = 2 } export interface TaskSet { tasks: Task[]; extension?: IExtensionDescription; -} - -export function computeLabel(task: Task): string { - if (task._source.kind === TaskSourceKind.Extension) { - return nls.localize('taskEntry.label', '{0}: {1}', task._source.label, task.name); - } else { - return task.name; - } } \ No newline at end of file diff --git a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.ts b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.ts index 24441e1eba0..af5ca29ae20 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.ts @@ -13,32 +13,41 @@ import commonSchema from './jsonSchemaCommon'; const schema: IJSONSchema = { oneOf: [ { - 'allOf': [ + allOf: [ { - 'type': 'object', - 'required': ['version'], - 'properties': { - 'version': { - 'type': 'string', - 'enum': ['0.1.0'], - 'description': nls.localize('JsonSchema.version', 'The config\'s version number') + type: 'object', + required: ['version'], + properties: { + version: { + type: 'string', + enum: ['0.1.0'], + description: nls.localize('JsonSchema.version', 'The config\'s version number') }, - 'windows': { - '$ref': '#/definitions/taskRunnerConfiguration', - 'description': nls.localize('JsonSchema.windows', 'Windows specific command configuration') + _runner: { + deprecationMessage: nls.localize('JsonSchema._runner', 'The runner has graduated. Use the offical runner property') }, - 'osx': { - '$ref': '#/definitions/taskRunnerConfiguration', - 'description': nls.localize('JsonSchema.mac', 'Mac specific command configuration') + runner: { + type: 'string', + enum: ['process', 'terminal'], + default: 'process', + description: nls.localize('JsonSchema.runner', 'Defines whether the task is executed as a process and the output is shown in the output window or inside the terminal.') }, - 'linux': { - '$ref': '#/definitions/taskRunnerConfiguration', - 'description': nls.localize('JsonSchema.linux', 'Linux specific command configuration') + windows: { + $ref: '#/definitions/taskRunnerConfiguration', + description: nls.localize('JsonSchema.windows', 'Windows specific command configuration') + }, + osx: { + $ref: '#/definitions/taskRunnerConfiguration', + description: nls.localize('JsonSchema.mac', 'Mac specific command configuration') + }, + linux: { + $ref: '#/definitions/taskRunnerConfiguration', + description: nls.localize('JsonSchema.linux', 'Linux specific command configuration') } } }, { - '$ref': '#/definitions/taskRunnerConfiguration' + $ref: '#/definitions/taskRunnerConfiguration' } ] } diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index 540ff68d8ca..f6a16bb6ba8 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -71,7 +71,7 @@ import { Scope, IActionBarRegistry, Extensions as ActionBarExtensions } from 'vs import { ITerminalService } from 'vs/workbench/parts/terminal/common/terminal'; import { ITaskSystem, ITaskResolver, ITaskSummary, ITaskExecuteResult, TaskExecuteKind, TaskError, TaskErrors, TaskSystemEvents } from 'vs/workbench/parts/tasks/common/taskSystem'; -import { Task, TaskSet, TaskGroup, ExecutionEngine, TaskSourceKind, computeLabel as computeTaskLabel } from 'vs/workbench/parts/tasks/common/tasks'; +import { Task, TaskSet, TaskGroup, ExecutionEngine, TaskSourceKind } from 'vs/workbench/parts/tasks/common/tasks'; import { ITaskService, TaskServiceEvents, ITaskProvider } from 'vs/workbench/parts/tasks/common/taskService'; import { templates as taskTemplates } from 'vs/workbench/parts/tasks/common/taskTemplates'; @@ -455,7 +455,7 @@ interface WorkspaceTaskResult { set: TaskSet; annotatingTasks: { byIdentifier: IStringDictionary; - byName: IStringDictionary; + byLabel: IStringDictionary; }; hasErrors: boolean; } @@ -547,7 +547,7 @@ class TaskService extends EventEmitter implements ITaskService { ? ExecutionEngine.Terminal : this._taskSystem instanceof ProcessTaskSystem ? ExecutionEngine.Process - : ExecutionEngine.Unknown; + : undefined; if (currentExecutionEngine !== this.getExecutionEngine()) { this.messageService.show(Severity.Info, nls.localize('TaskSystem.noHotSwap', 'Changing the task execution engine requires restarting VS Code. The change is ignored.')); } @@ -709,7 +709,7 @@ class TaskService extends EventEmitter implements ITaskService { return TPromise.as(undefined); } let fileConfig = configuration.config; - let customize = { taskName: computeTaskLabel(task), identifier: task.identifier }; + let customize = { taskName: task._label, identifier: task.identifier }; if (!fileConfig) { fileConfig = { version: '2.0.0', @@ -746,7 +746,7 @@ class TaskService extends EventEmitter implements ITaskService { sets.forEach((set) => { set.tasks.forEach((task) => { uuidMap[task._id] = task; - labelMap[computeTaskLabel(task)] = task; + labelMap[task._label] = task; identifierMap[task.identifier] = task; if (group && task.group === group) { if (task._source.kind === TaskSourceKind.Workspace) { @@ -779,6 +779,7 @@ class TaskService extends EventEmitter implements ITaskService { let task: Task = { _id: id, _source: { kind: TaskSourceKind.Generic, label: 'generic' }, + _label: id, name: id, identifier: id, dependsOn: extensionTasks.map(task => task._id), @@ -794,7 +795,7 @@ class TaskService extends EventEmitter implements ITaskService { sets.forEach((set) => { set.tasks.forEach((task) => { - labelMap[computeTaskLabel(task)] = task; + labelMap[task._label] = task; identifierMap[task.identifier] = task; }); }); @@ -922,10 +923,11 @@ class TaskService extends EventEmitter implements ITaskService { for (let set of result) { for (let task of set.tasks) { if (annotatingTasks) { - let annotatingTask = annotatingTasks.byIdentifier[task.identifier] || annotatingTasks.byName[task.name]; + let annotatingTask = annotatingTasks.byIdentifier[task.identifier] || annotatingTasks.byLabel[task._label]; if (annotatingTask) { TaskConfig.mergeTasks(task, annotatingTask); task.name = annotatingTask.name; + task._label = annotatingTask._label; task._source.kind = TaskSourceKind.Workspace; continue; } @@ -936,6 +938,7 @@ class TaskService extends EventEmitter implements ITaskService { TaskConfig.mergeTasks(task, legacyAnnotatingTask); task._source.kind = TaskSourceKind.Workspace; task.name = legacyAnnotatingTask.name; + task._label = legacyAnnotatingTask._label; workspaceTasksToDelete.push(legacyAnnotatingTask); continue; } @@ -1015,29 +1018,36 @@ class TaskService extends EventEmitter implements ITaskService { } if (config) { let engine = TaskConfig.ExecutionEngine.from(config); - if (engine === ExecutionEngine.Process && this.hasDetectorSupport(config)) { - configPromise = new ProcessRunnerDetector(this.fileService, this.contextService, this.configurationResolverService, config).detect(true).then((value): WorkspaceConfigurationResult => { - let hasErrors = this.printStderr(value.stderr); - let detectedConfig = value.config; - if (!detectedConfig) { - return { config, hasErrors }; - } - let result: TaskConfig.ExternalTaskRunnerConfiguration = Objects.clone(config); - let configuredTasks: IStringDictionary = Object.create(null); - if (!result.tasks) { - if (detectedConfig.tasks) { - result.tasks = detectedConfig.tasks; + if (engine === ExecutionEngine.Process) { + if (this.hasDetectorSupport(config)) { + configPromise = new ProcessRunnerDetector(this.fileService, this.contextService, this.configurationResolverService, config).detect(true).then((value): WorkspaceConfigurationResult => { + let hasErrors = this.printStderr(value.stderr); + let detectedConfig = value.config; + if (!detectedConfig) { + return { config, hasErrors }; } - } else { - result.tasks.forEach(task => configuredTasks[task.taskName] = task); - detectedConfig.tasks.forEach((task) => { - if (!configuredTasks[task.taskName]) { - result.tasks.push(task); + let result: TaskConfig.ExternalTaskRunnerConfiguration = Objects.clone(config); + let configuredTasks: IStringDictionary = Object.create(null); + if (!result.tasks) { + if (detectedConfig.tasks) { + result.tasks = detectedConfig.tasks; } - }); - } - return { config: result, hasErrors }; - }); + } else { + result.tasks.forEach(task => configuredTasks[task.taskName] = task); + detectedConfig.tasks.forEach((task) => { + if (!configuredTasks[task.taskName]) { + result.tasks.push(task); + } + }); + } + return { config: result, hasErrors }; + }); + } else { + configPromise = new ProcessRunnerDetector(this.fileService, this.contextService, this.configurationResolverService).detect(true).then((value) => { + let hasErrors = this.printStderr(value.stderr); + return { config: value.config, hasErrors }; + }); + } } else { configPromise = TPromise.as({ config, hasErrors: false }); } @@ -1061,16 +1071,16 @@ class TaskService extends EventEmitter implements ITaskService { problemReporter.fatal(nls.localize('TaskSystem.configurationErrors', 'Error: the provided task configuration has validation errors and can\'t not be used. Please correct the errors first.')); return { set: undefined, annotatingTasks: undefined, hasErrors }; } - let annotatingTasks: { byIdentifier: IStringDictionary; byName: IStringDictionary; }; + let annotatingTasks: { byIdentifier: IStringDictionary; byLabel: IStringDictionary; }; if (parseResult.annotatingTasks && parseResult.annotatingTasks.length > 0) { annotatingTasks = { byIdentifier: Object.create(null), - byName: Object.create(null) + byLabel: Object.create(null) }; for (let task of parseResult.annotatingTasks) { annotatingTasks.byIdentifier[task.identifier] = task; - if (task.name) { - annotatingTasks.byName[task.name] = task; + if (task._label) { + annotatingTasks.byLabel[task._label] = task; } } } @@ -1087,6 +1097,16 @@ class TaskService extends EventEmitter implements ITaskService { return TaskConfig.ExecutionEngine.from(config); } + /* + private getJsonSchemaVersion(): JsonSchemaVersion { + let { config } = this.getConfiguration(); + if (!config) { + return JsonSchemaVersion.V2_0_0; + } + return TaskConfig.JsonSchemaVersion.from(config); + } + */ + private getConfiguration(): { config: TaskConfig.ExternalTaskRunnerConfiguration; hasParseErrors: boolean } { let result = this.configurationService.getConfiguration('tasks'); if (!result) { diff --git a/src/vs/workbench/parts/tasks/test/node/configuration.test.ts b/src/vs/workbench/parts/tasks/test/node/configuration.test.ts index c958d68336b..bd75eb83f01 100644 --- a/src/vs/workbench/parts/tasks/test/node/configuration.test.ts +++ b/src/vs/workbench/parts/tasks/test/node/configuration.test.ts @@ -145,6 +145,7 @@ class TaskBuilder { this.result = { _id: name, _source: { kind: Tasks.TaskSourceKind.Workspace, label: 'workspace' }, + _label: name, identifier: name, name: name, command: this.commandBuilder.result, -- GitLab From 83001adc615e261c1d9844c4ad9208f1beef0d79 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Wed, 31 May 2017 13:17:54 +0200 Subject: [PATCH 0345/1347] More work on #27581 --- src/vs/vscode.d.ts | 4 ++-- src/vs/workbench/api/node/extHostTask.ts | 4 ++-- src/vs/workbench/api/node/extHostTypes.ts | 12 +++++----- .../parts/tasks/common/taskConfiguration.ts | 22 +++++++++---------- src/vs/workbench/parts/tasks/common/tasks.ts | 2 +- .../electron-browser/terminalTaskSystem.ts | 12 +++++----- .../parts/tasks/node/processTaskSystem.ts | 4 ++-- .../tasks/test/node/configuration.test.ts | 4 ++-- 8 files changed, 32 insertions(+), 32 deletions(-) diff --git a/src/vs/vscode.d.ts b/src/vs/vscode.d.ts index d7682428116..4e5e206c8af 100644 --- a/src/vs/vscode.d.ts +++ b/src/vs/vscode.d.ts @@ -3700,7 +3700,7 @@ declare module 'vscode' { /** * The terminal behavior. Defaults to an empty object literal. */ - terminal: TaskTerminalBehavior; + terminalBehavior: TaskTerminalBehavior; /** * The problem matchers attached to the task. Defaults to an empty @@ -3832,7 +3832,7 @@ declare module 'vscode' { /** * The terminal behavior. Defaults to an empty object literal. */ - terminal: TaskTerminalBehavior; + terminalBehavior: TaskTerminalBehavior; /** * The problem matchers attached to the task. Defaults to an empty diff --git a/src/vs/workbench/api/node/extHostTask.ts b/src/vs/workbench/api/node/extHostTask.ts index babbdf49a8a..b1febc8eb3d 100644 --- a/src/vs/workbench/api/node/extHostTask.ts +++ b/src/vs/workbench/api/node/extHostTask.ts @@ -338,7 +338,7 @@ namespace Tasks { name: value.process, args: Strings.from(value.args), type: TaskSystem.CommandType.Process, - terminal: TerminalBehaviour.from(value.terminal) + terminalBehavior: TerminalBehaviour.from(value.terminalBehavior) }; if (value.options) { result.options = CommandOptions.from(value.options); @@ -353,7 +353,7 @@ namespace Tasks { let result: TaskSystem.CommandConfiguration = { name: value.commandLine, type: TaskSystem.CommandType.Shell, - terminal: TerminalBehaviour.from(value.terminal) + terminalBehavior: TerminalBehaviour.from(value.terminalBehavior) }; if (value.options) { result.options = CommandOptions.from(value.options); diff --git a/src/vs/workbench/api/node/extHostTypes.ts b/src/vs/workbench/api/node/extHostTypes.ts index e2967887266..34a86f3e017 100644 --- a/src/vs/workbench/api/node/extHostTypes.ts +++ b/src/vs/workbench/api/node/extHostTypes.ts @@ -1045,7 +1045,7 @@ export class BaseTask { private _isBackground: boolean; private _source: string; private _group: string; - private _terminal: vscode.TaskTerminalBehavior; + private _terminalBehavior: vscode.TaskTerminalBehavior; constructor(name: string, problemMatchers: string[]) { if (typeof name !== 'string') { @@ -1054,7 +1054,7 @@ export class BaseTask { this._name = name; this._problemMatchers = problemMatchers || []; this._isBackground = false; - this._terminal = Object.create(null); + this._terminalBehavior = Object.create(null); } get identifier(): string { @@ -1116,15 +1116,15 @@ export class BaseTask { this._group = value; } - get terminal(): vscode.TaskTerminalBehavior { - return this._terminal; + get terminalBehavior(): vscode.TaskTerminalBehavior { + return this._terminalBehavior; } - set terminal(value: vscode.TaskTerminalBehavior) { + set terminalBehavior(value: vscode.TaskTerminalBehavior) { if (value === void 0 || value === null) { value = Object.create(null); } - this._terminal = value; + this._terminalBehavior = value; } get problemMatchers(): string[] { diff --git a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts index bf17dd08930..08a0477c753 100644 --- a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts +++ b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts @@ -568,7 +568,7 @@ namespace CommandConfiguration { let result: Tasks.CommandConfiguration = { name: undefined, type: undefined, - terminal: undefined + terminalBehavior: undefined }; if (Types.isString(config.command)) { result.name = config.command; @@ -600,7 +600,7 @@ namespace CommandConfiguration { } let terminal = TerminalBehavior.from(config, context); if (terminal) { - result.terminal = terminal; + result.terminalBehavior = terminal; } if (Types.isString(config.taskSelector)) { result.taskSelector = config.taskSelector; @@ -609,12 +609,12 @@ namespace CommandConfiguration { } export function isEmpty(value: Tasks.CommandConfiguration): boolean { - return !value || value.name === void 0 && value.type === void 0 && value.args === void 0 && CommandOptions.isEmpty(value.options) && value.terminal === void 0; + return !value || value.name === void 0 && value.type === void 0 && value.args === void 0 && CommandOptions.isEmpty(value.options) && value.terminalBehavior === void 0; } export function onlyTerminalBehaviour(value: Tasks.CommandConfiguration): boolean { return value && - value.terminal && (value.terminal.echo !== void 0 || value.terminal.reveal !== void 0) && + value.terminalBehavior && (value.terminalBehavior.echo !== void 0 || value.terminalBehavior.reveal !== void 0) && value.name === void 0 && value.type === void 0 && value.args === void 0 && CommandOptions.isEmpty(value.options); } @@ -632,7 +632,7 @@ namespace CommandConfiguration { target.type = source.type; } - target.terminal = TerminalBehavior.merge(target.terminal, source.terminal); + target.terminalBehavior = TerminalBehavior.merge(target.terminalBehavior, source.terminalBehavior); mergeProperty(target, source, 'taskSelector'); if (source.args !== void 0) { if (target.args === void 0) { @@ -652,7 +652,7 @@ namespace CommandConfiguration { if (value.name !== void 0 && value.type === void 0) { value.type = Tasks.CommandType.Process; } - value.terminal = TerminalBehavior.fillDefault(value.terminal); + value.terminalBehavior = TerminalBehavior.fillDefault(value.terminalBehavior); if (value.args === void 0) { value.args = EMPTY_ARRAY; } @@ -669,8 +669,8 @@ namespace CommandConfiguration { if (value.options) { CommandOptions.freeze(value.options); } - if (value.terminal) { - TerminalBehavior.freeze(value.terminal); + if (value.terminalBehavior) { + TerminalBehavior.freeze(value.terminalBehavior); } } } @@ -793,7 +793,7 @@ namespace TaskDescription { let command: Tasks.CommandConfiguration = externalTask.command !== void 0 ? CommandConfiguration.from(externalTask, context) : externalTask.echoCommand !== void 0 - ? { name: undefined, type: undefined, terminal: CommandConfiguration.TerminalBehavior.from(externalTask, context) } + ? { name: undefined, type: undefined, terminalBehavior: CommandConfiguration.TerminalBehavior.from(externalTask, context) } : undefined; let identifer = Types.isString(externalTask.identifier) ? externalTask.identifier : taskName; let task: Tasks.Task = { @@ -940,9 +940,9 @@ namespace TaskDescription { // The globals can have a echo set which would override the local echo // Saves the need of a additional fill method. But might be necessary // at some point. - let oldTerminal = Objects.clone(task.command.terminal); + let oldTerminal = Objects.clone(task.command.terminalBehavior); CommandConfiguration.merge(task.command, globals.command); - task.command.terminal = oldTerminal; + task.command.terminalBehavior = oldTerminal; } } // promptOnClose is inferred from isBackground if available diff --git a/src/vs/workbench/parts/tasks/common/tasks.ts b/src/vs/workbench/parts/tasks/common/tasks.ts index 0cc7270b723..ab09f644078 100644 --- a/src/vs/workbench/parts/tasks/common/tasks.ts +++ b/src/vs/workbench/parts/tasks/common/tasks.ts @@ -141,7 +141,7 @@ export interface CommandConfiguration { /** * Describes how the terminal is supposed to behave. */ - terminal: TerminalBehavior; + terminalBehavior: TerminalBehavior; } export namespace TaskGroup { diff --git a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts index 04591b40b55..37cef5b6c85 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts @@ -134,7 +134,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { public run(task: Task, resolver: ITaskResolver, trigger: string = Triggers.command): ITaskExecuteResult { let terminalData = this.activeTasks[task._id]; if (terminalData && terminalData.promise) { - let reveal = task.command.terminal.reveal; + let reveal = task.command.terminalBehavior.reveal; if (reveal === RevealKind.Always) { terminalData.terminal.setVisible(true); } @@ -289,7 +289,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { this.emit(TaskSystemEvents.Inactive, event); } eventCounter = 0; - let reveal = task.command.terminal.reveal; + let reveal = task.command.terminalBehavior.reveal; if (exitCode && exitCode === 1 && watchingProblemMatcher.numberOfMatches === 0 && reveal !== RevealKind.Never) { this.terminalService.setActiveInstance(terminal); this.terminalService.showPanel(false); @@ -332,7 +332,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { }); } this.terminalService.setActiveInstance(terminal); - if (task.command.terminal.reveal === RevealKind.Always) { + if (task.command.terminalBehavior.reveal === RevealKind.Always) { this.terminalService.showPanel(false); } this.activeTasks[task._id] = { terminal, task, promise }; @@ -369,7 +369,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { let { command, args } = this.resolveCommandAndArgs(task); let terminalName = nls.localize('TerminalTaskSystem.terminalName', 'Task - {0}', task.name); let waitOnExit: boolean | string = false; - if (task.command.terminal.reveal !== RevealKind.Never || !task.isBackground) { + if (task.command.terminalBehavior.reveal !== RevealKind.Never || !task.isBackground) { waitOnExit = nls.localize('reuseTerminal', 'Terminal will be reused by tasks, press any key to close it.'); }; let shellLaunchConfig: IShellLaunchConfig = undefined; @@ -422,7 +422,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { }); shellArgs.push(commandLine); shellLaunchConfig.args = Platform.isWindows ? shellArgs.join(' ') : shellArgs; - if (task.command.terminal.echo) { + if (task.command.terminalBehavior.echo) { shellLaunchConfig.initialText = `> ${commandLine}`; } } else { @@ -436,7 +436,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { args, waitOnExit }; - if (task.command.terminal.echo) { + if (task.command.terminalBehavior.echo) { let getArgsToEcho = (args: string | string[]): string => { if (!args || args.length === 0) { return ''; diff --git a/src/vs/workbench/parts/tasks/node/processTaskSystem.ts b/src/vs/workbench/parts/tasks/node/processTaskSystem.ts index 9f4d55278f5..de4bc36b7f5 100644 --- a/src/vs/workbench/parts/tasks/node/processTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/node/processTaskSystem.ts @@ -179,12 +179,12 @@ export class ProcessTaskSystem extends EventEmitter implements ITaskSystem { this.childProcess = new LineProcess(command, args, commandConfig.type === CommandType.Shell, this.resolveOptions(commandConfig.options)); telemetryEvent.command = this.childProcess.getSanitizedCommand(); // we have no problem matchers defined. So show the output log - let reveal = task.command.terminal.reveal; + let reveal = task.command.terminalBehavior.reveal; if (reveal === RevealKind.Always || (reveal === RevealKind.Silent && task.problemMatchers.length === 0)) { this.showOutput(); } - if (commandConfig.terminal.echo) { + if (commandConfig.terminalBehavior.echo) { let prompt: string = Platform.isWindows ? '>' : '$'; this.log(`running command${prompt} ${command} ${args.join(' ')}`); } diff --git a/src/vs/workbench/parts/tasks/test/node/configuration.test.ts b/src/vs/workbench/parts/tasks/test/node/configuration.test.ts index bd75eb83f01..27dcb251cd0 100644 --- a/src/vs/workbench/parts/tasks/test/node/configuration.test.ts +++ b/src/vs/workbench/parts/tasks/test/node/configuration.test.ts @@ -101,7 +101,7 @@ class CommandConfigurationBuilder { options: { cwd: '${workspaceRoot}' }, - terminal: this.terminalBuilder.result + terminalBehavior: this.terminalBuilder.result }; } @@ -432,7 +432,7 @@ function assertTask(actual: Tasks.Task, expected: Tasks.Task) { function assertCommandConfiguration(actual: Tasks.CommandConfiguration, expected: Tasks.CommandConfiguration) { assert.strictEqual(typeof actual, typeof expected); if (actual && expected) { - assertTerminalBehavior(actual.terminal, expected.terminal); + assertTerminalBehavior(actual.terminalBehavior, expected.terminalBehavior); assert.strictEqual(actual.name, expected.name, 'name'); assert.strictEqual(actual.type, expected.type, 'task type'); assert.deepEqual(actual.args, expected.args, 'args'); -- GitLab From 8d6fd510b8d6ea23ad7e319b8abb129bf3479419 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 31 May 2017 13:28:56 +0200 Subject: [PATCH 0346/1347] Fixes #27459: Test first/last character in match if they are word separators besides the before/after characters --- src/vs/editor/common/model/textModelSearch.ts | 54 +++++++++++++++---- .../test/common/model/textModelSearch.test.ts | 26 +++++++++ 2 files changed, 70 insertions(+), 10 deletions(-) diff --git a/src/vs/editor/common/model/textModelSearch.ts b/src/vs/editor/common/model/textModelSearch.ts index af265935776..867d52204e5 100644 --- a/src/vs/editor/common/model/textModelSearch.ts +++ b/src/vs/editor/common/model/textModelSearch.ts @@ -405,23 +405,57 @@ export class TextModelSearch { } } -function isValidMatch(wordSeparators: WordCharacterClassifier, text: string, textLength: number, matchStartIndex: number, matchLength: number): boolean { +function leftIsWordBounday(wordSeparators: WordCharacterClassifier, text: string, textLength: number, matchStartIndex: number, matchLength: number): boolean { + if (matchStartIndex === 0) { + // Match starts at start of string + return true; + } - if (matchStartIndex - 1 >= 0) { - const charBefore = text.charCodeAt(matchStartIndex - 1); - if (wordSeparators.get(charBefore) === WordCharacterClass.Regular) { - return false; + const charBefore = text.charCodeAt(matchStartIndex - 1); + if (wordSeparators.get(charBefore) !== WordCharacterClass.Regular) { + // The character before the match is a word separator + return true; + } + + if (matchLength > 0) { + const firstCharInMatch = text.charCodeAt(matchStartIndex); + if (wordSeparators.get(firstCharInMatch) !== WordCharacterClass.Regular) { + // The first character inside the match is a word separator + return true; } } - if (matchStartIndex + matchLength < textLength) { - const charAfter = text.charCodeAt(matchStartIndex + matchLength); - if (wordSeparators.get(charAfter) === WordCharacterClass.Regular) { - return false; + return false; +} + +function rightIsWordBounday(wordSeparators: WordCharacterClassifier, text: string, textLength: number, matchStartIndex: number, matchLength: number): boolean { + if (matchStartIndex + matchLength === textLength) { + // Match ends at end of string + return true; + } + + const charAfter = text.charCodeAt(matchStartIndex + matchLength); + if (wordSeparators.get(charAfter) !== WordCharacterClass.Regular) { + // The character after the match is a word separator + return true; + } + + if (matchLength > 0) { + const lastCharInMatch = text.charCodeAt(matchStartIndex + matchLength - 1); + if (wordSeparators.get(lastCharInMatch) !== WordCharacterClass.Regular) { + // The last character in the match is a word separator + return true; } } - return true; + return false; +} + +function isValidMatch(wordSeparators: WordCharacterClassifier, text: string, textLength: number, matchStartIndex: number, matchLength: number): boolean { + return ( + leftIsWordBounday(wordSeparators, text, textLength, matchStartIndex, matchLength) + && rightIsWordBounday(wordSeparators, text, textLength, matchStartIndex, matchLength) + ); } class Searcher { diff --git a/src/vs/editor/test/common/model/textModelSearch.test.ts b/src/vs/editor/test/common/model/textModelSearch.test.ts index 274ce45b934..df67b81aa49 100644 --- a/src/vs/editor/test/common/model/textModelSearch.test.ts +++ b/src/vs/editor/test/common/model/textModelSearch.test.ts @@ -354,6 +354,32 @@ suite('TextModelSearch', () => { ); }); + test('issue #27459: Match whole words regression', () => { + assertFindMatches( + [ + 'this._register(this._textAreaInput.onKeyDown((e: IKeyboardEvent) => {', + ' this._viewController.emitKeyDown(e);', + '}));', + ].join('\n'), + '((e: ', false, false, USUAL_WORD_SEPARATORS, + [ + [1, 45, 1, 50] + ] + ); + }); + + test('issue #27594: Search results disappear', () => { + assertFindMatches( + [ + 'this.server.listen(0);', + ].join('\n'), + 'listen(', false, false, USUAL_WORD_SEPARATORS, + [ + [1, 13, 1, 20] + ] + ); + }); + test('findNextMatch without regex', () => { let model = TextModel.createFromString('line line one\nline two\nthree'); -- GitLab From eb76d7a88f9eef8188db2284afb657966414bb99 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 31 May 2017 13:38:46 +0200 Subject: [PATCH 0347/1347] Fixes #27699: Use default cursor on the screen reader status bar entry --- .../browser/parts/editor/media/editorstatus.css | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/src/vs/workbench/browser/parts/editor/media/editorstatus.css b/src/vs/workbench/browser/parts/editor/media/editorstatus.css index 5d33e7ae6fd..b7ff137ac26 100644 --- a/src/vs/workbench/browser/parts/editor/media/editorstatus.css +++ b/src/vs/workbench/browser/parts/editor/media/editorstatus.css @@ -12,17 +12,13 @@ .monaco-workbench .editor-statusbar-item > .editor-status-eol, .monaco-workbench .editor-statusbar-item > .editor-status-selection, .monaco-workbench .editor-statusbar-item > .editor-status-indentation, -.monaco-workbench .editor-statusbar-item > .editor-status-metadata { +.monaco-workbench .editor-statusbar-item > .editor-status-metadata, +.monaco-workbench .editor-statusbar-item > .editor-status-tabfocusmode, +.monaco-workbench .editor-statusbar-item > .editor-status-screenreadermode { padding: 0 5px 0 5px; } -.monaco-workbench .editor-statusbar-item > .editor-status-metadata { +.monaco-workbench .editor-statusbar-item > .editor-status-metadata, +.monaco-workbench > .part.statusbar > .statusbar-item > .editor-statusbar-item > a.editor-status-screenreadermode { cursor: default; } - -.monaco-workbench .editor-statusbar-item > .editor-status-tabfocusmode { - padding: 0 5px 0 5px; -} -.monaco-workbench .editor-statusbar-item > .editor-status-screenreadermode { - padding: 0 5px 0 5px; -} \ No newline at end of file -- GitLab From c212aeb70463e0aeea10ef4b706712b186bace4a Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 31 May 2017 14:07:05 +0200 Subject: [PATCH 0348/1347] Fixes #27550: Mention that the editor.multiCursorModifier setting influences Go To Definition and Open Link gestures --- src/vs/editor/common/config/commonEditorConfig.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/vs/editor/common/config/commonEditorConfig.ts b/src/vs/editor/common/config/commonEditorConfig.ts index 38eb78fc8b9..7d74da7a72d 100644 --- a/src/vs/editor/common/config/commonEditorConfig.ts +++ b/src/vs/editor/common/config/commonEditorConfig.ts @@ -329,7 +329,13 @@ const editorConfiguration: IConfigurationNode = { nls.localize('multiCursorModifier.alt', "Maps to `Alt` on Windows and Linux and to `Option` on OSX.") ], 'default': 'alt', - 'description': nls.localize('multiCursorModifier', "The modifier to be used to add multiple cursors with the mouse. `ctrlCmd` maps to `Control` on Windows and Linux and to `Command` on OSX") + 'description': nls.localize({ + key: 'multiCursorModifier', + comment: [ + '- `ctrlCmd` refers to a value the setting can take and should not be localized.', + '- `Control` and `Command` refer to the modifier keys Ctrl or Cmd on the keyboard and can be localized.' + ] + }, "The modifier to be used to add multiple cursors with the mouse. `ctrlCmd` maps to `Control` on Windows and Linux and to `Command` on OSX. The Go To Definition and Open Link mouse gestures will adapt such that they do not conflict with the multicursor modifier.") }, 'editor.quickSuggestions': { 'anyOf': [ -- GitLab From eade00613f46fdb119def35131d76f4bae262267 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 31 May 2017 14:21:55 +0200 Subject: [PATCH 0349/1347] cancel snippet mode when undo'ing to the 'before' state, fixes #27612 --- .../snippet/browser/snippetController2.ts | 16 ++++++++++++++-- .../test/browser/snippetController2.old.test.ts | 16 ++++++++-------- 2 files changed, 22 insertions(+), 10 deletions(-) diff --git a/src/vs/editor/contrib/snippet/browser/snippetController2.ts b/src/vs/editor/contrib/snippet/browser/snippetController2.ts index 4c210d851ac..96dd960845b 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetController2.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetController2.ts @@ -82,9 +82,9 @@ export class SnippetController2 { private readonly _hasNextTabstop: IContextKey; private readonly _hasPrevTabstop: IContextKey; - // private _snippet: SnippetSession; private _sessions = new SnippetSessions(); private _snippetListener: IDisposable[] = []; + private _modelVersionId: number; constructor( private readonly _editor: ICommonCodeEditor, @@ -122,7 +122,13 @@ export class SnippetController2 { const snippet = new SnippetSession(this._editor, template, overwriteBefore, overwriteAfter); const newLen = this._sessions.add(snippet); - snippet.insert(newLen > 1); + + if (newLen === 1) { + this._modelVersionId = this._editor.getModel().getAlternativeVersionId(); + snippet.insert(false); + } else { + snippet.insert(true); + } if (undoStopAfter) { this._editor.getModel().pushStackElement(); @@ -141,6 +147,12 @@ export class SnippetController2 { return; } + if (this._modelVersionId === this._editor.getModel().getAlternativeVersionId()) { + // undo until the 'before' state happened + // and makes use cancel snippet mode + return this.cancel(); + } + if (!this._sessions.hasPlaceholder) { // don't listen for selection changes and don't // update context keys when the snippet is plain text diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetController2.old.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetController2.old.test.ts index 1efa1b1a8c1..fc12236bd33 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetController2.old.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetController2.old.test.ts @@ -189,16 +189,16 @@ suite('SnippetController', () => { }); }); - // test('Stops when undoing', () => { - // snippetTest((editor, cursor, codeSnippet, snippetController) => { - // editor.setPosition({ lineNumber: 4, column: 2 }); - // snippetController.run(codeSnippet, 0, 0); + test('Stops when undoing', () => { + snippetTest((editor, cursor, codeSnippet, snippetController) => { + editor.setPosition({ lineNumber: 4, column: 2 }); + snippetController.insert(codeSnippet, 0, 0); - // editor.getModel().undo(); + editor.getModel().undo(); - // assert.equal(snippetController.isInSnippetMode(), false); - // }); - // }); + assert.equal(snippetController.isInSnippetMode(), false); + }); + }); test('Stops when moving cursor outside', () => { snippetTest((editor, cursor, codeSnippet, snippetController) => { -- GitLab From 48631d689f77bab489ba0d9ced197263c5d5447c Mon Sep 17 00:00:00 2001 From: isidor Date: Wed, 31 May 2017 14:36:00 +0200 Subject: [PATCH 0350/1347] Breakpoints/Call Stack: clicking on entry with column info jump to that column fixes #27598 --- src/vs/workbench/parts/debug/common/debugModel.ts | 2 +- src/vs/workbench/parts/debug/electron-browser/debugViewer.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/debug/common/debugModel.ts b/src/vs/workbench/parts/debug/common/debugModel.ts index 4b0a76db320..e82bdfd5f67 100644 --- a/src/vs/workbench/parts/debug/common/debugModel.ts +++ b/src/vs/workbench/parts/debug/common/debugModel.ts @@ -383,7 +383,7 @@ export class StackFrame implements IStackFrame { description: this.source.origin, options: { preserveFocus, - selection: { startLineNumber: this.range.startLineNumber, startColumn: 1 }, + selection: this.range, revealIfVisible: true, revealInCenterIfOutsideViewport: true, pinned: !preserveFocus diff --git a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts index ea989342bbb..e4eb230068f 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts @@ -1270,7 +1270,7 @@ export class BreakpointsController extends BaseDebugController { endColumn: breakpoint.endColumn } : { startLineNumber: breakpoint.lineNumber, - startColumn: 1 + startColumn: breakpoint.column || 1 }; this.editorService.openEditor({ -- GitLab From 8cf60f346cbd451d04531c2639c21798ed961a5e Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Wed, 31 May 2017 14:31:49 +0200 Subject: [PATCH 0351/1347] Fix #27670 --- src/vs/vscode.proposed.d.ts | 2 +- src/vs/workbench/api/node/extHostTreeViews.ts | 33 +++++++++++-------- 2 files changed, 21 insertions(+), 14 deletions(-) diff --git a/src/vs/vscode.proposed.d.ts b/src/vs/vscode.proposed.d.ts index 7bc2d682391..2e015db6753 100644 --- a/src/vs/vscode.proposed.d.ts +++ b/src/vs/vscode.proposed.d.ts @@ -36,7 +36,7 @@ declare module 'vscode' { * @param element The element for which [TreeItem](#TreeItem) representation is asked for. * @return [TreeItem](#TreeItem) representation of the element */ - getTreeItem(element: T): TreeItem; + getTreeItem(element: T): TreeItem | Thenable; /** * Get the children of `element` or root. diff --git a/src/vs/workbench/api/node/extHostTreeViews.ts b/src/vs/workbench/api/node/extHostTreeViews.ts index d94eabb4167..99e21c10c72 100644 --- a/src/vs/workbench/api/node/extHostTreeViews.ts +++ b/src/vs/workbench/api/node/extHostTreeViews.ts @@ -125,28 +125,35 @@ class ExtHostTreeView extends Disposable { } private processAndMapElements(elements: T[]): TPromise { - const treeItemsPromises: TPromise[] = []; - for (const element of elements) { - if (element) { - if (this.extChildrenElementsMap.has(element)) { - return TPromise.wrapError(localize('treeView.duplicateElement', 'Element {0} is already registered', element)); - } - const treeItem = this.massageTreeItem(this.dataProvider.getTreeItem(element)); + return TPromise.join( + elements.filter(element => !!element) + .map(element => { + if (this.extChildrenElementsMap.has(element)) { + return TPromise.wrapError(localize('treeView.duplicateElement', 'Element {0} is already registered', element)); + } + return this.resolveElement(element); + })) + .then(treeItems => treeItems.filter(treeItem => !!treeItem)); + } + + private resolveElement(element: T): TPromise { + return asWinJsPromise(() => this.dataProvider.getTreeItem(element)) + .then(extTreeItem => { + const treeItem = this.massageTreeItem(extTreeItem); if (treeItem) { this.itemHandlesMap.set(element, treeItem.handle); this.extElementsMap.set(treeItem.handle, element); if (treeItem.collapsibleState === TreeItemCollapsibleState.Expanded) { - treeItemsPromises.push(this.getChildren(treeItem.handle).then(children => { + return this.getChildren(treeItem.handle).then(children => { treeItem.children = children; return treeItem; - })); + }); } else { - treeItemsPromises.push(TPromise.as(treeItem)); + return treeItem; } } - } - } - return TPromise.join(treeItemsPromises); + return null; + }); } private massageTreeItem(extensionTreeItem: vscode.TreeItem): ITreeItem { -- GitLab From 05fc00ead2bb4f80fc41a82e6b7e1f4720adb1f0 Mon Sep 17 00:00:00 2001 From: isidor Date: Wed, 31 May 2017 14:59:15 +0200 Subject: [PATCH 0352/1347] debug: toString of OutputNameValueElement do not take name into account if it is not defined fixes #27523 --- src/vs/workbench/parts/debug/common/debugModel.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/debug/common/debugModel.ts b/src/vs/workbench/parts/debug/common/debugModel.ts index e82bdfd5f67..e036ea1bb08 100644 --- a/src/vs/workbench/parts/debug/common/debugModel.ts +++ b/src/vs/workbench/parts/debug/common/debugModel.ts @@ -96,7 +96,7 @@ export class OutputNameValueElement extends AbstractOutputElement implements IEx } public toString(): string { - return `${this.name}: ${this.value}`; + return this.name ? `${this.name}: ${this.value}` : this.value; } } -- GitLab From c4620deadf4240acfc11606e9afb45baaedfefb8 Mon Sep 17 00:00:00 2001 From: isidor Date: Wed, 31 May 2017 15:04:35 +0200 Subject: [PATCH 0353/1347] debug: save all before sending a custom restart request to be aligned with regular restart fixes #26844 --- src/vs/workbench/parts/debug/electron-browser/debugService.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugService.ts b/src/vs/workbench/parts/debug/electron-browser/debugService.ts index c54ba326fb5..87f7a74c5c4 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugService.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugService.ts @@ -893,7 +893,7 @@ export class DebugService implements debug.IDebugService { public restartProcess(process: debug.IProcess, restartData?: any): TPromise { if (process.session.capabilities.supportsRestartRequest) { - return process.session.custom('restart', null); + return this.textFileService.saveAll().then(() => process.session.custom('restart', null)); } const focusedProcess = this.viewModel.focusedProcess; const preserveFocus = focusedProcess && process.getId() === focusedProcess.getId(); -- GitLab From 4a38bdc1f577a538e09a1f501e6fc4464e8bac54 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Wed, 31 May 2017 15:16:40 +0200 Subject: [PATCH 0354/1347] First cut of a version converter --- .../parts/tasks/common/taskConfiguration.ts | 82 ++++++++++++++++++- 1 file changed, 80 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts index 08a0477c753..f39f7786efa 100644 --- a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts +++ b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts @@ -989,7 +989,7 @@ namespace TaskDescription { for (let i = 0; i < value.length; i++) { let ch = value.charAt(i); if (ch === ' ') { - if (i === 0 || value.charAt(i) !== '\\') { + if (i === 0 || value.charAt(i - 1) !== '\\') { return true; } } @@ -1236,4 +1236,82 @@ export function parse(configuration: ExternalTaskRunnerConfiguration, logger: IP export function mergeTasks(target: Tasks.Task, source: Tasks.Task): Tasks.Task { return TaskDescription.merge(target, source); -} \ No newline at end of file +} + +/* +class VersionConverter { + constructor(private problemReporter: IProblemReporter) { + } + + public convert(fromConfig: ExternalTaskRunnerConfiguration): ExternalTaskRunnerConfiguration { + let result: ExternalTaskRunnerConfiguration; + result.version = '2.0.0'; + if (Array.isArray(fromConfig.tasks)) { + + } else { + result.tasks = []; + } + + + return result; + } + + private convertGlobalTask(fromConfig: ExternalTaskRunnerConfiguration): TaskDescription { + let command: string = this.getGlobalCommand(fromConfig); + if (!command) { + this.problemReporter.error(nls.localize('Converter.noGlobalName', 'No global command specified. Can\'t convert to 2.0.0 version.')); + return undefined; + } + let result: TaskDescription = { + taskName: command + }; + if (fromConfig.isShellCommand) { + result.type = 'shell'; + } else { + result.type = 'process'; + result.args = fromConfig.args; + } + if (fromConfig.) + + return result; + } + + private getGlobalCommand(fromConfig: ExternalTaskRunnerConfiguration): string { + if (fromConfig.command) { + return fromConfig.command; + } else if (fromConfig.windows && fromConfig.windows.command) { + return fromConfig.windows.command; + } else if (fromConfig.osx && fromConfig.osx.command) { + return fromConfig.osx.command; + } else if (fromConfig.linux && fromConfig.linux.command) { + return fromConfig.linux.command; + } else { + return undefined; + } + } + + private createCommandLine(command: string, args: string[], isWindows: boolean): string { + let result: string[]; + let commandHasSpace = false; + let argHasSpace = false; + if (TaskDescription.hasUnescapedSpaces(command)) { + result.push(`"${command}"`); + commandHasSpace = true; + } else { + result.push(command); + } + if (args) { + for (let arg of args) { + if (TaskDescription.hasUnescapedSpaces(arg)) { + result.push(`"${arg}"`); + argHasSpace= true; + } else { + result.push(arg); + } + } + } + return result.join(' '); + } + +} +*/ \ No newline at end of file -- GitLab From 06d60228fdbe75641998f6e82c6bda981379607b Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 31 May 2017 15:27:50 +0200 Subject: [PATCH 0355/1347] Added description on how to debug smoke test. --- test/smoke/CONTRIBUTING.md | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/test/smoke/CONTRIBUTING.md b/test/smoke/CONTRIBUTING.md index 8aaef8a7875..7b403022778 100644 --- a/test/smoke/CONTRIBUTING.md +++ b/test/smoke/CONTRIBUTING.md @@ -11,4 +11,25 @@ To contribute a new smoke test area, add `${area}.ts` file under `./areas`. This has to follow the bot-style approach described in the links mentioned above. Methods should be calling WebDriverIO API through `SpectronClient` class. If there is no existing WebDriverIO method, add it to the class. # Adding new test -To add new test area or test, `main.ts` should be updated. The same instruction-style principle needs to be followed with the called area method names that reflect manual tester's actions. \ No newline at end of file +To add new test area or test, `main.ts` should be updated. The same instruction-style principle needs to be followed with the called area method names that reflect manual tester's actions. + +# Debugging +1. Add the following configuration to launch.json, specifying binaries in `args`: +```json +{ + "type": "node", + "request": "launch", + "name": "Launch Smoke Test", + "program": "${workspaceRoot}/test/smoke/src/main.js", + "cwd": "${workspaceRoot}/test/smoke", + "port": 9999, + "args": [ + "-l", + "path/to/Code.exe" + ], + "outFiles": [ + "${cwd}/out/**/*.js" + ] +}, +``` +2. In main.js add `--debug-brk=9999` argument to the place where `src/mocha-runner.js` is spawned. \ No newline at end of file -- GitLab From 100f70c3fb9353a7c724215f81a59c5e7a1a874b Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 31 May 2017 15:30:00 +0200 Subject: [PATCH 0356/1347] Fixes #27604. --- test/smoke/src/areas/integrated-terminal.ts | 16 ++++++++-------- test/smoke/src/mocha-runner.js | 1 - test/smoke/src/tests/integrated-terminal.ts | 3 +-- 3 files changed, 9 insertions(+), 11 deletions(-) diff --git a/test/smoke/src/areas/integrated-terminal.ts b/test/smoke/src/areas/integrated-terminal.ts index c41f2946d4d..4431794546c 100644 --- a/test/smoke/src/areas/integrated-terminal.ts +++ b/test/smoke/src/areas/integrated-terminal.ts @@ -23,17 +23,17 @@ export class IntegratedTerminal { return this.spectron.command('workbench.action.terminal.toggleTerminal'); } - public async getCommandOutput(command: string): Promise { + public async commandOutputHas(result: string): Promise { const selector = 'div[id="workbench.panel.terminal"] .xterm-rows'; - // Default Powershell terminal adds 3 header rows at the top, whereas bash does not. - let readRow = process.platform === 'win32' ? 5 : 2; - let output: string = await this.spectron.client.getText(`${selector}>:nth-child(${readRow})`); - // If ended up on the wrong line, it could be terminal's restored session (e.g. on OS X) - if (output.trim().endsWith(command)) { - output = await this.spectron.client.getText(`${selector}>:nth-child(${readRow+1})`); // try next line + const rows = await this.spectron.client.elements(`${selector} div`); + for (let i = 0; i < rows.value.length; i++) { + const rowText = await this.spectron.client.getText(`${selector}>:nth-child(${i+1})`); + if (rowText.trim() === result) { + return true; + } } - return output.trim(); // remove many   tags + return false; } } \ No newline at end of file diff --git a/test/smoke/src/mocha-runner.js b/test/smoke/src/mocha-runner.js index 39a91bcdbab..fe25e885544 100644 --- a/test/smoke/src/mocha-runner.js +++ b/test/smoke/src/mocha-runner.js @@ -5,7 +5,6 @@ var Mocha = require('mocha'); var path = require('path'); -var fs = require('fs'); var mocha = new Mocha({ timeout: 360000, diff --git a/test/smoke/src/tests/integrated-terminal.ts b/test/smoke/src/tests/integrated-terminal.ts index c05a84e0b2a..4785e47aff6 100644 --- a/test/smoke/src/tests/integrated-terminal.ts +++ b/test/smoke/src/tests/integrated-terminal.ts @@ -34,8 +34,7 @@ export function testIntegratedTerminal() { await common.type(command); await common.enter(); await app.wait(); - let output = await terminal.getCommandOutput(command); - assert.equal(output, 'test'); + assert.ok(await terminal.commandOutputHas('test')); }); }); } \ No newline at end of file -- GitLab From 20a33eeb2cdceda1dd56405acc498da5eecb5333 Mon Sep 17 00:00:00 2001 From: isidor Date: Wed, 31 May 2017 15:41:10 +0200 Subject: [PATCH 0357/1347] output: reveal last line and column, not only line because some users only use append in output and have a long line fixes #26753 --- src/vs/workbench/browser/parts/editor/textResourceEditor.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/vs/workbench/browser/parts/editor/textResourceEditor.ts b/src/vs/workbench/browser/parts/editor/textResourceEditor.ts index dda89f7447b..764c0576604 100644 --- a/src/vs/workbench/browser/parts/editor/textResourceEditor.ts +++ b/src/vs/workbench/browser/parts/editor/textResourceEditor.ts @@ -152,7 +152,6 @@ export class TextResourceEditor extends BaseTextEditor { /** * Reveals the last line of this editor if it has a model set. - * If smart reveal is true will only reveal the last line if the line before last is visible #3351 */ public revealLastLine(): void { const codeEditor = this.getControl(); @@ -160,7 +159,7 @@ export class TextResourceEditor extends BaseTextEditor { if (model) { const lastLine = model.getLineCount(); - codeEditor.revealLine(lastLine); + codeEditor.revealPosition({ lineNumber: lastLine, column: model.getLineMaxColumn(lastLine) }); } } -- GitLab From 86110204b284bcf4af1ac50f66028e58658a11df Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Wed, 31 May 2017 15:58:59 +0200 Subject: [PATCH 0358/1347] Fix #12744 --- .../configuration-editing/src/extension.ts | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/extensions/configuration-editing/src/extension.ts b/extensions/configuration-editing/src/extension.ts index 92a3075f8b3..666e8775a69 100644 --- a/extensions/configuration-editing/src/extension.ts +++ b/extensions/configuration-editing/src/extension.ts @@ -79,7 +79,15 @@ function registerExtensionsCompletions(): vscode.Disposable { || e.id === 'Microsoft.vscode-markdown' || alreadyEnteredExtensions.indexOf(e.id) > -1 )) - .map(e => newSimpleCompletionItem(e.id, range, undefined, '"' + e.id + '"')); + .map(e => { + const item = new vscode.CompletionItem(e.id); + const insertText = `"${e.id}"`; + item.kind = vscode.CompletionItemKind.Value; + item.insertText = insertText; + item.range = range; + item.filterText = insertText; + return item; + }); } } return []; @@ -87,11 +95,11 @@ function registerExtensionsCompletions(): vscode.Disposable { }); } -function newSimpleCompletionItem(text: string, range: vscode.Range, description?: string, insertText?: string): vscode.CompletionItem { - const item = new vscode.CompletionItem(text); +function newSimpleCompletionItem(label: string, range: vscode.Range, description?: string, insertText?: string): vscode.CompletionItem { + const item = new vscode.CompletionItem(label); item.kind = vscode.CompletionItemKind.Value; item.detail = description; - item.insertText = insertText || text; + item.insertText = insertText || label; item.range = range; return item; -- GitLab From d401c82fad589177f35ac2fcd7ec9e1070221f31 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 31 May 2017 16:12:43 +0200 Subject: [PATCH 0359/1347] Fixes #27490: Improve hover message --- .../browser/keybindingsEditorContribution.ts | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.ts b/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.ts index 3f560219cfe..d4be2ebf38c 100644 --- a/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.ts +++ b/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.ts @@ -28,7 +28,6 @@ import { ScanCodeBinding } from 'vs/workbench/services/keybinding/common/scanCod import { EditorContextKeys } from 'vs/editor/common/editorContextKeys'; const NLS_LAUNCH_MESSAGE = nls.localize('defineKeybinding.start', "Define Keybinding"); -const NLS_KB_LAYOUT_INFO_MESSAGE = nls.localize('defineKeybinding.kbLayoutInfoMessage', "For your current keyboard layout press "); const NLS_KB_LAYOUT_ERROR_MESSAGE = nls.localize('defineKeybinding.kbLayoutErrorMessage', "You won't be able to produce this key combination under your current keyboard layout."); const INTERESTING_FILE = /keybindings\.json$/; @@ -298,8 +297,15 @@ export class KeybindingEditorDecorationsRenderer extends Disposable { overviewRulerColor = 'rgba(250, 100, 100, 0.6)'; } else { // this is the info case - msg = [NLS_KB_LAYOUT_INFO_MESSAGE]; - msg = msg.concat(message); + msg = [ + nls.localize({ + key: 'defineKeybinding.kbLayoutLocalMessage', + comment: [ + 'Please translate maintaining the stars (*) around the placeholder such that it will be rendered in bold.', + 'The placeholder will contain a keyboard combination e.g. Ctrl+Shift+/' + ] + }, "**{0}** for your current keyboard layout.", message) + ]; className = 'keybindingInfo'; beforeContentClassName = 'inlineKeybindingInfo'; overviewRulerColor = 'rgba(100, 100, 250, 0.6)'; -- GitLab From bcdbc335eb000671ce708896f33366bb96f34f30 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Wed, 31 May 2017 16:13:49 +0200 Subject: [PATCH 0360/1347] Fix #27747 --- src/vs/vscode.proposed.d.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vs/vscode.proposed.d.ts b/src/vs/vscode.proposed.d.ts index 2e015db6753..89aad78d404 100644 --- a/src/vs/vscode.proposed.d.ts +++ b/src/vs/vscode.proposed.d.ts @@ -39,10 +39,10 @@ declare module 'vscode' { getTreeItem(element: T): TreeItem | Thenable; /** - * Get the children of `element` or root. + * Get the children of `element` or root if no element (`undefined`) is passed. * - * @param element The element from which the provider gets children for. - * @return Children of `element` or root. + * @param element The element from which the provider gets children. Can be `undefined`. + * @return Children of `element` or root if no element (`undefined`) is passed. */ getChildren(element?: T): ProviderResult; } -- GitLab From 6ba48011f541aa50bdaf31e966bf08f1efde5551 Mon Sep 17 00:00:00 2001 From: isidor Date: Wed, 31 May 2017 16:18:27 +0200 Subject: [PATCH 0361/1347] debug: tryToAutoFocusStackFrame fixes #25104 --- .../debug/electron-browser/debugService.ts | 34 ++++++++++++------- 1 file changed, 22 insertions(+), 12 deletions(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugService.ts b/src/vs/workbench/parts/debug/electron-browser/debugService.ts index 87f7a74c5c4..49b429ed4f4 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugService.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugService.ts @@ -126,7 +126,8 @@ export class DebugService implements debug.IDebugService { // Some adapters might not respect the number levels in StackTraceRequest and might // return more stackFrames than requested. For those do not send an additional stackTrace request. if (callStack.length <= 1) { - this.model.fetchCallStack(focusedThread).done(undefined, errors.onUnexpectedError); + this.model.fetchCallStack(focusedThread).done(() => + this.tryToAutoFocusStackFrame(focusedThread), errors.onUnexpectedError); } } }, 420); @@ -264,6 +265,25 @@ export class DebugService implements debug.IDebugService { } } + private tryToAutoFocusStackFrame(thread: debug.IThread): TPromise { + const callStack = thread.getCallStack(); + if (!callStack.length || this.viewModel.focusedStackFrame) { + return TPromise.as(null); + } + + // focus first stack frame from top that has source location if no other stack frame is focussed + const stackFrameToFocus = first(callStack, sf => sf.source && sf.source.available, undefined); + if (!stackFrameToFocus) { + return TPromise.as(null); + } + + this.focusStackFrameAndEvaluate(stackFrameToFocus).done(null, errors.onUnexpectedError); + this.windowService.getWindow().focus(); + aria.alert(nls.localize('debuggingPaused', "Debugging paused, reason {0}, {1} {2}", thread.stoppedDetails.reason, stackFrameToFocus.source ? stackFrameToFocus.source.name : '', stackFrameToFocus.range.startLineNumber)); + + return stackFrameToFocus.openInEditor(this.editorService); + } + private registerSessionListeners(process: Process, session: RawDebugSession): void { this.toDisposeOnSessionEnd.get(session.getId()).push(session); this.toDisposeOnSessionEnd.get(session.getId()).push(session.onDidInitialize(event => { @@ -307,18 +327,8 @@ export class DebugService implements debug.IDebugService { // Call fetch call stack twice, the first only return the top stack frame. // Second retrieves the rest of the call stack. For performance reasons #25605 this.model.fetchCallStack(thread).then(() => { - const callStack = thread.getCallStack(); this.callStackScheduler.schedule(); - if (callStack.length > 0 && !this.viewModel.focusedStackFrame) { - // focus first stack frame from top that has source location if no other stack frame is focussed - const stackFrameToFocus = first(callStack, sf => sf.source && sf.source.available, callStack[0]); - this.focusStackFrameAndEvaluate(stackFrameToFocus).done(null, errors.onUnexpectedError); - this.windowService.getWindow().focus(); - aria.alert(nls.localize('debuggingPaused', "Debugging paused, reason {0}, {1} {2}", event.body.reason, stackFrameToFocus.source ? stackFrameToFocus.source.name : '', stackFrameToFocus.range.startLineNumber)); - - return stackFrameToFocus.openInEditor(this.editorService); - } - return undefined; + return this.tryToAutoFocusStackFrame(thread); }); } }, errors.onUnexpectedError); -- GitLab From e98c09c842df5a045f52386246a860c530945d9d Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Wed, 31 May 2017 16:18:42 +0200 Subject: [PATCH 0362/1347] Fixes #27738: Defer switching to Tasks 2.0.0 as the default --- extensions/grunt/package.json | 1 + extensions/gulp/package.json | 1 + extensions/jake/package.json | 1 + extensions/typescript/package.json | 1 + extensions/typescript/src/typings/ref.d.ts | 1 + src/vs/vscode.d.ts | 329 ------------------ src/vs/vscode.proposed.d.ts | 329 ++++++++++++++++++ src/vs/workbench/api/node/extHost.api.impl.ts | 4 +- .../parts/tasks/common/taskConfiguration.ts | 10 +- .../parts/tasks/common/taskTemplates.ts | 218 ++++++++++++ .../tasks/electron-browser/jsonSchema_v2.ts | 12 +- .../electron-browser/task.contribution.ts | 61 +++- 12 files changed, 626 insertions(+), 342 deletions(-) diff --git a/extensions/grunt/package.json b/extensions/grunt/package.json index e8bac905a69..274d158ab28 100644 --- a/extensions/grunt/package.json +++ b/extensions/grunt/package.json @@ -7,6 +7,7 @@ "engines": { "vscode": "*" }, + "enableProposedApi": true, "categories": [ "Other" ], diff --git a/extensions/gulp/package.json b/extensions/gulp/package.json index 5ec491853fe..6a9845ce00a 100644 --- a/extensions/gulp/package.json +++ b/extensions/gulp/package.json @@ -7,6 +7,7 @@ "engines": { "vscode": "*" }, + "enableProposedApi": true, "categories": [ "Other" ], diff --git a/extensions/jake/package.json b/extensions/jake/package.json index ee5a916ade5..16892a14655 100644 --- a/extensions/jake/package.json +++ b/extensions/jake/package.json @@ -7,6 +7,7 @@ "engines": { "vscode": "*" }, + "enableProposedApi": true, "categories": [ "Other" ], diff --git a/extensions/typescript/package.json b/extensions/typescript/package.json index 7d5105c3dca..74700e642b7 100644 --- a/extensions/typescript/package.json +++ b/extensions/typescript/package.json @@ -10,6 +10,7 @@ "engines": { "vscode": "*" }, + "enableProposedApi": true, "dependencies": { "semver": "4.3.6", "vscode-extension-telemetry": "^0.0.7", diff --git a/extensions/typescript/src/typings/ref.d.ts b/extensions/typescript/src/typings/ref.d.ts index bc057c55878..954bab971e3 100644 --- a/extensions/typescript/src/typings/ref.d.ts +++ b/extensions/typescript/src/typings/ref.d.ts @@ -4,4 +4,5 @@ *--------------------------------------------------------------------------------------------*/ /// +/// /// diff --git a/src/vs/vscode.d.ts b/src/vs/vscode.d.ts index 4e5e206c8af..1943316e026 100644 --- a/src/vs/vscode.d.ts +++ b/src/vs/vscode.d.ts @@ -3537,335 +3537,6 @@ declare module 'vscode' { update(key: string, value: any): Thenable; } - /** - * Controls the behaviour of the terminal's visibility. - */ - export enum TaskRevealKind { - /** - * Always brings the terminal to front if the task is executed. - */ - Always = 1, - - /** - * Only brings the terminal to front if a problem is detected executing the task - * (e.g. the task couldn't be started because). - */ - Silent = 2, - - /** - * The terminal never comes to front when the task is executed. - */ - Never = 3 - } - - /** - * Controls terminal specific behavior. - */ - export interface TaskTerminalBehavior { - /** - * Controls whether the terminal executing a task is brought to front or not. - * Defaults to `RevealKind.Always`. - */ - reveal?: TaskRevealKind; - - /** - * Controls whether the command is echoed in the terminal or not. - */ - echo?: boolean; - } - - export interface ProcessTaskOptions { - /** - * The current working directory of the executed program or shell. - * If omitted the tools current workspace root is used. - */ - cwd?: string; - - /** - * The additional environment of the executed program or shell. If omitted - * the parent process' environment is used. If provided it is merged with - * the parent process' environment. - */ - env?: { [key: string]: string }; - } - - export namespace TaskGroup { - /** - * The clean task group - */ - export const Clean: 'clean'; - /** - * The build task group. If a task is part of the build task group - * it can be executed via the run build short cut. - */ - export const Build: 'build'; - /** - * The rebuild all task group - */ - export const RebuildAll: 'rebuildAll'; - /** - * The test task group. If a task is part of the test task group - * it can be executed via the run test short cut. - */ - export const Test: 'test'; - } - - /** - * A task that starts an external process. - */ - export class ProcessTask { - - /** - * Creates a process task. - * - * @param name the task's name. Is presented in the user interface. - * @param process the process to start. - * @param problemMatchers the names of problem matchers to use, like '$tsc' - * or '$eslint'. Problem matchers can be contributed by an extension using - * the `problemMatchers` extension point. - */ - constructor(name: string, process: string, problemMatchers?: string | string[]); - - /** - * Creates a process task. - * - * @param name the task's name. Is presented in the user interface. - * @param process the process to start. - * @param args arguments to be passed to the process. - * @param problemMatchers the names of problem matchers to use, like '$tsc' - * or '$eslint'. Problem matchers can be contributed by an extension using - * the `problemMatchers` extension point. - */ - constructor(name: string, process: string, args: string[], problemMatchers?: string | string[]); - - /** - * Creates a process task. - * - * @param name the task's name. Is presented in the user interface. - * @param process the process to start. - * @param args arguments to be passed to the process. - * @param options additional options for the started process. - * @param problemMatchers the names of problem matchers to use, like '$tsc' - * or '$eslint'. Problem matchers can be contributed by an extension using - * the `problemMatchers` extension point. - */ - constructor(name: string, process: string, args: string[], options: ProcessTaskOptions, problemMatchers?: string | string[]); - - /** - * The task's name - */ - readonly name: string; - - /** - * The task's identifier. If omitted the internal identifier will - * be `${extensionName}:${name}` - */ - identifier: string | undefined; - - /** - * Whether the task is a background task or not. - */ - isBackground: boolean; - - /** - * The process to be executed. - */ - readonly process: string; - - /** - * The arguments passed to the process. Defaults to an empty array. - */ - args: string[]; - - /** - * A human-readable string describing the source of this - * shell task, e.g. 'gulp' or 'npm'. - */ - source: string | undefined; - - /** - * The task group this tasks belongs to. See TaskGroup - * for a predefined set of available groups. - * Defaults to undefined meaning that the task doesn't - * belong to any special group. - */ - group: string | undefined; - - /** - * The process options used when the process is executed. - * Defaults to an empty object literal. - */ - options: ProcessTaskOptions; - - /** - * The terminal behavior. Defaults to an empty object literal. - */ - terminalBehavior: TaskTerminalBehavior; - - /** - * The problem matchers attached to the task. Defaults to an empty - * array. - */ - problemMatchers: string[]; - } - - export type ShellTaskOptions = { - /** - * The shell executable. - */ - executable: string; - - /** - * The arguments to be passed to the shell executable used to run the task. - */ - shellArgs?: string[]; - - /** - * The current working directory of the executed shell. - * If omitted the tools current workspace root is used. - */ - cwd?: string; - - /** - * The additional environment of the executed shell. If omitted - * the parent process' environment is used. If provided it is merged with - * the parent process' environment. - */ - env?: { [key: string]: string }; - } | { - /** - * The current working directory of the executed shell. - * If omitted the tools current workspace root is used. - */ - cwd: string; - - /** - * The additional environment of the executed shell. If omitted - * the parent process' environment is used. If provided it is merged with - * the parent process' environment. - */ - env?: { [key: string]: string }; - } | { - /** - * The current working directory of the executed shell. - * If omitted the tools current workspace root is used. - */ - cwd?: string; - - /** - * The additional environment of the executed shell. If omitted - * the parent process' environment is used. If provided it is merged with - * the parent process' environment. - */ - env: { [key: string]: string }; - }; - - /** - * A task that executes a shell command. - */ - export class ShellTask { - - /** - * Creates a shell task. - * - * @param name the task's name. Is presented in the user interface. - * @param commandLine the command line to execute. - * @param problemMatchers the names of problem matchers to use, like '$tsc' - * or '$eslint'. Problem matchers can be contributed by an extension using - * the `problemMatchers` extension point. - */ - constructor(name: string, commandLine: string, problemMatchers?: string | string[]); - - /** - * Creates a shell task. - * - * @param name the task's name. Is presented in the user interface. - * @param commandLine the command line to execute. - * @param options additional options used when creating the shell. - * @param problemMatchers the names of problem matchers to use, like '$tsc' - * or '$eslint'. Problem matchers can be contributed by an extension using - * the `problemMatchers` extension point. - */ - constructor(name: string, commandLine: string, options: ShellTaskOptions, problemMatchers?: string | string[]); - - /** - * The task's name - */ - readonly name: string; - - /** - * The task's identifier. If omitted the internal identifier will - * be `${extensionName}:${name}` - */ - identifier: string | undefined; - - /** - * Whether the task is a background task or not. - */ - isBackground: boolean; - - /** - * The command line to execute. - */ - readonly commandLine: string; - - /** - * A human-readable string describing the source of this - * shell task, e.g. 'gulp' or 'npm'. - */ - source: string | undefined; - - /** - * The task group this tasks belongs to. See TaskGroup - * for a predefined set of available groups. - * Defaults to undefined meaning that the task doesn't - * belong to any special group. - */ - group: string | undefined; - - /** - * The shell options used when the shell is executed. Defaults to an - * empty object literal. - */ - options: ShellTaskOptions; - - /** - * The terminal behavior. Defaults to an empty object literal. - */ - terminalBehavior: TaskTerminalBehavior; - - /** - * The problem matchers attached to the task. Defaults to an empty - * array. - */ - problemMatchers: string[]; - } - - export type Task = ProcessTask | ShellTask; - - /** - * A task provider allows to add tasks to the task service. - * A task provider is registerd via #workspace.registerTaskProvider. - */ - export interface TaskProvider { - /** - * Provides additional tasks. - * @param token A cancellation token. - * @return a #TaskSet - */ - provideTasks(token: CancellationToken): ProviderResult; - } - - export namespace workspace { - /** - * Register a task provider. - * - * @param provider A task provider. - * @return A [disposable](#Disposable) that unregisters this provider when being disposed. - */ - export function registerTaskProvider(provider: TaskProvider): Disposable; - } - /** * Namespace describing the environment the editor runs in. */ diff --git a/src/vs/vscode.proposed.d.ts b/src/vs/vscode.proposed.d.ts index 89aad78d404..c4ec6306a25 100644 --- a/src/vs/vscode.proposed.d.ts +++ b/src/vs/vscode.proposed.d.ts @@ -7,6 +7,335 @@ declare module 'vscode' { + /** + * Controls the behaviour of the terminal's visibility. + */ + export enum TaskRevealKind { + /** + * Always brings the terminal to front if the task is executed. + */ + Always = 1, + + /** + * Only brings the terminal to front if a problem is detected executing the task + * (e.g. the task couldn't be started because). + */ + Silent = 2, + + /** + * The terminal never comes to front when the task is executed. + */ + Never = 3 + } + + /** + * Controls terminal specific behavior. + */ + export interface TaskTerminalBehavior { + /** + * Controls whether the terminal executing a task is brought to front or not. + * Defaults to `RevealKind.Always`. + */ + reveal?: TaskRevealKind; + + /** + * Controls whether the command is echoed in the terminal or not. + */ + echo?: boolean; + } + + export interface ProcessTaskOptions { + /** + * The current working directory of the executed program or shell. + * If omitted the tools current workspace root is used. + */ + cwd?: string; + + /** + * The additional environment of the executed program or shell. If omitted + * the parent process' environment is used. If provided it is merged with + * the parent process' environment. + */ + env?: { [key: string]: string }; + } + + export namespace TaskGroup { + /** + * The clean task group + */ + export const Clean: 'clean'; + /** + * The build task group. If a task is part of the build task group + * it can be executed via the run build short cut. + */ + export const Build: 'build'; + /** + * The rebuild all task group + */ + export const RebuildAll: 'rebuildAll'; + /** + * The test task group. If a task is part of the test task group + * it can be executed via the run test short cut. + */ + export const Test: 'test'; + } + + /** + * A task that starts an external process. + */ + export class ProcessTask { + + /** + * Creates a process task. + * + * @param name the task's name. Is presented in the user interface. + * @param process the process to start. + * @param problemMatchers the names of problem matchers to use, like '$tsc' + * or '$eslint'. Problem matchers can be contributed by an extension using + * the `problemMatchers` extension point. + */ + constructor(name: string, process: string, problemMatchers?: string | string[]); + + /** + * Creates a process task. + * + * @param name the task's name. Is presented in the user interface. + * @param process the process to start. + * @param args arguments to be passed to the process. + * @param problemMatchers the names of problem matchers to use, like '$tsc' + * or '$eslint'. Problem matchers can be contributed by an extension using + * the `problemMatchers` extension point. + */ + constructor(name: string, process: string, args: string[], problemMatchers?: string | string[]); + + /** + * Creates a process task. + * + * @param name the task's name. Is presented in the user interface. + * @param process the process to start. + * @param args arguments to be passed to the process. + * @param options additional options for the started process. + * @param problemMatchers the names of problem matchers to use, like '$tsc' + * or '$eslint'. Problem matchers can be contributed by an extension using + * the `problemMatchers` extension point. + */ + constructor(name: string, process: string, args: string[], options: ProcessTaskOptions, problemMatchers?: string | string[]); + + /** + * The task's name + */ + readonly name: string; + + /** + * The task's identifier. If omitted the internal identifier will + * be `${extensionName}:${name}` + */ + identifier: string | undefined; + + /** + * Whether the task is a background task or not. + */ + isBackground: boolean; + + /** + * The process to be executed. + */ + readonly process: string; + + /** + * The arguments passed to the process. Defaults to an empty array. + */ + args: string[]; + + /** + * A human-readable string describing the source of this + * shell task, e.g. 'gulp' or 'npm'. + */ + source: string | undefined; + + /** + * The task group this tasks belongs to. See TaskGroup + * for a predefined set of available groups. + * Defaults to undefined meaning that the task doesn't + * belong to any special group. + */ + group: string | undefined; + + /** + * The process options used when the process is executed. + * Defaults to an empty object literal. + */ + options: ProcessTaskOptions; + + /** + * The terminal behavior. Defaults to an empty object literal. + */ + terminalBehavior: TaskTerminalBehavior; + + /** + * The problem matchers attached to the task. Defaults to an empty + * array. + */ + problemMatchers: string[]; + } + + export type ShellTaskOptions = { + /** + * The shell executable. + */ + executable: string; + + /** + * The arguments to be passed to the shell executable used to run the task. + */ + shellArgs?: string[]; + + /** + * The current working directory of the executed shell. + * If omitted the tools current workspace root is used. + */ + cwd?: string; + + /** + * The additional environment of the executed shell. If omitted + * the parent process' environment is used. If provided it is merged with + * the parent process' environment. + */ + env?: { [key: string]: string }; + } | { + /** + * The current working directory of the executed shell. + * If omitted the tools current workspace root is used. + */ + cwd: string; + + /** + * The additional environment of the executed shell. If omitted + * the parent process' environment is used. If provided it is merged with + * the parent process' environment. + */ + env?: { [key: string]: string }; + } | { + /** + * The current working directory of the executed shell. + * If omitted the tools current workspace root is used. + */ + cwd?: string; + + /** + * The additional environment of the executed shell. If omitted + * the parent process' environment is used. If provided it is merged with + * the parent process' environment. + */ + env: { [key: string]: string }; + }; + + /** + * A task that executes a shell command. + */ + export class ShellTask { + + /** + * Creates a shell task. + * + * @param name the task's name. Is presented in the user interface. + * @param commandLine the command line to execute. + * @param problemMatchers the names of problem matchers to use, like '$tsc' + * or '$eslint'. Problem matchers can be contributed by an extension using + * the `problemMatchers` extension point. + */ + constructor(name: string, commandLine: string, problemMatchers?: string | string[]); + + /** + * Creates a shell task. + * + * @param name the task's name. Is presented in the user interface. + * @param commandLine the command line to execute. + * @param options additional options used when creating the shell. + * @param problemMatchers the names of problem matchers to use, like '$tsc' + * or '$eslint'. Problem matchers can be contributed by an extension using + * the `problemMatchers` extension point. + */ + constructor(name: string, commandLine: string, options: ShellTaskOptions, problemMatchers?: string | string[]); + + /** + * The task's name + */ + readonly name: string; + + /** + * The task's identifier. If omitted the internal identifier will + * be `${extensionName}:${name}` + */ + identifier: string | undefined; + + /** + * Whether the task is a background task or not. + */ + isBackground: boolean; + + /** + * The command line to execute. + */ + readonly commandLine: string; + + /** + * A human-readable string describing the source of this + * shell task, e.g. 'gulp' or 'npm'. + */ + source: string | undefined; + + /** + * The task group this tasks belongs to. See TaskGroup + * for a predefined set of available groups. + * Defaults to undefined meaning that the task doesn't + * belong to any special group. + */ + group: string | undefined; + + /** + * The shell options used when the shell is executed. Defaults to an + * empty object literal. + */ + options: ShellTaskOptions; + + /** + * The terminal behavior. Defaults to an empty object literal. + */ + terminalBehavior: TaskTerminalBehavior; + + /** + * The problem matchers attached to the task. Defaults to an empty + * array. + */ + problemMatchers: string[]; + } + + export type Task = ProcessTask | ShellTask; + + /** + * A task provider allows to add tasks to the task service. + * A task provider is registerd via #workspace.registerTaskProvider. + */ + export interface TaskProvider { + /** + * Provides additional tasks. + * @param token A cancellation token. + * @return a #TaskSet + */ + provideTasks(token: CancellationToken): ProviderResult; + } + + export namespace workspace { + /** + * Register a task provider. + * + * @param provider A task provider. + * @return A [disposable](#Disposable) that unregisters this provider when being disposed. + */ + export function registerTaskProvider(provider: TaskProvider): Disposable; + } + export namespace window { export function sampleFunction(): Thenable; diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index a859a1369fe..065f16fc76c 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -448,9 +448,9 @@ export function createApiFactory( getConfiguration: (section?: string): vscode.WorkspaceConfiguration => { return extHostConfiguration.getConfiguration(section); }, - registerTaskProvider: (provider: vscode.TaskProvider) => { + registerTaskProvider: proposedApiFunction(extension, (provider: vscode.TaskProvider) => { return extHostTask.registerTaskProvider(extension, provider); - } + }) }; class SCM { diff --git a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts index f39f7786efa..8d7903008c9 100644 --- a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts +++ b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts @@ -1101,6 +1101,8 @@ namespace Globals { export namespace ExecutionEngine { + export const _default: Tasks.ExecutionEngine = Tasks.ExecutionEngine.Process; + export function from(config: ExternalTaskRunnerConfiguration): Tasks.ExecutionEngine { let runner = config.runner || config._runner; let result: Tasks.ExecutionEngine; @@ -1128,16 +1130,20 @@ export namespace ExecutionEngine { export namespace JsonSchemaVersion { + export const _default: Tasks.JsonSchemaVersion = Tasks.JsonSchemaVersion.V0_1_0; + export function from(config: ExternalTaskRunnerConfiguration): Tasks.JsonSchemaVersion { let version = config.version; if (!version) { - return Tasks.JsonSchemaVersion.V2_0_0; + return _default; } switch (version) { case '0.1.0': return Tasks.JsonSchemaVersion.V0_1_0; - default: + case '2.0.0': return Tasks.JsonSchemaVersion.V2_0_0; + default: + return _default; } } } diff --git a/src/vs/workbench/parts/tasks/common/taskTemplates.ts b/src/vs/workbench/parts/tasks/common/taskTemplates.ts index b88527097ca..461062f19a8 100644 --- a/src/vs/workbench/parts/tasks/common/taskTemplates.ts +++ b/src/vs/workbench/parts/tasks/common/taskTemplates.ts @@ -14,6 +14,7 @@ export interface TaskEntry extends IPickOpenEntry { content: string; } +/* Version 2.0 templates const dotnetBuild: TaskEntry = { id: 'dotnetCore', label: '.NET Core', @@ -127,3 +128,220 @@ export let templates: TaskEntry[] = [dotnetBuild, msbuild, maven].sort((a, b) => return (a.sort || a.label).localeCompare(b.sort || b.label); }); templates.push(command); +*/ + +const gulp: TaskEntry = { + id: 'gulp', + label: 'Gulp', + autoDetect: true, + content: [ + '{', + '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', + '\t// for the documentation about the tasks.json format', + '\t"version": "0.1.0",', + '\t"command": "gulp",', + '\t"isShellCommand": true,', + '\t"args": ["--no-color"],', + '\t"showOutput": "always"', + '}' + ].join('\n') +}; + +const grunt: TaskEntry = { + id: 'grunt', + label: 'Grunt', + autoDetect: true, + content: [ + '{', + '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', + '\t// for the documentation about the tasks.json format', + '\t"version": "0.1.0",', + '\t"command": "grunt",', + '\t"isShellCommand": true,', + '\t"args": ["--no-color"],', + '\t"showOutput": "always"', + '}' + ].join('\n') +}; + +const npm: TaskEntry = { + id: 'npm', + label: 'npm', + sort: 'NPM', + autoDetect: false, + content: [ + '{', + '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', + '\t// for the documentation about the tasks.json format', + '\t"version": "0.1.0",', + '\t"command": "npm",', + '\t"isShellCommand": true,', + '\t"showOutput": "always",', + '\t"suppressTaskName": true,', + '\t"tasks": [', + '\t\t{', + '\t\t\t"taskName": "install",', + '\t\t\t"args": ["install"]', + '\t\t},', + '\t\t{', + '\t\t\t"taskName": "update",', + '\t\t\t"args": ["update"]', + '\t\t},', + '\t\t{', + '\t\t\t"taskName": "test",', + '\t\t\t"args": ["run", "test"]', + '\t\t}', + '\t]', + '}' + ].join('\n') +}; + +const tscConfig: TaskEntry = { + id: 'tsc.config', + label: 'TypeScript - tsconfig.json', + autoDetect: false, + description: nls.localize('tsc.config', 'Compiles a TypeScript project'), + content: [ + '{', + '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', + '\t// for the documentation about the tasks.json format', + '\t"version": "0.1.0",', + '\t"command": "tsc",', + '\t"isShellCommand": true,', + '\t"args": ["-p", "."],', + '\t"showOutput": "silent",', + '\t"problemMatcher": "$tsc"', + '}' + ].join('\n') +}; + +const tscWatch: TaskEntry = { + id: 'tsc.watch', + label: 'TypeScript - Watch Mode', + autoDetect: false, + description: nls.localize('tsc.watch', 'Compiles a TypeScript project in watch mode'), + content: [ + '{', + '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', + '\t// for the documentation about the tasks.json format', + '\t"version": "0.1.0",', + '\t"command": "tsc",', + '\t"isShellCommand": true,', + '\t"args": ["-w", "-p", "."],', + '\t"showOutput": "silent",', + '\t"isBackground": true,', + '\t"problemMatcher": "$tsc-watch"', + '}' + ].join('\n') +}; + +const dotnetBuild: TaskEntry = { + id: 'dotnetCore', + label: '.NET Core', + sort: 'NET Core', + autoDetect: false, + description: nls.localize('dotnetCore', 'Executes .NET Core build command'), + content: [ + '{', + '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', + '\t// for the documentation about the tasks.json format', + '\t"version": "0.1.0",', + '\t"command": "dotnet",', + '\t"isShellCommand": true,', + '\t"args": [],', + '\t"tasks": [', + '\t\t{', + '\t\t\t"taskName": "build",', + '\t\t\t"args": [ ],', + '\t\t\t"isBuildCommand": true,', + '\t\t\t"showOutput": "silent",', + '\t\t\t"problemMatcher": "$msCompile"', + '\t\t}', + '\t]', + '}' + ].join('\n') +}; + +const msbuild: TaskEntry = { + id: 'msbuild', + label: 'MSBuild', + autoDetect: false, + description: nls.localize('msbuild', 'Executes the build target'), + content: [ + '{', + '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', + '\t// for the documentation about the tasks.json format', + '\t"version": "0.1.0",', + '\t"command": "msbuild",', + '\t"args": [', + '\t\t// Ask msbuild to generate full paths for file names.', + '\t\t"/property:GenerateFullPaths=true"', + '\t],', + '\t"taskSelector": "/t:",', + '\t"showOutput": "silent",', + '\t"tasks": [', + '\t\t{', + '\t\t\t"taskName": "build",', + '\t\t\t// Show the output window only if unrecognized errors occur.', + '\t\t\t"showOutput": "silent",', + '\t\t\t// Use the standard MS compiler pattern to detect errors, warnings and infos', + '\t\t\t"problemMatcher": "$msCompile"', + '\t\t}', + '\t]', + '}' + ].join('\n') +}; + +const command: TaskEntry = { + id: 'externalCommand', + label: 'Others', + autoDetect: false, + description: nls.localize('externalCommand', 'Example to run an arbitrary external command'), + content: [ + '{', + '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', + '\t// for the documentation about the tasks.json format', + '\t"version": "0.1.0",', + '\t"command": "echo",', + '\t"isShellCommand": true,', + '\t"args": ["Hello World"],', + '\t"showOutput": "always"', + '}' + ].join('\n') +}; + +const maven: TaskEntry = { + id: 'maven', + label: 'maven', + sort: 'MVN', + autoDetect: false, + description: nls.localize('Maven', 'Executes common maven commands'), + content: [ + '{', + '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', + '\t// for the documentation about the tasks.json format', + '\t"version": "0.1.0",', + '\t"command": "mvn",', + '\t"isShellCommand": true,', + '\t"showOutput": "always",', + '\t"suppressTaskName": true,', + '\t"tasks": [', + '\t\t{', + '\t\t\t"taskName": "verify",', + '\t\t\t"args": ["-B", "verify"],', + '\t\t\t"isBuildCommand": true', + '\t\t},', + '\t\t{', + '\t\t\t"taskName": "test",', + '\t\t\t"args": ["-B", "test"],', + '\t\t\t"isTestCommand": true', + '\t\t}', + '\t]', + '}' + ].join('\n') +}; + +export let templates: TaskEntry[] = [gulp, grunt, tscConfig, tscWatch, dotnetBuild, msbuild, npm, maven].sort((a, b) => { + return (a.sort || a.label).localeCompare(b.sort || b.label); +}); +templates.push(command); diff --git a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts index e12e519fc02..3a60d35d088 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts @@ -20,8 +20,8 @@ const shellCommand: IJSONSchema = { { $ref: '#definitions/shellConfiguration' } - ], - deprecationMessage: nls.localize('JsonSchema.tasks.isShellCommand.deprecated', 'The property isShellCommand is deprecated. Use the type property and the shell property in the options instead.') + ] + // deprecationMessage: nls.localize('JsonSchema.tasks.isShellCommand.deprecated', 'The property isShellCommand is deprecated. Use the type property and the shell property in the options instead.') }; const dependsOn: IJSONSchema = { @@ -124,10 +124,10 @@ let definitions = schema.definitions; definitions.commandConfiguration.properties.isShellCommand = Objects.deepClone(shellCommand); definitions.taskDescription.properties.isShellCommand = Objects.deepClone(shellCommand); definitions.taskDescription.properties.dependsOn = dependsOn; -definitions.showOutputType.deprecationMessage = nls.localize('JsonSchema.tasks.showOputput.deprecated', 'The property showOutput is deprecated. Use the terminal property instead.'); -definitions.taskDescription.properties.echoCommand.deprecationMessage = nls.localize('JsonSchema.tasks.echoCommand.deprecated', 'The property echoCommand is deprecated. Use the terminal property instead.'); -definitions.taskDescription.properties.isBuildCommand.deprecationMessage = nls.localize('JsonSchema.tasks.isBuildCommand.deprecated', 'The property isBuildCommand is deprecated. Use the group property instead.'); -definitions.taskDescription.properties.isTestCommand.deprecationMessage = nls.localize('JsonSchema.tasks.isTestCommand.deprecated', 'The property isTestCommand is deprecated. Use the group property instead.'); +// definitions.showOutputType.deprecationMessage = nls.localize('JsonSchema.tasks.showOputput.deprecated', 'The property showOutput is deprecated. Use the terminal property instead.'); +// definitions.taskDescription.properties.echoCommand.deprecationMessage = nls.localize('JsonSchema.tasks.echoCommand.deprecated', 'The property echoCommand is deprecated. Use the terminal property instead.'); +// definitions.taskDescription.properties.isBuildCommand.deprecationMessage = nls.localize('JsonSchema.tasks.isBuildCommand.deprecated', 'The property isBuildCommand is deprecated. Use the group property instead.'); +// definitions.taskDescription.properties.isTestCommand.deprecationMessage = nls.localize('JsonSchema.tasks.isTestCommand.deprecated', 'The property isTestCommand is deprecated. Use the group property instead.'); definitions.taskDescription.properties.identifier = identifier; definitions.taskDescription.properties.type = Objects.deepClone(taskType); definitions.taskDescription.properties.terminal = terminal; diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index f6a16bb6ba8..317f79f6ef1 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -119,6 +119,52 @@ abstract class OpenTaskConfigurationAction extends Action { if (!selection) { return undefined; } + let contentPromise: TPromise; + if (selection.autoDetect) { + const outputChannel = this.outputService.getChannel(TaskService.OutputChannelId); + outputChannel.show(true); + outputChannel.append(nls.localize('ConfigureTaskRunnerAction.autoDetecting', 'Auto detecting tasks for {0}', selection.id) + '\n'); + let detector = new ProcessRunnerDetector(this.fileService, this.contextService, this.configurationResolverService); + contentPromise = detector.detect(false, selection.id).then((value) => { + let config = value.config; + if (value.stderr && value.stderr.length > 0) { + value.stderr.forEach((line) => { + outputChannel.append(line + '\n'); + }); + if (config && (!config.tasks || config.tasks.length === 0)) { + this.messageService.show(Severity.Warning, nls.localize('ConfigureTaskRunnerAction.autoDetect', 'Auto detecting the task system failed. Using default template. Consult the task output for details.')); + return selection.content; + } else { + this.messageService.show(Severity.Warning, nls.localize('ConfigureTaskRunnerAction.autoDetectError', 'Auto detecting the task system produced errors. Consult the task output for details.')); + } + } + if (config) { + if (value.stdout && value.stdout.length > 0) { + value.stdout.forEach(line => outputChannel.append(line + '\n')); + } + let content = JSON.stringify(config, null, '\t'); + content = [ + '{', + '\t// See https://go.microsoft.com/fwlink/?LinkId=733558', + '\t// for the documentation about the tasks.json format', + ].join('\n') + content.substr(1); + return content; + } else { + return selection.content; + } + }); + } else { + contentPromise = TPromise.as(selection.content); + } + return contentPromise.then(content => { + let editorConfig = this.configurationService.getConfiguration(); + if (editorConfig.editor.insertSpaces) { + content = content.replace(/(\n)(\t+)/g, (_, s1, s2) => s1 + strings.repeat(' ', s2.length * editorConfig.editor.tabSize)); + } + configFileCreated = true; + return this.fileService.createFile(this.contextService.toResource('.vscode/tasks.json'), content); + }); + /* 2.0 version let content = selection.content; let editorConfig = this.configurationService.getConfiguration(); if (editorConfig.editor.insertSpaces) { @@ -126,6 +172,7 @@ abstract class OpenTaskConfigurationAction extends Action { } configFileCreated = true; return this.fileService.createFile(this.contextService.toResource('.vscode/tasks.json'), content); + */ }); }).then((stat) => { if (!stat) { @@ -1016,8 +1063,9 @@ class TaskService extends EventEmitter implements ITaskService { if (hasParseErrors) { return TPromise.as({ set: undefined, hasErrors: true }); } + let engine = TaskConfig.ExecutionEngine._default; if (config) { - let engine = TaskConfig.ExecutionEngine.from(config); + engine = TaskConfig.ExecutionEngine.from(config); if (engine === ExecutionEngine.Process) { if (this.hasDetectorSupport(config)) { configPromise = new ProcessRunnerDetector(this.fileService, this.contextService, this.configurationResolverService, config).detect(true).then((value): WorkspaceConfigurationResult => { @@ -1052,7 +1100,14 @@ class TaskService extends EventEmitter implements ITaskService { configPromise = TPromise.as({ config, hasErrors: false }); } } else { - configPromise = TPromise.as({ config, hasErrors: false }); + if (engine === ExecutionEngine.Terminal) { + configPromise = TPromise.as({ config, hasErrors: false }); + } else { + configPromise = new ProcessRunnerDetector(this.fileService, this.contextService, this.configurationResolverService).detect(true).then((value) => { + let hasErrors = this.printStderr(value.stderr); + return { config: value.config, hasErrors }; + }); + } } } return configPromise.then((resolved) => { @@ -1092,7 +1147,7 @@ class TaskService extends EventEmitter implements ITaskService { private getExecutionEngine(): ExecutionEngine { let { config } = this.getConfiguration(); if (!config) { - return ExecutionEngine.Terminal; + return ExecutionEngine.Process; } return TaskConfig.ExecutionEngine.from(config); } -- GitLab From d2bb304c86a4e753e609b1998e46024ce6398247 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Wed, 31 May 2017 16:26:12 +0200 Subject: [PATCH 0363/1347] Fix #27745 --- src/vs/workbench/parts/views/browser/treeView.ts | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/src/vs/workbench/parts/views/browser/treeView.ts b/src/vs/workbench/parts/views/browser/treeView.ts index fd8a1387fce..b7c39098766 100644 --- a/src/vs/workbench/parts/views/browser/treeView.ts +++ b/src/vs/workbench/parts/views/browser/treeView.ts @@ -62,7 +62,7 @@ export class TreeView extends CollapsibleViewletView { this.menus.onDidChangeTitle(() => this.updateActions(), this, this.disposables); this.themeService.onThemeChange(() => this.tree.refresh() /* soft refresh */, this, this.disposables); if (!options.collapsed) { - this.triggerActivation(); + this.activate(); } } @@ -82,14 +82,15 @@ export class TreeView extends CollapsibleViewletView { protected changeState(state: CollapsibleState): void { super.changeState(state); if (state === CollapsibleState.EXPANDED) { - this.triggerActivation(); + this.activate(); } } - private triggerActivation() { + private activate() { if (!this.activated && this.extensionService) { this.extensionService.activateByEvent(`onView:${this.id}`); this.activated = true; + this.setInput(); } } @@ -123,10 +124,6 @@ export class TreeView extends CollapsibleViewletView { return createActionItem(action, this.keybindingService, this.messageService); } - public create(): TPromise { - return this.setInput(); - } - public setVisible(visible: boolean): TPromise { return super.setVisible(visible); } -- GitLab From 2efcddf229d99cfe24d52d6590eb99b332dcf518 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 31 May 2017 16:30:05 +0200 Subject: [PATCH 0364/1347] Extension host crashes on MacOS when crash reporter is disabled (fixes #27735) --- .../electron-browser/crashReporterService.ts | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts b/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts index 792a8672297..59c19df4001 100644 --- a/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts +++ b/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts @@ -21,6 +21,7 @@ export class CrashReporterService implements ICrashReporterService { public _serviceBrand: any; private options: Electron.CrashReporterStartOptions; + private isEnabled: boolean; constructor( @ITelemetryService private telemetryService: ITelemetryService, @@ -28,7 +29,9 @@ export class CrashReporterService implements ICrashReporterService { @IConfigurationService configurationService: IConfigurationService ) { const config = configurationService.getConfiguration(TELEMETRY_SECTION_ID); - if (config.enableCrashReporter) { + this.isEnabled = !!config.enableCrashReporter; + + if (this.isEnabled) { this.startCrashReporter(); } } @@ -78,11 +81,12 @@ export class CrashReporterService implements ICrashReporterService { public getChildProcessStartOptions(name: string): Electron.CrashReporterStartOptions { - // Experimental attempt on Mac only for now - if (isMacintosh) { + // Experimental crash reporting support for child processes on Mac only for now + if (this.isEnabled && isMacintosh) { const childProcessOptions = clone(this.options); childProcessOptions.extra.processName = name; childProcessOptions.crashesDirectory = os.tmpdir(); + return childProcessOptions; } -- GitLab From aae395f8b2735ba70edbe350274726c8c6efea49 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Wed, 31 May 2017 16:38:10 +0200 Subject: [PATCH 0365/1347] Linux: Ugly flicker in welcome page on first startup. Fixes #27518 --- .../themes/electron-browser/colorThemeData.ts | 9 +++++++ .../electron-browser/workbenchThemeService.ts | 27 +++++++------------ 2 files changed, 18 insertions(+), 18 deletions(-) diff --git a/src/vs/workbench/services/themes/electron-browser/colorThemeData.ts b/src/vs/workbench/services/themes/electron-browser/colorThemeData.ts index f182c1494c8..c0ac0c551f4 100644 --- a/src/vs/workbench/services/themes/electron-browser/colorThemeData.ts +++ b/src/vs/workbench/services/themes/electron-browser/colorThemeData.ts @@ -131,6 +131,15 @@ export class ColorThemeData implements IColorTheme { } } +export function createUnloadedTheme(id: string): ColorThemeData { + let themeData = new ColorThemeData(); + themeData.id = id; + themeData.label = ''; + themeData.settingsId = null; + themeData.isLoaded = false; + return themeData; +} + export function fromStorageData(input: string): ColorThemeData { try { let data = JSON.parse(input); diff --git a/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.ts b/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.ts index 4125a7a1ea8..2b5eef2d40f 100644 --- a/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.ts +++ b/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.ts @@ -27,7 +27,7 @@ import { IEnvironmentService } from 'vs/platform/environment/common/environment' import { IMessageService } from 'vs/platform/message/common/message'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import Severity from 'vs/base/common/severity'; -import { ColorThemeData, fromStorageData, fromExtensionTheme } from './colorThemeData'; +import { ColorThemeData, fromStorageData, fromExtensionTheme, createUnloadedTheme } from './colorThemeData'; import { ITheme, Extensions as ThemingExtensions, IThemingRegistry } from 'vs/platform/theme/common/themeService'; import { editorBackground } from 'vs/platform/theme/common/colorRegistry'; @@ -229,30 +229,21 @@ export class WorkbenchThemeService implements IWorkbenchThemeService { this.updateColorCustomizations(false); + // In order to avoid paint flashing for tokens, because + // themes are loaded asynchronously, we need to initialize + // a color theme document with good defaults until the theme is loaded let themeData = null; let persistedThemeData = this.storageService.get(PERSISTED_THEME_STORAGE_KEY); if (persistedThemeData) { themeData = fromStorageData(persistedThemeData); } - if (themeData !== null) { - themeData.setCustomColors(this.colorCustomizations); - this.updateDynamicCSSRules(themeData); - this.applyTheme(themeData, null, true); - } else { - // In order to avoid paint flashing for tokens, because - // themes are loaded asynchronously, we need to initialize - // a color theme document with good defaults until the theme is loaded + if (!themeData) { let isLightTheme = (Array.prototype.indexOf.call(document.body.classList, 'vs') >= 0); - - let initialTheme = new ColorThemeData(); - initialTheme.id = isLightTheme ? VS_LIGHT_THEME : VS_DARK_THEME; - initialTheme.label = ''; - initialTheme.settingsId = null; - initialTheme.isLoaded = false; - initialTheme.tokenColors = [{ settings: {} }]; - initialTheme.setCustomColors(this.colorCustomizations); - this.currentColorTheme = initialTheme; + themeData = createUnloadedTheme(isLightTheme ? VS_LIGHT_THEME : VS_DARK_THEME); } + themeData.setCustomColors(this.colorCustomizations); + this.updateDynamicCSSRules(themeData); + this.applyTheme(themeData, null, true); themesExtPoint.setHandler((extensions) => { for (let ext of extensions) { -- GitLab From 2b1787d6a6e2aa16d4c067c3a834bcf8ef6da841 Mon Sep 17 00:00:00 2001 From: isidor Date: Wed, 31 May 2017 16:39:48 +0200 Subject: [PATCH 0366/1347] Provide feedback when check for updates has no updates fixes #27531 --- src/vs/workbench/parts/update/electron-browser/update.ts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/vs/workbench/parts/update/electron-browser/update.ts b/src/vs/workbench/parts/update/electron-browser/update.ts index e91b4311779..30f7f301ca5 100644 --- a/src/vs/workbench/parts/update/electron-browser/update.ts +++ b/src/vs/workbench/parts/update/electron-browser/update.ts @@ -302,6 +302,14 @@ export class LightUpdateContribution implements IGlobalActivity { }); this.updateService.onError(err => messageService.show(severity.Error, err)); + + this.updateService.onUpdateNotAvailable(explicit => { + if (!explicit) { + return; + } + + messageService.show(severity.Info, nls.localize('noUpdatesAvailable', "There are no updates currently available.")); + }); } getActions(): IAction[] { -- GitLab From 171e5c204fefbc6653332e9da18be2a98dd15582 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Wed, 31 May 2017 16:41:58 +0200 Subject: [PATCH 0367/1347] Fixes #27730: Deprecation warnings in our package.json --- .vscode/tasks.json | 2 +- extensions/typescript/package.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.vscode/tasks.json b/.vscode/tasks.json index a52055b9636..4ad8767d06c 100644 --- a/.vscode/tasks.json +++ b/.vscode/tasks.json @@ -30,7 +30,7 @@ "location": 2, "message": 3 }, - "watching": { + "background": { "beginsPattern": "Starting compilation", "endsPattern": "Finished compilation" } diff --git a/extensions/typescript/package.json b/extensions/typescript/package.json index 74700e642b7..eefc7874d37 100644 --- a/extensions/typescript/package.json +++ b/extensions/typescript/package.json @@ -479,7 +479,7 @@ "${cwd}" ], "pattern": "$tsc", - "watching": { + "background": { "activeOnStart": true, "beginsPattern": { "regexp": "^\\s*(?:message TS6032:|\\d{1,2}:\\d{1,2}:\\d{1,2}(?: AM| PM)? -) File change detected\\. Starting incremental compilation\\.\\.\\." -- GitLab From 7c7235fc5ba12d5a24e59f87c7d195238291dc5c Mon Sep 17 00:00:00 2001 From: isidor Date: Wed, 31 May 2017 16:48:34 +0200 Subject: [PATCH 0368/1347] add update badge as soon as update is availble on linux (since it is never ready on that platform) fixes #27565 --- src/vs/workbench/parts/update/electron-browser/update.ts | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/update/electron-browser/update.ts b/src/vs/workbench/parts/update/electron-browser/update.ts index 30f7f301ca5..c42a94259ba 100644 --- a/src/vs/workbench/parts/update/electron-browser/update.ts +++ b/src/vs/workbench/parts/update/electron-browser/update.ts @@ -296,10 +296,15 @@ export class LightUpdateContribution implements IGlobalActivity { @IWorkbenchEditorService editorService: IWorkbenchEditorService, @IActivityBarService activityBarService: IActivityBarService ) { - this.updateService.onUpdateReady(() => { + const addBadge = () => { const badge = new NumberBadge(1, () => nls.localize('updateIsReady', "New update available.")); activityBarService.showGlobalActivity(this.id, badge); - }); + }; + if (isLinux) { + this.updateService.onUpdateAvailable(() => addBadge()); + } else { + this.updateService.onUpdateReady(() => addBadge()); + } this.updateService.onError(err => messageService.show(severity.Error, err)); -- GitLab From 747922d752ad485f236495e123a29550cb929aaa Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Wed, 31 May 2017 16:51:03 +0200 Subject: [PATCH 0369/1347] editorWidget.border color is not respected by all editor widgets Fixes #27514 --- src/vs/platform/theme/common/colorRegistry.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/platform/theme/common/colorRegistry.ts b/src/vs/platform/theme/common/colorRegistry.ts index 5f3a474f034..f0249f32481 100644 --- a/src/vs/platform/theme/common/colorRegistry.ts +++ b/src/vs/platform/theme/common/colorRegistry.ts @@ -213,7 +213,7 @@ export const editorForeground = registerColor('editor.foreground', { light: '#33 * Editor widgets */ export const editorWidgetBackground = registerColor('editorWidget.background', { dark: '#2D2D30', light: '#EFEFF2', hc: '#0C141F' }, nls.localize('editorWidgetBackground', 'Background color of editor widgets, such as find/replace.')); -export const editorWidgetBorder = registerColor('editorWidget.border', { dark: '#454545', light: '#C8C8C8', hc: contrastBorder }, nls.localize('editorWidgetBorder', 'Border color of the editor widget.')); +export const editorWidgetBorder = registerColor('editorWidget.border', { dark: '#454545', light: '#C8C8C8', hc: contrastBorder }, nls.localize('editorWidgetBorder', 'Border color of editor widgets. The color is only used if the widget chooses to have a border and if the color is not overridden by a widget.')); /** -- GitLab From 7655e2fb3269aaf79fbdcebd5699f95083f49f3c Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 31 May 2017 16:51:58 +0200 Subject: [PATCH 0370/1347] Fixes #27491: Show also the US keybinding in the info hover --- .../browser/keybindingsEditorContribution.ts | 45 +++++++++++++------ .../common/windowsKeyboardMapper.ts | 16 +++++++ 2 files changed, 47 insertions(+), 14 deletions(-) diff --git a/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.ts b/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.ts index d4be2ebf38c..633268739df 100644 --- a/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.ts +++ b/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.ts @@ -26,6 +26,7 @@ import { parseTree, Node } from 'vs/base/common/json'; import { KeybindingIO } from 'vs/workbench/services/keybinding/common/keybindingIO'; import { ScanCodeBinding } from 'vs/workbench/services/keybinding/common/scanCode'; import { EditorContextKeys } from 'vs/editor/common/editorContextKeys'; +import { WindowsNativeResolvedKeybinding } from "vs/workbench/services/keybinding/common/windowsKeyboardMapper"; const NLS_LAUNCH_MESSAGE = nls.localize('defineKeybinding.start', "Define Keybinding"); const NLS_KB_LAYOUT_ERROR_MESSAGE = nls.localize('defineKeybinding.kbLayoutErrorMessage', "You won't be able to produce this key combination under your current keyboard layout."); @@ -229,18 +230,22 @@ export class KeybindingEditorDecorationsRenderer extends Disposable { const resolvedKeybindings = this._keybindingService.resolveUserBinding(value.value); if (resolvedKeybindings.length === 0) { - return this._createDecoration(true, null, model, value); + return this._createDecoration(true, null, null, model, value); } const resolvedKeybinding = resolvedKeybindings[0]; + let usLabel: string = null; + if (resolvedKeybinding instanceof WindowsNativeResolvedKeybinding) { + usLabel = resolvedKeybinding.getUSLabel(); + } if (!resolvedKeybinding.isWYSIWYG()) { - return this._createDecoration(false, resolvedKeybinding.getLabel(), model, value); + return this._createDecoration(false, resolvedKeybinding.getLabel(), usLabel, model, value); } if (/abnt_|oem_/.test(value.value)) { - return this._createDecoration(false, resolvedKeybinding.getLabel(), model, value); + return this._createDecoration(false, resolvedKeybinding.getLabel(), usLabel, model, value); } const expectedUserSettingsLabel = resolvedKeybinding.getUserSettingsLabel(); if (!KeybindingEditorDecorationsRenderer._userSettingsFuzzyEquals(value.value, expectedUserSettingsLabel)) { - return this._createDecoration(false, resolvedKeybinding.getLabel(), model, value); + return this._createDecoration(false, resolvedKeybinding.getLabel(), usLabel, model, value); } return null; } @@ -283,7 +288,7 @@ export class KeybindingEditorDecorationsRenderer extends Disposable { return false; } - private _createDecoration(isError: boolean, message: string, model: editorCommon.IModel, keyNode: Node): editorCommon.IModelDeltaDecoration { + private _createDecoration(isError: boolean, uiLabel: string, usLabel: string, model: editorCommon.IModel, keyNode: Node): editorCommon.IModelDeltaDecoration { let msg: MarkedString[]; let className: string; let beforeContentClassName: string; @@ -297,15 +302,27 @@ export class KeybindingEditorDecorationsRenderer extends Disposable { overviewRulerColor = 'rgba(250, 100, 100, 0.6)'; } else { // this is the info case - msg = [ - nls.localize({ - key: 'defineKeybinding.kbLayoutLocalMessage', - comment: [ - 'Please translate maintaining the stars (*) around the placeholder such that it will be rendered in bold.', - 'The placeholder will contain a keyboard combination e.g. Ctrl+Shift+/' - ] - }, "**{0}** for your current keyboard layout.", message) - ]; + if (usLabel && uiLabel !== usLabel) { + msg = [ + nls.localize({ + key: 'defineKeybinding.kbLayoutLocalAndUSMessage', + comment: [ + 'Please translate maintaining the stars (*) around the placeholders such that they will be rendered in bold.', + 'The placeholders will contain a keyboard combination e.g. Ctrl+Shift+/' + ] + }, "**{0}** for your current keyboard layout (**{1}** for US standard).", uiLabel, usLabel) + ]; + } else { + msg = [ + nls.localize({ + key: 'defineKeybinding.kbLayoutLocalMessage', + comment: [ + 'Please translate maintaining the stars (*) around the placeholder such that it will be rendered in bold.', + 'The placeholder will contain a keyboard combination e.g. Ctrl+Shift+/' + ] + }, "**{0}** for your current keyboard layout.", uiLabel) + ]; + } className = 'keybindingInfo'; beforeContentClassName = 'inlineKeybindingInfo'; overviewRulerColor = 'rgba(100, 100, 250, 0.6)'; diff --git a/src/vs/workbench/services/keybinding/common/windowsKeyboardMapper.ts b/src/vs/workbench/services/keybinding/common/windowsKeyboardMapper.ts index 3772cc723fb..1eeb5b682b5 100644 --- a/src/vs/workbench/services/keybinding/common/windowsKeyboardMapper.ts +++ b/src/vs/workbench/services/keybinding/common/windowsKeyboardMapper.ts @@ -107,6 +107,22 @@ export class WindowsNativeResolvedKeybinding extends ResolvedKeybinding { return UILabelProvider.toLabel(this._firstPart, firstPart, this._chordPart, chordPart, OperatingSystem.Windows); } + private _getUSLabelForKeybinding(keybinding: SimpleKeybinding): string { + if (!keybinding) { + return null; + } + if (keybinding.isDuplicateModifierCase()) { + return ''; + } + return KeyCodeUtils.toString(keybinding.keyCode); + } + + public getUSLabel(): string { + let firstPart = this._getUSLabelForKeybinding(this._firstPart); + let chordPart = this._getUSLabelForKeybinding(this._chordPart); + return UILabelProvider.toLabel(this._firstPart, firstPart, this._chordPart, chordPart, OperatingSystem.Windows); + } + private _getAriaLabelForKeybinding(keybinding: SimpleKeybinding): string { if (!keybinding) { return null; -- GitLab From 92ec96d8e9da18938e3f4134a611853ef419d5b2 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 31 May 2017 17:08:49 +0200 Subject: [PATCH 0371/1347] Fixes #27600: Use a typical half-width character width for the new line width --- .../browser/viewParts/lines/viewLines.ts | 39 +++++++++++-------- 1 file changed, 22 insertions(+), 17 deletions(-) diff --git a/src/vs/editor/browser/viewParts/lines/viewLines.ts b/src/vs/editor/browser/viewParts/lines/viewLines.ts index f6bb857221b..462a4e5160d 100644 --- a/src/vs/editor/browser/viewParts/lines/viewLines.ts +++ b/src/vs/editor/browser/viewParts/lines/viewLines.ts @@ -37,10 +37,6 @@ class LastRenderedData { } export class ViewLines extends ViewPart implements IVisibleLinesHost, IViewLines { - /** - * Width to extends a line to render the line feed at the end of the line - */ - private static LINE_FEED_WIDTH = 10; /** * Adds this ammount of pixels to the right of lines (no-one wants to type near the edge of the viewport) */ @@ -53,6 +49,7 @@ export class ViewLines extends ViewPart implements IVisibleLinesHost, // --- config private _lineHeight: number; + private _typicalHalfwidthCharacterWidth: number; private _isViewportWrapping: boolean; private _revealHorizontalRightPadding: number; private _canUseTranslate3d: boolean; @@ -72,15 +69,18 @@ export class ViewLines extends ViewPart implements IVisibleLinesHost, this._visibleLines = new VisibleLinesCollection(this); this.domNode = this._visibleLines.domNode; - this._lineHeight = this._context.configuration.editor.lineHeight; - this._isViewportWrapping = this._context.configuration.editor.wrappingInfo.isViewportWrapping; - this._revealHorizontalRightPadding = this._context.configuration.editor.viewInfo.revealHorizontalRightPadding; - this._canUseTranslate3d = this._context.configuration.editor.canUseTranslate3d; - this._viewLineOptions = new ViewLineOptions(this._context.configuration); + const conf = this._context.configuration; + + this._lineHeight = conf.editor.lineHeight; + this._typicalHalfwidthCharacterWidth = conf.editor.fontInfo.typicalHalfwidthCharacterWidth; + this._isViewportWrapping = conf.editor.wrappingInfo.isViewportWrapping; + this._revealHorizontalRightPadding = conf.editor.viewInfo.revealHorizontalRightPadding; + this._canUseTranslate3d = conf.editor.canUseTranslate3d; + this._viewLineOptions = new ViewLineOptions(conf); PartFingerprints.write(this.domNode, PartFingerprint.ViewLines); this.domNode.setClassName('view-lines'); - Configuration.applyFontInfo(this.domNode, this._context.configuration.editor.fontInfo); + Configuration.applyFontInfo(this.domNode, conf.editor.fontInfo); // --- width & height this._maxLineWidth = 0; @@ -118,23 +118,28 @@ export class ViewLines extends ViewPart implements IVisibleLinesHost, this._maxLineWidth = 0; } + const conf = this._context.configuration; + if (e.lineHeight) { - this._lineHeight = this._context.configuration.editor.lineHeight; + this._lineHeight = conf.editor.lineHeight; + } + if (e.fontInfo) { + this._typicalHalfwidthCharacterWidth = conf.editor.fontInfo.typicalHalfwidthCharacterWidth; } if (e.wrappingInfo) { - this._isViewportWrapping = this._context.configuration.editor.wrappingInfo.isViewportWrapping; + this._isViewportWrapping = conf.editor.wrappingInfo.isViewportWrapping; } if (e.viewInfo) { - this._revealHorizontalRightPadding = this._context.configuration.editor.viewInfo.revealHorizontalRightPadding; + this._revealHorizontalRightPadding = conf.editor.viewInfo.revealHorizontalRightPadding; } if (e.canUseTranslate3d) { - this._canUseTranslate3d = this._context.configuration.editor.canUseTranslate3d; + this._canUseTranslate3d = conf.editor.canUseTranslate3d; } if (e.fontInfo) { - Configuration.applyFontInfo(this.domNode, this._context.configuration.editor.fontInfo); + Configuration.applyFontInfo(this.domNode, conf.editor.fontInfo); } - let newViewLineOptions = new ViewLineOptions(this._context.configuration); + let newViewLineOptions = new ViewLineOptions(conf); if (!this._viewLineOptions.equals(newViewLineOptions)) { this._viewLineOptions = newViewLineOptions; @@ -321,7 +326,7 @@ export class ViewLines extends ViewPart implements IVisibleLinesHost, nextLineModelLineNumber = this._context.model.coordinatesConverter.convertViewPositionToModelPosition(new Position(lineNumber + 1, 1)).lineNumber; if (currentLineModelLineNumber !== nextLineModelLineNumber) { - visibleRangesForLine[visibleRangesForLine.length - 1].width += ViewLines.LINE_FEED_WIDTH; + visibleRangesForLine[visibleRangesForLine.length - 1].width += this._typicalHalfwidthCharacterWidth; } } -- GitLab From 80050178152f9d2c0b95ef8666566bcd9578ab38 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 31 May 2017 17:17:24 +0200 Subject: [PATCH 0372/1347] start with a failing test, #27543 --- .../test/browser/snippetController2.test.ts | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts index 7a485ac4f6b..7cccf8ad7fd 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts @@ -181,4 +181,28 @@ suite('SnippetController2', function () { assertSelections(editor, new Selection(1, 7, 1, 7), new Selection(2, 11, 2, 11)); assertContextKeys(contextKeys, false, false, false); }); + // + // test('Inconsistent tab stop behaviour with recursive snippets and tab / shift tab, #27543', function () { + // const ctrl = new SnippetController2(editor, contextKeys); + // ctrl.insert('1_calize(${1:nl}, \'${2:value}\')$0'); + + // assertContextKeys(contextKeys, true, false, true); + // assertSelections(editor, new Selection(1, 10, 1, 12), new Selection(2, 14, 2, 16)); + + // ctrl.insert('2_calize(${1:nl}, \'${2:value}\')$0'); + + // assertSelections(editor, new Selection(1, 19, 1, 21), new Selection(2, 23, 2, 25)); + + // ctrl.next(); // inner `value` + // assertSelections(editor, new Selection(1, 24, 1, 29), new Selection(2, 28, 2, 33)); + + // ctrl.next(); // inner `$0` + // assertSelections(editor, new Selection(1, 31, 1, 31), new Selection(2, 35, 2, 35)); + + // ctrl.next(); // outer `value` + // assertSelections(editor, new Selection(1, 34, 1, 39), new Selection(2, 38, 2, 43)); + + // ctrl.prev(); // inner `$0` + // assertSelections(editor, new Selection(1, 31, 1, 31), new Selection(2, 35, 2, 35)); + // }); }); -- GitLab From a0968527d5345aad1eaa146e72418355cc636a40 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Wed, 31 May 2017 17:25:01 +0200 Subject: [PATCH 0373/1347] error navigation widget should default to editor error color. Fixes #25415 --- src/vs/editor/contrib/gotoError/browser/gotoError.ts | 10 +++++++--- src/vs/platform/theme/common/colorRegistry.ts | 12 ++++++++++++ 2 files changed, 19 insertions(+), 3 deletions(-) diff --git a/src/vs/editor/contrib/gotoError/browser/gotoError.ts b/src/vs/editor/contrib/gotoError/browser/gotoError.ts index cf7c1658777..600a3024636 100644 --- a/src/vs/editor/contrib/gotoError/browser/gotoError.ts +++ b/src/vs/editor/contrib/gotoError/browser/gotoError.ts @@ -23,12 +23,13 @@ import { editorAction, ServicesAccessor, IActionOptions, EditorAction, EditorCom import { ICodeEditor } from 'vs/editor/browser/editorBrowser'; import { editorContribution } from 'vs/editor/browser/editorBrowserExtensions'; import { ZoneWidget } from 'vs/editor/contrib/zoneWidget/browser/zoneWidget'; -import { registerColor } from 'vs/platform/theme/common/colorRegistry'; +import { registerColor, oneOf } from 'vs/platform/theme/common/colorRegistry'; import { IThemeService, ITheme } from 'vs/platform/theme/common/themeService'; import { Color } from 'vs/base/common/color'; import { EditorContextKeys } from 'vs/editor/common/editorContextKeys'; import { getAccessibilitySupport } from 'vs/base/browser/browser'; import { AccessibilitySupport } from 'vs/base/common/platform'; +import { editorErrorForeground, editorErrorBorder, editorWarningForeground, editorWarningBorder } from "vs/editor/common/view/editorColorRegistry"; class MarkerModel { @@ -488,6 +489,9 @@ CommonEditorRegistry.registerEditorCommand(new MarkerCommand({ // theming -export const editorMarkerNavigationError = registerColor('editorMarkerNavigationError.background', { dark: '#ff5a5a', light: '#ff5a5a', hc: '#ff5a5a' }, nls.localize('editorMarkerNavigationError', 'Editor marker navigation widget error color.')); -export const editorMarkerNavigationWarning = registerColor('editorMarkerNavigationWarning.background', { dark: '#5aac5a', light: '#5aac5a', hc: '#5aac5a' }, nls.localize('editorMarkerNavigationWarning', 'Editor marker navigation widget warning color.')); +let errorDefault = oneOf(editorErrorForeground, editorErrorBorder); +let warningDefault = oneOf(editorWarningForeground, editorWarningBorder); + +export const editorMarkerNavigationError = registerColor('editorMarkerNavigationError.background', { dark: errorDefault, light: errorDefault, hc: errorDefault }, nls.localize('editorMarkerNavigationError', 'Editor marker navigation widget error color.')); +export const editorMarkerNavigationWarning = registerColor('editorMarkerNavigationWarning.background', { dark: warningDefault, light: warningDefault, hc: warningDefault }, nls.localize('editorMarkerNavigationWarning', 'Editor marker navigation widget warning color.')); export const editorMarkerNavigationBackground = registerColor('editorMarkerNavigation.background', { dark: '#2D2D30', light: Color.white, hc: '#0C141F' }, nls.localize('editorMarkerNavigationBackground', 'Editor marker navigation widget background.')); diff --git a/src/vs/platform/theme/common/colorRegistry.ts b/src/vs/platform/theme/common/colorRegistry.ts index f0249f32481..ffc6c33eb06 100644 --- a/src/vs/platform/theme/common/colorRegistry.ts +++ b/src/vs/platform/theme/common/colorRegistry.ts @@ -304,6 +304,18 @@ export function transparent(colorValue: ColorValue, factor: number): ColorFuncti }; } +export function oneOf(...colorValues: ColorValue[]): ColorFunction { + return (theme) => { + for (let colorValue of colorValues) { + let color = resolveColorValue(colorValue, theme); + if (color) { + return color; + } + } + return null; + }; +} + function lessProminent(colorValue: ColorValue, backgroundColorValue: ColorValue, factor: number, transparency: number): ColorFunction { return (theme) => { let from = resolveColorValue(colorValue, theme); -- GitLab From 179e79839fa0bdebcbfe096fd575efb225a155db Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 31 May 2017 17:34:36 +0200 Subject: [PATCH 0374/1347] Change workspaceContains snippet to use filePattern; add * snippet; (#27663) --- src/vs/platform/extensions/common/extensionsRegistry.ts | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/vs/platform/extensions/common/extensionsRegistry.ts b/src/vs/platform/extensions/common/extensionsRegistry.ts index 7edf4f74960..b94a42edc8c 100644 --- a/src/vs/platform/extensions/common/extensionsRegistry.ts +++ b/src/vs/platform/extensions/common/extensionsRegistry.ts @@ -182,7 +182,14 @@ const schema: IJSONSchema = { type: 'array', items: { type: 'string', - defaultSnippets: [{ label: 'onLanguage', body: 'onLanguage:${1:languageId}' }, { label: 'onCommand', body: 'onCommand:${2:commandId}' }, { label: 'onDebug', body: 'onDebug:${3:type}' }, { label: 'workspaceContains', body: 'workspaceContains:${4:fileName}' }, { label: 'onView', body: 'onView:${5:viewId}' }], + defaultSnippets: [ + { label: 'onLanguage', body: 'onLanguage:${1:languageId}' }, + { label: 'onCommand', body: 'onCommand:${2:commandId}' }, + { label: 'onDebug', body: 'onDebug:${3:type}' }, + { label: 'workspaceContains', body: 'workspaceContains:${4:filePattern}' }, + { label: 'onView', body: 'onView:${5:viewId}' }, + { label: '*', body: '*' } + ], } }, badges: { -- GitLab From 8132b809de081dbcf4a1a91011d6d1a46127e3a5 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Wed, 31 May 2017 08:41:57 -0700 Subject: [PATCH 0375/1347] Reduce number of colors used (#27497) --- .../parts/welcome/overlay/browser/welcomeOverlay.ts | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.ts b/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.ts index d5a435aac22..20c82ff7a7c 100644 --- a/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.ts +++ b/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.ts @@ -23,7 +23,8 @@ import { RawContextKey, IContextKey, IContextKeyService } from 'vs/platform/cont import { KeyCode } from 'vs/base/common/keyCodes'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; -import { registerColor, textPreformatForeground } from 'vs/platform/theme/common/colorRegistry'; +import { textPreformatForeground, foreground } from 'vs/platform/theme/common/colorRegistry'; +import { Color } from 'vs/base/common/color'; interface Key { id: string; @@ -238,15 +239,12 @@ Registry.as(Extensions.WorkbenchActions) // theming -const foreground = registerColor('welcomeOverlay.foreground', { dark: '#fff', light: '#000', hc: '#fff' }, localize('welcomeOverlay.foreground', 'Foreground color for the Interface Overview.')); -const background = registerColor('welcomeOverlay.background', { dark: '#00000085', light: '#FFFFFF85', hc: '#00000085' }, localize('welcomeOverlay.background', 'Background color for the Interface Overview.')); - registerThemingParticipant((theme, collector) => { const key = theme.getColor(foreground); if (key) { collector.addRule(`.monaco-workbench > .welcomeOverlay > .key { color: ${key}; }`); } - const backgroundColor = theme.getColor(background); + const backgroundColor = Color.fromHex(theme.type === 'light' ? '#FFFFFF85' : '#00000085'); if (backgroundColor) { collector.addRule(`.monaco-workbench > .welcomeOverlay { background: ${backgroundColor}; }`); } -- GitLab From a1ca777088ff455f7c1c397089db3ad3371b662b Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Wed, 31 May 2017 08:42:11 -0700 Subject: [PATCH 0376/1347] Color names (#27497) --- .../welcome/page/electron-browser/welcomePage.ts | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts index 6141d64d0bb..6773da75c39 100644 --- a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts +++ b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts @@ -447,8 +447,8 @@ class WelcomePage { // theming -const quickLinkBackground = registerColor('welcomePage.quickLinkBackground', { dark: null, light: null, hc: null }, localize('welcomePage.quickLinkBackground', 'Background color for the quick links on the Welcome page.')); -const quickLinkHoverBackground = registerColor('welcomePage.quickLinkHoverBackground', { dark: null, light: null, hc: null }, localize('welcomePage.quickLinkHoverBackground', 'Hover background color for the quick links on the Welcome page.')); +const buttonBackground = registerColor('welcomePage.buttonBackground', { dark: null, light: null, hc: null }, localize('welcomePage.buttonBackground', 'Background color for the buttons on the Welcome page.')); +const buttonHoverBackground = registerColor('welcomePage.buttonHoverBackground', { dark: null, light: null, hc: null }, localize('welcomePage.buttonHoverBackground', 'Hover background color for the buttons on the Welcome page.')); registerThemingParticipant((theme, collector) => { const foregroundColor = theme.getColor(foreground); @@ -459,13 +459,13 @@ registerThemingParticipant((theme, collector) => { if (descriptionColor) { collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .detail { color: ${descriptionColor}; }`); } - const color = getExtraColor(theme, quickLinkBackground, { dark: 'rgba(0, 0, 0, .2)', extra_dark: 'rgba(200, 235, 255, .042)', light: 'rgba(0,0,0,.04)', hc: 'black' }); - if (color) { - collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .commands li button { background: ${color}; }`); + const buttonColor = getExtraColor(theme, buttonBackground, { dark: 'rgba(0, 0, 0, .2)', extra_dark: 'rgba(200, 235, 255, .042)', light: 'rgba(0,0,0,.04)', hc: 'black' }); + if (buttonColor) { + collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .commands li button { background: ${buttonColor}; }`); } - const hover = getExtraColor(theme, quickLinkHoverBackground, { dark: 'rgba(200, 235, 255, .072)', extra_dark: 'rgba(200, 235, 255, .072)', light: 'rgba(0,0,0,.10)', hc: null }); - if (hover) { - collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .commands li button:hover { background: ${hover}; }`); + const buttonHoverColor = getExtraColor(theme, buttonHoverBackground, { dark: 'rgba(200, 235, 255, .072)', extra_dark: 'rgba(200, 235, 255, .072)', light: 'rgba(0,0,0,.10)', hc: null }); + if (buttonHoverColor) { + collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .commands li button:hover { background: ${buttonHoverColor}; }`); } const link = theme.getColor(textLinkForeground); if (link) { -- GitLab From ee52cacaf67af9026e50bd998562e1b7bfcb5e56 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Wed, 31 May 2017 17:49:25 +0200 Subject: [PATCH 0377/1347] Consistent name for overviewRuler.currentContentForeground. Fixes #27756 --- extensions/merge-conflict/src/mergeDecorator.ts | 4 ++-- src/vs/platform/theme/common/colorRegistry.ts | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/extensions/merge-conflict/src/mergeDecorator.ts b/extensions/merge-conflict/src/mergeDecorator.ts index be9e733a562..0dd5ad6f6c6 100644 --- a/extensions/merge-conflict/src/mergeDecorator.ts +++ b/extensions/merge-conflict/src/mergeDecorator.ts @@ -66,11 +66,11 @@ export default class MergeDectorator implements vscode.Disposable { // Create decorators if (config.enableDecorations || config.enableEditorOverview) { this.decorations['current.content'] = vscode.window.createTextEditorDecorationType( - this.generateBlockRenderOptions('merge.currentContentBackground', 'overviewRuler.currentContentForeground', config) + this.generateBlockRenderOptions('merge.currentContentBackground', 'editorOverviewRuler.currentContentForeground', config) ); this.decorations['incoming.content'] = vscode.window.createTextEditorDecorationType( - this.generateBlockRenderOptions('merge.incomingContentBackground', 'overviewRuler.incomingContentForeground', config) + this.generateBlockRenderOptions('merge.incomingContentBackground', 'editorOverviewRuler.incomingContentForeground', config) ); } diff --git a/src/vs/platform/theme/common/colorRegistry.ts b/src/vs/platform/theme/common/colorRegistry.ts index ffc6c33eb06..ce0e3fd190b 100644 --- a/src/vs/platform/theme/common/colorRegistry.ts +++ b/src/vs/platform/theme/common/colorRegistry.ts @@ -269,8 +269,8 @@ export const mergeCurrentContentBackground = registerColor('merge.currentContent export const mergeIncomingHeaderBackground = registerColor('merge.incomingHeaderBackground', { dark: incomingBaseColor, light: incomingBaseColor, hc: incomingBaseColor }, nls.localize('mergeIncomingHeaderBackground', 'Incoming header background in inline merge-conflict.')); export const mergeIncomingContentBackground = registerColor('merge.incomingContentBackground', { dark: transparent(mergeIncomingHeaderBackground, contentTransparency), light: transparent(mergeIncomingHeaderBackground, contentTransparency), hc: transparent(mergeIncomingHeaderBackground, contentTransparency) }, nls.localize('mergeIncomingContentBackground', 'Incoming content background in inline merge-conflict.')); -export const overviewRulerCurrentContentForeground = registerColor('overviewRuler.currentContentForeground', { dark: transparent(mergeCurrentHeaderBackground, rulerTransparency), light: transparent(mergeCurrentHeaderBackground, rulerTransparency), hc: transparent(mergeCurrentHeaderBackground, rulerTransparency) }, nls.localize('overviewRulerCurrentContentForeground', 'Current overview ruler foreground for inline merge-conflict.')); -export const overviewRulerIncomingContentForeground = registerColor('overviewRuler.incomingContentForeground', { dark: transparent(mergeIncomingHeaderBackground, rulerTransparency), light: transparent(mergeIncomingHeaderBackground, rulerTransparency), hc: transparent(mergeIncomingHeaderBackground, rulerTransparency) }, nls.localize('overviewRulerIncomingContentForeground', 'Incoming overview ruler foreground for inline merge-conflict.')); +export const overviewRulerCurrentContentForeground = registerColor('editorOverviewRuler.currentContentForeground', { dark: transparent(mergeCurrentHeaderBackground, rulerTransparency), light: transparent(mergeCurrentHeaderBackground, rulerTransparency), hc: transparent(mergeCurrentHeaderBackground, rulerTransparency) }, nls.localize('overviewRulerCurrentContentForeground', 'Current overview ruler foreground for inline merge-conflict.')); +export const overviewRulerIncomingContentForeground = registerColor('editorOverviewRuler.incomingContentForeground', { dark: transparent(mergeIncomingHeaderBackground, rulerTransparency), light: transparent(mergeIncomingHeaderBackground, rulerTransparency), hc: transparent(mergeIncomingHeaderBackground, rulerTransparency) }, nls.localize('overviewRulerIncomingContentForeground', 'Incoming overview ruler foreground for inline merge-conflict.')); // ----- color functions -- GitLab From f661def623de1491f1f1ac6c13c2e49d264df8f6 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Wed, 31 May 2017 09:02:49 -0700 Subject: [PATCH 0378/1347] Use 'textLink.activeForeground' (fixes #27499) --- .../parts/welcome/page/electron-browser/welcomePage.ts | 7 ++++++- .../walkThrough/electron-browser/walkThroughPart.ts | 7 ++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts index 6773da75c39..6081e05539a 100644 --- a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts +++ b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts @@ -35,7 +35,7 @@ import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { tildify } from 'vs/base/common/labels'; import { isLinux } from 'vs/base/common/platform'; import { IThemeService, registerThemingParticipant } from 'vs/platform/theme/common/themeService'; -import { registerColor, textLinkForeground, foreground, descriptionForeground, contrastBorder, activeContrastBorder } from 'vs/platform/theme/common/colorRegistry'; +import { registerColor, textLinkForeground, textLinkActiveForeground, foreground, descriptionForeground, contrastBorder, activeContrastBorder } from 'vs/platform/theme/common/colorRegistry'; import { getExtraColor } from 'vs/workbench/parts/welcome/walkThrough/node/walkThroughUtils'; used(); @@ -471,6 +471,11 @@ registerThemingParticipant((theme, collector) => { if (link) { collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage a { color: ${link}; }`); } + const activeLink = theme.getColor(textLinkActiveForeground); + if (activeLink) { + collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage a:hover, + .monaco-workbench > .part.editor > .content .welcomePage a:active { color: ${activeLink}; }`); + } const border = theme.getColor(contrastBorder); if (border) { collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .commands li button { border-color: ${border}; }`); diff --git a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts index f22fa7e0702..28d9042de6c 100644 --- a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts +++ b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts @@ -38,7 +38,7 @@ import { IPartService } from 'vs/workbench/services/part/common/partService'; import { IEditorOptions } from 'vs/editor/common/config/editorOptions'; import { IMessageService, Severity } from 'vs/platform/message/common/message'; import { IThemeService, registerThemingParticipant } from 'vs/platform/theme/common/themeService'; -import { registerColor, textLinkForeground, textPreformatForeground, contrastBorder, textBlockQuoteBackground, textBlockQuoteBorder } from 'vs/platform/theme/common/colorRegistry'; +import { registerColor, textLinkForeground, textLinkActiveForeground, textPreformatForeground, contrastBorder, textBlockQuoteBackground, textBlockQuoteBorder } from 'vs/platform/theme/common/colorRegistry'; import { getExtraColor } from 'vs/workbench/parts/welcome/walkThrough/node/walkThroughUtils'; export const WALK_THROUGH_FOCUS = new RawContextKey('interactivePlaygroundFocus', false); @@ -538,6 +538,11 @@ registerThemingParticipant((theme, collector) => { if (link) { collector.addRule(`.monaco-workbench > .part.editor > .content .walkThroughContent a { color: ${link}; }`); } + const activeLink = theme.getColor(textLinkActiveForeground); + if (activeLink) { + collector.addRule(`.monaco-workbench > .part.editor > .content .walkThroughContent a:hover, + .monaco-workbench > .part.editor > .content .walkThroughContent a:active { color: ${activeLink}; }`); + } const shortcut = theme.getColor(textPreformatForeground); if (shortcut) { collector.addRule(`.monaco-workbench > .part.editor > .content .walkThroughContent code, -- GitLab From 9e277b57537fa924632df4b345aea6c82d0221d6 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Wed, 31 May 2017 09:15:50 -0700 Subject: [PATCH 0379/1347] Use focus border color (fixes #27501) --- .../parts/welcome/page/electron-browser/welcomePage.ts | 6 +++++- .../welcome/walkThrough/electron-browser/walkThroughPart.ts | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts index 6081e05539a..2c0dda61a41 100644 --- a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts +++ b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts @@ -35,7 +35,7 @@ import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { tildify } from 'vs/base/common/labels'; import { isLinux } from 'vs/base/common/platform'; import { IThemeService, registerThemingParticipant } from 'vs/platform/theme/common/themeService'; -import { registerColor, textLinkForeground, textLinkActiveForeground, foreground, descriptionForeground, contrastBorder, activeContrastBorder } from 'vs/platform/theme/common/colorRegistry'; +import { registerColor, focusBorder, textLinkForeground, textLinkActiveForeground, foreground, descriptionForeground, contrastBorder, activeContrastBorder } from 'vs/platform/theme/common/colorRegistry'; import { getExtraColor } from 'vs/workbench/parts/welcome/walkThrough/node/walkThroughUtils'; used(); @@ -476,6 +476,10 @@ registerThemingParticipant((theme, collector) => { collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage a:hover, .monaco-workbench > .part.editor > .content .welcomePage a:active { color: ${activeLink}; }`); } + const focusColor = theme.getColor(focusBorder); + if (focusColor) { + collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage a:focus { outline-color: ${focusColor}; }`); + } const border = theme.getColor(contrastBorder); if (border) { collector.addRule(`.monaco-workbench > .part.editor > .content .welcomePage .commands li button { border-color: ${border}; }`); diff --git a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts index 28d9042de6c..7e2df964f9b 100644 --- a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts +++ b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts @@ -38,7 +38,7 @@ import { IPartService } from 'vs/workbench/services/part/common/partService'; import { IEditorOptions } from 'vs/editor/common/config/editorOptions'; import { IMessageService, Severity } from 'vs/platform/message/common/message'; import { IThemeService, registerThemingParticipant } from 'vs/platform/theme/common/themeService'; -import { registerColor, textLinkForeground, textLinkActiveForeground, textPreformatForeground, contrastBorder, textBlockQuoteBackground, textBlockQuoteBorder } from 'vs/platform/theme/common/colorRegistry'; +import { registerColor, focusBorder, textLinkForeground, textLinkActiveForeground, textPreformatForeground, contrastBorder, textBlockQuoteBackground, textBlockQuoteBorder } from 'vs/platform/theme/common/colorRegistry'; import { getExtraColor } from 'vs/workbench/parts/welcome/walkThrough/node/walkThroughUtils'; export const WALK_THROUGH_FOCUS = new RawContextKey('interactivePlaygroundFocus', false); @@ -543,6 +543,10 @@ registerThemingParticipant((theme, collector) => { collector.addRule(`.monaco-workbench > .part.editor > .content .walkThroughContent a:hover, .monaco-workbench > .part.editor > .content .walkThroughContent a:active { color: ${activeLink}; }`); } + const focusColor = theme.getColor(focusBorder); + if (focusColor) { + collector.addRule(`.monaco-workbench > .part.editor > .content .walkThroughContent a:focus { outline-color: ${focusColor}; }`); + } const shortcut = theme.getColor(textPreformatForeground); if (shortcut) { collector.addRule(`.monaco-workbench > .part.editor > .content .walkThroughContent code, -- GitLab From d1dd5d3bdfdf8d9ecc974c728614afe0dd0fd796 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Wed, 31 May 2017 09:20:05 -0700 Subject: [PATCH 0380/1347] Turn off minimaps (fixes #27502) --- .../welcome/walkThrough/electron-browser/walkThroughPart.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts index 7e2df964f9b..76a67b79d8e 100644 --- a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts +++ b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts @@ -430,7 +430,7 @@ export class WalkThroughPart extends BaseEditor { overviewRulerLanes: 3, fixedOverflowWidgets: true, lineNumbersMinChars: 1, - minimap: false, + minimap: { enabled: false }, }; } -- GitLab From 498beff5442e844c67febb3e8d297db6bfc96141 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 31 May 2017 18:27:17 +0200 Subject: [PATCH 0381/1347] Add descriptions to the activation events snippets (#27663) --- .../extensions/common/extensionsRegistry.ts | 35 +++++++++++++++---- 1 file changed, 29 insertions(+), 6 deletions(-) diff --git a/src/vs/platform/extensions/common/extensionsRegistry.ts b/src/vs/platform/extensions/common/extensionsRegistry.ts index b94a42edc8c..c950bdc66ff 100644 --- a/src/vs/platform/extensions/common/extensionsRegistry.ts +++ b/src/vs/platform/extensions/common/extensionsRegistry.ts @@ -183,12 +183,35 @@ const schema: IJSONSchema = { items: { type: 'string', defaultSnippets: [ - { label: 'onLanguage', body: 'onLanguage:${1:languageId}' }, - { label: 'onCommand', body: 'onCommand:${2:commandId}' }, - { label: 'onDebug', body: 'onDebug:${3:type}' }, - { label: 'workspaceContains', body: 'workspaceContains:${4:filePattern}' }, - { label: 'onView', body: 'onView:${5:viewId}' }, - { label: '*', body: '*' } + { + label: 'onLanguage', + description: nls.localize('vscode.extension.activationEvents.onLanguage', 'An activation event emitted whenever a file that resolves to the specified language gets opened.'), + body: 'onLanguage:${1:languageId}' + }, + { + label: 'onCommand', + description: nls.localize('vscode.extension.activationEvents.onCommand', 'An activation event emitted whenever the specified command gets invoked.'), + body: 'onCommand:${2:commandId}' + }, + { + label: 'onDebug', + description: nls.localize('vscode.extension.activationEvents.onDebug', 'An activation event emitted whenever a debug session of the specified type is started.'), + body: 'onDebug:${3:type}' + }, + { + label: 'workspaceContains', + description: nls.localize('vscode.extension.activationEvents.workspaceContains', 'An activation event emitted whenever a folder is opened that contains at least a file matching the specified glob pattern.'), + body: 'workspaceContains:${4:filePattern}' + }, + { + label: 'onView', + body: 'onView:${5:viewId}' + }, + { + label: '*', + description: nls.localize('vscode.extension.activationEvents.star', 'An activation event emitted on VS Code startup. To ensure a great end user experience, please use this activation event in your extension only when no other activation events combination works in your use-case.'), + body: '*' + } ], } }, -- GitLab From a857ee8fb514a35df286879bf40c14970229d0ad Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 31 May 2017 18:31:34 +0200 Subject: [PATCH 0382/1347] Click on menus on explorer title bar collapses the explorer (fixes #27648) --- src/vs/base/browser/ui/dropdown/dropdown.ts | 17 +++++++++++------ .../parts/files/browser/explorerViewlet.ts | 9 +++++++++ .../parts/files/browser/views/explorerView.ts | 2 +- 3 files changed, 21 insertions(+), 7 deletions(-) diff --git a/src/vs/base/browser/ui/dropdown/dropdown.ts b/src/vs/base/browser/ui/dropdown/dropdown.ts index f670bf899e4..e078d8ddc2b 100644 --- a/src/vs/base/browser/ui/dropdown/dropdown.ts +++ b/src/vs/base/browser/ui/dropdown/dropdown.ts @@ -8,7 +8,7 @@ import 'vs/css!./dropdown'; import { Builder, $ } from 'vs/base/browser/builder'; import { TPromise } from 'vs/base/common/winjs.base'; -import { Gesture, EventType } from 'vs/base/browser/touch'; +import { Gesture, EventType as GestureEventType } from 'vs/base/browser/touch'; import { ActionRunner, IAction } from 'vs/base/common/actions'; import { IActionItem } from 'vs/base/browser/ui/actionbar/actionbar'; import { EventEmitter } from 'vs/base/common/eventEmitter'; @@ -16,6 +16,7 @@ import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { IContextViewProvider } from 'vs/base/browser/ui/contextview/contextview'; import { IMenuOptions } from 'vs/base/browser/ui/menu/menu'; import { ResolvedKeybinding } from 'vs/base/common/keyCodes'; +import { EventHelper, EventType } from "vs/base/browser/dom"; export interface ILabelRenderer { (container: HTMLElement): IDisposable; @@ -50,11 +51,15 @@ export class BaseDropdown extends ActionRunner { }; } - this.$label.on(['mousedown', EventType.Tap], (e: Event) => { - e.preventDefault(); - e.stopPropagation(); - - this.show(); + this.$label.on([EventType.CLICK, EventType.MOUSE_DOWN, GestureEventType.Tap], (e: Event) => { + EventHelper.stop(e, true); // prevent default click behaviour to trigger + }).on([EventType.MOUSE_DOWN, GestureEventType.Tap], (e: Event) => { + // We want to show the context menu on dropdown so that as a user you can press and hold the + // mouse button, make a choice of action in the menu and release the mouse to trigger that + // action. + // Due to some weird bugs though, we delay showing the menu to unwind event stack + // (see https://github.com/Microsoft/vscode/issues/27648) + setTimeout(() => this.show(), 100); }).appendTo(this.$el); let cleanupFn = labelRenderer(this.$label.getHTMLElement()); diff --git a/src/vs/workbench/parts/files/browser/explorerViewlet.ts b/src/vs/workbench/parts/files/browser/explorerViewlet.ts index 9160ec7459b..2500f800ae7 100644 --- a/src/vs/workbench/parts/files/browser/explorerViewlet.ts +++ b/src/vs/workbench/parts/files/browser/explorerViewlet.ts @@ -99,6 +99,15 @@ export class ExplorerViewlet extends Viewlet { if (this.views.length === 1) { return this.views[0].getActions(); } + + return []; + } + + public getSecondaryActions(): IAction[] { + if (this.views.length === 1) { + return this.views[0].getSecondaryActions(); + } + return []; } diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index cad31f52e9f..5b3ec0df63e 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -131,7 +131,7 @@ export class ExplorerView extends CollapsibleViewletView { this.tree = this.createViewer($(this.treeContainer)); if (this.toolBar) { - this.toolBar.setActions(prepareActions(this.getActions()), [])(); + this.toolBar.setActions(prepareActions(this.getActions()), this.getSecondaryActions())(); } const onFileIconThemeChange = (fileIconTheme: IFileIconTheme) => { -- GitLab From f1a8632778e4574cf07b3cb162aa998e4a51aebc Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Wed, 31 May 2017 09:40:56 -0700 Subject: [PATCH 0383/1347] Fixes #27641 and Fixes #27708 --- .../contrib/suggest/browser/media/suggest.css | 15 ++++++++------- .../contrib/suggest/browser/suggestWidget.ts | 9 +++++---- 2 files changed, 13 insertions(+), 11 deletions(-) diff --git a/src/vs/editor/contrib/suggest/browser/media/suggest.css b/src/vs/editor/contrib/suggest/browser/media/suggest.css index 41ac9914b31..577af30bea5 100644 --- a/src/vs/editor/contrib/suggest/browser/media/suggest.css +++ b/src/vs/editor/contrib/suggest/browser/media/suggest.css @@ -109,7 +109,7 @@ /** Icon styles **/ -.monaco-editor .suggest-widget .details > .monaco-scrollable-element > .body > .close, +.monaco-editor .suggest-widget .details > .monaco-scrollable-element > .body > .header > .close, .monaco-editor .suggest-widget .monaco-list .monaco-list-row > .contents > .main > .readMore { opacity: 0.6; background-position: center center; @@ -118,7 +118,7 @@ cursor: pointer; } -.monaco-editor .suggest-widget .details > .monaco-scrollable-element > .body > .close { +.monaco-editor .suggest-widget .details > .monaco-scrollable-element > .body > .header > .close { background-image: url('./close.svg'); float: right; } @@ -127,7 +127,7 @@ background-image: url('./info.svg'); } -.monaco-editor .suggest-widget .details > .monaco-scrollable-element > .body > .close:hover, +.monaco-editor .suggest-widget .details > .monaco-scrollable-element > .body > .header > .close:hover, .monaco-editor .suggest-widget .monaco-list .monaco-list-row > .contents > .main > .readMore:hover { opacity: 1; } @@ -235,7 +235,7 @@ white-space: pre-wrap; } -.monaco-editor .suggest-widget .details > .monaco-scrollable-element > .body > .type { +.monaco-editor .suggest-widget .details > .monaco-scrollable-element > .body > .header > .type { flex: 2; overflow: hidden; text-overflow: ellipsis; @@ -244,7 +244,8 @@ margin: 0; } -.monaco-editor .suggest-widget .details > .monaco-scrollable-element > .body > p { +.monaco-editor .suggest-widget .details > .monaco-scrollable-element > .body > .docs, +.monaco-editor .suggest-widget .details > .monaco-scrollable-element > .body > .header { margin: 0; padding: 4px 5px; } @@ -256,8 +257,8 @@ /* High Contrast and Dark Theming */ -.monaco-editor.vs-dark .suggest-widget .details > .monaco-scrollable-element > .body > .close, -.monaco-editor.hc-black .suggest-widget .details > .monaco-scrollable-element > .body > .close { +.monaco-editor.vs-dark .suggest-widget .details > .monaco-scrollable-element > .body > .header > .close, +.monaco-editor.hc-black .suggest-widget .details > .monaco-scrollable-element > .body > .header > .close { background-image: url('./close-dark.svg'); } diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index 1ebbe971fac..6d704f5176d 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -189,6 +189,7 @@ class SuggestionDetails { private close: HTMLElement; private scrollbar: DomScrollableElement; private body: HTMLElement; + private header: HTMLElement; private type: HTMLElement; private docs: HTMLElement; private ariaLabel: string; @@ -211,10 +212,10 @@ class SuggestionDetails { append(this.el, this.scrollbar.getDomNode()); this.disposables.push(this.scrollbar); - this.close = append(this.body, $('span.close')); + this.header = append(this.body, $('.header')); + this.close = append(this.header, $('span.close')); this.close.title = nls.localize('readLess', "Read less...{0}", triggerKeybindingLabel); - this.type = append(this.body, $('p.type')); - + this.type = append(this.header, $('p.type')); this.docs = append(this.body, $('p.docs')); this.ariaLabel = null; @@ -242,7 +243,7 @@ class SuggestionDetails { this.type.innerText = item.suggestion.detail || ''; this.docs.textContent = item.suggestion.documentation; - this.el.style.height = this.type.offsetHeight + this.docs.offsetHeight + 'px'; + this.el.style.height = this.header.offsetHeight + this.docs.offsetHeight + 'px'; this.close.onmousedown = e => { e.preventDefault(); -- GitLab From db41a5fe474fad7b425b6cd22cb42256d77c2747 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Wed, 31 May 2017 10:20:03 -0700 Subject: [PATCH 0384/1347] Fixes #27690 Reveal range for the last selection --- extensions/emmet/src/matchTag.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/extensions/emmet/src/matchTag.ts b/extensions/emmet/src/matchTag.ts index a3e22642226..8037ca97d95 100644 --- a/extensions/emmet/src/matchTag.ts +++ b/extensions/emmet/src/matchTag.ts @@ -25,6 +25,7 @@ export function matchTag() { }); if (updatedSelections.length > 0) { editor.selections = updatedSelections; + editor.revealRange(editor.selections[updatedSelections.length - 1]); } } -- GitLab From 89fa243fc9aa731d01bc6254b728efa3cba4c546 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Wed, 31 May 2017 10:28:11 -0700 Subject: [PATCH 0385/1347] Hid Git actions from merge conflict (fixes #27563) --- extensions/git/package.json | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/extensions/git/package.json b/extensions/git/package.json index 0ea489cc812..62c735337de 100644 --- a/extensions/git/package.json +++ b/extensions/git/package.json @@ -531,7 +531,7 @@ { "command": "git.openFile", "group": "navigation", - "when": "config.git.enabled && scmProvider == git && isInDiffEditor && resourceScheme != extension" + "when": "config.git.enabled && scmProvider == git && isInDiffEditor && resourceScheme != extension && resourceScheme != merge-conflict.conflict-diff" }, { "command": "git.openChange", @@ -541,17 +541,17 @@ { "command": "git.stageSelectedRanges", "group": "2_git@1", - "when": "config.git.enabled && scmProvider == git && isInDiffEditor" + "when": "config.git.enabled && scmProvider == git && isInDiffEditor && resourceScheme != merge-conflict.conflict-diff" }, { "command": "git.unstageSelectedRanges", "group": "2_git@2", - "when": "config.git.enabled && scmProvider == git && isInDiffEditor" + "when": "config.git.enabled && scmProvider == git && isInDiffEditor && resourceScheme != merge-conflict.conflict-diff" }, { "command": "git.revertSelectedRanges", "group": "2_git@3", - "when": "config.git.enabled && scmProvider == git && isInDiffEditor" + "when": "config.git.enabled && scmProvider == git && isInDiffEditor && resourceScheme != merge-conflict.conflict-diff" } ] }, -- GitLab From b431336fde9e5cef026696bf4837a6e9278be85d Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Wed, 31 May 2017 10:29:50 -0700 Subject: [PATCH 0386/1347] Fixes #27690 Reveal range for edit point and select item --- extensions/emmet/src/editPoint.ts | 3 ++- extensions/emmet/src/selectItem.ts | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/extensions/emmet/src/editPoint.ts b/extensions/emmet/src/editPoint.ts index e7f468f29c7..5338c5012e1 100644 --- a/extensions/emmet/src/editPoint.ts +++ b/extensions/emmet/src/editPoint.ts @@ -15,9 +15,10 @@ export function fetchEditPoint(direction: string): void { let newSelections: vscode.Selection[] = []; editor.selections.forEach(selection => { let updatedSelection = direction === 'next' ? nextEditPoint(selection.anchor, editor) : prevEditPoint(selection.anchor, editor); - newSelections.push(updatedSelection); + newSelections.push(updatedSelection ? updatedSelection : selection); }); editor.selections = newSelections; + editor.revealRange(editor.selections[editor.selections.length - 1]); } function nextEditPoint(position: vscode.Position, editor: vscode.TextEditor): vscode.Selection { diff --git a/extensions/emmet/src/selectItem.ts b/extensions/emmet/src/selectItem.ts index b479c0ca74c..5ef47062ede 100644 --- a/extensions/emmet/src/selectItem.ts +++ b/extensions/emmet/src/selectItem.ts @@ -38,4 +38,5 @@ export function fetchSelectItem(direction: string): void { newSelections.push(updatedSelection ? updatedSelection : selection); }); editor.selections = newSelections; + editor.revealRange(editor.selections[editor.selections.length - 1]); } \ No newline at end of file -- GitLab From 8d9f0f561fb975d94fd9e3f2a460c5e7f7baa1e4 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Wed, 31 May 2017 10:36:08 -0700 Subject: [PATCH 0387/1347] Only bold press any key text --- .../parts/terminal/electron-browser/terminalInstance.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index b236832add4..bb4237e7aad 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -532,8 +532,8 @@ export class TerminalInstance implements ITerminalInstance { let message = typeof this._shellLaunchConfig.waitOnExit === 'string' ? this._shellLaunchConfig.waitOnExit : nls.localize('terminal.integrated.waitOnExit', 'Press any key to close the terminal'); - // Style the message to make it stand out from the rest of the output - message = `\n\x1b[40;37;1m${message}\x1b[0m`; + // Bold the message and add an extra new line to make it stand out from the rest of the output + message = `\n\x1b[1m${message}\x1b[0m`; this._xterm.writeln(message); // Disable all input if the terminal is exiting and listen for next keypress this._xterm.setOption('disableStdin', true); -- GitLab From 6aa3aca8ccaf2f4c3ebced37cb5b842604745acf Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Wed, 31 May 2017 10:35:05 -0700 Subject: [PATCH 0388/1347] Remove extra package.json (fixes #27754) --- extensions/merge-conflict/src/package.json | 722 --------------------- 1 file changed, 722 deletions(-) delete mode 100644 extensions/merge-conflict/src/package.json diff --git a/extensions/merge-conflict/src/package.json b/extensions/merge-conflict/src/package.json deleted file mode 100644 index 2f79e20bf7f..00000000000 --- a/extensions/merge-conflict/src/package.json +++ /dev/null @@ -1,722 +0,0 @@ -{ - "name": "git", - "publisher": "vscode", - "displayName": "git", - "description": "Git", - "version": "0.0.1", - "engines": { - "vscode": "^1.5.0" - }, - "aiKey": "AIF-d9b70cd4-b9f9-4d70-929b-a071c400b217", - "enableProposedApi": true, - "categories": [ - "Other" - ], - "activationEvents": [ - "*" - ], - "main": "./out/main", - "scripts": { - "compile": "gulp compile-extension:git", - "watch": "gulp watch-extension:git" - }, - "contributes": { - "commands": [ - { - "command": "git.clone", - "title": "%command.clone%", - "category": "Git" - }, - { - "command": "git.init", - "title": "%command.init%", - "category": "Git" - }, - { - "command": "git.refresh", - "title": "%command.refresh%", - "category": "Git", - "icon": { - "light": "resources/icons/light/refresh.svg", - "dark": "resources/icons/dark/refresh.svg" - } - }, - { - "command": "git.openChange", - "title": "%command.openChange%", - "category": "Git", - "icon": { - "light": "resources/icons/light/open-change.svg", - "dark": "resources/icons/dark/open-change.svg" - } - }, - { - "command": "git.openFile", - "title": "%command.openFile%", - "category": "Git", - "icon": { - "light": "resources/icons/light/open-file.svg", - "dark": "resources/icons/dark/open-file.svg" - } - }, - { - "command": "git.stage", - "title": "%command.stage%", - "category": "Git", - "icon": { - "light": "resources/icons/light/stage.svg", - "dark": "resources/icons/dark/stage.svg" - } - }, - { - "command": "git.stageAll", - "title": "%command.stageAll%", - "category": "Git", - "icon": { - "light": "resources/icons/light/stage.svg", - "dark": "resources/icons/dark/stage.svg" - } - }, - { - "command": "git.stageSelectedRanges", - "title": "%command.stageSelectedRanges%", - "category": "Git" - }, - { - "command": "git.revertSelectedRanges", - "title": "%command.revertSelectedRanges%", - "category": "Git" - }, - { - "command": "git.unstage", - "title": "%command.unstage%", - "category": "Git", - "icon": { - "light": "resources/icons/light/unstage.svg", - "dark": "resources/icons/dark/unstage.svg" - } - }, - { - "command": "git.unstageAll", - "title": "%command.unstageAll%", - "category": "Git", - "icon": { - "light": "resources/icons/light/unstage.svg", - "dark": "resources/icons/dark/unstage.svg" - } - }, - { - "command": "git.unstageSelectedRanges", - "title": "%command.unstageSelectedRanges%", - "category": "Git" - }, - { - "command": "git.clean", - "title": "%command.clean%", - "category": "Git", - "icon": { - "light": "resources/icons/light/clean.svg", - "dark": "resources/icons/dark/clean.svg" - } - }, - { - "command": "git.cleanAll", - "title": "%command.cleanAll%", - "category": "Git", - "icon": { - "light": "resources/icons/light/clean.svg", - "dark": "resources/icons/dark/clean.svg" - } - }, - { - "command": "git.commit", - "title": "%command.commit%", - "category": "Git", - "icon": { - "light": "resources/icons/light/check.svg", - "dark": "resources/icons/dark/check.svg" - } - }, - { - "command": "git.commitStaged", - "title": "%command.commitStaged%", - "category": "Git" - }, - { - "command": "git.commitStagedSigned", - "title": "%command.commitStagedSigned%", - "category": "Git" - }, - { - "command": "git.commitAll", - "title": "%command.commitAll%", - "category": "Git" - }, - { - "command": "git.commitAllSigned", - "title": "%command.commitAllSigned%", - "category": "Git" - }, - { - "command": "git.undoCommit", - "title": "%command.undoCommit%", - "category": "Git" - }, - { - "command": "git.checkout", - "title": "%command.checkout%", - "category": "Git" - }, - { - "command": "git.branch", - "title": "%command.branch%", - "category": "Git" - }, - { - "command": "git.pull", - "title": "%command.pull%", - "category": "Git" - }, - { - "command": "git.pullRebase", - "title": "%command.pullRebase%", - "category": "Git" - }, - { - "command": "git.push", - "title": "%command.push%", - "category": "Git" - }, - { - "command": "git.pushTo", - "title": "%command.pushTo%", - "category": "Git" - }, - { - "command": "git.sync", - "title": "%command.sync%", - "category": "Git" - }, - { - "command": "git.publish", - "title": "%command.publish%", - "category": "Git" - }, - { - "command": "git.showOutput", - "title": "%command.showOutput%", - "category": "Git" - }, - { - "command": "git.merge.accept.all-current", - "title": "Accept all current", - "category": "Git Merge" - }, - { - "category": "Git Merge", - "title": "Accept all incoming", - "command": "git.merge.accept.all-incoming" - }, - { - "category": "Git Merge", - "title": "Accept all both", - "command": "git.merge.accept.all-both" - }, - { - "category": "Git Merge", - "title": "Accept current", - "command": "git.merge.accept.current" - }, - { - "category": "Git Merge", - "title": "Accept incoming", - "command": "git.merge.accept.incoming" - }, - { - "category": "Git Merge", - "title": "Accept selection", - "command": "git.merge.accept.selection" - }, - { - "category": "Git Merge", - "title": "Accept both", - "command": "git.merge.accept.both" - }, - { - "category": "Git Merge", - "title": "Next conflict", - "command": "git.merge.next" - }, - { - "category": "Git Merge", - "title": "Previous conflict", - "command": "git.merge.previous" - }, - { - "category": "Git Merge", - "title": "Compare current conflict", - "command": "git.merge.compare" - } - ], - "keybindings": [ - { - "command": "git.merge.next", - "when": "editorTextFocus", - "key": "alt+m down" - }, - { - "command": "git.merge.previous", - "when": "editorTextFocus", - "key": "alt+m up" - }, - { - "command": "git.merge.accept.selection", - "when": "editorTextFocus", - "key": "alt+m enter" - }, - { - "command": "git.merge.accept.current", - "when": "editorTextFocus", - "key": "alt+m 1" - }, - { - "command": "git.merge.accept.incoming", - "when": "editorTextFocus", - "key": "alt+m 2" - }, - { - "command": "git.merge.accept.both", - "when": "editorTextFocus", - "key": "alt+m 3" - } - ], - "menus": { - "commandPalette": [ - { - "command": "git.clone", - "when": "config.git.enabled" - }, - { - "command": "git.init", - "when": "config.git.enabled && scmProvider == git && gitState == norepo" - }, - { - "command": "git.refresh", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.openFile", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.openChange", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.stage", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.stageAll", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.stageSelectedRanges", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.revertSelectedRanges", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.unstage", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.unstageAll", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.unstageSelectedRanges", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.clean", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.cleanAll", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.commit", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.commitStaged", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.commitStagedSigned", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.commitAll", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.commitAllSigned", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.undoCommit", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.checkout", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.branch", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.pull", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.pullRebase", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.push", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.pushTo", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.sync", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.publish", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.showOutput", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - } - ], - "scm/title": [ - { - "command": "git.init", - "group": "navigation", - "when": "config.git.enabled && scmProvider == git && gitState == norepo" - }, - { - "command": "git.commit", - "group": "navigation", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.refresh", - "group": "navigation", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.sync", - "group": "1_sync", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.pull", - "group": "1_sync", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.pullRebase", - "group": "1_sync", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.push", - "group": "1_sync", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.pushTo", - "group": "1_sync", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.publish", - "group": "2_publish", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.commitStaged", - "group": "3_commit", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.commitStagedSigned", - "group": "3_commit", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.commitAll", - "group": "3_commit", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.commitAllSigned", - "group": "3_commit", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.undoCommit", - "group": "3_commit", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.unstageAll", - "group": "4_stage", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.cleanAll", - "group": "4_stage", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - }, - { - "command": "git.showOutput", - "group": "5_output", - "when": "config.git.enabled && scmProvider == git && gitState == idle" - } - ], - "scm/resourceGroup/context": [ - { - "command": "git.stageAll", - "when": "config.git.enabled && scmProvider == git && gitState == idle && scmResourceGroup == merge", - "group": "1_modification" - }, - { - "command": "git.stageAll", - "when": "config.git.enabled && scmProvider == git && gitState == idle && scmResourceGroup == merge", - "group": "inline" - }, - { - "command": "git.unstageAll", - "when": "config.git.enabled && scmProvider == git && gitState == idle && scmResourceGroup == index", - "group": "1_modification" - }, - { - "command": "git.unstageAll", - "when": "config.git.enabled && scmProvider == git && gitState == idle && scmResourceGroup == index", - "group": "inline" - }, - { - "command": "git.cleanAll", - "when": "config.git.enabled && scmProvider == git && gitState == idle && scmResourceGroup == workingTree", - "group": "1_modification" - }, - { - "command": "git.stageAll", - "when": "config.git.enabled && scmProvider == git && gitState == idle && scmResourceGroup == workingTree", - "group": "1_modification" - }, - { - "command": "git.cleanAll", - "when": "config.git.enabled && scmProvider == git && gitState == idle && scmResourceGroup == workingTree", - "group": "inline" - }, - { - "command": "git.stageAll", - "when": "config.git.enabled && scmProvider == git && gitState == idle && scmResourceGroup == workingTree", - "group": "inline" - } - ], - "scm/resourceState/context": [ - { - "command": "git.stage", - "when": "config.git.enabled && scmProvider == git && gitState == idle && scmResourceGroup == merge", - "group": "1_modification" - }, - { - "command": "git.stage", - "when": "config.git.enabled && scmProvider == git && gitState == idle && scmResourceGroup == merge", - "group": "inline" - }, - { - "command": "git.openChange", - "when": "config.git.enabled && scmProvider == git && gitState == idle && scmResourceGroup == index", - "group": "navigation" - }, - { - "command": "git.openFile", - "when": "config.git.enabled && scmProvider == git && gitState == idle && scmResourceGroup == index", - "group": "navigation" - }, - { - "command": "git.unstage", - "when": "config.git.enabled && scmProvider == git && gitState == idle && scmResourceGroup == index", - "group": "1_modification" - }, - { - "command": "git.unstage", - "when": "config.git.enabled && scmProvider == git && gitState == idle && scmResourceGroup == index", - "group": "inline" - }, - { - "command": "git.openChange", - "when": "config.git.enabled && scmProvider == git && gitState == idle && scmResourceGroup == workingTree", - "group": "navigation" - }, - { - "command": "git.openFile", - "when": "config.git.enabled && scmProvider == git && gitState == idle && scmResourceGroup == workingTree", - "group": "navigation" - }, - { - "command": "git.stage", - "when": "config.git.enabled && scmProvider == git && gitState == idle && scmResourceGroup == workingTree", - "group": "1_modification" - }, - { - "command": "git.clean", - "when": "config.git.enabled && scmProvider == git && gitState == idle && scmResourceGroup == workingTree", - "group": "1_modification" - }, - { - "command": "git.clean", - "when": "config.git.enabled && scmProvider == git && gitState == idle && scmResourceGroup == workingTree", - "group": "inline" - }, - { - "command": "git.stage", - "when": "config.git.enabled && scmProvider == git && gitState == idle && scmResourceGroup == workingTree", - "group": "inline" - } - ], - "editor/title": [ - { - "command": "git.openFile", - "group": "navigation", - "when": "config.git.enabled && scmProvider == git && isInDiffEditor && resourceScheme != extension" - }, - { - "command": "git.openChange", - "group": "navigation", - "when": "config.git.enabled && scmProvider == git && !isInDiffEditor && resourceScheme != extension" - }, - { - "command": "git.stageSelectedRanges", - "group": "2_git@1", - "when": "config.git.enabled && scmProvider == git && isInDiffEditor" - }, - { - "command": "git.unstageSelectedRanges", - "group": "2_git@2", - "when": "config.git.enabled && scmProvider == git && isInDiffEditor" - }, - { - "command": "git.revertSelectedRanges", - "group": "2_git@3", - "when": "config.git.enabled && scmProvider == git && isInDiffEditor" - } - ] - }, - "configuration": { - "title": "Git", - "properties": { - "git.enabled": { - "type": "boolean", - "description": "%config.enabled%", - "default": true - }, - "git.path": { - "type": [ - "string", - "null" - ], - "description": "%config.path%", - "default": null, - "isExecutable": true - }, - "git.autorefresh": { - "type": "boolean", - "description": "%config.autorefresh%", - "default": true - }, - "git.autofetch": { - "type": "boolean", - "description": "%config.autofetch%", - "default": true - }, - "git.confirmSync": { - "type": "boolean", - "description": "%config.confirmSync%", - "default": true - }, - "git.countBadge": { - "type": "string", - "enum": [ - "all", - "tracked", - "off" - ], - "description": "%config.countBadge%", - "default": "all" - }, - "git.checkoutType": { - "type": "string", - "enum": [ - "all", - "local", - "tags", - "remote" - ], - "description": "%config.checkoutType%", - "default": "all" - }, - "git.ignoreLegacyWarning": { - "type": "boolean", - "description": "%config.ignoreLegacyWarning%", - "default": false - }, - "git.ignoreLimitWarning": { - "type": "boolean", - "description": "%config.ignoreLimitWarning%", - "default": false - }, - "git.defaultCloneDirectory": { - "type": "string", - "default": null, - "description": "%config.defaultCloneDirectory%" - }, - "git.enableSmartCommit": { - "type": "boolean", - "description": "%config.enableSmartCommit%", - "default": false - }, - "git.enableEditorMerge": { - "type": "boolean", - "description": "%config.enableEditorMerge%", - "default": true - } - } - } - }, - "dependencies": { - "iconv-lite": "0.4.15", - "vscode-extension-telemetry": "^0.0.7", - "vscode-nls": "^2.0.1" - }, - "devDependencies": { - "@types/mocha": "^2.2.41", - "@types/node": "^7.0.4", - "mocha": "^3.2.0" - } -} \ No newline at end of file -- GitLab From 005c78dbf07331e621b7a5570e31cd456f7927db Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Wed, 31 May 2017 10:39:31 -0700 Subject: [PATCH 0389/1347] Title case (fixes #27569) --- extensions/merge-conflict/package.nls.json | 16 ++++++++-------- .../merge-conflict/src/codelensProvider.ts | 8 ++++---- extensions/merge-conflict/src/commandHandler.ts | 2 +- extensions/merge-conflict/src/mergeDecorator.ts | 4 ++-- 4 files changed, 15 insertions(+), 15 deletions(-) diff --git a/extensions/merge-conflict/package.nls.json b/extensions/merge-conflict/package.nls.json index d991f872b44..b2927ca3431 100644 --- a/extensions/merge-conflict/package.nls.json +++ b/extensions/merge-conflict/package.nls.json @@ -1,14 +1,14 @@ { "command.category": "Merge Conflict", - "command.accept.all-incoming": "Accept all incoming", - "command.accept.all-both": "Accept all both", - "command.accept.current": "Accept current", - "command.accept.incoming": "Accept incoming", - "command.accept.selection": "Accept selection", + "command.accept.all-incoming": "Accept All Incoming", + "command.accept.all-both": "Accept All Both", + "command.accept.current": "Accept Current", + "command.accept.incoming": "Accept Incoming", + "command.accept.selection": "Accept Selection", "command.accept.both": "Accept Both", - "command.next": "Next conflict", - "command.previous": "Previous conflict", - "command.compare": "Compare current conflict", + "command.next": "Next Conflict", + "command.previous": "Previous Conflict", + "command.compare": "Compare Current Conflict", "config.title": "Merge Conflict", "config.codeLensEnabled": "Enable/disable merge conflict block CodeLens within editor", "config.decoratorsEnabled": "Enable/disable merge conflict decorators within editor" diff --git a/extensions/merge-conflict/src/codelensProvider.ts b/extensions/merge-conflict/src/codelensProvider.ts index 72135945054..aa7bc6e30e0 100644 --- a/extensions/merge-conflict/src/codelensProvider.ts +++ b/extensions/merge-conflict/src/codelensProvider.ts @@ -63,25 +63,25 @@ export default class MergeConflictCodeLensProvider implements vscode.CodeLensPro conflicts.forEach(conflict => { let acceptCurrentCommand: vscode.Command = { command: 'merge-conflict.accept.current', - title: localize('acceptCurrentChange', 'Accept current change'), + title: localize('acceptCurrentChange', 'Accept Current Change'), arguments: ['known-conflict', conflict] }; let acceptIncomingCommand: vscode.Command = { command: 'merge-conflict.accept.incoming', - title: localize('acceptIncomingChange', 'Accept incoming change'), + title: localize('acceptIncomingChange', 'Accept Incoming Change'), arguments: ['known-conflict', conflict] }; let acceptBothCommand: vscode.Command = { command: 'merge-conflict.accept.both', - title: localize('acceptBothChanges', 'Accept both changes'), + title: localize('acceptBothChanges', 'Accept Both Changes'), arguments: ['known-conflict', conflict] }; let diffCommand: vscode.Command = { command: 'merge-conflict.compare', - title: localize('compareChanges', 'Compare changes'), + title: localize('compareChanges', 'Compare Changes'), arguments: [conflict] }; diff --git a/extensions/merge-conflict/src/commandHandler.ts b/extensions/merge-conflict/src/commandHandler.ts index 41982c06307..fe3dbd67201 100644 --- a/extensions/merge-conflict/src/commandHandler.ts +++ b/extensions/merge-conflict/src/commandHandler.ts @@ -90,7 +90,7 @@ export default class CommandHandler implements vscode.Disposable { range = conflict.incoming.content; const rightUri = leftUri.with({ query: JSON.stringify(range) }); - const title = localize('compareChangesTitle', '{0}: Current changes ⟷ Incoming changes', fileName); + const title = localize('compareChangesTitle', '{0}: Current Changes ⟷ Incoming Changes', fileName); vscode.commands.executeCommand('vscode.diff', leftUri, rightUri, title); } diff --git a/extensions/merge-conflict/src/mergeDecorator.ts b/extensions/merge-conflict/src/mergeDecorator.ts index 0dd5ad6f6c6..d07e7fe5681 100644 --- a/extensions/merge-conflict/src/mergeDecorator.ts +++ b/extensions/merge-conflict/src/mergeDecorator.ts @@ -80,7 +80,7 @@ export default class MergeDectorator implements vscode.Disposable { backgroundColor: new vscode.ThemeColor('merge.currentHeaderBackground'), color: new vscode.ThemeColor('editor.foreground'), after: { - contentText: ' ' + localize('currentChange', '(Current change)'), + contentText: ' ' + localize('currentChange', '(Current Change)'), color: new vscode.ThemeColor('descriptionForeground') } }); @@ -95,7 +95,7 @@ export default class MergeDectorator implements vscode.Disposable { color: new vscode.ThemeColor('editor.foreground'), isWholeLine: this.decorationUsesWholeLine, after: { - contentText: ' ' + localize('incomingChange', '(Incoming change)'), + contentText: ' ' + localize('incomingChange', '(Incoming Change)'), color: new vscode.ThemeColor('descriptionForeground') } }); -- GitLab From e0c1e7d2429fa182b14eee4f6944f815e5e573e5 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Wed, 31 May 2017 11:06:43 -0700 Subject: [PATCH 0390/1347] Title case (fixes #27569) --- extensions/merge-conflict/src/mergeDecorator.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/extensions/merge-conflict/src/mergeDecorator.ts b/extensions/merge-conflict/src/mergeDecorator.ts index d07e7fe5681..0dd5ad6f6c6 100644 --- a/extensions/merge-conflict/src/mergeDecorator.ts +++ b/extensions/merge-conflict/src/mergeDecorator.ts @@ -80,7 +80,7 @@ export default class MergeDectorator implements vscode.Disposable { backgroundColor: new vscode.ThemeColor('merge.currentHeaderBackground'), color: new vscode.ThemeColor('editor.foreground'), after: { - contentText: ' ' + localize('currentChange', '(Current Change)'), + contentText: ' ' + localize('currentChange', '(Current change)'), color: new vscode.ThemeColor('descriptionForeground') } }); @@ -95,7 +95,7 @@ export default class MergeDectorator implements vscode.Disposable { color: new vscode.ThemeColor('editor.foreground'), isWholeLine: this.decorationUsesWholeLine, after: { - contentText: ' ' + localize('incomingChange', '(Incoming Change)'), + contentText: ' ' + localize('incomingChange', '(Incoming change)'), color: new vscode.ThemeColor('descriptionForeground') } }); -- GitLab From c45f29b2b3694d925bec33d82740937bc99bc1ca Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Wed, 31 May 2017 11:13:49 -0700 Subject: [PATCH 0391/1347] Track pending updates per editor (fixes #27570) --- .../merge-conflict/src/mergeDecorator.ts | 70 +++++++++++-------- 1 file changed, 39 insertions(+), 31 deletions(-) diff --git a/extensions/merge-conflict/src/mergeDecorator.ts b/extensions/merge-conflict/src/mergeDecorator.ts index 0dd5ad6f6c6..868f383f5d8 100644 --- a/extensions/merge-conflict/src/mergeDecorator.ts +++ b/extensions/merge-conflict/src/mergeDecorator.ts @@ -15,6 +15,7 @@ export default class MergeDectorator implements vscode.Disposable { private config: interfaces.IExtensionConfiguration; private tracker: interfaces.IDocumentMergeConflictTracker; + private updating = new Map(); constructor(private context: vscode.ExtensionContext, trackerService: interfaces.IDocumentMergeConflictTrackerService) { this.tracker = trackerService.createTracker('decorator'); @@ -146,47 +147,54 @@ export default class MergeDectorator implements vscode.Disposable { } // If we have a pending scan from the same origin, exit early. - if (this.tracker.isPending(editor.document)) { + if (this.updating.get(editor)) { return; } - let conflicts = await this.tracker.getConflicts(editor.document); + try { + this.updating.set(editor, true); - if (conflicts.length === 0) { - this.removeDecorations(editor); - return; - } + let conflicts = await this.tracker.getConflicts(editor.document); - // Store decorations keyed by the type of decoration, set decoration wants a "style" - // to go with it, which will match this key (see constructor); - let matchDecorations: { [key: string]: vscode.DecorationOptions[] } = {}; + if (conflicts.length === 0) { + this.removeDecorations(editor); + return; + } - let pushDecoration = (key: string, d: vscode.DecorationOptions) => { - matchDecorations[key] = matchDecorations[key] || []; - matchDecorations[key].push(d); - }; + // Store decorations keyed by the type of decoration, set decoration wants a "style" + // to go with it, which will match this key (see constructor); + let matchDecorations: { [key: string]: vscode.DecorationOptions[] } = {}; - conflicts.forEach(conflict => { - // TODO, this could be more effective, just call getMatchPositions once with a map of decoration to position - pushDecoration('current.content', { range: conflict.current.decoratorContent }); - pushDecoration('incoming.content', { range: conflict.incoming.decoratorContent }); + let pushDecoration = (key: string, d: vscode.DecorationOptions) => { + matchDecorations[key] = matchDecorations[key] || []; + matchDecorations[key].push(d); + }; - if (this.config.enableDecorations) { - pushDecoration('current.header', { range: conflict.current.header }); - pushDecoration('splitter', { range: conflict.splitter }); - pushDecoration('incoming.header', { range: conflict.incoming.header }); - } - }); + conflicts.forEach(conflict => { + // TODO, this could be more effective, just call getMatchPositions once with a map of decoration to position + pushDecoration('current.content', { range: conflict.current.decoratorContent }); + pushDecoration('incoming.content', { range: conflict.incoming.decoratorContent }); - // For each match we've generated, apply the generated decoration with the matching decoration type to the - // editor instance. Keys in both matches and decorations should match. - Object.keys(matchDecorations).forEach(decorationKey => { - let decorationType = this.decorations[decorationKey]; + if (this.config.enableDecorations) { + pushDecoration('current.header', { range: conflict.current.header }); + pushDecoration('splitter', { range: conflict.splitter }); + pushDecoration('incoming.header', { range: conflict.incoming.header }); + } + }); - if (decorationType) { - editor.setDecorations(decorationType, matchDecorations[decorationKey]); - } - }); + // For each match we've generated, apply the generated decoration with the matching decoration type to the + // editor instance. Keys in both matches and decorations should match. + Object.keys(matchDecorations).forEach(decorationKey => { + let decorationType = this.decorations[decorationKey]; + + if (decorationType) { + editor.setDecorations(decorationType, matchDecorations[decorationKey]); + } + }); + + } finally { + this.updating.delete(editor); + } } private removeDecorations(editor: vscode.TextEditor) { -- GitLab From fc2d062f999de5daa90041a1d6591fcc8b662d2c Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Wed, 31 May 2017 11:16:06 -0700 Subject: [PATCH 0392/1347] Comment --- extensions/merge-conflict/src/mergeDecorator.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/merge-conflict/src/mergeDecorator.ts b/extensions/merge-conflict/src/mergeDecorator.ts index 868f383f5d8..19429fc2385 100644 --- a/extensions/merge-conflict/src/mergeDecorator.ts +++ b/extensions/merge-conflict/src/mergeDecorator.ts @@ -146,7 +146,7 @@ export default class MergeDectorator implements vscode.Disposable { return; } - // If we have a pending scan from the same origin, exit early. + // If we have a pending scan from the same origin, exit early. (Cannot use this.tracker.isPending() because decorations are per editor.) if (this.updating.get(editor)) { return; } -- GitLab From ab6371af50c5abb988d43f04db3e5e5e93726071 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Wed, 31 May 2017 20:25:47 +0200 Subject: [PATCH 0393/1347] Fix #27663 --- src/vs/platform/extensions/common/extensionsRegistry.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/vs/platform/extensions/common/extensionsRegistry.ts b/src/vs/platform/extensions/common/extensionsRegistry.ts index c950bdc66ff..e1492b50885 100644 --- a/src/vs/platform/extensions/common/extensionsRegistry.ts +++ b/src/vs/platform/extensions/common/extensionsRegistry.ts @@ -205,7 +205,8 @@ const schema: IJSONSchema = { }, { label: 'onView', - body: 'onView:${5:viewId}' + body: 'onView:${5:viewId}', + description: nls.localize('vscode.extension.activationEvents.onView', 'An activation event emitted whenever the specified view is expanded.'), }, { label: '*', -- GitLab From d23b97b4626845f531befd19690fd8466a6c6e72 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Wed, 31 May 2017 20:29:19 +0200 Subject: [PATCH 0394/1347] ExthostTreeView: Check if children are null or undefined --- src/vs/workbench/api/node/extHostTreeViews.ts | 21 +++++++++++-------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/src/vs/workbench/api/node/extHostTreeViews.ts b/src/vs/workbench/api/node/extHostTreeViews.ts index 99e21c10c72..452e83b8068 100644 --- a/src/vs/workbench/api/node/extHostTreeViews.ts +++ b/src/vs/workbench/api/node/extHostTreeViews.ts @@ -125,15 +125,18 @@ class ExtHostTreeView extends Disposable { } private processAndMapElements(elements: T[]): TPromise { - return TPromise.join( - elements.filter(element => !!element) - .map(element => { - if (this.extChildrenElementsMap.has(element)) { - return TPromise.wrapError(localize('treeView.duplicateElement', 'Element {0} is already registered', element)); - } - return this.resolveElement(element); - })) - .then(treeItems => treeItems.filter(treeItem => !!treeItem)); + if (elements && elements.length) { + return TPromise.join( + elements.filter(element => !!element) + .map(element => { + if (this.extChildrenElementsMap.has(element)) { + return TPromise.wrapError(localize('treeView.duplicateElement', 'Element {0} is already registered', element)); + } + return this.resolveElement(element); + })) + .then(treeItems => treeItems.filter(treeItem => !!treeItem)); + } + return TPromise.as([]); } private resolveElement(element: T): TPromise { -- GitLab From 0913cd5b89de025df59b8d34153157c6fa5cc9ae Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Wed, 31 May 2017 11:33:36 -0700 Subject: [PATCH 0395/1347] Make terminal path dragging more robust Fixes #27511 --- .../electron-browser/terminalPanel.ts | 31 ++++++++++--------- 1 file changed, 17 insertions(+), 14 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts index a1a746a7bd2..c9a9c9a57a1 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts @@ -216,19 +216,20 @@ export class TerminalPanel extends Panel { } // Check if the file was dragged from the tree explorer - let url = e.dataTransfer.getData('URL'); - if (!url && e.dataTransfer.files.length > 0) { + let uri = e.dataTransfer.getData('URL'); + if (uri) { + uri = URI.parse(uri).path; + } else if (e.dataTransfer.files.length > 0) { // Check if the file was dragged from the filesystem - url = e.dataTransfer.files[0].path; + uri = URI.file(e.dataTransfer.files[0].path).path; } - const filePath = URI.parse(url).path; - if (!filePath) { + if (!uri) { return; } const terminal = this._terminalService.getActiveInstance(); - terminal.sendText(this._wrapPathInQuotes(filePath), false); + terminal.sendText(this._preparePathForTerminal(uri), false); } })); } @@ -292,20 +293,22 @@ export class TerminalPanel extends Panel { /** * Adds quotes to a path if it contains whitespaces */ - private _wrapPathInQuotes(path: string) { + private _preparePathForTerminal(path: string) { if (platform.isWindows) { if (/\s+/.test(path)) { return `"${path}"`; } return path; } - const charsToReplace: { a: string, b: string }[] = [ - { a: '\\', b: '\\\\' }, - { a: ' ', b: '\\ ' }, - { a: '\'', b: '\\\'' }, - { a: '"', b: '\\"' } - ]; - charsToReplace.forEach(chars => path = path.replace(chars.a, chars.b)); + path = path.replace(/(%5C|\\)/g, '\\\\'); + const charsToEscape = [' ', '\'', '"', '?', ':', ';']; + for (let i = 0; i < path.length; i++) { + const indexOfChar = charsToEscape.indexOf(path.charAt(i)); + if (indexOfChar >= 0) { + path = `${path.substring(0, i)}\\${path.charAt(i)}${path.substring(i + 1)}`; + i++; // Skip char due to escape char being added + } + } return path; } } -- GitLab From 508c7a7d505211897df805b0e750b8692d06d688 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Wed, 31 May 2017 20:34:19 +0200 Subject: [PATCH 0396/1347] Improve tree data provider documentation --- src/vs/vscode.proposed.d.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/vs/vscode.proposed.d.ts b/src/vs/vscode.proposed.d.ts index c4ec6306a25..6e1ea7f6d9f 100644 --- a/src/vs/vscode.proposed.d.ts +++ b/src/vs/vscode.proposed.d.ts @@ -351,11 +351,12 @@ declare module 'vscode' { } /** - * A data provider that provides tree data for a view + * A data provider that provides tree data */ export interface TreeDataProvider { /** * An optional event to signal that an element or root has changed. + * To signal that root has changed, do not pass any argument or pass `undefined` or `null`. */ onDidChangeTreeData?: Event; @@ -368,10 +369,10 @@ declare module 'vscode' { getTreeItem(element: T): TreeItem | Thenable; /** - * Get the children of `element` or root if no element (`undefined`) is passed. + * Get the children of `element` or root if no element is passed. * * @param element The element from which the provider gets children. Can be `undefined`. - * @return Children of `element` or root if no element (`undefined`) is passed. + * @return Children of `element` or root if no element is passed. */ getChildren(element?: T): ProviderResult; } -- GitLab From 00fe73336716dc33b9a39a845cff6a0e099988f0 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Wed, 31 May 2017 11:40:55 -0700 Subject: [PATCH 0397/1347] Make sure we decorate all visible editors (fixes #27574) --- extensions/merge-conflict/src/mergeDecorator.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/extensions/merge-conflict/src/mergeDecorator.ts b/extensions/merge-conflict/src/mergeDecorator.ts index 19429fc2385..ce25324e25f 100644 --- a/extensions/merge-conflict/src/mergeDecorator.ts +++ b/extensions/merge-conflict/src/mergeDecorator.ts @@ -36,9 +36,9 @@ export default class MergeDectorator implements vscode.Disposable { this.applyDecorationsFromEvent(event.document); }, null, this.context.subscriptions); - vscode.window.onDidChangeActiveTextEditor((e) => { - // New editor attempt to apply - this.applyDecorations(e); + vscode.window.onDidChangeVisibleTextEditors((e) => { + // Any of which could be new (not just the active one). + e.forEach(e => this.applyDecorations(e)); }, null, this.context.subscriptions); } -- GitLab From 09ce1ccb2bfbff7290ef4d4edc94120f3013f0ee Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Wed, 31 May 2017 11:50:20 -0700 Subject: [PATCH 0398/1347] Make sure we don't apply decorations to disposed editors --- extensions/merge-conflict/src/mergeDecorator.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/extensions/merge-conflict/src/mergeDecorator.ts b/extensions/merge-conflict/src/mergeDecorator.ts index ce25324e25f..1b419908847 100644 --- a/extensions/merge-conflict/src/mergeDecorator.ts +++ b/extensions/merge-conflict/src/mergeDecorator.ts @@ -155,6 +155,9 @@ export default class MergeDectorator implements vscode.Disposable { this.updating.set(editor, true); let conflicts = await this.tracker.getConflicts(editor.document); + if (vscode.window.visibleTextEditors.indexOf(editor) === -1) { + return; + } if (conflicts.length === 0) { this.removeDecorations(editor); -- GitLab From 93b38d1092ec8efe22597a3769780e792f7d4042 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 31 May 2017 20:57:57 +0200 Subject: [PATCH 0399/1347] Fixes #24712: remove code that tries to preserve editor options, but is incorrect --- src/vs/workbench/common/editor.ts | 20 +------------------- 1 file changed, 1 insertion(+), 19 deletions(-) diff --git a/src/vs/workbench/common/editor.ts b/src/vs/workbench/common/editor.ts index 3767ac95928..d42dd606002 100644 --- a/src/vs/workbench/common/editor.ts +++ b/src/vs/workbench/common/editor.ts @@ -10,12 +10,11 @@ import * as objects from 'vs/base/common/objects'; import types = require('vs/base/common/types'); import URI from 'vs/base/common/uri'; import { IDisposable, dispose, Disposable } from 'vs/base/common/lifecycle'; -import { IEditor, ICommonCodeEditor, IEditorViewState, IModel } from 'vs/editor/common/editorCommon'; +import { IEditor, IEditorViewState, IModel } from 'vs/editor/common/editorCommon'; import { IEditorInput, IEditorModel, IEditorOptions, ITextEditorOptions, IBaseResourceInput, Position, Verbosity } from 'vs/platform/editor/common/editor'; import { SyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import { IInstantiationService, IConstructorSignature0 } from 'vs/platform/instantiation/common/instantiation'; import { RawContextKey } from 'vs/platform/contextkey/common/contextkey'; -import * as editorOptions from 'vs/editor/common/config/editorOptions'; export const TextCompareEditorVisible = new RawContextKey('textCompareEditorVisible', false); @@ -586,7 +585,6 @@ export class TextEditorOptions extends EditorOptions { private revealInCenterIfOutsideViewport: boolean; private editorViewState: IEditorViewState; - private editorOptions: editorOptions.IEditorOptions; public static from(input: IBaseResourceInput): TextEditorOptions { let options: TextEditorOptions = null; @@ -691,17 +689,6 @@ export class TextEditorOptions extends EditorOptions { // View state options.editorViewState = editor.saveViewState(); - // Selected editor options - const codeEditor = editor; - if (typeof codeEditor.getConfiguration === 'function') { - const config = codeEditor.getConfiguration(); - if (config && config.viewInfo && config.wrappingInfo) { - options.editorOptions = Object.create(null); - options.editorOptions.renderWhitespace = config.viewInfo.renderWhitespace; - options.editorOptions.renderControlCharacters = config.viewInfo.renderControlCharacters; - options.editorOptions.wordWrap = config.wrappingInfo.isViewportWrapping ? 'on' : 'off'; - } - } return options; } @@ -712,11 +699,6 @@ export class TextEditorOptions extends EditorOptions { */ public apply(editor: IEditor): boolean { - // Editor options - if (this.editorOptions) { - editor.updateOptions(this.editorOptions); - } - // View state return this.applyViewState(editor); } -- GitLab From c7f91ca6bc02d657e73db8a02a9bd720c1ec67c8 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 31 May 2017 21:17:41 +0200 Subject: [PATCH 0400/1347] Fixes #27766: Disable wrapping when a screen reader is detected --- src/vs/editor/common/config/editorOptions.ts | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/src/vs/editor/common/config/editorOptions.ts b/src/vs/editor/common/config/editorOptions.ts index 24ea09ddf31..b0586e45307 100644 --- a/src/vs/editor/common/config/editorOptions.ts +++ b/src/vs/editor/common/config/editorOptions.ts @@ -1760,7 +1760,17 @@ export class InternalEditorOptionsFactory { const wordWrapColumn = opts.wordWrapColumn; const wordWrapMinified = opts.wordWrapMinified; - if (wordWrapMinified && env.isDominatedByLongLines) { + if (env.accessibilitySupport === platform.AccessibilitySupport.Enabled) { + // See https://github.com/Microsoft/vscode/issues/27766 + // Never enable wrapping when a screen reader is attached + // because arrow down etc. will not move the cursor in the way + // a screen reader expects. + bareWrappingInfo = { + isWordWrapMinified: false, + isViewportWrapping: false, + wrappingColumn: -1 + }; + } else if (wordWrapMinified && env.isDominatedByLongLines) { // Force viewport width wrapping if model is dominated by long lines bareWrappingInfo = { isWordWrapMinified: true, -- GitLab From b5a1ecb64cd67d844c046419229c2ba08961c394 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Wed, 31 May 2017 12:36:58 -0700 Subject: [PATCH 0401/1347] Fixes #27615 --- src/vs/editor/contrib/suggest/browser/suggestWidget.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index 6d704f5176d..00c80169328 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -61,6 +61,9 @@ function matchesColor(text: string) { } function canExpandCompletionItem(item: ICompletionItem) { + if (!item) { + return false; + } const suggestion = item.suggestion; if (suggestion.documentation) { return true; @@ -611,7 +614,8 @@ export class SuggestWidget implements IContentWidget, IDelegate case State.Open: hide(this.messageElement); show(this.listElement); - if (this.storageService.getBoolean('expandSuggestionDocs', StorageScope.GLOBAL, expandSuggestionDocsByDefault)) { + if (this.storageService.getBoolean('expandSuggestionDocs', StorageScope.GLOBAL, expandSuggestionDocsByDefault) + && canExpandCompletionItem(this.list.getFocusedElements()[0])) { show(this.details.element); this.expandSideOrBelow(); } else { -- GitLab From 11c717ef23a92dda70a4657391ae14a1c45e9ab8 Mon Sep 17 00:00:00 2001 From: Sam El-Husseini Date: Wed, 31 May 2017 13:25:45 -0700 Subject: [PATCH 0402/1347] Avoiding a number of Android IME keyboard issues by turning autocomplete to off in the text area. (monaco-editor) --- src/vs/editor/browser/controller/textAreaHandler.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/vs/editor/browser/controller/textAreaHandler.ts b/src/vs/editor/browser/controller/textAreaHandler.ts index e927fcb4ab1..ab478c59ad4 100644 --- a/src/vs/editor/browser/controller/textAreaHandler.ts +++ b/src/vs/editor/browser/controller/textAreaHandler.ts @@ -108,6 +108,7 @@ export class TextAreaHandler extends ViewPart { this.textArea.setAttribute('wrap', 'off'); this.textArea.setAttribute('autocorrect', 'off'); this.textArea.setAttribute('autocapitalize', 'off'); + this.textArea.setAttribute('autocomplete', 'off'); this.textArea.setAttribute('spellcheck', 'false'); this.textArea.setAttribute('aria-label', conf.viewInfo.ariaLabel); this.textArea.setAttribute('role', 'textbox'); -- GitLab From aa921aa2915aeb41262f18180f22ba3d0d34888f Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Wed, 31 May 2017 13:38:23 -0700 Subject: [PATCH 0403/1347] Check for special URLs (fixes #27603) (#27781) --- extensions/typescript/src/typescriptMain.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/typescript/src/typescriptMain.ts b/extensions/typescript/src/typescriptMain.ts index 9c207250932..3938f9888f2 100644 --- a/extensions/typescript/src/typescriptMain.ts +++ b/extensions/typescript/src/typescriptMain.ts @@ -613,7 +613,7 @@ class TypeScriptServiceClientHost implements ITypescriptServiceClientHost { } private findLanguage(file: string): Thenable { - return workspace.openTextDocument(file).then((doc: TextDocument) => { + return workspace.openTextDocument(this.client.asUrl(file)).then((doc: TextDocument) => { for (const language of this.languages) { if (language.handles(file, doc)) { return language; -- GitLab From eb097f89a64d702702b90c46810a1cf46b670739 Mon Sep 17 00:00:00 2001 From: Greg Van Liew Date: Wed, 31 May 2017 13:38:40 -0700 Subject: [PATCH 0404/1347] ATA is Automatic Type Acquisition (#27760) --- extensions/typescript/package.nls.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/extensions/typescript/package.nls.json b/extensions/typescript/package.nls.json index 6aab169b6fb..374860ba9c4 100644 --- a/extensions/typescript/package.nls.json +++ b/extensions/typescript/package.nls.json @@ -36,8 +36,8 @@ "typescript.selectTypeScriptVersion.title": "Select TypeScript Version", "jsDocCompletion.enabled": "Enable/disable auto JSDoc comments", "javascript.implicitProjectConfig.checkJs": "Enable/disable semantic checking of JavaScript files. Existing jsconfig.json or tsconfig.json files override this setting. Requires TypeScript >=2.3.1.", - "typescript.npm": "Specifies the path to the NPM install used for automatic typings acquisition. Requires TypeScript >= 2.3.4", - "typescript.check.npmIsInstalled": "Check if NPM is installed for automatic typings acquisition", + "typescript.npm": "Specifies the path to the NPM install used for Automatic Type Acquisition. Requires TypeScript >= 2.3.4.", + "typescript.check.npmIsInstalled": "Check if NPM is installed for Automatic Type Acquisition.", "javascript.nameSuggestions": "Enable/disable including unique names from the file in JavaScript suggestion lists.", "typescript.tsc.autoDetect": "Controls whether auto detection of tsc tasks is on or off." } -- GitLab From 0b2249b4232697bd12fcd7d70a891f1e069f48ac Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Wed, 31 May 2017 13:43:03 -0700 Subject: [PATCH 0405/1347] Fixes #27767 --- extensions/emmet/package.json | 4 ++-- extensions/emmet/src/emmetCompletionProvider.ts | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/extensions/emmet/package.json b/extensions/emmet/package.json index 177d7be2cec..bf96e3d75fd 100644 --- a/extensions/emmet/package.json +++ b/extensions/emmet/package.json @@ -35,12 +35,12 @@ "type": "object", "title": "Emmet configuration", "properties": { - "emmet.suggestExpandedAbbreviation": { + "emmet.showExpandedAbbreviation": { "type": "boolean", "default": true, "description": "Shows expanded emmet abbreviations as suggestions" }, - "emmet.suggestAbbreviations": { + "emmet.showAbbreviationSuggestions": { "type": "boolean", "default": true, "description": "Shows possible emmet abbreviations as suggestions" diff --git a/extensions/emmet/src/emmetCompletionProvider.ts b/extensions/emmet/src/emmetCompletionProvider.ts index 8e77e0cec84..cbd5b750ae2 100644 --- a/extensions/emmet/src/emmetCompletionProvider.ts +++ b/extensions/emmet/src/emmetCompletionProvider.ts @@ -29,7 +29,7 @@ export class EmmetCompletionItemProvider implements vscode.CompletionItemProvide } function getExpandedAbbreviation(document: vscode.TextDocument, position: vscode.Position): vscode.CompletionItem { - if (!vscode.workspace.getConfiguration('emmet')['suggestExpandedAbbreviation']) { + if (!vscode.workspace.getConfiguration('emmet')['showExpandedAbbreviation']) { return; } let [rangeToReplace, wordToExpand] = extractAbbreviation(position); @@ -72,7 +72,7 @@ function removeTabStops(expandedWord: string): string { return expandedWord.replace(/\$\{\d+\}/g, '').replace(/\$\{\d+:([^\}]+)\}/g, '$1'); } function getAbbreviationSuggestions(syntax: string, prefix: string, skipExactMatch: boolean) { - if (!vscode.workspace.getConfiguration('emmet')['suggestAbbreviations'] || !prefix || isStyleSheet(syntax)) { + if (!vscode.workspace.getConfiguration('emmet')['showAbbreviationSuggestions'] || !prefix || isStyleSheet(syntax)) { return []; } -- GitLab From d7757bd8ee610f1a580080fed404bf039e44f674 Mon Sep 17 00:00:00 2001 From: Ben Stein Date: Wed, 31 May 2017 16:42:11 -0500 Subject: [PATCH 0406/1347] Initial work on #10023. Modified terminalInstance to expose setTitle and fire the onTitleChanged event when it's called. Added workbench.action.terminal.rename contribution from the workbench and the action that fires when it's run. --- .../parts/terminal/common/terminal.ts | 5 +++ .../electron-browser/terminal.contribution.ts | 3 +- .../electron-browser/terminalActions.ts | 30 +++++++++++++++++ .../electron-browser/terminalInstance.ts | 33 +++++++++++++++---- 4 files changed, 64 insertions(+), 7 deletions(-) diff --git a/src/vs/workbench/parts/terminal/common/terminal.ts b/src/vs/workbench/parts/terminal/common/terminal.ts index 1093b3ee7e0..502dc642b8a 100644 --- a/src/vs/workbench/parts/terminal/common/terminal.ts +++ b/src/vs/workbench/parts/terminal/common/terminal.ts @@ -325,4 +325,9 @@ export interface ITerminalInstance { * Experimental: Call to enable onData to be passed over IPC to the extension host. */ enableApiOnData(): void; + + /** + * Sets the title of the terminal instance. + */ + setTitle(title: string): void; } diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts index 17e931a643b..b502d20a6aa 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts @@ -18,7 +18,7 @@ import { TERMINAL_DEFAULT_SHELL_LINUX, TERMINAL_DEFAULT_SHELL_OSX, TERMINAL_DEFA import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/workbench/common/actionRegistry'; import { KeyCode, KeyMod } from 'vs/base/common/keyCodes'; import { ContextKeyExpr } from 'vs/platform/contextkey/common/contextkey'; -import { KillTerminalAction, CopyTerminalSelectionAction, CreateNewTerminalAction, FocusActiveTerminalAction, FocusNextTerminalAction, FocusPreviousTerminalAction, FocusTerminalAtIndexAction, SelectDefaultShellWindowsTerminalAction, RunSelectedTextInTerminalAction, RunActiveFileInTerminalAction, ScrollDownTerminalAction, ScrollDownPageTerminalAction, ScrollToBottomTerminalAction, ScrollUpTerminalAction, ScrollUpPageTerminalAction, ScrollToTopTerminalAction, TerminalPasteAction, ToggleTerminalAction, ClearTerminalAction, AllowWorkspaceShellTerminalCommand, DisallowWorkspaceShellTerminalCommand } from 'vs/workbench/parts/terminal/electron-browser/terminalActions'; +import { KillTerminalAction, CopyTerminalSelectionAction, CreateNewTerminalAction, FocusActiveTerminalAction, FocusNextTerminalAction, FocusPreviousTerminalAction, FocusTerminalAtIndexAction, SelectDefaultShellWindowsTerminalAction, RunSelectedTextInTerminalAction, RunActiveFileInTerminalAction, ScrollDownTerminalAction, ScrollDownPageTerminalAction, ScrollToBottomTerminalAction, ScrollUpTerminalAction, ScrollUpPageTerminalAction, ScrollToTopTerminalAction, TerminalPasteAction, ToggleTerminalAction, ClearTerminalAction, AllowWorkspaceShellTerminalCommand, DisallowWorkspaceShellTerminalCommand, RenameTerminalAction } from 'vs/workbench/parts/terminal/electron-browser/terminalActions'; import { Registry } from 'vs/platform/platform'; import { ShowAllCommandsAction } from 'vs/workbench/parts/quickopen/browser/commandsHandler'; import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; @@ -268,5 +268,6 @@ if (platform.isWindows) { } actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(AllowWorkspaceShellTerminalCommand, AllowWorkspaceShellTerminalCommand.ID, AllowWorkspaceShellTerminalCommand.LABEL), 'Terminal: Allow Workspace Shell Configuration', category); actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(DisallowWorkspaceShellTerminalCommand, DisallowWorkspaceShellTerminalCommand.ID, DisallowWorkspaceShellTerminalCommand.LABEL), 'Terminal: Disallow Workspace Shell Configuration', category); +actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(RenameTerminalAction, RenameTerminalAction.ID, RenameTerminalAction.LABEL), 'Terminal: Rename', category); registerColors(); diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts index 3b62f9642ed..a4e80114abc 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts @@ -17,6 +17,7 @@ import { IPanelService } from 'vs/workbench/services/panel/common/panelService'; import { IMessageService, Severity } from 'vs/platform/message/common/message'; import { attachSelectBoxStyler } from 'vs/platform/theme/common/styler'; import { IThemeService } from 'vs/platform/theme/common/themeService'; +import { IQuickOpenService } from 'vs/platform/quickOpen/common/quickOpen'; export class ToggleTerminalAction extends TogglePanelAction { @@ -533,3 +534,32 @@ export class DisallowWorkspaceShellTerminalCommand extends Action { return TPromise.as(void 0); } } + +export class RenameTerminalAction extends Action { + + public static ID = 'workbench.action.terminal.rename'; + public static LABEL = nls.localize('workbench.action.terminal.rename', "Rename"); + + constructor( + id: string, label: string, + @IQuickOpenService private quickOpenService: IQuickOpenService, + @ITerminalService private terminalService: ITerminalService + ) { + super(id, label); + } + + public run(): TPromise { + const terminalInstance = this.terminalService.getActiveInstance(); + if (!terminalInstance) { + return TPromise.as(void 0); + } + return this.quickOpenService.input({ + prompt: nls.localize('workbench.action.terminal.rename.prompt', "Enter terminal name"), + }).then(name => { + if (name) { + terminalInstance.setTitle(name); + } + }); + + } +} \ No newline at end of file diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index 3b320363826..98dbc2f2654 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -479,12 +479,13 @@ export class TerminalInstance implements ITerminalInstance { }); if (!shell.name) { // Only listen for process title changes when a name is not provided - this._process.on('message', (message) => { - if (message.type === 'title') { - this._title = message.content ? message.content : ''; - this._onTitleChanged.fire(this._title); - } - }); + this._process.on('message', this._onPtyProcessMessageTitleChanged); + // this._process.on('message', (message) => { + // if (message.type === 'title') { + // this._title = message.content ? message.content : ''; + // this._onTitleChanged.fire(this._title); + // } + // }); } this._process.on('message', (message) => { if (message.type === 'pid') { @@ -561,6 +562,13 @@ export class TerminalInstance implements ITerminalInstance { } } + private _onPtyProcessMessageTitleChanged(message: any): void { + if (message.type === 'title') { + this._title = message.content ? message.content : ''; + this._onTitleChanged.fire(this._title); + } + } + private _attachPressAnyKeyToCloseListener() { this._processDisposables.push(dom.addDisposableListener(this._xterm.textarea, 'keypress', (event: KeyboardEvent) => { this.dispose(); @@ -761,6 +769,19 @@ export class TerminalInstance implements ITerminalInstance { public static setTerminalProcessFactory(factory: ITerminalProcessFactory): void { this._terminalProcessFactory = factory; } + + public setTitle(title: string): void { + const oldTitle = this._title; + if (title !== oldTitle) { + this._title = title; + this._onTitleChanged.fire(title); + } + + // if the title is set via API, unregister the handler that automatically updates the terminal name + if (this._process) { + this._process.removeListener('message', this._onPtyProcessMessageTitleChanged); + } + } } registerThemingParticipant((theme: ITheme, collector: ICssStyleCollector) => { -- GitLab From cc0d24a24adb01d3f759309fa185af76fdbbc816 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 31 May 2017 14:44:37 -0700 Subject: [PATCH 0407/1347] Fix shrinkwrap of ts --- extensions/npm-shrinkwrap.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/npm-shrinkwrap.json b/extensions/npm-shrinkwrap.json index c7036103d67..82311e47d81 100644 --- a/extensions/npm-shrinkwrap.json +++ b/extensions/npm-shrinkwrap.json @@ -3,7 +3,7 @@ "version": "0.0.1", "dependencies": { "typescript": { - "version": "2.3.4,", + "version": "2.3.4", "from": "typescript@typescript@2.3.4", "resolved": "https://registry.npmjs.org/typescript/-/typescript-2.3.4.tgz" } -- GitLab From 717c93ae17963c37758dd0b1178f8a09362c54d8 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 31 May 2017 15:06:51 -0700 Subject: [PATCH 0408/1347] Fix ts shrinkwrap --- extensions/npm-shrinkwrap.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/npm-shrinkwrap.json b/extensions/npm-shrinkwrap.json index 82311e47d81..278e305e39b 100644 --- a/extensions/npm-shrinkwrap.json +++ b/extensions/npm-shrinkwrap.json @@ -4,7 +4,7 @@ "dependencies": { "typescript": { "version": "2.3.4", - "from": "typescript@typescript@2.3.4", + "from": "typescript@2.3.4", "resolved": "https://registry.npmjs.org/typescript/-/typescript-2.3.4.tgz" } } -- GitLab From ca923a5ee127fb35caa5025dc5948ef9ee4db6db Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Wed, 31 May 2017 15:16:22 -0700 Subject: [PATCH 0409/1347] Implement oncancel (fixes #27638) --- src/vs/workbench/parts/search/browser/openAnythingHandler.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/vs/workbench/parts/search/browser/openAnythingHandler.ts b/src/vs/workbench/parts/search/browser/openAnythingHandler.ts index 113adfd286d..64c2f66afeb 100644 --- a/src/vs/workbench/parts/search/browser/openAnythingHandler.ts +++ b/src/vs/workbench/parts/search/browser/openAnythingHandler.ts @@ -229,6 +229,10 @@ export class OpenAnythingHandler extends QuickOpenHandler { this.pendingSearch = null; this.messageService.show(Severity.Error, error); }); + }, () => { + resultPromises.forEach(resultPromise => { + resultPromise.cancel(); + }); }); return this.pendingSearch; -- GitLab From b87307ee8d5999ea8ce507a8706817124150ed07 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 31 May 2017 15:18:41 -0700 Subject: [PATCH 0410/1347] Correctly set ts version in package.json --- extensions/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/package.json b/extensions/package.json index 18e2c7dafbc..180253c59ae 100644 --- a/extensions/package.json +++ b/extensions/package.json @@ -3,7 +3,7 @@ "version": "0.0.1", "description": "Dependencies shared by all extensions", "dependencies": { - "typescript": "typescript@2.3.4" + "typescript": "2.3.4" }, "scripts": { "postinstall": "node ./postinstall" -- GitLab From 06fd9024acbaf7a38a6084ea8d995fe4edbe6403 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 31 May 2017 15:38:22 -0700 Subject: [PATCH 0411/1347] Add info about typescript.npm to warning message Fixes #27707 --- extensions/typescript/src/utils/typingsStatus.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/typescript/src/utils/typingsStatus.ts b/extensions/typescript/src/utils/typingsStatus.ts index 9bdbd6d1070..33c4a85c7d6 100644 --- a/extensions/typescript/src/utils/typingsStatus.ts +++ b/extensions/typescript/src/utils/typingsStatus.ts @@ -106,7 +106,7 @@ export class AtaProgressReporter { window.showWarningMessage( localize( 'typesInstallerInitializationFailed.title', - "Could not install typings files for JavaScript language features. Please ensure that NPM is installed" + "Could not install typings files for JavaScript language features. Please ensure that NPM is installed or configure 'typescript.npm' in your user settings" ), { title: localize('typesInstallerInitializationFailed.moreInformation', "More Information"), id: 1 -- GitLab From eb9de44ec9a053cf9d5dd391cb91372363362472 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Thu, 1 Jun 2017 00:15:16 +0200 Subject: [PATCH 0412/1347] Fixes #27470: Tasks: below tasks.json is not valid although it should be --- src/vs/workbench/api/node/extHostTask.ts | 2 +- .../parts/tasks/common/taskConfiguration.ts | 307 +++++++++++------- src/vs/workbench/parts/tasks/common/tasks.ts | 17 +- .../electron-browser/task.contribution.ts | 5 +- .../electron-browser/terminalTaskSystem.ts | 12 - .../parts/tasks/node/processTaskSystem.ts | 12 - .../tasks/test/node/configuration.test.ts | 230 ++++++++----- 7 files changed, 340 insertions(+), 245 deletions(-) diff --git a/src/vs/workbench/api/node/extHostTask.ts b/src/vs/workbench/api/node/extHostTask.ts index b1febc8eb3d..180bc9ffbf3 100644 --- a/src/vs/workbench/api/node/extHostTask.ts +++ b/src/vs/workbench/api/node/extHostTask.ts @@ -324,7 +324,6 @@ namespace Tasks { group: types.TaskGroup.is(task.group) ? task.group : undefined, command: command, isBackground: !!task.isBackground, - suppressTaskName: true, problemMatchers: task.problemMatchers.slice() }; return result; @@ -338,6 +337,7 @@ namespace Tasks { name: value.process, args: Strings.from(value.args), type: TaskSystem.CommandType.Process, + suppressTaskName: true, terminalBehavior: TerminalBehaviour.from(value.terminalBehavior) }; if (value.options) { diff --git a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts index 8d7903008c9..2419be66ba0 100644 --- a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts +++ b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts @@ -337,12 +337,19 @@ enum ProblemMatcherKind { const EMPTY_ARRAY: any[] = []; Object.freeze(EMPTY_ARRAY); -function mergeProperty(target: T, source: T, key: K) { +function assignProperty(target: T, source: T, key: K) { if (source[key] !== void 0) { target[key] = source[key]; } } +function fillProperty(target: T, source: T, key: K) { + if (target[key] === void 0 && source[key] !== void 0) { + target[key] = source[key]; + } +} + + interface ParseContext { problemReporter: IProblemReporter; namedProblemMatchers: IStringDictionary; @@ -350,6 +357,62 @@ interface ParseContext { schemaVersion: Tasks.JsonSchemaVersion; } +namespace ShellConfiguration { + export function is(value: any): value is ShellConfiguration { + let candidate: ShellConfiguration = value; + return candidate && Types.isString(candidate.executable) && (candidate.args === void 0 || Types.isStringArray(candidate.args)); + } + + export function from(this: void, config: ShellConfiguration, context: ParseContext): Tasks.ShellConfiguration { + if (!is(config)) { + return undefined; + } + let result: ShellConfiguration = { executable: config.executable }; + if (config.args !== void 0) { + result.args = config.args.slice(); + } + return result; + } + + export function isEmpty(value: Tasks.ShellConfiguration): boolean { + return !value || value.executable === void 0 && (value.args === void 0 || value.args.length === 0); + } + + export function assignProperties(target: Tasks.ShellConfiguration, source: Tasks.ShellConfiguration): Tasks.ShellConfiguration { + if (isEmpty(source)) { + return target; + } + if (isEmpty(target)) { + return source; + } + assignProperty(target, source, 'executable'); + assignProperty(target, source, 'args'); + return target; + } + + export function fillProperties(target: Tasks.ShellConfiguration, source: Tasks.ShellConfiguration): Tasks.ShellConfiguration { + if (isEmpty(source)) { + return target; + } + if (isEmpty(target)) { + return source; + } + fillProperty(target, source, 'executable'); + fillProperty(target, source, 'args'); + return target; + } + + export function fillDefaults(value: Tasks.ShellConfiguration): void { + } + + export function freeze(value: Tasks.ShellConfiguration): void { + if (!value) { + return; + } + Object.freeze(value); + } +} + namespace CommandOptions { export function from(this: void, options: CommandOptions, context: ParseContext): Tasks.CommandOptions { let result: Tasks.CommandOptions = {}; @@ -371,23 +434,36 @@ namespace CommandOptions { return !value || value.cwd === void 0 && value.env === void 0 && value.shell === void 0; } - export function merge(target: Tasks.CommandOptions, source: Tasks.CommandOptions): Tasks.CommandOptions { + export function assignProperties(target: Tasks.CommandOptions, source: Tasks.CommandOptions): Tasks.CommandOptions { if (isEmpty(source)) { return target; } if (isEmpty(target)) { return source; } - mergeProperty(target, source, 'cwd'); + assignProperty(target, source, 'cwd'); if (target.env === void 0) { target.env = source.env; } else if (source.env !== void 0) { let env: { [key: string]: string; } = Object.create(null); Object.keys(target.env).forEach(key => env[key] = target.env[key]); - Object.keys(source.env).forEach(key => env[key = source.env[key]]); + Object.keys(source.env).forEach(key => env[key] = source.env[key]); target.env = env; } - target.shell = ShellConfiguration.merge(target.shell, source.shell); + target.shell = ShellConfiguration.assignProperties(target.shell, source.shell); + return target; + } + + export function fillProperties(target: Tasks.CommandOptions, source: Tasks.CommandOptions): Tasks.CommandOptions { + if (isEmpty(source)) { + return target; + } + if (isEmpty(target)) { + return source; + } + fillProperty(target, source, 'cwd'); + fillProperty(target, source, 'env'); + target.shell = ShellConfiguration.fillProperties(target.shell, source.shell); return target; } @@ -414,50 +490,6 @@ namespace CommandOptions { } } -namespace ShellConfiguration { - export function is(value: any): value is ShellConfiguration { - let candidate: ShellConfiguration = value; - return candidate && Types.isString(candidate.executable) && (candidate.args === void 0 || Types.isStringArray(candidate.args)); - } - - export function from(this: void, config: ShellConfiguration, context: ParseContext): Tasks.ShellConfiguration { - if (!is(config)) { - return undefined; - } - let result: ShellConfiguration = { executable: config.executable }; - if (config.args !== void 0) { - result.args = config.args.slice(); - } - return result; - } - - export function isEmpty(value: Tasks.ShellConfiguration): boolean { - return !value || value.executable === void 0 && (value.args === void 0 || value.args.length === 0); - } - - export function merge(target: Tasks.ShellConfiguration, source: Tasks.ShellConfiguration): Tasks.ShellConfiguration { - if (isEmpty(source)) { - return target; - } - if (isEmpty(target)) { - return source; - } - mergeProperty(target, source, 'executable'); - mergeProperty(target, source, 'args'); - return target; - } - - export function fillDefaults(value: Tasks.ShellConfiguration): void { - } - - export function freeze(value: Tasks.ShellConfiguration): void { - if (!value) { - return; - } - Object.freeze(value); - } -} - namespace CommandConfiguration { interface TerminalBehavior { echo?: boolean; @@ -474,6 +506,7 @@ namespace CommandConfiguration { showOutput?: string; terminal?: TerminalBehavior; taskSelector?: string; + suppressTaskName?: boolean; } interface CommandConfiguationShape extends BaseCommandConfiguationShape { @@ -506,15 +539,27 @@ namespace CommandConfiguration { return { echo, reveal }; } - export function merge(target: Tasks.TerminalBehavior, source: Tasks.TerminalBehavior): Tasks.TerminalBehavior { + export function assignProperties(target: Tasks.TerminalBehavior, source: Tasks.TerminalBehavior): Tasks.TerminalBehavior { if (isEmpty(source)) { return target; } if (isEmpty(target)) { return source; } - mergeProperty(target, source, 'echo'); - mergeProperty(target, source, 'reveal'); + assignProperty(target, source, 'echo'); + assignProperty(target, source, 'reveal'); + return target; + } + + export function fillProperties(target: Tasks.TerminalBehavior, source: Tasks.TerminalBehavior): Tasks.TerminalBehavior { + if (isEmpty(source)) { + return target; + } + if (isEmpty(target)) { + return source; + } + fillProperty(target, source, 'echo'); + fillProperty(target, source, 'reveal'); return target; } @@ -541,7 +586,7 @@ namespace CommandConfiguration { Object.freeze(value); } - function isEmpty(this: void, value: Tasks.TerminalBehavior): boolean { + export function isEmpty(this: void, value: Tasks.TerminalBehavior): boolean { return !value || value.echo === void 0 && value.reveal === void 0; } } @@ -558,9 +603,8 @@ namespace CommandConfiguration { osConfig = fromBase(config.linux, context); } if (osConfig) { - result = merge(result, osConfig); + result = assignProperties(result, osConfig); } - fillDefaults(result); return isEmpty(result) ? undefined : result; } @@ -605,11 +649,20 @@ namespace CommandConfiguration { if (Types.isString(config.taskSelector)) { result.taskSelector = config.taskSelector; } + if (Types.isBoolean(config.suppressTaskName)) { + result.suppressTaskName = config.suppressTaskName; + } return isEmpty(result) ? undefined : result; } export function isEmpty(value: Tasks.CommandConfiguration): boolean { - return !value || value.name === void 0 && value.type === void 0 && value.args === void 0 && CommandOptions.isEmpty(value.options) && value.terminalBehavior === void 0; + return !value || value.name === void 0 + && value.type === void 0 + && value.args === void 0 + && value.taskSelector === void 0 + && value.suppressTaskName === void 0 + && CommandOptions.isEmpty(value.options) + && TerminalBehavior.isEmpty(value.terminalBehavior); } export function onlyTerminalBehaviour(value: Tasks.CommandConfiguration): boolean { @@ -618,22 +671,17 @@ namespace CommandConfiguration { value.name === void 0 && value.type === void 0 && value.args === void 0 && CommandOptions.isEmpty(value.options); } - export function merge(target: Tasks.CommandConfiguration, source: Tasks.CommandConfiguration): Tasks.CommandConfiguration { + export function assignProperties(target: Tasks.CommandConfiguration, source: Tasks.CommandConfiguration): Tasks.CommandConfiguration { if (isEmpty(source)) { return target; } if (isEmpty(target)) { return source; } - mergeProperty(target, source, 'name'); - mergeProperty(target, source, 'type'); - // Merge isShellCommand - if (target.type === void 0) { - target.type = source.type; - } - - target.terminalBehavior = TerminalBehavior.merge(target.terminalBehavior, source.terminalBehavior); - mergeProperty(target, source, 'taskSelector'); + assignProperty(target, source, 'name'); + assignProperty(target, source, 'type'); + assignProperty(target, source, 'taskSelector'); + assignProperty(target, source, 'suppressTaskName'); if (source.args !== void 0) { if (target.args === void 0) { target.args = source.args; @@ -641,7 +689,40 @@ namespace CommandConfiguration { target.args = target.args.concat(source.args); } } - target.options = CommandOptions.merge(target.options, source.options); + target.terminalBehavior = TerminalBehavior.assignProperties(target.terminalBehavior, source.terminalBehavior); + target.options = CommandOptions.assignProperties(target.options, source.options); + return target; + } + + export function fillGlobals(target: Tasks.CommandConfiguration, source: Tasks.CommandConfiguration, taskName: string): Tasks.CommandConfiguration { + if (isEmpty(source)) { + return target; + } + target = target || { + name: undefined, + type: undefined, + terminalBehavior: undefined + }; + fillProperty(target, source, 'name'); + fillProperty(target, source, 'type'); + fillProperty(target, source, 'taskSelector'); + fillProperty(target, source, 'suppressTaskName'); + + target.terminalBehavior = TerminalBehavior.fillProperties(target.terminalBehavior, source.terminalBehavior); + target.options = CommandOptions.fillProperties(target.options, source.options); + + let args: string[] = source.args ? source.args.slice() : []; + if (!target.suppressTaskName) { + if (target.taskSelector !== void 0) { + args.push(target.taskSelector + taskName); + } else { + args.push(taskName); + } + } + if (target.args) { + args = args.concat(target.args); + } + target.args = args; return target; } @@ -653,11 +734,14 @@ namespace CommandConfiguration { value.type = Tasks.CommandType.Process; } value.terminalBehavior = TerminalBehavior.fillDefault(value.terminalBehavior); + if (!isEmpty(value)) { + value.options = CommandOptions.fillDefaults(value.options); + } if (value.args === void 0) { value.args = EMPTY_ARRAY; } - if (!isEmpty(value)) { - value.options = CommandOptions.fillDefaults(value.options); + if (value.suppressTaskName === void 0) { + value.suppressTaskName = false; } } @@ -771,7 +855,7 @@ namespace TaskDescription { export let source: Tasks.TaskSource = { kind: Tasks.TaskSourceKind.Workspace, label: 'Workspace', - detail: '.settins\tasks.json' + detail: '.settins\\tasks.json' }; export function from(this: void, tasks: TaskDescription[], globals: Globals, context: ParseContext): TaskParseResult { @@ -790,11 +874,7 @@ namespace TaskDescription { return; } let problemMatchers = ProblemMatcherConverter.from(externalTask.problemMatcher, context); - let command: Tasks.CommandConfiguration = externalTask.command !== void 0 - ? CommandConfiguration.from(externalTask, context) - : externalTask.echoCommand !== void 0 - ? { name: undefined, type: undefined, terminalBehavior: CommandConfiguration.TerminalBehavior.from(externalTask, context) } - : undefined; + let command: Tasks.CommandConfiguration = CommandConfiguration.from(externalTask, context); let identifer = Types.isString(externalTask.identifier) ? externalTask.identifier : taskName; let task: Tasks.Task = { _id: UUID.generateUuid(), @@ -804,9 +884,6 @@ namespace TaskDescription { identifier: identifer, command }; - if (externalTask.command === void 0 && Types.isStringArray(externalTask.args)) { - task.args = externalTask.args.slice(); - } if (externalTask.isWatching !== void 0) { task.isBackground = !!externalTask.isWatching; } @@ -829,9 +906,7 @@ namespace TaskDescription { if (externalTask.command !== void 0) { // if the task has its own command then we suppress the // task name by default. - task.suppressTaskName = true; - } else if (externalTask.suppressTaskName !== void 0) { - task.suppressTaskName = !!externalTask.suppressTaskName; + command.suppressTaskName = true; } if (externalTask.dependsOn !== void 0) { if (Types.isString(externalTask.dependsOn)) { @@ -848,7 +923,7 @@ namespace TaskDescription { annotatingTasks.push(task); return; } - mergeGlobals(task, globals); + fillGlobals(task, globals); fillDefaults(task); let addTask: boolean = true; if (context.engine === Tasks.ExecutionEngine.Terminal && task.command && task.command.name && task.command.type === Tasks.CommandType.Shell && task.command.args && task.command.args.length > 0) { @@ -901,7 +976,7 @@ namespace TaskDescription { }; } - export function mergeTasks(target: Tasks.Task[], source: Tasks.Task[]): Tasks.Task[] { + export function assignTasks(target: Tasks.Task[], source: Tasks.Task[]): Tasks.Task[] { if (source === void 0 || source.length === 0) { return target; } @@ -930,28 +1005,15 @@ namespace TaskDescription { return target; } - export function mergeGlobals(task: Tasks.Task, globals: Globals): void { + export function fillGlobals(task: Tasks.Task, globals: Globals): void { // We only merge a command from a global definition if there is no dependsOn if (task.dependsOn === void 0) { - if (CommandConfiguration.isEmpty(task.command) && !CommandConfiguration.isEmpty(globals.command) && globals.command.name !== void 0) { - task.command = globals.command; - } - if (CommandConfiguration.onlyTerminalBehaviour(task.command)) { - // The globals can have a echo set which would override the local echo - // Saves the need of a additional fill method. But might be necessary - // at some point. - let oldTerminal = Objects.clone(task.command.terminalBehavior); - CommandConfiguration.merge(task.command, globals.command); - task.command.terminalBehavior = oldTerminal; - } + task.command = CommandConfiguration.fillGlobals(task.command, globals.command, task.name); } // promptOnClose is inferred from isBackground if available if (task.promptOnClose === void 0 && task.isBackground === void 0 && globals.promptOnClose !== void 0) { task.promptOnClose = globals.promptOnClose; } - if (task.suppressTaskName === void 0 && globals.suppressTaskName !== void 0) { - task.suppressTaskName = globals.suppressTaskName; - } } export function mergeGlobalsIntoAnnnotation(task: Tasks.Task, globals: Globals): void { @@ -959,12 +1021,6 @@ namespace TaskDescription { export function fillDefaults(task: Tasks.Task): void { CommandConfiguration.fillDefaults(task.command); - if (task.args === void 0 && task.command === void 0) { - task.args = EMPTY_ARRAY; - } - if (task.suppressTaskName === void 0) { - task.suppressTaskName = false; - } if (task.promptOnClose === void 0) { task.promptOnClose = task.isBackground !== void 0 ? !task.isBackground : true; } @@ -1002,7 +1058,7 @@ namespace TaskDescription { return (task.command === void 0 || task.command.name === void 0) && (task.dependsOn === void 0 || task.dependsOn.length === 0); } - export function merge(target: Tasks.Task, source: Tasks.Task): Tasks.Task { + export function assignProperties(target: Tasks.Task, source: Tasks.Task): Tasks.Task { if (!target) { return source; } @@ -1010,14 +1066,12 @@ namespace TaskDescription { return target; } - mergeProperty(target, source, 'group'); - target.command = CommandConfiguration.merge(target.command, source.command); - mergeProperty(target, source, 'suppressTaskName'); - mergeProperty(target, source, 'args'); - mergeProperty(target, source, 'isBackground'); - mergeProperty(target, source, 'promptOnClose'); - mergeProperty(target, source, 'dependsOn'); - mergeProperty(target, source, 'problemMatchers'); + assignProperty(target, source, 'group'); + target.command = CommandConfiguration.assignProperties(target.command, source.command); + assignProperty(target, source, 'isBackground'); + assignProperty(target, source, 'promptOnClose'); + assignProperty(target, source, 'dependsOn'); + assignProperty(target, source, 'problemMatchers'); return target; } } @@ -1041,13 +1095,13 @@ namespace Globals { osGlobals = fromBase(config.linux, context); } if (osGlobals) { - result = Globals.merge(result, osGlobals); + result = Globals.assignProperties(result, osGlobals); } - Globals.fillDefaults(result); let command = CommandConfiguration.from(config, context); if (command) { result.command = command; } + Globals.fillDefaults(result); Globals.freeze(result); return result; } @@ -1067,15 +1121,15 @@ namespace Globals { return !value || value.command === void 0 && value.promptOnClose === void 0 && value.suppressTaskName === void 0; } - export function merge(target: Globals, source: Globals): Globals { + export function assignProperties(target: Globals, source: Globals): Globals { if (isEmpty(source)) { return target; } if (isEmpty(target)) { return source; } - mergeProperty(target, source, 'promptOnClose'); - mergeProperty(target, source, 'suppressTaskName'); + assignProperty(target, source, 'promptOnClose'); + assignProperty(target, source, 'suppressTaskName'); return target; } @@ -1083,6 +1137,7 @@ namespace Globals { if (!value) { return; } + CommandConfiguration.fillDefaults(value.command); if (value.suppressTaskName === void 0) { value.suppressTaskName = false; } @@ -1207,8 +1262,8 @@ class ConfigurationParser { result = TaskDescription.from(fileConfig.tasks, globals, context); } if (globalTasks) { - result.tasks = TaskDescription.mergeTasks(result.tasks, globalTasks.tasks); - result.annotatingTasks = TaskDescription.mergeTasks(result.annotatingTasks, globalTasks.annotatingTasks); + result.tasks = TaskDescription.assignTasks(result.tasks, globalTasks.tasks); + result.annotatingTasks = TaskDescription.assignTasks(result.annotatingTasks, globalTasks.annotatingTasks); } if ((!result.tasks || result.tasks.length === 0) && (globals.command && globals.command.name)) { @@ -1221,12 +1276,16 @@ class ConfigurationParser { name: globals.command.name, identifier: globals.command.name, group: Tasks.TaskGroup.Build, - command: undefined, + command: { + name: undefined, + type: undefined, + terminalBehavior: undefined, + suppressTaskName: true + }, isBackground: isBackground, - suppressTaskName: true, // this must be true since we infer the task from the global data. problemMatchers: matchers }; - TaskDescription.mergeGlobals(task, globals); + TaskDescription.fillGlobals(task, globals); TaskDescription.fillDefaults(task); result.tasks = [task]; } @@ -1241,7 +1300,7 @@ export function parse(configuration: ExternalTaskRunnerConfiguration, logger: IP } export function mergeTasks(target: Tasks.Task, source: Tasks.Task): Tasks.Task { - return TaskDescription.merge(target, source); + return TaskDescription.assignProperties(target, source); } /* diff --git a/src/vs/workbench/parts/tasks/common/tasks.ts b/src/vs/workbench/parts/tasks/common/tasks.ts index ab09f644078..88dfd56ba73 100644 --- a/src/vs/workbench/parts/tasks/common/tasks.ts +++ b/src/vs/workbench/parts/tasks/common/tasks.ts @@ -138,6 +138,12 @@ export interface CommandConfiguration { */ taskSelector?: string; + /** + * Whether to suppress the task name when merging global args + * + */ + suppressTaskName?: boolean; + /** * Describes how the terminal is supposed to behave. */ @@ -212,17 +218,6 @@ export interface Task { */ command: CommandConfiguration; - /** - * Suppresses the task name when calling the task using the task runner. - */ - suppressTaskName?: boolean; - - /** - * Additional arguments passed to the command when this target is - * invoked. - */ - args?: string[]; - /** * Whether the task is a background task or not. */ diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index 317f79f6ef1..f14e2e4bbc6 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -1091,10 +1091,7 @@ class TaskService extends EventEmitter implements ITaskService { return { config: result, hasErrors }; }); } else { - configPromise = new ProcessRunnerDetector(this.fileService, this.contextService, this.configurationResolverService).detect(true).then((value) => { - let hasErrors = this.printStderr(value.stderr); - return { config: value.config, hasErrors }; - }); + configPromise = TPromise.as({ config, hasErrors: false }); } } else { configPromise = TPromise.as({ config, hasErrors: false }); diff --git a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts index 37cef5b6c85..6dbbc5b93a6 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts @@ -503,18 +503,6 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { private resolveCommandAndArgs(task: Task): { command: string, args: string[] } { // First we need to use the command args: let args: string[] = task.command.args ? task.command.args.slice() : []; - // We need to first pass the task name - if (!task.suppressTaskName) { - if (task.command.taskSelector) { - args.push(task.command.taskSelector + task.name); - } else { - args.push(task.name); - } - } - // And then additional arguments - if (task.args) { - args = args.concat(task.args); - } args = this.resolveVariables(args); let command: string = this.resolveVariable(task.command.name); return { command, args }; diff --git a/src/vs/workbench/parts/tasks/node/processTaskSystem.ts b/src/vs/workbench/parts/tasks/node/processTaskSystem.ts index de4bc36b7f5..0ac2c85e08f 100644 --- a/src/vs/workbench/parts/tasks/node/processTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/node/processTaskSystem.ts @@ -162,18 +162,6 @@ export class ProcessTaskSystem extends EventEmitter implements ITaskSystem { } let args: string[] = commandConfig.args ? commandConfig.args.slice() : []; - // We need to first pass the task name - if (!task.suppressTaskName) { - if (commandConfig.taskSelector) { - args.push(commandConfig.taskSelector + task.name); - } else { - args.push(task.name); - } - } - // And then additional arguments - if (task.args) { - args = args.concat(task.args); - } args = this.resolveVariables(args); let command: string = this.resolveVariable(commandConfig.name); this.childProcess = new LineProcess(command, args, commandConfig.type === CommandType.Shell, this.resolveOptions(commandConfig.options)); diff --git a/src/vs/workbench/parts/tasks/test/node/configuration.test.ts b/src/vs/workbench/parts/tasks/test/node/configuration.test.ts index 27dcb251cd0..a82a75b6e7c 100644 --- a/src/vs/workbench/parts/tasks/test/node/configuration.test.ts +++ b/src/vs/workbench/parts/tasks/test/node/configuration.test.ts @@ -56,16 +56,25 @@ class ProblemReporter implements IProblemReporter { class ConfiguationBuilder { public result: Tasks.Task[]; + private builders: TaskBuilder[]; constructor() { this.result = []; + this.builders = []; } public task(name: string, command: string): TaskBuilder { let builder = new TaskBuilder(this, name, command); + this.builders.push(builder); this.result.push(builder.result); return builder; } + + public done(): void { + for (let builder of this.builders) { + builder.done(); + } + } } class TerminalBehaviorBuilder { @@ -85,6 +94,9 @@ class TerminalBehaviorBuilder { this.result.reveal = value; return this; } + + public done(): void { + } } class CommandConfigurationBuilder { @@ -101,7 +113,8 @@ class CommandConfigurationBuilder { options: { cwd: '${workspaceRoot}' }, - terminalBehavior: this.terminalBuilder.result + terminalBehavior: this.terminalBuilder.result, + suppressTaskName: false }; } @@ -130,9 +143,19 @@ class CommandConfigurationBuilder { return this; } + public suppressTaskName(value: boolean): CommandConfigurationBuilder { + this.result.suppressTaskName = value; + return this; + } + public terminal(): TerminalBehaviorBuilder { return this.terminalBuilder; } + + public done(taskName: string): void { + this.result.args = this.result.args.map(arg => arg === '$name' ? taskName : arg); + this.terminalBuilder.done(); + } } class TaskBuilder { @@ -149,7 +172,6 @@ class TaskBuilder { identifier: name, name: name, command: this.commandBuilder.result, - suppressTaskName: false, isBackground: false, promptOnClose: true, problemMatchers: [] @@ -166,16 +188,6 @@ class TaskBuilder { return this; } - public args(value: string[]): TaskBuilder { - this.result.args = value; - return this; - } - - public suppressTaskName(value: boolean): TaskBuilder { - this.result.suppressTaskName = value; - return this; - } - public isBackground(value: boolean): TaskBuilder { this.result.isBackground = value; return this; @@ -195,6 +207,10 @@ class TaskBuilder { public command(): CommandConfigurationBuilder { return this.commandBuilder; } + + public done(): void { + this.commandBuilder.done(this.result.name); + } } class ProblemMatcherBuilder { @@ -323,6 +339,7 @@ function testDefaultProblemMatcher(external: ExternalTaskRunnerConfiguration, re } function testConfiguration(external: ExternalTaskRunnerConfiguration, builder: ConfiguationBuilder): void { + builder.done(); let reporter = new ProblemReporter(); let result = parse(external, reporter); if (reporter.receivedMessage) { @@ -417,7 +434,6 @@ function assertTask(actual: Tasks.Task, expected: Tasks.Task) { assert.ok(actual._id); assert.strictEqual(actual.name, expected.name, 'name'); assertCommandConfiguration(actual.command, expected.command); - assert.strictEqual(actual.suppressTaskName, expected.suppressTaskName, 'suppressTaskName'); assert.strictEqual(actual.isBackground, expected.isBackground, 'isBackground'); assert.strictEqual(actual.promptOnClose, expected.promptOnClose, 'promptOnClose'); assert.strictEqual(typeof actual.problemMatchers, typeof expected.problemMatchers); @@ -435,6 +451,8 @@ function assertCommandConfiguration(actual: Tasks.CommandConfiguration, expected assertTerminalBehavior(actual.terminalBehavior, expected.terminalBehavior); assert.strictEqual(actual.name, expected.name, 'name'); assert.strictEqual(actual.type, expected.type, 'task type'); + assert.strictEqual(actual.suppressTaskName, expected.suppressTaskName, 'suppressTaskName'); + assert.strictEqual(actual.taskSelector, expected.taskSelector, 'taskSelector'); assert.deepEqual(actual.args, expected.args, 'args'); assert.strictEqual(typeof actual.options, typeof expected.options); if (actual.options && expected.options) { @@ -444,7 +462,6 @@ function assertCommandConfiguration(actual: Tasks.CommandConfiguration, expected assert.deepEqual(actual.options.env, expected.options.env, 'env'); } } - assert.strictEqual(actual.taskSelector, expected.taskSelector, 'taskSelector'); } } @@ -518,7 +535,7 @@ suite('Tasks version 0.1.0', () => { let builder = new ConfiguationBuilder(); builder.task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). - suppressTaskName(true); + command().suppressTaskName(true); testConfiguration( { version: '0.1.0', @@ -530,8 +547,7 @@ suite('Tasks version 0.1.0', () => { let builder = new ConfiguationBuilder(); builder.task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). - suppressTaskName(true). - command(). + command().suppressTaskName(true). type(Tasks.CommandType.Shell); testConfiguration( { @@ -547,8 +563,8 @@ suite('Tasks version 0.1.0', () => { builder. task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). - suppressTaskName(true). - command().terminal().reveal(Tasks.RevealKind.Silent); + command().suppressTaskName(true). + terminal().reveal(Tasks.RevealKind.Silent); testConfiguration( { version: '0.1.0', @@ -563,7 +579,7 @@ suite('Tasks version 0.1.0', () => { let builder = new ConfiguationBuilder(); builder.task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). - suppressTaskName(true); + command().suppressTaskName(true); testConfiguration( { version: '0.1.0', @@ -577,9 +593,9 @@ suite('Tasks version 0.1.0', () => { test('tasks: global promptOnClose', () => { let builder = new ConfiguationBuilder(); builder.task('tsc', 'tsc'). - suppressTaskName(true). group(Tasks.TaskGroup.Build). - promptOnClose(false); + promptOnClose(false). + command().suppressTaskName(true); testConfiguration( { version: '0.1.0', @@ -593,10 +609,10 @@ suite('Tasks version 0.1.0', () => { test('tasks: global promptOnClose default watching', () => { let builder = new ConfiguationBuilder(); builder.task('tsc', 'tsc'). - suppressTaskName(true). group(Tasks.TaskGroup.Build). isBackground(true). - promptOnClose(false); + promptOnClose(false). + command().suppressTaskName(true); testConfiguration( { version: '0.1.0', @@ -612,8 +628,8 @@ suite('Tasks version 0.1.0', () => { builder. task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). - suppressTaskName(true). - command().terminal().reveal(Tasks.RevealKind.Never); + command().suppressTaskName(true). + terminal().reveal(Tasks.RevealKind.Never); testConfiguration( { version: '0.1.0', @@ -629,8 +645,8 @@ suite('Tasks version 0.1.0', () => { builder. task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). - suppressTaskName(true). - command().terminal(). + command().suppressTaskName(true). + terminal(). echo(true); testConfiguration( { @@ -647,8 +663,7 @@ suite('Tasks version 0.1.0', () => { builder. task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). - suppressTaskName(true). - command(). + command().suppressTaskName(true). args(['--p']); testConfiguration( { @@ -667,8 +682,7 @@ suite('Tasks version 0.1.0', () => { builder. task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). - suppressTaskName(true). - command(). + command().suppressTaskName(true). options({ cwd: 'myPath' }); @@ -689,8 +703,7 @@ suite('Tasks version 0.1.0', () => { builder. task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). - suppressTaskName(true). - command(). + command().suppressTaskName(true). options({ cwd: '${workspaceRoot}', env: { key: 'value' } }); testConfiguration( { @@ -712,7 +725,7 @@ suite('Tasks version 0.1.0', () => { builder. task(name, name). group(Tasks.TaskGroup.Build). - suppressTaskName(true); + command().suppressTaskName(true); let external: ExternalTaskRunnerConfiguration = { version: '0.1.0', command: 'tsc', @@ -729,8 +742,7 @@ suite('Tasks version 0.1.0', () => { builder. task(name, name). group(Tasks.TaskGroup.Build). - suppressTaskName(true). - command(). + command().suppressTaskName(true). type(Tasks.CommandType.Shell); let external: ExternalTaskRunnerConfiguration = { version: '0.1.0', @@ -749,7 +761,7 @@ suite('Tasks version 0.1.0', () => { builder. task(name, name). group(Tasks.TaskGroup.Build). - suppressTaskName(true); + command().suppressTaskName(true); let external: ExternalTaskRunnerConfiguration = { version: '0.1.0', command: 'tsc', @@ -766,7 +778,7 @@ suite('Tasks version 0.1.0', () => { builder. task(name, name). group(Tasks.TaskGroup.Build). - suppressTaskName(true); + command().suppressTaskName(true); let external: ExternalTaskRunnerConfiguration = { version: '0.1.0', command: 'tsc', @@ -782,8 +794,8 @@ suite('Tasks version 0.1.0', () => { builder. task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). - suppressTaskName(true). - command().terminal().reveal(Platform.isWindows ? Tasks.RevealKind.Always : Tasks.RevealKind.Never); + command().suppressTaskName(true). + terminal().reveal(Platform.isWindows ? Tasks.RevealKind.Always : Tasks.RevealKind.Never); let external: ExternalTaskRunnerConfiguration = { version: '0.1.0', command: 'tsc', @@ -800,8 +812,8 @@ suite('Tasks version 0.1.0', () => { builder. task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). - suppressTaskName(true). - command().terminal(). + command().suppressTaskName(true). + terminal(). echo(Platform.isWindows ? false : true); let external: ExternalTaskRunnerConfiguration = { version: '0.1.0', @@ -843,7 +855,7 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('taskName', 'tsc'); + builder.task('taskName', 'tsc').command().args(['$name']); testConfiguration(external, builder); }); @@ -859,7 +871,7 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('taskName', 'tsc').group(Tasks.TaskGroup.Build); + builder.task('taskName', 'tsc').group(Tasks.TaskGroup.Build).command().args(['$name']); testConfiguration(external, builder); }); @@ -874,7 +886,7 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('build', 'tsc').group(Tasks.TaskGroup.Build); + builder.task('build', 'tsc').group(Tasks.TaskGroup.Build).command().args(['$name']); testConfiguration(external, builder); }); @@ -890,7 +902,7 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('taskName', 'tsc').group(Tasks.TaskGroup.Test); + builder.task('taskName', 'tsc').group(Tasks.TaskGroup.Test).command().args(['$name']); testConfiguration(external, builder); }); @@ -905,7 +917,7 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('test', 'tsc').group(Tasks.TaskGroup.Test); + builder.task('test', 'tsc').group(Tasks.TaskGroup.Test).command().args(['$name']); testConfiguration(external, builder); }); @@ -926,10 +938,10 @@ suite('Tasks version 0.1.0', () => { let builder = new ConfiguationBuilder(); builder.task('test', 'tsc'). group(Tasks.TaskGroup.Test). - args(['--p']). isBackground(true). promptOnClose(false). - command().terminal(). + command().args(['$name', '--p']). + terminal(). echo(true).reveal(Tasks.RevealKind.Never); testConfiguration(external, builder); @@ -950,7 +962,7 @@ suite('Tasks version 0.1.0', () => { let builder = new ConfiguationBuilder(); builder.task('test', 'tsc'). group(Tasks.TaskGroup.Test). - command().terminal(). + command().args(['$name']).terminal(). echo(true).reveal(Tasks.RevealKind.Never); testConfiguration(external, builder); @@ -972,7 +984,9 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('taskName', 'tsc').problemMatcher().pattern(/abc/); + builder.task('taskName', 'tsc'). + command().args(['$name']).parent. + problemMatcher().pattern(/abc/); testConfiguration(external, builder); }); @@ -992,7 +1006,9 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('taskName', 'tsc').problemMatcher().pattern(/.*/); + builder.task('taskName', 'tsc'). + command().args(['$name']).parent. + problemMatcher().pattern(/.*/); testConfiguration(external, builder); }); @@ -1016,7 +1032,9 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('taskName', 'tsc').problemMatcher(). + builder.task('taskName', 'tsc'). + command().args(['$name']).parent. + problemMatcher(). owner('myOwner'). applyTo(ApplyToKind.closedDocuments). severity(Severity.Warning). @@ -1043,7 +1061,9 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('taskName', 'tsc').problemMatcher(). + builder.task('taskName', 'tsc'). + command().args(['$name']).parent. + problemMatcher(). fileLocation(FileLocationKind.Relative). filePrefix('myPath'). pattern(/abc/); @@ -1071,7 +1091,9 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('taskName', 'tsc').problemMatcher(). + builder.task('taskName', 'tsc'). + command().args(['$name']).parent. + problemMatcher(). pattern(/abc/).file(10).message(11).location(12).severity(13).code(14); testConfiguration(external, builder); }); @@ -1100,7 +1122,9 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('taskName', 'tsc').problemMatcher(). + builder.task('taskName', 'tsc'). + command().args(['$name']).parent. + problemMatcher(). pattern(/abc/).file(10).message(11). line(12).character(13).endLine(14).endCharacter(15). severity(16).code(17); @@ -1118,7 +1142,9 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('taskName', 'tsc').promptOnClose(true); + builder.task('taskName', 'tsc'). + promptOnClose(true). + command().args(['$name']); testConfiguration(external, builder); }); @@ -1134,7 +1160,9 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('taskName', 'tsc').isBackground(true).promptOnClose(false); + builder.task('taskName', 'tsc'). + isBackground(true).promptOnClose(false). + command().args(['$name']); testConfiguration(external, builder); }); @@ -1150,7 +1178,9 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('taskName', 'tsc').promptOnClose(false); + builder.task('taskName', 'tsc'). + promptOnClose(false). + command().args(['$name']); testConfiguration(external, builder); }); @@ -1158,7 +1188,7 @@ suite('Tasks version 0.1.0', () => { let external: ExternalTaskRunnerConfiguration = { version: '0.1.0', command: 'tsc', - taskSelector: '/t', + taskSelector: '/t:', tasks: [ { taskName: 'taskName', @@ -1168,7 +1198,8 @@ suite('Tasks version 0.1.0', () => { let builder = new ConfiguationBuilder(); builder.task('taskName', 'tsc'). command(). - taskSelector('/t'); + taskSelector('/t:'). + args(['/t:taskName']); testConfiguration(external, builder); }); @@ -1186,11 +1217,11 @@ suite('Tasks version 0.1.0', () => { }; let builder = new ConfiguationBuilder(); builder.task('taskName', 'tsc'). - suppressTaskName(true); + command().suppressTaskName(true); testConfiguration(external, builder); }); - test('tasks: suppress task name inerit', () => { + test('tasks: suppress task name inherit', () => { let external: ExternalTaskRunnerConfiguration = { version: '0.1.0', command: 'tsc', @@ -1203,7 +1234,7 @@ suite('Tasks version 0.1.0', () => { }; let builder = new ConfiguationBuilder(); builder.task('taskName', 'tsc'). - suppressTaskName(true); + command().suppressTaskName(true); testConfiguration(external, builder); }); @@ -1221,8 +1252,10 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('taskNameOne', 'tsc'); - builder.task('taskNameTwo', 'tsc'); + builder.task('taskNameOne', 'tsc'). + command().args(['$name']); + builder.task('taskNameTwo', 'tsc'). + command().args(['$name']); testConfiguration(external, builder); }); @@ -1237,7 +1270,7 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('taskNameOne', 'tsc').suppressTaskName(true); + builder.task('taskNameOne', 'tsc').command().suppressTaskName(true); testConfiguration(external, builder); }); @@ -1256,8 +1289,8 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('taskNameOne', 'tsc').suppressTaskName(true); - builder.task('taskNameTwo', 'dir').suppressTaskName(true); + builder.task('taskNameOne', 'tsc').command().suppressTaskName(true); + builder.task('taskNameTwo', 'dir').command().suppressTaskName(true); testConfiguration(external, builder); }); @@ -1280,7 +1313,7 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('taskNameOne', 'tsc').suppressTaskName(true).command(). + builder.task('taskNameOne', 'tsc').command().suppressTaskName(true). type(Tasks.CommandType.Shell).args(['arg']).options({ cwd: 'cwd', env: { env: 'env' } }); testConfiguration(external, builder); }); @@ -1300,7 +1333,7 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('taskNameOne', name).suppressTaskName(true); + builder.task('taskNameOne', name).command().suppressTaskName(true); testConfiguration(external, builder); }); @@ -1320,7 +1353,7 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('tsc', 'tsc').suppressTaskName(true).command().args(args); + builder.task('tsc', 'tsc').command().suppressTaskName(true).args(args); testConfiguration(external, builder); }); @@ -1340,7 +1373,7 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('tsc', 'tsc').suppressTaskName(true).command().args(args); + builder.task('tsc', 'tsc').command().suppressTaskName(true).args(args); testConfiguration(external, builder); }); @@ -1356,7 +1389,42 @@ suite('Tasks version 0.1.0', () => { ] }; let builder = new ConfiguationBuilder(); - builder.task('taskNameOne', 'tsc').command().type(Tasks.CommandType.Process); + builder.task('taskNameOne', 'tsc').command().type(Tasks.CommandType.Shell).args(['$name']); + testConfiguration(external, builder); + }); + + test('tasks: global and tasks args', () => { + let external: ExternalTaskRunnerConfiguration = { + version: '0.1.0', + command: 'tsc', + args: ['global'], + tasks: [ + { + taskName: 'taskNameOne', + args: ['local'] + } + ] + }; + let builder = new ConfiguationBuilder(); + builder.task('taskNameOne', 'tsc').command().args(['global', '$name', 'local']); + testConfiguration(external, builder); + }); + + test('tasks: global and tasks args with task selector', () => { + let external: ExternalTaskRunnerConfiguration = { + version: '0.1.0', + command: 'tsc', + args: ['global'], + taskSelector: '/t:', + tasks: [ + { + taskName: 'taskNameOne', + args: ['local'] + } + ] + }; + let builder = new ConfiguationBuilder(); + builder.task('taskNameOne', 'tsc').command().taskSelector('/t:').args(['global', '/t:taskNameOne', 'local']); testConfiguration(external, builder); }); }); @@ -1376,9 +1444,9 @@ suite('Tasks version 2.0.0', () => { }; let builder = new ConfiguationBuilder(); builder.task('dir', 'dir'). - suppressTaskName(true). group(Tasks.TaskGroup.Build). - command().type(Tasks.CommandType.Shell); + command().suppressTaskName(true). + type(Tasks.CommandType.Shell); testConfiguration(external, builder); }); @@ -1436,16 +1504,16 @@ suite('Bugs / regression tests', () => { let builder = new ConfiguationBuilder(); if (Platform.isWindows) { builder.task('composeForDebug', 'powershell'). - suppressTaskName(true). + command().suppressTaskName(true). args(['-ExecutionPolicy', 'RemoteSigned', '.\\dockerTask.ps1', '-ComposeForDebug', '-Environment', 'debug']). - command().options({ cwd: '${workspaceRoot}' }). + options({ cwd: '${workspaceRoot}' }). terminal().echo(true).reveal(Tasks.RevealKind.Always); testConfiguration(external, builder); } else if (Platform.isMacintosh) { builder.task('composeForDebug', '/bin/bash'). - suppressTaskName(true). + command().suppressTaskName(true). args(['-c', './dockerTask.sh composeForDebug debug']). - command().options({ cwd: '${workspaceRoot}' }). + options({ cwd: '${workspaceRoot}' }). terminal().reveal(Tasks.RevealKind.Always); testConfiguration(external, builder); } -- GitLab From fbdbd2dda223ecfe43d9524c68935df0897a8fe6 Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Wed, 31 May 2017 15:55:26 -0700 Subject: [PATCH 0413/1347] node-debug2@1.13.1 --- build/gulpfile.vscode.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index e73e03c311d..942bb3847e3 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -43,7 +43,7 @@ const nodeModules = ['electron', 'original-fs'] const builtInExtensions = [ { name: 'ms-vscode.node-debug', version: '1.13.7' }, - { name: 'ms-vscode.node-debug2', version: '1.13.0' } + { name: 'ms-vscode.node-debug2', version: '1.13.1' } ]; const vscodeEntryPoints = _.flatten([ -- GitLab From f8c01e91a9f3af4cdaf2d1cc272b6edaf099a6e8 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 31 May 2017 17:31:56 -0700 Subject: [PATCH 0414/1347] Update distro for #24538 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index bfc4fed8575..0c8f77e4dba 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "code-oss-dev", "version": "1.13.0", "electronVersion": "1.6.6", - "distro": "20d9b7ca9af07894c19dbabde24c7c954510fb5b", + "distro": "6a21d9ea82740d478d8b3fb72ec2a63d27b8a29c", "author": { "name": "Microsoft Corporation" }, -- GitLab From 5fe794bdb0fbae757612c611120e9b7180705254 Mon Sep 17 00:00:00 2001 From: Daniel Ye Date: Wed, 31 May 2017 17:40:04 -0700 Subject: [PATCH 0415/1347] 2017-05-31. Merged in translations from transifex. --- .../markdown/out/extension.i18n.json | 4 +++- .../out/codelensProvider.i18n.json | 4 +--- .../out/commandHandler.i18n.json | 1 + .../out/mergeDecorator.i18n.json | 3 ++- .../merge-conflict/package.i18n.json | 8 ++++---- .../out/utils/typingsStatus.i18n.json | 1 - .../extensions/typescript/package.i18n.json | 4 ++-- .../resourceviewer/resourceViewer.i18n.json | 1 + .../src/vs/code/electron-main/menus.i18n.json | 2 +- .../config/commonEditorConfig.i18n.json | 3 +++ .../common/view/editorColorRegistry.i18n.json | 6 +++++- .../browser/accessibility.i18n.json | 6 +++--- .../common/caretOperations.i18n.json | 4 ++-- .../format/browser/formatActions.i18n.json | 8 ++++---- .../browser/goToDeclarationCommands.i18n.json | 19 ++++++++++++++++++- .../browser/goToDeclarationMouse.i18n.json | 4 +++- .../common/linesOperations.i18n.json | 2 +- .../contrib/links/browser/links.i18n.json | 1 + .../common/toggleTabFocusMode.i18n.json | 2 +- .../common/keybindingLabels.i18n.json | 4 ++-- .../theme/common/colorRegistry.i18n.json | 9 +++++++-- .../workbench/api/node/extHostTask.i18n.json | 6 ++++++ .../parts/editor/editorStatus.i18n.json | 1 + .../src/vs/workbench/common/theme.i18n.json | 9 ++++++--- .../electron-browser/workbench.i18n.json | 5 ++++- .../electron-browser/debugService.i18n.json | 2 +- .../statusbarColorProvider.i18n.json | 3 ++- .../browser/extensionsActions.i18n.json | 9 ++++++++- .../extensionsUtils.i18n.json | 2 ++ .../browser/files.contribution.i18n.json | 1 + .../keybindingsEditorContribution.i18n.json | 1 - .../dirtydiffDecorator.i18n.json | 6 +++++- .../electron-browser/TMSnippets.i18n.json | 3 ++- .../parts/tasks/browser/quickOpen.i18n.json | 4 +--- .../tasks/common/taskConfiguration.i18n.json | 3 +-- .../electron-browser/jsonSchema_v2.i18n.json | 9 ++++----- .../electron-browser/welcomePage.i18n.json | 6 ++---- .../out/codelensProvider.i18n.json | 7 +------ .../out/commandHandler.i18n.json | 2 ++ .../merge-conflict/package.i18n.json | 11 ++--------- .../out/utils/typingsStatus.i18n.json | 1 - .../extensions/typescript/package.i18n.json | 5 ++++- .../resourceviewer/resourceViewer.i18n.json | 1 + .../src/vs/code/electron-main/menus.i18n.json | 2 +- .../config/commonEditorConfig.i18n.json | 1 + .../common/view/editorColorRegistry.i18n.json | 6 +++++- ...guageConfigurationExtensionPoint.i18n.json | 2 ++ .../workbench/api/node/extHostTask.i18n.json | 6 ++++++ .../src/vs/workbench/common/theme.i18n.json | 3 --- .../electron-browser/workbench.i18n.json | 5 ++++- .../electron-browser/debugService.i18n.json | 2 +- .../keybindingsEditorContribution.i18n.json | 1 - .../parts/tasks/browser/quickOpen.i18n.json | 4 +--- .../tasks/common/taskConfiguration.i18n.json | 3 +-- .../electron-browser/jsonSchema_v2.i18n.json | 9 ++++----- .../task.contribution.i18n.json | 1 + .../vs_code_welcome_page.i18n.json | 2 ++ .../electron-browser/welcomePage.i18n.json | 3 +-- .../configurationEditingService.i18n.json | 7 ++++++- .../deu/extensions/git/out/commands.i18n.json | 3 +++ i18n/deu/extensions/git/package.i18n.json | 1 + i18n/deu/extensions/jake/out/main.i18n.json | 4 +++- i18n/deu/extensions/jake/package.i18n.json | 4 +++- .../markdown/out/extension.i18n.json | 4 +++- .../out/commandHandler.i18n.json | 5 ++++- .../merge-conflict/package.i18n.json | 6 +++++- i18n/deu/extensions/npm/package.i18n.json | 4 +++- .../out/utils/typingsStatus.i18n.json | 1 - .../extensions/typescript/package.i18n.json | 5 +++-- .../resourceviewer/resourceViewer.i18n.json | 1 + .../src/vs/code/electron-main/menus.i18n.json | 3 ++- .../config/commonEditorConfig.i18n.json | 1 + .../contrib/links/browser/links.i18n.json | 1 + .../suggest/browser/suggestWidget.i18n.json | 1 + .../workbench/api/node/extHostTask.i18n.json | 6 ++++++ .../api/node/extHostTreeViews.i18n.json | 5 ++++- .../src/vs/workbench/common/theme.i18n.json | 3 --- .../electron-browser/workbench.i18n.json | 5 ++++- .../electron-browser/debugService.i18n.json | 2 +- .../electronDebugActions.i18n.json | 1 + .../performance.contribution.i18n.json | 3 ++- .../keybindingsEditorContribution.i18n.json | 1 - .../browser/commandsHandler.i18n.json | 1 + .../tasks/common/taskConfiguration.i18n.json | 3 +-- .../electron-browser/jsonSchema_v2.i18n.json | 9 ++++----- .../vs_code_welcome_page.i18n.json | 3 +++ .../electron-browser/welcomePage.i18n.json | 4 ++++ .../out/codelensProvider.i18n.json | 7 +------ .../out/commandHandler.i18n.json | 1 - .../merge-conflict/package.i18n.json | 8 -------- .../out/utils/typingsStatus.i18n.json | 1 - .../extensions/typescript/package.i18n.json | 1 - .../src/vs/code/electron-main/menus.i18n.json | 2 +- .../theme/common/colorRegistry.i18n.json | 1 - .../workbench/api/node/extHostTask.i18n.json | 6 ++++++ .../src/vs/workbench/common/theme.i18n.json | 3 --- .../electron-browser/workbench.i18n.json | 5 ++++- .../electron-browser/debugService.i18n.json | 2 +- .../keybindingsEditorContribution.i18n.json | 1 - .../parts/tasks/browser/quickOpen.i18n.json | 4 +--- .../tasks/common/taskConfiguration.i18n.json | 3 +-- .../electron-browser/jsonSchema_v2.i18n.json | 9 ++++----- .../electron-browser/welcomePage.i18n.json | 4 +--- .../out/utils/typingsStatus.i18n.json | 1 - .../extensions/typescript/package.i18n.json | 3 +-- .../src/vs/code/electron-main/menus.i18n.json | 2 +- .../workbench/api/node/extHostTask.i18n.json | 6 ++++++ .../src/vs/workbench/common/theme.i18n.json | 3 --- .../electron-browser/workbench.i18n.json | 5 ++++- .../electron-browser/debugService.i18n.json | 2 +- .../keybindingsEditorContribution.i18n.json | 1 - .../tasks/common/taskConfiguration.i18n.json | 3 +-- .../electron-browser/jsonSchema_v2.i18n.json | 9 ++++----- .../ita/extensions/git/out/commands.i18n.json | 3 +++ i18n/ita/extensions/git/package.i18n.json | 1 + i18n/ita/extensions/jake/out/main.i18n.json | 4 +++- i18n/ita/extensions/jake/package.i18n.json | 4 +++- .../markdown/out/extension.i18n.json | 4 +++- .../out/commandHandler.i18n.json | 7 ++++++- .../out/mergeDecorator.i18n.json | 5 ++++- .../merge-conflict/package.i18n.json | 8 +++++++- i18n/ita/extensions/npm/package.i18n.json | 4 +++- .../out/utils/typingsStatus.i18n.json | 1 - .../extensions/typescript/package.i18n.json | 5 +++-- .../resourceviewer/resourceViewer.i18n.json | 1 + .../src/vs/code/electron-main/menus.i18n.json | 2 +- .../config/commonEditorConfig.i18n.json | 3 +++ .../common/view/editorColorRegistry.i18n.json | 6 +++++- .../contrib/links/browser/links.i18n.json | 1 + .../theme/common/colorRegistry.i18n.json | 9 +++++++-- .../workbench/api/node/extHostTask.i18n.json | 6 ++++++ .../src/vs/workbench/common/theme.i18n.json | 3 --- .../electron-browser/workbench.i18n.json | 5 ++++- .../electron-browser/debugService.i18n.json | 2 +- .../performance.contribution.i18n.json | 4 +++- .../keybindingsEditorContribution.i18n.json | 1 - .../scm.contribution.i18n.json | 1 + .../tasks/common/taskConfiguration.i18n.json | 3 +-- .../electron-browser/jsonSchema_v2.i18n.json | 9 ++++----- .../themes.contribution.i18n.json | 1 + .../configurationEditingService.i18n.json | 7 ++++++- .../out/codelensProvider.i18n.json | 4 +--- .../out/commandHandler.i18n.json | 1 + .../out/mergeDecorator.i18n.json | 3 ++- .../merge-conflict/package.i18n.json | 8 ++++---- .../out/utils/typingsStatus.i18n.json | 1 - .../extensions/typescript/package.i18n.json | 4 ++-- .../src/vs/code/electron-main/menus.i18n.json | 2 +- .../config/commonEditorConfig.i18n.json | 3 +++ .../gotoError/browser/gotoError.i18n.json | 3 +-- .../theme/common/colorRegistry.i18n.json | 1 - .../workbench/api/node/extHostTask.i18n.json | 6 ++++++ .../parts/editor/editorStatus.i18n.json | 1 + .../src/vs/workbench/common/theme.i18n.json | 9 ++++++--- .../electron-browser/workbench.i18n.json | 5 ++++- .../electron-browser/debugService.i18n.json | 2 +- .../browser/extensionsActions.i18n.json | 9 ++++++--- .../extensionsUtils.i18n.json | 2 ++ .../keybindingsEditorContribution.i18n.json | 1 - .../dirtydiffDecorator.i18n.json | 6 +++++- .../parts/tasks/browser/quickOpen.i18n.json | 4 +--- .../tasks/common/taskConfiguration.i18n.json | 3 +-- .../electron-browser/jsonSchema_v2.i18n.json | 9 ++++----- .../electron-browser/welcomePage.i18n.json | 4 +--- .../out/utils/typingsStatus.i18n.json | 1 - .../extensions/typescript/package.i18n.json | 3 +-- .../src/vs/code/electron-main/menus.i18n.json | 2 +- .../workbench/api/node/extHostTask.i18n.json | 6 ++++++ .../src/vs/workbench/common/theme.i18n.json | 3 --- .../electron-browser/workbench.i18n.json | 5 ++++- .../electron-browser/debugService.i18n.json | 2 +- .../keybindingsEditorContribution.i18n.json | 1 - .../tasks/common/taskConfiguration.i18n.json | 3 +-- .../electron-browser/jsonSchema_v2.i18n.json | 9 ++++----- .../out/settingsDocumentHelper.i18n.json | 4 ++-- .../out/codelensProvider.i18n.json | 7 +------ .../out/commandHandler.i18n.json | 1 - .../merge-conflict/package.i18n.json | 8 -------- .../out/utils/typingsStatus.i18n.json | 1 - .../extensions/typescript/package.i18n.json | 4 ++-- .../src/vs/code/electron-main/menus.i18n.json | 4 ++-- .../config/commonEditorConfig.i18n.json | 1 - .../theme/common/colorRegistry.i18n.json | 9 +++++++-- .../workbench/api/node/extHostTask.i18n.json | 6 ++++++ .../src/vs/workbench/common/theme.i18n.json | 3 --- .../electron-browser/workbench.i18n.json | 5 ++++- .../electron-browser/debugService.i18n.json | 2 +- .../emmet.contribution.i18n.json | 3 +-- .../extensionsUtils.i18n.json | 1 + .../keybindingsEditorContribution.i18n.json | 1 - .../dirtydiffDecorator.i18n.json | 6 +++++- .../parts/tasks/browser/quickOpen.i18n.json | 4 +--- .../tasks/common/taskConfiguration.i18n.json | 3 +-- .../electron-browser/jsonSchema_v2.i18n.json | 9 ++++----- .../electron-browser/welcomePage.i18n.json | 4 +--- .../out/utils/typingsStatus.i18n.json | 1 - .../extensions/typescript/package.i18n.json | 3 +-- .../src/vs/code/electron-main/menus.i18n.json | 2 +- .../workbench/api/node/extHostTask.i18n.json | 6 ++++++ .../src/vs/workbench/common/theme.i18n.json | 3 --- .../electron-browser/workbench.i18n.json | 5 ++++- .../electron-browser/debugService.i18n.json | 2 +- .../keybindingsEditorContribution.i18n.json | 1 - .../tasks/common/taskConfiguration.i18n.json | 3 +-- .../electron-browser/jsonSchema_v2.i18n.json | 9 ++++----- 205 files changed, 469 insertions(+), 321 deletions(-) create mode 100644 i18n/chs/src/vs/workbench/api/node/extHostTask.i18n.json create mode 100644 i18n/cht/src/vs/workbench/api/node/extHostTask.i18n.json create mode 100644 i18n/deu/src/vs/workbench/api/node/extHostTask.i18n.json create mode 100644 i18n/esn/src/vs/workbench/api/node/extHostTask.i18n.json create mode 100644 i18n/fra/src/vs/workbench/api/node/extHostTask.i18n.json create mode 100644 i18n/ita/src/vs/workbench/api/node/extHostTask.i18n.json create mode 100644 i18n/jpn/src/vs/workbench/api/node/extHostTask.i18n.json create mode 100644 i18n/kor/src/vs/workbench/api/node/extHostTask.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/api/node/extHostTask.i18n.json create mode 100644 i18n/rus/src/vs/workbench/api/node/extHostTask.i18n.json diff --git a/i18n/chs/extensions/markdown/out/extension.i18n.json b/i18n/chs/extensions/markdown/out/extension.i18n.json index 8b6ad71cd4e..111330fed75 100644 --- a/i18n/chs/extensions/markdown/out/extension.i18n.json +++ b/i18n/chs/extensions/markdown/out/extension.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "onPreviewStyleLoadError": "无法加载“markdown.stylesâ€ï¼š{0}" +} \ No newline at end of file diff --git a/i18n/chs/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/chs/extensions/merge-conflict/out/codelensProvider.i18n.json index 3590523ef87..8b6ad71cd4e 100644 --- a/i18n/chs/extensions/merge-conflict/out/codelensProvider.i18n.json +++ b/i18n/chs/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -3,6 +3,4 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{ - "acceptCurrentChange": "采用当å‰æ›´æ”¹" -} \ No newline at end of file +{} \ No newline at end of file diff --git a/i18n/chs/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/chs/extensions/merge-conflict/out/commandHandler.i18n.json index 996cf7276b8..b6f2dae32e9 100644 --- a/i18n/chs/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/chs/extensions/merge-conflict/out/commandHandler.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "cursorNotInConflict": "编辑器光标ä¸åœ¨åˆå¹¶å†²çªå†…", + "cursorOnSplitterRange": "编辑器光标在åˆå¹¶å†²çªåˆ†å‰²çº¿ä¸Šï¼Œè¯·å°†å…¶ç§»åŠ¨è‡³â€œå½“å‰â€æˆ–“传入â€åŒºåŸŸä¸­", "noConflicts": "没有在此文件中找到åˆå¹¶å†²çª", "noOtherConflictsInThisFile": "此文件中没有其他åˆå¹¶å†²çªäº†" } \ No newline at end of file diff --git a/i18n/chs/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/chs/extensions/merge-conflict/out/mergeDecorator.i18n.json index feac7a236d8..6fb9fc93479 100644 --- a/i18n/chs/extensions/merge-conflict/out/mergeDecorator.i18n.json +++ b/i18n/chs/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "currentChange": "(当å‰æ›´æ”¹)" + "currentChange": "(当å‰æ›´æ”¹)", + "incomingChange": "(传入的更改)" } \ No newline at end of file diff --git a/i18n/chs/extensions/merge-conflict/package.i18n.json b/i18n/chs/extensions/merge-conflict/package.i18n.json index 82e4bc58463..7ed47cfef74 100644 --- a/i18n/chs/extensions/merge-conflict/package.i18n.json +++ b/i18n/chs/extensions/merge-conflict/package.i18n.json @@ -5,8 +5,8 @@ // Do not edit this file. It is machine generated. { "command.category": "åˆå¹¶å†²çª", - "command.next": "下一个冲çª", - "command.previous": "上一个冲çª", - "command.compare": "比较当å‰å†²çª", - "config.title": "åˆå¹¶å†²çª" + "command.accept.both": "ä¿ç•™ä¸¤è€…", + "config.title": "åˆå¹¶å†²çª", + "config.codeLensEnabled": "å¯ç”¨/ç¦ç”¨ç¼–辑器内åˆå¹¶å†²çªåŒºåŸŸçš„ CodeLens", + "config.decoratorsEnabled": "å¯ç”¨/ç¦ç”¨ç¼–辑器内的åˆå¹¶å†²çªä¿®é¥°å™¨" } \ No newline at end of file diff --git a/i18n/chs/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/chs/extensions/typescript/out/utils/typingsStatus.i18n.json index 01709f2e6d3..f6ee369cc40 100644 --- a/i18n/chs/extensions/typescript/out/utils/typingsStatus.i18n.json +++ b/i18n/chs/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -5,7 +5,6 @@ // Do not edit this file. It is machine generated. { "installingPackages": "æå–æ•°æ®ä»¥å®žçŽ°æ›´å¥½çš„ TypeScript IntelliSense", - "typesInstallerInitializationFailed.title": "无法为 JavaScript 语言功能安装 typings 文件。请确认 NPM å·²ç»å®‰è£…且ä½äºŽ PATH 中", "typesInstallerInitializationFailed.moreInformation": "详细信æ¯", "typesInstallerInitializationFailed.doNotCheckAgain": "ä¸è¦å†æ¬¡æ£€æŸ¥", "typesInstallerInitializationFailed.close": "关闭" diff --git a/i18n/chs/extensions/typescript/package.i18n.json b/i18n/chs/extensions/typescript/package.i18n.json index e9bd0e95be0..e5267352ece 100644 --- a/i18n/chs/extensions/typescript/package.i18n.json +++ b/i18n/chs/extensions/typescript/package.i18n.json @@ -41,6 +41,6 @@ "typescript.selectTypeScriptVersion.title": "选择 TypeScript 版本", "jsDocCompletion.enabled": "å¯ç”¨/ç¦ç”¨è‡ªåŠ¨ JSDoc 注释", "javascript.implicitProjectConfig.checkJs": "å¯ç”¨/ç¦ç”¨ JavaScript 文件的语义检查。现有的 jsconfig.json 或\n tsconfig.json 文件会覆盖此设置。è¦æ±‚ TypeScript >=2.3.1。", - "typescript.check.npmIsInstalled": "检查是å¦å®‰è£…了 NPM 以进行自动 typings 获å–", - "javascript.nameSuggestions": "å¯ç”¨/ç¦ç”¨åœ¨ JavaScript 建议列表中包å«æ–‡ä»¶ä¸­çš„唯一å称。" + "javascript.nameSuggestions": "å¯ç”¨/ç¦ç”¨åœ¨ JavaScript 建议列表中包å«æ–‡ä»¶ä¸­çš„唯一å称。", + "typescript.tsc.autoDetect": "控制自动检测 tsc 任务是å¦æ‰“开。" } \ No newline at end of file diff --git a/i18n/chs/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/chs/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index 4e5bf82d935..883b4c5cbca 100644 --- a/i18n/chs/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/chs/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,6 +6,7 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "图åƒå¤ªå¤§ï¼Œæ— æ³•åœ¨ç¼–辑器中显示。 ", + "resourceOpenExternalButton": "使用外部程åºæ‰“开图片?", "nativeBinaryError": "文件将ä¸åœ¨ç¼–辑器中显示,因为它是二进制文件ã€éžå¸¸å¤§æˆ–使用ä¸æ”¯æŒçš„文本编ç ã€‚", "sizeB": "{0} B", "sizeKB": "{0} KB", diff --git a/i18n/chs/src/vs/code/electron-main/menus.i18n.json b/i18n/chs/src/vs/code/electron-main/menus.i18n.json index 4f7e61e056c..10d2dd072d7 100644 --- a/i18n/chs/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/chs/src/vs/code/electron-main/menus.i18n.json @@ -153,12 +153,12 @@ "miLicense": "查看许å¯è¯(&&L)", "miPrivacyStatement": "éšç§å£°æ˜Ž(&&P)", "miAbout": "关于(&&A)", + "accessibilityOptionsWindowTitle": "辅助功能选项", "miRestartToUpdate": "é‡å¯ä»¥æ›´æ–°...", "miCheckingForUpdates": "正在检查更新...", "miDownloadUpdate": "下载å¯ç”¨æ›´æ–°", "miDownloadingUpdate": "正在下载更新...", "miInstallingUpdate": "正在安装更新...", - "miCheckForUpdates": "检查更新...", "aboutDetail": "\n版本 {0}\næ交 {1}\n日期 {2}\nShell {3}\n渲染器 {4}\nNode {5}", "okButton": "确定" } \ No newline at end of file diff --git a/i18n/chs/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/chs/src/vs/editor/common/config/commonEditorConfig.i18n.json index 5c4e0b1ea13..9943fbbaa8a 100644 --- a/i18n/chs/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/chs/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -23,6 +23,8 @@ "minimap.enabled": "控制是å¦æ˜¾ç¤º minimap", "minimap.renderCharacters": "呈现æŸè¡Œä¸Šçš„实际字符(与颜色å—相å)", "minimap.maxColumn": "é™åˆ¶æœ€å°æ˜ å°„的宽度,尽é‡å¤šåœ°å‘ˆçŽ°ç‰¹å®šæ•°é‡çš„列", + "find.seedSearchStringFromSelection": "控制是å¦å°†ç¼–辑器的选中内容作为æœç´¢è¯å¡«å…¥åˆ°æŸ¥æ‰¾ç»„件", + "find.autoFindInSelection": "控制当编辑器中选中多个字符或多行文字时是å¦å¼€å¯â€œåœ¨é€‰å®šå†…容中查找â€é€‰é¡¹ ", "wordWrap.off": "æ°¸ä¸æ¢è¡Œã€‚", "wordWrap.on": "将在视区宽度处æ¢è¡Œã€‚", "wordWrap.wordWrapColumn": "将在 \"editor.wordWrapColumn\" 处æ¢è¡Œã€‚", @@ -41,6 +43,7 @@ "formatOnType": "控制编辑器是å¦åº”在键入åŽè‡ªåŠ¨è®¾ç½®è¡Œçš„æ ¼å¼", "formatOnPaste": "控制编辑器是å¦åº”自动设置粘贴内容的格å¼ã€‚æ ¼å¼åŒ–程åºå¿…é¡»å¯ç”¨å¹¶ä¸”能设置文档中æŸä¸€èŒƒå›´çš„æ ¼å¼ã€‚", "suggestOnTriggerCharacters": "控制键入触å‘器字符时是å¦åº”自动显示建议", + "acceptSuggestionOnEnter": "控制按“Enterâ€é”®æ˜¯å¦åƒæŒ‰â€œTabâ€é”®ä¸€æ ·æŽ¥å—建议。这能帮助é¿å…“æ’入新行â€å’Œâ€œæŽ¥å—建议â€ä¹‹é—´çš„歧义。值为“smartâ€æ—¶è¡¨ç¤ºï¼Œä»…当文字改å˜æ—¶ï¼ŒæŒ‰â€œEnterâ€é”®æ‰èƒ½æŽ¥å—建议", "acceptSuggestionOnCommitCharacter": "控制是å¦åº”在é‡åˆ°æ交字符时接å—建议。例如,在 JavaScript 中,分å·(\";\")å¯ä»¥ä¸ºæ交字符,å¯æŽ¥å—建议并键入该字符。", "snippetSuggestions": "控制是å¦å°†ä»£ç æ®µä¸Žå…¶ä»–建议一起显示以åŠå®ƒä»¬çš„排åºæ–¹å¼ã€‚", "emptySelectionClipboard": "控制没有选择内容的å¤åˆ¶æ˜¯å¦å¤åˆ¶å½“å‰è¡Œã€‚", diff --git a/i18n/chs/src/vs/editor/common/view/editorColorRegistry.i18n.json b/i18n/chs/src/vs/editor/common/view/editorColorRegistry.i18n.json index dc0edc0650c..26da122b2d8 100644 --- a/i18n/chs/src/vs/editor/common/view/editorColorRegistry.i18n.json +++ b/i18n/chs/src/vs/editor/common/view/editorColorRegistry.i18n.json @@ -16,5 +16,9 @@ "editorBracketMatchBackground": "匹é…括å·çš„背景色", "editorBracketMatchBorder": "匹é…括å·å¤–框颜色", "editorOverviewRulerBorder": "概览标尺边框的颜色。", - "editorGutter": "编辑器导航线的背景色。导航线包括边缘符å·å’Œè¡Œå·ã€‚" + "editorGutter": "编辑器导航线的背景色。导航线包括边缘符å·å’Œè¡Œå·ã€‚", + "errorForeground": "编辑器中错误波浪线的å‰æ™¯è‰²ã€‚", + "errorBorder": "编辑器中错误波浪线的边框颜色。", + "warningForeground": "编辑器中警告波浪线的å‰æ™¯è‰²ã€‚", + "warningBorder": "编辑器中警告波浪线的边框颜色。" } \ No newline at end of file diff --git a/i18n/chs/src/vs/editor/contrib/accessibility/browser/accessibility.i18n.json b/i18n/chs/src/vs/editor/contrib/accessibility/browser/accessibility.i18n.json index 714861ecdf6..94299c46f7b 100644 --- a/i18n/chs/src/vs/editor/contrib/accessibility/browser/accessibility.i18n.json +++ b/i18n/chs/src/vs/editor/contrib/accessibility/browser/accessibility.i18n.json @@ -6,10 +6,10 @@ { "introMsg": "感谢试用 VS Code 的辅助功能选项。", "status": "状æ€:", - "tabFocusModeOnMsg": "在当å‰ç¼–辑器中按 Tab 会将焦点移动到下一个å¯èšç„¦çš„元素。通过按 {0} 切æ¢æ­¤è¡Œä¸ºã€‚", + "tabFocusModeOnMsg": "在当å‰ç¼–辑器中按 Tab 会将焦点移动到下一个å¯èšç„¦çš„元素。按 {0} æ¥åˆ‡æ¢æ­¤è¡Œä¸ºã€‚", "tabFocusModeOnMsgNoKb": "在当å‰ç¼–辑器中按 Tab 会将焦点移动到下一个å¯èšç„¦çš„元素。当å‰æ— æ³•é€šè¿‡é”®ç»‘定触å‘命令 {0}。", - "tabFocusModeOffMsg": "在当å‰ç¼–辑器中按 Tab å°†æ’入制表符。通过按 {0} 切æ¢æ­¤è¡Œä¸ºã€‚", + "tabFocusModeOffMsg": "在当å‰ç¼–辑器中按 Tab å°†æ’入制表符。按 {0} æ¥åˆ‡æ¢æ­¤è¡Œä¸ºã€‚", "tabFocusModeOffMsgNoKb": "在当å‰ç¼–辑器中按 Tab 会æ’入制表符。当å‰æ— æ³•é€šè¿‡é”®ç»‘定触å‘命令 {0}。", - "outroMsg": "å¯ä»¥é€šè¿‡æŒ‰ Esc 消除此工具æ示并返回到编辑器。", + "outroMsg": "ä½ å¯ä»¥æŒ‰ Esc é”®æ¥æ¶ˆé™¤æ­¤æ示并返回到编辑器。", "ShowAccessibilityHelpAction": "显示辅助功能帮助" } \ No newline at end of file diff --git a/i18n/chs/src/vs/editor/contrib/caretOperations/common/caretOperations.i18n.json b/i18n/chs/src/vs/editor/contrib/caretOperations/common/caretOperations.i18n.json index 11871e98a80..3e762317766 100644 --- a/i18n/chs/src/vs/editor/contrib/caretOperations/common/caretOperations.i18n.json +++ b/i18n/chs/src/vs/editor/contrib/caretOperations/common/caretOperations.i18n.json @@ -4,6 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "caret.moveLeft": "将脱字å·å‘左移", - "caret.moveRight": "将脱字å·å‘å³ç§»" + "caret.moveLeft": "å°†æ’入点左移", + "caret.moveRight": "å°†æ’入点å³ç§»" } \ No newline at end of file diff --git a/i18n/chs/src/vs/editor/contrib/format/browser/formatActions.i18n.json b/i18n/chs/src/vs/editor/contrib/format/browser/formatActions.i18n.json index d1fd1741e74..e1cac086434 100644 --- a/i18n/chs/src/vs/editor/contrib/format/browser/formatActions.i18n.json +++ b/i18n/chs/src/vs/editor/contrib/format/browser/formatActions.i18n.json @@ -4,10 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "hint11": "Made 1 formatting edit on line {0}", - "hintn1": "Made {0} formatting edits on line {1}", - "hint1n": "Made 1 formatting edit between lines {0} and {1}", + "hint11": "在第 {0} 行作出1 次格å¼ç¼–辑", + "hintn1": "在第 {1} 行进行了 {0} 次格å¼ç¼–辑", + "hint1n": "第 {0} 行到第 {1} 行间进行了 1 次格å¼ç¼–辑", "hintnn": "Made {0} formatting edits between lines {1} and {2}", "formatDocument.label": "Format Document", - "formatSelection.label": "Format Selection" + "formatSelection.label": "æ ¼å¼åŒ–选定代ç " } \ No newline at end of file diff --git a/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json index 8b6ad71cd4e..e788771d2f2 100644 --- a/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json +++ b/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -3,4 +3,21 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "noResultWord": "未找到“{0}â€çš„任何定义", + "generic.noResults": "找ä¸åˆ°å®šä¹‰", + "meta.title": " – {0} 定义", + "actions.goToDecl.label": "转到定义", + "actions.goToDeclToSide.label": "打开侧边的定义", + "actions.previewDecl.label": "查看定义", + "goToImplementation.noResultWord": "未找到“{0}â€çš„实现", + "goToImplementation.generic.noResults": "未找到实现", + "meta.implementations.title": "– {0} 个实现", + "actions.goToImplementation.label": "转到实现", + "actions.peekImplementation.label": "速览实现", + "goToTypeDefinition.noResultWord": "未找到“{0}â€çš„类型定义", + "goToTypeDefinition.generic.noResults": "未找到类型定义", + "meta.typeDefinitions.title": " – {0} 个类型定义", + "actions.goToTypeDefinition.label": "转到类型定义", + "actions.peekTypeDefinition.label": "快速查看类型定义" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json index 8b6ad71cd4e..ab0b4761cf9 100644 --- a/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json +++ b/i18n/chs/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "multipleResults": "å•å‡»æ˜¾ç¤º {0} 个定义。" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/editor/contrib/linesOperations/common/linesOperations.i18n.json b/i18n/chs/src/vs/editor/contrib/linesOperations/common/linesOperations.i18n.json index 59c62abf01c..346d11b6706 100644 --- a/i18n/chs/src/vs/editor/contrib/linesOperations/common/linesOperations.i18n.json +++ b/i18n/chs/src/vs/editor/contrib/linesOperations/common/linesOperations.i18n.json @@ -18,7 +18,7 @@ "lines.insertAfter": "在下é¢æ’入行", "lines.deleteAllLeft": "删除左侧所有内容", "lines.deleteAllRight": "删除å³ä¾§æ‰€æœ‰å†…容", - "lines.joinLines": "è”接行", + "lines.joinLines": "åˆå¹¶è¡Œ", "editor.transpose": "转置游标处的字符", "editor.transformToUppercase": "转æ¢ä¸ºå¤§å†™", "editor.transformToLowercase": "转æ¢ä¸ºå°å†™" diff --git a/i18n/chs/src/vs/editor/contrib/links/browser/links.i18n.json b/i18n/chs/src/vs/editor/contrib/links/browser/links.i18n.json index 345d85ddefa..9e17ff5092c 100644 --- a/i18n/chs/src/vs/editor/contrib/links/browser/links.i18n.json +++ b/i18n/chs/src/vs/editor/contrib/links/browser/links.i18n.json @@ -6,6 +6,7 @@ { "links.navigate.mac": "Cmd + å•å‡»ä»¥è·Ÿè¸ªé“¾æŽ¥", "links.navigate": "Ctrl + å•å‡»ä»¥è·Ÿè¸ªé“¾æŽ¥", + "links.navigate.al": "Alt + å•å‡»ä»¥è®¿é—®é“¾æŽ¥", "invalid.url": "抱歉,无法打开此链接,因为其格å¼ä¸æ­£ç¡®: {0}", "missing.url": "抱歉,无法打开此链接,因为其目标丢失。", "label": "打开链接" diff --git a/i18n/chs/src/vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode.i18n.json b/i18n/chs/src/vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode.i18n.json index a64a607ad87..897e74dff44 100644 --- a/i18n/chs/src/vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode.i18n.json +++ b/i18n/chs/src/vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode.i18n.json @@ -4,5 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "toggle.tabMovesFocus": "åˆ‡æ¢ Tab 键移动焦点" + "toggle.tabMovesFocus": "åˆ‡æ¢ Tab 键是å¦ç§»åŠ¨ç„¦ç‚¹" } \ No newline at end of file diff --git a/i18n/chs/src/vs/platform/keybinding/common/keybindingLabels.i18n.json b/i18n/chs/src/vs/platform/keybinding/common/keybindingLabels.i18n.json index 8fa747b0b99..0e97d8b37c3 100644 --- a/i18n/chs/src/vs/platform/keybinding/common/keybindingLabels.i18n.json +++ b/i18n/chs/src/vs/platform/keybinding/common/keybindingLabels.i18n.json @@ -8,9 +8,9 @@ "shiftKey": "Shift", "altKey": "Alt", "windowsKey": "Windows", - "ctrlKey.long": "控件", + "ctrlKey.long": "Control", "shiftKey.long": "Shift", "altKey.long": "Alt", - "cmdKey.long": "命令", + "cmdKey.long": "Command", "windowsKey.long": "Windows" } \ No newline at end of file diff --git a/i18n/chs/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/chs/src/vs/platform/theme/common/colorRegistry.i18n.json index 0af4fc2114c..37be20d77e9 100644 --- a/i18n/chs/src/vs/platform/theme/common/colorRegistry.i18n.json +++ b/i18n/chs/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -60,7 +60,6 @@ "editorBackground": "编辑器背景颜色。", "editorForeground": "编辑器默认å‰æ™¯è‰²ã€‚", "editorWidgetBackground": "编辑器组件(如查找/替æ¢)背景颜色。", - "editorWidgetBorder": "编辑器å°ç»„件的边框颜色。", "editorSelection": "编辑器所选内容的颜色。", "editorInactiveSelection": "éžæ´»åŠ¨ç¼–辑器中所选内容的颜色。", "editorSelectionHighlight": "与所选内容具有相åŒå†…容的区域颜色。", @@ -74,5 +73,11 @@ "diffEditorInserted": "å·²æ’入文本的背景颜色。", "diffEditorRemoved": "被删除文本的背景颜色。", "diffEditorInsertedOutline": "æ’入的文本的轮廓颜色。", - "diffEditorRemovedOutline": "被删除文本的轮廓颜色。" + "diffEditorRemovedOutline": "被删除文本的轮廓颜色。", + "mergeCurrentHeaderBackground": "内è”åˆå¹¶å†²çªä¸­å½“å‰ç‰ˆæœ¬åŒºåŸŸçš„标头背景色。", + "mergeCurrentContentBackground": "内è”åˆå¹¶å†²çªä¸­å½“å‰ç‰ˆæœ¬åŒºåŸŸçš„内容背景色。", + "mergeIncomingHeaderBackground": "内è”åˆå¹¶å†²çªä¸­ä¼ å…¥çš„版本区域的标头背景色。", + "mergeIncomingContentBackground": "内è”åˆå¹¶å†²çªä¸­ä¼ å…¥çš„版本区域的内容背景色。", + "overviewRulerCurrentContentForeground": "内è”åˆå¹¶å†²çªä¸­å½“å‰ç‰ˆæœ¬åŒºåŸŸçš„概览标尺å‰æ™¯è‰²ã€‚", + "overviewRulerIncomingContentForeground": "内è”åˆå¹¶å†²çªä¸­ä¼ å…¥çš„版本区域的概览标尺å‰æ™¯è‰²ã€‚" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/chs/src/vs/workbench/api/node/extHostTask.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/chs/src/vs/workbench/api/node/extHostTask.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json b/i18n/chs/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json index 7f7594d784a..056d85f4a23 100644 --- a/i18n/chs/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json +++ b/i18n/chs/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json @@ -11,6 +11,7 @@ "endOfLineLineFeed": "LF", "endOfLineCarriageReturnLineFeed": "CRLF", "tabFocusModeEnabled": "按 Tab 移动焦点", + "screenReaderDetected": "检测到å±å¹•é˜…读器", "disableTabMode": "ç¦ç”¨è¾…助功能模å¼", "gotoLine": "转到行", "indentation": "缩进", diff --git a/i18n/chs/src/vs/workbench/common/theme.i18n.json b/i18n/chs/src/vs/workbench/common/theme.i18n.json index 0f3e7eb1bf9..e130cd7df4d 100644 --- a/i18n/chs/src/vs/workbench/common/theme.i18n.json +++ b/i18n/chs/src/vs/workbench/common/theme.i18n.json @@ -7,34 +7,37 @@ "tabActiveBackground": "活动选项å¡çš„背景色。在编辑器区域,选项å¡æ˜¯ç¼–辑器的容器。å¯åœ¨ä¸€ä¸ªç¼–辑器组中打开多个选项å¡ã€‚å¯ä»¥æœ‰å¤šä¸ªç¼–辑器组。", "tabInactiveBackground": "éžæ´»åŠ¨é€‰é¡¹å¡çš„背景色。在编辑器区域,选项å¡æ˜¯ç¼–辑器的容器。å¯åœ¨ä¸€ä¸ªç¼–辑器组中打开多个选项å¡ã€‚å¯ä»¥æœ‰å¤šä¸ªç¼–辑器组。", "tabBorder": "用于将选项å¡å½¼æ­¤åˆ†éš”开的边框。选项å¡æ˜¯ç¼–辑器区域中编辑器的容器。å¯åœ¨ä¸€ä¸ªç¼–辑器组中打开多个选项å¡ã€‚å¯ä»¥å­˜åœ¨å¤šä¸ªç¼–辑器组。", - "tabActiveEditorGroupActiveForeground": "活动组中活动选项å¡çš„å‰æ™¯è‰²ã€‚在编辑器区域,选项å¡æ˜¯ç¼–辑器的容器。å¯åœ¨ä¸€ä¸ªç¼–辑器组中打开多个选项å¡ã€‚å¯ä»¥æœ‰å¤šä¸ªç¼–辑器组。", - "tabInactiveEditorGroupActiveForeground": "活动组中éžæ´»åŠ¨é€‰é¡¹å¡çš„å‰æ™¯è‰²ã€‚在编辑器区域,选项å¡æ˜¯ç¼–辑器的容器。å¯åœ¨ä¸€ä¸ªç¼–辑器组中打开多个选项å¡ã€‚å¯ä»¥æœ‰å¤šä¸ªç¼–辑器组。", "editorGroupBackground": "编辑器组的背景颜色。编辑器组是编辑器的容器。此颜色在拖动编辑器组时显示。", "tabsContainerBackground": "å¯ç”¨é€‰é¡¹å¡æ—¶ç¼–辑器组标题的背景颜色。编辑器组是编辑器的容器。", + "tabsContainerBorder": "选项å¡å¯ç”¨æ—¶ç¼–辑器组标题的边框颜色。编辑器组是编辑器的容器。", "editorGroupHeaderBackground": "ç¦ç”¨é€‰é¡¹å¡æ—¶ç¼–辑器组标题的背景颜色。编辑器组是编辑器的容器。", "editorGroupBorder": "将多个编辑器组彼此分隔开的颜色。编辑器组是编辑器的容器。", "editorDragAndDropBackground": "拖动编辑器时的背景颜色。此颜色应有é€æ˜Žåº¦ï¼Œä»¥ä¾¿ç¼–辑器内容能é€è¿‡èƒŒæ™¯ã€‚", - "panelBackground": "é¢æ¿çš„背景色。é¢æ¿æ˜¾ç¤ºåœ¨ç¼–辑器区域下方,å¯åŒ…å«è¾“出和集æˆç»ˆç«¯ç­‰è§†å›¾ã€‚", "panelBorder": "分隔到编辑器的顶部é¢æ¿è¾¹æ¡†è‰²ã€‚é¢æ¿æ˜¾ç¤ºåœ¨ç¼–辑器区域下方,å¯åŒ…å«è¾“出和集æˆç»ˆç«¯ç­‰è§†å›¾ã€‚", "panelActiveTitleForeground": "活动é¢æ¿çš„标题颜色。é¢æ¿æ˜¾ç¤ºåœ¨ç¼–辑器区域下方,并包å«è¾“出和集æˆç»ˆç«¯ç­‰è§†å›¾ã€‚", "panelInactiveTitleForeground": "éžæ´»åŠ¨é¢æ¿çš„标题颜色。é¢æ¿æ˜¾ç¤ºåœ¨ç¼–辑器区域下方,并包å«è¾“出和集æˆç»ˆç«¯ç­‰è§†å›¾ã€‚", "panelActiveTitleBorder": "活动é¢æ¿çš„边框颜色。é¢æ¿æ˜¾ç¤ºåœ¨ç¼–辑器区域下方,包å«è¾“出和集æˆç»ˆç«¯ç­‰è§†å›¾ã€‚", "statusBarForeground": "状æ€æ å‰æ™¯è‰²ã€‚状æ€æ æ˜¾ç¤ºåœ¨çª—å£åº•éƒ¨ã€‚", "statusBarBackground": "标准状æ€æ èƒŒæ™¯è‰²ã€‚状æ€æ æ˜¾ç¤ºåœ¨çª—å£åº•éƒ¨ã€‚", + "statusBarBorder": "状æ€æ åˆ†éš”侧边æ å’Œç¼–辑器的边框颜色。状æ€æ æ˜¾ç¤ºåœ¨çª—å£åº•éƒ¨ã€‚", "statusBarNoFolderBackground": "没有打开文件夹时状æ€æ çš„背景色。状æ€æ æ˜¾ç¤ºåœ¨çª—å£åº•éƒ¨ã€‚", + "statusBarNoFolderForeground": "没有打开文件夹时状æ€æ çš„å‰æ™¯è‰²ã€‚状æ€æ æ˜¾ç¤ºåœ¨çª—å£åº•éƒ¨ã€‚", "statusBarItemActiveBackground": "å•å‡»æ—¶çš„状æ€æ é¡¹èƒŒæ™¯è‰²ã€‚状æ€æ æ˜¾ç¤ºåœ¨çª—å£åº•éƒ¨ã€‚", "statusBarItemHoverBackground": "悬åœæ—¶çš„状æ€æ é¡¹èƒŒæ™¯è‰²ã€‚状æ€æ æ˜¾ç¤ºåœ¨çª—å£åº•éƒ¨ã€‚", "statusBarProminentItemBackground": "状æ€æ çªå‡ºæ˜¾ç¤ºé¡¹çš„背景颜色。çªå‡ºæ˜¾ç¤ºé¡¹æ¯”状æ€æ ä¸­çš„其他æ¡ç›®æ›´æ˜¾çœ¼ï¼Œè¡¨æ˜Žå…¶é‡è¦æ€§æ›´é«˜ã€‚状æ€æ æ˜¾ç¤ºåœ¨çª—å£åº•éƒ¨ã€‚", "statusBarProminentItemHoverBackground": "状æ€æ çªå‡ºæ˜¾ç¤ºé¡¹åœ¨æ‚¬åœæ—¶çš„背景颜色。çªå‡ºæ˜¾ç¤ºé¡¹æ¯”状æ€æ ä¸­çš„其他æ¡ç›®æ›´æ˜¾çœ¼ï¼Œè¡¨æ˜Žå…¶é‡è¦æ€§æ›´é«˜ã€‚状æ€æ æ˜¾ç¤ºåœ¨çª—å£åº•éƒ¨ã€‚", "activityBarBackground": "活动æ èƒŒæ™¯è‰²ã€‚活动æ æ˜¾ç¤ºåœ¨æœ€å·¦ä¾§æˆ–最å³ä¾§ï¼Œå¹¶å…许在侧边æ çš„视图间切æ¢ã€‚", "activityBarForeground": "活动æ å‰æ™¯è‰²(例如用于图标)。活动æ æ˜¾ç¤ºåœ¨æœ€å·¦ä¾§æˆ–最å³ä¾§ï¼Œå¹¶å…许在侧边æ çš„视图间切æ¢ã€‚", + "activityBarBorder": "活动æ åˆ†éš”侧边æ çš„边框颜色。活动æ æ˜¾ç¤ºåœ¨æœ€å·¦ä¾§æˆ–最å³ä¾§ï¼Œå¹¶å¯ä»¥åˆ‡æ¢ä¾§è¾¹æ çš„视图。", "activityBarDragAndDropBackground": "活动æ é¡¹åœ¨è¢«æ‹–放时的å馈颜色。此颜色应有é€æ˜Žåº¦ï¼Œä»¥ä¾¿æ´»åŠ¨æ æ¡ç›®èƒ½é€è¿‡æ­¤é¢œè‰²ã€‚活动æ æ˜¾ç¤ºåœ¨æœ€å·¦ä¾§æˆ–最å³ä¾§ï¼Œå¹¶å…许在侧边æ è§†å›¾ä¹‹é—´åˆ‡æ¢ã€‚", "activityBarBadgeBackground": "活动通知徽章背景色。活动æ æ˜¾ç¤ºåœ¨æœ€å·¦ä¾§æˆ–最å³ä¾§ï¼Œå¹¶å…许在侧边æ çš„视图间切æ¢ã€‚", "activityBarBadgeForeground": "活动通知徽章å‰æ™¯è‰²ã€‚活动æ æ˜¾ç¤ºåœ¨æœ€å·¦ä¾§æˆ–最å³ä¾§ï¼Œå¹¶å…许在侧边æ çš„视图间切æ¢ã€‚", "sideBarBackground": "侧边æ èƒŒæ™¯è‰²ã€‚侧边æ æ˜¯èµ„æºç®¡ç†å™¨å’Œæœç´¢ç­‰è§†å›¾çš„容器。", "sideBarForeground": "侧边æ å‰æ™¯è‰²ã€‚侧边æ æ˜¯èµ„æºç®¡ç†å™¨å’Œæœç´¢ç­‰è§†å›¾çš„容器。", + "sideBarBorder": "侧边æ åˆ†éš”编辑器的边框颜色。侧边æ åŒ…å«èµ„æºç®¡ç†å™¨ã€æœç´¢ç­‰è§†å›¾ã€‚", "sideBarTitleForeground": "侧边æ æ ‡é¢˜å‰æ™¯è‰²ã€‚侧边æ æ˜¯èµ„æºç®¡ç†å™¨å’Œæœç´¢ç­‰è§†å›¾çš„容器。", "sideBarSectionHeaderBackground": "侧边æ èŠ‚标题的背景颜色。侧边æ æ˜¯èµ„æºç®¡ç†å™¨å’Œæœç´¢ç­‰è§†å›¾çš„容器。", + "sideBarSectionHeaderForeground": "侧边æ èŠ‚标题的å‰æ™¯è‰²ã€‚侧边æ åŒ…括资æºç®¡ç†å™¨ã€æœç´¢ç­‰è§†å›¾ã€‚", "titleBarActiveForeground": "窗å£å¤„于活动状æ€æ—¶çš„标题æ å‰æ™¯è‰²ã€‚请注æ„,该颜色当å‰ä»…在 macOS 上å—支æŒã€‚", "titleBarInactiveForeground": "窗å£å¤„于éžæ´»åŠ¨çŠ¶æ€æ—¶çš„标题æ å‰æ™¯è‰²ã€‚请注æ„,该颜色当å‰ä»…在 macOS 上å—支æŒã€‚", "titleBarActiveBackground": "窗å£å¤„于活动状æ€æ—¶çš„标题æ èƒŒæ™¯è‰²ã€‚请注æ„,该颜色当å‰ä»…在 macOS 上å—支æŒã€‚", diff --git a/i18n/chs/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/chs/src/vs/workbench/electron-browser/workbench.i18n.json index 8b6ad71cd4e..b7d445f6a6a 100644 --- a/i18n/chs/src/vs/workbench/electron-browser/workbench.i18n.json +++ b/i18n/chs/src/vs/workbench/electron-browser/workbench.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "developer": "å¼€å‘者", + "file": "文件" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json b/i18n/chs/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json index f29ac67da10..31765f90ced 100644 --- a/i18n/chs/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json @@ -5,8 +5,8 @@ // Do not edit this file. It is machine generated. { "snapshotObj": "仅显示了此对象的基元值。", - "debuggingStarted": "已开始调试。", "debuggingPaused": "已暂åœè°ƒè¯•ï¼ŒåŽŸå›  {0},{1} {2}", + "debuggingStarted": "已开始调试。", "debuggingStopped": "å·²åœæ­¢è°ƒè¯•ã€‚", "breakpointAdded": "已添加断点,行 {0}, 文件 {1}", "breakpointRemoved": "已删除断点,行 {0},文件 {1}", diff --git a/i18n/chs/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json b/i18n/chs/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json index 6e5b8b41255..f5089c0197a 100644 --- a/i18n/chs/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "statusBarDebuggingBackground": "调试程åºæ—¶çŠ¶æ€æ çš„背景色。状æ€æ æ˜¾ç¤ºåœ¨çª—å£åº•éƒ¨" + "statusBarDebuggingBackground": "调试程åºæ—¶çŠ¶æ€æ çš„背景色。状æ€æ æ˜¾ç¤ºåœ¨çª—å£åº•éƒ¨", + "statusBarDebuggingForeground": "调试程åºæ—¶çŠ¶æ€æ çš„å‰æ™¯è‰²ã€‚状æ€æ æ˜¾ç¤ºåœ¨çª—å£åº•éƒ¨" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json b/i18n/chs/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json index af246476905..38c86c25f8b 100644 --- a/i18n/chs/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json @@ -22,6 +22,8 @@ "disableGloballyAction": "始终", "disableAction": "ç¦ç”¨", "checkForUpdates": "检查更新", + "enableAutoUpdate": "å¯ç”¨è‡ªåŠ¨æ›´æ–°æ‰©å±•", + "disableAutoUpdate": "ç¦ç”¨è‡ªåŠ¨æ›´æ–°æ‰©å±•", "updateAll": "更新所有扩展", "reloadAction": "é‡æ–°åŠ è½½", "postUpdateTooltip": "é‡è½½ä»¥æ›´æ–°", @@ -44,6 +46,8 @@ "showWorkspaceRecommendedExtensions": "显示工作区建议的扩展å", "showRecommendedKeymapExtensions": "显示推è键映射", "showRecommendedKeymapExtensionsShort": "键映射", + "showLanguageExtensions": "显示语言扩展", + "showLanguageExtensionsShort": "语言扩展", "configureWorkspaceRecommendedExtensions": "é…置建议的扩展(工作区)", "ConfigureWorkspaceRecommendations.noWorkspace": "建议仅在工作区文件夹上å¯ç”¨ã€‚", "OpenExtensionsFile.failed": "无法在 \".vscode\" 文件夹({0})内创建 \"extensions.json\" 文件。", @@ -51,5 +55,8 @@ "disableAll": "ç¦ç”¨æ‰€æœ‰å·²å®‰è£…的扩展", "disableAllWorkspace": "ç¦ç”¨æ­¤å·¥ä½œåŒºçš„所有已安装的扩展", "enableAll": "å¯ç”¨æ‰€æœ‰å·²å®‰è£…的扩展", - "enableAllWorkspace": "å¯ç”¨æ­¤å·¥ä½œåŒºçš„所有已安装的扩展" + "enableAllWorkspace": "å¯ç”¨æ­¤å·¥ä½œåŒºçš„所有已安装的扩展", + "extensionButtonProminentBackground": "扩展中çªå‡ºæ“作的按钮背景色(比如 安装按钮)。", + "extensionButtonProminentForeground": "扩展中çªå‡ºæ“作的按钮å‰æ™¯è‰²ï¼ˆæ¯”如 安装按钮)。", + "extensionButtonProminentHoverBackground": "扩展中çªå‡ºæ“作的按钮被悬åœæ—¶çš„颜色(比如 安装按钮)。" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/chs/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index a8554464048..518bee02115 100644 --- a/i18n/chs/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -4,8 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "disableOtherKeymapsConfirmation": "ç¦ç”¨å…¶ä»–键映射 ({0}) 以é¿å…键绑定之间的冲çªï¼Ÿ", "yes": "是", "no": "å¦", + "betterMergeDisabled": "现已内置 Better Merge 扩展。此扩展已被安装并ç¦ç”¨ï¼Œä¸”能被å¸è½½ã€‚", "uninstall": "å¸è½½", "later": "ç¨åŽ" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/chs/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 5813db26a24..955985888a9 100644 --- a/i18n/chs/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,6 +16,7 @@ "associations": "é…置语言的文件关è”(如: \"*.extension\": \"html\")。这些关è”的优先级高于已安装语言的默认关è”。", "encoding": "读å–和编写文件时将使用的默认字符集编ç ã€‚", "autoGuessEncoding": "å¯ç”¨æ—¶ï¼Œä¼šåœ¨æ‰“开文件时å°è¯•çŒœæµ‹å­—符集编ç ", + "eol": "默认行尾字符。使用 \\n 表示 LF,\\r\\n 表示 CRLF。", "trimTrailingWhitespace": "å¯ç”¨åŽï¼Œå°†åœ¨ä¿å­˜æ–‡ä»¶æ—¶å‰ªè£å°¾éšç©ºæ ¼ã€‚", "insertFinalNewline": "å¯ç”¨åŽï¼Œä¿å­˜æ–‡ä»¶æ—¶åœ¨æ–‡ä»¶æœ«å°¾æ’入一个最终新行。", "files.autoSave.off": "æ°¸ä¸è‡ªåŠ¨ä¿å­˜æ›´æ–°åŽçš„文件。", diff --git a/i18n/chs/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/chs/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json index 3db635ddc24..1cd8910edd8 100644 --- a/i18n/chs/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -5,6 +5,5 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.start": "定义键绑定", - "defineKeybinding.kbLayoutInfoMessage": "对于当å‰é”®ç›˜å¸ƒå±€ï¼ŒæŒ‰ ", "defineKeybinding.kbLayoutErrorMessage": "在当å‰é”®ç›˜å¸ƒå±€ä¸‹æ— æ³•ç”Ÿæˆæ­¤ç»„åˆé”®ã€‚" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/chs/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json index 8b6ad71cd4e..bc3bae9c0e5 100644 --- a/i18n/chs/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "editorGutterModifiedBackground": "编辑器导航线中被修改行的背景颜色。", + "editorGutterAddedBackground": "编辑器导航线中已æ’入行的背景颜色。", + "editorGutterDeletedBackground": "编辑器导航线中被删除行的背景颜色。" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json b/i18n/chs/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json index 340ee7fc03e..a667d902bfe 100644 --- a/i18n/chs/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json @@ -9,5 +9,6 @@ "vscode.extension.contributes.snippets-path": "代ç ç‰‡æ®µæ–‡ä»¶çš„路径。该路径相对于扩展文件夹,通常以 \"./snippets/\" 开头。", "invalid.language": "“contributes.{0}.languageâ€ä¸­å­˜åœ¨æœªçŸ¥çš„语言。æ供的值: {1}", "invalid.path.0": "“contributes.{0}.pathâ€ä¸­åº”为字符串。æ供的值: {1}", - "invalid.path.1": "“contributes.{0}.pathâ€({1})应包å«åœ¨æ‰©å±•çš„文件夹({2})内。这å¯èƒ½ä¼šä½¿æ‰©å±•ä¸å¯ç§»æ¤ã€‚" + "invalid.path.1": "“contributes.{0}.pathâ€({1})应包å«åœ¨æ‰©å±•çš„文件夹({2})内。这å¯èƒ½ä¼šä½¿æ‰©å±•ä¸å¯ç§»æ¤ã€‚", + "badVariableUse": "“{0}â€ä»£ç ç‰‡æ®µå¾ˆå¯èƒ½æ··æ·†äº†ç‰‡æ®µå˜é‡å’Œç‰‡æ®µå ä½ç¬¦ã€‚有关详细信æ¯ï¼Œè¯·è®¿é—® https://code.visualstudio.com/docs/editor/userdefinedsnippets#_snippet-syntax。" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/chs/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index 48bcbb508c2..bf5eec2631c 100644 --- a/i18n/chs/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,7 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0},任务", - "workspace": "æ¥è‡ªå·¥ä½œåŒº", - "extension": "æ¥è‡ªæ‰©å±•" + "entryAriaLabel": "{0},任务" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/chs/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json index 8490e6b190a..0c2209acdb6 100644 --- a/i18n/chs/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -5,13 +5,12 @@ // Do not edit this file. It is machine generated. { "ConfigurationParser.invalidCWD": "警告: options.cwd 必须属于字符串类型。正在忽略值 {0}\n", - "ConfigurationParser.noShell": "警告: ä»…å½“åœ¨ç»ˆç«¯ä¸­æ‰§è¡Œä»»åŠ¡æ—¶æ”¯æŒ shell é…置。", "ConfigurationParser.noargs": "错误: 命令å‚数必须是字符串数组。æ供的值为:\n{0}", + "ConfigurationParser.noShell": "警告: ä»…å½“åœ¨ç»ˆç«¯ä¸­æ‰§è¡Œä»»åŠ¡æ—¶æ”¯æŒ shell é…置。", "ConfigurationParser.noName": "错误: 声明范围内的问题匹é…程åºå¿…须具有å称:\n{0}\n", "ConfigurationParser.unknownMatcherKind": "警告: 已定义的问题匹é…程åºæœªçŸ¥ã€‚å—支æŒçš„类型为 string | ProblemMatcher | (string | ProblemMatcher)[]。\n{0}\n", "ConfigurationParser.invalidVaraibleReference": "错误: 无效的 problemMatcher 引用: {0}\n", "ConfigurationParser.noTaskName": "错误: 任务必须æä¾› taskName 属性。将忽略该任务。\n{0}\n", "taskConfiguration.shellArgs": "警告: 任务“{0}â€æ˜¯ shell 命令,该命令的å称或其中一个å‚数具有éžè½¬ä¹‰ç©ºæ ¼ã€‚è‹¥è¦ç¡®ä¿å‘½ä»¤è¡Œå¼•ç”¨æ­£ç¡®ï¼Œè¯·å°†å‚æ•°åˆå¹¶åˆ°è¯¥å‘½ä»¤ã€‚", - "taskConfiguration.noCommandOrDependsOn": "错误: 任务“{0}â€æ—¢ä¸æŒ‡å®šå‘½ä»¤ï¼Œä¹Ÿä¸æŒ‡å®š dependsOn 属性。将忽略该任务。其定义为:\n{1}", "taskConfiguration.noCommand": "错误: 任务“{0}â€æœªå®šä¹‰å‘½ä»¤ã€‚将忽略该任务。其定义为:\n{1}" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json index 4106097a93e..0fc11b17268 100644 --- a/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -4,11 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "JsonSchema.version": "é…置的版本å·", - "JsonSchema.windows": "Windows 特定的命令é…ç½®", - "JsonSchema.mac": "Mac 特定的命令é…ç½®", - "JsonSchema.linux": "Linux 特定的命令é…ç½®", "JsonSchema.shell": "指定命令是 shell 命令还是外部程åºã€‚如果çœç•¥ï¼Œé»˜è®¤å€¼æ˜¯ false。", "JsonSchema.tasks.dependsOn.string": "此任务ä¾èµ–çš„å¦ä¸€ä»»åŠ¡ã€‚", - "JsonSchema.tasks.dependsOn.array": "此任务ä¾èµ–的其他任务。" + "JsonSchema.tasks.dependsOn.array": "此任务ä¾èµ–的其他任务。", + "JsonSchema.windows": "Windows 特定的命令é…ç½®", + "JsonSchema.mac": "Mac 特定的命令é…ç½®", + "JsonSchema.linux": "Linux 特定的命令é…ç½®" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 07f438f169e..495283f621e 100644 --- a/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -22,10 +22,8 @@ "welcomePage.installingKeymap": "正在安装 {0} 键盘快æ·æ–¹å¼...", "welcomePage.keymapNotFound": "找ä¸åˆ° ID 为 {1} çš„ {0} 键盘快æ·æ–¹å¼ã€‚", "welcome.title": "欢迎使用", - "welcomePage.extensionListSeparator": ",", + "welcomePage.extensionListSeparator": "ã€", "welcomePage.installedExtension": "{0}(已安装)", "ok": "确定", - "cancel": "å–消", - "welcomePage.quickLinkBackground": "欢迎页快速链接的背景颜色。", - "welcomePage.quickLinkHoverBackground": "欢迎页快速链接被悬åœæ—¶çš„背景颜色。" + "cancel": "å–消" } \ No newline at end of file diff --git a/i18n/cht/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/cht/extensions/merge-conflict/out/codelensProvider.i18n.json index fd3fc4ee512..8b6ad71cd4e 100644 --- a/i18n/cht/extensions/merge-conflict/out/codelensProvider.i18n.json +++ b/i18n/cht/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -3,9 +3,4 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{ - "acceptCurrentChange": "接å—當å‰è®Šæ›´", - "acceptIncomingChange": "接å—來æºè®Šæ›´", - "acceptBothChanges": "接å—兩者變更", - "compareChanges": "比較變更" -} \ No newline at end of file +{} \ No newline at end of file diff --git a/i18n/cht/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/cht/extensions/merge-conflict/out/commandHandler.i18n.json index b72349a9332..fe300c53427 100644 --- a/i18n/cht/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/cht/extensions/merge-conflict/out/commandHandler.i18n.json @@ -4,6 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "cursorNotInConflict": "編輯器游標ä¸åœ¨è¡çªåˆä½µç¯„åœä¹‹å…§", + "cursorOnSplitterRange": "編輯器游標在è¡çªåˆä½µå·¥å…·ç¯„åœå…§,請移動至\"當å‰é …ç›®\"或來æºé …ç›®\"å€å¡Š", "noConflicts": "檔案內找ä¸åˆ°éœ€è¦åˆä½µè¡çªé …ç›®", "noOtherConflictsInThisFile": "此檔案內沒有其他的è¡çªåˆä½µé …ç›®" } \ No newline at end of file diff --git a/i18n/cht/extensions/merge-conflict/package.i18n.json b/i18n/cht/extensions/merge-conflict/package.i18n.json index 1afd0effd3e..8546878e4e4 100644 --- a/i18n/cht/extensions/merge-conflict/package.i18n.json +++ b/i18n/cht/extensions/merge-conflict/package.i18n.json @@ -5,15 +5,8 @@ // Do not edit this file. It is machine generated. { "command.category": "åˆä½µè¡çª", - "command.accept.all-incoming": "接å—所有來æº", - "command.accept.all-both": "接å—兩者", - "command.accept.current": "接å—當å‰é …ç›®", - "command.accept.incoming": "接å—來æº", - "command.accept.selection": "接å—é¸å–é …ç›®", "command.accept.both": "接å—兩者", - "command.next": "後一個è¡çª", - "command.previous": "å‰ä¸€å€‹è¡çª", - "command.compare": "比較目å‰è¡çª", "config.title": "åˆä½µè¡çª", - "config.codeLensEnabled": "啟用/åœç”¨ 編輯器CodeLensè¡çªåˆä½µ " + "config.codeLensEnabled": "啟用/åœç”¨ 編輯器CodeLensè¡çªåˆä½µ ", + "config.decoratorsEnabled": "啟用/åœç”¨ 編輯器è¡çªåˆä½µè‰²å½©è£é£¾" } \ No newline at end of file diff --git a/i18n/cht/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/cht/extensions/typescript/out/utils/typingsStatus.i18n.json index 1c4d07bd746..4f15ff5fc04 100644 --- a/i18n/cht/extensions/typescript/out/utils/typingsStatus.i18n.json +++ b/i18n/cht/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -5,7 +5,6 @@ // Do not edit this file. It is machine generated. { "installingPackages": "正在擷å–資料以改善 TypeScript IntelliSense", - "typesInstallerInitializationFailed.title": "無法安è£éµå…¥æª”案以å–å¾— JavaScript èªžè¨€åŠŸèƒ½ã€‚è«‹ç¢ºèª NPM 已安è£ï¼Œä¸”ä½æ–¼æ‚¨çš„ PATH", "typesInstallerInitializationFailed.moreInformation": "詳細資訊", "typesInstallerInitializationFailed.doNotCheckAgain": "ä¸è¦å†æª¢æŸ¥", "typesInstallerInitializationFailed.close": "關閉" diff --git a/i18n/cht/extensions/typescript/package.i18n.json b/i18n/cht/extensions/typescript/package.i18n.json index 316f057d5a8..a9e009d33a4 100644 --- a/i18n/cht/extensions/typescript/package.i18n.json +++ b/i18n/cht/extensions/typescript/package.i18n.json @@ -33,10 +33,13 @@ "javascript.validate.enable": "啟用/åœç”¨ JavaScript 驗證。", "typescript.goToProjectConfig.title": "移至專案組態", "javascript.goToProjectConfig.title": "移至專案組態", + "javascript.referencesCodeLens.enabled": "在JavaScript檔案啟用/åœç”¨ åƒè€ƒCodeLens ", + "typescript.referencesCodeLens.enabled": "在TypeScript檔案啟用/åœç”¨CodeLensåƒè€ƒã€‚需è¦TypeScript>=2.0.6。", "typescript.implementationsCodeLens.enabled": "啟用/åœç”¨å¯¦ä½œ CodeLensã€‚éœ€è¦ TypeScript >= 2.2.0。", "typescript.openTsServerLog.title": "é–‹å•Ÿ TS 伺æœå™¨è¨˜éŒ„", + "typescript.restartTsServer": "é‡æ–°å•Ÿå‹•TS伺æœå™¨", "typescript.selectTypeScriptVersion.title": "é¸å– TypeScript 版本", "jsDocCompletion.enabled": "啟用/åœç”¨è‡ªå‹• JSDoc 註解", "javascript.implicitProjectConfig.checkJs": "啟用/åœç”¨ JavaScript 檔案的語æ„檢查。ç¾æœ‰çš„ jsconfig.json 或 tsconfig.json æª”æ¡ˆæœƒè¦†å¯«æ­¤è¨­å®šã€‚éœ€è¦ TypeScript >=2.3.1。", - "typescript.check.npmIsInstalled": "檢查是å¦å·²å®‰è£ NPM,以å–得自動éµå…¥" + "javascript.nameSuggestions": "從JavaScript推薦表檔案中啟用/åœç”¨åŒ…å«å”¯ä¸€æª”å" } \ No newline at end of file diff --git a/i18n/cht/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/cht/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index c01f13f3bcb..a88561eebde 100644 --- a/i18n/cht/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/cht/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,6 +6,7 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "因為影åƒå¤ªå¤§ï¼Œæ‰€ä»¥ç„¡æ³•åœ¨ç·¨è¼¯å™¨ä¸­é¡¯ç¤ºã€‚", + "resourceOpenExternalButton": "è¦ä½¿ç”¨å¤–部程å¼æ‰“é–‹å½±åƒå—Ž?", "nativeBinaryError": "檔案為二進ä½æª”ã€éžå¸¸å¤§æˆ–使用ä¸æ”¯æ´çš„文字編碼,因此將ä¸æœƒé¡¯ç¤ºæ–¼ç·¨è¼¯å™¨ä¸­ã€‚", "sizeB": "{0}B", "sizeKB": "{0}KB", diff --git a/i18n/cht/src/vs/code/electron-main/menus.i18n.json b/i18n/cht/src/vs/code/electron-main/menus.i18n.json index 5961aa8e789..6d87a7b4902 100644 --- a/i18n/cht/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/cht/src/vs/code/electron-main/menus.i18n.json @@ -149,12 +149,12 @@ "miLicense": "檢視授權(&&L)", "miPrivacyStatement": "éš±ç§æ¬Šè²æ˜Ž(&&P)", "miAbout": "關於(&&A)", + "accessibilityOptionsWindowTitle": "å”助工具é¸é …", "miRestartToUpdate": "é‡æ–°å•Ÿå‹•ä»¥æ›´æ–°...", "miCheckingForUpdates": "正在查看是å¦æœ‰æ›´æ–°...", "miDownloadUpdate": "下載å¯ç”¨æ›´æ–°", "miDownloadingUpdate": "正在下載更新...", "miInstallingUpdate": "正在安è£æ›´æ–°...", - "miCheckForUpdates": "查看是å¦æœ‰æ›´æ–°...", "aboutDetail": "\n版本 {0}\nèªå¯ {1}\n日期 {2}\nShell {3}\n轉譯器 {4}\nNode {5}", "okButton": "確定" } \ No newline at end of file diff --git a/i18n/cht/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/cht/src/vs/editor/common/config/commonEditorConfig.i18n.json index f06682edb16..f1f6f5fa235 100644 --- a/i18n/cht/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/cht/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -9,6 +9,7 @@ "fontWeight": "控制字型寬度。", "fontSize": "æŽ§åˆ¶å­—åž‹å¤§å° (以åƒç´ ç‚ºå–®ä½)。", "lineHeight": "控制行高。使用 0 會從 fontSize 計算 lineHeight。", + "letterSpacing": "æŽ§åˆ¶å­—å…ƒé–“è· (以åƒç´ ç‚ºå–®ä½)", "lineNumbers": "控制行號顯示。å¯èƒ½çš„值有 'on'ã€'off' åŠ 'relative'。'relative' 會從目å‰çš„資料指標ä½ç½®é¡¯ç¤ºè¡Œæ•¸ã€‚", "rulers": "è¦åœ¨å…¶ä¸­é¡¯ç¤ºåž‚ç›´å°ºè¦çš„資料行", "wordSeparators": "執行文字相關導覽或作業時將作為文字分隔符號的字元", diff --git a/i18n/cht/src/vs/editor/common/view/editorColorRegistry.i18n.json b/i18n/cht/src/vs/editor/common/view/editorColorRegistry.i18n.json index b08c173b100..a64950d25e3 100644 --- a/i18n/cht/src/vs/editor/common/view/editorColorRegistry.i18n.json +++ b/i18n/cht/src/vs/editor/common/view/editorColorRegistry.i18n.json @@ -16,5 +16,9 @@ "editorBracketMatchBackground": "æˆå°æ‹¬è™ŸèƒŒæ™¯è‰²å½©", "editorBracketMatchBorder": "æˆå°æ‹¬è™Ÿé‚Šæ¡†è‰²å½©", "editorOverviewRulerBorder": "é è¦½æª¢è¦–編輯器尺è¦çš„邊框色彩.", - "editorGutter": "編輯器邊框的背景é¡è‰²,包å«è¡Œè™Ÿèˆ‡å­—形圖示的邊框." + "editorGutter": "編輯器邊框的背景é¡è‰²,包å«è¡Œè™Ÿèˆ‡å­—形圖示的邊框.", + "errorForeground": "編輯器內錯誤æ示線的å‰æ™¯è‰²å½©.", + "errorBorder": "編輯器內錯誤æ示線的邊框色彩.", + "warningForeground": "編輯器內警告æ示線的å‰æ™¯è‰²å½©.", + "warningBorder": "編輯器內警告æ示線的邊框色彩." } \ No newline at end of file diff --git a/i18n/cht/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json b/i18n/cht/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json index 13c0c141c50..3c019fc1a1c 100644 --- a/i18n/cht/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json +++ b/i18n/cht/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json @@ -16,5 +16,7 @@ "schema.autoClosingPairs": "定義æˆå°æ‹¬å¼§ã€‚輸入左括弧時,å³è‡ªå‹•æ’å…¥å³æ‹¬å¼§ã€‚", "schema.autoClosingPairs.notIn": "定義åœç”¨è‡ªå‹•é…å°çš„範åœæ¸…單。", "schema.surroundingPairs": "定義å¯ç”¨ä»¥æ‹¬ä½æ‰€é¸å­—串的æˆå°æ‹¬å¼§ã€‚", + "schema.wordPattern.pattern": "使用正è¦è¡¨ç¤ºå¼é€²è¡Œæ–‡å­—比å°", + "schema.wordPattern.flags": "使用正è¦è¡¨ç¤ºå¼æ¨™è¨˜é€²è¡Œæ–‡å­—比å°", "schema.wordPattern.flags.errorMessage": "必須符åˆæ¨£å¼ `/^([gimuy]+)$/`" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/cht/src/vs/workbench/api/node/extHostTask.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/cht/src/vs/workbench/api/node/extHostTask.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/common/theme.i18n.json b/i18n/cht/src/vs/workbench/common/theme.i18n.json index 72a8d8abb7e..ae6c513e6ce 100644 --- a/i18n/cht/src/vs/workbench/common/theme.i18n.json +++ b/i18n/cht/src/vs/workbench/common/theme.i18n.json @@ -7,12 +7,9 @@ "tabActiveBackground": "使用中之索引標籤的背景色彩。索引標籤是編輯器在編輯器å€åŸŸä¸­çš„容器。åŒä¸€å€‹ç·¨è¼¯å™¨ç¾¤çµ„中的多個索引標籤å¯ä»¥åŒæ™‚開啟。å¯èƒ½æœƒæœ‰å¤šå€‹ç·¨è¼¯å™¨ç¾¤çµ„。", "tabInactiveBackground": "éžä½¿ç”¨ä¸­ä¹‹ç´¢å¼•æ¨™ç±¤çš„背景色彩。索引標籤是編輯器在編輯器å€åŸŸä¸­çš„容器。åŒä¸€å€‹ç·¨è¼¯å™¨ç¾¤çµ„中的多個索引標籤å¯ä»¥åŒæ™‚開啟。å¯èƒ½æœƒæœ‰å¤šå€‹ç·¨è¼¯å™¨ç¾¤çµ„。", "tabBorder": "用以分隔索引標籤彼此的框線。索引標籤是編輯器在編輯器å€åŸŸä¸­çš„容器。åŒä¸€å€‹ç·¨è¼¯å™¨ç¾¤çµ„中的多個索引標籤å¯ä»¥åŒæ™‚開啟。å¯èƒ½æœƒæœ‰å¤šå€‹ç·¨è¼¯å™¨ç¾¤çµ„。", - "tabActiveEditorGroupActiveForeground": "使用中的群組內,使用中之索引標籤的å‰æ™¯è‰²å½©ã€‚索引標籤是編輯器在編輯器å€åŸŸä¸­çš„容器。åŒä¸€å€‹ç·¨è¼¯å™¨ç¾¤çµ„中的多個索引標籤å¯ä»¥åŒæ™‚開啟。å¯èƒ½æœƒæœ‰å¤šå€‹ç·¨è¼¯å™¨ç¾¤çµ„。", - "tabInactiveEditorGroupActiveForeground": "使用中的群組內,éžä½¿ç”¨ä¸­ä¹‹ç´¢å¼•æ¨™ç±¤çš„å‰æ™¯è‰²å½©ã€‚索引標籤是編輯器在編輯器å€åŸŸä¸­çš„容器。åŒä¸€å€‹ç·¨è¼¯å™¨ç¾¤çµ„中的多個索引標籤å¯ä»¥åŒæ™‚開啟。å¯èƒ½æœƒæœ‰å¤šå€‹ç·¨è¼¯å™¨ç¾¤çµ„。", "editorGroupBackground": "編輯器群組的背景色彩。編輯器群組是編輯器的容器。當拖曳編輯器群組時會顯示背景色彩。", "editorGroupHeaderBackground": "當索引標籤ç¦ç”¨çš„時候編輯器群組標題的背景é¡è‰²ã€‚編輯器群組是編輯器的容器。", "editorGroupBorder": "用以分隔多個編輯器群組彼此的色彩。編輯器群組是編輯器的容器。", - "panelBackground": "é¢æ¿çš„å‰æ™¯è‰²å½©ã€‚é¢æ¿æœƒé¡¯ç¤ºåœ¨ç·¨è¼¯å™¨å€åŸŸçš„下方,其中包å«è«¸å¦‚輸出與整åˆå¼çµ‚端機等檢視。", "panelBorder": "é¢æ¿é ‚端用以分隔編輯器的邊框色彩。é¢æ¿æœƒé¡¯ç¤ºåœ¨ç·¨è¼¯å™¨å€åŸŸçš„下方,其中包å«è«¸å¦‚輸出與整åˆå¼çµ‚端機等檢視。", "panelActiveTitleForeground": "使用中之é¢æ¿æ¨™é¡Œçš„標題色彩。é¢æ¿æœƒé¡¯ç¤ºåœ¨ç·¨è¼¯å™¨å€åŸŸçš„下方,其中包å«è«¸å¦‚輸出與整åˆå¼çµ‚端機等檢視。", "panelInactiveTitleForeground": "éžä½¿ç”¨ä¸­ä¹‹é¢æ¿æ¨™é¡Œçš„標題色彩。é¢æ¿æœƒé¡¯ç¤ºåœ¨ç·¨è¼¯å™¨å€åŸŸçš„下方,其中包å«è«¸å¦‚輸出與整åˆå¼çµ‚端機等檢視。", diff --git a/i18n/cht/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/cht/src/vs/workbench/electron-browser/workbench.i18n.json index 8b6ad71cd4e..2375ce9a84f 100644 --- a/i18n/cht/src/vs/workbench/electron-browser/workbench.i18n.json +++ b/i18n/cht/src/vs/workbench/electron-browser/workbench.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "developer": "開發人員", + "file": "檔案" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json b/i18n/cht/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json index c3db57caac6..4ff9fe0b2b9 100644 --- a/i18n/cht/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json @@ -5,8 +5,8 @@ // Do not edit this file. It is machine generated. { "snapshotObj": "åªæœƒé¡¯ç¤ºæ­¤ç‰©ä»¶çš„基本值。", - "debuggingStarted": "åµéŒ¯å·²é–‹å§‹ã€‚", "debuggingPaused": "åµéŒ¯å·²æš«åœï¼ŒåŽŸå›  {0},{1} {2}", + "debuggingStarted": "åµéŒ¯å·²é–‹å§‹ã€‚", "debuggingStopped": "åµéŒ¯å·²åœæ­¢ã€‚", "breakpointAdded": "已新增中斷點,行 {0},檔案 {1}", "breakpointRemoved": "已移除中斷點,行 {0},檔案 {1}", diff --git a/i18n/cht/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/cht/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json index 0d448edf6a5..799796b51ff 100644 --- a/i18n/cht/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -5,6 +5,5 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.start": "定義按éµç¹«çµé—œä¿‚", - "defineKeybinding.kbLayoutInfoMessage": "é‡å°æ‚¨ç›®å‰çš„éµç›¤é…置,請按 ", "defineKeybinding.kbLayoutErrorMessage": "您無法在目å‰çš„éµç›¤é…置下產生此按éµçµ„åˆã€‚" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/cht/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index c9f6c178105..e35a0884650 100644 --- a/i18n/cht/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,7 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0},工作", - "workspace": "從工作å€", - "extension": "從擴充功能" + "entryAriaLabel": "{0},工作" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/cht/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json index 8da7ffbc6c4..e2b27a208b0 100644 --- a/i18n/cht/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -5,13 +5,12 @@ // Do not edit this file. It is machine generated. { "ConfigurationParser.invalidCWD": "警告: options.cwd 必須屬於字串類型。å³å°‡å¿½ç•¥å€¼ {0}。", - "ConfigurationParser.noShell": "警告: åªæœ‰åœ¨çµ‚端機中執行工作時æ‰æ”¯æ´æ®¼å±¤çµ„態。", "ConfigurationParser.noargs": "錯誤: 命令引數必須是字串陣列。æ供的值為:\n{0}", + "ConfigurationParser.noShell": "警告: åªæœ‰åœ¨çµ‚端機中執行工作時æ‰æ”¯æ´æ®¼å±¤çµ„態。", "ConfigurationParser.noName": "錯誤: 宣告範åœä¸­çš„å•é¡Œæ¯”å°å™¨å¿…須有å稱:\n{0}\n", "ConfigurationParser.unknownMatcherKind": "警告: 定義的å•é¡Œæ¯”å°å™¨æœªçŸ¥ã€‚支æ´çš„類型為 string | ProblemMatcher | (string | ProblemMatcher)[]。\n{0}\n", "ConfigurationParser.invalidVaraibleReference": "錯誤: problemMatcher åƒè€ƒç„¡æ•ˆ: {0}\n", "ConfigurationParser.noTaskName": "錯誤: 工作必須æä¾› taskName 屬性。å³å°‡å¿½ç•¥æ­¤å·¥ä½œã€‚\n{0}\n", "taskConfiguration.shellArgs": "警告: 工作 '{0}' 是殼層命令,但命令å稱或其中一個引數有的未逸出的空格。若è¦ç¢ºä¿å‘½ä»¤åˆ—正確引述,請將引數åˆä½µåˆ°å‘½ä»¤ä¸­ã€‚", - "taskConfiguration.noCommandOrDependsOn": "錯誤: 工作 '{0}' 未指定命令或 dependsOn 屬性。å³å°‡ç•¥éŽè©²å·¥ä½œã€‚其定義為:\n{1}", "taskConfiguration.noCommand": "錯誤: 工作 '{0}' 未定義命令。å³å°‡ç•¥éŽè©²å·¥ä½œã€‚其定義為:\n{1}" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json index 91d93e19374..b24501dac4e 100644 --- a/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -4,11 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "JsonSchema.version": "組態的版本號碼", - "JsonSchema.windows": "Windows 特定命令組態", - "JsonSchema.mac": "Mac 特定命令組態", - "JsonSchema.linux": "Linux 特定命令組態", "JsonSchema.shell": "指定此命令是殼層命令或外部程å¼ã€‚如果çœç•¥ï¼Œé è¨­ç‚º False。", "JsonSchema.tasks.dependsOn.string": "此工作相ä¾çš„å¦ä¸€å€‹å·¥ä½œã€‚", - "JsonSchema.tasks.dependsOn.array": "此工作相ä¾çš„其他工作。" + "JsonSchema.tasks.dependsOn.array": "此工作相ä¾çš„其他工作。", + "JsonSchema.windows": "Windows 特定命令組態", + "JsonSchema.mac": "Mac 特定命令組態", + "JsonSchema.linux": "Linux 特定命令組態" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json b/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json index f73c9b1e8a6..c0537ee4cdf 100644 --- a/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json @@ -18,6 +18,7 @@ "problems": "å•é¡Œ", "manyMarkers": "99+", "tasks": "工作", + "TaskSystem.noHotSwap": "變更工作執行引擎需è¦é‡æ–°å•Ÿå‹• VS Code。已略éŽè®Šæ›´ã€‚", "TaskService.noBuildTask": "未定義任何建置工作。請使用 'isBuildCommand' 標記 tasks.json 檔案中的工作。", "TaskService.noTestTask": "未定義任何建置工作。請使用 'isTestCommand' 標記 tasks.json 檔案中的工作。", "TaskServer.noTask": "找ä¸åˆ°æ‰€è¦æ±‚è¦åŸ·è¡Œçš„工作 {0}。", diff --git a/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json index 9a00f615c32..41c9f9e1a0d 100644 --- a/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -20,8 +20,10 @@ "welcomePage.stackOverflow": "Stack Overflow", "welcomePage.showOnStartup": "啟動時顯示歡迎é é¢", "welcomePage.customize": "自訂", + "welcomePage.installExtensionPacks": "工具與語言", "welcomePage.moreExtensions": "更多", "welcomePage.installKeymapDescription": "安è£éµç›¤å¿«é€Ÿéµ", + "welcomePage.installKeymapExtension": "安è£éµç›¤å¿«é€Ÿéµ{0}與{1}", "welcomePage.others": "其他", "welcomePage.colorTheme": "彩色佈景主題", "welcomePage.colorThemeDescription": "將編輯器åŠæ‚¨çš„程å¼ç¢¼è¨­å®šæˆæ‚¨å–œæ„›çš„外觀", diff --git a/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index dfce04ba61a..69d1bd41dad 100644 --- a/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -21,6 +21,5 @@ "welcomePage.extensionListSeparator": ",", "welcomePage.installedExtension": "{0}(已安è£)", "ok": "確定", - "cancel": "å–消", - "welcomePage.quickLinkBackground": "起始é é¢é€£çµçš„背景色彩." + "cancel": "å–消" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json b/i18n/cht/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json index 66d7f136aff..d1d07b14ebd 100644 --- a/i18n/cht/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json +++ b/i18n/cht/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json @@ -7,5 +7,10 @@ "open": "開啟設定", "close": "關閉", "errorUnknownKey": "無法寫入組態檔 (ä¸æ˜Žçš„按éµ)", - "errorInvalidTarget": "無法寫入組態檔 (目標無效)" + "errorInvalidTarget": "無法寫入組態檔 (目標無效)", + "errorNoWorkspaceOpened": "無法寫入設定,因為沒有開啟資料夾,請開啟資料夾後å†è©¦ä¸€æ¬¡.", + "errorInvalidConfiguration": "無法寫入設定.è«‹é–‹å•Ÿ**使用者設定**並修正錯誤/警告後å†è©¦ä¸€æ¬¡.", + "errorInvalidConfigurationWorkspace": "無法寫入設定.è«‹é–‹å•Ÿ**工作å€è¨­å®š**並修正檔案中的錯誤/警告後å†è©¦ä¸€æ¬¡.", + "errorConfigurationFileDirty": "無法寫入設定,因為檔案已變更.請儲存**使用者設定**後å†è©¦ä¸€æ¬¡", + "errorConfigurationFileDirtyWorkspace": "無法寫入設定,因檔案已變更.請儲存**工作å€è¨­å®š**後å†è©¦ä¸€æ¬¡." } \ No newline at end of file diff --git a/i18n/deu/extensions/git/out/commands.i18n.json b/i18n/deu/extensions/git/out/commands.i18n.json index 1a8943807b8..b3f20ad87c7 100644 --- a/i18n/deu/extensions/git/out/commands.i18n.json +++ b/i18n/deu/extensions/git/out/commands.i18n.json @@ -26,6 +26,9 @@ "provide commit message": "Geben Sie eine Commit-Nachrichte ein.", "branch name": "Branchname", "provide branch name": "Geben Sie einen Branchnamen an.", + "select branch to delete": "Wählen Sie einen Branch zum Löschen aus", + "confirm force delete branch": "Der Branch '{0}' ist noch nicht vollständig zusammengeführt. Trotzdem löschen?", + "delete branch": "Branch löschen", "no remotes to pull": "In Ihrem Repository wurden keine Remoteelemente für den Pull konfiguriert.", "no remotes to push": "In Ihrem Repository wurden keine Remoteelemente für den Push konfiguriert.", "nobranch": "Wählen Sie ein Branch für den Push zu einem Remoteelement aus.", diff --git a/i18n/deu/extensions/git/package.i18n.json b/i18n/deu/extensions/git/package.i18n.json index 26ab785ffbf..83830454714 100644 --- a/i18n/deu/extensions/git/package.i18n.json +++ b/i18n/deu/extensions/git/package.i18n.json @@ -26,6 +26,7 @@ "command.undoCommit": "Letzten Commit rückgängig machen", "command.checkout": "Auschecken an...", "command.branch": "Branch erstellen...", + "command.deleteBranch": "Branch löschen...", "command.pull": "Pull", "command.pullRebase": "Pull (Rebase)", "command.push": "Push", diff --git a/i18n/deu/extensions/jake/out/main.i18n.json b/i18n/deu/extensions/jake/out/main.i18n.json index 8b6ad71cd4e..83268c00071 100644 --- a/i18n/deu/extensions/jake/out/main.i18n.json +++ b/i18n/deu/extensions/jake/out/main.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "execFailed": "Fehler bei der automatischen Jake-Erkennung. Fehlermeldung: {0}" +} \ No newline at end of file diff --git a/i18n/deu/extensions/jake/package.i18n.json b/i18n/deu/extensions/jake/package.i18n.json index 8b6ad71cd4e..6ca3a5549dd 100644 --- a/i18n/deu/extensions/jake/package.i18n.json +++ b/i18n/deu/extensions/jake/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.jake.autoDetect": "Steuert, ob die automatische Erkennung von Jake-Tasks aktiviert oder deaktiviert ist. Standardmäßig ist die Funktion aktiviert." +} \ No newline at end of file diff --git a/i18n/deu/extensions/markdown/out/extension.i18n.json b/i18n/deu/extensions/markdown/out/extension.i18n.json index 8b6ad71cd4e..490139dcf55 100644 --- a/i18n/deu/extensions/markdown/out/extension.i18n.json +++ b/i18n/deu/extensions/markdown/out/extension.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "onPreviewStyleLoadError": "'markdown.styles' konnte nicht geladen werden: {0}" +} \ No newline at end of file diff --git a/i18n/deu/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/deu/extensions/merge-conflict/out/commandHandler.i18n.json index 8b6ad71cd4e..f18cf168246 100644 --- a/i18n/deu/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/deu/extensions/merge-conflict/out/commandHandler.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "noConflicts": "Keine Merge-Konflikte in dieser Datei gefunden", + "noOtherConflictsInThisFile": "Keine weiteren Merge-Konflikte in dieser Datei" +} \ No newline at end of file diff --git a/i18n/deu/extensions/merge-conflict/package.i18n.json b/i18n/deu/extensions/merge-conflict/package.i18n.json index 8b6ad71cd4e..0875e460a99 100644 --- a/i18n/deu/extensions/merge-conflict/package.i18n.json +++ b/i18n/deu/extensions/merge-conflict/package.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "command.category": "Merge-Konflikt", + "command.accept.both": "Beides akzeptieren", + "config.title": "Merge-Konflikt" +} \ No newline at end of file diff --git a/i18n/deu/extensions/npm/package.i18n.json b/i18n/deu/extensions/npm/package.i18n.json index 8b6ad71cd4e..df3491b4c05 100644 --- a/i18n/deu/extensions/npm/package.i18n.json +++ b/i18n/deu/extensions/npm/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.npm.autoDetect": "Steuert, ob die automatische Erkennung von NPM-Skripts aktiviert oder deaktiviert ist. Standardmäßig ist die Funktion aktiviert." +} \ No newline at end of file diff --git a/i18n/deu/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/deu/extensions/typescript/out/utils/typingsStatus.i18n.json index abc0ee901f8..6d936266697 100644 --- a/i18n/deu/extensions/typescript/out/utils/typingsStatus.i18n.json +++ b/i18n/deu/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -5,7 +5,6 @@ // Do not edit this file. It is machine generated. { "installingPackages": "Daten werden zum Optimieren von TypeScript IntelliSense abgerufen", - "typesInstallerInitializationFailed.title": "Typisierungsdateien für JavaScript-Sprachfunktionen konnten nicht installiert werden. Stellen Sie sicher, das NPM installiert ist und sich in Ihrem PFAD befindet.", "typesInstallerInitializationFailed.moreInformation": "Weitere Informationen", "typesInstallerInitializationFailed.doNotCheckAgain": "Nicht erneut überprüfen", "typesInstallerInitializationFailed.close": "Schließen" diff --git a/i18n/deu/extensions/typescript/package.i18n.json b/i18n/deu/extensions/typescript/package.i18n.json index d48740fd4d3..451b77c6fa5 100644 --- a/i18n/deu/extensions/typescript/package.i18n.json +++ b/i18n/deu/extensions/typescript/package.i18n.json @@ -34,8 +34,9 @@ "typescript.goToProjectConfig.title": "Zur Projektkonfiguration wechseln", "javascript.goToProjectConfig.title": "Zur Projektkonfiguration wechseln", "typescript.implementationsCodeLens.enabled": "Aktiviert oder deaktiviert CodeLens-Implementierungen. Erfordert TypeScript 2.2.0 oder höher.", + "typescript.openTsServerLog.title": "TS Server-Protokolldatei öffnen", + "typescript.restartTsServer": "TS Server neu starten", "typescript.selectTypeScriptVersion.title": "TypeScript-Version wählen", "jsDocCompletion.enabled": "Automatische JSDoc-Kommentare aktivieren/deaktivieren", - "javascript.implicitProjectConfig.checkJs": "Aktiviert/deaktiviert die Semantikprüfung bei JavaScript-Dateien. Diese Einstellung wird von vorhandenen \"jsconfig.json\"- oder \"tsconfig.json\"-Dateien außer Kraft gesetzt. Erfordert TypeScript 2.3.1 oder höher.", - "typescript.check.npmIsInstalled": "Ãœberprüfen, ob NPM für automatische Typerfassung installiert ist" + "javascript.implicitProjectConfig.checkJs": "Aktiviert/deaktiviert die Semantikprüfung bei JavaScript-Dateien. Diese Einstellung wird von vorhandenen \"jsconfig.json\"- oder \"tsconfig.json\"-Dateien außer Kraft gesetzt. Erfordert TypeScript 2.3.1 oder höher." } \ No newline at end of file diff --git a/i18n/deu/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/deu/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index 24c2e906e90..9b3e7fa3e6e 100644 --- a/i18n/deu/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/deu/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,6 +6,7 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "Das Bild ist zu groß für den Editor. ", + "resourceOpenExternalButton": "Bild mit externem Programm öffnen?", "nativeBinaryError": "Die Datei wird nicht im Editor angezeigt, weil sie binär oder sehr groß ist oder eine nicht unterstützte Textcodierung verwendet.", "sizeB": "{0} B", "sizeKB": "{0} KB", diff --git a/i18n/deu/src/vs/code/electron-main/menus.i18n.json b/i18n/deu/src/vs/code/electron-main/menus.i18n.json index 2a26af07f79..739090b7521 100644 --- a/i18n/deu/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/deu/src/vs/code/electron-main/menus.i18n.json @@ -14,6 +14,7 @@ "mHelp": "&&Hilfe", "miNewWindow": "Neues &&Fenster", "mAbout": "Informationen zu {0}", + "mServices": "Dienste", "mHide": "{0} ausblenden", "mHideOthers": "Andere ausblenden", "mShowAll": "Alle anzeigen", @@ -148,12 +149,12 @@ "miLicense": "&&Lizenz anzeigen", "miPrivacyStatement": "&&Datenschutzerklärung", "miAbout": "&&Info", + "accessibilityOptionsWindowTitle": "Optionen für erleichterte Bedienung", "miRestartToUpdate": "Für Update neu starten...", "miCheckingForUpdates": "Ãœberprüfen auf Updates...", "miDownloadUpdate": "Verfügbares Update herunterladen", "miDownloadingUpdate": "Das Update wird heruntergeladen...", "miInstallingUpdate": "Update wird installiert...", - "miCheckForUpdates": "Auf Updates überprüfen...", "aboutDetail": "\nVersion {0}\nCommit {1}\nDatum {2}\nShell {3}\nRenderer {4}\nNode {5}", "okButton": "OK" } \ No newline at end of file diff --git a/i18n/deu/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/deu/src/vs/editor/common/config/commonEditorConfig.i18n.json index a01ec274ece..15fd087f170 100644 --- a/i18n/deu/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/deu/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -9,6 +9,7 @@ "fontWeight": "Steuert die Schriftbreite.", "fontSize": "Steuert den Schriftgrad in Pixeln.", "lineHeight": "Steuert die Zeilenhöhe. Verwenden Sie 0, um LineHeight aus der FontSize-Angabe zu berechnen.", + "letterSpacing": "Steuert den Zeichenabstand in Pixeln.", "lineNumbers": "Steuert die Anzeige von Zeilennummern. Mögliche Werte sind \"Ein\", \"Aus\" und \"Relativ\". \"Relativ\" zeigt die Zeilenanzahl ab der aktuellen Cursorposition.", "rulers": "Spalten, an denen vertikale Lineale angezeigt werden sollen", "wordSeparators": "Zeichen, die als Worttrennzeichen verwendet werden, wenn wortbezogene Navigationen oder Vorgänge ausgeführt werden.", diff --git a/i18n/deu/src/vs/editor/contrib/links/browser/links.i18n.json b/i18n/deu/src/vs/editor/contrib/links/browser/links.i18n.json index 84459913349..3c582ab348d 100644 --- a/i18n/deu/src/vs/editor/contrib/links/browser/links.i18n.json +++ b/i18n/deu/src/vs/editor/contrib/links/browser/links.i18n.json @@ -6,6 +6,7 @@ { "links.navigate.mac": "BEFEHLSTASTE + Mausklick zum Aufrufen des Links", "links.navigate": "STRG + Mausklick zum Aufrufen des Links", + "links.navigate.al": "ALT + Mausklick zum Aufrufen des Links", "invalid.url": "Fehler beim Öffnen dieses Links, weil er nicht wohlgeformt ist: {0}", "missing.url": "Fehler beim Öffnen dieses Links, weil das Ziel fehlt.", "label": "Link öffnen" diff --git a/i18n/deu/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json b/i18n/deu/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json index 73686f1e295..df507c729f9 100644 --- a/i18n/deu/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json +++ b/i18n/deu/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json @@ -12,6 +12,7 @@ "readMore": "Mehr anzeigen...{0}", "suggestionWithDetailsAriaLabel": "{0}, Vorschlag, hat Details", "suggestionAriaLabel": "{0}, Vorschlag", + "readLess": "Weniger anzeigen...{0}", "suggestWidget.loading": "Wird geladen...", "suggestWidget.noSuggestions": "Keine Vorschläge.", "suggestionAriaAccepted": "{0}, angenommen", diff --git a/i18n/deu/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/deu/src/vs/workbench/api/node/extHostTask.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/deu/src/vs/workbench/api/node/extHostTask.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/api/node/extHostTreeViews.i18n.json b/i18n/deu/src/vs/workbench/api/node/extHostTreeViews.i18n.json index 8b6ad71cd4e..83810e505c9 100644 --- a/i18n/deu/src/vs/workbench/api/node/extHostTreeViews.i18n.json +++ b/i18n/deu/src/vs/workbench/api/node/extHostTreeViews.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "treeItem.notFound": "Kein Tree-Eintrag mit der id '{0}' gefunden.", + "treeView.duplicateElement": "Element {0} ist bereit registriert." +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/common/theme.i18n.json b/i18n/deu/src/vs/workbench/common/theme.i18n.json index 825c4c4c377..52d4cbaf357 100644 --- a/i18n/deu/src/vs/workbench/common/theme.i18n.json +++ b/i18n/deu/src/vs/workbench/common/theme.i18n.json @@ -7,12 +7,9 @@ "tabActiveBackground": "Hintergrundfarbe der aktiven Registerkarte. Registerkarten sind die Container für Editors im Editorbereich. In einer Editorgruppe können mehrere Registerkarten geöffnet werden. Mehrere Editorgruppen können vorhanden sein.", "tabInactiveBackground": "Hintergrundfarbe der inaktiven Registerkarte. Registerkarten sind die Container für Editors im Editorbereich. In einer Editorgruppe können mehrere Registerkarten geöffnet werden. Mehrere Editorgruppen können vorhanden sein.", "tabBorder": "Rahmen zum Trennen von Registerkarten. Registerkarten sind die Container für Editoren im Editor-Bereich. In einer Editor-Gruppe können mehrere Registerkarten geöffnet werden. Mehrere Editor-Gruppen sind möglich.", - "tabActiveEditorGroupActiveForeground": "Vordergrundfarbe der aktiven Registerkarte in einer aktiven Gruppe. Registerkarten sind die Container für Editors im Editorbereich. In einer Editorgruppe können mehrere Registerkarten geöffnet werden. Mehrere Editorgruppen können vorhanden sein.", - "tabInactiveEditorGroupActiveForeground": "Vordergrundfarbe der inaktiven Registerkarte in einer aktiven Gruppe. Registerkarten sind die Container für Editors im Editorbereich. In einer Editorgruppe können mehrere Registerkarten geöffnet werden. Mehrere Editorgruppen können vorhanden sein.", "editorGroupBackground": "Hintergrundfarbe einer Editor-Gruppe. Editor-Gruppen sind die Container der Editoren. Die Hintergrundfarbe wird beim Ziehen von Editoren angezeigt.", "editorGroupHeaderBackground": "Hintergrundfarbe der Titelüberschrift des Editors, wenn die Registerkarten deaktiviert sind. Editor-Gruppen sind die Container der Editoren.", "editorGroupBorder": "Farbe zum Trennen mehrerer Editor-Gruppen. Editor-Gruppen sind die Container der Editoren.", - "panelBackground": "Hintergrundfarbe des Panels. Panels werden unter dem Editorbereich angezeigt und enthalten Ansichten wie die Ausgabe und das integrierte Terminal.", "panelBorder": "Farbe des oberen Panelrahmens, der das Panel vom Editor abtrennt. Panels werden unter dem Editorbereich angezeigt und enthalten Ansichten wie die Ausgabe und das integrierten Terminal.", "panelActiveTitleForeground": "Titelfarbe für den aktiven Bereich. Bereiche werden unter dem Editorbereich angezeigt und enthalten Ansichten wie Ausgabe und integriertes Terminal.", "panelInactiveTitleForeground": "Titelfarbe für den inaktiven Bereich. Bereiche werden unter dem Editorbereich angezeigt und enthalten Ansichten wie Ausgabe und integriertes Terminal.", diff --git a/i18n/deu/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/deu/src/vs/workbench/electron-browser/workbench.i18n.json index 8b6ad71cd4e..db7c9434c92 100644 --- a/i18n/deu/src/vs/workbench/electron-browser/workbench.i18n.json +++ b/i18n/deu/src/vs/workbench/electron-browser/workbench.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "developer": "Entwickler", + "file": "Datei" +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json b/i18n/deu/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json index 68430d77560..7c044c0e580 100644 --- a/i18n/deu/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json @@ -5,8 +5,8 @@ // Do not edit this file. It is machine generated. { "snapshotObj": "Nur primitive Werte werden für dieses Objekt angezeigt.", - "debuggingStarted": "Das Debuggen wurde gestartet.", "debuggingPaused": "Das Debuggen wurde angehalten. Ursache {0}, {1}{2}", + "debuggingStarted": "Das Debuggen wurde gestartet.", "debuggingStopped": "Das Debuggen wurde beendet.", "breakpointAdded": "Der Haltepunkt wurde hinzugefügt. Zeile {0}, Datei \"{1}\".", "breakpointRemoved": "Der Haltepunkt wurde entfernt. Zeile {0}, Datei \"{1}\".", diff --git a/i18n/deu/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json b/i18n/deu/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json index 77b8513319c..bef42d1efed 100644 --- a/i18n/deu/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json @@ -6,5 +6,6 @@ { "copyValue": "Wert kopieren", "copy": "Kopieren", + "copyAll": "Alles kopieren", "copyStackTrace": "Aufrufliste kopieren" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/deu/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index 687359bd486..b7e6e189740 100644 --- a/i18n/deu/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -9,5 +9,6 @@ "prof.message": "Profile wurden erfolgreich erstellt.", "prof.detail": "Erstellen Sie ein Problem, und fügen Sie die folgenden Dateien manuell an:\n{0}", "prof.restartAndFileIssue": "Problem erstellen und neu starten", - "prof.restart": "Neu starten" + "prof.restart": "Neu starten", + "prof.thanks": "Danke für Ihre Hilfe." } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/deu/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json index 9a66f7f69c7..17617151e91 100644 --- a/i18n/deu/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -5,6 +5,5 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.start": "Tastenbindung definieren", - "defineKeybinding.kbLayoutInfoMessage": "Drücken Sie für Ihr aktuelles Tastaturlayout ", "defineKeybinding.kbLayoutErrorMessage": "Sie können diese Tastenkombination mit Ihrem aktuellen Tastaturlayout nicht generieren." } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json b/i18n/deu/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json index 9d86b8f7244..37e4e489362 100644 --- a/i18n/deu/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "showTriggerActions": "Alle Befehle anzeigen", + "showCommands.label": "Befehlspalette...", "entryAriaLabelWithKey": "{0}, {1}, Befehle", "entryAriaLabel": "{0}, Befehle", "canNotRun": "Der Befehl '{0}' kann nicht an dieser Stelle ausgeführt werden.", diff --git a/i18n/deu/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/deu/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json index a72e1281b77..bf5de1662ad 100644 --- a/i18n/deu/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -5,13 +5,12 @@ // Do not edit this file. It is machine generated. { "ConfigurationParser.invalidCWD": "Warnung: \"options.cwd\" muss vom Typ \"string\" sein. Der Wert {0} wird ignoriert.\n", - "ConfigurationParser.noShell": "Warnung: Die Shell-Konfiguration wird nur beim Ausführen von Tasks im Terminal unterstützt.", "ConfigurationParser.noargs": "Fehler: Befehlsargumente müssen ein Array aus Zeichenfolgen sein. Angegebener Wert:\n{0}", + "ConfigurationParser.noShell": "Warnung: Die Shell-Konfiguration wird nur beim Ausführen von Tasks im Terminal unterstützt.", "ConfigurationParser.noName": "Fehler: Der Problemabgleich im Deklarationsbereich muss einen Namen besitzen:\n{0}\n", "ConfigurationParser.unknownMatcherKind": "Warnung: Der definierte Problemabgleich ist unbekannt. Die folgenden Typen werden unterstützt: string | ProblemMatcher | (string | ProblemMatcher)[].\n{0}\n", "ConfigurationParser.invalidVaraibleReference": "Fehler: Ungültiger ProblemMatcher-Verweis: {0}\n", "ConfigurationParser.noTaskName": "Fehler: Tasks müssen eine Eigenschaft \"TaskName\" angeben. Der Task wird ignoriert.\n{0}\n", "taskConfiguration.shellArgs": "Warnung: Die Aufgabe \"{0}\" ist ein Shellbefehl, und der Befehlsname oder eines seiner Argumente enthält Leerzeichen ohne Escapezeichen. Führen Sie Argumente im Befehl zusammen, um eine korrekte Angabe der Befehlszeile sicherzustellen.", - "taskConfiguration.noCommandOrDependsOn": "Fehler: Aufgabe \"{0}\" definiert keinen Befehl bzw. keine depondsOn-Eigenschaft. Die Aufgabe wird ignoriert. Die Definition lautet:\n{1}", "taskConfiguration.noCommand": "Fehler: Aufgabe \"{0}\" definiert keinen Befehl. Die Aufgabe wird ignoriert. Die Definition lautet:\n{1}" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json index e52c61e82c7..1363d395b95 100644 --- a/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -4,11 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "JsonSchema.version": "Die Versionsnummer der Konfiguration.", - "JsonSchema.windows": "Windows-spezifische Befehlskonfiguration", - "JsonSchema.mac": "Mac-spezifische Befehlskonfiguration", - "JsonSchema.linux": "Linux-spezifische Befehlskonfiguration", "JsonSchema.shell": "Gibt an, ob der Befehl ein Shellbefehl oder ein externes Programm ist. Wenn keine Angabe erfolgt, ist der Standardwert \"false\".", "JsonSchema.tasks.dependsOn.string": "Eine weitere Aufgabe, von der diese Aufgabe abhängt.", - "JsonSchema.tasks.dependsOn.array": "Die anderen Aufgaben, von denen diese Aufgabe abhängt." + "JsonSchema.tasks.dependsOn.array": "Die anderen Aufgaben, von denen diese Aufgabe abhängt.", + "JsonSchema.windows": "Windows-spezifische Befehlskonfiguration", + "JsonSchema.mac": "Mac-spezifische Befehlskonfiguration", + "JsonSchema.linux": "Linux-spezifische Befehlskonfiguration" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json index b167d91d677..57931ea4bd6 100644 --- a/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -11,6 +11,7 @@ "welcomePage.openFolder": "Ordner öffnen...", "welcomePage.cloneGitRepository": "Git-Repository klonen...", "welcomePage.recent": "Zuletzt verwendet", + "welcomePage.moreRecent": "Weitere Informationen...", "welcomePage.noRecentFolders": "Keine kürzlich verwendeten Ordner", "welcomePage.help": "Hilfe", "welcomePage.introductoryVideos": "Einführungsvideos", @@ -19,10 +20,12 @@ "welcomePage.stackOverflow": "Stack Overflow", "welcomePage.showOnStartup": "Willkommensseite beim Start anzeigen", "welcomePage.customize": "Anpassen", + "welcomePage.moreExtensions": "mehr", "welcomePage.installKeymapDescription": "Tastenkombinationen installieren", "welcomePage.others": "Andere", "welcomePage.colorTheme": "Farbdesign", "welcomePage.colorThemeDescription": "Passen Sie das Aussehen des Editors und Ihres Codes an Ihre Wünsche an.", + "welcomePage.learn": "Lernen", "welcomePage.showCommands": "Alle Befehle suchen und ausführen", "welcomePage.showCommandsDescription": "Ãœber die Einstellungen ({0}) können Sie Befehle schnell suchen und darauf zugreifen.", "welcomePage.interfaceOverview": "Ãœberblick über die Schnittstelle", diff --git a/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 5693a1f5b13..a6f6f26a54a 100644 --- a/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -5,11 +5,15 @@ // Do not edit this file. It is machine generated. { "welcomePage": "Willkommen", + "welcomePage.javaScript": "JavaScript", "welcomePage.typeScript": "TypeScript", + "welcomePage.python": "Python", "welcomePage.php": "PHP", + "welcomePage.docker": "Docker", "welcomePage.vim": "Vim", "welcomePage.sublime": "Sublime", "welcomePage.atom": "Atom", + "welcomePage.extensionPackAlreadyInstalled": "Unterstützung für {0} ist bereits installiert.", "welcomePage.keymapAlreadyInstalled": "Die {0} Tastenkombinationen sind bereits installiert.", "welcomePage.willReloadAfterInstallingKeymap": "Das Fenster wird nach der Installation der {0}-Tastaturbefehle neu geladen.", "welcomePage.installingKeymap": "Die {0}-Tastenkombinationen werden installiert...", diff --git a/i18n/esn/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/esn/extensions/merge-conflict/out/codelensProvider.i18n.json index 22ca13053b5..8b6ad71cd4e 100644 --- a/i18n/esn/extensions/merge-conflict/out/codelensProvider.i18n.json +++ b/i18n/esn/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -3,9 +3,4 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{ - "acceptCurrentChange": "Aceptar cambio actual", - "acceptIncomingChange": "Aceptar cambio entrante", - "acceptBothChanges": "Aceptar ambos cambios", - "compareChanges": "Comparar cambios" -} \ No newline at end of file +{} \ No newline at end of file diff --git a/i18n/esn/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/esn/extensions/merge-conflict/out/commandHandler.i18n.json index eb8028b1717..c3d2c17c302 100644 --- a/i18n/esn/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/esn/extensions/merge-conflict/out/commandHandler.i18n.json @@ -5,7 +5,6 @@ // Do not edit this file. It is machine generated. { "cursorNotInConflict": "El cursor de edición no se encuentra en un conflicto de fusión", - "compareChangesTitle": "{0}: Cambios actuales \\u2194 Cambios entrantes", "cursorOnSplitterRange": "El cursor del editor está dentro del separador de conflictos de fusión, muévalo al bloque \"actual\" o al \"entrante\" ", "noConflicts": "No se encontraron conflictos en este archivo", "noOtherConflictsInThisFile": "No hay más conflictos en este archivo" diff --git a/i18n/esn/extensions/merge-conflict/package.i18n.json b/i18n/esn/extensions/merge-conflict/package.i18n.json index 880711d45ac..97bdb649962 100644 --- a/i18n/esn/extensions/merge-conflict/package.i18n.json +++ b/i18n/esn/extensions/merge-conflict/package.i18n.json @@ -5,15 +5,7 @@ // Do not edit this file. It is machine generated. { "command.category": "Fusionar conflicto", - "command.accept.all-incoming": "Aceptar todos los entrantes", - "command.accept.all-both": "Aceptar todos ambos", - "command.accept.current": "Aceptar actual", - "command.accept.incoming": "Aceptar entrante", - "command.accept.selection": "Aceptar selección", "command.accept.both": "Aceptar ambos", - "command.next": "Siguiente conflicto", - "command.previous": "Conflicto anterior", - "command.compare": "Comparar conflicto actual", "config.title": "Fusionar conflicto", "config.codeLensEnabled": "Habilitar/deshabilitar CodeLens de fusionar bloque de conflictos en el editor", "config.decoratorsEnabled": "Habilitar/deshabilitar decoradores de conflictos de fusión en el editor" diff --git a/i18n/esn/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/esn/extensions/typescript/out/utils/typingsStatus.i18n.json index f522401a83d..0d39c772a73 100644 --- a/i18n/esn/extensions/typescript/out/utils/typingsStatus.i18n.json +++ b/i18n/esn/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -5,7 +5,6 @@ // Do not edit this file. It is machine generated. { "installingPackages": "Recuperando cambios en los datos para un mejor rendimiento de TypeScript IntelliSense", - "typesInstallerInitializationFailed.title": "No se pudieron instalar los archivos de lenguaje para las características de lenguaje JavaScript. Asegúrese que NPM está instalado y en su ruta de acceso", "typesInstallerInitializationFailed.moreInformation": "Más información", "typesInstallerInitializationFailed.doNotCheckAgain": "No volver a comprobar", "typesInstallerInitializationFailed.close": "Cerrar" diff --git a/i18n/esn/extensions/typescript/package.i18n.json b/i18n/esn/extensions/typescript/package.i18n.json index 4ff6892a0a6..3de04eb5b4a 100644 --- a/i18n/esn/extensions/typescript/package.i18n.json +++ b/i18n/esn/extensions/typescript/package.i18n.json @@ -41,6 +41,5 @@ "typescript.selectTypeScriptVersion.title": "Seleccionar versión de TypeScript", "jsDocCompletion.enabled": "Habilita o deshabilita comentarios automaticos de JSDoc", "javascript.implicitProjectConfig.checkJs": "Habilita/deshabilita la comprobación semántica de los archivos JavaScript. Los archivos jsconfig.json o tsconfig.json reemplazan esta configuración. Se requiere TypeScript >=2.3.1.", - "typescript.check.npmIsInstalled": "Comprueba si NPM esta instalado para recibir adquisiciones automaticas de Typings", "javascript.nameSuggestions": "Habilitar/deshabilitar nombres únicos de la lista de sugerencias en los archivos de JavaScript. " } \ No newline at end of file diff --git a/i18n/esn/src/vs/code/electron-main/menus.i18n.json b/i18n/esn/src/vs/code/electron-main/menus.i18n.json index 44ff7a3f5f1..4b1468558ad 100644 --- a/i18n/esn/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/esn/src/vs/code/electron-main/menus.i18n.json @@ -153,12 +153,12 @@ "miLicense": "Ver &&licencia", "miPrivacyStatement": "&&Declaración de privacidad", "miAbout": "&&Acerca de", + "accessibilityOptionsWindowTitle": "Opciones de accesibilidad", "miRestartToUpdate": "Reiniciar para actualizar...", "miCheckingForUpdates": "Buscando actualizaciones...", "miDownloadUpdate": "Descargar actualización disponible", "miDownloadingUpdate": "Descargando actualización...", "miInstallingUpdate": "Instalando actualización...", - "miCheckForUpdates": "Buscar actualizaciones...", "aboutDetail": "\nVersión {0}\nConfirmación {1}\nFecha {2}\nShell {3}\nRepresentador {4}\nNode {5}", "okButton": "Aceptar" } \ No newline at end of file diff --git a/i18n/esn/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/esn/src/vs/platform/theme/common/colorRegistry.i18n.json index 889a845a813..c20c4e2b34f 100644 --- a/i18n/esn/src/vs/platform/theme/common/colorRegistry.i18n.json +++ b/i18n/esn/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -60,7 +60,6 @@ "editorBackground": "Color de fondo del editor.", "editorForeground": "Color de primer plano predeterminado del editor.", "editorWidgetBackground": "Color de fondo del editor de widgets como buscar/reemplazar", - "editorWidgetBorder": "Color de borde del editor de widget.", "editorSelection": "Color de la selección del editor.", "editorInactiveSelection": "Color de la selección en un editor inactivo.", "editorSelectionHighlight": "Color de las regiones con el mismo contenido que la selección.", diff --git a/i18n/esn/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/esn/src/vs/workbench/api/node/extHostTask.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/esn/src/vs/workbench/api/node/extHostTask.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/common/theme.i18n.json b/i18n/esn/src/vs/workbench/common/theme.i18n.json index 40dfe03ebb6..9ae35bba944 100644 --- a/i18n/esn/src/vs/workbench/common/theme.i18n.json +++ b/i18n/esn/src/vs/workbench/common/theme.i18n.json @@ -7,14 +7,11 @@ "tabActiveBackground": "Color de fondo de la pestaña activa. Las pestañas son los contenedores de los editores en el área de editores. Se pueden abrir varias pestañas en un grupo de editores. Puede haber varios grupos de editores.", "tabInactiveBackground": "Color de fondo de la pestaña inactiva. Las pestañas son los contenedores de los editores en el área de editores. Se pueden abrir varias pestañas en un grupo de editores. Puede haber varios grupos de editores.", "tabBorder": "Borde para separar las pestañas entre sí. Las pestañas son contenedores de editores en el área de editores. Se pueden abrir varias pestañas en un grupo de editores. Puede haber varios grupos de editores.", - "tabActiveEditorGroupActiveForeground": "Color de primer plano de la pestaña activa en un grupo activo. Las pestañas son los contenedores de los editores en el área de editores. Se pueden abrir varias pestañas en un grupo de editores. Puede haber varios grupos de editores.", - "tabInactiveEditorGroupActiveForeground": "Color de primer plano de la pestaña inactiva en un grupo activo. Las pestañas son los contenedores de los editores en el área de editores. Se pueden abrir varias pestañas en un grupo de editores. Puede haber varios grupos de editores.", "editorGroupBackground": "Color de fondo de un grupo de editores. Los grupos de editores son los contenedores de los editores. El color de fondo se ve cuando se mueven arrastrando los grupos de editores.", "tabsContainerBackground": "Color de fondo del encabezado del título del grupo de editores cuando las fichas están habilitadas. Los grupos de editores son contenedores de editores.", "editorGroupHeaderBackground": "Color de fondo del encabezado del título del grupo de editores cuando las fichas están deshabilitadas. Los grupos de editores son contenedores de editores.", "editorGroupBorder": "Color para separar varios grupos de editores entre sí. Los grupos de editores son los contenedores de los editores.", "editorDragAndDropBackground": "Color de fondo cuando se arrastran los editores. El color debería tener transparencia para que el contenido del editor pueda brillar a su través.", - "panelBackground": "Color de fondo del panel. Los paneles se muestran debajo del área de editores y contienen vistas, como Salida y Terminal integrado.", "panelBorder": "Color del borde superior del panel que lo separa del editor. Los paneles se muestran debajo del área de editores y contienen vistas, como Salida y Terminal integrado.", "panelActiveTitleForeground": "Color del título del panel activo. Los paneles se muestran debajo del área del editor y contienen vistas como Salida y Terminal integrado.", "panelInactiveTitleForeground": "Color del título del panel inactivo. Los paneles se muestran debajo del área del editor y contienen vistas como Salida y Terminal integrado.", diff --git a/i18n/esn/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/esn/src/vs/workbench/electron-browser/workbench.i18n.json index 8b6ad71cd4e..24a3d974637 100644 --- a/i18n/esn/src/vs/workbench/electron-browser/workbench.i18n.json +++ b/i18n/esn/src/vs/workbench/electron-browser/workbench.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "developer": "Desarrollador", + "file": "Archivo" +} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json b/i18n/esn/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json index 96a50f5d740..ce2f816c868 100644 --- a/i18n/esn/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json @@ -5,8 +5,8 @@ // Do not edit this file. It is machine generated. { "snapshotObj": "Solo se muestran valores primitivos para este objeto.", - "debuggingStarted": "La depuración se ha iniciado.", "debuggingPaused": "La depuración se ha pausado. Motivo: {0}, {1} {2}", + "debuggingStarted": "La depuración se ha iniciado.", "debuggingStopped": "La depuración se ha detenido.", "breakpointAdded": "Punto de interrupción agregado, línea {0}, archivo {1}", "breakpointRemoved": "Punto de interrupción quitado, línea {0}, archivo {1}", diff --git a/i18n/esn/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/esn/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json index cb715f51220..6c042c0daff 100644 --- a/i18n/esn/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -5,6 +5,5 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.start": "Definir enlace de teclado", - "defineKeybinding.kbLayoutInfoMessage": "Para la distribución del teclado actual, presione ", "defineKeybinding.kbLayoutErrorMessage": "La distribución del teclado actual no permite reproducir esta combinación de teclas." } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/esn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index 30e2262eef7..e5995f59713 100644 --- a/i18n/esn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,7 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0}, tareas", - "workspace": "De área de trabajo", - "extension": "De extensiones" + "entryAriaLabel": "{0}, tareas" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/esn/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json index 14c75ef21d9..2cc7fa59535 100644 --- a/i18n/esn/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -5,13 +5,12 @@ // Do not edit this file. It is machine generated. { "ConfigurationParser.invalidCWD": "Advertencia: options.cwd debe ser de tipo cadena. Se ignora el valor {0}.", - "ConfigurationParser.noShell": "Advertencia: La configuración del shell solo se admite al ejecutar tareas en el terminal.", "ConfigurationParser.noargs": "Error: Los argumentos de comando deben ser una matriz de cadenas. El valor proporcionado es: {0}", + "ConfigurationParser.noShell": "Advertencia: La configuración del shell solo se admite al ejecutar tareas en el terminal.", "ConfigurationParser.noName": "Error: El buscador de coincidencias de problemas del ámbito de declaración debe tener un nombre: {0}", "ConfigurationParser.unknownMatcherKind": "Advertencia: El buscador de coincidencias de problemas definido se desconoce. Los tipos admitidos son string | ProblemMatcher | (string | ProblemMatcher). {0}", "ConfigurationParser.invalidVaraibleReference": "Error: Referencia a problemMatcher no válida: {0}", "ConfigurationParser.noTaskName": "Error: Las tareas deben proporcionar una propiedad taskName. La tarea se ignorará. {0}", "taskConfiguration.shellArgs": "Advertencia: La tarea \"{0}\" es un comando de shell y su nombre de comando o uno de sus argumentos tiene espacios sin escape. Para asegurarse de que la línea de comandos se cite correctamente, combine mediante fusión los argumentos en el comando.", - "taskConfiguration.noCommandOrDependsOn": "Error: La tarea \"{0}\" no especifica un comando ni una propiedad dependsOn. La tarea se ignorará. Su definición es: {1}", "taskConfiguration.noCommand": "Error: La tarea \"{0}\" no define un comando. La tarea se ignorará. Su definición es: {1}" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json index 35f7a06e8d6..a568620f9fe 100644 --- a/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -4,11 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "JsonSchema.version": "Número de versión de la configuración", - "JsonSchema.windows": "Configuración de comando específico de Windows", - "JsonSchema.mac": "Configuración de comando específico de Mac", - "JsonSchema.linux": "Configuración de comando específico de Linux", "JsonSchema.shell": "Especifica si el comando es un comando shell o un programa externo. Si se omite, el valor predeterminado es false.", "JsonSchema.tasks.dependsOn.string": "Otra tarea de la que depende esta tarea.", - "JsonSchema.tasks.dependsOn.array": "Las otras tareas de las que depende esta tarea." + "JsonSchema.tasks.dependsOn.array": "Las otras tareas de las que depende esta tarea.", + "JsonSchema.windows": "Configuración de comando específico de Windows", + "JsonSchema.mac": "Configuración de comando específico de Mac", + "JsonSchema.linux": "Configuración de comando específico de Linux" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 57b34bdf736..0ada1a16443 100644 --- a/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -25,7 +25,5 @@ "welcomePage.extensionListSeparator": ", ", "welcomePage.installedExtension": "{0} (instalado)", "ok": "Aceptar", - "cancel": "Cancelar", - "welcomePage.quickLinkBackground": "Color de fondo de los vínculos rápidos en la página principal.", - "welcomePage.quickLinkHoverBackground": "Mantener el puntero sobre el color de fondo para acceder los vínculos rápidos en la página principal." + "cancel": "Cancelar" } \ No newline at end of file diff --git a/i18n/fra/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/fra/extensions/typescript/out/utils/typingsStatus.i18n.json index d9cc787276c..0b61796218c 100644 --- a/i18n/fra/extensions/typescript/out/utils/typingsStatus.i18n.json +++ b/i18n/fra/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -5,7 +5,6 @@ // Do not edit this file. It is machine generated. { "installingPackages": "Récupération (fetch) des données pour l'amélioration de TypeScript IntelliSense", - "typesInstallerInitializationFailed.title": "Impossible d'installer des fichiers de typages pour les fonctionnalités du langage JavaScript. Vérifiez que NPM est installé et se trouve dans votre chemin", "typesInstallerInitializationFailed.moreInformation": "Informations", "typesInstallerInitializationFailed.doNotCheckAgain": "Ne plus vérifier", "typesInstallerInitializationFailed.close": "Fermer" diff --git a/i18n/fra/extensions/typescript/package.i18n.json b/i18n/fra/extensions/typescript/package.i18n.json index d60399d9b5b..d672a75d013 100644 --- a/i18n/fra/extensions/typescript/package.i18n.json +++ b/i18n/fra/extensions/typescript/package.i18n.json @@ -36,6 +36,5 @@ "typescript.implementationsCodeLens.enabled": "Activer/désactiver CodeLens dans les implémentations. Nécessite TypeScript >= 2.2.0.", "typescript.selectTypeScriptVersion.title": "Sélectionner la version de TypeScript", "jsDocCompletion.enabled": "Activer/désactiver les commentaires JSDoc automatiques", - "javascript.implicitProjectConfig.checkJs": "Activer/désactiver la vérification sémantique des fichiers JavaScript. Les fichiers jsconfig.json ou tsconfig.json existants remplacent ce paramètre. Nécessite TypeScript >=2.3.1.", - "typescript.check.npmIsInstalled": "Vérifie si NPM est installé pour l'acquisition automatique des typages" + "javascript.implicitProjectConfig.checkJs": "Activer/désactiver la vérification sémantique des fichiers JavaScript. Les fichiers jsconfig.json ou tsconfig.json existants remplacent ce paramètre. Nécessite TypeScript >=2.3.1." } \ No newline at end of file diff --git a/i18n/fra/src/vs/code/electron-main/menus.i18n.json b/i18n/fra/src/vs/code/electron-main/menus.i18n.json index 767d8088cca..770b210d764 100644 --- a/i18n/fra/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/fra/src/vs/code/electron-main/menus.i18n.json @@ -148,12 +148,12 @@ "miLicense": "Affic&&her la licence", "miPrivacyStatement": "Déc&&laration de confidentialité", "miAbout": "À pr&&opos de", + "accessibilityOptionsWindowTitle": "Options d'accessibilité", "miRestartToUpdate": "Redémarrer pour mettre à jour...", "miCheckingForUpdates": "Recherche des mises à jour...", "miDownloadUpdate": "Télécharger la mise à jour disponible", "miDownloadingUpdate": "Téléchargement de la mise à jour...", "miInstallingUpdate": "Installation de la mise à jour...", - "miCheckForUpdates": "Rechercher les mises à jour...", "aboutDetail": "\nVersion {0}\nValidation {1}\nDate {2}\nInterpréteur de commandes {3}\nConvertisseur {4}\nNode {5}", "okButton": "OK" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/fra/src/vs/workbench/api/node/extHostTask.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/fra/src/vs/workbench/api/node/extHostTask.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/common/theme.i18n.json b/i18n/fra/src/vs/workbench/common/theme.i18n.json index 8363fa14b9a..541ca65cc44 100644 --- a/i18n/fra/src/vs/workbench/common/theme.i18n.json +++ b/i18n/fra/src/vs/workbench/common/theme.i18n.json @@ -7,12 +7,9 @@ "tabActiveBackground": "Couleur d'arrière-plan de l'onglet actif. Les onglets sont les conteneurs des éditeurs dans la zone d'éditeurs. Vous pouvez ouvrir plusieurs onglets dans un groupe d'éditeurs. Il peut exister plusieurs groupes d'éditeurs.", "tabInactiveBackground": "Couleur d'arrière-plan de l'onglet inactif. Les onglets sont les conteneurs des éditeurs dans la zone d'éditeurs. Vous pouvez ouvrir plusieurs onglets dans un groupe d'éditeurs. Il peut exister plusieurs groupes d'éditeurs.", "tabBorder": "Bordure séparant les onglets les uns des autres. Les onglets sont les conteneurs des éditeurs dans la zone d'éditeurs. Vous pouvez ouvrir plusieurs onglets dans un groupe d'éditeurs. Il peut exister plusieurs groupes d'éditeurs.", - "tabActiveEditorGroupActiveForeground": "Couleur de premier plan de l'onglet actif dans un groupe actif. Les onglets sont les conteneurs des éditeurs dans la zone d'éditeurs. Vous pouvez ouvrir plusieurs onglets dans un groupe d'éditeurs. Il peut exister plusieurs groupes d'éditeurs.", - "tabInactiveEditorGroupActiveForeground": "Couleur de premier plan de l'onglet inactif dans un groupe actif. Les onglets sont les conteneurs des éditeurs dans la zone d'éditeurs. Vous pouvez ouvrir plusieurs onglets dans un groupe d'éditeurs. Il peut exister plusieurs groupes d'éditeurs.", "editorGroupBackground": "Couleur d'arrière-plan d'un groupe d'éditeurs. Les groupes d'éditeurs sont les conteneurs des éditeurs. La couleur d'arrière-plan s'affiche pendant le glissement de groupes d'éditeurs.", "editorGroupHeaderBackground": "Couleur d'arrière-plan de l'en-tête du titre du groupe d'éditeurs quand les onglets sont désactivés. Les groupes d'éditeurs sont les conteneurs des éditeurs.", "editorGroupBorder": "Couleur séparant plusieurs groupes d'éditeurs les uns des autres. Les groupes d'éditeurs sont les conteneurs des éditeurs.", - "panelBackground": "Couleur d'arrière-plan du panneau. Les panneaux s'affichent sous la zone d'éditeurs et contiennent des affichages tels que la sortie et le terminal intégré.", "panelBorder": "Couleur de bordure de panneau dans la partie supérieure de séparation de l'éditeur. Les panneaux s'affichent sous la zone d'éditeurs et contiennent des affichages tels que la sortie et le terminal intégré.", "panelActiveTitleForeground": "Couleur du titre du panneau actif. Les panneaux se situent sous la zone de l'éditeur et contiennent des affichages comme la sortie et le terminal intégré.", "panelInactiveTitleForeground": "Couleur du titre du panneau inactif. Les panneaux se situent sous la zone de l'éditeur et contiennent des affichages comme la sortie et le terminal intégré.", diff --git a/i18n/fra/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/fra/src/vs/workbench/electron-browser/workbench.i18n.json index 8b6ad71cd4e..771fa003a69 100644 --- a/i18n/fra/src/vs/workbench/electron-browser/workbench.i18n.json +++ b/i18n/fra/src/vs/workbench/electron-browser/workbench.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "developer": "Développeur", + "file": "Fichier" +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json b/i18n/fra/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json index 377b069eb13..afd0c7bd386 100644 --- a/i18n/fra/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json @@ -5,8 +5,8 @@ // Do not edit this file. It is machine generated. { "snapshotObj": "Seules les valeurs primitives sont affichées pour cet objet.", - "debuggingStarted": "Débogage démarré.", "debuggingPaused": "Débogage en pause. Raison : {0}, {1} {2}", + "debuggingStarted": "Débogage démarré.", "debuggingStopped": "Débogage arrêté.", "breakpointAdded": "Point d'arrêt ajouté, ligne {0}, fichier {1}", "breakpointRemoved": "Point d'arrêt supprimé, ligne {0}, fichier {1}", diff --git a/i18n/fra/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/fra/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json index d147a9a8e32..0a1d06c06ef 100644 --- a/i18n/fra/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -5,6 +5,5 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.start": "Définir une combinaison de touches", - "defineKeybinding.kbLayoutInfoMessage": "Pour votre disposition actuelle du clavier, appuyez sur ", "defineKeybinding.kbLayoutErrorMessage": "Vous ne pouvez pas produire cette combinaison de touches avec la disposition actuelle du clavier." } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/fra/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json index ae988778751..5c565fd6389 100644 --- a/i18n/fra/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -5,13 +5,12 @@ // Do not edit this file. It is machine generated. { "ConfigurationParser.invalidCWD": "Warning: options.cwd must be of type string. Ignoring value {0}\n", - "ConfigurationParser.noShell": "Avertissement : La configuration de l'interpréteur de commandes n'est prise en charge que durant l'exécution des tâches dans le terminal.", "ConfigurationParser.noargs": "Erreur : les arguments de commande doivent correspondre à un tableau de chaînes. La valeur fournie est :\n{0}", + "ConfigurationParser.noShell": "Avertissement : La configuration de l'interpréteur de commandes n'est prise en charge que durant l'exécution des tâches dans le terminal.", "ConfigurationParser.noName": "Erreur : le détecteur de problèmes de correspondance dans la portée de déclaration doit avoir un nom :\n{0}\n", "ConfigurationParser.unknownMatcherKind": "Avertissement : le détecteur de problèmes de correspondance défini est inconnu. Les types pris en charge sont string | ProblemMatcher | (string | ProblemMatcher)[].\n{0}\n", "ConfigurationParser.invalidVaraibleReference": "Erreur : référence à problemMatcher non valide : {0}\n", "ConfigurationParser.noTaskName": "Erreur : les tâches doivent fournir une propriété taskName. La tâche va être ignorée.\n{0}\n", "taskConfiguration.shellArgs": "Avertissement : La tâche '{0}' est une commande d'interpréteur de commandes, et le nom de la commande ou l'un de ses arguments contient des espaces non précédés d'un caractère d'échappement. Pour garantir une ligne de commande correcte, fusionnez les arguments dans la commande.", - "taskConfiguration.noCommandOrDependsOn": "Erreur : La tâche '{0}' ne spécifie ni une commande, ni une propriété dependsOn. La tâche va être ignorée. Sa définition est :\n{1}", "taskConfiguration.noCommand": "Erreur : La tâche '{0}' ne définit aucune commande. La tâche va être ignorée. Sa définition est :\n{1}" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json index 19b06a2f224..c95ac82e6a8 100644 --- a/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -4,11 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "JsonSchema.version": "Numéro de version de la configuration", - "JsonSchema.windows": "Configuration de commande spécifique à Windows", - "JsonSchema.mac": "Configuration de commande spécifique à Mac", - "JsonSchema.linux": "Configuration de commande spécifique à Linux", "JsonSchema.shell": "Spécifie si la commande est une commande d'interpréteur de commandes ou un programme externe. La valeur par défaut est false, en cas d'omission.", "JsonSchema.tasks.dependsOn.string": "Autre tâche dont cette tâche dépend.", - "JsonSchema.tasks.dependsOn.array": "Autres tâches dont cette tâche dépend." + "JsonSchema.tasks.dependsOn.array": "Autres tâches dont cette tâche dépend.", + "JsonSchema.windows": "Configuration de commande spécifique à Windows", + "JsonSchema.mac": "Configuration de commande spécifique à Mac", + "JsonSchema.linux": "Configuration de commande spécifique à Linux" } \ No newline at end of file diff --git a/i18n/ita/extensions/git/out/commands.i18n.json b/i18n/ita/extensions/git/out/commands.i18n.json index 530bbe4a409..1890044ddd3 100644 --- a/i18n/ita/extensions/git/out/commands.i18n.json +++ b/i18n/ita/extensions/git/out/commands.i18n.json @@ -26,6 +26,9 @@ "provide commit message": "Specificare un messaggio di commit", "branch name": "Nome ramo", "provide branch name": "Specificare un nome di ramo", + "select branch to delete": "Seleziona un ramo da cancellare", + "confirm force delete branch": "Il merge del ramo '{0}' non è completo. Elimina comunque?", + "delete branch": "Elimina ramo", "no remotes to pull": "Il repository non contiene elementi remoti configurati come origini del pull.", "no remotes to push": "Il repository non contiene elementi remoti configurati come destinazione del push.", "nobranch": "Estrarre un ramo per eseguire il push in un elemento remoto.", diff --git a/i18n/ita/extensions/git/package.i18n.json b/i18n/ita/extensions/git/package.i18n.json index 3ba24f908e9..9e1b703cc3d 100644 --- a/i18n/ita/extensions/git/package.i18n.json +++ b/i18n/ita/extensions/git/package.i18n.json @@ -26,6 +26,7 @@ "command.undoCommit": "Annulla ultimo commit", "command.checkout": "Estrai in...", "command.branch": "Crea ramo...", + "command.deleteBranch": "Elimina ramo...", "command.pull": "Esegui pull", "command.pullRebase": "Esegui pull (Riassegna)", "command.push": "Esegui push", diff --git a/i18n/ita/extensions/jake/out/main.i18n.json b/i18n/ita/extensions/jake/out/main.i18n.json index 8b6ad71cd4e..be50361d378 100644 --- a/i18n/ita/extensions/jake/out/main.i18n.json +++ b/i18n/ita/extensions/jake/out/main.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "execFailed": "Rilevamento automatico di Jake non riuscito - errore: {0}" +} \ No newline at end of file diff --git a/i18n/ita/extensions/jake/package.i18n.json b/i18n/ita/extensions/jake/package.i18n.json index 8b6ad71cd4e..76d5185d8c3 100644 --- a/i18n/ita/extensions/jake/package.i18n.json +++ b/i18n/ita/extensions/jake/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.jake.autoDetect": "Controlla se la rilevazione automatica delle attività Jake è on/off. L'impostazione predefinita è 'on'." +} \ No newline at end of file diff --git a/i18n/ita/extensions/markdown/out/extension.i18n.json b/i18n/ita/extensions/markdown/out/extension.i18n.json index 8b6ad71cd4e..2448cc1f0e0 100644 --- a/i18n/ita/extensions/markdown/out/extension.i18n.json +++ b/i18n/ita/extensions/markdown/out/extension.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "onPreviewStyleLoadError": "Impossibile caricare 'markdown.styles': {0}" +} \ No newline at end of file diff --git a/i18n/ita/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/ita/extensions/merge-conflict/out/commandHandler.i18n.json index 8b6ad71cd4e..7d9e71fea31 100644 --- a/i18n/ita/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/ita/extensions/merge-conflict/out/commandHandler.i18n.json @@ -3,4 +3,9 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "cursorNotInConflict": "Il cursore dell'editor non si trova all'interno di un conflitto merge", + "cursorOnSplitterRange": "Il cursore si trova sulla barra di divisione di merge conflitti, si prega di spostarlo o al blocco \"corrente\" o a quello \"in ricezione\"", + "noConflicts": "Conflitti merge non trovati in questo file", + "noOtherConflictsInThisFile": "Nessun altro conflitto merge trovato in questo file" +} \ No newline at end of file diff --git a/i18n/ita/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/ita/extensions/merge-conflict/out/mergeDecorator.i18n.json index 8b6ad71cd4e..ff68382dadc 100644 --- a/i18n/ita/extensions/merge-conflict/out/mergeDecorator.i18n.json +++ b/i18n/ita/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "currentChange": "(modifica corrente)", + "incomingChange": "(modifica in ingresso)" +} \ No newline at end of file diff --git a/i18n/ita/extensions/merge-conflict/package.i18n.json b/i18n/ita/extensions/merge-conflict/package.i18n.json index 8b6ad71cd4e..7d13f05f2b3 100644 --- a/i18n/ita/extensions/merge-conflict/package.i18n.json +++ b/i18n/ita/extensions/merge-conflict/package.i18n.json @@ -3,4 +3,10 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "command.category": "Esegui merge del conflitto", + "command.accept.both": "Accettare entrambe", + "config.title": "Esegui merge del conflitto", + "config.codeLensEnabled": "Abilita/Disabilita le finestre CodeLens del blocco merge di conflitti all'interno di editor", + "config.decoratorsEnabled": "Abilita/Disabilita gli elementi Decorator sul blocco merge di conflitti all'interno di editor" +} \ No newline at end of file diff --git a/i18n/ita/extensions/npm/package.i18n.json b/i18n/ita/extensions/npm/package.i18n.json index 8b6ad71cd4e..3e4c81db38d 100644 --- a/i18n/ita/extensions/npm/package.i18n.json +++ b/i18n/ita/extensions/npm/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.npm.autoDetect": "Controlla se la rilevazione automatica degli script npm è on/off. L'impostazione predefinita è 'on'." +} \ No newline at end of file diff --git a/i18n/ita/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/ita/extensions/typescript/out/utils/typingsStatus.i18n.json index ede347b5776..4cc0b902ae3 100644 --- a/i18n/ita/extensions/typescript/out/utils/typingsStatus.i18n.json +++ b/i18n/ita/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -5,7 +5,6 @@ // Do not edit this file. It is machine generated. { "installingPackages": "Recupero dei dati per ottimizzare IntelliSense in TypeScript", - "typesInstallerInitializationFailed.title": "Non è stato possibile installare i file di definizione tipi per le funzionalità del linguaggio JavaScript. Verificare che NPM sia installato e che sia incluso nel PATH", "typesInstallerInitializationFailed.moreInformation": "Altre informazioni", "typesInstallerInitializationFailed.doNotCheckAgain": "Non eseguire più la verifica", "typesInstallerInitializationFailed.close": "Chiudi" diff --git a/i18n/ita/extensions/typescript/package.i18n.json b/i18n/ita/extensions/typescript/package.i18n.json index 36ff2654b3e..2b6f87e951f 100644 --- a/i18n/ita/extensions/typescript/package.i18n.json +++ b/i18n/ita/extensions/typescript/package.i18n.json @@ -37,9 +37,10 @@ "typescript.referencesCodeLens.enabled": "Abilita/disabilita riferimenti CodeLens nei file TypeScript. Richiede TypeScript >= 2.0.6.", "typescript.implementationsCodeLens.enabled": "Abilita/Disabilita le finestre CodeLens per le implementazioni. Richiede una versione di TypeScript uguale o successiva alla 2.2.0.", "typescript.openTsServerLog.title": "Apri il log del server TypeScript", + "typescript.restartTsServer": "Riavvia server TS", "typescript.selectTypeScriptVersion.title": "Seleziona la versione di TypeScript", "jsDocCompletion.enabled": "Abilita/Disabilita commenti automatici JSDoc", "javascript.implicitProjectConfig.checkJs": "Abilita/disabilita il controllo semantico di file JavaScript. File jsconfig.json o tsconfig.json esistenti sovrascrivono su questa impostazione. Richiede TypeScript >= 2.3.1.", - "typescript.check.npmIsInstalled": "Controllare se NPM è installato per l'acquisizione automatica delle definizioni di tipi", - "javascript.nameSuggestions": "Abilita/disabilita l'inclusione di nomi univoci dal file negli elenchi di suggerimento di JavaScript." + "javascript.nameSuggestions": "Abilita/disabilita l'inclusione di nomi univoci dal file negli elenchi di suggerimento di JavaScript.", + "typescript.tsc.autoDetect": "Controlla se la rilevazione automatica di attività tsc è on/off." } \ No newline at end of file diff --git a/i18n/ita/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/ita/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index c64a07b4379..6e295ef1e2c 100644 --- a/i18n/ita/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/ita/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,6 +6,7 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "L'immagine è troppo grande per essere visualizzata nell'editor", + "resourceOpenExternalButton": "Aprire immagine utilizzando un programma esterno?", "nativeBinaryError": "Il file non verrà visualizzato nell'editor perché è binario, è molto grande o usa una codifica testo non supportata.", "sizeB": "{0} B", "sizeKB": "{0} KB", diff --git a/i18n/ita/src/vs/code/electron-main/menus.i18n.json b/i18n/ita/src/vs/code/electron-main/menus.i18n.json index 86c52fb5640..8956dea0708 100644 --- a/i18n/ita/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/ita/src/vs/code/electron-main/menus.i18n.json @@ -148,12 +148,12 @@ "miLicense": "&&Visualizza licenza", "miPrivacyStatement": "&&Informativa sulla privacy", "miAbout": "&&Informazioni su", + "accessibilityOptionsWindowTitle": "Opzioni accessibilità", "miRestartToUpdate": "Riavvia per aggiornare...", "miCheckingForUpdates": "Verifica della disponibilità di aggiornamenti...", "miDownloadUpdate": "Scarica l'aggiornamento disponibile", "miDownloadingUpdate": "Download dell'aggiornamento...", "miInstallingUpdate": "Installazione dell'aggiornamento...", - "miCheckForUpdates": "Verifica disponibilità aggiornamenti...", "aboutDetail": "\nVersione {0}\nCommit {1}\nData {2}\nShell {3}\nRenderer {4}\nNode {5}", "okButton": "OK" } \ No newline at end of file diff --git a/i18n/ita/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/ita/src/vs/editor/common/config/commonEditorConfig.i18n.json index 06ec2510c3a..b44e9539fe0 100644 --- a/i18n/ita/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/ita/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -23,6 +23,8 @@ "minimap.enabled": "Controlla se la mini mappa è visualizzata", "minimap.renderCharacters": "Esegue il rendering dei caratteri effettivi di una riga (in contrapposizione ai blocchi colore)", "minimap.maxColumn": "Limita la larghezza della mini mappa in modo da eseguire il rendering al massimo di un certo numero di colonne", + "find.seedSearchStringFromSelection": "Controlla se inizializzare la stringa di ricerca nel Widget Trova con il testo selezionato nell'editor", + "find.autoFindInSelection": "Controlla se l'impostazione Trova nella selezione è attivata quando vengono selezionati più caratteri o righe di testo nell'editor", "wordWrap.off": "Il wrapping delle righe non viene eseguito.", "wordWrap.on": "Verrà eseguito il wrapping delle righe in base alla larghezza del viewport.", "wordWrap.wordWrapColumn": "Verrà eseguito il wrapping delle righe alla posizione corrispondente a `editor.wordWrapColumn`.", @@ -41,6 +43,7 @@ "formatOnType": "Controlla se l'editor deve formattare automaticamente la riga dopo la digitazione", "formatOnPaste": "Controlla se l'editor deve formattare automaticamente il contenuto incollato. Deve essere disponibile un formattatore che deve essere in grado di formattare un intervallo in un documento.", "suggestOnTriggerCharacters": "Controlla se i suggerimenti devono essere visualizzati automaticamente durante la digitazione dei caratteri trigger", + "acceptSuggestionOnEnter": "Controlla se i suggerimenti devono essere accettati con 'INVIO' in aggiunta a 'TAB'. In questo modo è possibile evitare ambiguità tra l'inserimento di nuove righe e l'accettazione di suggerimenti. Il valore 'smart' indica di accettare un suggerimento con 'INVIO' quando comporta una modifica al testo", "acceptSuggestionOnCommitCharacter": "Controlla se accettare i suggerimenti con i caratteri di commit. Ad esempio, in JavaScript il punto e virgola (';') può essere un carattere di commit che accetta un suggerimento e digita tale carattere.", "snippetSuggestions": "Controlla se i frammenti di codice sono visualizzati con altri suggerimenti e il modo in cui sono ordinati.", "emptySelectionClipboard": "Consente di controllare se, quando si copia senza aver effettuato una selezione, viene copiata la riga corrente.", diff --git a/i18n/ita/src/vs/editor/common/view/editorColorRegistry.i18n.json b/i18n/ita/src/vs/editor/common/view/editorColorRegistry.i18n.json index 48a155767d2..1eb8439fa14 100644 --- a/i18n/ita/src/vs/editor/common/view/editorColorRegistry.i18n.json +++ b/i18n/ita/src/vs/editor/common/view/editorColorRegistry.i18n.json @@ -16,5 +16,9 @@ "editorBracketMatchBackground": "Colore di sfondo delle parentesi corrispondenti", "editorBracketMatchBorder": "Colore delle caselle di parentesi corrispondenti", "editorOverviewRulerBorder": "Colore del bordo del righello delle annotazioni.", - "editorGutter": "Colore di sfondo della barra di navigazione dell'editor. La barra contiene i margini di glifo e i numeri di riga." + "editorGutter": "Colore di sfondo della barra di navigazione dell'editor. La barra contiene i margini di glifo e i numeri di riga.", + "errorForeground": "Colore primo piano degli squiggle di errore nell'editor.", + "errorBorder": "Colore del bordo degli squiggle di errore nell'editor.", + "warningForeground": "Colore primo piano degli squiggle di avviso nell'editor", + "warningBorder": "Colore del bordo degli squggle di avviso nell'editor." } \ No newline at end of file diff --git a/i18n/ita/src/vs/editor/contrib/links/browser/links.i18n.json b/i18n/ita/src/vs/editor/contrib/links/browser/links.i18n.json index e5d5773a699..969ff8d55c9 100644 --- a/i18n/ita/src/vs/editor/contrib/links/browser/links.i18n.json +++ b/i18n/ita/src/vs/editor/contrib/links/browser/links.i18n.json @@ -6,6 +6,7 @@ { "links.navigate.mac": "Cmd + clic per seguire il collegamento", "links.navigate": "CTRL + clic per seguire il collegamento", + "links.navigate.al": "Alt + clic per seguire il collegamento", "invalid.url": "Non è stato possibile aprire questo collegamento perché il formato non è valido: {0}", "missing.url": "Non è stato possibile aprire questo collegamento perché manca la destinazione.", "label": "Apri il collegamento" diff --git a/i18n/ita/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/ita/src/vs/platform/theme/common/colorRegistry.i18n.json index e1d1005789b..4822dfeb812 100644 --- a/i18n/ita/src/vs/platform/theme/common/colorRegistry.i18n.json +++ b/i18n/ita/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -60,7 +60,6 @@ "editorBackground": "Colore di sfondo dell'editor.", "editorForeground": "Colore primo piano predefinito dell'editor.", "editorWidgetBackground": "Colore di sfondo dei widget dell'editor, ad esempio Trova/Sostituisci.", - "editorWidgetBorder": "Colore del bordo del widget editor.", "editorSelection": "Colore della selezione dell'editor.", "editorInactiveSelection": "Colore della selezione in un editor inattivo.", "editorSelectionHighlight": "Colore delle aree con lo stesso contenuto della selezione.", @@ -74,5 +73,11 @@ "diffEditorInserted": "Colore di sfondo del testo che è stato inserito.", "diffEditorRemoved": "Colore di sfondo del testo che è stato rimosso.", "diffEditorInsertedOutline": "Colore del contorno del testo che è stato inserito.", - "diffEditorRemovedOutline": "Colore del contorno del testo che è stato rimosso." + "diffEditorRemovedOutline": "Colore del contorno del testo che è stato rimosso.", + "mergeCurrentHeaderBackground": "Sfondo intestazione corrente in conflitto di merge in linea.", + "mergeCurrentContentBackground": "Sfondo contenuto corrente in conflitto di merge in linea.", + "mergeIncomingHeaderBackground": "Sfondo intestazione modifica in ingresso in conflitto di merge in linea.", + "mergeIncomingContentBackground": "Sfondo contenuto modifica in ingresso in conflitto di merge in linea.", + "overviewRulerCurrentContentForeground": "Primo piano righello panoramica corrente per conflitto di merge in linea.", + "overviewRulerIncomingContentForeground": "Primo piano righello panoramica modifiche in ingresso per conflitto di merge in linea." } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/ita/src/vs/workbench/api/node/extHostTask.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ita/src/vs/workbench/api/node/extHostTask.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/common/theme.i18n.json b/i18n/ita/src/vs/workbench/common/theme.i18n.json index 05253aee2c4..213ebbab5dc 100644 --- a/i18n/ita/src/vs/workbench/common/theme.i18n.json +++ b/i18n/ita/src/vs/workbench/common/theme.i18n.json @@ -7,12 +7,9 @@ "tabActiveBackground": "Colore di sfondo delle schede attive. Le schede sono i contenitori degli editor nell'area degli editor. È possibile aprire più schede in un gruppo di editor e possono esistere più gruppi di editor.", "tabInactiveBackground": "Colore di sfondo delle schede inattive. Le schede sono i contenitori degli editor nell'area degli editor. È possibile aprire più schede in un gruppo di editor e possono esistere più gruppi di editor.", "tabBorder": "Bordo per separare le schede l'una dall'altra. Le schede sono i contenitori degli editor nell'area degli editor. È possibile aprire più schede in un gruppo di editor e possono esistere più gruppi di editor.", - "tabActiveEditorGroupActiveForeground": "Colore di primo piano delle schede attive in un gruppo attivo. Le schede sono i contenitori degli editor nell'area degli editor. È possibile aprire più schede in un gruppo di editor e possono esistere più gruppi di editor.", - "tabInactiveEditorGroupActiveForeground": "Colore di primo piano delle schede inattive in un gruppo attivo. Le schede sono i contenitori degli editor nell'area degli editor. È possibile aprire più schede in un gruppo di editor e possono esistere più gruppi di editor.", "editorGroupBackground": "Colore di sfondo di un gruppo di editor. I gruppi di editor sono contenitori di editor. Il colore di sfondo viene visualizzato quando si trascinano i gruppi di editor in un'altra posizione.", "editorGroupHeaderBackground": "Colore di sfondo dell'intestazione del titolo dell'editor quando le schede sono disabilitate. I gruppi di editor sono contenitori di editor.", "editorGroupBorder": "Colore per separare più gruppi di editor l'uno dall'altro. I gruppi di editor sono i contenitori degli editor.", - "panelBackground": "Colore di sfondo dei pannelli. I pannelli sono visualizzati sotto l'area degli editor e contengono visualizzazioni quali quella di output e del terminale integrato.", "panelBorder": "Colore del bordo dei pannelli nella parte superiore di separazione dall'editor. I pannelli sono visualizzati sotto l'area degli editor e contengono visualizzazioni quali quella di output e del terminale integrato.", "panelActiveTitleForeground": "Colore del titolo del pannello attivo. I pannelli sono visualizzati sotto l'area degli editor e contengono visualizzazioni quali quella di output e quella del terminale integrato.", "panelInactiveTitleForeground": "Colore del titolo del pannello inattivo. I pannelli sono visualizzati sotto l'area degli editor e contengono visualizzazioni quali quella di output e quella del terminale integrato.", diff --git a/i18n/ita/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/ita/src/vs/workbench/electron-browser/workbench.i18n.json index 8b6ad71cd4e..8392fa95835 100644 --- a/i18n/ita/src/vs/workbench/electron-browser/workbench.i18n.json +++ b/i18n/ita/src/vs/workbench/electron-browser/workbench.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "developer": "Sviluppatore", + "file": "File" +} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json b/i18n/ita/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json index d5422d908c3..e90a97c9394 100644 --- a/i18n/ita/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json @@ -5,8 +5,8 @@ // Do not edit this file. It is machine generated. { "snapshotObj": "Per questo oggetto vengono visualizzati solo i valori primitivi.", - "debuggingStarted": "Il debug è stato avviato.", "debuggingPaused": "Il debug è stato sospeso. Motivo: {0}, {1} {2}", + "debuggingStarted": "Il debug è stato avviato.", "debuggingStopped": "Il debug è stato arrestato.", "breakpointAdded": "Aggiunto un punto di interruzione a riga {0} del file {1}", "breakpointRemoved": "Rimosso un punto di interruzione a riga {0} del file {1}", diff --git a/i18n/ita/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/ita/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index 158ed123e7a..e72592662b9 100644 --- a/i18n/ita/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -9,5 +9,7 @@ "prof.message": "I profili sono stati creati.", "prof.detail": "Creare un problema e allegare manualmente i file seguenti:\n{0}", "prof.restartAndFileIssue": "Crea problema e riavvia", - "prof.restart": "Riavvia" + "prof.restart": "Riavvia", + "prof.thanks": "Grazie per l'aiuto.", + "prof.detail.restart": "È necessario un riavvio alla fine per continuare a utilizzare '{0}'. Ancora una volta, grazie per il vostro contributo." } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/ita/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json index 670ffa4c4ac..9e7b35dce5d 100644 --- a/i18n/ita/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -5,6 +5,5 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.start": "Definisci tasto di scelta rapida", - "defineKeybinding.kbLayoutInfoMessage": "Per il layout di tastiera corrente premere ", "defineKeybinding.kbLayoutErrorMessage": "Non sarà possibile produrre questa combinazione di tasti con il layout di tastiera corrente." } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json b/i18n/ita/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json index 44389863a65..acbf024d405 100644 --- a/i18n/ita/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "toggleGitViewlet": "Mostra GIT", + "installAdditionalSCMProviders": "Installa ulteriori provider SCM ...", "source control": "Controllo del codice sorgente", "toggleSCMViewlet": "Mostra Gestione controllo servizi", "view": "Visualizza" diff --git a/i18n/ita/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/ita/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json index 8de23c2bbed..7a620ff7e5a 100644 --- a/i18n/ita/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -5,13 +5,12 @@ // Do not edit this file. It is machine generated. { "ConfigurationParser.invalidCWD": "Avviso: options.cwd deve essere di tipo string. Il valore {0} verrà ignorato.\n", - "ConfigurationParser.noShell": "Avviso: la configurazione della shell è supportata solo quando si eseguono attività nel terminale.", "ConfigurationParser.noargs": "Errore: gli argomenti del comando devono essere un array di stringhe. Il valore specificato è:\n{0}", + "ConfigurationParser.noShell": "Avviso: la configurazione della shell è supportata solo quando si eseguono attività nel terminale.", "ConfigurationParser.noName": "Errore: è necessario specificare un nome per il matcher problemi nell'ambito di dichiarazione:\n{0}\n", "ConfigurationParser.unknownMatcherKind": "Avviso: il matcher problemi definito è sconosciuto. I tipi supportati sono string | ProblemMatcher | (string | ProblemMatcher)[].\n{0}\n", "ConfigurationParser.invalidVaraibleReference": "Errore: il riferimento a problemMatcher non è valido: {0}\n", "ConfigurationParser.noTaskName": "Errore: le attività devono specificare una proprietà taskName. L'attività verrà ignorata.\n{0}\n", "taskConfiguration.shellArgs": "Avviso: l'attività '{0}' è un comando della shell e il nome del comando o uno dei relativi argomenti contiene spazi senza codice di escape. Per garantire la corretta indicazione della riga di comando, unire gli argomenti nel comando.", - "taskConfiguration.noCommandOrDependsOn": "Errore: l'attività '{0}' non specifica un comando o una proprietà dependsOn. L'attività verrà ignorata. Definizione dell'attività:\n{1}", "taskConfiguration.noCommand": "Errore: l'attività '{0}' non definisce un comando. L'attività verrà ignorata. Definizione dell'attività:\n{1}" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json index 248adfe6f6e..8d0ab5a5a75 100644 --- a/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -4,11 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "JsonSchema.version": "Numero di versione della configurazione", - "JsonSchema.windows": "Configurazione dei comandi specifica di Windows", - "JsonSchema.mac": "Configurazione dei comandi specifica di Mac", - "JsonSchema.linux": "Configurazione dei comandi specifica di Linux", "JsonSchema.shell": "Specifica se il comando è un comando della shell o un programma esterno. Se omesso, viene usato il valore predefinito false.", "JsonSchema.tasks.dependsOn.string": "Altra attività da cui dipende questa attività.", - "JsonSchema.tasks.dependsOn.array": "Altre attività da cui dipende questa attività." + "JsonSchema.tasks.dependsOn.array": "Altre attività da cui dipende questa attività.", + "JsonSchema.windows": "Configurazione dei comandi specifica di Windows", + "JsonSchema.mac": "Configurazione dei comandi specifica di Mac", + "JsonSchema.linux": "Configurazione dei comandi specifica di Linux" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json b/i18n/ita/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json index cf402ad3802..7801fc1c436 100644 --- a/i18n/ita/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json @@ -6,6 +6,7 @@ { "selectTheme.label": "Tema colori", "installColorThemes": "Installa temi colori aggiuntivi...", + "themes.selectTheme": "Selezionare il Tema colori (tasti su/giù per anteprima)", "selectIconTheme.label": "Tema icona file", "installIconThemes": "Installa temi dell'icona file aggiuntivi...", "noIconThemeLabel": "Nessuno", diff --git a/i18n/ita/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json b/i18n/ita/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json index 52726bd226c..2c3dacb4148 100644 --- a/i18n/ita/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json +++ b/i18n/ita/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json @@ -6,6 +6,11 @@ { "open": "Apri impostazioni", "close": "Chiudi", + "saveAndRetry": "Salva le impostazioni e riprova", "errorUnknownKey": "Non è possibile scrivere nel file di configurazione. La chiave è sconosciuta", - "errorInvalidTarget": "Non è possibile scrivere nel file di configurazione (destinazione non valida)" + "errorInvalidTarget": "Non è possibile scrivere nel file di configurazione (destinazione non valida)", + "errorNoWorkspaceOpened": "Impossibile scrivere nelle impostazioni perché nessuna cartella è aperta. Si prega di aprire una cartella e riprovare.", + "errorInvalidConfiguration": "Impossibile scrivere nelle impostazioni. Si prega di aprire **Impostazioni utente** per correggere eventuali errori o avvisi nel file e riprovare.", + "errorInvalidConfigurationWorkspace": "Impossibile scrivere in impostazioni. Si prega di aprire **Impostazioni area di lavoro** per correggere eventuali errori o avvisi nel file e riprovare.", + "errorConfigurationFileDirty": "Impossibile scrivere nelle impostazioni perché il file è stato modificato ma non salvato. Si prega di salvare il file **impostazioni utente** e riprovare." } \ No newline at end of file diff --git a/i18n/jpn/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/jpn/extensions/merge-conflict/out/codelensProvider.i18n.json index 104396accee..8b6ad71cd4e 100644 --- a/i18n/jpn/extensions/merge-conflict/out/codelensProvider.i18n.json +++ b/i18n/jpn/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -3,6 +3,4 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{ - "compareChanges": "変更ã®æ¯”較" -} \ No newline at end of file +{} \ No newline at end of file diff --git a/i18n/jpn/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/jpn/extensions/merge-conflict/out/commandHandler.i18n.json index 6c318704912..d435e6965b3 100644 --- a/i18n/jpn/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/jpn/extensions/merge-conflict/out/commandHandler.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "cursorNotInConflict": "エディターã®ã‚«ãƒ¼ã‚½ãƒ«ãŒãƒžãƒ¼ã‚¸ã®ç«¶åˆã®ç¯„囲内ã«ã‚ã‚Šã¾ã›ã‚“", + "cursorOnSplitterRange": "エディターã®ã‚«ãƒ¼ã‚½ãƒ«ãŒãƒžãƒ¼ã‚¸ コンフリクトã®ã‚¹ãƒ—リッター内ã«ã‚ã‚Šã¾ã™ã€‚â€ç¾åœ¨â€ ã¾ãŸã¯ \"入力å´\" ã®ã„ãšã‚Œã‹ã®ãƒ–ロックã«ç§»å‹•ã—ã¦ãã ã•ã„", "noConflicts": "ã“ã®ãƒ•ã‚¡ã‚¤ãƒ«ã«ãƒžãƒ¼ã‚¸ã®ç«¶åˆã¯å­˜åœ¨ã—ã¾ã›ã‚“", "noOtherConflictsInThisFile": "ã“ã®ãƒ•ã‚¡ã‚¤ãƒ«ã«ä»–ã®ãƒžãƒ¼ã‚¸ã®ç«¶åˆã¯å­˜åœ¨ã—ã¾ã›ã‚“" } \ No newline at end of file diff --git a/i18n/jpn/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/jpn/extensions/merge-conflict/out/mergeDecorator.i18n.json index 9da2446076d..6f8b1654a4d 100644 --- a/i18n/jpn/extensions/merge-conflict/out/mergeDecorator.i18n.json +++ b/i18n/jpn/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "currentChange": "(ç¾åœ¨ã®å¤‰æ›´)" + "currentChange": "(ç¾åœ¨ã®å¤‰æ›´)", + "incomingChange": "(入力å´ã®å¤‰æ›´)" } \ No newline at end of file diff --git a/i18n/jpn/extensions/merge-conflict/package.i18n.json b/i18n/jpn/extensions/merge-conflict/package.i18n.json index 178880dd69d..e2adf262063 100644 --- a/i18n/jpn/extensions/merge-conflict/package.i18n.json +++ b/i18n/jpn/extensions/merge-conflict/package.i18n.json @@ -5,8 +5,8 @@ // Do not edit this file. It is machine generated. { "command.category": "マージã®ç«¶åˆ", - "command.next": "次ã®ç«¶åˆ", - "command.previous": "å‰ã®ç«¶åˆ", - "command.compare": "ç¾åœ¨ã®ç«¶åˆã‚’比較", - "config.title": "マージã®ç«¶åˆ" + "command.accept.both": "両方をå–り込む", + "config.title": "マージã®ç«¶åˆ", + "config.codeLensEnabled": "エディター内ã®ãƒžãƒ¼ã‚¸ç«¶åˆãƒ–ロック㧠CodeLens を有効/無効ã«ã—ã¾ã™", + "config.decoratorsEnabled": "エディター内ã§ãƒžãƒ¼ã‚¸ã®ç«¶åˆãƒ‡ã‚³ãƒ¬ãƒ¼ã‚¿ãƒ¼ã‚’有効/無効ã«ã—ã¾ã™ã€‚" } \ No newline at end of file diff --git a/i18n/jpn/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/jpn/extensions/typescript/out/utils/typingsStatus.i18n.json index 5696b940392..3a40c2e29d9 100644 --- a/i18n/jpn/extensions/typescript/out/utils/typingsStatus.i18n.json +++ b/i18n/jpn/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -5,7 +5,6 @@ // Do not edit this file. It is machine generated. { "installingPackages": "よりé©ã—㟠TypeScript IntelliSense ã«é–¢ã™ã‚‹ãƒ‡ãƒ¼ã‚¿ã‚’フェッãƒã—ã¦ã„ã¾ã™", - "typesInstallerInitializationFailed.title": "JavaScript 言語機能ã®ãŸã‚ã®åž‹å®šç¾©ãƒ•ã‚¡ã‚¤ãƒ«ã‚’インストールã§ãã¾ã›ã‚“ã§ã—ãŸã€‚NPM ãŒã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã€PATH ã«ã‚ã‚‹ã“ã¨ã‚’確èªã—ã¦ãã ã•ã„。", "typesInstallerInitializationFailed.moreInformation": "詳細情報", "typesInstallerInitializationFailed.doNotCheckAgain": "今後確èªã—ãªã„", "typesInstallerInitializationFailed.close": "é–‰ã˜ã‚‹" diff --git a/i18n/jpn/extensions/typescript/package.i18n.json b/i18n/jpn/extensions/typescript/package.i18n.json index 1ad434c3205..9f60798218f 100644 --- a/i18n/jpn/extensions/typescript/package.i18n.json +++ b/i18n/jpn/extensions/typescript/package.i18n.json @@ -41,6 +41,6 @@ "typescript.selectTypeScriptVersion.title": "TypeScript ã®ãƒãƒ¼ã‚¸ãƒ§ãƒ³ã®é¸æŠž", "jsDocCompletion.enabled": " 自動 JSDoc コメントを有効/無効ã«ã—ã¾ã™", "javascript.implicitProjectConfig.checkJs": "JavaScript ファイルã®ã‚»ãƒžãƒ³ãƒ†ã‚£ãƒƒã‚¯ ãƒã‚§ãƒƒã‚¯ã‚’有効/無効ã«ã—ã¾ã™ã€‚既存㮠jsconfi.json ã‚„ tsconfi.json ファイルã®è¨­å®šã¯ã“れより優先ã•ã‚Œã¾ã™ã€‚TypeScript 㯠2.3.1 以上ã§ã‚ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™ã€‚", - "typescript.check.npmIsInstalled": "型定義ã®è‡ªå‹•å–å¾—ã« NPM ãŒã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã¦ã„ã‚‹ã‹ã©ã†ã‹ã‚’確èªã™ã‚‹", - "javascript.nameSuggestions": "JavaScript ã®å€™è£œãƒªã‚¹ãƒˆå†…ã§ãƒ•ã‚¡ã‚¤ãƒ«ã‹ã‚‰ä¸€æ„ã®åå‰ã‚’å«ã‚€ã‹ã©ã†ã‹ã‚’有効/無効ã«ã—ã¾ã™ã€‚" + "javascript.nameSuggestions": "JavaScript ã®å€™è£œãƒªã‚¹ãƒˆå†…ã§ãƒ•ã‚¡ã‚¤ãƒ«ã‹ã‚‰ä¸€æ„ã®åå‰ã‚’å«ã‚€ã‹ã©ã†ã‹ã‚’有効/無効ã«ã—ã¾ã™ã€‚", + "typescript.tsc.autoDetect": "tsc タスクã®è‡ªå‹•æ¤œå‡ºã‚’オンã«ã™ã‚‹ã‹ã‚ªãƒ•ã«ã™ã‚‹ã‹ã‚’制御ã—ã¾ã™ã€‚" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/code/electron-main/menus.i18n.json b/i18n/jpn/src/vs/code/electron-main/menus.i18n.json index 79412979d8d..541c16a930c 100644 --- a/i18n/jpn/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/jpn/src/vs/code/electron-main/menus.i18n.json @@ -153,12 +153,12 @@ "miLicense": "ライセンスã®è¡¨ç¤º(&&L)", "miPrivacyStatement": "プライãƒã‚·ãƒ¼ã«ã¤ã„ã¦(&&P)", "miAbout": "ãƒãƒ¼ã‚¸ãƒ§ãƒ³æƒ…å ±(&&A)", + "accessibilityOptionsWindowTitle": "ユーザー補助オプション", "miRestartToUpdate": "æ›´æ–°ã®ãŸã‚ã«å†èµ·å‹•ã—ã¾ã™...", "miCheckingForUpdates": "更新を確èªã—ã¦ã„ã¾ã™...", "miDownloadUpdate": "利用å¯èƒ½ãªæ›´æ–°ãƒ—ログラムをダウンロードã—ã¾ã™", "miDownloadingUpdate": "更新をダウンロードã—ã¦ã„ã¾ã™...", "miInstallingUpdate": "更新プログラムをインストールã—ã¦ã„ã¾ã™...", - "miCheckForUpdates": "æ›´æ–°ã®ç¢ºèª...", "aboutDetail": "\nãƒãƒ¼ã‚¸ãƒ§ãƒ³{0}\nコミット{1}\n日付{2}\nシェル{3}\nレンダラー{4}\nNode {5}", "okButton": "OK" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/jpn/src/vs/editor/common/config/commonEditorConfig.i18n.json index 8ce8d297e00..1fa006e9cb2 100644 --- a/i18n/jpn/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/jpn/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -23,6 +23,8 @@ "minimap.enabled": "ミニマップを表示ã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™", "minimap.renderCharacters": "行㫠(カラー ブロックã§ã¯ãªã) 実際ã®æ–‡å­—を表示ã—ã¾ã™", "minimap.maxColumn": "表示ã™ã‚‹ãƒŸãƒ‹ãƒžãƒƒãƒ—ã®æœ€å¤§å¹…を特定ã®æ¡æ•°ã«åˆ¶é™ã—ã¾ã™", + "find.seedSearchStringFromSelection": "エディターã®é¸æŠžã‹ã‚‰æ¤œç´¢ã‚¦ã‚£ã‚¸ã‚§ãƒƒãƒˆå†…ã®æ¤œç´¢æ–‡å­—列を与ãˆã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™", + "find.autoFindInSelection": "エディター内ã§è¤‡æ•°ã®æ–‡å­—ã‚‚ã—ãã¯è¡ŒãŒé¸æŠžã•ã‚Œã¦ã„ã‚‹ã¨ãã«é¸æŠžç¯„囲を検索ã™ã‚‹ãƒ•ãƒ©ã‚°ã‚’有効ã«ã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™", "wordWrap.off": "行を折り返ã—ã¾ã›ã‚“。", "wordWrap.on": "行をビューãƒãƒ¼ãƒˆã®å¹…ã§æŠ˜ã‚Šè¿”ã—ã¾ã™ã€‚", "wordWrap.wordWrapColumn": "行を 'editor.wordWrapColumn' ã§æŠ˜ã‚Šè¿”ã—ã¾ã™ã€‚", @@ -41,6 +43,7 @@ "formatOnType": "エディターã§å…¥åŠ›å¾Œã«è‡ªå‹•çš„ã«è¡Œã®æ›¸å¼è¨­å®šã‚’è¡Œã†ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™", "formatOnPaste": "貼り付ã‘ãŸå†…容ãŒã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã«ã‚ˆã‚Šè‡ªå‹•çš„ã«ãƒ•ã‚©ãƒ¼ãƒžãƒƒãƒˆã•ã‚Œã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚フォーマッタを使用å¯èƒ½ã«ã™ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™ã€‚ã¾ãŸã€ãƒ•ã‚©ãƒ¼ãƒžãƒƒã‚¿ãŒãƒ‰ã‚­ãƒ¥ãƒ¡ãƒ³ãƒˆå†…ã®ç¯„囲をフォーマットã§ããªã‘ã‚Œã°ãªã‚Šã¾ã›ã‚“。", "suggestOnTriggerCharacters": "トリガー文字ã®å…¥åŠ›æ™‚ã«å€™è£œãŒè‡ªå‹•çš„ã«è¡¨ç¤ºã•ã‚Œã‚‹ã‚ˆã†ã«ã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™", + "acceptSuggestionOnEnter": "'Tab' キーã«åŠ ãˆã¦ 'Enter' キーã§å€™è£œã‚’å—ã‘入れるã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚改行ã®æŒ¿å…¥ã‚„候補ã®å映ã®é–“ã§ã‚ã„ã¾ã„ã•ã‚’解消ã™ã‚‹ã®ã«å½¹ç«‹ã¡ã¾ã™ã€‚'smart' 値ã¯æ–‡å­—を変更ã™ã‚‹ã¨ãã«ã€Enter キーを押ã™ã ã‘ã§æ案をå映ã™ã‚‹ã“ã¨ã‚’æ„味ã—ã¾ã™ã€‚", "acceptSuggestionOnCommitCharacter": "コミット文字ã§å€™è£œã‚’å—ã‘入れるã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚ãŸã¨ãˆã°ã€JavaScript ã§ã¯ã‚»ãƒŸã‚³ãƒ­ãƒ³ (';') をコミット文字ã«ã—ã¦ã€å€™è£œã‚’å—ã‘入れã¦ãã®æ–‡å­—を入力ã™ã‚‹ã“ã¨ãŒã§ãã¾ã™ã€‚", "snippetSuggestions": "ä»–ã®ä¿®æ­£å€™è£œã¨ä¸€ç·’ã«ã‚¹ãƒ‹ãƒšãƒƒãƒˆã‚’表示ã™ã‚‹ã‹ã©ã†ã‹ã€ãŠã‚ˆã³ãã®ä¸¦ã³æ›¿ãˆã®æ–¹æ³•ã‚’制御ã—ã¾ã™ã€‚", "emptySelectionClipboard": "é¸æŠžç¯„囲を指定ã—ãªã„ã§ã‚³ãƒ”ーã™ã‚‹å ´åˆã«ç¾åœ¨ã®è¡Œã‚’コピーã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚", diff --git a/i18n/jpn/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json b/i18n/jpn/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json index 4fbcbda9f94..989d71f385b 100644 --- a/i18n/jpn/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json +++ b/i18n/jpn/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json @@ -8,6 +8,5 @@ "markerAction.next.label": "次ã®ã‚¨ãƒ©ãƒ¼ã¾ãŸã¯è­¦å‘Šã¸ç§»å‹•", "markerAction.previous.label": "å‰ã®ã‚¨ãƒ©ãƒ¼ã¾ãŸã¯è­¦å‘Šã¸ç§»å‹•", "editorMarkerNavigationError": "エディターã®ãƒžãƒ¼ã‚«ãƒ¼ ナビゲーション ウィジェットã®ã‚¨ãƒ©ãƒ¼ã®è‰²ã€‚", - "editorMarkerNavigationWarning": "エディターã®ãƒžãƒ¼ã‚«ãƒ¼ ナビゲーション ウィジェットã®è­¦å‘Šã®è‰²ã€‚", - "editorMarkerNavigationBackground": "エディターã®ãƒžãƒ¼ã‚«ãƒ¼ ナビゲーション ウィジェットã®èƒŒæ™¯ã€‚" + "editorMarkerNavigationWarning": "エディターã®ãƒžãƒ¼ã‚«ãƒ¼ ナビゲーション ウィジェットã®è­¦å‘Šã®è‰²ã€‚" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/jpn/src/vs/platform/theme/common/colorRegistry.i18n.json index 9872f49057d..8da89f6115c 100644 --- a/i18n/jpn/src/vs/platform/theme/common/colorRegistry.i18n.json +++ b/i18n/jpn/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -60,7 +60,6 @@ "editorBackground": "エディターã®èƒŒæ™¯è‰²ã€‚", "editorForeground": "エディターã®æ—¢å®šã®å‰æ™¯è‰²ã€‚", "editorWidgetBackground": "検索/ç½®æ›çª“ãªã©ã€ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ ウィジェットã®èƒŒæ™¯è‰²ã€‚", - "editorWidgetBorder": "エディター ウィジェットã®å¢ƒç•Œç·šã®è‰²ã€‚", "editorSelection": "エディターã®é¸æŠžç¯„囲ã®è‰²ã€‚", "editorInactiveSelection": "éžã‚¢ã‚¯ãƒ†ã‚£ãƒ–ãªã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã®é¸æŠžç¯„囲ã®è‰²ã€‚", "editorSelectionHighlight": "é¸æŠžç¯„囲ã¨åŒã˜ã‚³ãƒ³ãƒ†ãƒ³ãƒ„ã®é ˜åŸŸã®è‰²ã€‚", diff --git a/i18n/jpn/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/jpn/src/vs/workbench/api/node/extHostTask.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/jpn/src/vs/workbench/api/node/extHostTask.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json b/i18n/jpn/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json index ff6068c7837..2b2a554b6db 100644 --- a/i18n/jpn/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json +++ b/i18n/jpn/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json @@ -11,6 +11,7 @@ "endOfLineLineFeed": "LF", "endOfLineCarriageReturnLineFeed": "CRLF", "tabFocusModeEnabled": "タブã«ã‚ˆã‚‹ãƒ•ã‚©ãƒ¼ã‚«ã‚¹ã®ç§»å‹•", + "screenReaderDetected": "スクリーン リーダーãŒæ¤œå‡ºã•ã‚Œã¾ã—ãŸ", "disableTabMode": "アクセシビリティ モードを無効ã«ã™ã‚‹", "gotoLine": "è¡Œã¸ç§»å‹•", "indentation": "インデント", diff --git a/i18n/jpn/src/vs/workbench/common/theme.i18n.json b/i18n/jpn/src/vs/workbench/common/theme.i18n.json index d183c267924..26f43afd107 100644 --- a/i18n/jpn/src/vs/workbench/common/theme.i18n.json +++ b/i18n/jpn/src/vs/workbench/common/theme.i18n.json @@ -7,34 +7,37 @@ "tabActiveBackground": "アクティブ タブã®èƒŒæ™¯è‰²ã€‚タブã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸã«ãŠã‘るエディターã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚1 ã¤ã®ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ グループã§è¤‡æ•°ã®ã‚¿ãƒ–ã‚’é–‹ãã“ã¨ãŒã§ãã¾ã™ã€‚エディター グループを複数ã«ã™ã‚‹ã“ã¨ã‚‚ã§ãã¾ã™ã€‚", "tabInactiveBackground": "éžã‚¢ã‚¯ãƒ†ã‚£ãƒ– タブã®èƒŒæ™¯è‰²ã€‚タブã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸã«ãŠã‘るエディターã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚1 ã¤ã®ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ グループã§è¤‡æ•°ã®ã‚¿ãƒ–ã‚’é–‹ãã“ã¨ãŒã§ãã¾ã™ã€‚エディター グループを複数ã«ã™ã‚‹ã“ã¨ã‚‚ã§ãã¾ã™ã€‚", "tabBorder": "タブåŒå£«ã‚’分ã‘ã‚‹ãŸã‚ã®å¢ƒç•Œç·šã€‚タブã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸå†…ã«ã‚るエディターã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚複数ã®ã‚¿ãƒ–ã‚’ 1 ã¤ã®ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ グループã§é–‹ãã“ã¨ãŒã§ãã¾ã™ã€‚複数ã®ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ グループãŒã‚ã‚‹å¯èƒ½æ€§ãŒã‚ã‚Šã¾ã™ã€‚", - "tabActiveEditorGroupActiveForeground": "アクティブ グループ内ã®ã‚¢ã‚¯ãƒ†ã‚£ãƒ– タブã®å‰æ™¯è‰²ã€‚タブã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸã«ãŠã‘るエディターã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚1 ã¤ã®ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ グループã§è¤‡æ•°ã®ã‚¿ãƒ–ã‚’é–‹ãã“ã¨ãŒã§ãã¾ã™ã€‚エディター グループを複数ã«ã™ã‚‹ã“ã¨ã‚‚ã§ãã¾ã™ã€‚", - "tabInactiveEditorGroupActiveForeground": "アクティブ グループ内ã®éžã‚¢ã‚¯ãƒ†ã‚£ãƒ– タブã®å‰æ™¯è‰²ã€‚タブã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸã«ãŠã‘るエディターã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚1 ã¤ã®ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ グループã§è¤‡æ•°ã®ã‚¿ãƒ–ã‚’é–‹ãã“ã¨ãŒã§ãã¾ã™ã€‚エディター グループを複数ã«ã™ã‚‹ã“ã¨ã‚‚ã§ãã¾ã™ã€‚", "editorGroupBackground": "エディター グループã®èƒŒæ™¯è‰²ã€‚エディター グループã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚背景色ã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ グループをドラッグã™ã‚‹ã¨è¡¨ç¤ºã•ã‚Œã¾ã™ã€‚", "tabsContainerBackground": "タブãŒæœ‰åŠ¹ãªå ´åˆã® エディター グループ タイトル ヘッダーã®èƒŒæ™¯è‰²ã€‚エディター グループã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", + "tabsContainerBorder": "タブãŒæœ‰åŠ¹ãªå ´åˆã® エディター グループ タイトル ヘッダーã®å¢ƒç•Œç·šè‰²ã€‚エディター グループã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", "editorGroupHeaderBackground": "タブãŒç„¡åŠ¹ãªå ´åˆã® エディター グループ タイトル ヘッダーã®èƒŒæ™¯è‰²ã€‚エディター グループã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", "editorGroupBorder": "複数ã®ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ グループを互ã„ã«åˆ†é›¢ã™ã‚‹ãŸã‚ã®è‰²ã€‚エディター グループã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", "editorDragAndDropBackground": "エディターã®å‘¨å›²ã‚’ドラッグã—ã¦ã„ã‚‹ã¨ãã®èƒŒæ™¯è‰²ã€‚エディターã®ã‚³ãƒ³ãƒ†ãƒ³ãƒ„ãŒæœ€å¾Œã¾ã§è¼ããŸã‚ã«ã€è‰²ã¯é€éŽã§ã‚ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™ã€‚", - "panelBackground": "パãƒãƒ«ã®èƒŒæ™¯è‰²ã€‚パãƒãƒ«ã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸã®ä¸‹ã«è¡¨ç¤ºã•ã‚Œã€å‡ºåŠ›ã‚„çµ±åˆã‚¿ãƒ¼ãƒŸãƒŠãƒ«ãªã©ã®ãƒ“ューをå«ã¿ã¾ã™ã€‚", "panelBorder": "エディターã¨ã®åŒºåˆ‡ã‚Šã‚’示ã™ãƒ‘ãƒãƒ«ä¸Šéƒ¨ã®ç½«ç·šã®è‰²ã€‚パãƒãƒ«ã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸã®ä¸‹ã«è¡¨ç¤ºã•ã‚Œã€å‡ºåŠ›ã‚„çµ±åˆã‚¿ãƒ¼ãƒŸãƒŠãƒ«ãªã©ã®ãƒ“ューをå«ã¿ã¾ã™ã€‚", "panelActiveTitleForeground": "アクティブ パãƒãƒ«ã®ã‚¿ã‚¤ãƒˆãƒ«ã®è‰²ã€‚パãƒãƒ«ã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸã®ä¸‹ã«è¡¨ç¤ºã•ã‚Œã€å‡ºåŠ›ã‚„çµ±åˆã‚¿ãƒ¼ãƒŸãƒŠãƒ«ãªã©ã®ãƒ“ューをå«ã¿ã¾ã™ã€‚", "panelInactiveTitleForeground": "éžã‚¢ã‚¯ãƒ†ã‚£ãƒ– パãƒãƒ«ã®ã‚¿ã‚¤ãƒˆãƒ«ã®è‰²ã€‚パãƒãƒ«ã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸã®ä¸‹ã«è¡¨ç¤ºã•ã‚Œã€å‡ºåŠ›ã‚„çµ±åˆã‚¿ãƒ¼ãƒŸãƒŠãƒ«ãªã©ã®ãƒ“ューをå«ã¿ã¾ã™ã€‚", "panelActiveTitleBorder": "アクティブ パãƒãƒ« タイトルã®å¢ƒç•Œç·šã®è‰²ã€‚パãƒãƒ«ã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸã®ä¸‹ã«è¡¨ç¤ºã•ã‚Œã€å‡ºåŠ›ã‚„çµ±åˆã‚¿ãƒ¼ãƒŸãƒŠãƒ«ãªã©ã®ãƒ“ューをå«ã¿ã¾ã™ã€‚", "statusBarForeground": "ステータス ãƒãƒ¼ã®å‰æ™¯è‰²ã€‚ステータス ãƒãƒ¼ã¯ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã®ä¸‹éƒ¨ã«è¡¨ç¤ºã•ã‚Œã¾ã™ã€‚", "statusBarBackground": "標準ステータス ãƒãƒ¼ã®èƒŒæ™¯è‰²ã€‚ステータス ãƒãƒ¼ã¯ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã®ä¸‹éƒ¨ã«è¡¨ç¤ºã•ã‚Œã¾ã™ã€‚", + "statusBarBorder": "サイドãƒãƒ¼ã¨ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã‚’éš”ã¦ã‚‹ã‚¹ãƒ†ãƒ¼ã‚¿ã‚¹ ãƒãƒ¼ã®å¢ƒç•Œç·šè‰²ã€‚ステータス ãƒãƒ¼ã¯ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã®ä¸‹éƒ¨ã«è¡¨ç¤ºã•ã‚Œã¾ã™ã€‚", "statusBarNoFolderBackground": "フォルダーãŒé–‹ã„ã¦ã„ãªã„ã¨ãã®ã‚¹ãƒ†ãƒ¼ã‚¿ã‚¹ ãƒãƒ¼ã®èƒŒæ™¯è‰²ã€‚ステータス ãƒãƒ¼ã¯ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã®ä¸‹éƒ¨ã«è¡¨ç¤ºã•ã‚Œã¾ã™ã€‚", + "statusBarNoFolderForeground": "フォルダーãŒé–‹ã„ã¦ã„ãªã„ã¨ãã®ã‚¹ãƒ†ãƒ¼ã‚¿ã‚¹ ãƒãƒ¼ã®å‰æ™¯è‰²ã€‚ステータス ãƒãƒ¼ã¯ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã®ä¸‹éƒ¨ã«è¡¨ç¤ºã•ã‚Œã¾ã™ã€‚", "statusBarItemActiveBackground": "クリック時ã®ã‚¹ãƒ†ãƒ¼ã‚¿ã‚¹ ãƒãƒ¼ã®é …ç›®ã®èƒŒæ™¯è‰²ã€‚ステータス ãƒãƒ¼ã¯ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã®ä¸‹éƒ¨ã«è¡¨ç¤ºã•ã‚Œã¾ã™ã€‚", "statusBarItemHoverBackground": "ホãƒãƒ¼ã—ãŸã¨ãã®ã‚¹ãƒ†ãƒ¼ã‚¿ã‚¹ ãƒãƒ¼ã®é …ç›®ã®èƒŒæ™¯è‰²ã€‚ステータス ãƒãƒ¼ã¯ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã®ä¸‹éƒ¨ã«è¡¨ç¤ºã•ã‚Œã¾ã™ã€‚", "statusBarProminentItemBackground": "ステータス ãƒãƒ¼ã®é‡è¦ãªé …ç›®ã®èƒŒæ™¯è‰²ã€‚é‡è¦ãªé …ç›®ã¯ã€é‡è¦æ€§ã‚’示ã™ãŸã‚ã«ä»–ã®ã‚¹ãƒ†ãƒ¼ã‚¿ã‚¹ãƒãƒ¼ã®é …ç›®ã‹ã‚‰éš›ç«‹ã£ã¦ã„ã¾ã™ã€‚ ステータス ãƒãƒ¼ã¯ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã®ä¸‹éƒ¨ã«è¡¨ç¤ºã•ã‚Œã¾ã™ã€‚", "statusBarProminentItemHoverBackground": "ホãƒãƒ¼ã—ãŸã¨ãã®ã‚¹ãƒ†ãƒ¼ã‚¿ã‚¹ ãƒãƒ¼ã®é‡è¦ãªé …ç›®ã®èƒŒæ™¯è‰²ã€‚é‡è¦ãªé …ç›®ã¯ã€é‡è¦æ€§ã‚’示ã™ãŸã‚ã«ä»–ã®ã‚¹ãƒ†ãƒ¼ã‚¿ã‚¹ãƒãƒ¼ã®é …ç›®ã‹ã‚‰éš›ç«‹ã£ã¦ã„ã¾ã™ã€‚ ステータス ãƒãƒ¼ã¯ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã®ä¸‹éƒ¨ã«è¡¨ç¤ºã•ã‚Œã¾ã™ã€‚", "activityBarBackground": "アクティビティ ãƒãƒ¼ã®èƒŒæ™¯è‰²ã€‚アクティビティ ãƒãƒ¼ã¯å·¦ç«¯ã¾ãŸã¯å³ç«¯ã«è¡¨ç¤ºã•ã‚Œã€ã‚µã‚¤ãƒ‰ ãƒãƒ¼ã®ãƒ“ューを切り替ãˆã‚‹ã“ã¨ãŒã§ãã¾ã™ã€‚", "activityBarForeground": "アクティビティ ãƒãƒ¼ã®å‰æ™¯è‰² (例: アイコンã®è‰²)。アクティビティ ãƒãƒ¼ã¯å·¦ç«¯ã¾ãŸã¯å³ç«¯ã«è¡¨ç¤ºã•ã‚Œã€ã‚µã‚¤ãƒ‰ ãƒãƒ¼ã®ãƒ“ューを切り替ãˆã‚‹ã“ã¨ãŒã§ãã¾ã™ã€‚", + "activityBarBorder": "サイド ãƒãƒ¼ã¨éš”ã¦ã‚‹ã‚¢ã‚¯ãƒ†ã‚£ãƒ“ティ ãƒãƒ¼ã®å¢ƒç•Œç·šè‰²ã€‚アクティビティ ãƒãƒ¼ã¯å·¦ç«¯ã¾ãŸã¯å³ç«¯ã«è¡¨ç¤ºã•ã‚Œã€ã‚µã‚¤ãƒ‰ ãƒãƒ¼ã®ãƒ“ューを切り替ãˆã‚‹ã“ã¨ãŒã§ãã¾ã™ã€‚", "activityBarDragAndDropBackground": "アクティビティ ãƒãƒ¼ã®é …ç›®ã®ãƒ‰ãƒ©ãƒƒã‚° アンド ドロップ フィードãƒãƒƒã‚¯ã®è‰²ã€‚アクティビティ ãƒãƒ¼ãŒæœ€å¾Œã¾ã§è¼ããŸã‚ã«ã€è‰²ã¯é€éŽã§ã‚ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™ã€‚アクティビティ ãƒãƒ¼ã¯å·¦ç«¯ã¾ãŸã¯å³ç«¯ã«è¡¨ç¤ºã•ã‚Œã€ã‚µã‚¤ãƒ‰ ãƒãƒ¼ã®è¡¨ç¤ºã‚’切り替ãˆã‚‹ã“ã¨ãŒã§ãã¾ã™ã€‚", "activityBarBadgeBackground": "アクティビティ通知ãƒãƒƒã‚¸ã®èƒŒæ™¯è‰²ã€‚アクティビティ ãƒãƒ¼ã¯å·¦ç«¯ã¾ãŸã¯å³ç«¯ã«è¡¨ç¤ºã•ã‚Œã€ã‚µã‚¤ãƒ‰ ãƒãƒ¼ã®è¡¨ç¤ºã‚’切り替ãˆã‚‹ã“ã¨ãŒã§ãã¾ã™ã€‚", "activityBarBadgeForeground": "アクティビティ通知ãƒãƒƒã‚¸ã®å‰æ™¯è‰²ã€‚アクティビティ ãƒãƒ¼ã¯å·¦ç«¯ã¾ãŸã¯å³ç«¯ã«è¡¨ç¤ºã•ã‚Œã€ã‚µã‚¤ãƒ‰ ãƒãƒ¼ã®è¡¨ç¤ºã‚’切り替ãˆã‚‹ã“ã¨ãŒã§ãã¾ã™ã€‚", "sideBarBackground": "サイド ãƒãƒ¼ã®èƒŒæ™¯è‰²ã€‚サイド ãƒãƒ¼ã¯ã€ã‚¨ã‚¯ã‚¹ãƒ—ローラーや検索ãªã©ã®ãƒ“ューãŒå…¥ã‚‹ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", "sideBarForeground": "サイド ãƒãƒ¼ã®å‰æ™¯è‰²ã€‚サイド ãƒãƒ¼ã¯ã€ã‚¨ã‚¯ã‚¹ãƒ—ローラーや検索ãªã©ã®ãƒ“ューãŒå…¥ã‚‹ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", + "sideBarBorder": "エディターã¨ã®åŒºåˆ‡ã‚Šã‚’示ã™ã‚µã‚¤ãƒ‰ ãƒãƒ¼ã®å¢ƒç•Œç·šã®è‰²ã€‚サイド ãƒãƒ¼ã¯ã€ã‚¨ã‚¯ã‚¹ãƒ—ローラーや検索ãªã©ã®ãƒ“ューãŒå…¥ã‚‹ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", "sideBarTitleForeground": "サイド ãƒãƒ¼ã®ã‚¿ã‚¤ãƒˆãƒ«ã®å‰æ™¯è‰²ã€‚サイド ãƒãƒ¼ã¯ã€ã‚¨ã‚¯ã‚¹ãƒ—ローラーや検索ãªã©ã®ãƒ“ューãŒå…¥ã‚‹ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", "sideBarSectionHeaderBackground": "サイド ãƒãƒ¼ã®ã‚»ã‚¯ã‚·ãƒ§ãƒ³ ヘッダーã®èƒŒæ™¯è‰²ã€‚サイド ãƒãƒ¼ã¯ã€ã‚¨ã‚¯ã‚¹ãƒ—ローラーや検索ãªã©ã®ãƒ“ューãŒå…¥ã‚‹ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", + "sideBarSectionHeaderForeground": "サイド ãƒãƒ¼ã®ã‚»ã‚¯ã‚·ãƒ§ãƒ³ ヘッダーã®å‰æ™¯è‰²ã€‚サイド ãƒãƒ¼ã¯ã€ã‚¨ã‚¯ã‚¹ãƒ—ローラーや検索ãªã©ã®ãƒ“ューãŒå…¥ã‚‹ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", "titleBarActiveForeground": "ウィンドウãŒã‚¢ã‚¯ãƒ†ã‚£ãƒ–ãªå ´åˆã®ã‚¿ã‚¤ãƒˆãƒ« ãƒãƒ¼ã®å‰æ™¯ã€‚ç¾åœ¨ã€ã“ã®è‰²ã¯ macOS ã§ã®ã¿ã‚µãƒãƒ¼ãƒˆã•ã‚Œã¦ã„ã‚‹ã®ã§ã”注æ„ãã ã•ã„。", "titleBarInactiveForeground": "ウィンドウãŒéžã‚¢ã‚¯ãƒ†ã‚£ãƒ–ãªå ´åˆã®ã‚¿ã‚¤ãƒˆãƒ« ãƒãƒ¼ã®å‰æ™¯ã€‚ç¾åœ¨ã€ã“ã®è‰²ã¯ macOS ã§ã®ã¿ã‚µãƒãƒ¼ãƒˆã•ã‚Œã¦ã„ã‚‹ã®ã§ã”注æ„ãã ã•ã„。", "titleBarActiveBackground": "ウィンドウãŒã‚¢ã‚¯ãƒ†ã‚£ãƒ–ãªå ´åˆã®ã‚¿ã‚¤ãƒˆãƒ« ãƒãƒ¼ã®èƒŒæ™¯ã€‚ç¾åœ¨ã€ã“ã®è‰²ã¯ macOS ã§ã®ã¿ã‚µãƒãƒ¼ãƒˆã•ã‚Œã¦ã„ã‚‹ã®ã§ã”注æ„ãã ã•ã„。", diff --git a/i18n/jpn/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/jpn/src/vs/workbench/electron-browser/workbench.i18n.json index 8b6ad71cd4e..bbe34173584 100644 --- a/i18n/jpn/src/vs/workbench/electron-browser/workbench.i18n.json +++ b/i18n/jpn/src/vs/workbench/electron-browser/workbench.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "developer": "開発者", + "file": "ファイル" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json b/i18n/jpn/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json index dfffb6e0790..45728f86746 100644 --- a/i18n/jpn/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json @@ -5,8 +5,8 @@ // Do not edit this file. It is machine generated. { "snapshotObj": "ã“ã®ã‚ªãƒ–ジェクトã®ãƒ—リミティブ値ã®ã¿è¡¨ç¤ºã•ã‚Œã¾ã™ã€‚", - "debuggingStarted": "デãƒãƒƒã‚°ã¯é–‹å§‹ã•ã‚Œã¾ã—ãŸã€‚", "debuggingPaused": "デãƒãƒƒã‚°ã¯ä¸€æ™‚åœæ­¢ã•ã‚Œã¾ã—ãŸã€ç†ç”± {0}ã€{1} {2}", + "debuggingStarted": "デãƒãƒƒã‚°ã¯é–‹å§‹ã•ã‚Œã¾ã—ãŸã€‚", "debuggingStopped": "デãƒãƒƒã‚°ã¯åœæ­¢ã•ã‚Œã¾ã—ãŸã€‚", "breakpointAdded": "ブレークãƒã‚¤ãƒ³ãƒˆã‚’追加ã—ã¾ã—ãŸã€‚è¡Œ {0}ã€ãƒ•ã‚¡ã‚¤ãƒ« {1}", "breakpointRemoved": "ブレークãƒã‚¤ãƒ³ãƒˆã‚’削除ã—ã¾ã—ãŸã€‚è¡Œ {0}ã€ãƒ•ã‚¡ã‚¤ãƒ« {1}", diff --git a/i18n/jpn/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json b/i18n/jpn/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json index 868785478db..51044b7942e 100644 --- a/i18n/jpn/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json @@ -26,13 +26,13 @@ "disableAutoUpdate": "拡張機能ã®è‡ªå‹•æ›´æ–°ã‚’無効ã«ã™ã‚‹", "updateAll": "ã™ã¹ã¦ã®æ‹¡å¼µæ©Ÿèƒ½ã‚’æ›´æ–°ã—ã¾ã™", "reloadAction": "å†èª­ã¿è¾¼ã¿", - "postUpdateTooltip": "å†åº¦èª­ã¿è¾¼ã‚“ã§æ›´æ–°ã™ã‚‹", + "postUpdateTooltip": "å†èª­ã¿è¾¼ã¿ã—ã¦æ›´æ–°ã™ã‚‹", "postUpdateMessage": "ã“ã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã‚’å†åº¦èª­ã¿è¾¼ã‚“ã§ã€æ›´æ–°æ¸ˆã¿ã®æ‹¡å¼µæ©Ÿèƒ½ '{0}' をアクティブ化ã—ã¾ã™ã‹?", "postEnableTooltip": "å†åº¦èª­ã¿è¾¼ã‚“ã§ã‚¢ã‚¯ãƒ†ã‚£ãƒ–ã«ã™ã‚‹", "postEnableMessage": "ã“ã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã‚’å†åº¦èª­ã¿è¾¼ã‚“ã§ã€æ‹¡å¼µæ©Ÿèƒ½ '{0}' をアクティブ化ã—ã¾ã™ã‹?", "postDisableTooltip": "読ã¿è¾¼ã‚“ã§éžã‚¢ã‚¯ãƒ†ã‚£ãƒ–化ã™ã‚‹", "postDisableMessage": "ã“ã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã‚’å†åº¦èª­ã¿è¾¼ã‚“ã§ã€æ‹¡å¼µæ©Ÿèƒ½ '{0}' ã‚’éžã‚¢ã‚¯ãƒ†ã‚£ãƒ–化ã—ã¾ã™ã‹?", - "postUninstallTooltip": "読ã¿è¾¼ã‚“ã§éžã‚¢ã‚¯ãƒ†ã‚£ãƒ–化ã™ã‚‹", + "postUninstallTooltip": "å†èª­ã¿è¾¼ã¿ã—ã¦éžã‚¢ã‚¯ãƒ†ã‚£ãƒ–化ã™ã‚‹", "postUninstallMessage": "ã“ã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã‚’å†åº¦èª­ã¿è¾¼ã‚“ã§ã€ã‚¢ãƒ³ã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«æ¸ˆã¿ã®æ‹¡å¼µæ©Ÿèƒ½ '{0}' ã‚’éžã‚¢ã‚¯ãƒ†ã‚£ãƒ–化ã—ã¾ã™ã‹?", "reload": "ウィンドウã®å†èª­ã¿è¾¼ã¿(&&R)", "toggleExtensionsViewlet": "拡張機能を表示ã™ã‚‹", @@ -55,5 +55,8 @@ "disableAll": "インストール済ã¿ã®ã™ã¹ã¦ã®æ‹¡å¼µæ©Ÿèƒ½ã‚’無効ã«ã™ã‚‹", "disableAllWorkspace": "ã“ã®ãƒ¯ãƒ¼ã‚¯ã‚¹ãƒšãƒ¼ã‚¹ã®ã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«æ¸ˆã¿ã®æ‹¡å¼µæ©Ÿèƒ½ã‚’ã™ã¹ã¦ç„¡åŠ¹ã«ã™ã‚‹", "enableAll": "インストール済ã¿ã®æ‹¡å¼µæ©Ÿèƒ½ã‚’ã™ã¹ã¦æœ‰åŠ¹ã«ã™ã‚‹", - "enableAllWorkspace": "ã“ã®ãƒ¯ãƒ¼ã‚¯ã‚¹ãƒšãƒ¼ã‚¹ã®ã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«æ¸ˆã¿ã®æ‹¡å¼µæ©Ÿèƒ½ã‚’ã™ã¹ã¦æœ‰åŠ¹ã«ã™ã‚‹" + "enableAllWorkspace": "ã“ã®ãƒ¯ãƒ¼ã‚¯ã‚¹ãƒšãƒ¼ã‚¹ã®ã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«æ¸ˆã¿ã®æ‹¡å¼µæ©Ÿèƒ½ã‚’ã™ã¹ã¦æœ‰åŠ¹ã«ã™ã‚‹", + "extensionButtonProminentBackground": "際立ã£ã¦ã„るアクション拡張機能ã®ãƒœã‚¿ãƒ³ã®èƒŒæ™¯è‰²ï¼ˆä¾‹: インストールボタン)。", + "extensionButtonProminentForeground": "際立ã£ã¦ã„るアクション拡張機能ã®ãƒœã‚¿ãƒ³ã®å‰æ™¯è‰²ï¼ˆä¾‹: インストールボタン)。", + "extensionButtonProminentHoverBackground": "際立ã£ã¦ã„るアクション拡張機能ã®ãƒœã‚¿ãƒ³ã®ãƒ›ãƒãƒ¼èƒŒæ™¯è‰²ï¼ˆä¾‹: インストールボタン)。" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/jpn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 6fd33bfb0e0..4859dfe81bb 100644 --- a/i18n/jpn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -4,8 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "disableOtherKeymapsConfirmation": "キーãƒã‚¤ãƒ³ãƒ‰é–“ã®ç«¶åˆã‚’回é¿ã™ã‚‹ãŸã‚ã«ã€ä»–ã®ã‚­ãƒ¼ãƒžãƒƒãƒ— ({0}) を無効ã«ã—ã¾ã™ã‹?", "yes": "ã¯ã„", "no": "ã„ã„ãˆ", + "betterMergeDisabled": "拡張機能 Better Merge ã¯ç¾åœ¨ãƒ“ルトインã§ã™ã€‚インストール済ã¿ã®æ‹¡å¼µæ©Ÿèƒ½ã¯ç„¡åŠ¹åŒ–ã•ã‚Œã€ã‚¢ãƒ³ã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã§ãã¾ã™ã€‚", "uninstall": "アンインストール", "later": "後続" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/jpn/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json index 08cb632b3e7..e556fff23e6 100644 --- a/i18n/jpn/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -5,6 +5,5 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.start": "キー ãƒã‚¤ãƒ³ãƒ‰ã®å®šç¾©", - "defineKeybinding.kbLayoutInfoMessage": "ç¾åœ¨ã®ã‚­ãƒ¼ãƒœãƒ¼ãƒ‰ レイアウト用ã«", "defineKeybinding.kbLayoutErrorMessage": "ç¾åœ¨ã®ã‚­ãƒ¼ãƒœãƒ¼ãƒ‰ レイアウトã§ã¯ã€ã“ã®ã‚­ãƒ¼ã®çµ„ã¿åˆã‚ã›ã‚’生æˆã™ã‚‹ã“ã¨ã¯ã§ãã¾ã›ã‚“。" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json index 8b6ad71cd4e..3902ae77527 100644 --- a/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "editorGutterModifiedBackground": "編集ã•ã‚ŒãŸè¡Œã‚’示ã™ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ä½™ç™½ã®èƒŒæ™¯è‰²ã€‚", + "editorGutterAddedBackground": "追加ã•ã‚ŒãŸè¡Œã‚’示ã™ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ä½™ç™½ã®èƒŒæ™¯è‰²ã€‚", + "editorGutterDeletedBackground": "削除ã•ã‚ŒãŸè¡Œã‚’示ã™ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ä½™ç™½ã®èƒŒæ™¯è‰²ã€‚" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index f7db07a2e2d..c0432625724 100644 --- a/i18n/jpn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,7 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0}, tasks", - "workspace": "ワークスペースã‹ã‚‰", - "extension": "拡張機能ã‹ã‚‰" + "entryAriaLabel": "{0}, tasks" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json index c7b8031b6e5..fbd42ea691d 100644 --- a/i18n/jpn/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -5,13 +5,12 @@ // Do not edit this file. It is machine generated. { "ConfigurationParser.invalidCWD": "警告: options.cwd ã¯ã€string åž‹ã§ãªã‘ã‚Œã°ãªã‚Šã¾ã›ã‚“。値 {0} を無視ã—ã¾ã™", - "ConfigurationParser.noShell": "警告: シェル構æˆãŒã‚µãƒãƒ¼ãƒˆã•ã‚Œã‚‹ã®ã¯ã€ã‚¿ãƒ¼ãƒŸãƒŠãƒ«ã§ã‚¿ã‚¹ã‚¯ã‚’実行ã—ã¦ã„ã‚‹å ´åˆã®ã¿ã§ã™ã€‚", "ConfigurationParser.noargs": "エラー: コマンド引数ã¯æ–‡å­—列ã®é…列ã§ãªã‘ã‚Œã°ãªã‚Šã¾ã›ã‚“。指定ã•ã‚ŒãŸå€¤:\n{0}", + "ConfigurationParser.noShell": "警告: シェル構æˆãŒã‚µãƒãƒ¼ãƒˆã•ã‚Œã‚‹ã®ã¯ã€ã‚¿ãƒ¼ãƒŸãƒŠãƒ«ã§ã‚¿ã‚¹ã‚¯ã‚’実行ã—ã¦ã„ã‚‹å ´åˆã®ã¿ã§ã™ã€‚", "ConfigurationParser.noName": "エラー: 宣言スコープ内ã®å•é¡Œãƒžãƒƒãƒãƒ£ãƒ¼ã«æ¬¡ã®åå‰ãŒãªã‘ã‚Œã°ãªã‚Šã¾ã›ã‚“:\n{0}\n", "ConfigurationParser.unknownMatcherKind": "警告: 定義ã•ã‚Œã¦ã„ã‚‹å•é¡Œãƒžãƒƒãƒãƒ£ãƒ¼ãŒä¸æ˜Žã§ã™ã€‚サãƒãƒ¼ãƒˆã•ã‚Œã¦ã„る型㯠string | ProblemMatcher | (string | ProblemMatcher)[] ã§ã™ã€‚\n{0}\n", "ConfigurationParser.invalidVaraibleReference": "エラー: æ­£ã—ããªã„ problemMatcher å‚ç…§ {0}\n", "ConfigurationParser.noTaskName": "エラー: タスク㌠taskName プロパティをæä¾›ã—ãªã‘ã‚Œã°ãªã‚Šã¾ã›ã‚“。ã“ã®ã‚¿ã‚¹ã‚¯ã¯ç„¡è¦–ã•ã‚Œã¾ã™ã€‚\n{0}\n", "taskConfiguration.shellArgs": "警告: タスク '{0}' ã¯ã‚·ã‚§ãƒ« コマンドã§ã™ã€‚コマンドåã¾ãŸã¯å¼•æ•°ã® 1 ã¤ã«ã€ã‚¨ã‚¹ã‚±ãƒ¼ãƒ—ã•ã‚Œã¦ã„ãªã„スペースãŒå«ã¾ã‚Œã¦ã„ã¾ã™ã€‚コマンド ラインã®å¼•ç”¨ãŒæ­£ã—ã解釈ã•ã‚Œã‚‹ã‚ˆã†ã«ã€å¼•æ•°ã‚’コマンドã«ãƒžãƒ¼ã‚¸ã—ã¦ãã ã•ã„。", - "taskConfiguration.noCommandOrDependsOn": "エラー: タスク '{0}' ã¯ã€ã‚³ãƒžãƒ³ãƒ‰ã‚‚ã€dependsOn プロパティも指定ã—ã¦ã„ã¾ã›ã‚“。ã“ã®ã‚¿ã‚¹ã‚¯ã¯ç„¡è¦–ã•ã‚Œã¾ã™ã€‚定義ã¯æ¬¡ã®ã¨ãŠã‚Šã§ã™:\n{1}", "taskConfiguration.noCommand": "エラー: タスク '{0}' ã¯ã‚³ãƒžãƒ³ãƒ‰ã‚’定義ã—ã¦ã„ã¾ã›ã‚“。ã“ã®ã‚¿ã‚¹ã‚¯ã¯ç„¡è¦–ã•ã‚Œã¾ã™ã€‚定義ã¯æ¬¡ã®ã¨ãŠã‚Šã§ã™:\n{1}" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json index fd5f48dd415..063435e42d5 100644 --- a/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -4,11 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "JsonSchema.version": "構æˆã®ãƒãƒ¼ã‚¸ãƒ§ãƒ³ç•ªå·", - "JsonSchema.windows": "Windows 固有ã®ã‚³ãƒžãƒ³ãƒ‰æ§‹æˆ", - "JsonSchema.mac": "Mac 固有ã®ã‚³ãƒžãƒ³ãƒ‰æ§‹æˆ", - "JsonSchema.linux": "Linux 固有ã®ã‚³ãƒžãƒ³ãƒ‰æ§‹æˆ", "JsonSchema.shell": "コマンドãŒã‚·ã‚§ãƒ« コマンドã‹å¤–部プログラムã‹ã‚’指定ã—ã¾ã™ã€‚çœç•¥ã™ã‚‹ã¨ã€æ—¢å®šã¯ false ã«ãªã‚Šã¾ã™ã€‚", "JsonSchema.tasks.dependsOn.string": "ã“ã®ã‚¿ã‚¹ã‚¯ãŒä¾å­˜ã—ã¦ã„る別ã®ã‚¿ã‚¹ã‚¯ã€‚", - "JsonSchema.tasks.dependsOn.array": "ã“ã®ã‚¿ã‚¹ã‚¯ãŒä¾å­˜ã—ã¦ã„ã‚‹ä»–ã®è¤‡æ•°ã®ã‚¿ã‚¹ã‚¯ã€‚" + "JsonSchema.tasks.dependsOn.array": "ã“ã®ã‚¿ã‚¹ã‚¯ãŒä¾å­˜ã—ã¦ã„ã‚‹ä»–ã®è¤‡æ•°ã®ã‚¿ã‚¹ã‚¯ã€‚", + "JsonSchema.windows": "Windows 固有ã®ã‚³ãƒžãƒ³ãƒ‰æ§‹æˆ", + "JsonSchema.mac": "Mac 固有ã®ã‚³ãƒžãƒ³ãƒ‰æ§‹æˆ", + "JsonSchema.linux": "Linux 固有ã®ã‚³ãƒžãƒ³ãƒ‰æ§‹æˆ" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index eba406025bb..c30717a4d73 100644 --- a/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -25,7 +25,5 @@ "welcomePage.extensionListSeparator": ",", "welcomePage.installedExtension": "{0} (インストール済ã¿) ", "ok": "OK", - "cancel": "キャンセル", - "welcomePage.quickLinkBackground": "ウェルカム ページã®ã‚¯ã‚¤ãƒƒã‚¯ リンクã®èƒŒæ™¯è‰²ã€‚", - "welcomePage.quickLinkHoverBackground": "ウェルカム ページã®ã‚¯ã‚¤ãƒƒã‚¯ リンクã®ãƒ›ãƒãƒ¼èƒŒæ™¯è‰²ã€‚" + "cancel": "キャンセル" } \ No newline at end of file diff --git a/i18n/kor/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/kor/extensions/typescript/out/utils/typingsStatus.i18n.json index 07c376496cf..bba27308a23 100644 --- a/i18n/kor/extensions/typescript/out/utils/typingsStatus.i18n.json +++ b/i18n/kor/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -5,7 +5,6 @@ // Do not edit this file. It is machine generated. { "installingPackages": "TypeScript IntelliSense를 í–¥ìƒí•˜ê¸° 위해 ë°ì´í„°ë¥¼ 페치하는 중", - "typesInstallerInitializationFailed.title": "JavaScript 언어 ê¸°ëŠ¥ì— ëŒ€í•´ ìž…ë ¥ 파ì¼ì„ 설치할 수 없습니다. NPMì´ ì„¤ì¹˜ë˜ì–´ 있고 PATHì— ìžˆëŠ”ì§€ 확ì¸í•˜ì„¸ìš”.", "typesInstallerInitializationFailed.moreInformation": "추가 ì •ë³´", "typesInstallerInitializationFailed.doNotCheckAgain": "다시 í™•ì¸ ì•ˆ 함", "typesInstallerInitializationFailed.close": "닫기" diff --git a/i18n/kor/extensions/typescript/package.i18n.json b/i18n/kor/extensions/typescript/package.i18n.json index 4e1ce76b213..348ff9b8498 100644 --- a/i18n/kor/extensions/typescript/package.i18n.json +++ b/i18n/kor/extensions/typescript/package.i18n.json @@ -36,6 +36,5 @@ "typescript.implementationsCodeLens.enabled": "구현 CodeLens를 사용하거나 사용하지 ì•Šë„ë¡ ì„¤ì •í•©ë‹ˆë‹¤. TypeScript >= 2.2.0ì´ í•„ìš”í•©ë‹ˆë‹¤.", "typescript.selectTypeScriptVersion.title": "TypeScript 버전 ì„ íƒ", "jsDocCompletion.enabled": "ìžë™ JSDoc ì£¼ì„ ì‚¬ìš©/사용 안 함", - "javascript.implicitProjectConfig.checkJs": "JavaScript 파ì¼ì˜ ì˜ë¯¸ 체계 검사를 사용/사용하지 않습니다. 기존 jsconfig.json ë˜ëŠ” tsconfig.json 파ì¼ì€ ì´ ì„¤ì •ì„ ìž¬ì •ì˜í•©ë‹ˆë‹¤. TypeScript >=2.3.1ì´ í•„ìš”í•©ë‹ˆë‹¤. ", - "typescript.check.npmIsInstalled": "ìžë™ ìž…ë ¥ ì¸ì‹ì— 대해 NPMì´ ì„¤ì¹˜ë˜ì–´ 있는지 확ì¸" + "javascript.implicitProjectConfig.checkJs": "JavaScript 파ì¼ì˜ ì˜ë¯¸ 체계 검사를 사용/사용하지 않습니다. 기존 jsconfig.json ë˜ëŠ” tsconfig.json 파ì¼ì€ ì´ ì„¤ì •ì„ ìž¬ì •ì˜í•©ë‹ˆë‹¤. TypeScript >=2.3.1ì´ í•„ìš”í•©ë‹ˆë‹¤. " } \ No newline at end of file diff --git a/i18n/kor/src/vs/code/electron-main/menus.i18n.json b/i18n/kor/src/vs/code/electron-main/menus.i18n.json index a8faf00b858..b293d481517 100644 --- a/i18n/kor/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/kor/src/vs/code/electron-main/menus.i18n.json @@ -148,12 +148,12 @@ "miLicense": "ë¼ì´ì„ ìŠ¤ 보기(&&L)", "miPrivacyStatement": "ê°œì¸ì •ë³´ì²˜ë¦¬ë°©ì¹¨(&&P)", "miAbout": "ì •ë³´(&&A)", + "accessibilityOptionsWindowTitle": "접근성 옵션", "miRestartToUpdate": "ì—…ë°ì´íŠ¸í•˜ê¸° 위해 다시 시작...", "miCheckingForUpdates": "ì—…ë°ì´íŠ¸ë¥¼ 확ì¸í•˜ëŠ” 중...", "miDownloadUpdate": "사용 가능한 ì—…ë°ì´íŠ¸ 다운로드", "miDownloadingUpdate": "ì—…ë°ì´íŠ¸ë¥¼ 다운로드하는 중...", "miInstallingUpdate": "ì—…ë°ì´íŠ¸ë¥¼ 설치하는 중...", - "miCheckForUpdates": "ì—…ë°ì´íŠ¸ 확ì¸...", "aboutDetail": "\n버전 {0}\n커밋 {1}\n날짜 {2}\nì…¸{3}\në Œë”러 {4}\nNode {5}", "okButton": "확ì¸" } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/kor/src/vs/workbench/api/node/extHostTask.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/kor/src/vs/workbench/api/node/extHostTask.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/common/theme.i18n.json b/i18n/kor/src/vs/workbench/common/theme.i18n.json index ca6f547f854..182ceaa205e 100644 --- a/i18n/kor/src/vs/workbench/common/theme.i18n.json +++ b/i18n/kor/src/vs/workbench/common/theme.i18n.json @@ -7,12 +7,9 @@ "tabActiveBackground": "활성 탭 배경색입니다. íƒ­ì€ íŽ¸ì§‘ê¸° ì˜ì—­ì—ì„œ íŽ¸ì§‘ê¸°ì˜ ì»¨í…Œì´ë„ˆìž…니다. í•œ 편집기 그룹ì—ì„œ 여러 íƒ­ì„ ì—´ 수 있습니다. 여러 편집기 ê·¸ë£¹ì´ ìžˆì„ ìˆ˜ 있습니다.", "tabInactiveBackground": "비활성 탭 배경색입니다. íƒ­ì€ íŽ¸ì§‘ê¸° ì˜ì—­ì—ì„œ íŽ¸ì§‘ê¸°ì˜ ì»¨í…Œì´ë„ˆìž…니다. í•œ 편집기 그룹ì—ì„œ 여러 íƒ­ì„ ì—´ 수 있습니다. 여러 편집기 ê·¸ë£¹ì´ ìžˆì„ ìˆ˜ 있습니다.", "tabBorder": "íƒ­ì„ ì„œë¡œ 구분하기 위한 í…Œë‘리입니다. íƒ­ì€ íŽ¸ì§‘ê¸° ì˜ì—­ì—ì„œ íŽ¸ì§‘ê¸°ì˜ ì»¨í…Œì´ë„ˆìž…니다. í•œ 편집기 ê·¸ë£¹ì— ì—¬ëŸ¬ íƒ­ì„ ì—´ 수 있습니다. 여러 편집기 ê·¸ë£¹ì´ ìžˆì„ ìˆ˜ 있습니다.", - "tabActiveEditorGroupActiveForeground": "활성 ê·¸ë£¹ì˜ í™œì„± 탭 전경색입니다. íƒ­ì€ íŽ¸ì§‘ê¸° ì˜ì—­ì—ì„œ íŽ¸ì§‘ê¸°ì˜ ì»¨í…Œì´ë„ˆìž…니다. í•œ 편집기 그룹ì—ì„œ 여러 íƒ­ì„ ì—´ 수 있습니다. 여러 편집기 ê·¸ë£¹ì´ ìžˆì„ ìˆ˜ 있습니다.", - "tabInactiveEditorGroupActiveForeground": "활성 ê·¸ë£¹ì˜ ë¹„í™œì„± 탭 전경색입니다. íƒ­ì€ íŽ¸ì§‘ê¸° ì˜ì—­ì—ì„œ íŽ¸ì§‘ê¸°ì˜ ì»¨í…Œì´ë„ˆìž…니다. í•œ 편집기 그룹ì—ì„œ 여러 íƒ­ì„ ì—´ 수 있습니다. 여러 편집기 ê·¸ë£¹ì´ ìžˆì„ ìˆ˜ 있습니다.", "editorGroupBackground": "편집기 ê·¸ë£¹ì˜ ë°°ê²½ìƒ‰ìž…ë‹ˆë‹¤. 편집기 ê·¸ë£¹ì€ íŽ¸ì§‘ê¸°ì˜ ì»¨í…Œì´ë„ˆìž…니다. ë°°ê²½ìƒ‰ì€ íŽ¸ì§‘ê¸° ê·¸ë£¹ì„ ëŒ ë•Œ 표시ë©ë‹ˆë‹¤.", "editorGroupHeaderBackground": "íƒ­ì„ ì‚¬ìš©í•˜ì§€ ì•Šë„ë¡ ì„¤ì •í•œ 경우 편집기 그룹 제목 ë¨¸ë¦¬ê¸€ì˜ ë°°ê²½ìƒ‰ìž…ë‹ˆë‹¤. 편집기 ê·¸ë£¹ì€ íŽ¸ì§‘ê¸°ì˜ ì»¨í…Œì´ë„ˆìž…니다.", "editorGroupBorder": "여러 편집기 ê·¸ë£¹ì„ ì„œë¡œ 구분하기 위한 색입니다. 편집기 ê·¸ë£¹ì€ íŽ¸ì§‘ê¸°ì˜ ì»¨í…Œì´ë„ˆìž…니다.", - "panelBackground": "íŒ¨ë„ ë°°ê²½ìƒ‰ìž…ë‹ˆë‹¤. 패ë„ì€ íŽ¸ì§‘ê¸° ì˜ì—­ ì•„ëž˜ì— í‘œì‹œë˜ë©° 출력 ë° í†µí•© í„°ë¯¸ë„ ê°™ì€ ë³´ê¸°ê°€ í¬í•¨ë©ë‹ˆë‹¤.", "panelBorder": "편집기와 구분ë˜ëŠ” 맨 ìœ„ì˜ íŒ¨ë„ í…Œë‘리 색입니다. 패ë„ì€ íŽ¸ì§‘ê¸° ì˜ì—­ ì•„ëž˜ì— í‘œì‹œë˜ë©° 출력 ë° í†µí•© í„°ë¯¸ë„ ê°™ì€ ë³´ê¸°ê°€ í¬í•¨ë©ë‹ˆë‹¤.", "panelActiveTitleForeground": "활성 패ë„ì˜ ì œëª© 색입니다. 패ë„ì€ íŽ¸ì§‘ê¸° ì˜ì—­ ì•„ëž˜ì— í‘œì‹œë˜ë©° 출력 ë° í†µí•© í„°ë¯¸ë„ ê°™ì€ ë³´ê¸°ê°€ í¬í•¨ë©ë‹ˆë‹¤.", "panelInactiveTitleForeground": "비활성 패ë„ì˜ ì œëª© 색입니다. 패ë„ì€ íŽ¸ì§‘ê¸° ì˜ì—­ ì•„ëž˜ì— í‘œì‹œë˜ë©° 출력 ë° í†µí•© í„°ë¯¸ë„ ê°™ì€ ë³´ê¸°ê°€ í¬í•¨ë©ë‹ˆë‹¤.", diff --git a/i18n/kor/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/kor/src/vs/workbench/electron-browser/workbench.i18n.json index 8b6ad71cd4e..de8d40eec3b 100644 --- a/i18n/kor/src/vs/workbench/electron-browser/workbench.i18n.json +++ b/i18n/kor/src/vs/workbench/electron-browser/workbench.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "developer": "개발ìž", + "file": "파ì¼" +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json b/i18n/kor/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json index d56a0b492cd..a864dd07491 100644 --- a/i18n/kor/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json @@ -5,8 +5,8 @@ // Do not edit this file. It is machine generated. { "snapshotObj": "ì´ ê°œì²´ì— ëŒ€í•œ 기본 값만 표시ë©ë‹ˆë‹¤.", - "debuggingStarted": "디버그가 시작ë˜ì—ˆìŠµë‹ˆë‹¤.", "debuggingPaused": "디버그가 ì¼ì‹œ 중지ë˜ì—ˆìŠµë‹ˆë‹¤. ì´ìœ  {0}, {1} {2}", + "debuggingStarted": "디버그가 시작ë˜ì—ˆìŠµë‹ˆë‹¤.", "debuggingStopped": "디버그가 중지ë˜ì—ˆìŠµë‹ˆë‹¤.", "breakpointAdded": "íŒŒì¼ {1}, 줄 {0}ì— ì¤‘ë‹¨ì ì´ 추가ë˜ì—ˆìŠµë‹ˆë‹¤.", "breakpointRemoved": "íŒŒì¼ {1}, 줄 {0}ì—ì„œ 중단ì ì´ 제거ë˜ì—ˆìŠµë‹ˆë‹¤.", diff --git a/i18n/kor/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/kor/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json index d03c1ba3ba2..fee497eeb33 100644 --- a/i18n/kor/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -5,6 +5,5 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.start": "키 ë°”ì¸ë”© ì •ì˜", - "defineKeybinding.kbLayoutInfoMessage": "현재 ìžíŒ ë°°ì—´ì˜ ê²½ìš° 다ìŒì„ 누르세요.", "defineKeybinding.kbLayoutErrorMessage": "현재 ìžíŒ ë°°ì—´ì—서는 ì´ í‚¤ ì¡°í•©ì„ ìƒì„±í•  수 없습니다." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/kor/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json index cf0d425f7fd..e34db9894ef 100644 --- a/i18n/kor/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -5,13 +5,12 @@ // Do not edit this file. It is machine generated. { "ConfigurationParser.invalidCWD": "경고: options.cwd는 string 형ì‹ì´ì–´ì•¼ 합니다. {0} ê°’ì„ ë¬´ì‹œí•©ë‹ˆë‹¤.\n", - "ConfigurationParser.noShell": "경고: ì…¸ êµ¬ì„±ì€ ìž‘ì—…ì„ í„°ë¯¸ë„ì—ì„œ 실행 ì¤‘ì¼ ë•Œì—만 지ì›ë©ë‹ˆë‹¤.", "ConfigurationParser.noargs": "오류: 명령 ì¸ìˆ˜ëŠ” 문ìžì—´ì˜ ë°°ì—´ì´ì–´ì•¼ 합니다. ì œê³µëœ ê°’:\n{0}", + "ConfigurationParser.noShell": "경고: ì…¸ êµ¬ì„±ì€ ìž‘ì—…ì„ í„°ë¯¸ë„ì—ì„œ 실행 ì¤‘ì¼ ë•Œì—만 지ì›ë©ë‹ˆë‹¤.", "ConfigurationParser.noName": "오류: ì„ ì–¸ 범위 ë‚´ì˜ ë¬¸ì œ ì„ íƒê¸°ëŠ” ì´ë¦„ì´ ìžˆì–´ì•¼ 합니다.\n{0}\n", "ConfigurationParser.unknownMatcherKind": "경고: ì •ì˜ëœ 문제 ì„ íƒê¸°ë¥¼ ì•Œ 수 없습니다. 지ì›ë˜ëŠ” 형ì‹ì€ string | ProblemMatcher |(string | ProblemMatcher)[]입니다.\n{0}\n", "ConfigurationParser.invalidVaraibleReference": "오류: ìž˜ëª»ëœ problemMatcher 참조: {0}\n", "ConfigurationParser.noTaskName": "오류: ìž‘ì—…ì—ì„œ taskName ì†ì„±ì„ 제공해야 합니다. ì´ ìž‘ì—…ì€ ë¬´ì‹œë©ë‹ˆë‹¤.\n{0}\n", "taskConfiguration.shellArgs": "경고: ìž‘ì—… '{0}'ì€(는) ì…¸ 명령ì´ë©°, 명령 ì´ë¦„ì´ë‚˜ ì¸ìˆ˜ 중 í•˜ë‚˜ì— ì´ìŠ¤ì¼€ì´í”„ë˜ì§€ ì•Šì€ ê³µë°±ì´ ìžˆìŠµë‹ˆë‹¤. 명령줄 ì¸ìš©ì„ 올바르게 하려면 ì¸ìˆ˜ë¥¼ 명령으로 병합하세요.", - "taskConfiguration.noCommandOrDependsOn": "오류: ìž‘ì—… '{0}'ì—ì„œ 명령ì´ë‚˜ dependsOn ì†ì„±ì„ 지정하지 않습니다. ì´ ìž‘ì—…ì€ ë¬´ì‹œë©ë‹ˆë‹¤. 해당 ìž‘ì—…ì˜ ì •ì˜ëŠ”:\n{1}입니다.", "taskConfiguration.noCommand": "오류: ìž‘ì—… '{0}'ì—ì„œ ëª…ë ¹ì„ ì •ì˜í•˜ì§€ 않습니다. ì´ ìž‘ì—…ì€ ë¬´ì‹œë©ë‹ˆë‹¤. 해당 ìž‘ì—…ì˜ ì •ì˜ëŠ”\n{1}입니다." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json index 9ae6b6172e5..13d620361aa 100644 --- a/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -4,11 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "JsonSchema.version": "êµ¬ì„±ì˜ ë²„ì „ 번호입니다.", - "JsonSchema.windows": "Windows 특정 명령 구성", - "JsonSchema.mac": "Mac 특정 명령 구성", - "JsonSchema.linux": "Linux 특정 명령 구성", "JsonSchema.shell": "ëª…ë ¹ì´ ì…¸ 명령ì¸ì§€ 외부 프로그램ì¸ì§€ 여부를 지정합니다. ìƒëžµí•˜ë©´ 기본값 falseê°€ 사용ë©ë‹ˆë‹¤.", "JsonSchema.tasks.dependsOn.string": "ì´ ìž‘ì—…ì´ ì¢…ì†ëœ ë˜ ë‹¤ë¥¸ 작업입니다.", - "JsonSchema.tasks.dependsOn.array": "ì´ ìž‘ì—…ì´ ì¢…ì†ëœ 다른 여러 작업입니다." + "JsonSchema.tasks.dependsOn.array": "ì´ ìž‘ì—…ì´ ì¢…ì†ëœ 다른 여러 작업입니다.", + "JsonSchema.windows": "Windows 특정 명령 구성", + "JsonSchema.mac": "Mac 특정 명령 구성", + "JsonSchema.linux": "Linux 특정 명령 구성" } \ No newline at end of file diff --git a/i18n/ptb/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json b/i18n/ptb/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json index 74a80b4280d..3ffec1c5e87 100644 --- a/i18n/ptb/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json +++ b/i18n/ptb/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json @@ -6,9 +6,9 @@ { "activeEditorShort": "e.g. meuArquivo.txt", "activeEditorMedium": "e.g. minhaPasta/meuArquivo.txt", - "activeEditorLong": "e.g. /Usuarios/Desenvolvimento/meuProjeto/minhaPasta/meuArquivo.txt", + "activeEditorLong": "por exemplo /Usuários/Desenvolvimento/meuProjeto/minhaPasta/meuArquivo/txt", "rootName": "e.g. meuProjeto", - "rootPath": "e.g. /Usuarios/Desenvolvimento/meuProjeto", + "rootPath": "por exemplo /Usuários/desenvolvimento/meuProjeto", "appName": "e.g. VS Code", "dirty": "Um indicador de alteração se o editor ativo foi alterado", "separator": "um separador condicional (' - ') que somente é mostrado quando envolvido por variáveis com valores", diff --git a/i18n/ptb/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/ptb/extensions/merge-conflict/out/codelensProvider.i18n.json index dd5a316f1a1..8b6ad71cd4e 100644 --- a/i18n/ptb/extensions/merge-conflict/out/codelensProvider.i18n.json +++ b/i18n/ptb/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -3,9 +3,4 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{ - "acceptCurrentChange": "Aceitar a mudança atual", - "acceptIncomingChange": "Aceitar a mudança de entrada", - "acceptBothChanges": "Aceitar ambas alterações", - "compareChanges": "Comparar alteracões" -} \ No newline at end of file +{} \ No newline at end of file diff --git a/i18n/ptb/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/ptb/extensions/merge-conflict/out/commandHandler.i18n.json index ee80b2e1905..231dd1e64b1 100644 --- a/i18n/ptb/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/ptb/extensions/merge-conflict/out/commandHandler.i18n.json @@ -5,7 +5,6 @@ // Do not edit this file. It is machine generated. { "cursorNotInConflict": "Cursor do editor não está dentro de um conflito de mesclagem", - "compareChangesTitle": "{0}: Mudanças atuais \\u2194 alterações de entrada ", "cursorOnSplitterRange": "Cursor do editor está dentro do separador de conflitos de mesclagem, por favor mova-o para o bloco \"atual\" ou \"entrada\"", "noConflicts": "Nenhum conflito de mesclagem encontrado neste arquivo", "noOtherConflictsInThisFile": "Não há outros conflitos de mesclagem dentro desse arquivo" diff --git a/i18n/ptb/extensions/merge-conflict/package.i18n.json b/i18n/ptb/extensions/merge-conflict/package.i18n.json index b290f272513..1ca50299264 100644 --- a/i18n/ptb/extensions/merge-conflict/package.i18n.json +++ b/i18n/ptb/extensions/merge-conflict/package.i18n.json @@ -5,15 +5,7 @@ // Do not edit this file. It is machine generated. { "command.category": "Conflito de Mesclagem", - "command.accept.all-incoming": "Aceitar todas as novas entradas", - "command.accept.all-both": "Aceitar Ambos", - "command.accept.current": "Aceitar a atual", - "command.accept.incoming": "Aceitar as novas entradas", - "command.accept.selection": "Aceitar a seleção", "command.accept.both": "Aceitar Ambos", - "command.next": "Próximo conflito", - "command.previous": "Conflito anterior", - "command.compare": "Comparar o conflito atual", "config.title": "Mesclar conflitos", "config.codeLensEnabled": "Habilitar/Desabilitar o conflito de mesclagem no bloco CodeLens dentro do editor", "config.decoratorsEnabled": "Habilitar/Desabilitar decoradores de mesclagem de conflitos dentro do editor" diff --git a/i18n/ptb/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/ptb/extensions/typescript/out/utils/typingsStatus.i18n.json index ce050eb3d8e..4ba4da55a07 100644 --- a/i18n/ptb/extensions/typescript/out/utils/typingsStatus.i18n.json +++ b/i18n/ptb/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -5,7 +5,6 @@ // Do not edit this file. It is machine generated. { "installingPackages": "Buscando dados para melhor IntelliSense do TypeScript", - "typesInstallerInitializationFailed.title": "Não foi possível instalar arquivos de digitação para recursos da linguagem JavaScript. Certifique-se que NPM está instalado e está em seu caminho", "typesInstallerInitializationFailed.moreInformation": "Mais informações", "typesInstallerInitializationFailed.doNotCheckAgain": "Não verificar novamente", "typesInstallerInitializationFailed.close": "Fechar" diff --git a/i18n/ptb/extensions/typescript/package.i18n.json b/i18n/ptb/extensions/typescript/package.i18n.json index 74b4568f8b9..e46048cba4a 100644 --- a/i18n/ptb/extensions/typescript/package.i18n.json +++ b/i18n/ptb/extensions/typescript/package.i18n.json @@ -41,6 +41,6 @@ "typescript.selectTypeScriptVersion.title": "Selecionar a versão do JavaScript", "jsDocCompletion.enabled": "Habilitar/Desabilitar comentários JSDoc automáticos.", "javascript.implicitProjectConfig.checkJs": "Habilitar/desabilitar verificação semântica de arquivos JavaScript. Os arquivos existentes jsconfig.json ou tsconfig.json substituem essa configuração. Requer TypeScript > = 2.3.1.", - "typescript.check.npmIsInstalled": "Verificar se NPM está instalado para aquisição automática de digitação", - "javascript.nameSuggestions": "Habilitar/desabilitar incluindo nomes exclusivos do arquivo nas listas de sugestão de JavaScript." + "javascript.nameSuggestions": "Habilitar/desabilitar incluindo nomes exclusivos do arquivo nas listas de sugestão de JavaScript.", + "typescript.tsc.autoDetect": "Controla se a auto-detecção de tarefas tsc estão ligadas ou desligadas." } \ No newline at end of file diff --git a/i18n/ptb/src/vs/code/electron-main/menus.i18n.json b/i18n/ptb/src/vs/code/electron-main/menus.i18n.json index 85312962c12..2a3b275d70d 100644 --- a/i18n/ptb/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/ptb/src/vs/code/electron-main/menus.i18n.json @@ -153,12 +153,12 @@ "miLicense": "&&Exibir Licença", "miPrivacyStatement": "&&Política de Privacidade", "miAbout": "&&Sobre", + "accessibilityOptionsWindowTitle": "Opções de Acessibilidade", "miRestartToUpdate": "Reinicie para Atualizar...", "miCheckingForUpdates": "Verificando Atualizações...", "miDownloadUpdate": "Baixar Atualização Disponível", "miDownloadingUpdate": "Baixando Atualização...", "miInstallingUpdate": "Instalando Atualização...", - "miCheckForUpdates": "Verificar Atualizações...", - "aboutDetail": "\\\\nVersão {0}\\\\nConfirmação {1}\\\\nData {2}\\\\nShell {3}\\\\nRenderizador {4}\\\\nNó {5}", + "aboutDetail": "\nVersão {0}\nConfirmação {1}\nData {2}\nShell {3}\nRenderizador {4}\nNó {5}", "okButton": "OK" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/ptb/src/vs/editor/common/config/commonEditorConfig.i18n.json index 32deba05d12..7de4c179900 100644 --- a/i18n/ptb/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/ptb/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -33,7 +33,6 @@ "wordWrapColumn": "Controla a coluna de quebra de linha do editor quando editor.wordWrap` é 'wordWrapColumn' ou 'bounded'.", "wrappingIndent": "Controla o recuo de linhas quebradas. Pode ser \"none\", \"same\" ou \"indent\".", "mouseWheelScrollSensitivity": "Um multiplicador a ser usado em \"deltaX\" e \"deltaY\" dos eventos de rolagem do botão de rolagem do mouse", - "multicursorModifier": "O modificador a ser utilizado para adicionar vários cursores com o mouse.", "quickSuggestions.strings": "Habilitar sugestões rápidas dentro de strings.", "quickSuggestions.comments": "Habilitar sugestões rápidas dentro de comentários.", "quickSuggestions.other": "Habilitar sugestões rápidas fora de strings e comentários.", diff --git a/i18n/ptb/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/ptb/src/vs/platform/theme/common/colorRegistry.i18n.json index 64d68304f98..ca84c495b32 100644 --- a/i18n/ptb/src/vs/platform/theme/common/colorRegistry.i18n.json +++ b/i18n/ptb/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -60,7 +60,6 @@ "editorBackground": "Cor de plano de fundo do editor.", "editorForeground": "Cor de primeiro plano padrão do editor.", "editorWidgetBackground": "Cor de plano de fundo das ferramentas de edição, como pesquisar/substituir.", - "editorWidgetBorder": "Cor da borda da ferramenta editor.", "editorSelection": "Cor de seleção do editor.", "editorInactiveSelection": "Cor de seleção em um editor inativo.", "editorSelectionHighlight": "Cor de regiões com o mesmo conteúdo da seleção.", @@ -74,5 +73,11 @@ "diffEditorInserted": "Cor de fundo para texto que foi inserido.", "diffEditorRemoved": "Cor de fundo para texto que foi removido.", "diffEditorInsertedOutline": "Cor de contorno para o texto que foi inserido.", - "diffEditorRemovedOutline": "Cor de contorno para o texto que foi removido." + "diffEditorRemovedOutline": "Cor de contorno para o texto que foi removido.", + "mergeCurrentHeaderBackground": "Cor de fundo de cabeçalho atual em conflito de mesclagem em linha.", + "mergeCurrentContentBackground": "Cor de fundo de conteúdo atual em conflito de mesclagem em linha.", + "mergeIncomingHeaderBackground": "Cor de fundo de cabeçalho de entrada em conflito de mesclagem em linha.", + "mergeIncomingContentBackground": "Cor de fundo de conteúdo de entrada em conflito de mesclagem em linha.", + "overviewRulerCurrentContentForeground": "Cor de fundo de régua de visuaização atual em conflito de mesclagem em linha.", + "overviewRulerIncomingContentForeground": "Cor de fundo de régua de visuaização de entrada em conflito de mesclagem em linha." } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/ptb/src/vs/workbench/api/node/extHostTask.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ptb/src/vs/workbench/api/node/extHostTask.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/common/theme.i18n.json b/i18n/ptb/src/vs/workbench/common/theme.i18n.json index 635ace8d708..0ba78701559 100644 --- a/i18n/ptb/src/vs/workbench/common/theme.i18n.json +++ b/i18n/ptb/src/vs/workbench/common/theme.i18n.json @@ -7,15 +7,12 @@ "tabActiveBackground": "Cor de fundo da guia ativa. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", "tabInactiveBackground": "Cor de fundo da guia inativa. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", "tabBorder": "Borda para separar uma guia das outras. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", - "tabActiveEditorGroupActiveForeground": "Cor de primeiro plano da guia ativa em um grupo ativo. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", - "tabInactiveEditorGroupActiveForeground": "Cor de primeiro plano da guia inativa em um grupo ativo. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", "editorGroupBackground": "Cor de fundo de um grupo de editor. Grupos de editor são os recipientes dos editores. A cor de fundo é mostrada ao arrastar o editor de grupos ao redor.", "tabsContainerBackground": "Cor de fundo do cabeçalho do título do grupo de editor quando as guias são habilitadas. Grupos de editor são os recipientes dos editores.", "tabsContainerBorder": "Cor da borda do cabeçalho do título do grupo de editor quando as guias estão habilitadas. Grupos de editor são os recipientes dos editores.", "editorGroupHeaderBackground": "Cor de fundo do título do cabeçalho do grupo de editor quando as guias são desabilitadas. Grupos de editor são os recipientes dos editores.", "editorGroupBorder": "Cor para separar múltiplos grupos de editor de outro. Grupos de editor são os recipientes dos editores.", "editorDragAndDropBackground": "Cor de fundo ao arrastar editores. A cor deve ter transparência para que o conteúdo do editor ainda possa ser visto.", - "panelBackground": "Cor de fundo do painel. Os painéis são mostrados abaixo da área do editor e contém visualizações como saída e terminal integrado.", "panelBorder": "Cor da borda do painel no topo separando do editor. Os painéis são mostrados abaixo da área do editor e contém visualizações como saída e terminal integrado.", "panelActiveTitleForeground": "Cor do título para o painel ativo. Os painéis são mostrados abaixo da área do editor e contém visualizações como saída e terminal integrado.", "panelInactiveTitleForeground": "Cor do título para o painel inativo. Os painéis são mostrados abaixo da área do editor e contém visualizações como saída e terminal integrado.", diff --git a/i18n/ptb/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/ptb/src/vs/workbench/electron-browser/workbench.i18n.json index 8b6ad71cd4e..46bdaa6720d 100644 --- a/i18n/ptb/src/vs/workbench/electron-browser/workbench.i18n.json +++ b/i18n/ptb/src/vs/workbench/electron-browser/workbench.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "developer": "Desenvolvedor", + "file": "Arquivo" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json index 6dc0bc48afb..de6d591510a 100644 --- a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json @@ -5,8 +5,8 @@ // Do not edit this file. It is machine generated. { "snapshotObj": "Apenas valores primitivos são mostrados para este objeto.", - "debuggingStarted": "Depuração Iniciada.", "debuggingPaused": "Depuração pausada, razão {0}, {1} {2}", + "debuggingStarted": "Depuração Iniciada.", "debuggingStopped": "Depuração parada.", "breakpointAdded": "Adicionado ponto de interrupção, linha {0}, arquivo {1}", "breakpointRemoved": "Ponto de interrupção removido, linha {0}, arquivo {1}", diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json index 7f32e3bf156..1caebe040f5 100644 --- a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json @@ -9,6 +9,5 @@ "emmetPreferences": "Preferências usadas para modificar o comportamento de algumas ações e resolvedores de Emmet.", "emmetSyntaxProfiles": "Definir o perfil para a sintaxe especificada ou usar seu próprio perfil com regras específicas.", "emmetExclude": "Uma matriz de línguagens onde abreviaturas emmet não devem ser expandidas.", - "emmetExtensionsPath": "Caminho para uma pasta contendo perfis emmet, trechos e preferências", - "emmetUseModules": "Use os novos módulos emmet para características emmet ao invés da biblioteca emmet única." + "emmetExtensionsPath": "Caminho para uma pasta contendo perfis emmet, trechos e preferências" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 7e8cde2d602..e1aa51729e5 100644 --- a/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -4,6 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "disableOtherKeymapsConfirmation": "Desabilitar outros mapeamentos de teclado ({0}) para evitar conflitos entre as combinações de teclas?", "yes": "Sim", "no": "Não", "betterMergeDisabled": "A extensão Better Merge agora é intrínseca, a extensão instalada foi desabilitada e pode ser desinstalada.", diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json index 15fd432f9fa..a4aa8b55e2f 100644 --- a/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -5,6 +5,5 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.start": "Definir Keybinding", - "defineKeybinding.kbLayoutInfoMessage": "Para o seu layout de teclado atual pressionar", "defineKeybinding.kbLayoutErrorMessage": "Você não será capaz de produzir esta combinação de teclas sob seu layout de teclado atual." } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json index 8b6ad71cd4e..1cb8d16e566 100644 --- a/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "editorGutterModifiedBackground": "Cor de fundo da dobra do editor para as linhas que estão modificadas.", + "editorGutterAddedBackground": "Cor de fundo da dobra do editor para as linhas que estão adicionadas.", + "editorGutterDeletedBackground": "Cor de fundo da dobra do editor para as linhas que estão excluídas." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index be3fefb5d3d..32bbf24976b 100644 --- a/i18n/ptb/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,7 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0}, tarefas", - "workspace": "Do espaço de trabalho", - "extension": "De extensões" + "entryAriaLabel": "{0}, tarefas" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json index 2de0b161ac8..45308919a6e 100644 --- a/i18n/ptb/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -5,13 +5,12 @@ // Do not edit this file. It is machine generated. { "ConfigurationParser.invalidCWD": "Aviso: options.cwd deve ser do tipo string. Ignorando valor {0}\n", - "ConfigurationParser.noShell": "Aviso: A configuração do shell somente é suportada quando estiver executando tarefas no terminal.", "ConfigurationParser.noargs": "Erro: Argumentos do comando devem ser uma matriz de strings. Valor informado é:\n{0}", + "ConfigurationParser.noShell": "Aviso: A configuração do shell somente é suportada quando estiver executando tarefas no terminal.", "ConfigurationParser.noName": "Erro: Problem Matcher no escopo declarado deve ter um nome:\n{0}\n", "ConfigurationParser.unknownMatcherKind": "Aviso: a correspondência de problema definido é desconhecido. Tipos suportados são string | ProblemMatcher | (string | ProblemMatcher)[].\n{0}\n", "ConfigurationParser.invalidVaraibleReference": "Erro: ProblemMatcher inválido referência: {0}\n", "ConfigurationParser.noTaskName": "Erro: tarefas devem fornecer uma propriedade taskName. A tarefa será ignorada.\n{0}\n", "taskConfiguration.shellArgs": "Aviso: a tarefa '{0}' é um comando do shell e o nome de comando ou um dos seus argumentos tem espaços sem escape. Para garantir a linha de comando correta por favor mesclar argumentos no comando.", - "taskConfiguration.noCommandOrDependsOn": "Erro: a tarefa '{0}' também não especifica um comando ou uma propriedade dependsOn. A tarefa será ignorada. Sua definição é: {1}", "taskConfiguration.noCommand": "Erro: a tarefa '{0}' não define um comando. A tarefa será ignorada. Sua definição é: {1}" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json index 3130e474d7e..9010242ce87 100644 --- a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -4,11 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "JsonSchema.version": "Número da versão do config", - "JsonSchema.windows": "Configuração de comando específica do Windows", - "JsonSchema.mac": "Configuração de comando específica do Mac", - "JsonSchema.linux": "Configuração de comando específica do Linux", "JsonSchema.shell": "Especifica se o comando é um comando shell ou um programa externo. O padrão é falso se omitido.", "JsonSchema.tasks.dependsOn.string": "Outra tarefa da qual esta tarefa depende.", - "JsonSchema.tasks.dependsOn.array": "A outra tarefa que esta tarefa depende." + "JsonSchema.tasks.dependsOn.array": "A outra tarefa que esta tarefa depende.", + "JsonSchema.windows": "Configuração de comando específica do Windows", + "JsonSchema.mac": "Configuração de comando específica do Mac", + "JsonSchema.linux": "Configuração de comando específica do Linux" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 29755259794..396a21b1c49 100644 --- a/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -25,7 +25,5 @@ "welcomePage.extensionListSeparator": ", ", "welcomePage.installedExtension": "{0} (instalado)", "ok": "OK", - "cancel": "Cancelar", - "welcomePage.quickLinkBackground": "Cor de fundo para as ligações rápidas na página de boas-vindas.", - "welcomePage.quickLinkHoverBackground": "Passar sobre a cor de fundo para as ligações rápidas na página de boas-vindas." + "cancel": "Cancelar" } \ No newline at end of file diff --git a/i18n/rus/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/rus/extensions/typescript/out/utils/typingsStatus.i18n.json index 4adb921367a..506fc2b22fb 100644 --- a/i18n/rus/extensions/typescript/out/utils/typingsStatus.i18n.json +++ b/i18n/rus/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -5,7 +5,6 @@ // Do not edit this file. It is machine generated. { "installingPackages": "Получение данных Ð´Ð»Ñ Ð¿Ð¾Ð²Ñ‹ÑˆÐµÐ½Ð¸Ñ ÑффективноÑти IntelliSense TypeScript", - "typesInstallerInitializationFailed.title": "Ðе удалоÑÑŒ уÑтановить файлы типизации Ð´Ð»Ñ Ñзыка JavaScript. УбедитеÑÑŒ, что NPM уÑтановлен и путь к нему указан в переменной PATH", "typesInstallerInitializationFailed.moreInformation": "Дополнительные ÑведениÑ", "typesInstallerInitializationFailed.doNotCheckAgain": "Больше не проверÑÑ‚ÑŒ", "typesInstallerInitializationFailed.close": "Закрыть" diff --git a/i18n/rus/extensions/typescript/package.i18n.json b/i18n/rus/extensions/typescript/package.i18n.json index eefc82f18b2..879f5909ede 100644 --- a/i18n/rus/extensions/typescript/package.i18n.json +++ b/i18n/rus/extensions/typescript/package.i18n.json @@ -36,6 +36,5 @@ "typescript.implementationsCodeLens.enabled": "Включить или отключить CodeLens Ð´Ð»Ñ Ñ€ÐµÐ°Ð»Ð¸Ð·Ð°Ñ†Ð¸Ð¹. ТребуетÑÑ TypeScript >= 2.2.0.", "typescript.selectTypeScriptVersion.title": "Выберите верÑию TypeScript.", "jsDocCompletion.enabled": "Включить или отключить JSDoc коментарии", - "javascript.implicitProjectConfig.checkJs": "Включает/отключает ÑемантичеÑкую проверку файлов JavaScript. Этот параметр может переопределÑÑ‚ÑŒÑÑ Ð² файле jsconfig.json или tsconfig.json. ТребуетÑÑ TypeScript 2.3.1 или более поздней верÑии.", - "typescript.check.npmIsInstalled": "ПроверÑет, уÑтановлен ли NPM Ð´Ð»Ñ Ð°Ð²Ñ‚Ð¾Ð¼Ð°Ñ‚Ð¸Ñ‡ÐµÑкого Ð¿Ð¾Ð»ÑƒÑ‡ÐµÐ½Ð¸Ñ Ñ‚Ð¸Ð¿Ð¾Ð²" + "javascript.implicitProjectConfig.checkJs": "Включает/отключает ÑемантичеÑкую проверку файлов JavaScript. Этот параметр может переопределÑÑ‚ÑŒÑÑ Ð² файле jsconfig.json или tsconfig.json. ТребуетÑÑ TypeScript 2.3.1 или более поздней верÑии." } \ No newline at end of file diff --git a/i18n/rus/src/vs/code/electron-main/menus.i18n.json b/i18n/rus/src/vs/code/electron-main/menus.i18n.json index 68b593f2118..edcee11b1f1 100644 --- a/i18n/rus/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/rus/src/vs/code/electron-main/menus.i18n.json @@ -150,12 +150,12 @@ "miLicense": "ПроÑмотреть &&лицензию", "miPrivacyStatement": "&&ЗаÑвление о конфиденциальноÑти", "miAbout": "&&О программе", + "accessibilityOptionsWindowTitle": "Специальные возможноÑти", "miRestartToUpdate": "ПерезапуÑтить Ð´Ð»Ñ Ð¾Ð±Ð½Ð¾Ð²Ð»ÐµÐ½Ð¸Ñ...", "miCheckingForUpdates": "Идет проверка Ð½Ð°Ð»Ð¸Ñ‡Ð¸Ñ Ð¾Ð±Ð½Ð¾Ð²Ð»ÐµÐ½Ð¸Ð¹...", "miDownloadUpdate": "Скачать доÑтупное обновление", "miDownloadingUpdate": "СкачиваетÑÑ Ð¾Ð±Ð½Ð¾Ð²Ð»ÐµÐ½Ð¸Ðµ...", "miInstallingUpdate": "Идет уÑтановка обновлениÑ...", - "miCheckForUpdates": "Проверить наличие обновлений...", "aboutDetail": "\nВерÑÐ¸Ñ {0}\nФикÑÐ°Ñ†Ð¸Ñ {1}\nДата {2}\nОболочка {3}\nОбработчик {4}\nNode {5}", "okButton": "ОК" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/rus/src/vs/workbench/api/node/extHostTask.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/rus/src/vs/workbench/api/node/extHostTask.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/common/theme.i18n.json b/i18n/rus/src/vs/workbench/common/theme.i18n.json index 76b8cda3228..3939a7804fa 100644 --- a/i18n/rus/src/vs/workbench/common/theme.i18n.json +++ b/i18n/rus/src/vs/workbench/common/theme.i18n.json @@ -7,12 +7,9 @@ "tabActiveBackground": "Цвет фона активной вкладки. Вкладки — Ñто контейнеры Ð´Ð»Ñ Ñ€ÐµÐ´Ð°ÐºÑ‚Ð¾Ñ€Ð¾Ð² в облаÑти редактора. Ð’ одной группе редакторов можно открыть неÑколько вкладок. Может приÑутÑтвовать неÑколько групп редакторов.", "tabInactiveBackground": "Цвет фона неактивной вкладки. Вкладки — Ñто контейнеры Ð´Ð»Ñ Ñ€ÐµÐ´Ð°ÐºÑ‚Ð¾Ñ€Ð¾Ð² в облаÑти редактора. Ð’ одной группе редакторов можно открыть неÑколько вкладок. Может приÑутÑтвовать неÑколько групп редакторов.", "tabBorder": "Граница Ð´Ð»Ñ Ñ€Ð°Ð·Ð´ÐµÐ»ÐµÐ½Ð¸Ñ Ð²ÐºÐ»Ð°Ð´Ð¾Ðº. Вкладки — Ñто контейнеры Ð´Ð»Ñ Ñ€ÐµÐ´Ð°ÐºÑ‚Ð¾Ñ€Ð¾Ð² в облаÑти редакторов. Ð’ одной группе редакторов можно открыть неÑколько вкладок. Может быть неÑколько групп редакторов.", - "tabActiveEditorGroupActiveForeground": "Цвет переднего плана активной вкладки в активной группе. Вкладки — Ñто контейнеры Ð´Ð»Ñ Ñ€ÐµÐ´Ð°ÐºÑ‚Ð¾Ñ€Ð¾Ð² в облаÑти редактора. Ð’ одной группе редакторов можно открыть неÑколько вкладок. Может приÑутÑтвовать неÑколько групп редакторов.", - "tabInactiveEditorGroupActiveForeground": "Цвет переднего плана неактивной вкладки в активной группе. Вкладки — Ñто контейнеры Ð´Ð»Ñ Ñ€ÐµÐ´Ð°ÐºÑ‚Ð¾Ñ€Ð¾Ð² в облаÑти редактора. Ð’ одной группе редакторов можно открыть неÑколько вкладок. Может приÑутÑтвовать неÑколько групп редакторов.", "editorGroupBackground": "Цвет фона группы редакторов. Группы редакторов предÑтавлÑÑŽÑ‚ Ñобой контейнеры редакторов. Цвет фона отображаетÑÑ Ð¿Ñ€Ð¸ перетаÑкивании групп редакторов.", "editorGroupHeaderBackground": "Цвет фона Ð´Ð»Ñ Ð·Ð°Ð³Ð¾Ð»Ð¾Ð²ÐºÐ° группы редакторов, когда вкладки отключены. Группы редакторов предÑтавлÑÑŽÑ‚ Ñобой контейнеры редакторов.", "editorGroupBorder": "Цвет Ð´Ð»Ñ Ñ€Ð°Ð·Ð´ÐµÐ»ÐµÐ½Ð¸Ñ Ð½ÐµÑкольких групп редакторов. Группы редакторов — Ñто контейнеры редакторов.", - "panelBackground": "Цвет фона панели. Панели показаны под облаÑтью редактора и Ñодержат такие предÑтавлениÑ, как выходные данные и вÑтроенный терминал.", "panelBorder": "Цвет верхней границы панели, отделÑющей ее от редактора. Панели показаны под облаÑтью редактора и Ñодержат такие предÑтавлениÑ, как выходные данные и вÑтроенный терминал.", "panelActiveTitleForeground": "Цвет заголовка Ð´Ð»Ñ Ð°ÐºÑ‚Ð¸Ð²Ð½Ð¾Ð¹ панели. Панели отображаютÑÑ Ð¿Ð¾Ð´ облаÑтью редактора и Ñодержат такие предÑтавлениÑ, как окно вывода и вÑтроенный терминал.", "panelInactiveTitleForeground": "Цвет заголовка Ð´Ð»Ñ Ð½ÐµÐ°ÐºÑ‚Ð¸Ð²Ð½Ð¾Ð¹ панели. Панели отображаютÑÑ Ð¿Ð¾Ð´ облаÑтью редактора и Ñодержат такие предÑтавлениÑ, как окно вывода и вÑтроенный терминал.", diff --git a/i18n/rus/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/rus/src/vs/workbench/electron-browser/workbench.i18n.json index 8b6ad71cd4e..1aca4f5d59c 100644 --- a/i18n/rus/src/vs/workbench/electron-browser/workbench.i18n.json +++ b/i18n/rus/src/vs/workbench/electron-browser/workbench.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "developer": "Разработчик", + "file": "Файл" +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json b/i18n/rus/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json index 4dceb7811c0..342aae775b8 100644 --- a/i18n/rus/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json @@ -5,8 +5,8 @@ // Do not edit this file. It is machine generated. { "snapshotObj": "Ð”Ð»Ñ Ñтого объекта показаны только значениÑ-примитивы.", - "debuggingStarted": "Отладка началаÑÑŒ.", "debuggingPaused": "Отладка была приоÑтановлена, причина {0}, {1} {2}", + "debuggingStarted": "Отладка началаÑÑŒ.", "debuggingStopped": "Отладка оÑтановилаÑÑŒ.", "breakpointAdded": "Добавлена точка оÑтанова: Ñтрока {0}, файл {1}", "breakpointRemoved": "Удалена точка оÑтанова: Ñтрока {0}, файл {1}", diff --git a/i18n/rus/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/rus/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json index 2798a3b44bd..92f25868855 100644 --- a/i18n/rus/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -5,6 +5,5 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.start": "Определить назначение клавиш", - "defineKeybinding.kbLayoutInfoMessage": "Ð”Ð»Ñ Ñ‚ÐµÐºÑƒÑ‰ÐµÐ¹ раÑкладки клавиатуры нажмите ", "defineKeybinding.kbLayoutErrorMessage": "Ð’Ñ‹ не Ñможете нажать Ñто Ñочетание клавиш в текущей раÑкладке клавиатуры." } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/rus/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json index 450789f1e66..7802fd33b5d 100644 --- a/i18n/rus/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -5,13 +5,12 @@ // Do not edit this file. It is machine generated. { "ConfigurationParser.invalidCWD": "Предупреждение: options.cwd должен иметь тип string. ИгнорируетÑÑ Ð·Ð½Ð°Ñ‡ÐµÐ½Ð¸Ðµ {0}\n", - "ConfigurationParser.noShell": "Предупреждение: ÐºÐ¾Ð½Ñ„Ð¸Ð³ÑƒÑ€Ð°Ñ†Ð¸Ñ Ð¾Ð±Ð¾Ð»Ð¾Ñ‡ÐºÐ¸ поддерживаетÑÑ Ñ‚Ð¾Ð»ÑŒÐºÐ¾ при выполнении задач в терминале.", "ConfigurationParser.noargs": "Ошибка: аргументы команды должны предÑтавлÑÑ‚ÑŒ Ñобой маÑÑив Ñтрок. Указанное значение:\n{0}", + "ConfigurationParser.noShell": "Предупреждение: ÐºÐ¾Ð½Ñ„Ð¸Ð³ÑƒÑ€Ð°Ñ†Ð¸Ñ Ð¾Ð±Ð¾Ð»Ð¾Ñ‡ÐºÐ¸ поддерживаетÑÑ Ñ‚Ð¾Ð»ÑŒÐºÐ¾ при выполнении задач в терминале.", "ConfigurationParser.noName": "Ошибка: ÑопоÑтавитель проблем в облаÑти объÑÐ²Ð»ÐµÐ½Ð¸Ñ Ð´Ð¾Ð»Ð¶ÐµÐ½ иметь имÑ:\n{0}\n", "ConfigurationParser.unknownMatcherKind": "Предупреждение: определен неизвеÑтный ÑопоÑтавитель проблем. Поддерживаемые типы: Ñтрока | СопоÑтавительПроблем | (Ñтрока | СопоÑтавительПроблем)[].\n{0}\n", "ConfigurationParser.invalidVaraibleReference": "Ошибка: недопуÑÑ‚Ð¸Ð¼Ð°Ñ ÑÑылка на problemMatcher: {0}\n", "ConfigurationParser.noTaskName": "Ошибка: задачи должны предоÑтавлÑÑ‚ÑŒ ÑвойÑтво taskName. Задача будет проигнорирована.\n{0}\n", "taskConfiguration.shellArgs": "Предупреждение: задача \"{0}\" ÑвлÑетÑÑ ÐºÐ¾Ð¼Ð°Ð½Ð´Ð¾Ð¹ оболочки, и Ð¸Ð¼Ñ ÐºÐ¾Ð¼Ð°Ð½Ð´Ñ‹ или одного из ее аргументов включает пробелы без escape-поÑледовательноÑти. Чтобы обеÑпечить правильную раÑÑтановку кавычек в командной Ñтроке, объедините аргументы в команде.", - "taskConfiguration.noCommandOrDependsOn": "Ошибка: задача \"{0}\" не задает команду или ÑвойÑтво dependsOn. Задача будет игнорироватьÑÑ. Ее определение:\n{1}", "taskConfiguration.noCommand": "Ошибка: задача \"{0}\" не определÑет команду. Задача будет игнорироватьÑÑ. Ее определение:\n{1}" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json index 881457afe77..f74df060945 100644 --- a/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -4,11 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "JsonSchema.version": "Ðомер верÑии конфигурации", - "JsonSchema.windows": "ÐаÑтройка команд Windows", - "JsonSchema.mac": "ÐаÑтройка команд Mac", - "JsonSchema.linux": "ÐаÑтройка команд Linux", "JsonSchema.shell": "Указывает, ÑвлÑетÑÑ Ð»Ð¸ команда командой оболочки или внешней программой. ЕÑли опущено, значение по умолчанию — false.", "JsonSchema.tasks.dependsOn.string": "Ð”Ñ€ÑƒÐ³Ð°Ñ Ð·Ð°Ð´Ð°Ñ‡Ð°, от которой завиÑит Ñта задача.", - "JsonSchema.tasks.dependsOn.array": "Другие задачи, от которых завиÑит Ñта задача." + "JsonSchema.tasks.dependsOn.array": "Другие задачи, от которых завиÑит Ñта задача.", + "JsonSchema.windows": "ÐаÑтройка команд Windows", + "JsonSchema.mac": "ÐаÑтройка команд Mac", + "JsonSchema.linux": "ÐаÑтройка команд Linux" } \ No newline at end of file -- GitLab From c204fe965e1412d541c7dbdb712aa09b60135b7d Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 1 Jun 2017 08:01:24 +0200 Subject: [PATCH 0416/1347] global settings action: trigger on mouse down and space/enter --- .../parts/activitybar/activitybarActions.ts | 32 +++++++++++++++---- 1 file changed, 26 insertions(+), 6 deletions(-) diff --git a/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts b/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts index ab0ec27b420..7aab7fc7c7d 100644 --- a/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts +++ b/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts @@ -28,6 +28,8 @@ import { IThemeService, ITheme, registerThemingParticipant, ICssStyleCollector } import { ACTIVITY_BAR_BADGE_FOREGROUND, ACTIVITY_BAR_BADGE_BACKGROUND, ACTIVITY_BAR_DRAG_AND_DROP_BACKGROUND, ACTIVITY_BAR_FOREGROUND } from 'vs/workbench/common/theme'; import { contrastBorder, activeContrastBorder, focusBorder } from 'vs/platform/theme/common/colorRegistry'; import { StandardMouseEvent } from "vs/base/browser/mouseEvent"; +import { KeyCode } from "vs/base/common/keyCodes"; +import { StandardKeyboardEvent } from "vs/base/browser/keyboardEvent"; export interface IViewletActivity { badge: IBadge; @@ -669,17 +671,35 @@ export class GlobalActivityActionItem extends ActivityActionItem { super(action, { draggable: false }, themeService); } - public onClick(e: MouseEvent): void { + public render(container: HTMLElement): void { + super.render(container); + + // Context menus are triggered on mouse down so that an item can be picked + // and executed with releasing the mouse over it + this.$container.on(DOM.EventType.MOUSE_DOWN, (e: MouseEvent) => { + DOM.EventHelper.stop(e, true); + + const event = new StandardMouseEvent(e); + this.showContextMenu({ x: event.posx, y: event.posy }); + }); + + this.$container.on(DOM.EventType.KEY_UP, (e: KeyboardEvent) => { + let event = new StandardKeyboardEvent(e); + if (event.equals(KeyCode.Enter) || event.equals(KeyCode.Space)) { + DOM.EventHelper.stop(e, true); + + this.showContextMenu(this.$container.getHTMLElement()); + } + }); + } + + private showContextMenu(location: HTMLElement | { x: number, y: number }): void { const globalAction = this._action as GlobalActivityAction; const activity = globalAction.activity as IGlobalActivity; const actions = activity.getActions(); - const event = new StandardMouseEvent(e); - event.stopPropagation(); - event.preventDefault(); - this.contextMenuService.showContextMenu({ - getAnchor: () => ({ x: event.posx, y: event.posy }), + getAnchor: () => location, getActions: () => TPromise.as(actions), onHide: () => dispose(actions) }); -- GitLab From 5b473bbe2dd33fe2918814962d70f6929517b802 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Thu, 1 Jun 2017 08:31:44 +0200 Subject: [PATCH 0417/1347] Use customize instead of identifier for customizing tasks --- .../parts/tasks/common/taskConfiguration.ts | 10 ++++++++- src/vs/workbench/parts/tasks/common/tasks.ts | 5 +++++ .../tasks/electron-browser/jsonSchema_v2.ts | 6 +++--- .../electron-browser/task.contribution.ts | 21 +++++++------------ 4 files changed, 24 insertions(+), 18 deletions(-) diff --git a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts index 2419be66ba0..717fa268eab 100644 --- a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts +++ b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts @@ -105,6 +105,11 @@ export interface TaskDescription extends PlatformTaskDescription { */ identifier?: string; + /** + * The id of the customized task + */ + customize?: string; + /** * Windows specific task configuration */ @@ -903,6 +908,9 @@ namespace TaskDescription { task.group = Tasks.TaskGroup.Test; } } + if (Types.isString(externalTask.customize)) { + task.customize = externalTask.customize; + } if (externalTask.command !== void 0) { // if the task has its own command then we suppress the // task name by default. @@ -1055,7 +1063,7 @@ namespace TaskDescription { } function isAnnotating(task: Tasks.Task): boolean { - return (task.command === void 0 || task.command.name === void 0) && (task.dependsOn === void 0 || task.dependsOn.length === 0); + return task.customize !== void 0 && (task.command === void 0 || task.command.name === void 0); } export function assignProperties(target: Tasks.Task, source: Tasks.Task): Tasks.Task { diff --git a/src/vs/workbench/parts/tasks/common/tasks.ts b/src/vs/workbench/parts/tasks/common/tasks.ts index 88dfd56ba73..b75a5750e58 100644 --- a/src/vs/workbench/parts/tasks/common/tasks.ts +++ b/src/vs/workbench/parts/tasks/common/tasks.ts @@ -208,6 +208,11 @@ export interface Task { */ identifier: string; + /** + * The id of the customized task + */ + customize?: string; + /** * the task's group; */ diff --git a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts index 3a60d35d088..14985496e18 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts @@ -83,9 +83,9 @@ const version: IJSONSchema = { description: nls.localize('JsonSchema.version', 'The config\'s version number.') }; -const identifier: IJSONSchema = { +const customize: IJSONSchema = { type: 'string', - description: nls.localize('JsonSchema.tasks.identifier', 'A unique identifier of the task.') + description: nls.localize('JsonSchema.tasks.customize', 'The contributed task to be customized.') }; const schema: IJSONSchema = { @@ -128,7 +128,7 @@ definitions.taskDescription.properties.dependsOn = dependsOn; // definitions.taskDescription.properties.echoCommand.deprecationMessage = nls.localize('JsonSchema.tasks.echoCommand.deprecated', 'The property echoCommand is deprecated. Use the terminal property instead.'); // definitions.taskDescription.properties.isBuildCommand.deprecationMessage = nls.localize('JsonSchema.tasks.isBuildCommand.deprecated', 'The property isBuildCommand is deprecated. Use the group property instead.'); // definitions.taskDescription.properties.isTestCommand.deprecationMessage = nls.localize('JsonSchema.tasks.isTestCommand.deprecated', 'The property isTestCommand is deprecated. Use the group property instead.'); -definitions.taskDescription.properties.identifier = identifier; +definitions.taskDescription.properties.customize = customize; definitions.taskDescription.properties.type = Objects.deepClone(taskType); definitions.taskDescription.properties.terminal = terminal; definitions.taskDescription.properties.group = group; diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index f14e2e4bbc6..126ca11a1b8 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -71,7 +71,7 @@ import { Scope, IActionBarRegistry, Extensions as ActionBarExtensions } from 'vs import { ITerminalService } from 'vs/workbench/parts/terminal/common/terminal'; import { ITaskSystem, ITaskResolver, ITaskSummary, ITaskExecuteResult, TaskExecuteKind, TaskError, TaskErrors, TaskSystemEvents } from 'vs/workbench/parts/tasks/common/taskSystem'; -import { Task, TaskSet, TaskGroup, ExecutionEngine, TaskSourceKind } from 'vs/workbench/parts/tasks/common/tasks'; +import { Task, TaskSet, TaskGroup, ExecutionEngine, JsonSchemaVersion, TaskSourceKind } from 'vs/workbench/parts/tasks/common/tasks'; import { ITaskService, TaskServiceEvents, ITaskProvider } from 'vs/workbench/parts/tasks/common/taskService'; import { templates as taskTemplates } from 'vs/workbench/parts/tasks/common/taskTemplates'; @@ -502,7 +502,6 @@ interface WorkspaceTaskResult { set: TaskSet; annotatingTasks: { byIdentifier: IStringDictionary; - byLabel: IStringDictionary; }; hasErrors: boolean; } @@ -756,7 +755,7 @@ class TaskService extends EventEmitter implements ITaskService { return TPromise.as(undefined); } let fileConfig = configuration.config; - let customize = { taskName: task._label, identifier: task.identifier }; + let customize = { customize: task.identifier, taskName: task._label, problemMatcher: [] }; if (!fileConfig) { fileConfig = { version: '2.0.0', @@ -952,7 +951,7 @@ class TaskService extends EventEmitter implements ITaskService { resolve(result); } }; - if (this.getExecutionEngine() === ExecutionEngine.Terminal && this._providers.size > 0) { + if (this.getJsonSchemaVersion() === JsonSchemaVersion.V2_0_0 && this._providers.size > 0) { this._providers.forEach((provider) => { counter++; provider.provideTasks().done(done, error); @@ -970,7 +969,7 @@ class TaskService extends EventEmitter implements ITaskService { for (let set of result) { for (let task of set.tasks) { if (annotatingTasks) { - let annotatingTask = annotatingTasks.byIdentifier[task.identifier] || annotatingTasks.byLabel[task._label]; + let annotatingTask = annotatingTasks.byIdentifier[task.identifier]; if (annotatingTask) { TaskConfig.mergeTasks(task, annotatingTask); task.name = annotatingTask.name; @@ -1123,17 +1122,13 @@ class TaskService extends EventEmitter implements ITaskService { problemReporter.fatal(nls.localize('TaskSystem.configurationErrors', 'Error: the provided task configuration has validation errors and can\'t not be used. Please correct the errors first.')); return { set: undefined, annotatingTasks: undefined, hasErrors }; } - let annotatingTasks: { byIdentifier: IStringDictionary; byLabel: IStringDictionary; }; + let annotatingTasks: { byIdentifier: IStringDictionary; }; if (parseResult.annotatingTasks && parseResult.annotatingTasks.length > 0) { annotatingTasks = { - byIdentifier: Object.create(null), - byLabel: Object.create(null) + byIdentifier: Object.create(null) }; for (let task of parseResult.annotatingTasks) { - annotatingTasks.byIdentifier[task.identifier] = task; - if (task._label) { - annotatingTasks.byLabel[task._label] = task; - } + annotatingTasks.byIdentifier[task.customize] = task; } } return { set: { tasks: parseResult.tasks }, annotatingTasks: annotatingTasks, hasErrors }; @@ -1149,7 +1144,6 @@ class TaskService extends EventEmitter implements ITaskService { return TaskConfig.ExecutionEngine.from(config); } - /* private getJsonSchemaVersion(): JsonSchemaVersion { let { config } = this.getConfiguration(); if (!config) { @@ -1157,7 +1151,6 @@ class TaskService extends EventEmitter implements ITaskService { } return TaskConfig.JsonSchemaVersion.from(config); } - */ private getConfiguration(): { config: TaskConfig.ExternalTaskRunnerConfiguration; hasParseErrors: boolean } { let result = this.configurationService.getConfiguration('tasks'); -- GitLab From 69ddf8a83e12da26cba57af4cd653d78b5f77a86 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Thu, 1 Jun 2017 09:15:19 +0200 Subject: [PATCH 0418/1347] Fixes #27811: Add editor.multicursorModifier to most common editor settings --- .../telemetry/common/telemetryUtils.ts | 108 ++++++++++-------- .../preferences/browser/preferencesService.ts | 5 +- 2 files changed, 64 insertions(+), 49 deletions(-) diff --git a/src/vs/platform/telemetry/common/telemetryUtils.ts b/src/vs/platform/telemetry/common/telemetryUtils.ts index e3370d3d865..7ba7db945fe 100644 --- a/src/vs/platform/telemetry/common/telemetryUtils.ts +++ b/src/vs/platform/telemetry/common/telemetryUtils.ts @@ -190,82 +190,96 @@ export function telemetryURIDescriptor(uri: URI): URIDescriptor { * Only add settings that cannot contain any personal/private information of users (PII). */ const configurationValueWhitelist = [ - 'window.zoomLevel', - 'editor.fontSize', + 'editor.tabCompletion', 'editor.fontFamily', + 'editor.fontWeight', + 'editor.fontSize', + 'editor.lineHeight', + 'editor.letterSpacing', + 'editor.lineNumbers', + 'editor.rulers', + 'editor.wordSeparators', 'editor.tabSize', + 'editor.insertSpaces', + 'editor.detectIndentation', + 'editor.roundedSelection', + 'editor.scrollBeyondLastLine', + 'editor.minimap.enabled', + 'editor.minimap.renderCharacters', + 'editor.minimap.maxColumn', + 'editor.find.seedSearchStringFromSelection', + 'editor.find.autoFindInSelection', + 'editor.wordWrap', + 'editor.wordWrapColumn', + 'editor.wrappingIndent', + 'editor.mouseWheelScrollSensitivity', + 'editor.multiCursorModifier', + 'editor.quickSuggestions', + 'editor.quickSuggestionsDelay', + 'editor.parameterHints', + 'editor.autoClosingBrackets', + 'editor.formatOnType', + 'editor.formatOnPaste', + 'editor.suggestOnTriggerCharacters', + 'editor.acceptSuggestionOnEnter', + 'editor.acceptSuggestionOnCommitCharacter', + 'editor.snippetSuggestions', + 'editor.emptySelectionClipboard', + 'editor.wordBasedSuggestions', + 'editor.suggestFontSize', + 'editor.suggestLineHeight', + 'editor.selectionHighlight', + 'editor.occurrencesHighlight', + 'editor.overviewRulerLanes', + 'editor.overviewRulerBorder', + 'editor.cursorBlinking', + 'editor.cursorStyle', + 'editor.mouseWheelZoom', + 'editor.fontLigatures', + 'editor.hideCursorInOverviewRuler', + 'editor.renderWhitespace', + 'editor.renderControlCharacters', + 'editor.renderIndentGuides', + 'editor.renderLineHighlight', + 'editor.codeLens', + 'editor.folding', + 'editor.showFoldingControls', + 'editor.matchBrackets', + 'editor.glyphMargin', + 'editor.useTabStops', + 'editor.trimAutoWhitespace', + 'editor.stablePeek', + 'editor.dragAndDrop', + 'editor.formatOnSave', + + 'window.zoomLevel', 'files.autoSave', 'files.hotExit', 'typescript.check.tscVersion', - 'editor.renderWhitespace', - 'editor.cursorBlinking', - 'editor.cursorStyle', 'files.associations', 'workbench.statusBar.visible', - 'editor.wordWrap', - 'editor.wordWrapColumn', - 'editor.insertSpaces', - 'editor.renderIndentGuides', 'files.trimTrailingWhitespace', 'git.confirmSync', - 'editor.rulers', 'workbench.sideBar.location', - 'editor.fontLigatures', - 'editor.wordWrap', - 'editor.lineHeight', - 'editor.detectIndentation', - 'editor.formatOnType', - 'editor.formatOnSave', - 'editor.formatOnPaste', - 'editor.dragAndDrop', 'window.openFilesInNewWindow', 'javascript.validate.enable', - 'editor.mouseWheelZoom', - 'editor.fontWeight', - 'editor.scrollBeyondLastLine', - 'editor.lineNumbers', - 'editor.letterSpacing', - 'editor.wrappingIndent', - 'editor.renderControlCharacters', - 'editor.autoClosingBrackets', 'window.reopenFolders', 'extensions.autoUpdate', - 'editor.tabCompletion', 'files.eol', 'explorer.openEditors.visible', 'workbench.editor.enablePreview', 'files.autoSaveDelay', - 'editor.roundedSelection', - 'editor.quickSuggestions', - 'editor.acceptSuggestionOnEnter', - 'editor.acceptSuggestionOnCommitCharacter', 'workbench.editor.showTabs', 'files.encoding', 'files.autoGuessEncoding', - 'editor.quickSuggestionsDelay', - 'editor.snippetSuggestions', - 'editor.selectionHighlight', - 'editor.occurrencesHighlight', - 'editor.glyphMargin', - 'editor.wordSeparators', - 'editor.mouseWheelScrollSensitivity', - 'editor.suggestOnTriggerCharacters', 'git.enabled', 'http.proxyStrictSSL', 'terminal.integrated.fontFamily', - 'editor.overviewRulerLanes', - 'editor.overviewRulerBorder', - 'editor.wordBasedSuggestions', - 'editor.hideCursorInOverviewRuler', - 'editor.trimAutoWhitespace', - 'editor.folding', - 'editor.matchBrackets', 'workbench.editor.enablePreviewFromQuickOpen', 'workbench.editor.swipeToNavigate', 'php.builtInCompletions.enable', 'php.validate.enable', 'php.validate.run', - 'editor.parameterHints', 'workbench.welcome.enabled', ]; diff --git a/src/vs/workbench/parts/preferences/browser/preferencesService.ts b/src/vs/workbench/parts/preferences/browser/preferencesService.ts index 436d010bd46..bb6d77f0d30 100644 --- a/src/vs/workbench/parts/preferences/browser/preferencesService.ts +++ b/src/vs/workbench/parts/preferences/browser/preferencesService.ts @@ -289,15 +289,16 @@ export class PreferencesService extends Disposable implements IPreferencesServic private fetchMostCommonlyUsedSettings(): TPromise { return TPromise.wrap([ - 'editor.fontSize', 'files.autoSave', + 'editor.fontSize', 'editor.fontFamily', 'editor.tabSize', 'editor.renderWhitespace', - 'files.exclude', 'editor.cursorStyle', + 'editor.multiCursorModifier', 'editor.insertSpaces', 'editor.wordWrap', + 'files.exclude', 'files.associations' ]); } -- GitLab From eac49a321b84cb9828430e9dcd3f34243a3480f7 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 1 Jun 2017 09:26:32 +0200 Subject: [PATCH 0419/1347] Git: rename 'Publish' to 'Publish Branch' (fixes #26133) --- extensions/git/package.nls.json | 2 +- extensions/git/src/statusbar.ts | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/extensions/git/package.nls.json b/extensions/git/package.nls.json index e02a5ed2310..c34b7166da3 100644 --- a/extensions/git/package.nls.json +++ b/extensions/git/package.nls.json @@ -27,7 +27,7 @@ "command.push": "Push", "command.pushTo": "Push to...", "command.sync": "Sync", - "command.publish": "Publish", + "command.publish": "Publish Branch", "command.showOutput": "Show Git Output", "config.enabled": "Whether git is enabled", "config.path": "Path to the git executable", diff --git a/extensions/git/src/statusbar.ts b/extensions/git/src/statusbar.ts index c609d570b9d..9fe437ccec5 100644 --- a/extensions/git/src/statusbar.ts +++ b/extensions/git/src/statusbar.ts @@ -114,11 +114,11 @@ class SyncStatusBar { text += `${HEAD.behind}↓ ${HEAD.ahead}↑`; } command = 'git.sync'; - tooltip = localize('sync changes', "Synchronize changes"); + tooltip = localize('sync changes', "Synchronize Changes"); } else { icon = '$(cloud-upload)'; command = 'git.publish'; - tooltip = localize('publish changes', "Publish changes"); + tooltip = localize('publish changes', "Publish Changes"); } } else { command = ''; @@ -128,7 +128,7 @@ class SyncStatusBar { if (this.state.isSyncRunning) { icon = '$(sync~spin)'; command = ''; - tooltip = localize('syncing changes', "Synchronizing changes..."); + tooltip = localize('syncing changes', "Synchronizing Changes..."); } return { -- GitLab From b648f36f707cdf9e3b08fb833c2a7345d802383c Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Thu, 1 Jun 2017 09:39:39 +0200 Subject: [PATCH 0420/1347] Fixes #27726: Tasks.json: Provide intellisense for problem matcher --- src/vs/platform/markers/common/problemMatcher.ts | 10 ++++++++++ .../parts/tasks/electron-browser/jsonSchema_v1.ts | 12 ++++++++++++ .../parts/tasks/electron-browser/jsonSchema_v2.ts | 12 ++++++++++++ 3 files changed, 34 insertions(+) diff --git a/src/vs/platform/markers/common/problemMatcher.ts b/src/vs/platform/markers/common/problemMatcher.ts index b42f0f2a906..055e46fecaa 100644 --- a/src/vs/platform/markers/common/problemMatcher.ts +++ b/src/vs/platform/markers/common/problemMatcher.ts @@ -1482,6 +1482,8 @@ export interface IProblemMatcherRegistry { onReady(): TPromise; exists(name: string): boolean; get(name: string): ProblemMatcher; + values(): ProblemMatcher[]; + keys(): string[]; } class ProblemMatcherRegistryImpl implements IProblemMatcherRegistry { @@ -1536,6 +1538,14 @@ class ProblemMatcherRegistryImpl implements IProblemMatcherRegistry { delete this.matchers[name]; } + public keys(): string[] { + return Object.keys(this.matchers); + } + + public values(): ProblemMatcher[] { + return Object.keys(this.matchers).map(key => this.matchers[key]); + } + private fillDefaults(): void { this.add('msCompile', { owner: 'msCompile', diff --git a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.ts b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.ts index af5ca29ae20..a82c294c6c7 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.ts @@ -8,6 +8,8 @@ import * as nls from 'vs/nls'; import * as Objects from 'vs/base/common/objects'; import { IJSONSchema } from 'vs/base/common/jsonSchema'; +import { ProblemMatcherRegistry } from 'vs/platform/markers/common/problemMatcher'; + import commonSchema from './jsonSchemaCommon'; const schema: IJSONSchema = { @@ -89,4 +91,14 @@ function fixReferences(literal: any) { } fixReferences(schema); +ProblemMatcherRegistry.onReady().then(() => { + try { + let matcherIds = ProblemMatcherRegistry.keys().map(key => '$' + key); + definitions.problemMatcherType1.oneOf[0].enum = matcherIds; + (definitions.problemMatcherType1.oneOf[2].items as IJSONSchema).anyOf[1].enum = matcherIds; + } catch (err) { + console.log('Installing problem matcher ids failed'); + } +}); + export default schema; \ No newline at end of file diff --git a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts index 14985496e18..f63861f41d7 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts @@ -10,6 +10,8 @@ import { IJSONSchema } from 'vs/base/common/jsonSchema'; import commonSchema from './jsonSchemaCommon'; +import { ProblemMatcherRegistry } from 'vs/platform/markers/common/problemMatcher'; + const shellCommand: IJSONSchema = { anyOf: [ { @@ -162,4 +164,14 @@ function fixReferences(literal: any) { } fixReferences(schema); +ProblemMatcherRegistry.onReady().then(() => { + try { + let matcherIds = ProblemMatcherRegistry.keys().map(key => '$' + key); + definitions.problemMatcherType2.oneOf[0].enum = matcherIds; + (definitions.problemMatcherType2.oneOf[2].items as IJSONSchema).anyOf[1].enum = matcherIds; + } catch (err) { + console.log('Installing problem matcher ids failed'); + } +}); + export default schema; \ No newline at end of file -- GitLab From b28e0e3425b1ef6206db83fa2524e35a7cafd981 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 1 Jun 2017 10:38:05 +0200 Subject: [PATCH 0421/1347] Update thirdpartynotices --- ThirdPartyNotices.txt | 184 +++++++++++++++++---------------- extensions/html/OSSREADME.json | 2 +- 2 files changed, 94 insertions(+), 92 deletions(-) diff --git a/ThirdPartyNotices.txt b/ThirdPartyNotices.txt index 49020843ae9..958cac6b8d3 100644 --- a/ThirdPartyNotices.txt +++ b/ThirdPartyNotices.txt @@ -1,3 +1,5 @@ +===================BEGIN GENERATOR LOG +===================END GENERATOR LOG microsoft-vscode THIRD-PARTY SOFTWARE NOTICES AND INFORMATION @@ -5,64 +7,63 @@ Do Not Translate or Localize This project incorporates components from the projects listed below. The original copyright notices and the licenses under which Microsoft received such components are set forth below. Microsoft reserves all rights not expressly granted herein, whether by implication, estoppel or otherwise. -1. atom/language-c version 0.51.3 (https://github.com/atom/language-c) +1. atom/language-c (https://github.com/atom/language-c) 2. atom/language-clojure (https://github.com/atom/language-clojure) 3. atom/language-coffee-script (https://github.com/atom/language-coffee-script) 4. atom/language-css (https://github.com/atom/language-css) -5. atom/language-objective-c (https://github.com/atom/language-objective-c) -6. atom/language-sass version 0.52.0 (https://github.com/atom/language-sass) -7. atom/language-xml (https://github.com/atom/language-xml) -8. Benvie/JavaScriptNext.tmLanguage (https://github.com/Benvie/JavaScriptNext.tmLanguage) -9. chjj-marked version 0.3.2 (https://github.com/npmcomponent/chjj-marked) -10. chriskempson/tomorrow-theme (https://github.com/chriskempson/tomorrow-theme) -11. Colorsublime-Themes version 0.1.0 (https://github.com/Colorsublime/Colorsublime-Themes) -12. daaain/Handlebars (https://github.com/daaain/Handlebars) -13. davidrios/jade-tmbundle (https://github.com/davidrios/jade-tmbundle) -14. definitelytyped (https://github.com/DefinitelyTyped/DefinitelyTyped) -15. demyte/language-cshtml (https://github.com/demyte/language-cshtml) -16. dotnet/csharp-tmLanguage version 0.1.0 (https://github.com/dotnet/csharp-tmLanguage) -17. freebroccolo/atom-language-swift (https://github.com/freebroccolo/atom-language-swift) -18. HTML 5.1 W3C Working Draft version 08 October 2015 (http://www.w3.org/TR/2015/WD-html51-20151008/) -19. Ionic documentation version 1.2.4 (https://github.com/driftyco/ionic-site) -20. ionide/ionide-fsgrammar (https://github.com/ionide/ionide-fsgrammar) -21. js-beautify version 1.6.8 (https://github.com/beautify-web/js-beautify) -22. Jxck/assert version 1.0.0 (https://github.com/Jxck/assert) -23. language-docker (https://github.com/moby/moby) -24. language-go version 0.39.0 (https://github.com/atom/language-go) -25. language-less (https://github.com/atom/language-less) -26. language-php (https://github.com/atom/language-php) -27. language-rust version 0.4.9 (https://github.com/zargony/atom-language-rust) -28. MagicStack/MagicPython (https://github.com/MagicStack/MagicPython) -29. Microsoft/TypeScript-TmLanguage version 0.0.1 (https://github.com/Microsoft/TypeScript-TmLanguage) -30. octicons-code version 3.1.0 (https://octicons.github.com) -31. octicons-font version 3.1.0 (https://octicons.github.com) -32. seti-ui version 0.1.0 (https://github.com/jesseweed/seti-ui) -33. shaders-tmLanguage version 0.1.0 (https://github.com/tgjones/shaders-tmLanguage) -34. string_scorer version 0.1.20 (https://github.com/joshaven/string_score) -35. sublimehq/Packages (https://github.com/sublimehq/Packages) -36. SublimeText/PowerShell (https://github.com/SublimeText/PowerShell) -37. textmate/asp.vb.net.tmbundle (https://github.com/textmate/asp.vb.net.tmbundle) -38. textmate/c.tmbundle (https://github.com/textmate/c.tmbundle) -39. textmate/diff.tmbundle (https://github.com/textmate/diff.tmbundle) -40. textmate/git.tmbundle (https://github.com/textmate/git.tmbundle) -41. textmate/groovy.tmbundle (https://github.com/textmate/groovy.tmbundle) -42. textmate/html.tmbundle (https://github.com/textmate/html.tmbundle) -43. textmate/ini.tmbundle (https://github.com/textmate/ini.tmbundle) -44. textmate/java.tmbundle (https://github.com/textmate/java.tmbundle) -45. textmate/javadoc.tmbundle (https://github.com/textmate/javadoc.tmbundle) -46. textmate/javascript.tmbundle (https://github.com/textmate/javascript.tmbundle) -47. textmate/lua.tmbundle (https://github.com/textmate/lua.tmbundle) -48. textmate/make.tmbundle (https://github.com/textmate/make.tmbundle) -49. textmate/markdown.tmbundle (https://github.com/textmate/markdown.tmbundle) -50. textmate/perl.tmbundle (https://github.com/textmate/perl.tmbundle) -51. textmate/r.tmbundle (https://github.com/textmate/r.tmbundle) -52. textmate/ruby.tmbundle (https://github.com/textmate/ruby.tmbundle) -53. textmate/shellscript.tmbundle (https://github.com/textmate/shellscript.tmbundle) -54. textmate/sql.tmbundle (https://github.com/textmate/sql.tmbundle) -55. textmate/yaml.tmbundle (https://github.com/textmate/yaml.tmbundle) -56. typescript-legacy version 1.5 (https://github.com/Microsoft/TypeScript) -57. TypeScript-TmLanguage version 0.1.8 (https://github.com/Microsoft/TypeScript-TmLanguage) -58. vscode-swift version 0.0.1 (https://github.com/owensd/vscode-swift) +5. atom/language-java (https://github.com/atom/language-java) +6. atom/language-objective-c (https://github.com/atom/language-objective-c) +7. atom/language-sass version 0.52.0 (https://github.com/atom/language-sass) +8. atom/language-xml (https://github.com/atom/language-xml) +9. Benvie/JavaScriptNext.tmLanguage (https://github.com/Benvie/JavaScriptNext.tmLanguage) +10. chjj-marked version 0.3.2 (https://github.com/npmcomponent/chjj-marked) +11. chriskempson/tomorrow-theme (https://github.com/chriskempson/tomorrow-theme) +12. Colorsublime-Themes version 0.1.0 (https://github.com/Colorsublime/Colorsublime-Themes) +13. daaain/Handlebars (https://github.com/daaain/Handlebars) +14. davidrios/jade-tmbundle (https://github.com/davidrios/jade-tmbundle) +15. definitelytyped (https://github.com/DefinitelyTyped/DefinitelyTyped) +16. demyte/language-cshtml (https://github.com/demyte/language-cshtml) +17. dotnet/csharp-tmLanguage version 0.1.0 (https://github.com/dotnet/csharp-tmLanguage) +18. freebroccolo/atom-language-swift (https://github.com/freebroccolo/atom-language-swift) +19. HTML 5.1 W3C Working Draft version 08 October 2015 (http://www.w3.org/TR/2015/WD-html51-20151008/) +20. Ionic documentation version 1.2.4 (https://github.com/ionic-team/ionic-site) +21. ionide/ionide-fsgrammar (https://github.com/ionide/ionide-fsgrammar) +22. js-beautify version 1.6.8 (https://github.com/beautify-web/js-beautify) +23. Jxck/assert version 1.0.0 (https://github.com/Jxck/assert) +24. language-docker (https://github.com/moby/moby) +25. language-go version 0.39.0 (https://github.com/atom/language-go) +26. language-less (https://github.com/atom/language-less) +27. language-php (https://github.com/atom/language-php) +28. language-rust version 0.4.9 (https://github.com/zargony/atom-language-rust) +29. MagicStack/MagicPython (https://github.com/MagicStack/MagicPython) +30. Microsoft/TypeScript-TmLanguage version 0.0.1 (https://github.com/Microsoft/TypeScript-TmLanguage) +31. octicons-code version 3.1.0 (https://octicons.github.com) +32. octicons-font version 3.1.0 (https://octicons.github.com) +33. seti-ui version 0.1.0 (https://github.com/jesseweed/seti-ui) +34. shaders-tmLanguage version 0.1.0 (https://github.com/tgjones/shaders-tmLanguage) +35. string_scorer version 0.1.20 (https://github.com/joshaven/string_score) +36. sublimehq/Packages (https://github.com/sublimehq/Packages) +37. SublimeText/PowerShell (https://github.com/SublimeText/PowerShell) +38. textmate/asp.vb.net.tmbundle (https://github.com/textmate/asp.vb.net.tmbundle) +39. textmate/c.tmbundle (https://github.com/textmate/c.tmbundle) +40. textmate/diff.tmbundle (https://github.com/textmate/diff.tmbundle) +41. textmate/git.tmbundle (https://github.com/textmate/git.tmbundle) +42. textmate/groovy.tmbundle (https://github.com/textmate/groovy.tmbundle) +43. textmate/html.tmbundle (https://github.com/textmate/html.tmbundle) +44. textmate/ini.tmbundle (https://github.com/textmate/ini.tmbundle) +45. textmate/javascript.tmbundle (https://github.com/textmate/javascript.tmbundle) +46. textmate/lua.tmbundle (https://github.com/textmate/lua.tmbundle) +47. textmate/make.tmbundle (https://github.com/textmate/make.tmbundle) +48. textmate/markdown.tmbundle (https://github.com/textmate/markdown.tmbundle) +49. textmate/perl.tmbundle (https://github.com/textmate/perl.tmbundle) +50. textmate/r.tmbundle (https://github.com/textmate/r.tmbundle) +51. textmate/ruby.tmbundle (https://github.com/textmate/ruby.tmbundle) +52. textmate/shellscript.tmbundle (https://github.com/textmate/shellscript.tmbundle) +53. textmate/sql.tmbundle (https://github.com/textmate/sql.tmbundle) +54. textmate/yaml.tmbundle (https://github.com/textmate/yaml.tmbundle) +55. typescript-legacy version 1.5 (https://github.com/Microsoft/TypeScript) +56. TypeScript-TmLanguage version 0.1.8 (https://github.com/Microsoft/TypeScript-TmLanguage) +57. vscode-swift version 0.0.1 (https://github.com/owensd/vscode-swift) %% atom/language-c NOTICES AND INFORMATION BEGIN HERE @@ -246,6 +247,43 @@ suitability for any purpose. ========================================= END OF atom/language-css NOTICES AND INFORMATION +%% atom/language-java NOTICES AND INFORMATION BEGIN HERE +========================================= +The MIT License (MIT) + +Copyright (c) 2014 GitHub Inc. + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + + +This package was derived from a TextMate bundle located at +https://github.com/textmate/java.tmbundle and distributed under the following +license, located in `README.mdown`: + +Permission to copy, use, modify, sell and distribute this +software is granted. This software is provided "as is" without +express or implied warranty, and with no claim as to its +suitability for any purpose. +========================================= +END OF atom/language-java NOTICES AND INFORMATION + %% atom/language-objective-c NOTICES AND INFORMATION BEGIN HERE ========================================= The MIT License (MIT) @@ -1701,42 +1739,6 @@ to the base-name name of the original file, and an extension of txt, html, or si ========================================= END OF textmate/ini.tmbundle NOTICES AND INFORMATION -%% textmate/java.tmbundle NOTICES AND INFORMATION BEGIN HERE -========================================= -Copyright (c) textmate-java.tmbundle project authors - -If not otherwise specified (see below), files in this repository fall under the following license: - -Permission to copy, use, modify, sell and distribute this -software is granted. This software is provided "as is" without -express or implied warranty, and with no claim as to its -suitability for any purpose. - -An exception is made for files in readable text which contain their own license information, -or files where an accompanying file exists (in the same directory) with a "-license" suffix added -to the base-name name of the original file, and an extension of txt, html, or similar. For example -"tidy" is accompanied by "tidy-license.txt". -========================================= -END OF textmate/java.tmbundle NOTICES AND INFORMATION - -%% textmate/javadoc.tmbundle NOTICES AND INFORMATION BEGIN HERE -========================================= -Copyright (c) textmate-javadoc.tmbundle project authors - -If not otherwise specified (see below), files in this repository fall under the following license: - -Permission to copy, use, modify, sell and distribute this -software is granted. This software is provided "as is" without -express or implied warranty, and with no claim as to its -suitability for any purpose. - -An exception is made for files in readable text which contain their own license information, -or files where an accompanying file exists (in the same directory) with a "-license" suffix added -to the base-name name of the original file, and an extension of txt, html, or similar. For example -"tidy" is accompanied by "tidy-license.txt". -========================================= -END OF textmate/javadoc.tmbundle NOTICES AND INFORMATION - %% textmate/javascript.tmbundle NOTICES AND INFORMATION BEGIN HERE ========================================= Copyright (c) textmate-javascript.tmbundle project authors diff --git a/extensions/html/OSSREADME.json b/extensions/html/OSSREADME.json index 238e37e068f..473df53afb3 100644 --- a/extensions/html/OSSREADME.json +++ b/extensions/html/OSSREADME.json @@ -50,7 +50,7 @@ "name": "Ionic documentation", "version": "1.2.4", "license": "Apache2", - "repositoryURL": "https://github.com/driftyco/ionic-site", + "repositoryURL": "https://github.com/ionic-team/ionic-site", "licenseDetail": [ "Copyright Drifty Co. http://drifty.com/.", "", -- GitLab From 038703dc84ae9e969e7c7cc6b867b5bacfbc6b19 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 1 Jun 2017 10:35:46 +0200 Subject: [PATCH 0422/1347] renamed and make TextSnippet extend Marker, #27543 --- .../contrib/snippet/browser/snippetParser.ts | 92 ++++++++++++------- .../contrib/snippet/browser/snippetSession.ts | 2 +- .../test/browser/snippetParser.test.ts | 78 +++++++++------- .../emmet/electron-browser/editorAccessor.ts | 8 +- .../snippets/electron-browser/TMSnippets.ts | 10 +- 5 files changed, 113 insertions(+), 77 deletions(-) diff --git a/src/vs/editor/contrib/snippet/browser/snippetParser.ts b/src/vs/editor/contrib/snippet/browser/snippetParser.ts index 0506b2b187b..488b53b864b 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetParser.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetParser.ts @@ -134,8 +134,19 @@ export abstract class Marker { parent: Marker; - protected _adopt(child: Marker): void { - child.parent = this; + private _children: Marker[] = []; + + set children(marker: Marker[]) { + this._children = []; + for (const m of marker) { + m.parent = this; + this._children.push(m); + } + // Object.freeze(this._children); + } + + get children(): Marker[] { + return this._children; } toString() { @@ -176,15 +187,15 @@ export class Placeholder extends Marker { } } - constructor(public index: string = '', public defaultValue: Marker[]) { + constructor(public index: string = '', children: Marker[]) { super(); - defaultValue.forEach(this._adopt, this); + this.children = children; } get isFinalTabstop() { return this.index === '0'; } toString() { - return Marker.toString(this.defaultValue); + return Marker.toString(this.children); } } @@ -192,9 +203,9 @@ export class Variable extends Marker { resolvedValue: string; - constructor(public name: string = '', public defaultValue: Marker[]) { + constructor(public name: string = '', children: Marker[]) { super(); - defaultValue.forEach(this._adopt, this); + this.children = children; } get isDefined(): boolean { return this.resolvedValue !== undefined; @@ -207,7 +218,7 @@ export class Variable extends Marker { } } toString() { - return this.isDefined ? this.resolvedValue : Marker.toString(this.defaultValue); + return this.isDefined ? this.resolvedValue : Marker.toString(this.children); } } export function walk(marker: Marker[], visitor: (marker: Marker) => boolean): void { @@ -219,36 +230,38 @@ export function walk(marker: Marker[], visitor: (marker: Marker) => boolean): vo break; } if (marker instanceof Placeholder || marker instanceof Variable) { - stack.unshift(...marker.defaultValue); + stack.unshift(...marker.children); } } } -export class TextmateSnippet { +export class TextmateSnippet extends Marker { - readonly marker: Marker[]; - readonly placeholders: Placeholder[]; + private _placeholders: Placeholder[]; constructor(marker: Marker[]) { - this.marker = marker; - this.placeholders = []; - - // fill in placeholders - walk(marker, candidate => { - if (candidate instanceof Placeholder) { - this.placeholders.push(candidate); - } - return true; - }); + super(); + this.children = marker; + } - Object.freeze(this.marker); - Object.freeze(this.placeholders); + get placeholders(): Placeholder[] { + if (!this._placeholders) { + // fill in placeholders + this._placeholders = []; + walk(this.children, candidate => { + if (candidate instanceof Placeholder) { + this.placeholders.push(candidate); + } + return true; + }); + } + return this._placeholders; } offset(marker: Marker): number { let pos = 0; let found = false; - walk(this.marker, candidate => { + walk(this.children, candidate => { if (candidate === marker) { found = true; return false; @@ -263,7 +276,7 @@ export class TextmateSnippet { return pos; } - len(marker: Marker): number { + fullLen(marker: Marker): number { let ret = 0; walk([marker], marker => { ret += marker.len(); @@ -285,22 +298,31 @@ export class TextmateSnippet { } get text() { - return Marker.toString(this.marker); + return Marker.toString(this.children); } resolveVariables(resolver: { resolve(name: string): string }): this { - walk(this.marker, candidate => { + walk(this.children, candidate => { if (candidate instanceof Variable) { candidate.resolvedValue = resolver.resolve(candidate.name); if (candidate.isDefined) { // remove default value from resolved variable - candidate.defaultValue.length = 0; + candidate.children = []; } } return true; }); return this; } + + replace(marker: Marker, others: Marker[]): void { + const { parent } = marker; + const idx = parent.children.indexOf(marker); + const newChildren = parent.children.slice(0); + newChildren.splice(idx, 1, ...others); + parent.children = newChildren; + this._placeholders = undefined; + } } export class SnippetParser { @@ -349,17 +371,17 @@ export class SnippetParser { // fill in default values for repeated placeholders // like `${1:foo}and$1` becomes ${1:foo}and${1:foo} if (!placeholderDefaultValues.has(thisMarker.index)) { - placeholderDefaultValues.set(thisMarker.index, thisMarker.defaultValue); - } else if (thisMarker.defaultValue.length === 0) { - thisMarker.defaultValue = placeholderDefaultValues.get(thisMarker.index).slice(0); + placeholderDefaultValues.set(thisMarker.index, thisMarker.children); + } else if (thisMarker.children.length === 0) { + thisMarker.children = placeholderDefaultValues.get(thisMarker.index).slice(0); } - if (thisMarker.defaultValue.length > 0) { - walk(thisMarker.defaultValue, placeholderDefaultValues); + if (thisMarker.children.length > 0) { + walk(thisMarker.children, placeholderDefaultValues); } } else if (thisMarker instanceof Variable) { - walk(thisMarker.defaultValue, placeholderDefaultValues); + walk(thisMarker.children, placeholderDefaultValues); } else if (i > 0 && thisMarker instanceof Text && marker[i - 1] instanceof Text) { (marker[i - 1]).string += (marker[i]).string; diff --git a/src/vs/editor/contrib/snippet/browser/snippetSession.ts b/src/vs/editor/contrib/snippet/browser/snippetSession.ts index 4a5d4cc9e41..f319844d5c5 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetSession.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetSession.ts @@ -65,7 +65,7 @@ export class OneSnippet { // create a decoration for each placeholder for (const placeholder of this._snippet.placeholders) { const placeholderOffset = this._snippet.offset(placeholder); - const placeholderLen = this._snippet.len(placeholder); + const placeholderLen = this._snippet.fullLen(placeholder); const range = Range.fromPositions( model.getPositionAt(this._offset + placeholderOffset), model.getPositionAt(this._offset + placeholderOffset + placeholderLen) diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetParser.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetParser.test.ts index 66e204e9da2..dc697aa740c 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetParser.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetParser.test.ts @@ -153,13 +153,13 @@ suite('SnippetParser', () => { assertTextAndMarker('foo${1:bar\\}${2:foo}}', 'foobar}foo', Text, Placeholder); let [, placeholder] = new SnippetParser(true, false).parse('foo${1:bar\\}${2:foo}}'); - let { defaultValue } = (placeholder); + let { children } = (placeholder); assert.equal((placeholder).index, '1'); - assert.ok(defaultValue[0] instanceof Text); - assert.equal(defaultValue[0].toString(), 'bar}'); - assert.ok(defaultValue[1] instanceof Placeholder); - assert.equal(defaultValue[1].toString(), 'foo'); + assert.ok(children[0] instanceof Text); + assert.equal(children[0].toString(), 'bar}'); + assert.ok(children[1] instanceof Placeholder); + assert.equal(children[1].toString(), 'foo'); }); test('Parser, placeholder', () => { @@ -225,17 +225,17 @@ suite('SnippetParser', () => { const placeholder = marker[1]; assert.equal(placeholder, false); assert.equal(placeholder.index, '1'); - assert.equal(placeholder.defaultValue.length, 3); - assert.ok(placeholder.defaultValue[0] instanceof Text); - assert.ok(placeholder.defaultValue[1] instanceof Variable); - assert.ok(placeholder.defaultValue[2] instanceof Text); - assert.equal(placeholder.defaultValue[0].toString(), ' '); - assert.equal(placeholder.defaultValue[1].toString(), ''); - assert.equal(placeholder.defaultValue[2].toString(), ' '); - - const nestedVariable = placeholder.defaultValue[1]; + assert.equal(placeholder.children.length, 3); + assert.ok(placeholder.children[0] instanceof Text); + assert.ok(placeholder.children[1] instanceof Variable); + assert.ok(placeholder.children[2] instanceof Text); + assert.equal(placeholder.children[0].toString(), ' '); + assert.equal(placeholder.children[1].toString(), ''); + assert.equal(placeholder.children[2].toString(), ' '); + + const nestedVariable = placeholder.children[1]; assert.equal(nestedVariable.name, 'TM_SELECTED_TEXT'); - assert.equal(nestedVariable.defaultValue.length, 0); + assert.equal(nestedVariable.children.length, 0); marker = new SnippetParser().parse('$TM_SELECTED_TEXT'); assert.equal(marker.length, 1); @@ -268,13 +268,13 @@ suite('SnippetParser', () => { const [p1, , p2, , p3] = new SnippetParser().parse('{{first}}-{{2:}}-{{second}}-{{1:}}'); assert.equal((p1).index, 'first'); - assert.equal(Marker.toString((p1).defaultValue), 'first'); + assert.equal(Marker.toString((p1).children), 'first'); assert.equal((p2).index, '2'); - assert.equal(Marker.toString((p2).defaultValue), ''); + assert.equal(Marker.toString((p2).children), ''); assert.equal((p3).index, 'second'); - assert.equal(Marker.toString((p3).defaultValue), 'second'); + assert.equal(Marker.toString((p3).children), 'second'); }); test('Parser, default placeholder values', () => { @@ -284,12 +284,12 @@ suite('SnippetParser', () => { const [, p1, , p2] = new SnippetParser().parse('errorContext: `${1:err}`, error:$1'); assert.equal((p1).index, '1'); - assert.equal((p1).defaultValue.length, '1'); - assert.equal(((p1).defaultValue[0]), 'err'); + assert.equal((p1).children.length, '1'); + assert.equal(((p1).children[0]), 'err'); assert.equal((p2).index, '1'); - assert.equal((p2).defaultValue.length, '1'); - assert.equal(((p2).defaultValue[0]), 'err'); + assert.equal((p2).children.length, '1'); + assert.equal(((p2).children[0]), 'err'); }); @@ -309,8 +309,8 @@ suite('SnippetParser', () => { test('marker#len', () => { function assertLen(template: string, ...lengths: number[]): void { - const { marker } = SnippetParser.parse(template); - walk(marker, m => { + const { children } = SnippetParser.parse(template); + walk(children, m => { const expected = lengths.shift(); assert.equal(m.len(), expected); return true; @@ -335,15 +335,15 @@ suite('SnippetParser', () => { assert.equal(first.index, '1'); assert.equal(second.index, '2'); assert.ok(second.parent === first); - assert.ok(first.parent === undefined); + assert.ok(first.parent === snippet); snippet = SnippetParser.parse('${VAR:default${1:value}}$0'); assert.equal(snippet.placeholders.length, 2); [first] = snippet.placeholders; assert.equal(first.index, '1'); - assert.ok(snippet.marker[0] instanceof Variable); - assert.ok(first.parent === snippet.marker[0]); + assert.ok(snippet.children[0] instanceof Variable); + assert.ok(first.parent === snippet.children[0]); }); test('TextmateSnippet#enclosingPlaceholders', function () { @@ -356,13 +356,13 @@ suite('SnippetParser', () => { test('TextmateSnippet#offset', () => { let snippet = SnippetParser.parse('te$1xt'); - assert.equal(snippet.offset(snippet.marker[0]), 0); - assert.equal(snippet.offset(snippet.marker[1]), 2); - assert.equal(snippet.offset(snippet.marker[2]), 2); + assert.equal(snippet.offset(snippet.children[0]), 0); + assert.equal(snippet.offset(snippet.children[1]), 2); + assert.equal(snippet.offset(snippet.children[2]), 2); snippet = SnippetParser.parse('${TM_SELECTED_TEXT:def}'); - assert.equal(snippet.offset(snippet.marker[0]), 0); - assert.equal(snippet.offset((snippet.marker[0]).defaultValue[0]), 0); + assert.equal(snippet.offset(snippet.children[0]), 0); + assert.equal(snippet.offset((snippet.children[0]).children[0]), 0); // forgein marker assert.equal(snippet.offset(new Text('foo')), -1); @@ -386,4 +386,18 @@ suite('SnippetParser', () => { placeholders = snippet.placeholders; assert.equal(placeholders.length, 3); }); + + test('TextmateSnippet#replace', function () { + let snippet = SnippetParser.parse('aaa${1:bbb${2:ccc}}$0'); + + assert.equal(snippet.placeholders.length, 3); + const [, second] = snippet.placeholders; + assert.equal(second.index, '2'); + + let nested = SnippetParser.parse('ddd$1eee$0'); + snippet.replace(second, nested.children); + + assert.equal(snippet.text, 'aaabbbdddeee'); + assert.equal(snippet.placeholders.length, 4); + }); }); diff --git a/src/vs/workbench/parts/emmet/electron-browser/editorAccessor.ts b/src/vs/workbench/parts/emmet/electron-browser/editorAccessor.ts index 26f7cf390e7..f5e1ca1e52c 100644 --- a/src/vs/workbench/parts/emmet/electron-browser/editorAccessor.ts +++ b/src/vs/workbench/parts/emmet/electron-browser/editorAccessor.ts @@ -144,14 +144,14 @@ export class EditorAccessor implements emmet.Editor { return SnippetParser.escape(marker.string); } else if (marker instanceof Placeholder) { - if (marker.defaultValue.length > 0) { - return `\${${marker.index}:${marker.defaultValue.map(toSnippetString).join('')}}`; + if (marker.children.length > 0) { + return `\${${marker.index}:${marker.children.map(toSnippetString).join('')}}`; } else { return `\$${marker.index}`; } } else if (marker instanceof Variable) { - if (marker.defaultValue.length > 0) { - return `\${${marker.name}:${marker.defaultValue.map(toSnippetString).join('')}}`; + if (marker.children.length > 0) { + return `\${${marker.name}:${marker.children.map(toSnippetString).join('')}}`; } else { return `\$${marker.name}`; } diff --git a/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.ts b/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.ts index dcdfe17498a..899bc5a55d8 100644 --- a/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.ts +++ b/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.ts @@ -169,13 +169,13 @@ function _rewriteBogousVariables(snippet: ISnippet): boolean { return SnippetParser.escape(marker.string); } else if (marker instanceof Placeholder) { - if (marker.defaultValue.length > 0) { - return `\${${marker.index}:${marker.defaultValue.map(fixBogousVariables).join('')}}`; + if (marker.children.length > 0) { + return `\${${marker.index}:${marker.children.map(fixBogousVariables).join('')}}`; } else { return `\$${marker.index}`; } } else if (marker instanceof Variable) { - if (marker.defaultValue.length === 0 && !EditorSnippetVariableResolver.VariableNames[marker.name]) { + if (marker.children.length === 0 && !EditorSnippetVariableResolver.VariableNames[marker.name]) { // a 'variable' without a default value and not being one of our supported // variables is automatically turing into a placeholder. This is to restore // a bug we had before. So `${foo}` becomes `${N:foo}` @@ -183,8 +183,8 @@ function _rewriteBogousVariables(snippet: ISnippet): boolean { placeholders.set(marker.name, index); return `\${${index++}:${marker.name}}`; - } else if (marker.defaultValue.length > 0) { - return `\${${marker.name}:${marker.defaultValue.map(fixBogousVariables).join('')}}`; + } else if (marker.children.length > 0) { + return `\${${marker.name}:${marker.children.map(fixBogousVariables).join('')}}`; } else { return `\$${marker.name}`; } -- GitLab From be76e31cb9113ac36d3469a937bf69319bafbc08 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Thu, 1 Jun 2017 10:39:28 +0200 Subject: [PATCH 0423/1347] #26948 Publish tree api --- src/vs/vscode.d.ts | 100 +++++++++++++++++++++++++++++++++++ src/vs/vscode.proposed.d.ts | 102 ------------------------------------ 2 files changed, 100 insertions(+), 102 deletions(-) diff --git a/src/vs/vscode.d.ts b/src/vs/vscode.d.ts index 1943316e026..b0670a90ba7 100644 --- a/src/vs/vscode.d.ts +++ b/src/vs/vscode.d.ts @@ -4007,6 +4007,106 @@ declare module 'vscode' { * @return A new Terminal. */ export function createTerminal(options: TerminalOptions): Terminal; + + /** + * Register a [TreeDataProvider](#TreeDataProvider) for the view contributed using the extension point `views`. + * @param viewId Id of the view contributed using the extension point `views`. + * @param treeDataProvider A [TreeDataProvider](#TreeDataProvider) that provides tree data for the view + */ + export function registerTreeDataProvider(viewId: string, treeDataProvider: TreeDataProvider): Disposable; + } + + /** + * A data provider that provides tree data + */ + export interface TreeDataProvider { + /** + * An optional event to signal that an element or root has changed. + * To signal that root has changed, do not pass any argument or pass `undefined` or `null`. + */ + onDidChangeTreeData?: Event; + + /** + * Get [TreeItem](#TreeItem) representation of the `element` + * + * @param element The element for which [TreeItem](#TreeItem) representation is asked for. + * @return [TreeItem](#TreeItem) representation of the element + */ + getTreeItem(element: T): TreeItem | Thenable; + + /** + * Get the children of `element` or root if no element is passed. + * + * @param element The element from which the provider gets children. Can be `undefined`. + * @return Children of `element` or root if no element is passed. + */ + getChildren(element?: T): ProviderResult; + } + + export class TreeItem { + /** + * A human-readable string describing this item + */ + label: string; + + /** + * The icon path for the tree item + */ + iconPath?: string | Uri | { light: string | Uri; dark: string | Uri }; + + /** + * The [command](#Command) which should be run when the tree item is selected. + */ + command?: Command; + + /** + * [TreeItemCollapsibleState](#TreeItemCollapsibleState) of the tree item. + */ + collapsibleState?: TreeItemCollapsibleState; + + /** + * Context value of the tree item. This can be used to contribute item specific actions in the tree. + * For example, a tree item is given a context value as `folder`. When contributing actions to `view/item/context` + * using `menus` extension point, you can specify context value for key `viewItem` in `when` expression like `viewItem == folder`. + * ``` + * "contributes": { + * "menus": { + * "view/item/context": [ + * { + * "command": "extension.deleteFolder", + * "when": "viewItem == folder" + * } + * ] + * } + * } + * ``` + * This will show action `extension.deleteFolder` only for items with `contextValue` is `folder`. + */ + contextValue?: string; + + /** + * @param label A human-readable string describing this item + * @param collapsibleState [TreeItemCollapsibleState](#TreeItemCollapsibleState) of the tree item. Default is [TreeItemCollapsibleState.None](#TreeItemCollapsibleState.None) + */ + constructor(label: string, collapsibleState?: TreeItemCollapsibleState); + } + + /** + * Collapsible state of the tree item + */ + export enum TreeItemCollapsibleState { + /** + * Determines an item can be neither collapsed nor expanded. Implies it has no children. + */ + None = 0, + /** + * Determines an item is collapsed + */ + Collapsed = 1, + /** + * Determines an item is expanded + */ + Expanded = 2 } /** diff --git a/src/vs/vscode.proposed.d.ts b/src/vs/vscode.proposed.d.ts index 6e1ea7f6d9f..bd8dd3dd51e 100644 --- a/src/vs/vscode.proposed.d.ts +++ b/src/vs/vscode.proposed.d.ts @@ -341,108 +341,6 @@ declare module 'vscode' { export function sampleFunction(): Thenable; } - export namespace window { - /** - * Register a [TreeDataProvider](#TreeDataProvider) for the view contributed using the extension point `views`. - * @param viewId Id of the view contributed using the extension point `views`. - * @param treeDataProvider A [TreeDataProvider](#TreeDataProvider) that provides tree data for the view - */ - export function registerTreeDataProvider(viewId: string, treeDataProvider: TreeDataProvider): Disposable; - } - - /** - * A data provider that provides tree data - */ - export interface TreeDataProvider { - /** - * An optional event to signal that an element or root has changed. - * To signal that root has changed, do not pass any argument or pass `undefined` or `null`. - */ - onDidChangeTreeData?: Event; - - /** - * Get [TreeItem](#TreeItem) representation of the `element` - * - * @param element The element for which [TreeItem](#TreeItem) representation is asked for. - * @return [TreeItem](#TreeItem) representation of the element - */ - getTreeItem(element: T): TreeItem | Thenable; - - /** - * Get the children of `element` or root if no element is passed. - * - * @param element The element from which the provider gets children. Can be `undefined`. - * @return Children of `element` or root if no element is passed. - */ - getChildren(element?: T): ProviderResult; - } - - export class TreeItem { - /** - * A human-readable string describing this item - */ - label: string; - - /** - * The icon path for the tree item - */ - iconPath?: string | Uri | { light: string | Uri; dark: string | Uri }; - - /** - * The [command](#Command) which should be run when the tree item is selected. - */ - command?: Command; - - /** - * [TreeItemCollapsibleState](#TreeItemCollapsibleState) of the tree item. - */ - collapsibleState?: TreeItemCollapsibleState; - - /** - * Context value of the tree item. This can be used to contribute item specific actions in the tree. - * For example, a tree item is given a context value as `folder`. When contributing actions to `view/item/context` - * using `menus` extension point, you can specify context value for key `viewItem` in `when` expression like `viewItem == folder`. - * ``` - * "contributes": { - * "menus": { - * "view/item/context": [ - * { - * "command": "extension.deleteFolder", - * "when": "viewItem == folder" - * } - * ] - * } - * } - * ``` - * This will show action `extension.deleteFolder` only for items with `contextValue` is `folder`. - */ - contextValue?: string; - - /** - * @param label A human-readable string describing this item - * @param collapsibleState [TreeItemCollapsibleState](#TreeItemCollapsibleState) of the tree item. Default is [TreeItemCollapsibleState.None](#TreeItemCollapsibleState.None) - */ - constructor(label: string, collapsibleState?: TreeItemCollapsibleState); - } - - /** - * Collapsible state of the tree item - */ - export enum TreeItemCollapsibleState { - /** - * Determines an item can be neither collapsed nor expanded. Implies it has no children. - */ - None = 0, - /** - * Determines an item is collapsed - */ - Collapsed = 1, - /** - * Determines an item is expanded - */ - Expanded = 2 - } - /** * The contiguous set of modified lines in a diff. */ -- GitLab From eeb076cc71bcc358d6ebe830d049a8791d7063cc Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 1 Jun 2017 10:43:15 +0200 Subject: [PATCH 0424/1347] Update distro hash --- ThirdPartyNotices.txt | 4 +--- package.json | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/ThirdPartyNotices.txt b/ThirdPartyNotices.txt index 958cac6b8d3..84e13002af2 100644 --- a/ThirdPartyNotices.txt +++ b/ThirdPartyNotices.txt @@ -1,6 +1,4 @@ -===================BEGIN GENERATOR LOG -===================END GENERATOR LOG -microsoft-vscode +dmicrosoft-vscode THIRD-PARTY SOFTWARE NOTICES AND INFORMATION Do Not Translate or Localize diff --git a/package.json b/package.json index 0c8f77e4dba..127d1dfb457 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "code-oss-dev", "version": "1.13.0", "electronVersion": "1.6.6", - "distro": "6a21d9ea82740d478d8b3fb72ec2a63d27b8a29c", + "distro": "cb257c519d1ee526acfd00c0a7adc6b0fa4c18d2", "author": { "name": "Microsoft Corporation" }, -- GitLab From 41463b1b56cec758c7888b65166eb28e2f7ee2a2 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Thu, 1 Jun 2017 10:45:50 +0200 Subject: [PATCH 0425/1347] Add pt-BR locale only in non-stable build quality. --- build/gulpfile.vscode.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index 942bb3847e3..7334fd94fce 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -158,7 +158,10 @@ gulp.task('electron', ['clean-electron'], getElectron(process.arch)); gulp.task('electron-ia32', ['clean-electron'], getElectron('ia32')); gulp.task('electron-x64', ['clean-electron'], getElectron('x64')); -const languages = ['chs', 'cht', 'jpn', 'kor', 'deu', 'fra', 'esn', 'rus', 'ita', 'ptb']; +var languages = ['chs', 'cht', 'jpn', 'kor', 'deu', 'fra', 'esn', 'rus', 'ita']; +if (product.quality !== 'stable') { + languages.concat(['ptb']); +} /** * Compute checksums for some files. -- GitLab From 19aecfd367cb4de1df5683fac5f177cf5116f095 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Thu, 1 Jun 2017 11:12:01 +0200 Subject: [PATCH 0426/1347] Addresses #27672: Task Detection For Gulp --- extensions/grunt/src/main.ts | 19 +++++++++++++++---- extensions/gulp/src/main.ts | 20 ++++++++++++++++---- extensions/jake/src/main.ts | 18 +++++++++++++++--- 3 files changed, 46 insertions(+), 11 deletions(-) diff --git a/extensions/grunt/src/main.ts b/extensions/grunt/src/main.ts index a90eff6c933..6af05a0d312 100644 --- a/extensions/grunt/src/main.ts +++ b/extensions/grunt/src/main.ts @@ -73,6 +73,14 @@ function exec(command: string, options: cp.ExecOptions): Promise<{ stdout: strin }); } +let _channel: vscode.OutputChannel; +function getOutputChannel(): vscode.OutputChannel { + if (!_channel) { + _channel = vscode.window.createOutputChannel('Grunt Auto Detection'); + } + return _channel; +} + async function getGruntTasks(): Promise { let workspaceRoot = vscode.workspace.rootPath; let emptyTasks: vscode.Task[] = []; @@ -95,12 +103,11 @@ async function getGruntTasks(): Promise { } let commandLine = `${command} --help --no-color`; - let channel = vscode.window.createOutputChannel('tasks'); try { let { stdout, stderr } = await exec(commandLine, { cwd: workspaceRoot }); if (stderr) { - channel.appendLine(stderr); - channel.show(true); + getOutputChannel().appendLine(stderr); + getOutputChannel().show(true); } let result: vscode.Task[] = []; if (stdout) { @@ -166,11 +173,15 @@ async function getGruntTasks(): Promise { } return result; } catch (err) { + let channel = getOutputChannel(); if (err.stderr) { channel.appendLine(err.stderr); - channel.show(true); + } + if (err.stdout) { + channel.appendLine(err.stdout); } channel.appendLine(localize('execFailed', 'Auto detecting Grunt failed with error: {0}', err.error ? err.error.toString() : 'unknown')); + channel.show(true); return emptyTasks; } } \ No newline at end of file diff --git a/extensions/gulp/src/main.ts b/extensions/gulp/src/main.ts index c75a8ce5d9c..1de05aa70d8 100644 --- a/extensions/gulp/src/main.ts +++ b/extensions/gulp/src/main.ts @@ -73,6 +73,14 @@ function exec(command: string, options: cp.ExecOptions): Promise<{ stdout: strin }); } +let _channel: vscode.OutputChannel; +function getOutputChannel(): vscode.OutputChannel { + if (!_channel) { + _channel = vscode.window.createOutputChannel('Gulp Auto Detection'); + } + return _channel; +} + async function getGulpTasks(): Promise { let workspaceRoot = vscode.workspace.rootPath; let emptyTasks: vscode.Task[] = []; @@ -98,12 +106,11 @@ async function getGulpTasks(): Promise { } let commandLine = `${gulpCommand} --tasks-simple --no-color`; - let channel = vscode.window.createOutputChannel('tasks'); try { let { stdout, stderr } = await exec(commandLine, { cwd: workspaceRoot }); - if (stderr) { - channel.appendLine(stderr); - channel.show(true); + if (stderr && stderr.length > 0) { + getOutputChannel().appendLine(stderr); + getOutputChannel().show(true); } let result: vscode.Task[] = []; if (stdout) { @@ -137,10 +144,15 @@ async function getGulpTasks(): Promise { } return result; } catch (err) { + let channel = getOutputChannel(); if (err.stderr) { channel.appendLine(err.stderr); } + if (err.stdout) { + channel.appendLine(err.stdout); + } channel.appendLine(localize('execFailed', 'Auto detecting gulp failed with error: {0}', err.error ? err.error.toString() : 'unknown')); + channel.show(true); return emptyTasks; } } \ No newline at end of file diff --git a/extensions/jake/src/main.ts b/extensions/jake/src/main.ts index 25d93a29780..eb87180ca78 100644 --- a/extensions/jake/src/main.ts +++ b/extensions/jake/src/main.ts @@ -73,6 +73,14 @@ function exec(command: string, options: cp.ExecOptions): Promise<{ stdout: strin }); } +let _channel: vscode.OutputChannel; +function getOutputChannel(): vscode.OutputChannel { + if (!_channel) { + _channel = vscode.window.createOutputChannel('Jake Auto Detection'); + } + return _channel; +} + async function getJakeTasks(): Promise { let workspaceRoot = vscode.workspace.rootPath; let emptyTasks: vscode.Task[] = []; @@ -98,12 +106,11 @@ async function getJakeTasks(): Promise { } let commandLine = `${jakeCommand} --tasks`; - let channel = vscode.window.createOutputChannel('tasks'); try { let { stdout, stderr } = await exec(commandLine, { cwd: workspaceRoot }); if (stderr) { - channel.appendLine(stderr); - channel.show(true); + getOutputChannel().appendLine(stderr); + getOutputChannel().show(true); } let result: vscode.Task[] = []; if (stdout) { @@ -142,10 +149,15 @@ async function getJakeTasks(): Promise { } return result; } catch (err) { + let channel = getOutputChannel(); if (err.stderr) { channel.appendLine(err.stderr); } + if (err.stdout) { + channel.appendLine(err.stdout); + } channel.appendLine(localize('execFailed', 'Auto detecting Jake failed with error: {0}', err.error ? err.error.toString() : 'unknown')); + channel.show(true); return emptyTasks; } } \ No newline at end of file -- GitLab From c3d478f336c47ae6de954d5b3f6d3215179d9f02 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 1 Jun 2017 11:31:19 +0200 Subject: [PATCH 0427/1347] fix #27753 --- .../mainThreadExtensionService.ts | 38 ++++++++----------- 1 file changed, 16 insertions(+), 22 deletions(-) diff --git a/src/vs/workbench/api/electron-browser/mainThreadExtensionService.ts b/src/vs/workbench/api/electron-browser/mainThreadExtensionService.ts index 14b8d69f5dc..43b35d1908a 100644 --- a/src/vs/workbench/api/electron-browser/mainThreadExtensionService.ts +++ b/src/vs/workbench/api/electron-browser/mainThreadExtensionService.ts @@ -89,13 +89,17 @@ export class MainProcessExtensionService extends AbstractExtensionService Date: Thu, 1 Jun 2017 11:36:27 +0200 Subject: [PATCH 0428/1347] don't have unit tests that take multiple seconds fixes #27821 --- .../workbench/parts/output/test/bufferedContent.test.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/vs/workbench/parts/output/test/bufferedContent.test.ts b/src/vs/workbench/parts/output/test/bufferedContent.test.ts index f94f61c9cc0..06a00d45b5b 100644 --- a/src/vs/workbench/parts/output/test/bufferedContent.test.ts +++ b/src/vs/workbench/parts/output/test/bufferedContent.test.ts @@ -41,19 +41,19 @@ suite('Workbench - Output Buffered Content', () => { bufferedContent.append('first line'); const firstDelta = bufferedContent.getDelta(); let longString = ''; - for (var i = 0; i < 50000; i++) { + for (var i = 0; i < 5000; i++) { bufferedContent.append(i.toString()); longString += i.toString(); } const secondDelta = bufferedContent.getDelta(firstDelta); assert.equal(secondDelta.append, true); - assert.equal(secondDelta.value.substr(secondDelta.value.length - 5), '49999'); + assert.equal(secondDelta.value.substr(secondDelta.value.length - 4), '4999'); longString = longString + longString + longString + longString; bufferedContent.append(longString); bufferedContent.append(longString); const thirdDelta = bufferedContent.getDelta(firstDelta); - assert.equal(!!thirdDelta.append, false); - assert.equal(thirdDelta.value.substr(thirdDelta.value.length - 5), '49999'); + assert.equal(!!thirdDelta.append, true); + assert.equal(thirdDelta.value.substr(thirdDelta.value.length - 4), '4999'); bufferedContent.clear(); assert.equal(bufferedContent.getDelta().value, ''); -- GitLab From af63affc986b51008a70e0440eed7f67bdb87105 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Thu, 1 Jun 2017 11:47:34 +0200 Subject: [PATCH 0429/1347] Fixes #27665: Let the search process never inherit `process.execArgv` --- src/vs/base/parts/ipc/node/ipc.cp.ts | 12 ++++++++++++ .../workbench/services/search/node/searchService.ts | 5 +++++ 2 files changed, 17 insertions(+) diff --git a/src/vs/base/parts/ipc/node/ipc.cp.ts b/src/vs/base/parts/ipc/node/ipc.cp.ts index 940c18638fb..21b1b3f5531 100644 --- a/src/vs/base/parts/ipc/node/ipc.cp.ts +++ b/src/vs/base/parts/ipc/node/ipc.cp.ts @@ -56,6 +56,14 @@ export interface IIPCOptions { */ debugBrk?: number; + /** + * See https://github.com/Microsoft/vscode/issues/27665 + * Allows to pass in fresh execArgv to the forked process such that it doesn't inherit them from `process.execArgv`. + * e.g. Launching the extension host process with `--debug-brk=xxx` and then forking a process from the extension host + * results in the forked process inheriting `--debug-brk=xxx`. + */ + freshExecArgv?: boolean; + /** * Enables our createQueuedSender helper for this Client. Uses a queue when the internal Node.js queue is * full of messages - see notes on that method. @@ -125,6 +133,10 @@ export class Client implements IChannelClient, IDisposable { forkOpts.env = assign(forkOpts.env, this.options.env); } + if (this.options && this.options.freshExecArgv) { + forkOpts.execArgv = []; + } + if (this.options && typeof this.options.debug === 'number') { forkOpts.execArgv = ['--nolazy', '--debug=' + this.options.debug]; } diff --git a/src/vs/workbench/services/search/node/searchService.ts b/src/vs/workbench/services/search/node/searchService.ts index 1c2d62c29d1..ac68c6c4e28 100644 --- a/src/vs/workbench/services/search/node/searchService.ts +++ b/src/vs/workbench/services/search/node/searchService.ts @@ -207,6 +207,11 @@ export class DiskSearch { serverName: 'Search', timeout: timeout, args: ['--type=searchService'], + // See https://github.com/Microsoft/vscode/issues/27665 + // Pass in fresh execArgv to the forked process such that it doesn't inherit them from `process.execArgv`. + // e.g. Launching the extension host process with `--debug-brk=xxx` and then forking a process from the extension host + // results in the forked process inheriting `--debug-brk=xxx`. + freshExecArgv: true, env: { AMD_ENTRYPOINT: 'vs/workbench/services/search/node/searchApp', PIPE_LOGGING: 'true', -- GitLab From 16aa259d470cc091888cf848dd666979f68a4cea Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Thu, 1 Jun 2017 12:31:50 +0200 Subject: [PATCH 0430/1347] Fixes #27831: The find widget should use aria-hidden when it is hidden --- src/vs/editor/contrib/find/browser/findWidget.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/vs/editor/contrib/find/browser/findWidget.ts b/src/vs/editor/contrib/find/browser/findWidget.ts index 409caf8fb73..de4cbdea320 100644 --- a/src/vs/editor/contrib/find/browser/findWidget.ts +++ b/src/vs/editor/contrib/find/browser/findWidget.ts @@ -402,6 +402,7 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas setTimeout(() => { dom.addClass(this._domNode, 'visible'); + this._domNode.setAttribute('aria-hidden', 'false'); if (!animate) { dom.addClass(this._domNode, 'noanimation'); setTimeout(() => { @@ -421,6 +422,7 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas this._updateButtons(); dom.removeClass(this._domNode, 'visible'); + this._domNode.setAttribute('aria-hidden', 'true'); if (focusTheEditor) { this._codeEditor.focus(); } @@ -812,7 +814,7 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas // Widget this._domNode = document.createElement('div'); this._domNode.className = 'editor-widget find-widget'; - this._domNode.setAttribute('aria-hidden', 'false'); + this._domNode.setAttribute('aria-hidden', 'true'); this._domNode.appendChild(this._toggleReplaceBtn.domNode); this._domNode.appendChild(findPart); -- GitLab From 8f2d12c97e74b22147613f5f52e28ef75deaebff Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 1 Jun 2017 12:42:00 +0200 Subject: [PATCH 0431/1347] Activity bar: active item decoration lost when hovering (fixes #27822) --- .../browser/parts/activitybar/activitybarActions.ts | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts b/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts index 7aab7fc7c7d..ee8df3e9d27 100644 --- a/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts +++ b/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts @@ -458,9 +458,9 @@ export class ViewletActionItem extends ActivityActionItem { protected _updateChecked(): void { if (this.getAction().checked) { - this.$container.addClass('active'); + this.$container.addClass('checked'); } else { - this.$container.removeClass('active'); + this.$container.removeClass('checked'); } } @@ -723,7 +723,9 @@ registerThemingParticipant((theme: ITheme, collector: ICssStyleCollector) => { } .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item.active:before, - .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item.active:hover:before { + .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item.active:hover:before, + .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item.checked:before, + .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item.checked:hover:before { outline: 1px solid; } @@ -732,6 +734,7 @@ registerThemingParticipant((theme: ITheme, collector: ICssStyleCollector) => { } .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item.active:before, + .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item.checked:before, .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item:hover:before { opacity: 1; } @@ -742,6 +745,8 @@ registerThemingParticipant((theme: ITheme, collector: ICssStyleCollector) => { .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item.active:before, .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item.active:hover:before, + .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item.checked:before, + .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item.checked:hover:before, .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item:hover:before { outline-color: ${outline}; } @@ -754,6 +759,7 @@ registerThemingParticipant((theme: ITheme, collector: ICssStyleCollector) => { if (focusBorderColor) { collector.addRule(` .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item.active .action-label, + .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item.checked .action-label, .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item:focus .action-label, .monaco-workbench > .activitybar > .content .monaco-action-bar .action-item:hover .action-label { opacity: 1; -- GitLab From 9496e10c117c89f6f64720887aeb30e841c7a157 Mon Sep 17 00:00:00 2001 From: Andre Weinand Date: Thu, 1 Jun 2017 12:35:41 +0200 Subject: [PATCH 0432/1347] use final 1.20.0 version of DAP modules --- npm-shrinkwrap.json | 6 +++--- package.json | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/npm-shrinkwrap.json b/npm-shrinkwrap.json index d7f219b1638..3e962373c7d 100644 --- a/npm-shrinkwrap.json +++ b/npm-shrinkwrap.json @@ -410,9 +410,9 @@ "resolved": "git://github.com/jrieken/v8-profiler.git#bc0803a4d4b2150b8a1bbffa80270769007036c2" }, "vscode-debugprotocol": { - "version": "1.19.0", - "from": "vscode-debugprotocol@1.19.0", - "resolved": "https://registry.npmjs.org/vscode-debugprotocol/-/vscode-debugprotocol-1.19.0.tgz" + "version": "1.20.0", + "from": "vscode-debugprotocol@1.20.0", + "resolved": "https://registry.npmjs.org/vscode-debugprotocol/-/vscode-debugprotocol-1.20.0.tgz" }, "vscode-ripgrep": { "version": "0.0.12", diff --git a/package.json b/package.json index 127d1dfb457..f423138397b 100644 --- a/package.json +++ b/package.json @@ -38,7 +38,7 @@ "node-pty": "0.6.6", "semver": "4.3.6", "v8-profiler": "jrieken/v8-profiler#vscode", - "vscode-debugprotocol": "1.19.0", + "vscode-debugprotocol": "1.20.0", "vscode-ripgrep": "0.0.12", "vscode-textmate": "^3.1.5", "winreg": "1.2.0", -- GitLab From ab69231014b9a35480a0c88ee665057e57816cc5 Mon Sep 17 00:00:00 2001 From: Andre Weinand Date: Thu, 1 Jun 2017 12:47:50 +0200 Subject: [PATCH 0433/1347] node-debug@1.13.8 (translations) --- build/gulpfile.vscode.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index 7334fd94fce..c9d3cd27a37 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -42,7 +42,7 @@ const nodeModules = ['electron', 'original-fs'] // Build const builtInExtensions = [ - { name: 'ms-vscode.node-debug', version: '1.13.7' }, + { name: 'ms-vscode.node-debug', version: '1.13.8' }, { name: 'ms-vscode.node-debug2', version: '1.13.1' } ]; -- GitLab From fb4a49b00083e30874bc578bbad730b453f91615 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Thu, 1 Jun 2017 12:54:18 +0200 Subject: [PATCH 0434/1347] Target only core languages for the stable build. Ref #27818 --- build/gulpfile.vscode.js | 12 +++++++----- build/lib/i18n.js | 29 ++++++++++++----------------- build/lib/i18n.ts | 29 +++++++++++------------------ build/lib/optimize.js | 3 ++- build/lib/optimize.ts | 7 ++++++- 5 files changed, 38 insertions(+), 42 deletions(-) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index c9d3cd27a37..9d5c3ff31fc 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -84,6 +84,11 @@ const BUNDLED_FILE_HEADER = [ ' *--------------------------------------------------------*/' ].join('\n'); +var languages = ['chs', 'cht', 'jpn', 'kor', 'deu', 'fra', 'esn', 'rus', 'ita']; +if (product.quality !== 'stable') { + languages = languages.concat(['ptb']); // Add languages requested by the community to non-stable builds +} + gulp.task('clean-optimized-vscode', util.rimraf('out-vscode')); gulp.task('optimize-vscode', ['clean-optimized-vscode', 'compile-build', 'compile-extensions-build'], common.optimizeTask({ entryPoints: vscodeEntryPoints, @@ -91,7 +96,8 @@ gulp.task('optimize-vscode', ['clean-optimized-vscode', 'compile-build', 'compil resources: vscodeResources, loaderConfig: common.loaderConfig(nodeModules), header: BUNDLED_FILE_HEADER, - out: 'out-vscode' + out: 'out-vscode', + languages: languages })); @@ -158,10 +164,6 @@ gulp.task('electron', ['clean-electron'], getElectron(process.arch)); gulp.task('electron-ia32', ['clean-electron'], getElectron('ia32')); gulp.task('electron-x64', ['clean-electron'], getElectron('x64')); -var languages = ['chs', 'cht', 'jpn', 'kor', 'deu', 'fra', 'esn', 'rus', 'ita']; -if (product.quality !== 'stable') { - languages.concat(['ptb']); -} /** * Compute checksums for some files. diff --git a/build/lib/i18n.js b/build/lib/i18n.js index 3f16ccc97f1..4447e34ab60 100644 --- a/build/lib/i18n.js +++ b/build/lib/i18n.js @@ -1,8 +1,8 @@ -"use strict"; /*--------------------------------------------------------------------------------------------- * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ +"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); var path = require("path"); var fs = require("fs"); @@ -207,17 +207,6 @@ XLF.parse = function (xlfString) { }); }; exports.XLF = XLF; -var vscodeLanguages = [ - 'chs', - 'cht', - 'jpn', - 'kor', - 'deu', - 'fra', - 'esn', - 'rus', - 'ita' -]; var iso639_3_to_2 = { 'chs': 'zh-cn', 'cht': 'zh-tw', @@ -347,7 +336,7 @@ function escapeCharacters(value) { } return result.join(''); } -function processCoreBundleFormat(fileHeader, json, emitter) { +function processCoreBundleFormat(fileHeader, languages, json, emitter) { var keysSection = json.keys; var messageSection = json.messages; var bundleSection = json.bundles; @@ -375,8 +364,14 @@ function processCoreBundleFormat(fileHeader, json, emitter) { }); }); var languageDirectory = path.join(__dirname, '..', '..', 'i18n'); - var languages = sortLanguages(fs.readdirSync(languageDirectory).filter(function (item) { return fs.statSync(path.join(languageDirectory, item)).isDirectory(); })); - languages.forEach(function (language) { + var languageDirs; + if (languageDirs) { + languageDirs = sortLanguages(languages); + } + else { + languageDirs = sortLanguages(fs.readdirSync(languageDirectory).filter(function (item) { return fs.statSync(path.join(languageDirectory, item)).isDirectory(); })); + } + languageDirs.forEach(function (language) { if (!language.iso639_2) { return; } @@ -448,7 +443,7 @@ function processCoreBundleFormat(fileHeader, json, emitter) { var value = statistics[key]; log(key + " has " + value + " untranslated strings."); }); - vscodeLanguages.forEach(function (language) { + languageDirs.forEach(function (language) { var iso639_2 = iso639_3_to_2[language]; if (!iso639_2) { log("\tCouldn't find iso639 2 mapping for language " + language + ". Using default language instead."); @@ -473,7 +468,7 @@ function processNlsFiles(opts) { this.emit('error', "Failed to read component file: " + file.relative); } if (BundledFormat.is(json)) { - processCoreBundleFormat(opts.fileHeader, json, this); + processCoreBundleFormat(opts.fileHeader, opts.languages, json, this); } } this.emit('data', file); diff --git a/build/lib/i18n.ts b/build/lib/i18n.ts index 9667b01fa2f..53b46933a80 100644 --- a/build/lib/i18n.ts +++ b/build/lib/i18n.ts @@ -272,18 +272,6 @@ export class XLF { }; } -const vscodeLanguages: string[] = [ - 'chs', - 'cht', - 'jpn', - 'kor', - 'deu', - 'fra', - 'esn', - 'rus', - 'ita' -]; - const iso639_3_to_2: Map = { 'chs': 'zh-cn', 'cht': 'zh-tw', @@ -420,7 +408,7 @@ function escapeCharacters(value: string): string { return result.join(''); } -function processCoreBundleFormat(fileHeader: string, json: BundledFormat, emitter: any) { +function processCoreBundleFormat(fileHeader: string, languages: string[], json: BundledFormat, emitter: any) { let keysSection = json.keys; let messageSection = json.messages; let bundleSection = json.bundles; @@ -450,8 +438,13 @@ function processCoreBundleFormat(fileHeader: string, json: BundledFormat, emitte }); let languageDirectory = path.join(__dirname, '..', '..', 'i18n'); - let languages = sortLanguages(fs.readdirSync(languageDirectory).filter((item) => fs.statSync(path.join(languageDirectory, item)).isDirectory())); - languages.forEach((language) => { + let languageDirs; + if (languageDirs) { + languageDirs = sortLanguages(languages); + } else { + languageDirs = sortLanguages(fs.readdirSync(languageDirectory).filter((item) => fs.statSync(path.join(languageDirectory, item)).isDirectory())); + } + languageDirs.forEach((language) => { if (!language.iso639_2) { return; } @@ -523,7 +516,7 @@ function processCoreBundleFormat(fileHeader: string, json: BundledFormat, emitte let value = statistics[key]; log(`${key} has ${value} untranslated strings.`); }); - vscodeLanguages.forEach(language => { + languageDirs.forEach(language => { let iso639_2 = iso639_3_to_2[language]; if (!iso639_2) { log(`\tCouldn't find iso639 2 mapping for language ${language}. Using default language instead.`); @@ -536,7 +529,7 @@ function processCoreBundleFormat(fileHeader: string, json: BundledFormat, emitte }); } -export function processNlsFiles(opts: { fileHeader: string; }): ThroughStream { +export function processNlsFiles(opts: { fileHeader: string; languages: string[] }): ThroughStream { return through(function (file: File) { let fileName = path.basename(file.path); if (fileName === 'nls.metadata.json') { @@ -547,7 +540,7 @@ export function processNlsFiles(opts: { fileHeader: string; }): ThroughStream { this.emit('error', `Failed to read component file: ${file.relative}`); } if (BundledFormat.is(json)) { - processCoreBundleFormat(opts.fileHeader, json, this); + processCoreBundleFormat(opts.fileHeader, opts.languages, json, this); } } this.emit('data', file); diff --git a/build/lib/optimize.js b/build/lib/optimize.js index d3bc1ee5c8c..1957b6dde3c 100644 --- a/build/lib/optimize.js +++ b/build/lib/optimize.js @@ -163,7 +163,8 @@ function optimizeTask(opts) { includeContent: true })) .pipe(i18n.processNlsFiles({ - fileHeader: bundledFileHeader + fileHeader: bundledFileHeader, + languages: opts.languages })) .pipe(gulp.dest(out)); }; diff --git a/build/lib/optimize.ts b/build/lib/optimize.ts index 9dbaead5f79..2fb92c5ecdf 100644 --- a/build/lib/optimize.ts +++ b/build/lib/optimize.ts @@ -158,6 +158,10 @@ export interface IOptimizeTaskOpts { * (out folder name) */ out: string; + /** + * (languages to process) + */ + languages: string[]; } export function optimizeTask(opts: IOptimizeTaskOpts): () => NodeJS.ReadWriteStream { const entryPoints = opts.entryPoints; @@ -228,7 +232,8 @@ export function optimizeTask(opts: IOptimizeTaskOpts): () => NodeJS.ReadWriteStr includeContent: true })) .pipe(i18n.processNlsFiles({ - fileHeader: bundledFileHeader + fileHeader: bundledFileHeader, + languages: opts.languages })) .pipe(gulp.dest(out)); }; -- GitLab From 2140cc91b748237fd2e02708706290d57686affe Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Thu, 1 Jun 2017 13:13:44 +0200 Subject: [PATCH 0435/1347] Fixes #27551: Add ToggleMultiCursorModifierAction and corresponding menu item --- src/vs/code/electron-main/menus.ts | 24 ++++++++++ .../codeEditor/codeEditor.contribution.ts | 1 + .../toggleMultiCursorModifier.ts | 45 +++++++++++++++++++ 3 files changed, 70 insertions(+) create mode 100644 src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.ts diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index 16f3af28054..3a5aa4756e5 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -51,6 +51,9 @@ interface IConfiguration extends IFilesConfiguration { visible: boolean; } }; + editor: { + multiCursorModifier: 'ctrlCmd' | 'alt' + }; } class KeybindingsResolver { @@ -153,6 +156,7 @@ export class VSCodeMenu { private static MAX_MENU_RECENT_ENTRIES = 10; private currentAutoSaveSetting: string; + private currentMultiCursorModifierSetting: string; private currentSidebarLocation: 'left' | 'right'; private currentStatusbarVisible: boolean; private currentActivityBarVisible: boolean; @@ -232,6 +236,12 @@ export class VSCodeMenu { updateMenu = true; } + const newMultiCursorModifierSetting = config && config.editor && config.editor.multiCursorModifier; + if (newMultiCursorModifierSetting !== this.currentMultiCursorModifierSetting) { + this.currentMultiCursorModifierSetting = newMultiCursorModifierSetting; + updateMenu = true; + } + const newSidebarLocation = config && config.workbench && config.workbench.sideBar && config.workbench.sideBar.location || 'left'; if (newSidebarLocation !== this.currentSidebarLocation) { this.currentSidebarLocation = newSidebarLocation; @@ -616,6 +626,19 @@ export class VSCodeMenu { } private setSelectionMenu(winLinuxEditMenu: Electron.Menu): void { + let multiCursorModifierLabel: string; + if (this.currentMultiCursorModifierSetting === 'ctrlCmd') { + // The default has been overwritten + multiCursorModifierLabel = nls.localize('miMultiCursorAlt', "Use Alt+Click for Multi-Cursor"); + } else { + multiCursorModifierLabel = ( + isMacintosh + ? nls.localize('miMultiCursorCmd', "Use Cmd+Click for Multi-Cursor") + : nls.localize('miMultiCursorCtrl', "Use Ctrl+Click for Multi-Cursor") + ); + } + + const multicursorModifier = this.createMenuItem(multiCursorModifierLabel, 'workbench.action.toggleMultiCursorModifier'); const insertCursorAbove = this.createMenuItem(nls.localize({ key: 'miInsertCursorAbove', comment: ['&& denotes a mnemonic'] }, "&&Add Cursor Above"), 'editor.action.insertCursorAbove'); const insertCursorBelow = this.createMenuItem(nls.localize({ key: 'miInsertCursorBelow', comment: ['&& denotes a mnemonic'] }, "A&&dd Cursor Below"), 'editor.action.insertCursorBelow'); const insertCursorAtEndOfEachLineSelected = this.createMenuItem(nls.localize({ key: 'miInsertCursorAtEndOfEachLineSelected', comment: ['&& denotes a mnemonic'] }, "Add C&&ursors to Line Ends"), 'editor.action.insertCursorAtEndOfEachLineSelected'); @@ -647,6 +670,7 @@ export class VSCodeMenu { moveLinesUp, moveLinesDown, __separator__(), + multicursorModifier, insertCursorAbove, insertCursorBelow, insertCursorAtEndOfEachLineSelected, diff --git a/src/vs/workbench/parts/codeEditor/codeEditor.contribution.ts b/src/vs/workbench/parts/codeEditor/codeEditor.contribution.ts index 7e8a05cdce0..e209510c694 100644 --- a/src/vs/workbench/parts/codeEditor/codeEditor.contribution.ts +++ b/src/vs/workbench/parts/codeEditor/codeEditor.contribution.ts @@ -3,6 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ +import './electron-browser/toggleMultiCursorModifier'; import './electron-browser/toggleRenderControlCharacter'; import './electron-browser/toggleRenderWhitespace'; import './electron-browser/toggleWordWrap'; diff --git a/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.ts b/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.ts new file mode 100644 index 00000000000..de0783f35b6 --- /dev/null +++ b/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.ts @@ -0,0 +1,45 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +'use strict'; + +import { TPromise } from 'vs/base/common/winjs.base'; +import * as nls from 'vs/nls'; +import { Registry } from 'vs/platform/platform'; +import { Action } from 'vs/base/common/actions'; +import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; +import { IWorkbenchActionRegistry, Extensions } from 'vs/workbench/common/actionRegistry'; +import { IConfigurationEditingService, ConfigurationTarget } from 'vs/workbench/services/configuration/common/configurationEditing'; +import { IConfigurationService } from "vs/platform/configuration/common/configuration"; + +export class ToggleMultiCursorModifierAction extends Action { + + public static ID = 'workbench.action.toggleMultiCursorModifier'; + public static LABEL = nls.localize('toggleLocation', "Toggle Multi-Cursor Modifier"); + + private static multiCursorModifierConfigurationKey = 'editor.multiCursorModifier'; + + constructor( + id: string, + label: string, + @IConfigurationService private configurationService: IConfigurationService, + @IConfigurationEditingService private configurationEditingService: IConfigurationEditingService + ) { + super(id, label); + + this.enabled = !!this.configurationService && !!this.configurationEditingService; + } + + public run(): TPromise { + const editorConf = this.configurationService.getConfiguration<{ multiCursorModifier: 'ctrlCmd' | 'alt' }>('editor'); + const newValue: 'ctrlCmd' | 'alt' = (editorConf.multiCursorModifier === 'ctrlCmd' ? 'alt' : 'ctrlCmd'); + + this.configurationEditingService.writeConfiguration(ConfigurationTarget.USER, { key: ToggleMultiCursorModifierAction.multiCursorModifierConfigurationKey, value: newValue }); + + return TPromise.as(null); + } +} + +const registry = Registry.as(Extensions.WorkbenchActions); +registry.registerWorkbenchAction(new SyncActionDescriptor(ToggleMultiCursorModifierAction, ToggleMultiCursorModifierAction.ID, ToggleMultiCursorModifierAction.LABEL), 'Toggle Multi-Cursor Modifier'); -- GitLab From 229fb9cadc625f32a69125e382c84c91c3c1d73d Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 1 Jun 2017 14:16:53 +0200 Subject: [PATCH 0436/1347] merge snippets, don't stack them, #27543 --- .../snippet/browser/snippetController2.ts | 86 ++-------- .../contrib/snippet/browser/snippetSession.ts | 149 +++++++++++++----- .../test/browser/snippetController2.test.ts | 38 ++--- .../test/browser/snippetParser.test.ts | 29 +++- .../test/browser/snippetSession.test.ts | 30 ++++ 5 files changed, 200 insertions(+), 132 deletions(-) diff --git a/src/vs/editor/contrib/snippet/browser/snippetController2.ts b/src/vs/editor/contrib/snippet/browser/snippetController2.ts index 96dd960845b..86c6c543eec 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetController2.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetController2.ts @@ -13,60 +13,6 @@ import { SnippetSession } from './snippetSession'; import { EditorContextKeys } from 'vs/editor/common/editorContextKeys'; import { KeyCode, KeyMod } from 'vs/base/common/keyCodes'; -class SnippetSessions { - - private _stack: SnippetSession[] = []; - - add(session: SnippetSession): number { - return this._stack.push(session); - } - - clear(): void { - dispose(this._stack); - this._stack.length = 0; - } - - get empty(): boolean { - return this._stack.length === 0; - } - - get hasPlaceholder(): boolean { - return this._stack.some(s => s.hasPlaceholder); - } - - get isAtFirstPlaceholder(): boolean { - return this._stack.every(s => s.isAtFirstPlaceholder); - } - - get isAtFinalPlaceholder(): boolean { - return !this.empty && this._stack[0].isAtLastPlaceholder; - } - - get isSelectionWithinPlaceholders(): boolean { - return this._stack.some(s => s.isSelectionWithinPlaceholders()); - } - - prev(): void { - for (let i = this._stack.length - 1; i >= 0; i--) { - const snippet = this._stack[i]; - if (!snippet.isAtFirstPlaceholder) { - snippet.prev(); - break; - } - } - } - - next(): void { - for (let i = this._stack.length - 1; i >= 0; i--) { - const snippet = this._stack[i]; - if (!snippet.isAtLastPlaceholder) { - snippet.next(); - break; - } - } - } -} - @commonEditorContribution export class SnippetController2 { @@ -82,7 +28,7 @@ export class SnippetController2 { private readonly _hasNextTabstop: IContextKey; private readonly _hasPrevTabstop: IContextKey; - private _sessions = new SnippetSessions(); + private _session: SnippetSession; private _snippetListener: IDisposable[] = []; private _modelVersionId: number; @@ -99,7 +45,7 @@ export class SnippetController2 { this._inSnippet.reset(); this._hasPrevTabstop.reset(); this._hasNextTabstop.reset(); - this._sessions.clear(); + dispose(this._session); } getId(): string { @@ -120,14 +66,12 @@ export class SnippetController2 { this._editor.getModel().pushStackElement(); } - const snippet = new SnippetSession(this._editor, template, overwriteBefore, overwriteAfter); - const newLen = this._sessions.add(snippet); - - if (newLen === 1) { + if (!this._session) { this._modelVersionId = this._editor.getModel().getAlternativeVersionId(); - snippet.insert(false); + this._session = new SnippetSession(this._editor, template, overwriteBefore, overwriteAfter); + this._session.insert(); } else { - snippet.insert(true); + this._session.merge(template, overwriteBefore, overwriteAfter); } if (undoStopAfter) { @@ -142,7 +86,7 @@ export class SnippetController2 { } private _updateState(): void { - if (this._sessions.empty) { + if (!this._session) { // canceled in the meanwhile return; } @@ -153,19 +97,19 @@ export class SnippetController2 { return this.cancel(); } - if (!this._sessions.hasPlaceholder) { + if (!this._session.hasPlaceholder) { // don't listen for selection changes and don't // update context keys when the snippet is plain text return this.cancel(); } - if (this._sessions.isAtFinalPlaceholder || !this._sessions.isSelectionWithinPlaceholders) { + if (this._session.isAtLastPlaceholder || !this._session.isSelectionWithinPlaceholders()) { return this.cancel(); } this._inSnippet.set(true); - this._hasPrevTabstop.set(!this._sessions.isAtFirstPlaceholder); - this._hasNextTabstop.set(!this._sessions.isAtFinalPlaceholder); + this._hasPrevTabstop.set(!this._session.isAtFirstPlaceholder); + this._hasNextTabstop.set(!this._session.isAtLastPlaceholder); } finish(): void { @@ -178,17 +122,19 @@ export class SnippetController2 { this._inSnippet.reset(); this._hasPrevTabstop.reset(); this._hasNextTabstop.reset(); - this._sessions.clear(); dispose(this._snippetListener); + dispose(this._session); + this._session = undefined; + this._modelVersionId = -1; } prev(): void { - this._sessions.prev(); + this._session.prev(); this._updateState(); } next(): void { - this._sessions.next(); + this._session.next(); this._updateState(); } } diff --git a/src/vs/editor/contrib/snippet/browser/snippetSession.ts b/src/vs/editor/contrib/snippet/browser/snippetSession.ts index f319844d5c5..a000690d786 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetSession.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetSession.ts @@ -77,14 +77,14 @@ export class OneSnippet { }); } - move(fwd: boolean): Selection[] { + move(fwd: boolean | undefined): Selection[] { this._initDecorations(); - if (fwd && this._placeholderGroupsIdx < this._placeholderGroups.length - 1) { + if (fwd === true && this._placeholderGroupsIdx < this._placeholderGroups.length - 1) { this._placeholderGroupsIdx += 1; - } else if (!fwd && this._placeholderGroupsIdx > 0) { + } else if (fwd === false && this._placeholderGroupsIdx > 0) { this._placeholderGroupsIdx -= 1; } else { @@ -153,6 +153,57 @@ export class OneSnippet { }); return ret; } + + merge(others: OneSnippet[]): void { + + const model = this._editor.getModel(); + + this._editor.changeDecorations(accessor => { + + // For each active placeholder take one snippet and merge it + // in that the placeholder (can be many for `$1foo$1foo`). Because + // everything is sorted by editor selection we can simply remove + // elements from the beginning of the array + for (const placeholder of this._placeholderGroups[this._placeholderGroupsIdx]) { + const nested = others.shift(); + console.assert(!nested._placeholderDecorations); + + // Massage placeholder-indicies of the nested snippet to be + // sorted right after the insertion point. This ensures we move + // through the placeholders in the correct order + for (const nestedPlaceholder of nested._snippet.placeholders) { + if (nestedPlaceholder.isFinalTabstop) { + nestedPlaceholder.index = `${placeholder.index}.${nested._snippet.placeholders.length}`; + } else { + nestedPlaceholder.index = `${placeholder.index}.${nestedPlaceholder.index}`; + } + } + this._snippet.replace(placeholder, nested._snippet.children); + + // Remove the placeholder at which position are inserting + // the snippet and also remove its decoration. + const id = this._placeholderDecorations.get(placeholder); + accessor.removeDecoration(id); + this._placeholderDecorations.delete(placeholder); + + // For each *new* placeholder we create decoration to monitor + // how and if it grows/shrinks. + for (const placeholder of nested._snippet.placeholders) { + const placeholderOffset = nested._snippet.offset(placeholder); + const placeholderLen = nested._snippet.fullLen(placeholder); + const range = Range.fromPositions( + model.getPositionAt(nested._offset + placeholderOffset), + model.getPositionAt(nested._offset + placeholderOffset + placeholderLen) + ); + const handle = accessor.addDecoration(range, OneSnippet._decor.inactive); + this._placeholderDecorations.set(placeholder, handle); + } + } + + // Last, re-create the placeholder groups by sorting placeholders by their index. + this._placeholderGroups = groupBy(this._snippet.placeholders, Placeholder.compareByIndex); + }); + } } export class SnippetSession { @@ -192,41 +243,25 @@ export class SnippetSession { return selection; } - private readonly _editor: ICommonCodeEditor; - private readonly _template: string; - private readonly _overwriteBefore: number; - private readonly _overwriteAfter: number; - private _snippets: OneSnippet[] = []; - - constructor(editor: ICommonCodeEditor, template: string, overwriteBefore: number = 0, overwriteAfter: number = 0) { - this._editor = editor; - this._template = template; - this._overwriteBefore = overwriteBefore; - this._overwriteAfter = overwriteAfter; - } - - dispose(): void { - dispose(this._snippets); - } + static createEditsAndSnippets(editor: ICommonCodeEditor, template: string, overwriteBefore: number, overwriteAfter: number): { edits: IIdentifiedSingleEditOperation[], snippets: OneSnippet[] } { - insert(ignoreFinalTabstops: boolean = false): void { - - const model = this._editor.getModel(); + const model = editor.getModel(); const edits: IIdentifiedSingleEditOperation[] = []; + const snippets: OneSnippet[] = []; let delta = 0; // know what text the overwrite[Before|After] extensions // of the primary curser have selected because only when // secondary selections extend to the same text we can grow them - let firstBeforeText = model.getValueInRange(SnippetSession.adjustSelection(model, this._editor.getSelection(), this._overwriteBefore, 0)); - let firstAfterText = model.getValueInRange(SnippetSession.adjustSelection(model, this._editor.getSelection(), 0, this._overwriteAfter)); + let firstBeforeText = model.getValueInRange(SnippetSession.adjustSelection(model, editor.getSelection(), overwriteBefore, 0)); + let firstAfterText = model.getValueInRange(SnippetSession.adjustSelection(model, editor.getSelection(), 0, overwriteAfter)); // sort selections by their start position but remeber // the original index. that allows you to create correct // offset-based selection logic without changing the // primary selection - const indexedSelection = this._editor.getSelections() + const indexedSelection = editor.getSelections() .map((selection, idx) => ({ selection, idx })) .sort((a, b) => Range.compareRangesUsingStarts(a.selection, b.selection)); @@ -234,8 +269,8 @@ export class SnippetSession { // extend selection with the `overwriteBefore` and `overwriteAfter` and then // compare if this matches the extensions of the primary selection - let extensionBefore = SnippetSession.adjustSelection(model, selection, this._overwriteBefore, 0); - let extensionAfter = SnippetSession.adjustSelection(model, selection, 0, this._overwriteAfter); + let extensionBefore = SnippetSession.adjustSelection(model, selection, overwriteBefore, 0); + let extensionAfter = SnippetSession.adjustSelection(model, selection, 0, overwriteAfter); if (firstBeforeText !== model.getValueInRange(extensionBefore)) { extensionBefore = selection; } @@ -251,20 +286,10 @@ export class SnippetSession { // adjust the template string to match the indentation and // whitespace rules of this insert location (can be different for each cursor) const start = snippetSelection.getStartPosition(); - const adjustedTemplate = SnippetSession.adjustWhitespace(model, start, this._template); + const adjustedTemplate = SnippetSession.adjustWhitespace(model, start, template); const snippet = SnippetParser.parse(adjustedTemplate).resolveVariables(new EditorSnippetVariableResolver(model, selection)); - // rewrite final-tabstop to some other placeholder because this - // snippet sits inside another snippet - if (ignoreFinalTabstops) { - for (const placeholder of snippet.placeholders) { - if (placeholder.isFinalTabstop) { - placeholder.index = String(snippet.placeholders.length); - } - } - } - const offset = model.getOffsetAt(start) + delta; delta += snippet.text.length - model.getValueLengthInRange(snippetSelection); @@ -272,10 +297,36 @@ export class SnippetSession { // that ensures the primiary cursor stays primary despite not being // the one with lowest start position edits[idx] = EditOperation.replaceMove(snippetSelection, snippet.text); - this._snippets[idx] = new OneSnippet(this._editor, snippet, offset); + snippets[idx] = new OneSnippet(editor, snippet, offset); } + return { edits, snippets }; + } + + private readonly _editor: ICommonCodeEditor; + private readonly _template: string; + private readonly _overwriteBefore: number; + private readonly _overwriteAfter: number; + private _snippets: OneSnippet[] = []; + + constructor(editor: ICommonCodeEditor, template: string, overwriteBefore: number = 0, overwriteAfter: number = 0) { + this._editor = editor; + this._template = template; + this._overwriteBefore = overwriteBefore; + this._overwriteAfter = overwriteAfter; + } + + dispose(): void { + dispose(this._snippets); + } + + insert(): void { + + const model = this._editor.getModel(); + // make insert edit and start with first selections + const { edits, snippets } = SnippetSession.createEditsAndSnippets(this._editor, this._template, this._overwriteBefore, this._overwriteAfter); + this._snippets = snippets; this._editor.setSelections(model.pushEditOperations(this._editor.getSelections(), edits, undoEdits => { if (this._snippets[0].hasPlaceholder) { @@ -286,6 +337,24 @@ export class SnippetSession { })); } + merge(template: string, overwriteBefore: number = 0, overwriteAfter: number = 0): void { + const { edits, snippets } = SnippetSession.createEditsAndSnippets(this._editor, template, overwriteBefore, overwriteAfter); + + this._editor.setSelections(this._editor.getModel().pushEditOperations(this._editor.getSelections(), edits, undoEdits => { + + for (const snippet of this._snippets) { + snippet.merge(snippets); + } + console.assert(snippets.length === 0); + + if (this._snippets[0].hasPlaceholder) { + return this._move(undefined); + } else { + return undoEdits.map(edit => Selection.fromPositions(edit.range.getEndPosition())); + } + })); + } + next(): void { const newSelections = this._move(true); this._editor.setSelections(newSelections); @@ -296,7 +365,7 @@ export class SnippetSession { this._editor.setSelections(newSelections); } - private _move(fwd: boolean): Selection[] { + private _move(fwd: boolean | undefined): Selection[] { const selections: Selection[] = []; for (const snippet of this._snippets) { const oneSelection = snippet.move(fwd); diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts index 7cccf8ad7fd..0074a467414 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts @@ -175,34 +175,30 @@ suite('SnippetController2', function () { ctrl.insert('farboo'); assertSelections(editor, new Selection(1, 7, 1, 7), new Selection(2, 11, 2, 11)); - assertContextKeys(contextKeys, true, false, true); - - ctrl.next(); - assertSelections(editor, new Selection(1, 7, 1, 7), new Selection(2, 11, 2, 11)); assertContextKeys(contextKeys, false, false, false); }); - // - // test('Inconsistent tab stop behaviour with recursive snippets and tab / shift tab, #27543', function () { - // const ctrl = new SnippetController2(editor, contextKeys); - // ctrl.insert('1_calize(${1:nl}, \'${2:value}\')$0'); - // assertContextKeys(contextKeys, true, false, true); - // assertSelections(editor, new Selection(1, 10, 1, 12), new Selection(2, 14, 2, 16)); + test('Inconsistent tab stop behaviour with recursive snippets and tab / shift tab, #27543', function () { + const ctrl = new SnippetController2(editor, contextKeys); + ctrl.insert('1_calize(${1:nl}, \'${2:value}\')$0'); + + assertContextKeys(contextKeys, true, false, true); + assertSelections(editor, new Selection(1, 10, 1, 12), new Selection(2, 14, 2, 16)); - // ctrl.insert('2_calize(${1:nl}, \'${2:value}\')$0'); + ctrl.insert('2_calize(${1:nl}, \'${2:value}\')$0'); - // assertSelections(editor, new Selection(1, 19, 1, 21), new Selection(2, 23, 2, 25)); + assertSelections(editor, new Selection(1, 19, 1, 21), new Selection(2, 23, 2, 25)); - // ctrl.next(); // inner `value` - // assertSelections(editor, new Selection(1, 24, 1, 29), new Selection(2, 28, 2, 33)); + ctrl.next(); // inner `value` + assertSelections(editor, new Selection(1, 24, 1, 29), new Selection(2, 28, 2, 33)); - // ctrl.next(); // inner `$0` - // assertSelections(editor, new Selection(1, 31, 1, 31), new Selection(2, 35, 2, 35)); + ctrl.next(); // inner `$0` + assertSelections(editor, new Selection(1, 31, 1, 31), new Selection(2, 35, 2, 35)); - // ctrl.next(); // outer `value` - // assertSelections(editor, new Selection(1, 34, 1, 39), new Selection(2, 38, 2, 43)); + ctrl.next(); // outer `value` + assertSelections(editor, new Selection(1, 34, 1, 39), new Selection(2, 38, 2, 43)); - // ctrl.prev(); // inner `$0` - // assertSelections(editor, new Selection(1, 31, 1, 31), new Selection(2, 35, 2, 35)); - // }); + ctrl.prev(); // inner `$0` + assertSelections(editor, new Selection(1, 31, 1, 31), new Selection(2, 35, 2, 35)); + }); }); diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetParser.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetParser.test.ts index dc697aa740c..2092238acc3 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetParser.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetParser.test.ts @@ -387,17 +387,44 @@ suite('SnippetParser', () => { assert.equal(placeholders.length, 3); }); - test('TextmateSnippet#replace', function () { + test('TextmateSnippet#replace 1/2', function () { let snippet = SnippetParser.parse('aaa${1:bbb${2:ccc}}$0'); assert.equal(snippet.placeholders.length, 3); const [, second] = snippet.placeholders; assert.equal(second.index, '2'); + const enclosing = snippet.enclosingPlaceholders(second); + assert.equal(enclosing.length, 1); + assert.equal(enclosing[0].index, '1'); + let nested = SnippetParser.parse('ddd$1eee$0'); snippet.replace(second, nested.children); assert.equal(snippet.text, 'aaabbbdddeee'); assert.equal(snippet.placeholders.length, 4); + assert.equal(snippet.placeholders[0].index, '1'); + assert.equal(snippet.placeholders[1].index, '1'); + assert.equal(snippet.placeholders[2].index, '0'); + assert.equal(snippet.placeholders[3].index, '0'); + + const newEnclosing = snippet.enclosingPlaceholders(snippet.placeholders[1]); + assert.ok(newEnclosing[0] === snippet.placeholders[0]); + assert.equal(newEnclosing.length, 1); + assert.equal(newEnclosing[0].index, '1'); + }); + + test('TextmateSnippet#replace 2/2', function () { + let snippet = SnippetParser.parse('aaa${1:bbb${2:ccc}}$0'); + + assert.equal(snippet.placeholders.length, 3); + const [, second] = snippet.placeholders; + assert.equal(second.index, '2'); + + let nested = SnippetParser.parse('dddeee$0'); + snippet.replace(second, nested.children); + + assert.equal(snippet.text, 'aaabbbdddeee'); + assert.equal(snippet.placeholders.length, 3); }); }); diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts index 4691eaad476..138d98856b9 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetSession.test.ts @@ -403,5 +403,35 @@ suite('SnippetSession', function () { assert.equal(model.getValue(), '@line=1function foo() {\n @line=2console.log(a);\n}'); assertSelections(editor, new Selection(1, 8, 1, 8), new Selection(2, 12, 2, 12)); }); + + test('snippets, merge', function () { + editor.setSelection(new Selection(1, 1, 1, 1)); + const session = new SnippetSession(editor, 'This ${1:is ${2:nested}}.$0'); + session.insert(); + session.next(); + assertSelections(editor, new Selection(1, 9, 1, 15)); + + session.merge('really ${1:nested}$0'); + assertSelections(editor, new Selection(1, 16, 1, 22)); + + session.next(); + assertSelections(editor, new Selection(1, 22, 1, 22)); + assert.equal(session.isAtLastPlaceholder, false); + + session.next(); + assert.equal(session.isAtLastPlaceholder, true); + assertSelections(editor, new Selection(1, 23, 1, 23)); + + session.prev(); + editor.trigger('test', 'type', { text: 'AAA' }); + + // back to `really ${1:nested}` + session.prev(); + assertSelections(editor, new Selection(1, 16, 1, 22)); + + // back to `${1:is ...}` which now grew + session.prev(); + assertSelections(editor, new Selection(1, 6, 1, 25)); + }); }); -- GitLab From 186309ab9b30cb540dc47c123b118a3782b17477 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 1 Jun 2017 14:22:16 +0200 Subject: [PATCH 0437/1347] Flicker in minimap. Fixes #27518 --- .../workbench/services/themes/electron-browser/colorThemeData.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/vs/workbench/services/themes/electron-browser/colorThemeData.ts b/src/vs/workbench/services/themes/electron-browser/colorThemeData.ts index c0ac0c551f4..44d21ea3546 100644 --- a/src/vs/workbench/services/themes/electron-browser/colorThemeData.ts +++ b/src/vs/workbench/services/themes/electron-browser/colorThemeData.ts @@ -137,6 +137,7 @@ export function createUnloadedTheme(id: string): ColorThemeData { themeData.label = ''; themeData.settingsId = null; themeData.isLoaded = false; + themeData.tokenColors = [{ settings: {} }]; return themeData; } -- GitLab From bed537a4166905ef62e341285933aad7d21cedd3 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Thu, 1 Jun 2017 14:27:26 +0200 Subject: [PATCH 0438/1347] Added waiting to give enough time for VS Code to type the text in the editor. --- test/smoke/src/tests/data-loss.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/smoke/src/tests/data-loss.ts b/test/smoke/src/tests/data-loss.ts index e1498299e8e..0086f6268ef 100644 --- a/test/smoke/src/tests/data-loss.ts +++ b/test/smoke/src/tests/data-loss.ts @@ -54,13 +54,13 @@ export function testDataLoss() { // create one untitled file await common.newUntitledFile(); - await app.wait(); await common.type(textToType); - + await app.wait(); + // make one dirty file, await common.openFile('readme.md', true); - await app.wait(); await common.type(textToType); + await app.wait(); await app.stop(); await app.start(); -- GitLab From 895deefdf218ca2ce42c8b8ae86f4ed4332dba4b Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Thu, 1 Jun 2017 14:29:56 +0200 Subject: [PATCH 0439/1347] Iterate over the language names, rather than objects. --- build/lib/i18n.js | 3 ++- build/lib/i18n.ts | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/build/lib/i18n.js b/build/lib/i18n.js index 4447e34ab60..ed8a75c7bfc 100644 --- a/build/lib/i18n.js +++ b/build/lib/i18n.js @@ -443,7 +443,8 @@ function processCoreBundleFormat(fileHeader, languages, json, emitter) { var value = statistics[key]; log(key + " has " + value + " untranslated strings."); }); - languageDirs.forEach(function (language) { + languageDirs.forEach(function (dir) { + var language = dir.name; var iso639_2 = iso639_3_to_2[language]; if (!iso639_2) { log("\tCouldn't find iso639 2 mapping for language " + language + ". Using default language instead."); diff --git a/build/lib/i18n.ts b/build/lib/i18n.ts index 53b46933a80..23a3d743f06 100644 --- a/build/lib/i18n.ts +++ b/build/lib/i18n.ts @@ -516,7 +516,8 @@ function processCoreBundleFormat(fileHeader: string, languages: string[], json: let value = statistics[key]; log(`${key} has ${value} untranslated strings.`); }); - languageDirs.forEach(language => { + languageDirs.forEach(dir => { + const language = dir.name; let iso639_2 = iso639_3_to_2[language]; if (!iso639_2) { log(`\tCouldn't find iso639 2 mapping for language ${language}. Using default language instead.`); -- GitLab From 0803f7cef2561781d295a64075803e9242cc574f Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Thu, 1 Jun 2017 14:36:29 +0200 Subject: [PATCH 0440/1347] Removed wait from the test. Ref #27841 --- test/smoke/src/tests/data-loss.ts | 2 -- 1 file changed, 2 deletions(-) diff --git a/test/smoke/src/tests/data-loss.ts b/test/smoke/src/tests/data-loss.ts index 0086f6268ef..495838eb774 100644 --- a/test/smoke/src/tests/data-loss.ts +++ b/test/smoke/src/tests/data-loss.ts @@ -55,12 +55,10 @@ export function testDataLoss() { // create one untitled file await common.newUntitledFile(); await common.type(textToType); - await app.wait(); // make one dirty file, await common.openFile('readme.md', true); await common.type(textToType); - await app.wait(); await app.stop(); await app.start(); -- GitLab From 9dc26570166fb3955360ea7514ea9189b6209a6b Mon Sep 17 00:00:00 2001 From: isidor Date: Thu, 1 Jun 2017 14:50:26 +0200 Subject: [PATCH 0441/1347] fix double click focus movement when clicking in debug trees fixes #27835 --- src/vs/workbench/parts/debug/electron-browser/debugViewer.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts index e4eb230068f..fabffd9ca16 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts @@ -251,6 +251,7 @@ export class CallStackController extends BaseDebugController { } if (element instanceof StackFrame) { this.focusStackFrame(element, event, event.detail !== 2); + return true; } return super.onLeftClick(tree, element, event); @@ -1256,6 +1257,7 @@ export class BreakpointsController extends BaseDebugController { } if (element instanceof Breakpoint) { this.openBreakpointSource(element, event, event.detail !== 2); + return true; } return super.onLeftClick(tree, element, event); -- GitLab From f6891b951af7ac152b55639d56de3c0e9501dc07 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Thu, 1 Jun 2017 15:02:12 +0200 Subject: [PATCH 0442/1347] Fixes #27844: Task quick selection needs to filter on label --- src/vs/workbench/parts/tasks/browser/quickOpen.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/tasks/browser/quickOpen.ts b/src/vs/workbench/parts/tasks/browser/quickOpen.ts index 2b0eb83c769..3ec4cf96180 100644 --- a/src/vs/workbench/parts/tasks/browser/quickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/quickOpen.ts @@ -81,7 +81,7 @@ export abstract class QuickOpenHandler extends Quickopen.QuickOpenHandler { return compare; } } - return a.name.localeCompare(b.name); + return a._label.localeCompare(b._label); } if (aKind === TaskSourceKind.Workspace) { return -1; @@ -95,7 +95,7 @@ export abstract class QuickOpenHandler extends Quickopen.QuickOpenHandler { let groupExtension = groupWorkspace; let hadWorkspace = false; for (let task of tasks) { - let highlights = Filters.matchesContiguousSubString(input, task.name); + let highlights = Filters.matchesContiguousSubString(input, task._label); if (!highlights) { continue; } -- GitLab From 724f31f5bc953f7557736ca43076a284624d251b Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 1 Jun 2017 15:03:58 +0200 Subject: [PATCH 0443/1347] [decorators] only inclode border and outline styles if color is set. For #27790. --- .../editor/browser/services/codeEditorServiceImpl.ts | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/vs/editor/browser/services/codeEditorServiceImpl.ts b/src/vs/editor/browser/services/codeEditorServiceImpl.ts index f19885a1326..10a48dacbe3 100644 --- a/src/vs/editor/browser/services/codeEditorServiceImpl.ts +++ b/src/vs/editor/browser/services/codeEditorServiceImpl.ts @@ -343,9 +343,10 @@ class DecorationCSSRules { return ''; } let cssTextArr: string[] = []; - this.collectCSSText(opts, ['backgroundColor', 'outline', 'outlineColor', 'outlineStyle', 'outlineWidth'], cssTextArr); - this.collectBorderSettingsCSSText(opts, cssTextArr); - + this.collectCSSText(opts, ['backgroundColor'], cssTextArr); + if (this.collectCSSText(opts, ['outline', 'outlineColor'], cssTextArr)) { + this.collectCSSText(opts, ['outlineStyle', 'outlineWidth'], cssTextArr); + } return cssTextArr.join(''); } @@ -415,10 +416,9 @@ class DecorationCSSRules { return cssTextArr.join(''); } - private static border_rules = ['border', 'borderRadius', 'borderColor', 'borderSpacing', 'borderStyle', 'borderWidth']; - private collectBorderSettingsCSSText(opts: any, cssTextArr: string[]): boolean { - if (this.collectCSSText(opts, DecorationCSSRules.border_rules, cssTextArr)) { + if (this.collectCSSText(opts, ['border', 'borderColor'], cssTextArr)) { + this.collectCSSText(opts, ['borderRadius', 'borderSpacing', 'borderStyle', 'borderWidth'], cssTextArr); cssTextArr.push(strings.format('box-sizing: border-box;')); return true; } -- GitLab From 45e33456d6bdecf70d0e851fb8025d72a1db99a5 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Thu, 1 Jun 2017 15:13:31 +0200 Subject: [PATCH 0444/1347] Fixed adding languages only to non-stable build. --- build/gulpfile.vscode.js | 2 +- build/lib/i18n.js | 2 +- build/lib/i18n.ts | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index 9d5c3ff31fc..954a95afdee 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -85,7 +85,7 @@ const BUNDLED_FILE_HEADER = [ ].join('\n'); var languages = ['chs', 'cht', 'jpn', 'kor', 'deu', 'fra', 'esn', 'rus', 'ita']; -if (product.quality !== 'stable') { +if (process.env.VSCODE_QUALITY !== 'stable') { languages = languages.concat(['ptb']); // Add languages requested by the community to non-stable builds } diff --git a/build/lib/i18n.js b/build/lib/i18n.js index ed8a75c7bfc..3cf4f78401e 100644 --- a/build/lib/i18n.js +++ b/build/lib/i18n.js @@ -365,7 +365,7 @@ function processCoreBundleFormat(fileHeader, languages, json, emitter) { }); var languageDirectory = path.join(__dirname, '..', '..', 'i18n'); var languageDirs; - if (languageDirs) { + if (languages) { languageDirs = sortLanguages(languages); } else { diff --git a/build/lib/i18n.ts b/build/lib/i18n.ts index 23a3d743f06..e4a1029f7fe 100644 --- a/build/lib/i18n.ts +++ b/build/lib/i18n.ts @@ -439,7 +439,7 @@ function processCoreBundleFormat(fileHeader: string, languages: string[], json: let languageDirectory = path.join(__dirname, '..', '..', 'i18n'); let languageDirs; - if (languageDirs) { + if (languages) { languageDirs = sortLanguages(languages); } else { languageDirs = sortLanguages(fs.readdirSync(languageDirectory).filter((item) => fs.statSync(path.join(languageDirectory, item)).isDirectory())); -- GitLab From c8ad3f5aa633402b2d70b5239b683059b1fada19 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Thu, 1 Jun 2017 15:20:29 +0200 Subject: [PATCH 0445/1347] Fixes #27813: Add editor option to forcefully enable/disable accessibility support --- .../common/config/commonEditorConfig.ts | 11 ++++++++ src/vs/editor/common/config/editorOptions.ts | 25 ++++++++++++++++--- src/vs/monaco.d.ts | 5 ++++ 3 files changed, 38 insertions(+), 3 deletions(-) diff --git a/src/vs/editor/common/config/commonEditorConfig.ts b/src/vs/editor/common/config/commonEditorConfig.ts index 7d74da7a72d..2d54be1a832 100644 --- a/src/vs/editor/common/config/commonEditorConfig.ts +++ b/src/vs/editor/common/config/commonEditorConfig.ts @@ -551,6 +551,17 @@ const editorConfiguration: IConfigurationNode = { 'default': EDITOR_DEFAULTS.dragAndDrop, 'description': nls.localize('dragAndDrop', "Controls if the editor should allow to move selections via drag and drop.") }, + 'editor.accessibilitySupport': { + 'type': 'string', + 'enum': ['auto', 'on', 'off'], + 'enumDescriptions': [ + nls.localize('accessibilitySupport.auto', "The editor will use platform APIs to detect when a Screen Reader is attached."), + nls.localize('accessibilitySupport.on', "The editor will be permanently optimized for usage with a Screen Reader."), + nls.localize('accessibilitySupport.off', "The editor will never be optimized for usage with a Screen Reader."), + ], + 'default': EDITOR_DEFAULTS.accessibilitySupport, + 'description': nls.localize('accessibilitySupport', "Controls whether the editor should run in a mode where it is optimized for screen readers.") + }, 'diffEditor.renderSideBySide': { 'type': 'boolean', 'default': true, diff --git a/src/vs/editor/common/config/editorOptions.ts b/src/vs/editor/common/config/editorOptions.ts index b0586e45307..5db649e062c 100644 --- a/src/vs/editor/common/config/editorOptions.ts +++ b/src/vs/editor/common/config/editorOptions.ts @@ -336,6 +336,11 @@ export interface IEditorOptions { * Defaults to 'alt' */ multiCursorModifier?: 'ctrlCmd' | 'alt'; + /** + * Configure the editor's accessibility support. + * Defaults to 'auto'. It is best to leave this to 'auto'. + */ + accessibilitySupport?: 'auto' | 'off' | 'on'; /** * Enable quick suggestions (shadow suggestions) * Defaults to true. @@ -789,6 +794,7 @@ export interface IValidatedEditorOptions { readonly emptySelectionClipboard: boolean; readonly useTabStops: boolean; readonly multiCursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; + readonly accessibilitySupport: 'auto' | 'off' | 'on'; readonly viewInfo: InternalEditorViewOptions; readonly contribInfo: EditorContribOptions; @@ -1429,6 +1435,7 @@ export class EditorOptionsValidator { emptySelectionClipboard: _boolean(opts.emptySelectionClipboard, defaults.emptySelectionClipboard), useTabStops: _boolean(opts.useTabStops, defaults.useTabStops), multiCursorModifier: multiCursorModifier, + accessibilitySupport: _stringSet<'auto' | 'on' | 'off'>(opts.accessibilitySupport, defaults.accessibilitySupport, ['auto', 'on', 'off']), viewInfo: viewInfo, contribInfo: contribInfo, }; @@ -1653,6 +1660,7 @@ export class InternalEditorOptionsFactory { emptySelectionClipboard: opts.emptySelectionClipboard, useTabStops: opts.useTabStops, multiCursorModifier: opts.multiCursorModifier, + accessibilitySupport: opts.accessibilitySupport, viewInfo: { extraEditorClassName: opts.viewInfo.extraEditorClassName, @@ -1718,9 +1726,19 @@ export class InternalEditorOptionsFactory { public static createInternalEditorOptions(env: IEnvironmentalOptions, _opts: IValidatedEditorOptions) { + let accessibilitySupport: platform.AccessibilitySupport; + if (_opts.accessibilitySupport === 'auto') { + // The editor reads the `accessibilitySupport` from the environment + accessibilitySupport = env.accessibilitySupport; + } else if (_opts.accessibilitySupport === 'on') { + accessibilitySupport = platform.AccessibilitySupport.Enabled; + } else { + accessibilitySupport = platform.AccessibilitySupport.Disabled; + } + // Disable some non critical features to get as best performance as possible // See https://github.com/Microsoft/vscode/issues/26730 - const opts = this._handlePerformanceCritical(_opts, (env.accessibilitySupport === platform.AccessibilitySupport.Enabled)); + const opts = this._handlePerformanceCritical(_opts, (accessibilitySupport === platform.AccessibilitySupport.Enabled)); let lineDecorationsWidth: number; if (typeof opts.lineDecorationsWidth === 'string' && /^\d+(\.\d+)?ch$/.test(opts.lineDecorationsWidth)) { @@ -1760,7 +1778,7 @@ export class InternalEditorOptionsFactory { const wordWrapColumn = opts.wordWrapColumn; const wordWrapMinified = opts.wordWrapMinified; - if (env.accessibilitySupport === platform.AccessibilitySupport.Enabled) { + if (accessibilitySupport === platform.AccessibilitySupport.Enabled) { // See https://github.com/Microsoft/vscode/issues/27766 // Never enable wrapping when a screen reader is attached // because arrow down etc. will not move the cursor in the way @@ -1838,7 +1856,7 @@ export class InternalEditorOptionsFactory { editorClassName: className, lineHeight: env.fontInfo.lineHeight, readOnly: opts.readOnly, - accessibilitySupport: env.accessibilitySupport, + accessibilitySupport: accessibilitySupport, multiCursorModifier: opts.multiCursorModifier, wordSeparators: opts.wordSeparators, autoClosingBrackets: opts.autoClosingBrackets, @@ -2059,6 +2077,7 @@ export const EDITOR_DEFAULTS: IValidatedEditorOptions = { emptySelectionClipboard: true, useTabStops: true, multiCursorModifier: 'altKey', + accessibilitySupport: 'auto', viewInfo: { extraEditorClassName: '', diff --git a/src/vs/monaco.d.ts b/src/vs/monaco.d.ts index 34d430262a6..3fad661a07f 100644 --- a/src/vs/monaco.d.ts +++ b/src/vs/monaco.d.ts @@ -2882,6 +2882,11 @@ declare module monaco.editor { * Defaults to 'alt' */ multiCursorModifier?: 'ctrlCmd' | 'alt'; + /** + * Configure the editor's accessibility support. + * Defaults to 'auto'. It is best to leave this to 'auto'. + */ + accessibilitySupport?: 'auto' | 'off' | 'on'; /** * Enable quick suggestions (shadow suggestions) * Defaults to true. -- GitLab From 239ff7d0e030c93d5eadedd6ff764f909d0cd317 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Thu, 1 Jun 2017 15:27:23 +0200 Subject: [PATCH 0446/1347] Fixes #23758: Can start same task twice when adding task to tasks.json in between --- .../parts/tasks/common/taskConfiguration.ts | 70 +++++++++++++++++-- 1 file changed, 66 insertions(+), 4 deletions(-) diff --git a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts index 717fa268eab..b89dcfaeca2 100644 --- a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts +++ b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts @@ -358,6 +358,7 @@ function fillProperty(target: T, source: T, key: K) { interface ParseContext { problemReporter: IProblemReporter; namedProblemMatchers: IStringDictionary; + uuidMap: UUIDMap; engine: Tasks.ExecutionEngine; schemaVersion: Tasks.JsonSchemaVersion; } @@ -882,7 +883,7 @@ namespace TaskDescription { let command: Tasks.CommandConfiguration = CommandConfiguration.from(externalTask, context); let identifer = Types.isString(externalTask.identifier) ? externalTask.identifier : taskName; let task: Tasks.Task = { - _id: UUID.generateUuid(), + _id: context.uuidMap.getUUID(taskName), _source: source, _label: taskName, name: taskName, @@ -1222,11 +1223,65 @@ export interface IProblemReporter extends IProblemReporterBase { clearOutput(): void; } +class UUIDMap { + + private last: IStringDictionary; + private current: IStringDictionary; + + constructor() { + this.current = Object.create(null); + } + + public start(): void { + this.last = this.current; + this.current = Object.create(null); + } + + public getUUID(identifier: string): string { + let lastValue = this.last[identifier]; + let result: string; + if (lastValue !== void 0) { + if (Array.isArray(lastValue)) { + result = lastValue.shift(); + if (lastValue.length === 0) { + delete this.last[identifier]; + } + } else { + result = lastValue; + delete this.last[identifier]; + } + } + if (result === void 0) { + result = UUID.generateUuid(); + } + let currentValue = this.current[identifier]; + if (currentValue === void 0) { + this.current[identifier] = result; + } else { + if (Array.isArray(currentValue)) { + currentValue.push(result); + } else { + let arrayValue: string[] = [currentValue]; + arrayValue.push(result); + this.current[identifier] = arrayValue; + } + } + return result; + } + + public finish(): void { + this.last = undefined; + } +} + class ConfigurationParser { private problemReporter: IProblemReporter; - constructor(problemReporter: IProblemReporter) { + private uuidMap: UUIDMap; + + constructor(problemReporter: IProblemReporter, uuidMap: UUIDMap) { this.problemReporter = problemReporter; + this.uuidMap = uuidMap; } public run(fileConfig: ExternalTaskRunnerConfiguration): ParseResult { @@ -1237,6 +1292,7 @@ class ConfigurationParser { } let context: ParseContext = { problemReporter: this.problemReporter, + uuidMap: this.uuidMap, namedProblemMatchers: undefined, engine, schemaVersion, @@ -1278,7 +1334,7 @@ class ConfigurationParser { let matchers: ProblemMatcher[] = ProblemMatcherConverter.from(fileConfig.problemMatcher, context);; let isBackground = fileConfig.isBackground ? !!fileConfig.isBackground : fileConfig.isWatching ? !!fileConfig.isWatching : undefined; let task: Tasks.Task = { - _id: UUID.generateUuid(), + _id: context.uuidMap.getUUID(globals.command.name), _source: TaskDescription.source, _label: globals.command.name, name: globals.command.name, @@ -1303,8 +1359,14 @@ class ConfigurationParser { } } +let uuidMap: UUIDMap = new UUIDMap(); export function parse(configuration: ExternalTaskRunnerConfiguration, logger: IProblemReporter): ParseResult { - return (new ConfigurationParser(logger)).run(configuration); + try { + uuidMap.start(); + return (new ConfigurationParser(logger, uuidMap)).run(configuration); + } finally { + uuidMap.finish(); + } } export function mergeTasks(target: Tasks.Task, source: Tasks.Task): Tasks.Task { -- GitLab From cb72a7ca99dd987759d9b82ed57129a2374870ad Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 1 Jun 2017 15:38:29 +0200 Subject: [PATCH 0447/1347] add more ouis from VM --- src/vs/base/node/id.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/vs/base/node/id.ts b/src/vs/base/node/id.ts index 082983bea72..f8b65bfcbc9 100644 --- a/src/vs/base/node/id.ts +++ b/src/vs/base/node/id.ts @@ -35,6 +35,9 @@ export const virtualMachineHint: { value(): number } = new class { this._virtualMachineOUIs.insert('00-05-69', true); this._virtualMachineOUIs.insert('00-03-FF', true); this._virtualMachineOUIs.insert('00-1C-42', true); + this._virtualMachineOUIs.insert('00-16-3E', true); + this._virtualMachineOUIs.insert('08-00-27', true); + } return this._virtualMachineOUIs.findSubstr(mac); } -- GitLab From 56709d135e42bc7342c57031d02ef6c332ac84a5 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Thu, 1 Jun 2017 15:39:17 +0200 Subject: [PATCH 0448/1347] Present screen reader status in Alt+F1 info (#27833) --- .../accessibility/browser/accessibility.ts | 40 +++++++++++++++++-- 1 file changed, 36 insertions(+), 4 deletions(-) diff --git a/src/vs/editor/contrib/accessibility/browser/accessibility.ts b/src/vs/editor/contrib/accessibility/browser/accessibility.ts index 1294dc7b306..b72127b43ba 100644 --- a/src/vs/editor/contrib/accessibility/browser/accessibility.ts +++ b/src/vs/editor/contrib/accessibility/browser/accessibility.ts @@ -25,6 +25,9 @@ import { editorContribution } from 'vs/editor/browser/editorBrowserExtensions'; import { ToggleTabFocusModeAction } from 'vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode'; import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; import { editorWidgetBackground, widgetShadow, contrastBorder } from 'vs/platform/theme/common/colorRegistry'; +import { IConfigurationService } from "vs/platform/configuration/common/configuration"; +import * as editorOptions from 'vs/editor/common/config/editorOptions'; +import * as platform from 'vs/base/common/platform'; const CONTEXT_ACCESSIBILITY_WIDGET_VISIBLE = new RawContextKey('accessibilityHelpWidgetVisible', false); @@ -43,12 +46,13 @@ class AccessibilityHelpController extends Disposable implements IEditorContribut constructor( editor: ICodeEditor, @IContextKeyService contextKeyService: IContextKeyService, - @IKeybindingService keybindingService: IKeybindingService + @IKeybindingService keybindingService: IKeybindingService, + @IConfigurationService configurationService: IConfigurationService ) { super(); this._editor = editor; - this._widget = this._register(new AccessibilityHelpWidget(this._editor, contextKeyService, keybindingService)); + this._widget = this._register(new AccessibilityHelpWidget(this._editor, contextKeyService, keybindingService, configurationService)); } public getId(): string { @@ -72,15 +76,17 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { private _editor: ICodeEditor; private _keybindingService: IKeybindingService; + private _configurationService: IConfigurationService; private _domNode: FastDomNode; private _isVisible: boolean; private _isVisibleKey: IContextKey; - constructor(editor: ICodeEditor, contextKeyService: IContextKeyService, keybindingService: IKeybindingService) { + constructor(editor: ICodeEditor, contextKeyService: IContextKeyService, keybindingService: IKeybindingService, configurationService: IConfigurationService) { super(); this._editor = editor; this._keybindingService = keybindingService; + this._configurationService = configurationService; this._isVisibleKey = CONTEXT_ACCESSIBILITY_WIDGET_VISIBLE.bindTo(contextKeyService); this._domNode = createFastDomNode(document.createElement('div')); @@ -151,6 +157,32 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { text += '\n\n' + nls.localize('status', "Status:"); + const configuredValue = this._configurationService.getConfiguration('editor').accessibilitySupport; + const actualValue = opts.accessibilitySupport; + + switch (configuredValue) { + case 'auto': + switch (actualValue) { + case platform.AccessibilitySupport.Unknown: + // Should never happen in VS Code + text += '\n\n - ' + nls.localize('auto_unknown', "The editor is configured to use platform APIs to detect when a Screen Reader is attached, but the current runtime does not support this."); + break; + case platform.AccessibilitySupport.Enabled: + text += '\n\n - ' + nls.localize('auto_on', "The editor has automatically detected a Screen Reader is attached."); + break; + case platform.AccessibilitySupport.Disabled: + text += '\n\n - ' + nls.localize('auto_off', "The editor is configured to automatically detect when a Screen Reader is attached, which is not the case at this time."); + break; + } + break; + case 'on': + text += '\n\n - ' + nls.localize('configuredOn', "The editor is configured to be permanently optimized for usage with a Screen Reader - you can change this by editing the setting `editor.accessibilitySupport`."); + break; + case 'off': + text += '\n\n - ' + nls.localize('configuredOff', "The editor is configured to never be optimized for usage with a Screen Reader - you can change this by editing the setting `editor.accessibilitySupport`."); + break; + } + const NLS_TAB_FOCUS_MODE_ON = nls.localize('tabFocusModeOnMsg', "Pressing Tab in the current editor will move focus to the next focusable element. Toggle this behavior by pressing {0}."); const NLS_TAB_FOCUS_MODE_ON_NO_KB = nls.localize('tabFocusModeOnMsgNoKb', "Pressing Tab in the current editor will move focus to the next focusable element. The command {0} is currently not triggerable by a keybinding."); const NLS_TAB_FOCUS_MODE_OFF = nls.localize('tabFocusModeOffMsg', "Pressing Tab in the current editor will insert the tab character. Toggle this behavior by pressing {0}."); @@ -162,7 +194,7 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { text += '\n\n - ' + this._descriptionForCommand(ToggleTabFocusModeAction.ID, NLS_TAB_FOCUS_MODE_OFF, NLS_TAB_FOCUS_MODE_OFF_NO_KB); } - text += '\n\n' + nls.localize('outroMsg', "You can dismiss this tooltip and return to the editor by pressing Escape."); + text += '\n\n' + nls.localize('outroMsg', "You can dismiss this tooltip and return to the editor by pressing Escape or Shift-Escape."); this._domNode.domNode.appendChild(renderHtml({ formattedText: text -- GitLab From e4c130c36a2e47820cf534d967aef5213a0a8a89 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Thu, 1 Jun 2017 15:50:23 +0200 Subject: [PATCH 0449/1347] Moved contribution section to readme. --- test/smoke/CONTRIBUTING.md | 35 ----------------------------------- test/smoke/README.md | 38 ++++++++++++++++++++++++++++++++++---- 2 files changed, 34 insertions(+), 39 deletions(-) delete mode 100644 test/smoke/CONTRIBUTING.md diff --git a/test/smoke/CONTRIBUTING.md b/test/smoke/CONTRIBUTING.md deleted file mode 100644 index 7b403022778..00000000000 --- a/test/smoke/CONTRIBUTING.md +++ /dev/null @@ -1,35 +0,0 @@ -# Architecture -* `main.js` is used to prepare all smoke test dependencies (fetching key bindings and 'Express' repository, running `npm install` there). -* `mocha-runner.js` launches Mocha programmatically. It is spawned in Node environment from main.js to ensure that it is possible to listen on `stderr`s (primary `process.stderr` is not readable otherwise). This is accomplished because WebDriverIO command deprecation warnings need to be redirected to a separate log. Those warnings are coming from WebDriverIO because ChromeDriver has not migrated from JsonWire to W3C WebDriver protocol. -* `tests.ts` contains the main smoke test suite. It includes all tests separated into mocha `describe()` groups that represent each of the areas of [Smoke Test document](https://github.com/Microsoft/vscode/wiki/Smoke-Test). - -* `./areas/` folder contains a `.ts` file per each area of the document. E.g. `'Search'` area goes under `'search.ts'`. Every area file contains a list of methods with the name that represents the action that can be performed in the corresponding test. This reduces the amount of test suite code and means that if the UI changes, the fix need only be applied in one place. The name of the method reflects the action the tester would do if he would perform the test manually. See [Selenium Page Objects Wiki](https://github.com/SeleniumHQ/selenium/wiki/PageObjects) and [Selenium Bot Style Tests Wiki](https://github.com/SeleniumHQ/selenium/wiki/Bot-Style-Tests) for a good explanation of the implementation. Every smoke test area contains methods that are used in a bot-style approach in `main.ts`. -* `./spectron/` wraps the Spectron, with WebDriverIO API wrapped in `client.ts` and instance of Spectron Application is wrapped in `application.ts`. -* `./scripts/` contains scripts to run the smoke test. - -# Adding new area -To contribute a new smoke test area, add `${area}.ts` file under `./areas`. This has to follow the bot-style approach described in the links mentioned above. Methods should be calling WebDriverIO API through `SpectronClient` class. If there is no existing WebDriverIO method, add it to the class. - -# Adding new test -To add new test area or test, `main.ts` should be updated. The same instruction-style principle needs to be followed with the called area method names that reflect manual tester's actions. - -# Debugging -1. Add the following configuration to launch.json, specifying binaries in `args`: -```json -{ - "type": "node", - "request": "launch", - "name": "Launch Smoke Test", - "program": "${workspaceRoot}/test/smoke/src/main.js", - "cwd": "${workspaceRoot}/test/smoke", - "port": 9999, - "args": [ - "-l", - "path/to/Code.exe" - ], - "outFiles": [ - "${cwd}/out/**/*.js" - ] -}, -``` -2. In main.js add `--debug-brk=9999` argument to the place where `src/mocha-runner.js` is spawned. \ No newline at end of file diff --git a/test/smoke/README.md b/test/smoke/README.md index 501ec51f087..2cff1cd8b19 100644 --- a/test/smoke/README.md +++ b/test/smoke/README.md @@ -1,10 +1,40 @@ # VS Code Smoke Testing -This repository contains the smoke test automation code with Spectron for Visual Studio Code. - The following command is used to run the tests: `npm test -- --latest "path/to/binary"`. If you want to include 'Data Migration' area tests use `npm test -- --latest path/to/binary --stable path/to/currentStable` respectively. -# Contributing +# Architecture +* `main.js` is used to prepare all smoke test dependencies (fetching key bindings and 'Express' repository, running `npm install` there). +* `mocha-runner.js` launches Mocha programmatically. It is spawned in Node environment from main.js to ensure that it is possible to listen on `stderr`s (primary `process.stderr` is not readable otherwise). This is accomplished because WebDriverIO command deprecation warnings need to be redirected to a separate log. Those warnings are coming from WebDriverIO because ChromeDriver has not migrated from JsonWire to W3C WebDriver protocol. +* `test.ts` contains the main smoke test suite calling the tests that are bundled in areas and defined in `./tests/`. It includes all tests separated into mocha `describe()` groups that represent each of the areas of [Smoke Test document](https://github.com/Microsoft/vscode/wiki/Smoke-Test). + +* `./areas/` folder contains a `.ts` file per each area of the document. E.g. `'Search'` area goes under `'search.ts'`. Every area file contains a list of methods with the name that represents the action that can be performed in the corresponding test. This reduces the amount of test suite code and means that if the UI changes, the fix need only be applied in one place. The name of the method reflects the action the tester would do if he would perform the test manually. See [Selenium Page Objects Wiki](https://github.com/SeleniumHQ/selenium/wiki/PageObjects) and [Selenium Bot Style Tests Wiki](https://github.com/SeleniumHQ/selenium/wiki/Bot-Style-Tests) for a good explanation of the implementation. Every smoke test area contains methods that are used in a bot-style approach in `main.ts`. +* `./spectron/` wraps the Spectron, with WebDriverIO API wrapped in `client.ts` and instance of Spectron Application is wrapped in `application.ts`. +* `./scripts/` contains scripts to run the smoke test. + +# Adding new area +To contribute a new smoke test area, add `${area}.ts` file under `./areas/`. All related tests to the area should go to the alike named file under `./tests/` This has to follow the bot-style approach described in the links mentioned above. Methods should be calling WebDriverIO API through `SpectronClient` class. If there is no existing WebDriverIO method, add it to the class. + +# Adding new test +To add new test area or test, `main.ts` should be updated. The same instruction-style principle needs to be followed with the called area method names that reflect manual tester's actions. -This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments. +# Debugging +1. Add the following configuration to launch.json, specifying binaries in `args`: +```json +{ + "type": "node", + "request": "launch", + "name": "Launch Smoke Test", + "program": "${workspaceRoot}/test/smoke/src/main.js", + "cwd": "${workspaceRoot}/test/smoke", + "port": 9999, + "args": [ + "-l", + "path/to/Code.exe" + ], + "outFiles": [ + "${cwd}/out/**/*.js" + ] +}, +``` +2. In main.js add `--debug-brk=9999` argument to the place where `src/mocha-runner.js` is spawned. \ No newline at end of file -- GitLab From 7533eb39a04140247a36c5b0a2a3474a9a336cd0 Mon Sep 17 00:00:00 2001 From: isidor Date: Thu, 1 Jun 2017 15:16:46 +0200 Subject: [PATCH 0450/1347] debug: null guard --- .../workbench/parts/debug/electron-browser/debugService.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugService.ts b/src/vs/workbench/parts/debug/electron-browser/debugService.ts index 49b429ed4f4..983d0cac314 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugService.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugService.ts @@ -278,8 +278,10 @@ export class DebugService implements debug.IDebugService { } this.focusStackFrameAndEvaluate(stackFrameToFocus).done(null, errors.onUnexpectedError); - this.windowService.getWindow().focus(); - aria.alert(nls.localize('debuggingPaused', "Debugging paused, reason {0}, {1} {2}", thread.stoppedDetails.reason, stackFrameToFocus.source ? stackFrameToFocus.source.name : '', stackFrameToFocus.range.startLineNumber)); + if (thread.stoppedDetails) { + this.windowService.getWindow().focus(); + aria.alert(nls.localize('debuggingPaused', "Debugging paused, reason {0}, {1} {2}", thread.stoppedDetails.reason, stackFrameToFocus.source ? stackFrameToFocus.source.name : '', stackFrameToFocus.range.startLineNumber)); + } return stackFrameToFocus.openInEditor(this.editorService); } -- GitLab From 36a00d12c51a8cc4ed45c74bdf7c7b487dab861e Mon Sep 17 00:00:00 2001 From: isidor Date: Thu, 1 Jun 2017 16:00:40 +0200 Subject: [PATCH 0451/1347] use more precise ids for stack frames to avoid time era collisions #27694 --- src/vs/workbench/parts/debug/common/debugModel.ts | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/vs/workbench/parts/debug/common/debugModel.ts b/src/vs/workbench/parts/debug/common/debugModel.ts index e036ea1bb08..6d4f7691c3e 100644 --- a/src/vs/workbench/parts/debug/common/debugModel.ts +++ b/src/vs/workbench/parts/debug/common/debugModel.ts @@ -333,13 +333,14 @@ export class StackFrame implements IStackFrame { public frameId: number, public source: Source, public name: string, - public range: IRange + public range: IRange, + private index: number ) { this.scopes = null; } public getId(): string { - return `stackframe:${this.thread.getId()}:${this.frameId}`; + return `stackframe:${this.thread.getId()}:${this.frameId}:${this.index}`; } public getScopes(): TPromise { @@ -462,7 +463,7 @@ export class Thread implements IThread { this.stoppedDetails.totalFrames = response.body.totalFrames; } - return response.body.stackFrames.map((rsf, level) => { + return response.body.stackFrames.map((rsf, index) => { let source = new Source(rsf.source, rsf.source ? rsf.source.presentationHint : rsf.presentationHint); if (this.process.sources.has(source.uri.toString())) { const alreadyCreatedSource = this.process.sources.get(source.uri.toString()); @@ -477,7 +478,7 @@ export class Thread implements IThread { rsf.column, rsf.endLine, rsf.endColumn - )); + ), startFrame + index); }); }, (err: Error) => { if (this.stoppedDetails) { -- GitLab From 9a3e322cd5b626dbfe7f841c6b78b9301b53b4de Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Thu, 1 Jun 2017 15:43:57 +0200 Subject: [PATCH 0452/1347] Move accessibility help up to workbench (#27833) --- src/vs/workbench/electron-browser/workbench.main.ts | 1 - src/vs/workbench/parts/codeEditor/codeEditor.contribution.ts | 1 + .../parts/codeEditor/electron-browser}/accessibility.css | 0 .../parts/codeEditor/electron-browser}/accessibility.ts | 0 4 files changed, 1 insertion(+), 1 deletion(-) rename src/vs/{editor/contrib/accessibility/browser => workbench/parts/codeEditor/electron-browser}/accessibility.css (100%) rename src/vs/{editor/contrib/accessibility/browser => workbench/parts/codeEditor/electron-browser}/accessibility.ts (100%) diff --git a/src/vs/workbench/electron-browser/workbench.main.ts b/src/vs/workbench/electron-browser/workbench.main.ts index 0d6c2c4aa0c..a8fee7959d0 100644 --- a/src/vs/workbench/electron-browser/workbench.main.ts +++ b/src/vs/workbench/electron-browser/workbench.main.ts @@ -10,7 +10,6 @@ import 'vs/base/common/strings'; import 'vs/base/common/errors'; // Editor -import 'vs/editor/contrib/accessibility/browser/accessibility'; import 'vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes'; import 'vs/editor/contrib/selectionClipboard/electron-browser/selectionClipboard'; import 'vs/editor/browser/editor.all'; diff --git a/src/vs/workbench/parts/codeEditor/codeEditor.contribution.ts b/src/vs/workbench/parts/codeEditor/codeEditor.contribution.ts index e209510c694..f8b57c7352d 100644 --- a/src/vs/workbench/parts/codeEditor/codeEditor.contribution.ts +++ b/src/vs/workbench/parts/codeEditor/codeEditor.contribution.ts @@ -3,6 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ +import './electron-browser/accessibility'; import './electron-browser/toggleMultiCursorModifier'; import './electron-browser/toggleRenderControlCharacter'; import './electron-browser/toggleRenderWhitespace'; diff --git a/src/vs/editor/contrib/accessibility/browser/accessibility.css b/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.css similarity index 100% rename from src/vs/editor/contrib/accessibility/browser/accessibility.css rename to src/vs/workbench/parts/codeEditor/electron-browser/accessibility.css diff --git a/src/vs/editor/contrib/accessibility/browser/accessibility.ts b/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.ts similarity index 100% rename from src/vs/editor/contrib/accessibility/browser/accessibility.ts rename to src/vs/workbench/parts/codeEditor/electron-browser/accessibility.ts -- GitLab From 989a015e45a4871fb91bf7f23248ed7a77394efd Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Thu, 1 Jun 2017 16:02:34 +0200 Subject: [PATCH 0453/1347] Add possibility to turn on `editor.accessibilityOptions` from Alt+F1 (#27833) --- .../electron-browser/accessibility.ts | 52 ++++++++++++++++--- 1 file changed, 45 insertions(+), 7 deletions(-) diff --git a/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.ts b/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.ts index b72127b43ba..c155e0cb656 100644 --- a/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.ts +++ b/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.ts @@ -10,7 +10,7 @@ import * as nls from 'vs/nls'; import { KeyCode, KeyMod } from 'vs/base/common/keyCodes'; import { Disposable } from 'vs/base/common/lifecycle'; import * as strings from 'vs/base/common/strings'; -import { clearNode } from 'vs/base/browser/dom'; +import * as dom from 'vs/base/browser/dom'; import { renderHtml } from 'vs/base/browser/htmlContentRenderer'; import { FastDomNode, createFastDomNode } from 'vs/base/browser/fastDomNode'; import { Widget } from 'vs/base/browser/ui/widget'; @@ -28,6 +28,8 @@ import { editorWidgetBackground, widgetShadow, contrastBorder } from 'vs/platfor import { IConfigurationService } from "vs/platform/configuration/common/configuration"; import * as editorOptions from 'vs/editor/common/config/editorOptions'; import * as platform from 'vs/base/common/platform'; +import { IConfigurationEditingService, ConfigurationTarget } from 'vs/workbench/services/configuration/common/configurationEditing'; +import { alert } from 'vs/base/browser/ui/aria/aria'; const CONTEXT_ACCESSIBILITY_WIDGET_VISIBLE = new RawContextKey('accessibilityHelpWidgetVisible', false); @@ -47,12 +49,13 @@ class AccessibilityHelpController extends Disposable implements IEditorContribut editor: ICodeEditor, @IContextKeyService contextKeyService: IContextKeyService, @IKeybindingService keybindingService: IKeybindingService, - @IConfigurationService configurationService: IConfigurationService + @IConfigurationService configurationService: IConfigurationService, + @IConfigurationEditingService configurationEditingService: IConfigurationEditingService ) { super(); this._editor = editor; - this._widget = this._register(new AccessibilityHelpWidget(this._editor, contextKeyService, keybindingService, configurationService)); + this._widget = this._register(new AccessibilityHelpWidget(this._editor, contextKeyService, keybindingService, configurationService, configurationEditingService)); } public getId(): string { @@ -77,16 +80,24 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { private _editor: ICodeEditor; private _keybindingService: IKeybindingService; private _configurationService: IConfigurationService; + private _configurationEditingService: IConfigurationEditingService; private _domNode: FastDomNode; private _isVisible: boolean; private _isVisibleKey: IContextKey; - constructor(editor: ICodeEditor, contextKeyService: IContextKeyService, keybindingService: IKeybindingService, configurationService: IConfigurationService) { + constructor( + editor: ICodeEditor, + contextKeyService: IContextKeyService, + keybindingService: IKeybindingService, + configurationService: IConfigurationService, + configurationEditingService: IConfigurationEditingService + ) { super(); this._editor = editor; this._keybindingService = keybindingService; this._configurationService = configurationService; + this._configurationEditingService = configurationEditingService; this._isVisibleKey = CONTEXT_ACCESSIBILITY_WIDGET_VISIBLE.bindTo(contextKeyService); this._domNode = createFastDomNode(document.createElement('div')); @@ -103,6 +114,25 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { this._layout(); } })); + + // Intentionally not configurable! + this._register(dom.addStandardDisposableListener(this._domNode.domNode, 'keydown', (e) => { + if (!this._isVisible) { + return; + } + if (e.equals(KeyMod.CtrlCmd | KeyCode.KEY_E)) { + alert(nls.localize('emergencyConfOn', "Now changing the setting `editor.accessibilitySupport` to 'on'.")); + + this._configurationEditingService.writeConfiguration(ConfigurationTarget.USER, { + key: 'editor.accessibilitySupport', + value: 'on' + }); + + e.preventDefault(); + e.stopPropagation(); + } + })); + this.onblur(this._domNode.domNode, () => { this.hide(); }); @@ -160,6 +190,12 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { const configuredValue = this._configurationService.getConfiguration('editor').accessibilitySupport; const actualValue = opts.accessibilitySupport; + const emergencyTurnOnMessage = ( + platform.isMacintosh + ? nls.localize('changeConfigToOnMac', "To configure the editor to be permanently optimized for usage with a Screen Reader press Command+E now.") + : nls.localize('changeConfigToOnWinLinux', "To configure the editor to be permanently optimized for usage with a Screen Reader press Control+E now.") + ); + switch (configuredValue) { case 'auto': switch (actualValue) { @@ -172,6 +208,7 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { break; case platform.AccessibilitySupport.Disabled: text += '\n\n - ' + nls.localize('auto_off', "The editor is configured to automatically detect when a Screen Reader is attached, which is not the case at this time."); + text += ' ' + emergencyTurnOnMessage; break; } break; @@ -179,7 +216,8 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { text += '\n\n - ' + nls.localize('configuredOn', "The editor is configured to be permanently optimized for usage with a Screen Reader - you can change this by editing the setting `editor.accessibilitySupport`."); break; case 'off': - text += '\n\n - ' + nls.localize('configuredOff', "The editor is configured to never be optimized for usage with a Screen Reader - you can change this by editing the setting `editor.accessibilitySupport`."); + text += '\n\n - ' + nls.localize('configuredOff', "The editor is configured to never be optimized for usage with a Screen Reader."); + text += ' ' + emergencyTurnOnMessage; break; } @@ -194,7 +232,7 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { text += '\n\n - ' + this._descriptionForCommand(ToggleTabFocusModeAction.ID, NLS_TAB_FOCUS_MODE_OFF, NLS_TAB_FOCUS_MODE_OFF_NO_KB); } - text += '\n\n' + nls.localize('outroMsg', "You can dismiss this tooltip and return to the editor by pressing Escape or Shift-Escape."); + text += '\n\n' + nls.localize('outroMsg', "You can dismiss this tooltip and return to the editor by pressing Escape or Shift+Escape."); this._domNode.domNode.appendChild(renderHtml({ formattedText: text @@ -210,7 +248,7 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { this._domNode.setDisplay('none'); this._domNode.setAttribute('aria-hidden', 'true'); this._domNode.domNode.tabIndex = -1; - clearNode(this._domNode.domNode); + dom.clearNode(this._domNode.domNode); this._editor.focus(); } -- GitLab From 5348835ecbee9c8d1582493c3070f20c1b78cee2 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Thu, 1 Jun 2017 16:05:38 +0200 Subject: [PATCH 0454/1347] Fixes #27699 --- src/vs/workbench/browser/parts/editor/media/editorstatus.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/browser/parts/editor/media/editorstatus.css b/src/vs/workbench/browser/parts/editor/media/editorstatus.css index b7ff137ac26..b4fd4bdd7d2 100644 --- a/src/vs/workbench/browser/parts/editor/media/editorstatus.css +++ b/src/vs/workbench/browser/parts/editor/media/editorstatus.css @@ -20,5 +20,5 @@ .monaco-workbench .editor-statusbar-item > .editor-status-metadata, .monaco-workbench > .part.statusbar > .statusbar-item > .editor-statusbar-item > a.editor-status-screenreadermode { - cursor: default; + cursor: default !important; } -- GitLab From b00746468d6965c70b87037b2a2f24fe9aa1c3dc Mon Sep 17 00:00:00 2001 From: isidor Date: Thu, 1 Jun 2017 16:16:32 +0200 Subject: [PATCH 0455/1347] fix compile errors because who needs them --- .../workbench/parts/debug/test/common/debugViewModel.test.ts | 2 +- src/vs/workbench/parts/debug/test/node/debugModel.test.ts | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vs/workbench/parts/debug/test/common/debugViewModel.test.ts b/src/vs/workbench/parts/debug/test/common/debugViewModel.test.ts index 872818bd727..4832d5ca842 100644 --- a/src/vs/workbench/parts/debug/test/common/debugViewModel.test.ts +++ b/src/vs/workbench/parts/debug/test/common/debugViewModel.test.ts @@ -25,7 +25,7 @@ suite('Debug - View Model', () => { const mockSession = new MockSession(); const process = new Process({ name: 'mockProcess', type: 'node', request: 'launch' }, mockSession); const thread = new Thread(process, 'myThread', 1); - const frame = new StackFrame(thread, 1, null, 'app.js', { startColumn: 1, startLineNumber: 1, endColumn: undefined, endLineNumber: undefined }); + const frame = new StackFrame(thread, 1, null, 'app.js', { startColumn: 1, startLineNumber: 1, endColumn: undefined, endLineNumber: undefined }, 0); model.setFocusedStackFrame(frame, process); assert.equal(model.focusedStackFrame.getId(), frame.getId()); diff --git a/src/vs/workbench/parts/debug/test/node/debugModel.test.ts b/src/vs/workbench/parts/debug/test/node/debugModel.test.ts index da310a4f622..cda10c59ea9 100644 --- a/src/vs/workbench/parts/debug/test/node/debugModel.test.ts +++ b/src/vs/workbench/parts/debug/test/node/debugModel.test.ts @@ -304,7 +304,7 @@ suite('Debug - Model', () => { assert.equal(model.getWatchExpressions().length, 0); const process = new Process({ name: 'mockProcess', type: 'node', request: 'launch' }, rawSession); const thread = new Thread(process, 'mockthread', 1); - const stackFrame = new StackFrame(thread, 1, null, 'app.js', { startLineNumber: 1, startColumn: 1, endLineNumber: undefined, endColumn: undefined }); + const stackFrame = new StackFrame(thread, 1, null, 'app.js', { startLineNumber: 1, startColumn: 1, endLineNumber: undefined, endColumn: undefined }, 0); model.addWatchExpression(process, stackFrame, 'console').done(); model.addWatchExpression(process, stackFrame, 'console').done(); let watchExpressions = model.getWatchExpressions(); @@ -332,7 +332,7 @@ suite('Debug - Model', () => { assert.equal(model.getReplElements().length, 0); const process = new Process({ name: 'mockProcess', type: 'node', request: 'launch' }, rawSession); const thread = new Thread(process, 'mockthread', 1); - const stackFrame = new StackFrame(thread, 1, null, 'app.js', { startLineNumber: 1, startColumn: 1, endLineNumber: 1, endColumn: 10 }); + const stackFrame = new StackFrame(thread, 1, null, 'app.js', { startLineNumber: 1, startColumn: 1, endLineNumber: 1, endColumn: 10 }, 1); model.addReplExpression(process, stackFrame, 'myVariable').done(); model.addReplExpression(process, stackFrame, 'myVariable').done(); model.addReplExpression(process, stackFrame, 'myVariable').done(); -- GitLab From c0ba6ba60b5bd050c67601cc539fadfcbb30fbec Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Thu, 1 Jun 2017 07:26:09 -0700 Subject: [PATCH 0456/1347] Fixes #27773 --- extensions/emmet/src/extension.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/emmet/src/extension.ts b/extensions/emmet/src/extension.ts index 2fb79bdadd3..620df18dc32 100644 --- a/extensions/emmet/src/extension.ts +++ b/extensions/emmet/src/extension.ts @@ -43,7 +43,7 @@ export function activate(context: vscode.ExtensionContext) { let completionProvider = new EmmetCompletionItemProvider(); for (let language of SUPPORTED_LANGUAGE_MODES) { - const selector: vscode.DocumentFilter = { language: language.id, scheme: 'file' }; + const selector: vscode.DocumentFilter = { language: language.id }; const provider = vscode.languages.registerCompletionItemProvider(selector, completionProvider, ...language.triggerCharacters); context.subscriptions.push(provider); -- GitLab From caaaed37bd682f14771222def96488ec09a66b63 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Thu, 1 Jun 2017 16:37:47 +0200 Subject: [PATCH 0457/1347] Test failures in decorationRenderOptions.test (for #27790) --- src/vs/editor/browser/services/codeEditorServiceImpl.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/vs/editor/browser/services/codeEditorServiceImpl.ts b/src/vs/editor/browser/services/codeEditorServiceImpl.ts index 10a48dacbe3..eaf57c98d5d 100644 --- a/src/vs/editor/browser/services/codeEditorServiceImpl.ts +++ b/src/vs/editor/browser/services/codeEditorServiceImpl.ts @@ -347,6 +347,7 @@ class DecorationCSSRules { if (this.collectCSSText(opts, ['outline', 'outlineColor'], cssTextArr)) { this.collectCSSText(opts, ['outlineStyle', 'outlineWidth'], cssTextArr); } + this.collectBorderSettingsCSSText(opts, cssTextArr); return cssTextArr.join(''); } -- GitLab From 1d61c56f0fa60004a127919fc40025623140bf9f Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 1 Jun 2017 17:00:06 +0200 Subject: [PATCH 0458/1347] add phases to lifecycle service, #27852 --- src/vs/platform/lifecycle/common/lifecycle.ts | 23 +++++++++++++----- src/vs/workbench/electron-browser/shell.ts | 8 +++++-- .../electron-browser/lifecycleService.ts | 24 ++++++++++++++----- .../textfile/common/textFileEditorModel.ts | 4 ++-- .../workbench/test/workbenchTestServices.ts | 11 +++++---- 5 files changed, 50 insertions(+), 20 deletions(-) diff --git a/src/vs/platform/lifecycle/common/lifecycle.ts b/src/vs/platform/lifecycle/common/lifecycle.ts index 1cd1ab93cea..c3ff228ae9b 100644 --- a/src/vs/platform/lifecycle/common/lifecycle.ts +++ b/src/vs/platform/lifecycle/common/lifecycle.ts @@ -44,6 +44,12 @@ export enum StartupKind { ReopenedWindow = 4, } +export enum LifecyclePhase { + Starting = 1, + Running = 2, + ShuttingDown = 3 +} + /** * A lifecycle service informs about lifecycle events of the * application, such as shutdown. @@ -58,10 +64,14 @@ export interface ILifecycleService { readonly startupKind: StartupKind; /** - * A flag indicating if the application is in the process of shutting down. This will be true - * before the onWillShutdown event is fired and false if the shutdown is being vetoed. + * A flag indicating in what phase of the lifecycle we currently are. + */ + readonly phase: LifecyclePhase; + + /** + * An event that fire when the lifecycle phase has changed */ - readonly willShutdown: boolean; + readonly onDidChangePhase: Event; /** * Fired before shutdown happens. Allows listeners to veto against the @@ -80,8 +90,9 @@ export interface ILifecycleService { export const NullLifecycleService: ILifecycleService = { _serviceBrand: null, + phase: LifecyclePhase.Running, startupKind: StartupKind.NewWindow, - willShutdown: false, - onWillShutdown: () => ({ dispose() { } }), - onShutdown: (reason) => ({ dispose() { } }) + onDidChangePhase: Event.None, + onWillShutdown: Event.None, + onShutdown: Event.None }; diff --git a/src/vs/workbench/electron-browser/shell.ts b/src/vs/workbench/electron-browser/shell.ts index 66e974a00c7..4647e99bcc8 100644 --- a/src/vs/workbench/electron-browser/shell.ts +++ b/src/vs/workbench/electron-browser/shell.ts @@ -59,7 +59,7 @@ import { IInstantiationService } from 'vs/platform/instantiation/common/instanti import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; import { InstantiationService } from 'vs/platform/instantiation/common/instantiationService'; import { IContextViewService } from 'vs/platform/contextview/browser/contextView'; -import { ILifecycleService } from 'vs/platform/lifecycle/common/lifecycle'; +import { ILifecycleService, LifecyclePhase } from 'vs/platform/lifecycle/common/lifecycle'; import { IMarkerService } from 'vs/platform/markers/common/markers'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { IMessageService, IChoiceService, Severity } from 'vs/platform/message/common/message'; @@ -132,7 +132,7 @@ export class WorkbenchShell { private windowIPCService: IWindowIPCService; private timerService: ITimerService; private themeService: WorkbenchThemeService; - private lifecycleService: ILifecycleService; + private lifecycleService: LifecycleService; private container: HTMLElement; private toUnbind: IDisposable[]; @@ -235,6 +235,10 @@ export class WorkbenchShell { if ((platform.isLinux || platform.isMacintosh) && process.getuid() === 0) { this.messageService.show(Severity.Warning, nls.localize('runningAsRoot', "It is recommended not to run Code as 'root'.")); } + + // Set lifecycle phase to `Runnning` so that other contributions + // can now do something + this.lifecycleService.phase = LifecyclePhase.Running; } private initServiceCollection(container: HTMLElement): [IInstantiationService, ServiceCollection] { diff --git a/src/vs/workbench/services/lifecycle/electron-browser/lifecycleService.ts b/src/vs/workbench/services/lifecycle/electron-browser/lifecycleService.ts index 3cf631de01a..42230c25b94 100644 --- a/src/vs/workbench/services/lifecycle/electron-browser/lifecycleService.ts +++ b/src/vs/workbench/services/lifecycle/electron-browser/lifecycleService.ts @@ -7,7 +7,7 @@ import { TPromise } from 'vs/base/common/winjs.base'; import Severity from 'vs/base/common/severity'; import { toErrorMessage } from 'vs/base/common/errorMessage'; -import { ILifecycleService, ShutdownEvent, ShutdownReason, StartupKind } from 'vs/platform/lifecycle/common/lifecycle'; +import { ILifecycleService, ShutdownEvent, ShutdownReason, StartupKind, LifecyclePhase } from 'vs/platform/lifecycle/common/lifecycle'; import { IMessageService } from 'vs/platform/message/common/message'; import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage'; import { IWindowIPCService } from 'vs/workbench/services/window/electron-browser/windowService'; @@ -20,11 +20,12 @@ export class LifecycleService implements ILifecycleService { public _serviceBrand: any; + private readonly _onDidChangePhase = new Emitter(); private readonly _onWillShutdown = new Emitter(); private readonly _onShutdown = new Emitter(); private readonly _startupKind: StartupKind; - private _willShutdown: boolean; + private _phase: LifecyclePhase = LifecyclePhase.Starting; constructor( @IMessageService private _messageService: IMessageService, @@ -44,12 +45,23 @@ export class LifecycleService implements ILifecycleService { } } + public get phase(): LifecyclePhase { + return this._phase; + } + + public set phase(value: LifecyclePhase) { + if (this._phase !== value) { + this._phase = value; + this._onDidChangePhase.fire(value); + } + } + public get startupKind(): StartupKind { return this._startupKind; } - public get willShutdown(): boolean { - return this._willShutdown; + public get onDidChangePhase(): Event { + return this._onDidChangePhase.event; } public get onWillShutdown(): Event { @@ -65,14 +77,14 @@ export class LifecycleService implements ILifecycleService { // Main side indicates that window is about to unload, check for vetos ipc.on('vscode:beforeUnload', (event, reply: { okChannel: string, cancelChannel: string, reason: ShutdownReason }) => { - this._willShutdown = true; + this.phase = LifecyclePhase.ShuttingDown; this._storageService.store(LifecycleService._lastShutdownReasonKey, JSON.stringify(reply.reason), StorageScope.WORKSPACE); // trigger onWillShutdown events and veto collecting this.onBeforeUnload(reply.reason).done(veto => { if (veto) { this._storageService.remove(LifecycleService._lastShutdownReasonKey, StorageScope.WORKSPACE); - this._willShutdown = false; // reset this flag since the shutdown has been vetoed! + this.phase = LifecyclePhase.Running; // reset this flag since the shutdown has been vetoed! ipc.send(reply.cancelChannel, windowId); } else { this._onShutdown.fire(reply.reason); diff --git a/src/vs/workbench/services/textfile/common/textFileEditorModel.ts b/src/vs/workbench/services/textfile/common/textFileEditorModel.ts index eb3a76b87b1..0f23475b17f 100644 --- a/src/vs/workbench/services/textfile/common/textFileEditorModel.ts +++ b/src/vs/workbench/services/textfile/common/textFileEditorModel.ts @@ -17,7 +17,7 @@ import paths = require('vs/base/common/paths'); import diagnostics = require('vs/base/common/diagnostics'); import types = require('vs/base/common/types'); import { IMode } from 'vs/editor/common/modes'; -import { ILifecycleService } from 'vs/platform/lifecycle/common/lifecycle'; +import { ILifecycleService, LifecyclePhase } from 'vs/platform/lifecycle/common/lifecycle'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { ITextFileService, IAutoSaveConfiguration, ModelState, ITextFileEditorModel, IModelSaveOptions, ISaveErrorHandler, ISaveParticipant, StateChange, SaveReason, IRawTextContent } from 'vs/workbench/services/textfile/common/textfiles'; @@ -623,7 +623,7 @@ export class TextFileEditorModel extends BaseTextEditorModel implements ITextFil // We DO NOT run any save participant if we are in the shutdown phase and files are being // saved as a result of that. let saveParticipantPromise = TPromise.as(versionId); - if (TextFileEditorModel.saveParticipant && !this.lifecycleService.willShutdown) { + if (TextFileEditorModel.saveParticipant && this.lifecycleService.phase !== LifecyclePhase.ShuttingDown) { const onCompleteOrError = () => { this.blockModelContentChange = false; diff --git a/src/vs/workbench/test/workbenchTestServices.ts b/src/vs/workbench/test/workbenchTestServices.ts index a7f4f1ea918..32f74fe5a2d 100644 --- a/src/vs/workbench/test/workbenchTestServices.ts +++ b/src/vs/workbench/test/workbenchTestServices.ts @@ -28,7 +28,7 @@ import { IEditorInput, IEditorOptions, Position, Direction, IEditor, IResourceIn import { IUntitledEditorService, UntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; import { IMessageService, IConfirmation } from 'vs/platform/message/common/message'; import { IWorkspace, IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; -import { ILifecycleService, ShutdownEvent, ShutdownReason, StartupKind } from 'vs/platform/lifecycle/common/lifecycle'; +import { ILifecycleService, ShutdownEvent, ShutdownReason, StartupKind, LifecyclePhase } from 'vs/platform/lifecycle/common/lifecycle'; import { EditorStacksModel } from 'vs/workbench/common/editor/editorStacksModel'; import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; import { InstantiationService } from 'vs/platform/instantiation/common/instantiationService'; @@ -857,14 +857,13 @@ export class TestLifecycleService implements ILifecycleService { public _serviceBrand: any; - public willShutdown: boolean; + public phase: LifecyclePhase; public startupKind: StartupKind; + private _onDidChangePhase = new Emitter(); private _onWillShutdown = new Emitter(); private _onShutdown = new Emitter(); - constructor() { - } public fireShutdown(reason = ShutdownReason.QUIT): void { this._onShutdown.fire(reason); @@ -874,6 +873,10 @@ export class TestLifecycleService implements ILifecycleService { this._onWillShutdown.fire(event); } + public get onDidChangePhase(): Event { + return this._onDidChangePhase.event; + } + public get onWillShutdown(): Event { return this._onWillShutdown.event; } -- GitLab From bec63af7ef93dbbf36159f3cffe307c1452b9a18 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 1 Jun 2017 17:21:44 +0200 Subject: [PATCH 0459/1347] startup profiler listens on lifecycle event, #27852 --- src/vs/base/common/event.ts | 11 ++++++++++- src/vs/workbench/electron-browser/shell.ts | 8 ++++---- .../electron-browser/performance.contribution.ts | 12 ++++++++++-- 3 files changed, 24 insertions(+), 7 deletions(-) diff --git a/src/vs/base/common/event.ts b/src/vs/base/common/event.ts index a8d793e83ea..2b68de0c2e3 100644 --- a/src/vs/base/common/event.ts +++ b/src/vs/base/common/event.ts @@ -257,6 +257,15 @@ export function fromPromise(promise: TPromise): Event { return emitter.event; } +export function toPromise(event: Event): TPromise { + return new TPromise(complete => { + const sub = event(e => { + sub.dispose(); + complete(e); + }); + }); +} + export function delayed(promise: TPromise>): Event { let toCancel: TPromise = null; let listener: IDisposable = null; @@ -511,4 +520,4 @@ export function echo(event: Event, nextTick = false, buffer: T[] = []): Ev }); return emitter.event; -} \ No newline at end of file +} diff --git a/src/vs/workbench/electron-browser/shell.ts b/src/vs/workbench/electron-browser/shell.ts index 4647e99bcc8..e0fb2e384aa 100644 --- a/src/vs/workbench/electron-browser/shell.ts +++ b/src/vs/workbench/electron-browser/shell.ts @@ -179,6 +179,10 @@ export class WorkbenchShell { // start cached data manager instantiationService.createInstance(NodeCachedDataManager); + + // Set lifecycle phase to `Runnning` so that other contributions + // can now do something + this.lifecycleService.phase = LifecyclePhase.Running; } }); @@ -235,10 +239,6 @@ export class WorkbenchShell { if ((platform.isLinux || platform.isMacintosh) && process.getuid() === 0) { this.messageService.show(Severity.Warning, nls.localize('runningAsRoot', "It is recommended not to run Code as 'root'.")); } - - // Set lifecycle phase to `Runnning` so that other contributions - // can now do something - this.lifecycleService.phase = LifecyclePhase.Running; } private initServiceCollection(container: HTMLElement): [IInstantiationService, ServiceCollection] { diff --git a/src/vs/workbench/parts/performance/electron-browser/performance.contribution.ts b/src/vs/workbench/parts/performance/electron-browser/performance.contribution.ts index 820590107e2..23945bccb61 100644 --- a/src/vs/workbench/parts/performance/electron-browser/performance.contribution.ts +++ b/src/vs/workbench/parts/performance/electron-browser/performance.contribution.ts @@ -10,6 +10,7 @@ import { IEnvironmentService } from 'vs/platform/environment/common/environment' import { IExtensionService } from 'vs/platform/extensions/common/extensions'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { IMessageService } from 'vs/platform/message/common/message'; +import { ILifecycleService, LifecyclePhase } from 'vs/platform/lifecycle/common/lifecycle'; import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage'; import { ITimerService } from 'vs/workbench/services/timer/common/timerService'; import { IWindowsService } from 'vs/platform/windows/common/windows'; @@ -20,6 +21,7 @@ import { ReportPerformanceIssueAction } from 'vs/workbench/electron-browser/acti import { TPromise } from 'vs/base/common/winjs.base'; import { join } from 'path'; import { localize } from 'vs/nls'; +import { toPromise, filterEvent } from 'vs/base/common/event'; import { platform, Platform } from 'vs/base/common/platform'; import { readdir, stat } from 'vs/base/node/pfs'; import { release } from 'os'; @@ -149,10 +151,16 @@ class StartupProfiler implements IWorkbenchContribution { @IMessageService private readonly _messageService: IMessageService, @IEnvironmentService private readonly _environmentService: IEnvironmentService, @IInstantiationService private readonly _instantiationService: IInstantiationService, + @ILifecycleService lifecycleService: ILifecycleService, @IExtensionService extensionService: IExtensionService, ) { - - extensionService.onReady().then(() => this._stopProfiling()); + // wait for everything to be ready + TPromise.join([ + extensionService.onReady(), + toPromise(filterEvent(lifecycleService.onDidChangePhase, phase => phase === LifecyclePhase.Running)), + ]).then(() => { + this._stopProfiling(); + }); } getId(): string { -- GitLab From 9bd2d94c51106076c33c5796378850794b0f18ab Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 1 Jun 2017 08:48:12 -0700 Subject: [PATCH 0460/1347] Revert "Implement oncancel (fixes #27638)" This reverts commit ca923a5ee127fb35caa5025dc5948ef9ee4db6db. --- src/vs/workbench/parts/search/browser/openAnythingHandler.ts | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/vs/workbench/parts/search/browser/openAnythingHandler.ts b/src/vs/workbench/parts/search/browser/openAnythingHandler.ts index 64c2f66afeb..113adfd286d 100644 --- a/src/vs/workbench/parts/search/browser/openAnythingHandler.ts +++ b/src/vs/workbench/parts/search/browser/openAnythingHandler.ts @@ -229,10 +229,6 @@ export class OpenAnythingHandler extends QuickOpenHandler { this.pendingSearch = null; this.messageService.show(Severity.Error, error); }); - }, () => { - resultPromises.forEach(resultPromise => { - resultPromise.cancel(); - }); }); return this.pendingSearch; -- GitLab From eef9baf1152868cc9faecfed59c136eed73fd476 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 1 Jun 2017 08:48:22 -0700 Subject: [PATCH 0461/1347] Revert "Update controller, simplify telemetry (#27152)" This reverts commit 66bc0d13fafadbddb5b26a3bc114bdcc29cfd39c. --- .../parts/quickopen/quickOpenController.ts | 19 +++---- .../search/browser/openAnythingHandler.ts | 52 +++++++++++-------- 2 files changed, 37 insertions(+), 34 deletions(-) diff --git a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts index 32ef0a9c37a..8c1f65535e0 100644 --- a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts +++ b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts @@ -774,8 +774,7 @@ export class QuickOpenController extends Component implements IQuickOpenService } // Get results - let addedGroupLabel = false; - const handleResult = (result: IModel, last = false) => { + const handleResult = (result) => { if (this.currentResultToken === currentResultToken) { // now is the time to show the input if we did not have set it before @@ -786,10 +785,10 @@ export class QuickOpenController extends Component implements IQuickOpenService // merge history and default handler results const handlerResults = (result && result.entries) || []; - addedGroupLabel = this.mergeResults(quickOpenModel, handlerResults, !addedGroupLabel ? resolvedHandler.getGroupLabel() : null, last) || addedGroupLabel; + this.mergeResults(quickOpenModel, handlerResults, resolvedHandler.getGroupLabel()); } }; - return resolvedHandler.getResults(value).then(result => handleResult(result, true), undefined, handleResult); + return resolvedHandler.getResults(value).then(handleResult, undefined, handleResult); }); } @@ -846,7 +845,7 @@ export class QuickOpenController extends Component implements IQuickOpenService return results.sort((elementA: EditorHistoryEntry, elementB: EditorHistoryEntry) => QuickOpenEntry.compare(elementA, elementB, normalizedSearchValue)); } - private mergeResults(quickOpenModel: QuickOpenModel, handlerResults: QuickOpenEntry[], groupLabel: string, last: boolean): boolean { + private mergeResults(quickOpenModel: QuickOpenModel, handlerResults: QuickOpenEntry[], groupLabel: string): void { // Remove results already showing by checking for a "resource" property const mapEntryToResource = this.mapEntriesToResource(quickOpenModel); @@ -863,21 +862,17 @@ export class QuickOpenController extends Component implements IQuickOpenService // Show additional handler results below any existing results if (additionalHandlerResults.length > 0) { const autoFocusFirstEntry = (quickOpenModel.getEntries().length === 0); // the user might have selected another entry meanwhile in local history (see https://github.com/Microsoft/vscode/issues/20828) - if (groupLabel) { - const useTopBorder = quickOpenModel.getEntries().length > 0; - additionalHandlerResults[0] = new QuickOpenEntryGroup(additionalHandlerResults[0], groupLabel, useTopBorder); - } + const useTopBorder = quickOpenModel.getEntries().length > 0; + additionalHandlerResults[0] = new QuickOpenEntryGroup(additionalHandlerResults[0], groupLabel, useTopBorder); quickOpenModel.addEntries(additionalHandlerResults); this.quickOpenWidget.refresh(quickOpenModel, { autoFocusFirstEntry }); - return !!groupLabel; } // Otherwise if no results are present (even from histoy) indicate this to the user - else if (quickOpenModel.getEntries().length === 0 && last) { + else if (quickOpenModel.getEntries().length === 0) { quickOpenModel.addEntries([new PlaceholderQuickOpenEntry(nls.localize('noResultsFound1', "No results found"))]); this.quickOpenWidget.refresh(quickOpenModel, { autoFocusFirstEntry: true }); } - return false; } private handleSpecificHandler(handlerDescriptor: QuickOpenHandlerDescriptor, value: string, currentResultToken: string): TPromise { diff --git a/src/vs/workbench/parts/search/browser/openAnythingHandler.ts b/src/vs/workbench/parts/search/browser/openAnythingHandler.ts index 113adfd286d..7ac06c931f6 100644 --- a/src/vs/workbench/parts/search/browser/openAnythingHandler.ts +++ b/src/vs/workbench/parts/search/browser/openAnythingHandler.ts @@ -168,7 +168,8 @@ export class OpenAnythingHandler extends QuickOpenHandler { resultPromises.push(this.openSymbolHandler.getResults(searchValue)); } - const handleResult = (result: QuickOpenModel | FileQuickOpenModel) => { + // Join and sort unified + const handleResults = (results: (QuickOpenModel | FileQuickOpenModel)[]) => { this.pendingSearch = null; // If the quick open widget has been closed meanwhile, ignore the result @@ -176,13 +177,16 @@ export class OpenAnythingHandler extends QuickOpenHandler { return new QuickOpenModel(); } - const entries = result.entries; + // Combine file results and symbol results (if any) + const mergedResults: QuickOpenEntry[] = results.reduce((entries: QuickOpenEntry[], model: QuickOpenModel) => { + return entries.concat(model.entries); + }, []); // Sort const unsortedResultTime = Date.now(); const normalizedSearchValue = strings.stripWildcards(searchValue).toLowerCase(); const compare = (elementA: QuickOpenEntry, elementB: QuickOpenEntry) => QuickOpenEntry.compareByScore(elementA, elementB, searchValue, normalizedSearchValue, this.scorerCache); - const viewResults = arrays.top(entries, compare, OpenAnythingHandler.MAX_DISPLAYED_RESULTS); + const viewResults = arrays.top(mergedResults, compare, OpenAnythingHandler.MAX_DISPLAYED_RESULTS); const sortedResultTime = Date.now(); // Apply range and highlights to file entries @@ -195,34 +199,38 @@ export class OpenAnythingHandler extends QuickOpenHandler { } }); - // Telemetry - if (result instanceof FileQuickOpenModel) { - const fileSearchStats = (result).stats; - const duration = new Date().getTime() - startTime; - const data = this.createTimerEventData(startTime, { - searchLength: searchValue.length, - unsortedResultTime, - sortedResultTime, - resultCount: entries.length, - symbols: { fromCache: false }, - files: fileSearchStats - }); - - this.telemetryService.publicLog('openAnything', objects.assign(data, { duration })); + let fileSearchStats: ISearchStats; + for (const result of results) { + if (result instanceof FileQuickOpenModel) { + fileSearchStats = (result).stats; + break; + } } + const duration = new Date().getTime() - startTime; + const data = this.createTimerEventData(startTime, { + searchLength: searchValue.length, + unsortedResultTime, + sortedResultTime, + resultCount: mergedResults.length, + symbols: { fromCache: false }, + files: fileSearchStats + }); + + this.telemetryService.publicLog('openAnything', objects.assign(data, { duration })); + return new QuickOpenModel(viewResults); }; this.pendingSearch = new PPromise((complete, error, progress) => { // When any of the result promises return, forward the result as progress. - const processed = resultPromises.map(resultPromise => + resultPromises.map(resultPromise => { resultPromise.then(result => { - progress(handleResult(result)); - }) - ); + progress(handleResults([result])); + }); + }); // Complete the promise when all promises have completed. - TPromise.join(processed).then(() => { + TPromise.join(resultPromises).then(() => { // We already sent the results via progress. complete(new QuickOpenModel()); }, error => { -- GitLab From 6d54161153df8a9f993805c047ef3a3dff7f74c6 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 1 Jun 2017 08:48:29 -0700 Subject: [PATCH 0462/1347] Revert "Handle progress results in quick open controller (#27152)" This reverts commit dfd358082f4f03d6439e65fb130eb77988ad53ef. --- .../parts/quickopen/quickOpenController.ts | 5 +- src/vs/workbench/browser/quickopen.ts | 4 +- .../search/browser/openAnythingHandler.ts | 47 +++++++------------ 3 files changed, 20 insertions(+), 36 deletions(-) diff --git a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts index 8c1f65535e0..7c8a7df4a14 100644 --- a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts +++ b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts @@ -774,7 +774,7 @@ export class QuickOpenController extends Component implements IQuickOpenService } // Get results - const handleResult = (result) => { + return resolvedHandler.getResults(value).then(result => { if (this.currentResultToken === currentResultToken) { // now is the time to show the input if we did not have set it before @@ -787,8 +787,7 @@ export class QuickOpenController extends Component implements IQuickOpenService const handlerResults = (result && result.entries) || []; this.mergeResults(quickOpenModel, handlerResults, resolvedHandler.getGroupLabel()); } - }; - return resolvedHandler.getResults(value).then(handleResult, undefined, handleResult); + }); }); } diff --git a/src/vs/workbench/browser/quickopen.ts b/src/vs/workbench/browser/quickopen.ts index 551ffbd9808..ebb31e7a833 100644 --- a/src/vs/workbench/browser/quickopen.ts +++ b/src/vs/workbench/browser/quickopen.ts @@ -5,7 +5,7 @@ 'use strict'; import nls = require('vs/nls'); -import { PPromise, TPromise } from 'vs/base/common/winjs.base'; +import { TPromise } from 'vs/base/common/winjs.base'; import * as objects from 'vs/base/common/objects'; import filters = require('vs/base/common/filters'); import arrays = require('vs/base/common/arrays'); @@ -34,7 +34,7 @@ export class QuickOpenHandler { * As such, returning the same model instance across multiple searches will yield best * results in terms of performance when many items are shown. */ - public getResults(searchValue: string): PPromise, IModel> { + public getResults(searchValue: string): TPromise> { return TPromise.as(null); } diff --git a/src/vs/workbench/parts/search/browser/openAnythingHandler.ts b/src/vs/workbench/parts/search/browser/openAnythingHandler.ts index 7ac06c931f6..cc77586caa2 100644 --- a/src/vs/workbench/parts/search/browser/openAnythingHandler.ts +++ b/src/vs/workbench/parts/search/browser/openAnythingHandler.ts @@ -7,7 +7,7 @@ import * as arrays from 'vs/base/common/arrays'; import * as objects from 'vs/base/common/objects'; -import { PPromise, TPromise } from 'vs/base/common/winjs.base'; +import { TPromise } from 'vs/base/common/winjs.base'; import nls = require('vs/nls'); import { ThrottledDelayer } from 'vs/base/common/async'; import types = require('vs/base/common/types'); @@ -91,7 +91,7 @@ export class OpenAnythingHandler extends QuickOpenHandler { private openSymbolHandler: OpenSymbolHandler; private openFileHandler: OpenFileHandler; private searchDelayer: ThrottledDelayer; - private pendingSearch: PPromise; + private pendingSearch: TPromise; private isClosed: boolean; private scorerCache: { [key: string]: number }; private includeSymbols: boolean; @@ -135,7 +135,7 @@ export class OpenAnythingHandler extends QuickOpenHandler { }); } - public getResults(searchValue: string): PPromise { + public getResults(searchValue: string): TPromise { const startTime = Date.now(); this.cancelPendingSearch(); @@ -166,21 +166,21 @@ export class OpenAnythingHandler extends QuickOpenHandler { // Symbol Results (unless disabled or a range or absolute path is specified) if (this.includeSymbols && !searchWithRange) { resultPromises.push(this.openSymbolHandler.getResults(searchValue)); + } else { + resultPromises.push(TPromise.as(new QuickOpenModel())); // We need this empty promise because we are using the throttler below! } // Join and sort unified - const handleResults = (results: (QuickOpenModel | FileQuickOpenModel)[]) => { + this.pendingSearch = TPromise.join(resultPromises).then(results => { this.pendingSearch = null; // If the quick open widget has been closed meanwhile, ignore the result if (this.isClosed) { - return new QuickOpenModel(); + return TPromise.as(new QuickOpenModel()); } // Combine file results and symbol results (if any) - const mergedResults: QuickOpenEntry[] = results.reduce((entries: QuickOpenEntry[], model: QuickOpenModel) => { - return entries.concat(model.entries); - }, []); + const mergedResults = [...results[0].entries, ...results[1].entries]; // Sort const unsortedResultTime = Date.now(); @@ -200,11 +200,10 @@ export class OpenAnythingHandler extends QuickOpenHandler { }); let fileSearchStats: ISearchStats; - for (const result of results) { - if (result instanceof FileQuickOpenModel) { - fileSearchStats = (result).stats; - break; - } + if (results[0] instanceof FileQuickOpenModel) { + fileSearchStats = (results[0]).stats; + } else if (results[1] instanceof FileQuickOpenModel) { + fileSearchStats = (results[1]).stats; } const duration = new Date().getTime() - startTime; @@ -219,24 +218,10 @@ export class OpenAnythingHandler extends QuickOpenHandler { this.telemetryService.publicLog('openAnything', objects.assign(data, { duration })); - return new QuickOpenModel(viewResults); - }; - - this.pendingSearch = new PPromise((complete, error, progress) => { - // When any of the result promises return, forward the result as progress. - resultPromises.map(resultPromise => { - resultPromise.then(result => { - progress(handleResults([result])); - }); - }); - // Complete the promise when all promises have completed. - TPromise.join(resultPromises).then(() => { - // We already sent the results via progress. - complete(new QuickOpenModel()); - }, error => { - this.pendingSearch = null; - this.messageService.show(Severity.Error, error); - }); + return TPromise.as(new QuickOpenModel(viewResults)); + }, (error: Error) => { + this.pendingSearch = null; + this.messageService.show(Severity.Error, error); }); return this.pendingSearch; -- GitLab From 529495d64b7c22430e8ca6156a8a4fd6946183a6 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 1 Jun 2017 09:28:35 -0700 Subject: [PATCH 0463/1347] Tools and languages label too long (fixes #27510) --- .../parts/welcome/page/electron-browser/welcomePage.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts index 2c0dda61a41..9740e44f97e 100644 --- a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts +++ b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts @@ -303,7 +303,8 @@ class WelcomePage { list.appendChild(a); const span = document.createElement('span'); - span.innerText = localize('welcomePage.installedExtension', "{0} (installed)", extension.name); + span.innerText = extension.name; + span.title = localize('welcomePage.installedExtension', "{0} support is already installed", extension.name); span.classList.add('enabledExtension'); span.setAttribute('data-extension', extension.id); list.appendChild(span); @@ -342,7 +343,7 @@ class WelcomePage { if (!extension) { return false; } - return this.extensionManagementService.installFromGallery(extension) + return this.extensionManagementService.installFromGallery(extension, false) .then(() => { // TODO: Do this as part of the install to avoid multiple events. return this.extensionEnablementService.setEnablement(extensionSuggestion.id, false); -- GitLab From 90bfb284fa032943f0823f90c360529c77e1e214 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Thu, 1 Jun 2017 10:10:25 -0700 Subject: [PATCH 0464/1347] Fix more chars in terminal dnd Fixes #27511 --- .../parts/terminal/electron-browser/terminalPanel.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts index c9a9c9a57a1..51ddb07c92b 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts @@ -301,7 +301,9 @@ export class TerminalPanel extends Panel { return path; } path = path.replace(/(%5C|\\)/g, '\\\\'); - const charsToEscape = [' ', '\'', '"', '?', ':', ';']; + const charsToEscape = [ + ' ', '\'', '"', '?', ':', ';', '!', '*', '(', ')', '{', '}', '[', ']' + ]; for (let i = 0; i < path.length; i++) { const indexOfChar = charsToEscape.indexOf(path.charAt(i)); if (indexOfChar >= 0) { -- GitLab From c43cc5f0eb12f2bdcf86351b6fdfaa2ebecfda9e Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 1 Jun 2017 10:10:47 -0700 Subject: [PATCH 0465/1347] Use outlines in high contrast (#27580) --- extensions/merge-conflict/src/mergeDecorator.ts | 9 +++++++++ src/vs/platform/theme/common/colorRegistry.ts | 14 ++++++++------ 2 files changed, 17 insertions(+), 6 deletions(-) diff --git a/extensions/merge-conflict/src/mergeDecorator.ts b/extensions/merge-conflict/src/mergeDecorator.ts index 1b419908847..d30863eca9a 100644 --- a/extensions/merge-conflict/src/mergeDecorator.ts +++ b/extensions/merge-conflict/src/mergeDecorator.ts @@ -80,6 +80,9 @@ export default class MergeDectorator implements vscode.Disposable { isWholeLine: this.decorationUsesWholeLine, backgroundColor: new vscode.ThemeColor('merge.currentHeaderBackground'), color: new vscode.ThemeColor('editor.foreground'), + outlineStyle: 'solid', + outlineWidth: '1pt', + outlineColor: new vscode.ThemeColor('merge.border'), after: { contentText: ' ' + localize('currentChange', '(Current change)'), color: new vscode.ThemeColor('descriptionForeground') @@ -88,12 +91,18 @@ export default class MergeDectorator implements vscode.Disposable { this.decorations['splitter'] = vscode.window.createTextEditorDecorationType({ color: new vscode.ThemeColor('editor.foreground'), + outlineStyle: 'solid', + outlineWidth: '1pt', + outlineColor: new vscode.ThemeColor('merge.border'), isWholeLine: this.decorationUsesWholeLine, }); this.decorations['incoming.header'] = vscode.window.createTextEditorDecorationType({ backgroundColor: new vscode.ThemeColor('merge.incomingHeaderBackground'), color: new vscode.ThemeColor('editor.foreground'), + outlineStyle: 'solid', + outlineWidth: '1pt', + outlineColor: new vscode.ThemeColor('merge.border'), isWholeLine: this.decorationUsesWholeLine, after: { contentText: ' ' + localize('incomingChange', '(Incoming change)'), diff --git a/src/vs/platform/theme/common/colorRegistry.ts b/src/vs/platform/theme/common/colorRegistry.ts index ce0e3fd190b..d790e964b0c 100644 --- a/src/vs/platform/theme/common/colorRegistry.ts +++ b/src/vs/platform/theme/common/colorRegistry.ts @@ -264,13 +264,15 @@ const incomingBaseColor = Color.fromHex('#40A6FF').transparent(headerTransparenc const contentTransparency = 0.4; const rulerTransparency = 1; -export const mergeCurrentHeaderBackground = registerColor('merge.currentHeaderBackground', { dark: currentBaseColor, light: currentBaseColor, hc: currentBaseColor }, nls.localize('mergeCurrentHeaderBackground', 'Current header background in inline merge-conflict.')); -export const mergeCurrentContentBackground = registerColor('merge.currentContentBackground', { dark: transparent(mergeCurrentHeaderBackground, contentTransparency), light: transparent(mergeCurrentHeaderBackground, contentTransparency), hc: transparent(mergeCurrentHeaderBackground, contentTransparency) }, nls.localize('mergeCurrentContentBackground', 'Current content background in inline merge-conflict.')); -export const mergeIncomingHeaderBackground = registerColor('merge.incomingHeaderBackground', { dark: incomingBaseColor, light: incomingBaseColor, hc: incomingBaseColor }, nls.localize('mergeIncomingHeaderBackground', 'Incoming header background in inline merge-conflict.')); -export const mergeIncomingContentBackground = registerColor('merge.incomingContentBackground', { dark: transparent(mergeIncomingHeaderBackground, contentTransparency), light: transparent(mergeIncomingHeaderBackground, contentTransparency), hc: transparent(mergeIncomingHeaderBackground, contentTransparency) }, nls.localize('mergeIncomingContentBackground', 'Incoming content background in inline merge-conflict.')); +export const mergeCurrentHeaderBackground = registerColor('merge.currentHeaderBackground', { dark: currentBaseColor, light: currentBaseColor, hc: null }, nls.localize('mergeCurrentHeaderBackground', 'Current header background in inline merge-conflicts.')); +export const mergeCurrentContentBackground = registerColor('merge.currentContentBackground', { dark: transparent(mergeCurrentHeaderBackground, contentTransparency), light: transparent(mergeCurrentHeaderBackground, contentTransparency), hc: transparent(mergeCurrentHeaderBackground, contentTransparency) }, nls.localize('mergeCurrentContentBackground', 'Current content background in inline merge-conflicts.')); +export const mergeIncomingHeaderBackground = registerColor('merge.incomingHeaderBackground', { dark: incomingBaseColor, light: incomingBaseColor, hc: null }, nls.localize('mergeIncomingHeaderBackground', 'Incoming header background in inline merge-conflicts.')); +export const mergeIncomingContentBackground = registerColor('merge.incomingContentBackground', { dark: transparent(mergeIncomingHeaderBackground, contentTransparency), light: transparent(mergeIncomingHeaderBackground, contentTransparency), hc: transparent(mergeIncomingHeaderBackground, contentTransparency) }, nls.localize('mergeIncomingContentBackground', 'Incoming content background in inline merge-conflicts.')); -export const overviewRulerCurrentContentForeground = registerColor('editorOverviewRuler.currentContentForeground', { dark: transparent(mergeCurrentHeaderBackground, rulerTransparency), light: transparent(mergeCurrentHeaderBackground, rulerTransparency), hc: transparent(mergeCurrentHeaderBackground, rulerTransparency) }, nls.localize('overviewRulerCurrentContentForeground', 'Current overview ruler foreground for inline merge-conflict.')); -export const overviewRulerIncomingContentForeground = registerColor('editorOverviewRuler.incomingContentForeground', { dark: transparent(mergeIncomingHeaderBackground, rulerTransparency), light: transparent(mergeIncomingHeaderBackground, rulerTransparency), hc: transparent(mergeIncomingHeaderBackground, rulerTransparency) }, nls.localize('overviewRulerIncomingContentForeground', 'Incoming overview ruler foreground for inline merge-conflict.')); +export const mergeBorder = registerColor('merge.border', { dark: null, light: null, hc: '#C3DF6F' }, nls.localize('mergeBorder', 'Border color on headers and the splitter in inline merge-conflicts.')); + +export const overviewRulerCurrentContentForeground = registerColor('editorOverviewRuler.currentContentForeground', { dark: transparent(mergeCurrentHeaderBackground, rulerTransparency), light: transparent(mergeCurrentHeaderBackground, rulerTransparency), hc: mergeBorder }, nls.localize('overviewRulerCurrentContentForeground', 'Current overview ruler foreground for inline merge-conflicts.')); +export const overviewRulerIncomingContentForeground = registerColor('editorOverviewRuler.incomingContentForeground', { dark: transparent(mergeIncomingHeaderBackground, rulerTransparency), light: transparent(mergeIncomingHeaderBackground, rulerTransparency), hc: mergeBorder }, nls.localize('overviewRulerIncomingContentForeground', 'Incoming overview ruler foreground for inline merge-conflicts.')); // ----- color functions -- GitLab From 089bd8980b70d035ffce267c823fbdb4484f50e8 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 1 Jun 2017 19:05:14 +0200 Subject: [PATCH 0466/1347] Revert "theming - remove panel.background as we currently do not support it end to end" This reverts commit 3c1f7878b2d3114483d09c5ee8490d3cf27ec0b2. --- extensions/theme-abyss/themes/abyss-color-theme.json | 1 + .../theme-quietlight/themes/quietlight-color-theme.json | 1 + .../themes/solarized-dark-color-theme.json | 1 + .../themes/solarized-light-color-theme.json | 1 + src/vs/workbench/browser/parts/panel/panelPart.ts | 6 +++--- src/vs/workbench/common/theme.ts | 6 ++++++ 6 files changed, 13 insertions(+), 3 deletions(-) diff --git a/extensions/theme-abyss/themes/abyss-color-theme.json b/extensions/theme-abyss/themes/abyss-color-theme.json index 5b2c2e1e546..9901ee0d6b8 100644 --- a/extensions/theme-abyss/themes/abyss-color-theme.json +++ b/extensions/theme-abyss/themes/abyss-color-theme.json @@ -375,6 +375,7 @@ // "activityBar.dropBackground": "", // Workbench: Panel + // "panel.background": "", "panel.border": "#2b2b4a", // "panelTitle.activeBorder": "", // "panelTitle.activeForeground": "", diff --git a/extensions/theme-quietlight/themes/quietlight-color-theme.json b/extensions/theme-quietlight/themes/quietlight-color-theme.json index 5ab654716a7..e1d9201c6d7 100644 --- a/extensions/theme-quietlight/themes/quietlight-color-theme.json +++ b/extensions/theme-quietlight/themes/quietlight-color-theme.json @@ -466,6 +466,7 @@ "editorWhitespace.foreground": "#AAAAAA", "editor.lineHighlightBackground": "#E4F6D4", "editor.selectionBackground": "#C9D0D9", + "panel.background": "#F5F5F5", "sideBar.background": "#F2F2F2", "sideBarSectionHeader.background": "#ede8ef", "editorLineNumber.foreground": "#9DA39A", diff --git a/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json b/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json index 542de82d4c8..04967aae331 100644 --- a/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json +++ b/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json @@ -423,6 +423,7 @@ // "activityBarBadge.foreground": "", // Workbench: Panel + // "panel.background": "", "panel.border": "#2b2b4a", // "panelTitle.activeBorder": "", // "panelTitle.activeForeground": "", diff --git a/extensions/theme-solarized-light/themes/solarized-light-color-theme.json b/extensions/theme-solarized-light/themes/solarized-light-color-theme.json index cd42bbaa859..ba74b7d0385 100644 --- a/extensions/theme-solarized-light/themes/solarized-light-color-theme.json +++ b/extensions/theme-solarized-light/themes/solarized-light-color-theme.json @@ -421,6 +421,7 @@ // "activityBarBadge.foreground": "", // Workbench: Panel + // "panel.background": "", "panel.border": "#DDD6C1", // "panelTitle.activeBorder": "", // "panelTitle.activeForeground": "", diff --git a/src/vs/workbench/browser/parts/panel/panelPart.ts b/src/vs/workbench/browser/parts/panel/panelPart.ts index 1a8f0cf4529..8ad40e000be 100644 --- a/src/vs/workbench/browser/parts/panel/panelPart.ts +++ b/src/vs/workbench/browser/parts/panel/panelPart.ts @@ -25,8 +25,8 @@ import { IInstantiationService } from 'vs/platform/instantiation/common/instanti import { ActionsOrientation, ActionBar } from 'vs/base/browser/ui/actionbar/actionbar'; import { ClosePanelAction, PanelAction, ToggleMaximizedPanelAction } from 'vs/workbench/browser/parts/panel/panelActions'; import { IThemeService, registerThemingParticipant, ITheme, ICssStyleCollector } from 'vs/platform/theme/common/themeService'; -import { PANEL_BORDER, PANEL_ACTIVE_TITLE_FOREGROUND, PANEL_INACTIVE_TITLE_FOREGROUND, PANEL_ACTIVE_TITLE_BORDER } from 'vs/workbench/common/theme'; -import { activeContrastBorder, focusBorder, contrastBorder, editorBackground } from 'vs/platform/theme/common/colorRegistry'; +import { PANEL_BACKGROUND, PANEL_BORDER, PANEL_ACTIVE_TITLE_FOREGROUND, PANEL_INACTIVE_TITLE_FOREGROUND, PANEL_ACTIVE_TITLE_BORDER } from 'vs/workbench/common/theme'; +import { activeContrastBorder, focusBorder, contrastBorder } from 'vs/platform/theme/common/colorRegistry'; export class PanelPart extends CompositePart implements IPanelService { @@ -101,7 +101,7 @@ export class PanelPart extends CompositePart implements IPanelService { super.updateStyles(); const container = this.getContainer(); - container.style('background-color', this.getColor(editorBackground)); + container.style('background-color', this.getColor(PANEL_BACKGROUND)); const title = this.getTitleArea(); title.style('border-top-color', this.getColor(PANEL_BORDER) || this.getColor(contrastBorder)); diff --git a/src/vs/workbench/common/theme.ts b/src/vs/workbench/common/theme.ts index 3b35554eb6e..4297f3a2df2 100644 --- a/src/vs/workbench/common/theme.ts +++ b/src/vs/workbench/common/theme.ts @@ -96,6 +96,12 @@ export const EDITOR_DRAG_AND_DROP_BACKGROUND = registerColor('editorGroup.dropBa // < --- Panels --- > +export const PANEL_BACKGROUND = registerColor('panel.background', { + dark: editorBackground, + light: editorBackground, + hc: editorBackground +}, nls.localize('panelBackground', "Panel background color. Panels are shown below the editor area and contain views like output and integrated terminal.")); + export const PANEL_BORDER = registerColor('panel.border', { dark: Color.fromHex('#808080').transparent(0.35), light: Color.fromHex('#808080').transparent(0.35), -- GitLab From 3bab8149c03dceacc79c0c37b93395af0e25ec69 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 1 Jun 2017 11:02:38 -0700 Subject: [PATCH 0467/1347] Add margin for outline (fixes #27662) --- .../parts/welcome/page/electron-browser/welcomePage.css | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.css b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.css index a3c2fa3e686..a87de4ff421 100644 --- a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.css +++ b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.css @@ -136,9 +136,9 @@ margin: 7px 0px; } .monaco-workbench > .part.editor > .content .welcomePage .commands li button { - margin: 0; + margin: 1px; padding: 12px 10px; - width: 100%; + width: calc(100% - 2px); height: 5em; font-size: 1.3em; text-align: left; -- GitLab From 202fd245e39d7895bb24f5e8deea29031c5f921e Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 1 Jun 2017 11:17:05 -0700 Subject: [PATCH 0468/1347] Add aria-label (fixes #27666) --- .../parts/welcome/page/electron-browser/welcomePage.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts index 9740e44f97e..bfa4a4f58d9 100644 --- a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts +++ b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts @@ -224,8 +224,11 @@ class WelcomePage { name = parentFolder; parentFolder = tmp; } + const tildifiedParentFolder = tildify(parentFolder, this.environmentService.userHome); + a.innerText = name; a.title = folder; + a.setAttribute('aria-label', localize('welcomePage.openFolderWithPath', "Open folder {0} with path {1}", name, tildifiedParentFolder)); a.href = 'javascript:void(0)'; a.addEventListener('click', e => { this.telemetryService.publicLog('workbenchActionExecuted', { @@ -241,7 +244,7 @@ class WelcomePage { const span = document.createElement('span'); span.classList.add('path'); span.classList.add('detail'); - span.innerText = tildify(parentFolder, this.environmentService.userHome); + span.innerText = tildifiedParentFolder; span.title = folder; li.appendChild(span); -- GitLab From 6574483b3fe988ba13c31055b0f9ce005114bd11 Mon Sep 17 00:00:00 2001 From: rebornix Date: Thu, 1 Jun 2017 10:17:00 -0700 Subject: [PATCH 0469/1347] Fix #27505. Make find widget sash 3px. --- src/vs/editor/contrib/find/browser/findWidget.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/editor/contrib/find/browser/findWidget.ts b/src/vs/editor/contrib/find/browser/findWidget.ts index de4cbdea320..4c5b20bd38c 100644 --- a/src/vs/editor/contrib/find/browser/findWidget.ts +++ b/src/vs/editor/contrib/find/browser/findWidget.ts @@ -1036,7 +1036,7 @@ registerThemingParticipant((theme, collector) => { let border = theme.getColor('panel.border'); if (border) { - collector.addRule(`.monaco-editor .find-widget .monaco-sash { background-color: ${border}; width: 2px !important; margin-left: -4px;}`); + collector.addRule(`.monaco-editor .find-widget .monaco-sash { background-color: ${border}; width: 3px !important; margin-left: -4px;}`); } }); -- GitLab From b0990849bb0171cd4e94b28f9d89793e3774f6fb Mon Sep 17 00:00:00 2001 From: rebornix Date: Thu, 1 Jun 2017 12:36:44 -0700 Subject: [PATCH 0470/1347] Fix #27495. --- .../editor/contrib/find/browser/findWidget.ts | 34 +++++++++++++++++-- 1 file changed, 31 insertions(+), 3 deletions(-) diff --git a/src/vs/editor/contrib/find/browser/findWidget.ts b/src/vs/editor/contrib/find/browser/findWidget.ts index 4c5b20bd38c..91d6b991af3 100644 --- a/src/vs/editor/contrib/find/browser/findWidget.ts +++ b/src/vs/editor/contrib/find/browser/findWidget.ts @@ -411,7 +411,31 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas } }, 0); this._codeEditor.layoutOverlayWidget(this); - this._showViewZone(); + + let adjustEditorScrollTop = true; + if (this._codeEditor.getConfiguration().contribInfo.find.seedSearchStringFromSelection && selection) { + let editorCoords = dom.getDomNodePagePosition(this._codeEditor.getDomNode()); + let startCoords = this._codeEditor.getScrolledVisiblePosition(selection.getStartPosition()); + let startLeft = editorCoords.left + startCoords.left; + let startTop = startCoords.top; + + if (startTop < this._viewZone.heightInPx) { + if (selection.endLineNumber > selection.startLineNumber) { + adjustEditorScrollTop = false; + } + + let leftOfFindWidget = dom.getTopLeftOffset(this._domNode).left; + if (startLeft > leftOfFindWidget) { + adjustEditorScrollTop = false; + } + let endCoords = this._codeEditor.getScrolledVisiblePosition(selection.getEndPosition()); + let endLeft = editorCoords.left + endCoords.left; + if (endLeft > leftOfFindWidget) { + adjustEditorScrollTop = false; + } + } + } + this._showViewZone(adjustEditorScrollTop); } } @@ -454,11 +478,12 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas } this._viewZoneId = accessor.addZone(this._viewZone); + // scroll top adjust to make sure the editor doesn't scroll when adding viewzone at the beginning. this._codeEditor.setScrollTop(this._codeEditor.getScrollTop() + this._viewZone.heightInPx); }); } - private _showViewZone() { + private _showViewZone(adjustScroll: boolean = true) { if (!this._isVisible) { return; } @@ -479,7 +504,10 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas this._viewZone.heightInPx = FIND_INPUT_AREA_HEIGHT; } this._viewZoneId = accessor.addZone(this._viewZone); - this._codeEditor.setScrollTop(this._codeEditor.getScrollTop() + scrollAdjustment); + + if (adjustScroll) { + this._codeEditor.setScrollTop(this._codeEditor.getScrollTop() + scrollAdjustment); + } }); } -- GitLab From 07bbca9f9a973afb754efdf8deccbd3788d93b65 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 1 Jun 2017 12:43:42 -0700 Subject: [PATCH 0471/1347] Improve screen reader experience on install buttons (fixes #27661) --- .../welcome/page/electron-browser/vs_code_welcome_page.ts | 4 ++-- .../parts/welcome/page/electron-browser/welcomePage.ts | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.ts b/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.ts index 767ee36747a..2fe5fc81aa1 100644 --- a/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.ts +++ b/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.ts @@ -52,11 +52,11 @@ export default () => `

${escape(localize('welcomePage.customize', "Customize"))}

    -
  • -
  • diff --git a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts index bfa4a4f58d9..204b34b3f63 100644 --- a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts +++ b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts @@ -295,6 +295,7 @@ class WelcomePage { const a = document.createElement('a'); a.innerText = extension.name; + a.title = extension.isKeymap ? localize('welcomePage.installKeymap', "Install {0} keymap", extension.name) : localize('welcomePage.installExtensionPack', "Install additional support for {0}", extension.name); a.classList.add('installExtension'); a.setAttribute('data-extension', extension.id); a.href = 'javascript:void(0)'; @@ -307,7 +308,7 @@ class WelcomePage { const span = document.createElement('span'); span.innerText = extension.name; - span.title = localize('welcomePage.installedExtension', "{0} support is already installed", extension.name); + span.title = extension.isKeymap ? localize('welcomePage.installedKeymap', "{0} keymap is already installed", extension.name) : localize('welcomePage.installedExtensionPack', "{0} support is already installed", extension.name); span.classList.add('enabledExtension'); span.setAttribute('data-extension', extension.id); list.appendChild(span); -- GitLab From 0346c023f6bb057df1a9ff793cebb5cc5810ac56 Mon Sep 17 00:00:00 2001 From: rebornix Date: Thu, 1 Jun 2017 13:13:25 -0700 Subject: [PATCH 0472/1347] Fix #27515. --- src/vs/editor/contrib/find/browser/findWidget.ts | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/vs/editor/contrib/find/browser/findWidget.ts b/src/vs/editor/contrib/find/browser/findWidget.ts index 91d6b991af3..8eadb32492a 100644 --- a/src/vs/editor/contrib/find/browser/findWidget.ts +++ b/src/vs/editor/contrib/find/browser/findWidget.ts @@ -236,10 +236,17 @@ export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSas }); })); + this._register(this._codeEditor.onDidScrollChange((e) => { if (e.scrollTopChanged) { this._layoutViewZone(); + return; } + + // for other scroll changes, layout the viewzone in next tick to avoid ruining current rendering. + setTimeout(() => { + this._layoutViewZone(); + }, 0); })); } -- GitLab From cab96c00b2b9a2551fc3f0207cc0bcbd8bcb6a97 Mon Sep 17 00:00:00 2001 From: rebornix Date: Thu, 1 Jun 2017 13:27:54 -0700 Subject: [PATCH 0473/1347] Fix #26106. This time make it right. --- src/vs/editor/common/viewModel/viewModelDecorations.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/editor/common/viewModel/viewModelDecorations.ts b/src/vs/editor/common/viewModel/viewModelDecorations.ts index 2a04c160d94..2e631c09486 100644 --- a/src/vs/editor/common/viewModel/viewModelDecorations.ts +++ b/src/vs/editor/common/viewModel/viewModelDecorations.ts @@ -73,7 +73,7 @@ export class ViewModelDecorations implements IDisposable { let removedDecorations = e.removedDecorations; for (let i = 0, len = removedDecorations.length; i < len; i++) { let removedDecoration = removedDecorations[i]; - if (removedDecoration !== null && removedDecoration !== undefined) { + if (this._decorationsCache !== null && this._decorationsCache !== undefined) { delete this._decorationsCache[removedDecoration]; } } -- GitLab From d3df76f50d7982c8c2fa296c22529d2b85590032 Mon Sep 17 00:00:00 2001 From: rebornix Date: Thu, 1 Jun 2017 13:33:20 -0700 Subject: [PATCH 0474/1347] Re #26106. Reduce null check. --- src/vs/editor/common/viewModel/viewModelDecorations.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vs/editor/common/viewModel/viewModelDecorations.ts b/src/vs/editor/common/viewModel/viewModelDecorations.ts index 2e631c09486..f4311681f82 100644 --- a/src/vs/editor/common/viewModel/viewModelDecorations.ts +++ b/src/vs/editor/common/viewModel/viewModelDecorations.ts @@ -71,9 +71,9 @@ export class ViewModelDecorations implements IDisposable { } let removedDecorations = e.removedDecorations; - for (let i = 0, len = removedDecorations.length; i < len; i++) { - let removedDecoration = removedDecorations[i]; - if (this._decorationsCache !== null && this._decorationsCache !== undefined) { + if (this._decorationsCache !== null && this._decorationsCache !== undefined) { + for (let i = 0, len = removedDecorations.length; i < len; i++) { + let removedDecoration = removedDecorations[i]; delete this._decorationsCache[removedDecoration]; } } -- GitLab From 86417cea29412b5247650154cad2e9f395b7623b Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 1 Jun 2017 14:24:42 -0700 Subject: [PATCH 0475/1347] Details for extension being installed (fixes #27659) --- .../page/electron-browser/welcomePage.ts | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts index 204b34b3f63..976702e229d 100644 --- a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts +++ b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts @@ -37,6 +37,7 @@ import { isLinux } from 'vs/base/common/platform'; import { IThemeService, registerThemingParticipant } from 'vs/platform/theme/common/themeService'; import { registerColor, focusBorder, textLinkForeground, textLinkActiveForeground, foreground, descriptionForeground, contrastBorder, activeContrastBorder } from 'vs/platform/theme/common/colorRegistry'; import { getExtraColor } from 'vs/workbench/parts/welcome/walkThrough/node/walkThroughUtils'; +import { IExtensionsWorkbenchService } from 'vs/workbench/parts/extensions/common/extensions'; used(); @@ -125,6 +126,7 @@ const keymapExtensions: ExtensionSuggestion[] = [ interface Strings { installEvent: string; installedEvent: string; + detailsEvent: string; alreadyInstalled: string; reloadAfterInstall: string; @@ -135,16 +137,18 @@ interface Strings { const extensionPackStrings: Strings = { installEvent: 'installExtension', installedEvent: 'installedExtension', + detailsEvent: 'detailsExtension', alreadyInstalled: localize('welcomePage.extensionPackAlreadyInstalled', "Support for {0} is already installed."), - reloadAfterInstall: localize('welcomePage.willReloadAfterInstallingExtensionPack', "The window will reload after installing support for {0}."), - installing: localize('welcomePage.installingExtensionPack', "Installing support for {0}..."), + reloadAfterInstall: localize('welcomePage.willReloadAfterInstallingExtensionPack', "The window will reload after installing additional support for {0}."), + installing: localize('welcomePage.installingExtensionPack', "Installing additional support for {0}..."), extensionNotFound: localize('welcomePage.extensionPackNotFound', "Support for {0} with id {1} could not be found."), }; const keymapStrings: Strings = { installEvent: 'installKeymap', installedEvent: 'installedKeymap', + detailsEvent: 'detailsKeymap', alreadyInstalled: localize('welcomePage.keymapAlreadyInstalled', "The {0} keyboard shortcuts are already installed."), reloadAfterInstall: localize('welcomePage.willReloadAfterInstallingKeymap', "The window will reload after installing the {0} keyboard shortcuts."), @@ -170,6 +174,7 @@ class WelcomePage { @IExtensionGalleryService private extensionGalleryService: IExtensionGalleryService, @IExtensionManagementService private extensionManagementService: IExtensionManagementService, @IExtensionTipsService private tipsService: IExtensionTipsService, + @IExtensionsWorkbenchService private extensionsWorkbenchService: IExtensionsWorkbenchService, @ILifecycleService lifecycleService: ILifecycleService, @IThemeService private themeService: IThemeService, @ITelemetryService private telemetryService: ITelemetryService @@ -403,6 +408,16 @@ class WelcomePage { }); return TPromise.as(true); }), + new Action('details', localize('details', "Details"), null, true, () => { + this.telemetryService.publicLog(strings.detailsEvent, { + from: telemetryFrom, + extensionId: extensionSuggestion.id, + }); + this.extensionsWorkbenchService.queryGallery({ names: [extensionSuggestion.id] }) + .then(result => this.extensionsWorkbenchService.open(result.firstPage[0])) + .then(null, onUnexpectedError); + return TPromise.as(false); + }), new Action('cancel', localize('cancel', "Cancel"), null, true, () => { this.telemetryService.publicLog(strings.installedEvent, { from: telemetryFrom, -- GitLab From 120e1d041d322e7755d932de49ed932899ff6243 Mon Sep 17 00:00:00 2001 From: Andre Weinand Date: Thu, 1 Jun 2017 23:29:01 +0200 Subject: [PATCH 0476/1347] node-debug@1.13.9 --- build/gulpfile.vscode.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index 954a95afdee..a44f3e99bd8 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -42,7 +42,7 @@ const nodeModules = ['electron', 'original-fs'] // Build const builtInExtensions = [ - { name: 'ms-vscode.node-debug', version: '1.13.8' }, + { name: 'ms-vscode.node-debug', version: '1.13.9' }, { name: 'ms-vscode.node-debug2', version: '1.13.1' } ]; -- GitLab From 148a23aef5135ae3b0e8a380fc4804f84d58933e Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Thu, 1 Jun 2017 15:15:48 -0700 Subject: [PATCH 0477/1347] Explicitly specify that typescrip.tnpm should point to the executable --- extensions/typescript/package.nls.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/typescript/package.nls.json b/extensions/typescript/package.nls.json index 374860ba9c4..c2cf5917496 100644 --- a/extensions/typescript/package.nls.json +++ b/extensions/typescript/package.nls.json @@ -36,7 +36,7 @@ "typescript.selectTypeScriptVersion.title": "Select TypeScript Version", "jsDocCompletion.enabled": "Enable/disable auto JSDoc comments", "javascript.implicitProjectConfig.checkJs": "Enable/disable semantic checking of JavaScript files. Existing jsconfig.json or tsconfig.json files override this setting. Requires TypeScript >=2.3.1.", - "typescript.npm": "Specifies the path to the NPM install used for Automatic Type Acquisition. Requires TypeScript >= 2.3.4.", + "typescript.npm": "Specifies the path to the NPM executable used for Automatic Type Acquisition. Requires TypeScript >= 2.3.4.", "typescript.check.npmIsInstalled": "Check if NPM is installed for Automatic Type Acquisition.", "javascript.nameSuggestions": "Enable/disable including unique names from the file in JavaScript suggestion lists.", "typescript.tsc.autoDetect": "Controls whether auto detection of tsc tasks is on or off." -- GitLab From b16b4ce42f8a76fbd6649c051decca95faf76d93 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Thu, 1 Jun 2017 15:26:48 -0700 Subject: [PATCH 0478/1347] Fixes #27633 --- .../parts/emmet/electron-browser/actions/editPoints.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.ts b/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.ts index d4d1111fe5c..cd52920c25d 100644 --- a/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.ts +++ b/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.ts @@ -15,7 +15,7 @@ class PreviousEditPointAction extends BasicEmmetEditorAction { constructor() { super( 'editor.emmet.action.previousEditPoint', - nls.localize('previousEditPoint', "Emmet: Previous Edit Point"), + nls.localize('previousEditPoint', "Emmet: Go to Previous Edit Point"), 'Emmet: Go to Previous Edit Point', 'prev_edit_point' ); @@ -27,7 +27,7 @@ class NextEditPointAction extends BasicEmmetEditorAction { constructor() { super( 'editor.emmet.action.nextEditPoint', - nls.localize('nextEditPoint', "Emmet: Next Edit Point"), + nls.localize('nextEditPoint', "Emmet: Go to Next Edit Point"), 'Emmet: Go to Next Edit Point', 'next_edit_point' ); -- GitLab From 4d4d9cac5f643c386aa76c5b0299829e839d6c39 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Thu, 1 Jun 2017 15:31:04 -0700 Subject: [PATCH 0479/1347] Fixes #27316 --- extensions/emmet/src/editPoint.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/extensions/emmet/src/editPoint.ts b/extensions/emmet/src/editPoint.ts index 5338c5012e1..2028d3295b3 100644 --- a/extensions/emmet/src/editPoint.ts +++ b/extensions/emmet/src/editPoint.ts @@ -45,8 +45,7 @@ function findEditPoint(lineNum: number, editor: vscode.TextEditor, position: vsc let lineContent = line.text; if (lineNum !== position.line && line.isEmptyOrWhitespace) { - editor.selection = new vscode.Selection(lineNum, lineContent.length, lineNum, lineContent.length); - return; + return new vscode.Selection(lineNum, lineContent.length, lineNum, lineContent.length); } if (lineNum === position.line && direction === 'prev') { -- GitLab From d4bbcc63683855c3005f92c1c71a1c597f70512a Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 1 Jun 2017 16:00:22 -0700 Subject: [PATCH 0480/1347] Adapt to "editor.multiCursorModifier" setting (fixes #27884) --- .../editor/vs_code_editor_walkthrough.md | 2 +- .../electron-browser/walkThroughPart.ts | 17 +++++++++++++++++ 2 files changed, 18 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/editor/vs_code_editor_walkthrough.md b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/editor/vs_code_editor_walkthrough.md index 6dedb7d9978..765597aac9a 100644 --- a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/editor/vs_code_editor_walkthrough.md +++ b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/editor/vs_code_editor_walkthrough.md @@ -16,7 +16,7 @@ The core editor in VS Code is packed with features. This page highlights a numb ### Multi-Cursor Editing Using multiple cursors allows you to edit multiple parts of the document at once, greatly improving your productivity. Try the following actions in the code block below: 1. Box Selection - press any combination of kb(cursorColumnSelectDown), kb(cursorColumnSelectRight), kb(cursorColumnSelectUp), kb(cursorColumnSelectLeft) to select a block of text, you can also press `⇧⌥``Shift+Alt` while selecting text with the mouse. -2. Add a cursor - press kb(editor.action.insertCursorAbove) or kb(editor.action.insertCursorBelow) to add a new cursor above or below, you can also use your mouse with `⌥+Click``Alt+Click` to add a cursor anywhere. +2. Add a cursor - press kb(editor.action.insertCursorAbove) or kb(editor.action.insertCursorBelow) to add a new cursor above or below, you can also use your mouse with +Click to add a cursor anywhere. 3. Create cursors on all occurrences of a string - select one instance of a string e.g. `background-color` and press kb(editor.action.selectHighlights). Now you can replace all instances by simply typing. That is the tip of the iceberg for multi-cursor editing have a look at the `selection menu` and our handy [keyboard reference guide](command:workbench.action.keybindingsReference) for additional actions. diff --git a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts index 76a67b79d8e..48160e32d1e 100644 --- a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts +++ b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts @@ -40,6 +40,8 @@ import { IMessageService, Severity } from 'vs/platform/message/common/message'; import { IThemeService, registerThemingParticipant } from 'vs/platform/theme/common/themeService'; import { registerColor, focusBorder, textLinkForeground, textLinkActiveForeground, textPreformatForeground, contrastBorder, textBlockQuoteBackground, textBlockQuoteBorder } from 'vs/platform/theme/common/colorRegistry'; import { getExtraColor } from 'vs/workbench/parts/welcome/walkThrough/node/walkThroughUtils'; +import { UILabelProvider } from 'vs/platform/keybinding/common/keybindingLabels'; +import { OS, OperatingSystem } from 'vs/base/common/platform'; export const WALK_THROUGH_FOCUS = new RawContextKey('interactivePlaygroundFocus', false); @@ -406,6 +408,8 @@ export class WalkThroughPart extends BaseEditor { })); }); this.updateSizeClasses(); + this.multiCursorModifier(); + this.contentDisposables.push(this.configurationService.onDidUpdateConfiguration(() => this.multiCursorModifier())); if (input.onReady) { input.onReady(innerContent); } @@ -461,6 +465,19 @@ export class WalkThroughPart extends BaseEditor { }); } + private multiCursorModifier() { + const labels = UILabelProvider.modifierLabels[OS]; + const setting = this.configurationService.lookup('editor.multiCursorModifier'); + const modifier = labels[setting.value === 'ctrlCmd' ? (OS === OperatingSystem.Macintosh ? 'metaKey' : 'ctrlKey') : 'altKey']; + const keys = this.content.querySelectorAll('.multi-cursor-modifier'); + Array.prototype.forEach.call(keys, (key: Element) => { + while (key.firstChild) { + key.removeChild(key.firstChild); + } + key.appendChild(document.createTextNode(modifier)); + }); + } + private saveTextEditorViewState(resource: URI): void { const memento = this.getMemento(this.storageService, Scope.WORKSPACE); let editorViewStateMemento = memento[WALK_THROUGH_EDITOR_VIEW_STATE_PREFERENCE_KEY]; -- GitLab From 02783b149c99cc6e8b7f066d4660cec0d4c361d6 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Thu, 1 Jun 2017 16:12:48 -0700 Subject: [PATCH 0481/1347] Use jsx transformations in emmet --- extensions/emmet/src/abbreviationActions.ts | 13 ++++++++----- extensions/emmet/src/emmetCompletionProvider.ts | 3 ++- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/extensions/emmet/src/abbreviationActions.ts b/extensions/emmet/src/abbreviationActions.ts index c95bfed3211..6f9bbe78f50 100644 --- a/extensions/emmet/src/abbreviationActions.ts +++ b/extensions/emmet/src/abbreviationActions.ts @@ -20,11 +20,13 @@ export function wrapWithAbbreviation() { rangeToReplace = new vscode.Range(rangeToReplace.start.line, 0, rangeToReplace.start.line, editor.document.lineAt(rangeToReplace.start.line).text.length); } let textToReplace = editor.document.getText(rangeToReplace); + let syntax = getSyntax(editor.document); let options = { field: field, - syntax: getSyntax(editor.document), + syntax: syntax, profile: getProfile(getSyntax(editor.document)), - text: textToReplace + text: textToReplace, + addons: syntax === 'jsx' ? { 'jsx': syntax === 'jsx' } : null }; vscode.window.showInputBox({ prompt: 'Enter Abbreviation' }).then(abbr => { @@ -45,11 +47,12 @@ export function expandAbbreviation() { if (rangeToReplace.isEmpty) { [rangeToReplace, abbr] = extractAbbreviation(rangeToReplace.start); } - + let syntax = getSyntax(editor.document); let options = { field: field, - syntax: getSyntax(editor.document), - profile: getProfile(getSyntax(editor.document)) + syntax: syntax, + profile: getProfile(getSyntax(editor.document)), + addons: syntax === 'jsx' ? { 'jsx': true } : null }; let expandedText = expand(abbr, options); diff --git a/extensions/emmet/src/emmetCompletionProvider.ts b/extensions/emmet/src/emmetCompletionProvider.ts index cbd5b750ae2..9a84da40c31 100644 --- a/extensions/emmet/src/emmetCompletionProvider.ts +++ b/extensions/emmet/src/emmetCompletionProvider.ts @@ -40,7 +40,8 @@ function getExpandedAbbreviation(document: vscode.TextDocument, position: vscode let expandedWord = expand(wordToExpand, { field: field, syntax: syntax, - profile: getProfile(syntax) + profile: getProfile(syntax), + addons: syntax === 'jsx' ? { 'jsx': true } : null }); let completionitem = new vscode.CompletionItem(wordToExpand); -- GitLab From d80d55063470aa31f7fe14e856cb56e26656c5b8 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Thu, 1 Jun 2017 16:15:25 -0700 Subject: [PATCH 0482/1347] Removing toggleComment from new emmet features as it needs more work --- src/vs/workbench/parts/emmet/electron-browser/emmetActions.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/emmet/electron-browser/emmetActions.ts b/src/vs/workbench/parts/emmet/electron-browser/emmetActions.ts index a313f378b21..e6f0e88243b 100644 --- a/src/vs/workbench/parts/emmet/electron-browser/emmetActions.ts +++ b/src/vs/workbench/parts/emmet/electron-browser/emmetActions.ts @@ -249,8 +249,7 @@ export abstract class EmmetEditorAction extends EditorAction { 'editor.emmet.action.mergeLines': 'emmet.mergeLines', 'editor.emmet.action.selectPreviousItem': 'emmet.selectPrevItem', 'editor.emmet.action.selectNextItem': 'emmet.selectNextItem', - 'editor.emmet.action.splitJoinTag': 'emmet.splitJoinTag', - 'editor.emmet.action.toggleComment': 'emmet.toggleComment' + 'editor.emmet.action.splitJoinTag': 'emmet.splitJoinTag' }; protected emmetActionName: string; -- GitLab From 2f0ad0af90b2c0a9daa79c4155ac58bc10f4a169 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Thu, 1 Jun 2017 16:26:45 -0700 Subject: [PATCH 0483/1347] Cleaning up messag for tsc mismatch warning as part of #27826 --- extensions/typescript/src/features/bufferSyncSupport.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/typescript/src/features/bufferSyncSupport.ts b/extensions/typescript/src/features/bufferSyncSupport.ts index f2b11faebef..90b989b77a4 100644 --- a/extensions/typescript/src/features/bufferSyncSupport.ts +++ b/extensions/typescript/src/features/bufferSyncSupport.ts @@ -298,7 +298,7 @@ export default class BufferSyncSupport { } if (tscVersion && tscVersion !== this.client.apiVersion.versionString) { window.showInformationMessage( - localize('versionMismatch', 'Version mismatch! global tsc ({0}) != VS Code\'s language service ({1}). Inconsistent compile errors might occur', tscVersion, this.client.apiVersion.versionString), + localize('versionMismatch', 'Using TypeScript ({1}) for editor features. TypeScript ({0}) is installed globally on your machine. Inconsistent compile errors may occur', tscVersion, this.client.apiVersion.versionString), { title: localize('moreInformation', 'More Information'), id: 1 -- GitLab From 786e0984cbc53eaa64fd2706e46c73d87394a268 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Thu, 1 Jun 2017 16:46:06 -0700 Subject: [PATCH 0484/1347] Telemetry for expand/collapse suggest docs --- src/vs/editor/contrib/suggest/browser/suggestWidget.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index 00c80169328..cdd6d6f3e1b 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -814,6 +814,7 @@ export class SuggestWidget implements IContentWidget, IDelegate this.details.element.style.borderColor = this.detailsFocusBorderColor; } } + this.telemetryService.publicLog('suggestWidget:toggleDetailsFocus', this.editor.getTelemetryData()); } toggleDetails(): void { @@ -827,13 +828,14 @@ export class SuggestWidget implements IContentWidget, IDelegate removeClass(this.element, 'docs-side'); removeClass(this.element, 'docs-below'); this.editor.layoutContentWidget(this); + this.telemetryService.publicLog('suggestWidget:collapseDetails', this.editor.getTelemetryData()); } else { this.storageService.store('expandSuggestionDocs', true, StorageScope.GLOBAL); - this.expandSideOrBelow(); - this.showDetails(); + this.telemetryService.publicLog('suggestWidget:expandDetails', this.editor.getTelemetryData()); } + } showDetails(): void { -- GitLab From 874bb86c94e608eb6c61c8ff930960a59f510325 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Thu, 1 Jun 2017 17:27:02 -0700 Subject: [PATCH 0485/1347] Fixes #27869 --- src/vs/editor/contrib/suggest/browser/suggestWidget.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index cdd6d6f3e1b..3ae8ad6be8c 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -831,7 +831,6 @@ export class SuggestWidget implements IContentWidget, IDelegate this.telemetryService.publicLog('suggestWidget:collapseDetails', this.editor.getTelemetryData()); } else { this.storageService.store('expandSuggestionDocs', true, StorageScope.GLOBAL); - this.expandSideOrBelow(); this.showDetails(); this.telemetryService.publicLog('suggestWidget:expandDetails', this.editor.getTelemetryData()); } @@ -842,6 +841,7 @@ export class SuggestWidget implements IContentWidget, IDelegate if (this.state !== State.Open && this.state !== State.Details) { return; } + this.expandSideOrBelow(); show(this.details.element); this.renderDetails(); -- GitLab From df1034a8a4b144a24c44c80ffde0c8cab8fb408d Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Thu, 1 Jun 2017 17:27:29 -0700 Subject: [PATCH 0486/1347] Fixes #27610 --- .../contrib/suggest/browser/suggestWidget.ts | 64 +++---------------- 1 file changed, 9 insertions(+), 55 deletions(-) diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index 3ae8ad6be8c..386980d3288 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -846,8 +846,8 @@ export class SuggestWidget implements IContentWidget, IDelegate show(this.details.element); this.renderDetails(); - // With docs showing up, list might need adjustments to keep it close to the cursor - this.adjustListPosition(); + // Reset margin-top that was set as Fix for #26416 + this.listElement.style.marginTop = '0px'; // with docs showing up widget width/height may change, so reposition the widget this.editor.layoutContentWidget(this); @@ -939,15 +939,13 @@ export class SuggestWidget implements IContentWidget, IDelegate removeClass(this.element, 'list-right'); } - if (cursorY > widgetY) { - if (!hasClass(this.element, 'widget-above')) { - addClass(this.element, 'widget-above'); - // Since the widget was previously not above the cursor, - // the list needs to be adjusted to keep it close to the cursor - this.adjustListPosition(); - } - } else { - removeClass(this.element, 'widget-above'); + if (hasClass(this.element, 'docs-side') + && cursorY > widgetY + && this.details.element.offsetHeight > this.listElement.offsetHeight) { + + // Fix for #26416 + // Docs is bigger than list and widget is above cursor, apply margin-top so that list appears right above cursor + this.listElement.style.marginTop = `${this.details.element.offsetHeight - this.listElement.offsetHeight}px`; } } @@ -962,50 +960,6 @@ export class SuggestWidget implements IContentWidget, IDelegate } } - private adjustListPosition(): void { - - - if (hasClass(this.element, 'docs-side')) { - - if (this.details.element.offsetHeight > this.listElement.offsetHeight) { - - // Fix for #26416 - // Docs is bigger than list and widget is above cursor, apply margin-top so that list appears right above cursor - if (hasClass(this.element, 'widget-above')) { - this.listElement.style.marginTop = `${this.details.element.offsetHeight - this.listElement.offsetHeight}px`; - } - - // Fix for #26244 - // if (hasClass(this.element, 'list-right')) { - // addClass(this.listElement, 'empty-left-border'); - // removeClass(this.listElement, 'empty-right-border'); - // } else { - // addClass(this.listElement, 'empty-right-border'); - // removeClass(this.listElement, 'empty-left-border'); - // } - - // removeClass(this.details.element, 'empty-left-border'); - // removeClass(this.details.element, 'empty-right-border'); - return; - } else { - // Fix for #26244 - // if (hasClass(this.element, 'list-right')) { - // addClass(this.details.element, 'empty-right-border'); - // removeClass(this.details.element, 'empty-left-border'); - // } else { - // addClass(this.details.element, 'empty-left-border'); - // removeClass(this.details.element, 'empty-right-border'); - // } - - // removeClass(this.listElement, 'empty-right-border'); - // removeClass(this.listElement, 'empty-left-border'); - } - } - - // Reset margin-top that was set as Fix for #26416 - this.listElement.style.marginTop = '0px'; - } - private renderDetails(): void { if (this.state === State.Details || this.state === State.Open) { this.details.render(this.list.getFocusedElements()[0]); -- GitLab From af2752dad442341000b0bf95861b91ecd8263ca0 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Thu, 1 Jun 2017 20:32:00 -0700 Subject: [PATCH 0487/1347] Fixes #27876 --- src/vs/editor/contrib/suggest/browser/media/suggest.css | 5 +++-- src/vs/editor/contrib/suggest/browser/suggestWidget.ts | 9 ++++++++- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/src/vs/editor/contrib/suggest/browser/media/suggest.css b/src/vs/editor/contrib/suggest/browser/media/suggest.css index 577af30bea5..0fc6559fdf1 100644 --- a/src/vs/editor/contrib/suggest/browser/media/suggest.css +++ b/src/vs/editor/contrib/suggest/browser/media/suggest.css @@ -121,6 +121,7 @@ .monaco-editor .suggest-widget .details > .monaco-scrollable-element > .body > .header > .close { background-image: url('./close.svg'); float: right; + margin-right: 5px; } .monaco-editor .suggest-widget .monaco-list .monaco-list-row > .contents > .main > .readMore { @@ -242,10 +243,10 @@ opacity: 0.7; word-break: break-all; margin: 0; + padding: 4px 0 4px 5px; } -.monaco-editor .suggest-widget .details > .monaco-scrollable-element > .body > .docs, -.monaco-editor .suggest-widget .details > .monaco-scrollable-element > .body > .header { +.monaco-editor .suggest-widget .details > .monaco-scrollable-element > .body > .docs { margin: 0; padding: 4px 5px; } diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index 386980d3288..7bec683cacf 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -243,9 +243,16 @@ class SuggestionDetails { return; } removeClass(this.el, 'no-docs'); - this.type.innerText = item.suggestion.detail || ''; this.docs.textContent = item.suggestion.documentation; + if (item.suggestion.detail) { + this.type.innerText = item.suggestion.detail; + show(this.type); + } else { + this.type.innerText = ''; + hide(this.type); + } + this.el.style.height = this.header.offsetHeight + this.docs.offsetHeight + 'px'; this.close.onmousedown = e => { -- GitLab From 4ff7fbd861a236b2ee225726559b18dc51b73aff Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Fri, 2 Jun 2017 06:56:46 +0200 Subject: [PATCH 0488/1347] theming - apply panel.background to editors in panels --- .../workbench/browser/parts/panel/panelPart.ts | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/browser/parts/panel/panelPart.ts b/src/vs/workbench/browser/parts/panel/panelPart.ts index 8ad40e000be..f3334acfe78 100644 --- a/src/vs/workbench/browser/parts/panel/panelPart.ts +++ b/src/vs/workbench/browser/parts/panel/panelPart.ts @@ -26,7 +26,7 @@ import { ActionsOrientation, ActionBar } from 'vs/base/browser/ui/actionbar/acti import { ClosePanelAction, PanelAction, ToggleMaximizedPanelAction } from 'vs/workbench/browser/parts/panel/panelActions'; import { IThemeService, registerThemingParticipant, ITheme, ICssStyleCollector } from 'vs/platform/theme/common/themeService'; import { PANEL_BACKGROUND, PANEL_BORDER, PANEL_ACTIVE_TITLE_FOREGROUND, PANEL_INACTIVE_TITLE_FOREGROUND, PANEL_ACTIVE_TITLE_BORDER } from 'vs/workbench/common/theme'; -import { activeContrastBorder, focusBorder, contrastBorder } from 'vs/platform/theme/common/colorRegistry'; +import { activeContrastBorder, focusBorder, contrastBorder, editorBackground } from 'vs/platform/theme/common/colorRegistry'; export class PanelPart extends CompositePart implements IPanelService { @@ -194,6 +194,20 @@ export class PanelPart extends CompositePart implements IPanelService { registerThemingParticipant((theme: ITheme, collector: ICssStyleCollector) => { + // Panel Background: since panels can host editors, we apply a background rule if the panel background + // color is different from the editor background color. This is a bit of a hack though. The better way + // would be to have a way to push the background color onto each editor widget itself somehow. + const panelBackground = theme.getColor(PANEL_BACKGROUND); + if (panelBackground && panelBackground !== theme.getColor(editorBackground)) { + collector.addRule(` + .monaco-workbench > .part.panel > .content .monaco-editor, + .monaco-workbench > .part.panel > .content .monaco-editor .margin, + .monaco-workbench > .part.panel > .content .monaco-editor .monaco-editor-background { + background-color: ${panelBackground}; + } + `); + } + // Title Active const titleActive = theme.getColor(PANEL_ACTIVE_TITLE_FOREGROUND); const titleActiveBorder = theme.getColor(PANEL_ACTIVE_TITLE_BORDER); -- GitLab From fff2f37662b3848622c36f9a1c14baff992dff6b Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 2 Jun 2017 09:38:20 +0200 Subject: [PATCH 0489/1347] Add a way to open VS Code's Accessibility docs from Alt+F1 (#27833) --- .../electron-browser/accessibility.ts | 46 ++++++++++++------- 1 file changed, 29 insertions(+), 17 deletions(-) diff --git a/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.ts b/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.ts index c155e0cb656..d5e42787347 100644 --- a/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.ts +++ b/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.ts @@ -14,7 +14,7 @@ import * as dom from 'vs/base/browser/dom'; import { renderHtml } from 'vs/base/browser/htmlContentRenderer'; import { FastDomNode, createFastDomNode } from 'vs/base/browser/fastDomNode'; import { Widget } from 'vs/base/browser/ui/widget'; -import { ServicesAccessor } from 'vs/platform/instantiation/common/instantiation'; +import { ServicesAccessor, IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { RawContextKey, IContextKey, IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; import { ICommonCodeEditor, IEditorContribution } from 'vs/editor/common/editorCommon'; @@ -30,6 +30,8 @@ import * as editorOptions from 'vs/editor/common/config/editorOptions'; import * as platform from 'vs/base/common/platform'; import { IConfigurationEditingService, ConfigurationTarget } from 'vs/workbench/services/configuration/common/configurationEditing'; import { alert } from 'vs/base/browser/ui/aria/aria'; +import { IOpenerService } from "vs/platform/opener/common/opener"; +import URI from "vs/base/common/uri"; const CONTEXT_ACCESSIBILITY_WIDGET_VISIBLE = new RawContextKey('accessibilityHelpWidgetVisible', false); @@ -47,15 +49,12 @@ class AccessibilityHelpController extends Disposable implements IEditorContribut constructor( editor: ICodeEditor, - @IContextKeyService contextKeyService: IContextKeyService, - @IKeybindingService keybindingService: IKeybindingService, - @IConfigurationService configurationService: IConfigurationService, - @IConfigurationEditingService configurationEditingService: IConfigurationEditingService + @IInstantiationService instantiationService: IInstantiationService ) { super(); this._editor = editor; - this._widget = this._register(new AccessibilityHelpWidget(this._editor, contextKeyService, keybindingService, configurationService, configurationEditingService)); + this._widget = this._register(instantiationService.createInstance(AccessibilityHelpWidget, this._editor)); } public getId(): string { @@ -78,27 +77,22 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { private static HEIGHT = 300; private _editor: ICodeEditor; - private _keybindingService: IKeybindingService; - private _configurationService: IConfigurationService; - private _configurationEditingService: IConfigurationEditingService; private _domNode: FastDomNode; private _isVisible: boolean; private _isVisibleKey: IContextKey; constructor( editor: ICodeEditor, - contextKeyService: IContextKeyService, - keybindingService: IKeybindingService, - configurationService: IConfigurationService, - configurationEditingService: IConfigurationEditingService + @IContextKeyService private _contextKeyService: IContextKeyService, + @IKeybindingService private _keybindingService: IKeybindingService, + @IConfigurationService private _configurationService: IConfigurationService, + @IConfigurationEditingService private _configurationEditingService: IConfigurationEditingService, + @IOpenerService private _openerService: IOpenerService ) { super(); this._editor = editor; - this._keybindingService = keybindingService; - this._configurationService = configurationService; - this._configurationEditingService = configurationEditingService; - this._isVisibleKey = CONTEXT_ACCESSIBILITY_WIDGET_VISIBLE.bindTo(contextKeyService); + this._isVisibleKey = CONTEXT_ACCESSIBILITY_WIDGET_VISIBLE.bindTo(this._contextKeyService); this._domNode = createFastDomNode(document.createElement('div')); this._domNode.setClassName('accessibilityHelpWidget'); @@ -120,6 +114,7 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { if (!this._isVisible) { return; } + if (e.equals(KeyMod.CtrlCmd | KeyCode.KEY_E)) { alert(nls.localize('emergencyConfOn', "Now changing the setting `editor.accessibilitySupport` to 'on'.")); @@ -131,6 +126,15 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { e.preventDefault(); e.stopPropagation(); } + + if (e.equals(KeyMod.CtrlCmd | KeyCode.KEY_H)) { + alert(nls.localize('openingDocs', "Now opening the VS Code Accessibility documentation page.")); + + this._openerService.open(URI.parse('https://go.microsoft.com/fwlink/?linkid=851010')); + + e.preventDefault(); + e.stopPropagation(); + } })); this.onblur(this._domNode.domNode, () => { @@ -232,6 +236,14 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { text += '\n\n - ' + this._descriptionForCommand(ToggleTabFocusModeAction.ID, NLS_TAB_FOCUS_MODE_OFF, NLS_TAB_FOCUS_MODE_OFF_NO_KB); } + const openDocMessage = ( + platform.isMacintosh + ? nls.localize('openDocMac', "Press Command+H now to open a browser window with more VS Code information related to Accessibility.") + : nls.localize('openDocWinLinux', "Press Control+H now to open a browser window with more VS Code information related to Accessibility.") + ); + + text += '\n\n' + openDocMessage; + text += '\n\n' + nls.localize('outroMsg', "You can dismiss this tooltip and return to the editor by pressing Escape or Shift+Escape."); this._domNode.domNode.appendChild(renderHtml({ -- GitLab From 496603e40dbe7bec2be0b0a6cce1f9b7f753300c Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 2 Jun 2017 09:40:35 +0200 Subject: [PATCH 0490/1347] fix #27898 --- .../contrib/snippet/browser/snippetParser.ts | 11 ++++----- .../contrib/snippet/browser/snippetSession.ts | 8 +++---- .../test/browser/snippetController2.test.ts | 23 +++++++++++++++++++ 3 files changed, 32 insertions(+), 10 deletions(-) diff --git a/src/vs/editor/contrib/snippet/browser/snippetParser.ts b/src/vs/editor/contrib/snippet/browser/snippetParser.ts index 488b53b864b..7cd1fd61b3e 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetParser.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetParser.ts @@ -331,8 +331,8 @@ export class SnippetParser { return value.replace(/\$|}|\\/g, '\\$&'); } - static parse(template: string): TextmateSnippet { - const marker = new SnippetParser(true, false).parse(template, true); + static parse(template: string, enforceFinalTabstop?: boolean): TextmateSnippet { + const marker = new SnippetParser(true, false).parse(template, true, enforceFinalTabstop); return new TextmateSnippet(marker); } @@ -351,7 +351,7 @@ export class SnippetParser { return Marker.toString(this.parse(value)); } - parse(value: string, insertFinalTabstop?: boolean): Marker[] { + parse(value: string, insertFinalTabstop?: boolean, enforceFinalTabstop?: boolean): Marker[] { const marker: Marker[] = []; this._scanner.text(value); @@ -395,9 +395,8 @@ export class SnippetParser { walk(marker, placeholderDefaultValues); if ( - insertFinalTabstop - && placeholderDefaultValues.size > 0 - && !placeholderDefaultValues.has('0') + !placeholderDefaultValues.has('0') && // there is no final tabstop + (insertFinalTabstop && placeholderDefaultValues.size > 0 || enforceFinalTabstop) ) { // the snippet uses placeholders but has no // final tabstop defined -> insert at the end diff --git a/src/vs/editor/contrib/snippet/browser/snippetSession.ts b/src/vs/editor/contrib/snippet/browser/snippetSession.ts index a000690d786..8f132684531 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetSession.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetSession.ts @@ -243,7 +243,7 @@ export class SnippetSession { return selection; } - static createEditsAndSnippets(editor: ICommonCodeEditor, template: string, overwriteBefore: number, overwriteAfter: number): { edits: IIdentifiedSingleEditOperation[], snippets: OneSnippet[] } { + static createEditsAndSnippets(editor: ICommonCodeEditor, template: string, overwriteBefore: number, overwriteAfter: number, enforceFinalTabstop: boolean): { edits: IIdentifiedSingleEditOperation[], snippets: OneSnippet[] } { const model = editor.getModel(); const edits: IIdentifiedSingleEditOperation[] = []; @@ -288,7 +288,7 @@ export class SnippetSession { const start = snippetSelection.getStartPosition(); const adjustedTemplate = SnippetSession.adjustWhitespace(model, start, template); - const snippet = SnippetParser.parse(adjustedTemplate).resolveVariables(new EditorSnippetVariableResolver(model, selection)); + const snippet = SnippetParser.parse(adjustedTemplate, enforceFinalTabstop).resolveVariables(new EditorSnippetVariableResolver(model, selection)); const offset = model.getOffsetAt(start) + delta; delta += snippet.text.length - model.getValueLengthInRange(snippetSelection); @@ -325,7 +325,7 @@ export class SnippetSession { const model = this._editor.getModel(); // make insert edit and start with first selections - const { edits, snippets } = SnippetSession.createEditsAndSnippets(this._editor, this._template, this._overwriteBefore, this._overwriteAfter); + const { edits, snippets } = SnippetSession.createEditsAndSnippets(this._editor, this._template, this._overwriteBefore, this._overwriteAfter, false); this._snippets = snippets; this._editor.setSelections(model.pushEditOperations(this._editor.getSelections(), edits, undoEdits => { @@ -338,7 +338,7 @@ export class SnippetSession { } merge(template: string, overwriteBefore: number = 0, overwriteAfter: number = 0): void { - const { edits, snippets } = SnippetSession.createEditsAndSnippets(this._editor, template, overwriteBefore, overwriteAfter); + const { edits, snippets } = SnippetSession.createEditsAndSnippets(this._editor, template, overwriteBefore, overwriteAfter, true); this._editor.setSelections(this._editor.getModel().pushEditOperations(this._editor.getSelections(), edits, undoEdits => { diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts index 0074a467414..2f42a0c9932 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts @@ -175,6 +175,29 @@ suite('SnippetController2', function () { ctrl.insert('farboo'); assertSelections(editor, new Selection(1, 7, 1, 7), new Selection(2, 11, 2, 11)); + assertContextKeys(contextKeys, true, false, true); + + ctrl.next(); + assertSelections(editor, new Selection(1, 7, 1, 7), new Selection(2, 11, 2, 11)); + assertContextKeys(contextKeys, false, false, false); + }); + + test('Nested snippets without final placeholder jumps to next outer placeholder, #27898', function () { + const ctrl = new SnippetController2(editor, contextKeys); + + ctrl.insert('for(const ${1:element} of ${2:array}) {$0}'); + assertContextKeys(contextKeys, true, false, true); + assertSelections(editor, new Selection(1, 11, 1, 18), new Selection(2, 15, 2, 22)); + + ctrl.next(); + assertContextKeys(contextKeys, true, true, true); + assertSelections(editor, new Selection(1, 22, 1, 27), new Selection(2, 26, 2, 31)); + + ctrl.insert('document'); + assertContextKeys(contextKeys, true, true, true); + assertSelections(editor, new Selection(1, 30, 1, 30), new Selection(2, 34, 2, 34)); + + ctrl.next(); assertContextKeys(contextKeys, false, false, false); }); -- GitLab From 729c59fd7eac85d72ef4a98d9dfe445e2ac3e6b3 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Fri, 2 Jun 2017 09:59:35 +0200 Subject: [PATCH 0491/1347] Make tree data api public --- src/vs/workbench/api/node/extHost.api.impl.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index 065f16fc76c..f6f4099db43 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -365,13 +365,13 @@ export function createApiFactory( } return extHostTerminalService.createTerminal(nameOrOptions, shellPath, shellArgs); }, + registerTreeDataProvider(viewId: string, treeDataProvider: vscode.TreeDataProvider): vscode.Disposable { + return extHostTreeViews.registerTreeDataProvider(viewId, treeDataProvider); + }, // proposed API sampleFunction: proposedApiFunction(extension, () => { return extHostMessageService.showMessage(Severity.Info, 'Hello Proposed Api!', {}, []); }), - registerTreeDataProvider: proposedApiFunction(extension, (viewId: string, treeDataProvider: vscode.TreeDataProvider): vscode.Disposable => { - return extHostTreeViews.registerTreeDataProvider(viewId, treeDataProvider); - }) }; // namespace: workspace -- GitLab From 7c46b52166ad31663b8ba7b96262fd459f52078a Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Fri, 2 Jun 2017 10:50:21 +0200 Subject: [PATCH 0492/1347] imports style --- src/vs/base/browser/ui/dropdown/dropdown.ts | 2 +- src/vs/editor/contrib/gotoError/browser/gotoError.ts | 2 +- .../browser/parts/activitybar/activitybarActions.ts | 6 +++--- .../parts/codeEditor/electron-browser/accessibility.ts | 6 +++--- .../electron-browser/toggleMultiCursorModifier.ts | 2 +- .../preferences/browser/keybindingsEditorContribution.ts | 2 +- .../crashReporter/electron-browser/crashReporterService.ts | 4 ++-- 7 files changed, 12 insertions(+), 12 deletions(-) diff --git a/src/vs/base/browser/ui/dropdown/dropdown.ts b/src/vs/base/browser/ui/dropdown/dropdown.ts index e078d8ddc2b..b01ac4b60f6 100644 --- a/src/vs/base/browser/ui/dropdown/dropdown.ts +++ b/src/vs/base/browser/ui/dropdown/dropdown.ts @@ -16,7 +16,7 @@ import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { IContextViewProvider } from 'vs/base/browser/ui/contextview/contextview'; import { IMenuOptions } from 'vs/base/browser/ui/menu/menu'; import { ResolvedKeybinding } from 'vs/base/common/keyCodes'; -import { EventHelper, EventType } from "vs/base/browser/dom"; +import { EventHelper, EventType } from 'vs/base/browser/dom'; export interface ILabelRenderer { (container: HTMLElement): IDisposable; diff --git a/src/vs/editor/contrib/gotoError/browser/gotoError.ts b/src/vs/editor/contrib/gotoError/browser/gotoError.ts index 600a3024636..69792d86b8e 100644 --- a/src/vs/editor/contrib/gotoError/browser/gotoError.ts +++ b/src/vs/editor/contrib/gotoError/browser/gotoError.ts @@ -29,7 +29,7 @@ import { Color } from 'vs/base/common/color'; import { EditorContextKeys } from 'vs/editor/common/editorContextKeys'; import { getAccessibilitySupport } from 'vs/base/browser/browser'; import { AccessibilitySupport } from 'vs/base/common/platform'; -import { editorErrorForeground, editorErrorBorder, editorWarningForeground, editorWarningBorder } from "vs/editor/common/view/editorColorRegistry"; +import { editorErrorForeground, editorErrorBorder, editorWarningForeground, editorWarningBorder } from 'vs/editor/common/view/editorColorRegistry'; class MarkerModel { diff --git a/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts b/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts index ee8df3e9d27..6deb54dcab2 100644 --- a/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts +++ b/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts @@ -27,9 +27,9 @@ import { IPartService, Parts } from 'vs/workbench/services/part/common/partServi import { IThemeService, ITheme, registerThemingParticipant, ICssStyleCollector } from 'vs/platform/theme/common/themeService'; import { ACTIVITY_BAR_BADGE_FOREGROUND, ACTIVITY_BAR_BADGE_BACKGROUND, ACTIVITY_BAR_DRAG_AND_DROP_BACKGROUND, ACTIVITY_BAR_FOREGROUND } from 'vs/workbench/common/theme'; import { contrastBorder, activeContrastBorder, focusBorder } from 'vs/platform/theme/common/colorRegistry'; -import { StandardMouseEvent } from "vs/base/browser/mouseEvent"; -import { KeyCode } from "vs/base/common/keyCodes"; -import { StandardKeyboardEvent } from "vs/base/browser/keyboardEvent"; +import { StandardMouseEvent } from 'vs/base/browser/mouseEvent'; +import { KeyCode } from 'vs/base/common/keyCodes'; +import { StandardKeyboardEvent } from 'vs/base/browser/keyboardEvent'; export interface IViewletActivity { badge: IBadge; diff --git a/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.ts b/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.ts index d5e42787347..1147eef15c2 100644 --- a/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.ts +++ b/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.ts @@ -25,13 +25,13 @@ import { editorContribution } from 'vs/editor/browser/editorBrowserExtensions'; import { ToggleTabFocusModeAction } from 'vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode'; import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; import { editorWidgetBackground, widgetShadow, contrastBorder } from 'vs/platform/theme/common/colorRegistry'; -import { IConfigurationService } from "vs/platform/configuration/common/configuration"; +import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import * as editorOptions from 'vs/editor/common/config/editorOptions'; import * as platform from 'vs/base/common/platform'; import { IConfigurationEditingService, ConfigurationTarget } from 'vs/workbench/services/configuration/common/configurationEditing'; import { alert } from 'vs/base/browser/ui/aria/aria'; -import { IOpenerService } from "vs/platform/opener/common/opener"; -import URI from "vs/base/common/uri"; +import { IOpenerService } from 'vs/platform/opener/common/opener'; +import URI from 'vs/base/common/uri'; const CONTEXT_ACCESSIBILITY_WIDGET_VISIBLE = new RawContextKey('accessibilityHelpWidgetVisible', false); diff --git a/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.ts b/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.ts index de0783f35b6..0efd4f260f8 100644 --- a/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.ts +++ b/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.ts @@ -11,7 +11,7 @@ import { Action } from 'vs/base/common/actions'; import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; import { IWorkbenchActionRegistry, Extensions } from 'vs/workbench/common/actionRegistry'; import { IConfigurationEditingService, ConfigurationTarget } from 'vs/workbench/services/configuration/common/configurationEditing'; -import { IConfigurationService } from "vs/platform/configuration/common/configuration"; +import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; export class ToggleMultiCursorModifierAction extends Action { diff --git a/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.ts b/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.ts index 633268739df..ed4b39ebc17 100644 --- a/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.ts +++ b/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.ts @@ -26,7 +26,7 @@ import { parseTree, Node } from 'vs/base/common/json'; import { KeybindingIO } from 'vs/workbench/services/keybinding/common/keybindingIO'; import { ScanCodeBinding } from 'vs/workbench/services/keybinding/common/scanCode'; import { EditorContextKeys } from 'vs/editor/common/editorContextKeys'; -import { WindowsNativeResolvedKeybinding } from "vs/workbench/services/keybinding/common/windowsKeyboardMapper"; +import { WindowsNativeResolvedKeybinding } from 'vs/workbench/services/keybinding/common/windowsKeyboardMapper'; const NLS_LAUNCH_MESSAGE = nls.localize('defineKeybinding.start', "Define Keybinding"); const NLS_KB_LAYOUT_ERROR_MESSAGE = nls.localize('defineKeybinding.kbLayoutErrorMessage', "You won't be able to produce this key combination under your current keyboard layout."); diff --git a/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts b/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts index 59c19df4001..096c578d77f 100644 --- a/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts +++ b/src/vs/workbench/services/crashReporter/electron-browser/crashReporterService.ts @@ -13,8 +13,8 @@ import { crashReporter } from 'electron'; import product from 'vs/platform/node/product'; import pkg from 'vs/platform/node/package'; import * as os from 'os'; -import { ICrashReporterService, TELEMETRY_SECTION_ID, ICrashReporterConfig } from "vs/workbench/services/crashReporter/common/crashReporterService"; -import { isWindows, isMacintosh, isLinux } from "vs/base/common/platform"; +import { ICrashReporterService, TELEMETRY_SECTION_ID, ICrashReporterConfig } from 'vs/workbench/services/crashReporter/common/crashReporterService'; +import { isWindows, isMacintosh, isLinux } from 'vs/base/common/platform'; export class CrashReporterService implements ICrashReporterService { -- GitLab From ca2491d91649fbe32e08e5e6178987ae760ecde5 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Fri, 2 Jun 2017 11:08:10 +0200 Subject: [PATCH 0493/1347] Show views in extension editor page --- .../common/extensionManagement.ts | 7 ++--- .../extensions/browser/extensionEditor.ts | 31 +++++++++++++++++-- 2 files changed, 32 insertions(+), 6 deletions(-) diff --git a/src/vs/platform/extensionManagement/common/extensionManagement.ts b/src/vs/platform/extensionManagement/common/extensionManagement.ts index 8df367a9615..e60c845c300 100644 --- a/src/vs/platform/extensionManagement/common/extensionManagement.ts +++ b/src/vs/platform/extensionManagement/common/extensionManagement.ts @@ -74,10 +74,9 @@ export interface ITheme { label: string; } -export interface ITreeExplorer { +export interface IView { id: string; - label: string; - icon: string; + name: string; } export interface IExtensionContributions { @@ -91,7 +90,7 @@ export interface IExtensionContributions { menus?: { [context: string]: IMenu[] }; snippets?: ISnippet[]; themes?: ITheme[]; - explorer?: ITreeExplorer; + views?: { [location: string]: IView[] }; } export interface IExtensionManifest { diff --git a/src/vs/workbench/parts/extensions/browser/extensionEditor.ts b/src/vs/workbench/parts/extensions/browser/extensionEditor.ts index 11915ba81c4..9334cdb4f53 100644 --- a/src/vs/workbench/parts/extensions/browser/extensionEditor.ts +++ b/src/vs/workbench/parts/extensions/browser/extensionEditor.ts @@ -25,7 +25,7 @@ import { BaseEditor } from 'vs/workbench/browser/parts/editor/baseEditor'; import { IViewletService } from 'vs/workbench/services/viewlet/browser/viewlet'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; -import { IExtensionGalleryService, IExtensionManifest, IKeyBinding } from 'vs/platform/extensionManagement/common/extensionManagement'; +import { IExtensionGalleryService, IExtensionManifest, IKeyBinding, IView } from 'vs/platform/extensionManagement/common/extensionManagement'; import { ResolvedKeybinding } from 'vs/base/common/keyCodes'; import { ExtensionsInput } from 'vs/workbench/parts/extensions/common/extensionsInput'; import { IExtensionsWorkbenchService, IExtensionsViewlet, VIEWLET_ID, IExtension, IExtensionDependencies } from 'vs/workbench/parts/extensions/common/extensions'; @@ -370,7 +370,8 @@ export class ExtensionEditor extends BaseEditor { this.renderLanguages(content, manifest, layout), this.renderThemes(content, manifest, layout), this.renderJSONValidation(content, manifest, layout), - this.renderDebuggers(content, manifest, layout) + this.renderDebuggers(content, manifest, layout), + this.renderViews(content, manifest, layout) ]; const isEmpty = !renders.reduce((v, r) => r || v, false); @@ -495,6 +496,32 @@ export class ExtensionEditor extends BaseEditor { return true; } + private renderViews(container: HTMLElement, manifest: IExtensionManifest, onDetailsToggle: Function): boolean { + const contributes = manifest.contributes; + const contrib = contributes && contributes.views || {}; + + let views = <{ id: string, name: string, location: string }[]>Object.keys(contrib).reduce((result, location) => { + let viewsForLocation: IView[] = contrib[location]; + result.push(...viewsForLocation.map(view => ({ ...view, location }))); + return result; + }, []); + + if (!views.length) { + return false; + } + + const details = $('details', { open: true, ontoggle: onDetailsToggle }, + $('summary', null, localize('views', "Views ({0})", views.length)), + $('table', null, + $('tr', null, $('th', null, localize('view id', "ID")), $('th', null, localize('view name', "Name")), $('th', null, localize('view location', "Where"))), + ...views.map(view => $('tr', null, $('td', null, view.id), $('td', null, view.name), $('td', null, view.location))) + ) + ); + + append(container, details); + return true; + } + private renderThemes(container: HTMLElement, manifest: IExtensionManifest, onDetailsToggle: Function): boolean { const contributes = manifest.contributes; const contrib = contributes && contributes.themes || []; -- GitLab From 891adacb7a2360baead3020e7ba6f450c63642d9 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Fri, 2 Jun 2017 11:16:10 +0200 Subject: [PATCH 0494/1347] Updated instructions to add new area and test --- test/smoke/README.md | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/test/smoke/README.md b/test/smoke/README.md index 2cff1cd8b19..947fb43969a 100644 --- a/test/smoke/README.md +++ b/test/smoke/README.md @@ -10,13 +10,12 @@ If you want to include 'Data Migration' area tests use `npm test -- --latest pa * `./areas/` folder contains a `.ts` file per each area of the document. E.g. `'Search'` area goes under `'search.ts'`. Every area file contains a list of methods with the name that represents the action that can be performed in the corresponding test. This reduces the amount of test suite code and means that if the UI changes, the fix need only be applied in one place. The name of the method reflects the action the tester would do if he would perform the test manually. See [Selenium Page Objects Wiki](https://github.com/SeleniumHQ/selenium/wiki/PageObjects) and [Selenium Bot Style Tests Wiki](https://github.com/SeleniumHQ/selenium/wiki/Bot-Style-Tests) for a good explanation of the implementation. Every smoke test area contains methods that are used in a bot-style approach in `main.ts`. * `./spectron/` wraps the Spectron, with WebDriverIO API wrapped in `client.ts` and instance of Spectron Application is wrapped in `application.ts`. -* `./scripts/` contains scripts to run the smoke test. # Adding new area -To contribute a new smoke test area, add `${area}.ts` file under `./areas/`. All related tests to the area should go to the alike named file under `./tests/` This has to follow the bot-style approach described in the links mentioned above. Methods should be calling WebDriverIO API through `SpectronClient` class. If there is no existing WebDriverIO method, add it to the class. +To contribute a new smoke test area, add `${area}.ts` file under `./areas/`. All related tests to the area should go to the alike named file under `./tests/${area}.ts`. This has to follow the bot-style approach described in the links mentioned above. Methods should be calling WebDriverIO API through `SpectronClient` class. If there is no existing WebDriverIO method, add it to the class. # Adding new test -To add new test area or test, `main.ts` should be updated. The same instruction-style principle needs to be followed with the called area method names that reflect manual tester's actions. +To add new test, `./test/${area}.ts` should be updated. The same instruction-style principle needs to be followed with the called area method names that reflect manual tester's actions. # Debugging 1. Add the following configuration to launch.json, specifying binaries in `args`: @@ -37,4 +36,4 @@ To add new test area or test, `main.ts` should be updated. The same instruction- ] }, ``` -2. In main.js add `--debug-brk=9999` argument to the place where `src/mocha-runner.js` is spawned. \ No newline at end of file +2. In main.js add `--debug-brk=9999` argument to the place where `src/mocha-runner.js` is spawned. -- GitLab From 835be78328a03b492443a83b4faf4fef59c178db Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 2 Jun 2017 11:18:55 +0200 Subject: [PATCH 0495/1347] Have a good aria label when the editor has accessibility disabled (#27833) --- src/vs/editor/common/config/editorOptions.ts | 36 +++++++++----------- 1 file changed, 17 insertions(+), 19 deletions(-) diff --git a/src/vs/editor/common/config/editorOptions.ts b/src/vs/editor/common/config/editorOptions.ts index 5db649e062c..2daf0ddac8f 100644 --- a/src/vs/editor/common/config/editorOptions.ts +++ b/src/vs/editor/common/config/editorOptions.ts @@ -1634,11 +1634,9 @@ export class EditorOptionsValidator { */ export class InternalEditorOptionsFactory { - private static _handlePerformanceCritical(opts: IValidatedEditorOptions, performanceCritical: boolean): IValidatedEditorOptions { - if (!performanceCritical) { - return opts; - } - + private static _tweakValidatedOptions(opts: IValidatedEditorOptions, accessibilitySupport: platform.AccessibilitySupport): IValidatedEditorOptions { + const accessibilityIsOn = (accessibilitySupport === platform.AccessibilitySupport.Enabled); + const accessibilityIsOff = (accessibilitySupport === platform.AccessibilitySupport.Disabled); return { inDiffEditor: opts.inDiffEditor, wordSeparators: opts.wordSeparators, @@ -1666,14 +1664,14 @@ export class InternalEditorOptionsFactory { extraEditorClassName: opts.viewInfo.extraEditorClassName, disableMonospaceOptimizations: opts.viewInfo.disableMonospaceOptimizations, rulers: opts.viewInfo.rulers, - ariaLabel: opts.viewInfo.ariaLabel, + ariaLabel: (accessibilityIsOff ? nls.localize('accessibilityOffAriaLabel', "The editor is not accessible at this time. Press Alt+F1 for options.") : opts.viewInfo.ariaLabel), renderLineNumbers: opts.viewInfo.renderLineNumbers, renderCustomLineNumbers: opts.viewInfo.renderCustomLineNumbers, renderRelativeLineNumbers: opts.viewInfo.renderRelativeLineNumbers, selectOnLineNumbers: opts.viewInfo.selectOnLineNumbers, glyphMargin: opts.viewInfo.glyphMargin, revealHorizontalRightPadding: opts.viewInfo.revealHorizontalRightPadding, - roundedSelection: false, // DISABLED + roundedSelection: (accessibilityIsOn ? false : opts.viewInfo.roundedSelection), // DISABLED WHEN SCREEN READER IS ATTACHED overviewRulerLanes: opts.viewInfo.overviewRulerLanes, overviewRulerBorder: opts.viewInfo.overviewRulerBorder, cursorBlinking: opts.viewInfo.cursorBlinking, @@ -1682,14 +1680,14 @@ export class InternalEditorOptionsFactory { hideCursorInOverviewRuler: opts.viewInfo.hideCursorInOverviewRuler, scrollBeyondLastLine: opts.viewInfo.scrollBeyondLastLine, stopRenderingLineAfter: opts.viewInfo.stopRenderingLineAfter, - renderWhitespace: 'none', // DISABLED - renderControlCharacters: false, // DISABLED - fontLigatures: false, // DISABLED - renderIndentGuides: false, // DISABLED - renderLineHighlight: 'none', // DISABLED + renderWhitespace: (accessibilityIsOn ? 'none' : opts.viewInfo.renderWhitespace), // DISABLED WHEN SCREEN READER IS ATTACHED + renderControlCharacters: (accessibilityIsOn ? false : opts.viewInfo.renderControlCharacters), // DISABLED WHEN SCREEN READER IS ATTACHED + fontLigatures: (accessibilityIsOn ? false : opts.viewInfo.fontLigatures), // DISABLED WHEN SCREEN READER IS ATTACHED + renderIndentGuides: (accessibilityIsOn ? false : opts.viewInfo.renderIndentGuides), // DISABLED WHEN SCREEN READER IS ATTACHED + renderLineHighlight: (accessibilityIsOn ? 'none' : opts.viewInfo.renderLineHighlight), // DISABLED WHEN SCREEN READER IS ATTACHED scrollbar: opts.viewInfo.scrollbar, minimap: { - enabled: false, // DISABLED + enabled: (accessibilityIsOn ? false : opts.viewInfo.minimap.enabled), // DISABLED WHEN SCREEN READER IS ATTACHED renderCharacters: opts.viewInfo.minimap.renderCharacters, maxColumn: opts.viewInfo.minimap.maxColumn }, @@ -1713,12 +1711,12 @@ export class InternalEditorOptionsFactory { wordBasedSuggestions: opts.contribInfo.wordBasedSuggestions, suggestFontSize: opts.contribInfo.suggestFontSize, suggestLineHeight: opts.contribInfo.suggestLineHeight, - selectionHighlight: false, // DISABLED - occurrencesHighlight: false, // DISABLED - codeLens: false, // DISABLED - folding: false, // DISABLED + selectionHighlight: (accessibilityIsOn ? false : opts.contribInfo.selectionHighlight), // DISABLED WHEN SCREEN READER IS ATTACHED + occurrencesHighlight: (accessibilityIsOn ? false : opts.contribInfo.occurrencesHighlight), // DISABLED WHEN SCREEN READER IS ATTACHED + codeLens: (accessibilityIsOn ? false : opts.contribInfo.codeLens), // DISABLED WHEN SCREEN READER IS ATTACHED + folding: (accessibilityIsOn ? false : opts.contribInfo.folding), // DISABLED WHEN SCREEN READER IS ATTACHED showFoldingControls: opts.contribInfo.showFoldingControls, - matchBrackets: false, // DISABLED + matchBrackets: (accessibilityIsOn ? false : opts.contribInfo.matchBrackets), // DISABLED WHEN SCREEN READER IS ATTACHED find: opts.contribInfo.find } }; @@ -1738,7 +1736,7 @@ export class InternalEditorOptionsFactory { // Disable some non critical features to get as best performance as possible // See https://github.com/Microsoft/vscode/issues/26730 - const opts = this._handlePerformanceCritical(_opts, (accessibilitySupport === platform.AccessibilitySupport.Enabled)); + const opts = this._tweakValidatedOptions(_opts, accessibilitySupport); let lineDecorationsWidth: number; if (typeof opts.lineDecorationsWidth === 'string' && /^\d+(\.\d+)?ch$/.test(opts.lineDecorationsWidth)) { -- GitLab From 309963a2d045d4fceaf29c4cde9be5603a2bcdae Mon Sep 17 00:00:00 2001 From: isidor Date: Fri, 2 Jun 2017 11:25:04 +0200 Subject: [PATCH 0496/1347] null guard fixes #27640 --- .../workbench/parts/debug/electron-browser/debugService.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugService.ts b/src/vs/workbench/parts/debug/electron-browser/debugService.ts index 983d0cac314..441ac578f43 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugService.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugService.ts @@ -506,7 +506,10 @@ export class DebugService implements debug.IDebugService { } const state = this.state; - this.debugState.set(debug.State[state].toLowerCase()); + const stateLabel = debug.State[state]; + if (stateLabel) { + this.debugState.set(stateLabel.toLowerCase()); + } this._onDidChangeState.fire(state); } -- GitLab From 9caf8d7642e3a11e346b0290377c1664cf30ba27 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 2 Jun 2017 11:35:21 +0200 Subject: [PATCH 0497/1347] Have other places respect `editor.accessibilitySupport` (#27833, #27893) --- .../contrib/gotoError/browser/gotoError.ts | 3 +- .../browser/parts/editor/editorStatus.ts | 30 +++++++++++++------ 2 files changed, 22 insertions(+), 11 deletions(-) diff --git a/src/vs/editor/contrib/gotoError/browser/gotoError.ts b/src/vs/editor/contrib/gotoError/browser/gotoError.ts index 69792d86b8e..d0e1a23068b 100644 --- a/src/vs/editor/contrib/gotoError/browser/gotoError.ts +++ b/src/vs/editor/contrib/gotoError/browser/gotoError.ts @@ -27,7 +27,6 @@ import { registerColor, oneOf } from 'vs/platform/theme/common/colorRegistry'; import { IThemeService, ITheme } from 'vs/platform/theme/common/themeService'; import { Color } from 'vs/base/common/color'; import { EditorContextKeys } from 'vs/editor/common/editorContextKeys'; -import { getAccessibilitySupport } from 'vs/base/browser/browser'; import { AccessibilitySupport } from 'vs/base/common/platform'; import { editorErrorForeground, editorErrorBorder, editorWarningForeground, editorWarningBorder } from 'vs/editor/common/view/editorColorRegistry'; @@ -279,7 +278,7 @@ class MarkerNavigationWidget extends ZoneWidget { public show(where: Position, heightInLines: number): void { super.show(where, heightInLines); - if (getAccessibilitySupport() !== AccessibilitySupport.Disabled) { + if (this.editor.getConfiguration().accessibilitySupport !== AccessibilitySupport.Disabled) { this.focus(); } } diff --git a/src/vs/workbench/browser/parts/editor/editorStatus.ts b/src/vs/workbench/browser/parts/editor/editorStatus.ts index 831f6897471..d17d44c54d9 100644 --- a/src/vs/workbench/browser/parts/editor/editorStatus.ts +++ b/src/vs/workbench/browser/parts/editor/editorStatus.ts @@ -14,7 +14,6 @@ import paths = require('vs/base/common/paths'); import types = require('vs/base/common/types'); import uri from 'vs/base/common/uri'; import errors = require('vs/base/common/errors'); -import * as browser from 'vs/base/browser/browser'; import { IStatusbarItem } from 'vs/workbench/browser/parts/statusbar/statusbar'; import { Action } from 'vs/base/common/actions'; import { language, LANGUAGE_DEFAULT, AccessibilitySupport } from 'vs/base/common/platform'; @@ -47,6 +46,7 @@ import { ITextFileService } from 'vs/workbench/services/textfile/common/textfile import { getCodeEditor as getEditorWidget } from 'vs/editor/common/services/codeEditorService'; import { IPreferencesService } from 'vs/workbench/parts/preferences/common/preferences'; import { ICursorPositionChangedEvent } from 'vs/editor/common/controller/cursorEvents'; +import { IConfigurationChangedEvent } from "vs/editor/common/config/editorOptions"; function toEditorWithEncodingSupport(input: IEditorInput): IEncodingSupport { if (input instanceof SideBySideEditorInput) { @@ -329,9 +329,7 @@ export class EditorStatus implements IStatusbarItem { this.untitledEditorService.onDidChangeEncoding(r => this.onResourceEncodingChange(r)), this.textFileService.models.onModelEncodingChanged(e => this.onResourceEncodingChange(e.resource)), TabFocus.onDidChangeTabFocus(e => this.onTabFocusModeChange()), - browser.onDidChangeAccessibilitySupport(() => this.onScreenReaderModeChange()) ); - this.onScreenReaderModeChange(); return combinedDisposable(this.toDispose); } @@ -492,6 +490,7 @@ export class EditorStatus implements IStatusbarItem { const control = getEditorWidget(activeEditor); // Update all states + this.onScreenReaderModeChange(control); this.onSelectionChange(control); this.onModeChange(control); this.onEOLChange(control); @@ -505,6 +504,13 @@ export class EditorStatus implements IStatusbarItem { // Attach new listeners to active editor if (control) { + // Hook Listener for Configuration changes + this.activeEditorListeners.push(control.onDidChangeConfiguration((event: IConfigurationChangedEvent) => { + if (event.accessibilitySupport) { + this.onScreenReaderModeChange(control); + } + })); + // Hook Listener for Selection changes this.activeEditorListeners.push(control.onDidChangeCursorPosition((event: ICursorPositionChangedEvent) => { this.onSelectionChange(control); @@ -595,6 +601,18 @@ export class EditorStatus implements IStatusbarItem { this.updateState(update); } + private onScreenReaderModeChange(editorWidget: ICommonCodeEditor): void { + let screenReaderMode = false; + + // We only support text based editors + if (editorWidget) { + + screenReaderMode = (editorWidget.getConfiguration().accessibilitySupport === AccessibilitySupport.Enabled); + } + + this.updateState({ screenReaderMode: screenReaderMode }); + } + private onSelectionChange(editorWidget: ICommonCodeEditor): void { const info: IEditorSelectionStatus = {}; @@ -685,12 +703,6 @@ export class EditorStatus implements IStatusbarItem { this.updateState(info); } - private onScreenReaderModeChange(): void { - const info: StateDelta = { screenReaderMode: browser.getAccessibilitySupport() === AccessibilitySupport.Enabled }; - - this.updateState(info); - } - private isActiveEditor(e: IBaseEditor): boolean { const activeEditor = this.editorService.getActiveEditor(); -- GitLab From f8c4c5e6f85b10b0c2c0b0f914246083164af979 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 2 Jun 2017 11:41:31 +0200 Subject: [PATCH 0498/1347] fix schema comment, #27090 --- .../parts/snippets/electron-browser/snippets.contribution.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.ts b/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.ts index 10a8b9e074d..2e69a2d456e 100644 --- a/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.ts +++ b/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.ts @@ -145,7 +145,7 @@ let schema: IJSONSchema = { 'type': 'string' }, 'body': { - 'description': nls.localize('snippetSchema.json.body', 'The snippet content. Use \'${id}\', \'${id:label}\', \'${1:label}\' for variables and \'$0\', \'$1\' for the cursor positions'), + 'description': nls.localize('snippetSchema.json.body', 'The snippet content. Use \'$1\', \'${1:defaultText}\' to define cursor positions, use \'$0\' for the final cursor position. Insert variable values with \'${varName}\' and \'${varName:defaultText}\', e.g \'This is file: $TM_FILENAME\'.'), 'type': ['string', 'array'], 'items': { 'type': 'string' -- GitLab From ec164303925616b0779e88b51f840989d0cfd6d9 Mon Sep 17 00:00:00 2001 From: isidor Date: Fri, 2 Jun 2017 11:52:22 +0200 Subject: [PATCH 0499/1347] fix brekpoint selection on click fixes #27835 --- src/vs/workbench/parts/debug/electron-browser/debugViewer.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts index fabffd9ca16..9653e86d58c 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts @@ -19,6 +19,7 @@ import { IActionItem, Separator } from 'vs/base/browser/ui/actionbar/actionbar'; import { ITree, IAccessibilityProvider, ContextMenuEvent, IDataSource, IRenderer, DRAG_OVER_REJECT, IDragAndDropData, IDragOverReaction, IActionProvider } from 'vs/base/parts/tree/browser/tree'; import { InputBox, IInputValidationOptions } from 'vs/base/browser/ui/inputbox/inputBox'; import { DefaultController, DefaultDragAndDrop, ClickBehavior } from 'vs/base/parts/tree/browser/treeDefaults'; +import { Constants } from 'vs/editor/common/core/uint'; import { IContextViewService, IContextMenuService } from 'vs/platform/contextview/browser/contextView'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; @@ -1272,7 +1273,9 @@ export class BreakpointsController extends BaseDebugController { endColumn: breakpoint.endColumn } : { startLineNumber: breakpoint.lineNumber, - startColumn: breakpoint.column || 1 + startColumn: breakpoint.column || 1, + endLineNumber: breakpoint.lineNumber, + endColumn: breakpoint.column || Constants.MAX_SAFE_SMALL_INTEGER }; this.editorService.openEditor({ -- GitLab From 2602410f20224bac2e72d84a6f2ca2f95e890aa7 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 2 Jun 2017 11:52:59 +0200 Subject: [PATCH 0500/1347] Guide the false-positive case towards the setting (#27893) --- src/vs/workbench/browser/parts/editor/editorStatus.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/browser/parts/editor/editorStatus.ts b/src/vs/workbench/browser/parts/editor/editorStatus.ts index d17d44c54d9..12cf4abfe2d 100644 --- a/src/vs/workbench/browser/parts/editor/editorStatus.ts +++ b/src/vs/workbench/browser/parts/editor/editorStatus.ts @@ -226,7 +226,8 @@ const nlsMultiSelection = nls.localize('multiSelection', "{0} selections"); const nlsEOLLF = nls.localize('endOfLineLineFeed', "LF"); const nlsEOLCRLF = nls.localize('endOfLineCarriageReturnLineFeed', "CRLF"); const nlsTabFocusMode = nls.localize('tabFocusModeEnabled', "Tab moves focus"); -const nlsScreenReaderDetected = nls.localize('screenReaderDetected', "Screen reader detected"); +const nlsScreenReaderDetected = nls.localize('screenReaderDetected', "Screen Reader detected"); +const nlsScreenReaderDetectedTitle = nls.localize('screenReaderDetectedExtra', "If you are not using a Screen Reader, please change the setting `editor.accessibilitySupport` to off."); function _setDisplay(el: HTMLElement, desiredValue: string): void { if (el.style.display !== desiredValue) { @@ -282,6 +283,7 @@ export class EditorStatus implements IStatusbarItem { this.screenRedearModeElement = append(this.element, $('a.editor-status-screenreadermode.status-bar-info')); this.screenRedearModeElement.textContent = nlsScreenReaderDetected; + this.screenRedearModeElement.title = nlsScreenReaderDetectedTitle; hide(this.screenRedearModeElement); this.selectionElement = append(this.element, $('a.editor-status-selection')); -- GitLab From 1d65268de82f24b9123acd1fa6074b0acf9cd748 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 2 Jun 2017 11:55:18 +0200 Subject: [PATCH 0501/1347] Improve tooltip (#27893) --- src/vs/workbench/browser/parts/editor/editorStatus.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/browser/parts/editor/editorStatus.ts b/src/vs/workbench/browser/parts/editor/editorStatus.ts index 12cf4abfe2d..ee9d12bbcd7 100644 --- a/src/vs/workbench/browser/parts/editor/editorStatus.ts +++ b/src/vs/workbench/browser/parts/editor/editorStatus.ts @@ -227,7 +227,7 @@ const nlsEOLLF = nls.localize('endOfLineLineFeed', "LF"); const nlsEOLCRLF = nls.localize('endOfLineCarriageReturnLineFeed', "CRLF"); const nlsTabFocusMode = nls.localize('tabFocusModeEnabled', "Tab moves focus"); const nlsScreenReaderDetected = nls.localize('screenReaderDetected', "Screen Reader detected"); -const nlsScreenReaderDetectedTitle = nls.localize('screenReaderDetectedExtra', "If you are not using a Screen Reader, please change the setting `editor.accessibilitySupport` to off."); +const nlsScreenReaderDetectedTitle = nls.localize('screenReaderDetectedExtra', "If you are not using a Screen Reader, please change the setting `editor.accessibilitySupport` to \"off\"."); function _setDisplay(el: HTMLElement, desiredValue: string): void { if (el.style.display !== desiredValue) { -- GitLab From 0aec2d6838b5e65cc74c33b853ffbd9fa191d636 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Fri, 2 Jun 2017 12:18:44 +0200 Subject: [PATCH 0502/1347] Fixed selector after eac49a321b84cb9828430e9dcd3f34243a3480f7 change. --- test/smoke/src/areas/git.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/smoke/src/areas/git.ts b/test/smoke/src/areas/git.ts index 58dcd1e9b3e..9a088d46566 100644 --- a/test/smoke/src/areas/git.ts +++ b/test/smoke/src/areas/git.ts @@ -65,6 +65,6 @@ export class Git { } public getOutgoingChanges(): Promise { - return this.spectron.client.getText('a[title="Synchronize changes"]'); + return this.spectron.client.getText('a[title="Synchronize Changes"]'); } } \ No newline at end of file -- GitLab From f977399d58f7b64db35047fafe0c6e59e15f11d5 Mon Sep 17 00:00:00 2001 From: isidor Date: Fri, 2 Jun 2017 12:28:44 +0200 Subject: [PATCH 0503/1347] fixes #27835 --- src/vs/workbench/parts/debug/electron-browser/debugViewer.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts index 9653e86d58c..caddb78c3d3 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts @@ -1257,6 +1257,7 @@ export class BreakpointsController extends BaseDebugController { return true; } if (element instanceof Breakpoint) { + super.onLeftClick(tree, element, event); this.openBreakpointSource(element, event, event.detail !== 2); return true; } -- GitLab From d4c79504607a17718671a41e88b559bbb5ec0bd0 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 2 Jun 2017 15:27:09 +0200 Subject: [PATCH 0504/1347] don't scan snippets-dir on startup, only re-scan files with changes, #27908 --- .../snippets/electron-browser/TMSnippets.ts | 6 + .../electron-browser/snippetsTracker.ts | 118 +++++------------- 2 files changed, 40 insertions(+), 84 deletions(-) diff --git a/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.ts b/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.ts index 899bc5a55d8..9098d608e88 100644 --- a/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.ts +++ b/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.ts @@ -94,6 +94,12 @@ export function readAndRegisterSnippets( return readFile(filePath).then(fileContents => { let snippets = parseSnippetFile(fileContents.toString(), extensionName, collector); snippetService.registerSnippets(languageIdentifier.id, snippets, filePath); + }, err => { + if (err && err.code === 'ENOENT') { + snippetService.registerSnippets(languageIdentifier.id, [], filePath); + } else { + throw err; + } }); } diff --git a/src/vs/workbench/parts/snippets/electron-browser/snippetsTracker.ts b/src/vs/workbench/parts/snippets/electron-browser/snippetsTracker.ts index e143e7258ae..2ecbc3150fb 100644 --- a/src/vs/workbench/parts/snippets/electron-browser/snippetsTracker.ts +++ b/src/vs/workbench/parts/snippets/electron-browser/snippetsTracker.ts @@ -5,114 +5,64 @@ 'use strict'; -import workbenchExt = require('vs/workbench/common/contributions'); +import { IWorkbenchContribution } from 'vs/workbench/common/contributions'; import { join } from 'path'; -import async = require('vs/base/common/async'); -import winjs = require('vs/base/common/winjs.base'); -import { mkdirp, fileExists, readdir } from 'vs/base/node/pfs'; +import { mkdirp, fileExists } from 'vs/base/node/pfs'; import { onUnexpectedError } from 'vs/base/common/errors'; -import lifecycle = require('vs/base/common/lifecycle'); +import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { readAndRegisterSnippets } from './TMSnippets'; import { ISnippetsService } from 'vs/workbench/parts/snippets/electron-browser/snippetsService'; -import { ILifecycleService } from 'vs/platform/lifecycle/common/lifecycle'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { IExtensionService } from 'vs/platform/extensions/common/extensions'; -import { watch, FSWatcher } from 'fs'; +import { watch } from 'fs'; import { IModeService } from 'vs/editor/common/services/modeService'; -export class SnippetsTracker implements workbenchExt.IWorkbenchContribution { - private static FILE_WATCH_DELAY = 200; +export class SnippetsTracker implements IWorkbenchContribution { - private snippetFolder: string; - private toDispose: lifecycle.IDisposable[]; - private watcher: FSWatcher; - private fileWatchDelayer: async.ThrottledDelayer; + private readonly _snippetFolder: string; + private readonly _toDispose: IDisposable[]; constructor( - @ILifecycleService private lifecycleService: ILifecycleService, - @IModeService private modeService: IModeService, - @ISnippetsService private snippetService: ISnippetsService, + @IModeService modeService: IModeService, + @ISnippetsService snippetService: ISnippetsService, @IEnvironmentService environmentService: IEnvironmentService, @IExtensionService extensionService: IExtensionService ) { - this.snippetFolder = join(environmentService.appSettingsHome, 'snippets'); + this._snippetFolder = join(environmentService.appSettingsHome, 'snippets'); + this._toDispose = []; - this.toDispose = []; - this.fileWatchDelayer = new async.ThrottledDelayer(SnippetsTracker.FILE_WATCH_DELAY); + // Whenever a mode is being created check if a snippet file exists + // and iff so read all snippets from it. + this._toDispose.push(modeService.onDidCreateMode(mode => { + const snippetPath = join(this._snippetFolder, `${mode.getId()}.json`); + fileExists(snippetPath) + .then(exists => exists && readAndRegisterSnippets(snippetService, mode.getLanguageIdentifier(), snippetPath)) + .done(undefined, onUnexpectedError); + })); - extensionService.onReady() - .then(() => mkdirp(this.snippetFolder)) - .then(() => this.scanUserSnippets()) - .then(() => this.registerListeners()) - .done(undefined, onUnexpectedError); - } - - private registerListeners(): void { - var scheduler = new async.RunOnceScheduler(() => { - this.scanUserSnippets(); - }, 500); - this.toDispose.push(scheduler); - - try { - this.watcher = watch(this.snippetFolder); // will be persistent but not recursive - this.watcher.on('change', (eventType: string) => { - if (eventType === 'delete') { - this.unregisterListener(); + // Install a FS watcher on the snippet directory and when an + // event occurs update the snippets for that one snippet. + mkdirp(this._snippetFolder).then(() => { + const watcher = watch(this._snippetFolder); + this._toDispose.push({ dispose: () => watcher.close() }); + watcher.on('change', (type, filename) => { + if (typeof filename !== 'string') { return; } - scheduler.schedule(); + extensionService.onReady().then(() => { + const langName = filename.replace(/\.json$/, '').toLowerCase(); + const langId = modeService.getLanguageIdentifier(langName); + return langId && readAndRegisterSnippets(snippetService, langId, join(this._snippetFolder, filename)); + }, onUnexpectedError); }); - } catch (error) { - // the path might not exist anymore, ignore this error and return - } - - this.lifecycleService.onShutdown(this.dispose, this); - } - - private scanUserSnippets(): winjs.Promise { - return readFilesInDir(this.snippetFolder, /\.json$/).then(snippetFiles => { - return winjs.TPromise.join(snippetFiles.map(snippetFile => { - var modeId = snippetFile.replace(/\.json$/, '').toLowerCase(); - var snippetPath = join(this.snippetFolder, snippetFile); - let languageIdentifier = this.modeService.getLanguageIdentifier(modeId); - if (languageIdentifier) { - return readAndRegisterSnippets(this.snippetService, languageIdentifier, snippetPath); - } - return undefined; - })); }); } - private unregisterListener(): void { - if (this.watcher) { - this.watcher.close(); - this.watcher = null; - } - } - - public getId(): string { + getId(): string { return 'vs.snippets.snippetsTracker'; } - public dispose(): void { - this.unregisterListener(); - this.toDispose = lifecycle.dispose(this.toDispose); + dispose(): void { + dispose(this._toDispose); } } - -function readFilesInDir(dirPath: string, namePattern: RegExp = null): winjs.TPromise { - return readdir(dirPath).then((children) => { - return winjs.TPromise.join( - children.map((child) => { - if (namePattern && !namePattern.test(child)) { - return winjs.TPromise.as(null); - } - return fileExists(join(dirPath, child)).then(isFile => { - return isFile ? child : null; - }); - }) - ).then((subdirs) => { - return subdirs.filter(subdir => (subdir !== null)); - }); - }); -} -- GitLab From e10bb6e4fbcc42765eef634234a41c4af4dd5c1b Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Fri, 2 Jun 2017 16:31:55 +0200 Subject: [PATCH 0505/1347] Bump to 1.14 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index f423138397b..333ee2253b6 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "code-oss-dev", - "version": "1.13.0", + "version": "1.14.0", "electronVersion": "1.6.6", "distro": "cb257c519d1ee526acfd00c0a7adc6b0fa4c18d2", "author": { -- GitLab From fcfdfd8b9050973a6f2c22975ef4f585bde0c776 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Fri, 2 Jun 2017 07:53:16 -0700 Subject: [PATCH 0506/1347] Configure automatic labelling of issues for insiders (#26223) --- .github/insiders.yml | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 .github/insiders.yml diff --git a/.github/insiders.yml b/.github/insiders.yml new file mode 100644 index 00000000000..28192b556e5 --- /dev/null +++ b/.github/insiders.yml @@ -0,0 +1,4 @@ +{ + insidersLabel: 'insiders', + perform: true +} \ No newline at end of file -- GitLab From c4081f0d07472090ececc14207e5c33d5dd511ae Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Thu, 1 Jun 2017 16:42:18 -0700 Subject: [PATCH 0507/1347] Continue tweaking tsc mismatch message --- extensions/typescript/src/features/bufferSyncSupport.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/typescript/src/features/bufferSyncSupport.ts b/extensions/typescript/src/features/bufferSyncSupport.ts index 90b989b77a4..9cdaf802b21 100644 --- a/extensions/typescript/src/features/bufferSyncSupport.ts +++ b/extensions/typescript/src/features/bufferSyncSupport.ts @@ -298,7 +298,7 @@ export default class BufferSyncSupport { } if (tscVersion && tscVersion !== this.client.apiVersion.versionString) { window.showInformationMessage( - localize('versionMismatch', 'Using TypeScript ({1}) for editor features. TypeScript ({0}) is installed globally on your machine. Inconsistent compile errors may occur', tscVersion, this.client.apiVersion.versionString), + localize('versionMismatch', 'Using TypeScript ({1}) for editor features. TypeScript ({0}) is installed globally on your machine. Errors in VS Code may differ from TSC errors', tscVersion, this.client.apiVersion.versionString), { title: localize('moreInformation', 'More Information'), id: 1 -- GitLab From fdbdf32717c4f73b3d5be48e13db6fa2473345ec Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Fri, 2 Jun 2017 13:37:01 -0700 Subject: [PATCH 0508/1347] Extract typescript service configuration to a class --- .../typescript/src/typescriptServiceClient.ts | 163 ++++++++++-------- 1 file changed, 88 insertions(+), 75 deletions(-) diff --git a/extensions/typescript/src/typescriptServiceClient.ts b/extensions/typescript/src/typescriptServiceClient.ts index d5e718bb34c..5dbe275c7ae 100644 --- a/extensions/typescript/src/typescriptServiceClient.ts +++ b/extensions/typescript/src/typescriptServiceClient.ts @@ -94,6 +94,68 @@ interface MyMessageItem extends MessageItem { id: MessageAction; } +class TypeScriptServiceConfiguration { + public readonly globalTsdk: string | null; + public readonly localTsdk: string | null; + public readonly npmLocation: string | null; + public readonly tsServerLogLevel: TsServerLogLevel = TsServerLogLevel.Off; + public readonly checkJs: boolean; + + public static loadFromWorkspace(): TypeScriptServiceConfiguration { + return new TypeScriptServiceConfiguration(); + } + + private constructor() { + const configuration = workspace.getConfiguration(); + + this.globalTsdk = TypeScriptServiceConfiguration.extractGlobalTsdk(configuration); + this.localTsdk = TypeScriptServiceConfiguration.extractLocalTsdk(configuration); + this.npmLocation = TypeScriptServiceConfiguration.readNpmLocation(configuration); + this.tsServerLogLevel = TypeScriptServiceConfiguration.readTsServerLogLevel(configuration); + this.checkJs = TypeScriptServiceConfiguration.readCheckJs(configuration); + } + + public isEqualTo(other: TypeScriptServiceConfiguration): boolean { + return this.globalTsdk === other.globalTsdk + && this.localTsdk === other.localTsdk + && this.npmLocation === other.npmLocation + && this.tsServerLogLevel === other.tsServerLogLevel + && this.checkJs === other.checkJs; + } + + private static extractGlobalTsdk(configuration: WorkspaceConfiguration): string | null { + let inspect = configuration.inspect('typescript.tsdk'); + if (inspect && inspect.globalValue && 'string' === typeof inspect.globalValue) { + return inspect.globalValue; + } + if (inspect && inspect.defaultValue && 'string' === typeof inspect.defaultValue) { + return inspect.defaultValue; + } + return null; + } + + private static extractLocalTsdk(configuration: WorkspaceConfiguration): string | null { + let inspect = configuration.inspect('typescript.tsdk'); + if (inspect && inspect.workspaceValue && 'string' === typeof inspect.workspaceValue) { + return inspect.workspaceValue; + } + return null; + } + + private static readTsServerLogLevel(configuration: WorkspaceConfiguration): TsServerLogLevel { + const setting = configuration.get('typescript.tsserver.log', 'off'); + return TsServerLogLevel.fromString(setting); + } + + private static readCheckJs(configuration: WorkspaceConfiguration): boolean { + return configuration.get('javascript.implicitProjectConfig.checkJs', false); + } + + private static readNpmLocation(configuration: WorkspaceConfiguration): string | null { + return configuration.get('typescript.npm', null); + } +} + export default class TypeScriptServiceClient implements ITypescriptServiceClient { private static useWorkspaceTsdkStorageKey = 'typescript.useWorkspaceTsdk'; private static tsdkMigratedStorageKey = 'typescript.tsdkMigrated'; @@ -108,15 +170,12 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient private modulePath: string | undefined; private _onReady: { promise: Promise; resolve: () => void; reject: () => void; }; - private globalTsdk: string | null; - private localTsdk: string | null; - private npmLocation: string | null; + private configuration: TypeScriptServiceConfiguration; private _checkGlobalTSCVersion: boolean; private _experimentalAutoBuild: boolean; private tracer: Tracer; private readonly logger: Logger = new Logger(); private tsServerLogFile: string | null = null; - private tsServerLogLevel: TsServerLogLevel = TsServerLogLevel.Off; private servicePromise: Thenable | null; private lastError: Error | null; private reader: Reader; @@ -136,7 +195,6 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient private _apiVersion: API; private telemetryReporter: TelemetryReporter; - private checkJs: boolean; constructor( host: ITypescriptServiceClientHost, @@ -168,42 +226,27 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient this.requestQueue = []; this.pendingResponses = 0; this.callbacks = Object.create(null); - const configuration = workspace.getConfiguration(); - this.globalTsdk = this.extractGlobalTsdk(configuration); - this.localTsdk = this.extractLocalTsdk(configuration); - this.npmLocation = configuration.get('typescript.npm', null); + this.configuration = TypeScriptServiceConfiguration.loadFromWorkspace(); this._experimentalAutoBuild = false; // configuration.get('typescript.tsserver.experimentalAutoBuild', false); this._apiVersion = new API('1.0.0'); this._checkGlobalTSCVersion = true; this.tracer = new Tracer(this.logger); - this.tsServerLogLevel = this.readTsServerLogLevel(); - this.checkJs = this.readCheckJs(); disposables.push(workspace.onDidChangeConfiguration(() => { - let oldLoggingLevel = this.tsServerLogLevel; - let oldglobalTsdk = this.globalTsdk; - let oldLocalTsdk = this.localTsdk; - let oldCheckJs = this.checkJs; - const oldNpmLocation = this.npmLocation; + const oldConfiguration = this.configuration; + this.configuration = TypeScriptServiceConfiguration.loadFromWorkspace(); this.tracer.updateConfiguration(); - this.tsServerLogLevel = this.readTsServerLogLevel(); - - const configuration = workspace.getConfiguration(); - this.globalTsdk = this.extractGlobalTsdk(configuration); - this.localTsdk = this.extractLocalTsdk(configuration); - this.checkJs = this.readCheckJs(); - this.npmLocation = configuration.get('typescript.npm', null); - if (this.servicePromise && oldCheckJs !== this.checkJs) { - this.setCompilerOptionsForInferredProjects(); - } + if (this.servicePromise) { + if (this.configuration.checkJs !== oldConfiguration.checkJs) { + this.setCompilerOptionsForInferredProjects(); + } - if (this.servicePromise === null && (oldglobalTsdk !== this.globalTsdk || oldLocalTsdk !== this.localTsdk)) { - this.startService(); - } else if (this.servicePromise !== null && (this.tsServerLogLevel !== oldLoggingLevel || oldglobalTsdk !== this.globalTsdk || oldLocalTsdk !== this.localTsdk || oldNpmLocation !== this.npmLocation)) { - this.restartTsServer(); + if (!this.configuration.isEqualTo(oldConfiguration)) { + this.restartTsServer(); + } } })); this.telemetryReporter = new TelemetryReporter(); @@ -213,12 +256,11 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient public restartTsServer(): void { const start = () => { - this.tsServerLogLevel = this.readTsServerLogLevel(); this.servicePromise = this.startService(); return this.servicePromise; }; - if (this.servicePromise !== null) { + if (this.servicePromise) { this.servicePromise = this.servicePromise.then(cp => { if (cp) { cp.kill(); @@ -229,26 +271,6 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient } } - - private extractGlobalTsdk(configuration: WorkspaceConfiguration): string | null { - let inspect = configuration.inspect('typescript.tsdk'); - if (inspect && inspect.globalValue && 'string' === typeof inspect.globalValue) { - return inspect.globalValue; - } - if (inspect && inspect.defaultValue && 'string' === typeof inspect.defaultValue) { - return inspect.defaultValue; - } - return null; - } - - private extractLocalTsdk(configuration: WorkspaceConfiguration): string | null { - let inspect = configuration.inspect('typescript.tsdk'); - if (inspect && inspect.workspaceValue && 'string' === typeof inspect.workspaceValue) { - return inspect.workspaceValue; - } - return null; - } - get onProjectLanguageServiceStateChanged(): Event { return this._onProjectLanguageServiceStateChanged.event; } @@ -265,15 +287,6 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient return this._onTypesInstallerInitializationFailed.event; } - private readTsServerLogLevel(): TsServerLogLevel { - const setting = workspace.getConfiguration().get('typescript.tsserver.log', 'off'); - return TsServerLogLevel.fromString(setting); - } - - private readCheckJs(): boolean { - return workspace.getConfiguration().get('javascript.implicitProjectConfig.checkJs', false); - } - public get experimentalAutoBuild(): boolean { return this._experimentalAutoBuild; } @@ -333,12 +346,12 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient return null; } - if (this.localTsdk) { + if (this.configuration.localTsdk) { this._checkGlobalTSCVersion = false; - if ((path).isAbsolute(this.localTsdk)) { - return path.join(this.localTsdk, 'tsserver.js'); + if ((path).isAbsolute(this.configuration.localTsdk)) { + return path.join(this.configuration.localTsdk, 'tsserver.js'); } - return path.join(workspace.rootPath, this.localTsdk, 'tsserver.js'); + return path.join(workspace.rootPath, this.configuration.localTsdk, 'tsserver.js'); } const localModulePath = path.join(workspace.rootPath, 'node_modules', 'typescript', 'lib', 'tsserver.js'); @@ -349,12 +362,12 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient } private get globalTypescriptPath(): string { - if (this.globalTsdk) { + if (this.configuration.globalTsdk) { this._checkGlobalTSCVersion = false; - if ((path).isAbsolute(this.globalTsdk)) { - return path.join(this.globalTsdk, 'tsserver.js'); + if ((path).isAbsolute(this.configuration.globalTsdk)) { + return path.join(this.configuration.globalTsdk, 'tsserver.js'); } else if (workspace.rootPath) { - return path.join(workspace.rootPath, this.globalTsdk, 'tsserver.js'); + return path.join(workspace.rootPath, this.configuration.globalTsdk, 'tsserver.js'); } } @@ -362,7 +375,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient } private hasWorkspaceTsdkSetting(): boolean { - return !!this.localTsdk; + return !!this.configuration.localTsdk; } private startService(resendModels: boolean = false): Thenable { @@ -457,7 +470,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient } if (this.apiVersion.has222Features()) { - if (this.tsServerLogLevel !== TsServerLogLevel.Off) { + if (this.configuration.tsServerLogLevel !== TsServerLogLevel.Off) { try { const logDir = fs.mkdtempSync(path.join(os.tmpdir(), `vscode-tsserver-log-`)); this.tsServerLogFile = path.join(logDir, `tsserver.log`); @@ -467,7 +480,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient } if (this.tsServerLogFile) { - args.push('--logVerbosity', TsServerLogLevel.toString(this.tsServerLogLevel)); + args.push('--logVerbosity', TsServerLogLevel.toString(this.configuration.tsServerLogLevel)); args.push('--logFile', this.tsServerLogFile); } } @@ -483,8 +496,8 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient } if (this.apiVersion.has234Features()) { - if (this.npmLocation) { - args.push('--npmLocation', `"${this.npmLocation}"`); + if (this.configuration.npmLocation) { + args.push('--npmLocation', `"${this.configuration.npmLocation}"`); } } @@ -649,7 +662,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient .then(() => false); } - if (this.tsServerLogLevel === TsServerLogLevel.Off) { + if (this.configuration.tsServerLogLevel === TsServerLogLevel.Off) { return window.showErrorMessage( localize( 'typescript.openTsServerLog.loggingNotEnabled', -- GitLab From a88d97d63edef71f5a574616a5c045839e25f4ca Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Fri, 2 Jun 2017 14:23:48 -0700 Subject: [PATCH 0509/1347] Title case (#27569) --- extensions/merge-conflict/src/mergeDecorator.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/extensions/merge-conflict/src/mergeDecorator.ts b/extensions/merge-conflict/src/mergeDecorator.ts index d30863eca9a..f988eef1fed 100644 --- a/extensions/merge-conflict/src/mergeDecorator.ts +++ b/extensions/merge-conflict/src/mergeDecorator.ts @@ -84,7 +84,7 @@ export default class MergeDectorator implements vscode.Disposable { outlineWidth: '1pt', outlineColor: new vscode.ThemeColor('merge.border'), after: { - contentText: ' ' + localize('currentChange', '(Current change)'), + contentText: ' ' + localize('currentChange', '(Current Change)'), color: new vscode.ThemeColor('descriptionForeground') } }); @@ -105,7 +105,7 @@ export default class MergeDectorator implements vscode.Disposable { outlineColor: new vscode.ThemeColor('merge.border'), isWholeLine: this.decorationUsesWholeLine, after: { - contentText: ' ' + localize('incomingChange', '(Incoming change)'), + contentText: ' ' + localize('incomingChange', '(Incoming Change)'), color: new vscode.ThemeColor('descriptionForeground') } }); -- GitLab From 6a01ff4870d45ecec8ada0f8e48dc24fcbc0b1b0 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Fri, 2 Jun 2017 14:14:10 -0700 Subject: [PATCH 0510/1347] Remove old tscheck migration logic --- extensions/typescript/src/typescriptMain.ts | 5 ++-- .../typescript/src/typescriptServiceClient.ts | 25 +++---------------- 2 files changed, 5 insertions(+), 25 deletions(-) diff --git a/extensions/typescript/src/typescriptMain.ts b/extensions/typescript/src/typescriptMain.ts index 3938f9888f2..197cff2b6ef 100644 --- a/extensions/typescript/src/typescriptMain.ts +++ b/extensions/typescript/src/typescriptMain.ts @@ -94,7 +94,7 @@ export function activate(context: ExtensionContext): void { let clientHost: TypeScriptServiceClientHost | undefined; return () => { if (!clientHost) { - clientHost = new TypeScriptServiceClientHost(standardLanguageDescriptions, context.storagePath, context.globalState, context.workspaceState, plugins); + clientHost = new TypeScriptServiceClientHost(standardLanguageDescriptions, context.storagePath, context.workspaceState, plugins); context.subscriptions.push(clientHost); const host = clientHost; @@ -457,7 +457,6 @@ class TypeScriptServiceClientHost implements ITypescriptServiceClientHost { constructor( descriptions: LanguageDescription[], storagePath: string | undefined, - globalState: Memento, workspaceState: Memento, plugins: TypeScriptServerPlugin[] ) { @@ -479,7 +478,7 @@ class TypeScriptServiceClientHost implements ITypescriptServiceClientHost { this.versionStatus = new VersionStatus(); this.disposables.push(this.versionStatus); - this.client = new TypeScriptServiceClient(this, storagePath, globalState, workspaceState, this.versionStatus, plugins, this.disposables); + this.client = new TypeScriptServiceClient(this, storagePath, workspaceState, this.versionStatus, plugins, this.disposables); this.languagePerId = Object.create(null); for (const description of descriptions) { const manager = new LanguageProvider(this.client, description); diff --git a/extensions/typescript/src/typescriptServiceClient.ts b/extensions/typescript/src/typescriptServiceClient.ts index 5dbe275c7ae..84f35f4f11c 100644 --- a/extensions/typescript/src/typescriptServiceClient.ts +++ b/extensions/typescript/src/typescriptServiceClient.ts @@ -163,9 +163,6 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient private static readonly WALK_THROUGH_SNIPPET_SCHEME = 'walkThroughSnippet'; private static readonly WALK_THROUGH_SNIPPET_SCHEME_COLON = `${TypeScriptServiceClient.WALK_THROUGH_SNIPPET_SCHEME}:`; - private host: ITypescriptServiceClientHost; - private storagePath: string | undefined; - private globalState: Memento; private pathSeparator: string; private modulePath: string | undefined; @@ -197,18 +194,13 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient private telemetryReporter: TelemetryReporter; constructor( - host: ITypescriptServiceClientHost, - storagePath: string | undefined, - globalState: Memento, + private readonly host: ITypescriptServiceClientHost, + private readonly storagePath: string | undefined, private readonly workspaceState: Memento, private readonly versionStatus: VersionStatus, - - private plugins: TypeScriptServerPlugin[], + private readonly plugins: TypeScriptServerPlugin[], disposables: Disposable[] ) { - this.host = host; - this.storagePath = storagePath; - this.globalState = globalState; this.pathSeparator = path.sep; this.lastStart = Date.now(); @@ -400,8 +392,6 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient return this.getDebugPort().then(debugPort => ({ modulePath, debugPort })); }).then(({ modulePath, debugPort }) => { return this.servicePromise = new Promise((resolve, reject) => { - const tsConfig = workspace.getConfiguration('typescript'); - this.info(`Using tsserver from: ${modulePath}`); if (!fs.existsSync(modulePath)) { window.showWarningMessage(localize('noServerFound', 'The path {0} doesn\'t point to a valid tsserver install. Falling back to bundled TypeScript version.', modulePath ? path.dirname(modulePath) : '')); @@ -426,15 +416,6 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient this.versionStatus.showHideStatus(); this.versionStatus.setInfo(label, tooltip); - // This is backwards compatibility code to move the setting from the local - // store into the workspace setting file. - const doGlobalVersionCheckKey: string = 'doGlobalVersionCheck'; - const globalStateValue = this.globalState.get(doGlobalVersionCheckKey, true); - const checkTscVersion = 'check.tscVersion'; - if (!globalStateValue) { - tsConfig.update(checkTscVersion, false, true); - this.globalState.update(doGlobalVersionCheckKey, true); - } this.sequenceNumber = 0; this.requestQueue = []; -- GitLab From fcd65cc862bed7bddfc43f24f938ff62406e9cd4 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Fri, 2 Jun 2017 14:33:24 -0700 Subject: [PATCH 0511/1347] Ensure terminal pty is ready before sendText is called Fixes #27939 --- .../electron-browser/terminalInstance.ts | 23 +++++++++++++------ 1 file changed, 16 insertions(+), 7 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index bb4237e7aad..4b70c062ba8 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -31,6 +31,7 @@ import { TerminalLinkHandler } from 'vs/workbench/parts/terminal/electron-browse import { TerminalWidgetManager } from 'vs/workbench/parts/terminal/browser/terminalWidgetManager'; import { registerThemingParticipant, ITheme, ICssStyleCollector } from 'vs/platform/theme/common/themeService'; import { scrollbarSliderBackground, scrollbarSliderHoverBackground, scrollbarSliderActiveBackground } from 'vs/platform/theme/common/colorRegistry'; +import { TPromise } from "vs/base/common/winjs.base"; /** The amount of time to consider terminal errors to be related to the launch */ const LAUNCHING_DURATION = 500; @@ -56,6 +57,7 @@ export class TerminalInstance implements ITerminalInstance { private _hadFocusOnExit: boolean; private _isLaunching: boolean; private _isVisible: boolean; + private _processReady: TPromise; private _isDisposed: boolean; private _onDisposed: Emitter; private _onDataForApi: Emitter<{ instance: ITerminalInstance, data: string }>; @@ -115,6 +117,11 @@ export class TerminalInstance implements ITerminalInstance { this._onProcessIdReady = new Emitter(); this._onTitleChanged = new Emitter(); + // Create a promise that resolves when the pty is ready + this._processReady = new TPromise(c => { + this.onProcessIdReady(() => c(void 0)); + }); + this._initDimensions(); this._createProcess(this._contextService.getWorkspace(), this._shellLaunchConfig); this._createXterm(); @@ -376,13 +383,15 @@ export class TerminalInstance implements ITerminalInstance { } public sendText(text: string, addNewLine: boolean): void { - text = this._sanitizeInput(text); - if (addNewLine && text.substr(text.length - 1) !== '\r') { - text += '\r'; - } - this._process.send({ - event: 'input', - data: text + this._processReady.then(() => { + text = this._sanitizeInput(text); + if (addNewLine && text.substr(text.length - 1) !== '\r') { + text += '\r'; + } + this._process.send({ + event: 'input', + data: text + }); }); } -- GitLab From 6e8b0229b874a1b0a426522e9650ba1d9a8baaf8 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Fri, 2 Jun 2017 14:44:44 -0700 Subject: [PATCH 0512/1347] Enforce a minimum for markdown.preview.fontSize Fixes #27797 --- extensions/markdown/src/previewContentProvider.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/extensions/markdown/src/previewContentProvider.ts b/extensions/markdown/src/previewContentProvider.ts index caacead613e..44531e5b62e 100644 --- a/extensions/markdown/src/previewContentProvider.ts +++ b/extensions/markdown/src/previewContentProvider.ts @@ -76,8 +76,8 @@ class MarkdownPreviewConfig { this.markEditorSelection = !!markdownConfig.get('preview.markEditorSelection', true); this.fontFamily = markdownConfig.get('preview.fontFamily', undefined); - this.fontSize = +markdownConfig.get('preview.fontSize', NaN); - this.lineHeight = +markdownConfig.get('preview.lineHeight', NaN); + this.fontSize = Math.max(8, +markdownConfig.get('preview.fontSize', NaN)); + this.lineHeight = Math.max(0.6, +markdownConfig.get('preview.lineHeight', NaN)); this.styles = markdownConfig.get('styles', []); } @@ -176,8 +176,8 @@ export class MDDocumentContentProvider implements vscode.TextDocumentContentProv return ``; } -- GitLab From c353e6e9b09727ce112bfdced4669a3fd4c184da Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Fri, 2 Jun 2017 14:53:10 -0700 Subject: [PATCH 0513/1347] Fix configure ts/jsconfig.json inserting duplicate snippet for unsaved file. Fixes #27793 --- extensions/typescript/src/typescriptMain.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/extensions/typescript/src/typescriptMain.ts b/extensions/typescript/src/typescriptMain.ts index 197cff2b6ef..e217aa00400 100644 --- a/extensions/typescript/src/typescriptMain.ts +++ b/extensions/typescript/src/typescriptMain.ts @@ -593,7 +593,13 @@ class TypeScriptServiceClientHost implements ITypescriptServiceClientHost { }, _ => { return workspace.openTextDocument(configFile.with({ scheme: 'untitled' })) .then(doc => window.showTextDocument(doc, col)) - .then(editor => editor.insertSnippet(new SnippetString('{\n\t$0\n}'))); + .then(editor => { + if (editor.document.getText().length === 0) { + return editor.insertSnippet(new SnippetString('{\n\t$0\n}')) + .then(_ => editor); + } + return editor; + }); }); case ProjectConfigAction.LearnMore: -- GitLab From 0d01d06096ebe77567a2db57feca822e5ac196d0 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Fri, 2 Jun 2017 15:28:40 -0700 Subject: [PATCH 0514/1347] Fixes #27956 --- src/vs/editor/contrib/suggest/browser/suggestWidget.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index 7bec683cacf..f12fe31c393 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -932,6 +932,7 @@ export class SuggestWidget implements IContentWidget, IDelegate } private adjustDocsPosition() { + const lineHeight = this.editor.getConfiguration().fontInfo.lineHeight; const cursorCoords = this.editor.getScrolledVisiblePosition(this.editor.getPosition()); const editorCoords = getDomNodePagePosition(this.editor.getDomNode()); const cursorX = editorCoords.left + cursorCoords.left; @@ -946,8 +947,11 @@ export class SuggestWidget implements IContentWidget, IDelegate removeClass(this.element, 'list-right'); } + // Compare top of the cursor (cursorY - lineheight) with widgetTop to determine if + // margin-top needs to be applied on list to make it appear right above the cursor + // Cannot compare cursorY directly as it may be a few decimals off due to zoooming if (hasClass(this.element, 'docs-side') - && cursorY > widgetY + && cursorY - lineHeight > widgetY && this.details.element.offsetHeight > this.listElement.offsetHeight) { // Fix for #26416 -- GitLab From 85e31cfacb2b8228da1c66877dc39e60b0ab3d99 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Fri, 2 Jun 2017 17:39:35 -0700 Subject: [PATCH 0515/1347] Set maxheight on docs dynamically #27954 --- .../contrib/suggest/browser/media/suggest.css | 1 - .../contrib/suggest/browser/suggestWidget.ts | 15 ++++++--------- 2 files changed, 6 insertions(+), 10 deletions(-) diff --git a/src/vs/editor/contrib/suggest/browser/media/suggest.css b/src/vs/editor/contrib/suggest/browser/media/suggest.css index 0fc6559fdf1..a154e7c1959 100644 --- a/src/vs/editor/contrib/suggest/browser/media/suggest.css +++ b/src/vs/editor/contrib/suggest/browser/media/suggest.css @@ -210,7 +210,6 @@ /** Styles for the docs of the completion item in focus **/ .monaco-editor .suggest-widget .details { - max-height: 216px; display: flex; flex-direction: column; cursor: default; diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index f12fe31c393..1c7a97e314b 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -34,6 +34,7 @@ import { IStorageService, StorageScope } from 'vs/platform/storage/common/storag const sticky = false; // for development purposes const expandSuggestionDocsByDefault = false; +const maxSuggestionsToShow = 12; interface ISuggestionTemplateData { root: HTMLElement; @@ -852,6 +853,7 @@ export class SuggestWidget implements IContentWidget, IDelegate show(this.details.element); this.renderDetails(); + this.details.element.style.maxHeight = this.maxWidgetHeight + 'px'; // Reset margin-top that was set as Fix for #26416 this.listElement.style.marginTop = '0px'; @@ -909,17 +911,12 @@ export class SuggestWidget implements IContentWidget, IDelegate private updateListHeight(): number { let height = 0; - let maxSuggestionsToShow = 11; if (this.state === State.Empty || this.state === State.Loading) { height = this.unfocusedHeight; } else { - const focus = this.list.getFocusedElements()[0]; - const focusHeight = focus ? this.getHeight(focus) : this.unfocusedHeight; - height = focusHeight; - - const suggestionCount = (this.list.contentHeight - focusHeight) / this.unfocusedHeight; - height += Math.min(suggestionCount, maxSuggestionsToShow) * this.unfocusedHeight; + const suggestionCount = this.list.contentHeight / this.unfocusedHeight; + height = Math.min(suggestionCount, maxSuggestionsToShow) * this.unfocusedHeight; } this.element.style.lineHeight = `${this.unfocusedHeight}px`; @@ -981,8 +978,8 @@ export class SuggestWidget implements IContentWidget, IDelegate // Heights - private get focusHeight(): number { - return this.unfocusedHeight * 2; + private get maxWidgetHeight(): number { + return this.unfocusedHeight * maxSuggestionsToShow; } private get unfocusedHeight(): number { -- GitLab From f05594583bd8aca277d2f9b50658edf1314916d3 Mon Sep 17 00:00:00 2001 From: Chun Hei Ernest Wong Date: Sat, 3 Jun 2017 22:35:16 -0700 Subject: [PATCH 0516/1347] Added editor.urlClickable setting to enable/disable clickable URL --- src/vs/editor/common/config/commonEditorConfig.ts | 5 +++++ src/vs/editor/common/config/editorOptions.ts | 15 ++++++++++++++- src/vs/editor/contrib/links/browser/links.ts | 2 +- src/vs/monaco.d.ts | 6 ++++++ 4 files changed, 26 insertions(+), 2 deletions(-) diff --git a/src/vs/editor/common/config/commonEditorConfig.ts b/src/vs/editor/common/config/commonEditorConfig.ts index 2d54be1a832..7fddb2add18 100644 --- a/src/vs/editor/common/config/commonEditorConfig.ts +++ b/src/vs/editor/common/config/commonEditorConfig.ts @@ -562,6 +562,11 @@ const editorConfiguration: IConfigurationNode = { 'default': EDITOR_DEFAULTS.accessibilitySupport, 'description': nls.localize('accessibilitySupport', "Controls whether the editor should run in a mode where it is optimized for screen readers.") }, + 'editor.urlClickable': { + 'type': 'boolean', + 'default': EDITOR_DEFAULTS.urlClickable, + 'description': nls.localize('urlClickable', "Controls whether the editor should underline any URL and make them clickable through CTRL-Left Click") + }, 'diffEditor.renderSideBySide': { 'type': 'boolean', 'default': true, diff --git a/src/vs/editor/common/config/editorOptions.ts b/src/vs/editor/common/config/editorOptions.ts index 2daf0ddac8f..08009bb9b47 100644 --- a/src/vs/editor/common/config/editorOptions.ts +++ b/src/vs/editor/common/config/editorOptions.ts @@ -341,6 +341,11 @@ export interface IEditorOptions { * Defaults to 'auto'. It is best to leave this to 'auto'. */ accessibilitySupport?: 'auto' | 'off' | 'on'; + /** + * Enable underlining URL and make it as a clickable link through CTRL-click + * Defaults to true. + */ + urlClickable?: boolean; /** * Enable quick suggestions (shadow suggestions) * Defaults to true. @@ -795,6 +800,7 @@ export interface IValidatedEditorOptions { readonly useTabStops: boolean; readonly multiCursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; readonly accessibilitySupport: 'auto' | 'off' | 'on'; + readonly urlClickable: boolean; readonly viewInfo: InternalEditorViewOptions; readonly contribInfo: EditorContribOptions; @@ -816,6 +822,7 @@ export class InternalEditorOptions { */ readonly accessibilitySupport: platform.AccessibilitySupport; readonly multiCursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; + readonly urlClickable: boolean; // ---- cursor options readonly wordSeparators: string; @@ -854,6 +861,7 @@ export class InternalEditorOptions { viewInfo: InternalEditorViewOptions; wrappingInfo: EditorWrappingInfo; contribInfo: EditorContribOptions; + urlClickable: boolean; }) { this.canUseTranslate3d = source.canUseTranslate3d; this.pixelRatio = source.pixelRatio; @@ -873,6 +881,7 @@ export class InternalEditorOptions { this.viewInfo = source.viewInfo; this.wrappingInfo = source.wrappingInfo; this.contribInfo = source.contribInfo; + this.urlClickable = source.urlClickable; } /** @@ -1436,6 +1445,7 @@ export class EditorOptionsValidator { useTabStops: _boolean(opts.useTabStops, defaults.useTabStops), multiCursorModifier: multiCursorModifier, accessibilitySupport: _stringSet<'auto' | 'on' | 'off'>(opts.accessibilitySupport, defaults.accessibilitySupport, ['auto', 'on', 'off']), + urlClickable: _boolean(opts.urlClickable, defaults.urlClickable), viewInfo: viewInfo, contribInfo: contribInfo, }; @@ -1659,6 +1669,7 @@ export class InternalEditorOptionsFactory { useTabStops: opts.useTabStops, multiCursorModifier: opts.multiCursorModifier, accessibilitySupport: opts.accessibilitySupport, + urlClickable: opts.urlClickable, viewInfo: { extraEditorClassName: opts.viewInfo.extraEditorClassName, @@ -1866,7 +1877,8 @@ export class InternalEditorOptionsFactory { fontInfo: env.fontInfo, viewInfo: opts.viewInfo, wrappingInfo: wrappingInfo, - contribInfo: opts.contribInfo + contribInfo: opts.contribInfo, + urlClickable: opts.urlClickable }); } } @@ -2076,6 +2088,7 @@ export const EDITOR_DEFAULTS: IValidatedEditorOptions = { useTabStops: true, multiCursorModifier: 'altKey', accessibilitySupport: 'auto', + urlClickable: true, viewInfo: { extraEditorClassName: '', diff --git a/src/vs/editor/contrib/links/browser/links.ts b/src/vs/editor/contrib/links/browser/links.ts index c50fc2e0c43..1f6e93fb08e 100644 --- a/src/vs/editor/contrib/links/browser/links.ts +++ b/src/vs/editor/contrib/links/browser/links.ts @@ -184,7 +184,7 @@ class LinkDetector implements editorCommon.IEditorContribution { } private beginCompute(): void { - if (!this.editor.getModel()) { + if (!this.editor.getModel() || !this.editor.getConfiguration().urlClickable) { return; } diff --git a/src/vs/monaco.d.ts b/src/vs/monaco.d.ts index 3fad661a07f..3c10f80eb64 100644 --- a/src/vs/monaco.d.ts +++ b/src/vs/monaco.d.ts @@ -2887,6 +2887,11 @@ declare module monaco.editor { * Defaults to 'auto'. It is best to leave this to 'auto'. */ accessibilitySupport?: 'auto' | 'off' | 'on'; + /** + * Enable underlining URL and make it as a clickable link through CTRL-click + * Defaults to true. + */ + urlClickable?: boolean; /** * Enable quick suggestions (shadow suggestions) * Defaults to true. @@ -3269,6 +3274,7 @@ declare module monaco.editor { readonly lineHeight: number; readonly readOnly: boolean; readonly multiCursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; + readonly urlClickable: boolean; readonly wordSeparators: string; readonly autoClosingBrackets: boolean; readonly useTabStops: boolean; -- GitLab From a1c051a4de6770c99fa77195b3d37dfaa7f72878 Mon Sep 17 00:00:00 2001 From: Chun Hei Ernest Wong Date: Sun, 4 Jun 2017 09:19:21 -0700 Subject: [PATCH 0517/1347] Added urlClickable in equals and createChangeEvent --- src/vs/editor/common/config/editorOptions.ts | 3 +++ src/vs/monaco.d.ts | 1 + 2 files changed, 4 insertions(+) diff --git a/src/vs/editor/common/config/editorOptions.ts b/src/vs/editor/common/config/editorOptions.ts index 08009bb9b47..e2f0285cfd4 100644 --- a/src/vs/editor/common/config/editorOptions.ts +++ b/src/vs/editor/common/config/editorOptions.ts @@ -902,6 +902,7 @@ export class InternalEditorOptions { && this.tabFocusMode === other.tabFocusMode && this.dragAndDrop === other.dragAndDrop && this.emptySelectionClipboard === other.emptySelectionClipboard + && this.urlClickable === other.urlClickable && InternalEditorOptions._equalsLayoutInfo(this.layoutInfo, other.layoutInfo) && this.fontInfo.equals(other.fontInfo) && InternalEditorOptions._equalsViewOptions(this.viewInfo, other.viewInfo) @@ -933,6 +934,7 @@ export class InternalEditorOptions { viewInfo: (!InternalEditorOptions._equalsViewOptions(this.viewInfo, newOpts.viewInfo)), wrappingInfo: (!InternalEditorOptions._equalsWrappingInfo(this.wrappingInfo, newOpts.wrappingInfo)), contribInfo: (!InternalEditorOptions._equalsContribOptions(this.contribInfo, newOpts.contribInfo)), + urlClickable: (this.urlClickable !== newOpts.urlClickable), }; } @@ -1271,6 +1273,7 @@ export interface IConfigurationChangedEvent { readonly viewInfo: boolean; readonly wrappingInfo: boolean; readonly contribInfo: boolean; + readonly urlClickable: boolean; } /** diff --git a/src/vs/monaco.d.ts b/src/vs/monaco.d.ts index 3c10f80eb64..2670e27c2e6 100644 --- a/src/vs/monaco.d.ts +++ b/src/vs/monaco.d.ts @@ -3418,6 +3418,7 @@ declare module monaco.editor { readonly viewInfo: boolean; readonly wrappingInfo: boolean; readonly contribInfo: boolean; + readonly urlClickable: boolean; } /** -- GitLab From acfc6b6ece64cb1d631a2460e68f57d9d68e352a Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Sun, 4 Jun 2017 17:49:32 -0700 Subject: [PATCH 0518/1347] Skip unnecessary |s in extension list for #27987 --- src/vs/workbench/electron-browser/actions.ts | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/vs/workbench/electron-browser/actions.ts b/src/vs/workbench/electron-browser/actions.ts index 98e0d84f20c..552d57bc81f 100644 --- a/src/vs/workbench/electron-browser/actions.ts +++ b/src/vs/workbench/electron-browser/actions.ts @@ -725,15 +725,16 @@ Steps to Reproduce: return 'none'; } - let tableHeader = `|Extension|Author|Version| -|---|---|---|`; + let tableHeader = `Extension|Author|Version +---|---|---`; const table = extensions.map(e => { - return `|${e.manifest.name}|${e.manifest.publisher}|${e.manifest.version}|`; + return `${e.manifest.name}|${e.manifest.publisher}|${e.manifest.version}`; }).join('\n'); const extensionTable = ` -${tableHeader}\n${table}; +${tableHeader} +${table} `; // 2000 chars is browsers de-facto limit for URLs, 400 chars are allowed for other string parts of the issue URL -- GitLab From 2e618308bfc8181936325903e745af3a6d0070c1 Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Sun, 4 Jun 2017 18:18:32 -0700 Subject: [PATCH 0519/1347] Exclude extensions that only contribute themes from the extension list - #27987 --- src/vs/workbench/electron-browser/actions.ts | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/electron-browser/actions.ts b/src/vs/workbench/electron-browser/actions.ts index 552d57bc81f..2d900b8c8f4 100644 --- a/src/vs/workbench/electron-browser/actions.ts +++ b/src/vs/workbench/electron-browser/actions.ts @@ -6,6 +6,7 @@ 'use strict'; import URI from 'vs/base/common/uri'; +import * as collections from 'vs/base/common/collections'; import { TPromise } from 'vs/base/common/winjs.base'; import { Action } from 'vs/base/common/actions'; import { IWindowIPCService } from 'vs/workbench/services/window/electron-browser/windowService'; @@ -721,8 +722,17 @@ Steps to Reproduce: } private generateExtensionTable(extensions: ILocalExtension[]): string { + const { nonThemes, themes } = collections.groupBy(extensions, ext => { + const manifestKeys = ext.manifest.contributes ? Object.keys(ext.manifest.contributes) : []; + const onlyTheme = !ext.manifest.activationEvents && manifestKeys.length === 1 && manifestKeys[0] === 'themes'; + return onlyTheme ? 'themes' : 'nonThemes'; + }); + + const themeExclusionStr = themes.length ? `\n(${themes.length} theme extensions excluded)` : ''; + extensions = nonThemes; + if (!extensions.length) { - return 'none'; + return 'none' + themeExclusionStr; } let tableHeader = `Extension|Author|Version @@ -735,8 +745,10 @@ Steps to Reproduce: ${tableHeader} ${table} +${themeExclusionStr} `; + // 2000 chars is browsers de-facto limit for URLs, 400 chars are allowed for other string parts of the issue URL // http://stackoverflow.com/questions/417142/what-is-the-maximum-length-of-a-url-in-different-browsers if (encodeURIComponent(extensionTable).length > 1600) { -- GitLab From e3589e9184037ff74150ac25a63ea30c74bcc8e3 Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Sun, 4 Jun 2017 18:20:54 -0700 Subject: [PATCH 0520/1347] Truncate publisher name in extension list #27987 --- src/vs/workbench/electron-browser/actions.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/electron-browser/actions.ts b/src/vs/workbench/electron-browser/actions.ts index 2d900b8c8f4..81278ea1d19 100644 --- a/src/vs/workbench/electron-browser/actions.ts +++ b/src/vs/workbench/electron-browser/actions.ts @@ -735,10 +735,10 @@ Steps to Reproduce: return 'none' + themeExclusionStr; } - let tableHeader = `Extension|Author|Version + let tableHeader = `Extension|Author (truncated)|Version ---|---|---`; const table = extensions.map(e => { - return `${e.manifest.name}|${e.manifest.publisher}|${e.manifest.version}`; + return `${e.manifest.name}|${e.manifest.publisher.substr(0, 3)}|${e.manifest.version}`; }).join('\n'); const extensionTable = ` -- GitLab From fc229891ce561b5a9ea1f78f3771a97f4c159a09 Mon Sep 17 00:00:00 2001 From: Jens Hausdorf Date: Mon, 5 Jun 2017 10:44:16 +0200 Subject: [PATCH 0521/1347] Add `.rhtml` to html extension --- extensions/html/package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/extensions/html/package.json b/extensions/html/package.json index 7c6e97305a1..c8525093d01 100644 --- a/extensions/html/package.json +++ b/extensions/html/package.json @@ -24,6 +24,7 @@ { "id": "html", "extensions": [ + ".rhtml", ".html", ".htm", ".shtml", -- GitLab From e8f7f408dbe7cc5d90376d0799615516db86131a Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Mon, 5 Jun 2017 08:57:47 -0700 Subject: [PATCH 0522/1347] Update node-debug2 for #28020 --- build/gulpfile.vscode.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index a44f3e99bd8..2168fbe5bd5 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -43,7 +43,7 @@ const nodeModules = ['electron', 'original-fs'] const builtInExtensions = [ { name: 'ms-vscode.node-debug', version: '1.13.9' }, - { name: 'ms-vscode.node-debug2', version: '1.13.1' } + { name: 'ms-vscode.node-debug2', version: '1.13.2' } ]; const vscodeEntryPoints = _.flatten([ -- GitLab From 651409ec3c7c4f03e470fbf657473cd5978ee70d Mon Sep 17 00:00:00 2001 From: Andre Weinand Date: Mon, 5 Jun 2017 18:18:34 +0200 Subject: [PATCH 0523/1347] node-debug@1.13.10 (translations) --- build/gulpfile.vscode.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index 2168fbe5bd5..5b24acb0bd4 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -42,7 +42,7 @@ const nodeModules = ['electron', 'original-fs'] // Build const builtInExtensions = [ - { name: 'ms-vscode.node-debug', version: '1.13.9' }, + { name: 'ms-vscode.node-debug', version: '1.13.10' }, { name: 'ms-vscode.node-debug2', version: '1.13.2' } ]; -- GitLab From ab1e78ef1f217824c6fe5fda7d80792b4bd7c0a6 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Mon, 5 Jun 2017 10:05:50 -0700 Subject: [PATCH 0524/1347] Update js/ts grammar (#27957) --- .../syntaxes/JavaScript.tmLanguage.json | 19 ++++++++----- .../syntaxes/TypeScript.tmLanguage.json | 27 ++++++++++++------- .../syntaxes/TypeScriptReact.tmLanguage.json | 19 ++++++++----- 3 files changed, 43 insertions(+), 22 deletions(-) diff --git a/extensions/javascript/syntaxes/JavaScript.tmLanguage.json b/extensions/javascript/syntaxes/JavaScript.tmLanguage.json index 8856e46770c..57c071374cc 100644 --- a/extensions/javascript/syntaxes/JavaScript.tmLanguage.json +++ b/extensions/javascript/syntaxes/JavaScript.tmLanguage.json @@ -4,6 +4,7 @@ "If you want to provide a fix or improvement, please create a pull request against the original repository.", "Once accepted there, we are happy to receive an update request." ], + "version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/3a70fab1b03520774fa236f1f7e7a0939463739f", "name": "JavaScript (with React support)", "scopeName": "source.js", "fileTypes": [ @@ -1560,7 +1561,7 @@ } }, { - "match": "(?x)(?:\\s*\\b(public|private|protected|readonly)\\s+)?(\\.\\.\\.)?\\s*(?)\n )) |\n ((async\\s*)?(\n ([(]\\s*(([)]\\s*:)|([_$[:alpha:]][_$[:alnum:]]*\\s*:)|(\\.\\.\\.) )) |\n ([<]\\s*[_$[:alpha:]][_$[:alnum:]]*((\\s+extends\\s*[^=>])|(\\s*[,]))) |\n ((<([^<>=]|=[^<]|\\<([^=<>]|=[^<])+\\>)+>\\s*)?\\(([^()]|\\([^()]*\\))*\\)(\\s*:\\s*(.)*)?\\s*=>)\n ))\n )) |\n (:\\s*(\n (<) |\n ([(]\\s*(\n ([)]) |\n (\\.\\.\\.) |\n ([_$[:alnum:]]+\\s*(\n ([:,?=])|\n ([)]\\s*=>)\n ))\n ))\n ))\n)", + "match": "(?x)(?:\\s*\\b(public|private|protected|readonly)\\s+)?(\\.\\.\\.)?\\s*(?)\n )) |\n ((async\\s*)?(\n ([(]\\s*(([)]\\s*:)|([_$[:alpha:]][_$[:alnum:]]*\\s*:)|(\\.\\.\\.) )) |\n ([<]\\s*[_$[:alpha:]][_$[:alnum:]]*((\\s+extends\\s*[^=>])|(\\s*[,]))) |\n ((<([^<>=]|=[^<]|\\<([^=<>]|=[^<])+\\>)+>\\s*)?\\(([^()]|\\([^()]*\\))*\\)(\\s*:\\s*(.)*)?\\s*=>)\n ))\n )) |\n (:\\s*(\n (<) |\n ([(]\\s*(\n ([)]) |\n (\\.\\.\\.) |\n ([_$[:alnum:]]+\\s*(\n ([:,?=])|\n ([)]\\s*=>)\n ))\n ))\n ))\n)", "captures": { "1": { "name": "storage.modifier.js" @@ -1569,15 +1570,18 @@ "name": "keyword.operator.rest.js" }, "3": { - "name": "entity.name.function.js" + "name": "entity.name.function.js variable.language.this.js" }, "4": { + "name": "entity.name.function.js" + }, + "5": { "name": "keyword.operator.optional.js" } } }, { - "match": "(?:\\s*\\b(public|private|protected|readonly)\\s+)?(\\.\\.\\.)?\\s*(?)|((?!\\{)(?=\\S))", "patterns": [ { "include": "#decl-block" diff --git a/extensions/typescript/syntaxes/TypeScript.tmLanguage.json b/extensions/typescript/syntaxes/TypeScript.tmLanguage.json index a4ba918145b..90c14f0fc99 100644 --- a/extensions/typescript/syntaxes/TypeScript.tmLanguage.json +++ b/extensions/typescript/syntaxes/TypeScript.tmLanguage.json @@ -4,6 +4,7 @@ "If you want to provide a fix or improvement, please create a pull request against the original repository.", "Once accepted there, we are happy to receive an update request." ], + "version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/3a70fab1b03520774fa236f1f7e7a0939463739f", "name": "TypeScript", "scopeName": "source.ts", "fileTypes": [ @@ -1554,7 +1555,7 @@ } }, { - "match": "(?x)(?:\\s*\\b(public|private|protected|readonly)\\s+)?(\\.\\.\\.)?\\s*(?)\n )) |\n ((async\\s*)?(\n ([(]\\s*(([)]\\s*:)|([_$[:alpha:]][_$[:alnum:]]*\\s*:)|(\\.\\.\\.) )) |\n ([<]\\s*[_$[:alpha:]][_$[:alnum:]]*((\\s+extends\\s*[^=>])|(\\s*[,]))) |\n ((<([^<>=]|=[^<]|\\<([^=<>]|=[^<])+\\>)+>\\s*)?\\(([^()]|\\([^()]*\\))*\\)(\\s*:\\s*(.)*)?\\s*=>)\n ))\n )) |\n (:\\s*(\n (<) |\n ([(]\\s*(\n ([)]) |\n (\\.\\.\\.) |\n ([_$[:alnum:]]+\\s*(\n ([:,?=])|\n ([)]\\s*=>)\n ))\n ))\n ))\n)", + "match": "(?x)(?:\\s*\\b(public|private|protected|readonly)\\s+)?(\\.\\.\\.)?\\s*(?)\n )) |\n ((async\\s*)?(\n ([(]\\s*(([)]\\s*:)|([_$[:alpha:]][_$[:alnum:]]*\\s*:)|(\\.\\.\\.) )) |\n ([<]\\s*[_$[:alpha:]][_$[:alnum:]]*((\\s+extends\\s*[^=>])|(\\s*[,]))) |\n ((<([^<>=]|=[^<]|\\<([^=<>]|=[^<])+\\>)+>\\s*)?\\(([^()]|\\([^()]*\\))*\\)(\\s*:\\s*(.)*)?\\s*=>)\n ))\n )) |\n (:\\s*(\n (<) |\n ([(]\\s*(\n ([)]) |\n (\\.\\.\\.) |\n ([_$[:alnum:]]+\\s*(\n ([:,?=])|\n ([)]\\s*=>)\n ))\n ))\n ))\n)", "captures": { "1": { "name": "storage.modifier.ts" @@ -1563,15 +1564,18 @@ "name": "keyword.operator.rest.ts" }, "3": { - "name": "entity.name.function.ts" + "name": "entity.name.function.ts variable.language.this.ts" }, "4": { + "name": "entity.name.function.ts" + }, + "5": { "name": "keyword.operator.optional.ts" } } }, { - "match": "(?:\\s*\\b(public|private|protected|readonly)\\s+)?(\\.\\.\\.)?\\s*(?", + "end": "(\\>)\\s*", "endCaptures": { - "0": { + "1": { "name": "meta.brace.angle.ts" } }, @@ -2561,9 +2568,9 @@ "name": "meta.brace.angle.ts" } }, - "end": "\\>", + "end": "(\\>)\\s*", "endCaptures": { - "0": { + "1": { "name": "meta.brace.angle.ts" } }, @@ -2887,7 +2894,7 @@ "name": "storage.type.function.arrow.ts" } }, - "end": "(?<=\\})|((?!\\{)(?=\\S))", + "end": "(?<=\\}|\\S)(?)|((?!\\{)(?=\\S))", "patterns": [ { "include": "#decl-block" diff --git a/extensions/typescript/syntaxes/TypeScriptReact.tmLanguage.json b/extensions/typescript/syntaxes/TypeScriptReact.tmLanguage.json index f52b684089e..78145cde032 100644 --- a/extensions/typescript/syntaxes/TypeScriptReact.tmLanguage.json +++ b/extensions/typescript/syntaxes/TypeScriptReact.tmLanguage.json @@ -4,6 +4,7 @@ "If you want to provide a fix or improvement, please create a pull request against the original repository.", "Once accepted there, we are happy to receive an update request." ], + "version": "https://github.com/Microsoft/TypeScript-TmLanguage/commit/3a70fab1b03520774fa236f1f7e7a0939463739f", "name": "TypeScriptReact", "scopeName": "source.tsx", "fileTypes": [ @@ -1557,7 +1558,7 @@ } }, { - "match": "(?x)(?:\\s*\\b(public|private|protected|readonly)\\s+)?(\\.\\.\\.)?\\s*(?)\n )) |\n ((async\\s*)?(\n ([(]\\s*(([)]\\s*:)|([_$[:alpha:]][_$[:alnum:]]*\\s*:)|(\\.\\.\\.) )) |\n ([<]\\s*[_$[:alpha:]][_$[:alnum:]]*((\\s+extends\\s*[^=>])|(\\s*[,]))) |\n ((<([^<>=]|=[^<]|\\<([^=<>]|=[^<])+\\>)+>\\s*)?\\(([^()]|\\([^()]*\\))*\\)(\\s*:\\s*(.)*)?\\s*=>)\n ))\n )) |\n (:\\s*(\n (<) |\n ([(]\\s*(\n ([)]) |\n (\\.\\.\\.) |\n ([_$[:alnum:]]+\\s*(\n ([:,?=])|\n ([)]\\s*=>)\n ))\n ))\n ))\n)", + "match": "(?x)(?:\\s*\\b(public|private|protected|readonly)\\s+)?(\\.\\.\\.)?\\s*(?)\n )) |\n ((async\\s*)?(\n ([(]\\s*(([)]\\s*:)|([_$[:alpha:]][_$[:alnum:]]*\\s*:)|(\\.\\.\\.) )) |\n ([<]\\s*[_$[:alpha:]][_$[:alnum:]]*((\\s+extends\\s*[^=>])|(\\s*[,]))) |\n ((<([^<>=]|=[^<]|\\<([^=<>]|=[^<])+\\>)+>\\s*)?\\(([^()]|\\([^()]*\\))*\\)(\\s*:\\s*(.)*)?\\s*=>)\n ))\n )) |\n (:\\s*(\n (<) |\n ([(]\\s*(\n ([)]) |\n (\\.\\.\\.) |\n ([_$[:alnum:]]+\\s*(\n ([:,?=])|\n ([)]\\s*=>)\n ))\n ))\n ))\n)", "captures": { "1": { "name": "storage.modifier.tsx" @@ -1566,15 +1567,18 @@ "name": "keyword.operator.rest.tsx" }, "3": { - "name": "entity.name.function.tsx" + "name": "entity.name.function.tsx variable.language.this.tsx" }, "4": { + "name": "entity.name.function.tsx" + }, + "5": { "name": "keyword.operator.optional.tsx" } } }, { - "match": "(?:\\s*\\b(public|private|protected|readonly)\\s+)?(\\.\\.\\.)?\\s*(?)|((?!\\{)(?=\\S))", "patterns": [ { "include": "#decl-block" -- GitLab From 706d52c1aafc14a1e737fae8a3478b3d9268cb5d Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Mon, 5 Jun 2017 10:35:57 -0700 Subject: [PATCH 0525/1347] Fix svg links in webview. Fixes #28035 --- src/vs/workbench/parts/html/browser/webview-pre.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/html/browser/webview-pre.js b/src/vs/workbench/parts/html/browser/webview-pre.js index a371b3f33c0..0abf15e97f8 100644 --- a/src/vs/workbench/parts/html/browser/webview-pre.js +++ b/src/vs/workbench/parts/html/browser/webview-pre.js @@ -47,7 +47,7 @@ /** @type {any} */ var node = event.target; while (node) { - if (node.tagName === "A" && node.href) { + if (node.tagName && node.tagName.toLowerCase() === 'a' && node.href) { var baseElement = event.view.document.getElementsByTagName("base")[0]; if (node.getAttribute("href") === "#") { event.view.scrollTo(0, 0); -- GitLab From 13112461e05790ecdaabc57d64ba3432aaa5bec4 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 31 May 2017 07:42:54 +0200 Subject: [PATCH 0526/1347] Layer-breaker in telemetryUtils (fixes #27141) --- .../telemetry/common/telemetryUtils.ts | 38 +++++++++---------- .../welcomePage.contribution.ts | 16 -------- .../page/electron-browser/welcomePage.ts | 21 +++++++++- 3 files changed, 39 insertions(+), 36 deletions(-) diff --git a/src/vs/platform/telemetry/common/telemetryUtils.ts b/src/vs/platform/telemetry/common/telemetryUtils.ts index 7ba7db945fe..74b796dc0a8 100644 --- a/src/vs/platform/telemetry/common/telemetryUtils.ts +++ b/src/vs/platform/telemetry/common/telemetryUtils.ts @@ -50,15 +50,15 @@ export function loadExperiments(accessor: ServicesAccessor): ITelemetryExperimen const storageService = accessor.get(IStorageService); const configurationService = accessor.get(IConfigurationService); - updateExperimentsOverrides(configurationService); - configurationService.onDidUpdateConfiguration(e => updateExperimentsOverrides(configurationService)); + updateExperimentsOverrides(configurationService, storageService); + configurationService.onDidUpdateConfiguration(e => updateExperimentsOverrides(configurationService, storageService)); let { showNewUserWatermark, openUntitledFile, enableWelcomePage, mergeQuickLinks, - } = splitExperimentsRandomness(); + } = splitExperimentsRandomness(storageService); const newUserDuration = 24 * 60 * 60 * 1000; const firstSessionDate = storageService.get('telemetry.firstSessionDate'); @@ -73,16 +73,16 @@ export function loadExperiments(accessor: ServicesAccessor): ITelemetryExperimen openUntitledFile, enableWelcomePage, mergeQuickLinks, - }); + }, storageService); } -export function isWelcomePageEnabled() { - const overrides = getExperimentsOverrides(); - return 'enableWelcomePage' in overrides ? overrides.enableWelcomePage : splitExperimentsRandomness().enableWelcomePage; +export function isWelcomePageEnabled(storageService: IStorageService) { + const overrides = getExperimentsOverrides(storageService); + return 'enableWelcomePage' in overrides ? overrides.enableWelcomePage : splitExperimentsRandomness(storageService).enableWelcomePage; } -function applyOverrides(experiments: ITelemetryExperiments): ITelemetryExperiments { - const experimentsConfig = getExperimentsOverrides(); +function applyOverrides(experiments: ITelemetryExperiments, storageService: IStorageService): ITelemetryExperiments { + const experimentsConfig = getExperimentsOverrides(storageService); Object.keys(experiments).forEach(key => { if (key in experimentsConfig) { experiments[key] = experimentsConfig[key]; @@ -91,8 +91,8 @@ function applyOverrides(experiments: ITelemetryExperiments): ITelemetryExperimen return experiments; } -function splitExperimentsRandomness(): ITelemetryExperiments { - const random1 = getExperimentsRandomness(); +function splitExperimentsRandomness(storageService: IStorageService): ITelemetryExperiments { + const random1 = getExperimentsRandomness(storageService); const [random2, showNewUserWatermark] = splitRandom(random1); const [random3, openUntitledFile] = splitRandom(random2); const [random4, mergeQuickLinks] = splitRandom(random3); @@ -105,12 +105,12 @@ function splitExperimentsRandomness(): ITelemetryExperiments { }; } -function getExperimentsRandomness() { +function getExperimentsRandomness(storageService: IStorageService) { const key = StorageService.GLOBAL_PREFIX + 'experiments.randomness'; - let valueString = window.localStorage.getItem(key); + let valueString = storageService.get(key); if (!valueString) { valueString = Math.random().toString(); - window.localStorage.setItem(key, valueString); + storageService.store(key, valueString); } return parseFloat(valueString); @@ -124,17 +124,17 @@ function splitRandom(random: number): [number, boolean] { const experimentsOverridesKey = StorageService.GLOBAL_PREFIX + 'experiments.overrides'; -function getExperimentsOverrides(): ITelemetryExperiments { - const valueString = window.localStorage.getItem(experimentsOverridesKey); +function getExperimentsOverrides(storageService: IStorageService): ITelemetryExperiments { + const valueString = storageService.get(experimentsOverridesKey); return valueString ? JSON.parse(valueString) : {}; } -function updateExperimentsOverrides(configurationService: IConfigurationService) { - const storageOverrides = getExperimentsOverrides(); +function updateExperimentsOverrides(configurationService: IConfigurationService, storageService: IStorageService) { + const storageOverrides = getExperimentsOverrides(storageService); const config: any = configurationService.getConfiguration('telemetry'); const configOverrides = config && config.experiments || {}; if (!objects.equals(storageOverrides, configOverrides)) { - window.localStorage.setItem(experimentsOverridesKey, JSON.stringify(configOverrides)); + storageService.store(experimentsOverridesKey, JSON.stringify(configOverrides)); } } diff --git a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.ts b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.ts index d9be0524ce0..4ca598c5111 100644 --- a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.ts +++ b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.ts @@ -8,24 +8,8 @@ import { localize } from 'vs/nls'; import { IWorkbenchContributionsRegistry, Extensions as WorkbenchExtensions } from 'vs/workbench/common/contributions'; import { Registry } from 'vs/platform/platform'; import { WelcomePageContribution, WelcomePageAction } from 'vs/workbench/parts/welcome/page/electron-browser/welcomePage'; -import { IConfigurationRegistry, Extensions as ConfigurationExtensions } from 'vs/platform/configuration/common/configurationRegistry'; import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/workbench/common/actionRegistry'; import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; -import { isWelcomePageEnabled } from 'vs/platform/telemetry/common/telemetryUtils'; - -Registry.as(ConfigurationExtensions.Configuration) - .registerConfiguration({ - 'id': 'workbench', - 'order': 7, - 'title': localize('workbenchConfigurationTitle', "Workbench"), - 'properties': { - 'workbench.welcome.enabled': { - 'type': 'boolean', - 'default': isWelcomePageEnabled(), - 'description': localize('welcomePage.enabled', "When enabled, will show the Welcome page on startup.") - }, - } - }); Registry.as(WorkbenchExtensions.Workbench) .registerWorkbenchContribution(WelcomePageContribution); diff --git a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts index 976702e229d..56c00efa87e 100644 --- a/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts +++ b/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.ts @@ -38,6 +38,10 @@ import { IThemeService, registerThemingParticipant } from 'vs/platform/theme/com import { registerColor, focusBorder, textLinkForeground, textLinkActiveForeground, foreground, descriptionForeground, contrastBorder, activeContrastBorder } from 'vs/platform/theme/common/colorRegistry'; import { getExtraColor } from 'vs/workbench/parts/welcome/walkThrough/node/walkThroughUtils'; import { IExtensionsWorkbenchService } from 'vs/workbench/parts/extensions/common/extensions'; +import { isWelcomePageEnabled } from 'vs/platform/telemetry/common/telemetryUtils'; +import { IConfigurationRegistry, Extensions as ConfigurationExtensions } from 'vs/platform/configuration/common/configurationRegistry'; +import { IStorageService } from "vs/platform/storage/common/storage"; +import { Registry } from 'vs/platform/platform'; used(); @@ -52,7 +56,8 @@ export class WelcomePageContribution implements IWorkbenchContribution { @IConfigurationService configurationService: IConfigurationService, @IWorkbenchEditorService editorService: IWorkbenchEditorService, @IBackupFileService backupFileService: IBackupFileService, - @ITelemetryService telemetryService: ITelemetryService + @ITelemetryService telemetryService: ITelemetryService, + @IStorageService storageService: IStorageService ) { const enabled = configurationService.lookup(enabledKey).value; if (enabled) { @@ -66,6 +71,20 @@ export class WelcomePageContribution implements IWorkbenchContribution { } }).then(null, onUnexpectedError); } + + Registry.as(ConfigurationExtensions.Configuration) + .registerConfiguration({ + 'id': 'workbench', + 'order': 7, + 'title': localize('workbenchConfigurationTitle', "Workbench"), + 'properties': { + 'workbench.welcome.enabled': { + 'type': 'boolean', + 'default': isWelcomePageEnabled(storageService), + 'description': localize('welcomePage.enabled', "When enabled, will show the Welcome page on startup.") + }, + } + }); } public getId() { -- GitLab From 794b435b27bcf4a92cc0a6345b97821e3c827dcc Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Mon, 5 Jun 2017 14:32:53 -0700 Subject: [PATCH 0527/1347] Include border when setting details height to remove the workaround of setting calc width that caused #28058 --- .../contrib/suggest/browser/media/suggest.css | 30 ++++--------------- .../contrib/suggest/browser/suggestWidget.ts | 8 ++++- 2 files changed, 12 insertions(+), 26 deletions(-) diff --git a/src/vs/editor/contrib/suggest/browser/media/suggest.css b/src/vs/editor/contrib/suggest/browser/media/suggest.css index a154e7c1959..1c3b4374b66 100644 --- a/src/vs/editor/contrib/suggest/browser/media/suggest.css +++ b/src/vs/editor/contrib/suggest/browser/media/suggest.css @@ -14,16 +14,18 @@ width: 430px; } +.monaco-editor .suggest-widget > .message, .monaco-editor .suggest-widget > .tree, .monaco-editor .suggest-widget > .details { - width: calc(100% - 2px); + width: 100%; border-style: solid; border-width: 1px; + box-sizing: border-box; } +.monaco-editor.hc-black .suggest-widget > .message, .monaco-editor.hc-black .suggest-widget > .tree, .monaco-editor.hc-black .suggest-widget > .details { - width: calc(100% - 4px); border-width: 2px; } @@ -34,12 +36,8 @@ .monaco-editor .suggest-widget.docs-side > .tree, .monaco-editor .suggest-widget.docs-side > .details { - /* subtract 2px for border, and another 2 for the Chromium zoom issue - where the children get slightly bigger width than what is set - which makes the docs go below the list */ - width: calc(50% - 4px); + width: 50%; float: left; - } .monaco-editor .suggest-widget.docs-side.list-right > .tree, @@ -47,28 +45,10 @@ float: right; } -.monaco-editor.hc-black .suggest-widget.docs-side > .tree, -.monaco-editor.hc-black .suggest-widget.docs-side > .details { - width: 326px; -} - -.monaco-editor .suggest-widget.docs-side .empty-left-border { - border-left-width: 0px; -} - -.monaco-editor .suggest-widget.docs-side .empty-right-border { - border-right-width: 0px; -} /* Styles for Message element for when widget is loading or is empty */ .monaco-editor .suggest-widget > .message { padding-left: 22px; - border-style: solid; - border-width: 1px; -} - -.monaco-editor.hc-black .suggest-widget > .message { - border-width: 2px; } /** Styles for the list element **/ diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index 1c7a97e314b..a3154f2a23d 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -198,6 +198,7 @@ class SuggestionDetails { private docs: HTMLElement; private ariaLabel: string; private disposables: IDisposable[]; + private borderWidth: number = 1; constructor( container: HTMLElement, @@ -254,7 +255,7 @@ class SuggestionDetails { hide(this.type); } - this.el.style.height = this.header.offsetHeight + this.docs.offsetHeight + 'px'; + this.el.style.height = this.header.offsetHeight + this.docs.offsetHeight + (this.borderWidth * 2) + 'px'; this.close.onmousedown = e => { e.preventDefault(); @@ -300,6 +301,10 @@ class SuggestionDetails { this.scrollUp(80); } + setBorderWidth(width: number): void { + this.borderWidth = width; + } + private configureFont() { const configuration = this.editor.getConfiguration(); const fontFamily = configuration.fontInfo.fontFamily; @@ -507,6 +512,7 @@ export class SuggestWidget implements IContentWidget, IDelegate if (focusBorderColor) { this.detailsFocusBorderColor = focusBorderColor.toString(); } + this.details.setBorderWidth(theme.type === 'hc' ? 2 : 1); } private onListFocus(e: IListEvent): void { -- GitLab From 51b55e8021ef496cabaecc411bbb74207f739fc5 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Mon, 5 Jun 2017 15:03:43 -0700 Subject: [PATCH 0528/1347] Stringify Telemetry Fields in the TSExtension Fixes #28065 --- extensions/typescript/src/typescriptServiceClient.ts | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/extensions/typescript/src/typescriptServiceClient.ts b/extensions/typescript/src/typescriptServiceClient.ts index 84f35f4f11c..072652eedad 100644 --- a/extensions/typescript/src/typescriptServiceClient.ts +++ b/extensions/typescript/src/typescriptServiceClient.ts @@ -971,8 +971,12 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient let payload = telemetryData.payload; if (payload) { Object.keys(payload).forEach((key) => { - if (payload.hasOwnProperty(key) && is.string(payload[key])) { - properties[key] = payload[key]; + try { + if (payload.hasOwnProperty(key)) { + properties[key] = is.string(payload[key]) ? payload[key] : JSON.stringify(payload[key]); + } + } catch (e) { + // noop } }); } -- GitLab From f5b5966c947a2a432e6ff3427248d8eafece5785 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Mon, 5 Jun 2017 16:12:30 -0700 Subject: [PATCH 0529/1347] Mark a few more fields as readonly --- extensions/typescript/src/typescriptServiceClient.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/extensions/typescript/src/typescriptServiceClient.ts b/extensions/typescript/src/typescriptServiceClient.ts index 072652eedad..d790668427e 100644 --- a/extensions/typescript/src/typescriptServiceClient.ts +++ b/extensions/typescript/src/typescriptServiceClient.ts @@ -185,10 +185,10 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient private requestQueue: RequestItem[]; private pendingResponses: number; private callbacks: CallbackMap; - private _onProjectLanguageServiceStateChanged = new EventEmitter(); - private _onDidBeginInstallTypings = new EventEmitter(); - private _onDidEndInstallTypings = new EventEmitter(); - private _onTypesInstallerInitializationFailed = new EventEmitter(); + private readonly _onProjectLanguageServiceStateChanged = new EventEmitter(); + private readonly _onDidBeginInstallTypings = new EventEmitter(); + private readonly _onDidEndInstallTypings = new EventEmitter(); + private readonly _onTypesInstallerInitializationFailed = new EventEmitter(); private _apiVersion: API; private telemetryReporter: TelemetryReporter; -- GitLab From 70e52f186078256e85273bb5736f22b0c56ccf25 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Mon, 5 Jun 2017 15:51:52 -0700 Subject: [PATCH 0530/1347] Extract basic request queue to class --- .../typescript/src/typescriptServiceClient.ts | 61 +++++++++++++------ 1 file changed, 43 insertions(+), 18 deletions(-) diff --git a/extensions/typescript/src/typescriptServiceClient.ts b/extensions/typescript/src/typescriptServiceClient.ts index d790668427e..1191bb9243a 100644 --- a/extensions/typescript/src/typescriptServiceClient.ts +++ b/extensions/typescript/src/typescriptServiceClient.ts @@ -156,6 +156,42 @@ class TypeScriptServiceConfiguration { } } +class RequestQueue { + private queue: RequestItem[] = []; + private sequenceNumber: number = 0; + + public get length(): number { + return this.queue.length; + } + + public push(item: RequestItem): void { + this.queue.push(item); + } + + public shift(): RequestItem | undefined { + return this.queue.shift(); + } + + public tryCancelPendingRequest(seq: number): boolean { + for (let i = 0; i < this.queue.length; i++) { + if (this.queue[i].request.seq === seq) { + this.queue.splice(i, 1); + return true; + } + } + return false; + } + + public createRequest(command: string, args: any): Proto.Request { + return { + seq: this.sequenceNumber++, + type: 'request', + command: command, + arguments: args + }; + } +} + export default class TypeScriptServiceClient implements ITypescriptServiceClient { private static useWorkspaceTsdkStorageKey = 'typescript.useWorkspaceTsdk'; private static tsdkMigratedStorageKey = 'typescript.tsdkMigrated'; @@ -176,13 +212,12 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient private servicePromise: Thenable | null; private lastError: Error | null; private reader: Reader; - private sequenceNumber: number; private firstStart: number; private lastStart: number; private numberRestarts: number; private cancellationPipeName: string | null = null; - private requestQueue: RequestItem[]; + private requestQueue: RequestQueue; private pendingResponses: number; private callbacks: CallbackMap; private readonly _onProjectLanguageServiceStateChanged = new EventEmitter(); @@ -211,11 +246,10 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient this.servicePromise = null; this.lastError = null; - this.sequenceNumber = 0; this.firstStart = Date.now(); this.numberRestarts = 0; - this.requestQueue = []; + this.requestQueue = new RequestQueue(); this.pendingResponses = 0; this.callbacks = Object.create(null); this.configuration = TypeScriptServiceConfiguration.loadFromWorkspace(); @@ -417,8 +451,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient this.versionStatus.setInfo(label, tooltip); - this.sequenceNumber = 0; - this.requestQueue = []; + this.requestQueue = new RequestQueue(); this.pendingResponses = 0; this.lastError = null; @@ -839,12 +872,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient token = expectsResultOrToken; } - const request: Proto.Request = { - seq: this.sequenceNumber++, - type: 'request', - command: command, - arguments: args - }; + const request = this.requestQueue.createRequest(command, args); const requestInfo: RequestItem = { request: request, promise: null, @@ -899,12 +927,9 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient } private tryCancelRequest(seq: number): boolean { - for (let i = 0; i < this.requestQueue.length; i++) { - if (this.requestQueue[i].request.seq === seq) { - this.requestQueue.splice(i, 1); - this.tracer.logTrace(`TypeScript Service: canceled request with sequence number ${seq}`); - return true; - } + if (this.requestQueue.tryCancelPendingRequest(seq)) { + this.tracer.logTrace(`TypeScript Service: canceled request with sequence number ${seq}`); + return true; } if (this.apiVersion.has222Features() && this.cancellationPipeName) { -- GitLab From 42ede266aa9ce62e258d54e73576642ab684eb43 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Mon, 5 Jun 2017 16:32:16 -0700 Subject: [PATCH 0531/1347] Extracting callbackmap to own class --- .../typescript/src/typescriptServiceClient.ts | 60 ++++++++++++------- 1 file changed, 38 insertions(+), 22 deletions(-) diff --git a/extensions/typescript/src/typescriptServiceClient.ts b/extensions/typescript/src/typescriptServiceClient.ts index 1191bb9243a..4f68a6991fb 100644 --- a/extensions/typescript/src/typescriptServiceClient.ts +++ b/extensions/typescript/src/typescriptServiceClient.ts @@ -32,8 +32,34 @@ interface CallbackItem { start: number; } -interface CallbackMap { - [key: number]: CallbackItem; +class CallbackMap { + private callbacks: Map = new Map(); + public pendingResponses: number = 0; + + public destroy(e: any): void { + for (const callback of this.callbacks.values()) { + callback.e(e); + } + this.callbacks = new Map(); + this.pendingResponses = 0; + } + + public add(seq: number, callback: CallbackItem) { + this.callbacks.set(seq, callback); + ++this.pendingResponses; + } + + public fetch(seq: number): CallbackItem | undefined { + const callback = this.callbacks.get(seq); + this.delete(seq); + return callback; + } + + private delete(seq: number) { + if (this.callbacks.delete(seq)) { + --this.pendingResponses; + } + } } interface RequestItem { @@ -218,8 +244,8 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient private cancellationPipeName: string | null = null; private requestQueue: RequestQueue; - private pendingResponses: number; private callbacks: CallbackMap; + private readonly _onProjectLanguageServiceStateChanged = new EventEmitter(); private readonly _onDidBeginInstallTypings = new EventEmitter(); private readonly _onDidEndInstallTypings = new EventEmitter(); @@ -250,8 +276,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient this.numberRestarts = 0; this.requestQueue = new RequestQueue(); - this.pendingResponses = 0; - this.callbacks = Object.create(null); + this.callbacks = new CallbackMap(); this.configuration = TypeScriptServiceConfiguration.loadFromWorkspace(); this._experimentalAutoBuild = false; // configuration.get('typescript.tsserver.experimentalAutoBuild', false); @@ -452,7 +477,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient this.requestQueue = new RequestQueue(); - this.pendingResponses = 0; + this.callbacks = new CallbackMap(); this.lastError = null; try { @@ -787,10 +812,8 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient private serviceExited(restart: boolean): void { this.servicePromise = null; this.tsServerLogFile = null; - Object.keys(this.callbacks).forEach((key) => { - this.callbacks[parseInt(key)].e(new Error('Service died.')); - }); - this.callbacks = Object.create(null); + this.callbacks.destroy(new Error('Service died.')); + this.callbacks = new CallbackMap(); if (restart) { const diff = Date.now() - this.lastStart; this.numberRestarts++; @@ -898,7 +921,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient } private sendNextRequests(): void { - while (this.pendingResponses === 0 && this.requestQueue.length > 0) { + while (this.callbacks.pendingResponses === 0 && this.requestQueue.length > 0) { const item = this.requestQueue.shift(); if (item) { this.sendRequest(item); @@ -910,18 +933,15 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient let serverRequest = requestItem.request; this.tracer.traceRequest(serverRequest, !!requestItem.callbacks, this.requestQueue.length); if (requestItem.callbacks) { - this.callbacks[serverRequest.seq] = requestItem.callbacks; - this.pendingResponses++; + this.callbacks.add(serverRequest.seq, requestItem.callbacks); } this.service() .then((childProcess) => { childProcess.stdin.write(JSON.stringify(serverRequest) + '\r\n', 'utf8'); }).then(undefined, err => { - let callback = this.callbacks[serverRequest.seq]; + const callback = this.callbacks.fetch(serverRequest.seq); if (callback) { callback.e(err); - delete this.callbacks[serverRequest.seq]; - this.pendingResponses--; } }); } @@ -940,10 +960,8 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient } catch (e) { // noop } finally { - const p = this.callbacks[seq]; + const p = this.callbacks.fetch(seq); if (p) { - delete this.callbacks[seq]; - this.pendingResponses--; p.e(new Error(`Cancelled Request ${seq}`)); } } @@ -957,11 +975,9 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient try { if (message.type === 'response') { const response: Proto.Response = message as Proto.Response; - const p = this.callbacks[response.request_seq]; + const p = this.callbacks.fetch(response.request_seq); if (p) { this.tracer.traceResponse(response, p.start); - delete this.callbacks[response.request_seq]; - this.pendingResponses--; if (response.success) { p.c(response); } else { -- GitLab From dd361faca8708cba5f1fde705187cdd87040c0b4 Mon Sep 17 00:00:00 2001 From: Jens Hausdorf Date: Tue, 6 Jun 2017 08:25:35 +0200 Subject: [PATCH 0532/1347] fix casing --- src/vs/workbench/browser/parts/editor/editorStatus.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/browser/parts/editor/editorStatus.ts b/src/vs/workbench/browser/parts/editor/editorStatus.ts index ee9d12bbcd7..f6a52750b63 100644 --- a/src/vs/workbench/browser/parts/editor/editorStatus.ts +++ b/src/vs/workbench/browser/parts/editor/editorStatus.ts @@ -225,8 +225,8 @@ const nlsMultiSelectionRange = nls.localize('multiSelectionRange', "{0} selectio const nlsMultiSelection = nls.localize('multiSelection', "{0} selections"); const nlsEOLLF = nls.localize('endOfLineLineFeed', "LF"); const nlsEOLCRLF = nls.localize('endOfLineCarriageReturnLineFeed', "CRLF"); -const nlsTabFocusMode = nls.localize('tabFocusModeEnabled', "Tab moves focus"); -const nlsScreenReaderDetected = nls.localize('screenReaderDetected', "Screen Reader detected"); +const nlsTabFocusMode = nls.localize('tabFocusModeEnabled', "Tab Moves Focus"); +const nlsScreenReaderDetected = nls.localize('screenReaderDetected', "Screen Reader Detected"); const nlsScreenReaderDetectedTitle = nls.localize('screenReaderDetectedExtra', "If you are not using a Screen Reader, please change the setting `editor.accessibilitySupport` to \"off\"."); function _setDisplay(el: HTMLElement, desiredValue: string): void { -- GitLab From 56cf3122bef57dbf52f8702dec5107536694eb8f Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Tue, 6 Jun 2017 11:15:36 +0200 Subject: [PATCH 0533/1347] improve window picker (for #25145) --- src/vs/platform/windows/common/windows.ts | 2 +- .../windows/electron-main/windowsService.ts | 12 +- src/vs/workbench/electron-browser/actions.ts | 25 +--- .../electron-browser/main.contribution.ts | 20 ++- .../electron-browser/windowPicker.ts | 120 ++++++++++++++++++ 5 files changed, 153 insertions(+), 26 deletions(-) create mode 100644 src/vs/workbench/electron-browser/windowPicker.ts diff --git a/src/vs/platform/windows/common/windows.ts b/src/vs/platform/windows/common/windows.ts index b4ff59ddacf..b85f0b15315 100644 --- a/src/vs/platform/windows/common/windows.ts +++ b/src/vs/platform/windows/common/windows.ts @@ -50,7 +50,7 @@ export interface IWindowsService { openWindow(paths: string[], options?: { forceNewWindow?: boolean, forceReuseWindow?: boolean }): TPromise; openNewWindow(): TPromise; showWindow(windowId: number): TPromise; - getWindows(): TPromise<{ id: number; path: string; title: string; }[]>; + getWindows(): TPromise<{ id: number; path: string; title: string; filename?: string; }[]>; getWindowCount(): TPromise; log(severity: string, ...messages: string[]): TPromise; // TODO@joao: what? diff --git a/src/vs/platform/windows/electron-main/windowsService.ts b/src/vs/platform/windows/electron-main/windowsService.ts index 5cef01c60f5..096386c0f5e 100644 --- a/src/vs/platform/windows/electron-main/windowsService.ts +++ b/src/vs/platform/windows/electron-main/windowsService.ts @@ -16,9 +16,8 @@ import Event, { chain } from 'vs/base/common/event'; import { fromEventEmitter } from 'vs/base/node/event'; import { IURLService } from 'vs/platform/url/common/url'; import { ITelemetryData } from 'vs/platform/telemetry/common/telemetry'; - -// TODO@Joao: remove this dependency, move all implementation to this class -import { OpenContext } from 'vs/code/common/windows'; +import { isMacintosh } from "vs/base/common/platform"; +import { OpenContext } from 'vs/code/common/windows'; // TODO@Joao: remove this dependency, move all implementation to this class import { IWindowsMainService } from 'vs/code/electron-main/windows'; import { ILifecycleService } from "vs/code/electron-main/lifecycle"; @@ -255,7 +254,12 @@ export class WindowsService implements IWindowsService, IDisposable { getWindows(): TPromise<{ id: number; path: string; title: string; }[]> { const windows = this.windowsMainService.getWindows(); - const result = windows.map(w => ({ path: w.openedWorkspacePath, title: w.win.getTitle(), id: w.id })); + const result = windows.map(w => { + const filename = isMacintosh ? w.win.getRepresentedFilename() : void 0; + + return { path: w.openedWorkspacePath, title: w.win.getTitle(), id: w.id, filename }; + }); + return TPromise.as(result); } diff --git a/src/vs/workbench/electron-browser/actions.ts b/src/vs/workbench/electron-browser/actions.ts index 98e0d84f20c..05eac607208 100644 --- a/src/vs/workbench/electron-browser/actions.ts +++ b/src/vs/workbench/electron-browser/actions.ts @@ -34,6 +34,8 @@ import { IEditorGroupService } from 'vs/workbench/services/group/common/groupSer import { IPanelService } from 'vs/workbench/services/panel/common/panelService'; import { IPartService, Parts, Position as SidebarPosition } from 'vs/workbench/services/part/common/partService'; import { IViewletService } from 'vs/workbench/services/viewlet/browser/viewlet'; +import { QuickOpenAction } from "vs/workbench/browser/quickopen"; +import { SWITCH_WINDOWS_PREFIX } from "vs/workbench/electron-browser/windowPicker"; import * as os from 'os'; import { webFrame } from 'electron'; @@ -79,7 +81,7 @@ export class CloseWindowAction extends Action { } } -export class SwitchWindow extends Action { +export class SwitchWindow extends QuickOpenAction { static ID = 'workbench.action.switchWindow'; static LABEL = nls.localize('switchWindow', "Switch Window"); @@ -87,26 +89,9 @@ export class SwitchWindow extends Action { constructor( id: string, label: string, - @IWindowsService private windowsService: IWindowsService, - @IWindowService private windowService: IWindowService, - @IQuickOpenService private quickOpenService: IQuickOpenService + @IQuickOpenService quickOpenService: IQuickOpenService ) { - super(id, label); - } - - run(): TPromise { - const currentWindowId = this.windowService.getCurrentWindowId(); - - return this.windowsService.getWindows().then(workspaces => { - const placeHolder = nls.localize('switchWindowPlaceHolder', "Select a window"); - const picks = workspaces.map(w => ({ - label: w.title, - description: (currentWindowId === w.id) ? nls.localize('current', "Current Window") : void 0, - run: () => this.windowsService.showWindow(w.id) - })); - - this.quickOpenService.pick(picks, { placeHolder }); - }); + super(id, label, SWITCH_WINDOWS_PREFIX, quickOpenService); } } diff --git a/src/vs/workbench/electron-browser/main.contribution.ts b/src/vs/workbench/electron-browser/main.contribution.ts index 53ab7b01760..7e293e56bbb 100644 --- a/src/vs/workbench/electron-browser/main.contribution.ts +++ b/src/vs/workbench/electron-browser/main.contribution.ts @@ -18,6 +18,8 @@ import { CloseEditorAction, KeybindingsReferenceAction, OpenDocumentationUrlActi import { MessagesVisibleContext } from 'vs/workbench/electron-browser/workbench'; import { IJSONSchema } from 'vs/base/common/jsonSchema'; import { registerCommands } from 'vs/workbench/electron-browser/commands'; +import { IQuickOpenRegistry, QuickOpenHandlerDescriptor, Extensions as QuickOpenExtensions } from "vs/workbench/browser/quickopen"; +import { SWITCH_WINDOWS_PREFIX } from "vs/workbench/electron-browser/windowPicker"; // Contribute Commands registerCommands(); @@ -80,6 +82,22 @@ const developerCategory = nls.localize('developer', "Developer"); workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(ShowStartupPerformance, ShowStartupPerformance.ID, ShowStartupPerformance.LABEL), 'Developer: Startup Performance', developerCategory); workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(ToggleSharedProcessAction, ToggleSharedProcessAction.ID, ToggleSharedProcessAction.LABEL), 'Developer: Toggle Shared Process', developerCategory); +// Window switcher +Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpenHandler( + new QuickOpenHandlerDescriptor( + 'vs/workbench/electron-browser/windowPicker', + 'WindowPicker', + SWITCH_WINDOWS_PREFIX, + [ + { + prefix: SWITCH_WINDOWS_PREFIX, + needsEditor: false, + description: nls.localize('switchBetweenWindows', "Switch between Windows") + } + ] + ) +); + // Configuration: Workbench const configurationRegistry = Registry.as(ConfigurationExtensions.Configuration); @@ -345,4 +363,4 @@ configurationRegistry.registerConfiguration({ 'description': nls.localize('zenMode.restore', "Controls if a window should restore to zen mode if it was exited in zen mode.") } } -}); +}); \ No newline at end of file diff --git a/src/vs/workbench/electron-browser/windowPicker.ts b/src/vs/workbench/electron-browser/windowPicker.ts new file mode 100644 index 00000000000..05767e25f41 --- /dev/null +++ b/src/vs/workbench/electron-browser/windowPicker.ts @@ -0,0 +1,120 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +'use strict'; + +import { TPromise } from 'vs/base/common/winjs.base'; +import nls = require('vs/nls'); +import URI from 'vs/base/common/uri'; +import errors = require('vs/base/common/errors'); +import { IIconLabelOptions } from 'vs/base/browser/ui/iconLabel/iconLabel'; +import { Mode, IEntryRunContext } from 'vs/base/parts/quickopen/common/quickOpen'; +import { QuickOpenModel, QuickOpenEntry } from 'vs/base/parts/quickopen/browser/quickOpenModel'; +import scorer = require('vs/base/common/scorer'); +import { IModeService } from 'vs/editor/common/services/modeService'; +import { getIconClasses } from 'vs/workbench/browser/labels'; +import { IModelService } from 'vs/editor/common/services/modelService'; +import { QuickOpenHandler } from 'vs/workbench/browser/quickopen'; +import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; +import { IWindowsService, IWindowService } from "vs/platform/windows/common/windows"; +import { stripWildcards } from "vs/base/common/strings"; + +export const SWITCH_WINDOWS_PREFIX = 'windows '; + +export class WindowPickerEntry extends QuickOpenEntry { + + constructor( + private windowId: number, + private label: string, + private resource: URI, + private isCurrentWindow: boolean, + private hasFolderOpened: boolean, + @IWindowsService private windowsService: IWindowsService, + @IModelService private modelService: IModelService, + @IModeService private modeService: IModeService + ) { + super(); + } + + public getLabelOptions(): IIconLabelOptions { + return { + extraClasses: getIconClasses(this.modelService, this.modeService, this.resource, !this.resource && this.hasFolderOpened /* isFolder */) + }; + } + + public getLabel(): string { + return this.label; + } + + public getResource(): URI { + return this.resource; + } + + public getAriaLabel(): string { + return nls.localize('entryAriaLabel', "{0}, window picker", this.getLabel()); + } + + public getDescription(): string { + return this.isCurrentWindow ? nls.localize('current', "Current Window") : void 0; + } + + public run(mode: Mode, context: IEntryRunContext): boolean { + if (mode === Mode.OPEN) { + setTimeout(() => { + // Bug: somehow when not running this code in a timeout, it is not possible to use this picker + // with quick navigate keys (not able to trigger quick navigate once running it once). + this.windowsService.showWindow(this.windowId).done(null, errors.onUnexpectedError); + }); + + return true; + } + + return super.run(mode, context); + } +} + +export class WindowPicker extends QuickOpenHandler { + + constructor( + @IWindowsService private windowsService: IWindowsService, + @IWindowService private windowService: IWindowService, + @IInstantiationService private instantiationService: IInstantiationService + ) { + super(); + } + + public getResults(searchValue: string): TPromise { + searchValue = searchValue.trim(); + + const normalizedSearchValueLowercase = stripWildcards(searchValue).toLowerCase(); + const currentWindowId = this.windowService.getCurrentWindowId(); + + return this.windowsService.getWindows().then(windows => { + let entries = windows.map(win => { + return this.instantiationService.createInstance(WindowPickerEntry, win.id, win.title, win.filename ? URI.file(win.filename) : void 0, currentWindowId === win.id, !!win.path); + }); + + entries = entries.filter(e => { + if (!searchValue) { + return true; + } + + if (!scorer.matches(e.getLabel(), normalizedSearchValueLowercase)) { + return false; + } + + const { labelHighlights, descriptionHighlights } = QuickOpenEntry.highlight(e, searchValue, true /* fuzzy highlight */); + e.setHighlights(labelHighlights, descriptionHighlights); + + return true; + }); + + return new QuickOpenModel(entries); + }); + } + + public getEmptyLabel(searchString: string): string { + return nls.localize('noWindowResults', "No matching opened windows found"); + } +} \ No newline at end of file -- GitLab From 85257c4de65307fd8ddbd8ac50dcbb28540d90a4 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Tue, 6 Jun 2017 11:29:15 +0200 Subject: [PATCH 0534/1347] Fix #27955 --- src/vs/workbench/parts/files/browser/explorerViewlet.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/files/browser/explorerViewlet.ts b/src/vs/workbench/parts/files/browser/explorerViewlet.ts index 2500f800ae7..59a054490ff 100644 --- a/src/vs/workbench/parts/files/browser/explorerViewlet.ts +++ b/src/vs/workbench/parts/files/browser/explorerViewlet.ts @@ -354,7 +354,9 @@ export class ExplorerViewlet extends Viewlet { return this.emptyView.focusBody(); } - return this.openEditorsView.focus(); + if (this.lastFocusedView) { + return this.lastFocusedView.focus(); + } } private hasSelectionOrFocus(view: IViewletView): boolean { -- GitLab From a7dee48b14207dc92a41105eeed51d73ff8b127a Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Tue, 6 Jun 2017 11:32:34 +0200 Subject: [PATCH 0535/1347] tweak menu (for #25145) --- src/vs/code/electron-main/menus.ts | 8 +++++--- src/vs/workbench/electron-browser/actions.ts | 2 +- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index 3a5aa4756e5..dc6c05f0d49 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -485,7 +485,7 @@ export class VSCodeMenu { revertFile, closeEditor, closeFolder, - !isMacintosh ? closeWindow : null, + closeWindow, !isMacintosh ? __separator__() : null, !isMacintosh ? exit : null ]).forEach(item => fileMenu.append(item)); @@ -898,12 +898,14 @@ export class VSCodeMenu { private setMacWindowMenu(macWindowMenu: Electron.Menu): void { const minimize = new MenuItem({ label: nls.localize('mMinimize', "Minimize"), role: 'minimize', accelerator: 'Command+M', enabled: this.windowsService.getWindowCount() > 0 }); - const close = new MenuItem({ label: nls.localize('mClose', "Close"), role: 'close', accelerator: 'Command+W', enabled: this.windowsService.getWindowCount() > 0 }); + const zoom = new MenuItem({ label: nls.localize('mZoom', "Zoom"), role: 'zoom', enabled: this.windowsService.getWindowCount() > 0 }); const bringAllToFront = new MenuItem({ label: nls.localize('mBringToFront', "Bring All to Front"), role: 'front', enabled: this.windowsService.getWindowCount() > 0 }); + const switchWindow = this.createMenuItem(nls.localize({ key: 'miSwitchWindow', comment: ['&& denotes a mnemonic'] }, "Switch &&Window..."), 'workbench.action.switchWindow', this.windowsService.getWindowCount() > 0); [ minimize, - close, + zoom, + switchWindow, __separator__(), bringAllToFront ].forEach(item => macWindowMenu.append(item)); diff --git a/src/vs/workbench/electron-browser/actions.ts b/src/vs/workbench/electron-browser/actions.ts index 05eac607208..f538efb3bf3 100644 --- a/src/vs/workbench/electron-browser/actions.ts +++ b/src/vs/workbench/electron-browser/actions.ts @@ -84,7 +84,7 @@ export class CloseWindowAction extends Action { export class SwitchWindow extends QuickOpenAction { static ID = 'workbench.action.switchWindow'; - static LABEL = nls.localize('switchWindow', "Switch Window"); + static LABEL = nls.localize('switchWindow', "Switch Window..."); constructor( id: string, -- GitLab From 14adf4bb46f407b325fd07c86fad1e2a076d4425 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Tue, 6 Jun 2017 11:44:38 +0200 Subject: [PATCH 0536/1347] always have a representedFilename --- src/vs/code/electron-main/window.ts | 17 +++++++++++++++++ .../windows/electron-main/windowsService.ts | 9 ++------- src/vs/workbench/electron-browser/window.ts | 12 +++++------- 3 files changed, 24 insertions(+), 14 deletions(-) diff --git a/src/vs/code/electron-main/window.ts b/src/vs/code/electron-main/window.ts index b4151b960d3..71d26108b0c 100644 --- a/src/vs/code/electron-main/window.ts +++ b/src/vs/code/electron-main/window.ts @@ -155,6 +155,7 @@ export class VSCodeWindow { private currentMenuBarVisibility: MenuBarVisibility; private currentWindowMode: WindowMode; private toDispose: IDisposable[]; + private representedFilename: string; private whenReadyCallbacks: TValueCallback[]; @@ -311,6 +312,22 @@ export class VSCodeWindow { return this._win; } + public setRepresentedFilename(filename: string): void { + if (platform.isMacintosh) { + this.win.setRepresentedFilename(filename); + } else { + this.representedFilename = filename; + } + } + + public getRepresentedFilename(): string { + if (platform.isMacintosh) { + return this.win.getRepresentedFilename(); + } + + return this.representedFilename; + } + public focus(): void { if (!this._win) { return; diff --git a/src/vs/platform/windows/electron-main/windowsService.ts b/src/vs/platform/windows/electron-main/windowsService.ts index 096386c0f5e..9d147b623ca 100644 --- a/src/vs/platform/windows/electron-main/windowsService.ts +++ b/src/vs/platform/windows/electron-main/windowsService.ts @@ -16,7 +16,6 @@ import Event, { chain } from 'vs/base/common/event'; import { fromEventEmitter } from 'vs/base/node/event'; import { IURLService } from 'vs/platform/url/common/url'; import { ITelemetryData } from 'vs/platform/telemetry/common/telemetry'; -import { isMacintosh } from "vs/base/common/platform"; import { OpenContext } from 'vs/code/common/windows'; // TODO@Joao: remove this dependency, move all implementation to this class import { IWindowsMainService } from 'vs/code/electron-main/windows'; import { ILifecycleService } from "vs/code/electron-main/lifecycle"; @@ -124,7 +123,7 @@ export class WindowsService implements IWindowsService, IDisposable { const vscodeWindow = this.windowsMainService.getWindowById(windowId); if (vscodeWindow) { - vscodeWindow.win.setRepresentedFilename(fileName); + vscodeWindow.setRepresentedFilename(fileName); } return TPromise.as(null); @@ -254,11 +253,7 @@ export class WindowsService implements IWindowsService, IDisposable { getWindows(): TPromise<{ id: number; path: string; title: string; }[]> { const windows = this.windowsMainService.getWindows(); - const result = windows.map(w => { - const filename = isMacintosh ? w.win.getRepresentedFilename() : void 0; - - return { path: w.openedWorkspacePath, title: w.win.getTitle(), id: w.id, filename }; - }); + const result = windows.map(w => ({ path: w.openedWorkspacePath, title: w.win.getTitle(), id: w.id, filename: w.getRepresentedFilename() })); return TPromise.as(result); } diff --git a/src/vs/workbench/electron-browser/window.ts b/src/vs/workbench/electron-browser/window.ts index e0eb6f23dfe..a604e215ea5 100644 --- a/src/vs/workbench/electron-browser/window.ts +++ b/src/vs/workbench/electron-browser/window.ts @@ -98,14 +98,12 @@ export class ElectronWindow extends Themable { private registerListeners(): void { - // React to editor input changes (Mac only) - if (platform.platform === platform.Platform.Mac) { - this.editorGroupService.onEditorsChanged(() => { - const file = toResource(this.editorService.getActiveEditorInput(), { supportSideBySide: true, filter: 'file' }); + // React to editor input changes + this.editorGroupService.onEditorsChanged(() => { + const file = toResource(this.editorService.getActiveEditorInput(), { supportSideBySide: true, filter: 'file' }); - this.titleService.setRepresentedFilename(file ? file.fsPath : ''); - }); - } + this.titleService.setRepresentedFilename(file ? file.fsPath : ''); + }); let draggedExternalResources: URI[]; let dropOverlay: Builder; -- GitLab From 70deb179d4f1044b868133a011d58c0fdc393741 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Tue, 6 Jun 2017 11:51:06 +0200 Subject: [PATCH 0537/1347] inputs: open context menu where mouse is --- src/vs/code/electron-main/window.ts | 34 ++++++++++----------- src/vs/workbench/electron-browser/window.ts | 2 +- 2 files changed, 18 insertions(+), 18 deletions(-) diff --git a/src/vs/code/electron-main/window.ts b/src/vs/code/electron-main/window.ts index 71d26108b0c..9d40c049ad7 100644 --- a/src/vs/code/electron-main/window.ts +++ b/src/vs/code/electron-main/window.ts @@ -6,7 +6,6 @@ 'use strict'; import * as path from 'path'; -import * as platform from 'vs/base/common/platform'; import * as objects from 'vs/base/common/objects'; import { stopProfiling } from 'vs/base/node/profiler'; import nls = require('vs/nls'); @@ -23,6 +22,7 @@ import { getCommonHTTPHeaders } from 'vs/platform/environment/node/http'; import { IWindowSettings, MenuBarVisibility } from 'vs/platform/windows/common/windows'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { KeyboardLayoutMonitor } from 'vs/code/node/keyboard'; +import { IProcessEnvironment, isLinux, isMacintosh, isWindows } from "vs/base/common/platform"; export interface IWindowState { width?: number; @@ -76,7 +76,7 @@ export interface IWindowConfiguration extends ParsedArgs { appRoot: string; execPath: string; - userEnv: platform.IProcessEnvironment; + userEnv: IProcessEnvironment; /** * The physical keyboard is of ISO type (on OSX). @@ -199,7 +199,7 @@ export class VSCodeWindow { } }; - if (platform.isLinux) { + if (isLinux) { options.icon = path.join(this.environmentService.appRoot, 'resources/linux/code.png'); // Windows and Mac are better off using the embedded icon(s) } @@ -212,7 +212,7 @@ export class VSCodeWindow { } let useCustomTitleStyle = false; - if (platform.isMacintosh && (!windowConfig || !windowConfig.titleBarStyle || windowConfig.titleBarStyle === 'custom')) { + if (isMacintosh && (!windowConfig || !windowConfig.titleBarStyle || windowConfig.titleBarStyle === 'custom')) { const isDev = !this.environmentService.isBuilt || !!config.extensionDevelopmentPath; if (!isDev) { useCustomTitleStyle = true; // not enabled when developing due to https://github.com/electron/electron/issues/3647 @@ -237,7 +237,7 @@ export class VSCodeWindow { } // Set relaunch command - if (platform.isWindows && product.win32AppUserModelId && typeof this._win.setAppDetails === 'function') { + if (isWindows && product.win32AppUserModelId && typeof this._win.setAppDetails === 'function') { this._win.setAppDetails({ appId: product.win32AppUserModelId, relaunchCommand: `"${process.execPath}" -n`, @@ -313,7 +313,7 @@ export class VSCodeWindow { } public setRepresentedFilename(filename: string): void { - if (platform.isMacintosh) { + if (isMacintosh) { this.win.setRepresentedFilename(filename); } else { this.representedFilename = filename; @@ -321,7 +321,7 @@ export class VSCodeWindow { } public getRepresentedFilename(): string { - if (platform.isMacintosh) { + if (isMacintosh) { return this.win.getRepresentedFilename(); } @@ -440,7 +440,7 @@ export class VSCodeWindow { }); // React to HC color scheme changes (Windows) - if (platform.isWindows) { + if (isWindows) { systemPreferences.on('inverted-color-scheme-changed', () => { if (systemPreferences.isInvertedColorScheme()) { this.sendWhenReady('vscode:enterHighContrast'); @@ -477,7 +477,7 @@ export class VSCodeWindow { } // Swipe command support (macOS) - if (platform.isMacintosh) { + if (isMacintosh) { const config = this.configurationService.getConfiguration(); if (config && config.workbench && config.workbench.editor && config.workbench.editor.swipeToNavigate) { this.registerNavigationListenerOn('swipe', 'left', 'right', true); @@ -505,7 +505,7 @@ export class VSCodeWindow { } // Make sure to clear any previous edited state - if (platform.isMacintosh && this._win.isDocumentEdited()) { + if (isMacintosh && this._win.isDocumentEdited()) { this._win.setDocumentEdited(false); } @@ -569,7 +569,7 @@ export class VSCodeWindow { windowConfiguration.fullscreen = this._win.isFullScreen(); // Set Accessibility Config - windowConfiguration.highContrast = platform.isWindows && systemPreferences.isInvertedColorScheme() && (!windowConfig || windowConfig.autoDetectHighContrast); + windowConfiguration.highContrast = isWindows && systemPreferences.isInvertedColorScheme() && (!windowConfig || windowConfig.autoDetectHighContrast); windowConfiguration.accessibilitySupport = app.isAccessibilitySupportEnabled(); // Set Keyboard Config @@ -599,7 +599,7 @@ export class VSCodeWindow { } private getBaseTheme(): string { - if (platform.isWindows && systemPreferences.isInvertedColorScheme()) { + if (isWindows && systemPreferences.isInvertedColorScheme()) { return 'hc-black'; } const theme = this.storageService.getItem(VSCodeWindow.themeStorageKey, 'vs-dark'); @@ -607,14 +607,14 @@ export class VSCodeWindow { } private getBackgroundColor(): string { - if (platform.isWindows && systemPreferences.isInvertedColorScheme()) { + if (isWindows && systemPreferences.isInvertedColorScheme()) { return '#000000'; } let background = this.storageService.getItem(VSCodeWindow.themeBackgroundStorageKey, null); if (!background) { let baseTheme = this.getBaseTheme(); - return baseTheme === 'hc-black' ? '#000000' : (baseTheme === 'vs' ? '#FFFFFF' : (platform.isMacintosh ? '#171717' : '#1E1E1E')); // https://github.com/electron/electron/issues/5150 + return baseTheme === 'hc-black' ? '#000000' : (baseTheme === 'vs' ? '#FFFFFF' : (isMacintosh ? '#171717' : '#1E1E1E')); // https://github.com/electron/electron/issues/5150 } return background; @@ -642,7 +642,7 @@ export class VSCodeWindow { let mode: WindowMode; // get window mode - if (!platform.isMacintosh && this._win.isMaximized()) { + if (!isMacintosh && this._win.isMaximized()) { mode = WindowMode.Maximized; } else { mode = WindowMode.Normal; @@ -800,7 +800,7 @@ export class VSCodeWindow { } public setMenuBarVisibility(visibility: MenuBarVisibility, notify: boolean = true): void { - if (platform.isMacintosh) { + if (isMacintosh) { return; // ignore for macOS platform } @@ -843,7 +843,7 @@ export class VSCodeWindow { public onWindowTitleDoubleClick(): void { // Respect system settings on mac with regards to title click on windows title - if (platform.isMacintosh) { + if (isMacintosh) { const action = systemPreferences.getUserDefault('AppleActionOnDoubleClick', 'string'); switch (action) { case 'Minimize': diff --git a/src/vs/workbench/electron-browser/window.ts b/src/vs/workbench/electron-browser/window.ts index a604e215ea5..d76662cdc5b 100644 --- a/src/vs/workbench/electron-browser/window.ts +++ b/src/vs/workbench/electron-browser/window.ts @@ -335,7 +335,7 @@ export class ElectronWindow extends Themable { e.stopPropagation(); this.contextMenuService.showContextMenu({ - getAnchor: () => target, + getAnchor: () => e, getActions: () => TPromise.as(TextInputActions) }); } -- GitLab From 552c80be2d0236d021021c819bb59a235df5e35b Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Tue, 6 Jun 2017 11:54:45 +0200 Subject: [PATCH 0538/1347] Fixes #28064: Use editor's configured line height for textarea's line height --- .../browser/controller/textAreaHandler.ts | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/src/vs/editor/browser/controller/textAreaHandler.ts b/src/vs/editor/browser/controller/textAreaHandler.ts index e927fcb4ab1..ec417fd436c 100644 --- a/src/vs/editor/browser/controller/textAreaHandler.ts +++ b/src/vs/editor/browser/controller/textAreaHandler.ts @@ -421,7 +421,24 @@ export class TextAreaHandler extends ViewPart { ta.setFontSize(1); // Chrome does not generate input events in empty textareas that end // up having a line height smaller than 1 screen pixel. - ta.setLineHeight(Math.ceil(Math.max(this._pixelRatio, 1 / this._pixelRatio))); + + // The problem is that I could not find any formula to explain how Chromium converts css px to screen px in the DOM. + // Observed values on a retina screen (by taking screenshots): + // |--------|-----------|------------|------------|-----------| + // | css px | zoomLevel | zoomFactor | pixelRatio | screen px | + // |--------|-----------|------------|------------|-----------| + // | 18 | -8 | 0.2325 | 0.5000 | 8 | + // | 18 | -7 | 0.2790 | 0.5581 | 10 | + // | 18 | -6 | 0.3348 | 0.6697 | 12 | + // | 18 | -5 | 0.4018 | 0.8037 | 14 | + // | 18 | -4 | 0.4822 | 0.9645 | 18 | + // | 18 | -3 | 0.5787 | 1.1574 | 20 | + // | 18 | -2 | 0.6944 | 1.3888 | 26 | + // | 18 | -1 | 0.8333 | 1.6666 | 30 | + // | 18 | 0 | 1.0000 | 2.0000 | 36 | + // |--------|-----------|------------|------------|-----------| + + ta.setLineHeight(this._fontInfo.lineHeight); } ta.setTop(top); -- GitLab From a8c7eaf7d1b759417c5d1b4c0c98b74fe568a0e8 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Tue, 6 Jun 2017 11:57:23 +0200 Subject: [PATCH 0539/1347] align command alias with labels --- .../browser/actions/toggleSidebarPosition.ts | 2 +- .../browser/parts/editor/editor.contribution.ts | 8 ++++---- .../workbench/browser/parts/panel/panelActions.ts | 2 +- .../electron-browser/main.contribution.ts | 6 +++--- .../toggleRenderControlCharacter.ts | 2 +- .../debug/electron-browser/debug.contribution.ts | 4 ++-- .../electron-browser/extensions.contribution.ts | 14 +++++++------- .../browser/preferences.contribution.ts | 2 +- .../quickopen/browser/quickopen.contribution.ts | 2 +- .../parts/scm/electron-browser/scm.contribution.ts | 2 +- .../electron-browser/snippets.contribution.ts | 2 +- .../tasks/electron-browser/task.contribution.ts | 2 +- .../electron-browser/terminal.contribution.ts | 2 +- .../update/electron-browser/update.contribution.ts | 2 +- .../welcome/overlay/browser/welcomeOverlay.ts | 2 +- 15 files changed, 27 insertions(+), 27 deletions(-) diff --git a/src/vs/workbench/browser/actions/toggleSidebarPosition.ts b/src/vs/workbench/browser/actions/toggleSidebarPosition.ts index 57364bd9188..63036b94c5e 100644 --- a/src/vs/workbench/browser/actions/toggleSidebarPosition.ts +++ b/src/vs/workbench/browser/actions/toggleSidebarPosition.ts @@ -42,4 +42,4 @@ export class ToggleSidebarPositionAction extends Action { } const registry = Registry.as(Extensions.WorkbenchActions); -registry.registerWorkbenchAction(new SyncActionDescriptor(ToggleSidebarPositionAction, ToggleSidebarPositionAction.ID, ToggleSidebarPositionAction.LABEL), 'View: Toggle Side Bar Position', nls.localize('view', "View")); \ No newline at end of file +registry.registerWorkbenchAction(new SyncActionDescriptor(ToggleSidebarPositionAction, ToggleSidebarPositionAction.ID, ToggleSidebarPositionAction.LABEL), 'View: Toggle Side Bar Location', nls.localize('view', "View")); \ No newline at end of file diff --git a/src/vs/workbench/browser/parts/editor/editor.contribution.ts b/src/vs/workbench/browser/parts/editor/editor.contribution.ts index 7e8aa1bae2b..8c6275f0b55 100644 --- a/src/vs/workbench/browser/parts/editor/editor.contribution.ts +++ b/src/vs/workbench/browser/parts/editor/editor.contribution.ts @@ -315,9 +315,9 @@ Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpen // Register Editor Actions const category = nls.localize('view', "View"); registry.registerWorkbenchAction(new SyncActionDescriptor(OpenNextEditorInGroup, OpenNextEditorInGroup.ID, OpenNextEditorInGroup.LABEL), 'View: Open Next Editor in Group', category); -registry.registerWorkbenchAction(new SyncActionDescriptor(OpenPreviousEditorInGroup, OpenPreviousEditorInGroup.ID, OpenPreviousEditorInGroup.LABEL), 'View: Open Next Recently Used Editor in Group', category); -registry.registerWorkbenchAction(new SyncActionDescriptor(OpenNextRecentlyUsedEditorAction, OpenNextRecentlyUsedEditorAction.ID, OpenNextRecentlyUsedEditorAction.LABEL), 'View: Open Next Recently Used Editor'); -registry.registerWorkbenchAction(new SyncActionDescriptor(OpenPreviousRecentlyUsedEditorAction, OpenPreviousRecentlyUsedEditorAction.ID, OpenPreviousRecentlyUsedEditorAction.LABEL), 'View: Open Previous Recently Used Editor'); +registry.registerWorkbenchAction(new SyncActionDescriptor(OpenPreviousEditorInGroup, OpenPreviousEditorInGroup.ID, OpenPreviousEditorInGroup.LABEL), 'View: Open Previous Editor in Group', category); +registry.registerWorkbenchAction(new SyncActionDescriptor(OpenNextRecentlyUsedEditorAction, OpenNextRecentlyUsedEditorAction.ID, OpenNextRecentlyUsedEditorAction.LABEL), 'View: Open Next Recently Used Editor', category); +registry.registerWorkbenchAction(new SyncActionDescriptor(OpenPreviousRecentlyUsedEditorAction, OpenPreviousRecentlyUsedEditorAction.ID, OpenPreviousRecentlyUsedEditorAction.LABEL), 'View: Open Previous Recently Used Editor', category); registry.registerWorkbenchAction(new SyncActionDescriptor(OpenNextRecentlyUsedEditorInGroupAction, OpenNextRecentlyUsedEditorInGroupAction.ID, OpenNextRecentlyUsedEditorInGroupAction.LABEL, { primary: KeyMod.CtrlCmd | KeyCode.Tab, mac: { primary: KeyMod.WinCtrl | KeyCode.Tab } }), 'Open Next Recently Used Editor in Group'); registry.registerWorkbenchAction(new SyncActionDescriptor(OpenPreviousRecentlyUsedEditorInGroupAction, OpenPreviousRecentlyUsedEditorInGroupAction.ID, OpenPreviousRecentlyUsedEditorInGroupAction.LABEL, { primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.Tab, mac: { primary: KeyMod.WinCtrl | KeyMod.Shift | KeyCode.Tab } }), 'Open Previous Recently Used Editor in Group'); registry.registerWorkbenchAction(new SyncActionDescriptor(ShowAllEditorsAction, ShowAllEditorsAction.ID, ShowAllEditorsAction.LABEL, { primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KEY_K, KeyMod.CtrlCmd | KeyCode.KEY_P), mac: { primary: KeyMod.CtrlCmd | KeyMod.Alt | KeyCode.Tab } }), 'View: Show All Editors', category); @@ -342,7 +342,7 @@ registry.registerWorkbenchAction(new SyncActionDescriptor(FocusActiveGroupAction registry.registerWorkbenchAction(new SyncActionDescriptor(FocusFirstGroupAction, FocusFirstGroupAction.ID, FocusFirstGroupAction.LABEL, { primary: KeyMod.CtrlCmd | KeyCode.KEY_1 }), 'View: Focus First Editor Group', category); registry.registerWorkbenchAction(new SyncActionDescriptor(FocusSecondGroupAction, FocusSecondGroupAction.ID, FocusSecondGroupAction.LABEL, { primary: KeyMod.CtrlCmd | KeyCode.KEY_2 }), 'View: Focus Second Editor Group', category); registry.registerWorkbenchAction(new SyncActionDescriptor(FocusThirdGroupAction, FocusThirdGroupAction.ID, FocusThirdGroupAction.LABEL, { primary: KeyMod.CtrlCmd | KeyCode.KEY_3 }), 'View: Focus Third Editor Group', category); -registry.registerWorkbenchAction(new SyncActionDescriptor(FocusLastEditorInStackAction, FocusLastEditorInStackAction.ID, FocusLastEditorInStackAction.LABEL, { primary: KeyMod.Alt | KeyCode.KEY_0, mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_0 } }), 'View: Focus Last Editor in Group', category); +registry.registerWorkbenchAction(new SyncActionDescriptor(FocusLastEditorInStackAction, FocusLastEditorInStackAction.ID, FocusLastEditorInStackAction.LABEL, { primary: KeyMod.Alt | KeyCode.KEY_0, mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_0 } }), 'View: Open Last Editor in Group', category); registry.registerWorkbenchAction(new SyncActionDescriptor(EvenGroupWidthsAction, EvenGroupWidthsAction.ID, EvenGroupWidthsAction.LABEL), 'View: Even Editor Group Widths', category); registry.registerWorkbenchAction(new SyncActionDescriptor(MaximizeGroupAction, MaximizeGroupAction.ID, MaximizeGroupAction.LABEL), 'View: Maximize Editor Group and Hide Sidebar', category); registry.registerWorkbenchAction(new SyncActionDescriptor(MinimizeOtherGroupsAction, MinimizeOtherGroupsAction.ID, MinimizeOtherGroupsAction.LABEL), 'View: Minimize Other Editor Groups', category); diff --git a/src/vs/workbench/browser/parts/panel/panelActions.ts b/src/vs/workbench/browser/parts/panel/panelActions.ts index 8ef9ca2e6db..fb50f93eb53 100644 --- a/src/vs/workbench/browser/parts/panel/panelActions.ts +++ b/src/vs/workbench/browser/parts/panel/panelActions.ts @@ -150,7 +150,7 @@ export class ToggleMaximizedPanelAction extends Action { } const actionRegistry = Registry.as(WorkbenchExtensions.WorkbenchActions); -actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(TogglePanelAction, TogglePanelAction.ID, TogglePanelAction.LABEL, { primary: KeyMod.CtrlCmd | KeyCode.KEY_J }), 'View: Toggle Panel Visibility', nls.localize('view', "View")); +actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(TogglePanelAction, TogglePanelAction.ID, TogglePanelAction.LABEL, { primary: KeyMod.CtrlCmd | KeyCode.KEY_J }), 'View: Toggle Panel', nls.localize('view', "View")); actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(FocusPanelAction, FocusPanelAction.ID, FocusPanelAction.LABEL), 'View: Focus into Panel', nls.localize('view', "View")); actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(ToggleMaximizedPanelAction, ToggleMaximizedPanelAction.ID, ToggleMaximizedPanelAction.LABEL), 'View: Toggle Maximized Panel', nls.localize('view', "View")); actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(ClosePanelAction, ClosePanelAction.ID, ClosePanelAction.LABEL), 'View: Close Panel', nls.localize('view', "View")); \ No newline at end of file diff --git a/src/vs/workbench/electron-browser/main.contribution.ts b/src/vs/workbench/electron-browser/main.contribution.ts index 7e293e56bbb..f53c0ee723b 100644 --- a/src/vs/workbench/electron-browser/main.contribution.ts +++ b/src/vs/workbench/electron-browser/main.contribution.ts @@ -35,7 +35,7 @@ workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(Switch workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(CloseFolderAction, CloseFolderAction.ID, CloseFolderAction.LABEL, { primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KEY_K, KeyCode.KEY_F) }), 'File: Close Folder', fileCategory); if (!!product.reportIssueUrl) { workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(ReportIssueAction, ReportIssueAction.ID, ReportIssueAction.LABEL), 'Help: Report Issues', helpCategory); - workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(ReportPerformanceIssueAction, ReportPerformanceIssueAction.ID, ReportPerformanceIssueAction.LABEL), 'Help: Report Performance Issues', helpCategory); + workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(ReportPerformanceIssueAction, ReportPerformanceIssueAction.ID, ReportPerformanceIssueAction.LABEL), 'Help: Report Performance Issue', helpCategory); } if (KeybindingsReferenceAction.AVAILABLE) { workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(KeybindingsReferenceAction, KeybindingsReferenceAction.ID, KeybindingsReferenceAction.LABEL, { primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KEY_K, KeyMod.CtrlCmd | KeyCode.KEY_R) }), 'Help: Keyboard Shortcuts Reference', helpCategory); @@ -74,8 +74,8 @@ workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(Naviga workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(NavigateLeftAction, NavigateLeftAction.ID, NavigateLeftAction.LABEL, null), 'View: Move to the View on the Left', viewCategory); workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(NavigateRightAction, NavigateRightAction.ID, NavigateRightAction.LABEL, null), 'View: Move to the View on the Right', viewCategory); -workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(IncreaseViewSizeAction, IncreaseViewSizeAction.ID, IncreaseViewSizeAction.LABEL, null), 'View: Increase View Size', viewCategory); -workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(DecreaseViewSizeAction, DecreaseViewSizeAction.ID, DecreaseViewSizeAction.LABEL, null), 'View: Decrease View Size', viewCategory); +workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(IncreaseViewSizeAction, IncreaseViewSizeAction.ID, IncreaseViewSizeAction.LABEL, null), 'View: Increase Current View Size', viewCategory); +workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(DecreaseViewSizeAction, DecreaseViewSizeAction.ID, DecreaseViewSizeAction.LABEL, null), 'View: Decrease Current View Size', viewCategory); // Developer related actions const developerCategory = nls.localize('developer', "Developer"); diff --git a/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderControlCharacter.ts b/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderControlCharacter.ts index 584821e2d3a..7428c61dc87 100644 --- a/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderControlCharacter.ts +++ b/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderControlCharacter.ts @@ -16,7 +16,7 @@ export class ToggleRenderControlCharacterAction extends EditorAction { super({ id: 'editor.action.toggleRenderControlCharacter', label: nls.localize('toggleRenderControlCharacters', "Toggle Control Characters"), - alias: 'Toggle Render Control Characters', + alias: 'Toggle Control Characters', precondition: null }); } diff --git a/src/vs/workbench/parts/debug/electron-browser/debug.contribution.ts b/src/vs/workbench/parts/debug/electron-browser/debug.contribution.ts index 22c7191e517..947763e0255 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debug.contribution.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debug.contribution.ts @@ -127,9 +127,9 @@ registry.registerWorkbenchAction(new SyncActionDescriptor(RunAction, RunAction.I registry.registerWorkbenchAction(new SyncActionDescriptor(RemoveAllBreakpointsAction, RemoveAllBreakpointsAction.ID, RemoveAllBreakpointsAction.LABEL), 'Debug: Remove All Breakpoints', debugCategory); registry.registerWorkbenchAction(new SyncActionDescriptor(EnableAllBreakpointsAction, EnableAllBreakpointsAction.ID, EnableAllBreakpointsAction.LABEL), 'Debug: Enable All Breakpoints', debugCategory); registry.registerWorkbenchAction(new SyncActionDescriptor(DisableAllBreakpointsAction, DisableAllBreakpointsAction.ID, DisableAllBreakpointsAction.LABEL), 'Debug: Disable All Breakpoints', debugCategory); -registry.registerWorkbenchAction(new SyncActionDescriptor(ClearReplAction, ClearReplAction.ID, ClearReplAction.LABEL), 'Debug: Clear Debug Console', debugCategory); +registry.registerWorkbenchAction(new SyncActionDescriptor(ClearReplAction, ClearReplAction.ID, ClearReplAction.LABEL), 'Debug: Clear Console', debugCategory); registry.registerWorkbenchAction(new SyncActionDescriptor(FocusReplAction, FocusReplAction.ID, FocusReplAction.LABEL), 'Debug: Focus Debug Console', debugCategory); -registry.registerWorkbenchAction(new SyncActionDescriptor(SelectAndStartAction, SelectAndStartAction.ID, SelectAndStartAction.LABEL), 'Debug: Launch Configuration', debugCategory); +registry.registerWorkbenchAction(new SyncActionDescriptor(SelectAndStartAction, SelectAndStartAction.ID, SelectAndStartAction.LABEL), 'Debug: Select and Start Debugging', debugCategory); // Register Quick Open (Registry.as(QuickOpenExtensions.Quickopen)).registerQuickOpenHandler( diff --git a/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.ts b/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.ts index 74161d1c27c..34b56a366bb 100644 --- a/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.ts +++ b/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.ts @@ -105,7 +105,7 @@ const openViewletActionDescriptor = new SyncActionDescriptor(OpenExtensionsViewl actionRegistry.registerWorkbenchAction(openViewletActionDescriptor, 'View: Show Extensions', localize('view', "View")); const installActionDescriptor = new SyncActionDescriptor(InstallExtensionsAction, InstallExtensionsAction.ID, InstallExtensionsAction.LABEL); -actionRegistry.registerWorkbenchAction(installActionDescriptor, 'Extensions: Install', ExtensionsLabel); +actionRegistry.registerWorkbenchAction(installActionDescriptor, 'Extensions: Install Extensions', ExtensionsLabel); const listOutdatedActionDescriptor = new SyncActionDescriptor(ShowOutdatedExtensionsAction, ShowOutdatedExtensionsAction.ID, ShowOutdatedExtensionsAction.LABEL); actionRegistry.registerWorkbenchAction(listOutdatedActionDescriptor, 'Extensions: Show Outdated Extensions', ExtensionsLabel); @@ -117,7 +117,7 @@ const keymapRecommendationsActionDescriptor = new SyncActionDescriptor(ShowRecom actionRegistry.registerWorkbenchAction(keymapRecommendationsActionDescriptor, 'Preferences: Keymaps', PreferencesLabel); const languageExtensionsActionDescriptor = new SyncActionDescriptor(ShowLanguageExtensionsAction, ShowLanguageExtensionsAction.ID, ShowLanguageExtensionsAction.SHORT_LABEL); -actionRegistry.registerWorkbenchAction(languageExtensionsActionDescriptor, 'Extensions: Language Extensions', PreferencesLabel); +actionRegistry.registerWorkbenchAction(languageExtensionsActionDescriptor, 'Preferences: Language Extensions', PreferencesLabel); const workspaceRecommendationsActionDescriptor = new SyncActionDescriptor(ShowWorkspaceRecommendedExtensionsAction, ShowWorkspaceRecommendedExtensionsAction.ID, ShowWorkspaceRecommendedExtensionsAction.LABEL); actionRegistry.registerWorkbenchAction(workspaceRecommendationsActionDescriptor, 'Extensions: Show Workspace Recommended Extensions', ExtensionsLabel); @@ -138,22 +138,22 @@ const openExtensionsFolderActionDescriptor = new SyncActionDescriptor(OpenExtens actionRegistry.registerWorkbenchAction(openExtensionsFolderActionDescriptor, 'Extensions: Open Extensions Folder', ExtensionsLabel); const openExtensionsFileActionDescriptor = new SyncActionDescriptor(ConfigureWorkspaceRecommendedExtensionsAction, ConfigureWorkspaceRecommendedExtensionsAction.ID, ConfigureWorkspaceRecommendedExtensionsAction.LABEL); -actionRegistry.registerWorkbenchAction(openExtensionsFileActionDescriptor, 'Extensions: Open Extensions File', ExtensionsLabel); +actionRegistry.registerWorkbenchAction(openExtensionsFileActionDescriptor, 'Extensions: Configure Recommended Extensions (Workspace)', ExtensionsLabel); const installVSIXActionDescriptor = new SyncActionDescriptor(InstallVSIXAction, InstallVSIXAction.ID, InstallVSIXAction.LABEL); actionRegistry.registerWorkbenchAction(installVSIXActionDescriptor, 'Extensions: Install from VSIX...', ExtensionsLabel); const disableAllAction = new SyncActionDescriptor(DisableAllAction, DisableAllAction.ID, DisableAllAction.LABEL); -actionRegistry.registerWorkbenchAction(disableAllAction, 'Extensions: Disable All', ExtensionsLabel); +actionRegistry.registerWorkbenchAction(disableAllAction, 'Extensions: Disable All Installed Extensions', ExtensionsLabel); const disableAllWorkspaceAction = new SyncActionDescriptor(DisableAllWorkpsaceAction, DisableAllWorkpsaceAction.ID, DisableAllWorkpsaceAction.LABEL); -actionRegistry.registerWorkbenchAction(disableAllWorkspaceAction, 'Extensions: Disable All (Workspace)', ExtensionsLabel); +actionRegistry.registerWorkbenchAction(disableAllWorkspaceAction, 'Extensions: Disable All Installed Extensions for this Workspace', ExtensionsLabel); const enableAllAction = new SyncActionDescriptor(EnableAllAction, EnableAllAction.ID, EnableAllAction.LABEL); -actionRegistry.registerWorkbenchAction(enableAllAction, 'Extensions: Enable All', ExtensionsLabel); +actionRegistry.registerWorkbenchAction(enableAllAction, 'Extensions: Enable All Installed Extensions', ExtensionsLabel); const enableAllWorkspaceAction = new SyncActionDescriptor(EnableAllWorkpsaceAction, EnableAllWorkpsaceAction.ID, EnableAllWorkpsaceAction.LABEL); -actionRegistry.registerWorkbenchAction(enableAllWorkspaceAction, 'Extensions: Enable All (Workspace)', ExtensionsLabel); +actionRegistry.registerWorkbenchAction(enableAllWorkspaceAction, 'Extensions: Enable All Installed Extensions for this Workspace', ExtensionsLabel); const checkForUpdatesAction = new SyncActionDescriptor(CheckForUpdatesAction, CheckForUpdatesAction.ID, CheckForUpdatesAction.LABEL); actionRegistry.registerWorkbenchAction(checkForUpdatesAction, `Extensions: Check for Updates`, ExtensionsLabel); diff --git a/src/vs/workbench/parts/preferences/browser/preferences.contribution.ts b/src/vs/workbench/parts/preferences/browser/preferences.contribution.ts index 1c4f38ca6e9..872e9a7c1de 100644 --- a/src/vs/workbench/parts/preferences/browser/preferences.contribution.ts +++ b/src/vs/workbench/parts/preferences/browser/preferences.contribution.ts @@ -166,7 +166,7 @@ registry.registerWorkbenchAction(new SyncActionDescriptor(OpenGlobalSettingsActi registry.registerWorkbenchAction(new SyncActionDescriptor(OpenWorkspaceSettingsAction, OpenWorkspaceSettingsAction.ID, OpenWorkspaceSettingsAction.LABEL), 'Preferences: Open Workspace Settings', category); registry.registerWorkbenchAction(new SyncActionDescriptor(OpenGlobalKeybindingsAction, OpenGlobalKeybindingsAction.ID, OpenGlobalKeybindingsAction.LABEL, { primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KEY_K, KeyMod.CtrlCmd | KeyCode.KEY_S) }), 'Preferences: Open Keyboard Shortcuts', category); registry.registerWorkbenchAction(new SyncActionDescriptor(OpenGlobalKeybindingsFileAction, OpenGlobalKeybindingsFileAction.ID, OpenGlobalKeybindingsFileAction.LABEL, { primary: null }), 'Preferences: Open Keyboard Shortcuts File', category); -registry.registerWorkbenchAction(new SyncActionDescriptor(ConfigureLanguageBasedSettingsAction, ConfigureLanguageBasedSettingsAction.ID, ConfigureLanguageBasedSettingsAction.LABEL), 'Preferences: Configure Language Specific Settings', category); +registry.registerWorkbenchAction(new SyncActionDescriptor(ConfigureLanguageBasedSettingsAction, ConfigureLanguageBasedSettingsAction.ID, ConfigureLanguageBasedSettingsAction.LABEL), 'Preferences: Configure Language Specific Settings...', category); KeybindingsRegistry.registerCommandAndKeybindingRule({ id: KEYBINDINGS_EDITOR_COMMAND_DEFINE, diff --git a/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts b/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts index 154b5eb08c0..e659f567dd4 100644 --- a/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts +++ b/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts @@ -32,7 +32,7 @@ registry.registerWorkbenchAction(new SyncActionDescriptor(GotoLineAction, GotoLi registry.registerWorkbenchAction(new SyncActionDescriptor(GotoSymbolAction, GotoSymbolAction.ID, GotoSymbolAction.LABEL, { primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_O -}), 'Go to Symbol...'); +}), 'Go to Symbol in File...'); registry.registerWorkbenchAction(new SyncActionDescriptor(OpenViewPickerAction, OpenViewPickerAction.ID, OpenViewPickerAction.LABEL), 'Open View'); registry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenViewPickerAction, QuickOpenViewPickerAction.ID, QuickOpenViewPickerAction.LABEL, { diff --git a/src/vs/workbench/parts/scm/electron-browser/scm.contribution.ts b/src/vs/workbench/parts/scm/electron-browser/scm.contribution.ts index e4cedd1923c..045541ba0ea 100644 --- a/src/vs/workbench/parts/scm/electron-browser/scm.contribution.ts +++ b/src/vs/workbench/parts/scm/electron-browser/scm.contribution.ts @@ -101,4 +101,4 @@ Registry.as(WorkbenchActionExtensions.WorkbenchActions ); Registry.as(WorkbenchActionExtensions.WorkbenchActions) - .registerWorkbenchAction(new SyncActionDescriptor(SwitchProvider, SwitchProvider.ID, SwitchProvider.LABEL), 'SCM: Switch Provider', 'SCM'); + .registerWorkbenchAction(new SyncActionDescriptor(SwitchProvider, SwitchProvider.ID, SwitchProvider.LABEL), 'SCM: Switch SCM Provider', 'SCM'); diff --git a/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.ts b/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.ts index 2e69a2d456e..5abcf73825d 100644 --- a/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.ts +++ b/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.ts @@ -118,7 +118,7 @@ function fileExists(path: string): winjs.TPromise { var preferencesCategory = nls.localize('preferences', "Preferences"); var workbenchActionsRegistry = platform.Registry.as(workbenchActionRegistry.Extensions.WorkbenchActions); -workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(OpenSnippetsAction, OpenSnippetsAction.ID, OpenSnippetsAction.LABEL), 'Preferences: Snippets', preferencesCategory); +workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(OpenSnippetsAction, OpenSnippetsAction.ID, OpenSnippetsAction.LABEL), 'Preferences: Open User Snippets', preferencesCategory); (platform.Registry.as(workbenchContributions.Extensions.Workbench)).registerWorkbenchContribution( snippetsTracker.SnippetsTracker diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index 126ca11a1b8..5fea1fd052b 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -1368,7 +1368,7 @@ class TaskService extends EventEmitter implements ITaskService { let workbenchActionsRegistry = Registry.as(WorkbenchActionExtensions.WorkbenchActions); -workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(ConfigureTaskRunnerAction, ConfigureTaskRunnerAction.ID, ConfigureTaskRunnerAction.TEXT), 'Configure Task Runner', tasksCategory); +workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(ConfigureTaskRunnerAction, ConfigureTaskRunnerAction.ID, ConfigureTaskRunnerAction.TEXT), 'Tasks: Configure Task Runner', tasksCategory); MenuRegistry.addCommand({ id: 'workbench.action.tasks.showLog', title: { value: nls.localize('ShowLogAction.label', "Show Task Log"), original: 'Show Task Log' }, category: { value: tasksCategory, original: 'Tasks' } }); MenuRegistry.addCommand({ id: 'workbench.action.tasks.runTask', title: { value: nls.localize('RunTaskAction.label', "Run Task"), original: 'Run Task' }, category: { value: tasksCategory, original: 'Tasks' } }); diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts index 17e931a643b..94e7e9a4b52 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts @@ -217,7 +217,7 @@ actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(CreateNewTermina primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.US_BACKTICK, mac: { primary: KeyMod.WinCtrl | KeyMod.Shift | KeyCode.US_BACKTICK } }), 'Terminal: Create New Integrated Terminal', category); -actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(FocusActiveTerminalAction, FocusActiveTerminalAction.ID, FocusActiveTerminalAction.LABEL), 'Terminal: Focus Active Terminal', category); +actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(FocusActiveTerminalAction, FocusActiveTerminalAction.ID, FocusActiveTerminalAction.LABEL), 'Terminal: Focus Terminal', category); actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(FocusNextTerminalAction, FocusNextTerminalAction.ID, FocusNextTerminalAction.LABEL), 'Terminal: Focus Next Terminal', category); actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(FocusPreviousTerminalAction, FocusPreviousTerminalAction.ID, FocusPreviousTerminalAction.LABEL), 'Terminal: Focus Previous Terminal', category); for (let i = 1; i < 10; i++) { diff --git a/src/vs/workbench/parts/update/electron-browser/update.contribution.ts b/src/vs/workbench/parts/update/electron-browser/update.contribution.ts index 64bba795487..7e9a2bb60d2 100644 --- a/src/vs/workbench/parts/update/electron-browser/update.contribution.ts +++ b/src/vs/workbench/parts/update/electron-browser/update.contribution.ts @@ -44,7 +44,7 @@ Registry.as(EditorExtensions.Editors) .registerEditor(editorDescriptor, [new SyncDescriptor(ReleaseNotesInput)]); Registry.as(ActionExtensions.WorkbenchActions) - .registerWorkbenchAction(new SyncActionDescriptor(ShowCurrentReleaseNotesAction, ShowCurrentReleaseNotesAction.ID, ShowCurrentReleaseNotesAction.LABEL), 'Open Release Notes'); + .registerWorkbenchAction(new SyncActionDescriptor(ShowCurrentReleaseNotesAction, ShowCurrentReleaseNotesAction.ID, ShowCurrentReleaseNotesAction.LABEL), 'Show Release Notes'); // Configuration: Update const configurationRegistry = Registry.as(ConfigurationExtensions.Configuration); diff --git a/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.ts b/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.ts index 20c82ff7a7c..7d63156d89e 100644 --- a/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.ts +++ b/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.ts @@ -232,7 +232,7 @@ class WelcomeOverlay { } Registry.as(Extensions.WorkbenchActions) - .registerWorkbenchAction(new SyncActionDescriptor(WelcomeOverlayAction, WelcomeOverlayAction.ID, WelcomeOverlayAction.LABEL), 'Help: Show Interface Overview', localize('help', "Help")); + .registerWorkbenchAction(new SyncActionDescriptor(WelcomeOverlayAction, WelcomeOverlayAction.ID, WelcomeOverlayAction.LABEL), 'Help: User Interface Overview', localize('help', "Help")); Registry.as(Extensions.WorkbenchActions) .registerWorkbenchAction(new SyncActionDescriptor(HideWelcomeOverlayAction, HideWelcomeOverlayAction.ID, HideWelcomeOverlayAction.LABEL, { primary: KeyCode.Escape }, OVERLAY_VISIBLE), 'Help: Hide Interface Overview', localize('help', "Help")); -- GitLab From 0c125f9b6133fff011256a6465d086f759a457f1 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Tue, 6 Jun 2017 11:58:18 +0200 Subject: [PATCH 0540/1347] tweak path labels with environment --- src/vs/base/common/labels.ts | 12 ------------ .../browser/referencesController.ts | 6 ++++-- .../referenceSearch/browser/referencesWidget.ts | 5 +++-- src/vs/workbench/electron-browser/actions.ts | 12 +++++++----- .../parts/debug/electron-browser/debugViewer.ts | 17 +++++++++++------ .../preferences/browser/preferencesService.ts | 2 +- 6 files changed, 26 insertions(+), 28 deletions(-) diff --git a/src/vs/base/common/labels.ts b/src/vs/base/common/labels.ts index f2aeccb2109..efbe348a613 100644 --- a/src/vs/base/common/labels.ts +++ b/src/vs/base/common/labels.ts @@ -29,18 +29,6 @@ export interface IUserHomeProvider { userHome: string; } -export class PathLabelProvider implements ILabelProvider { - private root: string; - - constructor(arg1?: URI | string | IWorkspaceProvider) { - this.root = arg1 && getPath(arg1); - } - - public getLabel(arg1: URI | string | IWorkspaceProvider): string { - return getPathLabel(getPath(arg1), this.root); - } -} - export function getPathLabel(resource: URI | string, basePathProvider?: URI | string | IWorkspaceProvider, userHomeProvider?: IUserHomeProvider): string { const absolutePath = getPath(resource); if (!absolutePath) { diff --git a/src/vs/editor/contrib/referenceSearch/browser/referencesController.ts b/src/vs/editor/contrib/referenceSearch/browser/referencesController.ts index 140a7e3e0e8..c92079e5566 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referencesController.ts +++ b/src/vs/editor/contrib/referenceSearch/browser/referencesController.ts @@ -28,6 +28,7 @@ import { Range } from 'vs/editor/common/core/range'; import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { Position } from 'vs/editor/common/core/position'; +import { IEnvironmentService } from "vs/platform/environment/common/environment"; export const ctxReferenceSearchVisible = new RawContextKey('referenceSearchVisible', false); @@ -66,7 +67,8 @@ export class ReferencesController implements editorCommon.IEditorContribution { @IStorageService private _storageService: IStorageService, @IThemeService private _themeService: IThemeService, @IConfigurationService private _configurationService: IConfigurationService, - @optional(IPeekViewService) private _peekViewService: IPeekViewService + @optional(IPeekViewService) private _peekViewService: IPeekViewService, + @optional(IEnvironmentService) private _environmentService: IEnvironmentService ) { this._editor = editor; this._referenceSearchVisible = ctxReferenceSearchVisible.bindTo(contextKeyService); @@ -107,7 +109,7 @@ export class ReferencesController implements editorCommon.IEditorContribution { })); const storageKey = 'peekViewLayout'; const data = JSON.parse(this._storageService.get(storageKey, undefined, '{}')); - this._widget = new ReferenceWidget(this._editor, data, this._textModelResolverService, this._contextService, this._themeService, this._instantiationService); + this._widget = new ReferenceWidget(this._editor, data, this._textModelResolverService, this._contextService, this._themeService, this._instantiationService, this._environmentService); this._widget.setTitle(nls.localize('labelLoading', "Loading...")); this._widget.show(range); this._disposables.push(this._widget.onDidClose(() => { diff --git a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts index 959c2bc8939..2a5de66352a 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts +++ b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts @@ -539,7 +539,8 @@ export class ReferenceWidget extends PeekViewWidget { private _textModelResolverService: ITextModelResolverService, private _contextService: IWorkspaceContextService, private _themeService: IThemeService, - private _instantiationService: IInstantiationService + private _instantiationService: IInstantiationService, + private _environmentService: IEnvironmentService ) { super(editor, { showFrame: false, showArrow: true, isResizeable: true }); @@ -777,7 +778,7 @@ export class ReferenceWidget extends PeekViewWidget { // Update widget header if (reference.uri.scheme !== Schemas.inMemory) { - this.setTitle(reference.name, getPathLabel(reference.directory, this._contextService)); + this.setTitle(reference.name, getPathLabel(reference.directory, this._contextService, this._environmentService)); } else { this.setTitle(nls.localize('peekView.alternateTitle', "References")); } diff --git a/src/vs/workbench/electron-browser/actions.ts b/src/vs/workbench/electron-browser/actions.ts index f538efb3bf3..3dde6ba6ca7 100644 --- a/src/vs/workbench/electron-browser/actions.ts +++ b/src/vs/workbench/electron-browser/actions.ts @@ -39,6 +39,7 @@ import { SWITCH_WINDOWS_PREFIX } from "vs/workbench/electron-browser/windowPicke import * as os from 'os'; import { webFrame } from 'electron'; +import { getPathLabel } from "vs/base/common/labels"; // --- actions @@ -580,7 +581,8 @@ export class OpenRecentAction extends Action { @IWindowsService private windowsService: IWindowsService, @IWindowService private windowService: IWindowService, @IQuickOpenService private quickOpenService: IQuickOpenService, - @IWorkspaceContextService private contextService: IWorkspaceContextService + @IWorkspaceContextService private contextService: IWorkspaceContextService, + @IEnvironmentService private environmentService: IEnvironmentService ) { super(id, label); } @@ -591,12 +593,12 @@ export class OpenRecentAction extends Action { } private openRecent(recentFiles: string[], recentFolders: string[]): void { - function toPick(path: string, separator: ISeparator, isFolder: boolean): IFilePickOpenEntry { + function toPick(path: string, separator: ISeparator, isFolder: boolean, environmentService: IEnvironmentService): IFilePickOpenEntry { return { resource: URI.file(path), isFolder, label: paths.basename(path), - description: paths.dirname(path), + description: getPathLabel(paths.dirname(path), null, environmentService), separator, run: context => runPick(path, context) }; @@ -607,8 +609,8 @@ export class OpenRecentAction extends Action { this.windowsService.openWindow([path], { forceNewWindow }); }; - const folderPicks: IFilePickOpenEntry[] = recentFolders.map((p, index) => toPick(p, index === 0 ? { label: nls.localize('folders', "folders") } : void 0, true)); - const filePicks: IFilePickOpenEntry[] = recentFiles.map((p, index) => toPick(p, index === 0 ? { label: nls.localize('files', "files"), border: true } : void 0, false)); + const folderPicks: IFilePickOpenEntry[] = recentFolders.map((p, index) => toPick(p, index === 0 ? { label: nls.localize('folders', "folders") } : void 0, true, this.environmentService)); + const filePicks: IFilePickOpenEntry[] = recentFiles.map((p, index) => toPick(p, index === 0 ? { label: nls.localize('files', "files"), border: true } : void 0, false, this.environmentService)); const hasWorkspace = this.contextService.hasWorkspace(); diff --git a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts index caddb78c3d3..820660e4f1d 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts @@ -36,6 +36,7 @@ import { Source } from 'vs/workbench/parts/debug/common/debugSource'; import { once } from 'vs/base/common/functional'; import { attachInputBoxStyler } from 'vs/platform/theme/common/styler'; import { IThemeService } from 'vs/platform/theme/common/themeService'; +import { IEnvironmentService } from "vs/platform/environment/common/environment"; const $ = dom.$; const booleanRegex = /^true|false$/i; @@ -179,12 +180,12 @@ function renderRenameBox(debugService: debug.IDebugService, contextViewService: })); } -function getSourceName(source: Source, contextService: IWorkspaceContextService): string { +function getSourceName(source: Source, contextService: IWorkspaceContextService, environmentService?: IEnvironmentService): string { if (source.name) { return source.name; } - return getPathLabel(paths.basename(source.uri.fsPath), contextService); + return getPathLabel(paths.basename(source.uri.fsPath), contextService, environmentService); } export class BaseDebugController extends DefaultController { @@ -427,7 +428,10 @@ export class CallStackRenderer implements IRenderer { private static LOAD_MORE_TEMPLATE_ID = 'loadMore'; private static PROCESS_TEMPLATE_ID = 'process'; - constructor( @IWorkspaceContextService private contextService: IWorkspaceContextService) { + constructor( + @IWorkspaceContextService private contextService: IWorkspaceContextService, + @IEnvironmentService private environmentService: IEnvironmentService + ) { // noop } @@ -549,7 +553,7 @@ export class CallStackRenderer implements IRenderer { } data.label.textContent = stackFrame.name; data.label.title = stackFrame.name; - data.fileName.textContent = getSourceName(stackFrame.source, this.contextService); + data.fileName.textContent = getSourceName(stackFrame.source, this.contextService, this.environmentService); if (stackFrame.range.startLineNumber !== undefined) { data.lineNumber.textContent = `${stackFrame.range.startLineNumber}`; if (stackFrame.range.startColumn) { @@ -1107,7 +1111,8 @@ export class BreakpointsRenderer implements IRenderer { @IWorkspaceContextService private contextService: IWorkspaceContextService, @debug.IDebugService private debugService: debug.IDebugService, @IContextViewService private contextViewService: IContextViewService, - @IThemeService private themeService: IThemeService + @IThemeService private themeService: IThemeService, + @IEnvironmentService private environmentService: IEnvironmentService ) { // noop } @@ -1209,7 +1214,7 @@ export class BreakpointsRenderer implements IRenderer { if (breakpoint.column) { data.lineNumber.textContent += `:${breakpoint.column}`; } - data.filePath.textContent = getPathLabel(paths.dirname(breakpoint.uri.fsPath), this.contextService); + data.filePath.textContent = getPathLabel(paths.dirname(breakpoint.uri.fsPath), this.contextService, this.environmentService); data.checkbox.checked = breakpoint.enabled; const debugActive = this.debugService.state === debug.State.Running || this.debugService.state === debug.State.Stopped || this.debugService.state === debug.State.Initializing; diff --git a/src/vs/workbench/parts/preferences/browser/preferencesService.ts b/src/vs/workbench/parts/preferences/browser/preferencesService.ts index bb6d77f0d30..6f2fd27c01f 100644 --- a/src/vs/workbench/parts/preferences/browser/preferencesService.ts +++ b/src/vs/workbench/parts/preferences/browser/preferencesService.ts @@ -271,7 +271,7 @@ export class PreferencesService extends Disposable implements IPreferencesServic return this.fileService.resolveContent(resource, { acceptTextOnly: true }).then(null, error => { if ((error).fileOperationResult === FileOperationResult.FILE_NOT_FOUND) { return this.fileService.updateContent(resource, contents).then(null, error => { - return TPromise.wrapError(new Error(nls.localize('fail.createSettings', "Unable to create '{0}' ({1}).", labels.getPathLabel(resource, this.contextService), error))); + return TPromise.wrapError(new Error(nls.localize('fail.createSettings', "Unable to create '{0}' ({1}).", labels.getPathLabel(resource, this.contextService, this.environmentService), error))); }); } -- GitLab From 7df06724b89958cb975da1d9e43ea97807ff277a Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Tue, 6 Jun 2017 11:58:49 +0200 Subject: [PATCH 0541/1347] use tildify in more places --- src/vs/code/electron-main/menus.ts | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index dc6c05f0d49..4323e8ca2ca 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -24,6 +24,7 @@ import { IInstantiationService } from 'vs/platform/instantiation/common/instanti import Event, { Emitter, once } from 'vs/base/common/event'; import { ConfigWatcher } from 'vs/base/node/config'; import { IUserFriendlyKeybinding } from 'vs/platform/keybinding/common/keybinding'; +import { tildify } from "vs/base/common/labels"; interface IKeybinding { id: string; @@ -543,13 +544,8 @@ export class VSCodeMenu { } private createOpenRecentMenuItem(path: string, commandId: string): Electron.MenuItem { - let label = path; - if ((isMacintosh || isLinux) && path.indexOf(this.environmentService.userHome) === 0) { - label = `~${path.substr(this.environmentService.userHome.length)}`; - } - return new MenuItem(this.likeAction(commandId, { - label: this.unmnemonicLabel(label), click: (menuItem, win, event) => { + label: this.unmnemonicLabel(tildify(path, this.environmentService.userHome)), click: (menuItem, win, event) => { const openInNewWindow = this.isOptionClick(event); const success = !!this.windowsService.open({ context: OpenContext.MENU, cli: this.environmentService.args, pathsToOpen: [path], forceNewWindow: openInNewWindow }); if (!success) { -- GitLab From 90b78697adf7a21fb4be9bd5c50e1cf255133fba Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Tue, 6 Jun 2017 12:00:42 +0200 Subject: [PATCH 0542/1347] :lipstick: --- src/vs/workbench/electron-browser/actions.ts | 8 ++++---- src/vs/workbench/parts/debug/browser/debugActions.ts | 4 ++-- src/vs/workbench/parts/debug/browser/debugViewlet.ts | 6 +++--- .../parts/debug/electron-browser/debugCommands.ts | 2 +- .../electron-browser/debugConfigurationManager.ts | 6 +++--- .../parts/debug/electron-browser/debugService.ts | 10 +++++----- .../parts/tasks/node/processRunnerDetector.ts | 3 +-- .../services/textfile/common/textFileEditorModel.ts | 2 +- 8 files changed, 20 insertions(+), 21 deletions(-) diff --git a/src/vs/workbench/electron-browser/actions.ts b/src/vs/workbench/electron-browser/actions.ts index 3dde6ba6ca7..90bf406fd57 100644 --- a/src/vs/workbench/electron-browser/actions.ts +++ b/src/vs/workbench/electron-browser/actions.ts @@ -1037,7 +1037,7 @@ export abstract class BaseNavigationAction extends Action { export class NavigateLeftAction extends BaseNavigationAction { public static ID = 'workbench.action.navigateLeft'; - public static LABEL = nls.localize('navigateLeft', "Move to the View on the Left"); + public static LABEL = nls.localize('navigateLeft', "Navigate to the View on the Left"); constructor( id: string, @@ -1087,7 +1087,7 @@ export class NavigateLeftAction extends BaseNavigationAction { export class NavigateRightAction extends BaseNavigationAction { public static ID = 'workbench.action.navigateRight'; - public static LABEL = nls.localize('navigateRight', "Move to the View on the Right"); + public static LABEL = nls.localize('navigateRight', "Navigate to the View on the Right"); constructor( id: string, @@ -1137,7 +1137,7 @@ export class NavigateRightAction extends BaseNavigationAction { export class NavigateUpAction extends BaseNavigationAction { public static ID = 'workbench.action.navigateUp'; - public static LABEL = nls.localize('navigateUp', "Move to the View Above"); + public static LABEL = nls.localize('navigateUp', "Navigate to the View Above"); constructor( id: string, @@ -1168,7 +1168,7 @@ export class NavigateUpAction extends BaseNavigationAction { export class NavigateDownAction extends BaseNavigationAction { public static ID = 'workbench.action.navigateDown'; - public static LABEL = nls.localize('navigateDown', "Move to the View Below"); + public static LABEL = nls.localize('navigateDown', "Navigate to the View Below"); constructor( id: string, diff --git a/src/vs/workbench/parts/debug/browser/debugActions.ts b/src/vs/workbench/parts/debug/browser/debugActions.ts index 6a23b8588cd..159cbaf03b8 100644 --- a/src/vs/workbench/parts/debug/browser/debugActions.ts +++ b/src/vs/workbench/parts/debug/browser/debugActions.ts @@ -98,7 +98,7 @@ export class ConfigureAction extends AbstractDebugAction { } public run(event?: any): TPromise { - if (!this.contextService.getWorkspace()) { + if (!this.contextService.hasWorkspace()) { this.messageService.show(severity.Info, nls.localize('noFolderDebugConfig', "Please first open a folder in order to do advanced debug configuration.")); return TPromise.as(null); } @@ -137,7 +137,7 @@ export class StartAction extends AbstractDebugAction { const compound = this.debugService.getConfigurationManager().getCompound(this.debugService.getViewModel().selectedConfigurationName); return state !== State.Initializing && processes.every(p => p.name !== this.debugService.getViewModel().selectedConfigurationName) && (!compound || !compound.configurations || processes.every(p => compound.configurations.indexOf(p.name) === -1)) && - (!this.contextService || !!this.contextService.getWorkspace() || processes.length === 0); + (!this.contextService || this.contextService.hasWorkspace() || processes.length === 0); } } diff --git a/src/vs/workbench/parts/debug/browser/debugViewlet.ts b/src/vs/workbench/parts/debug/browser/debugViewlet.ts index a36d3128022..07d674a0d16 100644 --- a/src/vs/workbench/parts/debug/browser/debugViewlet.ts +++ b/src/vs/workbench/parts/debug/browser/debugViewlet.ts @@ -110,7 +110,7 @@ export class DebugViewlet extends Viewlet { public focus(): void { super.focus(); - if (!this.contextService.getWorkspace()) { + if (!this.contextService.hasWorkspace()) { this.views[0].focusBody(); } @@ -123,7 +123,7 @@ export class DebugViewlet extends Viewlet { if (!this.actions) { this.actions = []; this.actions.push(this.instantiationService.createInstance(StartAction, StartAction.ID, StartAction.LABEL)); - if (this.contextService.getWorkspace()) { + if (this.contextService.hasWorkspace()) { this.actions.push(this.instantiationService.createInstance(ConfigureAction, ConfigureAction.ID, ConfigureAction.LABEL)); } this.actions.push(this.instantiationService.createInstance(ToggleReplAction, ToggleReplAction.ID, ToggleReplAction.LABEL)); @@ -137,7 +137,7 @@ export class DebugViewlet extends Viewlet { } public getActionItem(action: IAction): IActionItem { - if (action.id === StartAction.ID && this.contextService.getWorkspace()) { + if (action.id === StartAction.ID && this.contextService.hasWorkspace()) { this.startDebugActionItem = this.instantiationService.createInstance(StartDebugActionItem, null, action); return this.startDebugActionItem; } diff --git a/src/vs/workbench/parts/debug/electron-browser/debugCommands.ts b/src/vs/workbench/parts/debug/electron-browser/debugCommands.ts index ec6a8673d4f..d19a3b4beff 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugCommands.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugCommands.ts @@ -199,7 +199,7 @@ export function registerCommands(): void { primary: undefined, handler: (accessor) => { const manager = accessor.get(IDebugService).getConfigurationManager(); - if (!accessor.get(IWorkspaceContextService).getWorkspace()) { + if (!accessor.get(IWorkspaceContextService).hasWorkspace()) { accessor.get(IMessageService).show(severity.Info, nls.localize('noFolderDebugConfig', "Please first open a folder in order to do advanced debug configuration.")); return TPromise.as(null); } diff --git a/src/vs/workbench/parts/debug/electron-browser/debugConfigurationManager.ts b/src/vs/workbench/parts/debug/electron-browser/debugConfigurationManager.ts index 35091fbd8b7..c8f9bc3ec76 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugConfigurationManager.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugConfigurationManager.ts @@ -272,7 +272,7 @@ export class ConfigurationManager implements debug.IConfigurationManager { } public getCompound(name: string): debug.ICompound { - if (!this.contextService.getWorkspace()) { + if (!this.contextService.hasWorkspace()) { return null; } @@ -302,7 +302,7 @@ export class ConfigurationManager implements debug.IConfigurationManager { } public getConfiguration(name: string): debug.IConfig { - if (!this.contextService.getWorkspace()) { + if (!this.contextService.hasWorkspace()) { return null; } @@ -315,7 +315,7 @@ export class ConfigurationManager implements debug.IConfigurationManager { } public resloveConfiguration(config: debug.IConfig): TPromise { - if (!this.contextService.getWorkspace()) { + if (!this.contextService.hasWorkspace()) { return TPromise.as(config); } diff --git a/src/vs/workbench/parts/debug/electron-browser/debugService.ts b/src/vs/workbench/parts/debug/electron-browser/debugService.ts index 441ac578f43..64bf423dfc1 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugService.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugService.ts @@ -410,7 +410,7 @@ export class DebugService implements debug.IDebugService { // 'Run without debugging' mode VSCode must terminate the extension host. More details: #3905 const process = this.viewModel.focusedProcess; if (process && session && process.getId() === session.getId() && strings.equalsIgnoreCase(process.configuration.type, 'extensionhost') && this.sessionStates.get(session.getId()) === debug.State.Running && - process && this.contextService.getWorkspace() && process.configuration.noDebug) { + process && this.contextService.hasWorkspace() && process.configuration.noDebug) { this.windowsService.closeExtensionHostWindow(this.contextService.getWorkspace().resource.fsPath); } if (session && session.getId() === event.body.sessionId) { @@ -646,7 +646,7 @@ export class DebugService implements debug.IDebugService { if (commandAndType && commandAndType.command) { const defaultConfig = noDebug ? { noDebug: true } : {}; return this.commandService.executeCommand(commandAndType.command, config || defaultConfig).then((result: StartSessionResult) => { - if (this.contextService.getWorkspace()) { + if (this.contextService.hasWorkspace()) { if (result && result.status === 'initialConfiguration') { return manager.openConfigFile(false, commandAndType.type); } @@ -662,7 +662,7 @@ export class DebugService implements debug.IDebugService { if (config) { return this.createProcess(config); } - if (this.contextService.getWorkspace() && commandAndType) { + if (this.contextService.hasWorkspace() && commandAndType) { return manager.openConfigFile(false, commandAndType.type); } @@ -719,7 +719,7 @@ export class DebugService implements debug.IDebugService { }); }); }, err => { - if (!this.contextService.getWorkspace()) { + if (!this.contextService.hasWorkspace()) { return this.messageService.show(severity.Error, nls.localize('noFolderWorkspaceDebugError', "The active file can not be debugged. Make sure it is saved on disk and that you have a debug extension installed for that file type.")); } @@ -803,7 +803,7 @@ export class DebugService implements debug.IDebugService { this.panelService.openPanel(debug.REPL_ID, false).done(undefined, errors.onUnexpectedError); } - if (!this.viewModel.changedWorkbenchViewState && (this.partService.isVisible(Parts.SIDEBAR_PART) || !this.contextService.getWorkspace())) { + if (!this.viewModel.changedWorkbenchViewState && (this.partService.isVisible(Parts.SIDEBAR_PART) || !this.contextService.hasWorkspace())) { // We only want to change the workbench view state on the first debug session #5738 and if the side bar is not hidden this.viewModel.changedWorkbenchViewState = true; this.viewletService.openViewlet(debug.VIEWLET_ID); diff --git a/src/vs/workbench/parts/tasks/node/processRunnerDetector.ts b/src/vs/workbench/parts/tasks/node/processRunnerDetector.ts index 92c7473515a..a280054865e 100644 --- a/src/vs/workbench/parts/tasks/node/processRunnerDetector.ts +++ b/src/vs/workbench/parts/tasks/node/processRunnerDetector.ts @@ -155,8 +155,7 @@ export class ProcessRunnerDetector { this.taskConfiguration = config; this._stderr = []; this._stdout = []; - const workspace = this.contextService.getWorkspace(); - this._cwd = workspace ? Paths.normalize(workspace.resource.fsPath, true) : ''; + this._cwd = this.contextService.hasWorkspace() ? Paths.normalize(this.contextService.getWorkspace().resource.fsPath, true) : ''; } public get stderr(): string[] { diff --git a/src/vs/workbench/services/textfile/common/textFileEditorModel.ts b/src/vs/workbench/services/textfile/common/textFileEditorModel.ts index 0f23475b17f..43631b46cc1 100644 --- a/src/vs/workbench/services/textfile/common/textFileEditorModel.ts +++ b/src/vs/workbench/services/textfile/common/textFileEditorModel.ts @@ -669,7 +669,7 @@ export class TextFileEditorModel extends BaseTextEditorModel implements ITextFil diag(`doSave(${versionId}) - after updateContent()`, this.resource, new Date()); // Telemetry - if ((this.contextService.getWorkspace() && isEqualOrParent(this.resource.fsPath, this.contextService.toResource('.vscode').fsPath)) || + if ((this.contextService.hasWorkspace() && isEqualOrParent(this.resource.fsPath, this.contextService.toResource('.vscode').fsPath)) || this.resource.fsPath === this.environmentService.appSettingsPath) { // Do not log write to user settings.json and .vscode folder as a filePUT event as it ruins our JSON usage data this.telemetryService.publicLog('settingsWritten'); -- GitLab From 0b6b5857fc5fb815960afc44d25085447de2058a Mon Sep 17 00:00:00 2001 From: Anton Vildyaev Date: Tue, 6 Jun 2017 12:06:12 +0200 Subject: [PATCH 0543/1347] Fix funny dot bug (#27966) * Fix funny dot bug * fix comment --- src/vs/base/common/labels.ts | 2 +- src/vs/base/test/common/labels.test.ts | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/vs/base/common/labels.ts b/src/vs/base/common/labels.ts index efbe348a613..ce95b07160c 100644 --- a/src/vs/base/common/labels.ts +++ b/src/vs/base/common/labels.ts @@ -122,7 +122,7 @@ export function shorten(paths: string[]): string[] { let path = paths[pathIndex]; if (path === '') { - shortenedPaths[pathIndex] = '.'; + shortenedPaths[pathIndex] = `.${nativeSep}`; continue; } diff --git a/src/vs/base/test/common/labels.test.ts b/src/vs/base/test/common/labels.test.ts index 4476a121f25..650b4ee86a6 100644 --- a/src/vs/base/test/common/labels.test.ts +++ b/src/vs/base/test/common/labels.test.ts @@ -57,11 +57,11 @@ suite('Labels', () => { assert.deepEqual(labels.shorten(['a\\b\\c', 'd\\b\\C']), ['…\\c', '…\\C']); // empty or null - assert.deepEqual(labels.shorten(['', null]), ['.', null]); + assert.deepEqual(labels.shorten(['', null]), ['.\\', null]); assert.deepEqual(labels.shorten(['a', 'a\\b', 'a\\b\\c', 'd\\b\\c', 'd\\b']), ['a', 'a\\b', 'a\\b\\c', 'd\\b\\c', 'd\\b']); assert.deepEqual(labels.shorten(['a', 'a\\b', 'b']), ['a', 'a\\b', 'b']); - assert.deepEqual(labels.shorten(['', 'a', 'b', 'b\\c', 'a\\c']), ['.', 'a', 'b', 'b\\c', 'a\\c']); + assert.deepEqual(labels.shorten(['', 'a', 'b', 'b\\c', 'a\\c']), ['.\\', 'a', 'b', 'b\\c', 'a\\c']); assert.deepEqual(labels.shorten(['src\\vs\\workbench\\parts\\execution\\electron-browser', 'src\\vs\\workbench\\parts\\execution\\electron-browser\\something', 'src\\vs\\workbench\\parts\\terminal\\electron-browser']), ['…\\execution\\electron-browser', '…\\something', '…\\terminal\\…']); }); @@ -105,11 +105,11 @@ suite('Labels', () => { assert.deepEqual(labels.shorten(['a/b/c', 'd/b/C']), ['…/c', '…/C']); // empty or null - assert.deepEqual(labels.shorten(['', null]), ['.', null]); + assert.deepEqual(labels.shorten(['', null]), ['./', null]); assert.deepEqual(labels.shorten(['a', 'a/b', 'a/b/c', 'd/b/c', 'd/b']), ['a', 'a/b', 'a/b/c', 'd/b/c', 'd/b']); assert.deepEqual(labels.shorten(['a', 'a/b', 'b']), ['a', 'a/b', 'b']); - assert.deepEqual(labels.shorten(['', 'a', 'b', 'b/c', 'a/c']), ['.', 'a', 'b', 'b/c', 'a/c']); + assert.deepEqual(labels.shorten(['', 'a', 'b', 'b/c', 'a/c']), ['./', 'a', 'b', 'b/c', 'a/c']); }); test('template', function () { -- GitLab From d221a330e92805f4ee162a5264d494b0053b18c0 Mon Sep 17 00:00:00 2001 From: isidor Date: Tue, 6 Jun 2017 12:06:10 +0200 Subject: [PATCH 0544/1347] debug: fix callstack focus/selection weirdness fixes #28098 --- src/vs/workbench/parts/debug/electron-browser/debugViewer.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts index 820660e4f1d..210f9e632e7 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts @@ -252,6 +252,7 @@ export class CallStackController extends BaseDebugController { return this.showMoreStackFrames(tree, element); } if (element instanceof StackFrame) { + super.onLeftClick(tree, element, event); this.focusStackFrame(element, event, event.detail !== 2); return true; } -- GitLab From 23e0a8a65628d9d293b7a45124b39e1977647955 Mon Sep 17 00:00:00 2001 From: Anton Vildyaev Date: Tue, 6 Jun 2017 12:07:09 +0200 Subject: [PATCH 0545/1347] Next group action should not create new group (#27967) * Next group action should not create new group * Remove unused references --- .../browser/parts/editor/editorActions.ts | 56 ++++++++----------- 1 file changed, 23 insertions(+), 33 deletions(-) diff --git a/src/vs/workbench/browser/parts/editor/editorActions.ts b/src/vs/workbench/browser/parts/editor/editorActions.ts index f7f5e2e9b83..34a37ea902f 100644 --- a/src/vs/workbench/browser/parts/editor/editorActions.ts +++ b/src/vs/workbench/browser/parts/editor/editorActions.ts @@ -15,8 +15,7 @@ import { EditorQuickOpenEntry, EditorQuickOpenEntryGroup, IEditorQuickOpenEntry, import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; import { IQuickOpenService } from 'vs/platform/quickOpen/common/quickOpen'; import { IPartService } from 'vs/workbench/services/part/common/partService'; -import { Position, IEditor, Direction, IResourceInput, IEditorInput, POSITIONS } from 'vs/platform/editor/common/editor'; -import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; +import { Position, IEditor, Direction, IResourceInput, IEditorInput } from 'vs/platform/editor/common/editor'; import { IHistoryService } from 'vs/workbench/services/history/common/history'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { IEditorGroupService, GroupArrangement } from 'vs/workbench/services/group/common/groupService'; @@ -414,19 +413,17 @@ export class FocusPreviousGroup extends Action { return TPromise.as(true); } + const stacks = this.editorGroupService.getStacksModel(); + const groupCount = stacks.groups.length; - // Find the next position to the left/top - let nextPosition: Position = Position.ONE; - if (activeEditor.position === Position.THREE) { - nextPosition = Position.TWO; - } else if (activeEditor.position === Position.ONE) { - // Get the last active position - const lastPosition = this.editorGroupService.getStacksModel().groups.length - 1; - nextPosition = lastPosition; + // Nothing to do if the only group + if (groupCount === 1) { + return TPromise.as(true); } - // Focus next position if provided - this.editorGroupService.focusGroup(nextPosition); + // Nevigate to the previous group or to the last group if the first group is active + const newPositionIndex = (activeEditor.position + groupCount - 1) % groupCount; + this.editorGroupService.focusGroup(newPositionIndex); return TPromise.as(true); } @@ -437,42 +434,35 @@ export class FocusNextGroup extends Action { public static ID = 'workbench.action.focusNextGroup'; public static LABEL = nls.localize('focusNextGroup', "Focus Next Group"); - private navigateActions: Action[]; - constructor( id: string, label: string, - @IWorkbenchEditorService private editorService: IWorkbenchEditorService, - @IInstantiationService instantiationService: IInstantiationService + @IEditorGroupService private editorGroupService: IEditorGroupService, + @IWorkbenchEditorService private editorService: IWorkbenchEditorService ) { super(id, label); - - this.navigateActions = []; - this.navigateActions[Position.ONE] = instantiationService.createInstance(FocusFirstGroupAction, FocusFirstGroupAction.ID, FocusFirstGroupAction.LABEL); - this.navigateActions[Position.TWO] = instantiationService.createInstance(FocusSecondGroupAction, FocusSecondGroupAction.ID, FocusSecondGroupAction.LABEL); - this.navigateActions[Position.THREE] = instantiationService.createInstance(FocusThirdGroupAction, FocusThirdGroupAction.ID, FocusThirdGroupAction.LABEL); } public run(event?: any): TPromise { - // Find the next position to the right/bottom to use - let nextPosition: Position; const activeEditor = this.editorService.getActiveEditor(); - const lastPosition = POSITIONS[POSITIONS.length - 1]; - if (!activeEditor || activeEditor.position === lastPosition) { - nextPosition = Position.ONE; - } else if (activeEditor.position === Position.ONE) { - nextPosition = Position.TWO; - } else if (activeEditor.position === Position.TWO) { - nextPosition = Position.THREE; + if (!activeEditor) { + return TPromise.as(true); } - // Run the action for the target next position - if (typeof nextPosition === 'number' && this.navigateActions[nextPosition]) { - return this.navigateActions[nextPosition].run(event); + const stacks = this.editorGroupService.getStacksModel(); + const groupCount = stacks.groups.length; + + // Nowhere to switch if the only group + if (groupCount === 1) { + return TPromise.as(true); } + // Nevigate to the next group or to the first group if the last group is active + const newPositionIndex = (activeEditor.position + 1) % groupCount; + this.editorGroupService.focusGroup(newPositionIndex); + return TPromise.as(true); } } -- GitLab From 35d1212bff530eab899d035cfa4df11e56ba5b93 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Tue, 6 Jun 2017 12:19:31 +0200 Subject: [PATCH 0546/1347] debt - less dependencies to untitlededitorinput --- src/vs/workbench/common/editor/untitledEditorInput.ts | 1 - src/vs/workbench/services/editor/browser/editorService.ts | 5 ++--- .../textmodelResolver/common/textModelResolverService.ts | 5 ++--- .../services/untitled/common/untitledEditorService.ts | 6 ++++-- 4 files changed, 8 insertions(+), 9 deletions(-) diff --git a/src/vs/workbench/common/editor/untitledEditorInput.ts b/src/vs/workbench/common/editor/untitledEditorInput.ts index 753220ec1ba..09cb75038a9 100644 --- a/src/vs/workbench/common/editor/untitledEditorInput.ts +++ b/src/vs/workbench/common/editor/untitledEditorInput.ts @@ -26,7 +26,6 @@ import { IEnvironmentService } from 'vs/platform/environment/common/environment' export class UntitledEditorInput extends EditorInput implements IEncodingSupport { public static ID: string = 'workbench.editors.untitledEditorInput'; - public static SCHEMA: string = 'untitled'; private resource: URI; private _hasAssociatedFilePath: boolean; diff --git a/src/vs/workbench/services/editor/browser/editorService.ts b/src/vs/workbench/services/editor/browser/editorService.ts index b7257dd4119..7e4d4a52bcb 100644 --- a/src/vs/workbench/services/editor/browser/editorService.ts +++ b/src/vs/workbench/services/editor/browser/editorService.ts @@ -12,8 +12,7 @@ import { basename, dirname } from 'vs/base/common/paths'; import { BaseEditor } from 'vs/workbench/browser/parts/editor/baseEditor'; import { EditorInput, EditorOptions, TextEditorOptions, IEditorRegistry, Extensions, SideBySideEditorInput, IFileEditorInput, IFileInputFactory } from 'vs/workbench/common/editor'; import { ResourceEditorInput } from 'vs/workbench/common/editor/resourceEditorInput'; -import { UntitledEditorInput } from 'vs/workbench/common/editor/untitledEditorInput'; -import { IUntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; +import { IUntitledEditorService, UNTITLED_SCHEMA } from 'vs/workbench/services/untitled/common/untitledEditorService'; import { IWorkbenchEditorService, IResourceInputType } from 'vs/workbench/services/editor/common/editorService'; import { IEditorInput, IEditorOptions, ITextEditorOptions, Position, Direction, IEditor, IResourceInput, IResourceDiffInput, IResourceSideBySideInput, IUntitledResourceInput } from 'vs/platform/editor/common/editor'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; @@ -233,7 +232,7 @@ export class WorkbenchEditorService implements IWorkbenchEditorService { // Untitled file support const untitledInput = input; - if (!untitledInput.resource || typeof untitledInput.filePath === 'string' || (untitledInput.resource instanceof URI && untitledInput.resource.scheme === UntitledEditorInput.SCHEMA)) { + if (!untitledInput.resource || typeof untitledInput.filePath === 'string' || (untitledInput.resource instanceof URI && untitledInput.resource.scheme === UNTITLED_SCHEMA)) { return this.untitledEditorService.createOrGet(untitledInput.filePath ? URI.file(untitledInput.filePath) : untitledInput.resource, untitledInput.language, untitledInput.contents); } diff --git a/src/vs/workbench/services/textmodelResolver/common/textModelResolverService.ts b/src/vs/workbench/services/textmodelResolver/common/textModelResolverService.ts index c04739698dc..e23296a9759 100644 --- a/src/vs/workbench/services/textmodelResolver/common/textModelResolverService.ts +++ b/src/vs/workbench/services/textmodelResolver/common/textModelResolverService.ts @@ -15,8 +15,7 @@ import { ResourceEditorModel } from 'vs/workbench/common/editor/resourceEditorMo import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; import network = require('vs/base/common/network'); import { ITextModelResolverService, ITextModelContentProvider, ITextEditorModel } from 'vs/editor/common/services/resolverService'; -import { IUntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; -import { UntitledEditorInput } from 'vs/workbench/common/editor/untitledEditorInput'; +import { IUntitledEditorService, UNTITLED_SCHEMA } from 'vs/workbench/services/untitled/common/untitledEditorService'; import { TextFileEditorModel } from 'vs/workbench/services/textfile/common/textFileEditorModel'; class ResourceModelCollection extends ReferenceCollection> { @@ -116,7 +115,7 @@ export class TextModelResolverService implements ITextModelResolverService { // Untitled Schema: go through cached input // TODO ImmortalReference is a hack - if (resource.scheme === UntitledEditorInput.SCHEMA) { + if (resource.scheme === UNTITLED_SCHEMA) { return this.untitledEditorService.createOrGet(resource).resolve() .then(model => new ImmortalReference(model)); } diff --git a/src/vs/workbench/services/untitled/common/untitledEditorService.ts b/src/vs/workbench/services/untitled/common/untitledEditorService.ts index e1d7d25bbe6..f0c9de49e3e 100644 --- a/src/vs/workbench/services/untitled/common/untitledEditorService.ts +++ b/src/vs/workbench/services/untitled/common/untitledEditorService.ts @@ -15,6 +15,8 @@ import { ResourceMap } from 'vs/base/common/map'; export const IUntitledEditorService = createDecorator('untitledEditorService'); +export const UNTITLED_SCHEMA = 'untitled'; + export interface IUntitledEditorService { _serviceBrand: any; @@ -161,7 +163,7 @@ export class UntitledEditorService implements IUntitledEditorService { let hasAssociatedFilePath = false; if (resource) { hasAssociatedFilePath = (resource.scheme === 'file'); - resource = resource.with({ scheme: UntitledEditorInput.SCHEMA }); // ensure we have the right scheme + resource = resource.with({ scheme: UNTITLED_SCHEMA }); // ensure we have the right scheme if (hasAssociatedFilePath) { UntitledEditorService.KNOWN_ASSOCIATED_FILE_PATHS.set(resource, true); // remember for future lookups @@ -183,7 +185,7 @@ export class UntitledEditorService implements IUntitledEditorService { // Create new taking a resource URI that is not already taken let counter = UntitledEditorService.CACHE.size + 1; do { - resource = URI.from({ scheme: UntitledEditorInput.SCHEMA, path: `Untitled-${counter}` }); + resource = URI.from({ scheme: UNTITLED_SCHEMA, path: `Untitled-${counter}` }); counter++; } while (UntitledEditorService.CACHE.has(resource)); } -- GitLab From b0e7f06a76d35da032123340ecea13ad46c623ea Mon Sep 17 00:00:00 2001 From: jens1o Date: Tue, 6 Jun 2017 12:23:10 +0200 Subject: [PATCH 0547/1347] fix some typos --- src/vs/editor/browser/widget/codeEditorWidget.ts | 1 + .../parts/debug/electron-browser/debugService.ts | 4 ++-- .../workbench/parts/debug/electron-browser/debugViews.ts | 8 ++++---- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/src/vs/editor/browser/widget/codeEditorWidget.ts b/src/vs/editor/browser/widget/codeEditorWidget.ts index 0749b9d9171..0c0e7235b56 100644 --- a/src/vs/editor/browser/widget/codeEditorWidget.ts +++ b/src/vs/editor/browser/widget/codeEditorWidget.ts @@ -524,6 +524,7 @@ class CodeEditorWidgetFocusTracker extends Disposable { private _domFocusTracker: dom.IFocusTracker; private _onChange: Emitter = this._register(new Emitter()); + // TODO: Fix name public onChage: Event = this._onChange.event; constructor(domElement: HTMLElement) { diff --git a/src/vs/workbench/parts/debug/electron-browser/debugService.ts b/src/vs/workbench/parts/debug/electron-browser/debugService.ts index 64bf423dfc1..833ad93f878 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugService.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugService.ts @@ -172,7 +172,7 @@ export class DebugService implements debug.IDebugService { // attach: PH is ready to be attached to // TODO@Isidor this is a hack to just get any 'extensionHost' session. // Optimally the broadcast would contain the id of the session - // We are only intersted if we have an active debug session for extensionHost + // We are only interested if we have an active debug session for extensionHost const process = this.model.getProcesses().filter(p => strings.equalsIgnoreCase(p.configuration.type, 'extensionhost')).pop(); const session = process ? process.session : null; if (broadcast.channel === EXTENSION_ATTACH_BROADCAST_CHANNEL) { @@ -258,7 +258,7 @@ export class DebugService implements debug.IDebugService { } // flush simple values - // always append a new line for output coming from an extension such that seperate logs go to seperate lines #23695 + // always append a new line for output coming from an extension such that separate logs go to separate lines #23695 if (simpleVals.length) { this.model.appendToRepl(simpleVals.join(' ') + '\n', sev); } diff --git a/src/vs/workbench/parts/debug/electron-browser/debugViews.ts b/src/vs/workbench/parts/debug/electron-browser/debugViews.ts index f70b82840e5..d13d9f8cd11 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugViews.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugViews.ts @@ -64,7 +64,7 @@ export class VariablesView extends CollapsibleViewletView { super(actionRunner, !!settings[VariablesView.MEMENTO], nls.localize('variablesSection', "Variables Section"), messageService, keybindingService, contextMenuService); this.variablesFocusedContext = CONTEXT_VARIABLES_FOCUSED.bindTo(contextKeyService); - // Use schedulre to prevent unnecessary flashing + // Use scheduler to prevent unnecessary flashing this.onFocusStackFrameScheduler = new RunOnceScheduler(() => { // Always clear tree highlight to avoid ending up in a broken state #12203 this.tree.clearHighlight(); @@ -116,7 +116,7 @@ export class VariablesView extends CollapsibleViewletView { this.toolBar.setActions(prepareActions([collapseAction]))(); this.toDispose.push(viewModel.onDidFocusStackFrame(sf => { - // Refresh the tree immediatly if it is not visible. + // Refresh the tree immediately if it is not visible. // Otherwise postpone the refresh until user stops stepping. if (!this.tree.getContentHeight()) { this.onFocusStackFrameScheduler.schedule(0); @@ -281,7 +281,7 @@ export class CallStackView extends CollapsibleViewletView { } // Only show the global pause message if we do not display threads. - // Otherwsie there will be a pause message per thread and there is no need for a global one. + // Otherwise there will be a pause message per thread and there is no need for a global one. if (newTreeInput instanceof Thread && newTreeInput.stoppedDetails) { this.pauseMessageLabel.text(newTreeInput.stoppedDetails.description || nls.localize('debugStopped', "Paused on {0}", newTreeInput.stoppedDetails.reason)); if (newTreeInput.stoppedDetails.text) { @@ -355,7 +355,7 @@ export class CallStackView extends CollapsibleViewletView { private updateTreeSelection(): TPromise { if (!this.tree.getInput()) { - // Tree not initialitized yet + // Tree not initialized yet return TPromise.as(null); } -- GitLab From 0ee66e5d3376b57bafafb880b863e6f132768fbb Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Tue, 6 Jun 2017 12:38:40 +0200 Subject: [PATCH 0548/1347] debt - clean up view state for resources/untitled when input gets disposed --- .../parts/editor/textResourceEditor.ts | 47 ++++++++++--------- .../parts/output/browser/outputPanel.ts | 4 +- .../common/editor/editorDiffModel.test.ts | 4 +- 3 files changed, 27 insertions(+), 28 deletions(-) diff --git a/src/vs/workbench/browser/parts/editor/textResourceEditor.ts b/src/vs/workbench/browser/parts/editor/textResourceEditor.ts index 764c0576604..3a2a2b6a906 100644 --- a/src/vs/workbench/browser/parts/editor/textResourceEditor.ts +++ b/src/vs/workbench/browser/parts/editor/textResourceEditor.ts @@ -14,16 +14,15 @@ import { ResourceEditorInput } from 'vs/workbench/common/editor/resourceEditorIn import { BaseTextEditorModel } from 'vs/workbench/common/editor/textEditorModel'; import { UntitledEditorInput } from 'vs/workbench/common/editor/untitledEditorInput'; import { BaseTextEditor } from 'vs/workbench/browser/parts/editor/textEditor'; -import URI from 'vs/base/common/uri'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IStorageService } from 'vs/platform/storage/common/storage'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { IThemeService } from 'vs/platform/theme/common/themeService'; -import { IUntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { IModeService } from 'vs/editor/common/services/modeService'; import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; +import { once } from "vs/base/common/event"; /** * An editor implementation that is capable of showing the contents of resource inputs. Uses @@ -39,20 +38,11 @@ export class TextResourceEditor extends BaseTextEditor { @IStorageService storageService: IStorageService, @IConfigurationService configurationService: IConfigurationService, @IThemeService themeService: IThemeService, - @IUntitledEditorService private untitledEditorService: IUntitledEditorService, @IEditorGroupService editorGroupService: IEditorGroupService, @IModeService modeService: IModeService, @ITextFileService textFileService: ITextFileService ) { super(TextResourceEditor.ID, telemetryService, instantiationService, storageService, configurationService, themeService, modeService, textFileService, editorGroupService); - - this.toUnbind.push(this.untitledEditorService.onDidChangeDirty(e => this.onUntitledDirtyChange(e))); - } - - private onUntitledDirtyChange(resource: URI): void { - if (!this.untitledEditorService.isDirty(resource)) { - this.clearTextEditorViewState([resource.toString()]); // untitled file got reverted, so remove view state - } } public getTitle(): string { @@ -83,7 +73,7 @@ export class TextResourceEditor extends BaseTextEditor { } // Remember view settings if input changes - this.saveTextEditorViewState(oldInput); + this.saveTextEditorViewStateForInput(oldInput); // Different Input (Reload) return input.resolve(true).then((resolvedModel: EditorModel) => { @@ -166,7 +156,7 @@ export class TextResourceEditor extends BaseTextEditor { public clearInput(): void { // Keep editor view state in settings to restore when coming back - this.saveTextEditorViewState(this.input); + this.saveTextEditorViewStateForInput(this.input); // Clear Model this.getControl().setModel(null); @@ -176,22 +166,35 @@ export class TextResourceEditor extends BaseTextEditor { public shutdown(): void { - // Save View State - this.saveTextEditorViewState(this.input); + // Save View State (only for untitled) + if (this.input instanceof UntitledEditorInput) { + this.saveTextEditorViewStateForInput(this.input); + } // Call Super super.shutdown(); } - protected saveTextEditorViewState(input: EditorInput): void; - protected saveTextEditorViewState(key: string): void; - protected saveTextEditorViewState(arg1: EditorInput | string): void { - if (typeof arg1 === 'string') { - return super.saveTextEditorViewState(arg1); + protected saveTextEditorViewStateForInput(input: EditorInput): void { + if (!(input instanceof UntitledEditorInput) && !(input instanceof ResourceEditorInput)) { + return; // only enabled for untitled and resource inputs } - if ((arg1 instanceof UntitledEditorInput || arg1 instanceof ResourceEditorInput) && !arg1.isDisposed()) { - return super.saveTextEditorViewState(arg1.getResource().toString()); + const key = input.getResource().toString(); + + // Clear view state if input is disposed + if (input.isDisposed()) { + super.clearTextEditorViewState([key]); + } + + // Otherwise save it + else { + super.saveTextEditorViewState(key); + + // Make sure to clean up when the input gets disposed + once(input.onDispose)(() => { + super.clearTextEditorViewState([key]); + }); } } } \ No newline at end of file diff --git a/src/vs/workbench/parts/output/browser/outputPanel.ts b/src/vs/workbench/parts/output/browser/outputPanel.ts index 217bb1972c6..04cecbc3937 100644 --- a/src/vs/workbench/parts/output/browser/outputPanel.ts +++ b/src/vs/workbench/parts/output/browser/outputPanel.ts @@ -22,7 +22,6 @@ import { TextResourceEditor } from 'vs/workbench/browser/parts/editor/textResour import { OutputEditors, OUTPUT_PANEL_ID, IOutputService, CONTEXT_IN_OUTPUT } from 'vs/workbench/parts/output/common/output'; import { SwitchOutputAction, SwitchOutputActionItem, ClearOutputAction, ToggleOutputScrollLockAction } from 'vs/workbench/parts/output/browser/outputActions'; import { IThemeService } from 'vs/platform/theme/common/themeService'; -import { IUntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { IModeService } from 'vs/editor/common/services/modeService'; import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; @@ -39,13 +38,12 @@ export class OutputPanel extends TextResourceEditor { @IConfigurationService configurationService: IConfigurationService, @IThemeService themeService: IThemeService, @IOutputService private outputService: IOutputService, - @IUntitledEditorService untitledEditorService: IUntitledEditorService, @IContextKeyService private contextKeyService: IContextKeyService, @IEditorGroupService editorGroupService: IEditorGroupService, @IModeService modeService: IModeService, @ITextFileService textFileService: ITextFileService ) { - super(telemetryService, instantiationService, storageService, configurationService, themeService, untitledEditorService, editorGroupService, modeService, textFileService); + super(telemetryService, instantiationService, storageService, configurationService, themeService, editorGroupService, modeService, textFileService); this.scopedInstantiationService = instantiationService; this.toDispose = []; diff --git a/src/vs/workbench/test/common/editor/editorDiffModel.test.ts b/src/vs/workbench/test/common/editor/editorDiffModel.test.ts index 2db61acaf4e..91541187e84 100644 --- a/src/vs/workbench/test/common/editor/editorDiffModel.test.ts +++ b/src/vs/workbench/test/common/editor/editorDiffModel.test.ts @@ -16,7 +16,6 @@ import { ResourceEditorInput } from 'vs/workbench/common/editor/resourceEditorIn import URI from 'vs/base/common/uri'; import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; -import { IUntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; import { TestTextFileService, workbenchInstantiationService } from 'vs/workbench/test/workbenchTestServices'; import { TPromise } from "vs/base/common/winjs.base"; import { IModel } from 'vs/editor/common/editorCommon'; @@ -30,8 +29,7 @@ class ServiceAccessor { @ITextModelResolverService public textModelResolverService: ITextModelResolverService, @IModelService public modelService: IModelService, @IModeService public modeService: IModeService, - @ITextFileService public textFileService: TestTextFileService, - @IUntitledEditorService public untitledEditorService: IUntitledEditorService + @ITextFileService public textFileService: TestTextFileService ) { } } -- GitLab From e4d76e67e1648071b364235d969465f79b56f66b Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Tue, 6 Jun 2017 12:40:12 +0200 Subject: [PATCH 0549/1347] Fixes #28093: deep clone editor creation options --- src/vs/editor/common/config/commonEditorConfig.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/editor/common/config/commonEditorConfig.ts b/src/vs/editor/common/config/commonEditorConfig.ts index 2d54be1a832..7c32373ad2f 100644 --- a/src/vs/editor/common/config/commonEditorConfig.ts +++ b/src/vs/editor/common/config/commonEditorConfig.ts @@ -76,7 +76,7 @@ export abstract class CommonEditorConfiguration extends Disposable implements ed constructor(options: editorOptions.IEditorOptions) { super(); - this._rawOptions = objects.mixin({}, options || {}); + this._rawOptions = objects.deepClone(options || {}); this._validatedOptions = editorOptions.EditorOptionsValidator.validate(this._rawOptions, EDITOR_DEFAULTS); this.editor = null; this._isDominatedByLongLines = false; -- GitLab From d03b5e954186a51c258afa77aef13b247c3e45c9 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Tue, 6 Jun 2017 12:57:46 +0200 Subject: [PATCH 0550/1347] eng - print test failure to renderer console for easy reveal in dev tools --- test/electron/renderer.js | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/test/electron/renderer.js b/test/electron/renderer.js index 21424034851..93fb1472aa9 100644 --- a/test/electron/renderer.js +++ b/test/electron/renderer.js @@ -243,11 +243,19 @@ function runTests(opts) { mocha.reporter(IPCReporter); } - mocha.run(() => { + const runner = mocha.run(() => { createCoverageReport(opts).then(() => { ipcRenderer.send('all done'); }); }); + + if (opts.debug) { + runner.on('fail', (test, err) => { + + console.error(test.fullTitle()); + console.error(err.stack); + }); + } }); } -- GitLab From 2497dfe8a9991c48d5b2e6b345c7802fe11fbba1 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Tue, 6 Jun 2017 12:59:45 +0200 Subject: [PATCH 0551/1347] debt - remove last bit of old snippet syntax --- .../contrib/snippet/browser/snippetParser.ts | 80 +------------------ .../test/browser/snippetParser.test.ts | 80 ++++--------------- .../emmet/electron-browser/editorAccessor.ts | 2 +- .../snippets/electron-browser/TMSnippets.ts | 2 +- 4 files changed, 22 insertions(+), 142 deletions(-) diff --git a/src/vs/editor/contrib/snippet/browser/snippetParser.ts b/src/vs/editor/contrib/snippet/browser/snippetParser.ts index 7cd1fd61b3e..6cb1be524c4 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetParser.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetParser.ts @@ -332,20 +332,14 @@ export class SnippetParser { } static parse(template: string, enforceFinalTabstop?: boolean): TextmateSnippet { - const marker = new SnippetParser(true, false).parse(template, true, enforceFinalTabstop); + const marker = new SnippetParser().parse(template, true, enforceFinalTabstop); return new TextmateSnippet(marker); } - private _enableTextMate: boolean; - private _enableInternal: boolean; private _scanner = new Scanner(); private _token: Token; private _prevToken: Token; - constructor(enableTextMate: boolean = true, enableInternal: boolean = true) { - this._enableTextMate = enableTextMate; - this._enableInternal = enableInternal; - } text(value: string): string { return Marker.toString(this.parse(value)); @@ -415,18 +409,10 @@ export class SnippetParser { return false; } - private _return(token: Token): void { - this._prevToken = undefined; - this._token = token; - this._scanner.pos = token.pos + token.len; - } - private _parseAny(marker: Marker[]): boolean { if (this._parseEscaped(marker)) { return true; - } else if (this._enableInternal && this._parseInternal(marker)) { - return true; - } else if (this._enableTextMate && this._parseTM(marker)) { + } else if (this._parseTM(marker)) { return true; } return false; @@ -491,69 +477,9 @@ export class SnippetParser { return false; } - private _parseInternal(marker: Marker[]): boolean { - if (this._accept(TokenType.CurlyOpen)) { - - if (!this._accept(TokenType.CurlyOpen)) { - this._return(this._prevToken); - return false; - } - - // {{name:children}}, {{name}}, {{name:}} - let name: Marker[] = []; - let children: Marker[] = []; - let target = name; - - while (true) { - - if (this._accept(TokenType.Colon)) { - target = children; - continue; - } - - if (this._accept(TokenType.CurlyClose)) { - - if (!this._accept(TokenType.CurlyClose)) { - this._return(this._prevToken); - continue; - } - - if (children !== target) { - // we have not seen the colon which - // means use the ident also as - // default value - children = name; - } - - marker.push(new Placeholder(Marker.toString(name), children)); - return true; - } - - if (this._parseAny(target) || this._parseText(target)) { - continue; - } - - // fallback - if (children.length > 0) { - marker.push(new Text('{{' + Marker.toString(name) + ':')); - marker.push(...children); - } else { - marker.push(new Text('{{')); - marker.push(...name); - } - return true; - } - } - return false; - } - private _parseEscaped(marker: Marker[]): boolean { if (this._accept(TokenType.Backslash)) { - if (// Internal style - (this._enableInternal && (this._accept(TokenType.CurlyOpen) || this._accept(TokenType.CurlyClose) || this._accept(TokenType.Backslash))) - // TextMate style - || (this._enableTextMate && (this._accept(TokenType.Dollar) || this._accept(TokenType.CurlyClose) || this._accept(TokenType.Backslash))) - ) { + if (this._accept(TokenType.Dollar) || this._accept(TokenType.CurlyClose) || this._accept(TokenType.Backslash)) { // just consume them } marker.push(new Text(this._scanner.tokenText(this._prevToken))); diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetParser.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetParser.test.ts index 2092238acc3..874aadd1c56 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetParser.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetParser.test.ts @@ -126,23 +126,23 @@ suite('SnippetParser', () => { assertText('\\}', '}'); assertText('\\abc', '\\abc'); assertText('foo${f:\\}}bar', 'foo}bar'); - assertText('\\{', '{'); + assertText('\\{', '\\{'); assertText('I need \\\\\\$', 'I need \\$'); assertText('\\', '\\'); - assertText('\\{{', '{{'); + assertText('\\{{', '\\{{'); assertText('{{', '{{'); assertText('{{dd', '{{dd'); assertText('}}', '}}'); assertText('ff}}', 'ff}}'); assertText('farboo', 'farboo'); - assertText('far{{}}boo', 'farboo'); - assertText('far{{123}}boo', 'far123boo'); - assertText('far\\{{123}}boo', 'far{{123}}boo'); - assertText('far{{id:bern}}boo', 'farbernboo'); - assertText('far{{id:bern {{basel}}}}boo', 'farbern baselboo'); - assertText('far{{id:bern {{id:basel}}}}boo', 'farbern baselboo'); - assertText('far{{id:bern {{id2:basel}}}}boo', 'farbern baselboo'); + assertText('far{{}}boo', 'far{{}}boo'); + assertText('far{{123}}boo', 'far{{123}}boo'); + assertText('far\\{{123}}boo', 'far\\{{123}}boo'); + assertText('far{{id:bern}}boo', 'far{{id:bern}}boo'); + assertText('far{{id:bern {{basel}}}}boo', 'far{{id:bern {{basel}}}}boo'); + assertText('far{{id:bern {{id:basel}}}}boo', 'far{{id:bern {{id:basel}}}}boo'); + assertText('far{{id:bern {{id2:basel}}}}boo', 'far{{id:bern {{id2:basel}}}}boo'); }); @@ -152,7 +152,7 @@ suite('SnippetParser', () => { assertTextAndMarker('foo${1:bar\\}${2:foo}}', 'foobar}foo', Text, Placeholder); - let [, placeholder] = new SnippetParser(true, false).parse('foo${1:bar\\}${2:foo}}'); + let [, placeholder] = new SnippetParser().parse('foo${1:bar\\}${2:foo}}'); let { children } = (placeholder); assert.equal((placeholder).index, '1'); @@ -164,9 +164,9 @@ suite('SnippetParser', () => { test('Parser, placeholder', () => { assertTextAndMarker('farboo', 'farboo', Text); - assertTextAndMarker('far{{}}boo', 'farboo', Text, Placeholder, Text); - assertTextAndMarker('far{{123}}boo', 'far123boo', Text, Placeholder, Text); - assertTextAndMarker('far\\{{123}}boo', 'far{{123}}boo', Text); + assertTextAndMarker('far{{}}boo', 'far{{}}boo', Text); + assertTextAndMarker('far{{123}}boo', 'far{{123}}boo', Text); + assertTextAndMarker('far\\{{123}}boo', 'far\\{{123}}boo', Text); }); test('Parser, literal code', () => { @@ -194,7 +194,7 @@ suite('SnippetParser', () => { }); test('Parser, only textmate', () => { - const p = new SnippetParser(true, false); + const p = new SnippetParser(); assertMarker(p.parse('far{{}}boo'), Text); assertMarker(p.parse('far{{123}}boo'), Text); assertMarker(p.parse('far\\{{123}}boo'), Text); @@ -204,17 +204,6 @@ suite('SnippetParser', () => { assertMarker(p.parse('far\\${123}boo'), Text); }); - test('Parser, only internal', () => { - const p = new SnippetParser(false, true); - assertMarker(p.parse('far{{}}boo'), Text, Placeholder, Text); - assertMarker(p.parse('far{{123}}boo'), Text, Placeholder, Text); - assertMarker(p.parse('far\\{{123}}boo'), Text); - - assertMarker(p.parse('far$0boo'), Text); - assertMarker(p.parse('far${123}boo'), Text); - assertMarker(p.parse('far\\${123}boo'), Text); - }); - test('Parser, real world', () => { let marker = new SnippetParser().parse('console.warn(${1: $TM_SELECTED_TEXT })'); @@ -242,41 +231,6 @@ suite('SnippetParser', () => { assert.ok(marker[0] instanceof Variable); }); - test('Parser, real world, mixed', () => { - - assertTextAndMarker( - 'finished:{{}}, second:{{2:name}}, first:{{1:}}, third:{{3:}}', - 'finished:, second:name, first:, third:', - Text, Placeholder, Text, Placeholder, Text, Placeholder, Text, Placeholder - ); - - - assertTextAndMarker( - 'begin\\{{{1:enumerate}}\\}\n\t{{}}\nend\\{{{1:}}\\}', - 'begin{enumerate}\n\t\nend{enumerate}', - Text, Placeholder, Text, Placeholder, Text, Placeholder, Text - ); - - }); - - test('Parser, default name/value', () => { - assertTextAndMarker( - '{{first}}-{{2:}}-{{second}}-{{1:}}', - 'first--second-', - Placeholder, Text, Placeholder, Text, Placeholder, Text, Placeholder - ); - - const [p1, , p2, , p3] = new SnippetParser().parse('{{first}}-{{2:}}-{{second}}-{{1:}}'); - assert.equal((p1).index, 'first'); - assert.equal(Marker.toString((p1).children), 'first'); - - assert.equal((p2).index, '2'); - assert.equal(Marker.toString((p2).children), ''); - - assert.equal((p3).index, 'second'); - assert.equal(Marker.toString((p3).children), 'second'); - }); - test('Parser, default placeholder values', () => { assertMarker('errorContext: `${1:err}`, error: $1', Text, Placeholder, Text, Placeholder); @@ -294,15 +248,15 @@ suite('SnippetParser', () => { }); test('backspace esapce in TM only, #16212', () => { - const actual = new SnippetParser(true, false).text('Foo \\\\${abc}bar'); + const actual = new SnippetParser().text('Foo \\\\${abc}bar'); assert.equal(actual, 'Foo \\bar'); }); test('colon as variable/placeholder value, #16717', () => { - let actual = new SnippetParser(true, false).text('${TM_SELECTED_TEXT:foo:bar}'); + let actual = new SnippetParser().text('${TM_SELECTED_TEXT:foo:bar}'); assert.equal(actual, 'foo:bar'); - actual = new SnippetParser(true, false).text('${1:foo:bar}'); + actual = new SnippetParser().text('${1:foo:bar}'); assert.equal(actual, 'foo:bar'); }); diff --git a/src/vs/workbench/parts/emmet/electron-browser/editorAccessor.ts b/src/vs/workbench/parts/emmet/electron-browser/editorAccessor.ts index f5e1ca1e52c..66d77c525f9 100644 --- a/src/vs/workbench/parts/emmet/electron-browser/editorAccessor.ts +++ b/src/vs/workbench/parts/emmet/electron-browser/editorAccessor.ts @@ -114,7 +114,7 @@ export class EditorAccessor implements emmet.Editor { // string to string conversion that tries to fix the // snippet in-place - let marker = new SnippetParser(true, false).parse(template); + let marker = new SnippetParser().parse(template); let maxIndex = -Number.MIN_VALUE; // find highest placeholder index diff --git a/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.ts b/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.ts index 9098d608e88..505049bb5f2 100644 --- a/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.ts +++ b/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.ts @@ -159,7 +159,7 @@ function parseSnippetFile(snippetFileContent: string, extensionName?: string, co } function _rewriteBogousVariables(snippet: ISnippet): boolean { - const marker = new SnippetParser(true, false).parse(snippet.codeSnippet, false); + const marker = new SnippetParser().parse(snippet.codeSnippet, false); let placeholders = new Map(); let placeholderMax = 0; -- GitLab From b13f7c7aaaa552f6bca362a5c485ee165f6e6eff Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Tue, 6 Jun 2017 13:06:50 +0200 Subject: [PATCH 0552/1347] fix #27902 --- .../performance/electron-browser/performance.contribution.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/performance/electron-browser/performance.contribution.ts b/src/vs/workbench/parts/performance/electron-browser/performance.contribution.ts index 23945bccb61..2e5916bdde0 100644 --- a/src/vs/workbench/parts/performance/electron-browser/performance.contribution.ts +++ b/src/vs/workbench/parts/performance/electron-browser/performance.contribution.ts @@ -192,7 +192,7 @@ class StartupProfiler implements IWorkbenchContribution { const action = this._instantiationService.createInstance(ReportPerformanceIssueAction, ReportPerformanceIssueAction.ID, ReportPerformanceIssueAction.LABEL); TPromise.join([ this._windowsService.showItemInFolder(join(profileStartup.dir, files[0])), - action.run(`:warning: Make sure to **attach** these files: :warning:\n${files.map(file => `-\`${join(profileStartup.dir, file)}\``).join('\n')}`) + action.run(`:warning: Make sure to **attach** these files from your *home*-directory: :warning:\n${files.map(file => `-\`${file}\``).join('\n')}`) ]).then(() => { // keep window stable until restart is selected this._messageService.confirm({ -- GitLab From 772aa2c10fb040fa402537d8bf7e525673d5970c Mon Sep 17 00:00:00 2001 From: campersau Date: Tue, 6 Jun 2017 13:32:10 +0200 Subject: [PATCH 0553/1347] cleanup duplicate semicolons in minimapCharRenderer itroduced in https://github.com/Microsoft/vscode/commit/8f9dc8e220aef53c19ef9dfa7284689e04080a0d#diff-0e25f213bdb14a7f0c59d148e40f02f5R256 and https://github.com/Microsoft/vscode/commit/8faa03f88573dbf4b0f5a5a6b583436319d836a8#diff-0e25f213bdb14a7f0c59d148e40f02f5R256 --- src/vs/editor/common/view/minimapCharRenderer.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/editor/common/view/minimapCharRenderer.ts b/src/vs/editor/common/view/minimapCharRenderer.ts index ac1d59a029f..cdf67f31294 100644 --- a/src/vs/editor/common/view/minimapCharRenderer.ts +++ b/src/vs/editor/common/view/minimapCharRenderer.ts @@ -253,7 +253,7 @@ export class MinimapCharRenderer { const deltaG = color.g - backgroundG; const deltaB = color.b - backgroundB; - const colorR = backgroundR + deltaR * c;; + const colorR = backgroundR + deltaR * c; const colorG = backgroundG + deltaG * c; const colorB = backgroundB + deltaB * c; @@ -325,7 +325,7 @@ export class MinimapCharRenderer { const deltaG = color.g - backgroundG; const deltaB = color.b - backgroundB; - const colorR = backgroundR + deltaR * c;; + const colorR = backgroundR + deltaR * c; const colorG = backgroundG + deltaG * c; const colorB = backgroundB + deltaB * c; -- GitLab From 38743ee0fb484c9cdc8d5399637cce906529a82e Mon Sep 17 00:00:00 2001 From: isidor Date: Tue, 6 Jun 2017 14:03:10 +0200 Subject: [PATCH 0554/1347] debug: respect that '[2J' is the ansi escape sequence for clearing the display fixes #27389 --- .../debug/electron-browser/debugService.ts | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugService.ts b/src/vs/workbench/parts/debug/electron-browser/debugService.ts index 64bf423dfc1..d11367c4eae 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugService.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugService.ts @@ -225,12 +225,12 @@ export class DebugService implements debug.IDebugService { // flush any existing simple values logged if (simpleVals.length) { - this.model.appendToRepl(simpleVals.join(' '), sev); + this.logToRepl(simpleVals.join(' '), sev); simpleVals = []; } // show object - this.model.appendToRepl(new OutputNameValueElement((a).prototype, a, nls.localize('snapshotObj', "Only primitive values are shown for this object.")), sev); + this.logToRepl(new OutputNameValueElement((a).prototype, a, nls.localize('snapshotObj', "Only primitive values are shown for this object.")), sev); } // string: watch out for % replacement directive @@ -260,7 +260,7 @@ export class DebugService implements debug.IDebugService { // flush simple values // always append a new line for output coming from an extension such that seperate logs go to seperate lines #23695 if (simpleVals.length) { - this.model.appendToRepl(simpleVals.join(' ') + '\n', sev); + this.logToRepl(simpleVals.join(' ') + '\n', sev); } } } @@ -382,11 +382,11 @@ export class DebugService implements debug.IDebugService { children.forEach(child => { // Since we can not display multiple trees in a row, we are displaying these variables one after the other (ignoring their names) child.name = null; - this.model.appendToRepl(child, outputSeverity); + this.logToRepl(child, outputSeverity); }); }); } else if (typeof event.body.output === 'string') { - this.model.appendToRepl(event.body.output, outputSeverity); + this.logToRepl(event.body.output, outputSeverity); } })); @@ -596,8 +596,13 @@ export class DebugService implements debug.IDebugService { this.model.removeReplExpressions(); } - public logToRepl(value: string, sev = severity.Info): void { - this.model.appendToRepl(value, sev); + public logToRepl(value: string | debug.IExpression, sev = severity.Info): void { + if (typeof value === 'string' && '[2J'.localeCompare(value) === 0) { + // [2J is the ansi escape sequence for clearing the display http://ascii-table.com/ansi-escape-sequences.php + this.model.removeReplExpressions(); + } else { + this.model.appendToRepl(value, sev); + } } public addWatchExpression(name: string): TPromise { -- GitLab From f68e7383e2dfe03b1581dfd9cf04fd2f591c92ec Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Tue, 6 Jun 2017 14:13:18 +0200 Subject: [PATCH 0555/1347] Do not use object.deepClone on the incoming editor options (#28093) --- src/vs/editor/common/config/commonEditorConfig.ts | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/vs/editor/common/config/commonEditorConfig.ts b/src/vs/editor/common/config/commonEditorConfig.ts index 7c32373ad2f..310a51d8538 100644 --- a/src/vs/editor/common/config/commonEditorConfig.ts +++ b/src/vs/editor/common/config/commonEditorConfig.ts @@ -76,7 +76,12 @@ export abstract class CommonEditorConfiguration extends Disposable implements ed constructor(options: editorOptions.IEditorOptions) { super(); - this._rawOptions = objects.deepClone(options || {}); + // Do a "deep clone of sorts" on the incoming options + this._rawOptions = objects.mixin({}, options || {}); + this._rawOptions.scrollbar = objects.mixin({}, this._rawOptions.scrollbar || {}); + this._rawOptions.minimap = objects.mixin({}, this._rawOptions.minimap || {}); + this._rawOptions.find = objects.mixin({}, this._rawOptions.find || {}); + this._validatedOptions = editorOptions.EditorOptionsValidator.validate(this._rawOptions, EDITOR_DEFAULTS); this.editor = null; this._isDominatedByLongLines = false; -- GitLab From 60bbed82be56373264dfb827b43197596d363bab Mon Sep 17 00:00:00 2001 From: isidor Date: Tue, 6 Jun 2017 14:26:28 +0200 Subject: [PATCH 0556/1347] disable minimap in output fixes #27979 --- src/vs/workbench/parts/output/browser/outputPanel.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/vs/workbench/parts/output/browser/outputPanel.ts b/src/vs/workbench/parts/output/browser/outputPanel.ts index 04cecbc3937..e2ce6e1e405 100644 --- a/src/vs/workbench/parts/output/browser/outputPanel.ts +++ b/src/vs/workbench/parts/output/browser/outputPanel.ts @@ -87,6 +87,12 @@ export class OutputPanel extends TextResourceEditor { options.folding = false; options.scrollBeyondLastLine = false; options.renderLineHighlight = 'none'; + options.minimap = { enabled: false }; + + const outputConfig = this.configurationService.getConfiguration('[Log]'); + if (outputConfig && outputConfig['editor.minimap.enabled']) { + options.minimap = { enabled: true }; + } return options; } -- GitLab From b97d6d3bf3033920fa766e1f7b267b4ab6557887 Mon Sep 17 00:00:00 2001 From: isidor Date: Tue, 6 Jun 2017 14:55:59 +0200 Subject: [PATCH 0557/1347] debug: fix debug console string counter fixes #27856 --- src/vs/workbench/parts/debug/common/debugModel.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/debug/common/debugModel.ts b/src/vs/workbench/parts/debug/common/debugModel.ts index 6d4f7691c3e..6c1f0223469 100644 --- a/src/vs/workbench/parts/debug/common/debugModel.ts +++ b/src/vs/workbench/parts/debug/common/debugModel.ts @@ -939,9 +939,11 @@ export class Model implements IModel { public appendToRepl(output: string | IExpression, severity: severity): void { if (typeof output === 'string') { const previousOutput = this.replElements.length && (this.replElements[this.replElements.length - 1] as OutputElement); - if (previousOutput instanceof OutputElement && severity === previousOutput.severity && previousOutput.value === output && output.trim() && output.length > 1) { + const lastNonEmpty = previousOutput && previousOutput.value.trim() ? previousOutput : this.replElements.length > 1 ? this.replElements[this.replElements.length - 2] : undefined; + + if (lastNonEmpty instanceof OutputElement && severity === lastNonEmpty.severity && lastNonEmpty.value === output.trim() && output.trim() && output.length > 1) { // we got the same output (but not an empty string when trimmed) so we just increment the counter - previousOutput.counter++; + lastNonEmpty.counter++; } else { const toAdd = output.split('\n').map(line => new OutputElement(line, severity)); if (previousOutput instanceof OutputElement && severity === previousOutput.severity && toAdd.length) { -- GitLab From 3ab0ef4d7b8fa6190352467d28f15aff4e7a690f Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Tue, 6 Jun 2017 14:48:36 +0200 Subject: [PATCH 0558/1347] :lipstick: --- .../untitled/common/untitledEditorService.ts | 28 +++++++++---------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/src/vs/workbench/services/untitled/common/untitledEditorService.ts b/src/vs/workbench/services/untitled/common/untitledEditorService.ts index f0c9de49e3e..092460d9dac 100644 --- a/src/vs/workbench/services/untitled/common/untitledEditorService.ts +++ b/src/vs/workbench/services/untitled/common/untitledEditorService.ts @@ -85,8 +85,8 @@ export class UntitledEditorService implements IUntitledEditorService { public _serviceBrand: any; - private static CACHE: ResourceMap = new ResourceMap(); - private static KNOWN_ASSOCIATED_FILE_PATHS: ResourceMap = new ResourceMap(); + private mapResourceToInput = new ResourceMap(); + private mapResourceToAssociatedFilePath = new ResourceMap(); private _onDidChangeContent: Emitter; private _onDidChangeDirty: Emitter; @@ -120,7 +120,7 @@ export class UntitledEditorService implements IUntitledEditorService { } public get(resource: URI): UntitledEditorInput { - return UntitledEditorService.CACHE.get(resource); + return this.mapResourceToInput.get(resource); } public getAll(resources?: URI[]): UntitledEditorInput[] { @@ -128,7 +128,7 @@ export class UntitledEditorService implements IUntitledEditorService { return arrays.coalesce(resources.map(r => this.get(r))); } - return UntitledEditorService.CACHE.values(); + return this.mapResourceToInput.values(); } public revertAll(resources?: URI[], force?: boolean): URI[] { @@ -154,7 +154,7 @@ export class UntitledEditorService implements IUntitledEditorService { } public getDirty(): URI[] { - return UntitledEditorService.CACHE.values() + return this.mapResourceToInput.values() .filter(i => i.isDirty()) .map(i => i.getResource()); } @@ -166,13 +166,13 @@ export class UntitledEditorService implements IUntitledEditorService { resource = resource.with({ scheme: UNTITLED_SCHEMA }); // ensure we have the right scheme if (hasAssociatedFilePath) { - UntitledEditorService.KNOWN_ASSOCIATED_FILE_PATHS.set(resource, true); // remember for future lookups + this.mapResourceToAssociatedFilePath.set(resource, true); // remember for future lookups } } // Return existing instance if asked for it - if (resource && UntitledEditorService.CACHE.has(resource)) { - return UntitledEditorService.CACHE.get(resource); + if (resource && this.mapResourceToInput.has(resource)) { + return this.mapResourceToInput.get(resource); } // Create new otherwise @@ -183,11 +183,11 @@ export class UntitledEditorService implements IUntitledEditorService { if (!resource) { // Create new taking a resource URI that is not already taken - let counter = UntitledEditorService.CACHE.size + 1; + let counter = this.mapResourceToInput.size + 1; do { resource = URI.from({ scheme: UNTITLED_SCHEMA, path: `Untitled-${counter}` }); counter++; - } while (UntitledEditorService.CACHE.has(resource)); + } while (this.mapResourceToInput.has(resource)); } // Look up default language from settings if any @@ -219,8 +219,8 @@ export class UntitledEditorService implements IUntitledEditorService { // Remove from cache on dispose const onceDispose = once(input.onDispose); onceDispose(() => { - UntitledEditorService.CACHE.delete(input.getResource()); - UntitledEditorService.KNOWN_ASSOCIATED_FILE_PATHS.delete(input.getResource()); + this.mapResourceToInput.delete(input.getResource()); + this.mapResourceToAssociatedFilePath.delete(input.getResource()); contentListener.dispose(); dirtyListener.dispose(); encodingListener.dispose(); @@ -228,13 +228,13 @@ export class UntitledEditorService implements IUntitledEditorService { }); // Add to cache - UntitledEditorService.CACHE.set(resource, input); + this.mapResourceToInput.set(resource, input); return input; } public hasAssociatedFilePath(resource: URI): boolean { - return UntitledEditorService.KNOWN_ASSOCIATED_FILE_PATHS.has(resource); + return this.mapResourceToAssociatedFilePath.has(resource); } public dispose(): void { -- GitLab From 7b9679d2bc4597b9ad9f6a668f9630a411fec511 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Tue, 6 Jun 2017 14:36:29 +0200 Subject: [PATCH 0559/1347] Add tests for ScrollbarState (#6710) --- .../browser/ui/scrollbar/abstractScrollbar.ts | 7 ++-- .../ui/scrollbar/horizontalScrollbar.ts | 4 ++ .../browser/ui/scrollbar/scrollbarState.ts | 42 ++++++++++++++----- .../browser/ui/scrollbar/verticalScrollbar.ts | 4 ++ src/vs/base/common/scrollable.ts | 14 +++++++ .../ui/scrollbar/scrollbarState.test.ts | 25 +++++++++++ 6 files changed, 81 insertions(+), 15 deletions(-) create mode 100644 src/vs/base/test/browser/ui/scrollbar/scrollbarState.test.ts diff --git a/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts b/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts index 243d62b86f5..d1d8d02d113 100644 --- a/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts +++ b/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts @@ -234,10 +234,6 @@ export abstract class AbstractScrollbar extends Widget { } } - public validateScrollPosition(desiredScrollPosition: number): number { - return this._scrollbarState.validateScrollPosition(desiredScrollPosition); - } - public setDesiredScrollPosition(desiredScrollPosition: number): boolean { desiredScrollPosition = this.validateScrollPosition(desiredScrollPosition); @@ -256,9 +252,12 @@ export abstract class AbstractScrollbar extends Widget { protected abstract _renderDomNode(largeSize: number, smallSize: number): void; protected abstract _updateSlider(sliderSize: number, sliderPosition: number): void; + protected abstract _mouseDownRelativePosition(e: IMouseEvent, domNodePosition: DomUtils.IDomNodePagePosition): number; protected abstract _sliderMousePosition(e: IMouseMoveEventData): number; protected abstract _sliderOrthogonalMousePosition(e: IMouseMoveEventData): number; + protected abstract _getScrollPosition(): number; protected abstract _setScrollPosition(elementScrollPosition: number): void; + public abstract validateScrollPosition(desiredScrollPosition: number): number; } diff --git a/src/vs/base/browser/ui/scrollbar/horizontalScrollbar.ts b/src/vs/base/browser/ui/scrollbar/horizontalScrollbar.ts index bb0d255d2de..616d185a633 100644 --- a/src/vs/base/browser/ui/scrollbar/horizontalScrollbar.ts +++ b/src/vs/base/browser/ui/scrollbar/horizontalScrollbar.ts @@ -106,4 +106,8 @@ export class HorizontalScrollbar extends AbstractScrollbar { scrollLeft: scrollPosition }); } + + public validateScrollPosition(desiredScrollPosition: number): number { + return this._scrollable.validateScrollLeft(desiredScrollPosition); + } } diff --git a/src/vs/base/browser/ui/scrollbar/scrollbarState.ts b/src/vs/base/browser/ui/scrollbar/scrollbarState.ts index b9b8a99849d..c16f442f98e 100644 --- a/src/vs/base/browser/ui/scrollbar/scrollbarState.ts +++ b/src/vs/base/browser/ui/scrollbar/scrollbarState.ts @@ -11,14 +11,41 @@ const MINIMUM_SLIDER_SIZE = 20; export class ScrollbarState { - // --- immutable - private _scrollbarSize: number; - private _oppositeScrollbarSize: number; - private _arrowSize: number; + /** + * For the vertical scrollbar: the width. + * For the horizontal scrollbar: the height. + */ + private readonly _scrollbarSize: number; + + /** + * For the vertical scrollbar: the height of the pair horizontal scrollbar. + * For the horizontal scrollbar: the width of the pair vertical scrollbar. + */ + private readonly _oppositeScrollbarSize: number; + + /** + * For the vertical scrollbar: the height of the scrollbar's arrows. + * For the horizontal scrollbar: the width of the scrollbar's arrows. + */ + private readonly _arrowSize: number; // --- variables + /** + * For the vertical scrollbar: the viewport height. + * For the horizontal scrollbar: the viewport width. + */ private _visibleSize: number; + + /** + * For the vertical scrollbar: the scroll height. + * For the horizontal scrollbar: the scroll width. + */ private _scrollSize: number; + + /** + * For the vertical scrollbar: the scroll top. + * For the horizontal scrollbar: the scroll left. + */ private _scrollPosition: number; // --- computed variables @@ -178,11 +205,4 @@ export class ScrollbarState { public convertSliderPositionToScrollPosition(desiredSliderPosition: number): number { return desiredSliderPosition / this._computedRatio; } - - public validateScrollPosition(desiredScrollPosition: number): number { - desiredScrollPosition = Math.round(desiredScrollPosition); - desiredScrollPosition = Math.max(desiredScrollPosition, 0); - desiredScrollPosition = Math.min(desiredScrollPosition, this._scrollSize - this._visibleSize); - return desiredScrollPosition; - } } diff --git a/src/vs/base/browser/ui/scrollbar/verticalScrollbar.ts b/src/vs/base/browser/ui/scrollbar/verticalScrollbar.ts index e7b363ef16e..e2bfa6b645f 100644 --- a/src/vs/base/browser/ui/scrollbar/verticalScrollbar.ts +++ b/src/vs/base/browser/ui/scrollbar/verticalScrollbar.ts @@ -111,4 +111,8 @@ export class VerticalScrollbar extends AbstractScrollbar { scrollTop: scrollPosition }); } + + public validateScrollPosition(desiredScrollPosition: number): number { + return this._scrollable.validateScrollTop(desiredScrollPosition); + } } diff --git a/src/vs/base/common/scrollable.ts b/src/vs/base/common/scrollable.ts index f7d327627f0..31d821d4ed8 100644 --- a/src/vs/base/common/scrollable.ts +++ b/src/vs/base/common/scrollable.ts @@ -154,6 +154,20 @@ export class Scrollable extends Disposable { return this._state; } + public validateScrollTop(desiredScrollTop: number): number { + desiredScrollTop = Math.round(desiredScrollTop); + desiredScrollTop = Math.max(desiredScrollTop, 0); + desiredScrollTop = Math.min(desiredScrollTop, this._state.scrollHeight - this._state.height); + return desiredScrollTop; + } + + public validateScrollLeft(desiredScrollLeft: number): number { + desiredScrollLeft = Math.round(desiredScrollLeft); + desiredScrollLeft = Math.max(desiredScrollLeft, 0); + desiredScrollLeft = Math.min(desiredScrollLeft, this._state.scrollWidth - this._state.width); + return desiredScrollLeft; + } + public updateState(update: INewScrollState): void { const oldState = this._state; const newState = new ScrollState( diff --git a/src/vs/base/test/browser/ui/scrollbar/scrollbarState.test.ts b/src/vs/base/test/browser/ui/scrollbar/scrollbarState.test.ts new file mode 100644 index 00000000000..99c625ffa28 --- /dev/null +++ b/src/vs/base/test/browser/ui/scrollbar/scrollbarState.test.ts @@ -0,0 +1,25 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +'use strict'; + +import * as assert from 'assert'; +import { ScrollbarState } from "vs/base/browser/ui/scrollbar/scrollbarState"; + +suite('ScrollbarState', () => { + test('inflates slider size', () => { + let actual = new ScrollbarState(0, 14, 0); + actual.setVisibleSize(339); + actual.setScrollSize(42423); + actual.setScrollPosition(32787); + + assert.equal(actual.getArrowSize(), 0); + assert.equal(actual.getRectangleLargeSize(), 339); + assert.equal(actual.getRectangleSmallSize(), 14); + assert.equal(actual.isNeeded(), true); + assert.equal(actual.getSliderSize(), 20); + assert.equal(actual.getSliderPosition(), 252); + assert.equal(actual.getSliderCenter(), 262); + }); +}); -- GitLab From 31a42937a4ab6ffe31537626acad9c7c8a72446f Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Tue, 6 Jun 2017 15:03:38 +0200 Subject: [PATCH 0560/1347] Move slider position computation into ScrollbarState (#6710) --- .../browser/ui/scrollbar/abstractScrollbar.ts | 25 ++++++++------- .../browser/ui/scrollbar/scrollbarState.ts | 31 ++++++++++++++++++- 2 files changed, 43 insertions(+), 13 deletions(-) diff --git a/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts b/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts index d1d8d02d113..ce1196e6b81 100644 --- a/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts +++ b/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts @@ -197,31 +197,32 @@ export abstract class AbstractScrollbar extends Widget { private _onMouseDown(e: IMouseEvent): void { let domNodePosition = DomUtils.getDomNodePagePosition(this.domNode.domNode); - let desiredSliderPosition = this._mouseDownRelativePosition(e, domNodePosition) - this._scrollbarState.getArrowSize() - this._scrollbarState.getSliderSize() / 2; - this.setDesiredScrollPosition(this._scrollbarState.convertSliderPositionToScrollPosition(desiredSliderPosition)); + this.setDesiredScrollPosition(this._scrollbarState.getDesiredScrollPositionFromOffset(this._mouseDownRelativePosition(e, domNodePosition))); this._sliderMouseDown(e); } private _sliderMouseDown(e: IMouseEvent): void { if (e.leftButton) { - let initialMouseOrthogonalPosition = this._sliderOrthogonalMousePosition(e); - let initialScrollPosition = this._getScrollPosition(); - let draggingDelta = this._sliderMousePosition(e) - this._scrollbarState.getSliderPosition(); + const initialMousePosition = this._sliderMousePosition(e); + const initialMouseOrthogonalPosition = this._sliderOrthogonalMousePosition(e); + const initialScrollbarState = this._scrollbarState.clone(); this.slider.toggleClassName('active', true); this._mouseMoveMonitor.startMonitoring( standardMouseMoveMerger, (mouseMoveData: IStandardMouseMoveEventData) => { - let mouseOrthogonalPosition = this._sliderOrthogonalMousePosition(mouseMoveData); - let mouseOrthogonalDelta = Math.abs(mouseOrthogonalPosition - initialMouseOrthogonalPosition); - // console.log(initialMouseOrthogonalPosition + ' -> ' + mouseOrthogonalPosition + ': ' + mouseOrthogonalDelta); + const mouseOrthogonalPosition = this._sliderOrthogonalMousePosition(mouseMoveData); + const mouseOrthogonalDelta = Math.abs(mouseOrthogonalPosition - initialMouseOrthogonalPosition); + if (Platform.isWindows && mouseOrthogonalDelta > MOUSE_DRAG_RESET_DISTANCE) { // The mouse has wondered away from the scrollbar => reset dragging - this.setDesiredScrollPosition(initialScrollPosition); - } else { - let desiredSliderPosition = this._sliderMousePosition(mouseMoveData) - draggingDelta; - this.setDesiredScrollPosition(this._scrollbarState.convertSliderPositionToScrollPosition(desiredSliderPosition)); + this.setDesiredScrollPosition(initialScrollbarState.getScrollPosition()); + return; } + + const mousePosition = this._sliderMousePosition(mouseMoveData); + const mouseDelta = mousePosition - initialMousePosition; + this.setDesiredScrollPosition(initialScrollbarState.getDesiredScrollPositionFromDelta(mouseDelta)); }, () => { this.slider.toggleClassName('active', false); diff --git a/src/vs/base/browser/ui/scrollbar/scrollbarState.ts b/src/vs/base/browser/ui/scrollbar/scrollbarState.ts index c16f442f98e..fed253c78f7 100644 --- a/src/vs/base/browser/ui/scrollbar/scrollbarState.ts +++ b/src/vs/base/browser/ui/scrollbar/scrollbarState.ts @@ -92,6 +92,14 @@ export class ScrollbarState { this._refreshComputedValues(); } + public clone(): ScrollbarState { + let r = new ScrollbarState(this._arrowSize, this._scrollbarSize, this._oppositeScrollbarSize); + r.setVisibleSize(this._visibleSize); + r.setScrollSize(this._scrollSize); + r.setScrollPosition(this._scrollPosition); + return r; + } + public setVisibleSize(visibleSize: number): boolean { let iVisibleSize = Math.round(visibleSize); if (this._visibleSize !== iVisibleSize) { @@ -178,6 +186,10 @@ export class ScrollbarState { return this._arrowSize; } + public getScrollPosition(): number { + return this._scrollPosition; + } + public getRectangleLargeSize(): number { return this._computedAvailableSize; } @@ -202,7 +214,24 @@ export class ScrollbarState { return (this._computedSliderPosition + this._computedSliderSize / 2); } - public convertSliderPositionToScrollPosition(desiredSliderPosition: number): number { + private _convertSliderPositionToScrollPosition(desiredSliderPosition: number): number { return desiredSliderPosition / this._computedRatio; } + + /** + * Compute a desired `scrollPosition` such that `offset` ends up in the center of the slider. + * `offset` is based on the same coordinate system as the `sliderPosition`. + */ + public getDesiredScrollPositionFromOffset(offset: number): number { + let desiredSliderPosition = offset - this._arrowSize - this._computedSliderSize / 2; + return this._convertSliderPositionToScrollPosition(desiredSliderPosition); + } + + /** + * Compute a desired `scrollPosition` such that the slider moves by `delta`. + */ + public getDesiredScrollPositionFromDelta(delta: number): number { + let desiredSliderPosition = this._computedSliderPosition + delta; + return this._convertSliderPositionToScrollPosition(desiredSliderPosition); + } } -- GitLab From a25ffe6b55fe26b8e06fdb58757fb3b319bdae4f Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Tue, 6 Jun 2017 15:40:13 +0200 Subject: [PATCH 0561/1347] Fixes #6710: Correctly model the case where the slider is artificially inflated in size --- .../browser/ui/scrollbar/scrollbarState.ts | 117 ++++++++---------- .../ui/scrollbar/scrollbarState.test.ts | 17 ++- 2 files changed, 66 insertions(+), 68 deletions(-) diff --git a/src/vs/base/browser/ui/scrollbar/scrollbarState.ts b/src/vs/base/browser/ui/scrollbar/scrollbarState.ts index fed253c78f7..ee2041c3af2 100644 --- a/src/vs/base/browser/ui/scrollbar/scrollbarState.ts +++ b/src/vs/base/browser/ui/scrollbar/scrollbarState.ts @@ -54,23 +54,13 @@ export class ScrollbarState { * `visibleSize` - `oppositeScrollbarSize` */ private _computedAvailableSize: number; - - /** - * `computedAvailableSize` - 2 * `arrowSize` - */ - private _computedRepresentableSize: number; - /** - * `computedRepresentableSize` / `scrollSize` - */ - private _computedRatio: number; - - /** - * (`scrollSize` > `visibleSize`) + * (`scrollSize` > 0 && `scrollSize` > `visibleSize`) */ private _computedIsNeeded: boolean; private _computedSliderSize: number; + private _computedSliderRatio: number; private _computedSliderPosition: number; constructor(arrowSize: number, scrollbarSize: number, oppositeScrollbarSize: number) { @@ -83,10 +73,9 @@ export class ScrollbarState { this._scrollPosition = 0; this._computedAvailableSize = 0; - this._computedRepresentableSize = 0; - this._computedRatio = 0.1; this._computedIsNeeded = false; this._computedSliderSize = 0; + this._computedSliderRatio = 0; this._computedSliderPosition = 0; this._refreshComputedValues(); @@ -130,56 +119,46 @@ export class ScrollbarState { return false; } - private _refreshComputedValues(): void { - const oppositeScrollbarSize = this._oppositeScrollbarSize; - const arrowSize = this._arrowSize; - const visibleSize = this._visibleSize; - const scrollSize = this._scrollSize; - const scrollPosition = this._scrollPosition; - - let computedAvailableSize = Math.max(0, visibleSize - oppositeScrollbarSize); - let computedRepresentableSize = Math.max(0, computedAvailableSize - 2 * arrowSize); - let computedRatio = scrollSize > 0 ? (computedRepresentableSize / scrollSize) : 0; - let computedIsNeeded = (scrollSize > visibleSize); - - let computedSliderSize: number; - let computedSliderPosition: number; + private static _computeValues(oppositeScrollbarSize: number, arrowSize: number, visibleSize: number, scrollSize: number, scrollPosition: number) { + const computedAvailableSize = Math.max(0, visibleSize - oppositeScrollbarSize); + const computedRepresentableSize = Math.max(0, computedAvailableSize - 2 * arrowSize); + const computedIsNeeded = (scrollSize > 0 && scrollSize > visibleSize); if (!computedIsNeeded) { - computedSliderSize = computedRepresentableSize; - computedSliderPosition = 0; - } else { - computedSliderSize = Math.floor(visibleSize * computedRatio); - computedSliderPosition = Math.floor(scrollPosition * computedRatio); - - if (computedSliderSize < MINIMUM_SLIDER_SIZE) { - // We must artificially increase the size of the slider, since the slider would be too small otherwise - // The effort is to keep the slider centered around the original position, but we must take into - // account the cases when the slider is too close to the top or too close to the bottom - - let sliderArtificialOffset = (MINIMUM_SLIDER_SIZE - computedSliderSize) / 2; - computedSliderSize = MINIMUM_SLIDER_SIZE; - - computedSliderPosition -= sliderArtificialOffset; - - if (computedSliderPosition + computedSliderSize > computedRepresentableSize) { - // Slider is too close to the bottom, so we glue it to the bottom - computedSliderPosition = computedRepresentableSize - computedSliderSize; - } - - if (computedSliderPosition < 0) { - // Slider is too close to the top, so we glue it to the top - computedSliderPosition = 0; - } - } + // There is no need for a slider + return { + computedAvailableSize: Math.round(computedAvailableSize), + computedIsNeeded: computedIsNeeded, + computedSliderSize: Math.round(computedRepresentableSize), + computedSliderRatio: 0, + computedSliderPosition: 0, + }; } - this._computedAvailableSize = Math.round(computedAvailableSize); - this._computedRepresentableSize = Math.round(computedRepresentableSize); - this._computedRatio = computedRatio; - this._computedIsNeeded = computedIsNeeded; - this._computedSliderSize = Math.round(computedSliderSize); - this._computedSliderPosition = Math.round(computedSliderPosition); + // We must artificially increase the size of the slider if needed, since the slider would be too small to grab with the mouse otherwise + const computedSliderSize = Math.round(Math.max(MINIMUM_SLIDER_SIZE, Math.floor(visibleSize * computedRepresentableSize / scrollSize))); + + // The slider can move from 0 to `computedRepresentableSize` - `computedSliderSize` + // in the same way `scrollPosition` can move from 0 to `scrollSize` - `visibleSize`. + const computedSliderRatio = (computedRepresentableSize - computedSliderSize) / (scrollSize - visibleSize); + const computedSliderPosition = (scrollPosition * computedSliderRatio); + + return { + computedAvailableSize: Math.round(computedAvailableSize), + computedIsNeeded: computedIsNeeded, + computedSliderSize: Math.round(computedSliderSize), + computedSliderRatio: computedSliderRatio, + computedSliderPosition: Math.round(computedSliderPosition), + }; + } + + private _refreshComputedValues(): void { + const r = ScrollbarState._computeValues(this._oppositeScrollbarSize, this._arrowSize, this._visibleSize, this._scrollSize, this._scrollPosition); + this._computedAvailableSize = r.computedAvailableSize; + this._computedIsNeeded = r.computedIsNeeded; + this._computedSliderSize = r.computedSliderSize; + this._computedSliderRatio = r.computedSliderRatio; + this._computedSliderPosition = r.computedSliderPosition; } public getArrowSize(): number { @@ -214,24 +193,30 @@ export class ScrollbarState { return (this._computedSliderPosition + this._computedSliderSize / 2); } - private _convertSliderPositionToScrollPosition(desiredSliderPosition: number): number { - return desiredSliderPosition / this._computedRatio; - } - /** * Compute a desired `scrollPosition` such that `offset` ends up in the center of the slider. * `offset` is based on the same coordinate system as the `sliderPosition`. */ public getDesiredScrollPositionFromOffset(offset: number): number { + if (!this._computedIsNeeded) { + // no need for a slider + return 0; + } + let desiredSliderPosition = offset - this._arrowSize - this._computedSliderSize / 2; - return this._convertSliderPositionToScrollPosition(desiredSliderPosition); + return Math.round(desiredSliderPosition / this._computedSliderRatio); } /** * Compute a desired `scrollPosition` such that the slider moves by `delta`. */ public getDesiredScrollPositionFromDelta(delta: number): number { + if (!this._computedIsNeeded) { + // no need for a slider + return 0; + } + let desiredSliderPosition = this._computedSliderPosition + delta; - return this._convertSliderPositionToScrollPosition(desiredSliderPosition); + return Math.round(desiredSliderPosition / this._computedSliderRatio); } } diff --git a/src/vs/base/test/browser/ui/scrollbar/scrollbarState.test.ts b/src/vs/base/test/browser/ui/scrollbar/scrollbarState.test.ts index 99c625ffa28..719e0be2578 100644 --- a/src/vs/base/test/browser/ui/scrollbar/scrollbarState.test.ts +++ b/src/vs/base/test/browser/ui/scrollbar/scrollbarState.test.ts @@ -15,11 +15,24 @@ suite('ScrollbarState', () => { actual.setScrollPosition(32787); assert.equal(actual.getArrowSize(), 0); + assert.equal(actual.getScrollPosition(), 32787); assert.equal(actual.getRectangleLargeSize(), 339); assert.equal(actual.getRectangleSmallSize(), 14); assert.equal(actual.isNeeded(), true); assert.equal(actual.getSliderSize(), 20); - assert.equal(actual.getSliderPosition(), 252); - assert.equal(actual.getSliderCenter(), 262); + assert.equal(actual.getSliderPosition(), 249); + assert.equal(actual.getSliderCenter(), 259); + + + assert.equal(actual.getDesiredScrollPositionFromOffset(259), 32849); + actual.setScrollPosition(32849); + assert.equal(actual.getArrowSize(), 0); + assert.equal(actual.getScrollPosition(), 32849); + assert.equal(actual.getRectangleLargeSize(), 339); + assert.equal(actual.getRectangleSmallSize(), 14); + assert.equal(actual.isNeeded(), true); + assert.equal(actual.getSliderSize(), 20); + assert.equal(actual.getSliderPosition(), 249); + assert.equal(actual.getSliderCenter(), 259); }); }); -- GitLab From 4cbb97ca2369dfa1a31646d8e1a43ccb3ace9804 Mon Sep 17 00:00:00 2001 From: isidor Date: Tue, 6 Jun 2017 15:45:47 +0200 Subject: [PATCH 0562/1347] debug: improve hc colors for variables fixes #28014 --- .../parts/debug/browser/media/debug.contribution.css | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/vs/workbench/parts/debug/browser/media/debug.contribution.css b/src/vs/workbench/parts/debug/browser/media/debug.contribution.css index 7c67f7d14b8..efafecc857d 100644 --- a/src/vs/workbench/parts/debug/browser/media/debug.contribution.css +++ b/src/vs/workbench/parts/debug/browser/media/debug.contribution.css @@ -163,6 +163,18 @@ color: #B5CEA8; } +.hc-black .monaco-workbench .monaco-tree-row:not(.selected) .expression .value.number { + color: #89d185; +} + +.hc-black .monaco-workbench .monaco-tree-row:not(.selected) .expression .value.boolean { + color: #75bdfe; +} + +.hc-black .monaco-workbench .monaco-tree-row:not(.selected) .expression .value.string { + color: #f48771; +} + .vs-dark .monaco-workbench .monaco-tree-row:not(.selected) .expression .value.boolean { color: #4E94CE; } -- GitLab From 0697435ac5ca028b055cac042fd9d97ee63d7d7d Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Tue, 6 Jun 2017 15:45:45 +0200 Subject: [PATCH 0563/1347] More tests for ScrollbarState (#6710) --- .../ui/scrollbar/scrollbarState.test.ts | 28 +++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/src/vs/base/test/browser/ui/scrollbar/scrollbarState.test.ts b/src/vs/base/test/browser/ui/scrollbar/scrollbarState.test.ts index 719e0be2578..9d10e81ba5f 100644 --- a/src/vs/base/test/browser/ui/scrollbar/scrollbarState.test.ts +++ b/src/vs/base/test/browser/ui/scrollbar/scrollbarState.test.ts @@ -35,4 +35,32 @@ suite('ScrollbarState', () => { assert.equal(actual.getSliderPosition(), 249); assert.equal(actual.getSliderCenter(), 259); }); + + test('inflates slider size with arrows', () => { + let actual = new ScrollbarState(12, 14, 0); + actual.setVisibleSize(339); + actual.setScrollSize(42423); + actual.setScrollPosition(32787); + + assert.equal(actual.getArrowSize(), 12); + assert.equal(actual.getScrollPosition(), 32787); + assert.equal(actual.getRectangleLargeSize(), 339); + assert.equal(actual.getRectangleSmallSize(), 14); + assert.equal(actual.isNeeded(), true); + assert.equal(actual.getSliderSize(), 20); + assert.equal(actual.getSliderPosition(), 230); + assert.equal(actual.getSliderCenter(), 240); + + + assert.equal(actual.getDesiredScrollPositionFromOffset(240 + 12), 32811); + actual.setScrollPosition(32811); + assert.equal(actual.getArrowSize(), 12); + assert.equal(actual.getScrollPosition(), 32811); + assert.equal(actual.getRectangleLargeSize(), 339); + assert.equal(actual.getRectangleSmallSize(), 14); + assert.equal(actual.isNeeded(), true); + assert.equal(actual.getSliderSize(), 20); + assert.equal(actual.getSliderPosition(), 230); + assert.equal(actual.getSliderCenter(), 240); + }); }); -- GitLab From d167d92ba11aec0cc4d0bb6d51d86d4322759043 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Tue, 6 Jun 2017 16:03:39 +0200 Subject: [PATCH 0564/1347] Fix typo (#28101) --- src/vs/editor/browser/widget/codeEditorWidget.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/vs/editor/browser/widget/codeEditorWidget.ts b/src/vs/editor/browser/widget/codeEditorWidget.ts index 0c0e7235b56..bfb0cc8cecc 100644 --- a/src/vs/editor/browser/widget/codeEditorWidget.ts +++ b/src/vs/editor/browser/widget/codeEditorWidget.ts @@ -98,7 +98,7 @@ export abstract class CodeEditorWidget extends CommonCodeEditor implements edito this._themeService = themeService; this._focusTracker = new CodeEditorWidgetFocusTracker(domElement); - this._focusTracker.onChage(() => { + this._focusTracker.onChange(() => { let hasFocus = this._focusTracker.hasFocus(); if (hasFocus) { @@ -524,8 +524,7 @@ class CodeEditorWidgetFocusTracker extends Disposable { private _domFocusTracker: dom.IFocusTracker; private _onChange: Emitter = this._register(new Emitter()); - // TODO: Fix name - public onChage: Event = this._onChange.event; + public onChange: Event = this._onChange.event; constructor(domElement: HTMLElement) { super(); -- GitLab From 97dc70739e6726f2d992e7dd61ba28e5c41de0c7 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Tue, 6 Jun 2017 14:40:29 +0200 Subject: [PATCH 0565/1347] debt - remove commented out stuff --- src/vs/base/common/objects.ts | 34 ---------------------------------- 1 file changed, 34 deletions(-) diff --git a/src/vs/base/common/objects.ts b/src/vs/base/common/objects.ts index 9a814afa30c..d834bfe2ddd 100644 --- a/src/vs/base/common/objects.ts +++ b/src/vs/base/common/objects.ts @@ -82,40 +82,6 @@ function _cloneAndChange(obj: any, changer: (orig: any) => any, encounteredObjec return obj; } -// DON'T USE THESE FUNCTION UNLESS YOU KNOW HOW CHROME -// WORKS... WE HAVE SEEN VERY WEIRD BEHAVIOUR WITH CHROME >= 37 - -///** -// * Recursively call Object.freeze on object and any properties that are objects. -// */ -//export function deepFreeze(obj:any):void { -// Object.freeze(obj); -// Object.keys(obj).forEach((key) => { -// if(!(typeof obj[key] === 'object') || Object.isFrozen(obj[key])) { -// return; -// } -// -// deepFreeze(obj[key]); -// }); -// if(!Object.isFrozen(obj)) { -// console.log('too warm'); -// } -//} -// -//export function deepSeal(obj:any):void { -// Object.seal(obj); -// Object.keys(obj).forEach((key) => { -// if(!(typeof obj[key] === 'object') || Object.isSealed(obj[key])) { -// return; -// } -// -// deepSeal(obj[key]); -// }); -// if(!Object.isSealed(obj)) { -// console.log('NOT sealed'); -// } -//} - /** * Copies all properties of source into destination. The optional parameter "overwrite" allows to control * if existing properties on the destination should be overwritten or not. Defaults to true (overwrite). -- GitLab From 44da540b4b29d2cb49cae37ddc24415e7a2d1b9b Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Tue, 6 Jun 2017 14:56:41 +0200 Subject: [PATCH 0566/1347] fix #27949 --- .../api/node/extHostDocumentsAndEditors.ts | 7 +-- .../api/extHostDocumentsAndEditors.test.ts | 63 +++++++++++++++++++ 2 files changed, 66 insertions(+), 4 deletions(-) create mode 100644 src/vs/workbench/test/electron-browser/api/extHostDocumentsAndEditors.test.ts diff --git a/src/vs/workbench/api/node/extHostDocumentsAndEditors.ts b/src/vs/workbench/api/node/extHostDocumentsAndEditors.ts index 164827a79fd..27baef47f89 100644 --- a/src/vs/workbench/api/node/extHostDocumentsAndEditors.ts +++ b/src/vs/workbench/api/node/extHostDocumentsAndEditors.ts @@ -98,6 +98,9 @@ export class ExtHostDocumentsAndEditors extends ExtHostDocumentsAndEditorsShape this._activeEditorId = delta.newActiveEditor; } + dispose(removedDocuments); + dispose(removedEditors); + // now that the internal state is complete, fire events if (delta.removedDocuments) { this._onDidRemoveDocuments.fire(removedDocuments); @@ -112,10 +115,6 @@ export class ExtHostDocumentsAndEditors extends ExtHostDocumentsAndEditorsShape if (delta.newActiveEditor !== undefined) { this._onDidChangeActiveTextEditor.fire(this.activeEditor()); } - - // now that the events are out, dispose removed documents and editors - dispose(removedDocuments); - dispose(removedEditors); } getDocument(strUrl: string): ExtHostDocumentData { diff --git a/src/vs/workbench/test/electron-browser/api/extHostDocumentsAndEditors.test.ts b/src/vs/workbench/test/electron-browser/api/extHostDocumentsAndEditors.test.ts new file mode 100644 index 00000000000..fc14d9e5382 --- /dev/null +++ b/src/vs/workbench/test/electron-browser/api/extHostDocumentsAndEditors.test.ts @@ -0,0 +1,63 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +'use strict'; + +import * as assert from 'assert'; +import URI from 'vs/base/common/uri'; +import { ExtHostDocumentsAndEditors } from 'vs/workbench/api/node/extHostDocumentsAndEditors'; +import { TPromise } from 'vs/base/common/winjs.base'; + + +suite('ExtHostDocumentsAndEditors', () => { + + let editors: ExtHostDocumentsAndEditors; + + setup(function () { + editors = new ExtHostDocumentsAndEditors({ + _serviceBrand: undefined, + get() { return undefined; }, + set() { } + }); + }); + + test('The value of TextDocument.isClosed is incorrect when a text document is closed, #27949', () => { + + editors.$acceptDocumentsAndEditorsDelta({ + addedDocuments: [{ + EOL: '\n', + isDirty: true, + modeId: 'fooLang', + url: URI.parse('foo:bar'), + versionId: 1, + lines: [ + 'first', + 'second' + ] + }] + }); + + return new TPromise((resolve, reject) => { + + editors.onDidRemoveDocuments(e => { + try { + + for (const data of e) { + assert.equal(data.document.isClosed, true); + } + resolve(undefined); + } catch (e) { + reject(e); + } + }); + + editors.$acceptDocumentsAndEditorsDelta({ + removedDocuments: ['foo:bar'] + }); + + }); + }); + +}); -- GitLab From c664cb83449c87e45072c66216cb3bd40cd9a485 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Tue, 6 Jun 2017 19:13:58 +0200 Subject: [PATCH 0567/1347] extract snippet suggest provider, #26275 --- .../electron-browser/snippetsService.ts | 78 +++++++++---------- 1 file changed, 39 insertions(+), 39 deletions(-) diff --git a/src/vs/workbench/parts/snippets/electron-browser/snippetsService.ts b/src/vs/workbench/parts/snippets/electron-browser/snippetsService.ts index fdb96d9beaa..31b32d88c8a 100644 --- a/src/vs/workbench/parts/snippets/electron-browser/snippetsService.ts +++ b/src/vs/workbench/parts/snippets/electron-browser/snippetsService.ts @@ -7,7 +7,7 @@ import { localize } from 'vs/nls'; import * as strings from 'vs/base/common/strings'; import { IModel } from 'vs/editor/common/editorCommon'; -import { ISuggestion, LanguageId } from 'vs/editor/common/modes'; +import { ISuggestSupport, ISuggestResult, ISuggestion, LanguageId } from 'vs/editor/common/modes'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; import { registerSingleton } from 'vs/platform/instantiation/common/extensions'; import { setSnippetSuggestSupport } from 'vs/editor/contrib/suggest/browser/suggest'; @@ -41,19 +41,12 @@ class SnippetsService implements ISnippetsService { _serviceBrand: any; - private static _defaultDetail = localize('detail.userSnippet', "User Snippet"); - - private _snippets = new Map>(); + private readonly _snippets = new Map>(); constructor( - @IModeService private _modeService: IModeService + @IModeService modeService: IModeService ) { - setSnippetSuggestSupport({ - provideCompletionItems: (model, position) => { - const suggestions = this._getSnippetCompletions(model, position); - return { suggestions }; - } - }); + setSnippetSuggestSupport(new SnippetSuggestProvider(modeService, this)); } public registerSnippets(languageId: LanguageId, snippets: ISnippet[], fileName: string): void { @@ -74,33 +67,33 @@ class SnippetsService implements ISnippetsService { }); } } +} - private _getLanguageIdAtPosition(model: IModel, position: Position): LanguageId { - // validate the `languageId` to ensure this is a user - // facing language with a name and the chance to have - // snippets, else fall back to the outer language - model.forceTokenization(position.lineNumber); - let languageId = model.getLanguageIdAtPosition(position.lineNumber, position.column); - let { language } = this._modeService.getLanguageIdentifier(languageId); - if (!this._modeService.getLanguageName(language)) { - languageId = model.getLanguageIdentifier().id; - } - return languageId; +registerSingleton(ISnippetsService, SnippetsService); + +export interface ISimpleModel { + getLineContent(lineNumber: number): string; +} + +class SnippetSuggestProvider implements ISuggestSupport { + + constructor( + @IModeService private _modeService: IModeService, + @ISnippetsService private _snippets: ISnippetsService + ) { + // } - private _getSnippetCompletions(model: IModel, position: Position): ISuggestion[] { - const languageId = this._getLanguageIdAtPosition(model, position); - if (!this._snippets.has(languageId)) { - return undefined; - } + provideCompletionItems(model: IModel, position: Position): ISuggestResult { - const result: ISnippetSuggestion[] = []; + const languageId = this._getLanguageIdAtPosition(model, position); + const suggestions: ISnippetSuggestion[] = []; const word = model.getWordAtPosition(position); const currentWord = word ? word.word.substring(0, position.column - word.startColumn).toLowerCase() : ''; const currentFullWord = getNonWhitespacePrefix(model, position).toLowerCase(); - this.visitSnippets(languageId, s => { + this._snippets.visitSnippets(languageId, s => { const prefixLower = s.prefix.toLowerCase(); let overwriteBefore = 0; @@ -118,11 +111,11 @@ class SnippetsService implements ISnippetsService { } // store in result - result.push({ + suggestions.push({ type: 'snippet', label: s.prefix, get disambiguateLabel() { return localize('snippetSuggest.longLabel', "{0}, {1}", s.prefix, s.name); }, - detail: s.extensionName || SnippetsService._defaultDetail, + detail: s.extensionName || localize('detail.userSnippet', "User Snippet"), documentation: s.description, insertText: s.codeSnippet, sortText: `${s.prefix}-${s.extensionName || ''}`, @@ -136,7 +129,7 @@ class SnippetsService implements ISnippetsService { // dismbiguate suggestions with same labels let lastSuggestion: ISnippetSuggestion; - for (const suggestion of result.sort(SnippetsService._compareSuggestionsByLabel)) { + for (const suggestion of suggestions.sort(SnippetSuggestProvider._compareSuggestionsByLabel)) { if (lastSuggestion && lastSuggestion.label === suggestion.label) { // use the disambiguateLabel instead of the actual label lastSuggestion.label = lastSuggestion.disambiguateLabel; @@ -145,7 +138,20 @@ class SnippetsService implements ISnippetsService { lastSuggestion = suggestion; } - return result; + return { suggestions }; + } + + private _getLanguageIdAtPosition(model: IModel, position: Position): LanguageId { + // validate the `languageId` to ensure this is a user + // facing language with a name and the chance to have + // snippets, else fall back to the outer language + model.forceTokenization(position.lineNumber); + let languageId = model.getLanguageIdAtPosition(position.lineNumber, position.column); + let { language } = this._modeService.getLanguageIdentifier(languageId); + if (!this._modeService.getLanguageName(language)) { + languageId = model.getLanguageIdentifier().id; + } + return languageId; } private static _compareSuggestionsByLabel(a: ISuggestion, b: ISuggestion): number { @@ -153,12 +159,6 @@ class SnippetsService implements ISnippetsService { } } -registerSingleton(ISnippetsService, SnippetsService); - -export interface ISimpleModel { - getLineContent(lineNumber: number): string; -} - export function getNonWhitespacePrefix(model: ISimpleModel, position: Position): string { /** * Do not analyze more characters -- GitLab From d5890e4a161fd87ca204de161ec2e42d7279c9b1 Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Tue, 6 Jun 2017 13:45:47 -0700 Subject: [PATCH 0568/1347] Fix #28123 --- build/gulpfile.vscode.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index 66932ddcba6..4c394e8c629 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -43,7 +43,7 @@ const nodeModules = ['electron', 'original-fs'] const builtInExtensions = [ { name: 'ms-vscode.node-debug', version: '1.13.10' }, - { name: 'ms-vscode.node-debug2', version: '1.13.2' } + { name: 'ms-vscode.node-debug2', version: '1.13.3' } ]; const vscodeEntryPoints = _.flatten([ -- GitLab From 544d44350b773f7b5aafaa433e44febcce2b089d Mon Sep 17 00:00:00 2001 From: Jens Hausdorf Date: Tue, 6 Jun 2017 22:51:23 +0200 Subject: [PATCH 0569/1347] remove double semicolons (#28110) --- extensions/html/server/src/modes/languageModes.ts | 2 +- src/vs/editor/common/config/fontInfo.ts | 2 +- src/vs/editor/contrib/find/browser/findWidget.ts | 2 +- src/vs/editor/test/common/model/textModelSearch.test.ts | 2 +- src/vs/workbench/api/electron-browser/mainThreadEditor.ts | 2 +- src/vs/workbench/browser/parts/editor/tabsTitleControl.ts | 4 ++-- src/vs/workbench/parts/debug/electron-browser/debugViewer.ts | 4 ++-- .../workbench/parts/debug/electron-browser/rawDebugSession.ts | 2 +- .../parts/preferences/common/keybindingsEditorModel.ts | 2 +- src/vs/workbench/parts/tasks/common/taskConfiguration.ts | 2 +- test/smoke/src/tests/configuration-views.ts | 2 +- 11 files changed, 13 insertions(+), 13 deletions(-) diff --git a/extensions/html/server/src/modes/languageModes.ts b/extensions/html/server/src/modes/languageModes.ts index 54349b429d8..59851b10851 100644 --- a/extensions/html/server/src/modes/languageModes.ts +++ b/extensions/html/server/src/modes/languageModes.ts @@ -68,7 +68,7 @@ export function getLanguageModes(supportedLanguages: { [languageId: string]: boo } return { getModeAtPosition(document: TextDocument, position: Position): LanguageMode { - let languageId = documentRegions.get(document).getLanguageAtPosition(position);; + let languageId = documentRegions.get(document).getLanguageAtPosition(position); if (languageId) { return modes[languageId]; } diff --git a/src/vs/editor/common/config/fontInfo.ts b/src/vs/editor/common/config/fontInfo.ts index 9ab9a11d2a9..af6a2d82873 100644 --- a/src/vs/editor/common/config/fontInfo.ts +++ b/src/vs/editor/common/config/fontInfo.ts @@ -86,7 +86,7 @@ export class BareFontInfo { lineHeight = 8; } - let letterSpacing = safeParseFloat(opts.letterSpacing, 0);; + let letterSpacing = safeParseFloat(opts.letterSpacing, 0); letterSpacing = clamp(letterSpacing, -20, 20); let editorZoomLevelMultiplier = 1 + (EditorZoom.getZoomLevel() * 0.1); diff --git a/src/vs/editor/contrib/find/browser/findWidget.ts b/src/vs/editor/contrib/find/browser/findWidget.ts index 8eadb32492a..ceecbd9db0c 100644 --- a/src/vs/editor/contrib/find/browser/findWidget.ts +++ b/src/vs/editor/contrib/find/browser/findWidget.ts @@ -81,7 +81,7 @@ export class FindWidgetViewZone implements IViewZone { } export class FindWidget extends Widget implements IOverlayWidget, IHorizontalSashLayoutProvider { - private static ID = 'editor.contrib.findWidget';; + private static ID = 'editor.contrib.findWidget'; private _codeEditor: ICodeEditor; private _state: FindReplaceState; private _controller: IFindController; diff --git a/src/vs/editor/test/common/model/textModelSearch.test.ts b/src/vs/editor/test/common/model/textModelSearch.test.ts index df67b81aa49..97417836da7 100644 --- a/src/vs/editor/test/common/model/textModelSearch.test.ts +++ b/src/vs/editor/test/common/model/textModelSearch.test.ts @@ -31,7 +31,7 @@ suite('TextModelSearch', () => { let match = TextModelSearch.findNextMatch(model, searchParams, startPos, false); assert.deepEqual(match, expectedMatches[0], `findNextMatch ${startPos}`); for (let i = 0; i < expectedMatches.length; i++) { - startPos = expectedMatches[i].range.getStartPosition();; + startPos = expectedMatches[i].range.getStartPosition(); match = TextModelSearch.findNextMatch(model, searchParams, startPos, false); assert.deepEqual(match, expectedMatches[i], `findNextMatch ${startPos}`); } diff --git a/src/vs/workbench/api/electron-browser/mainThreadEditor.ts b/src/vs/workbench/api/electron-browser/mainThreadEditor.ts index cd44f6778a1..a875e16c35e 100644 --- a/src/vs/workbench/api/electron-browser/mainThreadEditor.ts +++ b/src/vs/workbench/api/electron-browser/mainThreadEditor.ts @@ -254,7 +254,7 @@ export class MainThreadTextEditor { break; case TextEditorRevealType.InCenter: this._codeEditor.revealRangeInCenter(range); - break;; + break; case TextEditorRevealType.InCenterIfOutsideViewport: this._codeEditor.revealRangeInCenterIfOutsideViewport(range); break; diff --git a/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts b/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts index 759efa00c16..612f7aff73f 100644 --- a/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts +++ b/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts @@ -272,8 +272,8 @@ export class TabsTitleControl extends TitleControl { // Container tabContainer.setAttribute('aria-label', `${name}, tab`); tabContainer.title = title; - tabContainer.style.borderLeftColor = (index !== 0) ? (this.getColor(TAB_BORDER) || this.getColor(contrastBorder)) : null;; - tabContainer.style.borderRightColor = (index === editorsOfGroup.length - 1) ? (this.getColor(TAB_BORDER) || this.getColor(contrastBorder)) : null;; + tabContainer.style.borderLeftColor = (index !== 0) ? (this.getColor(TAB_BORDER) || this.getColor(contrastBorder)) : null; + tabContainer.style.borderRightColor = (index === editorsOfGroup.length - 1) ? (this.getColor(TAB_BORDER) || this.getColor(contrastBorder)) : null; tabContainer.style.outlineColor = this.getColor(activeContrastBorder); const tabOptions = this.editorGroupService.getTabOptions(); diff --git a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts index 210f9e632e7..41251145877 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts @@ -1029,7 +1029,7 @@ export class BreakpointsActionProvider implements IActionProvider { } public hasActions(tree: ITree, element: any): boolean { - return false;; + return false; } public hasSecondaryActions(tree: ITree, element: any): boolean { @@ -1175,7 +1175,7 @@ export class BreakpointsRenderer implements IRenderer { } private renderExceptionBreakpoint(exceptionBreakpoint: debug.IExceptionBreakpoint, data: IBaseBreakpointTemplateData): void { - data.name.textContent = exceptionBreakpoint.label || `${exceptionBreakpoint.filter} exceptions`;; + data.name.textContent = exceptionBreakpoint.label || `${exceptionBreakpoint.filter} exceptions`; data.breakpoint.title = data.name.textContent; data.checkbox.checked = exceptionBreakpoint.enabled; } diff --git a/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.ts b/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.ts index 0df197051a3..211539a5d4f 100644 --- a/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.ts +++ b/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.ts @@ -278,7 +278,7 @@ export class RawDebugSession extends v8.V8Protocol implements debug.ISession { return this.send('restartFrame', args).then(response => { this.fireFakeContinued(threadId); return response; - });; + }); } public completions(args: DebugProtocol.CompletionsArguments): TPromise { diff --git a/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.ts b/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.ts index 65379a3689f..cce68a1ae07 100644 --- a/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.ts +++ b/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.ts @@ -288,7 +288,7 @@ class KeybindingItemMatches { } private filterAndSort(matches: IMatch[]): IMatch[] { - return distinct(matches, (a => a.start + '.' + a.end)).filter(match => !matches.some(m => !(m.start === match.start && m.end === match.end) && (m.start <= match.start && m.end >= match.end))).sort((a, b) => a.start - b.start);; + return distinct(matches, (a => a.start + '.' + a.end)).filter(match => !matches.some(m => !(m.start === match.start && m.end === match.end) && (m.start <= match.start && m.end >= match.end))).sort((a, b) => a.start - b.start); } private matchesKeybinding(keybinding: ResolvedKeybinding, searchValue: string, words: string[]): KeybindingMatches { diff --git a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts index b89dcfaeca2..cd6ab3b3382 100644 --- a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts +++ b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts @@ -1331,7 +1331,7 @@ class ConfigurationParser { } if ((!result.tasks || result.tasks.length === 0) && (globals.command && globals.command.name)) { - let matchers: ProblemMatcher[] = ProblemMatcherConverter.from(fileConfig.problemMatcher, context);; + let matchers: ProblemMatcher[] = ProblemMatcherConverter.from(fileConfig.problemMatcher, context); let isBackground = fileConfig.isBackground ? !!fileConfig.isBackground : fileConfig.isWatching ? !!fileConfig.isWatching : undefined; let task: Tasks.Task = { _id: context.uuidMap.getUUID(globals.command.name), diff --git a/test/smoke/src/tests/configuration-views.ts b/test/smoke/src/tests/configuration-views.ts index e1241b6bfb5..25938ab1206 100644 --- a/test/smoke/src/tests/configuration-views.ts +++ b/test/smoke/src/tests/configuration-views.ts @@ -47,7 +47,7 @@ export function testConfigViews() { await configView.enterBinding(['Control', 'u', 'NULL']); await common.enter(); let html = await configView.getActivityBar(ActivityBarPosition.RIGHT); - assert.equal(html, undefined);; + assert.equal(html, undefined); await app.wait(); await configView.toggleActivityBarPosition(); html = await configView.getActivityBar(ActivityBarPosition.RIGHT); -- GitLab From a53cce90d3d790607ef36e33c05fa6d688150c31 Mon Sep 17 00:00:00 2001 From: Dustin Campbell Date: Tue, 6 Jun 2017 14:28:34 -0700 Subject: [PATCH 0570/1347] Update C# TextMate grammar with latest fixes from csharp-tmLanguage (#28120) This includes fixes for the following: * C# 7 ref locals and ref returns (https://github.com/dotnet/csharp-tmLanguage/issues/12) * C# 7 throw expressions (https://github.com/dotnet/csharp-tmLanguage/issues/69) --- .../csharp/syntaxes/csharp.tmLanguage.json | 62 ++++++++++++++++--- 1 file changed, 52 insertions(+), 10 deletions(-) diff --git a/extensions/csharp/syntaxes/csharp.tmLanguage.json b/extensions/csharp/syntaxes/csharp.tmLanguage.json index 010852c16e7..1567d53273e 100644 --- a/extensions/csharp/syntaxes/csharp.tmLanguage.json +++ b/extensions/csharp/syntaxes/csharp.tmLanguage.json @@ -4,7 +4,7 @@ "If you want to provide a fix or improvement, please create a pull request against the original repository.", "Once accepted there, we are happy to receive an update request." ], - "version": "https://github.com/dotnet/csharp-tmLanguage/commit/9ef19ad34df99e0e5bf3e0a8e8a1733d1f0c4aca", + "version": "https://github.com/dotnet/csharp-tmLanguage/commit/e7f564b60e08e6d8400d2512918c2ff5ccbf4cec", "name": "C#", "scopeName": "source.cs", "fileTypes": [ @@ -275,6 +275,9 @@ { "include": "#nameof-expression" }, + { + "include": "#throw-expression" + }, { "include": "#interpolated-string" }, @@ -614,7 +617,7 @@ ] }, "delegate-declaration": { - "begin": "(?x)\n(?:\\b(delegate)\\b)\\s+\n(?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)\\s+\n(\\g)\\s*\n(<([^<>]+)>)?\\s*\n(?=\\()", + "begin": "(?x)\n(?:\\b(delegate)\\b)\\s+\n(?\n (?:\n (?:ref\\s+)? # ref return\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)\\s+\n(\\g)\\s*\n(<([^<>]+)>)?\\s*\n(?=\\()", "beginCaptures": { "1": { "name": "keyword.other.delegate.cs" @@ -999,7 +1002,7 @@ ] }, "property-declaration": { - "begin": "(?x)\n(?!.*\\b(?:class|interface|struct|enum|event)\\b)\\s*\n(?\n (?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n )\\s+\n)\n(?\\g\\s*\\.\\s*)?\n(?\\g)\\s*\n(?=\\{|=>|$)", + "begin": "(?x)\n(?!.*\\b(?:class|interface|struct|enum|event)\\b)\\s*\n(?\n (?\n (?:\n (?:ref\\s+)? # ref return\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n )\\s+\n)\n(?\\g\\s*\\.\\s*)?\n(?\\g)\\s*\n(?=\\{|=>|$)", "beginCaptures": { "1": { "patterns": [ @@ -1042,7 +1045,7 @@ ] }, "indexer-declaration": { - "begin": "(?x)\n(?\n (?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n )\\s+\n)\n(?\\g\\s*\\.\\s*)?\n(?this)\\s*\n(?=\\[)", + "begin": "(?x)\n(?\n (?\n (?:\n (?:ref\\s+)? # ref return\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n )\\s+\n)\n(?\\g\\s*\\.\\s*)?\n(?this)\\s*\n(?=\\[)", "beginCaptures": { "1": { "patterns": [ @@ -1215,7 +1218,7 @@ ] }, "method-declaration": { - "begin": "(?x)\n(?\n (?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n )\\s+\n)\n(?\\g\\s*\\.\\s*)?\n(\\g)\\s*\n(<([^<>]+)>)?\\s*\n(?=\\()", + "begin": "(?x)\n(?\n (?\n (?:\n (?:ref\\s+)? # ref return\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n )\\s+\n)\n(?\\g\\s*\\.\\s*)?\n(\\g)\\s*\n(<([^<>]+)>)?\\s*\n(?=\\()", "beginCaptures": { "1": { "patterns": [ @@ -1351,7 +1354,7 @@ ] }, "operator-declaration": { - "begin": "(?x)\n(?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)\\s*\n(?(?:\\b(?:operator)))\\s*\n(?(?:\\+|-|\\*|/|%|&|\\||\\^|\\<\\<|\\>\\>|==|!=|\\>|\\<|\\>=|\\<=|!|~|\\+\\+|--|true|false))\\s*\n(?=\\()", + "begin": "(?x)\n(?\n (?:\n (?:ref\\s+)? # ref return\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)\\s*\n(?(?:\\b(?:operator)))\\s*\n(?(?:\\+|-|\\*|/|%|&|\\||\\^|\\<\\<|\\>\\>|==|!=|\\>|\\<|\\>=|\\<=|!|~|\\+\\+|--|true|false))\\s*\n(?=\\()", "beginCaptures": { "1": { "patterns": [ @@ -1384,7 +1387,7 @@ ] }, "conversion-operator-declaration": { - "begin": "(?x)\n(?(?:\\b(?:explicit|implicit)))\\s*\n(?(?:\\b(?:operator)))\\s*\n(?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)\\s*\n(?=\\()", + "begin": "(?x)\n(?(?:\\b(?:explicit|implicit)))\\s*\n(?(?:\\b(?:operator)))\\s*\n(?\n (?:\n (?:ref\\s+)? # ref return\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n)\\s*\n(?=\\()", "beginCaptures": { "1": { "patterns": [ @@ -1461,6 +1464,9 @@ }, "end": "(?=[,\\)\\];}])", "patterns": [ + { + "include": "#ref-modifier" + }, { "include": "#expression" } @@ -1475,6 +1481,9 @@ }, "end": "(?=[,\\);}])", "patterns": [ + { + "include": "#ref-modifier" + }, { "include": "#expression" } @@ -1526,6 +1535,9 @@ }, "end": "(?=;)", "patterns": [ + { + "include": "#ref-modifier" + }, { "include": "#expression" } @@ -2122,19 +2134,22 @@ ] }, "local-variable-declaration": { - "begin": "(?x)\n(?:\n (\\bvar\\b)|\n (?\n (?:\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n )\n)\\s+\n(\\g)\\s*\n(?=,|;|=|\\))", + "begin": "(?x)\n(?:\n (?:(\\bref)\\s+)?(\\bvar\\b)| # ref local\n (?\n (?:\n (?:ref\\s+)? # ref local\n (?:\n (?:(?[_[:alpha:]][_[:alnum:]]*)\\s*\\:\\:\\s*)? # alias-qualification\n (? # identifier + type arguments (if any)\n \\g\\s*\n (?\\s*<(?:[^<>]|\\g)+>\\s*)?\n )\n (?:\\s*\\.\\s*\\g)* | # Are there any more names being dotted into?\n (?\\s*\\((?:[^\\(\\)]|\\g)+\\))\n )\n (?:\\s*\\*\\s*)* # pointer suffix?\n (?:\\s*\\?\\s*)? # nullable suffix?\n (?:\\s*\\[(?:\\s*,\\s*)*\\]\\s*)* # array suffix?\n )\n )\n)\\s+\n(\\g)\\s*\n(?=,|;|=|\\))", "beginCaptures": { "1": { - "name": "keyword.other.var.cs" + "name": "storage.modifier.cs" }, "2": { + "name": "keyword.other.var.cs" + }, + "3": { "patterns": [ { "include": "#type" } ] }, - "7": { + "8": { "name": "entity.name.variable.local.cs" } }, @@ -2405,6 +2420,20 @@ } ] }, + "throw-expression": { + "begin": "(? Date: Tue, 6 Jun 2017 15:50:38 -0700 Subject: [PATCH 0571/1347] Ignore comments when select next/prev. Fixes #27763 --- extensions/emmet/src/selectItem.ts | 5 +- extensions/emmet/src/selectItemHTML.ts | 105 ++++++++++--------- extensions/emmet/src/selectItemStylesheet.ts | 8 +- extensions/emmet/src/util.ts | 7 +- 4 files changed, 69 insertions(+), 56 deletions(-) diff --git a/extensions/emmet/src/selectItem.ts b/extensions/emmet/src/selectItem.ts index 5ef47062ede..961f3a0dfa5 100644 --- a/extensions/emmet/src/selectItem.ts +++ b/extensions/emmet/src/selectItem.ts @@ -34,7 +34,10 @@ export function fetchSelectItem(direction: string): void { let rootNode: Node = parseContent(editor.document.getText()); let newSelections: vscode.Selection[] = []; editor.selections.forEach(selection => { - let updatedSelection = direction === 'next' ? nextItem(selection, editor, rootNode) : prevItem(selection, editor, rootNode); + const selectionStart = editor.document.offsetAt(selection.isReversed ? selection.active : selection.anchor); + const selectionEnd = editor.document.offsetAt(selection.isReversed ? selection.anchor : selection.active); + + let updatedSelection = direction === 'next' ? nextItem(selectionStart, selectionEnd, editor, rootNode) : prevItem(selectionStart, selectionEnd, editor, rootNode); newSelections.push(updatedSelection ? updatedSelection : selection); }); editor.selections = newSelections; diff --git a/extensions/emmet/src/selectItemHTML.ts b/extensions/emmet/src/selectItemHTML.ts index 2c0be704ead..7aad3f9c2a9 100644 --- a/extensions/emmet/src/selectItemHTML.ts +++ b/extensions/emmet/src/selectItemHTML.ts @@ -7,90 +7,104 @@ import * as vscode from 'vscode'; import { getNode, getDeepestNode, findNextWord, findPrevWord } from './util'; import Node from '@emmetio/node'; -export function nextItemHTML(selection: vscode.Selection, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { - let offset = editor.document.offsetAt(selection.active); - let currentNode = getNode(rootNode, offset); +export function nextItemHTML(selectionStart: number, selectionEnd: number, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { + let currentNode = getNode(rootNode, selectionEnd); + let nextNode: Node; + + if (currentNode.type !== 'comment') { + // If cursor is in the tag name, select tag + if (selectionEnd < currentNode.open.start + currentNode.name.length) { + return getSelectionFromNode(currentNode, editor.document); + } - // Cursor is in the open tag, look for attributes - if (offset < currentNode.open.end) { - let attrSelection = getNextAttribute(selection, editor.document, currentNode); - if (attrSelection) { - return attrSelection; + // If cursor is in the open tag, look for attributes + if (selectionEnd < currentNode.open.end) { + let attrSelection = getNextAttribute(selectionStart, selectionEnd, editor.document, currentNode); + if (attrSelection) { + return attrSelection; + } } - } - // Get the first child of current node which is right after the cursor - let nextNode = currentNode.firstChild; - while (nextNode && nextNode.start < offset) { - nextNode = nextNode.nextSibling; + // Get the first child of current node which is right after the cursor and is not a comment + nextNode = currentNode.firstChild; + while (nextNode && (nextNode.start < selectionEnd || nextNode.type === 'comment')) { + nextNode = nextNode.nextSibling; + } } - // Get next sibling of current node or the parent + + // Get next sibling of current node which is not a comment. If none is found try the same on the parent while (!nextNode && currentNode) { - nextNode = currentNode.nextSibling; - currentNode = currentNode.parent; + if (currentNode.nextSibling) { + if (currentNode.nextSibling.type !== 'comment') { + nextNode = currentNode.nextSibling; + } else { + currentNode = currentNode.nextSibling; + } + } else { + currentNode = currentNode.parent; + } } return getSelectionFromNode(nextNode, editor.document); } -export function prevItemHTML(selection: vscode.Selection, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { - let offset = editor.document.offsetAt(selection.active); - let currentNode = getNode(rootNode, offset); +export function prevItemHTML(selectionStart: number, selectionEnd: number, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { + let currentNode = getNode(rootNode, selectionStart); let prevNode: Node; - // Cursor is in the open tag after the tag name - if (offset > currentNode.open.start + currentNode.name.length + 1 && offset <= currentNode.open.end) { - prevNode = currentNode; - } + if (currentNode.type !== 'comment' && selectionStart > currentNode.open.start + 1) { - // Cursor is inside the tag - if (!prevNode && offset > currentNode.open.end) { - if (!currentNode.firstChild) { - // No children, so current node should be selected + if (selectionStart < currentNode.open.end || !currentNode.firstChild) { prevNode = currentNode; } else { - // Select the child that appears just before the cursor + // Select the child that appears just before the cursor and is not a comment prevNode = currentNode.firstChild; - while (prevNode.nextSibling && prevNode.nextSibling.end < offset) { + let oldOption: Node; + while (prevNode.nextSibling && prevNode.nextSibling.end < selectionStart) { + if (prevNode && prevNode.type !== 'comment') { + oldOption = prevNode; + } prevNode = prevNode.nextSibling; } - if (prevNode) { - prevNode = getDeepestNode(prevNode); - } + + prevNode = getDeepestNode((prevNode && prevNode.type !== 'comment') ? prevNode : oldOption); } } - if (!prevNode && currentNode.previousSibling) { - prevNode = getDeepestNode(currentNode.previousSibling); - } + // Select previous sibling which is not a comment. If none found, then select parent + while (!prevNode && currentNode) { + if (currentNode.previousSibling) { + if (currentNode.previousSibling.type !== 'comment') { + prevNode = getDeepestNode(currentNode.previousSibling); + } else { + currentNode = currentNode.previousSibling; + } + } else { + prevNode = currentNode.parent; + } - if (!prevNode && currentNode.parent) { - prevNode = currentNode.parent; } - let attrSelection = getPrevAttribute(selection, editor.document, prevNode); + let attrSelection = getPrevAttribute(selectionStart, selectionEnd, editor.document, prevNode); return attrSelection ? attrSelection : getSelectionFromNode(prevNode, editor.document); } function getSelectionFromNode(node: Node, document: vscode.TextDocument): vscode.Selection { if (node && node.open) { let selectionStart = document.positionAt(node.open.start + 1); - let selectionEnd = node.type === 'comment' ? document.positionAt(node.open.end - 1) : selectionStart.translate(0, node.name.length); + let selectionEnd = selectionStart.translate(0, node.name.length); return new vscode.Selection(selectionStart, selectionEnd); } } -function getNextAttribute(selection: vscode.Selection, document: vscode.TextDocument, node: Node): vscode.Selection { +function getNextAttribute(selectionStart: number, selectionEnd: number, document: vscode.TextDocument, node: Node): vscode.Selection { if (!node.attributes || node.attributes.length === 0 || node.type === 'comment') { return; } - let selectionStart = document.offsetAt(selection.anchor); - let selectionEnd = document.offsetAt(selection.active); - for (let i = 0; i < node.attributes.length; i++) { let attr = node.attributes[i]; @@ -136,15 +150,12 @@ function getNextAttribute(selection: vscode.Selection, document: vscode.TextDocu } } -function getPrevAttribute(selection: vscode.Selection, document: vscode.TextDocument, node: Node): vscode.Selection { +function getPrevAttribute(selectionStart: number, selectionEnd: number, document: vscode.TextDocument, node: Node): vscode.Selection { if (!node.attributes || node.attributes.length === 0 || node.type === 'comment') { return; } - let selectionStart = document.offsetAt(selection.anchor); - let selectionEnd = document.offsetAt(selection.active); - for (let i = node.attributes.length - 1; i >= 0; i--) { let attr = node.attributes[i]; diff --git a/extensions/emmet/src/selectItemStylesheet.ts b/extensions/emmet/src/selectItemStylesheet.ts index e3144cbf666..0a11f5e5e33 100644 --- a/extensions/emmet/src/selectItemStylesheet.ts +++ b/extensions/emmet/src/selectItemStylesheet.ts @@ -7,9 +7,7 @@ import * as vscode from 'vscode'; import { getNode, getDeepestNode, findNextWord, findPrevWord } from './util'; import Node from '@emmetio/node'; -export function nextItemStylesheet(selection: vscode.Selection, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { - let startOffset = editor.document.offsetAt(selection.anchor); - let endOffset = editor.document.offsetAt(selection.active); +export function nextItemStylesheet(startOffset: number, endOffset: number, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { let currentNode = getNode(rootNode, endOffset, true); // Full property is selected, so select full property value next @@ -47,9 +45,7 @@ export function nextItemStylesheet(selection: vscode.Selection, editor: vscode.T } -export function prevItemStylesheet(selection: vscode.Selection, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { - let startOffset = editor.document.offsetAt(selection.anchor); - let endOffset = editor.document.offsetAt(selection.active); +export function prevItemStylesheet(startOffset: number, endOffset: number, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { let currentNode = getNode(rootNode, startOffset); if (!currentNode) { currentNode = rootNode; diff --git a/extensions/emmet/src/util.ts b/extensions/emmet/src/util.ts index 81085e5b6d6..d6b80549fdf 100644 --- a/extensions/emmet/src/util.ts +++ b/extensions/emmet/src/util.ts @@ -134,8 +134,11 @@ export function getDeepestNode(node: Node): Node { if (!node || !node.children || node.children.length === 0) { return node; } - - return getDeepestNode(node.children[node.children.length - 1]); + for (let i = node.children.length - 1; i >= 0; i--) { + if (node.children[i].type !== 'comment') { + return getDeepestNode(node.children[i]); + } + } } export function findNextWord(propertyValue: string, pos: number): [number, number] { -- GitLab From fbb786088eb0413f26e781fd4c4ad9fb5f7dcec2 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Tue, 6 Jun 2017 15:43:43 -0700 Subject: [PATCH 0572/1347] Remove experimental autobuild --- extensions/typescript/package.nls.json | 1 - .../src/features/bufferSyncSupport.ts | 2 +- extensions/typescript/src/typescriptMain.ts | 5 ++--- extensions/typescript/src/typescriptService.ts | 1 - .../typescript/src/typescriptServiceClient.ts | 18 ++---------------- 5 files changed, 5 insertions(+), 22 deletions(-) diff --git a/extensions/typescript/package.nls.json b/extensions/typescript/package.nls.json index c2cf5917496..d2028875402 100644 --- a/extensions/typescript/package.nls.json +++ b/extensions/typescript/package.nls.json @@ -8,7 +8,6 @@ "typescript.check.tscVersion": "Check if a global install TypeScript compiler (e.g. tsc) differs from the used TypeScript language service.", "typescript.tsserver.log": "Enables logging of the TS server to a file. This log can be used to diagnose TS Server issues. The log may contain file paths, source code, and other potentially sensitive information from your project.", "typescript.tsserver.trace": "Enables tracing of messages sent to the TS server. This trace can be used to diagnose TS Server issues. The trace may contain file paths, source code, and other potentially sensitive information from your project.", - "typescript.tsserver.experimentalAutoBuild": "Enables experimental auto build. Requires 1.9 dev or 2.x tsserver version and a restart of VS Code after changing it.", "typescript.validate.enable": "Enable/disable TypeScript validation.", "typescript.format.enable": "Enable/disable default TypeScript formatter.", "javascript.format.enable": "Enable/disable default JavaScript formatter.", diff --git a/extensions/typescript/src/features/bufferSyncSupport.ts b/extensions/typescript/src/features/bufferSyncSupport.ts index 9cdaf802b21..216eebde2ed 100644 --- a/extensions/typescript/src/features/bufferSyncSupport.ts +++ b/extensions/typescript/src/features/bufferSyncSupport.ts @@ -229,7 +229,7 @@ export default class BufferSyncSupport { } public requestDiagnostic(file: string): void { - if (!this._validate || this.client.experimentalAutoBuild) { + if (!this._validate) { return; } diff --git a/extensions/typescript/src/typescriptMain.ts b/extensions/typescript/src/typescriptMain.ts index e217aa00400..50d5d4cc980 100644 --- a/extensions/typescript/src/typescriptMain.ts +++ b/extensions/typescript/src/typescriptMain.ts @@ -94,7 +94,7 @@ export function activate(context: ExtensionContext): void { let clientHost: TypeScriptServiceClientHost | undefined; return () => { if (!clientHost) { - clientHost = new TypeScriptServiceClientHost(standardLanguageDescriptions, context.storagePath, context.workspaceState, plugins); + clientHost = new TypeScriptServiceClientHost(standardLanguageDescriptions, context.workspaceState, plugins); context.subscriptions.push(clientHost); const host = clientHost; @@ -456,7 +456,6 @@ class TypeScriptServiceClientHost implements ITypescriptServiceClientHost { constructor( descriptions: LanguageDescription[], - storagePath: string | undefined, workspaceState: Memento, plugins: TypeScriptServerPlugin[] ) { @@ -478,7 +477,7 @@ class TypeScriptServiceClientHost implements ITypescriptServiceClientHost { this.versionStatus = new VersionStatus(); this.disposables.push(this.versionStatus); - this.client = new TypeScriptServiceClient(this, storagePath, workspaceState, this.versionStatus, plugins, this.disposables); + this.client = new TypeScriptServiceClient(this, workspaceState, this.versionStatus, plugins, this.disposables); this.languagePerId = Object.create(null); for (const description of descriptions) { const manager = new LanguageProvider(this.client, description); diff --git a/extensions/typescript/src/typescriptService.ts b/extensions/typescript/src/typescriptService.ts index dd24447e929..f2ad09da59a 100644 --- a/extensions/typescript/src/typescriptService.ts +++ b/extensions/typescript/src/typescriptService.ts @@ -85,7 +85,6 @@ export interface ITypescriptServiceClient { logTelemetry(eventName: string, properties?: { [prop: string]: string }): void; - experimentalAutoBuild: boolean; apiVersion: API; checkGlobalTSCVersion: boolean; diff --git a/extensions/typescript/src/typescriptServiceClient.ts b/extensions/typescript/src/typescriptServiceClient.ts index 4f68a6991fb..ba756961c9b 100644 --- a/extensions/typescript/src/typescriptServiceClient.ts +++ b/extensions/typescript/src/typescriptServiceClient.ts @@ -20,10 +20,10 @@ import Logger from './utils/logger'; import VersionStatus from './utils/versionStatus'; import * as is from './utils/is'; +import TelemetryReporter from './utils/telemetry'; +import Tracer from './utils/tracer'; import * as nls from 'vscode-nls'; -import TelemetryReporter from "./utils/telemetry"; -import Tracer from "./utils/tracer"; const localize = nls.loadMessageBundle(); interface CallbackItem { @@ -231,7 +231,6 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient private _onReady: { promise: Promise; resolve: () => void; reject: () => void; }; private configuration: TypeScriptServiceConfiguration; private _checkGlobalTSCVersion: boolean; - private _experimentalAutoBuild: boolean; private tracer: Tracer; private readonly logger: Logger = new Logger(); private tsServerLogFile: string | null = null; @@ -256,7 +255,6 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient constructor( private readonly host: ITypescriptServiceClientHost, - private readonly storagePath: string | undefined, private readonly workspaceState: Memento, private readonly versionStatus: VersionStatus, private readonly plugins: TypeScriptServerPlugin[], @@ -279,7 +277,6 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient this.callbacks = new CallbackMap(); this.configuration = TypeScriptServiceConfiguration.loadFromWorkspace(); - this._experimentalAutoBuild = false; // configuration.get('typescript.tsserver.experimentalAutoBuild', false); this._apiVersion = new API('1.0.0'); this._checkGlobalTSCVersion = true; this.tracer = new Tracer(this.logger); @@ -338,10 +335,6 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient return this._onTypesInstallerInitializationFailed.event; } - public get experimentalAutoBuild(): boolean { - return this._experimentalAutoBuild; - } - public get checkGlobalTSCVersion(): boolean { return this._checkGlobalTSCVersion; } @@ -741,13 +734,6 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient let configureOptions: Proto.ConfigureRequestArguments = { hostInfo: 'vscode' }; - if (this._experimentalAutoBuild && this.storagePath) { - try { - fs.mkdirSync(this.storagePath); - } catch (error) { - } - // configureOptions.autoDiagnostics = true; - } this.execute('configure', configureOptions); this.setCompilerOptionsForInferredProjects(); if (resendModels) { -- GitLab From d808a55641c93f912aa360f79b3f6ba50713cf5c Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Tue, 6 Jun 2017 15:46:01 -0700 Subject: [PATCH 0573/1347] Remove buildstatus --- extensions/typescript/src/typescriptMain.ts | 8 ------- .../typescript/src/utils/buildStatus.ts | 21 ------------------- 2 files changed, 29 deletions(-) delete mode 100644 extensions/typescript/src/utils/buildStatus.ts diff --git a/extensions/typescript/src/typescriptMain.ts b/extensions/typescript/src/typescriptMain.ts index 50d5d4cc980..be294238123 100644 --- a/extensions/typescript/src/typescriptMain.ts +++ b/extensions/typescript/src/typescriptMain.ts @@ -45,7 +45,6 @@ import TypeScriptTaskProviderManager from './features/taskProvider'; import ImplementationCodeLensProvider from './features/implementationsCodeLensProvider'; -import * as BuildStatus from './utils/buildStatus'; import * as ProjectStatus from './utils/projectStatus'; import TypingsStatus, { AtaProgressReporter } from './utils/typingsStatus'; import VersionStatus from './utils/versionStatus'; @@ -161,8 +160,6 @@ export function activate(context: ExtensionContext): void { break; } } - - BuildStatus.update({ queueLength: 0 }); } @@ -658,11 +655,6 @@ class TypeScriptServiceClientHost implements ITypescriptServiceClientHost { } }); } - /* - if (Is.defined(body.queueLength)) { - BuildStatus.update({ queueLength: body.queueLength }); - } - */ } /* internal */ configFileDiagnosticsReceived(event: Proto.ConfigFileDiagnosticEvent): void { diff --git a/extensions/typescript/src/utils/buildStatus.ts b/extensions/typescript/src/utils/buildStatus.ts deleted file mode 100644 index ced56fd43b9..00000000000 --- a/extensions/typescript/src/utils/buildStatus.ts +++ /dev/null @@ -1,21 +0,0 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ - -import vscode = require('vscode'); - -const statusItem: vscode.StatusBarItem = vscode.window.createStatusBarItem(vscode.StatusBarAlignment.Left, Number.MIN_VALUE); - -export interface BuildInfo { - queueLength: number; -} - -export function update(info: BuildInfo): void { - if (info.queueLength === 0) { - statusItem.hide(); - return; - } - statusItem.text = info.queueLength.toString(); - statusItem.show(); -} \ No newline at end of file -- GitLab From 94cf0f8e78f1d005d15fbb110e3c247ea7c01b53 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Tue, 6 Jun 2017 16:03:05 -0700 Subject: [PATCH 0574/1347] Use map for syncedBuffers --- .../src/features/bufferSyncSupport.ts | 48 ++++++++----------- 1 file changed, 19 insertions(+), 29 deletions(-) diff --git a/extensions/typescript/src/features/bufferSyncSupport.ts b/extensions/typescript/src/features/bufferSyncSupport.ts index 216eebde2ed..7fcf7103e34 100644 --- a/extensions/typescript/src/features/bufferSyncSupport.ts +++ b/extensions/typescript/src/features/bufferSyncSupport.ts @@ -104,7 +104,7 @@ export default class BufferSyncSupport { private readonly modeIds: Set; private readonly diagnostics: Diagnostics; private readonly disposables: Disposable[] = []; - private readonly syncedBuffers: ObjectMap; + private readonly syncedBuffers: Map; private pendingDiagnostics: { [key: string]: number; }; private readonly diagnosticDelayer: Delayer; @@ -119,7 +119,7 @@ export default class BufferSyncSupport { this.pendingDiagnostics = Object.create(null); this.diagnosticDelayer = new Delayer(300); - this.syncedBuffers = Object.create(null); + this.syncedBuffers = new Map(); const tsConfig = workspace.getConfiguration('typescript'); this.checkGlobalTSCVersion = client.checkGlobalTSCVersion && this.modeIds.has('typescript') && tsConfig.get(checkTscVersionSettingKey, true); @@ -129,7 +129,6 @@ export default class BufferSyncSupport { workspace.onDidOpenTextDocument(this.onDidOpenTextDocument, this, this.disposables); workspace.onDidCloseTextDocument(this.onDidCloseTextDocument, this, this.disposables); workspace.onDidChangeTextDocument(this.onDidChangeTextDocument, this, this.disposables); - workspace.onDidSaveTextDocument(this.onDidSaveTextDocument, this, this.disposables); workspace.textDocuments.forEach(this.onDidOpenTextDocument, this); } @@ -142,13 +141,13 @@ export default class BufferSyncSupport { } public handles(file: string): boolean { - return !!this.syncedBuffers[file]; + return this.syncedBuffers.has(file); } public reOpenDocuments(): void { - Object.keys(this.syncedBuffers).forEach(key => { - this.syncedBuffers[key].open(); - }); + for (const buffer of this.syncedBuffers.values()) { + buffer.open(); + } } public dispose(): void { @@ -164,13 +163,13 @@ export default class BufferSyncSupport { if (!this.modeIds.has(document.languageId)) { return; } - let resource = document.uri; - let filepath = this.client.normalizePath(resource); + const resource = document.uri; + const filepath = this.client.normalizePath(resource); if (!filepath) { return; } - let syncedBuffer = new SyncedBuffer(document, filepath, this, this.client); - this.syncedBuffers[filepath] = syncedBuffer; + const syncedBuffer = new SyncedBuffer(document, filepath, this, this.client); + this.syncedBuffers.set(filepath, syncedBuffer); syncedBuffer.open(); this.requestDiagnostic(filepath); if (document.languageId === 'typescript' || document.languageId === 'typescriptreact') { @@ -183,12 +182,12 @@ export default class BufferSyncSupport { if (!filepath) { return; } - let syncedBuffer = this.syncedBuffers[filepath]; + const syncedBuffer = this.syncedBuffers.get(filepath); if (!syncedBuffer) { return; } this.diagnostics.delete(filepath); - delete this.syncedBuffers[filepath]; + this.syncedBuffers.delete(filepath); syncedBuffer.close(); if (!fs.existsSync(filepath)) { this.requestAllDiagnostics(); @@ -200,29 +199,20 @@ export default class BufferSyncSupport { if (!filepath) { return; } - let syncedBuffer = this.syncedBuffers[filepath]; + let syncedBuffer = this.syncedBuffers.get(filepath); if (!syncedBuffer) { return; } syncedBuffer.onContentChanged(e.contentChanges); } - private onDidSaveTextDocument(document: TextDocument): void { - let filepath = this.client.normalizePath(document.uri); - if (!filepath) { - return; - } - let syncedBuffer = this.syncedBuffers[filepath]; - if (!syncedBuffer) { - return; - } - } - public requestAllDiagnostics() { if (!this._validate) { return; } - Object.keys(this.syncedBuffers).forEach(filePath => this.pendingDiagnostics[filePath] = Date.now()); + for (const filePath of this.syncedBuffers.keys()) { + this.pendingDiagnostics[filePath] = Date.now(); + } this.diagnosticDelayer.trigger(() => { this.sendPendingDiagnostics(); }, 200); @@ -234,7 +224,7 @@ export default class BufferSyncSupport { } this.pendingDiagnostics[file] = Date.now(); - let buffer = this.syncedBuffers[file]; + const buffer = this.syncedBuffers.get(file); let delay = 300; if (buffer) { let lineCount = buffer.lineCount; @@ -261,11 +251,11 @@ export default class BufferSyncSupport { }); // Add all open TS buffers to the geterr request. They might be visible - Object.keys(this.syncedBuffers).forEach((file) => { + for (const file of this.syncedBuffers.keys()) { if (!this.pendingDiagnostics[file]) { files.push(file); } - }); + } let args: Proto.GeterrRequestArgs = { delay: 0, -- GitLab From 7968d90989e014bc0ef66dc08b6530bedc8ed81d Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Tue, 6 Jun 2017 16:13:22 -0700 Subject: [PATCH 0575/1347] Extract dispatch blocks to own functions --- .../typescript/src/typescriptServiceClient.ts | 125 ++++++++++-------- 1 file changed, 67 insertions(+), 58 deletions(-) diff --git a/extensions/typescript/src/typescriptServiceClient.ts b/extensions/typescript/src/typescriptServiceClient.ts index ba756961c9b..7a4581674e1 100644 --- a/extensions/typescript/src/typescriptServiceClient.ts +++ b/extensions/typescript/src/typescriptServiceClient.ts @@ -973,64 +973,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient } else if (message.type === 'event') { const event: Proto.Event = message; this.tracer.traceEvent(event); - if (event.event === 'syntaxDiag') { - this.host.syntaxDiagnosticsReceived(event as Proto.DiagnosticEvent); - } else if (event.event === 'semanticDiag') { - this.host.semanticDiagnosticsReceived(event as Proto.DiagnosticEvent); - } else if (event.event === 'configFileDiag') { - this.host.configFileDiagnosticsReceived(event as Proto.ConfigFileDiagnosticEvent); - } else if (event.event === 'telemetry') { - let telemetryData = (event as Proto.TelemetryEvent).body; - let properties: ObjectMap = Object.create(null); - switch (telemetryData.telemetryEventName) { - case 'typingsInstalled': - let typingsInstalledPayload: Proto.TypingsInstalledTelemetryEventPayload = (telemetryData.payload as Proto.TypingsInstalledTelemetryEventPayload); - properties['installedPackages'] = typingsInstalledPayload.installedPackages; - - if (is.defined(typingsInstalledPayload.installSuccess)) { - properties['installSuccess'] = typingsInstalledPayload.installSuccess.toString(); - } - if (is.string(typingsInstalledPayload.typingsInstallerVersion)) { - properties['typingsInstallerVersion'] = typingsInstalledPayload.typingsInstallerVersion; - } - break; - default: - let payload = telemetryData.payload; - if (payload) { - Object.keys(payload).forEach((key) => { - try { - if (payload.hasOwnProperty(key)) { - properties[key] = is.string(payload[key]) ? payload[key] : JSON.stringify(payload[key]); - } - } catch (e) { - // noop - } - }); - } - break; - } - this.logTelemetry(telemetryData.telemetryEventName, properties); - } else if (event.event === 'projectLanguageServiceState') { - const data = (event as Proto.ProjectLanguageServiceStateEvent).body; - if (data) { - this._onProjectLanguageServiceStateChanged.fire(data); - } - } else if (event.event === 'beginInstallTypes') { - const data = (event as Proto.BeginInstallTypesEvent).body; - if (data) { - this._onDidBeginInstallTypings.fire(data); - } - } else if (event.event === 'endInstallTypes') { - const data = (event as Proto.EndInstallTypesEvent).body; - if (data) { - this._onDidEndInstallTypings.fire(data); - } - } else if (event.event === 'typesInstallerInitializationFailed') { - const data = (event as Proto.TypesInstallerInitializationFailedEvent).body; - if (data) { - this._onTypesInstallerInitializationFailed.fire(data); - } - } + this.dispatchEvent(event); } else { throw new Error('Unknown message type ' + message.type + ' recevied'); } @@ -1038,4 +981,70 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient this.sendNextRequests(); } } + + private dispatchEvent(event: Proto.Event) { + if (event.event === 'syntaxDiag') { + this.host.syntaxDiagnosticsReceived(event as Proto.DiagnosticEvent); + } else if (event.event === 'semanticDiag') { + this.host.semanticDiagnosticsReceived(event as Proto.DiagnosticEvent); + } else if (event.event === 'configFileDiag') { + this.host.configFileDiagnosticsReceived(event as Proto.ConfigFileDiagnosticEvent); + } else if (event.event === 'telemetry') { + let telemetryData = (event as Proto.TelemetryEvent).body; + this.dispatchTelemetryEvent(telemetryData); + } else if (event.event === 'projectLanguageServiceState') { + const data = (event as Proto.ProjectLanguageServiceStateEvent).body; + if (data) { + this._onProjectLanguageServiceStateChanged.fire(data); + } + } else if (event.event === 'beginInstallTypes') { + const data = (event as Proto.BeginInstallTypesEvent).body; + if (data) { + this._onDidBeginInstallTypings.fire(data); + } + } else if (event.event === 'endInstallTypes') { + const data = (event as Proto.EndInstallTypesEvent).body; + if (data) { + this._onDidEndInstallTypings.fire(data); + } + } else if (event.event === 'typesInstallerInitializationFailed') { + const data = (event as Proto.TypesInstallerInitializationFailedEvent).body; + if (data) { + this._onTypesInstallerInitializationFailed.fire(data); + } + } + } + + private dispatchTelemetryEvent(telemetryData: Proto.TelemetryEventBody): void { + const properties: ObjectMap = Object.create(null); + switch (telemetryData.telemetryEventName) { + case 'typingsInstalled': + const typingsInstalledPayload: Proto.TypingsInstalledTelemetryEventPayload = (telemetryData.payload as Proto.TypingsInstalledTelemetryEventPayload); + properties['installedPackages'] = typingsInstalledPayload.installedPackages; + + if (is.defined(typingsInstalledPayload.installSuccess)) { + properties['installSuccess'] = typingsInstalledPayload.installSuccess.toString(); + } + if (is.string(typingsInstalledPayload.typingsInstallerVersion)) { + properties['typingsInstallerVersion'] = typingsInstalledPayload.typingsInstallerVersion; + } + break; + + default: + const payload = telemetryData.payload; + if (payload) { + Object.keys(payload).forEach((key) => { + try { + if (payload.hasOwnProperty(key)) { + properties[key] = is.string(payload[key]) ? payload[key] : JSON.stringify(payload[key]); + } + } catch (e) { + // noop + } + }); + } + break; + } + this.logTelemetry(telemetryData.telemetryEventName, properties); + } } \ No newline at end of file -- GitLab From a5c9a7c58c5d253ab691ea2842759ae41a7e2399 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Tue, 6 Jun 2017 17:52:58 -0700 Subject: [PATCH 0576/1347] Open config file when configure excludes status bar item is clicked. Fixes #21215 --- .../typescript/src/features/taskProvider.ts | 6 +-- extensions/typescript/src/typescriptMain.ts | 24 ++------- .../typescript/src/typescriptServiceClient.ts | 2 +- .../typescript/src/utils/projectStatus.ts | 54 +++++++------------ extensions/typescript/src/utils/tsconfig.ts | 36 +++++++++++++ .../typescript/src/utils/wireProtocol.ts | 2 +- 6 files changed, 65 insertions(+), 59 deletions(-) create mode 100644 extensions/typescript/src/utils/tsconfig.ts diff --git a/extensions/typescript/src/features/taskProvider.ts b/extensions/typescript/src/features/taskProvider.ts index 9cb0a3a64a8..fc15145b65e 100644 --- a/extensions/typescript/src/features/taskProvider.ts +++ b/extensions/typescript/src/features/taskProvider.ts @@ -11,8 +11,8 @@ import * as vscode from 'vscode'; import * as Proto from '../protocol'; import TypeScriptServiceClient from '../typescriptServiceClient'; -import TsConfigProvider from "../utils/tsconfigProvider"; - +import TsConfigProvider from '../utils/tsconfigProvider'; +import { isImplicitProjectConfigFile } from '../utils/tsconfig'; const exists = (file: string): Promise => new Promise((resolve, _reject) => { @@ -89,7 +89,7 @@ class TscTaskProvider implements vscode.TaskProvider { } const { configFileName } = res.body; - if (configFileName && configFileName.indexOf('/dev/null/') !== 0) { + if (configFileName && !isImplicitProjectConfigFile(configFileName)) { return [configFileName]; } return []; diff --git a/extensions/typescript/src/typescriptMain.ts b/extensions/typescript/src/typescriptMain.ts index be294238123..67e04f4df2e 100644 --- a/extensions/typescript/src/typescriptMain.ts +++ b/extensions/typescript/src/typescriptMain.ts @@ -8,7 +8,7 @@ * https://github.com/Microsoft/TypeScript-Sublime-Plugin/blob/master/TypeScript%20Indent.tmPreferences * ------------------------------------------------------------------------------------------ */ -import { env, languages, commands, workspace, window, ExtensionContext, Memento, IndentAction, Diagnostic, DiagnosticCollection, Range, Disposable, Uri, MessageItem, TextEditor, DiagnosticSeverity, TextDocument, SnippetString } from 'vscode'; +import { env, languages, commands, workspace, window, ExtensionContext, Memento, IndentAction, Diagnostic, DiagnosticCollection, Range, Disposable, Uri, MessageItem, TextEditor, DiagnosticSeverity, TextDocument } from 'vscode'; // This must be the first statement otherwise modules might got loaded with // the wrong locale. @@ -48,7 +48,8 @@ import ImplementationCodeLensProvider from './features/implementationsCodeLensPr import * as ProjectStatus from './utils/projectStatus'; import TypingsStatus, { AtaProgressReporter } from './utils/typingsStatus'; import VersionStatus from './utils/versionStatus'; -import { getContributedTypeScriptServerPlugins, TypeScriptServerPlugin } from "./utils/plugins"; +import { getContributedTypeScriptServerPlugins, TypeScriptServerPlugin } from './utils/plugins'; +import { openOrCreateConfigFile, isImplicitProjectConfigFile } from './utils/tsconfig'; interface LanguageDescription { id: string; @@ -560,7 +561,7 @@ class TypeScriptServiceClientHost implements ITypescriptServiceClientHost { } const { configFileName } = res.body; - if (configFileName && configFileName.indexOf('/dev/null/') !== 0) { + if (configFileName && !isImplicitProjectConfigFile(configFileName)) { return workspace.openTextDocument(configFileName) .then(doc => window.showTextDocument(doc, window.activeTextEditor ? window.activeTextEditor.viewColumn : undefined)); @@ -581,22 +582,7 @@ class TypeScriptServiceClientHost implements ITypescriptServiceClientHost { }).then(selected => { switch (selected && selected.id) { case ProjectConfigAction.CreateConfig: - const configFile = Uri.file(path.join(rootPath, isTypeScriptProject ? 'tsconfig.json' : 'jsconfig.json')); - const col = window.activeTextEditor ? window.activeTextEditor.viewColumn : undefined; - return workspace.openTextDocument(configFile) - .then(doc => { - return window.showTextDocument(doc, col); - }, _ => { - return workspace.openTextDocument(configFile.with({ scheme: 'untitled' })) - .then(doc => window.showTextDocument(doc, col)) - .then(editor => { - if (editor.document.getText().length === 0) { - return editor.insertSnippet(new SnippetString('{\n\t$0\n}')) - .then(_ => editor); - } - return editor; - }); - }); + return openOrCreateConfigFile(isTypeScriptProject); case ProjectConfigAction.LearnMore: if (isTypeScriptProject) { diff --git a/extensions/typescript/src/typescriptServiceClient.ts b/extensions/typescript/src/typescriptServiceClient.ts index 7a4581674e1..62b3c53f369 100644 --- a/extensions/typescript/src/typescriptServiceClient.ts +++ b/extensions/typescript/src/typescriptServiceClient.ts @@ -990,7 +990,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient } else if (event.event === 'configFileDiag') { this.host.configFileDiagnosticsReceived(event as Proto.ConfigFileDiagnosticEvent); } else if (event.event === 'telemetry') { - let telemetryData = (event as Proto.TelemetryEvent).body; + const telemetryData = (event as Proto.TelemetryEvent).body; this.dispatchTelemetryEvent(telemetryData); } else if (event.event === 'projectLanguageServiceState') { const data = (event as Proto.ProjectLanguageServiceStateEvent).body; diff --git a/extensions/typescript/src/utils/projectStatus.ts b/extensions/typescript/src/utils/projectStatus.ts index 8c9911531eb..65fa9dd6c2f 100644 --- a/extensions/typescript/src/utils/projectStatus.ts +++ b/extensions/typescript/src/utils/projectStatus.ts @@ -6,18 +6,15 @@ import * as vscode from 'vscode'; import { ITypescriptServiceClient } from '../typescriptService'; import { loadMessageBundle } from 'vscode-nls'; -import { dirname, join } from 'path'; +import { dirname } from 'path'; +import { openOrCreateConfigFile, isImplicitProjectConfigFile } from './tsconfig'; const localize = loadMessageBundle(); const selector = ['javascript', 'javascriptreact']; -interface Option extends vscode.MessageItem { - execute(): void; -} interface Hint { message: string; - options: Option[]; } interface ProjectHintedMap { @@ -45,29 +42,11 @@ class ExcludeHintItem { this._item.hide(); } - public show(configFileName: string, largeRoots: string, onExecute: () => void) { + public show(largeRoots: string) { this._currentHint = { message: largeRoots.length > 0 ? localize('hintExclude', "To enable project-wide JavaScript/TypeScript language features, exclude folders with many files, like: {0}", largeRoots) - : localize('hintExclude.generic', "To enable project-wide JavaScript/TypeScript language features, exclude large folders with source files that you do not work on."), - options: [{ - title: localize('open', "Configure Excludes"), - execute: () => { - this._client.logTelemetry('js.hintProjectExcludes.accepted'); - onExecute(); - this._item.hide(); - - let configFileUri: vscode.Uri; - if (vscode.workspace.rootPath && dirname(configFileName).indexOf(vscode.workspace.rootPath) === 0) { - configFileUri = vscode.Uri.file(configFileName); - } else { - configFileUri = vscode.Uri.parse('untitled://' + join(vscode.workspace.rootPath || '', 'jsconfig.json')); - } - - return vscode.workspace.openTextDocument(configFileName) - .then(vscode.window.showTextDocument); - } - }] + : localize('hintExclude.generic', "To enable project-wide JavaScript/TypeScript language features, exclude large folders with source files that you do not work on.") }; this._item.tooltip = this._currentHint.message; this._item.text = localize('large.label', "Configure Excludes"); @@ -120,9 +99,8 @@ function createLargeProjectMonitorForProject(item: ExcludeHintItem, client: ITyp if (fileNames.length > fileLimit || res.body.languageServiceDisabled) { let largeRoots = computeLargeRoots(configFileName, fileNames).map(f => `'/${f}/'`).join(', '); - item.show(configFileName, largeRoots, () => { - projectHinted[configFileName] = true; - }); + item.show(largeRoots); + projectHinted[configFileName] = true; } else { item.hide(); } @@ -147,7 +125,17 @@ function createLargeProjectMonitorFromTypeScript(item: ExcludeHintItem, client: if (body.languageServiceEnabled) { item.hide(); } else { - item.show(body.projectName, '', () => { }); + const configFileName = body.projectName; + if (configFileName) { + if (!isImplicitProjectConfigFile(configFileName)) { + vscode.workspace.openTextDocument(configFileName) + .then(vscode.window.showTextDocument); + } else { + openOrCreateConfigFile(configFileName.match(/tsconfig\.?.*\.json/) !== null); + } + } + + item.show(''); } }); } @@ -157,12 +145,8 @@ export function create(client: ITypescriptServiceClient, isOpen: (path: string) let item = new ExcludeHintItem(client); toDispose.push(vscode.commands.registerCommand('js.projectStatus.command', () => { - let { message, options } = item.getCurrentHint(); - return vscode.window.showInformationMessage(message, ...options).then(selection => { - if (selection) { - return selection.execute(); - } - }); + let { message } = item.getCurrentHint(); + return vscode.window.showInformationMessage(message); })); if (client.apiVersion.has213Features()) { diff --git a/extensions/typescript/src/utils/tsconfig.ts b/extensions/typescript/src/utils/tsconfig.ts new file mode 100644 index 00000000000..afa6b4b97eb --- /dev/null +++ b/extensions/typescript/src/utils/tsconfig.ts @@ -0,0 +1,36 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as vscode from 'vscode'; +import * as path from 'path'; + +export function isImplicitProjectConfigFile(configFileName: string) { + return configFileName.indexOf('/dev/null/') === 0; +} + +export function openOrCreateConfigFile( + isTypeScriptProject: boolean +): Thenable { + if (!vscode.workspace.rootPath) { + return Promise.resolve(null); + } + + const configFile = vscode.Uri.file(path.join(vscode.workspace.rootPath, isTypeScriptProject ? 'tsconfig.json' : 'jsconfig.json')); + const col = vscode.window.activeTextEditor ? vscode.window.activeTextEditor.viewColumn : undefined; + return vscode.workspace.openTextDocument(configFile) + .then(doc => { + return vscode.window.showTextDocument(doc, col); + }, _ => { + return vscode.workspace.openTextDocument(configFile.with({ scheme: 'untitled' })) + .then(doc => vscode.window.showTextDocument(doc, col)) + .then(editor => { + if (editor.document.getText().length === 0) { + return editor.insertSnippet(new vscode.SnippetString('{\n\t$0\n}')) + .then(_ => editor); + } + return editor; + }); + }); +} \ No newline at end of file diff --git a/extensions/typescript/src/utils/wireProtocol.ts b/extensions/typescript/src/utils/wireProtocol.ts index ad5d464304d..799ec78da52 100644 --- a/extensions/typescript/src/utils/wireProtocol.ts +++ b/extensions/typescript/src/utils/wireProtocol.ts @@ -3,7 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import stream = require('stream'); +import * as stream from 'stream'; const DefaultSize: number = 8192; const ContentLength: string = 'Content-Length: '; -- GitLab From 0da90fcc62c44d2ac99ce45c8f0fbd4ac53a95f2 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Tue, 6 Jun 2017 18:17:36 -0700 Subject: [PATCH 0577/1347] toggle comment across html nodes #27629 --- extensions/emmet/src/toggleComment.ts | 30 ++++++++++------ extensions/emmet/src/util.ts | 51 +++++++++++++++++++++++++++ 2 files changed, 71 insertions(+), 10 deletions(-) diff --git a/extensions/emmet/src/toggleComment.ts b/extensions/emmet/src/toggleComment.ts index 17aabeaca44..b26e31ad1e2 100644 --- a/extensions/emmet/src/toggleComment.ts +++ b/extensions/emmet/src/toggleComment.ts @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ import * as vscode from 'vscode'; -import { getNode, isStyleSheet } from './util'; +import { getNode, isStyleSheet, getNodesInBetween } from './util'; import parse from '@emmetio/html-matcher'; import parseStylesheet from '@emmetio/css-parser'; import Node from '@emmetio/node'; @@ -58,19 +58,29 @@ export function toggleComment() { } function toggleCommentHTML(document: vscode.TextDocument, selection: vscode.Selection, rootNode: Node): [vscode.Range[], vscode.Position, vscode.Position] { - let offset = document.offsetAt(selection.start); - let nodeToUpdate = getNode(rootNode, offset); - if (!nodeToUpdate) { + const selectionStart = document.offsetAt(selection.isReversed ? selection.active : selection.anchor); + const selectionEnd = document.offsetAt(selection.isReversed ? selection.anchor : selection.active); + + let startNode = getNode(rootNode, selectionStart, true); + let endNode = getNode(rootNode, selectionEnd, true); + + if (!startNode || !endNode) { return [[], null, null]; } - let rangesToUnComment = getRangesToUnCommentHTML(nodeToUpdate, document); - if (nodeToUpdate.type === 'comment') { + let allNodes: Node[] = getNodesInBetween(startNode, endNode); + let rangesToUnComment: vscode.Range[] = []; + + allNodes.forEach(node => { + rangesToUnComment = rangesToUnComment.concat(getRangesToUnCommentHTML(node, document)); + }); + + if (startNode.type === 'comment') { return [rangesToUnComment, null, null]; } - let positionForCommentStart = document.positionAt(nodeToUpdate.start); - let positionForCommentEnd = document.positionAt(nodeToUpdate.end); + let positionForCommentStart = document.positionAt(allNodes[0].start); + let positionForCommentEnd = document.positionAt(allNodes[allNodes.length - 1].end); return [rangesToUnComment, positionForCommentStart, positionForCommentEnd]; } @@ -95,8 +105,8 @@ function getRangesToUnCommentHTML(node: Node, document: vscode.TextDocument): vs function toggleCommentStylesheet(document: vscode.TextDocument, selection: vscode.Selection, rootNode: Node): [vscode.Range[], vscode.Position, vscode.Position] { - let selectionStart = document.offsetAt(selection.anchor); - let selectionEnd = document.offsetAt(selection.active); + const selectionStart = document.offsetAt(selection.isReversed ? selection.active : selection.anchor); + const selectionEnd = document.offsetAt(selection.isReversed ? selection.anchor : selection.active); // If current node is commented, then uncomment and return let rangesToUnComment = getRangesToUnCommentStylesheet(rootNode, selectionStart, selectionEnd, document, true); diff --git a/extensions/emmet/src/util.ts b/extensions/emmet/src/util.ts index d6b80549fdf..bc3f3893e89 100644 --- a/extensions/emmet/src/util.ts +++ b/extensions/emmet/src/util.ts @@ -215,4 +215,55 @@ export function findPrevWord(propertyValue: string, pos: number): [number, numbe } return [newSelectionStart, newSelectionEnd]; +} + +export function getNodesInBetween(node1: Node, node2: Node): Node[] { + // Same node + if (sameNodes(node1, node2)) { + return [node1]; + } + + // Same parent + if (sameNodes(node1.parent, node2.parent)) { + return getNextSiblingsTillPosition(node1, node2.end); + } + + // node2 is ancestor of node1 + if (node2.start < node1.start) { + return [node2]; + } + + // node1 is ancestor of node2 + if (node2.start < node1.end) { + return [node1]; + } + + // Get the highest ancestor of node1 that should be commented + while (node1.parent && node1.parent.end < node2.start) { + node1 = node1.parent; + } + + // Get the highest ancestor of node2 that should be commented + while (node2.parent && node2.parent.start > node1.start) { + node2 = node2.parent; + } + + return getNextSiblingsTillPosition(node1, node2.end); +} + +function getNextSiblingsTillPosition(node: Node, position: number): Node[] { + let siblings: Node[] = []; + let currentNode = node; + while (currentNode && currentNode.start < position) { + siblings.push(currentNode); + currentNode = currentNode.nextSibling; + } + return siblings; +} + +export function sameNodes(node1: Node, node2: Node): boolean { + if (!node1 || !node2) { + return false; + } + return node1.start === node2.start && node1.end === node2.end; } \ No newline at end of file -- GitLab From 66212c6328645fbb6cd0433990340e1d1626aa8b Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Tue, 6 Jun 2017 19:17:15 -0700 Subject: [PATCH 0578/1347] toggle comment across css nodes #27629 --- extensions/emmet/src/toggleComment.ts | 50 ++++++++++----------------- 1 file changed, 18 insertions(+), 32 deletions(-) diff --git a/extensions/emmet/src/toggleComment.ts b/extensions/emmet/src/toggleComment.ts index b26e31ad1e2..75c0791342d 100644 --- a/extensions/emmet/src/toggleComment.ts +++ b/extensions/emmet/src/toggleComment.ts @@ -108,45 +108,31 @@ function toggleCommentStylesheet(document: vscode.TextDocument, selection: vscod const selectionStart = document.offsetAt(selection.isReversed ? selection.active : selection.anchor); const selectionEnd = document.offsetAt(selection.isReversed ? selection.anchor : selection.active); - // If current node is commented, then uncomment and return - let rangesToUnComment = getRangesToUnCommentStylesheet(rootNode, selectionStart, selectionEnd, document, true); - if (rangesToUnComment.length > 0) { - return [rangesToUnComment, null, null]; - } - - // Find the node that needs to be commented - let nodeToComment = getNode(rootNode, selectionStart, true); - if (!nodeToComment) { - return [[], null, null]; - } - - // Uncomment children of current node and then comment the node - rangesToUnComment = getRangesToUnCommentStylesheet(rootNode, nodeToComment.start, nodeToComment.end, document, false); - let positionForCommentStart = document.positionAt(nodeToComment.start); - let positionForCommentEnd = document.positionAt(nodeToComment.end); - - return [rangesToUnComment, positionForCommentStart, positionForCommentEnd]; -} + let startNode = getNode(rootNode, selectionStart, true); + let endNode = getNode(rootNode, selectionEnd, true); + let rangesToUnComment: vscode.Range[] = []; -function getRangesToUnCommentStylesheet(rootNode: Node, selectionStart: number, selectionEnd: number, document: vscode.TextDocument, selectionInsideComment: boolean): vscode.Range[] { - if (!rootNode.comments || rootNode.comments.length === 0) { - return []; - } + let isFirstNodeCommented = false; - let rangesToUnComment = []; + // Uncomment the comments that intersect with the selection. rootNode.comments.forEach(comment => { - let foundComment = false; - if (selectionInsideComment) { - foundComment = comment.start <= selectionStart && comment.end >= selectionEnd; - } else { - foundComment = selectionStart <= comment.start && selectionEnd >= comment.end; + let commentStart = document.positionAt(comment.start); + let commentEnd = document.positionAt(comment.end); + + if (!isFirstNodeCommented) { + isFirstNodeCommented = (comment.start <= selectionStart && comment.end >= selectionEnd); } - if (foundComment) { + if (selection.contains(commentStart) || selection.contains(commentEnd) || (comment.start <= selectionStart && comment.end >= selectionEnd)) { rangesToUnComment.push(new vscode.Range(document.positionAt(comment.start), document.positionAt(comment.start + startCommentStylesheet.length))); rangesToUnComment.push(new vscode.Range(document.positionAt(comment.end), document.positionAt(comment.end - endCommentStylesheet.length))); } }); - return rangesToUnComment; -} \ No newline at end of file + let positionForCommentStart = isFirstNodeCommented ? null : document.positionAt(startNode.start); + let positionForCommentEnd = isFirstNodeCommented ? null : document.positionAt(endNode.end); + + return [rangesToUnComment, positionForCommentStart, positionForCommentEnd]; + + +} -- GitLab From 6f0d0c6bcc5d6558aa6813b766f090729b374ed6 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 7 Jun 2017 08:42:49 +0200 Subject: [PATCH 0579/1347] Fixes #21784: Add `editor.minimap.showSlider` to control the minimap's slider visibility --- .../editor/browser/viewParts/minimap/minimap.css | 9 ++++++--- .../editor/browser/viewParts/minimap/minimap.ts | 15 ++++++++++++++- src/vs/editor/common/config/commonEditorConfig.ts | 6 ++++++ src/vs/editor/common/config/editorOptions.ts | 10 ++++++++++ src/vs/monaco.d.ts | 6 ++++++ 5 files changed, 42 insertions(+), 4 deletions(-) diff --git a/src/vs/editor/browser/viewParts/minimap/minimap.css b/src/vs/editor/browser/viewParts/minimap/minimap.css index 692577e87bd..f3692e7e4dc 100644 --- a/src/vs/editor/browser/viewParts/minimap/minimap.css +++ b/src/vs/editor/browser/viewParts/minimap/minimap.css @@ -3,16 +3,19 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -.monaco-editor .minimap-slider { +/* START cover the case that slider is visible on mouseover */ +.monaco-editor .minimap.slider-mouseover .minimap-slider { opacity: 0; transition: opacity 100ms linear; } -.monaco-editor .minimap:hover .minimap-slider { +.monaco-editor .minimap.slider-mouseover:hover .minimap-slider { opacity: 1; } -.monaco-editor .minimap-slider.active { +.monaco-editor .minimap.slider-mouseover .minimap-slider.active { opacity: 1; } +/* END cover the case that slider is visible on mouseover */ + .monaco-editor .minimap-shadow-hidden { position: absolute; width: 0; diff --git a/src/vs/editor/browser/viewParts/minimap/minimap.ts b/src/vs/editor/browser/viewParts/minimap/minimap.ts index 46d8dde55d5..2e9415eb221 100644 --- a/src/vs/editor/browser/viewParts/minimap/minimap.ts +++ b/src/vs/editor/browser/viewParts/minimap/minimap.ts @@ -73,6 +73,8 @@ class MinimapOptions { public readonly renderMinimap: RenderMinimap; + public readonly showSlider: 'always' | 'mouseover'; + public readonly pixelRatio: number; public readonly lineHeight: number; @@ -107,8 +109,10 @@ class MinimapOptions { constructor(configuration: editorCommon.IConfiguration) { const pixelRatio = configuration.editor.pixelRatio; const layoutInfo = configuration.editor.layoutInfo; + const viewInfo = configuration.editor.viewInfo; this.renderMinimap = layoutInfo.renderMinimap | 0; + this.showSlider = viewInfo.minimap.showSlider; this.pixelRatio = pixelRatio; this.lineHeight = configuration.editor.lineHeight; this.minimapWidth = layoutInfo.minimapWidth; @@ -123,6 +127,7 @@ class MinimapOptions { public equals(other: MinimapOptions): boolean { return (this.renderMinimap === other.renderMinimap + && this.showSlider === other.showSlider && this.pixelRatio === other.pixelRatio && this.lineHeight === other.lineHeight && this.minimapWidth === other.minimapWidth @@ -440,7 +445,7 @@ export class Minimap extends ViewPart { this._domNode = createFastDomNode(document.createElement('div')); PartFingerprints.write(this._domNode, PartFingerprint.Minimap); - this._domNode.setClassName('minimap'); + this._domNode.setClassName(this._getMinimapDomNodeClassName()); this._domNode.setPosition('absolute'); this._domNode.setAttribute('role', 'presentation'); this._domNode.setAttribute('aria-hidden', 'true'); @@ -549,6 +554,13 @@ export class Minimap extends ViewPart { super.dispose(); } + private _getMinimapDomNodeClassName(): string { + if (this._options.showSlider === 'always') { + return 'minimap slider-always'; + } + return 'minimap slider-mouseover'; + } + public getDomNode(): FastDomNode { return this._domNode; } @@ -585,6 +597,7 @@ export class Minimap extends ViewPart { this._lastRenderData = null; this._buffers = null; this._applyLayout(); + this._domNode.setClassName(this._getMinimapDomNodeClassName()); return true; } diff --git a/src/vs/editor/common/config/commonEditorConfig.ts b/src/vs/editor/common/config/commonEditorConfig.ts index 310a51d8538..87ecf2fdb30 100644 --- a/src/vs/editor/common/config/commonEditorConfig.ts +++ b/src/vs/editor/common/config/commonEditorConfig.ts @@ -254,6 +254,12 @@ const editorConfiguration: IConfigurationNode = { 'default': EDITOR_DEFAULTS.viewInfo.minimap.enabled, 'description': nls.localize('minimap.enabled', "Controls if the minimap is shown") }, + 'editor.minimap.showSlider': { + 'type': 'string', + 'enum': ['always', 'mouseover'], + 'default': EDITOR_DEFAULTS.viewInfo.minimap.showSlider, + 'description': nls.localize('minimap.showSlider', "Controls whether the minimap slider is automatically hidden.") + }, 'editor.minimap.renderCharacters': { 'type': 'boolean', 'default': EDITOR_DEFAULTS.viewInfo.minimap.renderCharacters, diff --git a/src/vs/editor/common/config/editorOptions.ts b/src/vs/editor/common/config/editorOptions.ts index 2daf0ddac8f..89378c65bdc 100644 --- a/src/vs/editor/common/config/editorOptions.ts +++ b/src/vs/editor/common/config/editorOptions.ts @@ -97,6 +97,11 @@ export interface IEditorMinimapOptions { * Defaults to false. */ enabled?: boolean; + /** + * Control the rendering of the minimap slider. + * Defaults to 'mouseover'. + */ + showSlider?: 'always' | 'mouseover'; /** * Render the actual text on a line (as opposed to color blocks). * Defaults to true. @@ -691,6 +696,7 @@ export interface InternalEditorScrollbarOptions { export interface InternalEditorMinimapOptions { readonly enabled: boolean; + readonly showSlider: 'always' | 'mouseover'; readonly renderCharacters: boolean; readonly maxColumn: number; } @@ -1028,6 +1034,7 @@ export class InternalEditorOptions { private static _equalsMinimapOptions(a: InternalEditorMinimapOptions, b: InternalEditorMinimapOptions): boolean { return ( a.enabled === b.enabled + && a.showSlider === b.showSlider && a.renderCharacters === b.renderCharacters && a.maxColumn === b.maxColumn ); @@ -1474,6 +1481,7 @@ export class EditorOptionsValidator { } return { enabled: _boolean(opts.enabled, defaults.enabled), + showSlider: _stringSet<'always' | 'mouseover'>(opts.showSlider, defaults.showSlider, ['always', 'mouseover']), renderCharacters: _boolean(opts.renderCharacters, defaults.renderCharacters), maxColumn: _clampedInt(opts.maxColumn, defaults.maxColumn, 1, 10000), }; @@ -1689,6 +1697,7 @@ export class InternalEditorOptionsFactory { minimap: { enabled: (accessibilityIsOn ? false : opts.viewInfo.minimap.enabled), // DISABLED WHEN SCREEN READER IS ATTACHED renderCharacters: opts.viewInfo.minimap.renderCharacters, + showSlider: opts.viewInfo.minimap.showSlider, maxColumn: opts.viewInfo.minimap.maxColumn }, fixedOverflowWidgets: opts.viewInfo.fixedOverflowWidgets @@ -2118,6 +2127,7 @@ export const EDITOR_DEFAULTS: IValidatedEditorOptions = { }, minimap: { enabled: true, + showSlider: 'mouseover', renderCharacters: true, maxColumn: 120 }, diff --git a/src/vs/monaco.d.ts b/src/vs/monaco.d.ts index 3fad661a07f..cdb3e52fee3 100644 --- a/src/vs/monaco.d.ts +++ b/src/vs/monaco.d.ts @@ -2655,6 +2655,11 @@ declare module monaco.editor { * Defaults to false. */ enabled?: boolean; + /** + * Control the rendering of the minimap slider. + * Defaults to 'mouseover'. + */ + showSlider?: 'always' | 'mouseover'; /** * Render the actual text on a line (as opposed to color blocks). * Defaults to true. @@ -3177,6 +3182,7 @@ declare module monaco.editor { export interface InternalEditorMinimapOptions { readonly enabled: boolean; + readonly showSlider: 'always' | 'mouseover'; readonly renderCharacters: boolean; readonly maxColumn: number; } -- GitLab From ea1b253767bd52c4667c43e84ac7147cb0b114d4 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 7 Jun 2017 10:03:34 +0200 Subject: [PATCH 0580/1347] debt - improve usage of untitled editor service --- .../electron-browser/mainThreadDocuments.ts | 18 +++-- .../common/editor/untitledEditorInput.ts | 2 +- .../parts/backup/common/backupModelTracker.ts | 5 +- .../parts/backup/common/backupRestorer.ts | 11 +-- .../parts/files/browser/fileActions.ts | 37 ++++++--- .../services/search/node/searchService.ts | 2 +- .../textfile/common/textFileService.ts | 51 ++++++------ .../common/textModelResolverService.ts | 3 +- .../untitled/common/untitledEditorService.ts | 78 +++++++++++++++---- .../test/common/editor/untitledEditor.test.ts | 63 ++++++++++++++- 10 files changed, 196 insertions(+), 74 deletions(-) diff --git a/src/vs/workbench/api/electron-browser/mainThreadDocuments.ts b/src/vs/workbench/api/electron-browser/mainThreadDocuments.ts index 13e61675fa4..0734061ff17 100644 --- a/src/vs/workbench/api/electron-browser/mainThreadDocuments.ts +++ b/src/vs/workbench/api/electron-browser/mainThreadDocuments.ts @@ -234,15 +234,17 @@ export class MainThreadDocuments extends MainThreadDocumentsShape { }, err => this._doCreateUntitled(asFileUri).then(resource => !!resource)); } - private _doCreateUntitled(uri?: URI, modeId?: string, initialValue?: string): TPromise { - let input = this._untitledEditorService.createOrGet(uri, modeId, initialValue); - return input.resolve(true).then(model => { - if (!this._modelIsSynced[input.getResource().toString()]) { - throw new Error(`expected URI ${input.getResource().toString()} to have come to LIFE`); + private _doCreateUntitled(resource?: URI, modeId?: string, initialValue?: string): TPromise { + return this._untitledEditorService.loadOrCreate({ resource, modeId, initialValue }).then(model => { + const resource = model.getResource(); + + if (!this._modelIsSynced[resource.toString()]) { + throw new Error(`expected URI ${resource.toString()} to have come to LIFE`); } - return this._proxy.$acceptDirtyStateChanged(input.getResource().toString(), true); // mark as dirty - }).then(() => { - return input.getResource(); + + this._proxy.$acceptDirtyStateChanged(resource.toString(), true); // mark as dirty + + return resource; }); } diff --git a/src/vs/workbench/common/editor/untitledEditorInput.ts b/src/vs/workbench/common/editor/untitledEditorInput.ts index 09cb75038a9..0d27f285512 100644 --- a/src/vs/workbench/common/editor/untitledEditorInput.ts +++ b/src/vs/workbench/common/editor/untitledEditorInput.ts @@ -155,7 +155,7 @@ export class UntitledEditorInput extends EditorInput implements IEncodingSupport } } - public resolve(refresh?: boolean): TPromise { + public resolve(): TPromise { // Join a model resolve if we have had one before if (this.modelResolve) { diff --git a/src/vs/workbench/parts/backup/common/backupModelTracker.ts b/src/vs/workbench/parts/backup/common/backupModelTracker.ts index c437b4d70f8..fa7bb0e5356 100644 --- a/src/vs/workbench/parts/backup/common/backupModelTracker.ts +++ b/src/vs/workbench/parts/backup/common/backupModelTracker.ts @@ -80,9 +80,8 @@ export class BackupModelTracker implements IWorkbenchContribution { } private onUntitledModelChanged(resource: Uri): void { - const input = this.untitledEditorService.get(resource); - if (input.isDirty()) { - input.resolve().then(model => this.backupFileService.backupResource(resource, model.getValue(), model.getVersionId())).done(null, errors.onUnexpectedError); + if (this.untitledEditorService.isDirty(resource)) { + this.untitledEditorService.loadOrCreate({ resource }).then(model => this.backupFileService.backupResource(resource, model.getValue(), model.getVersionId())).done(null, errors.onUnexpectedError); } else { this.discardBackup(resource); } diff --git a/src/vs/workbench/parts/backup/common/backupRestorer.ts b/src/vs/workbench/parts/backup/common/backupRestorer.ts index 77603e199d9..3b64fdda7ad 100644 --- a/src/vs/workbench/parts/backup/common/backupRestorer.ts +++ b/src/vs/workbench/parts/backup/common/backupRestorer.ts @@ -7,7 +7,7 @@ import URI from 'vs/base/common/uri'; import { TPromise } from 'vs/base/common/winjs.base'; -import { IUntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; +import { IUntitledEditorService, UNTITLED_SCHEMA } from 'vs/workbench/services/untitled/common/untitledEditorService'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { IWorkbenchContribution } from 'vs/workbench/common/contributions'; import { IPartService } from 'vs/workbench/services/part/common/partService'; @@ -17,6 +17,7 @@ import { IEditorGroupService } from 'vs/workbench/services/group/common/groupSer import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; import { Position, IResourceInput, IUntitledResourceInput } from 'vs/platform/editor/common/editor'; import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; +import { Schemas } from "vs/base/common/network"; export class BackupRestorer implements IWorkbenchContribution { @@ -67,10 +68,10 @@ export class BackupRestorer implements IWorkbenchContribution { backups.forEach(backup => { if (stacks.isOpen(backup)) { - if (backup.scheme === 'file') { + if (backup.scheme === Schemas.file) { restorePromises.push(this.textFileService.models.loadOrCreate(backup).then(null, () => unresolved.push(backup))); - } else if (backup.scheme === 'untitled') { - restorePromises.push(this.untitledEditorService.get(backup).resolve().then(null, () => unresolved.push(backup))); + } else if (backup.scheme === UNTITLED_SCHEMA) { + restorePromises.push(this.untitledEditorService.loadOrCreate({ resource: backup }).then(null, () => unresolved.push(backup))); } } else { unresolved.push(backup); @@ -92,7 +93,7 @@ export class BackupRestorer implements IWorkbenchContribution { private resolveInput(resource: URI, index: number, hasOpenedEditors: boolean): IResourceInput | IUntitledResourceInput { const options = { pinned: true, preserveFocus: true, inactive: index > 0 || hasOpenedEditors }; - if (resource.scheme === 'untitled' && !BackupRestorer.UNTITLED_REGEX.test(resource.fsPath)) { + if (resource.scheme === UNTITLED_SCHEMA && !BackupRestorer.UNTITLED_REGEX.test(resource.fsPath)) { // TODO@Ben debt: instead of guessing if an untitled file has an associated file path or not // this information should be provided by the backup service and stored as meta data within return { filePath: resource.fsPath, options }; diff --git a/src/vs/workbench/parts/files/browser/fileActions.ts b/src/vs/workbench/parts/files/browser/fileActions.ts index ede08115230..98e8c094ddd 100644 --- a/src/vs/workbench/parts/files/browser/fileActions.ts +++ b/src/vs/workbench/parts/files/browser/fileActions.ts @@ -1354,7 +1354,7 @@ export abstract class BaseSaveFileAction extends BaseActionWithErrorReporting { if (this.isSaveAs() || source.scheme === 'untitled') { let encodingOfSource: string; if (source.scheme === 'untitled') { - encodingOfSource = this.untitledEditorService.get(source).getEncoding(); + encodingOfSource = this.untitledEditorService.getEncoding(source); } else if (source.scheme === 'file') { const textModel = this.textFileService.models.get(source); encodingOfSource = textModel && textModel.getEncoding(); // text model can be null e.g. if this is a binary file! @@ -1494,18 +1494,33 @@ export abstract class BaseSaveAllAction extends BaseActionWithErrorReporting { // Store some properties per untitled file to restore later after save is completed const mapUntitledToProperties: { [resource: string]: { encoding: string; indexInGroups: number[]; activeInGroups: boolean[] } } = Object.create(null); - this.textFileService.getDirty() - .filter(r => r.scheme === 'untitled') // All untitled resources - .map(r => this.untitledEditorService.get(r)) // Mapped to their inputs - .filter(input => !!input) // If possible :) - .forEach(input => { - mapUntitledToProperties[input.getResource().toString()] = { - encoding: input.getEncoding(), - indexInGroups: stacks.groups.map(g => g.indexOf(input)), - activeInGroups: stacks.groups.map(g => g.isActive(input)) - }; + this.untitledEditorService.getDirty().forEach(resource => { + const activeInGroups: boolean[] = []; + const indexInGroups: number[] = []; + const encoding = this.untitledEditorService.getEncoding(resource); + + // For each group + stacks.groups.forEach((group, groupIndex) => { + + // Find out if editor is active in group + const activeEditor = group.activeEditor; + const activeResource = toResource(activeEditor, { supportSideBySide: true }); + activeInGroups[groupIndex] = (activeResource && activeResource.toString() === resource.toString()); + + // Find index of editor in group + indexInGroups[groupIndex] = -1; + group.getEditors().forEach((editor, editorIndex) => { + const editorResource = toResource(editor, { supportSideBySide: true }); + if (editorResource && editorResource.toString() === resource.toString()) { + indexInGroups[groupIndex] = editorIndex; + return; + } + }); }); + mapUntitledToProperties[resource.toString()] = { encoding, indexInGroups, activeInGroups }; + }); + // Save all return this.textFileService.saveAll(this.getSaveAllArguments(context)).then(results => { diff --git a/src/vs/workbench/services/search/node/searchService.ts b/src/vs/workbench/services/search/node/searchService.ts index ac68c6c4e28..518f269d7b7 100644 --- a/src/vs/workbench/services/search/node/searchService.ts +++ b/src/vs/workbench/services/search/node/searchService.ts @@ -120,7 +120,7 @@ export class SearchService implements ISearchService { // Support untitled files if (resource.scheme === 'untitled') { - if (!this.untitledEditorService.get(resource)) { + if (!this.untitledEditorService.exists(resource)) { return; } } diff --git a/src/vs/workbench/services/textfile/common/textFileService.ts b/src/vs/workbench/services/textfile/common/textFileService.ts index 96626c1b4d8..f8cc7e2f2f8 100644 --- a/src/vs/workbench/services/textfile/common/textFileService.ts +++ b/src/vs/workbench/services/textfile/common/textFileService.ts @@ -24,12 +24,13 @@ import { IConfigurationService } from 'vs/platform/configuration/common/configur import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; -import { IUntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; +import { IUntitledEditorService, UNTITLED_SCHEMA } from 'vs/workbench/services/untitled/common/untitledEditorService'; import { UntitledEditorModel } from 'vs/workbench/common/editor/untitledEditorModel'; import { TextFileEditorModelManager } from 'vs/workbench/services/textfile/common/textFileEditorModelManager'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { IMessageService, Severity } from 'vs/platform/message/common/message'; import { ResourceMap } from 'vs/base/common/map'; +import { Schemas } from "vs/base/common/network"; export interface IBackupResult { didBackup: boolean; @@ -222,9 +223,9 @@ export abstract class TextFileService implements ITextFileService { const filesToBackup: ITextFileEditorModel[] = []; const untitledToBackup: URI[] = []; dirtyToBackup.forEach(s => { - if (s.scheme === 'file') { + if (s.scheme === Schemas.file) { filesToBackup.push(textFileEditorModelManager.get(s)); - } else if (s.scheme === 'untitled') { + } else if (s.scheme === UNTITLED_SCHEMA) { untitledToBackup.push(s); } }); @@ -238,9 +239,9 @@ export abstract class TextFileService implements ITextFileService { return TPromise.join(dirtyFileModels.map(model => this.backupFileService.backupResource(model.getResource(), model.getValue(), model.getVersionId()))).then(results => { // Handle untitled resources - const untitledModelPromises = untitledResources.map(untitledResource => this.untitledEditorService.get(untitledResource)) - .filter(untitled => !!untitled) - .map(untitled => untitled.resolve()); + const untitledModelPromises = untitledResources + .filter(untitled => this.untitledEditorService.exists(untitled)) + .map(untitled => this.untitledEditorService.loadOrCreate({ resource: untitled })); return TPromise.join(untitledModelPromises).then(untitledModels => { const untitledBackupPromises = untitledModels.map(model => { @@ -358,12 +359,7 @@ export abstract class TextFileService implements ITextFileService { const dirty = this.getDirtyFileModels(resources).map(m => m.getResource()); // Add untitled ones - if (!resources) { - dirty.push(...this.untitledEditorService.getDirty()); - } else { - const dirtyUntitled = resources.map(r => this.untitledEditorService.get(r)).filter(u => u && u.isDirty()).map(u => u.getResource()); - dirty.push(...dirtyUntitled); - } + dirty.push(...this.untitledEditorService.getDirty(resources)); return dirty; } @@ -382,7 +378,7 @@ export abstract class TextFileService implements ITextFileService { public save(resource: URI, options?: ISaveOptions): TPromise { // Run a forced save if we detect the file is not dirty so that save participants can still run - if (options && options.force && resource.scheme === 'file' && !this.isDirty(resource)) { + if (options && options.force && resource.scheme === Schemas.file && !this.isDirty(resource)) { const model = this._models.get(resource); if (model) { model.save({ force: true, reason: SaveReason.EXPLICIT }).then(() => !model.isDirty()); @@ -408,9 +404,9 @@ export abstract class TextFileService implements ITextFileService { const filesToSave: URI[] = []; const untitledToSave: URI[] = []; toSave.forEach(s => { - if (s.scheme === 'file') { + if (s.scheme === Schemas.file) { filesToSave.push(s); - } else if ((Array.isArray(arg1) || arg1 === true /* includeUntitled */) && s.scheme === 'untitled') { + } else if ((Array.isArray(arg1) || arg1 === true /* includeUntitled */) && s.scheme === UNTITLED_SCHEMA) { untitledToSave.push(s); } }); @@ -426,18 +422,18 @@ export abstract class TextFileService implements ITextFileService { // Preflight for untitled to handle cancellation from the dialog const targetsForUntitled: URI[] = []; for (let i = 0; i < untitledResources.length; i++) { - const untitled = this.untitledEditorService.get(untitledResources[i]); - if (untitled) { + const untitled = untitledResources[i]; + if (this.untitledEditorService.exists(untitled)) { let targetPath: string; // Untitled with associated file path don't need to prompt - if (this.untitledEditorService.hasAssociatedFilePath(untitled.getResource())) { - targetPath = untitled.getResource().fsPath; + if (this.untitledEditorService.hasAssociatedFilePath(untitled)) { + targetPath = untitled.fsPath; } // Otherwise ask user else { - targetPath = this.promptForPath(this.suggestFileName(untitledResources[i])); + targetPath = this.promptForPath(this.suggestFileName(untitled)); if (!targetPath) { return TPromise.as({ results: [...fileResources, ...untitledResources].map(r => { @@ -529,7 +525,7 @@ export abstract class TextFileService implements ITextFileService { // Get to target resource if (!target) { let dialogPath = resource.fsPath; - if (resource.scheme === 'untitled') { + if (resource.scheme === UNTITLED_SCHEMA) { dialogPath = this.suggestFileName(resource); } @@ -556,13 +552,10 @@ export abstract class TextFileService implements ITextFileService { // Retrieve text model from provided resource if any let modelPromise: TPromise = TPromise.as(null); - if (resource.scheme === 'file') { + if (resource.scheme === Schemas.file) { modelPromise = TPromise.as(this._models.get(resource)); - } else if (resource.scheme === 'untitled') { - const untitled = this.untitledEditorService.get(resource); - if (untitled) { - modelPromise = untitled.resolve(); - } + } else if (resource.scheme === UNTITLED_SCHEMA && this.untitledEditorService.exists(resource)) { + modelPromise = this.untitledEditorService.loadOrCreate({ resource }); } return modelPromise.then(model => { @@ -623,10 +616,10 @@ export abstract class TextFileService implements ITextFileService { private suggestFileName(untitledResource: URI): string { const workspace = this.contextService.getWorkspace(); if (workspace) { - return URI.file(paths.join(workspace.resource.fsPath, this.untitledEditorService.get(untitledResource).suggestFileName())).fsPath; + return URI.file(paths.join(workspace.resource.fsPath, this.untitledEditorService.suggestFileName(untitledResource))).fsPath; } - return this.untitledEditorService.get(untitledResource).suggestFileName(); + return this.untitledEditorService.suggestFileName(untitledResource); } public revert(resource: URI, options?: IRevertOptions): TPromise { diff --git a/src/vs/workbench/services/textmodelResolver/common/textModelResolverService.ts b/src/vs/workbench/services/textmodelResolver/common/textModelResolverService.ts index e23296a9759..f3c7ba8d7a0 100644 --- a/src/vs/workbench/services/textmodelResolver/common/textModelResolverService.ts +++ b/src/vs/workbench/services/textmodelResolver/common/textModelResolverService.ts @@ -116,8 +116,7 @@ export class TextModelResolverService implements ITextModelResolverService { // Untitled Schema: go through cached input // TODO ImmortalReference is a hack if (resource.scheme === UNTITLED_SCHEMA) { - return this.untitledEditorService.createOrGet(resource).resolve() - .then(model => new ImmortalReference(model)); + return this.untitledEditorService.loadOrCreate({ resource }).then(model => new ImmortalReference(model)); } // InMemory Schema: go through model service cache diff --git a/src/vs/workbench/services/untitled/common/untitledEditorService.ts b/src/vs/workbench/services/untitled/common/untitledEditorService.ts index 092460d9dac..264aa9275d4 100644 --- a/src/vs/workbench/services/untitled/common/untitledEditorService.ts +++ b/src/vs/workbench/services/untitled/common/untitledEditorService.ts @@ -12,11 +12,20 @@ import { IFilesConfiguration } from 'vs/platform/files/common/files'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import Event, { Emitter, once } from 'vs/base/common/event'; import { ResourceMap } from 'vs/base/common/map'; +import { TPromise } from "vs/base/common/winjs.base"; +import { UntitledEditorModel } from "vs/workbench/common/editor/untitledEditorModel"; +import { Schemas } from "vs/base/common/network"; export const IUntitledEditorService = createDecorator('untitledEditorService'); export const UNTITLED_SCHEMA = 'untitled'; +export interface IModelLoadOrCreateOptions { + resource?: URI; + modeId?: string; + initialValue?: string; +} + export interface IUntitledEditorService { _serviceBrand: any; @@ -42,19 +51,14 @@ export interface IUntitledEditorService { onDidDisposeModel: Event; /** - * Returns the untitled editor input matching the provided resource. - */ - get(resource: URI): UntitledEditorInput; - - /** - * Returns all untitled editor inputs. + * Returns if an untitled resource with the given URI exists. */ - getAll(resources?: URI[]): UntitledEditorInput[]; + exists(resource: URI): boolean; /** * Returns dirty untitled editors as resource URIs. */ - getDirty(): URI[]; + getDirty(resources?: URI[]): URI[]; /** * Returns true iff the provided resource is dirty. @@ -75,10 +79,29 @@ export interface IUntitledEditorService { */ createOrGet(resource?: URI, modeId?: string, initialValue?: string): UntitledEditorInput; + /** + * Creates a new untitled model with the optional resource URI or returns an existing one + * if the provided resource exists already as untitled model. + * + * It is valid to pass in a file resource. In that case the path will be used as identifier. + * The use case is to be able to create a new file with a specific path with VSCode. + */ + loadOrCreate(options: IModelLoadOrCreateOptions): TPromise; + /** * A check to find out if a untitled resource has a file path associated or not. */ hasAssociatedFilePath(resource: URI): boolean; + + /** + * Suggests a filename for the given untitled resource if it is known. + */ + suggestFileName(resource: URI): string; + + /** + * Get the configured encoding for the given untitled resource if any. + */ + getEncoding(resource: URI): string; } export class UntitledEditorService implements IUntitledEditorService { @@ -119,11 +142,11 @@ export class UntitledEditorService implements IUntitledEditorService { return this._onDidChangeEncoding.event; } - public get(resource: URI): UntitledEditorInput { + protected get(resource: URI): UntitledEditorInput { return this.mapResourceToInput.get(resource); } - public getAll(resources?: URI[]): UntitledEditorInput[] { + protected getAll(resources?: URI[]): UntitledEditorInput[] { if (resources) { return arrays.coalesce(resources.map(r => this.get(r))); } @@ -131,6 +154,10 @@ export class UntitledEditorService implements IUntitledEditorService { return this.mapResourceToInput.values(); } + public exists(resource: URI): boolean { + return this.mapResourceToInput.has(resource); + } + public revertAll(resources?: URI[], force?: boolean): URI[] { const reverted: URI[] = []; @@ -153,16 +180,29 @@ export class UntitledEditorService implements IUntitledEditorService { return input && input.isDirty(); } - public getDirty(): URI[] { - return this.mapResourceToInput.values() + public getDirty(resources?: URI[]): URI[] { + let inputs: UntitledEditorInput[]; + if (resources) { + inputs = resources.map(r => this.get(r)).filter(i => !!i); + } else { + inputs = this.mapResourceToInput.values(); + } + + return inputs .filter(i => i.isDirty()) .map(i => i.getResource()); } + public loadOrCreate(options: IModelLoadOrCreateOptions = Object.create(null)): TPromise { + return this.createOrGet(options.resource, options.modeId, options.initialValue).resolve(); + } + public createOrGet(resource?: URI, modeId?: string, initialValue?: string): UntitledEditorInput { + + // Massage resource if it comes with a file:// scheme let hasAssociatedFilePath = false; if (resource) { - hasAssociatedFilePath = (resource.scheme === 'file'); + hasAssociatedFilePath = (resource.scheme === Schemas.file); resource = resource.with({ scheme: UNTITLED_SCHEMA }); // ensure we have the right scheme if (hasAssociatedFilePath) { @@ -237,6 +277,18 @@ export class UntitledEditorService implements IUntitledEditorService { return this.mapResourceToAssociatedFilePath.has(resource); } + public suggestFileName(resource: URI): string { + const input = this.get(resource); + + return input ? input.suggestFileName() : void 0; + } + + public getEncoding(resource: URI): string { + const input = this.get(resource); + + return input ? input.getEncoding() : void 0; + } + public dispose(): void { this._onDidChangeContent.dispose(); this._onDidChangeDirty.dispose(); diff --git a/src/vs/workbench/test/common/editor/untitledEditor.test.ts b/src/vs/workbench/test/common/editor/untitledEditor.test.ts index c02f5c19483..d7ba2043f80 100644 --- a/src/vs/workbench/test/common/editor/untitledEditor.test.ts +++ b/src/vs/workbench/test/common/editor/untitledEditor.test.ts @@ -16,10 +16,22 @@ import { workbenchInstantiationService } from 'vs/workbench/test/workbenchTestSe import { UntitledEditorModel } from 'vs/workbench/common/editor/untitledEditorModel'; import { IModeService } from 'vs/editor/common/services/modeService'; import { ModeServiceImpl } from 'vs/editor/common/services/modeServiceImpl'; +import { UntitledEditorInput } from "vs/workbench/common/editor/untitledEditorInput"; + +export class TestUntitledEditorService extends UntitledEditorService { + + public get(resource: URI): UntitledEditorInput { + return super.get(resource); + } + + public getAll(resources?: URI[]): UntitledEditorInput[] { + return super.getAll(resources); + } +} class ServiceAccessor { constructor( - @IUntitledEditorService public untitledEditorService: UntitledEditorService, + @IUntitledEditorService public untitledEditorService: TestUntitledEditorService, @IModeService public modeService: ModeServiceImpl, @IConfigurationService public testConfigurationService: TestConfigurationService) { } @@ -47,6 +59,9 @@ suite('Workbench - Untitled Editor', () => { const input1 = service.createOrGet(); assert.equal(input1, service.createOrGet(input1.getResource())); + assert.ok(service.exists(input1.getResource())); + assert.ok(!service.exists(URI.file('testing'))); + const input2 = service.createOrGet(); // get() / getAll() @@ -70,6 +85,8 @@ suite('Workbench - Untitled Editor', () => { assert.ok(service.isDirty(input2.getResource())); assert.equal(service.getDirty()[0].toString(), input2.getResource().toString()); + assert.equal(service.getDirty([input2.getResource()])[0].toString(), input2.getResource().toString()); + assert.equal(service.getDirty([input1.getResource()]).length, 0); service.revertAll(); assert.equal(service.getAll().length, 0); @@ -78,6 +95,8 @@ suite('Workbench - Untitled Editor', () => { input2.dispose(); + assert.ok(!service.exists(input2.getResource())); + done(); }); @@ -113,6 +132,48 @@ suite('Workbench - Untitled Editor', () => { }); }); + test('Untitled via loadOrCreate', function (done) { + const service = accessor.untitledEditorService; + service.loadOrCreate().then(model1 => { + model1.textEditorModel.setValue('foo bar'); + assert.ok(model1.isDirty()); + + model1.textEditorModel.setValue(''); + assert.ok(!model1.isDirty()); + + return service.loadOrCreate({ initialValue: 'Hello World' }).then(model2 => { + assert.equal(model2.getValue(), 'Hello World'); + + const input = service.createOrGet(); + + return service.loadOrCreate({ resource: input.getResource() }).then(model3 => { + assert.equal(model3.getResource().toString(), input.getResource().toString()); + + const file = URI.file(join('C:\\', '/foo/file44.txt')); + return service.loadOrCreate({ resource: file }).then(model4 => { + assert.ok(service.hasAssociatedFilePath(model4.getResource())); + assert.ok(model4.isDirty()); + + model1.dispose(); + model2.dispose(); + model3.dispose(); + model4.dispose(); + input.dispose(); + + done(); + }); + }); + }); + }); + }); + + test('Untitled suggest name', function () { + const service = accessor.untitledEditorService; + const input = service.createOrGet(); + + assert.ok(service.suggestFileName(input.getResource())); + }); + test('Untitled with associated path remains dirty when content gets empty', function (done) { const service = accessor.untitledEditorService; const file = URI.file(join('C:\\', '/foo/file.txt')); -- GitLab From 93ea9d1ca92fdf4b1282882a9c7ca7125ee2b0bd Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 7 Jun 2017 10:03:56 +0200 Subject: [PATCH 0581/1347] more improvements for #25145 --- src/vs/platform/quickOpen/common/quickOpen.ts | 5 + .../parts/quickopen/quickOpenController.ts | 7 +- src/vs/workbench/electron-browser/actions.ts | 178 +++++++++++++++--- .../electron-browser/main.contribution.ts | 24 +-- .../electron-browser/windowPicker.ts | 120 ------------ .../workbench/electron-browser/workbench.ts | 2 +- 6 files changed, 165 insertions(+), 171 deletions(-) delete mode 100644 src/vs/workbench/electron-browser/windowPicker.ts diff --git a/src/vs/platform/quickOpen/common/quickOpen.ts b/src/vs/platform/quickOpen/common/quickOpen.ts index 6cc6781e190..160539465d5 100644 --- a/src/vs/platform/quickOpen/common/quickOpen.ts +++ b/src/vs/platform/quickOpen/common/quickOpen.ts @@ -57,6 +57,11 @@ export interface IPickOptions { * an optional flag to not close the picker on focus lost */ ignoreFocusLost?: boolean; + + /** + * enables quick navigate in the picker to open an element without typing + */ + quickNavigateConfiguration?: IQuickNavigateConfiguration; } export interface IInputOptions { diff --git a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts index 7c8a7df4a14..0bf51c9c1d7 100644 --- a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts +++ b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts @@ -73,6 +73,7 @@ interface IInternalPickOptions { matchOnDescription?: boolean; matchOnDetail?: boolean; ignoreFocusLost?: boolean; + quickNavigateConfiguration?: IQuickNavigateConfiguration; onDidType?: (value: string) => any; } @@ -155,8 +156,8 @@ export class QuickOpenController extends Component implements IQuickOpenService this.quickOpenWidget.navigate(next, quickNavigate); } - if (!quickNavigate && this.pickOpenWidget) { - this.pickOpenWidget.navigate(next); // quick-navigate is only supported in quick open, not picker + if (this.pickOpenWidget) { + this.pickOpenWidget.navigate(next, quickNavigate); } } @@ -446,7 +447,7 @@ export class QuickOpenController extends Component implements IQuickOpenService // Set input if (!this.pickOpenWidget.isVisible()) { - this.pickOpenWidget.show(model, { autoFocus }); + this.pickOpenWidget.show(model, { autoFocus, quickNavigateConfiguration: options.quickNavigateConfiguration }); } else { this.pickOpenWidget.setInput(model, autoFocus); } diff --git a/src/vs/workbench/electron-browser/actions.ts b/src/vs/workbench/electron-browser/actions.ts index 90bf406fd57..8848026edc5 100644 --- a/src/vs/workbench/electron-browser/actions.ts +++ b/src/vs/workbench/electron-browser/actions.ts @@ -34,8 +34,7 @@ import { IEditorGroupService } from 'vs/workbench/services/group/common/groupSer import { IPanelService } from 'vs/workbench/services/panel/common/panelService'; import { IPartService, Parts, Position as SidebarPosition } from 'vs/workbench/services/part/common/partService'; import { IViewletService } from 'vs/workbench/services/viewlet/browser/viewlet'; -import { QuickOpenAction } from "vs/workbench/browser/quickopen"; -import { SWITCH_WINDOWS_PREFIX } from "vs/workbench/electron-browser/windowPicker"; +import { IKeybindingService } from "vs/platform/keybinding/common/keybinding"; import * as os from 'os'; import { webFrame } from 'electron'; @@ -82,20 +81,6 @@ export class CloseWindowAction extends Action { } } -export class SwitchWindow extends QuickOpenAction { - - static ID = 'workbench.action.switchWindow'; - static LABEL = nls.localize('switchWindow', "Switch Window..."); - - constructor( - id: string, - label: string, - @IQuickOpenService quickOpenService: IQuickOpenService - ) { - super(id, label, SWITCH_WINDOWS_PREFIX, quickOpenService); - } -} - export class CloseFolderAction extends Action { static ID = 'workbench.action.closeFolder'; @@ -570,29 +555,115 @@ export class ReloadWindowAction extends Action { } } -export class OpenRecentAction extends Action { +export abstract class BaseSwitchWindow extends Action { - public static ID = 'workbench.action.openRecent'; - public static LABEL = nls.localize('openRecent', "Open Recent"); + constructor( + id: string, + label: string, + private windowsService: IWindowsService, + private windowService: IWindowService, + private quickOpenService: IQuickOpenService, + private keybindingService: IKeybindingService + ) { + super(id, label); + } + + protected abstract isQuickNavigate(): boolean; + + public run(): TPromise { + const currentWindowId = this.windowService.getCurrentWindowId(); + + return this.windowsService.getWindows().then(workspaces => { + const placeHolder = nls.localize('switchWindowPlaceHolder', "Select a window to switch to"); + const picks = workspaces.map(win => ({ + resource: win.filename ? URI.file(win.filename) : win.path, + isFolder: !win.filename && !!win.path, + label: win.title, + description: (currentWindowId === win.id) ? nls.localize('current', "Current Window") : void 0, + run: () => { + setTimeout(() => { + // Bug: somehow when not running this code in a timeout, it is not possible to use this picker + // with quick navigate keys (not able to trigger quick navigate once running it once). + this.windowsService.showWindow(win.id).done(null, errors.onUnexpectedError); + }); + } + } as IFilePickOpenEntry)); + + this.quickOpenService.pick(picks, { + autoFocus: { autoFocusFirstEntry: true }, + placeHolder, + quickNavigateConfiguration: this.isQuickNavigate() ? { keybindings: this.keybindingService.lookupKeybindings(this.id) } : void 0 + }); + }); + } +} + +export class SwitchWindow extends BaseSwitchWindow { + + static ID = 'workbench.action.switchWindow'; + static LABEL = nls.localize('switchWindow', "Switch Window..."); constructor( id: string, label: string, - @IWindowsService private windowsService: IWindowsService, - @IWindowService private windowService: IWindowService, - @IQuickOpenService private quickOpenService: IQuickOpenService, - @IWorkspaceContextService private contextService: IWorkspaceContextService, - @IEnvironmentService private environmentService: IEnvironmentService + @IWindowsService windowsService: IWindowsService, + @IWindowService windowService: IWindowService, + @IQuickOpenService quickOpenService: IQuickOpenService, + @IKeybindingService keybindingService: IKeybindingService + ) { + super(id, label, windowsService, windowService, quickOpenService, keybindingService); + } + + protected isQuickNavigate(): boolean { + return false; + } +} + +export class QuickSwitchWindow extends BaseSwitchWindow { + + static ID = 'workbench.action.quickSwitchWindow'; + static LABEL = nls.localize('quickSwitchWindow', "Quick Switch Window..."); + + constructor( + id: string, + label: string, + @IWindowsService windowsService: IWindowsService, + @IWindowService windowService: IWindowService, + @IQuickOpenService quickOpenService: IQuickOpenService, + @IKeybindingService keybindingService: IKeybindingService + ) { + super(id, label, windowsService, windowService, quickOpenService, keybindingService); + } + + protected isQuickNavigate(): boolean { + return true; + } +} + +export abstract class BaseOpenRecentAction extends Action { + + constructor( + id: string, + label: string, + private windowsService: IWindowsService, + private windowService: IWindowService, + private quickOpenService: IQuickOpenService, + private contextService: IWorkspaceContextService, + private environmentService: IEnvironmentService, + private keybindingService: IKeybindingService ) { super(id, label); } + protected abstract isQuickNavigate(): boolean; + public run(): TPromise { return this.windowService.getRecentlyOpen() .then(({ files, folders }) => this.openRecent(files, folders)); } private openRecent(recentFiles: string[], recentFolders: string[]): void { + function toPick(path: string, separator: ISeparator, isFolder: boolean, environmentService: IEnvironmentService): IFilePickOpenEntry { return { resource: URI.file(path), @@ -600,7 +671,13 @@ export class OpenRecentAction extends Action { label: paths.basename(path), description: getPathLabel(paths.dirname(path), null, environmentService), separator, - run: context => runPick(path, context) + run: context => { + setTimeout(() => { + // Bug: somehow when not running this code in a timeout, it is not possible to use this picker + // with quick navigate keys (not able to trigger quick navigate once running it once). + runPick(path, context); + }); + } }; } @@ -615,13 +692,60 @@ export class OpenRecentAction extends Action { const hasWorkspace = this.contextService.hasWorkspace(); this.quickOpenService.pick(folderPicks.concat(...filePicks), { - autoFocus: { autoFocusFirstEntry: !hasWorkspace, autoFocusSecondEntry: hasWorkspace }, + autoFocus: { autoFocusFirstEntry: !hasWorkspace && !this.isQuickNavigate(), autoFocusSecondEntry: hasWorkspace || this.isQuickNavigate() }, placeHolder: isMacintosh ? nls.localize('openRecentPlaceHolderMac', "Select a path (hold Cmd-key to open in new window)") : nls.localize('openRecentPlaceHolder', "Select a path to open (hold Ctrl-key to open in new window)"), - matchOnDescription: true + matchOnDescription: true, + quickNavigateConfiguration: this.isQuickNavigate() ? { keybindings: this.keybindingService.lookupKeybindings(this.id) } : void 0 }).done(null, errors.onUnexpectedError); } } +export class OpenRecentAction extends BaseOpenRecentAction { + + public static ID = 'workbench.action.openRecent'; + public static LABEL = nls.localize('openRecent', "Open Recent..."); + + constructor( + id: string, + label: string, + @IWindowsService windowsService: IWindowsService, + @IWindowService windowService: IWindowService, + @IQuickOpenService quickOpenService: IQuickOpenService, + @IWorkspaceContextService contextService: IWorkspaceContextService, + @IEnvironmentService environmentService: IEnvironmentService, + @IKeybindingService keybindingService: IKeybindingService + ) { + super(id, label, windowsService, windowService, quickOpenService, contextService, environmentService, keybindingService); + } + + protected isQuickNavigate(): boolean { + return false; + } +} + +export class QuickOpenRecentAction extends BaseOpenRecentAction { + + public static ID = 'workbench.action.quickOpenRecent'; + public static LABEL = nls.localize('quickOpenRecent', "Quick Open Recent..."); + + constructor( + id: string, + label: string, + @IWindowsService windowsService: IWindowsService, + @IWindowService windowService: IWindowService, + @IQuickOpenService quickOpenService: IQuickOpenService, + @IWorkspaceContextService contextService: IWorkspaceContextService, + @IEnvironmentService environmentService: IEnvironmentService, + @IKeybindingService keybindingService: IKeybindingService + ) { + super(id, label, windowsService, windowService, quickOpenService, contextService, environmentService, keybindingService); + } + + protected isQuickNavigate(): boolean { + return true; + } +} + export class CloseMessagesAction extends Action { public static ID = 'workbench.action.closeMessages'; diff --git a/src/vs/workbench/electron-browser/main.contribution.ts b/src/vs/workbench/electron-browser/main.contribution.ts index f53c0ee723b..87feaac6d44 100644 --- a/src/vs/workbench/electron-browser/main.contribution.ts +++ b/src/vs/workbench/electron-browser/main.contribution.ts @@ -14,12 +14,10 @@ import { IConfigurationRegistry, Extensions as ConfigurationExtensions } from 'v import { IWorkbenchActionRegistry, Extensions } from 'vs/workbench/common/actionRegistry'; import { KeyMod, KeyChord, KeyCode } from 'vs/base/common/keyCodes'; import { isWindows, isLinux, isMacintosh } from 'vs/base/common/platform'; -import { CloseEditorAction, KeybindingsReferenceAction, OpenDocumentationUrlAction, OpenIntroductoryVideosUrlAction, ReportIssueAction, ReportPerformanceIssueAction, ZoomResetAction, ZoomOutAction, ZoomInAction, ToggleFullScreenAction, ToggleMenuBarAction, CloseFolderAction, CloseWindowAction, SwitchWindow, NewWindowAction, CloseMessagesAction, NavigateUpAction, NavigateDownAction, NavigateLeftAction, NavigateRightAction, IncreaseViewSizeAction, DecreaseViewSizeAction, ShowStartupPerformance, ToggleSharedProcessAction } from 'vs/workbench/electron-browser/actions'; +import { CloseEditorAction, KeybindingsReferenceAction, OpenDocumentationUrlAction, OpenIntroductoryVideosUrlAction, ReportIssueAction, ReportPerformanceIssueAction, ZoomResetAction, ZoomOutAction, ZoomInAction, ToggleFullScreenAction, ToggleMenuBarAction, CloseFolderAction, CloseWindowAction, SwitchWindow, NewWindowAction, CloseMessagesAction, NavigateUpAction, NavigateDownAction, NavigateLeftAction, NavigateRightAction, IncreaseViewSizeAction, DecreaseViewSizeAction, ShowStartupPerformance, ToggleSharedProcessAction, QuickSwitchWindow, QuickOpenRecentAction } from 'vs/workbench/electron-browser/actions'; import { MessagesVisibleContext } from 'vs/workbench/electron-browser/workbench'; import { IJSONSchema } from 'vs/base/common/jsonSchema'; import { registerCommands } from 'vs/workbench/electron-browser/commands'; -import { IQuickOpenRegistry, QuickOpenHandlerDescriptor, Extensions as QuickOpenExtensions } from "vs/workbench/browser/quickopen"; -import { SWITCH_WINDOWS_PREFIX } from "vs/workbench/electron-browser/windowPicker"; // Contribute Commands registerCommands(); @@ -31,7 +29,9 @@ const fileCategory = nls.localize('file', "File"); const workbenchActionsRegistry = Registry.as(Extensions.WorkbenchActions); workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(NewWindowAction, NewWindowAction.ID, NewWindowAction.LABEL, { primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_N }), 'New Window'); workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(CloseWindowAction, CloseWindowAction.ID, CloseWindowAction.LABEL, { primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_W }), 'Close Window'); -workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(SwitchWindow, SwitchWindow.ID, SwitchWindow.LABEL), 'Switch Window'); +workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(SwitchWindow, SwitchWindow.ID, SwitchWindow.LABEL, { primary: null, mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_W } }), 'Switch Window...'); +workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(QuickSwitchWindow, QuickSwitchWindow.ID, QuickSwitchWindow.LABEL), 'Quick Switch Window...'); +workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenRecentAction, QuickOpenRecentAction.ID, QuickOpenRecentAction.LABEL), 'File: Quick Open Recent...', fileCategory); workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(CloseFolderAction, CloseFolderAction.ID, CloseFolderAction.LABEL, { primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KEY_K, KeyCode.KEY_F) }), 'File: Close Folder', fileCategory); if (!!product.reportIssueUrl) { workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(ReportIssueAction, ReportIssueAction.ID, ReportIssueAction.LABEL), 'Help: Report Issues', helpCategory); @@ -82,22 +82,6 @@ const developerCategory = nls.localize('developer', "Developer"); workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(ShowStartupPerformance, ShowStartupPerformance.ID, ShowStartupPerformance.LABEL), 'Developer: Startup Performance', developerCategory); workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(ToggleSharedProcessAction, ToggleSharedProcessAction.ID, ToggleSharedProcessAction.LABEL), 'Developer: Toggle Shared Process', developerCategory); -// Window switcher -Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpenHandler( - new QuickOpenHandlerDescriptor( - 'vs/workbench/electron-browser/windowPicker', - 'WindowPicker', - SWITCH_WINDOWS_PREFIX, - [ - { - prefix: SWITCH_WINDOWS_PREFIX, - needsEditor: false, - description: nls.localize('switchBetweenWindows', "Switch between Windows") - } - ] - ) -); - // Configuration: Workbench const configurationRegistry = Registry.as(ConfigurationExtensions.Configuration); diff --git a/src/vs/workbench/electron-browser/windowPicker.ts b/src/vs/workbench/electron-browser/windowPicker.ts deleted file mode 100644 index 05767e25f41..00000000000 --- a/src/vs/workbench/electron-browser/windowPicker.ts +++ /dev/null @@ -1,120 +0,0 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ -'use strict'; - -import { TPromise } from 'vs/base/common/winjs.base'; -import nls = require('vs/nls'); -import URI from 'vs/base/common/uri'; -import errors = require('vs/base/common/errors'); -import { IIconLabelOptions } from 'vs/base/browser/ui/iconLabel/iconLabel'; -import { Mode, IEntryRunContext } from 'vs/base/parts/quickopen/common/quickOpen'; -import { QuickOpenModel, QuickOpenEntry } from 'vs/base/parts/quickopen/browser/quickOpenModel'; -import scorer = require('vs/base/common/scorer'); -import { IModeService } from 'vs/editor/common/services/modeService'; -import { getIconClasses } from 'vs/workbench/browser/labels'; -import { IModelService } from 'vs/editor/common/services/modelService'; -import { QuickOpenHandler } from 'vs/workbench/browser/quickopen'; -import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; -import { IWindowsService, IWindowService } from "vs/platform/windows/common/windows"; -import { stripWildcards } from "vs/base/common/strings"; - -export const SWITCH_WINDOWS_PREFIX = 'windows '; - -export class WindowPickerEntry extends QuickOpenEntry { - - constructor( - private windowId: number, - private label: string, - private resource: URI, - private isCurrentWindow: boolean, - private hasFolderOpened: boolean, - @IWindowsService private windowsService: IWindowsService, - @IModelService private modelService: IModelService, - @IModeService private modeService: IModeService - ) { - super(); - } - - public getLabelOptions(): IIconLabelOptions { - return { - extraClasses: getIconClasses(this.modelService, this.modeService, this.resource, !this.resource && this.hasFolderOpened /* isFolder */) - }; - } - - public getLabel(): string { - return this.label; - } - - public getResource(): URI { - return this.resource; - } - - public getAriaLabel(): string { - return nls.localize('entryAriaLabel', "{0}, window picker", this.getLabel()); - } - - public getDescription(): string { - return this.isCurrentWindow ? nls.localize('current', "Current Window") : void 0; - } - - public run(mode: Mode, context: IEntryRunContext): boolean { - if (mode === Mode.OPEN) { - setTimeout(() => { - // Bug: somehow when not running this code in a timeout, it is not possible to use this picker - // with quick navigate keys (not able to trigger quick navigate once running it once). - this.windowsService.showWindow(this.windowId).done(null, errors.onUnexpectedError); - }); - - return true; - } - - return super.run(mode, context); - } -} - -export class WindowPicker extends QuickOpenHandler { - - constructor( - @IWindowsService private windowsService: IWindowsService, - @IWindowService private windowService: IWindowService, - @IInstantiationService private instantiationService: IInstantiationService - ) { - super(); - } - - public getResults(searchValue: string): TPromise { - searchValue = searchValue.trim(); - - const normalizedSearchValueLowercase = stripWildcards(searchValue).toLowerCase(); - const currentWindowId = this.windowService.getCurrentWindowId(); - - return this.windowsService.getWindows().then(windows => { - let entries = windows.map(win => { - return this.instantiationService.createInstance(WindowPickerEntry, win.id, win.title, win.filename ? URI.file(win.filename) : void 0, currentWindowId === win.id, !!win.path); - }); - - entries = entries.filter(e => { - if (!searchValue) { - return true; - } - - if (!scorer.matches(e.getLabel(), normalizedSearchValueLowercase)) { - return false; - } - - const { labelHighlights, descriptionHighlights } = QuickOpenEntry.highlight(e, searchValue, true /* fuzzy highlight */); - e.setHighlights(labelHighlights, descriptionHighlights); - - return true; - }); - - return new QuickOpenModel(entries); - }); - } - - public getEmptyLabel(searchString: string): string { - return nls.localize('noWindowResults', "No matching opened windows found"); - } -} \ No newline at end of file diff --git a/src/vs/workbench/electron-browser/workbench.ts b/src/vs/workbench/electron-browser/workbench.ts index b8c52c3c984..e475fb59619 100644 --- a/src/vs/workbench/electron-browser/workbench.ts +++ b/src/vs/workbench/electron-browser/workbench.ts @@ -390,7 +390,7 @@ export class Workbench implements IPartService { const workbenchActionsRegistry = Registry.as(Extensions.WorkbenchActions); workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(ReloadWindowAction, ReloadWindowAction.ID, ReloadWindowAction.LABEL, isDeveloping ? { primary: KeyMod.CtrlCmd | KeyCode.KEY_R } : void 0), 'Reload Window'); workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(ToggleDevToolsAction, ToggleDevToolsAction.ID, ToggleDevToolsAction.LABEL, isDeveloping ? { primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_I, mac: { primary: KeyMod.CtrlCmd | KeyMod.Alt | KeyCode.KEY_I } } : void 0), 'Developer: Toggle Developer Tools', localize('developer', "Developer")); - workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(OpenRecentAction, OpenRecentAction.ID, OpenRecentAction.LABEL, { primary: isDeveloping ? null : KeyMod.CtrlCmd | KeyCode.KEY_R, mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_R } }), 'File: Open Recent', localize('file', "File")); + workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(OpenRecentAction, OpenRecentAction.ID, OpenRecentAction.LABEL, { primary: isDeveloping ? null : KeyMod.CtrlCmd | KeyCode.KEY_R, mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_R } }), 'File: Open Recent...', localize('file', "File")); } private resolveEditorsToOpen(): TPromise { -- GitLab From f3fa86d0a59af29855ad7bedbd0f460b9a2655c8 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 7 Jun 2017 10:04:36 +0200 Subject: [PATCH 0582/1347] debt - better restore empty workspaces --- .../workbench/browser/parts/editor/editorPart.ts | 4 ++++ src/vs/workbench/electron-browser/actions.ts | 2 +- src/vs/workbench/electron-browser/workbench.ts | 15 ++++++++------- 3 files changed, 13 insertions(+), 8 deletions(-) diff --git a/src/vs/workbench/browser/parts/editor/editorPart.ts b/src/vs/workbench/browser/parts/editor/editorPart.ts index be76d1a4ff6..d6676433416 100644 --- a/src/vs/workbench/browser/parts/editor/editorPart.ts +++ b/src/vs/workbench/browser/parts/editor/editorPart.ts @@ -1031,6 +1031,10 @@ export class EditorPart extends Part implements IEditorPart, IEditorGroupService return this.doOpenEditors(editors, activePosition, ratio); } + public hasEditorsToRestore(): boolean { + return this.stacks.groups.some(g => g.count > 0); + } + public restoreEditors(): TPromise { const editors = this.stacks.groups.map((group, index) => { return { diff --git a/src/vs/workbench/electron-browser/actions.ts b/src/vs/workbench/electron-browser/actions.ts index 8848026edc5..cad6f26bd2f 100644 --- a/src/vs/workbench/electron-browser/actions.ts +++ b/src/vs/workbench/electron-browser/actions.ts @@ -692,7 +692,7 @@ export abstract class BaseOpenRecentAction extends Action { const hasWorkspace = this.contextService.hasWorkspace(); this.quickOpenService.pick(folderPicks.concat(...filePicks), { - autoFocus: { autoFocusFirstEntry: !hasWorkspace && !this.isQuickNavigate(), autoFocusSecondEntry: hasWorkspace || this.isQuickNavigate() }, + autoFocus: { autoFocusFirstEntry: !hasWorkspace, autoFocusSecondEntry: hasWorkspace }, placeHolder: isMacintosh ? nls.localize('openRecentPlaceHolderMac', "Select a path (hold Cmd-key to open in new window)") : nls.localize('openRecentPlaceHolder', "Select a path to open (hold Ctrl-key to open in new window)"), matchOnDescription: true, quickNavigateConfiguration: this.isQuickNavigate() ? { keybindings: this.keybindingService.lookupKeybindings(this.id) } : void 0 diff --git a/src/vs/workbench/electron-browser/workbench.ts b/src/vs/workbench/electron-browser/workbench.ts index e475fb59619..93e8408e070 100644 --- a/src/vs/workbench/electron-browser/workbench.ts +++ b/src/vs/workbench/electron-browser/workbench.ts @@ -426,6 +426,10 @@ export class Workbench implements IPartService { // Empty workbench: some first time users will not have an untiled file; returning users will always have one else if (!this.contextService.hasWorkspace() && this.telemetryService.getExperiments().openUntitledFile && !this.configurationService.lookup('workbench.welcome.enabled').value) { + if (this.editorPart.hasEditorsToRestore()) { + return TPromise.as([]); // do not open any empty untitled file if we have editors to restore + } + return this.backupFileService.hasBackups().then(hasBackups => { if (hasBackups) { return TPromise.as([]); // do not open any empty untitled file if we have backups to restore @@ -562,16 +566,13 @@ export class Workbench implements IPartService { private initSettings(): void { // Sidebar visibility - this.sideBarHidden = this.storageService.getBoolean(Workbench.sidebarHiddenSettingKey, StorageScope.WORKSPACE, false); - if (!this.contextService.hasWorkspace()) { - this.sideBarHidden = true; // we hide sidebar in single-file-mode - } + this.sideBarHidden = this.storageService.getBoolean(Workbench.sidebarHiddenSettingKey, StorageScope.WORKSPACE, !this.contextService.hasWorkspace()); // Panel part visibility const panelRegistry = Registry.as(PanelExtensions.Panels); - this.panelHidden = this.storageService.getBoolean(Workbench.panelHiddenSettingKey, StorageScope.WORKSPACE, true); - if (!this.contextService.hasWorkspace() || !panelRegistry.getDefaultPanelId()) { - this.panelHidden = true; // we hide panel part in single-file-mode or if there is no default panel + this.panelHidden = this.storageService.getBoolean(Workbench.panelHiddenSettingKey, StorageScope.WORKSPACE, !this.contextService.hasWorkspace()); + if (!panelRegistry.getDefaultPanelId()) { + this.panelHidden = true; // we hide panel part if there is no default panel } // Sidebar position -- GitLab From ed1b6da17acae8c641525c7abdd6588285436164 Mon Sep 17 00:00:00 2001 From: isidor Date: Wed, 7 Jun 2017 10:22:51 +0200 Subject: [PATCH 0583/1347] debug menu: enable all breakpoints fixes #28143 --- src/vs/code/electron-main/menus.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index 4323e8ca2ca..ca5849620fe 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -864,6 +864,7 @@ export class VSCodeMenu { breakpointsMenu.append(this.createMenuItem(nls.localize({ key: 'miColumnBreakpoint', comment: ['&& denotes a mnemonic'] }, "C&&olumn Breakpoint"), 'editor.debug.action.toggleColumnBreakpoint')); breakpointsMenu.append(this.createMenuItem(nls.localize({ key: 'miFunctionBreakpoint', comment: ['&& denotes a mnemonic'] }, "&&Function Breakpoint..."), 'workbench.debug.viewlet.action.addFunctionBreakpointAction')); const newBreakpoints = new MenuItem({ label: this.mnemonicLabel(nls.localize({ key: 'miNewBreakpoint', comment: ['&& denotes a mnemonic'] }, "&&New Breakpoint")), submenu: breakpointsMenu }); + const enableAllBreakpoints = this.createMenuItem(nls.localize({ key: 'miEnableAllBreakpoints', comment: ['&& denotes a mnemonic'] }, "Enable All Breakpoints"), 'workbench.debug.viewlet.action.enableAllBreakpoints'); const disableAllBreakpoints = this.createMenuItem(nls.localize({ key: 'miDisableAllBreakpoints', comment: ['&& denotes a mnemonic'] }, "Disable A&&ll Breakpoints"), 'workbench.debug.viewlet.action.disableAllBreakpoints'); const removeAllBreakpoints = this.createMenuItem(nls.localize({ key: 'miRemoveAllBreakpoints', comment: ['&& denotes a mnemonic'] }, "Remove &&All Breakpoints"), 'workbench.debug.viewlet.action.removeAllBreakpoints'); @@ -884,6 +885,7 @@ export class VSCodeMenu { __separator__(), toggleBreakpoint, newBreakpoints, + enableAllBreakpoints, disableAllBreakpoints, removeAllBreakpoints, __separator__(), -- GitLab From 0bbb9c7c447a88e5b76c9c306ef557117b2845b9 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Wed, 7 Jun 2017 10:23:42 +0200 Subject: [PATCH 0584/1347] Fixes #28171: Problem matchers referenced in API will not be resolved correctly --- .../parts/tasks/electron-browser/terminalTaskSystem.ts | 6 +++++- src/vs/workbench/parts/tasks/node/processTaskSystem.ts | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts index 6dbbc5b93a6..76a07d3b7a0 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts @@ -559,7 +559,11 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { values.forEach((value) => { let matcher: ProblemMatcher; if (Types.isString(value)) { - matcher = ProblemMatcherRegistry.get(value); + if (value[0] === '$') { + matcher = ProblemMatcherRegistry.get(value.substring(1)); + } else { + matcher = ProblemMatcherRegistry.get(value); + } } else { matcher = value; } diff --git a/src/vs/workbench/parts/tasks/node/processTaskSystem.ts b/src/vs/workbench/parts/tasks/node/processTaskSystem.ts index 0ac2c85e08f..0db8946a2d2 100644 --- a/src/vs/workbench/parts/tasks/node/processTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/node/processTaskSystem.ts @@ -333,7 +333,11 @@ export class ProcessTaskSystem extends EventEmitter implements ITaskSystem { values.forEach((value) => { let matcher: ProblemMatcher; if (Types.isString(value)) { - matcher = ProblemMatcherRegistry.get(value); + if (value[0] === '$') { + matcher = ProblemMatcherRegistry.get(value.substring(1)); + } else { + matcher = ProblemMatcherRegistry.get(value); + } } else { matcher = value; } -- GitLab From 32dd1b768414253437c52593380463088798add8 Mon Sep 17 00:00:00 2001 From: Nick Snyder Date: Wed, 7 Jun 2017 01:29:48 -0700 Subject: [PATCH 0585/1347] More explicit typing (#28148) Does not change any behavior --- src/vs/workbench/electron-browser/window.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/vs/workbench/electron-browser/window.ts b/src/vs/workbench/electron-browser/window.ts index d76662cdc5b..e193c9391e4 100644 --- a/src/vs/workbench/electron-browser/window.ts +++ b/src/vs/workbench/electron-browser/window.ts @@ -38,7 +38,7 @@ import { IWorkbenchThemeService, VS_HC_THEME, VS_DARK_THEME } from 'vs/workbench import * as browser from 'vs/base/browser/browser'; import { ICommandService } from 'vs/platform/commands/common/commands'; import { IViewletService } from 'vs/workbench/services/viewlet/browser/viewlet'; -import { Position, IResourceInput, IUntitledResourceInput } from 'vs/platform/editor/common/editor'; +import { Position, IResourceInput, IUntitledResourceInput, IEditor } from 'vs/platform/editor/common/editor'; import { IExtensionService } from 'vs/platform/extensions/common/extensions'; import { KeyboardMapperFactory } from 'vs/workbench/services/keybinding/electron-browser/keybindingService'; import { Themable, EDITOR_DRAG_AND_DROP_BACKGROUND } from 'vs/workbench/common/theme'; @@ -389,8 +389,9 @@ export class ElectronWindow extends Themable { } } - private openResources(resources: (IResourceInput | IUntitledResourceInput)[], diffMode: boolean): TPromise { - return this.partService.joinCreation().then(() => { + private openResources(resources: (IResourceInput | IUntitledResourceInput)[], diffMode: boolean): TPromise { + return this.partService.joinCreation().then((): TPromise => { + // In diffMode we open 2 resources as diff if (diffMode && resources.length === 2) { -- GitLab From 8526234cbb5678a06b0331b0b01014a2e0c7efc7 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 7 Jun 2017 10:38:23 +0200 Subject: [PATCH 0586/1347] :lipstick: --- src/vs/workbench/parts/files/browser/views/explorerView.ts | 3 +-- src/vs/workbench/parts/files/common/explorerViewModel.ts | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index 5b3ec0df63e..d86e3af8392 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -22,7 +22,6 @@ import { RefreshViewExplorerAction, NewFolderAction, NewFileAction } from 'vs/wo import { FileDragAndDrop, FileFilter, FileSorter, FileController, FileRenderer, FileDataSource, FileViewletState, FileAccessibilityProvider } from 'vs/workbench/parts/files/browser/views/explorerViewer'; import { toResource } from 'vs/workbench/common/editor'; import { DiffEditorInput } from 'vs/workbench/common/editor/diffEditorInput'; -import { UntitledEditorInput } from 'vs/workbench/common/editor/untitledEditorInput'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import * as DOM from 'vs/base/browser/dom'; import { CollapseAction, CollapsibleViewletView } from 'vs/workbench/browser/viewlet'; @@ -204,7 +203,7 @@ export class ExplorerView extends CollapsibleViewletView { // Handle closed or untitled file (convince explorer to not reopen any file when getting visible) const activeInput = this.editorService.getActiveEditorInput(); - if (activeInput instanceof UntitledEditorInput || !activeInput) { + if (!activeInput || toResource(activeInput, { supportSideBySide: true, filter: 'untitled' })) { this.settings[ExplorerView.MEMENTO_LAST_ACTIVE_FILE_RESOURCE] = void 0; clearFocus = true; } diff --git a/src/vs/workbench/parts/files/common/explorerViewModel.ts b/src/vs/workbench/parts/files/common/explorerViewModel.ts index 64b3abbe18f..f7463ababd9 100644 --- a/src/vs/workbench/parts/files/common/explorerViewModel.ts +++ b/src/vs/workbench/parts/files/common/explorerViewModel.ts @@ -8,7 +8,6 @@ import URI from 'vs/base/common/uri'; import paths = require('vs/base/common/paths'); import { IFileStat, isEqual, isParent, isEqualOrParent } from 'vs/platform/files/common/files'; -import { UntitledEditorInput } from 'vs/workbench/common/editor/untitledEditorInput'; import { IEditorInput } from 'vs/platform/editor/common/editor'; import { IEditorGroup, toResource } from 'vs/workbench/common/editor'; import { ResourceMap } from 'vs/base/common/map'; @@ -361,7 +360,7 @@ export class OpenEditor { } public isUntitled(): boolean { - return this.editor instanceof UntitledEditorInput; + return !!toResource(this.editor, { supportSideBySide: true, filter: 'untitled' }); } public isDirty(): boolean { -- GitLab From 573b0577c4518d48413dbaf97d8f46d63d10689f Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 7 Jun 2017 10:59:51 +0200 Subject: [PATCH 0587/1347] TS 2.4 fixes --- src/vs/base/browser/ui/splitview/splitview.ts | 2 +- .../browser/parts/editor/editorPart.ts | 13 ++++----- .../browser/parts/sidebar/sidebarPart.ts | 6 ++-- .../common/editor/diffEditorInput.ts | 2 +- .../common/editor/diffEditorModel.ts | 15 +++++----- .../parts/files/browser/fileCommands.ts | 2 +- .../services/editor/browser/editorService.ts | 6 ++-- .../textfile/common/textFileEditorModel.ts | 28 +++++++++---------- .../services/textfile/common/textfiles.ts | 2 ++ 9 files changed, 38 insertions(+), 38 deletions(-) diff --git a/src/vs/base/browser/ui/splitview/splitview.ts b/src/vs/base/browser/ui/splitview/splitview.ts index a328f784bdc..41415d49b18 100644 --- a/src/vs/base/browser/ui/splitview/splitview.ts +++ b/src/vs/base/browser/ui/splitview/splitview.ts @@ -102,7 +102,7 @@ export abstract class View extends ee.EventEmitter implements IView { abstract layout(size: number, orientation: Orientation): void; } -export interface IHeaderViewOptions extends IHeaderViewStyles { +export interface IHeaderViewOptions extends IHeaderViewStyles, IViewOptions { headerSize?: number; } diff --git a/src/vs/workbench/browser/parts/editor/editorPart.ts b/src/vs/workbench/browser/parts/editor/editorPart.ts index d6676433416..c1a20ee5dea 100644 --- a/src/vs/workbench/browser/parts/editor/editorPart.ts +++ b/src/vs/workbench/browser/parts/editor/editorPart.ts @@ -441,22 +441,18 @@ export class EditorPart extends Part implements IEditorPart, IEditorGroupService const editorInstantiationService = this.editorGroupsControl.getInstantiationService(position).createChild(new ServiceCollection([IProgressService, progressService])); let loaded = false; - const onInstantiate = (arg: BaseEditor | Error): TPromise => { + const onInstantiate = (arg: BaseEditor): TPromise => { const position = this.stacks.positionOfGroup(group); // might have changed due to a rochade meanwhile loaded = true; delete this.mapEditorInstantiationPromiseToEditor[position][descriptor.getId()]; - if (arg instanceof BaseEditor) { - this.instantiatedEditors[position].push(arg); + this.instantiatedEditors[position].push(arg); - return TPromise.as(arg); - } - - return TPromise.wrapError(arg); + return TPromise.as(arg); }; - const instantiateEditorPromise = editorInstantiationService.createInstance(descriptor).then(onInstantiate, onInstantiate); + const instantiateEditorPromise = editorInstantiationService.createInstance(descriptor).then(onInstantiate); if (!loaded) { this.mapEditorInstantiationPromiseToEditor[position][descriptor.getId()] = instantiateEditorPromise; @@ -464,6 +460,7 @@ export class EditorPart extends Part implements IEditorPart, IEditorGroupService return instantiateEditorPromise.then(result => { progressService.dispose(); + return result; }); } diff --git a/src/vs/workbench/browser/parts/sidebar/sidebarPart.ts b/src/vs/workbench/browser/parts/sidebar/sidebarPart.ts index 36f23b53283..0bdf5e478a0 100644 --- a/src/vs/workbench/browser/parts/sidebar/sidebarPart.ts +++ b/src/vs/workbench/browser/parts/sidebar/sidebarPart.ts @@ -68,11 +68,11 @@ export class SidebarPart extends CompositePart { } public get onDidViewletOpen(): Event { - return this._onDidCompositeOpen.event; + return this._onDidCompositeOpen.event as Event; } public get onDidViewletClose(): Event { - return this._onDidCompositeClose.event; + return this._onDidCompositeClose.event as Event; } public updateStyles(): void { @@ -110,7 +110,7 @@ export class SidebarPart extends CompositePart { } } - return promise.then(() => this.openComposite(id, focus)); + return promise.then(() => this.openComposite(id, focus)) as TPromise; } public getActiveViewlet(): IViewlet { diff --git a/src/vs/workbench/common/editor/diffEditorInput.ts b/src/vs/workbench/common/editor/diffEditorInput.ts index df3376af921..6d7b5cbfdae 100644 --- a/src/vs/workbench/common/editor/diffEditorInput.ts +++ b/src/vs/workbench/common/editor/diffEditorInput.ts @@ -70,7 +70,7 @@ export class DiffEditorInput extends SideBySideEditorInput { private createModel(refresh?: boolean): TPromise { // Join resolve call over two inputs and build diff editor model - return TPromise.join([ + return TPromise.join([ this.originalInput.resolve(refresh), this.modifiedInput.resolve(refresh) ]).then((models) => { diff --git a/src/vs/workbench/common/editor/diffEditorModel.ts b/src/vs/workbench/common/editor/diffEditorModel.ts index e12b560ef53..fc13842aa18 100644 --- a/src/vs/workbench/common/editor/diffEditorModel.ts +++ b/src/vs/workbench/common/editor/diffEditorModel.ts @@ -6,16 +6,17 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { EditorModel } from 'vs/workbench/common/editor'; +import { IEditorModel } from "vs/platform/editor/common/editor"; /** * The base editor model for the diff editor. It is made up of two editor models, the original version * and the modified version. */ export class DiffEditorModel extends EditorModel { - protected _originalModel: EditorModel; - protected _modifiedModel: EditorModel; + protected _originalModel: IEditorModel; + protected _modifiedModel: IEditorModel; - constructor(originalModel: EditorModel, modifiedModel: EditorModel) { + constructor(originalModel: IEditorModel, modifiedModel: IEditorModel) { super(); this._originalModel = originalModel; @@ -23,15 +24,15 @@ export class DiffEditorModel extends EditorModel { } public get originalModel(): EditorModel { - return this._originalModel; + return this._originalModel as EditorModel; } public get modifiedModel(): EditorModel { - return this._modifiedModel; + return this._modifiedModel as EditorModel; } public load(): TPromise { - return TPromise.join([ + return TPromise.join([ this._originalModel.load(), this._modifiedModel.load() ]).then(() => { @@ -40,7 +41,7 @@ export class DiffEditorModel extends EditorModel { } public isResolved(): boolean { - return this._originalModel.isResolved() && this._modifiedModel.isResolved(); + return this.originalModel.isResolved() && this.modifiedModel.isResolved(); } public dispose(): void { diff --git a/src/vs/workbench/parts/files/browser/fileCommands.ts b/src/vs/workbench/parts/files/browser/fileCommands.ts index 5ee9500a35a..8d0711a0c3d 100644 --- a/src/vs/workbench/parts/files/browser/fileCommands.ts +++ b/src/vs/workbench/parts/files/browser/fileCommands.ts @@ -154,7 +154,7 @@ function withVisibleExplorer(accessor: ServicesAccessor): TPromise; }; export function withFocussedFilesExplorerViewItem(accessor: ServicesAccessor): TPromise<{ explorer: ExplorerViewlet, tree: ITree, item: FileStat }> { diff --git a/src/vs/workbench/services/editor/browser/editorService.ts b/src/vs/workbench/services/editor/browser/editorService.ts index 7e4d4a52bcb..afd412d0127 100644 --- a/src/vs/workbench/services/editor/browser/editorService.ts +++ b/src/vs/workbench/services/editor/browser/editorService.ts @@ -168,9 +168,9 @@ export class WorkbenchEditorService implements IWorkbenchEditorService { return this.editorPart.openEditors(typedInputs); } - public replaceEditors(editors: { toReplace: IResourceInputType, replaceWith: IResourceInputType }[], position?: Position): TPromise; - public replaceEditors(editors: { toReplace: IEditorInput, replaceWith: IEditorInput, options?: IEditorOptions }[], position?: Position): TPromise; - public replaceEditors(editors: any[], position?: Position): TPromise { + public replaceEditors(editors: { toReplace: IResourceInputType, replaceWith: IResourceInputType }[], position?: Position): TPromise; + public replaceEditors(editors: { toReplace: IEditorInput, replaceWith: IEditorInput, options?: IEditorOptions }[], position?: Position): TPromise; + public replaceEditors(editors: any[], position?: Position): TPromise { const toReplaceInputs = editors.map(editor => this.createInput(editor.toReplace)); const replaceWithInputs = editors.map(editor => this.createInput(editor.replaceWith)); const typedReplacements: { toReplace: IEditorInput, replaceWith: IEditorInput, options?: EditorOptions }[] = editors.map((editor, index) => { diff --git a/src/vs/workbench/services/textfile/common/textFileEditorModel.ts b/src/vs/workbench/services/textfile/common/textFileEditorModel.ts index 43631b46cc1..d200639a975 100644 --- a/src/vs/workbench/services/textfile/common/textFileEditorModel.ts +++ b/src/vs/workbench/services/textfile/common/textFileEditorModel.ts @@ -21,7 +21,7 @@ import { ILifecycleService, LifecyclePhase } from 'vs/platform/lifecycle/common/ import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { ITextFileService, IAutoSaveConfiguration, ModelState, ITextFileEditorModel, IModelSaveOptions, ISaveErrorHandler, ISaveParticipant, StateChange, SaveReason, IRawTextContent } from 'vs/workbench/services/textfile/common/textfiles'; -import { EncodingMode, EditorModel } from 'vs/workbench/common/editor'; +import { EncodingMode } from 'vs/workbench/common/editor'; import { BaseTextEditorModel } from 'vs/workbench/common/editor/textEditorModel'; import { IBackupFileService, BACKUP_FILE_RESOLVE_OPTIONS } from 'vs/workbench/services/backup/common/backup'; import { IFileService, IFileStat, IFileOperationResult, FileOperationResult, IContent, CONTENT_CHANGE_EVENT_BUFFER_DELAY, FileChangesEvent, FileChangeType, isEqualOrParent } from 'vs/platform/files/common/files'; @@ -238,7 +238,7 @@ export class TextFileEditorModel extends BaseTextEditorModel implements ITextFil // Unset flags const undo = this.setDirty(false); - let loadPromise: TPromise; + let loadPromise: TPromise; if (soft) { loadPromise = TPromise.as(this); } else { @@ -258,7 +258,7 @@ export class TextFileEditorModel extends BaseTextEditorModel implements ITextFil }); } - public load(force?: boolean /* bypass any caches and really go to disk */): TPromise { + public load(force?: boolean /* bypass any caches and really go to disk */): TPromise { diag('load() - enter', this.resource, new Date()); // It is very important to not reload the model when the model is dirty. We only want to reload the model from the disk @@ -279,7 +279,7 @@ export class TextFileEditorModel extends BaseTextEditorModel implements ITextFil return this.loadFromFile(force); } - private loadWithBackup(force: boolean): TPromise { + private loadWithBackup(force: boolean): TPromise { return this.backupFileService.loadBackupResource(this.resource).then(backup => { // Make sure meanwhile someone else did not suceed or start loading @@ -306,7 +306,7 @@ export class TextFileEditorModel extends BaseTextEditorModel implements ITextFil }); } - private loadFromFile(force: boolean): TPromise { + private loadFromFile(force: boolean): TPromise { // Decide on etag let etag: string; @@ -322,7 +322,7 @@ export class TextFileEditorModel extends BaseTextEditorModel implements ITextFil .then(content => this.handleLoadSuccess(content), error => this.handleLoadError(error)); } - private handleLoadSuccess(content: IRawTextContent): TPromise { + private handleLoadSuccess(content: IRawTextContent): TPromise { // Clear orphaned state when load was successful this.setOrphaned(false); @@ -330,7 +330,7 @@ export class TextFileEditorModel extends BaseTextEditorModel implements ITextFil return this.loadWithContent(content); } - private handleLoadError(error: IFileOperationResult): TPromise { + private handleLoadError(error: IFileOperationResult): TPromise { const result = error.fileOperationResult; // Apply orphaned state based on error code @@ -340,21 +340,21 @@ export class TextFileEditorModel extends BaseTextEditorModel implements ITextFil if (result === FileOperationResult.FILE_NOT_MODIFIED_SINCE) { this.setDirty(false); // Ensure we are not tracking a stale state - return TPromise.as(this); + return TPromise.as(this); } // Ignore when a model has been resolved once and the file was deleted meanwhile. Since // we already have the model loaded, we can return to this state and update the orphaned // flag to indicate that this model has no version on disk anymore. if (this.isResolved() && result === FileOperationResult.FILE_NOT_FOUND) { - return TPromise.as(this); + return TPromise.as(this); } // Otherwise bubble up the error - return TPromise.wrapError(error); + return TPromise.wrapError(error); } - private loadWithContent(content: IRawTextContent | IContent, backup?: URI): TPromise { + private loadWithContent(content: IRawTextContent | IContent, backup?: URI): TPromise { diag('load() - resolved content', this.resource, new Date()); // Telemetry @@ -399,7 +399,7 @@ export class TextFileEditorModel extends BaseTextEditorModel implements ITextFil return this.doCreateTextModel(content.resource, content.value, backup); } - private doUpdateTextModel(value: string | IRawTextSource): TPromise { + private doUpdateTextModel(value: string | IRawTextSource): TPromise { diag('load() - updated text editor model', this.resource, new Date()); this.setDirty(false); // Ensure we are not tracking a stale state @@ -411,10 +411,10 @@ export class TextFileEditorModel extends BaseTextEditorModel implements ITextFil this.blockModelContentChange = false; } - return TPromise.as(this); + return TPromise.as(this); } - private doCreateTextModel(resource: URI, value: string | IRawTextSource, backup: URI): TPromise { + private doCreateTextModel(resource: URI, value: string | IRawTextSource, backup: URI): TPromise { diag('load() - created text editor model', this.resource, new Date()); this.createTextEditorModelPromise = this.doLoadBackup(backup).then(backupContent => { diff --git a/src/vs/workbench/services/textfile/common/textfiles.ts b/src/vs/workbench/services/textfile/common/textfiles.ts index d84df51fe0b..fbedca95ca2 100644 --- a/src/vs/workbench/services/textfile/common/textfiles.ts +++ b/src/vs/workbench/services/textfile/common/textfiles.ts @@ -196,6 +196,8 @@ export interface ITextFileEditorModel extends ITextEditorModel, IEncodingSupport save(options?: IModelSaveOptions): TPromise; + load(): TPromise; + revert(soft?: boolean): TPromise; getValue(): string; -- GitLab From f5e4e4f4246a70d30c32a6047874da2bbb4417e4 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 7 Jun 2017 11:10:22 +0200 Subject: [PATCH 0588/1347] Have the minimap slider be constantly aligned with the scrollbar slider (#21346) --- .../browser/ui/scrollbar/verticalScrollbar.ts | 2 +- src/vs/editor/browser/view/viewImpl.ts | 2 +- .../browser/viewParts/minimap/minimap.ts | 123 ++++++------------ .../browser/viewParts/viewZones/viewZones.ts | 2 +- .../viewLayout/viewLinesViewportData.ts | 15 ++- 5 files changed, 56 insertions(+), 88 deletions(-) diff --git a/src/vs/base/browser/ui/scrollbar/verticalScrollbar.ts b/src/vs/base/browser/ui/scrollbar/verticalScrollbar.ts index e2bfa6b645f..520a7139b48 100644 --- a/src/vs/base/browser/ui/scrollbar/verticalScrollbar.ts +++ b/src/vs/base/browser/ui/scrollbar/verticalScrollbar.ts @@ -61,7 +61,7 @@ export class VerticalScrollbar extends AbstractScrollbar { } public getVerticalSliderVerticalCenter(): number { - return this._scrollbarState.getSliderCenter(); + return this._scrollbarState.getArrowSize() + this._scrollbarState.getSliderCenter(); } protected _updateSlider(sliderSize: number, sliderPosition: number): void { diff --git a/src/vs/editor/browser/view/viewImpl.ts b/src/vs/editor/browser/view/viewImpl.ts index 2ac56ac2773..222f39fe1f3 100644 --- a/src/vs/editor/browser/view/viewImpl.ts +++ b/src/vs/editor/browser/view/viewImpl.ts @@ -409,7 +409,7 @@ export class View extends ViewEventHandler { const partialViewportData = this._context.viewLayout.getLinesViewportData(); this._context.model.setViewport(partialViewportData.startLineNumber, partialViewportData.endLineNumber, partialViewportData.centeredLineNumber); - let viewportData = new ViewportData(partialViewportData, this._context.model); + let viewportData = new ViewportData(partialViewportData, this._context.viewLayout.getWhitespaceViewportData(), this._context.model); if (this.viewLines.shouldRender()) { this.viewLines.renderText(viewportData); diff --git a/src/vs/editor/browser/viewParts/minimap/minimap.ts b/src/vs/editor/browser/viewParts/minimap/minimap.ts index 2e9415eb221..e0cb9cd2cb3 100644 --- a/src/vs/editor/browser/viewParts/minimap/minimap.ts +++ b/src/vs/editor/browser/viewParts/minimap/minimap.ts @@ -166,6 +166,7 @@ class MinimapLayout { viewportStartLineNumber: number, viewportEndLineNumber: number, viewportHeight: number, + viewportContainsWhitespaceGaps: boolean, lineCount: number, scrollbarSliderCenter: number ) { @@ -174,96 +175,57 @@ class MinimapLayout { const minimapLinesFitting = Math.floor(options.canvasInnerHeight / minimapLineHeight); const lineHeight = options.lineHeight; - // Sometimes, the number of rendered lines varies for a constant viewport height. - // The reason is that only parts of the viewportStartLineNumber or viewportEndLineNumber are visible. - // This leads to an apparent tremor in the minimap's slider height. - // We try here to compensate, making the slider slightly incorrect in these cases, but more pleasing to the eye. - let viewportLineCount = viewportEndLineNumber - viewportStartLineNumber + 1; - const expectedViewportLineCount = Math.round(viewportHeight / lineHeight); - if (viewportLineCount > expectedViewportLineCount) { - viewportLineCount = expectedViewportLineCount; + // >>> The minimap slider should be center-aligned with the scrollbar slider. <<< + // >>> The entire minimap is painted around this constraint. <<< + // + // The slider should encompass the visible lines... Mostly. + // + // The visible line count in a viewport can change due to a number of reasons: + // a) with the same viewport width, different scroll positions can result in partial lines being visible: + // e.g. for a line height of 20, and a viewport height of 600 + // * scrollTop = 0 => visible lines are [1, 30] + // * scrollTop = 10 => visible lines are [1, 31] (with lines 1 and 31 partially visible) + // * scrollTop = 20 => visible lines are [2, 31] + // b) whitespace gaps might make their way in the viewport (which results in a decrease in the visible line count) + // c) we could be in the scroll beyond last line case (which also results in a decrease in the visible line count, down to possibly only one line being visible) + // + // It therefore results that the slider height is variable, based on the current viewport. + + + // We must first establish a desirable slider height. + if (viewportContainsWhitespaceGaps) { + // case b) from above: there are whitespace gaps in the viewport. + // In this case, the height of the slider directly reflects the visible line count. + const viewportLineCount = viewportEndLineNumber - viewportStartLineNumber + 1; + this.sliderHeight = Math.floor(viewportLineCount * minimapLineHeight / pixelRatio); + } else { + // The slider has a stable height + const expectedViewportLineCount = viewportHeight / lineHeight; + this.sliderHeight = Math.floor(expectedViewportLineCount * minimapLineHeight / pixelRatio); } if (minimapLinesFitting >= lineCount) { // All lines fit in the minimap => no minimap scrolling + // => the slider cannot be center-aligned with the scrollbar slider this.startLineNumber = 1; this.endLineNumber = lineCount; - } else { - // The desire is to align (centers) the minimap's slider with the scrollbar's slider - - // For a resolved this.startLineNumber, we can compute the minimap's slider's center with the following formula: - // scrollbarSliderCenter = (viewportStartLineNumber - this.startLineNumber + viewportLineCount/2) * minimapLineHeight / pixelRatio; - // => - // scrollbarSliderCenter = (viewportStartLineNumber - this.startLineNumber + viewportLineCount/2) * minimapLineHeight / pixelRatio; - // scrollbarSliderCenter * pixelRatio / minimapLineHeight = viewportStartLineNumber - this.startLineNumber + viewportLineCount/2 - // this.startLineNumber = viewportStartLineNumber + viewportLineCount/2 - scrollbarSliderCenter * pixelRatio / minimapLineHeight - let desiredStartLineNumber = Math.floor(viewportStartLineNumber + viewportLineCount / 2 - scrollbarSliderCenter * pixelRatio / minimapLineHeight); - let desiredEndLineNumber = desiredStartLineNumber + minimapLinesFitting - 1; - - // Aligning the slider's centers can result (correctly) in tremor. - // i.e. scrolling down might result in the startLineNumber going up. - // Avoid this tremor by being consistent w.r.t. the previous computed result - if (lastRenderData) { - const lastLayoutDecision = lastRenderData.renderedLayout; - if (lastLayoutDecision.viewportStartLineNumber <= viewportStartLineNumber) { - // going down => make sure we don't go above our previous decision - if (desiredStartLineNumber < lastLayoutDecision.startLineNumber) { - desiredStartLineNumber = lastLayoutDecision.startLineNumber; - desiredEndLineNumber = desiredStartLineNumber + minimapLinesFitting - 1; - } - } - if (lastLayoutDecision.viewportStartLineNumber >= viewportStartLineNumber) { - // going up => make sure we don't go below our previous decision - if (desiredEndLineNumber > lastLayoutDecision.endLineNumber) { - desiredEndLineNumber = lastLayoutDecision.endLineNumber; - desiredStartLineNumber = desiredEndLineNumber - minimapLinesFitting + 1; - } - } - } - // Aligning the slider's centers is a very good thing, but this would make - // the minimap never scroll all the way to the top or to the bottom of the file. - // We therefore check that the viewport lines are in the minimap viewport. - - // (a) validate on start line number - if (desiredStartLineNumber < 1) { - // must start after 1 - desiredStartLineNumber = 1; - desiredEndLineNumber = desiredStartLineNumber + minimapLinesFitting - 1; - } - if (desiredStartLineNumber > viewportStartLineNumber) { - // must contain the viewport's start line number - desiredStartLineNumber = viewportStartLineNumber; - desiredEndLineNumber = desiredStartLineNumber + minimapLinesFitting - 1; - } - - // (b) validate on end line number - if (desiredEndLineNumber > lineCount) { - // must end before line count - desiredEndLineNumber = lineCount; - desiredStartLineNumber = desiredEndLineNumber - minimapLinesFitting + 1; - } - if (desiredEndLineNumber < viewportEndLineNumber) { - // must contain the viewport's end line number - desiredEndLineNumber = viewportEndLineNumber; - desiredStartLineNumber = desiredEndLineNumber - minimapLinesFitting + 1; - } - - this.startLineNumber = desiredStartLineNumber; - this.endLineNumber = desiredEndLineNumber; - } - - this.sliderTop = Math.floor((viewportStartLineNumber - this.startLineNumber) * minimapLineHeight / pixelRatio); - if (viewportEndLineNumber === lineCount) { - // The last line is in the viewport => try to extend slider height below the painted lines - let desiredSliderHeight = Math.floor(expectedViewportLineCount * minimapLineHeight / pixelRatio); - if (this.sliderTop + desiredSliderHeight > options.minimapHeight) { - this.sliderHeight = options.minimapHeight - this.sliderTop; + if (viewportEndLineNumber === lineCount) { + // case c) from above: we could be in the scroll beyond last line case + this.sliderTop = Math.floor((viewportStartLineNumber - this.startLineNumber) * minimapLineHeight / pixelRatio); } else { - this.sliderHeight = desiredSliderHeight; + const desiredSliderTop = (viewportStartLineNumber - this.startLineNumber) * minimapLineHeight / pixelRatio; + const desiredSliderBottom = (viewportEndLineNumber - this.startLineNumber) * minimapLineHeight / pixelRatio; + const desiredSliderCenter = (desiredSliderTop + desiredSliderBottom) / 2; + this.sliderTop = Math.floor(desiredSliderCenter - this.sliderHeight / 2); } } else { - this.sliderHeight = Math.floor(viewportLineCount * minimapLineHeight / pixelRatio); + // assign sliderTop last to maintain the same field assignment order in both if and else branches + const sliderTop = Math.floor(Math.min(options.minimapHeight - this.sliderHeight, Math.max(0, scrollbarSliderCenter - this.sliderHeight / 2))); + + this.startLineNumber = Math.max(1, Math.floor(viewportStartLineNumber - sliderTop * pixelRatio / minimapLineHeight)); + this.endLineNumber = Math.min(lineCount, this.startLineNumber + minimapLinesFitting - 1); + this.sliderTop = sliderTop; } } } @@ -671,6 +633,7 @@ export class Minimap extends ViewPart { renderingCtx.visibleRange.startLineNumber, renderingCtx.visibleRange.endLineNumber, renderingCtx.viewportHeight, + (renderingCtx.viewportData.whitespaceViewportData.length > 0), this._context.model.getLineCount(), this._editorScrollbar.getVerticalSliderVerticalCenter() ); diff --git a/src/vs/editor/browser/viewParts/viewZones/viewZones.ts b/src/vs/editor/browser/viewParts/viewZones/viewZones.ts index d91430803b3..a02489ace2c 100644 --- a/src/vs/editor/browser/viewParts/viewZones/viewZones.ts +++ b/src/vs/editor/browser/viewParts/viewZones/viewZones.ts @@ -300,7 +300,7 @@ export class ViewZones extends ViewPart { } public render(ctx: RestrictedRenderingContext): void { - let visibleWhitespaces = this._context.viewLayout.getWhitespaceViewportData(); + const visibleWhitespaces = ctx.viewportData.whitespaceViewportData; let visibleZones: { [id: string]: IViewWhitespaceViewportData; } = {}; let hasVisibleZone = false; diff --git a/src/vs/editor/common/viewLayout/viewLinesViewportData.ts b/src/vs/editor/common/viewLayout/viewLinesViewportData.ts index 6d8a2ec910d..10f4bee3abd 100644 --- a/src/vs/editor/common/viewLayout/viewLinesViewportData.ts +++ b/src/vs/editor/common/viewLayout/viewLinesViewportData.ts @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ 'use strict'; -import { ViewLineRenderingData, IViewModel, ViewModelDecoration } from 'vs/editor/common/viewModel/viewModel'; +import { ViewLineRenderingData, IViewModel, ViewModelDecoration, IViewWhitespaceViewportData } from 'vs/editor/common/viewModel/viewModel'; import { Range } from 'vs/editor/common/core/range'; export interface IPartialViewLinesViewportData { @@ -21,8 +21,7 @@ export interface IPartialViewLinesViewportData { */ readonly endLineNumber: number; /** - * relativeVerticalOffset[i] is the gap that must be left between line at - * i - 1 + `startLineNumber` and i + `startLineNumber`. + * relativeVerticalOffset[i] is the `top` position for line at `i` + `startLineNumber`. */ readonly relativeVerticalOffset: number[]; /** @@ -55,8 +54,7 @@ export class ViewportData { public readonly endLineNumber: number; /** - * relativeVerticalOffset[i] is the gap that must be left between line at - * i - 1 + `startLineNumber` and i + `startLineNumber`. + * relativeVerticalOffset[i] is the `top` position for line at `i` + `startLineNumber`. */ public readonly relativeVerticalOffset: number[]; @@ -70,16 +68,23 @@ export class ViewportData { */ public readonly bigNumbersDelta: number; + /** + * Positioning information about gaps whitespace. + */ + public readonly whitespaceViewportData: IViewWhitespaceViewportData[]; + private readonly _model: IViewModel; constructor( partialData: IPartialViewLinesViewportData, + whitespaceViewportData: IViewWhitespaceViewportData[], model: IViewModel ) { this.startLineNumber = partialData.startLineNumber | 0; this.endLineNumber = partialData.endLineNumber | 0; this.relativeVerticalOffset = partialData.relativeVerticalOffset; this.bigNumbersDelta = partialData.bigNumbersDelta | 0; + this.whitespaceViewportData = whitespaceViewportData; this._model = model; -- GitLab From 59c132912a84e985c39ff4ee68cf0fa1c1111ee4 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 7 Jun 2017 12:35:34 +0200 Subject: [PATCH 0589/1347] Added missing workbench parts and services to pull from Transifex. --- build/lib/i18n.js | 5 +++++ build/lib/i18n.ts | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/build/lib/i18n.js b/build/lib/i18n.js index 3cf4f78401e..e529cde52e1 100644 --- a/build/lib/i18n.js +++ b/build/lib/i18n.js @@ -530,22 +530,27 @@ var workbenchResources = [ { name: 'vs/workbench/parts/performance', project: workbenchProject }, { name: 'vs/workbench/parts/preferences', project: workbenchProject }, { name: 'vs/workbench/parts/quickopen', project: workbenchProject }, + { name: 'vs/workbench/parts/relauncher', project: workbenchProject }, { name: 'vs/workbench/parts/scm', project: workbenchProject }, { name: 'vs/workbench/parts/search', project: workbenchProject }, { name: 'vs/workbench/parts/snippets', project: workbenchProject }, + { name: 'vs/workbench/parts/surveys', project: workbenchProject }, { name: 'vs/workbench/parts/tasks', project: workbenchProject }, { name: 'vs/workbench/parts/terminal', project: workbenchProject }, { name: 'vs/workbench/parts/themes', project: workbenchProject }, { name: 'vs/workbench/parts/trust', project: workbenchProject }, { name: 'vs/workbench/parts/update', project: workbenchProject }, + { name: 'vs/workbench/parts/views', project: workbenchProject }, { name: 'vs/workbench/parts/watermark', project: workbenchProject }, { name: 'vs/workbench/parts/welcome', project: workbenchProject }, { name: 'vs/workbench/services/configuration', project: workbenchProject }, + { name: 'vs/workbench/services/crashReporter', project: workbenchProject }, { name: 'vs/workbench/services/editor', project: workbenchProject }, { name: 'vs/workbench/services/files', project: workbenchProject }, { name: 'vs/workbench/services/keybinding', project: workbenchProject }, { name: 'vs/workbench/services/message', project: workbenchProject }, { name: 'vs/workbench/services/mode', project: workbenchProject }, + { name: 'vs/workbench/services/progress', project: workbenchProject }, { name: 'vs/workbench/services/textfile', project: workbenchProject }, { name: 'vs/workbench/services/themes', project: workbenchProject }, { name: 'setup_messages', project: workbenchProject } diff --git a/build/lib/i18n.ts b/build/lib/i18n.ts index e4a1029f7fe..4cf89dacda0 100644 --- a/build/lib/i18n.ts +++ b/build/lib/i18n.ts @@ -607,22 +607,27 @@ const workbenchResources: Resource[] = [ { name: 'vs/workbench/parts/performance', project: workbenchProject }, { name: 'vs/workbench/parts/preferences', project: workbenchProject }, { name: 'vs/workbench/parts/quickopen', project: workbenchProject }, + { name: 'vs/workbench/parts/relauncher', project: workbenchProject }, { name: 'vs/workbench/parts/scm', project: workbenchProject }, { name: 'vs/workbench/parts/search', project: workbenchProject }, { name: 'vs/workbench/parts/snippets', project: workbenchProject }, + { name: 'vs/workbench/parts/surveys', project: workbenchProject }, { name: 'vs/workbench/parts/tasks', project: workbenchProject }, { name: 'vs/workbench/parts/terminal', project: workbenchProject }, { name: 'vs/workbench/parts/themes', project: workbenchProject }, { name: 'vs/workbench/parts/trust', project: workbenchProject }, { name: 'vs/workbench/parts/update', project: workbenchProject }, + { name: 'vs/workbench/parts/views', project: workbenchProject }, { name: 'vs/workbench/parts/watermark', project: workbenchProject }, { name: 'vs/workbench/parts/welcome', project: workbenchProject }, { name: 'vs/workbench/services/configuration', project: workbenchProject }, + { name: 'vs/workbench/services/crashReporter', project: workbenchProject }, { name: 'vs/workbench/services/editor', project: workbenchProject }, { name: 'vs/workbench/services/files', project: workbenchProject }, { name: 'vs/workbench/services/keybinding', project: workbenchProject }, { name: 'vs/workbench/services/message', project: workbenchProject }, { name: 'vs/workbench/services/mode', project: workbenchProject }, + { name: 'vs/workbench/services/progress', project: workbenchProject }, { name: 'vs/workbench/services/textfile', project: workbenchProject }, { name: 'vs/workbench/services/themes', project: workbenchProject }, { name: 'setup_messages', project: workbenchProject } -- GitLab From 1f3721743d5b9664902241d8657ad41fef14dd6e Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Wed, 7 Jun 2017 13:04:31 +0200 Subject: [PATCH 0590/1347] Clojure mode for .cljc files. Fixes #27741 --- extensions/clojure/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/clojure/package.json b/extensions/clojure/package.json index 23a065a7fbe..b404ef5fb8a 100644 --- a/extensions/clojure/package.json +++ b/extensions/clojure/package.json @@ -10,7 +10,7 @@ "languages": [{ "id": "clojure", "aliases": ["Clojure", "clojure"], - "extensions": [".clj", ".cljs", ".cljx", ".clojure", ".edn"], + "extensions": [".clj", ".cljs", ".cljc", ".cljx", ".clojure", ".edn"], "configuration": "./language-configuration.json" }], "grammars": [{ -- GitLab From b83ec1a0e1643a8dc750a75d9b1bd997a142a8e6 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 7 Jun 2017 13:04:59 +0200 Subject: [PATCH 0591/1347] fix #26275 --- src/vs/base/common/strings.ts | 37 ++++++ src/vs/base/test/common/strings.test.ts | 10 ++ .../electron-browser/snippetsService.ts | 123 ++++++++++-------- .../electron-browser/snippetsService.test.ts | 88 +++++++++++++ 4 files changed, 205 insertions(+), 53 deletions(-) create mode 100644 src/vs/workbench/parts/snippets/test/electron-browser/snippetsService.test.ts diff --git a/src/vs/base/common/strings.ts b/src/vs/base/common/strings.ts index 83bbdaf61b0..a106860ac9e 100644 --- a/src/vs/base/common/strings.ts +++ b/src/vs/base/common/strings.ts @@ -468,6 +468,43 @@ export function commonSuffixLength(a: string, b: string): number { return len; } +function substrEquals(a: string, aStart: number, aEnd: number, b: string, bStart: number, bEnd: number): boolean { + while (aStart < aEnd && bStart < bEnd) { + if (a[aStart] !== b[bStart]) { + return false; + } + aStart += 1; + bStart += 1; + } + return true; +} + +/** + * Return the overlap between the suffix of `a` and the prefix of `b`. + * For instance `overlap("foobar", "arr, I'm a pirate") === 2`. + */ +export function overlap(a: string, b: string): number { + let aEnd = a.length; + let bEnd = b.length; + let aStart = aEnd - bEnd; + + if (aStart === 0) { + return a === b ? aEnd : 0; + } else if (aStart < 0) { + bEnd += aStart; + aStart = 0; + } + + while (aStart < aEnd && bEnd > 0) { + if (substrEquals(a, aStart, aEnd, b, 0, bEnd)) { + return bEnd; + } + bEnd -= 1; + aStart += 1; + } + return 0; +} + // --- unicode // http://en.wikipedia.org/wiki/Surrogate_pair // Returns the code point starting at a specified index in a string diff --git a/src/vs/base/test/common/strings.test.ts b/src/vs/base/test/common/strings.test.ts index 07d750b0ecd..813b94abafe 100644 --- a/src/vs/base/test/common/strings.test.ts +++ b/src/vs/base/test/common/strings.test.ts @@ -93,6 +93,16 @@ suite('Strings', () => { assert.strictEqual(strings.format('Foo {0} Bar. {1}', '(foo)', '.test'), 'Foo (foo) Bar. .test'); }); + test('overlap', function () { + assert.equal(strings.overlap('foobar', 'arr, I am a priate'), 2); + assert.equal(strings.overlap('no', 'overlap'), 1); + assert.equal(strings.overlap('no', '0verlap'), 0); + assert.equal(strings.overlap('nothing', ''), 0); + assert.equal(strings.overlap('', 'nothing'), 0); + assert.equal(strings.overlap('full', 'full'), 4); + assert.equal(strings.overlap('full', 'fulloverlap'), 4); + }); + test('computeLineStarts', function () { function assertLineStart(text: string, ...offsets: number[]): void { const actual = strings.computeLineStarts(text); diff --git a/src/vs/workbench/parts/snippets/electron-browser/snippetsService.ts b/src/vs/workbench/parts/snippets/electron-browser/snippetsService.ts index 31b32d88c8a..43fe76a8ce0 100644 --- a/src/vs/workbench/parts/snippets/electron-browser/snippetsService.ts +++ b/src/vs/workbench/parts/snippets/electron-browser/snippetsService.ts @@ -5,7 +5,6 @@ 'use strict'; import { localize } from 'vs/nls'; -import * as strings from 'vs/base/common/strings'; import { IModel } from 'vs/editor/common/editorCommon'; import { ISuggestSupport, ISuggestResult, ISuggestion, LanguageId } from 'vs/editor/common/modes'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; @@ -13,6 +12,7 @@ import { registerSingleton } from 'vs/platform/instantiation/common/extensions'; import { setSnippetSuggestSupport } from 'vs/editor/contrib/suggest/browser/suggest'; import { IModeService } from 'vs/editor/common/services/modeService'; import { Position } from 'vs/editor/common/core/position'; +import { overlap, compare, startsWith } from 'vs/base/common/strings'; export const ISnippetsService = createDecorator('snippetService'); @@ -23,6 +23,8 @@ export interface ISnippetsService { registerSnippets(languageId: LanguageId, snippets: ISnippet[], owner: string): void; visitSnippets(languageId: LanguageId, accept: (snippet: ISnippet) => void): void; + + getSnippets(languageId: LanguageId): ISnippet[]; } export interface ISnippet { @@ -33,11 +35,7 @@ export interface ISnippet { extensionName?: string; } -interface ISnippetSuggestion extends ISuggestion { - disambiguateLabel: string; -} - -class SnippetsService implements ISnippetsService { +export class SnippetsService implements ISnippetsService { _serviceBrand: any; @@ -49,14 +47,14 @@ class SnippetsService implements ISnippetsService { setSnippetSuggestSupport(new SnippetSuggestProvider(modeService, this)); } - public registerSnippets(languageId: LanguageId, snippets: ISnippet[], fileName: string): void { + registerSnippets(languageId: LanguageId, snippets: ISnippet[], fileName: string): void { if (!this._snippets.has(languageId)) { this._snippets.set(languageId, new Map()); } this._snippets.get(languageId).set(fileName, snippets); } - public visitSnippets(languageId: LanguageId, accept: (snippet: ISnippet) => boolean): void { + visitSnippets(languageId: LanguageId, accept: (snippet: ISnippet) => boolean): void { const modeSnippets = this._snippets.get(languageId); if (modeSnippets) { modeSnippets.forEach(snippets => { @@ -67,6 +65,17 @@ class SnippetsService implements ISnippetsService { }); } } + + getSnippets(languageId: LanguageId): ISnippet[] { + const modeSnippets = this._snippets.get(languageId); + const ret: ISnippet[] = []; + if (modeSnippets) { + modeSnippets.forEach(snippets => { + ret.push(...snippets); + }); + } + return ret; + } } registerSingleton(ISnippetsService, SnippetsService); @@ -75,7 +84,13 @@ export interface ISimpleModel { getLineContent(lineNumber: number): string; } -class SnippetSuggestProvider implements ISuggestSupport { +interface ISnippetSuggestion { + suggestion: ISuggestion; + snippet: ISnippet; +} + + +export class SnippetSuggestProvider implements ISuggestSupport { constructor( @IModeService private _modeService: IModeService, @@ -87,55 +102,57 @@ class SnippetSuggestProvider implements ISuggestSupport { provideCompletionItems(model: IModel, position: Position): ISuggestResult { const languageId = this._getLanguageIdAtPosition(model, position); - const suggestions: ISnippetSuggestion[] = []; - - const word = model.getWordAtPosition(position); - const currentWord = word ? word.word.substring(0, position.column - word.startColumn).toLowerCase() : ''; - const currentFullWord = getNonWhitespacePrefix(model, position).toLowerCase(); - - this._snippets.visitSnippets(languageId, s => { - const prefixLower = s.prefix.toLowerCase(); - - let overwriteBefore = 0; - if (currentWord.length > 0) { - // there is a word -> the prefix should match that - if (strings.startsWith(prefixLower, currentWord)) { - overwriteBefore = currentWord.length; - } else { - return true; - } + const snippets = this._snippets.getSnippets(languageId); + const items: ISnippetSuggestion[] = []; - } else if (currentFullWord.length > currentWord.length) { - // there is something -> fine if it matches - overwriteBefore = strings.commonPrefixLength(prefixLower, currentFullWord); - } + const lowWordUntil = model.getWordUntilPosition(position).word.toLowerCase(); + const lowLineUntil = model.getLineContent(position.lineNumber).substr(Math.max(0, position.column - 100), position.column - 1).toLowerCase(); - // store in result - suggestions.push({ - type: 'snippet', - label: s.prefix, - get disambiguateLabel() { return localize('snippetSuggest.longLabel', "{0}, {1}", s.prefix, s.name); }, - detail: s.extensionName || localize('detail.userSnippet', "User Snippet"), - documentation: s.description, - insertText: s.codeSnippet, - sortText: `${s.prefix}-${s.extensionName || ''}`, - noAutoAccept: true, - snippetType: 'textmate', - overwriteBefore - }); + for (const snippet of snippets) { + + const lowPrefix = snippet.prefix.toLowerCase(); + let overwriteBefore: number; - return true; - }); + if (lowWordUntil.length > 0 && startsWith(lowPrefix, lowWordUntil)) { + // cheap match on the (none-empty) current word + overwriteBefore = lowWordUntil.length; + + } else if (lowLineUntil.length > 0) { + // compute overlap between snippet and line on text + overwriteBefore = overlap(lowLineUntil, snippet.prefix.toLowerCase()); + } + + if (overwriteBefore !== 0) { + + items.push({ + snippet, + suggestion: { + type: 'snippet', + label: snippet.prefix, + detail: snippet.extensionName || localize('detail.userSnippet', "User Snippet"), + documentation: snippet.description, + insertText: snippet.codeSnippet, + sortText: `${snippet.prefix}-${snippet.extensionName || ''}`, + noAutoAccept: true, + snippetType: 'textmate', + overwriteBefore + } + }); + } + } // dismbiguate suggestions with same labels - let lastSuggestion: ISnippetSuggestion; - for (const suggestion of suggestions.sort(SnippetSuggestProvider._compareSuggestionsByLabel)) { - if (lastSuggestion && lastSuggestion.label === suggestion.label) { + const suggestions: ISuggestion[] = []; + let lastItem: ISnippetSuggestion; + for (const item of items.sort(SnippetSuggestProvider._compareSuggestionsByLabel)) { + if (lastItem && lastItem.suggestion.label === item.suggestion.label) { // use the disambiguateLabel instead of the actual label - lastSuggestion.label = lastSuggestion.disambiguateLabel; - suggestion.label = suggestion.disambiguateLabel; + lastItem.suggestion.label = localize('snippetSuggest.longLabel', "{0}, {1}", lastItem.suggestion.label, lastItem.snippet.name); + item.suggestion.label = localize('snippetSuggest.longLabel', "{0}, {1}", item.suggestion.label, item.snippet.name); } - lastSuggestion = suggestion; + lastItem = item; + + suggestions.push(item.suggestion); } return { suggestions }; @@ -154,8 +171,8 @@ class SnippetSuggestProvider implements ISuggestSupport { return languageId; } - private static _compareSuggestionsByLabel(a: ISuggestion, b: ISuggestion): number { - return strings.compare(a.label, b.label); + private static _compareSuggestionsByLabel(a: ISnippetSuggestion, b: ISnippetSuggestion): number { + return compare(a.suggestion.label, b.suggestion.label); } } diff --git a/src/vs/workbench/parts/snippets/test/electron-browser/snippetsService.test.ts b/src/vs/workbench/parts/snippets/test/electron-browser/snippetsService.test.ts new file mode 100644 index 00000000000..d9fa6f1b294 --- /dev/null +++ b/src/vs/workbench/parts/snippets/test/electron-browser/snippetsService.test.ts @@ -0,0 +1,88 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +'use strict'; + +import * as assert from 'assert'; +import { SnippetsService, ISnippet, SnippetSuggestProvider } from 'vs/workbench/parts/snippets/electron-browser/snippetsService'; +import { Position } from 'vs/editor/common/core/position'; +import { ModesRegistry } from 'vs/editor/common/modes/modesRegistry'; +import { ModeServiceImpl } from 'vs/editor/common/services/modeServiceImpl'; +import { Model } from 'vs/editor/common/model/model'; + +suite('SnippetsService', function () { + + suiteSetup(function () { + ModesRegistry.registerLanguage({ + id: 'fooLang', + extensions: ['.fooLang',] + }); + }); + + let modeService: ModeServiceImpl; + let snippetService: SnippetsService; + + setup(function () { + modeService = new ModeServiceImpl(); + snippetService = new SnippetsService(modeService); + + snippetService.registerSnippets(modeService.getLanguageIdentifier('fooLang').id, [{ + prefix: 'bar', + codeSnippet: 'barCodeSnippet', + name: 'barTest', + description: '' + }, { + prefix: 'bazz', + codeSnippet: 'bazzCodeSnippet', + name: 'bazzTest', + description: '' + }], 'fooFile.json'); + }); + + test('snippet completions - simple', function () { + + const provider = new SnippetSuggestProvider(modeService, snippetService); + const model = Model.createFromString('', undefined, modeService.getLanguageIdentifier('fooLang')); + + const result = provider.provideCompletionItems(model, new Position(1, 1)); + + assert.equal(result.incomplete, undefined); + assert.equal(result.suggestions.length, 2); + }); + + test('snippet completions - with prefix', function () { + + const provider = new SnippetSuggestProvider(modeService, snippetService); + const model = Model.createFromString('bar', undefined, modeService.getLanguageIdentifier('fooLang')); + + const result = provider.provideCompletionItems(model, new Position(1, 4)); + + assert.equal(result.incomplete, undefined); + assert.equal(result.suggestions.length, 1); + assert.equal(result.suggestions[0].label, 'bar'); + assert.equal(result.suggestions[0].insertText, 'barCodeSnippet'); + }); + + test('Cannot use "[{ + prefix: ' Date: Wed, 7 Jun 2017 15:27:50 +0200 Subject: [PATCH 0592/1347] Improve commands picker (#28184) --- .../ui/resourceviewer/resourceViewer.ts | 4 +- src/vs/base/common/filters.ts | 4 +- src/vs/base/common/glob.ts | 4 +- src/vs/base/common/map.ts | 93 ++-- src/vs/base/common/strings.ts | 4 +- .../parts/quickopen/browser/quickOpenModel.ts | 30 ++ .../quickopen/browser/quickOpenWidget.ts | 19 +- .../parts/quickopen/browser/quickopen.css | 12 +- src/vs/base/test/common/map.test.ts | 162 +++++-- .../test/common/instantiationServiceMock.ts | 6 +- src/vs/platform/quickOpen/common/quickOpen.ts | 1 + .../browser/parts/editor/editorPicker.ts | 14 +- .../browser/parts/editor/tabsTitleControl.ts | 6 +- .../parts/quickopen/quickOpenController.ts | 25 +- src/vs/workbench/browser/quickopen.ts | 101 +---- .../electron-browser/main.contribution.ts | 10 + .../node/extensionsWorkbenchService.ts | 2 +- .../parts/markers/common/markersModel.ts | 4 +- .../preferences/browser/preferencesService.ts | 2 +- .../parts/preferences/common/preferences.ts | 2 +- .../preferences/common/preferencesModels.ts | 2 +- .../quickopen/browser/commandsHandler.ts | 423 ++++++++++++------ .../browser/media/commandsHandler.css | 14 - .../browser/quickopen.contribution.ts | 5 +- .../quickopen/browser/viewPickerHandler.ts | 6 +- .../parts/search/common/searchModel.ts | 16 +- 26 files changed, 602 insertions(+), 369 deletions(-) delete mode 100644 src/vs/workbench/parts/quickopen/browser/media/commandsHandler.css diff --git a/src/vs/base/browser/ui/resourceviewer/resourceViewer.ts b/src/vs/base/browser/ui/resourceviewer/resourceViewer.ts index ea437ffc78b..4244dc01a59 100644 --- a/src/vs/base/browser/ui/resourceviewer/resourceViewer.ts +++ b/src/vs/base/browser/ui/resourceviewer/resourceViewer.ts @@ -13,7 +13,7 @@ import paths = require('vs/base/common/paths'); import { Builder, $ } from 'vs/base/browser/builder'; import DOM = require('vs/base/browser/dom'); import { DomScrollableElement } from 'vs/base/browser/ui/scrollbar/scrollableElement'; -import { BoundedLinkedMap } from 'vs/base/common/map'; +import { BoundedMap } from 'vs/base/common/map'; interface MapExtToMediaMimes { @@ -80,7 +80,7 @@ export interface IResourceDescriptor { // we need to bypass the cache or not. We could always bypass the cache everytime we show the image // however that has very bad impact on memory consumption because each time the image gets shown, // memory grows (see also https://github.com/electron/electron/issues/6275) -const IMAGE_RESOURCE_ETAG_CACHE = new BoundedLinkedMap<{ etag: string, src: string }>(100); +const IMAGE_RESOURCE_ETAG_CACHE = new BoundedMap<{ etag: string, src: string }>(100); function imageSrc(descriptor: IResourceDescriptor): string { const src = descriptor.resource.toString(); diff --git a/src/vs/base/common/filters.ts b/src/vs/base/common/filters.ts index d4b186650cc..e6404bb6edc 100644 --- a/src/vs/base/common/filters.ts +++ b/src/vs/base/common/filters.ts @@ -5,7 +5,7 @@ 'use strict'; import strings = require('vs/base/common/strings'); -import { BoundedLinkedMap } from 'vs/base/common/map'; +import { BoundedMap } from 'vs/base/common/map'; import { CharCode } from 'vs/base/common/charCode'; export interface IFilter { @@ -334,7 +334,7 @@ export enum SubstringMatching { export const fuzzyContiguousFilter = or(matchesPrefix, matchesCamelCase, matchesContiguousSubString); const fuzzySeparateFilter = or(matchesPrefix, matchesCamelCase, matchesSubString); -const fuzzyRegExpCache = new BoundedLinkedMap(10000); // bounded to 10000 elements +const fuzzyRegExpCache = new BoundedMap(10000); // bounded to 10000 elements export function matchesFuzzy(word: string, wordToMatchAgainst: string, enableSeparateSubstringMatching = false): IMatch[] { if (typeof word !== 'string' || typeof wordToMatchAgainst !== 'string') { diff --git a/src/vs/base/common/glob.ts b/src/vs/base/common/glob.ts index 7197d9ed801..33da9d6b879 100644 --- a/src/vs/base/common/glob.ts +++ b/src/vs/base/common/glob.ts @@ -7,7 +7,7 @@ import arrays = require('vs/base/common/arrays'); import strings = require('vs/base/common/strings'); import paths = require('vs/base/common/paths'); -import { BoundedLinkedMap } from 'vs/base/common/map'; +import { BoundedMap } from 'vs/base/common/map'; import { CharCode } from 'vs/base/common/charCode'; import { TPromise } from 'vs/base/common/winjs.base'; @@ -242,7 +242,7 @@ interface ParsedExpressionPattern { allPaths?: string[]; } -const CACHE = new BoundedLinkedMap(10000); // bounded to 10000 elements +const CACHE = new BoundedMap(10000); // bounded to 10000 elements const FALSE = function () { return false; diff --git a/src/vs/base/common/map.ts b/src/vs/base/common/map.ts index 09c03b971b0..ba7089dd829 100644 --- a/src/vs/base/common/map.ts +++ b/src/vs/base/common/map.ts @@ -12,8 +12,6 @@ export interface Key { } export interface Entry { - next?: Entry; - prev?: Entry; key: K; value: T; } @@ -22,7 +20,7 @@ export interface Entry { * A simple map to store value by a key object. Key can be any object that has toString() function to get * string value of the key. */ -export class LinkedMap { +export class SimpleMap { protected map: { [key: string]: Entry }; protected _size: number; @@ -122,22 +120,64 @@ export class LinkedMap { } } +export interface ISerializedBoundedLinkedMap { + entries: { key: string; value: T }[]; +} + +export interface LinkedEntry extends Entry { + next?: LinkedEntry; + prev?: LinkedEntry; +} + /** * A simple Map that optionally allows to set a limit of entries to store. Once the limit is hit, * the cache will remove the entry that was last recently added. Or, if a ratio is provided below 1, * all elements will be removed until the ratio is full filled (e.g. 0.75 to remove 25% of old elements). */ -export class BoundedLinkedMap { - protected map: { [key: string]: Entry }; - private head: Entry; - private tail: Entry; +export class BoundedMap { + protected map: { [key: string]: LinkedEntry }; + + private head: LinkedEntry; + private tail: LinkedEntry; private _size: number; private ratio: number; - constructor(private limit = Number.MAX_VALUE, ratio = 1) { + constructor(private limit = Number.MAX_VALUE, ratio = 1, value?: ISerializedBoundedLinkedMap) { this.map = Object.create(null); this._size = 0; this.ratio = limit * ratio; + + if (value) { + value.entries.forEach(entry => { + this.set(entry.key, entry.value); + }); + } + } + + public setLimit(limit: number): void { + if (limit < 0) { + return; // invalid limit + } + + this.limit = limit; + while (this._size > this.limit) { + this.trim(); + } + } + + public serialize(): ISerializedBoundedLinkedMap { + const serialized: ISerializedBoundedLinkedMap = { entries: [] }; + + let element = this.tail; + while (element) { + serialized.entries.push({ key: element.key, value: element.value }); + if (element === element.next) { + break; // end reached + } + element = element.next; + } + + return serialized; } public get size(): number { @@ -149,7 +189,7 @@ export class BoundedLinkedMap { return false; // already present! } - const entry: Entry = { key, value }; + const entry: LinkedEntry = { key, value }; this.push(entry); if (this._size > this.limit) { @@ -212,7 +252,7 @@ export class BoundedLinkedMap { this.tail = null; } - protected push(entry: Entry): void { + protected push(entry: LinkedEntry): void { if (this.head) { // [A]-[B] = [A]-[B]->[X] entry.prev = this.head; @@ -264,41 +304,14 @@ export class BoundedLinkedMap { // [x]-[B] = [B] this.tail = this.tail.next; - this.tail.prev = null; + if (this.tail) { + this.tail.prev = null; + } } } } } -/** - * A subclass of Map that makes an entry the MRU entry as soon - * as it is being accessed. In combination with the limit for the - * maximum number of elements in the cache, it helps to remove those - * entries from the cache that are LRU. - */ -export class LRUCache extends BoundedLinkedMap { - - constructor(limit: number) { - super(limit); - } - - public get(key: string): T { - - // Upon access of an entry, make it the head of - // the linked map so that it is the MRU element - const entry = this.map[key]; - if (entry) { - this.delete(key); - this.push(entry); - - return entry.value; - } - - - return null; - } -} - // --- trie'ish datastructure class Node { diff --git a/src/vs/base/common/strings.ts b/src/vs/base/common/strings.ts index a106860ac9e..1bed21cd315 100644 --- a/src/vs/base/common/strings.ts +++ b/src/vs/base/common/strings.ts @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ 'use strict'; -import { BoundedLinkedMap } from 'vs/base/common/map'; +import { BoundedMap } from 'vs/base/common/map'; import { CharCode } from 'vs/base/common/charCode'; /** @@ -251,7 +251,7 @@ export function regExpLeadsToEndlessLoop(regexp: RegExp): boolean { */ export let canNormalize = typeof (('').normalize) === 'function'; const nonAsciiCharactersPattern = /[^\u0000-\u0080]/; -const normalizedCache = new BoundedLinkedMap(10000); // bounded to 10000 elements +const normalizedCache = new BoundedMap(10000); // bounded to 10000 elements export function normalizeNFC(str: string): string { if (!canNormalize || !str) { return str; diff --git a/src/vs/base/parts/quickopen/browser/quickOpenModel.ts b/src/vs/base/parts/quickopen/browser/quickOpenModel.ts index 06629740fd7..7023eed3672 100644 --- a/src/vs/base/parts/quickopen/browser/quickOpenModel.ts +++ b/src/vs/base/parts/quickopen/browser/quickOpenModel.ts @@ -21,6 +21,9 @@ import { ActionBar, IActionItem } from 'vs/base/browser/ui/actionbar/actionbar'; import { HighlightedLabel } from 'vs/base/browser/ui/highlightedlabel/highlightedLabel'; import DOM = require('vs/base/browser/dom'); import { IQuickOpenStyles } from 'vs/base/parts/quickopen/browser/quickOpenWidget'; +import { KeybindingLabel } from "vs/base/browser/ui/keybindingLabel/keybindingLabel"; +import { OS } from "vs/base/common/platform"; +import { ResolvedKeybinding } from "vs/base/common/keyCodes"; export interface IContext { event: any; @@ -108,6 +111,13 @@ export class QuickOpenEntry { return null; } + /** + * An optional keybinding to show for an entry. + */ + public getKeybinding(): ResolvedKeybinding { + return null; + } + /** * A resource for this entry. Resource URIs can be used to compare different kinds of entries and group * them together. @@ -389,6 +399,7 @@ export interface IQuickOpenEntryTemplateData { label: IconLabel; detail: HighlightedLabel; description: HighlightedLabel; + keybinding: KeybindingLabel; actionBar: ActionBar; } @@ -449,6 +460,12 @@ class Renderer implements IRenderer { DOM.addClass(descriptionContainer, 'quick-open-entry-description'); const description = new HighlightedLabel(descriptionContainer); + // Keybinding + const keybindingContainer = document.createElement('span'); + row1.appendChild(keybindingContainer); + DOM.addClass(keybindingContainer, 'quick-open-entry-keybinding'); + const keybinding = new KeybindingLabel(keybindingContainer, OS); + // Detail const detailContainer = document.createElement('div'); row2.appendChild(detailContainer); @@ -481,6 +498,7 @@ class Renderer implements IRenderer { label, detail, description, + keybinding, group, actionBar }; @@ -508,6 +526,13 @@ class Renderer implements IRenderer { } }); + // Entry group class + if (entry instanceof QuickOpenEntryGroup && entry.getGroupLabel()) { + DOM.addClass(data.container, 'has-group-label'); + } else { + DOM.removeClass(data.container, 'has-group-label'); + } + // Entry group if (entry instanceof QuickOpenEntryGroup) { const group = entry; @@ -547,6 +572,9 @@ class Renderer implements IRenderer { // Description data.description.set(entry.getDescription(), descriptionHighlights || []); data.description.element.title = entry.getDescription(); + + // Keybinding + data.keybinding.set(entry.getKeybinding(), null); } } @@ -558,6 +586,8 @@ class Renderer implements IRenderer { data.entry = null; data.description.dispose(); data.description = null; + data.keybinding.dispose(); + data.keybinding = null; data.detail.dispose(); data.detail = null; data.group = null; diff --git a/src/vs/base/parts/quickopen/browser/quickOpenWidget.ts b/src/vs/base/parts/quickopen/browser/quickOpenWidget.ts index 5ac4eba8972..54953ca6c8e 100644 --- a/src/vs/base/parts/quickopen/browser/quickOpenWidget.ts +++ b/src/vs/base/parts/quickopen/browser/quickOpenWidget.ts @@ -15,7 +15,7 @@ import { IQuickNavigateConfiguration, IAutoFocus, IEntryRunContext, IModel, Mode import { Filter, Renderer, DataSource, IModelProvider, AccessibilityProvider } from 'vs/base/parts/quickopen/browser/quickOpenViewer'; import { Dimension, Builder, $ } from 'vs/base/browser/builder'; import { ISelectionEvent, IFocusEvent, ITree, ContextMenuEvent, IActionProvider, ITreeStyles } from 'vs/base/parts/tree/browser/tree'; -import { InputBox, MessageType, IInputBoxStyles } from 'vs/base/browser/ui/inputbox/inputBox'; +import { InputBox, MessageType, IInputBoxStyles, IRange } from 'vs/base/browser/ui/inputbox/inputBox'; import Severity from 'vs/base/common/severity'; import { Tree } from 'vs/base/parts/tree/browser/treeImpl'; import { ProgressBar } from 'vs/base/browser/ui/progressbar/progressbar'; @@ -59,6 +59,7 @@ export interface IQuickOpenStyles extends IInputBoxStyles, ITreeStyles { export interface IShowOptions { quickNavigateConfiguration?: IQuickNavigateConfiguration; autoFocus?: IAutoFocus; + inputSelection?: IRange; } export interface IQuickOpenUsageLogger { @@ -202,8 +203,11 @@ export class QuickOpenWidget implements IModelProvider { this.navigateInTree(keyboardEvent.keyCode, keyboardEvent.shiftKey); - // Position cursor at the end of input to allow right arrow (open in background) to function immediately - this.inputBox.inputElement.selectionStart = this.inputBox.value.length; + // Position cursor at the end of input to allow right arrow (open in background) + // to function immediately unless the user has made a selection + if (this.inputBox.inputElement.selectionStart === this.inputBox.inputElement.selectionEnd) { + this.inputBox.inputElement.selectionStart = this.inputBox.value.length; + } } // Select element on Enter or on Arrow-Right if we are at the end of the input @@ -392,7 +396,9 @@ export class QuickOpenWidget implements IModelProvider { return false; // no modifiers allowed } - return this.inputBox.inputElement.selectionStart === this.inputBox.value.length; // only when cursor is at the end of the input field value + // validate the cursor is at the end of the input, and if not prevent + // opening in the background such as the selection can be changed + return this.inputBox.inputElement.selectionEnd === this.inputBox.value.length; } private onType(): void { @@ -561,6 +567,11 @@ export class QuickOpenWidget implements IModelProvider { this.doShowWithInput(param, options && options.autoFocus ? options.autoFocus : {}); } + // Respect selectAll option + if (options && options.inputSelection && !this.quickNavigateConfiguration) { + this.inputBox.select(options.inputSelection); + } + if (this.callbacks.onShow) { this.callbacks.onShow(); } diff --git a/src/vs/base/parts/quickopen/browser/quickopen.css b/src/vs/base/parts/quickopen/browser/quickopen.css index 84eb7d781fb..9173f8121cc 100644 --- a/src/vs/base/parts/quickopen/browser/quickopen.css +++ b/src/vs/base/parts/quickopen/browser/quickopen.css @@ -36,7 +36,7 @@ } .quick-open-widget .quick-open-tree { - line-height: 1.8em; + line-height: 22px; } .quick-open-widget .quick-open-tree .monaco-tree-row > .content > .sub-content { @@ -87,6 +87,14 @@ text-overflow: ellipsis; } +.quick-open-widget .quick-open-tree .content.has-group-label .quick-open-entry-keybinding { + margin-right: 8px; +} + +.quick-open-widget .quick-open-tree .quick-open-entry-keybinding .monaco-kbkey { + vertical-align: inherit; +} + .quick-open-widget .quick-open-tree .results-group { margin-right: 18px; } @@ -121,7 +129,7 @@ } .monaco-tree .monaco-tree-row > .content.actions > .primary-action-bar { - line-height: 1em; + line-height: 22px; } .monaco-tree .monaco-tree-row > .content.actions > .primary-action-bar { diff --git a/src/vs/base/test/common/map.test.ts b/src/vs/base/test/common/map.test.ts index 43cbc7b44b9..38998ac5fb8 100644 --- a/src/vs/base/test/common/map.test.ts +++ b/src/vs/base/test/common/map.test.ts @@ -5,14 +5,14 @@ 'use strict'; -import { BoundedLinkedMap, LRUCache, LinkedMap, TrieMap, ResourceMap } from 'vs/base/common/map'; +import { BoundedMap, SimpleMap, TrieMap, ResourceMap } from 'vs/base/common/map'; import * as assert from 'assert'; import URI from 'vs/base/common/uri'; suite('Map', () => { - test('LinkedMap - basics', function () { - const map = new LinkedMap(); + test('SimpleMap - basics', function () { + const map = new SimpleMap(); assert.equal(map.size, 0); @@ -72,8 +72,8 @@ suite('Map', () => { assert.equal(res, 'bar'); }); - test('BoundedLinkedMap - basics', function () { - const map = new BoundedLinkedMap(); + test('BoundedMap - basics', function () { + const map = new BoundedMap(); assert.equal(map.size, 0); @@ -133,8 +133,96 @@ suite('Map', () => { assert.equal(res, 'bar'); }); - test('BoundedLinkedMap - bounded', function () { - const map = new BoundedLinkedMap(5); + test('BoundedMap - serialization', function () { + const map = new BoundedMap(5); + + map.set('1', 1); + map.set('2', '2'); + map.set('3', true); + + const obj = Object.create(null); + map.set('4', obj); + + const date = Date.now(); + map.set('5', date); + + const mapClone = new BoundedMap(5, 1, map.serialize()); + + assert.deepEqual(map.serialize(), mapClone.serialize()); + + assert.equal(mapClone.size, 5); + assert.equal(mapClone.get('1'), 1); + assert.equal(mapClone.get('2'), '2'); + assert.equal(mapClone.get('3'), true); + assert.equal(mapClone.get('4'), obj); + assert.equal(mapClone.get('5'), date); + assert.ok(!mapClone.get('6')); + + mapClone.set('6', '6'); + assert.equal(mapClone.size, 5); + assert.ok(!mapClone.get('1')); + }); + + test('BoundedMap - setLimit', function () { + const map = new BoundedMap(5); + + map.set('1', 1); + map.set('2', '2'); + map.set('3', true); + + const obj = Object.create(null); + map.set('4', obj); + + const date = Date.now(); + map.set('5', date); + + assert.equal(map.size, 5); + assert.equal(map.get('1'), 1); + assert.equal(map.get('2'), '2'); + assert.equal(map.get('3'), true); + assert.equal(map.get('4'), obj); + assert.equal(map.get('5'), date); + assert.ok(!map.get('6')); + + map.setLimit(3); + + assert.equal(map.size, 3); + assert.ok(!map.get('1')); + assert.ok(!map.get('2')); + assert.equal(map.get('3'), true); + assert.equal(map.get('4'), obj); + assert.equal(map.get('5'), date); + + map.setLimit(0); + + assert.equal(map.size, 0); + assert.ok(!map.get('3')); + assert.ok(!map.get('4')); + assert.ok(!map.get('5')); + + map.set('6', 6); + + assert.equal(map.size, 0); + assert.ok(!map.get('6')); + + map.setLimit(100); + + map.set('1', 1); + map.set('2', '2'); + map.set('3', true); + map.set('4', obj); + map.set('5', date); + + assert.equal(map.size, 5); + assert.equal(map.get('1'), 1); + assert.equal(map.get('2'), '2'); + assert.equal(map.get('3'), true); + assert.equal(map.get('4'), obj); + assert.equal(map.get('5'), date); + }); + + test('BoundedMap - bounded', function () { + const map = new BoundedMap(5); assert.equal(0, map.size); @@ -202,8 +290,8 @@ suite('Map', () => { assert.equal(map.get('14'), 14); }); - test('BoundedLinkedMap - bounded with ratio', function () { - const map = new BoundedLinkedMap(6, 0.5); + test('BoundedMap - bounded with ratio', function () { + const map = new BoundedMap(6, 0.5); assert.equal(0, map.size); @@ -240,37 +328,47 @@ suite('Map', () => { assert.equal(map.get('10'), 10); }); - test('LRUCache', function () { - const cache = new LRUCache(3); + test('BoundedMap - MRU order', function () { + const map = new BoundedMap(3); - assert.equal(0, cache.size); + function peek(key) { + const res = map.get(key); + if (res) { + map.delete(key); + map.set(key, res); + } - cache.set('1', 1); - cache.set('2', 2); - cache.set('3', 3); + return res; + } - assert.equal(3, cache.size); + assert.equal(0, map.size); - assert.equal(cache.get('1'), 1); - assert.equal(cache.get('2'), 2); - assert.equal(cache.get('3'), 3); + map.set('1', 1); + map.set('2', 2); + map.set('3', 3); - cache.set('4', 4); + assert.equal(3, map.size); - assert.equal(3, cache.size); - assert.equal(cache.get('4'), 4); // this changes MRU order - assert.equal(cache.get('3'), 3); - assert.equal(cache.get('2'), 2); + assert.equal(map.get('1'), 1); + assert.equal(map.get('2'), 2); + assert.equal(map.get('3'), 3); + + map.set('4', 4); + + assert.equal(3, map.size); + assert.equal(peek('4'), 4); // this changes MRU order + assert.equal(peek('3'), 3); + assert.equal(peek('2'), 2); - cache.set('5', 5); - cache.set('6', 6); + map.set('5', 5); + map.set('6', 6); - assert.equal(3, cache.size); - assert.equal(cache.get('2'), 2); - assert.equal(cache.get('5'), 5); - assert.equal(cache.get('6'), 6); - assert.ok(!cache.has('3')); - assert.ok(!cache.has('4')); + assert.equal(3, map.size); + assert.equal(peek('2'), 2); + assert.equal(peek('5'), 5); + assert.equal(peek('6'), 6); + assert.ok(!map.has('3')); + assert.ok(!map.has('4')); }); diff --git a/src/vs/platform/instantiation/test/common/instantiationServiceMock.ts b/src/vs/platform/instantiation/test/common/instantiationServiceMock.ts index c759246ea8f..717d46e30a1 100644 --- a/src/vs/platform/instantiation/test/common/instantiationServiceMock.ts +++ b/src/vs/platform/instantiation/test/common/instantiationServiceMock.ts @@ -8,7 +8,7 @@ import * as sinon from 'sinon'; import { TPromise } from 'vs/base/common/winjs.base'; import * as types from 'vs/base/common/types'; -import { LinkedMap } from 'vs/base/common/map'; +import { SimpleMap } from 'vs/base/common/map'; import { InstantiationService } from 'vs/platform/instantiation/common/instantiationService'; import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; import { ServiceIdentifier } from 'vs/platform/instantiation/common/instantiation'; @@ -20,12 +20,12 @@ interface IServiceMock { export class TestInstantiationService extends InstantiationService { - private _servciesMap: LinkedMap, any>; + private _servciesMap: SimpleMap, any>; constructor(private _serviceCollection: ServiceCollection = new ServiceCollection()) { super(_serviceCollection); - this._servciesMap = new LinkedMap, any>(); + this._servciesMap = new SimpleMap, any>(); } public get(service: ServiceIdentifier): T { diff --git a/src/vs/platform/quickOpen/common/quickOpen.ts b/src/vs/platform/quickOpen/common/quickOpen.ts index 160539465d5..6fe5fcc6169 100644 --- a/src/vs/platform/quickOpen/common/quickOpen.ts +++ b/src/vs/platform/quickOpen/common/quickOpen.ts @@ -101,6 +101,7 @@ export interface IInputOptions { export interface IShowOptions { quickNavigateConfiguration?: IQuickNavigateConfiguration; + inputSelection?: { start: number; end: number; }; } export const IQuickOpenService = createDecorator('quickOpenService'); diff --git a/src/vs/workbench/browser/parts/editor/editorPicker.ts b/src/vs/workbench/browser/parts/editor/editorPicker.ts index d1a0d74383d..4e73f77bb15 100644 --- a/src/vs/workbench/browser/parts/editor/editorPicker.ts +++ b/src/vs/workbench/browser/parts/editor/editorPicker.ts @@ -12,7 +12,7 @@ import URI from 'vs/base/common/uri'; import errors = require('vs/base/common/errors'); import strings = require('vs/base/common/strings'); import { IIconLabelOptions } from 'vs/base/browser/ui/iconLabel/iconLabel'; -import { IAutoFocus, Mode, IEntryRunContext, IQuickNavigateConfiguration } from 'vs/base/parts/quickopen/common/quickOpen'; +import { IAutoFocus, Mode, IEntryRunContext, IQuickNavigateConfiguration, IModel } from 'vs/base/parts/quickopen/common/quickOpen'; import { QuickOpenModel, QuickOpenEntry, QuickOpenEntryGroup } from 'vs/base/parts/quickopen/browser/quickOpenModel'; import scorer = require('vs/base/common/scorer'); import { IModeService } from 'vs/editor/common/services/modeService'; @@ -185,8 +185,8 @@ export abstract class EditorGroupPicker extends BaseEditorPicker { return nls.localize('noOpenedEditors', "List of opened editors is currently empty in group"); } - public getAutoFocus(searchValue: string, quickNavigateConfiguration: IQuickNavigateConfiguration): IAutoFocus { - if (searchValue || !quickNavigateConfiguration) { + public getAutoFocus(searchValue: string, context: { model: IModel, quickNavigateConfiguration?: IQuickNavigateConfiguration }): IAutoFocus { + if (searchValue || !context.quickNavigateConfiguration) { return { autoFocusFirstEntry: true }; @@ -195,10 +195,10 @@ export abstract class EditorGroupPicker extends BaseEditorPicker { const stacks = this.editorGroupService.getStacksModel(); const group = stacks.groupAt(this.getPosition()); if (!group) { - return super.getAutoFocus(searchValue); + return super.getAutoFocus(searchValue, context); } - const isShiftNavigate = (quickNavigateConfiguration && quickNavigateConfiguration.keybindings.some(k => { + const isShiftNavigate = (context.quickNavigateConfiguration && context.quickNavigateConfiguration.keybindings.some(k => { const [firstPart, chordPart] = k.getParts(); if (chordPart) { return false; @@ -262,13 +262,13 @@ export class AllEditorsPicker extends BaseEditorPicker { return nls.localize('noOpenedEditorsAllGroups', "List of opened editors is currently empty"); } - public getAutoFocus(searchValue: string): IAutoFocus { + public getAutoFocus(searchValue: string, context: { model: IModel, quickNavigateConfiguration?: IQuickNavigateConfiguration }): IAutoFocus { if (searchValue) { return { autoFocusFirstEntry: true }; } - return super.getAutoFocus(searchValue); + return super.getAutoFocus(searchValue, context); } } \ No newline at end of file diff --git a/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts b/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts index 612f7aff73f..c9a96445ccf 100644 --- a/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts +++ b/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts @@ -36,7 +36,7 @@ import { IDisposable, dispose, combinedDisposable } from 'vs/base/common/lifecyc import { ScrollableElement } from 'vs/base/browser/ui/scrollbar/scrollableElement'; import { ScrollbarVisibility } from 'vs/base/common/scrollable'; import { extractResources } from 'vs/base/browser/dnd'; -import { LinkedMap } from 'vs/base/common/map'; +import { SimpleMap } from 'vs/base/common/map'; import { DelegatingWorkbenchEditorService } from 'vs/workbench/services/editor/browser/editorService'; import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; import { IThemeService, registerThemingParticipant, ITheme, ICssStyleCollector } from 'vs/platform/theme/common/themeService'; @@ -320,8 +320,8 @@ export class TabsTitleControl extends TitleControl { private getUniqueTabLabels(editors: IEditorInput[]): IEditorInputLabel[] { const labels: IEditorInputLabel[] = []; - const mapLabelToDuplicates = new LinkedMap(); - const mapLabelAndDescriptionToDuplicates = new LinkedMap(); + const mapLabelToDuplicates = new SimpleMap(); + const mapLabelAndDescriptionToDuplicates = new SimpleMap(); // Build labels and descriptions for each editor editors.forEach(editor => { diff --git a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts index 0bf51c9c1d7..7a7872472ce 100644 --- a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts +++ b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts @@ -36,7 +36,7 @@ import { Component } from 'vs/workbench/common/component'; import Event, { Emitter } from 'vs/base/common/event'; import { IPartService } from 'vs/workbench/services/part/common/partService'; import { KeyMod } from 'vs/base/common/keyCodes'; -import { QuickOpenHandler, QuickOpenHandlerDescriptor, IQuickOpenRegistry, Extensions, EditorQuickOpenEntry } from 'vs/workbench/browser/quickopen'; +import { QuickOpenHandler, QuickOpenHandlerDescriptor, IQuickOpenRegistry, Extensions, EditorQuickOpenEntry, IWorkbenchQuickOpenConfiguration } from 'vs/workbench/browser/quickopen'; import errors = require('vs/base/common/errors'); import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; import { IPickOpenEntry, IFilePickOpenEntry, IInputOptions, IQuickOpenService, IPickOptions, IShowOptions } from 'vs/platform/quickOpen/common/quickOpen'; @@ -55,14 +55,6 @@ import { IEnvironmentService } from 'vs/platform/environment/common/environment' const HELP_PREFIX = '?'; -interface IWorkbenchQuickOpenConfiguration { - workbench: { - quickOpen: { - closeOnFocusLost: boolean; - } - }; -} - interface IInternalPickOptions { value?: string; valueSelection?: [number, number]; @@ -140,7 +132,7 @@ export class QuickOpenController extends Component implements IQuickOpenService } private updateConfiguration(settings: IWorkbenchQuickOpenConfiguration): void { - this.closeOnFocusLost = settings.workbench.quickOpen.closeOnFocusLost; + this.closeOnFocusLost = settings.workbench && settings.workbench.quickOpen && settings.workbench.quickOpen.closeOnFocusLost; } public get onShow(): Event { @@ -520,6 +512,7 @@ export class QuickOpenController extends Component implements IQuickOpenService public show(prefix?: string, options?: IShowOptions): TPromise { let quickNavigateConfiguration = options ? options.quickNavigateConfiguration : void 0; + let inputSelection = options ? options.inputSelection : void 0; this.previousValue = prefix; @@ -570,7 +563,7 @@ export class QuickOpenController extends Component implements IQuickOpenService // Show quick open with prefix or editor history if (!this.quickOpenWidget.isVisible() || quickNavigateConfiguration) { if (prefix) { - this.quickOpenWidget.show(prefix, { quickNavigateConfiguration }); + this.quickOpenWidget.show(prefix, { quickNavigateConfiguration, inputSelection }); } else { const editorHistory = this.getEditorHistoryWithGroupLabel(); if (editorHistory.getEntries().length < 2) { @@ -585,13 +578,13 @@ export class QuickOpenController extends Component implements IQuickOpenService autoFocus = { autoFocusFirstEntry: visibleEditorCount === 0, autoFocusSecondEntry: visibleEditorCount !== 0 }; } - this.quickOpenWidget.show(editorHistory, { quickNavigateConfiguration, autoFocus }); + this.quickOpenWidget.show(editorHistory, { quickNavigateConfiguration, autoFocus, inputSelection }); } } // Otherwise reset the widget to the prefix that is passed in else { - this.quickOpenWidget.show(prefix || ''); + this.quickOpenWidget.show(prefix || '', { inputSelection }); } return promiseCompletedOnHide; @@ -887,7 +880,7 @@ export class QuickOpenController extends Component implements IQuickOpenService const placeHolderLabel = (typeof canRun === 'string') ? canRun : nls.localize('canNotRunPlaceholder', "This quick open handler can not be used in the current context"); const model = new QuickOpenModel([new PlaceholderQuickOpenEntry(placeHolderLabel)], this.actionProvider); - this.showModel(model, resolvedHandler.getAutoFocus(value, this.quickOpenWidget.getQuickNavigateConfiguration()), resolvedHandler.getAriaLabel()); + this.showModel(model, resolvedHandler.getAutoFocus(value, { model, quickNavigateConfiguration: this.quickOpenWidget.getQuickNavigateConfiguration() }), resolvedHandler.getAriaLabel()); return TPromise.as(null); } @@ -908,9 +901,9 @@ export class QuickOpenController extends Component implements IQuickOpenService if (this.currentResultToken === currentResultToken) { if (!result || !result.entries.length) { const model = new QuickOpenModel([new PlaceholderQuickOpenEntry(resolvedHandler.getEmptyLabel(value))]); - this.showModel(model, resolvedHandler.getAutoFocus(value, this.quickOpenWidget.getQuickNavigateConfiguration()), resolvedHandler.getAriaLabel()); + this.showModel(model, resolvedHandler.getAutoFocus(value, { model, quickNavigateConfiguration: this.quickOpenWidget.getQuickNavigateConfiguration() }), resolvedHandler.getAriaLabel()); } else { - this.showModel(result, resolvedHandler.getAutoFocus(value, this.quickOpenWidget.getQuickNavigateConfiguration()), resolvedHandler.getAriaLabel()); + this.showModel(result, resolvedHandler.getAutoFocus(value, { model: result, quickNavigateConfiguration: this.quickOpenWidget.getQuickNavigateConfiguration() }), resolvedHandler.getAriaLabel()); } } }); diff --git a/src/vs/workbench/browser/quickopen.ts b/src/vs/workbench/browser/quickopen.ts index ebb31e7a833..152265f629a 100644 --- a/src/vs/workbench/browser/quickopen.ts +++ b/src/vs/workbench/browser/quickopen.ts @@ -7,7 +7,6 @@ import nls = require('vs/nls'); import { TPromise } from 'vs/base/common/winjs.base'; import * as objects from 'vs/base/common/objects'; -import filters = require('vs/base/common/filters'); import arrays = require('vs/base/common/arrays'); import strings = require('vs/base/common/strings'); import types = require('vs/base/common/types'); @@ -16,13 +15,25 @@ import { Registry } from 'vs/platform/platform'; import { Action } from 'vs/base/common/actions'; import { KeyMod } from 'vs/base/common/keyCodes'; import { Mode, IEntryRunContext, IAutoFocus, IModel, IQuickNavigateConfiguration } from 'vs/base/parts/quickopen/common/quickOpen'; -import { QuickOpenEntry, IHighlight, QuickOpenEntryGroup, QuickOpenModel } from 'vs/base/parts/quickopen/browser/quickOpenModel'; +import { QuickOpenEntry, IHighlight, QuickOpenEntryGroup } from 'vs/base/parts/quickopen/browser/quickOpenModel'; import { EditorOptions, EditorInput } from 'vs/workbench/common/editor'; import { IResourceInput, IEditorInput, IEditorOptions } from 'vs/platform/editor/common/editor'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; import { IQuickOpenService } from 'vs/platform/quickOpen/common/quickOpen'; import { AsyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; +export interface IWorkbenchQuickOpenConfiguration { + workbench: { + quickOpen: { + closeOnFocusLost: boolean; + }, + commandPalette: { + history: number; + preserveInput: boolean; + } + }; +} + export class QuickOpenHandler { /** @@ -71,7 +82,7 @@ export class QuickOpenHandler { * Indicates if the handler wishes the quick open widget to automatically select the first result entry or an entry * based on a specific prefix match. */ - public getAutoFocus(searchValue: string, quickNavigateConfiguration?: IQuickNavigateConfiguration): IAutoFocus { + public getAutoFocus(searchValue: string, context: { model: IModel, quickNavigateConfiguration?: IQuickNavigateConfiguration }): IAutoFocus { return {}; } @@ -341,88 +352,16 @@ export interface ICommandQuickOpenHandlerOptions { defaultCommand?: ICommand; } -export abstract class CommandQuickOpenHandler extends QuickOpenHandler { - +export class QuickOpenAction extends Action { private prefix: string; - private defaultCommand: ICommand; - private commands: { regexp: RegExp; command: ICommand; }[]; constructor( - @IQuickOpenService private quickOpenService: IQuickOpenService, - options: ICommandQuickOpenHandlerOptions + id: string, + label: string, + prefix: string, + @IQuickOpenService private quickOpenService: IQuickOpenService ) { - super(); - - this.prefix = options.prefix; - this.commands = options.commands.map(c => ({ - regexp: new RegExp('^(' + c.aliases.join('|') + ')\\b\\W+'), - command: c - })); - this.defaultCommand = options.defaultCommand || null; - } - - public getResults(input: string): TPromise { - let match: RegExpMatchArray; - let command = arrays.first(this.commands, c => !!(match = input.match(c.regexp))); - let promise: TPromise; - - if (command) { - promise = command.command.getResults(input.substr(match[0].length)); - } else if (this.defaultCommand) { - promise = this.defaultCommand.getResults(input); - } else { - promise = this.getCommands(input); - } - - return promise.then(e => new QuickOpenModel(e)); - } - - private getCommands(input: string): TPromise { - let entries: QuickOpenEntry[] = this.commands - .map(c => ({ command: c.command, highlights: filters.matchesFuzzy(input, c.command.aliases[0]) })) - .filter(({ command, highlights }) => !!highlights || command.aliases.some(a => input === a)) - .map(({ command, highlights }) => new CommandEntry(this.quickOpenService, this.prefix, command, highlights)); - - return TPromise.as(entries); - } - - public getClass(): string { - return null; - } - - public canRun(): boolean { - return true; - } - - public getAutoFocus(input: string): IAutoFocus { - return { autoFocusFirstEntry: true }; - } - - public onClose(canceled: boolean): void { - return; - } - - public getGroupLabel(): string { - return null; - } - - public getEmptyLabel(input: string): string { - let match: RegExpMatchArray; - let command = arrays.first(this.commands, c => !!(match = input.match(c.regexp))); - - if (!command) { - return nls.localize('noCommands', "No commands matching"); - } - - return command.command.getEmptyLabel(input); - } -} - -export class QuickOpenAction extends Action { - private prefix: string; - - constructor(actionId: string, actionLabel: string, prefix: string, @IQuickOpenService private quickOpenService: IQuickOpenService) { - super(actionId, actionLabel); + super(id, label); this.prefix = prefix; this.enabled = !!this.quickOpenService; diff --git a/src/vs/workbench/electron-browser/main.contribution.ts b/src/vs/workbench/electron-browser/main.contribution.ts index 87feaac6d44..e34a426f1ef 100644 --- a/src/vs/workbench/electron-browser/main.contribution.ts +++ b/src/vs/workbench/electron-browser/main.contribution.ts @@ -123,6 +123,16 @@ let workbenchProperties: { [path: string]: IJSONSchema; } = { 'description': nls.localize('revealIfOpen', "Controls if an editor is revealed in any of the visible groups if opened. If disabled, an editor will prefer to open in the currently active editor group. If enabled, an already opened editor will be revealed instead of opened again in the currently active editor group. Note that there are some cases where this setting is ignored, e.g. when forcing an editor to open in a specific group or to the side of the currently active group."), 'default': false }, + 'workbench.commandPalette.history': { + 'type': 'number', + 'description': nls.localize('commandHistory', "Controls if the number of recently used commands to keep in history for the command palette. Set to 0 to disable command history."), + 'default': 50 + }, + 'workbench.commandPalette.preserveInput': { + 'type': 'boolean', + 'description': nls.localize('preserveInput', "Controls if the last typed input to the command palette should be restored when opening it the next time."), + 'default': false + }, 'workbench.quickOpen.closeOnFocusLost': { 'type': 'boolean', 'description': nls.localize('closeOnFocusLost', "Controls if Quick Open should close automatically once it loses focus."), diff --git a/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.ts b/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.ts index 9f4f45594c4..395829a94f0 100644 --- a/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.ts +++ b/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.ts @@ -11,7 +11,7 @@ import * as semver from 'semver'; import * as path from 'path'; import Event, { Emitter, chain } from 'vs/base/common/event'; import { index } from 'vs/base/common/arrays'; -import { LinkedMap as Map } from 'vs/base/common/map'; +import { SimpleMap as Map } from 'vs/base/common/map'; import { assign } from 'vs/base/common/objects'; import { ThrottledDelayer } from 'vs/base/common/async'; import { isPromiseCanceledError } from 'vs/base/common/errors'; diff --git a/src/vs/workbench/parts/markers/common/markersModel.ts b/src/vs/workbench/parts/markers/common/markersModel.ts index e87e6f7906a..f91644a0943 100644 --- a/src/vs/workbench/parts/markers/common/markersModel.ts +++ b/src/vs/workbench/parts/markers/common/markersModel.ts @@ -125,14 +125,14 @@ export class FilterOptions { export class MarkersModel { - private markersByResource: Map.LinkedMap; + private markersByResource: Map.SimpleMap; private _filteredResources: Resource[]; private _nonFilteredResources: Resource[]; private _filterOptions: FilterOptions; constructor(markers: IMarker[] = []) { - this.markersByResource = new Map.LinkedMap(); + this.markersByResource = new Map.SimpleMap(); this._filterOptions = new FilterOptions(); this.update(markers); } diff --git a/src/vs/workbench/parts/preferences/browser/preferencesService.ts b/src/vs/workbench/parts/preferences/browser/preferencesService.ts index 6f2fd27c01f..fa9247c670e 100644 --- a/src/vs/workbench/parts/preferences/browser/preferencesService.ts +++ b/src/vs/workbench/parts/preferences/browser/preferencesService.ts @@ -8,7 +8,7 @@ import * as network from 'vs/base/common/network'; import { TPromise } from 'vs/base/common/winjs.base'; import * as nls from 'vs/nls'; import URI from 'vs/base/common/uri'; -import { LinkedMap as Map } from 'vs/base/common/map'; +import { SimpleMap as Map } from 'vs/base/common/map'; import * as labels from 'vs/base/common/labels'; import * as strings from 'vs/base/common/strings'; import { Disposable } from 'vs/base/common/lifecycle'; diff --git a/src/vs/workbench/parts/preferences/common/preferences.ts b/src/vs/workbench/parts/preferences/common/preferences.ts index 5465f7241d5..11206bc23a8 100644 --- a/src/vs/workbench/parts/preferences/common/preferences.ts +++ b/src/vs/workbench/parts/preferences/common/preferences.ts @@ -5,7 +5,7 @@ import URI from 'vs/base/common/uri'; import { TPromise } from 'vs/base/common/winjs.base'; -import { LinkedMap as Map } from 'vs/base/common/map'; +import { SimpleMap as Map } from 'vs/base/common/map'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; import { RawContextKey } from 'vs/platform/contextkey/common/contextkey'; import { IEditor } from 'vs/platform/editor/common/editor'; diff --git a/src/vs/workbench/parts/preferences/common/preferencesModels.ts b/src/vs/workbench/parts/preferences/common/preferencesModels.ts index 26a19561444..c35903695e2 100644 --- a/src/vs/workbench/parts/preferences/common/preferencesModels.ts +++ b/src/vs/workbench/parts/preferences/common/preferencesModels.ts @@ -6,7 +6,7 @@ import * as nls from 'vs/nls'; import * as strings from 'vs/base/common/strings'; import { assign } from 'vs/base/common/objects'; -import { LinkedMap as Map } from 'vs/base/common/map'; +import { SimpleMap as Map } from 'vs/base/common/map'; import { distinct } from 'vs/base/common/arrays'; import URI from 'vs/base/common/uri'; import { IReference } from 'vs/base/common/lifecycle'; diff --git a/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts b/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts index 260ab6e1a64..cf9fd534f85 100644 --- a/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts +++ b/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts @@ -5,21 +5,20 @@ 'use strict'; -import 'vs/css!./media/commandsHandler'; import { TPromise } from 'vs/base/common/winjs.base'; import nls = require('vs/nls'); import arrays = require('vs/base/common/arrays'); import types = require('vs/base/common/types'); import { language, LANGUAGE_DEFAULT } from 'vs/base/common/platform'; -import { IAction, Action } from 'vs/base/common/actions'; +import { Action } from 'vs/base/common/actions'; import { toErrorMessage } from 'vs/base/common/errorMessage'; -import { Mode, IEntryRunContext, IAutoFocus } from 'vs/base/parts/quickopen/common/quickOpen'; -import { QuickOpenEntryGroup, IHighlight, QuickOpenModel } from 'vs/base/parts/quickopen/browser/quickOpenModel'; +import { Mode, IEntryRunContext, IAutoFocus, IModel, IQuickNavigateConfiguration } from 'vs/base/parts/quickopen/common/quickOpen'; +import { QuickOpenEntryGroup, IHighlight, QuickOpenModel, QuickOpenEntry } from 'vs/base/parts/quickopen/browser/quickOpenModel'; import { SyncActionDescriptor, IMenuService, MenuId, MenuItemAction } from 'vs/platform/actions/common/actions'; import { IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/workbench/common/actionRegistry'; import { Registry } from 'vs/platform/platform'; -import { QuickOpenHandler, QuickOpenAction } from 'vs/workbench/browser/quickopen'; +import { QuickOpenHandler, IWorkbenchQuickOpenConfiguration } from 'vs/workbench/browser/quickopen'; import { IEditorAction, IEditor, isCommonCodeEditor, ICommonCodeEditor } from 'vs/editor/common/editorCommon'; import { matchesWords, matchesPrefix, matchesContiguousSubString, or } from 'vs/base/common/filters'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; @@ -29,19 +28,149 @@ import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { IQuickOpenService } from 'vs/platform/quickOpen/common/quickOpen'; import { editorAction, EditorAction } from 'vs/editor/common/editorCommonExtensions'; +import { IStorageService } from "vs/platform/storage/common/storage"; +import { ILifecycleService } from "vs/platform/lifecycle/common/lifecycle"; +import { once } from "vs/base/common/event"; +import { BoundedMap, ISerializedBoundedLinkedMap } from "vs/base/common/map"; +import { IConfigurationService } from "vs/platform/configuration/common/configuration"; +import { ResolvedKeybinding } from "vs/base/common/keyCodes"; export const ALL_COMMANDS_PREFIX = '>'; -export const EDITOR_COMMANDS_PREFIX = '$'; -const wordFilter = or(matchesPrefix, matchesWords, matchesContiguousSubString); +let lastCommandPaletteInput: string; +let commandHistory: BoundedMap; +let commandCounter = 1; + +function resolveCommandHistory(configurationService: IConfigurationService): number { + const config = configurationService.getConfiguration(); + + let commandHistory = config.workbench && config.workbench.commandPalette && config.workbench.commandPalette.history; + if (typeof commandHistory !== 'number') { + commandHistory = CommandsHistory.DEFAULT_COMMANDS_HISTORY_LENGTH; + } + + return commandHistory; +} + +class CommandsHistory { + + public static readonly DEFAULT_COMMANDS_HISTORY_LENGTH = 50; + + private static readonly PREF_KEY_CACHE = 'commandPalette.mru.cache'; + private static readonly PREF_KEY_COUNTER = 'commandPalette.mru.counter'; + + private commandHistoryLength: number; + + constructor( + @IStorageService private storageService: IStorageService, + @ILifecycleService private lifecycleService: ILifecycleService, + @IConfigurationService private configurationService: IConfigurationService + ) { + this.updateConfiguration(); + this.load(); + + this.registerListeners(); + } + + private updateConfiguration(): void { + this.commandHistoryLength = resolveCommandHistory(this.configurationService); + + if (commandHistory) { + commandHistory.setLimit(this.commandHistoryLength); + } + } + + private load(): void { + const raw = this.storageService.get(CommandsHistory.PREF_KEY_CACHE); + let deserializedCache: ISerializedBoundedLinkedMap; + if (raw) { + try { + deserializedCache = JSON.parse(raw); + } catch (error) { + // invalid data + } + } + + commandHistory = new BoundedMap(this.commandHistoryLength, 1, deserializedCache); + commandCounter = this.storageService.getInteger(CommandsHistory.PREF_KEY_COUNTER, void 0, commandCounter); + } + + private registerListeners(): void { + this.configurationService.onDidUpdateConfiguration(e => this.updateConfiguration()); + once(this.lifecycleService.onShutdown)(reason => this.save()); + } + + private save(): void { + this.storageService.store(CommandsHistory.PREF_KEY_CACHE, JSON.stringify(commandHistory.serialize())); + this.storageService.store(CommandsHistory.PREF_KEY_COUNTER, commandCounter); + } + + public push(commandId: string): void { -export class ShowAllCommandsAction extends QuickOpenAction { + // make MRU by deleting it first + commandHistory.delete(commandId); + + // set counter to command + commandHistory.set(commandId, commandCounter++); + } + + public get(commandId: string): number { + return commandHistory.get(commandId); + } +} + +export class ShowAllCommandsAction extends Action { public static ID = 'workbench.action.showCommands'; public static LABEL = nls.localize('showTriggerActions', "Show All Commands"); - constructor(actionId: string, actionLabel: string, @IQuickOpenService quickOpenService: IQuickOpenService) { - super(actionId, actionLabel, ALL_COMMANDS_PREFIX, quickOpenService); + constructor( + id: string, + label: string, + @IQuickOpenService private quickOpenService: IQuickOpenService, + @IConfigurationService private configurationService: IConfigurationService + ) { + super(id, label); + } + + public run(context?: any): TPromise { + const config = this.configurationService.getConfiguration(); + const restoreInput = config.workbench && config.workbench.commandPalette && config.workbench.commandPalette.preserveInput === true; + + // Show with last command palette input if any and configured + let value = ALL_COMMANDS_PREFIX; + if (restoreInput && lastCommandPaletteInput) { + value = `${value}${lastCommandPaletteInput}`; + } + + this.quickOpenService.show(value, { inputSelection: lastCommandPaletteInput ? { start: 1 /* after prefix */, end: value.length } : void 0 }); + + return TPromise.as(null); + } +} + +export class ClearCommandHistoryAction extends Action { + + public static ID = 'workbench.action.clearCommandHistory'; + public static LABEL = nls.localize('clearCommandHistory', "Clear Command History"); + + constructor( + id: string, + label: string, + @IStorageService private storageService: IStorageService, + @IConfigurationService private configurationService: IConfigurationService + ) { + super(id, label); + } + + public run(context?: any): TPromise { + const commandHistoryLength = resolveCommandHistory(this.configurationService); + if (commandHistoryLength > 0) { + commandHistory = new BoundedMap(commandHistoryLength); + commandCounter = 1; + } + + return TPromise.as(null); } } @@ -69,39 +198,34 @@ class CommandPaletteEditorAction extends EditorAction { } } -class BaseCommandEntry extends QuickOpenEntryGroup { - private commandId: string; - private keyLabel: string; - private keyAriaLabel: string; - private label: string; +abstract class BaseCommandEntry extends QuickOpenEntryGroup { private description: string; private alias: string; + private labelLowercase: string; + private keybindingAriaLabel: string; constructor( - commandId: string, - keyLabel: string, - keyAriaLabel: string, - label: string, + private commandId: string, + private keybinding: ResolvedKeybinding, + private label: string, alias: string, - labelHighlights: IHighlight[], - aliasHighlights: IHighlight[], + highlights: { label: IHighlight[], alias: IHighlight[] }, + private onBeforeRun: (commandId: string) => void, @IMessageService protected messageService: IMessageService, @ITelemetryService protected telemetryService: ITelemetryService ) { super(); - this.commandId = commandId; - this.keyLabel = keyLabel; - this.keyAriaLabel = keyAriaLabel; - this.label = label; + this.labelLowercase = this.label.toLowerCase(); + this.keybindingAriaLabel = keybinding ? keybinding.getAriaLabel() : void 0; - if (label !== alias) { + if (this.label !== alias) { this.alias = alias; } else { - aliasHighlights = null; + highlights.alias = null; } - this.setHighlights(labelHighlights, null, aliasHighlights); + this.setHighlights(highlights.label, null, highlights.alias); } public getCommandId(): string { @@ -112,6 +236,10 @@ class BaseCommandEntry extends QuickOpenEntryGroup { return this.label; } + public getSortLabel(): string { + return this.labelLowercase; + } + public getDescription(): string { return this.description; } @@ -120,22 +248,22 @@ class BaseCommandEntry extends QuickOpenEntryGroup { this.description = description; } + public getKeybinding(): ResolvedKeybinding { + return this.keybinding; + } + public getDetail(): string { return this.alias; } public getAriaLabel(): string { - if (this.keyAriaLabel) { - return nls.localize('entryAriaLabelWithKey', "{0}, {1}, commands", this.getLabel(), this.keyAriaLabel); + if (this.keybindingAriaLabel) { + return nls.localize('entryAriaLabelWithKey', "{0}, {1}, commands", this.getLabel(), this.keybindingAriaLabel); } return nls.localize('entryAriaLabel', "{0}, commands", this.getLabel()); } - public getGroupLabel(): string { - return this.keyLabel; - } - protected onError(error?: Error): void; protected onError(messagesWithAction?: IMessageWithAction): void; protected onError(arg1?: any): void { @@ -147,15 +275,32 @@ class BaseCommandEntry extends QuickOpenEntryGroup { } } - protected runAction(action: IAction): void { + public run(mode: Mode, context: IEntryRunContext): boolean { + if (mode === Mode.OPEN) { + this.runAction(this.getAction()); + + return true; + } + + return false; + } + + protected abstract getAction(): Action | IEditorAction; + + protected runAction(action: Action | IEditorAction): void { + + // Indicate onBeforeRun + this.onBeforeRun(this.commandId); // Use a timeout to give the quick open widget a chance to close itself first TPromise.timeout(50).done(() => { - if (action && action.enabled) { + if (action && (!(action instanceof Action) || action.enabled)) { try { this.telemetryService.publicLog('workbenchActionExecuted', { id: action.id, from: 'quick open' }); (action.run() || TPromise.as(null)).done(() => { - action.dispose(); + if (action instanceof Action) { + action.dispose(); + } }, err => this.onError(err)); } catch (error) { this.onError(error); @@ -168,138 +313,103 @@ class BaseCommandEntry extends QuickOpenEntryGroup { } class CommandEntry extends BaseCommandEntry { - private actionDescriptor: SyncActionDescriptor; constructor( commandId: string, - keyLabel: string, - keyAriaLabel: string, + keybinding: ResolvedKeybinding, label: string, meta: string, - labelHighlights: IHighlight[], - aliasHighlights: IHighlight[], - actionDescriptor: SyncActionDescriptor, + highlights: { label: IHighlight[], alias: IHighlight[] }, + private actionDescriptor: SyncActionDescriptor, + onBeforeRun: (commandId: string) => void, @IInstantiationService private instantiationService: IInstantiationService, @IMessageService messageService: IMessageService, @ITelemetryService telemetryService: ITelemetryService ) { - super(commandId, keyLabel, keyAriaLabel, label, meta, labelHighlights, aliasHighlights, messageService, telemetryService); - - this.actionDescriptor = actionDescriptor; + super(commandId, keybinding, label, meta, highlights, onBeforeRun, messageService, telemetryService); } - public run(mode: Mode, context: IEntryRunContext): boolean { - if (mode === Mode.OPEN) { - const action = this.instantiationService.createInstance(this.actionDescriptor.syncDescriptor); - this.runAction(action); - - return true; - } - - return false; + protected getAction(): Action | IEditorAction { + return this.instantiationService.createInstance(this.actionDescriptor.syncDescriptor); } } class EditorActionCommandEntry extends BaseCommandEntry { - private action: IEditorAction; constructor( commandId: string, - keyLabel: string, - keyAriaLabel: string, + keybinding: ResolvedKeybinding, label: string, meta: string, - labelHighlights: IHighlight[], - aliasHighlights: IHighlight[], - action: IEditorAction, + highlights: { label: IHighlight[], alias: IHighlight[] }, + private action: IEditorAction, + onBeforeRun: (commandId: string) => void, @IMessageService messageService: IMessageService, @ITelemetryService telemetryService: ITelemetryService ) { - super(commandId, keyLabel, keyAriaLabel, label, meta, labelHighlights, aliasHighlights, messageService, telemetryService); - - this.action = action; + super(commandId, keybinding, label, meta, highlights, onBeforeRun, messageService, telemetryService); } - public run(mode: Mode, context: IEntryRunContext): boolean { - if (mode === Mode.OPEN) { - // Use a timeout to give the quick open widget a chance to close itself first - TPromise.timeout(50).done(() => { - if (this.action) { - try { - this.telemetryService.publicLog('workbenchActionExecuted', { id: this.action.id, from: 'quick open' }); - (this.action.run() || TPromise.as(null)).done(null, err => this.onError(err)); - } catch (error) { - this.onError(error); - } - } else { - this.messageService.show(Severity.Info, nls.localize('actionNotEnabled', "Command '{0}' is not enabled in the current context.", this.getLabel())); - } - }, err => this.onError(err)); - - return true; - } - - return false; + protected getAction(): Action | IEditorAction { + return this.action; } } - class ActionCommandEntry extends BaseCommandEntry { - private action: IAction; constructor( commandId: string, - keyLabel: string, - keyAriaLabel: string, + keybinding: ResolvedKeybinding, label: string, alias: string, - labelHighlights: IHighlight[], - aliasHighlights: IHighlight[], - action: IAction, + highlights: { label: IHighlight[], alias: IHighlight[] }, + private action: Action, + onBeforeRun: (commandId: string) => void, @IMessageService messageService: IMessageService, @ITelemetryService telemetryService: ITelemetryService ) { - super(commandId, keyLabel, keyAriaLabel, label, alias, labelHighlights, aliasHighlights, messageService, telemetryService); - - this.action = action; + super(commandId, keybinding, label, alias, highlights, onBeforeRun, messageService, telemetryService); } - public run(mode: Mode, context: IEntryRunContext): boolean { - if (mode === Mode.OPEN) { - this.runAction(this.action); - - return true; - } - - return false; + protected getAction(): Action | IEditorAction { + return this.action; } } +const wordFilter = or(matchesPrefix, matchesWords, matchesContiguousSubString); + export class CommandsHandler extends QuickOpenHandler { + private lastSearchValue: string; + private commandHistoryEnabled: boolean; + private commandsHistory: CommandsHistory; constructor( @IWorkbenchEditorService private editorService: IWorkbenchEditorService, @IInstantiationService private instantiationService: IInstantiationService, @IKeybindingService private keybindingService: IKeybindingService, @IMenuService private menuService: IMenuService, - @IContextKeyService private contextKeyService: IContextKeyService + @IContextKeyService private contextKeyService: IContextKeyService, + @IConfigurationService private configurationService: IConfigurationService ) { super(); + + this.commandsHistory = this.instantiationService.createInstance(CommandsHistory); + + this.configurationService.onDidUpdateConfiguration(e => this.updateConfiguration()); + this.updateConfiguration(); } - protected includeWorkbenchCommands(): boolean { - return true; + private updateConfiguration(): void { + this.commandHistoryEnabled = resolveCommandHistory(this.configurationService) > 0; } public getResults(searchValue: string): TPromise { - searchValue = searchValue.trim(); + this.lastSearchValue = searchValue.trim(); - // Workbench Actions (if prefix asks for all commands) + // Workbench Actions let workbenchEntries: CommandEntry[] = []; - if (this.includeWorkbenchCommands()) { - const workbenchActions = Registry.as(ActionExtensions.WorkbenchActions).getWorkbenchActions(); - workbenchEntries = this.actionDescriptorsToEntries(workbenchActions, searchValue); - } + const workbenchActions = Registry.as(ActionExtensions.WorkbenchActions).getWorkbenchActions(); + workbenchEntries = this.actionDescriptorsToEntries(workbenchActions, searchValue); // Editor Actions const activeEditor = this.editorService.getActiveEditor(); @@ -340,8 +450,41 @@ export class CommandsHandler extends QuickOpenHandler { } }); - // Sort by name - entries = entries.sort((elementA, elementB) => elementA.getLabel().toLowerCase().localeCompare(elementB.getLabel().toLowerCase())); + // Sort by MRU order and fallback to name otherwie + entries = entries.sort((elementA, elementB) => { + const counterA = this.commandsHistory.get(elementA.getCommandId()); + const counterB = this.commandsHistory.get(elementB.getCommandId()); + + if (counterA && counterB) { + return counterA > counterB ? -1 : 1; // use more recently used command before older + } + + if (counterA) { + return -1; // first command was used, so it wins over the non used one + } + + if (counterB) { + return 1; // other command was used so it wins over the command + } + + // both commands were never used, so we sort by name + return elementA.getSortLabel().localeCompare(elementB.getSortLabel()); + }); + + // Introduce group marker border between recently used and others + // only if we have recently used commands in the result set + const firstEntry = entries[0]; + if (firstEntry && this.commandsHistory.get(firstEntry.getCommandId())) { + firstEntry.setGroupLabel(nls.localize('recentlyUsed', "recently used")); + for (let i = 1; i < entries.length; i++) { + const entry = entries[i]; + if (!this.commandsHistory.get(entry.getCommandId())) { + entry.setShowBorder(true); + entry.setGroupLabel(nls.localize('morecCommands', "other commands")); + break; + } + } + } return TPromise.as(new QuickOpenModel(entries)); } @@ -352,10 +495,6 @@ export class CommandsHandler extends QuickOpenHandler { for (let i = 0; i < actionDescriptors.length; i++) { const actionDescriptor = actionDescriptors[i]; - const keybinding = this.keybindingService.lookupKeybinding(actionDescriptor.id); - const keyLabel = keybinding ? keybinding.getLabel() : ''; - const keyAriaLabel = keybinding ? keybinding.getAriaLabel() : ''; - if (actionDescriptor.label) { // Label (with optional category) @@ -369,8 +508,9 @@ export class CommandsHandler extends QuickOpenHandler { const alias = (language !== LANGUAGE_DEFAULT) ? registry.getAlias(actionDescriptor.id) : null; const labelHighlights = wordFilter(searchValue, label); const aliasHighlights = alias ? wordFilter(searchValue, alias) : null; + if (labelHighlights || aliasHighlights) { - entries.push(this.instantiationService.createInstance(CommandEntry, actionDescriptor.id, keyLabel, keyAriaLabel, label, alias, labelHighlights, aliasHighlights, actionDescriptor)); + entries.push(this.instantiationService.createInstance(CommandEntry, actionDescriptor.id, this.keybindingService.lookupKeybinding(actionDescriptor.id), label, alias, { label: labelHighlights, alias: aliasHighlights }, actionDescriptor, id => this.onBeforeRunCommand(id))); } } } @@ -387,19 +527,16 @@ export class CommandsHandler extends QuickOpenHandler { continue; // avoid duplicates } - const keybinding = this.keybindingService.lookupKeybinding(action.id); - const keyLabel = keybinding ? keybinding.getLabel() : ''; - const keyAriaLabel = keybinding ? keybinding.getAriaLabel() : ''; const label = action.label; - if (label) { // Alias for non default languages const alias = (language !== LANGUAGE_DEFAULT) ? action.alias : null; const labelHighlights = wordFilter(searchValue, label); const aliasHighlights = alias ? wordFilter(searchValue, alias) : null; + if (labelHighlights || aliasHighlights) { - entries.push(this.instantiationService.createInstance(EditorActionCommandEntry, action.id, keyLabel, keyAriaLabel, label, alias, labelHighlights, aliasHighlights, action)); + entries.push(this.instantiationService.createInstance(EditorActionCommandEntry, action.id, this.keybindingService.lookupKeybinding(action.id), label, alias, { label: labelHighlights, alias: aliasHighlights }, action, id => this.onBeforeRunCommand(id))); } } } @@ -407,6 +544,15 @@ export class CommandsHandler extends QuickOpenHandler { return entries; } + private onBeforeRunCommand(commandId: string): void { + + // Remember as last command palette input + lastCommandPaletteInput = this.lastSearchValue; + + // Remember in commands history + this.commandsHistory.push(commandId); + } + private menuItemActionsToEntries(actions: MenuItemAction[], searchValue: string): ActionCommandEntry[] { const entries: ActionCommandEntry[] = []; @@ -420,9 +566,7 @@ export class CommandsHandler extends QuickOpenHandler { if (label) { const labelHighlights = wordFilter(searchValue, label); - const keybinding = this.keybindingService.lookupKeybinding(action.item.id); - const keyLabel = keybinding ? keybinding.getLabel() : ''; - const keyAriaLabel = keybinding ? keybinding.getAriaLabel() : ''; + // Add an 'alias' in original language when running in different locale const aliasTitle = (language !== LANGUAGE_DEFAULT && typeof action.item.title !== 'string') ? action.item.title.original : null; const aliasCategory = (language !== LANGUAGE_DEFAULT && category && typeof action.item.category !== 'string') ? action.item.category.original : null; @@ -433,8 +577,9 @@ export class CommandsHandler extends QuickOpenHandler { alias = aliasTitle; } const aliasHighlights = alias ? wordFilter(searchValue, alias) : null; + if (labelHighlights || aliasHighlights) { - entries.push(this.instantiationService.createInstance(ActionCommandEntry, action.id, keyLabel, keyAriaLabel, label, alias, labelHighlights, aliasHighlights, action)); + entries.push(this.instantiationService.createInstance(ActionCommandEntry, action.id, this.keybindingService.lookupKeybinding(action.item.id), label, alias, { label: labelHighlights, alias: aliasHighlights }, action, id => this.onBeforeRunCommand(id))); } } } @@ -442,25 +587,23 @@ export class CommandsHandler extends QuickOpenHandler { return entries; } - public getAutoFocus(searchValue: string): IAutoFocus { + public getAutoFocus(searchValue: string, context: { model: IModel, quickNavigateConfiguration?: IQuickNavigateConfiguration }): IAutoFocus { + let autoFocusPrefixMatch = searchValue.trim(); + + if (autoFocusPrefixMatch && this.commandHistoryEnabled) { + const firstEntry = context.model && context.model.entries[0]; + if (firstEntry instanceof BaseCommandEntry && this.commandsHistory.get(firstEntry.getCommandId())) { + autoFocusPrefixMatch = void 0; // keep focus on MRU element if we have history elements + } + } + return { autoFocusFirstEntry: true, - autoFocusPrefixMatch: searchValue.trim() + autoFocusPrefixMatch }; } - public getClass(): string { - return 'commands-handler'; - } - public getEmptyLabel(searchString: string): string { return nls.localize('noCommandsMatching', "No commands matching"); } -} - -export class EditorCommandsHandler extends CommandsHandler { - - protected includeWorkbenchCommands(): boolean { - return false; - } } \ No newline at end of file diff --git a/src/vs/workbench/parts/quickopen/browser/media/commandsHandler.css b/src/vs/workbench/parts/quickopen/browser/media/commandsHandler.css deleted file mode 100644 index 9d1bfd29f02..00000000000 --- a/src/vs/workbench/parts/quickopen/browser/media/commandsHandler.css +++ /dev/null @@ -1,14 +0,0 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ - -.quick-open-widget.commands-handler .quick-open-tree .results-group { - opacity: 1; - font-size: 12px; - color: inherit; -} - -.vs-dark .quick-open-widget.commands-handler .quick-open-tree .results-group { - color: inherit; -} \ No newline at end of file diff --git a/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts b/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts index e659f567dd4..606e882af9b 100644 --- a/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts +++ b/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts @@ -13,13 +13,14 @@ import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/workbench/common/actionRegistry'; import { KeyMod, KeyCode } from 'vs/base/common/keyCodes'; import { GotoSymbolAction, GOTO_SYMBOL_PREFIX, SCOPE_PREFIX } from 'vs/workbench/parts/quickopen/browser/gotoSymbolHandler'; -import { ShowAllCommandsAction, ALL_COMMANDS_PREFIX } from 'vs/workbench/parts/quickopen/browser/commandsHandler'; +import { ShowAllCommandsAction, ALL_COMMANDS_PREFIX, ClearCommandHistoryAction } from 'vs/workbench/parts/quickopen/browser/commandsHandler'; import { GotoLineAction, GOTO_LINE_PREFIX } from 'vs/workbench/parts/quickopen/browser/gotoLineHandler'; import { HELP_PREFIX } from 'vs/workbench/parts/quickopen/browser/helpHandler'; import { VIEW_PICKER_PREFIX, OpenViewPickerAction, QuickOpenViewPickerAction } from 'vs/workbench/parts/quickopen/browser/viewPickerHandler'; // Register Actions -let registry = Registry.as(ActionExtensions.WorkbenchActions); +const registry = Registry.as(ActionExtensions.WorkbenchActions); +registry.registerWorkbenchAction(new SyncActionDescriptor(ClearCommandHistoryAction, ClearCommandHistoryAction.ID, ClearCommandHistoryAction.LABEL), 'Clear Command History'); registry.registerWorkbenchAction(new SyncActionDescriptor(ShowAllCommandsAction, ShowAllCommandsAction.ID, ShowAllCommandsAction.LABEL, { primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_P, secondary: [KeyCode.F1] diff --git a/src/vs/workbench/parts/quickopen/browser/viewPickerHandler.ts b/src/vs/workbench/parts/quickopen/browser/viewPickerHandler.ts index 084ed409ccb..5cda2bf9d77 100644 --- a/src/vs/workbench/parts/quickopen/browser/viewPickerHandler.ts +++ b/src/vs/workbench/parts/quickopen/browser/viewPickerHandler.ts @@ -9,7 +9,7 @@ import nls = require('vs/nls'); import errors = require('vs/base/common/errors'); import strings = require('vs/base/common/strings'); import scorer = require('vs/base/common/scorer'); -import { Mode, IEntryRunContext, IAutoFocus, IQuickNavigateConfiguration } from 'vs/base/parts/quickopen/common/quickOpen'; +import { Mode, IEntryRunContext, IAutoFocus, IQuickNavigateConfiguration, IModel } from 'vs/base/parts/quickopen/common/quickOpen'; import { QuickOpenModel, QuickOpenEntryGroup, QuickOpenEntry } from 'vs/base/parts/quickopen/browser/quickOpenModel'; import { QuickOpenHandler, QuickOpenAction } from 'vs/workbench/browser/quickopen'; import { IViewletService } from 'vs/workbench/services/viewlet/browser/viewlet'; @@ -165,9 +165,9 @@ export class ViewPickerHandler extends QuickOpenHandler { return viewEntries; } - public getAutoFocus(searchValue: string, quickNavigateConfiguration: IQuickNavigateConfiguration): IAutoFocus { + public getAutoFocus(searchValue: string, context: { model: IModel, quickNavigateConfiguration?: IQuickNavigateConfiguration }): IAutoFocus { return { - autoFocusFirstEntry: !!searchValue || !!quickNavigateConfiguration + autoFocusFirstEntry: !!searchValue || !!context.quickNavigateConfiguration }; } } diff --git a/src/vs/workbench/parts/search/common/searchModel.ts b/src/vs/workbench/parts/search/common/searchModel.ts index 114d6657c1a..f8d357a5a26 100644 --- a/src/vs/workbench/parts/search/common/searchModel.ts +++ b/src/vs/workbench/parts/search/common/searchModel.ts @@ -11,7 +11,7 @@ import { RunOnceScheduler } from 'vs/base/common/async'; import { IDisposable, Disposable } from 'vs/base/common/lifecycle'; import { TPromise, PPromise } from 'vs/base/common/winjs.base'; import URI from 'vs/base/common/uri'; -import { LinkedMap } from 'vs/base/common/map'; +import { SimpleMap } from 'vs/base/common/map'; import { ArraySet } from 'vs/base/common/set'; import Event, { Emitter, fromPromise, stopwatch, any } from 'vs/base/common/event'; import { ISearchService, ISearchProgressItem, ISearchComplete, ISearchQuery, IPatternInfo, IFileMatch } from 'vs/platform/search/common/search'; @@ -126,7 +126,7 @@ export class FileMatch extends Disposable { private _resource: URI; private _model: IModel; private _modelListener: IDisposable; - private _matches: LinkedMap; + private _matches: SimpleMap; private _removedMatches: ArraySet; private _selectedMatch: Match; @@ -137,7 +137,7 @@ export class FileMatch extends Disposable { @IModelService private modelService: IModelService, @IReplaceService private replaceService: IReplaceService) { super(); this._resource = this.rawMatch.resource; - this._matches = new LinkedMap(); + this._matches = new SimpleMap(); this._removedMatches = new ArraySet(); this._updateScheduler = new RunOnceScheduler(this.updateMatchesForModel.bind(this), 250); @@ -198,7 +198,7 @@ export class FileMatch extends Disposable { if (!this._model) { return; } - this._matches = new LinkedMap(); + this._matches = new SimpleMap(); let matches = this._model .findMatches(this._query.pattern, this._model.getFullModelRange(), this._query.isRegExp, this._query.isCaseSensitive, this._query.isWordMatch ? this._query.wordSeparators : null, false, this._maxResults); @@ -340,8 +340,8 @@ export class SearchResult extends Disposable { private _onChange = this._register(new Emitter()); public onChange: Event = this._onChange.event; - private _fileMatches: LinkedMap; - private _unDisposedFileMatches: LinkedMap; + private _fileMatches: SimpleMap; + private _unDisposedFileMatches: SimpleMap; private _query: IPatternInfo = null; private _maxResults: number; private _showHighlights: boolean; @@ -352,8 +352,8 @@ export class SearchResult extends Disposable { constructor(private _searchModel: SearchModel, @IReplaceService private replaceService: IReplaceService, @ITelemetryService private telemetryService: ITelemetryService, @IInstantiationService private instantiationService: IInstantiationService) { super(); - this._fileMatches = new LinkedMap(); - this._unDisposedFileMatches = new LinkedMap(); + this._fileMatches = new SimpleMap(); + this._unDisposedFileMatches = new SimpleMap(); this._rangeHighlightDecorations = this.instantiationService.createInstance(RangeHighlightDecorations); } -- GitLab From 059f5e473c8e13481be63f2d5643d22f8195fe19 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 7 Jun 2017 15:49:55 +0200 Subject: [PATCH 0593/1347] add "quick open recent" to file menu --- src/vs/code/electron-main/menus.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index ca5849620fe..fe14d6cf223 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -538,6 +538,8 @@ export class VSCodeMenu { } if (folders.length || files.length) { + openRecentMenu.append(__separator__()); + openRecentMenu.append(this.createMenuItem(nls.localize({ key: 'miMore', comment: ['&& denotes a mnemonic'] }, "&&More..."), 'workbench.action.openRecent')); openRecentMenu.append(__separator__()); openRecentMenu.append(this.createMenuItem(nls.localize({ key: 'miClearRecentOpen', comment: ['&& denotes a mnemonic'] }, "&&Clear Recent Files"), 'workbench.action.clearRecentFiles')); } -- GitLab From f215700090187f1564e4e421cab381614b6f19be Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 7 Jun 2017 15:29:17 +0200 Subject: [PATCH 0594/1347] fix #28141 --- .../workbench/api/electron-browser/mainThreadQuickOpen.ts | 6 +++--- src/vs/workbench/api/node/extHost.protocol.ts | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/vs/workbench/api/electron-browser/mainThreadQuickOpen.ts b/src/vs/workbench/api/electron-browser/mainThreadQuickOpen.ts index 8751ff66638..6475757bb8d 100644 --- a/src/vs/workbench/api/electron-browser/mainThreadQuickOpen.ts +++ b/src/vs/workbench/api/electron-browser/mainThreadQuickOpen.ts @@ -29,7 +29,7 @@ export class MainThreadQuickOpen extends MainThreadQuickOpenShape { this._quickOpenService = quickOpenService; } - $show(options: IPickOptions): Thenable { + $show(options: IPickOptions): TPromise { const myToken = ++this._token; @@ -59,14 +59,14 @@ export class MainThreadQuickOpen extends MainThreadQuickOpenShape { }); } - $setItems(items: MyQuickPickItems[]): Thenable { + $setItems(items: MyQuickPickItems[]): TPromise { if (this._doSetItems) { this._doSetItems(items); } return undefined; } - $setError(error: Error): Thenable { + $setError(error: Error): TPromise { if (this._doSetError) { this._doSetError(error); } diff --git a/src/vs/workbench/api/node/extHost.protocol.ts b/src/vs/workbench/api/node/extHost.protocol.ts index 8f6d2c8deb5..6d92223c932 100644 --- a/src/vs/workbench/api/node/extHost.protocol.ts +++ b/src/vs/workbench/api/node/extHost.protocol.ts @@ -264,9 +264,9 @@ export interface MyQuickPickItems extends IPickOpenEntry { handle: number; } export abstract class MainThreadQuickOpenShape { - $show(options: IPickOptions): Thenable { throw ni(); } - $setItems(items: MyQuickPickItems[]): Thenable { throw ni(); } - $setError(error: Error): Thenable { throw ni(); } + $show(options: IPickOptions): TPromise { throw ni(); } + $setItems(items: MyQuickPickItems[]): TPromise { throw ni(); } + $setError(error: Error): TPromise { throw ni(); } $input(options: vscode.InputBoxOptions, validateInput: boolean): TPromise { throw ni(); } } -- GitLab From 3e7f7fe1b709e438197dd67b30220675cf98c7bd Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 7 Jun 2017 16:00:35 +0200 Subject: [PATCH 0595/1347] fix tests --- src/vs/workbench/electron-browser/workbench.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/electron-browser/workbench.ts b/src/vs/workbench/electron-browser/workbench.ts index 93e8408e070..ca0524e3014 100644 --- a/src/vs/workbench/electron-browser/workbench.ts +++ b/src/vs/workbench/electron-browser/workbench.ts @@ -570,7 +570,7 @@ export class Workbench implements IPartService { // Panel part visibility const panelRegistry = Registry.as(PanelExtensions.Panels); - this.panelHidden = this.storageService.getBoolean(Workbench.panelHiddenSettingKey, StorageScope.WORKSPACE, !this.contextService.hasWorkspace()); + this.panelHidden = this.storageService.getBoolean(Workbench.panelHiddenSettingKey, StorageScope.WORKSPACE, true); if (!panelRegistry.getDefaultPanelId()) { this.panelHidden = true; // we hide panel part if there is no default panel } -- GitLab From 85a0a67ce54509374bf06693d93b87867bb24885 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 7 Jun 2017 16:12:56 +0200 Subject: [PATCH 0596/1347] fix integration tests --- .../vscode-api-tests/src/editor.test.ts | 6 ++-- extensions/vscode-api-tests/src/utils.ts | 29 ++----------------- .../vscode-api-tests/src/window.test.ts | 12 ++++---- .../vscode-api-tests/src/workspace.test.ts | 4 +-- 4 files changed, 13 insertions(+), 38 deletions(-) diff --git a/extensions/vscode-api-tests/src/editor.test.ts b/extensions/vscode-api-tests/src/editor.test.ts index f39a736a967..a5d597b4bc0 100644 --- a/extensions/vscode-api-tests/src/editor.test.ts +++ b/extensions/vscode-api-tests/src/editor.test.ts @@ -7,11 +7,11 @@ import * as assert from 'assert'; import { workspace, window, Position, Range, commands, TextEditor, TextDocument, TextEditorCursorStyle, TextEditorLineNumbersStyle, SnippetString, Selection } from 'vscode'; -import { createRandomFile, deleteFile, cleanUp } from './utils'; +import { createRandomFile, deleteFile, closeAllEditors } from './utils'; suite('editor tests', () => { - teardown(cleanUp); + teardown(closeAllEditors); function withRandomFileEditor(initialContents: string, run: (editor: TextEditor, doc: TextDocument) => Thenable): Thenable { return createRandomFile(initialContents).then(file => { @@ -194,7 +194,7 @@ suite('editor tests', () => { (err) => { assert.ok(true, 'edit with overlapping ranges should fail'); } - ); + ); }); }); }); diff --git a/extensions/vscode-api-tests/src/utils.ts b/extensions/vscode-api-tests/src/utils.ts index d22baa8d55a..0d869ed787d 100644 --- a/extensions/vscode-api-tests/src/utils.ts +++ b/extensions/vscode-api-tests/src/utils.ts @@ -5,7 +5,6 @@ 'use strict'; -import * as assert from 'assert'; import * as vscode from 'vscode'; import * as fs from 'fs'; import * as os from 'os'; @@ -49,31 +48,7 @@ export function deleteFile(file: vscode.Uri): Thenable { }); } -export function cleanUp(): Thenable { - return new Promise((resolve, reject) => { - if (vscode.window.visibleTextEditors.length === 0) { - return resolve(); - } - - const reg = vscode.window.onDidChangeVisibleTextEditors(editors => { - if (editors.length === 0) { - resolve(); - reg.dispose(); - } - }); +export function closeAllEditors(): Thenable { + return vscode.commands.executeCommand('workbench.action.closeAllEditors'); - vscode.commands.executeCommand('workbench.action.closeAllEditors').then(undefined, reject); - - }).then(() => { - assert.equal(vscode.window.visibleTextEditors.length, 0); - assert(!vscode.window.activeTextEditor); - - // TODO: we can't yet make this assertion because when - // the phost creates a document and makes no changes to it, - // the main side doesn't know about it and the phost side - // assumes it exists. Calling closeAllFiles will not - // remove it from textDocuments array. :( - - // assert.equal(vscode.workspace.textDocuments.length, 0); - }); } diff --git a/extensions/vscode-api-tests/src/window.test.ts b/extensions/vscode-api-tests/src/window.test.ts index cb14027e666..cf4c0f653e5 100644 --- a/extensions/vscode-api-tests/src/window.test.ts +++ b/extensions/vscode-api-tests/src/window.test.ts @@ -8,11 +8,11 @@ import * as assert from 'assert'; import { workspace, window, commands, ViewColumn, TextEditorViewColumnChangeEvent, Uri, Selection, Position, CancellationTokenSource, TextEditorSelectionChangeKind } from 'vscode'; import { join } from 'path'; -import { cleanUp, pathEquals, createRandomFile } from './utils'; +import { closeAllEditors, pathEquals, createRandomFile } from './utils'; suite('window namespace tests', () => { - teardown(cleanUp); + teardown(closeAllEditors); test('editor, active text editor', () => { return workspace.openTextDocument(join(workspace.rootPath || '', './far.js')).then(doc => { @@ -24,10 +24,10 @@ suite('window namespace tests', () => { }); }); - test('editor, UN-active text editor', () => { - assert.equal(window.visibleTextEditors.length, 0); - assert.ok(window.activeTextEditor === undefined); - }); + // test('editor, UN-active text editor', () => { + // assert.equal(window.visibleTextEditors.length, 0); + // assert.ok(window.activeTextEditor === undefined); + // }); test('editor, assign and check view columns', () => { diff --git a/extensions/vscode-api-tests/src/workspace.test.ts b/extensions/vscode-api-tests/src/workspace.test.ts index 54aaa0f7962..acd9e5b4b99 100644 --- a/extensions/vscode-api-tests/src/workspace.test.ts +++ b/extensions/vscode-api-tests/src/workspace.test.ts @@ -7,13 +7,13 @@ import * as assert from 'assert'; import * as vscode from 'vscode'; -import { createRandomFile, deleteFile, cleanUp, pathEquals } from './utils'; +import { createRandomFile, deleteFile, closeAllEditors, pathEquals } from './utils'; import { join, basename } from 'path'; import * as fs from 'fs'; suite('workspace-namespace', () => { - teardown(cleanUp); + teardown(closeAllEditors); test('textDocuments', () => { -- GitLab From 6df8165d8d523f6256e03abf14c72b99d5b0b53f Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 7 Jun 2017 16:21:53 +0200 Subject: [PATCH 0597/1347] Fixes #21346: Implement a different minimap slider scroll strategy --- src/vs/base/browser/fastDomNode.ts | 8 - .../browser/ui/scrollbar/abstractScrollbar.ts | 93 +++++---- .../ui/scrollbar/horizontalScrollbar.ts | 10 +- .../browser/ui/scrollbar/scrollableElement.ts | 12 +- .../browser/ui/scrollbar/verticalScrollbar.ts | 10 +- src/vs/editor/browser/view/viewImpl.ts | 3 +- .../editorScrollbar/editorScrollbar.ts | 8 +- .../browser/viewParts/minimap/minimap.ts | 177 ++++++++---------- .../editor/browser/widget/codeEditorWidget.ts | 3 +- .../editor/browser/widget/diffEditorWidget.ts | 2 +- 10 files changed, 157 insertions(+), 169 deletions(-) diff --git a/src/vs/base/browser/fastDomNode.ts b/src/vs/base/browser/fastDomNode.ts index ee1dd6cd58f..edd726ec0a2 100644 --- a/src/vs/base/browser/fastDomNode.ts +++ b/src/vs/base/browser/fastDomNode.ts @@ -80,10 +80,6 @@ export abstract class FastDomNode { this.domNode.style.height = this._height + 'px'; } - public getHeight(): number { - return this._height; - } - public unsetHeight(): void { if (this._height === -1) { return; @@ -100,10 +96,6 @@ export abstract class FastDomNode { this.domNode.style.top = this._top + 'px'; } - public getTop(): number { - return this._top; - } - public unsetTop(): void { if (this._top === -1) { return; diff --git a/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts b/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts index ce1196e6b81..c7194cbc5c5 100644 --- a/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts +++ b/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts @@ -6,7 +6,7 @@ import * as Platform from 'vs/base/common/platform'; import * as DomUtils from 'vs/base/browser/dom'; -import { IMouseEvent, StandardMouseEvent, StandardMouseWheelEvent } from 'vs/base/browser/mouseEvent'; +import { IMouseEvent, StandardMouseWheelEvent } from 'vs/base/browser/mouseEvent'; import { GlobalMouseMoveMonitor, IStandardMouseMoveEventData, standardMouseMoveMerger } from 'vs/base/browser/globalMouseMoveMonitor'; import { Widget } from 'vs/base/browser/ui/widget'; import { FastDomNode, createFastDomNode } from 'vs/base/browser/fastDomNode'; @@ -20,8 +20,7 @@ import { Scrollable, ScrollbarVisibility } from 'vs/base/common/scrollable'; */ const MOUSE_DRAG_RESET_DISTANCE = 140; -export interface IMouseMoveEventData { - leftButton: boolean; +export interface ISimplifiedMouseEvent { posx: number; posy: number; } @@ -102,7 +101,12 @@ export abstract class AbstractScrollbar extends Widget { this.domNode.domNode.appendChild(this.slider.domNode); - this.onmousedown(this.slider.domNode, (e) => this._sliderMouseDown(e)); + this.onmousedown(this.slider.domNode, (e) => { + if (e.leftButton) { + e.preventDefault(); + this._sliderMouseDown(e, () => { /*nothing to do*/ }); + } + }); } // ----------------- Update state @@ -180,59 +184,66 @@ export abstract class AbstractScrollbar extends Widget { this._onMouseDown(e); } - public delegateMouseDown(browserEvent: MouseEvent): void { - let e = new StandardMouseEvent(browserEvent); + public delegateMouseDown(e: IMouseEvent): void { let domTop = this.domNode.domNode.getClientRects()[0].top; let sliderStart = domTop + this._scrollbarState.getSliderPosition(); let sliderStop = domTop + this._scrollbarState.getSliderPosition() + this._scrollbarState.getSliderSize(); let mousePos = this._sliderMousePosition(e); if (sliderStart <= mousePos && mousePos <= sliderStop) { // Act as if it was a mouse down on the slider - this._sliderMouseDown(e); + if (e.leftButton) { + e.preventDefault(); + this._sliderMouseDown(e, () => { /*nothing to do*/ }); + } } else { // Act as if it was a mouse down on the scrollbar this._onMouseDown(e); } } + public delegateSliderMouseDown(e: ISimplifiedMouseEvent, onDragFinished: () => void): void { + this._sliderMouseDown(e, onDragFinished); + } + private _onMouseDown(e: IMouseEvent): void { let domNodePosition = DomUtils.getDomNodePagePosition(this.domNode.domNode); this.setDesiredScrollPosition(this._scrollbarState.getDesiredScrollPositionFromOffset(this._mouseDownRelativePosition(e, domNodePosition))); - this._sliderMouseDown(e); + if (e.leftButton) { + e.preventDefault(); + this._sliderMouseDown(e, () => { /*nothing to do*/ }); + } } - private _sliderMouseDown(e: IMouseEvent): void { - if (e.leftButton) { - const initialMousePosition = this._sliderMousePosition(e); - const initialMouseOrthogonalPosition = this._sliderOrthogonalMousePosition(e); - const initialScrollbarState = this._scrollbarState.clone(); - this.slider.toggleClassName('active', true); - - this._mouseMoveMonitor.startMonitoring( - standardMouseMoveMerger, - (mouseMoveData: IStandardMouseMoveEventData) => { - const mouseOrthogonalPosition = this._sliderOrthogonalMousePosition(mouseMoveData); - const mouseOrthogonalDelta = Math.abs(mouseOrthogonalPosition - initialMouseOrthogonalPosition); - - if (Platform.isWindows && mouseOrthogonalDelta > MOUSE_DRAG_RESET_DISTANCE) { - // The mouse has wondered away from the scrollbar => reset dragging - this.setDesiredScrollPosition(initialScrollbarState.getScrollPosition()); - return; - } - - const mousePosition = this._sliderMousePosition(mouseMoveData); - const mouseDelta = mousePosition - initialMousePosition; - this.setDesiredScrollPosition(initialScrollbarState.getDesiredScrollPositionFromDelta(mouseDelta)); - }, - () => { - this.slider.toggleClassName('active', false); - this._host.onDragEnd(); + private _sliderMouseDown(e: ISimplifiedMouseEvent, onDragFinished: () => void): void { + const initialMousePosition = this._sliderMousePosition(e); + const initialMouseOrthogonalPosition = this._sliderOrthogonalMousePosition(e); + const initialScrollbarState = this._scrollbarState.clone(); + this.slider.toggleClassName('active', true); + + this._mouseMoveMonitor.startMonitoring( + standardMouseMoveMerger, + (mouseMoveData: IStandardMouseMoveEventData) => { + const mouseOrthogonalPosition = this._sliderOrthogonalMousePosition(mouseMoveData); + const mouseOrthogonalDelta = Math.abs(mouseOrthogonalPosition - initialMouseOrthogonalPosition); + + if (Platform.isWindows && mouseOrthogonalDelta > MOUSE_DRAG_RESET_DISTANCE) { + // The mouse has wondered away from the scrollbar => reset dragging + this.setDesiredScrollPosition(initialScrollbarState.getScrollPosition()); + return; } - ); - e.preventDefault(); - this._host.onDragStart(); - } + const mousePosition = this._sliderMousePosition(mouseMoveData); + const mouseDelta = mousePosition - initialMousePosition; + this.setDesiredScrollPosition(initialScrollbarState.getDesiredScrollPositionFromDelta(mouseDelta)); + }, + () => { + this.slider.toggleClassName('active', false); + this._host.onDragEnd(); + onDragFinished(); + } + ); + + this._host.onDragStart(); } public setDesiredScrollPosition(desiredScrollPosition: number): boolean { @@ -254,9 +265,9 @@ export abstract class AbstractScrollbar extends Widget { protected abstract _renderDomNode(largeSize: number, smallSize: number): void; protected abstract _updateSlider(sliderSize: number, sliderPosition: number): void; - protected abstract _mouseDownRelativePosition(e: IMouseEvent, domNodePosition: DomUtils.IDomNodePagePosition): number; - protected abstract _sliderMousePosition(e: IMouseMoveEventData): number; - protected abstract _sliderOrthogonalMousePosition(e: IMouseMoveEventData): number; + protected abstract _mouseDownRelativePosition(e: ISimplifiedMouseEvent, domNodePosition: DomUtils.IDomNodePagePosition): number; + protected abstract _sliderMousePosition(e: ISimplifiedMouseEvent): number; + protected abstract _sliderOrthogonalMousePosition(e: ISimplifiedMouseEvent): number; protected abstract _getScrollPosition(): number; protected abstract _setScrollPosition(elementScrollPosition: number): void; diff --git a/src/vs/base/browser/ui/scrollbar/horizontalScrollbar.ts b/src/vs/base/browser/ui/scrollbar/horizontalScrollbar.ts index 616d185a633..8e7e678f46f 100644 --- a/src/vs/base/browser/ui/scrollbar/horizontalScrollbar.ts +++ b/src/vs/base/browser/ui/scrollbar/horizontalScrollbar.ts @@ -4,8 +4,8 @@ *--------------------------------------------------------------------------------------------*/ 'use strict'; -import { AbstractScrollbar, ScrollbarHost, IMouseMoveEventData } from 'vs/base/browser/ui/scrollbar/abstractScrollbar'; -import { IMouseEvent, StandardMouseWheelEvent } from 'vs/base/browser/mouseEvent'; +import { AbstractScrollbar, ScrollbarHost, ISimplifiedMouseEvent } from 'vs/base/browser/ui/scrollbar/abstractScrollbar'; +import { StandardMouseWheelEvent } from 'vs/base/browser/mouseEvent'; import { IDomNodePagePosition } from 'vs/base/browser/dom'; import { ScrollableElementResolvedOptions } from 'vs/base/browser/ui/scrollbar/scrollableElementOptions'; import { Scrollable, ScrollEvent, ScrollbarVisibility } from 'vs/base/common/scrollable'; @@ -84,15 +84,15 @@ export class HorizontalScrollbar extends AbstractScrollbar { return this._shouldRender; } - protected _mouseDownRelativePosition(e: IMouseEvent, domNodePosition: IDomNodePagePosition): number { + protected _mouseDownRelativePosition(e: ISimplifiedMouseEvent, domNodePosition: IDomNodePagePosition): number { return e.posx - domNodePosition.left; } - protected _sliderMousePosition(e: IMouseMoveEventData): number { + protected _sliderMousePosition(e: ISimplifiedMouseEvent): number { return e.posx; } - protected _sliderOrthogonalMousePosition(e: IMouseMoveEventData): number { + protected _sliderOrthogonalMousePosition(e: ISimplifiedMouseEvent): number { return e.posy; } diff --git a/src/vs/base/browser/ui/scrollbar/scrollableElement.ts b/src/vs/base/browser/ui/scrollbar/scrollableElement.ts index 8e69aa38ffa..c07026b7f72 100644 --- a/src/vs/base/browser/ui/scrollbar/scrollableElement.ts +++ b/src/vs/base/browser/ui/scrollbar/scrollableElement.ts @@ -18,7 +18,7 @@ import { Scrollable, ScrollState, ScrollEvent, INewScrollState, ScrollbarVisibil import { Widget } from 'vs/base/browser/ui/widget'; import { TimeoutTimer } from 'vs/base/common/async'; import { FastDomNode, createFastDomNode } from 'vs/base/browser/fastDomNode'; -import { ScrollbarHost } from 'vs/base/browser/ui/scrollbar/abstractScrollbar'; +import { ScrollbarHost, ISimplifiedMouseEvent } from 'vs/base/browser/ui/scrollbar/abstractScrollbar'; import Event, { Emitter } from 'vs/base/common/event'; const HIDE_TIMEOUT = 500; @@ -141,10 +141,18 @@ export class ScrollableElement extends Widget { * Delegate a mouse down event to the vertical scrollbar. * This is to help with clicking somewhere else and having the scrollbar react. */ - public delegateVerticalScrollbarMouseDown(browserEvent: MouseEvent): void { + public delegateVerticalScrollbarMouseDown(browserEvent: IMouseEvent): void { this._verticalScrollbar.delegateMouseDown(browserEvent); } + /** + * Delegate a mouse down event to the vertical scrollbar (directly to the slider!). + * This is to help with clicking somewhere else and having the scrollbar react. + */ + public delegateSliderMouseDown(e: ISimplifiedMouseEvent, onDragFinished: () => void): void { + this._verticalScrollbar.delegateSliderMouseDown(e, onDragFinished); + } + public getVerticalSliderVerticalCenter(): number { return this._verticalScrollbar.getVerticalSliderVerticalCenter(); } diff --git a/src/vs/base/browser/ui/scrollbar/verticalScrollbar.ts b/src/vs/base/browser/ui/scrollbar/verticalScrollbar.ts index 520a7139b48..ce33b4164b4 100644 --- a/src/vs/base/browser/ui/scrollbar/verticalScrollbar.ts +++ b/src/vs/base/browser/ui/scrollbar/verticalScrollbar.ts @@ -4,8 +4,8 @@ *--------------------------------------------------------------------------------------------*/ 'use strict'; -import { AbstractScrollbar, ScrollbarHost, IMouseMoveEventData } from 'vs/base/browser/ui/scrollbar/abstractScrollbar'; -import { IMouseEvent, StandardMouseWheelEvent } from 'vs/base/browser/mouseEvent'; +import { AbstractScrollbar, ScrollbarHost, ISimplifiedMouseEvent } from 'vs/base/browser/ui/scrollbar/abstractScrollbar'; +import { StandardMouseWheelEvent } from 'vs/base/browser/mouseEvent'; import { IDomNodePagePosition } from 'vs/base/browser/dom'; import { ScrollableElementResolvedOptions } from 'vs/base/browser/ui/scrollbar/scrollableElementOptions'; import { Scrollable, ScrollEvent, ScrollbarVisibility } from 'vs/base/common/scrollable'; @@ -89,15 +89,15 @@ export class VerticalScrollbar extends AbstractScrollbar { return this._shouldRender; } - protected _mouseDownRelativePosition(e: IMouseEvent, domNodePosition: IDomNodePagePosition): number { + protected _mouseDownRelativePosition(e: ISimplifiedMouseEvent, domNodePosition: IDomNodePagePosition): number { return e.posy - domNodePosition.top; } - protected _sliderMousePosition(e: IMouseMoveEventData): number { + protected _sliderMousePosition(e: ISimplifiedMouseEvent): number { return e.posy; } - protected _sliderOrthogonalMousePosition(e: IMouseMoveEventData): number { + protected _sliderOrthogonalMousePosition(e: ISimplifiedMouseEvent): number { return e.posx; } diff --git a/src/vs/editor/browser/view/viewImpl.ts b/src/vs/editor/browser/view/viewImpl.ts index 222f39fe1f3..9c947e636be 100644 --- a/src/vs/editor/browser/view/viewImpl.ts +++ b/src/vs/editor/browser/view/viewImpl.ts @@ -49,6 +49,7 @@ import { Minimap } from 'vs/editor/browser/viewParts/minimap/minimap'; import * as viewEvents from 'vs/editor/common/view/viewEvents'; import { IThemeService, getThemeTypeSelector } from 'vs/platform/theme/common/themeService'; import { Cursor } from 'vs/editor/common/controller/cursor'; +import { IMouseEvent } from "vs/base/browser/mouseEvent"; export interface IContentWidgetData { widget: editorBrowser.IContentWidget; @@ -436,7 +437,7 @@ export class View extends ViewEventHandler { // --- BEGIN CodeEditor helpers - public delegateVerticalScrollbarMouseDown(browserEvent: MouseEvent): void { + public delegateVerticalScrollbarMouseDown(browserEvent: IMouseEvent): void { this._scrollbar.delegateVerticalScrollbarMouseDown(browserEvent); } diff --git a/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.ts b/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.ts index 89aee09559d..a90d8f52d03 100644 --- a/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.ts +++ b/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.ts @@ -14,6 +14,8 @@ import * as viewEvents from 'vs/editor/common/view/viewEvents'; import { RenderingContext, RestrictedRenderingContext } from 'vs/editor/common/view/renderingContext'; import { FastDomNode, createFastDomNode } from 'vs/base/browser/fastDomNode'; import { getThemeTypeSelector } from 'vs/platform/theme/common/themeService'; +import { IMouseEvent } from "vs/base/browser/mouseEvent"; +import { ISimplifiedMouseEvent } from "vs/base/browser/ui/scrollbar/abstractScrollbar"; export class EditorScrollbar extends ViewPart { @@ -110,10 +112,14 @@ export class EditorScrollbar extends ViewPart { return this.scrollbarDomNode; } - public delegateVerticalScrollbarMouseDown(browserEvent: MouseEvent): void { + public delegateVerticalScrollbarMouseDown(browserEvent: IMouseEvent): void { this.scrollbar.delegateVerticalScrollbarMouseDown(browserEvent); } + public delegateSliderMouseDown(e: ISimplifiedMouseEvent, onDragFinished: () => void): void { + this.scrollbar.delegateSliderMouseDown(e, onDragFinished); + } + public getVerticalSliderVerticalCenter(): number { return this.scrollbar.getVerticalSliderVerticalCenter(); } diff --git a/src/vs/editor/browser/viewParts/minimap/minimap.ts b/src/vs/editor/browser/viewParts/minimap/minimap.ts index e0cb9cd2cb3..676300944f1 100644 --- a/src/vs/editor/browser/viewParts/minimap/minimap.ts +++ b/src/vs/editor/browser/viewParts/minimap/minimap.ts @@ -142,6 +142,13 @@ class MinimapOptions { class MinimapLayout { + /** + * The given editor scrollTop (input). + */ + public readonly scrollTop: number; + + private readonly _computedSliderRatio: number; + /** * slider dom node top (in CSS px) */ @@ -161,25 +168,45 @@ class MinimapLayout { public readonly endLineNumber: number; constructor( - lastRenderData: RenderData, + scrollTop: number, + computedSliderRatio: number, + sliderTop: number, + sliderHeight: number, + startLineNumber: number, + endLineNumber: number + ) { + this.scrollTop = scrollTop; + this._computedSliderRatio = computedSliderRatio; + this.sliderTop = sliderTop; + this.sliderHeight = sliderHeight; + this.startLineNumber = startLineNumber; + this.endLineNumber = endLineNumber; + } + + /** + * Compute a desired `scrollPosition` such that the slider moves by `delta`. + */ + public getDesiredScrollTopFromDelta(delta: number): number { + let desiredSliderPosition = this.sliderTop + delta; + return Math.round(desiredSliderPosition / this._computedSliderRatio); + } + + public static create( options: MinimapOptions, viewportStartLineNumber: number, viewportEndLineNumber: number, viewportHeight: number, viewportContainsWhitespaceGaps: boolean, lineCount: number, - scrollbarSliderCenter: number - ) { + scrollbarSliderCenter: number, + scrollTop: number, + scrollHeight: number + ): MinimapLayout { const pixelRatio = options.pixelRatio; const minimapLineHeight = getMinimapLineHeight(options.renderMinimap); const minimapLinesFitting = Math.floor(options.canvasInnerHeight / minimapLineHeight); const lineHeight = options.lineHeight; - // >>> The minimap slider should be center-aligned with the scrollbar slider. <<< - // >>> The entire minimap is painted around this constraint. <<< - // - // The slider should encompass the visible lines... Mostly. - // // The visible line count in a viewport can change due to a number of reasons: // a) with the same viewport width, different scroll positions can result in partial lines being visible: // e.g. for a line height of 20, and a viewport height of 600 @@ -188,80 +215,41 @@ class MinimapLayout { // * scrollTop = 20 => visible lines are [2, 31] // b) whitespace gaps might make their way in the viewport (which results in a decrease in the visible line count) // c) we could be in the scroll beyond last line case (which also results in a decrease in the visible line count, down to possibly only one line being visible) - // - // It therefore results that the slider height is variable, based on the current viewport. - // We must first establish a desirable slider height. - if (viewportContainsWhitespaceGaps) { + let sliderHeight: number; + if (viewportContainsWhitespaceGaps && viewportEndLineNumber !== lineCount) { // case b) from above: there are whitespace gaps in the viewport. // In this case, the height of the slider directly reflects the visible line count. const viewportLineCount = viewportEndLineNumber - viewportStartLineNumber + 1; - this.sliderHeight = Math.floor(viewportLineCount * minimapLineHeight / pixelRatio); + sliderHeight = Math.floor(viewportLineCount * minimapLineHeight / pixelRatio); } else { // The slider has a stable height const expectedViewportLineCount = viewportHeight / lineHeight; - this.sliderHeight = Math.floor(expectedViewportLineCount * minimapLineHeight / pixelRatio); + sliderHeight = Math.floor(expectedViewportLineCount * minimapLineHeight / pixelRatio); } + const maxMinimapSliderTop = Math.min(options.minimapHeight - sliderHeight, (lineCount - 1) * minimapLineHeight / pixelRatio); + // The slider can move from 0 to `maxMinimapSliderTop` + // in the same way `scrollTop` can move from 0 to `scrollHeight` - `viewportHeight`. + const computedSliderRatio = (maxMinimapSliderTop) / (scrollHeight - viewportHeight); + const sliderTop = (scrollTop * computedSliderRatio); + if (minimapLinesFitting >= lineCount) { - // All lines fit in the minimap => no minimap scrolling - // => the slider cannot be center-aligned with the scrollbar slider - this.startLineNumber = 1; - this.endLineNumber = lineCount; - - if (viewportEndLineNumber === lineCount) { - // case c) from above: we could be in the scroll beyond last line case - this.sliderTop = Math.floor((viewportStartLineNumber - this.startLineNumber) * minimapLineHeight / pixelRatio); - } else { - const desiredSliderTop = (viewportStartLineNumber - this.startLineNumber) * minimapLineHeight / pixelRatio; - const desiredSliderBottom = (viewportEndLineNumber - this.startLineNumber) * minimapLineHeight / pixelRatio; - const desiredSliderCenter = (desiredSliderTop + desiredSliderBottom) / 2; - this.sliderTop = Math.floor(desiredSliderCenter - this.sliderHeight / 2); - } + // All lines fit in the minimap + const startLineNumber = 1; + const endLineNumber = lineCount; + + return new MinimapLayout(scrollTop, computedSliderRatio, sliderTop, sliderHeight, startLineNumber, endLineNumber); } else { - // assign sliderTop last to maintain the same field assignment order in both if and else branches - const sliderTop = Math.floor(Math.min(options.minimapHeight - this.sliderHeight, Math.max(0, scrollbarSliderCenter - this.sliderHeight / 2))); + const startLineNumber = Math.max(1, Math.floor(viewportStartLineNumber - sliderTop * pixelRatio / minimapLineHeight)); + const endLineNumber = Math.min(lineCount, startLineNumber + minimapLinesFitting - 1); - this.startLineNumber = Math.max(1, Math.floor(viewportStartLineNumber - sliderTop * pixelRatio / minimapLineHeight)); - this.endLineNumber = Math.min(lineCount, this.startLineNumber + minimapLinesFitting - 1); - this.sliderTop = sliderTop; + return new MinimapLayout(scrollTop, computedSliderRatio, sliderTop, sliderHeight, startLineNumber, endLineNumber); } } } -class RenderedLayout { - /** - * editor viewport start line number. - */ - public readonly viewportStartLineNumber: number; - /** - * editor viewport end line number. - */ - public readonly viewportEndLineNumber: number; - - /** - * minimap rendered start line number. - */ - public readonly startLineNumber: number; - /** - * minimap rendered end line number. - */ - public readonly endLineNumber: number; - - constructor( - viewportStartLineNumber: number, - viewportEndLineNumber: number, - startLineNumber: number, - endLineNumber: number - ) { - this.viewportStartLineNumber = viewportStartLineNumber; - this.viewportEndLineNumber = viewportEndLineNumber; - this.startLineNumber = startLineNumber; - this.endLineNumber = endLineNumber; - } -} - class MinimapLine implements ILine { public static INVALID = new MinimapLine(-1); @@ -285,12 +273,12 @@ class RenderData { /** * last rendered layout. */ - public readonly renderedLayout: RenderedLayout; + public readonly renderedLayout: MinimapLayout; private readonly _imageData: ImageData; private readonly _renderedLines: RenderedLinesCollection; constructor( - renderedLayout: RenderedLayout, + renderedLayout: MinimapLayout, imageData: ImageData, lines: MinimapLine[] ) { @@ -461,45 +449,30 @@ export class Minimap extends ViewPart { this._sliderMouseDownListener = dom.addStandardDisposableListener(this._slider.domNode, 'mousedown', (e) => { e.preventDefault(); + if (e.leftButton && this._lastRenderData) { - if (e.leftButton) { + const initialMousePosition = e.posy; const initialMouseOrthogonalPosition = e.posx; - const initialScrollTop = this._context.viewLayout.getScrollTop(); - const initialSliderCenter = (this._slider.getTop() + this._slider.getHeight() / 2); - const draggingDeltaCenter = e.posy - initialSliderCenter; + const initialSliderState = this._lastRenderData.renderedLayout; this._slider.toggleClassName('active', true); this._sliderMouseMoveMonitor.startMonitoring( standardMouseMoveMerger, (mouseMoveData: IStandardMouseMoveEventData) => { - const mouseOrthogonalPosition = mouseMoveData.posx; - const mouseOrthogonalDelta = Math.abs(mouseOrthogonalPosition - initialMouseOrthogonalPosition); - if (platform.isWindows && mouseOrthogonalDelta > MOUSE_DRAG_RESET_DISTANCE) { - // The mouse has wondered away from the slider => reset dragging - this._context.viewLayout.setScrollPosition({ - scrollTop: initialScrollTop - }); - } else { - const pixelRatio = this._options.pixelRatio; - const minimapLineHeight = getMinimapLineHeight(this._options.renderMinimap); - const entireCanvasOuterHeight = this._context.model.getLineCount() * minimapLineHeight / pixelRatio; - const representableHeight = Math.min(entireCanvasOuterHeight, this._options.canvasOuterHeight); - - // Account for the fact that the minimap does not render the extra space below the viewport - let discountScrollHeight = 0; - if (this._context.configuration.editor.viewInfo.scrollBeyondLastLine) { - discountScrollHeight = this._canvas.getHeight() - this._context.configuration.editor.lineHeight; - } - const scrollHeight = this._context.viewLayout.getScrollHeight() - discountScrollHeight; - - const desiredSliderCenter = mouseMoveData.posy - draggingDeltaCenter; - const desiredScrollCenter = desiredSliderCenter * (scrollHeight / representableHeight); - const desiredScrollTop = desiredScrollCenter - this._canvas.getHeight() / 2; + const mouseOrthogonalDelta = Math.abs(mouseMoveData.posx - initialMouseOrthogonalPosition); + if (platform.isWindows && mouseOrthogonalDelta > MOUSE_DRAG_RESET_DISTANCE) { + // The mouse has wondered away from the scrollbar => reset dragging this._context.viewLayout.setScrollPosition({ - scrollTop: desiredScrollTop + scrollTop: initialSliderState.scrollTop }); + return; } + + const mouseDelta = mouseMoveData.posy - initialMousePosition; + this._context.viewLayout.setScrollPosition({ + scrollTop: initialSliderState.getDesiredScrollTopFromDelta(mouseDelta) + }); }, () => { this._slider.toggleClassName('active', false); @@ -627,15 +600,16 @@ export class Minimap extends ViewPart { this._shadow.setClassName('minimap-shadow-visible'); } - const layout = new MinimapLayout( - this._lastRenderData, + const layout = MinimapLayout.create( this._options, renderingCtx.visibleRange.startLineNumber, renderingCtx.visibleRange.endLineNumber, renderingCtx.viewportHeight, (renderingCtx.viewportData.whitespaceViewportData.length > 0), this._context.model.getLineCount(), - this._editorScrollbar.getVerticalSliderVerticalCenter() + this._editorScrollbar.getVerticalSliderVerticalCenter(), + renderingCtx.scrollTop, + renderingCtx.scrollHeight ); this._slider.setTop(layout.sliderTop); this._slider.setHeight(layout.sliderHeight); @@ -684,12 +658,7 @@ export class Minimap extends ViewPart { // Save rendered data for reuse on next frame if possible this._lastRenderData = new RenderData( - new RenderedLayout( - renderingCtx.visibleRange.startLineNumber, - renderingCtx.visibleRange.endLineNumber, - startLineNumber, - endLineNumber - ), + layout, imageData, renderedLines ); diff --git a/src/vs/editor/browser/widget/codeEditorWidget.ts b/src/vs/editor/browser/widget/codeEditorWidget.ts index bfb0cc8cecc..dd68b25c24b 100644 --- a/src/vs/editor/browser/widget/codeEditorWidget.ts +++ b/src/vs/editor/browser/widget/codeEditorWidget.ts @@ -33,6 +33,7 @@ import { CoreEditorCommand } from 'vs/editor/common/controller/coreCommands'; import { IThemeService, registerThemingParticipant } from 'vs/platform/theme/common/themeService'; import { editorErrorForeground, editorErrorBorder, editorWarningForeground, editorWarningBorder } from 'vs/editor/common/view/editorColorRegistry'; import { Color } from 'vs/base/common/color'; +import { IMouseEvent } from "vs/base/browser/mouseEvent"; export abstract class CodeEditorWidget extends CommonCodeEditor implements editorBrowser.ICodeEditor { @@ -189,7 +190,7 @@ export abstract class CodeEditorWidget extends CommonCodeEditor implements edito return this.viewModel.coordinatesConverter.convertViewRangeToModelRange(viewRange); } - public delegateVerticalScrollbarMouseDown(browserEvent: MouseEvent): void { + public delegateVerticalScrollbarMouseDown(browserEvent: IMouseEvent): void { if (!this.hasView) { return; } diff --git a/src/vs/editor/browser/widget/diffEditorWidget.ts b/src/vs/editor/browser/widget/diffEditorWidget.ts index 556c843ce15..362c7383476 100644 --- a/src/vs/editor/browser/widget/diffEditorWidget.ts +++ b/src/vs/editor/browser/widget/diffEditorWidget.ts @@ -249,7 +249,7 @@ export class DiffEditorWidget extends Disposable implements editorBrowser.IDiffE this._overviewDomElement.appendChild(this._overviewViewportDomElement.domNode); - this._register(dom.addDisposableListener(this._overviewDomElement, 'mousedown', (e: MouseEvent) => { + this._register(dom.addStandardDisposableListener(this._overviewDomElement, 'mousedown', (e) => { this.modifiedEditor.delegateVerticalScrollbarMouseDown(e); })); this._containerDomElement.appendChild(this._overviewDomElement); -- GitLab From 39a1330e5ad7c40ccc79fd0208fd9a9666b60fc6 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Wed, 7 Jun 2017 10:38:26 +0200 Subject: [PATCH 0598/1347] Improve terminal default --- src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts index f63861f41d7..1e2aadffdb3 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts @@ -46,8 +46,7 @@ const dependsOn: IJSONSchema = { const terminal: IJSONSchema = { type: 'object', default: { - reveal: 'always', - echo: false + reveal: 'always' }, description: nls.localize('JsonSchema.tasks.terminal', 'Describe how the terminal used to execute a task behaves.'), properties: { -- GitLab From 093cd889ef603016862852fa70941087ee00ba9d Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Wed, 7 Jun 2017 13:38:45 +0200 Subject: [PATCH 0599/1347] Reactivate pickers for build and test tasks. --- .../parts/tasks/browser/buildQuickOpen.ts | 58 ++++++++++ .../parts/tasks/browser/testQuickOpen.ts | 58 ++++++++++ .../parts/tasks/common/taskService.ts | 1 + .../electron-browser/task.contribution.ts | 105 +++++++++++++++++- 4 files changed, 218 insertions(+), 4 deletions(-) create mode 100644 src/vs/workbench/parts/tasks/browser/buildQuickOpen.ts create mode 100644 src/vs/workbench/parts/tasks/browser/testQuickOpen.ts diff --git a/src/vs/workbench/parts/tasks/browser/buildQuickOpen.ts b/src/vs/workbench/parts/tasks/browser/buildQuickOpen.ts new file mode 100644 index 00000000000..28b9db52514 --- /dev/null +++ b/src/vs/workbench/parts/tasks/browser/buildQuickOpen.ts @@ -0,0 +1,58 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +'use strict'; + +import nls = require('vs/nls'); +import { TPromise } from 'vs/base/common/winjs.base'; +import QuickOpen = require('vs/base/parts/quickopen/common/quickOpen'); +import Model = require('vs/base/parts/quickopen/browser/quickOpenModel'); +import { IQuickOpenService } from 'vs/platform/quickOpen/common/quickOpen'; + +import { Task, TaskGroup } from 'vs/workbench/parts/tasks/common/tasks'; +import { ITaskService } from 'vs/workbench/parts/tasks/common/taskService'; + +import * as base from './quickOpen'; + +class TaskEntry extends base.TaskEntry { + constructor(taskService: ITaskService, task: Task, highlights: Model.IHighlight[] = []) { + super(taskService, task, highlights); + } + + public run(mode: QuickOpen.Mode, context: Model.IContext): boolean { + if (mode === QuickOpen.Mode.PREVIEW) { + return false; + } + this.taskService.run(this._task); + return true; + } +} + +export class QuickOpenHandler extends base.QuickOpenHandler { + constructor( + @IQuickOpenService quickOpenService: IQuickOpenService, + @ITaskService taskService: ITaskService + ) { + super(quickOpenService, taskService); + } + + public getAriaLabel(): string { + return nls.localize('tasksAriaLabel', "Type the name of a build task"); + } + + protected getTasks(): TPromise { + return this.taskService.getTasksForGroup(TaskGroup.Build); + } + + protected createEntry(taskService: ITaskService, task: Task, highlights: Model.IHighlight[]): base.TaskEntry { + return new TaskEntry(taskService, task, highlights); + } + + public getEmptyLabel(searchString: string): string { + if (searchString.length > 0) { + return nls.localize('noTasksMatching', "No tasks matching"); + } + return nls.localize('noTasksFound', "No build tasks found"); + } +} diff --git a/src/vs/workbench/parts/tasks/browser/testQuickOpen.ts b/src/vs/workbench/parts/tasks/browser/testQuickOpen.ts new file mode 100644 index 00000000000..96275341b2c --- /dev/null +++ b/src/vs/workbench/parts/tasks/browser/testQuickOpen.ts @@ -0,0 +1,58 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +'use strict'; + +import nls = require('vs/nls'); +import { TPromise } from 'vs/base/common/winjs.base'; +import QuickOpen = require('vs/base/parts/quickopen/common/quickOpen'); +import Model = require('vs/base/parts/quickopen/browser/quickOpenModel'); +import { IQuickOpenService } from 'vs/platform/quickOpen/common/quickOpen'; + +import { Task, TaskGroup } from 'vs/workbench/parts/tasks/common/tasks'; +import { ITaskService } from 'vs/workbench/parts/tasks/common/taskService'; + +import * as base from './quickOpen'; + +class TaskEntry extends base.TaskEntry { + constructor(taskService: ITaskService, task: Task, highlights: Model.IHighlight[] = []) { + super(taskService, task, highlights); + } + + public run(mode: QuickOpen.Mode, context: Model.IContext): boolean { + if (mode === QuickOpen.Mode.PREVIEW) { + return false; + } + this.taskService.run(this._task); + return true; + } +} + +export class QuickOpenHandler extends base.QuickOpenHandler { + constructor( + @IQuickOpenService quickOpenService: IQuickOpenService, + @ITaskService taskService: ITaskService + ) { + super(quickOpenService, taskService); + } + + public getAriaLabel(): string { + return nls.localize('tasksAriaLabel', "Type the name of a test task"); + } + + protected getTasks(): TPromise { + return this.taskService.getTasksForGroup(TaskGroup.Test); + } + + protected createEntry(taskService: ITaskService, task: Task, highlights: Model.IHighlight[]): base.TaskEntry { + return new TaskEntry(taskService, task, highlights); + } + + public getEmptyLabel(searchString: string): string { + if (searchString.length > 0) { + return nls.localize('noTasksMatching', "No tasks matching"); + } + return nls.localize('noTasksFound', "No test tasks found"); + } +} diff --git a/src/vs/workbench/parts/tasks/common/taskService.ts b/src/vs/workbench/parts/tasks/common/taskService.ts index 63b2da04137..b410569a283 100644 --- a/src/vs/workbench/parts/tasks/common/taskService.ts +++ b/src/vs/workbench/parts/tasks/common/taskService.ts @@ -42,6 +42,7 @@ export interface ITaskService extends IEventEmitter { terminate(task: string | Task): TPromise; terminateAll(): TPromise; tasks(): TPromise; + getTasksForGroup(group: string): TPromise; customize(task: Task, openConfig?: boolean): TPromise; diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index 5fea1fd052b..0619206da2f 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -9,6 +9,8 @@ import 'vs/css!./media/task.contribution'; import 'vs/workbench/parts/tasks/browser/taskQuickOpen'; import 'vs/workbench/parts/tasks/browser/terminateQuickOpen'; import 'vs/workbench/parts/tasks/browser/restartQuickOpen'; +import 'vs/workbench/parts/tasks/browser/buildQuickOpen'; +import 'vs/workbench/parts/tasks/browser/testQuickOpen'; import * as nls from 'vs/nls'; @@ -626,7 +628,7 @@ class TaskService extends EventEmitter implements ITaskService { if (!this.canRunCommand()) { return; } - this.build(); + this.runBuildCommand(); }); KeybindingsRegistry.registerKeybindingRule({ @@ -640,7 +642,7 @@ class TaskService extends EventEmitter implements ITaskService { if (!this.canRunCommand()) { return; } - this.runTest(); + this.runTestCommand(); }); } @@ -745,6 +747,33 @@ class TaskService extends EventEmitter implements ITaskService { }); } + public getTasksForGroup(group: string): TPromise { + return this.getTaskSets().then((values) => { + let result: Task[] = []; + for (let value of values) { + for (let task of value.tasks) { + if (task.group === group) { + result.push(task); + } + } + } + return result; + }); + } + + private splitTasks(tasks: Task[]): { configured: Task[], detected: Task[] } { + let configured: Task[] = []; + let detected: Task[] = []; + for (let task of tasks) { + if (task._source.kind === TaskSourceKind.Workspace) { + configured.push(task); + } else { + detected.push(task); + } + } + return { configured, detected }; + } + public customize(task: Task, openConfig: boolean = false): TPromise { if (task._source.kind !== TaskSourceKind.Extension) { return TPromise.as(undefined); @@ -755,7 +784,10 @@ class TaskService extends EventEmitter implements ITaskService { return TPromise.as(undefined); } let fileConfig = configuration.config; - let customize = { customize: task.identifier, taskName: task._label, problemMatcher: [] }; + let customize: TaskConfig.TaskDescription = { customize: task.identifier, taskName: task._label }; + if (task.problemMatchers === void 0) { + customize.problemMatcher = []; + } if (!fileConfig) { fileConfig = { version: '2.0.0', @@ -1188,7 +1220,10 @@ class TaskService extends EventEmitter implements ITaskService { } public inTerminal(): boolean { - return this._taskSystem instanceof TerminalTaskSystem; + if (this._taskSystem) { + return this._taskSystem instanceof TerminalTaskSystem; + } + return this.getExecutionEngine() === ExecutionEngine.Terminal; } private hasDetectorSupport(config: TaskConfig.ExternalTaskRunnerConfiguration): boolean { @@ -1306,6 +1341,50 @@ class TaskService extends EventEmitter implements ITaskService { } } + private runBuildCommand(): void { + if (!this.canRunCommand()) { + return; + } + if (!this.inTerminal()) { + this.build(); + return; + } + this.getTasksForGroup(TaskGroup.Build).then((tasks) => { + let { configured, detected } = this.splitTasks(tasks); + let total = configured.length + detected.length; + if (total === 0) { + return; + } + if (total === 1) { + this.run(configured[0] || detected[0]); + } else { + this.quickOpenService.show('build task '); + } + }); + } + + private runTestCommand(): void { + if (!this.canRunCommand()) { + return; + } + if (!this.inTerminal()) { + this.build(); + return; + } + this.getTasksForGroup(TaskGroup.Test).then((tasks) => { + let { configured, detected } = this.splitTasks(tasks); + let total = configured.length + detected.length; + if (total === 0) { + return; + } + if (total === 1) { + this.run(configured[0] || detected[0]); + } else { + this.quickOpenService.show('test task '); + } + }); + } + private runTerminateCommand(): void { if (!this.canRunCommand()) { return; @@ -1412,6 +1491,24 @@ quickOpenRegistry.registerQuickOpenHandler( ) ); +quickOpenRegistry.registerQuickOpenHandler( + new QuickOpenHandlerDescriptor( + 'vs/workbench/parts/tasks/browser/buildQuickOpen', + 'QuickOpenHandler', + 'build task ', + nls.localize('quickOpen.buildTask', "Build Task") + ) +); + +quickOpenRegistry.registerQuickOpenHandler( + new QuickOpenHandlerDescriptor( + 'vs/workbench/parts/tasks/browser/testQuickOpen', + 'QuickOpenHandler', + 'test task ', + nls.localize('quickOpen.testTask', "Test Task") + ) +); + const actionBarRegistry = Registry.as(ActionBarExtensions.Actionbar); actionBarRegistry.registerActionBarContributor(Scope.VIEWER, QuickOpenActionContributor); -- GitLab From 99b581e073ee6c4306e39569b918c47bd587a31b Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 7 Jun 2017 16:15:34 +0200 Subject: [PATCH 0600/1347] remove unused code --- src/vs/base/common/filters.ts | 23 -------------------- src/vs/base/test/common/filters.perf.test.ts | 1 - 2 files changed, 24 deletions(-) diff --git a/src/vs/base/common/filters.ts b/src/vs/base/common/filters.ts index e6404bb6edc..49e5de0eb5a 100644 --- a/src/vs/base/common/filters.ts +++ b/src/vs/base/common/filters.ts @@ -358,29 +358,6 @@ export function matchesFuzzy(word: string, wordToMatchAgainst: string, enableSep return enableSeparateSubstringMatching ? fuzzySeparateFilter(word, wordToMatchAgainst) : fuzzyContiguousFilter(word, wordToMatchAgainst); } -export function matchesFuzzy2(pattern: string, word: string): number[] { - - pattern = pattern.toLowerCase(); - word = word.toLowerCase(); - - let matches: number[] = []; - let patternPos = 0; - let wordPos = 0; - while (patternPos < pattern.length && wordPos < word.length) { - if (pattern[patternPos] === word[wordPos]) { - patternPos += 1; - matches.push(wordPos); - } - wordPos += 1; - } - - if (patternPos !== pattern.length) { - return undefined; - } - - return matches; -} - export function createMatches(position: number[]): IMatch[] { let ret: IMatch[] = []; if (!position) { diff --git a/src/vs/base/test/common/filters.perf.test.ts b/src/vs/base/test/common/filters.perf.test.ts index 790e1d3fd67..079c048239c 100644 --- a/src/vs/base/test/common/filters.perf.test.ts +++ b/src/vs/base/test/common/filters.perf.test.ts @@ -39,7 +39,6 @@ perfSuite('Performance - fuzzyMatch', function () { perfTest('matchesFuzzy', filters.matchesFuzzy); perfTest('fuzzyContiguousFilter', filters.fuzzyContiguousFilter); - perfTest('matchesFuzzy2', filters.matchesFuzzy2); perfTest('fuzzyScore', filters.fuzzyScore); perfTest('fuzzyScoreGraceful', filters.fuzzyScoreGraceful); -- GitLab From 4b78474e04295ed52fb01c8526404725615b6d58 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 7 Jun 2017 16:40:25 +0200 Subject: [PATCH 0601/1347] prune when total is going bad, fixes #26423 --- src/vs/base/common/filters.ts | 14 +++----------- src/vs/base/test/common/filters.test.ts | 3 +++ 2 files changed, 6 insertions(+), 11 deletions(-) diff --git a/src/vs/base/common/filters.ts b/src/vs/base/common/filters.ts index 49e5de0eb5a..67b4e38d292 100644 --- a/src/vs/base/common/filters.ts +++ b/src/vs/base/common/filters.ts @@ -474,9 +474,6 @@ export function fuzzyScore(pattern: string, word: string): [number, number[]] { return undefined; } - // keep track of the maximum score - let maxScore = -1; - for (patternPos = patternStartPos + 1; patternPos <= patternLen; patternPos++) { let lastLowWordChar = ''; @@ -508,9 +505,6 @@ export function fuzzyScore(pattern: string, word: string): [number, number[]] { } _scores[patternPos][wordPos] = score; - if (score > maxScore) { - maxScore = score; - } let diag = _table[patternPos - 1][wordPos - 1] + (score > 1 ? 1 : score); let top = _table[patternPos - 1][wordPos] + -1; @@ -546,10 +540,6 @@ export function fuzzyScore(pattern: string, word: string): [number, number[]] { } } - if (maxScore <= 1) { - return undefined; - } - if (_debug) { console.log(printTable(_table, pattern, patternLen, word, wordLen)); console.log(printTable(_arrows, pattern, patternLen, word, wordLen)); @@ -577,7 +567,9 @@ export function fuzzyScore(pattern: string, word: string): [number, number[]] { function findAllMatches(patternLen: number, patternPos: number, patternStartPos: number, wordPos: number, total: number, matches: number[], bucket: [number, number[]][], lastMatched: boolean): void { - if (bucket.length >= 10) { + if (bucket.length >= 10 || total < -25) { + // stop when having already 10 results, or + // when a potential alignment as already 5 gaps return; } diff --git a/src/vs/base/test/common/filters.test.ts b/src/vs/base/test/common/filters.test.ts index 4753059f57c..e555d4a08f5 100644 --- a/src/vs/base/test/common/filters.test.ts +++ b/src/vs/base/test/common/filters.test.ts @@ -306,6 +306,9 @@ suite('Filters', () => { }); test('fuzzyScore, issue #26423', function () { + + assertMatches('baba', 'abababab', undefined, fuzzyScore); + assertMatches( 'fsfsfs', 'dsafdsafdsafdsafdsafdsafdsafasdfdsa', -- GitLab From 4347674e041026e55f2b34dd750e550e43912d1c Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 7 Jun 2017 16:42:17 +0200 Subject: [PATCH 0602/1347] Fixes Microsoft/monaco-editor#425: Create an aria container dom node as soon as the first editor is instantiated --- src/vs/base/browser/ui/aria/aria.css | 2 +- src/vs/base/browser/ui/aria/aria.ts | 6 +++--- .../browser/standalone/standaloneCodeEditor.ts | 13 +++++++++++++ 3 files changed, 17 insertions(+), 4 deletions(-) diff --git a/src/vs/base/browser/ui/aria/aria.css b/src/vs/base/browser/ui/aria/aria.css index fd795b9af1b..75ae8780fe1 100644 --- a/src/vs/base/browser/ui/aria/aria.css +++ b/src/vs/base/browser/ui/aria/aria.css @@ -3,7 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -.aria-container { +.monaco-aria-container { position: absolute; /* try to hide from workbench but not from screen readers */ left:-999em; } \ No newline at end of file diff --git a/src/vs/base/browser/ui/aria/aria.ts b/src/vs/base/browser/ui/aria/aria.ts index dd5776ab9f8..ff89cc49172 100644 --- a/src/vs/base/browser/ui/aria/aria.ts +++ b/src/vs/base/browser/ui/aria/aria.ts @@ -14,10 +14,10 @@ let ariaContainer: Builder; let alertContainer: Builder; let statusContainer: Builder; export function setARIAContainer(parent: HTMLElement) { - ariaContainer = $('.aria-container').appendTo(parent); + ariaContainer = $('.monaco-aria-container').appendTo(parent); - alertContainer = $('.alert').appendTo(ariaContainer).attr({ 'role': 'alert', 'aria-atomic': 'true' }); - statusContainer = $('.status').appendTo(ariaContainer).attr({ 'role': 'status', 'aria-atomic': 'true' }); + alertContainer = $('.monaco-alert').appendTo(ariaContainer).attr({ 'role': 'alert', 'aria-atomic': 'true' }); + statusContainer = $('.monaco-status').appendTo(ariaContainer).attr({ 'role': 'status', 'aria-atomic': 'true' }); } /** diff --git a/src/vs/editor/browser/standalone/standaloneCodeEditor.ts b/src/vs/editor/browser/standalone/standaloneCodeEditor.ts index 2a3a9789ed4..8461009c2a9 100644 --- a/src/vs/editor/browser/standalone/standaloneCodeEditor.ts +++ b/src/vs/editor/browser/standalone/standaloneCodeEditor.ts @@ -25,6 +25,7 @@ import { InternalEditorAction } from 'vs/editor/common/editorAction'; import { MenuId, MenuRegistry, IMenuItem } from 'vs/platform/actions/common/actions'; import { IDiffEditorOptions, IEditorOptions } from 'vs/editor/common/config/editorOptions'; import { IThemeService } from 'vs/platform/theme/common/themeService'; +import * as aria from 'vs/base/browser/ui/aria/aria'; /** * The options to create an editor. @@ -83,6 +84,15 @@ export interface IStandaloneDiffEditor extends IDiffEditor { let LAST_GENERATED_COMMAND_ID = 0; +let ariaDomNodeCreated = false; +function createAriaDomNode() { + if (ariaDomNodeCreated) { + return; + } + ariaDomNodeCreated = true; + aria.setARIAContainer(document.body); +} + /** * A code editor to be used both by the standalone editor and the standalone diff editor. */ @@ -105,6 +115,9 @@ export class StandaloneCodeEditor extends CodeEditor implements IStandaloneCodeE if (keybindingService instanceof StandaloneKeybindingService) { this._standaloneKeybindingService = keybindingService; } + + // Create the ARIA dom node as soon as the first editor is instantiated + createAriaDomNode(); } public addCommand(keybinding: number, handler: ICommandHandler, context: string): string { -- GitLab From 5ca7c3dacb5ac7565d16b24ebdd73137f8965697 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 7 Jun 2017 16:51:04 +0200 Subject: [PATCH 0603/1347] Resolves #27921 --- test/smoke/src/spectron/application.ts | 23 ++++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/test/smoke/src/spectron/application.ts b/test/smoke/src/spectron/application.ts index 4d64259ae17..b6f5196857e 100644 --- a/test/smoke/src/spectron/application.ts +++ b/test/smoke/src/spectron/application.ts @@ -22,19 +22,36 @@ export class SpectronApplication { public client: SpectronClient; private spectron: Application; - private readonly pollTrials = 5; - private readonly pollTimeout = 3; // in secs private keybindings: any[]; private screenshot: Screenshot; + private readonly sampleExtensionsDir: string = 'test_data/sample_extensions_dir'; + private readonly pollTrials = 5; + private readonly pollTimeout = 3; // in secs + constructor(electronPath: string, testName: string, private testRetry: number, args?: string[], chromeDriverArgs?: string[]) { if (!args) { args = []; } + // Prevent 'Getting Started' web page from opening on clean user-data-dir + args.push('--skip-getting-started'); + + // Ensure that running over custom extensions directory, rather than picking up the one that was used by a tester previously + let extensionDirIsSet = false; + for (let arg of args) { + if (arg.startsWith('--extensions-dir')) { + extensionDirIsSet = true; + return; + } + } + if (!extensionDirIsSet) { + args.push(`--extensions-dir=${this.sampleExtensionsDir}`); + } + this.spectron = new Application({ path: electronPath, - args: args.concat(['--skip-getting-started']), // prevent 'Getting Started' web page from opening on clean user-data-dir + args: args, chromeDriverArgs: chromeDriverArgs }); this.screenshot = new Screenshot(this, testName); -- GitLab From e019e2484bc9bbb94b90f4375d788155cbc53519 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 7 Jun 2017 16:51:29 +0200 Subject: [PATCH 0604/1347] filters - simplify findAllMatches --- src/vs/base/common/filters.ts | 34 ++++++++++++------------- src/vs/base/test/common/filters.test.ts | 1 + 2 files changed, 18 insertions(+), 17 deletions(-) diff --git a/src/vs/base/common/filters.ts b/src/vs/base/common/filters.ts index 67b4e38d292..34966eedc71 100644 --- a/src/vs/base/common/filters.ts +++ b/src/vs/base/common/filters.ts @@ -546,15 +546,16 @@ export function fuzzyScore(pattern: string, word: string): [number, number[]] { console.log(printTable(_scores, pattern, patternLen, word, wordLen)); } - let bucket: [number, number[]][] = []; - findAllMatches(patternLen, patternLen, patternStartPos, wordLen, 0, [], bucket, false); + _bucket.length = 0; + _patternStartPos = patternStartPos; + _findAllMatches(patternLen, wordLen, 0, [], false); - if (bucket.length === 0) { + if (_bucket.length === 0) { return undefined; } - let topMatch = bucket.shift(); - for (const match of bucket) { + let topMatch = _bucket.shift(); + for (const match of _bucket) { if (!topMatch || topMatch[0] < match[0]) { topMatch = match; } @@ -565,9 +566,12 @@ export function fuzzyScore(pattern: string, word: string): [number, number[]] { return topMatch; } -function findAllMatches(patternLen: number, patternPos: number, patternStartPos: number, wordPos: number, total: number, matches: number[], bucket: [number, number[]][], lastMatched: boolean): void { +let _bucket: [number, number[]][] = []; +let _patternStartPos: number = 0; - if (bucket.length >= 10 || total < -25) { +function _findAllMatches(patternPos: number, wordPos: number, total: number, matches: number[], lastMatched: boolean): void { + + if (_bucket.length >= 10 || total < -25) { // stop when having already 10 results, or // when a potential alignment as already 5 gaps return; @@ -575,7 +579,7 @@ function findAllMatches(patternLen: number, patternPos: number, patternStartPos: let simpleMatchCount = 0; - while (patternPos > patternStartPos && wordPos > 0) { + while (patternPos > _patternStartPos && wordPos > 0) { let score = _scores[patternPos][wordPos]; let arrow = _arrows[patternPos][wordPos]; @@ -595,11 +599,12 @@ function findAllMatches(patternLen: number, patternPos: number, patternStartPos: if (arrow & Arrow.Left) { // left - findAllMatches( - patternLen, patternPos, patternStartPos, + _findAllMatches( + patternPos, wordPos - 1, matches.length !== 0 ? total - 1 : total, - matches.slice(0), bucket, lastMatched + matches.slice(0), + lastMatched ); } @@ -622,11 +627,6 @@ function findAllMatches(patternLen: number, patternPos: number, patternStartPos: } } - if (matches.length !== patternLen - patternStartPos) { - // doesn't cover whole pattern - return undefined; - } - if (_scores[1][matches[0] + 1] === 1) { // first match is weak return undefined; @@ -634,7 +634,7 @@ function findAllMatches(patternLen: number, patternPos: number, patternStartPos: total -= wordPos >= 3 ? 9 : wordPos * 3; // late start penalty - bucket.push([total, matches]); + _bucket.push([total, matches]); } diff --git a/src/vs/base/test/common/filters.test.ts b/src/vs/base/test/common/filters.test.ts index e555d4a08f5..f5c4bb30869 100644 --- a/src/vs/base/test/common/filters.test.ts +++ b/src/vs/base/test/common/filters.test.ts @@ -248,6 +248,7 @@ suite('Filters', () => { assertMatches('ccm', 'cacmelCase', '^ca^c^melCase', fuzzyScore); assertMatches('bti', 'the_black_knight', undefined, fuzzyScore); assertMatches('ccm', 'camelCase', undefined, fuzzyScore); + assertMatches('cmcm', 'camelCase', undefined, fuzzyScore); assertMatches('BK', 'the_black_knight', 'the_^black_^knight', fuzzyScore); assertMatches('KeyboardLayout=', 'KeyboardLayout', undefined, fuzzyScore); assertMatches('LLL', 'SVisualLoggerLogsList', 'SVisual^Logger^Logs^List', fuzzyScore); -- GitLab From 96869f57428d8b24a61255b3aba36b2d3f716dc2 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 7 Jun 2017 17:00:08 +0200 Subject: [PATCH 0605/1347] break from the loop instead of returning --- test/smoke/src/spectron/application.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/smoke/src/spectron/application.ts b/test/smoke/src/spectron/application.ts index b6f5196857e..64110535615 100644 --- a/test/smoke/src/spectron/application.ts +++ b/test/smoke/src/spectron/application.ts @@ -42,7 +42,7 @@ export class SpectronApplication { for (let arg of args) { if (arg.startsWith('--extensions-dir')) { extensionDirIsSet = true; - return; + break; } } if (!extensionDirIsSet) { -- GitLab From 1f1e1ec7c94e656d2fb05a70378fa5fefbb253f5 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 7 Jun 2017 17:07:12 +0200 Subject: [PATCH 0606/1347] Pass the argument to the VS Code executable, instead of a chrome driver. --- test/smoke/src/tests/extensions.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/smoke/src/tests/extensions.ts b/test/smoke/src/tests/extensions.ts index 9e563f2f3c1..b4514372569 100644 --- a/test/smoke/src/tests/extensions.ts +++ b/test/smoke/src/tests/extensions.ts @@ -24,7 +24,7 @@ export async function testExtensions() { let extensions: Extensions; beforeEach(async function () { - app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH], [`--extensions-dir=${EXTENSIONS_DIR}`]); + app = new SpectronApplication(LATEST_PATH, this.currentTest.fullTitle(), (this.currentTest as any).currentRetry(), [WORKSPACE_PATH, `--extensions-dir=${EXTENSIONS_DIR}`]); common = new CommonActions(app); extensions = new Extensions(app, common); await common.removeDirectory(EXTENSIONS_DIR); -- GitLab From fcf8b2942dee3ad558e24b31c7bcfde3d8b6b544 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 7 Jun 2017 17:11:35 +0200 Subject: [PATCH 0607/1347] Pass extensions-dir as VS Code arg, instead of Chrome Driver one. --- test/smoke/src/tests/data-migration.ts | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/test/smoke/src/tests/data-migration.ts b/test/smoke/src/tests/data-migration.ts index 68c4f698b7e..eee83600838 100644 --- a/test/smoke/src/tests/data-migration.ts +++ b/test/smoke/src/tests/data-migration.ts @@ -24,8 +24,13 @@ export function testDataMigration() { return await common.removeDirectory(EXTENSIONS_DIR); }); - function setupSpectron(context: Mocha.ITestCallbackContext, appPath: string, workspace?: string[]): void { - app = new SpectronApplication(appPath, context.test.fullTitle(), context.test.currentRetry(), workspace, [`--user-data-dir=${USER_DIR}`, `--extensions-dir=${EXTENSIONS_DIR}`]); + function setupSpectron(context: Mocha.ITestCallbackContext, appPath: string, args?: string[]): void { + if (!args) { + args = []; + } + args.push(`--extensions-dir=${EXTENSIONS_DIR}`); + + app = new SpectronApplication(appPath, context.test.fullTitle(), context.test.currentRetry(), args, [`--user-data-dir=${USER_DIR}`]); common = new CommonActions(app); } -- GitLab From dfc9961ae1c9efb9c4f76580e56c1f401783374c Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 7 Jun 2017 17:36:10 +0200 Subject: [PATCH 0608/1347] fix #23728 --- .../contrib/snippet/browser/snippetSession.ts | 2 +- .../test/browser/snippetController2.test.ts | 19 +++++++++++++++++++ 2 files changed, 20 insertions(+), 1 deletion(-) diff --git a/src/vs/editor/contrib/snippet/browser/snippetSession.ts b/src/vs/editor/contrib/snippet/browser/snippetSession.ts index 8f132684531..44cfd7cb388 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetSession.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetSession.ts @@ -296,7 +296,7 @@ export class SnippetSession { // store snippets with the index of their originating selection. // that ensures the primiary cursor stays primary despite not being // the one with lowest start position - edits[idx] = EditOperation.replaceMove(snippetSelection, snippet.text); + edits[idx] = EditOperation.replace(snippetSelection, snippet.text); snippets[idx] = new OneSnippet(editor, snippet, offset); } diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts index 2f42a0c9932..7b55d2061ff 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetController2.test.ts @@ -224,4 +224,23 @@ suite('SnippetController2', function () { ctrl.prev(); // inner `$0` assertSelections(editor, new Selection(1, 31, 1, 31), new Selection(2, 35, 2, 35)); }); + + test('Snippet tabstop selecting content of previously entered variable only works when separated by space, #23728', function () { + const ctrl = new SnippetController2(editor, contextKeys); + + model.setValue(''); + editor.setSelection(new Selection(1, 1, 1, 1)); + + ctrl.insert('import ${2:${1:module}} from \'${1: module }\'$0'); + + assertContextKeys(contextKeys, true, false, true); + assertSelections(editor, new Selection(1, 8, 1, 14), new Selection(1, 21, 1, 29)); + + ctrl.insert('foo'); + assertSelections(editor, new Selection(1, 11, 1, 11), new Selection(1, 21, 1, 21)); + + ctrl.next(); // ${2:...} + assertSelections(editor, new Selection(1, 8, 1, 11)); + }); + }); -- GitLab From 36e83cc200dd6bfe6e688faf5f9611d5e8f52143 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 7 Jun 2017 17:40:21 +0200 Subject: [PATCH 0609/1347] Fixes Microsoft/monaco-editor#446 --- src/vs/base/browser/ui/actionbar/actionbar.ts | 14 ++++++++++++-- src/vs/base/browser/ui/menu/menu.ts | 3 ++- .../contrib/contextmenu/browser/contextmenu.ts | 2 +- 3 files changed, 15 insertions(+), 4 deletions(-) diff --git a/src/vs/base/browser/ui/actionbar/actionbar.ts b/src/vs/base/browser/ui/actionbar/actionbar.ts index 452b2ece1e5..5ec92db83be 100644 --- a/src/vs/base/browser/ui/actionbar/actionbar.ts +++ b/src/vs/base/browser/ui/actionbar/actionbar.ts @@ -218,6 +218,7 @@ export interface IActionItemOptions extends IBaseActionItemOptions { icon?: boolean; label?: boolean; keybinding?: string; + isMenu?: boolean; } export class ActionItem extends BaseActionItem { @@ -239,7 +240,11 @@ export class ActionItem extends BaseActionItem { super.render(container); this.$e = $('a.action-label').appendTo(this.builder); - this.$e.attr({ role: 'button' }); + if (this.options.isMenu) { + this.$e.attr({ role: 'menuitem' }); + } else { + this.$e.attr({ role: 'button' }); + } if (this.options.label && this.options.keybinding) { $('span.keybinding').text(this.options.keybinding).appendTo(this.builder); @@ -343,6 +348,7 @@ export interface IActionBarOptions { actionRunner?: IActionRunner; ariaLabel?: string; animated?: boolean; + isMenu?: boolean; } let defaultOptions: IActionBarOptions = { @@ -458,7 +464,11 @@ export class ActionBar extends EventEmitter implements IActionRunner { this.actionsList = document.createElement('ul'); this.actionsList.className = 'actions-container'; - this.actionsList.setAttribute('role', 'toolbar'); + if (this.options.isMenu) { + this.actionsList.setAttribute('role', 'menubar'); + } else { + this.actionsList.setAttribute('role', 'toolbar'); + } if (this.options.ariaLabel) { this.actionsList.setAttribute('aria-label', this.options.ariaLabel); } diff --git a/src/vs/base/browser/ui/menu/menu.ts b/src/vs/base/browser/ui/menu/menu.ts index 15a21485536..2130e8803b7 100644 --- a/src/vs/base/browser/ui/menu/menu.ts +++ b/src/vs/base/browser/ui/menu/menu.ts @@ -36,7 +36,8 @@ export class Menu extends EventEmitter { orientation: ActionsOrientation.VERTICAL, actionItemProvider: options.actionItemProvider, context: options.context, - actionRunner: options.actionRunner + actionRunner: options.actionRunner, + isMenu: true }); this.listener = this.addEmitter(this.actionBar); diff --git a/src/vs/editor/contrib/contextmenu/browser/contextmenu.ts b/src/vs/editor/contrib/contextmenu/browser/contextmenu.ts index a5dbd5818bc..b389061785a 100644 --- a/src/vs/editor/contrib/contextmenu/browser/contextmenu.ts +++ b/src/vs/editor/contrib/contextmenu/browser/contextmenu.ts @@ -175,7 +175,7 @@ export class ContextMenuController implements IEditorContribution { getActionItem: (action) => { var keybinding = this._keybindingFor(action); if (keybinding) { - return new ActionItem(action, action, { label: true, keybinding: keybinding.getLabel() }); + return new ActionItem(action, action, { label: true, keybinding: keybinding.getLabel(), isMenu: true }); } var customActionItem = action; -- GitLab From bc72c645731b520d6f5893f92819072dd44298cd Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Wed, 7 Jun 2017 18:32:57 +0200 Subject: [PATCH 0610/1347] Always show group label --- .../workbench/parts/tasks/browser/quickOpen.ts | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/src/vs/workbench/parts/tasks/browser/quickOpen.ts b/src/vs/workbench/parts/tasks/browser/quickOpen.ts index 3ec4cf96180..c8661e0d52c 100644 --- a/src/vs/workbench/parts/tasks/browser/quickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/quickOpen.ts @@ -89,22 +89,20 @@ export abstract class QuickOpenHandler extends Quickopen.QuickOpenHandler { return +1; } }); - let hasWorkspace: boolean = tasks[0]._source.kind === TaskSourceKind.Workspace; - let hasExtension: boolean = tasks[tasks.length - 1]._source.kind === TaskSourceKind.Extension; - let groupWorkspace = hasWorkspace && hasExtension; - let groupExtension = groupWorkspace; - let hadWorkspace = false; + let firstWorkspace: boolean = true; + let firstExtension: boolean = true; + let hadWorkspace: boolean = false; for (let task of tasks) { let highlights = Filters.matchesContiguousSubString(input, task._label); if (!highlights) { continue; } - if (task._source.kind === TaskSourceKind.Workspace && groupWorkspace) { - groupWorkspace = false; + if (task._source.kind === TaskSourceKind.Workspace && firstWorkspace) { + firstWorkspace = false; hadWorkspace = true; entries.push(new TaskGroupEntry(this.createEntry(this.taskService, task, highlights), nls.localize('configured', 'Configured Tasks'), false)); - } else if (task._source.kind === TaskSourceKind.Extension && groupExtension) { - groupExtension = false; + } else if (task._source.kind === TaskSourceKind.Extension && firstExtension) { + firstExtension = false; entries.push(new TaskGroupEntry(this.createEntry(this.taskService, task, highlights), nls.localize('detected', 'Detected Tasks'), hadWorkspace)); } else { entries.push(this.createEntry(this.taskService, task, highlights)); -- GitLab From dd9ebe1d6eed63a29a87a87b887cb78b2205a860 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 7 Jun 2017 10:20:40 -0700 Subject: [PATCH 0611/1347] Fix more TS 2.4 Errors in VS Code codebase (#28144) --- src/vs/base/common/glob.ts | 3 ++- .../contrib/goToDeclaration/browser/goToDeclaration.ts | 2 +- src/vs/editor/contrib/rename/browser/rename.ts | 2 +- .../contrib/wordHighlighter/common/wordHighlighter.ts | 2 +- src/vs/platform/update/electron-main/updateService.ts | 6 +++--- .../workbench/api/electron-browser/mainThreadTreeViews.ts | 4 ++-- .../parts/snippets/electron-browser/snippetsService.ts | 2 +- .../parts/tasks/electron-browser/terminalTaskSystem.ts | 2 +- .../parts/terminal/electron-browser/terminalService.ts | 2 +- 9 files changed, 13 insertions(+), 12 deletions(-) diff --git a/src/vs/base/common/glob.ts b/src/vs/base/common/glob.ts index 33da9d6b879..8fcd060bf94 100644 --- a/src/vs/base/common/glob.ts +++ b/src/vs/base/common/glob.ts @@ -436,7 +436,8 @@ export function parse(arg1: string | IExpression, options: IGlobOptions = {}): a export function parseToAsync(expression: IExpression, options?: IGlobOptions): ParsedExpression { const parsedExpression = parse(expression, options); return (path: string, basename?: string, siblingsFn?: () => TPromise): TPromise => { - return TPromise.as(parsedExpression(path, basename, siblingsFn)); + const result = parsedExpression(path, basename, siblingsFn); + return typeof result === 'string' ? TPromise.as(result) : result; }; } diff --git a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclaration.ts b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclaration.ts index 61afed81136..182404712f7 100644 --- a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclaration.ts +++ b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclaration.ts @@ -15,7 +15,7 @@ import { CancellationToken } from 'vs/base/common/cancellation'; import { asWinJsPromise } from 'vs/base/common/async'; import { Position } from 'vs/editor/common/core/position'; -function outputResults(promises: TPromise[]) { +function outputResults(promises: TPromise[]) { return TPromise.join(promises).then(allReferences => { let result: Location[] = []; for (let references of allReferences) { diff --git a/src/vs/editor/contrib/rename/browser/rename.ts b/src/vs/editor/contrib/rename/browser/rename.ts index 582e3a2ab4e..70fc125ffa5 100644 --- a/src/vs/editor/contrib/rename/browser/rename.ts +++ b/src/vs/editor/contrib/rename/browser/rename.ts @@ -38,7 +38,7 @@ export function rename(model: IReadOnlyModel, position: Position, newName: strin let hasResult = false; const factory = supports.map(support => { - return () => { + return (): TPromise => { if (!hasResult) { return asWinJsPromise((token) => { return support.provideRenameEdits(model, position, newName, token); diff --git a/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.ts b/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.ts index 896e593b005..0aa87cb7282 100644 --- a/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.ts +++ b/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.ts @@ -32,7 +32,7 @@ export function getOccurrencesAtPosition(model: editorCommon.IReadOnlyModel, pos // until someone response with a good result // (good = none empty array) return sequence(orderedByScore.map(provider => { - return () => { + return (): TPromise => { if (!foundResult) { return asWinJsPromise((token) => { return provider.provideDocumentHighlights(model, position, token); diff --git a/src/vs/platform/update/electron-main/updateService.ts b/src/vs/platform/update/electron-main/updateService.ts index aa3f75c6d51..4db56de6d64 100644 --- a/src/vs/platform/update/electron-main/updateService.ts +++ b/src/vs/platform/update/electron-main/updateService.ts @@ -44,8 +44,8 @@ export class UpdateService implements IUpdateService { private _onUpdateNotAvailable = new Emitter(); get onUpdateNotAvailable(): Event { return this._onUpdateNotAvailable.event; } - private _onUpdateReady = new Emitter(); - get onUpdateReady(): Event { return this._onUpdateReady.event; } + private _onUpdateReady = new Emitter(); + get onUpdateReady(): Event { return this._onUpdateReady.event; } private _onStateChange = new Emitter(); get onStateChange(): Event { return this._onStateChange.event; } @@ -180,7 +180,7 @@ export class UpdateService implements IUpdateService { this.telemetryService.publicLog('update:available', { explicit, version: update.version, currentVersion: product.commit }); } else { - const data: IUpdate = { + const data: IRawUpdate = { releaseNotes: update.releaseNotes, version: update.version, date: update.date diff --git a/src/vs/workbench/api/electron-browser/mainThreadTreeViews.ts b/src/vs/workbench/api/electron-browser/mainThreadTreeViews.ts index 6d41b483db6..b429be71710 100644 --- a/src/vs/workbench/api/electron-browser/mainThreadTreeViews.ts +++ b/src/vs/workbench/api/electron-browser/mainThreadTreeViews.ts @@ -40,8 +40,8 @@ type TreeItemHandle = number; class TreeViewDataProvider implements ITreeViewDataProvider { - private _onDidChange: Emitter = new Emitter(); - readonly onDidChange: Event = this._onDidChange.event; + private _onDidChange: Emitter = new Emitter(); + readonly onDidChange: Event = this._onDidChange.event; private childrenMap: Map = new Map(); private itemsMap: Map = new Map(); diff --git a/src/vs/workbench/parts/snippets/electron-browser/snippetsService.ts b/src/vs/workbench/parts/snippets/electron-browser/snippetsService.ts index 43fe76a8ce0..8e4f75e32ca 100644 --- a/src/vs/workbench/parts/snippets/electron-browser/snippetsService.ts +++ b/src/vs/workbench/parts/snippets/electron-browser/snippetsService.ts @@ -22,7 +22,7 @@ export interface ISnippetsService { registerSnippets(languageId: LanguageId, snippets: ISnippet[], owner: string): void; - visitSnippets(languageId: LanguageId, accept: (snippet: ISnippet) => void): void; + visitSnippets(languageId: LanguageId, accept: (snippet: ISnippet) => boolean): void; getSnippets(languageId: LanguageId): ISnippet[]; } diff --git a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts index 76a07d3b7a0..a4bfa6e87e1 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts @@ -213,7 +213,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { } if (task.command) { - return TPromise.join(promises).then((summaries): ITaskSummary => { + return TPromise.join(promises).then((summaries): TPromise | ITaskSummary => { for (let summary of summaries) { if (summary.exitCode !== 0) { return { exitCode: summary.exitCode }; diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalService.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalService.ts index 5c3a969a73a..e731656e46d 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalService.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalService.ts @@ -178,7 +178,7 @@ export class TerminalService extends AbstractTerminalService implements ITermina } return this._validateShellPaths(label, potentialPaths); } - return [label, current]; + return [label, current] as [string, string]; }); } -- GitLab From c47b702fa5b4f667cc63e5be9e519d3c9e89b0cb Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Wed, 7 Jun 2017 10:03:05 -0700 Subject: [PATCH 0612/1347] Refactoring toggleComment --- extensions/emmet/src/toggleComment.ts | 41 ++++++++++++--------------- 1 file changed, 18 insertions(+), 23 deletions(-) diff --git a/extensions/emmet/src/toggleComment.ts b/extensions/emmet/src/toggleComment.ts index 75c0791342d..1849535420c 100644 --- a/extensions/emmet/src/toggleComment.ts +++ b/extensions/emmet/src/toggleComment.ts @@ -43,21 +43,21 @@ export function toggleComment() { editor.edit(editBuilder => { editor.selections.reverse().forEach(selection => { - let [rangesToUnComment, positionForCommentStart, positionForCommentEnd] = toggleCommentInternal(editor.document, selection, rootNode); - rangesToUnComment.forEach(rangeToDelete => { - editBuilder.delete(rangeToDelete); + let [rangesToUnComment, rangeToComment] = toggleCommentInternal(editor.document, selection, rootNode); + rangesToUnComment.forEach((rangeToUnComment: vscode.Range) => { + editBuilder.delete(new vscode.Range(rangeToUnComment.start, rangeToUnComment.start.translate(0, startComment.length))); + editBuilder.delete(new vscode.Range(rangeToUnComment.end.translate(0, -endComment.length), rangeToUnComment.end)); }); - if (positionForCommentStart) { - editBuilder.insert(positionForCommentStart, startComment); - } - if (positionForCommentEnd) { - editBuilder.insert(positionForCommentEnd, endComment); + if (rangeToComment) { + editBuilder.insert(rangeToComment.start, startComment); + editBuilder.insert(rangeToComment.end, endComment); } + }); }); } -function toggleCommentHTML(document: vscode.TextDocument, selection: vscode.Selection, rootNode: Node): [vscode.Range[], vscode.Position, vscode.Position] { +function toggleCommentHTML(document: vscode.TextDocument, selection: vscode.Selection, rootNode: Node): [vscode.Range[], vscode.Range] { const selectionStart = document.offsetAt(selection.isReversed ? selection.active : selection.anchor); const selectionEnd = document.offsetAt(selection.isReversed ? selection.anchor : selection.active); @@ -65,7 +65,7 @@ function toggleCommentHTML(document: vscode.TextDocument, selection: vscode.Sele let endNode = getNode(rootNode, selectionEnd, true); if (!startNode || !endNode) { - return [[], null, null]; + return [[], null]; } let allNodes: Node[] = getNodesInBetween(startNode, endNode); @@ -76,12 +76,11 @@ function toggleCommentHTML(document: vscode.TextDocument, selection: vscode.Sele }); if (startNode.type === 'comment') { - return [rangesToUnComment, null, null]; + return [rangesToUnComment, null]; } - let positionForCommentStart = document.positionAt(allNodes[0].start); - let positionForCommentEnd = document.positionAt(allNodes[allNodes.length - 1].end); - return [rangesToUnComment, positionForCommentStart, positionForCommentEnd]; + let rangeToComment = new vscode.Range(document.positionAt(allNodes[0].start), document.positionAt(allNodes[allNodes.length - 1].end)); + return [rangesToUnComment, rangeToComment]; } function getRangesToUnCommentHTML(node: Node, document: vscode.TextDocument): vscode.Range[] { @@ -89,8 +88,7 @@ function getRangesToUnCommentHTML(node: Node, document: vscode.TextDocument): vs // If current node is commented, then uncomment and return if (node.type === 'comment') { - rangesToUnComment.push(new vscode.Range(document.positionAt(node.start), document.positionAt(node.start + startCommentHTML.length))); - rangesToUnComment.push(new vscode.Range(document.positionAt(node.end), document.positionAt(node.end - endCommentHTML.length))); + rangesToUnComment.push(new vscode.Range(document.positionAt(node.start), document.positionAt(node.end))); return rangesToUnComment; } @@ -103,7 +101,7 @@ function getRangesToUnCommentHTML(node: Node, document: vscode.TextDocument): vs return rangesToUnComment; } -function toggleCommentStylesheet(document: vscode.TextDocument, selection: vscode.Selection, rootNode: Node): [vscode.Range[], vscode.Position, vscode.Position] { +function toggleCommentStylesheet(document: vscode.TextDocument, selection: vscode.Selection, rootNode: Node): [vscode.Range[], vscode.Range] { const selectionStart = document.offsetAt(selection.isReversed ? selection.active : selection.anchor); const selectionEnd = document.offsetAt(selection.isReversed ? selection.anchor : selection.active); @@ -124,15 +122,12 @@ function toggleCommentStylesheet(document: vscode.TextDocument, selection: vscod } if (selection.contains(commentStart) || selection.contains(commentEnd) || (comment.start <= selectionStart && comment.end >= selectionEnd)) { - rangesToUnComment.push(new vscode.Range(document.positionAt(comment.start), document.positionAt(comment.start + startCommentStylesheet.length))); - rangesToUnComment.push(new vscode.Range(document.positionAt(comment.end), document.positionAt(comment.end - endCommentStylesheet.length))); + rangesToUnComment.push(new vscode.Range(document.positionAt(comment.start), document.positionAt(comment.end))); } }); - let positionForCommentStart = isFirstNodeCommented ? null : document.positionAt(startNode.start); - let positionForCommentEnd = isFirstNodeCommented ? null : document.positionAt(endNode.end); - - return [rangesToUnComment, positionForCommentStart, positionForCommentEnd]; + let rangeToComment = isFirstNodeCommented ? null : new vscode.Range(document.positionAt(startNode.start), document.positionAt(endNode.end)); + return [rangesToUnComment, rangeToComment]; } -- GitLab From fed8544b4f957194b6dc54fd51e16a1179472fb2 Mon Sep 17 00:00:00 2001 From: kieferrm Date: Wed, 7 Jun 2017 10:29:04 -0700 Subject: [PATCH 0613/1347] change formatOnPase default, fixed 28176 --- src/vs/editor/common/config/editorOptions.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/editor/common/config/editorOptions.ts b/src/vs/editor/common/config/editorOptions.ts index 89378c65bdc..3a16f7e183b 100644 --- a/src/vs/editor/common/config/editorOptions.ts +++ b/src/vs/editor/common/config/editorOptions.ts @@ -2143,7 +2143,7 @@ export const EDITOR_DEFAULTS: IValidatedEditorOptions = { parameterHints: true, iconsInSuggestions: true, formatOnType: false, - formatOnPaste: true, + formatOnPaste: false, suggestOnTriggerCharacters: true, acceptSuggestionOnEnter: 'on', acceptSuggestionOnCommitCharacter: true, -- GitLab From cbae4c6e2e8aaf3db1810925df13e21b1b820823 Mon Sep 17 00:00:00 2001 From: cleidigh Date: Wed, 7 Jun 2017 14:15:16 -0400 Subject: [PATCH 0614/1347] Add Debug Output Copy All command --- .../parts/debug/electron-browser/repl.ts | 38 +++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/src/vs/workbench/parts/debug/electron-browser/repl.ts b/src/vs/workbench/parts/debug/electron-browser/repl.ts index cf2e3937375..60cc87029cd 100644 --- a/src/vs/workbench/parts/debug/electron-browser/repl.ts +++ b/src/vs/workbench/parts/debug/electron-browser/repl.ts @@ -43,6 +43,7 @@ import { IListService } from 'vs/platform/list/browser/listService'; import { attachListStyler } from 'vs/platform/theme/common/styler'; import { IEditorOptions } from 'vs/editor/common/config/editorOptions'; import { IThemeService } from 'vs/platform/theme/common/themeService'; +import { clipboard } from 'electron'; const $ = dom.$; @@ -59,6 +60,7 @@ export interface IPrivateReplService { _serviceBrand: any; navigateHistory(previous: boolean): void; acceptReplInput(): void; + copyAllReplOutput(): void; } export class Repl extends Panel implements IPrivateReplService { @@ -230,6 +232,19 @@ export class Repl extends Panel implements IPrivateReplService { this.layout(this.dimension); } + public copyAllReplOutput(): void { + let text = ''; + const navigator = this.tree.getNavigator(); + // skip first navigator element - the root node + while (navigator.next()) { + if (text) { + text += `\n`; + } + text += navigator.current().toString(); + } + clipboard.writeText(text); + } + public layout(dimension: Dimension): void { this.dimension = dimension; if (this.tree) { @@ -375,3 +390,26 @@ CommonEditorRegistry.registerEditorCommand(new SuggestCommand({ primary: KeyCode.RightArrow } })); + +@editorAction +class ReplCopyAllAction extends EditorAction { + + constructor() { + super({ + id: 'repl.action.copyall', + label: nls.localize('actions.repl.copyall', "Debug Copy All"), + alias: 'Debug Copy All', + precondition: debug.CONTEXT_IN_DEBUG_REPL, + kbOpts: { + kbExpr: null, + primary: null, + weight: 50 + } + + }); + } + + public run(accessor: ServicesAccessor, editor: ICommonCodeEditor): void | TPromise { + accessor.get(IPrivateReplService).copyAllReplOutput(); + } +} -- GitLab From 6ff1da8d30255afe4ca67ec6813644a2628dee48 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Wed, 7 Jun 2017 10:28:39 -0700 Subject: [PATCH 0615/1347] Separate Completion Provider for Emmet Css --- .../emmet/src/emmetCompletionProvider.ts | 141 +++++++++++------- extensions/emmet/src/extension.ts | 26 ++-- 2 files changed, 100 insertions(+), 67 deletions(-) diff --git a/extensions/emmet/src/emmetCompletionProvider.ts b/extensions/emmet/src/emmetCompletionProvider.ts index 9a84da40c31..5f1a641eef2 100644 --- a/extensions/emmet/src/emmetCompletionProvider.ts +++ b/extensions/emmet/src/emmetCompletionProvider.ts @@ -6,12 +6,12 @@ import * as vscode from 'vscode'; import { expand, createSnippetsRegistry } from '@emmetio/expand-abbreviation'; -import { getSyntax, isStyleSheet, getProfile, extractAbbreviation } from './util'; +import { getSyntax, getProfile, extractAbbreviation } from './util'; const field = (index, placeholder) => `\${${index}${placeholder ? ':' + placeholder : ''}}`; const snippetCompletionsCache = new Map(); -export class EmmetCompletionItemProvider implements vscode.CompletionItemProvider { +abstract class EmmetCompletionItemProviderBase implements vscode.CompletionItemProvider { public provideCompletionItems(document: vscode.TextDocument, position: vscode.Position, token: vscode.CancellationToken): Thenable { @@ -20,42 +20,97 @@ export class EmmetCompletionItemProvider implements vscode.CompletionItemProvide } let currentWord = getCurrentWord(document, position); - let expandedAbbr = getExpandedAbbreviation(document, position); - let abbreviationSuggestions = getAbbreviationSuggestions(getSyntax(document), currentWord, (expandedAbbr && currentWord === expandedAbbr.label)); + let expandedAbbr = this.getExpandedAbbreviation(document, position); + let abbreviationSuggestions = this.getAbbreviationSuggestions(getSyntax(document), currentWord, (expandedAbbr && currentWord === expandedAbbr.label)); let completionItems = expandedAbbr ? [expandedAbbr, ...abbreviationSuggestions] : abbreviationSuggestions; return Promise.resolve(new vscode.CompletionList(completionItems, true)); } + + protected getExpandedAbbreviation(document: vscode.TextDocument, position: vscode.Position): vscode.CompletionItem { + if (!vscode.workspace.getConfiguration('emmet')['showExpandedAbbreviation']) { + return; + } + let [rangeToReplace, wordToExpand] = extractAbbreviation(position); + if (!rangeToReplace || !wordToExpand) { + return; + } + let syntax = getSyntax(document); + let expandedWord = expand(wordToExpand, { + field: field, + syntax: syntax, + profile: getProfile(syntax), + addons: syntax === 'jsx' ? { 'jsx': true } : null + }); + + let completionitem = new vscode.CompletionItem(wordToExpand); + completionitem.insertText = new vscode.SnippetString(expandedWord); + completionitem.documentation = removeTabStops(expandedWord); + completionitem.range = rangeToReplace; + completionitem.detail = 'Expand Emmet Abbreviation'; + + + return completionitem; + } + + abstract getAbbreviationSuggestions(syntax: string, prefix: string, skipExactMatch: boolean): vscode.CompletionItem[]; + } -function getExpandedAbbreviation(document: vscode.TextDocument, position: vscode.Position): vscode.CompletionItem { - if (!vscode.workspace.getConfiguration('emmet')['showExpandedAbbreviation']) { - return; +export class EmmetCompletionItemProviderHtml extends EmmetCompletionItemProviderBase { + + protected getExpandedAbbreviation(document: vscode.TextDocument, position: vscode.Position): vscode.CompletionItem { + let completionItem = super.getExpandedAbbreviation(document, position); + + // In non stylesheet like syntax, this extension returns expanded abbr plus posssible abbr completions + // To differentiate between the 2, the former is given CompletionItemKind.Value so that it gets a different icon + completionItem.kind = vscode.CompletionItemKind.Value; + + return completionItem; + } + + getAbbreviationSuggestions(syntax: string, prefix: string, skipExactMatch: boolean) { + if (!vscode.workspace.getConfiguration('emmet')['showAbbreviationSuggestions'] || !prefix) { + return []; + } + + if (!snippetCompletionsCache.has(syntax)) { + let registry = createSnippetsRegistry(syntax); + let completions: vscode.CompletionItem[] = registry.all({ type: 'string' }).map(snippet => { + let expandedWord = expand(snippet.value, { + field: field, + syntax: syntax + }); + + let item = new vscode.CompletionItem(snippet.key); + item.documentation = removeTabStops(expandedWord); + item.detail = 'Complete Emmet Abbreviation'; + item.insertText = snippet.key; + return item; + }); + snippetCompletionsCache.set(syntax, completions); + } + + let snippetCompletions = snippetCompletionsCache.get(syntax); + + snippetCompletions = snippetCompletions.filter(x => x.label.startsWith(prefix) && (!skipExactMatch || x.label !== prefix)); + + return snippetCompletions; + } - let [rangeToReplace, wordToExpand] = extractAbbreviation(position); - if (!rangeToReplace || !wordToExpand) { - return; + + +} + +export class EmmetCompletionItemProviderCss extends EmmetCompletionItemProviderBase { + public provideCompletionItems(document: vscode.TextDocument, position: vscode.Position, token: vscode.CancellationToken): Thenable { + return super.provideCompletionItems(document, position, token); } - let syntax = getSyntax(document); - let expandedWord = expand(wordToExpand, { - field: field, - syntax: syntax, - profile: getProfile(syntax), - addons: syntax === 'jsx' ? { 'jsx': true } : null - }); - - let completionitem = new vscode.CompletionItem(wordToExpand); - completionitem.insertText = new vscode.SnippetString(expandedWord); - completionitem.documentation = removeTabStops(expandedWord); - completionitem.range = rangeToReplace; - completionitem.detail = 'Expand Emmet Abbreviation'; - - // In non stylesheet like syntax, this extension returns expanded abbr plus posssible abbr completions - // To differentiate between the 2, the former is given CompletionItemKind.Value so that it gets a different icon - if (!isStyleSheet(syntax)) { - completionitem.kind = vscode.CompletionItemKind.Value; + + getAbbreviationSuggestions(syntax: string, prefix: string, skipExactMatch: boolean) { + return []; } - return completionitem; + } function getCurrentWord(document: vscode.TextDocument, position: vscode.Position): string { @@ -72,35 +127,7 @@ function getCurrentWord(document: vscode.TextDocument, position: vscode.Position function removeTabStops(expandedWord: string): string { return expandedWord.replace(/\$\{\d+\}/g, '').replace(/\$\{\d+:([^\}]+)\}/g, '$1'); } -function getAbbreviationSuggestions(syntax: string, prefix: string, skipExactMatch: boolean) { - if (!vscode.workspace.getConfiguration('emmet')['showAbbreviationSuggestions'] || !prefix || isStyleSheet(syntax)) { - return []; - } - - if (!snippetCompletionsCache.has(syntax)) { - let registry = createSnippetsRegistry(syntax); - let completions: vscode.CompletionItem[] = registry.all({ type: 'string' }).map(snippet => { - let expandedWord = expand(snippet.value, { - field: field, - syntax: syntax - }); - - let item = new vscode.CompletionItem(snippet.key); - item.documentation = removeTabStops(expandedWord); - item.detail = 'Complete Emmet Abbreviation'; - item.insertText = snippet.key; - return item; - }); - snippetCompletionsCache.set(syntax, completions); - } - - let snippetCompletions = snippetCompletionsCache.get(syntax); - - snippetCompletions = snippetCompletions.filter(x => x.label.startsWith(prefix) && (!skipExactMatch || x.label !== prefix)); - return snippetCompletions; - -} diff --git a/extensions/emmet/src/extension.ts b/extensions/emmet/src/extension.ts index 620df18dc32..23f9190743d 100644 --- a/extensions/emmet/src/extension.ts +++ b/extensions/emmet/src/extension.ts @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ import * as vscode from 'vscode'; -import { EmmetCompletionItemProvider } from './emmetCompletionProvider'; +import { EmmetCompletionItemProviderHtml, EmmetCompletionItemProviderCss } from './emmetCompletionProvider'; import { expandAbbreviation, wrapWithAbbreviation } from './abbreviationActions'; import { removeTag } from './removeTag'; import { updateTag } from './updateTag'; @@ -21,7 +21,7 @@ interface ISupportedLanguageMode { triggerCharacters: string[]; } -const SUPPORTED_LANGUAGE_MODES: ISupportedLanguageMode[] = [ +const HTML_LANGUAGE_MODES: ISupportedLanguageMode[] = [ { id: 'html', triggerCharacters: ['!', '.', '}'] }, { id: 'jade', triggerCharacters: ['!', '.', '}'] }, { id: 'slim', triggerCharacters: ['!', '.', '}'] }, @@ -29,23 +29,29 @@ const SUPPORTED_LANGUAGE_MODES: ISupportedLanguageMode[] = [ { id: 'xml', triggerCharacters: ['.', '}'] }, { id: 'xsl', triggerCharacters: ['.', '}'] }, + { id: 'javascriptreact', triggerCharacters: ['.'] }, + { id: 'typescriptreact', triggerCharacters: ['.'] } +]; + +const CSS_LANGUAGE_MODES: ISupportedLanguageMode[] = [ { id: 'css', triggerCharacters: [':'] }, { id: 'scss', triggerCharacters: [':'] }, { id: 'sass', triggerCharacters: [':'] }, { id: 'less', triggerCharacters: [':'] }, - { id: 'stylus', triggerCharacters: [':'] }, - - { id: 'javascriptreact', triggerCharacters: ['.'] }, - { id: 'typescriptreact', triggerCharacters: ['.'] } + { id: 'stylus', triggerCharacters: [':'] } ]; export function activate(context: vscode.ExtensionContext) { - let completionProvider = new EmmetCompletionItemProvider(); + let completionProviderHtml = new EmmetCompletionItemProviderHtml(); + let completionProviderCss = new EmmetCompletionItemProviderCss(); - for (let language of SUPPORTED_LANGUAGE_MODES) { - const selector: vscode.DocumentFilter = { language: language.id }; - const provider = vscode.languages.registerCompletionItemProvider(selector, completionProvider, ...language.triggerCharacters); + for (let language of HTML_LANGUAGE_MODES) { + const provider = vscode.languages.registerCompletionItemProvider({ language: language.id }, completionProviderHtml, ...language.triggerCharacters); + context.subscriptions.push(provider); + } + for (let language of CSS_LANGUAGE_MODES) { + const provider = vscode.languages.registerCompletionItemProvider({ language: language.id }, completionProviderCss, ...language.triggerCharacters); context.subscriptions.push(provider); } -- GitLab From 28709b648b77dadf2b760bd112ee14ca6b99cc4b Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Wed, 7 Jun 2017 12:42:38 -0700 Subject: [PATCH 0616/1347] Enable new emmet by default, add toggle comment feature --- .../parts/emmet/electron-browser/emmet.contribution.ts | 2 +- src/vs/workbench/parts/emmet/electron-browser/emmetActions.ts | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.ts b/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.ts index e27026f8a0b..efa85ca249e 100644 --- a/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.ts +++ b/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.ts @@ -62,7 +62,7 @@ configurationRegistry.registerConfiguration({ }, 'emmet.useNewEmmet': { 'type': 'boolean', - 'default': false, + 'default': true, 'description': nls.localize('useNewEmmet', 'Try out the new emmet modules (which will eventually replace the old single emmet library) for all emmet features.') } } diff --git a/src/vs/workbench/parts/emmet/electron-browser/emmetActions.ts b/src/vs/workbench/parts/emmet/electron-browser/emmetActions.ts index e6f0e88243b..a313f378b21 100644 --- a/src/vs/workbench/parts/emmet/electron-browser/emmetActions.ts +++ b/src/vs/workbench/parts/emmet/electron-browser/emmetActions.ts @@ -249,7 +249,8 @@ export abstract class EmmetEditorAction extends EditorAction { 'editor.emmet.action.mergeLines': 'emmet.mergeLines', 'editor.emmet.action.selectPreviousItem': 'emmet.selectPrevItem', 'editor.emmet.action.selectNextItem': 'emmet.selectNextItem', - 'editor.emmet.action.splitJoinTag': 'emmet.splitJoinTag' + 'editor.emmet.action.splitJoinTag': 'emmet.splitJoinTag', + 'editor.emmet.action.toggleComment': 'emmet.toggleComment' }; protected emmetActionName: string; -- GitLab From 61377c23b0a21009a0e05dbec939dc66afbd5f23 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Wed, 7 Jun 2017 12:51:58 -0700 Subject: [PATCH 0617/1347] Fix build error --- extensions/emmet/src/emmetCompletionProvider.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/emmet/src/emmetCompletionProvider.ts b/extensions/emmet/src/emmetCompletionProvider.ts index 5f1a641eef2..acab02d57a5 100644 --- a/extensions/emmet/src/emmetCompletionProvider.ts +++ b/extensions/emmet/src/emmetCompletionProvider.ts @@ -11,7 +11,7 @@ import { getSyntax, getProfile, extractAbbreviation } from './util'; const field = (index, placeholder) => `\${${index}${placeholder ? ':' + placeholder : ''}}`; const snippetCompletionsCache = new Map(); -abstract class EmmetCompletionItemProviderBase implements vscode.CompletionItemProvider { +export abstract class EmmetCompletionItemProviderBase implements vscode.CompletionItemProvider { public provideCompletionItems(document: vscode.TextDocument, position: vscode.Position, token: vscode.CancellationToken): Thenable { -- GitLab From 69977be4a1bf14256f9bd870207e995552c05144 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Wed, 7 Jun 2017 12:55:15 -0700 Subject: [PATCH 0618/1347] Use beta xterm.js build --- npm-shrinkwrap.json | 6 +++--- package.json | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/npm-shrinkwrap.json b/npm-shrinkwrap.json index 3e962373c7d..9d6c80bfb68 100644 --- a/npm-shrinkwrap.json +++ b/npm-shrinkwrap.json @@ -440,9 +440,9 @@ "resolved": "https://registry.npmjs.org/winreg/-/winreg-1.2.0.tgz" }, "xterm": { - "version": "2.6.0", - "from": "Tyriar/xterm.js#vscode-release/1.13", - "resolved": "git+https://github.com/Tyriar/xterm.js.git#32c9eac8ee5a958093d126a06c1c06a7cd6052bf" + "version": "2.7.0", + "from": "Tyriar/xterm.js#vscode-release/1.14-beta", + "resolved": "git+https://github.com/Tyriar/xterm.js.git#2697bd2f9560b7ce28cfcd368cd68008276219a0" }, "yauzl": { "version": "2.3.1", diff --git a/package.json b/package.json index 333ee2253b6..588c630f9af 100644 --- a/package.json +++ b/package.json @@ -42,7 +42,7 @@ "vscode-ripgrep": "0.0.12", "vscode-textmate": "^3.1.5", "winreg": "1.2.0", - "xterm": "Tyriar/xterm.js#vscode-release/1.13", + "xterm": "Tyriar/xterm.js#vscode-release/1.14-beta", "yauzl": "2.3.1" }, "devDependencies": { -- GitLab From 68f9d22c6ccc8aee617a1cfacd3f0103ca16537a Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Wed, 7 Jun 2017 12:55:57 -0700 Subject: [PATCH 0619/1347] Integrate new xterm.js changes --- .../terminal/electron-browser/media/xterm.css | 17 +++++++++++++++++ .../electron-browser/terminalInstance.ts | 18 ++++++++++-------- 2 files changed, 27 insertions(+), 8 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/xterm.css b/src/vs/workbench/parts/terminal/electron-browser/media/xterm.css index 4ee863dbecb..a2b453ef228 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/media/xterm.css +++ b/src/vs/workbench/parts/terminal/electron-browser/media/xterm.css @@ -6,6 +6,7 @@ .monaco-workbench .panel.integrated-terminal .xterm { position: relative; height: 100%; + user-select: none; } .monaco-workbench .panel.integrated-terminal .xterm:focus { @@ -170,6 +171,22 @@ left: -9999em; } +.monaco-workbench .panel.integrated-terminal .xterm.enable-mouse-events { + /* When mouse events are enabled (eg. tmux), revert to the standard pointer cursor */ + cursor: default; +} + +.monaco-workbench .panel.integrated-terminal .xterm .xterm-selection { + position: absolute; + left: 0; + bottom: 0; +} + +.monaco-workbench .panel.integrated-terminal .xterm .xterm-selection div { + position: absolute; + background-color: #555; +} + .monaco-workbench .panel.integrated-terminal .xterm .xterm-bold { font-weight: bold; } diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index 4b70c062ba8..1db0be29dd7 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -31,7 +31,8 @@ import { TerminalLinkHandler } from 'vs/workbench/parts/terminal/electron-browse import { TerminalWidgetManager } from 'vs/workbench/parts/terminal/browser/terminalWidgetManager'; import { registerThemingParticipant, ITheme, ICssStyleCollector } from 'vs/platform/theme/common/themeService'; import { scrollbarSliderBackground, scrollbarSliderHoverBackground, scrollbarSliderActiveBackground } from 'vs/platform/theme/common/colorRegistry'; -import { TPromise } from "vs/base/common/winjs.base"; +import { TPromise } from 'vs/base/common/winjs.base'; +import { IClipboardService } from 'vs/platform/clipboard/common/clipboardService'; /** The amount of time to consider terminal errors to be related to the launch */ const LAUNCHING_DURATION = 500; @@ -99,7 +100,8 @@ export class TerminalInstance implements ITerminalInstance { @IPanelService private _panelService: IPanelService, @IWorkspaceContextService private _contextService: IWorkspaceContextService, @IWorkbenchEditorService private _editorService: IWorkbenchEditorService, - @IInstantiationService private _instantiationService: IInstantiationService + @IInstantiationService private _instantiationService: IInstantiationService, + @IClipboardService private _clipboardService: IClipboardService ) { this._instanceDisposables = []; this._processDisposables = []; @@ -323,14 +325,14 @@ export class TerminalInstance implements ITerminalInstance { } public hasSelection(): boolean { - return !document.getSelection().isCollapsed; + return this._xterm.hasSelection(); } public copySelection(): void { - if (document.activeElement.classList.contains('xterm')) { - document.execCommand('copy'); + if (this.hasSelection()) { + this._clipboardService.writeText(this._xterm.getSelection()); } else { - this._messageService.show(Severity.Warning, nls.localize('terminal.integrated.copySelection.noSelection', 'Cannot copy terminal selection when terminal does not have focus')); + this._messageService.show(Severity.Warning, nls.localize('terminal.integrated.copySelection.noSelection', 'The terminal has no selection to copy')); } } @@ -439,8 +441,8 @@ export class TerminalInstance implements ITerminalInstance { private _refreshSelectionContextKey() { const activePanel = this._panelService.getActivePanel(); - const isFocused = activePanel && activePanel.getId() === TERMINAL_PANEL_ID; - this._terminalHasTextContextKey.set(isFocused && !window.getSelection().isCollapsed); + const isActive = activePanel && activePanel.getId() === TERMINAL_PANEL_ID; + this._terminalHasTextContextKey.set(isActive && this.hasSelection()); } private _sanitizeInput(data: any) { -- GitLab From 50c2bc406e5cbda99a137f2f382c4c84e734439f Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Wed, 7 Jun 2017 13:34:12 -0700 Subject: [PATCH 0620/1347] Fix clear selection, add select all command --- npm-shrinkwrap.json | 2 +- .../parts/terminal/common/terminal.ts | 5 +++++ .../electron-browser/terminal.contribution.ts | 14 +++++++++++-- .../electron-browser/terminalActions.ts | 21 +++++++++++++++++++ .../electron-browser/terminalInstance.ts | 6 +++++- 5 files changed, 44 insertions(+), 4 deletions(-) diff --git a/npm-shrinkwrap.json b/npm-shrinkwrap.json index 9d6c80bfb68..91bff39ee52 100644 --- a/npm-shrinkwrap.json +++ b/npm-shrinkwrap.json @@ -442,7 +442,7 @@ "xterm": { "version": "2.7.0", "from": "Tyriar/xterm.js#vscode-release/1.14-beta", - "resolved": "git+https://github.com/Tyriar/xterm.js.git#2697bd2f9560b7ce28cfcd368cd68008276219a0" + "resolved": "git+https://github.com/Tyriar/xterm.js.git#2c61d9c26c0265b8a4ce1542d25dd1258c3e4f5b" }, "yauzl": { "version": "2.3.1", diff --git a/src/vs/workbench/parts/terminal/common/terminal.ts b/src/vs/workbench/parts/terminal/common/terminal.ts index 1093b3ee7e0..e2458c190e7 100644 --- a/src/vs/workbench/parts/terminal/common/terminal.ts +++ b/src/vs/workbench/parts/terminal/common/terminal.ts @@ -230,6 +230,11 @@ export interface ITerminalInstance { */ clearSelection(): void; + /** + * Select all text in the terminal. + */ + selectAll(): void; + /** * Focuses the terminal instance. * diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts index 94e7e9a4b52..09af3cb19c6 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts @@ -18,7 +18,7 @@ import { TERMINAL_DEFAULT_SHELL_LINUX, TERMINAL_DEFAULT_SHELL_OSX, TERMINAL_DEFA import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/workbench/common/actionRegistry'; import { KeyCode, KeyMod } from 'vs/base/common/keyCodes'; import { ContextKeyExpr } from 'vs/platform/contextkey/common/contextkey'; -import { KillTerminalAction, CopyTerminalSelectionAction, CreateNewTerminalAction, FocusActiveTerminalAction, FocusNextTerminalAction, FocusPreviousTerminalAction, FocusTerminalAtIndexAction, SelectDefaultShellWindowsTerminalAction, RunSelectedTextInTerminalAction, RunActiveFileInTerminalAction, ScrollDownTerminalAction, ScrollDownPageTerminalAction, ScrollToBottomTerminalAction, ScrollUpTerminalAction, ScrollUpPageTerminalAction, ScrollToTopTerminalAction, TerminalPasteAction, ToggleTerminalAction, ClearTerminalAction, AllowWorkspaceShellTerminalCommand, DisallowWorkspaceShellTerminalCommand } from 'vs/workbench/parts/terminal/electron-browser/terminalActions'; +import { KillTerminalAction, CopyTerminalSelectionAction, CreateNewTerminalAction, FocusActiveTerminalAction, FocusNextTerminalAction, FocusPreviousTerminalAction, FocusTerminalAtIndexAction, SelectDefaultShellWindowsTerminalAction, RunSelectedTextInTerminalAction, RunActiveFileInTerminalAction, ScrollDownTerminalAction, ScrollDownPageTerminalAction, ScrollToBottomTerminalAction, ScrollUpTerminalAction, ScrollUpPageTerminalAction, ScrollToTopTerminalAction, TerminalPasteAction, ToggleTerminalAction, ClearTerminalAction, AllowWorkspaceShellTerminalCommand, DisallowWorkspaceShellTerminalCommand, SelectAllTerminalAction } from 'vs/workbench/parts/terminal/electron-browser/terminalActions'; import { Registry } from 'vs/platform/platform'; import { ShowAllCommandsAction } from 'vs/workbench/parts/quickopen/browser/commandsHandler'; import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; @@ -185,7 +185,8 @@ configurationRegistry.registerConfiguration({ OpenPreviousRecentlyUsedEditorInGroupAction.ID, FocusFirstGroupAction.ID, FocusSecondGroupAction.ID, - FocusThirdGroupAction.ID + FocusThirdGroupAction.ID, + SelectAllTerminalAction.ID ].sort() } } @@ -229,6 +230,15 @@ actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(TerminalPasteAct // Don't apply to Mac since cmd+v works mac: { primary: null } }, KEYBINDING_CONTEXT_TERMINAL_FOCUS), 'Terminal: Paste into Active Terminal', category); +actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(SelectAllTerminalAction, SelectAllTerminalAction.ID, SelectAllTerminalAction.LABEL, { + // Don't use ctrl+a by default as that would override the common go to start + // of prompt shell binding + primary: null, + // Technically this doesn't need to be here as it will fall back to this + // behavior anyway when handed to xterm.js, having this handled by VS Code + // makes it easier for users to see how it works though. + mac: { primary: KeyMod.CtrlCmd | KeyCode.KEY_A } +}, KEYBINDING_CONTEXT_TERMINAL_FOCUS), 'Terminal: Select All', category); actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(RunSelectedTextInTerminalAction, RunSelectedTextInTerminalAction.ID, RunSelectedTextInTerminalAction.LABEL), 'Terminal: Run Selected Text In Active Terminal', category); actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(RunActiveFileInTerminalAction, RunActiveFileInTerminalAction.ID, RunActiveFileInTerminalAction.LABEL), 'Terminal: Run Active File In Active Terminal', category); actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(ToggleTerminalAction, ToggleTerminalAction.ID, ToggleTerminalAction.LABEL, { diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts index 3b62f9642ed..62780aee350 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts @@ -93,6 +93,27 @@ export class CopyTerminalSelectionAction extends Action { } } +export class SelectAllTerminalAction extends Action { + + public static ID = 'workbench.action.terminal.selectAll'; + public static LABEL = nls.localize('workbench.action.terminal.selectAll', "Select All"); + + constructor( + id: string, label: string, + @ITerminalService private terminalService: ITerminalService + ) { + super(id, label); + } + + public run(event?: any): TPromise { + let terminalInstance = this.terminalService.getActiveInstance(); + if (terminalInstance) { + terminalInstance.selectAll(); + } + return TPromise.as(void 0); + } +} + export class CreateNewTerminalAction extends Action { public static ID = 'workbench.action.terminal.new'; diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index 1db0be29dd7..919dd7dbdff 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -337,7 +337,11 @@ export class TerminalInstance implements ITerminalInstance { } public clearSelection(): void { - window.getSelection().empty(); + this._xterm.clearSelection(); + } + + public selectAll(): void { + this._xterm.selectAll(); } public dispose(): void { -- GitLab From 06dfe10a38e94e48ffd330f833fe9588e66e29dc Mon Sep 17 00:00:00 2001 From: Nick Snyder Date: Tue, 6 Jun 2017 07:47:57 -0700 Subject: [PATCH 0621/1347] Don't hardcode number of result providers Minor refactor. Does not change any logic. --- .../parts/search/browser/openAnythingHandler.ts | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/src/vs/workbench/parts/search/browser/openAnythingHandler.ts b/src/vs/workbench/parts/search/browser/openAnythingHandler.ts index cc77586caa2..a020b745e46 100644 --- a/src/vs/workbench/parts/search/browser/openAnythingHandler.ts +++ b/src/vs/workbench/parts/search/browser/openAnythingHandler.ts @@ -166,8 +166,6 @@ export class OpenAnythingHandler extends QuickOpenHandler { // Symbol Results (unless disabled or a range or absolute path is specified) if (this.includeSymbols && !searchWithRange) { resultPromises.push(this.openSymbolHandler.getResults(searchValue)); - } else { - resultPromises.push(TPromise.as(new QuickOpenModel())); // We need this empty promise because we are using the throttler below! } // Join and sort unified @@ -179,8 +177,10 @@ export class OpenAnythingHandler extends QuickOpenHandler { return TPromise.as(new QuickOpenModel()); } - // Combine file results and symbol results (if any) - const mergedResults = [...results[0].entries, ...results[1].entries]; + // Combine results. + const mergedResults: QuickOpenEntry[] = results.reduce((entries: QuickOpenEntry[], model: QuickOpenModel) => { + return entries.concat(model.entries); + }, []); // Sort const unsortedResultTime = Date.now(); @@ -200,10 +200,11 @@ export class OpenAnythingHandler extends QuickOpenHandler { }); let fileSearchStats: ISearchStats; - if (results[0] instanceof FileQuickOpenModel) { - fileSearchStats = (results[0]).stats; - } else if (results[1] instanceof FileQuickOpenModel) { - fileSearchStats = (results[1]).stats; + for (const result of results) { + if (result instanceof FileQuickOpenModel) { + fileSearchStats = (result).stats; + break; + } } const duration = new Date().getTime() - startTime; -- GitLab From 00a276cf8c76eefc5823e78f03dfde0c217e4f4c Mon Sep 17 00:00:00 2001 From: Nick Snyder Date: Wed, 7 Jun 2017 12:01:17 -0700 Subject: [PATCH 0622/1347] filePromise --- .../search/browser/openAnythingHandler.ts | 31 ++++++++----------- 1 file changed, 13 insertions(+), 18 deletions(-) diff --git a/src/vs/workbench/parts/search/browser/openAnythingHandler.ts b/src/vs/workbench/parts/search/browser/openAnythingHandler.ts index a020b745e46..2846c6243d3 100644 --- a/src/vs/workbench/parts/search/browser/openAnythingHandler.ts +++ b/src/vs/workbench/parts/search/browser/openAnythingHandler.ts @@ -161,7 +161,8 @@ export class OpenAnythingHandler extends QuickOpenHandler { const resultPromises: TPromise[] = []; // File Results - resultPromises.push(this.openFileHandler.getResults(searchValue, OpenAnythingHandler.MAX_DISPLAYED_RESULTS)); + const filePromise = this.openFileHandler.getResults(searchValue, OpenAnythingHandler.MAX_DISPLAYED_RESULTS); + resultPromises.push(filePromise); // Symbol Results (unless disabled or a range or absolute path is specified) if (this.includeSymbols && !searchWithRange) { @@ -199,26 +200,20 @@ export class OpenAnythingHandler extends QuickOpenHandler { } }); - let fileSearchStats: ISearchStats; - for (const result of results) { - if (result instanceof FileQuickOpenModel) { - fileSearchStats = (result).stats; - break; - } - } - const duration = new Date().getTime() - startTime; - const data = this.createTimerEventData(startTime, { - searchLength: searchValue.length, - unsortedResultTime, - sortedResultTime, - resultCount: mergedResults.length, - symbols: { fromCache: false }, - files: fileSearchStats + filePromise.then(fileModel => { + const data = this.createTimerEventData(startTime, { + searchLength: searchValue.length, + unsortedResultTime, + sortedResultTime, + resultCount: mergedResults.length, + symbols: { fromCache: false }, + files: fileModel.stats, + }); + + this.telemetryService.publicLog('openAnything', objects.assign(data, { duration })); }); - this.telemetryService.publicLog('openAnything', objects.assign(data, { duration })); - return TPromise.as(new QuickOpenModel(viewResults)); }, (error: Error) => { this.pendingSearch = null; -- GitLab From 61fa6e8f5d94070d6ba868548a7b84e2712c9a38 Mon Sep 17 00:00:00 2001 From: Nick Snyder Date: Wed, 7 Jun 2017 12:02:31 -0700 Subject: [PATCH 0623/1347] Concat instead of reduce --- src/vs/workbench/parts/search/browser/openAnythingHandler.ts | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/vs/workbench/parts/search/browser/openAnythingHandler.ts b/src/vs/workbench/parts/search/browser/openAnythingHandler.ts index 2846c6243d3..e777cc9311f 100644 --- a/src/vs/workbench/parts/search/browser/openAnythingHandler.ts +++ b/src/vs/workbench/parts/search/browser/openAnythingHandler.ts @@ -179,9 +179,7 @@ export class OpenAnythingHandler extends QuickOpenHandler { } // Combine results. - const mergedResults: QuickOpenEntry[] = results.reduce((entries: QuickOpenEntry[], model: QuickOpenModel) => { - return entries.concat(model.entries); - }, []); + const mergedResults = [].concat(...results.map(r => r.entries)); // Sort const unsortedResultTime = Date.now(); -- GitLab From 4fce291653da4dca159bd07fb4039c7532268f71 Mon Sep 17 00:00:00 2001 From: Andre Weinand Date: Wed, 7 Jun 2017 23:22:45 +0200 Subject: [PATCH 0624/1347] node-debug@1.14.0 --- build/gulpfile.vscode.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index 4c394e8c629..2aa62f99f33 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -42,7 +42,7 @@ const nodeModules = ['electron', 'original-fs'] // Build const builtInExtensions = [ - { name: 'ms-vscode.node-debug', version: '1.13.10' }, + { name: 'ms-vscode.node-debug', version: '1.14.0' }, { name: 'ms-vscode.node-debug2', version: '1.13.3' } ]; -- GitLab From a757842135bd3b08c76eeb293c9c43e06c65f2f7 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 7 Jun 2017 14:28:21 -0700 Subject: [PATCH 0625/1347] Simplify logging of TS request errors Fixes #28095 Removes the manual error logging on client requests in favor of doing this automatically in the service client. Also fixes logging of canellation errors --- .../src/features/baseCodeLensProvider.ts | 3 +- .../src/features/completionItemProvider.ts | 6 +-- .../src/features/definitionProviderBase.ts | 3 +- .../src/features/documentHighlightProvider.ts | 3 +- .../src/features/documentSymbolProvider.ts | 7 +--- .../src/features/formattingProvider.ts | 6 +-- .../typescript/src/features/hoverProvider.ts | 3 +- .../src/features/referenceProvider.ts | 3 +- .../typescript/src/features/renameProvider.ts | 3 +- .../src/features/signatureHelpProvider.ts | 3 +- .../src/features/workspaceSymbolProvider.ts | 3 +- .../typescript/src/typescriptService.ts | 2 - .../typescript/src/typescriptServiceClient.ts | 40 ++++++++++--------- 13 files changed, 36 insertions(+), 49 deletions(-) diff --git a/extensions/typescript/src/features/baseCodeLensProvider.ts b/extensions/typescript/src/features/baseCodeLensProvider.ts index 20952150c4b..84ba69a0a96 100644 --- a/extensions/typescript/src/features/baseCodeLensProvider.ts +++ b/extensions/typescript/src/features/baseCodeLensProvider.ts @@ -56,8 +56,7 @@ export abstract class TypeScriptBaseCodeLensProvider implements CodeLensProvider tree.childItems.forEach(item => this.walkNavTree(document, item, null, referenceableSpans)); } return referenceableSpans.map(span => new ReferencesCodeLens(document.uri, filepath, span)); - }, (err: any) => { - this.client.error(`'navtree' request failed with error.`, err); + }, () => { return []; }); } diff --git a/extensions/typescript/src/features/completionItemProvider.ts b/extensions/typescript/src/features/completionItemProvider.ts index 5f0740be10c..90a3f56b30e 100644 --- a/extensions/typescript/src/features/completionItemProvider.ts +++ b/extensions/typescript/src/features/completionItemProvider.ts @@ -223,8 +223,7 @@ export default class TypeScriptCompletionItemProvider implements CompletionItemP } return completionItems; - }, (err) => { - this.client.error(`'completions' request failed with error.`, err); + }, () => { return []; }); } @@ -264,8 +263,7 @@ export default class TypeScriptCompletionItemProvider implements CompletionItemP } return item; - }, (err) => { - this.client.error(`'completionEntryDetails' request failed with error.`, err); + }, () => { return item; }); } diff --git a/extensions/typescript/src/features/definitionProviderBase.ts b/extensions/typescript/src/features/definitionProviderBase.ts index b405d28fbaf..78768df2fee 100644 --- a/extensions/typescript/src/features/definitionProviderBase.ts +++ b/extensions/typescript/src/features/definitionProviderBase.ts @@ -40,8 +40,7 @@ export default class TypeScriptDefinitionProviderBase { return new Location(resource, new Range(location.start.line - 1, location.start.offset - 1, location.end.line - 1, location.end.offset - 1)); } }).filter(x => x !== null) as Location[]; - }, (error) => { - this.client.error(`'${definitionType}' request failed with error.`, error); + }, () => { return []; }); } diff --git a/extensions/typescript/src/features/documentHighlightProvider.ts b/extensions/typescript/src/features/documentHighlightProvider.ts index f0140953d92..15224ca2c2e 100644 --- a/extensions/typescript/src/features/documentHighlightProvider.ts +++ b/extensions/typescript/src/features/documentHighlightProvider.ts @@ -43,8 +43,7 @@ export default class TypeScriptDocumentHighlightProvider implements DocumentHigh }); } return []; - }, (err) => { - this.client.error(`'occurrences' request failed with error.`, err); + }, () => { return []; }); } diff --git a/extensions/typescript/src/features/documentSymbolProvider.ts b/extensions/typescript/src/features/documentSymbolProvider.ts index aa6a4e5ab7f..06b3e0983c2 100644 --- a/extensions/typescript/src/features/documentSymbolProvider.ts +++ b/extensions/typescript/src/features/documentSymbolProvider.ts @@ -53,8 +53,7 @@ export default class TypeScriptDocumentSymbolProvider implements DocumentSymbolP } } return result; - }, (err) => { - this.client.error(`'navtree' request failed with error.`, err); + }, () => { return []; }); } else { @@ -65,12 +64,10 @@ export default class TypeScriptDocumentSymbolProvider implements DocumentSymbolP response.body.forEach(item => TypeScriptDocumentSymbolProvider.convertNavBar(resource.uri, 0, foldingMap, result, item)); } return result; - }, (err) => { - this.client.error(`'navbar' request failed with error.`, err); + }, () => { return []; }); } - } private static convertNavBar(resource: Uri, indent: number, foldingMap: ObjectMap, bucket: SymbolInformation[], item: Proto.NavigationBarItem, containerLabel?: string): void { diff --git a/extensions/typescript/src/features/formattingProvider.ts b/extensions/typescript/src/features/formattingProvider.ts index 40b5522d0fa..d368bebbaa6 100644 --- a/extensions/typescript/src/features/formattingProvider.ts +++ b/extensions/typescript/src/features/formattingProvider.ts @@ -136,8 +136,7 @@ export default class TypeScriptFormattingProvider implements DocumentRangeFormat } else { return []; } - }, (err: any) => { - this.client.error(`'format' request failed with error.`, err); + }, () => { return []; }); }); @@ -195,8 +194,7 @@ export default class TypeScriptFormattingProvider implements DocumentRangeFormat } } return result; - }, (err: any) => { - this.client.error(`'formatonkey' request failed with error.`, err); + }, () => { return []; }); }); diff --git a/extensions/typescript/src/features/hoverProvider.ts b/extensions/typescript/src/features/hoverProvider.ts index e726ff1dc34..a0914aa1730 100644 --- a/extensions/typescript/src/features/hoverProvider.ts +++ b/extensions/typescript/src/features/hoverProvider.ts @@ -32,8 +32,7 @@ export default class TypeScriptHoverProvider implements HoverProvider { new Range(data.start.line - 1, data.start.offset - 1, data.end.line - 1, data.end.offset - 1)); } return undefined; - }, (err) => { - this.client.error(`'quickinfo' request failed with error.`, err); + }, () => { return null; }); } diff --git a/extensions/typescript/src/features/referenceProvider.ts b/extensions/typescript/src/features/referenceProvider.ts index 47921d128ea..9f7ccf9f49a 100644 --- a/extensions/typescript/src/features/referenceProvider.ts +++ b/extensions/typescript/src/features/referenceProvider.ts @@ -41,8 +41,7 @@ export default class TypeScriptReferenceSupport implements ReferenceProvider { result.push(location); } return result; - }, (err) => { - this.client.error(`'references' request failed with error.`, err); + }, () => { return []; }); } diff --git a/extensions/typescript/src/features/renameProvider.ts b/extensions/typescript/src/features/renameProvider.ts index 39c85f307a7..450523b4ade 100644 --- a/extensions/typescript/src/features/renameProvider.ts +++ b/extensions/typescript/src/features/renameProvider.ts @@ -49,8 +49,7 @@ export default class TypeScriptRenameProvider implements RenameProvider { }); }); return result; - }, (err) => { - this.client.error(`'rename' request failed with error.`, err); + }, () => { return null; }); } diff --git a/extensions/typescript/src/features/signatureHelpProvider.ts b/extensions/typescript/src/features/signatureHelpProvider.ts index 0a794878624..c3f6c86e001 100644 --- a/extensions/typescript/src/features/signatureHelpProvider.ts +++ b/extensions/typescript/src/features/signatureHelpProvider.ts @@ -64,8 +64,7 @@ export default class TypeScriptSignatureHelpProvider implements SignatureHelpPro }); return result; - }, (err: any) => { - this.client.error(`'signatureHelp' request failed with error.`, err); + }, () => { return null; }); } diff --git a/extensions/typescript/src/features/workspaceSymbolProvider.ts b/extensions/typescript/src/features/workspaceSymbolProvider.ts index 016ac8726b3..fa780771645 100644 --- a/extensions/typescript/src/features/workspaceSymbolProvider.ts +++ b/extensions/typescript/src/features/workspaceSymbolProvider.ts @@ -77,8 +77,7 @@ export default class TypeScriptWorkspaceSymbolProvider implements WorkspaceSymbo } } return result; - }, (err) => { - this.client.error(`'navto' request failed with error.`, err); + }, () => { return []; }); } diff --git a/extensions/typescript/src/typescriptService.ts b/extensions/typescript/src/typescriptService.ts index f2ad09da59a..d18e531b572 100644 --- a/extensions/typescript/src/typescriptService.ts +++ b/extensions/typescript/src/typescriptService.ts @@ -74,9 +74,7 @@ export interface ITypescriptServiceClient { normalizePath(resource: Uri): string | null; asUrl(filepath: string): Uri; - info(message: string, data?: any): void; warn(message: string, data?: any): void; - error(message: string, data?: any): void; onProjectLanguageServiceStateChanged: Event; onDidBeginInstallTypings: Event; diff --git a/extensions/typescript/src/typescriptServiceClient.ts b/extensions/typescript/src/typescriptServiceClient.ts index 62b3c53f369..6d604437626 100644 --- a/extensions/typescript/src/typescriptServiceClient.ts +++ b/extensions/typescript/src/typescriptServiceClient.ts @@ -889,14 +889,20 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient }; let result: Promise = Promise.resolve(null); if (expectsResult) { + let wasCancelled = false; result = new Promise((resolve, reject) => { requestInfo.callbacks = { c: resolve, e: reject, start: Date.now() }; if (token) { token.onCancellationRequested(() => { + wasCancelled = true; this.tryCancelRequest(request.seq); - resolve(undefined); }); } + }).catch((err: any) => { + if (!wasCancelled) { + this.error(`'${command}' request failed with error.`, err); + } + throw err; }); } requestInfo.promise = result; @@ -933,28 +939,26 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient } private tryCancelRequest(seq: number): boolean { - if (this.requestQueue.tryCancelPendingRequest(seq)) { - this.tracer.logTrace(`TypeScript Service: canceled request with sequence number ${seq}`); - return true; - } + try { + if (this.requestQueue.tryCancelPendingRequest(seq)) { + this.tracer.logTrace(`TypeScript Service: canceled request with sequence number ${seq}`); + return true; + } - if (this.apiVersion.has222Features() && this.cancellationPipeName) { - this.tracer.logTrace(`TypeScript Service: trying to cancel ongoing request with sequence number ${seq}`); - try { + if (this.apiVersion.has222Features() && this.cancellationPipeName) { + this.tracer.logTrace(`TypeScript Service: trying to cancel ongoing request with sequence number ${seq}`); fs.writeFileSync(this.cancellationPipeName + seq, ''); return true; - } catch (e) { - // noop - } finally { - const p = this.callbacks.fetch(seq); - if (p) { - p.e(new Error(`Cancelled Request ${seq}`)); - } } - } - this.tracer.logTrace(`TypeScript Service: tried to cancel request with sequence number ${seq}. But request got already delivered.`); - return false; + this.tracer.logTrace(`TypeScript Service: tried to cancel request with sequence number ${seq}. But request got already delivered.`); + return false; + } finally { + const p = this.callbacks.fetch(seq); + if (p) { + p.e(new Error(`Cancelled Request ${seq}`)); + } + } } private dispatchMessage(message: Proto.Message): void { -- GitLab From 0425eff0f0ade716038413915c942f1784867943 Mon Sep 17 00:00:00 2001 From: isidor Date: Wed, 7 Jun 2017 23:33:48 +0200 Subject: [PATCH 0626/1347] fixes #28198 --- .../parts/debug/electron-browser/rawDebugSession.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.ts b/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.ts index 211539a5d4f..819af044f04 100644 --- a/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.ts +++ b/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.ts @@ -79,7 +79,7 @@ export class RawDebugSession extends v8.V8Protocol implements debug.ISession { super(id); this.emittedStopped = false; this.readyForBreakpoints = false; - this.allThreadsContinued = true; + this.allThreadsContinued = false; this.sentPromises = []; this._onDidInitialize = new Emitter(); @@ -197,7 +197,7 @@ export class RawDebugSession extends v8.V8Protocol implements debug.ISession { this.emittedStopped = true; this._onDidStop.fire(event); } else if (event.event === 'continued') { - this.allThreadsContinued = (event).body.allThreadsContinued = false ? false : true; + this.allThreadsContinued = (event).body.allThreadsContinued === false ? false : true; this._onDidContinued.fire(event); } else if (event.event === 'thread') { this._onDidThread.fire(event); @@ -261,6 +261,7 @@ export class RawDebugSession extends v8.V8Protocol implements debug.ISession { public continue(args: DebugProtocol.ContinueArguments): TPromise { return this.send('continue', args).then(response => { + this.allThreadsContinued = response && response.body && response.body.allThreadsContinued === false ? false : true; this.fireFakeContinued(args.threadId, this.allThreadsContinued); return response; }); -- GitLab From d173d8ecc1a21a2561f85229bdeb426e867bd3a0 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 7 Jun 2017 14:48:57 -0700 Subject: [PATCH 0627/1347] Add insertSpaceAfterConstructor Formatting Option for TS and JS Fixes #28206 --- extensions/typescript/package.json | 10 +++++ extensions/typescript/package.nls.json | 1 + .../src/features/formattingProvider.ts | 37 ++++++++++--------- 3 files changed, 31 insertions(+), 17 deletions(-) diff --git a/extensions/typescript/package.json b/extensions/typescript/package.json index eefc7874d37..e3edc8ce90e 100644 --- a/extensions/typescript/package.json +++ b/extensions/typescript/package.json @@ -174,6 +174,11 @@ "default": true, "description": "%format.insertSpaceAfterCommaDelimiter%" }, + "typescript.format.insertSpaceAfterConstructor": { + "type": "boolean", + "default": false, + "description": "%format.insertSpaceAfterConstructor%" + }, "typescript.format.insertSpaceAfterSemicolonInForStatements": { "type": "boolean", "default": true, @@ -249,6 +254,11 @@ "default": true, "description": "%format.insertSpaceAfterCommaDelimiter%" }, + "javascript.format.insertSpaceAfterConstructor": { + "type": "boolean", + "default": false, + "description": "%format.insertSpaceAfterConstructor%" + }, "javascript.format.insertSpaceAfterSemicolonInForStatements": { "type": "boolean", "default": true, diff --git a/extensions/typescript/package.nls.json b/extensions/typescript/package.nls.json index d2028875402..9dbfd2d4564 100644 --- a/extensions/typescript/package.nls.json +++ b/extensions/typescript/package.nls.json @@ -12,6 +12,7 @@ "typescript.format.enable": "Enable/disable default TypeScript formatter.", "javascript.format.enable": "Enable/disable default JavaScript formatter.", "format.insertSpaceAfterCommaDelimiter": "Defines space handling after a comma delimiter.", + "format.insertSpaceAfterConstructor": "Defines space handling after the constructor keyword. Requires TypeScript >= 2.3.0.", "format.insertSpaceAfterSemicolonInForStatements": " Defines space handling after a semicolon in a for statement.", "format.insertSpaceBeforeAndAfterBinaryOperators": "Defines space handling after a binary operator.", "format.insertSpaceAfterKeywordsInControlFlowStatements": "Defines space handling after keywords in a control flow statement.", diff --git a/extensions/typescript/src/features/formattingProvider.ts b/extensions/typescript/src/features/formattingProvider.ts index d368bebbaa6..2687d317b2b 100644 --- a/extensions/typescript/src/features/formattingProvider.ts +++ b/extensions/typescript/src/features/formattingProvider.ts @@ -11,6 +11,7 @@ import { ITypescriptServiceClient } from '../typescriptService'; interface Configuration { enable: boolean; insertSpaceAfterCommaDelimiter: boolean; + insertSpaceAfterConstructor: boolean; insertSpaceAfterSemicolonInForStatements: boolean; insertSpaceBeforeAndAfterBinaryOperators: boolean; insertSpaceAfterKeywordsInControlFlowStatements: boolean; @@ -23,30 +24,29 @@ interface Configuration { insertSpaceBeforeFunctionParenthesis: boolean; placeOpenBraceOnNewLineForFunctions: boolean; placeOpenBraceOnNewLineForControlBlocks: boolean; - - [key: string]: boolean; } namespace Configuration { - export const insertSpaceAfterCommaDelimiter: string = 'insertSpaceAfterCommaDelimiter'; - export const insertSpaceAfterSemicolonInForStatements: string = 'insertSpaceAfterSemicolonInForStatements'; - export const insertSpaceBeforeAndAfterBinaryOperators: string = 'insertSpaceBeforeAndAfterBinaryOperators'; - export const insertSpaceAfterKeywordsInControlFlowStatements: string = 'insertSpaceAfterKeywordsInControlFlowStatements'; - export const insertSpaceAfterFunctionKeywordForAnonymousFunctions: string = 'insertSpaceAfterFunctionKeywordForAnonymousFunctions'; - export const insertSpaceBeforeFunctionParenthesis: string = 'insertSpaceBeforeFunctionParenthesis'; - export const insertSpaceAfterOpeningAndBeforeClosingNonemptyParenthesis: string = 'insertSpaceAfterOpeningAndBeforeClosingNonemptyParenthesis'; - export const insertSpaceAfterOpeningAndBeforeClosingNonemptyBrackets: string = 'insertSpaceAfterOpeningAndBeforeClosingNonemptyBrackets'; - export const insertSpaceAfterOpeningAndBeforeClosingNonemptyBraces: string = 'insertSpaceAfterOpeningAndBeforeClosingNonemptyBraces'; - export const insertSpaceAfterOpeningAndBeforeClosingTemplateStringBraces: string = 'insertSpaceAfterOpeningAndBeforeClosingTemplateStringBraces'; - export const insertSpaceAfterOpeningAndBeforeClosingJsxExpressionBraces: string = 'insertSpaceAfterOpeningAndBeforeClosingJsxExpressionBraces'; - export const placeOpenBraceOnNewLineForFunctions: string = 'placeOpenBraceOnNewLineForFunctions'; - export const placeOpenBraceOnNewLineForControlBlocks: string = 'placeOpenBraceOnNewLineForControlBlocks'; + export const insertSpaceAfterCommaDelimiter = 'insertSpaceAfterCommaDelimiter'; + export const insertSpaceAfterConstructor = 'insertSpaceAfterConstructor'; + export const insertSpaceAfterSemicolonInForStatements = 'insertSpaceAfterSemicolonInForStatements'; + export const insertSpaceBeforeAndAfterBinaryOperators = 'insertSpaceBeforeAndAfterBinaryOperators'; + export const insertSpaceAfterKeywordsInControlFlowStatements = 'insertSpaceAfterKeywordsInControlFlowStatements'; + export const insertSpaceAfterFunctionKeywordForAnonymousFunctions = 'insertSpaceAfterFunctionKeywordForAnonymousFunctions'; + export const insertSpaceBeforeFunctionParenthesis = 'insertSpaceBeforeFunctionParenthesis'; + export const insertSpaceAfterOpeningAndBeforeClosingNonemptyParenthesis = 'insertSpaceAfterOpeningAndBeforeClosingNonemptyParenthesis'; + export const insertSpaceAfterOpeningAndBeforeClosingNonemptyBrackets = 'insertSpaceAfterOpeningAndBeforeClosingNonemptyBrackets'; + export const insertSpaceAfterOpeningAndBeforeClosingNonemptyBraces = 'insertSpaceAfterOpeningAndBeforeClosingNonemptyBraces'; + export const insertSpaceAfterOpeningAndBeforeClosingTemplateStringBraces = 'insertSpaceAfterOpeningAndBeforeClosingTemplateStringBraces'; + export const insertSpaceAfterOpeningAndBeforeClosingJsxExpressionBraces = 'insertSpaceAfterOpeningAndBeforeClosingJsxExpressionBraces'; + export const placeOpenBraceOnNewLineForFunctions = 'placeOpenBraceOnNewLineForFunctions'; + export const placeOpenBraceOnNewLineForControlBlocks = 'placeOpenBraceOnNewLineForControlBlocks'; export function equals(a: Configuration, b: Configuration): boolean { let keys = Object.keys(a); for (let i = 0; i < keys.length; i++) { let key = keys[i]; - if (a[key] !== b[key]) { + if ((a as any)[key] !== (b as any)[key]) { return false; } } @@ -57,6 +57,7 @@ namespace Configuration { let result: Configuration = Object.create(null); result.enable = true; result.insertSpaceAfterCommaDelimiter = true; + result.insertSpaceAfterConstructor = false; result.insertSpaceAfterSemicolonInForStatements = true; result.insertSpaceBeforeAndAfterBinaryOperators = true; result.insertSpaceAfterKeywordsInControlFlowStatements = true; @@ -213,6 +214,7 @@ export default class TypeScriptFormattingProvider implements DocumentRangeFormat // We can use \n here since the editor normalizes later on to its line endings. newLineCharacter: '\n', insertSpaceAfterCommaDelimiter: this.config.insertSpaceAfterCommaDelimiter, + insertSpaceAfterConstructor: this.config.insertSpaceAfterConstructor, insertSpaceAfterSemicolonInForStatements: this.config.insertSpaceAfterSemicolonInForStatements, insertSpaceBeforeAndAfterBinaryOperators: this.config.insertSpaceBeforeAndAfterBinaryOperators, insertSpaceAfterKeywordsInControlFlowStatements: this.config.insertSpaceAfterKeywordsInControlFlowStatements, @@ -224,7 +226,8 @@ export default class TypeScriptFormattingProvider implements DocumentRangeFormat insertSpaceAfterOpeningAndBeforeClosingTemplateStringBraces: this.config.insertSpaceAfterOpeningAndBeforeClosingTemplateStringBraces, insertSpaceAfterOpeningAndBeforeClosingJsxExpressionBraces: this.config.insertSpaceAfterOpeningAndBeforeClosingJsxExpressionBraces, placeOpenBraceOnNewLineForFunctions: this.config.placeOpenBraceOnNewLineForFunctions, - placeOpenBraceOnNewLineForControlBlocks: this.config.placeOpenBraceOnNewLineForControlBlocks + placeOpenBraceOnNewLineForControlBlocks: this.config.placeOpenBraceOnNewLineForControlBlocks, + }; } } -- GitLab From fc2b063fa287ef19ea51bf605ea010eca23fc1b1 Mon Sep 17 00:00:00 2001 From: Yu Zhang <583181285@qq.com> Date: Thu, 8 Jun 2017 05:53:54 +0800 Subject: [PATCH 0628/1347] Default Markdown language configuration (#28172) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * 🔧 renew Markdown lang config * 🎨 format --- .../markdown/language-configuration.json | 60 +++++++++++-------- 1 file changed, 35 insertions(+), 25 deletions(-) diff --git a/extensions/markdown/language-configuration.json b/extensions/markdown/language-configuration.json index fd6cd6a1469..05e33bbdc90 100644 --- a/extensions/markdown/language-configuration.json +++ b/extensions/markdown/language-configuration.json @@ -8,31 +8,41 @@ }, // symbols used as brackets "brackets": [ - [ - "{", - "}" - ], - [ - "[", - "]" - ], - [ - "(", - ")" - ] + ["{", "}"], + ["[", "]"], + ["(", ")"] ], "autoClosingPairs": [ - [ - "{", - "}" - ], - [ - "[", - "]" - ], - [ - "(", - ")" - ] + { + "open": "{", + "close": "}" + }, + { + "open": "[", + "close": "]" + }, + { + "open": "(", + "close": ")" + }, + { + "open": "<", + "close": ">", + "notIn": [ + "string" + ] + }, + { + "open": "`", + "close": "`", + "notIn": [ + "string" + ] + } + ], + "surroundingPairs": [ + ["(", ")"], + ["[", "]"], + ["`", "`"] ] -} +} \ No newline at end of file -- GitLab From 07645a664feb2912620e727d7d2ab0182d6e99f4 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 7 Jun 2017 15:08:43 -0700 Subject: [PATCH 0629/1347] Restrict markdown preview to markdown files Fixes #28210 Only show the markdown preview commands when you are in a markdown file --- extensions/markdown/package.json | 32 +++++++++++++++++++++++++------- 1 file changed, 25 insertions(+), 7 deletions(-) diff --git a/extensions/markdown/package.json b/extensions/markdown/package.json index 4ffa3bd6b39..15c27055fe0 100644 --- a/extensions/markdown/package.json +++ b/extensions/markdown/package.json @@ -16,7 +16,8 @@ "onLanguage:markdown", "onCommand:markdown.showPreview", "onCommand:markdown.showPreviewToSide", - "onCommand:markdown.showSource" + "onCommand:markdown.showSource", + "onCommand:markdown.showPreviewSecuritySelector" ], "contributes": { "languages": [ @@ -79,25 +80,42 @@ "menus": { "editor/title": [ { - "when": "editorLangId == markdown", "command": "markdown.showPreviewToSide", + "when": "editorLangId == markdown", "alt": "markdown.showPreview", "group": "navigation" }, { - "when": "resourceScheme == markdown", "command": "markdown.showSource", + "when": "resourceScheme == markdown", "group": "navigation" }, { - "when": "resourceScheme == markdown", - "command": "markdown.showPreviewSecuritySelector" + "command": "markdown.showPreviewSecuritySelector", + "when": "resourceScheme == markdown" } ], "explorer/context": [ { + "command": "markdown.showPreview", "when": "resourceLangId == markdown", + "group": "navigation" + } + ], + "commandPalette": [ + { "command": "markdown.showPreview", + "when": "editorLangId == markdown", + "group": "navigation" + }, + { + "command": "markdown.showPreviewToSide", + "when": "editorLangId == markdown", + "group": "navigation" + }, + { + "command": "markdown.showSource", + "when": "resourceScheme == markdown", "group": "navigation" } ] @@ -107,13 +125,13 @@ "command": "markdown.showPreview", "key": "shift+ctrl+v", "mac": "shift+cmd+v", - "when": "editorFocus" + "when": "editorLangId == markdown" }, { "command": "markdown.showPreviewToSide", "key": "ctrl+k v", "mac": "cmd+k v", - "when": "editorFocus" + "when": "editorLangId == markdown" } ], "snippets": [ -- GitLab From dca7ae6908908cb1eccbb38b35bcdcdf3e212995 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Wed, 7 Jun 2017 15:23:28 -0700 Subject: [PATCH 0630/1347] Monokai: Use tab well color for title bar Fixes #27980 --- extensions/theme-monokai/themes/monokai-color-theme.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/theme-monokai/themes/monokai-color-theme.json b/extensions/theme-monokai/themes/monokai-color-theme.json index fa2146e0a84..693494c71de 100644 --- a/extensions/theme-monokai/themes/monokai-color-theme.json +++ b/extensions/theme-monokai/themes/monokai-color-theme.json @@ -37,7 +37,7 @@ "panelTitle.activeBorder": "#75715E", "panelTitle.inactiveForeground": "#75715E", "panel.border": "#414339", - "titleBar.activeBackground": "#414339", + "titleBar.activeBackground": "#1e1f1c", "statusBar.background": "#414339", "statusBar.noFolderBackground": "#414339", "statusBar.debuggingBackground": "#75715E", -- GitLab From 9f0ba70700e9c010501aa2f7eec19061ce75f799 Mon Sep 17 00:00:00 2001 From: isidor Date: Thu, 8 Jun 2017 00:28:24 +0200 Subject: [PATCH 0631/1347] fixes #28198 --- .../workbench/parts/debug/common/debugModel.ts | 6 +++--- .../parts/debug/electron-browser/debugViewer.ts | 16 ++++++++-------- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/src/vs/workbench/parts/debug/common/debugModel.ts b/src/vs/workbench/parts/debug/common/debugModel.ts index 6c1f0223469..c68c9be42db 100644 --- a/src/vs/workbench/parts/debug/common/debugModel.ts +++ b/src/vs/workbench/parts/debug/common/debugModel.ts @@ -435,17 +435,17 @@ export class Thread implements IThread { * Only fetches the first stack frame for performance reasons. Calling this method consecutive times * gets the remainder of the call stack. */ - public fetchCallStack(): TPromise { + public fetchCallStack(smartFetch = true): TPromise { if (!this.stopped) { return TPromise.as(null); } - if (!this.fetchPromise) { + if (!this.fetchPromise && smartFetch) { this.fetchPromise = this.getCallStackImpl(0, 1).then(callStack => { this.callStack = callStack || []; }); } else { - this.fetchPromise = this.fetchPromise.then(() => this.getCallStackImpl(this.callStack.length, 20).then(callStackSecondPart => { + this.fetchPromise = (this.fetchPromise || TPromise.as(null)).then(() => this.getCallStackImpl(this.callStack.length, 20).then(callStackSecondPart => { this.callStack = this.callStack.concat(callStackSecondPart); })); } diff --git a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts index 41251145877..76cb4fb9945 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts @@ -355,7 +355,7 @@ export class CallStackDataSource implements IDataSource { public getChildren(tree: ITree, element: any): TPromise { if (element instanceof Thread) { - return TPromise.as(this.getThreadChildren(element)); + return this.getThreadChildren(element); } if (element instanceof Model) { return TPromise.as(element.getProcesses()); @@ -365,25 +365,25 @@ export class CallStackDataSource implements IDataSource { return TPromise.as(process.getAllThreads()); } - private getThreadChildren(thread: Thread): any[] { + private getThreadChildren(thread: Thread): TPromise { const callStack: any[] = thread.getCallStack(); - if (!callStack) { - return []; + if (!callStack || !callStack.length) { + return thread.fetchCallStack(false).then(() => thread.getCallStack()); } if (callStack.length === 1) { // To reduce flashing of the call stack view simply append the stale call stack // once we have the correct data the tree will refresh and we will no longer display it. - return callStack.concat(thread.getStaleCallStack().slice(1)); + return TPromise.as(callStack.concat(thread.getStaleCallStack().slice(1))); } if (thread.stoppedDetails && thread.stoppedDetails.framesErrorMessage) { - return callStack.concat([thread.stoppedDetails.framesErrorMessage]); + return TPromise.as(callStack.concat([thread.stoppedDetails.framesErrorMessage])); } if (thread.stoppedDetails && thread.stoppedDetails.totalFrames > callStack.length && callStack.length > 1) { - return callStack.concat([new ThreadAndProcessIds(thread.process.getId(), thread.threadId)]); + return TPromise.as(callStack.concat([new ThreadAndProcessIds(thread.process.getId(), thread.threadId)])); } - return callStack; + return TPromise.as(callStack); } public getParent(tree: ITree, element: any): TPromise { -- GitLab From 4d020e27eaa6019124ffdc3389aaf51e1e65a0ee Mon Sep 17 00:00:00 2001 From: isidor Date: Thu, 8 Jun 2017 00:35:21 +0200 Subject: [PATCH 0632/1347] Revert "fixes #28198" This reverts commit 0425eff0f0ade716038413915c942f1784867943. --- .../parts/debug/electron-browser/rawDebugSession.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.ts b/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.ts index 819af044f04..211539a5d4f 100644 --- a/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.ts +++ b/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.ts @@ -79,7 +79,7 @@ export class RawDebugSession extends v8.V8Protocol implements debug.ISession { super(id); this.emittedStopped = false; this.readyForBreakpoints = false; - this.allThreadsContinued = false; + this.allThreadsContinued = true; this.sentPromises = []; this._onDidInitialize = new Emitter(); @@ -197,7 +197,7 @@ export class RawDebugSession extends v8.V8Protocol implements debug.ISession { this.emittedStopped = true; this._onDidStop.fire(event); } else if (event.event === 'continued') { - this.allThreadsContinued = (event).body.allThreadsContinued === false ? false : true; + this.allThreadsContinued = (event).body.allThreadsContinued = false ? false : true; this._onDidContinued.fire(event); } else if (event.event === 'thread') { this._onDidThread.fire(event); @@ -261,7 +261,6 @@ export class RawDebugSession extends v8.V8Protocol implements debug.ISession { public continue(args: DebugProtocol.ContinueArguments): TPromise { return this.send('continue', args).then(response => { - this.allThreadsContinued = response && response.body && response.body.allThreadsContinued === false ? false : true; this.fireFakeContinued(args.threadId, this.allThreadsContinued); return response; }); -- GitLab From 9ad78cf0c753d82cf35293cf18fdd8701eb147bf Mon Sep 17 00:00:00 2001 From: isidor Date: Thu, 8 Jun 2017 00:39:58 +0200 Subject: [PATCH 0633/1347] use tripple equals when comparing --- .../workbench/parts/debug/electron-browser/rawDebugSession.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.ts b/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.ts index 211539a5d4f..d83e1999d53 100644 --- a/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.ts +++ b/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.ts @@ -197,7 +197,7 @@ export class RawDebugSession extends v8.V8Protocol implements debug.ISession { this.emittedStopped = true; this._onDidStop.fire(event); } else if (event.event === 'continued') { - this.allThreadsContinued = (event).body.allThreadsContinued = false ? false : true; + this.allThreadsContinued = (event).body.allThreadsContinued === false ? false : true; this._onDidContinued.fire(event); } else if (event.event === 'thread') { this._onDidThread.fire(event); -- GitLab From 25458491ebb2b5717df6e363e1c4ed69242ff882 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 7 Jun 2017 15:40:04 -0700 Subject: [PATCH 0634/1347] Remove ` as autoclosing pair in markdown Having ` as an autoclosing pair makes typing fenced code blocks annoying https://github.com/Microsoft/vscode/pull/28172#issuecomment-306944985 --- extensions/markdown/language-configuration.json | 7 ------- 1 file changed, 7 deletions(-) diff --git a/extensions/markdown/language-configuration.json b/extensions/markdown/language-configuration.json index 05e33bbdc90..6c811c66aa6 100644 --- a/extensions/markdown/language-configuration.json +++ b/extensions/markdown/language-configuration.json @@ -31,13 +31,6 @@ "notIn": [ "string" ] - }, - { - "open": "`", - "close": "`", - "notIn": [ - "string" - ] } ], "surroundingPairs": [ -- GitLab From 2af6c114c3a48fd06e86683260483780727ffd0b Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 7 Jun 2017 15:41:41 -0700 Subject: [PATCH 0635/1347] Fix markdown wordwrap for langugae specific settings. Fixes #25357 --- extensions/markdown/src/previewContentProvider.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/extensions/markdown/src/previewContentProvider.ts b/extensions/markdown/src/previewContentProvider.ts index 44531e5b62e..8f6d925059c 100644 --- a/extensions/markdown/src/previewContentProvider.ts +++ b/extensions/markdown/src/previewContentProvider.ts @@ -65,9 +65,14 @@ class MarkdownPreviewConfig { private constructor() { const editorConfig = vscode.workspace.getConfiguration('editor'); const markdownConfig = vscode.workspace.getConfiguration('markdown'); + const markdownEditorConfig = vscode.workspace.getConfiguration('[markdown]'); this.scrollBeyondLastLine = editorConfig.get('scrollBeyondLastLine', false); + this.wordWrap = editorConfig.get('wordWrap', 'off') !== 'off'; + if (markdownEditorConfig && markdownEditorConfig['editor.wordWrap']) { + this.wordWrap = markdownEditorConfig['editor.wordWrap'] !== 'off'; + } this.previewFrontMatter = markdownConfig.get('previewFrontMatter', 'hide'); this.scrollPreviewWithEditorSelection = !!markdownConfig.get('preview.scrollPreviewWithEditorSelection', true); -- GitLab From 5291f831b69640ef901eb9383781e99cc9fa06a5 Mon Sep 17 00:00:00 2001 From: Cristian Date: Thu, 8 Jun 2017 08:20:45 +0300 Subject: [PATCH 0636/1347] #22622 - implemented DomScrollableElement --- src/vs/workbench/parts/debug/electron-browser/debugHover.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts index 33e4a4e21e0..96f025bc4bc 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts @@ -21,6 +21,7 @@ import { IDebugService, IExpression, IExpressionContainer } from 'vs/workbench/p import { Expression } from 'vs/workbench/parts/debug/common/debugModel'; import { VariablesRenderer, renderExpressionValue, VariablesDataSource } from 'vs/workbench/parts/debug/electron-browser/debugViewer'; import { IListService } from 'vs/platform/list/browser/listService'; +import { DomScrollableElement } from 'vs/base/browser/ui/scrollbar/scrollableElement'; const $ = dom.$; const MAX_ELEMENTS_SHOWN = 18; @@ -42,6 +43,7 @@ export class DebugHoverWidget implements IContentWidget { private valueContainer: HTMLElement; private stoleFocus: boolean; private toDispose: lifecycle.IDisposable[]; + private scrollbar: DomScrollableElement; constructor( private editor: ICodeEditor, @@ -68,6 +70,7 @@ export class DebugHoverWidget implements IContentWidget { private create(instantiationService: IInstantiationService): void { this.domNode = $('.debug-hover-widget'); this.complexValueContainer = dom.append(this.domNode, $('.complex-value')); + this.scrollbar = new DomScrollableElement(this.complexValueContainer, { canUseTranslate3d: false }); this.complexValueTitle = dom.append(this.complexValueContainer, $('.title')); this.treeContainer = dom.append(this.complexValueContainer, $('.debug-hover-tree')); this.treeContainer.setAttribute('role', 'tree'); @@ -81,6 +84,8 @@ export class DebugHoverWidget implements IContentWidget { ariaLabel: nls.localize('treeAriaLabel', "Debug Hover"), keyboardSupport: false }); + this.toDispose.push(this.scrollbar); + this.domNode.appendChild(this.scrollbar.getDomNode()); this.toDispose.push(this.listService.register(this.tree)); } -- GitLab From efa84ba72503f2ea8e2f3dfe2114c099009431db Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 8 Jun 2017 09:44:29 +0200 Subject: [PATCH 0637/1347] less eager snippet suggestions, #26275 --- .../parts/snippets/electron-browser/snippetsService.ts | 7 +++++-- .../snippets/test/electron-browser/snippetsService.test.ts | 5 +++++ 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/snippets/electron-browser/snippetsService.ts b/src/vs/workbench/parts/snippets/electron-browser/snippetsService.ts index 8e4f75e32ca..717bdbe3541 100644 --- a/src/vs/workbench/parts/snippets/electron-browser/snippetsService.ts +++ b/src/vs/workbench/parts/snippets/electron-browser/snippetsService.ts @@ -111,18 +111,21 @@ export class SnippetSuggestProvider implements ISuggestSupport { for (const snippet of snippets) { const lowPrefix = snippet.prefix.toLowerCase(); - let overwriteBefore: number; + let overwriteBefore = 0; + let accetSnippet = true; if (lowWordUntil.length > 0 && startsWith(lowPrefix, lowWordUntil)) { // cheap match on the (none-empty) current word overwriteBefore = lowWordUntil.length; + accetSnippet = true; } else if (lowLineUntil.length > 0) { // compute overlap between snippet and line on text overwriteBefore = overlap(lowLineUntil, snippet.prefix.toLowerCase()); + accetSnippet = overwriteBefore > 0 && !model.getWordAtPosition(new Position(position.lineNumber, position.column - overwriteBefore)); } - if (overwriteBefore !== 0) { + if (accetSnippet) { items.push({ snippet, diff --git a/src/vs/workbench/parts/snippets/test/electron-browser/snippetsService.test.ts b/src/vs/workbench/parts/snippets/test/electron-browser/snippetsService.test.ts index d9fa6f1b294..2cde3b1116d 100644 --- a/src/vs/workbench/parts/snippets/test/electron-browser/snippetsService.test.ts +++ b/src/vs/workbench/parts/snippets/test/electron-browser/snippetsService.test.ts @@ -84,5 +84,10 @@ suite('SnippetsService', function () { result = provider.provideCompletionItems(model, new Position(1, 4)); assert.equal(result.suggestions.length, 1); model.dispose(); + + model = Model.createFromString('a Date: Thu, 8 Jun 2017 09:45:21 +0200 Subject: [PATCH 0638/1347] dialogs - set type properly --- src/vs/workbench/electron-browser/window.ts | 3 ++- .../parts/extensions/browser/extensionsActions.ts | 2 +- src/vs/workbench/parts/files/browser/fileActions.ts | 9 ++++++--- .../parts/files/browser/views/explorerViewer.ts | 3 ++- src/vs/workbench/parts/search/browser/searchViewlet.ts | 7 ++++--- .../parts/tasks/electron-browser/task.contribution.ts | 6 ++++-- 6 files changed, 19 insertions(+), 11 deletions(-) diff --git a/src/vs/workbench/electron-browser/window.ts b/src/vs/workbench/electron-browser/window.ts index e193c9391e4..15bfd13bb22 100644 --- a/src/vs/workbench/electron-browser/window.ts +++ b/src/vs/workbench/electron-browser/window.ts @@ -149,7 +149,8 @@ export class ElectronWindow extends Themable { if (draggedExternalResources.length > 20) { doOpen = this.messageService.confirm({ message: nls.localize('confirmOpen', "Are you sure you want to open {0} folders?", draggedExternalResources.length), - primaryButton: nls.localize({ key: 'confirmOpenButton', comment: ['&& denotes a mnemonic'] }, "&&Open") + primaryButton: nls.localize({ key: 'confirmOpenButton', comment: ['&& denotes a mnemonic'] }, "&&Open"), + type: 'question' }); } diff --git a/src/vs/workbench/parts/extensions/browser/extensionsActions.ts b/src/vs/workbench/parts/extensions/browser/extensionsActions.ts index b922ba26c25..63de81c9037 100644 --- a/src/vs/workbench/parts/extensions/browser/extensionsActions.ts +++ b/src/vs/workbench/parts/extensions/browser/extensionsActions.ts @@ -865,7 +865,7 @@ export class ReloadAction extends Action { } run(): TPromise { - if (this.messageService.confirm({ message: this.reloadMessaage, primaryButton: localize('reload', "&&Reload Window") })) { + if (this.messageService.confirm({ message: this.reloadMessaage, type: 'question', primaryButton: localize('reload', "&&Reload Window") })) { return this.windowService.reloadWindow(); } return TPromise.wrap(null); diff --git a/src/vs/workbench/parts/files/browser/fileActions.ts b/src/vs/workbench/parts/files/browser/fileActions.ts index 98e8c094ddd..378a32e3889 100644 --- a/src/vs/workbench/parts/files/browser/fileActions.ts +++ b/src/vs/workbench/parts/files/browser/fileActions.ts @@ -698,13 +698,15 @@ export class BaseDeleteFileAction extends BaseFileAction { confirm = { message: this.element.isDirectory ? nls.localize('confirmMoveTrashMessageFolder', "Are you sure you want to delete '{0}' and its contents?", this.element.name) : nls.localize('confirmMoveTrashMessageFile', "Are you sure you want to delete '{0}'?", this.element.name), detail: isWindows ? nls.localize('undoBin', "You can restore from the recycle bin.") : nls.localize('undoTrash', "You can restore from the trash."), - primaryButton + primaryButton, + type: 'question' }; } else { confirm = { message: this.element.isDirectory ? nls.localize('confirmDeleteMessageFolder', "Are you sure you want to permanently delete '{0}' and its contents?", this.element.name) : nls.localize('confirmDeleteMessageFile', "Are you sure you want to permanently delete '{0}'?", this.element.name), detail: nls.localize('irreversible', "This action is irreversible!"), - primaryButton + primaryButton, + type: 'warning' }; } @@ -823,7 +825,8 @@ export class ImportFileAction extends BaseFileAction { const confirm: IConfirmation = { message: nls.localize('confirmOverwrite', "A file or folder with the same name already exists in the destination folder. Do you want to replace it?"), detail: nls.localize('irreversible', "This action is irreversible!"), - primaryButton: nls.localize({ key: 'replaceButtonLabel', comment: ['&& denotes a mnemonic'] }, "&&Replace") + primaryButton: nls.localize({ key: 'replaceButtonLabel', comment: ['&& denotes a mnemonic'] }, "&&Replace"), + type: 'warning' }; overwrite = this.messageService.confirm(confirm); diff --git a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts index 95f1dc2599c..e7ed0556942 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts @@ -804,7 +804,8 @@ export class FileDragAndDrop implements IDragAndDrop { const confirm: IConfirmation = { message: nls.localize('confirmOverwriteMessage', "'{0}' already exists in the destination folder. Do you want to replace it?", source.name), detail: nls.localize('irreversible', "This action is irreversible!"), - primaryButton: nls.localize({ key: 'replaceButtonLabel', comment: ['&& denotes a mnemonic'] }, "&&Replace") + primaryButton: nls.localize({ key: 'replaceButtonLabel', comment: ['&& denotes a mnemonic'] }, "&&Replace"), + type: 'warning' }; // Move with overwrite if the user confirms diff --git a/src/vs/workbench/parts/search/browser/searchViewlet.ts b/src/vs/workbench/parts/search/browser/searchViewlet.ts index 9fe88c72d57..94d852b0b3a 100644 --- a/src/vs/workbench/parts/search/browser/searchViewlet.ts +++ b/src/vs/workbench/parts/search/browser/searchViewlet.ts @@ -38,7 +38,7 @@ import { IStorageService, StorageScope } from 'vs/platform/storage/common/storag import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { IContextViewService } from 'vs/platform/contextview/browser/contextView'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; -import { IMessageService } from 'vs/platform/message/common/message'; +import { IMessageService, IConfirmation } from 'vs/platform/message/common/message'; import { IProgressService } from 'vs/platform/progress/common/progress'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { IContextKeyService, IContextKey } from 'vs/platform/contextkey/common/contextkey'; @@ -368,10 +368,11 @@ export class SearchViewlet extends Viewlet { let replaceValue = this.searchWidget.getReplaceValue() || ''; let afterReplaceAllMessage = this.buildAfterReplaceAllMessage(occurrences, fileCount, replaceValue); - let confirmation = { + let confirmation: IConfirmation = { title: nls.localize('replaceAll.confirmation.title', "Replace All"), message: this.buildReplaceAllConfirmationMessage(occurrences, fileCount, replaceValue), - primaryButton: nls.localize('replaceAll.confirm.button', "Replace") + primaryButton: nls.localize('replaceAll.confirm.button', "Replace"), + type: 'question' }; if (this.messageService.confirm(confirmation)) { diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index 0619206da2f..ee12526316b 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -1251,7 +1251,8 @@ class TaskService extends EventEmitter implements ITaskService { if (this._taskSystem && this._taskSystem.isActiveSync()) { if (this._taskSystem.canAutoTerminate() || this.messageService.confirm({ message: nls.localize('TaskSystem.runningTask', 'There is a task running. Do you want to terminate it?'), - primaryButton: nls.localize({ key: 'TaskSystem.terminateTask', comment: ['&& denotes a mnemonic'] }, "&&Terminate Task") + primaryButton: nls.localize({ key: 'TaskSystem.terminateTask', comment: ['&& denotes a mnemonic'] }, "&&Terminate Task"), + type: 'question' })) { return this._taskSystem.terminateAll().then((response) => { if (response.success) { @@ -1262,7 +1263,8 @@ class TaskService extends EventEmitter implements ITaskService { } else if (response.code && response.code === TerminateResponseCode.ProcessNotFound) { return !this.messageService.confirm({ message: nls.localize('TaskSystem.noProcess', 'The launched task doesn\'t exist anymore. If the task spawned background processes exiting VS Code might result in orphaned processes. To avoid this start the last background process with a wait flag.'), - primaryButton: nls.localize({ key: 'TaskSystem.exitAnyways', comment: ['&& denotes a mnemonic'] }, "&&Exit Anyways") + primaryButton: nls.localize({ key: 'TaskSystem.exitAnyways', comment: ['&& denotes a mnemonic'] }, "&&Exit Anyways"), + type: 'info' }); } return true; // veto -- GitLab From 4aa3f05d08a16ff967b96343df665b21aaa0396d Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 8 Jun 2017 09:48:37 +0200 Subject: [PATCH 0639/1347] :lipstick: main side --- src/vs/code/{electron-main => common}/log.ts | 3 +- src/vs/code/common/windows.ts | 5 +- src/vs/code/electron-main/app.ts | 9 +- src/vs/code/electron-main/launch.ts | 19 ++-- src/vs/code/electron-main/lifecycle.ts | 4 +- src/vs/code/electron-main/main.ts | 6 +- src/vs/code/electron-main/menus.ts | 2 +- src/vs/code/electron-main/sharedProcess.ts | 17 ++-- src/vs/code/electron-main/window.ts | 96 +++++++++---------- src/vs/code/electron-main/windows.ts | 6 +- src/vs/code/{electron-main => node}/paths.ts | 0 .../code/{electron-main => node}/shellEnv.ts | 2 +- .../code/{electron-main => node}/storage.ts | 6 +- src/vs/code/node/windowsUtils.ts | 12 ++- 14 files changed, 94 insertions(+), 93 deletions(-) rename src/vs/code/{electron-main => common}/log.ts (96%) rename src/vs/code/{electron-main => node}/paths.ts (100%) rename src/vs/code/{electron-main => node}/shellEnv.ts (100%) rename src/vs/code/{electron-main => node}/storage.ts (94%) diff --git a/src/vs/code/electron-main/log.ts b/src/vs/code/common/log.ts similarity index 96% rename from src/vs/code/electron-main/log.ts rename to src/vs/code/common/log.ts index caa630d6ad2..c9908624211 100644 --- a/src/vs/code/electron-main/log.ts +++ b/src/vs/code/common/log.ts @@ -12,6 +12,7 @@ export const ILogService = createDecorator('logService'); export interface ILogService { _serviceBrand: any; + log(...args: any[]): void; } @@ -22,7 +23,7 @@ export class MainLogService implements ILogService { constructor( @IEnvironmentService private environmentService: IEnvironmentService) { } - log(...args: any[]): void { + public log(...args: any[]): void { if (this.environmentService.verbose) { console.log(`\x1b[93m[main ${new Date().toLocaleTimeString()}]\x1b[0m`, ...args); } diff --git a/src/vs/code/common/windows.ts b/src/vs/code/common/windows.ts index 96ca219e07f..43c5fba2864 100644 --- a/src/vs/code/common/windows.ts +++ b/src/vs/code/common/windows.ts @@ -36,7 +36,6 @@ export interface IWindowEventService { } export class ActiveWindowManager implements IDisposable { - private disposables: IDisposable[] = []; private _activeWindowId: number; @@ -49,11 +48,11 @@ export class ActiveWindowManager implements IDisposable { this._activeWindowId = windowId; } - get activeClientId(): string { + public get activeClientId(): string { return `window:${this._activeWindowId}`; } - dispose() { + public dispose() { this.disposables = dispose(this.disposables); } } \ No newline at end of file diff --git a/src/vs/code/electron-main/app.ts b/src/vs/code/electron-main/app.ts index f15971a75de..435423de2c2 100644 --- a/src/vs/code/electron-main/app.ts +++ b/src/vs/code/electron-main/app.ts @@ -14,7 +14,7 @@ import { WindowsChannel } from 'vs/platform/windows/common/windowsIpc'; import { WindowsService } from 'vs/platform/windows/electron-main/windowsService'; import { ILifecycleService } from 'vs/code/electron-main/lifecycle'; import { VSCodeMenu } from 'vs/code/electron-main/menus'; -import { getShellEnvironment } from 'vs/code/electron-main/shellEnv'; +import { getShellEnvironment } from 'vs/code/node/shellEnv'; import { IUpdateService } from 'vs/platform/update/common/update'; import { UpdateChannel } from 'vs/platform/update/common/updateIpc'; import { UpdateService } from 'vs/platform/update/electron-main/updateService'; @@ -26,8 +26,8 @@ import { LaunchService, LaunchChannel, ILaunchService } from './launch'; import { IInstantiationService, ServicesAccessor } from 'vs/platform/instantiation/common/instantiation'; import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; import { SyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; -import { ILogService } from 'vs/code/electron-main/log'; -import { IStorageService } from 'vs/code/electron-main/storage'; +import { ILogService } from 'vs/code/common/log'; +import { IStorageService } from 'vs/code/node/storage'; import { IBackupMainService } from 'vs/platform/backup/common/backup'; import { BackupChannel } from 'vs/platform/backup/common/backupIpc'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; @@ -146,8 +146,7 @@ export class VSCodeApplication { // Spawn shared process this.sharedProcess = new SharedProcess(this.environmentService, this.userEnv); this.toDispose.push(this.sharedProcess); - this.sharedProcessClient = this.sharedProcess.whenReady() - .then(() => connect(this.environmentService.sharedIPCHandle, 'main')); + this.sharedProcessClient = this.sharedProcess.whenReady().then(() => connect(this.environmentService.sharedIPCHandle, 'main')); // Services const appInstantiationService = this.initServices(); diff --git a/src/vs/code/electron-main/launch.ts b/src/vs/code/electron-main/launch.ts index e69f31b9363..c8a6347a9de 100644 --- a/src/vs/code/electron-main/launch.ts +++ b/src/vs/code/electron-main/launch.ts @@ -10,7 +10,7 @@ import { IWindowsMainService } from 'vs/code/electron-main/windows'; import { VSCodeWindow } from 'vs/code/electron-main/window'; import { TPromise } from 'vs/base/common/winjs.base'; import { IChannel } from 'vs/base/parts/ipc/common/ipc'; -import { ILogService } from 'vs/code/electron-main/log'; +import { ILogService } from 'vs/code/common/log'; import { IURLService } from 'vs/platform/url/common/url'; import { IProcessEnvironment } from 'vs/base/common/platform'; import { ParsedArgs } from 'vs/platform/environment/common/environment'; @@ -41,7 +41,7 @@ export class LaunchChannel implements ILaunchChannel { constructor(private service: ILaunchService) { } - call(command: string, arg: any): TPromise { + public call(command: string, arg: any): TPromise { switch (command) { case 'start': const { args, userEnv } = arg as IStartArguments; @@ -50,6 +50,7 @@ export class LaunchChannel implements ILaunchChannel { case 'get-main-process-id': return this.service.getMainProcessId(); } + return undefined; } } @@ -60,11 +61,11 @@ export class LaunchChannelClient implements ILaunchService { constructor(private channel: ILaunchChannel) { } - start(args: ParsedArgs, userEnv: IProcessEnvironment): TPromise { + public start(args: ParsedArgs, userEnv: IProcessEnvironment): TPromise { return this.channel.call('start', { args, userEnv }); } - getMainProcessId(): TPromise { + public getMainProcessId(): TPromise { return this.channel.call('get-main-process-id', null); } } @@ -79,19 +80,20 @@ export class LaunchService implements ILaunchService { @IURLService private urlService: IURLService ) { } - start(args: ParsedArgs, userEnv: IProcessEnvironment): TPromise { + public start(args: ParsedArgs, userEnv: IProcessEnvironment): TPromise { this.logService.log('Received data from other instance: ', args, userEnv); + // Check early for open-url which is handled in URL service const openUrlArg = args['open-url'] || []; const openUrl = typeof openUrlArg === 'string' ? [openUrlArg] : openUrlArg; - const context = !!userEnv['VSCODE_CLI'] ? OpenContext.CLI : OpenContext.DESKTOP; - if (openUrl.length > 0) { openUrl.forEach(url => this.urlService.open(url)); + return TPromise.as(null); } // Otherwise handle in windows service + const context = !!userEnv['VSCODE_CLI'] ? OpenContext.CLI : OpenContext.DESKTOP; let usedWindows: VSCodeWindow[]; if (!!args.extensionDevelopmentPath) { this.windowsService.openExtensionDevelopmentHostWindow({ context, cli: args, userEnv }); @@ -129,8 +131,9 @@ export class LaunchService implements ILaunchService { return TPromise.as(null); } - getMainProcessId(): TPromise { + public getMainProcessId(): TPromise { this.logService.log('Received request for process ID from other instance.'); + return TPromise.as(process.pid); } } \ No newline at end of file diff --git a/src/vs/code/electron-main/lifecycle.ts b/src/vs/code/electron-main/lifecycle.ts index 895f8b05684..fbeb9a85472 100644 --- a/src/vs/code/electron-main/lifecycle.ts +++ b/src/vs/code/electron-main/lifecycle.ts @@ -9,8 +9,8 @@ import { ipcMain as ipc, app } from 'electron'; import { TPromise, TValueCallback } from 'vs/base/common/winjs.base'; import { ReadyState, VSCodeWindow } from 'vs/code/electron-main/window'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; -import { ILogService } from 'vs/code/electron-main/log'; -import { IStorageService } from 'vs/code/electron-main/storage'; +import { ILogService } from 'vs/code/common/log'; +import { IStorageService } from 'vs/code/node/storage'; import Event, { Emitter } from 'vs/base/common/event'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; diff --git a/src/vs/code/electron-main/main.ts b/src/vs/code/electron-main/main.ts index 8294cc1f22b..41bb32a7c01 100644 --- a/src/vs/code/electron-main/main.ts +++ b/src/vs/code/electron-main/main.ts @@ -10,7 +10,7 @@ import { assign } from 'vs/base/common/objects'; import * as platform from 'vs/base/common/platform'; import { parseMainProcessArgv } from 'vs/platform/environment/node/argv'; import { mkdirp } from 'vs/base/node/pfs'; -import { validatePaths } from 'vs/code/electron-main/paths'; +import { validatePaths } from 'vs/code/node/paths'; import { LifecycleService, ILifecycleService } from 'vs/code/electron-main/lifecycle'; import { Server, serve, connect } from 'vs/base/parts/ipc/node/ipc.net'; import { TPromise } from 'vs/base/common/winjs.base'; @@ -19,8 +19,8 @@ import { ServicesAccessor, IInstantiationService } from 'vs/platform/instantiati import { InstantiationService } from 'vs/platform/instantiation/common/instantiationService'; import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; import { SyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; -import { ILogService, MainLogService } from 'vs/code/electron-main/log'; -import { IStorageService, StorageService } from 'vs/code/electron-main/storage'; +import { ILogService, MainLogService } from 'vs/code/common/log'; +import { IStorageService, StorageService } from 'vs/code/node/storage'; import { IBackupMainService } from 'vs/platform/backup/common/backup'; import { BackupMainService } from 'vs/platform/backup/electron-main/backupMainService'; import { IEnvironmentService, ParsedArgs } from 'vs/platform/environment/common/environment'; diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index fe14d6cf223..f267b326372 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -14,7 +14,7 @@ import { OpenContext } from 'vs/code/common/windows'; import { IWindowsMainService } from 'vs/code/electron-main/windows'; import { VSCodeWindow } from 'vs/code/electron-main/window'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { IStorageService } from 'vs/code/electron-main/storage'; +import { IStorageService } from 'vs/code/node/storage'; import { IFilesConfiguration, AutoSaveConfiguration } from 'vs/platform/files/common/files'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IUpdateService, State as UpdateState } from 'vs/platform/update/common/update'; diff --git a/src/vs/code/electron-main/sharedProcess.ts b/src/vs/code/electron-main/sharedProcess.ts index c70ce1239f6..5004700f7eb 100644 --- a/src/vs/code/electron-main/sharedProcess.ts +++ b/src/vs/code/electron-main/sharedProcess.ts @@ -14,6 +14,8 @@ import { PromiseSource } from 'vs/base/common/async'; export class SharedProcess { + private spawnPromiseSource: PromiseSource; + private window: Electron.BrowserWindow; private disposables: IDisposable[] = []; @@ -41,6 +43,7 @@ export class SharedProcess { this.disposables.push(toDisposable(() => this.window.removeListener('close', onClose))); this.disposables.push(toDisposable(() => { + // Electron seems to crash on Windows without this setTimeout :| setTimeout(() => { try { @@ -65,8 +68,6 @@ export class SharedProcess { }); } - private spawnPromiseSource: PromiseSource; - constructor( private environmentService: IEnvironmentService, private userEnv: IProcessEnvironment @@ -74,15 +75,15 @@ export class SharedProcess { this.spawnPromiseSource = new PromiseSource(); } - spawn(): void { + public spawn(): void { this.spawnPromiseSource.complete(); } - whenReady(): TPromise { + public whenReady(): TPromise { return this.spawnPromiseSource.value.then(() => this._whenReady); } - toggle(): void { + public toggle(): void { if (this.window.isVisible()) { this.hide(); } else { @@ -90,17 +91,17 @@ export class SharedProcess { } } - show(): void { + public show(): void { this.window.show(); this.window.webContents.openDevTools(); } - hide(): void { + public hide(): void { this.window.webContents.closeDevTools(); this.window.hide(); } - dispose(): void { + public dispose(): void { this.disposables = dispose(this.disposables); } } diff --git a/src/vs/code/electron-main/window.ts b/src/vs/code/electron-main/window.ts index 9d40c049ad7..58f27e2a355 100644 --- a/src/vs/code/electron-main/window.ts +++ b/src/vs/code/electron-main/window.ts @@ -9,11 +9,11 @@ import * as path from 'path'; import * as objects from 'vs/base/common/objects'; import { stopProfiling } from 'vs/base/node/profiler'; import nls = require('vs/nls'); -import { IStorageService } from 'vs/code/electron-main/storage'; +import { IStorageService } from 'vs/code/node/storage'; import { shell, screen, BrowserWindow, systemPreferences, app } from 'electron'; import { TPromise, TValueCallback } from 'vs/base/common/winjs.base'; import { IEnvironmentService, ParsedArgs } from 'vs/platform/environment/common/environment'; -import { ILogService } from 'vs/code/electron-main/log'; +import { ILogService } from 'vs/code/common/log'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { IWorkbenchEditorConfiguration } from 'vs/workbench/common/editor'; import { parseArgs } from 'vs/platform/environment/node/argv'; @@ -78,9 +78,6 @@ export interface IWindowConfiguration extends ParsedArgs { userEnv: IProcessEnvironment; - /** - * The physical keyboard is of ISO type (on OSX). - */ isISOKeyboard?: boolean; zoomLevel?: number; @@ -128,12 +125,6 @@ export enum ReadyState { READY } -interface IConfiguration { - window: { - menuBarVisibility: MenuBarVisibility; - }; -} - export class VSCodeWindow { public static themeStorageKey = 'theme'; @@ -153,7 +144,6 @@ export class VSCodeWindow { private _isExtensionTestHost: boolean; private windowState: IWindowState; private currentMenuBarVisibility: MenuBarVisibility; - private currentWindowMode: WindowMode; private toDispose: IDisposable[]; private representedFilename: string; @@ -177,11 +167,27 @@ export class VSCodeWindow { this.whenReadyCallbacks = []; this.toDispose = []; + // create browser window + this.createBrowserWindow(config); + + // respect configured menu bar visibility + this.onConfigurationUpdated(); + + // TODO@joao: hook this up to some initialization routine this causes a race between setting the headers and doing + // a request that needs them. chances are low + this.setCommonHTTPHeaders(); + + // Eventing + this.registerListeners(); + } + + private createBrowserWindow(config: IWindowCreationOptions): void { + // Load window state - this.restoreWindowState(config.state); + this.windowState = this.restoreWindowState(config.state); // in case we are maximized or fullscreen, only show later after the call to maximize/fullscreen (see below) - const isFullscreenOrMaximized = (this.currentWindowMode === WindowMode.Maximized || this.currentWindowMode === WindowMode.Fullscreen); + const isFullscreenOrMaximized = (this.windowState.mode === WindowMode.Maximized || this.windowState.mode === WindowMode.Fullscreen); const options: Electron.BrowserWindowOptions = { width: this.windowState.width, @@ -248,7 +254,7 @@ export class VSCodeWindow { if (isFullscreenOrMaximized) { this._win.maximize(); - if (this.currentWindowMode === WindowMode.Fullscreen) { + if (this.windowState.mode === WindowMode.Fullscreen) { this._win.setFullScreen(true); } @@ -258,16 +264,6 @@ export class VSCodeWindow { } this._lastFocusTime = Date.now(); // since we show directly, we need to set the last focus time too - - // respect configured menu bar visibility - this.onConfigurationUpdated(); - - // TODO@joao: hook this up to some initialization routine this causes a race between setting the headers and doing - // a request that needs them. chances are low - this.setCommonHTTPHeaders(); - - // Eventing - this.registerListeners(); } private setCommonHTTPHeaders(): void { @@ -376,20 +372,6 @@ export class VSCodeWindow { return this._readyState; } - private registerNavigationListenerOn(command: 'swipe' | 'app-command', back: 'left' | 'browser-backward', forward: 'right' | 'browser-forward', acrossEditors: boolean) { - this._win.on(command, (e, cmd) => { - if (this.readyState !== ReadyState.READY) { - return; // window must be ready - } - - if (cmd === back) { - this.send('vscode:runAction', acrossEditors ? 'workbench.action.openPreviousRecentlyUsedEditor' : 'workbench.action.navigateBack'); - } else if (cmd === forward) { - this.send('vscode:runAction', acrossEditors ? 'workbench.action.openNextRecentlyUsedEditor' : 'workbench.action.navigateForward'); - } - }); - } - private registerListeners(): void { // Remember that we loaded @@ -405,7 +387,7 @@ export class VSCodeWindow { // To prevent flashing, we set the window visible after the page has finished to load but before VSCode is loaded if (!this._win.isVisible()) { - if (this.currentWindowMode === WindowMode.Maximized) { + if (this.windowState.mode === WindowMode.Maximized) { this._win.maximize(); } @@ -487,6 +469,20 @@ export class VSCodeWindow { } }; + private registerNavigationListenerOn(command: 'swipe' | 'app-command', back: 'left' | 'browser-backward', forward: 'right' | 'browser-forward', acrossEditors: boolean) { + this._win.on(command, (e, cmd) => { + if (this.readyState !== ReadyState.READY) { + return; // window must be ready + } + + if (cmd === back) { + this.send('vscode:runAction', acrossEditors ? 'workbench.action.openPreviousRecentlyUsedEditor' : 'workbench.action.navigateBack'); + } else if (cmd === forward) { + this.send('vscode:runAction', acrossEditors ? 'workbench.action.openNextRecentlyUsedEditor' : 'workbench.action.navigateForward'); + } + }); + } + public load(config: IWindowConfiguration): void { // If this is the first time the window is loaded, we associate the paths @@ -527,8 +523,7 @@ export class VSCodeWindow { // (--prof-startup) save profile to disk const { profileStartup } = this.environmentService; if (profileStartup) { - stopProfiling(profileStartup.dir, profileStartup.prefix) - .done(undefined, err => console.error(err)); + stopProfiling(profileStartup.dir, profileStartup.prefix).done(undefined, err => console.error(err)); } } @@ -556,7 +551,6 @@ export class VSCodeWindow { } private getUrl(windowConfiguration: IWindowConfiguration): string { - let url = require.toUrl('vs/workbench/electron-browser/bootstrap/index.html'); // Set zoomlevel const windowConfig = this.configurationService.getConfiguration('window'); @@ -593,16 +587,16 @@ export class VSCodeWindow { } } - url += '?config=' + encodeURIComponent(JSON.stringify(config)); - - return url; + return `${require.toUrl('vs/workbench/electron-browser/bootstrap/index.html')}?config=${encodeURIComponent(JSON.stringify(config))}`; } private getBaseTheme(): string { if (isWindows && systemPreferences.isInvertedColorScheme()) { return 'hc-black'; } + const theme = this.storageService.getItem(VSCodeWindow.themeStorageKey, 'vs-dark'); + return theme.split(' ')[0]; } @@ -611,9 +605,10 @@ export class VSCodeWindow { return '#000000'; } - let background = this.storageService.getItem(VSCodeWindow.themeBackgroundStorageKey, null); + const background = this.storageService.getItem(VSCodeWindow.themeBackgroundStorageKey, null); if (!background) { - let baseTheme = this.getBaseTheme(); + const baseTheme = this.getBaseTheme(); + return baseTheme === 'hc-black' ? '#000000' : (baseTheme === 'vs' ? '#FFFFFF' : (isMacintosh ? '#171717' : '#1E1E1E')); // https://github.com/electron/electron/issues/5150 } @@ -668,7 +663,7 @@ export class VSCodeWindow { return state; } - private restoreWindowState(state?: IWindowState): void { + private restoreWindowState(state?: IWindowState): IWindowState { if (state) { try { state = this.validateWindowState(state); @@ -681,8 +676,7 @@ export class VSCodeWindow { state = defaultWindowState(); } - this.windowState = state; - this.currentWindowMode = this.windowState.mode; + return state; } private validateWindowState(state: IWindowState): IWindowState { diff --git a/src/vs/code/electron-main/windows.ts b/src/vs/code/electron-main/windows.ts index cc0800f25e6..75b6792e95d 100644 --- a/src/vs/code/electron-main/windows.ts +++ b/src/vs/code/electron-main/windows.ts @@ -15,13 +15,13 @@ import { assign, mixin } from 'vs/base/common/objects'; import { IBackupMainService } from 'vs/platform/backup/common/backup'; import { trim } from 'vs/base/common/strings'; import { IEnvironmentService, ParsedArgs } from 'vs/platform/environment/common/environment'; -import { IStorageService } from 'vs/code/electron-main/storage'; +import { IStorageService } from 'vs/code/node/storage'; import { IPath, VSCodeWindow, IWindowConfiguration, IWindowState as ISingleWindowState, defaultWindowState, WindowMode } from 'vs/code/electron-main/window'; import { ipcMain as ipc, app, screen, BrowserWindow, dialog } from 'electron'; -import { IPathWithLineAndColumn, parseLineAndColumnAware } from 'vs/code/electron-main/paths'; +import { IPathWithLineAndColumn, parseLineAndColumnAware } from 'vs/code/node/paths'; import { ILifecycleService, UnloadReason } from 'vs/code/electron-main/lifecycle'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { ILogService } from 'vs/code/electron-main/log'; +import { ILogService } from 'vs/code/common/log'; import { getPathLabel } from 'vs/base/common/labels'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; import { IWindowSettings } from 'vs/platform/windows/common/windows'; diff --git a/src/vs/code/electron-main/paths.ts b/src/vs/code/node/paths.ts similarity index 100% rename from src/vs/code/electron-main/paths.ts rename to src/vs/code/node/paths.ts diff --git a/src/vs/code/electron-main/shellEnv.ts b/src/vs/code/node/shellEnv.ts similarity index 100% rename from src/vs/code/electron-main/shellEnv.ts rename to src/vs/code/node/shellEnv.ts index 2afa773a341..92c146fefae 100644 --- a/src/vs/code/electron-main/shellEnv.ts +++ b/src/vs/code/node/shellEnv.ts @@ -11,7 +11,6 @@ import { generateUuid } from 'vs/base/common/uuid'; import { TPromise } from 'vs/base/common/winjs.base'; import { isWindows } from 'vs/base/common/platform'; - function getUnixShellEnvironment(): TPromise { const promise = new TPromise((c, e) => { const runAsNode = process.env['ELECTRON_RUN_AS_NODE']; @@ -88,5 +87,6 @@ export function getShellEnvironment(): TPromise { _shellEnv = getUnixShellEnvironment(); } } + return _shellEnv; } diff --git a/src/vs/code/electron-main/storage.ts b/src/vs/code/node/storage.ts similarity index 94% rename from src/vs/code/electron-main/storage.ts rename to src/vs/code/node/storage.ts index d3f1351b6cc..438a7af5b8d 100644 --- a/src/vs/code/electron-main/storage.ts +++ b/src/vs/code/node/storage.ts @@ -30,7 +30,7 @@ export class StorageService implements IStorageService { this.dbPath = path.join(environmentService.userDataPath, 'storage.json'); } - getItem(key: string, defaultValue?: T): T { + public getItem(key: string, defaultValue?: T): T { if (!this.database) { this.database = this.load(); } @@ -43,7 +43,7 @@ export class StorageService implements IStorageService { return this.database[key]; } - setItem(key: string, data: any): void { + public setItem(key: string, data: any): void { if (!this.database) { this.database = this.load(); } @@ -59,7 +59,7 @@ export class StorageService implements IStorageService { this.save(); } - removeItem(key: string): void { + public removeItem(key: string): void { if (!this.database) { this.database = this.load(); } diff --git a/src/vs/code/node/windowsUtils.ts b/src/vs/code/node/windowsUtils.ts index 31a4f00b354..a46c1d96168 100644 --- a/src/vs/code/node/windowsUtils.ts +++ b/src/vs/code/node/windowsUtils.ts @@ -43,6 +43,7 @@ export function findBestWindowOrFolder({ win } else if (bestFolder) { return bestFolder; } + return !newWindow ? getLastActiveWindow(windows) : null; } @@ -51,6 +52,7 @@ function findBestWindow(windows: WINDOW[], filePat if (containers.length) { return containers.sort((a, b) => -(a.openedWorkspacePath.length - b.openedWorkspacePath.length))[0]; } + return null; } @@ -60,6 +62,7 @@ function findBestFolder(filePath: string, userHome?: string, vscodeFolder?: stri if (!platform.isLinux) { homeFolder = homeFolder && homeFolder.toLowerCase(); } + let previous = null; try { while (folder !== previous) { @@ -72,22 +75,23 @@ function findBestFolder(filePath: string, userHome?: string, vscodeFolder?: stri } catch (err) { // assume impossible to access } + return null; } function isProjectFolder(folder: string, normalizedUserHome?: string, vscodeFolder = '.vscode') { try { if ((platform.isLinux ? folder : folder.toLowerCase()) === normalizedUserHome) { - // ~/.vscode/extensions is used for extensions - return fs.statSync(path.join(folder, vscodeFolder, 'settings.json')).isFile(); - } else { - return fs.statSync(path.join(folder, vscodeFolder)).isDirectory(); + return fs.statSync(path.join(folder, vscodeFolder, 'settings.json')).isFile(); // ~/.vscode/extensions is used for extensions } + + return fs.statSync(path.join(folder, vscodeFolder)).isDirectory(); } catch (err) { if (!(err && err.code === 'ENOENT')) { throw err; } } + return false; } -- GitLab From f97a4729b244ba7d69ebf6cab26fc52dc2cc8693 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 8 Jun 2017 12:23:04 +0200 Subject: [PATCH 0640/1347] debt - some cleanup on main services --- src/vs/code/common/windows.ts | 21 ------- src/vs/code/electron-main/app.ts | 9 ++- src/vs/code/electron-main/launch.ts | 7 +-- src/vs/code/electron-main/main.ts | 6 +- src/vs/code/electron-main/menus.ts | 4 +- src/vs/code/electron-main/window.ts | 51 ++++++++-------- src/vs/code/electron-main/windows.ts | 11 ++-- src/vs/code/node/windowsUtils.ts | 2 +- src/vs/code/test/node/windowsUtils.test.ts | 2 +- .../lifecycle/electron-main/lifecycleMain.ts} | 36 ++++++------ src/vs/{code => platform/log}/common/log.ts | 0 .../storage}/node/storage.ts | 0 .../update/electron-main/updateService.ts | 2 +- src/vs/platform/windows/common/windows.ts | 58 +++++++++++++++++++ .../windows/electron-main/windowsService.ts | 5 +- 15 files changed, 122 insertions(+), 92 deletions(-) rename src/vs/{code/electron-main/lifecycle.ts => platform/lifecycle/electron-main/lifecycleMain.ts} (85%) rename src/vs/{code => platform/log}/common/log.ts (100%) rename src/vs/{code => platform/storage}/node/storage.ts (100%) diff --git a/src/vs/code/common/windows.ts b/src/vs/code/common/windows.ts index 43c5fba2864..9d1610531c7 100644 --- a/src/vs/code/common/windows.ts +++ b/src/vs/code/common/windows.ts @@ -7,27 +7,6 @@ import Event from 'vs/base/common/event'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { IWindowsService } from 'vs/platform/windows/common/windows'; -export enum OpenContext { - - // opening when running from the command line - CLI, - - // macOS only: opening from the dock (also when opening files to a running instance from desktop) - DOCK, - - // opening from the main application window - MENU, - - // opening from a file or folder dialog - DIALOG, - - // opening from the OS's UI - DESKTOP, - - // opening through the API - API -} - export interface IWindowEventService { _serviceBrand: any; diff --git a/src/vs/code/electron-main/app.ts b/src/vs/code/electron-main/app.ts index 435423de2c2..bfa18af3509 100644 --- a/src/vs/code/electron-main/app.ts +++ b/src/vs/code/electron-main/app.ts @@ -7,12 +7,11 @@ import { app, ipcMain as ipc, BrowserWindow } from 'electron'; import * as platform from 'vs/base/common/platform'; -import { OpenContext } from 'vs/code/common/windows'; import { IWindowsMainService, WindowsManager } from 'vs/code/electron-main/windows'; -import { IWindowsService } from 'vs/platform/windows/common/windows'; +import { IWindowsService, OpenContext } from 'vs/platform/windows/common/windows'; import { WindowsChannel } from 'vs/platform/windows/common/windowsIpc'; import { WindowsService } from 'vs/platform/windows/electron-main/windowsService'; -import { ILifecycleService } from 'vs/code/electron-main/lifecycle'; +import { ILifecycleService } from 'vs/platform/lifecycle/electron-main/lifecycleMain'; import { VSCodeMenu } from 'vs/code/electron-main/menus'; import { getShellEnvironment } from 'vs/code/node/shellEnv'; import { IUpdateService } from 'vs/platform/update/common/update'; @@ -26,8 +25,8 @@ import { LaunchService, LaunchChannel, ILaunchService } from './launch'; import { IInstantiationService, ServicesAccessor } from 'vs/platform/instantiation/common/instantiation'; import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; import { SyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; -import { ILogService } from 'vs/code/common/log'; -import { IStorageService } from 'vs/code/node/storage'; +import { ILogService } from 'vs/platform/log/common/log'; +import { IStorageService } from 'vs/platform/storage/node/storage'; import { IBackupMainService } from 'vs/platform/backup/common/backup'; import { BackupChannel } from 'vs/platform/backup/common/backupIpc'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; diff --git a/src/vs/code/electron-main/launch.ts b/src/vs/code/electron-main/launch.ts index c8a6347a9de..99103a7b5b4 100644 --- a/src/vs/code/electron-main/launch.ts +++ b/src/vs/code/electron-main/launch.ts @@ -5,17 +5,16 @@ 'use strict'; -import { OpenContext } from 'vs/code/common/windows'; import { IWindowsMainService } from 'vs/code/electron-main/windows'; -import { VSCodeWindow } from 'vs/code/electron-main/window'; import { TPromise } from 'vs/base/common/winjs.base'; import { IChannel } from 'vs/base/parts/ipc/common/ipc'; -import { ILogService } from 'vs/code/common/log'; +import { ILogService } from 'vs/platform/log/common/log'; import { IURLService } from 'vs/platform/url/common/url'; import { IProcessEnvironment } from 'vs/base/common/platform'; import { ParsedArgs } from 'vs/platform/environment/common/environment'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; import { once } from 'vs/base/common/event'; +import { ICodeWindow, OpenContext } from "vs/platform/windows/common/windows"; export const ID = 'launchService'; export const ILaunchService = createDecorator(ID); @@ -94,7 +93,7 @@ export class LaunchService implements ILaunchService { // Otherwise handle in windows service const context = !!userEnv['VSCODE_CLI'] ? OpenContext.CLI : OpenContext.DESKTOP; - let usedWindows: VSCodeWindow[]; + let usedWindows: ICodeWindow[]; if (!!args.extensionDevelopmentPath) { this.windowsService.openExtensionDevelopmentHostWindow({ context, cli: args, userEnv }); } else if (args._.length === 0 && (args['new-window'] || args['unity-launch'])) { diff --git a/src/vs/code/electron-main/main.ts b/src/vs/code/electron-main/main.ts index 41bb32a7c01..4b76c411f8f 100644 --- a/src/vs/code/electron-main/main.ts +++ b/src/vs/code/electron-main/main.ts @@ -11,7 +11,7 @@ import * as platform from 'vs/base/common/platform'; import { parseMainProcessArgv } from 'vs/platform/environment/node/argv'; import { mkdirp } from 'vs/base/node/pfs'; import { validatePaths } from 'vs/code/node/paths'; -import { LifecycleService, ILifecycleService } from 'vs/code/electron-main/lifecycle'; +import { LifecycleService, ILifecycleService } from 'vs/platform/lifecycle/electron-main/lifecycleMain'; import { Server, serve, connect } from 'vs/base/parts/ipc/node/ipc.net'; import { TPromise } from 'vs/base/common/winjs.base'; import { ILaunchChannel, LaunchChannelClient } from './launch'; @@ -19,8 +19,8 @@ import { ServicesAccessor, IInstantiationService } from 'vs/platform/instantiati import { InstantiationService } from 'vs/platform/instantiation/common/instantiationService'; import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; import { SyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; -import { ILogService, MainLogService } from 'vs/code/common/log'; -import { IStorageService, StorageService } from 'vs/code/node/storage'; +import { ILogService, MainLogService } from 'vs/platform/log/common/log'; +import { IStorageService, StorageService } from 'vs/platform/storage/node/storage'; import { IBackupMainService } from 'vs/platform/backup/common/backup'; import { BackupMainService } from 'vs/platform/backup/electron-main/backupMainService'; import { IEnvironmentService, ParsedArgs } from 'vs/platform/environment/common/environment'; diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index f267b326372..559b253ff55 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -10,11 +10,11 @@ import { isMacintosh, isLinux, isWindows, language } from 'vs/base/common/platfo import * as arrays from 'vs/base/common/arrays'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { ipcMain as ipc, app, shell, dialog, Menu, MenuItem, BrowserWindow } from 'electron'; -import { OpenContext } from 'vs/code/common/windows'; +import { OpenContext } from "vs/platform/windows/common/windows"; import { IWindowsMainService } from 'vs/code/electron-main/windows'; import { VSCodeWindow } from 'vs/code/electron-main/window'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { IStorageService } from 'vs/code/node/storage'; +import { IStorageService } from 'vs/platform/storage/node/storage'; import { IFilesConfiguration, AutoSaveConfiguration } from 'vs/platform/files/common/files'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IUpdateService, State as UpdateState } from 'vs/platform/update/common/update'; diff --git a/src/vs/code/electron-main/window.ts b/src/vs/code/electron-main/window.ts index 58f27e2a355..c4dfa4046ec 100644 --- a/src/vs/code/electron-main/window.ts +++ b/src/vs/code/electron-main/window.ts @@ -9,20 +9,21 @@ import * as path from 'path'; import * as objects from 'vs/base/common/objects'; import { stopProfiling } from 'vs/base/node/profiler'; import nls = require('vs/nls'); -import { IStorageService } from 'vs/code/node/storage'; +import { IStorageService } from 'vs/platform/storage/node/storage'; import { shell, screen, BrowserWindow, systemPreferences, app } from 'electron'; import { TPromise, TValueCallback } from 'vs/base/common/winjs.base'; import { IEnvironmentService, ParsedArgs } from 'vs/platform/environment/common/environment'; -import { ILogService } from 'vs/code/common/log'; +import { ILogService } from 'vs/platform/log/common/log'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { IWorkbenchEditorConfiguration } from 'vs/workbench/common/editor'; import { parseArgs } from 'vs/platform/environment/node/argv'; import product from 'vs/platform/node/product'; import { getCommonHTTPHeaders } from 'vs/platform/environment/node/http'; -import { IWindowSettings, MenuBarVisibility } from 'vs/platform/windows/common/windows'; +import { IWindowSettings, MenuBarVisibility, ICodeWindow, ReadyState, IWindowCloseEvent } from 'vs/platform/windows/common/windows'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { KeyboardLayoutMonitor } from 'vs/code/node/keyboard'; import { IProcessEnvironment, isLinux, isMacintosh, isWindows } from "vs/base/common/platform"; +import CommonEvent, { Emitter } from "vs/base/common/event"; export interface IWindowState { width?: number; @@ -102,30 +103,7 @@ export interface IWindowConfiguration extends ParsedArgs { nodeCachedDataDir: string; } -export enum ReadyState { - - /** - * This window has not loaded any HTML yet - */ - NONE, - - /** - * This window is loading HTML - */ - LOADING, - - /** - * This window is navigating to another HTML - */ - NAVIGATING, - - /** - * This window is done loading HTML - */ - READY -} - -export class VSCodeWindow { +export class VSCodeWindow implements ICodeWindow { public static themeStorageKey = 'theme'; public static themeBackgroundStorageKey = 'themeBackground'; @@ -133,6 +111,7 @@ export class VSCodeWindow { private static MIN_WIDTH = 200; private static MIN_HEIGHT = 120; + private _onClose: Emitter; private options: IWindowCreationOptions; private hiddenTitleBarStyle: boolean; private showTimeoutHandle: any; @@ -167,6 +146,9 @@ export class VSCodeWindow { this.whenReadyCallbacks = []; this.toDispose = []; + this._onClose = new Emitter(); + this.toDispose.push(this._onClose); + // create browser window this.createBrowserWindow(config); @@ -181,6 +163,10 @@ export class VSCodeWindow { this.registerListeners(); } + public get onClose(): CommonEvent { + return this._onClose.event; + } + private createBrowserWindow(config: IWindowCreationOptions): void { // Load window state @@ -374,6 +360,11 @@ export class VSCodeWindow { private registerListeners(): void { + // Re-emit close event + this._win.on('close', e => { + this._onClose.fire(e); + }); + // Remember that we loaded this._win.webContents.on('did-finish-load', () => { this._readyState = ReadyState.LOADING; @@ -861,6 +852,12 @@ export class VSCodeWindow { } } + public close(): void { + if (this._win) { + this._win.close(); + } + } + public sendWhenReady(channel: string, ...args: any[]): void { this.ready().then(() => { this.send(channel, ...args); diff --git a/src/vs/code/electron-main/windows.ts b/src/vs/code/electron-main/windows.ts index 75b6792e95d..2fb4b771094 100644 --- a/src/vs/code/electron-main/windows.ts +++ b/src/vs/code/electron-main/windows.ts @@ -15,20 +15,19 @@ import { assign, mixin } from 'vs/base/common/objects'; import { IBackupMainService } from 'vs/platform/backup/common/backup'; import { trim } from 'vs/base/common/strings'; import { IEnvironmentService, ParsedArgs } from 'vs/platform/environment/common/environment'; -import { IStorageService } from 'vs/code/node/storage'; +import { IStorageService } from 'vs/platform/storage/node/storage'; import { IPath, VSCodeWindow, IWindowConfiguration, IWindowState as ISingleWindowState, defaultWindowState, WindowMode } from 'vs/code/electron-main/window'; import { ipcMain as ipc, app, screen, BrowserWindow, dialog } from 'electron'; import { IPathWithLineAndColumn, parseLineAndColumnAware } from 'vs/code/node/paths'; -import { ILifecycleService, UnloadReason } from 'vs/code/electron-main/lifecycle'; +import { ILifecycleService, UnloadReason } from 'vs/platform/lifecycle/electron-main/lifecycleMain'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { ILogService } from 'vs/code/common/log'; +import { ILogService } from 'vs/platform/log/common/log'; import { getPathLabel } from 'vs/base/common/labels'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; -import { IWindowSettings } from 'vs/platform/windows/common/windows'; +import { IWindowSettings, OpenContext } from 'vs/platform/windows/common/windows'; import { getLastActiveWindow, findBestWindowOrFolder } from 'vs/code/node/windowsUtils'; import CommonEvent, { Emitter } from 'vs/base/common/event'; import product from 'vs/platform/node/product'; -import { OpenContext } from 'vs/code/common/windows'; import { ITelemetryService, ITelemetryData } from 'vs/platform/telemetry/common/telemetry'; import { isParent, isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; import { KeyboardLayoutMonitor } from 'vs/code/node/keyboard'; @@ -253,7 +252,7 @@ export class WindowsManager implements IWindowsMainService { }); // Update our windows state before quitting and before closing windows - this.lifecycleService.onBeforeWindowClose(win => this.onBeforeWindowClose(win)); + this.lifecycleService.onBeforeWindowClose(win => this.onBeforeWindowClose(win as VSCodeWindow)); this.lifecycleService.onBeforeQuit(() => this.onBeforeQuit()); // Keyboard layout changes diff --git a/src/vs/code/node/windowsUtils.ts b/src/vs/code/node/windowsUtils.ts index a46c1d96168..2f8407e0a4e 100644 --- a/src/vs/code/node/windowsUtils.ts +++ b/src/vs/code/node/windowsUtils.ts @@ -9,7 +9,7 @@ import * as path from 'path'; import * as fs from 'fs'; import * as platform from 'vs/base/common/platform'; import * as paths from 'vs/base/common/paths'; -import { OpenContext } from 'vs/code/common/windows'; +import { OpenContext } from "vs/platform/windows/common/windows"; import { isEqualOrParent } from 'vs/platform/files/common/files'; /** diff --git a/src/vs/code/test/node/windowsUtils.test.ts b/src/vs/code/test/node/windowsUtils.test.ts index 42649abda76..e8472fd9ae9 100644 --- a/src/vs/code/test/node/windowsUtils.test.ts +++ b/src/vs/code/test/node/windowsUtils.test.ts @@ -7,7 +7,7 @@ import assert = require('assert'); import path = require('path'); import { findBestWindowOrFolder, ISimpleWindow, IBestWindowOrFolderOptions } from 'vs/code/node/windowsUtils'; -import { OpenContext } from 'vs/code/common/windows'; +import { OpenContext } from "vs/platform/windows/common/windows"; const fixturesFolder = require.toUrl('./fixtures'); diff --git a/src/vs/code/electron-main/lifecycle.ts b/src/vs/platform/lifecycle/electron-main/lifecycleMain.ts similarity index 85% rename from src/vs/code/electron-main/lifecycle.ts rename to src/vs/platform/lifecycle/electron-main/lifecycleMain.ts index fbeb9a85472..2dc0242f8cf 100644 --- a/src/vs/code/electron-main/lifecycle.ts +++ b/src/vs/platform/lifecycle/electron-main/lifecycleMain.ts @@ -7,12 +7,12 @@ import { ipcMain as ipc, app } from 'electron'; import { TPromise, TValueCallback } from 'vs/base/common/winjs.base'; -import { ReadyState, VSCodeWindow } from 'vs/code/electron-main/window'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; -import { ILogService } from 'vs/code/common/log'; -import { IStorageService } from 'vs/code/node/storage'; +import { ILogService } from 'vs/platform/log/common/log'; +import { IStorageService } from 'vs/platform/storage/node/storage'; import Event, { Emitter } from 'vs/base/common/event'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; +import { ICodeWindow, ReadyState } from "vs/platform/windows/common/windows"; export const ILifecycleService = createDecorator('lifecycleService'); @@ -43,12 +43,12 @@ export interface ILifecycleService { * is called even when the window prevents the closing. We want an event that truly fires * before the window gets closed for real. */ - onBeforeWindowClose: Event; + onBeforeWindowClose: Event; ready(): void; - registerWindow(vscodeWindow: VSCodeWindow): void; + registerWindow(codeWindow: ICodeWindow): void; - unload(vscodeWindow: VSCodeWindow, reason: UnloadReason): TPromise; + unload(codeWindow: ICodeWindow, reason: UnloadReason): TPromise; relaunch(options?: { addArgs?: string[], removeArgs?: string[] }); @@ -74,8 +74,8 @@ export class LifecycleService implements ILifecycleService { private _onBeforeQuit = new Emitter(); onBeforeQuit: Event = this._onBeforeQuit.event; - private _onBeforeWindowClose = new Emitter(); - onBeforeWindowClose: Event = this._onBeforeWindowClose.event; + private _onBeforeWindowClose = new Emitter(); + onBeforeWindowClose: Event = this._onBeforeWindowClose.event; constructor( @IEnvironmentService private environmentService: IEnvironmentService, @@ -132,11 +132,11 @@ export class LifecycleService implements ILifecycleService { }); } - public registerWindow(vscodeWindow: VSCodeWindow): void { + public registerWindow(codeWindow: ICodeWindow): void { // Window Before Closing: Main -> Renderer - vscodeWindow.win.on('close', (e) => { - const windowId = vscodeWindow.id; + codeWindow.onClose(e => { + const windowId = codeWindow.id; this.logService.log('Lifecycle#window-before-close', windowId); // The window already acknowledged to be closed @@ -150,11 +150,11 @@ export class LifecycleService implements ILifecycleService { // Otherwise prevent unload and handle it from window e.preventDefault(); - this.unload(vscodeWindow, UnloadReason.CLOSE).done(veto => { + this.unload(codeWindow, UnloadReason.CLOSE).done(veto => { if (!veto) { this.windowToCloseRequest[windowId] = true; - this._onBeforeWindowClose.fire(vscodeWindow); - vscodeWindow.win.close(); + this._onBeforeWindowClose.fire(codeWindow); + codeWindow.close(); } else { this.quitRequested = false; delete this.windowToCloseRequest[windowId]; @@ -163,14 +163,14 @@ export class LifecycleService implements ILifecycleService { }); } - public unload(vscodeWindow: VSCodeWindow, reason: UnloadReason): TPromise { + public unload(codeWindow: ICodeWindow, reason: UnloadReason): TPromise { // Always allow to unload a window that is not yet ready - if (vscodeWindow.readyState !== ReadyState.READY) { + if (codeWindow.readyState !== ReadyState.READY) { return TPromise.as(false); } - this.logService.log('Lifecycle#unload()', vscodeWindow.id); + this.logService.log('Lifecycle#unload()', codeWindow.id); return new TPromise((c) => { const oneTimeEventToken = this.oneTimeListenerTokenGenerator++; @@ -193,7 +193,7 @@ export class LifecycleService implements ILifecycleService { c(true); // veto }); - vscodeWindow.send('vscode:beforeUnload', { okChannel, cancelChannel, reason: this.quitRequested ? UnloadReason.QUIT : reason }); + codeWindow.send('vscode:beforeUnload', { okChannel, cancelChannel, reason: this.quitRequested ? UnloadReason.QUIT : reason }); }); } diff --git a/src/vs/code/common/log.ts b/src/vs/platform/log/common/log.ts similarity index 100% rename from src/vs/code/common/log.ts rename to src/vs/platform/log/common/log.ts diff --git a/src/vs/code/node/storage.ts b/src/vs/platform/storage/node/storage.ts similarity index 100% rename from src/vs/code/node/storage.ts rename to src/vs/platform/storage/node/storage.ts diff --git a/src/vs/platform/update/electron-main/updateService.ts b/src/vs/platform/update/electron-main/updateService.ts index 4db56de6d64..9a106da3718 100644 --- a/src/vs/platform/update/electron-main/updateService.ts +++ b/src/vs/platform/update/electron-main/updateService.ts @@ -16,7 +16,7 @@ import { fromEventEmitter } from 'vs/base/node/event'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { Win32AutoUpdaterImpl } from './auto-updater.win32'; import { LinuxAutoUpdaterImpl } from './auto-updater.linux'; -import { ILifecycleService } from 'vs/code/electron-main/lifecycle'; +import { ILifecycleService } from 'vs/platform/lifecycle/electron-main/lifecycleMain'; import { IRequestService } from 'vs/platform/request/node/request'; import product from 'vs/platform/node/product'; import { TPromise } from 'vs/base/common/winjs.base'; diff --git a/src/vs/platform/windows/common/windows.ts b/src/vs/platform/windows/common/windows.ts index b85f0b15315..3ca41ea3f3b 100644 --- a/src/vs/platform/windows/common/windows.ts +++ b/src/vs/platform/windows/common/windows.ts @@ -108,3 +108,61 @@ export interface IWindowSettings { nativeTabs: boolean; enableMenuBarMnemonics: boolean; } + +export interface IWindowCloseEvent { + preventDefault: Function; +} + +export interface ICodeWindow { + id: number; + readyState: ReadyState; + + onClose: Event; + + close(): void; + send(channel: string, ...args: any[]): void; +} + +export enum ReadyState { + + /** + * This window has not loaded any HTML yet + */ + NONE, + + /** + * This window is loading HTML + */ + LOADING, + + /** + * This window is navigating to another HTML + */ + NAVIGATING, + + /** + * This window is done loading HTML + */ + READY +} + +export enum OpenContext { + + // opening when running from the command line + CLI, + + // macOS only: opening from the dock (also when opening files to a running instance from desktop) + DOCK, + + // opening from the main application window + MENU, + + // opening from a file or folder dialog + DIALOG, + + // opening from the OS's UI + DESKTOP, + + // opening through the API + API +} \ No newline at end of file diff --git a/src/vs/platform/windows/electron-main/windowsService.ts b/src/vs/platform/windows/electron-main/windowsService.ts index 9d147b623ca..28d29556f17 100644 --- a/src/vs/platform/windows/electron-main/windowsService.ts +++ b/src/vs/platform/windows/electron-main/windowsService.ts @@ -9,16 +9,15 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { assign } from 'vs/base/common/objects'; import URI from 'vs/base/common/uri'; -import { IWindowsService } from 'vs/platform/windows/common/windows'; +import { IWindowsService, OpenContext } from 'vs/platform/windows/common/windows'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { shell, crashReporter, app } from 'electron'; import Event, { chain } from 'vs/base/common/event'; import { fromEventEmitter } from 'vs/base/node/event'; import { IURLService } from 'vs/platform/url/common/url'; import { ITelemetryData } from 'vs/platform/telemetry/common/telemetry'; -import { OpenContext } from 'vs/code/common/windows'; // TODO@Joao: remove this dependency, move all implementation to this class import { IWindowsMainService } from 'vs/code/electron-main/windows'; -import { ILifecycleService } from "vs/code/electron-main/lifecycle"; +import { ILifecycleService } from "vs/platform/lifecycle/electron-main/lifecycleMain"; export interface ISharedProcess { whenReady(): TPromise; -- GitLab From 129ba23f70e31f226b37be639e2088989956b5fe Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 8 Jun 2017 12:26:32 +0200 Subject: [PATCH 0641/1347] vscodeWindow => codeWindow --- src/vs/code/electron-main/menus.ts | 4 +- src/vs/code/electron-main/window.ts | 16 +-- src/vs/code/electron-main/windows.ts | 134 +++++++++--------- src/vs/code/node/windowsUtils.ts | 2 +- .../windows/electron-main/windowsService.ts | 96 ++++++------- 5 files changed, 126 insertions(+), 126 deletions(-) diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index 559b253ff55..50f71919883 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -12,7 +12,7 @@ import { IEnvironmentService } from 'vs/platform/environment/common/environment' import { ipcMain as ipc, app, shell, dialog, Menu, MenuItem, BrowserWindow } from 'electron'; import { OpenContext } from "vs/platform/windows/common/windows"; import { IWindowsMainService } from 'vs/code/electron-main/windows'; -import { VSCodeWindow } from 'vs/code/electron-main/window'; +import { CodeWindow } from 'vs/code/electron-main/window'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { IStorageService } from 'vs/platform/storage/node/storage'; import { IFilesConfiguration, AutoSaveConfiguration } from 'vs/platform/files/common/files'; @@ -129,7 +129,7 @@ class KeybindingsResolver { this.windowsService.onWindowReload(() => this.resolveKeybindings()); } - private resolveKeybindings(win: VSCodeWindow = this.windowsService.getLastActiveWindow()): void { + private resolveKeybindings(win: CodeWindow = this.windowsService.getLastActiveWindow()): void { if (this.commandIds.size && win) { const commandIds = []; this.commandIds.forEach(id => commandIds.push(id)); diff --git a/src/vs/code/electron-main/window.ts b/src/vs/code/electron-main/window.ts index c4dfa4046ec..09e16223e15 100644 --- a/src/vs/code/electron-main/window.ts +++ b/src/vs/code/electron-main/window.ts @@ -103,7 +103,7 @@ export interface IWindowConfiguration extends ParsedArgs { nodeCachedDataDir: string; } -export class VSCodeWindow implements ICodeWindow { +export class CodeWindow implements ICodeWindow { public static themeStorageKey = 'theme'; public static themeBackgroundStorageKey = 'themeBackground'; @@ -126,7 +126,7 @@ export class VSCodeWindow implements ICodeWindow { private toDispose: IDisposable[]; private representedFilename: string; - private whenReadyCallbacks: TValueCallback[]; + private whenReadyCallbacks: TValueCallback[]; private currentConfig: IWindowConfiguration; private pendingLoadConfig: IWindowConfiguration; @@ -181,8 +181,8 @@ export class VSCodeWindow implements ICodeWindow { x: this.windowState.x, y: this.windowState.y, backgroundColor: this.getBackgroundColor(), - minWidth: VSCodeWindow.MIN_WIDTH, - minHeight: VSCodeWindow.MIN_HEIGHT, + minWidth: CodeWindow.MIN_WIDTH, + minHeight: CodeWindow.MIN_HEIGHT, show: !isFullscreenOrMaximized, title: product.nameLong, webPreferences: { @@ -343,8 +343,8 @@ export class VSCodeWindow implements ICodeWindow { } } - public ready(): TPromise { - return new TPromise((c) => { + public ready(): TPromise { + return new TPromise((c) => { if (this._readyState === ReadyState.READY) { return c(this); } @@ -586,7 +586,7 @@ export class VSCodeWindow implements ICodeWindow { return 'hc-black'; } - const theme = this.storageService.getItem(VSCodeWindow.themeStorageKey, 'vs-dark'); + const theme = this.storageService.getItem(CodeWindow.themeStorageKey, 'vs-dark'); return theme.split(' ')[0]; } @@ -596,7 +596,7 @@ export class VSCodeWindow implements ICodeWindow { return '#000000'; } - const background = this.storageService.getItem(VSCodeWindow.themeBackgroundStorageKey, null); + const background = this.storageService.getItem(CodeWindow.themeBackgroundStorageKey, null); if (!background) { const baseTheme = this.getBaseTheme(); diff --git a/src/vs/code/electron-main/windows.ts b/src/vs/code/electron-main/windows.ts index 2fb4b771094..e31775df667 100644 --- a/src/vs/code/electron-main/windows.ts +++ b/src/vs/code/electron-main/windows.ts @@ -16,7 +16,7 @@ import { IBackupMainService } from 'vs/platform/backup/common/backup'; import { trim } from 'vs/base/common/strings'; import { IEnvironmentService, ParsedArgs } from 'vs/platform/environment/common/environment'; import { IStorageService } from 'vs/platform/storage/node/storage'; -import { IPath, VSCodeWindow, IWindowConfiguration, IWindowState as ISingleWindowState, defaultWindowState, WindowMode } from 'vs/code/electron-main/window'; +import { IPath, CodeWindow, IWindowConfiguration, IWindowState as ISingleWindowState, defaultWindowState, WindowMode } from 'vs/code/electron-main/window'; import { ipcMain as ipc, app, screen, BrowserWindow, dialog } from 'electron'; import { IPathWithLineAndColumn, parseLineAndColumnAware } from 'vs/code/node/paths'; import { ILifecycleService, UnloadReason } from 'vs/platform/lifecycle/electron-main/lifecycleMain'; @@ -46,7 +46,7 @@ export interface IOpenConfiguration { forceNewWindow?: boolean; forceReuseWindow?: boolean; forceEmpty?: boolean; - windowToUse?: VSCodeWindow; + windowToUse?: CodeWindow; diffMode?: boolean; initialStartup?: boolean; } @@ -76,7 +76,7 @@ interface INativeOpenDialogOptions { pickFiles?: boolean; path?: string; forceNewWindow?: boolean; - window?: VSCodeWindow; + window?: CodeWindow; } const ReopenFoldersSetting = { @@ -91,7 +91,7 @@ export interface IWindowsMainService { _serviceBrand: any; // events - onWindowReady: CommonEvent; + onWindowReady: CommonEvent; onWindowClose: CommonEvent; onWindowReload: CommonEvent; onPathsOpen: CommonEvent; @@ -99,21 +99,21 @@ export interface IWindowsMainService { // methods ready(initialUserEnv: platform.IProcessEnvironment): void; - reload(win: VSCodeWindow, cli?: ParsedArgs): void; - open(openConfig: IOpenConfiguration): VSCodeWindow[]; + reload(win: CodeWindow, cli?: ParsedArgs): void; + open(openConfig: IOpenConfiguration): CodeWindow[]; openExtensionDevelopmentHostWindow(openConfig: IOpenConfiguration): void; openFileFolderPicker(forceNewWindow?: boolean, data?: ITelemetryData): void; - openFilePicker(forceNewWindow?: boolean, path?: string, window?: VSCodeWindow, data?: ITelemetryData): void; - openFolderPicker(forceNewWindow?: boolean, window?: VSCodeWindow, data?: ITelemetryData): void; - focusLastActive(cli: ParsedArgs, context: OpenContext): VSCodeWindow; - getLastActiveWindow(): VSCodeWindow; - findWindow(workspacePath: string, filePath?: string, extensionDevelopmentPath?: string): VSCodeWindow; + openFilePicker(forceNewWindow?: boolean, path?: string, window?: CodeWindow, data?: ITelemetryData): void; + openFolderPicker(forceNewWindow?: boolean, window?: CodeWindow, data?: ITelemetryData): void; + focusLastActive(cli: ParsedArgs, context: OpenContext): CodeWindow; + getLastActiveWindow(): CodeWindow; + findWindow(workspacePath: string, filePath?: string, extensionDevelopmentPath?: string): CodeWindow; openNewWindow(context: OpenContext): void; sendToFocused(channel: string, ...args: any[]): void; sendToAll(channel: string, payload: any, windowIdsToIgnore?: number[]): void; - getFocusedWindow(): VSCodeWindow; - getWindowById(windowId: number): VSCodeWindow; - getWindows(): VSCodeWindow[]; + getFocusedWindow(): CodeWindow; + getWindowById(windowId: number): CodeWindow; + getWindows(): CodeWindow[]; getWindowCount(): number; addToRecentPathsList(paths: { path: string; isFile?: boolean; }[]): void; getRecentPathsList(workspacePath?: string, filesToOpen?: IPath[]): IRecentPathsList; @@ -134,7 +134,7 @@ export class WindowsManager implements IWindowsMainService { private static workingDirPickerStorageKey = 'pickerWorkingDir'; private static windowsStateStorageKey = 'windowsState'; - private static WINDOWS: VSCodeWindow[] = []; + private static WINDOWS: CodeWindow[] = []; private initialUserEnv: platform.IProcessEnvironment; @@ -144,8 +144,8 @@ export class WindowsManager implements IWindowsMainService { private _onRecentPathsChange = new Emitter(); onRecentPathsChange: CommonEvent = this._onRecentPathsChange.event; - private _onWindowReady = new Emitter(); - onWindowReady: CommonEvent = this._onWindowReady.event; + private _onWindowReady = new Emitter(); + onWindowReady: CommonEvent = this._onWindowReady.event; private _onWindowClose = new Emitter(); onWindowClose: CommonEvent = this._onWindowClose.event; @@ -252,7 +252,7 @@ export class WindowsManager implements IWindowsMainService { }); // Update our windows state before quitting and before closing windows - this.lifecycleService.onBeforeWindowClose(win => this.onBeforeWindowClose(win as VSCodeWindow)); + this.lifecycleService.onBeforeWindowClose(win => this.onBeforeWindowClose(win as CodeWindow)); this.lifecycleService.onBeforeQuit(() => this.onBeforeQuit()); // Keyboard layout changes @@ -310,7 +310,7 @@ export class WindowsManager implements IWindowsMainService { } // See note on #onBeforeQuit() for details how these events are flowing - private onBeforeWindowClose(win: VSCodeWindow): void { + private onBeforeWindowClose(win: CodeWindow): void { if (this.lifecycleService.isQuitRequested()) { return; // during quit, many windows close in parallel so let it be handled in the before-quit handler } @@ -345,11 +345,11 @@ export class WindowsManager implements IWindowsMainService { if (event === 'vscode:changeColorTheme' && typeof payload === 'string') { let data = JSON.parse(payload); - this.storageService.setItem(VSCodeWindow.themeStorageKey, data.id); - this.storageService.setItem(VSCodeWindow.themeBackgroundStorageKey, data.background); + this.storageService.setItem(CodeWindow.themeStorageKey, data.id); + this.storageService.setItem(CodeWindow.themeBackgroundStorageKey, data.background); } } - public reload(win: VSCodeWindow, cli?: ParsedArgs): void { + public reload(win: CodeWindow, cli?: ParsedArgs): void { // Only reload when the window has not vetoed this this.lifecycleService.unload(win, UnloadReason.RELOAD).done(veto => { @@ -362,11 +362,11 @@ export class WindowsManager implements IWindowsMainService { }); } - public open(openConfig: IOpenConfiguration): VSCodeWindow[] { + public open(openConfig: IOpenConfiguration): CodeWindow[] { const windowConfig = this.configurationService.getConfiguration('window'); let iPathsToOpen: IPath[]; - const usedWindows: VSCodeWindow[] = []; + const usedWindows: CodeWindow[] = []; // Find paths from provided paths if any if (openConfig.pathsToOpen && openConfig.pathsToOpen.length > 0) { @@ -471,7 +471,7 @@ export class WindowsManager implements IWindowsMainService { filePath: fileToCheck && fileToCheck.filePath, userHome: this.environmentService.userHome }); - if (windowOrFolder instanceof VSCodeWindow) { + if (windowOrFolder instanceof CodeWindow) { windowOrFolder.focus(); const files = { filesToOpen, filesToCreate, filesToDiff }; // copy to object because they get reset shortly after windowOrFolder.ready().then(readyWindow => { @@ -821,19 +821,19 @@ export class WindowsManager implements IWindowsMainService { return [Object.create(null)]; } - private openInBrowserWindow(configuration: IWindowConfiguration, forceNewWindow?: boolean, windowToUse?: VSCodeWindow, emptyWorkspaceBackupFolder?: string): VSCodeWindow { - let vscodeWindow: VSCodeWindow; + private openInBrowserWindow(configuration: IWindowConfiguration, forceNewWindow?: boolean, windowToUse?: CodeWindow, emptyWorkspaceBackupFolder?: string): CodeWindow { + let codeWindow: CodeWindow; if (!forceNewWindow) { - vscodeWindow = windowToUse || this.getLastActiveWindow(); + codeWindow = windowToUse || this.getLastActiveWindow(); - if (vscodeWindow) { - vscodeWindow.focus(); + if (codeWindow) { + codeWindow.focus(); } } // New window - if (!vscodeWindow) { + if (!codeWindow) { const windowConfig = this.configurationService.getConfiguration('window'); const state = this.getNewWindowState(configuration); @@ -852,7 +852,7 @@ export class WindowsManager implements IWindowsMainService { state.mode = WindowMode.Normal; } - vscodeWindow = new VSCodeWindow({ + codeWindow = new CodeWindow({ state, extensionDevelopmentPath: configuration.extensionDevelopmentPath, isExtensionTestHost: !!configuration.extensionTestsPath @@ -863,17 +863,17 @@ export class WindowsManager implements IWindowsMainService { this.storageService ); - WindowsManager.WINDOWS.push(vscodeWindow); + WindowsManager.WINDOWS.push(codeWindow); // Window Events - vscodeWindow.win.webContents.removeAllListeners('devtools-reload-page'); // remove built in listener so we can handle this on our own - vscodeWindow.win.webContents.on('devtools-reload-page', () => this.reload(vscodeWindow)); - vscodeWindow.win.webContents.on('crashed', () => this.onWindowError(vscodeWindow, WindowError.CRASHED)); - vscodeWindow.win.on('unresponsive', () => this.onWindowError(vscodeWindow, WindowError.UNRESPONSIVE)); - vscodeWindow.win.on('closed', () => this.onWindowClosed(vscodeWindow)); + codeWindow.win.webContents.removeAllListeners('devtools-reload-page'); // remove built in listener so we can handle this on our own + codeWindow.win.webContents.on('devtools-reload-page', () => this.reload(codeWindow)); + codeWindow.win.webContents.on('crashed', () => this.onWindowError(codeWindow, WindowError.CRASHED)); + codeWindow.win.on('unresponsive', () => this.onWindowError(codeWindow, WindowError.UNRESPONSIVE)); + codeWindow.win.on('closed', () => this.onWindowClosed(codeWindow)); // Lifecycle - this.lifecycleService.registerWindow(vscodeWindow); + this.lifecycleService.registerWindow(codeWindow); } // Existing window @@ -881,7 +881,7 @@ export class WindowsManager implements IWindowsMainService { // Some configuration things get inherited if the window is being reused and we are // in extension development host mode. These options are all development related. - const currentWindowConfig = vscodeWindow.config; + const currentWindowConfig = codeWindow.config; if (!configuration.extensionDevelopmentPath && currentWindowConfig && !!currentWindowConfig.extensionDevelopmentPath) { configuration.extensionDevelopmentPath = currentWindowConfig.extensionDevelopmentPath; configuration.verbose = currentWindowConfig.verbose; @@ -892,20 +892,20 @@ export class WindowsManager implements IWindowsMainService { } // Only load when the window has not vetoed this - this.lifecycleService.unload(vscodeWindow, UnloadReason.LOAD).done(veto => { + this.lifecycleService.unload(codeWindow, UnloadReason.LOAD).done(veto => { if (!veto) { // Register window for backups if (!configuration.extensionDevelopmentPath) { - this.backupService.registerWindowForBackupsSync(vscodeWindow.id, !configuration.workspacePath, emptyWorkspaceBackupFolder, configuration.workspacePath); + this.backupService.registerWindowForBackupsSync(codeWindow.id, !configuration.workspacePath, emptyWorkspaceBackupFolder, configuration.workspacePath); } // Load it - vscodeWindow.load(configuration); + codeWindow.load(configuration); } }); - return vscodeWindow; + return codeWindow; } private getNewWindowState(configuration: IWindowConfiguration): INewWindowState { @@ -1016,11 +1016,11 @@ export class WindowsManager implements IWindowsMainService { this.doPickAndOpen({ pickFolders: true, pickFiles: true, forceNewWindow }, 'openFileFolder', data); } - public openFilePicker(forceNewWindow?: boolean, path?: string, window?: VSCodeWindow, data?: ITelemetryData): void { + public openFilePicker(forceNewWindow?: boolean, path?: string, window?: CodeWindow, data?: ITelemetryData): void { this.doPickAndOpen({ pickFiles: true, forceNewWindow, path, window }, 'openFile', data); } - public openFolderPicker(forceNewWindow?: boolean, window?: VSCodeWindow, data?: ITelemetryData): void { + public openFolderPicker(forceNewWindow?: boolean, window?: CodeWindow, data?: ITelemetryData): void { this.doPickAndOpen({ pickFolders: true, forceNewWindow, window }, 'openFolder', data); } @@ -1066,7 +1066,7 @@ export class WindowsManager implements IWindowsMainService { }); } - public focusLastActive(cli: ParsedArgs, context: OpenContext): VSCodeWindow { + public focusLastActive(cli: ParsedArgs, context: OpenContext): CodeWindow { const lastActive = this.getLastActiveWindow(); if (lastActive) { lastActive.focus(); @@ -1080,11 +1080,11 @@ export class WindowsManager implements IWindowsMainService { return res && res[0]; } - public getLastActiveWindow(): VSCodeWindow { + public getLastActiveWindow(): CodeWindow { return getLastActiveWindow(WindowsManager.WINDOWS); } - public findWindow(workspacePath: string, filePath?: string, extensionDevelopmentPath?: string): VSCodeWindow { + public findWindow(workspacePath: string, filePath?: string, extensionDevelopmentPath?: string): CodeWindow { if (WindowsManager.WINDOWS.length) { // Sort the last active window to the front of the array of windows to test @@ -1151,7 +1151,7 @@ export class WindowsManager implements IWindowsMainService { }); } - public getFocusedWindow(): VSCodeWindow { + public getFocusedWindow(): CodeWindow { const win = BrowserWindow.getFocusedWindow(); if (win) { return this.getWindowById(win.id); @@ -1160,7 +1160,7 @@ export class WindowsManager implements IWindowsMainService { return null; } - public getWindowById(windowId: number): VSCodeWindow { + public getWindowById(windowId: number): CodeWindow { const res = WindowsManager.WINDOWS.filter(w => w.id === windowId); if (res && res.length === 1) { return res[0]; @@ -1169,7 +1169,7 @@ export class WindowsManager implements IWindowsMainService { return null; } - public getWindows(): VSCodeWindow[] { + public getWindows(): CodeWindow[] { return WindowsManager.WINDOWS; } @@ -1177,12 +1177,12 @@ export class WindowsManager implements IWindowsMainService { return WindowsManager.WINDOWS.length; } - private onWindowError(vscodeWindow: VSCodeWindow, error: WindowError): void { + private onWindowError(codeWindow: CodeWindow, error: WindowError): void { console.error(error === WindowError.CRASHED ? '[VS Code]: render process crashed!' : '[VS Code]: detected unresponsive'); // Unresponsive if (error === WindowError.UNRESPONSIVE) { - dialog.showMessageBox(vscodeWindow.win, { + dialog.showMessageBox(codeWindow.win, { title: product.nameLong, type: 'warning', buttons: [nls.localize('reopen', "Reopen"), nls.localize('wait', "Keep Waiting"), nls.localize('close', "Close")], @@ -1190,22 +1190,22 @@ export class WindowsManager implements IWindowsMainService { detail: nls.localize('appStalledDetail', "You can reopen or close the window or keep waiting."), noLink: true }, result => { - if (!vscodeWindow.win) { + if (!codeWindow.win) { return; // Return early if the window has been going down already } if (result === 0) { - vscodeWindow.reload(); + codeWindow.reload(); } else if (result === 2) { - this.onBeforeWindowClose(vscodeWindow); // 'close' event will not be fired on destroy(), so run it manually - vscodeWindow.win.destroy(); // make sure to destroy the window as it is unresponsive + this.onBeforeWindowClose(codeWindow); // 'close' event will not be fired on destroy(), so run it manually + codeWindow.win.destroy(); // make sure to destroy the window as it is unresponsive } }); } // Crashed else { - dialog.showMessageBox(vscodeWindow.win, { + dialog.showMessageBox(codeWindow.win, { title: product.nameLong, type: 'warning', buttons: [nls.localize('reopen', "Reopen"), nls.localize('close', "Close")], @@ -1213,21 +1213,21 @@ export class WindowsManager implements IWindowsMainService { detail: nls.localize('appCrashedDetail', "We are sorry for the inconvenience! You can reopen the window to continue where you left off."), noLink: true }, result => { - if (!vscodeWindow.win) { + if (!codeWindow.win) { return; // Return early if the window has been going down already } if (result === 0) { - vscodeWindow.reload(); + codeWindow.reload(); } else if (result === 1) { - this.onBeforeWindowClose(vscodeWindow); // 'close' event will not be fired on destroy(), so run it manually - vscodeWindow.win.destroy(); // make sure to destroy the window as it has crashed + this.onBeforeWindowClose(codeWindow); // 'close' event will not be fired on destroy(), so run it manually + codeWindow.win.destroy(); // make sure to destroy the window as it has crashed } }); } } - private onWindowClosed(win: VSCodeWindow): void { + private onWindowClosed(win: CodeWindow): void { // Tell window win.dispose(); @@ -1306,9 +1306,9 @@ export class WindowsManager implements IWindowsMainService { // If the user selected to exit from an extension development host window, do not quit, but just // close the window unless this is the last window that is opened. - const vscodeWindow = this.getFocusedWindow(); - if (vscodeWindow && vscodeWindow.isExtensionDevelopmentHost && this.getWindowCount() > 1) { - vscodeWindow.win.close(); + const codeWindow = this.getFocusedWindow(); + if (codeWindow && codeWindow.isExtensionDevelopmentHost && this.getWindowCount() > 1) { + codeWindow.win.close(); } // Otherwise: normal quit diff --git a/src/vs/code/node/windowsUtils.ts b/src/vs/code/node/windowsUtils.ts index 2f8407e0a4e..27e8ae3fd63 100644 --- a/src/vs/code/node/windowsUtils.ts +++ b/src/vs/code/node/windowsUtils.ts @@ -13,7 +13,7 @@ import { OpenContext } from "vs/platform/windows/common/windows"; import { isEqualOrParent } from 'vs/platform/files/common/files'; /** - * Exported subset of VSCodeWindow for testing. + * Exported subset of CodeWindow for testing. */ export interface ISimpleWindow { openedWorkspacePath: string; diff --git a/src/vs/platform/windows/electron-main/windowsService.ts b/src/vs/platform/windows/electron-main/windowsService.ts index 28d29556f17..492ae30fdc0 100644 --- a/src/vs/platform/windows/electron-main/windowsService.ts +++ b/src/vs/platform/windows/electron-main/windowsService.ts @@ -57,38 +57,38 @@ export class WindowsService implements IWindowsService, IDisposable { } openFolderPicker(windowId: number, forceNewWindow?: boolean, data?: ITelemetryData): TPromise { - const vscodeWindow = this.windowsMainService.getWindowById(windowId); - this.windowsMainService.openFolderPicker(forceNewWindow, vscodeWindow, data); + const codeWindow = this.windowsMainService.getWindowById(windowId); + this.windowsMainService.openFolderPicker(forceNewWindow, codeWindow, data); return TPromise.as(null); } reloadWindow(windowId: number): TPromise { - const vscodeWindow = this.windowsMainService.getWindowById(windowId); + const codeWindow = this.windowsMainService.getWindowById(windowId); - if (vscodeWindow) { - this.windowsMainService.reload(vscodeWindow); + if (codeWindow) { + this.windowsMainService.reload(codeWindow); } return TPromise.as(null); } openDevTools(windowId: number): TPromise { - const vscodeWindow = this.windowsMainService.getWindowById(windowId); + const codeWindow = this.windowsMainService.getWindowById(windowId); - if (vscodeWindow) { - vscodeWindow.win.webContents.openDevTools(); + if (codeWindow) { + codeWindow.win.webContents.openDevTools(); } return TPromise.as(null); } toggleDevTools(windowId: number): TPromise { - const vscodeWindow = this.windowsMainService.getWindowById(windowId); + const codeWindow = this.windowsMainService.getWindowById(windowId); - if (vscodeWindow) { - const contents = vscodeWindow.win.webContents; - if (vscodeWindow.hasHiddenTitleBarStyle() && !vscodeWindow.win.isFullScreen() && !contents.isDevToolsOpened()) { + if (codeWindow) { + const contents = codeWindow.win.webContents; + if (codeWindow.hasHiddenTitleBarStyle() && !codeWindow.win.isFullScreen() && !contents.isDevToolsOpened()) { contents.openDevTools({ mode: 'undocked' }); // due to https://github.com/electron/electron/issues/3647 } else { contents.toggleDevTools(); @@ -99,30 +99,30 @@ export class WindowsService implements IWindowsService, IDisposable { } closeFolder(windowId: number): TPromise { - const vscodeWindow = this.windowsMainService.getWindowById(windowId); + const codeWindow = this.windowsMainService.getWindowById(windowId); - if (vscodeWindow) { - this.windowsMainService.open({ context: OpenContext.API, cli: this.environmentService.args, forceEmpty: true, windowToUse: vscodeWindow, forceReuseWindow: true }); + if (codeWindow) { + this.windowsMainService.open({ context: OpenContext.API, cli: this.environmentService.args, forceEmpty: true, windowToUse: codeWindow, forceReuseWindow: true }); } return TPromise.as(null); } toggleFullScreen(windowId: number): TPromise { - const vscodeWindow = this.windowsMainService.getWindowById(windowId); + const codeWindow = this.windowsMainService.getWindowById(windowId); - if (vscodeWindow) { - vscodeWindow.toggleFullScreen(); + if (codeWindow) { + codeWindow.toggleFullScreen(); } return TPromise.as(null); } setRepresentedFilename(windowId: number, fileName: string): TPromise { - const vscodeWindow = this.windowsMainService.getWindowById(windowId); + const codeWindow = this.windowsMainService.getWindowById(windowId); - if (vscodeWindow) { - vscodeWindow.setRepresentedFilename(fileName); + if (codeWindow) { + codeWindow.setRepresentedFilename(fileName); } return TPromise.as(null); @@ -146,10 +146,10 @@ export class WindowsService implements IWindowsService, IDisposable { } getRecentlyOpen(windowId: number): TPromise<{ files: string[]; folders: string[]; }> { - const vscodeWindow = this.windowsMainService.getWindowById(windowId); + const codeWindow = this.windowsMainService.getWindowById(windowId); - if (vscodeWindow) { - const { files, folders } = this.windowsMainService.getRecentPathsList(vscodeWindow.config.workspacePath, vscodeWindow.config.filesToOpen); + if (codeWindow) { + const { files, folders } = this.windowsMainService.getRecentPathsList(codeWindow.config.workspacePath, codeWindow.config.filesToOpen); return TPromise.as({ files, folders }); } @@ -157,70 +157,70 @@ export class WindowsService implements IWindowsService, IDisposable { } focusWindow(windowId: number): TPromise { - const vscodeWindow = this.windowsMainService.getWindowById(windowId); + const codeWindow = this.windowsMainService.getWindowById(windowId); - if (vscodeWindow) { - vscodeWindow.win.focus(); + if (codeWindow) { + codeWindow.win.focus(); } return TPromise.as(null); } isFocused(windowId: number): TPromise { - const vscodeWindow = this.windowsMainService.getWindowById(windowId); + const codeWindow = this.windowsMainService.getWindowById(windowId); - if (vscodeWindow) { - return TPromise.as(vscodeWindow.win.isFocused()); + if (codeWindow) { + return TPromise.as(codeWindow.win.isFocused()); } return TPromise.as(null); } isMaximized(windowId: number): TPromise { - const vscodeWindow = this.windowsMainService.getWindowById(windowId); + const codeWindow = this.windowsMainService.getWindowById(windowId); - if (vscodeWindow) { - return TPromise.as(vscodeWindow.win.isMaximized()); + if (codeWindow) { + return TPromise.as(codeWindow.win.isMaximized()); } return TPromise.as(null); } maximizeWindow(windowId: number): TPromise { - const vscodeWindow = this.windowsMainService.getWindowById(windowId); + const codeWindow = this.windowsMainService.getWindowById(windowId); - if (vscodeWindow) { - vscodeWindow.win.maximize(); + if (codeWindow) { + codeWindow.win.maximize(); } return TPromise.as(null); } unmaximizeWindow(windowId: number): TPromise { - const vscodeWindow = this.windowsMainService.getWindowById(windowId); + const codeWindow = this.windowsMainService.getWindowById(windowId); - if (vscodeWindow) { - vscodeWindow.win.unmaximize(); + if (codeWindow) { + codeWindow.win.unmaximize(); } return TPromise.as(null); } onWindowTitleDoubleClick(windowId: number): TPromise { - const vscodeWindow = this.windowsMainService.getWindowById(windowId); + const codeWindow = this.windowsMainService.getWindowById(windowId); - if (vscodeWindow) { - vscodeWindow.onWindowTitleDoubleClick(); + if (codeWindow) { + codeWindow.onWindowTitleDoubleClick(); } return TPromise.as(null); } setDocumentEdited(windowId: number, flag: boolean): TPromise { - const vscodeWindow = this.windowsMainService.getWindowById(windowId); + const codeWindow = this.windowsMainService.getWindowById(windowId); - if (vscodeWindow && vscodeWindow.win.isDocumentEdited() !== flag) { - vscodeWindow.win.setDocumentEdited(flag); + if (codeWindow && codeWindow.win.isDocumentEdited() !== flag) { + codeWindow.win.setDocumentEdited(flag); } return TPromise.as(null); @@ -241,10 +241,10 @@ export class WindowsService implements IWindowsService, IDisposable { } showWindow(windowId: number): TPromise { - const vscodeWindow = this.windowsMainService.getWindowById(windowId); + const codeWindow = this.windowsMainService.getWindowById(windowId); - if (vscodeWindow) { - vscodeWindow.win.show(); + if (codeWindow) { + codeWindow.win.show(); } return TPromise.as(null); -- GitLab From c2cb4fc173c5b6a48c9c282878b2d64503002f19 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 8 Jun 2017 12:28:22 +0200 Subject: [PATCH 0642/1347] delete unused code --- src/vs/code/common/windows.ts | 37 ------------------- .../electron-browser/sharedProcessMain.ts | 24 +++++++++++- 2 files changed, 23 insertions(+), 38 deletions(-) delete mode 100644 src/vs/code/common/windows.ts diff --git a/src/vs/code/common/windows.ts b/src/vs/code/common/windows.ts deleted file mode 100644 index 9d1610531c7..00000000000 --- a/src/vs/code/common/windows.ts +++ /dev/null @@ -1,37 +0,0 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ - -import Event from 'vs/base/common/event'; -import { IDisposable, dispose } from 'vs/base/common/lifecycle'; -import { IWindowsService } from 'vs/platform/windows/common/windows'; - -export interface IWindowEventService { - _serviceBrand: any; - - onNewWindowOpen: Event; - onWindowFocus: Event; -} - -export class ActiveWindowManager implements IDisposable { - private disposables: IDisposable[] = []; - private _activeWindowId: number; - - constructor( @IWindowsService windowsService: IWindowsService) { - windowsService.onWindowOpen(this.setActiveWindow, this, this.disposables); - windowsService.onWindowFocus(this.setActiveWindow, this, this.disposables); - } - - private setActiveWindow(windowId: number) { - this._activeWindowId = windowId; - } - - public get activeClientId(): string { - return `window:${this._activeWindowId}`; - } - - public dispose() { - this.disposables = dispose(this.disposables); - } -} \ No newline at end of file diff --git a/src/vs/code/electron-browser/sharedProcessMain.ts b/src/vs/code/electron-browser/sharedProcessMain.ts index 0d2d3221490..adaeba11397 100644 --- a/src/vs/code/electron-browser/sharedProcessMain.ts +++ b/src/vs/code/electron-browser/sharedProcessMain.ts @@ -32,14 +32,36 @@ import { IChoiceService } from 'vs/platform/message/common/message'; import { ChoiceChannelClient } from 'vs/platform/message/common/messageIpc'; import { IWindowsService } from 'vs/platform/windows/common/windows'; import { WindowsChannelClient } from 'vs/platform/windows/common/windowsIpc'; -import { ActiveWindowManager } from 'vs/code/common/windows'; import { ipcRenderer } from 'electron'; +import { IDisposable, dispose } from "vs/base/common/lifecycle"; interface ISharedProcessInitData { sharedIPCHandle: string; args: ParsedArgs; } +class ActiveWindowManager implements IDisposable { + private disposables: IDisposable[] = []; + private _activeWindowId: number; + + constructor( @IWindowsService windowsService: IWindowsService) { + windowsService.onWindowOpen(this.setActiveWindow, this, this.disposables); + windowsService.onWindowFocus(this.setActiveWindow, this, this.disposables); + } + + private setActiveWindow(windowId: number) { + this._activeWindowId = windowId; + } + + public get activeClientId(): string { + return `window:${this._activeWindowId}`; + } + + public dispose() { + this.disposables = dispose(this.disposables); + } +} + const eventPrefix = 'monacoworkbench'; function main(server: Server, initData: ISharedProcessInitData): void { -- GitLab From 0526234210d285746de1a44944a8507d3266d6d1 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 8 Jun 2017 12:33:04 +0200 Subject: [PATCH 0643/1347] more renames --- src/vs/code/electron-main/app.ts | 6 +++--- src/vs/code/electron-main/main.ts | 4 ++-- src/vs/code/electron-main/menus.ts | 6 +++--- src/vs/code/electron-main/window.ts | 8 ++++---- 4 files changed, 12 insertions(+), 12 deletions(-) diff --git a/src/vs/code/electron-main/app.ts b/src/vs/code/electron-main/app.ts index bfa18af3509..6ebb6c1db95 100644 --- a/src/vs/code/electron-main/app.ts +++ b/src/vs/code/electron-main/app.ts @@ -12,7 +12,7 @@ import { IWindowsService, OpenContext } from 'vs/platform/windows/common/windows import { WindowsChannel } from 'vs/platform/windows/common/windowsIpc'; import { WindowsService } from 'vs/platform/windows/electron-main/windowsService'; import { ILifecycleService } from 'vs/platform/lifecycle/electron-main/lifecycleMain'; -import { VSCodeMenu } from 'vs/code/electron-main/menus'; +import { CodeMenu } from 'vs/code/electron-main/menus'; import { getShellEnvironment } from 'vs/code/node/shellEnv'; import { IUpdateService } from 'vs/platform/update/common/update'; import { UpdateChannel } from 'vs/platform/update/common/updateIpc'; @@ -45,7 +45,7 @@ import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { ConfigurationService } from 'vs/platform/configuration/node/configurationService'; import { TPromise } from "vs/base/common/winjs.base"; -export class VSCodeApplication { +export class CodeApplication { private toDispose: IDisposable[]; private windowsMainService: IWindowsMainService; @@ -254,7 +254,7 @@ export class VSCodeApplication { } // Install Menu - appInstantiationService.createInstance(VSCodeMenu); + appInstantiationService.createInstance(CodeMenu); // Jump List this.windowsMainService.updateWindowsJumpList(); diff --git a/src/vs/code/electron-main/main.ts b/src/vs/code/electron-main/main.ts index 4b76c411f8f..ebbaaa2ed46 100644 --- a/src/vs/code/electron-main/main.ts +++ b/src/vs/code/electron-main/main.ts @@ -32,7 +32,7 @@ import { RequestService } from 'vs/platform/request/electron-main/requestService import { IURLService } from 'vs/platform/url/common/url'; import { URLService } from 'vs/platform/url/electron-main/urlService'; import * as fs from 'original-fs'; -import { VSCodeApplication } from "vs/code/electron-main/app"; +import { CodeApplication } from "vs/code/electron-main/app"; function createServices(args: ParsedArgs): IInstantiationService { const services = new ServiceCollection(); @@ -193,7 +193,7 @@ function main() { return instantiationService.invokeFunction(a => createPaths(a.get(IEnvironmentService))) .then(() => instantiationService.invokeFunction(setupIPC)) .then(mainIpcServer => { - const app = instantiationService.createInstance(VSCodeApplication, mainIpcServer, instanceEnv); + const app = instantiationService.createInstance(CodeApplication, mainIpcServer, instanceEnv); app.startup(); }); }).done(null, err => instantiationService.invokeFunction(quit, err)); diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index 50f71919883..a7b91e3360a 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -152,7 +152,7 @@ class KeybindingsResolver { const telemetryFrom = 'menu'; -export class VSCodeMenu { +export class CodeMenu { private static MAX_MENU_RECENT_ENTRIES = 10; @@ -523,7 +523,7 @@ export class VSCodeMenu { if (folders.length > 0) { openRecentMenu.append(__separator__()); - for (let i = 0; i < VSCodeMenu.MAX_MENU_RECENT_ENTRIES && i < folders.length; i++) { + for (let i = 0; i < CodeMenu.MAX_MENU_RECENT_ENTRIES && i < folders.length; i++) { openRecentMenu.append(this.createOpenRecentMenuItem(folders[i], 'openRecentFolder')); } } @@ -532,7 +532,7 @@ export class VSCodeMenu { if (files.length > 0) { openRecentMenu.append(__separator__()); - for (let i = 0; i < VSCodeMenu.MAX_MENU_RECENT_ENTRIES && i < files.length; i++) { + for (let i = 0; i < CodeMenu.MAX_MENU_RECENT_ENTRIES && i < files.length; i++) { openRecentMenu.append(this.createOpenRecentMenuItem(files[i], 'openRecentFile')); } } diff --git a/src/vs/code/electron-main/window.ts b/src/vs/code/electron-main/window.ts index 09e16223e15..1073d3db129 100644 --- a/src/vs/code/electron-main/window.ts +++ b/src/vs/code/electron-main/window.ts @@ -57,10 +57,10 @@ export const defaultWindowState = function (mode = WindowMode.Normal): IWindowSt export interface IPath { - // the workspace spath for a VSCode instance which can be null + // the workspace spath for a Code instance which can be null workspacePath?: string; - // the file path to open within a VSCode instance + // the file path to open within a Code instance filePath?: string; // the line number in the file path to open @@ -69,7 +69,7 @@ export interface IPath { // the column number in the file path to open columnNumber?: number; - // indicator to create the file path in the VSCode instance + // indicator to create the file path in the Code instance createFilePath?: boolean; } @@ -376,7 +376,7 @@ export class CodeWindow implements ICodeWindow { this.pendingLoadConfig = null; } - // To prevent flashing, we set the window visible after the page has finished to load but before VSCode is loaded + // To prevent flashing, we set the window visible after the page has finished to load but before Code is loaded if (!this._win.isVisible()) { if (this.windowState.mode === WindowMode.Maximized) { this._win.maximize(); -- GitLab From 63cdab315235be34ba13e7eca4033f538ea63f36 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 8 Jun 2017 13:17:17 +0200 Subject: [PATCH 0644/1347] debt - extract IWindowsMainService --- src/vs/code/electron-main/app.ts | 4 +- src/vs/code/electron-main/keyboard.ts | 175 ++++++++++++++++++ src/vs/code/electron-main/launch.ts | 4 +- src/vs/code/electron-main/menus.ts | 107 +---------- src/vs/code/electron-main/window.ts | 69 +------ src/vs/code/electron-main/windows.ts | 68 +------ src/vs/code/node/keyboard.ts | 70 ------- .../lifecycle/electron-main/lifecycleMain.ts | 5 +- src/vs/platform/windows/common/windows.ts | 14 -- .../windows/electron-main/windowsService.ts | 135 +++++++++++++- 10 files changed, 324 insertions(+), 327 deletions(-) create mode 100644 src/vs/code/electron-main/keyboard.ts delete mode 100644 src/vs/code/node/keyboard.ts diff --git a/src/vs/code/electron-main/app.ts b/src/vs/code/electron-main/app.ts index 6ebb6c1db95..9cc2c217653 100644 --- a/src/vs/code/electron-main/app.ts +++ b/src/vs/code/electron-main/app.ts @@ -7,10 +7,10 @@ import { app, ipcMain as ipc, BrowserWindow } from 'electron'; import * as platform from 'vs/base/common/platform'; -import { IWindowsMainService, WindowsManager } from 'vs/code/electron-main/windows'; +import { WindowsManager } from 'vs/code/electron-main/windows'; import { IWindowsService, OpenContext } from 'vs/platform/windows/common/windows'; import { WindowsChannel } from 'vs/platform/windows/common/windowsIpc'; -import { WindowsService } from 'vs/platform/windows/electron-main/windowsService'; +import { WindowsService, IWindowsMainService } from 'vs/platform/windows/electron-main/windowsService'; import { ILifecycleService } from 'vs/platform/lifecycle/electron-main/lifecycleMain'; import { CodeMenu } from 'vs/code/electron-main/menus'; import { getShellEnvironment } from 'vs/code/node/shellEnv'; diff --git a/src/vs/code/electron-main/keyboard.ts b/src/vs/code/electron-main/keyboard.ts new file mode 100644 index 00000000000..84608f5507d --- /dev/null +++ b/src/vs/code/electron-main/keyboard.ts @@ -0,0 +1,175 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +'use strict'; + +import * as nativeKeymap from 'native-keymap'; +import { IDisposable } from 'vs/base/common/lifecycle'; +import { isMacintosh } from 'vs/base/common/platform'; +import { IStorageService } from 'vs/platform/storage/node/storage'; +import Event, { Emitter, once } from 'vs/base/common/event'; +import { ConfigWatcher } from 'vs/base/node/config'; +import { IUserFriendlyKeybinding } from 'vs/platform/keybinding/common/keybinding'; +import { IEnvironmentService } from "vs/platform/environment/common/environment"; +import { IWindowsMainService } from "vs/platform/windows/electron-main/windowsService"; +import { ipcMain as ipc } from 'electron'; + +export class KeyboardLayoutMonitor { + + public static readonly INSTANCE = new KeyboardLayoutMonitor(); + + private _emitter: Emitter; + private _registered: boolean; + private _isISOKeyboard: boolean; + + private constructor() { + this._emitter = new Emitter(); + this._registered = false; + this._isISOKeyboard = this._readIsISOKeyboard(); + } + + public onDidChangeKeyboardLayout(callback: (isISOKeyboard: boolean) => void): IDisposable { + if (!this._registered) { + this._registered = true; + + nativeKeymap.onDidChangeKeyboardLayout(() => { + this._emitter.fire(this._isISOKeyboard); + }); + + if (isMacintosh) { + // See https://github.com/Microsoft/vscode/issues/24153 + // On OSX, on ISO keyboards, Chromium swaps the scan codes + // of IntlBackslash and Backquote. + // + // The C++ methods can give the current keyboard type (ISO or not) + // only after a NSEvent was handled. + // + // We therefore poll. + setInterval(() => { + let newValue = this._readIsISOKeyboard(); + if (this._isISOKeyboard === newValue) { + // no change + return; + } + + this._isISOKeyboard = newValue; + this._emitter.fire(this._isISOKeyboard); + + }, 3000); + } + } + return this._emitter.event(callback); + } + + private _readIsISOKeyboard(): boolean { + if (isMacintosh) { + return nativeKeymap.isISOKeyboard(); + } + return false; + } + + public isISOKeyboard(): boolean { + return this._isISOKeyboard; + } +} + +export interface IKeybinding { + id: string; + label: string; + isNative: boolean; +} + +export class KeybindingsResolver { + + private static lastKnownKeybindingsMapStorageKey = 'lastKnownKeybindings'; + + private commandIds: Set; + private keybindings: { [commandId: string]: IKeybinding }; + private keybindingsWatcher: ConfigWatcher; + + private _onKeybindingsChanged = new Emitter(); + onKeybindingsChanged: Event = this._onKeybindingsChanged.event; + + constructor( + @IStorageService private storageService: IStorageService, + @IEnvironmentService environmentService: IEnvironmentService, + @IWindowsMainService private windowsService: IWindowsMainService + ) { + this.commandIds = new Set(); + this.keybindings = this.storageService.getItem<{ [id: string]: string; }>(KeybindingsResolver.lastKnownKeybindingsMapStorageKey) || Object.create(null); + this.keybindingsWatcher = new ConfigWatcher(environmentService.appKeybindingsPath, { changeBufferDelay: 100 }); + + this.registerListeners(); + } + + private registerListeners(): void { + + // Resolve keybindings when any first window is loaded + const onceOnWindowReady = once(this.windowsService.onWindowReady); + onceOnWindowReady(win => this.resolveKeybindings(win)); + + // Listen to resolved keybindings from window + ipc.on('vscode:keybindingsResolved', (event, rawKeybindings: string) => { + let keybindings: IKeybinding[] = []; + try { + keybindings = JSON.parse(rawKeybindings); + } catch (error) { + // Should not happen + } + + // Fill hash map of resolved keybindings and check for changes + let keybindingsChanged = false; + let keybindingsCount = 0; + const resolvedKeybindings: { [commandId: string]: IKeybinding } = Object.create(null); + keybindings.forEach(keybinding => { + keybindingsCount++; + + resolvedKeybindings[keybinding.id] = keybinding; + + if (!this.keybindings[keybinding.id] || keybinding.label !== this.keybindings[keybinding.id].label) { + keybindingsChanged = true; + } + }); + + // A keybinding might have been unassigned, so we have to account for that too + if (Object.keys(this.keybindings).length !== keybindingsCount) { + keybindingsChanged = true; + } + + if (keybindingsChanged) { + this.keybindings = resolvedKeybindings; + this.storageService.setItem(KeybindingsResolver.lastKnownKeybindingsMapStorageKey, this.keybindings); // keep to restore instantly after restart + + this._onKeybindingsChanged.fire(); + } + }); + + // Resolve keybindings again when keybindings.json changes + this.keybindingsWatcher.onDidUpdateConfiguration(() => this.resolveKeybindings()); + + // Resolve keybindings when window reloads because an installed extension could have an impact + this.windowsService.onWindowReload(() => this.resolveKeybindings()); + } + + private resolveKeybindings(win = this.windowsService.getLastActiveWindow()): void { + if (this.commandIds.size && win) { + const commandIds = []; + this.commandIds.forEach(id => commandIds.push(id)); + win.sendWhenReady('vscode:resolveKeybindings', JSON.stringify(commandIds)); + } + } + + public getKeybinding(commandId: string): IKeybinding { + if (!commandId) { + return void 0; + } + + if (!this.commandIds.has(commandId)) { + this.commandIds.add(commandId); + } + + return this.keybindings[commandId]; + } +} \ No newline at end of file diff --git a/src/vs/code/electron-main/launch.ts b/src/vs/code/electron-main/launch.ts index 99103a7b5b4..17c9dd01223 100644 --- a/src/vs/code/electron-main/launch.ts +++ b/src/vs/code/electron-main/launch.ts @@ -5,7 +5,6 @@ 'use strict'; -import { IWindowsMainService } from 'vs/code/electron-main/windows'; import { TPromise } from 'vs/base/common/winjs.base'; import { IChannel } from 'vs/base/parts/ipc/common/ipc'; import { ILogService } from 'vs/platform/log/common/log'; @@ -14,7 +13,8 @@ import { IProcessEnvironment } from 'vs/base/common/platform'; import { ParsedArgs } from 'vs/platform/environment/common/environment'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; import { once } from 'vs/base/common/event'; -import { ICodeWindow, OpenContext } from "vs/platform/windows/common/windows"; +import { OpenContext } from "vs/platform/windows/common/windows"; +import { IWindowsMainService, ICodeWindow } from "vs/platform/windows/electron-main/windowsService"; export const ID = 'launchService'; export const ILaunchService = createDecorator(ID); diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index a7b91e3360a..f4a6e1b79a6 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -11,26 +11,16 @@ import * as arrays from 'vs/base/common/arrays'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { ipcMain as ipc, app, shell, dialog, Menu, MenuItem, BrowserWindow } from 'electron'; import { OpenContext } from "vs/platform/windows/common/windows"; -import { IWindowsMainService } from 'vs/code/electron-main/windows'; -import { CodeWindow } from 'vs/code/electron-main/window'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { IStorageService } from 'vs/platform/storage/node/storage'; import { IFilesConfiguration, AutoSaveConfiguration } from 'vs/platform/files/common/files'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IUpdateService, State as UpdateState } from 'vs/platform/update/common/update'; import product from 'vs/platform/node/product'; import { RunOnceScheduler } from 'vs/base/common/async'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; -import Event, { Emitter, once } from 'vs/base/common/event'; -import { ConfigWatcher } from 'vs/base/node/config'; -import { IUserFriendlyKeybinding } from 'vs/platform/keybinding/common/keybinding'; import { tildify } from "vs/base/common/labels"; - -interface IKeybinding { - id: string; - label: string; - isNative: boolean; -} +import { IWindowsMainService } from "vs/platform/windows/electron-main/windowsService"; +import { KeybindingsResolver } from "vs/code/electron-main/keyboard"; interface IExtensionViewlet { id: string; @@ -57,99 +47,6 @@ interface IConfiguration extends IFilesConfiguration { }; } -class KeybindingsResolver { - - private static lastKnownKeybindingsMapStorageKey = 'lastKnownKeybindings'; - - private commandIds: Set; - private keybindings: { [commandId: string]: IKeybinding }; - private keybindingsWatcher: ConfigWatcher; - - private _onKeybindingsChanged = new Emitter(); - onKeybindingsChanged: Event = this._onKeybindingsChanged.event; - - constructor( - @IStorageService private storageService: IStorageService, - @IEnvironmentService environmentService: IEnvironmentService, - @IWindowsMainService private windowsService: IWindowsMainService - ) { - this.commandIds = new Set(); - this.keybindings = this.storageService.getItem<{ [id: string]: string; }>(KeybindingsResolver.lastKnownKeybindingsMapStorageKey) || Object.create(null); - this.keybindingsWatcher = new ConfigWatcher(environmentService.appKeybindingsPath, { changeBufferDelay: 100 }); - - this.registerListeners(); - } - - private registerListeners(): void { - - // Resolve keybindings when any first window is loaded - const onceOnWindowReady = once(this.windowsService.onWindowReady); - onceOnWindowReady(win => this.resolveKeybindings(win)); - - // Listen to resolved keybindings from window - ipc.on('vscode:keybindingsResolved', (event, rawKeybindings: string) => { - let keybindings: IKeybinding[] = []; - try { - keybindings = JSON.parse(rawKeybindings); - } catch (error) { - // Should not happen - } - - // Fill hash map of resolved keybindings and check for changes - let keybindingsChanged = false; - let keybindingsCount = 0; - const resolvedKeybindings: { [commandId: string]: IKeybinding } = Object.create(null); - keybindings.forEach(keybinding => { - keybindingsCount++; - - resolvedKeybindings[keybinding.id] = keybinding; - - if (!this.keybindings[keybinding.id] || keybinding.label !== this.keybindings[keybinding.id].label) { - keybindingsChanged = true; - } - }); - - // A keybinding might have been unassigned, so we have to account for that too - if (Object.keys(this.keybindings).length !== keybindingsCount) { - keybindingsChanged = true; - } - - if (keybindingsChanged) { - this.keybindings = resolvedKeybindings; - this.storageService.setItem(KeybindingsResolver.lastKnownKeybindingsMapStorageKey, this.keybindings); // keep to restore instantly after restart - - this._onKeybindingsChanged.fire(); - } - }); - - // Resolve keybindings again when keybindings.json changes - this.keybindingsWatcher.onDidUpdateConfiguration(() => this.resolveKeybindings()); - - // Resolve keybindings when window reloads because an installed extension could have an impact - this.windowsService.onWindowReload(() => this.resolveKeybindings()); - } - - private resolveKeybindings(win: CodeWindow = this.windowsService.getLastActiveWindow()): void { - if (this.commandIds.size && win) { - const commandIds = []; - this.commandIds.forEach(id => commandIds.push(id)); - win.sendWhenReady('vscode:resolveKeybindings', JSON.stringify(commandIds)); - } - } - - public getKeybinding(commandId: string): IKeybinding { - if (!commandId) { - return void 0; - } - - if (!this.commandIds.has(commandId)) { - this.commandIds.add(commandId); - } - - return this.keybindings[commandId]; - } -} - const telemetryFrom = 'menu'; export class CodeMenu { diff --git a/src/vs/code/electron-main/window.ts b/src/vs/code/electron-main/window.ts index 1073d3db129..dc0979736d6 100644 --- a/src/vs/code/electron-main/window.ts +++ b/src/vs/code/electron-main/window.ts @@ -19,11 +19,11 @@ import { IWorkbenchEditorConfiguration } from 'vs/workbench/common/editor'; import { parseArgs } from 'vs/platform/environment/node/argv'; import product from 'vs/platform/node/product'; import { getCommonHTTPHeaders } from 'vs/platform/environment/node/http'; -import { IWindowSettings, MenuBarVisibility, ICodeWindow, ReadyState, IWindowCloseEvent } from 'vs/platform/windows/common/windows'; +import { IWindowSettings, MenuBarVisibility, ReadyState } from 'vs/platform/windows/common/windows'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; -import { KeyboardLayoutMonitor } from 'vs/code/node/keyboard'; -import { IProcessEnvironment, isLinux, isMacintosh, isWindows } from "vs/base/common/platform"; -import CommonEvent, { Emitter } from "vs/base/common/event"; +import { KeyboardLayoutMonitor } from 'vs/code/electron-main/keyboard'; +import { isLinux, isMacintosh, isWindows } from "vs/base/common/platform"; +import { ICodeWindow, IWindowConfiguration } from "vs/platform/windows/electron-main/windowsService"; export interface IWindowState { width?: number; @@ -55,54 +55,6 @@ export const defaultWindowState = function (mode = WindowMode.Normal): IWindowSt }; }; -export interface IPath { - - // the workspace spath for a Code instance which can be null - workspacePath?: string; - - // the file path to open within a Code instance - filePath?: string; - - // the line number in the file path to open - lineNumber?: number; - - // the column number in the file path to open - columnNumber?: number; - - // indicator to create the file path in the Code instance - createFilePath?: boolean; -} - -export interface IWindowConfiguration extends ParsedArgs { - appRoot: string; - execPath: string; - - userEnv: IProcessEnvironment; - - isISOKeyboard?: boolean; - - zoomLevel?: number; - fullscreen?: boolean; - highContrast?: boolean; - baseTheme?: string; - backgroundColor?: string; - accessibilitySupport?: boolean; - - isInitialStartup?: boolean; - - perfStartTime?: number; - perfAppReady?: number; - perfWindowLoadTime?: number; - - workspacePath?: string; - - filesToOpen?: IPath[]; - filesToCreate?: IPath[]; - filesToDiff?: IPath[]; - - nodeCachedDataDir: string; -} - export class CodeWindow implements ICodeWindow { public static themeStorageKey = 'theme'; @@ -111,7 +63,6 @@ export class CodeWindow implements ICodeWindow { private static MIN_WIDTH = 200; private static MIN_HEIGHT = 120; - private _onClose: Emitter; private options: IWindowCreationOptions; private hiddenTitleBarStyle: boolean; private showTimeoutHandle: any; @@ -146,9 +97,6 @@ export class CodeWindow implements ICodeWindow { this.whenReadyCallbacks = []; this.toDispose = []; - this._onClose = new Emitter(); - this.toDispose.push(this._onClose); - // create browser window this.createBrowserWindow(config); @@ -163,10 +111,6 @@ export class CodeWindow implements ICodeWindow { this.registerListeners(); } - public get onClose(): CommonEvent { - return this._onClose.event; - } - private createBrowserWindow(config: IWindowCreationOptions): void { // Load window state @@ -360,11 +304,6 @@ export class CodeWindow implements ICodeWindow { private registerListeners(): void { - // Re-emit close event - this._win.on('close', e => { - this._onClose.fire(e); - }); - // Remember that we loaded this._win.webContents.on('did-finish-load', () => { this._readyState = ReadyState.LOADING; diff --git a/src/vs/code/electron-main/windows.ts b/src/vs/code/electron-main/windows.ts index e31775df667..58ad622a738 100644 --- a/src/vs/code/electron-main/windows.ts +++ b/src/vs/code/electron-main/windows.ts @@ -16,41 +16,27 @@ import { IBackupMainService } from 'vs/platform/backup/common/backup'; import { trim } from 'vs/base/common/strings'; import { IEnvironmentService, ParsedArgs } from 'vs/platform/environment/common/environment'; import { IStorageService } from 'vs/platform/storage/node/storage'; -import { IPath, CodeWindow, IWindowConfiguration, IWindowState as ISingleWindowState, defaultWindowState, WindowMode } from 'vs/code/electron-main/window'; +import { CodeWindow, IWindowState as ISingleWindowState, defaultWindowState, WindowMode } from 'vs/code/electron-main/window'; import { ipcMain as ipc, app, screen, BrowserWindow, dialog } from 'electron'; import { IPathWithLineAndColumn, parseLineAndColumnAware } from 'vs/code/node/paths'; import { ILifecycleService, UnloadReason } from 'vs/platform/lifecycle/electron-main/lifecycleMain'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { ILogService } from 'vs/platform/log/common/log'; import { getPathLabel } from 'vs/base/common/labels'; -import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; import { IWindowSettings, OpenContext } from 'vs/platform/windows/common/windows'; import { getLastActiveWindow, findBestWindowOrFolder } from 'vs/code/node/windowsUtils'; import CommonEvent, { Emitter } from 'vs/base/common/event'; import product from 'vs/platform/node/product'; import { ITelemetryService, ITelemetryData } from 'vs/platform/telemetry/common/telemetry'; import { isParent, isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; -import { KeyboardLayoutMonitor } from 'vs/code/node/keyboard'; +import { KeyboardLayoutMonitor } from 'vs/code/electron-main/keyboard'; +import { IPath, IWindowsMainService, IOpenConfiguration, IRecentPathsList, IWindowConfiguration } from "vs/platform/windows/electron-main/windowsService"; enum WindowError { UNRESPONSIVE, CRASHED } -export interface IOpenConfiguration { - context: OpenContext; - cli: ParsedArgs; - userEnv?: platform.IProcessEnvironment; - pathsToOpen?: string[]; - preferNewWindow?: boolean; - forceNewWindow?: boolean; - forceReuseWindow?: boolean; - forceEmpty?: boolean; - windowToUse?: CodeWindow; - diffMode?: boolean; - initialStartup?: boolean; -} - interface INewWindowState extends ISingleWindowState { hasDefaultState?: boolean; } @@ -66,11 +52,6 @@ interface IWindowsState { openedFolders: IWindowState[]; } -export interface IRecentPathsList { - folders: string[]; - files: string[]; -} - interface INativeOpenDialogOptions { pickFolders?: boolean; pickFiles?: boolean; @@ -85,45 +66,6 @@ const ReopenFoldersSetting = { NONE: 'none' }; -export const IWindowsMainService = createDecorator('windowsMainService'); - -export interface IWindowsMainService { - _serviceBrand: any; - - // events - onWindowReady: CommonEvent; - onWindowClose: CommonEvent; - onWindowReload: CommonEvent; - onPathsOpen: CommonEvent; - onRecentPathsChange: CommonEvent; - - // methods - ready(initialUserEnv: platform.IProcessEnvironment): void; - reload(win: CodeWindow, cli?: ParsedArgs): void; - open(openConfig: IOpenConfiguration): CodeWindow[]; - openExtensionDevelopmentHostWindow(openConfig: IOpenConfiguration): void; - openFileFolderPicker(forceNewWindow?: boolean, data?: ITelemetryData): void; - openFilePicker(forceNewWindow?: boolean, path?: string, window?: CodeWindow, data?: ITelemetryData): void; - openFolderPicker(forceNewWindow?: boolean, window?: CodeWindow, data?: ITelemetryData): void; - focusLastActive(cli: ParsedArgs, context: OpenContext): CodeWindow; - getLastActiveWindow(): CodeWindow; - findWindow(workspacePath: string, filePath?: string, extensionDevelopmentPath?: string): CodeWindow; - openNewWindow(context: OpenContext): void; - sendToFocused(channel: string, ...args: any[]): void; - sendToAll(channel: string, payload: any, windowIdsToIgnore?: number[]): void; - getFocusedWindow(): CodeWindow; - getWindowById(windowId: number): CodeWindow; - getWindows(): CodeWindow[]; - getWindowCount(): number; - addToRecentPathsList(paths: { path: string; isFile?: boolean; }[]): void; - getRecentPathsList(workspacePath?: string, filesToOpen?: IPath[]): IRecentPathsList; - removeFromRecentPathsList(path: string): void; - removeFromRecentPathsList(paths: string[]): void; - clearRecentPathsList(): void; - updateWindowsJumpList(): void; - quit(): void; -} - export class WindowsManager implements IWindowsMainService { _serviceBrand: any; @@ -527,7 +469,7 @@ export class WindowsManager implements IWindowsMainService { } const configuration = this.toConfiguration(openConfig, folderToOpen, filesToOpen, filesToCreate, filesToDiff); - const browserWindow = this.openInBrowserWindow(configuration, openFolderInNewWindow, openFolderInNewWindow ? void 0 : openConfig.windowToUse); + const browserWindow = this.openInBrowserWindow(configuration, openFolderInNewWindow, openFolderInNewWindow ? void 0 : openConfig.windowToUse as CodeWindow); usedWindows.push(browserWindow); // Reset these because we handled them @@ -559,7 +501,7 @@ export class WindowsManager implements IWindowsMainService { else if (emptyToOpen.length > 0) { emptyToOpen.forEach(() => { const configuration = this.toConfiguration(openConfig); - const browserWindow = this.openInBrowserWindow(configuration, openFolderInNewWindow, openFolderInNewWindow ? void 0 : openConfig.windowToUse); + const browserWindow = this.openInBrowserWindow(configuration, openFolderInNewWindow, openFolderInNewWindow ? void 0 : openConfig.windowToUse as CodeWindow); usedWindows.push(browserWindow); openFolderInNewWindow = true; // any other folders to open must open in new window then diff --git a/src/vs/code/node/keyboard.ts b/src/vs/code/node/keyboard.ts deleted file mode 100644 index 16979fc90c0..00000000000 --- a/src/vs/code/node/keyboard.ts +++ /dev/null @@ -1,70 +0,0 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ - -'use strict'; - -import * as nativeKeymap from 'native-keymap'; -import { IDisposable } from 'vs/base/common/lifecycle'; -import { isMacintosh } from 'vs/base/common/platform'; -import { Emitter } from 'vs/base/common/event'; - -export class KeyboardLayoutMonitor { - - public static readonly INSTANCE = new KeyboardLayoutMonitor(); - - private _emitter: Emitter; - private _registered: boolean; - private _isISOKeyboard: boolean; - - private constructor() { - this._emitter = new Emitter(); - this._registered = false; - this._isISOKeyboard = this._readIsISOKeyboard(); - } - - public onDidChangeKeyboardLayout(callback: (isISOKeyboard: boolean) => void): IDisposable { - if (!this._registered) { - this._registered = true; - - nativeKeymap.onDidChangeKeyboardLayout(() => { - this._emitter.fire(this._isISOKeyboard); - }); - - if (isMacintosh) { - // See https://github.com/Microsoft/vscode/issues/24153 - // On OSX, on ISO keyboards, Chromium swaps the scan codes - // of IntlBackslash and Backquote. - // - // The C++ methods can give the current keyboard type (ISO or not) - // only after a NSEvent was handled. - // - // We therefore poll. - setInterval(() => { - let newValue = this._readIsISOKeyboard(); - if (this._isISOKeyboard === newValue) { - // no change - return; - } - - this._isISOKeyboard = newValue; - this._emitter.fire(this._isISOKeyboard); - - }, 3000); - } - } - return this._emitter.event(callback); - } - - private _readIsISOKeyboard(): boolean { - if (isMacintosh) { - return nativeKeymap.isISOKeyboard(); - } - return false; - } - - public isISOKeyboard(): boolean { - return this._isISOKeyboard; - } -} diff --git a/src/vs/platform/lifecycle/electron-main/lifecycleMain.ts b/src/vs/platform/lifecycle/electron-main/lifecycleMain.ts index 2dc0242f8cf..8c65a896d3d 100644 --- a/src/vs/platform/lifecycle/electron-main/lifecycleMain.ts +++ b/src/vs/platform/lifecycle/electron-main/lifecycleMain.ts @@ -12,7 +12,8 @@ import { ILogService } from 'vs/platform/log/common/log'; import { IStorageService } from 'vs/platform/storage/node/storage'; import Event, { Emitter } from 'vs/base/common/event'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; -import { ICodeWindow, ReadyState } from "vs/platform/windows/common/windows"; +import { ReadyState } from "vs/platform/windows/common/windows"; +import { ICodeWindow } from "vs/platform/windows/electron-main/windowsService"; export const ILifecycleService = createDecorator('lifecycleService'); @@ -135,7 +136,7 @@ export class LifecycleService implements ILifecycleService { public registerWindow(codeWindow: ICodeWindow): void { // Window Before Closing: Main -> Renderer - codeWindow.onClose(e => { + codeWindow.win.on('close', e => { const windowId = codeWindow.id; this.logService.log('Lifecycle#window-before-close', windowId); diff --git a/src/vs/platform/windows/common/windows.ts b/src/vs/platform/windows/common/windows.ts index 3ca41ea3f3b..844ce3a9aa0 100644 --- a/src/vs/platform/windows/common/windows.ts +++ b/src/vs/platform/windows/common/windows.ts @@ -109,20 +109,6 @@ export interface IWindowSettings { enableMenuBarMnemonics: boolean; } -export interface IWindowCloseEvent { - preventDefault: Function; -} - -export interface ICodeWindow { - id: number; - readyState: ReadyState; - - onClose: Event; - - close(): void; - send(channel: string, ...args: any[]): void; -} - export enum ReadyState { /** diff --git a/src/vs/platform/windows/electron-main/windowsService.ts b/src/vs/platform/windows/electron-main/windowsService.ts index 492ae30fdc0..4850b5a9a22 100644 --- a/src/vs/platform/windows/electron-main/windowsService.ts +++ b/src/vs/platform/windows/electron-main/windowsService.ts @@ -9,21 +9,148 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { assign } from 'vs/base/common/objects'; import URI from 'vs/base/common/uri'; -import { IWindowsService, OpenContext } from 'vs/platform/windows/common/windows'; -import { IEnvironmentService } from 'vs/platform/environment/common/environment'; +import { IWindowsService, OpenContext, ReadyState } from 'vs/platform/windows/common/windows'; +import { IEnvironmentService, ParsedArgs } from 'vs/platform/environment/common/environment'; import { shell, crashReporter, app } from 'electron'; import Event, { chain } from 'vs/base/common/event'; import { fromEventEmitter } from 'vs/base/node/event'; import { IURLService } from 'vs/platform/url/common/url'; import { ITelemetryData } from 'vs/platform/telemetry/common/telemetry'; -import { IWindowsMainService } from 'vs/code/electron-main/windows'; import { ILifecycleService } from "vs/platform/lifecycle/electron-main/lifecycleMain"; +import { createDecorator } from "vs/platform/instantiation/common/instantiation"; +import { IProcessEnvironment } from "vs/base/common/platform"; + +export interface ICodeWindow { + id: number; + win: Electron.BrowserWindow; + config: IWindowConfiguration; + openedWorkspacePath: string; + + readyState: ReadyState; + + close(): void; + + send(channel: string, ...args: any[]): void; + sendWhenReady(channel: string, ...args: any[]): void; + + toggleFullScreen(): void; + hasHiddenTitleBarStyle(): boolean; + setRepresentedFilename(name: string): void; + getRepresentedFilename(): string; + onWindowTitleDoubleClick(): void; +} + +export interface IWindowConfiguration extends ParsedArgs { + appRoot: string; + execPath: string; + + userEnv: IProcessEnvironment; + + isISOKeyboard?: boolean; + + zoomLevel?: number; + fullscreen?: boolean; + highContrast?: boolean; + baseTheme?: string; + backgroundColor?: string; + accessibilitySupport?: boolean; + + isInitialStartup?: boolean; + + perfStartTime?: number; + perfAppReady?: number; + perfWindowLoadTime?: number; + + workspacePath?: string; + + filesToOpen?: IPath[]; + filesToCreate?: IPath[]; + filesToDiff?: IPath[]; + + nodeCachedDataDir: string; +} export interface ISharedProcess { whenReady(): TPromise; toggle(): void; } +export const IWindowsMainService = createDecorator('windowsMainService'); + +export interface IWindowsMainService { + _serviceBrand: any; + + // events + onWindowReady: Event; + onWindowClose: Event; + onWindowReload: Event; + onPathsOpen: Event; + onRecentPathsChange: Event; + + // methods + ready(initialUserEnv: IProcessEnvironment): void; + reload(win: ICodeWindow, cli?: ParsedArgs): void; + open(openConfig: IOpenConfiguration): ICodeWindow[]; + openExtensionDevelopmentHostWindow(openConfig: IOpenConfiguration): void; + openFileFolderPicker(forceNewWindow?: boolean, data?: ITelemetryData): void; + openFilePicker(forceNewWindow?: boolean, path?: string, window?: ICodeWindow, data?: ITelemetryData): void; + openFolderPicker(forceNewWindow?: boolean, window?: ICodeWindow, data?: ITelemetryData): void; + focusLastActive(cli: ParsedArgs, context: OpenContext): ICodeWindow; + getLastActiveWindow(): ICodeWindow; + findWindow(workspacePath: string, filePath?: string, extensionDevelopmentPath?: string): ICodeWindow; + openNewWindow(context: OpenContext): void; + sendToFocused(channel: string, ...args: any[]): void; + sendToAll(channel: string, payload: any, windowIdsToIgnore?: number[]): void; + getFocusedWindow(): ICodeWindow; + getWindowById(windowId: number): ICodeWindow; + getWindows(): ICodeWindow[]; + getWindowCount(): number; + addToRecentPathsList(paths: { path: string; isFile?: boolean; }[]): void; + getRecentPathsList(workspacePath?: string, filesToOpen?: IPath[]): IRecentPathsList; + removeFromRecentPathsList(path: string): void; + removeFromRecentPathsList(paths: string[]): void; + clearRecentPathsList(): void; + updateWindowsJumpList(): void; + quit(): void; +} + +export interface IPath { + + // the workspace spath for a Code instance which can be null + workspacePath?: string; + + // the file path to open within a Code instance + filePath?: string; + + // the line number in the file path to open + lineNumber?: number; + + // the column number in the file path to open + columnNumber?: number; + + // indicator to create the file path in the Code instance + createFilePath?: boolean; +} + +export interface IOpenConfiguration { + context: OpenContext; + cli: ParsedArgs; + userEnv?: IProcessEnvironment; + pathsToOpen?: string[]; + preferNewWindow?: boolean; + forceNewWindow?: boolean; + forceReuseWindow?: boolean; + forceEmpty?: boolean; + windowToUse?: ICodeWindow; + diffMode?: boolean; + initialStartup?: boolean; +} + +export interface IRecentPathsList { + folders: string[]; + files: string[]; +} + export class WindowsService implements IWindowsService, IDisposable { _serviceBrand: any; @@ -321,4 +448,4 @@ export class WindowsService implements IWindowsService, IDisposable { dispose(): void { this.disposables = dispose(this.disposables); } -} +} \ No newline at end of file -- GitLab From 0fd62676f3fd3da679b0931b78a614ca52c1135f Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Thu, 8 Jun 2017 13:19:04 +0200 Subject: [PATCH 0645/1347] Resolves #27922 --- test/smoke/src/main.js | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/test/smoke/src/main.js b/test/smoke/src/main.js index ef6d65112e9..feedaf304e1 100644 --- a/test/smoke/src/main.js +++ b/test/smoke/src/main.js @@ -32,12 +32,13 @@ program.on('--help', () => { program.parse(process.argv); if (!program.latest) { - console.error('You must specify the binary to run the smoke test against'); - process.exit(1); + fail('You must specify the binary to run the smoke test against'); } if (!binaryExists(program.latest) || (program.stable && !binaryExists(program.stable))) { - console.error('The file path to electron binary does not exist or permissions do not allow to execute it. Please check the path provided.'); - process.exit(1); + fail('The file path to electron binary does not exist or permissions do not allow to execute it. Please check the path provided.'); +} +if (parseInt(process.version.substr(1)) < 6) { + fail('Please update your Node version to greater than 6 to run the smoke test.'); } // Setting up environment variables @@ -61,6 +62,10 @@ try { throw new Error('Error caught running the smoke test: ' + e); } +function fail(errorMessage) { + console.error(errorMessage); + process.exit(1); +} function runTests() { console.log('Running tests...') -- GitLab From 61a1d9abdc364b2f46df903cb9e955ec0f0d4114 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 8 Jun 2017 14:43:57 +0200 Subject: [PATCH 0646/1347] more docs about doc change event, #28077 --- src/vs/vscode.d.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/vs/vscode.d.ts b/src/vs/vscode.d.ts index b0670a90ba7..90bc45c524b 100644 --- a/src/vs/vscode.d.ts +++ b/src/vs/vscode.d.ts @@ -4417,7 +4417,9 @@ declare module 'vscode' { export const onDidCloseTextDocument: Event; /** - * An event that is emitted when a [text document](#TextDocument) is changed. + * An event that is emitted when a [text document](#TextDocument) is changed. This usually happens + * when the [contents](#TextDocument.getText) changes but also when other things like the + * [dirty](TextDocument#isDirty)-state changes. */ export const onDidChangeTextDocument: Event; -- GitLab From 0117f311aa61d1af3018ee0749702dd5e5691738 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 8 Jun 2017 15:00:32 +0200 Subject: [PATCH 0647/1347] make Placeholder#index a number, fixes #28185 --- .../contrib/snippet/browser/snippetParser.ts | 16 ++++++++-------- .../contrib/snippet/browser/snippetSession.ts | 4 ++-- .../snippet/test/browser/snippetParser.test.ts | 8 ++++++++ .../emmet/electron-browser/editorAccessor.ts | 4 ++-- 4 files changed, 20 insertions(+), 12 deletions(-) diff --git a/src/vs/editor/contrib/snippet/browser/snippetParser.ts b/src/vs/editor/contrib/snippet/browser/snippetParser.ts index 6cb1be524c4..956fdce23c5 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetParser.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetParser.ts @@ -187,12 +187,12 @@ export class Placeholder extends Marker { } } - constructor(public index: string = '', children: Marker[]) { + constructor(public index: number, children: Marker[]) { super(); this.children = children; } get isFinalTabstop() { - return this.index === '0'; + return this.index === 0; } toString() { return Marker.toString(this.children); @@ -356,7 +356,7 @@ export class SnippetParser { // * fill in default for empty placeHolders // * compact sibling Text markers - function walk(marker: Marker[], placeholderDefaultValues: Map) { + function walk(marker: Marker[], placeholderDefaultValues: Map) { for (let i = 0; i < marker.length; i++) { const thisMarker = marker[i]; @@ -385,16 +385,16 @@ export class SnippetParser { } } - const placeholderDefaultValues = new Map(); + const placeholderDefaultValues = new Map(); walk(marker, placeholderDefaultValues); if ( - !placeholderDefaultValues.has('0') && // there is no final tabstop + !placeholderDefaultValues.has(0) && // there is no final tabstop (insertFinalTabstop && placeholderDefaultValues.size > 0 || enforceFinalTabstop) ) { // the snippet uses placeholders but has no // final tabstop defined -> insert at the end - marker.push(new Placeholder('0', [])); + marker.push(new Placeholder(0, [])); } return marker; @@ -433,7 +433,7 @@ export class SnippetParser { if (this._accept(TokenType.VariableName) || this._accept(TokenType.Int)) { // $FOO, $123 const idOrName = this._scanner.tokenText(this._prevToken); - marker.push(/^\d+$/.test(idOrName) ? new Placeholder(idOrName, []) : new Variable(idOrName, [])); + marker.push(/^\d+$/.test(idOrName) ? new Placeholder(Number(idOrName), []) : new Variable(idOrName, [])); return true; } else if (this._accept(TokenType.CurlyOpen)) { @@ -451,7 +451,7 @@ export class SnippetParser { if (this._accept(TokenType.CurlyClose)) { const idOrName = Marker.toString(name); - marker.push(/^\d+$/.test(idOrName) ? new Placeholder(idOrName, children) : new Variable(idOrName, children)); + marker.push(/^\d+$/.test(idOrName) ? new Placeholder(Number(idOrName), children) : new Variable(idOrName, children)); return true; } diff --git a/src/vs/editor/contrib/snippet/browser/snippetSession.ts b/src/vs/editor/contrib/snippet/browser/snippetSession.ts index 44cfd7cb388..5f9a49a97e6 100644 --- a/src/vs/editor/contrib/snippet/browser/snippetSession.ts +++ b/src/vs/editor/contrib/snippet/browser/snippetSession.ts @@ -173,9 +173,9 @@ export class OneSnippet { // through the placeholders in the correct order for (const nestedPlaceholder of nested._snippet.placeholders) { if (nestedPlaceholder.isFinalTabstop) { - nestedPlaceholder.index = `${placeholder.index}.${nested._snippet.placeholders.length}`; + nestedPlaceholder.index = placeholder.index + (nested._snippet.placeholders.length / 10); } else { - nestedPlaceholder.index = `${placeholder.index}.${nestedPlaceholder.index}`; + nestedPlaceholder.index = placeholder.index + (nestedPlaceholder.index / 10); } } this._snippet.replace(placeholder, nested._snippet.children); diff --git a/src/vs/editor/contrib/snippet/test/browser/snippetParser.test.ts b/src/vs/editor/contrib/snippet/test/browser/snippetParser.test.ts index 874aadd1c56..e49a98baf39 100644 --- a/src/vs/editor/contrib/snippet/test/browser/snippetParser.test.ts +++ b/src/vs/editor/contrib/snippet/test/browser/snippetParser.test.ts @@ -381,4 +381,12 @@ suite('SnippetParser', () => { assert.equal(snippet.text, 'aaabbbdddeee'); assert.equal(snippet.placeholders.length, 3); }); + + test('Snippet order for placeholders, #28185', function () { + + const _10 = new Placeholder(10, []); + const _2 = new Placeholder(2, []); + + assert.equal(Placeholder.compareByIndex(_10, _2), 1); + }); }); diff --git a/src/vs/workbench/parts/emmet/electron-browser/editorAccessor.ts b/src/vs/workbench/parts/emmet/electron-browser/editorAccessor.ts index 66d77c525f9..dcc5e5ad74d 100644 --- a/src/vs/workbench/parts/emmet/electron-browser/editorAccessor.ts +++ b/src/vs/workbench/parts/emmet/electron-browser/editorAccessor.ts @@ -120,7 +120,7 @@ export class EditorAccessor implements emmet.Editor { // find highest placeholder index walk(marker, candidate => { if (candidate instanceof Placeholder) { - let index = Number(candidate.index); + let index = candidate.index; if (index > maxIndex) { maxIndex = index; } @@ -132,7 +132,7 @@ export class EditorAccessor implements emmet.Editor { walk(marker, candidate => { if (candidate instanceof Placeholder) { if (candidate.isFinalTabstop) { - candidate.index = String(++maxIndex); + candidate.index = ++maxIndex; } } return true; -- GitLab From 4a08a066e1eda96c8cb3a4c2c2792880412c0b16 Mon Sep 17 00:00:00 2001 From: isidor Date: Thu, 8 Jun 2017 15:32:15 +0200 Subject: [PATCH 0648/1347] debug: better hc color for focused stack frame fixes #28219 --- .../parts/debug/browser/media/debug.contribution.css | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/vs/workbench/parts/debug/browser/media/debug.contribution.css b/src/vs/workbench/parts/debug/browser/media/debug.contribution.css index efafecc857d..aa82f5ccf2a 100644 --- a/src/vs/workbench/parts/debug/browser/media/debug.contribution.css +++ b/src/vs/workbench/parts/debug/browser/media/debug.contribution.css @@ -246,6 +246,10 @@ /* High Contrast Theming */ +.monaco-editor.hc-black .debug-focused-stack-frame-line { + background: rgba(206, 231, 206, 1); +} + .hc-black .monaco-workbench .monaco-tree-row:not(.selected) .expression .name { color: inherit; } -- GitLab From 97105c24652d786c4b01106472090604aa7cd639 Mon Sep 17 00:00:00 2001 From: Yu <583181285@qq.com> Date: Thu, 8 Jun 2017 21:34:04 +0800 Subject: [PATCH 0649/1347] spaces in block comment (like line comment) --- src/vs/editor/contrib/comment/common/blockCommentCommand.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vs/editor/contrib/comment/common/blockCommentCommand.ts b/src/vs/editor/contrib/comment/common/blockCommentCommand.ts index ffceef3758f..a8a8e54a1bb 100644 --- a/src/vs/editor/contrib/comment/common/blockCommentCommand.ts +++ b/src/vs/editor/contrib/comment/common/blockCommentCommand.ts @@ -97,16 +97,16 @@ export class BlockCommentCommand implements editorCommon.ICommand { if (!Range.isEmpty(r)) { // Insert block comment start - res.push(EditOperation.insert(new Position(r.startLineNumber, r.startColumn), startToken)); + res.push(EditOperation.insert(new Position(r.startLineNumber, r.startColumn), startToken + ' ')); // Insert block comment end - res.push(EditOperation.insert(new Position(r.endLineNumber, r.endColumn), endToken)); + res.push(EditOperation.insert(new Position(r.endLineNumber, r.endColumn), ' ' + endToken)); } else { // Insert both continuously res.push(EditOperation.replace(new Range( r.startLineNumber, r.startColumn, r.endLineNumber, r.endColumn - ), startToken + endToken)); + ), startToken + ' ' + endToken)); } return res; -- GitLab From a1f1d6a57994fde51dadaec66d88252d68ffac99 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 8 Jun 2017 15:38:01 +0200 Subject: [PATCH 0650/1347] main - more shuffling around --- .../electron-browser/sharedProcessMain.ts | 2 +- src/vs/code/electron-main/app.ts | 3 +- src/vs/code/electron-main/keyboard.ts | 4 +- src/vs/code/electron-main/launch.ts | 4 +- src/vs/code/electron-main/menus.ts | 6 +- src/vs/code/electron-main/sharedProcess.ts | 3 +- src/vs/code/electron-main/window.ts | 6 +- src/vs/code/electron-main/windows.ts | 4 +- src/vs/code/node/windowsUtils.ts | 2 +- src/vs/code/test/node/windowsUtils.test.ts | 2 +- .../lifecycle/electron-main/lifecycleMain.ts | 2 +- src/vs/platform/windows/common/windows.ts | 76 ++++++++-- .../platform/windows/electron-main/windows.ts | 97 ++++++++++++ .../windows/electron-main/windowsService.ts | 138 +----------------- 14 files changed, 183 insertions(+), 166 deletions(-) create mode 100644 src/vs/platform/windows/electron-main/windows.ts diff --git a/src/vs/code/electron-browser/sharedProcessMain.ts b/src/vs/code/electron-browser/sharedProcessMain.ts index adaeba11397..5388d58ef34 100644 --- a/src/vs/code/electron-browser/sharedProcessMain.ts +++ b/src/vs/code/electron-browser/sharedProcessMain.ts @@ -33,7 +33,7 @@ import { ChoiceChannelClient } from 'vs/platform/message/common/messageIpc'; import { IWindowsService } from 'vs/platform/windows/common/windows'; import { WindowsChannelClient } from 'vs/platform/windows/common/windowsIpc'; import { ipcRenderer } from 'electron'; -import { IDisposable, dispose } from "vs/base/common/lifecycle"; +import { IDisposable, dispose } from 'vs/base/common/lifecycle'; interface ISharedProcessInitData { sharedIPCHandle: string; diff --git a/src/vs/code/electron-main/app.ts b/src/vs/code/electron-main/app.ts index 9cc2c217653..ac163efc5d2 100644 --- a/src/vs/code/electron-main/app.ts +++ b/src/vs/code/electron-main/app.ts @@ -10,7 +10,7 @@ import * as platform from 'vs/base/common/platform'; import { WindowsManager } from 'vs/code/electron-main/windows'; import { IWindowsService, OpenContext } from 'vs/platform/windows/common/windows'; import { WindowsChannel } from 'vs/platform/windows/common/windowsIpc'; -import { WindowsService, IWindowsMainService } from 'vs/platform/windows/electron-main/windowsService'; +import { WindowsService } from 'vs/platform/windows/electron-main/windowsService'; import { ILifecycleService } from 'vs/platform/lifecycle/electron-main/lifecycleMain'; import { CodeMenu } from 'vs/code/electron-main/menus'; import { getShellEnvironment } from 'vs/code/node/shellEnv'; @@ -44,6 +44,7 @@ import pkg from 'vs/platform/node/package'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { ConfigurationService } from 'vs/platform/configuration/node/configurationService'; import { TPromise } from "vs/base/common/winjs.base"; +import { IWindowsMainService } from "vs/platform/windows/electron-main/windows"; export class CodeApplication { private toDispose: IDisposable[]; diff --git a/src/vs/code/electron-main/keyboard.ts b/src/vs/code/electron-main/keyboard.ts index 84608f5507d..34b6a905e9c 100644 --- a/src/vs/code/electron-main/keyboard.ts +++ b/src/vs/code/electron-main/keyboard.ts @@ -12,9 +12,9 @@ import { IStorageService } from 'vs/platform/storage/node/storage'; import Event, { Emitter, once } from 'vs/base/common/event'; import { ConfigWatcher } from 'vs/base/node/config'; import { IUserFriendlyKeybinding } from 'vs/platform/keybinding/common/keybinding'; -import { IEnvironmentService } from "vs/platform/environment/common/environment"; -import { IWindowsMainService } from "vs/platform/windows/electron-main/windowsService"; +import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { ipcMain as ipc } from 'electron'; +import { IWindowsMainService } from "vs/platform/windows/electron-main/windows"; export class KeyboardLayoutMonitor { diff --git a/src/vs/code/electron-main/launch.ts b/src/vs/code/electron-main/launch.ts index 17c9dd01223..b3ad62b18fb 100644 --- a/src/vs/code/electron-main/launch.ts +++ b/src/vs/code/electron-main/launch.ts @@ -13,8 +13,8 @@ import { IProcessEnvironment } from 'vs/base/common/platform'; import { ParsedArgs } from 'vs/platform/environment/common/environment'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; import { once } from 'vs/base/common/event'; -import { OpenContext } from "vs/platform/windows/common/windows"; -import { IWindowsMainService, ICodeWindow } from "vs/platform/windows/electron-main/windowsService"; +import { OpenContext } from 'vs/platform/windows/common/windows'; +import { IWindowsMainService, ICodeWindow } from "vs/platform/windows/electron-main/windows"; export const ID = 'launchService'; export const ILaunchService = createDecorator(ID); diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index f4a6e1b79a6..8cc54439721 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -10,7 +10,7 @@ import { isMacintosh, isLinux, isWindows, language } from 'vs/base/common/platfo import * as arrays from 'vs/base/common/arrays'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { ipcMain as ipc, app, shell, dialog, Menu, MenuItem, BrowserWindow } from 'electron'; -import { OpenContext } from "vs/platform/windows/common/windows"; +import { OpenContext } from 'vs/platform/windows/common/windows'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { IFilesConfiguration, AutoSaveConfiguration } from 'vs/platform/files/common/files'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; @@ -18,9 +18,9 @@ import { IUpdateService, State as UpdateState } from 'vs/platform/update/common/ import product from 'vs/platform/node/product'; import { RunOnceScheduler } from 'vs/base/common/async'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; -import { tildify } from "vs/base/common/labels"; -import { IWindowsMainService } from "vs/platform/windows/electron-main/windowsService"; +import { tildify } from 'vs/base/common/labels'; import { KeybindingsResolver } from "vs/code/electron-main/keyboard"; +import { IWindowsMainService } from "vs/platform/windows/electron-main/windows"; interface IExtensionViewlet { id: string; diff --git a/src/vs/code/electron-main/sharedProcess.ts b/src/vs/code/electron-main/sharedProcess.ts index 5004700f7eb..eb540858c6d 100644 --- a/src/vs/code/electron-main/sharedProcess.ts +++ b/src/vs/code/electron-main/sharedProcess.ts @@ -11,8 +11,9 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { IProcessEnvironment } from 'vs/base/common/platform'; import { BrowserWindow, ipcMain } from 'electron'; import { PromiseSource } from 'vs/base/common/async'; +import { ISharedProcess } from "vs/platform/windows/electron-main/windows"; -export class SharedProcess { +export class SharedProcess implements ISharedProcess { private spawnPromiseSource: PromiseSource; diff --git a/src/vs/code/electron-main/window.ts b/src/vs/code/electron-main/window.ts index dc0979736d6..36e059d804e 100644 --- a/src/vs/code/electron-main/window.ts +++ b/src/vs/code/electron-main/window.ts @@ -19,11 +19,11 @@ import { IWorkbenchEditorConfiguration } from 'vs/workbench/common/editor'; import { parseArgs } from 'vs/platform/environment/node/argv'; import product from 'vs/platform/node/product'; import { getCommonHTTPHeaders } from 'vs/platform/environment/node/http'; -import { IWindowSettings, MenuBarVisibility, ReadyState } from 'vs/platform/windows/common/windows'; +import { IWindowSettings, MenuBarVisibility, IWindowConfiguration, ReadyState } from 'vs/platform/windows/common/windows'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { KeyboardLayoutMonitor } from 'vs/code/electron-main/keyboard'; -import { isLinux, isMacintosh, isWindows } from "vs/base/common/platform"; -import { ICodeWindow, IWindowConfiguration } from "vs/platform/windows/electron-main/windowsService"; +import { isLinux, isMacintosh, isWindows } from 'vs/base/common/platform'; +import { ICodeWindow } from "vs/platform/windows/electron-main/windows"; export interface IWindowState { width?: number; diff --git a/src/vs/code/electron-main/windows.ts b/src/vs/code/electron-main/windows.ts index 58ad622a738..8a5535a9898 100644 --- a/src/vs/code/electron-main/windows.ts +++ b/src/vs/code/electron-main/windows.ts @@ -23,14 +23,14 @@ import { ILifecycleService, UnloadReason } from 'vs/platform/lifecycle/electron- import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { ILogService } from 'vs/platform/log/common/log'; import { getPathLabel } from 'vs/base/common/labels'; -import { IWindowSettings, OpenContext } from 'vs/platform/windows/common/windows'; +import { IWindowSettings, OpenContext, IPath, IWindowConfiguration } from 'vs/platform/windows/common/windows'; import { getLastActiveWindow, findBestWindowOrFolder } from 'vs/code/node/windowsUtils'; import CommonEvent, { Emitter } from 'vs/base/common/event'; import product from 'vs/platform/node/product'; import { ITelemetryService, ITelemetryData } from 'vs/platform/telemetry/common/telemetry'; import { isParent, isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; import { KeyboardLayoutMonitor } from 'vs/code/electron-main/keyboard'; -import { IPath, IWindowsMainService, IOpenConfiguration, IRecentPathsList, IWindowConfiguration } from "vs/platform/windows/electron-main/windowsService"; +import { IWindowsMainService, IOpenConfiguration, IRecentPathsList } from "vs/platform/windows/electron-main/windows"; enum WindowError { UNRESPONSIVE, diff --git a/src/vs/code/node/windowsUtils.ts b/src/vs/code/node/windowsUtils.ts index 27e8ae3fd63..f7a75f9a85b 100644 --- a/src/vs/code/node/windowsUtils.ts +++ b/src/vs/code/node/windowsUtils.ts @@ -9,7 +9,7 @@ import * as path from 'path'; import * as fs from 'fs'; import * as platform from 'vs/base/common/platform'; import * as paths from 'vs/base/common/paths'; -import { OpenContext } from "vs/platform/windows/common/windows"; +import { OpenContext } from 'vs/platform/windows/common/windows'; import { isEqualOrParent } from 'vs/platform/files/common/files'; /** diff --git a/src/vs/code/test/node/windowsUtils.test.ts b/src/vs/code/test/node/windowsUtils.test.ts index e8472fd9ae9..026ce3040d1 100644 --- a/src/vs/code/test/node/windowsUtils.test.ts +++ b/src/vs/code/test/node/windowsUtils.test.ts @@ -7,7 +7,7 @@ import assert = require('assert'); import path = require('path'); import { findBestWindowOrFolder, ISimpleWindow, IBestWindowOrFolderOptions } from 'vs/code/node/windowsUtils'; -import { OpenContext } from "vs/platform/windows/common/windows"; +import { OpenContext } from 'vs/platform/windows/common/windows'; const fixturesFolder = require.toUrl('./fixtures'); diff --git a/src/vs/platform/lifecycle/electron-main/lifecycleMain.ts b/src/vs/platform/lifecycle/electron-main/lifecycleMain.ts index 8c65a896d3d..d89a243598d 100644 --- a/src/vs/platform/lifecycle/electron-main/lifecycleMain.ts +++ b/src/vs/platform/lifecycle/electron-main/lifecycleMain.ts @@ -12,8 +12,8 @@ import { ILogService } from 'vs/platform/log/common/log'; import { IStorageService } from 'vs/platform/storage/node/storage'; import Event, { Emitter } from 'vs/base/common/event'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; +import { ICodeWindow } from "vs/platform/windows/electron-main/windows"; import { ReadyState } from "vs/platform/windows/common/windows"; -import { ICodeWindow } from "vs/platform/windows/electron-main/windowsService"; export const ILifecycleService = createDecorator('lifecycleService'); diff --git a/src/vs/platform/windows/common/windows.ts b/src/vs/platform/windows/common/windows.ts index 844ce3a9aa0..ac16cd0c60a 100644 --- a/src/vs/platform/windows/common/windows.ts +++ b/src/vs/platform/windows/common/windows.ts @@ -9,6 +9,8 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; import Event from 'vs/base/common/event'; import { ITelemetryData } from 'vs/platform/telemetry/common/telemetry'; +import { IProcessEnvironment } from "vs/base/common/platform"; +import { ParsedArgs } from "vs/platform/environment/common/environment"; export const IWindowsService = createDecorator('windowsService'); @@ -109,6 +111,27 @@ export interface IWindowSettings { enableMenuBarMnemonics: boolean; } +export enum OpenContext { + + // opening when running from the command line + CLI, + + // macOS only: opening from the dock (also when opening files to a running instance from desktop) + DOCK, + + // opening from the main application window + MENU, + + // opening from a file or folder dialog + DIALOG, + + // opening from the OS's UI + DESKTOP, + + // opening through the API + API +} + export enum ReadyState { /** @@ -132,23 +155,50 @@ export enum ReadyState { READY } -export enum OpenContext { +export interface IPath { - // opening when running from the command line - CLI, + // the workspace spath for a Code instance which can be null + workspacePath?: string; - // macOS only: opening from the dock (also when opening files to a running instance from desktop) - DOCK, + // the file path to open within a Code instance + filePath?: string; - // opening from the main application window - MENU, + // the line number in the file path to open + lineNumber?: number; - // opening from a file or folder dialog - DIALOG, + // the column number in the file path to open + columnNumber?: number; - // opening from the OS's UI - DESKTOP, + // indicator to create the file path in the Code instance + createFilePath?: boolean; +} - // opening through the API - API +export interface IWindowConfiguration extends ParsedArgs { + appRoot: string; + execPath: string; + + userEnv: IProcessEnvironment; + + isISOKeyboard?: boolean; + + zoomLevel?: number; + fullscreen?: boolean; + highContrast?: boolean; + baseTheme?: string; + backgroundColor?: string; + accessibilitySupport?: boolean; + + isInitialStartup?: boolean; + + perfStartTime?: number; + perfAppReady?: number; + perfWindowLoadTime?: number; + + workspacePath?: string; + + filesToOpen?: IPath[]; + filesToCreate?: IPath[]; + filesToDiff?: IPath[]; + + nodeCachedDataDir: string; } \ No newline at end of file diff --git a/src/vs/platform/windows/electron-main/windows.ts b/src/vs/platform/windows/electron-main/windows.ts new file mode 100644 index 00000000000..f093d694f0c --- /dev/null +++ b/src/vs/platform/windows/electron-main/windows.ts @@ -0,0 +1,97 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +'use strict'; + +import { TPromise } from 'vs/base/common/winjs.base'; +import { OpenContext, IWindowConfiguration, ReadyState, IPath } from 'vs/platform/windows/common/windows'; +import { ParsedArgs } from 'vs/platform/environment/common/environment'; +import Event from 'vs/base/common/event'; +import { ITelemetryData } from 'vs/platform/telemetry/common/telemetry'; +import { createDecorator } from "vs/platform/instantiation/common/instantiation"; +import { IProcessEnvironment } from "vs/base/common/platform"; + +export interface ICodeWindow { + id: number; + win: Electron.BrowserWindow; + config: IWindowConfiguration; + openedWorkspacePath: string; + + readyState: ReadyState; + + close(): void; + + send(channel: string, ...args: any[]): void; + sendWhenReady(channel: string, ...args: any[]): void; + + toggleFullScreen(): void; + hasHiddenTitleBarStyle(): boolean; + setRepresentedFilename(name: string): void; + getRepresentedFilename(): string; + onWindowTitleDoubleClick(): void; +} + +export const IWindowsMainService = createDecorator('windowsMainService'); + +export interface IWindowsMainService { + _serviceBrand: any; + + // events + onWindowReady: Event; + onWindowClose: Event; + onWindowReload: Event; + onPathsOpen: Event; + onRecentPathsChange: Event; + + // methods + ready(initialUserEnv: IProcessEnvironment): void; + reload(win: ICodeWindow, cli?: ParsedArgs): void; + open(openConfig: IOpenConfiguration): ICodeWindow[]; + openExtensionDevelopmentHostWindow(openConfig: IOpenConfiguration): void; + openFileFolderPicker(forceNewWindow?: boolean, data?: ITelemetryData): void; + openFilePicker(forceNewWindow?: boolean, path?: string, window?: ICodeWindow, data?: ITelemetryData): void; + openFolderPicker(forceNewWindow?: boolean, window?: ICodeWindow, data?: ITelemetryData): void; + focusLastActive(cli: ParsedArgs, context: OpenContext): ICodeWindow; + getLastActiveWindow(): ICodeWindow; + findWindow(workspacePath: string, filePath?: string, extensionDevelopmentPath?: string): ICodeWindow; + openNewWindow(context: OpenContext): void; + sendToFocused(channel: string, ...args: any[]): void; + sendToAll(channel: string, payload: any, windowIdsToIgnore?: number[]): void; + getFocusedWindow(): ICodeWindow; + getWindowById(windowId: number): ICodeWindow; + getWindows(): ICodeWindow[]; + getWindowCount(): number; + addToRecentPathsList(paths: { path: string; isFile?: boolean; }[]): void; + getRecentPathsList(workspacePath?: string, filesToOpen?: IPath[]): IRecentPathsList; + removeFromRecentPathsList(path: string): void; + removeFromRecentPathsList(paths: string[]): void; + clearRecentPathsList(): void; + updateWindowsJumpList(): void; + quit(): void; +} + +export interface IOpenConfiguration { + context: OpenContext; + cli: ParsedArgs; + userEnv?: IProcessEnvironment; + pathsToOpen?: string[]; + preferNewWindow?: boolean; + forceNewWindow?: boolean; + forceReuseWindow?: boolean; + forceEmpty?: boolean; + windowToUse?: ICodeWindow; + diffMode?: boolean; + initialStartup?: boolean; +} + +export interface IRecentPathsList { + folders: string[]; + files: string[]; +} + +export interface ISharedProcess { + whenReady(): TPromise; + toggle(): void; +} \ No newline at end of file diff --git a/src/vs/platform/windows/electron-main/windowsService.ts b/src/vs/platform/windows/electron-main/windowsService.ts index 4850b5a9a22..2838717da32 100644 --- a/src/vs/platform/windows/electron-main/windowsService.ts +++ b/src/vs/platform/windows/electron-main/windowsService.ts @@ -9,147 +9,15 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { assign } from 'vs/base/common/objects'; import URI from 'vs/base/common/uri'; -import { IWindowsService, OpenContext, ReadyState } from 'vs/platform/windows/common/windows'; -import { IEnvironmentService, ParsedArgs } from 'vs/platform/environment/common/environment'; +import { IWindowsService, OpenContext } from 'vs/platform/windows/common/windows'; +import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { shell, crashReporter, app } from 'electron'; import Event, { chain } from 'vs/base/common/event'; import { fromEventEmitter } from 'vs/base/node/event'; import { IURLService } from 'vs/platform/url/common/url'; import { ITelemetryData } from 'vs/platform/telemetry/common/telemetry'; import { ILifecycleService } from "vs/platform/lifecycle/electron-main/lifecycleMain"; -import { createDecorator } from "vs/platform/instantiation/common/instantiation"; -import { IProcessEnvironment } from "vs/base/common/platform"; - -export interface ICodeWindow { - id: number; - win: Electron.BrowserWindow; - config: IWindowConfiguration; - openedWorkspacePath: string; - - readyState: ReadyState; - - close(): void; - - send(channel: string, ...args: any[]): void; - sendWhenReady(channel: string, ...args: any[]): void; - - toggleFullScreen(): void; - hasHiddenTitleBarStyle(): boolean; - setRepresentedFilename(name: string): void; - getRepresentedFilename(): string; - onWindowTitleDoubleClick(): void; -} - -export interface IWindowConfiguration extends ParsedArgs { - appRoot: string; - execPath: string; - - userEnv: IProcessEnvironment; - - isISOKeyboard?: boolean; - - zoomLevel?: number; - fullscreen?: boolean; - highContrast?: boolean; - baseTheme?: string; - backgroundColor?: string; - accessibilitySupport?: boolean; - - isInitialStartup?: boolean; - - perfStartTime?: number; - perfAppReady?: number; - perfWindowLoadTime?: number; - - workspacePath?: string; - - filesToOpen?: IPath[]; - filesToCreate?: IPath[]; - filesToDiff?: IPath[]; - - nodeCachedDataDir: string; -} - -export interface ISharedProcess { - whenReady(): TPromise; - toggle(): void; -} - -export const IWindowsMainService = createDecorator('windowsMainService'); - -export interface IWindowsMainService { - _serviceBrand: any; - - // events - onWindowReady: Event; - onWindowClose: Event; - onWindowReload: Event; - onPathsOpen: Event; - onRecentPathsChange: Event; - - // methods - ready(initialUserEnv: IProcessEnvironment): void; - reload(win: ICodeWindow, cli?: ParsedArgs): void; - open(openConfig: IOpenConfiguration): ICodeWindow[]; - openExtensionDevelopmentHostWindow(openConfig: IOpenConfiguration): void; - openFileFolderPicker(forceNewWindow?: boolean, data?: ITelemetryData): void; - openFilePicker(forceNewWindow?: boolean, path?: string, window?: ICodeWindow, data?: ITelemetryData): void; - openFolderPicker(forceNewWindow?: boolean, window?: ICodeWindow, data?: ITelemetryData): void; - focusLastActive(cli: ParsedArgs, context: OpenContext): ICodeWindow; - getLastActiveWindow(): ICodeWindow; - findWindow(workspacePath: string, filePath?: string, extensionDevelopmentPath?: string): ICodeWindow; - openNewWindow(context: OpenContext): void; - sendToFocused(channel: string, ...args: any[]): void; - sendToAll(channel: string, payload: any, windowIdsToIgnore?: number[]): void; - getFocusedWindow(): ICodeWindow; - getWindowById(windowId: number): ICodeWindow; - getWindows(): ICodeWindow[]; - getWindowCount(): number; - addToRecentPathsList(paths: { path: string; isFile?: boolean; }[]): void; - getRecentPathsList(workspacePath?: string, filesToOpen?: IPath[]): IRecentPathsList; - removeFromRecentPathsList(path: string): void; - removeFromRecentPathsList(paths: string[]): void; - clearRecentPathsList(): void; - updateWindowsJumpList(): void; - quit(): void; -} - -export interface IPath { - - // the workspace spath for a Code instance which can be null - workspacePath?: string; - - // the file path to open within a Code instance - filePath?: string; - - // the line number in the file path to open - lineNumber?: number; - - // the column number in the file path to open - columnNumber?: number; - - // indicator to create the file path in the Code instance - createFilePath?: boolean; -} - -export interface IOpenConfiguration { - context: OpenContext; - cli: ParsedArgs; - userEnv?: IProcessEnvironment; - pathsToOpen?: string[]; - preferNewWindow?: boolean; - forceNewWindow?: boolean; - forceReuseWindow?: boolean; - forceEmpty?: boolean; - windowToUse?: ICodeWindow; - diffMode?: boolean; - initialStartup?: boolean; -} - -export interface IRecentPathsList { - folders: string[]; - files: string[]; -} +import { IWindowsMainService, ISharedProcess } from "vs/platform/windows/electron-main/windows"; export class WindowsService implements IWindowsService, IDisposable { -- GitLab From b483b517d270190662461cea3aa1e7f191f0f46b Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 8 Jun 2017 17:42:51 +0200 Subject: [PATCH 0651/1347] stop using legacyrenderer, also nuke (newly) unused left-right-widget, #27705 --- .../ui/leftRightWidget/leftRightWidget.css | 15 -- .../ui/leftRightWidget/leftRightWidget.ts | 38 ----- .../browser/referencesWidget.css | 14 +- .../browser/referencesWidget.ts | 155 +++++++++++------- 4 files changed, 106 insertions(+), 116 deletions(-) delete mode 100644 src/vs/base/browser/ui/leftRightWidget/leftRightWidget.css delete mode 100644 src/vs/base/browser/ui/leftRightWidget/leftRightWidget.ts diff --git a/src/vs/base/browser/ui/leftRightWidget/leftRightWidget.css b/src/vs/base/browser/ui/leftRightWidget/leftRightWidget.css deleted file mode 100644 index 346b3ec60a1..00000000000 --- a/src/vs/base/browser/ui/leftRightWidget/leftRightWidget.css +++ /dev/null @@ -1,15 +0,0 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ - -.monaco-left-right-widget > .left { - overflow: hidden; - text-overflow: ellipsis; - white-space: nowrap; - display: block; -} - -.monaco-left-right-widget > .right { - float: right; -} diff --git a/src/vs/base/browser/ui/leftRightWidget/leftRightWidget.ts b/src/vs/base/browser/ui/leftRightWidget/leftRightWidget.ts deleted file mode 100644 index 85e960a9ce3..00000000000 --- a/src/vs/base/browser/ui/leftRightWidget/leftRightWidget.ts +++ /dev/null @@ -1,38 +0,0 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ - -'use strict'; - -import 'vs/css!./leftRightWidget'; -import { Builder, $ } from 'vs/base/browser/builder'; -import { IDisposable } from 'vs/base/common/lifecycle'; - -export interface IRenderer { - (container: HTMLElement): IDisposable; -} - -export class LeftRightWidget { - - private $el: Builder; - private toDispose: IDisposable[]; - - constructor(container: Builder, renderLeftFn: IRenderer, renderRightFn: IRenderer); - constructor(container: HTMLElement, renderLeftFn: IRenderer, renderRightFn: IRenderer); - constructor(container: any, renderLeftFn: IRenderer, renderRightFn: IRenderer) { - this.$el = $('.monaco-left-right-widget').appendTo(container); - - this.toDispose = [ - renderRightFn($('.right').appendTo(this.$el).getHTMLElement()), - renderLeftFn($('span.left').appendTo(this.$el).getHTMLElement()) - ].filter(x => !!x); - } - - public dispose() { - if (this.$el) { - this.$el.destroy(); - this.$el = null; - } - } -} diff --git a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.css b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.css index 922f4807e48..5b316141553 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.css +++ b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.css @@ -37,17 +37,21 @@ } .monaco-editor .reference-zone-widget .ref-tree .reference-file { - position: relative; - line-height: 22px; + display: flex; + justify-content: space-between; + align-items: center; } .monaco-editor .reference-zone-widget .monaco-count-badge { - margin-right: 12px; + margin-right: .5em; + height: 15px; + padding: 0 .5em .5em .5em } /* High Contrast Theming */ .monaco-editor.hc-black .reference-zone-widget .ref-tree .reference-file { - line-height: 20px; font-weight: bold; -} \ No newline at end of file + display: flex; + justify-content: space-between; +} diff --git a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts index 2a5de66352a..29bc862adde 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts +++ b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts @@ -23,9 +23,8 @@ import { IMouseEvent } from 'vs/base/browser/mouseEvent'; import { GestureEvent } from 'vs/base/browser/touch'; import { CountBadge } from 'vs/base/browser/ui/countBadge/countBadge'; import { FileLabel } from 'vs/base/browser/ui/iconLabel/iconLabel'; -import { LeftRightWidget } from 'vs/base/browser/ui/leftRightWidget/leftRightWidget'; import * as tree from 'vs/base/parts/tree/browser/tree'; -import { DefaultController, LegacyRenderer } from 'vs/base/parts/tree/browser/treeDefaults'; +import { DefaultController } from 'vs/base/parts/tree/browser/treeDefaults'; import { Tree } from 'vs/base/parts/tree/browser/treeImpl'; import { IInstantiationService, optional } from 'vs/platform/instantiation/common/instantiation'; import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; @@ -45,6 +44,7 @@ import { IModelDecorationsChangedEvent } from 'vs/editor/common/model/textModelE import { IEditorOptions } from 'vs/editor/common/config/editorOptions'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; +import URI from 'vs/base/common/uri'; class DecorationsManager implements IDisposable { @@ -344,81 +344,120 @@ class Controller extends DefaultController { } } -class Renderer extends LegacyRenderer { - private _contextService: IWorkspaceContextService; - private _themeService: IThemeService; - private _environmentService: IEnvironmentService; +class FileReferencesTemplate { + + readonly file: FileLabel; + readonly badge: CountBadge; + readonly dispose: () => void; constructor( - @IWorkspaceContextService contextService: IWorkspaceContextService, + container: HTMLElement, + @IWorkspaceContextService private _contextService: IWorkspaceContextService, + @optional(IEnvironmentService) private _environmentService: IEnvironmentService, @IThemeService themeService: IThemeService, - @optional(IEnvironmentService) environmentService: IEnvironmentService ) { - super(); - - this._contextService = contextService; - this._themeService = themeService; - this._environmentService = environmentService; - } - - public getHeight(tree: tree.ITree, element: any): number { - return 22; + const parent = document.createElement('div'); + dom.addClass(parent, 'reference-file'); + container.appendChild(parent); + + this.file = new FileLabel(parent, URI.parse('no:file'), this._contextService, this._environmentService); + this.badge = new CountBadge(parent); + const styler = attachBadgeStyler(this.badge, themeService); + this.dispose = () => styler.dispose(); + } + + set(element: FileReferences) { + this.file.setFile(element.uri, this._contextService, this._environmentService); + const len = element.children.length; + this.badge.setCount(len); + if (element.failure) { + this.badge.setTitleFormat(nls.localize('referencesFailre', "Failed to resolve file.")); + } else if (len > 1) { + this.badge.setTitleFormat(nls.localize('referencesCount', "{0} references", len)); + } else { + this.badge.setTitleFormat(nls.localize('referenceCount', "{0} reference", len)); + } } +} - protected render(tree: tree.ITree, element: FileReferences | OneReference, container: HTMLElement): tree.IElementCallback { - - const toDispose: IDisposable[] = []; - dom.clearNode(container); +class OneReferenceTemplate { - if (element instanceof FileReferences) { - const fileReferencesContainer = $('.reference-file'); + readonly before: HTMLSpanElement; + readonly inside: HTMLSpanElement; + readonly after: HTMLSpanElement; - /* tslint:disable:no-unused-expression */ - new LeftRightWidget(fileReferencesContainer, (left: HTMLElement) => { - - const label = new FileLabel(left, element.uri, this._contextService, this._environmentService); - toDispose.push(label); - return null; + constructor(container: HTMLElement) { + const parent = document.createElement('div'); + this.before = document.createElement('span'); + this.inside = document.createElement('span'); + this.after = document.createElement('span'); + dom.addClass(this.inside, 'referenceMatch'); + dom.addClass(parent, 'reference'); + parent.appendChild(this.before); + parent.appendChild(this.inside); + parent.appendChild(this.after); + container.appendChild(parent); + } - }, (right: HTMLElement) => { + set(element: OneReference): void { + const { before, inside, after } = element.parent.preview.preview(element.range); + this.before.innerHTML = strings.escape(before); + this.inside.innerHTML = strings.escape(inside); + this.after.innerHTML = strings.escape(after); + } +} - const len = element.children.length; - const badge = new CountBadge(right, { count: len }); - toDispose.push(attachBadgeStyler(badge, this._themeService)); +class Renderer implements tree.IRenderer { - if (element.failure) { - badge.setTitleFormat(nls.localize('referencesFailre', "Failed to resolve file.")); - } else if (len > 1) { - badge.setTitleFormat(nls.localize('referencesCount', "{0} references", len)); - } else { - badge.setTitleFormat(nls.localize('referenceCount', "{0} reference", len)); - } + private static _ids = { + FileReferences: 'FileReferences', + OneReference: 'OneReference' + }; - return null; - }); - /* tslint:enable:no-unused-expression */ + constructor( + @IWorkspaceContextService private _contextService: IWorkspaceContextService, + @IThemeService private _themeService: IThemeService, + @optional(IEnvironmentService) private _environmentService: IEnvironmentService + ) { + // + } - fileReferencesContainer.appendTo(container); + getHeight(tree: tree.ITree, element: FileReferences | OneReference): number { + return 22; + } + getTemplateId(tree: tree.ITree, element: FileReferences | OneReference): string { + if (element instanceof FileReferences) { + return Renderer._ids.FileReferences; } else if (element instanceof OneReference) { + return Renderer._ids.OneReference; + } + throw element; + } - const preview = element.parent.preview.preview(element.range); - - if (!preview) { - return undefined; - } + renderTemplate(tree: tree.ITree, templateId: string, container: HTMLElement) { + if (templateId === Renderer._ids.FileReferences) { + return new FileReferencesTemplate(container, this._contextService, this._environmentService, this._themeService); + } else if (templateId === Renderer._ids.OneReference) { + return new OneReferenceTemplate(container); + } + throw templateId; + } - $('.reference').innerHtml( - strings.format( - '{0}{1}{2}', - strings.escape(preview.before), - strings.escape(preview.inside), - strings.escape(preview.after))).appendTo(container); + renderElement(tree: tree.ITree, element: FileReferences | OneReference, templateId: string, templateData: any): void { + if (element instanceof FileReferences) { + (templateData).set(element); + } else if (element instanceof OneReference) { + (templateData).set(element); + } else { + throw templateId; } + } - return () => { - dispose(toDispose); - }; + disposeTemplate(tree: tree.ITree, templateId: string, templateData: any): void { + if (templateData instanceof FileReferencesTemplate) { + templateData.dispose(); + } } } -- GitLab From 3f043b2da69a78cb19bed3e59823714be81afd48 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 8 Jun 2017 18:10:45 +0200 Subject: [PATCH 0652/1347] get rid of LegacyRenderer (fixes #27705) --- .../base/parts/tree/browser/treeDefaults.ts | 53 ------------------- src/vs/base/parts/tree/browser/treeImpl.ts | 2 +- 2 files changed, 1 insertion(+), 54 deletions(-) diff --git a/src/vs/base/parts/tree/browser/treeDefaults.ts b/src/vs/base/parts/tree/browser/treeDefaults.ts index 4b0949c9618..bc4ccdc1b73 100644 --- a/src/vs/base/parts/tree/browser/treeDefaults.ts +++ b/src/vs/base/parts/tree/browser/treeDefaults.ts @@ -16,59 +16,6 @@ import { IKeyboardEvent } from 'vs/base/browser/keyboardEvent'; import _ = require('vs/base/parts/tree/browser/tree'); import { KeyCode, KeyMod, Keybinding, createKeybinding, SimpleKeybinding } from 'vs/base/common/keyCodes'; -export interface ILegacyTemplateData { - root: HTMLElement; - element: any; - previousCleanupFn: _.IElementCallback; -} - -export class LegacyRenderer implements _.IRenderer { - - public getHeight(tree: _.ITree, element: any): number { - return 20; - } - - public getTemplateId(tree: _.ITree, element: any): string { - return 'legacy'; - } - - public renderTemplate(tree: _.ITree, templateId: string, container: HTMLElement): any { - return { - root: container, - element: null, - previousCleanupFn: null - }; - } - - public renderElement(tree: _.ITree, element: any, templateId: string, templateData: ILegacyTemplateData): void { - if (templateData.previousCleanupFn) { - templateData.previousCleanupFn(tree, templateData.element); - } - - while (templateData.root && templateData.root.firstChild) { - templateData.root.removeChild(templateData.root.firstChild); - } - - templateData.element = element; - templateData.previousCleanupFn = this.render(tree, element, templateData.root); - } - - public disposeTemplate(tree: _.ITree, templateId: string, templateData: any): void { - if (templateData.previousCleanupFn) { - templateData.previousCleanupFn(tree, templateData.element); - } - - templateData.root = null; - templateData.element = null; - templateData.previousCleanupFn = null; - } - - protected render(tree: _.ITree, element: any, container: HTMLElement, previousCleanupFn?: _.IElementCallback): _.IElementCallback { - container.textContent = '' + element; - return null; - } -} - export interface IKeyBindingCallback { (tree: _.ITree, event: IKeyboardEvent): void; } diff --git a/src/vs/base/parts/tree/browser/treeImpl.ts b/src/vs/base/parts/tree/browser/treeImpl.ts index ba27e688847..ea81d203047 100644 --- a/src/vs/base/parts/tree/browser/treeImpl.ts +++ b/src/vs/base/parts/tree/browser/treeImpl.ts @@ -41,7 +41,7 @@ export class TreeContext implements _.ITreeContext { } this.dataSource = configuration.dataSource; - this.renderer = configuration.renderer || new TreeDefaults.LegacyRenderer(); + this.renderer = configuration.renderer; this.controller = configuration.controller || new TreeDefaults.DefaultController({ clickBehavior: TreeDefaults.ClickBehavior.ON_MOUSE_UP, keyboardSupport: typeof options.keyboardSupport !== 'boolean' || options.keyboardSupport }); this.dnd = configuration.dnd || new TreeDefaults.DefaultDragAndDrop(); this.filter = configuration.filter || new TreeDefaults.DefaultFilter(); -- GitLab From 278866dca573996b3d4f4988f276885980cce332 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Thu, 8 Jun 2017 10:41:01 -0700 Subject: [PATCH 0653/1347] Configure plugin for labelling issues for new releases --- .github/new_release.yml | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 .github/new_release.yml diff --git a/.github/new_release.yml b/.github/new_release.yml new file mode 100644 index 00000000000..ae864327333 --- /dev/null +++ b/.github/new_release.yml @@ -0,0 +1,5 @@ +{ + newReleaseLabel: 'new release', + newReleases: ['1.13'], + perform: true +} \ No newline at end of file -- GitLab From 0fe479a0f833e5fa272f14bf7dbfcd03f97e9cbc Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Fri, 9 Jun 2017 12:10:44 -0700 Subject: [PATCH 0654/1347] Fix cmd+a keybinding on mac --- .../parts/terminal/electron-browser/terminal.contribution.ts | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts index 09af3cb19c6..84dc99b9212 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts @@ -210,9 +210,7 @@ let actionRegistry = Registry.as(ActionExtensions.Work actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(KillTerminalAction, KillTerminalAction.ID, KillTerminalAction.LABEL), 'Terminal: Kill the Active Terminal Instance', category); actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(CopyTerminalSelectionAction, CopyTerminalSelectionAction.ID, CopyTerminalSelectionAction.LABEL, { primary: KeyMod.CtrlCmd | KeyCode.KEY_C, - linux: { primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_C }, - // Don't apply to Mac since cmd+c works - mac: { primary: null } + linux: { primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_C } }, ContextKeyExpr.and(KEYBINDING_CONTEXT_TERMINAL_TEXT_SELECTED, KEYBINDING_CONTEXT_TERMINAL_FOCUS)), 'Terminal: Copy Selection', category); actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(CreateNewTerminalAction, CreateNewTerminalAction.ID, CreateNewTerminalAction.LABEL, { primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.US_BACKTICK, -- GitLab From a32c0803778cc346e9424567d38a3bd75ee10315 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Fri, 9 Jun 2017 12:34:57 -0700 Subject: [PATCH 0655/1347] Uplevel xterm.js Brings in fix for link duplication --- npm-shrinkwrap.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/npm-shrinkwrap.json b/npm-shrinkwrap.json index 91bff39ee52..58d2fcc6cde 100644 --- a/npm-shrinkwrap.json +++ b/npm-shrinkwrap.json @@ -442,7 +442,7 @@ "xterm": { "version": "2.7.0", "from": "Tyriar/xterm.js#vscode-release/1.14-beta", - "resolved": "git+https://github.com/Tyriar/xterm.js.git#2c61d9c26c0265b8a4ce1542d25dd1258c3e4f5b" + "resolved": "git+https://github.com/Tyriar/xterm.js.git#e6130919622e238221ee9c8806cca8f084cfec2c" }, "yauzl": { "version": "2.3.1", -- GitLab From 979923ad4dc72f99fbef07113b5fab7b34801903 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Thu, 8 Jun 2017 14:02:56 -0700 Subject: [PATCH 0656/1347] Remove terminal selection colors --- .../parts/terminal/electron-browser/terminalPanel.ts | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts index 51ddb07c92b..7b7869bbe2e 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts @@ -243,13 +243,8 @@ export class TerminalPanel extends Panel { ansiColorIdentifiers.forEach((colorId: ColorIdentifier, index: number) => { if (colorId) { // should not happen, all indices should have a color defined. let color = theme.getColor(colorId); - let rgba = color.transparent(0.996); css += `.monaco-workbench .panel.integrated-terminal .xterm .xterm-color-${index} { color: ${color}; }` + - `.monaco-workbench .panel.integrated-terminal .xterm .xterm-color-${index}::selection,` + - `.monaco-workbench .panel.integrated-terminal .xterm .xterm-color-${index} *::selection { background-color: ${rgba}; }` + - `.monaco-workbench .panel.integrated-terminal .xterm .xterm-bg-color-${index} { background-color: ${color}; }` + - `.monaco-workbench .panel.integrated-terminal .xterm .xterm-bg-color-${index}::selection,` + - `.monaco-workbench .panel.integrated-terminal .xterm .xterm-bg-color-${index} *::selection { color: ${color}; }`; + `.monaco-workbench .panel.integrated-terminal .xterm .xterm-bg-color-${index} { background-color: ${color}; }`; } }); const bgColor = theme.getColor(TERMINAL_BACKGROUND_COLOR); -- GitLab From 4541e70733f110ada8d0b4266bc922565d74950a Mon Sep 17 00:00:00 2001 From: Andre Weinand Date: Thu, 8 Jun 2017 23:57:23 +0200 Subject: [PATCH 0657/1347] node-debug@1.14.1 --- build/gulpfile.vscode.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index 2aa62f99f33..aac30d1a5dc 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -42,7 +42,7 @@ const nodeModules = ['electron', 'original-fs'] // Build const builtInExtensions = [ - { name: 'ms-vscode.node-debug', version: '1.14.0' }, + { name: 'ms-vscode.node-debug', version: '1.14.1' }, { name: 'ms-vscode.node-debug2', version: '1.13.3' } ]; -- GitLab From 2a580b4d6844dcd7a9ed12fa9c08d4e413e0ad9b Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Fri, 9 Jun 2017 08:10:09 +0200 Subject: [PATCH 0658/1347] main - extract service for handling recent paths and jumplist --- src/vs/code/electron-main/app.ts | 8 +- src/vs/code/electron-main/main.ts | 6 +- src/vs/code/electron-main/menus.ts | 10 +- src/vs/code/electron-main/windows.ts | 176 +------------- .../electron-main/historyMainService.ts | 220 ++++++++++++++++++ src/vs/platform/log/common/log.ts | 2 +- .../platform/windows/electron-main/windows.ts | 12 - .../windows/electron-main/windowsService.ts | 12 +- 8 files changed, 249 insertions(+), 197 deletions(-) create mode 100644 src/vs/platform/history/electron-main/historyMainService.ts diff --git a/src/vs/code/electron-main/app.ts b/src/vs/code/electron-main/app.ts index ac163efc5d2..53f7e77bd38 100644 --- a/src/vs/code/electron-main/app.ts +++ b/src/vs/code/electron-main/app.ts @@ -45,6 +45,7 @@ import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { ConfigurationService } from 'vs/platform/configuration/node/configurationService'; import { TPromise } from "vs/base/common/winjs.base"; import { IWindowsMainService } from "vs/platform/windows/electron-main/windows"; +import { IHistoryMainService } from "vs/platform/history/electron-main/historyMainService"; export class CodeApplication { private toDispose: IDisposable[]; @@ -63,7 +64,8 @@ export class CodeApplication { @IEnvironmentService private environmentService: IEnvironmentService, @ILifecycleService private lifecycleService: ILifecycleService, @IConfigurationService private configurationService: ConfigurationService, - @IStorageService private storageService: IStorageService + @IStorageService private storageService: IStorageService, + @IHistoryMainService private historyService: IHistoryMainService ) { this.toDispose = [mainIpcServer, configurationService]; @@ -258,8 +260,8 @@ export class CodeApplication { appInstantiationService.createInstance(CodeMenu); // Jump List - this.windowsMainService.updateWindowsJumpList(); - this.windowsMainService.onRecentPathsChange(() => this.windowsMainService.updateWindowsJumpList()); + this.historyService.updateWindowsJumpList(); + this.historyService.onRecentPathsChange(() => this.historyService.updateWindowsJumpList()); // Start shared process here this.sharedProcess.spawn(); diff --git a/src/vs/code/electron-main/main.ts b/src/vs/code/electron-main/main.ts index ebbaaa2ed46..95b5fbed51b 100644 --- a/src/vs/code/electron-main/main.ts +++ b/src/vs/code/electron-main/main.ts @@ -19,7 +19,7 @@ import { ServicesAccessor, IInstantiationService } from 'vs/platform/instantiati import { InstantiationService } from 'vs/platform/instantiation/common/instantiationService'; import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; import { SyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; -import { ILogService, MainLogService } from 'vs/platform/log/common/log'; +import { ILogService, LogMainService } from 'vs/platform/log/common/log'; import { IStorageService, StorageService } from 'vs/platform/storage/node/storage'; import { IBackupMainService } from 'vs/platform/backup/common/backup'; import { BackupMainService } from 'vs/platform/backup/electron-main/backupMainService'; @@ -33,12 +33,14 @@ import { IURLService } from 'vs/platform/url/common/url'; import { URLService } from 'vs/platform/url/electron-main/urlService'; import * as fs from 'original-fs'; import { CodeApplication } from "vs/code/electron-main/app"; +import { HistoryMainService, IHistoryMainService } from "vs/platform/history/electron-main/historyMainService"; function createServices(args: ParsedArgs): IInstantiationService { const services = new ServiceCollection(); services.set(IEnvironmentService, new SyncDescriptor(EnvironmentService, args, process.execPath)); - services.set(ILogService, new SyncDescriptor(MainLogService)); + services.set(ILogService, new SyncDescriptor(LogMainService)); + services.set(IHistoryMainService, new SyncDescriptor(HistoryMainService)); services.set(ILifecycleService, new SyncDescriptor(LifecycleService)); services.set(IStorageService, new SyncDescriptor(StorageService)); services.set(IConfigurationService, new SyncDescriptor(ConfigurationService)); diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index 8cc54439721..db805f0637c 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -21,6 +21,7 @@ import { IInstantiationService } from 'vs/platform/instantiation/common/instanti import { tildify } from 'vs/base/common/labels'; import { KeybindingsResolver } from "vs/code/electron-main/keyboard"; import { IWindowsMainService } from "vs/platform/windows/electron-main/windows"; +import { IHistoryMainService } from "vs/platform/history/electron-main/historyMainService"; interface IExtensionViewlet { id: string; @@ -75,7 +76,8 @@ export class CodeMenu { @IConfigurationService private configurationService: IConfigurationService, @IWindowsMainService private windowsService: IWindowsMainService, @IEnvironmentService private environmentService: IEnvironmentService, - @ITelemetryService private telemetryService: ITelemetryService + @ITelemetryService private telemetryService: ITelemetryService, + @IHistoryMainService private historyService: IHistoryMainService ) { this.extensionViewlets = []; @@ -98,7 +100,7 @@ export class CodeMenu { // Listen to some events from window service this.windowsService.onPathsOpen(paths => this.updateMenu()); - this.windowsService.onRecentPathsChange(paths => this.updateMenu()); + this.historyService.onRecentPathsChange(paths => this.updateMenu()); this.windowsService.onWindowClose(_ => this.onClose(this.windowsService.getWindowCount())); // Listen to extension viewlets @@ -414,7 +416,7 @@ export class CodeMenu { private setOpenRecentMenu(openRecentMenu: Electron.Menu): void { openRecentMenu.append(this.createMenuItem(nls.localize({ key: 'miReopenClosedEditor', comment: ['&& denotes a mnemonic'] }, "&&Reopen Closed Editor"), 'workbench.action.reopenClosedEditor')); - const { folders, files } = this.windowsService.getRecentPathsList(); + const { folders, files } = this.historyService.getRecentPathsList(); // Folders if (folders.length > 0) { @@ -448,7 +450,7 @@ export class CodeMenu { const openInNewWindow = this.isOptionClick(event); const success = !!this.windowsService.open({ context: OpenContext.MENU, cli: this.environmentService.args, pathsToOpen: [path], forceNewWindow: openInNewWindow }); if (!success) { - this.windowsService.removeFromRecentPathsList(path); + this.historyService.removeFromRecentPathsList(path); } } }, false)); diff --git a/src/vs/code/electron-main/windows.ts b/src/vs/code/electron-main/windows.ts index 8a5535a9898..7e19e0fe300 100644 --- a/src/vs/code/electron-main/windows.ts +++ b/src/vs/code/electron-main/windows.ts @@ -13,7 +13,6 @@ import * as types from 'vs/base/common/types'; import * as arrays from 'vs/base/common/arrays'; import { assign, mixin } from 'vs/base/common/objects'; import { IBackupMainService } from 'vs/platform/backup/common/backup'; -import { trim } from 'vs/base/common/strings'; import { IEnvironmentService, ParsedArgs } from 'vs/platform/environment/common/environment'; import { IStorageService } from 'vs/platform/storage/node/storage'; import { CodeWindow, IWindowState as ISingleWindowState, defaultWindowState, WindowMode } from 'vs/code/electron-main/window'; @@ -22,7 +21,6 @@ import { IPathWithLineAndColumn, parseLineAndColumnAware } from 'vs/code/node/pa import { ILifecycleService, UnloadReason } from 'vs/platform/lifecycle/electron-main/lifecycleMain'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { ILogService } from 'vs/platform/log/common/log'; -import { getPathLabel } from 'vs/base/common/labels'; import { IWindowSettings, OpenContext, IPath, IWindowConfiguration } from 'vs/platform/windows/common/windows'; import { getLastActiveWindow, findBestWindowOrFolder } from 'vs/code/node/windowsUtils'; import CommonEvent, { Emitter } from 'vs/base/common/event'; @@ -30,7 +28,8 @@ import product from 'vs/platform/node/product'; import { ITelemetryService, ITelemetryData } from 'vs/platform/telemetry/common/telemetry'; import { isParent, isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; import { KeyboardLayoutMonitor } from 'vs/code/electron-main/keyboard'; -import { IWindowsMainService, IOpenConfiguration, IRecentPathsList } from "vs/platform/windows/electron-main/windows"; +import { IWindowsMainService, IOpenConfiguration } from "vs/platform/windows/electron-main/windows"; +import { IHistoryMainService } from "vs/platform/history/electron-main/historyMainService"; enum WindowError { UNRESPONSIVE, @@ -70,9 +69,6 @@ export class WindowsManager implements IWindowsMainService { _serviceBrand: any; - private static MAX_TOTAL_RECENT_ENTRIES = 100; - - private static recentPathsListStorageKey = 'openedPathsList'; private static workingDirPickerStorageKey = 'pickerWorkingDir'; private static windowsStateStorageKey = 'windowsState'; @@ -83,9 +79,6 @@ export class WindowsManager implements IWindowsMainService { private windowsState: IWindowsState; private lastClosedWindowState: IWindowState; - private _onRecentPathsChange = new Emitter(); - onRecentPathsChange: CommonEvent = this._onRecentPathsChange.event; - private _onWindowReady = new Emitter(); onWindowReady: CommonEvent = this._onWindowReady.event; @@ -105,7 +98,8 @@ export class WindowsManager implements IWindowsMainService { @ILifecycleService private lifecycleService: ILifecycleService, @IBackupMainService private backupService: IBackupMainService, @ITelemetryService private telemetryService: ITelemetryService, - @IConfigurationService private configurationService: IConfigurationService + @IConfigurationService private configurationService: IConfigurationService, + @IHistoryMainService private historyService: IHistoryMainService ) { } public ready(initialUserEnv: platform.IProcessEnvironment): void { @@ -521,7 +515,7 @@ export class WindowsManager implements IWindowsMainService { }); if (recentPaths.length) { - this.addToRecentPathsList(recentPaths); + this.historyService.addToRecentPathsList(recentPaths); } } @@ -531,103 +525,7 @@ export class WindowsManager implements IWindowsMainService { return arrays.distinct(usedWindows); } - public addToRecentPathsList(paths: { path: string; isFile?: boolean; }[]): void { - if (!paths || !paths.length) { - return; - } - - const mru = this.getRecentPathsList(); - paths.forEach(p => { - const { path, isFile } = p; - - if (isFile) { - mru.files.unshift(path); - mru.files = arrays.distinct(mru.files, (f) => platform.isLinux ? f : f.toLowerCase()); - } else { - mru.folders.unshift(path); - mru.folders = arrays.distinct(mru.folders, (f) => platform.isLinux ? f : f.toLowerCase()); - } - - // Make sure its bounded - mru.folders = mru.folders.slice(0, WindowsManager.MAX_TOTAL_RECENT_ENTRIES); - mru.files = mru.files.slice(0, WindowsManager.MAX_TOTAL_RECENT_ENTRIES); - }); - - this.storageService.setItem(WindowsManager.recentPathsListStorageKey, mru); - this._onRecentPathsChange.fire(); - } - - public removeFromRecentPathsList(path: string): void; - public removeFromRecentPathsList(paths: string[]): void; - public removeFromRecentPathsList(arg1: any): void { - let paths: string[]; - if (Array.isArray(arg1)) { - paths = arg1; - } else { - paths = [arg1]; - } - - const mru = this.getRecentPathsList(); - let update = false; - - paths.forEach(path => { - let index = mru.files.indexOf(path); - if (index >= 0) { - mru.files.splice(index, 1); - update = true; - } - - index = mru.folders.indexOf(path); - if (index >= 0) { - mru.folders.splice(index, 1); - update = true; - } - }); - - if (update) { - this.storageService.setItem(WindowsManager.recentPathsListStorageKey, mru); - this._onRecentPathsChange.fire(); - } - } - - public clearRecentPathsList(): void { - this.storageService.setItem(WindowsManager.recentPathsListStorageKey, { folders: [], files: [] }); - app.clearRecentDocuments(); - - // Event - this._onRecentPathsChange.fire(); - } - public getRecentPathsList(workspacePath?: string, filesToOpen?: IPath[]): IRecentPathsList { - let files: string[]; - let folders: string[]; - - // Get from storage - const storedRecents = this.storageService.getItem(WindowsManager.recentPathsListStorageKey); - if (storedRecents) { - files = storedRecents.files || []; - folders = storedRecents.folders || []; - } else { - files = []; - folders = []; - } - - // Add currently files to open to the beginning if any - if (filesToOpen) { - files.unshift(...filesToOpen.map(f => f.filePath)); - } - - // Add current workspace path to beginning if set - if (workspacePath) { - folders.unshift(workspacePath); - } - - // Clear those dupes - files = arrays.distinct(files); - folders = arrays.distinct(folders); - - return { files, folders }; - } private getWindowUserEnv(openConfig: IOpenConfiguration): platform.IProcessEnvironment { return assign({}, this.initialUserEnv, openConfig.userEnv || {}); @@ -705,7 +603,7 @@ export class WindowsManager implements IWindowsMainService { { workspacePath: candidate }; } } catch (error) { - this.removeFromRecentPathsList(candidate); // since file does not seem to exist anymore, remove from recent + this.historyService.removeFromRecentPathsList(candidate); // since file does not seem to exist anymore, remove from recent if (ignoreFileNotFound) { return { filePath: candidate, createFilePath: true }; // assume this is a file that does not yet exist @@ -1182,68 +1080,6 @@ export class WindowsManager implements IWindowsMainService { this._onWindowClose.fire(win.id); } - public updateWindowsJumpList(): void { - if (!platform.isWindows) { - return; // only on windows - } - - const jumpList: Electron.JumpListCategory[] = []; - - // Tasks - jumpList.push({ - type: 'tasks', - items: [ - { - type: 'task', - title: nls.localize('newWindow', "New Window"), - description: nls.localize('newWindowDesc', "Opens a new window"), - program: process.execPath, - args: '-n', // force new window - iconPath: process.execPath, - iconIndex: 0 - } - ] - }); - - // Recent Folders - if (this.getRecentPathsList().folders.length > 0) { - - // The user might have meanwhile removed items from the jump list and we have to respect that - // so we need to update our list of recent paths with the choice of the user to not add them again - // Also: Windows will not show our custom category at all if there is any entry which was removed - // by the user! See https://github.com/Microsoft/vscode/issues/15052 - this.removeFromRecentPathsList(app.getJumpListSettings().removedItems.map(r => trim(r.args, '"'))); - - // Add entries - jumpList.push({ - type: 'custom', - name: nls.localize('recentFolders', "Recent Folders"), - items: this.getRecentPathsList().folders.slice(0, 7 /* limit number of entries here */).map(folder => { - return { - type: 'task', - title: path.basename(folder) || folder, // use the base name to show shorter entries in the list - description: nls.localize('folderDesc', "{0} {1}", path.basename(folder), getPathLabel(path.dirname(folder))), - program: process.execPath, - args: `"${folder}"`, // open folder (use quotes to support paths with whitespaces) - iconPath: 'explorer.exe', // simulate folder icon - iconIndex: 0 - }; - }).filter(i => !!i) - }); - } - - // Recent - jumpList.push({ - type: 'recent' // this enables to show files in the "recent" category - }); - - try { - app.setJumpList(jumpList); - } catch (error) { - this.logService.log('#setJumpList', error); // since setJumpList is relatively new API, make sure to guard for errors - } - } - public quit(): void { // If the user selected to exit from an extension development host window, do not quit, but just diff --git a/src/vs/platform/history/electron-main/historyMainService.ts b/src/vs/platform/history/electron-main/historyMainService.ts new file mode 100644 index 00000000000..31ce2c45c79 --- /dev/null +++ b/src/vs/platform/history/electron-main/historyMainService.ts @@ -0,0 +1,220 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +'use strict'; + +import * as path from 'path'; +import * as platform from 'vs/base/common/platform'; +import * as nls from 'vs/nls'; +import * as arrays from 'vs/base/common/arrays'; +import { trim } from 'vs/base/common/strings'; +import { IStorageService } from 'vs/platform/storage/node/storage'; +import { app } from 'electron'; +import { ILogService } from 'vs/platform/log/common/log'; +import { getPathLabel } from 'vs/base/common/labels'; +import { IPath } from 'vs/platform/windows/common/windows'; +import CommonEvent, { Emitter } from 'vs/base/common/event'; +import { createDecorator } from "vs/platform/instantiation/common/instantiation"; + +export const IHistoryMainService = createDecorator('historyMainService'); + +export interface IRecentPathsList { + folders: string[]; + files: string[]; +} + +export interface IHistoryMainService { + _serviceBrand: any; + + // events + onRecentPathsChange: CommonEvent; + + // methods + + addToRecentPathsList(paths: { path: string; isFile?: boolean; }[]): void; + getRecentPathsList(workspacePath?: string, filesToOpen?: IPath[]): IRecentPathsList; + removeFromRecentPathsList(path: string): void; + removeFromRecentPathsList(paths: string[]): void; + clearRecentPathsList(): void; + updateWindowsJumpList(): void; +} + +export class HistoryMainService implements IHistoryMainService { + + private static MAX_TOTAL_RECENT_ENTRIES = 100; + + private static recentPathsListStorageKey = 'openedPathsList'; + + _serviceBrand: any; + + private _onRecentPathsChange = new Emitter(); + onRecentPathsChange: CommonEvent = this._onRecentPathsChange.event; + + constructor( + @IStorageService private storageService: IStorageService, + @ILogService private logService: ILogService + ) { + } + + public addToRecentPathsList(paths: { path: string; isFile?: boolean; }[]): void { + if (!paths || !paths.length) { + return; + } + + const mru = this.getRecentPathsList(); + paths.forEach(p => { + const { path, isFile } = p; + + if (isFile) { + mru.files.unshift(path); + mru.files = arrays.distinct(mru.files, (f) => platform.isLinux ? f : f.toLowerCase()); + } else { + mru.folders.unshift(path); + mru.folders = arrays.distinct(mru.folders, (f) => platform.isLinux ? f : f.toLowerCase()); + } + + // Make sure its bounded + mru.folders = mru.folders.slice(0, HistoryMainService.MAX_TOTAL_RECENT_ENTRIES); + mru.files = mru.files.slice(0, HistoryMainService.MAX_TOTAL_RECENT_ENTRIES); + }); + + this.storageService.setItem(HistoryMainService.recentPathsListStorageKey, mru); + this._onRecentPathsChange.fire(); + } + + public removeFromRecentPathsList(path: string): void; + public removeFromRecentPathsList(paths: string[]): void; + public removeFromRecentPathsList(arg1: any): void { + let paths: string[]; + if (Array.isArray(arg1)) { + paths = arg1; + } else { + paths = [arg1]; + } + + const mru = this.getRecentPathsList(); + let update = false; + + paths.forEach(path => { + let index = mru.files.indexOf(path); + if (index >= 0) { + mru.files.splice(index, 1); + update = true; + } + + index = mru.folders.indexOf(path); + if (index >= 0) { + mru.folders.splice(index, 1); + update = true; + } + }); + + if (update) { + this.storageService.setItem(HistoryMainService.recentPathsListStorageKey, mru); + this._onRecentPathsChange.fire(); + } + } + + public clearRecentPathsList(): void { + this.storageService.setItem(HistoryMainService.recentPathsListStorageKey, { folders: [], files: [] }); + app.clearRecentDocuments(); + + // Event + this._onRecentPathsChange.fire(); + } + + public getRecentPathsList(workspacePath?: string, filesToOpen?: IPath[]): IRecentPathsList { + let files: string[]; + let folders: string[]; + + // Get from storage + const storedRecents = this.storageService.getItem(HistoryMainService.recentPathsListStorageKey); + if (storedRecents) { + files = storedRecents.files || []; + folders = storedRecents.folders || []; + } else { + files = []; + folders = []; + } + + // Add currently files to open to the beginning if any + if (filesToOpen) { + files.unshift(...filesToOpen.map(f => f.filePath)); + } + + // Add current workspace path to beginning if set + if (workspacePath) { + folders.unshift(workspacePath); + } + + // Clear those dupes + files = arrays.distinct(files); + folders = arrays.distinct(folders); + + return { files, folders }; + } + + public updateWindowsJumpList(): void { + if (!platform.isWindows) { + return; // only on windows + } + + const jumpList: Electron.JumpListCategory[] = []; + + // Tasks + jumpList.push({ + type: 'tasks', + items: [ + { + type: 'task', + title: nls.localize('newWindow', "New Window"), + description: nls.localize('newWindowDesc', "Opens a new window"), + program: process.execPath, + args: '-n', // force new window + iconPath: process.execPath, + iconIndex: 0 + } + ] + }); + + // Recent Folders + if (this.getRecentPathsList().folders.length > 0) { + + // The user might have meanwhile removed items from the jump list and we have to respect that + // so we need to update our list of recent paths with the choice of the user to not add them again + // Also: Windows will not show our custom category at all if there is any entry which was removed + // by the user! See https://github.com/Microsoft/vscode/issues/15052 + this.removeFromRecentPathsList(app.getJumpListSettings().removedItems.map(r => trim(r.args, '"'))); + + // Add entries + jumpList.push({ + type: 'custom', + name: nls.localize('recentFolders', "Recent Folders"), + items: this.getRecentPathsList().folders.slice(0, 7 /* limit number of entries here */).map(folder => { + return { + type: 'task', + title: path.basename(folder) || folder, // use the base name to show shorter entries in the list + description: nls.localize('folderDesc', "{0} {1}", path.basename(folder), getPathLabel(path.dirname(folder))), + program: process.execPath, + args: `"${folder}"`, // open folder (use quotes to support paths with whitespaces) + iconPath: 'explorer.exe', // simulate folder icon + iconIndex: 0 + }; + }).filter(i => !!i) + }); + } + + // Recent + jumpList.push({ + type: 'recent' // this enables to show files in the "recent" category + }); + + try { + app.setJumpList(jumpList); + } catch (error) { + this.logService.log('#setJumpList', error); // since setJumpList is relatively new API, make sure to guard for errors + } + } +} \ No newline at end of file diff --git a/src/vs/platform/log/common/log.ts b/src/vs/platform/log/common/log.ts index c9908624211..51427842fea 100644 --- a/src/vs/platform/log/common/log.ts +++ b/src/vs/platform/log/common/log.ts @@ -16,7 +16,7 @@ export interface ILogService { log(...args: any[]): void; } -export class MainLogService implements ILogService { +export class LogMainService implements ILogService { _serviceBrand: any; diff --git a/src/vs/platform/windows/electron-main/windows.ts b/src/vs/platform/windows/electron-main/windows.ts index f093d694f0c..50f47d21104 100644 --- a/src/vs/platform/windows/electron-main/windows.ts +++ b/src/vs/platform/windows/electron-main/windows.ts @@ -43,7 +43,6 @@ export interface IWindowsMainService { onWindowClose: Event; onWindowReload: Event; onPathsOpen: Event; - onRecentPathsChange: Event; // methods ready(initialUserEnv: IProcessEnvironment): void; @@ -63,12 +62,6 @@ export interface IWindowsMainService { getWindowById(windowId: number): ICodeWindow; getWindows(): ICodeWindow[]; getWindowCount(): number; - addToRecentPathsList(paths: { path: string; isFile?: boolean; }[]): void; - getRecentPathsList(workspacePath?: string, filesToOpen?: IPath[]): IRecentPathsList; - removeFromRecentPathsList(path: string): void; - removeFromRecentPathsList(paths: string[]): void; - clearRecentPathsList(): void; - updateWindowsJumpList(): void; quit(): void; } @@ -86,11 +79,6 @@ export interface IOpenConfiguration { initialStartup?: boolean; } -export interface IRecentPathsList { - folders: string[]; - files: string[]; -} - export interface ISharedProcess { whenReady(): TPromise; toggle(): void; diff --git a/src/vs/platform/windows/electron-main/windowsService.ts b/src/vs/platform/windows/electron-main/windowsService.ts index 2838717da32..f1c49b83fea 100644 --- a/src/vs/platform/windows/electron-main/windowsService.ts +++ b/src/vs/platform/windows/electron-main/windowsService.ts @@ -18,6 +18,7 @@ import { IURLService } from 'vs/platform/url/common/url'; import { ITelemetryData } from 'vs/platform/telemetry/common/telemetry'; import { ILifecycleService } from "vs/platform/lifecycle/electron-main/lifecycleMain"; import { IWindowsMainService, ISharedProcess } from "vs/platform/windows/electron-main/windows"; +import { IHistoryMainService } from "vs/platform/history/electron-main/historyMainService"; export class WindowsService implements IWindowsService, IDisposable { @@ -33,7 +34,8 @@ export class WindowsService implements IWindowsService, IDisposable { @IWindowsMainService private windowsMainService: IWindowsMainService, @IEnvironmentService private environmentService: IEnvironmentService, @IURLService urlService: IURLService, - @ILifecycleService private lifecycleService: ILifecycleService + @ILifecycleService private lifecycleService: ILifecycleService, + @IHistoryMainService private historyService: IHistoryMainService ) { chain(urlService.onOpenURL) .filter(uri => uri.authority === 'file' && !!uri.path) @@ -124,19 +126,19 @@ export class WindowsService implements IWindowsService, IDisposable { } addToRecentlyOpen(paths: { path: string, isFile?: boolean }[]): TPromise { - this.windowsMainService.addToRecentPathsList(paths); + this.historyService.addToRecentPathsList(paths); return TPromise.as(null); } removeFromRecentlyOpen(paths: string[]): TPromise { - this.windowsMainService.removeFromRecentPathsList(paths); + this.historyService.removeFromRecentPathsList(paths); return TPromise.as(null); } clearRecentPathsList(): TPromise { - this.windowsMainService.clearRecentPathsList(); + this.historyService.clearRecentPathsList(); return TPromise.as(null); } @@ -144,7 +146,7 @@ export class WindowsService implements IWindowsService, IDisposable { const codeWindow = this.windowsMainService.getWindowById(windowId); if (codeWindow) { - const { files, folders } = this.windowsMainService.getRecentPathsList(codeWindow.config.workspacePath, codeWindow.config.filesToOpen); + const { files, folders } = this.historyService.getRecentPathsList(codeWindow.config.workspacePath, codeWindow.config.filesToOpen); return TPromise.as({ files, folders }); } -- GitLab From 2e4f2fb092f27559c3576549a3415d25297d7bf5 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Fri, 9 Jun 2017 08:37:24 +0200 Subject: [PATCH 0659/1347] main - move some events into app.ts --- src/vs/code/electron-main/app.ts | 90 ++++++++++++ src/vs/code/electron-main/windows.ts | 207 ++++++++------------------- 2 files changed, 152 insertions(+), 145 deletions(-) diff --git a/src/vs/code/electron-main/app.ts b/src/vs/code/electron-main/app.ts index 53f7e77bd38..77aa83653c5 100644 --- a/src/vs/code/electron-main/app.ts +++ b/src/vs/code/electron-main/app.ts @@ -46,6 +46,10 @@ import { ConfigurationService } from 'vs/platform/configuration/node/configurati import { TPromise } from "vs/base/common/winjs.base"; import { IWindowsMainService } from "vs/platform/windows/electron-main/windows"; import { IHistoryMainService } from "vs/platform/history/electron-main/historyMainService"; +import { isUndefinedOrNull } from "vs/base/common/types"; +import { CodeWindow } from "vs/code/electron-main/window"; +import { isEqual, isParent } from "vs/platform/files/common/files"; +import { KeyboardLayoutMonitor } from "vs/code/electron-main/keyboard"; export class CodeApplication { private toDispose: IDisposable[]; @@ -102,6 +106,51 @@ export class CodeApplication { this.dispose(); }); + app.on('accessibility-support-changed', (event: Event, accessibilitySupportEnabled: boolean) => { + if (this.windowsMainService) { + this.windowsMainService.sendToAll('vscode:accessibilitySupportChanged', accessibilitySupportEnabled); + } + }); + + app.on('activate', (event: Event, hasVisibleWindows: boolean) => { + this.logService.log('App#activate'); + + // Mac only event: open new window when we get activated + if (!hasVisibleWindows && this.windowsMainService) { + this.windowsMainService.openNewWindow(OpenContext.DOCK); + } + }); + + let macOpenFiles: string[] = []; + let runningTimeout: number = null; + app.on('open-file', (event: Event, path: string) => { + this.logService.log('App#open-file: ', path); + event.preventDefault(); + + // Keep in array because more might come! + macOpenFiles.push(path); + + // Clear previous handler if any + if (runningTimeout !== null) { + clearTimeout(runningTimeout); + runningTimeout = null; + } + + // Handle paths delayed in case more are coming! + runningTimeout = setTimeout(() => { + if (this.windowsMainService) { + this.windowsMainService.open({ + context: OpenContext.DOCK /* can also be opening from finder while app is running */, + cli: this.environmentService.args, + pathsToOpen: macOpenFiles, + preferNewWindow: true /* dropping on the dock or opening from finder prefers to open in a new window */ + }); + macOpenFiles = []; + runningTimeout = null; + } + }, 100); + }); + ipc.on('vscode:exit', (event, code: number) => { this.logService.log('IPC#vscode:exit', code); @@ -127,6 +176,47 @@ export class CodeApplication { console.error('Error fetching shell env', err); }); }); + + ipc.on('vscode:broadcast', (event, windowId: number, target: string, broadcast: { channel: string; payload: any; }) => { + if (this.windowsMainService && broadcast.channel && !isUndefinedOrNull(broadcast.payload)) { + this.logService.log('IPC#vscode:broadcast', target, broadcast.channel, broadcast.payload); + + // Handle specific events on main side + this.onBroadcast(broadcast.channel, broadcast.payload); + + // Send to windows + if (target) { + const otherWindowsWithTarget = this.windowsMainService.getWindows().filter(w => w.id !== windowId && typeof w.openedWorkspacePath === 'string'); + const directTargetMatch = otherWindowsWithTarget.filter(w => isEqual(target, w.openedWorkspacePath, !platform.isLinux /* ignorecase */)); + const parentTargetMatch = otherWindowsWithTarget.filter(w => isParent(target, w.openedWorkspacePath, !platform.isLinux /* ignorecase */)); + + const targetWindow = directTargetMatch.length ? directTargetMatch[0] : parentTargetMatch[0]; // prefer direct match over parent match + if (targetWindow) { + targetWindow.send('vscode:broadcast', broadcast); + } + } else { + this.windowsMainService.sendToAll('vscode:broadcast', broadcast, [windowId]); + } + } + }); + + // Keyboard layout changes + KeyboardLayoutMonitor.INSTANCE.onDidChangeKeyboardLayout(isISOKeyboard => { + if (this.windowsMainService) { + this.windowsMainService.sendToAll('vscode:keyboardLayoutChanged', isISOKeyboard); + } + }); + } + + private onBroadcast(event: string, payload: any): void { + + // Theme changes + if (event === 'vscode:changeColorTheme' && typeof payload === 'string') { + let data = JSON.parse(payload); + + this.storageService.setItem(CodeWindow.themeStorageKey, data.id); + this.storageService.setItem(CodeWindow.themeBackgroundStorageKey, data.background); + } } public startup(): void { diff --git a/src/vs/code/electron-main/windows.ts b/src/vs/code/electron-main/windows.ts index 7e19e0fe300..c3857975e30 100644 --- a/src/vs/code/electron-main/windows.ts +++ b/src/vs/code/electron-main/windows.ts @@ -9,7 +9,6 @@ import * as path from 'path'; import * as fs from 'original-fs'; import * as platform from 'vs/base/common/platform'; import * as nls from 'vs/nls'; -import * as types from 'vs/base/common/types'; import * as arrays from 'vs/base/common/arrays'; import { assign, mixin } from 'vs/base/common/objects'; import { IBackupMainService } from 'vs/platform/backup/common/backup'; @@ -26,8 +25,7 @@ import { getLastActiveWindow, findBestWindowOrFolder } from 'vs/code/node/window import CommonEvent, { Emitter } from 'vs/base/common/event'; import product from 'vs/platform/node/product'; import { ITelemetryService, ITelemetryData } from 'vs/platform/telemetry/common/telemetry'; -import { isParent, isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; -import { KeyboardLayoutMonitor } from 'vs/code/electron-main/keyboard'; +import { isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; import { IWindowsMainService, IOpenConfiguration } from "vs/platform/windows/electron-main/windows"; import { IHistoryMainService } from "vs/platform/history/electron-main/historyMainService"; @@ -100,58 +98,19 @@ export class WindowsManager implements IWindowsMainService { @ITelemetryService private telemetryService: ITelemetryService, @IConfigurationService private configurationService: IConfigurationService, @IHistoryMainService private historyService: IHistoryMainService - ) { } + ) { + this.windowsState = this.storageService.getItem(WindowsManager.windowsStateStorageKey) || { openedFolders: [] }; + } public ready(initialUserEnv: platform.IProcessEnvironment): void { - this.registerListeners(); - this.initialUserEnv = initialUserEnv; - this.windowsState = this.storageService.getItem(WindowsManager.windowsStateStorageKey) || { openedFolders: [] }; + + this.registerListeners(); } private registerListeners(): void { - app.on('accessibility-support-changed', (event: Event, accessibilitySupportEnabled: boolean) => { - this.sendToAll('vscode:accessibilitySupportChanged', accessibilitySupportEnabled); - }); - - app.on('activate', (event: Event, hasVisibleWindows: boolean) => { - this.logService.log('App#activate'); - - // Mac only event: open new window when we get activated - if (!hasVisibleWindows) { - this.openNewWindow(OpenContext.DOCK); - } - }); - - let macOpenFiles: string[] = []; - let runningTimeout: number = null; - app.on('open-file', (event: Event, path: string) => { - this.logService.log('App#open-file: ', path); - event.preventDefault(); - - // Keep in array because more might come! - macOpenFiles.push(path); - - // Clear previous handler if any - if (runningTimeout !== null) { - clearTimeout(runningTimeout); - runningTimeout = null; - } - - // Handle paths delayed in case more are coming! - runningTimeout = setTimeout(() => { - this.open({ - context: OpenContext.DOCK /* can also be opening from finder while app is running */, - cli: this.environmentService.args, - pathsToOpen: macOpenFiles, - preferNewWindow: true /* dropping on the dock or opening from finder prefers to open in a new window */ - }); - macOpenFiles = []; - runningTimeout = null; - }, 100); - }); - + // React to workbench loaded events from windows ipc.on('vscode:workbenchLoaded', (event, windowId: number) => { this.logService.log('IPC#vscode-workbenchLoaded'); @@ -164,35 +123,9 @@ export class WindowsManager implements IWindowsMainService { } }); - ipc.on('vscode:broadcast', (event, windowId: number, target: string, broadcast: { channel: string; payload: any; }) => { - if (broadcast.channel && !types.isUndefinedOrNull(broadcast.payload)) { - this.logService.log('IPC#vscode:broadcast', target, broadcast.channel, broadcast.payload); - - // Handle specific events on main side - this.onBroadcast(broadcast.channel, broadcast.payload); - - // Send to windows - if (target) { - const otherWindowsWithTarget = WindowsManager.WINDOWS.filter(w => w.id !== windowId && typeof w.openedWorkspacePath === 'string'); - const directTargetMatch = otherWindowsWithTarget.filter(w => isEqual(target, w.openedWorkspacePath, !platform.isLinux /* ignorecase */)); - const parentTargetMatch = otherWindowsWithTarget.filter(w => isParent(target, w.openedWorkspacePath, !platform.isLinux /* ignorecase */)); - - const targetWindow = directTargetMatch.length ? directTargetMatch[0] : parentTargetMatch[0]; // prefer direct match over parent match - if (targetWindow) { - targetWindow.send('vscode:broadcast', broadcast); - } - } else { - this.sendToAll('vscode:broadcast', broadcast, [windowId]); - } - } - }); - // Update our windows state before quitting and before closing windows this.lifecycleService.onBeforeWindowClose(win => this.onBeforeWindowClose(win as CodeWindow)); this.lifecycleService.onBeforeQuit(() => this.onBeforeQuit()); - - // Keyboard layout changes - KeyboardLayoutMonitor.INSTANCE.onDidChangeKeyboardLayout(isISOKeyboard => this.sendToAll('vscode:keyboardLayoutChanged', isISOKeyboard)); } // Note that onBeforeQuit() and onBeforeWindowClose() are fired in different order depending on the OS: @@ -275,16 +208,6 @@ export class WindowsManager implements IWindowsMainService { } } - private onBroadcast(event: string, payload: any): void { - - // Theme changes - if (event === 'vscode:changeColorTheme' && typeof payload === 'string') { - - let data = JSON.parse(payload); - this.storageService.setItem(CodeWindow.themeStorageKey, data.id); - this.storageService.setItem(CodeWindow.themeBackgroundStorageKey, data.background); - } - } public reload(win: CodeWindow, cli?: ParsedArgs): void { // Only reload when the window has not vetoed this @@ -525,12 +448,6 @@ export class WindowsManager implements IWindowsMainService { return arrays.distinct(usedWindows); } - - - private getWindowUserEnv(openConfig: IOpenConfiguration): platform.IProcessEnvironment { - return assign({}, this.initialUserEnv, openConfig.userEnv || {}); - } - public openExtensionDevelopmentHostWindow(openConfig: IOpenConfiguration): void { // Reload an existing extension development host window on the same path @@ -568,7 +485,7 @@ export class WindowsManager implements IWindowsMainService { const configuration: IWindowConfiguration = mixin({}, config.cli); // inherit all properties from CLI configuration.appRoot = this.environmentService.appRoot; configuration.execPath = process.execPath; - configuration.userEnv = this.getWindowUserEnv(config); + configuration.userEnv = assign({}, this.initialUserEnv, config.userEnv || {}); configuration.isInitialStartup = config.initialStartup; configuration.workspacePath = workspacePath; configuration.filesToOpen = filesToOpen; @@ -852,60 +769,6 @@ export class WindowsManager implements IWindowsMainService { return state; } - public openFileFolderPicker(forceNewWindow?: boolean, data?: ITelemetryData): void { - this.doPickAndOpen({ pickFolders: true, pickFiles: true, forceNewWindow }, 'openFileFolder', data); - } - - public openFilePicker(forceNewWindow?: boolean, path?: string, window?: CodeWindow, data?: ITelemetryData): void { - this.doPickAndOpen({ pickFiles: true, forceNewWindow, path, window }, 'openFile', data); - } - - public openFolderPicker(forceNewWindow?: boolean, window?: CodeWindow, data?: ITelemetryData): void { - this.doPickAndOpen({ pickFolders: true, forceNewWindow, window }, 'openFolder', data); - } - - private doPickAndOpen(options: INativeOpenDialogOptions, eventName: string, data?: ITelemetryData): void { - this.getFileOrFolderPaths(options, (paths: string[]) => { - const nOfPaths = paths ? paths.length : 0; - if (nOfPaths) { - this.open({ context: OpenContext.DIALOG, cli: this.environmentService.args, pathsToOpen: paths, forceNewWindow: options.forceNewWindow }); - } - this.telemetryService.publicLog(eventName, { - ...data, - outcome: nOfPaths ? 'success' : 'canceled', - nOfPaths - }); - }); - } - - private getFileOrFolderPaths(options: INativeOpenDialogOptions, clb: (paths: string[]) => void): void { - const workingDir = options.path || this.storageService.getItem(WindowsManager.workingDirPickerStorageKey); - const focussedWindow = options.window || this.getFocusedWindow(); - - let pickerProperties: ('openFile' | 'openDirectory' | 'multiSelections' | 'createDirectory')[]; - if (options.pickFiles && options.pickFolders) { - pickerProperties = ['multiSelections', 'openDirectory', 'openFile', 'createDirectory']; - } else { - pickerProperties = ['multiSelections', options.pickFolders ? 'openDirectory' : 'openFile', 'createDirectory']; - } - - dialog.showOpenDialog(focussedWindow && focussedWindow.win, { - defaultPath: workingDir, - properties: pickerProperties - }, paths => { - if (paths && paths.length > 0) { - - // Remember path in storage for next time - this.storageService.setItem(WindowsManager.workingDirPickerStorageKey, path.dirname(paths[0])); - - // Return - clb(paths); - } else { - clb(void (0)); - } - }); - } - public focusLastActive(cli: ParsedArgs, context: OpenContext): CodeWindow { const lastActive = this.getLastActiveWindow(); if (lastActive) { @@ -1080,6 +943,60 @@ export class WindowsManager implements IWindowsMainService { this._onWindowClose.fire(win.id); } + public openFileFolderPicker(forceNewWindow?: boolean, data?: ITelemetryData): void { + this.doPickAndOpen({ pickFolders: true, pickFiles: true, forceNewWindow }, 'openFileFolder', data); + } + + public openFilePicker(forceNewWindow?: boolean, path?: string, window?: CodeWindow, data?: ITelemetryData): void { + this.doPickAndOpen({ pickFiles: true, forceNewWindow, path, window }, 'openFile', data); + } + + public openFolderPicker(forceNewWindow?: boolean, window?: CodeWindow, data?: ITelemetryData): void { + this.doPickAndOpen({ pickFolders: true, forceNewWindow, window }, 'openFolder', data); + } + + private doPickAndOpen(options: INativeOpenDialogOptions, eventName: string, data?: ITelemetryData): void { + this.getFileOrFolderPaths(options, (paths: string[]) => { + const nOfPaths = paths ? paths.length : 0; + if (nOfPaths) { + this.open({ context: OpenContext.DIALOG, cli: this.environmentService.args, pathsToOpen: paths, forceNewWindow: options.forceNewWindow }); + } + this.telemetryService.publicLog(eventName, { + ...data, + outcome: nOfPaths ? 'success' : 'canceled', + nOfPaths + }); + }); + } + + private getFileOrFolderPaths(options: INativeOpenDialogOptions, clb: (paths: string[]) => void): void { + const workingDir = options.path || this.storageService.getItem(WindowsManager.workingDirPickerStorageKey); + const focussedWindow = options.window || this.getFocusedWindow(); + + let pickerProperties: ('openFile' | 'openDirectory' | 'multiSelections' | 'createDirectory')[]; + if (options.pickFiles && options.pickFolders) { + pickerProperties = ['multiSelections', 'openDirectory', 'openFile', 'createDirectory']; + } else { + pickerProperties = ['multiSelections', options.pickFolders ? 'openDirectory' : 'openFile', 'createDirectory']; + } + + dialog.showOpenDialog(focussedWindow && focussedWindow.win, { + defaultPath: workingDir, + properties: pickerProperties + }, paths => { + if (paths && paths.length > 0) { + + // Remember path in storage for next time + this.storageService.setItem(WindowsManager.workingDirPickerStorageKey, path.dirname(paths[0])); + + // Return + clb(paths); + } else { + clb(void (0)); + } + }); + } + public quit(): void { // If the user selected to exit from an extension development host window, do not quit, but just -- GitLab From 16ffd060c4e4160894f1f5781f26b3909fd3247d Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 9 Jun 2017 08:49:47 +0200 Subject: [PATCH 0660/1347] Fixes Microsoft/monaco-editor#388: Validate tokens produced by custom tokenizers --- .../browser/standalone/standaloneLanguages.ts | 43 ++++- .../standalone/standaloneLanguages.test.ts | 178 ++++++++++++++++++ 2 files changed, 214 insertions(+), 7 deletions(-) create mode 100644 src/vs/editor/test/browser/standalone/standaloneLanguages.test.ts diff --git a/src/vs/editor/browser/standalone/standaloneLanguages.ts b/src/vs/editor/browser/standalone/standaloneLanguages.ts index 2e23e5a33ec..0750a1db0a9 100644 --- a/src/vs/editor/browser/standalone/standaloneLanguages.ts +++ b/src/vs/editor/browser/standalone/standaloneLanguages.ts @@ -89,9 +89,23 @@ export class TokenizationSupport2Adapter implements modes.ITokenizationSupport { private _toClassicTokens(tokens: IToken[], language: string, offsetDelta: number): Token[] { let result: Token[] = []; + let previousStartIndex: number = 0; for (let i = 0, len = tokens.length; i < len; i++) { - let t = tokens[i]; - result[i] = new Token(t.startIndex + offsetDelta, t.scopes, language); + const t = tokens[i]; + let startIndex = t.startIndex; + + // Prevent issues stemming from a buggy external tokenizer. + if (i === 0) { + // Force first token to start at first index! + startIndex = 0; + } else if (startIndex < previousStartIndex) { + // Force tokens to be after one another! + startIndex = previousStartIndex; + } + + result[i] = new Token(startIndex + offsetDelta, t.scopes, language); + + previousStartIndex = startIndex; } return result; } @@ -112,19 +126,34 @@ export class TokenizationSupport2Adapter implements modes.ITokenizationSupport { } private _toBinaryTokens(tokens: IToken[], offsetDelta: number): Uint32Array { - let languageId = this._languageIdentifier.id; - let tokenTheme = this._standaloneThemeService.getTheme().tokenTheme; + const languageId = this._languageIdentifier.id; + const tokenTheme = this._standaloneThemeService.getTheme().tokenTheme; let result: number[] = [], resultLen = 0; + let previousStartIndex: number = 0; for (let i = 0, len = tokens.length; i < len; i++) { - let t = tokens[i]; - let metadata = tokenTheme.match(languageId, t.scopes); + const t = tokens[i]; + const metadata = tokenTheme.match(languageId, t.scopes); if (resultLen > 0 && result[resultLen - 1] === metadata) { // same metadata continue; } - result[resultLen++] = t.startIndex; + + let startIndex = t.startIndex; + + // Prevent issues stemming from a buggy external tokenizer. + if (i === 0) { + // Force first token to start at first index! + startIndex = 0; + } else if (startIndex < previousStartIndex) { + // Force tokens to be after one another! + startIndex = previousStartIndex; + } + + result[resultLen++] = startIndex + offsetDelta; result[resultLen++] = metadata; + + previousStartIndex = startIndex; } let actualResult = new Uint32Array(resultLen); diff --git a/src/vs/editor/test/browser/standalone/standaloneLanguages.test.ts b/src/vs/editor/test/browser/standalone/standaloneLanguages.test.ts new file mode 100644 index 00000000000..eed002041d1 --- /dev/null +++ b/src/vs/editor/test/browser/standalone/standaloneLanguages.test.ts @@ -0,0 +1,178 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +'use strict'; + +import * as assert from 'assert'; +import { TokenizationSupport2Adapter, TokensProvider, ILineTokens, IToken } from "vs/editor/browser/standalone/standaloneLanguages"; +import { IStandaloneThemeService, IStandaloneThemeData, IStandaloneTheme } from "vs/editor/common/services/standaloneThemeService"; +import Event from 'vs/base/common/event'; +import { ITheme, LIGHT } from "vs/platform/theme/common/themeService"; +import { LanguageIdentifier, LanguageId, IState, MetadataConsts } from "vs/editor/common/modes"; +import { Token } from "vs/editor/common/core/token"; +import { TokenTheme } from "vs/editor/common/modes/supports/tokenization"; +import { ColorIdentifier } from "vs/platform/theme/common/colorRegistry"; +import { Color } from "vs/base/common/color"; + +suite('TokenizationSupport2Adapter', () => { + + const languageIdentifier = new LanguageIdentifier('tttt', LanguageId.PlainText); + const tokenMetadata = (languageIdentifier.id << MetadataConsts.LANGUAGEID_OFFSET); + + class MockTokenTheme extends TokenTheme { + private counter = 0; + constructor() { + super(null, null); + } + public match(languageId: LanguageId, token: string): number { + return ( + ((this.counter++) << MetadataConsts.FOREGROUND_OFFSET) + | (languageId << MetadataConsts.LANGUAGEID_OFFSET) + ) >>> 0; + } + } + + class MockThemeService implements IStandaloneThemeService { + _serviceBrand = null; + public setTheme(themeName: string): string { + throw new Error('Not implemented'); + } + public defineTheme(themeName: string, themeData: IStandaloneThemeData): void { + throw new Error('Not implemented'); + } + public getTheme(): IStandaloneTheme { + return { + tokenTheme: new MockTokenTheme(), + + type: LIGHT, + + getColor: (color: ColorIdentifier, useDefault?: boolean): Color => { + throw new Error('Not implemented'); + }, + + defines: (color: ColorIdentifier): boolean => { + throw new Error('Not implemented'); + } + }; + } + public onThemeChange: Event = null; + } + + class MockState implements IState { + public static INSTANCE = new MockState(); + private constructor() { } + public clone(): IState { + return this; + } + public equals(other: IState): boolean { + return this === other; + } + } + + function testBadTokensProvider(providerTokens: IToken[], offsetDelta: number, expectedClassicTokens: Token[], expectedModernTokens: number[]): void { + + class BadTokensProvider implements TokensProvider { + public getInitialState(): IState { + return MockState.INSTANCE; + } + public tokenize(line: string, state: IState): ILineTokens { + return { + tokens: providerTokens, + endState: MockState.INSTANCE + }; + } + } + + const adapter = new TokenizationSupport2Adapter(new MockThemeService(), languageIdentifier, new BadTokensProvider()); + + const actualClassicTokens = adapter.tokenize('whatever', MockState.INSTANCE, offsetDelta); + assert.deepEqual(actualClassicTokens.tokens, expectedClassicTokens); + + const actualModernTokens = adapter.tokenize2('whatever', MockState.INSTANCE, offsetDelta); + const modernTokens: number[] = []; + for (let i = 0; i < actualModernTokens.tokens.length; i++) { + modernTokens[i] = actualModernTokens.tokens[i]; + } + assert.deepEqual(modernTokens, expectedModernTokens); + } + + test('tokens always start at index 0 (no offset delta)', () => { + testBadTokensProvider( + [ + { startIndex: 7, scopes: 'foo' }, + { startIndex: 0, scopes: 'bar' } + ], + 0, + [ + new Token(0, 'foo', languageIdentifier.language), + new Token(0, 'bar', languageIdentifier.language), + ], + [ + 0, tokenMetadata | (0 << MetadataConsts.FOREGROUND_OFFSET), + 0, tokenMetadata | (1 << MetadataConsts.FOREGROUND_OFFSET) + ] + ); + }); + + test('tokens always start after each other (no offset delta)', () => { + testBadTokensProvider( + [ + { startIndex: 0, scopes: 'foo' }, + { startIndex: 5, scopes: 'bar' }, + { startIndex: 3, scopes: 'foo' }, + ], + 0, + [ + new Token(0, 'foo', languageIdentifier.language), + new Token(5, 'bar', languageIdentifier.language), + new Token(5, 'foo', languageIdentifier.language), + ], + [ + 0, tokenMetadata | (0 << MetadataConsts.FOREGROUND_OFFSET), + 5, tokenMetadata | (1 << MetadataConsts.FOREGROUND_OFFSET), + 5, tokenMetadata | (2 << MetadataConsts.FOREGROUND_OFFSET) + ] + ); + }); + + test('tokens always start at index 0 (with offset delta)', () => { + testBadTokensProvider( + [ + { startIndex: 7, scopes: 'foo' }, + { startIndex: 0, scopes: 'bar' } + ], + 7, + [ + new Token(7, 'foo', languageIdentifier.language), + new Token(7, 'bar', languageIdentifier.language), + ], + [ + 7, tokenMetadata | (0 << MetadataConsts.FOREGROUND_OFFSET), + 7, tokenMetadata | (1 << MetadataConsts.FOREGROUND_OFFSET) + ] + ); + }); + + test('tokens always start after each other (with offset delta)', () => { + testBadTokensProvider( + [ + { startIndex: 0, scopes: 'foo' }, + { startIndex: 5, scopes: 'bar' }, + { startIndex: 3, scopes: 'foo' }, + ], + 7, + [ + new Token(7, 'foo', languageIdentifier.language), + new Token(12, 'bar', languageIdentifier.language), + new Token(12, 'foo', languageIdentifier.language), + ], + [ + 7, tokenMetadata | (0 << MetadataConsts.FOREGROUND_OFFSET), + 12, tokenMetadata | (1 << MetadataConsts.FOREGROUND_OFFSET), + 12, tokenMetadata | (2 << MetadataConsts.FOREGROUND_OFFSET) + ] + ); + }); + +}); \ No newline at end of file -- GitLab From e51b11b5a68efe976cb39fb4a54515603874cc57 Mon Sep 17 00:00:00 2001 From: jens1o Date: Fri, 9 Jun 2017 08:52:59 +0200 Subject: [PATCH 0661/1347] add more settings to gear menu --- src/vs/workbench/parts/update/electron-browser/update.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/vs/workbench/parts/update/electron-browser/update.ts b/src/vs/workbench/parts/update/electron-browser/update.ts index c42a94259ba..a45dc3b22f2 100644 --- a/src/vs/workbench/parts/update/electron-browser/update.ts +++ b/src/vs/workbench/parts/update/electron-browser/update.ts @@ -282,6 +282,8 @@ export class LightUpdateContribution implements IGlobalActivity { private static readonly showCommandsId = 'workbench.action.showCommands'; private static readonly openSettingsId = 'workbench.action.openGlobalSettings'; private static readonly openKeybindingsId = 'workbench.action.openGlobalKeybindings'; + private static readonly selectIconThemeId = 'workbench.action.selectIconTheme'; + private static readonly selectColorThemeId = 'workbench.action.selectTheme'; get id() { return 'vs.update'; } get name() { return ''; } @@ -324,6 +326,9 @@ export class LightUpdateContribution implements IGlobalActivity { new Action(LightUpdateContribution.openSettingsId, nls.localize('settings', "Settings"), null, true, () => this.commandService.executeCommand(LightUpdateContribution.openSettingsId)), new Action(LightUpdateContribution.openKeybindingsId, nls.localize('keyboardShortcuts', "Keyboard Shortcuts"), null, true, () => this.commandService.executeCommand(LightUpdateContribution.openKeybindingsId)), new Separator(), + new Action(LightUpdateContribution.selectIconThemeId, nls.localize('themes.selectIconTheme', "Select File Icon Theme"), null, true, () => this.commandService.executeCommand(LightUpdateContribution.selectIconThemeId)), + new Action(LightUpdateContribution.selectColorThemeId, nls.localize('selectTheme.label', "Color Theme"), null, true, () => this.commandService.executeCommand(LightUpdateContribution.selectColorThemeId)), + new Separator(), this.getUpdateAction() ]; } -- GitLab From 455a4e65db838cdcc96cb40c847201044130b4f6 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Fri, 9 Jun 2017 08:55:19 +0200 Subject: [PATCH 0662/1347] :lipstick: --- src/vs/code/electron-main/windows.ts | 109 +++++++++++++++------------ 1 file changed, 62 insertions(+), 47 deletions(-) diff --git a/src/vs/code/electron-main/windows.ts b/src/vs/code/electron-main/windows.ts index c3857975e30..93a7c4c7120 100644 --- a/src/vs/code/electron-main/windows.ts +++ b/src/vs/code/electron-main/windows.ts @@ -49,14 +49,6 @@ interface IWindowsState { openedFolders: IWindowState[]; } -interface INativeOpenDialogOptions { - pickFolders?: boolean; - pickFiles?: boolean; - path?: string; - forceNewWindow?: boolean; - window?: CodeWindow; -} - const ReopenFoldersSetting = { ALL: 'all', ONE: 'one', @@ -67,7 +59,6 @@ export class WindowsManager implements IWindowsMainService { _serviceBrand: any; - private static workingDirPickerStorageKey = 'pickerWorkingDir'; private static windowsStateStorageKey = 'windowsState'; private static WINDOWS: CodeWindow[] = []; @@ -77,6 +68,8 @@ export class WindowsManager implements IWindowsMainService { private windowsState: IWindowsState; private lastClosedWindowState: IWindowState; + private fileDialog: FileDialog; + private _onWindowReady = new Emitter(); onWindowReady: CommonEvent = this._onWindowReady.event; @@ -100,6 +93,7 @@ export class WindowsManager implements IWindowsMainService { @IHistoryMainService private historyService: IHistoryMainService ) { this.windowsState = this.storageService.getItem(WindowsManager.windowsStateStorageKey) || { openedFolders: [] }; + this.fileDialog = new FileDialog(environmentService, telemetryService, storageService, this); } public ready(initialUserEnv: platform.IProcessEnvironment): void { @@ -208,19 +202,6 @@ export class WindowsManager implements IWindowsMainService { } } - public reload(win: CodeWindow, cli?: ParsedArgs): void { - - // Only reload when the window has not vetoed this - this.lifecycleService.unload(win, UnloadReason.RELOAD).done(veto => { - if (!veto) { - win.reload(cli); - - // Emit - this._onWindowReload.fire(win.id); - } - }); - } - public open(openConfig: IOpenConfiguration): CodeWindow[] { const windowConfig = this.configurationService.getConfiguration('window'); @@ -769,6 +750,19 @@ export class WindowsManager implements IWindowsMainService { return state; } + public reload(win: CodeWindow, cli?: ParsedArgs): void { + + // Only reload when the window has not vetoed this + this.lifecycleService.unload(win, UnloadReason.RELOAD).done(veto => { + if (!veto) { + win.reload(cli); + + // Emit + this._onWindowReload.fire(win.id); + } + }); + } + public focusLastActive(cli: ParsedArgs, context: OpenContext): CodeWindow { const lastActive = this.getLastActiveWindow(); if (lastActive) { @@ -944,22 +938,60 @@ export class WindowsManager implements IWindowsMainService { } public openFileFolderPicker(forceNewWindow?: boolean, data?: ITelemetryData): void { - this.doPickAndOpen({ pickFolders: true, pickFiles: true, forceNewWindow }, 'openFileFolder', data); + this.fileDialog.pickAndOpen({ pickFolders: true, pickFiles: true, forceNewWindow }, 'openFileFolder', data); } public openFilePicker(forceNewWindow?: boolean, path?: string, window?: CodeWindow, data?: ITelemetryData): void { - this.doPickAndOpen({ pickFiles: true, forceNewWindow, path, window }, 'openFile', data); + this.fileDialog.pickAndOpen({ pickFiles: true, forceNewWindow, path, window }, 'openFile', data); } public openFolderPicker(forceNewWindow?: boolean, window?: CodeWindow, data?: ITelemetryData): void { - this.doPickAndOpen({ pickFolders: true, forceNewWindow, window }, 'openFolder', data); + this.fileDialog.pickAndOpen({ pickFolders: true, forceNewWindow, window }, 'openFolder', data); + } + + public quit(): void { + + // If the user selected to exit from an extension development host window, do not quit, but just + // close the window unless this is the last window that is opened. + const codeWindow = this.getFocusedWindow(); + if (codeWindow && codeWindow.isExtensionDevelopmentHost && this.getWindowCount() > 1) { + codeWindow.win.close(); + } + + // Otherwise: normal quit + else { + setTimeout(() => { + this.lifecycleService.quit(); + }, 10 /* delay to unwind callback stack (IPC) */); + } } +} + +interface INativeOpenDialogOptions { + pickFolders?: boolean; + pickFiles?: boolean; + path?: string; + forceNewWindow?: boolean; + window?: CodeWindow; +} + +class FileDialog { + + private static workingDirPickerStorageKey = 'pickerWorkingDir'; - private doPickAndOpen(options: INativeOpenDialogOptions, eventName: string, data?: ITelemetryData): void { + constructor( + private environmentService: IEnvironmentService, + private telemetryService: ITelemetryService, + private storageService: IStorageService, + private windowsMainService: IWindowsMainService + ) { + } + + public pickAndOpen(options: INativeOpenDialogOptions, eventName: string, data?: ITelemetryData): void { this.getFileOrFolderPaths(options, (paths: string[]) => { const nOfPaths = paths ? paths.length : 0; if (nOfPaths) { - this.open({ context: OpenContext.DIALOG, cli: this.environmentService.args, pathsToOpen: paths, forceNewWindow: options.forceNewWindow }); + this.windowsMainService.open({ context: OpenContext.DIALOG, cli: this.environmentService.args, pathsToOpen: paths, forceNewWindow: options.forceNewWindow }); } this.telemetryService.publicLog(eventName, { ...data, @@ -970,8 +1002,8 @@ export class WindowsManager implements IWindowsMainService { } private getFileOrFolderPaths(options: INativeOpenDialogOptions, clb: (paths: string[]) => void): void { - const workingDir = options.path || this.storageService.getItem(WindowsManager.workingDirPickerStorageKey); - const focussedWindow = options.window || this.getFocusedWindow(); + const workingDir = options.path || this.storageService.getItem(FileDialog.workingDirPickerStorageKey); + const focussedWindow = options.window || this.windowsMainService.getFocusedWindow(); let pickerProperties: ('openFile' | 'openDirectory' | 'multiSelections' | 'createDirectory')[]; if (options.pickFiles && options.pickFolders) { @@ -987,7 +1019,7 @@ export class WindowsManager implements IWindowsMainService { if (paths && paths.length > 0) { // Remember path in storage for next time - this.storageService.setItem(WindowsManager.workingDirPickerStorageKey, path.dirname(paths[0])); + this.storageService.setItem(FileDialog.workingDirPickerStorageKey, path.dirname(paths[0])); // Return clb(paths); @@ -996,21 +1028,4 @@ export class WindowsManager implements IWindowsMainService { } }); } - - public quit(): void { - - // If the user selected to exit from an extension development host window, do not quit, but just - // close the window unless this is the last window that is opened. - const codeWindow = this.getFocusedWindow(); - if (codeWindow && codeWindow.isExtensionDevelopmentHost && this.getWindowCount() > 1) { - codeWindow.win.close(); - } - - // Otherwise: normal quit - else { - setTimeout(() => { - this.lifecycleService.quit(); - }, 10 /* delay to unwind callback stack (IPC) */); - } - } } \ No newline at end of file -- GitLab From 0a6a94a1e4f72d6df49308e982a957afa7f9ee89 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 9 Jun 2017 10:08:17 +0200 Subject: [PATCH 0663/1347] ref - apply editor font to reference search tree --- .../browser/referencesWidget.ts | 22 +++++++++++++------ 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts index 29bc862adde..d40a682c8f8 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts +++ b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts @@ -385,8 +385,9 @@ class OneReferenceTemplate { readonly before: HTMLSpanElement; readonly inside: HTMLSpanElement; readonly after: HTMLSpanElement; + readonly dispose: () => void; - constructor(container: HTMLElement) { + constructor(container: HTMLElement, editor: ICodeEditor) { const parent = document.createElement('div'); this.before = document.createElement('span'); this.inside = document.createElement('span'); @@ -397,6 +398,14 @@ class OneReferenceTemplate { parent.appendChild(this.inside); parent.appendChild(this.after); container.appendChild(parent); + + function applyFontInfo() { + container.style.fontFamily = editor.getConfiguration().fontInfo.fontFamily; + } + + applyFontInfo(); + const reg = editor.onDidChangeConfiguration(e => e.fontInfo && applyFontInfo()); + this.dispose = () => reg.dispose(); } set(element: OneReference): void { @@ -415,9 +424,10 @@ class Renderer implements tree.IRenderer { }; constructor( + private _editor: ICodeEditor, @IWorkspaceContextService private _contextService: IWorkspaceContextService, @IThemeService private _themeService: IThemeService, - @optional(IEnvironmentService) private _environmentService: IEnvironmentService + @optional(IEnvironmentService) private _environmentService: IEnvironmentService, ) { // } @@ -439,7 +449,7 @@ class Renderer implements tree.IRenderer { if (templateId === Renderer._ids.FileReferences) { return new FileReferencesTemplate(container, this._contextService, this._environmentService, this._themeService); } else if (templateId === Renderer._ids.OneReference) { - return new OneReferenceTemplate(container); + return new OneReferenceTemplate(container, this._editor); } throw templateId; } @@ -455,9 +465,7 @@ class Renderer implements tree.IRenderer { } disposeTemplate(tree: tree.ITree, templateId: string, templateData: any): void { - if (templateData instanceof FileReferencesTemplate) { - templateData.dispose(); - } + templateData.dispose(); } } @@ -680,7 +688,7 @@ export class ReferenceWidget extends PeekViewWidget { container.div({ 'class': 'ref-tree inline' }, (div: Builder) => { var config = { dataSource: this._instantiationService.createInstance(DataSource), - renderer: this._instantiationService.createInstance(Renderer), + renderer: this._instantiationService.createInstance(Renderer, this.editor), controller: new Controller(), // TODO@{Joh,Ben} make this work with the embedded tree // accessibilityProvider: new AriaProvider() -- GitLab From 593efb9b89a3746e9623c4c8adadddd299b46562 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 9 Jun 2017 10:26:42 +0200 Subject: [PATCH 0664/1347] Fixes Microsoft/monaco-editor#412: Fix comparison to cover also empty strings --- src/vs/editor/common/modes/monarch/monarchLexer.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/editor/common/modes/monarch/monarchLexer.ts b/src/vs/editor/common/modes/monarch/monarchLexer.ts index fd57abca71a..bc6f6381138 100644 --- a/src/vs/editor/common/modes/monarch/monarchLexer.ts +++ b/src/vs/editor/common/modes/monarch/monarchLexer.ts @@ -755,7 +755,7 @@ export class MonarchTokenizer implements modes.ITokenizationSupport { tokensCollector.emit(pos0 + offsetDelta, tokenType); } - if (enteringEmbeddedMode) { + if (enteringEmbeddedMode !== null) { // substitute language alias to known modes to support syntax highlighting let enteringEmbeddedModeId = this._modeService.getModeIdForLanguageName(enteringEmbeddedMode); if (enteringEmbeddedModeId) { -- GitLab From 3e81316eab43552f51de4d563f04acdbb56a1108 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 9 Jun 2017 10:34:35 +0200 Subject: [PATCH 0665/1347] Revert "load main.js while waiting for app.isReady, #17108" This reverts commit 174fafae53ec26bc3dc1216080061449b17fb080. --- src/main.js | 17 +++++++++-------- src/vs/code/electron-main/main.ts | 14 +------------- 2 files changed, 10 insertions(+), 21 deletions(-) diff --git a/src/main.js b/src/main.js index 9576d766aaf..9bba0165cd7 100644 --- a/src/main.js +++ b/src/main.js @@ -227,12 +227,13 @@ var nodeCachedDataDir = getNodeCachedDataDir().then(function (value) { } }); -var nlsConfig = getNLSConfiguration(); -process.env['VSCODE_NLS_CONFIG'] = JSON.stringify(nlsConfig); - -var bootstrap = require('./bootstrap-amd'); -nodeCachedDataDir.then(function () { - bootstrap.bootstrap('vs/code/electron-main/main'); -}, function (err) { - console.error(err); +// Load our code once ready +app.once('ready', function () { + global.perfAppReady = Date.now(); + var nlsConfig = getNLSConfiguration(); + process.env['VSCODE_NLS_CONFIG'] = JSON.stringify(nlsConfig); + + nodeCachedDataDir.then(function () { + require('./bootstrap-amd').bootstrap('vs/code/electron-main/main'); + }, console.error); }); diff --git a/src/vs/code/electron-main/main.ts b/src/vs/code/electron-main/main.ts index 95b5fbed51b..8af2717ffec 100644 --- a/src/vs/code/electron-main/main.ts +++ b/src/vs/code/electron-main/main.ts @@ -201,16 +201,4 @@ function main() { }).done(null, err => instantiationService.invokeFunction(quit, err)); } -// Get going once we are ready -// TODO@Joh,Joao there more more potential here -// we should check for other instances etc while -// waiting for getting ready -if (app.isReady()) { - global.perfAppReady = Date.now(); - main(); -} else { - app.once('ready', () => { - global.perfAppReady = Date.now(); - main(); - }); -} +main(); \ No newline at end of file -- GitLab From 9202b6a922af878e9d8e5e34bf0f5e4be78fe44b Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Tue, 6 Jun 2017 11:55:37 +0200 Subject: [PATCH 0666/1347] Debt: Rename views to viewsRegistry --- src/vs/workbench/api/electron-browser/mainThreadTreeViews.ts | 2 +- src/vs/workbench/parts/files/browser/explorerViewlet.ts | 2 +- src/vs/workbench/parts/files/browser/views/emptyView.ts | 2 +- src/vs/workbench/parts/files/browser/views/explorerView.ts | 2 +- src/vs/workbench/parts/views/browser/treeView.ts | 2 +- src/vs/workbench/parts/views/browser/viewsExtensionPoint.ts | 2 +- .../parts/views/browser/{views.ts => viewsRegistry.ts} | 0 7 files changed, 6 insertions(+), 6 deletions(-) rename src/vs/workbench/parts/views/browser/{views.ts => viewsRegistry.ts} (100%) diff --git a/src/vs/workbench/api/electron-browser/mainThreadTreeViews.ts b/src/vs/workbench/api/electron-browser/mainThreadTreeViews.ts index b429be71710..18ea315cca7 100644 --- a/src/vs/workbench/api/electron-browser/mainThreadTreeViews.ts +++ b/src/vs/workbench/api/electron-browser/mainThreadTreeViews.ts @@ -9,7 +9,7 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { IThreadService } from 'vs/workbench/services/thread/common/threadService'; import { ExtHostContext, MainThreadTreeViewsShape, ExtHostTreeViewsShape } from '../node/extHost.protocol'; import { IMessageService, Severity } from 'vs/platform/message/common/message'; -import { ViewsRegistry } from 'vs/workbench/parts/views/browser/views'; +import { ViewsRegistry } from 'vs/workbench/parts/views/browser/viewsRegistry'; import { ITreeViewDataProvider, ITreeItem, TreeItemCollapsibleState } from 'vs/workbench/parts/views/common/views'; export class MainThreadTreeViews extends MainThreadTreeViewsShape { diff --git a/src/vs/workbench/parts/files/browser/explorerViewlet.ts b/src/vs/workbench/parts/files/browser/explorerViewlet.ts index 59a054490ff..38ae653e119 100644 --- a/src/vs/workbench/parts/files/browser/explorerViewlet.ts +++ b/src/vs/workbench/parts/files/browser/explorerViewlet.ts @@ -32,7 +32,7 @@ import { IEditorGroupService } from 'vs/workbench/services/group/common/groupSer import { IContextKeyService, IContextKey } from 'vs/platform/contextkey/common/contextkey'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { attachHeaderViewStyler } from 'vs/platform/theme/common/styler'; -import { ViewsRegistry, ViewLocation, IViewDescriptor } from 'vs/workbench/parts/views/browser/views'; +import { ViewsRegistry, ViewLocation, IViewDescriptor } from 'vs/workbench/parts/views/browser/viewsRegistry'; interface IViewState { collapsed: boolean; diff --git a/src/vs/workbench/parts/files/browser/views/emptyView.ts b/src/vs/workbench/parts/files/browser/views/emptyView.ts index de505174be1..5a46c95e1a6 100644 --- a/src/vs/workbench/parts/files/browser/views/emptyView.ts +++ b/src/vs/workbench/parts/files/browser/views/emptyView.ts @@ -18,7 +18,7 @@ import { IInstantiationService } from 'vs/platform/instantiation/common/instanti import { OpenFolderAction, OpenFileFolderAction } from 'vs/workbench/browser/actions/fileActions'; import { attachButtonStyler } from 'vs/platform/theme/common/styler'; import { IThemeService } from 'vs/platform/theme/common/themeService'; -import { IViewOptions } from 'vs/workbench/parts/views/browser/views'; +import { IViewOptions } from 'vs/workbench/parts/views/browser/viewsRegistry'; export class EmptyView extends CollapsibleView { diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index d86e3af8392..c16abfd280a 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -42,7 +42,7 @@ import { IWorkbenchThemeService, IFileIconTheme } from 'vs/workbench/services/th import { isLinux } from 'vs/base/common/platform'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { attachListStyler } from 'vs/platform/theme/common/styler'; -import { IViewOptions } from 'vs/workbench/parts/views/browser/views'; +import { IViewOptions } from 'vs/workbench/parts/views/browser/viewsRegistry'; export class ExplorerView extends CollapsibleViewletView { diff --git a/src/vs/workbench/parts/views/browser/treeView.ts b/src/vs/workbench/parts/views/browser/treeView.ts index b7c39098766..3fe6cf31d13 100644 --- a/src/vs/workbench/parts/views/browser/treeView.ts +++ b/src/vs/workbench/parts/views/browser/treeView.ts @@ -26,7 +26,7 @@ import { IProgressService } from 'vs/platform/progress/common/progress'; import { ITree, IDataSource, IRenderer, ContextMenuEvent } from 'vs/base/parts/tree/browser/tree'; import { IContextKeyService, IContextKey } from 'vs/platform/contextkey/common/contextkey'; import { ActionItem } from 'vs/base/browser/ui/actionbar/actionbar'; -import { ViewsRegistry, IViewOptions } from 'vs/workbench/parts/views/browser/views'; +import { ViewsRegistry, IViewOptions } from 'vs/workbench/parts/views/browser/viewsRegistry'; import { ITreeViewDataProvider, ITreeItem, TreeItemCollapsibleState, TreeViewItemHandleArg } from 'vs/workbench/parts/views/common/views'; import { IExtensionService } from 'vs/platform/extensions/common/extensions'; import { CollapsibleState } from 'vs/base/browser/ui/splitview/splitview'; diff --git a/src/vs/workbench/parts/views/browser/viewsExtensionPoint.ts b/src/vs/workbench/parts/views/browser/viewsExtensionPoint.ts index e7cc066c06a..a5f21d877ce 100644 --- a/src/vs/workbench/parts/views/browser/viewsExtensionPoint.ts +++ b/src/vs/workbench/parts/views/browser/viewsExtensionPoint.ts @@ -8,7 +8,7 @@ import { localize } from 'vs/nls'; import { forEach } from 'vs/base/common/collections'; import { IJSONSchema } from 'vs/base/common/jsonSchema'; import { ExtensionMessageCollector, ExtensionsRegistry } from 'vs/platform/extensions/common/extensionsRegistry'; -import { ViewLocation, ViewsRegistry } from 'vs/workbench/parts/views/browser/views'; +import { ViewLocation, ViewsRegistry } from 'vs/workbench/parts/views/browser/viewsRegistry'; import { TreeView } from 'vs/workbench/parts/views/browser/treeView'; namespace schema { diff --git a/src/vs/workbench/parts/views/browser/views.ts b/src/vs/workbench/parts/views/browser/viewsRegistry.ts similarity index 100% rename from src/vs/workbench/parts/views/browser/views.ts rename to src/vs/workbench/parts/views/browser/viewsRegistry.ts -- GitLab From ae4472e2114d55cdbb0d6451d89e26401b989471 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Tue, 6 Jun 2017 12:48:30 +0200 Subject: [PATCH 0667/1347] Debt: Move viewlet views to views package --- src/vs/workbench/browser/viewlet.ts | 337 +---------------- .../parts/debug/browser/debugViewRegistry.ts | 2 +- .../parts/debug/browser/debugViewlet.ts | 3 +- .../debug/electron-browser/debugViews.ts | 3 +- .../parts/files/browser/explorerViewlet.ts | 3 +- .../parts/files/browser/views/explorerView.ts | 3 +- .../files/browser/views/openEditorsView.ts | 2 +- .../workbench/parts/views/browser/treeView.ts | 2 +- src/vs/workbench/parts/views/browser/views.ts | 344 ++++++++++++++++++ .../parts/views/browser/viewsRegistry.ts | 2 +- 10 files changed, 358 insertions(+), 343 deletions(-) create mode 100644 src/vs/workbench/parts/views/browser/views.ts diff --git a/src/vs/workbench/browser/viewlet.ts b/src/vs/workbench/browser/viewlet.ts index 5f153eee59c..d4638f10439 100644 --- a/src/vs/workbench/browser/viewlet.ts +++ b/src/vs/workbench/browser/viewlet.ts @@ -8,23 +8,13 @@ import { TPromise } from 'vs/base/common/winjs.base'; import DOM = require('vs/base/browser/dom'); import errors = require('vs/base/common/errors'); import { Registry } from 'vs/platform/platform'; -import { Dimension, Builder, $ } from 'vs/base/browser/builder'; -import { IAction, IActionRunner, Action } from 'vs/base/common/actions'; -import { IActionItem, ActionsOrientation } from 'vs/base/browser/ui/actionbar/actionbar'; +import { Dimension, Builder } from 'vs/base/browser/builder'; +import { Action } from 'vs/base/common/actions'; import { ITree, IFocusEvent, ISelectionEvent } from 'vs/base/parts/tree/browser/tree'; -import { prepareActions } from 'vs/workbench/browser/actions'; -import { ToolBar } from 'vs/base/browser/ui/toolbar/toolbar'; -import { DelayedDragHandler } from 'vs/base/browser/dnd'; -import { dispose, IDisposable } from 'vs/base/common/lifecycle'; -import { CollapsibleView, CollapsibleState, FixedCollapsibleView, IView } from 'vs/base/browser/ui/splitview/splitview'; import { IViewletService } from 'vs/workbench/services/viewlet/browser/viewlet'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; import { IViewlet } from 'vs/workbench/common/viewlet'; import { Composite, CompositeDescriptor, CompositeRegistry } from 'vs/workbench/browser/composite'; -import { IContextMenuService } from 'vs/platform/contextview/browser/contextView'; -import { IMessageService } from 'vs/platform/message/common/message'; -import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; -import { IThemable } from 'vs/platform/theme/common/styler'; export abstract class Viewlet extends Composite implements IViewlet { @@ -287,327 +277,4 @@ export class CollapseAction extends Action { return TPromise.as(null); }); } -} - -export interface IViewletView extends IView, IThemable { - id?: string; - create(): TPromise; - setVisible(visible: boolean): TPromise; - getActions(): IAction[]; - getSecondaryActions(): IAction[]; - getActionItem(action: IAction): IActionItem; - showHeader(): boolean; - hideHeader(): boolean; - shutdown(): void; - focusBody(): void; - isExpanded(): boolean; - expand(): void; - collapse(): void; -} - -/** - * The AdaptiveCollapsibleViewletView can grow with the content inside dynamically. - */ -export abstract class AdaptiveCollapsibleViewletView extends FixedCollapsibleView implements IViewletView { - protected treeContainer: HTMLElement; - protected tree: ITree; - protected toDispose: IDisposable[]; - protected isVisible: boolean; - protected toolBar: ToolBar; - protected actionRunner: IActionRunner; - protected isDisposed: boolean; - - private dragHandler: DelayedDragHandler; - - constructor( - actionRunner: IActionRunner, - initialBodySize: number, - collapsed: boolean, - private viewName: string, - protected keybindingService: IKeybindingService, - protected contextMenuService: IContextMenuService - ) { - super({ - expandedBodySize: initialBodySize, - initialState: collapsed ? CollapsibleState.COLLAPSED : CollapsibleState.EXPANDED, - ariaHeaderLabel: viewName, - headerSize: 22, - }); - - this.actionRunner = actionRunner; - this.toDispose = []; - } - - protected changeState(state: CollapsibleState): void { - updateTreeVisibility(this.tree, state === CollapsibleState.EXPANDED); - - super.changeState(state); - } - - public create(): TPromise { - return TPromise.as(null); - } - - public renderHeader(container: HTMLElement): void { - - // Tool bar - this.toolBar = new ToolBar($('div.actions').appendTo(container).getHTMLElement(), this.contextMenuService, { - orientation: ActionsOrientation.HORIZONTAL, - actionItemProvider: (action) => this.getActionItem(action), - ariaLabel: nls.localize('viewToolbarAriaLabel', "{0} actions", this.viewName), - getKeyBinding: (action) => this.keybindingService.lookupKeybinding(action.id) - }); - this.toolBar.actionRunner = this.actionRunner; - this.updateActions(); - - // Expand on drag over - this.dragHandler = new DelayedDragHandler(container, () => { - if (!this.isExpanded()) { - this.expand(); - } - }); - } - - protected updateActions(): void { - this.toolBar.setActions(prepareActions(this.getActions()), prepareActions(this.getSecondaryActions()))(); - } - - protected renderViewTree(container: HTMLElement): HTMLElement { - return renderViewTree(container); - } - - public getViewer(): ITree { - return this.tree; - } - - public setVisible(visible: boolean): TPromise { - this.isVisible = visible; - - updateTreeVisibility(this.tree, visible && this.state === CollapsibleState.EXPANDED); - - return TPromise.as(null); - } - - public focusBody(): void { - focus(this.tree); - } - - protected reveal(element: any, relativeTop?: number): TPromise { - return reveal(this.tree, element, relativeTop); - } - - protected layoutBody(size: number): void { - this.treeContainer.style.height = size + 'px'; - this.tree.layout(size); - } - - public getActions(): IAction[] { - return []; - } - - public getSecondaryActions(): IAction[] { - return []; - } - - public getActionItem(action: IAction): IActionItem { - return null; - } - - public shutdown(): void { - // Subclass to implement - } - - public dispose(): void { - this.isDisposed = true; - this.treeContainer = null; - this.tree.dispose(); - - this.dragHandler.dispose(); - - this.toDispose = dispose(this.toDispose); - - if (this.toolBar) { - this.toolBar.dispose(); - } - - super.dispose(); - } -} - -export abstract class CollapsibleViewletView extends CollapsibleView implements IViewletView { - protected treeContainer: HTMLElement; - protected tree: ITree; - protected toDispose: IDisposable[]; - protected isVisible: boolean; - protected toolBar: ToolBar; - protected actionRunner: IActionRunner; - protected isDisposed: boolean; - - private dragHandler: DelayedDragHandler; - - constructor( - actionRunner: IActionRunner, - collapsed: boolean, - private viewName: string, - protected messageService: IMessageService, - protected keybindingService: IKeybindingService, - protected contextMenuService: IContextMenuService, - headerSize?: number, - minimumSize?: number - ) { - super({ - minimumSize: minimumSize === void 0 ? 5 * 22 : minimumSize, - initialState: collapsed ? CollapsibleState.COLLAPSED : CollapsibleState.EXPANDED, - ariaHeaderLabel: viewName, - headerSize - }); - - this.actionRunner = actionRunner; - this.toDispose = []; - } - - protected changeState(state: CollapsibleState): void { - updateTreeVisibility(this.tree, state === CollapsibleState.EXPANDED); - - super.changeState(state); - } - - public create(): TPromise { - return TPromise.as(null); - } - - public renderHeader(container: HTMLElement): void { - - // Tool bar - this.toolBar = new ToolBar($('div.actions').appendTo(container).getHTMLElement(), this.contextMenuService, { - orientation: ActionsOrientation.HORIZONTAL, - actionItemProvider: (action) => this.getActionItem(action), - ariaLabel: nls.localize('viewToolbarAriaLabel', "{0} actions", this.viewName), - getKeyBinding: (action) => this.keybindingService.lookupKeybinding(action.id) - }); - this.toolBar.actionRunner = this.actionRunner; - this.updateActions(); - - // Expand on drag over - this.dragHandler = new DelayedDragHandler(container, () => { - if (!this.isExpanded()) { - this.expand(); - } - }); - } - - protected updateActions(): void { - this.toolBar.setActions(prepareActions(this.getActions()), prepareActions(this.getSecondaryActions()))(); - } - - protected renderViewTree(container: HTMLElement): HTMLElement { - return renderViewTree(container); - } - - public getViewer(): ITree { - return this.tree; - } - - public setVisible(visible: boolean): TPromise { - this.isVisible = visible; - - updateTreeVisibility(this.tree, visible && this.state === CollapsibleState.EXPANDED); - - return TPromise.as(null); - } - - public focusBody(): void { - focus(this.tree); - } - - protected reveal(element: any, relativeTop?: number): TPromise { - return reveal(this.tree, element, relativeTop); - } - - public layoutBody(size: number): void { - this.treeContainer.style.height = size + 'px'; - this.tree.layout(size); - } - - public getActions(): IAction[] { - return []; - } - - public getSecondaryActions(): IAction[] { - return []; - } - - public getActionItem(action: IAction): IActionItem { - return null; - } - - public shutdown(): void { - // Subclass to implement - } - - public dispose(): void { - this.isDisposed = true; - this.treeContainer = null; - this.tree.dispose(); - - if (this.dragHandler) { - this.dragHandler.dispose(); - } - - this.toDispose = dispose(this.toDispose); - - if (this.toolBar) { - this.toolBar.dispose(); - } - - super.dispose(); - } -} - -function renderViewTree(container: HTMLElement): HTMLElement { - const treeContainer = document.createElement('div'); - container.appendChild(treeContainer); - - return treeContainer; -} - -function updateTreeVisibility(tree: ITree, isVisible: boolean): void { - if (!tree) { - return; - } - - if (isVisible) { - $(tree.getHTMLElement()).show(); - } else { - $(tree.getHTMLElement()).hide(); // make sure the tree goes out of the tabindex world by hiding it - } - - if (isVisible) { - tree.onVisible(); - } else { - tree.onHidden(); - } -} - -function focus(tree: ITree): void { - if (!tree) { - return; // return early if viewlet has not yet been created - } - - // Make sure the current selected element is revealed - const selection = tree.getSelection(); - if (selection.length > 0) { - reveal(tree, selection[0], 0.5).done(null, errors.onUnexpectedError); - } - - // Pass Focus to Viewer - tree.DOMFocus(); -} - -function reveal(tree: ITree, element: any, relativeTop?: number): TPromise { - if (!tree) { - return TPromise.as(null); // return early if viewlet has not yet been created - } - - return tree.reveal(element, relativeTop); } \ No newline at end of file diff --git a/src/vs/workbench/parts/debug/browser/debugViewRegistry.ts b/src/vs/workbench/parts/debug/browser/debugViewRegistry.ts index 0a2ae209760..6aea43a7635 100644 --- a/src/vs/workbench/parts/debug/browser/debugViewRegistry.ts +++ b/src/vs/workbench/parts/debug/browser/debugViewRegistry.ts @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ import { IActionRunner } from 'vs/base/common/actions'; -import { IViewletView } from 'vs/workbench/browser/viewlet'; +import { IViewletView } from 'vs/workbench/parts/views/browser/views'; // Debug view registration diff --git a/src/vs/workbench/parts/debug/browser/debugViewlet.ts b/src/vs/workbench/parts/debug/browser/debugViewlet.ts index 07d674a0d16..df7e198e7b7 100644 --- a/src/vs/workbench/parts/debug/browser/debugViewlet.ts +++ b/src/vs/workbench/parts/debug/browser/debugViewlet.ts @@ -12,7 +12,8 @@ import { IActionItem } from 'vs/base/browser/ui/actionbar/actionbar'; import { SplitView, HeaderView } from 'vs/base/browser/ui/splitview/splitview'; import { ILifecycleService } from 'vs/platform/lifecycle/common/lifecycle'; import { Scope } from 'vs/workbench/common/memento'; -import { IViewletView, Viewlet } from 'vs/workbench/browser/viewlet'; +import { Viewlet } from 'vs/workbench/browser/viewlet'; +import { IViewletView } from 'vs/workbench/parts/views/browser/views'; import { IDebugService, VIEWLET_ID, State } from 'vs/workbench/parts/debug/common/debug'; import { DebugViewRegistry } from 'vs/workbench/parts/debug/browser/debugViewRegistry'; import { StartAction, ToggleReplAction, ConfigureAction } from 'vs/workbench/parts/debug/browser/debugActions'; diff --git a/src/vs/workbench/parts/debug/electron-browser/debugViews.ts b/src/vs/workbench/parts/debug/electron-browser/debugViews.ts index d13d9f8cd11..6bb133269d5 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugViews.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugViews.ts @@ -16,7 +16,8 @@ import { prepareActions } from 'vs/workbench/browser/actions'; import { IHighlightEvent, ITree } from 'vs/base/parts/tree/browser/tree'; import { Tree } from 'vs/base/parts/tree/browser/treeImpl'; import { CollapsibleState } from 'vs/base/browser/ui/splitview/splitview'; -import { CollapsibleViewletView, AdaptiveCollapsibleViewletView, CollapseAction } from 'vs/workbench/browser/viewlet'; +import { CollapseAction } from 'vs/workbench/browser/viewlet'; +import { CollapsibleViewletView, AdaptiveCollapsibleViewletView } from 'vs/workbench/parts/views/browser/views'; import { IDebugService, State, IBreakpoint, IExpression, CONTEXT_BREAKPOINTS_FOCUSED, CONTEXT_WATCH_EXPRESSIONS_FOCUSED, CONTEXT_VARIABLES_FOCUSED } from 'vs/workbench/parts/debug/common/debug'; import { Expression, Variable, ExceptionBreakpoint, FunctionBreakpoint, Thread, StackFrame, Breakpoint, ThreadAndProcessIds } from 'vs/workbench/parts/debug/common/debugModel'; import * as viewer from 'vs/workbench/parts/debug/electron-browser/debugViewer'; diff --git a/src/vs/workbench/parts/files/browser/explorerViewlet.ts b/src/vs/workbench/parts/files/browser/explorerViewlet.ts index 38ae653e119..53897c152d6 100644 --- a/src/vs/workbench/parts/files/browser/explorerViewlet.ts +++ b/src/vs/workbench/parts/files/browser/explorerViewlet.ts @@ -12,7 +12,8 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { Dimension, Builder } from 'vs/base/browser/builder'; import { Scope } from 'vs/workbench/common/memento'; import { VIEWLET_ID, ExplorerViewletVisibleContext, IFilesConfiguration } from 'vs/workbench/parts/files/common/files'; -import { IViewletView, Viewlet } from 'vs/workbench/browser/viewlet'; +import { Viewlet } from 'vs/workbench/browser/viewlet'; +import { IViewletView } from 'vs/workbench/parts/views/browser/views'; import { SplitView } from 'vs/base/browser/ui/splitview/splitview'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { ActionRunner, FileViewletState } from 'vs/workbench/parts/files/browser/views/explorerViewer'; diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index c16abfd280a..119a886d91e 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -24,7 +24,8 @@ import { toResource } from 'vs/workbench/common/editor'; import { DiffEditorInput } from 'vs/workbench/common/editor/diffEditorInput'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import * as DOM from 'vs/base/browser/dom'; -import { CollapseAction, CollapsibleViewletView } from 'vs/workbench/browser/viewlet'; +import { CollapseAction } from 'vs/workbench/browser/viewlet'; +import { CollapsibleViewletView } from 'vs/workbench/parts/views/browser/views'; import { FileStat } from 'vs/workbench/parts/files/common/explorerViewModel'; import { IListService } from 'vs/platform/list/browser/listService'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; diff --git a/src/vs/workbench/parts/files/browser/views/openEditorsView.ts b/src/vs/workbench/parts/files/browser/views/openEditorsView.ts index 3af3b297057..48d12b9f952 100644 --- a/src/vs/workbench/parts/files/browser/views/openEditorsView.ts +++ b/src/vs/workbench/parts/files/browser/views/openEditorsView.ts @@ -19,7 +19,7 @@ import { IConfigurationService } from 'vs/platform/configuration/common/configur import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { IEditorStacksModel, IStacksModelChangeEvent, IEditorGroup } from 'vs/workbench/common/editor'; import { SaveAllAction } from 'vs/workbench/parts/files/browser/fileActions'; -import { AdaptiveCollapsibleViewletView } from 'vs/workbench/browser/viewlet'; +import { AdaptiveCollapsibleViewletView } from 'vs/workbench/parts/views/browser/views'; import { IFilesConfiguration, VIEWLET_ID, OpenEditorsFocussedContext, ExplorerFocussedContext } from 'vs/workbench/parts/files/common/files'; import { ITextFileService, AutoSaveMode } from 'vs/workbench/services/textfile/common/textfiles'; import { IViewletService } from 'vs/workbench/services/viewlet/browser/viewlet'; diff --git a/src/vs/workbench/parts/views/browser/treeView.ts b/src/vs/workbench/parts/views/browser/treeView.ts index 3fe6cf31d13..789a66389d7 100644 --- a/src/vs/workbench/parts/views/browser/treeView.ts +++ b/src/vs/workbench/parts/views/browser/treeView.ts @@ -6,7 +6,7 @@ import 'vs/css!./media/views'; import Event, { Emitter } from 'vs/base/common/event'; import { IDisposable, dispose, empty as EmptyDisposable, toDisposable } from 'vs/base/common/lifecycle'; -import { CollapsibleViewletView } from 'vs/workbench/browser/viewlet'; +import { CollapsibleViewletView } from 'vs/workbench/parts/views/browser/views'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { TPromise } from 'vs/base/common/winjs.base'; import * as DOM from 'vs/base/browser/dom'; diff --git a/src/vs/workbench/parts/views/browser/views.ts b/src/vs/workbench/parts/views/browser/views.ts new file mode 100644 index 00000000000..35453f2b06a --- /dev/null +++ b/src/vs/workbench/parts/views/browser/views.ts @@ -0,0 +1,344 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as nls from 'vs/nls'; +import { TPromise } from 'vs/base/common/winjs.base'; +import { IThemable } from 'vs/platform/theme/common/styler'; +import * as errors from 'vs/base/common/errors'; +import { $ } from 'vs/base/browser/builder'; +import { dispose, IDisposable } from 'vs/base/common/lifecycle'; +import { IAction, IActionRunner } from 'vs/base/common/actions'; +import { IActionItem, ActionsOrientation } from 'vs/base/browser/ui/actionbar/actionbar'; +import { prepareActions } from 'vs/workbench/browser/actions'; +import { ITree } from 'vs/base/parts/tree/browser/tree'; +import { DelayedDragHandler } from 'vs/base/browser/dnd'; +import { ToolBar } from 'vs/base/browser/ui/toolbar/toolbar'; +import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; +import { IContextMenuService } from 'vs/platform/contextview/browser/contextView'; +import { IMessageService } from 'vs/platform/message/common/message'; +import { CollapsibleView, CollapsibleState, FixedCollapsibleView, IView } from 'vs/base/browser/ui/splitview/splitview'; + +export interface IViewletView extends IView, IThemable { + id?: string; + create(): TPromise; + setVisible(visible: boolean): TPromise; + getActions(): IAction[]; + getSecondaryActions(): IAction[]; + getActionItem(action: IAction): IActionItem; + showHeader(): boolean; + hideHeader(): boolean; + shutdown(): void; + focusBody(): void; + isExpanded(): boolean; + expand(): void; + collapse(): void; +} + +/** + * The AdaptiveCollapsibleViewletView can grow with the content inside dynamically. + */ +export abstract class AdaptiveCollapsibleViewletView extends FixedCollapsibleView implements IViewletView { + protected treeContainer: HTMLElement; + protected tree: ITree; + protected toDispose: IDisposable[]; + protected isVisible: boolean; + protected toolBar: ToolBar; + protected actionRunner: IActionRunner; + protected isDisposed: boolean; + + private dragHandler: DelayedDragHandler; + + constructor( + actionRunner: IActionRunner, + initialBodySize: number, + collapsed: boolean, + private viewName: string, + protected keybindingService: IKeybindingService, + protected contextMenuService: IContextMenuService + ) { + super({ + expandedBodySize: initialBodySize, + initialState: collapsed ? CollapsibleState.COLLAPSED : CollapsibleState.EXPANDED, + ariaHeaderLabel: viewName, + headerSize: 22, + }); + + this.actionRunner = actionRunner; + this.toDispose = []; + } + + protected changeState(state: CollapsibleState): void { + updateTreeVisibility(this.tree, state === CollapsibleState.EXPANDED); + + super.changeState(state); + } + + public create(): TPromise { + return TPromise.as(null); + } + + public renderHeader(container: HTMLElement): void { + + // Tool bar + this.toolBar = new ToolBar($('div.actions').appendTo(container).getHTMLElement(), this.contextMenuService, { + orientation: ActionsOrientation.HORIZONTAL, + actionItemProvider: (action) => this.getActionItem(action), + ariaLabel: nls.localize('viewToolbarAriaLabel', "{0} actions", this.viewName), + getKeyBinding: (action) => this.keybindingService.lookupKeybinding(action.id) + }); + this.toolBar.actionRunner = this.actionRunner; + this.updateActions(); + + // Expand on drag over + this.dragHandler = new DelayedDragHandler(container, () => { + if (!this.isExpanded()) { + this.expand(); + } + }); + } + + protected updateActions(): void { + this.toolBar.setActions(prepareActions(this.getActions()), prepareActions(this.getSecondaryActions()))(); + } + + protected renderViewTree(container: HTMLElement): HTMLElement { + return renderViewTree(container); + } + + public getViewer(): ITree { + return this.tree; + } + + public setVisible(visible: boolean): TPromise { + this.isVisible = visible; + + updateTreeVisibility(this.tree, visible && this.state === CollapsibleState.EXPANDED); + + return TPromise.as(null); + } + + public focusBody(): void { + focus(this.tree); + } + + protected reveal(element: any, relativeTop?: number): TPromise { + return reveal(this.tree, element, relativeTop); + } + + protected layoutBody(size: number): void { + this.treeContainer.style.height = size + 'px'; + this.tree.layout(size); + } + + public getActions(): IAction[] { + return []; + } + + public getSecondaryActions(): IAction[] { + return []; + } + + public getActionItem(action: IAction): IActionItem { + return null; + } + + public shutdown(): void { + // Subclass to implement + } + + public dispose(): void { + this.isDisposed = true; + this.treeContainer = null; + this.tree.dispose(); + + this.dragHandler.dispose(); + + this.toDispose = dispose(this.toDispose); + + if (this.toolBar) { + this.toolBar.dispose(); + } + + super.dispose(); + } +} + +export abstract class CollapsibleViewletView extends CollapsibleView implements IViewletView { + protected treeContainer: HTMLElement; + protected tree: ITree; + protected toDispose: IDisposable[]; + protected isVisible: boolean; + protected toolBar: ToolBar; + protected actionRunner: IActionRunner; + protected isDisposed: boolean; + + private dragHandler: DelayedDragHandler; + + constructor( + actionRunner: IActionRunner, + collapsed: boolean, + private viewName: string, + protected messageService: IMessageService, + protected keybindingService: IKeybindingService, + protected contextMenuService: IContextMenuService, + headerSize?: number, + minimumSize?: number + ) { + super({ + minimumSize: minimumSize === void 0 ? 5 * 22 : minimumSize, + initialState: collapsed ? CollapsibleState.COLLAPSED : CollapsibleState.EXPANDED, + ariaHeaderLabel: viewName, + headerSize + }); + + this.actionRunner = actionRunner; + this.toDispose = []; + } + + protected changeState(state: CollapsibleState): void { + updateTreeVisibility(this.tree, state === CollapsibleState.EXPANDED); + + super.changeState(state); + } + + public create(): TPromise { + return TPromise.as(null); + } + + public renderHeader(container: HTMLElement): void { + + // Tool bar + this.toolBar = new ToolBar($('div.actions').appendTo(container).getHTMLElement(), this.contextMenuService, { + orientation: ActionsOrientation.HORIZONTAL, + actionItemProvider: (action) => this.getActionItem(action), + ariaLabel: nls.localize('viewToolbarAriaLabel', "{0} actions", this.viewName), + getKeyBinding: (action) => this.keybindingService.lookupKeybinding(action.id) + }); + this.toolBar.actionRunner = this.actionRunner; + this.updateActions(); + + // Expand on drag over + this.dragHandler = new DelayedDragHandler(container, () => { + if (!this.isExpanded()) { + this.expand(); + } + }); + } + + protected updateActions(): void { + this.toolBar.setActions(prepareActions(this.getActions()), prepareActions(this.getSecondaryActions()))(); + } + + protected renderViewTree(container: HTMLElement): HTMLElement { + return renderViewTree(container); + } + + public getViewer(): ITree { + return this.tree; + } + + public setVisible(visible: boolean): TPromise { + this.isVisible = visible; + + updateTreeVisibility(this.tree, visible && this.state === CollapsibleState.EXPANDED); + + return TPromise.as(null); + } + + public focusBody(): void { + focus(this.tree); + } + + protected reveal(element: any, relativeTop?: number): TPromise { + return reveal(this.tree, element, relativeTop); + } + + public layoutBody(size: number): void { + this.treeContainer.style.height = size + 'px'; + this.tree.layout(size); + } + + public getActions(): IAction[] { + return []; + } + + public getSecondaryActions(): IAction[] { + return []; + } + + public getActionItem(action: IAction): IActionItem { + return null; + } + + public shutdown(): void { + // Subclass to implement + } + + public dispose(): void { + this.isDisposed = true; + this.treeContainer = null; + this.tree.dispose(); + + if (this.dragHandler) { + this.dragHandler.dispose(); + } + + this.toDispose = dispose(this.toDispose); + + if (this.toolBar) { + this.toolBar.dispose(); + } + + super.dispose(); + } +} + +function updateTreeVisibility(tree: ITree, isVisible: boolean): void { + if (!tree) { + return; + } + + if (isVisible) { + $(tree.getHTMLElement()).show(); + } else { + $(tree.getHTMLElement()).hide(); // make sure the tree goes out of the tabindex world by hiding it + } + + if (isVisible) { + tree.onVisible(); + } else { + tree.onHidden(); + } +} + +function focus(tree: ITree): void { + if (!tree) { + return; // return early if viewlet has not yet been created + } + + // Make sure the current selected element is revealed + const selection = tree.getSelection(); + if (selection.length > 0) { + reveal(tree, selection[0], 0.5).done(null, errors.onUnexpectedError); + } + + // Pass Focus to Viewer + tree.DOMFocus(); +} + +function renderViewTree(container: HTMLElement): HTMLElement { + const treeContainer = document.createElement('div'); + container.appendChild(treeContainer); + + return treeContainer; +} + +function reveal(tree: ITree, element: any, relativeTop?: number): TPromise { + if (!tree) { + return TPromise.as(null); // return early if viewlet has not yet been created + } + + return tree.reveal(element, relativeTop); +} \ No newline at end of file diff --git a/src/vs/workbench/parts/views/browser/viewsRegistry.ts b/src/vs/workbench/parts/views/browser/viewsRegistry.ts index 7aa26d2466b..a335db36aad 100644 --- a/src/vs/workbench/parts/views/browser/viewsRegistry.ts +++ b/src/vs/workbench/parts/views/browser/viewsRegistry.ts @@ -5,7 +5,7 @@ import Event, { Emitter } from 'vs/base/common/event'; import { IActionRunner } from 'vs/base/common/actions'; -import { IViewletView as IView } from 'vs/workbench/browser/viewlet'; +import { IViewletView as IView } from 'vs/workbench/parts/views/browser/views'; import { ITreeViewDataProvider } from 'vs/workbench/parts/views/common/views'; export class ViewLocation { -- GitLab From 3ef002b0d569d1bc8962842e49ec0cd624ba3341 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Tue, 6 Jun 2017 22:21:22 +0200 Subject: [PATCH 0668/1347] Debt: Composed views viewlet - Implement a viewlet composed of views - Adopt Explorer viewlet to extend Composed views viewlet --- .../parts/files/browser/explorerViewlet.ts | 400 +++++------------- .../parts/files/browser/views/emptyView.ts | 28 +- .../parts/files/browser/views/explorerView.ts | 17 +- .../files/browser/views/openEditorsView.ts | 20 +- src/vs/workbench/parts/views/browser/views.ts | 218 +++++++++- .../parts/views/browser/viewsRegistry.ts | 15 + 6 files changed, 357 insertions(+), 341 deletions(-) diff --git a/src/vs/workbench/parts/files/browser/explorerViewlet.ts b/src/vs/workbench/parts/files/browser/explorerViewlet.ts index 53897c152d6..1e97d5703b5 100644 --- a/src/vs/workbench/parts/files/browser/explorerViewlet.ts +++ b/src/vs/workbench/parts/files/browser/explorerViewlet.ts @@ -6,21 +6,19 @@ 'use strict'; import 'vs/css!./media/explorerviewlet'; -import { IDisposable, dispose } from 'vs/base/common/lifecycle'; -import { IAction, IActionRunner } from 'vs/base/common/actions'; +import { IActionRunner } from 'vs/base/common/actions'; import { TPromise } from 'vs/base/common/winjs.base'; -import { Dimension, Builder } from 'vs/base/browser/builder'; +import * as DOM from 'vs/base/browser/dom'; +import { Builder } from 'vs/base/browser/builder'; import { Scope } from 'vs/workbench/common/memento'; import { VIEWLET_ID, ExplorerViewletVisibleContext, IFilesConfiguration } from 'vs/workbench/parts/files/common/files'; -import { Viewlet } from 'vs/workbench/browser/viewlet'; -import { IViewletView } from 'vs/workbench/parts/views/browser/views'; -import { SplitView } from 'vs/base/browser/ui/splitview/splitview'; +import { ComposedViewsViewlet, IViewletView } from 'vs/workbench/parts/views/browser/views'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { ActionRunner, FileViewletState } from 'vs/workbench/parts/files/browser/views/explorerViewer'; -import { ExplorerView } from 'vs/workbench/parts/files/browser/views/explorerView'; +import { ExplorerView, IExplorerViewOptions } from 'vs/workbench/parts/files/browser/views/explorerView'; import { EmptyView } from 'vs/workbench/parts/files/browser/views/emptyView'; import { OpenEditorsView } from 'vs/workbench/parts/files/browser/views/openEditorsView'; -import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage'; +import { IStorageService } from 'vs/platform/storage/common/storage'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; @@ -32,233 +30,105 @@ import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/edi import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { IContextKeyService, IContextKey } from 'vs/platform/contextkey/common/contextkey'; import { IThemeService } from 'vs/platform/theme/common/themeService'; -import { attachHeaderViewStyler } from 'vs/platform/theme/common/styler'; -import { ViewsRegistry, ViewLocation, IViewDescriptor } from 'vs/workbench/parts/views/browser/viewsRegistry'; +import { ViewsRegistry, ViewLocation, IViewDescriptor, IViewOptions } from 'vs/workbench/parts/views/browser/viewsRegistry'; -interface IViewState { - collapsed: boolean; - size: number; -} - -export class ExplorerViewlet extends Viewlet { +export class ExplorerViewlet extends ComposedViewsViewlet { private static EXPLORER_VIEWS_STATE = 'workbench.explorer.views.state'; - private viewletContainer: Builder; - private splitView: SplitView; - private views: IViewletView[]; - - private explorerView: ExplorerView; - private openEditorsView: OpenEditorsView; - private emptyView: EmptyView; - - private openEditorsVisible: boolean; - private lastFocusedView: IViewletView; - private focusListener: IDisposable; - private delayEditorOpeningInOpenedEditors: boolean; - private viewletSettings: any; private viewletState: FileViewletState; - private dimension: Dimension; - private viewletVisibleContextKey: IContextKey; - private disposables: IDisposable[] = []; constructor( @ITelemetryService telemetryService: ITelemetryService, - @IWorkspaceContextService private contextService: IWorkspaceContextService, - @IStorageService private storageService: IStorageService, + @IWorkspaceContextService protected contextService: IWorkspaceContextService, + @IStorageService protected storageService: IStorageService, @IEditorGroupService private editorGroupService: IEditorGroupService, @IWorkbenchEditorService private editorService: IWorkbenchEditorService, @IConfigurationService private configurationService: IConfigurationService, - @IInstantiationService private instantiationService: IInstantiationService, + @IInstantiationService protected instantiationService: IInstantiationService, @IContextKeyService contextKeyService: IContextKeyService, @IThemeService themeService: IThemeService ) { - super(VIEWLET_ID, telemetryService, themeService); - - this.views = []; + super(VIEWLET_ID, ViewLocation.Explorer, ExplorerViewlet.EXPLORER_VIEWS_STATE, telemetryService, storageService, instantiationService, themeService, contextService); this.viewletState = new FileViewletState(); - this.viewletVisibleContextKey = ExplorerViewletVisibleContext.bindTo(contextKeyService); - this.viewletSettings = this.getMemento(storageService, Scope.WORKSPACE); + this.viewletVisibleContextKey = ExplorerViewletVisibleContext.bindTo(contextKeyService); - this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated(e.config), this, this.disposables); - ViewsRegistry.onViewsRegistered(viewDescriptors => this.addCustomViews(viewDescriptors.filter(viewDescriptor => ViewLocation.Explorer === viewDescriptor.location), true), this, this.disposables); + this.registerViews(); + this._register(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated())); } public create(parent: Builder): TPromise { - super.create(parent); - - this.viewletContainer = parent.div().addClass('explorer-viewlet'); - - return this.render(); - } - - public getActions(): IAction[] { - if (this.views.length === 1) { - return this.views[0].getActions(); - } - - return []; + return super.create(parent).then(() => DOM.addClass(this.viewletContainer, 'explorer-viewlet')); } - public getSecondaryActions(): IAction[] { - if (this.views.length === 1) { - return this.views[0].getSecondaryActions(); - } - - return []; - } - - private render(): TPromise { - const config = this.configurationService.getConfiguration(); - - // No need to delay if preview is disabled - this.delayEditorOpeningInOpenedEditors = !!config.workbench.editor.enablePreview; - - // Open editors view should always be visible in no folder workspace. - this.openEditorsVisible = !this.contextService.hasWorkspace() || config.explorer.openEditors.visible !== 0; - - this.views = []; - this.viewletContainer.clearChildren(); - - this.splitView = new SplitView(this.viewletContainer.getHTMLElement()); - - // Track focus - this.focusListener = this.splitView.onFocus((view: IViewletView) => { - this.lastFocusedView = view; - }); - - const customViews = ViewsRegistry.getViews(ViewLocation.Explorer); - - if (this.openEditorsVisible) { - // Open editors view - this.openEditorsView = this.instantiationService.createInstance(OpenEditorsView, this.getActionRunner(), this.viewletSettings); - this.views.push(this.openEditorsView); + private registerViews(): void { + let viewDescriptors = []; + if (this.isOpenEditorsVisible()) { + viewDescriptors.push(this.createOpenEditorsViewDescriptor()); } - - const viewsState = JSON.parse(this.storageService.get(ExplorerViewlet.EXPLORER_VIEWS_STATE, this.contextService.hasWorkspace() ? StorageScope.WORKSPACE : StorageScope.GLOBAL, '{}')); - - // Explorer view - this.views.push(this.createExplorerOrEmptyView(viewsState)); - - // custom views - for (const view of customViews) { - this.addCustomView(view, viewsState[view.id], -1); - } - - for (let i = 0; i < this.views.length; i++) { - const view = this.views[i]; - attachHeaderViewStyler(view, this.themeService, { noContrastBorder: i === 0 }); - this.splitView.addView(view, viewsState[view.id] ? (viewsState[view.id]).size : void 0); + if (this.contextService.hasWorkspace()) { + viewDescriptors.push(this.createExplorerViewDescriptor()); + } else { + viewDescriptors.push(this.createEmptyViewDescriptor()); } - this.lastFocusedView = this.explorerView; - - return TPromise.join(this.views.map(view => view.create())).then(() => void 0).then(() => { - this.onViewsUpdated(); - return this.setVisible(this.isVisible()).then(() => this.focus()); // Focus the viewlet since that triggers a rerender. - }); + ViewsRegistry.registerViews(viewDescriptors); } - private updateOpenEditorsView(): void { - if (!this.splitView) { - return; - } - - if (this.openEditorsVisible) { - this.openEditorsView = this.instantiationService.createInstance(OpenEditorsView, this.getActionRunner(), this.viewletSettings); - this.views.unshift(this.openEditorsView); - this.splitView.addView(this.openEditorsView, undefined, 0); - this.openEditorsView.create().then(() => { - if (this.views.length === 2) { - this.views[1].showHeader(); - } - if (this.dimension) { - this.layout(this.dimension); - } - // Update title area since the title actions have changed. - this.updateTitleArea(); - }); - } else { - this.views.shift(); - this.splitView.removeView(this.openEditorsView); - this.openEditorsView.dispose(); - this.openEditorsView = null; - this.onViewsUpdated(); - } + private createOpenEditorsViewDescriptor(): IViewDescriptor { + return { + id: OpenEditorsView.ID, + name: '', + location: ViewLocation.Explorer, + ctor: OpenEditorsView, + order: 0 + }; } - private addCustomViews(viewDescriptors: IViewDescriptor[], end: boolean): void { - if (!this.splitView || !viewDescriptors.length) { - return; - } - const views = []; - - const registered = ViewsRegistry.getViews(ViewLocation.Explorer); - const viewsState = JSON.parse(this.storageService.get(ExplorerViewlet.EXPLORER_VIEWS_STATE, this.contextService.hasWorkspace() ? StorageScope.WORKSPACE : StorageScope.GLOBAL, '{}')); - for (const viewDescriptor of viewDescriptors) { - let index = end ? -1 : this.openEditorsView ? registered.indexOf(viewDescriptor) + 2 : registered.indexOf(viewDescriptor) + 1; - const view = this.addCustomView(viewDescriptor, viewsState[viewDescriptor.id], index); - views.push(view); - attachHeaderViewStyler(view, this.themeService); - this.splitView.addView(view, viewsState[view.id] ? (viewsState[view.id]).size : void 0, end ? void 0 : index); - } - - TPromise.join(views.map(view => view.create())).then(() => void 0).then(() => { - this.onViewsUpdated(); - }); + private createEmptyViewDescriptor(): IViewDescriptor { + return { + id: EmptyView.ID, + name: '', + location: ViewLocation.Explorer, + ctor: EmptyView, + order: 1 + }; } - private addCustomView(viewDescriptor: IViewDescriptor, viewState: IViewState, index: number): IViewletView { - const view = this.instantiationService.createInstance(viewDescriptor.ctor, viewDescriptor.id, { - name: viewDescriptor.name, - actionRunner: this.getActionRunner(), - collapsed: viewState ? viewState.collapsed : true - }); - if (index !== -1) { - this.views.splice(index, 0, view); - } else { - this.views.push(view); - } - return view; + private createExplorerViewDescriptor(): IViewDescriptor { + return { + id: ExplorerView.ID, + name: '', + location: ViewLocation.Explorer, + ctor: ExplorerView, + order: 1 + }; } - private onViewsUpdated(): void { - if (this.views.length > 1) { - this.views[0].showHeader(); + private onConfigurationUpdated(): void { + let openEditorsViewDescriptor = ViewsRegistry.getViews(ViewLocation.Explorer).filter(viewDescriptor => viewDescriptor.id === OpenEditorsView.ID)[0]; + let isOpenEditorsVisible = this.isOpenEditorsVisible(); + if (isOpenEditorsVisible) { + if (!openEditorsViewDescriptor) { + ViewsRegistry.registerViews([this.createOpenEditorsViewDescriptor()]); + } } else { - this.views[0].hideHeader(); - if (!this.views[0].isExpanded()) { - this.views[0].expand(); + if (openEditorsViewDescriptor) { + ViewsRegistry.deregisterViews([OpenEditorsView.ID], ViewLocation.Explorer); } } - - if (this.dimension) { - this.layout(this.dimension); - } - - // Update title area since the title actions have changed. - this.updateTitleArea(); } - private onConfigurationUpdated(config: IFilesConfiguration): void { - // Open editors view should always be visible in no folder workspace. - const openEditorsVisible = !this.contextService.hasWorkspace() || config.explorer.openEditors.visible !== 0; - if (this.openEditorsVisible !== openEditorsVisible) { - this.openEditorsVisible = openEditorsVisible; - this.updateOpenEditorsView(); - } + private isOpenEditorsVisible(): boolean { + return !this.contextService.hasWorkspace() || (this.configurationService.getConfiguration()).explorer.openEditors.visible !== 0; } - private createExplorerOrEmptyView(viewsState: any): IViewletView { - let explorerOrEmptyView: ExplorerView | EmptyView; - - // With a Workspace - if (this.contextService.hasWorkspace()) { - + protected createView(viewDescriptor: IViewDescriptor, options: IViewOptions): IViewletView { + if (viewDescriptor.id === ExplorerView.ID) { // Create a delegating editor service for the explorer to be able to delay the refresh in the opened // editors view above. This is a workaround for being able to double click on a file to make it pinned // without causing the animation in the opened editors view to kick in and change scroll position. @@ -266,21 +136,28 @@ export class ExplorerViewlet extends Viewlet { // a new entry in the opened editors view. const delegatingEditorService = this.instantiationService.createInstance(DelegatingWorkbenchEditorService); delegatingEditorService.setEditorOpenHandler((input: EditorInput, options?: EditorOptions, arg3?: any) => { - if (this.openEditorsView) { + let openEditorsView = this.getOpenEditorsView(); + if (openEditorsView) { let delay = 0; - if (this.delayEditorOpeningInOpenedEditors && (arg3 === false /* not side by side */ || typeof arg3 !== 'number' /* no explicit position */)) { + + const config = this.configurationService.getConfiguration(); + // No need to delay if preview is disabled + const delayEditorOpeningInOpenedEditors = !!config.workbench.editor.enablePreview; + + if (delayEditorOpeningInOpenedEditors && (arg3 === false /* not side by side */ || typeof arg3 !== 'number' /* no explicit position */)) { const activeGroup = this.editorGroupService.getStacksModel().activeGroup; if (!activeGroup || !activeGroup.previewEditor) { delay = 250; // a new editor entry is likely because there is either no group or no preview in group } } - this.openEditorsView.setStructuralRefreshDelay(delay); + openEditorsView.setStructuralRefreshDelay(delay); } const onSuccessOrError = (editor?: BaseEditor) => { - if (this.openEditorsView) { - this.openEditorsView.setStructuralRefreshDelay(0); + let openEditorsView = this.getOpenEditorsView(); + if (openEditorsView) { + openEditorsView.setStructuralRefreshDelay(0); } return editor; @@ -290,74 +167,62 @@ export class ExplorerViewlet extends Viewlet { }); const explorerInstantiator = this.instantiationService.createChild(new ServiceCollection([IWorkbenchEditorService, delegatingEditorService])); - this.explorerView = explorerOrEmptyView = explorerInstantiator.createInstance(ExplorerView, this.viewletState, { - collapsed: viewsState[ExplorerView.ID] ? (viewsState[ExplorerView.ID]).collapsed : false, - actionRunner: this.getActionRunner() - }, this.viewletSettings, void 0); - } - - // No workspace - else { - this.emptyView = explorerOrEmptyView = this.instantiationService.createInstance(EmptyView, { - collapsed: viewsState[EmptyView.ID] ? (viewsState[EmptyView.ID]).collapsed : false, - actionRunner: this.getActionRunner() - }); + return explorerInstantiator.createInstance(ExplorerView, viewDescriptor.id, { ...options, settings: this.viewletSettings, viewletState: this.viewletState }); } - - return explorerOrEmptyView; + return super.createView(viewDescriptor, options); } public getExplorerView(): ExplorerView { - return this.explorerView; + return this.getView(ExplorerView.ID); } public getOpenEditorsView(): OpenEditorsView { - return this.openEditorsView; + return this.getView(OpenEditorsView.ID); + } + + public getEmptyView(): EmptyView { + return this.getView(EmptyView.ID); } public setVisible(visible: boolean): TPromise { this.viewletVisibleContextKey.set(visible); - - return super.setVisible(visible).then(() => { - return TPromise.join(this.views.map((view) => view.setVisible(visible))).then(() => void 0); - }); + return super.setVisible(visible); } public focus(): void { - super.focus(); - const hasOpenedEditors = !!this.editorGroupService.getStacksModel().activeGroup; + let openEditorsView = this.getOpenEditorsView(); if (this.lastFocusedView && this.lastFocusedView.isExpanded() && this.hasSelectionOrFocus(this.lastFocusedView)) { - if (this.lastFocusedView !== this.openEditorsView || hasOpenedEditors) { + if (this.lastFocusedView !== openEditorsView || hasOpenedEditors) { this.lastFocusedView.focusBody(); return; } } - if (this.hasSelectionOrFocus(this.openEditorsView) && hasOpenedEditors) { - return this.openEditorsView.focusBody(); + if (this.hasSelectionOrFocus(openEditorsView) && hasOpenedEditors) { + return openEditorsView.focusBody(); } - if (this.hasSelectionOrFocus(this.explorerView)) { - return this.explorerView.focusBody(); + let explorerView = this.getExplorerView(); + if (this.hasSelectionOrFocus(explorerView)) { + return explorerView.focusBody(); } - if (this.openEditorsView && this.openEditorsView.isExpanded() && hasOpenedEditors) { - return this.openEditorsView.focusBody(); // we have entries in the opened editors view to focus on + if (openEditorsView && openEditorsView.isExpanded() && hasOpenedEditors) { + return openEditorsView.focusBody(); // we have entries in the opened editors view to focus on } - if (this.explorerView && this.explorerView.isExpanded()) { - return this.explorerView.focusBody(); + if (explorerView && explorerView.isExpanded()) { + return explorerView.focusBody(); } - if (this.emptyView && this.emptyView.isExpanded()) { - return this.emptyView.focusBody(); + let emptyView = this.getEmptyView(); + if (emptyView && emptyView.isExpanded()) { + return emptyView.focusBody(); } - if (this.lastFocusedView) { - return this.lastFocusedView.focus(); - } + super.focus(); } private hasSelectionOrFocus(view: IViewletView): boolean { @@ -382,83 +247,14 @@ export class ExplorerViewlet extends Viewlet { return false; } - public layout(dimension: Dimension): void { - this.dimension = dimension; - this.splitView.layout(dimension.height); - } - public getActionRunner(): IActionRunner { if (!this.actionRunner) { this.actionRunner = new ActionRunner(this.viewletState); } - return this.actionRunner; } public getViewletState(): FileViewletState { return this.viewletState; } - - public getOptimalWidth(): number { - const additionalMargin = 16; - const openedEditorsViewWidth = this.openEditorsView ? this.openEditorsView.getOptimalWidth() : 0; - const explorerView = this.getExplorerView(); - const explorerViewWidth = explorerView ? explorerView.getOptimalWidth() : 0; - const optimalWidth = Math.max(openedEditorsViewWidth, explorerViewWidth); - - return optimalWidth + additionalMargin; - } - - public shutdown(): void { - this.saveViewsState(); - this.views.forEach((view) => view.shutdown()); - super.shutdown(); - } - - private saveViewsState(): void { - const viewletState = this.views.reduce((result, view) => { - result[view.id] = this.getViewState(view); - return result; - }, {}); - this.storageService.store(ExplorerViewlet.EXPLORER_VIEWS_STATE, JSON.stringify(viewletState), this.contextService.hasWorkspace() ? StorageScope.WORKSPACE : StorageScope.GLOBAL); - } - - private getViewState(view: IViewletView): IViewState { - return { - collapsed: !view.isExpanded(), - size: view.size > 0 ? view.size : void 0 - }; - } - - public dispose(): void { - - for (const view of this.views) { - view.dispose(); - } - - if (this.splitView) { - this.splitView = null; - } - - if (this.explorerView) { - this.explorerView = null; - } - - if (this.openEditorsView) { - this.openEditorsView = null; - } - - if (this.emptyView) { - this.emptyView = null; - } - - if (this.focusListener) { - this.focusListener.dispose(); - this.focusListener = null; - } - - this.disposables = dispose(this.disposables); - - super.dispose(); - } } \ No newline at end of file diff --git a/src/vs/workbench/parts/files/browser/views/emptyView.ts b/src/vs/workbench/parts/files/browser/views/emptyView.ts index 5a46c95e1a6..eb02a3b1087 100644 --- a/src/vs/workbench/parts/files/browser/views/emptyView.ts +++ b/src/vs/workbench/parts/files/browser/views/emptyView.ts @@ -9,36 +9,36 @@ import * as errors from 'vs/base/common/errors'; import env = require('vs/base/common/platform'); import DOM = require('vs/base/browser/dom'); import { TPromise } from 'vs/base/common/winjs.base'; -import { IActionRunner, IAction } from 'vs/base/common/actions'; +import { IAction } from 'vs/base/common/actions'; import { Button } from 'vs/base/browser/ui/button/button'; import { $ } from 'vs/base/browser/builder'; import { IActionItem } from 'vs/base/browser/ui/actionbar/actionbar'; -import { CollapsibleView, CollapsibleState } from 'vs/base/browser/ui/splitview/splitview'; +import { CollapsibleViewletView } from 'vs/workbench/parts/views/browser/views'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { OpenFolderAction, OpenFileFolderAction } from 'vs/workbench/browser/actions/fileActions'; import { attachButtonStyler } from 'vs/platform/theme/common/styler'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { IViewOptions } from 'vs/workbench/parts/views/browser/viewsRegistry'; +import { IMessageService } from 'vs/platform/message/common/message'; +import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; +import { IContextMenuService } from 'vs/platform/contextview/browser/contextView'; -export class EmptyView extends CollapsibleView { +export class EmptyView extends CollapsibleViewletView { public static ID: string = 'workbench.explorer.emptyView'; - public readonly id: string = EmptyView.ID; - private openFolderButton: Button; - private actionRunner: IActionRunner; + constructor( + readonly id: string, options: IViewOptions, @IThemeService private themeService: IThemeService, - @IInstantiationService private instantiationService: IInstantiationService + @IInstantiationService private instantiationService: IInstantiationService, + @IMessageService messageService: IMessageService, + @IKeybindingService keybindingService: IKeybindingService, + @IContextMenuService contextMenuService: IContextMenuService ) { - super({ - minimumSize: 5 * 22, - ariaHeaderLabel: nls.localize('explorerSection', "Files Explorer Section"), - initialState: options.collapsed ? CollapsibleState.COLLAPSED : CollapsibleState.EXPANDED - }); - this.actionRunner = options.actionRunner; + super(options.actionRunner, options.collapsed, nls.localize('explorerSection', "Files Explorer Section"), messageService, keybindingService, contextMenuService, void 0, 5 * 22); } public renderHeader(container: HTMLElement): void { @@ -69,7 +69,7 @@ export class EmptyView extends CollapsibleView { }); } - protected layoutBody(size: number): void { + layoutBody(size: number): void { // no-op } diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index 119a886d91e..80bd2369b64 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -45,6 +45,11 @@ import { IEnvironmentService } from 'vs/platform/environment/common/environment' import { attachListStyler } from 'vs/platform/theme/common/styler'; import { IViewOptions } from 'vs/workbench/parts/views/browser/viewsRegistry'; +export interface IExplorerViewOptions extends IViewOptions { + settings: any; + viewletState: FileViewletState; +} + export class ExplorerView extends CollapsibleViewletView { public static ID: string = 'workbench.explorer.fileView'; @@ -79,10 +84,8 @@ export class ExplorerView extends CollapsibleViewletView { private settings: any; constructor( - viewletState: FileViewletState, - options: IViewOptions, - settings: any, - headerSize: number, + id: string, + options: IExplorerViewOptions, @IMessageService messageService: IMessageService, @IContextMenuService contextMenuService: IContextMenuService, @IInstantiationService private instantiationService: IInstantiationService, @@ -99,10 +102,10 @@ export class ExplorerView extends CollapsibleViewletView { @IWorkbenchThemeService private themeService: IWorkbenchThemeService, @IEnvironmentService private environmentService: IEnvironmentService ) { - super(options.actionRunner, options.collapsed, nls.localize('explorerSection', "Files Explorer Section"), messageService, keybindingService, contextMenuService, headerSize); + super(options.actionRunner, options.collapsed, nls.localize('explorerSection', "Files Explorer Section"), messageService, keybindingService, contextMenuService); - this.settings = settings; - this.viewletState = viewletState; + this.settings = options.settings; + this.viewletState = options.viewletState; this.actionRunner = options.actionRunner; this.autoReveal = true; diff --git a/src/vs/workbench/parts/files/browser/views/openEditorsView.ts b/src/vs/workbench/parts/files/browser/views/openEditorsView.ts index 48d12b9f952..cc78b196c58 100644 --- a/src/vs/workbench/parts/files/browser/views/openEditorsView.ts +++ b/src/vs/workbench/parts/files/browser/views/openEditorsView.ts @@ -7,9 +7,8 @@ import nls = require('vs/nls'); import errors = require('vs/base/common/errors'); import { RunOnceScheduler } from 'vs/base/common/async'; import { TPromise } from 'vs/base/common/winjs.base'; -import { IAction, IActionRunner } from 'vs/base/common/actions'; +import { IAction } from 'vs/base/common/actions'; import dom = require('vs/base/browser/dom'); -import { CollapsibleState } from 'vs/base/browser/ui/splitview/splitview'; import { Tree } from 'vs/base/parts/tree/browser/treeImpl'; import { IItemCollapseEvent } from 'vs/base/parts/tree/browser/treeModel'; import { IContextMenuService } from 'vs/platform/contextview/browser/contextView'; @@ -34,18 +33,16 @@ import { EditorGroup } from 'vs/workbench/common/editor/editorStacksModel'; import { attachListStyler, attachStylerCallback } from 'vs/platform/theme/common/styler'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { badgeBackground, badgeForeground, contrastBorder } from 'vs/platform/theme/common/colorRegistry'; +import { IViewOptions } from 'vs/workbench/parts/views/browser/viewsRegistry'; const $ = dom.$; export class OpenEditorsView extends AdaptiveCollapsibleViewletView { - private static MEMENTO_COLLAPSED = 'openEditors.memento.collapsed'; private static DEFAULT_VISIBLE_OPEN_EDITORS = 9; private static DEFAULT_DYNAMIC_HEIGHT = true; + static ID = 'workbench.explorer.openEditorsView'; - readonly id: string = 'workbench.explorer.openEditorsView'; - - private settings: any; private visibleOpenEditors: number; private dynamicHeight: boolean; @@ -59,7 +56,7 @@ export class OpenEditorsView extends AdaptiveCollapsibleViewletView { private openEditorsFocussedContext: IContextKey; private explorerFocussedContext: IContextKey; - constructor(actionRunner: IActionRunner, settings: any, + constructor(readonly id: string, options: IViewOptions, @IInstantiationService private instantiationService: IInstantiationService, @IContextMenuService contextMenuService: IContextMenuService, @ITextFileService private textFileService: ITextFileService, @@ -72,9 +69,8 @@ export class OpenEditorsView extends AdaptiveCollapsibleViewletView { @IViewletService private viewletService: IViewletService, @IThemeService private themeService: IThemeService ) { - super(actionRunner, OpenEditorsView.computeExpandedBodySize(editorGroupService.getStacksModel()), !!settings[OpenEditorsView.MEMENTO_COLLAPSED], nls.localize({ key: 'openEditosrSection', comment: ['Open is an adjective'] }, "Open Editors Section"), keybindingService, contextMenuService); + super(options.actionRunner, OpenEditorsView.computeExpandedBodySize(editorGroupService.getStacksModel()), options.collapsed, nls.localize({ key: 'openEditosrSection', comment: ['Open is an adjective'] }, "Open Editors Section"), keybindingService, contextMenuService); - this.settings = settings; this.model = editorGroupService.getStacksModel(); this.openEditorsFocussedContext = OpenEditorsFocussedContext.bindTo(contextKeyService); @@ -326,10 +322,4 @@ export class OpenEditorsView extends AdaptiveCollapsibleViewletView { return dom.getLargestChildWidth(parentNode, childNodes); } - - public shutdown(): void { - this.settings[OpenEditorsView.MEMENTO_COLLAPSED] = (this.state === CollapsibleState.COLLAPSED); - - super.shutdown(); - } } diff --git a/src/vs/workbench/parts/views/browser/views.ts b/src/vs/workbench/parts/views/browser/views.ts index 35453f2b06a..179d898bc3d 100644 --- a/src/vs/workbench/parts/views/browser/views.ts +++ b/src/vs/workbench/parts/views/browser/views.ts @@ -5,20 +5,28 @@ import * as nls from 'vs/nls'; import { TPromise } from 'vs/base/common/winjs.base'; -import { IThemable } from 'vs/platform/theme/common/styler'; +import { IThemable, attachHeaderViewStyler } from 'vs/platform/theme/common/styler'; import * as errors from 'vs/base/common/errors'; -import { $ } from 'vs/base/browser/builder'; +import * as DOM from 'vs/base/browser/dom'; +import { $, Dimension, Builder } from 'vs/base/browser/builder'; import { dispose, IDisposable } from 'vs/base/common/lifecycle'; import { IAction, IActionRunner } from 'vs/base/common/actions'; import { IActionItem, ActionsOrientation } from 'vs/base/browser/ui/actionbar/actionbar'; import { prepareActions } from 'vs/workbench/browser/actions'; +import { Viewlet } from 'vs/workbench/browser/viewlet'; import { ITree } from 'vs/base/parts/tree/browser/tree'; import { DelayedDragHandler } from 'vs/base/browser/dnd'; import { ToolBar } from 'vs/base/browser/ui/toolbar/toolbar'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { IContextMenuService } from 'vs/platform/contextview/browser/contextView'; import { IMessageService } from 'vs/platform/message/common/message'; -import { CollapsibleView, CollapsibleState, FixedCollapsibleView, IView } from 'vs/base/browser/ui/splitview/splitview'; +import { CollapsibleView, CollapsibleState, FixedCollapsibleView, IView, SplitView } from 'vs/base/browser/ui/splitview/splitview'; +import { ViewsRegistry, ViewLocation, IViewDescriptor, IViewOptions } from 'vs/workbench/parts/views/browser/viewsRegistry'; +import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; +import { IThemeService } from 'vs/platform/theme/common/themeService'; +import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; +import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage'; +import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; export interface IViewletView extends IView, IThemable { id?: string; @@ -34,6 +42,7 @@ export interface IViewletView extends IView, IThemable { isExpanded(): boolean; expand(): void; collapse(): void; + getOptimalWidth(): number; } /** @@ -148,6 +157,10 @@ export abstract class AdaptiveCollapsibleViewletView extends FixedCollapsibleVie // Subclass to implement } + public getOptimalWidth(): number { + return 0; + } + public dispose(): void { this.isDisposed = true; this.treeContainer = null; @@ -276,6 +289,10 @@ export abstract class CollapsibleViewletView extends CollapsibleView implements // Subclass to implement } + public getOptimalWidth(): number { + return 0; + } + public dispose(): void { this.isDisposed = true; this.treeContainer = null; @@ -341,4 +358,199 @@ function reveal(tree: ITree, element: any, relativeTop?: number): TPromise } return tree.reveal(element, relativeTop); +} + +export interface IViewState { + collapsed: boolean; + size: number; +} + +export class ComposedViewsViewlet extends Viewlet { + + protected viewletContainer: HTMLElement; + protected lastFocusedView: IViewletView; + + private splitView: SplitView; + private views: IViewletView[]; + private dimension: Dimension; + + private readonly viewsStates: Map; + + constructor( + id: string, + private location: ViewLocation, + private viewletStateStorageId: string, + @ITelemetryService telemetryService: ITelemetryService, + @IStorageService protected storageService: IStorageService, + @IInstantiationService protected instantiationService: IInstantiationService, + @IThemeService themeService: IThemeService, + @IWorkspaceContextService protected contextService: IWorkspaceContextService + ) { + super(id, telemetryService, themeService); + + this.views = []; + this.viewsStates = this.loadViewsStates(); + + this._register(ViewsRegistry.onViewsRegistered(viewDescriptors => this.createViews(viewDescriptors.filter(viewDescriptor => ViewLocation.Explorer === viewDescriptor.location)))); + this._register(ViewsRegistry.onViewsDeregistered(viewDescriptors => this.removeViews(viewDescriptors.filter(viewDescriptor => ViewLocation.Explorer === viewDescriptor.location)))); + } + + public create(parent: Builder): TPromise { + super.create(parent); + + this.viewletContainer = DOM.append(parent.getHTMLElement(), DOM.$('')); + this.splitView = this._register(new SplitView(this.viewletContainer)); + this._register(this.splitView.onFocus((view: IViewletView) => this.lastFocusedView = view)); + + const views = ViewsRegistry.getViews(ViewLocation.Explorer); + return this.createViews(views) + .then(() => this.lastFocusedView = this.views[0]) + .then(() => this.setVisible(this.isVisible())) + .then(() => this.focus()); + } + + public getActions(): IAction[] { + if (this.views.length === 1) { + return this.views[0].getActions(); + } + return []; + } + + public getSecondaryActions(): IAction[] { + if (this.views.length === 1) { + return this.views[0].getSecondaryActions(); + } + return []; + } + + private createViews(viewDescriptors: IViewDescriptor[]): TPromise { + if (!this.splitView || !viewDescriptors.length) { + return TPromise.as(null); + } + + const views = []; + const sorted = ViewsRegistry.getViews(this.location).sort((a, b) => { + if (b.order === void 0 || b.order === null) { + return -1; + } + if (a.order === void 0 || a.order === null) { + return 1; + } + return a.order - b.order; + }); + for (const viewDescriptor of viewDescriptors) { + let viewState = this.viewsStates.get(viewDescriptor.id); + let index = sorted.indexOf(viewDescriptor); + const view = this.createView(viewDescriptor, { + name: viewDescriptor.name, + actionRunner: this.getActionRunner(), + collapsed: viewState ? viewState.collapsed : true + }); + if (index !== -1) { + this.views.splice(index, 0, view); + } else { + this.views.push(view); + } + views.push(view); + attachHeaderViewStyler(view, this.themeService); + this.splitView.addView(view, viewState ? viewState.size : void 0, index); + } + + return TPromise.join(views.map(view => view.create())) + .then(() => this.onViewsUpdated()); + } + + + private removeViews(viewDescriptors: IViewDescriptor[]): void { + if (!this.splitView || !viewDescriptors.length) { + return; + } + + for (const viewDescriptor of viewDescriptors) { + let view = this.getView(viewDescriptor.id); + if (view) { + this.views.splice(this.views.indexOf(view), 1); + this.splitView.removeView(view); + } + } + + this.onViewsUpdated(); + } + + private onViewsUpdated(): void { + if (this.views.length === 1) { + this.views[0].hideHeader(); + if (!this.views[0].isExpanded()) { + this.views[0].expand(); + } + } else { + for (const view of this.views) { + view.showHeader(); + } + } + + if (this.dimension) { + this.layout(this.dimension); + } + + // Update title area since the title actions have changed. + this.updateTitleArea(); + } + + public setVisible(visible: boolean): TPromise { + return super.setVisible(visible) + .then(() => TPromise.join(this.views.map((view) => view.setVisible(visible)))) + .then(() => void 0); + } + + public focus(): void { + super.focus(); + if (this.lastFocusedView) { + this.lastFocusedView.focus(); + } + } + + public layout(dimension: Dimension): void { + this.dimension = dimension; + this.splitView.layout(dimension.height); + } + + public getOptimalWidth(): number { + const additionalMargin = 16; + const optimalWidth = Math.max(...this.views.map(view => view.getOptimalWidth() || 0)); + return optimalWidth + additionalMargin; + } + + public shutdown(): void { + this.saveViewsStates(); + this.views.forEach((view) => view.shutdown()); + super.shutdown(); + } + + protected saveViewsStates(): void { + const viewletState = this.views.reduce((result, view) => { + result[view.id] = { + collapsed: !view.isExpanded(), + size: view.size > 0 ? view.size : void 0 + }; + return result; + }, {}); + this.storageService.store(this.viewletStateStorageId, JSON.stringify(viewletState), this.contextService.hasWorkspace() ? StorageScope.WORKSPACE : StorageScope.GLOBAL); + } + + protected loadViewsStates(): Map { + const viewsStates = JSON.parse(this.storageService.get(this.viewletStateStorageId, this.contextService.hasWorkspace() ? StorageScope.WORKSPACE : StorageScope.GLOBAL, '{}')); + return Object.keys(viewsStates).reduce((result, id) => { + result.set(id, viewsStates[id]); + return result; + }, new Map()); + } + + protected createView(viewDescriptor: IViewDescriptor, options: IViewOptions): IViewletView { + return this.instantiationService.createInstance(viewDescriptor.ctor, viewDescriptor.id, options); + } + + protected getView(id: string): IViewletView { + return this.views.filter(view => view.id === id)[0]; + } } \ No newline at end of file diff --git a/src/vs/workbench/parts/views/browser/viewsRegistry.ts b/src/vs/workbench/parts/views/browser/viewsRegistry.ts index a335db36aad..ac12eb4be5b 100644 --- a/src/vs/workbench/parts/views/browser/viewsRegistry.ts +++ b/src/vs/workbench/parts/views/browser/viewsRegistry.ts @@ -50,10 +50,14 @@ export interface IViewsRegistry { readonly onViewsRegistered: Event; + readonly onViewsDeregistered: Event; + readonly onTreeViewDataProviderRegistered: Event; registerViews(views: IViewDescriptor[]): void; + deregisterViews(ids: string[], location: ViewLocation): void; + registerTreeViewDataProvider(id: string, factory: ITreeViewDataProvider): void; getViews(loc: ViewLocation): IViewDescriptor[]; @@ -67,6 +71,9 @@ export const ViewsRegistry: IViewsRegistry = new class { private _onViewsRegistered: Emitter = new Emitter(); readonly onViewsRegistered: Event = this._onViewsRegistered.event; + private _onViewsDeregistered: Emitter = new Emitter(); + readonly onViewsDeregistered: Event = this._onViewsDeregistered.event; + private _onTreeViewDataProviderRegistered: Emitter = new Emitter(); readonly onTreeViewDataProviderRegistered: Event = this._onTreeViewDataProviderRegistered.event; @@ -87,6 +94,14 @@ export const ViewsRegistry: IViewsRegistry = new class { } } + deregisterViews(ids: string[], location: ViewLocation): void { + const viewsToDeregister = this._views.get(location).filter(view => ids.indexOf(view.id) !== -1); + if (viewsToDeregister.length) { + this._views.set(location, this._views.get(location).filter(view => ids.indexOf(view.id) === -1)); + } + this._onViewsDeregistered.fire(viewsToDeregister); + } + registerTreeViewDataProvider(id: string, factory: ITreeViewDataProvider) { if (!this.isViewRegistered(id)) { // TODO: throw error -- GitLab From ed5bc914fc584307f7d75fc730908b4596db17ac Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Tue, 6 Jun 2017 22:37:11 +0200 Subject: [PATCH 0669/1347] Debt: Use viewlet view settings --- .../workbench/parts/files/browser/explorerViewlet.ts | 11 ++++------- .../parts/files/browser/views/explorerView.ts | 8 +++----- src/vs/workbench/parts/views/browser/views.ts | 12 ++++++++++-- 3 files changed, 17 insertions(+), 14 deletions(-) diff --git a/src/vs/workbench/parts/files/browser/explorerViewlet.ts b/src/vs/workbench/parts/files/browser/explorerViewlet.ts index 1e97d5703b5..87a26e07bfb 100644 --- a/src/vs/workbench/parts/files/browser/explorerViewlet.ts +++ b/src/vs/workbench/parts/files/browser/explorerViewlet.ts @@ -10,9 +10,8 @@ import { IActionRunner } from 'vs/base/common/actions'; import { TPromise } from 'vs/base/common/winjs.base'; import * as DOM from 'vs/base/browser/dom'; import { Builder } from 'vs/base/browser/builder'; -import { Scope } from 'vs/workbench/common/memento'; import { VIEWLET_ID, ExplorerViewletVisibleContext, IFilesConfiguration } from 'vs/workbench/parts/files/common/files'; -import { ComposedViewsViewlet, IViewletView } from 'vs/workbench/parts/views/browser/views'; +import { ComposedViewsViewlet, IViewletView, IViewletViewOptions } from 'vs/workbench/parts/views/browser/views'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { ActionRunner, FileViewletState } from 'vs/workbench/parts/files/browser/views/explorerViewer'; import { ExplorerView, IExplorerViewOptions } from 'vs/workbench/parts/files/browser/views/explorerView'; @@ -30,13 +29,12 @@ import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/edi import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { IContextKeyService, IContextKey } from 'vs/platform/contextkey/common/contextkey'; import { IThemeService } from 'vs/platform/theme/common/themeService'; -import { ViewsRegistry, ViewLocation, IViewDescriptor, IViewOptions } from 'vs/workbench/parts/views/browser/viewsRegistry'; +import { ViewsRegistry, ViewLocation, IViewDescriptor } from 'vs/workbench/parts/views/browser/viewsRegistry'; export class ExplorerViewlet extends ComposedViewsViewlet { private static EXPLORER_VIEWS_STATE = 'workbench.explorer.views.state'; - private viewletSettings: any; private viewletState: FileViewletState; private viewletVisibleContextKey: IContextKey; @@ -54,7 +52,6 @@ export class ExplorerViewlet extends ComposedViewsViewlet { super(VIEWLET_ID, ViewLocation.Explorer, ExplorerViewlet.EXPLORER_VIEWS_STATE, telemetryService, storageService, instantiationService, themeService, contextService); this.viewletState = new FileViewletState(); - this.viewletSettings = this.getMemento(storageService, Scope.WORKSPACE); this.viewletVisibleContextKey = ExplorerViewletVisibleContext.bindTo(contextKeyService); this.registerViews(); @@ -127,7 +124,7 @@ export class ExplorerViewlet extends ComposedViewsViewlet { return !this.contextService.hasWorkspace() || (this.configurationService.getConfiguration()).explorer.openEditors.visible !== 0; } - protected createView(viewDescriptor: IViewDescriptor, options: IViewOptions): IViewletView { + protected createView(viewDescriptor: IViewDescriptor, options: IViewletViewOptions): IViewletView { if (viewDescriptor.id === ExplorerView.ID) { // Create a delegating editor service for the explorer to be able to delay the refresh in the opened // editors view above. This is a workaround for being able to double click on a file to make it pinned @@ -167,7 +164,7 @@ export class ExplorerViewlet extends ComposedViewsViewlet { }); const explorerInstantiator = this.instantiationService.createChild(new ServiceCollection([IWorkbenchEditorService, delegatingEditorService])); - return explorerInstantiator.createInstance(ExplorerView, viewDescriptor.id, { ...options, settings: this.viewletSettings, viewletState: this.viewletState }); + return explorerInstantiator.createInstance(ExplorerView, viewDescriptor.id, { ...options, viewletState: this.viewletState }); } return super.createView(viewDescriptor, options); } diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index 80bd2369b64..b43a82cb081 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -25,7 +25,7 @@ import { DiffEditorInput } from 'vs/workbench/common/editor/diffEditorInput'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import * as DOM from 'vs/base/browser/dom'; import { CollapseAction } from 'vs/workbench/browser/viewlet'; -import { CollapsibleViewletView } from 'vs/workbench/parts/views/browser/views'; +import { CollapsibleViewletView, IViewletViewOptions } from 'vs/workbench/parts/views/browser/views'; import { FileStat } from 'vs/workbench/parts/files/common/explorerViewModel'; import { IListService } from 'vs/platform/list/browser/listService'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; @@ -43,10 +43,8 @@ import { IWorkbenchThemeService, IFileIconTheme } from 'vs/workbench/services/th import { isLinux } from 'vs/base/common/platform'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { attachListStyler } from 'vs/platform/theme/common/styler'; -import { IViewOptions } from 'vs/workbench/parts/views/browser/viewsRegistry'; -export interface IExplorerViewOptions extends IViewOptions { - settings: any; +export interface IExplorerViewOptions extends IViewletViewOptions { viewletState: FileViewletState; } @@ -104,7 +102,7 @@ export class ExplorerView extends CollapsibleViewletView { ) { super(options.actionRunner, options.collapsed, nls.localize('explorerSection', "Files Explorer Section"), messageService, keybindingService, contextMenuService); - this.settings = options.settings; + this.settings = options.viewletSettings; this.viewletState = options.viewletState; this.actionRunner = options.actionRunner; this.autoReveal = true; diff --git a/src/vs/workbench/parts/views/browser/views.ts b/src/vs/workbench/parts/views/browser/views.ts index 179d898bc3d..01aa578329c 100644 --- a/src/vs/workbench/parts/views/browser/views.ts +++ b/src/vs/workbench/parts/views/browser/views.ts @@ -9,6 +9,7 @@ import { IThemable, attachHeaderViewStyler } from 'vs/platform/theme/common/styl import * as errors from 'vs/base/common/errors'; import * as DOM from 'vs/base/browser/dom'; import { $, Dimension, Builder } from 'vs/base/browser/builder'; +import { Scope } from 'vs/workbench/common/memento'; import { dispose, IDisposable } from 'vs/base/common/lifecycle'; import { IAction, IActionRunner } from 'vs/base/common/actions'; import { IActionItem, ActionsOrientation } from 'vs/base/browser/ui/actionbar/actionbar'; @@ -28,6 +29,10 @@ import { IInstantiationService } from 'vs/platform/instantiation/common/instanti import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +export interface IViewletViewOptions extends IViewOptions { + viewletSettings: any; +} + export interface IViewletView extends IView, IThemable { id?: string; create(): TPromise; @@ -373,6 +378,7 @@ export class ComposedViewsViewlet extends Viewlet { private splitView: SplitView; private views: IViewletView[]; private dimension: Dimension; + private viewletSettings: any; private readonly viewsStates: Map; @@ -389,6 +395,7 @@ export class ComposedViewsViewlet extends Viewlet { super(id, telemetryService, themeService); this.views = []; + this.viewletSettings = this.getMemento(storageService, Scope.WORKSPACE); this.viewsStates = this.loadViewsStates(); this._register(ViewsRegistry.onViewsRegistered(viewDescriptors => this.createViews(viewDescriptors.filter(viewDescriptor => ViewLocation.Explorer === viewDescriptor.location)))); @@ -444,7 +451,8 @@ export class ComposedViewsViewlet extends Viewlet { const view = this.createView(viewDescriptor, { name: viewDescriptor.name, actionRunner: this.getActionRunner(), - collapsed: viewState ? viewState.collapsed : true + collapsed: viewState ? viewState.collapsed : true, + viewletSettings: this.viewletSettings }); if (index !== -1) { this.views.splice(index, 0, view); @@ -546,7 +554,7 @@ export class ComposedViewsViewlet extends Viewlet { }, new Map()); } - protected createView(viewDescriptor: IViewDescriptor, options: IViewOptions): IViewletView { + protected createView(viewDescriptor: IViewDescriptor, options: IViewletViewOptions): IViewletView { return this.instantiationService.createInstance(viewDescriptor.ctor, viewDescriptor.id, options); } -- GitLab From 9acebf6374b4e886d0290bd1cb672c2f37374d6e Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Fri, 9 Jun 2017 10:52:22 +0200 Subject: [PATCH 0670/1347] #27823 - Debt reduction. Clean up views. - Implement Composed views viewlet - Adopt explorer debug viewlet to composed views viewlet --- src/vs/base/browser/ui/splitview/splitview.ts | 100 ++-- .../parts/debug/browser/debugViewRegistry.ts | 37 -- .../parts/debug/browser/debugViewlet.ts | 116 +---- .../electron-browser/debug.contribution.ts | 10 +- .../debug/electron-browser/debugViews.ts | 59 +-- .../parts/files/browser/explorerViewlet.ts | 10 +- .../parts/files/browser/views/emptyView.ts | 13 +- .../parts/files/browser/views/explorerView.ts | 10 +- .../files/browser/views/openEditorsView.ts | 19 +- .../workbench/parts/views/browser/treeView.ts | 47 +- src/vs/workbench/parts/views/browser/views.ts | 429 ++++++++---------- .../views/browser/viewsExtensionPoint.ts | 15 +- .../parts/views/browser/viewsRegistry.ts | 20 +- 13 files changed, 361 insertions(+), 524 deletions(-) delete mode 100644 src/vs/workbench/parts/debug/browser/debugViewRegistry.ts diff --git a/src/vs/base/browser/ui/splitview/splitview.ts b/src/vs/base/browser/ui/splitview/splitview.ts index 41415d49b18..31710fb3489 100644 --- a/src/vs/base/browser/ui/splitview/splitview.ts +++ b/src/vs/base/browser/ui/splitview/splitview.ts @@ -9,7 +9,6 @@ import 'vs/css!./splitview'; import lifecycle = require('vs/base/common/lifecycle'); import ee = require('vs/base/common/eventEmitter'); import types = require('vs/base/common/types'); -import objects = require('vs/base/common/objects'); import dom = require('vs/base/browser/dom'); import numbers = require('vs/base/common/numbers'); import sash = require('vs/base/browser/ui/sash/sash'); @@ -240,10 +239,9 @@ export abstract class HeaderView extends View { } export interface ICollapsibleViewOptions { - ariaHeaderLabel?: string; - fixedSize?: number; - minimumSize?: number; - headerSize?: number; + sizing: ViewSizing; + ariaHeaderLabel: string; + bodySize?: number; initialState?: CollapsibleState; } @@ -260,14 +258,43 @@ export abstract class AbstractCollapsibleView extends HeaderView { private headerClickListener: lifecycle.IDisposable; private headerKeyListener: lifecycle.IDisposable; private focusTracker: dom.IFocusTracker; + private _bodySize: number; + private _previousSize: number = null; + private readonly viewSizing: ViewSizing; constructor(opts: ICollapsibleViewOptions) { super(opts); + this.viewSizing = opts.sizing; + this.ariaHeaderLabel = opts.ariaHeaderLabel; - this.ariaHeaderLabel = opts && opts.ariaHeaderLabel; + this.setBodySize(types.isUndefined(opts.bodySize) ? 22 : opts.bodySize); this.changeState(types.isUndefined(opts.initialState) ? CollapsibleState.EXPANDED : opts.initialState); } + get previousSize(): number { + return this._previousSize; + } + + setBodySize(bodySize: number) { + this._bodySize = bodySize; + this.updateSize(); + } + + private updateSize() { + if (this.viewSizing === ViewSizing.Fixed) { + this.setFixed(this.state === CollapsibleState.EXPANDED ? this._bodySize + this.headerSize : this.headerSize); + } else { + this._minimumSize = this._bodySize + this.headerSize; + this._previousSize = !this.previousSize || this._previousSize < this._minimumSize ? this._minimumSize : this._previousSize; + if (this.state === CollapsibleState.EXPANDED) { + this.setFlexible(this._previousSize || this._minimumSize); + } else { + this._previousSize = this.size || this._minimumSize; + this.setFixed(this.headerSize); + } + } + } + render(container: HTMLElement, orientation: Orientation): void { super.render(container, orientation); @@ -377,6 +404,7 @@ export abstract class AbstractCollapsibleView extends HeaderView { } this.layoutHeader(); + this.updateSize(); } dispose(): void { @@ -399,55 +427,6 @@ export abstract class AbstractCollapsibleView extends HeaderView { } } -export abstract class CollapsibleView extends AbstractCollapsibleView { - - private previousSize: number; - - constructor(opts: ICollapsibleViewOptions) { - super(opts); - this.previousSize = null; - } - - protected changeState(state: CollapsibleState): void { - super.changeState(state); - - if (state === CollapsibleState.EXPANDED) { - this.setFlexible(this.previousSize || this._minimumSize); - } else { - this.previousSize = this.size; - this.setFixed(); - } - } -} - -export interface IFixedCollapsibleViewOptions extends ICollapsibleViewOptions { - expandedBodySize?: number; -} - -export abstract class FixedCollapsibleView extends AbstractCollapsibleView { - - private _expandedBodySize: number; - - constructor(opts: IFixedCollapsibleViewOptions) { - super(objects.mixin({ sizing: ViewSizing.Fixed }, opts)); - this._expandedBodySize = types.isUndefined(opts.expandedBodySize) ? 22 : opts.expandedBodySize; - } - - get fixedSize(): number { return this.state === CollapsibleState.EXPANDED ? this.expandedSize : this.headerSize; } - private get expandedSize(): number { return this.expandedBodySize + this.headerSize; } - - get expandedBodySize(): number { return this._expandedBodySize; } - set expandedBodySize(size: number) { - this._expandedBodySize = size; - this.setFixed(this.fixedSize); - } - - protected changeState(state: CollapsibleState): void { - super.changeState(state); - this.setFixed(this.fixedSize); - } -} - class PlainView extends View { render() { } focus() { } @@ -555,7 +534,7 @@ export class SplitView implements } /** - * Reset size to null. This will layout newly added viees to initial weights. + * Reset size to null. This will layout newly added views to initial weights. */ this.size = null; @@ -599,6 +578,14 @@ export class SplitView implements this.viewFocusNextListeners.splice(index, 0, view.addListener('focusNext', () => index < this.views.length && this.views[index + 1].focus())); } + updateWeight(view: IView, weight: number) { + let index = this.views.indexOf(view); + if (index < 0) { + return; + } + this.initialWeights[index] = weight; + } + removeView(view: IView): void { let index = this.views.indexOf(view); @@ -606,6 +593,7 @@ export class SplitView implements return; } + this.size = null; let deadView = new DeadView(view); this.views[index] = deadView; this.onViewChange(deadView, 0); diff --git a/src/vs/workbench/parts/debug/browser/debugViewRegistry.ts b/src/vs/workbench/parts/debug/browser/debugViewRegistry.ts deleted file mode 100644 index 6aea43a7635..00000000000 --- a/src/vs/workbench/parts/debug/browser/debugViewRegistry.ts +++ /dev/null @@ -1,37 +0,0 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ - -import { IActionRunner } from 'vs/base/common/actions'; -import { IViewletView } from 'vs/workbench/parts/views/browser/views'; - -// Debug view registration - -export interface IDebugViewConstructorSignature { - new (actionRunner: IActionRunner, viewletSetings: any, ...services: { _serviceBrand: any; }[]): IViewletView; -} - -export interface IDebugViewRegistry { - registerDebugView(view: IDebugViewConstructorSignature, order: number, weight: number): void; - getDebugViews(): { view: IDebugViewConstructorSignature, weight: number }[]; -} - -class DebugViewRegistryImpl implements IDebugViewRegistry { - private debugViews: { view: IDebugViewConstructorSignature, order: number, weight: number }[]; - - constructor() { - this.debugViews = []; - } - - public registerDebugView(view: IDebugViewConstructorSignature, order: number, weight: number): void { - this.debugViews.push({ view, order, weight }); - } - - public getDebugViews(): { view: IDebugViewConstructorSignature, weight: number }[] { - return this.debugViews.sort((first, second) => first.order - second.order) - .map(viewWithOrder => ({ view: viewWithOrder.view, weight: viewWithOrder.weight })); - } -} - -export const DebugViewRegistry = new DebugViewRegistryImpl(); diff --git a/src/vs/workbench/parts/debug/browser/debugViewlet.ts b/src/vs/workbench/parts/debug/browser/debugViewlet.ts index df7e198e7b7..a6af5531673 100644 --- a/src/vs/workbench/parts/debug/browser/debugViewlet.ts +++ b/src/vs/workbench/parts/debug/browser/debugViewlet.ts @@ -4,108 +4,49 @@ *--------------------------------------------------------------------------------------------*/ import 'vs/css!./media/debugViewlet'; -import { Builder, Dimension } from 'vs/base/browser/builder'; +import { Builder } from 'vs/base/browser/builder'; +import * as DOM from 'vs/base/browser/dom'; import { TPromise } from 'vs/base/common/winjs.base'; -import * as lifecycle from 'vs/base/common/lifecycle'; import { IAction } from 'vs/base/common/actions'; import { IActionItem } from 'vs/base/browser/ui/actionbar/actionbar'; -import { SplitView, HeaderView } from 'vs/base/browser/ui/splitview/splitview'; -import { ILifecycleService } from 'vs/platform/lifecycle/common/lifecycle'; -import { Scope } from 'vs/workbench/common/memento'; -import { Viewlet } from 'vs/workbench/browser/viewlet'; -import { IViewletView } from 'vs/workbench/parts/views/browser/views'; +import { ComposedViewsViewlet } from 'vs/workbench/parts/views/browser/views'; import { IDebugService, VIEWLET_ID, State } from 'vs/workbench/parts/debug/common/debug'; -import { DebugViewRegistry } from 'vs/workbench/parts/debug/browser/debugViewRegistry'; import { StartAction, ToggleReplAction, ConfigureAction } from 'vs/workbench/parts/debug/browser/debugActions'; import { StartDebugActionItem } from 'vs/workbench/parts/debug/browser/debugActionItems'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { IProgressService, IProgressRunner } from 'vs/platform/progress/common/progress'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; -import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage'; +import { IStorageService } from 'vs/platform/storage/common/storage'; import { IThemeService } from 'vs/platform/theme/common/themeService'; -import { attachHeaderViewStyler } from 'vs/platform/theme/common/styler'; +import { ViewLocation } from 'vs/workbench/parts/views/browser/viewsRegistry'; +import { IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; -const DEBUG_VIEWS_WEIGHTS = 'debug.viewsweights'; +export class DebugViewlet extends ComposedViewsViewlet { -export class DebugViewlet extends Viewlet { - - private toDispose: lifecycle.IDisposable[]; private actions: IAction[]; private startDebugActionItem: StartDebugActionItem; private progressRunner: IProgressRunner; - private viewletSettings: any; - - private $el: Builder; - private splitView: SplitView; - private views: IViewletView[]; constructor( @ITelemetryService telemetryService: ITelemetryService, @IProgressService private progressService: IProgressService, @IDebugService private debugService: IDebugService, - @IInstantiationService private instantiationService: IInstantiationService, - @IWorkspaceContextService private contextService: IWorkspaceContextService, - @IStorageService private storageService: IStorageService, - @ILifecycleService lifecycleService: ILifecycleService, - @IThemeService themeService: IThemeService + @IInstantiationService instantiationService: IInstantiationService, + @IWorkspaceContextService contextService: IWorkspaceContextService, + @IStorageService storageService: IStorageService, + @IThemeService themeService: IThemeService, + @IContextKeyService contextKeyService: IContextKeyService ) { - super(VIEWLET_ID, telemetryService, themeService); + super(VIEWLET_ID, ViewLocation.Debug, `${VIEWLET_ID}.state`, telemetryService, storageService, instantiationService, themeService, contextService, contextKeyService); this.progressRunner = null; - this.viewletSettings = this.getMemento(storageService, Scope.WORKSPACE); - this.toDispose = []; - this.views = []; - this.toDispose.push(this.debugService.onDidChangeState(state => { - this.onDebugServiceStateChange(state); - })); - lifecycleService.onShutdown(this.store, this); - } - - // viewlet - - public create(parent: Builder): TPromise { - super.create(parent); - this.$el = parent.div().addClass('debug-viewlet'); - - const actionRunner = this.getActionRunner(); - const registeredViews = DebugViewRegistry.getDebugViews(); - this.views = registeredViews.map(viewConstructor => this.instantiationService.createInstance( - viewConstructor.view, - actionRunner, - this.viewletSettings) - ); - - this.views.forEach((view, index) => { - if (view instanceof HeaderView) { - attachHeaderViewStyler(view, this.themeService, { noContrastBorder: index === 0 }); - } - }); - - this.splitView = new SplitView(this.$el.getHTMLElement()); - this.toDispose.push(this.splitView); - let weights: number[] = JSON.parse(this.storageService.get(DEBUG_VIEWS_WEIGHTS, StorageScope.WORKSPACE, '[]')); - if (!weights.length) { - weights = registeredViews.map(v => v.weight); - } - - for (let i = 0; i < this.views.length; i++) { - this.splitView.addView(this.views[i], Math.max(weights[i], 1)); - } - - return TPromise.as(null); - } - public setVisible(visible: boolean): TPromise { - return super.setVisible(visible).then(() => { - return TPromise.join(this.views.map(view => view.setVisible(visible))); - }); + this._register(this.debugService.onDidChangeState(state => this.onDebugServiceStateChange(state))); } - public layout(dimension: Dimension): void { - if (this.splitView) { - this.splitView.layout(dimension.height); - } + public create(parent: Builder): TPromise { + return super.create(parent).then(() => DOM.addClass(this.viewletContainer, 'debug-viewlet')); } public focus(): void { @@ -127,16 +68,16 @@ export class DebugViewlet extends Viewlet { if (this.contextService.hasWorkspace()) { this.actions.push(this.instantiationService.createInstance(ConfigureAction, ConfigureAction.ID, ConfigureAction.LABEL)); } - this.actions.push(this.instantiationService.createInstance(ToggleReplAction, ToggleReplAction.ID, ToggleReplAction.LABEL)); - - this.actions.forEach(a => { - this.toDispose.push(a); - }); + this.actions.push(this._register(this.instantiationService.createInstance(ToggleReplAction, ToggleReplAction.ID, ToggleReplAction.LABEL))); } return this.actions; } + public getSecondaryActions(): IAction[] { + return []; + } + public getActionItem(action: IAction): IActionItem { if (action.id === StartAction.ID && this.contextService.hasWorkspace()) { this.startDebugActionItem = this.instantiationService.createInstance(StartDebugActionItem, null, action); @@ -157,19 +98,4 @@ export class DebugViewlet extends Viewlet { this.progressRunner = null; } } - - private store(): void { - this.storageService.store(DEBUG_VIEWS_WEIGHTS, JSON.stringify(this.views.map(view => view.size)), StorageScope.WORKSPACE); - } - - public dispose(): void { - this.toDispose = lifecycle.dispose(this.toDispose); - - super.dispose(); - } - - public shutdown(): void { - this.views.forEach(v => v.shutdown()); - super.shutdown(); - } } diff --git a/src/vs/workbench/parts/debug/electron-browser/debug.contribution.ts b/src/vs/workbench/parts/debug/electron-browser/debug.contribution.ts index 947763e0255..368615a85a9 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debug.contribution.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debug.contribution.ts @@ -15,7 +15,6 @@ import { IConfigurationRegistry, Extensions as ConfigurationExtensions } from 'v import { IWorkbenchActionRegistry, Extensions as WorkbenchActionRegistryExtensions } from 'vs/workbench/common/actionRegistry'; import { ToggleViewletAction, Extensions as ViewletExtensions, ViewletRegistry, ViewletDescriptor } from 'vs/workbench/browser/viewlet'; import { TogglePanelAction, Extensions as PanelExtensions, PanelRegistry, PanelDescriptor } from 'vs/workbench/browser/panel'; -import { DebugViewRegistry } from 'vs/workbench/parts/debug/browser/debugViewRegistry'; import { VariablesView, WatchExpressionsView, CallStackView, BreakpointsView } from 'vs/workbench/parts/debug/electron-browser/debugViews'; import { Extensions as WorkbenchExtensions, IWorkbenchContributionsRegistry } from 'vs/workbench/common/contributions'; import { IDebugService, VIEWLET_ID, REPL_ID, CONTEXT_NOT_IN_DEBUG_MODE, CONTEXT_IN_DEBUG_MODE, INTERNAL_CONSOLE_OPTIONS_SCHEMA } from 'vs/workbench/parts/debug/common/debug'; @@ -35,6 +34,7 @@ import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/edi import * as debugCommands from 'vs/workbench/parts/debug/electron-browser/debugCommands'; import { IQuickOpenRegistry, Extensions as QuickOpenExtensions, QuickOpenHandlerDescriptor } from 'vs/workbench/browser/quickopen'; import { StatusBarColorProvider } from 'vs/workbench/parts/debug/electron-browser/statusbarColorProvider'; +import { ViewLocation, ViewsRegistry } from 'vs/workbench/parts/views/browser/viewsRegistry'; class OpenDebugViewletAction extends ToggleViewletAction { public static ID = VIEWLET_ID; @@ -94,10 +94,10 @@ Registry.as(PanelExtensions.Panels).registerPanel(new PanelDescri Registry.as(PanelExtensions.Panels).setDefaultPanelId(REPL_ID); // Register default debug views -DebugViewRegistry.registerDebugView(VariablesView, 10, 40); -DebugViewRegistry.registerDebugView(WatchExpressionsView, 20, 10); -DebugViewRegistry.registerDebugView(CallStackView, 30, 30); -DebugViewRegistry.registerDebugView(BreakpointsView, 40, 20); +ViewsRegistry.registerViews([{ id: 'workbench.debug.variablesView', name: '', ctor: VariablesView, order: 10, size: 40, location: ViewLocation.Debug }]); +ViewsRegistry.registerViews([{ id: 'workbench.debug.watchExpressionsView', name: '', ctor: WatchExpressionsView, order: 20, size: 10, location: ViewLocation.Debug }]); +ViewsRegistry.registerViews([{ id: 'workbench.debug.callStackView', name: '', ctor: CallStackView, order: 30, size: 30, location: ViewLocation.Debug }]); +ViewsRegistry.registerViews([{ id: 'workbench.debug.breakPointsView', name: '', ctor: BreakpointsView, order: 40, size: 20, location: ViewLocation.Debug }]); // register action to open viewlet const registry = Registry.as(WorkbenchActionRegistryExtensions.WorkbenchActions); diff --git a/src/vs/workbench/parts/debug/electron-browser/debugViews.ts b/src/vs/workbench/parts/debug/electron-browser/debugViews.ts index 6bb133269d5..f6c919a997a 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugViews.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugViews.ts @@ -11,13 +11,13 @@ import * as builder from 'vs/base/browser/builder'; import { TPromise } from 'vs/base/common/winjs.base'; import * as errors from 'vs/base/common/errors'; import { EventType } from 'vs/base/common/events'; -import { IActionRunner, IAction } from 'vs/base/common/actions'; +import { IAction } from 'vs/base/common/actions'; import { prepareActions } from 'vs/workbench/browser/actions'; import { IHighlightEvent, ITree } from 'vs/base/parts/tree/browser/tree'; import { Tree } from 'vs/base/parts/tree/browser/treeImpl'; -import { CollapsibleState } from 'vs/base/browser/ui/splitview/splitview'; +import { CollapsibleState, ViewSizing } from 'vs/base/browser/ui/splitview/splitview'; import { CollapseAction } from 'vs/workbench/browser/viewlet'; -import { CollapsibleViewletView, AdaptiveCollapsibleViewletView } from 'vs/workbench/parts/views/browser/views'; +import { CollapsibleView, IViewletViewOptions } from 'vs/workbench/parts/views/browser/views'; import { IDebugService, State, IBreakpoint, IExpression, CONTEXT_BREAKPOINTS_FOCUSED, CONTEXT_WATCH_EXPRESSIONS_FOCUSED, CONTEXT_VARIABLES_FOCUSED } from 'vs/workbench/parts/debug/common/debug'; import { Expression, Variable, ExceptionBreakpoint, FunctionBreakpoint, Thread, StackFrame, Breakpoint, ThreadAndProcessIds } from 'vs/workbench/parts/debug/common/debugModel'; import * as viewer from 'vs/workbench/parts/debug/electron-browser/debugViewer'; @@ -26,7 +26,6 @@ import { IContextMenuService } from 'vs/platform/contextview/browser/contextView import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { MenuId } from 'vs/platform/actions/common/actions'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; -import { IMessageService } from 'vs/platform/message/common/message'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { IContextKeyService, IContextKey } from 'vs/platform/contextkey/common/contextkey'; import { IListService } from 'vs/platform/list/browser/listService'; @@ -43,16 +42,15 @@ function renderViewTree(container: HTMLElement): HTMLElement { const $ = builder.$; const twistiePixels = 20; -export class VariablesView extends CollapsibleViewletView { +export class VariablesView extends CollapsibleView { private static MEMENTO = 'variablesview.memento'; private onFocusStackFrameScheduler: RunOnceScheduler; private variablesFocusedContext: IContextKey; + private settings: any; constructor( - actionRunner: IActionRunner, - private settings: any, - @IMessageService messageService: IMessageService, + options: IViewletViewOptions, @IContextMenuService contextMenuService: IContextMenuService, @ITelemetryService private telemetryService: ITelemetryService, @IDebugService private debugService: IDebugService, @@ -62,8 +60,9 @@ export class VariablesView extends CollapsibleViewletView { @IListService private listService: IListService, @IThemeService private themeService: IThemeService ) { - super(actionRunner, !!settings[VariablesView.MEMENTO], nls.localize('variablesSection', "Variables Section"), messageService, keybindingService, contextMenuService); + super({ ...options, sizing: ViewSizing.Flexible, ariaHeaderLabel: nls.localize('variablesSection', "Variables Section") }, keybindingService, contextMenuService); + this.settings = options.viewletSettings; this.variablesFocusedContext = CONTEXT_VARIABLES_FOCUSED.bindTo(contextKeyService); // Use scheduler to prevent unnecessary flashing this.onFocusStackFrameScheduler = new RunOnceScheduler(() => { @@ -151,17 +150,16 @@ export class VariablesView extends CollapsibleViewletView { } } -export class WatchExpressionsView extends CollapsibleViewletView { +export class WatchExpressionsView extends CollapsibleView { private static MEMENTO = 'watchexpressionsview.memento'; private onWatchExpressionsUpdatedScheduler: RunOnceScheduler; private toReveal: IExpression; private watchExpressionsFocusedContext: IContextKey; + private settings: any; constructor( - actionRunner: IActionRunner, - private settings: any, - @IMessageService messageService: IMessageService, + options: IViewletViewOptions, @IContextMenuService contextMenuService: IContextMenuService, @IDebugService private debugService: IDebugService, @IKeybindingService keybindingService: IKeybindingService, @@ -170,7 +168,8 @@ export class WatchExpressionsView extends CollapsibleViewletView { @IListService private listService: IListService, @IThemeService private themeService: IThemeService ) { - super(actionRunner, !!settings[WatchExpressionsView.MEMENTO], nls.localize('expressionsSection', "Expressions Section"), messageService, keybindingService, contextMenuService); + super({ ...options, ariaHeaderLabel: nls.localize('expressionsSection', "Expressions Section"), sizing: ViewSizing.Flexible }, keybindingService, contextMenuService); + this.settings = options.viewletSettings; this.toDispose.push(this.debugService.getModel().onDidChangeWatchExpressions(we => { // only expand when a new watch expression is added. @@ -250,17 +249,16 @@ export class WatchExpressionsView extends CollapsibleViewletView { } } -export class CallStackView extends CollapsibleViewletView { +export class CallStackView extends CollapsibleView { private static MEMENTO = 'callstackview.memento'; private pauseMessage: builder.Builder; private pauseMessageLabel: builder.Builder; private onCallStackChangeScheduler: RunOnceScheduler; + private settings: any; constructor( - actionRunner: IActionRunner, - private settings: any, - @IMessageService messageService: IMessageService, + options: IViewletViewOptions, @IContextMenuService contextMenuService: IContextMenuService, @ITelemetryService private telemetryService: ITelemetryService, @IDebugService private debugService: IDebugService, @@ -269,7 +267,8 @@ export class CallStackView extends CollapsibleViewletView { @IListService private listService: IListService, @IThemeService private themeService: IThemeService ) { - super(actionRunner, !!settings[CallStackView.MEMENTO], nls.localize('callstackSection', "Call Stack Section"), messageService, keybindingService, contextMenuService); + super({ ...options, ariaHeaderLabel: nls.localize('callstackSection', "Call Stack Section"), sizing: ViewSizing.Flexible }, keybindingService, contextMenuService); + this.settings = options.viewletSettings; // Create scheduler to prevent unnecessary flashing of tree when reacting to changes this.onCallStackChangeScheduler = new RunOnceScheduler(() => { @@ -385,15 +384,15 @@ export class CallStackView extends CollapsibleViewletView { } } -export class BreakpointsView extends AdaptiveCollapsibleViewletView { +export class BreakpointsView extends CollapsibleView { private static MAX_VISIBLE_FILES = 9; private static MEMENTO = 'breakopintsview.memento'; private breakpointsFocusedContext: IContextKey; + private settings: any; constructor( - actionRunner: IActionRunner, - private settings: any, + options: IViewletViewOptions, @IContextMenuService contextMenuService: IContextMenuService, @IDebugService private debugService: IDebugService, @IKeybindingService keybindingService: IKeybindingService, @@ -402,10 +401,14 @@ export class BreakpointsView extends AdaptiveCollapsibleViewletView { @IListService private listService: IListService, @IThemeService private themeService: IThemeService ) { - super(actionRunner, BreakpointsView.getExpandedBodySize( - debugService.getModel().getBreakpoints().length + debugService.getModel().getFunctionBreakpoints().length + debugService.getModel().getExceptionBreakpoints().length), - !!settings[BreakpointsView.MEMENTO], nls.localize('breakpointsSection', "Breakpoints Section"), keybindingService, contextMenuService); - + super({ + ...options, + ariaHeaderLabel: nls.localize('breakpointsSection', "Breakpoints Section"), + sizing: ViewSizing.Fixed, initialBodySize: BreakpointsView.getExpandedBodySize( + debugService.getModel().getBreakpoints().length + debugService.getModel().getFunctionBreakpoints().length + debugService.getModel().getExceptionBreakpoints().length) + }, keybindingService, contextMenuService); + + this.settings = options.viewletSettings; this.breakpointsFocusedContext = CONTEXT_BREAKPOINTS_FOCUSED.bindTo(contextKeyService); this.toDispose.push(this.debugService.getModel().onDidChangeBreakpoints(() => this.onBreakpointsChange())); } @@ -503,8 +506,8 @@ export class BreakpointsView extends AdaptiveCollapsibleViewletView { private onBreakpointsChange(): void { const model = this.debugService.getModel(); - this.expandedBodySize = BreakpointsView.getExpandedBodySize( - model.getBreakpoints().length + model.getExceptionBreakpoints().length + model.getFunctionBreakpoints().length); + this.setBodySize(BreakpointsView.getExpandedBodySize( + model.getBreakpoints().length + model.getExceptionBreakpoints().length + model.getFunctionBreakpoints().length)); if (this.tree) { this.tree.refresh(); diff --git a/src/vs/workbench/parts/files/browser/explorerViewlet.ts b/src/vs/workbench/parts/files/browser/explorerViewlet.ts index 87a26e07bfb..eaea1615ad2 100644 --- a/src/vs/workbench/parts/files/browser/explorerViewlet.ts +++ b/src/vs/workbench/parts/files/browser/explorerViewlet.ts @@ -11,7 +11,7 @@ import { TPromise } from 'vs/base/common/winjs.base'; import * as DOM from 'vs/base/browser/dom'; import { Builder } from 'vs/base/browser/builder'; import { VIEWLET_ID, ExplorerViewletVisibleContext, IFilesConfiguration } from 'vs/workbench/parts/files/common/files'; -import { ComposedViewsViewlet, IViewletView, IViewletViewOptions } from 'vs/workbench/parts/views/browser/views'; +import { ComposedViewsViewlet, IView, IViewletViewOptions } from 'vs/workbench/parts/views/browser/views'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { ActionRunner, FileViewletState } from 'vs/workbench/parts/files/browser/views/explorerViewer'; import { ExplorerView, IExplorerViewOptions } from 'vs/workbench/parts/files/browser/views/explorerView'; @@ -49,7 +49,7 @@ export class ExplorerViewlet extends ComposedViewsViewlet { @IContextKeyService contextKeyService: IContextKeyService, @IThemeService themeService: IThemeService ) { - super(VIEWLET_ID, ViewLocation.Explorer, ExplorerViewlet.EXPLORER_VIEWS_STATE, telemetryService, storageService, instantiationService, themeService, contextService); + super(VIEWLET_ID, ViewLocation.Explorer, ExplorerViewlet.EXPLORER_VIEWS_STATE, telemetryService, storageService, instantiationService, themeService, contextService, contextKeyService); this.viewletState = new FileViewletState(); this.viewletVisibleContextKey = ExplorerViewletVisibleContext.bindTo(contextKeyService); @@ -124,7 +124,7 @@ export class ExplorerViewlet extends ComposedViewsViewlet { return !this.contextService.hasWorkspace() || (this.configurationService.getConfiguration()).explorer.openEditors.visible !== 0; } - protected createView(viewDescriptor: IViewDescriptor, options: IViewletViewOptions): IViewletView { + protected createView(viewDescriptor: IViewDescriptor, options: IViewletViewOptions): IView { if (viewDescriptor.id === ExplorerView.ID) { // Create a delegating editor service for the explorer to be able to delay the refresh in the opened // editors view above. This is a workaround for being able to double click on a file to make it pinned @@ -164,7 +164,7 @@ export class ExplorerViewlet extends ComposedViewsViewlet { }); const explorerInstantiator = this.instantiationService.createChild(new ServiceCollection([IWorkbenchEditorService, delegatingEditorService])); - return explorerInstantiator.createInstance(ExplorerView, viewDescriptor.id, { ...options, viewletState: this.viewletState }); + return explorerInstantiator.createInstance(ExplorerView, { ...options, viewletState: this.viewletState }); } return super.createView(viewDescriptor, options); } @@ -222,7 +222,7 @@ export class ExplorerViewlet extends ComposedViewsViewlet { super.focus(); } - private hasSelectionOrFocus(view: IViewletView): boolean { + private hasSelectionOrFocus(view: IView): boolean { if (!view) { return false; } diff --git a/src/vs/workbench/parts/files/browser/views/emptyView.ts b/src/vs/workbench/parts/files/browser/views/emptyView.ts index eb02a3b1087..7cecda136e6 100644 --- a/src/vs/workbench/parts/files/browser/views/emptyView.ts +++ b/src/vs/workbench/parts/files/browser/views/emptyView.ts @@ -13,32 +13,29 @@ import { IAction } from 'vs/base/common/actions'; import { Button } from 'vs/base/browser/ui/button/button'; import { $ } from 'vs/base/browser/builder'; import { IActionItem } from 'vs/base/browser/ui/actionbar/actionbar'; -import { CollapsibleViewletView } from 'vs/workbench/parts/views/browser/views'; +import { CollapsibleView, IViewletViewOptions } from 'vs/workbench/parts/views/browser/views'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { OpenFolderAction, OpenFileFolderAction } from 'vs/workbench/browser/actions/fileActions'; import { attachButtonStyler } from 'vs/platform/theme/common/styler'; import { IThemeService } from 'vs/platform/theme/common/themeService'; -import { IViewOptions } from 'vs/workbench/parts/views/browser/viewsRegistry'; -import { IMessageService } from 'vs/platform/message/common/message'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { IContextMenuService } from 'vs/platform/contextview/browser/contextView'; +import { ViewSizing } from 'vs/base/browser/ui/splitview/splitview'; -export class EmptyView extends CollapsibleViewletView { +export class EmptyView extends CollapsibleView { public static ID: string = 'workbench.explorer.emptyView'; private openFolderButton: Button; constructor( - readonly id: string, - options: IViewOptions, + options: IViewletViewOptions, @IThemeService private themeService: IThemeService, @IInstantiationService private instantiationService: IInstantiationService, - @IMessageService messageService: IMessageService, @IKeybindingService keybindingService: IKeybindingService, @IContextMenuService contextMenuService: IContextMenuService ) { - super(options.actionRunner, options.collapsed, nls.localize('explorerSection', "Files Explorer Section"), messageService, keybindingService, contextMenuService, void 0, 5 * 22); + super({ ...options, ariaHeaderLabel: nls.localize('explorerSection', "Files Explorer Section"), sizing: ViewSizing.Flexible }, keybindingService, contextMenuService); } public renderHeader(container: HTMLElement): void { diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index b43a82cb081..c9372420e06 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -25,7 +25,7 @@ import { DiffEditorInput } from 'vs/workbench/common/editor/diffEditorInput'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import * as DOM from 'vs/base/browser/dom'; import { CollapseAction } from 'vs/workbench/browser/viewlet'; -import { CollapsibleViewletView, IViewletViewOptions } from 'vs/workbench/parts/views/browser/views'; +import { CollapsibleView, IViewletViewOptions } from 'vs/workbench/parts/views/browser/views'; import { FileStat } from 'vs/workbench/parts/files/common/explorerViewModel'; import { IListService } from 'vs/platform/list/browser/listService'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; @@ -43,12 +43,13 @@ import { IWorkbenchThemeService, IFileIconTheme } from 'vs/workbench/services/th import { isLinux } from 'vs/base/common/platform'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { attachListStyler } from 'vs/platform/theme/common/styler'; +import { ViewSizing } from 'vs/base/browser/ui/splitview/splitview'; export interface IExplorerViewOptions extends IViewletViewOptions { viewletState: FileViewletState; } -export class ExplorerView extends CollapsibleViewletView { +export class ExplorerView extends CollapsibleView { public static ID: string = 'workbench.explorer.fileView'; private static EXPLORER_FILE_CHANGES_REACT_DELAY = 500; // delay in ms to react to file changes to give our internal events a chance to react first @@ -82,9 +83,8 @@ export class ExplorerView extends CollapsibleViewletView { private settings: any; constructor( - id: string, options: IExplorerViewOptions, - @IMessageService messageService: IMessageService, + @IMessageService private messageService: IMessageService, @IContextMenuService contextMenuService: IContextMenuService, @IInstantiationService private instantiationService: IInstantiationService, @IEditorGroupService private editorGroupService: IEditorGroupService, @@ -100,7 +100,7 @@ export class ExplorerView extends CollapsibleViewletView { @IWorkbenchThemeService private themeService: IWorkbenchThemeService, @IEnvironmentService private environmentService: IEnvironmentService ) { - super(options.actionRunner, options.collapsed, nls.localize('explorerSection', "Files Explorer Section"), messageService, keybindingService, contextMenuService); + super({ ...options, ariaHeaderLabel: nls.localize('explorerSection', "Files Explorer Section"), sizing: ViewSizing.Flexible }, keybindingService, contextMenuService); this.settings = options.viewletSettings; this.viewletState = options.viewletState; diff --git a/src/vs/workbench/parts/files/browser/views/openEditorsView.ts b/src/vs/workbench/parts/files/browser/views/openEditorsView.ts index cc78b196c58..d15bc3aef00 100644 --- a/src/vs/workbench/parts/files/browser/views/openEditorsView.ts +++ b/src/vs/workbench/parts/files/browser/views/openEditorsView.ts @@ -18,7 +18,7 @@ import { IConfigurationService } from 'vs/platform/configuration/common/configur import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { IEditorStacksModel, IStacksModelChangeEvent, IEditorGroup } from 'vs/workbench/common/editor'; import { SaveAllAction } from 'vs/workbench/parts/files/browser/fileActions'; -import { AdaptiveCollapsibleViewletView } from 'vs/workbench/parts/views/browser/views'; +import { CollapsibleView, IViewletViewOptions } from 'vs/workbench/parts/views/browser/views'; import { IFilesConfiguration, VIEWLET_ID, OpenEditorsFocussedContext, ExplorerFocussedContext } from 'vs/workbench/parts/files/common/files'; import { ITextFileService, AutoSaveMode } from 'vs/workbench/services/textfile/common/textfiles'; import { IViewletService } from 'vs/workbench/services/viewlet/browser/viewlet'; @@ -33,11 +33,11 @@ import { EditorGroup } from 'vs/workbench/common/editor/editorStacksModel'; import { attachListStyler, attachStylerCallback } from 'vs/platform/theme/common/styler'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { badgeBackground, badgeForeground, contrastBorder } from 'vs/platform/theme/common/colorRegistry'; -import { IViewOptions } from 'vs/workbench/parts/views/browser/viewsRegistry'; +import { ViewSizing } from 'vs/base/browser/ui/splitview/splitview'; const $ = dom.$; -export class OpenEditorsView extends AdaptiveCollapsibleViewletView { +export class OpenEditorsView extends CollapsibleView { private static DEFAULT_VISIBLE_OPEN_EDITORS = 9; private static DEFAULT_DYNAMIC_HEIGHT = true; @@ -56,7 +56,7 @@ export class OpenEditorsView extends AdaptiveCollapsibleViewletView { private openEditorsFocussedContext: IContextKey; private explorerFocussedContext: IContextKey; - constructor(readonly id: string, options: IViewOptions, + constructor(options: IViewletViewOptions, @IInstantiationService private instantiationService: IInstantiationService, @IContextMenuService contextMenuService: IContextMenuService, @ITextFileService private textFileService: ITextFileService, @@ -69,7 +69,12 @@ export class OpenEditorsView extends AdaptiveCollapsibleViewletView { @IViewletService private viewletService: IViewletService, @IThemeService private themeService: IThemeService ) { - super(options.actionRunner, OpenEditorsView.computeExpandedBodySize(editorGroupService.getStacksModel()), options.collapsed, nls.localize({ key: 'openEditosrSection', comment: ['Open is an adjective'] }, "Open Editors Section"), keybindingService, contextMenuService); + super({ + ...options, + ariaHeaderLabel: nls.localize({ key: 'openEditosrSection', comment: ['Open is an adjective'] }, "Open Editors Section"), + sizing: ViewSizing.Fixed, + initialBodySize: OpenEditorsView.computeExpandedBodySize(editorGroupService.getStacksModel()) + }, keybindingService, contextMenuService); this.model = editorGroupService.getStacksModel(); @@ -223,7 +228,7 @@ export class OpenEditorsView extends AdaptiveCollapsibleViewletView { private structuralTreeUpdate(): void { // View size - this.expandedBodySize = this.getExpandedBodySize(this.model); + this.setBodySize(this.getExpandedBodySize(this.model)); // Show groups only if there is more than 1 group const treeInput = this.model.groups.length === 1 ? this.model.groups[0] : this.model; // TODO@Isidor temporary workaround due to a partial tree refresh issue @@ -277,7 +282,7 @@ export class OpenEditorsView extends AdaptiveCollapsibleViewletView { } // Adjust expanded body size - this.expandedBodySize = this.getExpandedBodySize(this.model); + this.setBodySize(this.getExpandedBodySize(this.model)); } private updateDirtyIndicator(): void { diff --git a/src/vs/workbench/parts/views/browser/treeView.ts b/src/vs/workbench/parts/views/browser/treeView.ts index 789a66389d7..fd5eb54fed1 100644 --- a/src/vs/workbench/parts/views/browser/treeView.ts +++ b/src/vs/workbench/parts/views/browser/treeView.ts @@ -6,7 +6,6 @@ import 'vs/css!./media/views'; import Event, { Emitter } from 'vs/base/common/event'; import { IDisposable, dispose, empty as EmptyDisposable, toDisposable } from 'vs/base/common/lifecycle'; -import { CollapsibleViewletView } from 'vs/workbench/parts/views/browser/views'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { TPromise } from 'vs/base/common/winjs.base'; import * as DOM from 'vs/base/browser/dom'; @@ -26,13 +25,14 @@ import { IProgressService } from 'vs/platform/progress/common/progress'; import { ITree, IDataSource, IRenderer, ContextMenuEvent } from 'vs/base/parts/tree/browser/tree'; import { IContextKeyService, IContextKey } from 'vs/platform/contextkey/common/contextkey'; import { ActionItem } from 'vs/base/browser/ui/actionbar/actionbar'; -import { ViewsRegistry, IViewOptions } from 'vs/workbench/parts/views/browser/viewsRegistry'; +import { ViewsRegistry } from 'vs/workbench/parts/views/browser/viewsRegistry'; import { ITreeViewDataProvider, ITreeItem, TreeItemCollapsibleState, TreeViewItemHandleArg } from 'vs/workbench/parts/views/common/views'; import { IExtensionService } from 'vs/platform/extensions/common/extensions'; -import { CollapsibleState } from 'vs/base/browser/ui/splitview/splitview'; +import { CollapsibleState, ViewSizing } from 'vs/base/browser/ui/splitview/splitview'; +import { CollapsibleView, IViewletViewOptions } from 'vs/workbench/parts/views/browser/views'; import { ICommandService } from 'vs/platform/commands/common/commands'; -export class TreeView extends CollapsibleViewletView { +export class TreeView extends CollapsibleView { private menus: Menus; private viewFocusContext: IContextKey; @@ -44,9 +44,8 @@ export class TreeView extends CollapsibleViewletView { private disposables: IDisposable[] = []; constructor( - readonly id: string, - private options: IViewOptions, - @IMessageService messageService: IMessageService, + private options: IViewletViewOptions, + @IMessageService private messageService: IMessageService, @IKeybindingService keybindingService: IKeybindingService, @IContextMenuService contextMenuService: IContextMenuService, @IInstantiationService private instantiationService: IInstantiationService, @@ -56,7 +55,7 @@ export class TreeView extends CollapsibleViewletView { @IExtensionService private extensionService: IExtensionService, @ICommandService private commandService: ICommandService ) { - super(options.actionRunner, options.collapsed, options.name, messageService, keybindingService, contextMenuService); + super({ ...options, ariaHeaderLabel: options.name, sizing: ViewSizing.Flexible, collapsed: options.collapsed === void 0 ? true : options.collapsed }, keybindingService, contextMenuService); this.menus = this.instantiationService.createInstance(Menus, this.id); this.viewFocusContext = this.contextKeyService.createKey(this.id, void 0); this.menus.onDidChangeTitle(() => this.updateActions(), this, this.disposables); @@ -128,21 +127,27 @@ export class TreeView extends CollapsibleViewletView { return super.setVisible(visible); } - public setInput(): TPromise { - if (this.listenToDataProvider()) { - this.treeInputPromise = this.tree.setInput(new Root()); - return this.treeInputPromise; - } - this.treeInputPromise = new TPromise((c, e) => { - this.dataProviderRegisteredListener = ViewsRegistry.onTreeViewDataProviderRegistered(id => { - if (this.id === id) { - if (this.listenToDataProvider()) { - this.tree.setInput(new Root()).then(() => c(null)); - this.dataProviderRegisteredListener.dispose(); + public create(): TPromise { + return super.create().then(() => this.setInput()); + } + + private setInput(): TPromise { + if (this.tree && !this.treeInputPromise) { + if (this.listenToDataProvider()) { + this.treeInputPromise = this.tree.setInput(new Root()); + return this.treeInputPromise; + } + this.treeInputPromise = new TPromise((c, e) => { + this.dataProviderRegisteredListener = ViewsRegistry.onTreeViewDataProviderRegistered(id => { + if (this.id === id) { + if (this.listenToDataProvider()) { + this.tree.setInput(new Root()).then(() => c(null)); + this.dataProviderRegisteredListener.dispose(); + } } - } + }); }); - }); + } return TPromise.as(null); } diff --git a/src/vs/workbench/parts/views/browser/views.ts b/src/vs/workbench/parts/views/browser/views.ts index 01aa578329c..382e14ed695 100644 --- a/src/vs/workbench/parts/views/browser/views.ts +++ b/src/vs/workbench/parts/views/browser/views.ts @@ -20,170 +20,77 @@ import { DelayedDragHandler } from 'vs/base/browser/dnd'; import { ToolBar } from 'vs/base/browser/ui/toolbar/toolbar'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { IContextMenuService } from 'vs/platform/contextview/browser/contextView'; -import { IMessageService } from 'vs/platform/message/common/message'; -import { CollapsibleView, CollapsibleState, FixedCollapsibleView, IView, SplitView } from 'vs/base/browser/ui/splitview/splitview'; -import { ViewsRegistry, ViewLocation, IViewDescriptor, IViewOptions } from 'vs/workbench/parts/views/browser/viewsRegistry'; +import { AbstractCollapsibleView, CollapsibleState, IView as IBaseView, SplitView, ViewSizing } from 'vs/base/browser/ui/splitview/splitview'; +import { ViewsRegistry, ViewLocation, IViewDescriptor } from 'vs/workbench/parts/views/browser/viewsRegistry'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; -export interface IViewletViewOptions extends IViewOptions { - viewletSettings: any; -} +export interface IViewOptions { -export interface IViewletView extends IView, IThemable { - id?: string; - create(): TPromise; - setVisible(visible: boolean): TPromise; - getActions(): IAction[]; - getSecondaryActions(): IAction[]; - getActionItem(action: IAction): IActionItem; - showHeader(): boolean; - hideHeader(): boolean; - shutdown(): void; - focusBody(): void; - isExpanded(): boolean; - expand(): void; - collapse(): void; - getOptimalWidth(): number; -} + id: string; -/** - * The AdaptiveCollapsibleViewletView can grow with the content inside dynamically. - */ -export abstract class AdaptiveCollapsibleViewletView extends FixedCollapsibleView implements IViewletView { - protected treeContainer: HTMLElement; - protected tree: ITree; - protected toDispose: IDisposable[]; - protected isVisible: boolean; - protected toolBar: ToolBar; - protected actionRunner: IActionRunner; - protected isDisposed: boolean; + name: string; - private dragHandler: DelayedDragHandler; + actionRunner: IActionRunner; - constructor( - actionRunner: IActionRunner, - initialBodySize: number, - collapsed: boolean, - private viewName: string, - protected keybindingService: IKeybindingService, - protected contextMenuService: IContextMenuService - ) { - super({ - expandedBodySize: initialBodySize, - initialState: collapsed ? CollapsibleState.COLLAPSED : CollapsibleState.EXPANDED, - ariaHeaderLabel: viewName, - headerSize: 22, - }); - - this.actionRunner = actionRunner; - this.toDispose = []; - } + collapsed: boolean; - protected changeState(state: CollapsibleState): void { - updateTreeVisibility(this.tree, state === CollapsibleState.EXPANDED); +} - super.changeState(state); - } +export interface IViewConstructorSignature { - public create(): TPromise { - return TPromise.as(null); - } + new (options: IViewOptions, ...services: { _serviceBrand: any; }[]): IView; - public renderHeader(container: HTMLElement): void { +} - // Tool bar - this.toolBar = new ToolBar($('div.actions').appendTo(container).getHTMLElement(), this.contextMenuService, { - orientation: ActionsOrientation.HORIZONTAL, - actionItemProvider: (action) => this.getActionItem(action), - ariaLabel: nls.localize('viewToolbarAriaLabel', "{0} actions", this.viewName), - getKeyBinding: (action) => this.keybindingService.lookupKeybinding(action.id) - }); - this.toolBar.actionRunner = this.actionRunner; - this.updateActions(); +export interface IView extends IBaseView, IThemable { - // Expand on drag over - this.dragHandler = new DelayedDragHandler(container, () => { - if (!this.isExpanded()) { - this.expand(); - } - }); - } + id: string; - protected updateActions(): void { - this.toolBar.setActions(prepareActions(this.getActions()), prepareActions(this.getSecondaryActions()))(); - } + create(): TPromise; - protected renderViewTree(container: HTMLElement): HTMLElement { - return renderViewTree(container); - } + setVisible(visible: boolean): TPromise; - public getViewer(): ITree { - return this.tree; - } + getActions(): IAction[]; - public setVisible(visible: boolean): TPromise { - this.isVisible = visible; + getSecondaryActions(): IAction[]; - updateTreeVisibility(this.tree, visible && this.state === CollapsibleState.EXPANDED); + getActionItem(action: IAction): IActionItem; - return TPromise.as(null); - } + showHeader(): boolean; - public focusBody(): void { - focus(this.tree); - } + hideHeader(): boolean; - protected reveal(element: any, relativeTop?: number): TPromise { - return reveal(this.tree, element, relativeTop); - } + focusBody(): void; - protected layoutBody(size: number): void { - this.treeContainer.style.height = size + 'px'; - this.tree.layout(size); - } + isExpanded(): boolean; - public getActions(): IAction[] { - return []; - } + expand(): void; - public getSecondaryActions(): IAction[] { - return []; - } + collapse(): void; - public getActionItem(action: IAction): IActionItem { - return null; - } + getOptimalWidth(): number; - public shutdown(): void { - // Subclass to implement - } + shutdown(): void; +} - public getOptimalWidth(): number { - return 0; - } +export interface ICollapsibleViewOptions extends IViewOptions { - public dispose(): void { - this.isDisposed = true; - this.treeContainer = null; - this.tree.dispose(); + sizing: ViewSizing; - this.dragHandler.dispose(); + initialBodySize?: number; - this.toDispose = dispose(this.toDispose); +} - if (this.toolBar) { - this.toolBar.dispose(); - } +export abstract class CollapsibleView extends AbstractCollapsibleView implements IView { - super.dispose(); - } -} + readonly id: string; -export abstract class CollapsibleViewletView extends CollapsibleView implements IViewletView { + protected viewName: string; protected treeContainer: HTMLElement; protected tree: ITree; protected toDispose: IDisposable[]; @@ -195,28 +102,25 @@ export abstract class CollapsibleViewletView extends CollapsibleView implements private dragHandler: DelayedDragHandler; constructor( - actionRunner: IActionRunner, - collapsed: boolean, - private viewName: string, - protected messageService: IMessageService, + options: ICollapsibleViewOptions, protected keybindingService: IKeybindingService, - protected contextMenuService: IContextMenuService, - headerSize?: number, - minimumSize?: number + protected contextMenuService: IContextMenuService ) { super({ - minimumSize: minimumSize === void 0 ? 5 * 22 : minimumSize, - initialState: collapsed ? CollapsibleState.COLLAPSED : CollapsibleState.EXPANDED, - ariaHeaderLabel: viewName, - headerSize + ariaHeaderLabel: options.name, + sizing: options.sizing, + bodySize: options.initialBodySize ? options.initialBodySize : 4 * 22, + initialState: options.collapsed ? CollapsibleState.COLLAPSED : CollapsibleState.EXPANDED, }); - this.actionRunner = actionRunner; + this.id = options.id; + this.viewName = options.name; + this.actionRunner = options.actionRunner; this.toDispose = []; } protected changeState(state: CollapsibleState): void { - updateTreeVisibility(this.tree, state === CollapsibleState.EXPANDED); + this.updateTreeVisibility(this.tree, state === CollapsibleState.EXPANDED); super.changeState(state); } @@ -250,7 +154,10 @@ export abstract class CollapsibleViewletView extends CollapsibleView implements } protected renderViewTree(container: HTMLElement): HTMLElement { - return renderViewTree(container); + const treeContainer = document.createElement('div'); + container.appendChild(treeContainer); + + return treeContainer; } public getViewer(): ITree { @@ -258,19 +165,24 @@ export abstract class CollapsibleViewletView extends CollapsibleView implements } public setVisible(visible: boolean): TPromise { - this.isVisible = visible; - - updateTreeVisibility(this.tree, visible && this.state === CollapsibleState.EXPANDED); + if (this.isVisible !== visible) { + this.isVisible = visible; + this.updateTreeVisibility(this.tree, visible && this.state === CollapsibleState.EXPANDED); + } return TPromise.as(null); } public focusBody(): void { - focus(this.tree); + this.focusTree(); } protected reveal(element: any, relativeTop?: number): TPromise { - return reveal(this.tree, element, relativeTop); + if (!this.tree) { + return TPromise.as(null); // return early if viewlet has not yet been created + } + + return this.tree.reveal(element, relativeTop); } public layoutBody(size: number): void { @@ -315,68 +227,61 @@ export abstract class CollapsibleViewletView extends CollapsibleView implements super.dispose(); } -} -function updateTreeVisibility(tree: ITree, isVisible: boolean): void { - if (!tree) { - return; - } + private updateTreeVisibility(tree: ITree, isVisible: boolean): void { + if (!tree) { + return; + } - if (isVisible) { - $(tree.getHTMLElement()).show(); - } else { - $(tree.getHTMLElement()).hide(); // make sure the tree goes out of the tabindex world by hiding it - } + if (isVisible) { + $(tree.getHTMLElement()).show(); + } else { + $(tree.getHTMLElement()).hide(); // make sure the tree goes out of the tabindex world by hiding it + } - if (isVisible) { - tree.onVisible(); - } else { - tree.onHidden(); + if (isVisible) { + tree.onVisible(); + } else { + tree.onHidden(); + } } -} -function focus(tree: ITree): void { - if (!tree) { - return; // return early if viewlet has not yet been created - } + private focusTree(): void { + if (!this.tree) { + return; // return early if viewlet has not yet been created + } - // Make sure the current selected element is revealed - const selection = tree.getSelection(); - if (selection.length > 0) { - reveal(tree, selection[0], 0.5).done(null, errors.onUnexpectedError); - } + // Make sure the current selected element is revealed + const selection = this.tree.getSelection(); + if (selection.length > 0) { + this.reveal(selection[0], 0.5).done(null, errors.onUnexpectedError); + } - // Pass Focus to Viewer - tree.DOMFocus(); + // Pass Focus to Viewer + this.tree.DOMFocus(); + } } -function renderViewTree(container: HTMLElement): HTMLElement { - const treeContainer = document.createElement('div'); - container.appendChild(treeContainer); - - return treeContainer; -} +export interface IViewletViewOptions extends IViewOptions { -function reveal(tree: ITree, element: any, relativeTop?: number): TPromise { - if (!tree) { - return TPromise.as(null); // return early if viewlet has not yet been created - } + viewletSettings: any; - return tree.reveal(element, relativeTop); } export interface IViewState { + collapsed: boolean; + size: number; } export class ComposedViewsViewlet extends Viewlet { protected viewletContainer: HTMLElement; - protected lastFocusedView: IViewletView; + protected lastFocusedView: IView; private splitView: SplitView; - private views: IViewletView[]; + protected views: IView[]; private dimension: Dimension; private viewletSettings: any; @@ -390,7 +295,8 @@ export class ComposedViewsViewlet extends Viewlet { @IStorageService protected storageService: IStorageService, @IInstantiationService protected instantiationService: IInstantiationService, @IThemeService themeService: IThemeService, - @IWorkspaceContextService protected contextService: IWorkspaceContextService + @IWorkspaceContextService protected contextService: IWorkspaceContextService, + @IContextKeyService protected contextKeyService: IContextKeyService ) { super(id, telemetryService, themeService); @@ -398,8 +304,9 @@ export class ComposedViewsViewlet extends Viewlet { this.viewletSettings = this.getMemento(storageService, Scope.WORKSPACE); this.viewsStates = this.loadViewsStates(); - this._register(ViewsRegistry.onViewsRegistered(viewDescriptors => this.createViews(viewDescriptors.filter(viewDescriptor => ViewLocation.Explorer === viewDescriptor.location)))); - this._register(ViewsRegistry.onViewsDeregistered(viewDescriptors => this.removeViews(viewDescriptors.filter(viewDescriptor => ViewLocation.Explorer === viewDescriptor.location)))); + this._register(ViewsRegistry.onViewsRegistered(viewDescriptors => this.addViews(viewDescriptors.filter(viewDescriptor => this.location === viewDescriptor.location)))); + this._register(ViewsRegistry.onViewsDeregistered(viewDescriptors => this.updateViews([], viewDescriptors.filter(viewDescriptor => this.location === viewDescriptor.location)))); + this._register(contextKeyService.onDidChangeContext(keys => this.onContextChanged(keys))); } public create(parent: Builder): TPromise { @@ -407,13 +314,13 @@ export class ComposedViewsViewlet extends Viewlet { this.viewletContainer = DOM.append(parent.getHTMLElement(), DOM.$('')); this.splitView = this._register(new SplitView(this.viewletContainer)); - this._register(this.splitView.onFocus((view: IViewletView) => this.lastFocusedView = view)); + this._register(this.splitView.onFocus((view: IView) => this.lastFocusedView = view)); - const views = ViewsRegistry.getViews(ViewLocation.Explorer); - return this.createViews(views) - .then(() => this.lastFocusedView = this.views[0]) - .then(() => this.setVisible(this.isVisible())) - .then(() => this.focus()); + return this.addViews(ViewsRegistry.getViews(this.location)) + .then(() => { + this.lastFocusedView = this.views[0]; + this.focus(); + }); } public getActions(): IAction[] { @@ -430,62 +337,70 @@ export class ComposedViewsViewlet extends Viewlet { return []; } - private createViews(viewDescriptors: IViewDescriptor[]): TPromise { - if (!this.splitView || !viewDescriptors.length) { + private addViews(viewDescriptors: IViewDescriptor[]): TPromise { + viewDescriptors = viewDescriptors.filter(viewDescriptor => this.contextKeyService.contextMatchesRules(viewDescriptor.when)); + return this.updateViews(viewDescriptors, []); + } + + private updateViews(toAdd: IViewDescriptor[], toRemove: IViewDescriptor[]): TPromise { + if (!this.splitView || (!toAdd.length && !toRemove.length)) { return TPromise.as(null); } - const views = []; - const sorted = ViewsRegistry.getViews(this.location).sort((a, b) => { - if (b.order === void 0 || b.order === null) { - return -1; + for (const view of this.views) { + let viewState = this.viewsStates.get(view.id); + if (!viewState || view.size !== viewState.size || !view.isExpanded() !== viewState.collapsed) { + viewState = this.getViewState(view); + this.viewsStates.set(view.id, viewState); + this.splitView.updateWeight(view, viewState.size); } - if (a.order === void 0 || a.order === null) { - return 1; + } + + if (toRemove.length) { + for (const viewDescriptor of toRemove) { + let view = this.getView(viewDescriptor.id); + if (view) { + this.views.splice(this.views.indexOf(view), 1); + this.splitView.removeView(view); + } } - return a.order - b.order; - }); - for (const viewDescriptor of viewDescriptors) { + } + + const toCreate = []; + const viewsInOrder = ViewsRegistry.getViews(this.location) + .filter(viewDescriptor => this.contextKeyService.contextMatchesRules(viewDescriptor.when)) + .sort((a, b) => { + if (b.order === void 0 || b.order === null) { + return -1; + } + if (a.order === void 0 || a.order === null) { + return 1; + } + return a.order - b.order; + }); + + for (const viewDescriptor of toAdd) { let viewState = this.viewsStates.get(viewDescriptor.id); - let index = sorted.indexOf(viewDescriptor); + let index = viewsInOrder.indexOf(viewDescriptor); const view = this.createView(viewDescriptor, { + id: viewDescriptor.id, name: viewDescriptor.name, actionRunner: this.getActionRunner(), - collapsed: viewState ? viewState.collapsed : true, + collapsed: viewState ? viewState.collapsed : void 0, viewletSettings: this.viewletSettings }); - if (index !== -1) { - this.views.splice(index, 0, view); - } else { - this.views.push(view); - } - views.push(view); + toCreate.push(view); + + this.views.splice(index, 0, view); attachHeaderViewStyler(view, this.themeService); - this.splitView.addView(view, viewState ? viewState.size : void 0, index); + this.splitView.addView(view, viewState && viewState.size ? Math.max(viewState.size, 1) : viewDescriptor.size, index); } - return TPromise.join(views.map(view => view.create())) + return TPromise.join(toCreate.map(view => view.create())) .then(() => this.onViewsUpdated()); } - - private removeViews(viewDescriptors: IViewDescriptor[]): void { - if (!this.splitView || !viewDescriptors.length) { - return; - } - - for (const viewDescriptor of viewDescriptors) { - let view = this.getView(viewDescriptor.id); - if (view) { - this.views.splice(this.views.indexOf(view), 1); - this.splitView.removeView(view); - } - } - - this.onViewsUpdated(); - } - - private onViewsUpdated(): void { + private onViewsUpdated(): TPromise { if (this.views.length === 1) { this.views[0].hideHeader(); if (!this.views[0].isExpanded()) { @@ -503,6 +418,28 @@ export class ComposedViewsViewlet extends Viewlet { // Update title area since the title actions have changed. this.updateTitleArea(); + + return this.setVisible(this.isVisible()); + } + + private onContextChanged(keys: string[]): void { + let viewsToCreate: IViewDescriptor[] = []; + let viewsToRemove: IViewDescriptor[] = []; + + for (const viewDescriptor of ViewsRegistry.getViews(this.location)) { + const view = this.getView(viewDescriptor.id); + if (this.contextKeyService.contextMatchesRules(viewDescriptor.when)) { + if (!view) { + viewsToCreate.push(viewDescriptor); + } + } else { + if (view) { + viewsToRemove.push(viewDescriptor); + } + } + } + + this.updateViews(viewsToCreate, viewsToRemove); } public setVisible(visible: boolean): TPromise { @@ -521,6 +458,10 @@ export class ComposedViewsViewlet extends Viewlet { public layout(dimension: Dimension): void { this.dimension = dimension; this.splitView.layout(dimension.height); + for (const view of this.views) { + let viewState = this.getViewState(view); + this.viewsStates.set(view.id, viewState); + } } public getOptimalWidth(): number { @@ -537,10 +478,7 @@ export class ComposedViewsViewlet extends Viewlet { protected saveViewsStates(): void { const viewletState = this.views.reduce((result, view) => { - result[view.id] = { - collapsed: !view.isExpanded(), - size: view.size > 0 ? view.size : void 0 - }; + result[view.id] = this.getViewState(view); return result; }, {}); this.storageService.store(this.viewletStateStorageId, JSON.stringify(viewletState), this.contextService.hasWorkspace() ? StorageScope.WORKSPACE : StorageScope.GLOBAL); @@ -554,11 +492,20 @@ export class ComposedViewsViewlet extends Viewlet { }, new Map()); } - protected createView(viewDescriptor: IViewDescriptor, options: IViewletViewOptions): IViewletView { - return this.instantiationService.createInstance(viewDescriptor.ctor, viewDescriptor.id, options); + protected createView(viewDescriptor: IViewDescriptor, options: IViewletViewOptions): IView { + return this.instantiationService.createInstance(viewDescriptor.ctor, options); } - protected getView(id: string): IViewletView { + protected getView(id: string): IView { return this.views.filter(view => view.id === id)[0]; } + + private getViewState(view: IView): IViewState { + const collapsed = !view.isExpanded(); + const size = collapsed && view instanceof CollapsibleView ? view.previousSize : view.size; + return { + collapsed, + size: size && size > 0 ? size : void 0 + }; + } } \ No newline at end of file diff --git a/src/vs/workbench/parts/views/browser/viewsExtensionPoint.ts b/src/vs/workbench/parts/views/browser/viewsExtensionPoint.ts index a5f21d877ce..30715762ea6 100644 --- a/src/vs/workbench/parts/views/browser/viewsExtensionPoint.ts +++ b/src/vs/workbench/parts/views/browser/viewsExtensionPoint.ts @@ -10,6 +10,7 @@ import { IJSONSchema } from 'vs/base/common/jsonSchema'; import { ExtensionMessageCollector, ExtensionsRegistry } from 'vs/platform/extensions/common/extensionsRegistry'; import { ViewLocation, ViewsRegistry } from 'vs/workbench/parts/views/browser/viewsRegistry'; import { TreeView } from 'vs/workbench/parts/views/browser/treeView'; +import { ContextKeyExpr } from 'vs/platform/contextkey/common/contextkey'; namespace schema { @@ -18,6 +19,7 @@ namespace schema { export interface IUserFriendlyViewDescriptor { id: string; name: string; + when?: string; } export function parseLocation(value: string): ViewLocation { @@ -42,6 +44,10 @@ namespace schema { collector.error(localize('requirestring', "property `{0}` is mandatory and must be of type `string`", 'label')); return false; } + if (descriptor.when && typeof descriptor.when !== 'string') { + collector.error(localize('optstring', "property `{0}` can be omitted or must be of type `string`", 'when')); + return false; + } } return true; @@ -57,7 +63,11 @@ namespace schema { name: { description: localize('vscode.extension.contributes.view.name', 'The human-readable name of the view. Will be shown'), type: 'string' - } + }, + when: { + description: localize('vscode.extension.contributes.view.when', 'Condition which must be true to show this view'), + type: 'string' + }, } }; @@ -93,7 +103,8 @@ ExtensionsRegistry.registerExtensionPoint<{ [loc: string]: schema.IUserFriendlyV id: item.id, name: item.name, ctor: TreeView, - location + location, + when: ContextKeyExpr.deserialize(item.when) })); ViewsRegistry.registerViews(viewDescriptors); }); diff --git a/src/vs/workbench/parts/views/browser/viewsRegistry.ts b/src/vs/workbench/parts/views/browser/viewsRegistry.ts index ac12eb4be5b..f129e603889 100644 --- a/src/vs/workbench/parts/views/browser/viewsRegistry.ts +++ b/src/vs/workbench/parts/views/browser/viewsRegistry.ts @@ -4,13 +4,14 @@ *--------------------------------------------------------------------------------------------*/ import Event, { Emitter } from 'vs/base/common/event'; -import { IActionRunner } from 'vs/base/common/actions'; -import { IViewletView as IView } from 'vs/workbench/parts/views/browser/views'; +import { IViewConstructorSignature } from 'vs/workbench/parts/views/browser/views'; import { ITreeViewDataProvider } from 'vs/workbench/parts/views/common/views'; +import { ContextKeyExpr } from 'vs/platform/contextkey/common/contextkey'; export class ViewLocation { static readonly Explorer = new ViewLocation('explorer'); + static readonly Debug = new ViewLocation('debug'); constructor(private _id: string) { } @@ -20,18 +21,6 @@ export class ViewLocation { } } -export interface IViewOptions { - name: string; - actionRunner: IActionRunner; - collapsed: boolean; -} - -export interface IViewConstructorSignature { - - new (id: string, options: IViewOptions, ...services: { _serviceBrand: any; }[]): IView; - -} - export interface IViewDescriptor { readonly id: string; @@ -42,8 +31,11 @@ export interface IViewDescriptor { readonly ctor: IViewConstructorSignature; + readonly when?: ContextKeyExpr; + readonly order?: number; + readonly size?: number; } export interface IViewsRegistry { -- GitLab From 2792c5cd97c44b9e299008a62a071ed54bc9cc06 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 9 Jun 2017 11:10:18 +0200 Subject: [PATCH 0671/1347] multiroot - send telemetry event when workspace#rootPath is accessed --- src/vs/workbench/api/node/extHost.api.impl.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index f6f4099db43..9ae487ec77b 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -377,6 +377,10 @@ export function createApiFactory( // namespace: workspace const workspace: typeof vscode.workspace = { get rootPath() { + telemetryService.publicLog('api-getter', { + name: 'workspace#rootPath', + extension: extension.id + }); return extHostWorkspace.getPath(); }, set rootPath(value) { -- GitLab From 6122faea48beed0319efa1e3dd295404fe7bf3d0 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 9 Jun 2017 11:15:21 +0200 Subject: [PATCH 0672/1347] debt - remove "over-api", align styles --- src/vs/workbench/api/node/extHost.api.impl.ts | 26 ++++--------------- 1 file changed, 5 insertions(+), 21 deletions(-) diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index 9ae487ec77b..cef1654dca7 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ 'use strict'; -import { Emitter, mapEvent } from 'vs/base/common/event'; +import { Emitter } from 'vs/base/common/event'; import { TrieMap } from 'vs/base/common/map'; import { score } from 'vs/editor/common/modes/languageSelector'; import * as Platform from 'vs/base/common/platform'; @@ -457,24 +457,11 @@ export function createApiFactory( }) }; - class SCM { - - get activeSourceControl() { - return extHostSCM.activeProvider; - } - - get onDidChangeActiveSourceControl() { - return extHostSCM.onDidChangeActiveProvider; - } - + // namespace: scm + const scm: typeof vscode.scm = { get inputBox() { return extHostSCM.inputBox; - } - - get onDidAcceptInputValue() { - return mapEvent(extHostSCM.inputBox.onDidAccept, () => extHostSCM.inputBox); - } - + }, createSourceControl(id: string, label: string) { telemetryService.publicLog('registerSCMProvider', { extensionId: extension.id, @@ -484,10 +471,7 @@ export function createApiFactory( return extHostSCM.createSourceControl(id, label); } - } - - // namespace: scm - const scm: typeof vscode.scm = new SCM(); + }; return { version: pkg.version, -- GitLab From 7a9a71c716ef7942a936aaaccdf0b87cf66ec347 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Fri, 9 Jun 2017 12:10:45 +0200 Subject: [PATCH 0673/1347] :lipstick: windows main --- src/vs/code/electron-main/windows.ts | 365 ++++++++++++++++----------- 1 file changed, 214 insertions(+), 151 deletions(-) diff --git a/src/vs/code/electron-main/windows.ts b/src/vs/code/electron-main/windows.ts index 93a7c4c7120..754a63af36d 100644 --- a/src/vs/code/electron-main/windows.ts +++ b/src/vs/code/electron-main/windows.ts @@ -7,7 +7,6 @@ import * as path from 'path'; import * as fs from 'original-fs'; -import * as platform from 'vs/base/common/platform'; import * as nls from 'vs/nls'; import * as arrays from 'vs/base/common/arrays'; import { assign, mixin } from 'vs/base/common/objects'; @@ -28,6 +27,7 @@ import { ITelemetryService, ITelemetryData } from 'vs/platform/telemetry/common/ import { isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; import { IWindowsMainService, IOpenConfiguration } from "vs/platform/windows/electron-main/windows"; import { IHistoryMainService } from "vs/platform/history/electron-main/historyMainService"; +import { IProcessEnvironment, isLinux, isMacintosh } from "vs/base/common/platform"; enum WindowError { UNRESPONSIVE, @@ -55,6 +55,23 @@ const ReopenFoldersSetting = { NONE: 'none' }; +interface IOpenBrowserWindowOptions { + userEnv?: IProcessEnvironment; + cli?: ParsedArgs; + workspacePath?: string; + + initialStartup?: boolean; + + filesToOpen?: IPath[]; + filesToCreate?: IPath[]; + filesToDiff?: IPath[]; + + forceNewWindow?: boolean; + windowToUse?: CodeWindow; + + emptyWorkspaceBackupFolder?: string; +} + export class WindowsManager implements IWindowsMainService { _serviceBrand: any; @@ -63,7 +80,7 @@ export class WindowsManager implements IWindowsMainService { private static WINDOWS: CodeWindow[] = []; - private initialUserEnv: platform.IProcessEnvironment; + private initialUserEnv: IProcessEnvironment; private windowsState: IWindowsState; private lastClosedWindowState: IWindowState; @@ -96,7 +113,7 @@ export class WindowsManager implements IWindowsMainService { this.fileDialog = new FileDialog(environmentService, telemetryService, storageService, this); } - public ready(initialUserEnv: platform.IProcessEnvironment): void { + public ready(initialUserEnv: IProcessEnvironment): void { this.initialUserEnv = initialUserEnv; this.registerListeners(); @@ -187,7 +204,7 @@ export class WindowsManager implements IWindowsMainService { // Any non extension host window with same workspace else if (!win.isExtensionDevelopmentHost && !!win.openedWorkspacePath) { this.windowsState.openedFolders.forEach(o => { - if (isEqual(o.workspacePath, win.openedWorkspacePath, !platform.isLinux /* ignorecase */)) { + if (isEqual(o.workspacePath, win.openedWorkspacePath, !isLinux /* ignorecase */)) { o.uiState = state.uiState; } }); @@ -203,67 +220,23 @@ export class WindowsManager implements IWindowsMainService { } public open(openConfig: IOpenConfiguration): CodeWindow[] { - const windowConfig = this.configurationService.getConfiguration('window'); - - let iPathsToOpen: IPath[]; - const usedWindows: CodeWindow[] = []; - // Find paths from provided paths if any - if (openConfig.pathsToOpen && openConfig.pathsToOpen.length > 0) { - iPathsToOpen = openConfig.pathsToOpen.map(pathToOpen => { - const iPath = this.toIPath(pathToOpen, false, openConfig.cli && openConfig.cli.goto); - - // Warn if the requested path to open does not exist - if (!iPath) { - const options: Electron.ShowMessageBoxOptions = { - title: product.nameLong, - type: 'info', - buttons: [nls.localize('ok', "OK")], - message: nls.localize('pathNotExistTitle', "Path does not exist"), - detail: nls.localize('pathNotExistDetail', "The path '{0}' does not seem to exist anymore on disk.", pathToOpen), - noLink: true - }; - - const activeWindow = BrowserWindow.getFocusedWindow(); - if (activeWindow) { - dialog.showMessageBox(activeWindow, options); - } else { - dialog.showMessageBox(options); - } - } - - return iPath; - }); - - // get rid of nulls - iPathsToOpen = arrays.coalesce(iPathsToOpen); - - if (iPathsToOpen.length === 0) { - return null; // indicate to outside that open failed - } + // Find paths to open from config + const pathsToOpen = this.getPathsToOpen(openConfig); + if (!pathsToOpen) { + return null; // indicate to outside that open failed } - // Check for force empty - else if (openConfig.forceEmpty) { - iPathsToOpen = [Object.create(null)]; - } - - // Otherwise infer from command line arguments - else { - const ignoreFileNotFound = openConfig.cli._.length > 0; // we assume the user wants to create this file from command line - iPathsToOpen = this.cliToPaths(openConfig.cli, ignoreFileNotFound); - } - - let foldersToOpen = arrays.distinct(iPathsToOpen.filter(iPath => iPath.workspacePath && !iPath.filePath).map(iPath => iPath.workspacePath), folder => platform.isLinux ? folder : folder.toLowerCase()); // prevent duplicates + let foldersToOpen = arrays.distinct(pathsToOpen.filter(iPath => iPath.workspacePath && !iPath.filePath).map(iPath => iPath.workspacePath), folder => isLinux ? folder : folder.toLowerCase()); // prevent duplicates let foldersToRestore = (openConfig.initialStartup && !openConfig.cli.extensionDevelopmentPath) ? this.backupService.getWorkspaceBackupPaths() : []; let filesToOpen: IPath[] = []; let filesToDiff: IPath[] = []; - let emptyToOpen = iPathsToOpen.filter(iPath => !iPath.workspacePath && !iPath.filePath); + let emptyToOpen = pathsToOpen.filter(iPath => !iPath.workspacePath && !iPath.filePath); let emptyToRestore = (openConfig.initialStartup && !openConfig.cli.extensionDevelopmentPath) ? this.backupService.getEmptyWorkspaceBackupPaths() : []; - let filesToCreate = iPathsToOpen.filter(iPath => !!iPath.filePath && iPath.createFilePath); + let filesToCreate = pathsToOpen.filter(iPath => !!iPath.filePath && iPath.createFilePath); // Diff mode needs special care - const candidates = iPathsToOpen.filter(iPath => !!iPath.filePath && !iPath.createFilePath); + const candidates = pathsToOpen.filter(iPath => !!iPath.filePath && !iPath.createFilePath); if (openConfig.diffMode) { if (candidates.length === 2) { filesToDiff = candidates; @@ -279,12 +252,14 @@ export class WindowsManager implements IWindowsMainService { } // let the user settings override how folders are open in a new window or same window unless we are forced + const windowConfig = this.configurationService.getConfiguration('window'); let openFolderInNewWindow = (openConfig.preferNewWindow || openConfig.forceNewWindow) && !openConfig.forceReuseWindow; if (!openConfig.forceNewWindow && !openConfig.forceReuseWindow && windowConfig && (windowConfig.openFoldersInNewWindow === 'on' || windowConfig.openFoldersInNewWindow === 'off')) { openFolderInNewWindow = (windowConfig.openFoldersInNewWindow === 'on'); } // Handle files to open/diff or to create when we dont open a folder and we do not restore any folder/untitled from hot-exit + const usedWindows: CodeWindow[] = []; if (!foldersToOpen.length && !foldersToRestore.length && !emptyToRestore.length && (filesToOpen.length > 0 || filesToCreate.length > 0 || filesToDiff.length > 0)) { // let the user settings override how files are open in a new window or same window unless we are forced (not for extension development though) @@ -323,8 +298,16 @@ export class WindowsManager implements IWindowsMainService { // Otherwise open instance with files else { - const configuration = this.toConfiguration(openConfig, windowOrFolder, filesToOpen, filesToCreate, filesToDiff); - const browserWindow = this.openInBrowserWindow(configuration, true /* new window */); + const browserWindow = this.openInBrowserWindow({ + userEnv: openConfig.userEnv, + cli: openConfig.cli, + initialStartup: openConfig.initialStartup, + workspacePath: windowOrFolder, + filesToOpen, + filesToCreate, + filesToDiff, + forceNewWindow: true + }); usedWindows.push(browserWindow); openFolderInNewWindow = true; // any other folders to open must open in new window then @@ -337,7 +320,7 @@ export class WindowsManager implements IWindowsMainService { } // Handle folders to open (instructed and to restore) - let allFoldersToOpen = arrays.distinct([...foldersToOpen, ...foldersToRestore], folder => platform.isLinux ? folder : folder.toLowerCase()); // prevent duplicates + let allFoldersToOpen = arrays.distinct([...foldersToOpen, ...foldersToRestore], folder => isLinux ? folder : folder.toLowerCase()); // prevent duplicates if (allFoldersToOpen.length > 0) { // Check for existing instances @@ -362,12 +345,21 @@ export class WindowsManager implements IWindowsMainService { // Open remaining ones allFoldersToOpen.forEach(folderToOpen => { - if (windowsOnWorkspacePath.some(win => isEqual(win.openedWorkspacePath, folderToOpen, !platform.isLinux /* ignorecase */))) { + if (windowsOnWorkspacePath.some(win => isEqual(win.openedWorkspacePath, folderToOpen, !isLinux /* ignorecase */))) { return; // ignore folders that are already open } - const configuration = this.toConfiguration(openConfig, folderToOpen, filesToOpen, filesToCreate, filesToDiff); - const browserWindow = this.openInBrowserWindow(configuration, openFolderInNewWindow, openFolderInNewWindow ? void 0 : openConfig.windowToUse as CodeWindow); + const browserWindow = this.openInBrowserWindow({ + userEnv: openConfig.userEnv, + cli: openConfig.cli, + initialStartup: openConfig.initialStartup, + workspacePath: folderToOpen, + filesToOpen, + filesToCreate, + filesToDiff, + forceNewWindow: openFolderInNewWindow, + windowToUse: openFolderInNewWindow ? void 0 : openConfig.windowToUse as CodeWindow + }); usedWindows.push(browserWindow); // Reset these because we handled them @@ -382,8 +374,16 @@ export class WindowsManager implements IWindowsMainService { // Handle empty if (emptyToRestore.length > 0) { emptyToRestore.forEach(emptyWorkspaceBackupFolder => { - const configuration = this.toConfiguration(openConfig, void 0, filesToOpen, filesToCreate, filesToDiff); - const browserWindow = this.openInBrowserWindow(configuration, true /* new window */, null, emptyWorkspaceBackupFolder); + const browserWindow = this.openInBrowserWindow({ + userEnv: openConfig.userEnv, + cli: openConfig.cli, + initialStartup: openConfig.initialStartup, + filesToOpen, + filesToCreate, + filesToDiff, + forceNewWindow: true, + emptyWorkspaceBackupFolder + }); usedWindows.push(browserWindow); // Reset these because we handled them @@ -398,8 +398,13 @@ export class WindowsManager implements IWindowsMainService { // Only open empty if no empty workspaces were restored else if (emptyToOpen.length > 0) { emptyToOpen.forEach(() => { - const configuration = this.toConfiguration(openConfig); - const browserWindow = this.openInBrowserWindow(configuration, openFolderInNewWindow, openFolderInNewWindow ? void 0 : openConfig.windowToUse as CodeWindow); + const browserWindow = this.openInBrowserWindow({ + userEnv: openConfig.userEnv, + cli: openConfig.cli, + initialStartup: openConfig.initialStartup, + forceNewWindow: openFolderInNewWindow, + windowToUse: openFolderInNewWindow ? void 0 : openConfig.windowToUse as CodeWindow + }); usedWindows.push(browserWindow); openFolderInNewWindow = true; // any other folders to open must open in new window then @@ -411,7 +416,7 @@ export class WindowsManager implements IWindowsMainService { if (!usedWindows.some(w => w.isExtensionDevelopmentHost) && !openConfig.cli.diff) { const recentPaths: { path: string; isFile?: boolean; }[] = []; - iPathsToOpen.forEach(iPath => { + pathsToOpen.forEach(iPath => { if (iPath.filePath || iPath.workspacePath) { app.addRecentDocument(iPath.filePath || iPath.workspacePath); recentPaths.push({ path: iPath.filePath || iPath.workspacePath, isFile: !!iPath.filePath }); @@ -424,57 +429,117 @@ export class WindowsManager implements IWindowsMainService { } // Emit events - this._onPathsOpen.fire(iPathsToOpen); + this._onPathsOpen.fire(pathsToOpen); return arrays.distinct(usedWindows); } - public openExtensionDevelopmentHostWindow(openConfig: IOpenConfiguration): void { + private getPathsToOpen(openConfig: IOpenConfiguration): IPath[] { + let iPathsToOpen: IPath[]; - // Reload an existing extension development host window on the same path - // We currently do not allow more than one extension development window - // on the same extension path. - let res = WindowsManager.WINDOWS.filter(w => w.config && isEqual(w.config.extensionDevelopmentPath, openConfig.cli.extensionDevelopmentPath, !platform.isLinux /* ignorecase */)); - if (res && res.length === 1) { - this.reload(res[0], openConfig.cli); - res[0].focus(); // make sure it gets focus and is restored + // Find paths from provided paths if any + if (openConfig.pathsToOpen && openConfig.pathsToOpen.length > 0) { + iPathsToOpen = openConfig.pathsToOpen.map(pathToOpen => { + const iPath = this.toIPath(pathToOpen, false, openConfig.cli && openConfig.cli.goto); - return; - } + // Warn if the requested path to open does not exist + if (!iPath) { + const options: Electron.ShowMessageBoxOptions = { + title: product.nameLong, + type: 'info', + buttons: [nls.localize('ok', "OK")], + message: nls.localize('pathNotExistTitle', "Path does not exist"), + detail: nls.localize('pathNotExistDetail', "The path '{0}' does not seem to exist anymore on disk.", pathToOpen), + noLink: true + }; - // Fill in previously opened workspace unless an explicit path is provided and we are not unit testing - if (openConfig.cli._.length === 0 && !openConfig.cli.extensionTestsPath) { - const workspaceToOpen = this.windowsState.lastPluginDevelopmentHostWindow && this.windowsState.lastPluginDevelopmentHostWindow.workspacePath; - if (workspaceToOpen) { - openConfig.cli._ = [workspaceToOpen]; + const activeWindow = BrowserWindow.getFocusedWindow(); + if (activeWindow) { + dialog.showMessageBox(activeWindow, options); + } else { + dialog.showMessageBox(options); + } + } + + return iPath; + }); + + // get rid of nulls + iPathsToOpen = arrays.coalesce(iPathsToOpen); + + if (iPathsToOpen.length === 0) { + return null; // indicate to outside that open failed } } - // Make sure we are not asked to open a path that is already opened - if (openConfig.cli._.length > 0) { - res = WindowsManager.WINDOWS.filter(w => w.openedWorkspacePath && openConfig.cli._.indexOf(w.openedWorkspacePath) >= 0); - if (res.length) { - openConfig.cli._ = []; - } + // Check for force empty + else if (openConfig.forceEmpty) { + iPathsToOpen = [Object.create(null)]; } - // Open it - this.open({ context: openConfig.context, cli: openConfig.cli, forceNewWindow: true, forceEmpty: openConfig.cli._.length === 0, userEnv: openConfig.userEnv }); + // Otherwise infer from command line arguments + else if (openConfig.cli._.length > 0) { + iPathsToOpen = this.doExtractPathsFromCLI(openConfig.cli); + } + + // Finally check for paths from previous session + else { + iPathsToOpen = this.doExtractPathsFromLastSession(); + } + + return iPathsToOpen; } - private toConfiguration(config: IOpenConfiguration, workspacePath?: string, filesToOpen?: IPath[], filesToCreate?: IPath[], filesToDiff?: IPath[]): IWindowConfiguration { - const configuration: IWindowConfiguration = mixin({}, config.cli); // inherit all properties from CLI - configuration.appRoot = this.environmentService.appRoot; - configuration.execPath = process.execPath; - configuration.userEnv = assign({}, this.initialUserEnv, config.userEnv || {}); - configuration.isInitialStartup = config.initialStartup; - configuration.workspacePath = workspacePath; - configuration.filesToOpen = filesToOpen; - configuration.filesToCreate = filesToCreate; - configuration.filesToDiff = filesToDiff; - configuration.nodeCachedDataDir = this.environmentService.nodeCachedDataDir; + private doExtractPathsFromCLI(cli: ParsedArgs): IPath[] { + const candidates: string[] = cli._; + + const iPaths = candidates.map(candidate => this.toIPath(candidate, true /* ignoreFileNotFound */, cli.goto)).filter(path => !!path); + if (iPaths.length > 0) { + return iPaths; + } + + // No path provided, return empty to open empty + return [Object.create(null)]; + } + + private doExtractPathsFromLastSession(): IPath[] { + const candidates: string[] = []; + + let reopenFolders: string; + if (this.lifecycleService.wasRestarted) { + reopenFolders = ReopenFoldersSetting.ALL; // always reopen all folders when an update was applied + } else { + const windowConfig = this.configurationService.getConfiguration('window'); + reopenFolders = (windowConfig && windowConfig.reopenFolders) || ReopenFoldersSetting.ONE; + } + + const lastActiveFolder = this.windowsState.lastActiveWindow && this.windowsState.lastActiveWindow.workspacePath; + + // Restore all + if (reopenFolders === ReopenFoldersSetting.ALL) { + const lastOpenedFolders = this.windowsState.openedFolders.map(o => o.workspacePath); + + // If we have a last active folder, move it to the end + if (lastActiveFolder) { + lastOpenedFolders.splice(lastOpenedFolders.indexOf(lastActiveFolder), 1); + lastOpenedFolders.push(lastActiveFolder); + } + + candidates.push(...lastOpenedFolders); + } + + // Restore last active + else if (lastActiveFolder && (reopenFolders === ReopenFoldersSetting.ONE || reopenFolders !== ReopenFoldersSetting.NONE)) { + candidates.push(lastActiveFolder); + } + + const iPaths = candidates.map(candidate => this.toIPath(candidate)).filter(path => !!path); + if (iPaths.length > 0) { + return iPaths; + } - return configuration; + // No path provided, return empty to open empty + return [Object.create(null)]; } private toIPath(anyPath: string, ignoreFileNotFound?: boolean, gotoLineMode?: boolean): IPath { @@ -511,59 +576,57 @@ export class WindowsManager implements IWindowsMainService { return null; } - private cliToPaths(cli: ParsedArgs, ignoreFileNotFound?: boolean): IPath[] { - - // Check for pass in candidate or last opened path - let candidates: string[] = []; - if (cli._.length > 0) { - candidates = cli._; - } - - // No path argument, check settings for what to do now - else { - let reopenFolders: string; - if (this.lifecycleService.wasRestarted) { - reopenFolders = ReopenFoldersSetting.ALL; // always reopen all folders when an update was applied - } else { - const windowConfig = this.configurationService.getConfiguration('window'); - reopenFolders = (windowConfig && windowConfig.reopenFolders) || ReopenFoldersSetting.ONE; - } - - const lastActiveFolder = this.windowsState.lastActiveWindow && this.windowsState.lastActiveWindow.workspacePath; - - // Restore all - if (reopenFolders === ReopenFoldersSetting.ALL) { - const lastOpenedFolders = this.windowsState.openedFolders.map(o => o.workspacePath); + public openExtensionDevelopmentHostWindow(openConfig: IOpenConfiguration): void { - // If we have a last active folder, move it to the end - if (lastActiveFolder) { - lastOpenedFolders.splice(lastOpenedFolders.indexOf(lastActiveFolder), 1); - lastOpenedFolders.push(lastActiveFolder); - } + // Reload an existing extension development host window on the same path + // We currently do not allow more than one extension development window + // on the same extension path. + let res = WindowsManager.WINDOWS.filter(w => w.config && isEqual(w.config.extensionDevelopmentPath, openConfig.cli.extensionDevelopmentPath, !isLinux /* ignorecase */)); + if (res && res.length === 1) { + this.reload(res[0], openConfig.cli); + res[0].focus(); // make sure it gets focus and is restored - candidates.push(...lastOpenedFolders); - } + return; + } - // Restore last active - else if (lastActiveFolder && (reopenFolders === ReopenFoldersSetting.ONE || reopenFolders !== ReopenFoldersSetting.NONE)) { - candidates.push(lastActiveFolder); + // Fill in previously opened workspace unless an explicit path is provided and we are not unit testing + if (openConfig.cli._.length === 0 && !openConfig.cli.extensionTestsPath) { + const workspaceToOpen = this.windowsState.lastPluginDevelopmentHostWindow && this.windowsState.lastPluginDevelopmentHostWindow.workspacePath; + if (workspaceToOpen) { + openConfig.cli._ = [workspaceToOpen]; } } - const iPaths = candidates.map(candidate => this.toIPath(candidate, ignoreFileNotFound, cli.goto)).filter(path => !!path); - if (iPaths.length > 0) { - return iPaths; + // Make sure we are not asked to open a path that is already opened + if (openConfig.cli._.length > 0) { + res = WindowsManager.WINDOWS.filter(w => w.openedWorkspacePath && openConfig.cli._.indexOf(w.openedWorkspacePath) >= 0); + if (res.length) { + openConfig.cli._ = []; + } } - // No path provided, return empty to open empty - return [Object.create(null)]; + // Open it + this.open({ context: openConfig.context, cli: openConfig.cli, forceNewWindow: true, forceEmpty: openConfig.cli._.length === 0, userEnv: openConfig.userEnv }); } - private openInBrowserWindow(configuration: IWindowConfiguration, forceNewWindow?: boolean, windowToUse?: CodeWindow, emptyWorkspaceBackupFolder?: string): CodeWindow { + private openInBrowserWindow(options: IOpenBrowserWindowOptions): CodeWindow { + + // Build IWindowConfiguration from config and options + const configuration: IWindowConfiguration = mixin({}, options.cli); // inherit all properties from CLI + configuration.appRoot = this.environmentService.appRoot; + configuration.execPath = process.execPath; + configuration.userEnv = assign({}, this.initialUserEnv, options.userEnv || {}); + configuration.isInitialStartup = options.initialStartup; + configuration.workspacePath = options.workspacePath; + configuration.filesToOpen = options.filesToOpen; + configuration.filesToCreate = options.filesToCreate; + configuration.filesToDiff = options.filesToDiff; + configuration.nodeCachedDataDir = this.environmentService.nodeCachedDataDir; + let codeWindow: CodeWindow; - if (!forceNewWindow) { - codeWindow = windowToUse || this.getLastActiveWindow(); + if (!options.forceNewWindow) { + codeWindow = options.windowToUse || this.getLastActiveWindow(); if (codeWindow) { codeWindow.focus(); @@ -635,7 +698,7 @@ export class WindowsManager implements IWindowsMainService { // Register window for backups if (!configuration.extensionDevelopmentPath) { - this.backupService.registerWindowForBackupsSync(codeWindow.id, !configuration.workspacePath, emptyWorkspaceBackupFolder, configuration.workspacePath); + this.backupService.registerWindowForBackupsSync(codeWindow.id, !configuration.workspacePath, options.emptyWorkspaceBackupFolder, configuration.workspacePath); } // Load it @@ -655,7 +718,7 @@ export class WindowsManager implements IWindowsMainService { // Known Folder - load from stored settings if any if (configuration.workspacePath) { - const stateForWorkspace = this.windowsState.openedFolders.filter(o => isEqual(o.workspacePath, configuration.workspacePath, !platform.isLinux /* ignorecase */)).map(o => o.uiState); + const stateForWorkspace = this.windowsState.openedFolders.filter(o => isEqual(o.workspacePath, configuration.workspacePath, !isLinux /* ignorecase */)).map(o => o.uiState); if (stateForWorkspace.length) { return stateForWorkspace[0]; } @@ -685,7 +748,7 @@ export class WindowsManager implements IWindowsMainService { else { // on mac there is 1 menu per window so we need to use the monitor where the cursor currently is - if (platform.isMacintosh) { + if (isMacintosh) { const cursorPoint = screen.getCursorScreenPoint(); displayToUse = screen.getDisplayNearestPoint(cursorPoint); } @@ -796,22 +859,22 @@ export class WindowsManager implements IWindowsMainService { const res = windowsToTest.filter(w => { // match on workspace - if (typeof w.openedWorkspacePath === 'string' && (isEqual(w.openedWorkspacePath, workspacePath, !platform.isLinux /* ignorecase */))) { + if (typeof w.openedWorkspacePath === 'string' && (isEqual(w.openedWorkspacePath, workspacePath, !isLinux /* ignorecase */))) { return true; } // match on file - if (typeof w.openedFilePath === 'string' && isEqual(w.openedFilePath, filePath, !platform.isLinux /* ignorecase */)) { + if (typeof w.openedFilePath === 'string' && isEqual(w.openedFilePath, filePath, !isLinux /* ignorecase */)) { return true; } // match on file path - if (typeof w.openedWorkspacePath === 'string' && filePath && isEqualOrParent(filePath, w.openedWorkspacePath, !platform.isLinux /* ignorecase */)) { + if (typeof w.openedWorkspacePath === 'string' && filePath && isEqualOrParent(filePath, w.openedWorkspacePath, !isLinux /* ignorecase */)) { return true; } // match on extension development path - if (typeof extensionDevelopmentPath === 'string' && isEqual(w.extensionDevelopmentPath, extensionDevelopmentPath, !platform.isLinux /* ignorecase */)) { + if (typeof extensionDevelopmentPath === 'string' && isEqual(w.extensionDevelopmentPath, extensionDevelopmentPath, !isLinux /* ignorecase */)) { return true; } -- GitLab From 8bd339f185dbe0133859c497052d1abbdc60a814 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Fri, 9 Jun 2017 12:29:14 +0200 Subject: [PATCH 0674/1347] :lipstick: --- src/vs/code/electron-main/windows.ts | 63 +++++++++++-------- .../electron-main/historyMainService.ts | 13 ++-- 2 files changed, 45 insertions(+), 31 deletions(-) diff --git a/src/vs/code/electron-main/windows.ts b/src/vs/code/electron-main/windows.ts index 754a63af36d..743776829a7 100644 --- a/src/vs/code/electron-main/windows.ts +++ b/src/vs/code/electron-main/windows.ts @@ -14,7 +14,7 @@ import { IBackupMainService } from 'vs/platform/backup/common/backup'; import { IEnvironmentService, ParsedArgs } from 'vs/platform/environment/common/environment'; import { IStorageService } from 'vs/platform/storage/node/storage'; import { CodeWindow, IWindowState as ISingleWindowState, defaultWindowState, WindowMode } from 'vs/code/electron-main/window'; -import { ipcMain as ipc, app, screen, BrowserWindow, dialog } from 'electron'; +import { ipcMain as ipc, screen, BrowserWindow, dialog } from 'electron'; import { IPathWithLineAndColumn, parseLineAndColumnAware } from 'vs/code/node/paths'; import { ILifecycleService, UnloadReason } from 'vs/platform/lifecycle/electron-main/lifecycleMain'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; @@ -231,15 +231,15 @@ export class WindowsManager implements IWindowsMainService { let foldersToRestore = (openConfig.initialStartup && !openConfig.cli.extensionDevelopmentPath) ? this.backupService.getWorkspaceBackupPaths() : []; let filesToOpen: IPath[] = []; let filesToDiff: IPath[] = []; + let filesToCreate = pathsToOpen.filter(iPath => !!iPath.filePath && iPath.createFilePath); let emptyToOpen = pathsToOpen.filter(iPath => !iPath.workspacePath && !iPath.filePath); let emptyToRestore = (openConfig.initialStartup && !openConfig.cli.extensionDevelopmentPath) ? this.backupService.getEmptyWorkspaceBackupPaths() : []; - let filesToCreate = pathsToOpen.filter(iPath => !!iPath.filePath && iPath.createFilePath); // Diff mode needs special care - const candidates = pathsToOpen.filter(iPath => !!iPath.filePath && !iPath.createFilePath); + const filesToOpenCandidates = pathsToOpen.filter(iPath => !!iPath.filePath && !iPath.createFilePath); if (openConfig.diffMode) { - if (candidates.length === 2) { - filesToDiff = candidates; + if (filesToOpenCandidates.length === 2) { + filesToDiff = filesToOpenCandidates; } else { emptyToOpen = [Object.create(null)]; // improper use of diffMode, open empty } @@ -248,34 +248,16 @@ export class WindowsManager implements IWindowsMainService { foldersToRestore = []; // diff is always in empty workspace filesToCreate = []; // diff ignores other files that do not exist } else { - filesToOpen = candidates; + filesToOpen = filesToOpenCandidates; } - // let the user settings override how folders are open in a new window or same window unless we are forced - const windowConfig = this.configurationService.getConfiguration('window'); - let openFolderInNewWindow = (openConfig.preferNewWindow || openConfig.forceNewWindow) && !openConfig.forceReuseWindow; - if (!openConfig.forceNewWindow && !openConfig.forceReuseWindow && windowConfig && (windowConfig.openFoldersInNewWindow === 'on' || windowConfig.openFoldersInNewWindow === 'off')) { - openFolderInNewWindow = (windowConfig.openFoldersInNewWindow === 'on'); - } + // Settings can decide if files/folders open in new window or not + let { openFolderInNewWindow, openFilesInNewWindow } = this.shouldOpenNewWindow(openConfig); // Handle files to open/diff or to create when we dont open a folder and we do not restore any folder/untitled from hot-exit const usedWindows: CodeWindow[] = []; if (!foldersToOpen.length && !foldersToRestore.length && !emptyToRestore.length && (filesToOpen.length > 0 || filesToCreate.length > 0 || filesToDiff.length > 0)) { - // let the user settings override how files are open in a new window or same window unless we are forced (not for extension development though) - let openFilesInNewWindow: boolean; - if (openConfig.forceNewWindow || openConfig.forceReuseWindow) { - openFilesInNewWindow = openConfig.forceNewWindow && !openConfig.forceReuseWindow; - } else { - if (openConfig.context === OpenContext.DOCK) { - openFilesInNewWindow = true; // only on macOS do we allow to open files in a new window if this is triggered via DOCK context - } - - if (!openConfig.cli.extensionDevelopmentPath && windowConfig && (windowConfig.openFilesInNewWindow === 'on' || windowConfig.openFilesInNewWindow === 'off')) { - openFilesInNewWindow = (windowConfig.openFilesInNewWindow === 'on'); - } - } - // Open Files in last instance if any and flag tells us so const fileToCheck = filesToOpen[0] || filesToCreate[0] || filesToDiff[0]; const windowOrFolder = findBestWindowOrFolder({ @@ -286,6 +268,7 @@ export class WindowsManager implements IWindowsMainService { filePath: fileToCheck && fileToCheck.filePath, userHome: this.environmentService.userHome }); + if (windowOrFolder instanceof CodeWindow) { windowOrFolder.focus(); const files = { filesToOpen, filesToCreate, filesToDiff }; // copy to object because they get reset shortly after @@ -328,6 +311,7 @@ export class WindowsManager implements IWindowsMainService { if (windowsOnWorkspacePath.length > 0) { const browserWindow = windowsOnWorkspacePath[0]; browserWindow.focus(); // just focus one of them + const files = { filesToOpen, filesToCreate, filesToDiff }; // copy to object because they get reset shortly after browserWindow.ready().then(readyWindow => { readyWindow.send('vscode:openFiles', files); @@ -418,7 +402,6 @@ export class WindowsManager implements IWindowsMainService { pathsToOpen.forEach(iPath => { if (iPath.filePath || iPath.workspacePath) { - app.addRecentDocument(iPath.filePath || iPath.workspacePath); recentPaths.push({ path: iPath.filePath || iPath.workspacePath, isFile: !!iPath.filePath }); } }); @@ -576,6 +559,32 @@ export class WindowsManager implements IWindowsMainService { return null; } + private shouldOpenNewWindow(openConfig: IOpenConfiguration): { openFolderInNewWindow: boolean; openFilesInNewWindow: boolean; } { + + // let the user settings override how folders are open in a new window or same window unless we are forced + const windowConfig = this.configurationService.getConfiguration('window'); + let openFolderInNewWindow = (openConfig.preferNewWindow || openConfig.forceNewWindow) && !openConfig.forceReuseWindow; + if (!openConfig.forceNewWindow && !openConfig.forceReuseWindow && windowConfig && (windowConfig.openFoldersInNewWindow === 'on' || windowConfig.openFoldersInNewWindow === 'off')) { + openFolderInNewWindow = (windowConfig.openFoldersInNewWindow === 'on'); + } + + // let the user settings override how files are open in a new window or same window unless we are forced (not for extension development though) + let openFilesInNewWindow: boolean; + if (openConfig.forceNewWindow || openConfig.forceReuseWindow) { + openFilesInNewWindow = openConfig.forceNewWindow && !openConfig.forceReuseWindow; + } else { + if (openConfig.context === OpenContext.DOCK) { + openFilesInNewWindow = true; // only on macOS do we allow to open files in a new window if this is triggered via DOCK context + } + + if (!openConfig.cli.extensionDevelopmentPath && windowConfig && (windowConfig.openFilesInNewWindow === 'on' || windowConfig.openFilesInNewWindow === 'off')) { + openFilesInNewWindow = (windowConfig.openFilesInNewWindow === 'on'); + } + } + + return { openFolderInNewWindow, openFilesInNewWindow }; + } + public openExtensionDevelopmentHostWindow(openConfig: IOpenConfiguration): void { // Reload an existing extension development host window on the same path diff --git a/src/vs/platform/history/electron-main/historyMainService.ts b/src/vs/platform/history/electron-main/historyMainService.ts index 31ce2c45c79..568b27917e7 100644 --- a/src/vs/platform/history/electron-main/historyMainService.ts +++ b/src/vs/platform/history/electron-main/historyMainService.ts @@ -6,7 +6,6 @@ 'use strict'; import * as path from 'path'; -import * as platform from 'vs/base/common/platform'; import * as nls from 'vs/nls'; import * as arrays from 'vs/base/common/arrays'; import { trim } from 'vs/base/common/strings'; @@ -17,6 +16,7 @@ import { getPathLabel } from 'vs/base/common/labels'; import { IPath } from 'vs/platform/windows/common/windows'; import CommonEvent, { Emitter } from 'vs/base/common/event'; import { createDecorator } from "vs/platform/instantiation/common/instantiation"; +import { isWindows, isMacintosh, isLinux } from "vs/base/common/platform"; export const IHistoryMainService = createDecorator('historyMainService'); @@ -69,15 +69,20 @@ export class HistoryMainService implements IHistoryMainService { if (isFile) { mru.files.unshift(path); - mru.files = arrays.distinct(mru.files, (f) => platform.isLinux ? f : f.toLowerCase()); + mru.files = arrays.distinct(mru.files, (f) => isLinux ? f : f.toLowerCase()); } else { mru.folders.unshift(path); - mru.folders = arrays.distinct(mru.folders, (f) => platform.isLinux ? f : f.toLowerCase()); + mru.folders = arrays.distinct(mru.folders, (f) => isLinux ? f : f.toLowerCase()); } // Make sure its bounded mru.folders = mru.folders.slice(0, HistoryMainService.MAX_TOTAL_RECENT_ENTRIES); mru.files = mru.files.slice(0, HistoryMainService.MAX_TOTAL_RECENT_ENTRIES); + + // Add to recent documents (Windows/macOS only) + if (isMacintosh || isWindows) { + app.addRecentDocument(path); + } }); this.storageService.setItem(HistoryMainService.recentPathsListStorageKey, mru); @@ -157,7 +162,7 @@ export class HistoryMainService implements IHistoryMainService { } public updateWindowsJumpList(): void { - if (!platform.isWindows) { + if (!isWindows) { return; // only on windows } -- GitLab From 29ed566e4b71280ad742cf9fe4e85f4f5f85ec9d Mon Sep 17 00:00:00 2001 From: jens1o Date: Fri, 9 Jun 2017 12:57:42 +0200 Subject: [PATCH 0675/1347] fix ordering and rename select icon theme --- src/vs/workbench/parts/update/electron-browser/update.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/update/electron-browser/update.ts b/src/vs/workbench/parts/update/electron-browser/update.ts index a45dc3b22f2..26deadbcb10 100644 --- a/src/vs/workbench/parts/update/electron-browser/update.ts +++ b/src/vs/workbench/parts/update/electron-browser/update.ts @@ -282,8 +282,8 @@ export class LightUpdateContribution implements IGlobalActivity { private static readonly showCommandsId = 'workbench.action.showCommands'; private static readonly openSettingsId = 'workbench.action.openGlobalSettings'; private static readonly openKeybindingsId = 'workbench.action.openGlobalKeybindings'; - private static readonly selectIconThemeId = 'workbench.action.selectIconTheme'; private static readonly selectColorThemeId = 'workbench.action.selectTheme'; + private static readonly selectIconThemeId = 'workbench.action.selectIconTheme'; get id() { return 'vs.update'; } get name() { return ''; } @@ -326,8 +326,8 @@ export class LightUpdateContribution implements IGlobalActivity { new Action(LightUpdateContribution.openSettingsId, nls.localize('settings', "Settings"), null, true, () => this.commandService.executeCommand(LightUpdateContribution.openSettingsId)), new Action(LightUpdateContribution.openKeybindingsId, nls.localize('keyboardShortcuts', "Keyboard Shortcuts"), null, true, () => this.commandService.executeCommand(LightUpdateContribution.openKeybindingsId)), new Separator(), - new Action(LightUpdateContribution.selectIconThemeId, nls.localize('themes.selectIconTheme', "Select File Icon Theme"), null, true, () => this.commandService.executeCommand(LightUpdateContribution.selectIconThemeId)), new Action(LightUpdateContribution.selectColorThemeId, nls.localize('selectTheme.label', "Color Theme"), null, true, () => this.commandService.executeCommand(LightUpdateContribution.selectColorThemeId)), + new Action(LightUpdateContribution.selectIconThemeId, nls.localize('themes.selectIconTheme.label', "File Icon Theme"), null, true, () => this.commandService.executeCommand(LightUpdateContribution.selectIconThemeId)), new Separator(), this.getUpdateAction() ]; -- GitLab From 6c0d720cdf0bb4a00b13acec63dee1ed867ffd6f Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Fri, 9 Jun 2017 14:43:30 +0200 Subject: [PATCH 0676/1347] Resolves #28336 --- build/lib/i18n.js | 62 +------ build/lib/i18n.resources.json | 190 ++++++++++++++++++++++ build/lib/i18n.ts | 61 +------ build/lib/tslint/translationRemindRule.js | 72 ++++++++ build/lib/tslint/translationRemindRule.ts | 67 ++++++++ tslint.json | 3 +- 6 files changed, 340 insertions(+), 115 deletions(-) create mode 100644 build/lib/i18n.resources.json create mode 100644 build/lib/tslint/translationRemindRule.js create mode 100644 build/lib/tslint/translationRemindRule.ts diff --git a/build/lib/i18n.js b/build/lib/i18n.js index e529cde52e1..6d60d08d87c 100644 --- a/build/lib/i18n.js +++ b/build/lib/i18n.js @@ -1,8 +1,8 @@ +"use strict"; /*--------------------------------------------------------------------------------------------- * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); var path = require("path"); var fs = require("fs"); @@ -501,60 +501,6 @@ function prepareXlfFiles(projectName, extensionName) { } exports.prepareXlfFiles = prepareXlfFiles; var editorProject = 'vscode-editor', workbenchProject = 'vscode-workbench', extensionsProject = 'vscode-extensions', setupProject = 'vscode-setup'; -/** - * Ensure to update those arrays when new resources are pushed to Transifex. - * Used because Transifex does not have API method to pull all project resources. - */ -var editorResources = [ - { name: 'vs/platform', project: editorProject }, - { name: 'vs/editor/contrib', project: editorProject }, - { name: 'vs/editor', project: editorProject }, - { name: 'vs/base', project: editorProject } -]; -var workbenchResources = [ - { name: 'vs/code', project: workbenchProject }, - { name: 'vs/workbench', project: workbenchProject }, - { name: 'vs/workbench/parts/cli', project: workbenchProject }, - { name: 'vs/workbench/parts/codeEditor', project: workbenchProject }, - { name: 'vs/workbench/parts/debug', project: workbenchProject }, - { name: 'vs/workbench/parts/emmet', project: workbenchProject }, - { name: 'vs/workbench/parts/execution', project: workbenchProject }, - { name: 'vs/workbench/parts/explorers', project: workbenchProject }, - { name: 'vs/workbench/parts/extensions', project: workbenchProject }, - { name: 'vs/workbench/parts/feedback', project: workbenchProject }, - { name: 'vs/workbench/parts/files', project: workbenchProject }, - { name: 'vs/workbench/parts/html', project: workbenchProject }, - { name: 'vs/workbench/parts/markers', project: workbenchProject }, - { name: 'vs/workbench/parts/nps', project: workbenchProject }, - { name: 'vs/workbench/parts/output', project: workbenchProject }, - { name: 'vs/workbench/parts/performance', project: workbenchProject }, - { name: 'vs/workbench/parts/preferences', project: workbenchProject }, - { name: 'vs/workbench/parts/quickopen', project: workbenchProject }, - { name: 'vs/workbench/parts/relauncher', project: workbenchProject }, - { name: 'vs/workbench/parts/scm', project: workbenchProject }, - { name: 'vs/workbench/parts/search', project: workbenchProject }, - { name: 'vs/workbench/parts/snippets', project: workbenchProject }, - { name: 'vs/workbench/parts/surveys', project: workbenchProject }, - { name: 'vs/workbench/parts/tasks', project: workbenchProject }, - { name: 'vs/workbench/parts/terminal', project: workbenchProject }, - { name: 'vs/workbench/parts/themes', project: workbenchProject }, - { name: 'vs/workbench/parts/trust', project: workbenchProject }, - { name: 'vs/workbench/parts/update', project: workbenchProject }, - { name: 'vs/workbench/parts/views', project: workbenchProject }, - { name: 'vs/workbench/parts/watermark', project: workbenchProject }, - { name: 'vs/workbench/parts/welcome', project: workbenchProject }, - { name: 'vs/workbench/services/configuration', project: workbenchProject }, - { name: 'vs/workbench/services/crashReporter', project: workbenchProject }, - { name: 'vs/workbench/services/editor', project: workbenchProject }, - { name: 'vs/workbench/services/files', project: workbenchProject }, - { name: 'vs/workbench/services/keybinding', project: workbenchProject }, - { name: 'vs/workbench/services/message', project: workbenchProject }, - { name: 'vs/workbench/services/mode', project: workbenchProject }, - { name: 'vs/workbench/services/progress', project: workbenchProject }, - { name: 'vs/workbench/services/textfile', project: workbenchProject }, - { name: 'vs/workbench/services/themes', project: workbenchProject }, - { name: 'setup_messages', project: workbenchProject } -]; function getResource(sourceFile) { var resource; if (/^vs\/platform/.test(sourceFile)) { @@ -825,10 +771,12 @@ function updateResource(project, slug, xlfFile, apiHostname, credentials) { function obtainProjectResources(projectName) { var resources = []; if (projectName === editorProject) { - resources = editorResources; + var json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); + resources = JSON.parse(json).editor; } else if (projectName === workbenchProject) { - resources = workbenchResources; + var json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); + resources = JSON.parse(json).workbench; } else if (projectName === extensionsProject) { var extensionsToLocalize = glob.sync('./extensions/**/*.nls.json').map(function (extension) { return extension.split('/')[2]; }); diff --git a/build/lib/i18n.resources.json b/build/lib/i18n.resources.json new file mode 100644 index 00000000000..f3c4a3f9bfb --- /dev/null +++ b/build/lib/i18n.resources.json @@ -0,0 +1,190 @@ +{ + "editor": [ + { + "name": "vs/platform", + "project": "vscode-editor" + }, + { + "name": "vs/editor/contrib", + "project": "vscode-editor" + }, + { + "name": "vs/editor", + "project": "vscode-editor" + }, + { + "name": "vs/base", + "project": "vscode-editor" + } + ], + "workbench": [ + { + "name": "vs/code", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/cli", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/codeEditor", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/debug", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/emmet", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/execution", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/explorers", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/extensions", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/feedback", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/files", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/html", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/markers", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/nps", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/output", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/performance", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/preferences", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/quickopen", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/relauncher", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/scm", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/search", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/snippets", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/surveys", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/tasks", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/terminal", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/themes", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/trust", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/update", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/views", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/watermark", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/parts/welcome", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/services/configuration", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/services/crashReporter", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/services/editor", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/services/files", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/services/keybinding", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/services/message", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/services/mode", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/services/progress", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/services/textfile", + "project": "vscode-workbench" + }, + { + "name": "vs/workbench/services/themes", + "project": "vscode-workbench" + }, + { + "name": "setup_messages", + "project": "vscode-workbench" + } + ] +} \ No newline at end of file diff --git a/build/lib/i18n.ts b/build/lib/i18n.ts index 4cf89dacda0..815e599116b 100644 --- a/build/lib/i18n.ts +++ b/build/lib/i18n.ts @@ -578,61 +578,6 @@ const editorProject: string = 'vscode-editor', extensionsProject: string = 'vscode-extensions', setupProject: string = 'vscode-setup'; -/** - * Ensure to update those arrays when new resources are pushed to Transifex. - * Used because Transifex does not have API method to pull all project resources. - */ -const editorResources: Resource[] = [ - { name: 'vs/platform', project: editorProject }, - { name: 'vs/editor/contrib', project: editorProject }, - { name: 'vs/editor', project: editorProject }, - { name: 'vs/base', project: editorProject } -]; -const workbenchResources: Resource[] = [ - { name: 'vs/code', project: workbenchProject }, - { name: 'vs/workbench', project: workbenchProject }, - { name: 'vs/workbench/parts/cli', project: workbenchProject }, - { name: 'vs/workbench/parts/codeEditor', project: workbenchProject }, - { name: 'vs/workbench/parts/debug', project: workbenchProject }, - { name: 'vs/workbench/parts/emmet', project: workbenchProject }, - { name: 'vs/workbench/parts/execution', project: workbenchProject }, - { name: 'vs/workbench/parts/explorers', project: workbenchProject }, - { name: 'vs/workbench/parts/extensions', project: workbenchProject }, - { name: 'vs/workbench/parts/feedback', project: workbenchProject }, - { name: 'vs/workbench/parts/files', project: workbenchProject }, - { name: 'vs/workbench/parts/html', project: workbenchProject }, - { name: 'vs/workbench/parts/markers', project: workbenchProject }, - { name: 'vs/workbench/parts/nps', project: workbenchProject }, - { name: 'vs/workbench/parts/output', project: workbenchProject }, - { name: 'vs/workbench/parts/performance', project: workbenchProject }, - { name: 'vs/workbench/parts/preferences', project: workbenchProject }, - { name: 'vs/workbench/parts/quickopen', project: workbenchProject }, - { name: 'vs/workbench/parts/relauncher', project: workbenchProject }, - { name: 'vs/workbench/parts/scm', project: workbenchProject }, - { name: 'vs/workbench/parts/search', project: workbenchProject }, - { name: 'vs/workbench/parts/snippets', project: workbenchProject }, - { name: 'vs/workbench/parts/surveys', project: workbenchProject }, - { name: 'vs/workbench/parts/tasks', project: workbenchProject }, - { name: 'vs/workbench/parts/terminal', project: workbenchProject }, - { name: 'vs/workbench/parts/themes', project: workbenchProject }, - { name: 'vs/workbench/parts/trust', project: workbenchProject }, - { name: 'vs/workbench/parts/update', project: workbenchProject }, - { name: 'vs/workbench/parts/views', project: workbenchProject }, - { name: 'vs/workbench/parts/watermark', project: workbenchProject }, - { name: 'vs/workbench/parts/welcome', project: workbenchProject }, - { name: 'vs/workbench/services/configuration', project: workbenchProject }, - { name: 'vs/workbench/services/crashReporter', project: workbenchProject }, - { name: 'vs/workbench/services/editor', project: workbenchProject }, - { name: 'vs/workbench/services/files', project: workbenchProject }, - { name: 'vs/workbench/services/keybinding', project: workbenchProject }, - { name: 'vs/workbench/services/message', project: workbenchProject }, - { name: 'vs/workbench/services/mode', project: workbenchProject }, - { name: 'vs/workbench/services/progress', project: workbenchProject }, - { name: 'vs/workbench/services/textfile', project: workbenchProject }, - { name: 'vs/workbench/services/themes', project: workbenchProject }, - { name: 'setup_messages', project: workbenchProject } -]; - export function getResource(sourceFile: string): Resource { let resource: string; @@ -923,9 +868,11 @@ function obtainProjectResources(projectName: string): Resource[] { let resources: Resource[] = []; if (projectName === editorProject) { - resources = editorResources; + const json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); + resources = JSON.parse(json).editor; } else if (projectName === workbenchProject) { - resources = workbenchResources; + const json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); + resources = JSON.parse(json).workbench; } else if (projectName === extensionsProject) { let extensionsToLocalize: string[] = glob.sync('./extensions/**/*.nls.json').map(extension => extension.split('/')[2]); let resourcesToPull: string[] = []; diff --git a/build/lib/tslint/translationRemindRule.js b/build/lib/tslint/translationRemindRule.js new file mode 100644 index 00000000000..8db41098be5 --- /dev/null +++ b/build/lib/tslint/translationRemindRule.js @@ -0,0 +1,72 @@ +"use strict"; +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +var __extends = (this && this.__extends) || (function () { + var extendStatics = Object.setPrototypeOf || + ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || + function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + return function (d, b) { + extendStatics(d, b); + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); + }; +})(); +exports.__esModule = true; +var Lint = require("tslint"); +var fs = require("fs"); +var Rule = (function (_super) { + __extends(Rule, _super); + function Rule() { + return _super !== null && _super.apply(this, arguments) || this; + } + Rule.prototype.apply = function (sourceFile) { + return this.applyWithWalker(new TranslationRemindRuleWalker(sourceFile, this.getOptions())); + }; + return Rule; +}(Lint.Rules.AbstractRule)); +exports.Rule = Rule; +var TranslationRemindRuleWalker = (function (_super) { + __extends(TranslationRemindRuleWalker, _super); + function TranslationRemindRuleWalker(file, opts) { + return _super.call(this, file, opts) || this; + } + TranslationRemindRuleWalker.prototype.visitImportDeclaration = function (node) { + var declaration = node.moduleSpecifier.getText(); + if (declaration !== "'" + TranslationRemindRuleWalker.NLS_MODULE + "'") { + return; + } + this.visitImportLikeDeclaration(node); + }; + TranslationRemindRuleWalker.prototype.visitImportEqualsDeclaration = function (node) { + var reference = node.moduleReference.getText(); + if (reference !== "require('" + TranslationRemindRuleWalker.NLS_MODULE + "')") { + return; + } + this.visitImportLikeDeclaration(node); + }; + TranslationRemindRuleWalker.prototype.visitImportLikeDeclaration = function (node) { + var currentFile = node.getSourceFile().fileName; + var matchService = currentFile.match(/vs\/workbench\/services\/\w+/); + var matchPart = currentFile.match(/vs\/workbench\/parts\/\w+/); + if (!matchService && !matchPart) { + return; + } + var resource = matchService ? matchService[0] : matchPart[0]; + var resourceDefined = false; + var json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); + var workbenchResources = JSON.parse(json).workbench; + workbenchResources.forEach(function (existingResource) { + if (existingResource.name === resource) { + resourceDefined = true; + return; + } + }); + if (!resourceDefined) { + this.addFailureAtNode(node, "Please add '" + resource + "' to ./builds/lib/i18n.resources.json file to use translations here."); + } + }; + return TranslationRemindRuleWalker; +}(Lint.RuleWalker)); +TranslationRemindRuleWalker.NLS_MODULE = 'vs/nls'; diff --git a/build/lib/tslint/translationRemindRule.ts b/build/lib/tslint/translationRemindRule.ts new file mode 100644 index 00000000000..b33025a3536 --- /dev/null +++ b/build/lib/tslint/translationRemindRule.ts @@ -0,0 +1,67 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as ts from 'typescript'; +import * as Lint from 'tslint'; +import * as fs from 'fs'; + +export class Rule extends Lint.Rules.AbstractRule { + public apply(sourceFile: ts.SourceFile): Lint.RuleFailure[] { + return this.applyWithWalker(new TranslationRemindRuleWalker(sourceFile, this.getOptions())); + } +} + +class TranslationRemindRuleWalker extends Lint.RuleWalker { + + private static NLS_MODULE: string = 'vs/nls'; + + constructor(file: ts.SourceFile, opts: Lint.IOptions) { + super(file, opts); + } + + protected visitImportDeclaration(node: ts.ImportDeclaration): void { + const declaration = node.moduleSpecifier.getText(); + if (declaration !== `'${TranslationRemindRuleWalker.NLS_MODULE}'`) { + return; + } + + this.visitImportLikeDeclaration(node); + } + + protected visitImportEqualsDeclaration(node: ts.ImportEqualsDeclaration): void { + const reference = node.moduleReference.getText(); + if (reference !== `require('${TranslationRemindRuleWalker.NLS_MODULE}')`) { + return; + } + + this.visitImportLikeDeclaration(node); + } + + private visitImportLikeDeclaration(node: ts.ImportDeclaration | ts.ImportEqualsDeclaration) { + const currentFile = node.getSourceFile().fileName; + const matchService = currentFile.match(/vs\/workbench\/services\/\w+/); + const matchPart = currentFile.match(/vs\/workbench\/parts\/\w+/); + if (!matchService && !matchPart) { + return; + } + + const resource = matchService ? matchService[0] : matchPart[0]; + let resourceDefined = false; + + const json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); + const workbenchResources = JSON.parse(json).workbench; + + workbenchResources.forEach(existingResource => { + if (existingResource.name === resource) { + resourceDefined = true; + return; + } + }); + + if (!resourceDefined) { + this.addFailureAtNode(node, `Please add '${resource}' to ./builds/lib/i18n.resources.json file to use translations here.`); + } + } +} diff --git a/tslint.json b/tslint.json index b61b70ab046..84c20b3d478 100644 --- a/tslint.json +++ b/tslint.json @@ -69,6 +69,7 @@ "extensions", "smoke" ] - ] + ], + "translation-remind": true } } \ No newline at end of file -- GitLab From 8e89400791a16d71badf2eea6e4bd0bdd3dc0bcd Mon Sep 17 00:00:00 2001 From: isidor Date: Fri, 9 Jun 2017 15:19:48 +0200 Subject: [PATCH 0677/1347] debug: on restart only read out the launch.json if it was changed #28175 --- .../debug/electron-browser/debugService.ts | 25 +++++++++++++------ 1 file changed, 17 insertions(+), 8 deletions(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugService.ts b/src/vs/workbench/parts/debug/electron-browser/debugService.ts index 4a81f9be62d..24fa55d339a 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugService.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugService.ts @@ -81,6 +81,7 @@ export class DebugService implements debug.IDebugService { private debugState: IContextKey; private breakpointsToSendOnResourceSaved: Set; private callStackScheduler: RunOnceScheduler; + private launchJsonChanged: boolean; constructor( @IStorageService private storageService: IStorageService, @@ -628,6 +629,7 @@ export class DebugService implements debug.IDebugService { if (this.model.getProcesses().length === 0) { this.removeReplExpressions(); } + this.launchJsonChanged = false; const manager = this.getConfigurationManager(); configName = configName || this.viewModel.selectedConfigurationName; const config = manager.getConfiguration(configName); @@ -921,15 +923,19 @@ export class DebugService implements debug.IDebugService { return process.session.disconnect(true).then(() => new TPromise((c, e) => { setTimeout(() => { - // Read the configuration again if a launch.json exists, if not just use the inmemory configuration #19366 - const config = this.configurationManager.getConfiguration(process.configuration.name); - if (config) { - // Take the type from the process since the debug extension might overwrite it #21316 - config.type = process.configuration.type; - config.noDebug = process.configuration.noDebug; - config.__restart = restartData; + // Read the configuration again if a launch.json has been changed, if not just use the inmemory configuration + let config = process.configuration; + if (this.launchJsonChanged) { + this.launchJsonChanged = false; + config = this.configurationManager.getConfiguration(process.configuration.name) || process.configuration; + if (config) { + // Take the type from the process since the debug extension might overwrite it #21316 + config.type = process.configuration.type; + config.noDebug = process.configuration.noDebug; + config.__restart = restartData; + } } - this.createProcess(config || process.configuration).then(() => c(null), err => e(err)); + this.createProcess(config).then(() => c(null), err => e(err)); }, 300); }) ).then(() => { @@ -1115,6 +1121,9 @@ export class DebugService implements debug.IDebugService { this.breakpointsToSendOnResourceSaved.delete(event.resource.toString()); this.sendBreakpoints(event.resource, true).done(null, errors.onUnexpectedError); } + if (event.resource.toString().indexOf('.vscode/launch.json') >= 0) { + this.launchJsonChanged = true; + } }); } -- GitLab From 8283f95ce1bdefeb5184bd239cae3e294ed1672a Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 9 Jun 2017 15:21:10 +0200 Subject: [PATCH 0678/1347] Fixes Microsoft/monaco-editor#443 --- src/vs/editor/common/commands/shiftCommand.ts | 30 +++++++++++++- src/vs/editor/common/model/modelLine.ts | 6 +-- .../test/common/commands/shiftCommand.test.ts | 40 ++++++++++++++----- .../test/common/controller/cursor.test.ts | 27 +++++++++++++ 4 files changed, 89 insertions(+), 14 deletions(-) diff --git a/src/vs/editor/common/commands/shiftCommand.ts b/src/vs/editor/common/commands/shiftCommand.ts index 77a59b02385..209e93d7fcb 100644 --- a/src/vs/editor/common/commands/shiftCommand.ts +++ b/src/vs/editor/common/commands/shiftCommand.ts @@ -7,7 +7,7 @@ import * as strings from 'vs/base/common/strings'; import { CursorColumns } from 'vs/editor/common/controller/cursorCommon'; import { Range } from 'vs/editor/common/core/range'; -import { Selection } from 'vs/editor/common/core/selection'; +import { Selection, SelectionDirection } from 'vs/editor/common/core/selection'; import { ICommand, ICursorStateComputerData, IEditOperationBuilder, ITokenizedModel } from 'vs/editor/common/editorCommon'; import { LanguageConfigurationRegistry } from 'vs/editor/common/modes/languageConfigurationRegistry'; import { CharCode } from 'vs/base/common/charCode'; @@ -45,11 +45,13 @@ export class ShiftCommand implements ICommand { private _selection: Selection; private _selectionId: string; private _useLastEditRangeForCursorEndPosition: boolean; + private _selectionStartColumnStaysPut: boolean; constructor(range: Selection, opts: IShiftCommandOpts) { this._opts = opts; this._selection = range; this._useLastEditRangeForCursorEndPosition = false; + this._selectionStartColumnStaysPut = false; } private _addEditOperation(builder: IEditOperationBuilder, range: Range, text: string) { @@ -156,6 +158,10 @@ export class ShiftCommand implements ICommand { } this._addEditOperation(builder, new Range(lineNumber, 1, lineNumber, indentationEndIndex + 1), indents[desiredIndentCount]); + if (lineNumber === startLine) { + // Force the startColumn to stay put because we're inserting after it + this._selectionStartColumnStaysPut = (this._selection.startColumn <= indentationEndIndex + 1); + } } } else { @@ -197,6 +203,10 @@ export class ShiftCommand implements ICommand { this._addEditOperation(builder, new Range(lineNumber, 1, lineNumber, indentationEndIndex + 1), ''); } else { this._addEditOperation(builder, new Range(lineNumber, 1, lineNumber, 1), oneIndent); + if (lineNumber === startLine) { + // Force the startColumn to stay put because we're inserting after it + this._selectionStartColumnStaysPut = (this._selection.startColumn === 1); + } } } } @@ -209,6 +219,22 @@ export class ShiftCommand implements ICommand { let lastOp = helper.getInverseEditOperations()[0]; return new Selection(lastOp.range.endLineNumber, lastOp.range.endColumn, lastOp.range.endLineNumber, lastOp.range.endColumn); } - return helper.getTrackedSelection(this._selectionId); + const result = helper.getTrackedSelection(this._selectionId); + + if (this._selectionStartColumnStaysPut) { + // The selection start should not move + let initialStartColumn = this._selection.startColumn; + let resultStartColumn = result.startColumn; + if (resultStartColumn <= initialStartColumn) { + return result; + } + + if (result.getDirection() === SelectionDirection.LTR) { + return new Selection(result.startLineNumber, initialStartColumn, result.endLineNumber, result.endColumn); + } + return new Selection(result.endLineNumber, result.endColumn, result.startLineNumber, initialStartColumn); + } + + return result; } } diff --git a/src/vs/editor/common/model/modelLine.ts b/src/vs/editor/common/model/modelLine.ts index 2d64bc4dec5..b2d1b3eeea0 100644 --- a/src/vs/editor/common/model/modelLine.ts +++ b/src/vs/editor/common/model/modelLine.ts @@ -416,11 +416,11 @@ export class ModelLine { // var markers = this._markers; - // var printMarker = (m:ILineMarker) => { + // var printMarker = (m:LineMarker) => { // if (m.stickToPreviousCharacter) { - // return '|' + m.column; + // return '|' + m.position.column; // } - // return m.column + '|'; + // return m.position.column + '|'; // }; // return '[' + markers.map(printMarker).join(', ') + ']'; // } diff --git a/src/vs/editor/test/common/commands/shiftCommand.test.ts b/src/vs/editor/test/common/commands/shiftCommand.test.ts index 0ea6691e168..5a2b2ad6375 100644 --- a/src/vs/editor/test/common/commands/shiftCommand.test.ts +++ b/src/vs/editor/test/common/commands/shiftCommand.test.ts @@ -107,7 +107,7 @@ suite('Editor Commands - ShiftCommand', () => { '', '123' ], - new Selection(1, 2, 1, 2) + new Selection(1, 1, 1, 2) ); }); @@ -130,7 +130,7 @@ suite('Editor Commands - ShiftCommand', () => { '', '123' ], - new Selection(1, 4, 1, 2) + new Selection(1, 4, 1, 1) ); }); @@ -153,7 +153,7 @@ suite('Editor Commands - ShiftCommand', () => { '', '123' ], - new Selection(1, 2, 1, 4) + new Selection(1, 1, 1, 4) ); }); @@ -176,7 +176,7 @@ suite('Editor Commands - ShiftCommand', () => { '', '123' ], - new Selection(1, 2, 2, 1) + new Selection(1, 1, 2, 1) ); }); @@ -199,7 +199,7 @@ suite('Editor Commands - ShiftCommand', () => { '', '123' ], - new Selection(1, 2, 2, 1) + new Selection(1, 1, 2, 1) ); testShiftCommand( @@ -312,7 +312,7 @@ suite('Editor Commands - ShiftCommand', () => { '', '\t123' ], - new Selection(1, 2, 5, 3) + new Selection(1, 1, 5, 3) ); testShiftCommand( @@ -333,7 +333,7 @@ suite('Editor Commands - ShiftCommand', () => { '\t', '123' ], - new Selection(4, 2, 5, 1) + new Selection(4, 1, 5, 1) ); }); @@ -538,7 +538,7 @@ suite('Editor Commands - ShiftCommand', () => { '', '\t123' ], - new Selection(1, 2, 5, 5) + new Selection(1, 1, 5, 5) ); }); @@ -703,7 +703,7 @@ suite('Editor Commands - ShiftCommand', () => { ' eleven | 11', '', ], - new Selection(1, 5, 13, 1) + new Selection(1, 1, 13, 1) ); }); @@ -839,6 +839,28 @@ suite('Editor Commands - ShiftCommand', () => { ); }); + test('issue Microsoft/monaco-editor#443: Indentation of a single row deletes selected text in some cases', () => { + testCommand( + [ + 'Hello world!', + 'another line' + ], + null, + new Selection(1, 1, 1, 13), + (sel) => new ShiftCommand(sel, { + isUnshift: false, + tabSize: 4, + oneIndent: '\t', + useTabStops: true + }), + [ + '\tHello world!', + 'another line' + ], + new Selection(1, 1, 1, 14) + ); + }); + test('bug #16815:Shift+Tab doesn\'t go back to tabstop', () => { var repeatStr = (str: string, cnt: number): string => { diff --git a/src/vs/editor/test/common/controller/cursor.test.ts b/src/vs/editor/test/common/controller/cursor.test.ts index b3d15acc035..f2456100aa3 100644 --- a/src/vs/editor/test/common/controller/cursor.test.ts +++ b/src/vs/editor/test/common/controller/cursor.test.ts @@ -1131,6 +1131,33 @@ class IndentRulesMode extends MockMode { } suite('Editor Controller - Regression tests', () => { + + test('issue Microsoft/monaco-editor#443: Indentation of a single row deletes selected text in some cases', () => { + let model = Model.createFromString( + [ + 'Hello world!', + 'another line' + ].join('\n'), + { + defaultEOL: DefaultEndOfLine.LF, + detectIndentation: false, + insertSpaces: false, + tabSize: 4, + trimAutoWhitespace: false + }, + ); + + withMockCodeEditor(null, { model: model }, (editor, cursor) => { + cursor.setSelections('test', [new Selection(1, 1, 1, 13)]); + + // Check that indenting maintains the selection start at column 1 + CoreEditingCommands.Tab.runEditorCommand(null, editor, null); + assert.deepEqual(cursor.getSelection(), new Selection(1, 1, 1, 14)); + }); + + model.dispose(); + }); + test('Bug 9121: Auto indent + undo + redo is funky', () => { let model = Model.createFromString( [ -- GitLab From 5c66337d6d0c75b918437c31fbeb40f7ee8e556f Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Fri, 9 Jun 2017 15:35:12 +0200 Subject: [PATCH 0679/1347] Fix stubbing window.onerror --- .../electron-browser/telemetryService.test.ts | 21 ++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/src/vs/platform/telemetry/test/electron-browser/telemetryService.test.ts b/src/vs/platform/telemetry/test/electron-browser/telemetryService.test.ts index 0f6157ba5e6..9a49dfd7b38 100644 --- a/src/vs/platform/telemetry/test/electron-browser/telemetryService.test.ts +++ b/src/vs/platform/telemetry/test/electron-browser/telemetryService.test.ts @@ -263,7 +263,8 @@ suite('TelemetryService', () => { // })); test('Handle global errors', sinon.test(function () { - let errorStub = this.stub(window, 'onerror'); + let errorStub = sinon.stub(); + window.onerror = errorStub; let testAppender = new TestTelemetryAppender(); let service = new TelemetryService({ appender: testAppender }, undefined); @@ -289,7 +290,8 @@ suite('TelemetryService', () => { })); test('Uncaught Error Telemetry removes PII from filename', sinon.test(function () { - let errorStub = this.stub(window, 'onerror'); + let errorStub = sinon.stub(); + window.onerror = errorStub; let settings = new ErrorTestingSettings(); let testAppender = new TestTelemetryAppender(); let service = new TelemetryService({ appender: testAppender }, undefined); @@ -347,7 +349,8 @@ suite('TelemetryService', () => { })); test('Uncaught Error Telemetry removes PII', sinon.test(function () { - let errorStub = this.stub(window, 'onerror'); + let errorStub = sinon.stub(); + window.onerror = errorStub; let settings = new ErrorTestingSettings(); let testAppender = new TestTelemetryAppender(); let service = new TelemetryService({ appender: testAppender }, undefined); @@ -407,7 +410,8 @@ suite('TelemetryService', () => { })); test('Uncaught Error Telemetry removes PII but preserves Code file path', sinon.test(function () { - let errorStub = this.stub(window, 'onerror'); + let errorStub = sinon.stub(); + window.onerror = errorStub; let settings = new ErrorTestingSettings(); let testAppender = new TestTelemetryAppender(); let service = new TelemetryService({ appender: testAppender }, undefined); @@ -469,7 +473,8 @@ suite('TelemetryService', () => { })); test('Uncaught Error Telemetry removes PII but preserves Code file path when PIIPath is configured', sinon.test(function () { - let errorStub = this.stub(window, 'onerror'); + let errorStub = sinon.stub(); + window.onerror = errorStub; let settings = new ErrorTestingSettings(); let testAppender = new TestTelemetryAppender(); let service = new TelemetryService({ appender: testAppender, piiPaths: [settings.personalInfo + '/resources/app/'] }, undefined); @@ -531,7 +536,8 @@ suite('TelemetryService', () => { })); test('Uncaught Error Telemetry removes PII but preserves Missing Model error message', sinon.test(function () { - let errorStub = this.stub(window, 'onerror'); + let errorStub = sinon.stub(); + window.onerror = errorStub; let settings = new ErrorTestingSettings(); let testAppender = new TestTelemetryAppender(); let service = new TelemetryService({ appender: testAppender }, undefined); @@ -598,7 +604,8 @@ suite('TelemetryService', () => { Errors.setUnexpectedErrorHandler(() => { }); try { - let errorStub = this.stub(window, 'onerror'); + let errorStub = sinon.stub(); + window.onerror = errorStub; let settings = new ErrorTestingSettings(); let testAppender = new TestTelemetryAppender(); let service = new TelemetryService({ appender: testAppender }, undefined); -- GitLab From efe00425488162b40a9cf6f5b8e6a58c8db0c98f Mon Sep 17 00:00:00 2001 From: isidor Date: Fri, 9 Jun 2017 15:39:06 +0200 Subject: [PATCH 0680/1347] debug: fix ts 2.4 errors fixes #28134 --- .../workbench/parts/debug/test/common/mockDebug.ts | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/vs/workbench/parts/debug/test/common/mockDebug.ts b/src/vs/workbench/parts/debug/test/common/mockDebug.ts index c2f725b82c1..55b41b025e6 100644 --- a/src/vs/workbench/parts/debug/test/common/mockDebug.ts +++ b/src/vs/workbench/parts/debug/test/common/mockDebug.ts @@ -114,6 +114,11 @@ export class MockSession implements debug.ISession { public stackTrace(args: DebugProtocol.StackTraceArguments): TPromise { return TPromise.as({ + seq: 1, + type: 'response', + request_seq: 1, + success: true, + command: 'stackTrace', body: { stackFrames: [{ id: 1, @@ -126,12 +131,7 @@ export class MockSession implements debug.ISession { } public exceptionInfo(args: DebugProtocol.ExceptionInfoArguments): TPromise { - return TPromise.as({ - body: { - exceptionId: 'mockExceptionId', - breakMode: 'unhandled' - } - }); + return TPromise.as(null); } public attach(args: DebugProtocol.AttachRequestArguments): TPromise { -- GitLab From 8284c17202a5740dc132b31de0a35820b300a5a0 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Fri, 9 Jun 2017 15:57:58 +0200 Subject: [PATCH 0681/1347] Fixes #28351: Tasks executed in the terminal should always echo the executed command --- .../parts/tasks/common/taskConfiguration.ts | 22 +++++++++---------- .../electron-browser/terminalTaskSystem.ts | 4 ++-- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts index cd6ab3b3382..71be98158a3 100644 --- a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts +++ b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts @@ -569,7 +569,7 @@ namespace CommandConfiguration { return target; } - export function fillDefault(value: Tasks.TerminalBehavior): Tasks.TerminalBehavior { + export function fillDefault(value: Tasks.TerminalBehavior, context: ParseContext): Tasks.TerminalBehavior { if (value && Object.isFrozen(value)) { return value; } @@ -577,7 +577,7 @@ namespace CommandConfiguration { return { echo: false, reveal: Tasks.RevealKind.Always }; } if (value.echo === void 0) { - value.echo = false; + value.echo = context.engine === Tasks.ExecutionEngine.Terminal ? true : false; } if (value.reveal === void 0) { value.reveal = Tasks.RevealKind.Always; @@ -732,14 +732,14 @@ namespace CommandConfiguration { return target; } - export function fillDefaults(value: Tasks.CommandConfiguration): void { + export function fillDefaults(value: Tasks.CommandConfiguration, context: ParseContext): void { if (!value || Object.isFrozen(value)) { return; } if (value.name !== void 0 && value.type === void 0) { value.type = Tasks.CommandType.Process; } - value.terminalBehavior = TerminalBehavior.fillDefault(value.terminalBehavior); + value.terminalBehavior = TerminalBehavior.fillDefault(value.terminalBehavior, context); if (!isEmpty(value)) { value.options = CommandOptions.fillDefaults(value.options); } @@ -933,7 +933,7 @@ namespace TaskDescription { return; } fillGlobals(task, globals); - fillDefaults(task); + fillDefaults(task, context); let addTask: boolean = true; if (context.engine === Tasks.ExecutionEngine.Terminal && task.command && task.command.name && task.command.type === Tasks.CommandType.Shell && task.command.args && task.command.args.length > 0) { if (hasUnescapedSpaces(task.command.name) || task.command.args.some(hasUnescapedSpaces)) { @@ -1028,8 +1028,8 @@ namespace TaskDescription { export function mergeGlobalsIntoAnnnotation(task: Tasks.Task, globals: Globals): void { } - export function fillDefaults(task: Tasks.Task): void { - CommandConfiguration.fillDefaults(task.command); + export function fillDefaults(task: Tasks.Task, context: ParseContext): void { + CommandConfiguration.fillDefaults(task.command, context); if (task.promptOnClose === void 0) { task.promptOnClose = task.isBackground !== void 0 ? !task.isBackground : true; } @@ -1110,7 +1110,7 @@ namespace Globals { if (command) { result.command = command; } - Globals.fillDefaults(result); + Globals.fillDefaults(result, context); Globals.freeze(result); return result; } @@ -1142,11 +1142,11 @@ namespace Globals { return target; } - export function fillDefaults(value: Globals): void { + export function fillDefaults(value: Globals, context: ParseContext): void { if (!value) { return; } - CommandConfiguration.fillDefaults(value.command); + CommandConfiguration.fillDefaults(value.command, context); if (value.suppressTaskName === void 0) { value.suppressTaskName = false; } @@ -1350,7 +1350,7 @@ class ConfigurationParser { problemMatchers: matchers }; TaskDescription.fillGlobals(task, globals); - TaskDescription.fillDefaults(task); + TaskDescription.fillDefaults(task, context); result.tasks = [task]; } result.tasks = result.tasks || []; diff --git a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts index a4bfa6e87e1..31727dae1e0 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts @@ -423,7 +423,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { shellArgs.push(commandLine); shellLaunchConfig.args = Platform.isWindows ? shellArgs.join(' ') : shellArgs; if (task.command.terminalBehavior.echo) { - shellLaunchConfig.initialText = `> ${commandLine}`; + shellLaunchConfig.initialText = `\x1b[4mExecuting task: ${commandLine}\x1b[0m\n`; } } else { let cwd = options && options.cwd ? options.cwd : process.cwd(); @@ -446,7 +446,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { } return args.join(' '); }; - shellLaunchConfig.initialText = `> ${shellLaunchConfig.executable} ${getArgsToEcho(shellLaunchConfig.args)}`; + shellLaunchConfig.initialText = `Executing task: ${shellLaunchConfig.executable} ${getArgsToEcho(shellLaunchConfig.args)}\n`; } } if (options.cwd) { -- GitLab From d0a64636e06e1b6afb4bb68c9e1ae2aeeaec2917 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 9 Jun 2017 16:12:08 +0200 Subject: [PATCH 0682/1347] perf - ask less often to profile --- .../performance/electron-browser/performance.contribution.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/performance/electron-browser/performance.contribution.ts b/src/vs/workbench/parts/performance/electron-browser/performance.contribution.ts index 2e5916bdde0..17e17067705 100644 --- a/src/vs/workbench/parts/performance/electron-browser/performance.contribution.ts +++ b/src/vs/workbench/parts/performance/electron-browser/performance.contribution.ts @@ -107,7 +107,7 @@ class ProfilingHint implements IWorkbenchContribution { // Ignore virtual machines and only ask users // to profile with a certain propability - if (virtualMachineHint.value() >= .5 || Math.ceil(Math.random() * 50) !== 1) { + if (virtualMachineHint.value() >= .5 || Math.ceil(Math.random() * 1000) !== 1) { return; } -- GitLab From 441bfc3a0e3a5b52db041c4f1402fc3d8d72d183 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 9 Jun 2017 16:12:24 +0200 Subject: [PATCH 0683/1347] Fixes Microsoft/monaco-editor#439 --- src/vs/base/browser/ui/menu/menu.css | 1 - .../browser/standalone/media/standalone-tokens.css | 13 +++++++++++-- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/src/vs/base/browser/ui/menu/menu.css b/src/vs/base/browser/ui/menu/menu.css index 291f08b6ade..a7ea384d888 100644 --- a/src/vs/base/browser/ui/menu/menu.css +++ b/src/vs/base/browser/ui/menu/menu.css @@ -51,7 +51,6 @@ display: inline-block; -ms-flex: 2 1 auto; flex: 2 1 auto; - opacity: 0.7; padding: 0.8em 1em; line-height: 1.1em; font-size: 12px; diff --git a/src/vs/editor/browser/standalone/media/standalone-tokens.css b/src/vs/editor/browser/standalone/media/standalone-tokens.css index 8c3ae996849..de07f233940 100644 --- a/src/vs/editor/browser/standalone/media/standalone-tokens.css +++ b/src/vs/editor/browser/standalone/media/standalone-tokens.css @@ -9,8 +9,17 @@ font-family: system-ui, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", "Ubuntu", "Droid Sans", sans-serif; } -.monaco-menu .monaco-action-bar.vertical .action-item [tabindex="0"]:focus { - color: deepskyblue; +.monaco-menu .monaco-action-bar.vertical .action-item .action-label:focus { + color: #0059AC; + stroke-width: 1.2px; + text-shadow: 0px 0px 0.15px #0059AC; +} + +.monaco-editor.vs-dark .monaco-menu .monaco-action-bar.vertical .action-item .action-label:focus, +.monaco-editor.hc-black .monaco-menu .monaco-action-bar.vertical .action-item .action-label:focus { + color: #ACDDFF; + stroke-width: 1.2px; + text-shadow: 0px 0px 0.15px #ACDDFF; } .monaco-editor-hover p { -- GitLab From 6bdcfaa5fdd6f87a6cd3feec9169ecbc3aa81784 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Fri, 9 Jun 2017 16:15:52 +0200 Subject: [PATCH 0684/1347] Added Hungarian and Turkish to Insiders. Resolves #28062 and #27608. --- build/gulpfile.vscode.js | 6 +- build/lib/i18n.js | 1997 +++++++++++++++++++------------------- build/lib/i18n.ts | 4 +- 3 files changed, 1006 insertions(+), 1001 deletions(-) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index aac30d1a5dc..82c1c5cb670 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -86,7 +86,7 @@ const BUNDLED_FILE_HEADER = [ var languages = ['chs', 'cht', 'jpn', 'kor', 'deu', 'fra', 'esn', 'rus', 'ita']; if (process.env.VSCODE_QUALITY !== 'stable') { - languages = languages.concat(['ptb']); // Add languages requested by the community to non-stable builds + languages = languages.concat(['ptb', 'hun', 'trk']); // Add languages requested by the community to non-stable builds } gulp.task('clean-optimized-vscode', util.rimraf('out-vscode')); @@ -369,7 +369,9 @@ const vscodeLanguages = [ 'es', 'ru', 'it', - 'pt-br' + 'pt-br', + 'hu', + 'tr' ]; const setupDefaultLanguages = [ 'zh-hans', diff --git a/build/lib/i18n.js b/build/lib/i18n.js index 6d60d08d87c..5aeb3966003 100644 --- a/build/lib/i18n.js +++ b/build/lib/i18n.js @@ -1,998 +1,999 @@ -"use strict"; -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ -Object.defineProperty(exports, "__esModule", { value: true }); -var path = require("path"); -var fs = require("fs"); -var event_stream_1 = require("event-stream"); -var File = require("vinyl"); -var Is = require("is"); -var xml2js = require("xml2js"); -var glob = require("glob"); -var http = require("http"); -var util = require('gulp-util'); -var iconv = require('iconv-lite'); -function log(message) { - var rest = []; - for (var _i = 1; _i < arguments.length; _i++) { - rest[_i - 1] = arguments[_i]; - } - util.log.apply(util, [util.colors.green('[i18n]'), message].concat(rest)); -} -var LocalizeInfo; -(function (LocalizeInfo) { - function is(value) { - var candidate = value; - return Is.defined(candidate) && Is.string(candidate.key) && (Is.undef(candidate.comment) || (Is.array(candidate.comment) && candidate.comment.every(function (element) { return Is.string(element); }))); - } - LocalizeInfo.is = is; -})(LocalizeInfo || (LocalizeInfo = {})); -var BundledFormat; -(function (BundledFormat) { - function is(value) { - if (Is.undef(value)) { - return false; - } - var candidate = value; - var length = Object.keys(value).length; - return length === 3 && Is.defined(candidate.keys) && Is.defined(candidate.messages) && Is.defined(candidate.bundles); - } - BundledFormat.is = is; -})(BundledFormat || (BundledFormat = {})); -var PackageJsonFormat; -(function (PackageJsonFormat) { - function is(value) { - if (Is.undef(value) || !Is.object(value)) { - return false; - } - return Object.keys(value).every(function (key) { - var element = value[key]; - return Is.string(element) || (Is.object(element) && Is.defined(element.message) && Is.defined(element.comment)); - }); - } - PackageJsonFormat.is = is; -})(PackageJsonFormat || (PackageJsonFormat = {})); -var ModuleJsonFormat; -(function (ModuleJsonFormat) { - function is(value) { - var candidate = value; - return Is.defined(candidate) - && Is.array(candidate.messages) && candidate.messages.every(function (message) { return Is.string(message); }) - && Is.array(candidate.keys) && candidate.keys.every(function (key) { return Is.string(key) || LocalizeInfo.is(key); }); - } - ModuleJsonFormat.is = is; -})(ModuleJsonFormat || (ModuleJsonFormat = {})); -var Line = (function () { - function Line(indent) { - if (indent === void 0) { indent = 0; } - this.indent = indent; - this.buffer = []; - if (indent > 0) { - this.buffer.push(new Array(indent + 1).join(' ')); - } - } - Line.prototype.append = function (value) { - this.buffer.push(value); - return this; - }; - Line.prototype.toString = function () { - return this.buffer.join(''); - }; - return Line; -}()); -exports.Line = Line; -var TextModel = (function () { - function TextModel(contents) { - this._lines = contents.split(/\r\n|\r|\n/); - } - Object.defineProperty(TextModel.prototype, "lines", { - get: function () { - return this._lines; - }, - enumerable: true, - configurable: true - }); - return TextModel; -}()); -var XLF = (function () { - function XLF(project) { - this.project = project; - this.buffer = []; - this.files = Object.create(null); - } - XLF.prototype.toString = function () { - this.appendHeader(); - for (var file in this.files) { - this.appendNewLine("", 2); - for (var _i = 0, _a = this.files[file]; _i < _a.length; _i++) { - var item = _a[_i]; - this.addStringItem(item); - } - this.appendNewLine('', 2); - } - this.appendFooter(); - return this.buffer.join('\r\n'); - }; - XLF.prototype.addFile = function (original, keys, messages) { - this.files[original] = []; - var existingKeys = []; - for (var _i = 0, keys_1 = keys; _i < keys_1.length; _i++) { - var key = keys_1[_i]; - // Ignore duplicate keys because Transifex does not populate those with translated values. - if (existingKeys.indexOf(key) !== -1) { - continue; - } - existingKeys.push(key); - var message = encodeEntities(messages[keys.indexOf(key)]); - var comment = undefined; - // Check if the message contains description (if so, it becomes an object type in JSON) - if (Is.string(key)) { - this.files[original].push({ id: key, message: message, comment: comment }); - } - else { - if (key['comment'] && key['comment'].length > 0) { - comment = key['comment'].map(function (comment) { return encodeEntities(comment); }).join('\r\n'); - } - this.files[original].push({ id: key['key'], message: message, comment: comment }); - } - } - }; - XLF.prototype.addStringItem = function (item) { - if (!item.id || !item.message) { - throw new Error('No item ID or value specified.'); - } - this.appendNewLine("", 4); - this.appendNewLine("" + item.message + "", 6); - if (item.comment) { - this.appendNewLine("" + item.comment + "", 6); - } - this.appendNewLine('', 4); - }; - XLF.prototype.appendHeader = function () { - this.appendNewLine('', 0); - this.appendNewLine('', 0); - }; - XLF.prototype.appendFooter = function () { - this.appendNewLine('', 0); - }; - XLF.prototype.appendNewLine = function (content, indent) { - var line = new Line(indent); - line.append(content); - this.buffer.push(line.toString()); - }; - return XLF; -}()); -XLF.parse = function (xlfString) { - return new Promise(function (resolve, reject) { - var parser = new xml2js.Parser(); - var files = []; - parser.parseString(xlfString, function (err, result) { - if (err) { - reject("Failed to parse XLIFF string. " + err); - } - var fileNodes = result['xliff']['file']; - if (!fileNodes) { - reject('XLIFF file does not contain "xliff" or "file" node(s) required for parsing.'); - } - fileNodes.forEach(function (file) { - var originalFilePath = file.$.original; - if (!originalFilePath) { - reject('XLIFF file node does not contain original attribute to determine the original location of the resource file.'); - } - var language = file.$['target-language'].toLowerCase(); - if (!language) { - reject('XLIFF file node does not contain target-language attribute to determine translated language.'); - } - var messages = {}; - var transUnits = file.body[0]['trans-unit']; - transUnits.forEach(function (unit) { - var key = unit.$.id; - if (!unit.target) { - return; // No translation available - } - var val = unit.target.toString(); - if (key && val) { - messages[key] = decodeEntities(val); - } - else { - reject('XLIFF file does not contain full localization data. ID or target translation for one of the trans-unit nodes is not present.'); - } - }); - files.push({ messages: messages, originalFilePath: originalFilePath, language: language }); - }); - resolve(files); - }); - }); -}; -exports.XLF = XLF; -var iso639_3_to_2 = { - 'chs': 'zh-cn', - 'cht': 'zh-tw', - 'csy': 'cs-cz', - 'deu': 'de', - 'enu': 'en', - 'esn': 'es', - 'fra': 'fr', - 'hun': 'hu', - 'ita': 'it', - 'jpn': 'ja', - 'kor': 'ko', - 'nld': 'nl', - 'plk': 'pl', - 'ptb': 'pt-br', - 'ptg': 'pt', - 'rus': 'ru', - 'sve': 'sv-se', - 'trk': 'tr' -}; -/** - * Used to map Transifex to VS Code language code representation. - */ -var iso639_2_to_3 = { - 'zh-hans': 'chs', - 'zh-hant': 'cht', - 'cs-cz': 'csy', - 'de': 'deu', - 'en': 'enu', - 'es': 'esn', - 'fr': 'fra', - 'hu': 'hun', - 'it': 'ita', - 'ja': 'jpn', - 'ko': 'kor', - 'nl': 'nld', - 'pl': 'plk', - 'pt-br': 'ptb', - 'pt': 'ptg', - 'ru': 'rus', - 'sv-se': 'sve', - 'tr': 'trk' -}; -function sortLanguages(directoryNames) { - return directoryNames.map(function (dirName) { - var lower = dirName.toLowerCase(); - return { - name: lower, - iso639_2: iso639_3_to_2[lower] - }; - }).sort(function (a, b) { - if (!a.iso639_2 && !b.iso639_2) { - return 0; - } - if (!a.iso639_2) { - return -1; - } - if (!b.iso639_2) { - return 1; - } - return a.iso639_2 < b.iso639_2 ? -1 : (a.iso639_2 > b.iso639_2 ? 1 : 0); - }); -} -function stripComments(content) { - /** - * First capturing group matches double quoted string - * Second matches single quotes string - * Third matches block comments - * Fourth matches line comments - */ - var regexp = /("(?:[^\\\"]*(?:\\.)?)*")|('(?:[^\\\']*(?:\\.)?)*')|(\/\*(?:\r?\n|.)*?\*\/)|(\/{2,}.*?(?:(?:\r?\n)|$))/g; - var result = content.replace(regexp, function (match, m1, m2, m3, m4) { - // Only one of m1, m2, m3, m4 matches - if (m3) { - // A block comment. Replace with nothing - return ''; - } - else if (m4) { - // A line comment. If it ends in \r?\n then keep it. - var length_1 = m4.length; - if (length_1 > 2 && m4[length_1 - 1] === '\n') { - return m4[length_1 - 2] === '\r' ? '\r\n' : '\n'; - } - else { - return ''; - } - } - else { - // We match a string - return match; - } - }); - return result; -} -function escapeCharacters(value) { - var result = []; - for (var i = 0; i < value.length; i++) { - var ch = value.charAt(i); - switch (ch) { - case '\'': - result.push('\\\''); - break; - case '"': - result.push('\\"'); - break; - case '\\': - result.push('\\\\'); - break; - case '\n': - result.push('\\n'); - break; - case '\r': - result.push('\\r'); - break; - case '\t': - result.push('\\t'); - break; - case '\b': - result.push('\\b'); - break; - case '\f': - result.push('\\f'); - break; - default: - result.push(ch); - } - } - return result.join(''); -} -function processCoreBundleFormat(fileHeader, languages, json, emitter) { - var keysSection = json.keys; - var messageSection = json.messages; - var bundleSection = json.bundles; - var statistics = Object.create(null); - var total = 0; - var defaultMessages = Object.create(null); - var modules = Object.keys(keysSection); - modules.forEach(function (module) { - var keys = keysSection[module]; - var messages = messageSection[module]; - if (!messages || keys.length !== messages.length) { - emitter.emit('error', "Message for module " + module + " corrupted. Mismatch in number of keys and messages."); - return; - } - var messageMap = Object.create(null); - defaultMessages[module] = messageMap; - keys.map(function (key, i) { - total++; - if (Is.string(key)) { - messageMap[key] = messages[i]; - } - else { - messageMap[key.key] = messages[i]; - } - }); - }); - var languageDirectory = path.join(__dirname, '..', '..', 'i18n'); - var languageDirs; - if (languages) { - languageDirs = sortLanguages(languages); - } - else { - languageDirs = sortLanguages(fs.readdirSync(languageDirectory).filter(function (item) { return fs.statSync(path.join(languageDirectory, item)).isDirectory(); })); - } - languageDirs.forEach(function (language) { - if (!language.iso639_2) { - return; - } - if (process.env['VSCODE_BUILD_VERBOSE']) { - log("Generating nls bundles for: " + language.iso639_2); - } - statistics[language.iso639_2] = 0; - var localizedModules = Object.create(null); - var cwd = path.join(languageDirectory, language.name, 'src'); - modules.forEach(function (module) { - var order = keysSection[module]; - var i18nFile = path.join(cwd, module) + '.i18n.json'; - var messages = null; - if (fs.existsSync(i18nFile)) { - var content = stripComments(fs.readFileSync(i18nFile, 'utf8')); - messages = JSON.parse(content); - } - else { - if (process.env['VSCODE_BUILD_VERBOSE']) { - log("No localized messages found for module " + module + ". Using default messages."); - } - messages = defaultMessages[module]; - statistics[language.iso639_2] = statistics[language.iso639_2] + Object.keys(messages).length; - } - var localizedMessages = []; - order.forEach(function (keyInfo) { - var key = null; - if (Is.string(keyInfo)) { - key = keyInfo; - } - else { - key = keyInfo.key; - } - var message = messages[key]; - if (!message) { - if (process.env['VSCODE_BUILD_VERBOSE']) { - log("No localized message found for key " + key + " in module " + module + ". Using default message."); - } - message = defaultMessages[module][key]; - statistics[language.iso639_2] = statistics[language.iso639_2] + 1; - } - localizedMessages.push(message); - }); - localizedModules[module] = localizedMessages; - }); - Object.keys(bundleSection).forEach(function (bundle) { - var modules = bundleSection[bundle]; - var contents = [ - fileHeader, - "define(\"" + bundle + ".nls." + language.iso639_2 + "\", {" - ]; - modules.forEach(function (module, index) { - contents.push("\t\"" + module + "\": ["); - var messages = localizedModules[module]; - if (!messages) { - emitter.emit('error', "Didn't find messages for module " + module + "."); - return; - } - messages.forEach(function (message, index) { - contents.push("\t\t\"" + escapeCharacters(message) + (index < messages.length ? '",' : '"')); - }); - contents.push(index < modules.length - 1 ? '\t],' : '\t]'); - }); - contents.push('});'); - emitter.emit('data', new File({ path: bundle + '.nls.' + language.iso639_2 + '.js', contents: new Buffer(contents.join('\n'), 'utf-8') })); - }); - }); - Object.keys(statistics).forEach(function (key) { - var value = statistics[key]; - log(key + " has " + value + " untranslated strings."); - }); - languageDirs.forEach(function (dir) { - var language = dir.name; - var iso639_2 = iso639_3_to_2[language]; - if (!iso639_2) { - log("\tCouldn't find iso639 2 mapping for language " + language + ". Using default language instead."); - } - else { - var stats = statistics[iso639_2]; - if (Is.undef(stats)) { - log("\tNo translations found for language " + language + ". Using default language instead."); - } - } - }); -} -function processNlsFiles(opts) { - return event_stream_1.through(function (file) { - var fileName = path.basename(file.path); - if (fileName === 'nls.metadata.json') { - var json = null; - if (file.isBuffer()) { - json = JSON.parse(file.contents.toString('utf8')); - } - else { - this.emit('error', "Failed to read component file: " + file.relative); - } - if (BundledFormat.is(json)) { - processCoreBundleFormat(opts.fileHeader, opts.languages, json, this); - } - } - this.emit('data', file); - }); -} -exports.processNlsFiles = processNlsFiles; -function prepareXlfFiles(projectName, extensionName) { - return event_stream_1.through(function (file) { - if (!file.isBuffer()) { - throw new Error("Failed to read component file: " + file.relative); - } - var extension = path.extname(file.path); - if (extension === '.json') { - var json = JSON.parse(file.contents.toString('utf8')); - if (BundledFormat.is(json)) { - importBundleJson(file, json, this); - } - else if (PackageJsonFormat.is(json) || ModuleJsonFormat.is(json)) { - importModuleOrPackageJson(file, json, projectName, this, extensionName); - } - else { - throw new Error("JSON format cannot be deduced for " + file.relative + "."); - } - } - else if (extension === '.isl') { - importIsl(file, this); - } - }); -} -exports.prepareXlfFiles = prepareXlfFiles; -var editorProject = 'vscode-editor', workbenchProject = 'vscode-workbench', extensionsProject = 'vscode-extensions', setupProject = 'vscode-setup'; -function getResource(sourceFile) { - var resource; - if (/^vs\/platform/.test(sourceFile)) { - return { name: 'vs/platform', project: editorProject }; - } - else if (/^vs\/editor\/contrib/.test(sourceFile)) { - return { name: 'vs/editor/contrib', project: editorProject }; - } - else if (/^vs\/editor/.test(sourceFile)) { - return { name: 'vs/editor', project: editorProject }; - } - else if (/^vs\/base/.test(sourceFile)) { - return { name: 'vs/base', project: editorProject }; - } - else if (/^vs\/code/.test(sourceFile)) { - return { name: 'vs/code', project: workbenchProject }; - } - else if (/^vs\/workbench\/parts/.test(sourceFile)) { - resource = sourceFile.split('/', 4).join('/'); - return { name: resource, project: workbenchProject }; - } - else if (/^vs\/workbench\/services/.test(sourceFile)) { - resource = sourceFile.split('/', 4).join('/'); - return { name: resource, project: workbenchProject }; - } - else if (/^vs\/workbench/.test(sourceFile)) { - return { name: 'vs/workbench', project: workbenchProject }; - } - throw new Error("Could not identify the XLF bundle for " + sourceFile); -} -exports.getResource = getResource; -function importBundleJson(file, json, stream) { - var bundleXlfs = Object.create(null); - for (var source in json.keys) { - var projectResource = getResource(source); - var resource = projectResource.name; - var project = projectResource.project; - var keys = json.keys[source]; - var messages = json.messages[source]; - if (keys.length !== messages.length) { - throw new Error("There is a mismatch between keys and messages in " + file.relative); - } - var xlf = bundleXlfs[resource] ? bundleXlfs[resource] : bundleXlfs[resource] = new XLF(project); - xlf.addFile('src/' + source, keys, messages); - } - for (var resource in bundleXlfs) { - var newFilePath = bundleXlfs[resource].project + "/" + resource.replace(/\//g, '_') + ".xlf"; - var xlfFile = new File({ path: newFilePath, contents: new Buffer(bundleXlfs[resource].toString(), 'utf-8') }); - stream.emit('data', xlfFile); - } -} -// Keeps existing XLF instances and a state of how many files were already processed for faster file emission -var extensions = Object.create(null); -function importModuleOrPackageJson(file, json, projectName, stream, extensionName) { - if (ModuleJsonFormat.is(json) && json['keys'].length !== json['messages'].length) { - throw new Error("There is a mismatch between keys and messages in " + file.relative); - } - // Prepare the source path for attribute in XLF & extract messages from JSON - var formattedSourcePath = file.relative.replace(/\\/g, '/'); - var messages = Object.keys(json).map(function (key) { return json[key].toString(); }); - // Stores the amount of localization files to be transformed to XLF before the emission - var localizationFilesCount, originalFilePath; - // If preparing XLF for external extension, then use different glob pattern and source path - if (extensionName) { - localizationFilesCount = glob.sync('**/*.nls.json').length; - originalFilePath = "" + formattedSourcePath.substr(0, formattedSourcePath.length - '.nls.json'.length); - } - else { - // Used for vscode/extensions folder - extensionName = formattedSourcePath.split('/')[0]; - localizationFilesCount = glob.sync("./extensions/" + extensionName + "/**/*.nls.json").length; - originalFilePath = "extensions/" + formattedSourcePath.substr(0, formattedSourcePath.length - '.nls.json'.length); - } - var extension = extensions[extensionName] ? - extensions[extensionName] : extensions[extensionName] = { xlf: new XLF(projectName), processed: 0 }; - if (ModuleJsonFormat.is(json)) { - extension.xlf.addFile(originalFilePath, json['keys'], json['messages']); - } - else { - extension.xlf.addFile(originalFilePath, Object.keys(json), messages); - } - // Check if XLF is populated with file nodes to emit it - if (++extensions[extensionName].processed === localizationFilesCount) { - var newFilePath = path.join(projectName, extensionName + '.xlf'); - var xlfFile = new File({ path: newFilePath, contents: new Buffer(extension.xlf.toString(), 'utf-8') }); - stream.emit('data', xlfFile); - } -} -function importIsl(file, stream) { - var projectName, resourceFile; - if (path.basename(file.path) === 'Default.isl') { - projectName = setupProject; - resourceFile = 'setup_default.xlf'; - } - else { - projectName = workbenchProject; - resourceFile = 'setup_messages.xlf'; - } - var xlf = new XLF(projectName), keys = [], messages = []; - var model = new TextModel(file.contents.toString()); - var inMessageSection = false; - model.lines.forEach(function (line) { - if (line.length === 0) { - return; - } - var firstChar = line.charAt(0); - switch (firstChar) { - case ';': - // Comment line; - return; - case '[': - inMessageSection = '[Messages]' === line || '[CustomMessages]' === line; - return; - } - if (!inMessageSection) { - return; - } - var sections = line.split('='); - if (sections.length !== 2) { - throw new Error("Badly formatted message found: " + line); - } - else { - var key = sections[0]; - var value = sections[1]; - if (key.length > 0 && value.length > 0) { - keys.push(key); - messages.push(value); - } - } - }); - var originalPath = file.path.substring(file.cwd.length + 1, file.path.split('.')[0].length).replace(/\\/g, '/'); - xlf.addFile(originalPath, keys, messages); - // Emit only upon all ISL files combined into single XLF instance - var newFilePath = path.join(projectName, resourceFile); - var xlfFile = new File({ path: newFilePath, contents: new Buffer(xlf.toString(), 'utf-8') }); - stream.emit('data', xlfFile); -} -function pushXlfFiles(apiHostname, username, password) { - var tryGetPromises = []; - var updateCreatePromises = []; - return event_stream_1.through(function (file) { - var project = path.dirname(file.relative); - var fileName = path.basename(file.path); - var slug = fileName.substr(0, fileName.length - '.xlf'.length); - var credentials = username + ":" + password; - // Check if resource already exists, if not, then create it. - var promise = tryGetResource(project, slug, apiHostname, credentials); - tryGetPromises.push(promise); - promise.then(function (exists) { - if (exists) { - promise = updateResource(project, slug, file, apiHostname, credentials); - } - else { - promise = createResource(project, slug, file, apiHostname, credentials); - } - updateCreatePromises.push(promise); - }); - }, function () { - var _this = this; - // End the pipe only after all the communication with Transifex API happened - Promise.all(tryGetPromises).then(function () { - Promise.all(updateCreatePromises).then(function () { - _this.emit('end'); - }).catch(function (reason) { throw new Error(reason); }); - }).catch(function (reason) { throw new Error(reason); }); - }); -} -exports.pushXlfFiles = pushXlfFiles; -function tryGetResource(project, slug, apiHostname, credentials) { - return new Promise(function (resolve, reject) { - var options = { - hostname: apiHostname, - path: "/api/2/project/" + project + "/resource/" + slug + "/?details", - auth: credentials, - method: 'GET' - }; - var request = http.request(options, function (response) { - if (response.statusCode === 404) { - resolve(false); - } - else if (response.statusCode === 200) { - resolve(true); - } - else { - reject("Failed to query resource " + project + "/" + slug + ". Response: " + response.statusCode + " " + response.statusMessage); - } - }); - request.on('error', function (err) { - reject("Failed to get " + project + "/" + slug + " on Transifex: " + err); - }); - request.end(); - }); -} -function createResource(project, slug, xlfFile, apiHostname, credentials) { - return new Promise(function (resolve, reject) { - var data = JSON.stringify({ - 'content': xlfFile.contents.toString(), - 'name': slug, - 'slug': slug, - 'i18n_type': 'XLIFF' - }); - var options = { - hostname: apiHostname, - path: "/api/2/project/" + project + "/resources", - headers: { - 'Content-Type': 'application/json', - 'Content-Length': Buffer.byteLength(data) - }, - auth: credentials, - method: 'POST' - }; - var request = http.request(options, function (res) { - if (res.statusCode === 201) { - log("Resource " + project + "/" + slug + " successfully created on Transifex."); - } - else { - reject("Something went wrong in the request creating " + slug + " in " + project + ". " + res.statusCode); - } - }); - request.on('error', function (err) { - reject("Failed to create " + project + "/" + slug + " on Transifex: " + err); - }); - request.write(data); - request.end(); - }); -} -/** - * The following link provides information about how Transifex handles updates of a resource file: - * https://dev.befoolish.co/tx-docs/public/projects/updating-content#what-happens-when-you-update-files - */ -function updateResource(project, slug, xlfFile, apiHostname, credentials) { - return new Promise(function (resolve, reject) { - var data = JSON.stringify({ content: xlfFile.contents.toString() }); - var options = { - hostname: apiHostname, - path: "/api/2/project/" + project + "/resource/" + slug + "/content", - headers: { - 'Content-Type': 'application/json', - 'Content-Length': Buffer.byteLength(data) - }, - auth: credentials, - method: 'PUT' - }; - var request = http.request(options, function (res) { - if (res.statusCode === 200) { - res.setEncoding('utf8'); - var responseBuffer_1 = ''; - res.on('data', function (chunk) { - responseBuffer_1 += chunk; - }); - res.on('end', function () { - var response = JSON.parse(responseBuffer_1); - log("Resource " + project + "/" + slug + " successfully updated on Transifex. Strings added: " + response.strings_added + ", updated: " + response.strings_added + ", deleted: " + response.strings_added); - resolve(); - }); - } - else { - reject("Something went wrong in the request updating " + slug + " in " + project + ". " + res.statusCode); - } - }); - request.on('error', function (err) { - reject("Failed to update " + project + "/" + slug + " on Transifex: " + err); - }); - request.write(data); - request.end(); - }); -} -function obtainProjectResources(projectName) { - var resources = []; - if (projectName === editorProject) { - var json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); - resources = JSON.parse(json).editor; - } - else if (projectName === workbenchProject) { - var json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); - resources = JSON.parse(json).workbench; - } - else if (projectName === extensionsProject) { - var extensionsToLocalize = glob.sync('./extensions/**/*.nls.json').map(function (extension) { return extension.split('/')[2]; }); - var resourcesToPull_1 = []; - extensionsToLocalize.forEach(function (extension) { - if (resourcesToPull_1.indexOf(extension) === -1) { - resourcesToPull_1.push(extension); - resources.push({ name: extension, project: projectName }); - } - }); - } - else if (projectName === setupProject) { - resources.push({ name: 'setup_default', project: setupProject }); - } - return resources; -} -function pullXlfFiles(projectName, apiHostname, username, password, languages, resources) { - if (!resources) { - resources = obtainProjectResources(projectName); - } - if (!resources) { - throw new Error('Transifex projects and resources must be defined to be able to pull translations from Transifex.'); - } - var credentials = username + ":" + password; - var expectedTranslationsCount = languages.length * resources.length; - var translationsRetrieved = 0, called = false; - return event_stream_1.readable(function (count, callback) { - // Mark end of stream when all resources were retrieved - if (translationsRetrieved === expectedTranslationsCount) { - return this.emit('end'); - } - if (!called) { - called = true; - var stream_1 = this; - // Retrieve XLF files from main projects - languages.map(function (language) { - resources.map(function (resource) { - retrieveResource(language, resource, apiHostname, credentials).then(function (file) { - stream_1.emit('data', file); - translationsRetrieved++; - }).catch(function (error) { throw new Error(error); }); - }); - }); - } - callback(); - }); -} -exports.pullXlfFiles = pullXlfFiles; -function retrieveResource(language, resource, apiHostname, credentials) { - return new Promise(function (resolve, reject) { - var slug = resource.name.replace(/\//g, '_'); - var project = resource.project; - var iso639 = language.toLowerCase(); - var options = { - hostname: apiHostname, - path: "/api/2/project/" + project + "/resource/" + slug + "/translation/" + iso639 + "?file&mode=onlyreviewed", - auth: credentials, - method: 'GET' - }; - var request = http.request(options, function (res) { - var xlfBuffer = []; - res.on('data', function (chunk) { return xlfBuffer.push(chunk); }); - res.on('end', function () { - if (res.statusCode === 200) { - resolve(new File({ contents: Buffer.concat(xlfBuffer), path: project + "/" + iso639_2_to_3[language] + "/" + slug + ".xlf" })); - } - reject(slug + " in " + project + " returned no data. Response code: " + res.statusCode + "."); - }); - }); - request.on('error', function (err) { - reject("Failed to query resource " + slug + " with the following error: " + err); - }); - request.end(); - }); -} -function prepareJsonFiles() { - var parsePromises = []; - return event_stream_1.through(function (xlf) { - var stream = this; - var parsePromise = XLF.parse(xlf.contents.toString()); - parsePromises.push(parsePromise); - parsePromise.then(function (resolvedFiles) { - resolvedFiles.forEach(function (file) { - var messages = file.messages, translatedFile; - // ISL file path always starts with 'build/' - if (/^build\//.test(file.originalFilePath)) { - var defaultLanguages = { 'zh-hans': true, 'zh-hant': true, 'ko': true }; - if (path.basename(file.originalFilePath) === 'Default' && !defaultLanguages[file.language]) { - return; - } - translatedFile = createIslFile('..', file.originalFilePath, messages, iso639_2_to_3[file.language]); - } - else { - translatedFile = createI18nFile(iso639_2_to_3[file.language], file.originalFilePath, messages); - } - stream.emit('data', translatedFile); - }); - }, function (rejectReason) { - throw new Error("XLF parsing error: " + rejectReason); - }); - }, function () { - var _this = this; - Promise.all(parsePromises) - .then(function () { _this.emit('end'); }) - .catch(function (reason) { throw new Error(reason); }); - }); -} -exports.prepareJsonFiles = prepareJsonFiles; -function createI18nFile(base, originalFilePath, messages) { - var content = [ - '/*---------------------------------------------------------------------------------------------', - ' * Copyright (c) Microsoft Corporation. All rights reserved.', - ' * Licensed under the MIT License. See License.txt in the project root for license information.', - ' *--------------------------------------------------------------------------------------------*/', - '// Do not edit this file. It is machine generated.' - ].join('\n') + '\n' + JSON.stringify(messages, null, '\t').replace(/\r\n/g, '\n'); - return new File({ - path: path.join(base, originalFilePath + '.i18n.json'), - contents: new Buffer(content, 'utf8') - }); -} -var languageNames = { - 'chs': 'Simplified Chinese', - 'cht': 'Traditional Chinese', - 'kor': 'Korean' -}; -var languageIds = { - 'chs': '$0804', - 'cht': '$0404', - 'kor': '$0412' -}; -var encodings = { - 'chs': 'CP936', - 'cht': 'CP950', - 'jpn': 'CP932', - 'kor': 'CP949', - 'deu': 'CP1252', - 'fra': 'CP1252', - 'esn': 'CP1252', - 'rus': 'CP1251', - 'ita': 'CP1252', - 'ptb': 'CP1252' -}; -function createIslFile(base, originalFilePath, messages, language) { - var content = []; - var originalContent; - if (path.basename(originalFilePath) === 'Default') { - originalContent = new TextModel(fs.readFileSync(originalFilePath + '.isl', 'utf8')); - } - else { - originalContent = new TextModel(fs.readFileSync(originalFilePath + '.en.isl', 'utf8')); - } - originalContent.lines.forEach(function (line) { - if (line.length > 0) { - var firstChar = line.charAt(0); - if (firstChar === '[' || firstChar === ';') { - if (line === '; *** Inno Setup version 5.5.3+ English messages ***') { - content.push("; *** Inno Setup version 5.5.3+ " + languageNames[language] + " messages ***"); - } - else { - content.push(line); - } - } - else { - var sections = line.split('='); - var key = sections[0]; - var translated = line; - if (key) { - if (key === 'LanguageName') { - translated = key + "=" + languageNames[language]; - } - else if (key === 'LanguageID') { - translated = key + "=" + languageIds[language]; - } - else if (key === 'LanguageCodePage') { - translated = key + "=" + encodings[language].substr(2); - } - else { - var translatedMessage = messages[key]; - if (translatedMessage) { - translated = key + "=" + translatedMessage; - } - } - } - content.push(translated); - } - } - }); - var tag = iso639_3_to_2[language]; - var basename = path.basename(originalFilePath); - var filePath = path.join(base, path.dirname(originalFilePath), basename) + "." + tag + ".isl"; - return new File({ - path: filePath, - contents: iconv.encode(new Buffer(content.join('\r\n'), 'utf8'), encodings[language]) - }); -} -function encodeEntities(value) { - var result = []; - for (var i = 0; i < value.length; i++) { - var ch = value[i]; - switch (ch) { - case '<': - result.push('<'); - break; - case '>': - result.push('>'); - break; - case '&': - result.push('&'); - break; - default: - result.push(ch); - } - } - return result.join(''); -} -function decodeEntities(value) { - return value.replace(/</g, '<').replace(/>/g, '>').replace(/&/g, '&'); -} +"use strict"; +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +exports.__esModule = true; +var path = require("path"); +var fs = require("fs"); +var event_stream_1 = require("event-stream"); +var File = require("vinyl"); +var Is = require("is"); +var xml2js = require("xml2js"); +var glob = require("glob"); +var http = require("http"); +var util = require('gulp-util'); +var iconv = require('iconv-lite'); +function log(message) { + var rest = []; + for (var _i = 1; _i < arguments.length; _i++) { + rest[_i - 1] = arguments[_i]; + } + util.log.apply(util, [util.colors.green('[i18n]'), message].concat(rest)); +} +var LocalizeInfo; +(function (LocalizeInfo) { + function is(value) { + var candidate = value; + return Is.defined(candidate) && Is.string(candidate.key) && (Is.undef(candidate.comment) || (Is.array(candidate.comment) && candidate.comment.every(function (element) { return Is.string(element); }))); + } + LocalizeInfo.is = is; +})(LocalizeInfo || (LocalizeInfo = {})); +var BundledFormat; +(function (BundledFormat) { + function is(value) { + if (Is.undef(value)) { + return false; + } + var candidate = value; + var length = Object.keys(value).length; + return length === 3 && Is.defined(candidate.keys) && Is.defined(candidate.messages) && Is.defined(candidate.bundles); + } + BundledFormat.is = is; +})(BundledFormat || (BundledFormat = {})); +var PackageJsonFormat; +(function (PackageJsonFormat) { + function is(value) { + if (Is.undef(value) || !Is.object(value)) { + return false; + } + return Object.keys(value).every(function (key) { + var element = value[key]; + return Is.string(element) || (Is.object(element) && Is.defined(element.message) && Is.defined(element.comment)); + }); + } + PackageJsonFormat.is = is; +})(PackageJsonFormat || (PackageJsonFormat = {})); +var ModuleJsonFormat; +(function (ModuleJsonFormat) { + function is(value) { + var candidate = value; + return Is.defined(candidate) + && Is.array(candidate.messages) && candidate.messages.every(function (message) { return Is.string(message); }) + && Is.array(candidate.keys) && candidate.keys.every(function (key) { return Is.string(key) || LocalizeInfo.is(key); }); + } + ModuleJsonFormat.is = is; +})(ModuleJsonFormat || (ModuleJsonFormat = {})); +var Line = (function () { + function Line(indent) { + if (indent === void 0) { indent = 0; } + this.indent = indent; + this.buffer = []; + if (indent > 0) { + this.buffer.push(new Array(indent + 1).join(' ')); + } + } + Line.prototype.append = function (value) { + this.buffer.push(value); + return this; + }; + Line.prototype.toString = function () { + return this.buffer.join(''); + }; + return Line; +}()); +exports.Line = Line; +var TextModel = (function () { + function TextModel(contents) { + this._lines = contents.split(/\r\n|\r|\n/); + } + Object.defineProperty(TextModel.prototype, "lines", { + get: function () { + return this._lines; + }, + enumerable: true, + configurable: true + }); + return TextModel; +}()); +var XLF = (function () { + function XLF(project) { + this.project = project; + this.buffer = []; + this.files = Object.create(null); + } + XLF.prototype.toString = function () { + this.appendHeader(); + for (var file in this.files) { + this.appendNewLine("", 2); + for (var _i = 0, _a = this.files[file]; _i < _a.length; _i++) { + var item = _a[_i]; + this.addStringItem(item); + } + this.appendNewLine('', 2); + } + this.appendFooter(); + return this.buffer.join('\r\n'); + }; + XLF.prototype.addFile = function (original, keys, messages) { + this.files[original] = []; + var existingKeys = []; + for (var _i = 0, keys_1 = keys; _i < keys_1.length; _i++) { + var key = keys_1[_i]; + // Ignore duplicate keys because Transifex does not populate those with translated values. + if (existingKeys.indexOf(key) !== -1) { + continue; + } + existingKeys.push(key); + var message = encodeEntities(messages[keys.indexOf(key)]); + var comment = undefined; + // Check if the message contains description (if so, it becomes an object type in JSON) + if (Is.string(key)) { + this.files[original].push({ id: key, message: message, comment: comment }); + } + else { + if (key['comment'] && key['comment'].length > 0) { + comment = key['comment'].map(function (comment) { return encodeEntities(comment); }).join('\r\n'); + } + this.files[original].push({ id: key['key'], message: message, comment: comment }); + } + } + }; + XLF.prototype.addStringItem = function (item) { + if (!item.id || !item.message) { + throw new Error('No item ID or value specified.'); + } + this.appendNewLine("", 4); + this.appendNewLine("" + item.message + "", 6); + if (item.comment) { + this.appendNewLine("" + item.comment + "", 6); + } + this.appendNewLine('', 4); + }; + XLF.prototype.appendHeader = function () { + this.appendNewLine('', 0); + this.appendNewLine('', 0); + }; + XLF.prototype.appendFooter = function () { + this.appendNewLine('', 0); + }; + XLF.prototype.appendNewLine = function (content, indent) { + var line = new Line(indent); + line.append(content); + this.buffer.push(line.toString()); + }; + return XLF; +}()); +XLF.parse = function (xlfString) { + return new Promise(function (resolve, reject) { + var parser = new xml2js.Parser(); + var files = []; + parser.parseString(xlfString, function (err, result) { + if (err) { + reject("Failed to parse XLIFF string. " + err); + } + var fileNodes = result['xliff']['file']; + if (!fileNodes) { + reject('XLIFF file does not contain "xliff" or "file" node(s) required for parsing.'); + } + fileNodes.forEach(function (file) { + var originalFilePath = file.$.original; + if (!originalFilePath) { + reject('XLIFF file node does not contain original attribute to determine the original location of the resource file.'); + } + var language = file.$['target-language'].toLowerCase(); + if (!language) { + reject('XLIFF file node does not contain target-language attribute to determine translated language.'); + } + var messages = {}; + var transUnits = file.body[0]['trans-unit']; + transUnits.forEach(function (unit) { + var key = unit.$.id; + if (!unit.target) { + return; // No translation available + } + var val = unit.target.toString(); + if (key && val) { + messages[key] = decodeEntities(val); + } + else { + reject('XLIFF file does not contain full localization data. ID or target translation for one of the trans-unit nodes is not present.'); + } + }); + files.push({ messages: messages, originalFilePath: originalFilePath, language: language }); + }); + resolve(files); + }); + }); +}; +exports.XLF = XLF; +var iso639_3_to_2 = { + 'chs': 'zh-cn', + 'cht': 'zh-tw', + 'csy': 'cs-cz', + 'deu': 'de', + 'enu': 'en', + 'esn': 'es', + 'fra': 'fr', + 'hun': 'hu', + 'ita': 'it', + 'jpn': 'ja', + 'kor': 'ko', + 'nld': 'nl', + 'plk': 'pl', + 'ptb': 'pt-br', + 'ptg': 'pt', + 'rus': 'ru', + 'sve': 'sv-se', + 'trk': 'tr' +}; +/** + * Used to map Transifex to VS Code language code representation. + */ +var iso639_2_to_3 = { + 'zh-hans': 'chs', + 'zh-hant': 'cht', + 'cs-cz': 'csy', + 'de': 'deu', + 'en': 'enu', + 'es': 'esn', + 'fr': 'fra', + 'hu': 'hun', + 'it': 'ita', + 'ja': 'jpn', + 'ko': 'kor', + 'nl': 'nld', + 'pl': 'plk', + 'pt-br': 'ptb', + 'pt': 'ptg', + 'ru': 'rus', + 'sv-se': 'sve', + 'tr': 'trk' +}; +function sortLanguages(directoryNames) { + return directoryNames.map(function (dirName) { + var lower = dirName.toLowerCase(); + return { + name: lower, + iso639_2: iso639_3_to_2[lower] + }; + }).sort(function (a, b) { + if (!a.iso639_2 && !b.iso639_2) { + return 0; + } + if (!a.iso639_2) { + return -1; + } + if (!b.iso639_2) { + return 1; + } + return a.iso639_2 < b.iso639_2 ? -1 : (a.iso639_2 > b.iso639_2 ? 1 : 0); + }); +} +function stripComments(content) { + /** + * First capturing group matches double quoted string + * Second matches single quotes string + * Third matches block comments + * Fourth matches line comments + */ + var regexp = /("(?:[^\\\"]*(?:\\.)?)*")|('(?:[^\\\']*(?:\\.)?)*')|(\/\*(?:\r?\n|.)*?\*\/)|(\/{2,}.*?(?:(?:\r?\n)|$))/g; + var result = content.replace(regexp, function (match, m1, m2, m3, m4) { + // Only one of m1, m2, m3, m4 matches + if (m3) { + // A block comment. Replace with nothing + return ''; + } + else if (m4) { + // A line comment. If it ends in \r?\n then keep it. + var length_1 = m4.length; + if (length_1 > 2 && m4[length_1 - 1] === '\n') { + return m4[length_1 - 2] === '\r' ? '\r\n' : '\n'; + } + else { + return ''; + } + } + else { + // We match a string + return match; + } + }); + return result; +} +function escapeCharacters(value) { + var result = []; + for (var i = 0; i < value.length; i++) { + var ch = value.charAt(i); + switch (ch) { + case '\'': + result.push('\\\''); + break; + case '"': + result.push('\\"'); + break; + case '\\': + result.push('\\\\'); + break; + case '\n': + result.push('\\n'); + break; + case '\r': + result.push('\\r'); + break; + case '\t': + result.push('\\t'); + break; + case '\b': + result.push('\\b'); + break; + case '\f': + result.push('\\f'); + break; + default: + result.push(ch); + } + } + return result.join(''); +} +function processCoreBundleFormat(fileHeader, languages, json, emitter) { + var keysSection = json.keys; + var messageSection = json.messages; + var bundleSection = json.bundles; + var statistics = Object.create(null); + var total = 0; + var defaultMessages = Object.create(null); + var modules = Object.keys(keysSection); + modules.forEach(function (module) { + var keys = keysSection[module]; + var messages = messageSection[module]; + if (!messages || keys.length !== messages.length) { + emitter.emit('error', "Message for module " + module + " corrupted. Mismatch in number of keys and messages."); + return; + } + var messageMap = Object.create(null); + defaultMessages[module] = messageMap; + keys.map(function (key, i) { + total++; + if (Is.string(key)) { + messageMap[key] = messages[i]; + } + else { + messageMap[key.key] = messages[i]; + } + }); + }); + var languageDirectory = path.join(__dirname, '..', '..', 'i18n'); + var languageDirs; + if (languages) { + languageDirs = sortLanguages(languages); + } + else { + languageDirs = sortLanguages(fs.readdirSync(languageDirectory).filter(function (item) { return fs.statSync(path.join(languageDirectory, item)).isDirectory(); })); + } + languageDirs.forEach(function (language) { + if (!language.iso639_2) { + return; + } + if (process.env['VSCODE_BUILD_VERBOSE']) { + log("Generating nls bundles for: " + language.iso639_2); + } + statistics[language.iso639_2] = 0; + var localizedModules = Object.create(null); + var cwd = path.join(languageDirectory, language.name, 'src'); + modules.forEach(function (module) { + var order = keysSection[module]; + var i18nFile = path.join(cwd, module) + '.i18n.json'; + var messages = null; + if (fs.existsSync(i18nFile)) { + var content = stripComments(fs.readFileSync(i18nFile, 'utf8')); + messages = JSON.parse(content); + } + else { + if (process.env['VSCODE_BUILD_VERBOSE']) { + log("No localized messages found for module " + module + ". Using default messages."); + } + messages = defaultMessages[module]; + statistics[language.iso639_2] = statistics[language.iso639_2] + Object.keys(messages).length; + } + var localizedMessages = []; + order.forEach(function (keyInfo) { + var key = null; + if (Is.string(keyInfo)) { + key = keyInfo; + } + else { + key = keyInfo.key; + } + var message = messages[key]; + if (!message) { + if (process.env['VSCODE_BUILD_VERBOSE']) { + log("No localized message found for key " + key + " in module " + module + ". Using default message."); + } + message = defaultMessages[module][key]; + statistics[language.iso639_2] = statistics[language.iso639_2] + 1; + } + localizedMessages.push(message); + }); + localizedModules[module] = localizedMessages; + }); + Object.keys(bundleSection).forEach(function (bundle) { + var modules = bundleSection[bundle]; + var contents = [ + fileHeader, + "define(\"" + bundle + ".nls." + language.iso639_2 + "\", {" + ]; + modules.forEach(function (module, index) { + contents.push("\t\"" + module + "\": ["); + var messages = localizedModules[module]; + if (!messages) { + emitter.emit('error', "Didn't find messages for module " + module + "."); + return; + } + messages.forEach(function (message, index) { + contents.push("\t\t\"" + escapeCharacters(message) + (index < messages.length ? '",' : '"')); + }); + contents.push(index < modules.length - 1 ? '\t],' : '\t]'); + }); + contents.push('});'); + emitter.emit('data', new File({ path: bundle + '.nls.' + language.iso639_2 + '.js', contents: new Buffer(contents.join('\n'), 'utf-8') })); + }); + }); + Object.keys(statistics).forEach(function (key) { + var value = statistics[key]; + log(key + " has " + value + " untranslated strings."); + }); + languageDirs.forEach(function (dir) { + var language = dir.name; + var iso639_2 = iso639_3_to_2[language]; + if (!iso639_2) { + log("\tCouldn't find iso639 2 mapping for language " + language + ". Using default language instead."); + } + else { + var stats = statistics[iso639_2]; + if (Is.undef(stats)) { + log("\tNo translations found for language " + language + ". Using default language instead."); + } + } + }); +} +function processNlsFiles(opts) { + return event_stream_1.through(function (file) { + var fileName = path.basename(file.path); + if (fileName === 'nls.metadata.json') { + var json = null; + if (file.isBuffer()) { + json = JSON.parse(file.contents.toString('utf8')); + } + else { + this.emit('error', "Failed to read component file: " + file.relative); + } + if (BundledFormat.is(json)) { + processCoreBundleFormat(opts.fileHeader, opts.languages, json, this); + } + } + this.emit('data', file); + }); +} +exports.processNlsFiles = processNlsFiles; +function prepareXlfFiles(projectName, extensionName) { + return event_stream_1.through(function (file) { + if (!file.isBuffer()) { + throw new Error("Failed to read component file: " + file.relative); + } + var extension = path.extname(file.path); + if (extension === '.json') { + var json = JSON.parse(file.contents.toString('utf8')); + if (BundledFormat.is(json)) { + importBundleJson(file, json, this); + } + else if (PackageJsonFormat.is(json) || ModuleJsonFormat.is(json)) { + importModuleOrPackageJson(file, json, projectName, this, extensionName); + } + else { + throw new Error("JSON format cannot be deduced for " + file.relative + "."); + } + } + else if (extension === '.isl') { + importIsl(file, this); + } + }); +} +exports.prepareXlfFiles = prepareXlfFiles; +var editorProject = 'vscode-editor', workbenchProject = 'vscode-workbench', extensionsProject = 'vscode-extensions', setupProject = 'vscode-setup'; +function getResource(sourceFile) { + var resource; + if (/^vs\/platform/.test(sourceFile)) { + return { name: 'vs/platform', project: editorProject }; + } + else if (/^vs\/editor\/contrib/.test(sourceFile)) { + return { name: 'vs/editor/contrib', project: editorProject }; + } + else if (/^vs\/editor/.test(sourceFile)) { + return { name: 'vs/editor', project: editorProject }; + } + else if (/^vs\/base/.test(sourceFile)) { + return { name: 'vs/base', project: editorProject }; + } + else if (/^vs\/code/.test(sourceFile)) { + return { name: 'vs/code', project: workbenchProject }; + } + else if (/^vs\/workbench\/parts/.test(sourceFile)) { + resource = sourceFile.split('/', 4).join('/'); + return { name: resource, project: workbenchProject }; + } + else if (/^vs\/workbench\/services/.test(sourceFile)) { + resource = sourceFile.split('/', 4).join('/'); + return { name: resource, project: workbenchProject }; + } + else if (/^vs\/workbench/.test(sourceFile)) { + return { name: 'vs/workbench', project: workbenchProject }; + } + throw new Error("Could not identify the XLF bundle for " + sourceFile); +} +exports.getResource = getResource; +function importBundleJson(file, json, stream) { + var bundleXlfs = Object.create(null); + for (var source in json.keys) { + var projectResource = getResource(source); + var resource = projectResource.name; + var project = projectResource.project; + var keys = json.keys[source]; + var messages = json.messages[source]; + if (keys.length !== messages.length) { + throw new Error("There is a mismatch between keys and messages in " + file.relative); + } + var xlf = bundleXlfs[resource] ? bundleXlfs[resource] : bundleXlfs[resource] = new XLF(project); + xlf.addFile('src/' + source, keys, messages); + } + for (var resource in bundleXlfs) { + var newFilePath = bundleXlfs[resource].project + "/" + resource.replace(/\//g, '_') + ".xlf"; + var xlfFile = new File({ path: newFilePath, contents: new Buffer(bundleXlfs[resource].toString(), 'utf-8') }); + stream.emit('data', xlfFile); + } +} +// Keeps existing XLF instances and a state of how many files were already processed for faster file emission +var extensions = Object.create(null); +function importModuleOrPackageJson(file, json, projectName, stream, extensionName) { + if (ModuleJsonFormat.is(json) && json['keys'].length !== json['messages'].length) { + throw new Error("There is a mismatch between keys and messages in " + file.relative); + } + // Prepare the source path for attribute in XLF & extract messages from JSON + var formattedSourcePath = file.relative.replace(/\\/g, '/'); + var messages = Object.keys(json).map(function (key) { return json[key].toString(); }); + // Stores the amount of localization files to be transformed to XLF before the emission + var localizationFilesCount, originalFilePath; + // If preparing XLF for external extension, then use different glob pattern and source path + if (extensionName) { + localizationFilesCount = glob.sync('**/*.nls.json').length; + originalFilePath = "" + formattedSourcePath.substr(0, formattedSourcePath.length - '.nls.json'.length); + } + else { + // Used for vscode/extensions folder + extensionName = formattedSourcePath.split('/')[0]; + localizationFilesCount = glob.sync("./extensions/" + extensionName + "/**/*.nls.json").length; + originalFilePath = "extensions/" + formattedSourcePath.substr(0, formattedSourcePath.length - '.nls.json'.length); + } + var extension = extensions[extensionName] ? + extensions[extensionName] : extensions[extensionName] = { xlf: new XLF(projectName), processed: 0 }; + if (ModuleJsonFormat.is(json)) { + extension.xlf.addFile(originalFilePath, json['keys'], json['messages']); + } + else { + extension.xlf.addFile(originalFilePath, Object.keys(json), messages); + } + // Check if XLF is populated with file nodes to emit it + if (++extensions[extensionName].processed === localizationFilesCount) { + var newFilePath = path.join(projectName, extensionName + '.xlf'); + var xlfFile = new File({ path: newFilePath, contents: new Buffer(extension.xlf.toString(), 'utf-8') }); + stream.emit('data', xlfFile); + } +} +function importIsl(file, stream) { + var projectName, resourceFile; + if (path.basename(file.path) === 'Default.isl') { + projectName = setupProject; + resourceFile = 'setup_default.xlf'; + } + else { + projectName = workbenchProject; + resourceFile = 'setup_messages.xlf'; + } + var xlf = new XLF(projectName), keys = [], messages = []; + var model = new TextModel(file.contents.toString()); + var inMessageSection = false; + model.lines.forEach(function (line) { + if (line.length === 0) { + return; + } + var firstChar = line.charAt(0); + switch (firstChar) { + case ';': + // Comment line; + return; + case '[': + inMessageSection = '[Messages]' === line || '[CustomMessages]' === line; + return; + } + if (!inMessageSection) { + return; + } + var sections = line.split('='); + if (sections.length !== 2) { + throw new Error("Badly formatted message found: " + line); + } + else { + var key = sections[0]; + var value = sections[1]; + if (key.length > 0 && value.length > 0) { + keys.push(key); + messages.push(value); + } + } + }); + var originalPath = file.path.substring(file.cwd.length + 1, file.path.split('.')[0].length).replace(/\\/g, '/'); + xlf.addFile(originalPath, keys, messages); + // Emit only upon all ISL files combined into single XLF instance + var newFilePath = path.join(projectName, resourceFile); + var xlfFile = new File({ path: newFilePath, contents: new Buffer(xlf.toString(), 'utf-8') }); + stream.emit('data', xlfFile); +} +function pushXlfFiles(apiHostname, username, password) { + var tryGetPromises = []; + var updateCreatePromises = []; + return event_stream_1.through(function (file) { + var project = path.dirname(file.relative); + var fileName = path.basename(file.path); + var slug = fileName.substr(0, fileName.length - '.xlf'.length); + var credentials = username + ":" + password; + // Check if resource already exists, if not, then create it. + var promise = tryGetResource(project, slug, apiHostname, credentials); + tryGetPromises.push(promise); + promise.then(function (exists) { + if (exists) { + promise = updateResource(project, slug, file, apiHostname, credentials); + } + else { + promise = createResource(project, slug, file, apiHostname, credentials); + } + updateCreatePromises.push(promise); + }); + }, function () { + var _this = this; + // End the pipe only after all the communication with Transifex API happened + Promise.all(tryGetPromises).then(function () { + Promise.all(updateCreatePromises).then(function () { + _this.emit('end'); + })["catch"](function (reason) { throw new Error(reason); }); + })["catch"](function (reason) { throw new Error(reason); }); + }); +} +exports.pushXlfFiles = pushXlfFiles; +function tryGetResource(project, slug, apiHostname, credentials) { + return new Promise(function (resolve, reject) { + var options = { + hostname: apiHostname, + path: "/api/2/project/" + project + "/resource/" + slug + "/?details", + auth: credentials, + method: 'GET' + }; + var request = http.request(options, function (response) { + if (response.statusCode === 404) { + resolve(false); + } + else if (response.statusCode === 200) { + resolve(true); + } + else { + reject("Failed to query resource " + project + "/" + slug + ". Response: " + response.statusCode + " " + response.statusMessage); + } + }); + request.on('error', function (err) { + reject("Failed to get " + project + "/" + slug + " on Transifex: " + err); + }); + request.end(); + }); +} +function createResource(project, slug, xlfFile, apiHostname, credentials) { + return new Promise(function (resolve, reject) { + var data = JSON.stringify({ + 'content': xlfFile.contents.toString(), + 'name': slug, + 'slug': slug, + 'i18n_type': 'XLIFF' + }); + var options = { + hostname: apiHostname, + path: "/api/2/project/" + project + "/resources", + headers: { + 'Content-Type': 'application/json', + 'Content-Length': Buffer.byteLength(data) + }, + auth: credentials, + method: 'POST' + }; + var request = http.request(options, function (res) { + if (res.statusCode === 201) { + log("Resource " + project + "/" + slug + " successfully created on Transifex."); + } + else { + reject("Something went wrong in the request creating " + slug + " in " + project + ". " + res.statusCode); + } + }); + request.on('error', function (err) { + reject("Failed to create " + project + "/" + slug + " on Transifex: " + err); + }); + request.write(data); + request.end(); + }); +} +/** + * The following link provides information about how Transifex handles updates of a resource file: + * https://dev.befoolish.co/tx-docs/public/projects/updating-content#what-happens-when-you-update-files + */ +function updateResource(project, slug, xlfFile, apiHostname, credentials) { + return new Promise(function (resolve, reject) { + var data = JSON.stringify({ content: xlfFile.contents.toString() }); + var options = { + hostname: apiHostname, + path: "/api/2/project/" + project + "/resource/" + slug + "/content", + headers: { + 'Content-Type': 'application/json', + 'Content-Length': Buffer.byteLength(data) + }, + auth: credentials, + method: 'PUT' + }; + var request = http.request(options, function (res) { + if (res.statusCode === 200) { + res.setEncoding('utf8'); + var responseBuffer_1 = ''; + res.on('data', function (chunk) { + responseBuffer_1 += chunk; + }); + res.on('end', function () { + var response = JSON.parse(responseBuffer_1); + log("Resource " + project + "/" + slug + " successfully updated on Transifex. Strings added: " + response.strings_added + ", updated: " + response.strings_added + ", deleted: " + response.strings_added); + resolve(); + }); + } + else { + reject("Something went wrong in the request updating " + slug + " in " + project + ". " + res.statusCode); + } + }); + request.on('error', function (err) { + reject("Failed to update " + project + "/" + slug + " on Transifex: " + err); + }); + request.write(data); + request.end(); + }); +} +function obtainProjectResources(projectName) { + var resources = []; + if (projectName === editorProject) { + var json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); + resources = JSON.parse(json).editor; + } + else if (projectName === workbenchProject) { + var json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); + resources = JSON.parse(json).workbench; + } + else if (projectName === extensionsProject) { + var extensionsToLocalize = glob.sync('./extensions/**/*.nls.json').map(function (extension) { return extension.split('/')[2]; }); + var resourcesToPull_1 = []; + extensionsToLocalize.forEach(function (extension) { + if (resourcesToPull_1.indexOf(extension) === -1) { + resourcesToPull_1.push(extension); + resources.push({ name: extension, project: projectName }); + } + }); + } + else if (projectName === setupProject) { + resources.push({ name: 'setup_default', project: setupProject }); + } + return resources; +} +function pullXlfFiles(projectName, apiHostname, username, password, languages, resources) { + if (!resources) { + resources = obtainProjectResources(projectName); + } + if (!resources) { + throw new Error('Transifex projects and resources must be defined to be able to pull translations from Transifex.'); + } + var credentials = username + ":" + password; + var expectedTranslationsCount = languages.length * resources.length; + var translationsRetrieved = 0, called = false; + return event_stream_1.readable(function (count, callback) { + // Mark end of stream when all resources were retrieved + if (translationsRetrieved === expectedTranslationsCount) { + return this.emit('end'); + } + if (!called) { + called = true; + var stream_1 = this; + // Retrieve XLF files from main projects + languages.map(function (language) { + resources.map(function (resource) { + retrieveResource(language, resource, apiHostname, credentials).then(function (file) { + stream_1.emit('data', file); + translationsRetrieved++; + })["catch"](function (error) { throw new Error(error); }); + }); + }); + } + callback(); + }); +} +exports.pullXlfFiles = pullXlfFiles; +function retrieveResource(language, resource, apiHostname, credentials) { + return new Promise(function (resolve, reject) { + var slug = resource.name.replace(/\//g, '_'); + var project = resource.project; + var iso639 = language.toLowerCase(); + var options = { + hostname: apiHostname, + path: "/api/2/project/" + project + "/resource/" + slug + "/translation/" + iso639 + "?file&mode=onlyreviewed", + auth: credentials, + method: 'GET' + }; + var request = http.request(options, function (res) { + var xlfBuffer = []; + res.on('data', function (chunk) { return xlfBuffer.push(chunk); }); + res.on('end', function () { + if (res.statusCode === 200) { + resolve(new File({ contents: Buffer.concat(xlfBuffer), path: project + "/" + iso639_2_to_3[language] + "/" + slug + ".xlf" })); + } + reject(slug + " in " + project + " returned no data. Response code: " + res.statusCode + "."); + }); + }); + request.on('error', function (err) { + reject("Failed to query resource " + slug + " with the following error: " + err); + }); + request.end(); + }); +} +function prepareJsonFiles() { + var parsePromises = []; + return event_stream_1.through(function (xlf) { + var stream = this; + var parsePromise = XLF.parse(xlf.contents.toString()); + parsePromises.push(parsePromise); + parsePromise.then(function (resolvedFiles) { + resolvedFiles.forEach(function (file) { + var messages = file.messages, translatedFile; + // ISL file path always starts with 'build/' + if (/^build\//.test(file.originalFilePath)) { + var defaultLanguages = { 'zh-hans': true, 'zh-hant': true, 'ko': true }; + if (path.basename(file.originalFilePath) === 'Default' && !defaultLanguages[file.language]) { + return; + } + translatedFile = createIslFile('..', file.originalFilePath, messages, iso639_2_to_3[file.language]); + } + else { + translatedFile = createI18nFile(iso639_2_to_3[file.language], file.originalFilePath, messages); + } + stream.emit('data', translatedFile); + }); + }, function (rejectReason) { + throw new Error("XLF parsing error: " + rejectReason); + }); + }, function () { + var _this = this; + Promise.all(parsePromises) + .then(function () { _this.emit('end'); })["catch"](function (reason) { throw new Error(reason); }); + }); +} +exports.prepareJsonFiles = prepareJsonFiles; +function createI18nFile(base, originalFilePath, messages) { + var content = [ + '/*---------------------------------------------------------------------------------------------', + ' * Copyright (c) Microsoft Corporation. All rights reserved.', + ' * Licensed under the MIT License. See License.txt in the project root for license information.', + ' *--------------------------------------------------------------------------------------------*/', + '// Do not edit this file. It is machine generated.' + ].join('\n') + '\n' + JSON.stringify(messages, null, '\t').replace(/\r\n/g, '\n'); + return new File({ + path: path.join(base, originalFilePath + '.i18n.json'), + contents: new Buffer(content, 'utf8') + }); +} +var languageNames = { + 'chs': 'Simplified Chinese', + 'cht': 'Traditional Chinese', + 'kor': 'Korean' +}; +var languageIds = { + 'chs': '$0804', + 'cht': '$0404', + 'kor': '$0412' +}; +var encodings = { + 'chs': 'CP936', + 'cht': 'CP950', + 'jpn': 'CP932', + 'kor': 'CP949', + 'deu': 'CP1252', + 'fra': 'CP1252', + 'esn': 'CP1252', + 'rus': 'CP1251', + 'ita': 'CP1252', + 'ptb': 'CP1252', + 'hun': 'CP1250', + 'trk': 'CP1254' +}; +function createIslFile(base, originalFilePath, messages, language) { + var content = []; + var originalContent; + if (path.basename(originalFilePath) === 'Default') { + originalContent = new TextModel(fs.readFileSync(originalFilePath + '.isl', 'utf8')); + } + else { + originalContent = new TextModel(fs.readFileSync(originalFilePath + '.en.isl', 'utf8')); + } + originalContent.lines.forEach(function (line) { + if (line.length > 0) { + var firstChar = line.charAt(0); + if (firstChar === '[' || firstChar === ';') { + if (line === '; *** Inno Setup version 5.5.3+ English messages ***') { + content.push("; *** Inno Setup version 5.5.3+ " + languageNames[language] + " messages ***"); + } + else { + content.push(line); + } + } + else { + var sections = line.split('='); + var key = sections[0]; + var translated = line; + if (key) { + if (key === 'LanguageName') { + translated = key + "=" + languageNames[language]; + } + else if (key === 'LanguageID') { + translated = key + "=" + languageIds[language]; + } + else if (key === 'LanguageCodePage') { + translated = key + "=" + encodings[language].substr(2); + } + else { + var translatedMessage = messages[key]; + if (translatedMessage) { + translated = key + "=" + translatedMessage; + } + } + } + content.push(translated); + } + } + }); + var tag = iso639_3_to_2[language]; + var basename = path.basename(originalFilePath); + var filePath = path.join(base, path.dirname(originalFilePath), basename) + "." + tag + ".isl"; + return new File({ + path: filePath, + contents: iconv.encode(new Buffer(content.join('\r\n'), 'utf8'), encodings[language]) + }); +} +function encodeEntities(value) { + var result = []; + for (var i = 0; i < value.length; i++) { + var ch = value[i]; + switch (ch) { + case '<': + result.push('<'); + break; + case '>': + result.push('>'); + break; + case '&': + result.push('&'); + break; + default: + result.push(ch); + } + } + return result.join(''); +} +function decodeEntities(value) { + return value.replace(/</g, '<').replace(/>/g, '>').replace(/&/g, '&'); +} diff --git a/build/lib/i18n.ts b/build/lib/i18n.ts index 815e599116b..2d2724a4147 100644 --- a/build/lib/i18n.ts +++ b/build/lib/i18n.ts @@ -1032,7 +1032,9 @@ const encodings: Map = { 'esn': 'CP1252', 'rus': 'CP1251', 'ita': 'CP1252', - 'ptb': 'CP1252' + 'ptb': 'CP1252', + 'hun': 'CP1250', + 'trk': 'CP1254' }; function createIslFile(base: string, originalFilePath: string, messages: Map, language: string): File { -- GitLab From 2bdc580183ae60c98daa430ba81e73b2a9132986 Mon Sep 17 00:00:00 2001 From: cleidigh Date: Fri, 9 Jun 2017 12:08:51 -0400 Subject: [PATCH 0685/1347] Tweak label and alias --- .../workbench/parts/debug/electron-browser/repl.ts | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/repl.ts b/src/vs/workbench/parts/debug/electron-browser/repl.ts index 60cc87029cd..60e8853fd3f 100644 --- a/src/vs/workbench/parts/debug/electron-browser/repl.ts +++ b/src/vs/workbench/parts/debug/electron-browser/repl.ts @@ -392,20 +392,14 @@ CommonEditorRegistry.registerEditorCommand(new SuggestCommand({ })); @editorAction -class ReplCopyAllAction extends EditorAction { +export class ReplCopyAllAction extends EditorAction { constructor() { super({ id: 'repl.action.copyall', - label: nls.localize('actions.repl.copyall', "Debug Copy All"), - alias: 'Debug Copy All', + label: nls.localize('actions.repl.copyall', "Debug: Console Copy All"), + alias: 'Debug Console Copy All', precondition: debug.CONTEXT_IN_DEBUG_REPL, - kbOpts: { - kbExpr: null, - primary: null, - weight: 50 - } - }); } -- GitLab From 6697161ea77b6b11f7cca834838b327481e00616 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Fri, 9 Jun 2017 18:10:22 +0200 Subject: [PATCH 0686/1347] :lipstick: storage service --- .../platform/storage/common/storageService.ts | 35 ++++++++----------- .../telemetry/common/telemetryUtils.ts | 7 ++-- 2 files changed, 19 insertions(+), 23 deletions(-) diff --git a/src/vs/platform/storage/common/storageService.ts b/src/vs/platform/storage/common/storageService.ts index d447bd0d18f..1fca3d8262b 100644 --- a/src/vs/platform/storage/common/storageService.ts +++ b/src/vs/platform/storage/common/storageService.ts @@ -8,7 +8,8 @@ import types = require('vs/base/common/types'); import errors = require('vs/base/common/errors'); import strings = require('vs/base/common/strings'); import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage'; -import { IWorkspaceContextService, IWorkspace } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import URI from "vs/base/common/uri"; // Browser localStorage interface export interface IStorage { @@ -25,8 +26,8 @@ export class StorageService implements IStorageService { public _serviceBrand: any; private static COMMON_PREFIX = 'storage://'; - /*private*/ static GLOBAL_PREFIX = StorageService.COMMON_PREFIX + 'global/'; - private static WORKSPACE_PREFIX = StorageService.COMMON_PREFIX + 'workspace/'; + private static GLOBAL_PREFIX = `${StorageService.COMMON_PREFIX}global/`; + private static WORKSPACE_PREFIX = `${StorageService.COMMON_PREFIX}workspace/`; private static WORKSPACE_IDENTIFIER = 'workspaceIdentifier'; private static NO_WORKSPACE_IDENTIFIER = '__$noWorkspace__'; @@ -40,38 +41,33 @@ export class StorageService implements IStorageService { workspaceStorage: IStorage, @IWorkspaceContextService contextService: IWorkspaceContextService ) { - const workspace = contextService.getWorkspace(); - this.globalStorage = globalStorage; this.workspaceStorage = workspaceStorage || globalStorage; // Calculate workspace storage key - this.workspaceKey = this.getWorkspaceKey(workspace); + const workspace = contextService.getWorkspace(); + this.workspaceKey = this.getWorkspaceKey(workspace ? workspace.resource : void 0); // Make sure to delete all workspace storage if the workspace has been recreated meanwhile - const workspaceUniqueId: number = workspace ? workspace.uid : void 0; - if (types.isNumber(workspaceUniqueId)) { - this.cleanupWorkspaceScope(workspaceUniqueId, workspace.name); + if (workspace && types.isNumber(workspace.uid)) { + this.cleanupWorkspaceScope(workspace.uid, workspace.name); } } - private getWorkspaceKey(workspace?: IWorkspace): string { - let workspaceUri: string = null; - if (workspace && workspace.resource) { - workspaceUri = workspace.resource.toString(); + private getWorkspaceKey(workspaceId?: URI): string { + if (!workspaceId) { + return StorageService.NO_WORKSPACE_IDENTIFIER; } - return workspaceUri ? this.calculateWorkspaceKey(workspaceUri) : StorageService.NO_WORKSPACE_IDENTIFIER; - } + const workspaceIdStr = workspaceId.toString(); - private calculateWorkspaceKey(workspaceUrl: string): string { const root = 'file:///'; - const index = workspaceUrl.indexOf(root); + const index = workspaceIdStr.indexOf(root); if (index === 0) { - return strings.rtrim(workspaceUrl.substr(root.length), '/') + '/'; + return `${strings.rtrim(workspaceIdStr.substr(root.length), '/')}/`; } - return workspaceUrl; + return workspaceIdStr; } private cleanupWorkspaceScope(workspaceId: number, workspaceName: string): void { @@ -199,7 +195,6 @@ export class StorageService implements IStorageService { } } -// In-Memory Local Storage Implementation export class InMemoryLocalStorage implements IStorage { private store: { [key: string]: string; }; diff --git a/src/vs/platform/telemetry/common/telemetryUtils.ts b/src/vs/platform/telemetry/common/telemetryUtils.ts index 74b796dc0a8..0637bd49c33 100644 --- a/src/vs/platform/telemetry/common/telemetryUtils.ts +++ b/src/vs/platform/telemetry/common/telemetryUtils.ts @@ -16,7 +16,6 @@ import { IStorageService } from 'vs/platform/storage/common/storage'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { ITelemetryService, ITelemetryExperiments, ITelemetryInfo, ITelemetryData } from 'vs/platform/telemetry/common/telemetry'; import { ServicesAccessor } from 'vs/platform/instantiation/common/instantiation'; -import { StorageService } from 'vs/platform/storage/common/storageService'; import * as objects from 'vs/base/common/objects'; export const defaultExperiments: ITelemetryExperiments = { @@ -105,8 +104,10 @@ function splitExperimentsRandomness(storageService: IStorageService): ITelemetry }; } +const GLOBAL_PREFIX = `storage://global/`; // TODO@Christoph debt, why do you need to know? just use the storageservice? + function getExperimentsRandomness(storageService: IStorageService) { - const key = StorageService.GLOBAL_PREFIX + 'experiments.randomness'; + const key = GLOBAL_PREFIX + 'experiments.randomness'; let valueString = storageService.get(key); if (!valueString) { valueString = Math.random().toString(); @@ -122,7 +123,7 @@ function splitRandom(random: number): [number, boolean] { return [scaled - i, i === 1]; } -const experimentsOverridesKey = StorageService.GLOBAL_PREFIX + 'experiments.overrides'; +const experimentsOverridesKey = GLOBAL_PREFIX + 'experiments.overrides'; function getExperimentsOverrides(storageService: IStorageService): ITelemetryExperiments { const valueString = storageService.get(experimentsOverridesKey); -- GitLab From 11c9c5bd333bae461bb224301a7824343774881b Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Fri, 9 Jun 2017 18:10:38 +0200 Subject: [PATCH 0687/1347] check in compiled js --- build/lib/i18n.js | 1999 +++++++++++---------- build/lib/tslint/translationRemindRule.js | 144 +- 2 files changed, 1072 insertions(+), 1071 deletions(-) diff --git a/build/lib/i18n.js b/build/lib/i18n.js index 5aeb3966003..1ade4703c61 100644 --- a/build/lib/i18n.js +++ b/build/lib/i18n.js @@ -1,999 +1,1000 @@ -"use strict"; -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ -exports.__esModule = true; -var path = require("path"); -var fs = require("fs"); -var event_stream_1 = require("event-stream"); -var File = require("vinyl"); -var Is = require("is"); -var xml2js = require("xml2js"); -var glob = require("glob"); -var http = require("http"); -var util = require('gulp-util'); -var iconv = require('iconv-lite'); -function log(message) { - var rest = []; - for (var _i = 1; _i < arguments.length; _i++) { - rest[_i - 1] = arguments[_i]; - } - util.log.apply(util, [util.colors.green('[i18n]'), message].concat(rest)); -} -var LocalizeInfo; -(function (LocalizeInfo) { - function is(value) { - var candidate = value; - return Is.defined(candidate) && Is.string(candidate.key) && (Is.undef(candidate.comment) || (Is.array(candidate.comment) && candidate.comment.every(function (element) { return Is.string(element); }))); - } - LocalizeInfo.is = is; -})(LocalizeInfo || (LocalizeInfo = {})); -var BundledFormat; -(function (BundledFormat) { - function is(value) { - if (Is.undef(value)) { - return false; - } - var candidate = value; - var length = Object.keys(value).length; - return length === 3 && Is.defined(candidate.keys) && Is.defined(candidate.messages) && Is.defined(candidate.bundles); - } - BundledFormat.is = is; -})(BundledFormat || (BundledFormat = {})); -var PackageJsonFormat; -(function (PackageJsonFormat) { - function is(value) { - if (Is.undef(value) || !Is.object(value)) { - return false; - } - return Object.keys(value).every(function (key) { - var element = value[key]; - return Is.string(element) || (Is.object(element) && Is.defined(element.message) && Is.defined(element.comment)); - }); - } - PackageJsonFormat.is = is; -})(PackageJsonFormat || (PackageJsonFormat = {})); -var ModuleJsonFormat; -(function (ModuleJsonFormat) { - function is(value) { - var candidate = value; - return Is.defined(candidate) - && Is.array(candidate.messages) && candidate.messages.every(function (message) { return Is.string(message); }) - && Is.array(candidate.keys) && candidate.keys.every(function (key) { return Is.string(key) || LocalizeInfo.is(key); }); - } - ModuleJsonFormat.is = is; -})(ModuleJsonFormat || (ModuleJsonFormat = {})); -var Line = (function () { - function Line(indent) { - if (indent === void 0) { indent = 0; } - this.indent = indent; - this.buffer = []; - if (indent > 0) { - this.buffer.push(new Array(indent + 1).join(' ')); - } - } - Line.prototype.append = function (value) { - this.buffer.push(value); - return this; - }; - Line.prototype.toString = function () { - return this.buffer.join(''); - }; - return Line; -}()); -exports.Line = Line; -var TextModel = (function () { - function TextModel(contents) { - this._lines = contents.split(/\r\n|\r|\n/); - } - Object.defineProperty(TextModel.prototype, "lines", { - get: function () { - return this._lines; - }, - enumerable: true, - configurable: true - }); - return TextModel; -}()); -var XLF = (function () { - function XLF(project) { - this.project = project; - this.buffer = []; - this.files = Object.create(null); - } - XLF.prototype.toString = function () { - this.appendHeader(); - for (var file in this.files) { - this.appendNewLine("", 2); - for (var _i = 0, _a = this.files[file]; _i < _a.length; _i++) { - var item = _a[_i]; - this.addStringItem(item); - } - this.appendNewLine('', 2); - } - this.appendFooter(); - return this.buffer.join('\r\n'); - }; - XLF.prototype.addFile = function (original, keys, messages) { - this.files[original] = []; - var existingKeys = []; - for (var _i = 0, keys_1 = keys; _i < keys_1.length; _i++) { - var key = keys_1[_i]; - // Ignore duplicate keys because Transifex does not populate those with translated values. - if (existingKeys.indexOf(key) !== -1) { - continue; - } - existingKeys.push(key); - var message = encodeEntities(messages[keys.indexOf(key)]); - var comment = undefined; - // Check if the message contains description (if so, it becomes an object type in JSON) - if (Is.string(key)) { - this.files[original].push({ id: key, message: message, comment: comment }); - } - else { - if (key['comment'] && key['comment'].length > 0) { - comment = key['comment'].map(function (comment) { return encodeEntities(comment); }).join('\r\n'); - } - this.files[original].push({ id: key['key'], message: message, comment: comment }); - } - } - }; - XLF.prototype.addStringItem = function (item) { - if (!item.id || !item.message) { - throw new Error('No item ID or value specified.'); - } - this.appendNewLine("", 4); - this.appendNewLine("" + item.message + "", 6); - if (item.comment) { - this.appendNewLine("" + item.comment + "", 6); - } - this.appendNewLine('', 4); - }; - XLF.prototype.appendHeader = function () { - this.appendNewLine('', 0); - this.appendNewLine('', 0); - }; - XLF.prototype.appendFooter = function () { - this.appendNewLine('', 0); - }; - XLF.prototype.appendNewLine = function (content, indent) { - var line = new Line(indent); - line.append(content); - this.buffer.push(line.toString()); - }; - return XLF; -}()); -XLF.parse = function (xlfString) { - return new Promise(function (resolve, reject) { - var parser = new xml2js.Parser(); - var files = []; - parser.parseString(xlfString, function (err, result) { - if (err) { - reject("Failed to parse XLIFF string. " + err); - } - var fileNodes = result['xliff']['file']; - if (!fileNodes) { - reject('XLIFF file does not contain "xliff" or "file" node(s) required for parsing.'); - } - fileNodes.forEach(function (file) { - var originalFilePath = file.$.original; - if (!originalFilePath) { - reject('XLIFF file node does not contain original attribute to determine the original location of the resource file.'); - } - var language = file.$['target-language'].toLowerCase(); - if (!language) { - reject('XLIFF file node does not contain target-language attribute to determine translated language.'); - } - var messages = {}; - var transUnits = file.body[0]['trans-unit']; - transUnits.forEach(function (unit) { - var key = unit.$.id; - if (!unit.target) { - return; // No translation available - } - var val = unit.target.toString(); - if (key && val) { - messages[key] = decodeEntities(val); - } - else { - reject('XLIFF file does not contain full localization data. ID or target translation for one of the trans-unit nodes is not present.'); - } - }); - files.push({ messages: messages, originalFilePath: originalFilePath, language: language }); - }); - resolve(files); - }); - }); -}; -exports.XLF = XLF; -var iso639_3_to_2 = { - 'chs': 'zh-cn', - 'cht': 'zh-tw', - 'csy': 'cs-cz', - 'deu': 'de', - 'enu': 'en', - 'esn': 'es', - 'fra': 'fr', - 'hun': 'hu', - 'ita': 'it', - 'jpn': 'ja', - 'kor': 'ko', - 'nld': 'nl', - 'plk': 'pl', - 'ptb': 'pt-br', - 'ptg': 'pt', - 'rus': 'ru', - 'sve': 'sv-se', - 'trk': 'tr' -}; -/** - * Used to map Transifex to VS Code language code representation. - */ -var iso639_2_to_3 = { - 'zh-hans': 'chs', - 'zh-hant': 'cht', - 'cs-cz': 'csy', - 'de': 'deu', - 'en': 'enu', - 'es': 'esn', - 'fr': 'fra', - 'hu': 'hun', - 'it': 'ita', - 'ja': 'jpn', - 'ko': 'kor', - 'nl': 'nld', - 'pl': 'plk', - 'pt-br': 'ptb', - 'pt': 'ptg', - 'ru': 'rus', - 'sv-se': 'sve', - 'tr': 'trk' -}; -function sortLanguages(directoryNames) { - return directoryNames.map(function (dirName) { - var lower = dirName.toLowerCase(); - return { - name: lower, - iso639_2: iso639_3_to_2[lower] - }; - }).sort(function (a, b) { - if (!a.iso639_2 && !b.iso639_2) { - return 0; - } - if (!a.iso639_2) { - return -1; - } - if (!b.iso639_2) { - return 1; - } - return a.iso639_2 < b.iso639_2 ? -1 : (a.iso639_2 > b.iso639_2 ? 1 : 0); - }); -} -function stripComments(content) { - /** - * First capturing group matches double quoted string - * Second matches single quotes string - * Third matches block comments - * Fourth matches line comments - */ - var regexp = /("(?:[^\\\"]*(?:\\.)?)*")|('(?:[^\\\']*(?:\\.)?)*')|(\/\*(?:\r?\n|.)*?\*\/)|(\/{2,}.*?(?:(?:\r?\n)|$))/g; - var result = content.replace(regexp, function (match, m1, m2, m3, m4) { - // Only one of m1, m2, m3, m4 matches - if (m3) { - // A block comment. Replace with nothing - return ''; - } - else if (m4) { - // A line comment. If it ends in \r?\n then keep it. - var length_1 = m4.length; - if (length_1 > 2 && m4[length_1 - 1] === '\n') { - return m4[length_1 - 2] === '\r' ? '\r\n' : '\n'; - } - else { - return ''; - } - } - else { - // We match a string - return match; - } - }); - return result; -} -function escapeCharacters(value) { - var result = []; - for (var i = 0; i < value.length; i++) { - var ch = value.charAt(i); - switch (ch) { - case '\'': - result.push('\\\''); - break; - case '"': - result.push('\\"'); - break; - case '\\': - result.push('\\\\'); - break; - case '\n': - result.push('\\n'); - break; - case '\r': - result.push('\\r'); - break; - case '\t': - result.push('\\t'); - break; - case '\b': - result.push('\\b'); - break; - case '\f': - result.push('\\f'); - break; - default: - result.push(ch); - } - } - return result.join(''); -} -function processCoreBundleFormat(fileHeader, languages, json, emitter) { - var keysSection = json.keys; - var messageSection = json.messages; - var bundleSection = json.bundles; - var statistics = Object.create(null); - var total = 0; - var defaultMessages = Object.create(null); - var modules = Object.keys(keysSection); - modules.forEach(function (module) { - var keys = keysSection[module]; - var messages = messageSection[module]; - if (!messages || keys.length !== messages.length) { - emitter.emit('error', "Message for module " + module + " corrupted. Mismatch in number of keys and messages."); - return; - } - var messageMap = Object.create(null); - defaultMessages[module] = messageMap; - keys.map(function (key, i) { - total++; - if (Is.string(key)) { - messageMap[key] = messages[i]; - } - else { - messageMap[key.key] = messages[i]; - } - }); - }); - var languageDirectory = path.join(__dirname, '..', '..', 'i18n'); - var languageDirs; - if (languages) { - languageDirs = sortLanguages(languages); - } - else { - languageDirs = sortLanguages(fs.readdirSync(languageDirectory).filter(function (item) { return fs.statSync(path.join(languageDirectory, item)).isDirectory(); })); - } - languageDirs.forEach(function (language) { - if (!language.iso639_2) { - return; - } - if (process.env['VSCODE_BUILD_VERBOSE']) { - log("Generating nls bundles for: " + language.iso639_2); - } - statistics[language.iso639_2] = 0; - var localizedModules = Object.create(null); - var cwd = path.join(languageDirectory, language.name, 'src'); - modules.forEach(function (module) { - var order = keysSection[module]; - var i18nFile = path.join(cwd, module) + '.i18n.json'; - var messages = null; - if (fs.existsSync(i18nFile)) { - var content = stripComments(fs.readFileSync(i18nFile, 'utf8')); - messages = JSON.parse(content); - } - else { - if (process.env['VSCODE_BUILD_VERBOSE']) { - log("No localized messages found for module " + module + ". Using default messages."); - } - messages = defaultMessages[module]; - statistics[language.iso639_2] = statistics[language.iso639_2] + Object.keys(messages).length; - } - var localizedMessages = []; - order.forEach(function (keyInfo) { - var key = null; - if (Is.string(keyInfo)) { - key = keyInfo; - } - else { - key = keyInfo.key; - } - var message = messages[key]; - if (!message) { - if (process.env['VSCODE_BUILD_VERBOSE']) { - log("No localized message found for key " + key + " in module " + module + ". Using default message."); - } - message = defaultMessages[module][key]; - statistics[language.iso639_2] = statistics[language.iso639_2] + 1; - } - localizedMessages.push(message); - }); - localizedModules[module] = localizedMessages; - }); - Object.keys(bundleSection).forEach(function (bundle) { - var modules = bundleSection[bundle]; - var contents = [ - fileHeader, - "define(\"" + bundle + ".nls." + language.iso639_2 + "\", {" - ]; - modules.forEach(function (module, index) { - contents.push("\t\"" + module + "\": ["); - var messages = localizedModules[module]; - if (!messages) { - emitter.emit('error', "Didn't find messages for module " + module + "."); - return; - } - messages.forEach(function (message, index) { - contents.push("\t\t\"" + escapeCharacters(message) + (index < messages.length ? '",' : '"')); - }); - contents.push(index < modules.length - 1 ? '\t],' : '\t]'); - }); - contents.push('});'); - emitter.emit('data', new File({ path: bundle + '.nls.' + language.iso639_2 + '.js', contents: new Buffer(contents.join('\n'), 'utf-8') })); - }); - }); - Object.keys(statistics).forEach(function (key) { - var value = statistics[key]; - log(key + " has " + value + " untranslated strings."); - }); - languageDirs.forEach(function (dir) { - var language = dir.name; - var iso639_2 = iso639_3_to_2[language]; - if (!iso639_2) { - log("\tCouldn't find iso639 2 mapping for language " + language + ". Using default language instead."); - } - else { - var stats = statistics[iso639_2]; - if (Is.undef(stats)) { - log("\tNo translations found for language " + language + ". Using default language instead."); - } - } - }); -} -function processNlsFiles(opts) { - return event_stream_1.through(function (file) { - var fileName = path.basename(file.path); - if (fileName === 'nls.metadata.json') { - var json = null; - if (file.isBuffer()) { - json = JSON.parse(file.contents.toString('utf8')); - } - else { - this.emit('error', "Failed to read component file: " + file.relative); - } - if (BundledFormat.is(json)) { - processCoreBundleFormat(opts.fileHeader, opts.languages, json, this); - } - } - this.emit('data', file); - }); -} -exports.processNlsFiles = processNlsFiles; -function prepareXlfFiles(projectName, extensionName) { - return event_stream_1.through(function (file) { - if (!file.isBuffer()) { - throw new Error("Failed to read component file: " + file.relative); - } - var extension = path.extname(file.path); - if (extension === '.json') { - var json = JSON.parse(file.contents.toString('utf8')); - if (BundledFormat.is(json)) { - importBundleJson(file, json, this); - } - else if (PackageJsonFormat.is(json) || ModuleJsonFormat.is(json)) { - importModuleOrPackageJson(file, json, projectName, this, extensionName); - } - else { - throw new Error("JSON format cannot be deduced for " + file.relative + "."); - } - } - else if (extension === '.isl') { - importIsl(file, this); - } - }); -} -exports.prepareXlfFiles = prepareXlfFiles; -var editorProject = 'vscode-editor', workbenchProject = 'vscode-workbench', extensionsProject = 'vscode-extensions', setupProject = 'vscode-setup'; -function getResource(sourceFile) { - var resource; - if (/^vs\/platform/.test(sourceFile)) { - return { name: 'vs/platform', project: editorProject }; - } - else if (/^vs\/editor\/contrib/.test(sourceFile)) { - return { name: 'vs/editor/contrib', project: editorProject }; - } - else if (/^vs\/editor/.test(sourceFile)) { - return { name: 'vs/editor', project: editorProject }; - } - else if (/^vs\/base/.test(sourceFile)) { - return { name: 'vs/base', project: editorProject }; - } - else if (/^vs\/code/.test(sourceFile)) { - return { name: 'vs/code', project: workbenchProject }; - } - else if (/^vs\/workbench\/parts/.test(sourceFile)) { - resource = sourceFile.split('/', 4).join('/'); - return { name: resource, project: workbenchProject }; - } - else if (/^vs\/workbench\/services/.test(sourceFile)) { - resource = sourceFile.split('/', 4).join('/'); - return { name: resource, project: workbenchProject }; - } - else if (/^vs\/workbench/.test(sourceFile)) { - return { name: 'vs/workbench', project: workbenchProject }; - } - throw new Error("Could not identify the XLF bundle for " + sourceFile); -} -exports.getResource = getResource; -function importBundleJson(file, json, stream) { - var bundleXlfs = Object.create(null); - for (var source in json.keys) { - var projectResource = getResource(source); - var resource = projectResource.name; - var project = projectResource.project; - var keys = json.keys[source]; - var messages = json.messages[source]; - if (keys.length !== messages.length) { - throw new Error("There is a mismatch between keys and messages in " + file.relative); - } - var xlf = bundleXlfs[resource] ? bundleXlfs[resource] : bundleXlfs[resource] = new XLF(project); - xlf.addFile('src/' + source, keys, messages); - } - for (var resource in bundleXlfs) { - var newFilePath = bundleXlfs[resource].project + "/" + resource.replace(/\//g, '_') + ".xlf"; - var xlfFile = new File({ path: newFilePath, contents: new Buffer(bundleXlfs[resource].toString(), 'utf-8') }); - stream.emit('data', xlfFile); - } -} -// Keeps existing XLF instances and a state of how many files were already processed for faster file emission -var extensions = Object.create(null); -function importModuleOrPackageJson(file, json, projectName, stream, extensionName) { - if (ModuleJsonFormat.is(json) && json['keys'].length !== json['messages'].length) { - throw new Error("There is a mismatch between keys and messages in " + file.relative); - } - // Prepare the source path for attribute in XLF & extract messages from JSON - var formattedSourcePath = file.relative.replace(/\\/g, '/'); - var messages = Object.keys(json).map(function (key) { return json[key].toString(); }); - // Stores the amount of localization files to be transformed to XLF before the emission - var localizationFilesCount, originalFilePath; - // If preparing XLF for external extension, then use different glob pattern and source path - if (extensionName) { - localizationFilesCount = glob.sync('**/*.nls.json').length; - originalFilePath = "" + formattedSourcePath.substr(0, formattedSourcePath.length - '.nls.json'.length); - } - else { - // Used for vscode/extensions folder - extensionName = formattedSourcePath.split('/')[0]; - localizationFilesCount = glob.sync("./extensions/" + extensionName + "/**/*.nls.json").length; - originalFilePath = "extensions/" + formattedSourcePath.substr(0, formattedSourcePath.length - '.nls.json'.length); - } - var extension = extensions[extensionName] ? - extensions[extensionName] : extensions[extensionName] = { xlf: new XLF(projectName), processed: 0 }; - if (ModuleJsonFormat.is(json)) { - extension.xlf.addFile(originalFilePath, json['keys'], json['messages']); - } - else { - extension.xlf.addFile(originalFilePath, Object.keys(json), messages); - } - // Check if XLF is populated with file nodes to emit it - if (++extensions[extensionName].processed === localizationFilesCount) { - var newFilePath = path.join(projectName, extensionName + '.xlf'); - var xlfFile = new File({ path: newFilePath, contents: new Buffer(extension.xlf.toString(), 'utf-8') }); - stream.emit('data', xlfFile); - } -} -function importIsl(file, stream) { - var projectName, resourceFile; - if (path.basename(file.path) === 'Default.isl') { - projectName = setupProject; - resourceFile = 'setup_default.xlf'; - } - else { - projectName = workbenchProject; - resourceFile = 'setup_messages.xlf'; - } - var xlf = new XLF(projectName), keys = [], messages = []; - var model = new TextModel(file.contents.toString()); - var inMessageSection = false; - model.lines.forEach(function (line) { - if (line.length === 0) { - return; - } - var firstChar = line.charAt(0); - switch (firstChar) { - case ';': - // Comment line; - return; - case '[': - inMessageSection = '[Messages]' === line || '[CustomMessages]' === line; - return; - } - if (!inMessageSection) { - return; - } - var sections = line.split('='); - if (sections.length !== 2) { - throw new Error("Badly formatted message found: " + line); - } - else { - var key = sections[0]; - var value = sections[1]; - if (key.length > 0 && value.length > 0) { - keys.push(key); - messages.push(value); - } - } - }); - var originalPath = file.path.substring(file.cwd.length + 1, file.path.split('.')[0].length).replace(/\\/g, '/'); - xlf.addFile(originalPath, keys, messages); - // Emit only upon all ISL files combined into single XLF instance - var newFilePath = path.join(projectName, resourceFile); - var xlfFile = new File({ path: newFilePath, contents: new Buffer(xlf.toString(), 'utf-8') }); - stream.emit('data', xlfFile); -} -function pushXlfFiles(apiHostname, username, password) { - var tryGetPromises = []; - var updateCreatePromises = []; - return event_stream_1.through(function (file) { - var project = path.dirname(file.relative); - var fileName = path.basename(file.path); - var slug = fileName.substr(0, fileName.length - '.xlf'.length); - var credentials = username + ":" + password; - // Check if resource already exists, if not, then create it. - var promise = tryGetResource(project, slug, apiHostname, credentials); - tryGetPromises.push(promise); - promise.then(function (exists) { - if (exists) { - promise = updateResource(project, slug, file, apiHostname, credentials); - } - else { - promise = createResource(project, slug, file, apiHostname, credentials); - } - updateCreatePromises.push(promise); - }); - }, function () { - var _this = this; - // End the pipe only after all the communication with Transifex API happened - Promise.all(tryGetPromises).then(function () { - Promise.all(updateCreatePromises).then(function () { - _this.emit('end'); - })["catch"](function (reason) { throw new Error(reason); }); - })["catch"](function (reason) { throw new Error(reason); }); - }); -} -exports.pushXlfFiles = pushXlfFiles; -function tryGetResource(project, slug, apiHostname, credentials) { - return new Promise(function (resolve, reject) { - var options = { - hostname: apiHostname, - path: "/api/2/project/" + project + "/resource/" + slug + "/?details", - auth: credentials, - method: 'GET' - }; - var request = http.request(options, function (response) { - if (response.statusCode === 404) { - resolve(false); - } - else if (response.statusCode === 200) { - resolve(true); - } - else { - reject("Failed to query resource " + project + "/" + slug + ". Response: " + response.statusCode + " " + response.statusMessage); - } - }); - request.on('error', function (err) { - reject("Failed to get " + project + "/" + slug + " on Transifex: " + err); - }); - request.end(); - }); -} -function createResource(project, slug, xlfFile, apiHostname, credentials) { - return new Promise(function (resolve, reject) { - var data = JSON.stringify({ - 'content': xlfFile.contents.toString(), - 'name': slug, - 'slug': slug, - 'i18n_type': 'XLIFF' - }); - var options = { - hostname: apiHostname, - path: "/api/2/project/" + project + "/resources", - headers: { - 'Content-Type': 'application/json', - 'Content-Length': Buffer.byteLength(data) - }, - auth: credentials, - method: 'POST' - }; - var request = http.request(options, function (res) { - if (res.statusCode === 201) { - log("Resource " + project + "/" + slug + " successfully created on Transifex."); - } - else { - reject("Something went wrong in the request creating " + slug + " in " + project + ". " + res.statusCode); - } - }); - request.on('error', function (err) { - reject("Failed to create " + project + "/" + slug + " on Transifex: " + err); - }); - request.write(data); - request.end(); - }); -} -/** - * The following link provides information about how Transifex handles updates of a resource file: - * https://dev.befoolish.co/tx-docs/public/projects/updating-content#what-happens-when-you-update-files - */ -function updateResource(project, slug, xlfFile, apiHostname, credentials) { - return new Promise(function (resolve, reject) { - var data = JSON.stringify({ content: xlfFile.contents.toString() }); - var options = { - hostname: apiHostname, - path: "/api/2/project/" + project + "/resource/" + slug + "/content", - headers: { - 'Content-Type': 'application/json', - 'Content-Length': Buffer.byteLength(data) - }, - auth: credentials, - method: 'PUT' - }; - var request = http.request(options, function (res) { - if (res.statusCode === 200) { - res.setEncoding('utf8'); - var responseBuffer_1 = ''; - res.on('data', function (chunk) { - responseBuffer_1 += chunk; - }); - res.on('end', function () { - var response = JSON.parse(responseBuffer_1); - log("Resource " + project + "/" + slug + " successfully updated on Transifex. Strings added: " + response.strings_added + ", updated: " + response.strings_added + ", deleted: " + response.strings_added); - resolve(); - }); - } - else { - reject("Something went wrong in the request updating " + slug + " in " + project + ". " + res.statusCode); - } - }); - request.on('error', function (err) { - reject("Failed to update " + project + "/" + slug + " on Transifex: " + err); - }); - request.write(data); - request.end(); - }); -} -function obtainProjectResources(projectName) { - var resources = []; - if (projectName === editorProject) { - var json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); - resources = JSON.parse(json).editor; - } - else if (projectName === workbenchProject) { - var json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); - resources = JSON.parse(json).workbench; - } - else if (projectName === extensionsProject) { - var extensionsToLocalize = glob.sync('./extensions/**/*.nls.json').map(function (extension) { return extension.split('/')[2]; }); - var resourcesToPull_1 = []; - extensionsToLocalize.forEach(function (extension) { - if (resourcesToPull_1.indexOf(extension) === -1) { - resourcesToPull_1.push(extension); - resources.push({ name: extension, project: projectName }); - } - }); - } - else if (projectName === setupProject) { - resources.push({ name: 'setup_default', project: setupProject }); - } - return resources; -} -function pullXlfFiles(projectName, apiHostname, username, password, languages, resources) { - if (!resources) { - resources = obtainProjectResources(projectName); - } - if (!resources) { - throw new Error('Transifex projects and resources must be defined to be able to pull translations from Transifex.'); - } - var credentials = username + ":" + password; - var expectedTranslationsCount = languages.length * resources.length; - var translationsRetrieved = 0, called = false; - return event_stream_1.readable(function (count, callback) { - // Mark end of stream when all resources were retrieved - if (translationsRetrieved === expectedTranslationsCount) { - return this.emit('end'); - } - if (!called) { - called = true; - var stream_1 = this; - // Retrieve XLF files from main projects - languages.map(function (language) { - resources.map(function (resource) { - retrieveResource(language, resource, apiHostname, credentials).then(function (file) { - stream_1.emit('data', file); - translationsRetrieved++; - })["catch"](function (error) { throw new Error(error); }); - }); - }); - } - callback(); - }); -} -exports.pullXlfFiles = pullXlfFiles; -function retrieveResource(language, resource, apiHostname, credentials) { - return new Promise(function (resolve, reject) { - var slug = resource.name.replace(/\//g, '_'); - var project = resource.project; - var iso639 = language.toLowerCase(); - var options = { - hostname: apiHostname, - path: "/api/2/project/" + project + "/resource/" + slug + "/translation/" + iso639 + "?file&mode=onlyreviewed", - auth: credentials, - method: 'GET' - }; - var request = http.request(options, function (res) { - var xlfBuffer = []; - res.on('data', function (chunk) { return xlfBuffer.push(chunk); }); - res.on('end', function () { - if (res.statusCode === 200) { - resolve(new File({ contents: Buffer.concat(xlfBuffer), path: project + "/" + iso639_2_to_3[language] + "/" + slug + ".xlf" })); - } - reject(slug + " in " + project + " returned no data. Response code: " + res.statusCode + "."); - }); - }); - request.on('error', function (err) { - reject("Failed to query resource " + slug + " with the following error: " + err); - }); - request.end(); - }); -} -function prepareJsonFiles() { - var parsePromises = []; - return event_stream_1.through(function (xlf) { - var stream = this; - var parsePromise = XLF.parse(xlf.contents.toString()); - parsePromises.push(parsePromise); - parsePromise.then(function (resolvedFiles) { - resolvedFiles.forEach(function (file) { - var messages = file.messages, translatedFile; - // ISL file path always starts with 'build/' - if (/^build\//.test(file.originalFilePath)) { - var defaultLanguages = { 'zh-hans': true, 'zh-hant': true, 'ko': true }; - if (path.basename(file.originalFilePath) === 'Default' && !defaultLanguages[file.language]) { - return; - } - translatedFile = createIslFile('..', file.originalFilePath, messages, iso639_2_to_3[file.language]); - } - else { - translatedFile = createI18nFile(iso639_2_to_3[file.language], file.originalFilePath, messages); - } - stream.emit('data', translatedFile); - }); - }, function (rejectReason) { - throw new Error("XLF parsing error: " + rejectReason); - }); - }, function () { - var _this = this; - Promise.all(parsePromises) - .then(function () { _this.emit('end'); })["catch"](function (reason) { throw new Error(reason); }); - }); -} -exports.prepareJsonFiles = prepareJsonFiles; -function createI18nFile(base, originalFilePath, messages) { - var content = [ - '/*---------------------------------------------------------------------------------------------', - ' * Copyright (c) Microsoft Corporation. All rights reserved.', - ' * Licensed under the MIT License. See License.txt in the project root for license information.', - ' *--------------------------------------------------------------------------------------------*/', - '// Do not edit this file. It is machine generated.' - ].join('\n') + '\n' + JSON.stringify(messages, null, '\t').replace(/\r\n/g, '\n'); - return new File({ - path: path.join(base, originalFilePath + '.i18n.json'), - contents: new Buffer(content, 'utf8') - }); -} -var languageNames = { - 'chs': 'Simplified Chinese', - 'cht': 'Traditional Chinese', - 'kor': 'Korean' -}; -var languageIds = { - 'chs': '$0804', - 'cht': '$0404', - 'kor': '$0412' -}; -var encodings = { - 'chs': 'CP936', - 'cht': 'CP950', - 'jpn': 'CP932', - 'kor': 'CP949', - 'deu': 'CP1252', - 'fra': 'CP1252', - 'esn': 'CP1252', - 'rus': 'CP1251', - 'ita': 'CP1252', - 'ptb': 'CP1252', - 'hun': 'CP1250', - 'trk': 'CP1254' -}; -function createIslFile(base, originalFilePath, messages, language) { - var content = []; - var originalContent; - if (path.basename(originalFilePath) === 'Default') { - originalContent = new TextModel(fs.readFileSync(originalFilePath + '.isl', 'utf8')); - } - else { - originalContent = new TextModel(fs.readFileSync(originalFilePath + '.en.isl', 'utf8')); - } - originalContent.lines.forEach(function (line) { - if (line.length > 0) { - var firstChar = line.charAt(0); - if (firstChar === '[' || firstChar === ';') { - if (line === '; *** Inno Setup version 5.5.3+ English messages ***') { - content.push("; *** Inno Setup version 5.5.3+ " + languageNames[language] + " messages ***"); - } - else { - content.push(line); - } - } - else { - var sections = line.split('='); - var key = sections[0]; - var translated = line; - if (key) { - if (key === 'LanguageName') { - translated = key + "=" + languageNames[language]; - } - else if (key === 'LanguageID') { - translated = key + "=" + languageIds[language]; - } - else if (key === 'LanguageCodePage') { - translated = key + "=" + encodings[language].substr(2); - } - else { - var translatedMessage = messages[key]; - if (translatedMessage) { - translated = key + "=" + translatedMessage; - } - } - } - content.push(translated); - } - } - }); - var tag = iso639_3_to_2[language]; - var basename = path.basename(originalFilePath); - var filePath = path.join(base, path.dirname(originalFilePath), basename) + "." + tag + ".isl"; - return new File({ - path: filePath, - contents: iconv.encode(new Buffer(content.join('\r\n'), 'utf8'), encodings[language]) - }); -} -function encodeEntities(value) { - var result = []; - for (var i = 0; i < value.length; i++) { - var ch = value[i]; - switch (ch) { - case '<': - result.push('<'); - break; - case '>': - result.push('>'); - break; - case '&': - result.push('&'); - break; - default: - result.push(ch); - } - } - return result.join(''); -} -function decodeEntities(value) { - return value.replace(/</g, '<').replace(/>/g, '>').replace(/&/g, '&'); -} +"use strict"; +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +Object.defineProperty(exports, "__esModule", { value: true }); +var path = require("path"); +var fs = require("fs"); +var event_stream_1 = require("event-stream"); +var File = require("vinyl"); +var Is = require("is"); +var xml2js = require("xml2js"); +var glob = require("glob"); +var http = require("http"); +var util = require('gulp-util'); +var iconv = require('iconv-lite'); +function log(message) { + var rest = []; + for (var _i = 1; _i < arguments.length; _i++) { + rest[_i - 1] = arguments[_i]; + } + util.log.apply(util, [util.colors.green('[i18n]'), message].concat(rest)); +} +var LocalizeInfo; +(function (LocalizeInfo) { + function is(value) { + var candidate = value; + return Is.defined(candidate) && Is.string(candidate.key) && (Is.undef(candidate.comment) || (Is.array(candidate.comment) && candidate.comment.every(function (element) { return Is.string(element); }))); + } + LocalizeInfo.is = is; +})(LocalizeInfo || (LocalizeInfo = {})); +var BundledFormat; +(function (BundledFormat) { + function is(value) { + if (Is.undef(value)) { + return false; + } + var candidate = value; + var length = Object.keys(value).length; + return length === 3 && Is.defined(candidate.keys) && Is.defined(candidate.messages) && Is.defined(candidate.bundles); + } + BundledFormat.is = is; +})(BundledFormat || (BundledFormat = {})); +var PackageJsonFormat; +(function (PackageJsonFormat) { + function is(value) { + if (Is.undef(value) || !Is.object(value)) { + return false; + } + return Object.keys(value).every(function (key) { + var element = value[key]; + return Is.string(element) || (Is.object(element) && Is.defined(element.message) && Is.defined(element.comment)); + }); + } + PackageJsonFormat.is = is; +})(PackageJsonFormat || (PackageJsonFormat = {})); +var ModuleJsonFormat; +(function (ModuleJsonFormat) { + function is(value) { + var candidate = value; + return Is.defined(candidate) + && Is.array(candidate.messages) && candidate.messages.every(function (message) { return Is.string(message); }) + && Is.array(candidate.keys) && candidate.keys.every(function (key) { return Is.string(key) || LocalizeInfo.is(key); }); + } + ModuleJsonFormat.is = is; +})(ModuleJsonFormat || (ModuleJsonFormat = {})); +var Line = (function () { + function Line(indent) { + if (indent === void 0) { indent = 0; } + this.indent = indent; + this.buffer = []; + if (indent > 0) { + this.buffer.push(new Array(indent + 1).join(' ')); + } + } + Line.prototype.append = function (value) { + this.buffer.push(value); + return this; + }; + Line.prototype.toString = function () { + return this.buffer.join(''); + }; + return Line; +}()); +exports.Line = Line; +var TextModel = (function () { + function TextModel(contents) { + this._lines = contents.split(/\r\n|\r|\n/); + } + Object.defineProperty(TextModel.prototype, "lines", { + get: function () { + return this._lines; + }, + enumerable: true, + configurable: true + }); + return TextModel; +}()); +var XLF = (function () { + function XLF(project) { + this.project = project; + this.buffer = []; + this.files = Object.create(null); + } + XLF.prototype.toString = function () { + this.appendHeader(); + for (var file in this.files) { + this.appendNewLine("", 2); + for (var _i = 0, _a = this.files[file]; _i < _a.length; _i++) { + var item = _a[_i]; + this.addStringItem(item); + } + this.appendNewLine('', 2); + } + this.appendFooter(); + return this.buffer.join('\r\n'); + }; + XLF.prototype.addFile = function (original, keys, messages) { + this.files[original] = []; + var existingKeys = []; + for (var _i = 0, keys_1 = keys; _i < keys_1.length; _i++) { + var key = keys_1[_i]; + // Ignore duplicate keys because Transifex does not populate those with translated values. + if (existingKeys.indexOf(key) !== -1) { + continue; + } + existingKeys.push(key); + var message = encodeEntities(messages[keys.indexOf(key)]); + var comment = undefined; + // Check if the message contains description (if so, it becomes an object type in JSON) + if (Is.string(key)) { + this.files[original].push({ id: key, message: message, comment: comment }); + } + else { + if (key['comment'] && key['comment'].length > 0) { + comment = key['comment'].map(function (comment) { return encodeEntities(comment); }).join('\r\n'); + } + this.files[original].push({ id: key['key'], message: message, comment: comment }); + } + } + }; + XLF.prototype.addStringItem = function (item) { + if (!item.id || !item.message) { + throw new Error('No item ID or value specified.'); + } + this.appendNewLine("", 4); + this.appendNewLine("" + item.message + "", 6); + if (item.comment) { + this.appendNewLine("" + item.comment + "", 6); + } + this.appendNewLine('', 4); + }; + XLF.prototype.appendHeader = function () { + this.appendNewLine('', 0); + this.appendNewLine('', 0); + }; + XLF.prototype.appendFooter = function () { + this.appendNewLine('', 0); + }; + XLF.prototype.appendNewLine = function (content, indent) { + var line = new Line(indent); + line.append(content); + this.buffer.push(line.toString()); + }; + return XLF; +}()); +XLF.parse = function (xlfString) { + return new Promise(function (resolve, reject) { + var parser = new xml2js.Parser(); + var files = []; + parser.parseString(xlfString, function (err, result) { + if (err) { + reject("Failed to parse XLIFF string. " + err); + } + var fileNodes = result['xliff']['file']; + if (!fileNodes) { + reject('XLIFF file does not contain "xliff" or "file" node(s) required for parsing.'); + } + fileNodes.forEach(function (file) { + var originalFilePath = file.$.original; + if (!originalFilePath) { + reject('XLIFF file node does not contain original attribute to determine the original location of the resource file.'); + } + var language = file.$['target-language'].toLowerCase(); + if (!language) { + reject('XLIFF file node does not contain target-language attribute to determine translated language.'); + } + var messages = {}; + var transUnits = file.body[0]['trans-unit']; + transUnits.forEach(function (unit) { + var key = unit.$.id; + if (!unit.target) { + return; // No translation available + } + var val = unit.target.toString(); + if (key && val) { + messages[key] = decodeEntities(val); + } + else { + reject('XLIFF file does not contain full localization data. ID or target translation for one of the trans-unit nodes is not present.'); + } + }); + files.push({ messages: messages, originalFilePath: originalFilePath, language: language }); + }); + resolve(files); + }); + }); +}; +exports.XLF = XLF; +var iso639_3_to_2 = { + 'chs': 'zh-cn', + 'cht': 'zh-tw', + 'csy': 'cs-cz', + 'deu': 'de', + 'enu': 'en', + 'esn': 'es', + 'fra': 'fr', + 'hun': 'hu', + 'ita': 'it', + 'jpn': 'ja', + 'kor': 'ko', + 'nld': 'nl', + 'plk': 'pl', + 'ptb': 'pt-br', + 'ptg': 'pt', + 'rus': 'ru', + 'sve': 'sv-se', + 'trk': 'tr' +}; +/** + * Used to map Transifex to VS Code language code representation. + */ +var iso639_2_to_3 = { + 'zh-hans': 'chs', + 'zh-hant': 'cht', + 'cs-cz': 'csy', + 'de': 'deu', + 'en': 'enu', + 'es': 'esn', + 'fr': 'fra', + 'hu': 'hun', + 'it': 'ita', + 'ja': 'jpn', + 'ko': 'kor', + 'nl': 'nld', + 'pl': 'plk', + 'pt-br': 'ptb', + 'pt': 'ptg', + 'ru': 'rus', + 'sv-se': 'sve', + 'tr': 'trk' +}; +function sortLanguages(directoryNames) { + return directoryNames.map(function (dirName) { + var lower = dirName.toLowerCase(); + return { + name: lower, + iso639_2: iso639_3_to_2[lower] + }; + }).sort(function (a, b) { + if (!a.iso639_2 && !b.iso639_2) { + return 0; + } + if (!a.iso639_2) { + return -1; + } + if (!b.iso639_2) { + return 1; + } + return a.iso639_2 < b.iso639_2 ? -1 : (a.iso639_2 > b.iso639_2 ? 1 : 0); + }); +} +function stripComments(content) { + /** + * First capturing group matches double quoted string + * Second matches single quotes string + * Third matches block comments + * Fourth matches line comments + */ + var regexp = /("(?:[^\\\"]*(?:\\.)?)*")|('(?:[^\\\']*(?:\\.)?)*')|(\/\*(?:\r?\n|.)*?\*\/)|(\/{2,}.*?(?:(?:\r?\n)|$))/g; + var result = content.replace(regexp, function (match, m1, m2, m3, m4) { + // Only one of m1, m2, m3, m4 matches + if (m3) { + // A block comment. Replace with nothing + return ''; + } + else if (m4) { + // A line comment. If it ends in \r?\n then keep it. + var length_1 = m4.length; + if (length_1 > 2 && m4[length_1 - 1] === '\n') { + return m4[length_1 - 2] === '\r' ? '\r\n' : '\n'; + } + else { + return ''; + } + } + else { + // We match a string + return match; + } + }); + return result; +} +function escapeCharacters(value) { + var result = []; + for (var i = 0; i < value.length; i++) { + var ch = value.charAt(i); + switch (ch) { + case '\'': + result.push('\\\''); + break; + case '"': + result.push('\\"'); + break; + case '\\': + result.push('\\\\'); + break; + case '\n': + result.push('\\n'); + break; + case '\r': + result.push('\\r'); + break; + case '\t': + result.push('\\t'); + break; + case '\b': + result.push('\\b'); + break; + case '\f': + result.push('\\f'); + break; + default: + result.push(ch); + } + } + return result.join(''); +} +function processCoreBundleFormat(fileHeader, languages, json, emitter) { + var keysSection = json.keys; + var messageSection = json.messages; + var bundleSection = json.bundles; + var statistics = Object.create(null); + var total = 0; + var defaultMessages = Object.create(null); + var modules = Object.keys(keysSection); + modules.forEach(function (module) { + var keys = keysSection[module]; + var messages = messageSection[module]; + if (!messages || keys.length !== messages.length) { + emitter.emit('error', "Message for module " + module + " corrupted. Mismatch in number of keys and messages."); + return; + } + var messageMap = Object.create(null); + defaultMessages[module] = messageMap; + keys.map(function (key, i) { + total++; + if (Is.string(key)) { + messageMap[key] = messages[i]; + } + else { + messageMap[key.key] = messages[i]; + } + }); + }); + var languageDirectory = path.join(__dirname, '..', '..', 'i18n'); + var languageDirs; + if (languages) { + languageDirs = sortLanguages(languages); + } + else { + languageDirs = sortLanguages(fs.readdirSync(languageDirectory).filter(function (item) { return fs.statSync(path.join(languageDirectory, item)).isDirectory(); })); + } + languageDirs.forEach(function (language) { + if (!language.iso639_2) { + return; + } + if (process.env['VSCODE_BUILD_VERBOSE']) { + log("Generating nls bundles for: " + language.iso639_2); + } + statistics[language.iso639_2] = 0; + var localizedModules = Object.create(null); + var cwd = path.join(languageDirectory, language.name, 'src'); + modules.forEach(function (module) { + var order = keysSection[module]; + var i18nFile = path.join(cwd, module) + '.i18n.json'; + var messages = null; + if (fs.existsSync(i18nFile)) { + var content = stripComments(fs.readFileSync(i18nFile, 'utf8')); + messages = JSON.parse(content); + } + else { + if (process.env['VSCODE_BUILD_VERBOSE']) { + log("No localized messages found for module " + module + ". Using default messages."); + } + messages = defaultMessages[module]; + statistics[language.iso639_2] = statistics[language.iso639_2] + Object.keys(messages).length; + } + var localizedMessages = []; + order.forEach(function (keyInfo) { + var key = null; + if (Is.string(keyInfo)) { + key = keyInfo; + } + else { + key = keyInfo.key; + } + var message = messages[key]; + if (!message) { + if (process.env['VSCODE_BUILD_VERBOSE']) { + log("No localized message found for key " + key + " in module " + module + ". Using default message."); + } + message = defaultMessages[module][key]; + statistics[language.iso639_2] = statistics[language.iso639_2] + 1; + } + localizedMessages.push(message); + }); + localizedModules[module] = localizedMessages; + }); + Object.keys(bundleSection).forEach(function (bundle) { + var modules = bundleSection[bundle]; + var contents = [ + fileHeader, + "define(\"" + bundle + ".nls." + language.iso639_2 + "\", {" + ]; + modules.forEach(function (module, index) { + contents.push("\t\"" + module + "\": ["); + var messages = localizedModules[module]; + if (!messages) { + emitter.emit('error', "Didn't find messages for module " + module + "."); + return; + } + messages.forEach(function (message, index) { + contents.push("\t\t\"" + escapeCharacters(message) + (index < messages.length ? '",' : '"')); + }); + contents.push(index < modules.length - 1 ? '\t],' : '\t]'); + }); + contents.push('});'); + emitter.emit('data', new File({ path: bundle + '.nls.' + language.iso639_2 + '.js', contents: new Buffer(contents.join('\n'), 'utf-8') })); + }); + }); + Object.keys(statistics).forEach(function (key) { + var value = statistics[key]; + log(key + " has " + value + " untranslated strings."); + }); + languageDirs.forEach(function (dir) { + var language = dir.name; + var iso639_2 = iso639_3_to_2[language]; + if (!iso639_2) { + log("\tCouldn't find iso639 2 mapping for language " + language + ". Using default language instead."); + } + else { + var stats = statistics[iso639_2]; + if (Is.undef(stats)) { + log("\tNo translations found for language " + language + ". Using default language instead."); + } + } + }); +} +function processNlsFiles(opts) { + return event_stream_1.through(function (file) { + var fileName = path.basename(file.path); + if (fileName === 'nls.metadata.json') { + var json = null; + if (file.isBuffer()) { + json = JSON.parse(file.contents.toString('utf8')); + } + else { + this.emit('error', "Failed to read component file: " + file.relative); + } + if (BundledFormat.is(json)) { + processCoreBundleFormat(opts.fileHeader, opts.languages, json, this); + } + } + this.emit('data', file); + }); +} +exports.processNlsFiles = processNlsFiles; +function prepareXlfFiles(projectName, extensionName) { + return event_stream_1.through(function (file) { + if (!file.isBuffer()) { + throw new Error("Failed to read component file: " + file.relative); + } + var extension = path.extname(file.path); + if (extension === '.json') { + var json = JSON.parse(file.contents.toString('utf8')); + if (BundledFormat.is(json)) { + importBundleJson(file, json, this); + } + else if (PackageJsonFormat.is(json) || ModuleJsonFormat.is(json)) { + importModuleOrPackageJson(file, json, projectName, this, extensionName); + } + else { + throw new Error("JSON format cannot be deduced for " + file.relative + "."); + } + } + else if (extension === '.isl') { + importIsl(file, this); + } + }); +} +exports.prepareXlfFiles = prepareXlfFiles; +var editorProject = 'vscode-editor', workbenchProject = 'vscode-workbench', extensionsProject = 'vscode-extensions', setupProject = 'vscode-setup'; +function getResource(sourceFile) { + var resource; + if (/^vs\/platform/.test(sourceFile)) { + return { name: 'vs/platform', project: editorProject }; + } + else if (/^vs\/editor\/contrib/.test(sourceFile)) { + return { name: 'vs/editor/contrib', project: editorProject }; + } + else if (/^vs\/editor/.test(sourceFile)) { + return { name: 'vs/editor', project: editorProject }; + } + else if (/^vs\/base/.test(sourceFile)) { + return { name: 'vs/base', project: editorProject }; + } + else if (/^vs\/code/.test(sourceFile)) { + return { name: 'vs/code', project: workbenchProject }; + } + else if (/^vs\/workbench\/parts/.test(sourceFile)) { + resource = sourceFile.split('/', 4).join('/'); + return { name: resource, project: workbenchProject }; + } + else if (/^vs\/workbench\/services/.test(sourceFile)) { + resource = sourceFile.split('/', 4).join('/'); + return { name: resource, project: workbenchProject }; + } + else if (/^vs\/workbench/.test(sourceFile)) { + return { name: 'vs/workbench', project: workbenchProject }; + } + throw new Error("Could not identify the XLF bundle for " + sourceFile); +} +exports.getResource = getResource; +function importBundleJson(file, json, stream) { + var bundleXlfs = Object.create(null); + for (var source in json.keys) { + var projectResource = getResource(source); + var resource = projectResource.name; + var project = projectResource.project; + var keys = json.keys[source]; + var messages = json.messages[source]; + if (keys.length !== messages.length) { + throw new Error("There is a mismatch between keys and messages in " + file.relative); + } + var xlf = bundleXlfs[resource] ? bundleXlfs[resource] : bundleXlfs[resource] = new XLF(project); + xlf.addFile('src/' + source, keys, messages); + } + for (var resource in bundleXlfs) { + var newFilePath = bundleXlfs[resource].project + "/" + resource.replace(/\//g, '_') + ".xlf"; + var xlfFile = new File({ path: newFilePath, contents: new Buffer(bundleXlfs[resource].toString(), 'utf-8') }); + stream.emit('data', xlfFile); + } +} +// Keeps existing XLF instances and a state of how many files were already processed for faster file emission +var extensions = Object.create(null); +function importModuleOrPackageJson(file, json, projectName, stream, extensionName) { + if (ModuleJsonFormat.is(json) && json['keys'].length !== json['messages'].length) { + throw new Error("There is a mismatch between keys and messages in " + file.relative); + } + // Prepare the source path for attribute in XLF & extract messages from JSON + var formattedSourcePath = file.relative.replace(/\\/g, '/'); + var messages = Object.keys(json).map(function (key) { return json[key].toString(); }); + // Stores the amount of localization files to be transformed to XLF before the emission + var localizationFilesCount, originalFilePath; + // If preparing XLF for external extension, then use different glob pattern and source path + if (extensionName) { + localizationFilesCount = glob.sync('**/*.nls.json').length; + originalFilePath = "" + formattedSourcePath.substr(0, formattedSourcePath.length - '.nls.json'.length); + } + else { + // Used for vscode/extensions folder + extensionName = formattedSourcePath.split('/')[0]; + localizationFilesCount = glob.sync("./extensions/" + extensionName + "/**/*.nls.json").length; + originalFilePath = "extensions/" + formattedSourcePath.substr(0, formattedSourcePath.length - '.nls.json'.length); + } + var extension = extensions[extensionName] ? + extensions[extensionName] : extensions[extensionName] = { xlf: new XLF(projectName), processed: 0 }; + if (ModuleJsonFormat.is(json)) { + extension.xlf.addFile(originalFilePath, json['keys'], json['messages']); + } + else { + extension.xlf.addFile(originalFilePath, Object.keys(json), messages); + } + // Check if XLF is populated with file nodes to emit it + if (++extensions[extensionName].processed === localizationFilesCount) { + var newFilePath = path.join(projectName, extensionName + '.xlf'); + var xlfFile = new File({ path: newFilePath, contents: new Buffer(extension.xlf.toString(), 'utf-8') }); + stream.emit('data', xlfFile); + } +} +function importIsl(file, stream) { + var projectName, resourceFile; + if (path.basename(file.path) === 'Default.isl') { + projectName = setupProject; + resourceFile = 'setup_default.xlf'; + } + else { + projectName = workbenchProject; + resourceFile = 'setup_messages.xlf'; + } + var xlf = new XLF(projectName), keys = [], messages = []; + var model = new TextModel(file.contents.toString()); + var inMessageSection = false; + model.lines.forEach(function (line) { + if (line.length === 0) { + return; + } + var firstChar = line.charAt(0); + switch (firstChar) { + case ';': + // Comment line; + return; + case '[': + inMessageSection = '[Messages]' === line || '[CustomMessages]' === line; + return; + } + if (!inMessageSection) { + return; + } + var sections = line.split('='); + if (sections.length !== 2) { + throw new Error("Badly formatted message found: " + line); + } + else { + var key = sections[0]; + var value = sections[1]; + if (key.length > 0 && value.length > 0) { + keys.push(key); + messages.push(value); + } + } + }); + var originalPath = file.path.substring(file.cwd.length + 1, file.path.split('.')[0].length).replace(/\\/g, '/'); + xlf.addFile(originalPath, keys, messages); + // Emit only upon all ISL files combined into single XLF instance + var newFilePath = path.join(projectName, resourceFile); + var xlfFile = new File({ path: newFilePath, contents: new Buffer(xlf.toString(), 'utf-8') }); + stream.emit('data', xlfFile); +} +function pushXlfFiles(apiHostname, username, password) { + var tryGetPromises = []; + var updateCreatePromises = []; + return event_stream_1.through(function (file) { + var project = path.dirname(file.relative); + var fileName = path.basename(file.path); + var slug = fileName.substr(0, fileName.length - '.xlf'.length); + var credentials = username + ":" + password; + // Check if resource already exists, if not, then create it. + var promise = tryGetResource(project, slug, apiHostname, credentials); + tryGetPromises.push(promise); + promise.then(function (exists) { + if (exists) { + promise = updateResource(project, slug, file, apiHostname, credentials); + } + else { + promise = createResource(project, slug, file, apiHostname, credentials); + } + updateCreatePromises.push(promise); + }); + }, function () { + var _this = this; + // End the pipe only after all the communication with Transifex API happened + Promise.all(tryGetPromises).then(function () { + Promise.all(updateCreatePromises).then(function () { + _this.emit('end'); + }).catch(function (reason) { throw new Error(reason); }); + }).catch(function (reason) { throw new Error(reason); }); + }); +} +exports.pushXlfFiles = pushXlfFiles; +function tryGetResource(project, slug, apiHostname, credentials) { + return new Promise(function (resolve, reject) { + var options = { + hostname: apiHostname, + path: "/api/2/project/" + project + "/resource/" + slug + "/?details", + auth: credentials, + method: 'GET' + }; + var request = http.request(options, function (response) { + if (response.statusCode === 404) { + resolve(false); + } + else if (response.statusCode === 200) { + resolve(true); + } + else { + reject("Failed to query resource " + project + "/" + slug + ". Response: " + response.statusCode + " " + response.statusMessage); + } + }); + request.on('error', function (err) { + reject("Failed to get " + project + "/" + slug + " on Transifex: " + err); + }); + request.end(); + }); +} +function createResource(project, slug, xlfFile, apiHostname, credentials) { + return new Promise(function (resolve, reject) { + var data = JSON.stringify({ + 'content': xlfFile.contents.toString(), + 'name': slug, + 'slug': slug, + 'i18n_type': 'XLIFF' + }); + var options = { + hostname: apiHostname, + path: "/api/2/project/" + project + "/resources", + headers: { + 'Content-Type': 'application/json', + 'Content-Length': Buffer.byteLength(data) + }, + auth: credentials, + method: 'POST' + }; + var request = http.request(options, function (res) { + if (res.statusCode === 201) { + log("Resource " + project + "/" + slug + " successfully created on Transifex."); + } + else { + reject("Something went wrong in the request creating " + slug + " in " + project + ". " + res.statusCode); + } + }); + request.on('error', function (err) { + reject("Failed to create " + project + "/" + slug + " on Transifex: " + err); + }); + request.write(data); + request.end(); + }); +} +/** + * The following link provides information about how Transifex handles updates of a resource file: + * https://dev.befoolish.co/tx-docs/public/projects/updating-content#what-happens-when-you-update-files + */ +function updateResource(project, slug, xlfFile, apiHostname, credentials) { + return new Promise(function (resolve, reject) { + var data = JSON.stringify({ content: xlfFile.contents.toString() }); + var options = { + hostname: apiHostname, + path: "/api/2/project/" + project + "/resource/" + slug + "/content", + headers: { + 'Content-Type': 'application/json', + 'Content-Length': Buffer.byteLength(data) + }, + auth: credentials, + method: 'PUT' + }; + var request = http.request(options, function (res) { + if (res.statusCode === 200) { + res.setEncoding('utf8'); + var responseBuffer_1 = ''; + res.on('data', function (chunk) { + responseBuffer_1 += chunk; + }); + res.on('end', function () { + var response = JSON.parse(responseBuffer_1); + log("Resource " + project + "/" + slug + " successfully updated on Transifex. Strings added: " + response.strings_added + ", updated: " + response.strings_added + ", deleted: " + response.strings_added); + resolve(); + }); + } + else { + reject("Something went wrong in the request updating " + slug + " in " + project + ". " + res.statusCode); + } + }); + request.on('error', function (err) { + reject("Failed to update " + project + "/" + slug + " on Transifex: " + err); + }); + request.write(data); + request.end(); + }); +} +function obtainProjectResources(projectName) { + var resources = []; + if (projectName === editorProject) { + var json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); + resources = JSON.parse(json).editor; + } + else if (projectName === workbenchProject) { + var json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); + resources = JSON.parse(json).workbench; + } + else if (projectName === extensionsProject) { + var extensionsToLocalize = glob.sync('./extensions/**/*.nls.json').map(function (extension) { return extension.split('/')[2]; }); + var resourcesToPull_1 = []; + extensionsToLocalize.forEach(function (extension) { + if (resourcesToPull_1.indexOf(extension) === -1) { + resourcesToPull_1.push(extension); + resources.push({ name: extension, project: projectName }); + } + }); + } + else if (projectName === setupProject) { + resources.push({ name: 'setup_default', project: setupProject }); + } + return resources; +} +function pullXlfFiles(projectName, apiHostname, username, password, languages, resources) { + if (!resources) { + resources = obtainProjectResources(projectName); + } + if (!resources) { + throw new Error('Transifex projects and resources must be defined to be able to pull translations from Transifex.'); + } + var credentials = username + ":" + password; + var expectedTranslationsCount = languages.length * resources.length; + var translationsRetrieved = 0, called = false; + return event_stream_1.readable(function (count, callback) { + // Mark end of stream when all resources were retrieved + if (translationsRetrieved === expectedTranslationsCount) { + return this.emit('end'); + } + if (!called) { + called = true; + var stream_1 = this; + // Retrieve XLF files from main projects + languages.map(function (language) { + resources.map(function (resource) { + retrieveResource(language, resource, apiHostname, credentials).then(function (file) { + stream_1.emit('data', file); + translationsRetrieved++; + }).catch(function (error) { throw new Error(error); }); + }); + }); + } + callback(); + }); +} +exports.pullXlfFiles = pullXlfFiles; +function retrieveResource(language, resource, apiHostname, credentials) { + return new Promise(function (resolve, reject) { + var slug = resource.name.replace(/\//g, '_'); + var project = resource.project; + var iso639 = language.toLowerCase(); + var options = { + hostname: apiHostname, + path: "/api/2/project/" + project + "/resource/" + slug + "/translation/" + iso639 + "?file&mode=onlyreviewed", + auth: credentials, + method: 'GET' + }; + var request = http.request(options, function (res) { + var xlfBuffer = []; + res.on('data', function (chunk) { return xlfBuffer.push(chunk); }); + res.on('end', function () { + if (res.statusCode === 200) { + resolve(new File({ contents: Buffer.concat(xlfBuffer), path: project + "/" + iso639_2_to_3[language] + "/" + slug + ".xlf" })); + } + reject(slug + " in " + project + " returned no data. Response code: " + res.statusCode + "."); + }); + }); + request.on('error', function (err) { + reject("Failed to query resource " + slug + " with the following error: " + err); + }); + request.end(); + }); +} +function prepareJsonFiles() { + var parsePromises = []; + return event_stream_1.through(function (xlf) { + var stream = this; + var parsePromise = XLF.parse(xlf.contents.toString()); + parsePromises.push(parsePromise); + parsePromise.then(function (resolvedFiles) { + resolvedFiles.forEach(function (file) { + var messages = file.messages, translatedFile; + // ISL file path always starts with 'build/' + if (/^build\//.test(file.originalFilePath)) { + var defaultLanguages = { 'zh-hans': true, 'zh-hant': true, 'ko': true }; + if (path.basename(file.originalFilePath) === 'Default' && !defaultLanguages[file.language]) { + return; + } + translatedFile = createIslFile('..', file.originalFilePath, messages, iso639_2_to_3[file.language]); + } + else { + translatedFile = createI18nFile(iso639_2_to_3[file.language], file.originalFilePath, messages); + } + stream.emit('data', translatedFile); + }); + }, function (rejectReason) { + throw new Error("XLF parsing error: " + rejectReason); + }); + }, function () { + var _this = this; + Promise.all(parsePromises) + .then(function () { _this.emit('end'); }) + .catch(function (reason) { throw new Error(reason); }); + }); +} +exports.prepareJsonFiles = prepareJsonFiles; +function createI18nFile(base, originalFilePath, messages) { + var content = [ + '/*---------------------------------------------------------------------------------------------', + ' * Copyright (c) Microsoft Corporation. All rights reserved.', + ' * Licensed under the MIT License. See License.txt in the project root for license information.', + ' *--------------------------------------------------------------------------------------------*/', + '// Do not edit this file. It is machine generated.' + ].join('\n') + '\n' + JSON.stringify(messages, null, '\t').replace(/\r\n/g, '\n'); + return new File({ + path: path.join(base, originalFilePath + '.i18n.json'), + contents: new Buffer(content, 'utf8') + }); +} +var languageNames = { + 'chs': 'Simplified Chinese', + 'cht': 'Traditional Chinese', + 'kor': 'Korean' +}; +var languageIds = { + 'chs': '$0804', + 'cht': '$0404', + 'kor': '$0412' +}; +var encodings = { + 'chs': 'CP936', + 'cht': 'CP950', + 'jpn': 'CP932', + 'kor': 'CP949', + 'deu': 'CP1252', + 'fra': 'CP1252', + 'esn': 'CP1252', + 'rus': 'CP1251', + 'ita': 'CP1252', + 'ptb': 'CP1252', + 'hun': 'CP1250', + 'trk': 'CP1254' +}; +function createIslFile(base, originalFilePath, messages, language) { + var content = []; + var originalContent; + if (path.basename(originalFilePath) === 'Default') { + originalContent = new TextModel(fs.readFileSync(originalFilePath + '.isl', 'utf8')); + } + else { + originalContent = new TextModel(fs.readFileSync(originalFilePath + '.en.isl', 'utf8')); + } + originalContent.lines.forEach(function (line) { + if (line.length > 0) { + var firstChar = line.charAt(0); + if (firstChar === '[' || firstChar === ';') { + if (line === '; *** Inno Setup version 5.5.3+ English messages ***') { + content.push("; *** Inno Setup version 5.5.3+ " + languageNames[language] + " messages ***"); + } + else { + content.push(line); + } + } + else { + var sections = line.split('='); + var key = sections[0]; + var translated = line; + if (key) { + if (key === 'LanguageName') { + translated = key + "=" + languageNames[language]; + } + else if (key === 'LanguageID') { + translated = key + "=" + languageIds[language]; + } + else if (key === 'LanguageCodePage') { + translated = key + "=" + encodings[language].substr(2); + } + else { + var translatedMessage = messages[key]; + if (translatedMessage) { + translated = key + "=" + translatedMessage; + } + } + } + content.push(translated); + } + } + }); + var tag = iso639_3_to_2[language]; + var basename = path.basename(originalFilePath); + var filePath = path.join(base, path.dirname(originalFilePath), basename) + "." + tag + ".isl"; + return new File({ + path: filePath, + contents: iconv.encode(new Buffer(content.join('\r\n'), 'utf8'), encodings[language]) + }); +} +function encodeEntities(value) { + var result = []; + for (var i = 0; i < value.length; i++) { + var ch = value[i]; + switch (ch) { + case '<': + result.push('<'); + break; + case '>': + result.push('>'); + break; + case '&': + result.push('&'); + break; + default: + result.push(ch); + } + } + return result.join(''); +} +function decodeEntities(value) { + return value.replace(/</g, '<').replace(/>/g, '>').replace(/&/g, '&'); +} diff --git a/build/lib/tslint/translationRemindRule.js b/build/lib/tslint/translationRemindRule.js index 8db41098be5..53e6929d8e6 100644 --- a/build/lib/tslint/translationRemindRule.js +++ b/build/lib/tslint/translationRemindRule.js @@ -1,72 +1,72 @@ -"use strict"; -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ -var __extends = (this && this.__extends) || (function () { - var extendStatics = Object.setPrototypeOf || - ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; - return function (d, b) { - extendStatics(d, b); - function __() { this.constructor = d; } - d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); - }; -})(); -exports.__esModule = true; -var Lint = require("tslint"); -var fs = require("fs"); -var Rule = (function (_super) { - __extends(Rule, _super); - function Rule() { - return _super !== null && _super.apply(this, arguments) || this; - } - Rule.prototype.apply = function (sourceFile) { - return this.applyWithWalker(new TranslationRemindRuleWalker(sourceFile, this.getOptions())); - }; - return Rule; -}(Lint.Rules.AbstractRule)); -exports.Rule = Rule; -var TranslationRemindRuleWalker = (function (_super) { - __extends(TranslationRemindRuleWalker, _super); - function TranslationRemindRuleWalker(file, opts) { - return _super.call(this, file, opts) || this; - } - TranslationRemindRuleWalker.prototype.visitImportDeclaration = function (node) { - var declaration = node.moduleSpecifier.getText(); - if (declaration !== "'" + TranslationRemindRuleWalker.NLS_MODULE + "'") { - return; - } - this.visitImportLikeDeclaration(node); - }; - TranslationRemindRuleWalker.prototype.visitImportEqualsDeclaration = function (node) { - var reference = node.moduleReference.getText(); - if (reference !== "require('" + TranslationRemindRuleWalker.NLS_MODULE + "')") { - return; - } - this.visitImportLikeDeclaration(node); - }; - TranslationRemindRuleWalker.prototype.visitImportLikeDeclaration = function (node) { - var currentFile = node.getSourceFile().fileName; - var matchService = currentFile.match(/vs\/workbench\/services\/\w+/); - var matchPart = currentFile.match(/vs\/workbench\/parts\/\w+/); - if (!matchService && !matchPart) { - return; - } - var resource = matchService ? matchService[0] : matchPart[0]; - var resourceDefined = false; - var json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); - var workbenchResources = JSON.parse(json).workbench; - workbenchResources.forEach(function (existingResource) { - if (existingResource.name === resource) { - resourceDefined = true; - return; - } - }); - if (!resourceDefined) { - this.addFailureAtNode(node, "Please add '" + resource + "' to ./builds/lib/i18n.resources.json file to use translations here."); - } - }; - return TranslationRemindRuleWalker; -}(Lint.RuleWalker)); -TranslationRemindRuleWalker.NLS_MODULE = 'vs/nls'; +"use strict"; +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +var __extends = (this && this.__extends) || (function () { + var extendStatics = Object.setPrototypeOf || + ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || + function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + return function (d, b) { + extendStatics(d, b); + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); + }; +})(); +Object.defineProperty(exports, "__esModule", { value: true }); +var Lint = require("tslint"); +var fs = require("fs"); +var Rule = (function (_super) { + __extends(Rule, _super); + function Rule() { + return _super !== null && _super.apply(this, arguments) || this; + } + Rule.prototype.apply = function (sourceFile) { + return this.applyWithWalker(new TranslationRemindRuleWalker(sourceFile, this.getOptions())); + }; + return Rule; +}(Lint.Rules.AbstractRule)); +exports.Rule = Rule; +var TranslationRemindRuleWalker = (function (_super) { + __extends(TranslationRemindRuleWalker, _super); + function TranslationRemindRuleWalker(file, opts) { + return _super.call(this, file, opts) || this; + } + TranslationRemindRuleWalker.prototype.visitImportDeclaration = function (node) { + var declaration = node.moduleSpecifier.getText(); + if (declaration !== "'" + TranslationRemindRuleWalker.NLS_MODULE + "'") { + return; + } + this.visitImportLikeDeclaration(node); + }; + TranslationRemindRuleWalker.prototype.visitImportEqualsDeclaration = function (node) { + var reference = node.moduleReference.getText(); + if (reference !== "require('" + TranslationRemindRuleWalker.NLS_MODULE + "')") { + return; + } + this.visitImportLikeDeclaration(node); + }; + TranslationRemindRuleWalker.prototype.visitImportLikeDeclaration = function (node) { + var currentFile = node.getSourceFile().fileName; + var matchService = currentFile.match(/vs\/workbench\/services\/\w+/); + var matchPart = currentFile.match(/vs\/workbench\/parts\/\w+/); + if (!matchService && !matchPart) { + return; + } + var resource = matchService ? matchService[0] : matchPart[0]; + var resourceDefined = false; + var json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); + var workbenchResources = JSON.parse(json).workbench; + workbenchResources.forEach(function (existingResource) { + if (existingResource.name === resource) { + resourceDefined = true; + return; + } + }); + if (!resourceDefined) { + this.addFailureAtNode(node, "Please add '" + resource + "' to ./builds/lib/i18n.resources.json file to use translations here."); + } + }; + return TranslationRemindRuleWalker; +}(Lint.RuleWalker)); +TranslationRemindRuleWalker.NLS_MODULE = 'vs/nls'; -- GitLab From c5e3c8f1083e1372a4942419000bbda74fb4fe27 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Fri, 9 Jun 2017 18:22:17 +0200 Subject: [PATCH 0688/1347] Untitled: picked encoding is not restored after restart (fixes #28364) --- src/vs/platform/editor/common/editor.ts | 5 +++++ .../parts/editor/editor.contribution.ts | 7 +++++-- .../common/editor/untitledEditorInput.ts | 20 +++++++++---------- .../common/editor/untitledEditorModel.ts | 11 +++------- .../files/common/editors/fileEditorInput.ts | 9 ++------- .../services/editor/browser/editorService.ts | 2 +- .../untitled/common/untitledEditorService.ts | 13 ++++++------ 7 files changed, 32 insertions(+), 35 deletions(-) diff --git a/src/vs/platform/editor/common/editor.ts b/src/vs/platform/editor/common/editor.ts index 81dc32ec8bc..9beffac6e9c 100644 --- a/src/vs/platform/editor/common/editor.ts +++ b/src/vs/platform/editor/common/editor.ts @@ -90,6 +90,11 @@ export interface IUntitledResourceInput extends IBaseResourceInput { * Optional contents of the untitled resource. */ contents?: string; + + /** + * Optional encoding of the untitled resource. + */ + encoding?: string; } export interface IResourceDiffInput extends IBaseResourceInput { diff --git a/src/vs/workbench/browser/parts/editor/editor.contribution.ts b/src/vs/workbench/browser/parts/editor/editor.contribution.ts index 8c6275f0b55..cd4bc5a15ea 100644 --- a/src/vs/workbench/browser/parts/editor/editor.contribution.ts +++ b/src/vs/workbench/browser/parts/editor/editor.contribution.ts @@ -93,6 +93,7 @@ interface ISerializedUntitledEditorInput { resource: string; resourceJSON: any; modeId: string; + encoding: string; } // Register Editor Input Factory @@ -118,7 +119,8 @@ class UntitledEditorInputFactory implements IEditorInputFactory { const serialized: ISerializedUntitledEditorInput = { resource: resource.toString(), // Keep for backwards compatibility resourceJSON: resource.toJSON(), - modeId: untitledEditorInput.getModeId() + modeId: untitledEditorInput.getModeId(), + encoding: untitledEditorInput.getEncoding() }; return JSON.stringify(serialized); @@ -130,8 +132,9 @@ class UntitledEditorInputFactory implements IEditorInputFactory { const resource = !!deserialized.resourceJSON ? URI.revive(deserialized.resourceJSON) : URI.parse(deserialized.resource); const filePath = resource.scheme === 'file' ? resource.fsPath : void 0; const language = deserialized.modeId; + const encoding = deserialized.encoding; - return accessor.get(IWorkbenchEditorService).createInput({ resource, filePath, language }) as UntitledEditorInput; + return accessor.get(IWorkbenchEditorService).createInput({ resource, filePath, language, encoding }) as UntitledEditorInput; }); } } diff --git a/src/vs/workbench/common/editor/untitledEditorInput.ts b/src/vs/workbench/common/editor/untitledEditorInput.ts index 0d27f285512..081b9bd7df4 100644 --- a/src/vs/workbench/common/editor/untitledEditorInput.ts +++ b/src/vs/workbench/common/editor/untitledEditorInput.ts @@ -27,10 +27,7 @@ export class UntitledEditorInput extends EditorInput implements IEncodingSupport public static ID: string = 'workbench.editors.untitledEditorInput'; - private resource: URI; private _hasAssociatedFilePath: boolean; - private initialValue: string; - private modeId: string; private cachedModel: UntitledEditorModel; private modelResolve: TPromise; @@ -40,10 +37,11 @@ export class UntitledEditorInput extends EditorInput implements IEncodingSupport private toUnbind: IDisposable[]; constructor( - resource: URI, + private resource: URI, hasAssociatedFilePath: boolean, - modeId: string, - initialValue: string, + private modeId: string, + private initialValue: string, + private preferredEncoding: string, @IInstantiationService private instantiationService: IInstantiationService, @IWorkspaceContextService private contextService: IWorkspaceContextService, @ITextFileService private textFileService: ITextFileService, @@ -51,11 +49,9 @@ export class UntitledEditorInput extends EditorInput implements IEncodingSupport ) { super(); - this.resource = resource; - this.initialValue = initialValue; this._hasAssociatedFilePath = hasAssociatedFilePath; - this.modeId = modeId; this.toUnbind = []; + this._onDidModelChangeContent = new Emitter(); this._onDidModelChangeEncoding = new Emitter(); } @@ -146,10 +142,12 @@ export class UntitledEditorInput extends EditorInput implements IEncodingSupport return this.cachedModel.getEncoding(); } - return null; + return this.preferredEncoding; } public setEncoding(encoding: string, mode: EncodingMode /* ignored, we only have Encode */): void { + this.preferredEncoding = encoding; + if (this.cachedModel) { this.cachedModel.setEncoding(encoding); } @@ -170,7 +168,7 @@ export class UntitledEditorInput extends EditorInput implements IEncodingSupport } private createModel(): UntitledEditorModel { - const model = this.instantiationService.createInstance(UntitledEditorModel, this.modeId, this.resource, this.hasAssociatedFilePath, this.initialValue); + const model = this.instantiationService.createInstance(UntitledEditorModel, this.modeId, this.resource, this.hasAssociatedFilePath, this.initialValue, this.preferredEncoding); // re-emit some events from the model this.toUnbind.push(model.onDidChangeContent(() => this._onDidModelChangeContent.fire())); diff --git a/src/vs/workbench/common/editor/untitledEditorModel.ts b/src/vs/workbench/common/editor/untitledEditorModel.ts index bd0bb5300b1..65e8c973201 100644 --- a/src/vs/workbench/common/editor/untitledEditorModel.ts +++ b/src/vs/workbench/common/editor/untitledEditorModel.ts @@ -38,16 +38,13 @@ export class UntitledEditorModel extends BaseTextEditorModel implements IEncodin private contentChangeEventScheduler: RunOnceScheduler; private configuredEncoding: string; - private preferredEncoding: string; - - private hasAssociatedFilePath: boolean; - private initialValue: string; constructor( private modeId: string, private resource: URI, - hasAssociatedFilePath: boolean, - initialValue: string, + private hasAssociatedFilePath: boolean, + private initialValue: string, + private preferredEncoding: string, @IModeService modeService: IModeService, @IModelService modelService: IModelService, @IBackupFileService private backupFileService: IBackupFileService, @@ -56,8 +53,6 @@ export class UntitledEditorModel extends BaseTextEditorModel implements IEncodin ) { super(modelService, modeService); - this.hasAssociatedFilePath = hasAssociatedFilePath; - this.initialValue = initialValue; this.dirty = false; this.versionId = 0; diff --git a/src/vs/workbench/parts/files/common/editors/fileEditorInput.ts b/src/vs/workbench/parts/files/common/editors/fileEditorInput.ts index 2409a85a811..d2b5a8b9235 100644 --- a/src/vs/workbench/parts/files/common/editors/fileEditorInput.ts +++ b/src/vs/workbench/parts/files/common/editors/fileEditorInput.ts @@ -27,8 +27,6 @@ import { ITextModelResolverService } from 'vs/editor/common/services/resolverSer * A file editor input is the input type for the file editor of file system resources. */ export class FileEditorInput extends EditorInput implements IFileEditorInput { - private resource: URI; - private preferredEncoding: string; private forceOpenAsBinary: boolean; private textModelReference: TPromise>; @@ -46,8 +44,8 @@ export class FileEditorInput extends EditorInput implements IFileEditorInput { * An editor input who's contents are retrieved from file services. */ constructor( - resource: URI, - preferredEncoding: string, + private resource: URI, + private preferredEncoding: string, @IInstantiationService private instantiationService: IInstantiationService, @IWorkspaceContextService private contextService: IWorkspaceContextService, @ITextFileService private textFileService: ITextFileService, @@ -58,9 +56,6 @@ export class FileEditorInput extends EditorInput implements IFileEditorInput { this.toUnbind = []; - this.resource = resource; - this.preferredEncoding = preferredEncoding; - this.registerListeners(); } diff --git a/src/vs/workbench/services/editor/browser/editorService.ts b/src/vs/workbench/services/editor/browser/editorService.ts index afd412d0127..e8b52c75a1e 100644 --- a/src/vs/workbench/services/editor/browser/editorService.ts +++ b/src/vs/workbench/services/editor/browser/editorService.ts @@ -233,7 +233,7 @@ export class WorkbenchEditorService implements IWorkbenchEditorService { // Untitled file support const untitledInput = input; if (!untitledInput.resource || typeof untitledInput.filePath === 'string' || (untitledInput.resource instanceof URI && untitledInput.resource.scheme === UNTITLED_SCHEMA)) { - return this.untitledEditorService.createOrGet(untitledInput.filePath ? URI.file(untitledInput.filePath) : untitledInput.resource, untitledInput.language, untitledInput.contents); + return this.untitledEditorService.createOrGet(untitledInput.filePath ? URI.file(untitledInput.filePath) : untitledInput.resource, untitledInput.language, untitledInput.contents, untitledInput.encoding); } const resourceInput = input; diff --git a/src/vs/workbench/services/untitled/common/untitledEditorService.ts b/src/vs/workbench/services/untitled/common/untitledEditorService.ts index 264aa9275d4..89d3f6f4305 100644 --- a/src/vs/workbench/services/untitled/common/untitledEditorService.ts +++ b/src/vs/workbench/services/untitled/common/untitledEditorService.ts @@ -24,6 +24,7 @@ export interface IModelLoadOrCreateOptions { resource?: URI; modeId?: string; initialValue?: string; + encoding?: string; } export interface IUntitledEditorService { @@ -77,7 +78,7 @@ export interface IUntitledEditorService { * It is valid to pass in a file resource. In that case the path will be used as identifier. * The use case is to be able to create a new file with a specific path with VSCode. */ - createOrGet(resource?: URI, modeId?: string, initialValue?: string): UntitledEditorInput; + createOrGet(resource?: URI, modeId?: string, initialValue?: string, encoding?: string): UntitledEditorInput; /** * Creates a new untitled model with the optional resource URI or returns an existing one @@ -194,10 +195,10 @@ export class UntitledEditorService implements IUntitledEditorService { } public loadOrCreate(options: IModelLoadOrCreateOptions = Object.create(null)): TPromise { - return this.createOrGet(options.resource, options.modeId, options.initialValue).resolve(); + return this.createOrGet(options.resource, options.modeId, options.initialValue, options.encoding).resolve(); } - public createOrGet(resource?: URI, modeId?: string, initialValue?: string): UntitledEditorInput { + public createOrGet(resource?: URI, modeId?: string, initialValue?: string, encoding?: string): UntitledEditorInput { // Massage resource if it comes with a file:// scheme let hasAssociatedFilePath = false; @@ -216,10 +217,10 @@ export class UntitledEditorService implements IUntitledEditorService { } // Create new otherwise - return this.doCreate(resource, hasAssociatedFilePath, modeId, initialValue); + return this.doCreate(resource, hasAssociatedFilePath, modeId, initialValue, encoding); } - private doCreate(resource?: URI, hasAssociatedFilePath?: boolean, modeId?: string, initialValue?: string): UntitledEditorInput { + private doCreate(resource?: URI, hasAssociatedFilePath?: boolean, modeId?: string, initialValue?: string, encoding?: string): UntitledEditorInput { if (!resource) { // Create new taking a resource URI that is not already taken @@ -238,7 +239,7 @@ export class UntitledEditorService implements IUntitledEditorService { } } - const input = this.instantiationService.createInstance(UntitledEditorInput, resource, hasAssociatedFilePath, modeId, initialValue); + const input = this.instantiationService.createInstance(UntitledEditorInput, resource, hasAssociatedFilePath, modeId, initialValue, encoding); const contentListener = input.onDidModelChangeContent(() => { this._onDidChangeContent.fire(resource); -- GitLab From 7925fce1312a653b1c4389cd44a31436c0330972 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Fri, 9 Jun 2017 11:38:39 -0700 Subject: [PATCH 0689/1347] Fixes #28293 --- src/vs/base/common/glob.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/base/common/glob.ts b/src/vs/base/common/glob.ts index 8fcd060bf94..fd6a973da8d 100644 --- a/src/vs/base/common/glob.ts +++ b/src/vs/base/common/glob.ts @@ -437,7 +437,7 @@ export function parseToAsync(expression: IExpression, options?: IGlobOptions): P const parsedExpression = parse(expression, options); return (path: string, basename?: string, siblingsFn?: () => TPromise): TPromise => { const result = parsedExpression(path, basename, siblingsFn); - return typeof result === 'string' ? TPromise.as(result) : result; + return result instanceof TPromise ? result : TPromise.as(result); }; } -- GitLab From 1777366530dd13dcbd4081cb690a21a4d329e903 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Fri, 9 Jun 2017 12:16:39 -0700 Subject: [PATCH 0690/1347] Uplevel xterm.js Fixes #26038 --- npm-shrinkwrap.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/npm-shrinkwrap.json b/npm-shrinkwrap.json index 3e962373c7d..2306ffaedb5 100644 --- a/npm-shrinkwrap.json +++ b/npm-shrinkwrap.json @@ -442,7 +442,7 @@ "xterm": { "version": "2.6.0", "from": "Tyriar/xterm.js#vscode-release/1.13", - "resolved": "git+https://github.com/Tyriar/xterm.js.git#32c9eac8ee5a958093d126a06c1c06a7cd6052bf" + "resolved": "git+https://github.com/Tyriar/xterm.js.git#55e0399c1b3ccf06c5d677bf7945b9b2d598fc16" }, "yauzl": { "version": "2.3.1", -- GitLab From 43abcc20b3b47e1153e116ee98636a6ec9c3a68d Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Fri, 9 Jun 2017 22:26:56 +0200 Subject: [PATCH 0691/1347] Fixes #28379: Run Task should be sorted using MRU list --- src/vs/base/common/linkedMap.ts | 306 ++++++++++++++++++ .../parts/tasks/browser/quickOpen.ts | 56 ++-- .../parts/tasks/common/taskService.ts | 2 + .../electron-browser/task.contribution.ts | 41 ++- 4 files changed, 376 insertions(+), 29 deletions(-) create mode 100644 src/vs/base/common/linkedMap.ts diff --git a/src/vs/base/common/linkedMap.ts b/src/vs/base/common/linkedMap.ts new file mode 100644 index 00000000000..65eaa0e6c85 --- /dev/null +++ b/src/vs/base/common/linkedMap.ts @@ -0,0 +1,306 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +interface Item { + previous: Item | undefined; + next: Item | undefined; + key: K; + value: V; +} + +export namespace Touch { + export const None: 0 = 0; + export const First: 1 = 1; + export const Last: 2 = 2; +} + +export type Touch = 0 | 1 | 2; + +export class LinkedMap { + + private _map: Map>; + private _head: Item | undefined; + private _tail: Item | undefined; + private _size: number; + + constructor() { + this._map = new Map>(); + this._head = undefined; + this._tail = undefined; + this._size = 0; + } + + public clear(): void { + this._map.clear(); + this._head = undefined; + this._tail = undefined; + this._size = 0; + } + + public isEmpty(): boolean { + return !this._head && !this._tail; + } + + public get size(): number { + return this._size; + } + + public has(key: K): boolean { + return this._map.has(key); + } + + public get(key: K): V | undefined { + const item = this._map.get(key); + if (!item) { + return undefined; + } + return item.value; + } + + public set(key: K, value: V, touch: Touch = Touch.None): void { + let item = this._map.get(key); + if (item) { + item.value = value; + if (touch !== Touch.None) { + this.touch(item, touch); + } + } else { + item = { key, value, next: undefined, previous: undefined }; + switch (touch) { + case Touch.None: + this.addItemLast(item); + break; + case Touch.First: + this.addItemFirst(item); + break; + case Touch.Last: + this.addItemLast(item); + break; + default: + this.addItemLast(item); + break; + } + this._map.set(key, item); + this._size++; + } + } + + public delete(key: K): boolean { + const item = this._map.get(key); + if (!item) { + return false; + } + this._map.delete(key); + this.removeItem(item); + this._size--; + return true; + } + + public shift(): V | undefined { + if (!this._head && !this._tail) { + return undefined; + } + if (!this._head || !this._tail) { + throw new Error('Invalid list'); + } + const item = this._head; + this._map.delete(item.key); + this.removeItem(item); + this._size--; + return item.value; + } + + public forEach(callbackfn: (value: V, key: K, map: LinkedMap) => void, thisArg?: any): void { + let current = this._head; + while (current) { + if (thisArg) { + callbackfn.bind(thisArg)(current.value, current.key, this); + } else { + callbackfn(current.value, current.key, this); + } + current = current.next; + } + } + + public forEachReverse(callbackfn: (value: V, key: K, map: LinkedMap) => void, thisArg?: any): void { + let current = this._tail; + while (current) { + if (thisArg) { + callbackfn.bind(thisArg)(current.value, current.key, this); + } else { + callbackfn(current.value, current.key, this); + } + current = current.previous; + } + } + + public values(): V[] { + let result: V[] = []; + let current = this._head; + while (current) { + result.push(current.value); + current = current.next; + } + return result; + } + + public keys(): K[] { + let result: K[] = []; + let current = this._head; + while (current) { + result.push(current.key); + current = current.next; + } + return result; + } + + /* VS Code / Monaco editor runs on es5 which has no Symbol.iterator + public keys(): IterableIterator { + let current = this._head; + let iterator: IterableIterator = { + [Symbol.iterator]() { + return iterator; + }, + next():IteratorResult { + if (current) { + let result = { value: current.key, done: false }; + current = current.next; + return result; + } else { + return { value: undefined, done: true }; + } + } + }; + return iterator; + } + + public values(): IterableIterator { + let current = this._head; + let iterator: IterableIterator = { + [Symbol.iterator]() { + return iterator; + }, + next():IteratorResult { + if (current) { + let result = { value: current.value, done: false }; + current = current.next; + return result; + } else { + return { value: undefined, done: true }; + } + } + }; + return iterator; + } + */ + + private addItemFirst(item: Item): void { + // First time Insert + if (!this._head && !this._tail) { + this._tail = item; + } else if (!this._head) { + throw new Error('Invalid list'); + } else { + item.next = this._head; + this._head.previous = item; + } + this._head = item; + } + + private addItemLast(item: Item): void { + // First time Insert + if (!this._head && !this._tail) { + this._head = item; + } else if (!this._tail) { + throw new Error('Invalid list'); + } else { + item.previous = this._tail; + this._tail.next = item; + } + this._tail = item; + } + + private removeItem(item: Item): void { + if (item === this._head && item === this._tail) { + this._head = undefined; + this._tail = undefined; + } + else if (item === this._head) { + this._head = item.next; + } + else if (item === this._tail) { + this._tail = item.previous; + } + else { + const next = item.next; + const previous = item.previous; + if (!next || !previous) { + throw new Error('Invalid list'); + } + next.previous = previous; + previous.next = next; + } + } + + private touch(item: Item, touch: Touch): void { + if (!this._head || !this._tail) { + throw new Error('Invalid list'); + } + if ((touch !== Touch.First && touch !== Touch.Last)) { + return; + } + + if (touch === Touch.First) { + if (item === this._head) { + return; + } + + const next = item.next; + const previous = item.previous; + + // Unlink the item + if (item === this._tail) { + // previous must be defined since item was not head but is tail + // So there are more than on item in the map + previous!.next = undefined; + this._tail = previous; + } + else { + // Both next and previous are not undefined since item was neither head nor tail. + next!.previous = previous; + previous!.next = next; + } + + // Insert the node at head + item.previous = undefined; + item.next = this._head; + this._head.previous = item; + this._head = item; + } else if (touch === Touch.Last) { + if (item === this._tail) { + return; + } + + const next = item.next; + const previous = item.previous; + + // Unlink the item. + if (item === this._head) { + // next must be defined since item was not tail but is head + // So there are more than on item in the map + next!.previous = undefined; + this._head = next; + } else { + // Both next and previous are not undefined since item was neither head nor tail. + next!.previous = previous; + previous!.next = next; + } + item.next = undefined; + item.previous = this._tail; + this._tail.next = item; + this._tail = item; + } + } +} \ No newline at end of file diff --git a/src/vs/workbench/parts/tasks/browser/quickOpen.ts b/src/vs/workbench/parts/tasks/browser/quickOpen.ts index c8661e0d52c..9368b61de9a 100644 --- a/src/vs/workbench/parts/tasks/browser/quickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/quickOpen.ts @@ -8,6 +8,8 @@ import nls = require('vs/nls'); import Filters = require('vs/base/common/filters'); import { TPromise } from 'vs/base/common/winjs.base'; import { Action, IAction } from 'vs/base/common/actions'; +import { IStringDictionary } from 'vs/base/common/collections'; + import Quickopen = require('vs/workbench/browser/quickopen'); import QuickOpen = require('vs/base/parts/quickopen/common/quickOpen'); import Model = require('vs/base/parts/quickopen/browser/quickOpenModel'); @@ -49,7 +51,7 @@ export abstract class QuickOpenHandler extends Quickopen.QuickOpenHandler { constructor( protected quickOpenService: IQuickOpenService, - protected taskService: ITaskService, + protected taskService: ITaskService ) { super(); @@ -71,39 +73,39 @@ export abstract class QuickOpenHandler extends Quickopen.QuickOpenHandler { if (tasks.length === 0) { return new Model.QuickOpenModel(entries); } - tasks = tasks.sort((a, b) => { - let aKind = a._source.kind; - let bKind = b._source.kind; - if (aKind === bKind) { - if (aKind === TaskSourceKind.Extension) { - let compare = a._source.label.localeCompare(b._source.label); - if (compare !== 0) { - return compare; - } - } - return a._label.localeCompare(b._label); - } - if (aKind === TaskSourceKind.Workspace) { - return -1; - } else { - return +1; + let recentlyUsedTasks = this.taskService.getRecentlyUsedTasks(); + let recent: Task[] = []; + let others: Task[] = []; + let taskMap: IStringDictionary = Object.create(null); + tasks.forEach(task => taskMap[task.identifier] = task); + recentlyUsedTasks.keys().forEach(key => { + let task = taskMap[key]; + if (task) { + recent.push(task); } }); - let firstWorkspace: boolean = true; - let firstExtension: boolean = true; - let hadWorkspace: boolean = false; for (let task of tasks) { + if (!recentlyUsedTasks.has(task.identifier)) { + others.push(task); + } + } + others = others.sort((a, b) => a._source.label.localeCompare(b._source.label)); + let sortedTasks = recent.concat(others); + let recentlyUsed: boolean = recentlyUsedTasks.has(tasks[0].identifier); + let otherTasks: boolean = !recentlyUsedTasks.has(tasks[tasks.length - 1].identifier); + let hasRecentlyUsed: boolean = false; + for (let task of sortedTasks) { let highlights = Filters.matchesContiguousSubString(input, task._label); if (!highlights) { continue; } - if (task._source.kind === TaskSourceKind.Workspace && firstWorkspace) { - firstWorkspace = false; - hadWorkspace = true; - entries.push(new TaskGroupEntry(this.createEntry(this.taskService, task, highlights), nls.localize('configured', 'Configured Tasks'), false)); - } else if (task._source.kind === TaskSourceKind.Extension && firstExtension) { - firstExtension = false; - entries.push(new TaskGroupEntry(this.createEntry(this.taskService, task, highlights), nls.localize('detected', 'Detected Tasks'), hadWorkspace)); + if (recentlyUsed) { + recentlyUsed = false; + hasRecentlyUsed = true; + entries.push(new TaskGroupEntry(this.createEntry(this.taskService, task, highlights), nls.localize('recentlyUsed', 'recently used'), false)); + } else if (!recentlyUsedTasks.has(task.identifier) && otherTasks) { + otherTasks = false; + entries.push(new TaskGroupEntry(this.createEntry(this.taskService, task, highlights), nls.localize('other tasks', 'other tasks'), hasRecentlyUsed)); } else { entries.push(this.createEntry(this.taskService, task, highlights)); } diff --git a/src/vs/workbench/parts/tasks/common/taskService.ts b/src/vs/workbench/parts/tasks/common/taskService.ts index b410569a283..89ab0e6d57c 100644 --- a/src/vs/workbench/parts/tasks/common/taskService.ts +++ b/src/vs/workbench/parts/tasks/common/taskService.ts @@ -8,6 +8,7 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { Action } from 'vs/base/common/actions'; import { IEventEmitter } from 'vs/base/common/eventEmitter'; import { TerminateResponse } from 'vs/base/common/processes'; +import { LinkedMap } from 'vs/base/common/linkedMap'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; import { Task, TaskSet } from 'vs/workbench/parts/tasks/common/tasks'; import { ITaskSummary, TaskEvent, TaskType } from 'vs/workbench/parts/tasks/common/taskSystem'; @@ -43,6 +44,7 @@ export interface ITaskService extends IEventEmitter { terminateAll(): TPromise; tasks(): TPromise; getTasksForGroup(group: string): TPromise; + getRecentlyUsedTasks(): LinkedMap; customize(task: Task, openConfig?: boolean): TPromise; diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index ee12526316b..10b8f78aba5 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -29,6 +29,7 @@ import { TerminateResponse, TerminateResponseCode } from 'vs/base/common/process import * as strings from 'vs/base/common/strings'; import { ValidationStatus, ValidationState } from 'vs/base/common/parsers'; import * as UUID from 'vs/base/common/uuid'; +import { LinkedMap, Touch } from 'vs/base/common/linkedMap'; import { Registry } from 'vs/platform/platform'; import { ILifecycleService } from 'vs/platform/lifecycle/common/lifecycle'; @@ -45,7 +46,7 @@ import { CommandsRegistry } from 'vs/platform/commands/common/commands'; import { KeybindingsRegistry } from 'vs/platform/keybinding/common/keybindingsRegistry'; import { ServicesAccessor } from 'vs/platform/instantiation/common/instantiation'; import { ProblemMatcherRegistry } from 'vs/platform/markers/common/problemMatcher'; - +import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage'; import { IModeService } from 'vs/editor/common/services/modeService'; import { IModelService } from 'vs/editor/common/services/modelService'; @@ -516,6 +517,7 @@ interface WorkspaceConfigurationResult { class TaskService extends EventEmitter implements ITaskService { // private static autoDetectTelemetryName: string = 'taskServer.autoDetect'; + private static RecentlyUsedTasks_Key = 'workbench.tasks.recentlyUsedTasks'; public _serviceBrand: any; public static SERVICE_ID: string = 'taskService'; @@ -544,6 +546,7 @@ class TaskService extends EventEmitter implements ITaskService { private _taskSystem: ITaskSystem; private _taskSystemListeners: IDisposable[]; + private _recentlyUsedTasks: LinkedMap; private _outputChannel: IOutputChannel; @@ -559,7 +562,8 @@ class TaskService extends EventEmitter implements ITaskService { @IEnvironmentService private environmentService: IEnvironmentService, @IConfigurationResolverService private configurationResolverService: IConfigurationResolverService, @ITerminalService private terminalService: ITerminalService, - @IWorkbenchEditorService private workbenchEditorService: IWorkbenchEditorService + @IWorkbenchEditorService private workbenchEditorService: IWorkbenchEditorService, + @IStorageService private storageService: IStorageService ) { super(); @@ -689,6 +693,37 @@ class TaskService extends EventEmitter implements ITaskService { return TPromise.as(this._taskSystem.getActiveTasks()); } + public getRecentlyUsedTasks(): LinkedMap { + if (this._recentlyUsedTasks) { + return this._recentlyUsedTasks; + } + this._recentlyUsedTasks = new LinkedMap(); + let storageValue = this.storageService.get(TaskService.RecentlyUsedTasks_Key, StorageScope.WORKSPACE); + if (storageValue) { + try { + let values: string[] = JSON.parse(storageValue); + if (Array.isArray(values)) { + for (let value of values) { + this._recentlyUsedTasks.set(value, value); + } + } + } catch (error) { + // Ignore. We use the empty result + } + } + return this._recentlyUsedTasks; + } + + private saveRecentlyUsedTasks(): void { + if (!this._recentlyUsedTasks) { + return; + } + let values = this._recentlyUsedTasks.values(); + if (values.length > 30) { + values = values.slice(0, 30); + } + this.storageService.store(TaskService.RecentlyUsedTasks_Key, JSON.stringify(values), StorageScope.WORKSPACE); + } public build(): TPromise { return this.getTaskSets().then((values) => { @@ -896,6 +931,7 @@ class TaskService extends EventEmitter implements ITaskService { throw new TaskError(Severity.Warning, nls.localize('TaskSystem.active', 'There is already a task running. Terminate it first before executing another task.'), TaskErrors.RunningTask); } } + this.getRecentlyUsedTasks().set(task.identifier, task.identifier, Touch.First); return executeResult.promise; }); }); @@ -1248,6 +1284,7 @@ class TaskService extends EventEmitter implements ITaskService { } public beforeShutdown(): boolean | TPromise { + this.saveRecentlyUsedTasks(); if (this._taskSystem && this._taskSystem.isActiveSync()) { if (this._taskSystem.canAutoTerminate() || this.messageService.confirm({ message: nls.localize('TaskSystem.runningTask', 'There is a task running. Do you want to terminate it?'), -- GitLab From dd7277720b217a46eb6b9e21e3b9bbfd48f1bb7e Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Fri, 9 Jun 2017 14:05:57 -0700 Subject: [PATCH 0692/1347] Uplevel xterm.js --- npm-shrinkwrap.json | 4 ++-- package.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/npm-shrinkwrap.json b/npm-shrinkwrap.json index 58d2fcc6cde..01a089f8264 100644 --- a/npm-shrinkwrap.json +++ b/npm-shrinkwrap.json @@ -441,8 +441,8 @@ }, "xterm": { "version": "2.7.0", - "from": "Tyriar/xterm.js#vscode-release/1.14-beta", - "resolved": "git+https://github.com/Tyriar/xterm.js.git#e6130919622e238221ee9c8806cca8f084cfec2c" + "from": "Tyriar/xterm.js#vscode-release/1.14", + "resolved": "git+https://github.com/Tyriar/xterm.js.git#1d7007669dec1f60e5878aa102a36473d8cbd97f" }, "yauzl": { "version": "2.3.1", diff --git a/package.json b/package.json index 588c630f9af..09d83d51cb2 100644 --- a/package.json +++ b/package.json @@ -42,7 +42,7 @@ "vscode-ripgrep": "0.0.12", "vscode-textmate": "^3.1.5", "winreg": "1.2.0", - "xterm": "Tyriar/xterm.js#vscode-release/1.14-beta", + "xterm": "Tyriar/xterm.js#vscode-release/1.14", "yauzl": "2.3.1" }, "devDependencies": { -- GitLab From 32566fd1f1959de84a98be06fcfcd397ad729ead Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Fri, 9 Jun 2017 14:54:31 -0700 Subject: [PATCH 0693/1347] Add scss and pug to markdown fenced codeblock syntax highlighting Fixes #28382 --- extensions/markdown/syntaxes/gulpfile.js | 4 +- .../markdown/syntaxes/markdown.tmLanguage | 57 ++++++++++++++++++- .../syntaxes/markdown.tmLanguage.base | 4 +- 3 files changed, 61 insertions(+), 4 deletions(-) diff --git a/extensions/markdown/syntaxes/gulpfile.js b/extensions/markdown/syntaxes/gulpfile.js index a01ff06499c..15545e82502 100644 --- a/extensions/markdown/syntaxes/gulpfile.js +++ b/extensions/markdown/syntaxes/gulpfile.js @@ -32,13 +32,15 @@ const languages = [ { name: 'git_rebase', identifiers: ['git-rebase-todo'], source: 'text.git-rebase' }, { name: 'go', identifiers: ['go', 'golang'], source: 'source.go' }, { name: 'groovy', identifiers: ['groovy', 'gvy'], source: 'source.groovy' }, - { name: 'jade', identifiers: ['jade'], source: 'text.jade' }, + { name: 'jade', identifiers: ['jade', 'pug'], source: 'text.jade' }, { name: 'js', identifiers: ['js', 'jsx', 'javascript', 'es6', 'mjs'], source: 'source.js' }, { name: 'js_regexp', identifiers: ['regexp'], source: 'source.js.regexp' }, { name: 'json', identifiers: ['json', 'sublime-settings', 'sublime-menu', 'sublime-keymap', 'sublime-mousemap', 'sublime-theme', 'sublime-build', 'sublime-project', 'sublime-completions'], source: 'source.json' }, { name: 'less', identifiers: ['less'], source: 'source.css.less' }, { name: 'objc', identifiers: ['objectivec', 'objective-c', 'mm', 'objc', 'obj-c', 'm', 'h'], source: 'source.objc' }, + { name: 'scss', identifiers: ['scss'], source: 'source.css.scss' }, + { name: 'perl6', identifiers: ['perl6', 'p6', 'pl6', 'pm6', 'nqp'], source: 'source.perl.6' }, { name: 'powershell', identifiers: ['powershell', 'ps1', 'psm1', 'psd1'], source: 'source.powershell' }, { name: 'python', identifiers: ['python', 'py', 'py3', 'rpy', 'pyw', 'cpy', 'SConstruct', 'Sconstruct', 'sconstruct', 'SConscript', 'gyp', 'gypi'], source: 'source.python' }, diff --git a/extensions/markdown/syntaxes/markdown.tmLanguage b/extensions/markdown/syntaxes/markdown.tmLanguage index 38d1292f7e4..d9ac2a0ba6c 100644 --- a/extensions/markdown/syntaxes/markdown.tmLanguage +++ b/extensions/markdown/syntaxes/markdown.tmLanguage @@ -174,6 +174,10 @@ include #fenced_code_block_objc + + include + #fenced_code_block_scss + include #fenced_code_block_perl6 @@ -1914,7 +1918,7 @@ fenced_code_block_jade begin - (^|\G)(\s*)([`~]{3,})\s*((jade)(\s+[^`~]*)?$) + (^|\G)(\s*)([`~]{3,})\s*((jade|pug)(\s+[^`~]*)?$) name markup.fenced_code.block.markdown end @@ -2217,6 +2221,57 @@ + fenced_code_block_scss + + begin + (^|\G)(\s*)([`~]{3,})\s*((scss)(\s+[^`~]*)?$) + name + markup.fenced_code.block.markdown + end + (^|\G)(\2|\s{0,3})(\3)\s*$ + beginCaptures + + 3 + + name + punctuation.definition.markdown + + 5 + + name + fenced_code.block.language + + 6 + + name + fenced_code.block.language.attributes + + + endCaptures + + 3 + + name + punctuation.definition.markdown + + + patterns + + + begin + (^|\G)(\s*)(.*) + while + (^|\G)(?!\s*([`~]{3,})\s*$) + patterns + + + include + source.css.scss + + + + + fenced_code_block_perl6 begin diff --git a/extensions/markdown/syntaxes/markdown.tmLanguage.base b/extensions/markdown/syntaxes/markdown.tmLanguage.base index 6a8868a260b..7c5a5558a18 100644 --- a/extensions/markdown/syntaxes/markdown.tmLanguage.base +++ b/extensions/markdown/syntaxes/markdown.tmLanguage.base @@ -416,7 +416,7 @@ name markup.fenced_code.block.markdown begin - (^|\G)(\s*)([`~]{3,})\s*(?=[^`~]*)?$ + (^|\G)(\s*)([`~]{3,})\s*(?=([^`~]*)?$) end (^|\G)(\2|\s{0,3})(\3)\s*$ beginCaptures @@ -1118,7 +1118,7 @@ match - (\[)((?<square>[^\[\]\\]|\\.|\[\g<square>*+\])*+)(\])[ ]?(\[)([^\]]*+)(\]) + (\[)((?<square>[^\[\]\\]|\\.|\[\g<square>*+\])*+)(\])(\[)([^\]]*+)(\]) name meta.link.reference.markdown -- GitLab From 3b8a3ca25e5ed631c6a786792ac85cc817b09891 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Fri, 9 Jun 2017 15:17:14 -0700 Subject: [PATCH 0694/1347] Enable contextisolation in webviews --- src/vs/workbench/parts/html/browser/webview.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/html/browser/webview.ts b/src/vs/workbench/parts/html/browser/webview.ts index b8d6922a844..38005084ab2 100644 --- a/src/vs/workbench/parts/html/browser/webview.ts +++ b/src/vs/workbench/parts/html/browser/webview.ts @@ -21,7 +21,6 @@ declare interface WebviewElement extends HTMLElement { autoSize: 'on'; preload: string; contextIsolation: boolean; - send(channel: string, ...args: any[]); openDevTools(): any; } @@ -70,6 +69,7 @@ export default class Webview { this._webview.setAttribute('disableblinkfeatures', 'Auxclick'); this._webview.setAttribute('disableguestresize', ''); + this._webview.setAttribute('webpreferences', 'contextIsolation=yes'); this._webview.preload = require.toUrl('./webview-pre.js'); this._webview.src = require.toUrl('./webview.html'); -- GitLab From a50f22517ca4f8b00267d868495c89d1dac7d1d8 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Fri, 9 Jun 2017 15:23:35 -0700 Subject: [PATCH 0695/1347] Check for null/undefined before assigning kind --- extensions/emmet/src/emmetCompletionProvider.ts | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/extensions/emmet/src/emmetCompletionProvider.ts b/extensions/emmet/src/emmetCompletionProvider.ts index acab02d57a5..84d762988d2 100644 --- a/extensions/emmet/src/emmetCompletionProvider.ts +++ b/extensions/emmet/src/emmetCompletionProvider.ts @@ -62,9 +62,12 @@ export class EmmetCompletionItemProviderHtml extends EmmetCompletionItemProvider protected getExpandedAbbreviation(document: vscode.TextDocument, position: vscode.Position): vscode.CompletionItem { let completionItem = super.getExpandedAbbreviation(document, position); - // In non stylesheet like syntax, this extension returns expanded abbr plus posssible abbr completions - // To differentiate between the 2, the former is given CompletionItemKind.Value so that it gets a different icon - completionItem.kind = vscode.CompletionItemKind.Value; + if (completionItem) { + // In non stylesheet like syntax, this extension returns expanded abbr plus posssible abbr completions + // To differentiate between the 2, the former is given CompletionItemKind.Value so that it gets a different icon + completionItem.kind = vscode.CompletionItemKind.Value; + } + return completionItem; } -- GitLab From 8702fba6f12b76dab8c1f661952c2ffcefd9abf3 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Fri, 9 Jun 2017 15:57:55 -0700 Subject: [PATCH 0696/1347] Apply terminal.foreground to the terminal cursor too Fixes #28389 --- .../terminal/electron-browser/media/xterm.css | 48 +------------------ .../electron-browser/terminalPanel.ts | 9 +++- 2 files changed, 10 insertions(+), 47 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/xterm.css b/src/vs/workbench/parts/terminal/electron-browser/media/xterm.css index 4ee863dbecb..4b6de38e739 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/media/xterm.css +++ b/src/vs/workbench/parts/terminal/electron-browser/media/xterm.css @@ -55,33 +55,10 @@ text-decoration: none; } -.monaco-workbench .panel.integrated-terminal .xterm:not(.xterm-cursor-style-underline):not(.xterm-cursor-style-bar).focus .reverse-video, -.monaco-workbench .panel.integrated-terminal .xterm:not(.xterm-cursor-style-underline):not(.xterm-cursor-style-bar):focus .reverse-video { color: #CCC; } -.vs-dark .monaco-workbench .panel.integrated-terminal .xterm:not(.xterm-cursor-style-underline):not(.xterm-cursor-style-bar).focus .reverse-video, -.vs-dark .monaco-workbench .panel.integrated-terminal .xterm:not(.xterm-cursor-style-underline):not(.xterm-cursor-style-bar):focus .reverse-video { color: #1e1e1e; } -.hc-black .monaco-workbench .panel.integrated-terminal .xterm:not(.xterm-cursor-style-underline):not(.xterm-cursor-style-bar).focus .reverse-video, -.hc-black .monaco-workbench .panel.integrated-terminal .xterm:not(.xterm-cursor-style-underline):not(.xterm-cursor-style-bar):focus .reverse-video { color: #000; } - -.monaco-workbench .panel.integrated-terminal .xterm:not(.xterm-cursor-style-underline):not(.xterm-cursor-style-bar).focus .terminal-cursor, -.monaco-workbench .panel.integrated-terminal .xterm:not(.xterm-cursor-style-underline):not(.xterm-cursor-style-bar):focus .terminal-cursor { background-color: #333; } -.vs-dark .monaco-workbench .panel.integrated-terminal .xterm:not(.xterm-cursor-style-underline):not(.xterm-cursor-style-bar).focus .terminal-cursor, -.vs-dark .monaco-workbench .panel.integrated-terminal .xterm:not(.xterm-cursor-style-underline):not(.xterm-cursor-style-bar):focus .terminal-cursor { background-color: #CCC; } -.hc-black .monaco-workbench .panel.integrated-terminal .xterm:not(.xterm-cursor-style-underline):not(.xterm-cursor-style-bar).focus .terminal-cursor, -.hc-black .monaco-workbench .panel.integrated-terminal .xterm:not(.xterm-cursor-style-underline):not(.xterm-cursor-style-bar):focus .terminal-cursor { background-color: #FFF; } - .monaco-workbench .panel.integrated-terminal .xterm:not(.focus):not(:focus) .terminal-cursor { background-color: transparent; - outline: 1px solid #333; - outline-offset: -1px; -} -.vs-dark .monaco-workbench .panel.integrated-terminal .xterm:not(.focus):not(:focus) .terminal-cursor { - background-color: transparent; - outline: 1px solid #CCC; - outline-offset: -1px; -} -.hc-black .monaco-workbench .panel.integrated-terminal .xterm:not(.focus):not(:focus) .terminal-cursor { - background-color: transparent; - outline: 1px solid #FFF; + outline-width: 1px; + outline-style: solid; outline-offset: -1px; } @@ -100,15 +77,6 @@ content: ""; display: block; position: absolute; - background-color: #333; -} -.vs-dark .monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-bar .terminal-cursor::before, -.vs-dark .monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-underline .terminal-cursor::before { - background-color: #CCC; -} -.hc-black .monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-bar .terminal-cursor::before, -.hc-black .monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-underline .terminal-cursor::before { - background-color: #fff; } .monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-bar .terminal-cursor::before { top: 0; @@ -126,18 +94,6 @@ .monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-underline.focus.xterm-cursor-blink.xterm-cursor-blink-on .terminal-cursor::before { background-color: transparent !important; } -.monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-bar.focus.xterm-cursor-blink .terminal-cursor::before, -.monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-underline.focus.xterm-cursor-blink .terminal-cursor::before { - background-color: #333; -} -.vs-dark .monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-bar.focus.xterm-cursor-blink .terminal-cursor::before, -.vs-dark .monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-underline.focus.xterm-cursor-blink .terminal-cursor::before { - background-color: #ccc; -} -.hc-black .monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-bar.focus.xterm-cursor-blink .terminal-cursor::before, -.hc-black .monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-underline.focus.xterm-cursor-blink .terminal-cursor::before { - background-color: #fff; -} .monaco-workbench .panel.integrated-terminal .xterm .xterm-viewport { overflow-y: scroll; diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts index 51ddb07c92b..c3e600af19d 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts @@ -258,7 +258,14 @@ export class TerminalPanel extends Panel { } const fgColor = theme.getColor(TERMINAL_FOREGROUND_COLOR); if (fgColor) { - css += `.monaco-workbench .panel.integrated-terminal .xterm { color: ${fgColor}; }`; + css += `.monaco-workbench .panel.integrated-terminal .xterm { color: ${fgColor}; }` + + `.monaco-workbench .panel.integrated-terminal .xterm:not(.xterm-cursor-style-underline):not(.xterm-cursor-style-bar).focus .terminal-cursor,` + + `.monaco-workbench .panel.integrated-terminal .xterm:not(.xterm-cursor-style-underline):not(.xterm-cursor-style-bar):focus .terminal-cursor { background-color: ${fgColor} }` + + `.monaco-workbench .panel.integrated-terminal .xterm:not(.focus):not(:focus) .terminal-cursor { outline-color: ${fgColor}; }` + + `.monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-bar .terminal-cursor::before,` + + `.monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-underline .terminal-cursor::before { background-color: ${fgColor}; }` + + `.monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-bar.focus.xterm-cursor-blink .terminal-cursor::before,` + + `.monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-underline.focus.xterm-cursor-blink .terminal-cursor::before { background-color: ${fgColor}; }`; } this._themeStyleElement.innerHTML = css; -- GitLab From dea0e91074fea2f421120429d51bb363211827e5 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Fri, 9 Jun 2017 16:11:02 -0700 Subject: [PATCH 0697/1347] Use selection.background for the terminal The new selection model in xterm.js doesn't allow inverting colors right now so piggyback on selection.background. Ideally the terminal would have its own selection key since it has a terminal.background, but this is hopefully just temporary until selection color inverting is done upstream. --- src/vs/platform/theme/common/colorRegistry.ts | 2 +- .../terminal/electron-browser/media/xterm.css | 19 +------------------ .../electron-browser/terminalPanel.ts | 8 +++++++- 3 files changed, 9 insertions(+), 20 deletions(-) diff --git a/src/vs/platform/theme/common/colorRegistry.ts b/src/vs/platform/theme/common/colorRegistry.ts index d790e964b0c..2cd9b78d5ec 100644 --- a/src/vs/platform/theme/common/colorRegistry.ts +++ b/src/vs/platform/theme/common/colorRegistry.ts @@ -137,7 +137,7 @@ export const focusBorder = registerColor('focusBorder', { dark: Color.fromHex('# export const contrastBorder = registerColor('contrastBorder', { light: null, dark: null, hc: '#6FC3DF' }, nls.localize('contrastBorder', "An extra border around elements to separate them from others for greater contrast.")); export const activeContrastBorder = registerColor('contrastActiveBorder', { light: null, dark: null, hc: focusBorder }, nls.localize('activeContrastBorder', "An extra border around active elements to separate them from others for greater contrast.")); -export const selectionBackground = registerColor('selection.background', { light: null, dark: null, hc: null }, nls.localize('selectionBackground', "The background color of text selections in the workbench (e.g. for input fields or text areas). Note that this does not apply to selections within the editor and the terminal.")); +export const selectionBackground = registerColor('selection.background', { light: null, dark: null, hc: null }, nls.localize('selectionBackground', "The background color of text selections in the workbench (e.g. for input fields or text areas). Note that this does not apply to selections within the editor.")); // ------ text colors diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/xterm.css b/src/vs/workbench/parts/terminal/electron-browser/media/xterm.css index e30500606de..fe96994dcc9 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/media/xterm.css +++ b/src/vs/workbench/parts/terminal/electron-browser/media/xterm.css @@ -140,7 +140,7 @@ .monaco-workbench .panel.integrated-terminal .xterm .xterm-selection div { position: absolute; - background-color: #555; + opacity: 0.5; } .monaco-workbench .panel.integrated-terminal .xterm .xterm-bold { @@ -174,23 +174,6 @@ display: block; } -/* Base selection colors */ - -.monaco-workbench .panel.integrated-terminal .xterm ::selection { - color: #FFF; - background-color: rgba(51, 51, 51, 0.996); -} - -.vs-dark .monaco-workbench .panel.integrated-terminal .xterm ::selection { - color: #1e1e1e; - background-color: rgba(204, 204, 204, 0.996); -} - -.hc-black .monaco-workbench .panel.integrated-terminal .xterm ::selection { - color: #000; - background-color: rgba(255, 255, 255, 0.996); -} - /* Terminal colors 16-255 */ .monaco-workbench .panel.integrated-terminal .xterm .xterm-color-16 { diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts index 1a7238730c1..dc7558d33e9 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts @@ -16,7 +16,7 @@ import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { ITerminalService, ITerminalFont, TERMINAL_PANEL_ID } from 'vs/workbench/parts/terminal/common/terminal'; import { IThemeService, ITheme } from 'vs/platform/theme/common/themeService'; import { ansiColorIdentifiers, TERMINAL_BACKGROUND_COLOR, TERMINAL_FOREGROUND_COLOR } from './terminalColorRegistry'; -import { ColorIdentifier } from 'vs/platform/theme/common/colorRegistry'; +import { ColorIdentifier, selectionBackground } from 'vs/platform/theme/common/colorRegistry'; import { KillTerminalAction, CreateNewTerminalAction, SwitchTerminalInstanceAction, SwitchTerminalInstanceActionItem, CopyTerminalSelectionAction, TerminalPasteAction, ClearTerminalAction } from 'vs/workbench/parts/terminal/electron-browser/terminalActions'; import { Panel } from 'vs/workbench/browser/panel'; import { StandardMouseEvent } from 'vs/base/browser/mouseEvent'; @@ -262,6 +262,12 @@ export class TerminalPanel extends Panel { `.monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-bar.focus.xterm-cursor-blink .terminal-cursor::before,` + `.monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-underline.focus.xterm-cursor-blink .terminal-cursor::before { background-color: ${fgColor}; }`; } + // Use selection.background as the terminal selection, this is temporary + // until proper color inverting is implemented to ensure contrast. + const selectionColor = theme.getColor(selectionBackground); + if (selectionColor) { + css += `.monaco-workbench .panel.integrated-terminal .xterm .xterm-selection div { background-color: ${selectionColor}; }`; + } this._themeStyleElement.innerHTML = css; } -- GitLab From ebecfa501bf8d6e353cd971628b05cf5c223fa45 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Fri, 9 Jun 2017 15:19:11 -0700 Subject: [PATCH 0698/1347] Disable http resources in releasenotes --- .../parts/update/electron-browser/releaseNotesEditor.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/update/electron-browser/releaseNotesEditor.ts b/src/vs/workbench/parts/update/electron-browser/releaseNotesEditor.ts index 7f9174f7ca6..c6e9a5015f0 100644 --- a/src/vs/workbench/parts/update/electron-browser/releaseNotesEditor.ts +++ b/src/vs/workbench/parts/update/electron-browser/releaseNotesEditor.ts @@ -27,7 +27,7 @@ function renderBody(body: string): string { - + ${body} -- GitLab From 922c99876fee6fb4c2e658d08045f00e7f84a785 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Fri, 9 Jun 2017 16:31:15 -0700 Subject: [PATCH 0699/1347] Update parameter hint setting desc https://github.com/Microsoft/vscode/issues/28380 --- src/vs/editor/common/config/commonEditorConfig.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/editor/common/config/commonEditorConfig.ts b/src/vs/editor/common/config/commonEditorConfig.ts index 87ecf2fdb30..0dc60d8d6fb 100644 --- a/src/vs/editor/common/config/commonEditorConfig.ts +++ b/src/vs/editor/common/config/commonEditorConfig.ts @@ -386,7 +386,7 @@ const editorConfiguration: IConfigurationNode = { 'editor.parameterHints': { 'type': 'boolean', 'default': EDITOR_DEFAULTS.contribInfo.parameterHints, - 'description': nls.localize('parameterHints', "Enables parameter hints") + 'description': nls.localize('parameterHints', "Enables pop-up that shows parameter documentation and type information as you type") }, 'editor.autoClosingBrackets': { 'type': 'boolean', -- GitLab From c348bfb1056122f98580ad6e1e11ae344dd77d71 Mon Sep 17 00:00:00 2001 From: Cristian Date: Sat, 10 Jun 2017 12:16:33 +0300 Subject: [PATCH 0700/1347] #22622 - final version --- .../parts/debug/electron-browser/debugHover.ts | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts index 96f025bc4bc..ec04f7078bd 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts @@ -22,6 +22,7 @@ import { Expression } from 'vs/workbench/parts/debug/common/debugModel'; import { VariablesRenderer, renderExpressionValue, VariablesDataSource } from 'vs/workbench/parts/debug/electron-browser/debugViewer'; import { IListService } from 'vs/platform/list/browser/listService'; import { DomScrollableElement } from 'vs/base/browser/ui/scrollbar/scrollableElement'; +import { ScrollbarVisibility } from 'vs/base/common/scrollable'; const $ = dom.$; const MAX_ELEMENTS_SHOWN = 18; @@ -55,9 +56,12 @@ export class DebugHoverWidget implements IContentWidget { this.create(instantiationService); this.registerListeners(); - this.valueContainer = dom.append(this.domNode, $('.value')); + this.valueContainer = $('.value'); this.valueContainer.tabIndex = 0; this.valueContainer.setAttribute('role', 'tooltip'); + this.scrollbar = new DomScrollableElement(this.valueContainer, { canUseTranslate3d: false, horizontal: ScrollbarVisibility.Auto, vertical: ScrollbarVisibility.Auto }); + this.domNode.appendChild(this.scrollbar.getDomNode()); + this.toDispose.push(this.scrollbar); this._isVisible = false; this.showAtPosition = null; @@ -70,7 +74,6 @@ export class DebugHoverWidget implements IContentWidget { private create(instantiationService: IInstantiationService): void { this.domNode = $('.debug-hover-widget'); this.complexValueContainer = dom.append(this.domNode, $('.complex-value')); - this.scrollbar = new DomScrollableElement(this.complexValueContainer, { canUseTranslate3d: false }); this.complexValueTitle = dom.append(this.complexValueContainer, $('.title')); this.treeContainer = dom.append(this.complexValueContainer, $('.debug-hover-tree')); this.treeContainer.setAttribute('role', 'tree'); @@ -84,8 +87,6 @@ export class DebugHoverWidget implements IContentWidget { ariaLabel: nls.localize('treeAriaLabel', "Debug Hover"), keyboardSupport: false }); - this.toDispose.push(this.scrollbar); - this.domNode.appendChild(this.scrollbar.getDomNode()); this.toDispose.push(this.listService.register(this.tree)); } @@ -242,6 +243,7 @@ export class DebugHoverWidget implements IContentWidget { showChanged: false, preserveWhitespace: true }); + this.scrollbar.scanDomNode(); this.valueContainer.title = ''; this.editor.layoutContentWidget(this); if (focus) { -- GitLab From 33e339e9fc2e6b4a4d9b8b6d9973362f8542467f Mon Sep 17 00:00:00 2001 From: Ben Stein Date: Sun, 11 Jun 2017 09:08:26 -0700 Subject: [PATCH 0701/1347] Added deregistration for title change check on the terminal message event. --- .../electron-browser/terminalInstance.ts | 24 +++++++------------ 1 file changed, 9 insertions(+), 15 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index 98dbc2f2654..8dd4c361f13 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -59,6 +59,7 @@ export class TerminalInstance implements ITerminalInstance { private _isDisposed: boolean; private _onDisposed: Emitter; private _onDataForApi: Emitter<{ instance: ITerminalInstance, data: string }>; + private _onMessageTitleCheck: (message: any) => void; private _onProcessIdReady: Emitter; private _onTitleChanged: Emitter; private _process: cp.ChildProcess; @@ -479,13 +480,13 @@ export class TerminalInstance implements ITerminalInstance { }); if (!shell.name) { // Only listen for process title changes when a name is not provided - this._process.on('message', this._onPtyProcessMessageTitleChanged); - // this._process.on('message', (message) => { - // if (message.type === 'title') { - // this._title = message.content ? message.content : ''; - // this._onTitleChanged.fire(this._title); - // } - // }); + this._onMessageTitleCheck = (message) => { + if (message.type === 'title') { + this._title = message.content ? message.content : ''; + this._onTitleChanged.fire(this._title); + } + }; + this._process.on('message', this._onMessageTitleCheck); } this._process.on('message', (message) => { if (message.type === 'pid') { @@ -562,13 +563,6 @@ export class TerminalInstance implements ITerminalInstance { } } - private _onPtyProcessMessageTitleChanged(message: any): void { - if (message.type === 'title') { - this._title = message.content ? message.content : ''; - this._onTitleChanged.fire(this._title); - } - } - private _attachPressAnyKeyToCloseListener() { this._processDisposables.push(dom.addDisposableListener(this._xterm.textarea, 'keypress', (event: KeyboardEvent) => { this.dispose(); @@ -779,7 +773,7 @@ export class TerminalInstance implements ITerminalInstance { // if the title is set via API, unregister the handler that automatically updates the terminal name if (this._process) { - this._process.removeListener('message', this._onPtyProcessMessageTitleChanged); + this._process.removeListener('message', this._onMessageTitleCheck); } } } -- GitLab From d57c6a1b38eded15d56c01bf41d53d7baf24eb4f Mon Sep 17 00:00:00 2001 From: Ben Stein Date: Sun, 11 Jun 2017 10:54:03 -0700 Subject: [PATCH 0702/1347] Added missing newline. --- .../parts/terminal/electron-browser/terminalActions.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts index 3a66f07057d..1c7a798b747 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts @@ -583,4 +583,4 @@ export class RenameTerminalAction extends Action { }); } -} \ No newline at end of file +} -- GitLab From 1cc8f3cefbde0b4608fe866e44aa7f3ccc242203 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Sun, 11 Jun 2017 20:36:47 -0700 Subject: [PATCH 0703/1347] Ensure pty gets resize event on layout Fixes #28138 --- .../electron-browser/terminalInstance.ts | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index 919dd7dbdff..98e87b96aae 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -761,13 +761,15 @@ export class TerminalInstance implements ITerminalInstance { this._xterm.resize(this._cols, this._rows); this._xterm.element.style.width = terminalWidth + 'px'; } - if (this._process.connected) { - this._process.send({ - event: 'resize', - cols: this._cols, - rows: this._rows - }); - } + this._processReady.then(() => { + if (this._process) { + this._process.send({ + event: 'resize', + cols: this._cols, + rows: this._rows + }); + } + }); } public enableApiOnData(): void { -- GitLab From bdc326b9fd716e5c619fac84c82e567633b09308 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Mon, 12 Jun 2017 07:53:55 +0200 Subject: [PATCH 0704/1347] Fix #25780: Remove ArraySet and move to native Set --- src/vs/base/common/history.ts | 27 +++++++++---- src/vs/base/common/set.ts | 38 ------------------- .../parts/markers/browser/markersPanel.ts | 13 +++---- .../parts/search/common/searchModel.ts | 9 ++--- .../telemetry/common/workspaceStats.ts | 10 +++-- 5 files changed, 35 insertions(+), 62 deletions(-) delete mode 100644 src/vs/base/common/set.ts diff --git a/src/vs/base/common/history.ts b/src/vs/base/common/history.ts index 22e921b8d77..82099d63c30 100644 --- a/src/vs/base/common/history.ts +++ b/src/vs/base/common/history.ts @@ -3,28 +3,27 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import { ArraySet } from 'vs/base/common/set'; import { INavigator, ArrayNavigator } from 'vs/base/common/iterator'; export class HistoryNavigator implements INavigator { - private _history: ArraySet; + private _history: Set; private _limit: number; private _navigator: ArrayNavigator; constructor(history: T[] = [], limit: number = 10) { - this._history = new ArraySet(history); + this._initialize(history); this._limit = limit; this._onChange(); } public add(t: T) { - this._history.set(t); + this._history.add(t); this._onChange(); } public addIfNotPresent(t: T) { - if (!this._history.contains(t)) { + if (!this._history.has(t)) { this.add(t); } } @@ -63,15 +62,27 @@ export class HistoryNavigator implements INavigator { private _onChange() { this._reduceToLimit(); - this._navigator = new ArrayNavigator(this._history.elements); + this._navigator = new ArrayNavigator(this._elements); this._navigator.last(); } private _reduceToLimit() { - let data = this._history.elements; + let data = this._elements; if (data.length > this._limit) { - this._history = new ArraySet(data.slice(data.length - this._limit)); + this._initialize(data.slice(data.length - this._limit)); } } + private _initialize(history: T[]): void { + this._history = new Set(); + for (const entry of history) { + this._history.add(entry); + } + } + + private get _elements(): T[] { + const elements: T[] = []; + this._history.forEach(e => elements.push(e)); + return elements; + } } \ No newline at end of file diff --git a/src/vs/base/common/set.ts b/src/vs/base/common/set.ts deleted file mode 100644 index 245bf7480f8..00000000000 --- a/src/vs/base/common/set.ts +++ /dev/null @@ -1,38 +0,0 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ - -export class ArraySet { - - private _elements: T[]; - - constructor(elements: T[] = []) { - this._elements = elements.slice(); - } - - get size(): number { - return this._elements.length; - } - - set(element: T): void { - this.unset(element); - this._elements.push(element); - } - - contains(element: T): boolean { - return this._elements.indexOf(element) > -1; - } - - unset(element: T): void { - const index = this._elements.indexOf(element); - - if (index > -1) { - this._elements.splice(index, 1); - } - } - - get elements(): T[] { - return this._elements.slice(); - } -} \ No newline at end of file diff --git a/src/vs/workbench/parts/markers/browser/markersPanel.ts b/src/vs/workbench/parts/markers/browser/markersPanel.ts index f771f5dcaf9..3916e125640 100644 --- a/src/vs/workbench/parts/markers/browser/markersPanel.ts +++ b/src/vs/workbench/parts/markers/browser/markersPanel.ts @@ -6,7 +6,6 @@ import 'vs/css!./media/markers'; import * as errors from 'vs/base/common/errors'; -import * as Set from 'vs/base/common/set'; import URI from 'vs/base/common/uri'; import { TPromise } from 'vs/base/common/winjs.base'; import { Delayer } from 'vs/base/common/async'; @@ -53,7 +52,7 @@ export class MarkersPanel extends Panel { private hasToAutoReveal: boolean; private tree: Tree.ITree; - private autoExpanded: Set.ArraySet; + private autoExpanded: Set; private rangeHighlightDecorations: RangeHighlightDecorations; private actions: IAction[]; @@ -81,7 +80,7 @@ export class MarkersPanel extends Panel { super(Constants.MARKERS_PANEL_ID, telemetryService, themeService); this.toDispose = []; this.delayedRefresh = new Delayer(500); - this.autoExpanded = new Set.ArraySet(); + this.autoExpanded = new Set(); this.markerFocusContextKey = Constants.MarkerFocusContextKey.bindTo(contextKeyService); } @@ -188,7 +187,7 @@ export class MarkersPanel extends Panel { public updateFilter(filter: string) { this.markersModel.update(new FilterOptions(filter)); - this.autoExpanded = new Set.ArraySet(); + this.autoExpanded = new Set(); this.refreshPanel(); this.autoReveal(); } @@ -304,7 +303,7 @@ export class MarkersPanel extends Panel { bulkUpdater.done(); for (const resource of resources) { if (!this.markersModel.hasResource(resource)) { - this.autoExpanded.unset(resource.toString()); + this.autoExpanded.delete(resource.toString()); } } } @@ -326,9 +325,9 @@ export class MarkersPanel extends Panel { private autoExpand(): void { for (const resource of this.markersModel.filteredResources) { const resourceUri = resource.uri.toString(); - if (!this.autoExpanded.contains(resourceUri)) { + if (!this.autoExpanded.has(resourceUri)) { this.tree.expand(resource).done(null, errors.onUnexpectedError); - this.autoExpanded.set(resourceUri); + this.autoExpanded.add(resourceUri); } } } diff --git a/src/vs/workbench/parts/search/common/searchModel.ts b/src/vs/workbench/parts/search/common/searchModel.ts index f8d357a5a26..2a9c6145928 100644 --- a/src/vs/workbench/parts/search/common/searchModel.ts +++ b/src/vs/workbench/parts/search/common/searchModel.ts @@ -12,7 +12,6 @@ import { IDisposable, Disposable } from 'vs/base/common/lifecycle'; import { TPromise, PPromise } from 'vs/base/common/winjs.base'; import URI from 'vs/base/common/uri'; import { SimpleMap } from 'vs/base/common/map'; -import { ArraySet } from 'vs/base/common/set'; import Event, { Emitter, fromPromise, stopwatch, any } from 'vs/base/common/event'; import { ISearchService, ISearchProgressItem, ISearchComplete, ISearchQuery, IPatternInfo, IFileMatch } from 'vs/platform/search/common/search'; import { ReplacePattern } from 'vs/platform/search/common/replace'; @@ -127,7 +126,7 @@ export class FileMatch extends Disposable { private _model: IModel; private _modelListener: IDisposable; private _matches: SimpleMap; - private _removedMatches: ArraySet; + private _removedMatches: Set; private _selectedMatch: Match; private _updateScheduler: RunOnceScheduler; @@ -138,7 +137,7 @@ export class FileMatch extends Disposable { super(); this._resource = this.rawMatch.resource; this._matches = new SimpleMap(); - this._removedMatches = new ArraySet(); + this._removedMatches = new Set(); this._updateScheduler = new RunOnceScheduler(this.updateMatchesForModel.bind(this), 250); this.createMatches(); @@ -222,7 +221,7 @@ export class FileMatch extends Disposable { private updateMatches(matches: FindMatch[], modelChange: boolean) { matches.forEach(m => { let match = new Match(this, this._model.getLineContent(m.range.startLineNumber), m.range.startLineNumber - 1, m.range.startColumn - 1, m.range.endColumn - m.range.startColumn); - if (!this._removedMatches.contains(match.id())) { + if (!this._removedMatches.has(match.id())) { this.add(match); if (this.isMatchSelected(match)) { this._selectedMatch = match; @@ -263,7 +262,7 @@ export class FileMatch extends Disposable { public remove(match: Match): void { this.removeMatch(match); - this._removedMatches.set(match.id()); + this._removedMatches.add(match.id()); this._onChange.fire(false); } diff --git a/src/vs/workbench/services/telemetry/common/workspaceStats.ts b/src/vs/workbench/services/telemetry/common/workspaceStats.ts index 725b76e72ad..6fd83f56c53 100644 --- a/src/vs/workbench/services/telemetry/common/workspaceStats.ts +++ b/src/vs/workbench/services/telemetry/common/workspaceStats.ts @@ -8,7 +8,6 @@ import winjs = require('vs/base/common/winjs.base'); import errors = require('vs/base/common/errors'); import URI from 'vs/base/common/uri'; -import { ArraySet } from 'vs/base/common/set'; import { IFileService } from 'vs/platform/files/common/files'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; @@ -60,12 +59,12 @@ function extractDomain(url: string): string { } export function getDomainsOfRemotes(text: string, whitelist: string[]): string[] { - let domains = new ArraySet(); + let domains = new Set(); let match: RegExpExecArray; while (match = RemoteMatcher.exec(text)) { let domain = extractDomain(match[1]); if (domain) { - domains.set(domain); + domains.add(domain); } } @@ -74,7 +73,10 @@ export function getDomainsOfRemotes(text: string, whitelist: string[]): string[] return map; }, Object.create(null)); - return domains.elements + const elements: string[] = []; + domains.forEach(e => elements.push(e)); + + return elements .map(key => whitemap[key] ? key : key.replace(AnyButDot, 'a')); } -- GitLab From 25b4b172e402a86657104581acc1c925fd4e3cf2 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Mon, 12 Jun 2017 08:16:05 +0200 Subject: [PATCH 0705/1347] extract more functionality into IWorkspace --- .../browser/standalone/standaloneServices.ts | 8 +-- src/vs/platform/workspace/common/workspace.ts | 60 ++++++++++++++----- .../workspace/test/common/testWorkspace.ts | 12 ++-- src/vs/workbench/electron-browser/main.ts | 20 +++---- src/vs/workbench/node/extensionHostMain.ts | 11 +++- .../terminalLinkHandler.test.ts | 9 ++- .../node/configurationService.ts | 19 +++--- .../node/configurationEditingService.test.ts | 10 ++-- .../test/node/configurationService.test.ts | 22 +++---- .../quickopen.perf.integrationTest.ts | 4 +- .../textsearch.perf.integrationTest.ts | 4 +- 11 files changed, 108 insertions(+), 71 deletions(-) diff --git a/src/vs/editor/browser/standalone/standaloneServices.ts b/src/vs/editor/browser/standalone/standaloneServices.ts index 550b5294605..68e9623baf1 100644 --- a/src/vs/editor/browser/standalone/standaloneServices.ts +++ b/src/vs/editor/browser/standalone/standaloneServices.ts @@ -22,7 +22,7 @@ import { IMessageService } from 'vs/platform/message/common/message'; import { IProgressService } from 'vs/platform/progress/common/progress'; import { IStorageService, NullStorageService } from 'vs/platform/storage/common/storage'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; -import { IWorkspaceContextService, WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService, WorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import { ICodeEditorService } from 'vs/editor/common/services/codeEditorService'; import { IEditorWorkerService } from 'vs/editor/common/services/editorWorkerService'; import { EditorWorkerServiceImpl } from 'vs/editor/common/services/editorWorkerServiceImpl'; @@ -115,9 +115,9 @@ export module StaticServices { export const instantiationService = define(IInstantiationService, () => new InstantiationService(_serviceCollection, true)); - export const contextService = define(IWorkspaceContextService, () => new WorkspaceContextService({ - resource: URI.from({ scheme: 'inmemory', authority: 'model', path: '/' }) - })); + export const contextService = define(IWorkspaceContextService, () => new WorkspaceContextService(new Workspace( + URI.from({ scheme: 'inmemory', authority: 'model', path: '/' }) + ))); export const telemetryService = define(ITelemetryService, () => new StandaloneTelemetryService()); diff --git a/src/vs/platform/workspace/common/workspace.ts b/src/vs/platform/workspace/common/workspace.ts index 1218ddd4da8..eae7c42e20c 100644 --- a/src/vs/platform/workspace/common/workspace.ts +++ b/src/vs/platform/workspace/common/workspace.ts @@ -65,27 +65,26 @@ export interface IWorkspace { name?: string; } -export class WorkspaceContextService implements IWorkspaceContextService { - - public _serviceBrand: any; +export class Workspace implements IWorkspace { - private workspace: IWorkspace; + constructor(private _resource: URI, private _uid?: number, private _name?: string) { + } - constructor(workspace: IWorkspace) { - this.workspace = workspace; + public get resource(): URI { + return this._resource; } - public getWorkspace(): IWorkspace { - return this.workspace; + public get uid(): number { + return this._uid; } - public hasWorkspace(): boolean { - return !!this.workspace; + public get name(): string { + return this._name; } public isInsideWorkspace(resource: URI): boolean { - if (resource && this.workspace) { - return isEqualOrParent(resource.fsPath, this.workspace.resource.fsPath, !isLinux /* ignorecase */); + if (resource) { + return isEqualOrParent(resource.fsPath, this._resource.fsPath, !isLinux /* ignorecase */); } return false; @@ -93,17 +92,48 @@ export class WorkspaceContextService implements IWorkspaceContextService { public toWorkspaceRelativePath(resource: URI, toOSPath?: boolean): string { if (this.isInsideWorkspace(resource)) { - return paths.normalize(paths.relative(this.workspace.resource.fsPath, resource.fsPath), toOSPath); + return paths.normalize(paths.relative(this._resource.fsPath, resource.fsPath), toOSPath); } return null; } public toResource(workspaceRelativePath: string): URI { - if (typeof workspaceRelativePath === 'string' && this.workspace) { - return URI.file(paths.join(this.workspace.resource.fsPath, workspaceRelativePath)); + if (typeof workspaceRelativePath === 'string') { + return URI.file(paths.join(this._resource.fsPath, workspaceRelativePath)); } return null; } +} + +export class WorkspaceContextService implements IWorkspaceContextService { + + public _serviceBrand: any; + + private workspace: Workspace; + + constructor(workspace?: Workspace) { + this.workspace = workspace; + } + + public getWorkspace(): IWorkspace { + return this.workspace; + } + + public hasWorkspace(): boolean { + return !!this.workspace; + } + + public isInsideWorkspace(resource: URI): boolean { + return this.workspace ? this.workspace.isInsideWorkspace(resource) : false; + } + + public toWorkspaceRelativePath(resource: URI, toOSPath?: boolean): string { + return this.workspace ? this.workspace.toWorkspaceRelativePath(resource, toOSPath) : null; + } + + public toResource(workspaceRelativePath: string): URI { + return this.workspace ? this.workspace.toResource(workspaceRelativePath) : null; + } } \ No newline at end of file diff --git a/src/vs/platform/workspace/test/common/testWorkspace.ts b/src/vs/platform/workspace/test/common/testWorkspace.ts index 237d8529523..18926c9330d 100644 --- a/src/vs/platform/workspace/test/common/testWorkspace.ts +++ b/src/vs/platform/workspace/test/common/testWorkspace.ts @@ -3,11 +3,11 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import { IWorkspace } from 'vs/platform/workspace/common/workspace'; +import { Workspace } from 'vs/platform/workspace/common/workspace'; import URI from 'vs/base/common/uri'; -export const TestWorkspace: IWorkspace = { - resource: URI.file('C:\\testWorkspace'), - name: 'Test Workspace', - uid: Date.now() -}; +export const TestWorkspace = new Workspace( + URI.file('C:\\testWorkspace'), + Date.now(), + 'Test Workspace' +); diff --git a/src/vs/workbench/electron-browser/main.ts b/src/vs/workbench/electron-browser/main.ts index b20a6fd422a..b8bfbe51ce6 100644 --- a/src/vs/workbench/electron-browser/main.ts +++ b/src/vs/workbench/electron-browser/main.ts @@ -18,7 +18,7 @@ import paths = require('vs/base/common/paths'); import uri from 'vs/base/common/uri'; import strings = require('vs/base/common/strings'); import { IResourceInput } from 'vs/platform/editor/common/editor'; -import { IWorkspace, WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { WorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import { WorkspaceConfigurationService } from 'vs/workbench/services/configuration/node/configurationService'; import { ParsedArgs } from 'vs/platform/environment/common/environment'; import { realpath, stat } from 'vs/base/node/pfs'; @@ -116,7 +116,7 @@ function toInputs(paths: IPath[], isUntitledFile?: boolean): IResourceInput[] { }); } -function getWorkspace(workspacePath: string): TPromise { +function getWorkspace(workspacePath: string): TPromise { if (!workspacePath) { return TPromise.as(null); } @@ -135,23 +135,23 @@ function getWorkspace(workspacePath: string): TPromise { const folderName = path.basename(realWorkspacePath) || realWorkspacePath; return stat(realWorkspacePath).then(folderStat => { - return { - 'resource': workspaceResource, - 'name': folderName, - 'uid': platform.isLinux ? folderStat.ino : folderStat.birthtime.getTime() // On Linux, birthtime is ctime, so we cannot use it! We use the ino instead! - }; + return new Workspace( + workspaceResource, + platform.isLinux ? folderStat.ino : folderStat.birthtime.getTime(), + folderName // On Linux, birthtime is ctime, so we cannot use it! We use the ino instead! + ); }); - }, (error) => { + }, error => { errors.onUnexpectedError(error); return null; // treat invalid paths as empty workspace }); } -function openWorkbench(environment: IWindowConfiguration, workspace: IWorkspace, options: IOptions): TPromise { +function openWorkbench(environment: IWindowConfiguration, workspace: Workspace, options: IOptions): TPromise { const environmentService = new EnvironmentService(environment, environment.execPath); const contextService = new WorkspaceContextService(workspace); - const configurationService = new WorkspaceConfigurationService(contextService, environmentService); + const configurationService = new WorkspaceConfigurationService(environmentService, workspace); const timerService = new TimerService((window).MonacoEnvironment.timers as IInitData, !contextService.hasWorkspace()); // Since the configuration service is one of the core services that is used in so many places, we initialize it diff --git a/src/vs/workbench/node/extensionHostMain.ts b/src/vs/workbench/node/extensionHostMain.ts index fd41b0c29fe..abb6f76e6c8 100644 --- a/src/vs/workbench/node/extensionHostMain.ts +++ b/src/vs/workbench/node/extensionHostMain.ts @@ -15,7 +15,7 @@ import { ExtHostThreadService } from 'vs/workbench/services/thread/common/extHos import { QueryType, ISearchQuery } from 'vs/platform/search/common/search'; import { DiskSearch } from 'vs/workbench/services/search/node/searchService'; import { RemoteTelemetryService } from 'vs/workbench/api/node/extHostTelemetry'; -import { IWorkspaceContextService, WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService, WorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import { IInitData, IEnvironment, MainContext } from 'vs/workbench/api/node/extHost.protocol'; import * as errors from 'vs/base/common/errors'; @@ -43,7 +43,14 @@ export class ExtensionHostMain { constructor(remoteCom: IRemoteCom, initData: IInitData) { // services this._environment = initData.environment; - this._contextService = new WorkspaceContextService(initData.contextService.workspace); + + const workspaceRaw = initData.contextService.workspace; + let workspace: Workspace; + if (workspaceRaw) { + workspace = new Workspace(workspaceRaw.resource, workspaceRaw.uid, workspaceRaw.name); + } + this._contextService = new WorkspaceContextService(workspace); + const threadService = new ExtHostThreadService(remoteCom); const telemetryService = new RemoteTelemetryService('pluginHostTelemetry', threadService); this._extensionService = new ExtHostExtensionService(initData, threadService, telemetryService, this._contextService); diff --git a/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts b/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts index a491d6153d1..d61de282fd4 100644 --- a/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts +++ b/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts @@ -8,7 +8,7 @@ import * as assert from 'assert'; import { Platform } from 'vs/base/common/platform'; import { TerminalLinkHandler, LineColumnInfo } from 'vs/workbench/parts/terminal/electron-browser/terminalLinkHandler'; -import { IWorkspace, WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { WorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import URI from 'vs/base/common/uri'; import * as strings from 'vs/base/common/strings'; import * as path from 'path'; @@ -44,10 +44,9 @@ interface LinkFormatInfo { column?: string; } -class TestWorkspace implements IWorkspace { - resource: URI; - constructor(basePath: string) { - this.resource = new TestURI(basePath); +class TestWorkspace extends Workspace { + constructor(private basePath: string) { + super(new TestURI(basePath)); } } diff --git a/src/vs/workbench/services/configuration/node/configurationService.ts b/src/vs/workbench/services/configuration/node/configurationService.ts index b0537b9a12c..9ea368f587b 100644 --- a/src/vs/workbench/services/configuration/node/configurationService.ts +++ b/src/vs/workbench/services/configuration/node/configurationService.ts @@ -12,7 +12,6 @@ import extfs = require('vs/base/node/extfs'); import objects = require('vs/base/common/objects'); import { RunOnceScheduler } from 'vs/base/common/async'; import collections = require('vs/base/common/collections'); -import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { IDisposable, Disposable } from 'vs/base/common/lifecycle'; import { readFile } from 'vs/base/node/pfs'; @@ -24,7 +23,7 @@ import { ConfigurationService as BaseConfigurationService } from 'vs/platform/co import { IWorkspaceConfigurationValues, IWorkspaceConfigurationService, IWorkspaceConfigurationValue, WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME, WORKSPACE_STANDALONE_CONFIGURATIONS, WORKSPACE_CONFIG_DEFAULT_PATH } from 'vs/workbench/services/configuration/common/configuration'; import { FileChangeType, FileChangesEvent, isEqual } from 'vs/platform/files/common/files'; import Event, { Emitter } from 'vs/base/common/event'; - +import { Workspace } from "vs/platform/workspace/common/workspace"; interface IStat { resource: uri; @@ -62,8 +61,8 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp private reloadConfigurationScheduler: RunOnceScheduler; constructor( - @IWorkspaceContextService private contextService: IWorkspaceContextService, - @IEnvironmentService environmentService: IEnvironmentService, + private environmentService: IEnvironmentService, + private workspace?: Workspace, private workspaceSettingsRootFolder: string = WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME ) { super(); @@ -216,13 +215,13 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp private loadWorkspaceConfigFiles(): TPromise<{ [relativeWorkspacePath: string]: IConfigModel }> { // Return early if we don't have a workspace - if (!this.contextService.hasWorkspace()) { + if (!this.workspace) { return TPromise.as(Object.create(null)); } // once: when invoked for the first time we fetch json files that contribute settings if (!this.bulkFetchFromWorkspacePromise) { - this.bulkFetchFromWorkspacePromise = resolveStat(this.contextService.toResource(this.workspaceSettingsRootFolder)).then(stat => { + this.bulkFetchFromWorkspacePromise = resolveStat(this.workspace.toResource(this.workspaceSettingsRootFolder)).then(stat => { if (!stat.isDirectory) { return TPromise.as([]); } @@ -233,11 +232,11 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp return false; // only JSON files } - return this.isWorkspaceConfigurationFile(this.contextService.toWorkspaceRelativePath(stat.resource)); // only workspace config files + return this.isWorkspaceConfigurationFile(this.workspace.toWorkspaceRelativePath(stat.resource)); // only workspace config files }).map(stat => stat.resource)); }, err => [] /* never fail this call */) .then((contents: IContent[]) => { - contents.forEach(content => this.workspaceFilePathToConfiguration[this.contextService.toWorkspaceRelativePath(content.resource)] = TPromise.as(this.createConfigModel(content))); + contents.forEach(content => this.workspaceFilePathToConfiguration[this.workspace.toWorkspaceRelativePath(content.resource)] = TPromise.as(this.createConfigModel(content))); }, errors.onUnexpectedError); } @@ -259,7 +258,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp continue; // only JSON files or the actual settings folder } - const workspacePath = this.contextService.toWorkspaceRelativePath(resource); + const workspacePath = this.workspace.toWorkspaceRelativePath(resource); if (!workspacePath) { continue; // event is not inside workspace } @@ -295,7 +294,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } private createConfigModel(content: IContent): IConfigModel { - const path = this.contextService.toWorkspaceRelativePath(content.resource); + const path = this.workspace.toWorkspaceRelativePath(content.resource); if (path === WORKSPACE_CONFIG_DEFAULT_PATH) { return new WorkspaceSettingsConfigModel(content.value, content.resource.toString()); } else { diff --git a/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts b/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts index a444ccfb9cf..df423a3c094 100644 --- a/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts +++ b/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts @@ -15,7 +15,7 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { Registry } from 'vs/platform/platform'; import { ParsedArgs, IEnvironmentService } from 'vs/platform/environment/common/environment'; import { parseArgs } from 'vs/platform/environment/node/argv'; -import { WorkspaceContextService, IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { WorkspaceContextService, IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import { EnvironmentService } from 'vs/platform/environment/node/environmentService'; import extfs = require('vs/base/node/extfs'); import { TestTextFileService, TestEditorGroupService, TestLifecycleService, TestBackupFileService } from 'vs/workbench/test/workbenchTestServices'; @@ -113,9 +113,11 @@ suite('ConfigurationEditingService', () => { clearServices(); instantiationService = new TestInstantiationService(); - instantiationService.stub(IEnvironmentService, new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile)); - instantiationService.stub(IWorkspaceContextService, new WorkspaceContextService(noWorkspace ? null : { resource: URI.file(workspaceDir) })); - const configurationService = instantiationService.createInstance(WorkspaceConfigurationService); + const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); + instantiationService.stub(IEnvironmentService, environmentService); + const workspace = noWorkspace ? null : new Workspace(URI.file(workspaceDir)); + instantiationService.stub(IWorkspaceContextService, new WorkspaceContextService(workspace)); + const configurationService = new WorkspaceConfigurationService(environmentService, workspace); instantiationService.stub(IConfigurationService, configurationService); instantiationService.stub(ILifecycleService, new TestLifecycleService()); instantiationService.stub(IEditorGroupService, new TestEditorGroupService()); diff --git a/src/vs/workbench/services/configuration/test/node/configurationService.test.ts b/src/vs/workbench/services/configuration/test/node/configurationService.test.ts index 3d202425b4a..c61238061d7 100644 --- a/src/vs/workbench/services/configuration/test/node/configurationService.test.ts +++ b/src/vs/workbench/services/configuration/test/node/configurationService.test.ts @@ -13,7 +13,7 @@ import * as sinon from 'sinon'; import { TPromise } from 'vs/base/common/winjs.base'; import { Registry } from 'vs/platform/platform'; import { ParsedArgs } from 'vs/platform/environment/common/environment'; -import { WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { Workspace } from 'vs/platform/workspace/common/workspace'; import { EnvironmentService } from 'vs/platform/environment/node/environmentService'; import { parseArgs } from 'vs/platform/environment/node/argv'; import extfs = require('vs/base/node/extfs'); @@ -47,9 +47,9 @@ suite('WorkspaceConfigurationService - Node', () => { } function createService(workspaceDir: string, globalSettingsFile: string): TPromise { - const workspaceContextService = new WorkspaceContextService({ resource: URI.file(workspaceDir) }); + const workspace = new Workspace(URI.file(workspaceDir)); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); - const service = new WorkspaceConfigurationService(workspaceContextService, environmentService); + const service = new WorkspaceConfigurationService(environmentService, workspace); return service.initialize().then(() => service); } @@ -204,9 +204,9 @@ suite('WorkspaceConfigurationService - Node', () => { test('workspace change triggers event', (done: () => void) => { createWorkspace((workspaceDir, globalSettingsFile, cleanUp) => { - const workspaceContextService = new WorkspaceContextService({ resource: URI.file(workspaceDir) }); + const workspace = new Workspace(URI.file(workspaceDir)); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); - const service = new WorkspaceConfigurationService(workspaceContextService, environmentService); + const service = new WorkspaceConfigurationService(environmentService, workspace); return service.initialize().then(() => { service.onDidUpdateConfiguration(event => { @@ -230,9 +230,9 @@ suite('WorkspaceConfigurationService - Node', () => { test('workspace reload should triggers event if content changed', (done: () => void) => { createWorkspace((workspaceDir, globalSettingsFile, cleanUp) => { - const workspaceContextService = new WorkspaceContextService({ resource: URI.file(workspaceDir) }); + const workspace = new Workspace(URI.file(workspaceDir)); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); - const service = new WorkspaceConfigurationService(workspaceContextService, environmentService); + const service = new WorkspaceConfigurationService(environmentService, workspace); return service.initialize().then(() => { const settingsFile = path.join(workspaceDir, '.vscode', 'settings.json'); @@ -255,9 +255,9 @@ suite('WorkspaceConfigurationService - Node', () => { test('workspace reload should not trigger event if nothing changed', (done: () => void) => { createWorkspace((workspaceDir, globalSettingsFile, cleanUp) => { - const workspaceContextService = new WorkspaceContextService({ resource: URI.file(workspaceDir) }); + const workspace = new Workspace(URI.file(workspaceDir)); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); - const service = new WorkspaceConfigurationService(workspaceContextService, environmentService); + const service = new WorkspaceConfigurationService(environmentService, workspace); return service.initialize().then(() => { const settingsFile = path.join(workspaceDir, '.vscode', 'settings.json'); @@ -280,9 +280,9 @@ suite('WorkspaceConfigurationService - Node', () => { test('workspace reload should not trigger event if there is no model', (done: () => void) => { createWorkspace((workspaceDir, globalSettingsFile, cleanUp) => { - const workspaceContextService = new WorkspaceContextService({ resource: URI.file(workspaceDir) }); + const workspace = new Workspace(URI.file(workspaceDir)); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); - const service = new WorkspaceConfigurationService(workspaceContextService, environmentService); + const service = new WorkspaceConfigurationService(environmentService, workspace); return service.initialize().then(() => { const target = sinon.stub(); diff --git a/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts b/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts index ad4fdee36f5..dfd2576d1d4 100644 --- a/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts +++ b/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts @@ -7,7 +7,7 @@ import 'vs/workbench/parts/search/browser/search.contribution'; // load contributions import * as assert from 'assert'; -import { WorkspaceContextService, IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { WorkspaceContextService, IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import { createSyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { ISearchService } from 'vs/platform/search/common/search'; @@ -73,7 +73,7 @@ suite('QuickOpen performance (integration)', () => { [ITelemetryService, telemetryService], [IConfigurationService, new SimpleConfigurationService()], [IModelService, new ModelServiceImpl(null, configurationService)], - [IWorkspaceContextService, new WorkspaceContextService({ resource: URI.file(testWorkspacePath) })], + [IWorkspaceContextService, new WorkspaceContextService(new Workspace(URI.file(testWorkspacePath)))], [IWorkbenchEditorService, new TestEditorService()], [IEditorGroupService, new TestEditorGroupService()], [IEnvironmentService, TestEnvironmentService], diff --git a/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts b/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts index 861ff475677..7d1bb6b1139 100644 --- a/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts +++ b/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts @@ -8,7 +8,7 @@ import 'vs/workbench/parts/search/browser/search.contribution'; // load contributions import * as assert from 'assert'; import * as fs from 'fs'; -import { WorkspaceContextService, IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { WorkspaceContextService, IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import { createSyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { ISearchService, IQueryOptions } from 'vs/platform/search/common/search'; @@ -62,7 +62,7 @@ suite('TextSearch performance (integration)', () => { [ITelemetryService, telemetryService], [IConfigurationService, new SimpleConfigurationService()], [IModelService, new ModelServiceImpl(null, configurationService)], - [IWorkspaceContextService, new WorkspaceContextService({ resource: URI.file(testWorkspacePath) })], + [IWorkspaceContextService, new WorkspaceContextService(new Workspace(URI.file(testWorkspacePath)))], [IWorkbenchEditorService, new TestEditorService()], [IEditorGroupService, new TestEditorGroupService()], [IEnvironmentService, TestEnvironmentService], -- GitLab From 54f46520d4a3d37fd9246b4fb11e10c5b27ce5d9 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Mon, 12 Jun 2017 09:30:18 +0200 Subject: [PATCH 0706/1347] Added try/catch not to break on file not found error for 'resources to pull from Transifex' file. --- build/lib/tslint/translationRemindRule.js | 151 +++++++++++----------- build/lib/tslint/translationRemindRule.ts | 8 +- 2 files changed, 86 insertions(+), 73 deletions(-) diff --git a/build/lib/tslint/translationRemindRule.js b/build/lib/tslint/translationRemindRule.js index 53e6929d8e6..90ba94aa5f4 100644 --- a/build/lib/tslint/translationRemindRule.js +++ b/build/lib/tslint/translationRemindRule.js @@ -1,72 +1,79 @@ -"use strict"; -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ -var __extends = (this && this.__extends) || (function () { - var extendStatics = Object.setPrototypeOf || - ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; - return function (d, b) { - extendStatics(d, b); - function __() { this.constructor = d; } - d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); - }; -})(); -Object.defineProperty(exports, "__esModule", { value: true }); -var Lint = require("tslint"); -var fs = require("fs"); -var Rule = (function (_super) { - __extends(Rule, _super); - function Rule() { - return _super !== null && _super.apply(this, arguments) || this; - } - Rule.prototype.apply = function (sourceFile) { - return this.applyWithWalker(new TranslationRemindRuleWalker(sourceFile, this.getOptions())); - }; - return Rule; -}(Lint.Rules.AbstractRule)); -exports.Rule = Rule; -var TranslationRemindRuleWalker = (function (_super) { - __extends(TranslationRemindRuleWalker, _super); - function TranslationRemindRuleWalker(file, opts) { - return _super.call(this, file, opts) || this; - } - TranslationRemindRuleWalker.prototype.visitImportDeclaration = function (node) { - var declaration = node.moduleSpecifier.getText(); - if (declaration !== "'" + TranslationRemindRuleWalker.NLS_MODULE + "'") { - return; - } - this.visitImportLikeDeclaration(node); - }; - TranslationRemindRuleWalker.prototype.visitImportEqualsDeclaration = function (node) { - var reference = node.moduleReference.getText(); - if (reference !== "require('" + TranslationRemindRuleWalker.NLS_MODULE + "')") { - return; - } - this.visitImportLikeDeclaration(node); - }; - TranslationRemindRuleWalker.prototype.visitImportLikeDeclaration = function (node) { - var currentFile = node.getSourceFile().fileName; - var matchService = currentFile.match(/vs\/workbench\/services\/\w+/); - var matchPart = currentFile.match(/vs\/workbench\/parts\/\w+/); - if (!matchService && !matchPart) { - return; - } - var resource = matchService ? matchService[0] : matchPart[0]; - var resourceDefined = false; - var json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); - var workbenchResources = JSON.parse(json).workbench; - workbenchResources.forEach(function (existingResource) { - if (existingResource.name === resource) { - resourceDefined = true; - return; - } - }); - if (!resourceDefined) { - this.addFailureAtNode(node, "Please add '" + resource + "' to ./builds/lib/i18n.resources.json file to use translations here."); - } - }; - return TranslationRemindRuleWalker; -}(Lint.RuleWalker)); -TranslationRemindRuleWalker.NLS_MODULE = 'vs/nls'; +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +"use strict"; +var __extends = (this && this.__extends) || (function () { + var extendStatics = Object.setPrototypeOf || + ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || + function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + return function (d, b) { + extendStatics(d, b); + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); + }; +})(); +exports.__esModule = true; +var Lint = require("tslint"); +var fs = require("fs"); +var Rule = (function (_super) { + __extends(Rule, _super); + function Rule() { + return _super !== null && _super.apply(this, arguments) || this; + } + Rule.prototype.apply = function (sourceFile) { + return this.applyWithWalker(new TranslationRemindRuleWalker(sourceFile, this.getOptions())); + }; + return Rule; +}(Lint.Rules.AbstractRule)); +exports.Rule = Rule; +var TranslationRemindRuleWalker = (function (_super) { + __extends(TranslationRemindRuleWalker, _super); + function TranslationRemindRuleWalker(file, opts) { + return _super.call(this, file, opts) || this; + } + TranslationRemindRuleWalker.prototype.visitImportDeclaration = function (node) { + var declaration = node.moduleSpecifier.getText(); + if (declaration !== "'" + TranslationRemindRuleWalker.NLS_MODULE + "'") { + return; + } + this.visitImportLikeDeclaration(node); + }; + TranslationRemindRuleWalker.prototype.visitImportEqualsDeclaration = function (node) { + var reference = node.moduleReference.getText(); + if (reference !== "require('" + TranslationRemindRuleWalker.NLS_MODULE + "')") { + return; + } + this.visitImportLikeDeclaration(node); + }; + TranslationRemindRuleWalker.prototype.visitImportLikeDeclaration = function (node) { + var currentFile = node.getSourceFile().fileName; + var matchService = currentFile.match(/vs\/workbench\/services\/\w+/); + var matchPart = currentFile.match(/vs\/workbench\/parts\/\w+/); + if (!matchService && !matchPart) { + return; + } + var resource = matchService ? matchService[0] : matchPart[0]; + var resourceDefined = false; + var json; + try { + json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); + } + catch (e) { + console.error('[translation-remind rule]: File with resources to pull from Transifex was not found. Aborting translation resource check for newly defined workbench part/service.'); + return; + } + var workbenchResources = JSON.parse(json).workbench; + workbenchResources.forEach(function (existingResource) { + if (existingResource.name === resource) { + resourceDefined = true; + return; + } + }); + if (!resourceDefined) { + this.addFailureAtNode(node, "Please add '" + resource + "' to ./builds/lib/i18n.resources.json file to use translations here."); + } + }; + return TranslationRemindRuleWalker; +}(Lint.RuleWalker)); +TranslationRemindRuleWalker.NLS_MODULE = 'vs/nls'; diff --git a/build/lib/tslint/translationRemindRule.ts b/build/lib/tslint/translationRemindRule.ts index b33025a3536..6bc2a191619 100644 --- a/build/lib/tslint/translationRemindRule.ts +++ b/build/lib/tslint/translationRemindRule.ts @@ -50,7 +50,13 @@ class TranslationRemindRuleWalker extends Lint.RuleWalker { const resource = matchService ? matchService[0] : matchPart[0]; let resourceDefined = false; - const json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); + let json; + try { + json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); + } catch (e) { + console.error('[translation-remind rule]: File with resources to pull from Transifex was not found. Aborting translation resource check for newly defined workbench part/service.'); + return; + } const workbenchResources = JSON.parse(json).workbench; workbenchResources.forEach(existingResource => { -- GitLab From 7a927e308f12cbd9f505a37d8c15b2e0c7c372ae Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Mon, 12 Jun 2017 10:23:57 +0200 Subject: [PATCH 0707/1347] Move LinkedMap into map.ts --- src/vs/base/common/linkedMap.ts | 306 ------------------ src/vs/base/common/map.ts | 304 +++++++++++++++++ .../parts/tasks/common/taskService.ts | 2 +- .../electron-browser/task.contribution.ts | 2 +- 4 files changed, 306 insertions(+), 308 deletions(-) delete mode 100644 src/vs/base/common/linkedMap.ts diff --git a/src/vs/base/common/linkedMap.ts b/src/vs/base/common/linkedMap.ts deleted file mode 100644 index 65eaa0e6c85..00000000000 --- a/src/vs/base/common/linkedMap.ts +++ /dev/null @@ -1,306 +0,0 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ - -interface Item { - previous: Item | undefined; - next: Item | undefined; - key: K; - value: V; -} - -export namespace Touch { - export const None: 0 = 0; - export const First: 1 = 1; - export const Last: 2 = 2; -} - -export type Touch = 0 | 1 | 2; - -export class LinkedMap { - - private _map: Map>; - private _head: Item | undefined; - private _tail: Item | undefined; - private _size: number; - - constructor() { - this._map = new Map>(); - this._head = undefined; - this._tail = undefined; - this._size = 0; - } - - public clear(): void { - this._map.clear(); - this._head = undefined; - this._tail = undefined; - this._size = 0; - } - - public isEmpty(): boolean { - return !this._head && !this._tail; - } - - public get size(): number { - return this._size; - } - - public has(key: K): boolean { - return this._map.has(key); - } - - public get(key: K): V | undefined { - const item = this._map.get(key); - if (!item) { - return undefined; - } - return item.value; - } - - public set(key: K, value: V, touch: Touch = Touch.None): void { - let item = this._map.get(key); - if (item) { - item.value = value; - if (touch !== Touch.None) { - this.touch(item, touch); - } - } else { - item = { key, value, next: undefined, previous: undefined }; - switch (touch) { - case Touch.None: - this.addItemLast(item); - break; - case Touch.First: - this.addItemFirst(item); - break; - case Touch.Last: - this.addItemLast(item); - break; - default: - this.addItemLast(item); - break; - } - this._map.set(key, item); - this._size++; - } - } - - public delete(key: K): boolean { - const item = this._map.get(key); - if (!item) { - return false; - } - this._map.delete(key); - this.removeItem(item); - this._size--; - return true; - } - - public shift(): V | undefined { - if (!this._head && !this._tail) { - return undefined; - } - if (!this._head || !this._tail) { - throw new Error('Invalid list'); - } - const item = this._head; - this._map.delete(item.key); - this.removeItem(item); - this._size--; - return item.value; - } - - public forEach(callbackfn: (value: V, key: K, map: LinkedMap) => void, thisArg?: any): void { - let current = this._head; - while (current) { - if (thisArg) { - callbackfn.bind(thisArg)(current.value, current.key, this); - } else { - callbackfn(current.value, current.key, this); - } - current = current.next; - } - } - - public forEachReverse(callbackfn: (value: V, key: K, map: LinkedMap) => void, thisArg?: any): void { - let current = this._tail; - while (current) { - if (thisArg) { - callbackfn.bind(thisArg)(current.value, current.key, this); - } else { - callbackfn(current.value, current.key, this); - } - current = current.previous; - } - } - - public values(): V[] { - let result: V[] = []; - let current = this._head; - while (current) { - result.push(current.value); - current = current.next; - } - return result; - } - - public keys(): K[] { - let result: K[] = []; - let current = this._head; - while (current) { - result.push(current.key); - current = current.next; - } - return result; - } - - /* VS Code / Monaco editor runs on es5 which has no Symbol.iterator - public keys(): IterableIterator { - let current = this._head; - let iterator: IterableIterator = { - [Symbol.iterator]() { - return iterator; - }, - next():IteratorResult { - if (current) { - let result = { value: current.key, done: false }; - current = current.next; - return result; - } else { - return { value: undefined, done: true }; - } - } - }; - return iterator; - } - - public values(): IterableIterator { - let current = this._head; - let iterator: IterableIterator = { - [Symbol.iterator]() { - return iterator; - }, - next():IteratorResult { - if (current) { - let result = { value: current.value, done: false }; - current = current.next; - return result; - } else { - return { value: undefined, done: true }; - } - } - }; - return iterator; - } - */ - - private addItemFirst(item: Item): void { - // First time Insert - if (!this._head && !this._tail) { - this._tail = item; - } else if (!this._head) { - throw new Error('Invalid list'); - } else { - item.next = this._head; - this._head.previous = item; - } - this._head = item; - } - - private addItemLast(item: Item): void { - // First time Insert - if (!this._head && !this._tail) { - this._head = item; - } else if (!this._tail) { - throw new Error('Invalid list'); - } else { - item.previous = this._tail; - this._tail.next = item; - } - this._tail = item; - } - - private removeItem(item: Item): void { - if (item === this._head && item === this._tail) { - this._head = undefined; - this._tail = undefined; - } - else if (item === this._head) { - this._head = item.next; - } - else if (item === this._tail) { - this._tail = item.previous; - } - else { - const next = item.next; - const previous = item.previous; - if (!next || !previous) { - throw new Error('Invalid list'); - } - next.previous = previous; - previous.next = next; - } - } - - private touch(item: Item, touch: Touch): void { - if (!this._head || !this._tail) { - throw new Error('Invalid list'); - } - if ((touch !== Touch.First && touch !== Touch.Last)) { - return; - } - - if (touch === Touch.First) { - if (item === this._head) { - return; - } - - const next = item.next; - const previous = item.previous; - - // Unlink the item - if (item === this._tail) { - // previous must be defined since item was not head but is tail - // So there are more than on item in the map - previous!.next = undefined; - this._tail = previous; - } - else { - // Both next and previous are not undefined since item was neither head nor tail. - next!.previous = previous; - previous!.next = next; - } - - // Insert the node at head - item.previous = undefined; - item.next = this._head; - this._head.previous = item; - this._head = item; - } else if (touch === Touch.Last) { - if (item === this._tail) { - return; - } - - const next = item.next; - const previous = item.previous; - - // Unlink the item. - if (item === this._head) { - // next must be defined since item was not tail but is head - // So there are more than on item in the map - next!.previous = undefined; - this._head = next; - } else { - // Both next and previous are not undefined since item was neither head nor tail. - next!.previous = previous; - previous!.next = next; - } - item.next = undefined; - item.previous = this._tail; - this._tail.next = item; - this._tail = item; - } - } -} \ No newline at end of file diff --git a/src/vs/base/common/map.ts b/src/vs/base/common/map.ts index ba7089dd829..48357176b8a 100644 --- a/src/vs/base/common/map.ts +++ b/src/vs/base/common/map.ts @@ -469,4 +469,308 @@ export class ResourceMap { return key; } +} + +// We should fold BoundedMap and LinkedMap. See https://github.com/Microsoft/vscode/issues/28496 + +interface Item { + previous: Item | undefined; + next: Item | undefined; + key: K; + value: V; +} + +export namespace Touch { + export const None: 0 = 0; + export const First: 1 = 1; + export const Last: 2 = 2; +} + +export type Touch = 0 | 1 | 2; + +export class LinkedMap { + + private _map: Map>; + private _head: Item | undefined; + private _tail: Item | undefined; + private _size: number; + + constructor() { + this._map = new Map>(); + this._head = undefined; + this._tail = undefined; + this._size = 0; + } + + public clear(): void { + this._map.clear(); + this._head = undefined; + this._tail = undefined; + this._size = 0; + } + + public isEmpty(): boolean { + return !this._head && !this._tail; + } + + public get size(): number { + return this._size; + } + + public has(key: K): boolean { + return this._map.has(key); + } + + public get(key: K): V | undefined { + const item = this._map.get(key); + if (!item) { + return undefined; + } + return item.value; + } + + public set(key: K, value: V, touch: Touch = Touch.None): void { + let item = this._map.get(key); + if (item) { + item.value = value; + if (touch !== Touch.None) { + this.touch(item, touch); + } + } else { + item = { key, value, next: undefined, previous: undefined }; + switch (touch) { + case Touch.None: + this.addItemLast(item); + break; + case Touch.First: + this.addItemFirst(item); + break; + case Touch.Last: + this.addItemLast(item); + break; + default: + this.addItemLast(item); + break; + } + this._map.set(key, item); + this._size++; + } + } + + public delete(key: K): boolean { + const item = this._map.get(key); + if (!item) { + return false; + } + this._map.delete(key); + this.removeItem(item); + this._size--; + return true; + } + + public shift(): V | undefined { + if (!this._head && !this._tail) { + return undefined; + } + if (!this._head || !this._tail) { + throw new Error('Invalid list'); + } + const item = this._head; + this._map.delete(item.key); + this.removeItem(item); + this._size--; + return item.value; + } + + public forEach(callbackfn: (value: V, key: K, map: LinkedMap) => void, thisArg?: any): void { + let current = this._head; + while (current) { + if (thisArg) { + callbackfn.bind(thisArg)(current.value, current.key, this); + } else { + callbackfn(current.value, current.key, this); + } + current = current.next; + } + } + + public forEachReverse(callbackfn: (value: V, key: K, map: LinkedMap) => void, thisArg?: any): void { + let current = this._tail; + while (current) { + if (thisArg) { + callbackfn.bind(thisArg)(current.value, current.key, this); + } else { + callbackfn(current.value, current.key, this); + } + current = current.previous; + } + } + + public values(): V[] { + let result: V[] = []; + let current = this._head; + while (current) { + result.push(current.value); + current = current.next; + } + return result; + } + + public keys(): K[] { + let result: K[] = []; + let current = this._head; + while (current) { + result.push(current.key); + current = current.next; + } + return result; + } + + /* VS Code / Monaco editor runs on es5 which has no Symbol.iterator + public keys(): IterableIterator { + let current = this._head; + let iterator: IterableIterator = { + [Symbol.iterator]() { + return iterator; + }, + next():IteratorResult { + if (current) { + let result = { value: current.key, done: false }; + current = current.next; + return result; + } else { + return { value: undefined, done: true }; + } + } + }; + return iterator; + } + + public values(): IterableIterator { + let current = this._head; + let iterator: IterableIterator = { + [Symbol.iterator]() { + return iterator; + }, + next():IteratorResult { + if (current) { + let result = { value: current.value, done: false }; + current = current.next; + return result; + } else { + return { value: undefined, done: true }; + } + } + }; + return iterator; + } + */ + + private addItemFirst(item: Item): void { + // First time Insert + if (!this._head && !this._tail) { + this._tail = item; + } else if (!this._head) { + throw new Error('Invalid list'); + } else { + item.next = this._head; + this._head.previous = item; + } + this._head = item; + } + + private addItemLast(item: Item): void { + // First time Insert + if (!this._head && !this._tail) { + this._head = item; + } else if (!this._tail) { + throw new Error('Invalid list'); + } else { + item.previous = this._tail; + this._tail.next = item; + } + this._tail = item; + } + + private removeItem(item: Item): void { + if (item === this._head && item === this._tail) { + this._head = undefined; + this._tail = undefined; + } + else if (item === this._head) { + this._head = item.next; + } + else if (item === this._tail) { + this._tail = item.previous; + } + else { + const next = item.next; + const previous = item.previous; + if (!next || !previous) { + throw new Error('Invalid list'); + } + next.previous = previous; + previous.next = next; + } + } + + private touch(item: Item, touch: Touch): void { + if (!this._head || !this._tail) { + throw new Error('Invalid list'); + } + if ((touch !== Touch.First && touch !== Touch.Last)) { + return; + } + + if (touch === Touch.First) { + if (item === this._head) { + return; + } + + const next = item.next; + const previous = item.previous; + + // Unlink the item + if (item === this._tail) { + // previous must be defined since item was not head but is tail + // So there are more than on item in the map + previous!.next = undefined; + this._tail = previous; + } + else { + // Both next and previous are not undefined since item was neither head nor tail. + next!.previous = previous; + previous!.next = next; + } + + // Insert the node at head + item.previous = undefined; + item.next = this._head; + this._head.previous = item; + this._head = item; + } else if (touch === Touch.Last) { + if (item === this._tail) { + return; + } + + const next = item.next; + const previous = item.previous; + + // Unlink the item. + if (item === this._head) { + // next must be defined since item was not tail but is head + // So there are more than on item in the map + next!.previous = undefined; + this._head = next; + } else { + // Both next and previous are not undefined since item was neither head nor tail. + next!.previous = previous; + previous!.next = next; + } + item.next = undefined; + item.previous = this._tail; + this._tail.next = item; + this._tail = item; + } + } } \ No newline at end of file diff --git a/src/vs/workbench/parts/tasks/common/taskService.ts b/src/vs/workbench/parts/tasks/common/taskService.ts index 89ab0e6d57c..c235adc1e73 100644 --- a/src/vs/workbench/parts/tasks/common/taskService.ts +++ b/src/vs/workbench/parts/tasks/common/taskService.ts @@ -8,7 +8,7 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { Action } from 'vs/base/common/actions'; import { IEventEmitter } from 'vs/base/common/eventEmitter'; import { TerminateResponse } from 'vs/base/common/processes'; -import { LinkedMap } from 'vs/base/common/linkedMap'; +import { LinkedMap } from 'vs/base/common/map'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; import { Task, TaskSet } from 'vs/workbench/parts/tasks/common/tasks'; import { ITaskSummary, TaskEvent, TaskType } from 'vs/workbench/parts/tasks/common/taskSystem'; diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index 10b8f78aba5..905ed31a992 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -29,7 +29,7 @@ import { TerminateResponse, TerminateResponseCode } from 'vs/base/common/process import * as strings from 'vs/base/common/strings'; import { ValidationStatus, ValidationState } from 'vs/base/common/parsers'; import * as UUID from 'vs/base/common/uuid'; -import { LinkedMap, Touch } from 'vs/base/common/linkedMap'; +import { LinkedMap, Touch } from 'vs/base/common/map'; import { Registry } from 'vs/platform/platform'; import { ILifecycleService } from 'vs/platform/lifecycle/common/lifecycle'; -- GitLab From 9754a2107d4cdde92f88e87e5929814ec4b86991 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Mon, 12 Jun 2017 10:37:44 +0200 Subject: [PATCH 0708/1347] Revert "extract more functionality into IWorkspace" This reverts commit 25b4b172e402a86657104581acc1c925fd4e3cf2. --- .../browser/standalone/standaloneServices.ts | 8 +-- src/vs/platform/workspace/common/workspace.ts | 60 +++++-------------- .../workspace/test/common/testWorkspace.ts | 12 ++-- src/vs/workbench/electron-browser/main.ts | 20 +++---- src/vs/workbench/node/extensionHostMain.ts | 11 +--- .../terminalLinkHandler.test.ts | 9 +-- .../node/configurationService.ts | 19 +++--- .../node/configurationEditingService.test.ts | 10 ++-- .../test/node/configurationService.test.ts | 22 +++---- .../quickopen.perf.integrationTest.ts | 4 +- .../textsearch.perf.integrationTest.ts | 4 +- 11 files changed, 71 insertions(+), 108 deletions(-) diff --git a/src/vs/editor/browser/standalone/standaloneServices.ts b/src/vs/editor/browser/standalone/standaloneServices.ts index 68e9623baf1..550b5294605 100644 --- a/src/vs/editor/browser/standalone/standaloneServices.ts +++ b/src/vs/editor/browser/standalone/standaloneServices.ts @@ -22,7 +22,7 @@ import { IMessageService } from 'vs/platform/message/common/message'; import { IProgressService } from 'vs/platform/progress/common/progress'; import { IStorageService, NullStorageService } from 'vs/platform/storage/common/storage'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; -import { IWorkspaceContextService, WorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService, WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { ICodeEditorService } from 'vs/editor/common/services/codeEditorService'; import { IEditorWorkerService } from 'vs/editor/common/services/editorWorkerService'; import { EditorWorkerServiceImpl } from 'vs/editor/common/services/editorWorkerServiceImpl'; @@ -115,9 +115,9 @@ export module StaticServices { export const instantiationService = define(IInstantiationService, () => new InstantiationService(_serviceCollection, true)); - export const contextService = define(IWorkspaceContextService, () => new WorkspaceContextService(new Workspace( - URI.from({ scheme: 'inmemory', authority: 'model', path: '/' }) - ))); + export const contextService = define(IWorkspaceContextService, () => new WorkspaceContextService({ + resource: URI.from({ scheme: 'inmemory', authority: 'model', path: '/' }) + })); export const telemetryService = define(ITelemetryService, () => new StandaloneTelemetryService()); diff --git a/src/vs/platform/workspace/common/workspace.ts b/src/vs/platform/workspace/common/workspace.ts index eae7c42e20c..1218ddd4da8 100644 --- a/src/vs/platform/workspace/common/workspace.ts +++ b/src/vs/platform/workspace/common/workspace.ts @@ -65,26 +65,27 @@ export interface IWorkspace { name?: string; } -export class Workspace implements IWorkspace { +export class WorkspaceContextService implements IWorkspaceContextService { - constructor(private _resource: URI, private _uid?: number, private _name?: string) { - } + public _serviceBrand: any; - public get resource(): URI { - return this._resource; + private workspace: IWorkspace; + + constructor(workspace: IWorkspace) { + this.workspace = workspace; } - public get uid(): number { - return this._uid; + public getWorkspace(): IWorkspace { + return this.workspace; } - public get name(): string { - return this._name; + public hasWorkspace(): boolean { + return !!this.workspace; } public isInsideWorkspace(resource: URI): boolean { - if (resource) { - return isEqualOrParent(resource.fsPath, this._resource.fsPath, !isLinux /* ignorecase */); + if (resource && this.workspace) { + return isEqualOrParent(resource.fsPath, this.workspace.resource.fsPath, !isLinux /* ignorecase */); } return false; @@ -92,48 +93,17 @@ export class Workspace implements IWorkspace { public toWorkspaceRelativePath(resource: URI, toOSPath?: boolean): string { if (this.isInsideWorkspace(resource)) { - return paths.normalize(paths.relative(this._resource.fsPath, resource.fsPath), toOSPath); + return paths.normalize(paths.relative(this.workspace.resource.fsPath, resource.fsPath), toOSPath); } return null; } public toResource(workspaceRelativePath: string): URI { - if (typeof workspaceRelativePath === 'string') { - return URI.file(paths.join(this._resource.fsPath, workspaceRelativePath)); + if (typeof workspaceRelativePath === 'string' && this.workspace) { + return URI.file(paths.join(this.workspace.resource.fsPath, workspaceRelativePath)); } return null; } -} - -export class WorkspaceContextService implements IWorkspaceContextService { - - public _serviceBrand: any; - - private workspace: Workspace; - - constructor(workspace?: Workspace) { - this.workspace = workspace; - } - - public getWorkspace(): IWorkspace { - return this.workspace; - } - - public hasWorkspace(): boolean { - return !!this.workspace; - } - - public isInsideWorkspace(resource: URI): boolean { - return this.workspace ? this.workspace.isInsideWorkspace(resource) : false; - } - - public toWorkspaceRelativePath(resource: URI, toOSPath?: boolean): string { - return this.workspace ? this.workspace.toWorkspaceRelativePath(resource, toOSPath) : null; - } - - public toResource(workspaceRelativePath: string): URI { - return this.workspace ? this.workspace.toResource(workspaceRelativePath) : null; - } } \ No newline at end of file diff --git a/src/vs/platform/workspace/test/common/testWorkspace.ts b/src/vs/platform/workspace/test/common/testWorkspace.ts index 18926c9330d..237d8529523 100644 --- a/src/vs/platform/workspace/test/common/testWorkspace.ts +++ b/src/vs/platform/workspace/test/common/testWorkspace.ts @@ -3,11 +3,11 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import { Workspace } from 'vs/platform/workspace/common/workspace'; +import { IWorkspace } from 'vs/platform/workspace/common/workspace'; import URI from 'vs/base/common/uri'; -export const TestWorkspace = new Workspace( - URI.file('C:\\testWorkspace'), - Date.now(), - 'Test Workspace' -); +export const TestWorkspace: IWorkspace = { + resource: URI.file('C:\\testWorkspace'), + name: 'Test Workspace', + uid: Date.now() +}; diff --git a/src/vs/workbench/electron-browser/main.ts b/src/vs/workbench/electron-browser/main.ts index b8bfbe51ce6..b20a6fd422a 100644 --- a/src/vs/workbench/electron-browser/main.ts +++ b/src/vs/workbench/electron-browser/main.ts @@ -18,7 +18,7 @@ import paths = require('vs/base/common/paths'); import uri from 'vs/base/common/uri'; import strings = require('vs/base/common/strings'); import { IResourceInput } from 'vs/platform/editor/common/editor'; -import { WorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; +import { IWorkspace, WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { WorkspaceConfigurationService } from 'vs/workbench/services/configuration/node/configurationService'; import { ParsedArgs } from 'vs/platform/environment/common/environment'; import { realpath, stat } from 'vs/base/node/pfs'; @@ -116,7 +116,7 @@ function toInputs(paths: IPath[], isUntitledFile?: boolean): IResourceInput[] { }); } -function getWorkspace(workspacePath: string): TPromise { +function getWorkspace(workspacePath: string): TPromise { if (!workspacePath) { return TPromise.as(null); } @@ -135,23 +135,23 @@ function getWorkspace(workspacePath: string): TPromise { const folderName = path.basename(realWorkspacePath) || realWorkspacePath; return stat(realWorkspacePath).then(folderStat => { - return new Workspace( - workspaceResource, - platform.isLinux ? folderStat.ino : folderStat.birthtime.getTime(), - folderName // On Linux, birthtime is ctime, so we cannot use it! We use the ino instead! - ); + return { + 'resource': workspaceResource, + 'name': folderName, + 'uid': platform.isLinux ? folderStat.ino : folderStat.birthtime.getTime() // On Linux, birthtime is ctime, so we cannot use it! We use the ino instead! + }; }); - }, error => { + }, (error) => { errors.onUnexpectedError(error); return null; // treat invalid paths as empty workspace }); } -function openWorkbench(environment: IWindowConfiguration, workspace: Workspace, options: IOptions): TPromise { +function openWorkbench(environment: IWindowConfiguration, workspace: IWorkspace, options: IOptions): TPromise { const environmentService = new EnvironmentService(environment, environment.execPath); const contextService = new WorkspaceContextService(workspace); - const configurationService = new WorkspaceConfigurationService(environmentService, workspace); + const configurationService = new WorkspaceConfigurationService(contextService, environmentService); const timerService = new TimerService((window).MonacoEnvironment.timers as IInitData, !contextService.hasWorkspace()); // Since the configuration service is one of the core services that is used in so many places, we initialize it diff --git a/src/vs/workbench/node/extensionHostMain.ts b/src/vs/workbench/node/extensionHostMain.ts index abb6f76e6c8..fd41b0c29fe 100644 --- a/src/vs/workbench/node/extensionHostMain.ts +++ b/src/vs/workbench/node/extensionHostMain.ts @@ -15,7 +15,7 @@ import { ExtHostThreadService } from 'vs/workbench/services/thread/common/extHos import { QueryType, ISearchQuery } from 'vs/platform/search/common/search'; import { DiskSearch } from 'vs/workbench/services/search/node/searchService'; import { RemoteTelemetryService } from 'vs/workbench/api/node/extHostTelemetry'; -import { IWorkspaceContextService, WorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService, WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { IInitData, IEnvironment, MainContext } from 'vs/workbench/api/node/extHost.protocol'; import * as errors from 'vs/base/common/errors'; @@ -43,14 +43,7 @@ export class ExtensionHostMain { constructor(remoteCom: IRemoteCom, initData: IInitData) { // services this._environment = initData.environment; - - const workspaceRaw = initData.contextService.workspace; - let workspace: Workspace; - if (workspaceRaw) { - workspace = new Workspace(workspaceRaw.resource, workspaceRaw.uid, workspaceRaw.name); - } - this._contextService = new WorkspaceContextService(workspace); - + this._contextService = new WorkspaceContextService(initData.contextService.workspace); const threadService = new ExtHostThreadService(remoteCom); const telemetryService = new RemoteTelemetryService('pluginHostTelemetry', threadService); this._extensionService = new ExtHostExtensionService(initData, threadService, telemetryService, this._contextService); diff --git a/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts b/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts index d61de282fd4..a491d6153d1 100644 --- a/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts +++ b/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts @@ -8,7 +8,7 @@ import * as assert from 'assert'; import { Platform } from 'vs/base/common/platform'; import { TerminalLinkHandler, LineColumnInfo } from 'vs/workbench/parts/terminal/electron-browser/terminalLinkHandler'; -import { WorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; +import { IWorkspace, WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import URI from 'vs/base/common/uri'; import * as strings from 'vs/base/common/strings'; import * as path from 'path'; @@ -44,9 +44,10 @@ interface LinkFormatInfo { column?: string; } -class TestWorkspace extends Workspace { - constructor(private basePath: string) { - super(new TestURI(basePath)); +class TestWorkspace implements IWorkspace { + resource: URI; + constructor(basePath: string) { + this.resource = new TestURI(basePath); } } diff --git a/src/vs/workbench/services/configuration/node/configurationService.ts b/src/vs/workbench/services/configuration/node/configurationService.ts index 9ea368f587b..b0537b9a12c 100644 --- a/src/vs/workbench/services/configuration/node/configurationService.ts +++ b/src/vs/workbench/services/configuration/node/configurationService.ts @@ -12,6 +12,7 @@ import extfs = require('vs/base/node/extfs'); import objects = require('vs/base/common/objects'); import { RunOnceScheduler } from 'vs/base/common/async'; import collections = require('vs/base/common/collections'); +import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { IDisposable, Disposable } from 'vs/base/common/lifecycle'; import { readFile } from 'vs/base/node/pfs'; @@ -23,7 +24,7 @@ import { ConfigurationService as BaseConfigurationService } from 'vs/platform/co import { IWorkspaceConfigurationValues, IWorkspaceConfigurationService, IWorkspaceConfigurationValue, WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME, WORKSPACE_STANDALONE_CONFIGURATIONS, WORKSPACE_CONFIG_DEFAULT_PATH } from 'vs/workbench/services/configuration/common/configuration'; import { FileChangeType, FileChangesEvent, isEqual } from 'vs/platform/files/common/files'; import Event, { Emitter } from 'vs/base/common/event'; -import { Workspace } from "vs/platform/workspace/common/workspace"; + interface IStat { resource: uri; @@ -61,8 +62,8 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp private reloadConfigurationScheduler: RunOnceScheduler; constructor( - private environmentService: IEnvironmentService, - private workspace?: Workspace, + @IWorkspaceContextService private contextService: IWorkspaceContextService, + @IEnvironmentService environmentService: IEnvironmentService, private workspaceSettingsRootFolder: string = WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME ) { super(); @@ -215,13 +216,13 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp private loadWorkspaceConfigFiles(): TPromise<{ [relativeWorkspacePath: string]: IConfigModel }> { // Return early if we don't have a workspace - if (!this.workspace) { + if (!this.contextService.hasWorkspace()) { return TPromise.as(Object.create(null)); } // once: when invoked for the first time we fetch json files that contribute settings if (!this.bulkFetchFromWorkspacePromise) { - this.bulkFetchFromWorkspacePromise = resolveStat(this.workspace.toResource(this.workspaceSettingsRootFolder)).then(stat => { + this.bulkFetchFromWorkspacePromise = resolveStat(this.contextService.toResource(this.workspaceSettingsRootFolder)).then(stat => { if (!stat.isDirectory) { return TPromise.as([]); } @@ -232,11 +233,11 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp return false; // only JSON files } - return this.isWorkspaceConfigurationFile(this.workspace.toWorkspaceRelativePath(stat.resource)); // only workspace config files + return this.isWorkspaceConfigurationFile(this.contextService.toWorkspaceRelativePath(stat.resource)); // only workspace config files }).map(stat => stat.resource)); }, err => [] /* never fail this call */) .then((contents: IContent[]) => { - contents.forEach(content => this.workspaceFilePathToConfiguration[this.workspace.toWorkspaceRelativePath(content.resource)] = TPromise.as(this.createConfigModel(content))); + contents.forEach(content => this.workspaceFilePathToConfiguration[this.contextService.toWorkspaceRelativePath(content.resource)] = TPromise.as(this.createConfigModel(content))); }, errors.onUnexpectedError); } @@ -258,7 +259,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp continue; // only JSON files or the actual settings folder } - const workspacePath = this.workspace.toWorkspaceRelativePath(resource); + const workspacePath = this.contextService.toWorkspaceRelativePath(resource); if (!workspacePath) { continue; // event is not inside workspace } @@ -294,7 +295,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } private createConfigModel(content: IContent): IConfigModel { - const path = this.workspace.toWorkspaceRelativePath(content.resource); + const path = this.contextService.toWorkspaceRelativePath(content.resource); if (path === WORKSPACE_CONFIG_DEFAULT_PATH) { return new WorkspaceSettingsConfigModel(content.value, content.resource.toString()); } else { diff --git a/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts b/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts index df423a3c094..a444ccfb9cf 100644 --- a/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts +++ b/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts @@ -15,7 +15,7 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { Registry } from 'vs/platform/platform'; import { ParsedArgs, IEnvironmentService } from 'vs/platform/environment/common/environment'; import { parseArgs } from 'vs/platform/environment/node/argv'; -import { WorkspaceContextService, IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; +import { WorkspaceContextService, IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { EnvironmentService } from 'vs/platform/environment/node/environmentService'; import extfs = require('vs/base/node/extfs'); import { TestTextFileService, TestEditorGroupService, TestLifecycleService, TestBackupFileService } from 'vs/workbench/test/workbenchTestServices'; @@ -113,11 +113,9 @@ suite('ConfigurationEditingService', () => { clearServices(); instantiationService = new TestInstantiationService(); - const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); - instantiationService.stub(IEnvironmentService, environmentService); - const workspace = noWorkspace ? null : new Workspace(URI.file(workspaceDir)); - instantiationService.stub(IWorkspaceContextService, new WorkspaceContextService(workspace)); - const configurationService = new WorkspaceConfigurationService(environmentService, workspace); + instantiationService.stub(IEnvironmentService, new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile)); + instantiationService.stub(IWorkspaceContextService, new WorkspaceContextService(noWorkspace ? null : { resource: URI.file(workspaceDir) })); + const configurationService = instantiationService.createInstance(WorkspaceConfigurationService); instantiationService.stub(IConfigurationService, configurationService); instantiationService.stub(ILifecycleService, new TestLifecycleService()); instantiationService.stub(IEditorGroupService, new TestEditorGroupService()); diff --git a/src/vs/workbench/services/configuration/test/node/configurationService.test.ts b/src/vs/workbench/services/configuration/test/node/configurationService.test.ts index c61238061d7..3d202425b4a 100644 --- a/src/vs/workbench/services/configuration/test/node/configurationService.test.ts +++ b/src/vs/workbench/services/configuration/test/node/configurationService.test.ts @@ -13,7 +13,7 @@ import * as sinon from 'sinon'; import { TPromise } from 'vs/base/common/winjs.base'; import { Registry } from 'vs/platform/platform'; import { ParsedArgs } from 'vs/platform/environment/common/environment'; -import { Workspace } from 'vs/platform/workspace/common/workspace'; +import { WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { EnvironmentService } from 'vs/platform/environment/node/environmentService'; import { parseArgs } from 'vs/platform/environment/node/argv'; import extfs = require('vs/base/node/extfs'); @@ -47,9 +47,9 @@ suite('WorkspaceConfigurationService - Node', () => { } function createService(workspaceDir: string, globalSettingsFile: string): TPromise { - const workspace = new Workspace(URI.file(workspaceDir)); + const workspaceContextService = new WorkspaceContextService({ resource: URI.file(workspaceDir) }); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); - const service = new WorkspaceConfigurationService(environmentService, workspace); + const service = new WorkspaceConfigurationService(workspaceContextService, environmentService); return service.initialize().then(() => service); } @@ -204,9 +204,9 @@ suite('WorkspaceConfigurationService - Node', () => { test('workspace change triggers event', (done: () => void) => { createWorkspace((workspaceDir, globalSettingsFile, cleanUp) => { - const workspace = new Workspace(URI.file(workspaceDir)); + const workspaceContextService = new WorkspaceContextService({ resource: URI.file(workspaceDir) }); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); - const service = new WorkspaceConfigurationService(environmentService, workspace); + const service = new WorkspaceConfigurationService(workspaceContextService, environmentService); return service.initialize().then(() => { service.onDidUpdateConfiguration(event => { @@ -230,9 +230,9 @@ suite('WorkspaceConfigurationService - Node', () => { test('workspace reload should triggers event if content changed', (done: () => void) => { createWorkspace((workspaceDir, globalSettingsFile, cleanUp) => { - const workspace = new Workspace(URI.file(workspaceDir)); + const workspaceContextService = new WorkspaceContextService({ resource: URI.file(workspaceDir) }); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); - const service = new WorkspaceConfigurationService(environmentService, workspace); + const service = new WorkspaceConfigurationService(workspaceContextService, environmentService); return service.initialize().then(() => { const settingsFile = path.join(workspaceDir, '.vscode', 'settings.json'); @@ -255,9 +255,9 @@ suite('WorkspaceConfigurationService - Node', () => { test('workspace reload should not trigger event if nothing changed', (done: () => void) => { createWorkspace((workspaceDir, globalSettingsFile, cleanUp) => { - const workspace = new Workspace(URI.file(workspaceDir)); + const workspaceContextService = new WorkspaceContextService({ resource: URI.file(workspaceDir) }); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); - const service = new WorkspaceConfigurationService(environmentService, workspace); + const service = new WorkspaceConfigurationService(workspaceContextService, environmentService); return service.initialize().then(() => { const settingsFile = path.join(workspaceDir, '.vscode', 'settings.json'); @@ -280,9 +280,9 @@ suite('WorkspaceConfigurationService - Node', () => { test('workspace reload should not trigger event if there is no model', (done: () => void) => { createWorkspace((workspaceDir, globalSettingsFile, cleanUp) => { - const workspace = new Workspace(URI.file(workspaceDir)); + const workspaceContextService = new WorkspaceContextService({ resource: URI.file(workspaceDir) }); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); - const service = new WorkspaceConfigurationService(environmentService, workspace); + const service = new WorkspaceConfigurationService(workspaceContextService, environmentService); return service.initialize().then(() => { const target = sinon.stub(); diff --git a/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts b/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts index dfd2576d1d4..ad4fdee36f5 100644 --- a/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts +++ b/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts @@ -7,7 +7,7 @@ import 'vs/workbench/parts/search/browser/search.contribution'; // load contributions import * as assert from 'assert'; -import { WorkspaceContextService, IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; +import { WorkspaceContextService, IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { createSyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { ISearchService } from 'vs/platform/search/common/search'; @@ -73,7 +73,7 @@ suite('QuickOpen performance (integration)', () => { [ITelemetryService, telemetryService], [IConfigurationService, new SimpleConfigurationService()], [IModelService, new ModelServiceImpl(null, configurationService)], - [IWorkspaceContextService, new WorkspaceContextService(new Workspace(URI.file(testWorkspacePath)))], + [IWorkspaceContextService, new WorkspaceContextService({ resource: URI.file(testWorkspacePath) })], [IWorkbenchEditorService, new TestEditorService()], [IEditorGroupService, new TestEditorGroupService()], [IEnvironmentService, TestEnvironmentService], diff --git a/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts b/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts index 7d1bb6b1139..861ff475677 100644 --- a/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts +++ b/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts @@ -8,7 +8,7 @@ import 'vs/workbench/parts/search/browser/search.contribution'; // load contributions import * as assert from 'assert'; import * as fs from 'fs'; -import { WorkspaceContextService, IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; +import { WorkspaceContextService, IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { createSyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { ISearchService, IQueryOptions } from 'vs/platform/search/common/search'; @@ -62,7 +62,7 @@ suite('TextSearch performance (integration)', () => { [ITelemetryService, telemetryService], [IConfigurationService, new SimpleConfigurationService()], [IModelService, new ModelServiceImpl(null, configurationService)], - [IWorkspaceContextService, new WorkspaceContextService(new Workspace(URI.file(testWorkspacePath)))], + [IWorkspaceContextService, new WorkspaceContextService({ resource: URI.file(testWorkspacePath) })], [IWorkbenchEditorService, new TestEditorService()], [IEditorGroupService, new TestEditorGroupService()], [IEnvironmentService, TestEnvironmentService], -- GitLab From dabe5d0cc4c037e71c7f586a0a8f3b3c75fe9d3e Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Mon, 12 Jun 2017 10:51:34 +0200 Subject: [PATCH 0709/1347] extract more functionality into IWorkspace --- .../browser/standalone/standaloneServices.ts | 8 +-- src/vs/platform/workspace/common/workspace.ts | 64 ++++++++++++++----- .../workspace/test/common/testWorkspace.ts | 12 ++-- src/vs/workbench/electron-browser/main.ts | 20 +++--- src/vs/workbench/node/extensionHostMain.ts | 11 +++- .../terminalLinkHandler.test.ts | 9 ++- .../node/configurationService.ts | 19 +++--- .../node/configurationEditingService.test.ts | 10 +-- .../test/node/configurationService.test.ts | 22 +++---- .../quickopen.perf.integrationTest.ts | 4 +- .../textsearch.perf.integrationTest.ts | 4 +- 11 files changed, 112 insertions(+), 71 deletions(-) diff --git a/src/vs/editor/browser/standalone/standaloneServices.ts b/src/vs/editor/browser/standalone/standaloneServices.ts index 550b5294605..68e9623baf1 100644 --- a/src/vs/editor/browser/standalone/standaloneServices.ts +++ b/src/vs/editor/browser/standalone/standaloneServices.ts @@ -22,7 +22,7 @@ import { IMessageService } from 'vs/platform/message/common/message'; import { IProgressService } from 'vs/platform/progress/common/progress'; import { IStorageService, NullStorageService } from 'vs/platform/storage/common/storage'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; -import { IWorkspaceContextService, WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService, WorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import { ICodeEditorService } from 'vs/editor/common/services/codeEditorService'; import { IEditorWorkerService } from 'vs/editor/common/services/editorWorkerService'; import { EditorWorkerServiceImpl } from 'vs/editor/common/services/editorWorkerServiceImpl'; @@ -115,9 +115,9 @@ export module StaticServices { export const instantiationService = define(IInstantiationService, () => new InstantiationService(_serviceCollection, true)); - export const contextService = define(IWorkspaceContextService, () => new WorkspaceContextService({ - resource: URI.from({ scheme: 'inmemory', authority: 'model', path: '/' }) - })); + export const contextService = define(IWorkspaceContextService, () => new WorkspaceContextService(new Workspace( + URI.from({ scheme: 'inmemory', authority: 'model', path: '/' }) + ))); export const telemetryService = define(ITelemetryService, () => new StandaloneTelemetryService()); diff --git a/src/vs/platform/workspace/common/workspace.ts b/src/vs/platform/workspace/common/workspace.ts index 1218ddd4da8..a1a0480997d 100644 --- a/src/vs/platform/workspace/common/workspace.ts +++ b/src/vs/platform/workspace/common/workspace.ts @@ -65,27 +65,26 @@ export interface IWorkspace { name?: string; } -export class WorkspaceContextService implements IWorkspaceContextService { - - public _serviceBrand: any; +export class Workspace implements IWorkspace { - private workspace: IWorkspace; + constructor(private _resource: URI, private _uid?: number, private _name?: string) { + } - constructor(workspace: IWorkspace) { - this.workspace = workspace; + public get resource(): URI { + return this._resource; } - public getWorkspace(): IWorkspace { - return this.workspace; + public get uid(): number { + return this._uid; } - public hasWorkspace(): boolean { - return !!this.workspace; + public get name(): string { + return this._name; } public isInsideWorkspace(resource: URI): boolean { - if (resource && this.workspace) { - return isEqualOrParent(resource.fsPath, this.workspace.resource.fsPath, !isLinux /* ignorecase */); + if (resource) { + return isEqualOrParent(resource.fsPath, this._resource.fsPath, !isLinux /* ignorecase */); } return false; @@ -93,17 +92,52 @@ export class WorkspaceContextService implements IWorkspaceContextService { public toWorkspaceRelativePath(resource: URI, toOSPath?: boolean): string { if (this.isInsideWorkspace(resource)) { - return paths.normalize(paths.relative(this.workspace.resource.fsPath, resource.fsPath), toOSPath); + return paths.normalize(paths.relative(this._resource.fsPath, resource.fsPath), toOSPath); } return null; } public toResource(workspaceRelativePath: string): URI { - if (typeof workspaceRelativePath === 'string' && this.workspace) { - return URI.file(paths.join(this.workspace.resource.fsPath, workspaceRelativePath)); + if (typeof workspaceRelativePath === 'string') { + return URI.file(paths.join(this._resource.fsPath, workspaceRelativePath)); } return null; } + + public toJSON() { + return { resource: this._resource, uid: this._uid, name: this._name }; + } +} + +export class WorkspaceContextService implements IWorkspaceContextService { + + public _serviceBrand: any; + + private workspace: Workspace; + + constructor(workspace?: Workspace) { + this.workspace = workspace; + } + + public getWorkspace(): IWorkspace { + return this.workspace; + } + + public hasWorkspace(): boolean { + return !!this.workspace; + } + + public isInsideWorkspace(resource: URI): boolean { + return this.workspace ? this.workspace.isInsideWorkspace(resource) : false; + } + + public toWorkspaceRelativePath(resource: URI, toOSPath?: boolean): string { + return this.workspace ? this.workspace.toWorkspaceRelativePath(resource, toOSPath) : null; + } + + public toResource(workspaceRelativePath: string): URI { + return this.workspace ? this.workspace.toResource(workspaceRelativePath) : null; + } } \ No newline at end of file diff --git a/src/vs/platform/workspace/test/common/testWorkspace.ts b/src/vs/platform/workspace/test/common/testWorkspace.ts index 237d8529523..18926c9330d 100644 --- a/src/vs/platform/workspace/test/common/testWorkspace.ts +++ b/src/vs/platform/workspace/test/common/testWorkspace.ts @@ -3,11 +3,11 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import { IWorkspace } from 'vs/platform/workspace/common/workspace'; +import { Workspace } from 'vs/platform/workspace/common/workspace'; import URI from 'vs/base/common/uri'; -export const TestWorkspace: IWorkspace = { - resource: URI.file('C:\\testWorkspace'), - name: 'Test Workspace', - uid: Date.now() -}; +export const TestWorkspace = new Workspace( + URI.file('C:\\testWorkspace'), + Date.now(), + 'Test Workspace' +); diff --git a/src/vs/workbench/electron-browser/main.ts b/src/vs/workbench/electron-browser/main.ts index b20a6fd422a..b8bfbe51ce6 100644 --- a/src/vs/workbench/electron-browser/main.ts +++ b/src/vs/workbench/electron-browser/main.ts @@ -18,7 +18,7 @@ import paths = require('vs/base/common/paths'); import uri from 'vs/base/common/uri'; import strings = require('vs/base/common/strings'); import { IResourceInput } from 'vs/platform/editor/common/editor'; -import { IWorkspace, WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { WorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import { WorkspaceConfigurationService } from 'vs/workbench/services/configuration/node/configurationService'; import { ParsedArgs } from 'vs/platform/environment/common/environment'; import { realpath, stat } from 'vs/base/node/pfs'; @@ -116,7 +116,7 @@ function toInputs(paths: IPath[], isUntitledFile?: boolean): IResourceInput[] { }); } -function getWorkspace(workspacePath: string): TPromise { +function getWorkspace(workspacePath: string): TPromise { if (!workspacePath) { return TPromise.as(null); } @@ -135,23 +135,23 @@ function getWorkspace(workspacePath: string): TPromise { const folderName = path.basename(realWorkspacePath) || realWorkspacePath; return stat(realWorkspacePath).then(folderStat => { - return { - 'resource': workspaceResource, - 'name': folderName, - 'uid': platform.isLinux ? folderStat.ino : folderStat.birthtime.getTime() // On Linux, birthtime is ctime, so we cannot use it! We use the ino instead! - }; + return new Workspace( + workspaceResource, + platform.isLinux ? folderStat.ino : folderStat.birthtime.getTime(), + folderName // On Linux, birthtime is ctime, so we cannot use it! We use the ino instead! + ); }); - }, (error) => { + }, error => { errors.onUnexpectedError(error); return null; // treat invalid paths as empty workspace }); } -function openWorkbench(environment: IWindowConfiguration, workspace: IWorkspace, options: IOptions): TPromise { +function openWorkbench(environment: IWindowConfiguration, workspace: Workspace, options: IOptions): TPromise { const environmentService = new EnvironmentService(environment, environment.execPath); const contextService = new WorkspaceContextService(workspace); - const configurationService = new WorkspaceConfigurationService(contextService, environmentService); + const configurationService = new WorkspaceConfigurationService(environmentService, workspace); const timerService = new TimerService((window).MonacoEnvironment.timers as IInitData, !contextService.hasWorkspace()); // Since the configuration service is one of the core services that is used in so many places, we initialize it diff --git a/src/vs/workbench/node/extensionHostMain.ts b/src/vs/workbench/node/extensionHostMain.ts index fd41b0c29fe..abb6f76e6c8 100644 --- a/src/vs/workbench/node/extensionHostMain.ts +++ b/src/vs/workbench/node/extensionHostMain.ts @@ -15,7 +15,7 @@ import { ExtHostThreadService } from 'vs/workbench/services/thread/common/extHos import { QueryType, ISearchQuery } from 'vs/platform/search/common/search'; import { DiskSearch } from 'vs/workbench/services/search/node/searchService'; import { RemoteTelemetryService } from 'vs/workbench/api/node/extHostTelemetry'; -import { IWorkspaceContextService, WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService, WorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import { IInitData, IEnvironment, MainContext } from 'vs/workbench/api/node/extHost.protocol'; import * as errors from 'vs/base/common/errors'; @@ -43,7 +43,14 @@ export class ExtensionHostMain { constructor(remoteCom: IRemoteCom, initData: IInitData) { // services this._environment = initData.environment; - this._contextService = new WorkspaceContextService(initData.contextService.workspace); + + const workspaceRaw = initData.contextService.workspace; + let workspace: Workspace; + if (workspaceRaw) { + workspace = new Workspace(workspaceRaw.resource, workspaceRaw.uid, workspaceRaw.name); + } + this._contextService = new WorkspaceContextService(workspace); + const threadService = new ExtHostThreadService(remoteCom); const telemetryService = new RemoteTelemetryService('pluginHostTelemetry', threadService); this._extensionService = new ExtHostExtensionService(initData, threadService, telemetryService, this._contextService); diff --git a/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts b/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts index a491d6153d1..d61de282fd4 100644 --- a/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts +++ b/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts @@ -8,7 +8,7 @@ import * as assert from 'assert'; import { Platform } from 'vs/base/common/platform'; import { TerminalLinkHandler, LineColumnInfo } from 'vs/workbench/parts/terminal/electron-browser/terminalLinkHandler'; -import { IWorkspace, WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { WorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import URI from 'vs/base/common/uri'; import * as strings from 'vs/base/common/strings'; import * as path from 'path'; @@ -44,10 +44,9 @@ interface LinkFormatInfo { column?: string; } -class TestWorkspace implements IWorkspace { - resource: URI; - constructor(basePath: string) { - this.resource = new TestURI(basePath); +class TestWorkspace extends Workspace { + constructor(private basePath: string) { + super(new TestURI(basePath)); } } diff --git a/src/vs/workbench/services/configuration/node/configurationService.ts b/src/vs/workbench/services/configuration/node/configurationService.ts index b0537b9a12c..9ea368f587b 100644 --- a/src/vs/workbench/services/configuration/node/configurationService.ts +++ b/src/vs/workbench/services/configuration/node/configurationService.ts @@ -12,7 +12,6 @@ import extfs = require('vs/base/node/extfs'); import objects = require('vs/base/common/objects'); import { RunOnceScheduler } from 'vs/base/common/async'; import collections = require('vs/base/common/collections'); -import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { IDisposable, Disposable } from 'vs/base/common/lifecycle'; import { readFile } from 'vs/base/node/pfs'; @@ -24,7 +23,7 @@ import { ConfigurationService as BaseConfigurationService } from 'vs/platform/co import { IWorkspaceConfigurationValues, IWorkspaceConfigurationService, IWorkspaceConfigurationValue, WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME, WORKSPACE_STANDALONE_CONFIGURATIONS, WORKSPACE_CONFIG_DEFAULT_PATH } from 'vs/workbench/services/configuration/common/configuration'; import { FileChangeType, FileChangesEvent, isEqual } from 'vs/platform/files/common/files'; import Event, { Emitter } from 'vs/base/common/event'; - +import { Workspace } from "vs/platform/workspace/common/workspace"; interface IStat { resource: uri; @@ -62,8 +61,8 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp private reloadConfigurationScheduler: RunOnceScheduler; constructor( - @IWorkspaceContextService private contextService: IWorkspaceContextService, - @IEnvironmentService environmentService: IEnvironmentService, + private environmentService: IEnvironmentService, + private workspace?: Workspace, private workspaceSettingsRootFolder: string = WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME ) { super(); @@ -216,13 +215,13 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp private loadWorkspaceConfigFiles(): TPromise<{ [relativeWorkspacePath: string]: IConfigModel }> { // Return early if we don't have a workspace - if (!this.contextService.hasWorkspace()) { + if (!this.workspace) { return TPromise.as(Object.create(null)); } // once: when invoked for the first time we fetch json files that contribute settings if (!this.bulkFetchFromWorkspacePromise) { - this.bulkFetchFromWorkspacePromise = resolveStat(this.contextService.toResource(this.workspaceSettingsRootFolder)).then(stat => { + this.bulkFetchFromWorkspacePromise = resolveStat(this.workspace.toResource(this.workspaceSettingsRootFolder)).then(stat => { if (!stat.isDirectory) { return TPromise.as([]); } @@ -233,11 +232,11 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp return false; // only JSON files } - return this.isWorkspaceConfigurationFile(this.contextService.toWorkspaceRelativePath(stat.resource)); // only workspace config files + return this.isWorkspaceConfigurationFile(this.workspace.toWorkspaceRelativePath(stat.resource)); // only workspace config files }).map(stat => stat.resource)); }, err => [] /* never fail this call */) .then((contents: IContent[]) => { - contents.forEach(content => this.workspaceFilePathToConfiguration[this.contextService.toWorkspaceRelativePath(content.resource)] = TPromise.as(this.createConfigModel(content))); + contents.forEach(content => this.workspaceFilePathToConfiguration[this.workspace.toWorkspaceRelativePath(content.resource)] = TPromise.as(this.createConfigModel(content))); }, errors.onUnexpectedError); } @@ -259,7 +258,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp continue; // only JSON files or the actual settings folder } - const workspacePath = this.contextService.toWorkspaceRelativePath(resource); + const workspacePath = this.workspace.toWorkspaceRelativePath(resource); if (!workspacePath) { continue; // event is not inside workspace } @@ -295,7 +294,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } private createConfigModel(content: IContent): IConfigModel { - const path = this.contextService.toWorkspaceRelativePath(content.resource); + const path = this.workspace.toWorkspaceRelativePath(content.resource); if (path === WORKSPACE_CONFIG_DEFAULT_PATH) { return new WorkspaceSettingsConfigModel(content.value, content.resource.toString()); } else { diff --git a/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts b/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts index a444ccfb9cf..df423a3c094 100644 --- a/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts +++ b/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts @@ -15,7 +15,7 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { Registry } from 'vs/platform/platform'; import { ParsedArgs, IEnvironmentService } from 'vs/platform/environment/common/environment'; import { parseArgs } from 'vs/platform/environment/node/argv'; -import { WorkspaceContextService, IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { WorkspaceContextService, IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import { EnvironmentService } from 'vs/platform/environment/node/environmentService'; import extfs = require('vs/base/node/extfs'); import { TestTextFileService, TestEditorGroupService, TestLifecycleService, TestBackupFileService } from 'vs/workbench/test/workbenchTestServices'; @@ -113,9 +113,11 @@ suite('ConfigurationEditingService', () => { clearServices(); instantiationService = new TestInstantiationService(); - instantiationService.stub(IEnvironmentService, new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile)); - instantiationService.stub(IWorkspaceContextService, new WorkspaceContextService(noWorkspace ? null : { resource: URI.file(workspaceDir) })); - const configurationService = instantiationService.createInstance(WorkspaceConfigurationService); + const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); + instantiationService.stub(IEnvironmentService, environmentService); + const workspace = noWorkspace ? null : new Workspace(URI.file(workspaceDir)); + instantiationService.stub(IWorkspaceContextService, new WorkspaceContextService(workspace)); + const configurationService = new WorkspaceConfigurationService(environmentService, workspace); instantiationService.stub(IConfigurationService, configurationService); instantiationService.stub(ILifecycleService, new TestLifecycleService()); instantiationService.stub(IEditorGroupService, new TestEditorGroupService()); diff --git a/src/vs/workbench/services/configuration/test/node/configurationService.test.ts b/src/vs/workbench/services/configuration/test/node/configurationService.test.ts index 3d202425b4a..c61238061d7 100644 --- a/src/vs/workbench/services/configuration/test/node/configurationService.test.ts +++ b/src/vs/workbench/services/configuration/test/node/configurationService.test.ts @@ -13,7 +13,7 @@ import * as sinon from 'sinon'; import { TPromise } from 'vs/base/common/winjs.base'; import { Registry } from 'vs/platform/platform'; import { ParsedArgs } from 'vs/platform/environment/common/environment'; -import { WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { Workspace } from 'vs/platform/workspace/common/workspace'; import { EnvironmentService } from 'vs/platform/environment/node/environmentService'; import { parseArgs } from 'vs/platform/environment/node/argv'; import extfs = require('vs/base/node/extfs'); @@ -47,9 +47,9 @@ suite('WorkspaceConfigurationService - Node', () => { } function createService(workspaceDir: string, globalSettingsFile: string): TPromise { - const workspaceContextService = new WorkspaceContextService({ resource: URI.file(workspaceDir) }); + const workspace = new Workspace(URI.file(workspaceDir)); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); - const service = new WorkspaceConfigurationService(workspaceContextService, environmentService); + const service = new WorkspaceConfigurationService(environmentService, workspace); return service.initialize().then(() => service); } @@ -204,9 +204,9 @@ suite('WorkspaceConfigurationService - Node', () => { test('workspace change triggers event', (done: () => void) => { createWorkspace((workspaceDir, globalSettingsFile, cleanUp) => { - const workspaceContextService = new WorkspaceContextService({ resource: URI.file(workspaceDir) }); + const workspace = new Workspace(URI.file(workspaceDir)); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); - const service = new WorkspaceConfigurationService(workspaceContextService, environmentService); + const service = new WorkspaceConfigurationService(environmentService, workspace); return service.initialize().then(() => { service.onDidUpdateConfiguration(event => { @@ -230,9 +230,9 @@ suite('WorkspaceConfigurationService - Node', () => { test('workspace reload should triggers event if content changed', (done: () => void) => { createWorkspace((workspaceDir, globalSettingsFile, cleanUp) => { - const workspaceContextService = new WorkspaceContextService({ resource: URI.file(workspaceDir) }); + const workspace = new Workspace(URI.file(workspaceDir)); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); - const service = new WorkspaceConfigurationService(workspaceContextService, environmentService); + const service = new WorkspaceConfigurationService(environmentService, workspace); return service.initialize().then(() => { const settingsFile = path.join(workspaceDir, '.vscode', 'settings.json'); @@ -255,9 +255,9 @@ suite('WorkspaceConfigurationService - Node', () => { test('workspace reload should not trigger event if nothing changed', (done: () => void) => { createWorkspace((workspaceDir, globalSettingsFile, cleanUp) => { - const workspaceContextService = new WorkspaceContextService({ resource: URI.file(workspaceDir) }); + const workspace = new Workspace(URI.file(workspaceDir)); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); - const service = new WorkspaceConfigurationService(workspaceContextService, environmentService); + const service = new WorkspaceConfigurationService(environmentService, workspace); return service.initialize().then(() => { const settingsFile = path.join(workspaceDir, '.vscode', 'settings.json'); @@ -280,9 +280,9 @@ suite('WorkspaceConfigurationService - Node', () => { test('workspace reload should not trigger event if there is no model', (done: () => void) => { createWorkspace((workspaceDir, globalSettingsFile, cleanUp) => { - const workspaceContextService = new WorkspaceContextService({ resource: URI.file(workspaceDir) }); + const workspace = new Workspace(URI.file(workspaceDir)); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); - const service = new WorkspaceConfigurationService(workspaceContextService, environmentService); + const service = new WorkspaceConfigurationService(environmentService, workspace); return service.initialize().then(() => { const target = sinon.stub(); diff --git a/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts b/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts index ad4fdee36f5..dfd2576d1d4 100644 --- a/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts +++ b/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts @@ -7,7 +7,7 @@ import 'vs/workbench/parts/search/browser/search.contribution'; // load contributions import * as assert from 'assert'; -import { WorkspaceContextService, IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { WorkspaceContextService, IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import { createSyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { ISearchService } from 'vs/platform/search/common/search'; @@ -73,7 +73,7 @@ suite('QuickOpen performance (integration)', () => { [ITelemetryService, telemetryService], [IConfigurationService, new SimpleConfigurationService()], [IModelService, new ModelServiceImpl(null, configurationService)], - [IWorkspaceContextService, new WorkspaceContextService({ resource: URI.file(testWorkspacePath) })], + [IWorkspaceContextService, new WorkspaceContextService(new Workspace(URI.file(testWorkspacePath)))], [IWorkbenchEditorService, new TestEditorService()], [IEditorGroupService, new TestEditorGroupService()], [IEnvironmentService, TestEnvironmentService], diff --git a/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts b/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts index 861ff475677..7d1bb6b1139 100644 --- a/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts +++ b/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts @@ -8,7 +8,7 @@ import 'vs/workbench/parts/search/browser/search.contribution'; // load contributions import * as assert from 'assert'; import * as fs from 'fs'; -import { WorkspaceContextService, IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { WorkspaceContextService, IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import { createSyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { ISearchService, IQueryOptions } from 'vs/platform/search/common/search'; @@ -62,7 +62,7 @@ suite('TextSearch performance (integration)', () => { [ITelemetryService, telemetryService], [IConfigurationService, new SimpleConfigurationService()], [IModelService, new ModelServiceImpl(null, configurationService)], - [IWorkspaceContextService, new WorkspaceContextService({ resource: URI.file(testWorkspacePath) })], + [IWorkspaceContextService, new WorkspaceContextService(new Workspace(URI.file(testWorkspacePath)))], [IWorkbenchEditorService, new TestEditorService()], [IEditorGroupService, new TestEditorGroupService()], [IEnvironmentService, TestEnvironmentService], -- GitLab From 9363c783d3ebf233a3d22228bc438c841bdcb3da Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Mon, 12 Jun 2017 11:10:16 +0200 Subject: [PATCH 0710/1347] Tweak #28351 --- .../parts/tasks/electron-browser/terminalTaskSystem.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts index 31727dae1e0..5ea02159fff 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts @@ -423,7 +423,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { shellArgs.push(commandLine); shellLaunchConfig.args = Platform.isWindows ? shellArgs.join(' ') : shellArgs; if (task.command.terminalBehavior.echo) { - shellLaunchConfig.initialText = `\x1b[4mExecuting task: ${commandLine}\x1b[0m\n`; + shellLaunchConfig.initialText = `\x1b[1m>Executing task: ${commandLine}<\x1b[0m\n`; } } else { let cwd = options && options.cwd ? options.cwd : process.cwd(); @@ -446,7 +446,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { } return args.join(' '); }; - shellLaunchConfig.initialText = `Executing task: ${shellLaunchConfig.executable} ${getArgsToEcho(shellLaunchConfig.args)}\n`; + shellLaunchConfig.initialText = `\x1b[1m>Executing task: ${shellLaunchConfig.executable} ${getArgsToEcho(shellLaunchConfig.args)}<\x1b[0m\n`; } } if (options.cwd) { -- GitLab From 720cbadf293f4e932e14f932c64e666e15fa020d Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Mon, 12 Jun 2017 12:02:45 +0200 Subject: [PATCH 0711/1347] Implement correct silent bahviour for terminal task runner. --- .../parts/tasks/electron-browser/terminalTaskSystem.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts index 5ea02159fff..b22d2788cb3 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts @@ -332,7 +332,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { }); } this.terminalService.setActiveInstance(terminal); - if (task.command.terminalBehavior.reveal === RevealKind.Always) { + if (task.command.terminalBehavior.reveal === RevealKind.Always || (task.command.terminalBehavior.reveal === RevealKind.Silent && task.problemMatchers.length === 0)) { this.terminalService.showPanel(false); } this.activeTasks[task._id] = { terminal, task, promise }; -- GitLab From 240cf011a18b037a1929cace7bf5a3086aac6dbe Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Mon, 12 Jun 2017 12:38:08 +0200 Subject: [PATCH 0712/1347] VS code icons is distorted when invoked from the command line (fixes #28345) --- src/main.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/main.js b/src/main.js index 9bba0165cd7..492179610a3 100644 --- a/src/main.js +++ b/src/main.js @@ -19,9 +19,7 @@ if (process.argv.indexOf('--prof-startup') >= 0) { if (process.env.LC_ALL) { process.env.LC_ALL = 'C'; } -if (process.env.LC_NUMERIC) { - process.env.LC_NUMERIC = 'C'; -} +process.env.LC_NUMERIC = 'C'; // Perf measurements global.perfStartTime = Date.now(); -- GitLab From 00a24d5c82baa300ce8aa2f7c7780655d11070cf Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Mon, 12 Jun 2017 12:40:58 +0200 Subject: [PATCH 0713/1347] workspace - wire in some new apis to get at folders --- .../browser/standalone/standaloneServices.ts | 7 +- src/vs/platform/workspace/common/workspace.ts | 86 ++++++++++++++++++- .../electron-browser/main.contribution.ts | 29 +++++++ src/vs/workbench/electron-browser/main.ts | 2 +- src/vs/workbench/node/extensionHostMain.ts | 3 +- .../extensionsActions.test.ts | 3 +- .../extensionsWorkbenchService.test.ts | 3 +- .../terminalLinkHandler.test.ts | 7 +- .../node/nullConfigurationService.ts | 44 ++++++++++ .../node/configurationEditingService.test.ts | 2 +- src/vs/workbench/test/browser/part.test.ts | 3 +- src/vs/workbench/test/common/memento.test.ts | 3 +- .../quickopen.perf.integrationTest.ts | 4 +- .../textsearch.perf.integrationTest.ts | 4 +- .../workbench/test/workbenchTestServices.ts | 11 +++ 15 files changed, 191 insertions(+), 20 deletions(-) create mode 100644 src/vs/workbench/services/configuration/node/nullConfigurationService.ts diff --git a/src/vs/editor/browser/standalone/standaloneServices.ts b/src/vs/editor/browser/standalone/standaloneServices.ts index 68e9623baf1..456290afa8d 100644 --- a/src/vs/editor/browser/standalone/standaloneServices.ts +++ b/src/vs/editor/browser/standalone/standaloneServices.ts @@ -115,14 +115,15 @@ export module StaticServices { export const instantiationService = define(IInstantiationService, () => new InstantiationService(_serviceCollection, true)); - export const contextService = define(IWorkspaceContextService, () => new WorkspaceContextService(new Workspace( + const configurationServiceImpl = new SimpleConfigurationService(); + export const configurationService = define(IConfigurationService, () => configurationServiceImpl); + + export const contextService = define(IWorkspaceContextService, () => new WorkspaceContextService(configurationServiceImpl, new Workspace( URI.from({ scheme: 'inmemory', authority: 'model', path: '/' }) ))); export const telemetryService = define(ITelemetryService, () => new StandaloneTelemetryService()); - export const configurationService = define(IConfigurationService, () => new SimpleConfigurationService()); - export const messageService = define(IMessageService, () => new SimpleMessageService()); export const markerService = define(IMarkerService, () => new MarkerService()); diff --git a/src/vs/platform/workspace/common/workspace.ts b/src/vs/platform/workspace/common/workspace.ts index a1a0480997d..8e0747fa8de 100644 --- a/src/vs/platform/workspace/common/workspace.ts +++ b/src/vs/platform/workspace/common/workspace.ts @@ -9,6 +9,11 @@ import { createDecorator } from 'vs/platform/instantiation/common/instantiation' import paths = require('vs/base/common/paths'); import { isEqualOrParent } from 'vs/platform/files/common/files'; import { isLinux } from 'vs/base/common/platform'; +import Event, { Emitter } from 'vs/base/common/event'; +import { IConfigurationService } from "vs/platform/configuration/common/configuration"; +import { IDisposable, dispose } from "vs/base/common/lifecycle"; +import { distinct, equals } from "vs/base/common/arrays"; +import { Schemas } from "vs/base/common/network"; export const IWorkspaceContextService = createDecorator('contextService'); @@ -42,6 +47,12 @@ export interface IWorkspaceContextService { * Given a workspace relative path, returns the resource with the absolute path. */ toResource: (workspaceRelativePath: string) => URI; + + /** + * TODO@Ben multiroot + */ + getFolders(): URI[]; + onDidChangeFolders: Event; } export interface IWorkspace { @@ -111,14 +122,79 @@ export class Workspace implements IWorkspace { } } +type IWorkspaceConfiguration = { path: string; folders: string[]; }[]; + export class WorkspaceContextService implements IWorkspaceContextService { public _serviceBrand: any; - private workspace: Workspace; + private _onDidChangeFolders: Emitter; + private folders: URI[]; + private toDispose: IDisposable[]; + + constructor(private configurationService: IConfigurationService, private workspace?: Workspace) { + this.toDispose = []; + + this._onDidChangeFolders = new Emitter(); + this.toDispose.push(this._onDidChangeFolders); + + this.folders = workspace ? [workspace.resource] : []; + + this.resolveAdditionalFolders(); + + this.registerListeners(); + } + + private registerListeners(): void { + this.toDispose.push(this.configurationService.onDidUpdateConfiguration(e => this.onDidUpdateConfiguration())); + } + + private onDidUpdateConfiguration(): void { + this.resolveAdditionalFolders(true); + } + + private resolveAdditionalFolders(notify?: boolean): void { + if (!this.workspace) { + return; // no additional folders for empty workspaces + } + + // Resovled configured folders for workspace + let configuredFolders: URI[] = [this.workspace.resource]; + const config = this.configurationService.getConfiguration('workspace'); + if (Array.isArray(config)) { + for (let i = 0; i < config.length; i++) { + const targetWorkspace = config[i]; + if (targetWorkspace.path === this.workspace.resource.toString()) { + const additionalFolders = targetWorkspace.folders + .map(f => URI.parse(f)) + .filter(r => r.scheme === Schemas.file); // only support files for now + + configuredFolders.push(...additionalFolders); + + break; + } + } + } + + // Remove duplicates + configuredFolders = distinct(configuredFolders, r => r.toString()); + + // Find changes + const changed = !equals(this.folders, configuredFolders, (r1, r2) => r1.toString() === r2.toString()); + + this.folders = configuredFolders; - constructor(workspace?: Workspace) { - this.workspace = workspace; + if (notify && changed) { + this._onDidChangeFolders.fire(configuredFolders); + } + } + + public get onDidChangeFolders(): Event { + return this._onDidChangeFolders && this._onDidChangeFolders.event; //TODO@Sandeep sinon is a pita + } + + public getFolders(): URI[] { + return this.folders; } public getWorkspace(): IWorkspace { @@ -140,4 +216,8 @@ export class WorkspaceContextService implements IWorkspaceContextService { public toResource(workspaceRelativePath: string): URI { return this.workspace ? this.workspace.toResource(workspaceRelativePath) : null; } + + public dispose(): void { + dispose(this.toDispose); + } } \ No newline at end of file diff --git a/src/vs/workbench/electron-browser/main.contribution.ts b/src/vs/workbench/electron-browser/main.contribution.ts index e34a426f1ef..2cbc72f32ec 100644 --- a/src/vs/workbench/electron-browser/main.contribution.ts +++ b/src/vs/workbench/electron-browser/main.contribution.ts @@ -357,4 +357,33 @@ configurationRegistry.registerConfiguration({ 'description': nls.localize('zenMode.restore', "Controls if a window should restore to zen mode if it was exited in zen mode.") } } +}); + +// Configuration: Workspace +configurationRegistry.registerConfiguration({ + 'id': 'workspace', + 'order': 10000, + 'title': nls.localize('workspaceConfigurationTitle', "Workspace"), + 'type': 'object', + 'properties': { + 'workspace': { + 'type': 'array', + 'title': nls.localize('workspaces.title', "Folder configuration of the workspace"), + 'items': { + 'required': ['path'], + 'type': 'object', + 'defaultSnippets': [{ 'body': { 'path': '$1', 'folders': ['$2'] } }], + 'properties': { + 'path': { + 'type': 'string', + 'description': nls.localize('workspaces.path', "Path of the folder to configure folders for"), + }, + 'folders': { + 'description': nls.localize('workspaces.additionalFolders', "Folders of this workspace"), + 'type': 'array' + } + } + } + } + } }); \ No newline at end of file diff --git a/src/vs/workbench/electron-browser/main.ts b/src/vs/workbench/electron-browser/main.ts index b8bfbe51ce6..4afe4e06bf4 100644 --- a/src/vs/workbench/electron-browser/main.ts +++ b/src/vs/workbench/electron-browser/main.ts @@ -150,8 +150,8 @@ function getWorkspace(workspacePath: string): TPromise { function openWorkbench(environment: IWindowConfiguration, workspace: Workspace, options: IOptions): TPromise { const environmentService = new EnvironmentService(environment, environment.execPath); - const contextService = new WorkspaceContextService(workspace); const configurationService = new WorkspaceConfigurationService(environmentService, workspace); + const contextService = new WorkspaceContextService(configurationService, workspace); const timerService = new TimerService((window).MonacoEnvironment.timers as IInitData, !contextService.hasWorkspace()); // Since the configuration service is one of the core services that is used in so many places, we initialize it diff --git a/src/vs/workbench/node/extensionHostMain.ts b/src/vs/workbench/node/extensionHostMain.ts index abb6f76e6c8..6d38c79e651 100644 --- a/src/vs/workbench/node/extensionHostMain.ts +++ b/src/vs/workbench/node/extensionHostMain.ts @@ -18,6 +18,7 @@ import { RemoteTelemetryService } from 'vs/workbench/api/node/extHostTelemetry'; import { IWorkspaceContextService, WorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import { IInitData, IEnvironment, MainContext } from 'vs/workbench/api/node/extHost.protocol'; import * as errors from 'vs/base/common/errors'; +import { NullConfigurationService } from "vs/workbench/services/configuration/node/nullConfigurationService"; const nativeExit = process.exit.bind(process); process.exit = function () { @@ -49,7 +50,7 @@ export class ExtensionHostMain { if (workspaceRaw) { workspace = new Workspace(workspaceRaw.resource, workspaceRaw.uid, workspaceRaw.name); } - this._contextService = new WorkspaceContextService(workspace); + this._contextService = new WorkspaceContextService(new NullConfigurationService(), workspace); //TODO@Ben implement for exthost const threadService = new ExtHostThreadService(remoteCom); const telemetryService = new RemoteTelemetryService('pluginHostTelemetry', threadService); diff --git a/src/vs/workbench/parts/extensions/test/electron-browser/extensionsActions.test.ts b/src/vs/workbench/parts/extensions/test/electron-browser/extensionsActions.test.ts index 0f50eb3a0e5..084d5a3ad71 100644 --- a/src/vs/workbench/parts/extensions/test/electron-browser/extensionsActions.test.ts +++ b/src/vs/workbench/parts/extensions/test/electron-browser/extensionsActions.test.ts @@ -31,6 +31,7 @@ import { IExtensionService } from 'vs/platform/extensions/common/extensions'; import { IWorkspaceContextService, WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { TestWorkspace } from 'vs/platform/workspace/test/common/testWorkspace'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; +import { TestConfigurationService } from "vs/platform/configuration/test/common/testConfigurationService"; suite('ExtensionsActions Test', () => { @@ -52,7 +53,7 @@ suite('ExtensionsActions Test', () => { instantiationService.stub(IURLService, { onOpenURL: new Emitter().event }); instantiationService.stub(ITelemetryService, NullTelemetryService); - instantiationService.set(IWorkspaceContextService, new WorkspaceContextService(TestWorkspace)); + instantiationService.set(IWorkspaceContextService, new WorkspaceContextService(new TestConfigurationService(), TestWorkspace)); instantiationService.stub(IConfigurationService, { onDidUpdateConfiguration: () => { }, getConfiguration: () => ({}) }); instantiationService.stub(IExtensionGalleryService, ExtensionGalleryService); diff --git a/src/vs/workbench/parts/extensions/test/electron-browser/extensionsWorkbenchService.test.ts b/src/vs/workbench/parts/extensions/test/electron-browser/extensionsWorkbenchService.test.ts index d42837e340e..15ba37559d7 100644 --- a/src/vs/workbench/parts/extensions/test/electron-browser/extensionsWorkbenchService.test.ts +++ b/src/vs/workbench/parts/extensions/test/electron-browser/extensionsWorkbenchService.test.ts @@ -32,6 +32,7 @@ import { IWorkspaceContextService, WorkspaceContextService } from 'vs/platform/w import { TestWorkspace } from 'vs/platform/workspace/test/common/testWorkspace'; import { IChoiceService } from 'vs/platform/message/common/message'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; +import { TestConfigurationService } from "vs/platform/configuration/test/common/testConfigurationService"; suite('ExtensionsWorkbenchService Test', () => { @@ -55,7 +56,7 @@ suite('ExtensionsWorkbenchService Test', () => { instantiationService.stub(IExtensionGalleryService, ExtensionGalleryService); - instantiationService.set(IWorkspaceContextService, new WorkspaceContextService(TestWorkspace)); + instantiationService.set(IWorkspaceContextService, new WorkspaceContextService(new TestConfigurationService(), TestWorkspace)); instantiationService.stub(IConfigurationService, { onDidUpdateConfiguration: () => { }, getConfiguration: () => ({}) }); instantiationService.stub(IExtensionManagementService, ExtensionManagementService); diff --git a/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts b/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts index d61de282fd4..3670f2a79f9 100644 --- a/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts +++ b/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts @@ -13,6 +13,7 @@ import URI from 'vs/base/common/uri'; import * as strings from 'vs/base/common/strings'; import * as path from 'path'; import * as sinon from 'sinon'; +import { TestConfigurationService } from "vs/platform/configuration/test/common/testConfigurationService"; class TestTerminalLinkHandler extends TerminalLinkHandler { public get localLinkRegex(): RegExp { @@ -175,7 +176,7 @@ suite('Workbench - TerminalLinkHandler', () => { suite('preprocessPath', () => { test('Windows', () => { const linkHandler = new TestTerminalLinkHandler(new TestXterm(), Platform.Windows, null, null, - new WorkspaceContextService(new TestWorkspace('C:\\base'))); + new WorkspaceContextService(new TestConfigurationService(), new TestWorkspace('C:\\base'))); let stub = sinon.stub(path, 'join', function (arg1, arg2) { return arg1 + '\\' + arg2; @@ -189,7 +190,7 @@ suite('Workbench - TerminalLinkHandler', () => { test('Linux', () => { const linkHandler = new TestTerminalLinkHandler(new TestXterm(), Platform.Linux, null, null, - new WorkspaceContextService(new TestWorkspace('/base'))); + new WorkspaceContextService(new TestConfigurationService(), new TestWorkspace('/base'))); let stub = sinon.stub(path, 'join', function (arg1, arg2) { return arg1 + '/' + arg2; @@ -202,7 +203,7 @@ suite('Workbench - TerminalLinkHandler', () => { }); test('No Workspace', () => { - const linkHandler = new TestTerminalLinkHandler(new TestXterm(), Platform.Linux, null, null, new WorkspaceContextService(null)); + const linkHandler = new TestTerminalLinkHandler(new TestXterm(), Platform.Linux, null, null, new WorkspaceContextService(new TestConfigurationService())); assert.equal(linkHandler.preprocessPath('./src/file1'), null); assert.equal(linkHandler.preprocessPath('src/file2'), null); diff --git a/src/vs/workbench/services/configuration/node/nullConfigurationService.ts b/src/vs/workbench/services/configuration/node/nullConfigurationService.ts new file mode 100644 index 00000000000..c38b5b29b2e --- /dev/null +++ b/src/vs/workbench/services/configuration/node/nullConfigurationService.ts @@ -0,0 +1,44 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +'use strict'; + +import { IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, getConfigurationValue, IConfigurationKeys } from "vs/platform/configuration/common/configuration"; +import Event, { Emitter } from 'vs/base/common/event'; +import { TPromise } from "vs/base/common/winjs.base"; + +export class NullConfigurationService implements IConfigurationService { + + _serviceBrand: any; + + private _onDidUpdateConfiguration = new Emitter(); + public onDidUpdateConfiguration: Event = this._onDidUpdateConfiguration.event; + + private _config: any; + + constructor() { + this._config = Object.create(null); + } + + public getConfiguration(section?: any): T { + return this._config; + } + + public reloadConfiguration(section?: string): TPromise { + return TPromise.as(this.getConfiguration(section)); + } + + public lookup(key: string): IConfigurationValue { + return { + value: getConfigurationValue(this.getConfiguration(), key), + default: getConfigurationValue(this.getConfiguration(), key), + user: getConfigurationValue(this.getConfiguration(), key) + }; + } + + public keys(): IConfigurationKeys { + return { default: [], user: [] }; + } +} \ No newline at end of file diff --git a/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts b/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts index df423a3c094..86e267938fe 100644 --- a/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts +++ b/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts @@ -116,8 +116,8 @@ suite('ConfigurationEditingService', () => { const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); instantiationService.stub(IEnvironmentService, environmentService); const workspace = noWorkspace ? null : new Workspace(URI.file(workspaceDir)); - instantiationService.stub(IWorkspaceContextService, new WorkspaceContextService(workspace)); const configurationService = new WorkspaceConfigurationService(environmentService, workspace); + instantiationService.stub(IWorkspaceContextService, new WorkspaceContextService(configurationService, workspace)); instantiationService.stub(IConfigurationService, configurationService); instantiationService.stub(ILifecycleService, new TestLifecycleService()); instantiationService.stub(IEditorGroupService, new TestEditorGroupService()); diff --git a/src/vs/workbench/test/browser/part.test.ts b/src/vs/workbench/test/browser/part.test.ts index a8a31790634..0d4d0f1418f 100644 --- a/src/vs/workbench/test/browser/part.test.ts +++ b/src/vs/workbench/test/browser/part.test.ts @@ -14,6 +14,7 @@ import { IStorageService } from 'vs/platform/storage/common/storage'; import { StorageService, InMemoryLocalStorage } from 'vs/platform/storage/common/storageService'; import { TestWorkspace } from 'vs/platform/workspace/test/common/testWorkspace'; import { TestThemeService } from 'vs/workbench/test/workbenchTestServices'; +import { TestConfigurationService } from "vs/platform/configuration/test/common/testConfigurationService"; class MyPart extends Part { @@ -91,7 +92,7 @@ suite('Workbench Part', () => { fixture = document.createElement('div'); fixture.id = fixtureId; document.body.appendChild(fixture); - context = new WorkspaceContextService(TestWorkspace); + context = new WorkspaceContextService(new TestConfigurationService(), TestWorkspace); storage = new StorageService(new InMemoryLocalStorage(), null, context); }); diff --git a/src/vs/workbench/test/common/memento.test.ts b/src/vs/workbench/test/common/memento.test.ts index 796ef72d8dd..c8d988af459 100644 --- a/src/vs/workbench/test/common/memento.test.ts +++ b/src/vs/workbench/test/common/memento.test.ts @@ -11,13 +11,14 @@ import { StorageScope } from 'vs/platform/storage/common/storage'; import { TestWorkspace } from 'vs/platform/workspace/test/common/testWorkspace'; import { Memento, Scope } from 'vs/workbench/common/memento'; import { StorageService, InMemoryLocalStorage } from 'vs/platform/storage/common/storageService'; +import { TestConfigurationService } from "vs/platform/configuration/test/common/testConfigurationService"; suite('Workbench Memento', () => { let context; let storage; setup(() => { - context = new WorkspaceContextService(TestWorkspace); + context = new WorkspaceContextService(new TestConfigurationService(), TestWorkspace); storage = new StorageService(new InMemoryLocalStorage(), null, context); }); diff --git a/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts b/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts index dfd2576d1d4..26a08ffd11b 100644 --- a/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts +++ b/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts @@ -71,9 +71,9 @@ suite('QuickOpen performance (integration)', () => { const configurationService = new SimpleConfigurationService(); const instantiationService = new InstantiationService(new ServiceCollection( [ITelemetryService, telemetryService], - [IConfigurationService, new SimpleConfigurationService()], + [IConfigurationService, configurationService], [IModelService, new ModelServiceImpl(null, configurationService)], - [IWorkspaceContextService, new WorkspaceContextService(new Workspace(URI.file(testWorkspacePath)))], + [IWorkspaceContextService, new WorkspaceContextService(configurationService, new Workspace(URI.file(testWorkspacePath)))], [IWorkbenchEditorService, new TestEditorService()], [IEditorGroupService, new TestEditorGroupService()], [IEnvironmentService, TestEnvironmentService], diff --git a/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts b/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts index 7d1bb6b1139..64f77fcc9c9 100644 --- a/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts +++ b/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts @@ -60,9 +60,9 @@ suite('TextSearch performance (integration)', () => { const configurationService = new SimpleConfigurationService(); const instantiationService = new InstantiationService(new ServiceCollection( [ITelemetryService, telemetryService], - [IConfigurationService, new SimpleConfigurationService()], + [IConfigurationService, configurationService], [IModelService, new ModelServiceImpl(null, configurationService)], - [IWorkspaceContextService, new WorkspaceContextService(new Workspace(URI.file(testWorkspacePath)))], + [IWorkspaceContextService, new WorkspaceContextService(configurationService, new Workspace(URI.file(testWorkspacePath)))], [IWorkbenchEditorService, new TestEditorService()], [IEditorGroupService, new TestEditorGroupService()], [IEnvironmentService, TestEnvironmentService], diff --git a/src/vs/workbench/test/workbenchTestServices.ts b/src/vs/workbench/test/workbenchTestServices.ts index 32f74fe5a2d..0928c71276d 100644 --- a/src/vs/workbench/test/workbenchTestServices.ts +++ b/src/vs/workbench/test/workbenchTestServices.ts @@ -66,9 +66,20 @@ export class TestContextService implements IWorkspaceContextService { private workspace: any; private options: any; + private _onDidChangeFolders: Emitter; + constructor(workspace: any = TestWorkspace, options: any = null) { this.workspace = workspace; this.options = options || Object.create(null); + this._onDidChangeFolders = new Emitter(); + } + + public get onDidChangeFolders(): Event { + return this._onDidChangeFolders.event; + } + + public getFolders(): URI[] { + return this.workspace ? [this.workspace.resource] : []; } public hasWorkspace(): boolean { -- GitLab From 3194060001a3a1b11858dc6bbfeacae5f0953bf0 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Mon, 12 Jun 2017 12:46:14 +0200 Subject: [PATCH 0714/1347] debt - prevent accidentical exposing of APIs by being too relaxed --- src/vs/workbench/api/node/extHost.api.impl.ts | 51 +++---------------- 1 file changed, 8 insertions(+), 43 deletions(-) diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index cef1654dca7..b9b4746182f 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -65,33 +65,6 @@ function proposedApiFunction(extension: IExtensionDescription, fn: T): T { } } -function proposed(extension: IExtensionDescription): Function { - return (target: any, key: string, descriptor: any) => { - let fnKey: string = null; - let fn: Function = null; - - if (typeof descriptor.value === 'function') { - fnKey = 'value'; - fn = descriptor.value; - } else if (typeof descriptor.get === 'function') { - fnKey = 'get'; - fn = descriptor.get; - } - - if (!fn) { - throw new Error('not supported'); - } - - if (extension.enableProposedApi) { - return; - } - - descriptor[fnKey] = () => { - throw new Error(`${extension.id} cannot access proposed api`); - }; - }; -} - /** * This method instantiates and returns the extension API surface */ @@ -153,12 +126,11 @@ export function createApiFactory( } } - class Commands { - + // namespace: commands + const commands: typeof vscode.commands = { registerCommand(id: string, command: (...args: any[]) => T | Thenable, thisArgs?: any): vscode.Disposable { return extHostCommands.registerCommand(id, command, thisArgs); - } - + }, registerTextEditorCommand(id: string, callback: (textEditor: vscode.TextEditor, edit: vscode.TextEditorEdit, ...args: any[]) => void, thisArg?: any): vscode.Disposable { return extHostCommands.registerCommand(id, (...args: any[]) => { let activeTextEditor = extHostEditors.getActiveTextEditor(); @@ -179,10 +151,8 @@ export function createApiFactory( console.warn('An error occured while running command ' + id, err); }); }); - } - - @proposed(extension) - registerDiffInformationCommand(id: string, callback: (diff: vscode.LineChange[], ...args: any[]) => any, thisArg?: any): vscode.Disposable { + }, + registerDiffInformationCommand: proposedApiFunction(extension, (id: string, callback: (diff: vscode.LineChange[], ...args: any[]) => any, thisArg?: any): vscode.Disposable => { return extHostCommands.registerCommand(id, async (...args: any[]) => { let activeTextEditor = extHostEditors.getActiveTextEditor(); if (!activeTextEditor) { @@ -193,19 +163,14 @@ export function createApiFactory( const diff = await extHostEditors.getDiffInformation(activeTextEditor.id); callback.apply(thisArg, [diff, ...args]); }); - } - + }), executeCommand(id: string, ...args: any[]): Thenable { return extHostCommands.executeCommand(id, ...args); - } - + }, getCommands(filterInternal: boolean = false): Thenable { return extHostCommands.getCommands(filterInternal); } - } - - // namespace: commands - const commands: typeof vscode.commands = new Commands(); + }; // namespace: env const env: typeof vscode.env = Object.freeze({ -- GitLab From 7f54c775f3199f42ff5f4db51f0b65e9d1072fb4 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Mon, 12 Jun 2017 12:59:38 +0200 Subject: [PATCH 0715/1347] debt: Replace custom Map object with Native Map --- src/vs/base/common/map.ts | 116 ++---------------- src/vs/base/test/common/map.test.ts | 63 +--------- .../test/common/instantiationServiceMock.ts | 5 +- .../browser/parts/editor/tabsTitleControl.ts | 13 +- .../node/extensionsWorkbenchService.ts | 1 - .../parts/markers/common/markersModel.ts | 38 +++--- .../browser/preferencesRenderers.ts | 3 +- .../preferences/browser/preferencesService.ts | 6 +- .../parts/preferences/common/preferences.ts | 1 - .../preferences/common/preferencesModels.ts | 1 - .../parts/search/common/searchModel.ts | 20 +-- 11 files changed, 54 insertions(+), 213 deletions(-) diff --git a/src/vs/base/common/map.ts b/src/vs/base/common/map.ts index 48357176b8a..9e7d7dc8d73 100644 --- a/src/vs/base/common/map.ts +++ b/src/vs/base/common/map.ts @@ -16,108 +16,19 @@ export interface Entry { value: T; } -/** - * A simple map to store value by a key object. Key can be any object that has toString() function to get - * string value of the key. - */ -export class SimpleMap { - - protected map: { [key: string]: Entry }; - protected _size: number; - - constructor() { - this.map = Object.create(null); - this._size = 0; - } - - public get size(): number { - return this._size; - } - - public get(k: K): T { - const value = this.peek(k); - - return value ? value : null; - } - - public getOrSet(k: K, t: T): T { - const res = this.get(k); - if (res) { - return res; - } - - this.set(k, t); - - return t; - } - - public keys(): K[] { - const keys: K[] = []; - for (let key in this.map) { - keys.push(this.map[key].key); - } - return keys; - } - - public values(): T[] { - const values: T[] = []; - for (let key in this.map) { - values.push(this.map[key].value); - } - return values; - } - - public entries(): Entry[] { - const entries: Entry[] = []; - for (let key in this.map) { - entries.push(this.map[key]); - } - return entries; - } - - public set(k: K, t: T): boolean { - if (this.get(k)) { - return false; // already present! - } - - this.push(k, t); - - return true; - } - - public delete(k: K): T { - let value: T = this.get(k); - if (value) { - this.pop(k); - return value; - } - return null; - } - - public has(k: K): boolean { - return !!this.get(k); - } - - public clear(): void { - this.map = Object.create(null); - this._size = 0; - } - - protected push(key: K, value: T): void { - const entry: Entry = { key, value }; - this.map[key.toString()] = entry; - this._size++; - } - - protected pop(k: K): void { - delete this.map[k.toString()]; - this._size--; - } +export function values(map: Map): V[] { + const result: V[] = []; + map.forEach(value => result.push(value)); + return result; +} - protected peek(k: K): T { - const entry = this.map[k.toString()]; - return entry ? entry.value : null; +export function getOrSet(map: Map, key: K, value: V): V { + let result = map.get(key); + if (result === void 0) { + result = value; + map.set(key, result); } + return result; } export interface ISerializedBoundedLinkedMap { @@ -455,10 +366,7 @@ export class ResourceMap { } public values(): T[] { - const values: T[] = []; - this.map.forEach(value => values.push(value)); - - return values; + return values(this.map); } private toKey(resource: URI): string { diff --git a/src/vs/base/test/common/map.test.ts b/src/vs/base/test/common/map.test.ts index 38998ac5fb8..58c8413ba84 100644 --- a/src/vs/base/test/common/map.test.ts +++ b/src/vs/base/test/common/map.test.ts @@ -5,73 +5,12 @@ 'use strict'; -import { BoundedMap, SimpleMap, TrieMap, ResourceMap } from 'vs/base/common/map'; +import { BoundedMap, TrieMap, ResourceMap } from 'vs/base/common/map'; import * as assert from 'assert'; import URI from 'vs/base/common/uri'; suite('Map', () => { - test('SimpleMap - basics', function () { - const map = new SimpleMap(); - - assert.equal(map.size, 0); - - map.set('1', 1); - map.set('2', '2'); - map.set('3', true); - - const obj = Object.create(null); - map.set('4', obj); - - const date = Date.now(); - map.set('5', date); - - assert.equal(map.size, 5); - assert.equal(map.get('1'), 1); - assert.equal(map.get('2'), '2'); - assert.equal(map.get('3'), true); - assert.equal(map.get('4'), obj); - assert.equal(map.get('5'), date); - assert.ok(!map.get('6')); - - map.delete('6'); - assert.equal(map.size, 5); - assert.equal(map.delete('1'), 1); - assert.equal(map.delete('2'), '2'); - assert.equal(map.delete('3'), true); - assert.equal(map.delete('4'), obj); - assert.equal(map.delete('5'), date); - - assert.equal(map.size, 0); - assert.ok(!map.get('5')); - assert.ok(!map.get('4')); - assert.ok(!map.get('3')); - assert.ok(!map.get('2')); - assert.ok(!map.get('1')); - - map.set('1', 1); - map.set('2', '2'); - assert.ok(map.set('3', true)); // adding an element returns true - assert.ok(!map.set('3', true)); // adding it again returns false - - assert.ok(map.has('1')); - assert.equal(map.get('1'), 1); - assert.equal(map.get('2'), '2'); - assert.equal(map.get('3'), true); - - map.clear(); - - assert.equal(map.size, 0); - assert.ok(!map.get('1')); - assert.ok(!map.get('2')); - assert.ok(!map.get('3')); - assert.ok(!map.has('1')); - - const res = map.getOrSet('foo', 'bar'); - assert.equal(map.get('foo'), res); - assert.equal(res, 'bar'); - }); - test('BoundedMap - basics', function () { const map = new BoundedMap(); diff --git a/src/vs/platform/instantiation/test/common/instantiationServiceMock.ts b/src/vs/platform/instantiation/test/common/instantiationServiceMock.ts index 717d46e30a1..68c03f70da4 100644 --- a/src/vs/platform/instantiation/test/common/instantiationServiceMock.ts +++ b/src/vs/platform/instantiation/test/common/instantiationServiceMock.ts @@ -8,7 +8,6 @@ import * as sinon from 'sinon'; import { TPromise } from 'vs/base/common/winjs.base'; import * as types from 'vs/base/common/types'; -import { SimpleMap } from 'vs/base/common/map'; import { InstantiationService } from 'vs/platform/instantiation/common/instantiationService'; import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; import { ServiceIdentifier } from 'vs/platform/instantiation/common/instantiation'; @@ -20,12 +19,12 @@ interface IServiceMock { export class TestInstantiationService extends InstantiationService { - private _servciesMap: SimpleMap, any>; + private _servciesMap: Map, any>; constructor(private _serviceCollection: ServiceCollection = new ServiceCollection()) { super(_serviceCollection); - this._servciesMap = new SimpleMap, any>(); + this._servciesMap = new Map, any>(); } public get(service: ServiceIdentifier): T { diff --git a/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts b/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts index c9a96445ccf..1793a9c4a17 100644 --- a/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts +++ b/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts @@ -36,7 +36,7 @@ import { IDisposable, dispose, combinedDisposable } from 'vs/base/common/lifecyc import { ScrollableElement } from 'vs/base/browser/ui/scrollbar/scrollableElement'; import { ScrollbarVisibility } from 'vs/base/common/scrollable'; import { extractResources } from 'vs/base/browser/dnd'; -import { SimpleMap } from 'vs/base/common/map'; +import { getOrSet } from 'vs/base/common/map'; import { DelegatingWorkbenchEditorService } from 'vs/workbench/services/editor/browser/editorService'; import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; import { IThemeService, registerThemingParticipant, ITheme, ICssStyleCollector } from 'vs/platform/theme/common/themeService'; @@ -320,8 +320,8 @@ export class TabsTitleControl extends TitleControl { private getUniqueTabLabels(editors: IEditorInput[]): IEditorInputLabel[] { const labels: IEditorInputLabel[] = []; - const mapLabelToDuplicates = new SimpleMap(); - const mapLabelAndDescriptionToDuplicates = new SimpleMap(); + const mapLabelToDuplicates = new Map(); + const mapLabelAndDescriptionToDuplicates = new Map(); // Build labels and descriptions for each editor editors.forEach(editor => { @@ -334,16 +334,15 @@ export class TabsTitleControl extends TitleControl { }; labels.push(item); - mapLabelToDuplicates.getOrSet(item.name, []).push(item); + getOrSet(mapLabelToDuplicates, item.name, []).push(item); if (typeof description === 'string') { - mapLabelAndDescriptionToDuplicates.getOrSet(`${item.name}${item.description}`, []).push(item); + getOrSet(mapLabelAndDescriptionToDuplicates, `${item.name}${item.description}`, []).push(item); } }); // Mark duplicates and shorten their descriptions - const labelDuplicates = mapLabelToDuplicates.values(); - labelDuplicates.forEach(duplicates => { + mapLabelToDuplicates.forEach(duplicates => { if (duplicates.length > 1) { duplicates = duplicates.filter(d => { // we could have items with equal label and description. in that case it does not make much diff --git a/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.ts b/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.ts index 395829a94f0..26ce06d3634 100644 --- a/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.ts +++ b/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.ts @@ -11,7 +11,6 @@ import * as semver from 'semver'; import * as path from 'path'; import Event, { Emitter, chain } from 'vs/base/common/event'; import { index } from 'vs/base/common/arrays'; -import { SimpleMap as Map } from 'vs/base/common/map'; import { assign } from 'vs/base/common/objects'; import { ThrottledDelayer } from 'vs/base/common/async'; import { isPromiseCanceledError } from 'vs/base/common/errors'; diff --git a/src/vs/workbench/parts/markers/common/markersModel.ts b/src/vs/workbench/parts/markers/common/markersModel.ts index f91644a0943..be69523c4d2 100644 --- a/src/vs/workbench/parts/markers/common/markersModel.ts +++ b/src/vs/workbench/parts/markers/common/markersModel.ts @@ -6,7 +6,6 @@ import * as paths from 'vs/base/common/paths'; import * as types from 'vs/base/common/types'; -import * as Map from 'vs/base/common/map'; import Severity from 'vs/base/common/severity'; import URI from 'vs/base/common/uri'; import { Range, IRange } from 'vs/editor/common/core/range'; @@ -125,14 +124,14 @@ export class FilterOptions { export class MarkersModel { - private markersByResource: Map.SimpleMap; + private markersByResource: Map; private _filteredResources: Resource[]; private _nonFilteredResources: Resource[]; private _filterOptions: FilterOptions; constructor(markers: IMarker[] = []) { - this.markersByResource = new Map.SimpleMap(); + this.markersByResource = new Map(); this._filterOptions = new FilterOptions(); this.update(markers); } @@ -154,7 +153,7 @@ export class MarkersModel { } public hasResource(resource: URI): boolean { - return this.markersByResource.has(resource); + return this.markersByResource.has(resource.toString()); } public get nonFilteredResources(): Resource[] { @@ -198,48 +197,47 @@ export class MarkersModel { private refreshResources(): void { this._nonFilteredResources = []; this._filteredResources = []; - for (const entry of this.markersByResource.entries()) { - const filteredResource = this.toFilteredResource(entry); + this.markersByResource.forEach((values, uri) => { + const filteredResource = this.toFilteredResource(URI.parse(uri), values); if (filteredResource.markers.length) { this._filteredResources.push(filteredResource); } else { this._nonFilteredResources.push(filteredResource); } - } + }); } private updateResource(resourceUri: URI, markers: IMarker[]) { - if (this.markersByResource.has(resourceUri)) { - this.markersByResource.delete(resourceUri); + if (this.markersByResource.has(resourceUri.toString())) { + this.markersByResource.delete(resourceUri.toString()); } if (markers.length > 0) { - this.markersByResource.set(resourceUri, markers); + this.markersByResource.set(resourceUri.toString(), markers); } } private updateMarkers(markers: IMarker[]) { markers.forEach((marker: IMarker) => { let uri: URI = marker.resource; - let markers: IMarker[] = this.markersByResource.get(uri); + let markers: IMarker[] = this.markersByResource.get(uri.toString()); if (!markers) { markers = []; - this.markersByResource.set(uri, markers); + this.markersByResource.set(uri.toString(), markers); } markers.push(marker); }); } - private toFilteredResource(entry: Map.Entry) { + private toFilteredResource(uri: URI, values: IMarker[]) { let markers: Marker[] = []; - for (let i = 0; i < entry.value.length; i++) { - const m = entry.value[i]; - const uri = entry.key.toString(); - if (entry.key.scheme !== Schemas.walkThrough && entry.key.scheme !== Schemas.walkThroughSnippet && (!this._filterOptions.hasFilters() || this.filterMarker(m))) { - markers.push(this.toMarker(m, i, uri)); + for (let i = 0; i < values.length; i++) { + const m = values[i]; + if (uri.scheme !== Schemas.walkThrough && uri.scheme !== Schemas.walkThroughSnippet && (!this._filterOptions.hasFilters() || this.filterMarker(m))) { + markers.push(this.toMarker(m, i, uri.toString())); } } - const matches = this._filterOptions.hasFilters() ? FilterOptions._filter(this._filterOptions.filter, paths.basename(entry.key.fsPath)) : []; - return new Resource(entry.key, markers, this.getStatistics(entry.value), matches || []); + const matches = this._filterOptions.hasFilters() ? FilterOptions._filter(this._filterOptions.filter, paths.basename(uri.fsPath)) : []; + return new Resource(uri, markers, this.getStatistics(values), matches || []); } private toMarker(marker: IMarker, index: number, uri: string): Marker { diff --git a/src/vs/workbench/parts/preferences/browser/preferencesRenderers.ts b/src/vs/workbench/parts/preferences/browser/preferencesRenderers.ts index 81941633f5d..c5b7c37de3d 100644 --- a/src/vs/workbench/parts/preferences/browser/preferencesRenderers.ts +++ b/src/vs/workbench/parts/preferences/browser/preferencesRenderers.ts @@ -8,6 +8,7 @@ import * as nls from 'vs/nls'; import { Delayer } from 'vs/base/common/async'; import { Disposable, IDisposable, dispose } from 'vs/base/common/lifecycle'; import { flatten, distinct } from 'vs/base/common/arrays'; +import { values } from 'vs/base/common/map'; import { ArrayNavigator, INavigator } from 'vs/base/common/iterator'; import { IAction } from 'vs/base/common/actions'; import { IJSONSchema } from 'vs/base/common/jsonSchema'; @@ -465,7 +466,7 @@ export class FilteredMatchesRenderer extends Disposable implements HiddenAreasPr if (result) { this.hiddenAreas = this.computeHiddenRanges(result.filteredGroups, result.allGroups, model); this.editor.changeDecorations(changeAccessor => { - this.decorationIds = changeAccessor.deltaDecorations(this.decorationIds, flatten(result.matches.values()).map(match => this.createDecoration(match, model))); + this.decorationIds = changeAccessor.deltaDecorations(this.decorationIds, flatten(values(result.matches)).map(match => this.createDecoration(match, model))); }); } } diff --git a/src/vs/workbench/parts/preferences/browser/preferencesService.ts b/src/vs/workbench/parts/preferences/browser/preferencesService.ts index fa9247c670e..7c7461d4a69 100644 --- a/src/vs/workbench/parts/preferences/browser/preferencesService.ts +++ b/src/vs/workbench/parts/preferences/browser/preferencesService.ts @@ -8,7 +8,7 @@ import * as network from 'vs/base/common/network'; import { TPromise } from 'vs/base/common/winjs.base'; import * as nls from 'vs/nls'; import URI from 'vs/base/common/uri'; -import { SimpleMap as Map } from 'vs/base/common/map'; +import { ResourceMap } from 'vs/base/common/map'; import * as labels from 'vs/base/common/labels'; import * as strings from 'vs/base/common/strings'; import { Disposable } from 'vs/base/common/lifecycle'; @@ -52,7 +52,7 @@ export class PreferencesService extends Disposable implements IPreferencesServic _serviceBrand: any; // TODO:@sandy merge these models into editor inputs by extending resource editor model - private defaultPreferencesEditorModels: Map>>; + private defaultPreferencesEditorModels: ResourceMap>>; private lastOpenedSettingsInput: PreferencesEditorInput = null; constructor( @@ -74,7 +74,7 @@ export class PreferencesService extends Disposable implements IPreferencesServic @IModelService private modelService: IModelService ) { super(); - this.defaultPreferencesEditorModels = new Map>>(); + this.defaultPreferencesEditorModels = new ResourceMap>>(); this.editorGroupService.onEditorsChanged(() => { const activeEditorInput = this.editorService.getActiveEditorInput(); if (activeEditorInput instanceof PreferencesEditorInput) { diff --git a/src/vs/workbench/parts/preferences/common/preferences.ts b/src/vs/workbench/parts/preferences/common/preferences.ts index 11206bc23a8..44b0ee1fcd9 100644 --- a/src/vs/workbench/parts/preferences/common/preferences.ts +++ b/src/vs/workbench/parts/preferences/common/preferences.ts @@ -5,7 +5,6 @@ import URI from 'vs/base/common/uri'; import { TPromise } from 'vs/base/common/winjs.base'; -import { SimpleMap as Map } from 'vs/base/common/map'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; import { RawContextKey } from 'vs/platform/contextkey/common/contextkey'; import { IEditor } from 'vs/platform/editor/common/editor'; diff --git a/src/vs/workbench/parts/preferences/common/preferencesModels.ts b/src/vs/workbench/parts/preferences/common/preferencesModels.ts index c35903695e2..280187fab46 100644 --- a/src/vs/workbench/parts/preferences/common/preferencesModels.ts +++ b/src/vs/workbench/parts/preferences/common/preferencesModels.ts @@ -6,7 +6,6 @@ import * as nls from 'vs/nls'; import * as strings from 'vs/base/common/strings'; import { assign } from 'vs/base/common/objects'; -import { SimpleMap as Map } from 'vs/base/common/map'; import { distinct } from 'vs/base/common/arrays'; import URI from 'vs/base/common/uri'; import { IReference } from 'vs/base/common/lifecycle'; diff --git a/src/vs/workbench/parts/search/common/searchModel.ts b/src/vs/workbench/parts/search/common/searchModel.ts index 2a9c6145928..48ed4a14de6 100644 --- a/src/vs/workbench/parts/search/common/searchModel.ts +++ b/src/vs/workbench/parts/search/common/searchModel.ts @@ -11,7 +11,7 @@ import { RunOnceScheduler } from 'vs/base/common/async'; import { IDisposable, Disposable } from 'vs/base/common/lifecycle'; import { TPromise, PPromise } from 'vs/base/common/winjs.base'; import URI from 'vs/base/common/uri'; -import { SimpleMap } from 'vs/base/common/map'; +import { values, ResourceMap } from 'vs/base/common/map'; import Event, { Emitter, fromPromise, stopwatch, any } from 'vs/base/common/event'; import { ISearchService, ISearchProgressItem, ISearchComplete, ISearchQuery, IPatternInfo, IFileMatch } from 'vs/platform/search/common/search'; import { ReplacePattern } from 'vs/platform/search/common/replace'; @@ -125,7 +125,7 @@ export class FileMatch extends Disposable { private _resource: URI; private _model: IModel; private _modelListener: IDisposable; - private _matches: SimpleMap; + private _matches: Map; private _removedMatches: Set; private _selectedMatch: Match; @@ -136,7 +136,7 @@ export class FileMatch extends Disposable { @IModelService private modelService: IModelService, @IReplaceService private replaceService: IReplaceService) { super(); this._resource = this.rawMatch.resource; - this._matches = new SimpleMap(); + this._matches = new Map(); this._removedMatches = new Set(); this._updateScheduler = new RunOnceScheduler(this.updateMatchesForModel.bind(this), 250); @@ -197,7 +197,7 @@ export class FileMatch extends Disposable { if (!this._model) { return; } - this._matches = new SimpleMap(); + this._matches = new Map(); let matches = this._model .findMatches(this._query.pattern, this._model.getFullModelRange(), this._query.isRegExp, this._query.isCaseSensitive, this._query.isWordMatch ? this._query.wordSeparators : null, false, this._maxResults); @@ -211,7 +211,7 @@ export class FileMatch extends Disposable { endLineNumber: lineNumber, endColumn: this._model.getLineMaxColumn(lineNumber) }; - const oldMatches = this._matches.values().filter(match => match.range().startLineNumber === lineNumber); + const oldMatches = values(this._matches).filter(match => match.range().startLineNumber === lineNumber); oldMatches.forEach(match => this._matches.delete(match.id())); const matches = this._model.findMatches(this._query.pattern, range, this._query.isRegExp, this._query.isCaseSensitive, this._query.isWordMatch ? this._query.wordSeparators : null, false, this._maxResults); @@ -257,7 +257,7 @@ export class FileMatch extends Disposable { } public matches(): Match[] { - return this._matches.values(); + return values(this._matches); } public remove(match: Match): void { @@ -339,8 +339,8 @@ export class SearchResult extends Disposable { private _onChange = this._register(new Emitter()); public onChange: Event = this._onChange.event; - private _fileMatches: SimpleMap; - private _unDisposedFileMatches: SimpleMap; + private _fileMatches: ResourceMap; + private _unDisposedFileMatches: ResourceMap; private _query: IPatternInfo = null; private _maxResults: number; private _showHighlights: boolean; @@ -351,8 +351,8 @@ export class SearchResult extends Disposable { constructor(private _searchModel: SearchModel, @IReplaceService private replaceService: IReplaceService, @ITelemetryService private telemetryService: ITelemetryService, @IInstantiationService private instantiationService: IInstantiationService) { super(); - this._fileMatches = new SimpleMap(); - this._unDisposedFileMatches = new SimpleMap(); + this._fileMatches = new ResourceMap(); + this._unDisposedFileMatches = new ResourceMap(); this._rangeHighlightDecorations = this.instantiationService.createInstance(RangeHighlightDecorations); } -- GitLab From e26bdefbde037ab69857922398f80995bd933d12 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Mon, 12 Jun 2017 13:05:17 +0200 Subject: [PATCH 0716/1347] Fix #28129 --- .../workbench/parts/preferences/browser/preferencesService.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/preferences/browser/preferencesService.ts b/src/vs/workbench/parts/preferences/browser/preferencesService.ts index 7c7461d4a69..3cd438f300f 100644 --- a/src/vs/workbench/parts/preferences/browser/preferencesService.ts +++ b/src/vs/workbench/parts/preferences/browser/preferencesService.ts @@ -229,7 +229,7 @@ export class PreferencesService extends Disposable implements IPreferencesServic const resource = this.getEditableSettingsURI(configurationTarget); const editableSettingsEmptyContent = this.getEmptyEditableSettingsContent(configurationTarget); return this.createIfNotExists(resource, editableSettingsEmptyContent) - .then(() => this.editorService.createInput({ resource })); + .then(() => this.editorService.createInput({ resource })); } private createEditableSettingsEditorModel(configurationTarget: ConfigurationTarget): TPromise { -- GitLab From 2de8e6550d9f82785af63f57cb0a9f8222b17015 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Mon, 12 Jun 2017 13:06:20 +0200 Subject: [PATCH 0717/1347] fix npe in config service --- .../services/configuration/node/configurationService.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/vs/workbench/services/configuration/node/configurationService.ts b/src/vs/workbench/services/configuration/node/configurationService.ts index 9ea368f587b..7001b1bb00d 100644 --- a/src/vs/workbench/services/configuration/node/configurationService.ts +++ b/src/vs/workbench/services/configuration/node/configurationService.ts @@ -246,6 +246,10 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } public handleWorkspaceFileEvents(event: FileChangesEvent): void { + if (!this.workspace) { + return; // only enabled when we have a known workspace + } + const events = event.changes; let affectedByChanges = false; @@ -303,6 +307,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp return new ScopedConfigModel(content.value, content.resource.toString(), matches[1]); } } + return new ConfigModel(null); } -- GitLab From 9d81318248189c1f034868af0147ef9fd9e053c2 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Mon, 12 Jun 2017 13:16:22 +0200 Subject: [PATCH 0718/1347] #27458 Move fileResultsNavigation to files namespace --- .../{ => parts/files}/browser/fileResultsNavigation.ts | 0 src/vs/workbench/parts/markers/browser/markersPanel.ts | 2 +- src/vs/workbench/parts/search/browser/searchViewlet.ts | 2 +- 3 files changed, 2 insertions(+), 2 deletions(-) rename src/vs/workbench/{ => parts/files}/browser/fileResultsNavigation.ts (100%) diff --git a/src/vs/workbench/browser/fileResultsNavigation.ts b/src/vs/workbench/parts/files/browser/fileResultsNavigation.ts similarity index 100% rename from src/vs/workbench/browser/fileResultsNavigation.ts rename to src/vs/workbench/parts/files/browser/fileResultsNavigation.ts diff --git a/src/vs/workbench/parts/markers/browser/markersPanel.ts b/src/vs/workbench/parts/markers/browser/markersPanel.ts index 3916e125640..53c9bfdff05 100644 --- a/src/vs/workbench/parts/markers/browser/markersPanel.ts +++ b/src/vs/workbench/parts/markers/browser/markersPanel.ts @@ -36,7 +36,7 @@ import { IContextKeyService, IContextKey } from 'vs/platform/contextkey/common/c import { IListService } from 'vs/platform/list/browser/listService'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { ICommonCodeEditor } from 'vs/editor/common/editorCommon'; -import FileResultsNavigation from 'vs/workbench/browser/fileResultsNavigation'; +import FileResultsNavigation from 'vs/workbench/parts/files/browser/fileResultsNavigation'; import { debounceEvent } from 'vs/base/common/event'; import { attachListStyler } from 'vs/platform/theme/common/styler'; diff --git a/src/vs/workbench/parts/search/browser/searchViewlet.ts b/src/vs/workbench/parts/search/browser/searchViewlet.ts index 94d852b0b3a..f42a3d96708 100644 --- a/src/vs/workbench/parts/search/browser/searchViewlet.ts +++ b/src/vs/workbench/parts/search/browser/searchViewlet.ts @@ -56,7 +56,7 @@ import * as Constants from 'vs/workbench/parts/search/common/constants'; import { IListService } from 'vs/platform/list/browser/listService'; import { IThemeService, ITheme, ICssStyleCollector, registerThemingParticipant } from 'vs/platform/theme/common/themeService'; import { editorFindMatchHighlight, diffInserted, diffRemoved, diffInsertedOutline, diffRemovedOutline, activeContrastBorder } from 'vs/platform/theme/common/colorRegistry'; -import FileResultsNavigation from 'vs/workbench/browser/fileResultsNavigation'; +import FileResultsNavigation from 'vs/workbench/parts/files/browser/fileResultsNavigation'; import { attachListStyler } from 'vs/platform/theme/common/styler'; import { IOutputService } from 'vs/workbench/parts/output/common/output'; import { Color } from 'vs/base/common/color'; -- GitLab From 2c85446dc85f8eaf96e101a78abd062a4094d7cd Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Mon, 12 Jun 2017 14:38:15 +0200 Subject: [PATCH 0719/1347] Fixes #28308: Use role="dialog" combined with role="document" in Alt+F1 widget --- .../electron-browser/accessibility.ts | 22 ++++++++++++------- 1 file changed, 14 insertions(+), 8 deletions(-) diff --git a/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.ts b/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.ts index 1147eef15c2..d586fa34b38 100644 --- a/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.ts +++ b/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.ts @@ -78,6 +78,7 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { private _editor: ICodeEditor; private _domNode: FastDomNode; + private _contentDomNode: FastDomNode; private _isVisible: boolean; private _isVisibleKey: IContextKey; @@ -99,8 +100,13 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { this._domNode.setWidth(AccessibilityHelpWidget.WIDTH); this._domNode.setHeight(AccessibilityHelpWidget.HEIGHT); this._domNode.setDisplay('none'); - this._domNode.setAttribute('role', 'tooltip'); + this._domNode.setAttribute('role', 'dialog'); this._domNode.setAttribute('aria-hidden', 'true'); + + this._contentDomNode = createFastDomNode(document.createElement('div')); + this._contentDomNode.setAttribute('role', 'document'); + this._domNode.appendChild(this._contentDomNode); + this._isVisible = false; this._register(this._editor.onDidLayoutChange(() => { @@ -110,7 +116,7 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { })); // Intentionally not configurable! - this._register(dom.addStandardDisposableListener(this._domNode.domNode, 'keydown', (e) => { + this._register(dom.addStandardDisposableListener(this._contentDomNode.domNode, 'keydown', (e) => { if (!this._isVisible) { return; } @@ -137,7 +143,7 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { } })); - this.onblur(this._domNode.domNode, () => { + this.onblur(this._contentDomNode.domNode, () => { this.hide(); }); @@ -172,9 +178,9 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { this._layout(); this._domNode.setDisplay('block'); this._domNode.setAttribute('aria-hidden', 'false'); - this._domNode.domNode.tabIndex = 0; + this._contentDomNode.domNode.tabIndex = 0; this._buildContent(); - this._domNode.domNode.focus(); + this._contentDomNode.domNode.focus(); } private _descriptionForCommand(commandId: string, msg: string, noKbMsg: string): string { @@ -246,7 +252,7 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { text += '\n\n' + nls.localize('outroMsg', "You can dismiss this tooltip and return to the editor by pressing Escape or Shift+Escape."); - this._domNode.domNode.appendChild(renderHtml({ + this._contentDomNode.domNode.appendChild(renderHtml({ formattedText: text })); } @@ -259,8 +265,8 @@ class AccessibilityHelpWidget extends Widget implements IOverlayWidget { this._isVisibleKey.reset(); this._domNode.setDisplay('none'); this._domNode.setAttribute('aria-hidden', 'true'); - this._domNode.domNode.tabIndex = -1; - dom.clearNode(this._domNode.domNode); + this._contentDomNode.domNode.tabIndex = -1; + dom.clearNode(this._contentDomNode.domNode); this._editor.focus(); } -- GitLab From 5af0b38b91a969b6ffe401de645387c3ccd96a6f Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Mon, 12 Jun 2017 15:01:13 +0200 Subject: [PATCH 0720/1347] Fixes #27740: Tasks: Unclear property descriptions in tasks.json --- src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts index 1e2aadffdb3..554f6a9bc39 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts @@ -48,7 +48,7 @@ const terminal: IJSONSchema = { default: { reveal: 'always' }, - description: nls.localize('JsonSchema.tasks.terminal', 'Describe how the terminal used to execute a task behaves.'), + description: nls.localize('JsonSchema.tasks.terminal', 'Configures the terminal that is used to execute the task.'), properties: { echo: { type: 'boolean', -- GitLab From def13c6d788648100648830b4864b31264e41669 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Mon, 12 Jun 2017 15:29:31 +0200 Subject: [PATCH 0721/1347] better workspace format --- src/vs/platform/workspace/common/workspace.ts | 22 ++++++------- .../electron-browser/main.contribution.ts | 32 +++++++++---------- 2 files changed, 25 insertions(+), 29 deletions(-) diff --git a/src/vs/platform/workspace/common/workspace.ts b/src/vs/platform/workspace/common/workspace.ts index 8e0747fa8de..848ecb6b322 100644 --- a/src/vs/platform/workspace/common/workspace.ts +++ b/src/vs/platform/workspace/common/workspace.ts @@ -122,7 +122,7 @@ export class Workspace implements IWorkspace { } } -type IWorkspaceConfiguration = { path: string; folders: string[]; }[]; +type IWorkspaceConfiguration = { [rootFolder: string]: { folders: string[]; } }; export class WorkspaceContextService implements IWorkspaceContextService { @@ -161,18 +161,14 @@ export class WorkspaceContextService implements IWorkspaceContextService { // Resovled configured folders for workspace let configuredFolders: URI[] = [this.workspace.resource]; const config = this.configurationService.getConfiguration('workspace'); - if (Array.isArray(config)) { - for (let i = 0; i < config.length; i++) { - const targetWorkspace = config[i]; - if (targetWorkspace.path === this.workspace.resource.toString()) { - const additionalFolders = targetWorkspace.folders - .map(f => URI.parse(f)) - .filter(r => r.scheme === Schemas.file); // only support files for now - - configuredFolders.push(...additionalFolders); - - break; - } + if (config) { + const workspaceConfig = config[this.workspace.resource.toString()]; + if (workspaceConfig) { + const additionalFolders = workspaceConfig.folders + .map(f => URI.parse(f)) + .filter(r => r.scheme === Schemas.file); // only support files for now + + configuredFolders.push(...additionalFolders); } } diff --git a/src/vs/workbench/electron-browser/main.contribution.ts b/src/vs/workbench/electron-browser/main.contribution.ts index 2cbc72f32ec..380b33dc7e8 100644 --- a/src/vs/workbench/electron-browser/main.contribution.ts +++ b/src/vs/workbench/electron-browser/main.contribution.ts @@ -360,29 +360,29 @@ configurationRegistry.registerConfiguration({ }); // Configuration: Workspace -configurationRegistry.registerConfiguration({ +configurationRegistry.registerConfiguration({ 'id': 'workspace', 'order': 10000, 'title': nls.localize('workspaceConfigurationTitle', "Workspace"), 'type': 'object', 'properties': { 'workspace': { - 'type': 'array', - 'title': nls.localize('workspaces.title', "Folder configuration of the workspace"), - 'items': { - 'required': ['path'], - 'type': 'object', - 'defaultSnippets': [{ 'body': { 'path': '$1', 'folders': ['$2'] } }], - 'properties': { - 'path': { - 'type': 'string', - 'description': nls.localize('workspaces.path', "Path of the folder to configure folders for"), - }, - 'folders': { - 'description': nls.localize('workspaces.additionalFolders', "Folders of this workspace"), - 'type': 'array' + 'type': 'object', + 'description': nls.localize('workspaces.title', "Folder configuration of the workspace"), + 'additionalProperties': { + 'anyOf': [{ + 'type': 'object', + 'description': nls.localize('files.exclude.boolean', "The glob pattern to match file paths against. Set to true or false to enable or disable the pattern."), + 'properties': { + 'folders': { + 'description': nls.localize('workspaces.additionalFolders', "Folders of this workspace"), + 'type': 'array', + 'items': { + 'type': 'string' + } + } } - } + }] } } } -- GitLab From 7c1c21c15870d56b1bbc8dcccda9cb2f56f428df Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Mon, 12 Jun 2017 15:39:39 +0200 Subject: [PATCH 0722/1347] start with a step back and use IWorkspace where needed, nuke workspace context service from ext host, #28526 --- src/vs/workbench/api/node/extHost.api.impl.ts | 4 +-- src/vs/workbench/api/node/extHost.protocol.ts | 4 +-- .../api/node/extHostExtensionService.ts | 25 ++++++++----------- .../electron-browser/extensionHost.ts | 4 +-- src/vs/workbench/node/extensionHostMain.ts | 24 ++++++------------ 5 files changed, 21 insertions(+), 40 deletions(-) diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index b9b4746182f..810e4cf1f82 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -41,7 +41,6 @@ import EditorCommon = require('vs/editor/common/editorCommon'); import { IExtensionDescription } from 'vs/platform/extensions/common/extensions'; import { ExtHostExtensionService } from 'vs/workbench/api/node/extHostExtensionService'; import { TPromise } from 'vs/base/common/winjs.base'; -import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { CancellationTokenSource } from 'vs/base/common/cancellation'; import * as vscode from 'vscode'; @@ -72,7 +71,6 @@ export function createApiFactory( initData: IInitData, threadService: IThreadService, extensionService: ExtHostExtensionService, - contextService: IWorkspaceContextService, telemetryService: ITelemetryService ): IExtensionApiFactory { @@ -101,7 +99,7 @@ export function createApiFactory( const extHostStatusBar = new ExtHostStatusBar(threadService); const extHostProgress = new ExtHostProgress(threadService.get(MainContext.MainThreadProgress)); const extHostOutputService = new ExtHostOutputService(threadService); - const workspacePath = contextService.hasWorkspace() ? contextService.getWorkspace().resource.fsPath : undefined; + const workspacePath = initData.workspace ? initData.workspace.resource.fsPath : undefined; const extHostWorkspace = new ExtHostWorkspace(threadService, workspacePath); const extHostLanguages = new ExtHostLanguages(threadService); diff --git a/src/vs/workbench/api/node/extHost.protocol.ts b/src/vs/workbench/api/node/extHost.protocol.ts index 6d92223c932..e68efd0e513 100644 --- a/src/vs/workbench/api/node/extHost.protocol.ts +++ b/src/vs/workbench/api/node/extHost.protocol.ts @@ -60,9 +60,7 @@ export interface IEnvironment { export interface IInitData { parentPid: number; environment: IEnvironment; - contextService: { - workspace: IWorkspace; - }; + workspace: IWorkspace; extensions: IExtensionDescription[]; configuration: IWorkspaceConfigurationValues; telemetryInfo: ITelemetryInfo; diff --git a/src/vs/workbench/api/node/extHostExtensionService.ts b/src/vs/workbench/api/node/extHostExtensionService.ts index ae75796c7e2..aeb68c62eda 100644 --- a/src/vs/workbench/api/node/extHostExtensionService.ts +++ b/src/vs/workbench/api/node/extHostExtensionService.ts @@ -15,7 +15,7 @@ import { ExtHostStorage } from 'vs/workbench/api/node/extHostStorage'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { createApiFactory, initializeExtensionApi } from 'vs/workbench/api/node/extHost.api.impl'; import { IThreadService } from 'vs/workbench/services/thread/common/threadService'; -import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { IWorkspace } from 'vs/platform/workspace/common/workspace'; import { MainContext, MainProcessExtensionServiceShape, IEnvironment, IInitData } from './extHost.protocol'; import { createHash } from 'crypto'; @@ -103,14 +103,14 @@ class ExtensionMemento implements IExtensionMemento { class ExtensionStoragePath { - private readonly _contextService: IWorkspaceContextService; + private readonly _workspace: IWorkspace; private readonly _environment: IEnvironment; private readonly _ready: TPromise; private _value: string; - constructor(contextService: IWorkspaceContextService, environment: IEnvironment) { - this._contextService = contextService; + constructor(workspace: IWorkspace, environment: IEnvironment) { + this._workspace = workspace; this._environment = environment; this._ready = this._getOrCreateWorkspaceStoragePath().then(value => this._value = value); } @@ -127,16 +127,13 @@ class ExtensionStoragePath { } private _getOrCreateWorkspaceStoragePath(): TPromise { - - const workspace = this._contextService.getWorkspace(); - - if (!workspace) { + if (!this._workspace) { return TPromise.as(undefined); } const storageName = createHash('md5') - .update(workspace.resource.fsPath) - .update(workspace.uid ? workspace.uid.toString() : '') + .update(this._workspace.resource.fsPath) + .update(this._workspace.uid ? this._workspace.uid.toString() : '') .digest('hex'); const storagePath = join(this._environment.appSettingsHome, 'workspaceStorage', storageName); @@ -171,23 +168,21 @@ export class ExtHostExtensionService extends AbstractExtensionService this._triggerOnReady()); } diff --git a/src/vs/workbench/electron-browser/extensionHost.ts b/src/vs/workbench/electron-browser/extensionHost.ts index 2431281d98e..6b99c054bb7 100644 --- a/src/vs/workbench/electron-browser/extensionHost.ts +++ b/src/vs/workbench/electron-browser/extensionHost.ts @@ -259,9 +259,7 @@ export class ExtensionHostProcessWorker { enableProposedApiForAll: !this.environmentService.isBuilt || (!!this.environmentService.extensionDevelopmentPath && product.nameLong.indexOf('Insiders') >= 0), enableProposedApiFor: this.environmentService.args['enable-proposed-api'] || [] }, - contextService: { - workspace: this.contextService.getWorkspace() - }, + workspace: this.contextService.getWorkspace(), extensions: extensionDescriptions, configuration: this.configurationService.values(), telemetryInfo diff --git a/src/vs/workbench/node/extensionHostMain.ts b/src/vs/workbench/node/extensionHostMain.ts index 6d38c79e651..7f4aa8b0094 100644 --- a/src/vs/workbench/node/extensionHostMain.ts +++ b/src/vs/workbench/node/extensionHostMain.ts @@ -15,10 +15,9 @@ import { ExtHostThreadService } from 'vs/workbench/services/thread/common/extHos import { QueryType, ISearchQuery } from 'vs/platform/search/common/search'; import { DiskSearch } from 'vs/workbench/services/search/node/searchService'; import { RemoteTelemetryService } from 'vs/workbench/api/node/extHostTelemetry'; -import { IWorkspaceContextService, WorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import { IInitData, IEnvironment, MainContext } from 'vs/workbench/api/node/extHost.protocol'; import * as errors from 'vs/base/common/errors'; -import { NullConfigurationService } from "vs/workbench/services/configuration/node/nullConfigurationService"; +import { IWorkspace } from "vs/platform/workspace/common/workspace"; const nativeExit = process.exit.bind(process); process.exit = function () { @@ -36,25 +35,19 @@ interface ITestRunner { export class ExtensionHostMain { private _isTerminating: boolean = false; - private _contextService: IWorkspaceContextService; private _diskSearch: DiskSearch; + private _workspace: IWorkspace; private _environment: IEnvironment; private _extensionService: ExtHostExtensionService; constructor(remoteCom: IRemoteCom, initData: IInitData) { - // services this._environment = initData.environment; + this._workspace = initData.workspace; - const workspaceRaw = initData.contextService.workspace; - let workspace: Workspace; - if (workspaceRaw) { - workspace = new Workspace(workspaceRaw.resource, workspaceRaw.uid, workspaceRaw.name); - } - this._contextService = new WorkspaceContextService(new NullConfigurationService(), workspace); //TODO@Ben implement for exthost - + // services const threadService = new ExtHostThreadService(remoteCom); const telemetryService = new RemoteTelemetryService('pluginHostTelemetry', threadService); - this._extensionService = new ExtHostExtensionService(initData, threadService, telemetryService, this._contextService); + this._extensionService = new ExtHostExtensionService(initData, threadService, telemetryService); // Error forwarding const mainThreadErrors = threadService.get(MainContext.MainThreadErrors); @@ -108,12 +101,11 @@ export class ExtensionHostMain { } private handleWorkspaceContainsEagerExtensions(): TPromise { - let workspace = this._contextService.getWorkspace(); - if (!workspace || !workspace.resource) { + if (!this._workspace || !this._workspace.resource) { return TPromise.as(null); } - const folderPath = workspace.resource.fsPath; + const folderPath = this._workspace.resource.fsPath; const desiredFilesMap: { [filename: string]: boolean; @@ -143,7 +135,7 @@ export class ExtensionHostMain { } const query: ISearchQuery = { - folderResources: [workspace.resource], + folderResources: [this._workspace.resource], type: QueryType.File, maxResults: 1, includePattern: { [p]: true } -- GitLab From a65a1ba8c620558e3e1c3c878d914f028c1ba80e Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Mon, 12 Jun 2017 15:50:50 +0200 Subject: [PATCH 0723/1347] Fixes Microsoft/monaco-editor#453: trigger gotoLine action contiuously emit errors --- src/vs/base/parts/quickopen/browser/quickOpenWidget.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/vs/base/parts/quickopen/browser/quickOpenWidget.ts b/src/vs/base/parts/quickopen/browser/quickOpenWidget.ts index 54953ca6c8e..3cf4a81e4c5 100644 --- a/src/vs/base/parts/quickopen/browser/quickOpenWidget.ts +++ b/src/vs/base/parts/quickopen/browser/quickOpenWidget.ts @@ -99,6 +99,7 @@ export class QuickOpenWidget implements IModelProvider { private static MAX_WIDTH = 600; // Max total width of quick open widget private static MAX_ITEMS_HEIGHT = 20 * 22; // Max height of item list below input field + private isDisposed: boolean; private options: IQuickOpenOptions; private builder: Builder; private tree: ITree; @@ -123,6 +124,7 @@ export class QuickOpenWidget implements IModelProvider { private renderer: Renderer; constructor(container: HTMLElement, callbacks: IQuickOpenCallbacks, options: IQuickOpenOptions, usageLogger?: IQuickOpenUsageLogger) { + this.isDisposed = false; this.toUnbind = []; this.container = container; this.callbacks = callbacks; @@ -944,6 +946,9 @@ export class QuickOpenWidget implements IModelProvider { if (!this.isLoosingFocus) { return; } + if (this.isDisposed) { + return; + } const veto = this.callbacks.onFocusLost && this.callbacks.onFocusLost(); if (!veto) { @@ -953,6 +958,7 @@ export class QuickOpenWidget implements IModelProvider { } public dispose(): void { + this.isDisposed = true; this.toUnbind = dispose(this.toUnbind); this.progressBar.dispose(); -- GitLab From 24fbd1f5d2ee7615c62c6e175929ddf360007176 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Mon, 12 Jun 2017 16:05:12 +0200 Subject: [PATCH 0724/1347] add $acceptWorkspaceData to push new info about open folders, #28526 --- .../electron-browser/mainThreadWorkspace.ts | 46 ++++++++++--------- src/vs/workbench/api/node/extHost.api.impl.ts | 3 +- src/vs/workbench/api/node/extHost.protocol.ts | 7 ++- src/vs/workbench/api/node/extHostWorkspace.ts | 18 ++++++-- .../api/extHostWorkspace.test.ts | 5 +- 5 files changed, 49 insertions(+), 30 deletions(-) diff --git a/src/vs/workbench/api/electron-browser/mainThreadWorkspace.ts b/src/vs/workbench/api/electron-browser/mainThreadWorkspace.ts index 707349e5a93..8cd8b7c62e1 100644 --- a/src/vs/workbench/api/electron-browser/mainThreadWorkspace.ts +++ b/src/vs/workbench/api/electron-browser/mainThreadWorkspace.ts @@ -13,39 +13,41 @@ import { ITextFileService } from 'vs/workbench/services/textfile/common/textfile import { ICommonCodeEditor, isCommonCodeEditor } from 'vs/editor/common/editorCommon'; import { bulkEdit, IResourceEdit } from 'vs/editor/common/services/bulkEdit'; import { TPromise } from 'vs/base/common/winjs.base'; -import { Uri } from 'vscode'; -import { MainThreadWorkspaceShape } from '../node/extHost.protocol'; +import { MainThreadWorkspaceShape, ExtHostWorkspaceShape, ExtHostContext } from '../node/extHost.protocol'; import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; import { IFileService } from 'vs/platform/files/common/files'; +import { IThreadService } from 'vs/workbench/services/thread/common/threadService'; +import { IDisposable } from 'vs/base/common/lifecycle'; + export class MainThreadWorkspace extends MainThreadWorkspaceShape { - private _activeSearches: { [id: number]: TPromise } = Object.create(null); - private _searchService: ISearchService; - private _contextService: IWorkspaceContextService; - private _textFileService: ITextFileService; - private _editorService: IWorkbenchEditorService; - private _textModelResolverService: ITextModelResolverService; - private _fileService: IFileService; + private readonly _toDispose: IDisposable[] = []; + private readonly _activeSearches: { [id: number]: TPromise } = Object.create(null); + private readonly _proxy: ExtHostWorkspaceShape; constructor( - @ISearchService searchService: ISearchService, - @IWorkspaceContextService contextService: IWorkspaceContextService, - @ITextFileService textFileService: ITextFileService, - @IWorkbenchEditorService editorService: IWorkbenchEditorService, - @ITextModelResolverService textModelResolverService: ITextModelResolverService, - @IFileService fileService: IFileService + @ISearchService private readonly _searchService: ISearchService, + @IWorkspaceContextService private readonly _contextService: IWorkspaceContextService, + @ITextFileService private readonly _textFileService: ITextFileService, + @IWorkbenchEditorService private readonly _editorService: IWorkbenchEditorService, + @ITextModelResolverService private readonly _textModelResolverService: ITextModelResolverService, + @IFileService private readonly _fileService: IFileService, + @IThreadService threadService: IThreadService ) { super(); + this._proxy = threadService.get(ExtHostContext.ExtHostWorkspace); + this._contextService.onDidChangeFolders(this._onDidChangeWorkspace, this, this._toDispose); + } + + // --- workspace --- - this._searchService = searchService; - this._contextService = contextService; - this._textFileService = textFileService; - this._editorService = editorService; - this._fileService = fileService; - this._textModelResolverService = textModelResolverService; + private _onDidChangeWorkspace(folders: URI[]): void { + this._proxy.$acceptWorkspaceData(folders); } + // --- search --- + $startSearch(include: string, exclude: string, maxResults: number, requestId: number): Thenable { const workspace = this._contextService.getWorkspace(); if (!workspace) { @@ -84,6 +86,8 @@ export class MainThreadWorkspace extends MainThreadWorkspaceShape { return undefined; } + // --- save & edit resources --- + $saveAll(includeUntitled?: boolean): Thenable { return this._textFileService.saveAll(includeUntitled).then(result => { return result.results.every(each => each.success === true); diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index 810e4cf1f82..b450e6538e6 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -91,6 +91,7 @@ export function createApiFactory( const extHostTerminalService = col.define(ExtHostContext.ExtHostTerminalService).set(new ExtHostTerminalService(threadService)); const extHostSCM = col.define(ExtHostContext.ExtHostSCM).set(new ExtHostSCM(threadService, extHostCommands)); const extHostTask = col.define(ExtHostContext.ExtHostTask).set(new ExtHostTask(threadService)); + const extHostWorkspace = col.define(ExtHostContext.ExtHostWorkspace).set(new ExtHostWorkspace(threadService, initData.workspace && [initData.workspace.resource])); col.define(ExtHostContext.ExtHostExtensionService).set(extensionService); col.finish(false, threadService); @@ -99,8 +100,6 @@ export function createApiFactory( const extHostStatusBar = new ExtHostStatusBar(threadService); const extHostProgress = new ExtHostProgress(threadService.get(MainContext.MainThreadProgress)); const extHostOutputService = new ExtHostOutputService(threadService); - const workspacePath = initData.workspace ? initData.workspace.resource.fsPath : undefined; - const extHostWorkspace = new ExtHostWorkspace(threadService, workspacePath); const extHostLanguages = new ExtHostLanguages(threadService); // Register API-ish commands diff --git a/src/vs/workbench/api/node/extHost.protocol.ts b/src/vs/workbench/api/node/extHost.protocol.ts index e68efd0e513..393e50579ff 100644 --- a/src/vs/workbench/api/node/extHost.protocol.ts +++ b/src/vs/workbench/api/node/extHost.protocol.ts @@ -404,6 +404,10 @@ export abstract class ExtHostTreeViewsShape { $getChildren(treeViewId: string, treeItemHandle: number): TPromise { throw ni(); } } +export abstract class ExtHostWorkspaceShape { + $acceptWorkspaceData(folders: URI[]): void { throw ni(); } +} + export abstract class ExtHostExtensionServiceShape { $activateExtension(extensionDescription: IExtensionDescription): TPromise { throw ni(); } } @@ -524,5 +528,6 @@ export const ExtHostContext = { ExtHostExtensionService: createExtId('ExtHostExtensionService', ExtHostExtensionServiceShape), ExtHostTerminalService: createExtId('ExtHostTerminalService', ExtHostTerminalServiceShape), ExtHostSCM: createExtId('ExtHostSCM', ExtHostSCMShape), - ExtHostTask: createExtId('ExtHostTask', ExtHostTaskShape) + ExtHostTask: createExtId('ExtHostTask', ExtHostTaskShape), + ExtHostWorkspace: createExtId('ExtHostWorkspace', ExtHostWorkspaceShape), }; diff --git a/src/vs/workbench/api/node/extHostWorkspace.ts b/src/vs/workbench/api/node/extHostWorkspace.ts index 38024197279..c56bf79591b 100644 --- a/src/vs/workbench/api/node/extHostWorkspace.ts +++ b/src/vs/workbench/api/node/extHostWorkspace.ts @@ -6,26 +6,30 @@ import URI from 'vs/base/common/uri'; import { normalize } from 'vs/base/common/paths'; +import { isFalsyOrEmpty } from 'vs/base/common/arrays'; import { relative } from 'path'; import { IThreadService } from 'vs/workbench/services/thread/common/threadService'; import { IResourceEdit } from 'vs/editor/common/services/bulkEdit'; import { TPromise } from 'vs/base/common/winjs.base'; import { fromRange, EndOfLine } from 'vs/workbench/api/node/extHostTypeConverters'; -import { MainContext, MainThreadWorkspaceShape } from './extHost.protocol'; +import { ExtHostWorkspaceShape, MainContext, MainThreadWorkspaceShape } from './extHost.protocol'; import * as vscode from 'vscode'; -export class ExtHostWorkspace { +export class ExtHostWorkspace extends ExtHostWorkspaceShape { private static _requestIdPool = 0; private _proxy: MainThreadWorkspaceShape; private _workspacePath: string; - constructor(threadService: IThreadService, workspacePath: string) { + constructor(threadService: IThreadService, folders: URI[]) { + super(); this._proxy = threadService.get(MainContext.MainThreadWorkspace); - this._workspacePath = workspacePath; + this._workspacePath = isFalsyOrEmpty(folders) ? undefined : folders[0].fsPath; } + // --- workspace --- + getPath(): string { return this._workspacePath; } @@ -55,6 +59,12 @@ export class ExtHostWorkspace { return normalize(result); } + $acceptWorkspaceData(folders: URI[]): void { + // todo@joh do something, align with ctor URI[] vs IWorkspace + } + + // --- search --- + findFiles(include: string, exclude: string, maxResults?: number, token?: vscode.CancellationToken): Thenable { const requestId = ExtHostWorkspace._requestIdPool++; const result = this._proxy.$startSearch(include, exclude, maxResults, requestId); diff --git a/src/vs/workbench/test/electron-browser/api/extHostWorkspace.test.ts b/src/vs/workbench/test/electron-browser/api/extHostWorkspace.test.ts index a6aee8f4070..413e9f14fb2 100644 --- a/src/vs/workbench/test/electron-browser/api/extHostWorkspace.test.ts +++ b/src/vs/workbench/test/electron-browser/api/extHostWorkspace.test.ts @@ -6,6 +6,7 @@ 'use strict'; import * as assert from 'assert'; +import URI from 'vs/base/common/uri'; import { ExtHostWorkspace } from 'vs/workbench/api/node/extHostWorkspace'; import { TestThreadService } from './testThreadService'; @@ -13,7 +14,7 @@ suite('ExtHostWorkspace', function () { test('asRelativePath', function () { - const ws = new ExtHostWorkspace(new TestThreadService(), '/Coding/Applications/NewsWoWBot'); + const ws = new ExtHostWorkspace(new TestThreadService(), [URI.file('/Coding/Applications/NewsWoWBot')]); assert.equal(ws.getRelativePath('/Coding/Applications/NewsWoWBot/bernd/das/brot'), 'bernd/das/brot'); assert.equal(ws.getRelativePath('/Apps/DartPubCache/hosted/pub.dartlang.org/convert-2.0.1/lib/src/hex.dart'), @@ -26,7 +27,7 @@ suite('ExtHostWorkspace', function () { test('asRelativePath, same paths, #11402', function () { const root = '/home/aeschli/workspaces/samples/docker'; const input = '/home/aeschli/workspaces/samples/docker'; - const ws = new ExtHostWorkspace(new TestThreadService(), root); + const ws = new ExtHostWorkspace(new TestThreadService(), [URI.file(root)]); assert.equal(ws.getRelativePath(input), input); -- GitLab From f6adea0241a50c5a5518e6ee46f9fe329afe1c7c Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Mon, 12 Jun 2017 16:38:19 +0200 Subject: [PATCH 0725/1347] Possible bug where method is not invoked (fixes #28527) --- src/vs/base/parts/quickopen/browser/quickOpenWidget.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/base/parts/quickopen/browser/quickOpenWidget.ts b/src/vs/base/parts/quickopen/browser/quickOpenWidget.ts index 3cf4a81e4c5..7a4cbcf5a2d 100644 --- a/src/vs/base/parts/quickopen/browser/quickOpenWidget.ts +++ b/src/vs/base/parts/quickopen/browser/quickOpenWidget.ts @@ -420,7 +420,7 @@ export class QuickOpenWidget implements IModelProvider { } public navigate(next: boolean, quickNavigate?: IQuickNavigateConfiguration): void { - if (this.isVisible) { + if (this.isVisible()) { // Transition into quick navigate mode if not yet done if (!this.quickNavigateConfiguration && quickNavigate) { -- GitLab From 9a4a9a4021e0daae03ba83a7bec302a7e7c381ce Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Mon, 12 Jun 2017 16:41:40 +0200 Subject: [PATCH 0726/1347] make asRelativePath work with multiple root folders, #28526 --- src/vs/workbench/api/node/extHostWorkspace.ts | 26 +++++++++++-------- .../api/extHostWorkspace.test.ts | 13 ++++++++++ 2 files changed, 28 insertions(+), 11 deletions(-) diff --git a/src/vs/workbench/api/node/extHostWorkspace.ts b/src/vs/workbench/api/node/extHostWorkspace.ts index c56bf79591b..7ec394f6913 100644 --- a/src/vs/workbench/api/node/extHostWorkspace.ts +++ b/src/vs/workbench/api/node/extHostWorkspace.ts @@ -19,19 +19,19 @@ export class ExtHostWorkspace extends ExtHostWorkspaceShape { private static _requestIdPool = 0; - private _proxy: MainThreadWorkspaceShape; - private _workspacePath: string; + private readonly _proxy: MainThreadWorkspaceShape; + private _workspaceFolders: URI[]; constructor(threadService: IThreadService, folders: URI[]) { super(); this._proxy = threadService.get(MainContext.MainThreadWorkspace); - this._workspacePath = isFalsyOrEmpty(folders) ? undefined : folders[0].fsPath; + this._workspaceFolders = folders; } // --- workspace --- getPath(): string { - return this._workspacePath; + return isFalsyOrEmpty(this._workspaceFolders) ? undefined : this._workspaceFolders[0].fsPath; } getRelativePath(pathOrUri: string | vscode.Uri): string { @@ -47,20 +47,24 @@ export class ExtHostWorkspace extends ExtHostWorkspaceShape { return path; } - if (!this._workspacePath) { + if (isFalsyOrEmpty(this._workspaceFolders)) { return normalize(path); } - let result = relative(this._workspacePath, path); - if (!result || result.indexOf('..') === 0) { - return normalize(path); + for (const { fsPath } of this._workspaceFolders) { + let result = relative(fsPath, path); + if (!result || result.indexOf('..') === 0) { + continue; + } + return normalize(result); } - return normalize(result); + return normalize(path); } - $acceptWorkspaceData(folders: URI[]): void { - // todo@joh do something, align with ctor URI[] vs IWorkspace + $acceptWorkspaceData(workspaceFolders: URI[]): void { + //TODO@joh equality-check, emit event etc. + this._workspaceFolders = workspaceFolders; } // --- search --- diff --git a/src/vs/workbench/test/electron-browser/api/extHostWorkspace.test.ts b/src/vs/workbench/test/electron-browser/api/extHostWorkspace.test.ts index 413e9f14fb2..36430d52357 100644 --- a/src/vs/workbench/test/electron-browser/api/extHostWorkspace.test.ts +++ b/src/vs/workbench/test/electron-browser/api/extHostWorkspace.test.ts @@ -22,6 +22,7 @@ suite('ExtHostWorkspace', function () { assert.equal(ws.getRelativePath(''), ''); assert.equal(ws.getRelativePath('/foo/bar'), '/foo/bar'); + assert.equal(ws.getRelativePath('in/out'), 'in/out'); }); test('asRelativePath, same paths, #11402', function () { @@ -33,6 +34,18 @@ suite('ExtHostWorkspace', function () { const input2 = '/home/aeschli/workspaces/samples/docker/a.file'; assert.equal(ws.getRelativePath(input2), 'a.file'); + }); + + test('asRelativePath, no workspace', function () { + const ws = new ExtHostWorkspace(new TestThreadService(), null); + assert.equal(ws.getRelativePath(''), ''); + assert.equal(ws.getRelativePath('/foo/bar'), '/foo/bar'); + }); + test('asRelativePath, multiple folders', function () { + const ws = new ExtHostWorkspace(new TestThreadService(), [URI.file('/Coding/One'), URI.file('/Coding/Two')]); + assert.equal(ws.getRelativePath('/Coding/One/file.txt'), 'file.txt'); + assert.equal(ws.getRelativePath('/Coding/Two/files/out.txt'), 'files/out.txt'); + assert.equal(ws.getRelativePath('/Coding/Two2/files/out.txt'), '/Coding/Two2/files/out.txt'); }); }); -- GitLab From 10e4c1508ba687511a5a97e4e516a717465b68a0 Mon Sep 17 00:00:00 2001 From: isidor Date: Mon, 12 Jun 2017 16:58:02 +0200 Subject: [PATCH 0727/1347] minor copy all polish #28197 --- .../workbench/parts/debug/electron-browser/repl.ts | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/repl.ts b/src/vs/workbench/parts/debug/electron-browser/repl.ts index 758f67e4571..505ce6118de 100644 --- a/src/vs/workbench/parts/debug/electron-browser/repl.ts +++ b/src/vs/workbench/parts/debug/electron-browser/repl.ts @@ -60,7 +60,7 @@ export interface IPrivateReplService { _serviceBrand: any; navigateHistory(previous: boolean): void; acceptReplInput(): void; - copyAllReplOutput(): void; + getVisibleContent(): string; } export class Repl extends Panel implements IPrivateReplService { @@ -232,7 +232,7 @@ export class Repl extends Panel implements IPrivateReplService { this.layout(this.dimension); } - public copyAllReplOutput(): void { + public getVisibleContent(): string { let text = ''; const navigator = this.tree.getNavigator(); // skip first navigator element - the root node @@ -242,7 +242,8 @@ export class Repl extends Panel implements IPrivateReplService { } text += navigator.current().toString(); } - clipboard.writeText(text); + + return text; } public layout(dimension: Dimension): void { @@ -399,14 +400,14 @@ export class ReplCopyAllAction extends EditorAction { constructor() { super({ - id: 'repl.action.copyall', - label: nls.localize('actions.repl.copyall', "Debug: Console Copy All"), + id: 'repl.action.copyAll', + label: nls.localize('actions.repl.copyAll', "Debug: Console Copy All"), alias: 'Debug Console Copy All', precondition: debug.CONTEXT_IN_DEBUG_REPL, }); } public run(accessor: ServicesAccessor, editor: ICommonCodeEditor): void | TPromise { - accessor.get(IPrivateReplService).copyAllReplOutput(); + clipboard.writeText(accessor.get(IPrivateReplService).getVisibleContent()); } } -- GitLab From 149e1a9e1585732ed339da427843f5d3fc8ab6ac Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Mon, 12 Jun 2017 17:23:22 +0200 Subject: [PATCH 0728/1347] #28538 Clean up onDidChangeFolders event --- src/vs/platform/workspace/common/workspace.ts | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/vs/platform/workspace/common/workspace.ts b/src/vs/platform/workspace/common/workspace.ts index 848ecb6b322..ef64497ddb4 100644 --- a/src/vs/platform/workspace/common/workspace.ts +++ b/src/vs/platform/workspace/common/workspace.ts @@ -128,7 +128,9 @@ export class WorkspaceContextService implements IWorkspaceContextService { public _serviceBrand: any; - private _onDidChangeFolders: Emitter; + private readonly _onDidChangeFolders: Emitter = new Emitter(); + public readonly onDidChangeFolders: Event = this._onDidChangeFolders.event; + private folders: URI[]; private toDispose: IDisposable[]; @@ -185,10 +187,6 @@ export class WorkspaceContextService implements IWorkspaceContextService { } } - public get onDidChangeFolders(): Event { - return this._onDidChangeFolders && this._onDidChangeFolders.event; //TODO@Sandeep sinon is a pita - } - public getFolders(): URI[] { return this.folders; } -- GitLab From bf198359e67d71214d5f1bf2c95e499896f3f593 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Mon, 12 Jun 2017 17:38:49 +0200 Subject: [PATCH 0729/1347] #28538 Do not initialize event again --- src/vs/platform/workspace/common/workspace.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/src/vs/platform/workspace/common/workspace.ts b/src/vs/platform/workspace/common/workspace.ts index ef64497ddb4..b74d8fd31d9 100644 --- a/src/vs/platform/workspace/common/workspace.ts +++ b/src/vs/platform/workspace/common/workspace.ts @@ -137,7 +137,6 @@ export class WorkspaceContextService implements IWorkspaceContextService { constructor(private configurationService: IConfigurationService, private workspace?: Workspace) { this.toDispose = []; - this._onDidChangeFolders = new Emitter(); this.toDispose.push(this._onDidChangeFolders); this.folders = workspace ? [workspace.resource] : []; -- GitLab From b46e2e0b7bdb7178d602f2d71fe1f4a1210ca0dd Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Mon, 12 Jun 2017 11:31:28 -0700 Subject: [PATCH 0730/1347] Add defaults for terminal selection These will be fallen back to when selection.background isn't defined. Fixes #28554 --- .../parts/terminal/electron-browser/media/xterm.css | 7 +++++++ .../parts/terminal/electron-browser/terminalPanel.ts | 4 +++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/xterm.css b/src/vs/workbench/parts/terminal/electron-browser/media/xterm.css index fe96994dcc9..66487fab214 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/media/xterm.css +++ b/src/vs/workbench/parts/terminal/electron-browser/media/xterm.css @@ -141,6 +141,13 @@ .monaco-workbench .panel.integrated-terminal .xterm .xterm-selection div { position: absolute; opacity: 0.5; + background-color: #808080; +} +.vs-dark .monaco-workbench .panel.integrated-terminal .xterm .xterm-selection div { + background-color: #808080; +} +.hc-black .monaco-workbench .panel.integrated-terminal .xterm .xterm-selection div { + background-color: #FFF; } .monaco-workbench .panel.integrated-terminal .xterm .xterm-bold { diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts index dc7558d33e9..3dae4ebd1bd 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts @@ -266,7 +266,9 @@ export class TerminalPanel extends Panel { // until proper color inverting is implemented to ensure contrast. const selectionColor = theme.getColor(selectionBackground); if (selectionColor) { - css += `.monaco-workbench .panel.integrated-terminal .xterm .xterm-selection div { background-color: ${selectionColor}; }`; + // selection.background is set to null when not defined by the + // theme, as such it's default values are defined in CSS. + css += `.monaco-workbench .panel.integrated-terminal .xterm .xterm-selection div { background-color: ${selectionColor} !important; }`; } this._themeStyleElement.innerHTML = css; -- GitLab From a2e856de8e3a955a33076ea22372600abd56785f Mon Sep 17 00:00:00 2001 From: t-amqi Date: Mon, 12 Jun 2017 11:44:01 -0700 Subject: [PATCH 0731/1347] Add entry for tasks in menu --- src/vs/code/electron-main/menus.ts | 2 ++ .../quickopen/browser/commandsHandler.ts | 25 +++++++++++++++++++ .../browser/quickopen.contribution.ts | 6 ++++- 3 files changed, 32 insertions(+), 1 deletion(-) diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index db805f0637c..849b873cb9c 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -586,6 +586,7 @@ export class CodeMenu { const output = this.createMenuItem(nls.localize({ key: 'miToggleOutput', comment: ['&& denotes a mnemonic'] }, "&&Output"), 'workbench.action.output.toggleOutput'); const debugConsole = this.createMenuItem(nls.localize({ key: 'miToggleDebugConsole', comment: ['&& denotes a mnemonic'] }, "De&&bug Console"), 'workbench.debug.action.toggleRepl'); const integratedTerminal = this.createMenuItem(nls.localize({ key: 'miToggleIntegratedTerminal', comment: ['&& denotes a mnemonic'] }, "&&Integrated Terminal"), 'workbench.action.terminal.toggleTerminal'); + const taskMenu = this.createMenuItem(nls.localize({ key: 'miShowTask', comment: ['&& denotes a mnemonic'] }, "&&Show Tasks"), 'workbench.action.showTasks'); const problems = this.createMenuItem(nls.localize({ key: 'miMarker', comment: ['&& denotes a mnemonic'] }, "&&Problems"), 'workbench.actions.view.problems'); let additionalViewlets: Electron.MenuItem; @@ -657,6 +658,7 @@ export class CodeMenu { problems, debugConsole, integratedTerminal, + taskMenu, __separator__(), fullscreen, toggleZenMode, diff --git a/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts b/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts index cf9fd534f85..aee3eb1b140 100644 --- a/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts +++ b/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts @@ -149,6 +149,31 @@ export class ShowAllCommandsAction extends Action { } } +export class ShowTasksAction extends Action { + + public static ID = 'workbench.action.showTasks'; + public static LABEL = nls.localize('showTasks', "Show Task Menu"); + + constructor( + id: string, + label: string, + @IQuickOpenService private quickOpenService: IQuickOpenService, + @IConfigurationService private configurationService: IConfigurationService + ) { + super(id, label); + } + + public run(context?: any): TPromise { + let value = ALL_COMMANDS_PREFIX; + let taskStr = 'tasks'; + value = `${value}${taskStr}`; + + this.quickOpenService.show(value); + + return TPromise.as(null); + } +} + export class ClearCommandHistoryAction extends Action { public static ID = 'workbench.action.clearCommandHistory'; diff --git a/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts b/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts index 606e882af9b..d70aae56491 100644 --- a/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts +++ b/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts @@ -13,7 +13,7 @@ import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/workbench/common/actionRegistry'; import { KeyMod, KeyCode } from 'vs/base/common/keyCodes'; import { GotoSymbolAction, GOTO_SYMBOL_PREFIX, SCOPE_PREFIX } from 'vs/workbench/parts/quickopen/browser/gotoSymbolHandler'; -import { ShowAllCommandsAction, ALL_COMMANDS_PREFIX, ClearCommandHistoryAction } from 'vs/workbench/parts/quickopen/browser/commandsHandler'; +import { ShowAllCommandsAction, ALL_COMMANDS_PREFIX, ClearCommandHistoryAction, ShowTasksAction } from 'vs/workbench/parts/quickopen/browser/commandsHandler'; import { GotoLineAction, GOTO_LINE_PREFIX } from 'vs/workbench/parts/quickopen/browser/gotoLineHandler'; import { HELP_PREFIX } from 'vs/workbench/parts/quickopen/browser/helpHandler'; import { VIEW_PICKER_PREFIX, OpenViewPickerAction, QuickOpenViewPickerAction } from 'vs/workbench/parts/quickopen/browser/viewPickerHandler'; @@ -40,6 +40,10 @@ registry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenViewPickerAct primary: KeyMod.CtrlCmd | KeyCode.KEY_Q, mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_Q }, linux: { primary: null } }), 'Quick Open View'); +registry.registerWorkbenchAction(new SyncActionDescriptor(ShowTasksAction, ShowTasksAction.ID, ShowTasksAction.LABEL, { + primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_T +}), 'Show Task Menu'); + // Register Quick Open Handler Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpenHandler( -- GitLab From 7e9dc4a54b2c3217b4372ed23c6059c8d8d5e11f Mon Sep 17 00:00:00 2001 From: t-amqi Date: Mon, 12 Jun 2017 14:12:03 -0700 Subject: [PATCH 0732/1347] Fix tasks menu syntax --- src/vs/code/electron-main/menus.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index 849b873cb9c..e9cec735992 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -586,7 +586,7 @@ export class CodeMenu { const output = this.createMenuItem(nls.localize({ key: 'miToggleOutput', comment: ['&& denotes a mnemonic'] }, "&&Output"), 'workbench.action.output.toggleOutput'); const debugConsole = this.createMenuItem(nls.localize({ key: 'miToggleDebugConsole', comment: ['&& denotes a mnemonic'] }, "De&&bug Console"), 'workbench.debug.action.toggleRepl'); const integratedTerminal = this.createMenuItem(nls.localize({ key: 'miToggleIntegratedTerminal', comment: ['&& denotes a mnemonic'] }, "&&Integrated Terminal"), 'workbench.action.terminal.toggleTerminal'); - const taskMenu = this.createMenuItem(nls.localize({ key: 'miShowTask', comment: ['&& denotes a mnemonic'] }, "&&Show Tasks"), 'workbench.action.showTasks'); + const taskMenu = this.createMenuItem(nls.localize({ key: 'miShowTask', comment: ['&& denotes a mnemonic'] }, "&&Show Tasks..."), 'workbench.action.showTasks'); const problems = this.createMenuItem(nls.localize({ key: 'miMarker', comment: ['&& denotes a mnemonic'] }, "&&Problems"), 'workbench.actions.view.problems'); let additionalViewlets: Electron.MenuItem; -- GitLab From 78250b41d2ce7c288e226d47e86d6bd8f1eee597 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Mon, 12 Jun 2017 14:32:48 -0700 Subject: [PATCH 0733/1347] node-pty@0.6.8 Fixes #23396 --- npm-shrinkwrap.json | 6 +++--- package.json | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/npm-shrinkwrap.json b/npm-shrinkwrap.json index 01a089f8264..7b76d1c9edb 100644 --- a/npm-shrinkwrap.json +++ b/npm-shrinkwrap.json @@ -338,9 +338,9 @@ "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.7.tgz" }, "node-pty": { - "version": "0.6.6", - "from": "node-pty@0.6.6", - "resolved": "https://registry.npmjs.org/node-pty/-/node-pty-0.6.6.tgz", + "version": "0.6.8", + "from": "node-pty@0.6.8", + "resolved": "https://registry.npmjs.org/node-pty/-/node-pty-0.6.8.tgz", "dependencies": { "nan": { "version": "2.5.0", diff --git a/package.json b/package.json index 09d83d51cb2..6536cecc87a 100644 --- a/package.json +++ b/package.json @@ -35,7 +35,7 @@ "jschardet": "^1.4.2", "minimist": "1.2.0", "native-keymap": "1.2.4", - "node-pty": "0.6.6", + "node-pty": "0.6.8", "semver": "4.3.6", "v8-profiler": "jrieken/v8-profiler#vscode", "vscode-debugprotocol": "1.20.0", -- GitLab From f243ff904b987b311d76e1f91ea7fbe5008e761b Mon Sep 17 00:00:00 2001 From: t-amqi Date: Mon, 12 Jun 2017 14:41:08 -0700 Subject: [PATCH 0734/1347] Add memento for running a task --- .../parts/tasks/electron-browser/task.contribution.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index 905ed31a992..349ce3fe297 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -610,6 +610,9 @@ class TaskService extends EventEmitter implements ITaskService { private registerCommands(): void { CommandsRegistry.registerCommand('workbench.action.tasks.runTask', (accessor, arg) => { + if (!this.storageService.get('userRanTask', StorageScope.GLOBAL)) { + this.storageService.store('userRanTask', true, StorageScope.GLOBAL); + } this.runTaskCommand(accessor, arg); }); -- GitLab From 3c52b5ae39c74232085ebaf44af4fce121720961 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beatriz=20Magalh=C3=A3es?= Date: Mon, 12 Jun 2017 23:05:57 +0100 Subject: [PATCH 0735/1347] fixed misspelled occurrences and occurred --- .../lib/tslint/noUnexternalizedStringsRule.ts | 20 +- build/lib/typescript/typescriptServices.js | 524 +++++++++--------- src/typings/electron.d.ts | 2 +- src/vs/base/common/errorMessage.ts | 2 +- src/vs/base/common/marked/raw.marked.js | 2 +- .../editor/browser/controller/mouseHandler.ts | 2 +- .../browser/standalone/standaloneLanguages.ts | 2 +- .../common/controller/cursorTypeOperations.ts | 2 +- .../contrib/find/common/findController.ts | 10 +- .../find/test/common/findController.test.ts | 2 +- src/vs/editor/contrib/links/browser/links.ts | 62 +-- .../wordHighlighter/common/wordHighlighter.ts | 4 +- src/vs/monaco.d.ts | 2 +- src/vs/platform/files/common/files.ts | 2 +- src/vs/platform/search/common/replace.ts | 2 +- src/vs/workbench/api/node/extHost.api.impl.ts | 2 +- .../node/configurationResolverService.ts | 2 +- 17 files changed, 322 insertions(+), 322 deletions(-) diff --git a/build/lib/tslint/noUnexternalizedStringsRule.ts b/build/lib/tslint/noUnexternalizedStringsRule.ts index d7a2d8ca100..cbe457c5be5 100644 --- a/build/lib/tslint/noUnexternalizedStringsRule.ts +++ b/build/lib/tslint/noUnexternalizedStringsRule.ts @@ -82,10 +82,10 @@ class NoUnexternalizedStringsRuleWalker extends Lint.RuleWalker { protected visitSourceFile(node: ts.SourceFile): void { super.visitSourceFile(node); Object.keys(this.usedKeys).forEach(key => { - let occurences = this.usedKeys[key]; - if (occurences.length > 1) { - occurences.forEach(occurence => { - this.addFailure((this.createFailure(occurence.key.getStart(), occurence.key.getWidth(), `Duplicate key ${occurence.key.getText()} with different message value.`))); + let occurrences = this.usedKeys[key]; + if (occurrences.length > 1) { + occurrences.forEach(occurrence => { + this.addFailure((this.createFailure(occurrence.key.getStart(), occurrence.key.getWidth(), `Duplicate key ${occurrence.key.getText()} with different message value.`))); }); } }); @@ -157,17 +157,17 @@ class NoUnexternalizedStringsRuleWalker extends Lint.RuleWalker { private recordKey(keyNode: ts.StringLiteral, messageNode: ts.Node) { let text = keyNode.getText(); - let occurences: KeyMessagePair[] = this.usedKeys[text]; - if (!occurences) { - occurences = []; - this.usedKeys[text] = occurences; + let occurrences: KeyMessagePair[] = this.usedKeys[text]; + if (!occurrences) { + occurrences = []; + this.usedKeys[text] = occurrences; } if (messageNode) { - if (occurences.some(pair => pair.message ? pair.message.getText() === messageNode.getText() : false)) { + if (occurrences.some(pair => pair.message ? pair.message.getText() === messageNode.getText() : false)) { return; } } - occurences.push({ key: keyNode, message: messageNode }); + occurrences.push({ key: keyNode, message: messageNode }); } private findDescribingParent(node: ts.Node): { callInfo?: { callExpression: ts.CallExpression, argIndex: number }, ignoreUsage?: boolean; } { diff --git a/build/lib/typescript/typescriptServices.js b/build/lib/typescript/typescriptServices.js index 349ff6ad391..6cf24f63bf1 100644 --- a/build/lib/typescript/typescriptServices.js +++ b/build/lib/typescript/typescriptServices.js @@ -485,7 +485,7 @@ var ts; SymbolFlags[SymbolFlags["PropertyOrAccessor"] = 98308] = "PropertyOrAccessor"; SymbolFlags[SymbolFlags["Export"] = 7340032] = "Export"; /* @internal */ - // The set of things we consider semantically classifiable. Used to speed up the LS during + // The set of things we consider semantically classifiable. Used to speed up the LS during // classification. SymbolFlags[SymbolFlags["Classifiable"] = 788448] = "Classifiable"; })(ts.SymbolFlags || (ts.SymbolFlags = {})); @@ -1274,19 +1274,19 @@ var ts; ts.getNormalizedPathFromPathComponents = getNormalizedPathFromPathComponents; function getNormalizedPathComponentsOfUrl(url) { // Get root length of http://www.website.com/folder1/foler2/ - // In this example the root is: http://www.website.com/ + // In this example the root is: http://www.website.com/ // normalized path components should be ["http://www.website.com/", "folder1", "folder2"] var urlLength = url.length; // Initial root length is http:// part var rootLength = url.indexOf("://") + "://".length; while (rootLength < urlLength) { - // Consume all immediate slashes in the protocol + // Consume all immediate slashes in the protocol // eg.initial rootlength is just file:// but it needs to consume another "/" in file:/// if (url.charCodeAt(rootLength) === 47 /* slash */) { rootLength++; } else { - // non slash character means we continue proceeding to next component of root search + // non slash character means we continue proceeding to next component of root search break; } } @@ -1297,15 +1297,15 @@ var ts; // Find the index of "/" after website.com so the root can be http://www.website.com/ (from existing http://) var indexOfNextSlash = url.indexOf(ts.directorySeparator, rootLength); if (indexOfNextSlash !== -1) { - // Found the "/" after the website.com so the root is length of http://www.website.com/ + // Found the "/" after the website.com so the root is length of http://www.website.com/ // and get components afetr the root normally like any other folder components rootLength = indexOfNextSlash + 1; return normalizedPathComponents(url, rootLength); } else { - // Can't find the host assume the rest of the string as component + // Can't find the host assume the rest of the string as component // but make sure we append "/" to it as root is not joined using "/" - // eg. if url passed in was http://website.com we want to use root as [http://website.com/] + // eg. if url passed in was http://website.com we want to use root as [http://website.com/] // so that other path manipulations will be correct and it can be merged with relative paths correctly return [url + ts.directorySeparator]; } @@ -2580,7 +2580,7 @@ var ts; function computeLineAndCharacterOfPosition(lineStarts, position) { var lineNumber = ts.binarySearch(lineStarts, position); if (lineNumber < 0) { - // If the actual position was not found, + // If the actual position was not found, // the binary search returns the negative value of the next line start // e.g. if the line starts at [5, 10, 23, 80] and the position requested was 20 // then the search will return -2 @@ -2623,8 +2623,8 @@ var ts; // \u000D Carriage Return // \u2028 Line separator // \u2029 Paragraph separator - // Only the characters in Table 3 are treated as line terminators. Other new line or line - // breaking characters are treated as white space but not as line terminators. + // Only the characters in Table 3 are treated as line terminators. Other new line or line + // breaking characters are treated as white space but not as line terminators. return ch === 10 /* lineFeed */ || ch === 13 /* carriageReturn */ || ch === 8232 /* lineSeparator */ || @@ -2702,7 +2702,7 @@ var ts; } } ts.skipTrivia = skipTrivia; - // All conflict markers consist of the same character repeated seven times. If it is + // All conflict markers consist of the same character repeated seven times. If it is // a <<<<<<< or >>>>>>> marker then it is also followd by a space. var mergeConflictMarkerLength = "<<<<<<<".length; function isConflictMarkerTrivia(text, pos) { @@ -2747,12 +2747,12 @@ var ts; } return pos; } - // Extract comments from the given source text starting at the given position. If trailing is - // false, whitespace is skipped until the first line break and comments between that location - // and the next token are returned.If trailing is true, comments occurring between the given - // position and the next line break are returned.The return value is an array containing a - // TextRange for each comment. Single-line comment ranges include the beginning '//' characters - // but not the ending line break. Multi - line comment ranges include the beginning '/* and + // Extract comments from the given source text starting at the given position. If trailing is + // false, whitespace is skipped until the first line break and comments between that location + // and the next token are returned.If trailing is true, comments occurring between the given + // position and the next line break are returned.The return value is an array containing a + // TextRange for each comment. Single-line comment ranges include the beginning '//' characters + // but not the ending line break. Multi - line comment ranges include the beginning '/* and // ending '*/' characters.The return value is undefined if no comments were found. function getCommentRanges(text, pos, trailing) { var result; @@ -3699,7 +3699,7 @@ var ts; })(ts.ModuleInstanceState || (ts.ModuleInstanceState = {})); var ModuleInstanceState = ts.ModuleInstanceState; function getModuleInstanceState(node) { - // A module is uninstantiated if it contains only + // A module is uninstantiated if it contains only // 1. interface declarations, type alias declarations if (node.kind === 205 /* InterfaceDeclaration */ || node.kind === 206 /* TypeAliasDeclaration */) { return 0 /* NonInstantiated */; @@ -3739,7 +3739,7 @@ var ts; ts.getModuleInstanceState = getModuleInstanceState; var ContainerFlags; (function (ContainerFlags) { - // The current node is not a container, and no container manipulation should happen before + // The current node is not a container, and no container manipulation should happen before // recursing into it. ContainerFlags[ContainerFlags["None"] = 0] = "None"; // The current node is a container. It should be set as the current container (and block- @@ -3844,13 +3844,13 @@ var ts; if (name !== undefined) { // Check and see if the symbol table already has a symbol with this name. If not, // create a new symbol with this name and add it to the table. Note that we don't - // give the new symbol any flags *yet*. This ensures that it will not conflict + // give the new symbol any flags *yet*. This ensures that it will not conflict // witht he 'excludes' flags we pass in. // // If we do get an existing symbol, see if it conflicts with the new symbol we're // creating. For example, a 'var' symbol and a 'class' symbol will conflict within - // the same symbol table. If we have a conflict, report the issue on each - // declaration we have for this symbol, and then create a new symbol for this + // the same symbol table. If we have a conflict, report the issue on each + // declaration we have for this symbol, and then create a new symbol for this // declaration. // // If we created a new symbol, either because we didn't have a symbol with this name @@ -3904,7 +3904,7 @@ var ts; // ExportType, or ExportContainer flag, and an associated export symbol with all the correct flags set // on it. There are 2 main reasons: // - // 1. We treat locals and exports of the same name as mutually exclusive within a container. + // 1. We treat locals and exports of the same name as mutually exclusive within a container. // That means the binder will issue a Duplicate Identifier error if you mix locals and exports // with the same name in the same container. // TODO: Make this a more specific error and decouple it from the exclusion logic. @@ -3925,11 +3925,11 @@ var ts; } } } - // All container nodes are kept on a linked list in declaration order. This list is used by - // the getLocalNameOfContainer function in the type checker to validate that the local name + // All container nodes are kept on a linked list in declaration order. This list is used by + // the getLocalNameOfContainer function in the type checker to validate that the local name // used for a container is unique. function bindChildren(node) { - // Before we recurse into a node's chilren, we first save the existing parent, container + // Before we recurse into a node's chilren, we first save the existing parent, container // and block-container. Then after we pop out of processing the children, we restore // these saved values. var saveParent = parent; @@ -3943,9 +3943,9 @@ var ts; // may contain locals, we proactively initialize the .locals field. We do this because // it's highly likely that the .locals will be needed to place some child in (for example, // a parameter, or variable declaration). - // + // // However, we do not proactively create the .locals for block-containers because it's - // totally normal and common for block-containers to never actually have a block-scoped + // totally normal and common for block-containers to never actually have a block-scoped // variable in them. We don't want to end up allocating an object for every 'block' we // run into when most of them won't be necessary. // @@ -4005,7 +4005,7 @@ var ts; return 2 /* IsBlockScopedContainer */; case 182 /* Block */: // do not treat blocks directly inside a function as a block-scoped-container. - // Locals that reside in this block should go to the function locals. Othewise 'x' + // Locals that reside in this block should go to the function locals. Othewise 'x' // would not appear to be a redeclaration of a block scoped local in the following // example: // @@ -4018,7 +4018,7 @@ var ts; // the block, then there would be no collision. // // By not creating a new block-scoped-container here, we ensure that both 'var x' - // and 'let x' go into the Function-container's locals, and we do get a collision + // and 'let x' go into the Function-container's locals, and we do get a collision // conflict. return ts.isFunctionLike(node.parent) ? 0 /* None */ : 2 /* IsBlockScopedContainer */; } @@ -4150,8 +4150,8 @@ var ts; // For a given function symbol "<...>(...) => T" we want to generate a symbol identical // to the one we would get for: { <...>(...): T } // - // We do that by making an anonymous type literal symbol, and then setting the function - // symbol as its sole member. To the rest of the system, this symbol will be indistinguishable + // We do that by making an anonymous type literal symbol, and then setting the function + // symbol as its sole member. To the rest of the system, this symbol will be indistinguishable // from an actual type literal symbol you would have gotten had you used the long form. var symbol = createSymbol(131072 /* Signature */, getDeclarationName(node)); addDeclarationToSymbol(symbol, node, 131072 /* Signature */); @@ -4192,17 +4192,17 @@ var ts; function bind(node) { node.parent = parent; // First we bind declaration nodes to a symbol if possible. We'll both create a symbol - // and then potentially add the symbol to an appropriate symbol table. Possible + // and then potentially add the symbol to an appropriate symbol table. Possible // destination symbol tables are: - // + // // 1) The 'exports' table of the current container's symbol. // 2) The 'members' table of the current container's symbol. // 3) The 'locals' table of the current container. // - // However, not all symbols will end up in any of these tables. 'Anonymous' symbols + // However, not all symbols will end up in any of these tables. 'Anonymous' symbols // (like TypeLiterals for example) will not be put in any table. bindWorker(node); - // Then we recurse into the children of the node to bind them as well. For certain + // Then we recurse into the children of the node to bind them as well. For certain // symbols we do specialized work when we recurse. For example, we'll keep track of // the current 'container' node when it changes. This helps us know which symbol table // a local should go into for example. @@ -4324,9 +4324,9 @@ var ts; } var symbol = node.symbol; // TypeScript 1.0 spec (April 2014): 8.4 - // Every class automatically contains a static property member named 'prototype', the + // Every class automatically contains a static property member named 'prototype', the // type of which is an instantiation of the class type with type Any supplied as a type - // argument for each type parameter. It is an error to explicitly declare a static + // argument for each type parameter. It is an error to explicitly declare a static // property member with the name 'prototype'. // // Note: we check for this here because this class may be merging into a module. The @@ -4376,7 +4376,7 @@ var ts; else { declareSymbolAndAddToSymbolTable(node, 1 /* FunctionScopedVariable */, 107455 /* ParameterExcludes */); } - // If this is a property-parameter, then also declare the property symbol into the + // If this is a property-parameter, then also declare the property symbol into the // containing class. if (node.flags & 112 /* AccessibilityModifier */ && node.parent.kind === 137 /* Constructor */ && @@ -4456,7 +4456,7 @@ var ts; // b) any of it's children reported that it had an error. var thisNodeOrAnySubNodesHasError = ((node.parserContextFlags & 32 /* ThisNodeHasError */) !== 0) || ts.forEachChild(node, containsParseError); - // If so, mark ourselves accordingly. + // If so, mark ourselves accordingly. if (thisNodeOrAnySubNodesHasError) { node.parserContextFlags |= 128 /* ThisNodeOrAnySubNodesHasError */; } @@ -4491,13 +4491,13 @@ var ts; ts.getStartPosOfNode = getStartPosOfNode; // Returns true if this node is missing from the actual source code. 'missing' is different // from 'undefined/defined'. When a node is undefined (which can happen for optional nodes - // in the tree), it is definitel missing. HOwever, a node may be defined, but still be + // in the tree), it is definitel missing. HOwever, a node may be defined, but still be // missing. This happens whenever the parser knows it needs to parse something, but can't // get anything in the source code that it expects at that location. For example: // // let a: ; // - // Here, the Type in the Type-Annotation is not-optional (as there is a colon in the source + // Here, the Type in the Type-Annotation is not-optional (as there is a colon in the source // code). So the parser will attempt to parse out a type, and will create an actual node. // However, this node will be 'missing' in the sense that no actual source-code/tokens are // contained within it. @@ -4568,7 +4568,7 @@ var ts; isCatchClauseVariableDeclaration(declaration); } ts.isBlockOrCatchScoped = isBlockOrCatchScoped; - // Gets the nearest enclosing block scope container that has the provided node + // Gets the nearest enclosing block scope container that has the provided node // as a descendant, that is not the provided node. function getEnclosingBlockScopeContainer(node) { var current = node.parent; @@ -4662,7 +4662,7 @@ var ts; break; } if (errorNode === undefined) { - // If we don't have a better node, then just set the error on the first token of + // If we don't have a better node, then just set the error on the first token of // construct. return getSpanOfTokenAtPosition(sourceFile, node.pos); } @@ -4690,10 +4690,10 @@ var ts; } return node; } - // Returns the node flags for this node and all relevant parent nodes. This is done so that + // Returns the node flags for this node and all relevant parent nodes. This is done so that // nodes like variable declarations and binding elements can returned a view of their flags // that includes the modifiers from their container. i.e. flags like export/declare aren't - // stored on the variable declaration directly, but on the containing variable statement + // stored on the variable declaration directly, but on the containing variable statement // (if it has one). Similarly, flags for let/const are store on the variable declaration // list. By calling this function, all those flags are combined so that the client can treat // the node as if it actually had those flags. @@ -4994,7 +4994,7 @@ var ts; node = node.parent; break; case 132 /* Decorator */: - // Decorators are always applied outside of the body of a class or method. + // Decorators are always applied outside of the body of a class or method. if (node.parent.kind === 131 /* Parameter */ && isClassElement(node.parent.parent)) { // If the decorator's parent is a Parameter, we resolve the this container from // the grandparent class declaration. @@ -5050,7 +5050,7 @@ var ts; node = node.parent; break; case 132 /* Decorator */: - // Decorators are always applied outside of the body of a class or method. + // Decorators are always applied outside of the body of a class or method. if (node.parent.kind === 131 /* Parameter */ && isClassElement(node.parent.parent)) { // If the decorator's parent is a Parameter, we resolve the this container from // the grandparent class declaration. @@ -5326,7 +5326,7 @@ var ts; ts.getJSDocTemplateTag = getJSDocTemplateTag; function getCorrespondingJSDocParameterTag(parameter) { if (parameter.name && parameter.name.kind === 65 /* Identifier */) { - // If it's a parameter, see if the parent has a jsdoc comment with an @param + // If it's a parameter, see if the parent has a jsdoc comment with an @param // annotation. var parameterName = parameter.name.text; var docComment = parameter.parent.jsDocComment; @@ -6361,17 +6361,17 @@ var ts; // // 0 10 20 30 40 50 60 70 80 90 100 // ------------------------------------------------------------------------------------------------------- - // | / - // | /---- - // T1 | /---- - // | /---- - // | /---- + // | / + // | /---- + // T1 | /---- + // | /---- + // | /---- // ------------------------------------------------------------------------------------------------------- - // | \ - // | \ - // T2 | \ - // | \ - // | \ + // | \ + // | \ + // T2 | \ + // | \ + // | \ // ------------------------------------------------------------------------------------------------------- // // Merging these turns out to not be too difficult. First, determining the new start of the change is trivial @@ -6379,17 +6379,17 @@ var ts; // // 0 10 20 30 40 50 60 70 80 90 100 // ------------------------------------------------------------*------------------------------------------ - // | / - // | /---- - // T1 | /---- - // | /---- - // | /---- + // | / + // | /---- + // T1 | /---- + // | /---- + // | /---- // ----------------------------------------$-------------------$------------------------------------------ - // . | \ - // . | \ - // T2 . | \ - // . | \ - // . | \ + // . | \ + // . | \ + // T2 . | \ + // . | \ + // . | \ // ----------------------------------------------------------------------*-------------------------------- // // (Note the dots represent the newly inferrred start. @@ -6400,22 +6400,22 @@ var ts; // // 0 10 20 30 40 50 60 70 80 90 100 // --------------------------------------------------------------------------------*---------------------- - // | / - // | /---- - // T1 | /---- - // | /---- - // | /---- + // | / + // | /---- + // T1 | /---- + // | /---- + // | /---- // ------------------------------------------------------------$------------------------------------------ - // . | \ - // . | \ - // T2 . | \ - // . | \ - // . | \ + // . | \ + // . | \ + // T2 . | \ + // . | \ + // . | \ // ----------------------------------------------------------------------*-------------------------------- // // In other words (in this case), we're recognizing that the second edit happened after where the first edit // ended with a delta of 20 characters (60 - 40). Thus, if we go back in time to where the first edit started - // that's the same as if we started at char 80 instead of 60. + // that's the same as if we started at char 80 instead of 60. // // As it so happens, the same logic applies if the second edit precedes the first edit. In that case rahter // than pusing the first edit forward to match the second, we'll push the second edit forward to match the @@ -6425,7 +6425,7 @@ var ts; // semantics: { { start: 10, length: 70 }, newLength: 60 } // // The math then works out as follows. - // If we have { oldStart1, oldEnd1, newEnd1 } and { oldStart2, oldEnd2, newEnd2 } then we can compute the + // If we have { oldStart1, oldEnd1, newEnd1 } and { oldStart2, oldEnd2, newEnd2 } then we can compute the // final result like so: // // { @@ -6995,7 +6995,7 @@ var ts; if (setParentNodes) { fixupParentReferences(sourceFile); } - // If this is a javascript file, proactively see if we can get JSDoc comments for + // If this is a javascript file, proactively see if we can get JSDoc comments for // relevant nodes in the file. We'll use these to provide typing informaion if they're // available. if (ts.isJavaScript(fileName)) { @@ -7537,7 +7537,7 @@ var ts; // if we see "extends {}" then only treat the {} as what we're extending (and not // the class body) if we have: // - // extends {} { + // extends {} { // extends {}, // extends {} extends // extends {} implements @@ -9280,7 +9280,7 @@ var ts; expression = finishNode(propertyAccess); continue; } - // when in the [Decorator] context, we do not parse ElementAccess as it could be part of a ComputedPropertyName + // when in the [Decorator] context, we do not parse ElementAccess as it could be part of a ComputedPropertyName if (!inDecoratorContext() && parseOptional(18 /* OpenBracketToken */)) { var indexedAccess = createNode(159 /* ElementAccessExpression */, expression.pos); indexedAccess.expression = expression; @@ -9388,7 +9388,7 @@ var ts; case 23 /* CommaToken */: // foo, case 14 /* OpenBraceToken */: // foo { // We don't want to treat these as type arguments. Otherwise we'll parse this - // as an invocation expression. Instead, we want to parse out the expression + // as an invocation expression. Instead, we want to parse out the expression // in isolation from the type arguments. default: // Anything else treat as an expression. @@ -9560,7 +9560,7 @@ var ts; function parseFunctionBlock(allowYield, ignoreMissingOpenBrace, diagnosticMessage) { var savedYieldContext = inYieldContext(); setYieldContext(allowYield); - // We may be in a [Decorator] context when parsing a function expression or + // We may be in a [Decorator] context when parsing a function expression or // arrow function. The body of the function is not in [Decorator] context. var saveDecoratorContext = inDecoratorContext(); if (saveDecoratorContext) { @@ -10011,7 +10011,7 @@ var ts; default: if (decorators) { // We reached this point because we encountered decorators and/or modifiers and assumed a declaration - // would follow. For recovery and error reporting purposes, return an incomplete declaration. + // would follow. For recovery and error reporting purposes, return an incomplete declaration. var node = createMissingNode(221 /* MissingDeclaration */, true, ts.Diagnostics.Declaration_expected); node.pos = fullStart; node.decorators = decorators; @@ -10366,8 +10366,8 @@ var ts; } function parseClassExpression() { return parseClassDeclarationOrExpression( - /*fullStart*/ scanner.getStartPos(), - /*decorators*/ undefined, + /*fullStart*/ scanner.getStartPos(), + /*decorators*/ undefined, /*modifiers*/ undefined, 177 /* ClassExpression */); } function parseClassDeclaration(fullStart, decorators, modifiers) { @@ -11125,8 +11125,8 @@ var ts; ts.Debug.assert(end <= content.length); var tags; var pos; - // NOTE(cyrusn): This is essentially a handwritten scanner for JSDocComments. I - // considered using an actual Scanner, but this would complicate things. The + // NOTE(cyrusn): This is essentially a handwritten scanner for JSDocComments. I + // considered using an actual Scanner, but this would complicate things. The // scanner would need to know it was in a Doc Comment. Otherwise, it would then // produce comments *inside* the doc comment. In the end it was just easier to // write a simple scanner rather than go that route. @@ -12274,7 +12274,7 @@ var ts; } break; case 132 /* Decorator */: - // Decorators are resolved at the class declaration. Resolving at the parameter + // Decorators are resolved at the class declaration. Resolving at the parameter // or member would result in looking up locals in the method. // // function y() {} @@ -13690,7 +13690,7 @@ var ts; case 151 /* UnionType */: case 152 /* ParenthesizedType */: return isDeclarationVisible(node.parent); - // Default binding, import specifier and namespace import is visible + // Default binding, import specifier and namespace import is visible // only on demand so by default it is not visible case 213 /* ImportClause */: case 214 /* NamespaceImport */: @@ -17000,7 +17000,7 @@ var ts; if (assumeTrue) { // Assumed result is true. If check was not for a primitive type, remove all primitive types if (!typeInfo) { - return removeTypesFromUnionType(type, 258 /* StringLike */ | 132 /* NumberLike */ | 8 /* Boolean */ | 2097152 /* ESSymbol */, + return removeTypesFromUnionType(type, 258 /* StringLike */ | 132 /* NumberLike */ | 8 /* Boolean */ | 2097152 /* ESSymbol */, /*isOfTypeKind*/ true, false); } // Check was for a primitive type, return that primitive type if it is a subtype @@ -17737,7 +17737,7 @@ var ts; // c is represented in the tree as a spread element in an array literal. // But c really functions as a rest element, and its purpose is to provide // a contextual type for the right hand side of the assignment. Therefore, - // instead of calling checkExpression on "...c", which will give an error + // instead of calling checkExpression on "...c", which will give an error // if c is not iterable/array-like, we need to act as if we are trying to // get the contextual element type from it. So we do something similar to // getContextualTypeForElementExpression, which will crucially not error @@ -18641,7 +18641,7 @@ var ts; // We exclude union types because we may have a union of function types that happen to have // no common signatures. if (isTypeAny(funcType) || (!callSignatures.length && !constructSignatures.length && !(funcType.flags & 16384 /* Union */) && isTypeAssignableTo(funcType, globalFunctionType))) { - // The unknownType indicates that an error already occured (and was reported). No + // The unknownType indicates that an error already occurred (and was reported). No // need to report another error in this case. if (funcType !== unknownType && node.typeArguments) { error(node, ts.Diagnostics.Untyped_function_calls_may_not_accept_type_arguments); @@ -20415,7 +20415,7 @@ var ts; /** Checks a type reference node as an expression. */ function checkTypeNodeAsExpression(node) { // When we are emitting type metadata for decorators, we need to try to check the type - // as if it were an expression so that we can emit the type in a value position when we + // as if it were an expression so that we can emit the type in a value position when we // serialize the type metadata. if (node && node.kind === 144 /* TypeReference */) { var type = getTypeFromTypeNode(node); @@ -20911,7 +20911,7 @@ var ts; } else { var leftType = checkExpression(varExpr); - checkReferenceExpression(varExpr, ts.Diagnostics.Invalid_left_hand_side_in_for_of_statement, + checkReferenceExpression(varExpr, ts.Diagnostics.Invalid_left_hand_side_in_for_of_statement, /*constantVariableMessage*/ ts.Diagnostics.The_left_hand_side_of_a_for_of_statement_cannot_be_a_previously_defined_constant); // iteratedType will be undefined if the rightType was missing properties/signatures // required to get its iteratedType (like [Symbol.iterator] or next). This may be @@ -21945,7 +21945,7 @@ var ts; error(node.name, ts.Diagnostics.A_namespace_declaration_cannot_be_located_prior_to_a_class_or_function_with_which_it_is_merged); } } - // if the module merges with a class declaration in the same lexical scope, + // if the module merges with a class declaration in the same lexical scope, // we need to track this to ensure the correct emit. var mergedClass = ts.getDeclarationOfKind(symbol, 204 /* ClassDeclaration */); if (mergedClass && @@ -22605,7 +22605,7 @@ var ts; return getSymbolOfNode(entityName.parent); } if (entityName.parent.kind === 217 /* ExportAssignment */) { - return resolveEntityName(entityName, + return resolveEntityName(entityName, /*all meanings*/ 107455 /* Value */ | 793056 /* Type */ | 1536 /* Namespace */ | 8388608 /* Alias */); } if (entityName.kind !== 158 /* PropertyAccessExpression */) { @@ -23074,7 +23074,7 @@ var ts; // * The serialized type of an AccessorDeclaration is the serialized type of the return type annotation of its getter or parameter type annotation of its setter. // * The serialized type of any other FunctionLikeDeclaration is "Function". // * The serialized type of any other node is "void 0". - // + // // For rules on serializing type annotations, see `serializeTypeNode`. switch (node.kind) { case 204 /* ClassDeclaration */: return "Function"; @@ -23094,7 +23094,7 @@ var ts; // // * If the declaration is a class, the parameters of the first constructor with a body are used. // * If the declaration is function-like and has a body, the parameters of the function are used. - // + // // For the rules on serializing the type of each parameter declaration, see `serializeTypeOfDeclaration`. if (node) { var valueDeclaration; @@ -23162,7 +23162,7 @@ var ts; } function getReferencedValueSymbol(reference) { return getNodeLinks(reference).resolvedSymbol || - resolveName(reference, reference.text, 107455 /* Value */ | 1048576 /* ExportValue */ | 8388608 /* Alias */, + resolveName(reference, reference.text, 107455 /* Value */ | 1048576 /* ExportValue */ | 8388608 /* Alias */, /*nodeNotFoundMessage*/ undefined, undefined); } function getReferencedValueDeclaration(reference) { @@ -24494,7 +24494,7 @@ var ts; // we would write alias foo declaration when we visit it since it would now be marked as visible if (moduleElementEmitInfo) { if (moduleElementEmitInfo.node.kind === 212 /* ImportDeclaration */) { - // we have to create asynchronous output only after we have collected complete information + // we have to create asynchronous output only after we have collected complete information // because it is possible to enable multiple bindings as asynchronously visible moduleElementEmitInfo.isVisible = true; } @@ -24633,7 +24633,7 @@ var ts; return emitEntityName(type); } function emitEntityName(entityName) { - var visibilityResult = resolver.isEntityNameVisible(entityName, + var visibilityResult = resolver.isEntityNameVisible(entityName, // Aliases can be written asynchronously so use correct enclosing declaration entityName.parent.kind === 211 /* ImportEqualsDeclaration */ ? entityName.parent : enclosingDeclaration); handleSymbolAccessibilityError(visibilityResult); @@ -24845,7 +24845,7 @@ var ts; } } function writeImportEqualsDeclaration(node) { - // note usage of writer. methods instead of aliases created, just to make sure we are using + // note usage of writer. methods instead of aliases created, just to make sure we are using // correct writer especially to handle asynchronous alias writing emitJsDocComments(node); if (node.flags & 1 /* Export */) { @@ -24884,7 +24884,7 @@ var ts; } function writeImportDeclaration(node) { if (!node.importClause && !(node.flags & 1 /* Export */)) { - // do not write non-exported import declarations that don't have import clauses + // do not write non-exported import declarations that don't have import clauses return; } emitJsDocComments(node); @@ -25723,7 +25723,7 @@ var ts; : ts.shouldEmitToOwnFile(referencedFile, compilerOptions) ? ts.getOwnEmitOutputFilePath(referencedFile, host, ".d.ts") // Own output file so get the .d.ts file : ts.removeFileExtension(compilerOptions.out) + ".d.ts"; // Global out file - declFileName = ts.getRelativePathToDirectoryOrUrl(ts.getDirectoryPath(ts.normalizeSlashes(jsFilePath)), declFileName, host.getCurrentDirectory(), host.getCanonicalFileName, + declFileName = ts.getRelativePathToDirectoryOrUrl(ts.getDirectoryPath(ts.normalizeSlashes(jsFilePath)), declFileName, host.getCurrentDirectory(), host.getCanonicalFileName, /*isAbsolutePathAnUrl*/ false); referencePathsOutput += "/// " + newLine; } @@ -26191,7 +26191,7 @@ var ts; // If sourceroot option: Use the relative path corresponding to the common directory path // otherwise source locations relative to map file location var sourcesDirectoryPath = compilerOptions.sourceRoot ? host.getCommonSourceDirectory() : sourceMapDir; - sourceMapData.sourceMapSources.push(ts.getRelativePathToDirectoryOrUrl(sourcesDirectoryPath, node.fileName, host.getCurrentDirectory(), host.getCanonicalFileName, + sourceMapData.sourceMapSources.push(ts.getRelativePathToDirectoryOrUrl(sourcesDirectoryPath, node.fileName, host.getCurrentDirectory(), host.getCanonicalFileName, /*isAbsolutePathAnUrl*/ true)); sourceMapSourceIndex = sourceMapData.sourceMapSources.length - 1; // The one that can be used from program to get the actual source file @@ -26342,7 +26342,7 @@ var ts; if (!ts.isRootedDiskPath(sourceMapDir) && !ts.isUrl(sourceMapDir)) { // The relative paths are relative to the common directory sourceMapDir = ts.combinePaths(host.getCommonSourceDirectory(), sourceMapDir); - sourceMapData.jsSourceMappingURL = ts.getRelativePathToDirectoryOrUrl(ts.getDirectoryPath(ts.normalizePath(jsFilePath)), ts.combinePaths(sourceMapDir, sourceMapData.jsSourceMappingURL), host.getCurrentDirectory(), host.getCanonicalFileName, + sourceMapData.jsSourceMappingURL = ts.getRelativePathToDirectoryOrUrl(ts.getDirectoryPath(ts.normalizePath(jsFilePath)), ts.combinePaths(sourceMapDir, sourceMapData.jsSourceMappingURL), host.getCurrentDirectory(), host.getCanonicalFileName, /*isAbsolutePathAnUrl*/ true); } else { @@ -26759,7 +26759,7 @@ var ts; } else if (node.kind === 129 /* ComputedPropertyName */) { // if this is a decorated computed property, we will need to capture the result - // of the property expression so that we can apply decorators later. This is to ensure + // of the property expression so that we can apply decorators later. This is to ensure // we don't introduce unintended side effects: // // class C { @@ -27059,7 +27059,7 @@ var ts; write("]"); } else { - emitListWithSpread(elements, true, (node.flags & 512 /* MultiLine */) !== 0, + emitListWithSpread(elements, true, (node.flags & 512 /* MultiLine */) !== 0, /*trailingComma*/ elements.hasTrailingComma, true); } } @@ -27326,8 +27326,8 @@ var ts; } return false; } - // Returns 'true' if the code was actually indented, false otherwise. - // If the code is not indented, an optional valueToWriteWhenNotIndenting will be + // Returns 'true' if the code was actually indented, false otherwise. + // If the code is not indented, an optional valueToWriteWhenNotIndenting will be // emitted instead. function indentIfOnDifferentLines(parent, node1, node2, valueToWriteWhenNotIndenting) { var realNodesAreOnDifferentLines = !ts.nodeIsSynthesized(parent) && !nodeEndIsOnSameLineAsNodeStart(node1, node2); @@ -27706,7 +27706,7 @@ var ts; emit(node.whenFalse); decreaseIndentIf(indentedBeforeColon, indentedAfterColon); } - // Helper function to decrease the indent if we previously indented. Allows multiple + // Helper function to decrease the indent if we previously indented. Allows multiple // previous indent values to be considered at a time. This also allows caller to just // call this once, passing in all their appropriate indent values, instead of needing // to call this helper function multiple times. @@ -28748,7 +28748,7 @@ var ts; emitSignatureParameters(node); } if (!node.body) { - // There can be no body when there are parse errors. Just emit an empty block + // There can be no body when there are parse errors. Just emit an empty block // in that case. write(" { }"); } @@ -28776,7 +28776,7 @@ var ts; emitDownLevelExpressionFunctionBody(node, body); return; } - // For es6 and higher we can emit the expression as is. However, in the case + // For es6 and higher we can emit the expression as is. However, in the case // where the expression might end up looking like a block when emitted, we'll // also wrap it in parentheses first. For example if you have: a => {} // then we need to generate: a => ({}) @@ -29253,9 +29253,9 @@ var ts; } } // If the class has static properties, and it's a class expression, then we'll need - // to specialize the emit a bit. for a class expression of the form: + // to specialize the emit a bit. for a class expression of the form: // - // class C { static a = 1; static b = 2; ... } + // class C { static a = 1; static b = 2; ... } // // We'll emit: // @@ -29517,7 +29517,7 @@ var ts; // // The emit for a method is: // - // Object.defineProperty(C.prototype, "method", + // Object.defineProperty(C.prototype, "method", // __decorate([ // dec, // __param(0, dec2), @@ -29525,10 +29525,10 @@ var ts; // __metadata("design:paramtypes", [Object]), // __metadata("design:returntype", void 0) // ], C.prototype, "method", Object.getOwnPropertyDescriptor(C.prototype, "method"))); - // + // // The emit for an accessor is: // - // Object.defineProperty(C.prototype, "accessor", + // Object.defineProperty(C.prototype, "accessor", // __decorate([ // dec // ], C.prototype, "accessor", Object.getOwnPropertyDescriptor(C.prototype, "accessor"))); @@ -29610,7 +29610,7 @@ var ts; } function shouldEmitTypeMetadata(node) { // This method determines whether to emit the "design:type" metadata based on the node's kind. - // The caller should have already tested whether the node has decorators and whether the emitDecoratorMetadata + // The caller should have already tested whether the node has decorators and whether the emitDecoratorMetadata // compiler option is set. switch (node.kind) { case 136 /* MethodDeclaration */: @@ -29623,7 +29623,7 @@ var ts; } function shouldEmitReturnTypeMetadata(node) { // This method determines whether to emit the "design:returntype" metadata based on the node's kind. - // The caller should have already tested whether the node has decorators and whether the emitDecoratorMetadata + // The caller should have already tested whether the node has decorators and whether the emitDecoratorMetadata // compiler option is set. switch (node.kind) { case 136 /* MethodDeclaration */: @@ -29633,7 +29633,7 @@ var ts; } function shouldEmitParamTypesMetadata(node) { // This method determines whether to emit the "design:paramtypes" metadata based on the node's kind. - // The caller should have already tested whether the node has decorators and whether the emitDecoratorMetadata + // The caller should have already tested whether the node has decorators and whether the emitDecoratorMetadata // compiler option is set. switch (node.kind) { case 204 /* ClassDeclaration */: @@ -30386,7 +30386,7 @@ var ts; } function writeExportedName(node) { // do not record default exports - // they are local to module and never overwritten (explicitly skipped) by star export + // they are local to module and never overwritten (explicitly skipped) by star export if (node.kind !== 65 /* Identifier */ && node.flags & 256 /* Default */) { return; } @@ -30408,7 +30408,7 @@ var ts; } } function processTopLevelVariableAndFunctionDeclarations(node) { - // per ES6 spec: + // per ES6 spec: // 15.2.1.16.4 ModuleDeclarationInstantiation() Concrete Method // - var declarations are initialized to undefined - 14.a.ii // - function/generator declarations are instantiated - 16.a.iv @@ -30540,7 +30540,7 @@ var ts; // hoist variable if // - it is not block scoped // - it is top level block scoped - // if block scoped variables are nested in some another block then + // if block scoped variables are nested in some another block then // no other functions can use them except ones that are defined at least in the same block return (ts.getCombinedNodeFlags(node) & 12288 /* BlockScoped */) === 0 || ts.getEnclosingBlockScopeContainer(node).kind === 230 /* SourceFile */; @@ -30724,10 +30724,10 @@ var ts; // System modules has the following shape // System.register(['dep-1', ... 'dep-n'], function(exports) {/* module body function */}) // 'exports' here is a function 'exports(name: string, value: T): T' that is used to publish exported values. - // 'exports' returns its 'value' argument so in most cases expressions + // 'exports' returns its 'value' argument so in most cases expressions // that mutate exported values can be rewritten as: - // expr -> exports('name', expr). - // The only exception in this rule is postfix unary operators, + // expr -> exports('name', expr). + // The only exception in this rule is postfix unary operators, // see comment to 'emitPostfixUnaryExpression' for more details ts.Debug.assert(!exportFunctionForFile); // make sure that name of 'exports' function does not conflict with existing identifiers @@ -30769,8 +30769,8 @@ var ts; // factory function. var unaliasedModuleNames = []; // names of modules with no corresponding parameters in // factory function. - var importAliasNames = []; // names of the parameters in the factory function; these - // parameters need to match the indexes of the corresponding + var importAliasNames = []; // names of the parameters in the factory function; these + // parameters need to match the indexes of the corresponding // module names in aliasedModuleNames. // Fill in amd-dependency tags for (var _a = 0, _b = node.amdDependencies; _a < _b.length; _a++) { @@ -30863,7 +30863,7 @@ var ts; emitCaptureThisForNodeIfNecessary(node); emitLinesStartingAt(node.statements, startIndex); emitTempDeclarations(true); - // Emit exportDefault if it exists will happen as part + // Emit exportDefault if it exists will happen as part // or normal statement emit. } function emitExportEquals(emitAsReturn) { @@ -30993,7 +30993,7 @@ var ts; // emitting the module as well. return shouldEmitEnumDeclaration(node); } - // If this is the expression body of an arrow function that we're down-leveling, + // If this is the expression body of an arrow function that we're down-leveling, // then we don't want to emit comments when we emit the body. It will have already // been taken care of when we emitted the 'return' statement for the function // expression body. @@ -31719,7 +31719,7 @@ var ts; } else if (node.kind === 208 /* ModuleDeclaration */ && node.name.kind === 8 /* StringLiteral */ && (node.flags & 2 /* Ambient */ || ts.isDeclarationFile(file))) { // TypeScript 1.0 spec (April 2014): 12.1.6 - // An AmbientExternalModuleDeclaration declares an external module. + // An AmbientExternalModuleDeclaration declares an external module. // This type of declaration is permitted only in the global module. // The StringLiteral must specify a top - level external module name. // Relative external module names are not permitted @@ -31730,7 +31730,7 @@ var ts; var moduleName = nameLiteral.text; if (moduleName) { // TypeScript 1.0 spec (April 2014): 12.1.6 - // An ExternalImportDeclaration in anAmbientExternalModuleDeclaration may reference other external modules + // An ExternalImportDeclaration in anAmbientExternalModuleDeclaration may reference other external modules // only through top - level external module names. Relative external module names are not permitted. var searchName = ts.normalizePath(ts.combinePaths(basePath, moduleName)); ts.forEach(ts.supportedExtensions, function (extension) { return findModuleSourceFile(searchName + extension, nameLiteral); }); @@ -31848,7 +31848,7 @@ var ts; } } else if (firstExternalModuleSourceFile && languageVersion < 2 /* ES6 */ && !options.module) { - // We cannot use createDiagnosticFromNode because nodes do not have parents yet + // We cannot use createDiagnosticFromNode because nodes do not have parents yet var span = ts.getErrorSpanForNode(firstExternalModuleSourceFile, firstExternalModuleSourceFile.externalModuleIndicator); diagnostics.add(ts.createFileDiagnostic(firstExternalModuleSourceFile, span.start, span.length, ts.Diagnostics.Cannot_compile_modules_unless_the_module_flag_is_provided)); } @@ -31871,7 +31871,7 @@ var ts; commonSourceDirectory = computeCommonSourceDirectory(files); } if (commonSourceDirectory && commonSourceDirectory[commonSourceDirectory.length - 1] !== ts.directorySeparator) { - // Make sure directory path ends with directory separator so this string can directly + // Make sure directory path ends with directory separator so this string can directly // used to replace with "" to get the relative path of the source file and the relative path doesn't // start with / making it rooted path commonSourceDirectory += ts.directorySeparator; @@ -32477,14 +32477,14 @@ var ts; function getNavigateToItems(program, cancellationToken, searchValue, maxResultCount) { var patternMatcher = ts.createPatternMatcher(searchValue); var rawItems = []; - // Search the declarations in all files and output matched NavigateToItem into array of NavigateToItem[] + // Search the declarations in all files and output matched NavigateToItem into array of NavigateToItem[] ts.forEach(program.getSourceFiles(), function (sourceFile) { cancellationToken.throwIfCancellationRequested(); var nameToDeclarations = sourceFile.getNamedDeclarations(); for (var name_27 in nameToDeclarations) { var declarations = ts.getProperty(nameToDeclarations, name_27); if (declarations) { - // First do a quick check to see if the name of the declaration matches the + // First do a quick check to see if the name of the declaration matches the // last portion of the (possibly) dotted name they're searching for. var matches = patternMatcher.getMatchesForLastSegmentOfPattern(name_27); if (!matches) { @@ -32492,7 +32492,7 @@ var ts; } for (var _i = 0; _i < declarations.length; _i++) { var declaration = declarations[_i]; - // It was a match! If the pattern has dots in it, then also see if the + // It was a match! If the pattern has dots in it, then also see if the // declaration container matches as well. if (patternMatcher.patternContainsDots) { var containers = getContainers(declaration); @@ -32794,8 +32794,8 @@ var ts; } function isTopLevelFunctionDeclaration(functionDeclaration) { if (functionDeclaration.kind === 203 /* FunctionDeclaration */) { - // A function declaration is 'top level' if it contains any function declarations - // within it. + // A function declaration is 'top level' if it contains any function declarations + // within it. if (functionDeclaration.body && functionDeclaration.body.kind === 182 /* Block */) { // Proper function declarations can only have identifier names if (ts.forEach(functionDeclaration.body.statements, function (s) { return s.kind === 203 /* FunctionDeclaration */ && !isEmpty(s.name.text); })) { @@ -33076,8 +33076,8 @@ var ts; } function createPatternMatcher(pattern) { // We'll often see the same candidate string many times when searching (For example, when - // we see the name of a module that is used everywhere, or the name of an overload). As - // such, we cache the information we compute about the candidate for the life of this + // we see the name of a module that is used everywhere, or the name of an overload). As + // such, we cache the information we compute about the candidate for the life of this // pattern matcher so we don't have to compute it multiple times. var stringToWordSpans = {}; pattern = pattern.trim(); @@ -33160,7 +33160,7 @@ var ts; if (index > 0) { // c) If the part is entirely lowercase, then check if it is contained anywhere in the // candidate in a case insensitive manner. If so, return that there was a substring - // match. + // match. // // Note: We only have a substring match if the lowercase part is prefix match of some // word part. That way we don't match something like 'Class' when the user types 'a'. @@ -33169,7 +33169,7 @@ var ts; for (var _i = 0; _i < wordSpans.length; _i++) { var span = wordSpans[_i]; if (partStartsWith(candidate, span, chunk.text, true)) { - return createPatternMatch(PatternMatchKind.substring, punctuationStripped, + return createPatternMatch(PatternMatchKind.substring, punctuationStripped, /*isCaseSensitive:*/ partStartsWith(candidate, span, chunk.text, false)); } } @@ -33200,8 +33200,8 @@ var ts; if (isLowercase) { // f) Is the pattern a substring of the candidate starting on one of the candidate's word boundaries? // We could check every character boundary start of the candidate for the pattern. However, that's - // an m * n operation in the wost case. Instead, find the first instance of the pattern - // substring, and see if it starts on a capital letter. It seems unlikely that the user will try to + // an m * n operation in the wost case. Instead, find the first instance of the pattern + // substring, and see if it starts on a capital letter. It seems unlikely that the user will try to // filter the list based on a substring that starts on a capital letter and also with a lowercase one. // (Pattern: fogbar, Candidate: quuxfogbarFogBar). if (chunk.text.length < candidate.length) { @@ -33253,7 +33253,7 @@ var ts; // // c) If the word is entirely lowercase, then check if it is contained anywhere in the // candidate in a case insensitive manner. If so, return that there was a substring - // match. + // match. // // Note: We only have a substring match if the lowercase part is prefix match of // some word part. That way we don't match something like 'Class' when the user @@ -33267,7 +33267,7 @@ var ts; // e) If the word was not entirely lowercase, then attempt a camel cased match as // well. // - // f) The word is all lower case. Is it a case insensitive substring of the candidate starting + // f) The word is all lower case. Is it a case insensitive substring of the candidate starting // on a part boundary of the candidate? // // Only if all words have some sort of match is the pattern considered matched. @@ -33317,7 +33317,7 @@ var ts; // Note: we may have more pattern parts than candidate parts. This is because multiple // pattern parts may match a candidate part. For example "SiUI" against "SimpleUI". // We'll have 3 pattern parts Si/U/I against two candidate parts Simple/UI. However, U - // and I will both match in UI. + // and I will both match in UI. var currentCandidate = 0; var currentChunkSpan = 0; var firstMatch = undefined; @@ -33346,13 +33346,13 @@ var ts; // Consider the case of matching SiUI against SimpleUIElement. The candidate parts // will be Simple/UI/Element, and the pattern parts will be Si/U/I. We'll match 'Si' // against 'Simple' first. Then we'll match 'U' against 'UI'. However, we want to - // still keep matching pattern parts against that candidate part. + // still keep matching pattern parts against that candidate part. for (; currentChunkSpan < chunkCharacterSpans.length; currentChunkSpan++) { var chunkCharacterSpan = chunkCharacterSpans[currentChunkSpan]; if (gotOneMatchThisCandidate) { // We've already gotten one pattern part match in this candidate. We will // only continue trying to consumer pattern parts if the last part and this - // part are both upper case. + // part are both upper case. if (!isUpperCaseLetter(chunk.text.charCodeAt(chunkCharacterSpans[currentChunkSpan - 1].start)) || !isUpperCaseLetter(chunk.text.charCodeAt(chunkCharacterSpans[currentChunkSpan].start))) { break; @@ -33384,9 +33384,9 @@ var ts; ts.createPatternMatcher = createPatternMatcher; // Helper function to compare two matches to determine which is better. Matches are first // ordered by kind (so all prefix matches always beat all substring matches). Then, if the - // match is a camel case match, the relative weights of the match are used to determine - // which is better (with a greater weight being better). Then if the match is of the same - // type, then a case sensitive match is considered better than an insensitive one. + // match is a camel case match, the relative weights of the match are used to determine + // which is better (with a greater weight being better). Then if the match is of the same + // type, then a case sensitive match is considered better than an insensitive one. function patternMatchCompareTo(match1, match2) { return compareType(match1, match2) || compareCamelCase(match1, match2) || @@ -33436,7 +33436,7 @@ var ts; if (ch < 127 /* maxAsciiCharacter */ || !ts.isUnicodeIdentifierStart(ch, 2 /* Latest */)) { return false; } - // TODO: find a way to determine this for any unicode characters in a + // TODO: find a way to determine this for any unicode characters in a // non-allocating manner. var str = String.fromCharCode(ch); return str === str.toUpperCase(); @@ -33449,7 +33449,7 @@ var ts; if (ch < 127 /* maxAsciiCharacter */ || !ts.isUnicodeIdentifierStart(ch, 2 /* Latest */)) { return false; } - // TODO: find a way to determine this for any unicode characters in a + // TODO: find a way to determine this for any unicode characters in a // non-allocating manner. var str = String.fromCharCode(ch); return str === str.toLowerCase(); @@ -33498,7 +33498,7 @@ var ts; if (ch < 127 /* maxAsciiCharacter */) { return ch; } - // TODO: find a way to compute this for any unicode characters in a + // TODO: find a way to compute this for any unicode characters in a // non-allocating manner. return String.fromCharCode(ch).toLowerCase().charCodeAt(0); } @@ -33649,7 +33649,7 @@ var ts; var currentIsUpper = isUpperCaseLetter(identifier.charCodeAt(index)); // See if the casing indicates we're starting a new word. Note: if we're breaking on // words, then just seeing an upper case character isn't enough. Instead, it has to - // be uppercase and the previous character can't be uppercase. + // be uppercase and the previous character can't be uppercase. // // For example, breaking "AddMetadata" on words would make: Add Metadata // @@ -33673,9 +33673,9 @@ var ts; var SignatureHelp; (function (SignatureHelp) { // A partially written generic type expression is not guaranteed to have the correct syntax tree. the expression could be parsed as less than/greater than expression or a comma expression - // or some other combination depending on what the user has typed so far. For the purposes of signature help we need to consider any location after "<" as a possible generic type reference. - // To do this, the method will back parse the expression starting at the position required. it will try to parse the current expression as a generic type expression, if it did succeed it - // will return the generic identifier that started the expression (e.g. "foo" in "foo'. So, in the case where the last child is a comma, we increase the // arg count by one to compensate. // - // Note: this subtlety only applies to the last comma. If you had "Foo(a,," then - // we'll have: 'a' '' '' + // Note: this subtlety only applies to the last comma. If you had "Foo(a,," then + // we'll have: 'a' '' '' // That will give us 2 non-commas. We then add one for the last comma, givin us an // arg count of 3. var listChildren = argumentsList.getChildren(); @@ -34524,7 +34524,7 @@ var ts; var children = n.getChildren(); for (var _i = 0; _i < children.length; _i++) { var child = children[_i]; - var shouldDiveInChildNode = + var shouldDiveInChildNode = // previous token is enclosed somewhere in the child (child.pos <= previousToken.pos && child.end > previousToken.end) || // previous token ends exactly at the beginning of child @@ -34569,7 +34569,7 @@ var ts; } } ts.Debug.assert(startNode !== undefined || n.kind === 230 /* SourceFile */); - // Here we know that none of child token nodes embrace the position, + // Here we know that none of child token nodes embrace the position, // the only known case is when position is at the end of the file. // Try to find the rightmost token in the file without filtering. // Namely we are skipping the check: 'position < node.end' @@ -35031,9 +35031,9 @@ var ts; var startPos = (lastTokenInfo && lastTokenInfo.token.pos) || scanner.getStartPos(); return startPos < endPos && current !== 1 /* EndOfFileToken */ && !ts.isTrivia(current); } - // when containing node in the tree is token + // when containing node in the tree is token // but its kind differs from the kind that was returned by the scanner, - // then kind needs to be fixed. This might happen in cases + // then kind needs to be fixed. This might happen in cases // when parser interprets token differently, i.e keyword treated as identifier function fixTokenKind(tokenInfo, container) { if (ts.isToken(container) && tokenInfo.token.kind !== container.kind) { @@ -35555,17 +35555,17 @@ var ts; Rules.IsSameLineTokenOrBeforeMultilineBlockContext = function (context) { //// This check is mainly used inside SpaceBeforeOpenBraceInControl and SpaceBeforeOpenBraceInFunction. //// - //// Ex: + //// Ex: //// if (1) { .... //// * ) and { are on the same line so apply the rule. Here we don't care whether it's same or multi block context //// - //// Ex: + //// Ex: //// if (1) //// { ... } //// * ) and { are on differnet lines. We only need to format if the block is multiline context. So in this case we don't format. //// //// Ex: - //// if (1) + //// if (1) //// { ... //// } //// * ) and { are on differnet lines. We only need to format if the block is multiline context. So in this case we format. @@ -35841,9 +35841,9 @@ var ts; //// 4- Context rules with any token combination //// 5- Non-context rules with specific token combination //// 6- Non-context rules with any token combination - //// + //// //// The member rulesInsertionIndexBitmap is used to describe the number of rules - //// in each sub-bucket (above) hence can be used to know the index of where to insert + //// in each sub-bucket (above) hence can be used to know the index of where to insert //// the next rule. It's a bitmap which contains 6 different sections each is given 5 bits. //// //// Example: @@ -36037,7 +36037,7 @@ var ts; /// /// /// -/// +/// /// /* @internal */ var ts; @@ -36191,9 +36191,9 @@ var ts; } function findOutermostParent(position, expectedTokenKind, sourceFile) { var precedingToken = ts.findPrecedingToken(position, sourceFile); - // when it is claimed that trigger character was typed at given position + // when it is claimed that trigger character was typed at given position // we verify that there is a token with a matching kind whose end is equal to position (because the character was just typed). - // If this condition is not hold - then trigger character was typed in some other context, + // If this condition is not hold - then trigger character was typed in some other context, // i.e.in comment and thus should not trigger autoformatting if (!precedingToken || precedingToken.kind !== expectedTokenKind || @@ -36202,12 +36202,12 @@ var ts; } // walk up and search for the parent node that ends at the same position with precedingToken. // for cases like this - // + // // let x = 1; // while (true) { - // } + // } // after typing close curly in while statement we want to reformat just the while statement. - // However if we just walk upwards searching for the parent that has the same end value - + // However if we just walk upwards searching for the parent that has the same end value - // we'll end up with the whole source file. isListElement allows to stop on the list element level var current = precedingToken; while (current && @@ -36272,7 +36272,7 @@ var ts; // 'index' tracks the index of the most recent error that was checked. while (true) { if (index >= sorted.length) { - // all errors in the range were already checked -> no error in specified range + // all errors in the range were already checked -> no error in specified range return false; } var error = sorted[index]; @@ -36400,9 +36400,9 @@ var ts; var indentation = inheritedIndentation; if (indentation === -1 /* Unknown */) { if (isSomeBlock(node.kind)) { - // blocks should be indented in + // blocks should be indented in // - other blocks - // - source file + // - source file // - switch\default clauses if (isSomeBlock(parent.kind) || parent.kind === 230 /* SourceFile */ || @@ -36523,12 +36523,12 @@ var ts; // a useful observations when tracking context node // / // [a] - // / | \ + // / | \ // [b] [c] [d] - // node 'a' is a context node for nodes 'b', 'c', 'd' + // node 'a' is a context node for nodes 'b', 'c', 'd' // except for the leftmost leaf token in [b] - in this case context node ('e') is located somewhere above 'a' // this rule can be applied recursively to child nodes of 'a'. - // + // // context node is set to parent node value after processing every child node // context node is set to parent of the token after processing every token var childContextNode = contextNode; @@ -36630,7 +36630,7 @@ var ts; var tokenInfo = formattingScanner.readTokenInfo(parent); // consume the list end token only if it is still belong to the parent // there might be the case when current token matches end token but does not considered as one - // function (x: function) <-- + // function (x: function) <-- // without this check close paren will be interpreted as list end token for function expression which is wrong if (tokenInfo.token.kind === listEndToken && ts.rangeContainsRange(parent, tokenInfo.token)) { // consume list end token @@ -36747,7 +36747,7 @@ var ts; applyRuleEdits(rule, previousItem, previousStartLine, currentItem, currentStartLine); if (rule.Operation.Action & (2 /* Space */ | 8 /* Delete */) && currentStartLine !== previousStartLine) { lineAdded = false; - // Handle the case where the next line is moved to be the end of this line. + // Handle the case where the next line is moved to be the end of this line. // In this case we don't indent the next line in the next pass. if (currentParent.getStart(sourceFile) === currentItem.pos) { dynamicIndentation.recomputeIndentation(false); @@ -36755,7 +36755,7 @@ var ts; } else if (rule.Operation.Action & 4 /* NewLine */ && currentStartLine === previousStartLine) { lineAdded = true; - // Handle the case where token2 is moved to the new line. + // Handle the case where token2 is moved to the new line. // In this case we indent token2 in the next pass but we set // sameLineIndent flag to notify the indenter that the indentation is within the line. if (currentParent.getStart(sourceFile) === currentItem.pos) { @@ -37573,10 +37573,10 @@ var ts; var jsDocCommentParts = []; ts.forEach(declarations, function (declaration, indexOfDeclaration) { // Make sure we are collecting doc comment from declaration once, - // In case of union property there might be same declaration multiple times + // In case of union property there might be same declaration multiple times // which only varies in type parameter // Eg. let a: Array | Array; a.length - // The property length will have two declarations of property length coming + // The property length will have two declarations of property length coming // from Array - Array and Array if (ts.indexOf(declarations, declaration) === indexOfDeclaration) { var sourceFileOfDeclaration = ts.getSourceFileOfNode(declaration); @@ -37611,7 +37611,7 @@ var ts; return ts.map(ts.getJsDocComments(node, sourceFile), function (jsDocComment) { return { pos: jsDocComment.pos + "/*".length, - end: jsDocComment.end - "*/".length // Trim off comment end indicator + end: jsDocComment.end - "*/".length // Trim off comment end indicator }; }); } @@ -37713,7 +37713,7 @@ var ts; if (isParamTag(pos, end, sourceFile)) { var blankLineCount = 0; var recordedParamTag = false; - // Consume leading spaces + // Consume leading spaces pos = consumeWhiteSpaces(pos + paramTag.length); if (pos >= end) { break; @@ -37763,7 +37763,7 @@ var ts; var firstLineParamHelpStringPos = pos; while (pos < end) { var ch = sourceFile.text.charCodeAt(pos); - // at line break, set this comment line text and go to next line + // at line break, set this comment line text and go to next line if (ts.isLineBreak(ch)) { if (paramHelpString) { pushDocCommentLineText(paramDocComments, paramHelpString, blankLineCount); @@ -37816,7 +37816,7 @@ var ts; if (paramHelpStringMargin === undefined) { paramHelpStringMargin = sourceFile.getLineAndCharacterOfPosition(firstLineParamHelpStringPos).character; } - // Now consume white spaces max + // Now consume white spaces max var startOfLinePos = pos; pos = consumeWhiteSpacesOnTheLine(pos, end, sourceFile, paramHelpStringMargin); if (pos >= end) { @@ -37886,8 +37886,8 @@ var ts; }; SignatureObject.prototype.getDocumentationComment = function () { if (this.documentationComment === undefined) { - this.documentationComment = this.declaration ? getJsDocCommentsFromDeclarations([this.declaration], - /*name*/ undefined, + this.documentationComment = this.declaration ? getJsDocCommentsFromDeclarations([this.declaration], + /*name*/ undefined, /*canUseParsedParamTagComments*/ false) : []; } return this.documentationComment; @@ -38294,8 +38294,8 @@ var ts; return CancellationTokenObject; })(); ts.CancellationTokenObject = CancellationTokenObject; - // Cache host information about scrip Should be refreshed - // at each language service public entry point, since we don't know when + // Cache host information about scrip Should be refreshed + // at each language service public entry point, since we don't know when // set of scripts handled by the host changes. var HostCache = (function () { function HostCache(host, getCanonicalFileName) { @@ -38408,7 +38408,7 @@ var ts; options.isolatedModules = true; // Filename can be non-ts file. options.allowNonTsExtensions = true; - // We are not returning a sourceFile for lib file when asked by the program, + // We are not returning a sourceFile for lib file when asked by the program, // so pass --noLib to avoid reporting a file not found error. options.noLib = true; // We are not doing a full typecheck, we are not resolving the whole context, @@ -38461,7 +38461,7 @@ var ts; ts.createLanguageServiceSourceFile = createLanguageServiceSourceFile; ts.disableIncrementalParsing = false; function updateLanguageServiceSourceFile(sourceFile, scriptSnapshot, version, textChangeRange, aggressiveChecks) { - // If we were given a text change range, and our version or open-ness changed, then + // If we were given a text change range, and our version or open-ness changed, then // incrementally parse this file. if (textChangeRange) { if (version !== sourceFile.version) { @@ -38565,7 +38565,7 @@ var ts; bucket.set(fileName, entry); } else { - // We have an entry for this file. However, it may be for a different version of + // We have an entry for this file. However, it may be for a different version of // the script snapshot. If so, update it appropriately. Otherwise, we can just // return it as is. if (entry.sourceFile.version !== version) { @@ -39020,10 +39020,10 @@ var ts; if (programUpToDate()) { return; } - // IMPORTANT - It is critical from this moment onward that we do not check + // IMPORTANT - It is critical from this moment onward that we do not check // cancellation tokens. We are about to mutate source files from a previous program // instance. If we cancel midway through, we may end up in an inconsistent state where - // the program points to old source files that have been invalidated because of + // the program points to old source files that have been invalidated because of // incremental parsing. var oldSettings = program && program.getCompilerOptions(); var newSettings = hostCache.compilationSettings(); @@ -39039,7 +39039,7 @@ var ts; writeFile: function (fileName, data, writeByteOrderMark) { }, getCurrentDirectory: function () { return host.getCurrentDirectory(); } }); - // Release any files we have acquired in the old program but are + // Release any files we have acquired in the old program but are // not part of the new program. if (program) { var oldSourceFiles = program.getSourceFiles(); @@ -39055,7 +39055,7 @@ var ts; // It needs to be cleared to allow all collected snapshots to be released hostCache = undefined; program = newProgram; - // Make sure all the nodes in the program are both bound, and have their parent + // Make sure all the nodes in the program are both bound, and have their parent // pointers set property. program.getTypeChecker(); return; @@ -39075,7 +39075,7 @@ var ts; // Check if the old program had this file already var oldSourceFile = program && program.getSourceFile(fileName); if (oldSourceFile) { - // We already had a source file for this file name. Go to the registry to + // We already had a source file for this file name. Go to the registry to // ensure that we get the right up to date version of it. We need this to // address the following 'race'. Specifically, say we have the following: // @@ -39086,15 +39086,15 @@ var ts; // LS2 // // Each LS has a reference to file 'foo.ts' at version 1. LS2 then updates - // it's version of 'foo.ts' to version 2. This will cause LS2 and the - // DocumentRegistry to have version 2 of the document. HOwever, LS1 will + // it's version of 'foo.ts' to version 2. This will cause LS2 and the + // DocumentRegistry to have version 2 of the document. HOwever, LS1 will // have version 1. And *importantly* this source file will be *corrupt*. // The act of creating version 2 of the file irrevocably damages the version // 1 file. // // So, later when we call into LS1, we need to make sure that it doesn't use // it's source file any more, and instead defers to DocumentRegistry to get - // either version 1, version 2 (or some other version) depending on what the + // either version 1, version 2 (or some other version) depending on what the // host says should be used. return documentRegistry.updateDocument(fileName, newSettings, hostFileInformation.scriptSnapshot, hostFileInformation.version); } @@ -39153,7 +39153,7 @@ var ts; synchronizeHostData(); var targetSourceFile = getValidSourceFile(fileName); // For JavaScript files, we don't want to report the normal typescript semantic errors. - // Instead, we just report errors for using TypeScript-only constructs from within a + // Instead, we just report errors for using TypeScript-only constructs from within a // JavaScript file. if (ts.isJavaScript(fileName)) { return getJavaScriptSemanticDiagnostics(targetSourceFile); @@ -39398,8 +39398,8 @@ var ts; log("Returning an empty list because completion was requested in an invalid position."); return undefined; } - // Find the node where completion is requested on, in the case of a completion after - // a dot, it is the member access expression other wise, it is a request for all + // Find the node where completion is requested on, in the case of a completion after + // a dot, it is the member access expression other wise, it is a request for all // visible symbols in the scope, and the node is the current location. var node = currentToken; var isRightOfDot = false; @@ -39463,7 +39463,7 @@ var ts; } } if (isJavaScriptFile && type.flags & 16384 /* Union */) { - // In javascript files, for union types, we don't just get the members that + // In javascript files, for union types, we don't just get the members that // the individual types have in common, we also include all the members that // each individual type has. This is because we're going to add all identifiers // anyways. So we might as well elevate the members that were at least part @@ -39522,10 +39522,10 @@ var ts; // aggregating completion candidates. This is achieved in 'getScopeNode' // by finding the first node that encompasses a position, accounting for whether a node // is "complete" to decide whether a position belongs to the node. - // + // // However, at the end of an identifier, we are interested in the scope of the identifier // itself, but fall outside of the identifier. For instance: - // + // // xyz => x$ // // the cursor is outside of both the 'x' and the arrow function 'xyz => x', @@ -39574,7 +39574,7 @@ var ts; } function showCompletionsInImportsClause(node) { if (node) { - // import {| + // import {| // import {a,| if (node.kind === 14 /* OpenBraceToken */ || node.kind === 23 /* CommaToken */) { return node.parent.kind === 215 /* NamedImports */; @@ -39860,17 +39860,17 @@ var ts; return entries; } function createCompletionEntry(symbol, location) { - // Try to get a valid display name for this symbol, if we could not find one, then ignore it. + // Try to get a valid display name for this symbol, if we could not find one, then ignore it. // We would like to only show things that can be added after a dot, so for instance numeric properties can // not be accessed with a dot (a.1 <- invalid) var displayName = getCompletionEntryDisplayNameForSymbol(symbol, program.getCompilerOptions().target, true); if (!displayName) { return undefined; } - // TODO(drosen): Right now we just permit *all* semantic meanings when calling - // 'getSymbolKind' which is permissible given that it is backwards compatible; but + // TODO(drosen): Right now we just permit *all* semantic meanings when calling + // 'getSymbolKind' which is permissible given that it is backwards compatible; but // really we should consider passing the meaning for the node so that we don't report - // that a suggestion for a value is an interface. We COULD also just do what + // that a suggestion for a value is an interface. We COULD also just do what // 'getSymbolModifiers' does, which is to use the first declaration. // Use a 'sortText' of 0' so that all symbol completion entries come before any other // entries (like JavaScript identifier entries). @@ -39910,8 +39910,8 @@ var ts; var symbols = completionData.symbols, location_2 = completionData.location; // Find the symbol with the matching entry name. var target = program.getCompilerOptions().target; - // We don't need to perform character checks here because we're only comparing the - // name against 'entryName' (which is known to be good), not building a new + // We don't need to perform character checks here because we're only comparing the + // name against 'entryName' (which is known to be good), not building a new // completion entry. var symbol = ts.forEach(symbols, function (s) { return getCompletionEntryDisplayNameForSymbol(s, target, false) === entryName ? s : undefined; }); if (symbol) { @@ -40005,7 +40005,7 @@ var ts; ts.Debug.assert(!!(rootSymbolFlags & 8192 /* Method */)); }); if (!unionPropertyKind) { - // If this was union of all methods, + // If this was union of all methods, //make sure it has call signatures before we can label it as method var typeOfUnionProperty = typeChecker.getTypeOfSymbolAtLocation(symbol, location); if (typeOfUnionProperty.getCallSignatures().length) { @@ -40068,7 +40068,7 @@ var ts; var useConstructSignatures = callExpression.kind === 161 /* NewExpression */ || callExpression.expression.kind === 91 /* SuperKeyword */; var allSignatures = useConstructSignatures ? type.getConstructSignatures() : type.getCallSignatures(); if (!ts.contains(allSignatures, signature.target || signature)) { - // Get the first signature if there + // Get the first signature if there signature = allSignatures.length ? allSignatures[0] : undefined; } if (signature) { @@ -40411,7 +40411,7 @@ var ts; var containerName = containerSymbol ? typeChecker.symbolToString(containerSymbol, node) : ""; if (!tryAddConstructSignature(symbol, node, symbolKind, symbolName, containerName, result) && !tryAddCallSignature(symbol, node, symbolKind, symbolName, containerName, result)) { - // Just add all the declarations. + // Just add all the declarations. ts.forEach(declarations, function (declaration) { result.push(createDefinitionInfo(declaration, symbolKind, symbolName, containerName)); }); @@ -40506,7 +40506,7 @@ var ts; } // Because name in short-hand property assignment has two different meanings: property name and property value, // using go-to-definition at such position should go to the variable declaration of the property value rather than - // go to the declaration of the property name (in this case stay at the same position). However, if go-to-definition + // go to the declaration of the property name (in this case stay at the same position). However, if go-to-definition // is performed at the location of property access, we would like to go to definition of the property in the short-hand // assignment. This case and others are handled by the following code. if (node.parent.kind === 228 /* ShorthandPropertyAssignment */) { @@ -40557,7 +40557,7 @@ var ts; var results = getOccurrencesAtPositionCore(fileName, position); if (results) { var sourceFile = getCanonicalFileName(ts.normalizeSlashes(fileName)); - // Get occurrences only supports reporting occurrences for the file queried. So + // Get occurrences only supports reporting occurrences for the file queried. So // filter down to that list. results = ts.filter(results, function (r) { return getCanonicalFileName(ts.normalizeSlashes(r.fileName)) === sourceFile; }); } @@ -40677,7 +40677,7 @@ var ts; case 66 /* BreakKeyword */: case 71 /* ContinueKeyword */: if (hasKind(node.parent, 193 /* BreakStatement */) || hasKind(node.parent, 192 /* ContinueStatement */)) { - return getBreakOrContinueStatementOccurences(node.parent); + return getBreakOrContinueStatementOccurrences(node.parent); } break; case 82 /* ForKeyword */: @@ -40942,7 +40942,7 @@ var ts; }); return ts.map(keywords, getHighlightSpanForNode); } - function getBreakOrContinueStatementOccurences(breakOrContinueStatement) { + function getBreakOrContinueStatementOccurrences(breakOrContinueStatement) { var owner = getBreakOrContinueOwner(breakOrContinueStatement); if (owner) { switch (owner.kind) { @@ -41329,12 +41329,12 @@ var ts; // If we are past the end, stop looking if (position > end) break; - // We found a match. Make sure it's not part of a larger word (i.e. the char + // We found a match. Make sure it's not part of a larger word (i.e. the char // before and after it have to be a non-identifier char). var endPosition = position + symbolNameLength; if ((position === 0 || !ts.isIdentifierPart(text.charCodeAt(position - 1), 2 /* Latest */)) && (endPosition === sourceLength || !ts.isIdentifierPart(text.charCodeAt(endPosition), 2 /* Latest */))) { - // Found a real match. Keep searching. + // Found a real match. Keep searching. positions.push(position); } position = text.indexOf(symbolName, position + symbolNameLength + 1); @@ -41405,7 +41405,7 @@ var ts; cancellationToken.throwIfCancellationRequested(); var referenceLocation = ts.getTouchingPropertyName(sourceFile, position); if (!isValidReferencePosition(referenceLocation, searchText)) { - // This wasn't the start of a token. Check to see if it might be a + // This wasn't the start of a token. Check to see if it might be a // match in a comment or string if that's what the caller is asking // for. if ((findInStrings && isInString(position)) || @@ -41697,7 +41697,7 @@ var ts; return aliasedSymbol; } } - // If the reference location is in an object literal, try to get the contextual type for the + // If the reference location is in an object literal, try to get the contextual type for the // object literal, lookup the property symbol in the contextual type, and use this symbol to // compare to our searchSymbol if (isNameOfPropertyAssignment(referenceLocation)) { @@ -41712,7 +41712,7 @@ var ts; if (searchSymbols.indexOf(rootSymbol) >= 0) { return rootSymbol; } - // Finally, try all properties with the same name in any type the containing type extended or implemented, and + // Finally, try all properties with the same name in any type the containing type extended or implemented, and // see if any is in the list if (rootSymbol.parent && rootSymbol.parent.flags & (32 /* Class */ | 64 /* Interface */)) { var result_3 = []; @@ -42009,7 +42009,7 @@ var ts; } else if (isNameOfModuleDeclaration(nodeForStartPos)) { // If this is name of a module declarations, check if this is right side of dotted module name - // If parent of the module declaration which is parent of this node is module declaration and its body is the module declaration that this node is name of + // If parent of the module declaration which is parent of this node is module declaration and its body is the module declaration that this node is name of // Then this name is name from dotted module if (nodeForStartPos.parent.parent.kind === 208 /* ModuleDeclaration */ && nodeForStartPos.parent.parent.body === nodeForStartPos.parent) { @@ -42227,7 +42227,7 @@ var ts; for (var _i = 0, _a = docComment.tags; _i < _a.length; _i++) { var tag = _a[_i]; // As we walk through each tag, classify the portion of text from the end of - // the last tag (or the start of the entire doc comment) as 'comment'. + // the last tag (or the start of the entire doc comment) as 'comment'. if (tag.pos !== pos) { pushCommentRange(pos, tag.pos - pos); } @@ -42279,7 +42279,7 @@ var ts; } } function classifyDisabledMergeCode(text, start, end) { - // Classify the line that the ======= marker is on as a comment. Then just lex + // Classify the line that the ======= marker is on as a comment. Then just lex // all further tokens and add them to the result. for (var i = start; i < end; i++) { if (ts.isLineBreak(text.charCodeAt(i))) { @@ -42310,7 +42310,7 @@ var ts; } } } - // for accurate classification, the actual token should be passed in. however, for + // for accurate classification, the actual token should be passed in. however, for // cases like 'disabled merge code' classification, we just get the token kind and // classify based on that instead. function classifyTokenType(tokenKind, token) { @@ -42495,11 +42495,11 @@ var ts; return []; } function getTodoComments(fileName, descriptors) { - // Note: while getting todo comments seems like a syntactic operation, we actually + // Note: while getting todo comments seems like a syntactic operation, we actually // treat it as a semantic operation here. This is because we expect our host to call // this on every single file. If we treat this syntactically, then that will cause // us to populate and throw away the tree in our syntax tree cache for each file. By - // treating this as a semantic operation, we can access any tree without throwing + // treating this as a semantic operation, we can access any tree without throwing // anything away. synchronizeHostData(); var sourceFile = getValidSourceFile(fileName); @@ -42523,7 +42523,7 @@ var ts; // 0) The full match for the entire regexp. // 1) The preamble to the message portion. // 2) The message portion. - // 3...N) The descriptor that was matched - by index. 'undefined' for each + // 3...N) The descriptor that was matched - by index. 'undefined' for each // descriptor that didn't match. an actual value if it did match. // // i.e. 'undefined' in position 3 above means TODO(jason) didn't match. @@ -42545,7 +42545,7 @@ var ts; } } ts.Debug.assert(descriptor !== undefined); - // We don't want to match something like 'TODOBY', so we make sure a non + // We don't want to match something like 'TODOBY', so we make sure a non // letter/digit follows the match. if (isLetterOrDigit(fileContents.charCodeAt(matchPosition + descriptor.text.length))) { continue; @@ -42590,10 +42590,10 @@ var ts; // (?:(TODO\(jason\))|(HACK)) // // Note that the outermost group is *not* a capture group, but the innermost groups - // *are* capture groups. By capturing the inner literals we can determine after + // *are* capture groups. By capturing the inner literals we can determine after // matching which descriptor we are dealing with. var literals = "(?:" + ts.map(descriptors, function (d) { return "(" + escapeRegExp(d.text) + ")"; }).join("|") + ")"; - // After matching a descriptor literal, the following regexp matches the rest of the + // After matching a descriptor literal, the following regexp matches the rest of the // text up to the end of the line (or */). var endOfLineOrEndOfComment = /(?:$|\*\/)/.source; var messageRemainder = /(?:.*?)/.source; @@ -42753,7 +42753,7 @@ var ts; var scanner = ts.createScanner(2 /* Latest */, false); /// We do not have a full parser support to know when we should parse a regex or not /// If we consider every slash token to be a regex, we could be missing cases like "1/2/3", where - /// we have a series of divide operator. this list allows us to be more accurate by ruling out + /// we have a series of divide operator. this list allows us to be more accurate by ruling out /// locations where a regexp cannot exist. var noRegexTable = []; noRegexTable[65 /* Identifier */] = true; @@ -42796,7 +42796,7 @@ var ts; keyword2 === 122 /* SetKeyword */ || keyword2 === 114 /* ConstructorKeyword */ || keyword2 === 109 /* StaticKeyword */) { - // Allow things like "public get", "public constructor" and "public static". + // Allow things like "public get", "public constructor" and "public static". // These are all legal. return true; } @@ -42913,12 +42913,12 @@ var ts; // token. So the classification will go back to being an identifier. The moment the user // types again, number will become a keyword, then an identifier, etc. etc. // - // To try to avoid this problem, we avoid classifying contextual keywords as keywords + // To try to avoid this problem, we avoid classifying contextual keywords as keywords // when the user is potentially typing something generic. We just can't do a good enough // job at the lexical level, and so well leave it up to the syntactic classifier to make // the determination. // - // In order to determine if the user is potentially typing something generic, we use a + // In order to determine if the user is potentially typing something generic, we use a // weak heuristic where we track < and > tokens. It's a weak heuristic, but should // work well enough in practice. var angleBracketStack = 0; @@ -42934,7 +42934,7 @@ var ts; token = 65 /* Identifier */; } else if (isKeyword(lastNonTriviaToken) && isKeyword(token) && !canFollow(lastNonTriviaToken, token)) { - // We have two keywords in a row. Only treat the second as a keyword if + // We have two keywords in a row. Only treat the second as a keyword if // it's a sequence that could legally occur in the language. Otherwise // treat it as an identifier. This way, if someone writes "private var" // we recognize that 'var' is actually an identifier here. @@ -42942,7 +42942,7 @@ var ts; } else if (lastNonTriviaToken === 65 /* Identifier */ && token === 24 /* LessThanToken */) { - // Could be the start of something generic. Keep track of that by bumping + // Could be the start of something generic. Keep track of that by bumping // up the current count of generic contexts we may be in. angleBracketStack++; } @@ -42957,7 +42957,7 @@ var ts; token === 113 /* BooleanKeyword */ || token === 124 /* SymbolKeyword */) { if (angleBracketStack > 0 && !syntacticClassifierAbsent) { - // If it looks like we're could be in something generic, don't classify this + // If it looks like we're could be in something generic, don't classify this // as a keyword. We may just get overwritten by the syntactic classifier, // causing a noisy experience for the user. token = 65 /* Identifier */; @@ -43052,8 +43052,8 @@ var ts; return; } if (start === 0 && offset > 0) { - // We're classifying the first token, and this was a case where we prepended - // text. We should consider the start of this token to be at the start of + // We're classifying the first token, and this was a case where we prepended + // text. We should consider the start of this token to be at the start of // the original text. start += offset; } @@ -43200,7 +43200,7 @@ var ts; } initializeServices(); })(ts || (ts = {})); -// Copyright (c) Microsoft. All rights reserved. Licensed under the Apache License, Version 2.0. +// Copyright (c) Microsoft. All rights reserved. Licensed under the Apache License, Version 2.0. // See LICENSE.txt in the project root for complete license information. /// /* @internal */ @@ -43221,8 +43221,8 @@ var ts; if (sourceFile.getLineAndCharacterOfPosition(tokenAtLocation.getStart()).line > lineOfPosition) { // Get previous token if the token is returned starts on new line // eg: let x =10; |--- cursor is here - // let y = 10; - // token at position will return let keyword on second line as the token but we would like to use + // let y = 10; + // token at position will return let keyword on second line as the token but we would like to use // token on same line if trailing trivia (comments or white spaces on same line) part of the last token on that line tokenAtLocation = ts.findPrecedingToken(tokenAtLocation.pos, sourceFile); // Its a blank line diff --git a/src/typings/electron.d.ts b/src/typings/electron.d.ts index 05aab3a8161..156e175b1d5 100644 --- a/src/typings/electron.d.ts +++ b/src/typings/electron.d.ts @@ -584,7 +584,7 @@ declare namespace Electron { /** * ok - Nothing went wrong. - * error - One or more errors occured, enable runtime logging to figure out the likely cause. + * error - One or more errors occurred, enable runtime logging to figure out the likely cause. * invalidSeparatorError - An attempt was made to add a separator to a custom category in the Jump List. * Separators are only allowed in the standard Tasks category. * fileTypeRegistrationError - An attempt was made to add a file link to the Jump List diff --git a/src/vs/base/common/errorMessage.ts b/src/vs/base/common/errorMessage.ts index 9f5ed7fda90..3c882cba229 100644 --- a/src/vs/base/common/errorMessage.ts +++ b/src/vs/base/common/errorMessage.ts @@ -165,7 +165,7 @@ function detectSystemErrorMessage(exception: any): string { // See https://nodejs.org/api/errors.html#errors_class_system_error if (typeof exception.code === 'string' && typeof exception.errno === 'number' && typeof exception.syscall === 'string') { - return nls.localize('nodeExceptionMessage', "A system error occured ({0})", exception.message); + return nls.localize('nodeExceptionMessage', "A system error occurred ({0})", exception.message); } return exception.message; diff --git a/src/vs/base/common/marked/raw.marked.js b/src/vs/base/common/marked/raw.marked.js index ce02369727a..589c066b34e 100644 --- a/src/vs/base/common/marked/raw.marked.js +++ b/src/vs/base/common/marked/raw.marked.js @@ -1213,7 +1213,7 @@ function marked(src, opt, callback) { } catch (e) { e.message += '\nPlease report this to https://github.com/chjj/marked.'; if ((opt || marked.defaults).silent) { - return '

    An error occured:

    '
    +      return '

    An error occurred:

    '
             + escape(e.message + '', true)
             + '
    '; } diff --git a/src/vs/editor/browser/controller/mouseHandler.ts b/src/vs/editor/browser/controller/mouseHandler.ts index cc44acdd62d..60ff6e4d650 100644 --- a/src/vs/editor/browser/controller/mouseHandler.ts +++ b/src/vs/editor/browser/controller/mouseHandler.ts @@ -185,7 +185,7 @@ export class MouseHandler extends ViewEventHandler { } let actualMouseMoveTime = e.timestamp; if (actualMouseMoveTime < this.lastMouseLeaveTime) { - // Due to throttling, this event occured before the mouse left the editor, therefore ignore it. + // Due to throttling, this event occurred before the mouse left the editor, therefore ignore it. return; } diff --git a/src/vs/editor/browser/standalone/standaloneLanguages.ts b/src/vs/editor/browser/standalone/standaloneLanguages.ts index 0750a1db0a9..654a43b5f0e 100644 --- a/src/vs/editor/browser/standalone/standaloneLanguages.ts +++ b/src/vs/editor/browser/standalone/standaloneLanguages.ts @@ -290,7 +290,7 @@ export function registerDocumentSymbolProvider(languageId: string, provider: mod } /** - * Register a document highlight provider (used by e.g. highlight occurences). + * Register a document highlight provider (used by e.g. highlight occurrences). */ export function registerDocumentHighlightProvider(languageId: string, provider: modes.DocumentHighlightProvider): IDisposable { return modes.DocumentHighlightProviderRegistry.register(languageId, provider); diff --git a/src/vs/editor/common/controller/cursorTypeOperations.ts b/src/vs/editor/common/controller/cursorTypeOperations.ts index 6abac0a543e..7793fe670ce 100644 --- a/src/vs/editor/common/controller/cursorTypeOperations.ts +++ b/src/vs/editor/common/controller/cursorTypeOperations.ts @@ -239,7 +239,7 @@ export class TypeOperations { const selection = selections[i]; if (!selection.isEmpty()) { // looks like https://github.com/Microsoft/vscode/issues/2773 - // where a cursor operation occured before a canceled composition + // where a cursor operation occurred before a canceled composition // => ignore composition commands[i] = null; continue; diff --git a/src/vs/editor/contrib/find/common/findController.ts b/src/vs/editor/contrib/find/common/findController.ts index a5dae70a8dc..b1195ab30f4 100644 --- a/src/vs/editor/contrib/find/common/findController.ts +++ b/src/vs/editor/contrib/find/common/findController.ts @@ -862,7 +862,7 @@ export class SelectHighlightsAction extends AbstractSelectHighlightsAction { constructor() { super({ id: 'editor.action.selectHighlights', - label: nls.localize('selectAllOccurencesOfFindMatch', "Select All Occurrences of Find Match"), + label: nls.localize('selectAllOccurrencesOfFindMatch', "Select All Occurrences of Find Match"), alias: 'Select All Occurrences of Find Match', precondition: null, kbOpts: { @@ -1005,10 +1005,10 @@ export class SelectionHighlighter extends Disposable implements editorCommon.IEd return null; } - const hasFindOccurences = DocumentHighlightProviderRegistry.has(model); + const hasFindOccurrences = DocumentHighlightProviderRegistry.has(model); if (r.currentMatch) { // This is an empty selection - if (hasFindOccurences) { + if (hasFindOccurrences) { // Do not interfere with semantic word highlighting in the no selection case return null; } @@ -1070,7 +1070,7 @@ export class SelectionHighlighter extends Disposable implements editorCommon.IEd } const model = this.editor.getModel(); - const hasFindOccurences = DocumentHighlightProviderRegistry.has(model); + const hasFindOccurrences = DocumentHighlightProviderRegistry.has(model); let allMatches = model.findMatches(this.state.searchText, true, false, this.state.matchCase, this.state.wordSeparators, false).map(m => m.range); allMatches.sort(Range.compareRangesUsingStarts); @@ -1108,7 +1108,7 @@ export class SelectionHighlighter extends Disposable implements editorCommon.IEd return { range: r, // Show in overviewRuler only if model has no semantic highlighting - options: (hasFindOccurences ? SelectionHighlighter._SELECTION_HIGHLIGHT : SelectionHighlighter._SELECTION_HIGHLIGHT_OVERVIEW) + options: (hasFindOccurrences ? SelectionHighlighter._SELECTION_HIGHLIGHT : SelectionHighlighter._SELECTION_HIGHLIGHT_OVERVIEW) }; }); diff --git a/src/vs/editor/contrib/find/test/common/findController.test.ts b/src/vs/editor/contrib/find/test/common/findController.test.ts index aa2fb4de23d..20559f5713b 100644 --- a/src/vs/editor/contrib/find/test/common/findController.test.ts +++ b/src/vs/editor/contrib/find/test/common/findController.test.ts @@ -215,7 +215,7 @@ suite('FindController', () => { }); }); - test('issue #5400: "Select All Occurences of Find Match" does not select all if find uses regex', () => { + test('issue #5400: "Select All Occurrences of Find Match" does not select all if find uses regex', () => { withMockCodeEditor([ 'something', 'someething', diff --git a/src/vs/editor/contrib/links/browser/links.ts b/src/vs/editor/contrib/links/browser/links.ts index c50fc2e0c43..0e82f55cca3 100644 --- a/src/vs/editor/contrib/links/browser/links.ts +++ b/src/vs/editor/contrib/links/browser/links.ts @@ -58,7 +58,7 @@ const decoration = { }), }; -class LinkOccurence { +class LinkOccurrence { public static decoration(link: Link, useMetaKey: boolean): editorCommon.IModelDeltaDecoration { return { @@ -68,7 +68,7 @@ class LinkOccurence { endLineNumber: link.range.endLineNumber, endColumn: link.range.endColumn }, - options: LinkOccurence._getOptions(useMetaKey, false) + options: LinkOccurrence._getOptions(useMetaKey, false) }; } @@ -88,11 +88,11 @@ class LinkOccurence { } public activate(changeAccessor: editorCommon.IModelDecorationsChangeAccessor, useMetaKey: boolean): void { - changeAccessor.changeDecorationOptions(this.decorationId, LinkOccurence._getOptions(useMetaKey, true)); + changeAccessor.changeDecorationOptions(this.decorationId, LinkOccurrence._getOptions(useMetaKey, true)); } public deactivate(changeAccessor: editorCommon.IModelDecorationsChangeAccessor, useMetaKey: boolean): void { - changeAccessor.changeDecorationOptions(this.decorationId, LinkOccurence._getOptions(useMetaKey, false)); + changeAccessor.changeDecorationOptions(this.decorationId, LinkOccurrence._getOptions(useMetaKey, false)); } } @@ -115,7 +115,7 @@ class LinkDetector implements editorCommon.IEditorContribution { private openerService: IOpenerService; private messageService: IMessageService; private editorWorkerService: IEditorWorkerService; - private currentOccurences: { [decorationId: string]: LinkOccurence; }; + private currentOccurrences: { [decorationId: string]: LinkOccurrence; }; constructor( editor: ICodeEditor, @@ -148,7 +148,7 @@ class LinkDetector implements editorCommon.IEditorContribution { this.timeoutPromise = null; this.computePromise = null; - this.currentOccurences = {}; + this.currentOccurrences = {}; this.activeLinkDecorationId = null; this.beginCompute(); } @@ -162,7 +162,7 @@ class LinkDetector implements editorCommon.IEditorContribution { } private onModelChanged(): void { - this.currentOccurences = {}; + this.currentOccurrences = {}; this.activeLinkDecorationId = null; this.stop(); this.beginCompute(); @@ -202,10 +202,10 @@ class LinkDetector implements editorCommon.IEditorContribution { const useMetaKey = (this.editor.getConfiguration().multiCursorModifier === 'altKey'); this.editor.changeDecorations((changeAccessor: editorCommon.IModelDecorationsChangeAccessor) => { var oldDecorations: string[] = []; - let keys = Object.keys(this.currentOccurences); + let keys = Object.keys(this.currentOccurrences); for (let i = 0, len = keys.length; i < len; i++) { let decorationId = keys[i]; - let occurance = this.currentOccurences[decorationId]; + let occurance = this.currentOccurrences[decorationId]; oldDecorations.push(occurance.decorationId); } @@ -213,17 +213,17 @@ class LinkDetector implements editorCommon.IEditorContribution { if (links) { // Not sure why this is sometimes null for (var i = 0; i < links.length; i++) { - newDecorations.push(LinkOccurence.decoration(links[i], useMetaKey)); + newDecorations.push(LinkOccurrence.decoration(links[i], useMetaKey)); } } var decorations = changeAccessor.deltaDecorations(oldDecorations, newDecorations); - this.currentOccurences = {}; + this.currentOccurrences = {}; this.activeLinkDecorationId = null; for (let i = 0, len = decorations.length; i < len; i++) { - var occurance = new LinkOccurence(links[i], decorations[i]); - this.currentOccurences[occurance.decorationId] = occurance; + var occurance = new LinkOccurrence(links[i], decorations[i]); + this.currentOccurrences[occurance.decorationId] = occurance; } }); } @@ -232,11 +232,11 @@ class LinkDetector implements editorCommon.IEditorContribution { const useMetaKey = (this.editor.getConfiguration().multiCursorModifier === 'altKey'); if (this.isEnabled(mouseEvent, withKey)) { this.cleanUpActiveLinkDecoration(); // always remove previous link decoration as their can only be one - var occurence = this.getLinkOccurence(mouseEvent.target.position); - if (occurence) { + var occurrence = this.getLinkOccurrence(mouseEvent.target.position); + if (occurrence) { this.editor.changeDecorations((changeAccessor) => { - occurence.activate(changeAccessor, useMetaKey); - this.activeLinkDecorationId = occurence.decorationId; + occurrence.activate(changeAccessor, useMetaKey); + this.activeLinkDecorationId = occurrence.decorationId; }); } } else { @@ -247,10 +247,10 @@ class LinkDetector implements editorCommon.IEditorContribution { private cleanUpActiveLinkDecoration(): void { const useMetaKey = (this.editor.getConfiguration().multiCursorModifier === 'altKey'); if (this.activeLinkDecorationId) { - var occurence = this.currentOccurences[this.activeLinkDecorationId]; - if (occurence) { + var occurrence = this.currentOccurrences[this.activeLinkDecorationId]; + if (occurrence) { this.editor.changeDecorations((changeAccessor) => { - occurence.deactivate(changeAccessor, useMetaKey); + occurrence.deactivate(changeAccessor, useMetaKey); }); } @@ -262,20 +262,20 @@ class LinkDetector implements editorCommon.IEditorContribution { if (!this.isEnabled(mouseEvent)) { return; } - var occurence = this.getLinkOccurence(mouseEvent.target.position); - if (!occurence) { + var occurrence = this.getLinkOccurrence(mouseEvent.target.position); + if (!occurrence) { return; } - this.openLinkOccurence(occurence, mouseEvent.hasSideBySideModifier); + this.openLinkOccurrence(occurrence, mouseEvent.hasSideBySideModifier); } - public openLinkOccurence(occurence: LinkOccurence, openToSide: boolean): void { + public openLinkOccurrence(occurrence: LinkOccurrence, openToSide: boolean): void { if (!this.openerService) { return; } - const { link } = occurence; + const { link } = occurrence; link.resolve().then(uri => { // open the uri @@ -293,7 +293,7 @@ class LinkDetector implements editorCommon.IEditorContribution { }).done(null, onUnexpectedError); } - public getLinkOccurence(position: Position): LinkOccurence { + public getLinkOccurrence(position: Position): LinkOccurrence { var decorations = this.editor.getModel().getDecorationsInRange({ startLineNumber: position.lineNumber, startColumn: position.column, @@ -303,9 +303,9 @@ class LinkDetector implements editorCommon.IEditorContribution { for (var i = 0; i < decorations.length; i++) { var decoration = decorations[i]; - var currentOccurence = this.currentOccurences[decoration.id]; - if (currentOccurence) { - return currentOccurence; + var currentOccurrence = this.currentOccurrences[decoration.id]; + if (currentOccurrence) { + return currentOccurrence; } } @@ -354,9 +354,9 @@ class OpenLinkAction extends EditorAction { return; } - let link = linkDetector.getLinkOccurence(editor.getPosition()); + let link = linkDetector.getLinkOccurrence(editor.getPosition()); if (link) { - linkDetector.openLinkOccurence(link, false); + linkDetector.openLinkOccurrence(link, false); } } } diff --git a/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.ts b/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.ts index 0aa87cb7282..52b6d50d151 100644 --- a/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.ts +++ b/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.ts @@ -188,8 +188,8 @@ class WordHighlighter { } // All the effort below is trying to achieve this: - // - when cursor is moved to a word, trigger immediately a findOccurences request - // - 250ms later after the last cursor move event, render the occurences + // - when cursor is moved to a word, trigger immediately a findOccurrences request + // - 250ms later after the last cursor move event, render the occurrences // - no flickering! var currentWordRange = new Range(lineNumber, word.startColumn, lineNumber, word.endColumn); diff --git a/src/vs/monaco.d.ts b/src/vs/monaco.d.ts index cdb3e52fee3..1f0ec636fd9 100644 --- a/src/vs/monaco.d.ts +++ b/src/vs/monaco.d.ts @@ -3954,7 +3954,7 @@ declare module monaco.languages { export function registerDocumentSymbolProvider(languageId: string, provider: DocumentSymbolProvider): IDisposable; /** - * Register a document highlight provider (used by e.g. highlight occurences). + * Register a document highlight provider (used by e.g. highlight occurrences). */ export function registerDocumentHighlightProvider(languageId: string, provider: DocumentHighlightProvider): IDisposable; diff --git a/src/vs/platform/files/common/files.ts b/src/vs/platform/files/common/files.ts index 94d4d0295dd..099b40f2dbf 100644 --- a/src/vs/platform/files/common/files.ts +++ b/src/vs/platform/files/common/files.ts @@ -191,7 +191,7 @@ export enum FileChangeType { export interface IFileChange { /** - * The type of change that occured to the file. + * The type of change that occurred to the file. */ type: FileChangeType; diff --git a/src/vs/platform/search/common/replace.ts b/src/vs/platform/search/common/replace.ts index e57e23c1034..647b5d51a0d 100644 --- a/src/vs/platform/search/common/replace.ts +++ b/src/vs/platform/search/common/replace.ts @@ -175,7 +175,7 @@ export class ReplacePattern { } if (substrFrom === 0) { - // no replacement occured + // no replacement occurred return; } diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index b450e6538e6..0066f0146f6 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -145,7 +145,7 @@ export function createApiFactory( console.warn('Edits from command ' + id + ' were not applied.'); } }, (err) => { - console.warn('An error occured while running command ' + id, err); + console.warn('An error occurred while running command ' + id, err); }); }); }, diff --git a/src/vs/workbench/services/configurationResolver/node/configurationResolverService.ts b/src/vs/workbench/services/configurationResolver/node/configurationResolverService.ts index 3caa6312379..7dcd63979b0 100644 --- a/src/vs/workbench/services/configurationResolver/node/configurationResolverService.ts +++ b/src/vs/workbench/services/configurationResolver/node/configurationResolverService.ts @@ -214,7 +214,7 @@ export class ConfigurationResolverService implements IConfigurationResolverServi } // We need a map from interactive variables to keys because we only want to trigger an command once per key - - // even though it might occure multiple times in configuration #7026. + // even though it might occur multiple times in configuration #7026. const interactiveVariablesToSubstitutes: { [interactiveVariable: string]: { object: any, key: string }[] } = {}; const findInteractiveVariables = (object: any) => { Object.keys(object).forEach(key => { -- GitLab From 354042ac2ac6f2efffa43f6fa5bf6ac49335ebf5 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Mon, 12 Jun 2017 15:27:13 -0700 Subject: [PATCH 0736/1347] :lipstick: --- .../electron-browser/terminalActions.ts | 1 - .../electron-browser/terminalInstance.ts | 19 ++++++++++--------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts index 1c7a798b747..6ead524b144 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts @@ -581,6 +581,5 @@ export class RenameTerminalAction extends Action { terminalInstance.setTitle(name); } }); - } } diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index 2909a276483..abf9d69364d 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -62,7 +62,6 @@ export class TerminalInstance implements ITerminalInstance { private _isDisposed: boolean; private _onDisposed: Emitter; private _onDataForApi: Emitter<{ instance: ITerminalInstance, data: string }>; - private _onMessageTitleCheck: (message: any) => void; private _onProcessIdReady: Emitter; private _onTitleChanged: Emitter; private _process: cp.ChildProcess; @@ -77,6 +76,7 @@ export class TerminalInstance implements ITerminalInstance { private _terminalHasTextContextKey: IContextKey; private _cols: number; private _rows: number; + private _messageTitleListener: (message: { type: string, content: string }) => void; private _widgetManager: TerminalWidgetManager; private _linkHandler: TerminalLinkHandler; @@ -495,13 +495,13 @@ export class TerminalInstance implements ITerminalInstance { }); if (!shell.name) { // Only listen for process title changes when a name is not provided - this._onMessageTitleCheck = (message) => { + this._messageTitleListener = (message) => { if (message.type === 'title') { this._title = message.content ? message.content : ''; this._onTitleChanged.fire(this._title); } }; - this._process.on('message', this._onMessageTitleCheck); + this._process.on('message', this._messageTitleListener); } this._process.on('message', (message) => { if (message.type === 'pid') { @@ -782,15 +782,16 @@ export class TerminalInstance implements ITerminalInstance { } public setTitle(title: string): void { - const oldTitle = this._title; - if (title !== oldTitle) { - this._title = title; + const didTitleChange = title !== this._title; + if (didTitleChange) { this._onTitleChanged.fire(title); } - // if the title is set via API, unregister the handler that automatically updates the terminal name - if (this._process) { - this._process.removeListener('message', this._onMessageTitleCheck); + // If the title was not set by the API, unregister the handler that + // automatically updates the terminal name + if (this._process && this._messageTitleListener) { + this._process.removeListener('message', this._messageTitleListener); + this._messageTitleListener = null; } } } -- GitLab From 01fa0b83e90bd454ada93e4a0cb439db474c5ac2 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Mon, 12 Jun 2017 15:27:37 -0700 Subject: [PATCH 0737/1347] Fixing cancellation errors for TS. Fixes #28501 --- extensions/typescript/src/typescriptServiceClient.ts | 8 ++++++-- extensions/typescript/src/utils/electron.ts | 8 ++++++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/extensions/typescript/src/typescriptServiceClient.ts b/extensions/typescript/src/typescriptServiceClient.ts index 6d604437626..0afd4d6d491 100644 --- a/extensions/typescript/src/typescriptServiceClient.ts +++ b/extensions/typescript/src/typescriptServiceClient.ts @@ -497,7 +497,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient args.push('--enableTelemetry'); } if (this.apiVersion.has222Features()) { - this.cancellationPipeName = electron.getPipeName(`tscancellation-${electron.makeRandomHexString(20)}`); + this.cancellationPipeName = electron.getTempFile(`tscancellation-${electron.makeRandomHexString(20)}`); args.push('--cancellationPipeName', this.cancellationPipeName + '*'); } @@ -947,7 +947,11 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient if (this.apiVersion.has222Features() && this.cancellationPipeName) { this.tracer.logTrace(`TypeScript Service: trying to cancel ongoing request with sequence number ${seq}`); - fs.writeFileSync(this.cancellationPipeName + seq, ''); + try { + fs.writeFileSync(this.cancellationPipeName + seq, ''); + } catch (e) { + // noop + } return true; } diff --git a/extensions/typescript/src/utils/electron.ts b/extensions/typescript/src/utils/electron.ts index 4418ca51dbd..46ad56c464a 100644 --- a/extensions/typescript/src/utils/electron.ts +++ b/extensions/typescript/src/utils/electron.ts @@ -27,8 +27,7 @@ export function makeRandomHexString(length: number): string { function generatePipeName(): string { return getPipeName(makeRandomHexString(40)); } - -export function getPipeName(name: string): string { +function getPipeName(name: string): string { const fullName = 'vscode-' + name; if (process.platform === 'win32') { return '\\\\.\\pipe\\' + fullName + '-sock'; @@ -38,6 +37,11 @@ export function getPipeName(name: string): string { return path.join(os.tmpdir(), fullName + '.sock'); } +export function getTempFile(name: string): string { + const fullName = 'vscode-' + name; + return path.join(os.tmpdir(), fullName + '.sock'); +} + function generatePatchedEnv(env: any, stdInPipeName: string, stdOutPipeName: string, stdErrPipeName: string): any { // Set the two unique pipe names and the electron flag as process env -- GitLab From 66eddd98fa38ee1bd66ad8f12ef35e9ff1c7d409 Mon Sep 17 00:00:00 2001 From: t-amqi Date: Mon, 12 Jun 2017 15:52:45 -0700 Subject: [PATCH 0738/1347] Address review changes --- src/vs/code/electron-main/menus.ts | 2 +- src/vs/workbench/parts/quickopen/browser/commandsHandler.ts | 5 +---- .../parts/quickopen/browser/quickopen.contribution.ts | 2 +- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index e9cec735992..fe2206f6a36 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -586,7 +586,7 @@ export class CodeMenu { const output = this.createMenuItem(nls.localize({ key: 'miToggleOutput', comment: ['&& denotes a mnemonic'] }, "&&Output"), 'workbench.action.output.toggleOutput'); const debugConsole = this.createMenuItem(nls.localize({ key: 'miToggleDebugConsole', comment: ['&& denotes a mnemonic'] }, "De&&bug Console"), 'workbench.debug.action.toggleRepl'); const integratedTerminal = this.createMenuItem(nls.localize({ key: 'miToggleIntegratedTerminal', comment: ['&& denotes a mnemonic'] }, "&&Integrated Terminal"), 'workbench.action.terminal.toggleTerminal'); - const taskMenu = this.createMenuItem(nls.localize({ key: 'miShowTask', comment: ['&& denotes a mnemonic'] }, "&&Show Tasks..."), 'workbench.action.showTasks'); + const taskMenu = this.createMenuItem(nls.localize({ key: 'miShowTask', comment: ['&& denotes a mnemonic'] }, "Show Tas&&ks..."), 'workbench.action.showTasks'); const problems = this.createMenuItem(nls.localize({ key: 'miMarker', comment: ['&& denotes a mnemonic'] }, "&&Problems"), 'workbench.actions.view.problems'); let additionalViewlets: Electron.MenuItem; diff --git a/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts b/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts index aee3eb1b140..21076a5084e 100644 --- a/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts +++ b/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts @@ -164,10 +164,7 @@ export class ShowTasksAction extends Action { } public run(context?: any): TPromise { - let value = ALL_COMMANDS_PREFIX; - let taskStr = 'tasks'; - value = `${value}${taskStr}`; - + const value = `${ALL_COMMANDS_PREFIX}tasks`; this.quickOpenService.show(value); return TPromise.as(null); diff --git a/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts b/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts index d70aae56491..e46b5cd8432 100644 --- a/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts +++ b/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts @@ -41,7 +41,7 @@ registry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenViewPickerAct }), 'Quick Open View'); registry.registerWorkbenchAction(new SyncActionDescriptor(ShowTasksAction, ShowTasksAction.ID, ShowTasksAction.LABEL, { - primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_T + primary: KeyMod.CtrlCmd | KeyMod.Alt | KeyCode.KEY_T }), 'Show Task Menu'); // Register Quick Open Handler -- GitLab From 1c522e434945ed97aab8031c50015ccec8f774d8 Mon Sep 17 00:00:00 2001 From: t-amqi Date: Mon, 12 Jun 2017 16:16:35 -0700 Subject: [PATCH 0739/1347] Found better place for memento --- .../parts/tasks/electron-browser/task.contribution.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index 349ce3fe297..881c338f4c7 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -610,9 +610,6 @@ class TaskService extends EventEmitter implements ITaskService { private registerCommands(): void { CommandsRegistry.registerCommand('workbench.action.tasks.runTask', (accessor, arg) => { - if (!this.storageService.get('userRanTask', StorageScope.GLOBAL)) { - this.storageService.store('userRanTask', true, StorageScope.GLOBAL); - } this.runTaskCommand(accessor, arg); }); @@ -923,6 +920,9 @@ class TaskService extends EventEmitter implements ITaskService { } private executeTask(task: Task, resolver: ITaskResolver): TPromise { + if (!this.storageService.get('userRanTask', StorageScope.GLOBAL)) { + this.storageService.store('userRanTask', true, StorageScope.GLOBAL); + } return ProblemMatcherRegistry.onReady().then(() => { return this.textFileService.saveAll().then((value) => { // make sure all dirty files are saved let executeResult = this.getTaskSystem().run(task, resolver); -- GitLab From fe8ea995bd766177574b704df1c723ad55237b8e Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Mon, 12 Jun 2017 16:15:50 -0700 Subject: [PATCH 0740/1347] Cleaning up html renderer --- src/vs/base/browser/htmlContentRenderer.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/vs/base/browser/htmlContentRenderer.ts b/src/vs/base/browser/htmlContentRenderer.ts index 638afe7f41f..2b6cc38e2b0 100644 --- a/src/vs/base/browser/htmlContentRenderer.ts +++ b/src/vs/base/browser/htmlContentRenderer.ts @@ -134,6 +134,9 @@ function _renderHtml(content: IHTMLContentElement, options: RenderOptions = {}): } title = removeMarkdownEscapes(title); href = removeMarkdownEscapes(href); + if (href && !href.match(/^http:|https:|file:|mailto:/i)) { + return text; + } return `${text}`; }; renderer.paragraph = (text): string => { -- GitLab From 762ea4d2898d579a6183ac916c0b5efb319c13ae Mon Sep 17 00:00:00 2001 From: t-amqi Date: Mon, 12 Jun 2017 16:56:53 -0700 Subject: [PATCH 0741/1347] Addresses changes --- .../parts/tasks/electron-browser/task.contribution.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index 881c338f4c7..f4d4872c6d9 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -518,6 +518,7 @@ class TaskService extends EventEmitter implements ITaskService { // private static autoDetectTelemetryName: string = 'taskServer.autoDetect'; private static RecentlyUsedTasks_Key = 'workbench.tasks.recentlyUsedTasks'; + private static RanTaskBefore_Key = 'workbench.tasks.ranTaskBefore'; public _serviceBrand: any; public static SERVICE_ID: string = 'taskService'; @@ -920,8 +921,8 @@ class TaskService extends EventEmitter implements ITaskService { } private executeTask(task: Task, resolver: ITaskResolver): TPromise { - if (!this.storageService.get('userRanTask', StorageScope.GLOBAL)) { - this.storageService.store('userRanTask', true, StorageScope.GLOBAL); + if (!this.storageService.get(TaskService.RanTaskBefore_Key, StorageScope.GLOBAL)) { + this.storageService.store(TaskService.RanTaskBefore_Key, true, StorageScope.GLOBAL); } return ProblemMatcherRegistry.onReady().then(() => { return this.textFileService.saveAll().then((value) => { // make sure all dirty files are saved -- GitLab From d52e5881115c1b1d3de223ae2f13aac181ac1710 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Mon, 12 Jun 2017 17:11:15 -0700 Subject: [PATCH 0742/1347] Fix reloading TSServer not updating diagnostics Fixes #25412 --- .../typescript/src/features/bufferSyncSupport.ts | 12 +++++++----- extensions/typescript/src/typescriptMain.ts | 4 ++++ extensions/typescript/src/typescriptService.ts | 2 ++ extensions/typescript/src/typescriptServiceClient.ts | 12 ++++++++++-- 4 files changed, 23 insertions(+), 7 deletions(-) diff --git a/extensions/typescript/src/features/bufferSyncSupport.ts b/extensions/typescript/src/features/bufferSyncSupport.ts index 7fcf7103e34..05dbefb4a1a 100644 --- a/extensions/typescript/src/features/bufferSyncSupport.ts +++ b/extensions/typescript/src/features/bufferSyncSupport.ts @@ -257,11 +257,13 @@ export default class BufferSyncSupport { } } - let args: Proto.GeterrRequestArgs = { - delay: 0, - files: files - }; - this.client.execute('geterr', args, false); + if (files.length) { + const args: Proto.GeterrRequestArgs = { + delay: 0, + files: files + }; + this.client.execute('geterr', args, false); + } this.pendingDiagnostics = Object.create(null); } diff --git a/extensions/typescript/src/typescriptMain.ts b/extensions/typescript/src/typescriptMain.ts index 67e04f4df2e..9f0eed23e17 100644 --- a/extensions/typescript/src/typescriptMain.ts +++ b/extensions/typescript/src/typescriptMain.ts @@ -507,6 +507,10 @@ class TypeScriptServiceClientHost implements ITypescriptServiceClientHost { this.languagePerId[description.id] = manager; } }); + + this.client.onTsServerStarted(() => { + this.triggerAllDiagnostics(); + }); } public dispose(): void { diff --git a/extensions/typescript/src/typescriptService.ts b/extensions/typescript/src/typescriptService.ts index d18e531b572..1b545fef0ac 100644 --- a/extensions/typescript/src/typescriptService.ts +++ b/extensions/typescript/src/typescriptService.ts @@ -76,6 +76,8 @@ export interface ITypescriptServiceClient { warn(message: string, data?: any): void; + onTsServerStarted: Event; + onProjectLanguageServiceStateChanged: Event; onDidBeginInstallTypings: Event; onDidEndInstallTypings: Event; diff --git a/extensions/typescript/src/typescriptServiceClient.ts b/extensions/typescript/src/typescriptServiceClient.ts index 0afd4d6d491..212d7cb3b13 100644 --- a/extensions/typescript/src/typescriptServiceClient.ts +++ b/extensions/typescript/src/typescriptServiceClient.ts @@ -245,6 +245,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient private requestQueue: RequestQueue; private callbacks: CallbackMap; + private readonly _onTsServerStarted = new EventEmitter(); private readonly _onProjectLanguageServiceStateChanged = new EventEmitter(); private readonly _onDidBeginInstallTypings = new EventEmitter(); private readonly _onDidEndInstallTypings = new EventEmitter(); @@ -319,6 +320,10 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient } } + get onTsServerStarted(): Event { + return this._onTsServerStarted.event; + } + get onProjectLanguageServiceStateChanged(): Event { return this._onProjectLanguageServiceStateChanged.event; } @@ -572,6 +577,8 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient this._onReady.resolve(); resolve(childProcess); + this._onTsServerStarted.fire(); + this.serviceStarted(resendModels); }); } catch (error) { @@ -922,7 +929,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient } private sendRequest(requestItem: RequestItem): void { - let serverRequest = requestItem.request; + const serverRequest = requestItem.request; this.tracer.traceRequest(serverRequest, !!requestItem.callbacks, this.requestQueue.length); if (requestItem.callbacks) { this.callbacks.add(serverRequest.seq, requestItem.callbacks); @@ -930,7 +937,8 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient this.service() .then((childProcess) => { childProcess.stdin.write(JSON.stringify(serverRequest) + '\r\n', 'utf8'); - }).then(undefined, err => { + }) + .then(undefined, err => { const callback = this.callbacks.fetch(serverRequest.seq); if (callback) { callback.e(err); -- GitLab From 8959af85808c469ec3e09929b1b29728f9b93dd2 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Mon, 12 Jun 2017 17:16:55 -0700 Subject: [PATCH 0743/1347] Use real map for languagePerId --- extensions/typescript/src/typescriptMain.ts | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/extensions/typescript/src/typescriptMain.ts b/extensions/typescript/src/typescriptMain.ts index 9f0eed23e17..085e48bb40b 100644 --- a/extensions/typescript/src/typescriptMain.ts +++ b/extensions/typescript/src/typescriptMain.ts @@ -448,7 +448,7 @@ class LanguageProvider { class TypeScriptServiceClientHost implements ITypescriptServiceClientHost { private client: TypeScriptServiceClient; private languages: LanguageProvider[] = []; - private languagePerId: ObjectMap; + private languagePerId: Map; private readonly disposables: Disposable[] = []; private readonly versionStatus: VersionStatus; @@ -476,12 +476,12 @@ class TypeScriptServiceClientHost implements ITypescriptServiceClientHost { this.disposables.push(this.versionStatus); this.client = new TypeScriptServiceClient(this, workspaceState, this.versionStatus, plugins, this.disposables); - this.languagePerId = Object.create(null); + this.languagePerId = new Map(); for (const description of descriptions) { const manager = new LanguageProvider(this.client, description); this.languages.push(manager); this.disposables.push(manager); - this.languagePerId[description.id] = manager; + this.languagePerId.set(description.id, manager); } this.client.onReady().then(() => { @@ -504,7 +504,7 @@ class TypeScriptServiceClientHost implements ITypescriptServiceClientHost { const manager = new LanguageProvider(this.client, description); this.languages.push(manager); this.disposables.push(manager); - this.languagePerId[description.id] = manager; + this.languagePerId.set(description.id, manager); } }); @@ -615,13 +615,17 @@ class TypeScriptServiceClientHost implements ITypescriptServiceClientHost { } private triggerAllDiagnostics() { - Object.keys(this.languagePerId).forEach(key => this.languagePerId[key].triggerAllDiagnostics()); + for (const language of this.languagePerId.values()) { + language.triggerAllDiagnostics(); + } } /* internal */ populateService(): void { // See https://github.com/Microsoft/TypeScript/issues/5530 - workspace.saveAll(false).then(_ => { - Object.keys(this.languagePerId).forEach(key => this.languagePerId[key].reInitialize()); + workspace.saveAll(false).then(() => { + for (const language of this.languagePerId.values()) { + language.reInitialize(); + } }); } -- GitLab From ab528897935b0957249e90d69e5985870673fd4b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kate=20Mih=C3=A1likov=C3=A1?= Date: Tue, 13 Jun 2017 02:18:10 +0200 Subject: [PATCH 0744/1347] Handle diff3-style merge correctly (#27405) --- .../merge-conflict/src/commandHandler.ts | 19 ++++++++--- .../src/documentMergeConflict.ts | 2 ++ extensions/merge-conflict/src/interfaces.ts | 1 + .../merge-conflict/src/mergeConflictParser.ts | 33 ++++++++++++++++--- .../merge-conflict/src/mergeDecorator.ts | 18 ++++++++++ 5 files changed, 63 insertions(+), 10 deletions(-) diff --git a/extensions/merge-conflict/src/commandHandler.ts b/extensions/merge-conflict/src/commandHandler.ts index fe3dbd67201..26bab72285e 100644 --- a/extensions/merge-conflict/src/commandHandler.ts +++ b/extensions/merge-conflict/src/commandHandler.ts @@ -111,18 +111,27 @@ export default class CommandHandler implements vscode.Disposable { } let typeToAccept: interfaces.CommitType; + let tokenAfterCurrentBlock: vscode.Range = conflict.splitter; + + if (conflict.commonAncestors.length > 0) { + tokenAfterCurrentBlock = conflict.commonAncestors[0].header; + } // Figure out if the cursor is in current or incoming, we do this by seeing if - // the active position is before or after the range of the splitter. We can - // use this trick as the previous check in findConflictByActiveSelection will - // ensure it's within the conflict range, so we don't falsely identify "current" - // or "incoming" if outside of a conflict range. - if (editor.selection.active.isBefore(conflict.splitter.start)) { + // the active position is before or after the range of the splitter or common + // ancesors marker. We can use this trick as the previous check in + // findConflictByActiveSelection will ensure it's within the conflict range, so + // we don't falsely identify "current" or "incoming" if outside of a conflict range. + if (editor.selection.active.isBefore(tokenAfterCurrentBlock.start)) { typeToAccept = interfaces.CommitType.Current; } else if (editor.selection.active.isAfter(conflict.splitter.end)) { typeToAccept = interfaces.CommitType.Incoming; } + else if (editor.selection.active.isBefore(conflict.splitter.start)) { + vscode.window.showWarningMessage(localize('cursorOnCommonAncestorsRange', 'Editor cursor is within the common ancestors block, please move it to either the "current" or "incoming" block')); + return; + } else { vscode.window.showWarningMessage(localize('cursorOnSplitterRange', 'Editor cursor is within the merge conflict splitter, please move it to either the "current" or "incoming" block')); return; diff --git a/extensions/merge-conflict/src/documentMergeConflict.ts b/extensions/merge-conflict/src/documentMergeConflict.ts index 221ee8f36bc..f1714c98163 100644 --- a/extensions/merge-conflict/src/documentMergeConflict.ts +++ b/extensions/merge-conflict/src/documentMergeConflict.ts @@ -10,12 +10,14 @@ export class DocumentMergeConflict implements interfaces.IDocumentMergeConflict public range: vscode.Range; public current: interfaces.IMergeRegion; public incoming: interfaces.IMergeRegion; + public commonAncestors: interfaces.IMergeRegion[]; public splitter: vscode.Range; constructor(document: vscode.TextDocument, descriptor: interfaces.IDocumentMergeConflictDescriptor) { this.range = descriptor.range; this.current = descriptor.current; this.incoming = descriptor.incoming; + this.commonAncestors = descriptor.commonAncestors; this.splitter = descriptor.splitter; } diff --git a/extensions/merge-conflict/src/interfaces.ts b/extensions/merge-conflict/src/interfaces.ts index 9d411befaba..70519b72b1f 100644 --- a/extensions/merge-conflict/src/interfaces.ts +++ b/extensions/merge-conflict/src/interfaces.ts @@ -32,6 +32,7 @@ export interface IDocumentMergeConflictDescriptor { range: vscode.Range; current: IMergeRegion; incoming: IMergeRegion; + commonAncestors: IMergeRegion[]; splitter: vscode.Range; } diff --git a/extensions/merge-conflict/src/mergeConflictParser.ts b/extensions/merge-conflict/src/mergeConflictParser.ts index fa316a0701c..24c37ae88de 100644 --- a/extensions/merge-conflict/src/mergeConflictParser.ts +++ b/extensions/merge-conflict/src/mergeConflictParser.ts @@ -7,11 +7,13 @@ import * as interfaces from './interfaces'; import { DocumentMergeConflict } from './documentMergeConflict'; const startHeaderMarker = '<<<<<<< '; +const commonAncestorsMarker = '||||||| '; const splitterMarker = '======='; const endFooterMarker = '>>>>>>> '; interface IScanMergedConflict { startHeader: vscode.TextLine; + commonAncestors: vscode.TextLine[]; splitter?: vscode.TextLine; endFooter?: vscode.TextLine; } @@ -49,10 +51,14 @@ export class MergeConflictParser { } // Create a new conflict starting at this line - currentConflict = { startHeader: line }; + currentConflict = { startHeader: line, commonAncestors: [] }; + } + // Are we within a conflict block and is this a common ancestors marker? ||||||| + else if (currentConflict && !currentConflict.splitter && line.text.startsWith(commonAncestorsMarker)) { + currentConflict.commonAncestors.push(line); } // Are we within a conflict block and is this a splitter? ======= - else if (currentConflict && line.text.startsWith(splitterMarker)) { + else if (currentConflict && !currentConflict.splitter && line.text.startsWith(splitterMarker)) { currentConflict.splitter = line; } // Are we withon a conflict block and is this a footer? >>>>>>> @@ -84,6 +90,8 @@ export class MergeConflictParser { return null; } + let tokenAfterCurrentBlock: vscode.TextLine = scanned.commonAncestors[0] || scanned.splitter; + // Assume that descriptor.current.header, descriptor.incoming.header and descriptor.spliiter // have valid ranges, fill in content and total ranges from these parts. // NOTE: We need to shift the decortator range back one character so the splitter does not end up with @@ -94,13 +102,28 @@ export class MergeConflictParser { header: scanned.startHeader.range, decoratorContent: new vscode.Range( scanned.startHeader.rangeIncludingLineBreak.end, - MergeConflictParser.shiftBackOneCharacter(document, scanned.splitter.range.start)), - // Current content is range between header (shifted for linebreak) and splitter start + MergeConflictParser.shiftBackOneCharacter(document, tokenAfterCurrentBlock.range.start)), + // Current content is range between header (shifted for linebreak) and splitter or common ancestors mark start content: new vscode.Range( scanned.startHeader.rangeIncludingLineBreak.end, - scanned.splitter.range.start), + tokenAfterCurrentBlock.range.start), name: scanned.startHeader.text.substring(startHeaderMarker.length) }, + commonAncestors: scanned.commonAncestors.map((currentTokenLine, index, commonAncestors) => { + let nextTokenLine = commonAncestors[index + 1] || scanned.splitter; + return { + header: currentTokenLine.range, + decoratorContent: new vscode.Range( + currentTokenLine.rangeIncludingLineBreak.end, + MergeConflictParser.shiftBackOneCharacter(document, nextTokenLine.range.start)), + // Each common ancestors block is range between one common ancestors token + // (shifted for linebreak) and start of next common ancestors token or splitter + content: new vscode.Range( + currentTokenLine.rangeIncludingLineBreak.end, + nextTokenLine.range.start), + name: currentTokenLine.text.substring(commonAncestorsMarker.length) + }; + }), splitter: scanned.splitter.range, incoming: { header: scanned.endFooter.range, diff --git a/extensions/merge-conflict/src/mergeDecorator.ts b/extensions/merge-conflict/src/mergeDecorator.ts index f988eef1fed..24e81970846 100644 --- a/extensions/merge-conflict/src/mergeDecorator.ts +++ b/extensions/merge-conflict/src/mergeDecorator.ts @@ -73,6 +73,11 @@ export default class MergeDectorator implements vscode.Disposable { this.decorations['incoming.content'] = vscode.window.createTextEditorDecorationType( this.generateBlockRenderOptions('merge.incomingContentBackground', 'editorOverviewRuler.incomingContentForeground', config) ); + + this.decorations['commonAncestors.content'] = vscode.window.createTextEditorDecorationType({ + color: new vscode.ThemeColor('editor.foreground'), + isWholeLine: this.decorationUsesWholeLine, + }); } if (config.enableDecorations) { @@ -89,6 +94,11 @@ export default class MergeDectorator implements vscode.Disposable { } }); + this.decorations['commonAncestors.header'] = vscode.window.createTextEditorDecorationType({ + color: new vscode.ThemeColor('editor.foreground'), + isWholeLine: this.decorationUsesWholeLine, + }); + this.decorations['splitter'] = vscode.window.createTextEditorDecorationType({ color: new vscode.ThemeColor('editor.foreground'), outlineStyle: 'solid', @@ -187,10 +197,18 @@ export default class MergeDectorator implements vscode.Disposable { pushDecoration('current.content', { range: conflict.current.decoratorContent }); pushDecoration('incoming.content', { range: conflict.incoming.decoratorContent }); + conflict.commonAncestors.forEach(commonAncestorsRegion => { + pushDecoration('commonAncestors.content', { range: commonAncestorsRegion.decoratorContent }); + }); + if (this.config.enableDecorations) { pushDecoration('current.header', { range: conflict.current.header }); pushDecoration('splitter', { range: conflict.splitter }); pushDecoration('incoming.header', { range: conflict.incoming.header }); + + conflict.commonAncestors.forEach(commonAncestorsRegion => { + pushDecoration('commonAncestors.header', { range: commonAncestorsRegion.header }); + }); } }); -- GitLab From 996af4d965f4b9b3862cd7c02e28509f346bf0eb Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Mon, 12 Jun 2017 17:16:38 -0700 Subject: [PATCH 0745/1347] Workbench colors (#28507) --- extensions/merge-conflict/src/mergeDecorator.ts | 13 ++++++++----- src/vs/platform/theme/common/colorRegistry.ts | 4 ++++ 2 files changed, 12 insertions(+), 5 deletions(-) diff --git a/extensions/merge-conflict/src/mergeDecorator.ts b/extensions/merge-conflict/src/mergeDecorator.ts index 24e81970846..c3fa2e08e08 100644 --- a/extensions/merge-conflict/src/mergeDecorator.ts +++ b/extensions/merge-conflict/src/mergeDecorator.ts @@ -74,10 +74,9 @@ export default class MergeDectorator implements vscode.Disposable { this.generateBlockRenderOptions('merge.incomingContentBackground', 'editorOverviewRuler.incomingContentForeground', config) ); - this.decorations['commonAncestors.content'] = vscode.window.createTextEditorDecorationType({ - color: new vscode.ThemeColor('editor.foreground'), - isWholeLine: this.decorationUsesWholeLine, - }); + this.decorations['commonAncestors.content'] = vscode.window.createTextEditorDecorationType( + this.generateBlockRenderOptions('merge.commonContentBackground', 'editorOverviewRuler.commonContentForeground', config) + ); } if (config.enableDecorations) { @@ -95,8 +94,12 @@ export default class MergeDectorator implements vscode.Disposable { }); this.decorations['commonAncestors.header'] = vscode.window.createTextEditorDecorationType({ - color: new vscode.ThemeColor('editor.foreground'), isWholeLine: this.decorationUsesWholeLine, + backgroundColor: new vscode.ThemeColor('merge.commonHeaderBackground'), + color: new vscode.ThemeColor('editor.foreground'), + outlineStyle: 'solid', + outlineWidth: '1pt', + outlineColor: new vscode.ThemeColor('merge.border') }); this.decorations['splitter'] = vscode.window.createTextEditorDecorationType({ diff --git a/src/vs/platform/theme/common/colorRegistry.ts b/src/vs/platform/theme/common/colorRegistry.ts index 2cd9b78d5ec..02ffee0c423 100644 --- a/src/vs/platform/theme/common/colorRegistry.ts +++ b/src/vs/platform/theme/common/colorRegistry.ts @@ -261,6 +261,7 @@ export const diffRemovedOutline = registerColor('diffEditor.removedTextBorder', const headerTransparency = 0.5; const currentBaseColor = Color.fromHex('#40C8AE').transparent(headerTransparency); const incomingBaseColor = Color.fromHex('#40A6FF').transparent(headerTransparency); +const commonBaseColor = Color.fromHex('#606060').transparent(0.4); const contentTransparency = 0.4; const rulerTransparency = 1; @@ -268,11 +269,14 @@ export const mergeCurrentHeaderBackground = registerColor('merge.currentHeaderBa export const mergeCurrentContentBackground = registerColor('merge.currentContentBackground', { dark: transparent(mergeCurrentHeaderBackground, contentTransparency), light: transparent(mergeCurrentHeaderBackground, contentTransparency), hc: transparent(mergeCurrentHeaderBackground, contentTransparency) }, nls.localize('mergeCurrentContentBackground', 'Current content background in inline merge-conflicts.')); export const mergeIncomingHeaderBackground = registerColor('merge.incomingHeaderBackground', { dark: incomingBaseColor, light: incomingBaseColor, hc: null }, nls.localize('mergeIncomingHeaderBackground', 'Incoming header background in inline merge-conflicts.')); export const mergeIncomingContentBackground = registerColor('merge.incomingContentBackground', { dark: transparent(mergeIncomingHeaderBackground, contentTransparency), light: transparent(mergeIncomingHeaderBackground, contentTransparency), hc: transparent(mergeIncomingHeaderBackground, contentTransparency) }, nls.localize('mergeIncomingContentBackground', 'Incoming content background in inline merge-conflicts.')); +export const mergeCommonHeaderBackground = registerColor('merge.commonHeaderBackground', { dark: commonBaseColor, light: commonBaseColor, hc: null }, nls.localize('mergeCommonHeaderBackground', 'Common ancestor header background in inline merge-conflicts.')); +export const mergeCommonContentBackground = registerColor('merge.commonContentBackground', { dark: transparent(mergeCommonHeaderBackground, contentTransparency), light: transparent(mergeCommonHeaderBackground, contentTransparency), hc: transparent(mergeCommonHeaderBackground, contentTransparency) }, nls.localize('mergeCommonContentBackground', 'Common ancester content background in inline merge-conflicts.')); export const mergeBorder = registerColor('merge.border', { dark: null, light: null, hc: '#C3DF6F' }, nls.localize('mergeBorder', 'Border color on headers and the splitter in inline merge-conflicts.')); export const overviewRulerCurrentContentForeground = registerColor('editorOverviewRuler.currentContentForeground', { dark: transparent(mergeCurrentHeaderBackground, rulerTransparency), light: transparent(mergeCurrentHeaderBackground, rulerTransparency), hc: mergeBorder }, nls.localize('overviewRulerCurrentContentForeground', 'Current overview ruler foreground for inline merge-conflicts.')); export const overviewRulerIncomingContentForeground = registerColor('editorOverviewRuler.incomingContentForeground', { dark: transparent(mergeIncomingHeaderBackground, rulerTransparency), light: transparent(mergeIncomingHeaderBackground, rulerTransparency), hc: mergeBorder }, nls.localize('overviewRulerIncomingContentForeground', 'Incoming overview ruler foreground for inline merge-conflicts.')); +export const overviewRulerCommonContentForeground = registerColor('editorOverviewRuler.commonContentForeground', { dark: transparent(mergeCommonHeaderBackground, rulerTransparency), light: transparent(mergeCommonHeaderBackground, rulerTransparency), hc: mergeBorder }, nls.localize('overviewRulerCommonContentForeground', 'Common ancestor overview ruler foreground for inline merge-conflicts.')); // ----- color functions -- GitLab From bbcd10ae1a959c1681469533321fa418da7cd9db Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Mon, 12 Jun 2017 17:28:48 -0700 Subject: [PATCH 0746/1347] Use async in TS documentSymbolProvider --- .../src/features/documentSymbolProvider.ts | 28 ++++++++----------- 1 file changed, 12 insertions(+), 16 deletions(-) diff --git a/extensions/typescript/src/features/documentSymbolProvider.ts b/extensions/typescript/src/features/documentSymbolProvider.ts index 06b3e0983c2..9fbaf64fc80 100644 --- a/extensions/typescript/src/features/documentSymbolProvider.ts +++ b/extensions/typescript/src/features/documentSymbolProvider.ts @@ -33,18 +33,19 @@ export default class TypeScriptDocumentSymbolProvider implements DocumentSymbolP public constructor( private client: ITypescriptServiceClient) { } - public provideDocumentSymbols(resource: TextDocument, token: CancellationToken): Promise { + public async provideDocumentSymbols(resource: TextDocument, token: CancellationToken): Promise { const filepath = this.client.normalizePath(resource.uri); if (!filepath) { - return Promise.resolve([]); + return []; } const args: Proto.FileRequestArgs = { file: filepath }; - if (this.client.apiVersion.has206Features()) { - return this.client.execute('navtree', args, token).then((response) => { - const result: SymbolInformation[] = []; + try { + const result: SymbolInformation[] = []; + if (this.client.apiVersion.has206Features()) { + const response = await this.client.execute('navtree', args, token); if (response.body) { // The root represents the file. Ignore this when showing in the UI let tree = response.body; @@ -52,21 +53,16 @@ export default class TypeScriptDocumentSymbolProvider implements DocumentSymbolP tree.childItems.forEach(item => TypeScriptDocumentSymbolProvider.convertNavTree(resource.uri, result, item)); } } - return result; - }, () => { - return []; - }); - } else { - return this.client.execute('navbar', args, token).then((response) => { - const result: SymbolInformation[] = []; + } else { + const response = await this.client.execute('navbar', args, token); if (response.body) { let foldingMap: ObjectMap = Object.create(null); response.body.forEach(item => TypeScriptDocumentSymbolProvider.convertNavBar(resource.uri, 0, foldingMap, result, item)); } - return result; - }, () => { - return []; - }); + } + return result; + } catch (e) { + return []; } } -- GitLab From 4ffa2539dae42db2ac230f15181f5b83f74c1229 Mon Sep 17 00:00:00 2001 From: Ramya Rao Date: Mon, 12 Jun 2017 22:20:59 -0700 Subject: [PATCH 0747/1347] shrinkwrap, OSSREADME for emmet (#28570) --- extensions/emmet/OSSREADME.json | 118 +++++++++++ extensions/emmet/npm-shrinkwrap.json | 286 +++++++++++++++++++++++++++ 2 files changed, 404 insertions(+) create mode 100644 extensions/emmet/OSSREADME.json create mode 100644 extensions/emmet/npm-shrinkwrap.json diff --git a/extensions/emmet/OSSREADME.json b/extensions/emmet/OSSREADME.json new file mode 100644 index 00000000000..926f46f6fbd --- /dev/null +++ b/extensions/emmet/OSSREADME.json @@ -0,0 +1,118 @@ +[ + { + "name": "@emmetio/expand-abbreviation", + "license": "MIT", + "version": "0.5.7", + "repositoryURL": "https://github.com/emmetio/expand-abbreviation", + "licenseDetail": [ + "MIT License", + "", + "Copyright (c) 2017 Emmet.io", + "", + "Permission is hereby granted, free of charge, to any person obtaining a copy", + "of this software and associated documentation files (the \"Software\"), to deal", + "in the Software without restriction, including without limitation the rights", + "to use, copy, modify, merge, publish, distribute, sublicense, and/or sell", + "copies of the Software, and to permit persons to whom the Software is", + "furnished to do so, subject to the following conditions:", + "", + "The above copyright notice and this permission notice shall be included in all", + "copies or substantial portions of the Software.", + "", + "THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR", + "IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,", + "FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE", + "AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER", + "LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,", + "OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE", + "SOFTWARE." + ] + }, + { + "name": "@emmetio/css-parser", + "license": "MIT", + "version": "0.3.0", + "repositoryURL": "https://github.com/emmetio/css-parser", + "licenseDetail": [ + "MIT License", + "", + "Copyright (c) 2017 Emmet.io", + "", + "Permission is hereby granted, free of charge, to any person obtaining a copy", + "of this software and associated documentation files (the \"Software\"), to deal", + "in the Software without restriction, including without limitation the rights", + "to use, copy, modify, merge, publish, distribute, sublicense, and/or sell", + "copies of the Software, and to permit persons to whom the Software is", + "furnished to do so, subject to the following conditions:", + "", + "The above copyright notice and this permission notice shall be included in all", + "copies or substantial portions of the Software.", + "", + "THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR", + "IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,", + "FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE", + "AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER", + "LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,", + "OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE", + "SOFTWARE." + ] + }, + { + "name": "@emmetio/extract-abbreviation", + "license": "MIT", + "version": "0.1.2", + "repositoryURL": "https://github.com/emmetio/extract-abbreviation", + "licenseDetail": [ + "MIT License", + "", + "Copyright (c) 2017 Emmet.io", + "", + "Permission is hereby granted, free of charge, to any person obtaining a copy", + "of this software and associated documentation files (the \"Software\"), to deal", + "in the Software without restriction, including without limitation the rights", + "to use, copy, modify, merge, publish, distribute, sublicense, and/or sell", + "copies of the Software, and to permit persons to whom the Software is", + "furnished to do so, subject to the following conditions:", + "", + "The above copyright notice and this permission notice shall be included in all", + "copies or substantial portions of the Software.", + "", + "THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR", + "IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,", + "FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE", + "AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER", + "LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,", + "OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE", + "SOFTWARE." + ] + }, + { + "name": "@emmetio/html-matcher", + "license": "MIT", + "version": "0.3.2", + "repositoryURL": "https://github.com/emmetio/html-matcher", + "licenseDetail": [ + "MIT License", + "", + "Copyright (c) 2017 Emmet.io", + "", + "Permission is hereby granted, free of charge, to any person obtaining a copy", + "of this software and associated documentation files (the \"Software\"), to deal", + "in the Software without restriction, including without limitation the rights", + "to use, copy, modify, merge, publish, distribute, sublicense, and/or sell", + "copies of the Software, and to permit persons to whom the Software is", + "furnished to do so, subject to the following conditions:", + "", + "The above copyright notice and this permission notice shall be included in all", + "copies or substantial portions of the Software.", + "", + "THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR", + "IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,", + "FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE", + "AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER", + "LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,", + "OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE", + "SOFTWARE." + ] + } +] \ No newline at end of file diff --git a/extensions/emmet/npm-shrinkwrap.json b/extensions/emmet/npm-shrinkwrap.json new file mode 100644 index 00000000000..20736e323b9 --- /dev/null +++ b/extensions/emmet/npm-shrinkwrap.json @@ -0,0 +1,286 @@ +{ + "name": "emmet", + "version": "0.0.1", + "dependencies": { + "@emmetio/abbreviation": { + "version": "0.6.1", + "from": "@emmetio/abbreviation@>=0.6.1 <0.7.0", + "resolved": "https://registry.npmjs.org/@emmetio/abbreviation/-/abbreviation-0.6.1.tgz" + }, + "@emmetio/css-abbreviation": { + "version": "0.3.1", + "from": "@emmetio/css-abbreviation@>=0.3.1 <0.4.0", + "resolved": "https://registry.npmjs.org/@emmetio/css-abbreviation/-/css-abbreviation-0.3.1.tgz" + }, + "@emmetio/css-parser": { + "version": "0.3.0", + "from": "@emmetio/css-parser@>=0.3.0 <0.4.0", + "resolved": "https://registry.npmjs.org/@emmetio/css-parser/-/css-parser-0.3.0.tgz" + }, + "@emmetio/css-snippets-resolver": { + "version": "0.2.5", + "from": "@emmetio/css-snippets-resolver@>=0.2.5 <0.3.0", + "resolved": "https://registry.npmjs.org/@emmetio/css-snippets-resolver/-/css-snippets-resolver-0.2.5.tgz" + }, + "@emmetio/expand-abbreviation": { + "version": "0.5.7", + "from": "@emmetio/expand-abbreviation@>=0.5.4 <0.6.0", + "resolved": "https://registry.npmjs.org/@emmetio/expand-abbreviation/-/expand-abbreviation-0.5.7.tgz" + }, + "@emmetio/extract-abbreviation": { + "version": "0.1.2", + "from": "@emmetio/extract-abbreviation@>=0.1.1 <0.2.0", + "resolved": "https://registry.npmjs.org/@emmetio/extract-abbreviation/-/extract-abbreviation-0.1.2.tgz" + }, + "@emmetio/field-parser": { + "version": "0.3.0", + "from": "@emmetio/field-parser@>=0.3.0 <0.4.0", + "resolved": "https://registry.npmjs.org/@emmetio/field-parser/-/field-parser-0.3.0.tgz" + }, + "@emmetio/html-matcher": { + "version": "0.3.2", + "from": "@emmetio/html-matcher@>=0.3.1 <0.4.0", + "resolved": "https://registry.npmjs.org/@emmetio/html-matcher/-/html-matcher-0.3.2.tgz" + }, + "@emmetio/html-snippets-resolver": { + "version": "0.1.4", + "from": "@emmetio/html-snippets-resolver@>=0.1.4 <0.2.0", + "resolved": "https://registry.npmjs.org/@emmetio/html-snippets-resolver/-/html-snippets-resolver-0.1.4.tgz" + }, + "@emmetio/html-transform": { + "version": "0.3.2", + "from": "@emmetio/html-transform@>=0.3.2 <0.4.0", + "resolved": "https://registry.npmjs.org/@emmetio/html-transform/-/html-transform-0.3.2.tgz" + }, + "@emmetio/implicit-tag": { + "version": "1.0.0", + "from": "@emmetio/implicit-tag@>=1.0.0 <2.0.0", + "resolved": "https://registry.npmjs.org/@emmetio/implicit-tag/-/implicit-tag-1.0.0.tgz" + }, + "@emmetio/lorem": { + "version": "1.0.1", + "from": "@emmetio/lorem@>=1.0.1 <2.0.0", + "resolved": "https://registry.npmjs.org/@emmetio/lorem/-/lorem-1.0.1.tgz" + }, + "@emmetio/markup-formatters": { + "version": "0.3.3", + "from": "@emmetio/markup-formatters@>=0.3.3 <0.4.0", + "resolved": "https://registry.npmjs.org/@emmetio/markup-formatters/-/markup-formatters-0.3.3.tgz" + }, + "@emmetio/node": { + "version": "0.1.2", + "from": "@emmetio/node@>=0.1.2 <0.2.0", + "resolved": "https://registry.npmjs.org/@emmetio/node/-/node-0.1.2.tgz" + }, + "@emmetio/output-profile": { + "version": "0.1.5", + "from": "@emmetio/output-profile@>=0.1.5 <0.2.0", + "resolved": "https://registry.npmjs.org/@emmetio/output-profile/-/output-profile-0.1.5.tgz" + }, + "@emmetio/output-renderer": { + "version": "0.1.1", + "from": "@emmetio/output-renderer@>=0.1.0 <0.2.0", + "resolved": "https://registry.npmjs.org/@emmetio/output-renderer/-/output-renderer-0.1.1.tgz" + }, + "@emmetio/snippets": { + "version": "0.2.3", + "from": "@emmetio/snippets@>=0.2.3 <0.3.0", + "resolved": "https://registry.npmjs.org/@emmetio/snippets/-/snippets-0.2.3.tgz" + }, + "@emmetio/snippets-registry": { + "version": "0.3.1", + "from": "@emmetio/snippets-registry@>=0.3.1 <0.4.0", + "resolved": "https://registry.npmjs.org/@emmetio/snippets-registry/-/snippets-registry-0.3.1.tgz" + }, + "@emmetio/stream-reader": { + "version": "2.2.0", + "from": "@emmetio/stream-reader@>=2.2.0 <3.0.0", + "resolved": "https://registry.npmjs.org/@emmetio/stream-reader/-/stream-reader-2.2.0.tgz" + }, + "@emmetio/stream-reader-utils": { + "version": "0.1.0", + "from": "@emmetio/stream-reader-utils@>=0.1.0 <0.2.0", + "resolved": "https://registry.npmjs.org/@emmetio/stream-reader-utils/-/stream-reader-utils-0.1.0.tgz" + }, + "@emmetio/stylesheet-formatters": { + "version": "0.1.2", + "from": "@emmetio/stylesheet-formatters@>=0.1.2 <0.2.0", + "resolved": "https://registry.npmjs.org/@emmetio/stylesheet-formatters/-/stylesheet-formatters-0.1.2.tgz" + }, + "@emmetio/variable-resolver": { + "version": "0.2.1", + "from": "@emmetio/variable-resolver@>=0.2.1 <0.3.0", + "resolved": "https://registry.npmjs.org/@emmetio/variable-resolver/-/variable-resolver-0.2.1.tgz" + }, + "balanced-match": { + "version": "1.0.0", + "from": "balanced-match@>=1.0.0 <2.0.0", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz" + }, + "brace-expansion": { + "version": "1.1.8", + "from": "brace-expansion@>=1.1.7 <2.0.0", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.8.tgz" + }, + "browser-stdout": { + "version": "1.3.0", + "from": "browser-stdout@1.3.0", + "resolved": "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.0.tgz" + }, + "commander": { + "version": "2.9.0", + "from": "commander@2.9.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-2.9.0.tgz" + }, + "concat-map": { + "version": "0.0.1", + "from": "concat-map@0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz" + }, + "debug": { + "version": "2.6.0", + "from": "debug@2.6.0", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.0.tgz" + }, + "diff": { + "version": "3.2.0", + "from": "diff@3.2.0", + "resolved": "https://registry.npmjs.org/diff/-/diff-3.2.0.tgz" + }, + "escape-string-regexp": { + "version": "1.0.5", + "from": "escape-string-regexp@1.0.5", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz" + }, + "fs.realpath": { + "version": "1.0.0", + "from": "fs.realpath@>=1.0.0 <2.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz" + }, + "glob": { + "version": "7.1.1", + "from": "glob@7.1.1", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.1.tgz" + }, + "graceful-readlink": { + "version": "1.0.1", + "from": "graceful-readlink@>=1.0.0", + "resolved": "https://registry.npmjs.org/graceful-readlink/-/graceful-readlink-1.0.1.tgz" + }, + "growl": { + "version": "1.9.2", + "from": "growl@1.9.2", + "resolved": "https://registry.npmjs.org/growl/-/growl-1.9.2.tgz" + }, + "has-flag": { + "version": "1.0.0", + "from": "has-flag@>=1.0.0 <2.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-1.0.0.tgz" + }, + "inflight": { + "version": "1.0.6", + "from": "inflight@>=1.0.4 <2.0.0", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz" + }, + "inherits": { + "version": "2.0.3", + "from": "inherits@>=2.0.0 <3.0.0", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz" + }, + "json3": { + "version": "3.3.2", + "from": "json3@3.3.2", + "resolved": "https://registry.npmjs.org/json3/-/json3-3.3.2.tgz" + }, + "lodash._baseassign": { + "version": "3.2.0", + "from": "lodash._baseassign@>=3.0.0 <4.0.0", + "resolved": "https://registry.npmjs.org/lodash._baseassign/-/lodash._baseassign-3.2.0.tgz" + }, + "lodash._basecopy": { + "version": "3.0.1", + "from": "lodash._basecopy@>=3.0.0 <4.0.0", + "resolved": "https://registry.npmjs.org/lodash._basecopy/-/lodash._basecopy-3.0.1.tgz" + }, + "lodash._basecreate": { + "version": "3.0.3", + "from": "lodash._basecreate@>=3.0.0 <4.0.0", + "resolved": "https://registry.npmjs.org/lodash._basecreate/-/lodash._basecreate-3.0.3.tgz" + }, + "lodash._getnative": { + "version": "3.9.1", + "from": "lodash._getnative@>=3.0.0 <4.0.0", + "resolved": "https://registry.npmjs.org/lodash._getnative/-/lodash._getnative-3.9.1.tgz" + }, + "lodash._isiterateecall": { + "version": "3.0.9", + "from": "lodash._isiterateecall@>=3.0.0 <4.0.0", + "resolved": "https://registry.npmjs.org/lodash._isiterateecall/-/lodash._isiterateecall-3.0.9.tgz" + }, + "lodash.create": { + "version": "3.1.1", + "from": "lodash.create@3.1.1", + "resolved": "https://registry.npmjs.org/lodash.create/-/lodash.create-3.1.1.tgz" + }, + "lodash.isarguments": { + "version": "3.1.0", + "from": "lodash.isarguments@>=3.0.0 <4.0.0", + "resolved": "https://registry.npmjs.org/lodash.isarguments/-/lodash.isarguments-3.1.0.tgz" + }, + "lodash.isarray": { + "version": "3.0.4", + "from": "lodash.isarray@>=3.0.0 <4.0.0", + "resolved": "https://registry.npmjs.org/lodash.isarray/-/lodash.isarray-3.0.4.tgz" + }, + "lodash.keys": { + "version": "3.1.2", + "from": "lodash.keys@>=3.0.0 <4.0.0", + "resolved": "https://registry.npmjs.org/lodash.keys/-/lodash.keys-3.1.2.tgz" + }, + "minimatch": { + "version": "3.0.4", + "from": "minimatch@>=3.0.2 <4.0.0", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz" + }, + "minimist": { + "version": "0.0.8", + "from": "minimist@0.0.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz" + }, + "mkdirp": { + "version": "0.5.1", + "from": "mkdirp@0.5.1", + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz" + }, + "mocha": { + "version": "3.4.2", + "from": "mocha@>=3.4.1 <4.0.0", + "resolved": "https://registry.npmjs.org/mocha/-/mocha-3.4.2.tgz" + }, + "ms": { + "version": "0.7.2", + "from": "ms@0.7.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-0.7.2.tgz" + }, + "once": { + "version": "1.4.0", + "from": "once@>=1.3.0 <2.0.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz" + }, + "path-is-absolute": { + "version": "1.0.1", + "from": "path-is-absolute@>=1.0.0 <2.0.0", + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz" + }, + "supports-color": { + "version": "3.1.2", + "from": "supports-color@3.1.2", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-3.1.2.tgz" + }, + "wrappy": { + "version": "1.0.2", + "from": "wrappy@>=1.0.0 <2.0.0", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz" + } + } +} -- GitLab From 60a069504012d390c8b0c42af457098fd236458e Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Tue, 13 Jun 2017 07:49:05 +0200 Subject: [PATCH 0748/1347] Hot exit: set backupPath as configuration to windows (#28350) --- src/vs/code/electron-main/app.ts | 6 --- src/vs/code/electron-main/windows.ts | 3 +- src/vs/platform/backup/common/backup.ts | 12 +----- src/vs/platform/backup/common/backupIpc.ts | 38 ------------------- .../backup/electron-main/backupMainService.ts | 15 ++------ .../electron-main/backupMainService.test.ts | 27 ------------- src/vs/platform/windows/common/windows.ts | 16 ++++++-- src/vs/workbench/electron-browser/common.ts | 22 ----------- src/vs/workbench/electron-browser/main.ts | 29 ++------------ src/vs/workbench/electron-browser/shell.ts | 13 +++---- src/vs/workbench/electron-browser/window.ts | 3 +- .../workbench/electron-browser/workbench.ts | 10 +++-- .../relauncher.contribution.ts | 3 +- .../services/backup/node/backupFileService.ts | 22 +++-------- .../backup/test/backupFileService.test.ts | 10 +---- 15 files changed, 43 insertions(+), 186 deletions(-) delete mode 100644 src/vs/platform/backup/common/backupIpc.ts delete mode 100644 src/vs/workbench/electron-browser/common.ts diff --git a/src/vs/code/electron-main/app.ts b/src/vs/code/electron-main/app.ts index 77aa83653c5..9d09792a65b 100644 --- a/src/vs/code/electron-main/app.ts +++ b/src/vs/code/electron-main/app.ts @@ -27,8 +27,6 @@ import { ServiceCollection } from 'vs/platform/instantiation/common/serviceColle import { SyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import { ILogService } from 'vs/platform/log/common/log'; import { IStorageService } from 'vs/platform/storage/node/storage'; -import { IBackupMainService } from 'vs/platform/backup/common/backup'; -import { BackupChannel } from 'vs/platform/backup/common/backupIpc'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { IURLService } from 'vs/platform/url/common/url'; @@ -304,10 +302,6 @@ export class CodeApplication { const urlChannel = appInstantiationService.createInstance(URLChannel, urlService); this.electronIpcServer.registerChannel('url', urlChannel); - const backupService = accessor.get(IBackupMainService); - const backupChannel = appInstantiationService.createInstance(BackupChannel, backupService); - this.electronIpcServer.registerChannel('backup', backupChannel); - const windowsService = accessor.get(IWindowsService); const windowsChannel = new WindowsChannel(windowsService); this.electronIpcServer.registerChannel('windows', windowsChannel); diff --git a/src/vs/code/electron-main/windows.ts b/src/vs/code/electron-main/windows.ts index 743776829a7..537b279af93 100644 --- a/src/vs/code/electron-main/windows.ts +++ b/src/vs/code/electron-main/windows.ts @@ -707,7 +707,8 @@ export class WindowsManager implements IWindowsMainService { // Register window for backups if (!configuration.extensionDevelopmentPath) { - this.backupService.registerWindowForBackupsSync(codeWindow.id, !configuration.workspacePath, options.emptyWorkspaceBackupFolder, configuration.workspacePath); + const backupPath = this.backupService.registerWindowForBackupsSync(codeWindow.id, !configuration.workspacePath, options.emptyWorkspaceBackupFolder, configuration.workspacePath); + configuration.backupPath = backupPath; } // Load it diff --git a/src/vs/platform/backup/common/backup.ts b/src/vs/platform/backup/common/backup.ts index 9a53670387f..dcc3eec908c 100644 --- a/src/vs/platform/backup/common/backup.ts +++ b/src/vs/platform/backup/common/backup.ts @@ -4,7 +4,6 @@ *--------------------------------------------------------------------------------------------*/ import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; -import { TPromise } from 'vs/base/common/winjs.base'; export interface IBackupWorkspacesFormat { folderWorkspaces: string[]; @@ -12,19 +11,12 @@ export interface IBackupWorkspacesFormat { } export const IBackupMainService = createDecorator('backupMainService'); -export const IBackupService = createDecorator('backupService'); -export interface IBackupMainService extends IBackupService { +export interface IBackupMainService { _serviceBrand: any; getWorkspaceBackupPaths(): string[]; getEmptyWorkspaceBackupPaths(): string[]; - registerWindowForBackupsSync(windowId: number, isEmptyWorkspace: boolean, backupFolder?: string, workspacePath?: string): void; -} - -export interface IBackupService { - _serviceBrand: any; - - getBackupPath(windowId: number): TPromise; + registerWindowForBackupsSync(windowId: number, isEmptyWorkspace: boolean, backupFolder?: string, workspacePath?: string): string; } \ No newline at end of file diff --git a/src/vs/platform/backup/common/backupIpc.ts b/src/vs/platform/backup/common/backupIpc.ts deleted file mode 100644 index 0fdfdb86824..00000000000 --- a/src/vs/platform/backup/common/backupIpc.ts +++ /dev/null @@ -1,38 +0,0 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ - -'use strict'; - -import { TPromise } from 'vs/base/common/winjs.base'; -import { IChannel } from 'vs/base/parts/ipc/common/ipc'; -import { IBackupService } from './backup'; - -export interface IBackupChannel extends IChannel { - call(command: 'getBackupPath', arg: [number]): TPromise; - call(command: string, arg?: any): TPromise; -} - -export class BackupChannel implements IBackupChannel { - - constructor(private service: IBackupService) { } - - call(command: string, arg?: any): TPromise { - switch (command) { - case 'getBackupPath': return this.service.getBackupPath(arg); - } - return undefined; - } -} - -export class BackupChannelClient implements IBackupService { - - _serviceBrand: any; - - constructor(private channel: IBackupChannel) { } - - getBackupPath(windowId: number): TPromise { - return this.channel.call('getBackupPath', windowId); - } -} \ No newline at end of file diff --git a/src/vs/platform/backup/electron-main/backupMainService.ts b/src/vs/platform/backup/electron-main/backupMainService.ts index a5c984ca5ed..59f9d014a8c 100644 --- a/src/vs/platform/backup/electron-main/backupMainService.ts +++ b/src/vs/platform/backup/electron-main/backupMainService.ts @@ -13,7 +13,6 @@ import { IBackupWorkspacesFormat, IBackupMainService } from 'vs/platform/backup/ import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { IFilesConfiguration, HotExitConfiguration } from 'vs/platform/files/common/files'; -import { TPromise } from 'vs/base/common/winjs.base'; export class BackupMainService implements IBackupMainService { @@ -23,7 +22,6 @@ export class BackupMainService implements IBackupMainService { protected workspacesJsonPath: string; private backups: IBackupWorkspacesFormat; - private mapWindowToBackupFolder: { [windowId: number]: string; }; constructor( @IEnvironmentService environmentService: IEnvironmentService, @@ -31,7 +29,6 @@ export class BackupMainService implements IBackupMainService { ) { this.backupHome = environmentService.backupHome; this.workspacesJsonPath = environmentService.backupWorkspacesPath; - this.mapWindowToBackupFolder = Object.create(null); this.loadSync(); } @@ -50,22 +47,16 @@ export class BackupMainService implements IBackupMainService { return this.backups.emptyWorkspaces.slice(0); // return a copy } - public getBackupPath(windowId: number): TPromise { - if (!this.mapWindowToBackupFolder[windowId]) { - throw new Error(`Unknown backup workspace for window ${windowId}`); - } - - return TPromise.as(path.join(this.backupHome, this.mapWindowToBackupFolder[windowId])); - } + public registerWindowForBackupsSync(windowId: number, isEmptyWorkspace: boolean, backupFolder?: string, workspacePath?: string): string { - public registerWindowForBackupsSync(windowId: number, isEmptyWorkspace: boolean, backupFolder?: string, workspacePath?: string): void { // Generate a new folder if this is a new empty workspace if (isEmptyWorkspace && !backupFolder) { backupFolder = this.getRandomEmptyWorkspaceId(); } - this.mapWindowToBackupFolder[windowId] = isEmptyWorkspace ? backupFolder : this.getWorkspaceHash(workspacePath); this.pushBackupPathsSync(isEmptyWorkspace ? backupFolder : workspacePath, isEmptyWorkspace); + + return path.join(this.backupHome, isEmptyWorkspace ? backupFolder : this.getWorkspaceHash(workspacePath)); } private pushBackupPathsSync(workspaceIdentifier: string, isEmptyWorkspace: boolean): string { diff --git a/src/vs/platform/backup/test/electron-main/backupMainService.test.ts b/src/vs/platform/backup/test/electron-main/backupMainService.test.ts index 179a648ba0b..9519702d03e 100644 --- a/src/vs/platform/backup/test/electron-main/backupMainService.test.ts +++ b/src/vs/platform/backup/test/electron-main/backupMainService.test.ts @@ -336,33 +336,6 @@ suite('BackupMainService', () => { }); }); - suite('getBackupPath', () => { - test('should return the window\'s correct path', done => { - service.registerWindowForBackupsSync(1, false, null, fooFile.fsPath); - service.registerWindowForBackupsSync(2, true, 'test'); - service.getBackupPath(1).then(window1Path => { - assert.equal(window1Path, service.toBackupPath(fooFile.fsPath)); - service.getBackupPath(2).then(window2Path => { - assert.equal(window2Path, path.join(backupHome, 'test')); - done(); - }); - }); - }); - - test('should override stale window paths with new paths', done => { - service.registerWindowForBackupsSync(1, false, null, fooFile.fsPath); - service.registerWindowForBackupsSync(1, false, null, barFile.fsPath); - service.getBackupPath(1).then(windowPath => { - assert.equal(windowPath, service.toBackupPath(barFile.fsPath)); - done(); - }); - }); - - test('should throw when the window is not registered', () => { - assert.throws(() => service.getBackupPath(1)); - }); - }); - suite('mixed path casing', () => { test('should handle case insensitive paths properly (registerWindowForBackupsSync)', done => { service.registerWindowForBackupsSync(1, false, null, fooFile.fsPath); diff --git a/src/vs/platform/windows/common/windows.ts b/src/vs/platform/windows/common/windows.ts index ac16cd0c60a..4cb6db0cac3 100644 --- a/src/vs/platform/windows/common/windows.ts +++ b/src/vs/platform/windows/common/windows.ts @@ -97,6 +97,10 @@ export interface IWindowService { export type MenuBarVisibility = 'default' | 'visible' | 'toggle' | 'hidden'; +export interface IWindowConfiguration { + window: IWindowSettings; +} + export interface IWindowSettings { openFilesInNewWindow: 'on' | 'off' | 'default'; openFoldersInNewWindow: 'on' | 'off' | 'default'; @@ -173,7 +177,13 @@ export interface IPath { createFilePath?: boolean; } -export interface IWindowConfiguration extends ParsedArgs { +export interface IOpenFileRequest { + filesToOpen?: IPath[]; + filesToCreate?: IPath[]; + filesToDiff?: IPath[]; +} + +export interface IWindowConfiguration extends ParsedArgs, IOpenFileRequest { appRoot: string; execPath: string; @@ -196,9 +206,7 @@ export interface IWindowConfiguration extends ParsedArgs { workspacePath?: string; - filesToOpen?: IPath[]; - filesToCreate?: IPath[]; - filesToDiff?: IPath[]; + backupPath?: string; nodeCachedDataDir: string; } \ No newline at end of file diff --git a/src/vs/workbench/electron-browser/common.ts b/src/vs/workbench/electron-browser/common.ts deleted file mode 100644 index 9ddf433eeed..00000000000 --- a/src/vs/workbench/electron-browser/common.ts +++ /dev/null @@ -1,22 +0,0 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ - -import { IWindowSettings } from 'vs/platform/windows/common/windows'; - -export interface IPath { - filePath: string; - lineNumber?: number; - columnNumber?: number; -} - -export interface IOpenFileRequest { - filesToOpen?: IPath[]; - filesToCreate?: IPath[]; - filesToDiff?: IPath[]; -} - -export interface IWindowConfiguration { - window: IWindowSettings; -} \ No newline at end of file diff --git a/src/vs/workbench/electron-browser/main.ts b/src/vs/workbench/electron-browser/main.ts index 4afe4e06bf4..69ca40fed63 100644 --- a/src/vs/workbench/electron-browser/main.ts +++ b/src/vs/workbench/electron-browser/main.ts @@ -20,41 +20,20 @@ import strings = require('vs/base/common/strings'); import { IResourceInput } from 'vs/platform/editor/common/editor'; import { WorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import { WorkspaceConfigurationService } from 'vs/workbench/services/configuration/node/configurationService'; -import { ParsedArgs } from 'vs/platform/environment/common/environment'; import { realpath, stat } from 'vs/base/node/pfs'; import { EnvironmentService } from 'vs/platform/environment/node/environmentService'; import path = require('path'); import gracefulFs = require('graceful-fs'); -import { IPath, IOpenFileRequest } from 'vs/workbench/electron-browser/common'; import { IInitData } from 'vs/workbench/services/timer/common/timerService'; import { TimerService } from 'vs/workbench/services/timer/node/timerService'; import { KeyboardMapperFactory } from "vs/workbench/services/keybinding/electron-browser/keybindingService"; +import { IWindowConfiguration, IPath } from "vs/platform/windows/common/windows"; import { webFrame } from 'electron'; import fs = require('fs'); gracefulFs.gracefulify(fs); // enable gracefulFs -export interface IWindowConfiguration extends ParsedArgs, IOpenFileRequest { - - /** - * The physical keyboard is of ISO type (on OSX). - */ - isISOKeyboard?: boolean; - - accessibilitySupport?: boolean; - - appRoot: string; - execPath: string; - - userEnv: any; /* vs/code/electron-main/env/IProcessEnvironment*/ - - workspacePath?: string; - - zoomLevel?: number; - fullscreen?: boolean; -} - export function startup(configuration: IWindowConfiguration): TPromise { // Ensure others can listen to zoom level changes @@ -148,8 +127,8 @@ function getWorkspace(workspacePath: string): TPromise { }); } -function openWorkbench(environment: IWindowConfiguration, workspace: Workspace, options: IOptions): TPromise { - const environmentService = new EnvironmentService(environment, environment.execPath); +function openWorkbench(configuration: IWindowConfiguration, workspace: Workspace, options: IOptions): TPromise { + const environmentService = new EnvironmentService(configuration, configuration.execPath); const configurationService = new WorkspaceConfigurationService(environmentService, workspace); const contextService = new WorkspaceContextService(configurationService, workspace); const timerService = new TimerService((window).MonacoEnvironment.timers as IInitData, !contextService.hasWorkspace()); @@ -169,7 +148,7 @@ function openWorkbench(environment: IWindowConfiguration, workspace: Workspace, contextService, environmentService, timerService - }, options); + }, configuration, options); shell.open(); // Inform user about loading issues from the loader diff --git a/src/vs/workbench/electron-browser/shell.ts b/src/vs/workbench/electron-browser/shell.ts index e0fb2e384aa..cce0d8cf300 100644 --- a/src/vs/workbench/electron-browser/shell.ts +++ b/src/vs/workbench/electron-browser/shell.ts @@ -33,7 +33,7 @@ import { resolveWorkbenchCommonProperties, getOrCreateMachineId } from 'vs/platf import { machineIdIpcChannel } from 'vs/platform/telemetry/node/commonProperties'; import { WorkspaceStats } from 'vs/workbench/services/telemetry/common/workspaceStats'; import { IWindowIPCService, WindowIPCService } from 'vs/workbench/services/window/electron-browser/windowService'; -import { IWindowsService, IWindowService } from 'vs/platform/windows/common/windows'; +import { IWindowsService, IWindowService, IWindowConfiguration } from 'vs/platform/windows/common/windows'; import { WindowsChannelClient } from 'vs/platform/windows/common/windowsIpc'; import { WindowService } from 'vs/platform/windows/electron-browser/windowService'; import { MessageService } from 'vs/workbench/services/message/electron-browser/messageService'; @@ -86,8 +86,6 @@ import { UpdateChannelClient } from 'vs/platform/update/common/updateIpc'; import { IUpdateService } from 'vs/platform/update/common/update'; import { URLChannelClient } from 'vs/platform/url/common/urlIpc'; import { IURLService } from 'vs/platform/url/common/url'; -import { IBackupService } from 'vs/platform/backup/common/backup'; -import { BackupChannelClient } from 'vs/platform/backup/common/backupIpc'; import { ExtensionHostProcessWorker } from 'vs/workbench/electron-browser/extensionHost'; import { ITimerService } from 'vs/workbench/services/timer/common/timerService'; import { remote, ipcRenderer as ipc } from 'electron'; @@ -141,12 +139,14 @@ export class WorkbenchShell { private content: HTMLElement; private contentsContainer: Builder; + private configuration: IWindowConfiguration; private options: IOptions; private workbench: Workbench; - constructor(container: HTMLElement, services: ICoreServices, options: IOptions) { + constructor(container: HTMLElement, services: ICoreServices, configuration: IWindowConfiguration, options: IOptions) { this.container = container; + this.configuration = configuration; this.options = options; this.contextService = services.contextService; @@ -170,7 +170,7 @@ export class WorkbenchShell { const [instantiationService, serviceCollection] = this.initServiceCollection(parent.getHTMLElement()); // Workbench - this.workbench = instantiationService.createInstance(Workbench, parent.getHTMLElement(), workbenchContainer.getHTMLElement(), this.options, serviceCollection); + this.workbench = instantiationService.createInstance(Workbench, parent.getHTMLElement(), workbenchContainer.getHTMLElement(), this.configuration, this.options, serviceCollection); this.workbench.startup({ onWorkbenchStarted: (info: IWorkbenchStartedInfo) => { @@ -386,9 +386,6 @@ export class WorkbenchShell { const urlChannel = mainProcessClient.getChannel('url'); serviceCollection.set(IURLService, new SyncDescriptor(URLChannelClient, urlChannel, this.windowIPCService.getWindowId())); - const backupChannel = mainProcessClient.getChannel('backup'); - serviceCollection.set(IBackupService, new SyncDescriptor(BackupChannelClient, backupChannel)); - return [instantiationService, serviceCollection]; } diff --git a/src/vs/workbench/electron-browser/window.ts b/src/vs/workbench/electron-browser/window.ts index 15bfd13bb22..d164d685161 100644 --- a/src/vs/workbench/electron-browser/window.ts +++ b/src/vs/workbench/electron-browser/window.ts @@ -26,12 +26,11 @@ import { IWorkbenchEditorService, IResourceInputType } from 'vs/workbench/servic import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { IMessageService } from 'vs/platform/message/common/message'; import { IWorkspaceConfigurationService } from 'vs/workbench/services/configuration/common/configuration'; -import { IWindowsService, IWindowService, IWindowSettings } from 'vs/platform/windows/common/windows'; +import { IWindowsService, IWindowService, IWindowSettings, IWindowConfiguration, IPath, IOpenFileRequest } from 'vs/platform/windows/common/windows'; import { IContextMenuService } from 'vs/platform/contextview/browser/contextView'; import { IWindowIPCService } from 'vs/workbench/services/window/electron-browser/windowService'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; -import { IPath, IOpenFileRequest, IWindowConfiguration } from 'vs/workbench/electron-browser/common'; import { IConfigurationEditingService, ConfigurationTarget } from 'vs/workbench/services/configuration/common/configurationEditing'; import { ITitleService } from 'vs/workbench/services/title/common/titleService'; import { IWorkbenchThemeService, VS_HC_THEME, VS_DARK_THEME } from 'vs/workbench/services/themes/common/workbenchThemeService'; diff --git a/src/vs/workbench/electron-browser/workbench.ts b/src/vs/workbench/electron-browser/workbench.ts index ca0524e3014..a6dd9426102 100644 --- a/src/vs/workbench/electron-browser/workbench.ts +++ b/src/vs/workbench/electron-browser/workbench.ts @@ -83,7 +83,7 @@ import { TextModelResolverService } from 'vs/workbench/services/textmodelResolve import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; import { ILifecycleService, ShutdownReason } from 'vs/platform/lifecycle/common/lifecycle'; -import { IWindowService } from 'vs/platform/windows/common/windows'; +import { IWindowService, IWindowConfiguration as IWindowSettings, IWindowConfiguration } from 'vs/platform/windows/common/windows'; import { IMessageService } from 'vs/platform/message/common/message'; import { IStatusbarService } from 'vs/platform/statusbar/common/statusbar'; import { IMenuService, SyncActionDescriptor } from 'vs/platform/actions/common/actions'; @@ -91,7 +91,6 @@ import { MenuService } from 'vs/platform/actions/common/menuService'; import { IContextMenuService } from 'vs/platform/contextview/browser/contextView'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; -import { IWindowConfiguration } from 'vs/workbench/electron-browser/common'; import { IWorkbenchActionRegistry, Extensions } from 'vs/workbench/common/actionRegistry'; import { OpenRecentAction, ToggleDevToolsAction, ReloadWindowAction } from "vs/workbench/electron-browser/actions"; import { KeyMod } from 'vs/base/common/keyCodes'; @@ -104,6 +103,7 @@ export const NoEditorsVisibleContext: ContextKeyExpr = EditorsVisibleContext.toN interface WorkbenchParams { options: IOptions; + configuration: IWindowConfiguration; serviceCollection: ServiceCollection; } @@ -204,6 +204,7 @@ export class Workbench implements IPartService { constructor( parent: HTMLElement, container: HTMLElement, + configuration: IWindowConfiguration, options: IOptions, serviceCollection: ServiceCollection, @IInstantiationService private instantiationService: IInstantiationService, @@ -221,6 +222,7 @@ export class Workbench implements IPartService { this.workbenchParams = { options, + configuration, serviceCollection }; @@ -522,7 +524,7 @@ export class Workbench implements IPartService { serviceCollection.set(IHistoryService, new SyncDescriptor(HistoryService)); // Backup File Service - this.backupFileService = this.instantiationService.createInstance(BackupFileService); + this.backupFileService = this.instantiationService.createInstance(BackupFileService, this.workbenchParams.configuration.backupPath); serviceCollection.set(IBackupFileService, this.backupFileService); // Text File Service @@ -685,7 +687,7 @@ export class Workbench implements IPartService { return null; // not enabled when developing due to https://github.com/electron/electron/issues/3647 } - const windowConfig = this.configurationService.getConfiguration(); + const windowConfig = this.configurationService.getConfiguration(); if (windowConfig && windowConfig.window) { const useNativeTabs = windowConfig.window.nativeTabs; if (useNativeTabs) { diff --git a/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.ts b/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.ts index a4a4b1b9f8c..5e82b8c104e 100644 --- a/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.ts +++ b/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.ts @@ -10,9 +10,8 @@ import { IWorkbenchContributionsRegistry, IWorkbenchContribution, Extensions as import { Registry } from 'vs/platform/platform'; import { IMessageService } from 'vs/platform/message/common/message'; import { IPreferencesService } from 'vs/workbench/parts/preferences/common/preferences'; -import { IWindowsService, IWindowService } from 'vs/platform/windows/common/windows'; +import { IWindowsService, IWindowService, IWindowConfiguration } from 'vs/platform/windows/common/windows'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { IWindowConfiguration } from "vs/workbench/electron-browser/common"; import { localize } from 'vs/nls'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; diff --git a/src/vs/workbench/services/backup/node/backupFileService.ts b/src/vs/workbench/services/backup/node/backupFileService.ts index 8b1e2b5cd23..223bddc599f 100644 --- a/src/vs/workbench/services/backup/node/backupFileService.ts +++ b/src/vs/workbench/services/backup/node/backupFileService.ts @@ -12,12 +12,9 @@ import pfs = require('vs/base/node/pfs'); import Uri from 'vs/base/common/uri'; import { Queue } from 'vs/base/common/async'; import { IBackupFileService, BACKUP_FILE_UPDATE_OPTIONS } from 'vs/workbench/services/backup/common/backup'; -import { IBackupService } from 'vs/platform/backup/common/backup'; -import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { IFileService } from 'vs/platform/files/common/files'; import { TPromise } from 'vs/base/common/winjs.base'; import { readToMatchingString } from 'vs/base/node/stream'; -import { IWindowService } from 'vs/platform/windows/common/windows'; import { TextSource, IRawTextSource } from 'vs/editor/common/model/textSource'; import { DefaultEndOfLine } from 'vs/editor/common/editorCommon'; @@ -96,7 +93,6 @@ export class BackupFileService implements IBackupFileService { private static readonly META_MARKER = '\n'; private isShuttingDown: boolean; - private backupWorkspacePath: string; private ready: TPromise; /** * Ensure IO operations on individual files are performed in order, this could otherwise lead @@ -105,32 +101,26 @@ export class BackupFileService implements IBackupFileService { private ioOperationQueues: { [path: string]: Queue }; constructor( - @IEnvironmentService private environmentService: IEnvironmentService, - @IFileService private fileService: IFileService, - @IWindowService windowService: IWindowService, - @IBackupService private backupService: IBackupService + private backupWorkspacePath: string, + @IFileService private fileService: IFileService ) { this.isShuttingDown = false; - this.ready = this.init(windowService.getCurrentWindowId()); this.ioOperationQueues = {}; + this.ready = this.init(); } private get backupEnabled(): boolean { - return !this.environmentService.isExtensionDevelopment; // Hot exit is disabled when doing extension development + return !!this.backupWorkspacePath; // Hot exit requires a backup path } - private init(windowId: number): TPromise { + private init(): TPromise { const model = new BackupFilesModel(); if (!this.backupEnabled) { return TPromise.as(model); } - return this.backupService.getBackupPath(windowId).then(backupPath => { - this.backupWorkspacePath = backupPath; - - return model.resolve(this.backupWorkspacePath); - }); + return model.resolve(this.backupWorkspacePath); } public hasBackups(): TPromise { diff --git a/src/vs/workbench/services/backup/test/backupFileService.test.ts b/src/vs/workbench/services/backup/test/backupFileService.test.ts index 0c5c56ed14e..838f9333945 100644 --- a/src/vs/workbench/services/backup/test/backupFileService.test.ts +++ b/src/vs/workbench/services/backup/test/backupFileService.test.ts @@ -17,10 +17,7 @@ import Uri from 'vs/base/common/uri'; import { BackupFileService, BackupFilesModel } from 'vs/workbench/services/backup/node/backupFileService'; import { FileService } from 'vs/workbench/services/files/node/fileService'; import { EnvironmentService } from 'vs/platform/environment/node/environmentService'; -import { IBackupService } from 'vs/platform/backup/common/backup'; import { parseArgs } from 'vs/platform/environment/node/argv'; -import { TPromise } from 'vs/base/common/winjs.base'; -import { TestWindowService } from 'vs/workbench/test/workbenchTestServices'; import { RawTextSource } from 'vs/editor/common/model/textSource'; class TestEnvironmentService extends EnvironmentService { @@ -51,13 +48,8 @@ const untitledBackupPath = path.join(workspaceBackupPath, 'untitled', crypto.cre class TestBackupFileService extends BackupFileService { constructor(workspace: Uri, backupHome: string, workspacesJsonPath: string) { const fileService = new FileService(workspace.fsPath, { disableWatcher: true }); - const environmentService = new TestEnvironmentService(backupHome, workspacesJsonPath); - const backupService: IBackupService = { - _serviceBrand: null, - getBackupPath: () => TPromise.as(workspaceBackupPath) - }; - super(environmentService, fileService, new TestWindowService(), backupService); + super(workspaceBackupPath, fileService); } public getBackupResource(resource: Uri, legacyMacWindowsFormat?: boolean): Uri { -- GitLab From 03bb0adf982f54dea6a63b757b10658baf042a1a Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Tue, 13 Jun 2017 08:24:57 +0200 Subject: [PATCH 0749/1347] Remember all UI state even for empty windows (fixes #207) (#28580) --- src/vs/code/electron-main/launch.ts | 2 +- src/vs/code/electron-main/menus.ts | 2 +- src/vs/code/electron-main/window.ts | 8 +- src/vs/code/electron-main/windows.ts | 380 +++++++++++------- .../platform/storage/common/storageService.ts | 30 +- .../storage/test/storageService.test.ts | 12 +- .../telemetry/common/telemetryUtils.ts | 1 + .../electron-browser/commonProperties.test.ts | 2 +- src/vs/platform/windows/common/windows.ts | 9 +- .../workbench/browser/parts/compositePart.ts | 10 +- .../browser/parts/editor/editorPart.ts | 6 +- .../browser/parts/panel/panelPart.ts | 1 + .../browser/parts/sidebar/sidebarPart.ts | 1 + .../common/editor/editorStacksModel.ts | 6 +- .../electron-browser/main.contribution.ts | 13 +- src/vs/workbench/electron-browser/shell.ts | 17 +- .../workbench/electron-browser/workbench.ts | 31 +- .../parts/backup/common/backupModelTracker.ts | 4 +- .../parts/backup/common/backupRestorer.ts | 8 +- .../debug/electron-browser/debugService.ts | 39 +- .../parts/debug/electron-browser/repl.ts | 7 +- .../parts/files/browser/files.contribution.ts | 2 +- .../parts/files/browser/views/explorerView.ts | 11 +- .../parts/search/browser/searchViewlet.ts | 8 +- .../services/backup/common/backup.ts | 5 + .../services/backup/node/backupFileService.ts | 2 +- src/vs/workbench/test/browser/part.test.ts | 2 +- src/vs/workbench/test/common/memento.test.ts | 2 +- .../workbench/test/workbenchTestServices.ts | 4 +- 29 files changed, 416 insertions(+), 209 deletions(-) diff --git a/src/vs/code/electron-main/launch.ts b/src/vs/code/electron-main/launch.ts index b3ad62b18fb..14128133e06 100644 --- a/src/vs/code/electron-main/launch.ts +++ b/src/vs/code/electron-main/launch.ts @@ -114,7 +114,7 @@ export class LaunchService implements ILaunchService { // If the other instance is waiting to be killed, we hook up a window listener if one window // is being used and only then resolve the startup promise which will kill this second instance - if (args.wait && usedWindows && usedWindows.length === 1 && usedWindows[0]) { + if (args.wait && usedWindows.length === 1 && usedWindows[0]) { const windowId = usedWindows[0].id; return new TPromise((c, e) => { diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index fe2206f6a36..a2193ec6244 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -448,7 +448,7 @@ export class CodeMenu { return new MenuItem(this.likeAction(commandId, { label: this.unmnemonicLabel(tildify(path, this.environmentService.userHome)), click: (menuItem, win, event) => { const openInNewWindow = this.isOptionClick(event); - const success = !!this.windowsService.open({ context: OpenContext.MENU, cli: this.environmentService.args, pathsToOpen: [path], forceNewWindow: openInNewWindow }); + const success = this.windowsService.open({ context: OpenContext.MENU, cli: this.environmentService.args, pathsToOpen: [path], forceNewWindow: openInNewWindow }).length > 0; if (!success) { this.historyService.removeFromRecentPathsList(path); } diff --git a/src/vs/code/electron-main/window.ts b/src/vs/code/electron-main/window.ts index 36e059d804e..94c907dd4cc 100644 --- a/src/vs/code/electron-main/window.ts +++ b/src/vs/code/electron-main/window.ts @@ -271,11 +271,15 @@ export class CodeWindow implements ICodeWindow { } public get openedWorkspacePath(): string { - return this.currentConfig.workspacePath; + return this.currentConfig ? this.currentConfig.workspacePath : void 0; + } + + public get backupPath(): string { + return this.currentConfig ? this.currentConfig.backupPath : void 0; } public get openedFilePath(): string { - return this.currentConfig.filesToOpen && this.currentConfig.filesToOpen[0] && this.currentConfig.filesToOpen[0].filePath; + return this.currentConfig && this.currentConfig.filesToOpen && this.currentConfig.filesToOpen[0] && this.currentConfig.filesToOpen[0].filePath; } public setReady(): void { diff --git a/src/vs/code/electron-main/windows.ts b/src/vs/code/electron-main/windows.ts index 537b279af93..f05f08784a8 100644 --- a/src/vs/code/electron-main/windows.ts +++ b/src/vs/code/electron-main/windows.ts @@ -40,20 +40,18 @@ interface INewWindowState extends ISingleWindowState { interface IWindowState { workspacePath?: string; + backupPath: string; uiState: ISingleWindowState; } interface IWindowsState { lastActiveWindow?: IWindowState; lastPluginDevelopmentHostWindow?: IWindowState; - openedFolders: IWindowState[]; + openedWindows: IWindowState[]; + openedFolders?: IWindowState[]; // TODO@Ben deprecated } -const ReopenFoldersSetting = { - ALL: 'all', - ONE: 'one', - NONE: 'none' -}; +type RestoreWindowsSetting = 'all' | 'folders' | 'one' | 'none'; interface IOpenBrowserWindowOptions { userEnv?: IProcessEnvironment; @@ -72,6 +70,18 @@ interface IOpenBrowserWindowOptions { emptyWorkspaceBackupFolder?: string; } +interface IWindowToOpen extends IPath { + + // the workspace spath for a Code instance to open + workspacePath?: string; + + // the backup spath for a Code instance to use + backupPath?: string; + + // indicator to create the file path in the Code instance + createFilePath?: boolean; +} + export class WindowsManager implements IWindowsMainService { _serviceBrand: any; @@ -109,7 +119,16 @@ export class WindowsManager implements IWindowsMainService { @IConfigurationService private configurationService: IConfigurationService, @IHistoryMainService private historyService: IHistoryMainService ) { - this.windowsState = this.storageService.getItem(WindowsManager.windowsStateStorageKey) || { openedFolders: [] }; + this.windowsState = this.storageService.getItem(WindowsManager.windowsStateStorageKey) || { openedWindows: [] }; + + // TODO@Ben migration from previous openedFolders to new openedWindows property + if (Array.isArray(this.windowsState.openedFolders) && this.windowsState.openedFolders.length > 0) { + this.windowsState.openedWindows = this.windowsState.openedFolders; + this.windowsState.openedFolders = void 0; + } else if (!this.windowsState.openedWindows) { + this.windowsState.openedWindows = []; + } + this.fileDialog = new FileDialog(environmentService, telemetryService, storageService, this); } @@ -148,7 +167,8 @@ export class WindowsManager implements IWindowsMainService { // and then onBeforeWindowClose(). private onBeforeQuit(): void { const currentWindowsState: IWindowsState = { - openedFolders: [], + openedWindows: [], + openedFolders: [], // TODO@Ben migration so that old clients do not fail over data (prevents NPEs) lastPluginDevelopmentHostWindow: this.windowsState.lastPluginDevelopmentHostWindow, lastActiveWindow: this.lastClosedWindowState }; @@ -161,26 +181,27 @@ export class WindowsManager implements IWindowsMainService { } if (activeWindow) { - currentWindowsState.lastActiveWindow = { workspacePath: activeWindow.openedWorkspacePath, uiState: activeWindow.serializeWindowState() }; + currentWindowsState.lastActiveWindow = { workspacePath: activeWindow.openedWorkspacePath, uiState: activeWindow.serializeWindowState(), backupPath: activeWindow.backupPath }; } } // 2.) Find extension host window const extensionHostWindow = WindowsManager.WINDOWS.filter(w => w.isExtensionDevelopmentHost && !w.isExtensionTestHost)[0]; if (extensionHostWindow) { - currentWindowsState.lastPluginDevelopmentHostWindow = { workspacePath: extensionHostWindow.openedWorkspacePath, uiState: extensionHostWindow.serializeWindowState() }; + currentWindowsState.lastPluginDevelopmentHostWindow = { workspacePath: extensionHostWindow.openedWorkspacePath, uiState: extensionHostWindow.serializeWindowState(), backupPath: extensionHostWindow.backupPath }; } - // 3.) All windows with opened folders for N >= 2 to support reopenFolders: all or for auto update + // 3.) All windows (except extension host) for N >= 2 to support restoreWindows: all or for auto update // // Carefull here: asking a window for its window state after it has been closed returns bogus values (width: 0, height: 0) // so if we ever want to persist the UI state of the last closed window (window count === 1), it has // to come from the stored lastClosedWindowState on Win/Linux at least if (this.getWindowCount() > 1) { - currentWindowsState.openedFolders = WindowsManager.WINDOWS.filter(w => !!w.openedWorkspacePath && !w.isExtensionDevelopmentHost).map(w => { + currentWindowsState.openedWindows = WindowsManager.WINDOWS.filter(w => !w.isExtensionDevelopmentHost).map(w => { return { workspacePath: w.openedWorkspacePath, - uiState: w.serializeWindowState() + uiState: w.serializeWindowState(), + backupPath: w.backupPath }; }); } @@ -196,14 +217,14 @@ export class WindowsManager implements IWindowsMainService { } // On Window close, update our stored UI state of this window - const state: IWindowState = { workspacePath: win.openedWorkspacePath, uiState: win.serializeWindowState() }; + const state: IWindowState = { workspacePath: win.openedWorkspacePath, uiState: win.serializeWindowState(), backupPath: win.backupPath }; if (win.isExtensionDevelopmentHost && !win.isExtensionTestHost) { this.windowsState.lastPluginDevelopmentHostWindow = state; // do not let test run window state overwrite our extension development state } // Any non extension host window with same workspace else if (!win.isExtensionDevelopmentHost && !!win.openedWorkspacePath) { - this.windowsState.openedFolders.forEach(o => { + this.windowsState.openedWindows.forEach(o => { if (isEqual(o.workspacePath, win.openedWorkspacePath, !isLinux /* ignorecase */)) { o.uiState = state.uiState; } @@ -220,37 +241,79 @@ export class WindowsManager implements IWindowsMainService { } public open(openConfig: IOpenConfiguration): CodeWindow[] { + const windowsToOpen = this.getWindowsToOpen(openConfig); - // Find paths to open from config - const pathsToOpen = this.getPathsToOpen(openConfig); - if (!pathsToOpen) { - return null; // indicate to outside that open failed + // + // These are windows to open to show either folders or files (including diffing files or creating them) + // + const foldersToOpen = arrays.distinct(windowsToOpen.filter(win => win.workspacePath && !win.filePath).map(win => win.workspacePath), folder => isLinux ? folder : folder.toLowerCase()); // prevent duplicates + const emptyToOpen = windowsToOpen.filter(win => !win.workspacePath && !win.filePath && !win.backupPath).length; + + let filesToOpen = windowsToOpen.filter(path => !!path.filePath && !path.createFilePath); + let filesToCreate = windowsToOpen.filter(path => !!path.filePath && path.createFilePath); + let filesToDiff: IPath[]; + if (openConfig.diffMode && filesToOpen.length === 2) { + filesToDiff = filesToOpen; + filesToOpen = []; + filesToCreate = []; // diff ignores other files that do not exist + } else { + filesToDiff = []; } - let foldersToOpen = arrays.distinct(pathsToOpen.filter(iPath => iPath.workspacePath && !iPath.filePath).map(iPath => iPath.workspacePath), folder => isLinux ? folder : folder.toLowerCase()); // prevent duplicates - let foldersToRestore = (openConfig.initialStartup && !openConfig.cli.extensionDevelopmentPath) ? this.backupService.getWorkspaceBackupPaths() : []; - let filesToOpen: IPath[] = []; - let filesToDiff: IPath[] = []; - let filesToCreate = pathsToOpen.filter(iPath => !!iPath.filePath && iPath.createFilePath); - let emptyToOpen = pathsToOpen.filter(iPath => !iPath.workspacePath && !iPath.filePath); - let emptyToRestore = (openConfig.initialStartup && !openConfig.cli.extensionDevelopmentPath) ? this.backupService.getEmptyWorkspaceBackupPaths() : []; - - // Diff mode needs special care - const filesToOpenCandidates = pathsToOpen.filter(iPath => !!iPath.filePath && !iPath.createFilePath); - if (openConfig.diffMode) { - if (filesToOpenCandidates.length === 2) { - filesToDiff = filesToOpenCandidates; - } else { - emptyToOpen = [Object.create(null)]; // improper use of diffMode, open empty + // + // These are windows to restore because of hot-exit + // + const hotExitRestore = (openConfig.initialStartup && !openConfig.cli.extensionDevelopmentPath); + const foldersToRestore = hotExitRestore ? this.backupService.getWorkspaceBackupPaths() : []; + const emptyToRestore = hotExitRestore ? this.backupService.getEmptyWorkspaceBackupPaths() : []; + emptyToRestore.push(...windowsToOpen.filter(w => !w.workspacePath && w.backupPath).map(w => path.basename(w.backupPath))); // add empty windows with backupPath + + // Open based on config + const usedWindows = this.doOpen(openConfig, foldersToOpen, foldersToRestore, emptyToRestore, emptyToOpen, filesToOpen, filesToCreate, filesToDiff); + + // Make sure the last active window gets focus if we opened multiple + if (usedWindows.length > 1 && this.windowsState.lastActiveWindow) { + let lastActiveWindw = usedWindows.filter(w => w.backupPath === this.windowsState.lastActiveWindow.backupPath); + if (lastActiveWindw.length) { + lastActiveWindw[0].focus(); } + } - foldersToOpen = []; // diff is always in empty workspace - foldersToRestore = []; // diff is always in empty workspace - filesToCreate = []; // diff ignores other files that do not exist - } else { - filesToOpen = filesToOpenCandidates; + // Remember in recent document list (unless this opens for extension development) + // Also do not add paths when files are opened for diffing, only if opened individually + if (!usedWindows.some(w => w.isExtensionDevelopmentHost) && !openConfig.cli.diff) { + const recentPaths: { path: string; isFile?: boolean; }[] = []; + + windowsToOpen.forEach(win => { + if (win.filePath || win.workspacePath) { + recentPaths.push({ path: win.filePath || win.workspacePath, isFile: !!win.filePath }); + } + }); + + if (recentPaths.length) { + this.historyService.addToRecentPathsList(recentPaths); + } } + // Emit events + if (windowsToOpen.length) { + this._onPathsOpen.fire(windowsToOpen); + } + + return usedWindows; + } + + private doOpen( + openConfig: IOpenConfiguration, + foldersToOpen: string[], + foldersToRestore: string[], + emptyToRestore: string[], + emptyToOpen: number, + filesToOpen: IPath[], + filesToCreate: IPath[], + filesToDiff: IPath[] + ) { + // Settings can decide if files/folders open in new window or not let { openFolderInNewWindow, openFilesInNewWindow } = this.shouldOpenNewWindow(openConfig); @@ -380,8 +443,8 @@ export class WindowsManager implements IWindowsMainService { } // Only open empty if no empty workspaces were restored - else if (emptyToOpen.length > 0) { - emptyToOpen.forEach(() => { + else if (emptyToOpen > 0) { + for (let i = 0; i < emptyToOpen; i++) { const browserWindow = this.openInBrowserWindow({ userEnv: openConfig.userEnv, cli: openConfig.cli, @@ -392,140 +455,167 @@ export class WindowsManager implements IWindowsMainService { usedWindows.push(browserWindow); openFolderInNewWindow = true; // any other folders to open must open in new window then - }); - } - - // Remember in recent document list (unless this opens for extension development) - // Also do not add paths when files are opened for diffing, only if opened individually - if (!usedWindows.some(w => w.isExtensionDevelopmentHost) && !openConfig.cli.diff) { - const recentPaths: { path: string; isFile?: boolean; }[] = []; - - pathsToOpen.forEach(iPath => { - if (iPath.filePath || iPath.workspacePath) { - recentPaths.push({ path: iPath.filePath || iPath.workspacePath, isFile: !!iPath.filePath }); - } - }); - - if (recentPaths.length) { - this.historyService.addToRecentPathsList(recentPaths); } } - // Emit events - this._onPathsOpen.fire(pathsToOpen); - return arrays.distinct(usedWindows); } - private getPathsToOpen(openConfig: IOpenConfiguration): IPath[] { - let iPathsToOpen: IPath[]; + private getWindowsToOpen(openConfig: IOpenConfiguration): IWindowToOpen[] { + let windowsToOpen: IWindowToOpen[]; - // Find paths from provided paths if any + // Extract paths: from API if (openConfig.pathsToOpen && openConfig.pathsToOpen.length > 0) { - iPathsToOpen = openConfig.pathsToOpen.map(pathToOpen => { - const iPath = this.toIPath(pathToOpen, false, openConfig.cli && openConfig.cli.goto); - - // Warn if the requested path to open does not exist - if (!iPath) { - const options: Electron.ShowMessageBoxOptions = { - title: product.nameLong, - type: 'info', - buttons: [nls.localize('ok', "OK")], - message: nls.localize('pathNotExistTitle', "Path does not exist"), - detail: nls.localize('pathNotExistDetail', "The path '{0}' does not seem to exist anymore on disk.", pathToOpen), - noLink: true - }; - - const activeWindow = BrowserWindow.getFocusedWindow(); - if (activeWindow) { - dialog.showMessageBox(activeWindow, options); - } else { - dialog.showMessageBox(options); - } - } - - return iPath; - }); - - // get rid of nulls - iPathsToOpen = arrays.coalesce(iPathsToOpen); - - if (iPathsToOpen.length === 0) { - return null; // indicate to outside that open failed - } + windowsToOpen = this.doExtractPathsFromAPI(openConfig.pathsToOpen, openConfig.cli && openConfig.cli.goto); } // Check for force empty else if (openConfig.forceEmpty) { - iPathsToOpen = [Object.create(null)]; + windowsToOpen = [Object.create(null)]; } - // Otherwise infer from command line arguments + // Extract paths: from CLI else if (openConfig.cli._.length > 0) { - iPathsToOpen = this.doExtractPathsFromCLI(openConfig.cli); + windowsToOpen = this.doExtractPathsFromCLI(openConfig.cli); } - // Finally check for paths from previous session + // Extract windows: from previous session else { - iPathsToOpen = this.doExtractPathsFromLastSession(); + windowsToOpen = this.doGetWindowsFromLastSession(); } - return iPathsToOpen; + return windowsToOpen; } - private doExtractPathsFromCLI(cli: ParsedArgs): IPath[] { - const candidates: string[] = cli._; + private doExtractPathsFromAPI(paths: string[], gotoLineMode: boolean): IPath[] { + let pathsToOpen = paths.map(pathToOpen => { + const path = this.parsePath(pathToOpen, false, gotoLineMode); + + // Warn if the requested path to open does not exist + if (!path) { + const options: Electron.ShowMessageBoxOptions = { + title: product.nameLong, + type: 'info', + buttons: [nls.localize('ok', "OK")], + message: nls.localize('pathNotExistTitle', "Path does not exist"), + detail: nls.localize('pathNotExistDetail', "The path '{0}' does not seem to exist anymore on disk.", pathToOpen), + noLink: true + }; + + const activeWindow = BrowserWindow.getFocusedWindow(); + if (activeWindow) { + dialog.showMessageBox(activeWindow, options); + } else { + dialog.showMessageBox(options); + } + } - const iPaths = candidates.map(candidate => this.toIPath(candidate, true /* ignoreFileNotFound */, cli.goto)).filter(path => !!path); - if (iPaths.length > 0) { - return iPaths; + return path; + }); + + // get rid of nulls + pathsToOpen = arrays.coalesce(pathsToOpen); + + return pathsToOpen; + } + + private doExtractPathsFromCLI(cli: ParsedArgs): IPath[] { + const pathsToOpen = cli._.map(candidate => this.parsePath(candidate, true /* ignoreFileNotFound */, cli.goto)).filter(path => !!path); + if (pathsToOpen.length > 0) { + return pathsToOpen; } // No path provided, return empty to open empty return [Object.create(null)]; } - private doExtractPathsFromLastSession(): IPath[] { - const candidates: string[] = []; + private doGetWindowsFromLastSession(): IWindowToOpen[] { + const restoreWindows = this.getRestoreWindowsSetting(); + const lastActiveWindow = this.windowsState.lastActiveWindow; - let reopenFolders: string; - if (this.lifecycleService.wasRestarted) { - reopenFolders = ReopenFoldersSetting.ALL; // always reopen all folders when an update was applied - } else { - const windowConfig = this.configurationService.getConfiguration('window'); - reopenFolders = (windowConfig && windowConfig.reopenFolders) || ReopenFoldersSetting.ONE; - } + switch (restoreWindows) { - const lastActiveFolder = this.windowsState.lastActiveWindow && this.windowsState.lastActiveWindow.workspacePath; + // none: we always open an empty window + case 'none': + return [Object.create(null)]; - // Restore all - if (reopenFolders === ReopenFoldersSetting.ALL) { - const lastOpenedFolders = this.windowsState.openedFolders.map(o => o.workspacePath); + // one: restore last opened folder or empty window + case 'one': + if (lastActiveWindow) { - // If we have a last active folder, move it to the end - if (lastActiveFolder) { - lastOpenedFolders.splice(lastOpenedFolders.indexOf(lastActiveFolder), 1); - lastOpenedFolders.push(lastActiveFolder); - } + // return folder path if it is valid + const folder = lastActiveWindow.workspacePath; + if (folder) { + const validatedFolderPath = this.parsePath(folder); + if (validatedFolderPath) { + return [validatedFolderPath]; + } + } - candidates.push(...lastOpenedFolders); - } + // otherwise use backup path to restore empty windows + else if (lastActiveWindow.backupPath) { + return [{ backupPath: lastActiveWindow.backupPath }]; + } + } + break; + + // all: restore all windows + // folders: restore last opened folders only + case 'all': + case 'folders': + + // Windows with Folders + const lastOpenedFolders = this.windowsState.openedWindows.filter(w => !!w.workspacePath).map(o => o.workspacePath); + const lastActiveFolder = lastActiveWindow && lastActiveWindow.workspacePath; + if (lastActiveFolder) { + lastOpenedFolders.push(lastActiveFolder); + } - // Restore last active - else if (lastActiveFolder && (reopenFolders === ReopenFoldersSetting.ONE || reopenFolders !== ReopenFoldersSetting.NONE)) { - candidates.push(lastActiveFolder); - } + const windowsToOpen = lastOpenedFolders.map(candidate => this.parsePath(candidate)).filter(path => !!path); - const iPaths = candidates.map(candidate => this.toIPath(candidate)).filter(path => !!path); - if (iPaths.length > 0) { - return iPaths; + // Windows that were Empty + if (restoreWindows === 'all') { + const lastOpenedEmpty = this.windowsState.openedWindows.filter(w => !w.workspacePath && w.backupPath).map(w => w.backupPath); + const lastActiveEmpty = lastActiveWindow && !lastActiveWindow.workspacePath && lastActiveWindow.backupPath; + if (lastActiveEmpty) { + lastOpenedEmpty.push(lastActiveEmpty); + } + + windowsToOpen.push(...lastOpenedEmpty.map(backupPath => ({ backupPath }))); + } + + if (windowsToOpen.length > 0) { + return windowsToOpen; + } + + break; } - // No path provided, return empty to open empty + // Always fallback to empty window return [Object.create(null)]; } - private toIPath(anyPath: string, ignoreFileNotFound?: boolean, gotoLineMode?: boolean): IPath { + private getRestoreWindowsSetting(): RestoreWindowsSetting { + let restoreWindows: RestoreWindowsSetting; + if (this.lifecycleService.wasRestarted) { + restoreWindows = 'all'; // always reopen all windows when an update was applied + } else { + const windowConfig = this.configurationService.getConfiguration('window'); + restoreWindows = (windowConfig && windowConfig.restoreWindows) as RestoreWindowsSetting; + + if (windowConfig && windowConfig.restoreWindows === 'one' /* default */ && windowConfig.reopenFolders) { + restoreWindows = windowConfig.reopenFolders; // TODO@Ben migration + } + + if (['all', 'folders', 'one', 'none'].indexOf(restoreWindows) === -1) { + restoreWindows = 'one'; + } + } + + return restoreWindows; + } + + private parsePath(anyPath: string, ignoreFileNotFound?: boolean, gotoLineMode?: boolean): IWindowToOpen { if (!anyPath) { return null; } @@ -632,6 +722,14 @@ export class WindowsManager implements IWindowsMainService { configuration.filesToDiff = options.filesToDiff; configuration.nodeCachedDataDir = this.environmentService.nodeCachedDataDir; + // if we know the backup folder upfront (for empty workspaces to restore), we can set it + // directly here which helps for restoring UI state associated with that window. + // For all other cases we first call into registerWindowForBackupsSync() to set it before + // loading the window. + if (options.emptyWorkspaceBackupFolder) { + configuration.backupPath = path.join(this.environmentService.backupHome, options.emptyWorkspaceBackupFolder); + } + let codeWindow: CodeWindow; if (!options.forceNewWindow) { @@ -728,7 +826,15 @@ export class WindowsManager implements IWindowsMainService { // Known Folder - load from stored settings if any if (configuration.workspacePath) { - const stateForWorkspace = this.windowsState.openedFolders.filter(o => isEqual(o.workspacePath, configuration.workspacePath, !isLinux /* ignorecase */)).map(o => o.uiState); + const stateForWorkspace = this.windowsState.openedWindows.filter(o => isEqual(o.workspacePath, configuration.workspacePath, !isLinux /* ignorecase */)).map(o => o.uiState); + if (stateForWorkspace.length) { + return stateForWorkspace[0]; + } + } + + // Empty workspace with backups + else if (configuration.backupPath) { + const stateForWorkspace = this.windowsState.openedWindows.filter(o => o.backupPath === configuration.backupPath).map(o => o.uiState); if (stateForWorkspace.length) { return stateForWorkspace[0]; } @@ -845,9 +951,7 @@ export class WindowsManager implements IWindowsMainService { } // No window - open new empty one - const res = this.open({ context, cli, forceEmpty: true }); - - return res && res[0]; + return this.open({ context, cli, forceEmpty: true })[0]; } public getLastActiveWindow(): CodeWindow { diff --git a/src/vs/platform/storage/common/storageService.ts b/src/vs/platform/storage/common/storageService.ts index 1fca3d8262b..82952ee5dbd 100644 --- a/src/vs/platform/storage/common/storageService.ts +++ b/src/vs/platform/storage/common/storageService.ts @@ -8,7 +8,6 @@ import types = require('vs/base/common/types'); import errors = require('vs/base/common/errors'); import strings = require('vs/base/common/strings'); import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage'; -import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import URI from "vs/base/common/uri"; // Browser localStorage interface @@ -21,6 +20,12 @@ export interface IStorage { removeItem(key: string): void; } +export interface IWorkspaceStorageIdentifier { + resource: URI; + uid?: number; + name?: string; +} + export class StorageService implements IStorageService { public _serviceBrand: any; @@ -39,18 +44,18 @@ export class StorageService implements IStorageService { constructor( globalStorage: IStorage, workspaceStorage: IStorage, - @IWorkspaceContextService contextService: IWorkspaceContextService + workspaceIdentifier?: IWorkspaceStorageIdentifier ) { this.globalStorage = globalStorage; this.workspaceStorage = workspaceStorage || globalStorage; // Calculate workspace storage key - const workspace = contextService.getWorkspace(); - this.workspaceKey = this.getWorkspaceKey(workspace ? workspace.resource : void 0); + this.workspaceKey = this.getWorkspaceKey(workspaceIdentifier ? workspaceIdentifier.resource : void 0); // Make sure to delete all workspace storage if the workspace has been recreated meanwhile - if (workspace && types.isNumber(workspace.uid)) { - this.cleanupWorkspaceScope(workspace.uid, workspace.name); + // which is only possible if a UID property is provided that we can check on + if (workspaceIdentifier && types.isNumber(workspaceIdentifier.uid)) { + this.cleanupWorkspaceScope(workspaceIdentifier.uid, workspaceIdentifier.name); } } @@ -59,15 +64,16 @@ export class StorageService implements IStorageService { return StorageService.NO_WORKSPACE_IDENTIFIER; } - const workspaceIdStr = workspaceId.toString(); + let workspaceIdStr = workspaceId.toString(); - const root = 'file:///'; - const index = workspaceIdStr.indexOf(root); - if (index === 0) { - return `${strings.rtrim(workspaceIdStr.substr(root.length), '/')}/`; + // Special case file:// URIs: strip protocol from key to produce shorter key + const fileProtocol = 'file:///'; + if (workspaceIdStr.indexOf(fileProtocol) === 0) { + workspaceIdStr = workspaceIdStr.substr(fileProtocol.length); } - return workspaceIdStr; + // Always end with "/" + return `${strings.rtrim(workspaceIdStr, '/')}/`; } private cleanupWorkspaceScope(workspaceId: number, workspaceName: string): void { diff --git a/src/vs/platform/storage/test/storageService.test.ts b/src/vs/platform/storage/test/storageService.test.ts index 2765ef994c1..ed156bfabc7 100644 --- a/src/vs/platform/storage/test/storageService.test.ts +++ b/src/vs/platform/storage/test/storageService.test.ts @@ -24,7 +24,7 @@ suite('Workbench StorageSevice', () => { }); test('Swap Data with undefined default value', () => { - let s = new StorageService(new InMemoryLocalStorage(), null, contextService); + let s = new StorageService(new InMemoryLocalStorage(), null, contextService.getWorkspace()); s.swap('Monaco.IDE.Core.Storage.Test.swap', 'foobar', 'barfoo'); assert.strictEqual('foobar', s.get('Monaco.IDE.Core.Storage.Test.swap')); @@ -35,7 +35,7 @@ suite('Workbench StorageSevice', () => { }); test('Remove Data', () => { - let s = new StorageService(new InMemoryLocalStorage(), null, contextService); + let s = new StorageService(new InMemoryLocalStorage(), null, contextService.getWorkspace()); s.store('Monaco.IDE.Core.Storage.Test.remove', 'foobar'); assert.strictEqual('foobar', s.get('Monaco.IDE.Core.Storage.Test.remove')); @@ -44,7 +44,7 @@ suite('Workbench StorageSevice', () => { }); test('Get Data, Integer, Boolean', () => { - let s = new StorageService(new InMemoryLocalStorage(), null, contextService); + let s = new StorageService(new InMemoryLocalStorage(), null, contextService.getWorkspace()); assert.strictEqual(s.get('Monaco.IDE.Core.Storage.Test.get', StorageScope.GLOBAL, 'foobar'), 'foobar'); assert.strictEqual(s.get('Monaco.IDE.Core.Storage.Test.get', StorageScope.GLOBAL, ''), ''); @@ -78,14 +78,14 @@ suite('Workbench StorageSevice', () => { test('StorageSevice cleans up when workspace changes', () => { let storageImpl = new InMemoryLocalStorage(); - let s = new StorageService(storageImpl, null, contextService); + let s = new StorageService(storageImpl, null, contextService.getWorkspace()); s.store('key1', 'foobar'); s.store('key2', 'something'); s.store('wkey1', 'foo', StorageScope.WORKSPACE); s.store('wkey2', 'foo2', StorageScope.WORKSPACE); - s = new StorageService(storageImpl, null, contextService); + s = new StorageService(storageImpl, null, contextService.getWorkspace()); assert.strictEqual(s.get('key1', StorageScope.GLOBAL), 'foobar'); assert.strictEqual(s.get('key1', StorageScope.WORKSPACE, null), null); @@ -97,7 +97,7 @@ suite('Workbench StorageSevice', () => { let ws: any = clone(TestWorkspace); ws.uid = new Date().getTime() + 100; instantiationService.stub(IWorkspaceContextService, 'getWorkspace', ws); - s = new StorageService(storageImpl, null, contextService); + s = new StorageService(storageImpl, null, contextService.getWorkspace()); assert.strictEqual(s.get('key1', StorageScope.GLOBAL), 'foobar'); assert.strictEqual(s.get('key1', StorageScope.WORKSPACE, null), null); diff --git a/src/vs/platform/telemetry/common/telemetryUtils.ts b/src/vs/platform/telemetry/common/telemetryUtils.ts index 0637bd49c33..516a0320f0a 100644 --- a/src/vs/platform/telemetry/common/telemetryUtils.ts +++ b/src/vs/platform/telemetry/common/telemetryUtils.ts @@ -265,6 +265,7 @@ const configurationValueWhitelist = [ 'window.openFilesInNewWindow', 'javascript.validate.enable', 'window.reopenFolders', + 'window.restoreWindows', 'extensions.autoUpdate', 'files.eol', 'explorer.openEditors.visible', diff --git a/src/vs/platform/telemetry/test/electron-browser/commonProperties.test.ts b/src/vs/platform/telemetry/test/electron-browser/commonProperties.test.ts index 54bd6cb5618..61a93db8637 100644 --- a/src/vs/platform/telemetry/test/electron-browser/commonProperties.test.ts +++ b/src/vs/platform/telemetry/test/electron-browser/commonProperties.test.ts @@ -22,7 +22,7 @@ suite('Telemetry - common properties', function () { let instantiationService = new TestInstantiationService(); let contextService = instantiationService.stub(IWorkspaceContextService, WorkspaceContextService); instantiationService.stub(IWorkspaceContextService, 'getWorkspace', TestWorkspace); - storageService = new StorageService(new InMemoryLocalStorage(), null, contextService); + storageService = new StorageService(new InMemoryLocalStorage(), null, contextService.getWorkspace()); }); test('default', function () { diff --git a/src/vs/platform/windows/common/windows.ts b/src/vs/platform/windows/common/windows.ts index 4cb6db0cac3..9c5a90e9c0c 100644 --- a/src/vs/platform/windows/common/windows.ts +++ b/src/vs/platform/windows/common/windows.ts @@ -104,7 +104,8 @@ export interface IWindowConfiguration { export interface IWindowSettings { openFilesInNewWindow: 'on' | 'off' | 'default'; openFoldersInNewWindow: 'on' | 'off' | 'default'; - reopenFolders: 'all' | 'one' | 'none'; + restoreWindows: 'all' | 'folders' | 'one' | 'none'; + reopenFolders: 'all' | 'one' | 'none'; // TODO@Ben deprecated restoreFullscreen: boolean; zoomLevel: number; titleBarStyle: 'native' | 'custom'; @@ -161,9 +162,6 @@ export enum ReadyState { export interface IPath { - // the workspace spath for a Code instance which can be null - workspacePath?: string; - // the file path to open within a Code instance filePath?: string; @@ -172,9 +170,6 @@ export interface IPath { // the column number in the file path to open columnNumber?: number; - - // indicator to create the file path in the Code instance - createFilePath?: boolean; } export interface IOpenFileRequest { diff --git a/src/vs/workbench/browser/parts/compositePart.ts b/src/vs/workbench/browser/parts/compositePart.ts index dea7bce19b3..8800ba124fc 100644 --- a/src/vs/workbench/browser/parts/compositePart.ts +++ b/src/vs/workbench/browser/parts/compositePart.ts @@ -80,6 +80,7 @@ export abstract class CompositePart extends Part { themeService: IThemeService, private registry: CompositeRegistry, private activeCompositeSettingsKey: string, + private defaultCompositeId: string, private nameForTelemetry: string, private compositeCSSClass: string, private actionContributionScope: string, @@ -96,7 +97,7 @@ export abstract class CompositePart extends Part { this.activeComposite = null; this.instantiatedComposites = []; this.compositeLoaderPromises = {}; - this.lastActiveCompositeId = storageService.get(activeCompositeSettingsKey, StorageScope.WORKSPACE); + this.lastActiveCompositeId = storageService.get(activeCompositeSettingsKey, StorageScope.WORKSPACE, this.defaultCompositeId); } protected openComposite(id: string, focus?: boolean): TPromise { @@ -221,7 +222,12 @@ export abstract class CompositePart extends Part { this.activeComposite = composite; // Store in preferences - this.storageService.store(this.activeCompositeSettingsKey, this.activeComposite.getId(), StorageScope.WORKSPACE); + const id = this.activeComposite.getId(); + if (id !== this.defaultCompositeId) { + this.storageService.store(this.activeCompositeSettingsKey, id, StorageScope.WORKSPACE); + } else { + this.storageService.remove(this.activeCompositeSettingsKey, StorageScope.WORKSPACE); + } // Remember this.lastActiveCompositeId = this.activeComposite.getId(); diff --git a/src/vs/workbench/browser/parts/editor/editorPart.ts b/src/vs/workbench/browser/parts/editor/editorPart.ts index c1a20ee5dea..f0db5dc5baf 100644 --- a/src/vs/workbench/browser/parts/editor/editorPart.ts +++ b/src/vs/workbench/browser/parts/editor/editorPart.ts @@ -1250,7 +1250,11 @@ export class EditorPart extends Part implements IEditorPart, IEditorGroupService // Persist UI State const editorState: IEditorPartUIState = { ratio: this.editorGroupsControl.getRatio(), groupOrientation: this.editorGroupsControl.getGroupOrientation() }; - this.memento[EditorPart.EDITOR_PART_UI_STATE_STORAGE_KEY] = editorState; + if (editorState.ratio.length || editorState.groupOrientation !== 'vertical') { + this.memento[EditorPart.EDITOR_PART_UI_STATE_STORAGE_KEY] = editorState; + } else { + delete this.memento[EditorPart.EDITOR_PART_UI_STATE_STORAGE_KEY]; + } // Unload all Instantiated Editors for (let i = 0; i < this.instantiatedEditors.length; i++) { diff --git a/src/vs/workbench/browser/parts/panel/panelPart.ts b/src/vs/workbench/browser/parts/panel/panelPart.ts index f3334acfe78..a5a9f981b42 100644 --- a/src/vs/workbench/browser/parts/panel/panelPart.ts +++ b/src/vs/workbench/browser/parts/panel/panelPart.ts @@ -61,6 +61,7 @@ export class PanelPart extends CompositePart implements IPanelService { themeService, Registry.as(PanelExtensions.Panels), PanelPart.activePanelSettingsKey, + Registry.as(PanelExtensions.Panels).getDefaultPanelId(), 'panel', 'panel', Scope.PANEL, diff --git a/src/vs/workbench/browser/parts/sidebar/sidebarPart.ts b/src/vs/workbench/browser/parts/sidebar/sidebarPart.ts index 0bdf5e478a0..2e68646b26e 100644 --- a/src/vs/workbench/browser/parts/sidebar/sidebarPart.ts +++ b/src/vs/workbench/browser/parts/sidebar/sidebarPart.ts @@ -58,6 +58,7 @@ export class SidebarPart extends CompositePart { themeService, Registry.as(ViewletExtensions.Viewlets), SidebarPart.activeViewletSettingsKey, + Registry.as(ViewletExtensions.Viewlets).getDefaultViewletId(), 'sideBar', 'viewlet', Scope.VIEWLET, diff --git a/src/vs/workbench/common/editor/editorStacksModel.ts b/src/vs/workbench/common/editor/editorStacksModel.ts index c61412c99f8..c6bd0d5602b 100644 --- a/src/vs/workbench/common/editor/editorStacksModel.ts +++ b/src/vs/workbench/common/editor/editorStacksModel.ts @@ -1064,7 +1064,11 @@ export class EditorStacksModel implements IEditorStacksModel { private save(): void { const serialized = this.serialize(); - this.storageService.store(EditorStacksModel.STORAGE_KEY, JSON.stringify(serialized), StorageScope.WORKSPACE); + if (serialized.groups.length) { + this.storageService.store(EditorStacksModel.STORAGE_KEY, JSON.stringify(serialized), StorageScope.WORKSPACE); + } else { + this.storageService.remove(EditorStacksModel.STORAGE_KEY, StorageScope.WORKSPACE); + } } private serialize(): ISerializedEditorStacksModel { diff --git a/src/vs/workbench/electron-browser/main.contribution.ts b/src/vs/workbench/electron-browser/main.contribution.ts index 380b33dc7e8..1f362b099db 100644 --- a/src/vs/workbench/electron-browser/main.contribution.ts +++ b/src/vs/workbench/electron-browser/main.contribution.ts @@ -221,16 +221,17 @@ Note that there can still be cases where this setting is ignored (e.g. when usin Note that there can still be cases where this setting is ignored (e.g. when using the -new-window or -reuse-window command line option).` ) }, - 'window.reopenFolders': { + 'window.restoreWindows': { 'type': 'string', - 'enum': ['none', 'one', 'all'], + 'enum': ['all', 'folders', 'one', 'none'], 'enumDescriptions': [ - nls.localize({ comment: ['This is the description for a setting. Values surrounded by single quotes are not to be translated.'], key: 'window.reopenFolders.none' }, "Never reopen a folder."), - nls.localize({ comment: ['This is the description for a setting. Values surrounded by single quotes are not to be translated.'], key: 'window.reopenFolders.one' }, "Reopen the last active folder."), - nls.localize({ comment: ['This is the description for a setting. Values surrounded by single quotes are not to be translated.'], key: 'window.reopenFolders.all' }, "Reopen all folders of the last session."), + nls.localize({ comment: ['This is the description for a setting. Values surrounded by single quotes are not to be translated.'], key: 'window.reopenFolders.all' }, "Reopen all windows."), + nls.localize({ comment: ['This is the description for a setting. Values surrounded by single quotes are not to be translated.'], key: 'window.reopenFolders.folders' }, "Reopen all folders. Empty windows will not be restored."), + nls.localize({ comment: ['This is the description for a setting. Values surrounded by single quotes are not to be translated.'], key: 'window.reopenFolders.one' }, "Reopen the last active window."), + nls.localize({ comment: ['This is the description for a setting. Values surrounded by single quotes are not to be translated.'], key: 'window.reopenFolders.none' }, "Never reopen a window. Always start with an empty one.") ], 'default': 'one', - 'description': nls.localize('reopenFolders', "Controls how folders are being reopened after a restart. Select 'none' to never reopen a folder, 'one' to reopen the last folder you worked on or 'all' to reopen all folders of your last session.") + 'description': nls.localize('restoreWindows', "Controls how windows are being reopened after a restart. Select 'none' to always start with an empty window, 'one' to reopen the last window you worked on, 'folders' to reopen all folders you had opened or 'all' to reopen all windows of your last session.") }, 'window.restoreFullscreen': { 'type': 'boolean', diff --git a/src/vs/workbench/electron-browser/shell.ts b/src/vs/workbench/electron-browser/shell.ts index cce0d8cf300..00becc599ff 100644 --- a/src/vs/workbench/electron-browser/shell.ts +++ b/src/vs/workbench/electron-browser/shell.ts @@ -89,6 +89,8 @@ import { IURLService } from 'vs/platform/url/common/url'; import { ExtensionHostProcessWorker } from 'vs/workbench/electron-browser/extensionHost'; import { ITimerService } from 'vs/workbench/services/timer/common/timerService'; import { remote, ipcRenderer as ipc } from 'electron'; +import URI from "vs/base/common/uri"; +import { basename } from "path"; import { ITextMateService } from 'vs/editor/node/textMate/textMateService'; import { MainProcessTextMateSyntax } from 'vs/editor/electron-browser/textMate/TMSyntax'; import { BareFontInfo } from 'vs/editor/common/config/fontInfo'; @@ -272,8 +274,19 @@ export class WorkbenchShell { .done(client => client.registerChannel('choice', instantiationService.createInstance(ChoiceChannel))); // Storage Sevice - const disableWorkspaceStorage = this.environmentService.extensionTestsPath || (!this.contextService.hasWorkspace() && !this.environmentService.isExtensionDevelopment); // without workspace or in any extension test, we use inMemory storage unless we develop an extension where we want to preserve state - this.storageService = instantiationService.createInstance(StorageService, window.localStorage, disableWorkspaceStorage ? inMemoryLocalStorageInstance : window.localStorage); + let workspaceIdentifier = this.contextService.getWorkspace(); + if (!workspaceIdentifier && !!this.configuration.backupPath) { + // if we do not have a workspace open, we need to find another identifier for the window to store + // workspace UI state. if we have a backup path in the configuration we can use that because this + // will be a unique identifier per window that is stable between restarts as long as there are + // dirty files in the workspace. + // We use basename() to produce a short identifier, we do not need the full path. We use a custom + // scheme so that we can later distinguish these identifiers from the workspace one. + workspaceIdentifier = { resource: URI.from({ path: basename(this.configuration.backupPath), scheme: 'empty' }) }; + } + const disableStorage = !!this.environmentService.extensionTestsPath; // never keep any state when running extension tests! + const storage = disableStorage ? inMemoryLocalStorageInstance : window.localStorage; + this.storageService = new StorageService(storage, storage, workspaceIdentifier); serviceCollection.set(IStorageService, this.storageService); // Warm up font cache information before building up too many dom elements diff --git a/src/vs/workbench/electron-browser/workbench.ts b/src/vs/workbench/electron-browser/workbench.ts index a6dd9426102..d5b3f3bd621 100644 --- a/src/vs/workbench/electron-browser/workbench.ts +++ b/src/vs/workbench/electron-browser/workbench.ts @@ -751,15 +751,21 @@ export class Workbench implements IPartService { // If sidebar becomes visible, show last active Viewlet or default viewlet else if (!hidden && !this.sidebarPart.getActiveViewlet()) { - const viewletToOpen = this.sidebarPart.getLastActiveViewletId() || this.viewletService.getDefaultViewletId(); + const viewletToOpen = this.sidebarPart.getLastActiveViewletId(); if (viewletToOpen) { promise = this.sidebarPart.openViewlet(viewletToOpen, true); } } return promise.then(() => { + // Remember in settings - this.storageService.store(Workbench.sidebarHiddenSettingKey, hidden ? 'true' : 'false', StorageScope.WORKSPACE); + const defaultHidden = !this.contextService.hasWorkspace(); + if (hidden !== defaultHidden) { + this.storageService.store(Workbench.sidebarHiddenSettingKey, hidden ? 'true' : 'false', StorageScope.WORKSPACE); + } else { + this.storageService.remove(Workbench.sidebarHiddenSettingKey, StorageScope.WORKSPACE); + } // Layout if (!skipLayout) { @@ -778,8 +784,8 @@ export class Workbench implements IPartService { this.workbench.removeClass('nopanel'); } - let promise = TPromise.as(null); // If panel part becomes hidden, also hide the current active panel if any + let promise = TPromise.as(null); if (hidden && this.panelPart.getActivePanel()) { promise = this.panelPart.hideActivePanel().then(() => { // Pass Focus to Editor if Panel part is now hidden @@ -792,16 +798,20 @@ export class Workbench implements IPartService { // If panel part becomes visible, show last active panel or default panel else if (!hidden && !this.panelPart.getActivePanel()) { - const registry = Registry.as(PanelExtensions.Panels); - const panelToOpen = this.panelPart.getLastActivePanelId() || registry.getDefaultPanelId(); + const panelToOpen = this.panelPart.getLastActivePanelId(); if (panelToOpen) { promise = this.panelPart.openPanel(panelToOpen, true); } } return promise.then(() => { + // Remember in settings - this.storageService.store(Workbench.panelHiddenSettingKey, hidden ? 'true' : 'false', StorageScope.WORKSPACE); + if (!hidden) { + this.storageService.store(Workbench.panelHiddenSettingKey, 'false', StorageScope.WORKSPACE); + } else { + this.storageService.remove(Workbench.panelHiddenSettingKey, StorageScope.WORKSPACE); + } // Layout if (!skipLayout) { @@ -871,9 +881,14 @@ export class Workbench implements IPartService { this.storageService.store(Workbench.sidebarRestoreSettingKey, 'true', StorageScope.WORKSPACE); } - const zenConfig = this.configurationService.getConfiguration('zenMode'); // Preserve zen mode only on reload. Real quit gets out of zen mode so novice users do not get stuck in zen mode. - this.storageService.store(Workbench.zenModeActiveSettingKey, (zenConfig.restore || reason === ShutdownReason.RELOAD) && this.zenMode.active, StorageScope.WORKSPACE); + const zenConfig = this.configurationService.getConfiguration('zenMode'); + const zenModeActive = (zenConfig.restore || reason === ShutdownReason.RELOAD) && this.zenMode.active; + if (zenModeActive) { + this.storageService.store(Workbench.zenModeActiveSettingKey, true, StorageScope.WORKSPACE); + } else { + this.storageService.remove(Workbench.zenModeActiveSettingKey, StorageScope.WORKSPACE); + } // Pass shutdown on to each participant this.toShutdown.forEach(s => s.shutdown()); diff --git a/src/vs/workbench/parts/backup/common/backupModelTracker.ts b/src/vs/workbench/parts/backup/common/backupModelTracker.ts index fa7bb0e5356..71f7fd5d0dd 100644 --- a/src/vs/workbench/parts/backup/common/backupModelTracker.ts +++ b/src/vs/workbench/parts/backup/common/backupModelTracker.ts @@ -11,7 +11,6 @@ import { IBackupFileService } from 'vs/workbench/services/backup/common/backup'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { ITextFileService, TextFileModelChangeEvent, StateChange } from 'vs/workbench/services/textfile/common/textfiles'; import { IUntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; -import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { IWorkbenchContribution } from 'vs/workbench/common/contributions'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { IFilesConfiguration, AutoSaveConfiguration, CONTENT_CHANGE_EVENT_BUFFER_DELAY } from 'vs/platform/files/common/files'; @@ -29,7 +28,6 @@ export class BackupModelTracker implements IWorkbenchContribution { @IBackupFileService private backupFileService: IBackupFileService, @ITextFileService private textFileService: ITextFileService, @IUntitledEditorService private untitledEditorService: IUntitledEditorService, - @IEnvironmentService private environmentService: IEnvironmentService, @IConfigurationService private configurationService: IConfigurationService ) { this.toDispose = []; @@ -38,7 +36,7 @@ export class BackupModelTracker implements IWorkbenchContribution { } private registerListeners() { - if (this.environmentService.isExtensionDevelopment) { + if (!this.backupFileService.backupEnabled) { return; } diff --git a/src/vs/workbench/parts/backup/common/backupRestorer.ts b/src/vs/workbench/parts/backup/common/backupRestorer.ts index 3b64fdda7ad..a20f365912d 100644 --- a/src/vs/workbench/parts/backup/common/backupRestorer.ts +++ b/src/vs/workbench/parts/backup/common/backupRestorer.ts @@ -8,7 +8,6 @@ import URI from 'vs/base/common/uri'; import { TPromise } from 'vs/base/common/winjs.base'; import { IUntitledEditorService, UNTITLED_SCHEMA } from 'vs/workbench/services/untitled/common/untitledEditorService'; -import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { IWorkbenchContribution } from 'vs/workbench/common/contributions'; import { IPartService } from 'vs/workbench/services/part/common/partService'; import errors = require('vs/base/common/errors'); @@ -25,7 +24,6 @@ export class BackupRestorer implements IWorkbenchContribution { constructor( @IUntitledEditorService private untitledEditorService: IUntitledEditorService, - @IEnvironmentService private environmentService: IEnvironmentService, @IPartService private partService: IPartService, @IWorkbenchEditorService private editorService: IWorkbenchEditorService, @IBackupFileService private backupFileService: IBackupFileService, @@ -36,7 +34,7 @@ export class BackupRestorer implements IWorkbenchContribution { } private restoreBackups(): void { - if (!this.environmentService.isExtensionDevelopment) { + if (this.backupFileService.backupEnabled) { this.partService.joinCreation().then(() => { this.doRestoreBackups().done(null, errors.onUnexpectedError); }); @@ -55,7 +53,8 @@ export class BackupRestorer implements IWorkbenchContribution { if (unresolved.length > 0) { return this.doOpenEditors(unresolved).then(() => this.doResolveOpenedBackups(unresolved)); } - return undefined; + + return void 0; }); }); } @@ -102,7 +101,6 @@ export class BackupRestorer implements IWorkbenchContribution { return { resource, options }; } - public getId(): string { return 'vs.backup.backupRestorer'; } diff --git a/src/vs/workbench/parts/debug/electron-browser/debugService.ts b/src/vs/workbench/parts/debug/electron-browser/debugService.ts index 24fa55d339a..aa3fd1b98f8 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugService.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugService.ts @@ -1128,12 +1128,41 @@ export class DebugService implements debug.IDebugService { } private store(): void { - this.storageService.store(DEBUG_BREAKPOINTS_KEY, JSON.stringify(this.model.getBreakpoints()), StorageScope.WORKSPACE); - this.storageService.store(DEBUG_BREAKPOINTS_ACTIVATED_KEY, this.model.areBreakpointsActivated() ? 'true' : 'false', StorageScope.WORKSPACE); - this.storageService.store(DEBUG_FUNCTION_BREAKPOINTS_KEY, JSON.stringify(this.model.getFunctionBreakpoints()), StorageScope.WORKSPACE); - this.storageService.store(DEBUG_EXCEPTION_BREAKPOINTS_KEY, JSON.stringify(this.model.getExceptionBreakpoints()), StorageScope.WORKSPACE); + const breakpoints = this.model.getBreakpoints(); + if (breakpoints.length) { + this.storageService.store(DEBUG_BREAKPOINTS_KEY, JSON.stringify(breakpoints), StorageScope.WORKSPACE); + } else { + this.storageService.remove(DEBUG_BREAKPOINTS_KEY, StorageScope.WORKSPACE); + } + + if (!this.model.areBreakpointsActivated()) { + this.storageService.store(DEBUG_BREAKPOINTS_ACTIVATED_KEY, 'false', StorageScope.WORKSPACE); + } else { + this.storageService.remove(DEBUG_BREAKPOINTS_ACTIVATED_KEY, StorageScope.WORKSPACE); + } + + const functionBreakpoints = this.model.getFunctionBreakpoints(); + if (functionBreakpoints.length) { + this.storageService.store(DEBUG_FUNCTION_BREAKPOINTS_KEY, JSON.stringify(functionBreakpoints), StorageScope.WORKSPACE); + } else { + this.storageService.remove(DEBUG_FUNCTION_BREAKPOINTS_KEY, StorageScope.WORKSPACE); + } + + const exceptionBreakpoints = this.model.getExceptionBreakpoints(); + if (exceptionBreakpoints.length) { + this.storageService.store(DEBUG_EXCEPTION_BREAKPOINTS_KEY, JSON.stringify(exceptionBreakpoints), StorageScope.WORKSPACE); + } else { + this.storageService.remove(DEBUG_EXCEPTION_BREAKPOINTS_KEY, StorageScope.WORKSPACE); + } + this.storageService.store(DEBUG_SELECTED_CONFIG_NAME_KEY, this.viewModel.selectedConfigurationName, StorageScope.WORKSPACE); - this.storageService.store(DEBUG_WATCH_EXPRESSIONS_KEY, JSON.stringify(this.model.getWatchExpressions().map(we => ({ name: we.name, id: we.getId() }))), StorageScope.WORKSPACE); + + const watchExpressions = this.model.getWatchExpressions(); + if (watchExpressions.length) { + this.storageService.store(DEBUG_WATCH_EXPRESSIONS_KEY, JSON.stringify(watchExpressions.map(we => ({ name: we.name, id: we.getId() }))), StorageScope.WORKSPACE); + } else { + this.storageService.remove(DEBUG_WATCH_EXPRESSIONS_KEY, StorageScope.WORKSPACE); + } } public dispose(): void { diff --git a/src/vs/workbench/parts/debug/electron-browser/repl.ts b/src/vs/workbench/parts/debug/electron-browser/repl.ts index 505ce6118de..5823a900518 100644 --- a/src/vs/workbench/parts/debug/electron-browser/repl.ts +++ b/src/vs/workbench/parts/debug/electron-browser/repl.ts @@ -278,7 +278,12 @@ export class Repl extends Panel implements IPrivateReplService { } public shutdown(): void { - this.storageService.store(HISTORY_STORAGE_KEY, JSON.stringify(Repl.HISTORY.save()), StorageScope.WORKSPACE); + const replHistory = Repl.HISTORY.save(); + if (replHistory.length) { + this.storageService.store(HISTORY_STORAGE_KEY, JSON.stringify(replHistory), StorageScope.WORKSPACE); + } else { + this.storageService.remove(HISTORY_STORAGE_KEY, StorageScope.WORKSPACE); + } } private getReplInputOptions(): IEditorOptions { diff --git a/src/vs/workbench/parts/files/browser/files.contribution.ts b/src/vs/workbench/parts/files/browser/files.contribution.ts index 3e19dc5ed9d..6d5cba5b615 100644 --- a/src/vs/workbench/parts/files/browser/files.contribution.ts +++ b/src/vs/workbench/parts/files/browser/files.contribution.ts @@ -271,7 +271,7 @@ configurationRegistry.registerConfiguration({ 'enumDescriptions': [ nls.localize('hotExit.off', 'Disable hot exit.'), nls.localize('hotExit.onExit', 'Hot exit will be triggered when the application is closed, that is when the last window is closed on Windows/Linux or when the workbench.action.quit command is triggered (command palette, keybinding, menu). All windows with backups will be restored upon next launch.'), - nls.localize('hotExit.onExitAndWindowClose', 'Hot exit will be triggered when the application is closed, that is when the last window is closed on Windows/Linux or when the workbench.action.quit command is triggered (command palette, keybinding, menu), and also for any window with a folder opened regardless of whether it\'s the last window. All windows without folders opened will be restored upon next launch. To restore folder windows as they were before shutdown set "window.reopenFolders" to "all".') + nls.localize('hotExit.onExitAndWindowClose', 'Hot exit will be triggered when the application is closed, that is when the last window is closed on Windows/Linux or when the workbench.action.quit command is triggered (command palette, keybinding, menu), and also for any window with a folder opened regardless of whether it\'s the last window. All windows without folders opened will be restored upon next launch. To restore folder windows as they were before shutdown set "window.restoreWindows" to "all".') ], 'description': nls.localize('hotExit', "Controls whether unsaved files are remembered between sessions, allowing the save prompt when exiting the editor to be skipped.", HotExitConfiguration.ON_EXIT, HotExitConfiguration.ON_EXIT_AND_WINDOW_CLOSE) }, diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index c9372420e06..d1df344969a 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -854,7 +854,16 @@ export class ExplorerView extends CollapsibleView { .filter((e: FileStat) => e.resource.toString() !== this.contextService.getWorkspace().resource.toString()) .map((e: FileStat) => e.resource.toString()); - this.settings[ExplorerView.MEMENTO_EXPANDED_FOLDER_RESOURCES] = expanded; + if (expanded.length) { + this.settings[ExplorerView.MEMENTO_EXPANDED_FOLDER_RESOURCES] = expanded; + } else { + delete this.settings[ExplorerView.MEMENTO_EXPANDED_FOLDER_RESOURCES]; + } + } + + // Clean up last focussed if not set + if (!this.settings[ExplorerView.MEMENTO_LAST_ACTIVE_FILE_RESOURCE]) { + delete this.settings[ExplorerView.MEMENTO_LAST_ACTIVE_FILE_RESOURCE]; } super.shutdown(); diff --git a/src/vs/workbench/parts/search/browser/searchViewlet.ts b/src/vs/workbench/parts/search/browser/searchViewlet.ts index f42a3d96708..c02312985bf 100644 --- a/src/vs/workbench/parts/search/browser/searchViewlet.ts +++ b/src/vs/workbench/parts/search/browser/searchViewlet.ts @@ -334,7 +334,13 @@ export class SearchViewlet extends Viewlet { private onReplaceToggled(): void { this.layout(this.size); - this.storageService.store(SearchViewlet.SHOW_REPLACE_STORAGE_KEY, this.searchAndReplaceWidget.isReplaceShown(), StorageScope.WORKSPACE); + + const isReplaceShown = this.searchAndReplaceWidget.isReplaceShown(); + if (!isReplaceShown) { + this.storageService.store(SearchViewlet.SHOW_REPLACE_STORAGE_KEY, false, StorageScope.WORKSPACE); + } else { + this.storageService.remove(SearchViewlet.SHOW_REPLACE_STORAGE_KEY); + } } private onSearchResultsChanged(event?: IChangeEvent): TPromise { diff --git a/src/vs/workbench/services/backup/common/backup.ts b/src/vs/workbench/services/backup/common/backup.ts index f725e450087..c43688b8b48 100644 --- a/src/vs/workbench/services/backup/common/backup.ts +++ b/src/vs/workbench/services/backup/common/backup.ts @@ -22,6 +22,11 @@ export const BACKUP_FILE_UPDATE_OPTIONS: IUpdateContentOptions = { encoding: 'ut export interface IBackupFileService { _serviceBrand: any; + /** + * If backups are enabled. + */ + backupEnabled: boolean; + /** * Finds out if there are any backups stored. */ diff --git a/src/vs/workbench/services/backup/node/backupFileService.ts b/src/vs/workbench/services/backup/node/backupFileService.ts index 223bddc599f..b7c27aeca10 100644 --- a/src/vs/workbench/services/backup/node/backupFileService.ts +++ b/src/vs/workbench/services/backup/node/backupFileService.ts @@ -109,7 +109,7 @@ export class BackupFileService implements IBackupFileService { this.ready = this.init(); } - private get backupEnabled(): boolean { + public get backupEnabled(): boolean { return !!this.backupWorkspacePath; // Hot exit requires a backup path } diff --git a/src/vs/workbench/test/browser/part.test.ts b/src/vs/workbench/test/browser/part.test.ts index 0d4d0f1418f..37277b67a78 100644 --- a/src/vs/workbench/test/browser/part.test.ts +++ b/src/vs/workbench/test/browser/part.test.ts @@ -93,7 +93,7 @@ suite('Workbench Part', () => { fixture.id = fixtureId; document.body.appendChild(fixture); context = new WorkspaceContextService(new TestConfigurationService(), TestWorkspace); - storage = new StorageService(new InMemoryLocalStorage(), null, context); + storage = new StorageService(new InMemoryLocalStorage(), null, context.getWorkspace()); }); teardown(() => { diff --git a/src/vs/workbench/test/common/memento.test.ts b/src/vs/workbench/test/common/memento.test.ts index c8d988af459..c21ce5f9036 100644 --- a/src/vs/workbench/test/common/memento.test.ts +++ b/src/vs/workbench/test/common/memento.test.ts @@ -19,7 +19,7 @@ suite('Workbench Memento', () => { setup(() => { context = new WorkspaceContextService(new TestConfigurationService(), TestWorkspace); - storage = new StorageService(new InMemoryLocalStorage(), null, context); + storage = new StorageService(new InMemoryLocalStorage(), null, context.getWorkspace()); }); test('Loading and Saving Memento with Scopes', () => { diff --git a/src/vs/workbench/test/workbenchTestServices.ts b/src/vs/workbench/test/workbenchTestServices.ts index 0928c71276d..14736493081 100644 --- a/src/vs/workbench/test/workbenchTestServices.ts +++ b/src/vs/workbench/test/workbenchTestServices.ts @@ -353,7 +353,7 @@ export class TestStorageService extends EventEmitter implements IStorageService super(); let context = new TestContextService(); - this.storage = new StorageService(new InMemoryLocalStorage(), null, context); + this.storage = new StorageService(new InMemoryLocalStorage(), null, context.getWorkspace()); } store(key: string, value: any, scope: StorageScope = StorageScope.GLOBAL): void { @@ -728,6 +728,8 @@ export class TestFileService implements IFileService { export class TestBackupFileService implements IBackupFileService { public _serviceBrand: any; + public backupEnabled: boolean; + public hasBackups(): TPromise { return TPromise.as(false); } -- GitLab From 87e691c9cc9fec32e993e80d942240332bd8ffb7 Mon Sep 17 00:00:00 2001 From: Hasan Ali Date: Tue, 13 Jun 2017 07:26:28 +0100 Subject: [PATCH 0750/1347] Add options to theme notification buttons and badges (#28471) --- src/vs/workbench/common/theme.ts | 56 ++++++++++++++++++- .../services/message/browser/messageList.ts | 29 +++++++--- 2 files changed, 75 insertions(+), 10 deletions(-) diff --git a/src/vs/workbench/common/theme.ts b/src/vs/workbench/common/theme.ts index 4297f3a2df2..072582f273e 100644 --- a/src/vs/workbench/common/theme.ts +++ b/src/vs/workbench/common/theme.ts @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ import nls = require('vs/nls'); -import { registerColor, editorBackground, contrastBorder, transparent, badgeForeground, badgeBackground } from 'vs/platform/theme/common/colorRegistry'; +import { registerColor, editorBackground, contrastBorder, transparent, badgeForeground, badgeBackground, lighten, darken } from 'vs/platform/theme/common/colorRegistry'; import { IDisposable, Disposable, dispose } from 'vs/base/common/lifecycle'; import { IThemeService, ITheme } from 'vs/platform/theme/common/themeService'; import { Color } from 'vs/base/common/color'; @@ -306,6 +306,60 @@ export const NOTIFICATIONS_BACKGROUND = registerColor('notification.background', hc: '#000000' }, nls.localize('notificationsBackground', "Notifications background color. Notifications slide in from the top of the window.")); +export const NOTIFICATIONS_BUTTON_BACKGROUND = registerColor('notification.buttonBackground', { + dark: '#0E639C', + light: '#007ACC', + hc: null +}, nls.localize('notificationsButtonBackground', "Notifications button background color. Notifications slide in from the top of the window.")); + +export const NOTIFICATIONS_BUTTON_HOVER_BACKGROUND = registerColor('notification.buttonHoverBackground', { + dark: lighten(NOTIFICATIONS_BUTTON_BACKGROUND, 0.2), + light: darken(NOTIFICATIONS_BUTTON_BACKGROUND, 0.2), + hc: null +}, nls.localize('notificationsButtonHoverBackground', "Notifications button background color when hovering. Notifications slide in from the top of the window.")); + +export const NOTIFICATIONS_BUTTON_FOREGROUND = registerColor('notification.buttonForeground', { + dark: Color.white, + light: Color.white, + hc: Color.white +}, nls.localize('notificationsButtonForeground', "Notifications button foreground color. Notifications slide in from the top of the window.")); + +export const NOTIFICATIONS_INFO_BACKGROUND = registerColor('notification.infoBackground', { + dark: '#007acc', + light: '#007acc', + hc: contrastBorder +}, nls.localize('notificationsInfoBackground', "Notifications info background color. Notifications slide in from the top of the window.")); + +export const NOTIFICATIONS_INFO_FOREGROUND = registerColor('notification.infoForeground', { + dark: NOTIFICATIONS_FOREGROUND, + light: NOTIFICATIONS_FOREGROUND, + hc: null +}, nls.localize('notificationsInfoForeground', "Notifications info foreground color. Notifications slide in from the top of the window.")); + +export const NOTIFICATIONS_WARNING_BACKGROUND = registerColor('notification.warningBackground', { + dark: '#B89500', + light: '#B89500', + hc: contrastBorder +}, nls.localize('notificationsWarningBackground', "Notifications warning background color. Notifications slide in from the top of the window.")); + +export const NOTIFICATIONS_WARNING_FOREGROUND = registerColor('notification.warningForeground', { + dark: NOTIFICATIONS_FOREGROUND, + light: NOTIFICATIONS_FOREGROUND, + hc: null +}, nls.localize('notificationsWarningForeground', "Notifications warning foreground color. Notifications slide in from the top of the window.")); + +export const NOTIFICATIONS_ERROR_BACKGROUND = registerColor('notification.errorBackground', { + dark: '#BE1100', + light: '#BE1100', + hc: contrastBorder +}, nls.localize('notificationsErrorBackground', "Notifications error background color. Notifications slide in from the top of the window.")); + +export const NOTIFICATIONS_ERROR_FOREGROUND = registerColor('notification.errorForeground', { + dark: NOTIFICATIONS_FOREGROUND, + light: NOTIFICATIONS_FOREGROUND, + hc: null +}, nls.localize('notificationsErrorForeground', "Notifications error foreground color. Notifications slide in from the top of the window.")); + /** * Base class for all themable workbench components. */ diff --git a/src/vs/workbench/services/message/browser/messageList.ts b/src/vs/workbench/services/message/browser/messageList.ts index 744b5818055..55e51942ce2 100644 --- a/src/vs/workbench/services/message/browser/messageList.ts +++ b/src/vs/workbench/services/message/browser/messageList.ts @@ -19,10 +19,10 @@ import { Action } from 'vs/base/common/actions'; import htmlRenderer = require('vs/base/browser/htmlContentRenderer'); import { StandardKeyboardEvent } from 'vs/base/browser/keyboardEvent'; import { KeyCode } from 'vs/base/common/keyCodes'; -import { NOTIFICATIONS_FOREGROUND, NOTIFICATIONS_BACKGROUND } from 'vs/workbench/common/theme'; +import { NOTIFICATIONS_FOREGROUND, NOTIFICATIONS_BACKGROUND, NOTIFICATIONS_BUTTON_BACKGROUND, NOTIFICATIONS_BUTTON_HOVER_BACKGROUND, NOTIFICATIONS_BUTTON_FOREGROUND, NOTIFICATIONS_INFO_BACKGROUND, NOTIFICATIONS_WARNING_BACKGROUND, NOTIFICATIONS_ERROR_BACKGROUND, NOTIFICATIONS_INFO_FOREGROUND, NOTIFICATIONS_WARNING_FOREGROUND, NOTIFICATIONS_ERROR_FOREGROUND } from 'vs/workbench/common/theme'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; -import { contrastBorder, buttonBackground, buttonHoverBackground, widgetShadow, inputValidationErrorBorder, inputValidationWarningBorder, inputValidationInfoBorder } from 'vs/platform/theme/common/colorRegistry'; +import { contrastBorder, widgetShadow } from 'vs/platform/theme/common/colorRegistry'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { Color } from 'vs/base/common/color'; @@ -77,9 +77,13 @@ export class MessageList { private widgetShadow = Color.fromHex('#000000'); private outlineBorder: Color; private buttonBackground = Color.fromHex('#0E639C'); + private buttonForeground = this.foreground; private infoBackground = Color.fromHex('#007ACC'); + private infoForeground = this.foreground; private warningBackground = Color.fromHex('#B89500'); + private warningForeground = this.foreground; private errorBackground = Color.fromHex('#BE1100'); + private errorForeground = this.foreground; constructor( container: HTMLElement, @@ -106,12 +110,16 @@ export class MessageList { this.foreground = theme.getColor(NOTIFICATIONS_FOREGROUND); this.widgetShadow = theme.getColor(widgetShadow); this.outlineBorder = theme.getColor(contrastBorder); - this.buttonBackground = theme.getColor(buttonBackground); - this.infoBackground = theme.getColor(inputValidationInfoBorder); - this.warningBackground = theme.getColor(inputValidationWarningBorder); - this.errorBackground = theme.getColor(inputValidationErrorBorder); - - const buttonHoverBackgroundColor = theme.getColor(buttonHoverBackground); + this.buttonBackground = theme.getColor(NOTIFICATIONS_BUTTON_BACKGROUND); + this.buttonForeground = theme.getColor(NOTIFICATIONS_BUTTON_FOREGROUND); + this.infoBackground = theme.getColor(NOTIFICATIONS_INFO_BACKGROUND); + this.infoForeground = theme.getColor(NOTIFICATIONS_INFO_FOREGROUND); + this.warningBackground = theme.getColor(NOTIFICATIONS_WARNING_BACKGROUND); + this.warningForeground = theme.getColor(NOTIFICATIONS_WARNING_FOREGROUND); + this.errorBackground = theme.getColor(NOTIFICATIONS_ERROR_BACKGROUND); + this.errorForeground = theme.getColor(NOTIFICATIONS_ERROR_FOREGROUND); + + const buttonHoverBackgroundColor = theme.getColor(NOTIFICATIONS_BUTTON_HOVER_BACKGROUND); if (buttonHoverBackgroundColor) { collector.addRule(`.global-message-list li.message-list-entry .actions-container .message-action .action-button:hover { background-color: ${buttonHoverBackgroundColor} !important; }`); } @@ -281,6 +289,7 @@ export class MessageList { div.a({ class: 'action-button', tabindex: '0', role: 'button' }) .style('border-color', this.outlineBorder ? this.outlineBorder.toString() : null) .style('background-color', this.buttonBackground ? this.buttonBackground.toString() : null) + .style('color', this.buttonForeground ? this.buttonForeground.toString() : null) .text(action.label) .on([DOM.EventType.CLICK, DOM.EventType.KEY_DOWN], e => { if (e instanceof KeyboardEvent) { @@ -317,9 +326,11 @@ export class MessageList { const sev = message.severity; const label = (sev === Severity.Error) ? nls.localize('error', "Error") : (sev === Severity.Warning) ? nls.localize('warning', "Warn") : nls.localize('info', "Info"); const color = (sev === Severity.Error) ? this.errorBackground : (sev === Severity.Warning) ? this.warningBackground : this.infoBackground; + const foregroundColor = (sev === Severity.Error) ? this.errorForeground : (sev === Severity.Warning) ? this.warningForeground : this.infoForeground; const sevLabel = $().span({ class: `message-left-side severity ${sev === Severity.Error ? 'app-error' : sev === Severity.Warning ? 'app-warning' : 'app-info'}`, text: label }); sevLabel.style('border-color', this.outlineBorder ? this.outlineBorder.toString() : null); sevLabel.style('background-color', color ? color.toString() : null); + sevLabel.style('color', foregroundColor ? foregroundColor.toString() : null); sevLabel.appendTo(div); // Error message @@ -469,4 +480,4 @@ export class MessageList { public dispose(): void { this.toDispose = dispose(this.toDispose); } -} \ No newline at end of file +} -- GitLab From 37a797067c708c1f566c256c68832324fe30b029 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Tue, 13 Jun 2017 08:51:30 +0200 Subject: [PATCH 0751/1347] hot exit: prevent duplicate empty windows from opening --- src/vs/code/electron-main/windows.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/vs/code/electron-main/windows.ts b/src/vs/code/electron-main/windows.ts index f05f08784a8..12a7337fb3d 100644 --- a/src/vs/code/electron-main/windows.ts +++ b/src/vs/code/electron-main/windows.ts @@ -265,8 +265,9 @@ export class WindowsManager implements IWindowsMainService { // const hotExitRestore = (openConfig.initialStartup && !openConfig.cli.extensionDevelopmentPath); const foldersToRestore = hotExitRestore ? this.backupService.getWorkspaceBackupPaths() : []; - const emptyToRestore = hotExitRestore ? this.backupService.getEmptyWorkspaceBackupPaths() : []; + let emptyToRestore = hotExitRestore ? this.backupService.getEmptyWorkspaceBackupPaths() : []; emptyToRestore.push(...windowsToOpen.filter(w => !w.workspacePath && w.backupPath).map(w => path.basename(w.backupPath))); // add empty windows with backupPath + emptyToRestore = arrays.distinct(emptyToRestore); // prevent duplicates // Open based on config const usedWindows = this.doOpen(openConfig, foldersToOpen, foldersToRestore, emptyToRestore, emptyToOpen, filesToOpen, filesToCreate, filesToDiff); -- GitLab From ba9a4314e1e25cbd135a6f0d5ea855e8f437d104 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Tue, 13 Jun 2017 09:33:16 +0200 Subject: [PATCH 0752/1347] Resolves #27903 --- .../debug/electron-browser/debugEditorContribution.ts | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.ts b/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.ts index 95e12911dcf..72c5ac93ee9 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.ts @@ -356,8 +356,13 @@ export class DebugEditorContribution implements IDebugEditorContribution { // Toggles exception widget based on the state of the current editor model and debug stack frame const model = this.editor.getModel(); const focusedSf = this.debugService.getViewModel().focusedStackFrame; - const callStack = focusedSf ? focusedSf.thread.getCallStack() : null; - if (!model || !focusedSf || !callStack || callStack.length === 0) { + if (!model || !focusedSf || !focusedSf.source || !focusedSf.source.available) { + this.closeExceptionWidget(); + return; + } + + const callStack = focusedSf.thread.getCallStack(); + if (!callStack || callStack.length === 0) { this.closeExceptionWidget(); return; } -- GitLab From 631e0a74eece2f5b7829c2723b5249683a5af00d Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Tue, 13 Jun 2017 10:18:16 +0200 Subject: [PATCH 0753/1347] Adding correct command to open git viewlet as it was changed. --- test/smoke/src/areas/git.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/smoke/src/areas/git.ts b/test/smoke/src/areas/git.ts index 9a088d46566..807b6cf50ff 100644 --- a/test/smoke/src/areas/git.ts +++ b/test/smoke/src/areas/git.ts @@ -14,7 +14,7 @@ export class Git { } public openGitViewlet(): Promise { - return this.spectron.command('workbench.view.git'); + return this.spectron.command('workbench.view.scm'); } public getScmIconChanges(): Promise { -- GitLab From 24c9b0992502302491763f25cf126fe91e9c165b Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Tue, 13 Jun 2017 10:34:03 +0200 Subject: [PATCH 0754/1347] Fail the test if the key binding was not found. --- test/smoke/src/spectron/application.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/smoke/src/spectron/application.ts b/test/smoke/src/spectron/application.ts index 64110535615..76443e8ec10 100644 --- a/test/smoke/src/spectron/application.ts +++ b/test/smoke/src/spectron/application.ts @@ -152,6 +152,10 @@ export class SpectronApplication { */ public command(command: string, capture?: boolean): Promise { const binding = this.keybindings.find(x => x['command'] === command); + if (!binding) { + throw new Error(`Key binding for ${command} was not found`); + } + const keys: string = binding.key; let keysToPress: string[] = []; -- GitLab From 7ce9ddee07f711692e329617969c18a66e485b24 Mon Sep 17 00:00:00 2001 From: isidor Date: Tue, 13 Jun 2017 11:14:24 +0200 Subject: [PATCH 0755/1347] debug: make sure to fetch the remainder of the callstack for the same thread fixes #28536 --- .../parts/debug/electron-browser/debugService.ts | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugService.ts b/src/vs/workbench/parts/debug/electron-browser/debugService.ts index aa3fd1b98f8..0f363b20908 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugService.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugService.ts @@ -82,6 +82,7 @@ export class DebugService implements debug.IDebugService { private breakpointsToSendOnResourceSaved: Set; private callStackScheduler: RunOnceScheduler; private launchJsonChanged: boolean; + private threadToFetch: debug.IThread; constructor( @IStorageService private storageService: IStorageService, @@ -121,14 +122,13 @@ export class DebugService implements debug.IDebugService { this.toDispose.push(this.model); this.viewModel = new ViewModel(this.storageService.get(DEBUG_SELECTED_CONFIG_NAME_KEY, StorageScope.WORKSPACE, null)); this.callStackScheduler = new RunOnceScheduler(() => { - const focusedThread = this.viewModel.focusedThread; - if (focusedThread) { - const callStack = focusedThread.getCallStack(); + if (this.threadToFetch) { + const callStack = this.threadToFetch.getCallStack(); // Some adapters might not respect the number levels in StackTraceRequest and might // return more stackFrames than requested. For those do not send an additional stackTrace request. if (callStack.length <= 1) { - this.model.fetchCallStack(focusedThread).done(() => - this.tryToAutoFocusStackFrame(focusedThread), errors.onUnexpectedError); + this.model.fetchCallStack(this.threadToFetch).done(() => + this.tryToAutoFocusStackFrame(this.threadToFetch), errors.onUnexpectedError); } } }, 420); @@ -330,6 +330,7 @@ export class DebugService implements debug.IDebugService { // Call fetch call stack twice, the first only return the top stack frame. // Second retrieves the rest of the call stack. For performance reasons #25605 this.model.fetchCallStack(thread).then(() => { + this.threadToFetch = thread; this.callStackScheduler.schedule(); return this.tryToAutoFocusStackFrame(thread); }); -- GitLab From 40498b093e3cd94412909a2aee48aa6843ccf788 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Tue, 13 Jun 2017 11:15:21 +0200 Subject: [PATCH 0756/1347] missing compilation --- build/lib/tslint/translationRemindRule.js | 158 +++++++++++----------- 1 file changed, 79 insertions(+), 79 deletions(-) diff --git a/build/lib/tslint/translationRemindRule.js b/build/lib/tslint/translationRemindRule.js index 90ba94aa5f4..d0ed1a02403 100644 --- a/build/lib/tslint/translationRemindRule.js +++ b/build/lib/tslint/translationRemindRule.js @@ -1,79 +1,79 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ -"use strict"; -var __extends = (this && this.__extends) || (function () { - var extendStatics = Object.setPrototypeOf || - ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || - function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; - return function (d, b) { - extendStatics(d, b); - function __() { this.constructor = d; } - d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); - }; -})(); -exports.__esModule = true; -var Lint = require("tslint"); -var fs = require("fs"); -var Rule = (function (_super) { - __extends(Rule, _super); - function Rule() { - return _super !== null && _super.apply(this, arguments) || this; - } - Rule.prototype.apply = function (sourceFile) { - return this.applyWithWalker(new TranslationRemindRuleWalker(sourceFile, this.getOptions())); - }; - return Rule; -}(Lint.Rules.AbstractRule)); -exports.Rule = Rule; -var TranslationRemindRuleWalker = (function (_super) { - __extends(TranslationRemindRuleWalker, _super); - function TranslationRemindRuleWalker(file, opts) { - return _super.call(this, file, opts) || this; - } - TranslationRemindRuleWalker.prototype.visitImportDeclaration = function (node) { - var declaration = node.moduleSpecifier.getText(); - if (declaration !== "'" + TranslationRemindRuleWalker.NLS_MODULE + "'") { - return; - } - this.visitImportLikeDeclaration(node); - }; - TranslationRemindRuleWalker.prototype.visitImportEqualsDeclaration = function (node) { - var reference = node.moduleReference.getText(); - if (reference !== "require('" + TranslationRemindRuleWalker.NLS_MODULE + "')") { - return; - } - this.visitImportLikeDeclaration(node); - }; - TranslationRemindRuleWalker.prototype.visitImportLikeDeclaration = function (node) { - var currentFile = node.getSourceFile().fileName; - var matchService = currentFile.match(/vs\/workbench\/services\/\w+/); - var matchPart = currentFile.match(/vs\/workbench\/parts\/\w+/); - if (!matchService && !matchPart) { - return; - } - var resource = matchService ? matchService[0] : matchPart[0]; - var resourceDefined = false; - var json; - try { - json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); - } - catch (e) { - console.error('[translation-remind rule]: File with resources to pull from Transifex was not found. Aborting translation resource check for newly defined workbench part/service.'); - return; - } - var workbenchResources = JSON.parse(json).workbench; - workbenchResources.forEach(function (existingResource) { - if (existingResource.name === resource) { - resourceDefined = true; - return; - } - }); - if (!resourceDefined) { - this.addFailureAtNode(node, "Please add '" + resource + "' to ./builds/lib/i18n.resources.json file to use translations here."); - } - }; - return TranslationRemindRuleWalker; -}(Lint.RuleWalker)); -TranslationRemindRuleWalker.NLS_MODULE = 'vs/nls'; +"use strict"; +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +var __extends = (this && this.__extends) || (function () { + var extendStatics = Object.setPrototypeOf || + ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || + function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; + return function (d, b) { + extendStatics(d, b); + function __() { this.constructor = d; } + d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); + }; +})(); +Object.defineProperty(exports, "__esModule", { value: true }); +var Lint = require("tslint"); +var fs = require("fs"); +var Rule = (function (_super) { + __extends(Rule, _super); + function Rule() { + return _super !== null && _super.apply(this, arguments) || this; + } + Rule.prototype.apply = function (sourceFile) { + return this.applyWithWalker(new TranslationRemindRuleWalker(sourceFile, this.getOptions())); + }; + return Rule; +}(Lint.Rules.AbstractRule)); +exports.Rule = Rule; +var TranslationRemindRuleWalker = (function (_super) { + __extends(TranslationRemindRuleWalker, _super); + function TranslationRemindRuleWalker(file, opts) { + return _super.call(this, file, opts) || this; + } + TranslationRemindRuleWalker.prototype.visitImportDeclaration = function (node) { + var declaration = node.moduleSpecifier.getText(); + if (declaration !== "'" + TranslationRemindRuleWalker.NLS_MODULE + "'") { + return; + } + this.visitImportLikeDeclaration(node); + }; + TranslationRemindRuleWalker.prototype.visitImportEqualsDeclaration = function (node) { + var reference = node.moduleReference.getText(); + if (reference !== "require('" + TranslationRemindRuleWalker.NLS_MODULE + "')") { + return; + } + this.visitImportLikeDeclaration(node); + }; + TranslationRemindRuleWalker.prototype.visitImportLikeDeclaration = function (node) { + var currentFile = node.getSourceFile().fileName; + var matchService = currentFile.match(/vs\/workbench\/services\/\w+/); + var matchPart = currentFile.match(/vs\/workbench\/parts\/\w+/); + if (!matchService && !matchPart) { + return; + } + var resource = matchService ? matchService[0] : matchPart[0]; + var resourceDefined = false; + var json; + try { + json = fs.readFileSync('./build/lib/i18n.resources.json', 'utf8'); + } + catch (e) { + console.error('[translation-remind rule]: File with resources to pull from Transifex was not found. Aborting translation resource check for newly defined workbench part/service.'); + return; + } + var workbenchResources = JSON.parse(json).workbench; + workbenchResources.forEach(function (existingResource) { + if (existingResource.name === resource) { + resourceDefined = true; + return; + } + }); + if (!resourceDefined) { + this.addFailureAtNode(node, "Please add '" + resource + "' to ./builds/lib/i18n.resources.json file to use translations here."); + } + }; + return TranslationRemindRuleWalker; +}(Lint.RuleWalker)); +TranslationRemindRuleWalker.NLS_MODULE = 'vs/nls'; -- GitLab From 3d3167ace71701c63da04f7e2905f83401af10fa Mon Sep 17 00:00:00 2001 From: isidor Date: Tue, 13 Jun 2017 11:23:05 +0200 Subject: [PATCH 0757/1347] fix typo --- src/vs/workbench/parts/debug/common/debugModel.ts | 4 ++-- src/vs/workbench/parts/debug/common/debugSource.ts | 2 +- .../workbench/parts/debug/electron-browser/debugViewer.ts | 6 +++--- .../workbench/parts/debug/test/common/debugSource.test.ts | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/vs/workbench/parts/debug/common/debugModel.ts b/src/vs/workbench/parts/debug/common/debugModel.ts index c68c9be42db..702ada257df 100644 --- a/src/vs/workbench/parts/debug/common/debugModel.ts +++ b/src/vs/workbench/parts/debug/common/debugModel.ts @@ -467,7 +467,7 @@ export class Thread implements IThread { let source = new Source(rsf.source, rsf.source ? rsf.source.presentationHint : rsf.presentationHint); if (this.process.sources.has(source.uri.toString())) { const alreadyCreatedSource = this.process.sources.get(source.uri.toString()); - alreadyCreatedSource.presenationHint = source.presenationHint; + alreadyCreatedSource.presentationHint = source.presentationHint; source = alreadyCreatedSource; } else { this.process.sources.set(source.uri.toString(), source); @@ -1039,7 +1039,7 @@ export class Model implements IModel { public deemphasizeSource(uri: uri): void { this.processes.forEach(p => { if (p.sources.has(uri.toString())) { - p.sources.get(uri.toString()).presenationHint = 'deemphasize'; + p.sources.get(uri.toString()).presentationHint = 'deemphasize'; } }); this._onDidChangeCallStack.fire(); diff --git a/src/vs/workbench/parts/debug/common/debugSource.ts b/src/vs/workbench/parts/debug/common/debugSource.ts index 103ec1d9ec8..042c9e8d1b7 100644 --- a/src/vs/workbench/parts/debug/common/debugSource.ts +++ b/src/vs/workbench/parts/debug/common/debugSource.ts @@ -13,7 +13,7 @@ export class Source { public uri: uri; - constructor(public raw: DebugProtocol.Source, public presenationHint: string) { + constructor(public raw: DebugProtocol.Source, public presentationHint: string) { if (!raw) { this.raw = { name: UNKNOWN_SOURCE_LABEL }; } diff --git a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts index 76cb4fb9945..b7bd340b853 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts @@ -544,9 +544,9 @@ export class CallStackRenderer implements IRenderer { } private renderStackFrame(stackFrame: debug.IStackFrame, data: IStackFrameTemplateData): void { - dom.toggleClass(data.stackFrame, 'disabled', stackFrame.source.presenationHint === 'deemphasize'); - dom.toggleClass(data.stackFrame, 'label', stackFrame.source.presenationHint === 'label'); - dom.toggleClass(data.stackFrame, 'subtle', stackFrame.source.presenationHint === 'subtle'); + dom.toggleClass(data.stackFrame, 'disabled', stackFrame.source.presentationHint === 'deemphasize'); + dom.toggleClass(data.stackFrame, 'label', stackFrame.source.presentationHint === 'label'); + dom.toggleClass(data.stackFrame, 'subtle', stackFrame.source.presentationHint === 'subtle'); data.file.title = stackFrame.source.raw.path || stackFrame.source.name; if (stackFrame.source.raw.origin) { diff --git a/src/vs/workbench/parts/debug/test/common/debugSource.test.ts b/src/vs/workbench/parts/debug/test/common/debugSource.test.ts index 43606a43d15..faace16575a 100644 --- a/src/vs/workbench/parts/debug/test/common/debugSource.test.ts +++ b/src/vs/workbench/parts/debug/test/common/debugSource.test.ts @@ -17,7 +17,7 @@ suite('Debug - Source', () => { }; const source = new Source(rawSource, 'label'); - assert.equal(source.presenationHint, 'label'); + assert.equal(source.presentationHint, 'label'); assert.equal(source.name, rawSource.name); assert.equal(source.inMemory, false); assert.equal(source.reference, rawSource.sourceReference); @@ -31,7 +31,7 @@ suite('Debug - Source', () => { }; const source = new Source(rawSource, 'deemphasize'); - assert.equal(source.presenationHint, 'deemphasize'); + assert.equal(source.presentationHint, 'deemphasize'); assert.equal(source.name, rawSource.name); assert.equal(source.inMemory, true); assert.equal(source.reference, rawSource.sourceReference); -- GitLab From 4a97494d871f65880e0f1abffbba963240c52800 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Tue, 13 Jun 2017 11:53:07 +0200 Subject: [PATCH 0758/1347] Keybindings in quick open aren't vertically aligned (fixes #28602) --- src/vs/base/parts/quickopen/browser/quickopen.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/base/parts/quickopen/browser/quickopen.css b/src/vs/base/parts/quickopen/browser/quickopen.css index 9173f8121cc..dfe35cceb0b 100644 --- a/src/vs/base/parts/quickopen/browser/quickopen.css +++ b/src/vs/base/parts/quickopen/browser/quickopen.css @@ -92,7 +92,7 @@ } .quick-open-widget .quick-open-tree .quick-open-entry-keybinding .monaco-kbkey { - vertical-align: inherit; + vertical-align: text-bottom; } .quick-open-widget .quick-open-tree .results-group { -- GitLab From bf6952b96d7409dfaf7d0883d4cd1f3286e0078f Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Tue, 13 Jun 2017 12:36:43 +0200 Subject: [PATCH 0759/1347] Rename `editor.urlClickable` to `editor.links` --- .../common/config/commonEditorConfig.ts | 6 ++-- src/vs/editor/common/config/editorOptions.ts | 30 ++++++++----------- src/vs/editor/contrib/links/browser/links.ts | 2 +- src/vs/monaco.d.ts | 13 ++++---- 4 files changed, 22 insertions(+), 29 deletions(-) diff --git a/src/vs/editor/common/config/commonEditorConfig.ts b/src/vs/editor/common/config/commonEditorConfig.ts index 7fddb2add18..57062412760 100644 --- a/src/vs/editor/common/config/commonEditorConfig.ts +++ b/src/vs/editor/common/config/commonEditorConfig.ts @@ -562,10 +562,10 @@ const editorConfiguration: IConfigurationNode = { 'default': EDITOR_DEFAULTS.accessibilitySupport, 'description': nls.localize('accessibilitySupport', "Controls whether the editor should run in a mode where it is optimized for screen readers.") }, - 'editor.urlClickable': { + 'editor.links': { 'type': 'boolean', - 'default': EDITOR_DEFAULTS.urlClickable, - 'description': nls.localize('urlClickable', "Controls whether the editor should underline any URL and make them clickable through CTRL-Left Click") + 'default': EDITOR_DEFAULTS.contribInfo.links, + 'description': nls.localize('links', "Controls whether the editor should detect links and make them clickable") }, 'diffEditor.renderSideBySide': { 'type': 'boolean', diff --git a/src/vs/editor/common/config/editorOptions.ts b/src/vs/editor/common/config/editorOptions.ts index e2f0285cfd4..d32c4b258d4 100644 --- a/src/vs/editor/common/config/editorOptions.ts +++ b/src/vs/editor/common/config/editorOptions.ts @@ -321,6 +321,11 @@ export interface IEditorOptions { * Defaults to true. */ hover?: boolean; + /** + * Enable detecting links and making them clickable. + * Defaults to true. + */ + links?: boolean; /** * Enable custom contextmenu. * Defaults to true. @@ -341,11 +346,6 @@ export interface IEditorOptions { * Defaults to 'auto'. It is best to leave this to 'auto'. */ accessibilitySupport?: 'auto' | 'off' | 'on'; - /** - * Enable underlining URL and make it as a clickable link through CTRL-click - * Defaults to true. - */ - urlClickable?: boolean; /** * Enable quick suggestions (shadow suggestions) * Defaults to true. @@ -750,6 +750,7 @@ export interface InternalEditorViewOptions { export interface EditorContribOptions { readonly selectionClipboard: boolean; readonly hover: boolean; + readonly links: boolean; readonly contextmenu: boolean; readonly quickSuggestions: boolean | { other: boolean, comments: boolean, strings: boolean }; readonly quickSuggestionsDelay: number; @@ -800,7 +801,6 @@ export interface IValidatedEditorOptions { readonly useTabStops: boolean; readonly multiCursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; readonly accessibilitySupport: 'auto' | 'off' | 'on'; - readonly urlClickable: boolean; readonly viewInfo: InternalEditorViewOptions; readonly contribInfo: EditorContribOptions; @@ -822,7 +822,6 @@ export class InternalEditorOptions { */ readonly accessibilitySupport: platform.AccessibilitySupport; readonly multiCursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; - readonly urlClickable: boolean; // ---- cursor options readonly wordSeparators: string; @@ -861,7 +860,6 @@ export class InternalEditorOptions { viewInfo: InternalEditorViewOptions; wrappingInfo: EditorWrappingInfo; contribInfo: EditorContribOptions; - urlClickable: boolean; }) { this.canUseTranslate3d = source.canUseTranslate3d; this.pixelRatio = source.pixelRatio; @@ -881,7 +879,6 @@ export class InternalEditorOptions { this.viewInfo = source.viewInfo; this.wrappingInfo = source.wrappingInfo; this.contribInfo = source.contribInfo; - this.urlClickable = source.urlClickable; } /** @@ -902,7 +899,6 @@ export class InternalEditorOptions { && this.tabFocusMode === other.tabFocusMode && this.dragAndDrop === other.dragAndDrop && this.emptySelectionClipboard === other.emptySelectionClipboard - && this.urlClickable === other.urlClickable && InternalEditorOptions._equalsLayoutInfo(this.layoutInfo, other.layoutInfo) && this.fontInfo.equals(other.fontInfo) && InternalEditorOptions._equalsViewOptions(this.viewInfo, other.viewInfo) @@ -933,8 +929,7 @@ export class InternalEditorOptions { fontInfo: (!this.fontInfo.equals(newOpts.fontInfo)), viewInfo: (!InternalEditorOptions._equalsViewOptions(this.viewInfo, newOpts.viewInfo)), wrappingInfo: (!InternalEditorOptions._equalsWrappingInfo(this.wrappingInfo, newOpts.wrappingInfo)), - contribInfo: (!InternalEditorOptions._equalsContribOptions(this.contribInfo, newOpts.contribInfo)), - urlClickable: (this.urlClickable !== newOpts.urlClickable), + contribInfo: (!InternalEditorOptions._equalsContribOptions(this.contribInfo, newOpts.contribInfo)) }; } @@ -1091,6 +1086,7 @@ export class InternalEditorOptions { return ( a.selectionClipboard === b.selectionClipboard && a.hover === b.hover + && a.links === b.links && a.contextmenu === b.contextmenu && InternalEditorOptions._equalsQuickSuggestions(a.quickSuggestions, b.quickSuggestions) && a.quickSuggestionsDelay === b.quickSuggestionsDelay @@ -1273,7 +1269,6 @@ export interface IConfigurationChangedEvent { readonly viewInfo: boolean; readonly wrappingInfo: boolean; readonly contribInfo: boolean; - readonly urlClickable: boolean; } /** @@ -1448,7 +1443,6 @@ export class EditorOptionsValidator { useTabStops: _boolean(opts.useTabStops, defaults.useTabStops), multiCursorModifier: multiCursorModifier, accessibilitySupport: _stringSet<'auto' | 'on' | 'off'>(opts.accessibilitySupport, defaults.accessibilitySupport, ['auto', 'on', 'off']), - urlClickable: _boolean(opts.urlClickable, defaults.urlClickable), viewInfo: viewInfo, contribInfo: contribInfo, }; @@ -1617,6 +1611,7 @@ export class EditorOptionsValidator { return { selectionClipboard: _boolean(opts.selectionClipboard, defaults.selectionClipboard), hover: _boolean(opts.hover, defaults.hover), + links: _boolean(opts.links, defaults.links), contextmenu: _boolean(opts.contextmenu, defaults.contextmenu), quickSuggestions: quickSuggestions, quickSuggestionsDelay: _clampedInt(opts.quickSuggestionsDelay, defaults.quickSuggestionsDelay, Constants.MIN_SAFE_SMALL_INTEGER, Constants.MAX_SAFE_SMALL_INTEGER), @@ -1672,7 +1667,6 @@ export class InternalEditorOptionsFactory { useTabStops: opts.useTabStops, multiCursorModifier: opts.multiCursorModifier, accessibilitySupport: opts.accessibilitySupport, - urlClickable: opts.urlClickable, viewInfo: { extraEditorClassName: opts.viewInfo.extraEditorClassName, @@ -1711,6 +1705,7 @@ export class InternalEditorOptionsFactory { contribInfo: { selectionClipboard: opts.contribInfo.selectionClipboard, hover: opts.contribInfo.hover, + links: (accessibilityIsOn ? false : opts.contribInfo.links), // DISABLED WHEN SCREEN READER IS ATTACHED contextmenu: opts.contribInfo.contextmenu, quickSuggestions: opts.contribInfo.quickSuggestions, quickSuggestionsDelay: opts.contribInfo.quickSuggestionsDelay, @@ -1880,8 +1875,7 @@ export class InternalEditorOptionsFactory { fontInfo: env.fontInfo, viewInfo: opts.viewInfo, wrappingInfo: wrappingInfo, - contribInfo: opts.contribInfo, - urlClickable: opts.urlClickable + contribInfo: opts.contribInfo }); } } @@ -2091,7 +2085,6 @@ export const EDITOR_DEFAULTS: IValidatedEditorOptions = { useTabStops: true, multiCursorModifier: 'altKey', accessibilitySupport: 'auto', - urlClickable: true, viewInfo: { extraEditorClassName: '', @@ -2143,6 +2136,7 @@ export const EDITOR_DEFAULTS: IValidatedEditorOptions = { contribInfo: { selectionClipboard: true, hover: true, + links: true, contextmenu: true, quickSuggestions: { other: true, comments: false, strings: false }, quickSuggestionsDelay: 10, diff --git a/src/vs/editor/contrib/links/browser/links.ts b/src/vs/editor/contrib/links/browser/links.ts index 1f6e93fb08e..04ebb1a926b 100644 --- a/src/vs/editor/contrib/links/browser/links.ts +++ b/src/vs/editor/contrib/links/browser/links.ts @@ -184,7 +184,7 @@ class LinkDetector implements editorCommon.IEditorContribution { } private beginCompute(): void { - if (!this.editor.getModel() || !this.editor.getConfiguration().urlClickable) { + if (!this.editor.getModel() || !this.editor.getConfiguration().contribInfo.links) { return; } diff --git a/src/vs/monaco.d.ts b/src/vs/monaco.d.ts index 2670e27c2e6..e9ab788674a 100644 --- a/src/vs/monaco.d.ts +++ b/src/vs/monaco.d.ts @@ -2867,6 +2867,11 @@ declare module monaco.editor { * Defaults to true. */ hover?: boolean; + /** + * Enable detecting links and making them clickable. + * Defaults to true. + */ + links?: boolean; /** * Enable custom contextmenu. * Defaults to true. @@ -2887,11 +2892,6 @@ declare module monaco.editor { * Defaults to 'auto'. It is best to leave this to 'auto'. */ accessibilitySupport?: 'auto' | 'off' | 'on'; - /** - * Enable underlining URL and make it as a clickable link through CTRL-click - * Defaults to true. - */ - urlClickable?: boolean; /** * Enable quick suggestions (shadow suggestions) * Defaults to true. @@ -3236,6 +3236,7 @@ declare module monaco.editor { export interface EditorContribOptions { readonly selectionClipboard: boolean; readonly hover: boolean; + readonly links: boolean; readonly contextmenu: boolean; readonly quickSuggestions: boolean | { other: boolean; @@ -3274,7 +3275,6 @@ declare module monaco.editor { readonly lineHeight: number; readonly readOnly: boolean; readonly multiCursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; - readonly urlClickable: boolean; readonly wordSeparators: string; readonly autoClosingBrackets: boolean; readonly useTabStops: boolean; @@ -3418,7 +3418,6 @@ declare module monaco.editor { readonly viewInfo: boolean; readonly wrappingInfo: boolean; readonly contribInfo: boolean; - readonly urlClickable: boolean; } /** -- GitLab From b9204f6eefa4ff4fa469b33726d68eae8f425cc4 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Tue, 13 Jun 2017 12:44:50 +0200 Subject: [PATCH 0760/1347] Corrected necessary dependencies to match only minor versions #27537 --- test/smoke/package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/smoke/package.json b/test/smoke/package.json index eb58965b87c..292850b6a0e 100644 --- a/test/smoke/package.json +++ b/test/smoke/package.json @@ -11,10 +11,10 @@ "@types/mocha": "^2.2.41", "@types/node": "^6.0.70", "@types/webdriverio": "^4.6.1", - "@types/electron": "^1.4.37", + "@types/electron": "~1.4.37", "@types/rimraf": "^0.0.28", "mocha": "^3.2.0", - "spectron": "^3.6.4", + "spectron": "~3.6.4", "typescript": "^2.2.2", "rimraf": "^2.6.1", "commander": "^2.9.0", -- GitLab From 401a54a4247f9dcd8eb38ca625b30408360cd59f Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Tue, 13 Jun 2017 12:47:56 +0200 Subject: [PATCH 0761/1347] React to changing the `editor.links` option --- src/vs/editor/contrib/links/browser/links.ts | 21 +++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/src/vs/editor/contrib/links/browser/links.ts b/src/vs/editor/contrib/links/browser/links.ts index 04ebb1a926b..7b566b860be 100644 --- a/src/vs/editor/contrib/links/browser/links.ts +++ b/src/vs/editor/contrib/links/browser/links.ts @@ -108,6 +108,7 @@ class LinkDetector implements editorCommon.IEditorContribution { static RECOMPUTE_TIME = 1000; // ms private editor: ICodeEditor; + private enabled: boolean; private listenersToRemove: IDisposable[]; private timeoutPromise: TPromise; private computePromise: TPromise; @@ -141,6 +142,24 @@ class LinkDetector implements editorCommon.IEditorContribution { this.cleanUpActiveLinkDecoration(); })); + this.enabled = editor.getConfiguration().contribInfo.links; + this.listenersToRemove.push(editor.onDidChangeConfiguration((e) => { + let enabled = editor.getConfiguration().contribInfo.links; + if (this.enabled === enabled) { + // No change in our configuration option + return; + } + this.enabled = enabled; + + // Remove any links (for the getting disabled case) + this.updateDecorations([]); + + // Stop any computation (for the getting disabled case) + this.stop(); + + // Start computing (for the getting enabled case) + this.beginCompute(); + })); this.listenersToRemove.push(editor.onDidChangeModelContent((e) => this.onChange())); this.listenersToRemove.push(editor.onDidChangeModel((e) => this.onModelChanged())); this.listenersToRemove.push(editor.onDidChangeModelLanguage((e) => this.onModelModeChanged())); @@ -184,7 +203,7 @@ class LinkDetector implements editorCommon.IEditorContribution { } private beginCompute(): void { - if (!this.editor.getModel() || !this.editor.getConfiguration().contribInfo.links) { + if (!this.editor.getModel() || !this.enabled) { return; } -- GitLab From 0a203b9983836860fd2fa839629ea67ea0dd8818 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Tue, 13 Jun 2017 10:33:20 +0200 Subject: [PATCH 0762/1347] #28538 Merge WorkspaceContextService and WorkspaceConfigurationService into a single service implementation --- src/vs/workbench/electron-browser/main.ts | 15 +- .../services/workspace/node/workspace.ts | 413 ++++++++++++++++++ 2 files changed, 420 insertions(+), 8 deletions(-) create mode 100644 src/vs/workbench/services/workspace/node/workspace.ts diff --git a/src/vs/workbench/electron-browser/main.ts b/src/vs/workbench/electron-browser/main.ts index 69ca40fed63..26d301a6ded 100644 --- a/src/vs/workbench/electron-browser/main.ts +++ b/src/vs/workbench/electron-browser/main.ts @@ -18,8 +18,8 @@ import paths = require('vs/base/common/paths'); import uri from 'vs/base/common/uri'; import strings = require('vs/base/common/strings'); import { IResourceInput } from 'vs/platform/editor/common/editor'; -import { WorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; -import { WorkspaceConfigurationService } from 'vs/workbench/services/configuration/node/configurationService'; +import { Workspace } from 'vs/platform/workspace/common/workspace'; +import { WorkspaceService } from 'vs/workbench/services/configuration/node/configuration'; import { realpath, stat } from 'vs/base/node/pfs'; import { EnvironmentService } from 'vs/platform/environment/node/environmentService'; import path = require('path'); @@ -129,13 +129,12 @@ function getWorkspace(workspacePath: string): TPromise { function openWorkbench(configuration: IWindowConfiguration, workspace: Workspace, options: IOptions): TPromise { const environmentService = new EnvironmentService(configuration, configuration.execPath); - const configurationService = new WorkspaceConfigurationService(environmentService, workspace); - const contextService = new WorkspaceContextService(configurationService, workspace); - const timerService = new TimerService((window).MonacoEnvironment.timers as IInitData, !contextService.hasWorkspace()); + const workspaceService = new WorkspaceService(environmentService, workspace); + const timerService = new TimerService((window).MonacoEnvironment.timers as IInitData, !workspaceService.hasWorkspace()); // Since the configuration service is one of the core services that is used in so many places, we initialize it // right before startup of the workbench shell to have its data ready for consumers - return configurationService.initialize().then(() => { + return workspaceService.initialize().then(() => { timerService.beforeDOMContentLoaded = Date.now(); return domContentLoaded().then(() => { @@ -144,8 +143,8 @@ function openWorkbench(configuration: IWindowConfiguration, workspace: Workspace // Open Shell timerService.beforeWorkbenchOpen = Date.now(); const shell = new WorkbenchShell(document.body, { - configurationService, - contextService, + contextService: workspaceService, + configurationService: workspaceService, environmentService, timerService }, configuration, options); diff --git a/src/vs/workbench/services/workspace/node/workspace.ts b/src/vs/workbench/services/workspace/node/workspace.ts new file mode 100644 index 00000000000..85f411d715c --- /dev/null +++ b/src/vs/workbench/services/workspace/node/workspace.ts @@ -0,0 +1,413 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +'use strict'; + +import URI from 'vs/base/common/uri'; +import * as paths from 'vs/base/common/paths'; +import { TPromise } from 'vs/base/common/winjs.base'; +import Event, { Emitter } from 'vs/base/common/event'; +import { distinct, equals } from "vs/base/common/arrays"; +import * as objects from 'vs/base/common/objects'; +import * as errors from 'vs/base/common/errors'; +import * as collections from 'vs/base/common/collections'; +import { Disposable } from "vs/base/common/lifecycle"; +import { Schemas } from "vs/base/common/network"; +import { RunOnceScheduler } from 'vs/base/common/async'; +import { readFile } from 'vs/base/node/pfs'; +import * as extfs from 'vs/base/node/extfs'; +import { IWorkspaceContextService, Workspace, IWorkspace } from "vs/platform/workspace/common/workspace"; +import { IEnvironmentService } from 'vs/platform/environment/common/environment'; +import { FileChangeType, FileChangesEvent, isEqual } from 'vs/platform/files/common/files'; +import { ConfigModel } from 'vs/platform/configuration/common/model'; +import { ScopedConfigModel, WorkspaceConfigModel, WorkspaceSettingsConfigModel } from 'vs/workbench/services/configuration/common/configurationModels'; +import { IConfigurationServiceEvent, ConfigurationSource, getConfigurationValue, IConfigModel, IConfigurationOptions } from 'vs/platform/configuration/common/configuration'; +import { IWorkspaceConfigurationValues, IWorkspaceConfigurationService, IWorkspaceConfigurationValue, WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME, WORKSPACE_STANDALONE_CONFIGURATIONS, WORKSPACE_CONFIG_DEFAULT_PATH } from 'vs/workbench/services/configuration/common/configuration'; +import { ConfigurationService as GlobalConfigurationService } from 'vs/platform/configuration/node/configurationService'; + +interface IStat { + resource: URI; + isDirectory?: boolean; + children?: { resource: URI; }[]; +} + +interface IContent { + resource: URI; + value: string; +} + +interface IWorkspaceConfiguration { + workspace: T; + consolidated: any; +} + +type IWorkspaceFoldersConfiguration = { [rootFolder: string]: { folders: string[]; } }; + +export class WorkspaceService extends Disposable implements IWorkspaceContextService, IWorkspaceConfigurationService { + + private static RELOAD_CONFIGURATION_DELAY = 50; + + public _serviceBrand: any; + + private readonly _onDidChangeFolders: Emitter = this._register(new Emitter()); + public readonly onDidChangeFolders: Event = this._onDidChangeFolders.event; + + private readonly _onDidUpdateConfiguration: Emitter = this._register(new Emitter()); + public readonly onDidUpdateConfiguration: Event = this._onDidUpdateConfiguration.event; + + private baseConfigurationService: GlobalConfigurationService; + + private cachedConfig: ConfigModel; + private cachedWorkspaceConfig: WorkspaceConfigModel; + + private bulkFetchFromWorkspacePromise: TPromise; + private workspaceFilePathToConfiguration: { [relativeWorkspacePath: string]: TPromise> }; + private reloadConfigurationScheduler: RunOnceScheduler; + + private folders: URI[]; + + constructor(private environmentService: IEnvironmentService, private workspace?: Workspace, private workspaceSettingsRootFolder: string = WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME) { + super(); + + this.folders = workspace ? [workspace.resource] : []; + + this.workspaceFilePathToConfiguration = Object.create(null); + this.cachedConfig = new ConfigModel(null); + this.cachedWorkspaceConfig = new WorkspaceConfigModel(new WorkspaceSettingsConfigModel(null), []); + + this.baseConfigurationService = this._register(new GlobalConfigurationService(environmentService)); + this.reloadConfigurationScheduler = this._register(new RunOnceScheduler(() => this.doLoadConfiguration() + .then(config => this._onDidUpdateConfiguration.fire({ + config: config.consolidated, + source: ConfigurationSource.Workspace, + sourceConfig: config.workspace + })) + .done(null, errors.onUnexpectedError), WorkspaceService.RELOAD_CONFIGURATION_DELAY)); + + this._register(this.baseConfigurationService.onDidUpdateConfiguration(e => this.onBaseConfigurationChanged(e))); + this._register(this.onDidUpdateConfiguration(e => this.resolveAdditionalFolders(true))); + } + + private resolveAdditionalFolders(notify?: boolean): void { + if (!this.workspace) { + return; // no additional folders for empty workspaces + } + + // Resovled configured folders for workspace + let configuredFolders: URI[] = [this.workspace.resource]; + const config = this.getConfiguration('workspace'); + if (config) { + const workspaceConfig = config[this.workspace.resource.toString()]; + if (workspaceConfig) { + const additionalFolders = workspaceConfig.folders + .map(f => URI.parse(f)) + .filter(r => r.scheme === Schemas.file); // only support files for now + + configuredFolders.push(...additionalFolders); + } + } + + // Remove duplicates + configuredFolders = distinct(configuredFolders, r => r.toString()); + + // Find changes + const changed = !equals(this.folders, configuredFolders, (r1, r2) => r1.toString() === r2.toString()); + + this.folders = configuredFolders; + + if (notify && changed) { + this._onDidChangeFolders.fire(configuredFolders); + } + } + + public getFolders(): URI[] { + return this.folders; + } + + public getWorkspace(): IWorkspace { + return this.workspace; + } + + public hasWorkspace(): boolean { + return !!this.workspace; + } + + public isInsideWorkspace(resource: URI): boolean { + return this.workspace ? this.workspace.isInsideWorkspace(resource) : false; + } + + public toWorkspaceRelativePath(resource: URI, toOSPath?: boolean): string { + return this.workspace ? this.workspace.toWorkspaceRelativePath(resource, toOSPath) : null; + } + + public toResource(workspaceRelativePath: string): URI { + return this.workspace ? this.workspace.toResource(workspaceRelativePath) : null; + } + + private onBaseConfigurationChanged(event: IConfigurationServiceEvent): void { + if (event.source === ConfigurationSource.Default) { + this.cachedWorkspaceConfig.update(); + } + + // update cached config when base config changes + const configModel = >this.baseConfigurationService.getCache().consolidated // global/default values (do NOT modify) + .merge(this.cachedWorkspaceConfig); // workspace configured values + + // emit this as update to listeners if changed + if (!objects.equals(this.cachedConfig.contents, configModel.contents)) { + this.cachedConfig = configModel; + this._onDidUpdateConfiguration.fire({ + config: this.cachedConfig.contents, + source: event.source, + sourceConfig: event.sourceConfig + }); + } + } + + public initialize(): TPromise { + return this.doLoadConfiguration().then(() => null); + } + + public getConfiguration(section?: string): C + public getConfiguration(options?: IConfigurationOptions): C + public getConfiguration(arg?: any): C { + const options = this.toOptions(arg); + const configModel = options.overrideIdentifier ? this.cachedConfig.configWithOverrides(options.overrideIdentifier) : this.cachedConfig; + return options.section ? configModel.getContentsFor(options.section) : configModel.contents; + } + + public lookup(key: string, overrideIdentifier?: string): IWorkspaceConfigurationValue { + const configurationValue = this.baseConfigurationService.lookup(key, overrideIdentifier); + return { + default: configurationValue.default, + user: configurationValue.user, + workspace: objects.clone(getConfigurationValue(overrideIdentifier ? this.cachedWorkspaceConfig.configWithOverrides(overrideIdentifier).contents : this.cachedWorkspaceConfig.contents, key)), + value: objects.clone(getConfigurationValue(overrideIdentifier ? this.cachedConfig.configWithOverrides(overrideIdentifier).contents : this.cachedConfig.contents, key)) + }; + } + + public keys() { + const keys = this.baseConfigurationService.keys(); + + return { + default: keys.default, + user: keys.user, + workspace: this.cachedWorkspaceConfig.keys + }; + } + + public values(): IWorkspaceConfigurationValues { + const result: IWorkspaceConfigurationValues = Object.create(null); + const keyset = this.keys(); + const keys = [...keyset.workspace, ...keyset.user, ...keyset.default].sort(); + + let lastKey: string; + for (const key of keys) { + if (key !== lastKey) { + lastKey = key; + result[key] = this.lookup(key); + } + } + + return result; + } + + public reloadConfiguration(section?: string): TPromise { + + // Reset caches to ensure we are hitting the disk + this.bulkFetchFromWorkspacePromise = null; + this.workspaceFilePathToConfiguration = Object.create(null); + + // Load configuration + return this.baseConfigurationService.reloadConfiguration().then(() => { + const current = this.cachedConfig; + return this.doLoadConfiguration().then(configuration => { + // emit this as update to listeners if changed + if (!objects.equals(current, this.cachedConfig)) { + this._onDidUpdateConfiguration.fire({ + config: configuration.consolidated, + source: ConfigurationSource.Workspace, + sourceConfig: configuration.workspace + }); + } + return section ? configuration.consolidated[section] : configuration.consolidated; + }); + }); + } + + private toOptions(arg: any): IConfigurationOptions { + if (typeof arg === 'string') { + return { section: arg }; + } + if (typeof arg === 'object') { + return arg; + } + return {}; + } + + private doLoadConfiguration(): TPromise> { + + // Load workspace locals + return this.loadWorkspaceConfigFiles().then(workspaceConfigFiles => { + + // Consolidate (support *.json files in the workspace settings folder) + const workspaceSettingsConfig = >workspaceConfigFiles[WORKSPACE_CONFIG_DEFAULT_PATH] || new WorkspaceSettingsConfigModel(null); + const otherConfigModels = Object.keys(workspaceConfigFiles).filter(key => key !== WORKSPACE_CONFIG_DEFAULT_PATH).map(key => >workspaceConfigFiles[key]); + this.cachedWorkspaceConfig = new WorkspaceConfigModel(workspaceSettingsConfig, otherConfigModels); + + // Override base (global < user) with workspace locals (global < user < workspace) + this.cachedConfig = >this.baseConfigurationService.getCache().consolidated // global/default values (do NOT modify) + .merge(this.cachedWorkspaceConfig); // workspace configured values + + return { + consolidated: this.cachedConfig.contents, + workspace: this.cachedWorkspaceConfig.contents + }; + }); + } + + private loadWorkspaceConfigFiles(): TPromise<{ [relativeWorkspacePath: string]: IConfigModel }> { + + // Return early if we don't have a workspace + if (!this.workspace) { + return TPromise.as(Object.create(null)); + } + + // once: when invoked for the first time we fetch json files that contribute settings + if (!this.bulkFetchFromWorkspacePromise) { + this.bulkFetchFromWorkspacePromise = resolveStat(this.workspace.toResource(this.workspaceSettingsRootFolder)).then(stat => { + if (!stat.isDirectory) { + return TPromise.as([]); + } + + return resolveContents(stat.children.filter(stat => { + const isJson = paths.extname(stat.resource.fsPath) === '.json'; + if (!isJson) { + return false; // only JSON files + } + + return this.isWorkspaceConfigurationFile(this.workspace.toWorkspaceRelativePath(stat.resource)); // only workspace config files + }).map(stat => stat.resource)); + }, err => [] /* never fail this call */) + .then((contents: IContent[]) => { + contents.forEach(content => this.workspaceFilePathToConfiguration[this.workspace.toWorkspaceRelativePath(content.resource)] = TPromise.as(this.createConfigModel(content))); + }, errors.onUnexpectedError); + } + + // on change: join on *all* configuration file promises so that we can merge them into a single configuration object. this + // happens whenever a config file changes, is deleted, or added + return this.bulkFetchFromWorkspacePromise.then(() => TPromise.join(this.workspaceFilePathToConfiguration)); + } + + public handleWorkspaceFileEvents(event: FileChangesEvent): void { + if (!this.workspace) { + return; // only enabled when we have a known workspace + } + + const events = event.changes; + let affectedByChanges = false; + + // Find changes that affect workspace configuration files + for (let i = 0, len = events.length; i < len; i++) { + const resource = events[i].resource; + const isJson = paths.extname(resource.fsPath) === '.json'; + const isDeletedSettingsFolder = (events[i].type === FileChangeType.DELETED && isEqual(paths.basename(resource.fsPath), this.workspaceSettingsRootFolder)); + if (!isJson && !isDeletedSettingsFolder) { + continue; // only JSON files or the actual settings folder + } + + const workspacePath = this.workspace.toWorkspaceRelativePath(resource); + if (!workspacePath) { + continue; // event is not inside workspace + } + + // Handle case where ".vscode" got deleted + if (workspacePath === this.workspaceSettingsRootFolder && events[i].type === FileChangeType.DELETED) { + this.workspaceFilePathToConfiguration = Object.create(null); + affectedByChanges = true; + } + + // only valid workspace config files + if (!this.isWorkspaceConfigurationFile(workspacePath)) { + continue; + } + + // insert 'fetch-promises' for add and update events and + // remove promises for delete events + switch (events[i].type) { + case FileChangeType.DELETED: + affectedByChanges = collections.remove(this.workspaceFilePathToConfiguration, workspacePath); + break; + case FileChangeType.UPDATED: + case FileChangeType.ADDED: + this.workspaceFilePathToConfiguration[workspacePath] = resolveContent(resource).then(content => this.createConfigModel(content), errors.onUnexpectedError); + affectedByChanges = true; + } + } + + // trigger reload of the configuration if we are affected by changes + if (affectedByChanges && !this.reloadConfigurationScheduler.isScheduled()) { + this.reloadConfigurationScheduler.schedule(); + } + } + + private createConfigModel(content: IContent): IConfigModel { + const path = this.workspace.toWorkspaceRelativePath(content.resource); + if (path === WORKSPACE_CONFIG_DEFAULT_PATH) { + return new WorkspaceSettingsConfigModel(content.value, content.resource.toString()); + } else { + const matches = /\/([^\.]*)*\.json/.exec(path); + if (matches && matches[1]) { + return new ScopedConfigModel(content.value, content.resource.toString(), matches[1]); + } + } + + return new ConfigModel(null); + } + + private isWorkspaceConfigurationFile(workspaceRelativePath: string): boolean { + return [WORKSPACE_CONFIG_DEFAULT_PATH, WORKSPACE_STANDALONE_CONFIGURATIONS.launch, WORKSPACE_STANDALONE_CONFIGURATIONS.tasks].some(p => p === workspaceRelativePath); + } + + public getUnsupportedWorkspaceKeys(): string[] { + return this.cachedWorkspaceConfig.workspaceSettingsConfig.unsupportedKeys; + } + +} + +// node.hs helper functions + +function resolveContents(resources: URI[]): TPromise { + const contents: IContent[] = []; + + return TPromise.join(resources.map(resource => { + return resolveContent(resource).then(content => { + contents.push(content); + }); + })).then(() => contents); +} + +function resolveContent(resource: URI): TPromise { + return readFile(resource.fsPath).then(contents => ({ resource, value: contents.toString() })); +} + +function resolveStat(resource: URI): TPromise { + return new TPromise((c, e) => { + extfs.readdir(resource.fsPath, (error, children) => { + if (error) { + if ((error).code === 'ENOTDIR') { + c({ resource }); + } else { + e(error); + } + } else { + c({ + resource, + isDirectory: true, + children: children.map(child => { return { resource: URI.file(paths.join(resource.fsPath, child)) }; }) + }); + } + }); + }); +} \ No newline at end of file -- GitLab From 1e74972fe2e7d51daea0b9f08bef03889bd9320c Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Tue, 13 Jun 2017 11:51:48 +0200 Subject: [PATCH 0763/1347] #28538 Remove existing workspace context service - Create a simple workspace context service for standalone editor - Use the test context service for tests --- .../browser/standalone/simpleServices.ts | 39 ++++++++ .../browser/standalone/standaloneServices.ts | 6 +- .../common/extensionEnablementService.test.ts | 7 +- .../storage/test/storageService.test.ts | 13 +-- .../electron-browser/commonProperties.test.ts | 8 +- src/vs/platform/workspace/common/workspace.ts | 99 +------------------ .../extensionsActions.test.ts | 7 +- .../extensionsWorkbenchService.test.ts | 7 +- .../terminalLinkHandler.test.ts | 10 +- .../node/configurationEditingService.test.ts | 14 +-- src/vs/workbench/test/browser/part.test.ts | 8 +- src/vs/workbench/test/common/memento.test.ts | 8 +- .../quickopen.perf.integrationTest.ts | 7 +- .../textsearch.perf.integrationTest.ts | 6 +- 14 files changed, 82 insertions(+), 157 deletions(-) diff --git a/src/vs/editor/browser/standalone/simpleServices.ts b/src/vs/editor/browser/standalone/simpleServices.ts index f9c2a8fc51e..3b01a330dbf 100644 --- a/src/vs/editor/browser/standalone/simpleServices.ts +++ b/src/vs/editor/browser/standalone/simpleServices.ts @@ -17,6 +17,7 @@ import { KeybindingResolver } from 'vs/platform/keybinding/common/keybindingReso import { IKeybindingEvent, KeybindingSource, IKeyboardEvent } from 'vs/platform/keybinding/common/keybinding'; import { ContextKeyExpr, IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; import { IConfirmation, IMessageService } from 'vs/platform/message/common/message'; +import { IWorkspaceContextService, Workspace, IWorkspace } from 'vs/platform/workspace/common/workspace'; import * as editorCommon from 'vs/editor/common/editorCommon'; import { ICodeEditor, IDiffEditor } from 'vs/editor/browser/editorBrowser'; import { Selection } from 'vs/editor/common/core/selection'; @@ -489,3 +490,41 @@ export class StandaloneTelemetryService implements ITelemetryService { return null; } } + +export class SimpleWorkspaceContextService implements IWorkspaceContextService { + + public _serviceBrand: any; + + private readonly _onDidChangeFolders: Emitter = new Emitter(); + public readonly onDidChangeFolders: Event = this._onDidChangeFolders.event; + + private readonly folders: URI[]; + + constructor(private workspace?: Workspace) { + this.folders = workspace ? [workspace.resource] : []; + } + + public getFolders(): URI[] { + return this.folders; + } + + public getWorkspace(): IWorkspace { + return this.workspace; + } + + public hasWorkspace(): boolean { + return !!this.workspace; + } + + public isInsideWorkspace(resource: URI): boolean { + return this.workspace ? this.workspace.isInsideWorkspace(resource) : false; + } + + public toWorkspaceRelativePath(resource: URI, toOSPath?: boolean): string { + return this.workspace ? this.workspace.toWorkspaceRelativePath(resource, toOSPath) : null; + } + + public toResource(workspaceRelativePath: string): URI { + return this.workspace ? this.workspace.toResource(workspaceRelativePath) : null; + } +} \ No newline at end of file diff --git a/src/vs/editor/browser/standalone/standaloneServices.ts b/src/vs/editor/browser/standalone/standaloneServices.ts index 456290afa8d..0a50de37e9e 100644 --- a/src/vs/editor/browser/standalone/standaloneServices.ts +++ b/src/vs/editor/browser/standalone/standaloneServices.ts @@ -22,7 +22,7 @@ import { IMessageService } from 'vs/platform/message/common/message'; import { IProgressService } from 'vs/platform/progress/common/progress'; import { IStorageService, NullStorageService } from 'vs/platform/storage/common/storage'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; -import { IWorkspaceContextService, WorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import { ICodeEditorService } from 'vs/editor/common/services/codeEditorService'; import { IEditorWorkerService } from 'vs/editor/common/services/editorWorkerService'; import { EditorWorkerServiceImpl } from 'vs/editor/common/services/editorWorkerServiceImpl'; @@ -34,7 +34,7 @@ import { CodeEditorServiceImpl } from 'vs/editor/browser/services/codeEditorServ import { SimpleConfigurationService, SimpleMenuService, SimpleMessageService, SimpleProgressService, StandaloneCommandService, StandaloneKeybindingService, - StandaloneTelemetryService + StandaloneTelemetryService, SimpleWorkspaceContextService } from 'vs/editor/browser/standalone/simpleServices'; import { ContextKeyService } from 'vs/platform/contextkey/browser/contextKeyService'; import { IMenuService } from 'vs/platform/actions/common/actions'; @@ -118,7 +118,7 @@ export module StaticServices { const configurationServiceImpl = new SimpleConfigurationService(); export const configurationService = define(IConfigurationService, () => configurationServiceImpl); - export const contextService = define(IWorkspaceContextService, () => new WorkspaceContextService(configurationServiceImpl, new Workspace( + export const contextService = define(IWorkspaceContextService, () => new SimpleWorkspaceContextService(new Workspace( URI.from({ scheme: 'inmemory', authority: 'model', path: '/' }) ))); diff --git a/src/vs/platform/extensionManagement/test/common/extensionEnablementService.test.ts b/src/vs/platform/extensionManagement/test/common/extensionEnablementService.test.ts index 3ea2261d14a..01c5ab208cd 100644 --- a/src/vs/platform/extensionManagement/test/common/extensionEnablementService.test.ts +++ b/src/vs/platform/extensionManagement/test/common/extensionEnablementService.test.ts @@ -12,17 +12,16 @@ import { TestInstantiationService } from 'vs/platform/instantiation/test/common/ import { Emitter } from 'vs/base/common/event'; import { StorageService, InMemoryLocalStorage } from 'vs/platform/storage/common/storageService'; import { IStorageService } from 'vs/platform/storage/common/storage'; -import { IWorkspaceContextService, WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { TestContextService } from 'vs/workbench/test/workbenchTestServices'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; -import { TestWorkspace } from 'vs/platform/workspace/test/common/testWorkspace'; function storageService(instantiationService: TestInstantiationService): IStorageService { let service = instantiationService.get(IStorageService); if (!service) { let workspaceContextService = instantiationService.get(IWorkspaceContextService); if (!workspaceContextService) { - workspaceContextService = instantiationService.stub(IWorkspaceContextService, WorkspaceContextService); - instantiationService.stub(IWorkspaceContextService, 'getWorkspace', TestWorkspace); + workspaceContextService = instantiationService.stub(IWorkspaceContextService, new TestContextService()); } service = instantiationService.stub(IStorageService, instantiationService.createInstance(StorageService, new InMemoryLocalStorage(), new InMemoryLocalStorage())); } diff --git a/src/vs/platform/storage/test/storageService.test.ts b/src/vs/platform/storage/test/storageService.test.ts index ed156bfabc7..2be5dff0a16 100644 --- a/src/vs/platform/storage/test/storageService.test.ts +++ b/src/vs/platform/storage/test/storageService.test.ts @@ -6,11 +6,11 @@ 'use strict'; import * as assert from 'assert'; -import { clone } from 'vs/base/common/objects'; import { TestInstantiationService } from 'vs/platform/instantiation/test/common/instantiationServiceMock'; import { StorageScope } from 'vs/platform/storage/common/storage'; -import { IWorkspaceContextService, WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import { StorageService, InMemoryLocalStorage } from 'vs/platform/storage/common/storageService'; +import { TestContextService } from 'vs/workbench/test/workbenchTestServices'; import { TestWorkspace } from 'vs/platform/workspace/test/common/testWorkspace'; suite('Workbench StorageSevice', () => { @@ -19,8 +19,7 @@ suite('Workbench StorageSevice', () => { setup(() => { instantiationService = new TestInstantiationService(); - contextService = instantiationService.stub(IWorkspaceContextService, WorkspaceContextService); - instantiationService.stub(IWorkspaceContextService, 'getWorkspace', TestWorkspace); + contextService = instantiationService.stub(IWorkspaceContextService, new TestContextService()); }); test('Swap Data with undefined default value', () => { @@ -94,10 +93,8 @@ suite('Workbench StorageSevice', () => { assert.strictEqual(s.get('wkey1', StorageScope.WORKSPACE), 'foo'); assert.strictEqual(s.get('wkey2', StorageScope.WORKSPACE), 'foo2'); - let ws: any = clone(TestWorkspace); - ws.uid = new Date().getTime() + 100; - instantiationService.stub(IWorkspaceContextService, 'getWorkspace', ws); - s = new StorageService(storageImpl, null, contextService.getWorkspace()); + let ws: any = new Workspace(TestWorkspace.resource, new Date().getTime() + 100, TestWorkspace.name); + s = new StorageService(storageImpl, null, ws); assert.strictEqual(s.get('key1', StorageScope.GLOBAL), 'foobar'); assert.strictEqual(s.get('key1', StorageScope.WORKSPACE, null), null); diff --git a/src/vs/platform/telemetry/test/electron-browser/commonProperties.test.ts b/src/vs/platform/telemetry/test/electron-browser/commonProperties.test.ts index 61a93db8637..a5c00cac8c8 100644 --- a/src/vs/platform/telemetry/test/electron-browser/commonProperties.test.ts +++ b/src/vs/platform/telemetry/test/electron-browser/commonProperties.test.ts @@ -6,12 +6,11 @@ import * as assert from 'assert'; import { TPromise } from 'vs/base/common/winjs.base'; -import { TestInstantiationService } from 'vs/platform/instantiation/test/common/instantiationServiceMock'; import { resolveWorkbenchCommonProperties } from 'vs/platform/telemetry/node/workbenchCommonProperties'; -import { IWorkspaceContextService, WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { StorageService, InMemoryLocalStorage } from 'vs/platform/storage/common/storageService'; import { TestWorkspace } from 'vs/platform/workspace/test/common/testWorkspace'; + suite('Telemetry - common properties', function () { const commit = void 0; @@ -19,10 +18,7 @@ suite('Telemetry - common properties', function () { let storageService; setup(() => { - let instantiationService = new TestInstantiationService(); - let contextService = instantiationService.stub(IWorkspaceContextService, WorkspaceContextService); - instantiationService.stub(IWorkspaceContextService, 'getWorkspace', TestWorkspace); - storageService = new StorageService(new InMemoryLocalStorage(), null, contextService.getWorkspace()); + storageService = new StorageService(new InMemoryLocalStorage(), null, TestWorkspace); }); test('default', function () { diff --git a/src/vs/platform/workspace/common/workspace.ts b/src/vs/platform/workspace/common/workspace.ts index b74d8fd31d9..a1ccdac3e62 100644 --- a/src/vs/platform/workspace/common/workspace.ts +++ b/src/vs/platform/workspace/common/workspace.ts @@ -9,11 +9,7 @@ import { createDecorator } from 'vs/platform/instantiation/common/instantiation' import paths = require('vs/base/common/paths'); import { isEqualOrParent } from 'vs/platform/files/common/files'; import { isLinux } from 'vs/base/common/platform'; -import Event, { Emitter } from 'vs/base/common/event'; -import { IConfigurationService } from "vs/platform/configuration/common/configuration"; -import { IDisposable, dispose } from "vs/base/common/lifecycle"; -import { distinct, equals } from "vs/base/common/arrays"; -import { Schemas } from "vs/base/common/network"; +import Event from 'vs/base/common/event'; export const IWorkspaceContextService = createDecorator('contextService'); @@ -120,97 +116,4 @@ export class Workspace implements IWorkspace { public toJSON() { return { resource: this._resource, uid: this._uid, name: this._name }; } -} - -type IWorkspaceConfiguration = { [rootFolder: string]: { folders: string[]; } }; - -export class WorkspaceContextService implements IWorkspaceContextService { - - public _serviceBrand: any; - - private readonly _onDidChangeFolders: Emitter = new Emitter(); - public readonly onDidChangeFolders: Event = this._onDidChangeFolders.event; - - private folders: URI[]; - private toDispose: IDisposable[]; - - constructor(private configurationService: IConfigurationService, private workspace?: Workspace) { - this.toDispose = []; - - this.toDispose.push(this._onDidChangeFolders); - - this.folders = workspace ? [workspace.resource] : []; - - this.resolveAdditionalFolders(); - - this.registerListeners(); - } - - private registerListeners(): void { - this.toDispose.push(this.configurationService.onDidUpdateConfiguration(e => this.onDidUpdateConfiguration())); - } - - private onDidUpdateConfiguration(): void { - this.resolveAdditionalFolders(true); - } - - private resolveAdditionalFolders(notify?: boolean): void { - if (!this.workspace) { - return; // no additional folders for empty workspaces - } - - // Resovled configured folders for workspace - let configuredFolders: URI[] = [this.workspace.resource]; - const config = this.configurationService.getConfiguration('workspace'); - if (config) { - const workspaceConfig = config[this.workspace.resource.toString()]; - if (workspaceConfig) { - const additionalFolders = workspaceConfig.folders - .map(f => URI.parse(f)) - .filter(r => r.scheme === Schemas.file); // only support files for now - - configuredFolders.push(...additionalFolders); - } - } - - // Remove duplicates - configuredFolders = distinct(configuredFolders, r => r.toString()); - - // Find changes - const changed = !equals(this.folders, configuredFolders, (r1, r2) => r1.toString() === r2.toString()); - - this.folders = configuredFolders; - - if (notify && changed) { - this._onDidChangeFolders.fire(configuredFolders); - } - } - - public getFolders(): URI[] { - return this.folders; - } - - public getWorkspace(): IWorkspace { - return this.workspace; - } - - public hasWorkspace(): boolean { - return !!this.workspace; - } - - public isInsideWorkspace(resource: URI): boolean { - return this.workspace ? this.workspace.isInsideWorkspace(resource) : false; - } - - public toWorkspaceRelativePath(resource: URI, toOSPath?: boolean): string { - return this.workspace ? this.workspace.toWorkspaceRelativePath(resource, toOSPath) : null; - } - - public toResource(workspaceRelativePath: string): URI { - return this.workspace ? this.workspace.toResource(workspaceRelativePath) : null; - } - - public dispose(): void { - dispose(this.toDispose); - } } \ No newline at end of file diff --git a/src/vs/workbench/parts/extensions/test/electron-browser/extensionsActions.test.ts b/src/vs/workbench/parts/extensions/test/electron-browser/extensionsActions.test.ts index 084d5a3ad71..405be3a135f 100644 --- a/src/vs/workbench/parts/extensions/test/electron-browser/extensionsActions.test.ts +++ b/src/vs/workbench/parts/extensions/test/electron-browser/extensionsActions.test.ts @@ -28,10 +28,9 @@ import { IPager } from 'vs/base/common/paging'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { NullTelemetryService } from 'vs/platform/telemetry/common/telemetryUtils'; import { IExtensionService } from 'vs/platform/extensions/common/extensions'; -import { IWorkspaceContextService, WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; -import { TestWorkspace } from 'vs/platform/workspace/test/common/testWorkspace'; +import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { TestContextService } from 'vs/workbench/test/workbenchTestServices'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { TestConfigurationService } from "vs/platform/configuration/test/common/testConfigurationService"; suite('ExtensionsActions Test', () => { @@ -53,7 +52,7 @@ suite('ExtensionsActions Test', () => { instantiationService.stub(IURLService, { onOpenURL: new Emitter().event }); instantiationService.stub(ITelemetryService, NullTelemetryService); - instantiationService.set(IWorkspaceContextService, new WorkspaceContextService(new TestConfigurationService(), TestWorkspace)); + instantiationService.stub(IWorkspaceContextService, new TestContextService()); instantiationService.stub(IConfigurationService, { onDidUpdateConfiguration: () => { }, getConfiguration: () => ({}) }); instantiationService.stub(IExtensionGalleryService, ExtensionGalleryService); diff --git a/src/vs/workbench/parts/extensions/test/electron-browser/extensionsWorkbenchService.test.ts b/src/vs/workbench/parts/extensions/test/electron-browser/extensionsWorkbenchService.test.ts index 15ba37559d7..3cfe083cd16 100644 --- a/src/vs/workbench/parts/extensions/test/electron-browser/extensionsWorkbenchService.test.ts +++ b/src/vs/workbench/parts/extensions/test/electron-browser/extensionsWorkbenchService.test.ts @@ -28,11 +28,10 @@ import Event, { Emitter } from 'vs/base/common/event'; import { IPager } from 'vs/base/common/paging'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { NullTelemetryService } from 'vs/platform/telemetry/common/telemetryUtils'; -import { IWorkspaceContextService, WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; -import { TestWorkspace } from 'vs/platform/workspace/test/common/testWorkspace'; +import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { TestContextService } from 'vs/workbench/test/workbenchTestServices'; import { IChoiceService } from 'vs/platform/message/common/message'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { TestConfigurationService } from "vs/platform/configuration/test/common/testConfigurationService"; suite('ExtensionsWorkbenchService Test', () => { @@ -56,7 +55,7 @@ suite('ExtensionsWorkbenchService Test', () => { instantiationService.stub(IExtensionGalleryService, ExtensionGalleryService); - instantiationService.set(IWorkspaceContextService, new WorkspaceContextService(new TestConfigurationService(), TestWorkspace)); + instantiationService.stub(IWorkspaceContextService, new TestContextService()); instantiationService.stub(IConfigurationService, { onDidUpdateConfiguration: () => { }, getConfiguration: () => ({}) }); instantiationService.stub(IExtensionManagementService, ExtensionManagementService); diff --git a/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts b/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts index 3670f2a79f9..1c6a4f13b79 100644 --- a/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts +++ b/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts @@ -8,12 +8,12 @@ import * as assert from 'assert'; import { Platform } from 'vs/base/common/platform'; import { TerminalLinkHandler, LineColumnInfo } from 'vs/workbench/parts/terminal/electron-browser/terminalLinkHandler'; -import { WorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; +import { Workspace } from 'vs/platform/workspace/common/workspace'; +import { TestContextService } from 'vs/workbench/test/workbenchTestServices'; import URI from 'vs/base/common/uri'; import * as strings from 'vs/base/common/strings'; import * as path from 'path'; import * as sinon from 'sinon'; -import { TestConfigurationService } from "vs/platform/configuration/test/common/testConfigurationService"; class TestTerminalLinkHandler extends TerminalLinkHandler { public get localLinkRegex(): RegExp { @@ -176,7 +176,7 @@ suite('Workbench - TerminalLinkHandler', () => { suite('preprocessPath', () => { test('Windows', () => { const linkHandler = new TestTerminalLinkHandler(new TestXterm(), Platform.Windows, null, null, - new WorkspaceContextService(new TestConfigurationService(), new TestWorkspace('C:\\base'))); + new TestContextService(new TestWorkspace('C:\\base'))); let stub = sinon.stub(path, 'join', function (arg1, arg2) { return arg1 + '\\' + arg2; @@ -190,7 +190,7 @@ suite('Workbench - TerminalLinkHandler', () => { test('Linux', () => { const linkHandler = new TestTerminalLinkHandler(new TestXterm(), Platform.Linux, null, null, - new WorkspaceContextService(new TestConfigurationService(), new TestWorkspace('/base'))); + new TestContextService(new TestWorkspace('/base'))); let stub = sinon.stub(path, 'join', function (arg1, arg2) { return arg1 + '/' + arg2; @@ -203,7 +203,7 @@ suite('Workbench - TerminalLinkHandler', () => { }); test('No Workspace', () => { - const linkHandler = new TestTerminalLinkHandler(new TestXterm(), Platform.Linux, null, null, new WorkspaceContextService(new TestConfigurationService())); + const linkHandler = new TestTerminalLinkHandler(new TestXterm(), Platform.Linux, null, null, new TestContextService(null)); assert.equal(linkHandler.preprocessPath('./src/file1'), null); assert.equal(linkHandler.preprocessPath('src/file2'), null); diff --git a/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts b/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts index 86e267938fe..7e7eb3de7af 100644 --- a/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts +++ b/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts @@ -15,13 +15,13 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { Registry } from 'vs/platform/platform'; import { ParsedArgs, IEnvironmentService } from 'vs/platform/environment/common/environment'; import { parseArgs } from 'vs/platform/environment/node/argv'; -import { WorkspaceContextService, IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import { EnvironmentService } from 'vs/platform/environment/node/environmentService'; import extfs = require('vs/base/node/extfs'); import { TestTextFileService, TestEditorGroupService, TestLifecycleService, TestBackupFileService } from 'vs/workbench/test/workbenchTestServices'; import uuid = require('vs/base/common/uuid'); import { IConfigurationRegistry, Extensions as ConfigurationExtensions } from 'vs/platform/configuration/common/configurationRegistry'; -import { WorkspaceConfigurationService } from 'vs/workbench/services/configuration/node/configurationService'; +import { WorkspaceService } from 'vs/workbench/services/workspace/node/workspace'; import URI from 'vs/base/common/uri'; import { FileService } from 'vs/workbench/services/files/node/fileService'; import { ConfigurationEditingService } from 'vs/workbench/services/configuration/node/configurationEditingService'; @@ -116,9 +116,9 @@ suite('ConfigurationEditingService', () => { const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); instantiationService.stub(IEnvironmentService, environmentService); const workspace = noWorkspace ? null : new Workspace(URI.file(workspaceDir)); - const configurationService = new WorkspaceConfigurationService(environmentService, workspace); - instantiationService.stub(IWorkspaceContextService, new WorkspaceContextService(configurationService, workspace)); - instantiationService.stub(IConfigurationService, configurationService); + const workspaceService = new WorkspaceService(environmentService, workspace); + instantiationService.stub(IWorkspaceContextService, workspaceService); + instantiationService.stub(IConfigurationService, workspaceService); instantiationService.stub(ILifecycleService, new TestLifecycleService()); instantiationService.stub(IEditorGroupService, new TestEditorGroupService()); instantiationService.stub(ITelemetryService, NullTelemetryService); @@ -140,7 +140,7 @@ suite('ConfigurationEditingService', () => { }); testObject = instantiationService.createInstance(ConfigurationEditingService); - return configurationService.initialize(); + return workspaceService.initialize(); } teardown(() => { @@ -150,7 +150,7 @@ suite('ConfigurationEditingService', () => { function clearServices(): void { if (instantiationService) { - const configuraitonService = instantiationService.get(IConfigurationService); + const configuraitonService = instantiationService.get(IConfigurationService); if (configuraitonService) { configuraitonService.dispose(); } diff --git a/src/vs/workbench/test/browser/part.test.ts b/src/vs/workbench/test/browser/part.test.ts index 37277b67a78..6aeb1db693b 100644 --- a/src/vs/workbench/test/browser/part.test.ts +++ b/src/vs/workbench/test/browser/part.test.ts @@ -9,12 +9,10 @@ import * as assert from 'assert'; import { Build, Builder } from 'vs/base/browser/builder'; import { Part } from 'vs/workbench/browser/part'; import * as Types from 'vs/base/common/types'; -import { IWorkspaceContextService, WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { IStorageService } from 'vs/platform/storage/common/storage'; import { StorageService, InMemoryLocalStorage } from 'vs/platform/storage/common/storageService'; -import { TestWorkspace } from 'vs/platform/workspace/test/common/testWorkspace'; import { TestThemeService } from 'vs/workbench/test/workbenchTestServices'; -import { TestConfigurationService } from "vs/platform/configuration/test/common/testConfigurationService"; +import { TestWorkspace } from 'vs/platform/workspace/test/common/testWorkspace'; class MyPart extends Part { @@ -85,15 +83,13 @@ class MyPart3 extends Part { suite('Workbench Part', () => { let fixture: HTMLElement; let fixtureId = 'workbench-part-fixture'; - let context: IWorkspaceContextService; let storage: IStorageService; setup(() => { fixture = document.createElement('div'); fixture.id = fixtureId; document.body.appendChild(fixture); - context = new WorkspaceContextService(new TestConfigurationService(), TestWorkspace); - storage = new StorageService(new InMemoryLocalStorage(), null, context.getWorkspace()); + storage = new StorageService(new InMemoryLocalStorage(), null, TestWorkspace); }); teardown(() => { diff --git a/src/vs/workbench/test/common/memento.test.ts b/src/vs/workbench/test/common/memento.test.ts index c21ce5f9036..78edf69863c 100644 --- a/src/vs/workbench/test/common/memento.test.ts +++ b/src/vs/workbench/test/common/memento.test.ts @@ -6,20 +6,18 @@ 'use strict'; import * as assert from 'assert'; -import { WorkspaceContextService } from 'vs/platform/workspace/common/workspace'; + import { StorageScope } from 'vs/platform/storage/common/storage'; -import { TestWorkspace } from 'vs/platform/workspace/test/common/testWorkspace'; import { Memento, Scope } from 'vs/workbench/common/memento'; import { StorageService, InMemoryLocalStorage } from 'vs/platform/storage/common/storageService'; -import { TestConfigurationService } from "vs/platform/configuration/test/common/testConfigurationService"; +import { TestWorkspace } from 'vs/platform/workspace/test/common/testWorkspace'; suite('Workbench Memento', () => { let context; let storage; setup(() => { - context = new WorkspaceContextService(new TestConfigurationService(), TestWorkspace); - storage = new StorageService(new InMemoryLocalStorage(), null, context.getWorkspace()); + storage = new StorageService(new InMemoryLocalStorage(), null, TestWorkspace); }); test('Loading and Saving Memento with Scopes', () => { diff --git a/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts b/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts index 26a08ffd11b..c0c8221a118 100644 --- a/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts +++ b/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts @@ -7,7 +7,7 @@ import 'vs/workbench/parts/search/browser/search.contribution'; // load contributions import * as assert from 'assert'; -import { WorkspaceContextService, IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import { createSyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { ISearchService } from 'vs/platform/search/common/search'; @@ -21,7 +21,7 @@ import { QuickOpenHandler, IQuickOpenRegistry, Extensions } from 'vs/workbench/b import { Registry } from 'vs/platform/platform'; import { SearchService } from 'vs/workbench/services/search/node/searchService'; import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; -import { TestEnvironmentService, TestEditorService, TestEditorGroupService } from 'vs/workbench/test/workbenchTestServices'; +import { TestEnvironmentService, TestEditorService, TestEditorGroupService, TestContextService } from 'vs/workbench/test/workbenchTestServices'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { TPromise } from 'vs/base/common/winjs.base'; import URI from 'vs/base/common/uri'; @@ -31,7 +31,6 @@ import { IConfigurationService } from 'vs/platform/configuration/common/configur import { ModelServiceImpl } from 'vs/editor/common/services/modelServiceImpl'; import { IModelService } from 'vs/editor/common/services/modelService'; - namespace Timer { export interface ITimerEvent { id: number; @@ -73,7 +72,7 @@ suite('QuickOpen performance (integration)', () => { [ITelemetryService, telemetryService], [IConfigurationService, configurationService], [IModelService, new ModelServiceImpl(null, configurationService)], - [IWorkspaceContextService, new WorkspaceContextService(configurationService, new Workspace(URI.file(testWorkspacePath)))], + [IWorkspaceContextService, new TestContextService(new Workspace(URI.file(testWorkspacePath)))], [IWorkbenchEditorService, new TestEditorService()], [IEditorGroupService, new TestEditorGroupService()], [IEnvironmentService, TestEnvironmentService], diff --git a/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts b/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts index 64f77fcc9c9..cda4052f987 100644 --- a/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts +++ b/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts @@ -8,7 +8,7 @@ import 'vs/workbench/parts/search/browser/search.contribution'; // load contributions import * as assert from 'assert'; import * as fs from 'fs'; -import { WorkspaceContextService, IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; import { createSyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { ISearchService, IQueryOptions } from 'vs/platform/search/common/search'; @@ -20,7 +20,7 @@ import * as minimist from 'minimist'; import * as path from 'path'; import { SearchService } from 'vs/workbench/services/search/node/searchService'; import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; -import { TestEnvironmentService, TestEditorService, TestEditorGroupService } from 'vs/workbench/test/workbenchTestServices'; +import { TestEnvironmentService, TestEditorService, TestEditorGroupService, TestContextService } from 'vs/workbench/test/workbenchTestServices'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { TPromise } from 'vs/base/common/winjs.base'; import URI from 'vs/base/common/uri'; @@ -62,7 +62,7 @@ suite('TextSearch performance (integration)', () => { [ITelemetryService, telemetryService], [IConfigurationService, configurationService], [IModelService, new ModelServiceImpl(null, configurationService)], - [IWorkspaceContextService, new WorkspaceContextService(configurationService, new Workspace(URI.file(testWorkspacePath)))], + [IWorkspaceContextService, new TestContextService(new Workspace(URI.file(testWorkspacePath)))], [IWorkbenchEditorService, new TestEditorService()], [IEditorGroupService, new TestEditorGroupService()], [IEnvironmentService, TestEnvironmentService], -- GitLab From 2e2addebf7b8a4ec73b6d451fea6ef8095012ceb Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Tue, 13 Jun 2017 12:40:25 +0200 Subject: [PATCH 0764/1347] #28538 Remove existing workspace configuration service. Update tests. --- src/vs/workbench/electron-browser/main.ts | 12 +- .../workbench/electron-browser/workbench.ts | 2 +- .../node/configuration.ts} | 4 +- .../node/configurationService.ts | 357 ------------------ .../node/nullConfigurationService.ts | 44 --- ...nService.test.ts => configuration.test.ts} | 2 +- .../node/configurationEditingService.test.ts | 6 +- 7 files changed, 13 insertions(+), 414 deletions(-) rename src/vs/workbench/services/{workspace/node/workspace.ts => configuration/node/configuration.ts} (98%) delete mode 100644 src/vs/workbench/services/configuration/node/configurationService.ts delete mode 100644 src/vs/workbench/services/configuration/node/nullConfigurationService.ts rename src/vs/workbench/services/configuration/test/node/{configurationService.test.ts => configuration.test.ts} (99%) diff --git a/src/vs/workbench/electron-browser/main.ts b/src/vs/workbench/electron-browser/main.ts index 26d301a6ded..cf9c5e45db7 100644 --- a/src/vs/workbench/electron-browser/main.ts +++ b/src/vs/workbench/electron-browser/main.ts @@ -19,7 +19,7 @@ import uri from 'vs/base/common/uri'; import strings = require('vs/base/common/strings'); import { IResourceInput } from 'vs/platform/editor/common/editor'; import { Workspace } from 'vs/platform/workspace/common/workspace'; -import { WorkspaceService } from 'vs/workbench/services/configuration/node/configuration'; +import { WorkspaceConfigurationService } from 'vs/workbench/services/configuration/node/configuration'; import { realpath, stat } from 'vs/base/node/pfs'; import { EnvironmentService } from 'vs/platform/environment/node/environmentService'; import path = require('path'); @@ -129,12 +129,12 @@ function getWorkspace(workspacePath: string): TPromise { function openWorkbench(configuration: IWindowConfiguration, workspace: Workspace, options: IOptions): TPromise { const environmentService = new EnvironmentService(configuration, configuration.execPath); - const workspaceService = new WorkspaceService(environmentService, workspace); - const timerService = new TimerService((window).MonacoEnvironment.timers as IInitData, !workspaceService.hasWorkspace()); + const workspaceConfigurationService = new WorkspaceConfigurationService(environmentService, workspace); + const timerService = new TimerService((window).MonacoEnvironment.timers as IInitData, !workspaceConfigurationService.hasWorkspace()); // Since the configuration service is one of the core services that is used in so many places, we initialize it // right before startup of the workbench shell to have its data ready for consumers - return workspaceService.initialize().then(() => { + return workspaceConfigurationService.initialize().then(() => { timerService.beforeDOMContentLoaded = Date.now(); return domContentLoaded().then(() => { @@ -143,8 +143,8 @@ function openWorkbench(configuration: IWindowConfiguration, workspace: Workspace // Open Shell timerService.beforeWorkbenchOpen = Date.now(); const shell = new WorkbenchShell(document.body, { - contextService: workspaceService, - configurationService: workspaceService, + contextService: workspaceConfigurationService, + configurationService: workspaceConfigurationService, environmentService, timerService }, configuration, options); diff --git a/src/vs/workbench/electron-browser/workbench.ts b/src/vs/workbench/electron-browser/workbench.ts index d5b3f3bd621..a8afe425a03 100644 --- a/src/vs/workbench/electron-browser/workbench.ts +++ b/src/vs/workbench/electron-browser/workbench.ts @@ -47,7 +47,7 @@ import { IStorageService, StorageScope } from 'vs/platform/storage/common/storag import { ContextMenuService } from 'vs/workbench/services/contextview/electron-browser/contextmenuService'; import { WorkbenchKeybindingService } from 'vs/workbench/services/keybinding/electron-browser/keybindingService'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { WorkspaceConfigurationService } from 'vs/workbench/services/configuration/node/configurationService'; +import { WorkspaceConfigurationService } from 'vs/workbench/services/configuration/node/configuration'; import { IConfigurationEditingService } from 'vs/workbench/services/configuration/common/configurationEditing'; import { ConfigurationEditingService } from 'vs/workbench/services/configuration/node/configurationEditingService'; import { ContextKeyService } from 'vs/platform/contextkey/browser/contextKeyService'; diff --git a/src/vs/workbench/services/workspace/node/workspace.ts b/src/vs/workbench/services/configuration/node/configuration.ts similarity index 98% rename from src/vs/workbench/services/workspace/node/workspace.ts rename to src/vs/workbench/services/configuration/node/configuration.ts index 85f411d715c..4f0baaf5ba0 100644 --- a/src/vs/workbench/services/workspace/node/workspace.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -44,7 +44,7 @@ interface IWorkspaceConfiguration { type IWorkspaceFoldersConfiguration = { [rootFolder: string]: { folders: string[]; } }; -export class WorkspaceService extends Disposable implements IWorkspaceContextService, IWorkspaceConfigurationService { +export class WorkspaceConfigurationService extends Disposable implements IWorkspaceContextService, IWorkspaceConfigurationService { private static RELOAD_CONFIGURATION_DELAY = 50; @@ -83,7 +83,7 @@ export class WorkspaceService extends Disposable implements IWorkspaceContextSer source: ConfigurationSource.Workspace, sourceConfig: config.workspace })) - .done(null, errors.onUnexpectedError), WorkspaceService.RELOAD_CONFIGURATION_DELAY)); + .done(null, errors.onUnexpectedError), WorkspaceConfigurationService.RELOAD_CONFIGURATION_DELAY)); this._register(this.baseConfigurationService.onDidUpdateConfiguration(e => this.onBaseConfigurationChanged(e))); this._register(this.onDidUpdateConfiguration(e => this.resolveAdditionalFolders(true))); diff --git a/src/vs/workbench/services/configuration/node/configurationService.ts b/src/vs/workbench/services/configuration/node/configurationService.ts deleted file mode 100644 index 7001b1bb00d..00000000000 --- a/src/vs/workbench/services/configuration/node/configurationService.ts +++ /dev/null @@ -1,357 +0,0 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ - -'use strict'; - -import { TPromise } from 'vs/base/common/winjs.base'; -import uri from 'vs/base/common/uri'; -import paths = require('vs/base/common/paths'); -import extfs = require('vs/base/node/extfs'); -import objects = require('vs/base/common/objects'); -import { RunOnceScheduler } from 'vs/base/common/async'; -import collections = require('vs/base/common/collections'); -import { IEnvironmentService } from 'vs/platform/environment/common/environment'; -import { IDisposable, Disposable } from 'vs/base/common/lifecycle'; -import { readFile } from 'vs/base/node/pfs'; -import errors = require('vs/base/common/errors'); -import { ScopedConfigModel, WorkspaceConfigModel, WorkspaceSettingsConfigModel } from 'vs/workbench/services/configuration/common/configurationModels'; -import { IConfigurationServiceEvent, ConfigurationSource, getConfigurationValue, IConfigModel, IConfigurationOptions } from 'vs/platform/configuration/common/configuration'; -import { ConfigModel } from 'vs/platform/configuration/common/model'; -import { ConfigurationService as BaseConfigurationService } from 'vs/platform/configuration/node/configurationService'; -import { IWorkspaceConfigurationValues, IWorkspaceConfigurationService, IWorkspaceConfigurationValue, WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME, WORKSPACE_STANDALONE_CONFIGURATIONS, WORKSPACE_CONFIG_DEFAULT_PATH } from 'vs/workbench/services/configuration/common/configuration'; -import { FileChangeType, FileChangesEvent, isEqual } from 'vs/platform/files/common/files'; -import Event, { Emitter } from 'vs/base/common/event'; -import { Workspace } from "vs/platform/workspace/common/workspace"; - -interface IStat { - resource: uri; - isDirectory?: boolean; - children?: { resource: uri; }[]; -} - -interface IContent { - resource: uri; - value: string; -} - -interface IWorkspaceConfiguration { - workspace: T; - consolidated: any; -} - -/** - * Wraps around the basic configuration service and adds knowledge about workspace settings. - */ -export class WorkspaceConfigurationService extends Disposable implements IWorkspaceConfigurationService, IDisposable { - - public _serviceBrand: any; - - private static RELOAD_CONFIGURATION_DELAY = 50; - - private _onDidUpdateConfiguration: Emitter; - private baseConfigurationService: BaseConfigurationService; - - private cachedConfig: ConfigModel; - private cachedWorkspaceConfig: WorkspaceConfigModel; - - private bulkFetchFromWorkspacePromise: TPromise; - private workspaceFilePathToConfiguration: { [relativeWorkspacePath: string]: TPromise> }; - private reloadConfigurationScheduler: RunOnceScheduler; - - constructor( - private environmentService: IEnvironmentService, - private workspace?: Workspace, - private workspaceSettingsRootFolder: string = WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME - ) { - super(); - this.workspaceFilePathToConfiguration = Object.create(null); - - this.cachedConfig = new ConfigModel(null); - this.cachedWorkspaceConfig = new WorkspaceConfigModel(new WorkspaceSettingsConfigModel(null), []); - - this._onDidUpdateConfiguration = this._register(new Emitter()); - - this.baseConfigurationService = this._register(new BaseConfigurationService(environmentService)); - - this.reloadConfigurationScheduler = this._register(new RunOnceScheduler(() => this.doLoadConfiguration() - .then(config => this._onDidUpdateConfiguration.fire({ - config: config.consolidated, - source: ConfigurationSource.Workspace, - sourceConfig: config.workspace - })) - .done(null, errors.onUnexpectedError), WorkspaceConfigurationService.RELOAD_CONFIGURATION_DELAY)); - - this._register(this.baseConfigurationService.onDidUpdateConfiguration(e => this.onBaseConfigurationChanged(e))); - } - - get onDidUpdateConfiguration(): Event { - return this._onDidUpdateConfiguration.event; - } - - private onBaseConfigurationChanged(event: IConfigurationServiceEvent): void { - if (event.source === ConfigurationSource.Default) { - this.cachedWorkspaceConfig.update(); - } - - // update cached config when base config changes - const configModel = >this.baseConfigurationService.getCache().consolidated // global/default values (do NOT modify) - .merge(this.cachedWorkspaceConfig); // workspace configured values - - // emit this as update to listeners if changed - if (!objects.equals(this.cachedConfig.contents, configModel.contents)) { - this.cachedConfig = configModel; - this._onDidUpdateConfiguration.fire({ - config: this.cachedConfig.contents, - source: event.source, - sourceConfig: event.sourceConfig - }); - } - } - - public initialize(): TPromise { - return this.doLoadConfiguration().then(() => null); - } - - public getConfiguration(section?: string): C - public getConfiguration(options?: IConfigurationOptions): C - public getConfiguration(arg?: any): C { - const options = this.toOptions(arg); - const configModel = options.overrideIdentifier ? this.cachedConfig.configWithOverrides(options.overrideIdentifier) : this.cachedConfig; - return options.section ? configModel.getContentsFor(options.section) : configModel.contents; - } - - public lookup(key: string, overrideIdentifier?: string): IWorkspaceConfigurationValue { - const configurationValue = this.baseConfigurationService.lookup(key, overrideIdentifier); - return { - default: configurationValue.default, - user: configurationValue.user, - workspace: objects.clone(getConfigurationValue(overrideIdentifier ? this.cachedWorkspaceConfig.configWithOverrides(overrideIdentifier).contents : this.cachedWorkspaceConfig.contents, key)), - value: objects.clone(getConfigurationValue(overrideIdentifier ? this.cachedConfig.configWithOverrides(overrideIdentifier).contents : this.cachedConfig.contents, key)) - }; - } - - public keys() { - const keys = this.baseConfigurationService.keys(); - - return { - default: keys.default, - user: keys.user, - workspace: this.cachedWorkspaceConfig.keys - }; - } - - public values(): IWorkspaceConfigurationValues { - const result: IWorkspaceConfigurationValues = Object.create(null); - const keyset = this.keys(); - const keys = [...keyset.workspace, ...keyset.user, ...keyset.default].sort(); - - let lastKey: string; - for (const key of keys) { - if (key !== lastKey) { - lastKey = key; - result[key] = this.lookup(key); - } - } - - return result; - } - - public reloadConfiguration(section?: string): TPromise { - - // Reset caches to ensure we are hitting the disk - this.bulkFetchFromWorkspacePromise = null; - this.workspaceFilePathToConfiguration = Object.create(null); - - // Load configuration - return this.baseConfigurationService.reloadConfiguration().then(() => { - const current = this.cachedConfig; - return this.doLoadConfiguration().then(configuration => { - // emit this as update to listeners if changed - if (!objects.equals(current, this.cachedConfig)) { - this._onDidUpdateConfiguration.fire({ - config: configuration.consolidated, - source: ConfigurationSource.Workspace, - sourceConfig: configuration.workspace - }); - } - return section ? configuration.consolidated[section] : configuration.consolidated; - }); - }); - } - - private toOptions(arg: any): IConfigurationOptions { - if (typeof arg === 'string') { - return { section: arg }; - } - if (typeof arg === 'object') { - return arg; - } - return {}; - } - - private doLoadConfiguration(): TPromise> { - - // Load workspace locals - return this.loadWorkspaceConfigFiles().then(workspaceConfigFiles => { - - // Consolidate (support *.json files in the workspace settings folder) - const workspaceSettingsConfig = >workspaceConfigFiles[WORKSPACE_CONFIG_DEFAULT_PATH] || new WorkspaceSettingsConfigModel(null); - const otherConfigModels = Object.keys(workspaceConfigFiles).filter(key => key !== WORKSPACE_CONFIG_DEFAULT_PATH).map(key => >workspaceConfigFiles[key]); - this.cachedWorkspaceConfig = new WorkspaceConfigModel(workspaceSettingsConfig, otherConfigModels); - - // Override base (global < user) with workspace locals (global < user < workspace) - this.cachedConfig = >this.baseConfigurationService.getCache().consolidated // global/default values (do NOT modify) - .merge(this.cachedWorkspaceConfig); // workspace configured values - - return { - consolidated: this.cachedConfig.contents, - workspace: this.cachedWorkspaceConfig.contents - }; - }); - } - - private loadWorkspaceConfigFiles(): TPromise<{ [relativeWorkspacePath: string]: IConfigModel }> { - - // Return early if we don't have a workspace - if (!this.workspace) { - return TPromise.as(Object.create(null)); - } - - // once: when invoked for the first time we fetch json files that contribute settings - if (!this.bulkFetchFromWorkspacePromise) { - this.bulkFetchFromWorkspacePromise = resolveStat(this.workspace.toResource(this.workspaceSettingsRootFolder)).then(stat => { - if (!stat.isDirectory) { - return TPromise.as([]); - } - - return resolveContents(stat.children.filter(stat => { - const isJson = paths.extname(stat.resource.fsPath) === '.json'; - if (!isJson) { - return false; // only JSON files - } - - return this.isWorkspaceConfigurationFile(this.workspace.toWorkspaceRelativePath(stat.resource)); // only workspace config files - }).map(stat => stat.resource)); - }, err => [] /* never fail this call */) - .then((contents: IContent[]) => { - contents.forEach(content => this.workspaceFilePathToConfiguration[this.workspace.toWorkspaceRelativePath(content.resource)] = TPromise.as(this.createConfigModel(content))); - }, errors.onUnexpectedError); - } - - // on change: join on *all* configuration file promises so that we can merge them into a single configuration object. this - // happens whenever a config file changes, is deleted, or added - return this.bulkFetchFromWorkspacePromise.then(() => TPromise.join(this.workspaceFilePathToConfiguration)); - } - - public handleWorkspaceFileEvents(event: FileChangesEvent): void { - if (!this.workspace) { - return; // only enabled when we have a known workspace - } - - const events = event.changes; - let affectedByChanges = false; - - // Find changes that affect workspace configuration files - for (let i = 0, len = events.length; i < len; i++) { - const resource = events[i].resource; - const isJson = paths.extname(resource.fsPath) === '.json'; - const isDeletedSettingsFolder = (events[i].type === FileChangeType.DELETED && isEqual(paths.basename(resource.fsPath), this.workspaceSettingsRootFolder)); - if (!isJson && !isDeletedSettingsFolder) { - continue; // only JSON files or the actual settings folder - } - - const workspacePath = this.workspace.toWorkspaceRelativePath(resource); - if (!workspacePath) { - continue; // event is not inside workspace - } - - // Handle case where ".vscode" got deleted - if (workspacePath === this.workspaceSettingsRootFolder && events[i].type === FileChangeType.DELETED) { - this.workspaceFilePathToConfiguration = Object.create(null); - affectedByChanges = true; - } - - // only valid workspace config files - if (!this.isWorkspaceConfigurationFile(workspacePath)) { - continue; - } - - // insert 'fetch-promises' for add and update events and - // remove promises for delete events - switch (events[i].type) { - case FileChangeType.DELETED: - affectedByChanges = collections.remove(this.workspaceFilePathToConfiguration, workspacePath); - break; - case FileChangeType.UPDATED: - case FileChangeType.ADDED: - this.workspaceFilePathToConfiguration[workspacePath] = resolveContent(resource).then(content => this.createConfigModel(content), errors.onUnexpectedError); - affectedByChanges = true; - } - } - - // trigger reload of the configuration if we are affected by changes - if (affectedByChanges && !this.reloadConfigurationScheduler.isScheduled()) { - this.reloadConfigurationScheduler.schedule(); - } - } - - private createConfigModel(content: IContent): IConfigModel { - const path = this.workspace.toWorkspaceRelativePath(content.resource); - if (path === WORKSPACE_CONFIG_DEFAULT_PATH) { - return new WorkspaceSettingsConfigModel(content.value, content.resource.toString()); - } else { - const matches = /\/([^\.]*)*\.json/.exec(path); - if (matches && matches[1]) { - return new ScopedConfigModel(content.value, content.resource.toString(), matches[1]); - } - } - - return new ConfigModel(null); - } - - private isWorkspaceConfigurationFile(workspaceRelativePath: string): boolean { - return [WORKSPACE_CONFIG_DEFAULT_PATH, WORKSPACE_STANDALONE_CONFIGURATIONS.launch, WORKSPACE_STANDALONE_CONFIGURATIONS.tasks].some(p => p === workspaceRelativePath); - } - - public getUnsupportedWorkspaceKeys(): string[] { - return this.cachedWorkspaceConfig.workspaceSettingsConfig.unsupportedKeys; - } -} - -// node.hs helper functions - -function resolveContents(resources: uri[]): TPromise { - const contents: IContent[] = []; - - return TPromise.join(resources.map(resource => { - return resolveContent(resource).then(content => { - contents.push(content); - }); - })).then(() => contents); -} - -function resolveContent(resource: uri): TPromise { - return readFile(resource.fsPath).then(contents => ({ resource, value: contents.toString() })); -} - -function resolveStat(resource: uri): TPromise { - return new TPromise((c, e) => { - extfs.readdir(resource.fsPath, (error, children) => { - if (error) { - if ((error).code === 'ENOTDIR') { - c({ resource }); - } else { - e(error); - } - } else { - c({ - resource, - isDirectory: true, - children: children.map(child => { return { resource: uri.file(paths.join(resource.fsPath, child)) }; }) - }); - } - }); - }); -} \ No newline at end of file diff --git a/src/vs/workbench/services/configuration/node/nullConfigurationService.ts b/src/vs/workbench/services/configuration/node/nullConfigurationService.ts deleted file mode 100644 index c38b5b29b2e..00000000000 --- a/src/vs/workbench/services/configuration/node/nullConfigurationService.ts +++ /dev/null @@ -1,44 +0,0 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ - -'use strict'; - -import { IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, getConfigurationValue, IConfigurationKeys } from "vs/platform/configuration/common/configuration"; -import Event, { Emitter } from 'vs/base/common/event'; -import { TPromise } from "vs/base/common/winjs.base"; - -export class NullConfigurationService implements IConfigurationService { - - _serviceBrand: any; - - private _onDidUpdateConfiguration = new Emitter(); - public onDidUpdateConfiguration: Event = this._onDidUpdateConfiguration.event; - - private _config: any; - - constructor() { - this._config = Object.create(null); - } - - public getConfiguration(section?: any): T { - return this._config; - } - - public reloadConfiguration(section?: string): TPromise { - return TPromise.as(this.getConfiguration(section)); - } - - public lookup(key: string): IConfigurationValue { - return { - value: getConfigurationValue(this.getConfiguration(), key), - default: getConfigurationValue(this.getConfiguration(), key), - user: getConfigurationValue(this.getConfiguration(), key) - }; - } - - public keys(): IConfigurationKeys { - return { default: [], user: [] }; - } -} \ No newline at end of file diff --git a/src/vs/workbench/services/configuration/test/node/configurationService.test.ts b/src/vs/workbench/services/configuration/test/node/configuration.test.ts similarity index 99% rename from src/vs/workbench/services/configuration/test/node/configurationService.test.ts rename to src/vs/workbench/services/configuration/test/node/configuration.test.ts index c61238061d7..d7de49aba32 100644 --- a/src/vs/workbench/services/configuration/test/node/configurationService.test.ts +++ b/src/vs/workbench/services/configuration/test/node/configuration.test.ts @@ -19,7 +19,7 @@ import { parseArgs } from 'vs/platform/environment/node/argv'; import extfs = require('vs/base/node/extfs'); import uuid = require('vs/base/common/uuid'); import { IConfigurationRegistry, Extensions as ConfigurationExtensions } from 'vs/platform/configuration/common/configurationRegistry'; -import { WorkspaceConfigurationService } from 'vs/workbench/services/configuration/node/configurationService'; +import { WorkspaceConfigurationService } from 'vs/workbench/services/configuration/node/configuration'; import URI from 'vs/base/common/uri'; import { FileChangeType, FileChangesEvent } from 'vs/platform/files/common/files'; diff --git a/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts b/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts index 7e7eb3de7af..dfba23f324a 100644 --- a/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts +++ b/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts @@ -21,7 +21,7 @@ import extfs = require('vs/base/node/extfs'); import { TestTextFileService, TestEditorGroupService, TestLifecycleService, TestBackupFileService } from 'vs/workbench/test/workbenchTestServices'; import uuid = require('vs/base/common/uuid'); import { IConfigurationRegistry, Extensions as ConfigurationExtensions } from 'vs/platform/configuration/common/configurationRegistry'; -import { WorkspaceService } from 'vs/workbench/services/workspace/node/workspace'; +import { WorkspaceConfigurationService } from 'vs/workbench/services/configuration/node/configuration'; import URI from 'vs/base/common/uri'; import { FileService } from 'vs/workbench/services/files/node/fileService'; import { ConfigurationEditingService } from 'vs/workbench/services/configuration/node/configurationEditingService'; @@ -116,7 +116,7 @@ suite('ConfigurationEditingService', () => { const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); instantiationService.stub(IEnvironmentService, environmentService); const workspace = noWorkspace ? null : new Workspace(URI.file(workspaceDir)); - const workspaceService = new WorkspaceService(environmentService, workspace); + const workspaceService = new WorkspaceConfigurationService(environmentService, workspace); instantiationService.stub(IWorkspaceContextService, workspaceService); instantiationService.stub(IConfigurationService, workspaceService); instantiationService.stub(ILifecycleService, new TestLifecycleService()); @@ -150,7 +150,7 @@ suite('ConfigurationEditingService', () => { function clearServices(): void { if (instantiationService) { - const configuraitonService = instantiationService.get(IConfigurationService); + const configuraitonService = instantiationService.get(IConfigurationService); if (configuraitonService) { configuraitonService.dispose(); } -- GitLab From d9feff655e4947d3d5ae5692a59c8f7b9e44405d Mon Sep 17 00:00:00 2001 From: Yu <583181285@qq.com> Date: Tue, 13 Jun 2017 19:49:36 +0800 Subject: [PATCH 0765/1347] =?UTF-8?q?=F0=9F=92=9A=20fix=20tests=20for=20bl?= =?UTF-8?q?ock=20comment?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../test/common/blockCommentCommand.test.ts | 34 +++++++++---------- .../test/common/lineCommentCommand.test.ts | 24 ++++++------- 2 files changed, 29 insertions(+), 29 deletions(-) diff --git a/src/vs/editor/contrib/comment/test/common/blockCommentCommand.test.ts b/src/vs/editor/contrib/comment/test/common/blockCommentCommand.test.ts index 8f8f2cae118..1bd3597b7ac 100644 --- a/src/vs/editor/contrib/comment/test/common/blockCommentCommand.test.ts +++ b/src/vs/editor/contrib/comment/test/common/blockCommentCommand.test.ts @@ -28,13 +28,13 @@ suite('Editor Contrib - Block Comment Command', () => { ], new Selection(1, 3, 1, 3), [ - 'fi<00>rst', + 'fi<0 0>rst', '\tsecond line', 'third line', 'fourth line', 'fifth' ], - new Selection(1, 5, 1, 5) + new Selection(1, 6, 1, 6) ); }); @@ -49,13 +49,13 @@ suite('Editor Contrib - Block Comment Command', () => { ], new Selection(2, 1, 1, 1), [ - '<0first', - '0>\tsecond line', + '<0 first', + ' 0>\tsecond line', 'third line', 'fourth line', 'fifth' ], - new Selection(1, 3, 2, 1) + new Selection(1, 4, 2, 1) ); }); @@ -70,13 +70,13 @@ suite('Editor Contrib - Block Comment Command', () => { ], new Selection(1, 6, 1, 1), [ - '<0first0>', + '<0 first 0>', '\tsecond line', 'third line', 'fourth line', 'fifth' ], - new Selection(1, 3, 1, 8) + new Selection(1, 4, 1, 9) ); testBlockCommentCommand( @@ -110,13 +110,13 @@ suite('Editor Contrib - Block Comment Command', () => { ], new Selection(1, 6, 1, 3), [ - 'fi<0rst0>', + 'fi<0 rst 0>', '\tsecond line', 'third line', 'fourth line', 'fifth' ], - new Selection(1, 5, 1, 8) + new Selection(1, 6, 1, 9) ); }); @@ -131,13 +131,13 @@ suite('Editor Contrib - Block Comment Command', () => { ], new Selection(1, 6, 1, 3), [ - 'fi<0rst0>', + 'fi<0 rst 0>', '\tsecond line', 'third line', 'fourth line', 'fifth' ], - new Selection(1, 5, 1, 8) + new Selection(1, 6, 1, 9) ); testBlockCommentCommand( @@ -171,13 +171,13 @@ suite('Editor Contrib - Block Comment Command', () => { ], new Selection(2, 4, 1, 1), [ - '<0first', - '\tse0>cond line', + '<0 first', + '\tse 0>cond line', 'third line', 'fourth line', 'fifth' ], - new Selection(1, 3, 2, 4) + new Selection(1, 4, 2, 4) ); }); @@ -192,13 +192,13 @@ suite('Editor Contrib - Block Comment Command', () => { ], new Selection(2, 4, 1, 1), [ - '<0first', - '\tse0>cond line', + '<0 first', + '\tse 0>cond line', 'third line', 'fourth line', 'fifth' ], - new Selection(1, 3, 2, 4) + new Selection(1, 4, 2, 4) ); testBlockCommentCommand( diff --git a/src/vs/editor/contrib/comment/test/common/lineCommentCommand.test.ts b/src/vs/editor/contrib/comment/test/common/lineCommentCommand.test.ts index 64d900f1dd7..098872864e5 100644 --- a/src/vs/editor/contrib/comment/test/common/lineCommentCommand.test.ts +++ b/src/vs/editor/contrib/comment/test/common/lineCommentCommand.test.ts @@ -544,13 +544,13 @@ suite('Editor Contrib - Line Comment As Block Comment', () => { ], new Selection(1, 1, 1, 1), [ - '(first)', + '( first )', '\tsecond line', 'third line', 'fourth line', 'fifth' ], - new Selection(1, 2, 1, 2) + new Selection(1, 3, 1, 3) ); }); @@ -586,13 +586,13 @@ suite('Editor Contrib - Line Comment As Block Comment', () => { ], new Selection(1, 1, 1, 1), [ - '(first)', + '( first )', '\tsecond line', 'third line', 'fourth line', 'fifth' ], - new Selection(1, 2, 1, 2) + new Selection(1, 3, 1, 3) ); }); @@ -607,13 +607,13 @@ suite('Editor Contrib - Line Comment As Block Comment', () => { ], new Selection(3, 2, 1, 3), [ - '(first', + '( first', '\tsecond line', - 'third line)', + 'third line )', 'fourth line', 'fifth' ], - new Selection(1, 4, 3, 2) + new Selection(1, 5, 3, 2) ); testLineCommentCommand( @@ -655,7 +655,7 @@ suite('Editor Contrib - Line Comment As Block Comment 2', () => { ], new Selection(1, 1, 1, 1), [ - '\t\t', + '\t\t', '\t\tsecond line', '\tthird line', 'fourth line', @@ -809,8 +809,8 @@ suite('Editor Contrib - Line Comment As Block Comment 2', () => { ], new Selection(1, 1, 3, 1), [ - ' ', + ' ', '' ], new Selection(1, 1, 3, 1) @@ -927,13 +927,13 @@ suite('Editor Contrib - Line Comment in mixed modes', () => { [ 'import React from \'react\';', 'const Loader = () => (', - ' {/*
    */}', + ' {/*
    */}', ' Loading...', '
    ', ');', 'export default Loader;' ], - new Selection(3, 7, 3, 7), + new Selection(3, 8, 3, 8), ); }); -- GitLab From 91a0e04417cabaeda04bc20891d58ae338179f66 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Tue, 13 Jun 2017 14:25:03 +0200 Subject: [PATCH 0766/1347] Fix #28476 --- src/vs/workbench/parts/views/browser/viewsExtensionPoint.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/views/browser/viewsExtensionPoint.ts b/src/vs/workbench/parts/views/browser/viewsExtensionPoint.ts index 30715762ea6..769d2e9326d 100644 --- a/src/vs/workbench/parts/views/browser/viewsExtensionPoint.ts +++ b/src/vs/workbench/parts/views/browser/viewsExtensionPoint.ts @@ -41,7 +41,7 @@ namespace schema { return false; } if (typeof descriptor.name !== 'string') { - collector.error(localize('requirestring', "property `{0}` is mandatory and must be of type `string`", 'label')); + collector.error(localize('requirestring', "property `{0}` is mandatory and must be of type `string`", 'name')); return false; } if (descriptor.when && typeof descriptor.when !== 'string') { -- GitLab From 15564d7403e87b8688f0095c262a0d5c0a0d4267 Mon Sep 17 00:00:00 2001 From: Yu <583181285@qq.com> Date: Tue, 13 Jun 2017 20:29:26 +0800 Subject: [PATCH 0767/1347] =?UTF-8?q?=F0=9F=92=9A=20fix=20cursor=20pos?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/vs/editor/contrib/comment/common/blockCommentCommand.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/editor/contrib/comment/common/blockCommentCommand.ts b/src/vs/editor/contrib/comment/common/blockCommentCommand.ts index a8a8e54a1bb..d123d1f9d58 100644 --- a/src/vs/editor/contrib/comment/common/blockCommentCommand.ts +++ b/src/vs/editor/contrib/comment/common/blockCommentCommand.ts @@ -145,7 +145,7 @@ export class BlockCommentCommand implements editorCommon.ICommand { ); } else { var srcRange = inverseEditOperations[0].range; - var deltaColumn = this._usedEndToken ? -this._usedEndToken.length : 0; + var deltaColumn = this._usedEndToken ? -this._usedEndToken.length - 1 : 0; // minus 1 space before endToken return new Selection( srcRange.endLineNumber, srcRange.endColumn + deltaColumn, -- GitLab From 3a192e94d8cfecf8e0d59ba8ad738d09c57f8725 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Tue, 13 Jun 2017 14:55:38 +0200 Subject: [PATCH 0768/1347] Taking the top most available stack frame for exception widget. Resolves #27903 --- .../electron-browser/debugEditorContribution.ts | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.ts b/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.ts index 72c5ac93ee9..e33c15a909f 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.ts @@ -356,19 +356,25 @@ export class DebugEditorContribution implements IDebugEditorContribution { // Toggles exception widget based on the state of the current editor model and debug stack frame const model = this.editor.getModel(); const focusedSf = this.debugService.getViewModel().focusedStackFrame; - if (!model || !focusedSf || !focusedSf.source || !focusedSf.source.available) { + const callStack = focusedSf ? focusedSf.thread.getCallStack() : null; + if (!model || !focusedSf || !callStack || callStack.length === 0) { this.closeExceptionWidget(); return; } - const callStack = focusedSf.thread.getCallStack(); - if (!callStack || callStack.length === 0) { + // First call stack frame that is available is the frame where exception has been thrown + let exceptionSf; + for (let sf of callStack) { + if (sf.source && sf.source.available) { + exceptionSf = sf; + break; + } + } + if (!exceptionSf) { this.closeExceptionWidget(); return; } - // First call stack frame is the frame where exception has been thrown - const exceptionSf = callStack[0]; const sameUri = exceptionSf.source.uri.toString() === model.uri.toString(); if (this.exceptionWidget && !sameUri) { this.closeExceptionWidget(); -- GitLab From 09ad6343e1639774100c7b5c94bdc6fcfb393e53 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Tue, 13 Jun 2017 15:03:21 +0200 Subject: [PATCH 0769/1347] :lipstick: --- .../workbench/parts/views/browser/treeView.ts | 31 ++++++++++--------- 1 file changed, 17 insertions(+), 14 deletions(-) diff --git a/src/vs/workbench/parts/views/browser/treeView.ts b/src/vs/workbench/parts/views/browser/treeView.ts index fd5eb54fed1..b31b3f71a23 100644 --- a/src/vs/workbench/parts/views/browser/treeView.ts +++ b/src/vs/workbench/parts/views/browser/treeView.ts @@ -132,21 +132,24 @@ export class TreeView extends CollapsibleView { } private setInput(): TPromise { - if (this.tree && !this.treeInputPromise) { - if (this.listenToDataProvider()) { - this.treeInputPromise = this.tree.setInput(new Root()); - return this.treeInputPromise; + if (this.tree) { + if (!this.treeInputPromise) { + if (this.listenToDataProvider()) { + this.treeInputPromise = this.tree.setInput(new Root()); + } else { + this.treeInputPromise = new TPromise((c, e) => { + this.dataProviderRegisteredListener = ViewsRegistry.onTreeViewDataProviderRegistered(id => { + if (this.id === id) { + if (this.listenToDataProvider()) { + this.tree.setInput(new Root()).then(() => c(null)); + this.dataProviderRegisteredListener.dispose(); + } + } + }); + }); + } } - this.treeInputPromise = new TPromise((c, e) => { - this.dataProviderRegisteredListener = ViewsRegistry.onTreeViewDataProviderRegistered(id => { - if (this.id === id) { - if (this.listenToDataProvider()) { - this.tree.setInput(new Root()).then(() => c(null)); - this.dataProviderRegisteredListener.dispose(); - } - } - }); - }); + return this.treeInputPromise; } return TPromise.as(null); } -- GitLab From 083fc590df8065d035682bf212eb907a2f683073 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Tue, 13 Jun 2017 15:28:26 +0200 Subject: [PATCH 0770/1347] refactor tfs darwin builds --- build/tfs/darwin/build.sh | 23 ++--------------------- build/tfs/darwin/release.sh | 26 ++++++++++++++++++++++++++ build/tfs/darwin/smoketest.sh | 27 +++++++++++++++++++++++++++ 3 files changed, 55 insertions(+), 21 deletions(-) create mode 100755 build/tfs/darwin/release.sh create mode 100755 build/tfs/darwin/smoketest.sh diff --git a/build/tfs/darwin/build.sh b/build/tfs/darwin/build.sh index 1f569cf74f2..6397b310dca 100755 --- a/build/tfs/darwin/build.sh +++ b/build/tfs/darwin/build.sh @@ -30,24 +30,5 @@ step "Run unit tests" \ step "Run integration tests" \ ./scripts/test-integration.sh -(cd $BUILD_SOURCESDIRECTORY/build/tfs/common && \ - step "Install build dependencies" \ - npm i) - -REPO=`pwd` -ZIP=$REPO/../VSCode-darwin-selfsigned.zip -UNSIGNEDZIP=$REPO/../VSCode-darwin-unsigned.zip -BUILD=$REPO/../VSCode-darwin -PACKAGEJSON=`ls $BUILD/*.app/Contents/Resources/app/package.json` -VERSION=`node -p "require(\"$PACKAGEJSON\").version"` - -rm -rf $UNSIGNEDZIP -(cd $BUILD && \ - step "Create unsigned archive" \ - zip -r -X -y $UNSIGNEDZIP *) - -step "Upload unsigned archive" \ - node build/tfs/common/publish.js --upload-only $VSCODE_QUALITY darwin archive-unsigned VSCode-darwin-$VSCODE_QUALITY-unsigned.zip $VERSION false $UNSIGNEDZIP - -step "Sign build" \ - node build/tfs/common/enqueue.js $VSCODE_QUALITY \ No newline at end of file +step "Publish release" \ + ./build/tfs/darwin/release.sh \ No newline at end of file diff --git a/build/tfs/darwin/release.sh b/build/tfs/darwin/release.sh new file mode 100755 index 00000000000..24ed4c30a78 --- /dev/null +++ b/build/tfs/darwin/release.sh @@ -0,0 +1,26 @@ +#!/bin/sh + +. ./scripts/env.sh +. ./build/tfs/common/common.sh + +(cd $BUILD_SOURCESDIRECTORY/build/tfs/common && \ + step "Install build dependencies" \ + npm i) + +REPO=`pwd` +ZIP=$REPO/../VSCode-darwin-selfsigned.zip +UNSIGNEDZIP=$REPO/../VSCode-darwin-unsigned.zip +BUILD=$REPO/../VSCode-darwin +PACKAGEJSON=`ls $BUILD/*.app/Contents/Resources/app/package.json` +VERSION=`node -p "require(\"$PACKAGEJSON\").version"` + +rm -rf $UNSIGNEDZIP +(cd $BUILD && \ + step "Create unsigned archive" \ + zip -r -X -y $UNSIGNEDZIP *) + +step "Upload unsigned archive" \ + node build/tfs/common/publish.js --upload-only $VSCODE_QUALITY darwin archive-unsigned VSCode-darwin-$VSCODE_QUALITY-unsigned.zip $VERSION false $UNSIGNEDZIP + +step "Sign build" \ + node build/tfs/common/enqueue.js $VSCODE_QUALITY \ No newline at end of file diff --git a/build/tfs/darwin/smoketest.sh b/build/tfs/darwin/smoketest.sh new file mode 100755 index 00000000000..ae756d8ca35 --- /dev/null +++ b/build/tfs/darwin/smoketest.sh @@ -0,0 +1,27 @@ +#!/bin/sh + +. ./scripts/env.sh +. ./build/tfs/common/common.sh + +export VSCODE_MIXIN_PASSWORD="$1" +VSO_PAT="$2" + +echo "machine monacotools.visualstudio.com password $VSO_PAT" > ~/.netrc + +step "Install dependencies" \ + npm install + +step "Mix in repository from vscode-distro" \ + npm run gulp -- mixin + +step "Install distro dependencies" \ + node build/tfs/common/installDistro.js + +step "Build minified & upload source maps" \ + npm run gulp -- --max_old_space_size=4096 vscode-darwin-min + +step "Run unit tests" \ + ./scripts/test.sh --build --reporter dot + +step "Run integration tests" \ + ./scripts/test-integration.sh \ No newline at end of file -- GitLab From a401fee1823b0c701957f0a19bb1c9bc55da4f6b Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Tue, 13 Jun 2017 15:29:23 +0200 Subject: [PATCH 0771/1347] Fixes #28502: Channel closed error --- .../electron-browser/terminalInstance.ts | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index ab25e4dc0df..44a6c047dff 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -533,6 +533,7 @@ export class TerminalInstance implements ITerminalInstance { } this._isExiting = true; + this._process = null; let exitCodeMessage: string; if (exitCode) { exitCodeMessage = nls.localize('terminal.integrated.exitedWithCode', 'The terminal process terminated with exit code: {0}', exitCode); @@ -765,11 +766,19 @@ export class TerminalInstance implements ITerminalInstance { } this._processReady.then(() => { if (this._process) { - this._process.send({ - event: 'resize', - cols: this._cols, - rows: this._rows - }); + // The child process could aready be terminated + try { + this._process.send({ + event: 'resize', + cols: this._cols, + rows: this._rows + }); + } catch (error) { + // We tried to write to a closed pipe / channel. + if (error.code !== 'EPIPE' && error.code !== 'ERR_IPC_CHANNEL_CLOSED') { + throw (error); + } + } } }); } -- GitLab From 44fc473b58da4944de714a3269c50a3444c6559a Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Tue, 13 Jun 2017 15:24:37 +0200 Subject: [PATCH 0772/1347] :lipstick: --- src/vs/workbench/parts/views/browser/treeView.ts | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/vs/workbench/parts/views/browser/treeView.ts b/src/vs/workbench/parts/views/browser/treeView.ts index b31b3f71a23..4f226a0a81a 100644 --- a/src/vs/workbench/parts/views/browser/treeView.ts +++ b/src/vs/workbench/parts/views/browser/treeView.ts @@ -76,6 +76,7 @@ export class TreeView extends CollapsibleView { DOM.addClass(this.treeContainer, 'tree-explorer-viewlet-tree-view'); this.tree = this.createViewer($(this.treeContainer)); + this.setInput(); } protected changeState(state: CollapsibleState): void { @@ -127,10 +128,6 @@ export class TreeView extends CollapsibleView { return super.setVisible(visible); } - public create(): TPromise { - return super.create().then(() => this.setInput()); - } - private setInput(): TPromise { if (this.tree) { if (!this.treeInputPromise) { -- GitLab From 337ded059ae5140b86caf07e67ce92a41a8e6581 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Tue, 13 Jun 2017 16:00:36 +0200 Subject: [PATCH 0773/1347] rename ITextModelResolverService to ITextModelService, #10547 --- src/vs/editor/browser/standalone/simpleServices.ts | 6 +++--- src/vs/editor/browser/standalone/standaloneEditor.ts | 6 +++--- src/vs/editor/common/services/bulkEdit.ts | 10 +++++----- src/vs/editor/common/services/resolverService.ts | 6 +++--- .../goToDeclaration/browser/goToDeclarationMouse.ts | 4 ++-- .../referenceSearch/browser/referencesController.ts | 4 ++-- .../contrib/referenceSearch/browser/referencesModel.ts | 4 ++-- .../referenceSearch/browser/referencesWidget.ts | 6 +++--- src/vs/editor/contrib/rename/browser/rename.ts | 4 ++-- .../api/electron-browser/mainThreadDocuments.ts | 6 +++--- .../api/electron-browser/mainThreadWorkspace.ts | 4 ++-- src/vs/workbench/common/editor/resourceEditorInput.ts | 4 ++-- src/vs/workbench/electron-browser/workbench.ts | 4 ++-- .../parts/debug/browser/debugContentProvider.ts | 4 ++-- .../workbench/parts/files/browser/saveErrorHandler.ts | 10 +++++----- .../parts/files/common/editors/fileEditorInput.ts | 6 +++--- .../workbench/parts/html/browser/html.contribution.ts | 4 ++-- src/vs/workbench/parts/html/browser/htmlPreviewPart.ts | 4 ++-- .../workbench/parts/output/browser/outputServices.ts | 6 +++--- .../parts/preferences/browser/preferencesEditor.ts | 4 ++-- .../parts/preferences/browser/preferencesService.ts | 6 +++--- .../preferences/common/preferencesContentProvider.ts | 6 +++--- .../parts/scm/electron-browser/dirtydiffDecorator.ts | 6 +++--- .../workbench/parts/search/browser/replaceService.ts | 8 ++++---- .../walkThrough/node/walkThroughContentProvider.ts | 8 ++++---- .../parts/welcome/walkThrough/node/walkThroughInput.ts | 4 ++-- .../configuration/node/configurationEditingService.ts | 6 +++--- .../test/node/configurationEditingService.test.ts | 6 +++--- .../services/keybinding/common/keybindingEditing.ts | 6 +++--- .../services/keybinding/test/keybindingEditing.test.ts | 6 +++--- .../common/textModelResolverService.ts | 6 +++--- .../test/textModelResolverService.test.ts | 6 +++--- .../test/common/editor/editorDiffModel.test.ts | 6 +++--- src/vs/workbench/test/workbenchTestServices.ts | 4 ++-- 34 files changed, 95 insertions(+), 95 deletions(-) diff --git a/src/vs/editor/browser/standalone/simpleServices.ts b/src/vs/editor/browser/standalone/simpleServices.ts index 3b01a330dbf..e380ac9bd39 100644 --- a/src/vs/editor/browser/standalone/simpleServices.ts +++ b/src/vs/editor/browser/standalone/simpleServices.ts @@ -25,7 +25,7 @@ import Event, { Emitter } from 'vs/base/common/event'; import { getDefaultValues as getDefaultConfiguration } from 'vs/platform/configuration/common/model'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { IProgressService, IProgressRunner } from 'vs/platform/progress/common/progress'; -import { ITextModelResolverService, ITextModelContentProvider, ITextEditorModel } from 'vs/editor/common/services/resolverService'; +import { ITextModelService, ITextModelContentProvider, ITextEditorModel } from 'vs/editor/common/services/resolverService'; import { IDisposable, IReference, ImmortalReference, combinedDisposable } from 'vs/base/common/lifecycle'; import * as dom from 'vs/base/browser/dom'; import { StandardKeyboardEvent } from 'vs/base/browser/keyboardEvent'; @@ -173,7 +173,7 @@ export class SimpleEditorService implements IEditorService { } } -export class SimpleEditorModelResolverService implements ITextModelResolverService { +export class SimpleEditorModelResolverService implements ITextModelService { public _serviceBrand: any; private editor: SimpleEditor; @@ -527,4 +527,4 @@ export class SimpleWorkspaceContextService implements IWorkspaceContextService { public toResource(workspaceRelativePath: string): URI { return this.workspace ? this.workspace.toResource(workspaceRelativePath) : null; } -} \ No newline at end of file +} diff --git a/src/vs/editor/browser/standalone/standaloneEditor.ts b/src/vs/editor/browser/standalone/standaloneEditor.ts index 776016912c4..d5648359b2a 100644 --- a/src/vs/editor/browser/standalone/standaloneEditor.ts +++ b/src/vs/editor/browser/standalone/standaloneEditor.ts @@ -29,7 +29,7 @@ import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; import { ICodeEditorService } from 'vs/editor/common/services/codeEditorService'; import { IEditorWorkerService } from 'vs/editor/common/services/editorWorkerService'; -import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextModelService } from 'vs/editor/common/services/resolverService'; import { NULL_STATE, nullTokenize } from 'vs/editor/common/modes/nullMode'; import { IStandaloneThemeData, IStandaloneThemeService } from 'vs/editor/common/services/standaloneThemeService'; import { Token } from 'vs/editor/common/core/token'; @@ -55,9 +55,9 @@ function withAllStandaloneServices(domElement: H } let simpleEditorModelResolverService: SimpleEditorModelResolverService = null; - if (!services.has(ITextModelResolverService)) { + if (!services.has(ITextModelService)) { simpleEditorModelResolverService = new SimpleEditorModelResolverService(); - services.set(ITextModelResolverService, simpleEditorModelResolverService); + services.set(ITextModelService, simpleEditorModelResolverService); } if (!services.has(IOpenerService)) { diff --git a/src/vs/editor/common/services/bulkEdit.ts b/src/vs/editor/common/services/bulkEdit.ts index e847eafc911..9916d05ad03 100644 --- a/src/vs/editor/common/services/bulkEdit.ts +++ b/src/vs/editor/common/services/bulkEdit.ts @@ -10,7 +10,7 @@ import { IStringDictionary, forEach, values, groupBy, size } from 'vs/base/commo import { IDisposable, dispose, IReference } from 'vs/base/common/lifecycle'; import URI from 'vs/base/common/uri'; import { TPromise } from 'vs/base/common/winjs.base'; -import { ITextModelResolverService, ITextEditorModel } from 'vs/editor/common/services/resolverService'; +import { ITextModelService, ITextEditorModel } from 'vs/editor/common/services/resolverService'; import { IFileService, IFileChange } from 'vs/platform/files/common/files'; import { EditOperation } from 'vs/editor/common/core/editOperation'; import { Range, IRange } from 'vs/editor/common/core/range'; @@ -183,7 +183,7 @@ class SourceModelEditTask extends EditTask { class BulkEditModel implements IDisposable { - private _textModelResolverService: ITextModelResolverService; + private _textModelResolverService: ITextModelService; private _numberOfResourcesToModify: number = 0; private _numberOfChanges: number = 0; private _edits: IStringDictionary = Object.create(null); @@ -192,7 +192,7 @@ class BulkEditModel implements IDisposable { private _sourceSelections: Selection[]; private _sourceModelTask: SourceModelEditTask; - constructor(textModelResolverService: ITextModelResolverService, sourceModel: URI, sourceSelections: Selection[], edits: IResourceEdit[], private progress: IProgressRunner = null) { + constructor(textModelResolverService: ITextModelService, sourceModel: URI, sourceSelections: Selection[], edits: IResourceEdit[], private progress: IProgressRunner = null) { this._textModelResolverService = textModelResolverService; this._sourceModel = sourceModel; this._sourceSelections = sourceSelections; @@ -293,14 +293,14 @@ export interface BulkEdit { ariaMessage(): string; } -export function bulkEdit(textModelResolverService: ITextModelResolverService, editor: ICommonCodeEditor, edits: IResourceEdit[], fileService?: IFileService, progress: IProgressRunner = null): TPromise { +export function bulkEdit(textModelResolverService: ITextModelService, editor: ICommonCodeEditor, edits: IResourceEdit[], fileService?: IFileService, progress: IProgressRunner = null): TPromise { let bulk = createBulkEdit(textModelResolverService, editor, fileService); bulk.add(edits); bulk.progress(progress); return bulk.finish(); } -export function createBulkEdit(textModelResolverService: ITextModelResolverService, editor?: ICommonCodeEditor, fileService?: IFileService): BulkEdit { +export function createBulkEdit(textModelResolverService: ITextModelService, editor?: ICommonCodeEditor, fileService?: IFileService): BulkEdit { let all: IResourceEdit[] = []; let recording = new ChangeRecorder(fileService).start(); diff --git a/src/vs/editor/common/services/resolverService.ts b/src/vs/editor/common/services/resolverService.ts index aacd94b9622..f476280d339 100644 --- a/src/vs/editor/common/services/resolverService.ts +++ b/src/vs/editor/common/services/resolverService.ts @@ -11,9 +11,9 @@ import { IModel } from 'vs/editor/common/editorCommon'; import { IEditorModel } from 'vs/platform/editor/common/editor'; import { IDisposable, IReference } from 'vs/base/common/lifecycle'; -export const ITextModelResolverService = createDecorator('textModelResolverService'); +export const ITextModelService = createDecorator('textModelService'); -export interface ITextModelResolverService { +export interface ITextModelService { _serviceBrand: any; /** @@ -42,4 +42,4 @@ export interface ITextEditorModel extends IEditorModel { * Provides access to the underlying IModel. */ textEditorModel: IModel; -} \ No newline at end of file +} diff --git a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts index 124e4229c3d..6a8718e202b 100644 --- a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts +++ b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.ts @@ -19,7 +19,7 @@ import { ICodeEditor, IMouseTarget, MouseTargetType } from 'vs/editor/browser/ed import { editorContribution } from 'vs/editor/browser/editorBrowserExtensions'; import { getDefinitionsAtPosition } from './goToDeclaration'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; -import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextModelService } from 'vs/editor/common/services/resolverService'; import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; import { editorActiveLinkForeground } from 'vs/platform/theme/common/colorRegistry'; import { EditorState, CodeEditorStateFlag } from 'vs/editor/common/core/editorState'; @@ -40,7 +40,7 @@ class GotoDefinitionWithMouseEditorContribution implements editorCommon.IEditorC constructor( editor: ICodeEditor, - @ITextModelResolverService private textModelResolverService: ITextModelResolverService, + @ITextModelService private textModelResolverService: ITextModelService, @IModeService private modeService: IModeService ) { this.toUnhook = []; diff --git a/src/vs/editor/contrib/referenceSearch/browser/referencesController.ts b/src/vs/editor/contrib/referenceSearch/browser/referencesController.ts index c92079e5566..abc2506e575 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referencesController.ts +++ b/src/vs/editor/contrib/referenceSearch/browser/referencesController.ts @@ -25,7 +25,7 @@ import { IPeekViewService } from 'vs/editor/contrib/zoneWidget/browser/peekViewW import { ReferencesModel, OneReference } from './referencesModel'; import { ReferenceWidget, LayoutData } from './referencesWidget'; import { Range } from 'vs/editor/common/core/range'; -import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextModelService } from 'vs/editor/common/services/resolverService'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { Position } from 'vs/editor/common/core/position'; import { IEnvironmentService } from "vs/platform/environment/common/environment"; @@ -59,7 +59,7 @@ export class ReferencesController implements editorCommon.IEditorContribution { editor: ICodeEditor, @IContextKeyService contextKeyService: IContextKeyService, @IEditorService private _editorService: IEditorService, - @ITextModelResolverService private _textModelResolverService: ITextModelResolverService, + @ITextModelService private _textModelResolverService: ITextModelService, @ITelemetryService private _telemetryService: ITelemetryService, @IMessageService private _messageService: IMessageService, @IInstantiationService private _instantiationService: IInstantiationService, diff --git a/src/vs/editor/contrib/referenceSearch/browser/referencesModel.ts b/src/vs/editor/contrib/referenceSearch/browser/referencesModel.ts index b0660173eb5..4ddacbe9216 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referencesModel.ts +++ b/src/vs/editor/contrib/referenceSearch/browser/referencesModel.ts @@ -15,7 +15,7 @@ import { defaultGenerator } from 'vs/base/common/idGenerator'; import { TPromise } from 'vs/base/common/winjs.base'; import { Range, IRange } from 'vs/editor/common/core/range'; import { Location } from 'vs/editor/common/modes'; -import { ITextModelResolverService, ITextEditorModel } from 'vs/editor/common/services/resolverService'; +import { ITextModelService, ITextEditorModel } from 'vs/editor/common/services/resolverService'; import { Position } from 'vs/editor/common/core/position'; export class OneReference { @@ -160,7 +160,7 @@ export class FileReferences implements IDisposable { } } - public resolve(textModelResolverService: ITextModelResolverService): TPromise { + public resolve(textModelResolverService: ITextModelService): TPromise { if (this._resolved) { return TPromise.as(this); diff --git a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts index d40a682c8f8..7ad1761a1b9 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts +++ b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts @@ -36,7 +36,7 @@ import { ICodeEditor } from 'vs/editor/browser/editorBrowser'; import { EmbeddedCodeEditorWidget } from 'vs/editor/browser/widget/embeddedCodeEditorWidget'; import { PeekViewWidget, IPeekViewService } from 'vs/editor/contrib/zoneWidget/browser/peekViewWidget'; import { FileReferences, OneReference, ReferencesModel } from './referencesModel'; -import { ITextModelResolverService, ITextEditorModel } from 'vs/editor/common/services/resolverService'; +import { ITextModelService, ITextEditorModel } from 'vs/editor/common/services/resolverService'; import { registerColor, activeContrastBorder, contrastBorder } from 'vs/platform/theme/common/colorRegistry'; import { registerThemingParticipant, ITheme, IThemeService } from 'vs/platform/theme/common/themeService'; import { attachListStyler, attachBadgeStyler } from 'vs/platform/theme/common/styler'; @@ -166,7 +166,7 @@ class DecorationsManager implements IDisposable { class DataSource implements tree.IDataSource { constructor( - @ITextModelResolverService private _textModelResolverService: ITextModelResolverService + @ITextModelService private _textModelResolverService: ITextModelService ) { // } @@ -583,7 +583,7 @@ export class ReferenceWidget extends PeekViewWidget { constructor( editor: ICodeEditor, public layoutData: LayoutData, - private _textModelResolverService: ITextModelResolverService, + private _textModelResolverService: ITextModelService, private _contextService: IWorkspaceContextService, private _themeService: IThemeService, private _instantiationService: IInstantiationService, diff --git a/src/vs/editor/contrib/rename/browser/rename.ts b/src/vs/editor/contrib/rename/browser/rename.ts index 70fc125ffa5..92284675cbe 100644 --- a/src/vs/editor/contrib/rename/browser/rename.ts +++ b/src/vs/editor/contrib/rename/browser/rename.ts @@ -21,7 +21,7 @@ import { EditorContextKeys } from 'vs/editor/common/editorContextKeys'; import { BulkEdit, createBulkEdit } from 'vs/editor/common/services/bulkEdit'; import { ICodeEditor } from 'vs/editor/browser/editorBrowser'; import RenameInputField from './renameInputField'; -import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextModelService } from 'vs/editor/common/services/resolverService'; import { optional } from 'vs/platform/instantiation/common/instantiation'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { sequence, asWinJsPromise } from 'vs/base/common/async'; @@ -99,7 +99,7 @@ class RenameController implements IEditorContribution { constructor( private editor: ICodeEditor, @IMessageService private _messageService: IMessageService, - @ITextModelResolverService private _textModelResolverService: ITextModelResolverService, + @ITextModelService private _textModelResolverService: ITextModelService, @IProgressService private _progressService: IProgressService, @IContextKeyService contextKeyService: IContextKeyService, @IThemeService themeService: IThemeService, diff --git a/src/vs/workbench/api/electron-browser/mainThreadDocuments.ts b/src/vs/workbench/api/electron-browser/mainThreadDocuments.ts index 0734061ff17..83476253ea5 100644 --- a/src/vs/workbench/api/electron-browser/mainThreadDocuments.ts +++ b/src/vs/workbench/api/electron-browser/mainThreadDocuments.ts @@ -16,7 +16,7 @@ import { IModeService } from 'vs/editor/common/services/modeService'; import { IUntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { ExtHostContext, MainThreadDocumentsShape, ExtHostDocumentsShape } from '../node/extHost.protocol'; -import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextModelService } from 'vs/editor/common/services/resolverService'; import { ICodeEditorService } from 'vs/editor/common/services/codeEditorService'; import { ITextSource } from 'vs/editor/common/model/textSource'; import { MainThreadDocumentsAndEditors } from './mainThreadDocumentsAndEditors'; @@ -71,7 +71,7 @@ export class MainThreadDocuments extends MainThreadDocumentsShape { private _modelService: IModelService; private _modeService: IModeService; - private _textModelResolverService: ITextModelResolverService; + private _textModelResolverService: ITextModelService; private _textFileService: ITextFileService; private _codeEditorService: ICodeEditorService; private _fileService: IFileService; @@ -93,7 +93,7 @@ export class MainThreadDocuments extends MainThreadDocumentsShape { @ITextFileService textFileService: ITextFileService, @ICodeEditorService codeEditorService: ICodeEditorService, @IFileService fileService: IFileService, - @ITextModelResolverService textModelResolverService: ITextModelResolverService, + @ITextModelService textModelResolverService: ITextModelService, @IUntitledEditorService untitledEditorService: IUntitledEditorService, @IEditorGroupService editorGroupService: IEditorGroupService ) { diff --git a/src/vs/workbench/api/electron-browser/mainThreadWorkspace.ts b/src/vs/workbench/api/electron-browser/mainThreadWorkspace.ts index 8cd8b7c62e1..f7cd4fb7e91 100644 --- a/src/vs/workbench/api/electron-browser/mainThreadWorkspace.ts +++ b/src/vs/workbench/api/electron-browser/mainThreadWorkspace.ts @@ -14,7 +14,7 @@ import { ICommonCodeEditor, isCommonCodeEditor } from 'vs/editor/common/editorCo import { bulkEdit, IResourceEdit } from 'vs/editor/common/services/bulkEdit'; import { TPromise } from 'vs/base/common/winjs.base'; import { MainThreadWorkspaceShape, ExtHostWorkspaceShape, ExtHostContext } from '../node/extHost.protocol'; -import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextModelService } from 'vs/editor/common/services/resolverService'; import { IFileService } from 'vs/platform/files/common/files'; import { IThreadService } from 'vs/workbench/services/thread/common/threadService'; import { IDisposable } from 'vs/base/common/lifecycle'; @@ -31,7 +31,7 @@ export class MainThreadWorkspace extends MainThreadWorkspaceShape { @IWorkspaceContextService private readonly _contextService: IWorkspaceContextService, @ITextFileService private readonly _textFileService: ITextFileService, @IWorkbenchEditorService private readonly _editorService: IWorkbenchEditorService, - @ITextModelResolverService private readonly _textModelResolverService: ITextModelResolverService, + @ITextModelService private readonly _textModelResolverService: ITextModelService, @IFileService private readonly _fileService: IFileService, @IThreadService threadService: IThreadService ) { diff --git a/src/vs/workbench/common/editor/resourceEditorInput.ts b/src/vs/workbench/common/editor/resourceEditorInput.ts index b99b12ecd05..0f41e0edc5c 100644 --- a/src/vs/workbench/common/editor/resourceEditorInput.ts +++ b/src/vs/workbench/common/editor/resourceEditorInput.ts @@ -9,7 +9,7 @@ import { EditorInput, ITextEditorModel } from 'vs/workbench/common/editor'; import URI from 'vs/base/common/uri'; import { IReference } from 'vs/base/common/lifecycle'; import { telemetryURIDescriptor } from 'vs/platform/telemetry/common/telemetryUtils'; -import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextModelService } from 'vs/editor/common/services/resolverService'; import { ResourceEditorModel } from 'vs/workbench/common/editor/resourceEditorModel'; /** @@ -29,7 +29,7 @@ export class ResourceEditorInput extends EditorInput { name: string, description: string, resource: URI, - @ITextModelResolverService private textModelResolverService: ITextModelResolverService + @ITextModelService private textModelResolverService: ITextModelService ) { super(); diff --git a/src/vs/workbench/electron-browser/workbench.ts b/src/vs/workbench/electron-browser/workbench.ts index a8afe425a03..3256b4b5152 100644 --- a/src/vs/workbench/electron-browser/workbench.ts +++ b/src/vs/workbench/electron-browser/workbench.ts @@ -80,7 +80,7 @@ import { SCMService } from 'vs/workbench/services/scm/common/scmService'; import { IProgressService2 } from 'vs/platform/progress/common/progress'; import { ProgressService2 } from 'vs/workbench/services/progress/browser/progressService2'; import { TextModelResolverService } from 'vs/workbench/services/textmodelResolver/common/textModelResolverService'; -import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextModelService } from 'vs/editor/common/services/resolverService'; import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; import { ILifecycleService, ShutdownReason } from 'vs/platform/lifecycle/common/lifecycle'; import { IWindowService, IWindowConfiguration as IWindowSettings, IWindowConfiguration } from 'vs/platform/windows/common/windows'; @@ -534,7 +534,7 @@ export class Workbench implements IPartService { serviceCollection.set(ISCMService, new SyncDescriptor(SCMService)); // Text Model Resolver Service - serviceCollection.set(ITextModelResolverService, new SyncDescriptor(TextModelResolverService)); + serviceCollection.set(ITextModelService, new SyncDescriptor(TextModelResolverService)); // Configuration Editing this.configurationEditingService = this.instantiationService.createInstance(ConfigurationEditingService); diff --git a/src/vs/workbench/parts/debug/browser/debugContentProvider.ts b/src/vs/workbench/parts/debug/browser/debugContentProvider.ts index 0ad6436765e..7bb2d9ee15b 100644 --- a/src/vs/workbench/parts/debug/browser/debugContentProvider.ts +++ b/src/vs/workbench/parts/debug/browser/debugContentProvider.ts @@ -10,14 +10,14 @@ import { guessMimeTypes, MIME_TEXT } from 'vs/base/common/mime'; import { IModel } from 'vs/editor/common/editorCommon'; import { IModelService } from 'vs/editor/common/services/modelService'; import { IModeService } from 'vs/editor/common/services/modeService'; -import { ITextModelResolverService, ITextModelContentProvider } from 'vs/editor/common/services/resolverService'; +import { ITextModelService, ITextModelContentProvider } from 'vs/editor/common/services/resolverService'; import { IWorkbenchContribution } from 'vs/workbench/common/contributions'; import { DEBUG_SCHEME, IDebugService } from 'vs/workbench/parts/debug/common/debug'; export class DebugContentProvider implements IWorkbenchContribution, ITextModelContentProvider { constructor( - @ITextModelResolverService textModelResolverService: ITextModelResolverService, + @ITextModelService textModelResolverService: ITextModelService, @IDebugService private debugService: IDebugService, @IModelService private modelService: IModelService, @IModeService private modeService: IModeService diff --git a/src/vs/workbench/parts/files/browser/saveErrorHandler.ts b/src/vs/workbench/parts/files/browser/saveErrorHandler.ts index dca5ccb26c1..a4e45da21d8 100644 --- a/src/vs/workbench/parts/files/browser/saveErrorHandler.ts +++ b/src/vs/workbench/parts/files/browser/saveErrorHandler.ts @@ -23,7 +23,7 @@ import { IModelService } from 'vs/editor/common/services/modelService'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { IWorkbenchContribution } from 'vs/workbench/common/contributions'; import { TextFileEditorModel } from 'vs/workbench/services/textfile/common/textFileEditorModel'; -import { ITextModelResolverService, ITextModelContentProvider } from 'vs/editor/common/services/resolverService'; +import { ITextModelService, ITextModelContentProvider } from 'vs/editor/common/services/resolverService'; import { IModel } from 'vs/editor/common/editorCommon'; import { ResourceMap } from 'vs/base/common/map'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; @@ -43,7 +43,7 @@ export class SaveErrorHandler implements ISaveErrorHandler, IWorkbenchContributi constructor( @IMessageService private messageService: IMessageService, @ITextFileService private textFileService: ITextFileService, - @ITextModelResolverService private textModelResolverService: ITextModelResolverService, + @ITextModelService private textModelResolverService: ITextModelService, @IModelService private modelService: IModelService, @IModeService private modeService: IModeService, @IInstantiationService private instantiationService: IInstantiationService, @@ -240,7 +240,7 @@ class ResolveSaveConflictMessage implements IMessageWithAction { export const acceptLocalChangesCommand = (accessor: ServicesAccessor, resource: URI) => { const editorService = accessor.get(IWorkbenchEditorService); - const resolverService = accessor.get(ITextModelResolverService); + const resolverService = accessor.get(ITextModelService); const editor = editorService.getActiveEditor(); const input = editor.input; @@ -275,7 +275,7 @@ export const acceptLocalChangesCommand = (accessor: ServicesAccessor, resource: export const revertLocalChangesCommand = (accessor: ServicesAccessor, resource: URI) => { const editorService = accessor.get(IWorkbenchEditorService); - const resolverService = accessor.get(ITextModelResolverService); + const resolverService = accessor.get(ITextModelService); const editor = editorService.getActiveEditor(); const input = editor.input; @@ -298,4 +298,4 @@ export const revertLocalChangesCommand = (accessor: ServicesAccessor, resource: }); }); }); -}; \ No newline at end of file +}; diff --git a/src/vs/workbench/parts/files/common/editors/fileEditorInput.ts b/src/vs/workbench/parts/files/common/editors/fileEditorInput.ts index d2b5a8b9235..2de84284950 100644 --- a/src/vs/workbench/parts/files/common/editors/fileEditorInput.ts +++ b/src/vs/workbench/parts/files/common/editors/fileEditorInput.ts @@ -21,7 +21,7 @@ import { IDisposable, dispose, IReference } from 'vs/base/common/lifecycle'; import { telemetryURIDescriptor } from 'vs/platform/telemetry/common/telemetryUtils'; import { Verbosity } from 'vs/platform/editor/common/editor'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; -import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextModelService } from 'vs/editor/common/services/resolverService'; /** * A file editor input is the input type for the file editor of file system resources. @@ -50,7 +50,7 @@ export class FileEditorInput extends EditorInput implements IFileEditorInput { @IWorkspaceContextService private contextService: IWorkspaceContextService, @ITextFileService private textFileService: ITextFileService, @IEnvironmentService private environmentService: IEnvironmentService, - @ITextModelResolverService private textModelResolverService: ITextModelResolverService + @ITextModelService private textModelResolverService: ITextModelService ) { super(); @@ -267,4 +267,4 @@ export class FileEditorInput extends EditorInput implements IFileEditorInput { return false; } -} \ No newline at end of file +} diff --git a/src/vs/workbench/parts/html/browser/html.contribution.ts b/src/vs/workbench/parts/html/browser/html.contribution.ts index 70120e9682b..f41e225ce17 100644 --- a/src/vs/workbench/parts/html/browser/html.contribution.ts +++ b/src/vs/workbench/parts/html/browser/html.contribution.ts @@ -19,7 +19,7 @@ import { SyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { isCommonCodeEditor, ICommonCodeEditor } from 'vs/editor/common/editorCommon'; import { HtmlZoneController } from './htmlEditorZone'; -import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextModelService } from 'vs/editor/common/services/resolverService'; // --- Register Editor (Registry.as(EditorExtensions.Editors)).registerEditor(new EditorDescriptor(HtmlPreviewPart.ID, @@ -60,7 +60,7 @@ CommandsRegistry.registerCommand('_workbench.htmlZone', function (accessor: Serv return undefined; } - const textModelResolverService = accessor.get(ITextModelResolverService); + const textModelResolverService = accessor.get(ITextModelService); return textModelResolverService.createModelReference(params.resource).then(ref => { const model = ref.object; diff --git a/src/vs/workbench/parts/html/browser/htmlPreviewPart.ts b/src/vs/workbench/parts/html/browser/htmlPreviewPart.ts index 038c8c4cd99..43775d62aba 100644 --- a/src/vs/workbench/parts/html/browser/htmlPreviewPart.ts +++ b/src/vs/workbench/parts/html/browser/htmlPreviewPart.ts @@ -19,7 +19,7 @@ import { BaseTextEditorModel } from 'vs/workbench/common/editor/textEditorModel' import { HtmlInput } from 'vs/workbench/parts/html/common/htmlInput'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { IOpenerService } from 'vs/platform/opener/common/opener'; -import { ITextModelResolverService, ITextEditorModel } from 'vs/editor/common/services/resolverService'; +import { ITextModelService, ITextEditorModel } from 'vs/editor/common/services/resolverService'; import { Parts, IPartService } from 'vs/workbench/services/part/common/partService'; import Webview from './webview'; @@ -48,7 +48,7 @@ export class HtmlPreviewPart extends WebviewEditor { constructor( @ITelemetryService telemetryService: ITelemetryService, - @ITextModelResolverService private textModelResolverService: ITextModelResolverService, + @ITextModelService private textModelResolverService: ITextModelService, @IThemeService themeService: IThemeService, @IOpenerService private openerService: IOpenerService, @IWorkspaceContextService contextService: IWorkspaceContextService, diff --git a/src/vs/workbench/parts/output/browser/outputServices.ts b/src/vs/workbench/parts/output/browser/outputServices.ts index bd5efe6484c..11a34746309 100644 --- a/src/vs/workbench/parts/output/browser/outputServices.ts +++ b/src/vs/workbench/parts/output/browser/outputServices.ts @@ -20,7 +20,7 @@ import { IPanelService } from 'vs/workbench/services/panel/common/panelService'; import { IModelService } from 'vs/editor/common/services/modelService'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { OutputLinkProvider } from 'vs/workbench/parts/output/common/outputLinkProvider'; -import { ITextModelResolverService, ITextModelContentProvider } from 'vs/editor/common/services/resolverService'; +import { ITextModelService, ITextModelContentProvider } from 'vs/editor/common/services/resolverService'; import { IModel } from 'vs/editor/common/editorCommon'; import { IModeService } from 'vs/editor/common/services/modeService'; import { RunOnceScheduler } from 'vs/base/common/async'; @@ -101,7 +101,7 @@ export class OutputService implements IOutputService { @IPanelService private panelService: IPanelService, @IWorkspaceContextService contextService: IWorkspaceContextService, @IModelService modelService: IModelService, - @ITextModelResolverService textModelResolverService: ITextModelResolverService + @ITextModelService textModelResolverService: ITextModelService ) { this._onOutput = new Emitter(); this._onOutputChannel = new Emitter(); @@ -380,4 +380,4 @@ class OutputContentProvider implements ITextModelContentProvider { public dispose(): void { this.toDispose = dispose(this.toDispose); } -} \ No newline at end of file +} diff --git a/src/vs/workbench/parts/preferences/browser/preferencesEditor.ts b/src/vs/workbench/parts/preferences/browser/preferencesEditor.ts index ca535cf3de0..1b47bac1970 100644 --- a/src/vs/workbench/parts/preferences/browser/preferencesEditor.ts +++ b/src/vs/workbench/parts/preferences/browser/preferencesEditor.ts @@ -38,7 +38,7 @@ import { IModeService } from 'vs/editor/common/services/modeService'; import { IStorageService } from 'vs/platform/storage/common/storage'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; -import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextModelService } from 'vs/editor/common/services/resolverService'; import { ConfigurationTarget } from 'vs/workbench/services/configuration/common/configurationEditing'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { VSash } from 'vs/base/browser/ui/sash/sash'; @@ -71,7 +71,7 @@ export class PreferencesEditorInput extends SideBySideEditorInput { export class DefaultPreferencesEditorInput extends ResourceEditorInput { public static ID = 'workbench.editorinputs.defaultpreferences'; constructor(defaultSettingsResource: URI, - @ITextModelResolverService textModelResolverService: ITextModelResolverService + @ITextModelService textModelResolverService: ITextModelService ) { super(nls.localize('settingsEditorName', "Default Settings"), '', defaultSettingsResource, textModelResolverService); } diff --git a/src/vs/workbench/parts/preferences/browser/preferencesService.ts b/src/vs/workbench/parts/preferences/browser/preferencesService.ts index 3cd438f300f..05b44bc620d 100644 --- a/src/vs/workbench/parts/preferences/browser/preferencesService.ts +++ b/src/vs/workbench/parts/preferences/browser/preferencesService.ts @@ -31,7 +31,7 @@ import { SettingsEditorModel, DefaultSettingsEditorModel, DefaultKeybindingsEdit import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { DefaultPreferencesEditorInput, PreferencesEditorInput } from 'vs/workbench/parts/preferences/browser/preferencesEditor'; import { KeybindingsEditorInput } from 'vs/workbench/parts/preferences/browser/keybindingsEditor'; -import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextModelService } from 'vs/editor/common/services/resolverService'; import { getCodeEditor } from 'vs/editor/common/services/codeEditorService'; import { EditOperation } from 'vs/editor/common/core/editOperation'; import { Position, IPosition } from 'vs/editor/common/core/position'; @@ -67,7 +67,7 @@ export class PreferencesService extends Disposable implements IPreferencesServic @IStorageService private storageService: IStorageService, @IEnvironmentService private environmentService: IEnvironmentService, @ITelemetryService private telemetryService: ITelemetryService, - @ITextModelResolverService private textModelResolverService: ITextModelResolverService, + @ITextModelService private textModelResolverService: ITextModelService, @IConfigurationEditingService private configurationEditingService: IConfigurationEditingService, @IExtensionService private extensionService: IExtensionService, @IKeybindingService keybindingService: IKeybindingService, @@ -347,4 +347,4 @@ export class PreferencesService extends Disposable implements IPreferencesServic this.defaultPreferencesEditorModels.clear(); super.dispose(); } -} \ No newline at end of file +} diff --git a/src/vs/workbench/parts/preferences/common/preferencesContentProvider.ts b/src/vs/workbench/parts/preferences/common/preferencesContentProvider.ts index a9c27604d33..53b0b7d239b 100644 --- a/src/vs/workbench/parts/preferences/common/preferencesContentProvider.ts +++ b/src/vs/workbench/parts/preferences/common/preferencesContentProvider.ts @@ -12,7 +12,7 @@ import { IModel } from 'vs/editor/common/editorCommon'; import JSONContributionRegistry = require('vs/platform/jsonschemas/common/jsonContributionRegistry'); import { Registry } from 'vs/platform/platform'; import { IWorkbenchContribution } from 'vs/workbench/common/contributions'; -import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextModelService } from 'vs/editor/common/services/resolverService'; import { IPreferencesService } from 'vs/workbench/parts/preferences/common/preferences'; const schemaRegistry = Registry.as(JSONContributionRegistry.Extensions.JSONContribution); @@ -21,7 +21,7 @@ export class PreferencesContentProvider implements IWorkbenchContribution { constructor( @IModelService private modelService: IModelService, - @ITextModelResolverService private textModelResolverService: ITextModelResolverService, + @ITextModelService private textModelResolverService: ITextModelService, @IPreferencesService private preferencesService: IPreferencesService, @IModeService private modeService: IModeService ) { @@ -60,4 +60,4 @@ export class PreferencesContentProvider implements IWorkbenchContribution { } }); } -} \ No newline at end of file +} diff --git a/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.ts b/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.ts index 8561d451305..32b3d1689d2 100644 --- a/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.ts +++ b/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.ts @@ -15,7 +15,7 @@ import * as widget from 'vs/editor/browser/codeEditor'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { IMessageService } from 'vs/platform/message/common/message'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; -import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextModelService } from 'vs/editor/common/services/resolverService'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; import { IModelService } from 'vs/editor/common/services/modelService'; import { IEditorWorkerService } from 'vs/editor/common/services/editorWorkerService'; @@ -74,7 +74,7 @@ class DirtyDiffModelDecorator { @IEditorWorkerService private editorWorkerService: IEditorWorkerService, @IWorkbenchEditorService private editorService: IWorkbenchEditorService, @IWorkspaceContextService private contextService: IWorkspaceContextService, - @ITextModelResolverService private textModelResolverService: ITextModelResolverService + @ITextModelService private textModelResolverService: ITextModelService ) { this.decorations = []; this.diffDelayer = new ThrottledDelayer(200); @@ -310,4 +310,4 @@ registerThemingParticipant((theme: ITheme, collector: ICssStyleCollector) => { } `); } -}); \ No newline at end of file +}); diff --git a/src/vs/workbench/parts/search/browser/replaceService.ts b/src/vs/workbench/parts/search/browser/replaceService.ts index 4fb0b6372c3..f94c704efdf 100644 --- a/src/vs/workbench/parts/search/browser/replaceService.ts +++ b/src/vs/workbench/parts/search/browser/replaceService.ts @@ -19,7 +19,7 @@ import { BulkEdit, IResourceEdit, createBulkEdit } from 'vs/editor/common/servic import { IProgressRunner } from 'vs/platform/progress/common/progress'; import { IDiffEditor } from 'vs/editor/browser/editorBrowser'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; -import { ITextModelResolverService, ITextModelContentProvider } from 'vs/editor/common/services/resolverService'; +import { ITextModelService, ITextModelContentProvider } from 'vs/editor/common/services/resolverService'; import { IWorkbenchContribution } from 'vs/workbench/common/contributions'; import { IModel } from 'vs/editor/common/editorCommon'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; @@ -39,7 +39,7 @@ export class ReplacePreviewContentProvider implements ITextModelContentProvider, constructor( @IInstantiationService private instantiationService: IInstantiationService, - @ITextModelResolverService private textModelResolverService: ITextModelResolverService + @ITextModelService private textModelResolverService: ITextModelService ) { this.textModelResolverService.registerTextModelContentProvider(network.Schemas.internal, this); } @@ -60,7 +60,7 @@ class ReplacePreviewModel extends Disposable { constructor( @IModelService private modelService: IModelService, @IModeService private modeService: IModeService, - @ITextModelResolverService private textModelResolverService: ITextModelResolverService, + @ITextModelService private textModelResolverService: ITextModelService, @IReplaceService private replaceService: IReplaceService, @ISearchWorkbenchService private searchWorkbenchService: ISearchWorkbenchService ) { @@ -100,7 +100,7 @@ export class ReplaceService implements IReplaceService { @IFileService private fileService: IFileService, @IEditorService private editorService: IWorkbenchEditorService, @IInstantiationService private instantiationService: IInstantiationService, - @ITextModelResolverService private textModelResolverService: ITextModelResolverService, + @ITextModelService private textModelResolverService: ITextModelService, @ISearchWorkbenchService private searchWorkbenchService: ISearchWorkbenchService ) { } diff --git a/src/vs/workbench/parts/welcome/walkThrough/node/walkThroughContentProvider.ts b/src/vs/workbench/parts/welcome/walkThrough/node/walkThroughContentProvider.ts index 426918e274c..2fff2ba3f71 100644 --- a/src/vs/workbench/parts/welcome/walkThrough/node/walkThroughContentProvider.ts +++ b/src/vs/workbench/parts/welcome/walkThrough/node/walkThroughContentProvider.ts @@ -7,7 +7,7 @@ import { TPromise } from 'vs/base/common/winjs.base'; import URI from 'vs/base/common/uri'; -import { ITextModelResolverService, ITextModelContentProvider } from 'vs/editor/common/services/resolverService'; +import { ITextModelService, ITextModelContentProvider } from 'vs/editor/common/services/resolverService'; import { IModelService } from 'vs/editor/common/services/modelService'; import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; import { IModel } from 'vs/editor/common/editorCommon'; @@ -20,7 +20,7 @@ import { IRawTextSource } from 'vs/editor/common/model/textSource'; export class WalkThroughContentProvider implements ITextModelContentProvider, IWorkbenchContribution { constructor( - @ITextModelResolverService private textModelResolverService: ITextModelResolverService, + @ITextModelService private textModelResolverService: ITextModelService, @ITextFileService private textFileService: ITextFileService, @IModeService private modeService: IModeService, @IModelService private modelService: IModelService, @@ -59,7 +59,7 @@ export class WalkThroughContentProvider implements ITextModelContentProvider, IW export class WalkThroughSnippetContentProvider implements ITextModelContentProvider, IWorkbenchContribution { constructor( - @ITextModelResolverService private textModelResolverService: ITextModelResolverService, + @ITextModelService private textModelResolverService: ITextModelService, @ITextFileService private textFileService: ITextFileService, @IModeService private modeService: IModeService, @IModelService private modelService: IModelService, @@ -102,4 +102,4 @@ export class WalkThroughSnippetContentProvider implements ITextModelContentProvi public getId(): string { return 'vs.walkThroughSnippetContentProvider'; } -} \ No newline at end of file +} diff --git a/src/vs/workbench/parts/welcome/walkThrough/node/walkThroughInput.ts b/src/vs/workbench/parts/welcome/walkThrough/node/walkThroughInput.ts index 9a86c171ae6..889fdc162ed 100644 --- a/src/vs/workbench/parts/welcome/walkThrough/node/walkThroughInput.ts +++ b/src/vs/workbench/parts/welcome/walkThrough/node/walkThroughInput.ts @@ -10,7 +10,7 @@ import { EditorInput, EditorModel, ITextEditorModel } from 'vs/workbench/common/ import URI from 'vs/base/common/uri'; import { IReference, IDisposable, dispose } from 'vs/base/common/lifecycle'; import { telemetryURIDescriptor } from 'vs/platform/telemetry/common/telemetryUtils'; -import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextModelService } from 'vs/editor/common/services/resolverService'; import { marked } from 'vs/base/common/marked/marked'; import { Schemas } from 'vs/base/common/network'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; @@ -60,7 +60,7 @@ export class WalkThroughInput extends EditorInput { public readonly onReady: (container: HTMLElement) => void, @ITelemetryService private telemetryService: ITelemetryService, @ILifecycleService lifecycleService: ILifecycleService, - @ITextModelResolverService private textModelResolverService: ITextModelResolverService + @ITextModelService private textModelResolverService: ITextModelService ) { super(); this.disposables.push(lifecycleService.onShutdown(e => this.disposeTelemetry(e))); diff --git a/src/vs/workbench/services/configuration/node/configurationEditingService.ts b/src/vs/workbench/services/configuration/node/configurationEditingService.ts index a2ace0b1b2c..7d8534f8747 100644 --- a/src/vs/workbench/services/configuration/node/configurationEditingService.ts +++ b/src/vs/workbench/services/configuration/node/configurationEditingService.ts @@ -27,7 +27,7 @@ import { keyFromOverrideIdentifier } from 'vs/platform/configuration/common/mode import { WORKSPACE_CONFIG_DEFAULT_PATH, WORKSPACE_STANDALONE_CONFIGURATIONS } from 'vs/workbench/services/configuration/common/configuration'; import { IFileService } from 'vs/platform/files/common/files'; import { IConfigurationEditingService, ConfigurationEditingErrorCode, IConfigurationEditingError, ConfigurationTarget, IConfigurationValue, IConfigurationEditingOptions } from 'vs/workbench/services/configuration/common/configurationEditing'; -import { ITextModelResolverService, ITextEditorModel } from 'vs/editor/common/services/resolverService'; +import { ITextModelService, ITextEditorModel } from 'vs/editor/common/services/resolverService'; import { OVERRIDE_PROPERTY_PATTERN } from 'vs/platform/configuration/common/configurationRegistry'; import { IChoiceService, IMessageService, Severity } from 'vs/platform/message/common/message'; import { ICommandService } from 'vs/platform/commands/common/commands'; @@ -57,7 +57,7 @@ export class ConfigurationEditingService implements IConfigurationEditingService @IWorkspaceContextService private contextService: IWorkspaceContextService, @IEnvironmentService private environmentService: IEnvironmentService, @IFileService private fileService: IFileService, - @ITextModelResolverService private textModelResolverService: ITextModelResolverService, + @ITextModelService private textModelResolverService: ITextModelService, @ITextFileService private textFileService: ITextFileService, @IChoiceService private choiceService: IChoiceService, @IMessageService private messageService: IMessageService, @@ -285,4 +285,4 @@ export class ConfigurationEditingService implements IConfigurationEditingService return { key: config.key, value: config.value, overrideIdentifier: config.overrideIdentifier, resource: this.contextService.toResource(WORKSPACE_CONFIG_DEFAULT_PATH) }; } -} \ No newline at end of file +} diff --git a/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts b/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts index dfba23f324a..9ce0d3b7fd5 100644 --- a/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts +++ b/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts @@ -37,7 +37,7 @@ import { IBackupFileService } from 'vs/workbench/services/backup/common/backup'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { TestInstantiationService } from 'vs/platform/instantiation/test/common/instantiationServiceMock'; import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; -import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextModelService } from 'vs/editor/common/services/resolverService'; import { TextModelResolverService } from 'vs/workbench/services/textmodelResolver/common/textModelResolverService'; import { IModeService } from 'vs/editor/common/services/modeService'; import { ModeServiceImpl } from 'vs/editor/common/services/modeServiceImpl'; @@ -128,7 +128,7 @@ suite('ConfigurationEditingService', () => { instantiationService.stub(IUntitledEditorService, instantiationService.createInstance(UntitledEditorService)); instantiationService.stub(ITextFileService, instantiationService.createInstance(TestTextFileService)); - instantiationService.stub(ITextModelResolverService, instantiationService.createInstance(TextModelResolverService)); + instantiationService.stub(ITextModelService, instantiationService.createInstance(TextModelResolverService)); instantiationService.stub(IBackupFileService, new TestBackupFileService()); choiceService = instantiationService.stub(IChoiceService, { choose: (severity, message, options, cancelId): TPromise => { @@ -311,4 +311,4 @@ suite('ConfigurationEditingService', () => { assert.equal(parsed['tasks'][0]['taskName'], 'myTask'); }); }); -}); \ No newline at end of file +}); diff --git a/src/vs/workbench/services/keybinding/common/keybindingEditing.ts b/src/vs/workbench/services/keybinding/common/keybindingEditing.ts index 6e0ad503e6b..abfa76b0210 100644 --- a/src/vs/workbench/services/keybinding/common/keybindingEditing.ts +++ b/src/vs/workbench/services/keybinding/common/keybindingEditing.ts @@ -20,7 +20,7 @@ import { Range } from 'vs/editor/common/core/range'; import { Selection } from 'vs/editor/common/core/selection'; import { IUserFriendlyKeybinding } from 'vs/platform/keybinding/common/keybinding'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; -import { ITextModelResolverService, ITextEditorModel } from 'vs/editor/common/services/resolverService'; +import { ITextModelService, ITextEditorModel } from 'vs/editor/common/services/resolverService'; import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; import { IFileService } from 'vs/platform/files/common/files'; import { createDecorator, ServiceIdentifier } from 'vs/platform/instantiation/common/instantiation'; @@ -48,7 +48,7 @@ export class KeybindingsEditingService extends Disposable implements IKeybinding private resource: URI = URI.file(this.environmentService.appKeybindingsPath); constructor( - @ITextModelResolverService private textModelResolverService: ITextModelResolverService, + @ITextModelService private textModelResolverService: ITextModelService, @ITextFileService private textFileService: ITextFileService, @IFileService private fileService: IFileService, @IConfigurationService private configurationService: IConfigurationService, @@ -262,4 +262,4 @@ export class KeybindingsEditingService extends Disposable implements IKeybinding private getEmptyContent(EOL: string): string { return '// ' + localize('emptyKeybindingsHeader', "Place your key bindings in this file to overwrite the defaults") + EOL + '[]'; } -} \ No newline at end of file +} diff --git a/src/vs/workbench/services/keybinding/test/keybindingEditing.test.ts b/src/vs/workbench/services/keybinding/test/keybindingEditing.test.ts index cc4495e14e9..dc64fc81dfd 100644 --- a/src/vs/workbench/services/keybinding/test/keybindingEditing.test.ts +++ b/src/vs/workbench/services/keybinding/test/keybindingEditing.test.ts @@ -31,7 +31,7 @@ import { IBackupFileService } from 'vs/workbench/services/backup/common/backup'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { TestInstantiationService } from 'vs/platform/instantiation/test/common/instantiationServiceMock'; import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; -import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextModelService } from 'vs/editor/common/services/resolverService'; import { TextModelResolverService } from 'vs/workbench/services/textmodelResolver/common/textModelResolverService'; import { IModeService } from 'vs/editor/common/services/modeService'; import { ModeServiceImpl } from 'vs/editor/common/services/modeServiceImpl'; @@ -76,7 +76,7 @@ suite('Keybindings Editing', () => { instantiationService.stub(IFileService, new FileService(testDir, { disableWatcher: true })); instantiationService.stub(IUntitledEditorService, instantiationService.createInstance(UntitledEditorService)); instantiationService.stub(ITextFileService, instantiationService.createInstance(TestTextFileService)); - instantiationService.stub(ITextModelResolverService, instantiationService.createInstance(TextModelResolverService)); + instantiationService.stub(ITextModelService, instantiationService.createInstance(TextModelResolverService)); instantiationService.stub(IBackupFileService, new TestBackupFileService()); testObject = instantiationService.createInstance(KeybindingsEditingService); @@ -226,4 +226,4 @@ suite('Keybindings Editing', () => { return new ResolvedKeybindingItem(keybinding ? new USLayoutResolvedKeybinding(keybinding, OS) : null, command || 'some command', null, when ? ContextKeyExpr.deserialize(when) : null, isDefault === void 0 ? true : isDefault); } -}); \ No newline at end of file +}); diff --git a/src/vs/workbench/services/textmodelResolver/common/textModelResolverService.ts b/src/vs/workbench/services/textmodelResolver/common/textModelResolverService.ts index f3c7ba8d7a0..f8f99979212 100644 --- a/src/vs/workbench/services/textmodelResolver/common/textModelResolverService.ts +++ b/src/vs/workbench/services/textmodelResolver/common/textModelResolverService.ts @@ -14,7 +14,7 @@ import { IModelService } from 'vs/editor/common/services/modelService'; import { ResourceEditorModel } from 'vs/workbench/common/editor/resourceEditorModel'; import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; import network = require('vs/base/common/network'); -import { ITextModelResolverService, ITextModelContentProvider, ITextEditorModel } from 'vs/editor/common/services/resolverService'; +import { ITextModelService, ITextModelContentProvider, ITextEditorModel } from 'vs/editor/common/services/resolverService'; import { IUntitledEditorService, UNTITLED_SCHEMA } from 'vs/workbench/services/untitled/common/untitledEditorService'; import { TextFileEditorModel } from 'vs/workbench/services/textfile/common/textFileEditorModel'; @@ -92,7 +92,7 @@ class ResourceModelCollection extends ReferenceCollection { disposable.dispose(); }); -}); \ No newline at end of file +}); diff --git a/src/vs/workbench/test/common/editor/editorDiffModel.test.ts b/src/vs/workbench/test/common/editor/editorDiffModel.test.ts index 91541187e84..b2e26b3ec57 100644 --- a/src/vs/workbench/test/common/editor/editorDiffModel.test.ts +++ b/src/vs/workbench/test/common/editor/editorDiffModel.test.ts @@ -14,7 +14,7 @@ import { IModelService } from 'vs/editor/common/services/modelService'; import { IModeService } from 'vs/editor/common/services/modeService'; import { ResourceEditorInput } from 'vs/workbench/common/editor/resourceEditorInput'; import URI from 'vs/base/common/uri'; -import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextModelService } from 'vs/editor/common/services/resolverService'; import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; import { TestTextFileService, workbenchInstantiationService } from 'vs/workbench/test/workbenchTestServices'; import { TPromise } from "vs/base/common/winjs.base"; @@ -26,7 +26,7 @@ class MyTextEditorModel extends BaseTextEditorModel { } class ServiceAccessor { constructor( - @ITextModelResolverService public textModelResolverService: ITextModelResolverService, + @ITextModelService public textModelResolverService: ITextModelService, @IModelService public modelService: IModelService, @IModeService public modeService: IModeService, @ITextFileService public textFileService: TestTextFileService @@ -81,4 +81,4 @@ suite('Workbench - EditorModel', () => { done(); }); }); -}); \ No newline at end of file +}); diff --git a/src/vs/workbench/test/workbenchTestServices.ts b/src/vs/workbench/test/workbenchTestServices.ts index 14736493081..c280cd4c979 100644 --- a/src/vs/workbench/test/workbenchTestServices.ts +++ b/src/vs/workbench/test/workbenchTestServices.ts @@ -23,7 +23,7 @@ import { IConfigurationService } from 'vs/platform/configuration/common/configur import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage'; import { IPartService, Parts } from 'vs/workbench/services/part/common/partService'; import { TextModelResolverService } from 'vs/workbench/services/textmodelResolver/common/textModelResolverService'; -import { ITextModelResolverService } from 'vs/editor/common/services/resolverService'; +import { ITextModelService } from 'vs/editor/common/services/resolverService'; import { IEditorInput, IEditorOptions, Position, Direction, IEditor, IResourceInput } from 'vs/platform/editor/common/editor'; import { IUntitledEditorService, UntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; import { IMessageService, IConfirmation } from 'vs/platform/message/common/message'; @@ -223,7 +223,7 @@ export function workbenchInstantiationService(): IInstantiationService { instantiationService.stub(IUntitledEditorService, instantiationService.createInstance(UntitledEditorService)); instantiationService.stub(IWindowsService, new TestWindowsService()); instantiationService.stub(ITextFileService, instantiationService.createInstance(TestTextFileService)); - instantiationService.stub(ITextModelResolverService, instantiationService.createInstance(TextModelResolverService)); + instantiationService.stub(ITextModelService, instantiationService.createInstance(TextModelResolverService)); instantiationService.stub(IEnvironmentService, TestEnvironmentService); instantiationService.stub(IThemeService, new TestThemeService()); -- GitLab From 4f26974fdd1f00e22e82c407306a2c77716b1dd8 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Tue, 13 Jun 2017 16:00:17 +0200 Subject: [PATCH 0774/1347] First cut of #23752: Task dialog switches to output view --- src/vs/workbench/parts/tasks/common/taskSystem.ts | 1 + .../tasks/electron-browser/task.contribution.ts | 12 ++++++++++-- .../tasks/electron-browser/terminalTaskSystem.ts | 9 +++++++++ .../workbench/parts/tasks/node/processTaskSystem.ts | 4 ++++ 4 files changed, 24 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/tasks/common/taskSystem.ts b/src/vs/workbench/parts/tasks/common/taskSystem.ts index 30e51e8a2e3..b61a8fbc863 100644 --- a/src/vs/workbench/parts/tasks/common/taskSystem.ts +++ b/src/vs/workbench/parts/tasks/common/taskSystem.ts @@ -100,6 +100,7 @@ export interface ITaskResolver { export interface ITaskSystem extends IEventEmitter { run(task: Task, resolver: ITaskResolver): ITaskExecuteResult; + show(task: Task, forceFocus?: boolean): void; isActive(): TPromise; isActiveSync(): boolean; getActiveTasks(): Task[]; diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index f4d4872c6d9..529b36f8f0c 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -444,6 +444,9 @@ class NullTaskSystem extends EventEmitter implements ITaskSystem { promise: TPromise.as({}) }; } + public show(task: Task, forceFocus: boolean = false): void { + return; + } public isActive(): TPromise { return TPromise.as(false); } @@ -929,8 +932,13 @@ class TaskService extends EventEmitter implements ITaskService { let executeResult = this.getTaskSystem().run(task, resolver); if (executeResult.kind === TaskExecuteKind.Active) { let active = executeResult.active; - if (active.same && active.background) { - this.messageService.show(Severity.Info, nls.localize('TaskSystem.activeSame', 'The task is already active and in watch mode. To terminate the task use `F1 > terminate task`')); + if (active.same) { + if (active.background) { + this.messageService.show(Severity.Info, nls.localize('TaskSystem.activeSame.background', 'The task is already active and in background mode. To terminate the task use `F1 > terminate task`')); + } else { + this.getTaskSystem().show(task, true); + // this.messageService.show(Severity.Info, nls.localize('TaskSystem.activeSame.noBackground', 'The task is already active. To terminate the task use `F1 > terminate task`')); + } } else { throw new TaskError(Severity.Warning, nls.localize('TaskSystem.active', 'There is already a task running. Terminate it first before executing another task.'), TaskErrors.RunningTask); } diff --git a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts index b22d2788cb3..3bdec71f2ec 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts @@ -156,6 +156,15 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { } } + public show(task: Task, forceFocus: boolean = false): void { + let terminalData = this.activeTasks[task._id]; + if (terminalData === void 0) { + return; + } + this.terminalService.setActiveInstance(terminalData.terminal); + this.terminalService.showPanel(forceFocus); + } + public isActive(): TPromise { return TPromise.as(this.isActiveSync()); } diff --git a/src/vs/workbench/parts/tasks/node/processTaskSystem.ts b/src/vs/workbench/parts/tasks/node/processTaskSystem.ts index 0db8946a2d2..c6e4d70add9 100644 --- a/src/vs/workbench/parts/tasks/node/processTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/node/processTaskSystem.ts @@ -89,6 +89,10 @@ export class ProcessTaskSystem extends EventEmitter implements ITaskSystem { return this.executeTask(task); } + public show(task: Task, forceFocus: boolean = false): void { + this.outputChannel.show(!focus); + } + public hasErrors(value: boolean): void { this.errorsShown = !value; } -- GitLab From ac4bc6116eb7d8819bedbfca39d4dbfb95cf2eb7 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Tue, 13 Jun 2017 16:03:05 +0200 Subject: [PATCH 0775/1347] Code tidy up. --- .../debug/electron-browser/debugEditorContribution.ts | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.ts b/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.ts index e33c15a909f..4870b633470 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.ts @@ -38,6 +38,7 @@ import { IListService } from 'vs/platform/list/browser/listService'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { Position } from 'vs/editor/common/core/position'; import { CoreEditingCommands } from 'vs/editor/common/controller/coreCommands'; +import { first } from 'vs/base/common/arrays'; const HOVER_DELAY = 300; const LAUNCH_JSON_REGEX = /launch\.json$/; @@ -363,13 +364,7 @@ export class DebugEditorContribution implements IDebugEditorContribution { } // First call stack frame that is available is the frame where exception has been thrown - let exceptionSf; - for (let sf of callStack) { - if (sf.source && sf.source.available) { - exceptionSf = sf; - break; - } - } + const exceptionSf = first(callStack, sf => sf.source && sf.source.available, undefined); if (!exceptionSf) { this.closeExceptionWidget(); return; -- GitLab From cfd4a2087ead99d320dd6857998471cb59ceedb5 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Tue, 13 Jun 2017 16:46:45 +0200 Subject: [PATCH 0776/1347] debt - remove boilerplate code --- src/vs/base/common/lifecycle.ts | 16 ---------------- .../referenceSearch/browser/referencesWidget.ts | 10 +++++----- .../contrib/zoneWidget/browser/zoneWidget.ts | 14 +++++++------- src/vs/workbench/electron-browser/shell.ts | 16 ++++++++-------- .../parts/debug/browser/exceptionWidget.ts | 6 +++--- 5 files changed, 23 insertions(+), 39 deletions(-) diff --git a/src/vs/base/common/lifecycle.ts b/src/vs/base/common/lifecycle.ts index 1a17d2a524f..b392ef7768c 100644 --- a/src/vs/base/common/lifecycle.ts +++ b/src/vs/base/common/lifecycle.ts @@ -62,22 +62,6 @@ export abstract class Disposable implements IDisposable { } } -export class Disposables extends Disposable { - - public add(e: T): T; - public add(...elements: IDisposable[]): void; - public add(arg: T | T[]): T { - if (!Array.isArray(arg)) { - return this._register(arg); - } else { - for (let element of arg) { - return this._register(element); - } - return undefined; - } - } -} - export class OneDisposable implements IDisposable { private _value: IDisposable; diff --git a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts index 7ad1761a1b9..a0603d8f948 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts +++ b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts @@ -10,7 +10,7 @@ import { alert } from 'vs/base/browser/ui/aria/aria'; import { onUnexpectedError } from 'vs/base/common/errors'; import { getPathLabel } from 'vs/base/common/labels'; import Event, { Emitter } from 'vs/base/common/event'; -import { IDisposable, dispose, Disposables, IReference } from 'vs/base/common/lifecycle'; +import { IDisposable, dispose, IReference } from 'vs/base/common/lifecycle'; import { Schemas } from 'vs/base/common/network'; import * as strings from 'vs/base/common/strings'; import { TPromise } from 'vs/base/common/winjs.base'; @@ -484,7 +484,7 @@ class AriaProvider implements tree.IAccessibilityProvider { class VSash { - private _disposables = new Disposables(); + private _disposables: IDisposable[] = []; private _sash: Sash; private _ratio: number; private _height: number; @@ -501,11 +501,11 @@ class VSash { // compute the current widget clientX postion since // the sash works with clientX when dragging let clientX: number; - this._disposables.add(this._sash.addListener('start', (e: ISashEvent) => { + this._disposables.push(this._sash.addListener('start', (e: ISashEvent) => { clientX = e.startX - (this._width * this.ratio); })); - this._disposables.add(this._sash.addListener('change', (e: ISashEvent) => { + this._disposables.push(this._sash.addListener('change', (e: ISashEvent) => { // compute the new position of the sash and from that // compute the new ratio that we are using let newLeft = e.currentX - clientX; @@ -520,7 +520,7 @@ class VSash { dispose() { this._sash.dispose(); this._onDidChangePercentages.dispose(); - this._disposables.dispose(); + dispose(this._disposables); } get onDidChangePercentages() { diff --git a/src/vs/editor/contrib/zoneWidget/browser/zoneWidget.ts b/src/vs/editor/contrib/zoneWidget/browser/zoneWidget.ts index dc599a468bf..4764ae690e5 100644 --- a/src/vs/editor/contrib/zoneWidget/browser/zoneWidget.ts +++ b/src/vs/editor/contrib/zoneWidget/browser/zoneWidget.ts @@ -6,7 +6,7 @@ 'use strict'; import 'vs/css!./zoneWidget'; -import { Disposables } from 'vs/base/common/lifecycle'; +import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { Widget } from 'vs/base/browser/ui/widget'; import * as objects from 'vs/base/common/objects'; import * as dom from 'vs/base/browser/dom'; @@ -109,7 +109,7 @@ export abstract class ZoneWidget extends Widget implements IHorizontalSashLayout private _positionMarkerId: string[] = []; protected _viewZone: ViewZoneDelegate = null; - protected _disposables = new Disposables(); + protected _disposables: IDisposable[] = []; public container: HTMLElement = null; public domNode: HTMLElement; @@ -128,7 +128,7 @@ export abstract class ZoneWidget extends Widget implements IHorizontalSashLayout this.domNode.setAttribute('role', 'presentation'); } - this._disposables.add(this.editor.onDidLayoutChange((info: EditorLayoutInfo) => { + this._disposables.push(this.editor.onDidLayoutChange((info: EditorLayoutInfo) => { const width = this._getWidth(info); this.domNode.style.width = width + 'px'; this._onWidth(width); @@ -137,7 +137,7 @@ export abstract class ZoneWidget extends Widget implements IHorizontalSashLayout public dispose(): void { - this._disposables.dispose(); + dispose(this._disposables); if (this._overlayWidget) { this.editor.removeOverlayWidget(this._overlayWidget); @@ -392,7 +392,7 @@ export abstract class ZoneWidget extends Widget implements IHorizontalSashLayout } let data: { startY: number; heightInLines: number; }; - this._disposables.add(this._resizeSash.addListener('start', (e: ISashEvent) => { + this._disposables.push(this._resizeSash.addListener('start', (e: ISashEvent) => { if (this._viewZone) { data = { startY: e.startY, @@ -401,11 +401,11 @@ export abstract class ZoneWidget extends Widget implements IHorizontalSashLayout } })); - this._disposables.add(this._resizeSash.addListener('end', () => { + this._disposables.push(this._resizeSash.addListener('end', () => { data = undefined; })); - this._disposables.add(this._resizeSash.addListener('change', (evt: ISashEvent) => { + this._disposables.push(this._resizeSash.addListener('change', (evt: ISashEvent) => { if (data) { let lineDelta = (evt.currentY - data.startY) / this.editor.getConfiguration().lineHeight; let roundedLineDelta = lineDelta < 0 ? Math.ceil(lineDelta) : Math.floor(lineDelta); diff --git a/src/vs/workbench/electron-browser/shell.ts b/src/vs/workbench/electron-browser/shell.ts index 00becc599ff..141b3285c0a 100644 --- a/src/vs/workbench/electron-browser/shell.ts +++ b/src/vs/workbench/electron-browser/shell.ts @@ -13,7 +13,7 @@ import * as platform from 'vs/base/common/platform'; import { Dimension, Builder, $ } from 'vs/base/browser/builder'; import dom = require('vs/base/browser/dom'); import aria = require('vs/base/browser/ui/aria/aria'); -import { dispose, IDisposable, Disposables } from 'vs/base/common/lifecycle'; +import { dispose, IDisposable } from 'vs/base/common/lifecycle'; import errors = require('vs/base/common/errors'); import { toErrorMessage } from 'vs/base/common/errorMessage'; import product from 'vs/platform/node/product'; @@ -244,7 +244,7 @@ export class WorkbenchShell { } private initServiceCollection(container: HTMLElement): [IInstantiationService, ServiceCollection] { - const disposables = new Disposables(); + const disposables: IDisposable[] = []; const serviceCollection = new ServiceCollection(); serviceCollection.set(IWorkspaceContextService, this.contextService); @@ -259,7 +259,7 @@ export class WorkbenchShell { serviceCollection.set(IWindowIPCService, this.windowIPCService); const mainProcessClient = new ElectronIPCClient(String(`window${currentWindow.id}`)); - disposables.add(mainProcessClient); + disposables.push(mainProcessClient); const windowsChannel = mainProcessClient.getChannel('windows'); this.windowsService = new WindowsChannelClient(windowsChannel); @@ -319,14 +319,14 @@ export class WorkbenchShell { : TelemetryService.IDLE_START_EVENT_NAME )); - disposables.add(telemetryService, errorTelemetry, listener, idleMonitor); + disposables.push(telemetryService, errorTelemetry, listener, idleMonitor); } else { NullTelemetryService._experiments = instantiationService.invokeFunction(loadExperiments); this.telemetryService = NullTelemetryService; } serviceCollection.set(ITelemetryService, this.telemetryService); - disposables.add(configurationTelemetry(this.telemetryService, this.configurationService)); + disposables.push(configurationTelemetry(this.telemetryService, this.configurationService)); let crashReporterService = NullCrashReporterService; if (product.crashReporter && product.hockeyApp) { @@ -339,10 +339,10 @@ export class WorkbenchShell { serviceCollection.set(IChoiceService, this.messageService); const lifecycleService = instantiationService.createInstance(LifecycleService); - this.toUnbind.push(lifecycleService.onShutdown(reason => disposables.dispose())); + this.toUnbind.push(lifecycleService.onShutdown(reason => dispose(disposables))); this.toUnbind.push(lifecycleService.onShutdown(reason => saveFontInfo(this.storageService))); serviceCollection.set(ILifecycleService, lifecycleService); - disposables.add(lifecycleTelemetry(this.telemetryService, lifecycleService)); + disposables.push(lifecycleTelemetry(this.telemetryService, lifecycleService)); this.lifecycleService = lifecycleService; const extensionManagementChannel = getDelayedChannel(sharedProcess.then(c => c.getChannel('extensions'))); @@ -350,7 +350,7 @@ export class WorkbenchShell { const extensionEnablementService = instantiationService.createInstance(ExtensionEnablementService); serviceCollection.set(IExtensionEnablementService, extensionEnablementService); - disposables.add(extensionEnablementService); + disposables.push(extensionEnablementService); const extensionHostProcessWorker = instantiationService.createInstance(ExtensionHostProcessWorker); this.threadService = instantiationService.createInstance(MainThreadService, extensionHostProcessWorker.messagingProtocol); diff --git a/src/vs/workbench/parts/debug/browser/exceptionWidget.ts b/src/vs/workbench/parts/debug/browser/exceptionWidget.ts index 70004ffb526..3719a86393b 100644 --- a/src/vs/workbench/parts/debug/browser/exceptionWidget.ts +++ b/src/vs/workbench/parts/debug/browser/exceptionWidget.ts @@ -38,13 +38,13 @@ export class ExceptionWidget extends ZoneWidget { this._backgroundColor = Color.white; this._applyTheme(themeService.getTheme()); - this._disposables.add(themeService.onThemeChange(this._applyTheme.bind(this))); + this._disposables.push(themeService.onThemeChange(this._applyTheme.bind(this))); this.create(); const onDidLayoutChangeScheduler = new RunOnceScheduler(() => this._doLayout(undefined, undefined), 50); - this._disposables.add(this.editor.onDidLayoutChange(() => onDidLayoutChangeScheduler.schedule())); - this._disposables.add(onDidLayoutChangeScheduler); + this._disposables.push(this.editor.onDidLayoutChange(() => onDidLayoutChangeScheduler.schedule())); + this._disposables.push(onDidLayoutChangeScheduler); } private _applyTheme(theme: ITheme): void { -- GitLab From cf06cc073986ed34b06e8f144b978976cbf5c35f Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Tue, 13 Jun 2017 16:51:03 +0200 Subject: [PATCH 0777/1347] debt - simplify stuff --- src/vs/base/common/lifecycle.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/vs/base/common/lifecycle.ts b/src/vs/base/common/lifecycle.ts index b392ef7768c..2600d72e9ef 100644 --- a/src/vs/base/common/lifecycle.ts +++ b/src/vs/base/common/lifecycle.ts @@ -41,7 +41,13 @@ export function combinedDisposable(disposables: IDisposable[]): IDisposable { } export function toDisposable(...fns: (() => void)[]): IDisposable { - return combinedDisposable(fns.map(fn => ({ dispose: fn }))); + return { + dispose() { + for (const fn of fns) { + fn(); + } + } + }; } export abstract class Disposable implements IDisposable { -- GitLab From 97d8f90657204315794da82ec344d7b3785b405d Mon Sep 17 00:00:00 2001 From: isidor Date: Tue, 13 Jun 2017 17:01:42 +0200 Subject: [PATCH 0778/1347] debug: have a scheduler per thread fixes #28536 --- .../parts/debug/common/debugModel.ts | 38 ++++++++++++------- .../debug/electron-browser/debugService.ts | 16 -------- .../debug/electron-browser/debugViewer.ts | 4 +- 3 files changed, 27 insertions(+), 31 deletions(-) diff --git a/src/vs/workbench/parts/debug/common/debugModel.ts b/src/vs/workbench/parts/debug/common/debugModel.ts index 702ada257df..23f762661b4 100644 --- a/src/vs/workbench/parts/debug/common/debugModel.ts +++ b/src/vs/workbench/parts/debug/common/debugModel.ts @@ -9,6 +9,8 @@ import { TPromise } from 'vs/base/common/winjs.base'; import * as lifecycle from 'vs/base/common/lifecycle'; import Event, { Emitter } from 'vs/base/common/event'; import { generateUuid } from 'vs/base/common/uuid'; +import * as errors from 'vs/base/common/errors'; +import { RunOnceScheduler } from 'vs/base/common/async'; import { clone } from 'vs/base/common/objects'; import severity from 'vs/base/common/severity'; import { isObject, isString } from 'vs/base/common/types'; @@ -435,22 +437,14 @@ export class Thread implements IThread { * Only fetches the first stack frame for performance reasons. Calling this method consecutive times * gets the remainder of the call stack. */ - public fetchCallStack(smartFetch = true): TPromise { + public fetchCallStack(levels = 20): TPromise { if (!this.stopped) { return TPromise.as(null); } - if (!this.fetchPromise && smartFetch) { - this.fetchPromise = this.getCallStackImpl(0, 1).then(callStack => { - this.callStack = callStack || []; - }); - } else { - this.fetchPromise = (this.fetchPromise || TPromise.as(null)).then(() => this.getCallStackImpl(this.callStack.length, 20).then(callStackSecondPart => { - this.callStack = this.callStack.concat(callStackSecondPart); - })); - } - - return this.fetchPromise; + return this.getCallStackImpl(this.callStack.length, levels).then(callStack => { + this.callStack = this.callStack.concat(callStack || []); + }); } private getCallStackImpl(startFrame: number, levels: number): TPromise { @@ -738,6 +732,7 @@ export class Model implements IModel { private processes: Process[]; private toDispose: lifecycle.IDisposable[]; private replElements: IReplElement[]; + private schedulers = new Map(); private _onDidChangeBreakpoints: Emitter; private _onDidChangeCallStack: Emitter; private _onDidChangeWatchExpressions: Emitter; @@ -805,6 +800,9 @@ export class Model implements IModel { public clearThreads(id: string, removeThreads: boolean, reference: number = undefined): void { const process = this.processes.filter(p => p.getId() === id).pop(); + this.schedulers.forEach(scheduler => scheduler.dispose()); + this.schedulers.clear(); + if (process) { process.clearThreads(removeThreads, reference); this._onDidChangeCallStack.fire(); @@ -812,7 +810,21 @@ export class Model implements IModel { } public fetchCallStack(thread: IThread): TPromise { - return (thread).fetchCallStack().then(() => { + return (thread).fetchCallStack(1).then(() => { + if (!this.schedulers.has(thread.getId())) { + this.schedulers.set(thread.getId(), new RunOnceScheduler(() => { + const callStack = thread.getCallStack(); + // Some adapters might not respect the number levels in StackTraceRequest and might + // return more stackFrames than requested. For those do not send an additional stackTrace request. + if (callStack.length <= 1) { + (thread).fetchCallStack(19).done(() => { + this._onDidChangeCallStack.fire(); + }, errors.onUnexpectedError); + } + }, 420)); + } + + this.schedulers.get(thread.getId()).schedule(); this._onDidChangeCallStack.fire(); }); } diff --git a/src/vs/workbench/parts/debug/electron-browser/debugService.ts b/src/vs/workbench/parts/debug/electron-browser/debugService.ts index 0f363b20908..40c3ce62b05 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugService.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugService.ts @@ -7,7 +7,6 @@ import * as nls from 'vs/nls'; import * as lifecycle from 'vs/base/common/lifecycle'; import Event, { Emitter } from 'vs/base/common/event'; import * as paths from 'vs/base/common/paths'; -import { RunOnceScheduler } from 'vs/base/common/async'; import * as strings from 'vs/base/common/strings'; import { generateUuid } from 'vs/base/common/uuid'; import uri from 'vs/base/common/uri'; @@ -80,9 +79,7 @@ export class DebugService implements debug.IDebugService { private debugType: IContextKey; private debugState: IContextKey; private breakpointsToSendOnResourceSaved: Set; - private callStackScheduler: RunOnceScheduler; private launchJsonChanged: boolean; - private threadToFetch: debug.IThread; constructor( @IStorageService private storageService: IStorageService, @@ -121,17 +118,6 @@ export class DebugService implements debug.IDebugService { this.loadExceptionBreakpoints(), this.loadWatchExpressions()); this.toDispose.push(this.model); this.viewModel = new ViewModel(this.storageService.get(DEBUG_SELECTED_CONFIG_NAME_KEY, StorageScope.WORKSPACE, null)); - this.callStackScheduler = new RunOnceScheduler(() => { - if (this.threadToFetch) { - const callStack = this.threadToFetch.getCallStack(); - // Some adapters might not respect the number levels in StackTraceRequest and might - // return more stackFrames than requested. For those do not send an additional stackTrace request. - if (callStack.length <= 1) { - this.model.fetchCallStack(this.threadToFetch).done(() => - this.tryToAutoFocusStackFrame(this.threadToFetch), errors.onUnexpectedError); - } - } - }, 420); this.registerListeners(lifecycleService); } @@ -330,8 +316,6 @@ export class DebugService implements debug.IDebugService { // Call fetch call stack twice, the first only return the top stack frame. // Second retrieves the rest of the call stack. For performance reasons #25605 this.model.fetchCallStack(thread).then(() => { - this.threadToFetch = thread; - this.callStackScheduler.schedule(); return this.tryToAutoFocusStackFrame(thread); }); } diff --git a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts index b7bd340b853..81b08439bd2 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugViewer.ts @@ -366,9 +366,9 @@ export class CallStackDataSource implements IDataSource { } private getThreadChildren(thread: Thread): TPromise { - const callStack: any[] = thread.getCallStack(); + let callStack: any[] = thread.getCallStack(); if (!callStack || !callStack.length) { - return thread.fetchCallStack(false).then(() => thread.getCallStack()); + thread.fetchCallStack().then(() => callStack = thread.getCallStack()); } if (callStack.length === 1) { // To reduce flashing of the call stack view simply append the stale call stack -- GitLab From b5acc69cbf1bdbc3329b01eef2ba9fa61b9c21f8 Mon Sep 17 00:00:00 2001 From: isidor Date: Tue, 13 Jun 2017 17:17:03 +0200 Subject: [PATCH 0779/1347] explorerViewModel.ts -> explorerModel.ts --- .../workbench/parts/files/browser/fileActions.contribution.ts | 2 +- src/vs/workbench/parts/files/browser/fileActions.ts | 2 +- src/vs/workbench/parts/files/browser/fileCommands.ts | 2 +- src/vs/workbench/parts/files/browser/views/explorerView.ts | 2 +- src/vs/workbench/parts/files/browser/views/explorerViewer.ts | 2 +- src/vs/workbench/parts/files/browser/views/openEditorsView.ts | 2 +- src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts | 2 +- .../files/common/{explorerViewModel.ts => explorerModel.ts} | 0 src/vs/workbench/parts/files/common/files.ts | 2 +- .../parts/files/test/browser/explorerViewModel.test.ts | 2 +- 10 files changed, 9 insertions(+), 9 deletions(-) rename src/vs/workbench/parts/files/common/{explorerViewModel.ts => explorerModel.ts} (100%) diff --git a/src/vs/workbench/parts/files/browser/fileActions.contribution.ts b/src/vs/workbench/parts/files/browser/fileActions.contribution.ts index 6f04409b592..96e2e177e29 100644 --- a/src/vs/workbench/parts/files/browser/fileActions.contribution.ts +++ b/src/vs/workbench/parts/files/browser/fileActions.contribution.ts @@ -17,7 +17,7 @@ import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/wor import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; -import { FileStat } from 'vs/workbench/parts/files/common/explorerViewModel'; +import { FileStat } from 'vs/workbench/parts/files/common/explorerModel'; import { KeyMod, KeyChord, KeyCode } from 'vs/base/common/keyCodes'; import { OpenFolderAction, OpenFileFolderAction } from 'vs/workbench/browser/actions/fileActions'; import { copyFocusedFilesExplorerViewItem, revealInOSFocusedFilesExplorerItem, openFocusedExplorerItemSideBySideCommand, copyPathOfFocusedExplorerItem, copyPathCommand, revealInExplorerCommand, revealInOSCommand, openFolderPickerCommand, openWindowCommand, openFileInNewWindowCommand, deleteFocusedFilesExplorerViewItemCommand, moveFocusedFilesExplorerViewItemToTrashCommand, renameFocusedFilesExplorerViewItemCommand } from 'vs/workbench/parts/files/browser/fileCommands'; diff --git a/src/vs/workbench/parts/files/browser/fileActions.ts b/src/vs/workbench/parts/files/browser/fileActions.ts index 378a32e3889..8415914e7f0 100644 --- a/src/vs/workbench/parts/files/browser/fileActions.ts +++ b/src/vs/workbench/parts/files/browser/fileActions.ts @@ -27,7 +27,7 @@ import labels = require('vs/base/common/labels'); import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; import { IFileService, IFileStat, isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; import { toResource, IEditorIdentifier, EditorInput } from 'vs/workbench/common/editor'; -import { FileStat, NewStatPlaceholder } from 'vs/workbench/parts/files/common/explorerViewModel'; +import { FileStat, NewStatPlaceholder } from 'vs/workbench/parts/files/common/explorerModel'; import { ExplorerView } from 'vs/workbench/parts/files/browser/views/explorerView'; import { ExplorerViewlet } from 'vs/workbench/parts/files/browser/explorerViewlet'; import { IUntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; diff --git a/src/vs/workbench/parts/files/browser/fileCommands.ts b/src/vs/workbench/parts/files/browser/fileCommands.ts index 8d0711a0c3d..121cf168855 100644 --- a/src/vs/workbench/parts/files/browser/fileCommands.ts +++ b/src/vs/workbench/parts/files/browser/fileCommands.ts @@ -18,7 +18,7 @@ import { IViewletService } from 'vs/workbench/services/viewlet/browser/viewlet'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { ExplorerViewlet } from 'vs/workbench/parts/files/browser/explorerViewlet'; import { VIEWLET_ID, explorerItemToFileResource } from 'vs/workbench/parts/files/common/files'; -import { FileStat, OpenEditor } from 'vs/workbench/parts/files/common/explorerViewModel'; +import { FileStat, OpenEditor } from 'vs/workbench/parts/files/common/explorerModel'; import errors = require('vs/base/common/errors'); import { ITree } from 'vs/base/parts/tree/browser/tree'; import { IClipboardService } from 'vs/platform/clipboard/common/clipboardService'; diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index d1df344969a..a2c1f5fd485 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -26,7 +26,7 @@ import { IEditorGroupService } from 'vs/workbench/services/group/common/groupSer import * as DOM from 'vs/base/browser/dom'; import { CollapseAction } from 'vs/workbench/browser/viewlet'; import { CollapsibleView, IViewletViewOptions } from 'vs/workbench/parts/views/browser/views'; -import { FileStat } from 'vs/workbench/parts/files/common/explorerViewModel'; +import { FileStat } from 'vs/workbench/parts/files/common/explorerModel'; import { IListService } from 'vs/platform/list/browser/listService'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; import { IPartService } from 'vs/workbench/services/part/common/partService'; diff --git a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts index e7ed0556942..2464c18f1fc 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts @@ -31,7 +31,7 @@ import { DuplicateFileAction, ImportFileAction, IEditableData, IFileViewletState import { IDataSource, ITree, IAccessibilityProvider, IRenderer, ContextMenuEvent, ISorter, IFilter, IDragAndDrop, IDragAndDropData, IDragOverReaction, DRAG_OVER_ACCEPT_BUBBLE_DOWN, DRAG_OVER_ACCEPT_BUBBLE_DOWN_COPY, DRAG_OVER_ACCEPT_BUBBLE_UP, DRAG_OVER_ACCEPT_BUBBLE_UP_COPY, DRAG_OVER_REJECT } from 'vs/base/parts/tree/browser/tree'; import { DesktopDragAndDropData, ExternalElementsDragAndDropData } from 'vs/base/parts/tree/browser/treeDnd'; import { ClickBehavior, DefaultController } from 'vs/base/parts/tree/browser/treeDefaults'; -import { FileStat, NewStatPlaceholder } from 'vs/workbench/parts/files/common/explorerViewModel'; +import { FileStat, NewStatPlaceholder } from 'vs/workbench/parts/files/common/explorerModel'; import { DragMouseEvent, IMouseEvent } from 'vs/base/browser/mouseEvent'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; import { IPartService } from 'vs/workbench/services/part/common/partService'; diff --git a/src/vs/workbench/parts/files/browser/views/openEditorsView.ts b/src/vs/workbench/parts/files/browser/views/openEditorsView.ts index d15bc3aef00..f2fc598953a 100644 --- a/src/vs/workbench/parts/files/browser/views/openEditorsView.ts +++ b/src/vs/workbench/parts/files/browser/views/openEditorsView.ts @@ -22,7 +22,7 @@ import { CollapsibleView, IViewletViewOptions } from 'vs/workbench/parts/views/b import { IFilesConfiguration, VIEWLET_ID, OpenEditorsFocussedContext, ExplorerFocussedContext } from 'vs/workbench/parts/files/common/files'; import { ITextFileService, AutoSaveMode } from 'vs/workbench/services/textfile/common/textfiles'; import { IViewletService } from 'vs/workbench/services/viewlet/browser/viewlet'; -import { OpenEditor } from 'vs/workbench/parts/files/common/explorerViewModel'; +import { OpenEditor } from 'vs/workbench/parts/files/common/explorerModel'; import { Renderer, DataSource, Controller, AccessibilityProvider, ActionProvider, DragAndDrop } from 'vs/workbench/parts/files/browser/views/openEditorsViewer'; import { IUntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; import { CloseAllEditorsAction } from 'vs/workbench/browser/parts/editor/editorActions'; diff --git a/src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts b/src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts index f275bfd30a5..959e8c13aeb 100644 --- a/src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts +++ b/src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts @@ -22,7 +22,7 @@ import { IEditorGroupService } from 'vs/workbench/services/group/common/groupSer import { IContextMenuService } from 'vs/platform/contextview/browser/contextView'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { IEditorGroup, IEditorStacksModel } from 'vs/workbench/common/editor'; -import { OpenEditor } from 'vs/workbench/parts/files/common/explorerViewModel'; +import { OpenEditor } from 'vs/workbench/parts/files/common/explorerModel'; import { ContributableActionProvider } from 'vs/workbench/browser/actions'; import { explorerItemToFileResource } from 'vs/workbench/parts/files/common/files'; import { ITextFileService, AutoSaveMode } from 'vs/workbench/services/textfile/common/textfiles'; diff --git a/src/vs/workbench/parts/files/common/explorerViewModel.ts b/src/vs/workbench/parts/files/common/explorerModel.ts similarity index 100% rename from src/vs/workbench/parts/files/common/explorerViewModel.ts rename to src/vs/workbench/parts/files/common/explorerModel.ts diff --git a/src/vs/workbench/parts/files/common/files.ts b/src/vs/workbench/parts/files/common/files.ts index dc8cd834b61..f391f8497fa 100644 --- a/src/vs/workbench/parts/files/common/files.ts +++ b/src/vs/workbench/parts/files/common/files.ts @@ -8,7 +8,7 @@ import URI from 'vs/base/common/uri'; import { IEditorOptions } from 'vs/editor/common/config/editorOptions'; import { IWorkbenchEditorConfiguration } from 'vs/workbench/common/editor'; import { IFilesConfiguration } from 'vs/platform/files/common/files'; -import { FileStat, OpenEditor } from 'vs/workbench/parts/files/common/explorerViewModel'; +import { FileStat, OpenEditor } from 'vs/workbench/parts/files/common/explorerModel'; import { ContextKeyExpr, RawContextKey } from 'vs/platform/contextkey/common/contextkey'; /** diff --git a/src/vs/workbench/parts/files/test/browser/explorerViewModel.test.ts b/src/vs/workbench/parts/files/test/browser/explorerViewModel.test.ts index 92b2fdd10a3..4343b05fac3 100644 --- a/src/vs/workbench/parts/files/test/browser/explorerViewModel.test.ts +++ b/src/vs/workbench/parts/files/test/browser/explorerViewModel.test.ts @@ -11,7 +11,7 @@ import { isLinux, isWindows } from 'vs/base/common/platform'; import URI from 'vs/base/common/uri'; import { join } from 'vs/base/common/paths'; import { validateFileName } from 'vs/workbench/parts/files/browser/fileActions'; -import { FileStat } from 'vs/workbench/parts/files/common/explorerViewModel'; +import { FileStat } from 'vs/workbench/parts/files/common/explorerModel'; function createStat(path, name, isFolder, hasChildren, size, mtime) { return new FileStat(toResource(path), isFolder, hasChildren, name, mtime); -- GitLab From 5e70c18433df0bcdd8e3e99728a91c0952ee7ecf Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Tue, 13 Jun 2017 11:05:04 -0700 Subject: [PATCH 0780/1347] Uplevel xterm.js Fixes #23142 Fixes #28609 --- npm-shrinkwrap.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/npm-shrinkwrap.json b/npm-shrinkwrap.json index 7b76d1c9edb..a1d1223cab2 100644 --- a/npm-shrinkwrap.json +++ b/npm-shrinkwrap.json @@ -442,7 +442,7 @@ "xterm": { "version": "2.7.0", "from": "Tyriar/xterm.js#vscode-release/1.14", - "resolved": "git+https://github.com/Tyriar/xterm.js.git#1d7007669dec1f60e5878aa102a36473d8cbd97f" + "resolved": "git+https://github.com/Tyriar/xterm.js.git#7d3640ad17fbf69f1a1c776b6d08969e1da32875" }, "yauzl": { "version": "2.3.1", -- GitLab From bede3ce9cea769179cfc8144cf004566c851fb95 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Tue, 13 Jun 2017 11:08:55 -0700 Subject: [PATCH 0781/1347] Fix rename terminal action --- .../parts/terminal/electron-browser/terminalInstance.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index 44a6c047dff..fea2eb3d2b0 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -794,6 +794,7 @@ export class TerminalInstance implements ITerminalInstance { public setTitle(title: string): void { const didTitleChange = title !== this._title; + this._title = title; if (didTitleChange) { this._onTitleChanged.fire(title); } -- GitLab From 314ebc778cda5483cbdd29a831b50663267f6f2b Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Tue, 13 Jun 2017 11:20:38 -0700 Subject: [PATCH 0782/1347] Adding some validation --- src/vs/code/electron-main/app.ts | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/src/vs/code/electron-main/app.ts b/src/vs/code/electron-main/app.ts index 9d09792a65b..8effa87307f 100644 --- a/src/vs/code/electron-main/app.ts +++ b/src/vs/code/electron-main/app.ts @@ -48,6 +48,7 @@ import { isUndefinedOrNull } from "vs/base/common/types"; import { CodeWindow } from "vs/code/electron-main/window"; import { isEqual, isParent } from "vs/platform/files/common/files"; import { KeyboardLayoutMonitor } from "vs/code/electron-main/keyboard"; +import URI from 'vs/base/common/uri'; export class CodeApplication { private toDispose: IDisposable[]; @@ -119,6 +120,23 @@ export class CodeApplication { } }); + const isValidWebviewSource = (source: string) => + !source || (source.toLowerCase() as any).startsWith(URI.file(this.environmentService.appRoot.toLowerCase()).toString()); + + app.on('web-contents-created', (event, contents) => { + contents.on('will-attach-webview', (event, webPreferences, params) => { + delete webPreferences.preload; + webPreferences.nodeIntegration = false; + + // Verify URLs being loaded + if (isValidWebviewSource(params.src) && isValidWebviewSource(webPreferences.preloadURL)) { + return; + } + // Otherwise prevent loading + event.preventDefault(); + }); + }); + let macOpenFiles: string[] = []; let runningTimeout: number = null; app.on('open-file', (event: Event, path: string) => { -- GitLab From c6b610cd00b26a785d811eaf594058ae72f86849 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Tue, 13 Jun 2017 11:22:38 -0700 Subject: [PATCH 0783/1347] Only label upcoming recovery build --- .github/new_release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/new_release.yml b/.github/new_release.yml index ae864327333..dd081006329 100644 --- a/.github/new_release.yml +++ b/.github/new_release.yml @@ -1,5 +1,5 @@ { newReleaseLabel: 'new release', - newReleases: ['1.13'], + newReleases: ['1.13.1'], perform: true } \ No newline at end of file -- GitLab From 4c2b9a6917af708af7661d28ce33547f6f7038e3 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Tue, 13 Jun 2017 11:30:22 -0700 Subject: [PATCH 0784/1347] Fix solarized terminal colors Fixes #28288 --- .../themes/solarized-dark-color-theme.json | 32 +++++++++---------- .../themes/solarized-light-color-theme.json | 32 +++++++++---------- 2 files changed, 32 insertions(+), 32 deletions(-) diff --git a/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json b/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json index 04967aae331..f21572d1c11 100644 --- a/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json +++ b/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json @@ -459,21 +459,21 @@ // Workbench: Terminal // Colors sourced from the official palette http://ethanschoonover.com/solarized - "terminal.ansiBlack": "#262626", - "terminal.ansiBlue": "#0087ff", - "terminal.ansiBrightBlack": "#1c1c1c", - "terminal.ansiBrightBlue": "#808080", - "terminal.ansiBrightCyan": "#808080", - "terminal.ansiBrightGreen": "#585858", - "terminal.ansiBrightMagenta": "#5f5faf", - "terminal.ansiBrightRed": "#d75f00", - "terminal.ansiBrightWhite": "#808080", - "terminal.ansiBrightYellow": "#626262", - "terminal.ansiCyan": "#00afaf", - "terminal.ansiGreen": "#5f8700", - "terminal.ansiMagenta": "#af005f", - "terminal.ansiRed": "#d70000", - "terminal.ansiWhite": "#808080", - "terminal.ansiYellow": "#af8700" + "terminal.ansiBlack": "#073642", + "terminal.ansiRed": "#dc322f", + "terminal.ansiGreen": "#859900", + "terminal.ansiYellow": "#b58900", + "terminal.ansiBlue": "#268bd2", + "terminal.ansiMagenta": "#d33682", + "terminal.ansiCyan": "#2aa198", + "terminal.ansiWhite": "#eee8d5", + "terminal.ansiBrightBlack": "#002b36", + "terminal.ansiBrightRed": "#cb4b16", + "terminal.ansiBrightGreen": "#586e75", + "terminal.ansiBrightYellow": "#657b83", + "terminal.ansiBrightBlue": "#839496", + "terminal.ansiBrightMagenta": "#6c71c4", + "terminal.ansiBrightCyan": "#93a1a1", + "terminal.ansiBrightWhite": "#fdf6e3" } } \ No newline at end of file diff --git a/extensions/theme-solarized-light/themes/solarized-light-color-theme.json b/extensions/theme-solarized-light/themes/solarized-light-color-theme.json index ba74b7d0385..18414462120 100644 --- a/extensions/theme-solarized-light/themes/solarized-light-color-theme.json +++ b/extensions/theme-solarized-light/themes/solarized-light-color-theme.json @@ -462,21 +462,21 @@ // Workbench: Terminal // Colors sourced from the official palette http://ethanschoonover.com/solarized - "terminal.ansiBlack": "#262626", - "terminal.ansiBlue": "#0087ff", - "terminal.ansiBrightBlack": "#1c1c1c", - "terminal.ansiBrightBlue": "#808080", - "terminal.ansiBrightCyan": "#808080", - "terminal.ansiBrightGreen": "#585858", - "terminal.ansiBrightMagenta": "#5f5faf", - "terminal.ansiBrightRed": "#d75f00", - "terminal.ansiBrightWhite": "#808080", - "terminal.ansiBrightYellow": "#626262", - "terminal.ansiCyan": "#00afaf", - "terminal.ansiGreen": "#5f8700", - "terminal.ansiMagenta": "#af005f", - "terminal.ansiRed": "#d70000", - "terminal.ansiWhite": "#808080", - "terminal.ansiYellow": "#af8700" + "terminal.ansiBlack": "#073642", + "terminal.ansiRed": "#dc322f", + "terminal.ansiGreen": "#859900", + "terminal.ansiYellow": "#b58900", + "terminal.ansiBlue": "#268bd2", + "terminal.ansiMagenta": "#d33682", + "terminal.ansiCyan": "#2aa198", + "terminal.ansiWhite": "#eee8d5", + "terminal.ansiBrightBlack": "#002b36", + "terminal.ansiBrightRed": "#cb4b16", + "terminal.ansiBrightGreen": "#586e75", + "terminal.ansiBrightYellow": "#657b83", + "terminal.ansiBrightBlue": "#839496", + "terminal.ansiBrightMagenta": "#6c71c4", + "terminal.ansiBrightCyan": "#93a1a1", + "terminal.ansiBrightWhite": "#fdf6e3" } } \ No newline at end of file -- GitLab From 9f99d4ea35a9ff34a5a3667c01ecd8a1c4e6dd36 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Tue, 13 Jun 2017 14:19:22 -0700 Subject: [PATCH 0785/1347] Update OSSREADME to have only modules that dont have a explicit license file --- extensions/emmet/OSSREADME.json | 119 ++------------------------------ 1 file changed, 5 insertions(+), 114 deletions(-) diff --git a/extensions/emmet/OSSREADME.json b/extensions/emmet/OSSREADME.json index 926f46f6fbd..09831f14f17 100644 --- a/extensions/emmet/OSSREADME.json +++ b/extensions/emmet/OSSREADME.json @@ -1,118 +1,9 @@ [ { - "name": "@emmetio/expand-abbreviation", - "license": "MIT", - "version": "0.5.7", - "repositoryURL": "https://github.com/emmetio/expand-abbreviation", - "licenseDetail": [ - "MIT License", - "", - "Copyright (c) 2017 Emmet.io", - "", - "Permission is hereby granted, free of charge, to any person obtaining a copy", - "of this software and associated documentation files (the \"Software\"), to deal", - "in the Software without restriction, including without limitation the rights", - "to use, copy, modify, merge, publish, distribute, sublicense, and/or sell", - "copies of the Software, and to permit persons to whom the Software is", - "furnished to do so, subject to the following conditions:", - "", - "The above copyright notice and this permission notice shall be included in all", - "copies or substantial portions of the Software.", - "", - "THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR", - "IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,", - "FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE", - "AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER", - "LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,", - "OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE", - "SOFTWARE." - ] - }, - { - "name": "@emmetio/css-parser", - "license": "MIT", - "version": "0.3.0", - "repositoryURL": "https://github.com/emmetio/css-parser", - "licenseDetail": [ - "MIT License", - "", - "Copyright (c) 2017 Emmet.io", - "", - "Permission is hereby granted, free of charge, to any person obtaining a copy", - "of this software and associated documentation files (the \"Software\"), to deal", - "in the Software without restriction, including without limitation the rights", - "to use, copy, modify, merge, publish, distribute, sublicense, and/or sell", - "copies of the Software, and to permit persons to whom the Software is", - "furnished to do so, subject to the following conditions:", - "", - "The above copyright notice and this permission notice shall be included in all", - "copies or substantial portions of the Software.", - "", - "THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR", - "IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,", - "FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE", - "AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER", - "LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,", - "OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE", - "SOFTWARE." - ] - }, - { - "name": "@emmetio/extract-abbreviation", - "license": "MIT", - "version": "0.1.2", - "repositoryURL": "https://github.com/emmetio/extract-abbreviation", - "licenseDetail": [ - "MIT License", - "", - "Copyright (c) 2017 Emmet.io", - "", - "Permission is hereby granted, free of charge, to any person obtaining a copy", - "of this software and associated documentation files (the \"Software\"), to deal", - "in the Software without restriction, including without limitation the rights", - "to use, copy, modify, merge, publish, distribute, sublicense, and/or sell", - "copies of the Software, and to permit persons to whom the Software is", - "furnished to do so, subject to the following conditions:", - "", - "The above copyright notice and this permission notice shall be included in all", - "copies or substantial portions of the Software.", - "", - "THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR", - "IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,", - "FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE", - "AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER", - "LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,", - "OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE", - "SOFTWARE." - ] - }, - { - "name": "@emmetio/html-matcher", - "license": "MIT", - "version": "0.3.2", - "repositoryURL": "https://github.com/emmetio/html-matcher", - "licenseDetail": [ - "MIT License", - "", - "Copyright (c) 2017 Emmet.io", - "", - "Permission is hereby granted, free of charge, to any person obtaining a copy", - "of this software and associated documentation files (the \"Software\"), to deal", - "in the Software without restriction, including without limitation the rights", - "to use, copy, modify, merge, publish, distribute, sublicense, and/or sell", - "copies of the Software, and to permit persons to whom the Software is", - "furnished to do so, subject to the following conditions:", - "", - "The above copyright notice and this permission notice shall be included in all", - "copies or substantial portions of the Software.", - "", - "THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR", - "IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,", - "FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE", - "AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER", - "LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,", - "OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE", - "SOFTWARE." - ] + "name": "browser-stdout", + "version": "1.3.0", + "isLicense": true, + "repositoryURL": "https://github.com/kumavis/browser-stdout", + "license": "ISC" } ] \ No newline at end of file -- GitLab From 732824c35467b7d625421d3dc048bb1bbe99377e Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Tue, 13 Jun 2017 15:45:20 -0700 Subject: [PATCH 0786/1347] Fixing TSServer Restart Happening Twice Fixes #27817 **Bug** When triggering a manual TSServer restart, we currently start a new instance than immediatly kill it and start another new instance of the service. This is caused by the current handler for proces crashes not knowing that it should not restart the service for manual restarts. **Fix** Make sure kill doesn't automatically try to start up another instance of the TS Server when we manually restart the server --- extensions/typescript/src/typescriptServiceClient.ts | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/extensions/typescript/src/typescriptServiceClient.ts b/extensions/typescript/src/typescriptServiceClient.ts index 212d7cb3b13..e2bcf481277 100644 --- a/extensions/typescript/src/typescriptServiceClient.ts +++ b/extensions/typescript/src/typescriptServiceClient.ts @@ -240,6 +240,8 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient private firstStart: number; private lastStart: number; private numberRestarts: number; + private isRestarting: boolean = false; + private cancellationPipeName: string | null = null; private requestQueue: RequestQueue; @@ -305,13 +307,14 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient public restartTsServer(): void { const start = () => { - this.servicePromise = this.startService(); + this.servicePromise = this.startService(true); return this.servicePromise; }; if (this.servicePromise) { this.servicePromise = this.servicePromise.then(cp => { if (cp) { + this.isRestarting = true; cp.kill(); } }).then(start); @@ -352,7 +355,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient return this._onReady.promise; } - public info(message: string, data?: any): void { + private info(message: string, data?: any): void { this.logger.info(message, data); } @@ -360,7 +363,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient this.logger.warn(message, data); } - public error(message: string, data?: any): void { + private error(message: string, data?: any): void { this.logger.error(message, data); } @@ -567,7 +570,8 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient if (this.tsServerLogFile) { this.info(`TSServer log file: ${this.tsServerLogFile}`); } - this.serviceExited(true); + this.serviceExited(!this.isRestarting); + this.isRestarting = false; }); this.reader = new Reader( -- GitLab From fda3ed38449fea27b97698ad0950c2870bf6afaa Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Tue, 13 Jun 2017 20:27:32 -0700 Subject: [PATCH 0787/1347] Fix terminalFocus context key after select all from cmd palette Fixes #28679 --- .../parts/terminal/electron-browser/terminalInstance.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index fea2eb3d2b0..b03ee074b1e 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -342,6 +342,8 @@ export class TerminalInstance implements ITerminalInstance { } public selectAll(): void { + // Focus here to ensure the terminal context key is set + this._xterm.focus(); this._xterm.selectAll(); } -- GitLab From ce7982b6814d468bf785cbbedc2e6b19d1f08474 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 14 Jun 2017 07:48:47 +0200 Subject: [PATCH 0788/1347] introduce and use extfs.realpath --- src/vs/base/node/extfs.ts | 50 +++++++++++++++++-- src/vs/base/node/pfs.ts | 2 +- src/vs/base/test/node/extfs/extfs.test.ts | 40 +++++++++++++-- src/vs/code/node/paths.ts | 4 +- .../watcher/unix/chokidarWatcherService.ts | 4 +- 5 files changed, 87 insertions(+), 13 deletions(-) diff --git a/src/vs/base/node/extfs.ts b/src/vs/base/node/extfs.ts index ef8680f062a..ecffac0980d 100644 --- a/src/vs/base/node/extfs.ts +++ b/src/vs/base/node/extfs.ts @@ -374,13 +374,13 @@ export function writeFileAndFlush(path: string, data: string | NodeBuffer, optio /** * Copied from: https://github.com/Microsoft/vscode-node-debug/blob/master/src/node/pathUtilities.ts#L83 * - * Given an absolute, normalized, and existing file path 'realpath' returns the exact path that the file has on disk. + * Given an absolute, normalized, and existing file path 'realcase' returns the exact path that the file has on disk. * On a case insensitive file system, the returned path might differ from the original path by character casing. * On a case sensitive file system, the returned path will always be identical to the original path. * In case of errors, null is returned. But you cannot use this function to verify that a path exists. - * realpathSync does not handle '..' or '.' path segments and it does not take the locale into account. + * realcaseSync does not handle '..' or '.' path segments and it does not take the locale into account. */ -export function realpathSync(path: string): string { +export function realcaseSync(path: string): string { const dir = paths.dirname(path); if (path === dir) { // end recursion return path; @@ -392,7 +392,7 @@ export function realpathSync(path: string): string { const found = entries.filter(e => e.toLowerCase() === name); // use a case insensitive search if (found.length === 1) { // on a case sensitive filesystem we cannot determine here, whether the file exists or not, hence we need the 'file exists' precondition - const prefix = realpathSync(dir); // recurse + const prefix = realcaseSync(dir); // recurse if (prefix) { return paths.join(prefix, found[0]); } @@ -400,7 +400,7 @@ export function realpathSync(path: string): string { // must be a case sensitive $filesystem const ix = found.indexOf(name); if (ix >= 0) { // case sensitive - const prefix = realpathSync(dir); // recurse + const prefix = realcaseSync(dir); // recurse if (prefix) { return paths.join(prefix, found[ix]); } @@ -411,4 +411,44 @@ export function realpathSync(path: string): string { } return null; +} + +export function realpathSync(path: string): string { + try { + return fs.realpathSync(path); + } catch (error) { + + // We hit an error calling fs.realpathSync(). Since fs.realpathSync() is doing some path normalization + // we now do a similar normalization and then try again if we can access the path with read + // permissions at least. If that succeeds, we return that path. + // fs.realpath() is resolving symlinks and that can fail in certain cases. The workaround is + // to not resolve links but to simply see if the path is read accessible or not. + const normalizedPath = normalizePath(path); + fs.accessSync(normalizedPath, fs.constants.R_OK); // throws in case of an error + + return normalizedPath; + } +} + +export function realpath(path: string, callback: (error: Error, realpath: string) => void): void { + return fs.realpath(path, (error, realpath) => { + if (!error) { + return callback(null, realpath); + } + + // We hit an error calling fs.realpath(). Since fs.realpath() is doing some path normalization + // we now do a similar normalization and then try again if we can access the path with read + // permissions at least. If that succeeds, we return that path. + // fs.realpath() is resolving symlinks and that can fail in certain cases. The workaround is + // to not resolve links but to simply see if the path is read accessible or not. + const normalizedPath = normalizePath(path); + + return fs.access(normalizedPath, fs.constants.R_OK, error => { + return callback(error, normalizedPath); + }); + }); +} + +function normalizePath(path: string): string { + return strings.rtrim(paths.normalize(path), paths.sep); } \ No newline at end of file diff --git a/src/vs/base/node/pfs.ts b/src/vs/base/node/pfs.ts index 9ff23afdfa1..3d8e1808439 100644 --- a/src/vs/base/node/pfs.ts +++ b/src/vs/base/node/pfs.ts @@ -72,7 +72,7 @@ export function rimraf(path: string): TPromise { } export function realpath(path: string): TPromise { - return nfcall(fs.realpath, path, null); + return nfcall(extfs.realpath, path); } export function stat(path: string): TPromise { diff --git a/src/vs/base/test/node/extfs/extfs.test.ts b/src/vs/base/test/node/extfs/extfs.test.ts index 1eda91cea9d..ca184afd097 100644 --- a/src/vs/base/test/node/extfs/extfs.test.ts +++ b/src/vs/base/test/node/extfs/extfs.test.ts @@ -203,7 +203,7 @@ suite('Extfs', () => { }); }); - test('realpath', (done) => { + test('realcase', (done) => { const id = uuid.generateUuid(); const parentDir = path.join(os.tmpdir(), 'vsctests', id); const newDir = path.join(parentDir, 'extfs', id); @@ -213,7 +213,7 @@ suite('Extfs', () => { // assume case insensitive file system if (process.platform === 'win32' || process.platform === 'darwin') { const upper = newDir.toUpperCase(); - const real = extfs.realpathSync(upper); + const real = extfs.realcaseSync(upper); if (real) { // can be null in case of permission errors assert.notEqual(real, upper); @@ -224,11 +224,45 @@ suite('Extfs', () => { // linux, unix, etc. -> assume case sensitive file system else { - const real = extfs.realpathSync(newDir); + const real = extfs.realcaseSync(newDir); assert.equal(real, newDir); } extfs.del(parentDir, os.tmpdir(), () => { }, done); }); }); + + test('realpath', (done) => { + const id = uuid.generateUuid(); + const parentDir = path.join(os.tmpdir(), 'vsctests', id); + const newDir = path.join(parentDir, 'extfs', id); + + extfs.mkdirp(newDir, 493, (error) => { + + extfs.realpath(newDir, (error, realpath) => { + assert.ok(realpath); + assert.ok(!error); + + extfs.del(parentDir, os.tmpdir(), () => { }, done); + }); + }); + }); + + test('realpathSync', (done) => { + const id = uuid.generateUuid(); + const parentDir = path.join(os.tmpdir(), 'vsctests', id); + const newDir = path.join(parentDir, 'extfs', id); + + extfs.mkdirp(newDir, 493, (error) => { + let realpath: string; + try { + realpath = extfs.realpathSync(newDir); + } catch (error) { + assert.ok(!error); + } + assert.ok(realpath); + + extfs.del(parentDir, os.tmpdir(), () => { }, done); + }); + }); }); \ No newline at end of file diff --git a/src/vs/code/node/paths.ts b/src/vs/code/node/paths.ts index 8ad9d195910..1436632f935 100644 --- a/src/vs/code/node/paths.ts +++ b/src/vs/code/node/paths.ts @@ -5,7 +5,6 @@ 'use strict'; -import * as fs from 'original-fs'; import * as path from 'path'; import * as arrays from 'vs/base/common/arrays'; import * as strings from 'vs/base/common/strings'; @@ -13,6 +12,7 @@ import * as paths from 'vs/base/common/paths'; import * as platform from 'vs/base/common/platform'; import * as types from 'vs/base/common/types'; import { ParsedArgs } from 'vs/platform/environment/common/environment'; +import { realpathSync } from "vs/base/node/extfs"; export function validatePaths(args: ParsedArgs): ParsedArgs { @@ -43,7 +43,7 @@ function doValidatePaths(args: string[], gotoLineMode?: boolean): string[] { let realPath: string; try { - realPath = fs.realpathSync(pathCandidate); + realPath = realpathSync(pathCandidate); } catch (error) { // in case of an error, assume the user wants to create this file // if the path is relative, we join it to the cwd diff --git a/src/vs/workbench/services/files/node/watcher/unix/chokidarWatcherService.ts b/src/vs/workbench/services/files/node/watcher/unix/chokidarWatcherService.ts index 63a17ea995d..3dc0a747c60 100644 --- a/src/vs/workbench/services/files/node/watcher/unix/chokidarWatcherService.ts +++ b/src/vs/workbench/services/files/node/watcher/unix/chokidarWatcherService.ts @@ -15,7 +15,7 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { FileChangeType } from 'vs/platform/files/common/files'; import { ThrottledDelayer } from 'vs/base/common/async'; import strings = require('vs/base/common/strings'); -import { realpathSync } from 'vs/base/node/extfs'; +import { realcaseSync } from 'vs/base/node/extfs'; import { isMacintosh } from 'vs/base/common/platform'; import watcher = require('vs/workbench/services/files/node/watcher/common'); import { IWatcherRequest, IWatcherService } from './watcher'; @@ -43,7 +43,7 @@ export class ChokidarWatcherService implements IWatcherService { // so we have to find the real casing of the path and do some path massaging to fix this // see https://github.com/paulmillr/chokidar/issues/418 const originalBasePath = request.basePath; - const realBasePath = isMacintosh ? (realpathSync(originalBasePath) || originalBasePath) : originalBasePath; + const realBasePath = isMacintosh ? (realcaseSync(originalBasePath) || originalBasePath) : originalBasePath; const realBasePathLength = realBasePath.length; const realBasePathDiffers = (originalBasePath !== realBasePath); -- GitLab From f601ee83a669d05426fb1aae781275a76caba95f Mon Sep 17 00:00:00 2001 From: isidor Date: Wed, 14 Jun 2017 09:39:57 +0200 Subject: [PATCH 0789/1347] debug: source should be regarded as not available if presentationHint === `deemphasize` --- src/vs/workbench/parts/debug/common/debugSource.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/debug/common/debugSource.ts b/src/vs/workbench/parts/debug/common/debugSource.ts index 042c9e8d1b7..18d8149f874 100644 --- a/src/vs/workbench/parts/debug/common/debugSource.ts +++ b/src/vs/workbench/parts/debug/common/debugSource.ts @@ -34,7 +34,7 @@ export class Source { } public get available() { - return this.raw.name !== UNKNOWN_SOURCE_LABEL; + return this.raw.name !== UNKNOWN_SOURCE_LABEL && this.presentationHint !== 'deemphasize'; } public get inMemory() { -- GitLab From 6af7ef854e38c2b4a5ace7df267094afeef75778 Mon Sep 17 00:00:00 2001 From: isidor Date: Wed, 14 Jun 2017 09:43:24 +0200 Subject: [PATCH 0790/1347] merge master --- .github/new_release.yml | 2 +- extensions/emmet/OSSREADME.json | 119 +----------------- .../themes/solarized-dark-color-theme.json | 32 ++--- .../themes/solarized-light-color-theme.json | 32 ++--- .../typescript/src/typescriptServiceClient.ts | 12 +- npm-shrinkwrap.json | 2 +- src/vs/base/node/extfs.ts | 50 +++++++- src/vs/base/node/pfs.ts | 2 +- src/vs/base/test/node/extfs/extfs.test.ts | 40 +++++- src/vs/code/electron-main/app.ts | 18 +++ src/vs/code/node/paths.ts | 4 +- src/vs/workbench/electron-browser/actions.ts | 23 +++- .../parts/debug/common/debugSource.ts | 2 +- .../electron-browser/terminalInstance.ts | 3 + .../watcher/unix/chokidarWatcherService.ts | 4 +- 15 files changed, 174 insertions(+), 171 deletions(-) diff --git a/.github/new_release.yml b/.github/new_release.yml index ae864327333..dd081006329 100644 --- a/.github/new_release.yml +++ b/.github/new_release.yml @@ -1,5 +1,5 @@ { newReleaseLabel: 'new release', - newReleases: ['1.13'], + newReleases: ['1.13.1'], perform: true } \ No newline at end of file diff --git a/extensions/emmet/OSSREADME.json b/extensions/emmet/OSSREADME.json index 926f46f6fbd..09831f14f17 100644 --- a/extensions/emmet/OSSREADME.json +++ b/extensions/emmet/OSSREADME.json @@ -1,118 +1,9 @@ [ { - "name": "@emmetio/expand-abbreviation", - "license": "MIT", - "version": "0.5.7", - "repositoryURL": "https://github.com/emmetio/expand-abbreviation", - "licenseDetail": [ - "MIT License", - "", - "Copyright (c) 2017 Emmet.io", - "", - "Permission is hereby granted, free of charge, to any person obtaining a copy", - "of this software and associated documentation files (the \"Software\"), to deal", - "in the Software without restriction, including without limitation the rights", - "to use, copy, modify, merge, publish, distribute, sublicense, and/or sell", - "copies of the Software, and to permit persons to whom the Software is", - "furnished to do so, subject to the following conditions:", - "", - "The above copyright notice and this permission notice shall be included in all", - "copies or substantial portions of the Software.", - "", - "THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR", - "IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,", - "FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE", - "AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER", - "LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,", - "OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE", - "SOFTWARE." - ] - }, - { - "name": "@emmetio/css-parser", - "license": "MIT", - "version": "0.3.0", - "repositoryURL": "https://github.com/emmetio/css-parser", - "licenseDetail": [ - "MIT License", - "", - "Copyright (c) 2017 Emmet.io", - "", - "Permission is hereby granted, free of charge, to any person obtaining a copy", - "of this software and associated documentation files (the \"Software\"), to deal", - "in the Software without restriction, including without limitation the rights", - "to use, copy, modify, merge, publish, distribute, sublicense, and/or sell", - "copies of the Software, and to permit persons to whom the Software is", - "furnished to do so, subject to the following conditions:", - "", - "The above copyright notice and this permission notice shall be included in all", - "copies or substantial portions of the Software.", - "", - "THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR", - "IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,", - "FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE", - "AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER", - "LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,", - "OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE", - "SOFTWARE." - ] - }, - { - "name": "@emmetio/extract-abbreviation", - "license": "MIT", - "version": "0.1.2", - "repositoryURL": "https://github.com/emmetio/extract-abbreviation", - "licenseDetail": [ - "MIT License", - "", - "Copyright (c) 2017 Emmet.io", - "", - "Permission is hereby granted, free of charge, to any person obtaining a copy", - "of this software and associated documentation files (the \"Software\"), to deal", - "in the Software without restriction, including without limitation the rights", - "to use, copy, modify, merge, publish, distribute, sublicense, and/or sell", - "copies of the Software, and to permit persons to whom the Software is", - "furnished to do so, subject to the following conditions:", - "", - "The above copyright notice and this permission notice shall be included in all", - "copies or substantial portions of the Software.", - "", - "THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR", - "IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,", - "FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE", - "AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER", - "LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,", - "OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE", - "SOFTWARE." - ] - }, - { - "name": "@emmetio/html-matcher", - "license": "MIT", - "version": "0.3.2", - "repositoryURL": "https://github.com/emmetio/html-matcher", - "licenseDetail": [ - "MIT License", - "", - "Copyright (c) 2017 Emmet.io", - "", - "Permission is hereby granted, free of charge, to any person obtaining a copy", - "of this software and associated documentation files (the \"Software\"), to deal", - "in the Software without restriction, including without limitation the rights", - "to use, copy, modify, merge, publish, distribute, sublicense, and/or sell", - "copies of the Software, and to permit persons to whom the Software is", - "furnished to do so, subject to the following conditions:", - "", - "The above copyright notice and this permission notice shall be included in all", - "copies or substantial portions of the Software.", - "", - "THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR", - "IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,", - "FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE", - "AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER", - "LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,", - "OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE", - "SOFTWARE." - ] + "name": "browser-stdout", + "version": "1.3.0", + "isLicense": true, + "repositoryURL": "https://github.com/kumavis/browser-stdout", + "license": "ISC" } ] \ No newline at end of file diff --git a/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json b/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json index 04967aae331..f21572d1c11 100644 --- a/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json +++ b/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json @@ -459,21 +459,21 @@ // Workbench: Terminal // Colors sourced from the official palette http://ethanschoonover.com/solarized - "terminal.ansiBlack": "#262626", - "terminal.ansiBlue": "#0087ff", - "terminal.ansiBrightBlack": "#1c1c1c", - "terminal.ansiBrightBlue": "#808080", - "terminal.ansiBrightCyan": "#808080", - "terminal.ansiBrightGreen": "#585858", - "terminal.ansiBrightMagenta": "#5f5faf", - "terminal.ansiBrightRed": "#d75f00", - "terminal.ansiBrightWhite": "#808080", - "terminal.ansiBrightYellow": "#626262", - "terminal.ansiCyan": "#00afaf", - "terminal.ansiGreen": "#5f8700", - "terminal.ansiMagenta": "#af005f", - "terminal.ansiRed": "#d70000", - "terminal.ansiWhite": "#808080", - "terminal.ansiYellow": "#af8700" + "terminal.ansiBlack": "#073642", + "terminal.ansiRed": "#dc322f", + "terminal.ansiGreen": "#859900", + "terminal.ansiYellow": "#b58900", + "terminal.ansiBlue": "#268bd2", + "terminal.ansiMagenta": "#d33682", + "terminal.ansiCyan": "#2aa198", + "terminal.ansiWhite": "#eee8d5", + "terminal.ansiBrightBlack": "#002b36", + "terminal.ansiBrightRed": "#cb4b16", + "terminal.ansiBrightGreen": "#586e75", + "terminal.ansiBrightYellow": "#657b83", + "terminal.ansiBrightBlue": "#839496", + "terminal.ansiBrightMagenta": "#6c71c4", + "terminal.ansiBrightCyan": "#93a1a1", + "terminal.ansiBrightWhite": "#fdf6e3" } } \ No newline at end of file diff --git a/extensions/theme-solarized-light/themes/solarized-light-color-theme.json b/extensions/theme-solarized-light/themes/solarized-light-color-theme.json index ba74b7d0385..18414462120 100644 --- a/extensions/theme-solarized-light/themes/solarized-light-color-theme.json +++ b/extensions/theme-solarized-light/themes/solarized-light-color-theme.json @@ -462,21 +462,21 @@ // Workbench: Terminal // Colors sourced from the official palette http://ethanschoonover.com/solarized - "terminal.ansiBlack": "#262626", - "terminal.ansiBlue": "#0087ff", - "terminal.ansiBrightBlack": "#1c1c1c", - "terminal.ansiBrightBlue": "#808080", - "terminal.ansiBrightCyan": "#808080", - "terminal.ansiBrightGreen": "#585858", - "terminal.ansiBrightMagenta": "#5f5faf", - "terminal.ansiBrightRed": "#d75f00", - "terminal.ansiBrightWhite": "#808080", - "terminal.ansiBrightYellow": "#626262", - "terminal.ansiCyan": "#00afaf", - "terminal.ansiGreen": "#5f8700", - "terminal.ansiMagenta": "#af005f", - "terminal.ansiRed": "#d70000", - "terminal.ansiWhite": "#808080", - "terminal.ansiYellow": "#af8700" + "terminal.ansiBlack": "#073642", + "terminal.ansiRed": "#dc322f", + "terminal.ansiGreen": "#859900", + "terminal.ansiYellow": "#b58900", + "terminal.ansiBlue": "#268bd2", + "terminal.ansiMagenta": "#d33682", + "terminal.ansiCyan": "#2aa198", + "terminal.ansiWhite": "#eee8d5", + "terminal.ansiBrightBlack": "#002b36", + "terminal.ansiBrightRed": "#cb4b16", + "terminal.ansiBrightGreen": "#586e75", + "terminal.ansiBrightYellow": "#657b83", + "terminal.ansiBrightBlue": "#839496", + "terminal.ansiBrightMagenta": "#6c71c4", + "terminal.ansiBrightCyan": "#93a1a1", + "terminal.ansiBrightWhite": "#fdf6e3" } } \ No newline at end of file diff --git a/extensions/typescript/src/typescriptServiceClient.ts b/extensions/typescript/src/typescriptServiceClient.ts index 212d7cb3b13..e2bcf481277 100644 --- a/extensions/typescript/src/typescriptServiceClient.ts +++ b/extensions/typescript/src/typescriptServiceClient.ts @@ -240,6 +240,8 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient private firstStart: number; private lastStart: number; private numberRestarts: number; + private isRestarting: boolean = false; + private cancellationPipeName: string | null = null; private requestQueue: RequestQueue; @@ -305,13 +307,14 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient public restartTsServer(): void { const start = () => { - this.servicePromise = this.startService(); + this.servicePromise = this.startService(true); return this.servicePromise; }; if (this.servicePromise) { this.servicePromise = this.servicePromise.then(cp => { if (cp) { + this.isRestarting = true; cp.kill(); } }).then(start); @@ -352,7 +355,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient return this._onReady.promise; } - public info(message: string, data?: any): void { + private info(message: string, data?: any): void { this.logger.info(message, data); } @@ -360,7 +363,7 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient this.logger.warn(message, data); } - public error(message: string, data?: any): void { + private error(message: string, data?: any): void { this.logger.error(message, data); } @@ -567,7 +570,8 @@ export default class TypeScriptServiceClient implements ITypescriptServiceClient if (this.tsServerLogFile) { this.info(`TSServer log file: ${this.tsServerLogFile}`); } - this.serviceExited(true); + this.serviceExited(!this.isRestarting); + this.isRestarting = false; }); this.reader = new Reader( diff --git a/npm-shrinkwrap.json b/npm-shrinkwrap.json index 7b76d1c9edb..a1d1223cab2 100644 --- a/npm-shrinkwrap.json +++ b/npm-shrinkwrap.json @@ -442,7 +442,7 @@ "xterm": { "version": "2.7.0", "from": "Tyriar/xterm.js#vscode-release/1.14", - "resolved": "git+https://github.com/Tyriar/xterm.js.git#1d7007669dec1f60e5878aa102a36473d8cbd97f" + "resolved": "git+https://github.com/Tyriar/xterm.js.git#7d3640ad17fbf69f1a1c776b6d08969e1da32875" }, "yauzl": { "version": "2.3.1", diff --git a/src/vs/base/node/extfs.ts b/src/vs/base/node/extfs.ts index ef8680f062a..ecffac0980d 100644 --- a/src/vs/base/node/extfs.ts +++ b/src/vs/base/node/extfs.ts @@ -374,13 +374,13 @@ export function writeFileAndFlush(path: string, data: string | NodeBuffer, optio /** * Copied from: https://github.com/Microsoft/vscode-node-debug/blob/master/src/node/pathUtilities.ts#L83 * - * Given an absolute, normalized, and existing file path 'realpath' returns the exact path that the file has on disk. + * Given an absolute, normalized, and existing file path 'realcase' returns the exact path that the file has on disk. * On a case insensitive file system, the returned path might differ from the original path by character casing. * On a case sensitive file system, the returned path will always be identical to the original path. * In case of errors, null is returned. But you cannot use this function to verify that a path exists. - * realpathSync does not handle '..' or '.' path segments and it does not take the locale into account. + * realcaseSync does not handle '..' or '.' path segments and it does not take the locale into account. */ -export function realpathSync(path: string): string { +export function realcaseSync(path: string): string { const dir = paths.dirname(path); if (path === dir) { // end recursion return path; @@ -392,7 +392,7 @@ export function realpathSync(path: string): string { const found = entries.filter(e => e.toLowerCase() === name); // use a case insensitive search if (found.length === 1) { // on a case sensitive filesystem we cannot determine here, whether the file exists or not, hence we need the 'file exists' precondition - const prefix = realpathSync(dir); // recurse + const prefix = realcaseSync(dir); // recurse if (prefix) { return paths.join(prefix, found[0]); } @@ -400,7 +400,7 @@ export function realpathSync(path: string): string { // must be a case sensitive $filesystem const ix = found.indexOf(name); if (ix >= 0) { // case sensitive - const prefix = realpathSync(dir); // recurse + const prefix = realcaseSync(dir); // recurse if (prefix) { return paths.join(prefix, found[ix]); } @@ -411,4 +411,44 @@ export function realpathSync(path: string): string { } return null; +} + +export function realpathSync(path: string): string { + try { + return fs.realpathSync(path); + } catch (error) { + + // We hit an error calling fs.realpathSync(). Since fs.realpathSync() is doing some path normalization + // we now do a similar normalization and then try again if we can access the path with read + // permissions at least. If that succeeds, we return that path. + // fs.realpath() is resolving symlinks and that can fail in certain cases. The workaround is + // to not resolve links but to simply see if the path is read accessible or not. + const normalizedPath = normalizePath(path); + fs.accessSync(normalizedPath, fs.constants.R_OK); // throws in case of an error + + return normalizedPath; + } +} + +export function realpath(path: string, callback: (error: Error, realpath: string) => void): void { + return fs.realpath(path, (error, realpath) => { + if (!error) { + return callback(null, realpath); + } + + // We hit an error calling fs.realpath(). Since fs.realpath() is doing some path normalization + // we now do a similar normalization and then try again if we can access the path with read + // permissions at least. If that succeeds, we return that path. + // fs.realpath() is resolving symlinks and that can fail in certain cases. The workaround is + // to not resolve links but to simply see if the path is read accessible or not. + const normalizedPath = normalizePath(path); + + return fs.access(normalizedPath, fs.constants.R_OK, error => { + return callback(error, normalizedPath); + }); + }); +} + +function normalizePath(path: string): string { + return strings.rtrim(paths.normalize(path), paths.sep); } \ No newline at end of file diff --git a/src/vs/base/node/pfs.ts b/src/vs/base/node/pfs.ts index 9ff23afdfa1..3d8e1808439 100644 --- a/src/vs/base/node/pfs.ts +++ b/src/vs/base/node/pfs.ts @@ -72,7 +72,7 @@ export function rimraf(path: string): TPromise { } export function realpath(path: string): TPromise { - return nfcall(fs.realpath, path, null); + return nfcall(extfs.realpath, path); } export function stat(path: string): TPromise { diff --git a/src/vs/base/test/node/extfs/extfs.test.ts b/src/vs/base/test/node/extfs/extfs.test.ts index 1eda91cea9d..ca184afd097 100644 --- a/src/vs/base/test/node/extfs/extfs.test.ts +++ b/src/vs/base/test/node/extfs/extfs.test.ts @@ -203,7 +203,7 @@ suite('Extfs', () => { }); }); - test('realpath', (done) => { + test('realcase', (done) => { const id = uuid.generateUuid(); const parentDir = path.join(os.tmpdir(), 'vsctests', id); const newDir = path.join(parentDir, 'extfs', id); @@ -213,7 +213,7 @@ suite('Extfs', () => { // assume case insensitive file system if (process.platform === 'win32' || process.platform === 'darwin') { const upper = newDir.toUpperCase(); - const real = extfs.realpathSync(upper); + const real = extfs.realcaseSync(upper); if (real) { // can be null in case of permission errors assert.notEqual(real, upper); @@ -224,11 +224,45 @@ suite('Extfs', () => { // linux, unix, etc. -> assume case sensitive file system else { - const real = extfs.realpathSync(newDir); + const real = extfs.realcaseSync(newDir); assert.equal(real, newDir); } extfs.del(parentDir, os.tmpdir(), () => { }, done); }); }); + + test('realpath', (done) => { + const id = uuid.generateUuid(); + const parentDir = path.join(os.tmpdir(), 'vsctests', id); + const newDir = path.join(parentDir, 'extfs', id); + + extfs.mkdirp(newDir, 493, (error) => { + + extfs.realpath(newDir, (error, realpath) => { + assert.ok(realpath); + assert.ok(!error); + + extfs.del(parentDir, os.tmpdir(), () => { }, done); + }); + }); + }); + + test('realpathSync', (done) => { + const id = uuid.generateUuid(); + const parentDir = path.join(os.tmpdir(), 'vsctests', id); + const newDir = path.join(parentDir, 'extfs', id); + + extfs.mkdirp(newDir, 493, (error) => { + let realpath: string; + try { + realpath = extfs.realpathSync(newDir); + } catch (error) { + assert.ok(!error); + } + assert.ok(realpath); + + extfs.del(parentDir, os.tmpdir(), () => { }, done); + }); + }); }); \ No newline at end of file diff --git a/src/vs/code/electron-main/app.ts b/src/vs/code/electron-main/app.ts index 9d09792a65b..8effa87307f 100644 --- a/src/vs/code/electron-main/app.ts +++ b/src/vs/code/electron-main/app.ts @@ -48,6 +48,7 @@ import { isUndefinedOrNull } from "vs/base/common/types"; import { CodeWindow } from "vs/code/electron-main/window"; import { isEqual, isParent } from "vs/platform/files/common/files"; import { KeyboardLayoutMonitor } from "vs/code/electron-main/keyboard"; +import URI from 'vs/base/common/uri'; export class CodeApplication { private toDispose: IDisposable[]; @@ -119,6 +120,23 @@ export class CodeApplication { } }); + const isValidWebviewSource = (source: string) => + !source || (source.toLowerCase() as any).startsWith(URI.file(this.environmentService.appRoot.toLowerCase()).toString()); + + app.on('web-contents-created', (event, contents) => { + contents.on('will-attach-webview', (event, webPreferences, params) => { + delete webPreferences.preload; + webPreferences.nodeIntegration = false; + + // Verify URLs being loaded + if (isValidWebviewSource(params.src) && isValidWebviewSource(webPreferences.preloadURL)) { + return; + } + // Otherwise prevent loading + event.preventDefault(); + }); + }); + let macOpenFiles: string[] = []; let runningTimeout: number = null; app.on('open-file', (event: Event, path: string) => { diff --git a/src/vs/code/node/paths.ts b/src/vs/code/node/paths.ts index 8ad9d195910..1436632f935 100644 --- a/src/vs/code/node/paths.ts +++ b/src/vs/code/node/paths.ts @@ -5,7 +5,6 @@ 'use strict'; -import * as fs from 'original-fs'; import * as path from 'path'; import * as arrays from 'vs/base/common/arrays'; import * as strings from 'vs/base/common/strings'; @@ -13,6 +12,7 @@ import * as paths from 'vs/base/common/paths'; import * as platform from 'vs/base/common/platform'; import * as types from 'vs/base/common/types'; import { ParsedArgs } from 'vs/platform/environment/common/environment'; +import { realpathSync } from "vs/base/node/extfs"; export function validatePaths(args: ParsedArgs): ParsedArgs { @@ -43,7 +43,7 @@ function doValidatePaths(args: string[], gotoLineMode?: boolean): string[] { let realPath: string; try { - realPath = fs.realpathSync(pathCandidate); + realPath = realpathSync(pathCandidate); } catch (error) { // in case of an error, assume the user wants to create this file // if the path is relative, we join it to the cwd diff --git a/src/vs/workbench/electron-browser/actions.ts b/src/vs/workbench/electron-browser/actions.ts index cad6f26bd2f..ef63d8a7cf6 100644 --- a/src/vs/workbench/electron-browser/actions.ts +++ b/src/vs/workbench/electron-browser/actions.ts @@ -6,6 +6,7 @@ 'use strict'; import URI from 'vs/base/common/uri'; +import * as collections from 'vs/base/common/collections'; import { TPromise } from 'vs/base/common/winjs.base'; import { Action } from 'vs/base/common/actions'; import { IWindowIPCService } from 'vs/workbench/services/window/electron-browser/windowService'; @@ -832,21 +833,33 @@ Steps to Reproduce: } private generateExtensionTable(extensions: ILocalExtension[]): string { + const { nonThemes, themes } = collections.groupBy(extensions, ext => { + const manifestKeys = ext.manifest.contributes ? Object.keys(ext.manifest.contributes) : []; + const onlyTheme = !ext.manifest.activationEvents && manifestKeys.length === 1 && manifestKeys[0] === 'themes'; + return onlyTheme ? 'themes' : 'nonThemes'; + }); + + const themeExclusionStr = themes.length ? `\n(${themes.length} theme extensions excluded)` : ''; + extensions = nonThemes; + if (!extensions.length) { - return 'none'; + return 'none' + themeExclusionStr; } - let tableHeader = `|Extension|Author|Version| -|---|---|---|`; + let tableHeader = `Extension|Author (truncated)|Version +---|---|---`; const table = extensions.map(e => { - return `|${e.manifest.name}|${e.manifest.publisher}|${e.manifest.version}|`; + return `${e.manifest.name}|${e.manifest.publisher.substr(0, 3)}|${e.manifest.version}`; }).join('\n'); const extensionTable = ` -${tableHeader}\n${table}; +${tableHeader} +${table} +${themeExclusionStr} `; + // 2000 chars is browsers de-facto limit for URLs, 400 chars are allowed for other string parts of the issue URL // http://stackoverflow.com/questions/417142/what-is-the-maximum-length-of-a-url-in-different-browsers if (encodeURIComponent(extensionTable).length > 1600) { diff --git a/src/vs/workbench/parts/debug/common/debugSource.ts b/src/vs/workbench/parts/debug/common/debugSource.ts index 042c9e8d1b7..18d8149f874 100644 --- a/src/vs/workbench/parts/debug/common/debugSource.ts +++ b/src/vs/workbench/parts/debug/common/debugSource.ts @@ -34,7 +34,7 @@ export class Source { } public get available() { - return this.raw.name !== UNKNOWN_SOURCE_LABEL; + return this.raw.name !== UNKNOWN_SOURCE_LABEL && this.presentationHint !== 'deemphasize'; } public get inMemory() { diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index 44a6c047dff..b03ee074b1e 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -342,6 +342,8 @@ export class TerminalInstance implements ITerminalInstance { } public selectAll(): void { + // Focus here to ensure the terminal context key is set + this._xterm.focus(); this._xterm.selectAll(); } @@ -794,6 +796,7 @@ export class TerminalInstance implements ITerminalInstance { public setTitle(title: string): void { const didTitleChange = title !== this._title; + this._title = title; if (didTitleChange) { this._onTitleChanged.fire(title); } diff --git a/src/vs/workbench/services/files/node/watcher/unix/chokidarWatcherService.ts b/src/vs/workbench/services/files/node/watcher/unix/chokidarWatcherService.ts index 63a17ea995d..3dc0a747c60 100644 --- a/src/vs/workbench/services/files/node/watcher/unix/chokidarWatcherService.ts +++ b/src/vs/workbench/services/files/node/watcher/unix/chokidarWatcherService.ts @@ -15,7 +15,7 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { FileChangeType } from 'vs/platform/files/common/files'; import { ThrottledDelayer } from 'vs/base/common/async'; import strings = require('vs/base/common/strings'); -import { realpathSync } from 'vs/base/node/extfs'; +import { realcaseSync } from 'vs/base/node/extfs'; import { isMacintosh } from 'vs/base/common/platform'; import watcher = require('vs/workbench/services/files/node/watcher/common'); import { IWatcherRequest, IWatcherService } from './watcher'; @@ -43,7 +43,7 @@ export class ChokidarWatcherService implements IWatcherService { // so we have to find the real casing of the path and do some path massaging to fix this // see https://github.com/paulmillr/chokidar/issues/418 const originalBasePath = request.basePath; - const realBasePath = isMacintosh ? (realpathSync(originalBasePath) || originalBasePath) : originalBasePath; + const realBasePath = isMacintosh ? (realcaseSync(originalBasePath) || originalBasePath) : originalBasePath; const realBasePathLength = realBasePath.length; const realBasePathDiffers = (originalBasePath !== realBasePath); -- GitLab From 07b50d906ee75ef48b9f9de47d20f4913d11e736 Mon Sep 17 00:00:00 2001 From: isidor Date: Wed, 14 Jun 2017 09:43:48 +0200 Subject: [PATCH 0791/1347] explorerViewModel.test -> explorerModel.test --- .../browser/{explorerViewModel.test.ts => explorerModel.test.ts} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename src/vs/workbench/parts/files/test/browser/{explorerViewModel.test.ts => explorerModel.test.ts} (100%) diff --git a/src/vs/workbench/parts/files/test/browser/explorerViewModel.test.ts b/src/vs/workbench/parts/files/test/browser/explorerModel.test.ts similarity index 100% rename from src/vs/workbench/parts/files/test/browser/explorerViewModel.test.ts rename to src/vs/workbench/parts/files/test/browser/explorerModel.test.ts -- GitLab From a3ea17e7d87686b35e22a7dc983fd8c21988e9d6 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Tue, 13 Jun 2017 16:02:53 +0200 Subject: [PATCH 0792/1347] Do not paint minimap unless a line inside it has changed --- .../browser/viewParts/minimap/minimap.ts | 41 ++++++++++++++++--- 1 file changed, 36 insertions(+), 5 deletions(-) diff --git a/src/vs/editor/browser/viewParts/minimap/minimap.ts b/src/vs/editor/browser/viewParts/minimap/minimap.ts index 676300944f1..1358242f406 100644 --- a/src/vs/editor/browser/viewParts/minimap/minimap.ts +++ b/src/vs/editor/browser/viewParts/minimap/minimap.ts @@ -614,10 +614,41 @@ export class Minimap extends ViewPart { this._slider.setTop(layout.sliderTop); this._slider.setHeight(layout.sliderHeight); + this._lastRenderData = this.renderLines(layout); + } + + private renderLines(layout: MinimapLayout): RenderData { + const renderMinimap = this._options.renderMinimap; const startLineNumber = layout.startLineNumber; const endLineNumber = layout.endLineNumber; const minimapLineHeight = getMinimapLineHeight(renderMinimap); + // Check if nothing changed w.r.t. lines from last frame + if (this._lastRenderData) { + const _lastData = this._lastRenderData._get(); + const lastStartLineNumber = _lastData.rendLineNumberStart; + const lastLines = _lastData.lines; + const lastLinesLength = lastLines.length; + + let linesNeedPainting = false; + for (let lineNumber = startLineNumber; lineNumber <= endLineNumber; lineNumber++) { + const lastLineIndex = lineNumber - lastStartLineNumber; + const source_dy = (lastLineIndex >= 0 && lastLineIndex < lastLinesLength ? lastLines[lastLineIndex].dy : -1); + + if (source_dy === -1) { + linesNeedPainting = true; + break; + } + } + + if (!linesNeedPainting) { + // Nice!! Nothing changed from last frame + return new RenderData(layout, _lastData.imageData, _lastData.lines); + } + } + + // Oh well!! We need to repaint some lines... + const imageData = this._getBuffer(); // Render untouched lines by using last rendered data. @@ -656,16 +687,16 @@ export class Minimap extends ViewPart { dy += minimapLineHeight; } + // Finally, paint to the canvas + const ctx = this._canvas.domNode.getContext('2d'); + ctx.putImageData(imageData, 0, 0); + // Save rendered data for reuse on next frame if possible - this._lastRenderData = new RenderData( + return new RenderData( layout, imageData, renderedLines ); - - // Finally, paint to the canvas - const ctx = this._canvas.domNode.getContext('2d'); - ctx.putImageData(imageData, 0, 0); } private static _renderUntouchedLines( -- GitLab From 9f482b34502fded5b5c0df3af951b909192fb92a Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 14 Jun 2017 07:47:43 +0200 Subject: [PATCH 0793/1347] Hint GPU layers for editor sliders --- src/vs/base/browser/dom.ts | 5 +++++ src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts | 1 + src/vs/editor/browser/viewParts/minimap/minimap.ts | 1 + 3 files changed, 7 insertions(+) diff --git a/src/vs/base/browser/dom.ts b/src/vs/base/browser/dom.ts index 228550b57af..2915bcb44bb 100644 --- a/src/vs/base/browser/dom.ts +++ b/src/vs/base/browser/dom.ts @@ -1041,3 +1041,8 @@ export function domContentLoaded(): TPromise { } }); } + +export function hintGPULayer(target: HTMLElement): void { + // This is to hint browsers that this dom node is suited to live in its own layer (e.g. sliders, etc.) + (target.style).willChange = 'transform'; +} diff --git a/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts b/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts index c7194cbc5c5..7a8743cb62a 100644 --- a/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts +++ b/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts @@ -170,6 +170,7 @@ export abstract class AbstractScrollbar extends Widget { this.domNode.setTransform('translate3d(0px, 0px, 0px)'); } else { this.domNode.setTransform(''); + DomUtils.hintGPULayer(this.domNode.domNode); } this._renderDomNode(this._scrollbarState.getRectangleLargeSize(), this._scrollbarState.getRectangleSmallSize()); diff --git a/src/vs/editor/browser/viewParts/minimap/minimap.ts b/src/vs/editor/browser/viewParts/minimap/minimap.ts index 1358242f406..70cb44e1523 100644 --- a/src/vs/editor/browser/viewParts/minimap/minimap.ts +++ b/src/vs/editor/browser/viewParts/minimap/minimap.ts @@ -413,6 +413,7 @@ export class Minimap extends ViewPart { this._slider = createFastDomNode(document.createElement('div')); this._slider.setPosition('absolute'); this._slider.setClassName('minimap-slider'); + dom.hintGPULayer(this._slider.domNode); this._domNode.appendChild(this._slider); this._tokensColorTracker = MinimapTokensColorTracker.getInstance(); -- GitLab From 10f05818b9342ede40900738b115aaa9b5e06f47 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 14 Jun 2017 10:08:06 +0200 Subject: [PATCH 0794/1347] Added smoke test step. --- build/tfs/darwin/smoketest.sh | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/build/tfs/darwin/smoketest.sh b/build/tfs/darwin/smoketest.sh index ae756d8ca35..18da9dabf38 100755 --- a/build/tfs/darwin/smoketest.sh +++ b/build/tfs/darwin/smoketest.sh @@ -24,4 +24,11 @@ step "Run unit tests" \ ./scripts/test.sh --build --reporter dot step "Run integration tests" \ - ./scripts/test-integration.sh \ No newline at end of file + ./scripts/test-integration.sh + +step "Run smoke test" \ + pushd test/smoke + npm install + npm run compile + node src/main.js --latest "$AGENT_BUILDDIRECTORY/VSCode-darwin/Visual Studio Code - Insiders.app/Contents/MacOS/Electron" + popd \ No newline at end of file -- GitLab From 723bc3b3a74b8fe528648bfd4b665045bef12da0 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Wed, 14 Jun 2017 10:14:46 +0200 Subject: [PATCH 0795/1347] fix some typescript@next compilation errors related to #28151 --- src/vs/workbench/api/node/extHost.api.impl.ts | 2 +- src/vs/workbench/api/node/extHostSCM.ts | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index b450e6538e6..9f3ed92538c 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -408,7 +408,7 @@ export function createApiFactory( onWillSaveTextDocument: (listener, thisArgs?, disposables?) => { return extHostDocumentSaveParticipant.onWillSaveTextDocumentEvent(listener, thisArgs, disposables); }, - onDidChangeConfiguration: (listener: () => any, thisArgs?: any, disposables?: extHostTypes.Disposable[]) => { + onDidChangeConfiguration: (listener: (_: any) => any, thisArgs?: any, disposables?: extHostTypes.Disposable[]) => { return extHostConfiguration.onDidChangeConfiguration(listener, thisArgs, disposables); }, getConfiguration: (section?: string): vscode.WorkspaceConfiguration => { diff --git a/src/vs/workbench/api/node/extHostSCM.ts b/src/vs/workbench/api/node/extHostSCM.ts index 9d40839b177..8a87e5126c0 100644 --- a/src/vs/workbench/api/node/extHostSCM.ts +++ b/src/vs/workbench/api/node/extHostSCM.ts @@ -316,14 +316,14 @@ export class ExtHostSCM { return sourceControl; } - $provideOriginalResource(sourceControlHandle: number, uri: URI): TPromise { + $provideOriginalResource(sourceControlHandle: number, uri: URI): TPromise { const sourceControl = this._sourceControls.get(sourceControlHandle); if (!sourceControl || !sourceControl.quickDiffProvider) { return TPromise.as(null); } - return asWinJsPromise(token => sourceControl.quickDiffProvider.provideOriginalResource(uri, token)); + return asWinJsPromise(token => URI.parse(sourceControl.quickDiffProvider.provideOriginalResource(uri, token).toString())); } $onActiveSourceControlChange(handle: number): TPromise { -- GitLab From b33113d484d2f06c5fc60d0045a8a3929399d105 Mon Sep 17 00:00:00 2001 From: Nick Snyder Date: Wed, 14 Jun 2017 01:26:31 -0700 Subject: [PATCH 0796/1347] Only update viewlet switcher if it has already been rendered (#28568) --- .../workbench/browser/parts/activitybar/activitybarPart.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts b/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts index 75f4d49aa70..e24e7c1dc4a 100644 --- a/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts +++ b/src/vs/workbench/browser/parts/activitybar/activitybarPart.ts @@ -293,6 +293,11 @@ export class ActivitybarPart extends Part implements IActivityBarService { } private updateViewletSwitcher() { + if (!this.viewletSwitcherBar) { + // We have not been rendered yet so there is nothing to update. + return; + } + let viewletsToShow = this.getPinnedViewlets(); // Always show the active viewlet even if it is marked to be hidden -- GitLab From a7d864df4cfe3e18e16dfd3d5d5d54d1eb4fbc17 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Wed, 14 Jun 2017 10:45:06 +0200 Subject: [PATCH 0797/1347] #28538 Introduce IWorkspace2 in IWorkspaceContextService --- .../browser/standalone/simpleServices.ts | 10 +++- src/vs/platform/workspace/common/workspace.ts | 34 ++++++++--- .../electron-browser/mainThreadWorkspace.ts | 2 +- .../configuration/node/configuration.ts | 60 ++++++++++++------- .../workbench/test/workbenchTestServices.ts | 14 +++-- 5 files changed, 82 insertions(+), 38 deletions(-) diff --git a/src/vs/editor/browser/standalone/simpleServices.ts b/src/vs/editor/browser/standalone/simpleServices.ts index e380ac9bd39..c063ec34f7b 100644 --- a/src/vs/editor/browser/standalone/simpleServices.ts +++ b/src/vs/editor/browser/standalone/simpleServices.ts @@ -17,7 +17,7 @@ import { KeybindingResolver } from 'vs/platform/keybinding/common/keybindingReso import { IKeybindingEvent, KeybindingSource, IKeyboardEvent } from 'vs/platform/keybinding/common/keybinding'; import { ContextKeyExpr, IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; import { IConfirmation, IMessageService } from 'vs/platform/message/common/message'; -import { IWorkspaceContextService, Workspace, IWorkspace } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService, Workspace, IWorkspace, IWorkspace2 } from 'vs/platform/workspace/common/workspace'; import * as editorCommon from 'vs/editor/common/editorCommon'; import { ICodeEditor, IDiffEditor } from 'vs/editor/browser/editorBrowser'; import { Selection } from 'vs/editor/common/core/selection'; @@ -495,8 +495,8 @@ export class SimpleWorkspaceContextService implements IWorkspaceContextService { public _serviceBrand: any; - private readonly _onDidChangeFolders: Emitter = new Emitter(); - public readonly onDidChangeFolders: Event = this._onDidChangeFolders.event; + private readonly _onDidChangeWorkspaceRoots: Emitter = new Emitter(); + public readonly onDidChangeWorkspaceRoots: Event = this._onDidChangeWorkspaceRoots.event; private readonly folders: URI[]; @@ -512,6 +512,10 @@ export class SimpleWorkspaceContextService implements IWorkspaceContextService { return this.workspace; } + public getWorkspace2(): IWorkspace2 { + return this.workspace ? { id: `${this.workspace.uid}`, roots: [this.workspace.resource] } : void 0; + } + public hasWorkspace(): boolean { return !!this.workspace; } diff --git a/src/vs/platform/workspace/common/workspace.ts b/src/vs/platform/workspace/common/workspace.ts index a1ccdac3e62..8e1b08ed143 100644 --- a/src/vs/platform/workspace/common/workspace.ts +++ b/src/vs/platform/workspace/common/workspace.ts @@ -27,6 +27,17 @@ export interface IWorkspaceContextService { */ getWorkspace(): IWorkspace; + /** + * Provides access to the workspace object the platform is running with. This may be null if the workbench was opened + * without workspace (empty); + */ + getWorkspace2(): IWorkspace2; + + /** + * An event which fires on workspace roots change. + */ + onDidChangeWorkspaceRoots: Event; + /** * Returns iff the provided resource is inside the workspace or not. */ @@ -44,11 +55,6 @@ export interface IWorkspaceContextService { */ toResource: (workspaceRelativePath: string) => URI; - /** - * TODO@Ben multiroot - */ - getFolders(): URI[]; - onDidChangeFolders: Event; } export interface IWorkspace { @@ -72,6 +78,20 @@ export interface IWorkspace { name?: string; } +export interface IWorkspace2 { + + /** + * the unique identifier of the workspace. + */ + readonly id: string; + + /** + * Mutliple roots in this workspace. First entry is master and never changes. + */ + readonly roots: URI[]; + +} + export class Workspace implements IWorkspace { constructor(private _resource: URI, private _uid?: number, private _name?: string) { @@ -105,9 +125,9 @@ export class Workspace implements IWorkspace { return null; } - public toResource(workspaceRelativePath: string): URI { + public toResource(workspaceRelativePath: string, root?: URI): URI { if (typeof workspaceRelativePath === 'string') { - return URI.file(paths.join(this._resource.fsPath, workspaceRelativePath)); + return URI.file(paths.join(root ? root.fsPath : this._resource.fsPath, workspaceRelativePath)); } return null; diff --git a/src/vs/workbench/api/electron-browser/mainThreadWorkspace.ts b/src/vs/workbench/api/electron-browser/mainThreadWorkspace.ts index f7cd4fb7e91..f6fc31c91ef 100644 --- a/src/vs/workbench/api/electron-browser/mainThreadWorkspace.ts +++ b/src/vs/workbench/api/electron-browser/mainThreadWorkspace.ts @@ -37,7 +37,7 @@ export class MainThreadWorkspace extends MainThreadWorkspaceShape { ) { super(); this._proxy = threadService.get(ExtHostContext.ExtHostWorkspace); - this._contextService.onDidChangeFolders(this._onDidChangeWorkspace, this, this._toDispose); + this._contextService.onDidChangeWorkspaceRoots(this._onDidChangeWorkspace, this, this._toDispose); } // --- workspace --- diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index 4f0baaf5ba0..f449677e865 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -17,7 +17,7 @@ import { Schemas } from "vs/base/common/network"; import { RunOnceScheduler } from 'vs/base/common/async'; import { readFile } from 'vs/base/node/pfs'; import * as extfs from 'vs/base/node/extfs'; -import { IWorkspaceContextService, Workspace, IWorkspace } from "vs/platform/workspace/common/workspace"; +import { IWorkspaceContextService, IWorkspace2, Workspace as SingleRootWorkspace, IWorkspace } from "vs/platform/workspace/common/workspace"; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { FileChangeType, FileChangesEvent, isEqual } from 'vs/platform/files/common/files'; import { ConfigModel } from 'vs/platform/configuration/common/model'; @@ -44,14 +44,29 @@ interface IWorkspaceConfiguration { type IWorkspaceFoldersConfiguration = { [rootFolder: string]: { folders: string[]; } }; +class Workspace implements IWorkspace2 { + + constructor(readonly id: string, private _roots: URI[]) { + } + + get roots(): URI[] { + return this._roots; + } + + setRoots(roots: URI[]): void { + this._roots = roots; + } + +} + export class WorkspaceConfigurationService extends Disposable implements IWorkspaceContextService, IWorkspaceConfigurationService { private static RELOAD_CONFIGURATION_DELAY = 50; public _serviceBrand: any; - private readonly _onDidChangeFolders: Emitter = this._register(new Emitter()); - public readonly onDidChangeFolders: Event = this._onDidChangeFolders.event; + private readonly _onDidChangeWorkspaceRoots: Emitter = this._register(new Emitter()); + public readonly onDidChangeWorkspaceRoots: Event = this._onDidChangeWorkspaceRoots.event; private readonly _onDidUpdateConfiguration: Emitter = this._register(new Emitter()); public readonly onDidUpdateConfiguration: Event = this._onDidUpdateConfiguration.event; @@ -65,12 +80,12 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp private workspaceFilePathToConfiguration: { [relativeWorkspacePath: string]: TPromise> }; private reloadConfigurationScheduler: RunOnceScheduler; - private folders: URI[]; + private readonly workspace: Workspace; - constructor(private environmentService: IEnvironmentService, private workspace?: Workspace, private workspaceSettingsRootFolder: string = WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME) { + constructor(private environmentService: IEnvironmentService, private singleRootWorkspace?: SingleRootWorkspace, private workspaceSettingsRootFolder: string = WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME) { super(); - this.folders = workspace ? [workspace.resource] : []; + this.workspace = singleRootWorkspace ? new Workspace(`${singleRootWorkspace.uid}`, [singleRootWorkspace.resource]) : null; this.workspaceFilePathToConfiguration = Object.create(null); this.cachedConfig = new ConfigModel(null); @@ -95,10 +110,11 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } // Resovled configured folders for workspace - let configuredFolders: URI[] = [this.workspace.resource]; + let [master] = this.workspace.roots; + let configuredFolders: URI[] = [master]; const config = this.getConfiguration('workspace'); if (config) { - const workspaceConfig = config[this.workspace.resource.toString()]; + const workspaceConfig = config[master.toString()]; if (workspaceConfig) { const additionalFolders = workspaceConfig.folders .map(f => URI.parse(f)) @@ -112,20 +128,20 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp configuredFolders = distinct(configuredFolders, r => r.toString()); // Find changes - const changed = !equals(this.folders, configuredFolders, (r1, r2) => r1.toString() === r2.toString()); + const changed = !equals(this.workspace.roots, configuredFolders, (r1, r2) => r1.toString() === r2.toString()); - this.folders = configuredFolders; + this.workspace.setRoots(configuredFolders); if (notify && changed) { - this._onDidChangeFolders.fire(configuredFolders); + this._onDidChangeWorkspaceRoots.fire(configuredFolders); } } - public getFolders(): URI[] { - return this.folders; + public getWorkspace(): IWorkspace { + return this.singleRootWorkspace; } - public getWorkspace(): IWorkspace { + public getWorkspace2(): IWorkspace2 { return this.workspace; } @@ -134,15 +150,15 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } public isInsideWorkspace(resource: URI): boolean { - return this.workspace ? this.workspace.isInsideWorkspace(resource) : false; + return this.workspace ? this.singleRootWorkspace.isInsideWorkspace(resource) : false; } public toWorkspaceRelativePath(resource: URI, toOSPath?: boolean): string { - return this.workspace ? this.workspace.toWorkspaceRelativePath(resource, toOSPath) : null; + return this.workspace ? this.singleRootWorkspace.toWorkspaceRelativePath(resource, toOSPath) : null; } public toResource(workspaceRelativePath: string): URI { - return this.workspace ? this.workspace.toResource(workspaceRelativePath) : null; + return this.workspace ? this.singleRootWorkspace.toResource(workspaceRelativePath) : null; } private onBaseConfigurationChanged(event: IConfigurationServiceEvent): void { @@ -276,7 +292,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp // once: when invoked for the first time we fetch json files that contribute settings if (!this.bulkFetchFromWorkspacePromise) { - this.bulkFetchFromWorkspacePromise = resolveStat(this.workspace.toResource(this.workspaceSettingsRootFolder)).then(stat => { + this.bulkFetchFromWorkspacePromise = resolveStat(this.toResource(this.workspaceSettingsRootFolder)).then(stat => { if (!stat.isDirectory) { return TPromise.as([]); } @@ -287,11 +303,11 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp return false; // only JSON files } - return this.isWorkspaceConfigurationFile(this.workspace.toWorkspaceRelativePath(stat.resource)); // only workspace config files + return this.isWorkspaceConfigurationFile(this.toWorkspaceRelativePath(stat.resource)); // only workspace config files }).map(stat => stat.resource)); }, err => [] /* never fail this call */) .then((contents: IContent[]) => { - contents.forEach(content => this.workspaceFilePathToConfiguration[this.workspace.toWorkspaceRelativePath(content.resource)] = TPromise.as(this.createConfigModel(content))); + contents.forEach(content => this.workspaceFilePathToConfiguration[this.toWorkspaceRelativePath(content.resource)] = TPromise.as(this.createConfigModel(content))); }, errors.onUnexpectedError); } @@ -317,7 +333,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp continue; // only JSON files or the actual settings folder } - const workspacePath = this.workspace.toWorkspaceRelativePath(resource); + const workspacePath = this.toWorkspaceRelativePath(resource); if (!workspacePath) { continue; // event is not inside workspace } @@ -353,7 +369,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } private createConfigModel(content: IContent): IConfigModel { - const path = this.workspace.toWorkspaceRelativePath(content.resource); + const path = this.toWorkspaceRelativePath(content.resource); if (path === WORKSPACE_CONFIG_DEFAULT_PATH) { return new WorkspaceSettingsConfigModel(content.value, content.resource.toString()); } else { diff --git a/src/vs/workbench/test/workbenchTestServices.ts b/src/vs/workbench/test/workbenchTestServices.ts index c280cd4c979..dc3c013b404 100644 --- a/src/vs/workbench/test/workbenchTestServices.ts +++ b/src/vs/workbench/test/workbenchTestServices.ts @@ -27,7 +27,7 @@ import { ITextModelService } from 'vs/editor/common/services/resolverService'; import { IEditorInput, IEditorOptions, Position, Direction, IEditor, IResourceInput } from 'vs/platform/editor/common/editor'; import { IUntitledEditorService, UntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; import { IMessageService, IConfirmation } from 'vs/platform/message/common/message'; -import { IWorkspace, IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { IWorkspace, IWorkspaceContextService, IWorkspace2 } from 'vs/platform/workspace/common/workspace'; import { ILifecycleService, ShutdownEvent, ShutdownReason, StartupKind, LifecyclePhase } from 'vs/platform/lifecycle/common/lifecycle'; import { EditorStacksModel } from 'vs/workbench/common/editor/editorStacksModel'; import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; @@ -66,16 +66,16 @@ export class TestContextService implements IWorkspaceContextService { private workspace: any; private options: any; - private _onDidChangeFolders: Emitter; + private _onDidChangeWorkspaceRoots: Emitter; constructor(workspace: any = TestWorkspace, options: any = null) { this.workspace = workspace; this.options = options || Object.create(null); - this._onDidChangeFolders = new Emitter(); + this._onDidChangeWorkspaceRoots = new Emitter(); } - public get onDidChangeFolders(): Event { - return this._onDidChangeFolders.event; + public get onDidChangeWorkspaceRoots(): Event { + return this._onDidChangeWorkspaceRoots.event; } public getFolders(): URI[] { @@ -90,6 +90,10 @@ export class TestContextService implements IWorkspaceContextService { return this.workspace; } + public getWorkspace2(): IWorkspace2 { + return this.workspace ? { id: `${this.workspace.uid}`, roots: [this.workspace.resource] } : void 0; + } + public setWorkspace(workspace: any): void { this.workspace = workspace; } -- GitLab From 8d2f5a1075d74d6023e6a8c2c2daa2fd41887a2c Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 14 Jun 2017 10:56:05 +0200 Subject: [PATCH 0798/1347] Refactor tfs linux builds to suit smoke test. --- build/tfs/linux/build.sh | 83 +--------------------------------- build/tfs/linux/release.sh | 86 ++++++++++++++++++++++++++++++++++++ build/tfs/linux/smoketest.sh | 35 +++++++++++++++ 3 files changed, 123 insertions(+), 81 deletions(-) create mode 100644 build/tfs/linux/release.sh create mode 100644 build/tfs/linux/smoketest.sh diff --git a/build/tfs/linux/build.sh b/build/tfs/linux/build.sh index 7e50e47c05d..e6ba3dd8042 100755 --- a/build/tfs/linux/build.sh +++ b/build/tfs/linux/build.sh @@ -32,84 +32,5 @@ step "Build minified" \ step "Run unit tests" \ ./scripts/test.sh --xvfb --build --reporter dot -step "Build Debian package" \ - npm run gulp -- --max_old_space_size=4096 "vscode-linux-$ARCH-build-deb" - -step "Build RPM package" \ - npm run gulp -- --max_old_space_size=4096 "vscode-linux-$ARCH-build-rpm" - -(cd $BUILD_SOURCESDIRECTORY/build/tfs/common && \ - step "Install build dependencies" \ - npm install --unsafe-perm) - -# Variables -PLATFORM_LINUX="linux-$ARCH" -PLATFORM_DEB="linux-deb-$ARCH" -PLATFORM_RPM="linux-rpm-$ARCH" -[[ "$ARCH" == "ia32" ]] && DEB_ARCH="i386" || DEB_ARCH="amd64" -[[ "$ARCH" == "ia32" ]] && RPM_ARCH="i386" || RPM_ARCH="x86_64" -REPO="`pwd`" -ROOT="$REPO/.." -BUILDNAME="VSCode-$PLATFORM_LINUX" -BUILD="$ROOT/$BUILDNAME" -BUILD_VERSION="$(ls $REPO/.build/linux/deb/$DEB_ARCH/deb/ | sed -e 's/code-[a-z]*_//g' -e 's/\.deb$//g')" -[ -z "$VSCODE_QUALITY" ] && TARBALL_FILENAME="code-$BUILD_VERSION.tar.gz" || TARBALL_FILENAME="code-$VSCODE_QUALITY-$BUILD_VERSION.tar.gz" -TARBALL_PATH="$ROOT/$TARBALL_FILENAME" -PACKAGEJSON="$BUILD/resources/app/package.json" -VERSION=$(node -p "require(\"$PACKAGEJSON\").version") - -rm -rf $ROOT/code-*.tar.* -(cd $ROOT && \ - step "Create tar.gz archive" \ - tar -czvf $TARBALL_PATH $BUILDNAME) - -step "Publish tar.gz archive" \ - node build/tfs/common/publish.js $VSCODE_QUALITY $PLATFORM_LINUX archive-unsigned $TARBALL_FILENAME $VERSION true $TARBALL_PATH - -DEB_FILENAME="$(ls $REPO/.build/linux/deb/$DEB_ARCH/deb/)" -DEB_PATH="$REPO/.build/linux/deb/$DEB_ARCH/deb/$DEB_FILENAME" - -step "Publish Debian package" \ - node build/tfs/common/publish.js $VSCODE_QUALITY $PLATFORM_DEB package $DEB_FILENAME $VERSION true $DEB_PATH - -RPM_FILENAME="$(ls $REPO/.build/linux/rpm/$RPM_ARCH/ | grep .rpm)" -RPM_PATH="$REPO/.build/linux/rpm/$RPM_ARCH/$RPM_FILENAME" - -step "Publish RPM package" \ - node build/tfs/common/publish.js $VSCODE_QUALITY $PLATFORM_RPM package $RPM_FILENAME $VERSION true $RPM_PATH - -if [ -z "$VSCODE_QUALITY" ]; then - echo "VSCODE_QUALITY is not set, skipping repo package publish" -else - if [ "$BUILD_SOURCEBRANCH" = "master" ] || [ "$BUILD_SOURCEBRANCH" = "refs/heads/master" ]; then - if [[ $BUILD_QUEUEDBY = *"Project Collection Service Accounts"* || $BUILD_QUEUEDBY = *"Microsoft.VisualStudio.Services.TFS"* ]]; then - # Get necessary information - pushd $REPO && COMMIT_HASH=$(git rev-parse HEAD) && popd - PACKAGE_NAME="$(ls $REPO/.build/linux/deb/$DEB_ARCH/deb/ | sed -e 's/_.*//g')" - DEB_URL="https://az764295.vo.msecnd.net/$VSCODE_QUALITY/$COMMIT_HASH/$DEB_FILENAME" - RPM_URL="https://az764295.vo.msecnd.net/$VSCODE_QUALITY/$COMMIT_HASH/$RPM_FILENAME" - PACKAGE_VERSION="$(ls $REPO/.build/linux/deb/$DEB_ARCH/deb/ | sed -e 's/code-[a-z]*_//g' -e 's/\_.*$//g')" - # Write config files needed by API, use eval to force environment variable expansion - DIRNAME=$(dirname $(readlink -f $0)) - pushd $DIRNAME - # Submit to apt repo - if [ "$DEB_ARCH" = "amd64" ]; then - eval echo '{ \"server\": \"azure-apt-cat.cloudapp.net\", \"protocol\": \"https\", \"port\": \"443\", \"repositoryId\": \"58a4adf642421134a1a48d1a\", \"username\": \"$LINUX_REPO_USERNAME\", \"password\": \"$LINUX_REPO_PASSWORD\" }' > apt-config.json - eval echo '{ \"name\": \"$PACKAGE_NAME\", \"version\": \"$PACKAGE_VERSION\", \"repositoryId\": \"58a4adf642421134a1a48d1a\", \"sourceUrl\": \"$DEB_URL\" }' > apt-addpkg.json - echo "Submitting apt-addpkg.json:" - cat apt-addpkg.json - - step "Publish to repositories" \ - ./repoapi_client.sh -config apt-config.json -addpkg apt-addpkg.json - fi - # Submit to yum repo (disabled as it's manual until signing is automated) - # eval echo '{ \"server\": \"azure-apt-cat.cloudapp.net\", \"protocol\": \"https\", \"port\": \"443\", \"repositoryId\": \"58a4ae3542421134a1a48d1b\", \"username\": \"$LINUX_REPO_USERNAME\", \"password\": \"$LINUX_REPO_PASSWORD\" }' > yum-config.json - # eval echo '{ \"name\": \"$PACKAGE_NAME\", \"version\": \"$PACKAGE_VERSION\", \"repositoryId\": \"58a4ae3542421134a1a48d1b\", \"sourceUrl\": \"$RPM_URL\" }' > yum-addpkg.json - # echo "Submitting yum-addpkg.json:" - # cat yum-addpkg.json - # ./repoapi_client.sh -config yum-config.json -addpkg yum-addpkg.json - popd - echo "To check repo publish status run ./repoapi_client.sh -config config.json -check " - fi - fi -fi +step "Publish release" \ + ./build/tfs/linux/release.sh \ No newline at end of file diff --git a/build/tfs/linux/release.sh b/build/tfs/linux/release.sh new file mode 100644 index 00000000000..500622a47d4 --- /dev/null +++ b/build/tfs/linux/release.sh @@ -0,0 +1,86 @@ +#!/bin/sh + +. ./scripts/env.sh +. ./build/tfs/common/common.sh + +step "Build Debian package" \ + npm run gulp -- --max_old_space_size=4096 "vscode-linux-$ARCH-build-deb" + +step "Build RPM package" \ + npm run gulp -- --max_old_space_size=4096 "vscode-linux-$ARCH-build-rpm" + +(cd $BUILD_SOURCESDIRECTORY/build/tfs/common && \ + step "Install build dependencies" \ + npm install --unsafe-perm) + +# Variables +PLATFORM_LINUX="linux-$ARCH" +PLATFORM_DEB="linux-deb-$ARCH" +PLATFORM_RPM="linux-rpm-$ARCH" +[[ "$ARCH" == "ia32" ]] && DEB_ARCH="i386" || DEB_ARCH="amd64" +[[ "$ARCH" == "ia32" ]] && RPM_ARCH="i386" || RPM_ARCH="x86_64" +REPO="`pwd`" +ROOT="$REPO/.." +BUILDNAME="VSCode-$PLATFORM_LINUX" +BUILD="$ROOT/$BUILDNAME" +BUILD_VERSION="$(ls $REPO/.build/linux/deb/$DEB_ARCH/deb/ | sed -e 's/code-[a-z]*_//g' -e 's/\.deb$//g')" +[ -z "$VSCODE_QUALITY" ] && TARBALL_FILENAME="code-$BUILD_VERSION.tar.gz" || TARBALL_FILENAME="code-$VSCODE_QUALITY-$BUILD_VERSION.tar.gz" +TARBALL_PATH="$ROOT/$TARBALL_FILENAME" +PACKAGEJSON="$BUILD/resources/app/package.json" +VERSION=$(node -p "require(\"$PACKAGEJSON\").version") + +rm -rf $ROOT/code-*.tar.* +(cd $ROOT && \ + step "Create tar.gz archive" \ + tar -czvf $TARBALL_PATH $BUILDNAME) + +step "Publish tar.gz archive" \ + node build/tfs/common/publish.js $VSCODE_QUALITY $PLATFORM_LINUX archive-unsigned $TARBALL_FILENAME $VERSION true $TARBALL_PATH + +DEB_FILENAME="$(ls $REPO/.build/linux/deb/$DEB_ARCH/deb/)" +DEB_PATH="$REPO/.build/linux/deb/$DEB_ARCH/deb/$DEB_FILENAME" + +step "Publish Debian package" \ + node build/tfs/common/publish.js $VSCODE_QUALITY $PLATFORM_DEB package $DEB_FILENAME $VERSION true $DEB_PATH + +RPM_FILENAME="$(ls $REPO/.build/linux/rpm/$RPM_ARCH/ | grep .rpm)" +RPM_PATH="$REPO/.build/linux/rpm/$RPM_ARCH/$RPM_FILENAME" + +step "Publish RPM package" \ + node build/tfs/common/publish.js $VSCODE_QUALITY $PLATFORM_RPM package $RPM_FILENAME $VERSION true $RPM_PATH + +if [ -z "$VSCODE_QUALITY" ]; then + echo "VSCODE_QUALITY is not set, skipping repo package publish" +else + if [ "$BUILD_SOURCEBRANCH" = "master" ] || [ "$BUILD_SOURCEBRANCH" = "refs/heads/master" ]; then + if [[ $BUILD_QUEUEDBY = *"Project Collection Service Accounts"* || $BUILD_QUEUEDBY = *"Microsoft.VisualStudio.Services.TFS"* ]]; then + # Get necessary information + pushd $REPO && COMMIT_HASH=$(git rev-parse HEAD) && popd + PACKAGE_NAME="$(ls $REPO/.build/linux/deb/$DEB_ARCH/deb/ | sed -e 's/_.*//g')" + DEB_URL="https://az764295.vo.msecnd.net/$VSCODE_QUALITY/$COMMIT_HASH/$DEB_FILENAME" + RPM_URL="https://az764295.vo.msecnd.net/$VSCODE_QUALITY/$COMMIT_HASH/$RPM_FILENAME" + PACKAGE_VERSION="$(ls $REPO/.build/linux/deb/$DEB_ARCH/deb/ | sed -e 's/code-[a-z]*_//g' -e 's/\_.*$//g')" + # Write config files needed by API, use eval to force environment variable expansion + DIRNAME=$(dirname $(readlink -f $0)) + pushd $DIRNAME + # Submit to apt repo + if [ "$DEB_ARCH" = "amd64" ]; then + eval echo '{ \"server\": \"azure-apt-cat.cloudapp.net\", \"protocol\": \"https\", \"port\": \"443\", \"repositoryId\": \"58a4adf642421134a1a48d1a\", \"username\": \"$LINUX_REPO_USERNAME\", \"password\": \"$LINUX_REPO_PASSWORD\" }' > apt-config.json + eval echo '{ \"name\": \"$PACKAGE_NAME\", \"version\": \"$PACKAGE_VERSION\", \"repositoryId\": \"58a4adf642421134a1a48d1a\", \"sourceUrl\": \"$DEB_URL\" }' > apt-addpkg.json + echo "Submitting apt-addpkg.json:" + cat apt-addpkg.json + + step "Publish to repositories" \ + ./repoapi_client.sh -config apt-config.json -addpkg apt-addpkg.json + fi + # Submit to yum repo (disabled as it's manual until signing is automated) + # eval echo '{ \"server\": \"azure-apt-cat.cloudapp.net\", \"protocol\": \"https\", \"port\": \"443\", \"repositoryId\": \"58a4ae3542421134a1a48d1b\", \"username\": \"$LINUX_REPO_USERNAME\", \"password\": \"$LINUX_REPO_PASSWORD\" }' > yum-config.json + # eval echo '{ \"name\": \"$PACKAGE_NAME\", \"version\": \"$PACKAGE_VERSION\", \"repositoryId\": \"58a4ae3542421134a1a48d1b\", \"sourceUrl\": \"$RPM_URL\" }' > yum-addpkg.json + # echo "Submitting yum-addpkg.json:" + # cat yum-addpkg.json + # ./repoapi_client.sh -config yum-config.json -addpkg yum-addpkg.json + popd + echo "To check repo publish status run ./repoapi_client.sh -config config.json -check " + fi + fi +fi diff --git a/build/tfs/linux/smoketest.sh b/build/tfs/linux/smoketest.sh new file mode 100644 index 00000000000..5edac58188e --- /dev/null +++ b/build/tfs/linux/smoketest.sh @@ -0,0 +1,35 @@ +#!/bin/bash +set -e + +. ./scripts/env.sh +. ./build/tfs/common/common.sh + +export ARCH="$1" +VSO_PAT="$2" + +echo "machine monacotools.visualstudio.com password $VSO_PAT" > ~/.netrc + +step "Install dependencies" \ + npm install --arch=$ARCH --unsafe-perm + +step "Mix in repository from vscode-distro" \ + npm run gulp -- mixin + +step "Get Electron" \ + npm run gulp -- "electron-$ARCH" + +step "Install distro dependencies" \ + node build/tfs/common/installDistro.js --arch=$ARCH + +step "Build minified" \ + npm run gulp -- --max_old_space_size=4096 "vscode-linux-$ARCH-min" + +step "Run unit tests" \ + ./scripts/test.sh --xvfb --build --reporter dot + +step "Run smoke test" \ + pushd test/smoke + npm install + npm run compile + node src/main.js --latest "$AGENT_BUILDDIRECTORY/VSCode-linux-ia32/code-insiders" + popd \ No newline at end of file -- GitLab From fd094e3b3043862c4ff3bc6ad9118cae49631856 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 14 Jun 2017 10:57:50 +0200 Subject: [PATCH 0799/1347] Added necessary mixin password arg. --- build/tfs/linux/smoketest.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/build/tfs/linux/smoketest.sh b/build/tfs/linux/smoketest.sh index 5edac58188e..aff1074d373 100644 --- a/build/tfs/linux/smoketest.sh +++ b/build/tfs/linux/smoketest.sh @@ -5,7 +5,8 @@ set -e . ./build/tfs/common/common.sh export ARCH="$1" -VSO_PAT="$2" +export VSCODE_MIXIN_PASSWORD="$2" +VSO_PAT="$3" echo "machine monacotools.visualstudio.com password $VSO_PAT" > ~/.netrc -- GitLab From 40e9bf650ea9b39bf720f7ad17ada96b6b3718f5 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 14 Jun 2017 11:10:46 +0200 Subject: [PATCH 0800/1347] Added smoke test build script for Windows. --- build/tfs/win32/smoketest.ps1 | 54 +++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 build/tfs/win32/smoketest.ps1 diff --git a/build/tfs/win32/smoketest.ps1 b/build/tfs/win32/smoketest.ps1 new file mode 100644 index 00000000000..7658bbbd866 --- /dev/null +++ b/build/tfs/win32/smoketest.ps1 @@ -0,0 +1,54 @@ +Param( + [string]$arch, + [string]$mixinPassword, + [string]$vsoPAT +) + +. .\scripts\env.ps1 +. .\build\tfs\win32\lib.ps1 + +# Create a _netrc file to download distro dependencies +# In order to get _netrc to work, we need a HOME variable setup +$env:HOME=$env:USERPROFILE +"machine monacotools.visualstudio.com password ${vsoPAT}" | Out-File "$env:USERPROFILE\_netrc" -Encoding ASCII + +# Set the right architecture +$env:npm_config_arch="$arch" + +step "Install dependencies" { + exec { & npm install } +} + +$env:VSCODE_MIXIN_PASSWORD = $mixinPassword +step "Mix in repository from vscode-distro" { + exec { & npm run gulp -- mixin } +} + +step "Get Electron" { + exec { & npm run gulp -- "electron-$global:arch" } +} + +step "Install distro dependencies" { + exec { & node build\tfs\common\installDistro.js } +} + +step "Build minified" { + exec { & npm run gulp -- --max_old_space_size=4096 "vscode-win32-$global:arch-min" } +} + +step "Run unit tests" { + exec { & .\scripts\test.bat --build --reporter dot } +} + +# step "Run integration tests" { +# exec { & .\scripts\test-integration.bat } +# } + +step "Run smoke test" { + exec { & Push-Location test\smoke } + exec { & npm install; npm run compile } + exec { & node src/main.js --latest "$AGENT_BUILDDIRECTORY\VSCode-win32-$arch\Code - Insiders.exe" } + exec { & Pop-Location } +} + +done \ No newline at end of file -- GitLab From 340ef7fac2294f7bc6873c8270ce04422dcce9e6 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 14 Jun 2017 11:16:44 +0200 Subject: [PATCH 0801/1347] chmod +x --- build/tfs/linux/release.sh | 0 1 file changed, 0 insertions(+), 0 deletions(-) mode change 100644 => 100755 build/tfs/linux/release.sh diff --git a/build/tfs/linux/release.sh b/build/tfs/linux/release.sh old mode 100644 new mode 100755 -- GitLab From 181c346a4fe5c99a8510a8a1fed57489ee18a859 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 14 Jun 2017 11:40:41 +0200 Subject: [PATCH 0802/1347] Updated win32 smoketest variable references. --- build/tfs/win32/smoketest.ps1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/tfs/win32/smoketest.ps1 b/build/tfs/win32/smoketest.ps1 index 7658bbbd866..8a3a2dcfcb8 100644 --- a/build/tfs/win32/smoketest.ps1 +++ b/build/tfs/win32/smoketest.ps1 @@ -47,7 +47,7 @@ step "Run unit tests" { step "Run smoke test" { exec { & Push-Location test\smoke } exec { & npm install; npm run compile } - exec { & node src/main.js --latest "$AGENT_BUILDDIRECTORY\VSCode-win32-$arch\Code - Insiders.exe" } + exec { & node src/main.js --latest "$env:AGENT_BUILDDIRECTORY\VSCode-win32-$global:arch\Code - Insiders.exe" } exec { & Pop-Location } } -- GitLab From cae242f7145a5584bb8b8579f70e38168e1bb7c5 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Wed, 14 Jun 2017 12:00:39 +0200 Subject: [PATCH 0803/1347] fix linux build? --- build/tfs/linux/release.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/build/tfs/linux/release.sh b/build/tfs/linux/release.sh index 500622a47d4..40d68aee73f 100755 --- a/build/tfs/linux/release.sh +++ b/build/tfs/linux/release.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash . ./scripts/env.sh . ./build/tfs/common/common.sh @@ -32,7 +32,7 @@ VERSION=$(node -p "require(\"$PACKAGEJSON\").version") rm -rf $ROOT/code-*.tar.* (cd $ROOT && \ step "Create tar.gz archive" \ - tar -czvf $TARBALL_PATH $BUILDNAME) + tar -czf $TARBALL_PATH $BUILDNAME) step "Publish tar.gz archive" \ node build/tfs/common/publish.js $VSCODE_QUALITY $PLATFORM_LINUX archive-unsigned $TARBALL_FILENAME $VERSION true $TARBALL_PATH -- GitLab From f8eb2fa3b85da6f1949887c757d916ebaa8e3094 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 14 Jun 2017 12:21:16 +0200 Subject: [PATCH 0804/1347] adopt IWorkspace2, implement proper workspaceContains, #28526 --- .../electron-browser/mainThreadWorkspace.ts | 4 ++-- src/vs/workbench/api/node/extHost.api.impl.ts | 2 +- src/vs/workbench/api/node/extHost.protocol.ts | 10 ++++++--- .../api/node/extHostExtensionService.ts | 13 ++++++------ src/vs/workbench/api/node/extHostWorkspace.ts | 19 +++++++++-------- .../electron-browser/extensionHost.ts | 4 ++-- src/vs/workbench/node/extensionHostMain.ts | 21 ++++++++++++------- .../configuration/node/configuration.ts | 19 +++++++---------- .../api/extHostWorkspace.test.ts | 6 +++--- 9 files changed, 52 insertions(+), 46 deletions(-) diff --git a/src/vs/workbench/api/electron-browser/mainThreadWorkspace.ts b/src/vs/workbench/api/electron-browser/mainThreadWorkspace.ts index f6fc31c91ef..1cde185a17d 100644 --- a/src/vs/workbench/api/electron-browser/mainThreadWorkspace.ts +++ b/src/vs/workbench/api/electron-browser/mainThreadWorkspace.ts @@ -42,8 +42,8 @@ export class MainThreadWorkspace extends MainThreadWorkspaceShape { // --- workspace --- - private _onDidChangeWorkspace(folders: URI[]): void { - this._proxy.$acceptWorkspaceData(folders); + private _onDidChangeWorkspace(): void { + this._proxy.$acceptWorkspaceData(this._contextService.getWorkspace2()); } // --- search --- diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index 9f3ed92538c..a77a4b4e1ca 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -91,7 +91,7 @@ export function createApiFactory( const extHostTerminalService = col.define(ExtHostContext.ExtHostTerminalService).set(new ExtHostTerminalService(threadService)); const extHostSCM = col.define(ExtHostContext.ExtHostSCM).set(new ExtHostSCM(threadService, extHostCommands)); const extHostTask = col.define(ExtHostContext.ExtHostTask).set(new ExtHostTask(threadService)); - const extHostWorkspace = col.define(ExtHostContext.ExtHostWorkspace).set(new ExtHostWorkspace(threadService, initData.workspace && [initData.workspace.resource])); + const extHostWorkspace = col.define(ExtHostContext.ExtHostWorkspace).set(new ExtHostWorkspace(threadService, initData.workspace)); col.define(ExtHostContext.ExtHostExtensionService).set(extensionService); col.finish(false, threadService); diff --git a/src/vs/workbench/api/node/extHost.protocol.ts b/src/vs/workbench/api/node/extHost.protocol.ts index 393e50579ff..c7f432d81bb 100644 --- a/src/vs/workbench/api/node/extHost.protocol.ts +++ b/src/vs/workbench/api/node/extHost.protocol.ts @@ -22,7 +22,6 @@ import { IExtensionDescription } from 'vs/platform/extensions/common/extensions' import { StatusbarAlignment as MainThreadStatusBarAlignment } from 'vs/platform/statusbar/common/statusbar'; import { ITelemetryInfo } from 'vs/platform/telemetry/common/telemetry'; import { ICommandHandlerDescription } from 'vs/platform/commands/common/commands'; -import { IWorkspace } from 'vs/platform/workspace/common/workspace'; import { IProgressOptions, IProgressStep } from 'vs/platform/progress/common/progress'; import * as editorCommon from 'vs/editor/common/editorCommon'; @@ -57,10 +56,15 @@ export interface IEnvironment { extensionTestsPath: string; } +export interface IWorkspaceData { + id: string; + roots: URI[]; +} + export interface IInitData { parentPid: number; environment: IEnvironment; - workspace: IWorkspace; + workspace: IWorkspaceData; extensions: IExtensionDescription[]; configuration: IWorkspaceConfigurationValues; telemetryInfo: ITelemetryInfo; @@ -405,7 +409,7 @@ export abstract class ExtHostTreeViewsShape { } export abstract class ExtHostWorkspaceShape { - $acceptWorkspaceData(folders: URI[]): void { throw ni(); } + $acceptWorkspaceData(workspace: IWorkspaceData): void { throw ni(); } } export abstract class ExtHostExtensionServiceShape { diff --git a/src/vs/workbench/api/node/extHostExtensionService.ts b/src/vs/workbench/api/node/extHostExtensionService.ts index aeb68c62eda..67acd239b02 100644 --- a/src/vs/workbench/api/node/extHostExtensionService.ts +++ b/src/vs/workbench/api/node/extHostExtensionService.ts @@ -15,8 +15,7 @@ import { ExtHostStorage } from 'vs/workbench/api/node/extHostStorage'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { createApiFactory, initializeExtensionApi } from 'vs/workbench/api/node/extHost.api.impl'; import { IThreadService } from 'vs/workbench/services/thread/common/threadService'; -import { IWorkspace } from 'vs/platform/workspace/common/workspace'; -import { MainContext, MainProcessExtensionServiceShape, IEnvironment, IInitData } from './extHost.protocol'; +import { MainContext, MainProcessExtensionServiceShape, IWorkspaceData, IEnvironment, IInitData } from './extHost.protocol'; import { createHash } from 'crypto'; const hasOwnProperty = Object.hasOwnProperty; @@ -103,13 +102,13 @@ class ExtensionMemento implements IExtensionMemento { class ExtensionStoragePath { - private readonly _workspace: IWorkspace; + private readonly _workspace: IWorkspaceData; private readonly _environment: IEnvironment; private readonly _ready: TPromise; private _value: string; - constructor(workspace: IWorkspace, environment: IEnvironment) { + constructor(workspace: IWorkspaceData, environment: IEnvironment) { this._workspace = workspace; this._environment = environment; this._ready = this._getOrCreateWorkspaceStoragePath().then(value => this._value = value); @@ -130,10 +129,10 @@ class ExtensionStoragePath { if (!this._workspace) { return TPromise.as(undefined); } - + // TODO@joh what to do with multiple roots? const storageName = createHash('md5') - .update(this._workspace.resource.fsPath) - .update(this._workspace.uid ? this._workspace.uid.toString() : '') + .update(this._workspace.roots[0].fsPath) + .update(this._workspace.id || '') .digest('hex'); const storagePath = join(this._environment.appSettingsHome, 'workspaceStorage', storageName); diff --git a/src/vs/workbench/api/node/extHostWorkspace.ts b/src/vs/workbench/api/node/extHostWorkspace.ts index 7ec394f6913..dff559112b7 100644 --- a/src/vs/workbench/api/node/extHostWorkspace.ts +++ b/src/vs/workbench/api/node/extHostWorkspace.ts @@ -12,7 +12,7 @@ import { IThreadService } from 'vs/workbench/services/thread/common/threadServic import { IResourceEdit } from 'vs/editor/common/services/bulkEdit'; import { TPromise } from 'vs/base/common/winjs.base'; import { fromRange, EndOfLine } from 'vs/workbench/api/node/extHostTypeConverters'; -import { ExtHostWorkspaceShape, MainContext, MainThreadWorkspaceShape } from './extHost.protocol'; +import { IWorkspaceData, ExtHostWorkspaceShape, MainContext, MainThreadWorkspaceShape } from './extHost.protocol'; import * as vscode from 'vscode'; export class ExtHostWorkspace extends ExtHostWorkspaceShape { @@ -20,18 +20,19 @@ export class ExtHostWorkspace extends ExtHostWorkspaceShape { private static _requestIdPool = 0; private readonly _proxy: MainThreadWorkspaceShape; - private _workspaceFolders: URI[]; + private _workspace: IWorkspaceData; - constructor(threadService: IThreadService, folders: URI[]) { + constructor(threadService: IThreadService, workspace: IWorkspaceData) { super(); this._proxy = threadService.get(MainContext.MainThreadWorkspace); - this._workspaceFolders = folders; + this._workspace = workspace; } // --- workspace --- getPath(): string { - return isFalsyOrEmpty(this._workspaceFolders) ? undefined : this._workspaceFolders[0].fsPath; + // TODO@Joh handle roots.length > 1 case + return this._workspace ? this._workspace.roots[0].fsPath : undefined; } getRelativePath(pathOrUri: string | vscode.Uri): string { @@ -47,11 +48,11 @@ export class ExtHostWorkspace extends ExtHostWorkspaceShape { return path; } - if (isFalsyOrEmpty(this._workspaceFolders)) { + if (!this._workspace || isFalsyOrEmpty(this._workspace.roots)) { return normalize(path); } - for (const { fsPath } of this._workspaceFolders) { + for (const { fsPath } of this._workspace.roots) { let result = relative(fsPath, path); if (!result || result.indexOf('..') === 0) { continue; @@ -62,9 +63,9 @@ export class ExtHostWorkspace extends ExtHostWorkspaceShape { return normalize(path); } - $acceptWorkspaceData(workspaceFolders: URI[]): void { + $acceptWorkspaceData(workspace: IWorkspaceData): void { //TODO@joh equality-check, emit event etc. - this._workspaceFolders = workspaceFolders; + this._workspace = workspace; } // --- search --- diff --git a/src/vs/workbench/electron-browser/extensionHost.ts b/src/vs/workbench/electron-browser/extensionHost.ts index 6b99c054bb7..fdf5531f05f 100644 --- a/src/vs/workbench/electron-browser/extensionHost.ts +++ b/src/vs/workbench/electron-browser/extensionHost.ts @@ -29,7 +29,7 @@ import { IMessagePassingProtocol } from 'vs/base/parts/ipc/common/ipc'; import { generateRandomPipeName, Protocol } from 'vs/base/parts/ipc/node/ipc.net'; import { createServer, Server } from 'net'; import Event, { Emitter } from 'vs/base/common/event'; -import { IInitData } from 'vs/workbench/api/node/extHost.protocol'; +import { IInitData, IWorkspaceData } from 'vs/workbench/api/node/extHost.protocol'; import { MainProcessExtensionService } from 'vs/workbench/api/electron-browser/mainThreadExtensionService'; import { IWorkspaceConfigurationService } from 'vs/workbench/services/configuration/common/configuration'; import { ICrashReporterService } from 'vs/workbench/services/crashReporter/common/crashReporterService'; @@ -259,7 +259,7 @@ export class ExtensionHostProcessWorker { enableProposedApiForAll: !this.environmentService.isBuilt || (!!this.environmentService.extensionDevelopmentPath && product.nameLong.indexOf('Insiders') >= 0), enableProposedApiFor: this.environmentService.args['enable-proposed-api'] || [] }, - workspace: this.contextService.getWorkspace(), + workspace: this.contextService.getWorkspace2(), extensions: extensionDescriptions, configuration: this.configurationService.values(), telemetryInfo diff --git a/src/vs/workbench/node/extensionHostMain.ts b/src/vs/workbench/node/extensionHostMain.ts index 7f4aa8b0094..5c361eb9b06 100644 --- a/src/vs/workbench/node/extensionHostMain.ts +++ b/src/vs/workbench/node/extensionHostMain.ts @@ -15,9 +15,8 @@ import { ExtHostThreadService } from 'vs/workbench/services/thread/common/extHos import { QueryType, ISearchQuery } from 'vs/platform/search/common/search'; import { DiskSearch } from 'vs/workbench/services/search/node/searchService'; import { RemoteTelemetryService } from 'vs/workbench/api/node/extHostTelemetry'; -import { IInitData, IEnvironment, MainContext } from 'vs/workbench/api/node/extHost.protocol'; +import { IInitData, IEnvironment, IWorkspaceData, MainContext } from 'vs/workbench/api/node/extHost.protocol'; import * as errors from 'vs/base/common/errors'; -import { IWorkspace } from "vs/platform/workspace/common/workspace"; const nativeExit = process.exit.bind(process); process.exit = function () { @@ -36,7 +35,7 @@ export class ExtensionHostMain { private _isTerminating: boolean = false; private _diskSearch: DiskSearch; - private _workspace: IWorkspace; + private _workspace: IWorkspaceData; private _environment: IEnvironment; private _extensionService: ExtHostExtensionService; @@ -101,11 +100,10 @@ export class ExtensionHostMain { } private handleWorkspaceContainsEagerExtensions(): TPromise { - if (!this._workspace || !this._workspace.resource) { + if (!this._workspace || this._workspace.roots.length === 0) { return TPromise.as(null); } - const folderPath = this._workspace.resource.fsPath; const desiredFilesMap: { [filename: string]: boolean; @@ -135,7 +133,7 @@ export class ExtensionHostMain { } const query: ISearchQuery = { - folderResources: [this._workspace.resource], + folderResources: this._workspace.roots, type: QueryType.File, maxResults: 1, includePattern: { [p]: true } @@ -143,7 +141,16 @@ export class ExtensionHostMain { return this._diskSearch.search(query).then(result => result.results.length ? p : undefined); } else { - return pfs.exists(join(folderPath, p)).then(exists => exists ? p : undefined); + // find exact path + return new TPromise(async resolve => { + for (const { fsPath } of this._workspace.roots) { + if (await pfs.exists(join(fsPath, p))) { + resolve(p); + return; + } + } + resolve(undefined); + }); } }); diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index f449677e865..318ffc68d59 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -46,17 +46,12 @@ type IWorkspaceFoldersConfiguration = { [rootFolder: string]: { folders: string[ class Workspace implements IWorkspace2 { - constructor(readonly id: string, private _roots: URI[]) { + constructor( + public readonly id: string, + public roots: URI[] + ) { + // } - - get roots(): URI[] { - return this._roots; - } - - setRoots(roots: URI[]): void { - this._roots = roots; - } - } export class WorkspaceConfigurationService extends Disposable implements IWorkspaceContextService, IWorkspaceConfigurationService { @@ -130,7 +125,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp // Find changes const changed = !equals(this.workspace.roots, configuredFolders, (r1, r2) => r1.toString() === r2.toString()); - this.workspace.setRoots(configuredFolders); + this.workspace.roots = configuredFolders; if (notify && changed) { this._onDidChangeWorkspaceRoots.fire(configuredFolders); @@ -426,4 +421,4 @@ function resolveStat(resource: URI): TPromise { } }); }); -} \ No newline at end of file +} diff --git a/src/vs/workbench/test/electron-browser/api/extHostWorkspace.test.ts b/src/vs/workbench/test/electron-browser/api/extHostWorkspace.test.ts index 36430d52357..c66640c2bd7 100644 --- a/src/vs/workbench/test/electron-browser/api/extHostWorkspace.test.ts +++ b/src/vs/workbench/test/electron-browser/api/extHostWorkspace.test.ts @@ -14,7 +14,7 @@ suite('ExtHostWorkspace', function () { test('asRelativePath', function () { - const ws = new ExtHostWorkspace(new TestThreadService(), [URI.file('/Coding/Applications/NewsWoWBot')]); + const ws = new ExtHostWorkspace(new TestThreadService(), { id: 'foo', roots: [URI.file('/Coding/Applications/NewsWoWBot')] }); assert.equal(ws.getRelativePath('/Coding/Applications/NewsWoWBot/bernd/das/brot'), 'bernd/das/brot'); assert.equal(ws.getRelativePath('/Apps/DartPubCache/hosted/pub.dartlang.org/convert-2.0.1/lib/src/hex.dart'), @@ -28,7 +28,7 @@ suite('ExtHostWorkspace', function () { test('asRelativePath, same paths, #11402', function () { const root = '/home/aeschli/workspaces/samples/docker'; const input = '/home/aeschli/workspaces/samples/docker'; - const ws = new ExtHostWorkspace(new TestThreadService(), [URI.file(root)]); + const ws = new ExtHostWorkspace(new TestThreadService(), { id: 'foo', roots: [URI.file(root)] }); assert.equal(ws.getRelativePath(input), input); @@ -43,7 +43,7 @@ suite('ExtHostWorkspace', function () { }); test('asRelativePath, multiple folders', function () { - const ws = new ExtHostWorkspace(new TestThreadService(), [URI.file('/Coding/One'), URI.file('/Coding/Two')]); + const ws = new ExtHostWorkspace(new TestThreadService(), { id: 'foo', roots: [URI.file('/Coding/One'), URI.file('/Coding/Two')] }); assert.equal(ws.getRelativePath('/Coding/One/file.txt'), 'file.txt'); assert.equal(ws.getRelativePath('/Coding/Two/files/out.txt'), 'files/out.txt'); assert.equal(ws.getRelativePath('/Coding/Two2/files/out.txt'), '/Coding/Two2/files/out.txt'); -- GitLab From 5000246497bb4f0266299335b40ac4b49d77e237 Mon Sep 17 00:00:00 2001 From: Cristian Hosu Date: Wed, 14 Jun 2017 13:30:26 +0300 Subject: [PATCH 0805/1347] #22622 - removed ScollbarVisibility reference --- src/vs/workbench/parts/debug/electron-browser/debugHover.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts index 58f65f88f01..946fe4db939 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts @@ -22,7 +22,6 @@ import { Expression } from 'vs/workbench/parts/debug/common/debugModel'; import { VariablesRenderer, renderExpressionValue, VariablesDataSource } from 'vs/workbench/parts/debug/electron-browser/debugViewer'; import { IListService } from 'vs/platform/list/browser/listService'; import { DomScrollableElement } from 'vs/base/browser/ui/scrollbar/scrollableElement'; -import { ScrollbarVisibility } from 'vs/base/common/scrollable'; import { attachListStyler, attachStylerCallback } from 'vs/platform/theme/common/styler'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { editorHoverBackground, editorHoverBorder } from 'vs/platform/theme/common/colorRegistry'; @@ -63,7 +62,7 @@ export class DebugHoverWidget implements IContentWidget { this.valueContainer = $('.value'); this.valueContainer.tabIndex = 0; this.valueContainer.setAttribute('role', 'tooltip'); - this.scrollbar = new DomScrollableElement(this.valueContainer, { canUseTranslate3d: false, horizontal: ScrollbarVisibility.Auto, vertical: ScrollbarVisibility.Auto }); + this.scrollbar = new DomScrollableElement(this.valueContainer, { canUseTranslate3d: false }); this.domNode.appendChild(this.scrollbar.getDomNode()); this.toDispose.push(this.scrollbar); -- GitLab From 6b0b56e34552224f90a47d2cecc888c282061bfc Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 14 Jun 2017 12:50:21 +0200 Subject: [PATCH 0806/1347] first read basename, then full filepath --- .../contrib/referenceSearch/browser/referencesModel.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vs/editor/contrib/referenceSearch/browser/referencesModel.ts b/src/vs/editor/contrib/referenceSearch/browser/referencesModel.ts index 4ddacbe9216..06821595584 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referencesModel.ts +++ b/src/vs/editor/contrib/referenceSearch/browser/referencesModel.ts @@ -66,7 +66,7 @@ export class OneReference { public getAriaMessage(): string { return localize( 'aria.oneReference', "symbol in {0} on line {1} at column {2}", - this.uri.fsPath, this.range.startLineNumber, this.range.startColumn + basename(this.uri.fsPath), this.range.startLineNumber, this.range.startColumn ); } } @@ -154,9 +154,9 @@ export class FileReferences implements IDisposable { getAriaMessage(): string { const len = this.children.length; if (len === 1) { - return localize('aria.fileReferences.1', "1 symbol in {0}", this.uri.fsPath); + return localize('aria.fileReferences.1', "1 symbol in {0}, full path {1}", basename(this.uri.fsPath), this.uri.fsPath); } else { - return localize('aria.fileReferences.N', "{0} symbols in {1}", len, this.uri.fsPath); + return localize('aria.fileReferences.N', "{0} symbols in {1}, full path {2}", len, basename(this.uri.fsPath), this.uri.fsPath); } } -- GitLab From 5b6f2fa6013f4be14e9d620205d28ea54c33d650 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 14 Jun 2017 14:06:42 +0200 Subject: [PATCH 0807/1347] Added explanation where to look for test data. --- test/smoke/README.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/test/smoke/README.md b/test/smoke/README.md index 947fb43969a..1c9df539b8e 100644 --- a/test/smoke/README.md +++ b/test/smoke/README.md @@ -11,6 +11,9 @@ If you want to include 'Data Migration' area tests use `npm test -- --latest pa * `./areas/` folder contains a `.ts` file per each area of the document. E.g. `'Search'` area goes under `'search.ts'`. Every area file contains a list of methods with the name that represents the action that can be performed in the corresponding test. This reduces the amount of test suite code and means that if the UI changes, the fix need only be applied in one place. The name of the method reflects the action the tester would do if he would perform the test manually. See [Selenium Page Objects Wiki](https://github.com/SeleniumHQ/selenium/wiki/PageObjects) and [Selenium Bot Style Tests Wiki](https://github.com/SeleniumHQ/selenium/wiki/Bot-Style-Tests) for a good explanation of the implementation. Every smoke test area contains methods that are used in a bot-style approach in `main.ts`. * `./spectron/` wraps the Spectron, with WebDriverIO API wrapped in `client.ts` and instance of Spectron Application is wrapped in `application.ts`. +* `./test_data/` folder contains temporary data used by smoke test (cloned express repository, temporary user-data-dir/extensions-dir). +* `./test_data/screenshots` has action screenshots captured by a smoke test when performing actions during runtime. Screenshots are split in folders per each test. + # Adding new area To contribute a new smoke test area, add `${area}.ts` file under `./areas/`. All related tests to the area should go to the alike named file under `./tests/${area}.ts`. This has to follow the bot-style approach described in the links mentioned above. Methods should be calling WebDriverIO API through `SpectronClient` class. If there is no existing WebDriverIO method, add it to the class. -- GitLab From a2107d103a77307c3317a320cfbb94f6ec7a76f7 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 14 Jun 2017 15:12:23 +0200 Subject: [PATCH 0808/1347] remove aria.alert, bring back aria-provider, set isAccessible #17245 --- .../referenceSearch/browser/referencesWidget.ts | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) diff --git a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts index a0603d8f948..955ce894d60 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts +++ b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts @@ -6,7 +6,6 @@ import 'vs/css!./referencesWidget'; import * as nls from 'vs/nls'; -import { alert } from 'vs/base/browser/ui/aria/aria'; import { onUnexpectedError } from 'vs/base/common/errors'; import { getPathLabel } from 'vs/base/common/labels'; import Event, { Emitter } from 'vs/base/common/event'; @@ -589,7 +588,7 @@ export class ReferenceWidget extends PeekViewWidget { private _instantiationService: IInstantiationService, private _environmentService: IEnvironmentService ) { - super(editor, { showFrame: false, showArrow: true, isResizeable: true }); + super(editor, { showFrame: false, showArrow: true, isResizeable: true, isAccessible: true }); this._applyTheme(_themeService.getTheme()); this._callOnDispose.push(_themeService.onThemeChange(this._applyTheme.bind(this))); @@ -690,8 +689,7 @@ export class ReferenceWidget extends PeekViewWidget { dataSource: this._instantiationService.createInstance(DataSource), renderer: this._instantiationService.createInstance(Renderer, this.editor), controller: new Controller(), - // TODO@{Joh,Ben} make this work with the embedded tree - // accessibilityProvider: new AriaProvider() + accessibilityProvider: new AriaProvider() }; var options = { @@ -763,17 +761,6 @@ export class ReferenceWidget extends PeekViewWidget { // listen on model changes this._disposeOnNewModel.push(this._model.onDidChangeReferenceRange(reference => this._tree.refresh(reference))); - // listen on selection and focus - this._disposeOnNewModel.push(this._tree.addListener(Controller.Events.FOCUSED, (element) => { - if (element instanceof OneReference) { - this._revealReference(element); - this._onDidSelectReference.fire({ element, kind: 'show', source: 'tree' }); - } - if (element instanceof OneReference || element instanceof FileReferences) { - const msg = element.getAriaMessage(); - alert(msg); - } - })); this._disposeOnNewModel.push(this._tree.addListener(Controller.Events.SELECTED, (element: any) => { if (element instanceof OneReference) { this._onDidSelectReference.fire({ element, kind: 'goto', source: 'tree' }); -- GitLab From 09e22b8542070f492ffd87add72a7e8a64b56ed0 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Wed, 14 Jun 2017 15:16:25 +0200 Subject: [PATCH 0809/1347] fixes #27367 --- extensions/git/src/commands.ts | 6 +++--- extensions/git/src/git.ts | 8 ++------ extensions/git/src/model.ts | 21 ++++++++++++++++----- 3 files changed, 21 insertions(+), 14 deletions(-) diff --git a/extensions/git/src/commands.ts b/extensions/git/src/commands.ts index eed354dd8a4..127544276ab 100644 --- a/extensions/git/src/commands.ts +++ b/extensions/git/src/commands.ts @@ -774,7 +774,7 @@ export class CommandCenter { return; } - await this.model.pull(true); + await this.model.pullWithRebase(); } @command('git.push') @@ -812,7 +812,7 @@ export class CommandCenter { return; } - this.model.push(pick.label, branchName); + this.model.pushTo(pick.label, branchName); } @command('git.sync') @@ -860,7 +860,7 @@ export class CommandCenter { return; } - await this.model.push(choice, branchName, { setUpstream: true }); + await this.model.pushTo(choice, branchName, true); } @command('git.showOutput') diff --git a/extensions/git/src/git.ts b/extensions/git/src/git.ts index 9ef482def93..ad023efdf6e 100644 --- a/extensions/git/src/git.ts +++ b/extensions/git/src/git.ts @@ -21,10 +21,6 @@ export interface IGit { version: string; } -export interface PushOptions { - setUpstream?: boolean; -} - export interface IFileStatus { x: string; y: string; @@ -762,10 +758,10 @@ export class Repository { } } - async push(remote?: string, name?: string, options?: PushOptions): Promise { + async push(remote?: string, name?: string, setUpstream: boolean = false): Promise { const args = ['push']; - if (options && options.setUpstream) { + if (setUpstream) { args.push('-u'); } diff --git a/extensions/git/src/model.ts b/extensions/git/src/model.ts index aba4a4251d6..56479c7121c 100644 --- a/extensions/git/src/model.ts +++ b/extensions/git/src/model.ts @@ -6,7 +6,7 @@ 'use strict'; import { Uri, Command, EventEmitter, Event, SourceControlResourceState, SourceControlResourceDecorations, Disposable, ProgressLocation, window, workspace } from 'vscode'; -import { Git, Repository, Ref, Branch, Remote, PushOptions, Commit, GitErrorCodes } from './git'; +import { Git, Repository, Ref, Branch, Remote, Commit, GitErrorCodes } from './git'; import { anyEvent, eventToPromise, filterEvent, EmptyDisposable, combinedDisposable, dispose } from './util'; import { memoize, throttle, debounce } from './decorators'; import * as path from 'path'; @@ -479,12 +479,23 @@ export class Model implements Disposable { } } - async pull(rebase?: boolean): Promise { - await this.run(Operation.Pull, () => this.repository.pull(rebase)); + @throttle + async pull(): Promise { + await this.run(Operation.Pull, () => this.repository.pull()); + } + + @throttle + async pullWithRebase(): Promise { + await this.run(Operation.Pull, () => this.repository.pull(true)); + } + + @throttle + async push(): Promise { + await this.run(Operation.Push, () => this.repository.push()); } - async push(remote?: string, name?: string, options?: PushOptions): Promise { - await this.run(Operation.Push, () => this.repository.push(remote, name, options)); + async pushTo(remote?: string, name?: string, setUpstream: boolean = false): Promise { + await this.run(Operation.Push, () => this.repository.push(remote, name, setUpstream)); } @throttle -- GitLab From e7f7f423a5fe3680fba6bed5f5e2b78d99037f4b Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Wed, 14 Jun 2017 15:07:17 +0200 Subject: [PATCH 0810/1347] Border color not working. Fixes #28377 --- src/vs/editor/browser/services/codeEditorServiceImpl.ts | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/src/vs/editor/browser/services/codeEditorServiceImpl.ts b/src/vs/editor/browser/services/codeEditorServiceImpl.ts index eaf57c98d5d..f36e32b73fa 100644 --- a/src/vs/editor/browser/services/codeEditorServiceImpl.ts +++ b/src/vs/editor/browser/services/codeEditorServiceImpl.ts @@ -344,9 +344,7 @@ class DecorationCSSRules { } let cssTextArr: string[] = []; this.collectCSSText(opts, ['backgroundColor'], cssTextArr); - if (this.collectCSSText(opts, ['outline', 'outlineColor'], cssTextArr)) { - this.collectCSSText(opts, ['outlineStyle', 'outlineWidth'], cssTextArr); - } + this.collectCSSText(opts, ['outline', 'outlineColor', 'outlineStyle', 'outlineWidth'], cssTextArr); this.collectBorderSettingsCSSText(opts, cssTextArr); return cssTextArr.join(''); } @@ -418,8 +416,7 @@ class DecorationCSSRules { } private collectBorderSettingsCSSText(opts: any, cssTextArr: string[]): boolean { - if (this.collectCSSText(opts, ['border', 'borderColor'], cssTextArr)) { - this.collectCSSText(opts, ['borderRadius', 'borderSpacing', 'borderStyle', 'borderWidth'], cssTextArr); + if (this.collectCSSText(opts, ['border', 'borderColor', 'borderRadius', 'borderSpacing', 'borderStyle', 'borderWidth'], cssTextArr)) { cssTextArr.push(strings.format('box-sizing: border-box;')); return true; } @@ -444,7 +441,7 @@ class DecorationCSSRules { if (color) { return color.toString(); } - return void 0; + return 'transparent'; } return value; } -- GitLab From 555900bee9058d9aca528ffefb1fb5ea70890434 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Wed, 14 Jun 2017 15:48:52 +0200 Subject: [PATCH 0811/1347] tfs: call xvfb-run in linux smoke test --- build/tfs/linux/smoketest.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/tfs/linux/smoketest.sh b/build/tfs/linux/smoketest.sh index aff1074d373..70ceb3e9d7a 100644 --- a/build/tfs/linux/smoketest.sh +++ b/build/tfs/linux/smoketest.sh @@ -32,5 +32,5 @@ step "Run smoke test" \ pushd test/smoke npm install npm run compile - node src/main.js --latest "$AGENT_BUILDDIRECTORY/VSCode-linux-ia32/code-insiders" + xvfb-run -a node src/main.js --latest "$AGENT_BUILDDIRECTORY/VSCode-linux-ia32/code-insiders" popd \ No newline at end of file -- GitLab From 3bf3f69a08209bedac44dffdc05a720e16e7fefd Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 14 Jun 2017 15:53:13 +0200 Subject: [PATCH 0812/1347] multiroot - get rid of workspace.uid (only used for local storage) --- .../browser/standalone/simpleServices.ts | 5 +- .../platform/storage/common/storageService.ts | 15 +-- .../storage/test/storageService.test.ts | 7 +- src/vs/platform/workspace/common/workspace.ts | 15 +-- .../workspace/test/common/testWorkspace.ts | 1 - src/vs/workbench/electron-browser/main.ts | 125 +++++++++++------- src/vs/workbench/electron-browser/shell.ts | 22 +-- .../configuration/node/configuration.ts | 2 +- .../workbench/test/workbenchTestServices.ts | 5 +- 9 files changed, 101 insertions(+), 96 deletions(-) diff --git a/src/vs/editor/browser/standalone/simpleServices.ts b/src/vs/editor/browser/standalone/simpleServices.ts index c063ec34f7b..7d6d9ca4fa2 100644 --- a/src/vs/editor/browser/standalone/simpleServices.ts +++ b/src/vs/editor/browser/standalone/simpleServices.ts @@ -37,6 +37,7 @@ import { ResolvedKeybinding, Keybinding, createKeybinding, SimpleKeybinding } fr import { ResolvedKeybindingItem } from 'vs/platform/keybinding/common/resolvedKeybindingItem'; import { OS } from 'vs/base/common/platform'; import { IRange } from 'vs/editor/common/core/range'; +import { generateUuid } from "vs/base/common/uuid"; export class SimpleEditor implements IEditor { @@ -499,9 +500,11 @@ export class SimpleWorkspaceContextService implements IWorkspaceContextService { public readonly onDidChangeWorkspaceRoots: Event = this._onDidChangeWorkspaceRoots.event; private readonly folders: URI[]; + private readonly id: string; constructor(private workspace?: Workspace) { this.folders = workspace ? [workspace.resource] : []; + this.id = generateUuid(); } public getFolders(): URI[] { @@ -513,7 +516,7 @@ export class SimpleWorkspaceContextService implements IWorkspaceContextService { } public getWorkspace2(): IWorkspace2 { - return this.workspace ? { id: `${this.workspace.uid}`, roots: [this.workspace.resource] } : void 0; + return this.workspace ? { id: `${this.id}`, roots: [this.workspace.resource] } : void 0; } public hasWorkspace(): boolean { diff --git a/src/vs/platform/storage/common/storageService.ts b/src/vs/platform/storage/common/storageService.ts index 82952ee5dbd..83049e9736f 100644 --- a/src/vs/platform/storage/common/storageService.ts +++ b/src/vs/platform/storage/common/storageService.ts @@ -23,7 +23,6 @@ export interface IStorage { export interface IWorkspaceStorageIdentifier { resource: URI; uid?: number; - name?: string; } export class StorageService implements IStorageService { @@ -55,7 +54,7 @@ export class StorageService implements IStorageService { // Make sure to delete all workspace storage if the workspace has been recreated meanwhile // which is only possible if a UID property is provided that we can check on if (workspaceIdentifier && types.isNumber(workspaceIdentifier.uid)) { - this.cleanupWorkspaceScope(workspaceIdentifier.uid, workspaceIdentifier.name); + this.cleanupWorkspaceScope(workspaceIdentifier.uid); } } @@ -76,13 +75,13 @@ export class StorageService implements IStorageService { return `${strings.rtrim(workspaceIdStr, '/')}/`; } - private cleanupWorkspaceScope(workspaceId: number, workspaceName: string): void { + private cleanupWorkspaceScope(workspaceUid: number): void { // Get stored identifier from storage const id = this.getInteger(StorageService.WORKSPACE_IDENTIFIER, StorageScope.WORKSPACE); // If identifier differs, assume the workspace got recreated and thus clean all storage for this workspace - if (types.isNumber(id) && workspaceId !== id) { + if (types.isNumber(id) && workspaceUid !== id) { const keyPrefix = this.toStorageKey('', StorageScope.WORKSPACE); const toDelete: string[] = []; const length = this.workspaceStorage.length; @@ -99,10 +98,6 @@ export class StorageService implements IStorageService { } } - if (toDelete.length > 0) { - console.warn('Clearing previous version of local storage for workspace ', workspaceName); - } - // Run the delete toDelete.forEach((keyToDelete) => { this.workspaceStorage.removeItem(keyToDelete); @@ -110,8 +105,8 @@ export class StorageService implements IStorageService { } // Store workspace identifier now - if (workspaceId !== id) { - this.store(StorageService.WORKSPACE_IDENTIFIER, workspaceId, StorageScope.WORKSPACE); + if (workspaceUid !== id) { + this.store(StorageService.WORKSPACE_IDENTIFIER, workspaceUid, StorageScope.WORKSPACE); } } diff --git a/src/vs/platform/storage/test/storageService.test.ts b/src/vs/platform/storage/test/storageService.test.ts index 2be5dff0a16..2978c54f134 100644 --- a/src/vs/platform/storage/test/storageService.test.ts +++ b/src/vs/platform/storage/test/storageService.test.ts @@ -77,7 +77,9 @@ suite('Workbench StorageSevice', () => { test('StorageSevice cleans up when workspace changes', () => { let storageImpl = new InMemoryLocalStorage(); - let s = new StorageService(storageImpl, null, contextService.getWorkspace()); + let ws = contextService.getWorkspace(); + ws.uid = new Date().getTime(); + let s = new StorageService(storageImpl, null, ws); s.store('key1', 'foobar'); s.store('key2', 'something'); @@ -93,7 +95,8 @@ suite('Workbench StorageSevice', () => { assert.strictEqual(s.get('wkey1', StorageScope.WORKSPACE), 'foo'); assert.strictEqual(s.get('wkey2', StorageScope.WORKSPACE), 'foo2'); - let ws: any = new Workspace(TestWorkspace.resource, new Date().getTime() + 100, TestWorkspace.name); + ws = new Workspace(TestWorkspace.resource, TestWorkspace.name); + ws.uid = new Date().getTime() + 100; s = new StorageService(storageImpl, null, ws); assert.strictEqual(s.get('key1', StorageScope.GLOBAL), 'foobar'); diff --git a/src/vs/platform/workspace/common/workspace.ts b/src/vs/platform/workspace/common/workspace.ts index 8e1b08ed143..b133e6aea4e 100644 --- a/src/vs/platform/workspace/common/workspace.ts +++ b/src/vs/platform/workspace/common/workspace.ts @@ -65,13 +65,6 @@ export interface IWorkspace { */ resource: URI; - /** - * the unique identifier of the workspace. if the workspace is deleted and recreated - * the identifier also changes. this makes the uid more unique compared to the id which - * is just derived from the workspace name. - */ - uid?: number; - /** * the name of the workspace */ @@ -94,17 +87,13 @@ export interface IWorkspace2 { export class Workspace implements IWorkspace { - constructor(private _resource: URI, private _uid?: number, private _name?: string) { + constructor(private _resource: URI, private _name?: string) { } public get resource(): URI { return this._resource; } - public get uid(): number { - return this._uid; - } - public get name(): string { return this._name; } @@ -134,6 +123,6 @@ export class Workspace implements IWorkspace { } public toJSON() { - return { resource: this._resource, uid: this._uid, name: this._name }; + return { resource: this._resource, name: this._name }; } } \ No newline at end of file diff --git a/src/vs/platform/workspace/test/common/testWorkspace.ts b/src/vs/platform/workspace/test/common/testWorkspace.ts index 18926c9330d..4400e7544ea 100644 --- a/src/vs/platform/workspace/test/common/testWorkspace.ts +++ b/src/vs/platform/workspace/test/common/testWorkspace.ts @@ -8,6 +8,5 @@ import URI from 'vs/base/common/uri'; export const TestWorkspace = new Workspace( URI.file('C:\\testWorkspace'), - Date.now(), 'Test Workspace' ); diff --git a/src/vs/workbench/electron-browser/main.ts b/src/vs/workbench/electron-browser/main.ts index cf9c5e45db7..cf8ae033c6d 100644 --- a/src/vs/workbench/electron-browser/main.ts +++ b/src/vs/workbench/electron-browser/main.ts @@ -28,6 +28,9 @@ import { IInitData } from 'vs/workbench/services/timer/common/timerService'; import { TimerService } from 'vs/workbench/services/timer/node/timerService'; import { KeyboardMapperFactory } from "vs/workbench/services/keybinding/electron-browser/keybindingService"; import { IWindowConfiguration, IPath } from "vs/platform/windows/common/windows"; +import { IStorageService } from "vs/platform/storage/common/storage"; +import { IEnvironmentService } from "vs/platform/environment/common/environment"; +import { StorageService, inMemoryLocalStorageInstance, IWorkspaceStorageIdentifier } from "vs/platform/storage/common/storageService"; import { webFrame } from 'electron'; @@ -62,12 +65,8 @@ export function startup(configuration: IWindowConfiguration): TPromise { filesToDiff }; - // Resolve workspace - return getWorkspace(configuration.workspacePath).then(workspace => { - - // Open workbench - return openWorkbench(configuration, workspace, shellOptions); - }); + // Open workbench + return openWorkbench(configuration, shellOptions); } function toInputs(paths: IPath[], isUntitledFile?: boolean): IResourceInput[] { @@ -95,12 +94,53 @@ function toInputs(paths: IPath[], isUntitledFile?: boolean): IResourceInput[] { }); } -function getWorkspace(workspacePath: string): TPromise { - if (!workspacePath) { +function openWorkbench(configuration: IWindowConfiguration, options: IOptions): TPromise { + return getWorkspace(configuration).then(workspace => { + const environmentService = new EnvironmentService(configuration, configuration.execPath); + const workspaceConfigurationService = new WorkspaceConfigurationService(environmentService, workspace); + const timerService = new TimerService((window).MonacoEnvironment.timers as IInitData, !workspaceConfigurationService.hasWorkspace()); + + return createStorageService(configuration, environmentService).then(storageService => { + + // Since the configuration service is one of the core services that is used in so many places, we initialize it + // right before startup of the workbench shell to have its data ready for consumers + return workspaceConfigurationService.initialize().then(() => { + timerService.beforeDOMContentLoaded = Date.now(); + + return domContentLoaded().then(() => { + timerService.afterDOMContentLoaded = Date.now(); + + // Open Shell + timerService.beforeWorkbenchOpen = Date.now(); + const shell = new WorkbenchShell(document.body, { + contextService: workspaceConfigurationService, + configurationService: workspaceConfigurationService, + environmentService, + timerService, + storageService + }, configuration, options); + shell.open(); + + // Inform user about loading issues from the loader + (self).require.config({ + onError: (err: any) => { + if (err.errorCode === 'load') { + shell.onUnexpectedError(loaderError(err)); + } + } + }); + }); + }); + }); + }); +} + +function getWorkspace(configuration: IWindowConfiguration): TPromise { + if (!configuration.workspacePath) { return TPromise.as(null); } - return realpath(workspacePath).then(realWorkspacePath => { + return realpath(configuration.workspacePath).then(realWorkspacePath => { // for some weird reason, node adds a trailing slash to UNC paths // we never ever want trailing slashes as our workspace path unless @@ -110,16 +150,13 @@ function getWorkspace(workspacePath: string): TPromise { realWorkspacePath = strings.rtrim(realWorkspacePath, paths.nativeSep); } + // update config + configuration.workspacePath = realWorkspacePath; + const workspaceResource = uri.file(realWorkspacePath); const folderName = path.basename(realWorkspacePath) || realWorkspacePath; - return stat(realWorkspacePath).then(folderStat => { - return new Workspace( - workspaceResource, - platform.isLinux ? folderStat.ino : folderStat.birthtime.getTime(), - folderName // On Linux, birthtime is ctime, so we cannot use it! We use the ino instead! - ); - }); + return new Workspace(workspaceResource, folderName); }, error => { errors.onUnexpectedError(error); @@ -127,38 +164,30 @@ function getWorkspace(workspacePath: string): TPromise { }); } -function openWorkbench(configuration: IWindowConfiguration, workspace: Workspace, options: IOptions): TPromise { - const environmentService = new EnvironmentService(configuration, configuration.execPath); - const workspaceConfigurationService = new WorkspaceConfigurationService(environmentService, workspace); - const timerService = new TimerService((window).MonacoEnvironment.timers as IInitData, !workspaceConfigurationService.hasWorkspace()); - - // Since the configuration service is one of the core services that is used in so many places, we initialize it - // right before startup of the workbench shell to have its data ready for consumers - return workspaceConfigurationService.initialize().then(() => { - timerService.beforeDOMContentLoaded = Date.now(); - - return domContentLoaded().then(() => { - timerService.afterDOMContentLoaded = Date.now(); - - // Open Shell - timerService.beforeWorkbenchOpen = Date.now(); - const shell = new WorkbenchShell(document.body, { - contextService: workspaceConfigurationService, - configurationService: workspaceConfigurationService, - environmentService, - timerService - }, configuration, options); - shell.open(); - - // Inform user about loading issues from the loader - (self).require.config({ - onError: (err: any) => { - if (err.errorCode === 'load') { - shell.onUnexpectedError(loaderError(err)); - } - } - }); - }); +function createStorageService(configuration: IWindowConfiguration, environmentService: IEnvironmentService): TPromise { + let workspaceStatPromise: TPromise = TPromise.as(null); + if (configuration.workspacePath) { + workspaceStatPromise = stat(configuration.workspacePath); + } + + return workspaceStatPromise.then(stat => { + let id: IWorkspaceStorageIdentifier; + if (stat) { + id = { resource: uri.file(configuration.workspacePath), uid: platform.isLinux ? stat.ino : stat.birthtime.getTime() }; + } else if (configuration.backupPath) { + // if we do not have a workspace open, we need to find another identifier for the window to store + // workspace UI state. if we have a backup path in the configuration we can use that because this + // will be a unique identifier per window that is stable between restarts as long as there are + // dirty files in the workspace. + // We use basename() to produce a short identifier, we do not need the full path. We use a custom + // scheme so that we can later distinguish these identifiers from the workspace one. + id = { resource: uri.from({ path: path.basename(configuration.backupPath), scheme: 'empty' }) }; + } + + const disableStorage = !!environmentService.extensionTestsPath; // never keep any state when running extension tests! + const storage = disableStorage ? inMemoryLocalStorageInstance : window.localStorage; + + return new StorageService(storage, storage, id); }); } diff --git a/src/vs/workbench/electron-browser/shell.ts b/src/vs/workbench/electron-browser/shell.ts index 141b3285c0a..015cc5f7bbd 100644 --- a/src/vs/workbench/electron-browser/shell.ts +++ b/src/vs/workbench/electron-browser/shell.ts @@ -21,7 +21,6 @@ import { SyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import pkg from 'vs/platform/node/package'; import { ContextViewService } from 'vs/platform/contextview/browser/contextViewService'; import { Workbench, IWorkbenchStartedInfo } from 'vs/workbench/electron-browser/workbench'; -import { StorageService, inMemoryLocalStorageInstance } from 'vs/platform/storage/common/storageService'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { NullTelemetryService, configurationTelemetry, loadExperiments, lifecycleTelemetry } from 'vs/platform/telemetry/common/telemetryUtils'; import { ITelemetryAppenderChannel, TelemetryAppenderClient } from 'vs/platform/telemetry/common/telemetryIpc'; @@ -89,8 +88,6 @@ import { IURLService } from 'vs/platform/url/common/url'; import { ExtensionHostProcessWorker } from 'vs/workbench/electron-browser/extensionHost'; import { ITimerService } from 'vs/workbench/services/timer/common/timerService'; import { remote, ipcRenderer as ipc } from 'electron'; -import URI from "vs/base/common/uri"; -import { basename } from "path"; import { ITextMateService } from 'vs/editor/node/textMate/textMateService'; import { MainProcessTextMateSyntax } from 'vs/editor/electron-browser/textMate/TMSyntax'; import { BareFontInfo } from 'vs/editor/common/config/fontInfo'; @@ -110,6 +107,7 @@ export interface ICoreServices { configurationService: IConfigurationService; environmentService: IEnvironmentService; timerService: ITimerService; + storageService: IStorageService; } const currentWindow = remote.getCurrentWindow(); @@ -155,6 +153,7 @@ export class WorkbenchShell { this.configurationService = services.configurationService; this.environmentService = services.environmentService; this.timerService = services.timerService; + this.storageService = services.storageService; this.toUnbind = []; this.previousErrorTime = 0; @@ -251,6 +250,7 @@ export class WorkbenchShell { serviceCollection.set(IConfigurationService, this.configurationService); serviceCollection.set(IEnvironmentService, this.environmentService); serviceCollection.set(ITimerService, this.timerService); + serviceCollection.set(IStorageService, this.storageService); const instantiationService: IInstantiationService = new InstantiationService(serviceCollection, true); @@ -273,22 +273,6 @@ export class WorkbenchShell { sharedProcess .done(client => client.registerChannel('choice', instantiationService.createInstance(ChoiceChannel))); - // Storage Sevice - let workspaceIdentifier = this.contextService.getWorkspace(); - if (!workspaceIdentifier && !!this.configuration.backupPath) { - // if we do not have a workspace open, we need to find another identifier for the window to store - // workspace UI state. if we have a backup path in the configuration we can use that because this - // will be a unique identifier per window that is stable between restarts as long as there are - // dirty files in the workspace. - // We use basename() to produce a short identifier, we do not need the full path. We use a custom - // scheme so that we can later distinguish these identifiers from the workspace one. - workspaceIdentifier = { resource: URI.from({ path: basename(this.configuration.backupPath), scheme: 'empty' }) }; - } - const disableStorage = !!this.environmentService.extensionTestsPath; // never keep any state when running extension tests! - const storage = disableStorage ? inMemoryLocalStorageInstance : window.localStorage; - this.storageService = new StorageService(storage, storage, workspaceIdentifier); - serviceCollection.set(IStorageService, this.storageService); - // Warm up font cache information before building up too many dom elements restoreFontInfo(this.storageService); readFontInfo(BareFontInfo.createFromRawSettings(this.configurationService.getConfiguration('editor'), browser.getZoomLevel())); diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index 318ffc68d59..27661ffa4cb 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -80,7 +80,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp constructor(private environmentService: IEnvironmentService, private singleRootWorkspace?: SingleRootWorkspace, private workspaceSettingsRootFolder: string = WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME) { super(); - this.workspace = singleRootWorkspace ? new Workspace(`${singleRootWorkspace.uid}`, [singleRootWorkspace.resource]) : null; + this.workspace = singleRootWorkspace ? new Workspace(singleRootWorkspace.resource.toString(), [singleRootWorkspace.resource]) : null; this.workspaceFilePathToConfiguration = Object.create(null); this.cachedConfig = new ConfigModel(null); diff --git a/src/vs/workbench/test/workbenchTestServices.ts b/src/vs/workbench/test/workbenchTestServices.ts index dc3c013b404..d38d290f463 100644 --- a/src/vs/workbench/test/workbenchTestServices.ts +++ b/src/vs/workbench/test/workbenchTestServices.ts @@ -53,6 +53,7 @@ import { IEnvironmentService } from 'vs/platform/environment/common/environment' import { IThemeService, ITheme, DARK } from 'vs/platform/theme/common/themeService'; import { Color } from 'vs/base/common/color'; import { isLinux } from 'vs/base/common/platform'; +import { generateUuid } from "vs/base/common/uuid"; export function createFileInput(instantiationService: IInstantiationService, resource: URI): FileEditorInput { return instantiationService.createInstance(FileEditorInput, resource, void 0); @@ -64,12 +65,14 @@ export class TestContextService implements IWorkspaceContextService { public _serviceBrand: any; private workspace: any; + private id: string; private options: any; private _onDidChangeWorkspaceRoots: Emitter; constructor(workspace: any = TestWorkspace, options: any = null) { this.workspace = workspace; + this.id = generateUuid(); this.options = options || Object.create(null); this._onDidChangeWorkspaceRoots = new Emitter(); } @@ -91,7 +94,7 @@ export class TestContextService implements IWorkspaceContextService { } public getWorkspace2(): IWorkspace2 { - return this.workspace ? { id: `${this.workspace.uid}`, roots: [this.workspace.resource] } : void 0; + return this.workspace ? { id: this.id, roots: [this.workspace.resource] } : void 0; } public setWorkspace(workspace: any): void { -- GitLab From 004cad592d7ac8ab2dc77bb7f39c4a829759df83 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 14 Jun 2017 15:56:06 +0200 Subject: [PATCH 0813/1347] also don't alert when command finished, #17245 --- .../contrib/referenceSearch/browser/referenceSearch.ts | 7 +------ src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.ts | 3 ++- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.ts b/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.ts index 6249277425f..805cdb2bddc 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.ts +++ b/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.ts @@ -5,7 +5,6 @@ 'use strict'; import * as nls from 'vs/nls'; -import { alert } from 'vs/base/browser/ui/aria/aria'; import { KeyCode, KeyMod } from 'vs/base/common/keyCodes'; import URI from 'vs/base/common/uri'; import { TPromise } from 'vs/base/common/winjs.base'; @@ -85,11 +84,7 @@ export class ReferenceAction extends EditorAction { } let range = editor.getSelection(); let model = editor.getModel(); - let references = provideReferences(model, range.getStartPosition()).then(references => { - const model = new ReferencesModel(references); - alert(model.getAriaMessage()); - return model; - }); + let references = provideReferences(model, range.getStartPosition()).then(references => new ReferencesModel(references)); controller.toggleWidget(range, references, defaultReferenceSearchOptions); } } diff --git a/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.ts b/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.ts index 97a76078bba..45e8d7a3e56 100644 --- a/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.ts +++ b/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.ts @@ -169,6 +169,7 @@ export abstract class PeekViewWidget extends ZoneWidget implements IPeekViewServ public setTitle(primaryHeading: string, secondaryHeading?: string): void { $(this._primaryHeading).safeInnerHtml(primaryHeading); + this._primaryHeading.setAttribute('aria-label', primaryHeading); if (secondaryHeading) { $(this._secondaryHeading).safeInnerHtml(secondaryHeading); } else { @@ -212,4 +213,4 @@ export abstract class PeekViewWidget extends ZoneWidget implements IPeekViewServ protected _doLayoutBody(heightInPixel: number, widthInPixel: number): void { this._bodyElement.style.height = strings.format('{0}px', heightInPixel); } -} \ No newline at end of file +} -- GitLab From 38f89523141b60e34911594b7da3d1a8a4eff1e9 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 14 Jun 2017 15:24:33 +0200 Subject: [PATCH 0814/1347] Do not use translate3d in scrollbars, use will-change for scrollbar sliders instead (Microsoft/monaco-editor#426) --- .../browser/ui/scrollbar/abstractScrollbar.ts | 17 +---------------- .../browser/ui/scrollbar/horizontalScrollbar.ts | 9 +-------- .../browser/ui/scrollbar/scrollableElement.ts | 5 ----- .../ui/scrollbar/scrollableElementOptions.ts | 6 ------ .../browser/ui/scrollbar/verticalScrollbar.ts | 9 +-------- .../editorScrollbar/editorScrollbar.ts | 4 +--- 6 files changed, 4 insertions(+), 46 deletions(-) diff --git a/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts b/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts index 7a8743cb62a..2798c774222 100644 --- a/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts +++ b/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts @@ -32,7 +32,6 @@ export interface ScrollbarHost { } export interface AbstractScrollbarOptions { - canUseTranslate3d: boolean; lazyRender: boolean; host: ScrollbarHost; scrollbarState: ScrollbarState; @@ -43,7 +42,6 @@ export interface AbstractScrollbarOptions { export abstract class AbstractScrollbar extends Widget { - protected _canUseTranslate3d: boolean; protected _host: ScrollbarHost; protected _scrollable: Scrollable; private _lazyRender: boolean; @@ -58,7 +56,6 @@ export abstract class AbstractScrollbar extends Widget { constructor(opts: AbstractScrollbarOptions) { super(); - this._canUseTranslate3d = opts.canUseTranslate3d; this._lazyRender = opts.lazyRender; this._host = opts.host; this._scrollable = opts.scrollable; @@ -98,6 +95,7 @@ export abstract class AbstractScrollbar extends Widget { this.slider.setLeft(left); this.slider.setWidth(width); this.slider.setHeight(height); + DomUtils.hintGPULayer(this.slider.domNode); this.domNode.domNode.appendChild(this.slider.domNode); @@ -111,11 +109,6 @@ export abstract class AbstractScrollbar extends Widget { // ----------------- Update state - public setCanUseTranslate3d(canUseTranslate3d: boolean): boolean { - this._canUseTranslate3d = canUseTranslate3d; - return true; - } - protected _onElementSize(visibleSize: number): boolean { if (this._scrollbarState.setVisibleSize(visibleSize)) { this._visibilityController.setIsNeeded(this._scrollbarState.isNeeded()); @@ -165,14 +158,6 @@ export abstract class AbstractScrollbar extends Widget { } this._shouldRender = false; - if (this._canUseTranslate3d) { - // Put the scrollbar in its own layer - this.domNode.setTransform('translate3d(0px, 0px, 0px)'); - } else { - this.domNode.setTransform(''); - DomUtils.hintGPULayer(this.domNode.domNode); - } - this._renderDomNode(this._scrollbarState.getRectangleLargeSize(), this._scrollbarState.getRectangleSmallSize()); this._updateSlider(this._scrollbarState.getSliderSize(), this._scrollbarState.getArrowSize() + this._scrollbarState.getSliderPosition()); } diff --git a/src/vs/base/browser/ui/scrollbar/horizontalScrollbar.ts b/src/vs/base/browser/ui/scrollbar/horizontalScrollbar.ts index 8e7e678f46f..f6da6af6bc3 100644 --- a/src/vs/base/browser/ui/scrollbar/horizontalScrollbar.ts +++ b/src/vs/base/browser/ui/scrollbar/horizontalScrollbar.ts @@ -16,7 +16,6 @@ export class HorizontalScrollbar extends AbstractScrollbar { constructor(scrollable: Scrollable, options: ScrollableElementResolvedOptions, host: ScrollbarHost) { super({ - canUseTranslate3d: options.canUseTranslate3d, lazyRender: options.lazyRender, host: host, scrollbarState: new ScrollbarState( @@ -61,13 +60,7 @@ export class HorizontalScrollbar extends AbstractScrollbar { protected _updateSlider(sliderSize: number, sliderPosition: number): void { this.slider.setWidth(sliderSize); - if (this._canUseTranslate3d) { - this.slider.setTransform('translate3d(' + sliderPosition + 'px, 0px, 0px)'); - this.slider.setLeft(0); - } else { - this.slider.setTransform(''); - this.slider.setLeft(sliderPosition); - } + this.slider.setLeft(sliderPosition); } protected _renderDomNode(largeSize: number, smallSize: number): void { diff --git a/src/vs/base/browser/ui/scrollbar/scrollableElement.ts b/src/vs/base/browser/ui/scrollbar/scrollableElement.ts index c07026b7f72..7bb7da0f01e 100644 --- a/src/vs/base/browser/ui/scrollbar/scrollableElement.ts +++ b/src/vs/base/browser/ui/scrollbar/scrollableElement.ts @@ -6,7 +6,6 @@ import 'vs/css!./media/scrollbars'; -import * as Browser from 'vs/base/browser/browser'; import * as DomUtils from 'vs/base/browser/dom'; import * as Platform from 'vs/base/common/platform'; import { StandardMouseWheelEvent, IMouseEvent } from 'vs/base/browser/mouseEvent'; @@ -188,9 +187,6 @@ export class ScrollableElement extends Widget { this._options.mouseWheelScrollSensitivity = massagedOptions.mouseWheelScrollSensitivity; this._setListeningToMouseWheel(this._options.handleMouseWheel); - this._shouldRender = this._horizontalScrollbar.setCanUseTranslate3d(massagedOptions.canUseTranslate3d) || this._shouldRender; - this._shouldRender = this._verticalScrollbar.setCanUseTranslate3d(massagedOptions.canUseTranslate3d) || this._shouldRender; - if (!this._options.lazyRender) { this._render(); } @@ -409,7 +405,6 @@ export class DomScrollableElement extends ScrollableElement { function resolveOptions(opts: ScrollableElementCreationOptions): ScrollableElementResolvedOptions { let result: ScrollableElementResolvedOptions = { - canUseTranslate3d: opts.canUseTranslate3d && Browser.supportsTranslate3d, lazyRender: (typeof opts.lazyRender !== 'undefined' ? opts.lazyRender : false), className: (typeof opts.className !== 'undefined' ? opts.className : ''), useShadows: (typeof opts.useShadows !== 'undefined' ? opts.useShadows : true), diff --git a/src/vs/base/browser/ui/scrollbar/scrollableElementOptions.ts b/src/vs/base/browser/ui/scrollbar/scrollableElementOptions.ts index 032e637d5b5..5485e4eb84b 100644 --- a/src/vs/base/browser/ui/scrollbar/scrollableElementOptions.ts +++ b/src/vs/base/browser/ui/scrollbar/scrollableElementOptions.ts @@ -7,10 +7,6 @@ import { ScrollbarVisibility } from 'vs/base/common/scrollable'; export interface ScrollableElementCreationOptions { - /** - * Allow scrollbar rendering to use translate3d. - */ - canUseTranslate3d: boolean; /** * The scrollable element should not do any DOM mutations until renderNow() is called. * Defaults to false. @@ -105,13 +101,11 @@ export interface ScrollableElementCreationOptions { } export interface ScrollableElementChangeOptions { - canUseTranslate3d: boolean; handleMouseWheel?: boolean; mouseWheelScrollSensitivity?: number; } export interface ScrollableElementResolvedOptions { - canUseTranslate3d: boolean; lazyRender: boolean; className: string; useShadows: boolean; diff --git a/src/vs/base/browser/ui/scrollbar/verticalScrollbar.ts b/src/vs/base/browser/ui/scrollbar/verticalScrollbar.ts index ce33b4164b4..94a6130d90e 100644 --- a/src/vs/base/browser/ui/scrollbar/verticalScrollbar.ts +++ b/src/vs/base/browser/ui/scrollbar/verticalScrollbar.ts @@ -16,7 +16,6 @@ export class VerticalScrollbar extends AbstractScrollbar { constructor(scrollable: Scrollable, options: ScrollableElementResolvedOptions, host: ScrollbarHost) { super({ - canUseTranslate3d: options.canUseTranslate3d, lazyRender: options.lazyRender, host: host, scrollbarState: new ScrollbarState( @@ -66,13 +65,7 @@ export class VerticalScrollbar extends AbstractScrollbar { protected _updateSlider(sliderSize: number, sliderPosition: number): void { this.slider.setHeight(sliderSize); - if (this._canUseTranslate3d) { - this.slider.setTransform('translate3d(0px, ' + sliderPosition + 'px, 0px)'); - this.slider.setTop(0); - } else { - this.slider.setTransform(''); - this.slider.setTop(sliderPosition); - } + this.slider.setTop(sliderPosition); } protected _renderDomNode(largeSize: number, smallSize: number): void { diff --git a/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.ts b/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.ts index a90d8f52d03..8ceb2845eb3 100644 --- a/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.ts +++ b/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.ts @@ -34,7 +34,6 @@ export class EditorScrollbar extends ViewPart { const configScrollbarOpts = editor.viewInfo.scrollbar; let scrollbarOptions: ScrollableElementCreationOptions = { - canUseTranslate3d: editor.canUseTranslate3d, listenOnDomNode: viewDomNode.domNode, className: 'editor-scrollable' + ' ' + getThemeTypeSelector(context.theme.type), useShadows: false, @@ -127,10 +126,9 @@ export class EditorScrollbar extends ViewPart { // --- begin event handlers public onConfigurationChanged(e: viewEvents.ViewConfigurationChangedEvent): boolean { - if (e.viewInfo || e.canUseTranslate3d) { + if (e.viewInfo) { const editor = this._context.configuration.editor; let newOpts: ScrollableElementChangeOptions = { - canUseTranslate3d: editor.canUseTranslate3d, handleMouseWheel: editor.viewInfo.scrollbar.handleMouseWheel, mouseWheelScrollSensitivity: editor.viewInfo.scrollbar.mouseWheelScrollSensitivity }; -- GitLab From fc6f092223296841ca13f66456d76efe31d32ddd Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 14 Jun 2017 15:31:38 +0200 Subject: [PATCH 0815/1347] Do not use translate3d in overview ruler, use will-change instead (Microsoft/monaco-editor#426) --- .../overviewRuler/decorationsOverviewRuler.ts | 5 ----- .../viewParts/overviewRuler/overviewRuler.ts | 5 ----- .../overviewRuler/overviewRulerImpl.ts | 18 +++--------------- 3 files changed, 3 insertions(+), 25 deletions(-) diff --git a/src/vs/editor/browser/viewParts/overviewRuler/decorationsOverviewRuler.ts b/src/vs/editor/browser/viewParts/overviewRuler/decorationsOverviewRuler.ts index 46c6d71d941..3c4f0a6c3ab 100644 --- a/src/vs/editor/browser/viewParts/overviewRuler/decorationsOverviewRuler.ts +++ b/src/vs/editor/browser/viewParts/overviewRuler/decorationsOverviewRuler.ts @@ -46,7 +46,6 @@ export class DecorationsOverviewRuler extends ViewPart { 'decorationsOverviewRuler', this._context.viewLayout.getScrollHeight(), this._context.configuration.editor.lineHeight, - this._context.configuration.editor.canUseTranslate3d, this._context.configuration.editor.pixelRatio, DecorationsOverviewRuler.MIN_DECORATION_HEIGHT, DecorationsOverviewRuler.MAX_DECORATION_HEIGHT, @@ -101,10 +100,6 @@ export class DecorationsOverviewRuler extends ViewPart { this._overviewRuler.setLineHeight(this._context.configuration.editor.lineHeight, false); } - if (e.canUseTranslate3d) { - this._overviewRuler.setCanUseTranslate3d(this._context.configuration.editor.canUseTranslate3d, false); - } - if (e.pixelRatio) { this._overviewRuler.setPixelRatio(this._context.configuration.editor.pixelRatio, false); } diff --git a/src/vs/editor/browser/viewParts/overviewRuler/overviewRuler.ts b/src/vs/editor/browser/viewParts/overviewRuler/overviewRuler.ts index 65c793de876..bb2b4ee58ce 100644 --- a/src/vs/editor/browser/viewParts/overviewRuler/overviewRuler.ts +++ b/src/vs/editor/browser/viewParts/overviewRuler/overviewRuler.ts @@ -25,7 +25,6 @@ export class OverviewRuler extends ViewEventHandler implements IOverviewRuler { cssClassName, this._context.viewLayout.getScrollHeight(), this._context.configuration.editor.lineHeight, - this._context.configuration.editor.canUseTranslate3d, this._context.configuration.editor.pixelRatio, minimumHeight, maximumHeight, @@ -48,10 +47,6 @@ export class OverviewRuler extends ViewEventHandler implements IOverviewRuler { this._overviewRuler.setLineHeight(this._context.configuration.editor.lineHeight, true); } - if (e.canUseTranslate3d) { - this._overviewRuler.setCanUseTranslate3d(this._context.configuration.editor.canUseTranslate3d, true); - } - if (e.pixelRatio) { this._overviewRuler.setPixelRatio(this._context.configuration.editor.pixelRatio, true); } diff --git a/src/vs/editor/browser/viewParts/overviewRuler/overviewRulerImpl.ts b/src/vs/editor/browser/viewParts/overviewRuler/overviewRulerImpl.ts index 617a850a1d7..51434ac5838 100644 --- a/src/vs/editor/browser/viewParts/overviewRuler/overviewRulerImpl.ts +++ b/src/vs/editor/browser/viewParts/overviewRuler/overviewRulerImpl.ts @@ -10,6 +10,7 @@ import { OverviewZoneManager, ColorZone, OverviewRulerZone } from 'vs/editor/com import { Color } from 'vs/base/common/color'; import { OverviewRulerPosition } from 'vs/editor/common/config/editorOptions'; import { ThemeType, LIGHT } from 'vs/platform/theme/common/themeService'; +import * as dom from 'vs/base/browser/dom'; export class OverviewRulerImpl { @@ -17,12 +18,11 @@ export class OverviewRulerImpl { private _domNode: FastDomNode; private _lanesCount: number; private _zoneManager: OverviewZoneManager; - private _canUseTranslate3d: boolean; private _background: Color; constructor( canvasLeftOffset: number, cssClassName: string, scrollHeight: number, lineHeight: number, - canUseTranslate3d: boolean, pixelRatio: number, minimumHeight: number, maximumHeight: number, + pixelRatio: number, minimumHeight: number, maximumHeight: number, getVerticalOffsetForLine: (lineNumber: number) => number ) { this._canvasLeftOffset = canvasLeftOffset; @@ -31,10 +31,10 @@ export class OverviewRulerImpl { this._domNode.setClassName(cssClassName); this._domNode.setPosition('absolute'); + dom.hintGPULayer(this._domNode.domNode); this._lanesCount = 3; - this._canUseTranslate3d = canUseTranslate3d; this._background = null; this._zoneManager = new OverviewZoneManager(getVerticalOffsetForLine); @@ -127,13 +127,6 @@ export class OverviewRulerImpl { } } - public setCanUseTranslate3d(canUseTranslate3d: boolean, render: boolean): void { - this._canUseTranslate3d = canUseTranslate3d; - if (render) { - this.render(true); - } - } - public setPixelRatio(pixelRatio: number, render: boolean): void { this._zoneManager.setPixelRatio(pixelRatio); this._domNode.setWidth(this._zoneManager.getDOMWidth()); @@ -156,11 +149,6 @@ export class OverviewRulerImpl { if (this._zoneManager.getOuterHeight() === 0) { return false; } - if (this._canUseTranslate3d) { - this._domNode.setTransform('translate3d(0px, 0px, 0px)'); - } else { - this._domNode.setTransform(''); - } const width = this._zoneManager.getCanvasWidth(); const height = this._zoneManager.getCanvasHeight(); -- GitLab From 50b9dfef31fd8ae3a58bf07fd6e055feeba3c3d4 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 14 Jun 2017 15:41:14 +0200 Subject: [PATCH 0816/1347] canUseTranslate3d is no longer a ScrollableElement option --- src/vs/base/browser/ui/list/listView.ts | 1 - src/vs/base/parts/tree/browser/treeView.ts | 1 - src/vs/editor/contrib/hover/browser/hoverWidgets.ts | 2 +- .../contrib/parameterHints/browser/parameterHintsWidget.ts | 2 +- src/vs/editor/contrib/suggest/browser/suggestWidget.ts | 2 +- src/vs/workbench/browser/parts/editor/binaryEditor.ts | 2 +- src/vs/workbench/browser/parts/editor/tabsTitleControl.ts | 1 - src/vs/workbench/parts/extensions/browser/extensionEditor.ts | 4 ++-- .../welcome/walkThrough/electron-browser/walkThroughPart.ts | 1 - 9 files changed, 6 insertions(+), 10 deletions(-) diff --git a/src/vs/base/browser/ui/list/listView.ts b/src/vs/base/browser/ui/list/listView.ts index 91d89a81e55..497bf624a0c 100644 --- a/src/vs/base/browser/ui/list/listView.ts +++ b/src/vs/base/browser/ui/list/listView.ts @@ -81,7 +81,6 @@ export class ListView implements IDisposable { this.gesture = new Gesture(this.rowsContainer); this.scrollableElement = new ScrollableElement(this.rowsContainer, { - canUseTranslate3d: false, alwaysConsumeMouseWheel: true, horizontal: ScrollbarVisibility.Hidden, vertical: ScrollbarVisibility.Auto, diff --git a/src/vs/base/parts/tree/browser/treeView.ts b/src/vs/base/parts/tree/browser/treeView.ts index fbbef901f54..b424249e1eb 100644 --- a/src/vs/base/parts/tree/browser/treeView.ts +++ b/src/vs/base/parts/tree/browser/treeView.ts @@ -460,7 +460,6 @@ export class TreeView extends HeightMap { this.wrapper = document.createElement('div'); this.wrapper.className = 'monaco-tree-wrapper'; this.scrollableElement = new ScrollableElement(this.wrapper, { - canUseTranslate3d: false, alwaysConsumeMouseWheel: true, horizontal: ScrollbarVisibility.Hidden, vertical: (typeof context.options.verticalScrollMode !== 'undefined' ? context.options.verticalScrollMode : ScrollbarVisibility.Auto), diff --git a/src/vs/editor/contrib/hover/browser/hoverWidgets.ts b/src/vs/editor/contrib/hover/browser/hoverWidgets.ts index bc42fb4935a..eacdbf64f4e 100644 --- a/src/vs/editor/contrib/hover/browser/hoverWidgets.ts +++ b/src/vs/editor/contrib/hover/browser/hoverWidgets.ts @@ -51,7 +51,7 @@ export class ContentHoverWidget extends Widget implements editorBrowser.IContent this._domNode = document.createElement('div'); this._domNode.className = 'monaco-editor-hover-content'; - this.scrollbar = new DomScrollableElement(this._domNode, { canUseTranslate3d: false }); + this.scrollbar = new DomScrollableElement(this._domNode, {}); this.disposables.push(this.scrollbar); this._containerDomNode.appendChild(this.scrollbar.getDomNode()); diff --git a/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.ts b/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.ts index a9fec25edf6..7c4e88e035e 100644 --- a/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.ts +++ b/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.ts @@ -221,7 +221,7 @@ export class ParameterHintsWidget implements IContentWidget, IDisposable { this.overloads = dom.append(wrapper, $('.overloads')); const body = $('.body'); - this.scrollbar = new DomScrollableElement(body, { canUseTranslate3d: false }); + this.scrollbar = new DomScrollableElement(body, {}); this.disposables.push(this.scrollbar); wrapper.appendChild(this.scrollbar.getDomNode()); diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index a3154f2a23d..5ab85e8bf03 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -213,7 +213,7 @@ class SuggestionDetails { this.body = $('.body'); - this.scrollbar = new DomScrollableElement(this.body, { canUseTranslate3d: false }); + this.scrollbar = new DomScrollableElement(this.body, {}); append(this.el, this.scrollbar.getDomNode()); this.disposables.push(this.scrollbar); diff --git a/src/vs/workbench/browser/parts/editor/binaryEditor.ts b/src/vs/workbench/browser/parts/editor/binaryEditor.ts index f2e1ec0cde6..08ce253c8db 100644 --- a/src/vs/workbench/browser/parts/editor/binaryEditor.ts +++ b/src/vs/workbench/browser/parts/editor/binaryEditor.ts @@ -59,7 +59,7 @@ export abstract class BaseBinaryResourceEditor extends BaseEditor { this.binaryContainer.tabindex(0); // enable focus support from the editor part (do not remove) // Custom Scrollbars - this.scrollbar = new DomScrollableElement(binaryContainerElement, { canUseTranslate3d: false, horizontal: ScrollbarVisibility.Auto, vertical: ScrollbarVisibility.Auto }); + this.scrollbar = new DomScrollableElement(binaryContainerElement, { horizontal: ScrollbarVisibility.Auto, vertical: ScrollbarVisibility.Auto }); parent.getHTMLElement().appendChild(this.scrollbar.getDomNode()); } diff --git a/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts b/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts index 1793a9c4a17..b735e56fe40 100644 --- a/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts +++ b/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts @@ -152,7 +152,6 @@ export class TabsTitleControl extends TitleControl { vertical: ScrollbarVisibility.Hidden, scrollYToX: true, useShadows: false, - canUseTranslate3d: false, horizontalScrollbarSize: 3 }); diff --git a/src/vs/workbench/parts/extensions/browser/extensionEditor.ts b/src/vs/workbench/parts/extensions/browser/extensionEditor.ts index 9334cdb4f53..84274e3c76e 100644 --- a/src/vs/workbench/parts/extensions/browser/extensionEditor.ts +++ b/src/vs/workbench/parts/extensions/browser/extensionEditor.ts @@ -358,7 +358,7 @@ export class ExtensionEditor extends BaseEditor { return this.loadContents(() => this.extensionManifest.get() .then(manifest => { const content = $('div', { class: 'subcontent' }); - const scrollableContent = new DomScrollableElement(content, { canUseTranslate3d: false }); + const scrollableContent = new DomScrollableElement(content, {}); const layout = () => scrollableContent.scanDomNode(); const removeLayoutParticipant = arrays.insert(this.layoutParticipants, { layout }); @@ -396,7 +396,7 @@ export class ExtensionEditor extends BaseEditor { return this.loadContents(() => { return this.extensionDependencies.get().then(extensionDependencies => { const content = $('div', { class: 'subcontent' }); - const scrollableContent = new DomScrollableElement(content, { canUseTranslate3d: false }); + const scrollableContent = new DomScrollableElement(content, {}); append(this.content, scrollableContent.getDomNode()); this.contentDisposables.push(scrollableContent); diff --git a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts index 48160e32d1e..1187473c057 100644 --- a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts +++ b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts @@ -121,7 +121,6 @@ export class WalkThroughPart extends BaseEditor { this.content.style.outlineStyle = 'none'; this.scrollbar = new DomScrollableElement(this.content, { - canUseTranslate3d: false, horizontal: ScrollbarVisibility.Auto, vertical: ScrollbarVisibility.Auto }); -- GitLab From 8e7e6e1f65046dd1ce7ee616f0309cc2cebe149e Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 14 Jun 2017 16:01:17 +0200 Subject: [PATCH 0817/1347] Use will-change to hint browser layers for the lines content and the margin layers instead of using translate3d ((Microsoft/monaco-editor#426)) --- src/vs/base/browser/dom.ts | 5 --- src/vs/base/browser/fastDomNode.ts | 41 ++++--------------- .../browser/ui/scrollbar/abstractScrollbar.ts | 2 +- src/vs/editor/browser/config/configuration.ts | 1 - .../browser/viewParts/lines/viewLines.ts | 21 ++++------ .../editor/browser/viewParts/margin/margin.ts | 18 +++----- .../browser/viewParts/minimap/minimap.ts | 2 +- .../overviewRuler/overviewRulerImpl.ts | 3 +- .../common/config/commonEditorConfig.ts | 2 - src/vs/editor/common/config/editorOptions.ts | 28 ++++++------- src/vs/editor/common/view/viewEvents.ts | 4 +- .../common/config/commonEditorConfig.test.ts | 1 - .../test/common/mocks/testConfiguration.ts | 1 - src/vs/monaco.d.ts | 9 ++-- 14 files changed, 45 insertions(+), 93 deletions(-) diff --git a/src/vs/base/browser/dom.ts b/src/vs/base/browser/dom.ts index 2915bcb44bb..228550b57af 100644 --- a/src/vs/base/browser/dom.ts +++ b/src/vs/base/browser/dom.ts @@ -1041,8 +1041,3 @@ export function domContentLoaded(): TPromise { } }); } - -export function hintGPULayer(target: HTMLElement): void { - // This is to hint browsers that this dom node is suited to live in its own layer (e.g. sliders, etc.) - (target.style).willChange = 'transform'; -} diff --git a/src/vs/base/browser/fastDomNode.ts b/src/vs/base/browser/fastDomNode.ts index edd726ec0a2..695b48141e7 100644 --- a/src/vs/base/browser/fastDomNode.ts +++ b/src/vs/base/browser/fastDomNode.ts @@ -6,7 +6,7 @@ import * as dom from 'vs/base/browser/dom'; -export abstract class FastDomNode { +export class FastDomNode { public readonly domNode: T; private _maxWidth: number; @@ -25,7 +25,7 @@ export abstract class FastDomNode { private _display: string; private _position: string; private _visibility: string; - private _transform: string; + private _layerHint: boolean; constructor(domNode: T) { this.domNode = domNode; @@ -45,7 +45,7 @@ export abstract class FastDomNode { this._display = ''; this._position = ''; this._visibility = ''; - this._transform = ''; + this._layerHint = false; } public setMaxWidth(maxWidth: number): void { @@ -215,16 +215,14 @@ export abstract class FastDomNode { this.domNode.style.visibility = this._visibility; } - public setTransform(transform: string): void { - if (this._transform === transform) { + public setLayerHinting(layerHint: boolean): void { + if (this._layerHint === layerHint) { return; } - this._transform = transform; - this._setTransform(this.domNode, this._transform); + this._layerHint = layerHint; + (this.domNode.style).willChange = this._layerHint ? 'transform' : 'auto'; } - protected abstract _setTransform(domNode: T, transform: string): void; - public setAttribute(name: string, value: string): void { this.domNode.setAttribute(name, value); } @@ -250,29 +248,6 @@ export abstract class FastDomNode { } } -class WebKitFastDomNode extends FastDomNode { - protected _setTransform(domNode: T, transform: string): void { - (domNode.style).webkitTransform = transform; - } -} - -class StandardFastDomNode extends FastDomNode { - protected _setTransform(domNode: T, transform: string): void { - domNode.style.transform = transform; - } -} - -let useWebKitFastDomNode = false; -(function () { - let testDomNode = document.createElement('div'); - if (typeof (testDomNode.style).webkitTransform !== 'undefined') { - useWebKitFastDomNode = true; - } -})(); export function createFastDomNode(domNode: T): FastDomNode { - if (useWebKitFastDomNode) { - return new WebKitFastDomNode(domNode); - } else { - return new StandardFastDomNode(domNode); - } + return new FastDomNode(domNode); } diff --git a/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts b/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts index 2798c774222..5d326d59eb4 100644 --- a/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts +++ b/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts @@ -95,7 +95,7 @@ export abstract class AbstractScrollbar extends Widget { this.slider.setLeft(left); this.slider.setWidth(width); this.slider.setHeight(height); - DomUtils.hintGPULayer(this.slider.domNode); + this.slider.setLayerHinting(true); this.domNode.domNode.appendChild(this.slider.domNode); diff --git a/src/vs/editor/browser/config/configuration.ts b/src/vs/editor/browser/config/configuration.ts index 960faa7b1e6..0a7787b4926 100644 --- a/src/vs/editor/browser/config/configuration.ts +++ b/src/vs/editor/browser/config/configuration.ts @@ -351,7 +351,6 @@ export class Configuration extends CommonEditorConfiguration { extraEditorClassName: this._getExtraEditorClassName(), outerWidth: this._elementSizeObserver.getWidth(), outerHeight: this._elementSizeObserver.getHeight(), - canUseTranslate3d: browser.canUseTranslate3d(), emptySelectionClipboard: browser.isWebKit, pixelRatio: browser.getPixelRatio(), zoomLevel: browser.getZoomLevel(), diff --git a/src/vs/editor/browser/viewParts/lines/viewLines.ts b/src/vs/editor/browser/viewParts/lines/viewLines.ts index 462a4e5160d..6998bc6a8ea 100644 --- a/src/vs/editor/browser/viewParts/lines/viewLines.ts +++ b/src/vs/editor/browser/viewParts/lines/viewLines.ts @@ -52,7 +52,7 @@ export class ViewLines extends ViewPart implements IVisibleLinesHost, private _typicalHalfwidthCharacterWidth: number; private _isViewportWrapping: boolean; private _revealHorizontalRightPadding: number; - private _canUseTranslate3d: boolean; + private _canUseLayerHinting: boolean; private _viewLineOptions: ViewLineOptions; // --- width @@ -75,7 +75,7 @@ export class ViewLines extends ViewPart implements IVisibleLinesHost, this._typicalHalfwidthCharacterWidth = conf.editor.fontInfo.typicalHalfwidthCharacterWidth; this._isViewportWrapping = conf.editor.wrappingInfo.isViewportWrapping; this._revealHorizontalRightPadding = conf.editor.viewInfo.revealHorizontalRightPadding; - this._canUseTranslate3d = conf.editor.canUseTranslate3d; + this._canUseLayerHinting = conf.editor.canUseLayerHinting; this._viewLineOptions = new ViewLineOptions(conf); PartFingerprints.write(this.domNode, PartFingerprint.ViewLines); @@ -132,8 +132,8 @@ export class ViewLines extends ViewPart implements IVisibleLinesHost, if (e.viewInfo) { this._revealHorizontalRightPadding = conf.editor.viewInfo.revealHorizontalRightPadding; } - if (e.canUseTranslate3d) { - this._canUseTranslate3d = conf.editor.canUseTranslate3d; + if (e.canUseLayerHinting) { + this._canUseLayerHinting = conf.editor.canUseLayerHinting; } if (e.fontInfo) { Configuration.applyFontInfo(this.domNode, conf.editor.fontInfo); @@ -443,17 +443,10 @@ export class ViewLines extends ViewPart implements IVisibleLinesHost, } // (3) handle scrolling + this._linesContent.setLayerHinting(this._canUseLayerHinting); const adjustedScrollTop = this._context.viewLayout.getScrollTop() - viewportData.bigNumbersDelta; - if (this._canUseTranslate3d) { - let transform = 'translate3d(' + -this._context.viewLayout.getScrollLeft() + 'px, ' + -adjustedScrollTop + 'px, 0px)'; - this._linesContent.setTransform(transform); - this._linesContent.setTop(0); - this._linesContent.setLeft(0); - } else { - this._linesContent.setTransform(''); - this._linesContent.setTop(-adjustedScrollTop); - this._linesContent.setLeft(-this._context.viewLayout.getScrollLeft()); - } + this._linesContent.setTop(-adjustedScrollTop); + this._linesContent.setLeft(-this._context.viewLayout.getScrollLeft()); // Update max line width (not so important, it is just so the horizontal scrollbar doesn't get too small) this._asyncUpdateLineWidths.schedule(); diff --git a/src/vs/editor/browser/viewParts/margin/margin.ts b/src/vs/editor/browser/viewParts/margin/margin.ts index 35fcf1563b9..bd3fc8b97a6 100644 --- a/src/vs/editor/browser/viewParts/margin/margin.ts +++ b/src/vs/editor/browser/viewParts/margin/margin.ts @@ -16,7 +16,7 @@ export class Margin extends ViewPart { public static CLASS_NAME = 'glyph-margin'; private _domNode: FastDomNode; - private _canUseTranslate3d: boolean; + private _canUseLayerHinting: boolean; private _contentLeft: number; private _glyphMarginLeft: number; private _glyphMarginWidth: number; @@ -24,7 +24,7 @@ export class Margin extends ViewPart { constructor(context: ViewContext) { super(context); - this._canUseTranslate3d = this._context.configuration.editor.canUseTranslate3d; + this._canUseLayerHinting = this._context.configuration.editor.canUseLayerHinting; this._contentLeft = this._context.configuration.editor.layoutInfo.contentLeft; this._glyphMarginLeft = this._context.configuration.editor.layoutInfo.glyphMarginLeft; this._glyphMarginWidth = this._context.configuration.editor.layoutInfo.glyphMarginWidth; @@ -57,8 +57,8 @@ export class Margin extends ViewPart { // --- begin event handlers public onConfigurationChanged(e: viewEvents.ViewConfigurationChangedEvent): boolean { - if (e.canUseTranslate3d) { - this._canUseTranslate3d = this._context.configuration.editor.canUseTranslate3d; + if (e.canUseLayerHinting) { + this._canUseLayerHinting = this._context.configuration.editor.canUseLayerHinting; } if (e.layoutInfo) { @@ -80,15 +80,9 @@ export class Margin extends ViewPart { } public render(ctx: RestrictedRenderingContext): void { + this._domNode.setLayerHinting(this._canUseLayerHinting); const adjustedScrollTop = ctx.scrollTop - ctx.bigNumbersDelta; - if (this._canUseTranslate3d) { - let transform = 'translate3d(0px, ' + -adjustedScrollTop + 'px, 0px)'; - this._domNode.setTransform(transform); - this._domNode.setTop(0); - } else { - this._domNode.setTransform(''); - this._domNode.setTop(-adjustedScrollTop); - } + this._domNode.setTop(-adjustedScrollTop); let height = Math.min(ctx.scrollHeight, 1000000); this._domNode.setHeight(height); diff --git a/src/vs/editor/browser/viewParts/minimap/minimap.ts b/src/vs/editor/browser/viewParts/minimap/minimap.ts index 70cb44e1523..98609ffbbcd 100644 --- a/src/vs/editor/browser/viewParts/minimap/minimap.ts +++ b/src/vs/editor/browser/viewParts/minimap/minimap.ts @@ -413,7 +413,7 @@ export class Minimap extends ViewPart { this._slider = createFastDomNode(document.createElement('div')); this._slider.setPosition('absolute'); this._slider.setClassName('minimap-slider'); - dom.hintGPULayer(this._slider.domNode); + this._slider.setLayerHinting(true); this._domNode.appendChild(this._slider); this._tokensColorTracker = MinimapTokensColorTracker.getInstance(); diff --git a/src/vs/editor/browser/viewParts/overviewRuler/overviewRulerImpl.ts b/src/vs/editor/browser/viewParts/overviewRuler/overviewRulerImpl.ts index 51434ac5838..2e6a03a39d8 100644 --- a/src/vs/editor/browser/viewParts/overviewRuler/overviewRulerImpl.ts +++ b/src/vs/editor/browser/viewParts/overviewRuler/overviewRulerImpl.ts @@ -10,7 +10,6 @@ import { OverviewZoneManager, ColorZone, OverviewRulerZone } from 'vs/editor/com import { Color } from 'vs/base/common/color'; import { OverviewRulerPosition } from 'vs/editor/common/config/editorOptions'; import { ThemeType, LIGHT } from 'vs/platform/theme/common/themeService'; -import * as dom from 'vs/base/browser/dom'; export class OverviewRulerImpl { @@ -31,7 +30,7 @@ export class OverviewRulerImpl { this._domNode.setClassName(cssClassName); this._domNode.setPosition('absolute'); - dom.hintGPULayer(this._domNode.domNode); + this._domNode.setLayerHinting(true); this._lanesCount = 3; diff --git a/src/vs/editor/common/config/commonEditorConfig.ts b/src/vs/editor/common/config/commonEditorConfig.ts index 553a1722299..9dc377162fd 100644 --- a/src/vs/editor/common/config/commonEditorConfig.ts +++ b/src/vs/editor/common/config/commonEditorConfig.ts @@ -55,7 +55,6 @@ export interface IEnvConfiguration { extraEditorClassName: string; outerWidth: number; outerHeight: number; - canUseTranslate3d: boolean; emptySelectionClipboard: boolean; pixelRatio: number; zoomLevel: number; @@ -125,7 +124,6 @@ export abstract class CommonEditorConfiguration extends Disposable implements ed extraEditorClassName: partialEnv.extraEditorClassName, isDominatedByLongLines: this._isDominatedByLongLines, lineNumbersDigitCount: this._lineNumbersDigitCount, - canUseTranslate3d: partialEnv.canUseTranslate3d, emptySelectionClipboard: partialEnv.emptySelectionClipboard, pixelRatio: partialEnv.pixelRatio, tabFocusMode: TabFocus.getTabFocusMode(), diff --git a/src/vs/editor/common/config/editorOptions.ts b/src/vs/editor/common/config/editorOptions.ts index 82e3f1994b6..9835b48bc22 100644 --- a/src/vs/editor/common/config/editorOptions.ts +++ b/src/vs/editor/common/config/editorOptions.ts @@ -246,10 +246,11 @@ export interface IEditorOptions { */ fontLigatures?: boolean; /** - * Disable the use of `translate3d`. + * Disable the use of `will-change` for the editor margin and lines layers. + * The usage of `will-change` acts as a hint for browsers to create an extra layer. * Defaults to false. */ - disableTranslate3d?: boolean; + disableLayerHinting?: boolean; /** * Disable the optimizations for monospace fonts. * Defaults to false. @@ -792,7 +793,7 @@ export interface IValidatedEditorOptions { readonly lineDecorationsWidth: number | string; readonly readOnly: boolean; readonly mouseStyle: 'text' | 'default' | 'copy'; - readonly disableTranslate3d: boolean; + readonly disableLayerHinting: boolean; readonly automaticLayout: boolean; readonly wordWrap: 'off' | 'on' | 'wordWrapColumn' | 'bounded'; readonly wordWrapColumn: number; @@ -818,7 +819,7 @@ export interface IValidatedEditorOptions { export class InternalEditorOptions { readonly _internalEditorOptionsBrand: void; - readonly canUseTranslate3d: boolean; + readonly canUseLayerHinting: boolean; readonly pixelRatio: number; readonly editorClassName: string; readonly lineHeight: number; @@ -848,7 +849,7 @@ export class InternalEditorOptions { * @internal */ constructor(source: { - canUseTranslate3d: boolean; + canUseLayerHinting: boolean; pixelRatio: number; editorClassName: string; lineHeight: number; @@ -867,7 +868,7 @@ export class InternalEditorOptions { wrappingInfo: EditorWrappingInfo; contribInfo: EditorContribOptions; }) { - this.canUseTranslate3d = source.canUseTranslate3d; + this.canUseLayerHinting = source.canUseLayerHinting; this.pixelRatio = source.pixelRatio; this.editorClassName = source.editorClassName; this.lineHeight = source.lineHeight | 0; @@ -892,7 +893,7 @@ export class InternalEditorOptions { */ public equals(other: InternalEditorOptions): boolean { return ( - this.canUseTranslate3d === other.canUseTranslate3d + this.canUseLayerHinting === other.canUseLayerHinting && this.pixelRatio === other.pixelRatio && this.editorClassName === other.editorClassName && this.lineHeight === other.lineHeight @@ -918,7 +919,7 @@ export class InternalEditorOptions { */ public createChangeEvent(newOpts: InternalEditorOptions): IConfigurationChangedEvent { return { - canUseTranslate3d: (this.canUseTranslate3d !== newOpts.canUseTranslate3d), + canUseLayerHinting: (this.canUseLayerHinting !== newOpts.canUseLayerHinting), pixelRatio: (this.pixelRatio !== newOpts.pixelRatio), editorClassName: (this.editorClassName !== newOpts.editorClassName), lineHeight: (this.lineHeight !== newOpts.lineHeight), @@ -1258,7 +1259,7 @@ export interface EditorLayoutInfo { * An event describing that the configuration of the editor has changed. */ export interface IConfigurationChangedEvent { - readonly canUseTranslate3d: boolean; + readonly canUseLayerHinting: boolean; readonly pixelRatio: boolean; readonly editorClassName: boolean; readonly lineHeight: boolean; @@ -1288,7 +1289,6 @@ export interface IEnvironmentalOptions { readonly extraEditorClassName: string; readonly isDominatedByLongLines: boolean; readonly lineNumbersDigitCount: number; - readonly canUseTranslate3d: boolean; readonly emptySelectionClipboard: boolean; readonly pixelRatio: number; readonly tabFocusMode: boolean; @@ -1435,7 +1435,7 @@ export class EditorOptionsValidator { lineDecorationsWidth: (typeof opts.lineDecorationsWidth === 'undefined' ? defaults.lineDecorationsWidth : opts.lineDecorationsWidth), readOnly: _boolean(opts.readOnly, defaults.readOnly), mouseStyle: _stringSet<'text' | 'default' | 'copy'>(opts.mouseStyle, defaults.mouseStyle, ['text', 'default', 'copy']), - disableTranslate3d: _boolean(opts.disableTranslate3d, defaults.disableTranslate3d), + disableLayerHinting: _boolean(opts.disableLayerHinting, defaults.disableLayerHinting), automaticLayout: _boolean(opts.automaticLayout, defaults.automaticLayout), wordWrap: wordWrap, wordWrapColumn: _clampedInt(opts.wordWrapColumn, defaults.wordWrapColumn, 1, Constants.MAX_SAFE_SMALL_INTEGER), @@ -1660,7 +1660,7 @@ export class InternalEditorOptionsFactory { lineDecorationsWidth: opts.lineDecorationsWidth, readOnly: opts.readOnly, mouseStyle: opts.mouseStyle, - disableTranslate3d: opts.disableTranslate3d, + disableLayerHinting: opts.disableLayerHinting, automaticLayout: opts.automaticLayout, wordWrap: opts.wordWrap, wordWrapColumn: opts.wordWrapColumn, @@ -1867,7 +1867,7 @@ export class InternalEditorOptionsFactory { } return new InternalEditorOptions({ - canUseTranslate3d: opts.disableTranslate3d ? false : env.canUseTranslate3d, + canUseLayerHinting: opts.disableLayerHinting ? false : true, pixelRatio: env.pixelRatio, editorClassName: className, lineHeight: env.fontInfo.lineHeight, @@ -2079,7 +2079,7 @@ export const EDITOR_DEFAULTS: IValidatedEditorOptions = { lineDecorationsWidth: 10, readOnly: false, mouseStyle: 'text', - disableTranslate3d: false, + disableLayerHinting: false, automaticLayout: false, wordWrap: 'off', wordWrapColumn: 80, diff --git a/src/vs/editor/common/view/viewEvents.ts b/src/vs/editor/common/view/viewEvents.ts index 72fc6b41fbe..b4a6e4bbf28 100644 --- a/src/vs/editor/common/view/viewEvents.ts +++ b/src/vs/editor/common/view/viewEvents.ts @@ -33,7 +33,7 @@ export class ViewConfigurationChangedEvent { public readonly type = ViewEventType.ViewConfigurationChanged; - public readonly canUseTranslate3d: boolean; + public readonly canUseLayerHinting: boolean; public readonly pixelRatio: boolean; public readonly editorClassName: boolean; public readonly lineHeight: boolean; @@ -46,7 +46,7 @@ export class ViewConfigurationChangedEvent { public readonly wrappingInfo: boolean; constructor(source: IConfigurationChangedEvent) { - this.canUseTranslate3d = source.canUseTranslate3d; + this.canUseLayerHinting = source.canUseLayerHinting; this.pixelRatio = source.pixelRatio; this.editorClassName = source.editorClassName; this.lineHeight = source.lineHeight; diff --git a/src/vs/editor/test/common/config/commonEditorConfig.test.ts b/src/vs/editor/test/common/config/commonEditorConfig.test.ts index 2e2f47b16aa..4d5da6aec32 100644 --- a/src/vs/editor/test/common/config/commonEditorConfig.test.ts +++ b/src/vs/editor/test/common/config/commonEditorConfig.test.ts @@ -59,7 +59,6 @@ suite('Common Editor Config', () => { extraEditorClassName: '', outerWidth: 1000, outerHeight: 100, - canUseTranslate3d: true, emptySelectionClipboard: true, pixelRatio: 1, zoomLevel: 0, diff --git a/src/vs/editor/test/common/mocks/testConfiguration.ts b/src/vs/editor/test/common/mocks/testConfiguration.ts index a8778a6f055..b94830a8456 100644 --- a/src/vs/editor/test/common/mocks/testConfiguration.ts +++ b/src/vs/editor/test/common/mocks/testConfiguration.ts @@ -21,7 +21,6 @@ export class TestConfiguration extends CommonEditorConfiguration { extraEditorClassName: '', outerWidth: 100, outerHeight: 100, - canUseTranslate3d: true, emptySelectionClipboard: true, pixelRatio: 1, zoomLevel: 0, diff --git a/src/vs/monaco.d.ts b/src/vs/monaco.d.ts index 0b34c6869aa..25272570d5d 100644 --- a/src/vs/monaco.d.ts +++ b/src/vs/monaco.d.ts @@ -2793,10 +2793,11 @@ declare module monaco.editor { */ fontLigatures?: boolean; /** - * Disable the use of `translate3d`. + * Disable the use of `will-change` for the editor margin and lines layers. + * The usage of `will-change` acts as a hint for browsers to create an extra layer. * Defaults to false. */ - disableTranslate3d?: boolean; + disableLayerHinting?: boolean; /** * Disable the optimizations for monospace fonts. * Defaults to false. @@ -3275,7 +3276,7 @@ declare module monaco.editor { */ export class InternalEditorOptions { readonly _internalEditorOptionsBrand: void; - readonly canUseTranslate3d: boolean; + readonly canUseLayerHinting: boolean; readonly pixelRatio: number; readonly editorClassName: string; readonly lineHeight: number; @@ -3406,7 +3407,7 @@ declare module monaco.editor { * An event describing that the configuration of the editor has changed. */ export interface IConfigurationChangedEvent { - readonly canUseTranslate3d: boolean; + readonly canUseLayerHinting: boolean; readonly pixelRatio: boolean; readonly editorClassName: boolean; readonly lineHeight: boolean; -- GitLab From f33628287d1c87e39706f6c0fb9b281d873da748 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Wed, 14 Jun 2017 16:04:51 +0200 Subject: [PATCH 0818/1347] Removed integration and unit tests from smoke test. --- build/tfs/darwin/smoketest.sh | 6 ------ build/tfs/linux/smoketest.sh | 3 --- build/tfs/win32/smoketest.ps1 | 8 -------- 3 files changed, 17 deletions(-) diff --git a/build/tfs/darwin/smoketest.sh b/build/tfs/darwin/smoketest.sh index 18da9dabf38..60e1863f08d 100755 --- a/build/tfs/darwin/smoketest.sh +++ b/build/tfs/darwin/smoketest.sh @@ -20,12 +20,6 @@ step "Install distro dependencies" \ step "Build minified & upload source maps" \ npm run gulp -- --max_old_space_size=4096 vscode-darwin-min -step "Run unit tests" \ - ./scripts/test.sh --build --reporter dot - -step "Run integration tests" \ - ./scripts/test-integration.sh - step "Run smoke test" \ pushd test/smoke npm install diff --git a/build/tfs/linux/smoketest.sh b/build/tfs/linux/smoketest.sh index 70ceb3e9d7a..327d55b66d9 100644 --- a/build/tfs/linux/smoketest.sh +++ b/build/tfs/linux/smoketest.sh @@ -25,9 +25,6 @@ step "Install distro dependencies" \ step "Build minified" \ npm run gulp -- --max_old_space_size=4096 "vscode-linux-$ARCH-min" -step "Run unit tests" \ - ./scripts/test.sh --xvfb --build --reporter dot - step "Run smoke test" \ pushd test/smoke npm install diff --git a/build/tfs/win32/smoketest.ps1 b/build/tfs/win32/smoketest.ps1 index 8a3a2dcfcb8..e7737a9f895 100644 --- a/build/tfs/win32/smoketest.ps1 +++ b/build/tfs/win32/smoketest.ps1 @@ -36,14 +36,6 @@ step "Build minified" { exec { & npm run gulp -- --max_old_space_size=4096 "vscode-win32-$global:arch-min" } } -step "Run unit tests" { - exec { & .\scripts\test.bat --build --reporter dot } -} - -# step "Run integration tests" { -# exec { & .\scripts\test-integration.bat } -# } - step "Run smoke test" { exec { & Push-Location test\smoke } exec { & npm install; npm run compile } -- GitLab From 850c83918b90013cd091f47eafec8de1cdbda563 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 14 Jun 2017 16:13:13 +0200 Subject: [PATCH 0819/1347] Fix bad pull rebase --- src/vs/workbench/parts/debug/electron-browser/debugHover.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts index 946fe4db939..6948d29a257 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts @@ -62,7 +62,7 @@ export class DebugHoverWidget implements IContentWidget { this.valueContainer = $('.value'); this.valueContainer.tabIndex = 0; this.valueContainer.setAttribute('role', 'tooltip'); - this.scrollbar = new DomScrollableElement(this.valueContainer, { canUseTranslate3d: false }); + this.scrollbar = new DomScrollableElement(this.valueContainer, {}); this.domNode.appendChild(this.scrollbar.getDomNode()); this.toDispose.push(this.scrollbar); -- GitLab From 79282cda3e64a32d9538de917a0f20d0975099f3 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Wed, 14 Jun 2017 15:33:27 +0200 Subject: [PATCH 0820/1347] #28538 Create a configuration model that can retrieve and merge contents --- .../configuration/common/configuration.ts | 79 ++++++++++-- src/vs/platform/configuration/common/model.ts | 117 ++++-------------- .../node/configurationService.ts | 26 ++-- .../test/common/configuration.test.ts | 79 ++++++++++++ .../configuration/test/common/model.test.ts | 61 ++++----- .../common/configurationModels.ts | 8 +- .../configuration/node/configuration.ts | 25 ++-- 7 files changed, 222 insertions(+), 173 deletions(-) create mode 100644 src/vs/platform/configuration/test/common/configuration.test.ts diff --git a/src/vs/platform/configuration/common/configuration.ts b/src/vs/platform/configuration/common/configuration.ts index 7292988c11b..0aec692a2d8 100644 --- a/src/vs/platform/configuration/common/configuration.ts +++ b/src/vs/platform/configuration/common/configuration.ts @@ -4,6 +4,9 @@ *--------------------------------------------------------------------------------------------*/ import { TPromise } from 'vs/base/common/winjs.base'; +import * as arrays from 'vs/base/common/arrays'; +import * as types from 'vs/base/common/types'; +import * as objects from 'vs/base/common/objects'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; import Event from 'vs/base/common/event'; @@ -101,18 +104,76 @@ export function getConfigurationValue(config: any, settingPath: string, defau return typeof result === 'undefined' ? defaultValue : result; } -export interface IConfigModel { - contents: T; - overrides: IOverrides[]; - keys: string[]; - errors: any[]; - - merge(other: IConfigModel, overwrite?: boolean): IConfigModel; - getContentsFor(section: string): V; - configWithOverrides(identifier: string, section?: string): IConfigModel; +export function merge(base: any, add: any, overwrite: boolean): void { + Object.keys(add).forEach(key => { + if (key in base) { + if (types.isObject(base[key]) && types.isObject(add[key])) { + merge(base[key], add[key], overwrite); + } else if (overwrite) { + base[key] = add[key]; + } + } else { + base[key] = add[key]; + } + }); } export interface IOverrides { contents: T; identifiers: string[]; } + +export class Configuration { + + protected _keys: string[] = []; + + constructor(protected _contents: T = {}, protected _overrides: IOverrides[] = []) { + } + + public get contents(): T { + return this._contents; + } + + public get keys(): string[] { + return this._keys; + } + + public getContentsFor(section: string): V { + return objects.clone(this.contents[section]); + } + + public override(identifier: string): Configuration { + const result = new Configuration(); + const contents = objects.clone(this.contents); + if (this._overrides) { + for (const override of this._overrides) { + if (override.identifiers.indexOf(identifier) !== -1) { + merge(contents, override.contents, true); + } + } + } + result._contents = contents; + return result; + } + + public merge(other: Configuration, overwrite: boolean = true): Configuration { + const mergedModel = new Configuration(); + this.doMerge(mergedModel, this, overwrite); + this.doMerge(mergedModel, other, overwrite); + return mergedModel; + } + + protected doMerge(source: Configuration, target: Configuration, overwrite: boolean = true) { + merge(source.contents, objects.clone(target.contents), overwrite); + const overrides = objects.clone(source._overrides); + for (const override of target._overrides) { + const [sourceOverride] = overrides.filter(o => arrays.equals(o.identifiers, override.identifiers)); + if (sourceOverride) { + merge(sourceOverride.contents, override.contents, overwrite); + } else { + overrides.push(override); + } + } + source._overrides = overrides; + } +} \ No newline at end of file diff --git a/src/vs/platform/configuration/common/model.ts b/src/vs/platform/configuration/common/model.ts index cfbc368d83a..bbc843ffa3a 100644 --- a/src/vs/platform/configuration/common/model.ts +++ b/src/vs/platform/configuration/common/model.ts @@ -5,12 +5,9 @@ 'use strict'; import { Registry } from 'vs/platform/platform'; -import * as types from 'vs/base/common/types'; import * as json from 'vs/base/common/json'; -import * as objects from 'vs/base/common/objects'; -import * as arrays from 'vs/base/common/arrays'; import { IConfigurationRegistry, Extensions, OVERRIDE_PROPERTY_PATTERN } from 'vs/platform/configuration/common/configurationRegistry'; -import { IConfigModel, IOverrides } from 'vs/platform/configuration/common/configuration'; +import { Configuration, IOverrides } from 'vs/platform/configuration/common/configuration'; export function getDefaultValues(): any { const valueTreeRoot: any = Object.create(null); @@ -68,92 +65,45 @@ export function getConfigurationKeys(): string[] { return Object.keys(properties); } -export function merge(base: any, add: any, overwrite: boolean): void { - Object.keys(add).forEach(key => { - if (key in base) { - if (types.isObject(base[key]) && types.isObject(add[key])) { - merge(base[key], add[key], overwrite); - } else if (overwrite) { - base[key] = add[key]; - } - } else { - base[key] = add[key]; - } - }); +export class DefaultConfiguration extends Configuration { + + constructor() { + super(getDefaultValues()); + this._keys = getConfigurationKeys(); + this._overrides = Object.keys(this._contents) + .filter(key => OVERRIDE_PROPERTY_PATTERN.test(key)) + .map(key => { + return >{ + identifiers: [overrideIdentifierFromKey(key).trim()], + contents: toValuesTree(this._contents[key], message => console.error(`Conflict in default settings file: ${message}`)) + }; + }); + } + + public get keys(): string[] { + return this._keys; + } } interface Overrides extends IOverrides { raw: any; } -export class ConfigModel implements IConfigModel { +export class CustomConfiguration extends Configuration { - protected _contents: T = {}; - protected _overrides: IOverrides[] = []; - protected _keys: string[] = []; protected _parseErrors: any[] = []; constructor(content: string = '', private name: string = '') { + super(); if (content) { this.update(content); } } - public get contents(): T { - return this._contents; - } - - public get overrides(): IOverrides[] { - return this._overrides; - } - - public get keys(): string[] { - return this._keys; - } - public get errors(): any[] { return this._parseErrors; } - public merge(other: IConfigModel, overwrite: boolean = true): ConfigModel { - const mergedModel = new ConfigModel(null); - this.doMerge(mergedModel, this, overwrite); - this.doMerge(mergedModel, other, overwrite); - return mergedModel; - } - - protected doMerge(source: ConfigModel, target: IConfigModel, overwrite: boolean = true) { - merge(source.contents, objects.clone(target.contents), overwrite); - const overrides = objects.clone(source.overrides); - for (const override of target.overrides) { - const [sourceOverride] = overrides.filter(o => arrays.equals(o.identifiers, override.identifiers)); - if (sourceOverride) { - merge(sourceOverride.contents, override.contents, overwrite); - } else { - overrides.push(override); - } - } - source._overrides = overrides; - } - - public getContentsFor(section: string): V { - return objects.clone(this.contents[section]); - } - - public configWithOverrides(identifier: string): ConfigModel { - const result = new ConfigModel(null); - const contents = objects.clone(this.contents); - if (this.overrides) { - for (const override of this.overrides) { - if (override.identifiers.indexOf(identifier) !== -1) { - merge(contents, override.contents, true); - } - } - } - result._contents = contents; - return result; - } - public update(content: string): void { let parsed: T = {}; let overrides: Overrides[] = []; @@ -243,31 +193,6 @@ export class ConfigModel implements IConfigModel { } } -export class DefaultConfigModel extends ConfigModel { - - constructor() { - super(null); - this.update(); - } - - public get keys(): string[] { - return this._keys; - } - - public update(): void { - this._contents = getDefaultValues(); // defaults coming from contributions to registries - this._keys = getConfigurationKeys(); - this._overrides = Object.keys(this._contents) - .filter(key => OVERRIDE_PROPERTY_PATTERN.test(key)) - .map(key => { - return >{ - identifiers: [overrideIdentifierFromKey(key).trim()], - contents: toValuesTree(this._contents[key], message => console.error(`Conflict in default settings file: ${message}`)) - }; - }); - } -} - export function overrideIdentifierFromKey(key: string): string { return key.substring(1, key.length - 1); } diff --git a/src/vs/platform/configuration/node/configurationService.ts b/src/vs/platform/configuration/node/configurationService.ts index ea7164b96a1..3f7a1e9c22c 100644 --- a/src/vs/platform/configuration/node/configurationService.ts +++ b/src/vs/platform/configuration/node/configurationService.ts @@ -10,15 +10,15 @@ import { ConfigWatcher } from 'vs/base/node/config'; import { Registry } from 'vs/platform/platform'; import { IConfigurationRegistry, Extensions } from 'vs/platform/configuration/common/configurationRegistry'; import { IDisposable, toDisposable, Disposable } from 'vs/base/common/lifecycle'; -import { ConfigurationSource, IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, getConfigurationValue, IConfigurationKeys, IConfigModel, IConfigurationOptions } from 'vs/platform/configuration/common/configuration'; -import { ConfigModel, DefaultConfigModel } from 'vs/platform/configuration/common/model'; +import { ConfigurationSource, IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, getConfigurationValue, IConfigurationKeys, Configuration, IConfigurationOptions } from 'vs/platform/configuration/common/configuration'; +import { CustomConfiguration, DefaultConfiguration } from 'vs/platform/configuration/common/model'; import Event, { Emitter } from 'vs/base/common/event'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; export interface ICache { - defaults: IConfigModel; - user: IConfigModel; - consolidated: IConfigModel; + defaults: Configuration; + user: Configuration; + consolidated: Configuration; } export class ConfigurationService extends Disposable implements IConfigurationService, IDisposable { @@ -26,7 +26,7 @@ export class ConfigurationService extends Disposable implements IConfiguratio _serviceBrand: any; private cache: ICache; - private userConfigModelWatcher: ConfigWatcher>; + private userConfigModelWatcher: ConfigWatcher>; private _onDidUpdateConfiguration: Emitter = this._register(new Emitter()); public readonly onDidUpdateConfiguration: Event = this._onDidUpdateConfiguration.event; @@ -37,8 +37,8 @@ export class ConfigurationService extends Disposable implements IConfiguratio super(); this.userConfigModelWatcher = new ConfigWatcher(environmentService.appSettingsPath, { - changeBufferDelay: 300, defaultConfig: new ConfigModel(null, environmentService.appSettingsPath), parse: (content: string, parseErrors: any[]) => { - const userConfigModel = new ConfigModel(content, environmentService.appSettingsPath); + changeBufferDelay: 300, defaultConfig: new CustomConfiguration(null, environmentService.appSettingsPath), parse: (content: string, parseErrors: any[]) => { + const userConfigModel = new CustomConfiguration(content, environmentService.appSettingsPath); parseErrors = [...userConfigModel.errors]; return userConfigModel; } @@ -77,7 +77,7 @@ export class ConfigurationService extends Disposable implements IConfiguratio public getConfiguration(arg?: any): C { const options = this.toOptions(arg); const cache = this.getCache(); - const configModel = options.overrideIdentifier ? cache.consolidated.configWithOverrides(options.overrideIdentifier) : cache.consolidated; + const configModel = options.overrideIdentifier ? cache.consolidated.override(options.overrideIdentifier) : cache.consolidated; return options.section ? configModel.getContentsFor(options.section) : configModel.contents; } @@ -86,9 +86,9 @@ export class ConfigurationService extends Disposable implements IConfiguratio // make sure to clone the configuration so that the receiver does not tamper with the values return { - default: objects.clone(getConfigurationValue(overrideIdentifier ? cache.defaults.configWithOverrides(overrideIdentifier).contents : cache.defaults.contents, key)), - user: objects.clone(getConfigurationValue(overrideIdentifier ? cache.user.configWithOverrides(overrideIdentifier).contents : cache.user.contents, key)), - value: objects.clone(getConfigurationValue(overrideIdentifier ? cache.consolidated.configWithOverrides(overrideIdentifier).contents : cache.consolidated.contents, key)) + default: objects.clone(getConfigurationValue(overrideIdentifier ? cache.defaults.override(overrideIdentifier).contents : cache.defaults.contents, key)), + user: objects.clone(getConfigurationValue(overrideIdentifier ? cache.user.override(overrideIdentifier).contents : cache.user.contents, key)), + value: objects.clone(getConfigurationValue(overrideIdentifier ? cache.consolidated.override(overrideIdentifier).contents : cache.consolidated.contents, key)) }; } @@ -116,7 +116,7 @@ export class ConfigurationService extends Disposable implements IConfiguratio } private consolidateConfigurations(): ICache { - const defaults = new DefaultConfigModel(); + const defaults = new DefaultConfiguration(); const user = this.userConfigModelWatcher.getConfig(); const consolidated = defaults.merge(user); return { defaults, user, consolidated }; diff --git a/src/vs/platform/configuration/test/common/configuration.test.ts b/src/vs/platform/configuration/test/common/configuration.test.ts new file mode 100644 index 00000000000..69552e758fb --- /dev/null +++ b/src/vs/platform/configuration/test/common/configuration.test.ts @@ -0,0 +1,79 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +'use strict'; + +import * as assert from 'assert'; +import { Configuration, merge } from 'vs/platform/configuration/common/configuration'; +import { Extensions, IConfigurationRegistry } from 'vs/platform/configuration/common/configurationRegistry'; +import { Registry } from 'vs/platform/platform'; + +suite('Configuration', () => { + + suiteSetup(() => { + Registry.as(Extensions.Configuration).registerConfiguration({ + 'id': 'a', + 'order': 1, + 'title': 'a', + 'type': 'object', + 'properties': { + 'a': { + 'description': 'a', + 'type': 'boolean', + 'default': true, + 'overridable': true + } + } + }); + }); + + test('simple merge', () => { + let base = { 'a': 1, 'b': 2 }; + merge(base, { 'a': 3, 'c': 4 }, true); + assert.deepEqual(base, { 'a': 3, 'b': 2, 'c': 4 }); + base = { 'a': 1, 'b': 2 }; + merge(base, { 'a': 3, 'c': 4 }, false); + assert.deepEqual(base, { 'a': 1, 'b': 2, 'c': 4 }); + }); + + test('Recursive merge', () => { + const base = { 'a': { 'b': 1 } }; + merge(base, { 'a': { 'b': 2 } }, true); + assert.deepEqual(base, { 'a': { 'b': 2 } }); + }); + + test('simple merge using configuration', () => { + let base = new Configuration({ 'a': 1, 'b': 2 }); + let add = new Configuration({ 'a': 3, 'c': 4 }); + let result = base.merge(add); + assert.deepEqual(result.contents, { 'a': 3, 'b': 2, 'c': 4 }); + }); + + test('Recursive merge using config models', () => { + let base = new Configuration({ 'a': { 'b': 1 } }); + let add = new Configuration({ 'a': { 'b': 2 } }); + let result = base.merge(add); + assert.deepEqual(result.contents, { 'a': { 'b': 2 } }); + }); + + test('Test contents while getting an existing property', () => { + let testObject = new Configuration({ 'a': 1 }); + assert.deepEqual(testObject.getContentsFor('a'), 1); + + testObject = new Configuration({ 'a': { 'b': 1 } }); + assert.deepEqual(testObject.getContentsFor('a'), { 'b': 1 }); + }); + + test('Test contents are undefined for non existing properties', () => { + const testObject = new Configuration({ awesome: true }); + + assert.deepEqual(testObject.getContentsFor('unknownproperty'), undefined); + }); + + test('Test override gives all content merged with overrides', () => { + const testObject = new Configuration({ 'a': 1, 'c': 1 }, [{ identifiers: ['b'], contents: { 'a': 2 } }]); + + assert.deepEqual(testObject.override('b').contents, { 'a': 2, 'c': 1 }); + }); +}); \ No newline at end of file diff --git a/src/vs/platform/configuration/test/common/model.test.ts b/src/vs/platform/configuration/test/common/model.test.ts index db7edc4c0d7..e2f3bb6e997 100644 --- a/src/vs/platform/configuration/test/common/model.test.ts +++ b/src/vs/platform/configuration/test/common/model.test.ts @@ -5,11 +5,11 @@ 'use strict'; import * as assert from 'assert'; -import * as model from 'vs/platform/configuration/common/model'; +import { CustomConfiguration, DefaultConfiguration } from 'vs/platform/configuration/common/model'; import { Extensions, IConfigurationRegistry } from 'vs/platform/configuration/common/configurationRegistry'; import { Registry } from 'vs/platform/platform'; -suite('ConfigurationService - Model', () => { +suite('Configuration', () => { suiteSetup(() => { Registry.as(Extensions.Configuration).registerConfiguration({ @@ -28,62 +28,47 @@ suite('ConfigurationService - Model', () => { }); }); - test('simple merge', () => { - let base = { 'a': 1, 'b': 2 }; - model.merge(base, { 'a': 3, 'c': 4 }, true); - assert.deepEqual(base, { 'a': 3, 'b': 2, 'c': 4 }); - base = { 'a': 1, 'b': 2 }; - model.merge(base, { 'a': 3, 'c': 4 }, false); - assert.deepEqual(base, { 'a': 1, 'b': 2, 'c': 4 }); - }); - - test('Recursive merge', () => { - const base = { 'a': { 'b': 1 } }; - model.merge(base, { 'a': { 'b': 2 } }, true); - assert.deepEqual(base, { 'a': { 'b': 2 } }); - }); - test('simple merge using models', () => { - let base = new model.ConfigModel(JSON.stringify({ 'a': 1, 'b': 2 })); - let add = new model.ConfigModel(JSON.stringify({ 'a': 3, 'c': 4 })); + let base = new CustomConfiguration(JSON.stringify({ 'a': 1, 'b': 2 })); + let add = new CustomConfiguration(JSON.stringify({ 'a': 3, 'c': 4 })); let result = base.merge(add); assert.deepEqual(result.contents, { 'a': 3, 'b': 2, 'c': 4 }); }); test('simple merge with an undefined contents', () => { - let base = new model.ConfigModel(JSON.stringify({ 'a': 1, 'b': 2 })); - let add = new model.ConfigModel(null); + let base = new CustomConfiguration(JSON.stringify({ 'a': 1, 'b': 2 })); + let add = new CustomConfiguration(null); let result = base.merge(add); assert.deepEqual(result.contents, { 'a': 1, 'b': 2 }); - base = new model.ConfigModel(null); - add = new model.ConfigModel(JSON.stringify({ 'a': 1, 'b': 2 })); + base = new CustomConfiguration(null); + add = new CustomConfiguration(JSON.stringify({ 'a': 1, 'b': 2 })); result = base.merge(add); assert.deepEqual(result.contents, { 'a': 1, 'b': 2 }); - base = new model.ConfigModel(null); - add = new model.ConfigModel(null); + base = new CustomConfiguration(null); + add = new CustomConfiguration(null); result = base.merge(add); assert.deepEqual(result.contents, {}); }); test('Recursive merge using config models', () => { - let base = new model.ConfigModel(JSON.stringify({ 'a': { 'b': 1 } })); - let add = new model.ConfigModel(JSON.stringify({ 'a': { 'b': 2 } })); + let base = new CustomConfiguration(JSON.stringify({ 'a': { 'b': 1 } })); + let add = new CustomConfiguration(JSON.stringify({ 'a': { 'b': 2 } })); let result = base.merge(add); assert.deepEqual(result.contents, { 'a': { 'b': 2 } }); }); test('Test contents while getting an existing property', () => { - let testObject = new model.ConfigModel(JSON.stringify({ 'a': 1 })); + let testObject = new CustomConfiguration(JSON.stringify({ 'a': 1 })); assert.deepEqual(testObject.getContentsFor('a'), 1); - testObject = new model.ConfigModel(JSON.stringify({ 'a': { 'b': 1 } })); + testObject = new CustomConfiguration(JSON.stringify({ 'a': { 'b': 1 } })); assert.deepEqual(testObject.getContentsFor('a'), { 'b': 1 }); }); test('Test contents are undefined for non existing properties', () => { - const testObject = new model.ConfigModel(JSON.stringify({ + const testObject = new CustomConfiguration(JSON.stringify({ awesome: true })); @@ -91,25 +76,25 @@ suite('ConfigurationService - Model', () => { }); test('Test contents are undefined for undefined config', () => { - const testObject = new model.ConfigModel(null); + const testObject = new CustomConfiguration(null); assert.deepEqual(testObject.getContentsFor('unknownproperty'), undefined); }); test('Test configWithOverrides gives all content merged with overrides', () => { - const testObject = new model.ConfigModel(JSON.stringify({ 'a': 1, 'c': 1, '[b]': { 'a': 2 } })); + const testObject = new CustomConfiguration(JSON.stringify({ 'a': 1, 'c': 1, '[b]': { 'a': 2 } })); - assert.deepEqual(testObject.configWithOverrides('b').contents, { 'a': 2, 'c': 1, '[b]': { 'a': 2 } }); + assert.deepEqual(testObject.override('b').contents, { 'a': 2, 'c': 1, '[b]': { 'a': 2 } }); }); test('Test configWithOverrides gives empty contents', () => { - const testObject = new model.ConfigModel(null); + const testObject = new CustomConfiguration(null); - assert.deepEqual(testObject.configWithOverrides('b').contents, {}); + assert.deepEqual(testObject.override('b').contents, {}); }); test('Test update with empty data', () => { - const testObject = new model.ConfigModel(); + const testObject = new CustomConfiguration(); testObject.update(''); assert.deepEqual(testObject.contents, {}); @@ -140,7 +125,7 @@ suite('ConfigurationService - Model', () => { } } }); - assert.equal(true, new model.DefaultConfigModel().getContentsFor('a')); + assert.equal(true, new DefaultConfiguration().getContentsFor('a')); }); test('Test registering the language property', () => { @@ -157,7 +142,7 @@ suite('ConfigurationService - Model', () => { } } }); - assert.equal(undefined, new model.DefaultConfigModel().getContentsFor('[a]')); + assert.equal(undefined, new DefaultConfiguration().getContentsFor('[a]')); }); }); \ No newline at end of file diff --git a/src/vs/workbench/services/configuration/common/configurationModels.ts b/src/vs/workbench/services/configuration/common/configurationModels.ts index 10f1fb17a9d..d6ad817c30e 100644 --- a/src/vs/workbench/services/configuration/common/configurationModels.ts +++ b/src/vs/workbench/services/configuration/common/configurationModels.ts @@ -4,12 +4,12 @@ *--------------------------------------------------------------------------------------------*/ 'use strict'; -import { ConfigModel } from 'vs/platform/configuration/common/model'; +import { CustomConfiguration } from 'vs/platform/configuration/common/model'; import { WORKSPACE_STANDALONE_CONFIGURATIONS } from 'vs/workbench/services/configuration/common/configuration'; import { Registry } from 'vs/platform/platform'; import { IConfigurationRegistry, IConfigurationPropertySchema, Extensions } from 'vs/platform/configuration/common/configurationRegistry'; -export class ScopedConfigModel extends ConfigModel { +export class ScopedConfigModel extends CustomConfiguration { constructor(content: string, name: string, public readonly scope: string) { super(null, name); @@ -25,7 +25,7 @@ export class ScopedConfigModel extends ConfigModel { } -export class WorkspaceSettingsConfigModel extends ConfigModel { +export class WorkspaceSettingsConfigModel extends CustomConfiguration { private _raw: T; private _unsupportedKeys: string[]; @@ -62,7 +62,7 @@ export class WorkspaceSettingsConfigModel extends ConfigModel { } } -export class WorkspaceConfigModel extends ConfigModel { +export class WorkspaceConfigModel extends CustomConfiguration { constructor(public readonly workspaceSettingsConfig: WorkspaceSettingsConfigModel, private scopedConfigs: ScopedConfigModel[]) { super(); diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index 27661ffa4cb..cb06494acb2 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -20,9 +20,8 @@ import * as extfs from 'vs/base/node/extfs'; import { IWorkspaceContextService, IWorkspace2, Workspace as SingleRootWorkspace, IWorkspace } from "vs/platform/workspace/common/workspace"; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { FileChangeType, FileChangesEvent, isEqual } from 'vs/platform/files/common/files'; -import { ConfigModel } from 'vs/platform/configuration/common/model'; import { ScopedConfigModel, WorkspaceConfigModel, WorkspaceSettingsConfigModel } from 'vs/workbench/services/configuration/common/configurationModels'; -import { IConfigurationServiceEvent, ConfigurationSource, getConfigurationValue, IConfigModel, IConfigurationOptions } from 'vs/platform/configuration/common/configuration'; +import { IConfigurationServiceEvent, ConfigurationSource, getConfigurationValue, IConfigurationOptions, Configuration } from 'vs/platform/configuration/common/configuration'; import { IWorkspaceConfigurationValues, IWorkspaceConfigurationService, IWorkspaceConfigurationValue, WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME, WORKSPACE_STANDALONE_CONFIGURATIONS, WORKSPACE_CONFIG_DEFAULT_PATH } from 'vs/workbench/services/configuration/common/configuration'; import { ConfigurationService as GlobalConfigurationService } from 'vs/platform/configuration/node/configurationService'; @@ -68,11 +67,11 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp private baseConfigurationService: GlobalConfigurationService; - private cachedConfig: ConfigModel; + private cachedConfig: Configuration; private cachedWorkspaceConfig: WorkspaceConfigModel; private bulkFetchFromWorkspacePromise: TPromise; - private workspaceFilePathToConfiguration: { [relativeWorkspacePath: string]: TPromise> }; + private workspaceFilePathToConfiguration: { [relativeWorkspacePath: string]: TPromise> }; private reloadConfigurationScheduler: RunOnceScheduler; private readonly workspace: Workspace; @@ -83,7 +82,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp this.workspace = singleRootWorkspace ? new Workspace(singleRootWorkspace.resource.toString(), [singleRootWorkspace.resource]) : null; this.workspaceFilePathToConfiguration = Object.create(null); - this.cachedConfig = new ConfigModel(null); + this.cachedConfig = new Configuration(); this.cachedWorkspaceConfig = new WorkspaceConfigModel(new WorkspaceSettingsConfigModel(null), []); this.baseConfigurationService = this._register(new GlobalConfigurationService(environmentService)); @@ -162,7 +161,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } // update cached config when base config changes - const configModel = >this.baseConfigurationService.getCache().consolidated // global/default values (do NOT modify) + const configModel = >this.baseConfigurationService.getCache().consolidated // global/default values (do NOT modify) .merge(this.cachedWorkspaceConfig); // workspace configured values // emit this as update to listeners if changed @@ -184,7 +183,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp public getConfiguration(options?: IConfigurationOptions): C public getConfiguration(arg?: any): C { const options = this.toOptions(arg); - const configModel = options.overrideIdentifier ? this.cachedConfig.configWithOverrides(options.overrideIdentifier) : this.cachedConfig; + const configModel = options.overrideIdentifier ? this.cachedConfig.override(options.overrideIdentifier) : this.cachedConfig; return options.section ? configModel.getContentsFor(options.section) : configModel.contents; } @@ -193,8 +192,8 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp return { default: configurationValue.default, user: configurationValue.user, - workspace: objects.clone(getConfigurationValue(overrideIdentifier ? this.cachedWorkspaceConfig.configWithOverrides(overrideIdentifier).contents : this.cachedWorkspaceConfig.contents, key)), - value: objects.clone(getConfigurationValue(overrideIdentifier ? this.cachedConfig.configWithOverrides(overrideIdentifier).contents : this.cachedConfig.contents, key)) + workspace: objects.clone(getConfigurationValue(overrideIdentifier ? this.cachedWorkspaceConfig.override(overrideIdentifier).contents : this.cachedWorkspaceConfig.contents, key)), + value: objects.clone(getConfigurationValue(overrideIdentifier ? this.cachedConfig.override(overrideIdentifier).contents : this.cachedConfig.contents, key)) }; } @@ -268,7 +267,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp this.cachedWorkspaceConfig = new WorkspaceConfigModel(workspaceSettingsConfig, otherConfigModels); // Override base (global < user) with workspace locals (global < user < workspace) - this.cachedConfig = >this.baseConfigurationService.getCache().consolidated // global/default values (do NOT modify) + this.cachedConfig = >this.baseConfigurationService.getCache().consolidated // global/default values (do NOT modify) .merge(this.cachedWorkspaceConfig); // workspace configured values return { @@ -278,7 +277,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp }); } - private loadWorkspaceConfigFiles(): TPromise<{ [relativeWorkspacePath: string]: IConfigModel }> { + private loadWorkspaceConfigFiles(): TPromise<{ [relativeWorkspacePath: string]: Configuration }> { // Return early if we don't have a workspace if (!this.workspace) { @@ -363,7 +362,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } } - private createConfigModel(content: IContent): IConfigModel { + private createConfigModel(content: IContent): Configuration { const path = this.toWorkspaceRelativePath(content.resource); if (path === WORKSPACE_CONFIG_DEFAULT_PATH) { return new WorkspaceSettingsConfigModel(content.value, content.resource.toString()); @@ -374,7 +373,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } } - return new ConfigModel(null); + return new Configuration(); } private isWorkspaceConfigurationFile(workspaceRelativePath: string): boolean { -- GitLab From a807a515bb9bcc0ff06a6d277f219d325c60e5f7 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Wed, 14 Jun 2017 16:32:00 +0200 Subject: [PATCH 0821/1347] fixes #26642 --- extensions/git/src/model.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/extensions/git/src/model.ts b/extensions/git/src/model.ts index 56479c7121c..4b2cf900350 100644 --- a/extensions/git/src/model.ts +++ b/extensions/git/src/model.ts @@ -597,12 +597,13 @@ export class Model implements Disposable { const repositoryRoot = await this._git.getRepositoryRoot(this.workspaceRoot.fsPath); this.repository = this._git.open(repositoryRoot); - const onGitChange = filterEvent(this.onWorkspaceChange, uri => /\/\.git\//.test(uri.fsPath)); - const onRelevantGitChange = filterEvent(onGitChange, uri => !/\/\.git\/index\.lock$/.test(uri.fsPath)); + const onGitChange = filterEvent(this.onWorkspaceChange, uri => /\/\.git\//.test(uri.path)); + const onRelevantGitChange = filterEvent(onGitChange, uri => !/\/\.git\/index\.lock$/.test(uri.path)); + onRelevantGitChange(this.onFSChange, this, disposables); onRelevantGitChange(this._onDidChangeRepository.fire, this._onDidChangeRepository, disposables); - const onNonGitChange = filterEvent(this.onWorkspaceChange, uri => !/\/\.git\//.test(uri.fsPath)); + const onNonGitChange = filterEvent(this.onWorkspaceChange, uri => !/\/\.git\//.test(uri.path)); onNonGitChange(this.onFSChange, this, disposables); this.repositoryDisposable = combinedDisposable(disposables); -- GitLab From e8d9cb2fd679f39e065e34ed49cccd0e1238dc85 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 14 Jun 2017 16:32:56 +0200 Subject: [PATCH 0822/1347] Fixes #9634: Set rulers width with a value that maximizez the likelihood that all rulers are rendered with equal screen width --- src/vs/base/browser/dom.ts | 13 +++++++++++++ src/vs/editor/browser/viewParts/rulers/rulers.css | 1 - src/vs/editor/browser/viewParts/rulers/rulers.ts | 4 +++- 3 files changed, 16 insertions(+), 2 deletions(-) diff --git a/src/vs/base/browser/dom.ts b/src/vs/base/browser/dom.ts index 228550b57af..d0dfb1d885c 100644 --- a/src/vs/base/browser/dom.ts +++ b/src/vs/base/browser/dom.ts @@ -1041,3 +1041,16 @@ export function domContentLoaded(): TPromise { } }); } + +/** + * Find a value usable for a dom node size such that the likelihood that it would be + * displayed with constant screen pixels size is as high as possible. + * + * e.g. We would desire for the cursors to be 2px (CSS px) wide. Under a devicePixelRatio + * of 1.25, the cursor will be 2.5 screen pixels wide. Depending on how the dom node aligns/"snaps" + * with the screen pixels, it will sometimes be rendered with 2 screen pixels, and sometimes with 3 screen pixels. + */ +export function computeScreenAwareSize(cssPx: number): number { + const screenPx = window.devicePixelRatio * cssPx; + return Math.max(1, Math.floor(screenPx)) / window.devicePixelRatio; +} diff --git a/src/vs/editor/browser/viewParts/rulers/rulers.css b/src/vs/editor/browser/viewParts/rulers/rulers.css index 3012d205f67..d3d2d26ec95 100644 --- a/src/vs/editor/browser/viewParts/rulers/rulers.css +++ b/src/vs/editor/browser/viewParts/rulers/rulers.css @@ -5,6 +5,5 @@ .monaco-editor .view-ruler { position: absolute; - width: 1px; top: 0; } \ No newline at end of file diff --git a/src/vs/editor/browser/viewParts/rulers/rulers.ts b/src/vs/editor/browser/viewParts/rulers/rulers.ts index 852eb07fb2c..6a5e95b0b8c 100644 --- a/src/vs/editor/browser/viewParts/rulers/rulers.ts +++ b/src/vs/editor/browser/viewParts/rulers/rulers.ts @@ -13,6 +13,7 @@ import { RenderingContext, RestrictedRenderingContext } from 'vs/editor/common/v import * as viewEvents from 'vs/editor/common/view/viewEvents'; import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; import { editorRuler } from 'vs/editor/common/view/editorColorRegistry'; +import * as dom from 'vs/base/browser/dom'; export class Rulers extends ViewPart { @@ -69,11 +70,12 @@ export class Rulers extends ViewPart { } if (currentCount < desiredCount) { - // Add more rulers + const rulerWidth = dom.computeScreenAwareSize(1); let addCount = desiredCount - currentCount; while (addCount > 0) { let node = createFastDomNode(document.createElement('div')); node.setClassName('view-ruler'); + node.setWidth(rulerWidth); this.domNode.appendChild(node); this._renderedRulers.push(node); addCount--; -- GitLab From b275782509b8444c71e75273878b4703059e70d8 Mon Sep 17 00:00:00 2001 From: isidor Date: Wed, 14 Jun 2017 16:38:33 +0200 Subject: [PATCH 0823/1347] fileService.resolveFiles --- src/vs/platform/files/common/files.ts | 5 +++++ .../workbench/services/files/electron-browser/fileService.ts | 4 ++++ src/vs/workbench/services/files/node/fileService.ts | 4 ++++ src/vs/workbench/test/workbenchTestServices.ts | 4 ++++ 4 files changed, 17 insertions(+) diff --git a/src/vs/platform/files/common/files.ts b/src/vs/platform/files/common/files.ts index 94d4d0295dd..93cbdb6f3f9 100644 --- a/src/vs/platform/files/common/files.ts +++ b/src/vs/platform/files/common/files.ts @@ -43,6 +43,11 @@ export interface IFileService { */ resolveFile(resource: URI, options?: IResolveFileOptions): TPromise; + /** + * Same as resolveFile but supports resolving mulitple resources in parallel. + */ + resolveFiles(toResolve: { resource: URI, options?: IResolveFileOptions }[]): TPromise; + /** *Finds out if a file identified by the resource exists. */ diff --git a/src/vs/workbench/services/files/electron-browser/fileService.ts b/src/vs/workbench/services/files/electron-browser/fileService.ts index 0fba07f5e29..bca7ac11986 100644 --- a/src/vs/workbench/services/files/electron-browser/fileService.ts +++ b/src/vs/workbench/services/files/electron-browser/fileService.ts @@ -186,6 +186,10 @@ export class FileService implements IFileService { return this.raw.resolveFile(resource, options); } + public resolveFiles(toResolve: { resource: uri, options?: IResolveFileOptions }[]): TPromise { + return this.raw.resolveFiles(toResolve); + } + public existsFile(resource: uri): TPromise { return this.raw.existsFile(resource); } diff --git a/src/vs/workbench/services/files/node/fileService.ts b/src/vs/workbench/services/files/node/fileService.ts index a00926d40bb..a0e9e75e967 100644 --- a/src/vs/workbench/services/files/node/fileService.ts +++ b/src/vs/workbench/services/files/node/fileService.ts @@ -157,6 +157,10 @@ export class FileService implements IFileService { return this.resolve(resource, options); } + public resolveFiles(toResolve: { resource: uri, options?: IResolveFileOptions }[]): TPromise { + return TPromise.join(toResolve.map(resourceAndOptions => this.resolve(resourceAndOptions.resource, resourceAndOptions.options))); + } + public existsFile(resource: uri): TPromise { return this.resolveFile(resource).then(() => true, () => false); } diff --git a/src/vs/workbench/test/workbenchTestServices.ts b/src/vs/workbench/test/workbenchTestServices.ts index dc3c013b404..3b299beef00 100644 --- a/src/vs/workbench/test/workbenchTestServices.ts +++ b/src/vs/workbench/test/workbenchTestServices.ts @@ -625,6 +625,10 @@ export class TestFileService implements IFileService { }); } + resolveFiles(toResolve: { resource: URI, options?: IResolveFileOptions }[]): TPromise { + return TPromise.join(toResolve.map(resourceAndOption => this.resolveFile(resourceAndOption.resource, resourceAndOption.options))); + } + existsFile(resource: URI): TPromise { return TPromise.as(null); } -- GitLab From cf82d0c894f813fdf93da910ecab4f90a76aa716 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Wed, 14 Jun 2017 16:42:13 +0200 Subject: [PATCH 0824/1347] Fixes #28542: Set indent guides and cursors width with values that maximize the likelihood that all are rendered with equal screen width --- .../editor/browser/viewParts/indentGuides/indentGuides.css | 1 - src/vs/editor/browser/viewParts/indentGuides/indentGuides.ts | 4 +++- src/vs/editor/browser/viewParts/viewCursors/viewCursor.ts | 5 +++-- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/vs/editor/browser/viewParts/indentGuides/indentGuides.css b/src/vs/editor/browser/viewParts/indentGuides/indentGuides.css index 7cd5f89fd9f..45992137d18 100644 --- a/src/vs/editor/browser/viewParts/indentGuides/indentGuides.css +++ b/src/vs/editor/browser/viewParts/indentGuides/indentGuides.css @@ -9,5 +9,4 @@ */ .monaco-editor .lines-content .cigr { position: absolute; - width: 1px; } diff --git a/src/vs/editor/browser/viewParts/indentGuides/indentGuides.ts b/src/vs/editor/browser/viewParts/indentGuides/indentGuides.ts index 5b3a301abc0..caa4f1449a8 100644 --- a/src/vs/editor/browser/viewParts/indentGuides/indentGuides.ts +++ b/src/vs/editor/browser/viewParts/indentGuides/indentGuides.ts @@ -12,6 +12,7 @@ import { RenderingContext } from 'vs/editor/common/view/renderingContext'; import * as viewEvents from 'vs/editor/common/view/viewEvents'; import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; import { editorIndentGuides } from 'vs/editor/common/view/editorColorRegistry'; +import * as dom from 'vs/base/browser/dom'; export class IndentGuidesOverlay extends DynamicViewOverlay { @@ -85,6 +86,7 @@ export class IndentGuidesOverlay extends DynamicViewOverlay { const tabSize = this._context.model.getTabSize(); const tabWidth = tabSize * this._spaceWidth; const lineHeight = this._lineHeight; + const indentGuideWidth = dom.computeScreenAwareSize(1); let output: string[] = []; for (let lineNumber = visibleStartLineNumber; lineNumber <= visibleEndLineNumber; lineNumber++) { @@ -94,7 +96,7 @@ export class IndentGuidesOverlay extends DynamicViewOverlay { let result = ''; let left = 0; for (let i = 0; i < indent; i++) { - result += `
    `; + result += `
    `; left += tabWidth; } diff --git a/src/vs/editor/browser/viewParts/viewCursors/viewCursor.ts b/src/vs/editor/browser/viewParts/viewCursors/viewCursor.ts index babe35b4178..5288f92d7ea 100644 --- a/src/vs/editor/browser/viewParts/viewCursors/viewCursor.ts +++ b/src/vs/editor/browser/viewParts/viewCursors/viewCursor.ts @@ -12,6 +12,7 @@ import { Configuration } from 'vs/editor/browser/config/configuration'; import { ViewContext } from 'vs/editor/common/view/viewContext'; import { RenderingContext, RestrictedRenderingContext } from 'vs/editor/common/view/renderingContext'; import * as viewEvents from 'vs/editor/common/view/viewEvents'; +import * as dom from 'vs/base/browser/dom'; export interface IViewCursorRenderData { domNode: HTMLElement; @@ -137,9 +138,9 @@ export class ViewCursor { } let width: number; if (this._cursorStyle === TextEditorCursorStyle.Line) { - width = 2; + width = dom.computeScreenAwareSize(2); } else { - width = 1; + width = dom.computeScreenAwareSize(1); } const top = ctx.getVerticalOffsetForLineNumber(this._position.lineNumber) - ctx.bigNumbersDelta; return new ViewCursorRenderData(top, visibleRange.left, width, ''); -- GitLab From 5de63ca0e29d7e32297b2de3e0ea860c99940f78 Mon Sep 17 00:00:00 2001 From: isidor Date: Wed, 14 Jun 2017 16:41:12 +0200 Subject: [PATCH 0825/1347] explorerModel: Model --- .../parts/files/common/explorerModel.ts | 45 ++++++++++++++++++- 1 file changed, 43 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/files/common/explorerModel.ts b/src/vs/workbench/parts/files/common/explorerModel.ts index f7463ababd9..7dfe1c667fa 100644 --- a/src/vs/workbench/parts/files/common/explorerModel.ts +++ b/src/vs/workbench/parts/files/common/explorerModel.ts @@ -7,11 +7,12 @@ import URI from 'vs/base/common/uri'; import paths = require('vs/base/common/paths'); +import { ResourceMap } from 'vs/base/common/map'; +import { isLinux } from 'vs/base/common/platform'; import { IFileStat, isEqual, isParent, isEqualOrParent } from 'vs/platform/files/common/files'; import { IEditorInput } from 'vs/platform/editor/common/editor'; +import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { IEditorGroup, toResource } from 'vs/workbench/common/editor'; -import { ResourceMap } from 'vs/base/common/map'; -import { isLinux } from 'vs/base/common/platform'; export enum StatType { FILE, @@ -19,6 +20,46 @@ export enum StatType { ANY } +export class Model { + + private _roots: FileStat[]; + + constructor( @IWorkspaceContextService private contextService: IWorkspaceContextService) { + const setRoots = () => this._roots = this.contextService.getWorkspace2().roots.map(uri => new FileStat(uri)); + this.contextService.onDidChangeWorkspaceRoots(() => setRoots()); + setRoots(); + } + + public get roots(): FileStat[] { + return this._roots; + } + + /** + * Returns a child stat from this stat that matches with the provided path. + * Starts matching from the first root. + * Will return "null" in case the child does not exist. + */ + public findAll(resource: URI): FileStat[] { + return this.roots.map(root => root.find(resource)).filter(stat => !!stat); + } + + public findFirst(resource: URI): FileStat { + for (let root of this.roots) { + const result = root.find(resource); + if (result) { + return result; + } + } + + return null; + } + + public rootForResource(resource: URI): FileStat { + // TODO@Isidor temporary until we have a utility method for this + return this.roots[0]; + } +} + export class FileStat implements IFileStat { public resource: URI; public name: string; -- GitLab From 27272d8cb8e5c3f299c102163f42affae7ed2663 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Wed, 14 Jun 2017 16:53:55 +0200 Subject: [PATCH 0826/1347] fix decoration render option test failure --- .../test/browser/services/decorationRenderOptions.test.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/editor/test/browser/services/decorationRenderOptions.test.ts b/src/vs/editor/test/browser/services/decorationRenderOptions.test.ts index d68266803a7..00132c93923 100644 --- a/src/vs/editor/test/browser/services/decorationRenderOptions.test.ts +++ b/src/vs/editor/test/browser/services/decorationRenderOptions.test.ts @@ -67,7 +67,7 @@ suite('Decoration Render Options', () => { var s = new CodeEditorServiceImpl(themeService, styleSheet); s.registerDecorationType('example', options); var sheet = readStyleSheet(styleSheet); - assert.equal(sheet, '.monaco-editor .ced-example-0 { background-color: rgb(255, 0, 0); }'); + assert.equal(sheet, '.monaco-editor .ced-example-0 { background-color: rgb(255, 0, 0); border-color: transparent; box-sizing: border-box; }'); colors = { editorBackground: '#EE0000', -- GitLab From 1e76d7a07fecc8b88bdd7938acf61ccbc52d7981 Mon Sep 17 00:00:00 2001 From: isidor Date: Wed, 14 Jun 2017 17:03:53 +0200 Subject: [PATCH 0827/1347] explorerViewer: take into account the model when getting children --- .../files/browser/views/explorerViewer.ts | 29 ++++++++++++++----- 1 file changed, 22 insertions(+), 7 deletions(-) diff --git a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts index 2464c18f1fc..04f7f093da8 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts @@ -31,7 +31,7 @@ import { DuplicateFileAction, ImportFileAction, IEditableData, IFileViewletState import { IDataSource, ITree, IAccessibilityProvider, IRenderer, ContextMenuEvent, ISorter, IFilter, IDragAndDrop, IDragAndDropData, IDragOverReaction, DRAG_OVER_ACCEPT_BUBBLE_DOWN, DRAG_OVER_ACCEPT_BUBBLE_DOWN_COPY, DRAG_OVER_ACCEPT_BUBBLE_UP, DRAG_OVER_ACCEPT_BUBBLE_UP_COPY, DRAG_OVER_REJECT } from 'vs/base/parts/tree/browser/tree'; import { DesktopDragAndDropData, ExternalElementsDragAndDropData } from 'vs/base/parts/tree/browser/treeDnd'; import { ClickBehavior, DefaultController } from 'vs/base/parts/tree/browser/treeDefaults'; -import { FileStat, NewStatPlaceholder } from 'vs/workbench/parts/files/common/explorerModel'; +import { FileStat, NewStatPlaceholder, Model } from 'vs/workbench/parts/files/common/explorerModel'; import { DragMouseEvent, IMouseEvent } from 'vs/base/browser/mouseEvent'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; import { IPartService } from 'vs/workbench/services/part/common/partService'; @@ -51,6 +51,16 @@ import { IBackupFileService } from 'vs/workbench/services/backup/common/backup'; import { attachInputBoxStyler } from 'vs/platform/theme/common/styler'; import { IThemeService } from 'vs/platform/theme/common/themeService'; +// Multiple of the same folder in the explorer - id needs to get more complex, add index for the parent +// check context menu actions +// special context menu actions for root +// more checks might be needed for drag n drop +// step2: deleting one of the root folders +// Resolve me all the expansion state in one go +// revealing an element might be tricky if it is in two workspaces, in that case just reveal the first to not break. Not a common scenario + +// files.exclude, for each of the roots ask the configurations service for files.exclude + export class FileDataSource implements IDataSource { constructor( @IProgressService private progressService: IProgressService, @@ -61,14 +71,18 @@ export class FileDataSource implements IDataSource { ) { } public getId(tree: ITree, stat: FileStat): string { - return stat.getId(); + // TODO@Isidor take the id of the root into account + return `:${stat.getId()}`; } - public hasChildren(tree: ITree, stat: FileStat): boolean { - return stat.isDirectory; + public hasChildren(tree: ITree, stat: FileStat | Model): boolean { + return stat instanceof Model || (stat instanceof FileStat && stat.isDirectory); } - public getChildren(tree: ITree, stat: FileStat): TPromise { + public getChildren(tree: ITree, stat: FileStat | Model): TPromise { + if (stat instanceof Model) { + return TPromise.as(stat.roots); + } // Return early if stat is already resolved if (stat.isDirectoryResolved) { @@ -110,8 +124,8 @@ export class FileDataSource implements IDataSource { } // Return if root reached - const workspace = this.contextService.getWorkspace(); - if (workspace && stat.resource.toString() === workspace.resource.toString()) { + const workspace = this.contextService.getWorkspace2(); + if (workspace && workspace.roots.filter(root => root.toString() === stat.resource.toString())) { return TPromise.as(null); } @@ -558,6 +572,7 @@ export class FileFilter implements IFilter { const excludesConfig = (configuration && configuration.files && configuration.files.exclude) || Object.create(null); const needsRefresh = !objects.equals(this.hiddenExpression, excludesConfig); + // This needs to be per folder this.hiddenExpression = objects.clone(excludesConfig); // do not keep the config, as it gets mutated under our hoods return needsRefresh; -- GitLab From c3e8d3a3231e1a6766be1f9c573b64d9eed0ae49 Mon Sep 17 00:00:00 2001 From: isidor Date: Wed, 14 Jun 2017 17:17:58 +0200 Subject: [PATCH 0828/1347] explorerView: use isCreated to minimize use of root --- .../parts/files/browser/views/explorerView.ts | 26 +++++++++++++------ 1 file changed, 18 insertions(+), 8 deletions(-) diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index a2c1f5fd485..0a5dd614e82 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -14,6 +14,7 @@ import labels = require('vs/base/common/labels'); import paths = require('vs/base/common/paths'); import { Action, IAction } from 'vs/base/common/actions'; import { prepareActions } from 'vs/workbench/browser/actions'; +import { memoize } from 'vs/base/common/decorators'; import { ITree } from 'vs/base/parts/tree/browser/tree'; import { Tree } from 'vs/base/parts/tree/browser/treeImpl'; import { IFilesConfiguration, ExplorerFolderContext, FilesExplorerFocussedContext, ExplorerFocussedContext } from 'vs/workbench/parts/files/common/files'; @@ -26,7 +27,7 @@ import { IEditorGroupService } from 'vs/workbench/services/group/common/groupSer import * as DOM from 'vs/base/browser/dom'; import { CollapseAction } from 'vs/workbench/browser/viewlet'; import { CollapsibleView, IViewletViewOptions } from 'vs/workbench/parts/views/browser/views'; -import { FileStat } from 'vs/workbench/parts/files/common/explorerModel'; +import { FileStat, Model } from 'vs/workbench/parts/files/common/explorerModel'; import { IListService } from 'vs/platform/list/browser/listService'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; import { IPartService } from 'vs/workbench/services/part/common/partService'; @@ -300,7 +301,7 @@ export class ExplorerView extends CollapsibleView { lastActiveFileResource = URI.parse(this.settings[ExplorerView.MEMENTO_LAST_ACTIVE_FILE_RESOURCE]); } - if (lastActiveFileResource && this.root && this.root.find(lastActiveFileResource)) { + if (lastActiveFileResource && this.isCreated && this.root.find(lastActiveFileResource)) { this.editorService.openEditor({ resource: lastActiveFileResource, options: { revealIfVisible: true } }).done(null, errors.onUnexpectedError); return refreshPromise; @@ -338,6 +339,15 @@ export class ExplorerView extends CollapsibleView { return this.explorerViewer ? (this.explorerViewer.getInput()) : null; } + private get isCreated(): boolean { + return this.explorerViewer && this.explorerViewer.getInput(); + } + + @memoize + private get model(): Model { + return this.instantiationService.createInstance(Model); + } + public createViewer(container: Builder): ITree { const dataSource = this.instantiationService.createInstance(FileDataSource); const renderer = this.instantiationService.createInstance(FileRenderer, this.viewletState); @@ -405,7 +415,7 @@ export class ExplorerView extends CollapsibleView { } private onFileOperation(e: FileOperationEvent): void { - if (!this.root) { + if (!this.isCreated) { return; // ignore if not yet created } @@ -561,7 +571,7 @@ export class ExplorerView extends CollapsibleView { const added = e.getAdded(); const deleted = e.getDeleted(); - if (!this.root) { + if (!this.isCreated) { return false; } @@ -681,7 +691,7 @@ export class ExplorerView extends CollapsibleView { } // First time refresh: Receive target through active editor input or selection and also include settings from previous session - if (!this.root) { + if (!this.isCreated) { const activeFile = this.getActiveFile(); if (activeFile) { targetsToResolve.push(activeFile); @@ -706,7 +716,7 @@ export class ExplorerView extends CollapsibleView { const modelStat = FileStat.create(stat, options.resolveTo); // First time refresh: The stat becomes the input of the viewer - if (!this.root) { + if (!this.isCreated) { explorerPromise = this.explorerViewer.setInput(modelStat).then(() => { // Make sure to expand all folders that where expanded in the previous session @@ -778,7 +788,7 @@ export class ExplorerView extends CollapsibleView { } // First try to get the stat object from the input to avoid a roundtrip - if (!this.root) { + if (!this.isCreated) { return TPromise.as(null); } @@ -849,7 +859,7 @@ export class ExplorerView extends CollapsibleView { public shutdown(): void { // Keep list of expanded folders to restore on next load - if (this.root) { + if (this.isCreated) { const expanded = this.explorerViewer.getExpandedElements() .filter((e: FileStat) => e.resource.toString() !== this.contextService.getWorkspace().resource.toString()) .map((e: FileStat) => e.resource.toString()); -- GitLab From 21a2765e44c7f915b5d2c1e03748bcccde0d74ec Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Wed, 14 Jun 2017 17:19:48 +0200 Subject: [PATCH 0829/1347] [json] update service (for #28010) --- extensions/json/server/npm-shrinkwrap.json | 4 ++-- extensions/json/server/package.json | 2 +- .../test/browser/services/decorationRenderOptions.test.ts | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/extensions/json/server/npm-shrinkwrap.json b/extensions/json/server/npm-shrinkwrap.json index d199f7b2a0f..ae1d50bd689 100644 --- a/extensions/json/server/npm-shrinkwrap.json +++ b/extensions/json/server/npm-shrinkwrap.json @@ -43,9 +43,9 @@ "resolved": "https://registry.npmjs.org/request-light/-/request-light-0.2.1.tgz" }, "vscode-json-languageservice": { - "version": "2.0.9", + "version": "2.0.10", "from": "vscode-json-languageservice@next", - "resolved": "https://registry.npmjs.org/vscode-json-languageservice/-/vscode-json-languageservice-2.0.9.tgz" + "resolved": "https://registry.npmjs.org/vscode-json-languageservice/-/vscode-json-languageservice-2.0.10.tgz" }, "vscode-jsonrpc": { "version": "3.1.0-alpha.1", diff --git a/extensions/json/server/package.json b/extensions/json/server/package.json index 6c643c0f542..2897fd255db 100644 --- a/extensions/json/server/package.json +++ b/extensions/json/server/package.json @@ -10,7 +10,7 @@ "dependencies": { "jsonc-parser": "^0.4.2", "request-light": "^0.2.1", - "vscode-json-languageservice": "^2.0.9", + "vscode-json-languageservice": "^2.0.10", "vscode-languageserver": "^3.1.0-alpha.1", "vscode-nls": "^2.0.2" }, diff --git a/src/vs/editor/test/browser/services/decorationRenderOptions.test.ts b/src/vs/editor/test/browser/services/decorationRenderOptions.test.ts index 00132c93923..8194b3badcc 100644 --- a/src/vs/editor/test/browser/services/decorationRenderOptions.test.ts +++ b/src/vs/editor/test/browser/services/decorationRenderOptions.test.ts @@ -67,7 +67,7 @@ suite('Decoration Render Options', () => { var s = new CodeEditorServiceImpl(themeService, styleSheet); s.registerDecorationType('example', options); var sheet = readStyleSheet(styleSheet); - assert.equal(sheet, '.monaco-editor .ced-example-0 { background-color: rgb(255, 0, 0); border-color: transparent; box-sizing: border-box; }'); + assert.equal(sheet, '.monaco-editor .ced-example-0 { background-color: rgb(255, 0, 0); bordcer-color: transparent; box-sizing: border-box; }'); colors = { editorBackground: '#EE0000', -- GitLab From 24090b6a46973762e9253a72829ca1efc757157d Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Wed, 14 Jun 2017 17:31:58 +0200 Subject: [PATCH 0830/1347] Fix typo --- .../test/browser/services/decorationRenderOptions.test.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/editor/test/browser/services/decorationRenderOptions.test.ts b/src/vs/editor/test/browser/services/decorationRenderOptions.test.ts index 8194b3badcc..00132c93923 100644 --- a/src/vs/editor/test/browser/services/decorationRenderOptions.test.ts +++ b/src/vs/editor/test/browser/services/decorationRenderOptions.test.ts @@ -67,7 +67,7 @@ suite('Decoration Render Options', () => { var s = new CodeEditorServiceImpl(themeService, styleSheet); s.registerDecorationType('example', options); var sheet = readStyleSheet(styleSheet); - assert.equal(sheet, '.monaco-editor .ced-example-0 { background-color: rgb(255, 0, 0); bordcer-color: transparent; box-sizing: border-box; }'); + assert.equal(sheet, '.monaco-editor .ced-example-0 { background-color: rgb(255, 0, 0); border-color: transparent; box-sizing: border-box; }'); colors = { editorBackground: '#EE0000', -- GitLab From 8a4016440b7a74af9a9bebdc05d0af597bce6918 Mon Sep 17 00:00:00 2001 From: isidor Date: Wed, 14 Jun 2017 17:36:34 +0200 Subject: [PATCH 0831/1347] explorerView: reduce use of root more --- .../parts/files/browser/views/explorerView.ts | 51 +++++++++---------- 1 file changed, 25 insertions(+), 26 deletions(-) diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index 0a5dd614e82..acc79c91173 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -301,7 +301,7 @@ export class ExplorerView extends CollapsibleView { lastActiveFileResource = URI.parse(this.settings[ExplorerView.MEMENTO_LAST_ACTIVE_FILE_RESOURCE]); } - if (lastActiveFileResource && this.isCreated && this.root.find(lastActiveFileResource)) { + if (lastActiveFileResource && this.isCreated && this.model.findFirst(lastActiveFileResource)) { this.editorService.openEditor({ resource: lastActiveFileResource, options: { revealIfVisible: true } }).done(null, errors.onUnexpectedError); return refreshPromise; @@ -420,25 +420,24 @@ export class ExplorerView extends CollapsibleView { } let modelElement: FileStat; - let parent: FileStat; + let parents: FileStat[]; let parentResource: URI; - let parentElement: FileStat; // Add if (e.operation === FileOperation.CREATE || e.operation === FileOperation.IMPORT || e.operation === FileOperation.COPY) { const addedElement = e.target; parentResource = URI.file(paths.dirname(addedElement.resource.fsPath)); - parentElement = this.root.find(parentResource); + parents = this.model.findAll(parentResource); - if (parentElement) { + if (parents.length) { // Add the new file to its parent (Model) const childElement = FileStat.create(addedElement); - parentElement.removeChild(childElement); // make sure to remove any previous version of the file if any - parentElement.addChild(childElement); + parents[0].removeChild(childElement); // make sure to remove any previous version of the file if any + parents[0].addChild(childElement); // Refresh the Parent (View) - this.explorerViewer.refresh(parentElement).then(() => { + this.explorerViewer.refresh(parents).then(() => { return this.reveal(childElement, 0.5).then(() => { // Focus new element @@ -465,16 +464,16 @@ export class ExplorerView extends CollapsibleView { // Handle Rename if (oldParentResource && newParentResource && oldParentResource.toString() === newParentResource.toString()) { - modelElement = this.root.find(oldResource); + modelElement = this.model.findFirst(oldResource); if (modelElement) { // Rename File (Model) modelElement.rename(newElement); // Update Parent (View) - parent = modelElement.parent; - if (parent) { - this.explorerViewer.refresh(parent).done(() => { + parents = this.model.findAll(modelElement.parent.resource); + if (parents.length) { + this.explorerViewer.refresh(parents).done(() => { // Select in Viewer if set if (restoreFocus) { @@ -487,21 +486,21 @@ export class ExplorerView extends CollapsibleView { // Handle Move else if (oldParentResource && newParentResource) { - const oldParent = this.root.find(oldParentResource); - const newParent = this.root.find(newParentResource); - modelElement = this.root.find(oldResource); + const oldParents = this.model.findAll(oldParentResource); + const newParents = this.model.findAll(newParentResource); + modelElement = this.model.findFirst(oldResource); - if (oldParent && newParent && modelElement) { + if (oldParents.length && newParents.length && modelElement) { // Move in Model - modelElement.move(newParent, (callback: () => void) => { + modelElement.move(newParents[0], (callback: () => void) => { // Update old parent - this.explorerViewer.refresh(oldParent, true).done(callback, errors.onUnexpectedError); + this.explorerViewer.refresh(oldParents, true).done(callback, errors.onUnexpectedError); }, () => { // Update new parent - this.explorerViewer.refresh(newParent, true).done(() => this.explorerViewer.expand(newParent), errors.onUnexpectedError); + this.explorerViewer.refresh(newParents, true).done(() => this.explorerViewer.expand(newParents[0]), errors.onUnexpectedError); }); } } @@ -509,16 +508,16 @@ export class ExplorerView extends CollapsibleView { // Delete else if (e.operation === FileOperation.DELETE) { - modelElement = this.root.find(e.resource); + modelElement = this.model.findFirst(e.resource); if (modelElement && modelElement.parent) { - parent = modelElement.parent; + parents = this.model.findAll(modelElement.parent.resource); // Remove Element from Parent (Model) - parent.removeChild(modelElement); + parents[0].removeChild(modelElement); // Refresh Parent (View) const restoreFocus = this.explorerViewer.isDOMFocused(); - this.explorerViewer.refresh(parent).done(() => { + this.explorerViewer.refresh(parents).done(() => { // Ensure viewer has keyboard focus if event originates from viewer if (restoreFocus) { @@ -592,8 +591,8 @@ export class ExplorerView extends CollapsibleView { } // Compute if parent is visible and added file not yet part of it - const parentStat = this.root.find(URI.file(parent)); - if (parentStat && parentStat.isDirectoryResolved && !this.root.find(change.resource)) { + const parentStat = this.model.findFirst(URI.file(parent)); + if (parentStat && parentStat.isDirectoryResolved && !this.model.findFirst(change.resource)) { return true; } @@ -610,7 +609,7 @@ export class ExplorerView extends CollapsibleView { continue; // out of workspace file } - if (this.root.find(del.resource)) { + if (this.model.findFirst(del.resource)) { return true; } } -- GitLab From 476504aecfe2eada6f00e969e7dcb72f09a5be8e Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 14 Jun 2017 18:41:25 +0200 Subject: [PATCH 0832/1347] Text disappeared after update to 1.13 [Bug] (fixes #28619) --- extensions/markdown/package.json | 2 +- src/vs/editor/browser/standalone/media/standalone-tokens.css | 2 +- src/vs/workbench/electron-browser/media/shell.css | 2 +- .../workbench/parts/terminal/electron-browser/media/widgets.css | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/extensions/markdown/package.json b/extensions/markdown/package.json index 15c27055fe0..cbcb63c5531 100644 --- a/extensions/markdown/package.json +++ b/extensions/markdown/package.json @@ -161,7 +161,7 @@ }, "markdown.preview.fontFamily": { "type": "string", - "default": "system-ui, 'Segoe WPC', 'Segoe UI', 'HelveticaNeue-Light', 'Ubuntu', 'Droid Sans', sans-serif", + "default": "-apple-system, BlinkMacSystemFont, 'Segoe WPC', 'Segoe UI', 'HelveticaNeue-Light', 'Ubuntu', 'Droid Sans', sans-serif", "description": "%markdown.preview.fontFamily.desc%" }, "markdown.preview.fontSize": { diff --git a/src/vs/editor/browser/standalone/media/standalone-tokens.css b/src/vs/editor/browser/standalone/media/standalone-tokens.css index de07f233940..b815c5e181c 100644 --- a/src/vs/editor/browser/standalone/media/standalone-tokens.css +++ b/src/vs/editor/browser/standalone/media/standalone-tokens.css @@ -6,7 +6,7 @@ /* Default standalone editor font */ .monaco-editor { - font-family: system-ui, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", "Ubuntu", "Droid Sans", sans-serif; + font-family: -apple-system, BlinkMacSystemFont, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", "Ubuntu", "Droid Sans", sans-serif; } .monaco-menu .monaco-action-bar.vertical .action-item .action-label:focus { diff --git a/src/vs/workbench/electron-browser/media/shell.css b/src/vs/workbench/electron-browser/media/shell.css index 5696fc87867..f734da27292 100644 --- a/src/vs/workbench/electron-browser/media/shell.css +++ b/src/vs/workbench/electron-browser/media/shell.css @@ -15,7 +15,7 @@ /* Font Families (with CJK support) */ -.monaco-shell { font-family: system-ui, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", "Ubuntu", "Droid Sans", sans-serif; } +.monaco-shell { font-family: -apple-system, BlinkMacSystemFont, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", "Ubuntu", "Droid Sans", sans-serif; } .monaco-shell:lang(zh-Hans) { font-family: -apple-system, BlinkMacSystemFont, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", "Noto Sans", "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", "Source Han Sans SC", "Source Han Sans CN", "Source Han Sans", sans-serif; } .monaco-shell:lang(zh-Hant) { font-family: -apple-system, BlinkMacSystemFont, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", "Noto Sans", "Microsoft Jhenghei", "PingFang TC", "Source Han Sans TC", "Source Han Sans", "Source Han Sans TW", sans-serif; } .monaco-shell:lang(ja) { font-family: -apple-system, BlinkMacSystemFont, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", "Noto Sans", "Meiryo", "Hiragino Kaku Gothic Pro", "Source Han Sans J", "Source Han Sans JP", "Source Han Sans", "Sazanami Gothic", "IPA Gothic", sans-serif; } diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/widgets.css b/src/vs/workbench/parts/terminal/electron-browser/media/widgets.css index 2549ad70163..10751297b59 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/media/widgets.css +++ b/src/vs/workbench/parts/terminal/electron-browser/media/widgets.css @@ -12,7 +12,7 @@ } .monaco-workbench .terminal-message-widget { - font-family: system-ui, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", "Ubuntu", "Droid Sans", sans-serif; + font-family: -apple-system, BlinkMacSystemFont, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", "Ubuntu", "Droid Sans", sans-serif; font-size: 14px; line-height: 19px; padding: 4px 5px; -- GitLab From d639a81baa76ae912e6a2b48fc7e3849ff4661ed Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 14 Jun 2017 19:08:19 +0200 Subject: [PATCH 0833/1347] The unsaved (dot) indicator doesn't update when file is opened from the source code diff section (fixes #28515) --- .../common/editor/editorStacksModel.ts | 28 ++++++++++++++++--- .../test/browser/editorStacksModel.test.ts | 18 ++++++++++++ 2 files changed, 42 insertions(+), 4 deletions(-) diff --git a/src/vs/workbench/common/editor/editorStacksModel.ts b/src/vs/workbench/common/editor/editorStacksModel.ts index c6bd0d5602b..48f7308f2a3 100644 --- a/src/vs/workbench/common/editor/editorStacksModel.ts +++ b/src/vs/workbench/common/editor/editorStacksModel.ts @@ -277,8 +277,7 @@ export class EditorGroup implements IEditorGroup { targetIndex--; // accomodate for the fact that the preview editor closes } - this.closeEditor(this.preview, !makeActive); // optimization to prevent multiple setActive() in one call - this.splice(targetIndex, false, editor); + this.replaceEditor(this.preview, editor, targetIndex, !makeActive); } this.preview = editor; @@ -345,10 +344,31 @@ export class EditorGroup implements IEditorGroup { })); } + public replaceEditor(toReplace: EditorInput, replaceWidth: EditorInput, replaceIndex:number, openNext = true): void { + const event = this.doCloseEditor(toReplace, openNext); // optimization to prevent multiple setActive() in one call + + // We want to first add the new editor into our model before emitting the close event because + // firing the close event can trigger a dispose on the same editor that is now being added. + // This can lead into opening a disposed editor which is not what we want. + this.splice(replaceIndex, false, replaceWidth); + + if (event) { + this.fireEvent(this._onEditorClosed, event, true); + } + } + public closeEditor(editor: EditorInput, openNext = true): void { + const event = this.doCloseEditor(editor, openNext); + + if (event) { + this.fireEvent(this._onEditorClosed, event, true); + } + } + + private doCloseEditor(editor: EditorInput, openNext = true): EditorCloseEvent { const index = this.indexOf(editor); if (index === -1) { - return; // not found + return null; // not found } // Active Editor closed @@ -376,7 +396,7 @@ export class EditorGroup implements IEditorGroup { this.splice(index, true); // Event - this.fireEvent(this._onEditorClosed, { editor, pinned, index, group: this }, true); + return { editor, pinned, index, group: this }; } public closeEditors(except: EditorInput, direction?: Direction): void { diff --git a/src/vs/workbench/test/browser/editorStacksModel.test.ts b/src/vs/workbench/test/browser/editorStacksModel.test.ts index 8d96c2e5c80..3df007262ae 100644 --- a/src/vs/workbench/test/browser/editorStacksModel.test.ts +++ b/src/vs/workbench/test/browser/editorStacksModel.test.ts @@ -1764,6 +1764,24 @@ suite('Editor Stacks Model', () => { assert.equal(input1.isDisposed(), false); }); + test('Stack - Multiple Editors - Editor Not Disposed after Closing when opening Modified side (Diff Editor)', function () { + const model = create(); + + const group1 = model.openGroup('group1'); + + const input1 = input(); + const input2 = input(); + + const diffInput = new DiffEditorInput('name', 'description', input1, input2); + + group1.openEditor(diffInput, { pinned: false, active: true }); + group1.openEditor(input1, { pinned: false, active: true }); + + assert.equal(diffInput.isDisposed(), true); + assert.equal(input2.isDisposed(), true); + assert.equal(input1.isDisposed(), false); + }); + test('Stack - Multiple Editors - Editor Disposed on Close (same input, files)', function () { const model = create(); -- GitLab From 555df42805abcd9074de87aa532d860341508dfb Mon Sep 17 00:00:00 2001 From: t-amqi Date: Wed, 14 Jun 2017 12:01:28 -0700 Subject: [PATCH 0834/1347] Add task entry to top-level menu --- src/vs/code/electron-main/menus.ts | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index a2193ec6244..7c7cde56a15 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -263,6 +263,11 @@ export class CodeMenu { const helpMenuItem = new MenuItem({ label: this.mnemonicLabel(nls.localize({ key: 'mHelp', comment: ['&& denotes a mnemonic'] }, "&&Help")), submenu: helpMenu, role: 'help' }); this.setHelpMenu(helpMenu); + // Tasks + const taskMenu = new Menu(); + const taskMenuItem = new MenuItem({ label: this.mnemonicLabel(nls.localize({ key: 'mTask', comment: ['&& denotes a mnemonic'] }, "&&Tasks")), submenu: taskMenu }); + this.setTaskMenu(taskMenu); + // Menu Structure if (macApplicationMenuItem) { menubar.append(macApplicationMenuItem); @@ -274,6 +279,7 @@ export class CodeMenu { menubar.append(viewMenuItem); menubar.append(gotoMenuItem); menubar.append(debugMenuItem); + menubar.append(taskMenuItem); if (macWindowMenuItem) { menubar.append(macWindowMenuItem); @@ -901,6 +907,24 @@ export class CodeMenu { } } + private setTaskMenu(taskMenu: Electron.Menu): void { + const runTask = this.createMenuItem(nls.localize({ key: 'miRunTask', comment: ['&& denotes a mnemonic'] }, "&&Run Task..."), 'workbench.action.tasks.runTask'); + const restartTask = this.createMenuItem(nls.localize({ key: 'miRestartTask', comment: ['&& denotes a mnemonic'] }, "R&&estart Task"), 'workbench.action.tasks.restartTask'); + const terminateTask = this.createMenuItem(nls.localize({ key: 'miTerminateTask', comment: ['&& denotes a mnemonic'] }, "&&Terminate Task"), 'workbench.action.tasks.terminate'); + const buildTask = this.createMenuItem(nls.localize({ key: 'miBuildTask', comment: ['&& denotes a mnemonic'] }, "&&Build Task"), 'workbench.action.tasks.build'); + const testTask = this.createMenuItem(nls.localize({ key: 'miTestTask', comment: ['&& denotes a mnemonic'] }, "Test T&&ask"), 'workbench.action.tasks.test'); + const showTaskLog = this.createMenuItem(nls.localize({ key: 'miShowTaskLog', comment: ['&& denotes a mnemonic'] }, "&&Show Task Log"), 'workbench.action.tasks.showLog'); + + [ + showTaskLog, + runTask, + restartTask, + terminateTask, + buildTask, + testTask + ].forEach(item => taskMenu.append(item)); + } + private openAccessibilityOptions(): void { let win = new BrowserWindow({ alwaysOnTop: true, -- GitLab From bd0101a9ff45d5ec40f8544d4d81926ad6fc5a95 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Wed, 14 Jun 2017 21:18:39 +0200 Subject: [PATCH 0835/1347] hygiene --- src/vs/workbench/common/editor/editorStacksModel.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/common/editor/editorStacksModel.ts b/src/vs/workbench/common/editor/editorStacksModel.ts index 48f7308f2a3..dd41ad0eb1e 100644 --- a/src/vs/workbench/common/editor/editorStacksModel.ts +++ b/src/vs/workbench/common/editor/editorStacksModel.ts @@ -344,7 +344,7 @@ export class EditorGroup implements IEditorGroup { })); } - public replaceEditor(toReplace: EditorInput, replaceWidth: EditorInput, replaceIndex:number, openNext = true): void { + public replaceEditor(toReplace: EditorInput, replaceWidth: EditorInput, replaceIndex: number, openNext = true): void { const event = this.doCloseEditor(toReplace, openNext); // optimization to prevent multiple setActive() in one call // We want to first add the new editor into our model before emitting the close event because -- GitLab From 6802b7d4d41e2695b21ad53d8544371022937950 Mon Sep 17 00:00:00 2001 From: t-amqi Date: Wed, 14 Jun 2017 12:52:17 -0700 Subject: [PATCH 0836/1347] Remove #28565 --- src/vs/code/electron-main/menus.ts | 2 -- .../quickopen/browser/commandsHandler.ts | 22 ------------------- .../browser/quickopen.contribution.ts | 6 +---- 3 files changed, 1 insertion(+), 29 deletions(-) diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index 7c7cde56a15..8679eabeeef 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -592,7 +592,6 @@ export class CodeMenu { const output = this.createMenuItem(nls.localize({ key: 'miToggleOutput', comment: ['&& denotes a mnemonic'] }, "&&Output"), 'workbench.action.output.toggleOutput'); const debugConsole = this.createMenuItem(nls.localize({ key: 'miToggleDebugConsole', comment: ['&& denotes a mnemonic'] }, "De&&bug Console"), 'workbench.debug.action.toggleRepl'); const integratedTerminal = this.createMenuItem(nls.localize({ key: 'miToggleIntegratedTerminal', comment: ['&& denotes a mnemonic'] }, "&&Integrated Terminal"), 'workbench.action.terminal.toggleTerminal'); - const taskMenu = this.createMenuItem(nls.localize({ key: 'miShowTask', comment: ['&& denotes a mnemonic'] }, "Show Tas&&ks..."), 'workbench.action.showTasks'); const problems = this.createMenuItem(nls.localize({ key: 'miMarker', comment: ['&& denotes a mnemonic'] }, "&&Problems"), 'workbench.actions.view.problems'); let additionalViewlets: Electron.MenuItem; @@ -664,7 +663,6 @@ export class CodeMenu { problems, debugConsole, integratedTerminal, - taskMenu, __separator__(), fullscreen, toggleZenMode, diff --git a/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts b/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts index 21076a5084e..cf9fd534f85 100644 --- a/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts +++ b/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts @@ -149,28 +149,6 @@ export class ShowAllCommandsAction extends Action { } } -export class ShowTasksAction extends Action { - - public static ID = 'workbench.action.showTasks'; - public static LABEL = nls.localize('showTasks', "Show Task Menu"); - - constructor( - id: string, - label: string, - @IQuickOpenService private quickOpenService: IQuickOpenService, - @IConfigurationService private configurationService: IConfigurationService - ) { - super(id, label); - } - - public run(context?: any): TPromise { - const value = `${ALL_COMMANDS_PREFIX}tasks`; - this.quickOpenService.show(value); - - return TPromise.as(null); - } -} - export class ClearCommandHistoryAction extends Action { public static ID = 'workbench.action.clearCommandHistory'; diff --git a/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts b/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts index e46b5cd8432..606e882af9b 100644 --- a/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts +++ b/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts @@ -13,7 +13,7 @@ import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/workbench/common/actionRegistry'; import { KeyMod, KeyCode } from 'vs/base/common/keyCodes'; import { GotoSymbolAction, GOTO_SYMBOL_PREFIX, SCOPE_PREFIX } from 'vs/workbench/parts/quickopen/browser/gotoSymbolHandler'; -import { ShowAllCommandsAction, ALL_COMMANDS_PREFIX, ClearCommandHistoryAction, ShowTasksAction } from 'vs/workbench/parts/quickopen/browser/commandsHandler'; +import { ShowAllCommandsAction, ALL_COMMANDS_PREFIX, ClearCommandHistoryAction } from 'vs/workbench/parts/quickopen/browser/commandsHandler'; import { GotoLineAction, GOTO_LINE_PREFIX } from 'vs/workbench/parts/quickopen/browser/gotoLineHandler'; import { HELP_PREFIX } from 'vs/workbench/parts/quickopen/browser/helpHandler'; import { VIEW_PICKER_PREFIX, OpenViewPickerAction, QuickOpenViewPickerAction } from 'vs/workbench/parts/quickopen/browser/viewPickerHandler'; @@ -40,10 +40,6 @@ registry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenViewPickerAct primary: KeyMod.CtrlCmd | KeyCode.KEY_Q, mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_Q }, linux: { primary: null } }), 'Quick Open View'); -registry.registerWorkbenchAction(new SyncActionDescriptor(ShowTasksAction, ShowTasksAction.ID, ShowTasksAction.LABEL, { - primary: KeyMod.CtrlCmd | KeyMod.Alt | KeyCode.KEY_T -}), 'Show Task Menu'); - // Register Quick Open Handler Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpenHandler( -- GitLab From f0e428ac8f74feae028953bb099f11af1e7ddf8d Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Wed, 14 Jun 2017 13:37:50 -0700 Subject: [PATCH 0837/1347] Configure copying to test repo --- .github/copycat.yml | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 .github/copycat.yml diff --git a/.github/copycat.yml b/.github/copycat.yml new file mode 100644 index 00000000000..eccccc16b00 --- /dev/null +++ b/.github/copycat.yml @@ -0,0 +1,5 @@ +{ + perform: true, + target_owner: 'chrmarti', + target_repo: 'testissues' +} \ No newline at end of file -- GitLab From 2ebf3751e45378db505889760409864bb29507c3 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Wed, 14 Jun 2017 14:01:01 -0700 Subject: [PATCH 0838/1347] Initial nsfw prototype --- npm-shrinkwrap.json | 5 ++++ package.json | 1 + src/typings/nsfw.d.ts | 10 ++++++++ .../node/watcher/nsfw/nsfwWatcherService.ts | 23 +++++++++++++++++++ .../files/node/watcher/unix/watcherApp.ts | 4 ++-- 5 files changed, 41 insertions(+), 2 deletions(-) create mode 100644 src/typings/nsfw.d.ts create mode 100644 src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts diff --git a/npm-shrinkwrap.json b/npm-shrinkwrap.json index a1d1223cab2..4c28065065d 100644 --- a/npm-shrinkwrap.json +++ b/npm-shrinkwrap.json @@ -302,6 +302,11 @@ "from": "normalize-path@>=2.0.1 <3.0.0", "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-2.0.1.tgz" }, + "nsfw": { + "version": "1.0.15", + "from": "nsfw@1.0.15", + "resolved": "https://registry.npmjs.org/nsfw/-/nsfw-1.0.15.tgz" + }, "object.omit": { "version": "2.0.0", "from": "object.omit@>=2.0.0 <3.0.0", diff --git a/package.json b/package.json index 6536cecc87a..858436f3391 100644 --- a/package.json +++ b/package.json @@ -36,6 +36,7 @@ "minimist": "1.2.0", "native-keymap": "1.2.4", "node-pty": "0.6.8", + "nsfw": "1.0.15", "semver": "4.3.6", "v8-profiler": "jrieken/v8-profiler#vscode", "vscode-debugprotocol": "1.20.0", diff --git a/src/typings/nsfw.d.ts b/src/typings/nsfw.d.ts new file mode 100644 index 00000000000..8d80f6710b4 --- /dev/null +++ b/src/typings/nsfw.d.ts @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +declare module 'nsfw' { + function init(dir: string, ...args: any[]); + + export = init; +} diff --git a/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts b/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts new file mode 100644 index 00000000000..94462f18a40 --- /dev/null +++ b/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import nsfw = require('nsfw'); +import { IWatcherService, IWatcherRequest } from 'vs/workbench/services/files/node/watcher/unix/watcher'; +import { TPromise } from "vs/base/common/winjs.base"; + +export class NsfwWatcherService implements IWatcherService { + public watch(request: IWatcherRequest): TPromise { + console.log('nsfw ' + nsfw); + console.log('basePath ' + request.basePath); + return new TPromise((c, e, p) => { + nsfw(request.basePath, events => { + console.log(events); + p(events); + }).then(watcher => { + return watcher.start(); + }); + }); + } +} diff --git a/src/vs/workbench/services/files/node/watcher/unix/watcherApp.ts b/src/vs/workbench/services/files/node/watcher/unix/watcherApp.ts index 7c91d6c73e3..6f0942f996e 100644 --- a/src/vs/workbench/services/files/node/watcher/unix/watcherApp.ts +++ b/src/vs/workbench/services/files/node/watcher/unix/watcherApp.ts @@ -6,9 +6,9 @@ import { Server } from 'vs/base/parts/ipc/node/ipc.cp'; import { WatcherChannel } from 'vs/workbench/services/files/node/watcher/unix/watcherIpc'; -import { ChokidarWatcherService } from 'vs/workbench/services/files/node/watcher/unix/chokidarWatcherService'; +import { NsfwWatcherService } from 'vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService'; const server = new Server(); -const service = new ChokidarWatcherService(); +const service = new NsfwWatcherService(); const channel = new WatcherChannel(service); server.registerChannel('watcher', channel); \ No newline at end of file -- GitLab From db82543ad9e061d7e2ef452563eef720bc7a3f29 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Wed, 14 Jun 2017 14:28:52 -0700 Subject: [PATCH 0839/1347] Uplevel xterm.js Fixes some bugs and adds the new find API --- npm-shrinkwrap.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/npm-shrinkwrap.json b/npm-shrinkwrap.json index a1d1223cab2..4705b55d2da 100644 --- a/npm-shrinkwrap.json +++ b/npm-shrinkwrap.json @@ -442,7 +442,7 @@ "xterm": { "version": "2.7.0", "from": "Tyriar/xterm.js#vscode-release/1.14", - "resolved": "git+https://github.com/Tyriar/xterm.js.git#7d3640ad17fbf69f1a1c776b6d08969e1da32875" + "resolved": "git+https://github.com/Tyriar/xterm.js.git#e6fe120ecf93e552573be45867ae03c880319e11" }, "yauzl": { "version": "2.3.1", -- GitLab From 5c39083a4cb514505bf9ec465502b4d49c958537 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 14 Jun 2017 15:22:31 -0700 Subject: [PATCH 0840/1347] Highlight this in Monokai (#28748) Fixes #28682 --- .../themes/dimmed-monokai-color-theme.json | 32 +++++++++---------- .../themes/monokai-color-theme.json | 7 ++++ 2 files changed, 22 insertions(+), 17 deletions(-) diff --git a/extensions/theme-monokai-dimmed/themes/dimmed-monokai-color-theme.json b/extensions/theme-monokai-dimmed/themes/dimmed-monokai-color-theme.json index 68aeef661f0..a0994a3ff9a 100644 --- a/extensions/theme-monokai-dimmed/themes/dimmed-monokai-color-theme.json +++ b/extensions/theme-monokai-dimmed/themes/dimmed-monokai-color-theme.json @@ -191,7 +191,7 @@ }, { "name": "Class Variable", - "scope": "variable.other, variable.js, punctuation.separator.variable", + "scope": "variable.js, punctuation.separator.variable", "settings": { "fontStyle": "\n \t\t\t", "foreground": "#6089B4" @@ -229,14 +229,6 @@ "foreground": "#6089B4" } }, - { - "name": "Function Call", - "scope": "meta.function-call", - "settings": { - "fontStyle": "\n \t\t\t", - "foreground": "#0080FF" - } - }, { "name": "Function Object", "scope": "meta.function-call.object", @@ -245,14 +237,6 @@ "foreground": "#9872A2" } }, - { - "name": "Function Call Variable", - "scope": "variable.other.property", - "settings": { - "fontStyle": "\n \t\t\t", - "foreground": "#9872A2" - } - }, { "name": "Keyword Control", "scope": "keyword.control", @@ -550,6 +534,20 @@ "settings": { "foreground": "#b267e6" } + }, + { + "name": "this.self", + "scope": "variable.language", + "settings": { + "foreground": "#c7444a" + } + }, + { + "name": "this.self", + "scope": "variable.language", + "settings": { + "foreground": "#c7444a" + } } ] } \ No newline at end of file diff --git a/extensions/theme-monokai/themes/monokai-color-theme.json b/extensions/theme-monokai/themes/monokai-color-theme.json index 693494c71de..c8182750c5c 100644 --- a/extensions/theme-monokai/themes/monokai-color-theme.json +++ b/extensions/theme-monokai/themes/monokai-color-theme.json @@ -378,6 +378,13 @@ "settings": { "foreground": "#b267e6" } + }, + { + "name": "this.self", + "scope": "variable.language", + "settings": { + "foreground": "#FD971F" + } } ] } \ No newline at end of file -- GitLab From 0b27a58395b7f7f2b70489e1fe24a973599fc8a7 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 14 Jun 2017 15:41:01 -0700 Subject: [PATCH 0841/1347] Fix #28749 - Webviews not opening on windows --- src/vs/code/electron-main/app.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/code/electron-main/app.ts b/src/vs/code/electron-main/app.ts index 8effa87307f..a9adcc1e33a 100644 --- a/src/vs/code/electron-main/app.ts +++ b/src/vs/code/electron-main/app.ts @@ -121,7 +121,7 @@ export class CodeApplication { }); const isValidWebviewSource = (source: string) => - !source || (source.toLowerCase() as any).startsWith(URI.file(this.environmentService.appRoot.toLowerCase()).toString()); + !source || (URI.parse(source.toLowerCase()).toString() as any).startsWith(URI.file(this.environmentService.appRoot.toLowerCase()).toString()); app.on('web-contents-created', (event, contents) => { contents.on('will-attach-webview', (event, webPreferences, params) => { -- GitLab From e727ec56577cca70d3b93b843c08975f79f764ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beatriz=20Magalha=CC=83es?= Date: Wed, 14 Jun 2017 23:44:39 +0100 Subject: [PATCH 0842/1347] Undo changes to files that shouldn't be modified --- build/lib/typescript/typescriptServices.js | 524 ++++++++++----------- src/typings/electron.d.ts | 2 +- 2 files changed, 263 insertions(+), 263 deletions(-) diff --git a/build/lib/typescript/typescriptServices.js b/build/lib/typescript/typescriptServices.js index 6cf24f63bf1..349ff6ad391 100644 --- a/build/lib/typescript/typescriptServices.js +++ b/build/lib/typescript/typescriptServices.js @@ -485,7 +485,7 @@ var ts; SymbolFlags[SymbolFlags["PropertyOrAccessor"] = 98308] = "PropertyOrAccessor"; SymbolFlags[SymbolFlags["Export"] = 7340032] = "Export"; /* @internal */ - // The set of things we consider semantically classifiable. Used to speed up the LS during + // The set of things we consider semantically classifiable. Used to speed up the LS during // classification. SymbolFlags[SymbolFlags["Classifiable"] = 788448] = "Classifiable"; })(ts.SymbolFlags || (ts.SymbolFlags = {})); @@ -1274,19 +1274,19 @@ var ts; ts.getNormalizedPathFromPathComponents = getNormalizedPathFromPathComponents; function getNormalizedPathComponentsOfUrl(url) { // Get root length of http://www.website.com/folder1/foler2/ - // In this example the root is: http://www.website.com/ + // In this example the root is: http://www.website.com/ // normalized path components should be ["http://www.website.com/", "folder1", "folder2"] var urlLength = url.length; // Initial root length is http:// part var rootLength = url.indexOf("://") + "://".length; while (rootLength < urlLength) { - // Consume all immediate slashes in the protocol + // Consume all immediate slashes in the protocol // eg.initial rootlength is just file:// but it needs to consume another "/" in file:/// if (url.charCodeAt(rootLength) === 47 /* slash */) { rootLength++; } else { - // non slash character means we continue proceeding to next component of root search + // non slash character means we continue proceeding to next component of root search break; } } @@ -1297,15 +1297,15 @@ var ts; // Find the index of "/" after website.com so the root can be http://www.website.com/ (from existing http://) var indexOfNextSlash = url.indexOf(ts.directorySeparator, rootLength); if (indexOfNextSlash !== -1) { - // Found the "/" after the website.com so the root is length of http://www.website.com/ + // Found the "/" after the website.com so the root is length of http://www.website.com/ // and get components afetr the root normally like any other folder components rootLength = indexOfNextSlash + 1; return normalizedPathComponents(url, rootLength); } else { - // Can't find the host assume the rest of the string as component + // Can't find the host assume the rest of the string as component // but make sure we append "/" to it as root is not joined using "/" - // eg. if url passed in was http://website.com we want to use root as [http://website.com/] + // eg. if url passed in was http://website.com we want to use root as [http://website.com/] // so that other path manipulations will be correct and it can be merged with relative paths correctly return [url + ts.directorySeparator]; } @@ -2580,7 +2580,7 @@ var ts; function computeLineAndCharacterOfPosition(lineStarts, position) { var lineNumber = ts.binarySearch(lineStarts, position); if (lineNumber < 0) { - // If the actual position was not found, + // If the actual position was not found, // the binary search returns the negative value of the next line start // e.g. if the line starts at [5, 10, 23, 80] and the position requested was 20 // then the search will return -2 @@ -2623,8 +2623,8 @@ var ts; // \u000D Carriage Return // \u2028 Line separator // \u2029 Paragraph separator - // Only the characters in Table 3 are treated as line terminators. Other new line or line - // breaking characters are treated as white space but not as line terminators. + // Only the characters in Table 3 are treated as line terminators. Other new line or line + // breaking characters are treated as white space but not as line terminators. return ch === 10 /* lineFeed */ || ch === 13 /* carriageReturn */ || ch === 8232 /* lineSeparator */ || @@ -2702,7 +2702,7 @@ var ts; } } ts.skipTrivia = skipTrivia; - // All conflict markers consist of the same character repeated seven times. If it is + // All conflict markers consist of the same character repeated seven times. If it is // a <<<<<<< or >>>>>>> marker then it is also followd by a space. var mergeConflictMarkerLength = "<<<<<<<".length; function isConflictMarkerTrivia(text, pos) { @@ -2747,12 +2747,12 @@ var ts; } return pos; } - // Extract comments from the given source text starting at the given position. If trailing is - // false, whitespace is skipped until the first line break and comments between that location - // and the next token are returned.If trailing is true, comments occurring between the given - // position and the next line break are returned.The return value is an array containing a - // TextRange for each comment. Single-line comment ranges include the beginning '//' characters - // but not the ending line break. Multi - line comment ranges include the beginning '/* and + // Extract comments from the given source text starting at the given position. If trailing is + // false, whitespace is skipped until the first line break and comments between that location + // and the next token are returned.If trailing is true, comments occurring between the given + // position and the next line break are returned.The return value is an array containing a + // TextRange for each comment. Single-line comment ranges include the beginning '//' characters + // but not the ending line break. Multi - line comment ranges include the beginning '/* and // ending '*/' characters.The return value is undefined if no comments were found. function getCommentRanges(text, pos, trailing) { var result; @@ -3699,7 +3699,7 @@ var ts; })(ts.ModuleInstanceState || (ts.ModuleInstanceState = {})); var ModuleInstanceState = ts.ModuleInstanceState; function getModuleInstanceState(node) { - // A module is uninstantiated if it contains only + // A module is uninstantiated if it contains only // 1. interface declarations, type alias declarations if (node.kind === 205 /* InterfaceDeclaration */ || node.kind === 206 /* TypeAliasDeclaration */) { return 0 /* NonInstantiated */; @@ -3739,7 +3739,7 @@ var ts; ts.getModuleInstanceState = getModuleInstanceState; var ContainerFlags; (function (ContainerFlags) { - // The current node is not a container, and no container manipulation should happen before + // The current node is not a container, and no container manipulation should happen before // recursing into it. ContainerFlags[ContainerFlags["None"] = 0] = "None"; // The current node is a container. It should be set as the current container (and block- @@ -3844,13 +3844,13 @@ var ts; if (name !== undefined) { // Check and see if the symbol table already has a symbol with this name. If not, // create a new symbol with this name and add it to the table. Note that we don't - // give the new symbol any flags *yet*. This ensures that it will not conflict + // give the new symbol any flags *yet*. This ensures that it will not conflict // witht he 'excludes' flags we pass in. // // If we do get an existing symbol, see if it conflicts with the new symbol we're // creating. For example, a 'var' symbol and a 'class' symbol will conflict within - // the same symbol table. If we have a conflict, report the issue on each - // declaration we have for this symbol, and then create a new symbol for this + // the same symbol table. If we have a conflict, report the issue on each + // declaration we have for this symbol, and then create a new symbol for this // declaration. // // If we created a new symbol, either because we didn't have a symbol with this name @@ -3904,7 +3904,7 @@ var ts; // ExportType, or ExportContainer flag, and an associated export symbol with all the correct flags set // on it. There are 2 main reasons: // - // 1. We treat locals and exports of the same name as mutually exclusive within a container. + // 1. We treat locals and exports of the same name as mutually exclusive within a container. // That means the binder will issue a Duplicate Identifier error if you mix locals and exports // with the same name in the same container. // TODO: Make this a more specific error and decouple it from the exclusion logic. @@ -3925,11 +3925,11 @@ var ts; } } } - // All container nodes are kept on a linked list in declaration order. This list is used by - // the getLocalNameOfContainer function in the type checker to validate that the local name + // All container nodes are kept on a linked list in declaration order. This list is used by + // the getLocalNameOfContainer function in the type checker to validate that the local name // used for a container is unique. function bindChildren(node) { - // Before we recurse into a node's chilren, we first save the existing parent, container + // Before we recurse into a node's chilren, we first save the existing parent, container // and block-container. Then after we pop out of processing the children, we restore // these saved values. var saveParent = parent; @@ -3943,9 +3943,9 @@ var ts; // may contain locals, we proactively initialize the .locals field. We do this because // it's highly likely that the .locals will be needed to place some child in (for example, // a parameter, or variable declaration). - // + // // However, we do not proactively create the .locals for block-containers because it's - // totally normal and common for block-containers to never actually have a block-scoped + // totally normal and common for block-containers to never actually have a block-scoped // variable in them. We don't want to end up allocating an object for every 'block' we // run into when most of them won't be necessary. // @@ -4005,7 +4005,7 @@ var ts; return 2 /* IsBlockScopedContainer */; case 182 /* Block */: // do not treat blocks directly inside a function as a block-scoped-container. - // Locals that reside in this block should go to the function locals. Othewise 'x' + // Locals that reside in this block should go to the function locals. Othewise 'x' // would not appear to be a redeclaration of a block scoped local in the following // example: // @@ -4018,7 +4018,7 @@ var ts; // the block, then there would be no collision. // // By not creating a new block-scoped-container here, we ensure that both 'var x' - // and 'let x' go into the Function-container's locals, and we do get a collision + // and 'let x' go into the Function-container's locals, and we do get a collision // conflict. return ts.isFunctionLike(node.parent) ? 0 /* None */ : 2 /* IsBlockScopedContainer */; } @@ -4150,8 +4150,8 @@ var ts; // For a given function symbol "<...>(...) => T" we want to generate a symbol identical // to the one we would get for: { <...>(...): T } // - // We do that by making an anonymous type literal symbol, and then setting the function - // symbol as its sole member. To the rest of the system, this symbol will be indistinguishable + // We do that by making an anonymous type literal symbol, and then setting the function + // symbol as its sole member. To the rest of the system, this symbol will be indistinguishable // from an actual type literal symbol you would have gotten had you used the long form. var symbol = createSymbol(131072 /* Signature */, getDeclarationName(node)); addDeclarationToSymbol(symbol, node, 131072 /* Signature */); @@ -4192,17 +4192,17 @@ var ts; function bind(node) { node.parent = parent; // First we bind declaration nodes to a symbol if possible. We'll both create a symbol - // and then potentially add the symbol to an appropriate symbol table. Possible + // and then potentially add the symbol to an appropriate symbol table. Possible // destination symbol tables are: - // + // // 1) The 'exports' table of the current container's symbol. // 2) The 'members' table of the current container's symbol. // 3) The 'locals' table of the current container. // - // However, not all symbols will end up in any of these tables. 'Anonymous' symbols + // However, not all symbols will end up in any of these tables. 'Anonymous' symbols // (like TypeLiterals for example) will not be put in any table. bindWorker(node); - // Then we recurse into the children of the node to bind them as well. For certain + // Then we recurse into the children of the node to bind them as well. For certain // symbols we do specialized work when we recurse. For example, we'll keep track of // the current 'container' node when it changes. This helps us know which symbol table // a local should go into for example. @@ -4324,9 +4324,9 @@ var ts; } var symbol = node.symbol; // TypeScript 1.0 spec (April 2014): 8.4 - // Every class automatically contains a static property member named 'prototype', the + // Every class automatically contains a static property member named 'prototype', the // type of which is an instantiation of the class type with type Any supplied as a type - // argument for each type parameter. It is an error to explicitly declare a static + // argument for each type parameter. It is an error to explicitly declare a static // property member with the name 'prototype'. // // Note: we check for this here because this class may be merging into a module. The @@ -4376,7 +4376,7 @@ var ts; else { declareSymbolAndAddToSymbolTable(node, 1 /* FunctionScopedVariable */, 107455 /* ParameterExcludes */); } - // If this is a property-parameter, then also declare the property symbol into the + // If this is a property-parameter, then also declare the property symbol into the // containing class. if (node.flags & 112 /* AccessibilityModifier */ && node.parent.kind === 137 /* Constructor */ && @@ -4456,7 +4456,7 @@ var ts; // b) any of it's children reported that it had an error. var thisNodeOrAnySubNodesHasError = ((node.parserContextFlags & 32 /* ThisNodeHasError */) !== 0) || ts.forEachChild(node, containsParseError); - // If so, mark ourselves accordingly. + // If so, mark ourselves accordingly. if (thisNodeOrAnySubNodesHasError) { node.parserContextFlags |= 128 /* ThisNodeOrAnySubNodesHasError */; } @@ -4491,13 +4491,13 @@ var ts; ts.getStartPosOfNode = getStartPosOfNode; // Returns true if this node is missing from the actual source code. 'missing' is different // from 'undefined/defined'. When a node is undefined (which can happen for optional nodes - // in the tree), it is definitel missing. HOwever, a node may be defined, but still be + // in the tree), it is definitel missing. HOwever, a node may be defined, but still be // missing. This happens whenever the parser knows it needs to parse something, but can't // get anything in the source code that it expects at that location. For example: // // let a: ; // - // Here, the Type in the Type-Annotation is not-optional (as there is a colon in the source + // Here, the Type in the Type-Annotation is not-optional (as there is a colon in the source // code). So the parser will attempt to parse out a type, and will create an actual node. // However, this node will be 'missing' in the sense that no actual source-code/tokens are // contained within it. @@ -4568,7 +4568,7 @@ var ts; isCatchClauseVariableDeclaration(declaration); } ts.isBlockOrCatchScoped = isBlockOrCatchScoped; - // Gets the nearest enclosing block scope container that has the provided node + // Gets the nearest enclosing block scope container that has the provided node // as a descendant, that is not the provided node. function getEnclosingBlockScopeContainer(node) { var current = node.parent; @@ -4662,7 +4662,7 @@ var ts; break; } if (errorNode === undefined) { - // If we don't have a better node, then just set the error on the first token of + // If we don't have a better node, then just set the error on the first token of // construct. return getSpanOfTokenAtPosition(sourceFile, node.pos); } @@ -4690,10 +4690,10 @@ var ts; } return node; } - // Returns the node flags for this node and all relevant parent nodes. This is done so that + // Returns the node flags for this node and all relevant parent nodes. This is done so that // nodes like variable declarations and binding elements can returned a view of their flags // that includes the modifiers from their container. i.e. flags like export/declare aren't - // stored on the variable declaration directly, but on the containing variable statement + // stored on the variable declaration directly, but on the containing variable statement // (if it has one). Similarly, flags for let/const are store on the variable declaration // list. By calling this function, all those flags are combined so that the client can treat // the node as if it actually had those flags. @@ -4994,7 +4994,7 @@ var ts; node = node.parent; break; case 132 /* Decorator */: - // Decorators are always applied outside of the body of a class or method. + // Decorators are always applied outside of the body of a class or method. if (node.parent.kind === 131 /* Parameter */ && isClassElement(node.parent.parent)) { // If the decorator's parent is a Parameter, we resolve the this container from // the grandparent class declaration. @@ -5050,7 +5050,7 @@ var ts; node = node.parent; break; case 132 /* Decorator */: - // Decorators are always applied outside of the body of a class or method. + // Decorators are always applied outside of the body of a class or method. if (node.parent.kind === 131 /* Parameter */ && isClassElement(node.parent.parent)) { // If the decorator's parent is a Parameter, we resolve the this container from // the grandparent class declaration. @@ -5326,7 +5326,7 @@ var ts; ts.getJSDocTemplateTag = getJSDocTemplateTag; function getCorrespondingJSDocParameterTag(parameter) { if (parameter.name && parameter.name.kind === 65 /* Identifier */) { - // If it's a parameter, see if the parent has a jsdoc comment with an @param + // If it's a parameter, see if the parent has a jsdoc comment with an @param // annotation. var parameterName = parameter.name.text; var docComment = parameter.parent.jsDocComment; @@ -6361,17 +6361,17 @@ var ts; // // 0 10 20 30 40 50 60 70 80 90 100 // ------------------------------------------------------------------------------------------------------- - // | / - // | /---- - // T1 | /---- - // | /---- - // | /---- + // | / + // | /---- + // T1 | /---- + // | /---- + // | /---- // ------------------------------------------------------------------------------------------------------- - // | \ - // | \ - // T2 | \ - // | \ - // | \ + // | \ + // | \ + // T2 | \ + // | \ + // | \ // ------------------------------------------------------------------------------------------------------- // // Merging these turns out to not be too difficult. First, determining the new start of the change is trivial @@ -6379,17 +6379,17 @@ var ts; // // 0 10 20 30 40 50 60 70 80 90 100 // ------------------------------------------------------------*------------------------------------------ - // | / - // | /---- - // T1 | /---- - // | /---- - // | /---- + // | / + // | /---- + // T1 | /---- + // | /---- + // | /---- // ----------------------------------------$-------------------$------------------------------------------ - // . | \ - // . | \ - // T2 . | \ - // . | \ - // . | \ + // . | \ + // . | \ + // T2 . | \ + // . | \ + // . | \ // ----------------------------------------------------------------------*-------------------------------- // // (Note the dots represent the newly inferrred start. @@ -6400,22 +6400,22 @@ var ts; // // 0 10 20 30 40 50 60 70 80 90 100 // --------------------------------------------------------------------------------*---------------------- - // | / - // | /---- - // T1 | /---- - // | /---- - // | /---- + // | / + // | /---- + // T1 | /---- + // | /---- + // | /---- // ------------------------------------------------------------$------------------------------------------ - // . | \ - // . | \ - // T2 . | \ - // . | \ - // . | \ + // . | \ + // . | \ + // T2 . | \ + // . | \ + // . | \ // ----------------------------------------------------------------------*-------------------------------- // // In other words (in this case), we're recognizing that the second edit happened after where the first edit // ended with a delta of 20 characters (60 - 40). Thus, if we go back in time to where the first edit started - // that's the same as if we started at char 80 instead of 60. + // that's the same as if we started at char 80 instead of 60. // // As it so happens, the same logic applies if the second edit precedes the first edit. In that case rahter // than pusing the first edit forward to match the second, we'll push the second edit forward to match the @@ -6425,7 +6425,7 @@ var ts; // semantics: { { start: 10, length: 70 }, newLength: 60 } // // The math then works out as follows. - // If we have { oldStart1, oldEnd1, newEnd1 } and { oldStart2, oldEnd2, newEnd2 } then we can compute the + // If we have { oldStart1, oldEnd1, newEnd1 } and { oldStart2, oldEnd2, newEnd2 } then we can compute the // final result like so: // // { @@ -6995,7 +6995,7 @@ var ts; if (setParentNodes) { fixupParentReferences(sourceFile); } - // If this is a javascript file, proactively see if we can get JSDoc comments for + // If this is a javascript file, proactively see if we can get JSDoc comments for // relevant nodes in the file. We'll use these to provide typing informaion if they're // available. if (ts.isJavaScript(fileName)) { @@ -7537,7 +7537,7 @@ var ts; // if we see "extends {}" then only treat the {} as what we're extending (and not // the class body) if we have: // - // extends {} { + // extends {} { // extends {}, // extends {} extends // extends {} implements @@ -9280,7 +9280,7 @@ var ts; expression = finishNode(propertyAccess); continue; } - // when in the [Decorator] context, we do not parse ElementAccess as it could be part of a ComputedPropertyName + // when in the [Decorator] context, we do not parse ElementAccess as it could be part of a ComputedPropertyName if (!inDecoratorContext() && parseOptional(18 /* OpenBracketToken */)) { var indexedAccess = createNode(159 /* ElementAccessExpression */, expression.pos); indexedAccess.expression = expression; @@ -9388,7 +9388,7 @@ var ts; case 23 /* CommaToken */: // foo, case 14 /* OpenBraceToken */: // foo { // We don't want to treat these as type arguments. Otherwise we'll parse this - // as an invocation expression. Instead, we want to parse out the expression + // as an invocation expression. Instead, we want to parse out the expression // in isolation from the type arguments. default: // Anything else treat as an expression. @@ -9560,7 +9560,7 @@ var ts; function parseFunctionBlock(allowYield, ignoreMissingOpenBrace, diagnosticMessage) { var savedYieldContext = inYieldContext(); setYieldContext(allowYield); - // We may be in a [Decorator] context when parsing a function expression or + // We may be in a [Decorator] context when parsing a function expression or // arrow function. The body of the function is not in [Decorator] context. var saveDecoratorContext = inDecoratorContext(); if (saveDecoratorContext) { @@ -10011,7 +10011,7 @@ var ts; default: if (decorators) { // We reached this point because we encountered decorators and/or modifiers and assumed a declaration - // would follow. For recovery and error reporting purposes, return an incomplete declaration. + // would follow. For recovery and error reporting purposes, return an incomplete declaration. var node = createMissingNode(221 /* MissingDeclaration */, true, ts.Diagnostics.Declaration_expected); node.pos = fullStart; node.decorators = decorators; @@ -10366,8 +10366,8 @@ var ts; } function parseClassExpression() { return parseClassDeclarationOrExpression( - /*fullStart*/ scanner.getStartPos(), - /*decorators*/ undefined, + /*fullStart*/ scanner.getStartPos(), + /*decorators*/ undefined, /*modifiers*/ undefined, 177 /* ClassExpression */); } function parseClassDeclaration(fullStart, decorators, modifiers) { @@ -11125,8 +11125,8 @@ var ts; ts.Debug.assert(end <= content.length); var tags; var pos; - // NOTE(cyrusn): This is essentially a handwritten scanner for JSDocComments. I - // considered using an actual Scanner, but this would complicate things. The + // NOTE(cyrusn): This is essentially a handwritten scanner for JSDocComments. I + // considered using an actual Scanner, but this would complicate things. The // scanner would need to know it was in a Doc Comment. Otherwise, it would then // produce comments *inside* the doc comment. In the end it was just easier to // write a simple scanner rather than go that route. @@ -12274,7 +12274,7 @@ var ts; } break; case 132 /* Decorator */: - // Decorators are resolved at the class declaration. Resolving at the parameter + // Decorators are resolved at the class declaration. Resolving at the parameter // or member would result in looking up locals in the method. // // function y() {} @@ -13690,7 +13690,7 @@ var ts; case 151 /* UnionType */: case 152 /* ParenthesizedType */: return isDeclarationVisible(node.parent); - // Default binding, import specifier and namespace import is visible + // Default binding, import specifier and namespace import is visible // only on demand so by default it is not visible case 213 /* ImportClause */: case 214 /* NamespaceImport */: @@ -17000,7 +17000,7 @@ var ts; if (assumeTrue) { // Assumed result is true. If check was not for a primitive type, remove all primitive types if (!typeInfo) { - return removeTypesFromUnionType(type, 258 /* StringLike */ | 132 /* NumberLike */ | 8 /* Boolean */ | 2097152 /* ESSymbol */, + return removeTypesFromUnionType(type, 258 /* StringLike */ | 132 /* NumberLike */ | 8 /* Boolean */ | 2097152 /* ESSymbol */, /*isOfTypeKind*/ true, false); } // Check was for a primitive type, return that primitive type if it is a subtype @@ -17737,7 +17737,7 @@ var ts; // c is represented in the tree as a spread element in an array literal. // But c really functions as a rest element, and its purpose is to provide // a contextual type for the right hand side of the assignment. Therefore, - // instead of calling checkExpression on "...c", which will give an error + // instead of calling checkExpression on "...c", which will give an error // if c is not iterable/array-like, we need to act as if we are trying to // get the contextual element type from it. So we do something similar to // getContextualTypeForElementExpression, which will crucially not error @@ -18641,7 +18641,7 @@ var ts; // We exclude union types because we may have a union of function types that happen to have // no common signatures. if (isTypeAny(funcType) || (!callSignatures.length && !constructSignatures.length && !(funcType.flags & 16384 /* Union */) && isTypeAssignableTo(funcType, globalFunctionType))) { - // The unknownType indicates that an error already occurred (and was reported). No + // The unknownType indicates that an error already occured (and was reported). No // need to report another error in this case. if (funcType !== unknownType && node.typeArguments) { error(node, ts.Diagnostics.Untyped_function_calls_may_not_accept_type_arguments); @@ -20415,7 +20415,7 @@ var ts; /** Checks a type reference node as an expression. */ function checkTypeNodeAsExpression(node) { // When we are emitting type metadata for decorators, we need to try to check the type - // as if it were an expression so that we can emit the type in a value position when we + // as if it were an expression so that we can emit the type in a value position when we // serialize the type metadata. if (node && node.kind === 144 /* TypeReference */) { var type = getTypeFromTypeNode(node); @@ -20911,7 +20911,7 @@ var ts; } else { var leftType = checkExpression(varExpr); - checkReferenceExpression(varExpr, ts.Diagnostics.Invalid_left_hand_side_in_for_of_statement, + checkReferenceExpression(varExpr, ts.Diagnostics.Invalid_left_hand_side_in_for_of_statement, /*constantVariableMessage*/ ts.Diagnostics.The_left_hand_side_of_a_for_of_statement_cannot_be_a_previously_defined_constant); // iteratedType will be undefined if the rightType was missing properties/signatures // required to get its iteratedType (like [Symbol.iterator] or next). This may be @@ -21945,7 +21945,7 @@ var ts; error(node.name, ts.Diagnostics.A_namespace_declaration_cannot_be_located_prior_to_a_class_or_function_with_which_it_is_merged); } } - // if the module merges with a class declaration in the same lexical scope, + // if the module merges with a class declaration in the same lexical scope, // we need to track this to ensure the correct emit. var mergedClass = ts.getDeclarationOfKind(symbol, 204 /* ClassDeclaration */); if (mergedClass && @@ -22605,7 +22605,7 @@ var ts; return getSymbolOfNode(entityName.parent); } if (entityName.parent.kind === 217 /* ExportAssignment */) { - return resolveEntityName(entityName, + return resolveEntityName(entityName, /*all meanings*/ 107455 /* Value */ | 793056 /* Type */ | 1536 /* Namespace */ | 8388608 /* Alias */); } if (entityName.kind !== 158 /* PropertyAccessExpression */) { @@ -23074,7 +23074,7 @@ var ts; // * The serialized type of an AccessorDeclaration is the serialized type of the return type annotation of its getter or parameter type annotation of its setter. // * The serialized type of any other FunctionLikeDeclaration is "Function". // * The serialized type of any other node is "void 0". - // + // // For rules on serializing type annotations, see `serializeTypeNode`. switch (node.kind) { case 204 /* ClassDeclaration */: return "Function"; @@ -23094,7 +23094,7 @@ var ts; // // * If the declaration is a class, the parameters of the first constructor with a body are used. // * If the declaration is function-like and has a body, the parameters of the function are used. - // + // // For the rules on serializing the type of each parameter declaration, see `serializeTypeOfDeclaration`. if (node) { var valueDeclaration; @@ -23162,7 +23162,7 @@ var ts; } function getReferencedValueSymbol(reference) { return getNodeLinks(reference).resolvedSymbol || - resolveName(reference, reference.text, 107455 /* Value */ | 1048576 /* ExportValue */ | 8388608 /* Alias */, + resolveName(reference, reference.text, 107455 /* Value */ | 1048576 /* ExportValue */ | 8388608 /* Alias */, /*nodeNotFoundMessage*/ undefined, undefined); } function getReferencedValueDeclaration(reference) { @@ -24494,7 +24494,7 @@ var ts; // we would write alias foo declaration when we visit it since it would now be marked as visible if (moduleElementEmitInfo) { if (moduleElementEmitInfo.node.kind === 212 /* ImportDeclaration */) { - // we have to create asynchronous output only after we have collected complete information + // we have to create asynchronous output only after we have collected complete information // because it is possible to enable multiple bindings as asynchronously visible moduleElementEmitInfo.isVisible = true; } @@ -24633,7 +24633,7 @@ var ts; return emitEntityName(type); } function emitEntityName(entityName) { - var visibilityResult = resolver.isEntityNameVisible(entityName, + var visibilityResult = resolver.isEntityNameVisible(entityName, // Aliases can be written asynchronously so use correct enclosing declaration entityName.parent.kind === 211 /* ImportEqualsDeclaration */ ? entityName.parent : enclosingDeclaration); handleSymbolAccessibilityError(visibilityResult); @@ -24845,7 +24845,7 @@ var ts; } } function writeImportEqualsDeclaration(node) { - // note usage of writer. methods instead of aliases created, just to make sure we are using + // note usage of writer. methods instead of aliases created, just to make sure we are using // correct writer especially to handle asynchronous alias writing emitJsDocComments(node); if (node.flags & 1 /* Export */) { @@ -24884,7 +24884,7 @@ var ts; } function writeImportDeclaration(node) { if (!node.importClause && !(node.flags & 1 /* Export */)) { - // do not write non-exported import declarations that don't have import clauses + // do not write non-exported import declarations that don't have import clauses return; } emitJsDocComments(node); @@ -25723,7 +25723,7 @@ var ts; : ts.shouldEmitToOwnFile(referencedFile, compilerOptions) ? ts.getOwnEmitOutputFilePath(referencedFile, host, ".d.ts") // Own output file so get the .d.ts file : ts.removeFileExtension(compilerOptions.out) + ".d.ts"; // Global out file - declFileName = ts.getRelativePathToDirectoryOrUrl(ts.getDirectoryPath(ts.normalizeSlashes(jsFilePath)), declFileName, host.getCurrentDirectory(), host.getCanonicalFileName, + declFileName = ts.getRelativePathToDirectoryOrUrl(ts.getDirectoryPath(ts.normalizeSlashes(jsFilePath)), declFileName, host.getCurrentDirectory(), host.getCanonicalFileName, /*isAbsolutePathAnUrl*/ false); referencePathsOutput += "/// " + newLine; } @@ -26191,7 +26191,7 @@ var ts; // If sourceroot option: Use the relative path corresponding to the common directory path // otherwise source locations relative to map file location var sourcesDirectoryPath = compilerOptions.sourceRoot ? host.getCommonSourceDirectory() : sourceMapDir; - sourceMapData.sourceMapSources.push(ts.getRelativePathToDirectoryOrUrl(sourcesDirectoryPath, node.fileName, host.getCurrentDirectory(), host.getCanonicalFileName, + sourceMapData.sourceMapSources.push(ts.getRelativePathToDirectoryOrUrl(sourcesDirectoryPath, node.fileName, host.getCurrentDirectory(), host.getCanonicalFileName, /*isAbsolutePathAnUrl*/ true)); sourceMapSourceIndex = sourceMapData.sourceMapSources.length - 1; // The one that can be used from program to get the actual source file @@ -26342,7 +26342,7 @@ var ts; if (!ts.isRootedDiskPath(sourceMapDir) && !ts.isUrl(sourceMapDir)) { // The relative paths are relative to the common directory sourceMapDir = ts.combinePaths(host.getCommonSourceDirectory(), sourceMapDir); - sourceMapData.jsSourceMappingURL = ts.getRelativePathToDirectoryOrUrl(ts.getDirectoryPath(ts.normalizePath(jsFilePath)), ts.combinePaths(sourceMapDir, sourceMapData.jsSourceMappingURL), host.getCurrentDirectory(), host.getCanonicalFileName, + sourceMapData.jsSourceMappingURL = ts.getRelativePathToDirectoryOrUrl(ts.getDirectoryPath(ts.normalizePath(jsFilePath)), ts.combinePaths(sourceMapDir, sourceMapData.jsSourceMappingURL), host.getCurrentDirectory(), host.getCanonicalFileName, /*isAbsolutePathAnUrl*/ true); } else { @@ -26759,7 +26759,7 @@ var ts; } else if (node.kind === 129 /* ComputedPropertyName */) { // if this is a decorated computed property, we will need to capture the result - // of the property expression so that we can apply decorators later. This is to ensure + // of the property expression so that we can apply decorators later. This is to ensure // we don't introduce unintended side effects: // // class C { @@ -27059,7 +27059,7 @@ var ts; write("]"); } else { - emitListWithSpread(elements, true, (node.flags & 512 /* MultiLine */) !== 0, + emitListWithSpread(elements, true, (node.flags & 512 /* MultiLine */) !== 0, /*trailingComma*/ elements.hasTrailingComma, true); } } @@ -27326,8 +27326,8 @@ var ts; } return false; } - // Returns 'true' if the code was actually indented, false otherwise. - // If the code is not indented, an optional valueToWriteWhenNotIndenting will be + // Returns 'true' if the code was actually indented, false otherwise. + // If the code is not indented, an optional valueToWriteWhenNotIndenting will be // emitted instead. function indentIfOnDifferentLines(parent, node1, node2, valueToWriteWhenNotIndenting) { var realNodesAreOnDifferentLines = !ts.nodeIsSynthesized(parent) && !nodeEndIsOnSameLineAsNodeStart(node1, node2); @@ -27706,7 +27706,7 @@ var ts; emit(node.whenFalse); decreaseIndentIf(indentedBeforeColon, indentedAfterColon); } - // Helper function to decrease the indent if we previously indented. Allows multiple + // Helper function to decrease the indent if we previously indented. Allows multiple // previous indent values to be considered at a time. This also allows caller to just // call this once, passing in all their appropriate indent values, instead of needing // to call this helper function multiple times. @@ -28748,7 +28748,7 @@ var ts; emitSignatureParameters(node); } if (!node.body) { - // There can be no body when there are parse errors. Just emit an empty block + // There can be no body when there are parse errors. Just emit an empty block // in that case. write(" { }"); } @@ -28776,7 +28776,7 @@ var ts; emitDownLevelExpressionFunctionBody(node, body); return; } - // For es6 and higher we can emit the expression as is. However, in the case + // For es6 and higher we can emit the expression as is. However, in the case // where the expression might end up looking like a block when emitted, we'll // also wrap it in parentheses first. For example if you have: a => {} // then we need to generate: a => ({}) @@ -29253,9 +29253,9 @@ var ts; } } // If the class has static properties, and it's a class expression, then we'll need - // to specialize the emit a bit. for a class expression of the form: + // to specialize the emit a bit. for a class expression of the form: // - // class C { static a = 1; static b = 2; ... } + // class C { static a = 1; static b = 2; ... } // // We'll emit: // @@ -29517,7 +29517,7 @@ var ts; // // The emit for a method is: // - // Object.defineProperty(C.prototype, "method", + // Object.defineProperty(C.prototype, "method", // __decorate([ // dec, // __param(0, dec2), @@ -29525,10 +29525,10 @@ var ts; // __metadata("design:paramtypes", [Object]), // __metadata("design:returntype", void 0) // ], C.prototype, "method", Object.getOwnPropertyDescriptor(C.prototype, "method"))); - // + // // The emit for an accessor is: // - // Object.defineProperty(C.prototype, "accessor", + // Object.defineProperty(C.prototype, "accessor", // __decorate([ // dec // ], C.prototype, "accessor", Object.getOwnPropertyDescriptor(C.prototype, "accessor"))); @@ -29610,7 +29610,7 @@ var ts; } function shouldEmitTypeMetadata(node) { // This method determines whether to emit the "design:type" metadata based on the node's kind. - // The caller should have already tested whether the node has decorators and whether the emitDecoratorMetadata + // The caller should have already tested whether the node has decorators and whether the emitDecoratorMetadata // compiler option is set. switch (node.kind) { case 136 /* MethodDeclaration */: @@ -29623,7 +29623,7 @@ var ts; } function shouldEmitReturnTypeMetadata(node) { // This method determines whether to emit the "design:returntype" metadata based on the node's kind. - // The caller should have already tested whether the node has decorators and whether the emitDecoratorMetadata + // The caller should have already tested whether the node has decorators and whether the emitDecoratorMetadata // compiler option is set. switch (node.kind) { case 136 /* MethodDeclaration */: @@ -29633,7 +29633,7 @@ var ts; } function shouldEmitParamTypesMetadata(node) { // This method determines whether to emit the "design:paramtypes" metadata based on the node's kind. - // The caller should have already tested whether the node has decorators and whether the emitDecoratorMetadata + // The caller should have already tested whether the node has decorators and whether the emitDecoratorMetadata // compiler option is set. switch (node.kind) { case 204 /* ClassDeclaration */: @@ -30386,7 +30386,7 @@ var ts; } function writeExportedName(node) { // do not record default exports - // they are local to module and never overwritten (explicitly skipped) by star export + // they are local to module and never overwritten (explicitly skipped) by star export if (node.kind !== 65 /* Identifier */ && node.flags & 256 /* Default */) { return; } @@ -30408,7 +30408,7 @@ var ts; } } function processTopLevelVariableAndFunctionDeclarations(node) { - // per ES6 spec: + // per ES6 spec: // 15.2.1.16.4 ModuleDeclarationInstantiation() Concrete Method // - var declarations are initialized to undefined - 14.a.ii // - function/generator declarations are instantiated - 16.a.iv @@ -30540,7 +30540,7 @@ var ts; // hoist variable if // - it is not block scoped // - it is top level block scoped - // if block scoped variables are nested in some another block then + // if block scoped variables are nested in some another block then // no other functions can use them except ones that are defined at least in the same block return (ts.getCombinedNodeFlags(node) & 12288 /* BlockScoped */) === 0 || ts.getEnclosingBlockScopeContainer(node).kind === 230 /* SourceFile */; @@ -30724,10 +30724,10 @@ var ts; // System modules has the following shape // System.register(['dep-1', ... 'dep-n'], function(exports) {/* module body function */}) // 'exports' here is a function 'exports(name: string, value: T): T' that is used to publish exported values. - // 'exports' returns its 'value' argument so in most cases expressions + // 'exports' returns its 'value' argument so in most cases expressions // that mutate exported values can be rewritten as: - // expr -> exports('name', expr). - // The only exception in this rule is postfix unary operators, + // expr -> exports('name', expr). + // The only exception in this rule is postfix unary operators, // see comment to 'emitPostfixUnaryExpression' for more details ts.Debug.assert(!exportFunctionForFile); // make sure that name of 'exports' function does not conflict with existing identifiers @@ -30769,8 +30769,8 @@ var ts; // factory function. var unaliasedModuleNames = []; // names of modules with no corresponding parameters in // factory function. - var importAliasNames = []; // names of the parameters in the factory function; these - // parameters need to match the indexes of the corresponding + var importAliasNames = []; // names of the parameters in the factory function; these + // parameters need to match the indexes of the corresponding // module names in aliasedModuleNames. // Fill in amd-dependency tags for (var _a = 0, _b = node.amdDependencies; _a < _b.length; _a++) { @@ -30863,7 +30863,7 @@ var ts; emitCaptureThisForNodeIfNecessary(node); emitLinesStartingAt(node.statements, startIndex); emitTempDeclarations(true); - // Emit exportDefault if it exists will happen as part + // Emit exportDefault if it exists will happen as part // or normal statement emit. } function emitExportEquals(emitAsReturn) { @@ -30993,7 +30993,7 @@ var ts; // emitting the module as well. return shouldEmitEnumDeclaration(node); } - // If this is the expression body of an arrow function that we're down-leveling, + // If this is the expression body of an arrow function that we're down-leveling, // then we don't want to emit comments when we emit the body. It will have already // been taken care of when we emitted the 'return' statement for the function // expression body. @@ -31719,7 +31719,7 @@ var ts; } else if (node.kind === 208 /* ModuleDeclaration */ && node.name.kind === 8 /* StringLiteral */ && (node.flags & 2 /* Ambient */ || ts.isDeclarationFile(file))) { // TypeScript 1.0 spec (April 2014): 12.1.6 - // An AmbientExternalModuleDeclaration declares an external module. + // An AmbientExternalModuleDeclaration declares an external module. // This type of declaration is permitted only in the global module. // The StringLiteral must specify a top - level external module name. // Relative external module names are not permitted @@ -31730,7 +31730,7 @@ var ts; var moduleName = nameLiteral.text; if (moduleName) { // TypeScript 1.0 spec (April 2014): 12.1.6 - // An ExternalImportDeclaration in anAmbientExternalModuleDeclaration may reference other external modules + // An ExternalImportDeclaration in anAmbientExternalModuleDeclaration may reference other external modules // only through top - level external module names. Relative external module names are not permitted. var searchName = ts.normalizePath(ts.combinePaths(basePath, moduleName)); ts.forEach(ts.supportedExtensions, function (extension) { return findModuleSourceFile(searchName + extension, nameLiteral); }); @@ -31848,7 +31848,7 @@ var ts; } } else if (firstExternalModuleSourceFile && languageVersion < 2 /* ES6 */ && !options.module) { - // We cannot use createDiagnosticFromNode because nodes do not have parents yet + // We cannot use createDiagnosticFromNode because nodes do not have parents yet var span = ts.getErrorSpanForNode(firstExternalModuleSourceFile, firstExternalModuleSourceFile.externalModuleIndicator); diagnostics.add(ts.createFileDiagnostic(firstExternalModuleSourceFile, span.start, span.length, ts.Diagnostics.Cannot_compile_modules_unless_the_module_flag_is_provided)); } @@ -31871,7 +31871,7 @@ var ts; commonSourceDirectory = computeCommonSourceDirectory(files); } if (commonSourceDirectory && commonSourceDirectory[commonSourceDirectory.length - 1] !== ts.directorySeparator) { - // Make sure directory path ends with directory separator so this string can directly + // Make sure directory path ends with directory separator so this string can directly // used to replace with "" to get the relative path of the source file and the relative path doesn't // start with / making it rooted path commonSourceDirectory += ts.directorySeparator; @@ -32477,14 +32477,14 @@ var ts; function getNavigateToItems(program, cancellationToken, searchValue, maxResultCount) { var patternMatcher = ts.createPatternMatcher(searchValue); var rawItems = []; - // Search the declarations in all files and output matched NavigateToItem into array of NavigateToItem[] + // Search the declarations in all files and output matched NavigateToItem into array of NavigateToItem[] ts.forEach(program.getSourceFiles(), function (sourceFile) { cancellationToken.throwIfCancellationRequested(); var nameToDeclarations = sourceFile.getNamedDeclarations(); for (var name_27 in nameToDeclarations) { var declarations = ts.getProperty(nameToDeclarations, name_27); if (declarations) { - // First do a quick check to see if the name of the declaration matches the + // First do a quick check to see if the name of the declaration matches the // last portion of the (possibly) dotted name they're searching for. var matches = patternMatcher.getMatchesForLastSegmentOfPattern(name_27); if (!matches) { @@ -32492,7 +32492,7 @@ var ts; } for (var _i = 0; _i < declarations.length; _i++) { var declaration = declarations[_i]; - // It was a match! If the pattern has dots in it, then also see if the + // It was a match! If the pattern has dots in it, then also see if the // declaration container matches as well. if (patternMatcher.patternContainsDots) { var containers = getContainers(declaration); @@ -32794,8 +32794,8 @@ var ts; } function isTopLevelFunctionDeclaration(functionDeclaration) { if (functionDeclaration.kind === 203 /* FunctionDeclaration */) { - // A function declaration is 'top level' if it contains any function declarations - // within it. + // A function declaration is 'top level' if it contains any function declarations + // within it. if (functionDeclaration.body && functionDeclaration.body.kind === 182 /* Block */) { // Proper function declarations can only have identifier names if (ts.forEach(functionDeclaration.body.statements, function (s) { return s.kind === 203 /* FunctionDeclaration */ && !isEmpty(s.name.text); })) { @@ -33076,8 +33076,8 @@ var ts; } function createPatternMatcher(pattern) { // We'll often see the same candidate string many times when searching (For example, when - // we see the name of a module that is used everywhere, or the name of an overload). As - // such, we cache the information we compute about the candidate for the life of this + // we see the name of a module that is used everywhere, or the name of an overload). As + // such, we cache the information we compute about the candidate for the life of this // pattern matcher so we don't have to compute it multiple times. var stringToWordSpans = {}; pattern = pattern.trim(); @@ -33160,7 +33160,7 @@ var ts; if (index > 0) { // c) If the part is entirely lowercase, then check if it is contained anywhere in the // candidate in a case insensitive manner. If so, return that there was a substring - // match. + // match. // // Note: We only have a substring match if the lowercase part is prefix match of some // word part. That way we don't match something like 'Class' when the user types 'a'. @@ -33169,7 +33169,7 @@ var ts; for (var _i = 0; _i < wordSpans.length; _i++) { var span = wordSpans[_i]; if (partStartsWith(candidate, span, chunk.text, true)) { - return createPatternMatch(PatternMatchKind.substring, punctuationStripped, + return createPatternMatch(PatternMatchKind.substring, punctuationStripped, /*isCaseSensitive:*/ partStartsWith(candidate, span, chunk.text, false)); } } @@ -33200,8 +33200,8 @@ var ts; if (isLowercase) { // f) Is the pattern a substring of the candidate starting on one of the candidate's word boundaries? // We could check every character boundary start of the candidate for the pattern. However, that's - // an m * n operation in the wost case. Instead, find the first instance of the pattern - // substring, and see if it starts on a capital letter. It seems unlikely that the user will try to + // an m * n operation in the wost case. Instead, find the first instance of the pattern + // substring, and see if it starts on a capital letter. It seems unlikely that the user will try to // filter the list based on a substring that starts on a capital letter and also with a lowercase one. // (Pattern: fogbar, Candidate: quuxfogbarFogBar). if (chunk.text.length < candidate.length) { @@ -33253,7 +33253,7 @@ var ts; // // c) If the word is entirely lowercase, then check if it is contained anywhere in the // candidate in a case insensitive manner. If so, return that there was a substring - // match. + // match. // // Note: We only have a substring match if the lowercase part is prefix match of // some word part. That way we don't match something like 'Class' when the user @@ -33267,7 +33267,7 @@ var ts; // e) If the word was not entirely lowercase, then attempt a camel cased match as // well. // - // f) The word is all lower case. Is it a case insensitive substring of the candidate starting + // f) The word is all lower case. Is it a case insensitive substring of the candidate starting // on a part boundary of the candidate? // // Only if all words have some sort of match is the pattern considered matched. @@ -33317,7 +33317,7 @@ var ts; // Note: we may have more pattern parts than candidate parts. This is because multiple // pattern parts may match a candidate part. For example "SiUI" against "SimpleUI". // We'll have 3 pattern parts Si/U/I against two candidate parts Simple/UI. However, U - // and I will both match in UI. + // and I will both match in UI. var currentCandidate = 0; var currentChunkSpan = 0; var firstMatch = undefined; @@ -33346,13 +33346,13 @@ var ts; // Consider the case of matching SiUI against SimpleUIElement. The candidate parts // will be Simple/UI/Element, and the pattern parts will be Si/U/I. We'll match 'Si' // against 'Simple' first. Then we'll match 'U' against 'UI'. However, we want to - // still keep matching pattern parts against that candidate part. + // still keep matching pattern parts against that candidate part. for (; currentChunkSpan < chunkCharacterSpans.length; currentChunkSpan++) { var chunkCharacterSpan = chunkCharacterSpans[currentChunkSpan]; if (gotOneMatchThisCandidate) { // We've already gotten one pattern part match in this candidate. We will // only continue trying to consumer pattern parts if the last part and this - // part are both upper case. + // part are both upper case. if (!isUpperCaseLetter(chunk.text.charCodeAt(chunkCharacterSpans[currentChunkSpan - 1].start)) || !isUpperCaseLetter(chunk.text.charCodeAt(chunkCharacterSpans[currentChunkSpan].start))) { break; @@ -33384,9 +33384,9 @@ var ts; ts.createPatternMatcher = createPatternMatcher; // Helper function to compare two matches to determine which is better. Matches are first // ordered by kind (so all prefix matches always beat all substring matches). Then, if the - // match is a camel case match, the relative weights of the match are used to determine - // which is better (with a greater weight being better). Then if the match is of the same - // type, then a case sensitive match is considered better than an insensitive one. + // match is a camel case match, the relative weights of the match are used to determine + // which is better (with a greater weight being better). Then if the match is of the same + // type, then a case sensitive match is considered better than an insensitive one. function patternMatchCompareTo(match1, match2) { return compareType(match1, match2) || compareCamelCase(match1, match2) || @@ -33436,7 +33436,7 @@ var ts; if (ch < 127 /* maxAsciiCharacter */ || !ts.isUnicodeIdentifierStart(ch, 2 /* Latest */)) { return false; } - // TODO: find a way to determine this for any unicode characters in a + // TODO: find a way to determine this for any unicode characters in a // non-allocating manner. var str = String.fromCharCode(ch); return str === str.toUpperCase(); @@ -33449,7 +33449,7 @@ var ts; if (ch < 127 /* maxAsciiCharacter */ || !ts.isUnicodeIdentifierStart(ch, 2 /* Latest */)) { return false; } - // TODO: find a way to determine this for any unicode characters in a + // TODO: find a way to determine this for any unicode characters in a // non-allocating manner. var str = String.fromCharCode(ch); return str === str.toLowerCase(); @@ -33498,7 +33498,7 @@ var ts; if (ch < 127 /* maxAsciiCharacter */) { return ch; } - // TODO: find a way to compute this for any unicode characters in a + // TODO: find a way to compute this for any unicode characters in a // non-allocating manner. return String.fromCharCode(ch).toLowerCase().charCodeAt(0); } @@ -33649,7 +33649,7 @@ var ts; var currentIsUpper = isUpperCaseLetter(identifier.charCodeAt(index)); // See if the casing indicates we're starting a new word. Note: if we're breaking on // words, then just seeing an upper case character isn't enough. Instead, it has to - // be uppercase and the previous character can't be uppercase. + // be uppercase and the previous character can't be uppercase. // // For example, breaking "AddMetadata" on words would make: Add Metadata // @@ -33673,9 +33673,9 @@ var ts; var SignatureHelp; (function (SignatureHelp) { // A partially written generic type expression is not guaranteed to have the correct syntax tree. the expression could be parsed as less than/greater than expression or a comma expression - // or some other combination depending on what the user has typed so far. For the purposes of signature help we need to consider any location after "<" as a possible generic type reference. - // To do this, the method will back parse the expression starting at the position required. it will try to parse the current expression as a generic type expression, if it did succeed it - // will return the generic identifier that started the expression (e.g. "foo" in "foo'. So, in the case where the last child is a comma, we increase the // arg count by one to compensate. // - // Note: this subtlety only applies to the last comma. If you had "Foo(a,," then - // we'll have: 'a' '' '' + // Note: this subtlety only applies to the last comma. If you had "Foo(a,," then + // we'll have: 'a' '' '' // That will give us 2 non-commas. We then add one for the last comma, givin us an // arg count of 3. var listChildren = argumentsList.getChildren(); @@ -34524,7 +34524,7 @@ var ts; var children = n.getChildren(); for (var _i = 0; _i < children.length; _i++) { var child = children[_i]; - var shouldDiveInChildNode = + var shouldDiveInChildNode = // previous token is enclosed somewhere in the child (child.pos <= previousToken.pos && child.end > previousToken.end) || // previous token ends exactly at the beginning of child @@ -34569,7 +34569,7 @@ var ts; } } ts.Debug.assert(startNode !== undefined || n.kind === 230 /* SourceFile */); - // Here we know that none of child token nodes embrace the position, + // Here we know that none of child token nodes embrace the position, // the only known case is when position is at the end of the file. // Try to find the rightmost token in the file without filtering. // Namely we are skipping the check: 'position < node.end' @@ -35031,9 +35031,9 @@ var ts; var startPos = (lastTokenInfo && lastTokenInfo.token.pos) || scanner.getStartPos(); return startPos < endPos && current !== 1 /* EndOfFileToken */ && !ts.isTrivia(current); } - // when containing node in the tree is token + // when containing node in the tree is token // but its kind differs from the kind that was returned by the scanner, - // then kind needs to be fixed. This might happen in cases + // then kind needs to be fixed. This might happen in cases // when parser interprets token differently, i.e keyword treated as identifier function fixTokenKind(tokenInfo, container) { if (ts.isToken(container) && tokenInfo.token.kind !== container.kind) { @@ -35555,17 +35555,17 @@ var ts; Rules.IsSameLineTokenOrBeforeMultilineBlockContext = function (context) { //// This check is mainly used inside SpaceBeforeOpenBraceInControl and SpaceBeforeOpenBraceInFunction. //// - //// Ex: + //// Ex: //// if (1) { .... //// * ) and { are on the same line so apply the rule. Here we don't care whether it's same or multi block context //// - //// Ex: + //// Ex: //// if (1) //// { ... } //// * ) and { are on differnet lines. We only need to format if the block is multiline context. So in this case we don't format. //// //// Ex: - //// if (1) + //// if (1) //// { ... //// } //// * ) and { are on differnet lines. We only need to format if the block is multiline context. So in this case we format. @@ -35841,9 +35841,9 @@ var ts; //// 4- Context rules with any token combination //// 5- Non-context rules with specific token combination //// 6- Non-context rules with any token combination - //// + //// //// The member rulesInsertionIndexBitmap is used to describe the number of rules - //// in each sub-bucket (above) hence can be used to know the index of where to insert + //// in each sub-bucket (above) hence can be used to know the index of where to insert //// the next rule. It's a bitmap which contains 6 different sections each is given 5 bits. //// //// Example: @@ -36037,7 +36037,7 @@ var ts; /// /// /// -/// +/// /// /* @internal */ var ts; @@ -36191,9 +36191,9 @@ var ts; } function findOutermostParent(position, expectedTokenKind, sourceFile) { var precedingToken = ts.findPrecedingToken(position, sourceFile); - // when it is claimed that trigger character was typed at given position + // when it is claimed that trigger character was typed at given position // we verify that there is a token with a matching kind whose end is equal to position (because the character was just typed). - // If this condition is not hold - then trigger character was typed in some other context, + // If this condition is not hold - then trigger character was typed in some other context, // i.e.in comment and thus should not trigger autoformatting if (!precedingToken || precedingToken.kind !== expectedTokenKind || @@ -36202,12 +36202,12 @@ var ts; } // walk up and search for the parent node that ends at the same position with precedingToken. // for cases like this - // + // // let x = 1; // while (true) { - // } + // } // after typing close curly in while statement we want to reformat just the while statement. - // However if we just walk upwards searching for the parent that has the same end value - + // However if we just walk upwards searching for the parent that has the same end value - // we'll end up with the whole source file. isListElement allows to stop on the list element level var current = precedingToken; while (current && @@ -36272,7 +36272,7 @@ var ts; // 'index' tracks the index of the most recent error that was checked. while (true) { if (index >= sorted.length) { - // all errors in the range were already checked -> no error in specified range + // all errors in the range were already checked -> no error in specified range return false; } var error = sorted[index]; @@ -36400,9 +36400,9 @@ var ts; var indentation = inheritedIndentation; if (indentation === -1 /* Unknown */) { if (isSomeBlock(node.kind)) { - // blocks should be indented in + // blocks should be indented in // - other blocks - // - source file + // - source file // - switch\default clauses if (isSomeBlock(parent.kind) || parent.kind === 230 /* SourceFile */ || @@ -36523,12 +36523,12 @@ var ts; // a useful observations when tracking context node // / // [a] - // / | \ + // / | \ // [b] [c] [d] - // node 'a' is a context node for nodes 'b', 'c', 'd' + // node 'a' is a context node for nodes 'b', 'c', 'd' // except for the leftmost leaf token in [b] - in this case context node ('e') is located somewhere above 'a' // this rule can be applied recursively to child nodes of 'a'. - // + // // context node is set to parent node value after processing every child node // context node is set to parent of the token after processing every token var childContextNode = contextNode; @@ -36630,7 +36630,7 @@ var ts; var tokenInfo = formattingScanner.readTokenInfo(parent); // consume the list end token only if it is still belong to the parent // there might be the case when current token matches end token but does not considered as one - // function (x: function) <-- + // function (x: function) <-- // without this check close paren will be interpreted as list end token for function expression which is wrong if (tokenInfo.token.kind === listEndToken && ts.rangeContainsRange(parent, tokenInfo.token)) { // consume list end token @@ -36747,7 +36747,7 @@ var ts; applyRuleEdits(rule, previousItem, previousStartLine, currentItem, currentStartLine); if (rule.Operation.Action & (2 /* Space */ | 8 /* Delete */) && currentStartLine !== previousStartLine) { lineAdded = false; - // Handle the case where the next line is moved to be the end of this line. + // Handle the case where the next line is moved to be the end of this line. // In this case we don't indent the next line in the next pass. if (currentParent.getStart(sourceFile) === currentItem.pos) { dynamicIndentation.recomputeIndentation(false); @@ -36755,7 +36755,7 @@ var ts; } else if (rule.Operation.Action & 4 /* NewLine */ && currentStartLine === previousStartLine) { lineAdded = true; - // Handle the case where token2 is moved to the new line. + // Handle the case where token2 is moved to the new line. // In this case we indent token2 in the next pass but we set // sameLineIndent flag to notify the indenter that the indentation is within the line. if (currentParent.getStart(sourceFile) === currentItem.pos) { @@ -37573,10 +37573,10 @@ var ts; var jsDocCommentParts = []; ts.forEach(declarations, function (declaration, indexOfDeclaration) { // Make sure we are collecting doc comment from declaration once, - // In case of union property there might be same declaration multiple times + // In case of union property there might be same declaration multiple times // which only varies in type parameter // Eg. let a: Array | Array; a.length - // The property length will have two declarations of property length coming + // The property length will have two declarations of property length coming // from Array - Array and Array if (ts.indexOf(declarations, declaration) === indexOfDeclaration) { var sourceFileOfDeclaration = ts.getSourceFileOfNode(declaration); @@ -37611,7 +37611,7 @@ var ts; return ts.map(ts.getJsDocComments(node, sourceFile), function (jsDocComment) { return { pos: jsDocComment.pos + "/*".length, - end: jsDocComment.end - "*/".length // Trim off comment end indicator + end: jsDocComment.end - "*/".length // Trim off comment end indicator }; }); } @@ -37713,7 +37713,7 @@ var ts; if (isParamTag(pos, end, sourceFile)) { var blankLineCount = 0; var recordedParamTag = false; - // Consume leading spaces + // Consume leading spaces pos = consumeWhiteSpaces(pos + paramTag.length); if (pos >= end) { break; @@ -37763,7 +37763,7 @@ var ts; var firstLineParamHelpStringPos = pos; while (pos < end) { var ch = sourceFile.text.charCodeAt(pos); - // at line break, set this comment line text and go to next line + // at line break, set this comment line text and go to next line if (ts.isLineBreak(ch)) { if (paramHelpString) { pushDocCommentLineText(paramDocComments, paramHelpString, blankLineCount); @@ -37816,7 +37816,7 @@ var ts; if (paramHelpStringMargin === undefined) { paramHelpStringMargin = sourceFile.getLineAndCharacterOfPosition(firstLineParamHelpStringPos).character; } - // Now consume white spaces max + // Now consume white spaces max var startOfLinePos = pos; pos = consumeWhiteSpacesOnTheLine(pos, end, sourceFile, paramHelpStringMargin); if (pos >= end) { @@ -37886,8 +37886,8 @@ var ts; }; SignatureObject.prototype.getDocumentationComment = function () { if (this.documentationComment === undefined) { - this.documentationComment = this.declaration ? getJsDocCommentsFromDeclarations([this.declaration], - /*name*/ undefined, + this.documentationComment = this.declaration ? getJsDocCommentsFromDeclarations([this.declaration], + /*name*/ undefined, /*canUseParsedParamTagComments*/ false) : []; } return this.documentationComment; @@ -38294,8 +38294,8 @@ var ts; return CancellationTokenObject; })(); ts.CancellationTokenObject = CancellationTokenObject; - // Cache host information about scrip Should be refreshed - // at each language service public entry point, since we don't know when + // Cache host information about scrip Should be refreshed + // at each language service public entry point, since we don't know when // set of scripts handled by the host changes. var HostCache = (function () { function HostCache(host, getCanonicalFileName) { @@ -38408,7 +38408,7 @@ var ts; options.isolatedModules = true; // Filename can be non-ts file. options.allowNonTsExtensions = true; - // We are not returning a sourceFile for lib file when asked by the program, + // We are not returning a sourceFile for lib file when asked by the program, // so pass --noLib to avoid reporting a file not found error. options.noLib = true; // We are not doing a full typecheck, we are not resolving the whole context, @@ -38461,7 +38461,7 @@ var ts; ts.createLanguageServiceSourceFile = createLanguageServiceSourceFile; ts.disableIncrementalParsing = false; function updateLanguageServiceSourceFile(sourceFile, scriptSnapshot, version, textChangeRange, aggressiveChecks) { - // If we were given a text change range, and our version or open-ness changed, then + // If we were given a text change range, and our version or open-ness changed, then // incrementally parse this file. if (textChangeRange) { if (version !== sourceFile.version) { @@ -38565,7 +38565,7 @@ var ts; bucket.set(fileName, entry); } else { - // We have an entry for this file. However, it may be for a different version of + // We have an entry for this file. However, it may be for a different version of // the script snapshot. If so, update it appropriately. Otherwise, we can just // return it as is. if (entry.sourceFile.version !== version) { @@ -39020,10 +39020,10 @@ var ts; if (programUpToDate()) { return; } - // IMPORTANT - It is critical from this moment onward that we do not check + // IMPORTANT - It is critical from this moment onward that we do not check // cancellation tokens. We are about to mutate source files from a previous program // instance. If we cancel midway through, we may end up in an inconsistent state where - // the program points to old source files that have been invalidated because of + // the program points to old source files that have been invalidated because of // incremental parsing. var oldSettings = program && program.getCompilerOptions(); var newSettings = hostCache.compilationSettings(); @@ -39039,7 +39039,7 @@ var ts; writeFile: function (fileName, data, writeByteOrderMark) { }, getCurrentDirectory: function () { return host.getCurrentDirectory(); } }); - // Release any files we have acquired in the old program but are + // Release any files we have acquired in the old program but are // not part of the new program. if (program) { var oldSourceFiles = program.getSourceFiles(); @@ -39055,7 +39055,7 @@ var ts; // It needs to be cleared to allow all collected snapshots to be released hostCache = undefined; program = newProgram; - // Make sure all the nodes in the program are both bound, and have their parent + // Make sure all the nodes in the program are both bound, and have their parent // pointers set property. program.getTypeChecker(); return; @@ -39075,7 +39075,7 @@ var ts; // Check if the old program had this file already var oldSourceFile = program && program.getSourceFile(fileName); if (oldSourceFile) { - // We already had a source file for this file name. Go to the registry to + // We already had a source file for this file name. Go to the registry to // ensure that we get the right up to date version of it. We need this to // address the following 'race'. Specifically, say we have the following: // @@ -39086,15 +39086,15 @@ var ts; // LS2 // // Each LS has a reference to file 'foo.ts' at version 1. LS2 then updates - // it's version of 'foo.ts' to version 2. This will cause LS2 and the - // DocumentRegistry to have version 2 of the document. HOwever, LS1 will + // it's version of 'foo.ts' to version 2. This will cause LS2 and the + // DocumentRegistry to have version 2 of the document. HOwever, LS1 will // have version 1. And *importantly* this source file will be *corrupt*. // The act of creating version 2 of the file irrevocably damages the version // 1 file. // // So, later when we call into LS1, we need to make sure that it doesn't use // it's source file any more, and instead defers to DocumentRegistry to get - // either version 1, version 2 (or some other version) depending on what the + // either version 1, version 2 (or some other version) depending on what the // host says should be used. return documentRegistry.updateDocument(fileName, newSettings, hostFileInformation.scriptSnapshot, hostFileInformation.version); } @@ -39153,7 +39153,7 @@ var ts; synchronizeHostData(); var targetSourceFile = getValidSourceFile(fileName); // For JavaScript files, we don't want to report the normal typescript semantic errors. - // Instead, we just report errors for using TypeScript-only constructs from within a + // Instead, we just report errors for using TypeScript-only constructs from within a // JavaScript file. if (ts.isJavaScript(fileName)) { return getJavaScriptSemanticDiagnostics(targetSourceFile); @@ -39398,8 +39398,8 @@ var ts; log("Returning an empty list because completion was requested in an invalid position."); return undefined; } - // Find the node where completion is requested on, in the case of a completion after - // a dot, it is the member access expression other wise, it is a request for all + // Find the node where completion is requested on, in the case of a completion after + // a dot, it is the member access expression other wise, it is a request for all // visible symbols in the scope, and the node is the current location. var node = currentToken; var isRightOfDot = false; @@ -39463,7 +39463,7 @@ var ts; } } if (isJavaScriptFile && type.flags & 16384 /* Union */) { - // In javascript files, for union types, we don't just get the members that + // In javascript files, for union types, we don't just get the members that // the individual types have in common, we also include all the members that // each individual type has. This is because we're going to add all identifiers // anyways. So we might as well elevate the members that were at least part @@ -39522,10 +39522,10 @@ var ts; // aggregating completion candidates. This is achieved in 'getScopeNode' // by finding the first node that encompasses a position, accounting for whether a node // is "complete" to decide whether a position belongs to the node. - // + // // However, at the end of an identifier, we are interested in the scope of the identifier // itself, but fall outside of the identifier. For instance: - // + // // xyz => x$ // // the cursor is outside of both the 'x' and the arrow function 'xyz => x', @@ -39574,7 +39574,7 @@ var ts; } function showCompletionsInImportsClause(node) { if (node) { - // import {| + // import {| // import {a,| if (node.kind === 14 /* OpenBraceToken */ || node.kind === 23 /* CommaToken */) { return node.parent.kind === 215 /* NamedImports */; @@ -39860,17 +39860,17 @@ var ts; return entries; } function createCompletionEntry(symbol, location) { - // Try to get a valid display name for this symbol, if we could not find one, then ignore it. + // Try to get a valid display name for this symbol, if we could not find one, then ignore it. // We would like to only show things that can be added after a dot, so for instance numeric properties can // not be accessed with a dot (a.1 <- invalid) var displayName = getCompletionEntryDisplayNameForSymbol(symbol, program.getCompilerOptions().target, true); if (!displayName) { return undefined; } - // TODO(drosen): Right now we just permit *all* semantic meanings when calling - // 'getSymbolKind' which is permissible given that it is backwards compatible; but + // TODO(drosen): Right now we just permit *all* semantic meanings when calling + // 'getSymbolKind' which is permissible given that it is backwards compatible; but // really we should consider passing the meaning for the node so that we don't report - // that a suggestion for a value is an interface. We COULD also just do what + // that a suggestion for a value is an interface. We COULD also just do what // 'getSymbolModifiers' does, which is to use the first declaration. // Use a 'sortText' of 0' so that all symbol completion entries come before any other // entries (like JavaScript identifier entries). @@ -39910,8 +39910,8 @@ var ts; var symbols = completionData.symbols, location_2 = completionData.location; // Find the symbol with the matching entry name. var target = program.getCompilerOptions().target; - // We don't need to perform character checks here because we're only comparing the - // name against 'entryName' (which is known to be good), not building a new + // We don't need to perform character checks here because we're only comparing the + // name against 'entryName' (which is known to be good), not building a new // completion entry. var symbol = ts.forEach(symbols, function (s) { return getCompletionEntryDisplayNameForSymbol(s, target, false) === entryName ? s : undefined; }); if (symbol) { @@ -40005,7 +40005,7 @@ var ts; ts.Debug.assert(!!(rootSymbolFlags & 8192 /* Method */)); }); if (!unionPropertyKind) { - // If this was union of all methods, + // If this was union of all methods, //make sure it has call signatures before we can label it as method var typeOfUnionProperty = typeChecker.getTypeOfSymbolAtLocation(symbol, location); if (typeOfUnionProperty.getCallSignatures().length) { @@ -40068,7 +40068,7 @@ var ts; var useConstructSignatures = callExpression.kind === 161 /* NewExpression */ || callExpression.expression.kind === 91 /* SuperKeyword */; var allSignatures = useConstructSignatures ? type.getConstructSignatures() : type.getCallSignatures(); if (!ts.contains(allSignatures, signature.target || signature)) { - // Get the first signature if there + // Get the first signature if there signature = allSignatures.length ? allSignatures[0] : undefined; } if (signature) { @@ -40411,7 +40411,7 @@ var ts; var containerName = containerSymbol ? typeChecker.symbolToString(containerSymbol, node) : ""; if (!tryAddConstructSignature(symbol, node, symbolKind, symbolName, containerName, result) && !tryAddCallSignature(symbol, node, symbolKind, symbolName, containerName, result)) { - // Just add all the declarations. + // Just add all the declarations. ts.forEach(declarations, function (declaration) { result.push(createDefinitionInfo(declaration, symbolKind, symbolName, containerName)); }); @@ -40506,7 +40506,7 @@ var ts; } // Because name in short-hand property assignment has two different meanings: property name and property value, // using go-to-definition at such position should go to the variable declaration of the property value rather than - // go to the declaration of the property name (in this case stay at the same position). However, if go-to-definition + // go to the declaration of the property name (in this case stay at the same position). However, if go-to-definition // is performed at the location of property access, we would like to go to definition of the property in the short-hand // assignment. This case and others are handled by the following code. if (node.parent.kind === 228 /* ShorthandPropertyAssignment */) { @@ -40557,7 +40557,7 @@ var ts; var results = getOccurrencesAtPositionCore(fileName, position); if (results) { var sourceFile = getCanonicalFileName(ts.normalizeSlashes(fileName)); - // Get occurrences only supports reporting occurrences for the file queried. So + // Get occurrences only supports reporting occurrences for the file queried. So // filter down to that list. results = ts.filter(results, function (r) { return getCanonicalFileName(ts.normalizeSlashes(r.fileName)) === sourceFile; }); } @@ -40677,7 +40677,7 @@ var ts; case 66 /* BreakKeyword */: case 71 /* ContinueKeyword */: if (hasKind(node.parent, 193 /* BreakStatement */) || hasKind(node.parent, 192 /* ContinueStatement */)) { - return getBreakOrContinueStatementOccurrences(node.parent); + return getBreakOrContinueStatementOccurences(node.parent); } break; case 82 /* ForKeyword */: @@ -40942,7 +40942,7 @@ var ts; }); return ts.map(keywords, getHighlightSpanForNode); } - function getBreakOrContinueStatementOccurrences(breakOrContinueStatement) { + function getBreakOrContinueStatementOccurences(breakOrContinueStatement) { var owner = getBreakOrContinueOwner(breakOrContinueStatement); if (owner) { switch (owner.kind) { @@ -41329,12 +41329,12 @@ var ts; // If we are past the end, stop looking if (position > end) break; - // We found a match. Make sure it's not part of a larger word (i.e. the char + // We found a match. Make sure it's not part of a larger word (i.e. the char // before and after it have to be a non-identifier char). var endPosition = position + symbolNameLength; if ((position === 0 || !ts.isIdentifierPart(text.charCodeAt(position - 1), 2 /* Latest */)) && (endPosition === sourceLength || !ts.isIdentifierPart(text.charCodeAt(endPosition), 2 /* Latest */))) { - // Found a real match. Keep searching. + // Found a real match. Keep searching. positions.push(position); } position = text.indexOf(symbolName, position + symbolNameLength + 1); @@ -41405,7 +41405,7 @@ var ts; cancellationToken.throwIfCancellationRequested(); var referenceLocation = ts.getTouchingPropertyName(sourceFile, position); if (!isValidReferencePosition(referenceLocation, searchText)) { - // This wasn't the start of a token. Check to see if it might be a + // This wasn't the start of a token. Check to see if it might be a // match in a comment or string if that's what the caller is asking // for. if ((findInStrings && isInString(position)) || @@ -41697,7 +41697,7 @@ var ts; return aliasedSymbol; } } - // If the reference location is in an object literal, try to get the contextual type for the + // If the reference location is in an object literal, try to get the contextual type for the // object literal, lookup the property symbol in the contextual type, and use this symbol to // compare to our searchSymbol if (isNameOfPropertyAssignment(referenceLocation)) { @@ -41712,7 +41712,7 @@ var ts; if (searchSymbols.indexOf(rootSymbol) >= 0) { return rootSymbol; } - // Finally, try all properties with the same name in any type the containing type extended or implemented, and + // Finally, try all properties with the same name in any type the containing type extended or implemented, and // see if any is in the list if (rootSymbol.parent && rootSymbol.parent.flags & (32 /* Class */ | 64 /* Interface */)) { var result_3 = []; @@ -42009,7 +42009,7 @@ var ts; } else if (isNameOfModuleDeclaration(nodeForStartPos)) { // If this is name of a module declarations, check if this is right side of dotted module name - // If parent of the module declaration which is parent of this node is module declaration and its body is the module declaration that this node is name of + // If parent of the module declaration which is parent of this node is module declaration and its body is the module declaration that this node is name of // Then this name is name from dotted module if (nodeForStartPos.parent.parent.kind === 208 /* ModuleDeclaration */ && nodeForStartPos.parent.parent.body === nodeForStartPos.parent) { @@ -42227,7 +42227,7 @@ var ts; for (var _i = 0, _a = docComment.tags; _i < _a.length; _i++) { var tag = _a[_i]; // As we walk through each tag, classify the portion of text from the end of - // the last tag (or the start of the entire doc comment) as 'comment'. + // the last tag (or the start of the entire doc comment) as 'comment'. if (tag.pos !== pos) { pushCommentRange(pos, tag.pos - pos); } @@ -42279,7 +42279,7 @@ var ts; } } function classifyDisabledMergeCode(text, start, end) { - // Classify the line that the ======= marker is on as a comment. Then just lex + // Classify the line that the ======= marker is on as a comment. Then just lex // all further tokens and add them to the result. for (var i = start; i < end; i++) { if (ts.isLineBreak(text.charCodeAt(i))) { @@ -42310,7 +42310,7 @@ var ts; } } } - // for accurate classification, the actual token should be passed in. however, for + // for accurate classification, the actual token should be passed in. however, for // cases like 'disabled merge code' classification, we just get the token kind and // classify based on that instead. function classifyTokenType(tokenKind, token) { @@ -42495,11 +42495,11 @@ var ts; return []; } function getTodoComments(fileName, descriptors) { - // Note: while getting todo comments seems like a syntactic operation, we actually + // Note: while getting todo comments seems like a syntactic operation, we actually // treat it as a semantic operation here. This is because we expect our host to call // this on every single file. If we treat this syntactically, then that will cause // us to populate and throw away the tree in our syntax tree cache for each file. By - // treating this as a semantic operation, we can access any tree without throwing + // treating this as a semantic operation, we can access any tree without throwing // anything away. synchronizeHostData(); var sourceFile = getValidSourceFile(fileName); @@ -42523,7 +42523,7 @@ var ts; // 0) The full match for the entire regexp. // 1) The preamble to the message portion. // 2) The message portion. - // 3...N) The descriptor that was matched - by index. 'undefined' for each + // 3...N) The descriptor that was matched - by index. 'undefined' for each // descriptor that didn't match. an actual value if it did match. // // i.e. 'undefined' in position 3 above means TODO(jason) didn't match. @@ -42545,7 +42545,7 @@ var ts; } } ts.Debug.assert(descriptor !== undefined); - // We don't want to match something like 'TODOBY', so we make sure a non + // We don't want to match something like 'TODOBY', so we make sure a non // letter/digit follows the match. if (isLetterOrDigit(fileContents.charCodeAt(matchPosition + descriptor.text.length))) { continue; @@ -42590,10 +42590,10 @@ var ts; // (?:(TODO\(jason\))|(HACK)) // // Note that the outermost group is *not* a capture group, but the innermost groups - // *are* capture groups. By capturing the inner literals we can determine after + // *are* capture groups. By capturing the inner literals we can determine after // matching which descriptor we are dealing with. var literals = "(?:" + ts.map(descriptors, function (d) { return "(" + escapeRegExp(d.text) + ")"; }).join("|") + ")"; - // After matching a descriptor literal, the following regexp matches the rest of the + // After matching a descriptor literal, the following regexp matches the rest of the // text up to the end of the line (or */). var endOfLineOrEndOfComment = /(?:$|\*\/)/.source; var messageRemainder = /(?:.*?)/.source; @@ -42753,7 +42753,7 @@ var ts; var scanner = ts.createScanner(2 /* Latest */, false); /// We do not have a full parser support to know when we should parse a regex or not /// If we consider every slash token to be a regex, we could be missing cases like "1/2/3", where - /// we have a series of divide operator. this list allows us to be more accurate by ruling out + /// we have a series of divide operator. this list allows us to be more accurate by ruling out /// locations where a regexp cannot exist. var noRegexTable = []; noRegexTable[65 /* Identifier */] = true; @@ -42796,7 +42796,7 @@ var ts; keyword2 === 122 /* SetKeyword */ || keyword2 === 114 /* ConstructorKeyword */ || keyword2 === 109 /* StaticKeyword */) { - // Allow things like "public get", "public constructor" and "public static". + // Allow things like "public get", "public constructor" and "public static". // These are all legal. return true; } @@ -42913,12 +42913,12 @@ var ts; // token. So the classification will go back to being an identifier. The moment the user // types again, number will become a keyword, then an identifier, etc. etc. // - // To try to avoid this problem, we avoid classifying contextual keywords as keywords + // To try to avoid this problem, we avoid classifying contextual keywords as keywords // when the user is potentially typing something generic. We just can't do a good enough // job at the lexical level, and so well leave it up to the syntactic classifier to make // the determination. // - // In order to determine if the user is potentially typing something generic, we use a + // In order to determine if the user is potentially typing something generic, we use a // weak heuristic where we track < and > tokens. It's a weak heuristic, but should // work well enough in practice. var angleBracketStack = 0; @@ -42934,7 +42934,7 @@ var ts; token = 65 /* Identifier */; } else if (isKeyword(lastNonTriviaToken) && isKeyword(token) && !canFollow(lastNonTriviaToken, token)) { - // We have two keywords in a row. Only treat the second as a keyword if + // We have two keywords in a row. Only treat the second as a keyword if // it's a sequence that could legally occur in the language. Otherwise // treat it as an identifier. This way, if someone writes "private var" // we recognize that 'var' is actually an identifier here. @@ -42942,7 +42942,7 @@ var ts; } else if (lastNonTriviaToken === 65 /* Identifier */ && token === 24 /* LessThanToken */) { - // Could be the start of something generic. Keep track of that by bumping + // Could be the start of something generic. Keep track of that by bumping // up the current count of generic contexts we may be in. angleBracketStack++; } @@ -42957,7 +42957,7 @@ var ts; token === 113 /* BooleanKeyword */ || token === 124 /* SymbolKeyword */) { if (angleBracketStack > 0 && !syntacticClassifierAbsent) { - // If it looks like we're could be in something generic, don't classify this + // If it looks like we're could be in something generic, don't classify this // as a keyword. We may just get overwritten by the syntactic classifier, // causing a noisy experience for the user. token = 65 /* Identifier */; @@ -43052,8 +43052,8 @@ var ts; return; } if (start === 0 && offset > 0) { - // We're classifying the first token, and this was a case where we prepended - // text. We should consider the start of this token to be at the start of + // We're classifying the first token, and this was a case where we prepended + // text. We should consider the start of this token to be at the start of // the original text. start += offset; } @@ -43200,7 +43200,7 @@ var ts; } initializeServices(); })(ts || (ts = {})); -// Copyright (c) Microsoft. All rights reserved. Licensed under the Apache License, Version 2.0. +// Copyright (c) Microsoft. All rights reserved. Licensed under the Apache License, Version 2.0. // See LICENSE.txt in the project root for complete license information. /// /* @internal */ @@ -43221,8 +43221,8 @@ var ts; if (sourceFile.getLineAndCharacterOfPosition(tokenAtLocation.getStart()).line > lineOfPosition) { // Get previous token if the token is returned starts on new line // eg: let x =10; |--- cursor is here - // let y = 10; - // token at position will return let keyword on second line as the token but we would like to use + // let y = 10; + // token at position will return let keyword on second line as the token but we would like to use // token on same line if trailing trivia (comments or white spaces on same line) part of the last token on that line tokenAtLocation = ts.findPrecedingToken(tokenAtLocation.pos, sourceFile); // Its a blank line diff --git a/src/typings/electron.d.ts b/src/typings/electron.d.ts index 156e175b1d5..05aab3a8161 100644 --- a/src/typings/electron.d.ts +++ b/src/typings/electron.d.ts @@ -584,7 +584,7 @@ declare namespace Electron { /** * ok - Nothing went wrong. - * error - One or more errors occurred, enable runtime logging to figure out the likely cause. + * error - One or more errors occured, enable runtime logging to figure out the likely cause. * invalidSeparatorError - An attempt was made to add a separator to a custom category in the Jump List. * Separators are only allowed in the standard Tasks category. * fileTypeRegistrationError - An attempt was made to add a file link to the Jump List -- GitLab From 50879b0da3fbd85fa16b1bfeb68f3a330fb4413e Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Wed, 14 Jun 2017 15:56:01 -0700 Subject: [PATCH 0843/1347] Get nsfw file watcher sending events back --- .../node/watcher/nsfw/nsfwWatcherService.ts | 35 +++++++++++++++++-- 1 file changed, 33 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts b/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts index 94462f18a40..5b963bdc348 100644 --- a/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts +++ b/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts @@ -6,6 +6,16 @@ import nsfw = require('nsfw'); import { IWatcherService, IWatcherRequest } from 'vs/workbench/services/files/node/watcher/unix/watcher'; import { TPromise } from "vs/base/common/winjs.base"; +import watcher = require('vs/workbench/services/files/node/watcher/common'); +import * as path from 'path'; + +const nsfwEventActionToRawChangeType = { + 0: 1, // Created + 1: 2, // Deleted + 2: 0, // Modified + // TODO: handle rename event type + 3: null // Rename +}; export class NsfwWatcherService implements IWatcherService { public watch(request: IWatcherRequest): TPromise { @@ -13,11 +23,32 @@ export class NsfwWatcherService implements IWatcherService { console.log('basePath ' + request.basePath); return new TPromise((c, e, p) => { nsfw(request.basePath, events => { - console.log(events); - p(events); + if (request.verboseLogging) { + console.log('raw events start'); + events.forEach(e => console.log(e)); + console.log('raw events end'); + } + const convertedEvents = events.map(e => this._mapNsfwEventToRawFileChange(e)).filter(e => !!e); + // TODO: Utilize fileEventDelayer and watcher.normalize + p(convertedEvents); }).then(watcher => { return watcher.start(); }); }); } + + private _mapNsfwEventToRawFileChange(nsfwEvent: any): watcher.IRawFileChange { + // TODO: Handle other event types (directory change?) + if (!nsfwEvent.directory || !nsfwEvent.file) { + return null; + } + const event: watcher.IRawFileChange = { + type: nsfwEventActionToRawChangeType[nsfwEvent.action], + path: path.join(nsfwEvent.directory, nsfwEvent.file) + }; + if (!event.type) { + return null; + } + return event; + } } -- GitLab From 3fb0d0256a10d329197249a54087986f7a2bf6e4 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 14 Jun 2017 16:28:31 -0700 Subject: [PATCH 0844/1347] Update marked version Fixes Microsoft/vscode-internalbacklog#40 --- src/vs/base/common/marked/OSSREADME.json | 2 +- src/vs/base/common/marked/raw.marked.js | 67 ++++++++++++++---------- 2 files changed, 40 insertions(+), 29 deletions(-) diff --git a/src/vs/base/common/marked/OSSREADME.json b/src/vs/base/common/marked/OSSREADME.json index 5fc985980a4..5bfc34a583b 100644 --- a/src/vs/base/common/marked/OSSREADME.json +++ b/src/vs/base/common/marked/OSSREADME.json @@ -3,6 +3,6 @@ [{ "name": "chjj-marked", "repositoryURL": "https://github.com/npmcomponent/chjj-marked", - "version": "0.3.2", + "version": "0.3.6", "license": "MIT" }] diff --git a/src/vs/base/common/marked/raw.marked.js b/src/vs/base/common/marked/raw.marked.js index ce02369727a..5b3f6940d00 100644 --- a/src/vs/base/common/marked/raw.marked.js +++ b/src/vs/base/common/marked/raw.marked.js @@ -1,4 +1,3 @@ - /** * marked - a markdown parser * Copyright (c) 2011-2014, Christopher Jeffrey. (MIT Licensed) @@ -78,8 +77,9 @@ block.normal = merge({}, block); */ block.gfm = merge({}, block.normal, { - fences: /^ *(`{3,}|~{3,}) *(\S+)? *\n([\s\S]+?)\s*\1 *(?:\n+|$)/, - paragraph: /^/ + fences: /^ *(`{3,}|~{3,})[ \.]*(\S+)? *\n([\s\S]*?)\s*\1 *(?:\n+|$)/, + paragraph: /^/, + heading: /^ *(#{1,6}) +([^\n]+?) *#* *(?:\n+|$)/ }); block.gfm.paragraph = replace(block.paragraph) @@ -191,7 +191,7 @@ Lexer.prototype.token = function(src, top, bq) { this.tokens.push({ type: 'code', lang: cap[2], - text: cap[3] + text: cap[3] || '' }); continue; } @@ -362,7 +362,8 @@ Lexer.prototype.token = function(src, top, bq) { type: this.options.sanitize ? 'paragraph' : 'html', - pre: cap[1] === 'pre' || cap[1] === 'script' || cap[1] === 'style', + pre: !this.options.sanitizer + && (cap[1] === 'pre' || cap[1] === 'script' || cap[1] === 'style'), text: cap[0] }); continue; @@ -457,7 +458,7 @@ var inline = { reflink: /^!?\[(inside)\]\s*\[([^\]]*)\]/, nolink: /^!?\[((?:\[[^\]]*\]|[^\[\]])*)\]/, strong: /^__([\s\S]+?)__(?!_)|^\*\*([\s\S]+?)\*\*(?!\*)/, - em: /^\b_((?:__|[\s\S])+?)_\b|^\*((?:\*\*|[\s\S])+?)\*(?!\*)/, + em: /^\b_((?:[^_]|__)+?)_\b|^\*((?:\*\*|[\s\S])+?)\*(?!\*)/, code: /^(`+)\s*([\s\S]*?[^`])\s*\1(?!`)/, br: /^ {2,}\n(?!\s*$)/, del: noop, @@ -609,8 +610,10 @@ InlineLexer.prototype.output = function(src) { } src = src.substring(cap[0].length); out += this.options.sanitize - ? escape(cap[0]) - : cap[0]; + ? this.options.sanitizer + ? this.options.sanitizer(cap[0]) + : escape(cap[0]) + : cap[0] continue; } @@ -681,7 +684,7 @@ InlineLexer.prototype.output = function(src) { // text if (cap = this.rules.text.exec(src)) { src = src.substring(cap[0].length); - out += escape(this.smartypants(cap[0])); + out += this.renderer.text(escape(this.smartypants(cap[0]))); continue; } @@ -710,24 +713,24 @@ InlineLexer.prototype.outputLink = function(cap, link) { /** * Smartypants Transformations */ -// TODO MonacoChange: Our build fails over the following lines if they are not commented out + InlineLexer.prototype.smartypants = function(text) { - return text; -// if (!this.options.smartypants) return text; -// return text -// // em-dashes -// .replace(/--/g, '\u2014') -// // opening singles -// .replace(/(^|[-\u2014/(\[{"\s])'/g, '$1\u2018') -// // closing singles & apostrophes -// .replace(/'/g, '\u2019') -// // opening doubles -// .replace(/(^|[-\u2014/(\[{\u2018\s])"/g, '$1\u201c') -// // closing doubles -// .replace(/"/g, '\u201d') -// // ellipses -// .replace(/\.{3}/g, '\u2026'); -// END MonacoChange + if (!this.options.smartypants) return text; + return text + // em-dashes + .replace(/---/g, '\u2014') + // en-dashes + .replace(/--/g, '\u2013') + // opening singles + .replace(/(^|[-\u2014/(\[{"\s])'/g, '$1\u2018') + // closing singles & apostrophes + .replace(/'/g, '\u2019') + // opening doubles + .replace(/(^|[-\u2014/(\[{\u2018\s])"/g, '$1\u201c') + // closing doubles + .replace(/"/g, '\u201d') + // ellipses + .replace(/\.{3}/g, '\u2026'); }; /** @@ -735,6 +738,7 @@ InlineLexer.prototype.smartypants = function(text) { */ InlineLexer.prototype.mangle = function(text) { + if (!this.options.mangle) return text; var out = '' , l = text.length , i = 0 @@ -873,7 +877,7 @@ Renderer.prototype.link = function(href, title, text) { } catch (e) { return ''; } - if (prot.indexOf('javascript:') === 0) { + if (prot.indexOf('javascript:') === 0 || prot.indexOf('vbscript:') === 0 || prot.indexOf('data:') === 0) { return ''; } } @@ -894,6 +898,10 @@ Renderer.prototype.image = function(href, title, text) { return out; }; +Renderer.prototype.text = function(text) { + return text; +}; + /** * Parsing & Compiling */ @@ -1088,7 +1096,8 @@ function escape(html, encode) { } function unescape(html) { - return html.replace(/&([#\w]+);/g, function(_, n) { + // explicitly match decimal, hex, and named HTML entities + return html.replace(/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/g, function(_, n) { n = n.toLowerCase(); if (n === 'colon') return ':'; if (n.charAt(0) === '#') { @@ -1237,6 +1246,8 @@ marked.defaults = { breaks: false, pedantic: false, sanitize: false, + sanitizer: null, + mangle: true, smartLists: false, silent: false, highlight: null, -- GitLab From 29ee3244fd27023bb4c0ce3ca886ff09e14f9f26 Mon Sep 17 00:00:00 2001 From: rebornix Date: Wed, 14 Jun 2017 17:04:38 -0700 Subject: [PATCH 0845/1347] Find Widget in Terminal --- .../parts/terminal/common/terminal.ts | 17 ++ .../parts/terminal/common/terminalService.ts | 9 +- .../electron-browser/media/close-dark.svg | 1 + .../terminal/electron-browser/media/close.svg | 1 + .../electron-browser/media/next-inverse.svg | 5 + .../terminal/electron-browser/media/next.svg | 5 + .../media/previous-inverse.svg | 5 + .../electron-browser/media/previous.svg | 5 + .../electron-browser/media/terminal.css | 72 ++++++ .../electron-browser/terminal.contribution.ts | 12 +- .../electron-browser/terminalActions.ts | 34 +++ .../electron-browser/terminalFindWidget.ts | 221 ++++++++++++++++++ .../electron-browser/terminalInstance.ts | 8 + .../electron-browser/terminalPanel.ts | 18 +- .../electron-browser/terminalService.ts | 21 +- 15 files changed, 426 insertions(+), 8 deletions(-) create mode 100644 src/vs/workbench/parts/terminal/electron-browser/media/close-dark.svg create mode 100644 src/vs/workbench/parts/terminal/electron-browser/media/close.svg create mode 100644 src/vs/workbench/parts/terminal/electron-browser/media/next-inverse.svg create mode 100644 src/vs/workbench/parts/terminal/electron-browser/media/next.svg create mode 100644 src/vs/workbench/parts/terminal/electron-browser/media/previous-inverse.svg create mode 100644 src/vs/workbench/parts/terminal/electron-browser/media/previous.svg create mode 100644 src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.ts diff --git a/src/vs/workbench/parts/terminal/common/terminal.ts b/src/vs/workbench/parts/terminal/common/terminal.ts index 116c8854a77..34cf3aaac1d 100644 --- a/src/vs/workbench/parts/terminal/common/terminal.ts +++ b/src/vs/workbench/parts/terminal/common/terminal.ts @@ -27,6 +27,11 @@ export const KEYBINDING_CONTEXT_TERMINAL_TEXT_SELECTED = new RawContextKey('terminalFindWidgetVisible', undefined); +/** A context key that is set when the find widget in integrated terminal is not visible. */ +export const KEYBINDING_CONTEXT_TERMINAL_FIND_WIDGET_NOT_VISIBLE: ContextKeyExpr = KEYBINDING_CONTEXT_TERMINAL_FIND_WIDGET_VISIBLE.toNegated(); + export const IS_WORKSPACE_SHELL_ALLOWED_STORAGE_KEY = 'terminal.integrated.isWorkspaceShellAllowed'; export const NEVER_SUGGEST_SELECT_WINDOWS_SHELL_STORAGE_KEY = 'terminal.integrated.neverSuggestSelectWindowsShell'; @@ -147,6 +152,8 @@ export interface ITerminalService { showPanel(focus?: boolean): TPromise; hidePanel(): void; + focusFindWidget(): TPromise; + hideFindWidget(): void; setContainers(panelContainer: HTMLElement, terminalContainer: HTMLElement): void; updateConfig(): void; selectDefaultWindowsShell(): TPromise; @@ -235,6 +242,16 @@ export interface ITerminalInstance { */ selectAll(): void; + /** + * Find the next instance of the term + */ + findNext(term: string): boolean; + + /** + * Find the previous instance of the term + */ + findPrevious(term: string): boolean; + /** * Focuses the terminal instance. * diff --git a/src/vs/workbench/parts/terminal/common/terminalService.ts b/src/vs/workbench/parts/terminal/common/terminalService.ts index 7dbb40a3233..5362507941f 100644 --- a/src/vs/workbench/parts/terminal/common/terminalService.ts +++ b/src/vs/workbench/parts/terminal/common/terminalService.ts @@ -10,7 +10,7 @@ import { ILifecycleService } from 'vs/platform/lifecycle/common/lifecycle'; import { IPanelService } from 'vs/workbench/services/panel/common/panelService'; import { IPartService } from 'vs/workbench/services/part/common/partService'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { ITerminalService, ITerminalInstance, IShellLaunchConfig, ITerminalConfigHelper, KEYBINDING_CONTEXT_TERMINAL_FOCUS, TERMINAL_PANEL_ID } from 'vs/workbench/parts/terminal/common/terminal'; +import { ITerminalService, ITerminalInstance, IShellLaunchConfig, ITerminalConfigHelper, KEYBINDING_CONTEXT_TERMINAL_FOCUS, KEYBINDING_CONTEXT_TERMINAL_FIND_WIDGET_VISIBLE, TERMINAL_PANEL_ID } from 'vs/workbench/parts/terminal/common/terminal'; import { TPromise } from 'vs/base/common/winjs.base'; export abstract class TerminalService implements ITerminalService { @@ -18,6 +18,7 @@ export abstract class TerminalService implements ITerminalService { protected _isShuttingDown: boolean; protected _terminalFocusContextKey: IContextKey; + protected _findWidgetVisible: IContextKey; protected _terminalContainer: HTMLElement; protected _onInstancesChanged: Emitter; protected _onInstanceDisposed: Emitter; @@ -43,7 +44,7 @@ export abstract class TerminalService implements ITerminalService { constructor( @IContextKeyService private _contextKeyService: IContextKeyService, @IConfigurationService private _configurationService: IConfigurationService, - @IPanelService private _panelService: IPanelService, + @IPanelService protected _panelService: IPanelService, @IPartService private _partService: IPartService, @ILifecycleService lifecycleService: ILifecycleService ) { @@ -61,6 +62,7 @@ export abstract class TerminalService implements ITerminalService { this._configurationService.onDidUpdateConfiguration(() => this.updateConfig()); lifecycleService.onWillShutdown(event => event.veto(this._onWillShutdown())); this._terminalFocusContextKey = KEYBINDING_CONTEXT_TERMINAL_FOCUS.bindTo(this._contextKeyService); + this._findWidgetVisible = KEYBINDING_CONTEXT_TERMINAL_FIND_WIDGET_VISIBLE.bindTo(this._contextKeyService); this.onInstanceDisposed((terminalInstance) => { this._removeInstance(terminalInstance); }); } @@ -200,6 +202,9 @@ export abstract class TerminalService implements ITerminalService { } } + public abstract focusFindWidget(): TPromise; + public abstract hideFindWidget(): void; + private _getIndexFromId(terminalId: number): number { let terminalIndex = -1; this.terminalInstances.forEach((terminalInstance, i) => { diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/close-dark.svg b/src/vs/workbench/parts/terminal/electron-browser/media/close-dark.svg new file mode 100644 index 00000000000..751e89b3b02 --- /dev/null +++ b/src/vs/workbench/parts/terminal/electron-browser/media/close-dark.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/close.svg b/src/vs/workbench/parts/terminal/electron-browser/media/close.svg new file mode 100644 index 00000000000..fde34404d4e --- /dev/null +++ b/src/vs/workbench/parts/terminal/electron-browser/media/close.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/next-inverse.svg b/src/vs/workbench/parts/terminal/electron-browser/media/next-inverse.svg new file mode 100644 index 00000000000..7498a498bb6 --- /dev/null +++ b/src/vs/workbench/parts/terminal/electron-browser/media/next-inverse.svg @@ -0,0 +1,5 @@ + + + diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/next.svg b/src/vs/workbench/parts/terminal/electron-browser/media/next.svg new file mode 100644 index 00000000000..4b176879f90 --- /dev/null +++ b/src/vs/workbench/parts/terminal/electron-browser/media/next.svg @@ -0,0 +1,5 @@ + + + diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/previous-inverse.svg b/src/vs/workbench/parts/terminal/electron-browser/media/previous-inverse.svg new file mode 100644 index 00000000000..0aabf393d9c --- /dev/null +++ b/src/vs/workbench/parts/terminal/electron-browser/media/previous-inverse.svg @@ -0,0 +1,5 @@ + + + diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/previous.svg b/src/vs/workbench/parts/terminal/electron-browser/media/previous.svg new file mode 100644 index 00000000000..f7acf0acbd9 --- /dev/null +++ b/src/vs/workbench/parts/terminal/electron-browser/media/previous.svg @@ -0,0 +1,5 @@ + + + diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css b/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css index f2cc6747e2c..0b6570ccef9 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css +++ b/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css @@ -78,3 +78,75 @@ .hc-black .monaco-workbench.mac .panel.integrated-terminal .xterm-rows { cursor: -webkit-image-set(url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAQAAAC1+jfqAAAAL0lEQVQoz2NgCD3x//9/BhBYBWdhgFVAiVW4JBFKGIa4AqD0//9D3pt4I4tAdAMAHTQ/j5Zom30AAAAASUVORK5CYII=') 1x, url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAQAAADZc7J/AAAAz0lEQVRIx2NgYGBY/R8I/vx5eelX3n82IJ9FxGf6tksvf/8FiTMQAcAGQMDvSwu09abffY8QYSAScNk45G198eX//yev73/4///701eh//kZSARckrNBRvz//+8+6ZohwCzjGNjdgQxkAg7B9WADeBjIBqtJCbhRA0YNoIkBSNmaPEMoNmA0FkYNoFKhapJ6FGyAH3nauaSmPfwI0v/3OukVi0CIZ+F25KrtYcx/CTIy0e+rC7R1Z4KMICVTQQ14feVXIbR695u14+Ir4gwAAD49E54wc1kWAAAAAElFTkSuQmCC') 2x) 5 8, text; } + +.monaco-workbench .panel.integrated-terminal .find-part { + position: absolute; + top: -40px; + right: 28px; + display: none; + padding: 4px; + align-items: center; + + -webkit-transition: top 200ms linear; + -o-transition: top 200ms linear; + -moz-transition: top 200ms linear; + -ms-transition: top 200ms linear; + transition: top 200ms linear; +} + +.monaco-workbench .panel.integrated-terminal .find-part.visible { + top: 0; + display: flex; +} + +/* Temporarily we don't show match numbers */ +.monaco-workbench .panel.integrated-terminal .find-part .monaco-findInput .controls { + display: none; +} +.monaco-workbench .panel.integrated-terminal .find-part .monaco-findInput .monaco-inputbox .wrapper .input { + width: 100% !important; +} + +.monaco-workbench .panel.integrated-terminal .find-part .button { + min-width: 20px; + width: 20px; + height: 20px; + display: flex; + flex: initial; + margin-left: 3px; + background-position: center center; + background-repeat: no-repeat; + cursor: pointer; +} + +.monaco-workbench .panel.integrated-terminal .find-part .button.previous { + background-image: url('previous.svg'); +} + +.monaco-workbench .panel.integrated-terminal .find-part .button.next { + background-image: url('next.svg'); +} + +.monaco-workbench .panel.integrated-terminal .find-part .button.close-fw { + background-image: url('close.svg'); +} + +.hc-black .monaco-workbench .panel.integrated-terminal .find-part .button.previous, +.vs-dark .monaco-workbench .panel.integrated-terminal .find-part .button.previous { + background-image: url('previous-inverse.svg'); +} + +.hc-black .monaco-workbench .panel.integrated-terminal .find-part .button.next, +.vs-dark .monaco-workbench .panel.integrated-terminal .find-part .button.next { + background-image: url('next-inverse.svg'); +} + +.hc-black .monaco-workbench .panel.integrated-terminal .find-part .button.close-fw, +.vs-dark .monaco-workbench .panel.integrated-terminal .find-part .button.close-fw { + background-image: url('close-dark.svg'); +} + +monaco-workbench .panel.integrated-terminal .find-part .button.disabled { + opacity: 0.3; + cursor: default; +} \ No newline at end of file diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts index 3dafb84e0b5..b58c93b8e22 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts @@ -13,12 +13,12 @@ import * as panel from 'vs/workbench/browser/panel'; import * as platform from 'vs/base/common/platform'; import { Extensions, IConfigurationRegistry } from 'vs/platform/configuration/common/configurationRegistry'; import { GlobalQuickOpenAction } from 'vs/workbench/browser/parts/quickopen/quickopen.contribution'; -import { ITerminalService, KEYBINDING_CONTEXT_TERMINAL_FOCUS, KEYBINDING_CONTEXT_TERMINAL_TEXT_SELECTED, TERMINAL_PANEL_ID, TERMINAL_DEFAULT_RIGHT_CLICK_COPY_PASTE, TerminalCursorStyle } from 'vs/workbench/parts/terminal/common/terminal'; +import { ITerminalService, KEYBINDING_CONTEXT_TERMINAL_FOCUS, KEYBINDING_CONTEXT_TERMINAL_TEXT_SELECTED, TERMINAL_PANEL_ID, TERMINAL_DEFAULT_RIGHT_CLICK_COPY_PASTE, KEYBINDING_CONTEXT_TERMINAL_FIND_WIDGET_VISIBLE, TerminalCursorStyle } from 'vs/workbench/parts/terminal/common/terminal'; import { TERMINAL_DEFAULT_SHELL_LINUX, TERMINAL_DEFAULT_SHELL_OSX, TERMINAL_DEFAULT_SHELL_WINDOWS } from 'vs/workbench/parts/terminal/electron-browser/terminal'; import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/workbench/common/actionRegistry'; import { KeyCode, KeyMod } from 'vs/base/common/keyCodes'; import { ContextKeyExpr } from 'vs/platform/contextkey/common/contextkey'; -import { KillTerminalAction, CopyTerminalSelectionAction, CreateNewTerminalAction, FocusActiveTerminalAction, FocusNextTerminalAction, FocusPreviousTerminalAction, FocusTerminalAtIndexAction, SelectDefaultShellWindowsTerminalAction, RunSelectedTextInTerminalAction, RunActiveFileInTerminalAction, ScrollDownTerminalAction, ScrollDownPageTerminalAction, ScrollToBottomTerminalAction, ScrollUpTerminalAction, ScrollUpPageTerminalAction, ScrollToTopTerminalAction, TerminalPasteAction, ToggleTerminalAction, ClearTerminalAction, AllowWorkspaceShellTerminalCommand, DisallowWorkspaceShellTerminalCommand, RenameTerminalAction, SelectAllTerminalAction } from 'vs/workbench/parts/terminal/electron-browser/terminalActions'; +import { KillTerminalAction, CopyTerminalSelectionAction, CreateNewTerminalAction, FocusActiveTerminalAction, FocusNextTerminalAction, FocusPreviousTerminalAction, FocusTerminalAtIndexAction, SelectDefaultShellWindowsTerminalAction, RunSelectedTextInTerminalAction, RunActiveFileInTerminalAction, ScrollDownTerminalAction, ScrollDownPageTerminalAction, ScrollToBottomTerminalAction, ScrollUpTerminalAction, ScrollUpPageTerminalAction, ScrollToTopTerminalAction, TerminalPasteAction, ToggleTerminalAction, ClearTerminalAction, AllowWorkspaceShellTerminalCommand, DisallowWorkspaceShellTerminalCommand, RenameTerminalAction, SelectAllTerminalAction, FocusTerminalFindWidgetAction, HideTerminalFindWidgetAction } from 'vs/workbench/parts/terminal/electron-browser/terminalActions'; import { Registry } from 'vs/platform/platform'; import { ShowAllCommandsAction } from 'vs/workbench/parts/quickopen/browser/commandsHandler'; import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; @@ -277,5 +277,11 @@ if (platform.isWindows) { actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(AllowWorkspaceShellTerminalCommand, AllowWorkspaceShellTerminalCommand.ID, AllowWorkspaceShellTerminalCommand.LABEL), 'Terminal: Allow Workspace Shell Configuration', category); actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(DisallowWorkspaceShellTerminalCommand, DisallowWorkspaceShellTerminalCommand.ID, DisallowWorkspaceShellTerminalCommand.LABEL), 'Terminal: Disallow Workspace Shell Configuration', category); actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(RenameTerminalAction, RenameTerminalAction.ID, RenameTerminalAction.LABEL), 'Terminal: Rename', category); - +actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(FocusTerminalFindWidgetAction, FocusTerminalFindWidgetAction.ID, FocusTerminalFindWidgetAction.LABEL, { + primary: KeyMod.WinCtrl | KeyCode.Shift | KeyCode.KEY_F, + mac: { primary: KeyMod.CtrlCmd | KeyCode.KEY_F } +}), 'Terminal: Focus Find Widget', nls.localize('Terminal: Focus Find Widget', category)); +actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(HideTerminalFindWidgetAction, HideTerminalFindWidgetAction.ID, HideTerminalFindWidgetAction.LABEL, { + primary: KeyCode.Escape +}, KEYBINDING_CONTEXT_TERMINAL_FIND_WIDGET_VISIBLE), 'Terminal: Focus Find Widget', nls.localize('Terminal: Focus Find Widget', category)); registerColors(); diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts index 6ead524b144..0d3a3a0b17c 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts @@ -583,3 +583,37 @@ export class RenameTerminalAction extends Action { }); } } + +export class FocusTerminalFindWidgetAction extends Action { + + public static ID = 'workbench.action.terminal.focusFindWidget'; + public static LABEL = nls.localize('workbench.action.terminal.focusFindWidget', "Focus Find Widget"); + + constructor( + id: string, label: string, + @ITerminalService private terminalService: ITerminalService + ) { + super(id, label); + } + + public run(): TPromise { + return this.terminalService.focusFindWidget(); + } +} + +export class HideTerminalFindWidgetAction extends Action { + + public static ID = 'workbench.action.terminal.hideFindWidget'; + public static LABEL = nls.localize('workbench.action.terminal.hideFindWidget', "Hide Find Widget"); + + constructor( + id: string, label: string, + @ITerminalService private terminalService: ITerminalService + ) { + super(id, label); + } + + public run(): TPromise { + return TPromise.as(this.terminalService.hideFindWidget()); + } +} diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.ts new file mode 100644 index 00000000000..7e38eeec167 --- /dev/null +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.ts @@ -0,0 +1,221 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as nls from 'vs/nls'; +import { IKeyboardEvent } from 'vs/base/browser/keyboardEvent'; +import { Widget } from 'vs/base/browser/ui/widget'; +import { KeyCode, KeyMod } from 'vs/base/common/keyCodes'; +import * as dom from 'vs/base/browser/dom'; +import { FindInput } from 'vs/base/browser/ui/findinput/findInput'; +import { IContextViewService } from 'vs/platform/contextview/browser/contextView'; +import { ITerminalService } from 'vs/workbench/parts/terminal/common/terminal'; +import { registerThemingParticipant, ITheme } from 'vs/platform/theme/common/themeService'; +import { inputBackground, inputActiveOptionBorder, inputForeground, inputBorder, inputValidationInfoBackground, inputValidationInfoBorder, inputValidationWarningBackground, inputValidationWarningBorder, inputValidationErrorBackground, inputValidationErrorBorder, editorWidgetBackground, widgetShadow } from 'vs/platform/theme/common/colorRegistry'; + +interface IButtonOpts { + label: string; + className: string; + onTrigger: () => void; + onKeyDown: (e: IKeyboardEvent) => void; +} + +class SimpleButton extends Widget { + + private _opts: IButtonOpts; + private _domNode: HTMLElement; + + constructor(opts: IButtonOpts) { + super(); + this._opts = opts; + + this._domNode = document.createElement('div'); + this._domNode.title = this._opts.label; + this._domNode.tabIndex = 0; + this._domNode.className = 'button ' + this._opts.className; + this._domNode.setAttribute('role', 'button'); + this._domNode.setAttribute('aria-label', this._opts.label); + + this.onclick(this._domNode, (e) => { + this._opts.onTrigger(); + e.preventDefault(); + }); + this.onkeydown(this._domNode, (e) => { + if (e.equals(KeyCode.Space) || e.equals(KeyCode.Enter)) { + this._opts.onTrigger(); + e.preventDefault(); + return; + } + this._opts.onKeyDown(e); + }); + } + + public get domNode(): HTMLElement { + return this._domNode; + } + + public isEnabled(): boolean { + return (this._domNode.tabIndex >= 0); + } + + public focus(): void { + this._domNode.focus(); + } + + public setEnabled(enabled: boolean): void { + dom.toggleClass(this._domNode, 'disabled', !enabled); + this._domNode.setAttribute('aria-disabled', String(!enabled)); + this._domNode.tabIndex = enabled ? 0 : -1; + } + + public toggleClass(className: string, shouldHaveIt: boolean): void { + dom.toggleClass(this._domNode, className, shouldHaveIt); + } +} + +const NLS_FIND_INPUT_LABEL = nls.localize('label.find', "Find"); +const NLS_FIND_INPUT_PLACEHOLDER = nls.localize('placeholder.find', "Find"); +const NLS_PREVIOUS_MATCH_BTN_LABEL = nls.localize('label.previousMatchButton', "Previous match"); +const NLS_NEXT_MATCH_BTN_LABEL = nls.localize('label.nextMatchButton', "Next match"); +const NLS_CLOSE_BTN_LABEL = nls.localize('label.closeButton', "Close"); + +export class TerminalFindWidget extends Widget { + private _findInput: FindInput; + private _domNode: HTMLElement; + private _isVisible: boolean; + + constructor( + @IContextViewService private _contextViewService: IContextViewService, + @ITerminalService private _terminalService: ITerminalService + ) { + super(); + this._findInput = this._register(new FindInput(null, this._contextViewService, { + width: 155, + label: NLS_FIND_INPUT_LABEL, + placeholder: NLS_FIND_INPUT_PLACEHOLDER, + })); + + let find = (previous) => { + let val = this._findInput.getValue(); + let instance = this._terminalService.getActiveInstance(); + if (instance !== null) { + if (previous) { + instance.findPrevious(val); + } else { + instance.findNext(val); + } + } + }; + + this._register(this._findInput.onKeyDown((e) => { + if (e.equals(KeyCode.Enter)) { + find(false); + e.preventDefault(); + return; + } + + if (e.equals(KeyMod.Shift | KeyCode.Enter)) { + find(true); + e.preventDefault(); + return; + } + })); + + let prevBtn = new SimpleButton({ + label: NLS_PREVIOUS_MATCH_BTN_LABEL, + className: 'previous', + onTrigger: () => { + find(true); + }, + onKeyDown: (e) => { } + }); + + let nextBtn = new SimpleButton({ + label: NLS_NEXT_MATCH_BTN_LABEL, + className: 'next', + onTrigger: () => { + find(false); + }, + onKeyDown: (e) => { } + }); + + let closeBtn = new SimpleButton({ + label: NLS_CLOSE_BTN_LABEL, + className: 'close-fw', + onTrigger: () => { + this.hide(); + }, + onKeyDown: (e) => { } + }); + + this._domNode = document.createElement('div'); + this._domNode.className = 'find-part'; + this._domNode.appendChild(this._findInput.domNode); + this._domNode.appendChild(prevBtn.domNode); + this._domNode.appendChild(nextBtn.domNode); + this._domNode.appendChild(closeBtn.domNode); + + this._register(dom.addDisposableListener(this._domNode, 'click', (event) => { + event.stopPropagation(); + })); + } + + public updateTheme(theme?: ITheme): void { + let inputStyles = { + inputActiveOptionBorder: theme.getColor(inputActiveOptionBorder), + inputBackground: theme.getColor(inputBackground), + inputForeground: theme.getColor(inputForeground), + inputBorder: theme.getColor(inputBorder), + inputValidationInfoBackground: theme.getColor(inputValidationInfoBackground), + inputValidationInfoBorder: theme.getColor(inputValidationInfoBorder), + inputValidationWarningBackground: theme.getColor(inputValidationWarningBackground), + inputValidationWarningBorder: theme.getColor(inputValidationWarningBorder), + inputValidationErrorBackground: theme.getColor(inputValidationErrorBackground), + inputValidationErrorBorder: theme.getColor(inputValidationErrorBorder) + }; + this._findInput.style(inputStyles); + } + + public getDomNode(): HTMLElement { + return this._domNode; + } + + public reveal(): void { + if (!this._isVisible) { + this._isVisible = true; + + setTimeout(() => { + dom.addClass(this._domNode, 'visible'); + this._domNode.setAttribute('aria-hidden', 'false'); + dom.addClass(this._domNode, 'noanimation'); + setTimeout(() => { + dom.removeClass(this._domNode, 'noanimation'); + this._findInput.select(); + }, 200); + }, 0); + } + } + + public hide(): void { + if (this._isVisible) { + this._isVisible = false; + + dom.removeClass(this._domNode, 'visible'); + this._domNode.setAttribute('aria-hidden', 'true'); + } + } +} + +// theming +registerThemingParticipant((theme, collector) => { + const findWidgetBGColor = theme.getColor(editorWidgetBackground); + if (findWidgetBGColor) { + collector.addRule(`.monaco-workbench .panel.integrated-terminal .find-part { background-color: ${findWidgetBGColor} !important; }`); + } + + let widgetShadowColor = theme.getColor(widgetShadow); + if (widgetShadowColor) { + collector.addRule(`.monaco-workbench .panel.integrated-terminal .find-part { box-shadow: 0 2px 8px ${widgetShadowColor}; }`); + } +}); \ No newline at end of file diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index b03ee074b1e..54989b2c496 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -347,6 +347,14 @@ export class TerminalInstance implements ITerminalInstance { this._xterm.selectAll(); } + public findNext(term: string): boolean { + return this._xterm.findNext(term); + } + + public findPrevious(term: string): boolean { + return this._xterm.findPrevious(term); + } + public dispose(): void { if (this._linkHandler) { this._linkHandler.dispose(); diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts index 3dae4ebd1bd..ee922268212 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts @@ -10,11 +10,12 @@ import { Action, IAction } from 'vs/base/common/actions'; import { Builder, Dimension } from 'vs/base/browser/builder'; import { IActionItem, Separator } from 'vs/base/browser/ui/actionbar/actionbar'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { IContextMenuService } from 'vs/platform/contextview/browser/contextView'; +import { IContextMenuService, IContextViewService } from 'vs/platform/contextview/browser/contextView'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { ITerminalService, ITerminalFont, TERMINAL_PANEL_ID } from 'vs/workbench/parts/terminal/common/terminal'; import { IThemeService, ITheme } from 'vs/platform/theme/common/themeService'; +import { TerminalFindWidget } from './terminalFindWidget'; import { ansiColorIdentifiers, TERMINAL_BACKGROUND_COLOR, TERMINAL_FOREGROUND_COLOR } from './terminalColorRegistry'; import { ColorIdentifier, selectionBackground } from 'vs/platform/theme/common/colorRegistry'; import { KillTerminalAction, CreateNewTerminalAction, SwitchTerminalInstanceAction, SwitchTerminalInstanceActionItem, CopyTerminalSelectionAction, TerminalPasteAction, ClearTerminalAction } from 'vs/workbench/parts/terminal/electron-browser/terminalActions'; @@ -34,10 +35,12 @@ export class TerminalPanel extends Panel { private _parentDomElement: HTMLElement; private _terminalContainer: HTMLElement; private _themeStyleElement: HTMLElement; + private _findWidget: TerminalFindWidget; constructor( @IConfigurationService private _configurationService: IConfigurationService, @IContextMenuService private _contextMenuService: IContextMenuService, + @IContextViewService private _contextViewService: IContextViewService, @IInstantiationService private _instantiationService: IInstantiationService, @ITerminalService private _terminalService: ITerminalService, @IThemeService protected themeService: IThemeService, @@ -55,9 +58,13 @@ export class TerminalPanel extends Panel { this._terminalContainer = document.createElement('div'); dom.addClass(this._terminalContainer, 'terminal-outer-container'); + + this._findWidget = new TerminalFindWidget(this._contextViewService, this._terminalService); + this._parentDomElement.appendChild(this._themeStyleElement); this._parentDomElement.appendChild(this._fontStyleElement); this._parentDomElement.appendChild(this._terminalContainer); + this._parentDomElement.appendChild(this._findWidget.getDomNode()); this._attachEventListeners(); @@ -149,6 +156,14 @@ export class TerminalPanel extends Panel { } } + public focusFindWidget() { + this._findWidget.reveal(); + } + + public hideFindWidget() { + this._findWidget.hide(); + } + private _attachEventListeners(): void { this._register(dom.addDisposableListener(this._parentDomElement, 'mousedown', (event: MouseEvent) => { if (this._terminalService.terminalInstances.length === 0) { @@ -272,6 +287,7 @@ export class TerminalPanel extends Panel { } this._themeStyleElement.innerHTML = css; + this._findWidget.updateTheme(theme); } private _updateFont(): void { diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalService.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalService.ts index e731656e46d..5ce3dc18e9b 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalService.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalService.ts @@ -16,7 +16,7 @@ import { IWindowIPCService } from 'vs/workbench/services/window/electron-browser import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { IConfigurationEditingService, ConfigurationTarget } from 'vs/workbench/services/configuration/common/configurationEditing'; import { IQuickOpenService, IPickOpenEntry, IPickOptions } from 'vs/platform/quickOpen/common/quickOpen'; -import { ITerminalInstance, ITerminalService, IShellLaunchConfig, ITerminalConfigHelper, NEVER_SUGGEST_SELECT_WINDOWS_SHELL_STORAGE_KEY } from 'vs/workbench/parts/terminal/common/terminal'; +import { ITerminalInstance, ITerminalService, IShellLaunchConfig, ITerminalConfigHelper, NEVER_SUGGEST_SELECT_WINDOWS_SHELL_STORAGE_KEY, TERMINAL_PANEL_ID } from 'vs/workbench/parts/terminal/common/terminal'; import { TerminalService as AbstractTerminalService } from 'vs/workbench/parts/terminal/common/terminalService'; import { TerminalConfigHelper } from 'vs/workbench/parts/terminal/electron-browser/terminalConfigHelper'; import { TerminalInstance } from 'vs/workbench/parts/terminal/electron-browser/terminalInstance'; @@ -25,10 +25,10 @@ import { IChoiceService } from 'vs/platform/message/common/message'; import { Severity } from 'vs/editor/common/standalone/standaloneBase'; import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage'; import { TERMINAL_DEFAULT_SHELL_WINDOWS } from "vs/workbench/parts/terminal/electron-browser/terminal"; +import { TerminalPanel } from "vs/workbench/parts/terminal/electron-browser/terminalPanel"; export class TerminalService extends AbstractTerminalService implements ITerminalService { private _configHelper: TerminalConfigHelper; - public get configHelper(): ITerminalConfigHelper { return this._configHelper; }; constructor( @@ -69,6 +69,23 @@ export class TerminalService extends AbstractTerminalService implements ITermina return terminalInstance; } + public focusFindWidget(): TPromise { + return this.showPanel(false).then(() => { + let panel = this._panelService.getActivePanel() as TerminalPanel; + panel.focusFindWidget(); + this._findWidgetVisible.set(true); + }); + } + + public hideFindWidget(): void { + const panel = this._panelService.getActivePanel() as TerminalPanel; + if (panel && panel.getId() === TERMINAL_PANEL_ID) { + panel.hideFindWidget(); + this._findWidgetVisible.reset(); + panel.focus(); + } + } + private _suggestShellChange(wasNewTerminalAction?: boolean): void { // Only suggest on Windows since $SHELL works great for macOS/Linux if (!platform.isWindows) { -- GitLab From f37c1346b470acb4f0fdc859568203efe81ee261 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Wed, 14 Jun 2017 17:06:49 -0700 Subject: [PATCH 0846/1347] Use map for buffer sync support pending responses --- .../typescript/src/features/bufferSyncSupport.ts | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/extensions/typescript/src/features/bufferSyncSupport.ts b/extensions/typescript/src/features/bufferSyncSupport.ts index 05dbefb4a1a..64c8eea9a40 100644 --- a/extensions/typescript/src/features/bufferSyncSupport.ts +++ b/extensions/typescript/src/features/bufferSyncSupport.ts @@ -106,7 +106,7 @@ export default class BufferSyncSupport { private readonly disposables: Disposable[] = []; private readonly syncedBuffers: Map; - private pendingDiagnostics: { [key: string]: number; }; + private pendingDiagnostics = new Map(); private readonly diagnosticDelayer: Delayer; private checkGlobalTSCVersion: boolean; @@ -116,7 +116,6 @@ export default class BufferSyncSupport { this.diagnostics = diagnostics; this._validate = validate; - this.pendingDiagnostics = Object.create(null); this.diagnosticDelayer = new Delayer(300); this.syncedBuffers = new Map(); @@ -211,7 +210,7 @@ export default class BufferSyncSupport { return; } for (const filePath of this.syncedBuffers.keys()) { - this.pendingDiagnostics[filePath] = Date.now(); + this.pendingDiagnostics.set(filePath, Date.now()); } this.diagnosticDelayer.trigger(() => { this.sendPendingDiagnostics(); @@ -223,7 +222,7 @@ export default class BufferSyncSupport { return; } - this.pendingDiagnostics[file] = Date.now(); + this.pendingDiagnostics.set(file, Date.now()); const buffer = this.syncedBuffers.get(file); let delay = 300; if (buffer) { @@ -239,10 +238,10 @@ export default class BufferSyncSupport { if (!this._validate) { return; } - let files = Object.keys(this.pendingDiagnostics).map((key) => { + let files = Array.from(this.pendingDiagnostics.entries()).map(([key, value]) => { return { file: key, - time: this.pendingDiagnostics[key] + time: value }; }).sort((a, b) => { return a.time - b.time; @@ -252,7 +251,7 @@ export default class BufferSyncSupport { // Add all open TS buffers to the geterr request. They might be visible for (const file of this.syncedBuffers.keys()) { - if (!this.pendingDiagnostics[file]) { + if (!this.pendingDiagnostics.get(file)) { files.push(file); } } @@ -264,7 +263,7 @@ export default class BufferSyncSupport { }; this.client.execute('geterr', args, false); } - this.pendingDiagnostics = Object.create(null); + this.pendingDiagnostics.clear(); } private checkTSCVersion() { -- GitLab From 25056e6e53b8df1b45648e79e935bbc7b007884f Mon Sep 17 00:00:00 2001 From: rebornix Date: Wed, 14 Jun 2017 17:10:40 -0700 Subject: [PATCH 0847/1347] Terminal Find Widget context --- .../parts/terminal/electron-browser/terminal.contribution.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts index b58c93b8e22..bfc005a7fc1 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts @@ -280,7 +280,7 @@ actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(RenameTerminalAc actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(FocusTerminalFindWidgetAction, FocusTerminalFindWidgetAction.ID, FocusTerminalFindWidgetAction.LABEL, { primary: KeyMod.WinCtrl | KeyCode.Shift | KeyCode.KEY_F, mac: { primary: KeyMod.CtrlCmd | KeyCode.KEY_F } -}), 'Terminal: Focus Find Widget', nls.localize('Terminal: Focus Find Widget', category)); +}, KEYBINDING_CONTEXT_TERMINAL_FOCUS), 'Terminal: Focus Find Widget', nls.localize('Terminal: Focus Find Widget', category)); actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(HideTerminalFindWidgetAction, HideTerminalFindWidgetAction.ID, HideTerminalFindWidgetAction.LABEL, { primary: KeyCode.Escape }, KEYBINDING_CONTEXT_TERMINAL_FIND_WIDGET_VISIBLE), 'Terminal: Focus Find Widget', nls.localize('Terminal: Focus Find Widget', category)); -- GitLab From e27de3300a99ea2fc65235b38778253a4de286ce Mon Sep 17 00:00:00 2001 From: Rob Lourens Date: Wed, 14 Jun 2017 18:43:01 -0700 Subject: [PATCH 0848/1347] node-debug2@1.14.0 --- build/gulpfile.vscode.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index 7d48e3a93d8..e4e7211aaef 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -43,7 +43,7 @@ const nodeModules = ['electron', 'original-fs'] const builtInExtensions = [ { name: 'ms-vscode.node-debug', version: '1.14.1' }, - { name: 'ms-vscode.node-debug2', version: '1.13.3' } + { name: 'ms-vscode.node-debug2', version: '1.14.0' } ]; const vscodeEntryPoints = _.flatten([ -- GitLab From 081289866e73300bbce4d506a8d57b9dda8dd3b5 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Wed, 14 Jun 2017 19:42:44 -0700 Subject: [PATCH 0849/1347] Fix category error and keybindings --- .../electron-browser/terminal.contribution.ts | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts index bfc005a7fc1..85fa218b598 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts @@ -186,7 +186,9 @@ configurationRegistry.registerConfiguration({ FocusFirstGroupAction.ID, FocusSecondGroupAction.ID, FocusThirdGroupAction.ID, - SelectAllTerminalAction.ID + SelectAllTerminalAction.ID, + FocusTerminalFindWidgetAction.ID, + HideTerminalFindWidgetAction.ID ].sort() } } @@ -278,10 +280,9 @@ actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(AllowWorkspaceSh actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(DisallowWorkspaceShellTerminalCommand, DisallowWorkspaceShellTerminalCommand.ID, DisallowWorkspaceShellTerminalCommand.LABEL), 'Terminal: Disallow Workspace Shell Configuration', category); actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(RenameTerminalAction, RenameTerminalAction.ID, RenameTerminalAction.LABEL), 'Terminal: Rename', category); actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(FocusTerminalFindWidgetAction, FocusTerminalFindWidgetAction.ID, FocusTerminalFindWidgetAction.LABEL, { - primary: KeyMod.WinCtrl | KeyCode.Shift | KeyCode.KEY_F, - mac: { primary: KeyMod.CtrlCmd | KeyCode.KEY_F } -}, KEYBINDING_CONTEXT_TERMINAL_FOCUS), 'Terminal: Focus Find Widget', nls.localize('Terminal: Focus Find Widget', category)); + primary: KeyMod.CtrlCmd | KeyCode.KEY_F +}, KEYBINDING_CONTEXT_TERMINAL_FOCUS), 'Terminal: Focus Find Widget', category); actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(HideTerminalFindWidgetAction, HideTerminalFindWidgetAction.ID, HideTerminalFindWidgetAction.LABEL, { primary: KeyCode.Escape -}, KEYBINDING_CONTEXT_TERMINAL_FIND_WIDGET_VISIBLE), 'Terminal: Focus Find Widget', nls.localize('Terminal: Focus Find Widget', category)); +}, KEYBINDING_CONTEXT_TERMINAL_FIND_WIDGET_VISIBLE), 'Terminal: Focus Find Widget', category); registerColors(); -- GitLab From c89a5f66c646dd8c1f6d1692d90390660c765e62 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Wed, 14 Jun 2017 20:03:59 -0700 Subject: [PATCH 0850/1347] Focus terminal find on ctrl+f when it's visible and terminal is focused --- .../electron-browser/terminalFindWidget.ts | 25 +++++++++++-------- 1 file changed, 14 insertions(+), 11 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.ts index 7e38eeec167..8e8493811b8 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.ts @@ -182,19 +182,22 @@ export class TerminalFindWidget extends Widget { } public reveal(): void { - if (!this._isVisible) { - this._isVisible = true; + if (this._isVisible) { + this._findInput.select(); + return; + } + this._isVisible = true; + + setTimeout(() => { + dom.addClass(this._domNode, 'visible'); + this._domNode.setAttribute('aria-hidden', 'false'); + dom.addClass(this._domNode, 'noanimation'); setTimeout(() => { - dom.addClass(this._domNode, 'visible'); - this._domNode.setAttribute('aria-hidden', 'false'); - dom.addClass(this._domNode, 'noanimation'); - setTimeout(() => { - dom.removeClass(this._domNode, 'noanimation'); - this._findInput.select(); - }, 200); - }, 0); - } + dom.removeClass(this._domNode, 'noanimation'); + this._findInput.select(); + }, 200); + }, 0); } public hide(): void { -- GitLab From 6d5b99633b6c6636ac851bd40cd32da44072bfb5 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Thu, 15 Jun 2017 08:14:50 +0200 Subject: [PATCH 0851/1347] fix #28781 --- src/vs/workbench/api/node/extHostSCM.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/api/node/extHostSCM.ts b/src/vs/workbench/api/node/extHostSCM.ts index 8a87e5126c0..76c7078dda9 100644 --- a/src/vs/workbench/api/node/extHostSCM.ts +++ b/src/vs/workbench/api/node/extHostSCM.ts @@ -323,7 +323,10 @@ export class ExtHostSCM { return TPromise.as(null); } - return asWinJsPromise(token => URI.parse(sourceControl.quickDiffProvider.provideOriginalResource(uri, token).toString())); + return asWinJsPromise(token => { + const result = sourceControl.quickDiffProvider.provideOriginalResource(uri, token); + return result && URI.parse(result.toString()); + }); } $onActiveSourceControlChange(handle: number): TPromise { -- GitLab From ce1082248522c017d535c8a3b9386444090c9369 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 15 Jun 2017 08:21:04 +0200 Subject: [PATCH 0852/1347] Introduce a new keybinding context per quick open for quick navigate (fixes #28462) (#28784) --- src/vs/platform/quickOpen/common/quickOpen.ts | 5 + .../parts/editor/editor.contribution.ts | 39 +++- .../parts/quickopen/quickOpenController.ts | 50 ++++- .../parts/quickopen/quickopen.contribution.ts | 175 ++++-------------- .../browser/parts/quickopen/quickopen.ts | 132 +++++++++++++ src/vs/workbench/browser/quickopen.ts | 11 +- src/vs/workbench/electron-browser/actions.ts | 4 + .../electron-browser/workbench.main.ts | 1 + .../workbench/electron-browser/workbench.ts | 26 ++- .../electron-browser/debug.contribution.ts | 1 + .../extensions.contribution.ts | 2 + .../browser/quickopen.contribution.ts | 41 +++- .../search/browser/search.contribution.ts | 4 +- .../electron-browser/task.contribution.ts | 6 + .../electron-browser/terminal.contribution.ts | 2 +- .../watermark/electron-browser/watermark.ts | 2 +- .../workbench/test/browser/quickopen.test.ts | 3 +- 17 files changed, 344 insertions(+), 160 deletions(-) create mode 100644 src/vs/workbench/browser/parts/quickopen/quickopen.ts diff --git a/src/vs/platform/quickOpen/common/quickOpen.ts b/src/vs/platform/quickOpen/common/quickOpen.ts index 6fe5fcc6169..2ce7f0a3691 100644 --- a/src/vs/platform/quickOpen/common/quickOpen.ts +++ b/src/vs/platform/quickOpen/common/quickOpen.ts @@ -62,6 +62,11 @@ export interface IPickOptions { * enables quick navigate in the picker to open an element without typing */ quickNavigateConfiguration?: IQuickNavigateConfiguration; + + /** + * a context key to set when this picker is active + */ + contextKey?: string; } export interface IInputOptions { diff --git a/src/vs/workbench/browser/parts/editor/editor.contribution.ts b/src/vs/workbench/browser/parts/editor/editor.contribution.ts index cd4bc5a15ea..373bccf0f4e 100644 --- a/src/vs/workbench/browser/parts/editor/editor.contribution.ts +++ b/src/vs/workbench/browser/parts/editor/editor.contribution.ts @@ -36,6 +36,9 @@ import { } from 'vs/workbench/browser/parts/editor/editorActions'; import * as editorCommands from 'vs/workbench/browser/parts/editor/editorCommands'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; +import { getQuickNavigateHandler, inQuickOpenContext } from "vs/workbench/browser/parts/quickopen/quickopen"; +import { KeybindingsRegistry } from "vs/platform/keybinding/common/keybindingsRegistry"; +import { ContextKeyExpr } from "vs/platform/contextkey/common/contextkey"; // Register String Editor Registry.as(EditorExtensions.Editors).registerEditor( @@ -257,11 +260,15 @@ export class QuickOpenActionContributor extends ActionBarContributor { const actionBarRegistry = Registry.as(ActionBarExtensions.Actionbar); actionBarRegistry.registerActionBarContributor(Scope.VIEWER, QuickOpenActionContributor); +const editorPickerContextKey = 'inEditorsPicker'; +const editorPickerContext = ContextKeyExpr.and(inQuickOpenContext, ContextKeyExpr.has(editorPickerContextKey)); + Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpenHandler( new QuickOpenHandlerDescriptor( 'vs/workbench/browser/parts/editor/editorPicker', 'GroupOnePicker', NAVIGATE_IN_GROUP_ONE_PREFIX, + editorPickerContextKey, [ { prefix: NAVIGATE_IN_GROUP_ONE_PREFIX, @@ -287,6 +294,7 @@ Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpen 'vs/workbench/browser/parts/editor/editorPicker', 'GroupTwoPicker', NAVIGATE_IN_GROUP_TWO_PREFIX, + editorPickerContextKey, [] ) ); @@ -296,6 +304,7 @@ Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpen 'vs/workbench/browser/parts/editor/editorPicker', 'GroupThreePicker', NAVIGATE_IN_GROUP_THREE_PREFIX, + editorPickerContextKey, [] ) ); @@ -305,6 +314,7 @@ Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpen 'vs/workbench/browser/parts/editor/editorPicker', 'AllEditorsPicker', NAVIGATE_ALL_EDITORS_GROUP_PREFIX, + editorPickerContextKey, [ { prefix: NAVIGATE_ALL_EDITORS_GROUP_PREFIX, @@ -321,8 +331,6 @@ registry.registerWorkbenchAction(new SyncActionDescriptor(OpenNextEditorInGroup, registry.registerWorkbenchAction(new SyncActionDescriptor(OpenPreviousEditorInGroup, OpenPreviousEditorInGroup.ID, OpenPreviousEditorInGroup.LABEL), 'View: Open Previous Editor in Group', category); registry.registerWorkbenchAction(new SyncActionDescriptor(OpenNextRecentlyUsedEditorAction, OpenNextRecentlyUsedEditorAction.ID, OpenNextRecentlyUsedEditorAction.LABEL), 'View: Open Next Recently Used Editor', category); registry.registerWorkbenchAction(new SyncActionDescriptor(OpenPreviousRecentlyUsedEditorAction, OpenPreviousRecentlyUsedEditorAction.ID, OpenPreviousRecentlyUsedEditorAction.LABEL), 'View: Open Previous Recently Used Editor', category); -registry.registerWorkbenchAction(new SyncActionDescriptor(OpenNextRecentlyUsedEditorInGroupAction, OpenNextRecentlyUsedEditorInGroupAction.ID, OpenNextRecentlyUsedEditorInGroupAction.LABEL, { primary: KeyMod.CtrlCmd | KeyCode.Tab, mac: { primary: KeyMod.WinCtrl | KeyCode.Tab } }), 'Open Next Recently Used Editor in Group'); -registry.registerWorkbenchAction(new SyncActionDescriptor(OpenPreviousRecentlyUsedEditorInGroupAction, OpenPreviousRecentlyUsedEditorInGroupAction.ID, OpenPreviousRecentlyUsedEditorInGroupAction.LABEL, { primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.Tab, mac: { primary: KeyMod.WinCtrl | KeyMod.Shift | KeyCode.Tab } }), 'Open Previous Recently Used Editor in Group'); registry.registerWorkbenchAction(new SyncActionDescriptor(ShowAllEditorsAction, ShowAllEditorsAction.ID, ShowAllEditorsAction.LABEL, { primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KEY_K, KeyMod.CtrlCmd | KeyCode.KEY_P), mac: { primary: KeyMod.CtrlCmd | KeyMod.Alt | KeyCode.Tab } }), 'View: Show All Editors', category); registry.registerWorkbenchAction(new SyncActionDescriptor(ShowEditorsInGroupOneAction, ShowEditorsInGroupOneAction.ID, ShowEditorsInGroupOneAction.LABEL), 'View: Show Editors in First Group', category); registry.registerWorkbenchAction(new SyncActionDescriptor(ShowEditorsInGroupTwoAction, ShowEditorsInGroupTwoAction.ID, ShowEditorsInGroupTwoAction.LABEL), 'View: Show Editors in Second Group', category); @@ -363,5 +371,32 @@ registry.registerWorkbenchAction(new SyncActionDescriptor(OpenPreviousEditorFrom registry.registerWorkbenchAction(new SyncActionDescriptor(ClearEditorHistoryAction, ClearEditorHistoryAction.ID, ClearEditorHistoryAction.LABEL), 'Clear Editor History'); registry.registerWorkbenchAction(new SyncActionDescriptor(RevertAndCloseEditorAction, RevertAndCloseEditorAction.ID, RevertAndCloseEditorAction.LABEL), 'View: Revert and Close Editor', category); +// Register Editor Picker Actions including quick navigate support +const openNextEditorKeybinding = { primary: KeyMod.CtrlCmd | KeyCode.Tab, mac: { primary: KeyMod.WinCtrl | KeyCode.Tab } }; +const openPreviousEditorKeybinding = { primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.Tab, mac: { primary: KeyMod.WinCtrl | KeyMod.Shift | KeyCode.Tab } }; +registry.registerWorkbenchAction(new SyncActionDescriptor(OpenNextRecentlyUsedEditorInGroupAction, OpenNextRecentlyUsedEditorInGroupAction.ID, OpenNextRecentlyUsedEditorInGroupAction.LABEL, openNextEditorKeybinding), 'Open Next Recently Used Editor in Group'); +registry.registerWorkbenchAction(new SyncActionDescriptor(OpenPreviousRecentlyUsedEditorInGroupAction, OpenPreviousRecentlyUsedEditorInGroupAction.ID, OpenPreviousRecentlyUsedEditorInGroupAction.LABEL, openPreviousEditorKeybinding), 'Open Previous Recently Used Editor in Group'); + +const quickOpenNavigateNextInEditorPickerId = 'workbench.action.quickOpenNavigateNextInEditorPicker'; +KeybindingsRegistry.registerCommandAndKeybindingRule({ + id: quickOpenNavigateNextInEditorPickerId, + weight: KeybindingsRegistry.WEIGHT.workbenchContrib(50), + handler: getQuickNavigateHandler(quickOpenNavigateNextInEditorPickerId, true), + when: editorPickerContext, + primary: openNextEditorKeybinding.primary, + mac: openNextEditorKeybinding.mac +}); + +const quickOpenNavigatePreviousInEditorPickerId = 'workbench.action.quickOpenNavigatePreviousInEditorPicker'; +KeybindingsRegistry.registerCommandAndKeybindingRule({ + id: quickOpenNavigatePreviousInEditorPickerId, + weight: KeybindingsRegistry.WEIGHT.workbenchContrib(50), + handler: getQuickNavigateHandler(quickOpenNavigatePreviousInEditorPickerId, false), + when: editorPickerContext, + primary: openPreviousEditorKeybinding.primary, + mac: openPreviousEditorKeybinding.mac +}); + + // Editor Commands editorCommands.setup(); \ No newline at end of file diff --git a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts index 7a7872472ce..b8da38bc822 100644 --- a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts +++ b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts @@ -56,6 +56,7 @@ import { IEnvironmentService } from 'vs/platform/environment/common/environment' const HELP_PREFIX = '?'; interface IInternalPickOptions { + contextKey?: string; value?: string; valueSelection?: [number, number]; placeHolder?: string; @@ -84,6 +85,7 @@ export class QuickOpenController extends Component implements IQuickOpenService private pickOpenWidget: QuickOpenWidget; private layoutDimensions: Dimension; private mapResolvedHandlersToPrefix: { [prefix: string]: TPromise; }; + private mapContextKeyToContext: { [id: string]: IContextKey; }; private handlerOnOpenCalled: { [prefix: string]: boolean; }; private currentResultToken: string; private currentPickerToken: string; @@ -100,7 +102,7 @@ export class QuickOpenController extends Component implements IQuickOpenService @IMessageService private messageService: IMessageService, @ITelemetryService private telemetryService: ITelemetryService, @IWorkspaceContextService private contextService: IWorkspaceContextService, - @IContextKeyService contextKeyService: IContextKeyService, + @IContextKeyService private contextKeyService: IContextKeyService, @IConfigurationService private configurationService: IConfigurationService, @IHistoryService private historyService: IHistoryService, @IInstantiationService private instantiationService: IInstantiationService, @@ -112,6 +114,7 @@ export class QuickOpenController extends Component implements IQuickOpenService this.mapResolvedHandlersToPrefix = {}; this.handlerOnOpenCalled = {}; + this.mapContextKeyToContext = {}; this.promisesToCompleteOnHide = []; @@ -268,6 +271,9 @@ export class QuickOpenController extends Component implements IQuickOpenService const currentPickerToken = defaultGenerator.nextId(); this.currentPickerToken = currentPickerToken; + // Update context + this.setQuickOpenContextKey(options.contextKey); + // Create upon first open if (!this.pickOpenWidget) { this.pickOpenWidget = new QuickOpenWidget( @@ -578,6 +584,10 @@ export class QuickOpenController extends Component implements IQuickOpenService autoFocus = { autoFocusFirstEntry: visibleEditorCount === 0, autoFocusSecondEntry: visibleEditorCount !== 0 }; } + // Update context + const registry = Registry.as(Extensions.Quickopen); + this.setQuickOpenContextKey(registry.getDefaultQuickOpenHandler().contextKey); + this.quickOpenWidget.show(editorHistory, { quickNavigateConfiguration, autoFocus, inputSelection }); } } @@ -625,8 +635,8 @@ export class QuickOpenController extends Component implements IQuickOpenService const promise = this.mapResolvedHandlersToPrefix[prefix]; promise.then(handler => { this.handlerOnOpenCalled[prefix] = false; - // Don't check if onOpen was called to preserve old behaviour for now - handler.onClose(reason === HideReason.CANCELED); + + handler.onClose(reason === HideReason.CANCELED); // Don't check if onOpen was called to preserve old behaviour for now }); } } @@ -641,10 +651,39 @@ export class QuickOpenController extends Component implements IQuickOpenService this.restoreFocus(); // focus back to editor unless user clicked somewhere else } + // Reset context keys this.inQuickOpenMode.reset(); + this.resetQuickOpenContextKeys(); + + // Events this.emitQuickOpenVisibilityChange(false); } + private resetQuickOpenContextKeys(): void { + Object.keys(this.mapContextKeyToContext).forEach(k => this.mapContextKeyToContext[k].reset()); + } + + private setQuickOpenContextKey(id?: string): void { + let key: IContextKey; + if (id) { + key = this.mapContextKeyToContext[id]; + if (!key) { + key = new RawContextKey(id, false).bindTo(this.contextKeyService); + this.mapContextKeyToContext[id] = key; + } + } + + if (key && key.get()) { + return; // already active context + } + + this.resetQuickOpenContextKeys(); + + if (key) { + key.set(true); + } + } + private hasHandler(prefix: string): boolean { return !!Registry.as(Extensions.Quickopen).getQuickOpenHandler(prefix); } @@ -677,6 +716,7 @@ export class QuickOpenController extends Component implements IQuickOpenService const handlerDescriptor = registry.getQuickOpenHandler(value); const defaultHandlerDescriptor = registry.getDefaultQuickOpenHandler(); const instantProgress = handlerDescriptor && handlerDescriptor.instantProgress; + const contextKey = handlerDescriptor ? handlerDescriptor.contextKey : defaultHandlerDescriptor.contextKey; // Use a generated token to avoid race conditions from long running promises const currentResultToken = defaultGenerator.nextId(); @@ -690,6 +730,9 @@ export class QuickOpenController extends Component implements IQuickOpenService // Reset Extra Class this.quickOpenWidget.setExtraClass(null); + // Update context + this.setQuickOpenContextKey(contextKey); + // Remove leading and trailing whitespace const trimmedValue = strings.trim(value); @@ -701,6 +744,7 @@ export class QuickOpenController extends Component implements IQuickOpenService .done(null, errors.onUnexpectedError); this.quickOpenWidget.setInput(this.getEditorHistoryWithGroupLabel(), { autoFocusFirstEntry: true }); + return; } diff --git a/src/vs/workbench/browser/parts/quickopen/quickopen.contribution.ts b/src/vs/workbench/browser/parts/quickopen/quickopen.contribution.ts index 6d696c729c0..e263e028e10 100644 --- a/src/vs/workbench/browser/parts/quickopen/quickopen.contribution.ts +++ b/src/vs/workbench/browser/parts/quickopen/quickopen.contribution.ts @@ -5,121 +5,13 @@ 'use strict'; import { Registry } from 'vs/platform/platform'; -import { TPromise } from 'vs/base/common/winjs.base'; -import nls = require('vs/nls'); -import { Action } from 'vs/base/common/actions'; import { IQuickOpenService } from 'vs/platform/quickOpen/common/quickOpen'; -import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; -import { ContextKeyExpr } from 'vs/platform/contextkey/common/contextkey'; import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; import { KeyMod, KeyCode } from 'vs/base/common/keyCodes'; import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/workbench/common/actionRegistry'; -import { KeybindingsRegistry, IKeybindings } from 'vs/platform/keybinding/common/keybindingsRegistry'; +import { KeybindingsRegistry } from 'vs/platform/keybinding/common/keybindingsRegistry'; import { RemoveFromEditorHistoryAction } from 'vs/workbench/browser/parts/quickopen/quickOpenController'; - -export class GlobalQuickOpenAction extends Action { - - public static ID = 'workbench.action.quickOpen'; - public static LABEL = nls.localize('quickOpen', "Go to File..."); - - constructor(id: string, label: string, @IQuickOpenService private quickOpenService: IQuickOpenService) { - super(id, label); - - this.order = 100; // Allow other actions to position before or after - this.class = 'quickopen'; - } - - public run(): TPromise { - this.quickOpenService.show(null); - - return TPromise.as(true); - } -} - -export class BaseQuickOpenNavigateAction extends Action { - - constructor( - id: string, - label: string, - private next: boolean, - private quickNavigate: boolean, - @IQuickOpenService private quickOpenService: IQuickOpenService, - @IKeybindingService private keybindingService: IKeybindingService - ) { - super(id, label); - } - - public run(event?: any): TPromise { - const keys = this.keybindingService.lookupKeybindings(this.id); - const quickNavigate = this.quickNavigate ? { keybindings: keys } : void 0; - - this.quickOpenService.navigate(this.next, quickNavigate); - - return TPromise.as(true); - } -} - -export class QuickOpenNavigateNextAction extends BaseQuickOpenNavigateAction { - - public static ID = 'workbench.action.quickOpenNavigateNext'; - public static LABEL = nls.localize('quickNavigateNext', "Navigate Next in Quick Open"); - - constructor( - id: string, - label: string, - @IQuickOpenService quickOpenService: IQuickOpenService, - @IKeybindingService keybindingService: IKeybindingService - ) { - super(id, label, true, true, quickOpenService, keybindingService); - } -} - -export class QuickOpenNavigatePreviousAction extends BaseQuickOpenNavigateAction { - - public static ID = 'workbench.action.quickOpenNavigatePrevious'; - public static LABEL = nls.localize('quickNavigatePrevious', "Navigate Previous in Quick Open"); - - constructor( - id: string, - label: string, - @IQuickOpenService quickOpenService: IQuickOpenService, - @IKeybindingService keybindingService: IKeybindingService - ) { - super(id, label, false, true, quickOpenService, keybindingService); - } -} - -export class QuickOpenSelectNextAction extends BaseQuickOpenNavigateAction { - - public static ID = 'workbench.action.quickOpenSelectNext'; - public static LABEL = nls.localize('quickSelectNext', "Select Next in Quick Open"); - - constructor( - id: string, - label: string, - @IQuickOpenService quickOpenService: IQuickOpenService, - @IKeybindingService keybindingService: IKeybindingService - ) { - super(id, label, true, false, quickOpenService, keybindingService); - } -} - -export class QuickOpenSelectPreviousAction extends BaseQuickOpenNavigateAction { - - public static ID = 'workbench.action.quickOpenSelectPrevious'; - public static LABEL = nls.localize('quickSelectPrevious', "Select Previous in Quick Open"); - - constructor( - id: string, - label: string, - @IQuickOpenService quickOpenService: IQuickOpenService, - @IKeybindingService keybindingService: IKeybindingService - ) { - super(id, label, false, false, quickOpenService, keybindingService); - } -} - -const inQuickOpenContext = ContextKeyExpr.has('inQuickOpen'); +import { GlobalQuickOpenAction, QuickOpenSelectNextAction, QuickOpenSelectPreviousAction, inQuickOpenContext, getQuickNavigateHandler, QuickOpenNavigateNextAction, QuickOpenNavigatePreviousAction, defaultQuickOpenContext } from "vs/workbench/browser/parts/quickopen/quickopen"; KeybindingsRegistry.registerCommandAndKeybindingRule({ id: 'workbench.action.closeQuickOpen', @@ -154,41 +46,38 @@ KeybindingsRegistry.registerCommandAndKeybindingRule({ } }); -function navigateKeybinding(shift: boolean): IKeybindings { - if (!shift) { - return { - primary: KeyMod.CtrlCmd | KeyCode.Tab, - secondary: [KeyMod.CtrlCmd | KeyCode.KEY_Q, KeyMod.CtrlCmd | KeyCode.KEY_E, KeyMod.CtrlCmd | KeyCode.KEY_P], - mac: { - primary: KeyMod.WinCtrl | KeyCode.Tab, - secondary: [KeyMod.WinCtrl | KeyCode.KEY_Q, KeyMod.CtrlCmd | KeyCode.KEY_P] - }, - linux: { - primary: KeyMod.CtrlCmd | KeyCode.Tab, - secondary: [KeyMod.CtrlCmd | KeyCode.KEY_E, KeyMod.CtrlCmd | KeyCode.KEY_P] - } - }; - } - - return { - primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.Tab, - secondary: [KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_Q, KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_E, KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_P], - mac: { - primary: KeyMod.WinCtrl | KeyMod.Shift | KeyCode.Tab, - secondary: [KeyMod.WinCtrl | KeyMod.Shift | KeyCode.KEY_Q, KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_P] - }, - linux: { - primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.Tab, - secondary: [KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_E, KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_P] - } - }; -} - const registry = Registry.as(ActionExtensions.WorkbenchActions); -registry.registerWorkbenchAction(new SyncActionDescriptor(GlobalQuickOpenAction, GlobalQuickOpenAction.ID, GlobalQuickOpenAction.LABEL, { primary: KeyMod.CtrlCmd | KeyCode.KEY_P, secondary: [KeyMod.CtrlCmd | KeyCode.KEY_E], mac: { primary: KeyMod.CtrlCmd | KeyCode.KEY_P, secondary: null } }), 'Go to File...'); -registry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenNavigateNextAction, QuickOpenNavigateNextAction.ID, QuickOpenNavigateNextAction.LABEL, navigateKeybinding(false), inQuickOpenContext, KeybindingsRegistry.WEIGHT.workbenchContrib(50)), 'Navigate Next in Quick Open'); -registry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenNavigatePreviousAction, QuickOpenNavigatePreviousAction.ID, QuickOpenNavigatePreviousAction.LABEL, navigateKeybinding(true), inQuickOpenContext, KeybindingsRegistry.WEIGHT.workbenchContrib(50)), 'Navigate Previous in Quick Open'); +const globalQuickOpenKeybinding = { primary: KeyMod.CtrlCmd | KeyCode.KEY_P, secondary: [KeyMod.CtrlCmd | KeyCode.KEY_E], mac: { primary: KeyMod.CtrlCmd | KeyCode.KEY_P, secondary: null } }; + +registry.registerWorkbenchAction(new SyncActionDescriptor(GlobalQuickOpenAction, GlobalQuickOpenAction.ID, GlobalQuickOpenAction.LABEL, globalQuickOpenKeybinding), 'Go to File...'); registry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenSelectNextAction, QuickOpenSelectNextAction.ID, QuickOpenSelectNextAction.LABEL, { primary: null, mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_N } }, inQuickOpenContext, KeybindingsRegistry.WEIGHT.workbenchContrib(50)), 'Select Next in Quick Open'); registry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenSelectPreviousAction, QuickOpenSelectPreviousAction.ID, QuickOpenSelectPreviousAction.LABEL, { primary: null, mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_P } }, inQuickOpenContext, KeybindingsRegistry.WEIGHT.workbenchContrib(50)), 'Select Previous in Quick Open'); +registry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenNavigateNextAction, QuickOpenNavigateNextAction.ID, QuickOpenNavigateNextAction.LABEL), 'Navigate Next in Quick Open'); +registry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenNavigatePreviousAction, QuickOpenNavigatePreviousAction.ID, QuickOpenNavigatePreviousAction.LABEL), 'Navigate Previous in Quick Open'); registry.registerWorkbenchAction(new SyncActionDescriptor(RemoveFromEditorHistoryAction, RemoveFromEditorHistoryAction.ID, RemoveFromEditorHistoryAction.LABEL), 'Remove From History'); + +const quickOpenNavigateNextInFilePickerId = 'workbench.action.quickOpenNavigateNextInFilePicker'; +KeybindingsRegistry.registerCommandAndKeybindingRule({ + id: quickOpenNavigateNextInFilePickerId, + weight: KeybindingsRegistry.WEIGHT.workbenchContrib(50), + handler: getQuickNavigateHandler(quickOpenNavigateNextInFilePickerId, true), + when: defaultQuickOpenContext, + primary: globalQuickOpenKeybinding.primary, + secondary: globalQuickOpenKeybinding.secondary, + mac: globalQuickOpenKeybinding.mac +}); + +const quickOpenNavigatePreviousInFilePickerId = 'workbench.action.quickOpenNavigatePreviousInFilePicker'; +KeybindingsRegistry.registerCommandAndKeybindingRule({ + id: quickOpenNavigatePreviousInFilePickerId, + weight: KeybindingsRegistry.WEIGHT.workbenchContrib(50), + handler: getQuickNavigateHandler(quickOpenNavigatePreviousInFilePickerId, false), + when: defaultQuickOpenContext, + primary: globalQuickOpenKeybinding.primary | KeyMod.Shift, + secondary: [globalQuickOpenKeybinding.secondary[0] | KeyMod.Shift], + mac: { + primary: globalQuickOpenKeybinding.mac.primary | KeyMod.Shift, + secondary: null + } +}); \ No newline at end of file diff --git a/src/vs/workbench/browser/parts/quickopen/quickopen.ts b/src/vs/workbench/browser/parts/quickopen/quickopen.ts new file mode 100644 index 00000000000..be16c8f57b2 --- /dev/null +++ b/src/vs/workbench/browser/parts/quickopen/quickopen.ts @@ -0,0 +1,132 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +'use strict'; + +import { TPromise } from 'vs/base/common/winjs.base'; +import nls = require('vs/nls'); +import { Action } from 'vs/base/common/actions'; +import { IQuickOpenService } from 'vs/platform/quickOpen/common/quickOpen'; +import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; +import { ContextKeyExpr } from "vs/platform/contextkey/common/contextkey"; +import { ICommandHandler } from "vs/platform/commands/common/commands"; + +export const inQuickOpenContext = ContextKeyExpr.has('inQuickOpen'); +export const defaultQuickOpenContextKey = 'inFilesPicker'; +export const defaultQuickOpenContext = ContextKeyExpr.and(inQuickOpenContext, ContextKeyExpr.has(defaultQuickOpenContextKey)); + +export class GlobalQuickOpenAction extends Action { + + public static ID = 'workbench.action.quickOpen'; + public static LABEL = nls.localize('quickOpen', "Go to File..."); + + constructor(id: string, label: string, @IQuickOpenService private quickOpenService: IQuickOpenService) { + super(id, label); + + this.order = 100; // Allow other actions to position before or after + this.class = 'quickopen'; + } + + public run(): TPromise { + this.quickOpenService.show(null); + + return TPromise.as(true); + } +} + +export class BaseQuickOpenNavigateAction extends Action { + + constructor( + id: string, + label: string, + private next: boolean, + private quickNavigate: boolean, + @IQuickOpenService private quickOpenService: IQuickOpenService, + @IKeybindingService private keybindingService: IKeybindingService + ) { + super(id, label); + } + + public run(event?: any): TPromise { + const keys = this.keybindingService.lookupKeybindings(this.id); + const quickNavigate = this.quickNavigate ? { keybindings: keys } : void 0; + + this.quickOpenService.navigate(this.next, quickNavigate); + + return TPromise.as(true); + } +} + +export function getQuickNavigateHandler(id: string, next?: boolean): ICommandHandler { + return accessor => { + const keybindingService = accessor.get(IKeybindingService); + const quickOpenService = accessor.get(IQuickOpenService); + + const keys = keybindingService.lookupKeybindings(id); + const quickNavigate = { keybindings: keys }; + + quickOpenService.navigate(next, quickNavigate); + }; +} + +export class QuickOpenNavigateNextAction extends BaseQuickOpenNavigateAction { + + public static ID = 'workbench.action.quickOpenNavigateNext'; + public static LABEL = nls.localize('quickNavigateNext', "Navigate Next in Quick Open"); + + constructor( + id: string, + label: string, + @IQuickOpenService quickOpenService: IQuickOpenService, + @IKeybindingService keybindingService: IKeybindingService + ) { + super(id, label, true, true, quickOpenService, keybindingService); + } +} + +export class QuickOpenNavigatePreviousAction extends BaseQuickOpenNavigateAction { + + public static ID = 'workbench.action.quickOpenNavigatePrevious'; + public static LABEL = nls.localize('quickNavigatePrevious', "Navigate Previous in Quick Open"); + + constructor( + id: string, + label: string, + @IQuickOpenService quickOpenService: IQuickOpenService, + @IKeybindingService keybindingService: IKeybindingService + ) { + super(id, label, false, true, quickOpenService, keybindingService); + } +} + +export class QuickOpenSelectNextAction extends BaseQuickOpenNavigateAction { + + public static ID = 'workbench.action.quickOpenSelectNext'; + public static LABEL = nls.localize('quickSelectNext', "Select Next in Quick Open"); + + constructor( + id: string, + label: string, + @IQuickOpenService quickOpenService: IQuickOpenService, + @IKeybindingService keybindingService: IKeybindingService + ) { + super(id, label, true, false, quickOpenService, keybindingService); + } +} + +export class QuickOpenSelectPreviousAction extends BaseQuickOpenNavigateAction { + + public static ID = 'workbench.action.quickOpenSelectPrevious'; + public static LABEL = nls.localize('quickSelectPrevious', "Select Previous in Quick Open"); + + constructor( + id: string, + label: string, + @IQuickOpenService quickOpenService: IQuickOpenService, + @IKeybindingService keybindingService: IKeybindingService + ) { + super(id, label, false, false, quickOpenService, keybindingService); + } +} \ No newline at end of file diff --git a/src/vs/workbench/browser/quickopen.ts b/src/vs/workbench/browser/quickopen.ts index 152265f629a..62941ff5712 100644 --- a/src/vs/workbench/browser/quickopen.ts +++ b/src/vs/workbench/browser/quickopen.ts @@ -131,18 +131,21 @@ export interface QuickOpenHandlerHelpEntry { export class QuickOpenHandlerDescriptor extends AsyncDescriptor { public prefix: string; public description: string; + public contextKey: string; public isDefault: boolean; public helpEntries: QuickOpenHandlerHelpEntry[]; public instantProgress: boolean; + private id: string; - constructor(moduleId: string, ctorName: string, prefix: string, description: string, instantProgress?: boolean); - constructor(moduleId: string, ctorName: string, prefix: string, helpEntries: QuickOpenHandlerHelpEntry[], instantProgress?: boolean); - constructor(moduleId: string, ctorName: string, prefix: string, param: any, instantProgress: boolean = false) { + constructor(moduleId: string, ctorName: string, prefix: string, contextKey: string, description: string, instantProgress?: boolean); + constructor(moduleId: string, ctorName: string, prefix: string, contextKey: string, helpEntries: QuickOpenHandlerHelpEntry[], instantProgress?: boolean); + constructor(moduleId: string, ctorName: string, prefix: string, contextKey: string, param: any, instantProgress: boolean = false) { super(moduleId, ctorName); - this.prefix = prefix; this.id = moduleId + ctorName; + this.prefix = prefix; + this.contextKey = contextKey; this.instantProgress = instantProgress; if (types.isString(param)) { diff --git a/src/vs/workbench/electron-browser/actions.ts b/src/vs/workbench/electron-browser/actions.ts index ef63d8a7cf6..3f8b05dab1f 100644 --- a/src/vs/workbench/electron-browser/actions.ts +++ b/src/vs/workbench/electron-browser/actions.ts @@ -591,6 +591,7 @@ export abstract class BaseSwitchWindow extends Action { } as IFilePickOpenEntry)); this.quickOpenService.pick(picks, { + contextKey: 'inWindowsPicker', autoFocus: { autoFocusFirstEntry: true }, placeHolder, quickNavigateConfiguration: this.isQuickNavigate() ? { keybindings: this.keybindingService.lookupKeybindings(this.id) } : void 0 @@ -641,6 +642,8 @@ export class QuickSwitchWindow extends BaseSwitchWindow { } } +export const inRecentFilesPickerContextKey = 'inRecentFilesPicker'; + export abstract class BaseOpenRecentAction extends Action { constructor( @@ -693,6 +696,7 @@ export abstract class BaseOpenRecentAction extends Action { const hasWorkspace = this.contextService.hasWorkspace(); this.quickOpenService.pick(folderPicks.concat(...filePicks), { + contextKey: inRecentFilesPickerContextKey, autoFocus: { autoFocusFirstEntry: !hasWorkspace, autoFocusSecondEntry: hasWorkspace }, placeHolder: isMacintosh ? nls.localize('openRecentPlaceHolderMac', "Select a path (hold Cmd-key to open in new window)") : nls.localize('openRecentPlaceHolder', "Select a path to open (hold Ctrl-key to open in new window)"), matchOnDescription: true, diff --git a/src/vs/workbench/electron-browser/workbench.main.ts b/src/vs/workbench/electron-browser/workbench.main.ts index a8fee7959d0..d68ce2e3acf 100644 --- a/src/vs/workbench/electron-browser/workbench.main.ts +++ b/src/vs/workbench/electron-browser/workbench.main.ts @@ -31,6 +31,7 @@ import 'vs/workbench/parts/preferences/browser/preferences.contribution'; import 'vs/workbench/parts/preferences/browser/keybindingsEditorContribution'; import 'vs/workbench/browser/actions/configureLocale'; +import 'vs/workbench/browser/parts/quickopen/quickopen.contribution'; import 'vs/workbench/parts/quickopen/browser/quickopen.contribution'; import 'vs/workbench/browser/parts/editor/editorPicker'; diff --git a/src/vs/workbench/electron-browser/workbench.ts b/src/vs/workbench/electron-browser/workbench.ts index 3256b4b5152..277811b7aac 100644 --- a/src/vs/workbench/electron-browser/workbench.ts +++ b/src/vs/workbench/electron-browser/workbench.ts @@ -92,9 +92,11 @@ import { IContextMenuService } from 'vs/platform/contextview/browser/contextView import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IWorkbenchActionRegistry, Extensions } from 'vs/workbench/common/actionRegistry'; -import { OpenRecentAction, ToggleDevToolsAction, ReloadWindowAction } from "vs/workbench/electron-browser/actions"; +import { OpenRecentAction, ToggleDevToolsAction, ReloadWindowAction, inRecentFilesPickerContextKey } from "vs/workbench/electron-browser/actions"; import { KeyMod } from 'vs/base/common/keyCodes'; import { KeyCode } from 'vs/editor/common/standalone/standaloneBase'; +import { KeybindingsRegistry } from "vs/platform/keybinding/common/keybindingsRegistry"; +import { getQuickNavigateHandler, inQuickOpenContext } from "vs/workbench/browser/parts/quickopen/quickopen"; export const MessagesVisibleContext = new RawContextKey('globalMessageVisible', false); export const EditorsVisibleContext = new RawContextKey('editorIsOpen', false); @@ -393,6 +395,28 @@ export class Workbench implements IPartService { workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(ReloadWindowAction, ReloadWindowAction.ID, ReloadWindowAction.LABEL, isDeveloping ? { primary: KeyMod.CtrlCmd | KeyCode.KEY_R } : void 0), 'Reload Window'); workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(ToggleDevToolsAction, ToggleDevToolsAction.ID, ToggleDevToolsAction.LABEL, isDeveloping ? { primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_I, mac: { primary: KeyMod.CtrlCmd | KeyMod.Alt | KeyCode.KEY_I } } : void 0), 'Developer: Toggle Developer Tools', localize('developer', "Developer")); workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(OpenRecentAction, OpenRecentAction.ID, OpenRecentAction.LABEL, { primary: isDeveloping ? null : KeyMod.CtrlCmd | KeyCode.KEY_R, mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_R } }), 'File: Open Recent...', localize('file', "File")); + + const recentFilesPickerContext = ContextKeyExpr.and(inQuickOpenContext, ContextKeyExpr.has(inRecentFilesPickerContextKey)); + + const quickOpenNavigateNextInRecentFilesPickerId = 'workbench.action.quickOpenNavigateNextInRecentFilesPicker'; + KeybindingsRegistry.registerCommandAndKeybindingRule({ + id: quickOpenNavigateNextInRecentFilesPickerId, + weight: KeybindingsRegistry.WEIGHT.workbenchContrib(50), + handler: getQuickNavigateHandler(quickOpenNavigateNextInRecentFilesPickerId, true), + when: recentFilesPickerContext, + primary: KeyMod.CtrlCmd | KeyCode.KEY_R, + mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_R } + }); + + const quickOpenNavigatePreviousInRecentFilesPicker = 'workbench.action.quickOpenNavigatePreviousInRecentFilesPicker'; + KeybindingsRegistry.registerCommandAndKeybindingRule({ + id: quickOpenNavigatePreviousInRecentFilesPicker, + weight: KeybindingsRegistry.WEIGHT.workbenchContrib(50), + handler: getQuickNavigateHandler(quickOpenNavigatePreviousInRecentFilesPicker, false), + when: recentFilesPickerContext, + primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_R, + mac: { primary: KeyMod.WinCtrl | KeyMod.Shift | KeyCode.KEY_R } + }); } private resolveEditorsToOpen(): TPromise { diff --git a/src/vs/workbench/parts/debug/electron-browser/debug.contribution.ts b/src/vs/workbench/parts/debug/electron-browser/debug.contribution.ts index 368615a85a9..c8c0e1831dd 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debug.contribution.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debug.contribution.ts @@ -137,6 +137,7 @@ registry.registerWorkbenchAction(new SyncActionDescriptor(SelectAndStartAction, 'vs/workbench/parts/debug/browser/debugQuickOpen', 'DebugQuickOpenHandler', 'debug ', + 'inLaunchConfigurationsPicker', nls.localize('debugCommands', "Debug Configuration") ) ); diff --git a/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.ts b/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.ts index 34b56a366bb..e286fc06d05 100644 --- a/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.ts +++ b/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.ts @@ -59,6 +59,7 @@ Registry.as(Extensions.Quickopen).registerQuickOpenHandler( 'vs/workbench/parts/extensions/browser/extensionsQuickOpen', 'ExtensionsHandler', 'ext ', + null, localize('extensionsCommands', "Manage Extensions"), true ) @@ -69,6 +70,7 @@ Registry.as(Extensions.Quickopen).registerQuickOpenHandler( 'vs/workbench/parts/extensions/browser/extensionsQuickOpen', 'GalleryExtensionsHandler', 'ext install ', + null, localize('galleryExtensionsCommands', "Install Gallery Extensions"), true ) diff --git a/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts b/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts index 606e882af9b..23c643f7d2b 100644 --- a/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts +++ b/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts @@ -17,6 +17,9 @@ import { ShowAllCommandsAction, ALL_COMMANDS_PREFIX, ClearCommandHistoryAction } import { GotoLineAction, GOTO_LINE_PREFIX } from 'vs/workbench/parts/quickopen/browser/gotoLineHandler'; import { HELP_PREFIX } from 'vs/workbench/parts/quickopen/browser/helpHandler'; import { VIEW_PICKER_PREFIX, OpenViewPickerAction, QuickOpenViewPickerAction } from 'vs/workbench/parts/quickopen/browser/viewPickerHandler'; +import { inQuickOpenContext, getQuickNavigateHandler } from "vs/workbench/browser/parts/quickopen/quickopen"; +import { ContextKeyExpr } from "vs/platform/contextkey/common/contextkey"; +import { KeybindingsRegistry } from "vs/platform/keybinding/common/keybindingsRegistry"; // Register Actions const registry = Registry.as(ActionExtensions.WorkbenchActions); @@ -35,10 +38,37 @@ registry.registerWorkbenchAction(new SyncActionDescriptor(GotoSymbolAction, Goto primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_O }), 'Go to Symbol in File...'); +const inViewsPickerContextKey = 'inViewsPicker'; +const inViewsPickerContext = ContextKeyExpr.and(inQuickOpenContext, ContextKeyExpr.has(inViewsPickerContextKey)); + +const viewPickerKeybinding = { primary: KeyMod.CtrlCmd | KeyCode.KEY_Q, mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_Q }, linux: { primary: null } }; + registry.registerWorkbenchAction(new SyncActionDescriptor(OpenViewPickerAction, OpenViewPickerAction.ID, OpenViewPickerAction.LABEL), 'Open View'); -registry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenViewPickerAction, QuickOpenViewPickerAction.ID, QuickOpenViewPickerAction.LABEL, { - primary: KeyMod.CtrlCmd | KeyCode.KEY_Q, mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_Q }, linux: { primary: null } -}), 'Quick Open View'); +registry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenViewPickerAction, QuickOpenViewPickerAction.ID, QuickOpenViewPickerAction.LABEL, viewPickerKeybinding), 'Quick Open View'); + +const quickOpenNavigateNextInViewPickerId = 'workbench.action.quickOpenNavigateNextInViewPicker'; +KeybindingsRegistry.registerCommandAndKeybindingRule({ + id: quickOpenNavigateNextInViewPickerId, + weight: KeybindingsRegistry.WEIGHT.workbenchContrib(50), + handler: getQuickNavigateHandler(quickOpenNavigateNextInViewPickerId, true), + when: inViewsPickerContext, + primary: viewPickerKeybinding.primary, + linux: viewPickerKeybinding.linux, + mac: viewPickerKeybinding.mac +}); + +const quickOpenNavigatePreviousInViewPickerId = 'workbench.action.quickOpenNavigatePreviousInViewPicker'; +KeybindingsRegistry.registerCommandAndKeybindingRule({ + id: quickOpenNavigatePreviousInViewPickerId, + weight: KeybindingsRegistry.WEIGHT.workbenchContrib(50), + handler: getQuickNavigateHandler(quickOpenNavigatePreviousInViewPickerId, false), + when: inViewsPickerContext, + primary: viewPickerKeybinding.primary | KeyMod.Shift, + linux: viewPickerKeybinding.linux, + mac: { + primary: viewPickerKeybinding.mac.primary | KeyMod.Shift + } +}); // Register Quick Open Handler @@ -47,6 +77,7 @@ Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpen 'vs/workbench/parts/quickopen/browser/commandsHandler', 'CommandsHandler', ALL_COMMANDS_PREFIX, + 'inCommandsPicker', nls.localize('commandsHandlerDescriptionDefault', "Show and Run Commands") ) ); @@ -56,6 +87,7 @@ Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpen 'vs/workbench/parts/quickopen/browser/gotoLineHandler', 'GotoLineHandler', GOTO_LINE_PREFIX, + null, [ { prefix: GOTO_LINE_PREFIX, @@ -71,6 +103,7 @@ Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpen 'vs/workbench/parts/quickopen/browser/gotoSymbolHandler', 'GotoSymbolHandler', GOTO_SYMBOL_PREFIX, + 'inFileSymbolsPicker', [ { prefix: GOTO_SYMBOL_PREFIX, @@ -91,6 +124,7 @@ Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpen 'vs/workbench/parts/quickopen/browser/helpHandler', 'HelpHandler', HELP_PREFIX, + null, nls.localize('helpDescription', "Show Help") ) ); @@ -100,6 +134,7 @@ Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpen 'vs/workbench/parts/quickopen/browser/viewPickerHandler', 'ViewPickerHandler', VIEW_PICKER_PREFIX, + inViewsPickerContextKey, [ { prefix: VIEW_PICKER_PREFIX, diff --git a/src/vs/workbench/parts/search/browser/search.contribution.ts b/src/vs/workbench/parts/search/browser/search.contribution.ts index a03f6572e09..b4d892ab721 100644 --- a/src/vs/workbench/parts/search/browser/search.contribution.ts +++ b/src/vs/workbench/parts/search/browser/search.contribution.ts @@ -35,8 +35,8 @@ import { ISearchWorkbenchService, SearchWorkbenchService } from 'vs/workbench/pa import { CommandsRegistry } from 'vs/platform/commands/common/commands'; import { SearchViewlet } from 'vs/workbench/parts/search/browser/searchViewlet'; import { ListFocusContext } from 'vs/platform/list/browser/listService'; - import { IOutputChannelRegistry, Extensions as OutputExt } from 'vs/workbench/parts/output/common/output'; +import { defaultQuickOpenContextKey } from "vs/workbench/browser/parts/quickopen/quickopen"; registerSingleton(ISearchWorkbenchService, SearchWorkbenchService); replaceContributions(); @@ -274,6 +274,7 @@ Registry.as(QuickOpenExtensions.Quickopen).registerDefaultQu 'vs/workbench/parts/search/browser/openAnythingHandler', 'OpenAnythingHandler', '', + defaultQuickOpenContextKey, nls.localize('openAnythingHandlerDescription', "Go to File") ) ); @@ -283,6 +284,7 @@ Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpen 'vs/workbench/parts/search/browser/openAnythingHandler', 'OpenSymbolHandler', ALL_SYMBOLS_PREFIX, + 'inWorkspaceSymbolsPicker', [ { prefix: ALL_SYMBOLS_PREFIX, diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index 529b36f8f0c..a5a53dae147 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -1514,12 +1514,14 @@ registerSingleton(ITaskService, TaskService); // Register Quick Open const quickOpenRegistry = (Registry.as(QuickOpenExtensions.Quickopen)); +const tasksPickerContextKey = 'inTasksPicker'; quickOpenRegistry.registerQuickOpenHandler( new QuickOpenHandlerDescriptor( 'vs/workbench/parts/tasks/browser/taskQuickOpen', 'QuickOpenHandler', 'task ', + tasksPickerContextKey, nls.localize('quickOpen.task', "Run Task") ) ); @@ -1529,6 +1531,7 @@ quickOpenRegistry.registerQuickOpenHandler( 'vs/workbench/parts/tasks/browser/terminateQuickOpen', 'QuickOpenHandler', 'terminate task ', + tasksPickerContextKey, nls.localize('quickOpen.terminateTask', "Terminate Task") ) ); @@ -1538,6 +1541,7 @@ quickOpenRegistry.registerQuickOpenHandler( 'vs/workbench/parts/tasks/browser/restartQuickOpen', 'QuickOpenHandler', 'restart task ', + tasksPickerContextKey, nls.localize('quickOpen.restartTask', "Restart Task") ) ); @@ -1547,6 +1551,7 @@ quickOpenRegistry.registerQuickOpenHandler( 'vs/workbench/parts/tasks/browser/buildQuickOpen', 'QuickOpenHandler', 'build task ', + tasksPickerContextKey, nls.localize('quickOpen.buildTask', "Build Task") ) ); @@ -1556,6 +1561,7 @@ quickOpenRegistry.registerQuickOpenHandler( 'vs/workbench/parts/tasks/browser/testQuickOpen', 'QuickOpenHandler', 'test task ', + tasksPickerContextKey, nls.localize('quickOpen.testTask', "Test Task") ) ); diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts index 85fa218b598..b12e4812b9b 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts @@ -12,7 +12,7 @@ import * as nls from 'vs/nls'; import * as panel from 'vs/workbench/browser/panel'; import * as platform from 'vs/base/common/platform'; import { Extensions, IConfigurationRegistry } from 'vs/platform/configuration/common/configurationRegistry'; -import { GlobalQuickOpenAction } from 'vs/workbench/browser/parts/quickopen/quickopen.contribution'; +import { GlobalQuickOpenAction } from 'vs/workbench/browser/parts/quickopen/quickopen'; import { ITerminalService, KEYBINDING_CONTEXT_TERMINAL_FOCUS, KEYBINDING_CONTEXT_TERMINAL_TEXT_SELECTED, TERMINAL_PANEL_ID, TERMINAL_DEFAULT_RIGHT_CLICK_COPY_PASTE, KEYBINDING_CONTEXT_TERMINAL_FIND_WIDGET_VISIBLE, TerminalCursorStyle } from 'vs/workbench/parts/terminal/common/terminal'; import { TERMINAL_DEFAULT_SHELL_LINUX, TERMINAL_DEFAULT_SHELL_OSX, TERMINAL_DEFAULT_SHELL_WINDOWS } from 'vs/workbench/parts/terminal/electron-browser/terminal'; import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/workbench/common/actionRegistry'; diff --git a/src/vs/workbench/parts/watermark/electron-browser/watermark.ts b/src/vs/workbench/parts/watermark/electron-browser/watermark.ts index a6e55adf5c8..c28efbc3fc6 100644 --- a/src/vs/workbench/parts/watermark/electron-browser/watermark.ts +++ b/src/vs/workbench/parts/watermark/electron-browser/watermark.ts @@ -18,7 +18,7 @@ import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace import { IWorkbenchContribution, IWorkbenchContributionsRegistry, Extensions as WorkbenchExtensions } from 'vs/workbench/common/contributions'; import { ILifecycleService } from 'vs/platform/lifecycle/common/lifecycle'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { GlobalQuickOpenAction } from 'vs/workbench/browser/parts/quickopen/quickopen.contribution'; +import { GlobalQuickOpenAction } from 'vs/workbench/browser/parts/quickopen/quickopen'; import { KeybindingsReferenceAction, OpenRecentAction } from 'vs/workbench/electron-browser/actions'; import { ShowRecommendedKeymapExtensionsAction } from 'vs/workbench/parts/extensions/browser/extensionsActions'; import { GlobalNewUntitledFileAction, OpenFileAction } from 'vs/workbench/parts/files/browser/fileActions'; diff --git a/src/vs/workbench/test/browser/quickopen.test.ts b/src/vs/workbench/test/browser/quickopen.test.ts index caee483e75e..17baa336943 100644 --- a/src/vs/workbench/test/browser/quickopen.test.ts +++ b/src/vs/workbench/test/browser/quickopen.test.ts @@ -67,7 +67,8 @@ suite('Workbench QuickOpen', () => { 'test', 'TestHandler', ',', - 'Handler' + 'Handler', + null ); registry.registerQuickOpenHandler(handler); -- GitLab From 079ad467d5d2564c6ff42ab9f9949e6d4ca5ec84 Mon Sep 17 00:00:00 2001 From: Soney Mathew Date: Thu, 15 Jun 2017 16:21:56 +1000 Subject: [PATCH 0853/1347] Provide a command to close all unchanged files (#25692) --- .../parts/editor/editor.contribution.ts | 3 +- .../browser/parts/editor/editorActions.ts | 28 +++++++++++++++++++ .../browser/parts/editor/titleControl.ts | 7 ++++- .../files/browser/views/openEditorsViewer.ts | 5 +++- 4 files changed, 40 insertions(+), 3 deletions(-) diff --git a/src/vs/workbench/browser/parts/editor/editor.contribution.ts b/src/vs/workbench/browser/parts/editor/editor.contribution.ts index 373bccf0f4e..4f7181fbe59 100644 --- a/src/vs/workbench/browser/parts/editor/editor.contribution.ts +++ b/src/vs/workbench/browser/parts/editor/editor.contribution.ts @@ -30,7 +30,7 @@ import { KeyMod, KeyChord, KeyCode } from 'vs/base/common/keyCodes'; import { CloseEditorsInGroupAction, CloseEditorsInOtherGroupsAction, CloseAllEditorsAction, MoveGroupLeftAction, MoveGroupRightAction, SplitEditorAction, JoinTwoGroupsAction, KeepEditorAction, CloseOtherEditorsInGroupAction, OpenToSideAction, RevertAndCloseEditorAction, NavigateBetweenGroupsAction, FocusActiveGroupAction, FocusFirstGroupAction, FocusSecondGroupAction, FocusThirdGroupAction, EvenGroupWidthsAction, MaximizeGroupAction, MinimizeOtherGroupsAction, FocusPreviousGroup, FocusNextGroup, ShowEditorsInGroupOneAction, - toEditorQuickOpenEntry, CloseLeftEditorsInGroupAction, CloseRightEditorsInGroupAction, OpenNextEditor, OpenPreviousEditor, NavigateBackwardsAction, NavigateForwardAction, ReopenClosedEditorAction, OpenPreviousRecentlyUsedEditorInGroupAction, NAVIGATE_IN_GROUP_ONE_PREFIX, + toEditorQuickOpenEntry, CloseLeftEditorsInGroupAction, CloseRightEditorsInGroupAction, CloseUnmodifiedEditorsInGroupAction, OpenNextEditor, OpenPreviousEditor, NavigateBackwardsAction, NavigateForwardAction, ReopenClosedEditorAction, OpenPreviousRecentlyUsedEditorInGroupAction, NAVIGATE_IN_GROUP_ONE_PREFIX, OpenPreviousEditorFromHistoryAction, ShowAllEditorsAction, NAVIGATE_ALL_EDITORS_GROUP_PREFIX, ClearEditorHistoryAction, ShowEditorsInGroupTwoAction, MoveEditorRightInGroupAction, OpenNextEditorInGroup, OpenPreviousEditorInGroup, OpenNextRecentlyUsedEditorAction, OpenPreviousRecentlyUsedEditorAction, NAVIGATE_IN_GROUP_TWO_PREFIX, ShowEditorsInGroupThreeAction, NAVIGATE_IN_GROUP_THREE_PREFIX, FocusLastEditorInStackAction, OpenNextRecentlyUsedEditorInGroupAction, MoveEditorToPreviousGroupAction, MoveEditorToNextGroupAction, MoveEditorLeftInGroupAction, ClearRecentFilesAction } from 'vs/workbench/browser/parts/editor/editorActions'; @@ -343,6 +343,7 @@ registry.registerWorkbenchAction(new SyncActionDescriptor(KeepEditorAction, Keep registry.registerWorkbenchAction(new SyncActionDescriptor(CloseAllEditorsAction, CloseAllEditorsAction.ID, CloseAllEditorsAction.LABEL, { primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KEY_K, KeyMod.CtrlCmd | KeyCode.KEY_W) }), 'View: Close All Editors', category); registry.registerWorkbenchAction(new SyncActionDescriptor(CloseLeftEditorsInGroupAction, CloseLeftEditorsInGroupAction.ID, CloseLeftEditorsInGroupAction.LABEL), 'View: Close Editors to the Left', category); registry.registerWorkbenchAction(new SyncActionDescriptor(CloseRightEditorsInGroupAction, CloseRightEditorsInGroupAction.ID, CloseRightEditorsInGroupAction.LABEL), 'View: Close Editors to the Right', category); +registry.registerWorkbenchAction(new SyncActionDescriptor(CloseUnmodifiedEditorsInGroupAction, CloseUnmodifiedEditorsInGroupAction.ID, CloseUnmodifiedEditorsInGroupAction.LABEL, { primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KEY_K, KeyCode.KEY_U) }), 'View: Close Unmodified Editors', category); registry.registerWorkbenchAction(new SyncActionDescriptor(CloseEditorsInGroupAction, CloseEditorsInGroupAction.ID, CloseEditorsInGroupAction.LABEL, { primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KEY_K, KeyCode.KEY_W) }), 'View: Close All Editors in Group', category); registry.registerWorkbenchAction(new SyncActionDescriptor(CloseOtherEditorsInGroupAction, CloseOtherEditorsInGroupAction.ID, CloseOtherEditorsInGroupAction.LABEL, { primary: null, mac: { primary: KeyMod.CtrlCmd | KeyMod.Alt | KeyCode.KEY_T } }), 'View: Close Other Editors', category); registry.registerWorkbenchAction(new SyncActionDescriptor(CloseEditorsInOtherGroupsAction, CloseEditorsInOtherGroupsAction.ID, CloseEditorsInOtherGroupsAction.LABEL), 'View: Close Editors in Other Groups', category); diff --git a/src/vs/workbench/browser/parts/editor/editorActions.ts b/src/vs/workbench/browser/parts/editor/editorActions.ts index 34a37ea902f..3df24392886 100644 --- a/src/vs/workbench/browser/parts/editor/editorActions.ts +++ b/src/vs/workbench/browser/parts/editor/editorActions.ts @@ -691,6 +691,34 @@ export class CloseAllEditorsAction extends Action { } } +export class CloseUnmodifiedEditorsInGroupAction extends Action { + + public static ID = 'workbench.action.closeUnmodifiedEditors'; + public static LABEL = nls.localize('closeUnmodifiedEditors', "Close Unmodified Editors in Group"); + + constructor( + id: string, + label: string, + @IEditorGroupService private editorGroupService: IEditorGroupService, + @IWorkbenchEditorService private editorService: IWorkbenchEditorService + ) { + super(id, label); + } + + public run(context?: IEditorContext): TPromise { + const activeGroup = this.editorGroupService.getStacksModel().activeGroup; + const groupId = context && context.group ? context.group.id : activeGroup ? activeGroup.id : null; + if (groupId !== null) { + const stacks = this.editorGroupService.getStacksModel(); + const group = stacks.getGroup(groupId); + group.getEditors().filter(e => !e.isDirty()).forEach(e => this.editorService.closeEditor(stacks.positionOfGroup(group), e)); + return TPromise.as(null); + } + + return TPromise.as(false); + } +} + export class CloseEditorsInOtherGroupsAction extends Action { public static ID = 'workbench.action.closeEditorsInOtherGroups'; diff --git a/src/vs/workbench/browser/parts/editor/titleControl.ts b/src/vs/workbench/browser/parts/editor/titleControl.ts index 12c13c861ed..a2a66110f4c 100644 --- a/src/vs/workbench/browser/parts/editor/titleControl.ts +++ b/src/vs/workbench/browser/parts/editor/titleControl.ts @@ -32,7 +32,7 @@ import { IQuickOpenService } from 'vs/platform/quickOpen/common/quickOpen'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { ResolvedKeybinding } from 'vs/base/common/keyCodes'; import { IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; -import { CloseEditorsInGroupAction, SplitEditorAction, CloseEditorAction, KeepEditorAction, CloseOtherEditorsInGroupAction, CloseRightEditorsInGroupAction, ShowEditorsInGroupAction } from 'vs/workbench/browser/parts/editor/editorActions'; +import { CloseEditorsInGroupAction, SplitEditorAction, CloseEditorAction, KeepEditorAction, CloseOtherEditorsInGroupAction, CloseRightEditorsInGroupAction, ShowEditorsInGroupAction, CloseUnmodifiedEditorsInGroupAction } from 'vs/workbench/browser/parts/editor/editorActions'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { createActionItem, fillInActions } from 'vs/platform/actions/browser/menuItemActionItem'; import { IMenuService, MenuId, IMenu, ExecuteCommandAction } from 'vs/platform/actions/common/actions'; @@ -71,6 +71,7 @@ export abstract class TitleControl extends Themable implements ITitleAreaControl protected pinEditorAction: KeepEditorAction; protected closeOtherEditorsAction: CloseOtherEditorsInGroupAction; protected closeRightEditorsAction: CloseRightEditorsInGroupAction; + protected closeUnmodifiedEditorsInGroupAction: CloseUnmodifiedEditorsInGroupAction; protected closeEditorsInGroupAction: CloseEditorsInGroupAction; protected splitEditorAction: SplitEditorAction; protected showEditorsInGroupAction: ShowEditorsInGroupAction; @@ -228,6 +229,7 @@ export abstract class TitleControl extends Themable implements ITitleAreaControl this.closeOtherEditorsAction = services.createInstance(CloseOtherEditorsInGroupAction, CloseOtherEditorsInGroupAction.ID, nls.localize('closeOthers', "Close Others")); this.closeRightEditorsAction = services.createInstance(CloseRightEditorsInGroupAction, CloseRightEditorsInGroupAction.ID, nls.localize('closeRight', "Close to the Right")); this.closeEditorsInGroupAction = services.createInstance(CloseEditorsInGroupAction, CloseEditorsInGroupAction.ID, nls.localize('closeAll', "Close All")); + this.closeUnmodifiedEditorsInGroupAction = services.createInstance(CloseUnmodifiedEditorsInGroupAction, CloseUnmodifiedEditorsInGroupAction.ID, nls.localize('closeAllUnmodified', "Close Unmodified")); this.pinEditorAction = services.createInstance(KeepEditorAction, KeepEditorAction.ID, nls.localize('keepOpen', "Keep Open")); this.showEditorsInGroupAction = services.createInstance(ShowEditorsInGroupAction, ShowEditorsInGroupAction.ID, nls.localize('showOpenedEditors', "Show Opened Editors")); this.splitEditorAction = services.createInstance(SplitEditorAction, SplitEditorAction.ID, SplitEditorAction.LABEL); @@ -355,6 +357,7 @@ export abstract class TitleControl extends Themable implements ITitleAreaControl } secondaryEditorActions.push(this.showEditorsInGroupAction); secondaryEditorActions.push(new Separator()); + secondaryEditorActions.push(this.closeUnmodifiedEditorsInGroupAction); secondaryEditorActions.push(this.closeEditorsInGroupAction); } @@ -440,6 +443,7 @@ export abstract class TitleControl extends Themable implements ITitleAreaControl actions.push(this.closeRightEditorsAction); } + actions.push(this.closeUnmodifiedEditorsInGroupAction); actions.push(this.closeEditorsInGroupAction); if (tabOptions.previewEditors) { @@ -461,6 +465,7 @@ export abstract class TitleControl extends Themable implements ITitleAreaControl this.showEditorsInGroupAction, this.closeEditorAction, this.closeRightEditorsAction, + this.closeUnmodifiedEditorsInGroupAction, this.closeOtherEditorsAction, this.closeEditorsInGroupAction, this.pinEditorAction diff --git a/src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts b/src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts index f275bfd30a5..20c36a3af73 100644 --- a/src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts +++ b/src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts @@ -30,7 +30,7 @@ import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/edi import { EditorStacksModel, EditorGroup } from 'vs/workbench/common/editor/editorStacksModel'; import { SaveFileAction, RevertFileAction, SaveFileAsAction, OpenToSideAction, SelectResourceForCompareAction, CompareResourcesAction, SaveAllInGroupAction } from 'vs/workbench/parts/files/browser/fileActions'; import { IUntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; -import { CloseOtherEditorsInGroupAction, CloseEditorAction, CloseEditorsInGroupAction } from 'vs/workbench/browser/parts/editor/editorActions'; +import { CloseOtherEditorsInGroupAction, CloseEditorAction, CloseEditorsInGroupAction, CloseUnmodifiedEditorsInGroupAction } from 'vs/workbench/browser/parts/editor/editorActions'; const $ = dom.$; @@ -332,6 +332,7 @@ export class ActionProvider extends ContributableActionProvider { return [ saveAllAction, + this.instantiationService.createInstance(CloseUnmodifiedEditorsInGroupAction, CloseUnmodifiedEditorsInGroupAction.ID, CloseUnmodifiedEditorsInGroupAction.LABEL), this.instantiationService.createInstance(CloseEditorsInGroupAction, CloseEditorsInGroupAction.ID, CloseEditorsInGroupAction.LABEL) ]; } @@ -350,6 +351,7 @@ export class ActionProvider extends ContributableActionProvider { result.push(new Separator()); } + result.push(this.instantiationService.createInstance(CloseUnmodifiedEditorsInGroupAction, CloseUnmodifiedEditorsInGroupAction.ID, nls.localize('closeAllUnmodified', "Close Unmodified"))); result.push(this.instantiationService.createInstance(CloseEditorsInGroupAction, CloseEditorsInGroupAction.ID, nls.localize('closeAll', "Close All"))); } else { const openEditor = element; @@ -406,6 +408,7 @@ export class ActionProvider extends ContributableActionProvider { const closeOtherEditorsInGroupAction = this.instantiationService.createInstance(CloseOtherEditorsInGroupAction, CloseOtherEditorsInGroupAction.ID, nls.localize('closeOthers', "Close Others")); closeOtherEditorsInGroupAction.enabled = openEditor.editorGroup.count > 1; result.push(closeOtherEditorsInGroupAction); + result.push(this.instantiationService.createInstance(CloseUnmodifiedEditorsInGroupAction, CloseUnmodifiedEditorsInGroupAction.ID, nls.localize('closeAllUnmodified', "Close Unmodified"))); result.push(this.instantiationService.createInstance(CloseEditorsInGroupAction, CloseEditorsInGroupAction.ID, nls.localize('closeAll', "Close All"))); } -- GitLab From c1562a5ebb4a072367bf528b23db3a8c91e46c7b Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Thu, 15 Jun 2017 08:49:08 +0200 Subject: [PATCH 0854/1347] fix windows zip --- build/gulpfile.vscode.win32.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/build/gulpfile.vscode.win32.js b/build/gulpfile.vscode.win32.js index a4ebd283ee0..4ac842af71b 100644 --- a/build/gulpfile.vscode.win32.js +++ b/build/gulpfile.vscode.win32.js @@ -70,9 +70,9 @@ gulp.task('vscode-win32-x64-setup', ['clean-vscode-win32-x64-setup'], buildWin32 function archiveWin32Setup(arch) { return cb => { - const args = ['a', '-tzip', zipPath(arch), buildPath(arch), '-r']; + const args = ['a', '-tzip', zipPath(arch), '.', '-r']; - cp.spawn(_7z, args, { stdio: 'inherit' }) + cp.spawn(_7z, args, { stdio: 'inherit', cwd: buildPath(arch) }) .on('error', cb) .on('exit', () => cb(null)); }; -- GitLab From f63d0f56eb1188a880c9a1ad830ece1c8d0d2408 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 15 Jun 2017 08:59:05 +0200 Subject: [PATCH 0855/1347] :lipstick: --- .../parts/editor/editor.contribution.ts | 2 +- .../browser/parts/editor/editorActions.ts | 25 ++++---- .../browser/parts/editor/editorPart.ts | 60 +++++++++++++++---- .../services/editor/browser/editorService.ts | 6 +- .../services/editor/common/editorService.ts | 2 +- .../editor/test/browser/editorService.test.ts | 2 +- .../workbench/test/workbenchTestServices.ts | 2 +- 7 files changed, 70 insertions(+), 29 deletions(-) diff --git a/src/vs/workbench/browser/parts/editor/editor.contribution.ts b/src/vs/workbench/browser/parts/editor/editor.contribution.ts index 4f7181fbe59..f9d29431038 100644 --- a/src/vs/workbench/browser/parts/editor/editor.contribution.ts +++ b/src/vs/workbench/browser/parts/editor/editor.contribution.ts @@ -343,7 +343,7 @@ registry.registerWorkbenchAction(new SyncActionDescriptor(KeepEditorAction, Keep registry.registerWorkbenchAction(new SyncActionDescriptor(CloseAllEditorsAction, CloseAllEditorsAction.ID, CloseAllEditorsAction.LABEL, { primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KEY_K, KeyMod.CtrlCmd | KeyCode.KEY_W) }), 'View: Close All Editors', category); registry.registerWorkbenchAction(new SyncActionDescriptor(CloseLeftEditorsInGroupAction, CloseLeftEditorsInGroupAction.ID, CloseLeftEditorsInGroupAction.LABEL), 'View: Close Editors to the Left', category); registry.registerWorkbenchAction(new SyncActionDescriptor(CloseRightEditorsInGroupAction, CloseRightEditorsInGroupAction.ID, CloseRightEditorsInGroupAction.LABEL), 'View: Close Editors to the Right', category); -registry.registerWorkbenchAction(new SyncActionDescriptor(CloseUnmodifiedEditorsInGroupAction, CloseUnmodifiedEditorsInGroupAction.ID, CloseUnmodifiedEditorsInGroupAction.LABEL, { primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KEY_K, KeyCode.KEY_U) }), 'View: Close Unmodified Editors', category); +registry.registerWorkbenchAction(new SyncActionDescriptor(CloseUnmodifiedEditorsInGroupAction, CloseUnmodifiedEditorsInGroupAction.ID, CloseUnmodifiedEditorsInGroupAction.LABEL, { primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KEY_K, KeyCode.KEY_U) }), 'View: Close Unmodified Editors in Group', category); registry.registerWorkbenchAction(new SyncActionDescriptor(CloseEditorsInGroupAction, CloseEditorsInGroupAction.ID, CloseEditorsInGroupAction.LABEL, { primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KEY_K, KeyCode.KEY_W) }), 'View: Close All Editors in Group', category); registry.registerWorkbenchAction(new SyncActionDescriptor(CloseOtherEditorsInGroupAction, CloseOtherEditorsInGroupAction.ID, CloseOtherEditorsInGroupAction.LABEL, { primary: null, mac: { primary: KeyMod.CtrlCmd | KeyMod.Alt | KeyCode.KEY_T } }), 'View: Close Other Editors', category); registry.registerWorkbenchAction(new SyncActionDescriptor(CloseEditorsInOtherGroupsAction, CloseEditorsInOtherGroupsAction.ID, CloseEditorsInOtherGroupsAction.LABEL), 'View: Close Editors in Other Groups', category); diff --git a/src/vs/workbench/browser/parts/editor/editorActions.ts b/src/vs/workbench/browser/parts/editor/editorActions.ts index 3df24392886..29cf34bc07c 100644 --- a/src/vs/workbench/browser/parts/editor/editorActions.ts +++ b/src/vs/workbench/browser/parts/editor/editorActions.ts @@ -617,7 +617,7 @@ export class CloseLeftEditorsInGroupAction extends Action { public run(context?: IEditorContext): TPromise { const editor = getTarget(this.editorService, this.groupService, context); if (editor) { - return this.editorService.closeEditors(editor.position, editor.input, Direction.LEFT); + return this.editorService.closeEditors(editor.position, { except: editor.input, direction: Direction.LEFT }); } return TPromise.as(false); @@ -641,7 +641,7 @@ export class CloseRightEditorsInGroupAction extends Action { public run(context?: IEditorContext): TPromise { const editor = getTarget(this.editorService, this.groupService, context); if (editor) { - return this.editorService.closeEditors(editor.position, editor.input, Direction.RIGHT); + return this.editorService.closeEditors(editor.position, { except: editor.input, direction: Direction.RIGHT }); } return TPromise.as(false); @@ -706,13 +706,18 @@ export class CloseUnmodifiedEditorsInGroupAction extends Action { } public run(context?: IEditorContext): TPromise { - const activeGroup = this.editorGroupService.getStacksModel().activeGroup; - const groupId = context && context.group ? context.group.id : activeGroup ? activeGroup.id : null; - if (groupId !== null) { - const stacks = this.editorGroupService.getStacksModel(); - const group = stacks.getGroup(groupId); - group.getEditors().filter(e => !e.isDirty()).forEach(e => this.editorService.closeEditor(stacks.positionOfGroup(group), e)); - return TPromise.as(null); + let position = context ? this.editorGroupService.getStacksModel().positionOfGroup(context.group) : null; + + // If position is not passed in take the position of the active editor. + if (typeof position !== 'number') { + const active = this.editorService.getActiveEditor(); + if (active) { + position = active.position; + } + } + + if (typeof position === 'number') { + return this.editorService.closeEditors(position, { unmodifiedOnly: true }); } return TPromise.as(false); @@ -776,7 +781,7 @@ export class CloseOtherEditorsInGroupAction extends Action { } if (typeof position === 'number' && input) { - return this.editorService.closeEditors(position, input); + return this.editorService.closeEditors(position, { except: input }); } return TPromise.as(false); diff --git a/src/vs/workbench/browser/parts/editor/editorPart.ts b/src/vs/workbench/browser/parts/editor/editorPart.ts index f0db5dc5baf..18a865ad5fc 100644 --- a/src/vs/workbench/browser/parts/editor/editorPart.ts +++ b/src/vs/workbench/browser/parts/editor/editorPart.ts @@ -665,18 +665,23 @@ export class EditorPart extends Part implements IEditorPart, IEditorGroupService }); } - public closeEditors(position: Position, except?: EditorInput, direction?: Direction): TPromise { + public closeEditors(position: Position, filter: { except?: EditorInput, direction?: Direction, unmodifiedOnly?: boolean } = Object.create(null)): TPromise { const group = this.stacks.groupAt(position); if (!group) { return TPromise.as(null); } + let editors = group.getEditors(); + if (filter.unmodifiedOnly) { + editors = editors.filter(e => !e.isDirty()); + } + // Check for dirty and veto let editorsToClose: EditorInput[]; - if (types.isUndefinedOrNull(direction)) { - editorsToClose = group.getEditors().filter(e => !except || !e.matches(except)); + if (types.isUndefinedOrNull(filter.direction)) { + editorsToClose = editors.filter(e => !filter.except || !e.matches(filter.except)); } else { - editorsToClose = (direction === Direction.LEFT) ? group.getEditors().slice(0, group.indexOf(except)) : group.getEditors().slice(group.indexOf(except) + 1); + editorsToClose = (filter.direction === Direction.LEFT) ? editors.slice(0, group.indexOf(filter.except)) : editors.slice(group.indexOf(filter.except) + 1); } return this.handleDirty(editorsToClose.map(editor => { return { group, editor }; }), true /* ignore if opened in other group */).then(veto => { @@ -684,14 +689,26 @@ export class EditorPart extends Part implements IEditorPart, IEditorGroupService return; } - this.doCloseEditors(group, except, direction); + this.doCloseEditors(group, filter); }); } - private doCloseEditors(group: EditorGroup, except?: EditorInput, direction?: Direction): void { + private doCloseEditors(group: EditorGroup, filter: { except?: EditorInput, direction?: Direction, unmodifiedOnly?: boolean } = Object.create(null)): void { + + // Close all editors if there is no editor to except and + // we either are not only closing unmodified editors or + // there are no dirty editors. + let closeAllEditors = false; + if (!filter.except) { + if (!filter.unmodifiedOnly) { + closeAllEditors = true; + } else { + closeAllEditors = !group.getEditors().some(e => e.isDirty()); + } + } // Close all editors in group - if (!except) { + if (closeAllEditors) { // Update stacks model: remove all non active editors first to prevent opening the next editor in group group.closeEditors(group.activeEditor); @@ -700,23 +717,42 @@ export class EditorPart extends Part implements IEditorPart, IEditorGroupService this.doCloseActiveEditor(group); } + // Close unmodified editors in group + else if (filter.unmodifiedOnly) { + + // We can just close all unmodified editors around the currently active dirty one + if (group.activeEditor.isDirty()) { + group.getEditors().filter(editor => !editor.isDirty() && !editor.matches(filter.except)).forEach(editor => this.doCloseInactiveEditor(group, editor)); + } + + // Active editor is also a candidate to close, thus we make the first dirty editor + // active and then close the other ones + else { + const firstDirtyEditor = group.getEditors().filter(editor => editor.isDirty())[0]; + + this.openEditor(firstDirtyEditor, null, this.stacks.positionOfGroup(group)).done(() => { + this.doCloseEditors(group, filter); + }, errors.onUnexpectedError); + } + } + // Close all editors in group except active one - else if (except.matches(group.activeEditor)) { + else if (filter.except && filter.except.matches(group.activeEditor)) { // Update stacks model: close non active editors supporting the direction - group.closeEditors(group.activeEditor, direction); + group.closeEditors(group.activeEditor, filter.direction); } // Finally: we are asked to close editors around a non-active editor // Thus we make the non-active one active and then close the others else { - this.openEditor(except, null, this.stacks.positionOfGroup(group)).done(() => { + this.openEditor(filter.except, null, this.stacks.positionOfGroup(group)).done(() => { // since the opening might have failed, we have to check again for the active editor // being the expected one, otherwise we end up in an endless loop trying to open the // editor - if (except.matches(group.activeEditor)) { - this.doCloseEditors(group, except, direction); + if (filter.except.matches(group.activeEditor)) { + this.doCloseEditors(group, filter); } }, errors.onUnexpectedError); } diff --git a/src/vs/workbench/services/editor/browser/editorService.ts b/src/vs/workbench/services/editor/browser/editorService.ts index e8b52c75a1e..3e32edce31d 100644 --- a/src/vs/workbench/services/editor/browser/editorService.ts +++ b/src/vs/workbench/services/editor/browser/editorService.ts @@ -30,7 +30,7 @@ export interface IEditorPart { openEditors(editors: { input: IEditorInput, position: Position, options?: IEditorOptions | ITextEditorOptions }[]): TPromise; replaceEditors(editors: { toReplace: IEditorInput, replaceWith: IEditorInput, options?: IEditorOptions | ITextEditorOptions }[], position?: Position): TPromise; closeEditor(position: Position, input: IEditorInput): TPromise; - closeEditors(position: Position, except?: IEditorInput, direction?: Direction): TPromise; + closeEditors(position: Position, filter?: { except?: IEditorInput, direction?: Direction, unmodifiedOnly?: boolean }): TPromise; closeAllEditors(except?: Position): TPromise; getActiveEditor(): BaseEditor; getVisibleEditors(): IEditor[]; @@ -194,8 +194,8 @@ export class WorkbenchEditorService implements IWorkbenchEditorService { return this.editorPart.closeEditor(position, input); } - public closeEditors(position: Position, except?: IEditorInput, direction?: Direction): TPromise { - return this.editorPart.closeEditors(position, except, direction); + public closeEditors(position: Position, filter?: { except?: IEditorInput, direction?: Direction, unmodifiedOnly?: boolean }): TPromise { + return this.editorPart.closeEditors(position, filter); } public closeAllEditors(except?: Position): TPromise { diff --git a/src/vs/workbench/services/editor/common/editorService.ts b/src/vs/workbench/services/editor/common/editorService.ts index abedce481a0..5381c9de4e7 100644 --- a/src/vs/workbench/services/editor/common/editorService.ts +++ b/src/vs/workbench/services/editor/common/editorService.ts @@ -80,7 +80,7 @@ export interface IWorkbenchEditorService extends IEditorService { * will not be closed. The direction can be used in that case to control if all other editors should get closed, * or towards a specific direction. */ - closeEditors(position: Position, except?: IEditorInput, direction?: Direction): TPromise; + closeEditors(position: Position, filter?: { except?: IEditorInput, direction?: Direction, unmodifiedOnly?: boolean }): TPromise; /** * Closes all editors across all groups. The optional position allows to keep one group alive. diff --git a/src/vs/workbench/services/editor/test/browser/editorService.test.ts b/src/vs/workbench/services/editor/test/browser/editorService.test.ts index 4dd5a44fe16..1c3c11e3c10 100644 --- a/src/vs/workbench/services/editor/test/browser/editorService.test.ts +++ b/src/vs/workbench/services/editor/test/browser/editorService.test.ts @@ -51,7 +51,7 @@ class TestEditorPart implements IEditorPart { return TPromise.as([]); } - public closeEditors(position: Position, except?: EditorInput, direction?: Direction): TPromise { + public closeEditors(position: Position, filter?: { except?: EditorInput, direction?: Direction, unmodifiedOnly?: boolean }): TPromise { return TPromise.as(null); } diff --git a/src/vs/workbench/test/workbenchTestServices.ts b/src/vs/workbench/test/workbenchTestServices.ts index d38d290f463..372f2d1f494 100644 --- a/src/vs/workbench/test/workbenchTestServices.ts +++ b/src/vs/workbench/test/workbenchTestServices.ts @@ -525,7 +525,7 @@ export class TestEditorService implements IWorkbenchEditorService { return TPromise.as([]); } - public closeEditors(position: Position, except?: IEditorInput, direction?: Direction): TPromise { + public closeEditors(position: Position, filter?: { except?: IEditorInput, direction?: Direction, unmodifiedOnly?: boolean }): TPromise { return TPromise.as(null); } -- GitLab From 0e582fc66deb49307efc8a8b6e260f024e31e330 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 15 Jun 2017 09:24:01 +0200 Subject: [PATCH 0856/1347] multi root: workspace name --- .../browser/standalone/simpleServices.ts | 2 +- src/vs/platform/workspace/common/workspace.ts | 5 ++++ .../configuration/node/configuration.ts | 24 +++++++++++++++++-- .../workbench/test/workbenchTestServices.ts | 2 +- 4 files changed, 29 insertions(+), 4 deletions(-) diff --git a/src/vs/editor/browser/standalone/simpleServices.ts b/src/vs/editor/browser/standalone/simpleServices.ts index 7d6d9ca4fa2..a177a093718 100644 --- a/src/vs/editor/browser/standalone/simpleServices.ts +++ b/src/vs/editor/browser/standalone/simpleServices.ts @@ -516,7 +516,7 @@ export class SimpleWorkspaceContextService implements IWorkspaceContextService { } public getWorkspace2(): IWorkspace2 { - return this.workspace ? { id: `${this.id}`, roots: [this.workspace.resource] } : void 0; + return this.workspace ? { id: `${this.id}`, roots: [this.workspace.resource], name: this.workspace.resource.fsPath } : void 0; } public hasWorkspace(): boolean { diff --git a/src/vs/platform/workspace/common/workspace.ts b/src/vs/platform/workspace/common/workspace.ts index b133e6aea4e..7abd76ad14c 100644 --- a/src/vs/platform/workspace/common/workspace.ts +++ b/src/vs/platform/workspace/common/workspace.ts @@ -78,6 +78,11 @@ export interface IWorkspace2 { */ readonly id: string; + /** + * the name of the workspace. + */ + readonly name: string; + /** * Mutliple roots in this workspace. First entry is master and never changes. */ diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index cb06494acb2..4c62132f61d 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -24,6 +24,8 @@ import { ScopedConfigModel, WorkspaceConfigModel, WorkspaceSettingsConfigModel } import { IConfigurationServiceEvent, ConfigurationSource, getConfigurationValue, IConfigurationOptions, Configuration } from 'vs/platform/configuration/common/configuration'; import { IWorkspaceConfigurationValues, IWorkspaceConfigurationService, IWorkspaceConfigurationValue, WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME, WORKSPACE_STANDALONE_CONFIGURATIONS, WORKSPACE_CONFIG_DEFAULT_PATH } from 'vs/workbench/services/configuration/common/configuration'; import { ConfigurationService as GlobalConfigurationService } from 'vs/platform/configuration/node/configurationService'; +import { createHash } from "crypto"; +import { basename } from "path"; interface IStat { resource: URI; @@ -44,13 +46,31 @@ interface IWorkspaceConfiguration { type IWorkspaceFoldersConfiguration = { [rootFolder: string]: { folders: string[]; } }; class Workspace implements IWorkspace2 { + private _name: string; constructor( public readonly id: string, - public roots: URI[] + private _roots: URI[] ) { // } + + public set roots(roots: URI[]) { + this._roots = roots; + this._name = null; // will be recomputed based on roots next time accessed + } + + public get roots(): URI[] { + return this._roots; + } + + public get name(): string { + if (!this._name) { + this._name = this.roots.map(root => basename(root.fsPath)).join(', '); + } + + return this._name; + } } export class WorkspaceConfigurationService extends Disposable implements IWorkspaceContextService, IWorkspaceConfigurationService { @@ -79,7 +99,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp constructor(private environmentService: IEnvironmentService, private singleRootWorkspace?: SingleRootWorkspace, private workspaceSettingsRootFolder: string = WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME) { super(); - this.workspace = singleRootWorkspace ? new Workspace(singleRootWorkspace.resource.toString(), [singleRootWorkspace.resource]) : null; + this.workspace = singleRootWorkspace ? new Workspace(createHash('md5').update(singleRootWorkspace.resource.toString()).digest('hex'), [singleRootWorkspace.resource]) : null; // TODO@Ben for now use the first root folder as id, but revisit this later this.workspaceFilePathToConfiguration = Object.create(null); this.cachedConfig = new Configuration(); diff --git a/src/vs/workbench/test/workbenchTestServices.ts b/src/vs/workbench/test/workbenchTestServices.ts index 372f2d1f494..2ddd8120752 100644 --- a/src/vs/workbench/test/workbenchTestServices.ts +++ b/src/vs/workbench/test/workbenchTestServices.ts @@ -94,7 +94,7 @@ export class TestContextService implements IWorkspaceContextService { } public getWorkspace2(): IWorkspace2 { - return this.workspace ? { id: this.id, roots: [this.workspace.resource] } : void 0; + return this.workspace ? { id: this.id, roots: [this.workspace.resource], name: this.workspace.resource.fsPath } : void 0; } public setWorkspace(workspace: any): void { -- GitLab From e5e00d71d6803f2b96b46feba603d482e1c5a80d Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Thu, 15 Jun 2017 09:51:40 +0200 Subject: [PATCH 0857/1347] Run smoke test build in higher screen resolution. --- build/tfs/linux/smoketest.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/tfs/linux/smoketest.sh b/build/tfs/linux/smoketest.sh index 327d55b66d9..33344082253 100644 --- a/build/tfs/linux/smoketest.sh +++ b/build/tfs/linux/smoketest.sh @@ -29,5 +29,5 @@ step "Run smoke test" \ pushd test/smoke npm install npm run compile - xvfb-run -a node src/main.js --latest "$AGENT_BUILDDIRECTORY/VSCode-linux-ia32/code-insiders" + xvfb-run -a -s="-screen 0 1024x768x8" node src/main.js --latest "$AGENT_BUILDDIRECTORY/VSCode-linux-ia32/code-insiders" popd \ No newline at end of file -- GitLab From 293deaeb097a02e04faeb89316802dadd69ad732 Mon Sep 17 00:00:00 2001 From: isidor Date: Thu, 15 Jun 2017 10:30:04 +0200 Subject: [PATCH 0858/1347] fixes #28740 --- .../parts/debug/electron-browser/debugService.ts | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/src/vs/workbench/parts/debug/electron-browser/debugService.ts b/src/vs/workbench/parts/debug/electron-browser/debugService.ts index 40c3ce62b05..a79f53cadd6 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugService.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugService.ts @@ -912,14 +912,12 @@ export class DebugService implements debug.IDebugService { let config = process.configuration; if (this.launchJsonChanged) { this.launchJsonChanged = false; - config = this.configurationManager.getConfiguration(process.configuration.name) || process.configuration; - if (config) { - // Take the type from the process since the debug extension might overwrite it #21316 - config.type = process.configuration.type; - config.noDebug = process.configuration.noDebug; - config.__restart = restartData; - } + config = this.configurationManager.getConfiguration(process.configuration.name) || config; + // Take the type from the process since the debug extension might overwrite it #21316 + config.type = process.configuration.type; + config.noDebug = process.configuration.noDebug; } + config.__restart = restartData; this.createProcess(config).then(() => c(null), err => e(err)); }, 300); }) -- GitLab From dd2cd5fc5821aaa4786b6fcb115246d52c5cd14c Mon Sep 17 00:00:00 2001 From: isidor Date: Thu, 15 Jun 2017 10:31:27 +0200 Subject: [PATCH 0859/1347] merge master --- .github/copycat.yml | 5 + build/gulpfile.vscode.js | 4 +- build/gulpfile.vscode.win32.js | 4 +- .../lib/tslint/noUnexternalizedStringsRule.ts | 20 +- build/tfs/darwin/smoketest.sh | 6 - build/tfs/linux/build.sh | 83 +------ build/tfs/linux/release.sh | 86 +++++++ build/tfs/linux/smoketest.sh | 33 +++ build/tfs/win32/smoketest.ps1 | 46 ++++ extensions/git/src/commands.ts | 6 +- extensions/git/src/git.ts | 8 +- extensions/git/src/model.ts | 28 ++- extensions/json/server/npm-shrinkwrap.json | 4 +- extensions/json/server/package.json | 2 +- extensions/markdown/package.json | 2 +- .../themes/dimmed-monokai-color-theme.json | 32 ++- .../themes/monokai-color-theme.json | 7 + .../src/features/bufferSyncSupport.ts | 15 +- npm-shrinkwrap.json | 2 +- src/vs/base/browser/dom.ts | 14 +- src/vs/base/browser/fastDomNode.ts | 41 +--- src/vs/base/browser/ui/list/listView.ts | 1 - .../browser/ui/scrollbar/abstractScrollbar.ts | 17 +- .../ui/scrollbar/horizontalScrollbar.ts | 9 +- .../browser/ui/scrollbar/scrollableElement.ts | 5 - .../ui/scrollbar/scrollableElementOptions.ts | 6 - .../browser/ui/scrollbar/verticalScrollbar.ts | 9 +- src/vs/base/common/errorMessage.ts | 2 +- src/vs/base/common/marked/OSSREADME.json | 2 +- src/vs/base/common/marked/raw.marked.js | 69 +++--- src/vs/base/parts/tree/browser/treeView.ts | 1 - src/vs/code/electron-main/app.ts | 2 +- src/vs/code/electron-main/menus.ts | 26 +- src/vs/editor/browser/config/configuration.ts | 1 - .../editor/browser/controller/mouseHandler.ts | 2 +- .../browser/services/codeEditorServiceImpl.ts | 9 +- .../standalone/media/standalone-tokens.css | 2 +- .../browser/standalone/simpleServices.ts | 5 +- .../browser/standalone/standaloneLanguages.ts | 2 +- .../editorScrollbar/editorScrollbar.ts | 4 +- .../viewParts/indentGuides/indentGuides.css | 1 - .../viewParts/indentGuides/indentGuides.ts | 4 +- .../browser/viewParts/lines/viewLines.ts | 21 +- .../editor/browser/viewParts/margin/margin.ts | 18 +- .../browser/viewParts/minimap/minimap.ts | 2 +- .../overviewRuler/decorationsOverviewRuler.ts | 5 - .../viewParts/overviewRuler/overviewRuler.ts | 5 - .../overviewRuler/overviewRulerImpl.ts | 17 +- .../browser/viewParts/rulers/rulers.css | 1 - .../editor/browser/viewParts/rulers/rulers.ts | 4 +- .../viewParts/viewCursors/viewCursor.ts | 5 +- .../common/config/commonEditorConfig.ts | 2 - src/vs/editor/common/config/editorOptions.ts | 28 +-- .../common/controller/cursorTypeOperations.ts | 2 +- src/vs/editor/common/view/viewEvents.ts | 4 +- .../contrib/find/common/findController.ts | 10 +- .../find/test/common/findController.test.ts | 2 +- .../contrib/hover/browser/hoverWidgets.ts | 2 +- src/vs/editor/contrib/links/browser/links.ts | 62 ++--- .../browser/parameterHintsWidget.ts | 2 +- .../browser/referenceSearch.ts | 7 +- .../browser/referencesModel.ts | 6 +- .../browser/referencesWidget.ts | 17 +- .../contrib/suggest/browser/suggestWidget.ts | 2 +- .../wordHighlighter/common/wordHighlighter.ts | 4 +- .../zoneWidget/browser/peekViewWidget.ts | 3 +- .../services/decorationRenderOptions.test.ts | 2 +- .../common/config/commonEditorConfig.test.ts | 1 - .../test/common/mocks/testConfiguration.ts | 1 - src/vs/monaco.d.ts | 11 +- .../configuration/common/configuration.ts | 79 +++++- src/vs/platform/configuration/common/model.ts | 117 ++------- .../node/configurationService.ts | 26 +- .../test/common/configuration.test.ts | 79 ++++++ .../configuration/test/common/model.test.ts | 61 ++--- src/vs/platform/files/common/files.ts | 2 +- src/vs/platform/quickOpen/common/quickOpen.ts | 5 + src/vs/platform/search/common/replace.ts | 2 +- .../platform/storage/common/storageService.ts | 15 +- .../storage/test/storageService.test.ts | 7 +- src/vs/platform/workspace/common/workspace.ts | 20 +- .../workspace/test/common/testWorkspace.ts | 1 - .../electron-browser/mainThreadWorkspace.ts | 4 +- src/vs/workbench/api/node/extHost.api.impl.ts | 4 +- src/vs/workbench/api/node/extHost.protocol.ts | 10 +- .../api/node/extHostExtensionService.ts | 13 +- src/vs/workbench/api/node/extHostSCM.ts | 5 +- src/vs/workbench/api/node/extHostWorkspace.ts | 19 +- .../browser/parts/editor/binaryEditor.ts | 2 +- .../parts/editor/editor.contribution.ts | 42 +++- .../browser/parts/editor/editorActions.ts | 39 ++- .../browser/parts/editor/editorPart.ts | 60 ++++- .../browser/parts/editor/tabsTitleControl.ts | 1 - .../browser/parts/editor/titleControl.ts | 7 +- .../parts/quickopen/quickOpenController.ts | 50 +++- .../parts/quickopen/quickopen.contribution.ts | 175 +++----------- .../browser/parts/quickopen/quickopen.ts | 132 +++++++++++ src/vs/workbench/browser/quickopen.ts | 11 +- .../common/editor/editorStacksModel.ts | 28 ++- src/vs/workbench/electron-browser/actions.ts | 4 + .../electron-browser/extensionHost.ts | 4 +- src/vs/workbench/electron-browser/main.ts | 125 ++++++---- .../electron-browser/media/shell.css | 2 +- src/vs/workbench/electron-browser/shell.ts | 22 +- .../electron-browser/workbench.main.ts | 1 + .../workbench/electron-browser/workbench.ts | 26 +- src/vs/workbench/node/extensionHostMain.ts | 21 +- .../parts/debug/browser/media/debugHover.css | 4 +- .../electron-browser/debug.contribution.ts | 1 + .../debug/electron-browser/debugHover.ts | 10 +- .../debug/electron-browser/debugService.ts | 12 +- .../extensions/browser/extensionEditor.ts | 4 +- .../extensions.contribution.ts | 2 + .../files/browser/views/openEditorsViewer.ts | 5 +- .../quickopen/browser/commandsHandler.ts | 22 -- .../browser/quickopen.contribution.ts | 45 +++- .../search/browser/search.contribution.ts | 4 +- .../electron-browser/task.contribution.ts | 6 + .../parts/terminal/common/terminal.ts | 17 ++ .../parts/terminal/common/terminalService.ts | 9 +- .../electron-browser/media/close-dark.svg | 1 + .../terminal/electron-browser/media/close.svg | 1 + .../electron-browser/media/next-inverse.svg | 5 + .../terminal/electron-browser/media/next.svg | 5 + .../media/previous-inverse.svg | 5 + .../electron-browser/media/previous.svg | 5 + .../electron-browser/media/terminal.css | 72 ++++++ .../electron-browser/media/widgets.css | 2 +- .../electron-browser/terminal.contribution.ts | 17 +- .../electron-browser/terminalActions.ts | 34 +++ .../electron-browser/terminalFindWidget.ts | 224 ++++++++++++++++++ .../electron-browser/terminalInstance.ts | 8 + .../electron-browser/terminalPanel.ts | 18 +- .../electron-browser/terminalService.ts | 21 +- .../watermark/electron-browser/watermark.ts | 2 +- .../electron-browser/walkThroughPart.ts | 1 - .../common/configurationModels.ts | 8 +- .../configuration/node/configuration.ts | 56 +++-- .../node/configurationResolverService.ts | 2 +- .../services/editor/browser/editorService.ts | 6 +- .../services/editor/common/editorService.ts | 2 +- .../editor/test/browser/editorService.test.ts | 2 +- .../test/browser/editorStacksModel.test.ts | 18 ++ .../workbench/test/browser/quickopen.test.ts | 3 +- .../api/extHostWorkspace.test.ts | 6 +- .../workbench/test/workbenchTestServices.ts | 7 +- test/smoke/README.md | 3 + 147 files changed, 1786 insertions(+), 983 deletions(-) create mode 100644 .github/copycat.yml create mode 100755 build/tfs/linux/release.sh create mode 100644 build/tfs/linux/smoketest.sh create mode 100644 build/tfs/win32/smoketest.ps1 create mode 100644 src/vs/platform/configuration/test/common/configuration.test.ts create mode 100644 src/vs/workbench/browser/parts/quickopen/quickopen.ts create mode 100644 src/vs/workbench/parts/terminal/electron-browser/media/close-dark.svg create mode 100644 src/vs/workbench/parts/terminal/electron-browser/media/close.svg create mode 100644 src/vs/workbench/parts/terminal/electron-browser/media/next-inverse.svg create mode 100644 src/vs/workbench/parts/terminal/electron-browser/media/next.svg create mode 100644 src/vs/workbench/parts/terminal/electron-browser/media/previous-inverse.svg create mode 100644 src/vs/workbench/parts/terminal/electron-browser/media/previous.svg create mode 100644 src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.ts diff --git a/.github/copycat.yml b/.github/copycat.yml new file mode 100644 index 00000000000..eccccc16b00 --- /dev/null +++ b/.github/copycat.yml @@ -0,0 +1,5 @@ +{ + perform: true, + target_owner: 'chrmarti', + target_repo: 'testissues' +} \ No newline at end of file diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index 82c1c5cb670..e4e7211aaef 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -43,7 +43,7 @@ const nodeModules = ['electron', 'original-fs'] const builtInExtensions = [ { name: 'ms-vscode.node-debug', version: '1.14.1' }, - { name: 'ms-vscode.node-debug2', version: '1.13.3' } + { name: 'ms-vscode.node-debug2', version: '1.14.0' } ]; const vscodeEntryPoints = _.flatten([ @@ -123,6 +123,8 @@ const config = { darwinIcon: 'resources/darwin/code.icns', darwinBundleIdentifier: product.darwinBundleIdentifier, darwinApplicationCategoryType: 'public.app-category.developer-tools', + darwinHelpBookFolder: 'VS Code HelpBook', + darwinHelpBookName: 'VS Code HelpBook', darwinBundleDocumentTypes: [{ name: product.nameLong + ' document', role: 'Editor', diff --git a/build/gulpfile.vscode.win32.js b/build/gulpfile.vscode.win32.js index a4ebd283ee0..4ac842af71b 100644 --- a/build/gulpfile.vscode.win32.js +++ b/build/gulpfile.vscode.win32.js @@ -70,9 +70,9 @@ gulp.task('vscode-win32-x64-setup', ['clean-vscode-win32-x64-setup'], buildWin32 function archiveWin32Setup(arch) { return cb => { - const args = ['a', '-tzip', zipPath(arch), buildPath(arch), '-r']; + const args = ['a', '-tzip', zipPath(arch), '.', '-r']; - cp.spawn(_7z, args, { stdio: 'inherit' }) + cp.spawn(_7z, args, { stdio: 'inherit', cwd: buildPath(arch) }) .on('error', cb) .on('exit', () => cb(null)); }; diff --git a/build/lib/tslint/noUnexternalizedStringsRule.ts b/build/lib/tslint/noUnexternalizedStringsRule.ts index d7a2d8ca100..cbe457c5be5 100644 --- a/build/lib/tslint/noUnexternalizedStringsRule.ts +++ b/build/lib/tslint/noUnexternalizedStringsRule.ts @@ -82,10 +82,10 @@ class NoUnexternalizedStringsRuleWalker extends Lint.RuleWalker { protected visitSourceFile(node: ts.SourceFile): void { super.visitSourceFile(node); Object.keys(this.usedKeys).forEach(key => { - let occurences = this.usedKeys[key]; - if (occurences.length > 1) { - occurences.forEach(occurence => { - this.addFailure((this.createFailure(occurence.key.getStart(), occurence.key.getWidth(), `Duplicate key ${occurence.key.getText()} with different message value.`))); + let occurrences = this.usedKeys[key]; + if (occurrences.length > 1) { + occurrences.forEach(occurrence => { + this.addFailure((this.createFailure(occurrence.key.getStart(), occurrence.key.getWidth(), `Duplicate key ${occurrence.key.getText()} with different message value.`))); }); } }); @@ -157,17 +157,17 @@ class NoUnexternalizedStringsRuleWalker extends Lint.RuleWalker { private recordKey(keyNode: ts.StringLiteral, messageNode: ts.Node) { let text = keyNode.getText(); - let occurences: KeyMessagePair[] = this.usedKeys[text]; - if (!occurences) { - occurences = []; - this.usedKeys[text] = occurences; + let occurrences: KeyMessagePair[] = this.usedKeys[text]; + if (!occurrences) { + occurrences = []; + this.usedKeys[text] = occurrences; } if (messageNode) { - if (occurences.some(pair => pair.message ? pair.message.getText() === messageNode.getText() : false)) { + if (occurrences.some(pair => pair.message ? pair.message.getText() === messageNode.getText() : false)) { return; } } - occurences.push({ key: keyNode, message: messageNode }); + occurrences.push({ key: keyNode, message: messageNode }); } private findDescribingParent(node: ts.Node): { callInfo?: { callExpression: ts.CallExpression, argIndex: number }, ignoreUsage?: boolean; } { diff --git a/build/tfs/darwin/smoketest.sh b/build/tfs/darwin/smoketest.sh index 18da9dabf38..60e1863f08d 100755 --- a/build/tfs/darwin/smoketest.sh +++ b/build/tfs/darwin/smoketest.sh @@ -20,12 +20,6 @@ step "Install distro dependencies" \ step "Build minified & upload source maps" \ npm run gulp -- --max_old_space_size=4096 vscode-darwin-min -step "Run unit tests" \ - ./scripts/test.sh --build --reporter dot - -step "Run integration tests" \ - ./scripts/test-integration.sh - step "Run smoke test" \ pushd test/smoke npm install diff --git a/build/tfs/linux/build.sh b/build/tfs/linux/build.sh index 7e50e47c05d..e6ba3dd8042 100755 --- a/build/tfs/linux/build.sh +++ b/build/tfs/linux/build.sh @@ -32,84 +32,5 @@ step "Build minified" \ step "Run unit tests" \ ./scripts/test.sh --xvfb --build --reporter dot -step "Build Debian package" \ - npm run gulp -- --max_old_space_size=4096 "vscode-linux-$ARCH-build-deb" - -step "Build RPM package" \ - npm run gulp -- --max_old_space_size=4096 "vscode-linux-$ARCH-build-rpm" - -(cd $BUILD_SOURCESDIRECTORY/build/tfs/common && \ - step "Install build dependencies" \ - npm install --unsafe-perm) - -# Variables -PLATFORM_LINUX="linux-$ARCH" -PLATFORM_DEB="linux-deb-$ARCH" -PLATFORM_RPM="linux-rpm-$ARCH" -[[ "$ARCH" == "ia32" ]] && DEB_ARCH="i386" || DEB_ARCH="amd64" -[[ "$ARCH" == "ia32" ]] && RPM_ARCH="i386" || RPM_ARCH="x86_64" -REPO="`pwd`" -ROOT="$REPO/.." -BUILDNAME="VSCode-$PLATFORM_LINUX" -BUILD="$ROOT/$BUILDNAME" -BUILD_VERSION="$(ls $REPO/.build/linux/deb/$DEB_ARCH/deb/ | sed -e 's/code-[a-z]*_//g' -e 's/\.deb$//g')" -[ -z "$VSCODE_QUALITY" ] && TARBALL_FILENAME="code-$BUILD_VERSION.tar.gz" || TARBALL_FILENAME="code-$VSCODE_QUALITY-$BUILD_VERSION.tar.gz" -TARBALL_PATH="$ROOT/$TARBALL_FILENAME" -PACKAGEJSON="$BUILD/resources/app/package.json" -VERSION=$(node -p "require(\"$PACKAGEJSON\").version") - -rm -rf $ROOT/code-*.tar.* -(cd $ROOT && \ - step "Create tar.gz archive" \ - tar -czvf $TARBALL_PATH $BUILDNAME) - -step "Publish tar.gz archive" \ - node build/tfs/common/publish.js $VSCODE_QUALITY $PLATFORM_LINUX archive-unsigned $TARBALL_FILENAME $VERSION true $TARBALL_PATH - -DEB_FILENAME="$(ls $REPO/.build/linux/deb/$DEB_ARCH/deb/)" -DEB_PATH="$REPO/.build/linux/deb/$DEB_ARCH/deb/$DEB_FILENAME" - -step "Publish Debian package" \ - node build/tfs/common/publish.js $VSCODE_QUALITY $PLATFORM_DEB package $DEB_FILENAME $VERSION true $DEB_PATH - -RPM_FILENAME="$(ls $REPO/.build/linux/rpm/$RPM_ARCH/ | grep .rpm)" -RPM_PATH="$REPO/.build/linux/rpm/$RPM_ARCH/$RPM_FILENAME" - -step "Publish RPM package" \ - node build/tfs/common/publish.js $VSCODE_QUALITY $PLATFORM_RPM package $RPM_FILENAME $VERSION true $RPM_PATH - -if [ -z "$VSCODE_QUALITY" ]; then - echo "VSCODE_QUALITY is not set, skipping repo package publish" -else - if [ "$BUILD_SOURCEBRANCH" = "master" ] || [ "$BUILD_SOURCEBRANCH" = "refs/heads/master" ]; then - if [[ $BUILD_QUEUEDBY = *"Project Collection Service Accounts"* || $BUILD_QUEUEDBY = *"Microsoft.VisualStudio.Services.TFS"* ]]; then - # Get necessary information - pushd $REPO && COMMIT_HASH=$(git rev-parse HEAD) && popd - PACKAGE_NAME="$(ls $REPO/.build/linux/deb/$DEB_ARCH/deb/ | sed -e 's/_.*//g')" - DEB_URL="https://az764295.vo.msecnd.net/$VSCODE_QUALITY/$COMMIT_HASH/$DEB_FILENAME" - RPM_URL="https://az764295.vo.msecnd.net/$VSCODE_QUALITY/$COMMIT_HASH/$RPM_FILENAME" - PACKAGE_VERSION="$(ls $REPO/.build/linux/deb/$DEB_ARCH/deb/ | sed -e 's/code-[a-z]*_//g' -e 's/\_.*$//g')" - # Write config files needed by API, use eval to force environment variable expansion - DIRNAME=$(dirname $(readlink -f $0)) - pushd $DIRNAME - # Submit to apt repo - if [ "$DEB_ARCH" = "amd64" ]; then - eval echo '{ \"server\": \"azure-apt-cat.cloudapp.net\", \"protocol\": \"https\", \"port\": \"443\", \"repositoryId\": \"58a4adf642421134a1a48d1a\", \"username\": \"$LINUX_REPO_USERNAME\", \"password\": \"$LINUX_REPO_PASSWORD\" }' > apt-config.json - eval echo '{ \"name\": \"$PACKAGE_NAME\", \"version\": \"$PACKAGE_VERSION\", \"repositoryId\": \"58a4adf642421134a1a48d1a\", \"sourceUrl\": \"$DEB_URL\" }' > apt-addpkg.json - echo "Submitting apt-addpkg.json:" - cat apt-addpkg.json - - step "Publish to repositories" \ - ./repoapi_client.sh -config apt-config.json -addpkg apt-addpkg.json - fi - # Submit to yum repo (disabled as it's manual until signing is automated) - # eval echo '{ \"server\": \"azure-apt-cat.cloudapp.net\", \"protocol\": \"https\", \"port\": \"443\", \"repositoryId\": \"58a4ae3542421134a1a48d1b\", \"username\": \"$LINUX_REPO_USERNAME\", \"password\": \"$LINUX_REPO_PASSWORD\" }' > yum-config.json - # eval echo '{ \"name\": \"$PACKAGE_NAME\", \"version\": \"$PACKAGE_VERSION\", \"repositoryId\": \"58a4ae3542421134a1a48d1b\", \"sourceUrl\": \"$RPM_URL\" }' > yum-addpkg.json - # echo "Submitting yum-addpkg.json:" - # cat yum-addpkg.json - # ./repoapi_client.sh -config yum-config.json -addpkg yum-addpkg.json - popd - echo "To check repo publish status run ./repoapi_client.sh -config config.json -check " - fi - fi -fi +step "Publish release" \ + ./build/tfs/linux/release.sh \ No newline at end of file diff --git a/build/tfs/linux/release.sh b/build/tfs/linux/release.sh new file mode 100755 index 00000000000..40d68aee73f --- /dev/null +++ b/build/tfs/linux/release.sh @@ -0,0 +1,86 @@ +#!/bin/bash + +. ./scripts/env.sh +. ./build/tfs/common/common.sh + +step "Build Debian package" \ + npm run gulp -- --max_old_space_size=4096 "vscode-linux-$ARCH-build-deb" + +step "Build RPM package" \ + npm run gulp -- --max_old_space_size=4096 "vscode-linux-$ARCH-build-rpm" + +(cd $BUILD_SOURCESDIRECTORY/build/tfs/common && \ + step "Install build dependencies" \ + npm install --unsafe-perm) + +# Variables +PLATFORM_LINUX="linux-$ARCH" +PLATFORM_DEB="linux-deb-$ARCH" +PLATFORM_RPM="linux-rpm-$ARCH" +[[ "$ARCH" == "ia32" ]] && DEB_ARCH="i386" || DEB_ARCH="amd64" +[[ "$ARCH" == "ia32" ]] && RPM_ARCH="i386" || RPM_ARCH="x86_64" +REPO="`pwd`" +ROOT="$REPO/.." +BUILDNAME="VSCode-$PLATFORM_LINUX" +BUILD="$ROOT/$BUILDNAME" +BUILD_VERSION="$(ls $REPO/.build/linux/deb/$DEB_ARCH/deb/ | sed -e 's/code-[a-z]*_//g' -e 's/\.deb$//g')" +[ -z "$VSCODE_QUALITY" ] && TARBALL_FILENAME="code-$BUILD_VERSION.tar.gz" || TARBALL_FILENAME="code-$VSCODE_QUALITY-$BUILD_VERSION.tar.gz" +TARBALL_PATH="$ROOT/$TARBALL_FILENAME" +PACKAGEJSON="$BUILD/resources/app/package.json" +VERSION=$(node -p "require(\"$PACKAGEJSON\").version") + +rm -rf $ROOT/code-*.tar.* +(cd $ROOT && \ + step "Create tar.gz archive" \ + tar -czf $TARBALL_PATH $BUILDNAME) + +step "Publish tar.gz archive" \ + node build/tfs/common/publish.js $VSCODE_QUALITY $PLATFORM_LINUX archive-unsigned $TARBALL_FILENAME $VERSION true $TARBALL_PATH + +DEB_FILENAME="$(ls $REPO/.build/linux/deb/$DEB_ARCH/deb/)" +DEB_PATH="$REPO/.build/linux/deb/$DEB_ARCH/deb/$DEB_FILENAME" + +step "Publish Debian package" \ + node build/tfs/common/publish.js $VSCODE_QUALITY $PLATFORM_DEB package $DEB_FILENAME $VERSION true $DEB_PATH + +RPM_FILENAME="$(ls $REPO/.build/linux/rpm/$RPM_ARCH/ | grep .rpm)" +RPM_PATH="$REPO/.build/linux/rpm/$RPM_ARCH/$RPM_FILENAME" + +step "Publish RPM package" \ + node build/tfs/common/publish.js $VSCODE_QUALITY $PLATFORM_RPM package $RPM_FILENAME $VERSION true $RPM_PATH + +if [ -z "$VSCODE_QUALITY" ]; then + echo "VSCODE_QUALITY is not set, skipping repo package publish" +else + if [ "$BUILD_SOURCEBRANCH" = "master" ] || [ "$BUILD_SOURCEBRANCH" = "refs/heads/master" ]; then + if [[ $BUILD_QUEUEDBY = *"Project Collection Service Accounts"* || $BUILD_QUEUEDBY = *"Microsoft.VisualStudio.Services.TFS"* ]]; then + # Get necessary information + pushd $REPO && COMMIT_HASH=$(git rev-parse HEAD) && popd + PACKAGE_NAME="$(ls $REPO/.build/linux/deb/$DEB_ARCH/deb/ | sed -e 's/_.*//g')" + DEB_URL="https://az764295.vo.msecnd.net/$VSCODE_QUALITY/$COMMIT_HASH/$DEB_FILENAME" + RPM_URL="https://az764295.vo.msecnd.net/$VSCODE_QUALITY/$COMMIT_HASH/$RPM_FILENAME" + PACKAGE_VERSION="$(ls $REPO/.build/linux/deb/$DEB_ARCH/deb/ | sed -e 's/code-[a-z]*_//g' -e 's/\_.*$//g')" + # Write config files needed by API, use eval to force environment variable expansion + DIRNAME=$(dirname $(readlink -f $0)) + pushd $DIRNAME + # Submit to apt repo + if [ "$DEB_ARCH" = "amd64" ]; then + eval echo '{ \"server\": \"azure-apt-cat.cloudapp.net\", \"protocol\": \"https\", \"port\": \"443\", \"repositoryId\": \"58a4adf642421134a1a48d1a\", \"username\": \"$LINUX_REPO_USERNAME\", \"password\": \"$LINUX_REPO_PASSWORD\" }' > apt-config.json + eval echo '{ \"name\": \"$PACKAGE_NAME\", \"version\": \"$PACKAGE_VERSION\", \"repositoryId\": \"58a4adf642421134a1a48d1a\", \"sourceUrl\": \"$DEB_URL\" }' > apt-addpkg.json + echo "Submitting apt-addpkg.json:" + cat apt-addpkg.json + + step "Publish to repositories" \ + ./repoapi_client.sh -config apt-config.json -addpkg apt-addpkg.json + fi + # Submit to yum repo (disabled as it's manual until signing is automated) + # eval echo '{ \"server\": \"azure-apt-cat.cloudapp.net\", \"protocol\": \"https\", \"port\": \"443\", \"repositoryId\": \"58a4ae3542421134a1a48d1b\", \"username\": \"$LINUX_REPO_USERNAME\", \"password\": \"$LINUX_REPO_PASSWORD\" }' > yum-config.json + # eval echo '{ \"name\": \"$PACKAGE_NAME\", \"version\": \"$PACKAGE_VERSION\", \"repositoryId\": \"58a4ae3542421134a1a48d1b\", \"sourceUrl\": \"$RPM_URL\" }' > yum-addpkg.json + # echo "Submitting yum-addpkg.json:" + # cat yum-addpkg.json + # ./repoapi_client.sh -config yum-config.json -addpkg yum-addpkg.json + popd + echo "To check repo publish status run ./repoapi_client.sh -config config.json -check " + fi + fi +fi diff --git a/build/tfs/linux/smoketest.sh b/build/tfs/linux/smoketest.sh new file mode 100644 index 00000000000..33344082253 --- /dev/null +++ b/build/tfs/linux/smoketest.sh @@ -0,0 +1,33 @@ +#!/bin/bash +set -e + +. ./scripts/env.sh +. ./build/tfs/common/common.sh + +export ARCH="$1" +export VSCODE_MIXIN_PASSWORD="$2" +VSO_PAT="$3" + +echo "machine monacotools.visualstudio.com password $VSO_PAT" > ~/.netrc + +step "Install dependencies" \ + npm install --arch=$ARCH --unsafe-perm + +step "Mix in repository from vscode-distro" \ + npm run gulp -- mixin + +step "Get Electron" \ + npm run gulp -- "electron-$ARCH" + +step "Install distro dependencies" \ + node build/tfs/common/installDistro.js --arch=$ARCH + +step "Build minified" \ + npm run gulp -- --max_old_space_size=4096 "vscode-linux-$ARCH-min" + +step "Run smoke test" \ + pushd test/smoke + npm install + npm run compile + xvfb-run -a -s="-screen 0 1024x768x8" node src/main.js --latest "$AGENT_BUILDDIRECTORY/VSCode-linux-ia32/code-insiders" + popd \ No newline at end of file diff --git a/build/tfs/win32/smoketest.ps1 b/build/tfs/win32/smoketest.ps1 new file mode 100644 index 00000000000..e7737a9f895 --- /dev/null +++ b/build/tfs/win32/smoketest.ps1 @@ -0,0 +1,46 @@ +Param( + [string]$arch, + [string]$mixinPassword, + [string]$vsoPAT +) + +. .\scripts\env.ps1 +. .\build\tfs\win32\lib.ps1 + +# Create a _netrc file to download distro dependencies +# In order to get _netrc to work, we need a HOME variable setup +$env:HOME=$env:USERPROFILE +"machine monacotools.visualstudio.com password ${vsoPAT}" | Out-File "$env:USERPROFILE\_netrc" -Encoding ASCII + +# Set the right architecture +$env:npm_config_arch="$arch" + +step "Install dependencies" { + exec { & npm install } +} + +$env:VSCODE_MIXIN_PASSWORD = $mixinPassword +step "Mix in repository from vscode-distro" { + exec { & npm run gulp -- mixin } +} + +step "Get Electron" { + exec { & npm run gulp -- "electron-$global:arch" } +} + +step "Install distro dependencies" { + exec { & node build\tfs\common\installDistro.js } +} + +step "Build minified" { + exec { & npm run gulp -- --max_old_space_size=4096 "vscode-win32-$global:arch-min" } +} + +step "Run smoke test" { + exec { & Push-Location test\smoke } + exec { & npm install; npm run compile } + exec { & node src/main.js --latest "$env:AGENT_BUILDDIRECTORY\VSCode-win32-$global:arch\Code - Insiders.exe" } + exec { & Pop-Location } +} + +done \ No newline at end of file diff --git a/extensions/git/src/commands.ts b/extensions/git/src/commands.ts index eed354dd8a4..127544276ab 100644 --- a/extensions/git/src/commands.ts +++ b/extensions/git/src/commands.ts @@ -774,7 +774,7 @@ export class CommandCenter { return; } - await this.model.pull(true); + await this.model.pullWithRebase(); } @command('git.push') @@ -812,7 +812,7 @@ export class CommandCenter { return; } - this.model.push(pick.label, branchName); + this.model.pushTo(pick.label, branchName); } @command('git.sync') @@ -860,7 +860,7 @@ export class CommandCenter { return; } - await this.model.push(choice, branchName, { setUpstream: true }); + await this.model.pushTo(choice, branchName, true); } @command('git.showOutput') diff --git a/extensions/git/src/git.ts b/extensions/git/src/git.ts index 9ef482def93..ad023efdf6e 100644 --- a/extensions/git/src/git.ts +++ b/extensions/git/src/git.ts @@ -21,10 +21,6 @@ export interface IGit { version: string; } -export interface PushOptions { - setUpstream?: boolean; -} - export interface IFileStatus { x: string; y: string; @@ -762,10 +758,10 @@ export class Repository { } } - async push(remote?: string, name?: string, options?: PushOptions): Promise { + async push(remote?: string, name?: string, setUpstream: boolean = false): Promise { const args = ['push']; - if (options && options.setUpstream) { + if (setUpstream) { args.push('-u'); } diff --git a/extensions/git/src/model.ts b/extensions/git/src/model.ts index aba4a4251d6..4b2cf900350 100644 --- a/extensions/git/src/model.ts +++ b/extensions/git/src/model.ts @@ -6,7 +6,7 @@ 'use strict'; import { Uri, Command, EventEmitter, Event, SourceControlResourceState, SourceControlResourceDecorations, Disposable, ProgressLocation, window, workspace } from 'vscode'; -import { Git, Repository, Ref, Branch, Remote, PushOptions, Commit, GitErrorCodes } from './git'; +import { Git, Repository, Ref, Branch, Remote, Commit, GitErrorCodes } from './git'; import { anyEvent, eventToPromise, filterEvent, EmptyDisposable, combinedDisposable, dispose } from './util'; import { memoize, throttle, debounce } from './decorators'; import * as path from 'path'; @@ -479,12 +479,23 @@ export class Model implements Disposable { } } - async pull(rebase?: boolean): Promise { - await this.run(Operation.Pull, () => this.repository.pull(rebase)); + @throttle + async pull(): Promise { + await this.run(Operation.Pull, () => this.repository.pull()); + } + + @throttle + async pullWithRebase(): Promise { + await this.run(Operation.Pull, () => this.repository.pull(true)); } - async push(remote?: string, name?: string, options?: PushOptions): Promise { - await this.run(Operation.Push, () => this.repository.push(remote, name, options)); + @throttle + async push(): Promise { + await this.run(Operation.Push, () => this.repository.push()); + } + + async pushTo(remote?: string, name?: string, setUpstream: boolean = false): Promise { + await this.run(Operation.Push, () => this.repository.push(remote, name, setUpstream)); } @throttle @@ -586,12 +597,13 @@ export class Model implements Disposable { const repositoryRoot = await this._git.getRepositoryRoot(this.workspaceRoot.fsPath); this.repository = this._git.open(repositoryRoot); - const onGitChange = filterEvent(this.onWorkspaceChange, uri => /\/\.git\//.test(uri.fsPath)); - const onRelevantGitChange = filterEvent(onGitChange, uri => !/\/\.git\/index\.lock$/.test(uri.fsPath)); + const onGitChange = filterEvent(this.onWorkspaceChange, uri => /\/\.git\//.test(uri.path)); + const onRelevantGitChange = filterEvent(onGitChange, uri => !/\/\.git\/index\.lock$/.test(uri.path)); + onRelevantGitChange(this.onFSChange, this, disposables); onRelevantGitChange(this._onDidChangeRepository.fire, this._onDidChangeRepository, disposables); - const onNonGitChange = filterEvent(this.onWorkspaceChange, uri => !/\/\.git\//.test(uri.fsPath)); + const onNonGitChange = filterEvent(this.onWorkspaceChange, uri => !/\/\.git\//.test(uri.path)); onNonGitChange(this.onFSChange, this, disposables); this.repositoryDisposable = combinedDisposable(disposables); diff --git a/extensions/json/server/npm-shrinkwrap.json b/extensions/json/server/npm-shrinkwrap.json index d199f7b2a0f..ae1d50bd689 100644 --- a/extensions/json/server/npm-shrinkwrap.json +++ b/extensions/json/server/npm-shrinkwrap.json @@ -43,9 +43,9 @@ "resolved": "https://registry.npmjs.org/request-light/-/request-light-0.2.1.tgz" }, "vscode-json-languageservice": { - "version": "2.0.9", + "version": "2.0.10", "from": "vscode-json-languageservice@next", - "resolved": "https://registry.npmjs.org/vscode-json-languageservice/-/vscode-json-languageservice-2.0.9.tgz" + "resolved": "https://registry.npmjs.org/vscode-json-languageservice/-/vscode-json-languageservice-2.0.10.tgz" }, "vscode-jsonrpc": { "version": "3.1.0-alpha.1", diff --git a/extensions/json/server/package.json b/extensions/json/server/package.json index 6c643c0f542..2897fd255db 100644 --- a/extensions/json/server/package.json +++ b/extensions/json/server/package.json @@ -10,7 +10,7 @@ "dependencies": { "jsonc-parser": "^0.4.2", "request-light": "^0.2.1", - "vscode-json-languageservice": "^2.0.9", + "vscode-json-languageservice": "^2.0.10", "vscode-languageserver": "^3.1.0-alpha.1", "vscode-nls": "^2.0.2" }, diff --git a/extensions/markdown/package.json b/extensions/markdown/package.json index 15c27055fe0..cbcb63c5531 100644 --- a/extensions/markdown/package.json +++ b/extensions/markdown/package.json @@ -161,7 +161,7 @@ }, "markdown.preview.fontFamily": { "type": "string", - "default": "system-ui, 'Segoe WPC', 'Segoe UI', 'HelveticaNeue-Light', 'Ubuntu', 'Droid Sans', sans-serif", + "default": "-apple-system, BlinkMacSystemFont, 'Segoe WPC', 'Segoe UI', 'HelveticaNeue-Light', 'Ubuntu', 'Droid Sans', sans-serif", "description": "%markdown.preview.fontFamily.desc%" }, "markdown.preview.fontSize": { diff --git a/extensions/theme-monokai-dimmed/themes/dimmed-monokai-color-theme.json b/extensions/theme-monokai-dimmed/themes/dimmed-monokai-color-theme.json index 68aeef661f0..a0994a3ff9a 100644 --- a/extensions/theme-monokai-dimmed/themes/dimmed-monokai-color-theme.json +++ b/extensions/theme-monokai-dimmed/themes/dimmed-monokai-color-theme.json @@ -191,7 +191,7 @@ }, { "name": "Class Variable", - "scope": "variable.other, variable.js, punctuation.separator.variable", + "scope": "variable.js, punctuation.separator.variable", "settings": { "fontStyle": "\n \t\t\t", "foreground": "#6089B4" @@ -229,14 +229,6 @@ "foreground": "#6089B4" } }, - { - "name": "Function Call", - "scope": "meta.function-call", - "settings": { - "fontStyle": "\n \t\t\t", - "foreground": "#0080FF" - } - }, { "name": "Function Object", "scope": "meta.function-call.object", @@ -245,14 +237,6 @@ "foreground": "#9872A2" } }, - { - "name": "Function Call Variable", - "scope": "variable.other.property", - "settings": { - "fontStyle": "\n \t\t\t", - "foreground": "#9872A2" - } - }, { "name": "Keyword Control", "scope": "keyword.control", @@ -550,6 +534,20 @@ "settings": { "foreground": "#b267e6" } + }, + { + "name": "this.self", + "scope": "variable.language", + "settings": { + "foreground": "#c7444a" + } + }, + { + "name": "this.self", + "scope": "variable.language", + "settings": { + "foreground": "#c7444a" + } } ] } \ No newline at end of file diff --git a/extensions/theme-monokai/themes/monokai-color-theme.json b/extensions/theme-monokai/themes/monokai-color-theme.json index 693494c71de..c8182750c5c 100644 --- a/extensions/theme-monokai/themes/monokai-color-theme.json +++ b/extensions/theme-monokai/themes/monokai-color-theme.json @@ -378,6 +378,13 @@ "settings": { "foreground": "#b267e6" } + }, + { + "name": "this.self", + "scope": "variable.language", + "settings": { + "foreground": "#FD971F" + } } ] } \ No newline at end of file diff --git a/extensions/typescript/src/features/bufferSyncSupport.ts b/extensions/typescript/src/features/bufferSyncSupport.ts index 05dbefb4a1a..64c8eea9a40 100644 --- a/extensions/typescript/src/features/bufferSyncSupport.ts +++ b/extensions/typescript/src/features/bufferSyncSupport.ts @@ -106,7 +106,7 @@ export default class BufferSyncSupport { private readonly disposables: Disposable[] = []; private readonly syncedBuffers: Map; - private pendingDiagnostics: { [key: string]: number; }; + private pendingDiagnostics = new Map(); private readonly diagnosticDelayer: Delayer; private checkGlobalTSCVersion: boolean; @@ -116,7 +116,6 @@ export default class BufferSyncSupport { this.diagnostics = diagnostics; this._validate = validate; - this.pendingDiagnostics = Object.create(null); this.diagnosticDelayer = new Delayer(300); this.syncedBuffers = new Map(); @@ -211,7 +210,7 @@ export default class BufferSyncSupport { return; } for (const filePath of this.syncedBuffers.keys()) { - this.pendingDiagnostics[filePath] = Date.now(); + this.pendingDiagnostics.set(filePath, Date.now()); } this.diagnosticDelayer.trigger(() => { this.sendPendingDiagnostics(); @@ -223,7 +222,7 @@ export default class BufferSyncSupport { return; } - this.pendingDiagnostics[file] = Date.now(); + this.pendingDiagnostics.set(file, Date.now()); const buffer = this.syncedBuffers.get(file); let delay = 300; if (buffer) { @@ -239,10 +238,10 @@ export default class BufferSyncSupport { if (!this._validate) { return; } - let files = Object.keys(this.pendingDiagnostics).map((key) => { + let files = Array.from(this.pendingDiagnostics.entries()).map(([key, value]) => { return { file: key, - time: this.pendingDiagnostics[key] + time: value }; }).sort((a, b) => { return a.time - b.time; @@ -252,7 +251,7 @@ export default class BufferSyncSupport { // Add all open TS buffers to the geterr request. They might be visible for (const file of this.syncedBuffers.keys()) { - if (!this.pendingDiagnostics[file]) { + if (!this.pendingDiagnostics.get(file)) { files.push(file); } } @@ -264,7 +263,7 @@ export default class BufferSyncSupport { }; this.client.execute('geterr', args, false); } - this.pendingDiagnostics = Object.create(null); + this.pendingDiagnostics.clear(); } private checkTSCVersion() { diff --git a/npm-shrinkwrap.json b/npm-shrinkwrap.json index a1d1223cab2..4705b55d2da 100644 --- a/npm-shrinkwrap.json +++ b/npm-shrinkwrap.json @@ -442,7 +442,7 @@ "xterm": { "version": "2.7.0", "from": "Tyriar/xterm.js#vscode-release/1.14", - "resolved": "git+https://github.com/Tyriar/xterm.js.git#7d3640ad17fbf69f1a1c776b6d08969e1da32875" + "resolved": "git+https://github.com/Tyriar/xterm.js.git#e6fe120ecf93e552573be45867ae03c880319e11" }, "yauzl": { "version": "2.3.1", diff --git a/src/vs/base/browser/dom.ts b/src/vs/base/browser/dom.ts index 2915bcb44bb..d0dfb1d885c 100644 --- a/src/vs/base/browser/dom.ts +++ b/src/vs/base/browser/dom.ts @@ -1042,7 +1042,15 @@ export function domContentLoaded(): TPromise { }); } -export function hintGPULayer(target: HTMLElement): void { - // This is to hint browsers that this dom node is suited to live in its own layer (e.g. sliders, etc.) - (target.style).willChange = 'transform'; +/** + * Find a value usable for a dom node size such that the likelihood that it would be + * displayed with constant screen pixels size is as high as possible. + * + * e.g. We would desire for the cursors to be 2px (CSS px) wide. Under a devicePixelRatio + * of 1.25, the cursor will be 2.5 screen pixels wide. Depending on how the dom node aligns/"snaps" + * with the screen pixels, it will sometimes be rendered with 2 screen pixels, and sometimes with 3 screen pixels. + */ +export function computeScreenAwareSize(cssPx: number): number { + const screenPx = window.devicePixelRatio * cssPx; + return Math.max(1, Math.floor(screenPx)) / window.devicePixelRatio; } diff --git a/src/vs/base/browser/fastDomNode.ts b/src/vs/base/browser/fastDomNode.ts index edd726ec0a2..695b48141e7 100644 --- a/src/vs/base/browser/fastDomNode.ts +++ b/src/vs/base/browser/fastDomNode.ts @@ -6,7 +6,7 @@ import * as dom from 'vs/base/browser/dom'; -export abstract class FastDomNode { +export class FastDomNode { public readonly domNode: T; private _maxWidth: number; @@ -25,7 +25,7 @@ export abstract class FastDomNode { private _display: string; private _position: string; private _visibility: string; - private _transform: string; + private _layerHint: boolean; constructor(domNode: T) { this.domNode = domNode; @@ -45,7 +45,7 @@ export abstract class FastDomNode { this._display = ''; this._position = ''; this._visibility = ''; - this._transform = ''; + this._layerHint = false; } public setMaxWidth(maxWidth: number): void { @@ -215,16 +215,14 @@ export abstract class FastDomNode { this.domNode.style.visibility = this._visibility; } - public setTransform(transform: string): void { - if (this._transform === transform) { + public setLayerHinting(layerHint: boolean): void { + if (this._layerHint === layerHint) { return; } - this._transform = transform; - this._setTransform(this.domNode, this._transform); + this._layerHint = layerHint; + (this.domNode.style).willChange = this._layerHint ? 'transform' : 'auto'; } - protected abstract _setTransform(domNode: T, transform: string): void; - public setAttribute(name: string, value: string): void { this.domNode.setAttribute(name, value); } @@ -250,29 +248,6 @@ export abstract class FastDomNode { } } -class WebKitFastDomNode extends FastDomNode { - protected _setTransform(domNode: T, transform: string): void { - (domNode.style).webkitTransform = transform; - } -} - -class StandardFastDomNode extends FastDomNode { - protected _setTransform(domNode: T, transform: string): void { - domNode.style.transform = transform; - } -} - -let useWebKitFastDomNode = false; -(function () { - let testDomNode = document.createElement('div'); - if (typeof (testDomNode.style).webkitTransform !== 'undefined') { - useWebKitFastDomNode = true; - } -})(); export function createFastDomNode(domNode: T): FastDomNode { - if (useWebKitFastDomNode) { - return new WebKitFastDomNode(domNode); - } else { - return new StandardFastDomNode(domNode); - } + return new FastDomNode(domNode); } diff --git a/src/vs/base/browser/ui/list/listView.ts b/src/vs/base/browser/ui/list/listView.ts index 91d89a81e55..497bf624a0c 100644 --- a/src/vs/base/browser/ui/list/listView.ts +++ b/src/vs/base/browser/ui/list/listView.ts @@ -81,7 +81,6 @@ export class ListView implements IDisposable { this.gesture = new Gesture(this.rowsContainer); this.scrollableElement = new ScrollableElement(this.rowsContainer, { - canUseTranslate3d: false, alwaysConsumeMouseWheel: true, horizontal: ScrollbarVisibility.Hidden, vertical: ScrollbarVisibility.Auto, diff --git a/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts b/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts index 7a8743cb62a..5d326d59eb4 100644 --- a/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts +++ b/src/vs/base/browser/ui/scrollbar/abstractScrollbar.ts @@ -32,7 +32,6 @@ export interface ScrollbarHost { } export interface AbstractScrollbarOptions { - canUseTranslate3d: boolean; lazyRender: boolean; host: ScrollbarHost; scrollbarState: ScrollbarState; @@ -43,7 +42,6 @@ export interface AbstractScrollbarOptions { export abstract class AbstractScrollbar extends Widget { - protected _canUseTranslate3d: boolean; protected _host: ScrollbarHost; protected _scrollable: Scrollable; private _lazyRender: boolean; @@ -58,7 +56,6 @@ export abstract class AbstractScrollbar extends Widget { constructor(opts: AbstractScrollbarOptions) { super(); - this._canUseTranslate3d = opts.canUseTranslate3d; this._lazyRender = opts.lazyRender; this._host = opts.host; this._scrollable = opts.scrollable; @@ -98,6 +95,7 @@ export abstract class AbstractScrollbar extends Widget { this.slider.setLeft(left); this.slider.setWidth(width); this.slider.setHeight(height); + this.slider.setLayerHinting(true); this.domNode.domNode.appendChild(this.slider.domNode); @@ -111,11 +109,6 @@ export abstract class AbstractScrollbar extends Widget { // ----------------- Update state - public setCanUseTranslate3d(canUseTranslate3d: boolean): boolean { - this._canUseTranslate3d = canUseTranslate3d; - return true; - } - protected _onElementSize(visibleSize: number): boolean { if (this._scrollbarState.setVisibleSize(visibleSize)) { this._visibilityController.setIsNeeded(this._scrollbarState.isNeeded()); @@ -165,14 +158,6 @@ export abstract class AbstractScrollbar extends Widget { } this._shouldRender = false; - if (this._canUseTranslate3d) { - // Put the scrollbar in its own layer - this.domNode.setTransform('translate3d(0px, 0px, 0px)'); - } else { - this.domNode.setTransform(''); - DomUtils.hintGPULayer(this.domNode.domNode); - } - this._renderDomNode(this._scrollbarState.getRectangleLargeSize(), this._scrollbarState.getRectangleSmallSize()); this._updateSlider(this._scrollbarState.getSliderSize(), this._scrollbarState.getArrowSize() + this._scrollbarState.getSliderPosition()); } diff --git a/src/vs/base/browser/ui/scrollbar/horizontalScrollbar.ts b/src/vs/base/browser/ui/scrollbar/horizontalScrollbar.ts index 8e7e678f46f..f6da6af6bc3 100644 --- a/src/vs/base/browser/ui/scrollbar/horizontalScrollbar.ts +++ b/src/vs/base/browser/ui/scrollbar/horizontalScrollbar.ts @@ -16,7 +16,6 @@ export class HorizontalScrollbar extends AbstractScrollbar { constructor(scrollable: Scrollable, options: ScrollableElementResolvedOptions, host: ScrollbarHost) { super({ - canUseTranslate3d: options.canUseTranslate3d, lazyRender: options.lazyRender, host: host, scrollbarState: new ScrollbarState( @@ -61,13 +60,7 @@ export class HorizontalScrollbar extends AbstractScrollbar { protected _updateSlider(sliderSize: number, sliderPosition: number): void { this.slider.setWidth(sliderSize); - if (this._canUseTranslate3d) { - this.slider.setTransform('translate3d(' + sliderPosition + 'px, 0px, 0px)'); - this.slider.setLeft(0); - } else { - this.slider.setTransform(''); - this.slider.setLeft(sliderPosition); - } + this.slider.setLeft(sliderPosition); } protected _renderDomNode(largeSize: number, smallSize: number): void { diff --git a/src/vs/base/browser/ui/scrollbar/scrollableElement.ts b/src/vs/base/browser/ui/scrollbar/scrollableElement.ts index c07026b7f72..7bb7da0f01e 100644 --- a/src/vs/base/browser/ui/scrollbar/scrollableElement.ts +++ b/src/vs/base/browser/ui/scrollbar/scrollableElement.ts @@ -6,7 +6,6 @@ import 'vs/css!./media/scrollbars'; -import * as Browser from 'vs/base/browser/browser'; import * as DomUtils from 'vs/base/browser/dom'; import * as Platform from 'vs/base/common/platform'; import { StandardMouseWheelEvent, IMouseEvent } from 'vs/base/browser/mouseEvent'; @@ -188,9 +187,6 @@ export class ScrollableElement extends Widget { this._options.mouseWheelScrollSensitivity = massagedOptions.mouseWheelScrollSensitivity; this._setListeningToMouseWheel(this._options.handleMouseWheel); - this._shouldRender = this._horizontalScrollbar.setCanUseTranslate3d(massagedOptions.canUseTranslate3d) || this._shouldRender; - this._shouldRender = this._verticalScrollbar.setCanUseTranslate3d(massagedOptions.canUseTranslate3d) || this._shouldRender; - if (!this._options.lazyRender) { this._render(); } @@ -409,7 +405,6 @@ export class DomScrollableElement extends ScrollableElement { function resolveOptions(opts: ScrollableElementCreationOptions): ScrollableElementResolvedOptions { let result: ScrollableElementResolvedOptions = { - canUseTranslate3d: opts.canUseTranslate3d && Browser.supportsTranslate3d, lazyRender: (typeof opts.lazyRender !== 'undefined' ? opts.lazyRender : false), className: (typeof opts.className !== 'undefined' ? opts.className : ''), useShadows: (typeof opts.useShadows !== 'undefined' ? opts.useShadows : true), diff --git a/src/vs/base/browser/ui/scrollbar/scrollableElementOptions.ts b/src/vs/base/browser/ui/scrollbar/scrollableElementOptions.ts index 032e637d5b5..5485e4eb84b 100644 --- a/src/vs/base/browser/ui/scrollbar/scrollableElementOptions.ts +++ b/src/vs/base/browser/ui/scrollbar/scrollableElementOptions.ts @@ -7,10 +7,6 @@ import { ScrollbarVisibility } from 'vs/base/common/scrollable'; export interface ScrollableElementCreationOptions { - /** - * Allow scrollbar rendering to use translate3d. - */ - canUseTranslate3d: boolean; /** * The scrollable element should not do any DOM mutations until renderNow() is called. * Defaults to false. @@ -105,13 +101,11 @@ export interface ScrollableElementCreationOptions { } export interface ScrollableElementChangeOptions { - canUseTranslate3d: boolean; handleMouseWheel?: boolean; mouseWheelScrollSensitivity?: number; } export interface ScrollableElementResolvedOptions { - canUseTranslate3d: boolean; lazyRender: boolean; className: string; useShadows: boolean; diff --git a/src/vs/base/browser/ui/scrollbar/verticalScrollbar.ts b/src/vs/base/browser/ui/scrollbar/verticalScrollbar.ts index ce33b4164b4..94a6130d90e 100644 --- a/src/vs/base/browser/ui/scrollbar/verticalScrollbar.ts +++ b/src/vs/base/browser/ui/scrollbar/verticalScrollbar.ts @@ -16,7 +16,6 @@ export class VerticalScrollbar extends AbstractScrollbar { constructor(scrollable: Scrollable, options: ScrollableElementResolvedOptions, host: ScrollbarHost) { super({ - canUseTranslate3d: options.canUseTranslate3d, lazyRender: options.lazyRender, host: host, scrollbarState: new ScrollbarState( @@ -66,13 +65,7 @@ export class VerticalScrollbar extends AbstractScrollbar { protected _updateSlider(sliderSize: number, sliderPosition: number): void { this.slider.setHeight(sliderSize); - if (this._canUseTranslate3d) { - this.slider.setTransform('translate3d(0px, ' + sliderPosition + 'px, 0px)'); - this.slider.setTop(0); - } else { - this.slider.setTransform(''); - this.slider.setTop(sliderPosition); - } + this.slider.setTop(sliderPosition); } protected _renderDomNode(largeSize: number, smallSize: number): void { diff --git a/src/vs/base/common/errorMessage.ts b/src/vs/base/common/errorMessage.ts index 9f5ed7fda90..3c882cba229 100644 --- a/src/vs/base/common/errorMessage.ts +++ b/src/vs/base/common/errorMessage.ts @@ -165,7 +165,7 @@ function detectSystemErrorMessage(exception: any): string { // See https://nodejs.org/api/errors.html#errors_class_system_error if (typeof exception.code === 'string' && typeof exception.errno === 'number' && typeof exception.syscall === 'string') { - return nls.localize('nodeExceptionMessage', "A system error occured ({0})", exception.message); + return nls.localize('nodeExceptionMessage', "A system error occurred ({0})", exception.message); } return exception.message; diff --git a/src/vs/base/common/marked/OSSREADME.json b/src/vs/base/common/marked/OSSREADME.json index 5fc985980a4..5bfc34a583b 100644 --- a/src/vs/base/common/marked/OSSREADME.json +++ b/src/vs/base/common/marked/OSSREADME.json @@ -3,6 +3,6 @@ [{ "name": "chjj-marked", "repositoryURL": "https://github.com/npmcomponent/chjj-marked", - "version": "0.3.2", + "version": "0.3.6", "license": "MIT" }] diff --git a/src/vs/base/common/marked/raw.marked.js b/src/vs/base/common/marked/raw.marked.js index ce02369727a..0ee6a3b1e6a 100644 --- a/src/vs/base/common/marked/raw.marked.js +++ b/src/vs/base/common/marked/raw.marked.js @@ -1,4 +1,3 @@ - /** * marked - a markdown parser * Copyright (c) 2011-2014, Christopher Jeffrey. (MIT Licensed) @@ -78,8 +77,9 @@ block.normal = merge({}, block); */ block.gfm = merge({}, block.normal, { - fences: /^ *(`{3,}|~{3,}) *(\S+)? *\n([\s\S]+?)\s*\1 *(?:\n+|$)/, - paragraph: /^/ + fences: /^ *(`{3,}|~{3,})[ \.]*(\S+)? *\n([\s\S]*?)\s*\1 *(?:\n+|$)/, + paragraph: /^/, + heading: /^ *(#{1,6}) +([^\n]+?) *#* *(?:\n+|$)/ }); block.gfm.paragraph = replace(block.paragraph) @@ -191,7 +191,7 @@ Lexer.prototype.token = function(src, top, bq) { this.tokens.push({ type: 'code', lang: cap[2], - text: cap[3] + text: cap[3] || '' }); continue; } @@ -362,7 +362,8 @@ Lexer.prototype.token = function(src, top, bq) { type: this.options.sanitize ? 'paragraph' : 'html', - pre: cap[1] === 'pre' || cap[1] === 'script' || cap[1] === 'style', + pre: !this.options.sanitizer + && (cap[1] === 'pre' || cap[1] === 'script' || cap[1] === 'style'), text: cap[0] }); continue; @@ -457,7 +458,7 @@ var inline = { reflink: /^!?\[(inside)\]\s*\[([^\]]*)\]/, nolink: /^!?\[((?:\[[^\]]*\]|[^\[\]])*)\]/, strong: /^__([\s\S]+?)__(?!_)|^\*\*([\s\S]+?)\*\*(?!\*)/, - em: /^\b_((?:__|[\s\S])+?)_\b|^\*((?:\*\*|[\s\S])+?)\*(?!\*)/, + em: /^\b_((?:[^_]|__)+?)_\b|^\*((?:\*\*|[\s\S])+?)\*(?!\*)/, code: /^(`+)\s*([\s\S]*?[^`])\s*\1(?!`)/, br: /^ {2,}\n(?!\s*$)/, del: noop, @@ -609,8 +610,10 @@ InlineLexer.prototype.output = function(src) { } src = src.substring(cap[0].length); out += this.options.sanitize - ? escape(cap[0]) - : cap[0]; + ? this.options.sanitizer + ? this.options.sanitizer(cap[0]) + : escape(cap[0]) + : cap[0] continue; } @@ -681,7 +684,7 @@ InlineLexer.prototype.output = function(src) { // text if (cap = this.rules.text.exec(src)) { src = src.substring(cap[0].length); - out += escape(this.smartypants(cap[0])); + out += this.renderer.text(escape(this.smartypants(cap[0]))); continue; } @@ -710,24 +713,24 @@ InlineLexer.prototype.outputLink = function(cap, link) { /** * Smartypants Transformations */ -// TODO MonacoChange: Our build fails over the following lines if they are not commented out + InlineLexer.prototype.smartypants = function(text) { - return text; -// if (!this.options.smartypants) return text; -// return text -// // em-dashes -// .replace(/--/g, '\u2014') -// // opening singles -// .replace(/(^|[-\u2014/(\[{"\s])'/g, '$1\u2018') -// // closing singles & apostrophes -// .replace(/'/g, '\u2019') -// // opening doubles -// .replace(/(^|[-\u2014/(\[{\u2018\s])"/g, '$1\u201c') -// // closing doubles -// .replace(/"/g, '\u201d') -// // ellipses -// .replace(/\.{3}/g, '\u2026'); -// END MonacoChange + if (!this.options.smartypants) return text; + return text + // em-dashes + .replace(/---/g, '\u2014') + // en-dashes + .replace(/--/g, '\u2013') + // opening singles + .replace(/(^|[-\u2014/(\[{"\s])'/g, '$1\u2018') + // closing singles & apostrophes + .replace(/'/g, '\u2019') + // opening doubles + .replace(/(^|[-\u2014/(\[{\u2018\s])"/g, '$1\u201c') + // closing doubles + .replace(/"/g, '\u201d') + // ellipses + .replace(/\.{3}/g, '\u2026'); }; /** @@ -735,6 +738,7 @@ InlineLexer.prototype.smartypants = function(text) { */ InlineLexer.prototype.mangle = function(text) { + if (!this.options.mangle) return text; var out = '' , l = text.length , i = 0 @@ -873,7 +877,7 @@ Renderer.prototype.link = function(href, title, text) { } catch (e) { return ''; } - if (prot.indexOf('javascript:') === 0) { + if (prot.indexOf('javascript:') === 0 || prot.indexOf('vbscript:') === 0 || prot.indexOf('data:') === 0) { return ''; } } @@ -894,6 +898,10 @@ Renderer.prototype.image = function(href, title, text) { return out; }; +Renderer.prototype.text = function(text) { + return text; +}; + /** * Parsing & Compiling */ @@ -1088,7 +1096,8 @@ function escape(html, encode) { } function unescape(html) { - return html.replace(/&([#\w]+);/g, function(_, n) { + // explicitly match decimal, hex, and named HTML entities + return html.replace(/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/g, function(_, n) { n = n.toLowerCase(); if (n === 'colon') return ':'; if (n.charAt(0) === '#') { @@ -1213,7 +1222,7 @@ function marked(src, opt, callback) { } catch (e) { e.message += '\nPlease report this to https://github.com/chjj/marked.'; if ((opt || marked.defaults).silent) { - return '

    An error occured:

    '
    +      return '

    An error occurred:

    '
             + escape(e.message + '', true)
             + '
    '; } @@ -1237,6 +1246,8 @@ marked.defaults = { breaks: false, pedantic: false, sanitize: false, + sanitizer: null, + mangle: true, smartLists: false, silent: false, highlight: null, diff --git a/src/vs/base/parts/tree/browser/treeView.ts b/src/vs/base/parts/tree/browser/treeView.ts index fbbef901f54..b424249e1eb 100644 --- a/src/vs/base/parts/tree/browser/treeView.ts +++ b/src/vs/base/parts/tree/browser/treeView.ts @@ -460,7 +460,6 @@ export class TreeView extends HeightMap { this.wrapper = document.createElement('div'); this.wrapper.className = 'monaco-tree-wrapper'; this.scrollableElement = new ScrollableElement(this.wrapper, { - canUseTranslate3d: false, alwaysConsumeMouseWheel: true, horizontal: ScrollbarVisibility.Hidden, vertical: (typeof context.options.verticalScrollMode !== 'undefined' ? context.options.verticalScrollMode : ScrollbarVisibility.Auto), diff --git a/src/vs/code/electron-main/app.ts b/src/vs/code/electron-main/app.ts index 8effa87307f..a9adcc1e33a 100644 --- a/src/vs/code/electron-main/app.ts +++ b/src/vs/code/electron-main/app.ts @@ -121,7 +121,7 @@ export class CodeApplication { }); const isValidWebviewSource = (source: string) => - !source || (source.toLowerCase() as any).startsWith(URI.file(this.environmentService.appRoot.toLowerCase()).toString()); + !source || (URI.parse(source.toLowerCase()).toString() as any).startsWith(URI.file(this.environmentService.appRoot.toLowerCase()).toString()); app.on('web-contents-created', (event, contents) => { contents.on('will-attach-webview', (event, webPreferences, params) => { diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index a2193ec6244..8679eabeeef 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -263,6 +263,11 @@ export class CodeMenu { const helpMenuItem = new MenuItem({ label: this.mnemonicLabel(nls.localize({ key: 'mHelp', comment: ['&& denotes a mnemonic'] }, "&&Help")), submenu: helpMenu, role: 'help' }); this.setHelpMenu(helpMenu); + // Tasks + const taskMenu = new Menu(); + const taskMenuItem = new MenuItem({ label: this.mnemonicLabel(nls.localize({ key: 'mTask', comment: ['&& denotes a mnemonic'] }, "&&Tasks")), submenu: taskMenu }); + this.setTaskMenu(taskMenu); + // Menu Structure if (macApplicationMenuItem) { menubar.append(macApplicationMenuItem); @@ -274,6 +279,7 @@ export class CodeMenu { menubar.append(viewMenuItem); menubar.append(gotoMenuItem); menubar.append(debugMenuItem); + menubar.append(taskMenuItem); if (macWindowMenuItem) { menubar.append(macWindowMenuItem); @@ -586,7 +592,6 @@ export class CodeMenu { const output = this.createMenuItem(nls.localize({ key: 'miToggleOutput', comment: ['&& denotes a mnemonic'] }, "&&Output"), 'workbench.action.output.toggleOutput'); const debugConsole = this.createMenuItem(nls.localize({ key: 'miToggleDebugConsole', comment: ['&& denotes a mnemonic'] }, "De&&bug Console"), 'workbench.debug.action.toggleRepl'); const integratedTerminal = this.createMenuItem(nls.localize({ key: 'miToggleIntegratedTerminal', comment: ['&& denotes a mnemonic'] }, "&&Integrated Terminal"), 'workbench.action.terminal.toggleTerminal'); - const taskMenu = this.createMenuItem(nls.localize({ key: 'miShowTask', comment: ['&& denotes a mnemonic'] }, "Show Tas&&ks..."), 'workbench.action.showTasks'); const problems = this.createMenuItem(nls.localize({ key: 'miMarker', comment: ['&& denotes a mnemonic'] }, "&&Problems"), 'workbench.actions.view.problems'); let additionalViewlets: Electron.MenuItem; @@ -658,7 +663,6 @@ export class CodeMenu { problems, debugConsole, integratedTerminal, - taskMenu, __separator__(), fullscreen, toggleZenMode, @@ -901,6 +905,24 @@ export class CodeMenu { } } + private setTaskMenu(taskMenu: Electron.Menu): void { + const runTask = this.createMenuItem(nls.localize({ key: 'miRunTask', comment: ['&& denotes a mnemonic'] }, "&&Run Task..."), 'workbench.action.tasks.runTask'); + const restartTask = this.createMenuItem(nls.localize({ key: 'miRestartTask', comment: ['&& denotes a mnemonic'] }, "R&&estart Task"), 'workbench.action.tasks.restartTask'); + const terminateTask = this.createMenuItem(nls.localize({ key: 'miTerminateTask', comment: ['&& denotes a mnemonic'] }, "&&Terminate Task"), 'workbench.action.tasks.terminate'); + const buildTask = this.createMenuItem(nls.localize({ key: 'miBuildTask', comment: ['&& denotes a mnemonic'] }, "&&Build Task"), 'workbench.action.tasks.build'); + const testTask = this.createMenuItem(nls.localize({ key: 'miTestTask', comment: ['&& denotes a mnemonic'] }, "Test T&&ask"), 'workbench.action.tasks.test'); + const showTaskLog = this.createMenuItem(nls.localize({ key: 'miShowTaskLog', comment: ['&& denotes a mnemonic'] }, "&&Show Task Log"), 'workbench.action.tasks.showLog'); + + [ + showTaskLog, + runTask, + restartTask, + terminateTask, + buildTask, + testTask + ].forEach(item => taskMenu.append(item)); + } + private openAccessibilityOptions(): void { let win = new BrowserWindow({ alwaysOnTop: true, diff --git a/src/vs/editor/browser/config/configuration.ts b/src/vs/editor/browser/config/configuration.ts index 960faa7b1e6..0a7787b4926 100644 --- a/src/vs/editor/browser/config/configuration.ts +++ b/src/vs/editor/browser/config/configuration.ts @@ -351,7 +351,6 @@ export class Configuration extends CommonEditorConfiguration { extraEditorClassName: this._getExtraEditorClassName(), outerWidth: this._elementSizeObserver.getWidth(), outerHeight: this._elementSizeObserver.getHeight(), - canUseTranslate3d: browser.canUseTranslate3d(), emptySelectionClipboard: browser.isWebKit, pixelRatio: browser.getPixelRatio(), zoomLevel: browser.getZoomLevel(), diff --git a/src/vs/editor/browser/controller/mouseHandler.ts b/src/vs/editor/browser/controller/mouseHandler.ts index cc44acdd62d..60ff6e4d650 100644 --- a/src/vs/editor/browser/controller/mouseHandler.ts +++ b/src/vs/editor/browser/controller/mouseHandler.ts @@ -185,7 +185,7 @@ export class MouseHandler extends ViewEventHandler { } let actualMouseMoveTime = e.timestamp; if (actualMouseMoveTime < this.lastMouseLeaveTime) { - // Due to throttling, this event occured before the mouse left the editor, therefore ignore it. + // Due to throttling, this event occurred before the mouse left the editor, therefore ignore it. return; } diff --git a/src/vs/editor/browser/services/codeEditorServiceImpl.ts b/src/vs/editor/browser/services/codeEditorServiceImpl.ts index eaf57c98d5d..f36e32b73fa 100644 --- a/src/vs/editor/browser/services/codeEditorServiceImpl.ts +++ b/src/vs/editor/browser/services/codeEditorServiceImpl.ts @@ -344,9 +344,7 @@ class DecorationCSSRules { } let cssTextArr: string[] = []; this.collectCSSText(opts, ['backgroundColor'], cssTextArr); - if (this.collectCSSText(opts, ['outline', 'outlineColor'], cssTextArr)) { - this.collectCSSText(opts, ['outlineStyle', 'outlineWidth'], cssTextArr); - } + this.collectCSSText(opts, ['outline', 'outlineColor', 'outlineStyle', 'outlineWidth'], cssTextArr); this.collectBorderSettingsCSSText(opts, cssTextArr); return cssTextArr.join(''); } @@ -418,8 +416,7 @@ class DecorationCSSRules { } private collectBorderSettingsCSSText(opts: any, cssTextArr: string[]): boolean { - if (this.collectCSSText(opts, ['border', 'borderColor'], cssTextArr)) { - this.collectCSSText(opts, ['borderRadius', 'borderSpacing', 'borderStyle', 'borderWidth'], cssTextArr); + if (this.collectCSSText(opts, ['border', 'borderColor', 'borderRadius', 'borderSpacing', 'borderStyle', 'borderWidth'], cssTextArr)) { cssTextArr.push(strings.format('box-sizing: border-box;')); return true; } @@ -444,7 +441,7 @@ class DecorationCSSRules { if (color) { return color.toString(); } - return void 0; + return 'transparent'; } return value; } diff --git a/src/vs/editor/browser/standalone/media/standalone-tokens.css b/src/vs/editor/browser/standalone/media/standalone-tokens.css index de07f233940..b815c5e181c 100644 --- a/src/vs/editor/browser/standalone/media/standalone-tokens.css +++ b/src/vs/editor/browser/standalone/media/standalone-tokens.css @@ -6,7 +6,7 @@ /* Default standalone editor font */ .monaco-editor { - font-family: system-ui, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", "Ubuntu", "Droid Sans", sans-serif; + font-family: -apple-system, BlinkMacSystemFont, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", "Ubuntu", "Droid Sans", sans-serif; } .monaco-menu .monaco-action-bar.vertical .action-item .action-label:focus { diff --git a/src/vs/editor/browser/standalone/simpleServices.ts b/src/vs/editor/browser/standalone/simpleServices.ts index c063ec34f7b..a177a093718 100644 --- a/src/vs/editor/browser/standalone/simpleServices.ts +++ b/src/vs/editor/browser/standalone/simpleServices.ts @@ -37,6 +37,7 @@ import { ResolvedKeybinding, Keybinding, createKeybinding, SimpleKeybinding } fr import { ResolvedKeybindingItem } from 'vs/platform/keybinding/common/resolvedKeybindingItem'; import { OS } from 'vs/base/common/platform'; import { IRange } from 'vs/editor/common/core/range'; +import { generateUuid } from "vs/base/common/uuid"; export class SimpleEditor implements IEditor { @@ -499,9 +500,11 @@ export class SimpleWorkspaceContextService implements IWorkspaceContextService { public readonly onDidChangeWorkspaceRoots: Event = this._onDidChangeWorkspaceRoots.event; private readonly folders: URI[]; + private readonly id: string; constructor(private workspace?: Workspace) { this.folders = workspace ? [workspace.resource] : []; + this.id = generateUuid(); } public getFolders(): URI[] { @@ -513,7 +516,7 @@ export class SimpleWorkspaceContextService implements IWorkspaceContextService { } public getWorkspace2(): IWorkspace2 { - return this.workspace ? { id: `${this.workspace.uid}`, roots: [this.workspace.resource] } : void 0; + return this.workspace ? { id: `${this.id}`, roots: [this.workspace.resource], name: this.workspace.resource.fsPath } : void 0; } public hasWorkspace(): boolean { diff --git a/src/vs/editor/browser/standalone/standaloneLanguages.ts b/src/vs/editor/browser/standalone/standaloneLanguages.ts index 0750a1db0a9..654a43b5f0e 100644 --- a/src/vs/editor/browser/standalone/standaloneLanguages.ts +++ b/src/vs/editor/browser/standalone/standaloneLanguages.ts @@ -290,7 +290,7 @@ export function registerDocumentSymbolProvider(languageId: string, provider: mod } /** - * Register a document highlight provider (used by e.g. highlight occurences). + * Register a document highlight provider (used by e.g. highlight occurrences). */ export function registerDocumentHighlightProvider(languageId: string, provider: modes.DocumentHighlightProvider): IDisposable { return modes.DocumentHighlightProviderRegistry.register(languageId, provider); diff --git a/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.ts b/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.ts index a90d8f52d03..8ceb2845eb3 100644 --- a/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.ts +++ b/src/vs/editor/browser/viewParts/editorScrollbar/editorScrollbar.ts @@ -34,7 +34,6 @@ export class EditorScrollbar extends ViewPart { const configScrollbarOpts = editor.viewInfo.scrollbar; let scrollbarOptions: ScrollableElementCreationOptions = { - canUseTranslate3d: editor.canUseTranslate3d, listenOnDomNode: viewDomNode.domNode, className: 'editor-scrollable' + ' ' + getThemeTypeSelector(context.theme.type), useShadows: false, @@ -127,10 +126,9 @@ export class EditorScrollbar extends ViewPart { // --- begin event handlers public onConfigurationChanged(e: viewEvents.ViewConfigurationChangedEvent): boolean { - if (e.viewInfo || e.canUseTranslate3d) { + if (e.viewInfo) { const editor = this._context.configuration.editor; let newOpts: ScrollableElementChangeOptions = { - canUseTranslate3d: editor.canUseTranslate3d, handleMouseWheel: editor.viewInfo.scrollbar.handleMouseWheel, mouseWheelScrollSensitivity: editor.viewInfo.scrollbar.mouseWheelScrollSensitivity }; diff --git a/src/vs/editor/browser/viewParts/indentGuides/indentGuides.css b/src/vs/editor/browser/viewParts/indentGuides/indentGuides.css index 7cd5f89fd9f..45992137d18 100644 --- a/src/vs/editor/browser/viewParts/indentGuides/indentGuides.css +++ b/src/vs/editor/browser/viewParts/indentGuides/indentGuides.css @@ -9,5 +9,4 @@ */ .monaco-editor .lines-content .cigr { position: absolute; - width: 1px; } diff --git a/src/vs/editor/browser/viewParts/indentGuides/indentGuides.ts b/src/vs/editor/browser/viewParts/indentGuides/indentGuides.ts index 5b3a301abc0..caa4f1449a8 100644 --- a/src/vs/editor/browser/viewParts/indentGuides/indentGuides.ts +++ b/src/vs/editor/browser/viewParts/indentGuides/indentGuides.ts @@ -12,6 +12,7 @@ import { RenderingContext } from 'vs/editor/common/view/renderingContext'; import * as viewEvents from 'vs/editor/common/view/viewEvents'; import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; import { editorIndentGuides } from 'vs/editor/common/view/editorColorRegistry'; +import * as dom from 'vs/base/browser/dom'; export class IndentGuidesOverlay extends DynamicViewOverlay { @@ -85,6 +86,7 @@ export class IndentGuidesOverlay extends DynamicViewOverlay { const tabSize = this._context.model.getTabSize(); const tabWidth = tabSize * this._spaceWidth; const lineHeight = this._lineHeight; + const indentGuideWidth = dom.computeScreenAwareSize(1); let output: string[] = []; for (let lineNumber = visibleStartLineNumber; lineNumber <= visibleEndLineNumber; lineNumber++) { @@ -94,7 +96,7 @@ export class IndentGuidesOverlay extends DynamicViewOverlay { let result = ''; let left = 0; for (let i = 0; i < indent; i++) { - result += `
    `; + result += `
    `; left += tabWidth; } diff --git a/src/vs/editor/browser/viewParts/lines/viewLines.ts b/src/vs/editor/browser/viewParts/lines/viewLines.ts index 462a4e5160d..6998bc6a8ea 100644 --- a/src/vs/editor/browser/viewParts/lines/viewLines.ts +++ b/src/vs/editor/browser/viewParts/lines/viewLines.ts @@ -52,7 +52,7 @@ export class ViewLines extends ViewPart implements IVisibleLinesHost, private _typicalHalfwidthCharacterWidth: number; private _isViewportWrapping: boolean; private _revealHorizontalRightPadding: number; - private _canUseTranslate3d: boolean; + private _canUseLayerHinting: boolean; private _viewLineOptions: ViewLineOptions; // --- width @@ -75,7 +75,7 @@ export class ViewLines extends ViewPart implements IVisibleLinesHost, this._typicalHalfwidthCharacterWidth = conf.editor.fontInfo.typicalHalfwidthCharacterWidth; this._isViewportWrapping = conf.editor.wrappingInfo.isViewportWrapping; this._revealHorizontalRightPadding = conf.editor.viewInfo.revealHorizontalRightPadding; - this._canUseTranslate3d = conf.editor.canUseTranslate3d; + this._canUseLayerHinting = conf.editor.canUseLayerHinting; this._viewLineOptions = new ViewLineOptions(conf); PartFingerprints.write(this.domNode, PartFingerprint.ViewLines); @@ -132,8 +132,8 @@ export class ViewLines extends ViewPart implements IVisibleLinesHost, if (e.viewInfo) { this._revealHorizontalRightPadding = conf.editor.viewInfo.revealHorizontalRightPadding; } - if (e.canUseTranslate3d) { - this._canUseTranslate3d = conf.editor.canUseTranslate3d; + if (e.canUseLayerHinting) { + this._canUseLayerHinting = conf.editor.canUseLayerHinting; } if (e.fontInfo) { Configuration.applyFontInfo(this.domNode, conf.editor.fontInfo); @@ -443,17 +443,10 @@ export class ViewLines extends ViewPart implements IVisibleLinesHost, } // (3) handle scrolling + this._linesContent.setLayerHinting(this._canUseLayerHinting); const adjustedScrollTop = this._context.viewLayout.getScrollTop() - viewportData.bigNumbersDelta; - if (this._canUseTranslate3d) { - let transform = 'translate3d(' + -this._context.viewLayout.getScrollLeft() + 'px, ' + -adjustedScrollTop + 'px, 0px)'; - this._linesContent.setTransform(transform); - this._linesContent.setTop(0); - this._linesContent.setLeft(0); - } else { - this._linesContent.setTransform(''); - this._linesContent.setTop(-adjustedScrollTop); - this._linesContent.setLeft(-this._context.viewLayout.getScrollLeft()); - } + this._linesContent.setTop(-adjustedScrollTop); + this._linesContent.setLeft(-this._context.viewLayout.getScrollLeft()); // Update max line width (not so important, it is just so the horizontal scrollbar doesn't get too small) this._asyncUpdateLineWidths.schedule(); diff --git a/src/vs/editor/browser/viewParts/margin/margin.ts b/src/vs/editor/browser/viewParts/margin/margin.ts index 35fcf1563b9..bd3fc8b97a6 100644 --- a/src/vs/editor/browser/viewParts/margin/margin.ts +++ b/src/vs/editor/browser/viewParts/margin/margin.ts @@ -16,7 +16,7 @@ export class Margin extends ViewPart { public static CLASS_NAME = 'glyph-margin'; private _domNode: FastDomNode; - private _canUseTranslate3d: boolean; + private _canUseLayerHinting: boolean; private _contentLeft: number; private _glyphMarginLeft: number; private _glyphMarginWidth: number; @@ -24,7 +24,7 @@ export class Margin extends ViewPart { constructor(context: ViewContext) { super(context); - this._canUseTranslate3d = this._context.configuration.editor.canUseTranslate3d; + this._canUseLayerHinting = this._context.configuration.editor.canUseLayerHinting; this._contentLeft = this._context.configuration.editor.layoutInfo.contentLeft; this._glyphMarginLeft = this._context.configuration.editor.layoutInfo.glyphMarginLeft; this._glyphMarginWidth = this._context.configuration.editor.layoutInfo.glyphMarginWidth; @@ -57,8 +57,8 @@ export class Margin extends ViewPart { // --- begin event handlers public onConfigurationChanged(e: viewEvents.ViewConfigurationChangedEvent): boolean { - if (e.canUseTranslate3d) { - this._canUseTranslate3d = this._context.configuration.editor.canUseTranslate3d; + if (e.canUseLayerHinting) { + this._canUseLayerHinting = this._context.configuration.editor.canUseLayerHinting; } if (e.layoutInfo) { @@ -80,15 +80,9 @@ export class Margin extends ViewPart { } public render(ctx: RestrictedRenderingContext): void { + this._domNode.setLayerHinting(this._canUseLayerHinting); const adjustedScrollTop = ctx.scrollTop - ctx.bigNumbersDelta; - if (this._canUseTranslate3d) { - let transform = 'translate3d(0px, ' + -adjustedScrollTop + 'px, 0px)'; - this._domNode.setTransform(transform); - this._domNode.setTop(0); - } else { - this._domNode.setTransform(''); - this._domNode.setTop(-adjustedScrollTop); - } + this._domNode.setTop(-adjustedScrollTop); let height = Math.min(ctx.scrollHeight, 1000000); this._domNode.setHeight(height); diff --git a/src/vs/editor/browser/viewParts/minimap/minimap.ts b/src/vs/editor/browser/viewParts/minimap/minimap.ts index 70cb44e1523..98609ffbbcd 100644 --- a/src/vs/editor/browser/viewParts/minimap/minimap.ts +++ b/src/vs/editor/browser/viewParts/minimap/minimap.ts @@ -413,7 +413,7 @@ export class Minimap extends ViewPart { this._slider = createFastDomNode(document.createElement('div')); this._slider.setPosition('absolute'); this._slider.setClassName('minimap-slider'); - dom.hintGPULayer(this._slider.domNode); + this._slider.setLayerHinting(true); this._domNode.appendChild(this._slider); this._tokensColorTracker = MinimapTokensColorTracker.getInstance(); diff --git a/src/vs/editor/browser/viewParts/overviewRuler/decorationsOverviewRuler.ts b/src/vs/editor/browser/viewParts/overviewRuler/decorationsOverviewRuler.ts index 46c6d71d941..3c4f0a6c3ab 100644 --- a/src/vs/editor/browser/viewParts/overviewRuler/decorationsOverviewRuler.ts +++ b/src/vs/editor/browser/viewParts/overviewRuler/decorationsOverviewRuler.ts @@ -46,7 +46,6 @@ export class DecorationsOverviewRuler extends ViewPart { 'decorationsOverviewRuler', this._context.viewLayout.getScrollHeight(), this._context.configuration.editor.lineHeight, - this._context.configuration.editor.canUseTranslate3d, this._context.configuration.editor.pixelRatio, DecorationsOverviewRuler.MIN_DECORATION_HEIGHT, DecorationsOverviewRuler.MAX_DECORATION_HEIGHT, @@ -101,10 +100,6 @@ export class DecorationsOverviewRuler extends ViewPart { this._overviewRuler.setLineHeight(this._context.configuration.editor.lineHeight, false); } - if (e.canUseTranslate3d) { - this._overviewRuler.setCanUseTranslate3d(this._context.configuration.editor.canUseTranslate3d, false); - } - if (e.pixelRatio) { this._overviewRuler.setPixelRatio(this._context.configuration.editor.pixelRatio, false); } diff --git a/src/vs/editor/browser/viewParts/overviewRuler/overviewRuler.ts b/src/vs/editor/browser/viewParts/overviewRuler/overviewRuler.ts index 65c793de876..bb2b4ee58ce 100644 --- a/src/vs/editor/browser/viewParts/overviewRuler/overviewRuler.ts +++ b/src/vs/editor/browser/viewParts/overviewRuler/overviewRuler.ts @@ -25,7 +25,6 @@ export class OverviewRuler extends ViewEventHandler implements IOverviewRuler { cssClassName, this._context.viewLayout.getScrollHeight(), this._context.configuration.editor.lineHeight, - this._context.configuration.editor.canUseTranslate3d, this._context.configuration.editor.pixelRatio, minimumHeight, maximumHeight, @@ -48,10 +47,6 @@ export class OverviewRuler extends ViewEventHandler implements IOverviewRuler { this._overviewRuler.setLineHeight(this._context.configuration.editor.lineHeight, true); } - if (e.canUseTranslate3d) { - this._overviewRuler.setCanUseTranslate3d(this._context.configuration.editor.canUseTranslate3d, true); - } - if (e.pixelRatio) { this._overviewRuler.setPixelRatio(this._context.configuration.editor.pixelRatio, true); } diff --git a/src/vs/editor/browser/viewParts/overviewRuler/overviewRulerImpl.ts b/src/vs/editor/browser/viewParts/overviewRuler/overviewRulerImpl.ts index 617a850a1d7..2e6a03a39d8 100644 --- a/src/vs/editor/browser/viewParts/overviewRuler/overviewRulerImpl.ts +++ b/src/vs/editor/browser/viewParts/overviewRuler/overviewRulerImpl.ts @@ -17,12 +17,11 @@ export class OverviewRulerImpl { private _domNode: FastDomNode; private _lanesCount: number; private _zoneManager: OverviewZoneManager; - private _canUseTranslate3d: boolean; private _background: Color; constructor( canvasLeftOffset: number, cssClassName: string, scrollHeight: number, lineHeight: number, - canUseTranslate3d: boolean, pixelRatio: number, minimumHeight: number, maximumHeight: number, + pixelRatio: number, minimumHeight: number, maximumHeight: number, getVerticalOffsetForLine: (lineNumber: number) => number ) { this._canvasLeftOffset = canvasLeftOffset; @@ -31,10 +30,10 @@ export class OverviewRulerImpl { this._domNode.setClassName(cssClassName); this._domNode.setPosition('absolute'); + this._domNode.setLayerHinting(true); this._lanesCount = 3; - this._canUseTranslate3d = canUseTranslate3d; this._background = null; this._zoneManager = new OverviewZoneManager(getVerticalOffsetForLine); @@ -127,13 +126,6 @@ export class OverviewRulerImpl { } } - public setCanUseTranslate3d(canUseTranslate3d: boolean, render: boolean): void { - this._canUseTranslate3d = canUseTranslate3d; - if (render) { - this.render(true); - } - } - public setPixelRatio(pixelRatio: number, render: boolean): void { this._zoneManager.setPixelRatio(pixelRatio); this._domNode.setWidth(this._zoneManager.getDOMWidth()); @@ -156,11 +148,6 @@ export class OverviewRulerImpl { if (this._zoneManager.getOuterHeight() === 0) { return false; } - if (this._canUseTranslate3d) { - this._domNode.setTransform('translate3d(0px, 0px, 0px)'); - } else { - this._domNode.setTransform(''); - } const width = this._zoneManager.getCanvasWidth(); const height = this._zoneManager.getCanvasHeight(); diff --git a/src/vs/editor/browser/viewParts/rulers/rulers.css b/src/vs/editor/browser/viewParts/rulers/rulers.css index 3012d205f67..d3d2d26ec95 100644 --- a/src/vs/editor/browser/viewParts/rulers/rulers.css +++ b/src/vs/editor/browser/viewParts/rulers/rulers.css @@ -5,6 +5,5 @@ .monaco-editor .view-ruler { position: absolute; - width: 1px; top: 0; } \ No newline at end of file diff --git a/src/vs/editor/browser/viewParts/rulers/rulers.ts b/src/vs/editor/browser/viewParts/rulers/rulers.ts index 852eb07fb2c..6a5e95b0b8c 100644 --- a/src/vs/editor/browser/viewParts/rulers/rulers.ts +++ b/src/vs/editor/browser/viewParts/rulers/rulers.ts @@ -13,6 +13,7 @@ import { RenderingContext, RestrictedRenderingContext } from 'vs/editor/common/v import * as viewEvents from 'vs/editor/common/view/viewEvents'; import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; import { editorRuler } from 'vs/editor/common/view/editorColorRegistry'; +import * as dom from 'vs/base/browser/dom'; export class Rulers extends ViewPart { @@ -69,11 +70,12 @@ export class Rulers extends ViewPart { } if (currentCount < desiredCount) { - // Add more rulers + const rulerWidth = dom.computeScreenAwareSize(1); let addCount = desiredCount - currentCount; while (addCount > 0) { let node = createFastDomNode(document.createElement('div')); node.setClassName('view-ruler'); + node.setWidth(rulerWidth); this.domNode.appendChild(node); this._renderedRulers.push(node); addCount--; diff --git a/src/vs/editor/browser/viewParts/viewCursors/viewCursor.ts b/src/vs/editor/browser/viewParts/viewCursors/viewCursor.ts index babe35b4178..5288f92d7ea 100644 --- a/src/vs/editor/browser/viewParts/viewCursors/viewCursor.ts +++ b/src/vs/editor/browser/viewParts/viewCursors/viewCursor.ts @@ -12,6 +12,7 @@ import { Configuration } from 'vs/editor/browser/config/configuration'; import { ViewContext } from 'vs/editor/common/view/viewContext'; import { RenderingContext, RestrictedRenderingContext } from 'vs/editor/common/view/renderingContext'; import * as viewEvents from 'vs/editor/common/view/viewEvents'; +import * as dom from 'vs/base/browser/dom'; export interface IViewCursorRenderData { domNode: HTMLElement; @@ -137,9 +138,9 @@ export class ViewCursor { } let width: number; if (this._cursorStyle === TextEditorCursorStyle.Line) { - width = 2; + width = dom.computeScreenAwareSize(2); } else { - width = 1; + width = dom.computeScreenAwareSize(1); } const top = ctx.getVerticalOffsetForLineNumber(this._position.lineNumber) - ctx.bigNumbersDelta; return new ViewCursorRenderData(top, visibleRange.left, width, ''); diff --git a/src/vs/editor/common/config/commonEditorConfig.ts b/src/vs/editor/common/config/commonEditorConfig.ts index 553a1722299..9dc377162fd 100644 --- a/src/vs/editor/common/config/commonEditorConfig.ts +++ b/src/vs/editor/common/config/commonEditorConfig.ts @@ -55,7 +55,6 @@ export interface IEnvConfiguration { extraEditorClassName: string; outerWidth: number; outerHeight: number; - canUseTranslate3d: boolean; emptySelectionClipboard: boolean; pixelRatio: number; zoomLevel: number; @@ -125,7 +124,6 @@ export abstract class CommonEditorConfiguration extends Disposable implements ed extraEditorClassName: partialEnv.extraEditorClassName, isDominatedByLongLines: this._isDominatedByLongLines, lineNumbersDigitCount: this._lineNumbersDigitCount, - canUseTranslate3d: partialEnv.canUseTranslate3d, emptySelectionClipboard: partialEnv.emptySelectionClipboard, pixelRatio: partialEnv.pixelRatio, tabFocusMode: TabFocus.getTabFocusMode(), diff --git a/src/vs/editor/common/config/editorOptions.ts b/src/vs/editor/common/config/editorOptions.ts index 82e3f1994b6..9835b48bc22 100644 --- a/src/vs/editor/common/config/editorOptions.ts +++ b/src/vs/editor/common/config/editorOptions.ts @@ -246,10 +246,11 @@ export interface IEditorOptions { */ fontLigatures?: boolean; /** - * Disable the use of `translate3d`. + * Disable the use of `will-change` for the editor margin and lines layers. + * The usage of `will-change` acts as a hint for browsers to create an extra layer. * Defaults to false. */ - disableTranslate3d?: boolean; + disableLayerHinting?: boolean; /** * Disable the optimizations for monospace fonts. * Defaults to false. @@ -792,7 +793,7 @@ export interface IValidatedEditorOptions { readonly lineDecorationsWidth: number | string; readonly readOnly: boolean; readonly mouseStyle: 'text' | 'default' | 'copy'; - readonly disableTranslate3d: boolean; + readonly disableLayerHinting: boolean; readonly automaticLayout: boolean; readonly wordWrap: 'off' | 'on' | 'wordWrapColumn' | 'bounded'; readonly wordWrapColumn: number; @@ -818,7 +819,7 @@ export interface IValidatedEditorOptions { export class InternalEditorOptions { readonly _internalEditorOptionsBrand: void; - readonly canUseTranslate3d: boolean; + readonly canUseLayerHinting: boolean; readonly pixelRatio: number; readonly editorClassName: string; readonly lineHeight: number; @@ -848,7 +849,7 @@ export class InternalEditorOptions { * @internal */ constructor(source: { - canUseTranslate3d: boolean; + canUseLayerHinting: boolean; pixelRatio: number; editorClassName: string; lineHeight: number; @@ -867,7 +868,7 @@ export class InternalEditorOptions { wrappingInfo: EditorWrappingInfo; contribInfo: EditorContribOptions; }) { - this.canUseTranslate3d = source.canUseTranslate3d; + this.canUseLayerHinting = source.canUseLayerHinting; this.pixelRatio = source.pixelRatio; this.editorClassName = source.editorClassName; this.lineHeight = source.lineHeight | 0; @@ -892,7 +893,7 @@ export class InternalEditorOptions { */ public equals(other: InternalEditorOptions): boolean { return ( - this.canUseTranslate3d === other.canUseTranslate3d + this.canUseLayerHinting === other.canUseLayerHinting && this.pixelRatio === other.pixelRatio && this.editorClassName === other.editorClassName && this.lineHeight === other.lineHeight @@ -918,7 +919,7 @@ export class InternalEditorOptions { */ public createChangeEvent(newOpts: InternalEditorOptions): IConfigurationChangedEvent { return { - canUseTranslate3d: (this.canUseTranslate3d !== newOpts.canUseTranslate3d), + canUseLayerHinting: (this.canUseLayerHinting !== newOpts.canUseLayerHinting), pixelRatio: (this.pixelRatio !== newOpts.pixelRatio), editorClassName: (this.editorClassName !== newOpts.editorClassName), lineHeight: (this.lineHeight !== newOpts.lineHeight), @@ -1258,7 +1259,7 @@ export interface EditorLayoutInfo { * An event describing that the configuration of the editor has changed. */ export interface IConfigurationChangedEvent { - readonly canUseTranslate3d: boolean; + readonly canUseLayerHinting: boolean; readonly pixelRatio: boolean; readonly editorClassName: boolean; readonly lineHeight: boolean; @@ -1288,7 +1289,6 @@ export interface IEnvironmentalOptions { readonly extraEditorClassName: string; readonly isDominatedByLongLines: boolean; readonly lineNumbersDigitCount: number; - readonly canUseTranslate3d: boolean; readonly emptySelectionClipboard: boolean; readonly pixelRatio: number; readonly tabFocusMode: boolean; @@ -1435,7 +1435,7 @@ export class EditorOptionsValidator { lineDecorationsWidth: (typeof opts.lineDecorationsWidth === 'undefined' ? defaults.lineDecorationsWidth : opts.lineDecorationsWidth), readOnly: _boolean(opts.readOnly, defaults.readOnly), mouseStyle: _stringSet<'text' | 'default' | 'copy'>(opts.mouseStyle, defaults.mouseStyle, ['text', 'default', 'copy']), - disableTranslate3d: _boolean(opts.disableTranslate3d, defaults.disableTranslate3d), + disableLayerHinting: _boolean(opts.disableLayerHinting, defaults.disableLayerHinting), automaticLayout: _boolean(opts.automaticLayout, defaults.automaticLayout), wordWrap: wordWrap, wordWrapColumn: _clampedInt(opts.wordWrapColumn, defaults.wordWrapColumn, 1, Constants.MAX_SAFE_SMALL_INTEGER), @@ -1660,7 +1660,7 @@ export class InternalEditorOptionsFactory { lineDecorationsWidth: opts.lineDecorationsWidth, readOnly: opts.readOnly, mouseStyle: opts.mouseStyle, - disableTranslate3d: opts.disableTranslate3d, + disableLayerHinting: opts.disableLayerHinting, automaticLayout: opts.automaticLayout, wordWrap: opts.wordWrap, wordWrapColumn: opts.wordWrapColumn, @@ -1867,7 +1867,7 @@ export class InternalEditorOptionsFactory { } return new InternalEditorOptions({ - canUseTranslate3d: opts.disableTranslate3d ? false : env.canUseTranslate3d, + canUseLayerHinting: opts.disableLayerHinting ? false : true, pixelRatio: env.pixelRatio, editorClassName: className, lineHeight: env.fontInfo.lineHeight, @@ -2079,7 +2079,7 @@ export const EDITOR_DEFAULTS: IValidatedEditorOptions = { lineDecorationsWidth: 10, readOnly: false, mouseStyle: 'text', - disableTranslate3d: false, + disableLayerHinting: false, automaticLayout: false, wordWrap: 'off', wordWrapColumn: 80, diff --git a/src/vs/editor/common/controller/cursorTypeOperations.ts b/src/vs/editor/common/controller/cursorTypeOperations.ts index 6abac0a543e..7793fe670ce 100644 --- a/src/vs/editor/common/controller/cursorTypeOperations.ts +++ b/src/vs/editor/common/controller/cursorTypeOperations.ts @@ -239,7 +239,7 @@ export class TypeOperations { const selection = selections[i]; if (!selection.isEmpty()) { // looks like https://github.com/Microsoft/vscode/issues/2773 - // where a cursor operation occured before a canceled composition + // where a cursor operation occurred before a canceled composition // => ignore composition commands[i] = null; continue; diff --git a/src/vs/editor/common/view/viewEvents.ts b/src/vs/editor/common/view/viewEvents.ts index 72fc6b41fbe..b4a6e4bbf28 100644 --- a/src/vs/editor/common/view/viewEvents.ts +++ b/src/vs/editor/common/view/viewEvents.ts @@ -33,7 +33,7 @@ export class ViewConfigurationChangedEvent { public readonly type = ViewEventType.ViewConfigurationChanged; - public readonly canUseTranslate3d: boolean; + public readonly canUseLayerHinting: boolean; public readonly pixelRatio: boolean; public readonly editorClassName: boolean; public readonly lineHeight: boolean; @@ -46,7 +46,7 @@ export class ViewConfigurationChangedEvent { public readonly wrappingInfo: boolean; constructor(source: IConfigurationChangedEvent) { - this.canUseTranslate3d = source.canUseTranslate3d; + this.canUseLayerHinting = source.canUseLayerHinting; this.pixelRatio = source.pixelRatio; this.editorClassName = source.editorClassName; this.lineHeight = source.lineHeight; diff --git a/src/vs/editor/contrib/find/common/findController.ts b/src/vs/editor/contrib/find/common/findController.ts index a5dae70a8dc..b1195ab30f4 100644 --- a/src/vs/editor/contrib/find/common/findController.ts +++ b/src/vs/editor/contrib/find/common/findController.ts @@ -862,7 +862,7 @@ export class SelectHighlightsAction extends AbstractSelectHighlightsAction { constructor() { super({ id: 'editor.action.selectHighlights', - label: nls.localize('selectAllOccurencesOfFindMatch', "Select All Occurrences of Find Match"), + label: nls.localize('selectAllOccurrencesOfFindMatch', "Select All Occurrences of Find Match"), alias: 'Select All Occurrences of Find Match', precondition: null, kbOpts: { @@ -1005,10 +1005,10 @@ export class SelectionHighlighter extends Disposable implements editorCommon.IEd return null; } - const hasFindOccurences = DocumentHighlightProviderRegistry.has(model); + const hasFindOccurrences = DocumentHighlightProviderRegistry.has(model); if (r.currentMatch) { // This is an empty selection - if (hasFindOccurences) { + if (hasFindOccurrences) { // Do not interfere with semantic word highlighting in the no selection case return null; } @@ -1070,7 +1070,7 @@ export class SelectionHighlighter extends Disposable implements editorCommon.IEd } const model = this.editor.getModel(); - const hasFindOccurences = DocumentHighlightProviderRegistry.has(model); + const hasFindOccurrences = DocumentHighlightProviderRegistry.has(model); let allMatches = model.findMatches(this.state.searchText, true, false, this.state.matchCase, this.state.wordSeparators, false).map(m => m.range); allMatches.sort(Range.compareRangesUsingStarts); @@ -1108,7 +1108,7 @@ export class SelectionHighlighter extends Disposable implements editorCommon.IEd return { range: r, // Show in overviewRuler only if model has no semantic highlighting - options: (hasFindOccurences ? SelectionHighlighter._SELECTION_HIGHLIGHT : SelectionHighlighter._SELECTION_HIGHLIGHT_OVERVIEW) + options: (hasFindOccurrences ? SelectionHighlighter._SELECTION_HIGHLIGHT : SelectionHighlighter._SELECTION_HIGHLIGHT_OVERVIEW) }; }); diff --git a/src/vs/editor/contrib/find/test/common/findController.test.ts b/src/vs/editor/contrib/find/test/common/findController.test.ts index aa2fb4de23d..20559f5713b 100644 --- a/src/vs/editor/contrib/find/test/common/findController.test.ts +++ b/src/vs/editor/contrib/find/test/common/findController.test.ts @@ -215,7 +215,7 @@ suite('FindController', () => { }); }); - test('issue #5400: "Select All Occurences of Find Match" does not select all if find uses regex', () => { + test('issue #5400: "Select All Occurrences of Find Match" does not select all if find uses regex', () => { withMockCodeEditor([ 'something', 'someething', diff --git a/src/vs/editor/contrib/hover/browser/hoverWidgets.ts b/src/vs/editor/contrib/hover/browser/hoverWidgets.ts index bc42fb4935a..eacdbf64f4e 100644 --- a/src/vs/editor/contrib/hover/browser/hoverWidgets.ts +++ b/src/vs/editor/contrib/hover/browser/hoverWidgets.ts @@ -51,7 +51,7 @@ export class ContentHoverWidget extends Widget implements editorBrowser.IContent this._domNode = document.createElement('div'); this._domNode.className = 'monaco-editor-hover-content'; - this.scrollbar = new DomScrollableElement(this._domNode, { canUseTranslate3d: false }); + this.scrollbar = new DomScrollableElement(this._domNode, {}); this.disposables.push(this.scrollbar); this._containerDomNode.appendChild(this.scrollbar.getDomNode()); diff --git a/src/vs/editor/contrib/links/browser/links.ts b/src/vs/editor/contrib/links/browser/links.ts index 7b566b860be..e3ab8e404c8 100644 --- a/src/vs/editor/contrib/links/browser/links.ts +++ b/src/vs/editor/contrib/links/browser/links.ts @@ -58,7 +58,7 @@ const decoration = { }), }; -class LinkOccurence { +class LinkOccurrence { public static decoration(link: Link, useMetaKey: boolean): editorCommon.IModelDeltaDecoration { return { @@ -68,7 +68,7 @@ class LinkOccurence { endLineNumber: link.range.endLineNumber, endColumn: link.range.endColumn }, - options: LinkOccurence._getOptions(useMetaKey, false) + options: LinkOccurrence._getOptions(useMetaKey, false) }; } @@ -88,11 +88,11 @@ class LinkOccurence { } public activate(changeAccessor: editorCommon.IModelDecorationsChangeAccessor, useMetaKey: boolean): void { - changeAccessor.changeDecorationOptions(this.decorationId, LinkOccurence._getOptions(useMetaKey, true)); + changeAccessor.changeDecorationOptions(this.decorationId, LinkOccurrence._getOptions(useMetaKey, true)); } public deactivate(changeAccessor: editorCommon.IModelDecorationsChangeAccessor, useMetaKey: boolean): void { - changeAccessor.changeDecorationOptions(this.decorationId, LinkOccurence._getOptions(useMetaKey, false)); + changeAccessor.changeDecorationOptions(this.decorationId, LinkOccurrence._getOptions(useMetaKey, false)); } } @@ -116,7 +116,7 @@ class LinkDetector implements editorCommon.IEditorContribution { private openerService: IOpenerService; private messageService: IMessageService; private editorWorkerService: IEditorWorkerService; - private currentOccurences: { [decorationId: string]: LinkOccurence; }; + private currentOccurrences: { [decorationId: string]: LinkOccurrence; }; constructor( editor: ICodeEditor, @@ -167,7 +167,7 @@ class LinkDetector implements editorCommon.IEditorContribution { this.timeoutPromise = null; this.computePromise = null; - this.currentOccurences = {}; + this.currentOccurrences = {}; this.activeLinkDecorationId = null; this.beginCompute(); } @@ -181,7 +181,7 @@ class LinkDetector implements editorCommon.IEditorContribution { } private onModelChanged(): void { - this.currentOccurences = {}; + this.currentOccurrences = {}; this.activeLinkDecorationId = null; this.stop(); this.beginCompute(); @@ -221,10 +221,10 @@ class LinkDetector implements editorCommon.IEditorContribution { const useMetaKey = (this.editor.getConfiguration().multiCursorModifier === 'altKey'); this.editor.changeDecorations((changeAccessor: editorCommon.IModelDecorationsChangeAccessor) => { var oldDecorations: string[] = []; - let keys = Object.keys(this.currentOccurences); + let keys = Object.keys(this.currentOccurrences); for (let i = 0, len = keys.length; i < len; i++) { let decorationId = keys[i]; - let occurance = this.currentOccurences[decorationId]; + let occurance = this.currentOccurrences[decorationId]; oldDecorations.push(occurance.decorationId); } @@ -232,17 +232,17 @@ class LinkDetector implements editorCommon.IEditorContribution { if (links) { // Not sure why this is sometimes null for (var i = 0; i < links.length; i++) { - newDecorations.push(LinkOccurence.decoration(links[i], useMetaKey)); + newDecorations.push(LinkOccurrence.decoration(links[i], useMetaKey)); } } var decorations = changeAccessor.deltaDecorations(oldDecorations, newDecorations); - this.currentOccurences = {}; + this.currentOccurrences = {}; this.activeLinkDecorationId = null; for (let i = 0, len = decorations.length; i < len; i++) { - var occurance = new LinkOccurence(links[i], decorations[i]); - this.currentOccurences[occurance.decorationId] = occurance; + var occurance = new LinkOccurrence(links[i], decorations[i]); + this.currentOccurrences[occurance.decorationId] = occurance; } }); } @@ -251,11 +251,11 @@ class LinkDetector implements editorCommon.IEditorContribution { const useMetaKey = (this.editor.getConfiguration().multiCursorModifier === 'altKey'); if (this.isEnabled(mouseEvent, withKey)) { this.cleanUpActiveLinkDecoration(); // always remove previous link decoration as their can only be one - var occurence = this.getLinkOccurence(mouseEvent.target.position); - if (occurence) { + var occurrence = this.getLinkOccurrence(mouseEvent.target.position); + if (occurrence) { this.editor.changeDecorations((changeAccessor) => { - occurence.activate(changeAccessor, useMetaKey); - this.activeLinkDecorationId = occurence.decorationId; + occurrence.activate(changeAccessor, useMetaKey); + this.activeLinkDecorationId = occurrence.decorationId; }); } } else { @@ -266,10 +266,10 @@ class LinkDetector implements editorCommon.IEditorContribution { private cleanUpActiveLinkDecoration(): void { const useMetaKey = (this.editor.getConfiguration().multiCursorModifier === 'altKey'); if (this.activeLinkDecorationId) { - var occurence = this.currentOccurences[this.activeLinkDecorationId]; - if (occurence) { + var occurrence = this.currentOccurrences[this.activeLinkDecorationId]; + if (occurrence) { this.editor.changeDecorations((changeAccessor) => { - occurence.deactivate(changeAccessor, useMetaKey); + occurrence.deactivate(changeAccessor, useMetaKey); }); } @@ -281,20 +281,20 @@ class LinkDetector implements editorCommon.IEditorContribution { if (!this.isEnabled(mouseEvent)) { return; } - var occurence = this.getLinkOccurence(mouseEvent.target.position); - if (!occurence) { + var occurrence = this.getLinkOccurrence(mouseEvent.target.position); + if (!occurrence) { return; } - this.openLinkOccurence(occurence, mouseEvent.hasSideBySideModifier); + this.openLinkOccurrence(occurrence, mouseEvent.hasSideBySideModifier); } - public openLinkOccurence(occurence: LinkOccurence, openToSide: boolean): void { + public openLinkOccurrence(occurrence: LinkOccurrence, openToSide: boolean): void { if (!this.openerService) { return; } - const { link } = occurence; + const { link } = occurrence; link.resolve().then(uri => { // open the uri @@ -312,7 +312,7 @@ class LinkDetector implements editorCommon.IEditorContribution { }).done(null, onUnexpectedError); } - public getLinkOccurence(position: Position): LinkOccurence { + public getLinkOccurrence(position: Position): LinkOccurrence { var decorations = this.editor.getModel().getDecorationsInRange({ startLineNumber: position.lineNumber, startColumn: position.column, @@ -322,9 +322,9 @@ class LinkDetector implements editorCommon.IEditorContribution { for (var i = 0; i < decorations.length; i++) { var decoration = decorations[i]; - var currentOccurence = this.currentOccurences[decoration.id]; - if (currentOccurence) { - return currentOccurence; + var currentOccurrence = this.currentOccurrences[decoration.id]; + if (currentOccurrence) { + return currentOccurrence; } } @@ -373,9 +373,9 @@ class OpenLinkAction extends EditorAction { return; } - let link = linkDetector.getLinkOccurence(editor.getPosition()); + let link = linkDetector.getLinkOccurrence(editor.getPosition()); if (link) { - linkDetector.openLinkOccurence(link, false); + linkDetector.openLinkOccurrence(link, false); } } } diff --git a/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.ts b/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.ts index a9fec25edf6..7c4e88e035e 100644 --- a/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.ts +++ b/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.ts @@ -221,7 +221,7 @@ export class ParameterHintsWidget implements IContentWidget, IDisposable { this.overloads = dom.append(wrapper, $('.overloads')); const body = $('.body'); - this.scrollbar = new DomScrollableElement(body, { canUseTranslate3d: false }); + this.scrollbar = new DomScrollableElement(body, {}); this.disposables.push(this.scrollbar); wrapper.appendChild(this.scrollbar.getDomNode()); diff --git a/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.ts b/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.ts index 6249277425f..805cdb2bddc 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.ts +++ b/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.ts @@ -5,7 +5,6 @@ 'use strict'; import * as nls from 'vs/nls'; -import { alert } from 'vs/base/browser/ui/aria/aria'; import { KeyCode, KeyMod } from 'vs/base/common/keyCodes'; import URI from 'vs/base/common/uri'; import { TPromise } from 'vs/base/common/winjs.base'; @@ -85,11 +84,7 @@ export class ReferenceAction extends EditorAction { } let range = editor.getSelection(); let model = editor.getModel(); - let references = provideReferences(model, range.getStartPosition()).then(references => { - const model = new ReferencesModel(references); - alert(model.getAriaMessage()); - return model; - }); + let references = provideReferences(model, range.getStartPosition()).then(references => new ReferencesModel(references)); controller.toggleWidget(range, references, defaultReferenceSearchOptions); } } diff --git a/src/vs/editor/contrib/referenceSearch/browser/referencesModel.ts b/src/vs/editor/contrib/referenceSearch/browser/referencesModel.ts index 4ddacbe9216..06821595584 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referencesModel.ts +++ b/src/vs/editor/contrib/referenceSearch/browser/referencesModel.ts @@ -66,7 +66,7 @@ export class OneReference { public getAriaMessage(): string { return localize( 'aria.oneReference', "symbol in {0} on line {1} at column {2}", - this.uri.fsPath, this.range.startLineNumber, this.range.startColumn + basename(this.uri.fsPath), this.range.startLineNumber, this.range.startColumn ); } } @@ -154,9 +154,9 @@ export class FileReferences implements IDisposable { getAriaMessage(): string { const len = this.children.length; if (len === 1) { - return localize('aria.fileReferences.1', "1 symbol in {0}", this.uri.fsPath); + return localize('aria.fileReferences.1', "1 symbol in {0}, full path {1}", basename(this.uri.fsPath), this.uri.fsPath); } else { - return localize('aria.fileReferences.N', "{0} symbols in {1}", len, this.uri.fsPath); + return localize('aria.fileReferences.N', "{0} symbols in {1}, full path {2}", len, basename(this.uri.fsPath), this.uri.fsPath); } } diff --git a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts index a0603d8f948..955ce894d60 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts +++ b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts @@ -6,7 +6,6 @@ import 'vs/css!./referencesWidget'; import * as nls from 'vs/nls'; -import { alert } from 'vs/base/browser/ui/aria/aria'; import { onUnexpectedError } from 'vs/base/common/errors'; import { getPathLabel } from 'vs/base/common/labels'; import Event, { Emitter } from 'vs/base/common/event'; @@ -589,7 +588,7 @@ export class ReferenceWidget extends PeekViewWidget { private _instantiationService: IInstantiationService, private _environmentService: IEnvironmentService ) { - super(editor, { showFrame: false, showArrow: true, isResizeable: true }); + super(editor, { showFrame: false, showArrow: true, isResizeable: true, isAccessible: true }); this._applyTheme(_themeService.getTheme()); this._callOnDispose.push(_themeService.onThemeChange(this._applyTheme.bind(this))); @@ -690,8 +689,7 @@ export class ReferenceWidget extends PeekViewWidget { dataSource: this._instantiationService.createInstance(DataSource), renderer: this._instantiationService.createInstance(Renderer, this.editor), controller: new Controller(), - // TODO@{Joh,Ben} make this work with the embedded tree - // accessibilityProvider: new AriaProvider() + accessibilityProvider: new AriaProvider() }; var options = { @@ -763,17 +761,6 @@ export class ReferenceWidget extends PeekViewWidget { // listen on model changes this._disposeOnNewModel.push(this._model.onDidChangeReferenceRange(reference => this._tree.refresh(reference))); - // listen on selection and focus - this._disposeOnNewModel.push(this._tree.addListener(Controller.Events.FOCUSED, (element) => { - if (element instanceof OneReference) { - this._revealReference(element); - this._onDidSelectReference.fire({ element, kind: 'show', source: 'tree' }); - } - if (element instanceof OneReference || element instanceof FileReferences) { - const msg = element.getAriaMessage(); - alert(msg); - } - })); this._disposeOnNewModel.push(this._tree.addListener(Controller.Events.SELECTED, (element: any) => { if (element instanceof OneReference) { this._onDidSelectReference.fire({ element, kind: 'goto', source: 'tree' }); diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index a3154f2a23d..5ab85e8bf03 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -213,7 +213,7 @@ class SuggestionDetails { this.body = $('.body'); - this.scrollbar = new DomScrollableElement(this.body, { canUseTranslate3d: false }); + this.scrollbar = new DomScrollableElement(this.body, {}); append(this.el, this.scrollbar.getDomNode()); this.disposables.push(this.scrollbar); diff --git a/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.ts b/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.ts index 0aa87cb7282..52b6d50d151 100644 --- a/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.ts +++ b/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.ts @@ -188,8 +188,8 @@ class WordHighlighter { } // All the effort below is trying to achieve this: - // - when cursor is moved to a word, trigger immediately a findOccurences request - // - 250ms later after the last cursor move event, render the occurences + // - when cursor is moved to a word, trigger immediately a findOccurrences request + // - 250ms later after the last cursor move event, render the occurrences // - no flickering! var currentWordRange = new Range(lineNumber, word.startColumn, lineNumber, word.endColumn); diff --git a/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.ts b/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.ts index 97a76078bba..45e8d7a3e56 100644 --- a/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.ts +++ b/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.ts @@ -169,6 +169,7 @@ export abstract class PeekViewWidget extends ZoneWidget implements IPeekViewServ public setTitle(primaryHeading: string, secondaryHeading?: string): void { $(this._primaryHeading).safeInnerHtml(primaryHeading); + this._primaryHeading.setAttribute('aria-label', primaryHeading); if (secondaryHeading) { $(this._secondaryHeading).safeInnerHtml(secondaryHeading); } else { @@ -212,4 +213,4 @@ export abstract class PeekViewWidget extends ZoneWidget implements IPeekViewServ protected _doLayoutBody(heightInPixel: number, widthInPixel: number): void { this._bodyElement.style.height = strings.format('{0}px', heightInPixel); } -} \ No newline at end of file +} diff --git a/src/vs/editor/test/browser/services/decorationRenderOptions.test.ts b/src/vs/editor/test/browser/services/decorationRenderOptions.test.ts index d68266803a7..00132c93923 100644 --- a/src/vs/editor/test/browser/services/decorationRenderOptions.test.ts +++ b/src/vs/editor/test/browser/services/decorationRenderOptions.test.ts @@ -67,7 +67,7 @@ suite('Decoration Render Options', () => { var s = new CodeEditorServiceImpl(themeService, styleSheet); s.registerDecorationType('example', options); var sheet = readStyleSheet(styleSheet); - assert.equal(sheet, '.monaco-editor .ced-example-0 { background-color: rgb(255, 0, 0); }'); + assert.equal(sheet, '.monaco-editor .ced-example-0 { background-color: rgb(255, 0, 0); border-color: transparent; box-sizing: border-box; }'); colors = { editorBackground: '#EE0000', diff --git a/src/vs/editor/test/common/config/commonEditorConfig.test.ts b/src/vs/editor/test/common/config/commonEditorConfig.test.ts index 2e2f47b16aa..4d5da6aec32 100644 --- a/src/vs/editor/test/common/config/commonEditorConfig.test.ts +++ b/src/vs/editor/test/common/config/commonEditorConfig.test.ts @@ -59,7 +59,6 @@ suite('Common Editor Config', () => { extraEditorClassName: '', outerWidth: 1000, outerHeight: 100, - canUseTranslate3d: true, emptySelectionClipboard: true, pixelRatio: 1, zoomLevel: 0, diff --git a/src/vs/editor/test/common/mocks/testConfiguration.ts b/src/vs/editor/test/common/mocks/testConfiguration.ts index a8778a6f055..b94830a8456 100644 --- a/src/vs/editor/test/common/mocks/testConfiguration.ts +++ b/src/vs/editor/test/common/mocks/testConfiguration.ts @@ -21,7 +21,6 @@ export class TestConfiguration extends CommonEditorConfiguration { extraEditorClassName: '', outerWidth: 100, outerHeight: 100, - canUseTranslate3d: true, emptySelectionClipboard: true, pixelRatio: 1, zoomLevel: 0, diff --git a/src/vs/monaco.d.ts b/src/vs/monaco.d.ts index 0b34c6869aa..5dddf0d0f3d 100644 --- a/src/vs/monaco.d.ts +++ b/src/vs/monaco.d.ts @@ -2793,10 +2793,11 @@ declare module monaco.editor { */ fontLigatures?: boolean; /** - * Disable the use of `translate3d`. + * Disable the use of `will-change` for the editor margin and lines layers. + * The usage of `will-change` acts as a hint for browsers to create an extra layer. * Defaults to false. */ - disableTranslate3d?: boolean; + disableLayerHinting?: boolean; /** * Disable the optimizations for monospace fonts. * Defaults to false. @@ -3275,7 +3276,7 @@ declare module monaco.editor { */ export class InternalEditorOptions { readonly _internalEditorOptionsBrand: void; - readonly canUseTranslate3d: boolean; + readonly canUseLayerHinting: boolean; readonly pixelRatio: number; readonly editorClassName: string; readonly lineHeight: number; @@ -3406,7 +3407,7 @@ declare module monaco.editor { * An event describing that the configuration of the editor has changed. */ export interface IConfigurationChangedEvent { - readonly canUseTranslate3d: boolean; + readonly canUseLayerHinting: boolean; readonly pixelRatio: boolean; readonly editorClassName: boolean; readonly lineHeight: boolean; @@ -3960,7 +3961,7 @@ declare module monaco.languages { export function registerDocumentSymbolProvider(languageId: string, provider: DocumentSymbolProvider): IDisposable; /** - * Register a document highlight provider (used by e.g. highlight occurences). + * Register a document highlight provider (used by e.g. highlight occurrences). */ export function registerDocumentHighlightProvider(languageId: string, provider: DocumentHighlightProvider): IDisposable; diff --git a/src/vs/platform/configuration/common/configuration.ts b/src/vs/platform/configuration/common/configuration.ts index 7292988c11b..0aec692a2d8 100644 --- a/src/vs/platform/configuration/common/configuration.ts +++ b/src/vs/platform/configuration/common/configuration.ts @@ -4,6 +4,9 @@ *--------------------------------------------------------------------------------------------*/ import { TPromise } from 'vs/base/common/winjs.base'; +import * as arrays from 'vs/base/common/arrays'; +import * as types from 'vs/base/common/types'; +import * as objects from 'vs/base/common/objects'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; import Event from 'vs/base/common/event'; @@ -101,18 +104,76 @@ export function getConfigurationValue(config: any, settingPath: string, defau return typeof result === 'undefined' ? defaultValue : result; } -export interface IConfigModel { - contents: T; - overrides: IOverrides[]; - keys: string[]; - errors: any[]; - - merge(other: IConfigModel, overwrite?: boolean): IConfigModel; - getContentsFor(section: string): V; - configWithOverrides(identifier: string, section?: string): IConfigModel; +export function merge(base: any, add: any, overwrite: boolean): void { + Object.keys(add).forEach(key => { + if (key in base) { + if (types.isObject(base[key]) && types.isObject(add[key])) { + merge(base[key], add[key], overwrite); + } else if (overwrite) { + base[key] = add[key]; + } + } else { + base[key] = add[key]; + } + }); } export interface IOverrides { contents: T; identifiers: string[]; } + +export class Configuration { + + protected _keys: string[] = []; + + constructor(protected _contents: T = {}, protected _overrides: IOverrides[] = []) { + } + + public get contents(): T { + return this._contents; + } + + public get keys(): string[] { + return this._keys; + } + + public getContentsFor(section: string): V { + return objects.clone(this.contents[section]); + } + + public override(identifier: string): Configuration { + const result = new Configuration(); + const contents = objects.clone(this.contents); + if (this._overrides) { + for (const override of this._overrides) { + if (override.identifiers.indexOf(identifier) !== -1) { + merge(contents, override.contents, true); + } + } + } + result._contents = contents; + return result; + } + + public merge(other: Configuration, overwrite: boolean = true): Configuration { + const mergedModel = new Configuration(); + this.doMerge(mergedModel, this, overwrite); + this.doMerge(mergedModel, other, overwrite); + return mergedModel; + } + + protected doMerge(source: Configuration, target: Configuration, overwrite: boolean = true) { + merge(source.contents, objects.clone(target.contents), overwrite); + const overrides = objects.clone(source._overrides); + for (const override of target._overrides) { + const [sourceOverride] = overrides.filter(o => arrays.equals(o.identifiers, override.identifiers)); + if (sourceOverride) { + merge(sourceOverride.contents, override.contents, overwrite); + } else { + overrides.push(override); + } + } + source._overrides = overrides; + } +} \ No newline at end of file diff --git a/src/vs/platform/configuration/common/model.ts b/src/vs/platform/configuration/common/model.ts index cfbc368d83a..bbc843ffa3a 100644 --- a/src/vs/platform/configuration/common/model.ts +++ b/src/vs/platform/configuration/common/model.ts @@ -5,12 +5,9 @@ 'use strict'; import { Registry } from 'vs/platform/platform'; -import * as types from 'vs/base/common/types'; import * as json from 'vs/base/common/json'; -import * as objects from 'vs/base/common/objects'; -import * as arrays from 'vs/base/common/arrays'; import { IConfigurationRegistry, Extensions, OVERRIDE_PROPERTY_PATTERN } from 'vs/platform/configuration/common/configurationRegistry'; -import { IConfigModel, IOverrides } from 'vs/platform/configuration/common/configuration'; +import { Configuration, IOverrides } from 'vs/platform/configuration/common/configuration'; export function getDefaultValues(): any { const valueTreeRoot: any = Object.create(null); @@ -68,92 +65,45 @@ export function getConfigurationKeys(): string[] { return Object.keys(properties); } -export function merge(base: any, add: any, overwrite: boolean): void { - Object.keys(add).forEach(key => { - if (key in base) { - if (types.isObject(base[key]) && types.isObject(add[key])) { - merge(base[key], add[key], overwrite); - } else if (overwrite) { - base[key] = add[key]; - } - } else { - base[key] = add[key]; - } - }); +export class DefaultConfiguration extends Configuration { + + constructor() { + super(getDefaultValues()); + this._keys = getConfigurationKeys(); + this._overrides = Object.keys(this._contents) + .filter(key => OVERRIDE_PROPERTY_PATTERN.test(key)) + .map(key => { + return >{ + identifiers: [overrideIdentifierFromKey(key).trim()], + contents: toValuesTree(this._contents[key], message => console.error(`Conflict in default settings file: ${message}`)) + }; + }); + } + + public get keys(): string[] { + return this._keys; + } } interface Overrides extends IOverrides { raw: any; } -export class ConfigModel implements IConfigModel { +export class CustomConfiguration extends Configuration { - protected _contents: T = {}; - protected _overrides: IOverrides[] = []; - protected _keys: string[] = []; protected _parseErrors: any[] = []; constructor(content: string = '', private name: string = '') { + super(); if (content) { this.update(content); } } - public get contents(): T { - return this._contents; - } - - public get overrides(): IOverrides[] { - return this._overrides; - } - - public get keys(): string[] { - return this._keys; - } - public get errors(): any[] { return this._parseErrors; } - public merge(other: IConfigModel, overwrite: boolean = true): ConfigModel { - const mergedModel = new ConfigModel(null); - this.doMerge(mergedModel, this, overwrite); - this.doMerge(mergedModel, other, overwrite); - return mergedModel; - } - - protected doMerge(source: ConfigModel, target: IConfigModel, overwrite: boolean = true) { - merge(source.contents, objects.clone(target.contents), overwrite); - const overrides = objects.clone(source.overrides); - for (const override of target.overrides) { - const [sourceOverride] = overrides.filter(o => arrays.equals(o.identifiers, override.identifiers)); - if (sourceOverride) { - merge(sourceOverride.contents, override.contents, overwrite); - } else { - overrides.push(override); - } - } - source._overrides = overrides; - } - - public getContentsFor(section: string): V { - return objects.clone(this.contents[section]); - } - - public configWithOverrides(identifier: string): ConfigModel { - const result = new ConfigModel(null); - const contents = objects.clone(this.contents); - if (this.overrides) { - for (const override of this.overrides) { - if (override.identifiers.indexOf(identifier) !== -1) { - merge(contents, override.contents, true); - } - } - } - result._contents = contents; - return result; - } - public update(content: string): void { let parsed: T = {}; let overrides: Overrides[] = []; @@ -243,31 +193,6 @@ export class ConfigModel implements IConfigModel { } } -export class DefaultConfigModel extends ConfigModel { - - constructor() { - super(null); - this.update(); - } - - public get keys(): string[] { - return this._keys; - } - - public update(): void { - this._contents = getDefaultValues(); // defaults coming from contributions to registries - this._keys = getConfigurationKeys(); - this._overrides = Object.keys(this._contents) - .filter(key => OVERRIDE_PROPERTY_PATTERN.test(key)) - .map(key => { - return >{ - identifiers: [overrideIdentifierFromKey(key).trim()], - contents: toValuesTree(this._contents[key], message => console.error(`Conflict in default settings file: ${message}`)) - }; - }); - } -} - export function overrideIdentifierFromKey(key: string): string { return key.substring(1, key.length - 1); } diff --git a/src/vs/platform/configuration/node/configurationService.ts b/src/vs/platform/configuration/node/configurationService.ts index ea7164b96a1..3f7a1e9c22c 100644 --- a/src/vs/platform/configuration/node/configurationService.ts +++ b/src/vs/platform/configuration/node/configurationService.ts @@ -10,15 +10,15 @@ import { ConfigWatcher } from 'vs/base/node/config'; import { Registry } from 'vs/platform/platform'; import { IConfigurationRegistry, Extensions } from 'vs/platform/configuration/common/configurationRegistry'; import { IDisposable, toDisposable, Disposable } from 'vs/base/common/lifecycle'; -import { ConfigurationSource, IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, getConfigurationValue, IConfigurationKeys, IConfigModel, IConfigurationOptions } from 'vs/platform/configuration/common/configuration'; -import { ConfigModel, DefaultConfigModel } from 'vs/platform/configuration/common/model'; +import { ConfigurationSource, IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, getConfigurationValue, IConfigurationKeys, Configuration, IConfigurationOptions } from 'vs/platform/configuration/common/configuration'; +import { CustomConfiguration, DefaultConfiguration } from 'vs/platform/configuration/common/model'; import Event, { Emitter } from 'vs/base/common/event'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; export interface ICache { - defaults: IConfigModel; - user: IConfigModel; - consolidated: IConfigModel; + defaults: Configuration; + user: Configuration; + consolidated: Configuration; } export class ConfigurationService extends Disposable implements IConfigurationService, IDisposable { @@ -26,7 +26,7 @@ export class ConfigurationService extends Disposable implements IConfiguratio _serviceBrand: any; private cache: ICache; - private userConfigModelWatcher: ConfigWatcher>; + private userConfigModelWatcher: ConfigWatcher>; private _onDidUpdateConfiguration: Emitter = this._register(new Emitter()); public readonly onDidUpdateConfiguration: Event = this._onDidUpdateConfiguration.event; @@ -37,8 +37,8 @@ export class ConfigurationService extends Disposable implements IConfiguratio super(); this.userConfigModelWatcher = new ConfigWatcher(environmentService.appSettingsPath, { - changeBufferDelay: 300, defaultConfig: new ConfigModel(null, environmentService.appSettingsPath), parse: (content: string, parseErrors: any[]) => { - const userConfigModel = new ConfigModel(content, environmentService.appSettingsPath); + changeBufferDelay: 300, defaultConfig: new CustomConfiguration(null, environmentService.appSettingsPath), parse: (content: string, parseErrors: any[]) => { + const userConfigModel = new CustomConfiguration(content, environmentService.appSettingsPath); parseErrors = [...userConfigModel.errors]; return userConfigModel; } @@ -77,7 +77,7 @@ export class ConfigurationService extends Disposable implements IConfiguratio public getConfiguration(arg?: any): C { const options = this.toOptions(arg); const cache = this.getCache(); - const configModel = options.overrideIdentifier ? cache.consolidated.configWithOverrides(options.overrideIdentifier) : cache.consolidated; + const configModel = options.overrideIdentifier ? cache.consolidated.override(options.overrideIdentifier) : cache.consolidated; return options.section ? configModel.getContentsFor(options.section) : configModel.contents; } @@ -86,9 +86,9 @@ export class ConfigurationService extends Disposable implements IConfiguratio // make sure to clone the configuration so that the receiver does not tamper with the values return { - default: objects.clone(getConfigurationValue(overrideIdentifier ? cache.defaults.configWithOverrides(overrideIdentifier).contents : cache.defaults.contents, key)), - user: objects.clone(getConfigurationValue(overrideIdentifier ? cache.user.configWithOverrides(overrideIdentifier).contents : cache.user.contents, key)), - value: objects.clone(getConfigurationValue(overrideIdentifier ? cache.consolidated.configWithOverrides(overrideIdentifier).contents : cache.consolidated.contents, key)) + default: objects.clone(getConfigurationValue(overrideIdentifier ? cache.defaults.override(overrideIdentifier).contents : cache.defaults.contents, key)), + user: objects.clone(getConfigurationValue(overrideIdentifier ? cache.user.override(overrideIdentifier).contents : cache.user.contents, key)), + value: objects.clone(getConfigurationValue(overrideIdentifier ? cache.consolidated.override(overrideIdentifier).contents : cache.consolidated.contents, key)) }; } @@ -116,7 +116,7 @@ export class ConfigurationService extends Disposable implements IConfiguratio } private consolidateConfigurations(): ICache { - const defaults = new DefaultConfigModel(); + const defaults = new DefaultConfiguration(); const user = this.userConfigModelWatcher.getConfig(); const consolidated = defaults.merge(user); return { defaults, user, consolidated }; diff --git a/src/vs/platform/configuration/test/common/configuration.test.ts b/src/vs/platform/configuration/test/common/configuration.test.ts new file mode 100644 index 00000000000..69552e758fb --- /dev/null +++ b/src/vs/platform/configuration/test/common/configuration.test.ts @@ -0,0 +1,79 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +'use strict'; + +import * as assert from 'assert'; +import { Configuration, merge } from 'vs/platform/configuration/common/configuration'; +import { Extensions, IConfigurationRegistry } from 'vs/platform/configuration/common/configurationRegistry'; +import { Registry } from 'vs/platform/platform'; + +suite('Configuration', () => { + + suiteSetup(() => { + Registry.as(Extensions.Configuration).registerConfiguration({ + 'id': 'a', + 'order': 1, + 'title': 'a', + 'type': 'object', + 'properties': { + 'a': { + 'description': 'a', + 'type': 'boolean', + 'default': true, + 'overridable': true + } + } + }); + }); + + test('simple merge', () => { + let base = { 'a': 1, 'b': 2 }; + merge(base, { 'a': 3, 'c': 4 }, true); + assert.deepEqual(base, { 'a': 3, 'b': 2, 'c': 4 }); + base = { 'a': 1, 'b': 2 }; + merge(base, { 'a': 3, 'c': 4 }, false); + assert.deepEqual(base, { 'a': 1, 'b': 2, 'c': 4 }); + }); + + test('Recursive merge', () => { + const base = { 'a': { 'b': 1 } }; + merge(base, { 'a': { 'b': 2 } }, true); + assert.deepEqual(base, { 'a': { 'b': 2 } }); + }); + + test('simple merge using configuration', () => { + let base = new Configuration({ 'a': 1, 'b': 2 }); + let add = new Configuration({ 'a': 3, 'c': 4 }); + let result = base.merge(add); + assert.deepEqual(result.contents, { 'a': 3, 'b': 2, 'c': 4 }); + }); + + test('Recursive merge using config models', () => { + let base = new Configuration({ 'a': { 'b': 1 } }); + let add = new Configuration({ 'a': { 'b': 2 } }); + let result = base.merge(add); + assert.deepEqual(result.contents, { 'a': { 'b': 2 } }); + }); + + test('Test contents while getting an existing property', () => { + let testObject = new Configuration({ 'a': 1 }); + assert.deepEqual(testObject.getContentsFor('a'), 1); + + testObject = new Configuration({ 'a': { 'b': 1 } }); + assert.deepEqual(testObject.getContentsFor('a'), { 'b': 1 }); + }); + + test('Test contents are undefined for non existing properties', () => { + const testObject = new Configuration({ awesome: true }); + + assert.deepEqual(testObject.getContentsFor('unknownproperty'), undefined); + }); + + test('Test override gives all content merged with overrides', () => { + const testObject = new Configuration({ 'a': 1, 'c': 1 }, [{ identifiers: ['b'], contents: { 'a': 2 } }]); + + assert.deepEqual(testObject.override('b').contents, { 'a': 2, 'c': 1 }); + }); +}); \ No newline at end of file diff --git a/src/vs/platform/configuration/test/common/model.test.ts b/src/vs/platform/configuration/test/common/model.test.ts index db7edc4c0d7..e2f3bb6e997 100644 --- a/src/vs/platform/configuration/test/common/model.test.ts +++ b/src/vs/platform/configuration/test/common/model.test.ts @@ -5,11 +5,11 @@ 'use strict'; import * as assert from 'assert'; -import * as model from 'vs/platform/configuration/common/model'; +import { CustomConfiguration, DefaultConfiguration } from 'vs/platform/configuration/common/model'; import { Extensions, IConfigurationRegistry } from 'vs/platform/configuration/common/configurationRegistry'; import { Registry } from 'vs/platform/platform'; -suite('ConfigurationService - Model', () => { +suite('Configuration', () => { suiteSetup(() => { Registry.as(Extensions.Configuration).registerConfiguration({ @@ -28,62 +28,47 @@ suite('ConfigurationService - Model', () => { }); }); - test('simple merge', () => { - let base = { 'a': 1, 'b': 2 }; - model.merge(base, { 'a': 3, 'c': 4 }, true); - assert.deepEqual(base, { 'a': 3, 'b': 2, 'c': 4 }); - base = { 'a': 1, 'b': 2 }; - model.merge(base, { 'a': 3, 'c': 4 }, false); - assert.deepEqual(base, { 'a': 1, 'b': 2, 'c': 4 }); - }); - - test('Recursive merge', () => { - const base = { 'a': { 'b': 1 } }; - model.merge(base, { 'a': { 'b': 2 } }, true); - assert.deepEqual(base, { 'a': { 'b': 2 } }); - }); - test('simple merge using models', () => { - let base = new model.ConfigModel(JSON.stringify({ 'a': 1, 'b': 2 })); - let add = new model.ConfigModel(JSON.stringify({ 'a': 3, 'c': 4 })); + let base = new CustomConfiguration(JSON.stringify({ 'a': 1, 'b': 2 })); + let add = new CustomConfiguration(JSON.stringify({ 'a': 3, 'c': 4 })); let result = base.merge(add); assert.deepEqual(result.contents, { 'a': 3, 'b': 2, 'c': 4 }); }); test('simple merge with an undefined contents', () => { - let base = new model.ConfigModel(JSON.stringify({ 'a': 1, 'b': 2 })); - let add = new model.ConfigModel(null); + let base = new CustomConfiguration(JSON.stringify({ 'a': 1, 'b': 2 })); + let add = new CustomConfiguration(null); let result = base.merge(add); assert.deepEqual(result.contents, { 'a': 1, 'b': 2 }); - base = new model.ConfigModel(null); - add = new model.ConfigModel(JSON.stringify({ 'a': 1, 'b': 2 })); + base = new CustomConfiguration(null); + add = new CustomConfiguration(JSON.stringify({ 'a': 1, 'b': 2 })); result = base.merge(add); assert.deepEqual(result.contents, { 'a': 1, 'b': 2 }); - base = new model.ConfigModel(null); - add = new model.ConfigModel(null); + base = new CustomConfiguration(null); + add = new CustomConfiguration(null); result = base.merge(add); assert.deepEqual(result.contents, {}); }); test('Recursive merge using config models', () => { - let base = new model.ConfigModel(JSON.stringify({ 'a': { 'b': 1 } })); - let add = new model.ConfigModel(JSON.stringify({ 'a': { 'b': 2 } })); + let base = new CustomConfiguration(JSON.stringify({ 'a': { 'b': 1 } })); + let add = new CustomConfiguration(JSON.stringify({ 'a': { 'b': 2 } })); let result = base.merge(add); assert.deepEqual(result.contents, { 'a': { 'b': 2 } }); }); test('Test contents while getting an existing property', () => { - let testObject = new model.ConfigModel(JSON.stringify({ 'a': 1 })); + let testObject = new CustomConfiguration(JSON.stringify({ 'a': 1 })); assert.deepEqual(testObject.getContentsFor('a'), 1); - testObject = new model.ConfigModel(JSON.stringify({ 'a': { 'b': 1 } })); + testObject = new CustomConfiguration(JSON.stringify({ 'a': { 'b': 1 } })); assert.deepEqual(testObject.getContentsFor('a'), { 'b': 1 }); }); test('Test contents are undefined for non existing properties', () => { - const testObject = new model.ConfigModel(JSON.stringify({ + const testObject = new CustomConfiguration(JSON.stringify({ awesome: true })); @@ -91,25 +76,25 @@ suite('ConfigurationService - Model', () => { }); test('Test contents are undefined for undefined config', () => { - const testObject = new model.ConfigModel(null); + const testObject = new CustomConfiguration(null); assert.deepEqual(testObject.getContentsFor('unknownproperty'), undefined); }); test('Test configWithOverrides gives all content merged with overrides', () => { - const testObject = new model.ConfigModel(JSON.stringify({ 'a': 1, 'c': 1, '[b]': { 'a': 2 } })); + const testObject = new CustomConfiguration(JSON.stringify({ 'a': 1, 'c': 1, '[b]': { 'a': 2 } })); - assert.deepEqual(testObject.configWithOverrides('b').contents, { 'a': 2, 'c': 1, '[b]': { 'a': 2 } }); + assert.deepEqual(testObject.override('b').contents, { 'a': 2, 'c': 1, '[b]': { 'a': 2 } }); }); test('Test configWithOverrides gives empty contents', () => { - const testObject = new model.ConfigModel(null); + const testObject = new CustomConfiguration(null); - assert.deepEqual(testObject.configWithOverrides('b').contents, {}); + assert.deepEqual(testObject.override('b').contents, {}); }); test('Test update with empty data', () => { - const testObject = new model.ConfigModel(); + const testObject = new CustomConfiguration(); testObject.update(''); assert.deepEqual(testObject.contents, {}); @@ -140,7 +125,7 @@ suite('ConfigurationService - Model', () => { } } }); - assert.equal(true, new model.DefaultConfigModel().getContentsFor('a')); + assert.equal(true, new DefaultConfiguration().getContentsFor('a')); }); test('Test registering the language property', () => { @@ -157,7 +142,7 @@ suite('ConfigurationService - Model', () => { } } }); - assert.equal(undefined, new model.DefaultConfigModel().getContentsFor('[a]')); + assert.equal(undefined, new DefaultConfiguration().getContentsFor('[a]')); }); }); \ No newline at end of file diff --git a/src/vs/platform/files/common/files.ts b/src/vs/platform/files/common/files.ts index 93cbdb6f3f9..f37c6349d88 100644 --- a/src/vs/platform/files/common/files.ts +++ b/src/vs/platform/files/common/files.ts @@ -196,7 +196,7 @@ export enum FileChangeType { export interface IFileChange { /** - * The type of change that occured to the file. + * The type of change that occurred to the file. */ type: FileChangeType; diff --git a/src/vs/platform/quickOpen/common/quickOpen.ts b/src/vs/platform/quickOpen/common/quickOpen.ts index 6fe5fcc6169..2ce7f0a3691 100644 --- a/src/vs/platform/quickOpen/common/quickOpen.ts +++ b/src/vs/platform/quickOpen/common/quickOpen.ts @@ -62,6 +62,11 @@ export interface IPickOptions { * enables quick navigate in the picker to open an element without typing */ quickNavigateConfiguration?: IQuickNavigateConfiguration; + + /** + * a context key to set when this picker is active + */ + contextKey?: string; } export interface IInputOptions { diff --git a/src/vs/platform/search/common/replace.ts b/src/vs/platform/search/common/replace.ts index e57e23c1034..647b5d51a0d 100644 --- a/src/vs/platform/search/common/replace.ts +++ b/src/vs/platform/search/common/replace.ts @@ -175,7 +175,7 @@ export class ReplacePattern { } if (substrFrom === 0) { - // no replacement occured + // no replacement occurred return; } diff --git a/src/vs/platform/storage/common/storageService.ts b/src/vs/platform/storage/common/storageService.ts index 82952ee5dbd..83049e9736f 100644 --- a/src/vs/platform/storage/common/storageService.ts +++ b/src/vs/platform/storage/common/storageService.ts @@ -23,7 +23,6 @@ export interface IStorage { export interface IWorkspaceStorageIdentifier { resource: URI; uid?: number; - name?: string; } export class StorageService implements IStorageService { @@ -55,7 +54,7 @@ export class StorageService implements IStorageService { // Make sure to delete all workspace storage if the workspace has been recreated meanwhile // which is only possible if a UID property is provided that we can check on if (workspaceIdentifier && types.isNumber(workspaceIdentifier.uid)) { - this.cleanupWorkspaceScope(workspaceIdentifier.uid, workspaceIdentifier.name); + this.cleanupWorkspaceScope(workspaceIdentifier.uid); } } @@ -76,13 +75,13 @@ export class StorageService implements IStorageService { return `${strings.rtrim(workspaceIdStr, '/')}/`; } - private cleanupWorkspaceScope(workspaceId: number, workspaceName: string): void { + private cleanupWorkspaceScope(workspaceUid: number): void { // Get stored identifier from storage const id = this.getInteger(StorageService.WORKSPACE_IDENTIFIER, StorageScope.WORKSPACE); // If identifier differs, assume the workspace got recreated and thus clean all storage for this workspace - if (types.isNumber(id) && workspaceId !== id) { + if (types.isNumber(id) && workspaceUid !== id) { const keyPrefix = this.toStorageKey('', StorageScope.WORKSPACE); const toDelete: string[] = []; const length = this.workspaceStorage.length; @@ -99,10 +98,6 @@ export class StorageService implements IStorageService { } } - if (toDelete.length > 0) { - console.warn('Clearing previous version of local storage for workspace ', workspaceName); - } - // Run the delete toDelete.forEach((keyToDelete) => { this.workspaceStorage.removeItem(keyToDelete); @@ -110,8 +105,8 @@ export class StorageService implements IStorageService { } // Store workspace identifier now - if (workspaceId !== id) { - this.store(StorageService.WORKSPACE_IDENTIFIER, workspaceId, StorageScope.WORKSPACE); + if (workspaceUid !== id) { + this.store(StorageService.WORKSPACE_IDENTIFIER, workspaceUid, StorageScope.WORKSPACE); } } diff --git a/src/vs/platform/storage/test/storageService.test.ts b/src/vs/platform/storage/test/storageService.test.ts index 2be5dff0a16..2978c54f134 100644 --- a/src/vs/platform/storage/test/storageService.test.ts +++ b/src/vs/platform/storage/test/storageService.test.ts @@ -77,7 +77,9 @@ suite('Workbench StorageSevice', () => { test('StorageSevice cleans up when workspace changes', () => { let storageImpl = new InMemoryLocalStorage(); - let s = new StorageService(storageImpl, null, contextService.getWorkspace()); + let ws = contextService.getWorkspace(); + ws.uid = new Date().getTime(); + let s = new StorageService(storageImpl, null, ws); s.store('key1', 'foobar'); s.store('key2', 'something'); @@ -93,7 +95,8 @@ suite('Workbench StorageSevice', () => { assert.strictEqual(s.get('wkey1', StorageScope.WORKSPACE), 'foo'); assert.strictEqual(s.get('wkey2', StorageScope.WORKSPACE), 'foo2'); - let ws: any = new Workspace(TestWorkspace.resource, new Date().getTime() + 100, TestWorkspace.name); + ws = new Workspace(TestWorkspace.resource, TestWorkspace.name); + ws.uid = new Date().getTime() + 100; s = new StorageService(storageImpl, null, ws); assert.strictEqual(s.get('key1', StorageScope.GLOBAL), 'foobar'); diff --git a/src/vs/platform/workspace/common/workspace.ts b/src/vs/platform/workspace/common/workspace.ts index 8e1b08ed143..7abd76ad14c 100644 --- a/src/vs/platform/workspace/common/workspace.ts +++ b/src/vs/platform/workspace/common/workspace.ts @@ -65,13 +65,6 @@ export interface IWorkspace { */ resource: URI; - /** - * the unique identifier of the workspace. if the workspace is deleted and recreated - * the identifier also changes. this makes the uid more unique compared to the id which - * is just derived from the workspace name. - */ - uid?: number; - /** * the name of the workspace */ @@ -85,6 +78,11 @@ export interface IWorkspace2 { */ readonly id: string; + /** + * the name of the workspace. + */ + readonly name: string; + /** * Mutliple roots in this workspace. First entry is master and never changes. */ @@ -94,17 +92,13 @@ export interface IWorkspace2 { export class Workspace implements IWorkspace { - constructor(private _resource: URI, private _uid?: number, private _name?: string) { + constructor(private _resource: URI, private _name?: string) { } public get resource(): URI { return this._resource; } - public get uid(): number { - return this._uid; - } - public get name(): string { return this._name; } @@ -134,6 +128,6 @@ export class Workspace implements IWorkspace { } public toJSON() { - return { resource: this._resource, uid: this._uid, name: this._name }; + return { resource: this._resource, name: this._name }; } } \ No newline at end of file diff --git a/src/vs/platform/workspace/test/common/testWorkspace.ts b/src/vs/platform/workspace/test/common/testWorkspace.ts index 18926c9330d..4400e7544ea 100644 --- a/src/vs/platform/workspace/test/common/testWorkspace.ts +++ b/src/vs/platform/workspace/test/common/testWorkspace.ts @@ -8,6 +8,5 @@ import URI from 'vs/base/common/uri'; export const TestWorkspace = new Workspace( URI.file('C:\\testWorkspace'), - Date.now(), 'Test Workspace' ); diff --git a/src/vs/workbench/api/electron-browser/mainThreadWorkspace.ts b/src/vs/workbench/api/electron-browser/mainThreadWorkspace.ts index f6fc31c91ef..1cde185a17d 100644 --- a/src/vs/workbench/api/electron-browser/mainThreadWorkspace.ts +++ b/src/vs/workbench/api/electron-browser/mainThreadWorkspace.ts @@ -42,8 +42,8 @@ export class MainThreadWorkspace extends MainThreadWorkspaceShape { // --- workspace --- - private _onDidChangeWorkspace(folders: URI[]): void { - this._proxy.$acceptWorkspaceData(folders); + private _onDidChangeWorkspace(): void { + this._proxy.$acceptWorkspaceData(this._contextService.getWorkspace2()); } // --- search --- diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index 9f3ed92538c..7808ff172bb 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -91,7 +91,7 @@ export function createApiFactory( const extHostTerminalService = col.define(ExtHostContext.ExtHostTerminalService).set(new ExtHostTerminalService(threadService)); const extHostSCM = col.define(ExtHostContext.ExtHostSCM).set(new ExtHostSCM(threadService, extHostCommands)); const extHostTask = col.define(ExtHostContext.ExtHostTask).set(new ExtHostTask(threadService)); - const extHostWorkspace = col.define(ExtHostContext.ExtHostWorkspace).set(new ExtHostWorkspace(threadService, initData.workspace && [initData.workspace.resource])); + const extHostWorkspace = col.define(ExtHostContext.ExtHostWorkspace).set(new ExtHostWorkspace(threadService, initData.workspace)); col.define(ExtHostContext.ExtHostExtensionService).set(extensionService); col.finish(false, threadService); @@ -145,7 +145,7 @@ export function createApiFactory( console.warn('Edits from command ' + id + ' were not applied.'); } }, (err) => { - console.warn('An error occured while running command ' + id, err); + console.warn('An error occurred while running command ' + id, err); }); }); }, diff --git a/src/vs/workbench/api/node/extHost.protocol.ts b/src/vs/workbench/api/node/extHost.protocol.ts index 393e50579ff..c7f432d81bb 100644 --- a/src/vs/workbench/api/node/extHost.protocol.ts +++ b/src/vs/workbench/api/node/extHost.protocol.ts @@ -22,7 +22,6 @@ import { IExtensionDescription } from 'vs/platform/extensions/common/extensions' import { StatusbarAlignment as MainThreadStatusBarAlignment } from 'vs/platform/statusbar/common/statusbar'; import { ITelemetryInfo } from 'vs/platform/telemetry/common/telemetry'; import { ICommandHandlerDescription } from 'vs/platform/commands/common/commands'; -import { IWorkspace } from 'vs/platform/workspace/common/workspace'; import { IProgressOptions, IProgressStep } from 'vs/platform/progress/common/progress'; import * as editorCommon from 'vs/editor/common/editorCommon'; @@ -57,10 +56,15 @@ export interface IEnvironment { extensionTestsPath: string; } +export interface IWorkspaceData { + id: string; + roots: URI[]; +} + export interface IInitData { parentPid: number; environment: IEnvironment; - workspace: IWorkspace; + workspace: IWorkspaceData; extensions: IExtensionDescription[]; configuration: IWorkspaceConfigurationValues; telemetryInfo: ITelemetryInfo; @@ -405,7 +409,7 @@ export abstract class ExtHostTreeViewsShape { } export abstract class ExtHostWorkspaceShape { - $acceptWorkspaceData(folders: URI[]): void { throw ni(); } + $acceptWorkspaceData(workspace: IWorkspaceData): void { throw ni(); } } export abstract class ExtHostExtensionServiceShape { diff --git a/src/vs/workbench/api/node/extHostExtensionService.ts b/src/vs/workbench/api/node/extHostExtensionService.ts index aeb68c62eda..67acd239b02 100644 --- a/src/vs/workbench/api/node/extHostExtensionService.ts +++ b/src/vs/workbench/api/node/extHostExtensionService.ts @@ -15,8 +15,7 @@ import { ExtHostStorage } from 'vs/workbench/api/node/extHostStorage'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { createApiFactory, initializeExtensionApi } from 'vs/workbench/api/node/extHost.api.impl'; import { IThreadService } from 'vs/workbench/services/thread/common/threadService'; -import { IWorkspace } from 'vs/platform/workspace/common/workspace'; -import { MainContext, MainProcessExtensionServiceShape, IEnvironment, IInitData } from './extHost.protocol'; +import { MainContext, MainProcessExtensionServiceShape, IWorkspaceData, IEnvironment, IInitData } from './extHost.protocol'; import { createHash } from 'crypto'; const hasOwnProperty = Object.hasOwnProperty; @@ -103,13 +102,13 @@ class ExtensionMemento implements IExtensionMemento { class ExtensionStoragePath { - private readonly _workspace: IWorkspace; + private readonly _workspace: IWorkspaceData; private readonly _environment: IEnvironment; private readonly _ready: TPromise; private _value: string; - constructor(workspace: IWorkspace, environment: IEnvironment) { + constructor(workspace: IWorkspaceData, environment: IEnvironment) { this._workspace = workspace; this._environment = environment; this._ready = this._getOrCreateWorkspaceStoragePath().then(value => this._value = value); @@ -130,10 +129,10 @@ class ExtensionStoragePath { if (!this._workspace) { return TPromise.as(undefined); } - + // TODO@joh what to do with multiple roots? const storageName = createHash('md5') - .update(this._workspace.resource.fsPath) - .update(this._workspace.uid ? this._workspace.uid.toString() : '') + .update(this._workspace.roots[0].fsPath) + .update(this._workspace.id || '') .digest('hex'); const storagePath = join(this._environment.appSettingsHome, 'workspaceStorage', storageName); diff --git a/src/vs/workbench/api/node/extHostSCM.ts b/src/vs/workbench/api/node/extHostSCM.ts index 8a87e5126c0..76c7078dda9 100644 --- a/src/vs/workbench/api/node/extHostSCM.ts +++ b/src/vs/workbench/api/node/extHostSCM.ts @@ -323,7 +323,10 @@ export class ExtHostSCM { return TPromise.as(null); } - return asWinJsPromise(token => URI.parse(sourceControl.quickDiffProvider.provideOriginalResource(uri, token).toString())); + return asWinJsPromise(token => { + const result = sourceControl.quickDiffProvider.provideOriginalResource(uri, token); + return result && URI.parse(result.toString()); + }); } $onActiveSourceControlChange(handle: number): TPromise { diff --git a/src/vs/workbench/api/node/extHostWorkspace.ts b/src/vs/workbench/api/node/extHostWorkspace.ts index 7ec394f6913..dff559112b7 100644 --- a/src/vs/workbench/api/node/extHostWorkspace.ts +++ b/src/vs/workbench/api/node/extHostWorkspace.ts @@ -12,7 +12,7 @@ import { IThreadService } from 'vs/workbench/services/thread/common/threadServic import { IResourceEdit } from 'vs/editor/common/services/bulkEdit'; import { TPromise } from 'vs/base/common/winjs.base'; import { fromRange, EndOfLine } from 'vs/workbench/api/node/extHostTypeConverters'; -import { ExtHostWorkspaceShape, MainContext, MainThreadWorkspaceShape } from './extHost.protocol'; +import { IWorkspaceData, ExtHostWorkspaceShape, MainContext, MainThreadWorkspaceShape } from './extHost.protocol'; import * as vscode from 'vscode'; export class ExtHostWorkspace extends ExtHostWorkspaceShape { @@ -20,18 +20,19 @@ export class ExtHostWorkspace extends ExtHostWorkspaceShape { private static _requestIdPool = 0; private readonly _proxy: MainThreadWorkspaceShape; - private _workspaceFolders: URI[]; + private _workspace: IWorkspaceData; - constructor(threadService: IThreadService, folders: URI[]) { + constructor(threadService: IThreadService, workspace: IWorkspaceData) { super(); this._proxy = threadService.get(MainContext.MainThreadWorkspace); - this._workspaceFolders = folders; + this._workspace = workspace; } // --- workspace --- getPath(): string { - return isFalsyOrEmpty(this._workspaceFolders) ? undefined : this._workspaceFolders[0].fsPath; + // TODO@Joh handle roots.length > 1 case + return this._workspace ? this._workspace.roots[0].fsPath : undefined; } getRelativePath(pathOrUri: string | vscode.Uri): string { @@ -47,11 +48,11 @@ export class ExtHostWorkspace extends ExtHostWorkspaceShape { return path; } - if (isFalsyOrEmpty(this._workspaceFolders)) { + if (!this._workspace || isFalsyOrEmpty(this._workspace.roots)) { return normalize(path); } - for (const { fsPath } of this._workspaceFolders) { + for (const { fsPath } of this._workspace.roots) { let result = relative(fsPath, path); if (!result || result.indexOf('..') === 0) { continue; @@ -62,9 +63,9 @@ export class ExtHostWorkspace extends ExtHostWorkspaceShape { return normalize(path); } - $acceptWorkspaceData(workspaceFolders: URI[]): void { + $acceptWorkspaceData(workspace: IWorkspaceData): void { //TODO@joh equality-check, emit event etc. - this._workspaceFolders = workspaceFolders; + this._workspace = workspace; } // --- search --- diff --git a/src/vs/workbench/browser/parts/editor/binaryEditor.ts b/src/vs/workbench/browser/parts/editor/binaryEditor.ts index f2e1ec0cde6..08ce253c8db 100644 --- a/src/vs/workbench/browser/parts/editor/binaryEditor.ts +++ b/src/vs/workbench/browser/parts/editor/binaryEditor.ts @@ -59,7 +59,7 @@ export abstract class BaseBinaryResourceEditor extends BaseEditor { this.binaryContainer.tabindex(0); // enable focus support from the editor part (do not remove) // Custom Scrollbars - this.scrollbar = new DomScrollableElement(binaryContainerElement, { canUseTranslate3d: false, horizontal: ScrollbarVisibility.Auto, vertical: ScrollbarVisibility.Auto }); + this.scrollbar = new DomScrollableElement(binaryContainerElement, { horizontal: ScrollbarVisibility.Auto, vertical: ScrollbarVisibility.Auto }); parent.getHTMLElement().appendChild(this.scrollbar.getDomNode()); } diff --git a/src/vs/workbench/browser/parts/editor/editor.contribution.ts b/src/vs/workbench/browser/parts/editor/editor.contribution.ts index cd4bc5a15ea..f9d29431038 100644 --- a/src/vs/workbench/browser/parts/editor/editor.contribution.ts +++ b/src/vs/workbench/browser/parts/editor/editor.contribution.ts @@ -30,12 +30,15 @@ import { KeyMod, KeyChord, KeyCode } from 'vs/base/common/keyCodes'; import { CloseEditorsInGroupAction, CloseEditorsInOtherGroupsAction, CloseAllEditorsAction, MoveGroupLeftAction, MoveGroupRightAction, SplitEditorAction, JoinTwoGroupsAction, KeepEditorAction, CloseOtherEditorsInGroupAction, OpenToSideAction, RevertAndCloseEditorAction, NavigateBetweenGroupsAction, FocusActiveGroupAction, FocusFirstGroupAction, FocusSecondGroupAction, FocusThirdGroupAction, EvenGroupWidthsAction, MaximizeGroupAction, MinimizeOtherGroupsAction, FocusPreviousGroup, FocusNextGroup, ShowEditorsInGroupOneAction, - toEditorQuickOpenEntry, CloseLeftEditorsInGroupAction, CloseRightEditorsInGroupAction, OpenNextEditor, OpenPreviousEditor, NavigateBackwardsAction, NavigateForwardAction, ReopenClosedEditorAction, OpenPreviousRecentlyUsedEditorInGroupAction, NAVIGATE_IN_GROUP_ONE_PREFIX, + toEditorQuickOpenEntry, CloseLeftEditorsInGroupAction, CloseRightEditorsInGroupAction, CloseUnmodifiedEditorsInGroupAction, OpenNextEditor, OpenPreviousEditor, NavigateBackwardsAction, NavigateForwardAction, ReopenClosedEditorAction, OpenPreviousRecentlyUsedEditorInGroupAction, NAVIGATE_IN_GROUP_ONE_PREFIX, OpenPreviousEditorFromHistoryAction, ShowAllEditorsAction, NAVIGATE_ALL_EDITORS_GROUP_PREFIX, ClearEditorHistoryAction, ShowEditorsInGroupTwoAction, MoveEditorRightInGroupAction, OpenNextEditorInGroup, OpenPreviousEditorInGroup, OpenNextRecentlyUsedEditorAction, OpenPreviousRecentlyUsedEditorAction, NAVIGATE_IN_GROUP_TWO_PREFIX, ShowEditorsInGroupThreeAction, NAVIGATE_IN_GROUP_THREE_PREFIX, FocusLastEditorInStackAction, OpenNextRecentlyUsedEditorInGroupAction, MoveEditorToPreviousGroupAction, MoveEditorToNextGroupAction, MoveEditorLeftInGroupAction, ClearRecentFilesAction } from 'vs/workbench/browser/parts/editor/editorActions'; import * as editorCommands from 'vs/workbench/browser/parts/editor/editorCommands'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; +import { getQuickNavigateHandler, inQuickOpenContext } from "vs/workbench/browser/parts/quickopen/quickopen"; +import { KeybindingsRegistry } from "vs/platform/keybinding/common/keybindingsRegistry"; +import { ContextKeyExpr } from "vs/platform/contextkey/common/contextkey"; // Register String Editor Registry.as(EditorExtensions.Editors).registerEditor( @@ -257,11 +260,15 @@ export class QuickOpenActionContributor extends ActionBarContributor { const actionBarRegistry = Registry.as(ActionBarExtensions.Actionbar); actionBarRegistry.registerActionBarContributor(Scope.VIEWER, QuickOpenActionContributor); +const editorPickerContextKey = 'inEditorsPicker'; +const editorPickerContext = ContextKeyExpr.and(inQuickOpenContext, ContextKeyExpr.has(editorPickerContextKey)); + Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpenHandler( new QuickOpenHandlerDescriptor( 'vs/workbench/browser/parts/editor/editorPicker', 'GroupOnePicker', NAVIGATE_IN_GROUP_ONE_PREFIX, + editorPickerContextKey, [ { prefix: NAVIGATE_IN_GROUP_ONE_PREFIX, @@ -287,6 +294,7 @@ Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpen 'vs/workbench/browser/parts/editor/editorPicker', 'GroupTwoPicker', NAVIGATE_IN_GROUP_TWO_PREFIX, + editorPickerContextKey, [] ) ); @@ -296,6 +304,7 @@ Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpen 'vs/workbench/browser/parts/editor/editorPicker', 'GroupThreePicker', NAVIGATE_IN_GROUP_THREE_PREFIX, + editorPickerContextKey, [] ) ); @@ -305,6 +314,7 @@ Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpen 'vs/workbench/browser/parts/editor/editorPicker', 'AllEditorsPicker', NAVIGATE_ALL_EDITORS_GROUP_PREFIX, + editorPickerContextKey, [ { prefix: NAVIGATE_ALL_EDITORS_GROUP_PREFIX, @@ -321,8 +331,6 @@ registry.registerWorkbenchAction(new SyncActionDescriptor(OpenNextEditorInGroup, registry.registerWorkbenchAction(new SyncActionDescriptor(OpenPreviousEditorInGroup, OpenPreviousEditorInGroup.ID, OpenPreviousEditorInGroup.LABEL), 'View: Open Previous Editor in Group', category); registry.registerWorkbenchAction(new SyncActionDescriptor(OpenNextRecentlyUsedEditorAction, OpenNextRecentlyUsedEditorAction.ID, OpenNextRecentlyUsedEditorAction.LABEL), 'View: Open Next Recently Used Editor', category); registry.registerWorkbenchAction(new SyncActionDescriptor(OpenPreviousRecentlyUsedEditorAction, OpenPreviousRecentlyUsedEditorAction.ID, OpenPreviousRecentlyUsedEditorAction.LABEL), 'View: Open Previous Recently Used Editor', category); -registry.registerWorkbenchAction(new SyncActionDescriptor(OpenNextRecentlyUsedEditorInGroupAction, OpenNextRecentlyUsedEditorInGroupAction.ID, OpenNextRecentlyUsedEditorInGroupAction.LABEL, { primary: KeyMod.CtrlCmd | KeyCode.Tab, mac: { primary: KeyMod.WinCtrl | KeyCode.Tab } }), 'Open Next Recently Used Editor in Group'); -registry.registerWorkbenchAction(new SyncActionDescriptor(OpenPreviousRecentlyUsedEditorInGroupAction, OpenPreviousRecentlyUsedEditorInGroupAction.ID, OpenPreviousRecentlyUsedEditorInGroupAction.LABEL, { primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.Tab, mac: { primary: KeyMod.WinCtrl | KeyMod.Shift | KeyCode.Tab } }), 'Open Previous Recently Used Editor in Group'); registry.registerWorkbenchAction(new SyncActionDescriptor(ShowAllEditorsAction, ShowAllEditorsAction.ID, ShowAllEditorsAction.LABEL, { primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KEY_K, KeyMod.CtrlCmd | KeyCode.KEY_P), mac: { primary: KeyMod.CtrlCmd | KeyMod.Alt | KeyCode.Tab } }), 'View: Show All Editors', category); registry.registerWorkbenchAction(new SyncActionDescriptor(ShowEditorsInGroupOneAction, ShowEditorsInGroupOneAction.ID, ShowEditorsInGroupOneAction.LABEL), 'View: Show Editors in First Group', category); registry.registerWorkbenchAction(new SyncActionDescriptor(ShowEditorsInGroupTwoAction, ShowEditorsInGroupTwoAction.ID, ShowEditorsInGroupTwoAction.LABEL), 'View: Show Editors in Second Group', category); @@ -335,6 +343,7 @@ registry.registerWorkbenchAction(new SyncActionDescriptor(KeepEditorAction, Keep registry.registerWorkbenchAction(new SyncActionDescriptor(CloseAllEditorsAction, CloseAllEditorsAction.ID, CloseAllEditorsAction.LABEL, { primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KEY_K, KeyMod.CtrlCmd | KeyCode.KEY_W) }), 'View: Close All Editors', category); registry.registerWorkbenchAction(new SyncActionDescriptor(CloseLeftEditorsInGroupAction, CloseLeftEditorsInGroupAction.ID, CloseLeftEditorsInGroupAction.LABEL), 'View: Close Editors to the Left', category); registry.registerWorkbenchAction(new SyncActionDescriptor(CloseRightEditorsInGroupAction, CloseRightEditorsInGroupAction.ID, CloseRightEditorsInGroupAction.LABEL), 'View: Close Editors to the Right', category); +registry.registerWorkbenchAction(new SyncActionDescriptor(CloseUnmodifiedEditorsInGroupAction, CloseUnmodifiedEditorsInGroupAction.ID, CloseUnmodifiedEditorsInGroupAction.LABEL, { primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KEY_K, KeyCode.KEY_U) }), 'View: Close Unmodified Editors in Group', category); registry.registerWorkbenchAction(new SyncActionDescriptor(CloseEditorsInGroupAction, CloseEditorsInGroupAction.ID, CloseEditorsInGroupAction.LABEL, { primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KEY_K, KeyCode.KEY_W) }), 'View: Close All Editors in Group', category); registry.registerWorkbenchAction(new SyncActionDescriptor(CloseOtherEditorsInGroupAction, CloseOtherEditorsInGroupAction.ID, CloseOtherEditorsInGroupAction.LABEL, { primary: null, mac: { primary: KeyMod.CtrlCmd | KeyMod.Alt | KeyCode.KEY_T } }), 'View: Close Other Editors', category); registry.registerWorkbenchAction(new SyncActionDescriptor(CloseEditorsInOtherGroupsAction, CloseEditorsInOtherGroupsAction.ID, CloseEditorsInOtherGroupsAction.LABEL), 'View: Close Editors in Other Groups', category); @@ -363,5 +372,32 @@ registry.registerWorkbenchAction(new SyncActionDescriptor(OpenPreviousEditorFrom registry.registerWorkbenchAction(new SyncActionDescriptor(ClearEditorHistoryAction, ClearEditorHistoryAction.ID, ClearEditorHistoryAction.LABEL), 'Clear Editor History'); registry.registerWorkbenchAction(new SyncActionDescriptor(RevertAndCloseEditorAction, RevertAndCloseEditorAction.ID, RevertAndCloseEditorAction.LABEL), 'View: Revert and Close Editor', category); +// Register Editor Picker Actions including quick navigate support +const openNextEditorKeybinding = { primary: KeyMod.CtrlCmd | KeyCode.Tab, mac: { primary: KeyMod.WinCtrl | KeyCode.Tab } }; +const openPreviousEditorKeybinding = { primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.Tab, mac: { primary: KeyMod.WinCtrl | KeyMod.Shift | KeyCode.Tab } }; +registry.registerWorkbenchAction(new SyncActionDescriptor(OpenNextRecentlyUsedEditorInGroupAction, OpenNextRecentlyUsedEditorInGroupAction.ID, OpenNextRecentlyUsedEditorInGroupAction.LABEL, openNextEditorKeybinding), 'Open Next Recently Used Editor in Group'); +registry.registerWorkbenchAction(new SyncActionDescriptor(OpenPreviousRecentlyUsedEditorInGroupAction, OpenPreviousRecentlyUsedEditorInGroupAction.ID, OpenPreviousRecentlyUsedEditorInGroupAction.LABEL, openPreviousEditorKeybinding), 'Open Previous Recently Used Editor in Group'); + +const quickOpenNavigateNextInEditorPickerId = 'workbench.action.quickOpenNavigateNextInEditorPicker'; +KeybindingsRegistry.registerCommandAndKeybindingRule({ + id: quickOpenNavigateNextInEditorPickerId, + weight: KeybindingsRegistry.WEIGHT.workbenchContrib(50), + handler: getQuickNavigateHandler(quickOpenNavigateNextInEditorPickerId, true), + when: editorPickerContext, + primary: openNextEditorKeybinding.primary, + mac: openNextEditorKeybinding.mac +}); + +const quickOpenNavigatePreviousInEditorPickerId = 'workbench.action.quickOpenNavigatePreviousInEditorPicker'; +KeybindingsRegistry.registerCommandAndKeybindingRule({ + id: quickOpenNavigatePreviousInEditorPickerId, + weight: KeybindingsRegistry.WEIGHT.workbenchContrib(50), + handler: getQuickNavigateHandler(quickOpenNavigatePreviousInEditorPickerId, false), + when: editorPickerContext, + primary: openPreviousEditorKeybinding.primary, + mac: openPreviousEditorKeybinding.mac +}); + + // Editor Commands editorCommands.setup(); \ No newline at end of file diff --git a/src/vs/workbench/browser/parts/editor/editorActions.ts b/src/vs/workbench/browser/parts/editor/editorActions.ts index 34a37ea902f..29cf34bc07c 100644 --- a/src/vs/workbench/browser/parts/editor/editorActions.ts +++ b/src/vs/workbench/browser/parts/editor/editorActions.ts @@ -617,7 +617,7 @@ export class CloseLeftEditorsInGroupAction extends Action { public run(context?: IEditorContext): TPromise { const editor = getTarget(this.editorService, this.groupService, context); if (editor) { - return this.editorService.closeEditors(editor.position, editor.input, Direction.LEFT); + return this.editorService.closeEditors(editor.position, { except: editor.input, direction: Direction.LEFT }); } return TPromise.as(false); @@ -641,7 +641,7 @@ export class CloseRightEditorsInGroupAction extends Action { public run(context?: IEditorContext): TPromise { const editor = getTarget(this.editorService, this.groupService, context); if (editor) { - return this.editorService.closeEditors(editor.position, editor.input, Direction.RIGHT); + return this.editorService.closeEditors(editor.position, { except: editor.input, direction: Direction.RIGHT }); } return TPromise.as(false); @@ -691,6 +691,39 @@ export class CloseAllEditorsAction extends Action { } } +export class CloseUnmodifiedEditorsInGroupAction extends Action { + + public static ID = 'workbench.action.closeUnmodifiedEditors'; + public static LABEL = nls.localize('closeUnmodifiedEditors', "Close Unmodified Editors in Group"); + + constructor( + id: string, + label: string, + @IEditorGroupService private editorGroupService: IEditorGroupService, + @IWorkbenchEditorService private editorService: IWorkbenchEditorService + ) { + super(id, label); + } + + public run(context?: IEditorContext): TPromise { + let position = context ? this.editorGroupService.getStacksModel().positionOfGroup(context.group) : null; + + // If position is not passed in take the position of the active editor. + if (typeof position !== 'number') { + const active = this.editorService.getActiveEditor(); + if (active) { + position = active.position; + } + } + + if (typeof position === 'number') { + return this.editorService.closeEditors(position, { unmodifiedOnly: true }); + } + + return TPromise.as(false); + } +} + export class CloseEditorsInOtherGroupsAction extends Action { public static ID = 'workbench.action.closeEditorsInOtherGroups'; @@ -748,7 +781,7 @@ export class CloseOtherEditorsInGroupAction extends Action { } if (typeof position === 'number' && input) { - return this.editorService.closeEditors(position, input); + return this.editorService.closeEditors(position, { except: input }); } return TPromise.as(false); diff --git a/src/vs/workbench/browser/parts/editor/editorPart.ts b/src/vs/workbench/browser/parts/editor/editorPart.ts index f0db5dc5baf..18a865ad5fc 100644 --- a/src/vs/workbench/browser/parts/editor/editorPart.ts +++ b/src/vs/workbench/browser/parts/editor/editorPart.ts @@ -665,18 +665,23 @@ export class EditorPart extends Part implements IEditorPart, IEditorGroupService }); } - public closeEditors(position: Position, except?: EditorInput, direction?: Direction): TPromise { + public closeEditors(position: Position, filter: { except?: EditorInput, direction?: Direction, unmodifiedOnly?: boolean } = Object.create(null)): TPromise { const group = this.stacks.groupAt(position); if (!group) { return TPromise.as(null); } + let editors = group.getEditors(); + if (filter.unmodifiedOnly) { + editors = editors.filter(e => !e.isDirty()); + } + // Check for dirty and veto let editorsToClose: EditorInput[]; - if (types.isUndefinedOrNull(direction)) { - editorsToClose = group.getEditors().filter(e => !except || !e.matches(except)); + if (types.isUndefinedOrNull(filter.direction)) { + editorsToClose = editors.filter(e => !filter.except || !e.matches(filter.except)); } else { - editorsToClose = (direction === Direction.LEFT) ? group.getEditors().slice(0, group.indexOf(except)) : group.getEditors().slice(group.indexOf(except) + 1); + editorsToClose = (filter.direction === Direction.LEFT) ? editors.slice(0, group.indexOf(filter.except)) : editors.slice(group.indexOf(filter.except) + 1); } return this.handleDirty(editorsToClose.map(editor => { return { group, editor }; }), true /* ignore if opened in other group */).then(veto => { @@ -684,14 +689,26 @@ export class EditorPart extends Part implements IEditorPart, IEditorGroupService return; } - this.doCloseEditors(group, except, direction); + this.doCloseEditors(group, filter); }); } - private doCloseEditors(group: EditorGroup, except?: EditorInput, direction?: Direction): void { + private doCloseEditors(group: EditorGroup, filter: { except?: EditorInput, direction?: Direction, unmodifiedOnly?: boolean } = Object.create(null)): void { + + // Close all editors if there is no editor to except and + // we either are not only closing unmodified editors or + // there are no dirty editors. + let closeAllEditors = false; + if (!filter.except) { + if (!filter.unmodifiedOnly) { + closeAllEditors = true; + } else { + closeAllEditors = !group.getEditors().some(e => e.isDirty()); + } + } // Close all editors in group - if (!except) { + if (closeAllEditors) { // Update stacks model: remove all non active editors first to prevent opening the next editor in group group.closeEditors(group.activeEditor); @@ -700,23 +717,42 @@ export class EditorPart extends Part implements IEditorPart, IEditorGroupService this.doCloseActiveEditor(group); } + // Close unmodified editors in group + else if (filter.unmodifiedOnly) { + + // We can just close all unmodified editors around the currently active dirty one + if (group.activeEditor.isDirty()) { + group.getEditors().filter(editor => !editor.isDirty() && !editor.matches(filter.except)).forEach(editor => this.doCloseInactiveEditor(group, editor)); + } + + // Active editor is also a candidate to close, thus we make the first dirty editor + // active and then close the other ones + else { + const firstDirtyEditor = group.getEditors().filter(editor => editor.isDirty())[0]; + + this.openEditor(firstDirtyEditor, null, this.stacks.positionOfGroup(group)).done(() => { + this.doCloseEditors(group, filter); + }, errors.onUnexpectedError); + } + } + // Close all editors in group except active one - else if (except.matches(group.activeEditor)) { + else if (filter.except && filter.except.matches(group.activeEditor)) { // Update stacks model: close non active editors supporting the direction - group.closeEditors(group.activeEditor, direction); + group.closeEditors(group.activeEditor, filter.direction); } // Finally: we are asked to close editors around a non-active editor // Thus we make the non-active one active and then close the others else { - this.openEditor(except, null, this.stacks.positionOfGroup(group)).done(() => { + this.openEditor(filter.except, null, this.stacks.positionOfGroup(group)).done(() => { // since the opening might have failed, we have to check again for the active editor // being the expected one, otherwise we end up in an endless loop trying to open the // editor - if (except.matches(group.activeEditor)) { - this.doCloseEditors(group, except, direction); + if (filter.except.matches(group.activeEditor)) { + this.doCloseEditors(group, filter); } }, errors.onUnexpectedError); } diff --git a/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts b/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts index 1793a9c4a17..b735e56fe40 100644 --- a/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts +++ b/src/vs/workbench/browser/parts/editor/tabsTitleControl.ts @@ -152,7 +152,6 @@ export class TabsTitleControl extends TitleControl { vertical: ScrollbarVisibility.Hidden, scrollYToX: true, useShadows: false, - canUseTranslate3d: false, horizontalScrollbarSize: 3 }); diff --git a/src/vs/workbench/browser/parts/editor/titleControl.ts b/src/vs/workbench/browser/parts/editor/titleControl.ts index 12c13c861ed..a2a66110f4c 100644 --- a/src/vs/workbench/browser/parts/editor/titleControl.ts +++ b/src/vs/workbench/browser/parts/editor/titleControl.ts @@ -32,7 +32,7 @@ import { IQuickOpenService } from 'vs/platform/quickOpen/common/quickOpen'; import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { ResolvedKeybinding } from 'vs/base/common/keyCodes'; import { IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; -import { CloseEditorsInGroupAction, SplitEditorAction, CloseEditorAction, KeepEditorAction, CloseOtherEditorsInGroupAction, CloseRightEditorsInGroupAction, ShowEditorsInGroupAction } from 'vs/workbench/browser/parts/editor/editorActions'; +import { CloseEditorsInGroupAction, SplitEditorAction, CloseEditorAction, KeepEditorAction, CloseOtherEditorsInGroupAction, CloseRightEditorsInGroupAction, ShowEditorsInGroupAction, CloseUnmodifiedEditorsInGroupAction } from 'vs/workbench/browser/parts/editor/editorActions'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { createActionItem, fillInActions } from 'vs/platform/actions/browser/menuItemActionItem'; import { IMenuService, MenuId, IMenu, ExecuteCommandAction } from 'vs/platform/actions/common/actions'; @@ -71,6 +71,7 @@ export abstract class TitleControl extends Themable implements ITitleAreaControl protected pinEditorAction: KeepEditorAction; protected closeOtherEditorsAction: CloseOtherEditorsInGroupAction; protected closeRightEditorsAction: CloseRightEditorsInGroupAction; + protected closeUnmodifiedEditorsInGroupAction: CloseUnmodifiedEditorsInGroupAction; protected closeEditorsInGroupAction: CloseEditorsInGroupAction; protected splitEditorAction: SplitEditorAction; protected showEditorsInGroupAction: ShowEditorsInGroupAction; @@ -228,6 +229,7 @@ export abstract class TitleControl extends Themable implements ITitleAreaControl this.closeOtherEditorsAction = services.createInstance(CloseOtherEditorsInGroupAction, CloseOtherEditorsInGroupAction.ID, nls.localize('closeOthers', "Close Others")); this.closeRightEditorsAction = services.createInstance(CloseRightEditorsInGroupAction, CloseRightEditorsInGroupAction.ID, nls.localize('closeRight', "Close to the Right")); this.closeEditorsInGroupAction = services.createInstance(CloseEditorsInGroupAction, CloseEditorsInGroupAction.ID, nls.localize('closeAll', "Close All")); + this.closeUnmodifiedEditorsInGroupAction = services.createInstance(CloseUnmodifiedEditorsInGroupAction, CloseUnmodifiedEditorsInGroupAction.ID, nls.localize('closeAllUnmodified', "Close Unmodified")); this.pinEditorAction = services.createInstance(KeepEditorAction, KeepEditorAction.ID, nls.localize('keepOpen', "Keep Open")); this.showEditorsInGroupAction = services.createInstance(ShowEditorsInGroupAction, ShowEditorsInGroupAction.ID, nls.localize('showOpenedEditors', "Show Opened Editors")); this.splitEditorAction = services.createInstance(SplitEditorAction, SplitEditorAction.ID, SplitEditorAction.LABEL); @@ -355,6 +357,7 @@ export abstract class TitleControl extends Themable implements ITitleAreaControl } secondaryEditorActions.push(this.showEditorsInGroupAction); secondaryEditorActions.push(new Separator()); + secondaryEditorActions.push(this.closeUnmodifiedEditorsInGroupAction); secondaryEditorActions.push(this.closeEditorsInGroupAction); } @@ -440,6 +443,7 @@ export abstract class TitleControl extends Themable implements ITitleAreaControl actions.push(this.closeRightEditorsAction); } + actions.push(this.closeUnmodifiedEditorsInGroupAction); actions.push(this.closeEditorsInGroupAction); if (tabOptions.previewEditors) { @@ -461,6 +465,7 @@ export abstract class TitleControl extends Themable implements ITitleAreaControl this.showEditorsInGroupAction, this.closeEditorAction, this.closeRightEditorsAction, + this.closeUnmodifiedEditorsInGroupAction, this.closeOtherEditorsAction, this.closeEditorsInGroupAction, this.pinEditorAction diff --git a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts index 7a7872472ce..b8da38bc822 100644 --- a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts +++ b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts @@ -56,6 +56,7 @@ import { IEnvironmentService } from 'vs/platform/environment/common/environment' const HELP_PREFIX = '?'; interface IInternalPickOptions { + contextKey?: string; value?: string; valueSelection?: [number, number]; placeHolder?: string; @@ -84,6 +85,7 @@ export class QuickOpenController extends Component implements IQuickOpenService private pickOpenWidget: QuickOpenWidget; private layoutDimensions: Dimension; private mapResolvedHandlersToPrefix: { [prefix: string]: TPromise; }; + private mapContextKeyToContext: { [id: string]: IContextKey; }; private handlerOnOpenCalled: { [prefix: string]: boolean; }; private currentResultToken: string; private currentPickerToken: string; @@ -100,7 +102,7 @@ export class QuickOpenController extends Component implements IQuickOpenService @IMessageService private messageService: IMessageService, @ITelemetryService private telemetryService: ITelemetryService, @IWorkspaceContextService private contextService: IWorkspaceContextService, - @IContextKeyService contextKeyService: IContextKeyService, + @IContextKeyService private contextKeyService: IContextKeyService, @IConfigurationService private configurationService: IConfigurationService, @IHistoryService private historyService: IHistoryService, @IInstantiationService private instantiationService: IInstantiationService, @@ -112,6 +114,7 @@ export class QuickOpenController extends Component implements IQuickOpenService this.mapResolvedHandlersToPrefix = {}; this.handlerOnOpenCalled = {}; + this.mapContextKeyToContext = {}; this.promisesToCompleteOnHide = []; @@ -268,6 +271,9 @@ export class QuickOpenController extends Component implements IQuickOpenService const currentPickerToken = defaultGenerator.nextId(); this.currentPickerToken = currentPickerToken; + // Update context + this.setQuickOpenContextKey(options.contextKey); + // Create upon first open if (!this.pickOpenWidget) { this.pickOpenWidget = new QuickOpenWidget( @@ -578,6 +584,10 @@ export class QuickOpenController extends Component implements IQuickOpenService autoFocus = { autoFocusFirstEntry: visibleEditorCount === 0, autoFocusSecondEntry: visibleEditorCount !== 0 }; } + // Update context + const registry = Registry.as(Extensions.Quickopen); + this.setQuickOpenContextKey(registry.getDefaultQuickOpenHandler().contextKey); + this.quickOpenWidget.show(editorHistory, { quickNavigateConfiguration, autoFocus, inputSelection }); } } @@ -625,8 +635,8 @@ export class QuickOpenController extends Component implements IQuickOpenService const promise = this.mapResolvedHandlersToPrefix[prefix]; promise.then(handler => { this.handlerOnOpenCalled[prefix] = false; - // Don't check if onOpen was called to preserve old behaviour for now - handler.onClose(reason === HideReason.CANCELED); + + handler.onClose(reason === HideReason.CANCELED); // Don't check if onOpen was called to preserve old behaviour for now }); } } @@ -641,10 +651,39 @@ export class QuickOpenController extends Component implements IQuickOpenService this.restoreFocus(); // focus back to editor unless user clicked somewhere else } + // Reset context keys this.inQuickOpenMode.reset(); + this.resetQuickOpenContextKeys(); + + // Events this.emitQuickOpenVisibilityChange(false); } + private resetQuickOpenContextKeys(): void { + Object.keys(this.mapContextKeyToContext).forEach(k => this.mapContextKeyToContext[k].reset()); + } + + private setQuickOpenContextKey(id?: string): void { + let key: IContextKey; + if (id) { + key = this.mapContextKeyToContext[id]; + if (!key) { + key = new RawContextKey(id, false).bindTo(this.contextKeyService); + this.mapContextKeyToContext[id] = key; + } + } + + if (key && key.get()) { + return; // already active context + } + + this.resetQuickOpenContextKeys(); + + if (key) { + key.set(true); + } + } + private hasHandler(prefix: string): boolean { return !!Registry.as(Extensions.Quickopen).getQuickOpenHandler(prefix); } @@ -677,6 +716,7 @@ export class QuickOpenController extends Component implements IQuickOpenService const handlerDescriptor = registry.getQuickOpenHandler(value); const defaultHandlerDescriptor = registry.getDefaultQuickOpenHandler(); const instantProgress = handlerDescriptor && handlerDescriptor.instantProgress; + const contextKey = handlerDescriptor ? handlerDescriptor.contextKey : defaultHandlerDescriptor.contextKey; // Use a generated token to avoid race conditions from long running promises const currentResultToken = defaultGenerator.nextId(); @@ -690,6 +730,9 @@ export class QuickOpenController extends Component implements IQuickOpenService // Reset Extra Class this.quickOpenWidget.setExtraClass(null); + // Update context + this.setQuickOpenContextKey(contextKey); + // Remove leading and trailing whitespace const trimmedValue = strings.trim(value); @@ -701,6 +744,7 @@ export class QuickOpenController extends Component implements IQuickOpenService .done(null, errors.onUnexpectedError); this.quickOpenWidget.setInput(this.getEditorHistoryWithGroupLabel(), { autoFocusFirstEntry: true }); + return; } diff --git a/src/vs/workbench/browser/parts/quickopen/quickopen.contribution.ts b/src/vs/workbench/browser/parts/quickopen/quickopen.contribution.ts index 6d696c729c0..e263e028e10 100644 --- a/src/vs/workbench/browser/parts/quickopen/quickopen.contribution.ts +++ b/src/vs/workbench/browser/parts/quickopen/quickopen.contribution.ts @@ -5,121 +5,13 @@ 'use strict'; import { Registry } from 'vs/platform/platform'; -import { TPromise } from 'vs/base/common/winjs.base'; -import nls = require('vs/nls'); -import { Action } from 'vs/base/common/actions'; import { IQuickOpenService } from 'vs/platform/quickOpen/common/quickOpen'; -import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; -import { ContextKeyExpr } from 'vs/platform/contextkey/common/contextkey'; import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; import { KeyMod, KeyCode } from 'vs/base/common/keyCodes'; import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/workbench/common/actionRegistry'; -import { KeybindingsRegistry, IKeybindings } from 'vs/platform/keybinding/common/keybindingsRegistry'; +import { KeybindingsRegistry } from 'vs/platform/keybinding/common/keybindingsRegistry'; import { RemoveFromEditorHistoryAction } from 'vs/workbench/browser/parts/quickopen/quickOpenController'; - -export class GlobalQuickOpenAction extends Action { - - public static ID = 'workbench.action.quickOpen'; - public static LABEL = nls.localize('quickOpen', "Go to File..."); - - constructor(id: string, label: string, @IQuickOpenService private quickOpenService: IQuickOpenService) { - super(id, label); - - this.order = 100; // Allow other actions to position before or after - this.class = 'quickopen'; - } - - public run(): TPromise { - this.quickOpenService.show(null); - - return TPromise.as(true); - } -} - -export class BaseQuickOpenNavigateAction extends Action { - - constructor( - id: string, - label: string, - private next: boolean, - private quickNavigate: boolean, - @IQuickOpenService private quickOpenService: IQuickOpenService, - @IKeybindingService private keybindingService: IKeybindingService - ) { - super(id, label); - } - - public run(event?: any): TPromise { - const keys = this.keybindingService.lookupKeybindings(this.id); - const quickNavigate = this.quickNavigate ? { keybindings: keys } : void 0; - - this.quickOpenService.navigate(this.next, quickNavigate); - - return TPromise.as(true); - } -} - -export class QuickOpenNavigateNextAction extends BaseQuickOpenNavigateAction { - - public static ID = 'workbench.action.quickOpenNavigateNext'; - public static LABEL = nls.localize('quickNavigateNext', "Navigate Next in Quick Open"); - - constructor( - id: string, - label: string, - @IQuickOpenService quickOpenService: IQuickOpenService, - @IKeybindingService keybindingService: IKeybindingService - ) { - super(id, label, true, true, quickOpenService, keybindingService); - } -} - -export class QuickOpenNavigatePreviousAction extends BaseQuickOpenNavigateAction { - - public static ID = 'workbench.action.quickOpenNavigatePrevious'; - public static LABEL = nls.localize('quickNavigatePrevious', "Navigate Previous in Quick Open"); - - constructor( - id: string, - label: string, - @IQuickOpenService quickOpenService: IQuickOpenService, - @IKeybindingService keybindingService: IKeybindingService - ) { - super(id, label, false, true, quickOpenService, keybindingService); - } -} - -export class QuickOpenSelectNextAction extends BaseQuickOpenNavigateAction { - - public static ID = 'workbench.action.quickOpenSelectNext'; - public static LABEL = nls.localize('quickSelectNext', "Select Next in Quick Open"); - - constructor( - id: string, - label: string, - @IQuickOpenService quickOpenService: IQuickOpenService, - @IKeybindingService keybindingService: IKeybindingService - ) { - super(id, label, true, false, quickOpenService, keybindingService); - } -} - -export class QuickOpenSelectPreviousAction extends BaseQuickOpenNavigateAction { - - public static ID = 'workbench.action.quickOpenSelectPrevious'; - public static LABEL = nls.localize('quickSelectPrevious', "Select Previous in Quick Open"); - - constructor( - id: string, - label: string, - @IQuickOpenService quickOpenService: IQuickOpenService, - @IKeybindingService keybindingService: IKeybindingService - ) { - super(id, label, false, false, quickOpenService, keybindingService); - } -} - -const inQuickOpenContext = ContextKeyExpr.has('inQuickOpen'); +import { GlobalQuickOpenAction, QuickOpenSelectNextAction, QuickOpenSelectPreviousAction, inQuickOpenContext, getQuickNavigateHandler, QuickOpenNavigateNextAction, QuickOpenNavigatePreviousAction, defaultQuickOpenContext } from "vs/workbench/browser/parts/quickopen/quickopen"; KeybindingsRegistry.registerCommandAndKeybindingRule({ id: 'workbench.action.closeQuickOpen', @@ -154,41 +46,38 @@ KeybindingsRegistry.registerCommandAndKeybindingRule({ } }); -function navigateKeybinding(shift: boolean): IKeybindings { - if (!shift) { - return { - primary: KeyMod.CtrlCmd | KeyCode.Tab, - secondary: [KeyMod.CtrlCmd | KeyCode.KEY_Q, KeyMod.CtrlCmd | KeyCode.KEY_E, KeyMod.CtrlCmd | KeyCode.KEY_P], - mac: { - primary: KeyMod.WinCtrl | KeyCode.Tab, - secondary: [KeyMod.WinCtrl | KeyCode.KEY_Q, KeyMod.CtrlCmd | KeyCode.KEY_P] - }, - linux: { - primary: KeyMod.CtrlCmd | KeyCode.Tab, - secondary: [KeyMod.CtrlCmd | KeyCode.KEY_E, KeyMod.CtrlCmd | KeyCode.KEY_P] - } - }; - } - - return { - primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.Tab, - secondary: [KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_Q, KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_E, KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_P], - mac: { - primary: KeyMod.WinCtrl | KeyMod.Shift | KeyCode.Tab, - secondary: [KeyMod.WinCtrl | KeyMod.Shift | KeyCode.KEY_Q, KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_P] - }, - linux: { - primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.Tab, - secondary: [KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_E, KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_P] - } - }; -} - const registry = Registry.as(ActionExtensions.WorkbenchActions); -registry.registerWorkbenchAction(new SyncActionDescriptor(GlobalQuickOpenAction, GlobalQuickOpenAction.ID, GlobalQuickOpenAction.LABEL, { primary: KeyMod.CtrlCmd | KeyCode.KEY_P, secondary: [KeyMod.CtrlCmd | KeyCode.KEY_E], mac: { primary: KeyMod.CtrlCmd | KeyCode.KEY_P, secondary: null } }), 'Go to File...'); -registry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenNavigateNextAction, QuickOpenNavigateNextAction.ID, QuickOpenNavigateNextAction.LABEL, navigateKeybinding(false), inQuickOpenContext, KeybindingsRegistry.WEIGHT.workbenchContrib(50)), 'Navigate Next in Quick Open'); -registry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenNavigatePreviousAction, QuickOpenNavigatePreviousAction.ID, QuickOpenNavigatePreviousAction.LABEL, navigateKeybinding(true), inQuickOpenContext, KeybindingsRegistry.WEIGHT.workbenchContrib(50)), 'Navigate Previous in Quick Open'); +const globalQuickOpenKeybinding = { primary: KeyMod.CtrlCmd | KeyCode.KEY_P, secondary: [KeyMod.CtrlCmd | KeyCode.KEY_E], mac: { primary: KeyMod.CtrlCmd | KeyCode.KEY_P, secondary: null } }; + +registry.registerWorkbenchAction(new SyncActionDescriptor(GlobalQuickOpenAction, GlobalQuickOpenAction.ID, GlobalQuickOpenAction.LABEL, globalQuickOpenKeybinding), 'Go to File...'); registry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenSelectNextAction, QuickOpenSelectNextAction.ID, QuickOpenSelectNextAction.LABEL, { primary: null, mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_N } }, inQuickOpenContext, KeybindingsRegistry.WEIGHT.workbenchContrib(50)), 'Select Next in Quick Open'); registry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenSelectPreviousAction, QuickOpenSelectPreviousAction.ID, QuickOpenSelectPreviousAction.LABEL, { primary: null, mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_P } }, inQuickOpenContext, KeybindingsRegistry.WEIGHT.workbenchContrib(50)), 'Select Previous in Quick Open'); +registry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenNavigateNextAction, QuickOpenNavigateNextAction.ID, QuickOpenNavigateNextAction.LABEL), 'Navigate Next in Quick Open'); +registry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenNavigatePreviousAction, QuickOpenNavigatePreviousAction.ID, QuickOpenNavigatePreviousAction.LABEL), 'Navigate Previous in Quick Open'); registry.registerWorkbenchAction(new SyncActionDescriptor(RemoveFromEditorHistoryAction, RemoveFromEditorHistoryAction.ID, RemoveFromEditorHistoryAction.LABEL), 'Remove From History'); + +const quickOpenNavigateNextInFilePickerId = 'workbench.action.quickOpenNavigateNextInFilePicker'; +KeybindingsRegistry.registerCommandAndKeybindingRule({ + id: quickOpenNavigateNextInFilePickerId, + weight: KeybindingsRegistry.WEIGHT.workbenchContrib(50), + handler: getQuickNavigateHandler(quickOpenNavigateNextInFilePickerId, true), + when: defaultQuickOpenContext, + primary: globalQuickOpenKeybinding.primary, + secondary: globalQuickOpenKeybinding.secondary, + mac: globalQuickOpenKeybinding.mac +}); + +const quickOpenNavigatePreviousInFilePickerId = 'workbench.action.quickOpenNavigatePreviousInFilePicker'; +KeybindingsRegistry.registerCommandAndKeybindingRule({ + id: quickOpenNavigatePreviousInFilePickerId, + weight: KeybindingsRegistry.WEIGHT.workbenchContrib(50), + handler: getQuickNavigateHandler(quickOpenNavigatePreviousInFilePickerId, false), + when: defaultQuickOpenContext, + primary: globalQuickOpenKeybinding.primary | KeyMod.Shift, + secondary: [globalQuickOpenKeybinding.secondary[0] | KeyMod.Shift], + mac: { + primary: globalQuickOpenKeybinding.mac.primary | KeyMod.Shift, + secondary: null + } +}); \ No newline at end of file diff --git a/src/vs/workbench/browser/parts/quickopen/quickopen.ts b/src/vs/workbench/browser/parts/quickopen/quickopen.ts new file mode 100644 index 00000000000..be16c8f57b2 --- /dev/null +++ b/src/vs/workbench/browser/parts/quickopen/quickopen.ts @@ -0,0 +1,132 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +'use strict'; + +import { TPromise } from 'vs/base/common/winjs.base'; +import nls = require('vs/nls'); +import { Action } from 'vs/base/common/actions'; +import { IQuickOpenService } from 'vs/platform/quickOpen/common/quickOpen'; +import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; +import { ContextKeyExpr } from "vs/platform/contextkey/common/contextkey"; +import { ICommandHandler } from "vs/platform/commands/common/commands"; + +export const inQuickOpenContext = ContextKeyExpr.has('inQuickOpen'); +export const defaultQuickOpenContextKey = 'inFilesPicker'; +export const defaultQuickOpenContext = ContextKeyExpr.and(inQuickOpenContext, ContextKeyExpr.has(defaultQuickOpenContextKey)); + +export class GlobalQuickOpenAction extends Action { + + public static ID = 'workbench.action.quickOpen'; + public static LABEL = nls.localize('quickOpen', "Go to File..."); + + constructor(id: string, label: string, @IQuickOpenService private quickOpenService: IQuickOpenService) { + super(id, label); + + this.order = 100; // Allow other actions to position before or after + this.class = 'quickopen'; + } + + public run(): TPromise { + this.quickOpenService.show(null); + + return TPromise.as(true); + } +} + +export class BaseQuickOpenNavigateAction extends Action { + + constructor( + id: string, + label: string, + private next: boolean, + private quickNavigate: boolean, + @IQuickOpenService private quickOpenService: IQuickOpenService, + @IKeybindingService private keybindingService: IKeybindingService + ) { + super(id, label); + } + + public run(event?: any): TPromise { + const keys = this.keybindingService.lookupKeybindings(this.id); + const quickNavigate = this.quickNavigate ? { keybindings: keys } : void 0; + + this.quickOpenService.navigate(this.next, quickNavigate); + + return TPromise.as(true); + } +} + +export function getQuickNavigateHandler(id: string, next?: boolean): ICommandHandler { + return accessor => { + const keybindingService = accessor.get(IKeybindingService); + const quickOpenService = accessor.get(IQuickOpenService); + + const keys = keybindingService.lookupKeybindings(id); + const quickNavigate = { keybindings: keys }; + + quickOpenService.navigate(next, quickNavigate); + }; +} + +export class QuickOpenNavigateNextAction extends BaseQuickOpenNavigateAction { + + public static ID = 'workbench.action.quickOpenNavigateNext'; + public static LABEL = nls.localize('quickNavigateNext', "Navigate Next in Quick Open"); + + constructor( + id: string, + label: string, + @IQuickOpenService quickOpenService: IQuickOpenService, + @IKeybindingService keybindingService: IKeybindingService + ) { + super(id, label, true, true, quickOpenService, keybindingService); + } +} + +export class QuickOpenNavigatePreviousAction extends BaseQuickOpenNavigateAction { + + public static ID = 'workbench.action.quickOpenNavigatePrevious'; + public static LABEL = nls.localize('quickNavigatePrevious', "Navigate Previous in Quick Open"); + + constructor( + id: string, + label: string, + @IQuickOpenService quickOpenService: IQuickOpenService, + @IKeybindingService keybindingService: IKeybindingService + ) { + super(id, label, false, true, quickOpenService, keybindingService); + } +} + +export class QuickOpenSelectNextAction extends BaseQuickOpenNavigateAction { + + public static ID = 'workbench.action.quickOpenSelectNext'; + public static LABEL = nls.localize('quickSelectNext', "Select Next in Quick Open"); + + constructor( + id: string, + label: string, + @IQuickOpenService quickOpenService: IQuickOpenService, + @IKeybindingService keybindingService: IKeybindingService + ) { + super(id, label, true, false, quickOpenService, keybindingService); + } +} + +export class QuickOpenSelectPreviousAction extends BaseQuickOpenNavigateAction { + + public static ID = 'workbench.action.quickOpenSelectPrevious'; + public static LABEL = nls.localize('quickSelectPrevious', "Select Previous in Quick Open"); + + constructor( + id: string, + label: string, + @IQuickOpenService quickOpenService: IQuickOpenService, + @IKeybindingService keybindingService: IKeybindingService + ) { + super(id, label, false, false, quickOpenService, keybindingService); + } +} \ No newline at end of file diff --git a/src/vs/workbench/browser/quickopen.ts b/src/vs/workbench/browser/quickopen.ts index 152265f629a..62941ff5712 100644 --- a/src/vs/workbench/browser/quickopen.ts +++ b/src/vs/workbench/browser/quickopen.ts @@ -131,18 +131,21 @@ export interface QuickOpenHandlerHelpEntry { export class QuickOpenHandlerDescriptor extends AsyncDescriptor { public prefix: string; public description: string; + public contextKey: string; public isDefault: boolean; public helpEntries: QuickOpenHandlerHelpEntry[]; public instantProgress: boolean; + private id: string; - constructor(moduleId: string, ctorName: string, prefix: string, description: string, instantProgress?: boolean); - constructor(moduleId: string, ctorName: string, prefix: string, helpEntries: QuickOpenHandlerHelpEntry[], instantProgress?: boolean); - constructor(moduleId: string, ctorName: string, prefix: string, param: any, instantProgress: boolean = false) { + constructor(moduleId: string, ctorName: string, prefix: string, contextKey: string, description: string, instantProgress?: boolean); + constructor(moduleId: string, ctorName: string, prefix: string, contextKey: string, helpEntries: QuickOpenHandlerHelpEntry[], instantProgress?: boolean); + constructor(moduleId: string, ctorName: string, prefix: string, contextKey: string, param: any, instantProgress: boolean = false) { super(moduleId, ctorName); - this.prefix = prefix; this.id = moduleId + ctorName; + this.prefix = prefix; + this.contextKey = contextKey; this.instantProgress = instantProgress; if (types.isString(param)) { diff --git a/src/vs/workbench/common/editor/editorStacksModel.ts b/src/vs/workbench/common/editor/editorStacksModel.ts index c6bd0d5602b..dd41ad0eb1e 100644 --- a/src/vs/workbench/common/editor/editorStacksModel.ts +++ b/src/vs/workbench/common/editor/editorStacksModel.ts @@ -277,8 +277,7 @@ export class EditorGroup implements IEditorGroup { targetIndex--; // accomodate for the fact that the preview editor closes } - this.closeEditor(this.preview, !makeActive); // optimization to prevent multiple setActive() in one call - this.splice(targetIndex, false, editor); + this.replaceEditor(this.preview, editor, targetIndex, !makeActive); } this.preview = editor; @@ -345,10 +344,31 @@ export class EditorGroup implements IEditorGroup { })); } + public replaceEditor(toReplace: EditorInput, replaceWidth: EditorInput, replaceIndex: number, openNext = true): void { + const event = this.doCloseEditor(toReplace, openNext); // optimization to prevent multiple setActive() in one call + + // We want to first add the new editor into our model before emitting the close event because + // firing the close event can trigger a dispose on the same editor that is now being added. + // This can lead into opening a disposed editor which is not what we want. + this.splice(replaceIndex, false, replaceWidth); + + if (event) { + this.fireEvent(this._onEditorClosed, event, true); + } + } + public closeEditor(editor: EditorInput, openNext = true): void { + const event = this.doCloseEditor(editor, openNext); + + if (event) { + this.fireEvent(this._onEditorClosed, event, true); + } + } + + private doCloseEditor(editor: EditorInput, openNext = true): EditorCloseEvent { const index = this.indexOf(editor); if (index === -1) { - return; // not found + return null; // not found } // Active Editor closed @@ -376,7 +396,7 @@ export class EditorGroup implements IEditorGroup { this.splice(index, true); // Event - this.fireEvent(this._onEditorClosed, { editor, pinned, index, group: this }, true); + return { editor, pinned, index, group: this }; } public closeEditors(except: EditorInput, direction?: Direction): void { diff --git a/src/vs/workbench/electron-browser/actions.ts b/src/vs/workbench/electron-browser/actions.ts index ef63d8a7cf6..3f8b05dab1f 100644 --- a/src/vs/workbench/electron-browser/actions.ts +++ b/src/vs/workbench/electron-browser/actions.ts @@ -591,6 +591,7 @@ export abstract class BaseSwitchWindow extends Action { } as IFilePickOpenEntry)); this.quickOpenService.pick(picks, { + contextKey: 'inWindowsPicker', autoFocus: { autoFocusFirstEntry: true }, placeHolder, quickNavigateConfiguration: this.isQuickNavigate() ? { keybindings: this.keybindingService.lookupKeybindings(this.id) } : void 0 @@ -641,6 +642,8 @@ export class QuickSwitchWindow extends BaseSwitchWindow { } } +export const inRecentFilesPickerContextKey = 'inRecentFilesPicker'; + export abstract class BaseOpenRecentAction extends Action { constructor( @@ -693,6 +696,7 @@ export abstract class BaseOpenRecentAction extends Action { const hasWorkspace = this.contextService.hasWorkspace(); this.quickOpenService.pick(folderPicks.concat(...filePicks), { + contextKey: inRecentFilesPickerContextKey, autoFocus: { autoFocusFirstEntry: !hasWorkspace, autoFocusSecondEntry: hasWorkspace }, placeHolder: isMacintosh ? nls.localize('openRecentPlaceHolderMac', "Select a path (hold Cmd-key to open in new window)") : nls.localize('openRecentPlaceHolder', "Select a path to open (hold Ctrl-key to open in new window)"), matchOnDescription: true, diff --git a/src/vs/workbench/electron-browser/extensionHost.ts b/src/vs/workbench/electron-browser/extensionHost.ts index 6b99c054bb7..fdf5531f05f 100644 --- a/src/vs/workbench/electron-browser/extensionHost.ts +++ b/src/vs/workbench/electron-browser/extensionHost.ts @@ -29,7 +29,7 @@ import { IMessagePassingProtocol } from 'vs/base/parts/ipc/common/ipc'; import { generateRandomPipeName, Protocol } from 'vs/base/parts/ipc/node/ipc.net'; import { createServer, Server } from 'net'; import Event, { Emitter } from 'vs/base/common/event'; -import { IInitData } from 'vs/workbench/api/node/extHost.protocol'; +import { IInitData, IWorkspaceData } from 'vs/workbench/api/node/extHost.protocol'; import { MainProcessExtensionService } from 'vs/workbench/api/electron-browser/mainThreadExtensionService'; import { IWorkspaceConfigurationService } from 'vs/workbench/services/configuration/common/configuration'; import { ICrashReporterService } from 'vs/workbench/services/crashReporter/common/crashReporterService'; @@ -259,7 +259,7 @@ export class ExtensionHostProcessWorker { enableProposedApiForAll: !this.environmentService.isBuilt || (!!this.environmentService.extensionDevelopmentPath && product.nameLong.indexOf('Insiders') >= 0), enableProposedApiFor: this.environmentService.args['enable-proposed-api'] || [] }, - workspace: this.contextService.getWorkspace(), + workspace: this.contextService.getWorkspace2(), extensions: extensionDescriptions, configuration: this.configurationService.values(), telemetryInfo diff --git a/src/vs/workbench/electron-browser/main.ts b/src/vs/workbench/electron-browser/main.ts index cf9c5e45db7..cf8ae033c6d 100644 --- a/src/vs/workbench/electron-browser/main.ts +++ b/src/vs/workbench/electron-browser/main.ts @@ -28,6 +28,9 @@ import { IInitData } from 'vs/workbench/services/timer/common/timerService'; import { TimerService } from 'vs/workbench/services/timer/node/timerService'; import { KeyboardMapperFactory } from "vs/workbench/services/keybinding/electron-browser/keybindingService"; import { IWindowConfiguration, IPath } from "vs/platform/windows/common/windows"; +import { IStorageService } from "vs/platform/storage/common/storage"; +import { IEnvironmentService } from "vs/platform/environment/common/environment"; +import { StorageService, inMemoryLocalStorageInstance, IWorkspaceStorageIdentifier } from "vs/platform/storage/common/storageService"; import { webFrame } from 'electron'; @@ -62,12 +65,8 @@ export function startup(configuration: IWindowConfiguration): TPromise { filesToDiff }; - // Resolve workspace - return getWorkspace(configuration.workspacePath).then(workspace => { - - // Open workbench - return openWorkbench(configuration, workspace, shellOptions); - }); + // Open workbench + return openWorkbench(configuration, shellOptions); } function toInputs(paths: IPath[], isUntitledFile?: boolean): IResourceInput[] { @@ -95,12 +94,53 @@ function toInputs(paths: IPath[], isUntitledFile?: boolean): IResourceInput[] { }); } -function getWorkspace(workspacePath: string): TPromise { - if (!workspacePath) { +function openWorkbench(configuration: IWindowConfiguration, options: IOptions): TPromise { + return getWorkspace(configuration).then(workspace => { + const environmentService = new EnvironmentService(configuration, configuration.execPath); + const workspaceConfigurationService = new WorkspaceConfigurationService(environmentService, workspace); + const timerService = new TimerService((window).MonacoEnvironment.timers as IInitData, !workspaceConfigurationService.hasWorkspace()); + + return createStorageService(configuration, environmentService).then(storageService => { + + // Since the configuration service is one of the core services that is used in so many places, we initialize it + // right before startup of the workbench shell to have its data ready for consumers + return workspaceConfigurationService.initialize().then(() => { + timerService.beforeDOMContentLoaded = Date.now(); + + return domContentLoaded().then(() => { + timerService.afterDOMContentLoaded = Date.now(); + + // Open Shell + timerService.beforeWorkbenchOpen = Date.now(); + const shell = new WorkbenchShell(document.body, { + contextService: workspaceConfigurationService, + configurationService: workspaceConfigurationService, + environmentService, + timerService, + storageService + }, configuration, options); + shell.open(); + + // Inform user about loading issues from the loader + (self).require.config({ + onError: (err: any) => { + if (err.errorCode === 'load') { + shell.onUnexpectedError(loaderError(err)); + } + } + }); + }); + }); + }); + }); +} + +function getWorkspace(configuration: IWindowConfiguration): TPromise { + if (!configuration.workspacePath) { return TPromise.as(null); } - return realpath(workspacePath).then(realWorkspacePath => { + return realpath(configuration.workspacePath).then(realWorkspacePath => { // for some weird reason, node adds a trailing slash to UNC paths // we never ever want trailing slashes as our workspace path unless @@ -110,16 +150,13 @@ function getWorkspace(workspacePath: string): TPromise { realWorkspacePath = strings.rtrim(realWorkspacePath, paths.nativeSep); } + // update config + configuration.workspacePath = realWorkspacePath; + const workspaceResource = uri.file(realWorkspacePath); const folderName = path.basename(realWorkspacePath) || realWorkspacePath; - return stat(realWorkspacePath).then(folderStat => { - return new Workspace( - workspaceResource, - platform.isLinux ? folderStat.ino : folderStat.birthtime.getTime(), - folderName // On Linux, birthtime is ctime, so we cannot use it! We use the ino instead! - ); - }); + return new Workspace(workspaceResource, folderName); }, error => { errors.onUnexpectedError(error); @@ -127,38 +164,30 @@ function getWorkspace(workspacePath: string): TPromise { }); } -function openWorkbench(configuration: IWindowConfiguration, workspace: Workspace, options: IOptions): TPromise { - const environmentService = new EnvironmentService(configuration, configuration.execPath); - const workspaceConfigurationService = new WorkspaceConfigurationService(environmentService, workspace); - const timerService = new TimerService((window).MonacoEnvironment.timers as IInitData, !workspaceConfigurationService.hasWorkspace()); - - // Since the configuration service is one of the core services that is used in so many places, we initialize it - // right before startup of the workbench shell to have its data ready for consumers - return workspaceConfigurationService.initialize().then(() => { - timerService.beforeDOMContentLoaded = Date.now(); - - return domContentLoaded().then(() => { - timerService.afterDOMContentLoaded = Date.now(); - - // Open Shell - timerService.beforeWorkbenchOpen = Date.now(); - const shell = new WorkbenchShell(document.body, { - contextService: workspaceConfigurationService, - configurationService: workspaceConfigurationService, - environmentService, - timerService - }, configuration, options); - shell.open(); - - // Inform user about loading issues from the loader - (self).require.config({ - onError: (err: any) => { - if (err.errorCode === 'load') { - shell.onUnexpectedError(loaderError(err)); - } - } - }); - }); +function createStorageService(configuration: IWindowConfiguration, environmentService: IEnvironmentService): TPromise { + let workspaceStatPromise: TPromise = TPromise.as(null); + if (configuration.workspacePath) { + workspaceStatPromise = stat(configuration.workspacePath); + } + + return workspaceStatPromise.then(stat => { + let id: IWorkspaceStorageIdentifier; + if (stat) { + id = { resource: uri.file(configuration.workspacePath), uid: platform.isLinux ? stat.ino : stat.birthtime.getTime() }; + } else if (configuration.backupPath) { + // if we do not have a workspace open, we need to find another identifier for the window to store + // workspace UI state. if we have a backup path in the configuration we can use that because this + // will be a unique identifier per window that is stable between restarts as long as there are + // dirty files in the workspace. + // We use basename() to produce a short identifier, we do not need the full path. We use a custom + // scheme so that we can later distinguish these identifiers from the workspace one. + id = { resource: uri.from({ path: path.basename(configuration.backupPath), scheme: 'empty' }) }; + } + + const disableStorage = !!environmentService.extensionTestsPath; // never keep any state when running extension tests! + const storage = disableStorage ? inMemoryLocalStorageInstance : window.localStorage; + + return new StorageService(storage, storage, id); }); } diff --git a/src/vs/workbench/electron-browser/media/shell.css b/src/vs/workbench/electron-browser/media/shell.css index 5696fc87867..f734da27292 100644 --- a/src/vs/workbench/electron-browser/media/shell.css +++ b/src/vs/workbench/electron-browser/media/shell.css @@ -15,7 +15,7 @@ /* Font Families (with CJK support) */ -.monaco-shell { font-family: system-ui, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", "Ubuntu", "Droid Sans", sans-serif; } +.monaco-shell { font-family: -apple-system, BlinkMacSystemFont, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", "Ubuntu", "Droid Sans", sans-serif; } .monaco-shell:lang(zh-Hans) { font-family: -apple-system, BlinkMacSystemFont, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", "Noto Sans", "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", "Source Han Sans SC", "Source Han Sans CN", "Source Han Sans", sans-serif; } .monaco-shell:lang(zh-Hant) { font-family: -apple-system, BlinkMacSystemFont, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", "Noto Sans", "Microsoft Jhenghei", "PingFang TC", "Source Han Sans TC", "Source Han Sans", "Source Han Sans TW", sans-serif; } .monaco-shell:lang(ja) { font-family: -apple-system, BlinkMacSystemFont, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", "Noto Sans", "Meiryo", "Hiragino Kaku Gothic Pro", "Source Han Sans J", "Source Han Sans JP", "Source Han Sans", "Sazanami Gothic", "IPA Gothic", sans-serif; } diff --git a/src/vs/workbench/electron-browser/shell.ts b/src/vs/workbench/electron-browser/shell.ts index 141b3285c0a..015cc5f7bbd 100644 --- a/src/vs/workbench/electron-browser/shell.ts +++ b/src/vs/workbench/electron-browser/shell.ts @@ -21,7 +21,6 @@ import { SyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import pkg from 'vs/platform/node/package'; import { ContextViewService } from 'vs/platform/contextview/browser/contextViewService'; import { Workbench, IWorkbenchStartedInfo } from 'vs/workbench/electron-browser/workbench'; -import { StorageService, inMemoryLocalStorageInstance } from 'vs/platform/storage/common/storageService'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { NullTelemetryService, configurationTelemetry, loadExperiments, lifecycleTelemetry } from 'vs/platform/telemetry/common/telemetryUtils'; import { ITelemetryAppenderChannel, TelemetryAppenderClient } from 'vs/platform/telemetry/common/telemetryIpc'; @@ -89,8 +88,6 @@ import { IURLService } from 'vs/platform/url/common/url'; import { ExtensionHostProcessWorker } from 'vs/workbench/electron-browser/extensionHost'; import { ITimerService } from 'vs/workbench/services/timer/common/timerService'; import { remote, ipcRenderer as ipc } from 'electron'; -import URI from "vs/base/common/uri"; -import { basename } from "path"; import { ITextMateService } from 'vs/editor/node/textMate/textMateService'; import { MainProcessTextMateSyntax } from 'vs/editor/electron-browser/textMate/TMSyntax'; import { BareFontInfo } from 'vs/editor/common/config/fontInfo'; @@ -110,6 +107,7 @@ export interface ICoreServices { configurationService: IConfigurationService; environmentService: IEnvironmentService; timerService: ITimerService; + storageService: IStorageService; } const currentWindow = remote.getCurrentWindow(); @@ -155,6 +153,7 @@ export class WorkbenchShell { this.configurationService = services.configurationService; this.environmentService = services.environmentService; this.timerService = services.timerService; + this.storageService = services.storageService; this.toUnbind = []; this.previousErrorTime = 0; @@ -251,6 +250,7 @@ export class WorkbenchShell { serviceCollection.set(IConfigurationService, this.configurationService); serviceCollection.set(IEnvironmentService, this.environmentService); serviceCollection.set(ITimerService, this.timerService); + serviceCollection.set(IStorageService, this.storageService); const instantiationService: IInstantiationService = new InstantiationService(serviceCollection, true); @@ -273,22 +273,6 @@ export class WorkbenchShell { sharedProcess .done(client => client.registerChannel('choice', instantiationService.createInstance(ChoiceChannel))); - // Storage Sevice - let workspaceIdentifier = this.contextService.getWorkspace(); - if (!workspaceIdentifier && !!this.configuration.backupPath) { - // if we do not have a workspace open, we need to find another identifier for the window to store - // workspace UI state. if we have a backup path in the configuration we can use that because this - // will be a unique identifier per window that is stable between restarts as long as there are - // dirty files in the workspace. - // We use basename() to produce a short identifier, we do not need the full path. We use a custom - // scheme so that we can later distinguish these identifiers from the workspace one. - workspaceIdentifier = { resource: URI.from({ path: basename(this.configuration.backupPath), scheme: 'empty' }) }; - } - const disableStorage = !!this.environmentService.extensionTestsPath; // never keep any state when running extension tests! - const storage = disableStorage ? inMemoryLocalStorageInstance : window.localStorage; - this.storageService = new StorageService(storage, storage, workspaceIdentifier); - serviceCollection.set(IStorageService, this.storageService); - // Warm up font cache information before building up too many dom elements restoreFontInfo(this.storageService); readFontInfo(BareFontInfo.createFromRawSettings(this.configurationService.getConfiguration('editor'), browser.getZoomLevel())); diff --git a/src/vs/workbench/electron-browser/workbench.main.ts b/src/vs/workbench/electron-browser/workbench.main.ts index a8fee7959d0..d68ce2e3acf 100644 --- a/src/vs/workbench/electron-browser/workbench.main.ts +++ b/src/vs/workbench/electron-browser/workbench.main.ts @@ -31,6 +31,7 @@ import 'vs/workbench/parts/preferences/browser/preferences.contribution'; import 'vs/workbench/parts/preferences/browser/keybindingsEditorContribution'; import 'vs/workbench/browser/actions/configureLocale'; +import 'vs/workbench/browser/parts/quickopen/quickopen.contribution'; import 'vs/workbench/parts/quickopen/browser/quickopen.contribution'; import 'vs/workbench/browser/parts/editor/editorPicker'; diff --git a/src/vs/workbench/electron-browser/workbench.ts b/src/vs/workbench/electron-browser/workbench.ts index 3256b4b5152..277811b7aac 100644 --- a/src/vs/workbench/electron-browser/workbench.ts +++ b/src/vs/workbench/electron-browser/workbench.ts @@ -92,9 +92,11 @@ import { IContextMenuService } from 'vs/platform/contextview/browser/contextView import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IWorkbenchActionRegistry, Extensions } from 'vs/workbench/common/actionRegistry'; -import { OpenRecentAction, ToggleDevToolsAction, ReloadWindowAction } from "vs/workbench/electron-browser/actions"; +import { OpenRecentAction, ToggleDevToolsAction, ReloadWindowAction, inRecentFilesPickerContextKey } from "vs/workbench/electron-browser/actions"; import { KeyMod } from 'vs/base/common/keyCodes'; import { KeyCode } from 'vs/editor/common/standalone/standaloneBase'; +import { KeybindingsRegistry } from "vs/platform/keybinding/common/keybindingsRegistry"; +import { getQuickNavigateHandler, inQuickOpenContext } from "vs/workbench/browser/parts/quickopen/quickopen"; export const MessagesVisibleContext = new RawContextKey('globalMessageVisible', false); export const EditorsVisibleContext = new RawContextKey('editorIsOpen', false); @@ -393,6 +395,28 @@ export class Workbench implements IPartService { workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(ReloadWindowAction, ReloadWindowAction.ID, ReloadWindowAction.LABEL, isDeveloping ? { primary: KeyMod.CtrlCmd | KeyCode.KEY_R } : void 0), 'Reload Window'); workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(ToggleDevToolsAction, ToggleDevToolsAction.ID, ToggleDevToolsAction.LABEL, isDeveloping ? { primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_I, mac: { primary: KeyMod.CtrlCmd | KeyMod.Alt | KeyCode.KEY_I } } : void 0), 'Developer: Toggle Developer Tools', localize('developer', "Developer")); workbenchActionsRegistry.registerWorkbenchAction(new SyncActionDescriptor(OpenRecentAction, OpenRecentAction.ID, OpenRecentAction.LABEL, { primary: isDeveloping ? null : KeyMod.CtrlCmd | KeyCode.KEY_R, mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_R } }), 'File: Open Recent...', localize('file', "File")); + + const recentFilesPickerContext = ContextKeyExpr.and(inQuickOpenContext, ContextKeyExpr.has(inRecentFilesPickerContextKey)); + + const quickOpenNavigateNextInRecentFilesPickerId = 'workbench.action.quickOpenNavigateNextInRecentFilesPicker'; + KeybindingsRegistry.registerCommandAndKeybindingRule({ + id: quickOpenNavigateNextInRecentFilesPickerId, + weight: KeybindingsRegistry.WEIGHT.workbenchContrib(50), + handler: getQuickNavigateHandler(quickOpenNavigateNextInRecentFilesPickerId, true), + when: recentFilesPickerContext, + primary: KeyMod.CtrlCmd | KeyCode.KEY_R, + mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_R } + }); + + const quickOpenNavigatePreviousInRecentFilesPicker = 'workbench.action.quickOpenNavigatePreviousInRecentFilesPicker'; + KeybindingsRegistry.registerCommandAndKeybindingRule({ + id: quickOpenNavigatePreviousInRecentFilesPicker, + weight: KeybindingsRegistry.WEIGHT.workbenchContrib(50), + handler: getQuickNavigateHandler(quickOpenNavigatePreviousInRecentFilesPicker, false), + when: recentFilesPickerContext, + primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_R, + mac: { primary: KeyMod.WinCtrl | KeyMod.Shift | KeyCode.KEY_R } + }); } private resolveEditorsToOpen(): TPromise { diff --git a/src/vs/workbench/node/extensionHostMain.ts b/src/vs/workbench/node/extensionHostMain.ts index 7f4aa8b0094..5c361eb9b06 100644 --- a/src/vs/workbench/node/extensionHostMain.ts +++ b/src/vs/workbench/node/extensionHostMain.ts @@ -15,9 +15,8 @@ import { ExtHostThreadService } from 'vs/workbench/services/thread/common/extHos import { QueryType, ISearchQuery } from 'vs/platform/search/common/search'; import { DiskSearch } from 'vs/workbench/services/search/node/searchService'; import { RemoteTelemetryService } from 'vs/workbench/api/node/extHostTelemetry'; -import { IInitData, IEnvironment, MainContext } from 'vs/workbench/api/node/extHost.protocol'; +import { IInitData, IEnvironment, IWorkspaceData, MainContext } from 'vs/workbench/api/node/extHost.protocol'; import * as errors from 'vs/base/common/errors'; -import { IWorkspace } from "vs/platform/workspace/common/workspace"; const nativeExit = process.exit.bind(process); process.exit = function () { @@ -36,7 +35,7 @@ export class ExtensionHostMain { private _isTerminating: boolean = false; private _diskSearch: DiskSearch; - private _workspace: IWorkspace; + private _workspace: IWorkspaceData; private _environment: IEnvironment; private _extensionService: ExtHostExtensionService; @@ -101,11 +100,10 @@ export class ExtensionHostMain { } private handleWorkspaceContainsEagerExtensions(): TPromise { - if (!this._workspace || !this._workspace.resource) { + if (!this._workspace || this._workspace.roots.length === 0) { return TPromise.as(null); } - const folderPath = this._workspace.resource.fsPath; const desiredFilesMap: { [filename: string]: boolean; @@ -135,7 +133,7 @@ export class ExtensionHostMain { } const query: ISearchQuery = { - folderResources: [this._workspace.resource], + folderResources: this._workspace.roots, type: QueryType.File, maxResults: 1, includePattern: { [p]: true } @@ -143,7 +141,16 @@ export class ExtensionHostMain { return this._diskSearch.search(query).then(result => result.results.length ? p : undefined); } else { - return pfs.exists(join(folderPath, p)).then(exists => exists ? p : undefined); + // find exact path + return new TPromise(async resolve => { + for (const { fsPath } of this._workspace.roots) { + if (await pfs.exists(join(fsPath, p))) { + resolve(p); + return; + } + } + resolve(undefined); + }); } }); diff --git a/src/vs/workbench/parts/debug/browser/media/debugHover.css b/src/vs/workbench/parts/debug/browser/media/debugHover.css index a734651beab..6dd157e9449 100644 --- a/src/vs/workbench/parts/debug/browser/media/debugHover.css +++ b/src/vs/workbench/parts/debug/browser/media/debugHover.css @@ -26,7 +26,7 @@ word-break: normal; text-overflow: ellipsis; height: 18px; - overflow: hidden; + overflow: auto; border-bottom: 1px solid rgba(128, 128, 128, 0.35); } @@ -64,6 +64,8 @@ .monaco-editor .debug-hover-widget .value { white-space: pre-wrap; color: rgba(108, 108, 108, 0.8); + overflow: auto; + max-height: 500px; } .monaco-editor .debug-hover-widget .error { diff --git a/src/vs/workbench/parts/debug/electron-browser/debug.contribution.ts b/src/vs/workbench/parts/debug/electron-browser/debug.contribution.ts index 368615a85a9..c8c0e1831dd 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debug.contribution.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debug.contribution.ts @@ -137,6 +137,7 @@ registry.registerWorkbenchAction(new SyncActionDescriptor(SelectAndStartAction, 'vs/workbench/parts/debug/browser/debugQuickOpen', 'DebugQuickOpenHandler', 'debug ', + 'inLaunchConfigurationsPicker', nls.localize('debugCommands', "Debug Configuration") ) ); diff --git a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts index ce54f235ae5..6948d29a257 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugHover.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugHover.ts @@ -21,13 +21,13 @@ import { IDebugService, IExpression, IExpressionContainer } from 'vs/workbench/p import { Expression } from 'vs/workbench/parts/debug/common/debugModel'; import { VariablesRenderer, renderExpressionValue, VariablesDataSource } from 'vs/workbench/parts/debug/electron-browser/debugViewer'; import { IListService } from 'vs/platform/list/browser/listService'; +import { DomScrollableElement } from 'vs/base/browser/ui/scrollbar/scrollableElement'; import { attachListStyler, attachStylerCallback } from 'vs/platform/theme/common/styler'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { editorHoverBackground, editorHoverBorder } from 'vs/platform/theme/common/colorRegistry'; const $ = dom.$; const MAX_ELEMENTS_SHOWN = 18; -const MAX_VALUE_RENDER_LENGTH_IN_HOVER = 4096; export class DebugHoverWidget implements IContentWidget { @@ -46,6 +46,7 @@ export class DebugHoverWidget implements IContentWidget { private valueContainer: HTMLElement; private stoleFocus: boolean; private toDispose: lifecycle.IDisposable[]; + private scrollbar: DomScrollableElement; constructor( private editor: ICodeEditor, @@ -58,9 +59,12 @@ export class DebugHoverWidget implements IContentWidget { this.create(instantiationService); this.registerListeners(); - this.valueContainer = dom.append(this.domNode, $('.value')); + this.valueContainer = $('.value'); this.valueContainer.tabIndex = 0; this.valueContainer.setAttribute('role', 'tooltip'); + this.scrollbar = new DomScrollableElement(this.valueContainer, {}); + this.domNode.appendChild(this.scrollbar.getDomNode()); + this.toDispose.push(this.scrollbar); this._isVisible = false; this.showAtPosition = null; @@ -249,9 +253,9 @@ export class DebugHoverWidget implements IContentWidget { this.valueContainer.hidden = false; renderExpressionValue(expression, this.valueContainer, { showChanged: false, - maxValueLength: MAX_VALUE_RENDER_LENGTH_IN_HOVER, preserveWhitespace: true }); + this.scrollbar.scanDomNode(); this.valueContainer.title = ''; this.editor.layoutContentWidget(this); if (focus) { diff --git a/src/vs/workbench/parts/debug/electron-browser/debugService.ts b/src/vs/workbench/parts/debug/electron-browser/debugService.ts index 40c3ce62b05..a79f53cadd6 100644 --- a/src/vs/workbench/parts/debug/electron-browser/debugService.ts +++ b/src/vs/workbench/parts/debug/electron-browser/debugService.ts @@ -912,14 +912,12 @@ export class DebugService implements debug.IDebugService { let config = process.configuration; if (this.launchJsonChanged) { this.launchJsonChanged = false; - config = this.configurationManager.getConfiguration(process.configuration.name) || process.configuration; - if (config) { - // Take the type from the process since the debug extension might overwrite it #21316 - config.type = process.configuration.type; - config.noDebug = process.configuration.noDebug; - config.__restart = restartData; - } + config = this.configurationManager.getConfiguration(process.configuration.name) || config; + // Take the type from the process since the debug extension might overwrite it #21316 + config.type = process.configuration.type; + config.noDebug = process.configuration.noDebug; } + config.__restart = restartData; this.createProcess(config).then(() => c(null), err => e(err)); }, 300); }) diff --git a/src/vs/workbench/parts/extensions/browser/extensionEditor.ts b/src/vs/workbench/parts/extensions/browser/extensionEditor.ts index 9334cdb4f53..84274e3c76e 100644 --- a/src/vs/workbench/parts/extensions/browser/extensionEditor.ts +++ b/src/vs/workbench/parts/extensions/browser/extensionEditor.ts @@ -358,7 +358,7 @@ export class ExtensionEditor extends BaseEditor { return this.loadContents(() => this.extensionManifest.get() .then(manifest => { const content = $('div', { class: 'subcontent' }); - const scrollableContent = new DomScrollableElement(content, { canUseTranslate3d: false }); + const scrollableContent = new DomScrollableElement(content, {}); const layout = () => scrollableContent.scanDomNode(); const removeLayoutParticipant = arrays.insert(this.layoutParticipants, { layout }); @@ -396,7 +396,7 @@ export class ExtensionEditor extends BaseEditor { return this.loadContents(() => { return this.extensionDependencies.get().then(extensionDependencies => { const content = $('div', { class: 'subcontent' }); - const scrollableContent = new DomScrollableElement(content, { canUseTranslate3d: false }); + const scrollableContent = new DomScrollableElement(content, {}); append(this.content, scrollableContent.getDomNode()); this.contentDisposables.push(scrollableContent); diff --git a/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.ts b/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.ts index 34b56a366bb..e286fc06d05 100644 --- a/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.ts +++ b/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.ts @@ -59,6 +59,7 @@ Registry.as(Extensions.Quickopen).registerQuickOpenHandler( 'vs/workbench/parts/extensions/browser/extensionsQuickOpen', 'ExtensionsHandler', 'ext ', + null, localize('extensionsCommands', "Manage Extensions"), true ) @@ -69,6 +70,7 @@ Registry.as(Extensions.Quickopen).registerQuickOpenHandler( 'vs/workbench/parts/extensions/browser/extensionsQuickOpen', 'GalleryExtensionsHandler', 'ext install ', + null, localize('galleryExtensionsCommands', "Install Gallery Extensions"), true ) diff --git a/src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts b/src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts index 959e8c13aeb..432e5922ac3 100644 --- a/src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts +++ b/src/vs/workbench/parts/files/browser/views/openEditorsViewer.ts @@ -30,7 +30,7 @@ import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/edi import { EditorStacksModel, EditorGroup } from 'vs/workbench/common/editor/editorStacksModel'; import { SaveFileAction, RevertFileAction, SaveFileAsAction, OpenToSideAction, SelectResourceForCompareAction, CompareResourcesAction, SaveAllInGroupAction } from 'vs/workbench/parts/files/browser/fileActions'; import { IUntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; -import { CloseOtherEditorsInGroupAction, CloseEditorAction, CloseEditorsInGroupAction } from 'vs/workbench/browser/parts/editor/editorActions'; +import { CloseOtherEditorsInGroupAction, CloseEditorAction, CloseEditorsInGroupAction, CloseUnmodifiedEditorsInGroupAction } from 'vs/workbench/browser/parts/editor/editorActions'; const $ = dom.$; @@ -332,6 +332,7 @@ export class ActionProvider extends ContributableActionProvider { return [ saveAllAction, + this.instantiationService.createInstance(CloseUnmodifiedEditorsInGroupAction, CloseUnmodifiedEditorsInGroupAction.ID, CloseUnmodifiedEditorsInGroupAction.LABEL), this.instantiationService.createInstance(CloseEditorsInGroupAction, CloseEditorsInGroupAction.ID, CloseEditorsInGroupAction.LABEL) ]; } @@ -350,6 +351,7 @@ export class ActionProvider extends ContributableActionProvider { result.push(new Separator()); } + result.push(this.instantiationService.createInstance(CloseUnmodifiedEditorsInGroupAction, CloseUnmodifiedEditorsInGroupAction.ID, nls.localize('closeAllUnmodified', "Close Unmodified"))); result.push(this.instantiationService.createInstance(CloseEditorsInGroupAction, CloseEditorsInGroupAction.ID, nls.localize('closeAll', "Close All"))); } else { const openEditor = element; @@ -406,6 +408,7 @@ export class ActionProvider extends ContributableActionProvider { const closeOtherEditorsInGroupAction = this.instantiationService.createInstance(CloseOtherEditorsInGroupAction, CloseOtherEditorsInGroupAction.ID, nls.localize('closeOthers', "Close Others")); closeOtherEditorsInGroupAction.enabled = openEditor.editorGroup.count > 1; result.push(closeOtherEditorsInGroupAction); + result.push(this.instantiationService.createInstance(CloseUnmodifiedEditorsInGroupAction, CloseUnmodifiedEditorsInGroupAction.ID, nls.localize('closeAllUnmodified', "Close Unmodified"))); result.push(this.instantiationService.createInstance(CloseEditorsInGroupAction, CloseEditorsInGroupAction.ID, nls.localize('closeAll', "Close All"))); } diff --git a/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts b/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts index 21076a5084e..cf9fd534f85 100644 --- a/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts +++ b/src/vs/workbench/parts/quickopen/browser/commandsHandler.ts @@ -149,28 +149,6 @@ export class ShowAllCommandsAction extends Action { } } -export class ShowTasksAction extends Action { - - public static ID = 'workbench.action.showTasks'; - public static LABEL = nls.localize('showTasks', "Show Task Menu"); - - constructor( - id: string, - label: string, - @IQuickOpenService private quickOpenService: IQuickOpenService, - @IConfigurationService private configurationService: IConfigurationService - ) { - super(id, label); - } - - public run(context?: any): TPromise { - const value = `${ALL_COMMANDS_PREFIX}tasks`; - this.quickOpenService.show(value); - - return TPromise.as(null); - } -} - export class ClearCommandHistoryAction extends Action { public static ID = 'workbench.action.clearCommandHistory'; diff --git a/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts b/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts index e46b5cd8432..23c643f7d2b 100644 --- a/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts +++ b/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.ts @@ -13,10 +13,13 @@ import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/workbench/common/actionRegistry'; import { KeyMod, KeyCode } from 'vs/base/common/keyCodes'; import { GotoSymbolAction, GOTO_SYMBOL_PREFIX, SCOPE_PREFIX } from 'vs/workbench/parts/quickopen/browser/gotoSymbolHandler'; -import { ShowAllCommandsAction, ALL_COMMANDS_PREFIX, ClearCommandHistoryAction, ShowTasksAction } from 'vs/workbench/parts/quickopen/browser/commandsHandler'; +import { ShowAllCommandsAction, ALL_COMMANDS_PREFIX, ClearCommandHistoryAction } from 'vs/workbench/parts/quickopen/browser/commandsHandler'; import { GotoLineAction, GOTO_LINE_PREFIX } from 'vs/workbench/parts/quickopen/browser/gotoLineHandler'; import { HELP_PREFIX } from 'vs/workbench/parts/quickopen/browser/helpHandler'; import { VIEW_PICKER_PREFIX, OpenViewPickerAction, QuickOpenViewPickerAction } from 'vs/workbench/parts/quickopen/browser/viewPickerHandler'; +import { inQuickOpenContext, getQuickNavigateHandler } from "vs/workbench/browser/parts/quickopen/quickopen"; +import { ContextKeyExpr } from "vs/platform/contextkey/common/contextkey"; +import { KeybindingsRegistry } from "vs/platform/keybinding/common/keybindingsRegistry"; // Register Actions const registry = Registry.as(ActionExtensions.WorkbenchActions); @@ -35,14 +38,37 @@ registry.registerWorkbenchAction(new SyncActionDescriptor(GotoSymbolAction, Goto primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_O }), 'Go to Symbol in File...'); +const inViewsPickerContextKey = 'inViewsPicker'; +const inViewsPickerContext = ContextKeyExpr.and(inQuickOpenContext, ContextKeyExpr.has(inViewsPickerContextKey)); + +const viewPickerKeybinding = { primary: KeyMod.CtrlCmd | KeyCode.KEY_Q, mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_Q }, linux: { primary: null } }; + registry.registerWorkbenchAction(new SyncActionDescriptor(OpenViewPickerAction, OpenViewPickerAction.ID, OpenViewPickerAction.LABEL), 'Open View'); -registry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenViewPickerAction, QuickOpenViewPickerAction.ID, QuickOpenViewPickerAction.LABEL, { - primary: KeyMod.CtrlCmd | KeyCode.KEY_Q, mac: { primary: KeyMod.WinCtrl | KeyCode.KEY_Q }, linux: { primary: null } -}), 'Quick Open View'); +registry.registerWorkbenchAction(new SyncActionDescriptor(QuickOpenViewPickerAction, QuickOpenViewPickerAction.ID, QuickOpenViewPickerAction.LABEL, viewPickerKeybinding), 'Quick Open View'); + +const quickOpenNavigateNextInViewPickerId = 'workbench.action.quickOpenNavigateNextInViewPicker'; +KeybindingsRegistry.registerCommandAndKeybindingRule({ + id: quickOpenNavigateNextInViewPickerId, + weight: KeybindingsRegistry.WEIGHT.workbenchContrib(50), + handler: getQuickNavigateHandler(quickOpenNavigateNextInViewPickerId, true), + when: inViewsPickerContext, + primary: viewPickerKeybinding.primary, + linux: viewPickerKeybinding.linux, + mac: viewPickerKeybinding.mac +}); -registry.registerWorkbenchAction(new SyncActionDescriptor(ShowTasksAction, ShowTasksAction.ID, ShowTasksAction.LABEL, { - primary: KeyMod.CtrlCmd | KeyMod.Alt | KeyCode.KEY_T -}), 'Show Task Menu'); +const quickOpenNavigatePreviousInViewPickerId = 'workbench.action.quickOpenNavigatePreviousInViewPicker'; +KeybindingsRegistry.registerCommandAndKeybindingRule({ + id: quickOpenNavigatePreviousInViewPickerId, + weight: KeybindingsRegistry.WEIGHT.workbenchContrib(50), + handler: getQuickNavigateHandler(quickOpenNavigatePreviousInViewPickerId, false), + when: inViewsPickerContext, + primary: viewPickerKeybinding.primary | KeyMod.Shift, + linux: viewPickerKeybinding.linux, + mac: { + primary: viewPickerKeybinding.mac.primary | KeyMod.Shift + } +}); // Register Quick Open Handler @@ -51,6 +77,7 @@ Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpen 'vs/workbench/parts/quickopen/browser/commandsHandler', 'CommandsHandler', ALL_COMMANDS_PREFIX, + 'inCommandsPicker', nls.localize('commandsHandlerDescriptionDefault', "Show and Run Commands") ) ); @@ -60,6 +87,7 @@ Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpen 'vs/workbench/parts/quickopen/browser/gotoLineHandler', 'GotoLineHandler', GOTO_LINE_PREFIX, + null, [ { prefix: GOTO_LINE_PREFIX, @@ -75,6 +103,7 @@ Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpen 'vs/workbench/parts/quickopen/browser/gotoSymbolHandler', 'GotoSymbolHandler', GOTO_SYMBOL_PREFIX, + 'inFileSymbolsPicker', [ { prefix: GOTO_SYMBOL_PREFIX, @@ -95,6 +124,7 @@ Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpen 'vs/workbench/parts/quickopen/browser/helpHandler', 'HelpHandler', HELP_PREFIX, + null, nls.localize('helpDescription', "Show Help") ) ); @@ -104,6 +134,7 @@ Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpen 'vs/workbench/parts/quickopen/browser/viewPickerHandler', 'ViewPickerHandler', VIEW_PICKER_PREFIX, + inViewsPickerContextKey, [ { prefix: VIEW_PICKER_PREFIX, diff --git a/src/vs/workbench/parts/search/browser/search.contribution.ts b/src/vs/workbench/parts/search/browser/search.contribution.ts index a03f6572e09..b4d892ab721 100644 --- a/src/vs/workbench/parts/search/browser/search.contribution.ts +++ b/src/vs/workbench/parts/search/browser/search.contribution.ts @@ -35,8 +35,8 @@ import { ISearchWorkbenchService, SearchWorkbenchService } from 'vs/workbench/pa import { CommandsRegistry } from 'vs/platform/commands/common/commands'; import { SearchViewlet } from 'vs/workbench/parts/search/browser/searchViewlet'; import { ListFocusContext } from 'vs/platform/list/browser/listService'; - import { IOutputChannelRegistry, Extensions as OutputExt } from 'vs/workbench/parts/output/common/output'; +import { defaultQuickOpenContextKey } from "vs/workbench/browser/parts/quickopen/quickopen"; registerSingleton(ISearchWorkbenchService, SearchWorkbenchService); replaceContributions(); @@ -274,6 +274,7 @@ Registry.as(QuickOpenExtensions.Quickopen).registerDefaultQu 'vs/workbench/parts/search/browser/openAnythingHandler', 'OpenAnythingHandler', '', + defaultQuickOpenContextKey, nls.localize('openAnythingHandlerDescription', "Go to File") ) ); @@ -283,6 +284,7 @@ Registry.as(QuickOpenExtensions.Quickopen).registerQuickOpen 'vs/workbench/parts/search/browser/openAnythingHandler', 'OpenSymbolHandler', ALL_SYMBOLS_PREFIX, + 'inWorkspaceSymbolsPicker', [ { prefix: ALL_SYMBOLS_PREFIX, diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index 529b36f8f0c..a5a53dae147 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -1514,12 +1514,14 @@ registerSingleton(ITaskService, TaskService); // Register Quick Open const quickOpenRegistry = (Registry.as(QuickOpenExtensions.Quickopen)); +const tasksPickerContextKey = 'inTasksPicker'; quickOpenRegistry.registerQuickOpenHandler( new QuickOpenHandlerDescriptor( 'vs/workbench/parts/tasks/browser/taskQuickOpen', 'QuickOpenHandler', 'task ', + tasksPickerContextKey, nls.localize('quickOpen.task', "Run Task") ) ); @@ -1529,6 +1531,7 @@ quickOpenRegistry.registerQuickOpenHandler( 'vs/workbench/parts/tasks/browser/terminateQuickOpen', 'QuickOpenHandler', 'terminate task ', + tasksPickerContextKey, nls.localize('quickOpen.terminateTask', "Terminate Task") ) ); @@ -1538,6 +1541,7 @@ quickOpenRegistry.registerQuickOpenHandler( 'vs/workbench/parts/tasks/browser/restartQuickOpen', 'QuickOpenHandler', 'restart task ', + tasksPickerContextKey, nls.localize('quickOpen.restartTask', "Restart Task") ) ); @@ -1547,6 +1551,7 @@ quickOpenRegistry.registerQuickOpenHandler( 'vs/workbench/parts/tasks/browser/buildQuickOpen', 'QuickOpenHandler', 'build task ', + tasksPickerContextKey, nls.localize('quickOpen.buildTask', "Build Task") ) ); @@ -1556,6 +1561,7 @@ quickOpenRegistry.registerQuickOpenHandler( 'vs/workbench/parts/tasks/browser/testQuickOpen', 'QuickOpenHandler', 'test task ', + tasksPickerContextKey, nls.localize('quickOpen.testTask', "Test Task") ) ); diff --git a/src/vs/workbench/parts/terminal/common/terminal.ts b/src/vs/workbench/parts/terminal/common/terminal.ts index 116c8854a77..34cf3aaac1d 100644 --- a/src/vs/workbench/parts/terminal/common/terminal.ts +++ b/src/vs/workbench/parts/terminal/common/terminal.ts @@ -27,6 +27,11 @@ export const KEYBINDING_CONTEXT_TERMINAL_TEXT_SELECTED = new RawContextKey('terminalFindWidgetVisible', undefined); +/** A context key that is set when the find widget in integrated terminal is not visible. */ +export const KEYBINDING_CONTEXT_TERMINAL_FIND_WIDGET_NOT_VISIBLE: ContextKeyExpr = KEYBINDING_CONTEXT_TERMINAL_FIND_WIDGET_VISIBLE.toNegated(); + export const IS_WORKSPACE_SHELL_ALLOWED_STORAGE_KEY = 'terminal.integrated.isWorkspaceShellAllowed'; export const NEVER_SUGGEST_SELECT_WINDOWS_SHELL_STORAGE_KEY = 'terminal.integrated.neverSuggestSelectWindowsShell'; @@ -147,6 +152,8 @@ export interface ITerminalService { showPanel(focus?: boolean): TPromise; hidePanel(): void; + focusFindWidget(): TPromise; + hideFindWidget(): void; setContainers(panelContainer: HTMLElement, terminalContainer: HTMLElement): void; updateConfig(): void; selectDefaultWindowsShell(): TPromise; @@ -235,6 +242,16 @@ export interface ITerminalInstance { */ selectAll(): void; + /** + * Find the next instance of the term + */ + findNext(term: string): boolean; + + /** + * Find the previous instance of the term + */ + findPrevious(term: string): boolean; + /** * Focuses the terminal instance. * diff --git a/src/vs/workbench/parts/terminal/common/terminalService.ts b/src/vs/workbench/parts/terminal/common/terminalService.ts index 7dbb40a3233..5362507941f 100644 --- a/src/vs/workbench/parts/terminal/common/terminalService.ts +++ b/src/vs/workbench/parts/terminal/common/terminalService.ts @@ -10,7 +10,7 @@ import { ILifecycleService } from 'vs/platform/lifecycle/common/lifecycle'; import { IPanelService } from 'vs/workbench/services/panel/common/panelService'; import { IPartService } from 'vs/workbench/services/part/common/partService'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { ITerminalService, ITerminalInstance, IShellLaunchConfig, ITerminalConfigHelper, KEYBINDING_CONTEXT_TERMINAL_FOCUS, TERMINAL_PANEL_ID } from 'vs/workbench/parts/terminal/common/terminal'; +import { ITerminalService, ITerminalInstance, IShellLaunchConfig, ITerminalConfigHelper, KEYBINDING_CONTEXT_TERMINAL_FOCUS, KEYBINDING_CONTEXT_TERMINAL_FIND_WIDGET_VISIBLE, TERMINAL_PANEL_ID } from 'vs/workbench/parts/terminal/common/terminal'; import { TPromise } from 'vs/base/common/winjs.base'; export abstract class TerminalService implements ITerminalService { @@ -18,6 +18,7 @@ export abstract class TerminalService implements ITerminalService { protected _isShuttingDown: boolean; protected _terminalFocusContextKey: IContextKey; + protected _findWidgetVisible: IContextKey; protected _terminalContainer: HTMLElement; protected _onInstancesChanged: Emitter; protected _onInstanceDisposed: Emitter; @@ -43,7 +44,7 @@ export abstract class TerminalService implements ITerminalService { constructor( @IContextKeyService private _contextKeyService: IContextKeyService, @IConfigurationService private _configurationService: IConfigurationService, - @IPanelService private _panelService: IPanelService, + @IPanelService protected _panelService: IPanelService, @IPartService private _partService: IPartService, @ILifecycleService lifecycleService: ILifecycleService ) { @@ -61,6 +62,7 @@ export abstract class TerminalService implements ITerminalService { this._configurationService.onDidUpdateConfiguration(() => this.updateConfig()); lifecycleService.onWillShutdown(event => event.veto(this._onWillShutdown())); this._terminalFocusContextKey = KEYBINDING_CONTEXT_TERMINAL_FOCUS.bindTo(this._contextKeyService); + this._findWidgetVisible = KEYBINDING_CONTEXT_TERMINAL_FIND_WIDGET_VISIBLE.bindTo(this._contextKeyService); this.onInstanceDisposed((terminalInstance) => { this._removeInstance(terminalInstance); }); } @@ -200,6 +202,9 @@ export abstract class TerminalService implements ITerminalService { } } + public abstract focusFindWidget(): TPromise; + public abstract hideFindWidget(): void; + private _getIndexFromId(terminalId: number): number { let terminalIndex = -1; this.terminalInstances.forEach((terminalInstance, i) => { diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/close-dark.svg b/src/vs/workbench/parts/terminal/electron-browser/media/close-dark.svg new file mode 100644 index 00000000000..751e89b3b02 --- /dev/null +++ b/src/vs/workbench/parts/terminal/electron-browser/media/close-dark.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/close.svg b/src/vs/workbench/parts/terminal/electron-browser/media/close.svg new file mode 100644 index 00000000000..fde34404d4e --- /dev/null +++ b/src/vs/workbench/parts/terminal/electron-browser/media/close.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/next-inverse.svg b/src/vs/workbench/parts/terminal/electron-browser/media/next-inverse.svg new file mode 100644 index 00000000000..7498a498bb6 --- /dev/null +++ b/src/vs/workbench/parts/terminal/electron-browser/media/next-inverse.svg @@ -0,0 +1,5 @@ + + + diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/next.svg b/src/vs/workbench/parts/terminal/electron-browser/media/next.svg new file mode 100644 index 00000000000..4b176879f90 --- /dev/null +++ b/src/vs/workbench/parts/terminal/electron-browser/media/next.svg @@ -0,0 +1,5 @@ + + + diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/previous-inverse.svg b/src/vs/workbench/parts/terminal/electron-browser/media/previous-inverse.svg new file mode 100644 index 00000000000..0aabf393d9c --- /dev/null +++ b/src/vs/workbench/parts/terminal/electron-browser/media/previous-inverse.svg @@ -0,0 +1,5 @@ + + + diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/previous.svg b/src/vs/workbench/parts/terminal/electron-browser/media/previous.svg new file mode 100644 index 00000000000..f7acf0acbd9 --- /dev/null +++ b/src/vs/workbench/parts/terminal/electron-browser/media/previous.svg @@ -0,0 +1,5 @@ + + + diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css b/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css index f2cc6747e2c..0b6570ccef9 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css +++ b/src/vs/workbench/parts/terminal/electron-browser/media/terminal.css @@ -78,3 +78,75 @@ .hc-black .monaco-workbench.mac .panel.integrated-terminal .xterm-rows { cursor: -webkit-image-set(url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAQAAAC1+jfqAAAAL0lEQVQoz2NgCD3x//9/BhBYBWdhgFVAiVW4JBFKGIa4AqD0//9D3pt4I4tAdAMAHTQ/j5Zom30AAAAASUVORK5CYII=') 1x, url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAQAAADZc7J/AAAAz0lEQVRIx2NgYGBY/R8I/vx5eelX3n82IJ9FxGf6tksvf/8FiTMQAcAGQMDvSwu09abffY8QYSAScNk45G198eX//yev73/4///701eh//kZSARckrNBRvz//+8+6ZohwCzjGNjdgQxkAg7B9WADeBjIBqtJCbhRA0YNoIkBSNmaPEMoNmA0FkYNoFKhapJ6FGyAH3nauaSmPfwI0v/3OukVi0CIZ+F25KrtYcx/CTIy0e+rC7R1Z4KMICVTQQ14feVXIbR695u14+Ir4gwAAD49E54wc1kWAAAAAElFTkSuQmCC') 2x) 5 8, text; } + +.monaco-workbench .panel.integrated-terminal .find-part { + position: absolute; + top: -40px; + right: 28px; + display: none; + padding: 4px; + align-items: center; + + -webkit-transition: top 200ms linear; + -o-transition: top 200ms linear; + -moz-transition: top 200ms linear; + -ms-transition: top 200ms linear; + transition: top 200ms linear; +} + +.monaco-workbench .panel.integrated-terminal .find-part.visible { + top: 0; + display: flex; +} + +/* Temporarily we don't show match numbers */ +.monaco-workbench .panel.integrated-terminal .find-part .monaco-findInput .controls { + display: none; +} +.monaco-workbench .panel.integrated-terminal .find-part .monaco-findInput .monaco-inputbox .wrapper .input { + width: 100% !important; +} + +.monaco-workbench .panel.integrated-terminal .find-part .button { + min-width: 20px; + width: 20px; + height: 20px; + display: flex; + flex: initial; + margin-left: 3px; + background-position: center center; + background-repeat: no-repeat; + cursor: pointer; +} + +.monaco-workbench .panel.integrated-terminal .find-part .button.previous { + background-image: url('previous.svg'); +} + +.monaco-workbench .panel.integrated-terminal .find-part .button.next { + background-image: url('next.svg'); +} + +.monaco-workbench .panel.integrated-terminal .find-part .button.close-fw { + background-image: url('close.svg'); +} + +.hc-black .monaco-workbench .panel.integrated-terminal .find-part .button.previous, +.vs-dark .monaco-workbench .panel.integrated-terminal .find-part .button.previous { + background-image: url('previous-inverse.svg'); +} + +.hc-black .monaco-workbench .panel.integrated-terminal .find-part .button.next, +.vs-dark .monaco-workbench .panel.integrated-terminal .find-part .button.next { + background-image: url('next-inverse.svg'); +} + +.hc-black .monaco-workbench .panel.integrated-terminal .find-part .button.close-fw, +.vs-dark .monaco-workbench .panel.integrated-terminal .find-part .button.close-fw { + background-image: url('close-dark.svg'); +} + +monaco-workbench .panel.integrated-terminal .find-part .button.disabled { + opacity: 0.3; + cursor: default; +} \ No newline at end of file diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/widgets.css b/src/vs/workbench/parts/terminal/electron-browser/media/widgets.css index 2549ad70163..10751297b59 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/media/widgets.css +++ b/src/vs/workbench/parts/terminal/electron-browser/media/widgets.css @@ -12,7 +12,7 @@ } .monaco-workbench .terminal-message-widget { - font-family: system-ui, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", "Ubuntu", "Droid Sans", sans-serif; + font-family: -apple-system, BlinkMacSystemFont, "Segoe WPC", "Segoe UI", "HelveticaNeue-Light", "Ubuntu", "Droid Sans", sans-serif; font-size: 14px; line-height: 19px; padding: 4px 5px; diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts index 3dafb84e0b5..b12e4812b9b 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts @@ -12,13 +12,13 @@ import * as nls from 'vs/nls'; import * as panel from 'vs/workbench/browser/panel'; import * as platform from 'vs/base/common/platform'; import { Extensions, IConfigurationRegistry } from 'vs/platform/configuration/common/configurationRegistry'; -import { GlobalQuickOpenAction } from 'vs/workbench/browser/parts/quickopen/quickopen.contribution'; -import { ITerminalService, KEYBINDING_CONTEXT_TERMINAL_FOCUS, KEYBINDING_CONTEXT_TERMINAL_TEXT_SELECTED, TERMINAL_PANEL_ID, TERMINAL_DEFAULT_RIGHT_CLICK_COPY_PASTE, TerminalCursorStyle } from 'vs/workbench/parts/terminal/common/terminal'; +import { GlobalQuickOpenAction } from 'vs/workbench/browser/parts/quickopen/quickopen'; +import { ITerminalService, KEYBINDING_CONTEXT_TERMINAL_FOCUS, KEYBINDING_CONTEXT_TERMINAL_TEXT_SELECTED, TERMINAL_PANEL_ID, TERMINAL_DEFAULT_RIGHT_CLICK_COPY_PASTE, KEYBINDING_CONTEXT_TERMINAL_FIND_WIDGET_VISIBLE, TerminalCursorStyle } from 'vs/workbench/parts/terminal/common/terminal'; import { TERMINAL_DEFAULT_SHELL_LINUX, TERMINAL_DEFAULT_SHELL_OSX, TERMINAL_DEFAULT_SHELL_WINDOWS } from 'vs/workbench/parts/terminal/electron-browser/terminal'; import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/workbench/common/actionRegistry'; import { KeyCode, KeyMod } from 'vs/base/common/keyCodes'; import { ContextKeyExpr } from 'vs/platform/contextkey/common/contextkey'; -import { KillTerminalAction, CopyTerminalSelectionAction, CreateNewTerminalAction, FocusActiveTerminalAction, FocusNextTerminalAction, FocusPreviousTerminalAction, FocusTerminalAtIndexAction, SelectDefaultShellWindowsTerminalAction, RunSelectedTextInTerminalAction, RunActiveFileInTerminalAction, ScrollDownTerminalAction, ScrollDownPageTerminalAction, ScrollToBottomTerminalAction, ScrollUpTerminalAction, ScrollUpPageTerminalAction, ScrollToTopTerminalAction, TerminalPasteAction, ToggleTerminalAction, ClearTerminalAction, AllowWorkspaceShellTerminalCommand, DisallowWorkspaceShellTerminalCommand, RenameTerminalAction, SelectAllTerminalAction } from 'vs/workbench/parts/terminal/electron-browser/terminalActions'; +import { KillTerminalAction, CopyTerminalSelectionAction, CreateNewTerminalAction, FocusActiveTerminalAction, FocusNextTerminalAction, FocusPreviousTerminalAction, FocusTerminalAtIndexAction, SelectDefaultShellWindowsTerminalAction, RunSelectedTextInTerminalAction, RunActiveFileInTerminalAction, ScrollDownTerminalAction, ScrollDownPageTerminalAction, ScrollToBottomTerminalAction, ScrollUpTerminalAction, ScrollUpPageTerminalAction, ScrollToTopTerminalAction, TerminalPasteAction, ToggleTerminalAction, ClearTerminalAction, AllowWorkspaceShellTerminalCommand, DisallowWorkspaceShellTerminalCommand, RenameTerminalAction, SelectAllTerminalAction, FocusTerminalFindWidgetAction, HideTerminalFindWidgetAction } from 'vs/workbench/parts/terminal/electron-browser/terminalActions'; import { Registry } from 'vs/platform/platform'; import { ShowAllCommandsAction } from 'vs/workbench/parts/quickopen/browser/commandsHandler'; import { SyncActionDescriptor } from 'vs/platform/actions/common/actions'; @@ -186,7 +186,9 @@ configurationRegistry.registerConfiguration({ FocusFirstGroupAction.ID, FocusSecondGroupAction.ID, FocusThirdGroupAction.ID, - SelectAllTerminalAction.ID + SelectAllTerminalAction.ID, + FocusTerminalFindWidgetAction.ID, + HideTerminalFindWidgetAction.ID ].sort() } } @@ -277,5 +279,10 @@ if (platform.isWindows) { actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(AllowWorkspaceShellTerminalCommand, AllowWorkspaceShellTerminalCommand.ID, AllowWorkspaceShellTerminalCommand.LABEL), 'Terminal: Allow Workspace Shell Configuration', category); actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(DisallowWorkspaceShellTerminalCommand, DisallowWorkspaceShellTerminalCommand.ID, DisallowWorkspaceShellTerminalCommand.LABEL), 'Terminal: Disallow Workspace Shell Configuration', category); actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(RenameTerminalAction, RenameTerminalAction.ID, RenameTerminalAction.LABEL), 'Terminal: Rename', category); - +actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(FocusTerminalFindWidgetAction, FocusTerminalFindWidgetAction.ID, FocusTerminalFindWidgetAction.LABEL, { + primary: KeyMod.CtrlCmd | KeyCode.KEY_F +}, KEYBINDING_CONTEXT_TERMINAL_FOCUS), 'Terminal: Focus Find Widget', category); +actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(HideTerminalFindWidgetAction, HideTerminalFindWidgetAction.ID, HideTerminalFindWidgetAction.LABEL, { + primary: KeyCode.Escape +}, KEYBINDING_CONTEXT_TERMINAL_FIND_WIDGET_VISIBLE), 'Terminal: Focus Find Widget', category); registerColors(); diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts index 6ead524b144..0d3a3a0b17c 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalActions.ts @@ -583,3 +583,37 @@ export class RenameTerminalAction extends Action { }); } } + +export class FocusTerminalFindWidgetAction extends Action { + + public static ID = 'workbench.action.terminal.focusFindWidget'; + public static LABEL = nls.localize('workbench.action.terminal.focusFindWidget', "Focus Find Widget"); + + constructor( + id: string, label: string, + @ITerminalService private terminalService: ITerminalService + ) { + super(id, label); + } + + public run(): TPromise { + return this.terminalService.focusFindWidget(); + } +} + +export class HideTerminalFindWidgetAction extends Action { + + public static ID = 'workbench.action.terminal.hideFindWidget'; + public static LABEL = nls.localize('workbench.action.terminal.hideFindWidget', "Hide Find Widget"); + + constructor( + id: string, label: string, + @ITerminalService private terminalService: ITerminalService + ) { + super(id, label); + } + + public run(): TPromise { + return TPromise.as(this.terminalService.hideFindWidget()); + } +} diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.ts new file mode 100644 index 00000000000..8e8493811b8 --- /dev/null +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.ts @@ -0,0 +1,224 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as nls from 'vs/nls'; +import { IKeyboardEvent } from 'vs/base/browser/keyboardEvent'; +import { Widget } from 'vs/base/browser/ui/widget'; +import { KeyCode, KeyMod } from 'vs/base/common/keyCodes'; +import * as dom from 'vs/base/browser/dom'; +import { FindInput } from 'vs/base/browser/ui/findinput/findInput'; +import { IContextViewService } from 'vs/platform/contextview/browser/contextView'; +import { ITerminalService } from 'vs/workbench/parts/terminal/common/terminal'; +import { registerThemingParticipant, ITheme } from 'vs/platform/theme/common/themeService'; +import { inputBackground, inputActiveOptionBorder, inputForeground, inputBorder, inputValidationInfoBackground, inputValidationInfoBorder, inputValidationWarningBackground, inputValidationWarningBorder, inputValidationErrorBackground, inputValidationErrorBorder, editorWidgetBackground, widgetShadow } from 'vs/platform/theme/common/colorRegistry'; + +interface IButtonOpts { + label: string; + className: string; + onTrigger: () => void; + onKeyDown: (e: IKeyboardEvent) => void; +} + +class SimpleButton extends Widget { + + private _opts: IButtonOpts; + private _domNode: HTMLElement; + + constructor(opts: IButtonOpts) { + super(); + this._opts = opts; + + this._domNode = document.createElement('div'); + this._domNode.title = this._opts.label; + this._domNode.tabIndex = 0; + this._domNode.className = 'button ' + this._opts.className; + this._domNode.setAttribute('role', 'button'); + this._domNode.setAttribute('aria-label', this._opts.label); + + this.onclick(this._domNode, (e) => { + this._opts.onTrigger(); + e.preventDefault(); + }); + this.onkeydown(this._domNode, (e) => { + if (e.equals(KeyCode.Space) || e.equals(KeyCode.Enter)) { + this._opts.onTrigger(); + e.preventDefault(); + return; + } + this._opts.onKeyDown(e); + }); + } + + public get domNode(): HTMLElement { + return this._domNode; + } + + public isEnabled(): boolean { + return (this._domNode.tabIndex >= 0); + } + + public focus(): void { + this._domNode.focus(); + } + + public setEnabled(enabled: boolean): void { + dom.toggleClass(this._domNode, 'disabled', !enabled); + this._domNode.setAttribute('aria-disabled', String(!enabled)); + this._domNode.tabIndex = enabled ? 0 : -1; + } + + public toggleClass(className: string, shouldHaveIt: boolean): void { + dom.toggleClass(this._domNode, className, shouldHaveIt); + } +} + +const NLS_FIND_INPUT_LABEL = nls.localize('label.find', "Find"); +const NLS_FIND_INPUT_PLACEHOLDER = nls.localize('placeholder.find', "Find"); +const NLS_PREVIOUS_MATCH_BTN_LABEL = nls.localize('label.previousMatchButton', "Previous match"); +const NLS_NEXT_MATCH_BTN_LABEL = nls.localize('label.nextMatchButton', "Next match"); +const NLS_CLOSE_BTN_LABEL = nls.localize('label.closeButton', "Close"); + +export class TerminalFindWidget extends Widget { + private _findInput: FindInput; + private _domNode: HTMLElement; + private _isVisible: boolean; + + constructor( + @IContextViewService private _contextViewService: IContextViewService, + @ITerminalService private _terminalService: ITerminalService + ) { + super(); + this._findInput = this._register(new FindInput(null, this._contextViewService, { + width: 155, + label: NLS_FIND_INPUT_LABEL, + placeholder: NLS_FIND_INPUT_PLACEHOLDER, + })); + + let find = (previous) => { + let val = this._findInput.getValue(); + let instance = this._terminalService.getActiveInstance(); + if (instance !== null) { + if (previous) { + instance.findPrevious(val); + } else { + instance.findNext(val); + } + } + }; + + this._register(this._findInput.onKeyDown((e) => { + if (e.equals(KeyCode.Enter)) { + find(false); + e.preventDefault(); + return; + } + + if (e.equals(KeyMod.Shift | KeyCode.Enter)) { + find(true); + e.preventDefault(); + return; + } + })); + + let prevBtn = new SimpleButton({ + label: NLS_PREVIOUS_MATCH_BTN_LABEL, + className: 'previous', + onTrigger: () => { + find(true); + }, + onKeyDown: (e) => { } + }); + + let nextBtn = new SimpleButton({ + label: NLS_NEXT_MATCH_BTN_LABEL, + className: 'next', + onTrigger: () => { + find(false); + }, + onKeyDown: (e) => { } + }); + + let closeBtn = new SimpleButton({ + label: NLS_CLOSE_BTN_LABEL, + className: 'close-fw', + onTrigger: () => { + this.hide(); + }, + onKeyDown: (e) => { } + }); + + this._domNode = document.createElement('div'); + this._domNode.className = 'find-part'; + this._domNode.appendChild(this._findInput.domNode); + this._domNode.appendChild(prevBtn.domNode); + this._domNode.appendChild(nextBtn.domNode); + this._domNode.appendChild(closeBtn.domNode); + + this._register(dom.addDisposableListener(this._domNode, 'click', (event) => { + event.stopPropagation(); + })); + } + + public updateTheme(theme?: ITheme): void { + let inputStyles = { + inputActiveOptionBorder: theme.getColor(inputActiveOptionBorder), + inputBackground: theme.getColor(inputBackground), + inputForeground: theme.getColor(inputForeground), + inputBorder: theme.getColor(inputBorder), + inputValidationInfoBackground: theme.getColor(inputValidationInfoBackground), + inputValidationInfoBorder: theme.getColor(inputValidationInfoBorder), + inputValidationWarningBackground: theme.getColor(inputValidationWarningBackground), + inputValidationWarningBorder: theme.getColor(inputValidationWarningBorder), + inputValidationErrorBackground: theme.getColor(inputValidationErrorBackground), + inputValidationErrorBorder: theme.getColor(inputValidationErrorBorder) + }; + this._findInput.style(inputStyles); + } + + public getDomNode(): HTMLElement { + return this._domNode; + } + + public reveal(): void { + if (this._isVisible) { + this._findInput.select(); + return; + } + + this._isVisible = true; + + setTimeout(() => { + dom.addClass(this._domNode, 'visible'); + this._domNode.setAttribute('aria-hidden', 'false'); + dom.addClass(this._domNode, 'noanimation'); + setTimeout(() => { + dom.removeClass(this._domNode, 'noanimation'); + this._findInput.select(); + }, 200); + }, 0); + } + + public hide(): void { + if (this._isVisible) { + this._isVisible = false; + + dom.removeClass(this._domNode, 'visible'); + this._domNode.setAttribute('aria-hidden', 'true'); + } + } +} + +// theming +registerThemingParticipant((theme, collector) => { + const findWidgetBGColor = theme.getColor(editorWidgetBackground); + if (findWidgetBGColor) { + collector.addRule(`.monaco-workbench .panel.integrated-terminal .find-part { background-color: ${findWidgetBGColor} !important; }`); + } + + let widgetShadowColor = theme.getColor(widgetShadow); + if (widgetShadowColor) { + collector.addRule(`.monaco-workbench .panel.integrated-terminal .find-part { box-shadow: 0 2px 8px ${widgetShadowColor}; }`); + } +}); \ No newline at end of file diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index b03ee074b1e..54989b2c496 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -347,6 +347,14 @@ export class TerminalInstance implements ITerminalInstance { this._xterm.selectAll(); } + public findNext(term: string): boolean { + return this._xterm.findNext(term); + } + + public findPrevious(term: string): boolean { + return this._xterm.findPrevious(term); + } + public dispose(): void { if (this._linkHandler) { this._linkHandler.dispose(); diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts index 3dae4ebd1bd..ee922268212 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts @@ -10,11 +10,12 @@ import { Action, IAction } from 'vs/base/common/actions'; import { Builder, Dimension } from 'vs/base/browser/builder'; import { IActionItem, Separator } from 'vs/base/browser/ui/actionbar/actionbar'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { IContextMenuService } from 'vs/platform/contextview/browser/contextView'; +import { IContextMenuService, IContextViewService } from 'vs/platform/contextview/browser/contextView'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { ITerminalService, ITerminalFont, TERMINAL_PANEL_ID } from 'vs/workbench/parts/terminal/common/terminal'; import { IThemeService, ITheme } from 'vs/platform/theme/common/themeService'; +import { TerminalFindWidget } from './terminalFindWidget'; import { ansiColorIdentifiers, TERMINAL_BACKGROUND_COLOR, TERMINAL_FOREGROUND_COLOR } from './terminalColorRegistry'; import { ColorIdentifier, selectionBackground } from 'vs/platform/theme/common/colorRegistry'; import { KillTerminalAction, CreateNewTerminalAction, SwitchTerminalInstanceAction, SwitchTerminalInstanceActionItem, CopyTerminalSelectionAction, TerminalPasteAction, ClearTerminalAction } from 'vs/workbench/parts/terminal/electron-browser/terminalActions'; @@ -34,10 +35,12 @@ export class TerminalPanel extends Panel { private _parentDomElement: HTMLElement; private _terminalContainer: HTMLElement; private _themeStyleElement: HTMLElement; + private _findWidget: TerminalFindWidget; constructor( @IConfigurationService private _configurationService: IConfigurationService, @IContextMenuService private _contextMenuService: IContextMenuService, + @IContextViewService private _contextViewService: IContextViewService, @IInstantiationService private _instantiationService: IInstantiationService, @ITerminalService private _terminalService: ITerminalService, @IThemeService protected themeService: IThemeService, @@ -55,9 +58,13 @@ export class TerminalPanel extends Panel { this._terminalContainer = document.createElement('div'); dom.addClass(this._terminalContainer, 'terminal-outer-container'); + + this._findWidget = new TerminalFindWidget(this._contextViewService, this._terminalService); + this._parentDomElement.appendChild(this._themeStyleElement); this._parentDomElement.appendChild(this._fontStyleElement); this._parentDomElement.appendChild(this._terminalContainer); + this._parentDomElement.appendChild(this._findWidget.getDomNode()); this._attachEventListeners(); @@ -149,6 +156,14 @@ export class TerminalPanel extends Panel { } } + public focusFindWidget() { + this._findWidget.reveal(); + } + + public hideFindWidget() { + this._findWidget.hide(); + } + private _attachEventListeners(): void { this._register(dom.addDisposableListener(this._parentDomElement, 'mousedown', (event: MouseEvent) => { if (this._terminalService.terminalInstances.length === 0) { @@ -272,6 +287,7 @@ export class TerminalPanel extends Panel { } this._themeStyleElement.innerHTML = css; + this._findWidget.updateTheme(theme); } private _updateFont(): void { diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalService.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalService.ts index e731656e46d..5ce3dc18e9b 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalService.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalService.ts @@ -16,7 +16,7 @@ import { IWindowIPCService } from 'vs/workbench/services/window/electron-browser import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { IConfigurationEditingService, ConfigurationTarget } from 'vs/workbench/services/configuration/common/configurationEditing'; import { IQuickOpenService, IPickOpenEntry, IPickOptions } from 'vs/platform/quickOpen/common/quickOpen'; -import { ITerminalInstance, ITerminalService, IShellLaunchConfig, ITerminalConfigHelper, NEVER_SUGGEST_SELECT_WINDOWS_SHELL_STORAGE_KEY } from 'vs/workbench/parts/terminal/common/terminal'; +import { ITerminalInstance, ITerminalService, IShellLaunchConfig, ITerminalConfigHelper, NEVER_SUGGEST_SELECT_WINDOWS_SHELL_STORAGE_KEY, TERMINAL_PANEL_ID } from 'vs/workbench/parts/terminal/common/terminal'; import { TerminalService as AbstractTerminalService } from 'vs/workbench/parts/terminal/common/terminalService'; import { TerminalConfigHelper } from 'vs/workbench/parts/terminal/electron-browser/terminalConfigHelper'; import { TerminalInstance } from 'vs/workbench/parts/terminal/electron-browser/terminalInstance'; @@ -25,10 +25,10 @@ import { IChoiceService } from 'vs/platform/message/common/message'; import { Severity } from 'vs/editor/common/standalone/standaloneBase'; import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage'; import { TERMINAL_DEFAULT_SHELL_WINDOWS } from "vs/workbench/parts/terminal/electron-browser/terminal"; +import { TerminalPanel } from "vs/workbench/parts/terminal/electron-browser/terminalPanel"; export class TerminalService extends AbstractTerminalService implements ITerminalService { private _configHelper: TerminalConfigHelper; - public get configHelper(): ITerminalConfigHelper { return this._configHelper; }; constructor( @@ -69,6 +69,23 @@ export class TerminalService extends AbstractTerminalService implements ITermina return terminalInstance; } + public focusFindWidget(): TPromise { + return this.showPanel(false).then(() => { + let panel = this._panelService.getActivePanel() as TerminalPanel; + panel.focusFindWidget(); + this._findWidgetVisible.set(true); + }); + } + + public hideFindWidget(): void { + const panel = this._panelService.getActivePanel() as TerminalPanel; + if (panel && panel.getId() === TERMINAL_PANEL_ID) { + panel.hideFindWidget(); + this._findWidgetVisible.reset(); + panel.focus(); + } + } + private _suggestShellChange(wasNewTerminalAction?: boolean): void { // Only suggest on Windows since $SHELL works great for macOS/Linux if (!platform.isWindows) { diff --git a/src/vs/workbench/parts/watermark/electron-browser/watermark.ts b/src/vs/workbench/parts/watermark/electron-browser/watermark.ts index a6e55adf5c8..c28efbc3fc6 100644 --- a/src/vs/workbench/parts/watermark/electron-browser/watermark.ts +++ b/src/vs/workbench/parts/watermark/electron-browser/watermark.ts @@ -18,7 +18,7 @@ import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace import { IWorkbenchContribution, IWorkbenchContributionsRegistry, Extensions as WorkbenchExtensions } from 'vs/workbench/common/contributions'; import { ILifecycleService } from 'vs/platform/lifecycle/common/lifecycle'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; -import { GlobalQuickOpenAction } from 'vs/workbench/browser/parts/quickopen/quickopen.contribution'; +import { GlobalQuickOpenAction } from 'vs/workbench/browser/parts/quickopen/quickopen'; import { KeybindingsReferenceAction, OpenRecentAction } from 'vs/workbench/electron-browser/actions'; import { ShowRecommendedKeymapExtensionsAction } from 'vs/workbench/parts/extensions/browser/extensionsActions'; import { GlobalNewUntitledFileAction, OpenFileAction } from 'vs/workbench/parts/files/browser/fileActions'; diff --git a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts index 48160e32d1e..1187473c057 100644 --- a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts +++ b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts @@ -121,7 +121,6 @@ export class WalkThroughPart extends BaseEditor { this.content.style.outlineStyle = 'none'; this.scrollbar = new DomScrollableElement(this.content, { - canUseTranslate3d: false, horizontal: ScrollbarVisibility.Auto, vertical: ScrollbarVisibility.Auto }); diff --git a/src/vs/workbench/services/configuration/common/configurationModels.ts b/src/vs/workbench/services/configuration/common/configurationModels.ts index 10f1fb17a9d..d6ad817c30e 100644 --- a/src/vs/workbench/services/configuration/common/configurationModels.ts +++ b/src/vs/workbench/services/configuration/common/configurationModels.ts @@ -4,12 +4,12 @@ *--------------------------------------------------------------------------------------------*/ 'use strict'; -import { ConfigModel } from 'vs/platform/configuration/common/model'; +import { CustomConfiguration } from 'vs/platform/configuration/common/model'; import { WORKSPACE_STANDALONE_CONFIGURATIONS } from 'vs/workbench/services/configuration/common/configuration'; import { Registry } from 'vs/platform/platform'; import { IConfigurationRegistry, IConfigurationPropertySchema, Extensions } from 'vs/platform/configuration/common/configurationRegistry'; -export class ScopedConfigModel extends ConfigModel { +export class ScopedConfigModel extends CustomConfiguration { constructor(content: string, name: string, public readonly scope: string) { super(null, name); @@ -25,7 +25,7 @@ export class ScopedConfigModel extends ConfigModel { } -export class WorkspaceSettingsConfigModel extends ConfigModel { +export class WorkspaceSettingsConfigModel extends CustomConfiguration { private _raw: T; private _unsupportedKeys: string[]; @@ -62,7 +62,7 @@ export class WorkspaceSettingsConfigModel extends ConfigModel { } } -export class WorkspaceConfigModel extends ConfigModel { +export class WorkspaceConfigModel extends CustomConfiguration { constructor(public readonly workspaceSettingsConfig: WorkspaceSettingsConfigModel, private scopedConfigs: ScopedConfigModel[]) { super(); diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index f449677e865..4c62132f61d 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -20,11 +20,12 @@ import * as extfs from 'vs/base/node/extfs'; import { IWorkspaceContextService, IWorkspace2, Workspace as SingleRootWorkspace, IWorkspace } from "vs/platform/workspace/common/workspace"; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { FileChangeType, FileChangesEvent, isEqual } from 'vs/platform/files/common/files'; -import { ConfigModel } from 'vs/platform/configuration/common/model'; import { ScopedConfigModel, WorkspaceConfigModel, WorkspaceSettingsConfigModel } from 'vs/workbench/services/configuration/common/configurationModels'; -import { IConfigurationServiceEvent, ConfigurationSource, getConfigurationValue, IConfigModel, IConfigurationOptions } from 'vs/platform/configuration/common/configuration'; +import { IConfigurationServiceEvent, ConfigurationSource, getConfigurationValue, IConfigurationOptions, Configuration } from 'vs/platform/configuration/common/configuration'; import { IWorkspaceConfigurationValues, IWorkspaceConfigurationService, IWorkspaceConfigurationValue, WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME, WORKSPACE_STANDALONE_CONFIGURATIONS, WORKSPACE_CONFIG_DEFAULT_PATH } from 'vs/workbench/services/configuration/common/configuration'; import { ConfigurationService as GlobalConfigurationService } from 'vs/platform/configuration/node/configurationService'; +import { createHash } from "crypto"; +import { basename } from "path"; interface IStat { resource: URI; @@ -45,18 +46,31 @@ interface IWorkspaceConfiguration { type IWorkspaceFoldersConfiguration = { [rootFolder: string]: { folders: string[]; } }; class Workspace implements IWorkspace2 { + private _name: string; - constructor(readonly id: string, private _roots: URI[]) { + constructor( + public readonly id: string, + private _roots: URI[] + ) { + // } - get roots(): URI[] { - return this._roots; + public set roots(roots: URI[]) { + this._roots = roots; + this._name = null; // will be recomputed based on roots next time accessed } - setRoots(roots: URI[]): void { - this._roots = roots; + public get roots(): URI[] { + return this._roots; } + public get name(): string { + if (!this._name) { + this._name = this.roots.map(root => basename(root.fsPath)).join(', '); + } + + return this._name; + } } export class WorkspaceConfigurationService extends Disposable implements IWorkspaceContextService, IWorkspaceConfigurationService { @@ -73,11 +87,11 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp private baseConfigurationService: GlobalConfigurationService; - private cachedConfig: ConfigModel; + private cachedConfig: Configuration; private cachedWorkspaceConfig: WorkspaceConfigModel; private bulkFetchFromWorkspacePromise: TPromise; - private workspaceFilePathToConfiguration: { [relativeWorkspacePath: string]: TPromise> }; + private workspaceFilePathToConfiguration: { [relativeWorkspacePath: string]: TPromise> }; private reloadConfigurationScheduler: RunOnceScheduler; private readonly workspace: Workspace; @@ -85,10 +99,10 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp constructor(private environmentService: IEnvironmentService, private singleRootWorkspace?: SingleRootWorkspace, private workspaceSettingsRootFolder: string = WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME) { super(); - this.workspace = singleRootWorkspace ? new Workspace(`${singleRootWorkspace.uid}`, [singleRootWorkspace.resource]) : null; + this.workspace = singleRootWorkspace ? new Workspace(createHash('md5').update(singleRootWorkspace.resource.toString()).digest('hex'), [singleRootWorkspace.resource]) : null; // TODO@Ben for now use the first root folder as id, but revisit this later this.workspaceFilePathToConfiguration = Object.create(null); - this.cachedConfig = new ConfigModel(null); + this.cachedConfig = new Configuration(); this.cachedWorkspaceConfig = new WorkspaceConfigModel(new WorkspaceSettingsConfigModel(null), []); this.baseConfigurationService = this._register(new GlobalConfigurationService(environmentService)); @@ -130,7 +144,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp // Find changes const changed = !equals(this.workspace.roots, configuredFolders, (r1, r2) => r1.toString() === r2.toString()); - this.workspace.setRoots(configuredFolders); + this.workspace.roots = configuredFolders; if (notify && changed) { this._onDidChangeWorkspaceRoots.fire(configuredFolders); @@ -167,7 +181,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } // update cached config when base config changes - const configModel = >this.baseConfigurationService.getCache().consolidated // global/default values (do NOT modify) + const configModel = >this.baseConfigurationService.getCache().consolidated // global/default values (do NOT modify) .merge(this.cachedWorkspaceConfig); // workspace configured values // emit this as update to listeners if changed @@ -189,7 +203,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp public getConfiguration(options?: IConfigurationOptions): C public getConfiguration(arg?: any): C { const options = this.toOptions(arg); - const configModel = options.overrideIdentifier ? this.cachedConfig.configWithOverrides(options.overrideIdentifier) : this.cachedConfig; + const configModel = options.overrideIdentifier ? this.cachedConfig.override(options.overrideIdentifier) : this.cachedConfig; return options.section ? configModel.getContentsFor(options.section) : configModel.contents; } @@ -198,8 +212,8 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp return { default: configurationValue.default, user: configurationValue.user, - workspace: objects.clone(getConfigurationValue(overrideIdentifier ? this.cachedWorkspaceConfig.configWithOverrides(overrideIdentifier).contents : this.cachedWorkspaceConfig.contents, key)), - value: objects.clone(getConfigurationValue(overrideIdentifier ? this.cachedConfig.configWithOverrides(overrideIdentifier).contents : this.cachedConfig.contents, key)) + workspace: objects.clone(getConfigurationValue(overrideIdentifier ? this.cachedWorkspaceConfig.override(overrideIdentifier).contents : this.cachedWorkspaceConfig.contents, key)), + value: objects.clone(getConfigurationValue(overrideIdentifier ? this.cachedConfig.override(overrideIdentifier).contents : this.cachedConfig.contents, key)) }; } @@ -273,7 +287,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp this.cachedWorkspaceConfig = new WorkspaceConfigModel(workspaceSettingsConfig, otherConfigModels); // Override base (global < user) with workspace locals (global < user < workspace) - this.cachedConfig = >this.baseConfigurationService.getCache().consolidated // global/default values (do NOT modify) + this.cachedConfig = >this.baseConfigurationService.getCache().consolidated // global/default values (do NOT modify) .merge(this.cachedWorkspaceConfig); // workspace configured values return { @@ -283,7 +297,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp }); } - private loadWorkspaceConfigFiles(): TPromise<{ [relativeWorkspacePath: string]: IConfigModel }> { + private loadWorkspaceConfigFiles(): TPromise<{ [relativeWorkspacePath: string]: Configuration }> { // Return early if we don't have a workspace if (!this.workspace) { @@ -368,7 +382,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } } - private createConfigModel(content: IContent): IConfigModel { + private createConfigModel(content: IContent): Configuration { const path = this.toWorkspaceRelativePath(content.resource); if (path === WORKSPACE_CONFIG_DEFAULT_PATH) { return new WorkspaceSettingsConfigModel(content.value, content.resource.toString()); @@ -379,7 +393,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } } - return new ConfigModel(null); + return new Configuration(); } private isWorkspaceConfigurationFile(workspaceRelativePath: string): boolean { @@ -426,4 +440,4 @@ function resolveStat(resource: URI): TPromise { } }); }); -} \ No newline at end of file +} diff --git a/src/vs/workbench/services/configurationResolver/node/configurationResolverService.ts b/src/vs/workbench/services/configurationResolver/node/configurationResolverService.ts index 3caa6312379..7dcd63979b0 100644 --- a/src/vs/workbench/services/configurationResolver/node/configurationResolverService.ts +++ b/src/vs/workbench/services/configurationResolver/node/configurationResolverService.ts @@ -214,7 +214,7 @@ export class ConfigurationResolverService implements IConfigurationResolverServi } // We need a map from interactive variables to keys because we only want to trigger an command once per key - - // even though it might occure multiple times in configuration #7026. + // even though it might occur multiple times in configuration #7026. const interactiveVariablesToSubstitutes: { [interactiveVariable: string]: { object: any, key: string }[] } = {}; const findInteractiveVariables = (object: any) => { Object.keys(object).forEach(key => { diff --git a/src/vs/workbench/services/editor/browser/editorService.ts b/src/vs/workbench/services/editor/browser/editorService.ts index e8b52c75a1e..3e32edce31d 100644 --- a/src/vs/workbench/services/editor/browser/editorService.ts +++ b/src/vs/workbench/services/editor/browser/editorService.ts @@ -30,7 +30,7 @@ export interface IEditorPart { openEditors(editors: { input: IEditorInput, position: Position, options?: IEditorOptions | ITextEditorOptions }[]): TPromise; replaceEditors(editors: { toReplace: IEditorInput, replaceWith: IEditorInput, options?: IEditorOptions | ITextEditorOptions }[], position?: Position): TPromise; closeEditor(position: Position, input: IEditorInput): TPromise; - closeEditors(position: Position, except?: IEditorInput, direction?: Direction): TPromise; + closeEditors(position: Position, filter?: { except?: IEditorInput, direction?: Direction, unmodifiedOnly?: boolean }): TPromise; closeAllEditors(except?: Position): TPromise; getActiveEditor(): BaseEditor; getVisibleEditors(): IEditor[]; @@ -194,8 +194,8 @@ export class WorkbenchEditorService implements IWorkbenchEditorService { return this.editorPart.closeEditor(position, input); } - public closeEditors(position: Position, except?: IEditorInput, direction?: Direction): TPromise { - return this.editorPart.closeEditors(position, except, direction); + public closeEditors(position: Position, filter?: { except?: IEditorInput, direction?: Direction, unmodifiedOnly?: boolean }): TPromise { + return this.editorPart.closeEditors(position, filter); } public closeAllEditors(except?: Position): TPromise { diff --git a/src/vs/workbench/services/editor/common/editorService.ts b/src/vs/workbench/services/editor/common/editorService.ts index abedce481a0..5381c9de4e7 100644 --- a/src/vs/workbench/services/editor/common/editorService.ts +++ b/src/vs/workbench/services/editor/common/editorService.ts @@ -80,7 +80,7 @@ export interface IWorkbenchEditorService extends IEditorService { * will not be closed. The direction can be used in that case to control if all other editors should get closed, * or towards a specific direction. */ - closeEditors(position: Position, except?: IEditorInput, direction?: Direction): TPromise; + closeEditors(position: Position, filter?: { except?: IEditorInput, direction?: Direction, unmodifiedOnly?: boolean }): TPromise; /** * Closes all editors across all groups. The optional position allows to keep one group alive. diff --git a/src/vs/workbench/services/editor/test/browser/editorService.test.ts b/src/vs/workbench/services/editor/test/browser/editorService.test.ts index 4dd5a44fe16..1c3c11e3c10 100644 --- a/src/vs/workbench/services/editor/test/browser/editorService.test.ts +++ b/src/vs/workbench/services/editor/test/browser/editorService.test.ts @@ -51,7 +51,7 @@ class TestEditorPart implements IEditorPart { return TPromise.as([]); } - public closeEditors(position: Position, except?: EditorInput, direction?: Direction): TPromise { + public closeEditors(position: Position, filter?: { except?: EditorInput, direction?: Direction, unmodifiedOnly?: boolean }): TPromise { return TPromise.as(null); } diff --git a/src/vs/workbench/test/browser/editorStacksModel.test.ts b/src/vs/workbench/test/browser/editorStacksModel.test.ts index 8d96c2e5c80..3df007262ae 100644 --- a/src/vs/workbench/test/browser/editorStacksModel.test.ts +++ b/src/vs/workbench/test/browser/editorStacksModel.test.ts @@ -1764,6 +1764,24 @@ suite('Editor Stacks Model', () => { assert.equal(input1.isDisposed(), false); }); + test('Stack - Multiple Editors - Editor Not Disposed after Closing when opening Modified side (Diff Editor)', function () { + const model = create(); + + const group1 = model.openGroup('group1'); + + const input1 = input(); + const input2 = input(); + + const diffInput = new DiffEditorInput('name', 'description', input1, input2); + + group1.openEditor(diffInput, { pinned: false, active: true }); + group1.openEditor(input1, { pinned: false, active: true }); + + assert.equal(diffInput.isDisposed(), true); + assert.equal(input2.isDisposed(), true); + assert.equal(input1.isDisposed(), false); + }); + test('Stack - Multiple Editors - Editor Disposed on Close (same input, files)', function () { const model = create(); diff --git a/src/vs/workbench/test/browser/quickopen.test.ts b/src/vs/workbench/test/browser/quickopen.test.ts index caee483e75e..17baa336943 100644 --- a/src/vs/workbench/test/browser/quickopen.test.ts +++ b/src/vs/workbench/test/browser/quickopen.test.ts @@ -67,7 +67,8 @@ suite('Workbench QuickOpen', () => { 'test', 'TestHandler', ',', - 'Handler' + 'Handler', + null ); registry.registerQuickOpenHandler(handler); diff --git a/src/vs/workbench/test/electron-browser/api/extHostWorkspace.test.ts b/src/vs/workbench/test/electron-browser/api/extHostWorkspace.test.ts index 36430d52357..c66640c2bd7 100644 --- a/src/vs/workbench/test/electron-browser/api/extHostWorkspace.test.ts +++ b/src/vs/workbench/test/electron-browser/api/extHostWorkspace.test.ts @@ -14,7 +14,7 @@ suite('ExtHostWorkspace', function () { test('asRelativePath', function () { - const ws = new ExtHostWorkspace(new TestThreadService(), [URI.file('/Coding/Applications/NewsWoWBot')]); + const ws = new ExtHostWorkspace(new TestThreadService(), { id: 'foo', roots: [URI.file('/Coding/Applications/NewsWoWBot')] }); assert.equal(ws.getRelativePath('/Coding/Applications/NewsWoWBot/bernd/das/brot'), 'bernd/das/brot'); assert.equal(ws.getRelativePath('/Apps/DartPubCache/hosted/pub.dartlang.org/convert-2.0.1/lib/src/hex.dart'), @@ -28,7 +28,7 @@ suite('ExtHostWorkspace', function () { test('asRelativePath, same paths, #11402', function () { const root = '/home/aeschli/workspaces/samples/docker'; const input = '/home/aeschli/workspaces/samples/docker'; - const ws = new ExtHostWorkspace(new TestThreadService(), [URI.file(root)]); + const ws = new ExtHostWorkspace(new TestThreadService(), { id: 'foo', roots: [URI.file(root)] }); assert.equal(ws.getRelativePath(input), input); @@ -43,7 +43,7 @@ suite('ExtHostWorkspace', function () { }); test('asRelativePath, multiple folders', function () { - const ws = new ExtHostWorkspace(new TestThreadService(), [URI.file('/Coding/One'), URI.file('/Coding/Two')]); + const ws = new ExtHostWorkspace(new TestThreadService(), { id: 'foo', roots: [URI.file('/Coding/One'), URI.file('/Coding/Two')] }); assert.equal(ws.getRelativePath('/Coding/One/file.txt'), 'file.txt'); assert.equal(ws.getRelativePath('/Coding/Two/files/out.txt'), 'files/out.txt'); assert.equal(ws.getRelativePath('/Coding/Two2/files/out.txt'), '/Coding/Two2/files/out.txt'); diff --git a/src/vs/workbench/test/workbenchTestServices.ts b/src/vs/workbench/test/workbenchTestServices.ts index 3b299beef00..6cf8c61f13c 100644 --- a/src/vs/workbench/test/workbenchTestServices.ts +++ b/src/vs/workbench/test/workbenchTestServices.ts @@ -53,6 +53,7 @@ import { IEnvironmentService } from 'vs/platform/environment/common/environment' import { IThemeService, ITheme, DARK } from 'vs/platform/theme/common/themeService'; import { Color } from 'vs/base/common/color'; import { isLinux } from 'vs/base/common/platform'; +import { generateUuid } from "vs/base/common/uuid"; export function createFileInput(instantiationService: IInstantiationService, resource: URI): FileEditorInput { return instantiationService.createInstance(FileEditorInput, resource, void 0); @@ -64,12 +65,14 @@ export class TestContextService implements IWorkspaceContextService { public _serviceBrand: any; private workspace: any; + private id: string; private options: any; private _onDidChangeWorkspaceRoots: Emitter; constructor(workspace: any = TestWorkspace, options: any = null) { this.workspace = workspace; + this.id = generateUuid(); this.options = options || Object.create(null); this._onDidChangeWorkspaceRoots = new Emitter(); } @@ -91,7 +94,7 @@ export class TestContextService implements IWorkspaceContextService { } public getWorkspace2(): IWorkspace2 { - return this.workspace ? { id: `${this.workspace.uid}`, roots: [this.workspace.resource] } : void 0; + return this.workspace ? { id: this.id, roots: [this.workspace.resource], name: this.workspace.resource.fsPath } : void 0; } public setWorkspace(workspace: any): void { @@ -522,7 +525,7 @@ export class TestEditorService implements IWorkbenchEditorService { return TPromise.as([]); } - public closeEditors(position: Position, except?: IEditorInput, direction?: Direction): TPromise { + public closeEditors(position: Position, filter?: { except?: IEditorInput, direction?: Direction, unmodifiedOnly?: boolean }): TPromise { return TPromise.as(null); } diff --git a/test/smoke/README.md b/test/smoke/README.md index 947fb43969a..1c9df539b8e 100644 --- a/test/smoke/README.md +++ b/test/smoke/README.md @@ -11,6 +11,9 @@ If you want to include 'Data Migration' area tests use `npm test -- --latest pa * `./areas/` folder contains a `.ts` file per each area of the document. E.g. `'Search'` area goes under `'search.ts'`. Every area file contains a list of methods with the name that represents the action that can be performed in the corresponding test. This reduces the amount of test suite code and means that if the UI changes, the fix need only be applied in one place. The name of the method reflects the action the tester would do if he would perform the test manually. See [Selenium Page Objects Wiki](https://github.com/SeleniumHQ/selenium/wiki/PageObjects) and [Selenium Bot Style Tests Wiki](https://github.com/SeleniumHQ/selenium/wiki/Bot-Style-Tests) for a good explanation of the implementation. Every smoke test area contains methods that are used in a bot-style approach in `main.ts`. * `./spectron/` wraps the Spectron, with WebDriverIO API wrapped in `client.ts` and instance of Spectron Application is wrapped in `application.ts`. +* `./test_data/` folder contains temporary data used by smoke test (cloned express repository, temporary user-data-dir/extensions-dir). +* `./test_data/screenshots` has action screenshots captured by a smoke test when performing actions during runtime. Screenshots are split in folders per each test. + # Adding new area To contribute a new smoke test area, add `${area}.ts` file under `./areas/`. All related tests to the area should go to the alike named file under `./tests/${area}.ts`. This has to follow the bot-style approach described in the links mentioned above. Methods should be calling WebDriverIO API through `SpectronClient` class. If there is no existing WebDriverIO method, add it to the class. -- GitLab From 3c0bb6678d81fdc06658b2523986d2f41b428b81 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 15 Jun 2017 10:57:04 +0200 Subject: [PATCH 0860/1347] fix tests --- src/vs/workbench/services/configuration/node/configuration.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index 4c62132f61d..eae962acc3a 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -71,6 +71,10 @@ class Workspace implements IWorkspace2 { return this._name; } + + public toJSON(): IWorkspace2 { + return { id: this.id, roots: this.roots, name: this.name }; + } } export class WorkspaceConfigurationService extends Disposable implements IWorkspaceContextService, IWorkspaceConfigurationService { -- GitLab From b46e41cb36558a1d33d6445bfa422f4dc537d4c8 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Thu, 15 Jun 2017 10:57:14 +0200 Subject: [PATCH 0861/1347] Pass screen resolution argument correctly. --- build/tfs/linux/smoketest.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/tfs/linux/smoketest.sh b/build/tfs/linux/smoketest.sh index 33344082253..54f18db1774 100644 --- a/build/tfs/linux/smoketest.sh +++ b/build/tfs/linux/smoketest.sh @@ -29,5 +29,5 @@ step "Run smoke test" \ pushd test/smoke npm install npm run compile - xvfb-run -a -s="-screen 0 1024x768x8" node src/main.js --latest "$AGENT_BUILDDIRECTORY/VSCode-linux-ia32/code-insiders" + xvfb-run -a -s "-screen 0 1024x768x8" node src/main.js --latest "$AGENT_BUILDDIRECTORY/VSCode-linux-ia32/code-insiders" popd \ No newline at end of file -- GitLab From 03c919724f2b537d4948a063a4d8512696c9a32b Mon Sep 17 00:00:00 2001 From: isidor Date: Thu, 15 Jun 2017 10:59:10 +0200 Subject: [PATCH 0862/1347] explorerView: header area, also update on change workspace roots --- src/vs/workbench/parts/files/browser/views/explorerView.ts | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index acc79c91173..7366bde9697 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -120,7 +120,12 @@ export class ExplorerView extends CollapsibleView { public renderHeader(container: HTMLElement): void { const titleDiv = $('div.title').appendTo(container); - $('span').text(this.contextService.getWorkspace().name).title(labels.getPathLabel(this.contextService.getWorkspace().resource.fsPath, void 0, this.environmentService)).appendTo(titleDiv); + const setHeader = () => { + const title = this.contextService.getWorkspace2().roots.map(root => labels.getPathLabel(root.fsPath, void 0, this.environmentService)).join(); + $('span').text(this.contextService.getWorkspace2().name).title(title).appendTo(titleDiv); + }; + this.toDispose.push(this.contextService.onDidChangeWorkspaceRoots(() => setHeader())); + setHeader(); super.renderHeader(container); } -- GitLab From 836d40adbf949216e855da25c38cfa5c7d05026f Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Thu, 15 Jun 2017 11:27:09 +0200 Subject: [PATCH 0863/1347] Correct screenshotting logic. --- test/smoke/src/helpers/screenshot.ts | 8 +++---- test/smoke/src/spectron/client.ts | 36 ++++++++++++++-------------- 2 files changed, 22 insertions(+), 22 deletions(-) diff --git a/test/smoke/src/helpers/screenshot.ts b/test/smoke/src/helpers/screenshot.ts index 649c38493e4..d6a0b61370a 100644 --- a/test/smoke/src/helpers/screenshot.ts +++ b/test/smoke/src/helpers/screenshot.ts @@ -20,20 +20,20 @@ export class Screenshot { this.createFolder(this.testPath); } - public capture(): Promise { + public async capture(): Promise { return new Promise(async (res, rej) => { const image: Electron.NativeImage = await this.spectron.app.browserWindow.capturePage(); fs.writeFile(`${this.testPath}/${this.index}.png`, image, (err) => { if (err) { rej(err); } + this.index++; + res(); }); - this.index++; - res(); }); } - private createFolder(name: string) { + private createFolder(name: string): void { name.split('/').forEach((folderName, i, fullPath) => { const folder = fullPath.slice(0, i + 1).join('/'); if (!fs.existsSync(folder)) { diff --git a/test/smoke/src/spectron/client.ts b/test/smoke/src/spectron/client.ts index 6a9003199dc..93a4ef8deea 100644 --- a/test/smoke/src/spectron/client.ts +++ b/test/smoke/src/spectron/client.ts @@ -7,7 +7,7 @@ import { Application } from 'spectron'; import { Screenshot } from '../helpers/screenshot'; /** - * Abstracts the Spectron's WebdriverIO managed client property on the created Application instances. + * Abstracts the Spectron's WebdriverIO managed client property on the created Application instances. */ export class SpectronClient { @@ -20,77 +20,77 @@ export class SpectronClient { } public async keys(keys: string[] | string, capture: boolean = true): Promise { - await this.execute(capture); + await this.screenshot(capture); return this.spectron.client.keys(keys); } public async getText(selector: string, capture: boolean = true): Promise { - await this.execute(capture); + await this.screenshot(capture); return this.spectron.client.getText(selector); } public async getHTML(selector: string, capture: boolean = true): Promise { - await this.execute(capture); + await this.screenshot(capture); return this.spectron.client.getHTML(selector); } public async click(selector: string, capture: boolean = true): Promise { - await this.execute(capture); + await this.screenshot(capture); return this.spectron.client.click(selector); } public async doubleClick(selector: string, capture: boolean = true): Promise { - await this.execute(capture); + await this.screenshot(capture); return this.spectron.client.doubleClick(selector); } public async leftClick(selector: string, xoffset: number, yoffset: number, capture: boolean = true): Promise { - await this.execute(capture); + await this.screenshot(capture); return this.spectron.client.leftClick(selector, xoffset, yoffset); } public async rightClick(selector: string, capture: boolean = true): Promise { - await this.execute(capture); + await this.screenshot(capture); return this.spectron.client.rightClick(selector); } public async moveToObject(selector: string, capture: boolean = true): Promise { - await this.execute(capture); + await this.screenshot(capture); return this.spectron.client.moveToObject(selector); } public async setValue(selector: string, text: string, capture: boolean = true): Promise { - await this.execute(capture); + await this.screenshot(capture); return this.spectron.client.setValue(selector, text); } public async elements(selector: string, capture: boolean = true): Promise { - await this.execute(capture); + await this.screenshot(capture); return this.spectron.client.elements(selector); } public async element(selector: string, capture: boolean = true): Promise { - await this.execute(capture); + await this.screenshot(capture); return this.spectron.client.element(selector); } public async dragAndDrop(sourceElem: string, destinationElem: string, capture: boolean = true): Promise { - await this.execute(capture); + await this.screenshot(capture); return this.spectron.client.dragAndDrop(sourceElem, destinationElem); } public async selectByValue(selector: string, value: string, capture: boolean = true): Promise { - await this.execute(capture); + await this.screenshot(capture); return this.spectron.client.selectByValue(selector, value); } public async getValue(selector: string, capture: boolean = true): Promise { - await this.execute(capture); + await this.screenshot(capture); return this.spectron.client.getValue(selector); } public async getAttribute(selector: string, attribute: string, capture: boolean = true): Promise { - await this.execute(capture); + await this.screenshot(capture); return Promise.resolve(this.spectron.client.getAttribute(selector, attribute)); } @@ -107,7 +107,7 @@ export class SpectronClient { } public async isVisible(selector: string, capture: boolean = true): Promise { - await this.execute(capture); + await this.screenshot(capture); return this.spectron.client.isVisible(selector); } @@ -115,7 +115,7 @@ export class SpectronClient { return this.spectron.client.getTitle(); } - private async execute(capture: boolean): Promise { + private async screenshot(capture: boolean): Promise { if (capture) { try { await this.shot.capture(); -- GitLab From 06966cae58e9c4885016f155c4e950f3e425a312 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Thu, 15 Jun 2017 11:45:59 +0200 Subject: [PATCH 0864/1347] log exthost output --- .../electron-browser/extensionHost.ts | 29 +++++++++++++++++-- 1 file changed, 27 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/electron-browser/extensionHost.ts b/src/vs/workbench/electron-browser/extensionHost.ts index fdf5531f05f..7cccc708393 100644 --- a/src/vs/workbench/electron-browser/extensionHost.ts +++ b/src/vs/workbench/electron-browser/extensionHost.ts @@ -28,7 +28,8 @@ import { IInstantiationService } from 'vs/platform/instantiation/common/instanti import { IMessagePassingProtocol } from 'vs/base/parts/ipc/common/ipc'; import { generateRandomPipeName, Protocol } from 'vs/base/parts/ipc/node/ipc.net'; import { createServer, Server } from 'net'; -import Event, { Emitter } from 'vs/base/common/event'; +import Event, { Emitter, debounceEvent, mapEvent, any } from 'vs/base/common/event'; +import { fromEventEmitter } from 'vs/base/node/event'; import { IInitData, IWorkspaceData } from 'vs/workbench/api/node/extHost.protocol'; import { MainProcessExtensionService } from 'vs/workbench/api/electron-browser/mainThreadExtensionService'; import { IWorkspaceConfigurationService } from 'vs/workbench/services/configuration/common/configuration'; @@ -130,7 +131,8 @@ export class ExtensionHostProcessWorker { detached: !!isWindows, execArgv: port ? ['--nolazy', (this.isExtensionDevelopmentDebugBrk ? '--debug-brk=' : '--debug=') + port] - : undefined + : undefined, + silent: true }; const crashReporterOptions = this.crashReporterService.getChildProcessStartOptions('extensionHost'); @@ -141,6 +143,29 @@ export class ExtensionHostProcessWorker { // Run Extension Host as fork of current process this.extensionHostProcess = fork(URI.parse(require.toUrl('bootstrap')).fsPath, ['--type=extensionHost'], opts); + type Output = { data: string, format: string[] }; + + this.extensionHostProcess.stdout.setEncoding('utf8'); + this.extensionHostProcess.stderr.setEncoding('utf8'); + const onStdout = fromEventEmitter(this.extensionHostProcess.stdout, 'data'); + const onStderr = fromEventEmitter(this.extensionHostProcess.stderr, 'data'); + const onOutput = any( + mapEvent(onStdout, o => ({ data: `%c${o}`, format: [''] })), + mapEvent(onStderr, o => ({ data: `%c${o}`, format: ['color: red'] })) + ); + + const onDebouncedOutput = debounceEvent(onOutput, (r, o) => { + return r + ? { data: r.data + o.data, format: [...r.format, ...o.format] } + : { data: o.data, format: o.format }; + }, 300); + + onDebouncedOutput(data => { + console.group('Extension Host'); + console.log(data.data, ...data.format); + console.groupEnd(); + }); + // Support logging from extension host this.extensionHostProcess.on('message', msg => { if (msg && (msg).type === '__$console') { -- GitLab From 078fa6d3dacb829130f4ee5213a177100cf669f2 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Thu, 15 Jun 2017 11:46:45 +0200 Subject: [PATCH 0865/1347] Converted mocha-runner to TS, indicated to exit smoke test on mocha tests termination. --- test/smoke/src/main.js | 2 +- .../smoke/src/{mocha-runner.js => mocha-runner.ts} | 14 ++++++-------- 2 files changed, 7 insertions(+), 9 deletions(-) rename test/smoke/src/{mocha-runner.js => mocha-runner.ts} (65%) diff --git a/test/smoke/src/main.js b/test/smoke/src/main.js index feedaf304e1..acf9db502d2 100644 --- a/test/smoke/src/main.js +++ b/test/smoke/src/main.js @@ -71,7 +71,7 @@ function runTests() { console.log('Running tests...') const spawn = require('child_process').spawn; var proc = spawn(process.execPath, [ - 'src/mocha-runner.js' + 'out/mocha-runner.js' ]); proc.stdout.on('data', data => { console.log(data.toString()); diff --git a/test/smoke/src/mocha-runner.js b/test/smoke/src/mocha-runner.ts similarity index 65% rename from test/smoke/src/mocha-runner.js rename to test/smoke/src/mocha-runner.ts index fe25e885544..62171a6dbc2 100644 --- a/test/smoke/src/mocha-runner.js +++ b/test/smoke/src/mocha-runner.ts @@ -3,19 +3,17 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -var Mocha = require('mocha'); -var path = require('path'); +const MochaTest = require('mocha'); +const path = require('path'); -var mocha = new Mocha({ +const mochaTest = new MochaTest({ timeout: 360000, retries: 2, slow: 50000, useColors: true }); -mocha.addFile(path.join(process.cwd(), 'out/test.js')); -mocha.run((failures) => { - process.on('exit', () => { - process.exit(failures); - }); +mochaTest.addFile(path.join(process.cwd(), 'out/test.js')); +mochaTest.run((failures) => { + process.exit(failures); }); \ No newline at end of file -- GitLab From fd1a43076bd979422779cd725ff1d6ffc2357794 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Thu, 15 Jun 2017 10:42:49 +0200 Subject: [PATCH 0866/1347] let->const --- .../editor/common/model/editableTextModel.ts | 36 +++++++++---------- 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/src/vs/editor/common/model/editableTextModel.ts b/src/vs/editor/common/model/editableTextModel.ts index 265d8486fa9..02527836786 100644 --- a/src/vs/editor/common/model/editableTextModel.ts +++ b/src/vs/editor/common/model/editableTextModel.ts @@ -475,7 +475,7 @@ export class EditableTextModel extends TextModelWithDecorations implements edito let contentChanges: textModelEvents.IModelContentChange[] = []; let lineEditsQueue: IIdentifiedLineEdit[] = []; - let queueLineEdit = (lineEdit: IIdentifiedLineEdit) => { + const queueLineEdit = (lineEdit: IIdentifiedLineEdit) => { if (lineEdit.startColumn === lineEdit.endColumn && lineEdit.text.length === 0) { // empty edit => ignore it return; @@ -483,7 +483,7 @@ export class EditableTextModel extends TextModelWithDecorations implements edito lineEditsQueue.push(lineEdit); }; - let flushLineEdits = () => { + const flushLineEdits = () => { if (lineEditsQueue.length === 0) { return; } @@ -495,7 +495,7 @@ export class EditableTextModel extends TextModelWithDecorations implements edito let currentLineNumberStart = 0; for (let i = 1, len = lineEditsQueue.length; i < len; i++) { - let lineNumber = lineEditsQueue[i].lineNumber; + const lineNumber = lineEditsQueue[i].lineNumber; if (lineNumber === currentLineNumber) { continue; @@ -533,7 +533,7 @@ export class EditableTextModel extends TextModelWithDecorations implements edito let totalLinesCountDelta = 0; for (let i = 0, len = operations.length; i < len; i++) { - let op = operations[i]; + const op = operations[i]; // console.log(); // console.log('-------------------'); @@ -541,26 +541,26 @@ export class EditableTextModel extends TextModelWithDecorations implements edito // console.log('op: ', op); // console.log('<<<\n' + this._lines.map(l => l.text).join('\n') + '\n>>>'); - let startLineNumber = op.range.startLineNumber; - let startColumn = op.range.startColumn; - let endLineNumber = op.range.endLineNumber; - let endColumn = op.range.endColumn; + const startLineNumber = op.range.startLineNumber; + const startColumn = op.range.startColumn; + const endLineNumber = op.range.endLineNumber; + const endColumn = op.range.endColumn; if (startLineNumber === endLineNumber && startColumn === endColumn && (!op.lines || op.lines.length === 0)) { // no-op continue; } - let deletingLinesCnt = endLineNumber - startLineNumber; - let insertingLinesCnt = (op.lines ? op.lines.length - 1 : 0); - let editingLinesCnt = Math.min(deletingLinesCnt, insertingLinesCnt); + const deletingLinesCnt = endLineNumber - startLineNumber; + const insertingLinesCnt = (op.lines ? op.lines.length - 1 : 0); + const editingLinesCnt = Math.min(deletingLinesCnt, insertingLinesCnt); totalLinesCountDelta += (insertingLinesCnt - deletingLinesCnt); // Iterating descending to overlap with previous op // in case there are common lines being edited in both for (let j = editingLinesCnt; j >= 0; j--) { - let editLineNumber = startLineNumber + j; + const editLineNumber = startLineNumber + j; queueLineEdit({ lineNumber: editLineNumber, @@ -577,18 +577,18 @@ export class EditableTextModel extends TextModelWithDecorations implements edito // Flush any pending line edits flushLineEdits(); - let spliceStartLineNumber = startLineNumber + editingLinesCnt; - let spliceStartColumn = this.getLineMaxColumn(spliceStartLineNumber); + const spliceStartLineNumber = startLineNumber + editingLinesCnt; + const spliceStartColumn = this.getLineMaxColumn(spliceStartLineNumber); let endLineRemains = this._lines[endLineNumber - 1].split(markersTracker, endColumn, false, tabSize); this._invalidateLine(spliceStartLineNumber - 1); - let spliceCnt = endLineNumber - spliceStartLineNumber; + const spliceCnt = endLineNumber - spliceStartLineNumber; // Collect all these markers let markersOnDeletedLines: LineMarker[] = []; for (let j = 0; j < spliceCnt; j++) { - let deleteLineIndex = spliceStartLineNumber + j; + const deleteLineIndex = spliceStartLineNumber + j; markersOnDeletedLines = markersOnDeletedLines.concat(this._lines[deleteLineIndex].deleteLine()); } @@ -606,7 +606,7 @@ export class EditableTextModel extends TextModelWithDecorations implements edito } // Update deleted markers - let deletedMarkersPosition = new Position(spliceStartLineNumber, spliceStartColumn); + const deletedMarkersPosition = new Position(spliceStartLineNumber, spliceStartColumn); for (let j = 0, lenJ = markersOnDeletedLines.length; j < lenJ; j++) { markersOnDeletedLines[j].updatePosition(markersTracker, deletedMarkersPosition); } @@ -627,7 +627,7 @@ export class EditableTextModel extends TextModelWithDecorations implements edito // Flush any pending line edits flushLineEdits(); - let spliceLineNumber = startLineNumber + editingLinesCnt; + const spliceLineNumber = startLineNumber + editingLinesCnt; let spliceColumn = (spliceLineNumber === startLineNumber ? startColumn : 1); if (op.lines) { spliceColumn += op.lines[editingLinesCnt].length; -- GitLab From f65fd0ad9cfbd31effddfa439218c298d8ec434a Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Thu, 15 Jun 2017 11:52:19 +0200 Subject: [PATCH 0867/1347] Fixes Microsoft/monaco-editor#351: Do not use splice in a loop --- src/vs/base/common/arrays.ts | 10 ++++++++++ src/vs/editor/common/model/editableTextModel.ts | 5 ++++- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/src/vs/base/common/arrays.ts b/src/vs/base/common/arrays.ts index ce2d4100429..72416376659 100644 --- a/src/vs/base/common/arrays.ts +++ b/src/vs/base/common/arrays.ts @@ -317,3 +317,13 @@ export function insert(array: T[], element: T): () => void { } }; } + +/** + * Insert `insertArr` inside `taget` at `insertIndex`. + * Please don't touch unless you understand https://jsperf.com/inserting-an-array-within-an-array + */ +export function arrayInsert(target: T[], insertIndex: number, insertArr: T[]): T[] { + const before = target.slice(0, insertIndex); + const after = target.slice(insertIndex); + return before.concat(insertArr, after); +} diff --git a/src/vs/editor/common/model/editableTextModel.ts b/src/vs/editor/common/model/editableTextModel.ts index 02527836786..cbc963424da 100644 --- a/src/vs/editor/common/model/editableTextModel.ts +++ b/src/vs/editor/common/model/editableTextModel.ts @@ -10,6 +10,7 @@ import { EditStack } from 'vs/editor/common/model/editStack'; import { ILineEdit, LineMarker, ModelLine, MarkersTracker } from 'vs/editor/common/model/modelLine'; import { TextModelWithDecorations, ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; import * as strings from 'vs/base/common/strings'; +import * as arrays from 'vs/base/common/arrays'; import { Selection } from 'vs/editor/common/core/selection'; import { Position } from 'vs/editor/common/core/position'; import { IDisposable } from 'vs/base/common/lifecycle'; @@ -645,14 +646,16 @@ export class EditableTextModel extends TextModelWithDecorations implements edito this._invalidateLine(spliceLineNumber - 1); // Lines in the middle + let newLines: ModelLine[] = []; let newLinesContent: string[] = []; let newLinesLengths = new Uint32Array(insertingLinesCnt - editingLinesCnt); for (let j = editingLinesCnt + 1; j <= insertingLinesCnt; j++) { let newLineNumber = startLineNumber + j; - this._lines.splice(newLineNumber - 1, 0, new ModelLine(newLineNumber, op.lines[j], tabSize)); + newLines.push(new ModelLine(newLineNumber, op.lines[j], tabSize)); newLinesContent.push(op.lines[j]); newLinesLengths[j - editingLinesCnt - 1] = op.lines[j].length + this._EOL.length; } + this._lines = arrays.arrayInsert(this._lines, startLineNumber + editingLinesCnt, newLines); newLinesContent[newLinesContent.length - 1] += leftoverLine.text; if (this._lineStarts) { // update prefix sum -- GitLab From ac08540b9459062599e946bdbf1e96d121ce0998 Mon Sep 17 00:00:00 2001 From: Andre Weinand Date: Thu, 15 Jun 2017 11:57:58 +0200 Subject: [PATCH 0868/1347] node-debug@1.14.2 --- build/gulpfile.vscode.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index e4e7211aaef..1af153e1e81 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -42,7 +42,7 @@ const nodeModules = ['electron', 'original-fs'] // Build const builtInExtensions = [ - { name: 'ms-vscode.node-debug', version: '1.14.1' }, + { name: 'ms-vscode.node-debug', version: '1.14.2' }, { name: 'ms-vscode.node-debug2', version: '1.14.0' } ]; -- GitLab From 6fdfe2f055cc3d842c2cbd0c595e227a1df81c46 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 15 Jun 2017 10:40:45 +0200 Subject: [PATCH 0869/1347] fix ts 2.4.1 compile errors in workbench/api --- .../electron-browser/mainThreadDocumentsAndEditors.ts | 11 ++++------- src/vs/workbench/api/node/extHost.api.impl.ts | 4 ++-- src/vs/workbench/api/node/extHost.protocol.ts | 4 ++-- src/vs/workbench/api/node/extHostCommands.ts | 2 +- src/vs/workbench/api/node/extHostMessageService.ts | 4 +++- src/vs/workbench/api/node/extHostQuickOpen.ts | 4 +++- 6 files changed, 15 insertions(+), 14 deletions(-) diff --git a/src/vs/workbench/api/electron-browser/mainThreadDocumentsAndEditors.ts b/src/vs/workbench/api/electron-browser/mainThreadDocumentsAndEditors.ts index 974d8a45c70..a6be9198dd5 100644 --- a/src/vs/workbench/api/electron-browser/mainThreadDocumentsAndEditors.ts +++ b/src/vs/workbench/api/electron-browser/mainThreadDocumentsAndEditors.ts @@ -10,7 +10,7 @@ import { compare } from 'vs/base/common/strings'; import { delta } from 'vs/base/common/arrays'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { ICodeEditorService } from 'vs/editor/common/services/codeEditorService'; -import Event, { Emitter, any } from 'vs/base/common/event'; +import Event, { Emitter } from 'vs/base/common/event'; import { ExtHostContext, ExtHostDocumentsAndEditorsShape, IModelAddedData, ITextEditorAddData, IDocumentsAndEditorsDelta } from '../node/extHost.protocol'; import { MainThreadTextEditor } from './mainThreadEditor'; import { IThreadService } from 'vs/workbench/services/thread/common/threadService'; @@ -127,12 +127,9 @@ class MainThreadDocumentAndEditorStateComputer { } private _onDidAddEditor(e: ICommonCodeEditor): void { - const listener = any( - e.onDidChangeModel, - e.onDidFocusEditor, - e.onDidBlurEditor - )(this._updateState, this); - this._toDisposeOnEditorRemove.set(e.getId(), listener); + this._toDisposeOnEditorRemove.set(e.getId(), e.onDidChangeModel(() => this._updateState())); + this._toDisposeOnEditorRemove.set(e.getId(), e.onDidFocusEditor(() => this._updateState())); + this._toDisposeOnEditorRemove.set(e.getId(), e.onDidBlurEditor(() => this._updateState())); this._updateState(); } diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index 7808ff172bb..92943aa1520 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -129,7 +129,7 @@ export function createApiFactory( return extHostCommands.registerCommand(id, command, thisArgs); }, registerTextEditorCommand(id: string, callback: (textEditor: vscode.TextEditor, edit: vscode.TextEditorEdit, ...args: any[]) => void, thisArg?: any): vscode.Disposable { - return extHostCommands.registerCommand(id, (...args: any[]) => { + return extHostCommands.registerCommand(id, (...args: any[]): any => { let activeTextEditor = extHostEditors.getActiveTextEditor(); if (!activeTextEditor) { console.warn('Cannot execute ' + id + ' because there is no active text editor.'); @@ -313,7 +313,7 @@ export function createApiFactory( }, withScmProgress(task: (progress: vscode.Progress) => Thenable) { console.warn(`[Deprecation Warning] function 'withScmProgress' is deprecated and should no longer be used. Use 'withProgress' instead.`); - return extHostProgress.withProgress(extension, { location: extHostTypes.ProgressLocation.SourceControl }, task); + return extHostProgress.withProgress(extension, { location: extHostTypes.ProgressLocation.SourceControl }, (progress, token) => task({ report(n: number) { /*noop*/ } })); }, withProgress(options: vscode.ProgressOptions, task: (progress: vscode.Progress<{ message?: string; percentage?: number }>) => Thenable) { return extHostProgress.withProgress(extension, options, task); diff --git a/src/vs/workbench/api/node/extHost.protocol.ts b/src/vs/workbench/api/node/extHost.protocol.ts index c7f432d81bb..20cf8960029 100644 --- a/src/vs/workbench/api/node/extHost.protocol.ts +++ b/src/vs/workbench/api/node/extHost.protocol.ts @@ -84,9 +84,9 @@ export class InstanceCollection { public define(id: ProxyIdentifier): InstanceSetter { let that = this; return new class { - set(value: T) { + set(value: T): R { that._set(id, value); - return value; + return value; } }; } diff --git a/src/vs/workbench/api/node/extHostCommands.ts b/src/vs/workbench/api/node/extHostCommands.ts index 2095dac3b4a..e9c3afe662b 100644 --- a/src/vs/workbench/api/node/extHostCommands.ts +++ b/src/vs/workbench/api/node/extHostCommands.ts @@ -218,7 +218,7 @@ export class CommandsConverter { } } - private _executeConvertedCommand(...args: any[]) { + private _executeConvertedCommand(...args: any[]): Thenable { const actualCmd = this._heap.get(args[0]); return this._commands.executeCommand(actualCmd.command, ...actualCmd.arguments); } diff --git a/src/vs/workbench/api/node/extHostMessageService.ts b/src/vs/workbench/api/node/extHostMessageService.ts index 32572895213..31d5cbdcd22 100644 --- a/src/vs/workbench/api/node/extHostMessageService.ts +++ b/src/vs/workbench/api/node/extHostMessageService.ts @@ -31,7 +31,9 @@ export class ExtHostMessageService { this._proxy = threadService.get(MainContext.MainThreadMessageService); } - showMessage(severity: Severity, message: string, optionsOrFirstItem: vscode.MessageOptions | string | vscode.MessageItem, rest: (string | vscode.MessageItem)[]): Thenable { + showMessage(severity: Severity, message: string, optionsOrFirstItem: vscode.MessageOptions | string, rest: string[]): Thenable; + showMessage(severity: Severity, message: string, optionsOrFirstItem: vscode.MessageOptions | vscode.MessageItem, rest: vscode.MessageItem[]): Thenable; + showMessage(severity: Severity, message: string, optionsOrFirstItem: vscode.MessageOptions | string | vscode.MessageItem, rest: (string | vscode.MessageItem)[]): Thenable { const { options, items } = parseMessageArguments(optionsOrFirstItem, rest); const commands: { title: string; isCloseAffordance: boolean; handle: number; }[] = []; diff --git a/src/vs/workbench/api/node/extHostQuickOpen.ts b/src/vs/workbench/api/node/extHostQuickOpen.ts index 05cab704c0f..183dcd1d7bc 100644 --- a/src/vs/workbench/api/node/extHostQuickOpen.ts +++ b/src/vs/workbench/api/node/extHostQuickOpen.ts @@ -24,7 +24,9 @@ export class ExtHostQuickOpen extends ExtHostQuickOpenShape { this._proxy = threadService.get(MainContext.MainThreadQuickOpen); } - showQuickPick(itemsOrItemsPromise: Item[] | Thenable, options?: QuickPickOptions, token: CancellationToken = CancellationToken.None): Thenable { + showQuickPick(itemsOrItemsPromise: string[] | Thenable, options?: QuickPickOptions, token?: CancellationToken): Thenable; + showQuickPick(itemsOrItemsPromise: QuickPickItem[] | Thenable, options?: QuickPickOptions, token?: CancellationToken): Thenable; + showQuickPick(itemsOrItemsPromise: Item[] | Thenable, options?: QuickPickOptions, token: CancellationToken = CancellationToken.None): Thenable { // clear state from last invocation this._onDidSelectItem = undefined; -- GitLab From c80efd221b7f2f86e84433070ff220adedbac933 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 15 Jun 2017 11:59:11 +0200 Subject: [PATCH 0870/1347] debt - fix more ts 2.4.1 compile issues --- src/typings/node.d.ts | 33 ++++++++++--------- src/vs/base/common/event.ts | 4 +-- src/vs/base/node/extfs.ts | 2 +- .../browser/goToDeclarationCommands.ts | 2 +- .../browser/messageController.ts | 13 +++----- .../electron-browser/menusExtensionPoint.ts | 28 ++++++++-------- .../progress/browser/progressService2.ts | 2 +- .../api/extHostCommands.test.ts | 4 +-- 8 files changed, 43 insertions(+), 45 deletions(-) diff --git a/src/typings/node.d.ts b/src/typings/node.d.ts index aa5953d8f15..8c33c5a8412 100644 --- a/src/typings/node.d.ts +++ b/src/typings/node.d.ts @@ -88,10 +88,10 @@ interface NodeModule { // Same as module.exports declare var exports: any; declare var SlowBuffer: { - new (str: string, encoding?: string): Buffer; - new (size: number): Buffer; - new (size: Uint8Array): Buffer; - new (array: any[]): Buffer; + new(str: string, encoding?: string): Buffer; + new(size: number): Buffer; + new(size: Uint8Array): Buffer; + new(array: any[]): Buffer; prototype: Buffer; isBuffer(obj: any): boolean; byteLength(string: string, encoding?: string): number; @@ -115,19 +115,19 @@ declare var Buffer: { * @param str String to store in buffer. * @param encoding encoding to use, optional. Default is 'utf8' */ - new (str: string, encoding?: string): Buffer; + new(str: string, encoding?: string): Buffer; /** * Allocates a new buffer of {size} octets. * * @param size count of octets to allocate. */ - new (size: number): Buffer; + new(size: number): Buffer; /** * Allocates a new buffer containing the given {array} of octets. * * @param array The octets to store. */ - new (array: Uint8Array): Buffer; + new(array: Uint8Array): Buffer; /** * Produces a Buffer backed by the same allocated memory as * the given {ArrayBuffer}. @@ -135,19 +135,19 @@ declare var Buffer: { * * @param arrayBuffer The ArrayBuffer with which to share memory. */ - new (arrayBuffer: ArrayBuffer): Buffer; + new(arrayBuffer: ArrayBuffer): Buffer; /** * Allocates a new buffer containing the given {array} of octets. * * @param array The octets to store. */ - new (array: any[]): Buffer; + new(array: any[]): Buffer; /** * Copies the passed {buffer} data onto a new {Buffer} instance. * * @param buffer The buffer to copy. */ - new (buffer: Buffer): Buffer; + new(buffer: Buffer): Buffer; prototype: Buffer; /** * Allocates a new Buffer using an {array} of octets. @@ -250,7 +250,7 @@ declare var Buffer: { declare namespace NodeJS { export var Console: { prototype: Console; - new (stdout: WritableStream, stderr?: WritableStream): Console; + new(stdout: WritableStream, stderr?: WritableStream): Console; } export interface ErrnoException extends Error { @@ -1324,7 +1324,7 @@ declare module "https" { } export var Agent: { - new (options?: AgentOptions): Agent; + new(options?: AgentOptions): Agent; }; export interface Server extends tls.Server { } export function createServer(options: ServerOptions, requestListener?: Function): Server; @@ -1959,7 +1959,7 @@ declare module "net" { } export var Socket: { - new (options?: { fd?: string; type?: string; allowHalfOpen?: boolean; }): Socket; + new(options?: { fd?: string; type?: string; allowHalfOpen?: boolean; }): Socket; }; export interface ListenOptions { @@ -2464,6 +2464,7 @@ declare module "fs" { */ export function readFileSync(filename: string, options?: { flag?: string; }): Buffer; export function writeFile(filename: string | number, data: any, callback?: (err: NodeJS.ErrnoException) => void): void; + export function writeFile(filename: string | number, data: any, options: string, callback?: (err: NodeJS.ErrnoException) => void): void; export function writeFile(filename: string | number, data: any, options: { encoding?: string; mode?: number; flag?: string; }, callback?: (err: NodeJS.ErrnoException) => void): void; export function writeFile(filename: string | number, data: any, options: { encoding?: string; mode?: string; flag?: string; }, callback?: (err: NodeJS.ErrnoException) => void): void; export function writeFileSync(filename: string, data: any, options?: { encoding?: string; mode?: number; flag?: string; }): void; @@ -2780,7 +2781,7 @@ declare module "string_decoder" { end(buffer?: Buffer): string; } export var StringDecoder: { - new (encoding?: string): NodeStringDecoder; + new(encoding?: string): NodeStringDecoder; }; } @@ -3184,7 +3185,7 @@ declare module "crypto" { verifySpkac(spkac: Buffer): boolean; } export var Certificate: { - new (): Certificate; + new(): Certificate; (): Certificate; } @@ -4128,6 +4129,6 @@ declare module "_debugger" { } export var Client: { - new (): ClientInstance + new(): ClientInstance } } diff --git a/src/vs/base/common/event.ts b/src/vs/base/common/event.ts index 2b68de0c2e3..adbac3e5776 100644 --- a/src/vs/base/common/event.ts +++ b/src/vs/base/common/event.ts @@ -409,11 +409,11 @@ class ChainableEvent implements IChainableEvent { constructor(private _event: Event) { } - map(fn) { + map(fn: (i: T) => O): IChainableEvent { return new ChainableEvent(mapEvent(this._event, fn)); } - filter(fn) { + filter(fn: (e: T) => boolean): IChainableEvent { return new ChainableEvent(filterEvent(this._event, fn)); } diff --git a/src/vs/base/node/extfs.ts b/src/vs/base/node/extfs.ts index ecffac0980d..6b99256462b 100644 --- a/src/vs/base/node/extfs.ts +++ b/src/vs/base/node/extfs.ts @@ -451,4 +451,4 @@ export function realpath(path: string, callback: (error: Error, realpath: string function normalizePath(path: string): string { return strings.rtrim(paths.normalize(path), paths.sep); -} \ No newline at end of file +} diff --git a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.ts b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.ts index 7db3d8f0c5a..0115099afdc 100644 --- a/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.ts +++ b/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.ts @@ -149,7 +149,7 @@ export class DefinitionAction extends EditorAction { revealIfVisible: !sideBySide } }, sideBySide).then(editor => { - return editor && editor.getControl(); + return editor && editor.getControl(); }); } diff --git a/src/vs/editor/contrib/goToDeclaration/browser/messageController.ts b/src/vs/editor/contrib/goToDeclaration/browser/messageController.ts index d5453254827..4951c14ec8c 100644 --- a/src/vs/editor/contrib/goToDeclaration/browser/messageController.ts +++ b/src/vs/editor/contrib/goToDeclaration/browser/messageController.ts @@ -6,7 +6,6 @@ 'use strict'; import 'vs/css!./messageController'; -import { any } from 'vs/base/common/event'; import { setDisposableTimeout } from 'vs/base/common/async'; import { KeyCode } from 'vs/base/common/keyCodes'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; @@ -62,12 +61,10 @@ export class MessageController { this._messageWidget = new MessageWidget(this._editor, position, message); // close on blur, cursor, model change, dispose - this._messageListeners.push(any( - this._editor.onDidBlurEditorText, - this._editor.onDidChangeCursorPosition, - this._editor.onDidDispose, - this._editor.onDidChangeModel - )(this.closeMessage, this)); + this._messageListeners.push(this._editor.onDidBlurEditorText(() => this.closeMessage())); + this._messageListeners.push(this._editor.onDidChangeCursorPosition(() => this.closeMessage())); + this._messageListeners.push(this._editor.onDidDispose(() => this.closeMessage())); + this._messageListeners.push(this._editor.onDidChangeModel(() => this.closeMessage())); // close after 3s this._messageListeners.push(setDisposableTimeout(() => this.closeMessage(), 3000)); @@ -184,4 +181,4 @@ registerThemingParticipant((theme, collector) => { if (background) { collector.addRule(`.monaco-editor .monaco-editor-overlaymessage .message { background-color: ${background}; }`); } -}); \ No newline at end of file +}); diff --git a/src/vs/platform/actions/electron-browser/menusExtensionPoint.ts b/src/vs/platform/actions/electron-browser/menusExtensionPoint.ts index 0e9b8d4f004..401e489ee0f 100644 --- a/src/vs/platform/actions/electron-browser/menusExtensionPoint.ts +++ b/src/vs/platform/actions/electron-browser/menusExtensionPoint.ts @@ -234,22 +234,22 @@ namespace schema { }, icon: { description: localize('vscode.extension.contributes.commandType.icon', '(Optional) Icon which is used to represent the command in the UI. Either a file path or a themable configuration'), - anyOf: [ - 'string', - { - type: 'object', - properties: { - light: { - description: localize('vscode.extension.contributes.commandType.icon.light', 'Icon path when a light theme is used'), - type: 'string' - }, - dark: { - description: localize('vscode.extension.contributes.commandType.icon.dark', 'Icon path when a dark theme is used'), - type: 'string' - } + anyOf: [{ + type: 'string' + }, + { + type: 'object', + properties: { + light: { + description: localize('vscode.extension.contributes.commandType.icon.light', 'Icon path when a light theme is used'), + type: 'string' + }, + dark: { + description: localize('vscode.extension.contributes.commandType.icon.dark', 'Icon path when a dark theme is used'), + type: 'string' } } - ] + }] } } }; diff --git a/src/vs/workbench/services/progress/browser/progressService2.ts b/src/vs/workbench/services/progress/browser/progressService2.ts index 583d16c913d..7f55c70b15e 100644 --- a/src/vs/workbench/services/progress/browser/progressService2.ts +++ b/src/vs/workbench/services/progress/browser/progressService2.ts @@ -129,7 +129,7 @@ export class ProgressService2 implements IProgressService2 { } } - private _withViewletProgress(viewletId: string, task: (progress: IProgress) => TPromise): void { + private _withViewletProgress(viewletId: string, task: (progress: IProgress<{ message?: string, percentage?: number }>) => TPromise): void { const promise = task(emptyProgress); diff --git a/src/vs/workbench/test/electron-browser/api/extHostCommands.test.ts b/src/vs/workbench/test/electron-browser/api/extHostCommands.test.ts index 447581c40b0..9e4fb57d019 100644 --- a/src/vs/workbench/test/electron-browser/api/extHostCommands.test.ts +++ b/src/vs/workbench/test/electron-browser/api/extHostCommands.test.ts @@ -29,7 +29,7 @@ suite('ExtHostCommands', function () { }; const commands = new ExtHostCommands(OneGetThreadService(shape), undefined); - commands.registerCommand('foo', () => { }).dispose(); + commands.registerCommand('foo', (): any => { }).dispose(); assert.equal(lastUnregister, 'foo'); assert.equal(CommandsRegistry.getCommand('foo'), undefined); @@ -50,7 +50,7 @@ suite('ExtHostCommands', function () { }; const commands = new ExtHostCommands(OneGetThreadService(shape), undefined); - const reg = commands.registerCommand('foo', () => { }); + const reg = commands.registerCommand('foo', (): any => { }); reg.dispose(); reg.dispose(); reg.dispose(); -- GitLab From 47794539771b5e755fe1886466af6ea0b64eece3 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Thu, 15 Jun 2017 12:52:54 +0200 Subject: [PATCH 0871/1347] Expose require to Spectron if running smoke test. --- src/vs/workbench/electron-browser/bootstrap/index.js | 4 ++++ test/smoke/src/main.js | 1 + 2 files changed, 5 insertions(+) diff --git a/src/vs/workbench/electron-browser/bootstrap/index.js b/src/vs/workbench/electron-browser/bootstrap/index.js index c01da62847a..a094c0daba5 100644 --- a/src/vs/workbench/electron-browser/bootstrap/index.js +++ b/src/vs/workbench/electron-browser/bootstrap/index.js @@ -12,6 +12,10 @@ if (window.location.search.indexOf('prof-startup') >= 0) { profiler.startProfiling('renderer', true); } +if (process.env.SMOKE_TEST) { + window.electronRequire = require; // if smoke test, expose require to Spectron to access the core Electron APIs +} + /*global window,document,define*/ const startTimer = require('../../../base/node/startupTimers').startTimer; diff --git a/test/smoke/src/main.js b/test/smoke/src/main.js index acf9db502d2..d9136eed600 100644 --- a/test/smoke/src/main.js +++ b/test/smoke/src/main.js @@ -42,6 +42,7 @@ if (parseInt(process.version.substr(1)) < 6) { } // Setting up environment variables +process.env.SMOKE_TEST = 'true'; process.env.VSCODE_LATEST_PATH = program.latest; if (program.stable) process.env.VSCODE_STABLE_PATH = program.stable; process.env.SMOKETEST_REPO = testRepoLocalDir; -- GitLab From 937caced3b0fa017c5b0023380c68973946fef7c Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Thu, 15 Jun 2017 13:01:04 +0200 Subject: [PATCH 0872/1347] Missing indication of requireName added as a follow up on 47794539771b5e755fe1886466af6ea0b64eece3. --- test/smoke/src/spectron/application.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/smoke/src/spectron/application.ts b/test/smoke/src/spectron/application.ts index 76443e8ec10..03cc56070d4 100644 --- a/test/smoke/src/spectron/application.ts +++ b/test/smoke/src/spectron/application.ts @@ -52,7 +52,8 @@ export class SpectronApplication { this.spectron = new Application({ path: electronPath, args: args, - chromeDriverArgs: chromeDriverArgs + chromeDriverArgs: chromeDriverArgs, + requireName: 'electronRequire' }); this.screenshot = new Screenshot(this, testName); this.client = new SpectronClient(this.spectron, this.screenshot); -- GitLab From 9ca12f681f8017de0c0255caac5d5fe3cfb150bb Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Thu, 15 Jun 2017 13:28:24 +0200 Subject: [PATCH 0873/1347] #28538 Support settings for multi root workspace - Refactor configuration services to read settings from multiple folders - Implement merging strategy for multi root workspace settings - Implement a configuration model that can be reused across layers - Implement getRoot API in workspace context service --- src/vs/base/common/map.ts | 21 +- .../browser/standalone/simpleServices.ts | 9 +- .../configuration/common/configuration.ts | 121 +++++- src/vs/platform/configuration/common/model.ts | 6 +- .../node/configurationService.ts | 60 +-- .../test/common/configuration.test.ts | 18 +- .../configuration/test/common/model.test.ts | 40 +- .../test/common/testConfigurationService.ts | 6 +- .../electron-browser/telemetryService.test.ts | 5 +- src/vs/platform/workspace/common/workspace.ts | 6 + .../browser/parts/editor/textEditor.ts | 23 +- .../terminalConfigHelper.test.ts | 5 +- .../common/configurationModels.ts | 10 +- .../configuration/node/configuration.ts | 389 ++++++++++++------ .../test/common/configurationModels.test.ts | 28 +- .../node/configurationResolverService.test.ts | 4 +- .../workbench/test/workbenchTestServices.ts | 6 +- 17 files changed, 515 insertions(+), 242 deletions(-) diff --git a/src/vs/base/common/map.ts b/src/vs/base/common/map.ts index 9e7d7dc8d73..9b5804ee96f 100644 --- a/src/vs/base/common/map.ts +++ b/src/vs/base/common/map.ts @@ -22,6 +22,12 @@ export function values(map: Map): V[] { return result; } +export function keys(map: Map): K[] { + const result: K[] = []; + map.forEach((value, key) => result.push(key)); + return result; +} + export function getOrSet(map: Map, key: K, value: V): V { let result = map.get(key); if (result === void 0) { @@ -331,7 +337,8 @@ export class TrieMap { } export class ResourceMap { - private map: Map; + + protected map: Map; constructor(private ignoreCase?: boolean) { this.map = new Map(); @@ -379,6 +386,18 @@ export class ResourceMap { } } +export class StrictResourceMap extends ResourceMap { + + constructor() { + super(); + } + + public keys(): URI[] { + return keys(this.map).map(key => URI.parse(key)); + } + +} + // We should fold BoundedMap and LinkedMap. See https://github.com/Microsoft/vscode/issues/28496 interface Item { diff --git a/src/vs/editor/browser/standalone/simpleServices.ts b/src/vs/editor/browser/standalone/simpleServices.ts index a177a093718..da2acd51c1f 100644 --- a/src/vs/editor/browser/standalone/simpleServices.ts +++ b/src/vs/editor/browser/standalone/simpleServices.ts @@ -450,12 +450,13 @@ export class SimpleConfigurationService implements IConfigurationService { return { value: getConfigurationValue(this.getConfiguration(), key), default: getConfigurationValue(this.getConfiguration(), key), - user: getConfigurationValue(this.getConfiguration(), key) + user: getConfigurationValue(this.getConfiguration(), key), + workspace: void 0 }; } public keys(): IConfigurationKeys { - return { default: [], user: [] }; + return { default: [], user: [], workspace: [] }; } } @@ -519,6 +520,10 @@ export class SimpleWorkspaceContextService implements IWorkspaceContextService { return this.workspace ? { id: `${this.id}`, roots: [this.workspace.resource], name: this.workspace.resource.fsPath } : void 0; } + public getRoot(resource: URI): URI { + return this.isInsideWorkspace(resource) ? this.workspace.resource : null; + } + public hasWorkspace(): boolean { return !!this.workspace; } diff --git a/src/vs/platform/configuration/common/configuration.ts b/src/vs/platform/configuration/common/configuration.ts index 0aec692a2d8..b3baea8370c 100644 --- a/src/vs/platform/configuration/common/configuration.ts +++ b/src/vs/platform/configuration/common/configuration.ts @@ -7,6 +7,8 @@ import { TPromise } from 'vs/base/common/winjs.base'; import * as arrays from 'vs/base/common/arrays'; import * as types from 'vs/base/common/types'; import * as objects from 'vs/base/common/objects'; +import URI from 'vs/base/common/uri'; +import { StrictResourceMap } from 'vs/base/common/map'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; import Event from 'vs/base/common/event'; @@ -14,9 +16,12 @@ export const IConfigurationService = createDecorator('con export interface IConfigurationOptions { overrideIdentifier?: string; + resource?: URI; section?: string; } +export type IConfigurationValues = { [key: string]: IConfigurationValue }; + export interface IConfigurationService { _serviceBrand: any; @@ -59,6 +64,7 @@ export enum ConfigurationSource { export interface IConfigurationServiceEvent { /** + * TODO: Remove this * The full configuration. */ config: any; @@ -67,6 +73,7 @@ export interface IConfigurationServiceEvent { */ source: ConfigurationSource; /** + * TODO: Remove this * The part of the configuration contributed by the source of this event. */ sourceConfig: any; @@ -76,11 +83,13 @@ export interface IConfigurationValue { value: T; default: T; user: T; + workspace: T; } export interface IConfigurationKeys { default: string[]; user: string[]; + workspace: string[]; } /** @@ -123,7 +132,7 @@ export interface IOverrides { identifiers: string[]; } -export class Configuration { +export class ConfigurationModel { protected _keys: string[] = []; @@ -142,8 +151,8 @@ export class Configuration { return objects.clone(this.contents[section]); } - public override(identifier: string): Configuration { - const result = new Configuration(); + public override(identifier: string): ConfigurationModel { + const result = new ConfigurationModel(); const contents = objects.clone(this.contents); if (this._overrides) { for (const override of this._overrides) { @@ -156,14 +165,14 @@ export class Configuration { return result; } - public merge(other: Configuration, overwrite: boolean = true): Configuration { - const mergedModel = new Configuration(); + public merge(other: ConfigurationModel, overwrite: boolean = true): ConfigurationModel { + const mergedModel = new ConfigurationModel(); this.doMerge(mergedModel, this, overwrite); this.doMerge(mergedModel, other, overwrite); return mergedModel; } - protected doMerge(source: Configuration, target: Configuration, overwrite: boolean = true) { + protected doMerge(source: ConfigurationModel, target: ConfigurationModel, overwrite: boolean = true) { merge(source.contents, objects.clone(target.contents), overwrite); const overrides = objects.clone(source._overrides); for (const override of target._overrides) { @@ -176,4 +185,104 @@ export class Configuration { } source._overrides = overrides; } +} + +export class Configuration { + + private _global: ConfigurationModel; + private _workspace: ConfigurationModel; + protected _foldersConsolidated: StrictResourceMap>; + + constructor(protected _defaults: ConfigurationModel, protected _user: ConfigurationModel, protected folders: StrictResourceMap> = new StrictResourceMap>(), protected workspaceUri?: URI) { + this.merge(); + } + + get defaults(): ConfigurationModel { + return this._defaults; + } + + get user(): ConfigurationModel { + return this._user; + } + + get workspace(): ConfigurationModel { + return this._workspace; + } + + protected merge(): void { + this._global = this._workspace = new ConfigurationModel().merge(this._defaults).merge(this._user); + this._foldersConsolidated = new StrictResourceMap>(); + for (const folder of this.folders.keys()) { + this.mergeFolder(folder); + } + } + + protected mergeFolder(folder: URI) { + if (this.workspaceUri && this.workspaceUri.fsPath === folder.fsPath) { + this._workspace = new ConfigurationModel().merge(this._global).merge(this.folders.get(this.workspaceUri)); + this._foldersConsolidated.set(folder, this._workspace); + } else { + this._foldersConsolidated.set(folder, new ConfigurationModel().merge(this._workspace).merge(this.folders.get(folder))); + } + } + + getValue(options: IConfigurationOptions = {}): C { + const configModel = this.getConfigurationModel(options); + return options.section ? configModel.getContentsFor(options.section) : configModel.contents; + } + + lookup(key: string, overrideIdentifier?: string): IConfigurationValue { + // make sure to clone the configuration so that the receiver does not tamper with the values + return { + default: objects.clone(getConfigurationValue(overrideIdentifier ? this._defaults.override(overrideIdentifier).contents : this._defaults.contents, key)), + user: objects.clone(getConfigurationValue(overrideIdentifier ? this._user.override(overrideIdentifier).contents : this._user.contents, key)), + workspace: objects.clone(this.workspaceUri ? getConfigurationValue(overrideIdentifier ? this.folders.get(this.workspaceUri).override(overrideIdentifier).contents : this.folders.get(this.workspaceUri).contents, key) : void 0), + value: objects.clone(getConfigurationValue(overrideIdentifier ? this._workspace.override(overrideIdentifier).contents : this._workspace.contents, key)) + }; + } + + keys(): IConfigurationKeys { + return { + default: this._defaults.keys, + user: this._user.keys, + workspace: this.workspaceUri ? this.folders.get(this.workspaceUri).keys : [] + }; + } + + values(): IConfigurationValues { + const result = Object.create(null); + const keyset = this.keys(); + const keys = [...keyset.workspace, ...keyset.user, ...keyset.default].sort(); + + let lastKey: string; + for (const key of keys) { + if (key !== lastKey) { + lastKey = key; + result[key] = this.lookup(key); + } + } + + return result; + } + + values2(): Map> { + const result: Map> = new Map>(); + const keyset = this.keys(); + const keys = [...keyset.workspace, ...keyset.user, ...keyset.default].sort(); + + let lastKey: string; + for (const key of keys) { + if (key !== lastKey) { + lastKey = key; + result.set(key, this.lookup(key)); + } + } + + return result; + } + + private getConfigurationModel(options: IConfigurationOptions): ConfigurationModel { + let configurationModel = (options.resource ? this._foldersConsolidated.get(options.resource) : this._workspace) || new ConfigurationModel(); + return options.overrideIdentifier ? configurationModel.override(options.overrideIdentifier) : configurationModel; + } } \ No newline at end of file diff --git a/src/vs/platform/configuration/common/model.ts b/src/vs/platform/configuration/common/model.ts index bbc843ffa3a..4b60767383d 100644 --- a/src/vs/platform/configuration/common/model.ts +++ b/src/vs/platform/configuration/common/model.ts @@ -7,7 +7,7 @@ import { Registry } from 'vs/platform/platform'; import * as json from 'vs/base/common/json'; import { IConfigurationRegistry, Extensions, OVERRIDE_PROPERTY_PATTERN } from 'vs/platform/configuration/common/configurationRegistry'; -import { Configuration, IOverrides } from 'vs/platform/configuration/common/configuration'; +import { ConfigurationModel, IOverrides } from 'vs/platform/configuration/common/configuration'; export function getDefaultValues(): any { const valueTreeRoot: any = Object.create(null); @@ -65,7 +65,7 @@ export function getConfigurationKeys(): string[] { return Object.keys(properties); } -export class DefaultConfiguration extends Configuration { +export class DefaultConfigurationModel extends ConfigurationModel { constructor() { super(getDefaultValues()); @@ -89,7 +89,7 @@ interface Overrides extends IOverrides { raw: any; } -export class CustomConfiguration extends Configuration { +export class CustomConfigurationModel extends ConfigurationModel { protected _parseErrors: any[] = []; diff --git a/src/vs/platform/configuration/node/configurationService.ts b/src/vs/platform/configuration/node/configurationService.ts index 3f7a1e9c22c..76ad820e196 100644 --- a/src/vs/platform/configuration/node/configurationService.ts +++ b/src/vs/platform/configuration/node/configurationService.ts @@ -5,28 +5,21 @@ 'use strict'; import { TPromise } from 'vs/base/common/winjs.base'; -import * as objects from 'vs/base/common/objects'; import { ConfigWatcher } from 'vs/base/node/config'; import { Registry } from 'vs/platform/platform'; import { IConfigurationRegistry, Extensions } from 'vs/platform/configuration/common/configurationRegistry'; import { IDisposable, toDisposable, Disposable } from 'vs/base/common/lifecycle'; -import { ConfigurationSource, IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, getConfigurationValue, IConfigurationKeys, Configuration, IConfigurationOptions } from 'vs/platform/configuration/common/configuration'; -import { CustomConfiguration, DefaultConfiguration } from 'vs/platform/configuration/common/model'; +import { ConfigurationSource, IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, IConfigurationKeys, ConfigurationModel, IConfigurationOptions, Configuration } from 'vs/platform/configuration/common/configuration'; +import { CustomConfigurationModel, DefaultConfigurationModel } from 'vs/platform/configuration/common/model'; import Event, { Emitter } from 'vs/base/common/event'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; -export interface ICache { - defaults: Configuration; - user: Configuration; - consolidated: Configuration; -} - export class ConfigurationService extends Disposable implements IConfigurationService, IDisposable { _serviceBrand: any; - private cache: ICache; - private userConfigModelWatcher: ConfigWatcher>; + private _configuration: Configuration; + private userConfigModelWatcher: ConfigWatcher>; private _onDidUpdateConfiguration: Emitter = this._register(new Emitter()); public readonly onDidUpdateConfiguration: Event = this._onDidUpdateConfiguration.event; @@ -37,8 +30,8 @@ export class ConfigurationService extends Disposable implements IConfiguratio super(); this.userConfigModelWatcher = new ConfigWatcher(environmentService.appSettingsPath, { - changeBufferDelay: 300, defaultConfig: new CustomConfiguration(null, environmentService.appSettingsPath), parse: (content: string, parseErrors: any[]) => { - const userConfigModel = new CustomConfiguration(content, environmentService.appSettingsPath); + changeBufferDelay: 300, defaultConfig: new CustomConfigurationModel(null, environmentService.appSettingsPath), parse: (content: string, parseErrors: any[]) => { + const userConfigModel = new CustomConfigurationModel(content, environmentService.appSettingsPath); parseErrors = [...userConfigModel.errors]; return userConfigModel; } @@ -51,9 +44,9 @@ export class ConfigurationService extends Disposable implements IConfiguratio } private onConfigurationChange(source: ConfigurationSource): void { - this.cache = void 0; // reset our caches + this.reset(); // reset our caches - const cache = this.getCache(); + const cache = this.getConfiguration2(); this._onDidUpdateConfiguration.fire({ config: this.getConfiguration(), @@ -65,8 +58,7 @@ export class ConfigurationService extends Disposable implements IConfiguratio public reloadConfiguration(section?: string): TPromise { return new TPromise(c => { this.userConfigModelWatcher.reload(() => { - this.cache = void 0; // reset our caches - + this.reset(); // reset our caches c(this.getConfiguration(section)); }); }); @@ -75,34 +67,23 @@ export class ConfigurationService extends Disposable implements IConfiguratio public getConfiguration(section?: string): C public getConfiguration(options?: IConfigurationOptions): C public getConfiguration(arg?: any): C { - const options = this.toOptions(arg); - const cache = this.getCache(); - const configModel = options.overrideIdentifier ? cache.consolidated.override(options.overrideIdentifier) : cache.consolidated; - return options.section ? configModel.getContentsFor(options.section) : configModel.contents; + return this.getConfiguration2().getValue(this.toOptions(arg)); } public lookup(key: string, overrideIdentifier?: string): IConfigurationValue { - const cache = this.getCache(); - - // make sure to clone the configuration so that the receiver does not tamper with the values - return { - default: objects.clone(getConfigurationValue(overrideIdentifier ? cache.defaults.override(overrideIdentifier).contents : cache.defaults.contents, key)), - user: objects.clone(getConfigurationValue(overrideIdentifier ? cache.user.override(overrideIdentifier).contents : cache.user.contents, key)), - value: objects.clone(getConfigurationValue(overrideIdentifier ? cache.consolidated.override(overrideIdentifier).contents : cache.consolidated.contents, key)) - }; + return this.getConfiguration2().lookup(key, overrideIdentifier); } public keys(): IConfigurationKeys { - const cache = this.getCache(); + return this.getConfiguration2().keys(); + } - return { - default: cache.defaults.keys, - user: cache.user.keys - }; + public getConfiguration2(): Configuration { + return this._configuration || (this._configuration = this.consolidateConfigurations()); } - public getCache(): ICache { - return this.cache || (this.cache = this.consolidateConfigurations()); + private reset(): void { + this._configuration = this.consolidateConfigurations(); } private toOptions(arg: any): IConfigurationOptions { @@ -115,10 +96,9 @@ export class ConfigurationService extends Disposable implements IConfiguratio return {}; } - private consolidateConfigurations(): ICache { - const defaults = new DefaultConfiguration(); + private consolidateConfigurations(): Configuration { + const defaults = new DefaultConfigurationModel(); const user = this.userConfigModelWatcher.getConfig(); - const consolidated = defaults.merge(user); - return { defaults, user, consolidated }; + return new Configuration(defaults, user); } } \ No newline at end of file diff --git a/src/vs/platform/configuration/test/common/configuration.test.ts b/src/vs/platform/configuration/test/common/configuration.test.ts index 69552e758fb..e2163cfd88f 100644 --- a/src/vs/platform/configuration/test/common/configuration.test.ts +++ b/src/vs/platform/configuration/test/common/configuration.test.ts @@ -5,7 +5,7 @@ 'use strict'; import * as assert from 'assert'; -import { Configuration, merge } from 'vs/platform/configuration/common/configuration'; +import { ConfigurationModel, merge } from 'vs/platform/configuration/common/configuration'; import { Extensions, IConfigurationRegistry } from 'vs/platform/configuration/common/configurationRegistry'; import { Registry } from 'vs/platform/platform'; @@ -44,35 +44,35 @@ suite('Configuration', () => { }); test('simple merge using configuration', () => { - let base = new Configuration({ 'a': 1, 'b': 2 }); - let add = new Configuration({ 'a': 3, 'c': 4 }); + let base = new ConfigurationModel({ 'a': 1, 'b': 2 }); + let add = new ConfigurationModel({ 'a': 3, 'c': 4 }); let result = base.merge(add); assert.deepEqual(result.contents, { 'a': 3, 'b': 2, 'c': 4 }); }); test('Recursive merge using config models', () => { - let base = new Configuration({ 'a': { 'b': 1 } }); - let add = new Configuration({ 'a': { 'b': 2 } }); + let base = new ConfigurationModel({ 'a': { 'b': 1 } }); + let add = new ConfigurationModel({ 'a': { 'b': 2 } }); let result = base.merge(add); assert.deepEqual(result.contents, { 'a': { 'b': 2 } }); }); test('Test contents while getting an existing property', () => { - let testObject = new Configuration({ 'a': 1 }); + let testObject = new ConfigurationModel({ 'a': 1 }); assert.deepEqual(testObject.getContentsFor('a'), 1); - testObject = new Configuration({ 'a': { 'b': 1 } }); + testObject = new ConfigurationModel({ 'a': { 'b': 1 } }); assert.deepEqual(testObject.getContentsFor('a'), { 'b': 1 }); }); test('Test contents are undefined for non existing properties', () => { - const testObject = new Configuration({ awesome: true }); + const testObject = new ConfigurationModel({ awesome: true }); assert.deepEqual(testObject.getContentsFor('unknownproperty'), undefined); }); test('Test override gives all content merged with overrides', () => { - const testObject = new Configuration({ 'a': 1, 'c': 1 }, [{ identifiers: ['b'], contents: { 'a': 2 } }]); + const testObject = new ConfigurationModel({ 'a': 1, 'c': 1 }, [{ identifiers: ['b'], contents: { 'a': 2 } }]); assert.deepEqual(testObject.override('b').contents, { 'a': 2, 'c': 1 }); }); diff --git a/src/vs/platform/configuration/test/common/model.test.ts b/src/vs/platform/configuration/test/common/model.test.ts index e2f3bb6e997..86ac706b3f0 100644 --- a/src/vs/platform/configuration/test/common/model.test.ts +++ b/src/vs/platform/configuration/test/common/model.test.ts @@ -5,7 +5,7 @@ 'use strict'; import * as assert from 'assert'; -import { CustomConfiguration, DefaultConfiguration } from 'vs/platform/configuration/common/model'; +import { CustomConfigurationModel, DefaultConfigurationModel } from 'vs/platform/configuration/common/model'; import { Extensions, IConfigurationRegistry } from 'vs/platform/configuration/common/configurationRegistry'; import { Registry } from 'vs/platform/platform'; @@ -29,46 +29,46 @@ suite('Configuration', () => { }); test('simple merge using models', () => { - let base = new CustomConfiguration(JSON.stringify({ 'a': 1, 'b': 2 })); - let add = new CustomConfiguration(JSON.stringify({ 'a': 3, 'c': 4 })); + let base = new CustomConfigurationModel(JSON.stringify({ 'a': 1, 'b': 2 })); + let add = new CustomConfigurationModel(JSON.stringify({ 'a': 3, 'c': 4 })); let result = base.merge(add); assert.deepEqual(result.contents, { 'a': 3, 'b': 2, 'c': 4 }); }); test('simple merge with an undefined contents', () => { - let base = new CustomConfiguration(JSON.stringify({ 'a': 1, 'b': 2 })); - let add = new CustomConfiguration(null); + let base = new CustomConfigurationModel(JSON.stringify({ 'a': 1, 'b': 2 })); + let add = new CustomConfigurationModel(null); let result = base.merge(add); assert.deepEqual(result.contents, { 'a': 1, 'b': 2 }); - base = new CustomConfiguration(null); - add = new CustomConfiguration(JSON.stringify({ 'a': 1, 'b': 2 })); + base = new CustomConfigurationModel(null); + add = new CustomConfigurationModel(JSON.stringify({ 'a': 1, 'b': 2 })); result = base.merge(add); assert.deepEqual(result.contents, { 'a': 1, 'b': 2 }); - base = new CustomConfiguration(null); - add = new CustomConfiguration(null); + base = new CustomConfigurationModel(null); + add = new CustomConfigurationModel(null); result = base.merge(add); assert.deepEqual(result.contents, {}); }); test('Recursive merge using config models', () => { - let base = new CustomConfiguration(JSON.stringify({ 'a': { 'b': 1 } })); - let add = new CustomConfiguration(JSON.stringify({ 'a': { 'b': 2 } })); + let base = new CustomConfigurationModel(JSON.stringify({ 'a': { 'b': 1 } })); + let add = new CustomConfigurationModel(JSON.stringify({ 'a': { 'b': 2 } })); let result = base.merge(add); assert.deepEqual(result.contents, { 'a': { 'b': 2 } }); }); test('Test contents while getting an existing property', () => { - let testObject = new CustomConfiguration(JSON.stringify({ 'a': 1 })); + let testObject = new CustomConfigurationModel(JSON.stringify({ 'a': 1 })); assert.deepEqual(testObject.getContentsFor('a'), 1); - testObject = new CustomConfiguration(JSON.stringify({ 'a': { 'b': 1 } })); + testObject = new CustomConfigurationModel(JSON.stringify({ 'a': { 'b': 1 } })); assert.deepEqual(testObject.getContentsFor('a'), { 'b': 1 }); }); test('Test contents are undefined for non existing properties', () => { - const testObject = new CustomConfiguration(JSON.stringify({ + const testObject = new CustomConfigurationModel(JSON.stringify({ awesome: true })); @@ -76,25 +76,25 @@ suite('Configuration', () => { }); test('Test contents are undefined for undefined config', () => { - const testObject = new CustomConfiguration(null); + const testObject = new CustomConfigurationModel(null); assert.deepEqual(testObject.getContentsFor('unknownproperty'), undefined); }); test('Test configWithOverrides gives all content merged with overrides', () => { - const testObject = new CustomConfiguration(JSON.stringify({ 'a': 1, 'c': 1, '[b]': { 'a': 2 } })); + const testObject = new CustomConfigurationModel(JSON.stringify({ 'a': 1, 'c': 1, '[b]': { 'a': 2 } })); assert.deepEqual(testObject.override('b').contents, { 'a': 2, 'c': 1, '[b]': { 'a': 2 } }); }); test('Test configWithOverrides gives empty contents', () => { - const testObject = new CustomConfiguration(null); + const testObject = new CustomConfigurationModel(null); assert.deepEqual(testObject.override('b').contents, {}); }); test('Test update with empty data', () => { - const testObject = new CustomConfiguration(); + const testObject = new CustomConfigurationModel(); testObject.update(''); assert.deepEqual(testObject.contents, {}); @@ -125,7 +125,7 @@ suite('Configuration', () => { } } }); - assert.equal(true, new DefaultConfiguration().getContentsFor('a')); + assert.equal(true, new DefaultConfigurationModel().getContentsFor('a')); }); test('Test registering the language property', () => { @@ -142,7 +142,7 @@ suite('Configuration', () => { } } }); - assert.equal(undefined, new DefaultConfiguration().getContentsFor('[a]')); + assert.equal(undefined, new DefaultConfigurationModel().getContentsFor('[a]')); }); }); \ No newline at end of file diff --git a/src/vs/platform/configuration/test/common/testConfigurationService.ts b/src/vs/platform/configuration/test/common/testConfigurationService.ts index 9af8629a5bb..06be8aa2346 100644 --- a/src/vs/platform/configuration/test/common/testConfigurationService.ts +++ b/src/vs/platform/configuration/test/common/testConfigurationService.ts @@ -36,14 +36,16 @@ export class TestConfigurationService extends EventEmitter implements IConfigura return { value: getConfigurationValue(this.getConfiguration(), key), default: getConfigurationValue(this.getConfiguration(), key), - user: getConfigurationValue(this.getConfiguration(), key) + user: getConfigurationValue(this.getConfiguration(), key), + workspace: null }; } public keys(): IConfigurationKeys { return { default: getConfigurationKeys(), - user: Object.keys(this.configuration) + user: Object.keys(this.configuration), + workspace: [] }; } } diff --git a/src/vs/platform/telemetry/test/electron-browser/telemetryService.test.ts b/src/vs/platform/telemetry/test/electron-browser/telemetryService.test.ts index 9a49dfd7b38..814428897c6 100644 --- a/src/vs/platform/telemetry/test/electron-browser/telemetryService.test.ts +++ b/src/vs/platform/telemetry/test/electron-browser/telemetryService.test.ts @@ -688,10 +688,11 @@ suite('TelemetryService', () => { return { value: getConfigurationValue(this.getConfiguration(), key), default: getConfigurationValue(this.getConfiguration(), key), - user: getConfigurationValue(this.getConfiguration(), key) + user: getConfigurationValue(this.getConfiguration(), key), + workspace: null, }; }, - keys() { return { default: [], user: [] }; }, + keys() { return { default: [], user: [], workspace: [] }; }, onDidUpdateConfiguration: emitter.event }); diff --git a/src/vs/platform/workspace/common/workspace.ts b/src/vs/platform/workspace/common/workspace.ts index 7abd76ad14c..ab469fc3e8a 100644 --- a/src/vs/platform/workspace/common/workspace.ts +++ b/src/vs/platform/workspace/common/workspace.ts @@ -38,6 +38,12 @@ export interface IWorkspaceContextService { */ onDidChangeWorkspaceRoots: Event; + /** + * Returns the root for the given resource from the workspace. + * Can be null if there is no workspace or the resource is not inside the workspace. + */ + getRoot(resource: URI): URI; + /** * Returns iff the provided resource is inside the workspace or not. */ diff --git a/src/vs/workbench/browser/parts/editor/textEditor.ts b/src/vs/workbench/browser/parts/editor/textEditor.ts index d9cb5e09200..129428cd750 100644 --- a/src/vs/workbench/browser/parts/editor/textEditor.ts +++ b/src/vs/workbench/browser/parts/editor/textEditor.ts @@ -7,6 +7,7 @@ import nls = require('vs/nls'); import { TPromise } from 'vs/base/common/winjs.base'; +import URI from 'vs/base/common/uri'; import { Dimension, Builder } from 'vs/base/browser/builder'; import objects = require('vs/base/common/objects'); import types = require('vs/base/common/types'); @@ -116,9 +117,9 @@ export abstract class BaseTextEditor extends BaseEditor { protected getConfigurationOverrides(): IEditorOptions { const overrides = {}; - const language = this.getLanguage(); - if (language) { - objects.assign(overrides, this.configurationService.getConfiguration({ overrideIdentifier: language, section: 'editor' })); + const resource = this.getResource(); + if (resource) { + objects.assign(overrides, this.configurationService.getConfiguration({ /*resource: this.getResource(), */overrideIdentifier: this.getLanguage(), section: 'editor' })); } objects.assign(overrides, { @@ -326,6 +327,22 @@ export abstract class BaseTextEditor extends BaseEditor { return null; } + protected getResource(): URI { + const codeEditor = getCodeEditor(this); + if (codeEditor) { + const model = codeEditor.getModel(); + if (model) { + return model.uri; + } + } + + if (this.input) { + return toResource(this.input); + } + + return null; + } + protected abstract getAriaLabel(): string; public dispose(): void { diff --git a/src/vs/workbench/parts/terminal/test/electron-browser/terminalConfigHelper.test.ts b/src/vs/workbench/parts/terminal/test/electron-browser/terminalConfigHelper.test.ts index 2e0b9c5831d..80da83ff489 100644 --- a/src/vs/workbench/parts/terminal/test/electron-browser/terminalConfigHelper.test.ts +++ b/src/vs/workbench/parts/terminal/test/electron-browser/terminalConfigHelper.test.ts @@ -15,11 +15,12 @@ import { EDITOR_FONT_DEFAULTS } from 'vs/editor/common/config/editorOptions'; class MockConfigurationService implements IConfigurationService { public _serviceBrand: any; + public serviceId = IConfigurationService; public constructor(private configuration: any = {}) { } public reloadConfiguration(section?: string): TPromise { return TPromise.as(this.getConfiguration()); } - public lookup(key: string) { return { value: getConfigurationValue(this.getConfiguration(), key), default: getConfigurationValue(this.getConfiguration(), key), user: getConfigurationValue(this.getConfiguration(), key) }; } + public lookup(key: string) { return { value: getConfigurationValue(this.getConfiguration(), key), default: getConfigurationValue(this.getConfiguration(), key), user: getConfigurationValue(this.getConfiguration(), key), workspace: void 0 }; } + public keys() { return { default: [], user: [], workspace: [] }; } public getConfiguration(): any { return this.configuration; } - public keys() { return { default: [], user: [] }; } public onDidUpdateConfiguration() { return { dispose() { } }; } } diff --git a/src/vs/workbench/services/configuration/common/configurationModels.ts b/src/vs/workbench/services/configuration/common/configurationModels.ts index d6ad817c30e..cd3ee0e3388 100644 --- a/src/vs/workbench/services/configuration/common/configurationModels.ts +++ b/src/vs/workbench/services/configuration/common/configurationModels.ts @@ -4,12 +4,12 @@ *--------------------------------------------------------------------------------------------*/ 'use strict'; -import { CustomConfiguration } from 'vs/platform/configuration/common/model'; +import { CustomConfigurationModel } from 'vs/platform/configuration/common/model'; import { WORKSPACE_STANDALONE_CONFIGURATIONS } from 'vs/workbench/services/configuration/common/configuration'; import { Registry } from 'vs/platform/platform'; import { IConfigurationRegistry, IConfigurationPropertySchema, Extensions } from 'vs/platform/configuration/common/configurationRegistry'; -export class ScopedConfigModel extends CustomConfiguration { +export class ScopedConfigurationModel extends CustomConfigurationModel { constructor(content: string, name: string, public readonly scope: string) { super(null, name); @@ -25,7 +25,7 @@ export class ScopedConfigModel extends CustomConfiguration { } -export class WorkspaceSettingsConfigModel extends CustomConfiguration { +export class FolderSettingsModel extends CustomConfigurationModel { private _raw: T; private _unsupportedKeys: string[]; @@ -62,9 +62,9 @@ export class WorkspaceSettingsConfigModel extends CustomConfiguration { } } -export class WorkspaceConfigModel extends CustomConfiguration { +export class FolderConfigurationModel extends CustomConfigurationModel { - constructor(public readonly workspaceSettingsConfig: WorkspaceSettingsConfigModel, private scopedConfigs: ScopedConfigModel[]) { + constructor(public readonly workspaceSettingsConfig: FolderSettingsModel, private scopedConfigs: ScopedConfigurationModel[]) { super(); this.consolidate(); } diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index eae962acc3a..fb935685395 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -8,6 +8,7 @@ import URI from 'vs/base/common/uri'; import * as paths from 'vs/base/common/paths'; import { TPromise } from 'vs/base/common/winjs.base'; import Event, { Emitter } from 'vs/base/common/event'; +import { StrictResourceMap, TrieMap } from 'vs/base/common/map'; import { distinct, equals } from "vs/base/common/arrays"; import * as objects from 'vs/base/common/objects'; import * as errors from 'vs/base/common/errors'; @@ -18,11 +19,13 @@ import { RunOnceScheduler } from 'vs/base/common/async'; import { readFile } from 'vs/base/node/pfs'; import * as extfs from 'vs/base/node/extfs'; import { IWorkspaceContextService, IWorkspace2, Workspace as SingleRootWorkspace, IWorkspace } from "vs/platform/workspace/common/workspace"; +import { FileChangeType, FileChangesEvent, isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; +import { isLinux } from 'vs/base/common/platform'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; -import { FileChangeType, FileChangesEvent, isEqual } from 'vs/platform/files/common/files'; -import { ScopedConfigModel, WorkspaceConfigModel, WorkspaceSettingsConfigModel } from 'vs/workbench/services/configuration/common/configurationModels'; -import { IConfigurationServiceEvent, ConfigurationSource, getConfigurationValue, IConfigurationOptions, Configuration } from 'vs/platform/configuration/common/configuration'; -import { IWorkspaceConfigurationValues, IWorkspaceConfigurationService, IWorkspaceConfigurationValue, WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME, WORKSPACE_STANDALONE_CONFIGURATIONS, WORKSPACE_CONFIG_DEFAULT_PATH } from 'vs/workbench/services/configuration/common/configuration'; +import { CustomConfigurationModel } from 'vs/platform/configuration/common/model'; +import { ScopedConfigurationModel, FolderConfigurationModel, FolderSettingsModel } from 'vs/workbench/services/configuration/common/configurationModels'; +import { IConfigurationServiceEvent, ConfigurationSource, IConfigurationKeys, IConfigurationValue, ConfigurationModel, IConfigurationOptions, Configuration as BaseConfiguration } from 'vs/platform/configuration/common/configuration'; +import { IWorkspaceConfigurationService, WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME, WORKSPACE_STANDALONE_CONFIGURATIONS, WORKSPACE_CONFIG_DEFAULT_PATH, IWorkspaceConfigurationValues } from 'vs/workbench/services/configuration/common/configuration'; import { ConfigurationService as GlobalConfigurationService } from 'vs/platform/configuration/node/configurationService'; import { createHash } from "crypto"; import { basename } from "path"; @@ -79,8 +82,6 @@ class Workspace implements IWorkspace2 { export class WorkspaceConfigurationService extends Disposable implements IWorkspaceContextService, IWorkspaceConfigurationService { - private static RELOAD_CONFIGURATION_DELAY = 50; - public _serviceBrand: any; private readonly _onDidChangeWorkspaceRoots: Emitter = this._register(new Emitter()); @@ -91,35 +92,27 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp private baseConfigurationService: GlobalConfigurationService; - private cachedConfig: Configuration; - private cachedWorkspaceConfig: WorkspaceConfigModel; - - private bulkFetchFromWorkspacePromise: TPromise; - private workspaceFilePathToConfiguration: { [relativeWorkspacePath: string]: TPromise> }; - private reloadConfigurationScheduler: RunOnceScheduler; + private cachedFolderConfigs: StrictResourceMap>; private readonly workspace: Workspace; + private rootsTrieMap: TrieMap = new TrieMap(TrieMap.PathSplitter); + private _configuration: Configuration; constructor(private environmentService: IEnvironmentService, private singleRootWorkspace?: SingleRootWorkspace, private workspaceSettingsRootFolder: string = WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME) { super(); this.workspace = singleRootWorkspace ? new Workspace(createHash('md5').update(singleRootWorkspace.resource.toString()).digest('hex'), [singleRootWorkspace.resource]) : null; // TODO@Ben for now use the first root folder as id, but revisit this later - - this.workspaceFilePathToConfiguration = Object.create(null); - this.cachedConfig = new Configuration(); - this.cachedWorkspaceConfig = new WorkspaceConfigModel(new WorkspaceSettingsConfigModel(null), []); + this.rootsTrieMap = new TrieMap(TrieMap.PathSplitter); + if (this.workspace) { + this.rootsTrieMap.insert(this.workspace.roots[0].fsPath, this.workspace.roots[0]); + } + this._register(this.onDidUpdateConfiguration(e => this.resolveAdditionalFolders(true))); this.baseConfigurationService = this._register(new GlobalConfigurationService(environmentService)); - this.reloadConfigurationScheduler = this._register(new RunOnceScheduler(() => this.doLoadConfiguration() - .then(config => this._onDidUpdateConfiguration.fire({ - config: config.consolidated, - source: ConfigurationSource.Workspace, - sourceConfig: config.workspace - })) - .done(null, errors.onUnexpectedError), WorkspaceConfigurationService.RELOAD_CONFIGURATION_DELAY)); - this._register(this.baseConfigurationService.onDidUpdateConfiguration(e => this.onBaseConfigurationChanged(e))); - this._register(this.onDidUpdateConfiguration(e => this.resolveAdditionalFolders(true))); + this._register(this.onDidChangeWorkspaceRoots(e => this.onRootsChanged())); + + this.initCaches(); } private resolveAdditionalFolders(notify?: boolean): void { @@ -150,8 +143,15 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp this.workspace.roots = configuredFolders; - if (notify && changed) { - this._onDidChangeWorkspaceRoots.fire(configuredFolders); + if (changed) { + this.rootsTrieMap = new TrieMap(TrieMap.PathSplitter); + for (const folder of this.workspace.roots) { + this.rootsTrieMap.insert(folder.fsPath, folder); + } + + if (notify) { + this._onDidChangeWorkspaceRoots.fire(configuredFolders); + } } } @@ -167,6 +167,14 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp return !!this.workspace; } + public getRoot(resource: URI): URI { + return this.rootsTrieMap.findSubstr(resource.fsPath); + } + + private get workspaceUri(): URI { + return this.workspace ? this.workspace.roots[0] : null; + } + public isInsideWorkspace(resource: URI): boolean { return this.workspace ? this.singleRootWorkspace.isInsideWorkspace(resource) : false; } @@ -179,94 +187,121 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp return this.workspace ? this.singleRootWorkspace.toResource(workspaceRelativePath) : null; } - private onBaseConfigurationChanged(event: IConfigurationServiceEvent): void { - if (event.source === ConfigurationSource.Default) { - this.cachedWorkspaceConfig.update(); - } - - // update cached config when base config changes - const configModel = >this.baseConfigurationService.getCache().consolidated // global/default values (do NOT modify) - .merge(this.cachedWorkspaceConfig); // workspace configured values - - // emit this as update to listeners if changed - if (!objects.equals(this.cachedConfig.contents, configModel.contents)) { - this.cachedConfig = configModel; - this._onDidUpdateConfiguration.fire({ - config: this.cachedConfig.contents, - source: event.source, - sourceConfig: event.sourceConfig - }); - } - } - - public initialize(): TPromise { - return this.doLoadConfiguration().then(() => null); + public get configuration(): BaseConfiguration { + return this._configuration; } public getConfiguration(section?: string): C public getConfiguration(options?: IConfigurationOptions): C public getConfiguration(arg?: any): C { - const options = this.toOptions(arg); - const configModel = options.overrideIdentifier ? this.cachedConfig.override(options.overrideIdentifier) : this.cachedConfig; - return options.section ? configModel.getContentsFor(options.section) : configModel.contents; + return this._configuration.getValue(this.toOptions(arg)); } - public lookup(key: string, overrideIdentifier?: string): IWorkspaceConfigurationValue { - const configurationValue = this.baseConfigurationService.lookup(key, overrideIdentifier); - return { - default: configurationValue.default, - user: configurationValue.user, - workspace: objects.clone(getConfigurationValue(overrideIdentifier ? this.cachedWorkspaceConfig.override(overrideIdentifier).contents : this.cachedWorkspaceConfig.contents, key)), - value: objects.clone(getConfigurationValue(overrideIdentifier ? this.cachedConfig.override(overrideIdentifier).contents : this.cachedConfig.contents, key)) - }; + public lookup(key: string, overrideIdentifier?: string): IConfigurationValue { + return this._configuration.lookup(key, overrideIdentifier); } - public keys() { - const keys = this.baseConfigurationService.keys(); + public keys(): IConfigurationKeys { + return this._configuration.keys(); + } - return { - default: keys.default, - user: keys.user, - workspace: this.cachedWorkspaceConfig.keys - }; + public values(): IWorkspaceConfigurationValues { + return this._configuration.values(); } - public values(): IWorkspaceConfigurationValues { - const result: IWorkspaceConfigurationValues = Object.create(null); - const keyset = this.keys(); - const keys = [...keyset.workspace, ...keyset.user, ...keyset.default].sort(); + public getUnsupportedWorkspaceKeys(): string[] { + return this.workspace ? this._configuration.getFolderConfigurationModel(this.workspace.roots[0]).workspaceSettingsConfig.unsupportedKeys : []; + } - let lastKey: string; - for (const key of keys) { - if (key !== lastKey) { - lastKey = key; - result[key] = this.lookup(key); - } + public reloadConfiguration(section?: string): TPromise { + const current = this._configuration; + + return this.baseConfigurationService.reloadConfiguration() + .then(() => this.initialize()) // Reinitialize to ensure we are hitting the disk + .then(() => !this._configuration.equals(current)) // Check if the configuration is changed + .then(changed => changed ? this.trigger() : void 0) // Trigger event if changed + .then(() => this.getConfiguration(section)); + } + + public handleWorkspaceFileEvents(event: FileChangesEvent): void { + if (this.workspace) { + TPromise.join(this.workspace.roots.map(folder => this.cachedFolderConfigs.get(folder).handleWorkspaceFileEvents(event))) // handle file event for each folder + .then(folderConfigurations => + folderConfigurations.map((configuration, index) => ({ configuration, folder: this.workspace.roots[index] })) + .filter(folderConfiguration => !!folderConfiguration.configuration) // Filter folders which are not impacted by events + .map(folderConfiguration => this._configuration.updateFolderConfiguration(folderConfiguration.folder, folderConfiguration.configuration)) // Update the configuration of impacted folders + .reduce((result, value) => result || value, false)) // Check if the effective configuration of folder is changed + .then(changed => changed ? this.trigger() : void 0); // Trigger event if changed } + } - return result; + public initialize(): TPromise { + this.initCaches(); + return this.doInitialize(this.workspace ? this.workspace.roots : []); } - public reloadConfiguration(section?: string): TPromise { + private onRootsChanged(): void { + if (!this.workspace) { + return; + } - // Reset caches to ensure we are hitting the disk - this.bulkFetchFromWorkspacePromise = null; - this.workspaceFilePathToConfiguration = Object.create(null); + let configurationChanged = false; - // Load configuration - return this.baseConfigurationService.reloadConfiguration().then(() => { - const current = this.cachedConfig; - return this.doLoadConfiguration().then(configuration => { - // emit this as update to listeners if changed - if (!objects.equals(current, this.cachedConfig)) { - this._onDidUpdateConfiguration.fire({ - config: configuration.consolidated, - source: ConfigurationSource.Workspace, - sourceConfig: configuration.workspace - }); + // Remove the configurations of deleted folders + for (const key of this.cachedFolderConfigs.keys()) { + if (!this.workspace.roots.filter(folder => folder.toString() === key.toString())[0]) { + this.cachedFolderConfigs.delete(key); + if (this._configuration.deleteFolderConfiguration(key)) { + configurationChanged = true; } - return section ? configuration.consolidated[section] : configuration.consolidated; - }); + } + } + + // Initialize the newly added folders + const toInitialize = this.workspace.roots.filter(folder => !this.cachedFolderConfigs.has(folder)); + if (toInitialize.length) { + this.initCachesForFolders(toInitialize); + this.doInitialize(toInitialize) + .then(changed => configurationChanged || changed) + .then(changed => changed ? this.trigger() : void 0); + } + } + + private initCaches(): void { + this.cachedFolderConfigs = new StrictResourceMap>(); + this._configuration = new Configuration(this.baseConfigurationService.getConfiguration2(), new StrictResourceMap>(), this.workspaceUri); + this.initCachesForFolders(this.workspace ? this.workspace.roots : []); + } + + private initCachesForFolders(folders: URI[]): void { + for (const folder of folders) { + this.cachedFolderConfigs.set(folder, new FolderConfiguration(folder, this.workspaceSettingsRootFolder, this.workspace)); + } + } + + private doInitialize(folders: URI[]): TPromise { + return TPromise.join(folders.map(folder => this.cachedFolderConfigs.get(folder).loadConfiguration() + .then(configuration => this._configuration.updateFolderConfiguration(folder, configuration)))) + .then(changed => changed.reduce((result, value) => result || value, false)); + } + + private onBaseConfigurationChanged(event: IConfigurationServiceEvent): void { + if (event.source === ConfigurationSource.Default) { + if (this.workspace) { + this.workspace.roots.forEach(folder => this._configuration.getFolderConfigurationModel(folder).update()); + } + } + + if (this._configuration.updateBaseConfiguration(this.baseConfigurationService.getConfiguration2())) { + this.trigger(event); + } + } + + private trigger(baseEvent?: IConfigurationServiceEvent): void { + this._onDidUpdateConfiguration.fire({ + config: this.getConfiguration(), + source: baseEvent ? baseEvent.source : ConfigurationSource.Workspace, + sourceConfig: baseEvent ? baseEvent.sourceConfig : this._configuration.getFolderConfigurationModel(this.workspace.roots[0]).contents }); } @@ -279,38 +314,43 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } return {}; } +} - private doLoadConfiguration(): TPromise> { +class FolderConfiguration extends Disposable { - // Load workspace locals - return this.loadWorkspaceConfigFiles().then(workspaceConfigFiles => { + private static RELOAD_CONFIGURATION_DELAY = 50; - // Consolidate (support *.json files in the workspace settings folder) - const workspaceSettingsConfig = >workspaceConfigFiles[WORKSPACE_CONFIG_DEFAULT_PATH] || new WorkspaceSettingsConfigModel(null); - const otherConfigModels = Object.keys(workspaceConfigFiles).filter(key => key !== WORKSPACE_CONFIG_DEFAULT_PATH).map(key => >workspaceConfigFiles[key]); - this.cachedWorkspaceConfig = new WorkspaceConfigModel(workspaceSettingsConfig, otherConfigModels); - - // Override base (global < user) with workspace locals (global < user < workspace) - this.cachedConfig = >this.baseConfigurationService.getCache().consolidated // global/default values (do NOT modify) - .merge(this.cachedWorkspaceConfig); // workspace configured values - - return { - consolidated: this.cachedConfig.contents, - workspace: this.cachedWorkspaceConfig.contents - }; - }); - } + private bulkFetchFromWorkspacePromise: TPromise; + private workspaceFilePathToConfiguration: { [relativeWorkspacePath: string]: TPromise> }; + + private reloadConfigurationScheduler: RunOnceScheduler; + private reloadConfigurationEventEmitter: Emitter> = new Emitter>(); + + constructor(private folder: URI, private configFolderRelativePath: string, private workspace: Workspace) { + super(); - private loadWorkspaceConfigFiles(): TPromise<{ [relativeWorkspacePath: string]: Configuration }> { + this.workspaceFilePathToConfiguration = Object.create(null); + this.reloadConfigurationScheduler = this._register(new RunOnceScheduler(() => this.loadConfiguration().then(configuration => this.reloadConfigurationEventEmitter.fire(configuration), errors.onUnexpectedError), FolderConfiguration.RELOAD_CONFIGURATION_DELAY)); + } - // Return early if we don't have a workspace + loadConfiguration(): TPromise> { if (!this.workspace) { - return TPromise.as(Object.create(null)); + return TPromise.wrap(new FolderConfigurationModel(new FolderSettingsModel(null), [])); } + // Load workspace locals + return this.loadWorkspaceConfigFiles().then(workspaceConfigFiles => { + // Consolidate (support *.json files in the workspace settings folder) + const workspaceSettingsConfig = >workspaceConfigFiles[WORKSPACE_CONFIG_DEFAULT_PATH] || new FolderSettingsModel(null); + const otherConfigModels = Object.keys(workspaceConfigFiles).filter(key => key !== WORKSPACE_CONFIG_DEFAULT_PATH).map(key => >workspaceConfigFiles[key]); + return new FolderConfigurationModel(workspaceSettingsConfig, otherConfigModels); + }); + } + + private loadWorkspaceConfigFiles(): TPromise<{ [relativeWorkspacePath: string]: ConfigurationModel }> { // once: when invoked for the first time we fetch json files that contribute settings if (!this.bulkFetchFromWorkspacePromise) { - this.bulkFetchFromWorkspacePromise = resolveStat(this.toResource(this.workspaceSettingsRootFolder)).then(stat => { + this.bulkFetchFromWorkspacePromise = resolveStat(this.toResource(this.configFolderRelativePath)).then(stat => { if (!stat.isDirectory) { return TPromise.as([]); } @@ -334,9 +374,9 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp return this.bulkFetchFromWorkspacePromise.then(() => TPromise.join(this.workspaceFilePathToConfiguration)); } - public handleWorkspaceFileEvents(event: FileChangesEvent): void { + public handleWorkspaceFileEvents(event: FileChangesEvent): TPromise> { if (!this.workspace) { - return; // only enabled when we have a known workspace + return TPromise.wrap(null); } const events = event.changes; @@ -346,7 +386,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp for (let i = 0, len = events.length; i < len; i++) { const resource = events[i].resource; const isJson = paths.extname(resource.fsPath) === '.json'; - const isDeletedSettingsFolder = (events[i].type === FileChangeType.DELETED && isEqual(paths.basename(resource.fsPath), this.workspaceSettingsRootFolder)); + const isDeletedSettingsFolder = (events[i].type === FileChangeType.DELETED && isEqual(paths.basename(resource.fsPath), this.configFolderRelativePath)); if (!isJson && !isDeletedSettingsFolder) { continue; // only JSON files or the actual settings folder } @@ -357,7 +397,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } // Handle case where ".vscode" got deleted - if (workspacePath === this.workspaceSettingsRootFolder && events[i].type === FileChangeType.DELETED) { + if (workspacePath === this.configFolderRelativePath && events[i].type === FileChangeType.DELETED) { this.workspaceFilePathToConfiguration = Object.create(null); affectedByChanges = true; } @@ -380,34 +420,63 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } } - // trigger reload of the configuration if we are affected by changes - if (affectedByChanges && !this.reloadConfigurationScheduler.isScheduled()) { - this.reloadConfigurationScheduler.schedule(); + if (!affectedByChanges) { + return TPromise.as(null); } + + return new TPromise((c, e) => { + let disposable = this.reloadConfigurationEventEmitter.event(configuration => { + disposable.dispose(); + c(configuration); + }); + // trigger reload of the configuration if we are affected by changes + if (!this.reloadConfigurationScheduler.isScheduled()) { + this.reloadConfigurationScheduler.schedule(); + } + }); } - private createConfigModel(content: IContent): Configuration { + private createConfigModel(content: IContent): ConfigurationModel { const path = this.toWorkspaceRelativePath(content.resource); if (path === WORKSPACE_CONFIG_DEFAULT_PATH) { - return new WorkspaceSettingsConfigModel(content.value, content.resource.toString()); + return new FolderSettingsModel(content.value, content.resource.toString()); } else { const matches = /\/([^\.]*)*\.json/.exec(path); if (matches && matches[1]) { - return new ScopedConfigModel(content.value, content.resource.toString(), matches[1]); + return new ScopedConfigurationModel(content.value, content.resource.toString(), matches[1]); } } - return new Configuration(); + return new CustomConfigurationModel(null); } private isWorkspaceConfigurationFile(workspaceRelativePath: string): boolean { return [WORKSPACE_CONFIG_DEFAULT_PATH, WORKSPACE_STANDALONE_CONFIGURATIONS.launch, WORKSPACE_STANDALONE_CONFIGURATIONS.tasks].some(p => p === workspaceRelativePath); } - public getUnsupportedWorkspaceKeys(): string[] { - return this.cachedWorkspaceConfig.workspaceSettingsConfig.unsupportedKeys; + private toResource(workspaceRelativePath: string): URI { + if (typeof workspaceRelativePath === 'string') { + return URI.file(paths.join(this.folder.fsPath, workspaceRelativePath)); + } + + return null; + } + + private isInsideWorkspace(resource: URI): boolean { + if (resource) { + return isEqualOrParent(resource.fsPath, this.folder.fsPath, !isLinux /* ignorecase */); + } + + return false; } + private toWorkspaceRelativePath(resource: URI, toOSPath?: boolean): string { + if (this.isInsideWorkspace(resource)) { + return paths.normalize(paths.relative(this.folder.fsPath, resource.fsPath), toOSPath); + } + + return null; + } } // node.hs helper functions @@ -445,3 +514,63 @@ function resolveStat(resource: URI): TPromise { }); }); } + +class Configuration extends BaseConfiguration { + + constructor(private _baseConfiguration: BaseConfiguration, protected folders: StrictResourceMap>, workspaceUri: URI) { + super(_baseConfiguration.defaults, _baseConfiguration.user, folders, workspaceUri); + } + + updateBaseConfiguration(baseConfiguration: BaseConfiguration): boolean { + const current = new Configuration(this._baseConfiguration, this.folders, this.workspaceUri); + + this._defaults = baseConfiguration.defaults; + this._user = baseConfiguration.user; + this.merge(); + + return !this.equals(current); + } + + updateFolderConfiguration(resource: URI, configuration: FolderConfigurationModel): boolean { + this.folders.set(resource, configuration); + const current = this.getValue({ resource }); + this.mergeFolder(resource); + return !objects.equals(current, this.getValue({ resource })); + } + + deleteFolderConfiguration(folder: URI): boolean { + if (this.workspaceUri && this.workspaceUri.fsPath === folder.fsPath) { + // Do not remove workspace configuration + return false; + } + + this.folders.delete(folder); + return this._foldersConsolidated.delete(folder); + } + + getFolderConfigurationModel(folder: URI): FolderConfigurationModel { + return >this.folders.get(folder); + } + + equals(other: any): boolean { + if (!other || !(other instanceof Configuration)) { + return false; + } + + if (!objects.equals(this.getValue(), other.getValue())) { + return false; + } + + if (this._foldersConsolidated.size !== other._foldersConsolidated.size) { + return false; + } + + for (const resource of this._foldersConsolidated.keys()) { + if (!objects.equals(this.getValue({ resource }), other.getValue({ resource }))) { + return false; + } + } + + return true; + } +} \ No newline at end of file diff --git a/src/vs/workbench/services/configuration/test/common/configurationModels.test.ts b/src/vs/workbench/services/configuration/test/common/configurationModels.test.ts index 4e6ff132c7e..2609ca32cef 100644 --- a/src/vs/workbench/services/configuration/test/common/configurationModels.test.ts +++ b/src/vs/workbench/services/configuration/test/common/configurationModels.test.ts @@ -5,26 +5,26 @@ 'use strict'; import * as assert from 'assert'; -import { WorkspaceConfigModel, ScopedConfigModel, WorkspaceSettingsConfigModel } from 'vs/workbench/services/configuration/common/configurationModels'; +import { FolderConfigurationModel, ScopedConfigurationModel, FolderSettingsModel } from 'vs/workbench/services/configuration/common/configurationModels'; suite('ConfigurationService - Model', () => { test('Test scoped configs are undefined', () => { - const settingsConfig = new WorkspaceSettingsConfigModel(JSON.stringify({ + const settingsConfig = new FolderSettingsModel(JSON.stringify({ awesome: true })); - const testObject = new WorkspaceConfigModel(settingsConfig, []); + const testObject = new FolderConfigurationModel(settingsConfig, []); assert.equal(testObject.getContentsFor('task'), undefined); }); test('Test consolidate (settings and tasks)', () => { - const settingsConfig = new WorkspaceSettingsConfigModel(JSON.stringify({ + const settingsConfig = new FolderSettingsModel(JSON.stringify({ awesome: true })); - const tasksConfig = new ScopedConfigModel(JSON.stringify({ + const tasksConfig = new ScopedConfigurationModel(JSON.stringify({ awesome: false }), '', 'tasks'); @@ -35,15 +35,15 @@ suite('ConfigurationService - Model', () => { } }; - assert.deepEqual(new WorkspaceConfigModel(settingsConfig, [tasksConfig]).contents, expected); + assert.deepEqual(new FolderConfigurationModel(settingsConfig, [tasksConfig]).contents, expected); }); test('Test consolidate (settings and launch)', () => { - const settingsConfig = new WorkspaceSettingsConfigModel(JSON.stringify({ + const settingsConfig = new FolderSettingsModel(JSON.stringify({ awesome: true })); - const launchConfig = new ScopedConfigModel(JSON.stringify({ + const launchConfig = new ScopedConfigurationModel(JSON.stringify({ awesome: false }), '', 'launch'); @@ -54,11 +54,11 @@ suite('ConfigurationService - Model', () => { } }; - assert.deepEqual(new WorkspaceConfigModel(settingsConfig, [launchConfig]).contents, expected); + assert.deepEqual(new FolderConfigurationModel(settingsConfig, [launchConfig]).contents, expected); }); test('Test consolidate (settings and launch and tasks) - launch/tasks wins over settings file', () => { - const settingsConfig = new WorkspaceSettingsConfigModel(JSON.stringify({ + const settingsConfig = new FolderSettingsModel(JSON.stringify({ awesome: true, launch: { launchConfig: 'defined', @@ -70,11 +70,11 @@ suite('ConfigurationService - Model', () => { } })); - const tasksConfig = new ScopedConfigModel(JSON.stringify({ + const tasksConfig = new ScopedConfigurationModel(JSON.stringify({ taskConfig: 'overwritten', }), '', 'tasks'); - const launchConfig = new ScopedConfigModel(JSON.stringify({ + const launchConfig = new ScopedConfigurationModel(JSON.stringify({ launchConfig: 'overwritten', }), '', 'launch'); @@ -90,7 +90,7 @@ suite('ConfigurationService - Model', () => { } }; - assert.deepEqual(new WorkspaceConfigModel(settingsConfig, [launchConfig, tasksConfig]).contents, expected); - assert.deepEqual(new WorkspaceConfigModel(settingsConfig, [tasksConfig, launchConfig]).contents, expected); + assert.deepEqual(new FolderConfigurationModel(settingsConfig, [launchConfig, tasksConfig]).contents, expected); + assert.deepEqual(new FolderConfigurationModel(settingsConfig, [tasksConfig, launchConfig]).contents, expected); }); }); \ No newline at end of file diff --git a/src/vs/workbench/services/configurationResolver/test/node/configurationResolverService.test.ts b/src/vs/workbench/services/configurationResolver/test/node/configurationResolverService.test.ts index 2bf018a3473..df5b6f68b63 100644 --- a/src/vs/workbench/services/configurationResolver/test/node/configurationResolverService.test.ts +++ b/src/vs/workbench/services/configurationResolver/test/node/configurationResolverService.test.ts @@ -340,8 +340,8 @@ class MockConfigurationService implements IConfigurationService { public serviceId = IConfigurationService; public constructor(private configuration: any = {}) { } public reloadConfiguration(section?: string): TPromise { return TPromise.as(this.getConfiguration()); } - public lookup(key: string) { return { value: getConfigurationValue(this.getConfiguration(), key), default: getConfigurationValue(this.getConfiguration(), key), user: getConfigurationValue(this.getConfiguration(), key) }; } - public keys() { return { default: [], user: [] }; } + public lookup(key: string) { return { value: getConfigurationValue(this.getConfiguration(), key), default: getConfigurationValue(this.getConfiguration(), key), user: getConfigurationValue(this.getConfiguration(), key), workspace: void 0 }; } + public keys() { return { default: [], user: [], workspace: [] }; } public getConfiguration(): any { return this.configuration; } public onDidUpdateConfiguration() { return { dispose() { } }; } } diff --git a/src/vs/workbench/test/workbenchTestServices.ts b/src/vs/workbench/test/workbenchTestServices.ts index 2ddd8120752..fed3804bdff 100644 --- a/src/vs/workbench/test/workbenchTestServices.ts +++ b/src/vs/workbench/test/workbenchTestServices.ts @@ -64,7 +64,7 @@ export const TestEnvironmentService = new EnvironmentService(parseArgs(process.a export class TestContextService implements IWorkspaceContextService { public _serviceBrand: any; - private workspace: any; + private workspace: IWorkspace; private id: string; private options: any; @@ -97,6 +97,10 @@ export class TestContextService implements IWorkspaceContextService { return this.workspace ? { id: this.id, roots: [this.workspace.resource], name: this.workspace.resource.fsPath } : void 0; } + public getRoot(resource: URI): URI { + return this.isInsideWorkspace(resource) ? this.workspace.resource : null; + } + public setWorkspace(workspace: any): void { this.workspace = workspace; } -- GitLab From f4eda002f1f9a9dd969432951f3c1ad97f2853a5 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 15 Jun 2017 13:06:32 +0200 Subject: [PATCH 0874/1347] :lipstick: --- src/vs/base/common/filters.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/vs/base/common/filters.ts b/src/vs/base/common/filters.ts index 34966eedc71..ebf1af9fe90 100644 --- a/src/vs/base/common/filters.ts +++ b/src/vs/base/common/filters.ts @@ -554,9 +554,10 @@ export function fuzzyScore(pattern: string, word: string): [number, number[]] { return undefined; } - let topMatch = _bucket.shift(); - for (const match of _bucket) { - if (!topMatch || topMatch[0] < match[0]) { + let topMatch = _bucket[0]; + for (let i = 1; i < _bucket.length; i++) { + let match = _bucket[i]; + if (topMatch[0] < match[0]) { topMatch = match; } } -- GitLab From 77bdf51137c1f584e7358a03aedaeeec1d338ad0 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 15 Jun 2017 14:33:35 +0200 Subject: [PATCH 0875/1347] test --- src/vs/base/test/common/filters.test.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/vs/base/test/common/filters.test.ts b/src/vs/base/test/common/filters.test.ts index f5c4bb30869..b055bddefb2 100644 --- a/src/vs/base/test/common/filters.test.ts +++ b/src/vs/base/test/common/filters.test.ts @@ -397,6 +397,10 @@ suite('Filters', () => { assertTopScore(fuzzyScore, 'title', 1, 'files.trimTrailingWhitespace', 'window.title'); }); + // test('Unexpected suggestion scoring, #28791', function () { + // assertTopScore(fuzzyScore, '_lines', 1, '_lineStarts', '_lines'); + // }); + test('nextTypoPermutation', function () { function assertTypos(pattern: string, ...variants: string[]) { -- GitLab From a248e3362276f4f29a2e3f3c1858a7a67f4562bc Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 15 Jun 2017 15:00:43 +0200 Subject: [PATCH 0876/1347] fix #28791 --- src/vs/base/common/filters.ts | 11 ++++++++--- src/vs/base/test/common/filters.test.ts | 8 +++++--- 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/src/vs/base/common/filters.ts b/src/vs/base/common/filters.ts index ebf1af9fe90..684c17cc556 100644 --- a/src/vs/base/common/filters.ts +++ b/src/vs/base/common/filters.ts @@ -463,6 +463,9 @@ export function fuzzyScore(pattern: string, word: string): [number, number[]] { let patternPos = patternStartPos; let wordPos = 0; + // Run a simple check if the characters of pattern occur + // (in order) at all in word. If that isn't the case we + // stop because no match will be possible while (patternPos < patternLen && wordPos < wordLen) { if (lowPattern[patternPos] === lowWord[wordPos]) { patternPos += 1; @@ -470,10 +473,10 @@ export function fuzzyScore(pattern: string, word: string): [number, number[]] { wordPos += 1; } if (patternPos !== patternLen) { - // no simple matches found -> return early return undefined; } + // There will be a mach, fill in tables for (patternPos = patternStartPos + 1; patternPos <= patternLen; patternPos++) { let lastLowWordChar = ''; @@ -483,20 +486,22 @@ export function fuzzyScore(pattern: string, word: string): [number, number[]] { let score = -1; let lowWordChar = lowWord[wordPos - 1]; if (lowPattern[patternPos - 1] === lowWordChar) { - - if (wordPos === 1) { + if (wordPos === (patternPos - patternStartPos)) { + // common prefix: `foobar <-> foobaz` if (pattern[patternPos - 1] === word[wordPos - 1]) { score = 7; } else { score = 5; } } else if (lowWordChar !== word[wordPos - 1]) { + // hitting upper-case: `foo <-> forOthers` if (pattern[patternPos - 1] === word[wordPos - 1]) { score = 7; } else { score = 5; } } else if (_seps[lastLowWordChar]) { + // post separator: `foo <-> bar_foo` score = 5; } else { diff --git a/src/vs/base/test/common/filters.test.ts b/src/vs/base/test/common/filters.test.ts index b055bddefb2..663c7cccf3d 100644 --- a/src/vs/base/test/common/filters.test.ts +++ b/src/vs/base/test/common/filters.test.ts @@ -397,9 +397,11 @@ suite('Filters', () => { assertTopScore(fuzzyScore, 'title', 1, 'files.trimTrailingWhitespace', 'window.title'); }); - // test('Unexpected suggestion scoring, #28791', function () { - // assertTopScore(fuzzyScore, '_lines', 1, '_lineStarts', '_lines'); - // }); + test('Unexpected suggestion scoring, #28791', function () { + assertTopScore(fuzzyScore, '_lines', 1, '_lineStarts', '_lines'); + assertTopScore(fuzzyScore, '_lines', 1, '_lineS', '_lines'); + assertTopScore(fuzzyScore, '_lineS', 0, '_lineS', '_lines'); + }); test('nextTypoPermutation', function () { -- GitLab From 73dad2ebb9ee82fd40d358fbdf39e1403ced342e Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 15 Jun 2017 15:27:02 +0200 Subject: [PATCH 0877/1347] multi root - stable workspace.id --- .../storage/test/storageService.test.ts | 2 +- src/vs/platform/workspace/common/workspace.ts | 19 +-- .../workspace/test/common/testWorkspace.ts | 2 +- src/vs/workbench/api/node/extHost.protocol.ts | 1 + .../api/node/extHostExtensionService.ts | 7 +- src/vs/workbench/electron-browser/main.ts | 108 ++++++++---------- src/vs/workbench/node/extensionHostMain.ts | 1 - .../electron-browser/terminalInstance.test.ts | 10 +- .../configuration/node/configuration.ts | 10 +- .../api/extHostWorkspace.test.ts | 6 +- 10 files changed, 82 insertions(+), 84 deletions(-) diff --git a/src/vs/platform/storage/test/storageService.test.ts b/src/vs/platform/storage/test/storageService.test.ts index 2978c54f134..2893d767a27 100644 --- a/src/vs/platform/storage/test/storageService.test.ts +++ b/src/vs/platform/storage/test/storageService.test.ts @@ -95,7 +95,7 @@ suite('Workbench StorageSevice', () => { assert.strictEqual(s.get('wkey1', StorageScope.WORKSPACE), 'foo'); assert.strictEqual(s.get('wkey2', StorageScope.WORKSPACE), 'foo2'); - ws = new Workspace(TestWorkspace.resource, TestWorkspace.name); + ws = new Workspace(TestWorkspace.resource, Date.now()); ws.uid = new Date().getTime() + 100; s = new StorageService(storageImpl, null, ws); diff --git a/src/vs/platform/workspace/common/workspace.ts b/src/vs/platform/workspace/common/workspace.ts index ab469fc3e8a..e5670d0fa6c 100644 --- a/src/vs/platform/workspace/common/workspace.ts +++ b/src/vs/platform/workspace/common/workspace.ts @@ -60,7 +60,6 @@ export interface IWorkspaceContextService { * Given a workspace relative path, returns the resource with the absolute path. */ toResource: (workspaceRelativePath: string) => URI; - } export interface IWorkspace { @@ -71,6 +70,11 @@ export interface IWorkspace { */ resource: URI; + /** + * the creation date of the workspace if known. + */ + ctime: number; + /** * the name of the workspace */ @@ -93,12 +97,13 @@ export interface IWorkspace2 { * Mutliple roots in this workspace. First entry is master and never changes. */ readonly roots: URI[]; - } export class Workspace implements IWorkspace { + private _name: string; - constructor(private _resource: URI, private _name?: string) { + constructor(private _resource: URI, private _ctime?: number) { + this._name = paths.basename(this._resource.fsPath) || this._resource.fsPath; } public get resource(): URI { @@ -109,6 +114,10 @@ export class Workspace implements IWorkspace { return this._name; } + public get ctime(): number { + return this._ctime; + } + public isInsideWorkspace(resource: URI): boolean { if (resource) { return isEqualOrParent(resource.fsPath, this._resource.fsPath, !isLinux /* ignorecase */); @@ -132,8 +141,4 @@ export class Workspace implements IWorkspace { return null; } - - public toJSON() { - return { resource: this._resource, name: this._name }; - } } \ No newline at end of file diff --git a/src/vs/platform/workspace/test/common/testWorkspace.ts b/src/vs/platform/workspace/test/common/testWorkspace.ts index 4400e7544ea..8933555a376 100644 --- a/src/vs/platform/workspace/test/common/testWorkspace.ts +++ b/src/vs/platform/workspace/test/common/testWorkspace.ts @@ -8,5 +8,5 @@ import URI from 'vs/base/common/uri'; export const TestWorkspace = new Workspace( URI.file('C:\\testWorkspace'), - 'Test Workspace' + Date.now() ); diff --git a/src/vs/workbench/api/node/extHost.protocol.ts b/src/vs/workbench/api/node/extHost.protocol.ts index 20cf8960029..9cb2b395ee6 100644 --- a/src/vs/workbench/api/node/extHost.protocol.ts +++ b/src/vs/workbench/api/node/extHost.protocol.ts @@ -58,6 +58,7 @@ export interface IEnvironment { export interface IWorkspaceData { id: string; + name: string; roots: URI[]; } diff --git a/src/vs/workbench/api/node/extHostExtensionService.ts b/src/vs/workbench/api/node/extHostExtensionService.ts index 67acd239b02..ff5a189ebb7 100644 --- a/src/vs/workbench/api/node/extHostExtensionService.ts +++ b/src/vs/workbench/api/node/extHostExtensionService.ts @@ -16,7 +16,6 @@ import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { createApiFactory, initializeExtensionApi } from 'vs/workbench/api/node/extHost.api.impl'; import { IThreadService } from 'vs/workbench/services/thread/common/threadService'; import { MainContext, MainProcessExtensionServiceShape, IWorkspaceData, IEnvironment, IInitData } from './extHost.protocol'; -import { createHash } from 'crypto'; const hasOwnProperty = Object.hasOwnProperty; @@ -130,11 +129,7 @@ class ExtensionStoragePath { return TPromise.as(undefined); } // TODO@joh what to do with multiple roots? - const storageName = createHash('md5') - .update(this._workspace.roots[0].fsPath) - .update(this._workspace.id || '') - .digest('hex'); - + const storageName = this._workspace.id; const storagePath = join(this._environment.appSettingsHome, 'workspaceStorage', storageName); return dirExists(storagePath).then(exists => { diff --git a/src/vs/workbench/electron-browser/main.ts b/src/vs/workbench/electron-browser/main.ts index cf8ae033c6d..dd2f096321f 100644 --- a/src/vs/workbench/electron-browser/main.ts +++ b/src/vs/workbench/electron-browser/main.ts @@ -18,7 +18,7 @@ import paths = require('vs/base/common/paths'); import uri from 'vs/base/common/uri'; import strings = require('vs/base/common/strings'); import { IResourceInput } from 'vs/platform/editor/common/editor'; -import { Workspace } from 'vs/platform/workspace/common/workspace'; +import { IWorkspace, Workspace } from "vs/platform/workspace/common/workspace"; import { WorkspaceConfigurationService } from 'vs/workbench/services/configuration/node/configuration'; import { realpath, stat } from 'vs/base/node/pfs'; import { EnvironmentService } from 'vs/platform/environment/node/environmentService'; @@ -95,47 +95,45 @@ function toInputs(paths: IPath[], isUntitledFile?: boolean): IResourceInput[] { } function openWorkbench(configuration: IWindowConfiguration, options: IOptions): TPromise { - return getWorkspace(configuration).then(workspace => { + return resolveWorkspace(configuration).then(workspace => { const environmentService = new EnvironmentService(configuration, configuration.execPath); const workspaceConfigurationService = new WorkspaceConfigurationService(environmentService, workspace); const timerService = new TimerService((window).MonacoEnvironment.timers as IInitData, !workspaceConfigurationService.hasWorkspace()); - - return createStorageService(configuration, environmentService).then(storageService => { - - // Since the configuration service is one of the core services that is used in so many places, we initialize it - // right before startup of the workbench shell to have its data ready for consumers - return workspaceConfigurationService.initialize().then(() => { - timerService.beforeDOMContentLoaded = Date.now(); - - return domContentLoaded().then(() => { - timerService.afterDOMContentLoaded = Date.now(); - - // Open Shell - timerService.beforeWorkbenchOpen = Date.now(); - const shell = new WorkbenchShell(document.body, { - contextService: workspaceConfigurationService, - configurationService: workspaceConfigurationService, - environmentService, - timerService, - storageService - }, configuration, options); - shell.open(); - - // Inform user about loading issues from the loader - (self).require.config({ - onError: (err: any) => { - if (err.errorCode === 'load') { - shell.onUnexpectedError(loaderError(err)); - } + const storageService = createStorageService(workspace, configuration, environmentService); + + // Since the configuration service is one of the core services that is used in so many places, we initialize it + // right before startup of the workbench shell to have its data ready for consumers + return workspaceConfigurationService.initialize().then(() => { + timerService.beforeDOMContentLoaded = Date.now(); + + return domContentLoaded().then(() => { + timerService.afterDOMContentLoaded = Date.now(); + + // Open Shell + timerService.beforeWorkbenchOpen = Date.now(); + const shell = new WorkbenchShell(document.body, { + contextService: workspaceConfigurationService, + configurationService: workspaceConfigurationService, + environmentService, + timerService, + storageService + }, configuration, options); + shell.open(); + + // Inform user about loading issues from the loader + (self).require.config({ + onError: (err: any) => { + if (err.errorCode === 'load') { + shell.onUnexpectedError(loaderError(err)); } - }); + } }); }); }); }); } -function getWorkspace(configuration: IWindowConfiguration): TPromise { +function resolveWorkspace(configuration: IWindowConfiguration): TPromise { if (!configuration.workspacePath) { return TPromise.as(null); } @@ -153,10 +151,11 @@ function getWorkspace(configuration: IWindowConfiguration): TPromise // update config configuration.workspacePath = realWorkspacePath; - const workspaceResource = uri.file(realWorkspacePath); - const folderName = path.basename(realWorkspacePath) || realWorkspacePath; - - return new Workspace(workspaceResource, folderName); + // resolve ctime of workspace + return stat(realWorkspacePath).then(folderStat => new Workspace( + uri.file(realWorkspacePath), + platform.isLinux ? folderStat.ino : folderStat.birthtime.getTime() // On Linux, birthtime is ctime, so we cannot use it! We use the ino instead! + )); }, error => { errors.onUnexpectedError(error); @@ -164,31 +163,24 @@ function getWorkspace(configuration: IWindowConfiguration): TPromise }); } -function createStorageService(configuration: IWindowConfiguration, environmentService: IEnvironmentService): TPromise { - let workspaceStatPromise: TPromise = TPromise.as(null); - if (configuration.workspacePath) { - workspaceStatPromise = stat(configuration.workspacePath); +function createStorageService(workspace: IWorkspace, configuration: IWindowConfiguration, environmentService: IEnvironmentService): IStorageService { + let id: IWorkspaceStorageIdentifier; + if (workspace) { + id = { resource: workspace.resource, uid: workspace.ctime }; + } else if (configuration.backupPath) { + // if we do not have a workspace open, we need to find another identifier for the window to store + // workspace UI state. if we have a backup path in the configuration we can use that because this + // will be a unique identifier per window that is stable between restarts as long as there are + // dirty files in the workspace. + // We use basename() to produce a short identifier, we do not need the full path. We use a custom + // scheme so that we can later distinguish these identifiers from the workspace one. + id = { resource: uri.from({ path: path.basename(configuration.backupPath), scheme: 'empty' }) }; } - return workspaceStatPromise.then(stat => { - let id: IWorkspaceStorageIdentifier; - if (stat) { - id = { resource: uri.file(configuration.workspacePath), uid: platform.isLinux ? stat.ino : stat.birthtime.getTime() }; - } else if (configuration.backupPath) { - // if we do not have a workspace open, we need to find another identifier for the window to store - // workspace UI state. if we have a backup path in the configuration we can use that because this - // will be a unique identifier per window that is stable between restarts as long as there are - // dirty files in the workspace. - // We use basename() to produce a short identifier, we do not need the full path. We use a custom - // scheme so that we can later distinguish these identifiers from the workspace one. - id = { resource: uri.from({ path: path.basename(configuration.backupPath), scheme: 'empty' }) }; - } + const disableStorage = !!environmentService.extensionTestsPath; // never keep any state when running extension tests! + const storage = disableStorage ? inMemoryLocalStorageInstance : window.localStorage; - const disableStorage = !!environmentService.extensionTestsPath; // never keep any state when running extension tests! - const storage = disableStorage ? inMemoryLocalStorageInstance : window.localStorage; - - return new StorageService(storage, storage, id); - }); + return new StorageService(storage, storage, id); } function loaderError(err: Error): Error { diff --git a/src/vs/workbench/node/extensionHostMain.ts b/src/vs/workbench/node/extensionHostMain.ts index 5c361eb9b06..3cd60b367ec 100644 --- a/src/vs/workbench/node/extensionHostMain.ts +++ b/src/vs/workbench/node/extensionHostMain.ts @@ -104,7 +104,6 @@ export class ExtensionHostMain { return TPromise.as(null); } - const desiredFilesMap: { [filename: string]: boolean; } = {}; diff --git a/src/vs/workbench/parts/terminal/test/electron-browser/terminalInstance.test.ts b/src/vs/workbench/parts/terminal/test/electron-browser/terminalInstance.test.ts index 0542ce7f902..df83db52ee2 100644 --- a/src/vs/workbench/parts/terminal/test/electron-browser/terminalInstance.test.ts +++ b/src/vs/workbench/parts/terminal/test/electron-browser/terminalInstance.test.ts @@ -107,7 +107,7 @@ suite('Workbench - TerminalInstance', () => { }); test('should use to the workspace if it exists', () => { - assertPathsMatch(instance._getCwd({ executable: null, args: [] }, { resource: Uri.file('/foo') }), '/foo'); + assertPathsMatch(instance._getCwd({ executable: null, args: [] }, { resource: Uri.file('/foo'), ctime: Date.now() }), '/foo'); }); test('should use an absolute custom cwd as is', () => { @@ -117,11 +117,11 @@ suite('Workbench - TerminalInstance', () => { test('should normalize a relative custom cwd against the workspace path', () => { configHelper.config.cwd = 'foo'; - assertPathsMatch(instance._getCwd({ executable: null, args: [] }, { resource: Uri.file('/bar') }), '/bar/foo'); + assertPathsMatch(instance._getCwd({ executable: null, args: [] }, { resource: Uri.file('/bar'), ctime: Date.now() }), '/bar/foo'); configHelper.config.cwd = './foo'; - assertPathsMatch(instance._getCwd({ executable: null, args: [] }, { resource: Uri.file('/bar') }), '/bar/foo'); + assertPathsMatch(instance._getCwd({ executable: null, args: [] }, { resource: Uri.file('/bar'), ctime: Date.now() }), '/bar/foo'); configHelper.config.cwd = '../foo'; - assertPathsMatch(instance._getCwd({ executable: null, args: [] }, { resource: Uri.file('/bar') }, ), '/foo'); + assertPathsMatch(instance._getCwd({ executable: null, args: [] }, { resource: Uri.file('/bar'), ctime: Date.now() }, ), '/foo'); }); test('should fall back for relative a custom cwd that doesn\'t have a workspace', () => { @@ -135,7 +135,7 @@ suite('Workbench - TerminalInstance', () => { test('should ignore custom cwd when told to ignore', () => { configHelper.config.cwd = '/foo'; - assertPathsMatch(instance._getCwd({ executable: null, args: [], ignoreConfigurationCwd: true }, { resource: Uri.file('/bar') }), '/bar'); + assertPathsMatch(instance._getCwd({ executable: null, args: [], ignoreConfigurationCwd: true }, { resource: Uri.file('/bar'), ctime: Date.now() }), '/bar'); }); }); }); \ No newline at end of file diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index fb935685395..a2ba71e00b7 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -69,7 +69,7 @@ class Workspace implements IWorkspace2 { public get name(): string { if (!this._name) { - this._name = this.roots.map(root => basename(root.fsPath)).join(', '); + this._name = this.roots.map(root => basename(root.fsPath) || root.fsPath).join(', '); } return this._name; @@ -101,7 +101,13 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp constructor(private environmentService: IEnvironmentService, private singleRootWorkspace?: SingleRootWorkspace, private workspaceSettingsRootFolder: string = WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME) { super(); - this.workspace = singleRootWorkspace ? new Workspace(createHash('md5').update(singleRootWorkspace.resource.toString()).digest('hex'), [singleRootWorkspace.resource]) : null; // TODO@Ben for now use the first root folder as id, but revisit this later + if (singleRootWorkspace) { + const workspaceId = createHash('md5').update(singleRootWorkspace.resource.fsPath).update(singleRootWorkspace.ctime ? String(singleRootWorkspace.ctime) : '').digest('hex'); + this.workspace = new Workspace(workspaceId, [singleRootWorkspace.resource]); + } else { + this.workspace = null; + } + this.rootsTrieMap = new TrieMap(TrieMap.PathSplitter); if (this.workspace) { this.rootsTrieMap.insert(this.workspace.roots[0].fsPath, this.workspace.roots[0]); diff --git a/src/vs/workbench/test/electron-browser/api/extHostWorkspace.test.ts b/src/vs/workbench/test/electron-browser/api/extHostWorkspace.test.ts index c66640c2bd7..da0cc1a86a6 100644 --- a/src/vs/workbench/test/electron-browser/api/extHostWorkspace.test.ts +++ b/src/vs/workbench/test/electron-browser/api/extHostWorkspace.test.ts @@ -14,7 +14,7 @@ suite('ExtHostWorkspace', function () { test('asRelativePath', function () { - const ws = new ExtHostWorkspace(new TestThreadService(), { id: 'foo', roots: [URI.file('/Coding/Applications/NewsWoWBot')] }); + const ws = new ExtHostWorkspace(new TestThreadService(), { id: 'foo', roots: [URI.file('/Coding/Applications/NewsWoWBot')], name: 'Test' }); assert.equal(ws.getRelativePath('/Coding/Applications/NewsWoWBot/bernd/das/brot'), 'bernd/das/brot'); assert.equal(ws.getRelativePath('/Apps/DartPubCache/hosted/pub.dartlang.org/convert-2.0.1/lib/src/hex.dart'), @@ -28,7 +28,7 @@ suite('ExtHostWorkspace', function () { test('asRelativePath, same paths, #11402', function () { const root = '/home/aeschli/workspaces/samples/docker'; const input = '/home/aeschli/workspaces/samples/docker'; - const ws = new ExtHostWorkspace(new TestThreadService(), { id: 'foo', roots: [URI.file(root)] }); + const ws = new ExtHostWorkspace(new TestThreadService(), { id: 'foo', roots: [URI.file(root)], name: 'Test' }); assert.equal(ws.getRelativePath(input), input); @@ -43,7 +43,7 @@ suite('ExtHostWorkspace', function () { }); test('asRelativePath, multiple folders', function () { - const ws = new ExtHostWorkspace(new TestThreadService(), { id: 'foo', roots: [URI.file('/Coding/One'), URI.file('/Coding/Two')] }); + const ws = new ExtHostWorkspace(new TestThreadService(), { id: 'foo', roots: [URI.file('/Coding/One'), URI.file('/Coding/Two')], name: 'Test' }); assert.equal(ws.getRelativePath('/Coding/One/file.txt'), 'file.txt'); assert.equal(ws.getRelativePath('/Coding/Two/files/out.txt'), 'files/out.txt'); assert.equal(ws.getRelativePath('/Coding/Two2/files/out.txt'), '/Coding/Two2/files/out.txt'); -- GitLab From 6c502802f350eaf7675e5604e337c7a173ee88f2 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 15 Jun 2017 15:36:16 +0200 Subject: [PATCH 0878/1347] :lipstick: --- src/vs/workbench/electron-browser/main.ts | 14 ++++++------- .../configuration/node/configuration.ts | 20 +++++++++---------- 2 files changed, 17 insertions(+), 17 deletions(-) diff --git a/src/vs/workbench/electron-browser/main.ts b/src/vs/workbench/electron-browser/main.ts index dd2f096321f..c01173bccc2 100644 --- a/src/vs/workbench/electron-browser/main.ts +++ b/src/vs/workbench/electron-browser/main.ts @@ -18,7 +18,7 @@ import paths = require('vs/base/common/paths'); import uri from 'vs/base/common/uri'; import strings = require('vs/base/common/strings'); import { IResourceInput } from 'vs/platform/editor/common/editor'; -import { IWorkspace, Workspace } from "vs/platform/workspace/common/workspace"; +import { Workspace as LegacyWorkspace } from "vs/platform/workspace/common/workspace"; import { WorkspaceConfigurationService } from 'vs/workbench/services/configuration/node/configuration'; import { realpath, stat } from 'vs/base/node/pfs'; import { EnvironmentService } from 'vs/platform/environment/node/environmentService'; @@ -95,11 +95,11 @@ function toInputs(paths: IPath[], isUntitledFile?: boolean): IResourceInput[] { } function openWorkbench(configuration: IWindowConfiguration, options: IOptions): TPromise { - return resolveWorkspace(configuration).then(workspace => { + return resolveLegacyWorkspace(configuration).then(legacyWorkspace => { const environmentService = new EnvironmentService(configuration, configuration.execPath); - const workspaceConfigurationService = new WorkspaceConfigurationService(environmentService, workspace); + const workspaceConfigurationService = new WorkspaceConfigurationService(environmentService, legacyWorkspace); const timerService = new TimerService((window).MonacoEnvironment.timers as IInitData, !workspaceConfigurationService.hasWorkspace()); - const storageService = createStorageService(workspace, configuration, environmentService); + const storageService = createStorageService(legacyWorkspace, configuration, environmentService); // Since the configuration service is one of the core services that is used in so many places, we initialize it // right before startup of the workbench shell to have its data ready for consumers @@ -133,7 +133,7 @@ function openWorkbench(configuration: IWindowConfiguration, options: IOptions): }); } -function resolveWorkspace(configuration: IWindowConfiguration): TPromise { +function resolveLegacyWorkspace(configuration: IWindowConfiguration): TPromise { if (!configuration.workspacePath) { return TPromise.as(null); } @@ -152,7 +152,7 @@ function resolveWorkspace(configuration: IWindowConfiguration): TPromise new Workspace( + return stat(realWorkspacePath).then(folderStat => new LegacyWorkspace( uri.file(realWorkspacePath), platform.isLinux ? folderStat.ino : folderStat.birthtime.getTime() // On Linux, birthtime is ctime, so we cannot use it! We use the ino instead! )); @@ -163,7 +163,7 @@ function resolveWorkspace(configuration: IWindowConfiguration): TPromise = new TrieMap(TrieMap.PathSplitter); private _configuration: Configuration; - constructor(private environmentService: IEnvironmentService, private singleRootWorkspace?: SingleRootWorkspace, private workspaceSettingsRootFolder: string = WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME) { + constructor(private environmentService: IEnvironmentService, private legacyWorkspace?: LegacyWorkspace, private workspaceSettingsRootFolder: string = WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME) { super(); - if (singleRootWorkspace) { - const workspaceId = createHash('md5').update(singleRootWorkspace.resource.fsPath).update(singleRootWorkspace.ctime ? String(singleRootWorkspace.ctime) : '').digest('hex'); - this.workspace = new Workspace(workspaceId, [singleRootWorkspace.resource]); + if (legacyWorkspace) { + const workspaceId = createHash('md5').update(legacyWorkspace.resource.fsPath).update(legacyWorkspace.ctime ? String(legacyWorkspace.ctime) : '').digest('hex'); + this.workspace = new Workspace(workspaceId, [legacyWorkspace.resource]); } else { this.workspace = null; } @@ -161,8 +161,8 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } } - public getWorkspace(): IWorkspace { - return this.singleRootWorkspace; + public getWorkspace(): ILegacyWorkspace { + return this.legacyWorkspace; } public getWorkspace2(): IWorkspace2 { @@ -182,15 +182,15 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } public isInsideWorkspace(resource: URI): boolean { - return this.workspace ? this.singleRootWorkspace.isInsideWorkspace(resource) : false; + return this.workspace ? this.legacyWorkspace.isInsideWorkspace(resource) : false; } public toWorkspaceRelativePath(resource: URI, toOSPath?: boolean): string { - return this.workspace ? this.singleRootWorkspace.toWorkspaceRelativePath(resource, toOSPath) : null; + return this.workspace ? this.legacyWorkspace.toWorkspaceRelativePath(resource, toOSPath) : null; } public toResource(workspaceRelativePath: string): URI { - return this.workspace ? this.singleRootWorkspace.toResource(workspaceRelativePath) : null; + return this.workspace ? this.legacyWorkspace.toResource(workspaceRelativePath) : null; } public get configuration(): BaseConfiguration { -- GitLab From 6dd96307893f57bc2385cb236589d7a7509bf8e7 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 15 Jun 2017 15:51:18 +0200 Subject: [PATCH 0879/1347] fix #28213 --- src/vs/workbench/browser/parts/quickopen/quickOpenController.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts index b8da38bc822..47e8f16d80e 100644 --- a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts +++ b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts @@ -195,6 +195,7 @@ export class QuickOpenController extends Component implements IQuickOpenService currentDecoration = !!message ? Severity.Error : void 0; const newPick = message || defaultMessage; if (newPick !== currentPick) { + options.valueSelection = [lastValue.length, lastValue.length]; currentPick = newPick; resolve(new TPromise(init)); } -- GitLab From 6a1366de98bc18b973b67454111b17d2a4961e88 Mon Sep 17 00:00:00 2001 From: isidor Date: Thu, 15 Jun 2017 16:02:54 +0200 Subject: [PATCH 0880/1347] explorerView: remove use of root fully --- .../parts/files/browser/views/explorerView.ts | 77 ++++++++++--------- .../parts/files/common/explorerModel.ts | 13 ++-- 2 files changed, 45 insertions(+), 45 deletions(-) diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index 7366bde9697..bc207163e9c 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -340,10 +340,6 @@ export class ExplorerView extends CollapsibleView { return toResource(input, { supportSideBySide: true, filter: 'file' }); } - private get root(): FileStat { - return this.explorerViewer ? (this.explorerViewer.getInput()) : null; - } - private get isCreated(): boolean { return this.explorerViewer && this.explorerViewer.getInput(); } @@ -687,7 +683,11 @@ export class ExplorerView extends CollapsibleView { } private doRefresh(): TPromise { - const targetsToResolve: URI[] = []; + const targetsToResolve: { root: FileStat, resource: URI, options: { resolveTo: URI[] } }[] = []; + this.model.roots.forEach(root => { + const rootAndTargets = { root, resource: root.resource, options: { resolveTo: [] } }; + targetsToResolve.push(rootAndTargets); + }); let targetsToExpand: URI[] = []; if (this.settings[ExplorerView.MEMENTO_EXPANDED_FOLDER_RESOURCES]) { @@ -698,48 +698,50 @@ export class ExplorerView extends CollapsibleView { if (!this.isCreated) { const activeFile = this.getActiveFile(); if (activeFile) { - targetsToResolve.push(activeFile); + const root = this.contextService.getRoot(activeFile); + if (root) { + const found = targetsToResolve.filter(t => t.root.resource.toString() === root.toString()).pop(); + found.options.resolveTo.push(activeFile); + } } - if (targetsToExpand.length) { - targetsToResolve.push(...targetsToExpand); - } + targetsToExpand.forEach(toExpand => { + const root = this.contextService.getRoot(toExpand); + if (root) { + const found = targetsToResolve.filter(ttr => ttr.resource.toString() === root.toString()).pop(); + found.options.resolveTo.push(toExpand); + } + }); } // Subsequent refresh: Receive targets through expanded folders in tree else { - this.getResolvedDirectories(this.root, targetsToResolve); + targetsToResolve.forEach(t => { + this.getResolvedDirectories(t.root, t.options.resolveTo); + }); } // Load Root Stat with given target path configured - const options: IResolveFileOptions = { resolveTo: targetsToResolve }; - const promise = this.fileService.resolveFile(this.contextService.getWorkspace().resource, options).then(stat => { - let explorerPromise: TPromise; - + const promise = this.fileService.resolveFiles(targetsToResolve).then(stats => { // Convert to model - const modelStat = FileStat.create(stat, options.resolveTo); - - // First time refresh: The stat becomes the input of the viewer - if (!this.isCreated) { - explorerPromise = this.explorerViewer.setInput(modelStat).then(() => { - - // Make sure to expand all folders that where expanded in the previous session - if (targetsToExpand) { - return this.explorerViewer.expandAll(targetsToExpand.map(expand => this.root.find(expand))); - } + const modelStats = stats.map((stat, index) => FileStat.create(stat, targetsToResolve[index].options.resolveTo)); + // Subsequent refresh: Merge stat into our local model and refresh tree + modelStats.forEach((modelStat, index) => FileStat.mergeLocalWithDisk(modelStat, this.model.roots[index])); - return TPromise.as(null); - }); + if (this.isCreated) { + return this.explorerViewer.refresh(); } - // Subsequent refresh: Merge stat into our local model and refresh tree - else { - FileStat.mergeLocalWithDisk(modelStat, this.root); + // First time refresh: The stat becomes the input of the viewer + return this.explorerViewer.setInput(this.model).then(() => { - explorerPromise = this.explorerViewer.refresh(this.root); - } + // Make sure to expand all folders that where expanded in the previous session + if (targetsToExpand) { + return this.explorerViewer.expandAll(targetsToExpand.map(expand => this.model.findFirst(expand))); + } - return explorerPromise; + return TPromise.as(null); + }); }, (e: any) => TPromise.wrapError(e)); this.progressService.showWhile(promise, this.partService.isCreated() ? 800 : 3200 /* less ugly initial startup */); @@ -796,23 +798,24 @@ export class ExplorerView extends CollapsibleView { return TPromise.as(null); } - const fileStat = this.root.find(resource); + const fileStat = this.model.findFirst(resource); if (fileStat) { return this.doSelect(fileStat, reveal); } // Stat needs to be resolved first and then revealed const options: IResolveFileOptions = { resolveTo: [resource] }; - return this.fileService.resolveFile(this.contextService.getWorkspace().resource, options).then(stat => { + const rootUri = this.contextService.getRoot(resource); + return this.fileService.resolveFile(rootUri, options).then(stat => { // Convert to model const modelStat = FileStat.create(stat, options.resolveTo); - + const root = this.model.roots.filter(r => r.resource.toString() === rootUri.toString()).pop(); // Update Input with disk Stat - FileStat.mergeLocalWithDisk(modelStat, this.root); + FileStat.mergeLocalWithDisk(modelStat, root); // Select and Reveal - return this.explorerViewer.refresh(this.root).then(() => this.doSelect(this.root.find(resource), reveal)); + return this.explorerViewer.refresh(root).then(() => this.doSelect(root.find(resource), reveal)); }, (e: any) => this.messageService.show(Severity.Error, e)); } diff --git a/src/vs/workbench/parts/files/common/explorerModel.ts b/src/vs/workbench/parts/files/common/explorerModel.ts index 7dfe1c667fa..6edd5279360 100644 --- a/src/vs/workbench/parts/files/common/explorerModel.ts +++ b/src/vs/workbench/parts/files/common/explorerModel.ts @@ -53,11 +53,6 @@ export class Model { return null; } - - public rootForResource(resource: URI): FileStat { - // TODO@Isidor temporary until we have a utility method for this - return this.roots[0]; - } } export class FileStat implements IFileStat { @@ -148,9 +143,11 @@ export class FileStat implements IFileStat { // Map resource => stat const oldLocalChildren = new ResourceMap(); - local.children.forEach((localChild: FileStat) => { - oldLocalChildren.set(localChild.resource, localChild); - }); + if (local.children) { + local.children.forEach((localChild: FileStat) => { + oldLocalChildren.set(localChild.resource, localChild); + }); + } // Clear current children local.children = []; -- GitLab From 2e474545c225d8f616b1209a8ec16c766724f8b2 Mon Sep 17 00:00:00 2001 From: isidor Date: Thu, 15 Jun 2017 16:03:12 +0200 Subject: [PATCH 0881/1347] explorerViewer: steps towards multi root --- .../parts/files/browser/views/explorerViewer.ts | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts index 04f7f093da8..39890cff44e 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts @@ -70,9 +70,12 @@ export class FileDataSource implements IDataSource { @IWorkspaceContextService private contextService: IWorkspaceContextService ) { } - public getId(tree: ITree, stat: FileStat): string { - // TODO@Isidor take the id of the root into account - return `:${stat.getId()}`; + public getId(tree: ITree, stat: FileStat | Model): string { + if (stat instanceof Model) { + return 'model'; + } + + return `${this.contextService.getRoot(stat.resource).toString()}:${stat.getId()}`; } public hasChildren(tree: ITree, stat: FileStat | Model): boolean { @@ -418,7 +421,7 @@ export class FileController extends DefaultController { this.state = state; } - public onLeftClick(tree: ITree, stat: FileStat, event: IMouseEvent, origin: string = 'mouse'): boolean { + public onLeftClick(tree: ITree, stat: FileStat | Model, event: IMouseEvent, origin: string = 'mouse'): boolean { const payload = { origin: origin }; const isDoubleClick = (origin === 'mouse' && event.detail === 2); @@ -435,8 +438,7 @@ export class FileController extends DefaultController { } // Handle root - const workspace = this.contextService.getWorkspace(); - if (workspace && stat.resource.toString() === workspace.resource.toString()) { + if (stat instanceof Model) { tree.clearFocus(payload); tree.clearSelection(payload); -- GitLab From 972b9a12f3ed1ad6b74d8848944f02b868a28cd5 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 15 Jun 2017 16:05:14 +0200 Subject: [PATCH 0882/1347] fix #28789 --- .../contrib/referenceSearch/browser/referencesWidget.ts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts index 955ce894d60..bcdefd93118 100644 --- a/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts +++ b/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.ts @@ -761,6 +761,14 @@ export class ReferenceWidget extends PeekViewWidget { // listen on model changes this._disposeOnNewModel.push(this._model.onDidChangeReferenceRange(reference => this._tree.refresh(reference))); + // listen on selection and focus + this._disposeOnNewModel.push(this._tree.addListener(Controller.Events.FOCUSED, (element) => { + if (element instanceof OneReference) { + this._revealReference(element); + this._onDidSelectReference.fire({ element, kind: 'show', source: 'tree' }); + } + })); + this._disposeOnNewModel.push(this._tree.addListener(Controller.Events.SELECTED, (element: any) => { if (element instanceof OneReference) { this._onDidSelectReference.fire({ element, kind: 'goto', source: 'tree' }); -- GitLab From 33cdd8d152be5b04c3ed6acc2e9478ac9997f8ab Mon Sep 17 00:00:00 2001 From: isidor Date: Thu, 15 Jun 2017 16:05:15 +0200 Subject: [PATCH 0883/1347] show roots in explorer only when there is more than 1 root --- src/vs/workbench/parts/files/browser/views/explorerView.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index bc207163e9c..a0003873dda 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -733,7 +733,8 @@ export class ExplorerView extends CollapsibleView { } // First time refresh: The stat becomes the input of the viewer - return this.explorerViewer.setInput(this.model).then(() => { + // Display roots only when there is more than 1 root + return this.explorerViewer.setInput(this.model.roots.length === 1 ? this.model.roots[0] : this.model).then(() => { // Make sure to expand all folders that where expanded in the previous session if (targetsToExpand) { -- GitLab From 23c631879af3d1f5af33edda2d738618d95850e1 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Thu, 15 Jun 2017 16:04:42 +0200 Subject: [PATCH 0884/1347] Add support to focus terminal and to control terminal instance reuse --- src/vs/vscode.proposed.d.ts | 32 ++ src/vs/workbench/api/node/extHost.api.impl.ts | 1 + src/vs/workbench/api/node/extHostTask.ts | 25 +- src/vs/workbench/api/node/extHostTypes.ts | 8 + .../parts/tasks/browser/buildQuickOpen.ts | 15 +- .../parts/tasks/browser/quickOpen.ts | 57 ++-- .../parts/tasks/browser/restartQuickOpen.ts | 8 +- .../parts/tasks/browser/taskQuickOpen.ts | 15 +- .../parts/tasks/browser/terminateQuickOpen.ts | 8 +- .../parts/tasks/browser/testQuickOpen.ts | 15 +- .../parts/tasks/common/taskConfiguration.ts | 306 +++++++++++------- .../parts/tasks/common/taskSystem.ts | 1 - src/vs/workbench/parts/tasks/common/tasks.ts | 44 +++ .../electron-browser/task.contribution.ts | 8 +- .../electron-browser/terminalTaskSystem.ts | 21 +- .../parts/tasks/node/processTaskSystem.ts | 4 - .../tasks/test/node/configuration.test.ts | 15 +- 17 files changed, 389 insertions(+), 194 deletions(-) diff --git a/src/vs/vscode.proposed.d.ts b/src/vs/vscode.proposed.d.ts index bd8dd3dd51e..29bde57d318 100644 --- a/src/vs/vscode.proposed.d.ts +++ b/src/vs/vscode.proposed.d.ts @@ -28,6 +28,28 @@ declare module 'vscode' { Never = 3 } + /** + * Controls how the task channel is used between tasks + */ + export enum TaskInstanceKind { + + /** + * Shares a channel with other tasks. This is the default. + */ + Shared = 1, + + /** + * Uses the same task channel for every run if possible. The task channel is not + * shared with other tasks. + */ + Same = 2, + + /** + * Creates a new task channel whenever that task is executed + */ + New = 3 + } + /** * Controls terminal specific behavior. */ @@ -42,6 +64,16 @@ declare module 'vscode' { * Controls whether the command is echoed in the terminal or not. */ echo?: boolean; + + /** + * Controls whether the task pane takes focus when the task is executed + */ + focus?: boolean; + + /** + * Controls in which pane the task is executed. + */ + instance?: TaskInstanceKind; } export interface ProcessTaskOptions { diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index 92943aa1520..4b1429aa294 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -489,6 +489,7 @@ export function createApiFactory( ThemeColor: extHostTypes.ThemeColor, // functions TaskRevealKind: extHostTypes.TaskRevealKind, + TaskInstanceKind: extHostTypes.TaskInstanceKind, TaskGroup: extHostTypes.TaskGroup, ShellTask: extHostTypes.ShellTask, ProcessTask: extHostTypes.ProcessTask diff --git a/src/vs/workbench/api/node/extHostTask.ts b/src/vs/workbench/api/node/extHostTask.ts index 180bc9ffbf3..28721295f7d 100644 --- a/src/vs/workbench/api/node/extHostTask.ts +++ b/src/vs/workbench/api/node/extHostTask.ts @@ -207,12 +207,33 @@ namespace TaskRevealKind { } } +namespace TaskInstanceKind { + export function from(value: vscode.TaskInstanceKind): TaskSystem.InstanceKind { + if (value === void 0 || value === null) { + return TaskSystem.InstanceKind.Shared; + } + switch (value) { + case types.TaskInstanceKind.Same: + return TaskSystem.InstanceKind.Same; + case types.TaskInstanceKind.New: + return TaskSystem.InstanceKind.New; + default: + return TaskSystem.InstanceKind.Shared; + } + } +} + namespace TerminalBehaviour { export function from(value: vscode.TaskTerminalBehavior): TaskSystem.TerminalBehavior { if (value === void 0 || value === null) { - return { reveal: TaskSystem.RevealKind.Always, echo: false }; + return { reveal: TaskSystem.RevealKind.Always, echo: true, focus: false, instance: TaskSystem.InstanceKind.Shared }; } - return { reveal: TaskRevealKind.from(value.reveal), echo: !!value.echo }; + return { + reveal: TaskRevealKind.from(value.reveal), + echo: value.echo === void 0 ? true : !!value.echo, + focus: !!value.focus, + instance: TaskInstanceKind.from(value.instance) + }; } } diff --git a/src/vs/workbench/api/node/extHostTypes.ts b/src/vs/workbench/api/node/extHostTypes.ts index 34a86f3e017..5b60f3cff85 100644 --- a/src/vs/workbench/api/node/extHostTypes.ts +++ b/src/vs/workbench/api/node/extHostTypes.ts @@ -1037,6 +1037,14 @@ export enum TaskRevealKind { Never = 3 } +export enum TaskInstanceKind { + Shared = 1, + + Same = 2, + + New = 3 +} + export class BaseTask { private _name: string; diff --git a/src/vs/workbench/parts/tasks/browser/buildQuickOpen.ts b/src/vs/workbench/parts/tasks/browser/buildQuickOpen.ts index 28b9db52514..0ef0d65fb3e 100644 --- a/src/vs/workbench/parts/tasks/browser/buildQuickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/buildQuickOpen.ts @@ -16,15 +16,20 @@ import { ITaskService } from 'vs/workbench/parts/tasks/common/taskService'; import * as base from './quickOpen'; class TaskEntry extends base.TaskEntry { - constructor(taskService: ITaskService, task: Task, highlights: Model.IHighlight[] = []) { - super(taskService, task, highlights); + constructor(taskService: ITaskService, quickOpenService: IQuickOpenService, task: Task, highlights: Model.IHighlight[] = []) { + super(taskService, quickOpenService, task, highlights); } public run(mode: QuickOpen.Mode, context: Model.IContext): boolean { if (mode === QuickOpen.Mode.PREVIEW) { return false; } - this.taskService.run(this._task); + let task = this._task; + this.taskService.run(task); + if (task.command.terminalBehavior.focus) { + this.quickOpenService.close(); + return false; + } return true; } } @@ -45,8 +50,8 @@ export class QuickOpenHandler extends base.QuickOpenHandler { return this.taskService.getTasksForGroup(TaskGroup.Build); } - protected createEntry(taskService: ITaskService, task: Task, highlights: Model.IHighlight[]): base.TaskEntry { - return new TaskEntry(taskService, task, highlights); + protected createEntry(task: Task, highlights: Model.IHighlight[]): base.TaskEntry { + return new TaskEntry(this.taskService, this.quickOpenService, task, highlights); } public getEmptyLabel(searchString: string): string { diff --git a/src/vs/workbench/parts/tasks/browser/quickOpen.ts b/src/vs/workbench/parts/tasks/browser/quickOpen.ts index 9368b61de9a..35b7a680080 100644 --- a/src/vs/workbench/parts/tasks/browser/quickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/quickOpen.ts @@ -21,7 +21,7 @@ import { ActionBarContributor, ContributableActionProvider } from 'vs/workbench/ export class TaskEntry extends Model.QuickOpenEntry { - constructor(protected taskService: ITaskService, protected _task: Task, highlights: Model.IHighlight[] = []) { + constructor(protected taskService: ITaskService, protected quickOpenService: IQuickOpenService, protected _task: Task, highlights: Model.IHighlight[] = []) { super(highlights); } @@ -75,7 +75,8 @@ export abstract class QuickOpenHandler extends Quickopen.QuickOpenHandler { } let recentlyUsedTasks = this.taskService.getRecentlyUsedTasks(); let recent: Task[] = []; - let others: Task[] = []; + let configured: Task[] = []; + let detected: Task[] = []; let taskMap: IStringDictionary = Object.create(null); tasks.forEach(task => taskMap[task.identifier] = task); recentlyUsedTasks.keys().forEach(key => { @@ -86,37 +87,43 @@ export abstract class QuickOpenHandler extends Quickopen.QuickOpenHandler { }); for (let task of tasks) { if (!recentlyUsedTasks.has(task.identifier)) { - others.push(task); - } - } - others = others.sort((a, b) => a._source.label.localeCompare(b._source.label)); - let sortedTasks = recent.concat(others); - let recentlyUsed: boolean = recentlyUsedTasks.has(tasks[0].identifier); - let otherTasks: boolean = !recentlyUsedTasks.has(tasks[tasks.length - 1].identifier); - let hasRecentlyUsed: boolean = false; - for (let task of sortedTasks) { - let highlights = Filters.matchesContiguousSubString(input, task._label); - if (!highlights) { - continue; - } - if (recentlyUsed) { - recentlyUsed = false; - hasRecentlyUsed = true; - entries.push(new TaskGroupEntry(this.createEntry(this.taskService, task, highlights), nls.localize('recentlyUsed', 'recently used'), false)); - } else if (!recentlyUsedTasks.has(task.identifier) && otherTasks) { - otherTasks = false; - entries.push(new TaskGroupEntry(this.createEntry(this.taskService, task, highlights), nls.localize('other tasks', 'other tasks'), hasRecentlyUsed)); - } else { - entries.push(this.createEntry(this.taskService, task, highlights)); + if (task._source.kind === TaskSourceKind.Workspace) { + configured.push(task); + } else { + detected.push(task); + } } } + let hasRecentlyUsed: boolean = recent.length > 0; + this.fillEntries(entries, input, recent, nls.localize('recentlyUsed', 'recently used tasks')); + configured = configured.sort((a, b) => a._label.localeCompare(b._label)); + let hasConfigured = configured.length > 0; + this.fillEntries(entries, input, configured, nls.localize('configured', 'configured tasks'), hasRecentlyUsed); + detected = detected.sort((a, b) => a._label.localeCompare(b._label)); + this.fillEntries(entries, input, detected, nls.localize('detected', 'detected tasks'), hasRecentlyUsed || hasConfigured); return new Model.QuickOpenModel(entries, new ContributableActionProvider()); }); } + private fillEntries(entries: Model.QuickOpenEntry[], input: string, tasks: Task[], groupLabel: string, withBorder: boolean = false) { + let first = true; + for (let task of tasks) { + let highlights = Filters.matchesContiguousSubString(input, task._label); + if (!highlights) { + continue; + } + if (first) { + first = false; + entries.push(new TaskGroupEntry(this.createEntry(task, highlights), groupLabel, withBorder)); + } else { + entries.push(this.createEntry(task, highlights)); + } + } + } + protected abstract getTasks(): TPromise; - protected abstract createEntry(taskService: ITaskService, task: Task, highlights: Model.IHighlight[]): TaskEntry; + protected abstract createEntry(task: Task, highlights: Model.IHighlight[]): TaskEntry; public getAutoFocus(input: string): QuickOpen.IAutoFocus { return { diff --git a/src/vs/workbench/parts/tasks/browser/restartQuickOpen.ts b/src/vs/workbench/parts/tasks/browser/restartQuickOpen.ts index 95d4d2bd5dd..eeda3971243 100644 --- a/src/vs/workbench/parts/tasks/browser/restartQuickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/restartQuickOpen.ts @@ -16,8 +16,8 @@ import { ITaskService } from 'vs/workbench/parts/tasks/common/taskService'; import * as base from './quickOpen'; class TaskEntry extends base.TaskEntry { - constructor(taskService: ITaskService, task: Task, highlights: Model.IHighlight[] = []) { - super(taskService, task, highlights); + constructor(taskService: ITaskService, quickOpenService: IQuickOpenService, task: Task, highlights: Model.IHighlight[] = []) { + super(taskService, quickOpenService, task, highlights); } public run(mode: QuickOpen.Mode, context: Model.IContext): boolean { @@ -45,8 +45,8 @@ export class QuickOpenHandler extends base.QuickOpenHandler { return this.taskService.getActiveTasks(); } - protected createEntry(taskService: ITaskService, task: Task, highlights: Model.IHighlight[]): base.TaskEntry { - return new TaskEntry(taskService, task, highlights); + protected createEntry(task: Task, highlights: Model.IHighlight[]): base.TaskEntry { + return new TaskEntry(this.taskService, this.quickOpenService, task, highlights); } public getEmptyLabel(searchString: string): string { diff --git a/src/vs/workbench/parts/tasks/browser/taskQuickOpen.ts b/src/vs/workbench/parts/tasks/browser/taskQuickOpen.ts index b6939d7a77c..544826907d4 100644 --- a/src/vs/workbench/parts/tasks/browser/taskQuickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/taskQuickOpen.ts @@ -18,15 +18,20 @@ import { IExtensionService } from 'vs/platform/extensions/common/extensions'; import * as base from './quickOpen'; class TaskEntry extends base.TaskEntry { - constructor(taskService: ITaskService, task: Task, highlights: Model.IHighlight[] = []) { - super(taskService, task, highlights); + constructor(taskService: ITaskService, quickOpenService: IQuickOpenService, task: Task, highlights: Model.IHighlight[] = []) { + super(taskService, quickOpenService, task, highlights); } public run(mode: QuickOpen.Mode, context: Model.IContext): boolean { if (mode === QuickOpen.Mode.PREVIEW) { return false; } - this.taskService.run(this._task); + let task = this._task; + this.taskService.run(task); + if (task.command.terminalBehavior.focus) { + this.quickOpenService.close(); + return false; + } return true; } } @@ -53,8 +58,8 @@ export class QuickOpenHandler extends base.QuickOpenHandler { }); } - protected createEntry(taskService: ITaskService, task: Task, highlights: Model.IHighlight[]): base.TaskEntry { - return new TaskEntry(taskService, task, highlights); + protected createEntry(task: Task, highlights: Model.IHighlight[]): base.TaskEntry { + return new TaskEntry(this.taskService, this.quickOpenService, task, highlights); } public getEmptyLabel(searchString: string): string { diff --git a/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.ts b/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.ts index 80fc424f5d0..5317d378900 100644 --- a/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.ts @@ -16,8 +16,8 @@ import { ITaskService } from 'vs/workbench/parts/tasks/common/taskService'; import * as base from './quickOpen'; class TaskEntry extends base.TaskEntry { - constructor(taskService: ITaskService, task: Task, highlights: Model.IHighlight[] = []) { - super(taskService, task, highlights); + constructor(taskService: ITaskService, quickOpenService: IQuickOpenService, task: Task, highlights: Model.IHighlight[] = []) { + super(taskService, quickOpenService, task, highlights); } public run(mode: QuickOpen.Mode, context: Model.IContext): boolean { @@ -45,8 +45,8 @@ export class QuickOpenHandler extends base.QuickOpenHandler { return this.taskService.getActiveTasks(); } - protected createEntry(taskService: ITaskService, task: Task, highlights: Model.IHighlight[]): base.TaskEntry { - return new TaskEntry(taskService, task, highlights); + protected createEntry(task: Task, highlights: Model.IHighlight[]): base.TaskEntry { + return new TaskEntry(this.taskService, this.quickOpenService, task, highlights); } public getEmptyLabel(searchString: string): string { diff --git a/src/vs/workbench/parts/tasks/browser/testQuickOpen.ts b/src/vs/workbench/parts/tasks/browser/testQuickOpen.ts index 96275341b2c..ff9b506b36e 100644 --- a/src/vs/workbench/parts/tasks/browser/testQuickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/testQuickOpen.ts @@ -16,15 +16,20 @@ import { ITaskService } from 'vs/workbench/parts/tasks/common/taskService'; import * as base from './quickOpen'; class TaskEntry extends base.TaskEntry { - constructor(taskService: ITaskService, task: Task, highlights: Model.IHighlight[] = []) { - super(taskService, task, highlights); + constructor(taskService: ITaskService, quickOpenService: IQuickOpenService, task: Task, highlights: Model.IHighlight[] = []) { + super(taskService, quickOpenService, task, highlights); } public run(mode: QuickOpen.Mode, context: Model.IContext): boolean { if (mode === QuickOpen.Mode.PREVIEW) { return false; } - this.taskService.run(this._task); + let task = this._task; + this.taskService.run(task); + if (task.command.terminalBehavior.focus) { + this.quickOpenService.close(); + return false; + } return true; } } @@ -45,8 +50,8 @@ export class QuickOpenHandler extends base.QuickOpenHandler { return this.taskService.getTasksForGroup(TaskGroup.Test); } - protected createEntry(taskService: ITaskService, task: Task, highlights: Model.IHighlight[]): base.TaskEntry { - return new TaskEntry(taskService, task, highlights); + protected createEntry(task: Task, highlights: Model.IHighlight[]): base.TaskEntry { + return new TaskEntry(this.taskService, this.quickOpenService, task, highlights); } public getEmptyLabel(searchString: string): string { diff --git a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts index 71be98158a3..9b07f84f16f 100644 --- a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts +++ b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts @@ -355,6 +355,134 @@ function fillProperty(target: T, source: T, key: K) { } +interface ParserType { + isEmpty(value: T): boolean; + assignProperties(target: T, source: T): T; + fillProperties(target: T, source: T): T; + fillDefaults(value: T, context: ParseContext): T; + freeze(value: T): Readonly; +} + +interface MetaData { + property: keyof T; + type?: ParserType; +} + + +function _isEmpty(this: void, value: T, properties: MetaData[]): boolean { + if (value === void 0 || value === null) { + return true; + } + for (let meta of properties) { + let property = value[meta.property]; + if (property !== void 0 && property !== null) { + if (meta.type !== void 0 && !meta.type.isEmpty(property)) { + return false; + } else if (!Array.isArray(property) || property.length > 0) { + return false; + } + } + } + return true; +} + +function _assignProperties(this: void, target: T, source: T, properties: MetaData[]): T { + if (_isEmpty(source, properties)) { + return target; + } + if (_isEmpty(target, properties)) { + return source; + } + for (let meta of properties) { + let property = meta.property; + let value: any; + if (meta.type !== void 0) { + value = meta.type.assignProperties(target[property], source[property]); + } else { + value = source[property]; + } + if (value !== void 0 && value !== null) { + target[property] = value; + } + } + return target; +} + +function _fillProperties(this: void, target: T, source: T, properties: MetaData[]): T { + if (_isEmpty(source, properties)) { + return target; + } + if (_isEmpty(target, properties)) { + return source; + } + for (let meta of properties) { + let property = meta.property; + if (target[property] !== void 0) { + continue; + } + let value: any; + if (meta.type) { + value = meta.type.fillProperties(target[property], source[property]); + } else { + value = source[property]; + } + + if (value !== void 0 && value !== null) { + target[property] = value; + } + } + return target; +} + +function _fillDefaults(this: void, target: T, defaults: T, properties: MetaData[], context: ParseContext): T { + if (target && Object.isFrozen(target)) { + return target; + } + if (target === void 0 || target === null) { + if (defaults !== void 0 && defaults !== null) { + return Objects.deepClone(defaults); + } else { + return undefined; + } + } + for (let meta of properties) { + let property = meta.property; + if (target[property] !== void 0) { + continue; + } + let value: any; + if (meta.type) { + value = meta.type.fillDefaults(target[property], context); + } else { + value = defaults[property]; + } + + if (value !== void 0 && value !== null) { + target[property] = value; + } + } + return target; +} + +function _freeze(this: void, target: T, properties: MetaData[]): Readonly { + if (target === void 0 || target === null) { + return undefined; + } + if (Object.isFrozen(target)) { + return target; + } + for (let meta of properties) { + if (meta.type) { + let value = target[meta.property]; + if (value) { + meta.type.freeze(value); + } + } + } + Object.freeze(target); + return target; +} + interface ParseContext { problemReporter: IProblemReporter; namedProblemMatchers: IStringDictionary; @@ -363,7 +491,11 @@ interface ParseContext { schemaVersion: Tasks.JsonSchemaVersion; } + namespace ShellConfiguration { + + const properties: MetaData[] = [{ property: 'executable' }, { property: 'args' }]; + export function is(value: any): value is ShellConfiguration { let candidate: ShellConfiguration = value; return candidate && Types.isString(candidate.executable) && (candidate.args === void 0 || Types.isStringArray(candidate.args)); @@ -380,46 +512,35 @@ namespace ShellConfiguration { return result; } - export function isEmpty(value: Tasks.ShellConfiguration): boolean { - return !value || value.executable === void 0 && (value.args === void 0 || value.args.length === 0); + export function isEmpty(this: void, value: Tasks.ShellConfiguration): boolean { + return _isEmpty(value, properties); } - export function assignProperties(target: Tasks.ShellConfiguration, source: Tasks.ShellConfiguration): Tasks.ShellConfiguration { - if (isEmpty(source)) { - return target; - } - if (isEmpty(target)) { - return source; - } - assignProperty(target, source, 'executable'); - assignProperty(target, source, 'args'); - return target; + export function assignProperties(this: void, target: Tasks.ShellConfiguration, source: Tasks.ShellConfiguration): Tasks.ShellConfiguration { + return _assignProperties(target, source, properties); } - export function fillProperties(target: Tasks.ShellConfiguration, source: Tasks.ShellConfiguration): Tasks.ShellConfiguration { - if (isEmpty(source)) { - return target; - } - if (isEmpty(target)) { - return source; - } - fillProperty(target, source, 'executable'); - fillProperty(target, source, 'args'); - return target; + export function fillProperties(this: void, target: Tasks.ShellConfiguration, source: Tasks.ShellConfiguration): Tasks.ShellConfiguration { + return _fillProperties(target, source, properties); } - export function fillDefaults(value: Tasks.ShellConfiguration): void { + export function fillDefaults(this: void, value: Tasks.ShellConfiguration, context: ParseContext): Tasks.ShellConfiguration { + return value; } - export function freeze(value: Tasks.ShellConfiguration): void { + export function freeze(this: void, value: Tasks.ShellConfiguration): Readonly { if (!value) { - return; + return undefined; } - Object.freeze(value); + return Object.freeze(value); } } namespace CommandOptions { + + const properties: MetaData[] = [{ property: 'cwd' }, { property: 'env' }, { property: 'shell', type: ShellConfiguration }]; + const defaults: CommandOptions = { cwd: '${workspaceRoot}' }; + export function from(this: void, options: CommandOptions, context: ParseContext): Tasks.CommandOptions { let result: Tasks.CommandOptions = {}; if (options.cwd !== void 0) { @@ -437,7 +558,7 @@ namespace CommandOptions { } export function isEmpty(value: Tasks.CommandOptions): boolean { - return !value || value.cwd === void 0 && value.env === void 0 && value.shell === void 0; + return _isEmpty(value, properties); } export function assignProperties(target: Tasks.CommandOptions, source: Tasks.CommandOptions): Tasks.CommandOptions { @@ -461,45 +582,25 @@ namespace CommandOptions { } export function fillProperties(target: Tasks.CommandOptions, source: Tasks.CommandOptions): Tasks.CommandOptions { - if (isEmpty(source)) { - return target; - } - if (isEmpty(target)) { - return source; - } - fillProperty(target, source, 'cwd'); - fillProperty(target, source, 'env'); - target.shell = ShellConfiguration.fillProperties(target.shell, source.shell); - return target; + return _fillProperties(target, source, properties); } - export function fillDefaults(value: Tasks.CommandOptions): Tasks.CommandOptions { - if (value && Object.isFrozen(value)) { - return value; - } - if (value === void 0) { - value = {}; - } - if (value.cwd === void 0) { - value.cwd = '${workspaceRoot}'; - } - ShellConfiguration.fillDefaults(value.shell); - return value; + export function fillDefaults(value: Tasks.CommandOptions, context: ParseContext): Tasks.CommandOptions { + return _fillDefaults(value, defaults, properties, context); } - export function freeze(value: Tasks.CommandOptions): void { - Object.freeze(value); - if (value.env) { - Object.freeze(value.env); - } - ShellConfiguration.freeze(value.shell); + export function freeze(value: Tasks.CommandOptions): Readonly { + return _freeze(value, properties); } } namespace CommandConfiguration { + interface TerminalBehavior { echo?: boolean; reveal?: string; + focus?: boolean; + instance?: string; } interface BaseCommandConfiguationShape { @@ -522,9 +623,13 @@ namespace CommandConfiguration { } export namespace TerminalBehavior { + const properties: MetaData[] = [{ property: 'echo' }, { property: 'reveal' }, { property: 'focus' }, { property: 'instance' }]; + export function from(this: void, config: BaseCommandConfiguationShape, context: ParseContext): Tasks.TerminalBehavior { - let echo: boolean = undefined; - let reveal: Tasks.RevealKind = undefined; + let echo: boolean; + let reveal: Tasks.RevealKind; + let focus: boolean; + let instance: Tasks.InstanceKind; if (Types.isBoolean(config.echoCommand)) { echo = config.echoCommand; } @@ -538,65 +643,47 @@ namespace CommandConfiguration { if (Types.isString(config.terminal.reveal)) { reveal = Tasks.RevealKind.fromString(config.terminal.reveal); } + if (Types.isBoolean(config.terminal.focus)) { + focus = config.terminal.focus; + } + if (Types.isString(config.terminal.instance)) { + instance = Tasks.InstanceKind.fromString(config.terminal.instance); + } } - if (echo === void 0 && reveal === void 0) { + if (echo === void 0 && reveal === void 0 && focus === void 0 && instance === void 0) { return undefined; } - return { echo, reveal }; + return { echo, reveal, focus, instance }; } export function assignProperties(target: Tasks.TerminalBehavior, source: Tasks.TerminalBehavior): Tasks.TerminalBehavior { - if (isEmpty(source)) { - return target; - } - if (isEmpty(target)) { - return source; - } - assignProperty(target, source, 'echo'); - assignProperty(target, source, 'reveal'); - return target; + return _assignProperties(target, source, properties); } export function fillProperties(target: Tasks.TerminalBehavior, source: Tasks.TerminalBehavior): Tasks.TerminalBehavior { - if (isEmpty(source)) { - return target; - } - if (isEmpty(target)) { - return source; - } - fillProperty(target, source, 'echo'); - fillProperty(target, source, 'reveal'); - return target; + return _fillProperties(target, source, properties); } - export function fillDefault(value: Tasks.TerminalBehavior, context: ParseContext): Tasks.TerminalBehavior { - if (value && Object.isFrozen(value)) { - return value; - } - if (value === void 0) { - return { echo: false, reveal: Tasks.RevealKind.Always }; - } - if (value.echo === void 0) { - value.echo = context.engine === Tasks.ExecutionEngine.Terminal ? true : false; - } - if (value.reveal === void 0) { - value.reveal = Tasks.RevealKind.Always; - } - return value; + export function fillDefaults(value: Tasks.TerminalBehavior, context: ParseContext): Tasks.TerminalBehavior { + let defaultEcho = context.engine === Tasks.ExecutionEngine.Terminal ? true : false; + return _fillDefaults(value, { echo: defaultEcho, reveal: Tasks.RevealKind.Always, focus: false, instance: Tasks.InstanceKind.Shared }, properties, context); } - export function freeze(value: Tasks.TerminalBehavior): void { - if (value === void 0) { - return; - } - Object.freeze(value); + export function freeze(value: Tasks.TerminalBehavior): Readonly { + return _freeze(value, properties); } export function isEmpty(this: void, value: Tasks.TerminalBehavior): boolean { - return !value || value.echo === void 0 && value.reveal === void 0; + return _isEmpty(value, properties); } } + const properties: MetaData[] = [ + { property: 'type' }, { property: 'name' }, { property: 'options', type: CommandOptions }, + { property: 'args' }, { property: 'taskSelector' }, { property: 'suppressTaskName' }, + { property: 'terminalBehavior', type: TerminalBehavior } + ]; + export function from(this: void, config: CommandConfiguationShape, context: ParseContext): Tasks.CommandConfiguration { let result: Tasks.CommandConfiguration = fromBase(config, context); @@ -662,13 +749,7 @@ namespace CommandConfiguration { } export function isEmpty(value: Tasks.CommandConfiguration): boolean { - return !value || value.name === void 0 - && value.type === void 0 - && value.args === void 0 - && value.taskSelector === void 0 - && value.suppressTaskName === void 0 - && CommandOptions.isEmpty(value.options) - && TerminalBehavior.isEmpty(value.terminalBehavior); + return _isEmpty(value, properties); } export function onlyTerminalBehaviour(value: Tasks.CommandConfiguration): boolean { @@ -739,9 +820,9 @@ namespace CommandConfiguration { if (value.name !== void 0 && value.type === void 0) { value.type = Tasks.CommandType.Process; } - value.terminalBehavior = TerminalBehavior.fillDefault(value.terminalBehavior, context); + value.terminalBehavior = TerminalBehavior.fillDefaults(value.terminalBehavior, context); if (!isEmpty(value)) { - value.options = CommandOptions.fillDefaults(value.options); + value.options = CommandOptions.fillDefaults(value.options, context); } if (value.args === void 0) { value.args = EMPTY_ARRAY; @@ -751,17 +832,8 @@ namespace CommandConfiguration { } } - export function freeze(value: Tasks.CommandConfiguration): void { - Object.freeze(value); - if (value.args) { - Object.freeze(value.args); - } - if (value.options) { - CommandOptions.freeze(value.options); - } - if (value.terminalBehavior) { - TerminalBehavior.freeze(value.terminalBehavior); - } + export function freeze(value: Tasks.CommandConfiguration): Readonly { + return _freeze(value, properties); } } diff --git a/src/vs/workbench/parts/tasks/common/taskSystem.ts b/src/vs/workbench/parts/tasks/common/taskSystem.ts index b61a8fbc863..30e51e8a2e3 100644 --- a/src/vs/workbench/parts/tasks/common/taskSystem.ts +++ b/src/vs/workbench/parts/tasks/common/taskSystem.ts @@ -100,7 +100,6 @@ export interface ITaskResolver { export interface ITaskSystem extends IEventEmitter { run(task: Task, resolver: ITaskResolver): ITaskExecuteResult; - show(task: Task, forceFocus?: boolean): void; isActive(): TPromise; isActiveSync(): boolean; getActiveTasks(): Task[]; diff --git a/src/vs/workbench/parts/tasks/common/tasks.ts b/src/vs/workbench/parts/tasks/common/tasks.ts index b75a5750e58..ca4b93f5422 100644 --- a/src/vs/workbench/parts/tasks/common/tasks.ts +++ b/src/vs/workbench/parts/tasks/common/tasks.ts @@ -80,6 +80,40 @@ export namespace RevealKind { } } +export enum InstanceKind { + + /** + * Shares a terminal with other tasks. This is the default. + */ + Shared = 1, + + /** + * Uses the same terminal for every run if possible. The terminal is not + * shared with other tasks. + */ + Same = 2, + + /** + * Creates a new terminal whenever that task is executed + */ + New = 3 +} + +export namespace InstanceKind { + export function fromString(value: string): InstanceKind { + switch (value.toLowerCase()) { + case 'shared': + return InstanceKind.Shared; + case 'same': + return InstanceKind.Same; + case 'new': + return InstanceKind.New; + default: + return InstanceKind.Shared; + } + } +} + export interface TerminalBehavior { /** * Controls whether the terminal executing a task is brought to front or not. @@ -91,6 +125,16 @@ export interface TerminalBehavior { * Controls whether the executed command is printed to the output window or terminal as well. */ echo: boolean; + + /** + * Controls whether the terminal is focus when this task is executed + */ + focus: boolean; + + /** + * Controls whether the task runs in a new terminal + */ + instance: InstanceKind; } export enum CommandType { diff --git a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts index a5a53dae147..305ccdd5a4c 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/task.contribution.ts @@ -444,9 +444,6 @@ class NullTaskSystem extends EventEmitter implements ITaskSystem { promise: TPromise.as({}) }; } - public show(task: Task, forceFocus: boolean = false): void { - return; - } public isActive(): TPromise { return TPromise.as(false); } @@ -930,20 +927,19 @@ class TaskService extends EventEmitter implements ITaskService { return ProblemMatcherRegistry.onReady().then(() => { return this.textFileService.saveAll().then((value) => { // make sure all dirty files are saved let executeResult = this.getTaskSystem().run(task, resolver); + this.getRecentlyUsedTasks().set(task.identifier, task.identifier, Touch.First); if (executeResult.kind === TaskExecuteKind.Active) { let active = executeResult.active; if (active.same) { if (active.background) { this.messageService.show(Severity.Info, nls.localize('TaskSystem.activeSame.background', 'The task is already active and in background mode. To terminate the task use `F1 > terminate task`')); } else { - this.getTaskSystem().show(task, true); - // this.messageService.show(Severity.Info, nls.localize('TaskSystem.activeSame.noBackground', 'The task is already active. To terminate the task use `F1 > terminate task`')); + this.messageService.show(Severity.Info, nls.localize('TaskSystem.activeSame.noBackground', 'The task is already active. To terminate the task use `F1 > terminate task`')); } } else { throw new TaskError(Severity.Warning, nls.localize('TaskSystem.active', 'There is already a task running. Terminate it first before executing another task.'), TaskErrors.RunningTask); } } - this.getRecentlyUsedTasks().set(task.identifier, task.identifier, Touch.First); return executeResult.promise; }); }); diff --git a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts index 3bdec71f2ec..8f43026ea21 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts @@ -135,8 +135,10 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { let terminalData = this.activeTasks[task._id]; if (terminalData && terminalData.promise) { let reveal = task.command.terminalBehavior.reveal; - if (reveal === RevealKind.Always) { - terminalData.terminal.setVisible(true); + let focus = task.command.terminalBehavior.focus; + if (reveal === RevealKind.Always || focus) { + this.terminalService.setActiveInstance(terminalData.terminal); + this.terminalService.showPanel(focus); } return { kind: TaskExecuteKind.Active, active: { same: true, background: task.isBackground }, promise: terminalData.promise }; } @@ -156,15 +158,6 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { } } - public show(task: Task, forceFocus: boolean = false): void { - let terminalData = this.activeTasks[task._id]; - if (terminalData === void 0) { - return; - } - this.terminalService.setActiveInstance(terminalData.terminal); - this.terminalService.showPanel(forceFocus); - } - public isActive(): TPromise { return TPromise.as(this.isActiveSync()); } @@ -342,7 +335,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { } this.terminalService.setActiveInstance(terminal); if (task.command.terminalBehavior.reveal === RevealKind.Always || (task.command.terminalBehavior.reveal === RevealKind.Silent && task.problemMatchers.length === 0)) { - this.terminalService.showPanel(false); + this.terminalService.showPanel(task.command.terminalBehavior.focus); } this.activeTasks[task._id] = { terminal, task, promise }; return promise.then((summary) => { @@ -432,7 +425,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { shellArgs.push(commandLine); shellLaunchConfig.args = Platform.isWindows ? shellArgs.join(' ') : shellArgs; if (task.command.terminalBehavior.echo) { - shellLaunchConfig.initialText = `\x1b[1m>Executing task: ${commandLine}<\x1b[0m\n`; + shellLaunchConfig.initialText = `\x1b[1m> Executing task: ${commandLine} <\x1b[0m\n`; } } else { let cwd = options && options.cwd ? options.cwd : process.cwd(); @@ -455,7 +448,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { } return args.join(' '); }; - shellLaunchConfig.initialText = `\x1b[1m>Executing task: ${shellLaunchConfig.executable} ${getArgsToEcho(shellLaunchConfig.args)}<\x1b[0m\n`; + shellLaunchConfig.initialText = `\x1b[1m> Executing task: ${shellLaunchConfig.executable} ${getArgsToEcho(shellLaunchConfig.args)} <\x1b[0m\n`; } } if (options.cwd) { diff --git a/src/vs/workbench/parts/tasks/node/processTaskSystem.ts b/src/vs/workbench/parts/tasks/node/processTaskSystem.ts index c6e4d70add9..0db8946a2d2 100644 --- a/src/vs/workbench/parts/tasks/node/processTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/node/processTaskSystem.ts @@ -89,10 +89,6 @@ export class ProcessTaskSystem extends EventEmitter implements ITaskSystem { return this.executeTask(task); } - public show(task: Task, forceFocus: boolean = false): void { - this.outputChannel.show(!focus); - } - public hasErrors(value: boolean): void { this.errorsShown = !value; } diff --git a/src/vs/workbench/parts/tasks/test/node/configuration.test.ts b/src/vs/workbench/parts/tasks/test/node/configuration.test.ts index a82a75b6e7c..2d60a06a146 100644 --- a/src/vs/workbench/parts/tasks/test/node/configuration.test.ts +++ b/src/vs/workbench/parts/tasks/test/node/configuration.test.ts @@ -82,7 +82,7 @@ class TerminalBehaviorBuilder { public result: Tasks.TerminalBehavior; constructor(public parent: CommandConfigurationBuilder) { - this.result = { echo: false, reveal: Tasks.RevealKind.Always }; + this.result = { echo: false, reveal: Tasks.RevealKind.Always, focus: false, instance: Tasks.InstanceKind.Shared }; } public echo(value: boolean): TerminalBehaviorBuilder { @@ -95,6 +95,16 @@ class TerminalBehaviorBuilder { return this; } + public focus(value: boolean): TerminalBehaviorBuilder { + this.result.focus = value; + return this; + } + + public instance(value: Tasks.InstanceKind): TerminalBehaviorBuilder { + this.result.instance = value; + return this; + } + public done(): void { } } @@ -1446,7 +1456,8 @@ suite('Tasks version 2.0.0', () => { builder.task('dir', 'dir'). group(Tasks.TaskGroup.Build). command().suppressTaskName(true). - type(Tasks.CommandType.Shell); + type(Tasks.CommandType.Shell). + terminal().echo(true); testConfiguration(external, builder); }); -- GitLab From 63dd1ec2c4a6998acf70b4b6b749633c13c819e7 Mon Sep 17 00:00:00 2001 From: Ishan Arora Date: Thu, 15 Jun 2017 18:34:48 +0530 Subject: [PATCH 0885/1347] fixes #22593 --- src/vs/platform/environment/node/environmentService.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/vs/platform/environment/node/environmentService.ts b/src/vs/platform/environment/node/environmentService.ts index 34a82d9d571..2a93543b82f 100644 --- a/src/vs/platform/environment/node/environmentService.ts +++ b/src/vs/platform/environment/node/environmentService.ts @@ -30,6 +30,9 @@ function getUniqueUserId(): string { } function getNixIPCHandle(userDataPath: string, type: string): string { + if (process.env['XDG_RUNTIME_DIR']) { + return path.join(process.env['XDG_RUNTIME_DIR'], `${pkg.name}-${pkg.version}-${type}.sock`); + } return path.join(userDataPath, `${pkg.version}-${type}.sock`); } -- GitLab From ea25ce0583fe6c4c4c66f30e05527c8f09222445 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 15 Jun 2017 16:23:07 +0200 Subject: [PATCH 0886/1347] multi root - implement isInsideWorkspace properly --- .../browser/standalone/simpleServices.ts | 34 +++++++++---------- .../browser/standalone/standaloneServices.ts | 7 ++-- src/vs/platform/workspace/common/workspace.ts | 16 ++++----- src/vs/workbench/electron-browser/main.ts | 2 +- .../configuration/node/configuration.ts | 18 +++++----- 5 files changed, 36 insertions(+), 41 deletions(-) diff --git a/src/vs/editor/browser/standalone/simpleServices.ts b/src/vs/editor/browser/standalone/simpleServices.ts index da2acd51c1f..92970b62b40 100644 --- a/src/vs/editor/browser/standalone/simpleServices.ts +++ b/src/vs/editor/browser/standalone/simpleServices.ts @@ -17,7 +17,7 @@ import { KeybindingResolver } from 'vs/platform/keybinding/common/keybindingReso import { IKeybindingEvent, KeybindingSource, IKeyboardEvent } from 'vs/platform/keybinding/common/keybinding'; import { ContextKeyExpr, IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; import { IConfirmation, IMessageService } from 'vs/platform/message/common/message'; -import { IWorkspaceContextService, Workspace, IWorkspace, IWorkspace2 } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService, IWorkspace as ILegacyWorkspace, IWorkspace2 } from 'vs/platform/workspace/common/workspace'; import * as editorCommon from 'vs/editor/common/editorCommon'; import { ICodeEditor, IDiffEditor } from 'vs/editor/browser/editorBrowser'; import { Selection } from 'vs/editor/common/core/selection'; @@ -497,46 +497,44 @@ export class SimpleWorkspaceContextService implements IWorkspaceContextService { public _serviceBrand: any; + private static SCHEME: 'inmemory'; + private readonly _onDidChangeWorkspaceRoots: Emitter = new Emitter(); public readonly onDidChangeWorkspaceRoots: Event = this._onDidChangeWorkspaceRoots.event; - private readonly folders: URI[]; - private readonly id: string; - - constructor(private workspace?: Workspace) { - this.folders = workspace ? [workspace.resource] : []; - this.id = generateUuid(); - } + private readonly legacyWorkspace: ILegacyWorkspace; + private readonly workspace: IWorkspace2; - public getFolders(): URI[] { - return this.folders; + constructor() { + this.legacyWorkspace = { resource: URI.from({ scheme: SimpleWorkspaceContextService.SCHEME, authority: 'model', path: '/' }), ctime: Date.now() }; + this.workspace = { id: generateUuid(), roots: [this.legacyWorkspace.resource], name: this.legacyWorkspace.resource.fsPath }; } - public getWorkspace(): IWorkspace { - return this.workspace; + public getWorkspace(): ILegacyWorkspace { + return this.legacyWorkspace; } public getWorkspace2(): IWorkspace2 { - return this.workspace ? { id: `${this.id}`, roots: [this.workspace.resource], name: this.workspace.resource.fsPath } : void 0; + return this.workspace; } public getRoot(resource: URI): URI { - return this.isInsideWorkspace(resource) ? this.workspace.resource : null; + return resource && resource.scheme === SimpleWorkspaceContextService.SCHEME ? this.workspace.roots[0] : void 0; } public hasWorkspace(): boolean { - return !!this.workspace; + return true; } public isInsideWorkspace(resource: URI): boolean { - return this.workspace ? this.workspace.isInsideWorkspace(resource) : false; + return resource && resource.scheme === SimpleWorkspaceContextService.SCHEME; } public toWorkspaceRelativePath(resource: URI, toOSPath?: boolean): string { - return this.workspace ? this.workspace.toWorkspaceRelativePath(resource, toOSPath) : null; + return resource.fsPath; } public toResource(workspaceRelativePath: string): URI { - return this.workspace ? this.workspace.toResource(workspaceRelativePath) : null; + return URI.file(workspaceRelativePath); } } diff --git a/src/vs/editor/browser/standalone/standaloneServices.ts b/src/vs/editor/browser/standalone/standaloneServices.ts index 0a50de37e9e..212273a8e6c 100644 --- a/src/vs/editor/browser/standalone/standaloneServices.ts +++ b/src/vs/editor/browser/standalone/standaloneServices.ts @@ -5,7 +5,6 @@ 'use strict'; import { Disposable } from 'vs/base/common/lifecycle'; -import URI from 'vs/base/common/uri'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { ContextMenuService } from 'vs/platform/contextview/browser/contextMenuService'; import { IContextMenuService, IContextViewService } from 'vs/platform/contextview/browser/contextView'; @@ -22,7 +21,7 @@ import { IMessageService } from 'vs/platform/message/common/message'; import { IProgressService } from 'vs/platform/progress/common/progress'; import { IStorageService, NullStorageService } from 'vs/platform/storage/common/storage'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; -import { IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { ICodeEditorService } from 'vs/editor/common/services/codeEditorService'; import { IEditorWorkerService } from 'vs/editor/common/services/editorWorkerService'; import { EditorWorkerServiceImpl } from 'vs/editor/common/services/editorWorkerServiceImpl'; @@ -118,9 +117,7 @@ export module StaticServices { const configurationServiceImpl = new SimpleConfigurationService(); export const configurationService = define(IConfigurationService, () => configurationServiceImpl); - export const contextService = define(IWorkspaceContextService, () => new SimpleWorkspaceContextService(new Workspace( - URI.from({ scheme: 'inmemory', authority: 'model', path: '/' }) - ))); + export const contextService = define(IWorkspaceContextService, () => new SimpleWorkspaceContextService()); export const telemetryService = define(ITelemetryService, () => new StandaloneTelemetryService()); diff --git a/src/vs/platform/workspace/common/workspace.ts b/src/vs/platform/workspace/common/workspace.ts index e5670d0fa6c..d6bfd45a243 100644 --- a/src/vs/platform/workspace/common/workspace.ts +++ b/src/vs/platform/workspace/common/workspace.ts @@ -118,20 +118,20 @@ export class Workspace implements IWorkspace { return this._ctime; } - public isInsideWorkspace(resource: URI): boolean { - if (resource) { - return isEqualOrParent(resource.fsPath, this._resource.fsPath, !isLinux /* ignorecase */); + public toWorkspaceRelativePath(resource: URI, toOSPath?: boolean): string { + if (this.contains(resource)) { + return paths.normalize(paths.relative(this._resource.fsPath, resource.fsPath), toOSPath); } - return false; + return null; } - public toWorkspaceRelativePath(resource: URI, toOSPath?: boolean): string { - if (this.isInsideWorkspace(resource)) { - return paths.normalize(paths.relative(this._resource.fsPath, resource.fsPath), toOSPath); + private contains(resource: URI): boolean { + if (resource) { + return isEqualOrParent(resource.fsPath, this._resource.fsPath, !isLinux /* ignorecase */); } - return null; + return false; } public toResource(workspaceRelativePath: string, root?: URI): URI { diff --git a/src/vs/workbench/electron-browser/main.ts b/src/vs/workbench/electron-browser/main.ts index c01173bccc2..c447bf78692 100644 --- a/src/vs/workbench/electron-browser/main.ts +++ b/src/vs/workbench/electron-browser/main.ts @@ -98,7 +98,7 @@ function openWorkbench(configuration: IWindowConfiguration, options: IOptions): return resolveLegacyWorkspace(configuration).then(legacyWorkspace => { const environmentService = new EnvironmentService(configuration, configuration.execPath); const workspaceConfigurationService = new WorkspaceConfigurationService(environmentService, legacyWorkspace); - const timerService = new TimerService((window).MonacoEnvironment.timers as IInitData, !workspaceConfigurationService.hasWorkspace()); + const timerService = new TimerService((window).MonacoEnvironment.timers as IInitData, !!legacyWorkspace); const storageService = createStorageService(legacyWorkspace, configuration, environmentService); // Since the configuration service is one of the core services that is used in so many places, we initialize it diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index 8e7eee19fe9..5478bcbe539 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -182,7 +182,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } public isInsideWorkspace(resource: URI): boolean { - return this.workspace ? this.legacyWorkspace.isInsideWorkspace(resource) : false; + return !!this.getRoot(resource); } public toWorkspaceRelativePath(resource: URI, toOSPath?: boolean): string { @@ -468,20 +468,20 @@ class FolderConfiguration extends Disposable { return null; } - private isInsideWorkspace(resource: URI): boolean { - if (resource) { - return isEqualOrParent(resource.fsPath, this.folder.fsPath, !isLinux /* ignorecase */); + private toWorkspaceRelativePath(resource: URI, toOSPath?: boolean): string { + if (this.contains(resource)) { + return paths.normalize(paths.relative(this.folder.fsPath, resource.fsPath), toOSPath); } - return false; + return null; } - private toWorkspaceRelativePath(resource: URI, toOSPath?: boolean): string { - if (this.isInsideWorkspace(resource)) { - return paths.normalize(paths.relative(this.folder.fsPath, resource.fsPath), toOSPath); + private contains(resource: URI): boolean { + if (resource) { + return isEqualOrParent(resource.fsPath, this.folder.fsPath, !isLinux /* ignorecase */); } - return null; + return false; } } -- GitLab From 7563843dfec8c6ed14dc9832d351f674f2549c68 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Thu, 15 Jun 2017 16:36:21 +0200 Subject: [PATCH 0887/1347] show Developer Tools action in case of ext host crash --- .../electron-browser/extensionHost.ts | 33 +++++++++++++------ 1 file changed, 23 insertions(+), 10 deletions(-) diff --git a/src/vs/workbench/electron-browser/extensionHost.ts b/src/vs/workbench/electron-browser/extensionHost.ts index 7cccc708393..0e29ffee236 100644 --- a/src/vs/workbench/electron-browser/extensionHost.ts +++ b/src/vs/workbench/electron-browser/extensionHost.ts @@ -11,11 +11,12 @@ import { stringify } from 'vs/base/common/marshalling'; import * as objects from 'vs/base/common/objects'; import URI from 'vs/base/common/uri'; import { TPromise } from 'vs/base/common/winjs.base'; +import { Action } from 'vs/base/common/actions'; import { isWindows } from 'vs/base/common/platform'; import { findFreePort } from 'vs/base/node/ports'; import { IMessageService, Severity } from 'vs/platform/message/common/message'; import { ILifecycleService, ShutdownEvent } from 'vs/platform/lifecycle/common/lifecycle'; -import { IWindowsService } from 'vs/platform/windows/common/windows'; +import { IWindowsService, IWindowService } from 'vs/platform/windows/common/windows'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { IWindowIPCService } from 'vs/workbench/services/window/electron-browser/windowService'; @@ -89,7 +90,8 @@ export class ExtensionHostProcessWorker { @IWorkspaceContextService private contextService: IWorkspaceContextService, @IMessageService private messageService: IMessageService, @IWindowsService private windowsService: IWindowsService, - @IWindowIPCService private windowService: IWindowIPCService, + @IWindowService private windowService: IWindowService, + @IWindowIPCService private windowIpcService: IWindowIPCService, @ILifecycleService lifecycleService: ILifecycleService, @IInstantiationService private instantiationService: IInstantiationService, @IEnvironmentService private environmentService: IEnvironmentService, @@ -120,7 +122,7 @@ export class ExtensionHostProcessWorker { AMD_ENTRYPOINT: 'vs/workbench/node/extensionHostProcess', PIPE_LOGGING: 'true', VERBOSE_LOGGING: true, - VSCODE_WINDOW_ID: String(this.windowService.getWindowId()), + VSCODE_WINDOW_ID: String(this.windowIpcService.getWindowId()), VSCODE_IPC_HOOK_EXTHOST: hook, ELECTRON_NO_ASAR: '1' }), @@ -143,8 +145,8 @@ export class ExtensionHostProcessWorker { // Run Extension Host as fork of current process this.extensionHostProcess = fork(URI.parse(require.toUrl('bootstrap')).fsPath, ['--type=extensionHost'], opts); + // Catch all output coming from the extension host process type Output = { data: string, format: string[] }; - this.extensionHostProcess.stdout.setEncoding('utf8'); this.extensionHostProcess.stderr.setEncoding('utf8'); const onStdout = fromEventEmitter(this.extensionHostProcess.stdout, 'data'); @@ -154,12 +156,14 @@ export class ExtensionHostProcessWorker { mapEvent(onStderr, o => ({ data: `%c${o}`, format: ['color: red'] })) ); + // Debounce all output, so we can render it in the Chrome console as a group const onDebouncedOutput = debounceEvent(onOutput, (r, o) => { return r ? { data: r.data + o.data, format: [...r.format, ...o.format] } : { data: o.data, format: o.format }; - }, 300); + }, 100); + // Print out extension host output onDebouncedOutput(data => { console.group('Extension Host'); console.log(data.data, ...data.format); @@ -181,7 +185,7 @@ export class ExtensionHostProcessWorker { // Notify debugger that we are ready to attach to the process if we run a development extension if (this.isExtensionDevelopmentHost && port) { - this.windowService.broadcast({ + this.windowIpcService.broadcast({ channel: EXTENSION_ATTACH_BROADCAST_CHANNEL, payload: { port } }, this.environmentService.extensionDevelopmentPath /* target */); @@ -323,7 +327,7 @@ export class ExtensionHostProcessWorker { // Broadcast to other windows if we are in development mode else if (!this.environmentService.isBuilt || this.isExtensionDevelopmentHost) { - this.windowService.broadcast({ + this.windowIpcService.broadcast({ channel: EXTENSION_LOG_BROADCAST_CHANNEL, payload: logEntry }, this.environmentService.extensionDevelopmentPath /* target */); @@ -348,16 +352,25 @@ export class ExtensionHostProcessWorker { // Unexpected termination if (!this.isExtensionDevelopmentHost) { + const openDevTools = new Action('openDevTools', nls.localize('devTools', "Developer Tools"), '', true, async (): TPromise => { + await this.windowService.openDevTools(); + return false; + }); + this.messageService.show(Severity.Error, { message: nls.localize('extensionHostProcess.crash', "Extension host terminated unexpectedly. Please reload the window to recover."), - actions: [this.instantiationService.createInstance(ReloadWindowAction, ReloadWindowAction.ID, ReloadWindowAction.LABEL)] + actions: [ + openDevTools, + this.instantiationService.createInstance(ReloadWindowAction, ReloadWindowAction.ID, ReloadWindowAction.LABEL) + ] }); + console.error('Extension host terminated unexpectedly. Code: ', code, ' Signal: ', signal); } // Expected development extension termination: When the extension host goes down we also shutdown the window else if (!this.isExtensionDevelopmentTestFromCli) { - this.windowService.getWindow().close(); + this.windowIpcService.getWindow().close(); } // When CLI testing make sure to exit with proper exit code @@ -381,7 +394,7 @@ export class ExtensionHostProcessWorker { // If the extension development host was started without debugger attached we need // to communicate this back to the main side to terminate the debug session if (this.isExtensionDevelopmentHost && !this.isExtensionDevelopmentTestFromCli && !this.isExtensionDevelopmentDebug) { - this.windowService.broadcast({ + this.windowIpcService.broadcast({ channel: EXTENSION_TERMINATE_BROADCAST_CHANNEL, payload: true }, this.environmentService.extensionDevelopmentPath /* target */); -- GitLab From e57d3958c483b055dacb018088275df9e0c241a5 Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Thu, 15 Jun 2017 16:46:24 +0200 Subject: [PATCH 0888/1347] Corrected spelling mistakes. --- .../lib/tslint/noUnexternalizedStringsRule.js | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/build/lib/tslint/noUnexternalizedStringsRule.js b/build/lib/tslint/noUnexternalizedStringsRule.js index db189931465..d6edfc0570a 100644 --- a/build/lib/tslint/noUnexternalizedStringsRule.js +++ b/build/lib/tslint/noUnexternalizedStringsRule.js @@ -70,10 +70,10 @@ var NoUnexternalizedStringsRuleWalker = (function (_super) { var _this = this; _super.prototype.visitSourceFile.call(this, node); Object.keys(this.usedKeys).forEach(function (key) { - var occurences = _this.usedKeys[key]; - if (occurences.length > 1) { - occurences.forEach(function (occurence) { - _this.addFailure((_this.createFailure(occurence.key.getStart(), occurence.key.getWidth(), "Duplicate key " + occurence.key.getText() + " with different message value."))); + var occurrences = _this.usedKeys[key]; + if (occurrences.length > 1) { + occurrences.forEach(function (occurrence) { + _this.addFailure((_this.createFailure(occurrence.key.getStart(), occurrence.key.getWidth(), "Duplicate key " + occurrence.key.getText() + " with different message value."))); }); } }); @@ -140,17 +140,17 @@ var NoUnexternalizedStringsRuleWalker = (function (_super) { }; NoUnexternalizedStringsRuleWalker.prototype.recordKey = function (keyNode, messageNode) { var text = keyNode.getText(); - var occurences = this.usedKeys[text]; - if (!occurences) { - occurences = []; - this.usedKeys[text] = occurences; + var occurrences = this.usedKeys[text]; + if (!occurrences) { + occurrences = []; + this.usedKeys[text] = occurrences; } if (messageNode) { - if (occurences.some(function (pair) { return pair.message ? pair.message.getText() === messageNode.getText() : false; })) { + if (occurrences.some(function (pair) { return pair.message ? pair.message.getText() === messageNode.getText() : false; })) { return; } } - occurences.push({ key: keyNode, message: messageNode }); + occurrences.push({ key: keyNode, message: messageNode }); }; NoUnexternalizedStringsRuleWalker.prototype.findDescribingParent = function (node) { var parent; -- GitLab From e4601b2af0fa0efd4937329e492b01bc5607686a Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Thu, 15 Jun 2017 16:47:27 +0200 Subject: [PATCH 0889/1347] Simplified element waiting code. --- test/smoke/src/spectron/application.ts | 43 ++++++++++---------------- 1 file changed, 16 insertions(+), 27 deletions(-) diff --git a/test/smoke/src/spectron/application.ts b/test/smoke/src/spectron/application.ts index 03cc56070d4..73e555ffb96 100644 --- a/test/smoke/src/spectron/application.ts +++ b/test/smoke/src/spectron/application.ts @@ -82,7 +82,7 @@ export class SpectronApplication { } public waitFor(func: (...args: any[]) => any, args: any): Promise { - return this.callClientAPI(func, args, 0); + return this.callClientAPI(func, args); } public wait(): Promise { @@ -110,39 +110,28 @@ export class SpectronApplication { }); } - private callClientAPI(func: (...args: any[]) => Promise, args: any, trial: number): Promise { - if (trial > this.pollTrials) { - return Promise.reject(`Could not retrieve the element in ${this.testRetry * this.pollTrials * this.pollTimeout} seconds.`); - } - + private callClientAPI(func: (...args: any[]) => Promise, args: any): Promise { + let trial = 1; return new Promise(async (res, rej) => { - let resolved = false, capture = false; + while (true) { + if (trial > this.pollTrials) { + rej(`Could not retrieve the element in ${this.testRetry * this.pollTrials * this.pollTimeout} seconds.`); + break; + } - const tryCall = async (resolve: any, reject: any): Promise => { - await this.wait(); + let result; try { - const result = await this.callClientAPI(func, args, ++trial); - res(result); - } catch (error) { - rej(error); - } - } + result = await func.call(this.client, args); + } catch (e) {} - try { - const result = await func.call(this.client, args, capture); - if (!resolved && result === '') { - resolved = true; - await tryCall(res, rej); - } else if (!resolved) { - resolved = true; + if (result && result !== '') { await this.screenshot.capture(); res(result); + break; } - } catch (e) { - if (!resolved) { - resolved = true; - await tryCall(res, rej); - } + + this.wait(); + trial++; } }); } -- GitLab From 8f9e27396cb01c82151225758e41201f3751e3dd Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Thu, 15 Jun 2017 16:49:15 +0200 Subject: [PATCH 0890/1347] Removed exposure of require as it led to not working Spectron. --- src/vs/workbench/electron-browser/bootstrap/index.js | 4 ---- test/smoke/src/main.js | 1 - test/smoke/src/spectron/application.ts | 3 +-- 3 files changed, 1 insertion(+), 7 deletions(-) diff --git a/src/vs/workbench/electron-browser/bootstrap/index.js b/src/vs/workbench/electron-browser/bootstrap/index.js index a094c0daba5..c01da62847a 100644 --- a/src/vs/workbench/electron-browser/bootstrap/index.js +++ b/src/vs/workbench/electron-browser/bootstrap/index.js @@ -12,10 +12,6 @@ if (window.location.search.indexOf('prof-startup') >= 0) { profiler.startProfiling('renderer', true); } -if (process.env.SMOKE_TEST) { - window.electronRequire = require; // if smoke test, expose require to Spectron to access the core Electron APIs -} - /*global window,document,define*/ const startTimer = require('../../../base/node/startupTimers').startTimer; diff --git a/test/smoke/src/main.js b/test/smoke/src/main.js index d9136eed600..acf9db502d2 100644 --- a/test/smoke/src/main.js +++ b/test/smoke/src/main.js @@ -42,7 +42,6 @@ if (parseInt(process.version.substr(1)) < 6) { } // Setting up environment variables -process.env.SMOKE_TEST = 'true'; process.env.VSCODE_LATEST_PATH = program.latest; if (program.stable) process.env.VSCODE_STABLE_PATH = program.stable; process.env.SMOKETEST_REPO = testRepoLocalDir; diff --git a/test/smoke/src/spectron/application.ts b/test/smoke/src/spectron/application.ts index 73e555ffb96..8ccdc2f782c 100644 --- a/test/smoke/src/spectron/application.ts +++ b/test/smoke/src/spectron/application.ts @@ -52,8 +52,7 @@ export class SpectronApplication { this.spectron = new Application({ path: electronPath, args: args, - chromeDriverArgs: chromeDriverArgs, - requireName: 'electronRequire' + chromeDriverArgs: chromeDriverArgs }); this.screenshot = new Screenshot(this, testName); this.client = new SpectronClient(this.spectron, this.screenshot); -- GitLab From 43cedf1f6d864a6ba208f6806f28f2838fc70dff Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 15 Jun 2017 16:48:16 +0200 Subject: [PATCH 0891/1347] :lipstick: --- .../api/node/extHostExtensionService.ts | 1 - .../configuration/node/configuration.ts | 20 +++++++++---------- 2 files changed, 10 insertions(+), 11 deletions(-) diff --git a/src/vs/workbench/api/node/extHostExtensionService.ts b/src/vs/workbench/api/node/extHostExtensionService.ts index ff5a189ebb7..d75347f83dc 100644 --- a/src/vs/workbench/api/node/extHostExtensionService.ts +++ b/src/vs/workbench/api/node/extHostExtensionService.ts @@ -128,7 +128,6 @@ class ExtensionStoragePath { if (!this._workspace) { return TPromise.as(undefined); } - // TODO@joh what to do with multiple roots? const storageName = this._workspace.id; const storagePath = join(this._environment.appSettingsHome, 'workspaceStorage', storageName); diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index 5478bcbe539..c1617034e62 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -367,11 +367,11 @@ class FolderConfiguration extends Disposable { return false; // only JSON files } - return this.isWorkspaceConfigurationFile(this.toWorkspaceRelativePath(stat.resource)); // only workspace config files + return this.isWorkspaceConfigurationFile(this.toFolderRelativePath(stat.resource)); // only workspace config files }).map(stat => stat.resource)); }, err => [] /* never fail this call */) .then((contents: IContent[]) => { - contents.forEach(content => this.workspaceFilePathToConfiguration[this.toWorkspaceRelativePath(content.resource)] = TPromise.as(this.createConfigModel(content))); + contents.forEach(content => this.workspaceFilePathToConfiguration[this.toFolderRelativePath(content.resource)] = TPromise.as(this.createConfigModel(content))); }, errors.onUnexpectedError); } @@ -397,7 +397,7 @@ class FolderConfiguration extends Disposable { continue; // only JSON files or the actual settings folder } - const workspacePath = this.toWorkspaceRelativePath(resource); + const workspacePath = this.toFolderRelativePath(resource); if (!workspacePath) { continue; // event is not inside workspace } @@ -443,7 +443,7 @@ class FolderConfiguration extends Disposable { } private createConfigModel(content: IContent): ConfigurationModel { - const path = this.toWorkspaceRelativePath(content.resource); + const path = this.toFolderRelativePath(content.resource); if (path === WORKSPACE_CONFIG_DEFAULT_PATH) { return new FolderSettingsModel(content.value, content.resource.toString()); } else { @@ -456,19 +456,19 @@ class FolderConfiguration extends Disposable { return new CustomConfigurationModel(null); } - private isWorkspaceConfigurationFile(workspaceRelativePath: string): boolean { - return [WORKSPACE_CONFIG_DEFAULT_PATH, WORKSPACE_STANDALONE_CONFIGURATIONS.launch, WORKSPACE_STANDALONE_CONFIGURATIONS.tasks].some(p => p === workspaceRelativePath); + private isWorkspaceConfigurationFile(folderRelativePath: string): boolean { + return [WORKSPACE_CONFIG_DEFAULT_PATH, WORKSPACE_STANDALONE_CONFIGURATIONS.launch, WORKSPACE_STANDALONE_CONFIGURATIONS.tasks].some(p => p === folderRelativePath); } - private toResource(workspaceRelativePath: string): URI { - if (typeof workspaceRelativePath === 'string') { - return URI.file(paths.join(this.folder.fsPath, workspaceRelativePath)); + private toResource(folderRelativePath: string): URI { + if (typeof folderRelativePath === 'string') { + return URI.file(paths.join(this.folder.fsPath, folderRelativePath)); } return null; } - private toWorkspaceRelativePath(resource: URI, toOSPath?: boolean): string { + private toFolderRelativePath(resource: URI, toOSPath?: boolean): string { if (this.contains(resource)) { return paths.normalize(paths.relative(this.folder.fsPath, resource.fsPath), toOSPath); } -- GitLab From 0398ed29003d0fdff39b90347022d389ceaded3a Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Thu, 15 Jun 2017 17:00:01 +0200 Subject: [PATCH 0892/1347] increase timeout of search integration tests (for #28794) --- .../test/node/textSearch.integrationTest.ts | 28 +++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/src/vs/workbench/services/search/test/node/textSearch.integrationTest.ts b/src/vs/workbench/services/search/test/node/textSearch.integrationTest.ts index c5946648d15..896b6c3cb41 100644 --- a/src/vs/workbench/services/search/test/node/textSearch.integrationTest.ts +++ b/src/vs/workbench/services/search/test/node/textSearch.integrationTest.ts @@ -85,6 +85,8 @@ function doSearchTest(config: IRawSearch, expectedResultCount: number, done) { suite('Search-integration', () => { test('Text: GameOfLife', function (done: () => void) { + this.timeout(1000 * 60); // increase timeout for this one test + let config = { rootFolders: rootfolders(), filePattern: '*.js', @@ -95,6 +97,8 @@ suite('Search-integration', () => { }); test('Text: GameOfLife (RegExp)', function (done: () => void) { + this.timeout(1000 * 60); // increase timeout for this one test + let config = { rootFolders: rootfolders(), filePattern: '*.js', @@ -105,6 +109,8 @@ suite('Search-integration', () => { }); test('Text: GameOfLife (RegExp to EOL)', function (done: () => void) { + this.timeout(1000 * 60); // increase timeout for this one test + let config = { rootFolders: rootfolders(), filePattern: '*.js', @@ -115,6 +121,8 @@ suite('Search-integration', () => { }); test('Text: GameOfLife (Word Match, Case Sensitive)', function (done: () => void) { + this.timeout(1000 * 60); // increase timeout for this one test + let config = { rootFolders: rootfolders(), filePattern: '*.js', @@ -125,6 +133,8 @@ suite('Search-integration', () => { }); test('Text: GameOfLife (Word Match, Spaces)', function (done: () => void) { + this.timeout(1000 * 60); // increase timeout for this one test + let config = { rootFolders: rootfolders(), filePattern: '*.js', @@ -135,6 +145,8 @@ suite('Search-integration', () => { }); test('Text: GameOfLife (Word Match, Punctuation and Spaces)', function (done: () => void) { + this.timeout(1000 * 60); // increase timeout for this one test + let config = { rootFolders: rootfolders(), filePattern: '*.js', @@ -145,6 +157,8 @@ suite('Search-integration', () => { }); test('Text: Helvetica (UTF 16)', function (done: () => void) { + this.timeout(1000 * 60); // increase timeout for this one test + let config = { rootFolders: rootfolders(), filePattern: '*.css', @@ -155,6 +169,8 @@ suite('Search-integration', () => { }); test('Text: e', function (done: () => void) { + this.timeout(1000 * 60); // increase timeout for this one test + let config = { rootFolders: rootfolders(), filePattern: '*.*', @@ -165,6 +181,8 @@ suite('Search-integration', () => { }); test('Text: e (with excludes)', function (done: () => void) { + this.timeout(1000 * 60); // increase timeout for this one test + let config: any = { rootFolders: rootfolders(), filePattern: '*.*', @@ -176,6 +194,8 @@ suite('Search-integration', () => { }); test('Text: e (with includes)', function (done: () => void) { + this.timeout(1000 * 60); // increase timeout for this one test + let config: any = { rootFolders: rootfolders(), filePattern: '*.*', @@ -187,6 +207,8 @@ suite('Search-integration', () => { }); test('Text: e (with includes and exclude)', function (done: () => void) { + this.timeout(1000 * 60); // increase timeout for this one test + let config: any = { rootFolders: rootfolders(), filePattern: '*.*', @@ -199,6 +221,8 @@ suite('Search-integration', () => { }); test('Text: a (capped)', function (done: () => void) { + this.timeout(1000 * 60); // increase timeout for this one test + const maxResults = 520; let config = { rootFolders: rootfolders(), @@ -215,6 +239,8 @@ suite('Search-integration', () => { }); test('Text: a (no results)', function (done: () => void) { + this.timeout(1000 * 60); // increase timeout for this one test + let config = { rootFolders: rootfolders(), filePattern: '*.*', @@ -225,6 +251,8 @@ suite('Search-integration', () => { }); test('Text: -size', function (done: () => void) { + this.timeout(1000 * 60); // increase timeout for this one test + let config = { rootFolders: rootfolders(), filePattern: '*.css', -- GitLab From 63b4da631e796af65c6c66a3bbe2a0f06615a126 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 15 Jun 2017 17:03:18 +0200 Subject: [PATCH 0893/1347] :lipstick: #28526 --- src/vs/workbench/api/node/extHostWorkspace.ts | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/api/node/extHostWorkspace.ts b/src/vs/workbench/api/node/extHostWorkspace.ts index dff559112b7..e222fb03816 100644 --- a/src/vs/workbench/api/node/extHostWorkspace.ts +++ b/src/vs/workbench/api/node/extHostWorkspace.ts @@ -5,6 +5,7 @@ 'use strict'; import URI from 'vs/base/common/uri'; +import Event, { Emitter } from 'vs/base/common/event'; import { normalize } from 'vs/base/common/paths'; import { isFalsyOrEmpty } from 'vs/base/common/arrays'; import { relative } from 'path'; @@ -19,9 +20,12 @@ export class ExtHostWorkspace extends ExtHostWorkspaceShape { private static _requestIdPool = 0; + private readonly _onDidChangeWorkspace = new Emitter(); private readonly _proxy: MainThreadWorkspaceShape; private _workspace: IWorkspaceData; + readonly onDidChangeWorkspace: Event = this._onDidChangeWorkspace.event; + constructor(threadService: IThreadService, workspace: IWorkspaceData) { super(); this._proxy = threadService.get(MainContext.MainThreadWorkspace); @@ -31,7 +35,9 @@ export class ExtHostWorkspace extends ExtHostWorkspaceShape { // --- workspace --- getPath(): string { - // TODO@Joh handle roots.length > 1 case + // this is legacy from the days before having + // multi-root and we keep it only alive if there + // is just one workspace folder. return this._workspace ? this._workspace.roots[0].fsPath : undefined; } @@ -64,8 +70,8 @@ export class ExtHostWorkspace extends ExtHostWorkspaceShape { } $acceptWorkspaceData(workspace: IWorkspaceData): void { - //TODO@joh equality-check, emit event etc. this._workspace = workspace; + this._onDidChangeWorkspace.fire(this); } // --- search --- -- GitLab From 22dd958b33a26e40a8013d0b303f817314f22b39 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Thu, 15 Jun 2017 18:15:31 +0200 Subject: [PATCH 0894/1347] #28538 Remove configurationEvent.config property --- src/vs/code/electron-main/menus.ts | 2 +- .../configuration/common/configuration.ts | 6 ------ .../configuration/node/configurationService.ts | 1 - .../contextkey/browser/contextKeyService.ts | 2 +- src/vs/platform/request/node/requestService.ts | 8 ++------ .../workbench/browser/parts/editor/editorPart.ts | 2 +- .../workbench/browser/parts/editor/textEditor.ts | 2 +- .../parts/quickopen/quickOpenController.ts | 2 +- .../workbench/common/editor/editorStacksModel.ts | 2 +- .../common/editor/untitledEditorModel.ts | 2 +- src/vs/workbench/electron-browser/window.ts | 2 +- .../parts/backup/common/backupModelTracker.ts | 2 +- .../parts/files/browser/files.contribution.ts | 2 +- .../parts/files/browser/views/explorerView.ts | 2 +- .../parts/files/browser/views/explorerViewer.ts | 2 +- .../parts/files/browser/views/openEditorsView.ts | 2 +- .../files/common/editors/fileEditorTracker.ts | 2 +- .../parts/markers/browser/markersPanel.ts | 2 +- .../electron-browser/relauncher.contribution.ts | 2 +- .../parts/search/browser/openAnythingHandler.ts | 2 +- .../parts/search/browser/searchViewlet.ts | 2 +- .../services/configuration/node/configuration.ts | 16 ++++++---------- .../test/node/configuration.test.ts | 2 +- .../files/electron-browser/fileService.ts | 2 +- .../services/mode/common/workbenchModeService.ts | 2 +- .../services/textfile/common/textFileService.ts | 2 +- 26 files changed, 30 insertions(+), 45 deletions(-) diff --git a/src/vs/code/electron-main/menus.ts b/src/vs/code/electron-main/menus.ts index 8679eabeeef..da1ca7c05bb 100644 --- a/src/vs/code/electron-main/menus.ts +++ b/src/vs/code/electron-main/menus.ts @@ -119,7 +119,7 @@ export class CodeMenu { }); // Update when auto save config changes - this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated(e.config, true /* update menu if changed */)); + this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated(this.configurationService.getConfiguration(), true /* update menu if changed */)); // Listen to update service this.updateService.onStateChange(() => this.updateMenu()); diff --git a/src/vs/platform/configuration/common/configuration.ts b/src/vs/platform/configuration/common/configuration.ts index b3baea8370c..988c167e791 100644 --- a/src/vs/platform/configuration/common/configuration.ts +++ b/src/vs/platform/configuration/common/configuration.ts @@ -63,17 +63,11 @@ export enum ConfigurationSource { } export interface IConfigurationServiceEvent { - /** - * TODO: Remove this - * The full configuration. - */ - config: any; /** * The type of source that triggered this event. */ source: ConfigurationSource; /** - * TODO: Remove this * The part of the configuration contributed by the source of this event. */ sourceConfig: any; diff --git a/src/vs/platform/configuration/node/configurationService.ts b/src/vs/platform/configuration/node/configurationService.ts index 76ad820e196..c89737df2a2 100644 --- a/src/vs/platform/configuration/node/configurationService.ts +++ b/src/vs/platform/configuration/node/configurationService.ts @@ -49,7 +49,6 @@ export class ConfigurationService extends Disposable implements IConfiguratio const cache = this.getConfiguration2(); this._onDidUpdateConfiguration.fire({ - config: this.getConfiguration(), source, sourceConfig: source === ConfigurationSource.Default ? cache.defaults.contents : cache.user.contents }); diff --git a/src/vs/platform/contextkey/browser/contextKeyService.ts b/src/vs/platform/contextkey/browser/contextKeyService.ts index 45d993851a4..325e8cf9680 100644 --- a/src/vs/platform/contextkey/browser/contextKeyService.ts +++ b/src/vs/platform/contextkey/browser/contextKeyService.ts @@ -58,7 +58,7 @@ class ConfigAwareContextValuesContainer extends Context { super(id, null); this._emitter = emitter; - this._subscription = configurationService.onDidUpdateConfiguration(e => this._updateConfigurationContext(e.config)); + this._subscription = configurationService.onDidUpdateConfiguration(e => this._updateConfigurationContext(configurationService.getConfiguration())); this._updateConfigurationContext(configurationService.getConfiguration()); } diff --git a/src/vs/platform/request/node/requestService.ts b/src/vs/platform/request/node/requestService.ts index ac91d258b24..23033fbe4f0 100644 --- a/src/vs/platform/request/node/requestService.ts +++ b/src/vs/platform/request/node/requestService.ts @@ -10,7 +10,7 @@ import { assign } from 'vs/base/common/objects'; import { IRequestOptions, IRequestContext, IRequestFunction, request } from 'vs/base/node/request'; import { getProxyAgent } from 'vs/base/node/proxy'; import { IRequestService, IHTTPConfiguration } from 'vs/platform/request/node/request'; -import { IConfigurationService, IConfigurationServiceEvent } from 'vs/platform/configuration/common/configuration'; +import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; /** * This service exposes the `request` API, while using the global @@ -29,11 +29,7 @@ export class RequestService implements IRequestService { @IConfigurationService configurationService: IConfigurationService ) { this.configure(configurationService.getConfiguration()); - configurationService.onDidUpdateConfiguration(this.onDidUpdateConfiguration, this, this.disposables); - } - - private onDidUpdateConfiguration(e: IConfigurationServiceEvent) { - this.configure(e.config); + configurationService.onDidUpdateConfiguration(() => this.configure(configurationService.getConfiguration()), this, this.disposables); } private configure(config: IHTTPConfiguration) { diff --git a/src/vs/workbench/browser/parts/editor/editorPart.ts b/src/vs/workbench/browser/parts/editor/editorPart.ts index 18a865ad5fc..7c4fdc9653b 100644 --- a/src/vs/workbench/browser/parts/editor/editorPart.ts +++ b/src/vs/workbench/browser/parts/editor/editorPart.ts @@ -182,7 +182,7 @@ export class EditorPart extends Part implements IEditorPart, IEditorGroupService this.toUnbind.push(this.stacks.onEditorClosed(event => this.onEditorClosed(event))); this.toUnbind.push(this.stacks.onGroupOpened(event => this.onEditorGroupOpenedOrClosed())); this.toUnbind.push(this.stacks.onGroupClosed(event => this.onEditorGroupOpenedOrClosed())); - this.toUnbind.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated(e.config))); + this.toUnbind.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated(this.configurationService.getConfiguration()))); } private onEditorGroupOpenedOrClosed(): void { diff --git a/src/vs/workbench/browser/parts/editor/textEditor.ts b/src/vs/workbench/browser/parts/editor/textEditor.ts index 129428cd750..c926a9d2e17 100644 --- a/src/vs/workbench/browser/parts/editor/textEditor.ts +++ b/src/vs/workbench/browser/parts/editor/textEditor.ts @@ -66,7 +66,7 @@ export abstract class BaseTextEditor extends BaseEditor { ) { super(id, telemetryService, themeService); - this.toUnbind.push(this.configurationService.onDidUpdateConfiguration(e => this.handleConfigurationChangeEvent(e.config))); + this.toUnbind.push(this.configurationService.onDidUpdateConfiguration(e => this.handleConfigurationChangeEvent(this.configurationService.getConfiguration()))); } protected get instantiationService(): IInstantiationService { diff --git a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts index 47e8f16d80e..445c1325b40 100644 --- a/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts +++ b/src/vs/workbench/browser/parts/quickopen/quickOpenController.ts @@ -129,7 +129,7 @@ export class QuickOpenController extends Component implements IQuickOpenService } private registerListeners(): void { - this.toUnbind.push(this.configurationService.onDidUpdateConfiguration(e => this.updateConfiguration(e.config))); + this.toUnbind.push(this.configurationService.onDidUpdateConfiguration(e => this.updateConfiguration(this.configurationService.getConfiguration()))); this.toUnbind.push(this.partService.onTitleBarVisibilityChange(() => this.positionQuickOpenWidget())); this.toUnbind.push(browser.onDidChangeZoomLevel(() => this.positionQuickOpenWidget())); } diff --git a/src/vs/workbench/common/editor/editorStacksModel.ts b/src/vs/workbench/common/editor/editorStacksModel.ts index dd41ad0eb1e..a771fa75443 100644 --- a/src/vs/workbench/common/editor/editorStacksModel.ts +++ b/src/vs/workbench/common/editor/editorStacksModel.ts @@ -110,7 +110,7 @@ export class EditorGroup implements IEditorGroup { } private registerListeners(): void { - this.toDispose.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated(e.config))); + this.toDispose.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated(this.configurationService.getConfiguration()))); } private onConfigurationUpdated(config: IWorkbenchEditorConfiguration): void { diff --git a/src/vs/workbench/common/editor/untitledEditorModel.ts b/src/vs/workbench/common/editor/untitledEditorModel.ts index 65e8c973201..9a3d2afdee2 100644 --- a/src/vs/workbench/common/editor/untitledEditorModel.ts +++ b/src/vs/workbench/common/editor/untitledEditorModel.ts @@ -88,7 +88,7 @@ export class UntitledEditorModel extends BaseTextEditorModel implements IEncodin private registerListeners(): void { // Config Changes - this.configurationChangeListener = this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationChange(e.config)); + this.configurationChangeListener = this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationChange(this.configurationService.getConfiguration())); } private onConfigurationChange(configuration: IFilesConfiguration): void { diff --git a/src/vs/workbench/electron-browser/window.ts b/src/vs/workbench/electron-browser/window.ts index d164d685161..c92fb29c109 100644 --- a/src/vs/workbench/electron-browser/window.ts +++ b/src/vs/workbench/electron-browser/window.ts @@ -302,7 +302,7 @@ export class ElectronWindow extends Themable { // Configuration changes let previousConfiguredZoomLevel: number; this.configurationService.onDidUpdateConfiguration(e => { - const windowConfig: IWindowConfiguration = e.config; + const windowConfig: IWindowConfiguration = this.configurationService.getConfiguration(); let newZoomLevel = 0; if (windowConfig.window && typeof windowConfig.window.zoomLevel === 'number') { diff --git a/src/vs/workbench/parts/backup/common/backupModelTracker.ts b/src/vs/workbench/parts/backup/common/backupModelTracker.ts index 71f7fd5d0dd..787897cd389 100644 --- a/src/vs/workbench/parts/backup/common/backupModelTracker.ts +++ b/src/vs/workbench/parts/backup/common/backupModelTracker.ts @@ -50,7 +50,7 @@ export class BackupModelTracker implements IWorkbenchContribution { this.toDispose.push(this.untitledEditorService.onDidDisposeModel((e) => this.discardBackup(e))); // Listen to config changes - this.toDispose.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationChange(e.config))); + this.toDispose.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationChange(this.configurationService.getConfiguration()))); } private onConfigurationChange(configuration: IFilesConfiguration): void { diff --git a/src/vs/workbench/parts/files/browser/files.contribution.ts b/src/vs/workbench/parts/files/browser/files.contribution.ts index 6d5cba5b615..4c4c811c26c 100644 --- a/src/vs/workbench/parts/files/browser/files.contribution.ts +++ b/src/vs/workbench/parts/files/browser/files.contribution.ts @@ -122,7 +122,7 @@ class FileEditorInputFactory implements IEditorInputFactory { } private registerListeners(): void { - this.configurationService.onDidUpdateConfiguration(e => this.onConfiguration(e.config)); + this.configurationService.onDidUpdateConfiguration(e => this.onConfiguration(this.configurationService.getConfiguration())); } private onConfiguration(config: IFilesConfiguration): void { diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index d1df344969a..37d52b0f58e 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -173,7 +173,7 @@ export class ExplorerView extends CollapsibleView { this.toDispose.push(this.editorGroupService.onEditorsChanged(() => this.onEditorsChanged())); // Also handle configuration updates - this.toDispose.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated(e.config, true))); + this.toDispose.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated(this.configurationService.getConfiguration(), true))); }); } diff --git a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts index e7ed0556942..e46282959a5 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts @@ -611,7 +611,7 @@ export class FileDragAndDrop implements IDragAndDrop { } private registerListeners(): void { - this.toDispose.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated(e.config))); + this.toDispose.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated(this.configurationService.getConfiguration()))); } private onConfigurationUpdated(config: IFilesConfiguration): void { diff --git a/src/vs/workbench/parts/files/browser/views/openEditorsView.ts b/src/vs/workbench/parts/files/browser/views/openEditorsView.ts index d15bc3aef00..10c10b7736f 100644 --- a/src/vs/workbench/parts/files/browser/views/openEditorsView.ts +++ b/src/vs/workbench/parts/files/browser/views/openEditorsView.ts @@ -186,7 +186,7 @@ export class OpenEditorsView extends CollapsibleView { this.toDispose.push(this.model.onModelChanged(e => this.onEditorStacksModelChanged(e))); // Also handle configuration updates - this.toDispose.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated(e.config))); + this.toDispose.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated(this.configurationService.getConfiguration()))); // Handle dirty counter this.toDispose.push(this.untitledEditorService.onDidChangeDirty(e => this.updateDirtyIndicator())); diff --git a/src/vs/workbench/parts/files/common/editors/fileEditorTracker.ts b/src/vs/workbench/parts/files/common/editors/fileEditorTracker.ts index 1ea7c0e7452..b87ea5f7ab6 100644 --- a/src/vs/workbench/parts/files/common/editors/fileEditorTracker.ts +++ b/src/vs/workbench/parts/files/common/editors/fileEditorTracker.ts @@ -62,7 +62,7 @@ export class FileEditorTracker implements IWorkbenchContribution { this.lifecycleService.onShutdown(this.dispose, this); // Configuration - this.toUnbind.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated(e.config))); + this.toUnbind.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated(this.configurationService.getConfiguration()))); } private onConfigurationUpdated(configuration: IWorkbenchEditorConfiguration): void { diff --git a/src/vs/workbench/parts/markers/browser/markersPanel.ts b/src/vs/workbench/parts/markers/browser/markersPanel.ts index 53c9bfdff05..8df5bac927a 100644 --- a/src/vs/workbench/parts/markers/browser/markersPanel.ts +++ b/src/vs/workbench/parts/markers/browser/markersPanel.ts @@ -249,7 +249,7 @@ export class MarkersPanel extends Panel { } private createListeners(): void { - this.toDispose.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationsUpdated(e.config))); + this.toDispose.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationsUpdated(this.configurationService.getConfiguration()))); this.toDispose.push(this.markerService.onMarkerChanged(this.onMarkerChanged, this)); this.toDispose.push(this.editorGroupService.onEditorsChanged(this.onEditorsChanged, this)); this.toDispose.push(this.tree.addListener('selection', () => this.onSelected())); diff --git a/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.ts b/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.ts index 5e82b8c104e..fe3a1d25476 100644 --- a/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.ts +++ b/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.ts @@ -43,7 +43,7 @@ export class SettingsChangeRelauncher implements IWorkbenchContribution { } private registerListeners(): void { - this.toDispose.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationChange(e.config, true))); + this.toDispose.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationChange(this.configurationService.getConfiguration(), true))); } private onConfigurationChange(config: IConfiguration, notify: boolean): void { diff --git a/src/vs/workbench/parts/search/browser/openAnythingHandler.ts b/src/vs/workbench/parts/search/browser/openAnythingHandler.ts index e777cc9311f..8c79b5fa0ea 100644 --- a/src/vs/workbench/parts/search/browser/openAnythingHandler.ts +++ b/src/vs/workbench/parts/search/browser/openAnythingHandler.ts @@ -116,7 +116,7 @@ export class OpenAnythingHandler extends QuickOpenHandler { } private registerListeners(): void { - this.configurationService.onDidUpdateConfiguration(e => this.updateHandlers(e.config)); + this.configurationService.onDidUpdateConfiguration(e => this.updateHandlers(this.configurationService.getConfiguration())); } private updateHandlers(configuration: IWorkbenchSearchConfiguration): void { diff --git a/src/vs/workbench/parts/search/browser/searchViewlet.ts b/src/vs/workbench/parts/search/browser/searchViewlet.ts index c02312985bf..2f6f1b58471 100644 --- a/src/vs/workbench/parts/search/browser/searchViewlet.ts +++ b/src/vs/workbench/parts/search/browser/searchViewlet.ts @@ -139,7 +139,7 @@ export class SearchViewlet extends Viewlet { this.toUnbind.push(this.fileService.onFileChanges(e => this.onFilesChanged(e))); this.toUnbind.push(this.untitledEditorService.onDidChangeDirty(e => this.onUntitledDidChangeDirty(e))); - this.toUnbind.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated(e.config))); + this.toUnbind.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated(this.configurationService.getConfiguration()))); this.selectCurrentMatchEmitter = new Emitter(); debounceEvent(this.selectCurrentMatchEmitter.event, (l, e) => e, 100, /*leading=*/true) diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index c1617034e62..03d82070727 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -225,7 +225,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp return this.baseConfigurationService.reloadConfiguration() .then(() => this.initialize()) // Reinitialize to ensure we are hitting the disk .then(() => !this._configuration.equals(current)) // Check if the configuration is changed - .then(changed => changed ? this.trigger() : void 0) // Trigger event if changed + .then(changed => changed ? this.trigger(ConfigurationSource.Workspace, ) : void 0) // Trigger event if changed .then(() => this.getConfiguration(section)); } @@ -237,7 +237,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp .filter(folderConfiguration => !!folderConfiguration.configuration) // Filter folders which are not impacted by events .map(folderConfiguration => this._configuration.updateFolderConfiguration(folderConfiguration.folder, folderConfiguration.configuration)) // Update the configuration of impacted folders .reduce((result, value) => result || value, false)) // Check if the effective configuration of folder is changed - .then(changed => changed ? this.trigger() : void 0); // Trigger event if changed + .then(changed => changed ? this.trigger(ConfigurationSource.Workspace) : void 0); // Trigger event if changed } } @@ -269,7 +269,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp this.initCachesForFolders(toInitialize); this.doInitialize(toInitialize) .then(changed => configurationChanged || changed) - .then(changed => changed ? this.trigger() : void 0); + .then(changed => changed ? this.trigger(ConfigurationSource.Workspace) : void 0); } } @@ -299,16 +299,12 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } if (this._configuration.updateBaseConfiguration(this.baseConfigurationService.getConfiguration2())) { - this.trigger(event); + this.trigger(event.source, event.sourceConfig); } } - private trigger(baseEvent?: IConfigurationServiceEvent): void { - this._onDidUpdateConfiguration.fire({ - config: this.getConfiguration(), - source: baseEvent ? baseEvent.source : ConfigurationSource.Workspace, - sourceConfig: baseEvent ? baseEvent.sourceConfig : this._configuration.getFolderConfigurationModel(this.workspace.roots[0]).contents - }); + private trigger(source: ConfigurationSource, sourceConfig: any = this._configuration.getFolderConfigurationModel(this.workspace.roots[0]).contents): void { + this._onDidUpdateConfiguration.fire({ source, sourceConfig }); } private toOptions(arg: any): IConfigurationOptions { diff --git a/src/vs/workbench/services/configuration/test/node/configuration.test.ts b/src/vs/workbench/services/configuration/test/node/configuration.test.ts index d7de49aba32..6a2ec1f6cd1 100644 --- a/src/vs/workbench/services/configuration/test/node/configuration.test.ts +++ b/src/vs/workbench/services/configuration/test/node/configuration.test.ts @@ -212,7 +212,7 @@ suite('WorkspaceConfigurationService - Node', () => { service.onDidUpdateConfiguration(event => { const config = service.getConfiguration<{ testworkbench: { editor: { icons: boolean } } }>(); assert.equal(config.testworkbench.editor.icons, true); - assert.equal(event.config.testworkbench.editor.icons, true); + assert.equal(service.getConfiguration().testworkbench.editor.icons, true); service.dispose(); diff --git a/src/vs/workbench/services/files/electron-browser/fileService.ts b/src/vs/workbench/services/files/electron-browser/fileService.ts index 0fba07f5e29..4686db922fd 100644 --- a/src/vs/workbench/services/files/electron-browser/fileService.ts +++ b/src/vs/workbench/services/files/electron-browser/fileService.ts @@ -134,7 +134,7 @@ export class FileService implements IFileService { this.toUnbind.push(this.raw.onAfterOperation(e => this._onAfterOperation.fire(e))); // Config changes - this.toUnbind.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationChange(e.config))); + this.toUnbind.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationChange(this.configurationService.getConfiguration()))); // Editor changing this.toUnbind.push(this.editorGroupService.onEditorsChanged(() => this.onEditorsChanged())); diff --git a/src/vs/workbench/services/mode/common/workbenchModeService.ts b/src/vs/workbench/services/mode/common/workbenchModeService.ts index fc65de33c91..f5a138519f6 100644 --- a/src/vs/workbench/services/mode/common/workbenchModeService.ts +++ b/src/vs/workbench/services/mode/common/workbenchModeService.ts @@ -63,7 +63,7 @@ export class WorkbenchModeServiceImpl extends ModeServiceImpl { }); - this._configurationService.onDidUpdateConfiguration(e => this.onConfigurationChange(e.config)); + this._configurationService.onDidUpdateConfiguration(e => this.onConfigurationChange(this._configurationService.getConfiguration())); this.onDidCreateMode((mode) => { this._extensionService.activateByEvent(`onLanguage:${mode.getId()}`).done(null, onUnexpectedError); diff --git a/src/vs/workbench/services/textfile/common/textFileService.ts b/src/vs/workbench/services/textfile/common/textFileService.ts index f8cc7e2f2f8..515c976f07e 100644 --- a/src/vs/workbench/services/textfile/common/textFileService.ts +++ b/src/vs/workbench/services/textfile/common/textFileService.ts @@ -117,7 +117,7 @@ export abstract class TextFileService implements ITextFileService { this.lifecycleService.onShutdown(this.dispose, this); // Configuration changes - this.toUnbind.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationChange(e.config))); + this.toUnbind.push(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationChange(this.configurationService.getConfiguration()))); } private beforeShutdown(reason: ShutdownReason): boolean | TPromise { -- GitLab From be5fa397a53b12abb1ffb4ad36a867af944976e4 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 15 Jun 2017 17:19:41 +0200 Subject: [PATCH 0895/1347] :lipstick: --- src/vs/base/common/filters.ts | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/src/vs/base/common/filters.ts b/src/vs/base/common/filters.ts index 684c17cc556..d476d8ecce5 100644 --- a/src/vs/base/common/filters.ts +++ b/src/vs/base/common/filters.ts @@ -621,9 +621,20 @@ function _findAllMatches(patternPos: number, wordPos: number, total: number, mat matches.unshift(wordPos); lastMatched = true; + // count simple matches and boost a row of + // simple matches when they yield in a + // strong match. if (score === 1) { simpleMatchCount += 1; + + if (patternPos === _patternStartPos) { + // when the first match is a weak + // match we discard it + return undefined; + } + } else { + // boost total += 1 + (simpleMatchCount * (score - 1)); simpleMatchCount = 0; } @@ -633,11 +644,6 @@ function _findAllMatches(patternPos: number, wordPos: number, total: number, mat } } - if (_scores[1][matches[0] + 1] === 1) { - // first match is weak - return undefined; - } - total -= wordPos >= 3 ? 9 : wordPos * 3; // late start penalty _bucket.push([total, matches]); -- GitLab From 528682cd60d4564203cff441f33da65b06525801 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Thu, 15 Jun 2017 18:45:31 +0200 Subject: [PATCH 0896/1347] avoid slice-calls, avoid searching for best result when you know it, #18682 --- src/vs/base/common/filters.ts | 78 +++++++++++++++++++++++++++-------- 1 file changed, 60 insertions(+), 18 deletions(-) diff --git a/src/vs/base/common/filters.ts b/src/vs/base/common/filters.ts index d476d8ecce5..eafc2d5f6b1 100644 --- a/src/vs/base/common/filters.ts +++ b/src/vs/base/common/filters.ts @@ -551,31 +551,26 @@ export function fuzzyScore(pattern: string, word: string): [number, number[]] { console.log(printTable(_scores, pattern, patternLen, word, wordLen)); } + // _bucket is an array of [PrefixArray] we use to keep + // track of scores and matches. After calling `_findAllMatches` + // the best match (if available) is the first item in the array _bucket.length = 0; + _topScore = -100; _patternStartPos = patternStartPos; - _findAllMatches(patternLen, wordLen, 0, [], false); + _findAllMatches(patternLen, wordLen, 0, new LazyArray(), false); if (_bucket.length === 0) { return undefined; } - let topMatch = _bucket[0]; - for (let i = 1; i < _bucket.length; i++) { - let match = _bucket[i]; - if (topMatch[0] < match[0]) { - topMatch = match; - } - } - if (_debug) { - console.log(`${pattern} & ${word} => ${topMatch[0]} points for ${topMatch[1]}`); - } - return topMatch; + return [_topScore, _bucket[0].toArray()]; } -let _bucket: [number, number[]][] = []; +let _bucket: LazyArray[] = []; +let _topScore: number = 0; let _patternStartPos: number = 0; -function _findAllMatches(patternPos: number, wordPos: number, total: number, matches: number[], lastMatched: boolean): void { +function _findAllMatches(patternPos: number, wordPos: number, total: number, matches: LazyArray, lastMatched: boolean): void { if (_bucket.length >= 10 || total < -25) { // stop when having already 10 results, or @@ -595,7 +590,7 @@ function _findAllMatches(patternPos: number, wordPos: number, total: number, mat wordPos -= 1; if (lastMatched) { total -= 5; // new gap penalty - } else if (matches.length !== 0) { + } else if (!matches.isEmpty()) { total -= 1; // gap penalty after first match } lastMatched = false; @@ -608,8 +603,8 @@ function _findAllMatches(patternPos: number, wordPos: number, total: number, mat _findAllMatches( patternPos, wordPos - 1, - matches.length !== 0 ? total - 1 : total, - matches.slice(0), + !matches.isEmpty() ? total - 1 : total, // gap penalty after first match + matches.slice(), lastMatched ); } @@ -646,9 +641,56 @@ function _findAllMatches(patternPos: number, wordPos: number, total: number, mat total -= wordPos >= 3 ? 9 : wordPos * 3; // late start penalty - _bucket.push([total, matches]); + // dynamically keep track of the current top score + // and insert the current best score at head, the rest at tail + if (total > _topScore) { + _topScore = total; + _bucket.unshift(matches); + } else { + _bucket.push(matches); + } } +class LazyArray { + + private _parent: LazyArray; + private _parentLen: number; + private _data: number[]; + + isEmpty(): boolean { + return !this._data && (!this._parent || this._parent.isEmpty()); + } + + unshift(n: number) { + if (!this._data) { + this._data = [n]; + } else { + this._data.unshift(n); + } + } + + slice(): LazyArray { + const ret = new LazyArray(); + ret._parent = this; + ret._parentLen = this._data ? this._data.length : 0; + return ret; + } + + toArray(): number[] { + if (!this._data) { + return this._parent.toArray(); + } + const bucket: number[][] = []; + let element = this; + while (element) { + if (element._parent && element._parent._data) { + bucket.push(element._parent._data.slice(element._parent._data.length - element._parentLen)); + } + element = element._parent; + } + return Array.prototype.concat.apply(this._data, bucket); + } +} export function nextTypoPermutation(pattern: string, patternPos: number) { -- GitLab From 500c7ff845227a29e729ffa8fe23e8e62cd51c67 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Thu, 15 Jun 2017 10:17:54 -0700 Subject: [PATCH 0897/1347] Convert nsfw rename events to delete and create events --- .../node/watcher/nsfw/nsfwWatcherService.ts | 36 ++++++++++++++----- 1 file changed, 28 insertions(+), 8 deletions(-) diff --git a/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts b/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts index 5b963bdc348..717db358dfb 100644 --- a/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts +++ b/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts @@ -28,7 +28,16 @@ export class NsfwWatcherService implements IWatcherService { events.forEach(e => console.log(e)); console.log('raw events end'); } - const convertedEvents = events.map(e => this._mapNsfwEventToRawFileChange(e)).filter(e => !!e); + const convertedEvents: watcher.IRawFileChange[] = []; + events.forEach(e => { + const c = this._mapNsfwEventToRawFileChanges(e); + if (c && c.length) { + c.forEach(c1 => convertedEvents.push(c1)); + } + }); + if (request.verboseLogging) { + console.log('converted events', convertedEvents); + } // TODO: Utilize fileEventDelayer and watcher.normalize p(convertedEvents); }).then(watcher => { @@ -37,18 +46,29 @@ export class NsfwWatcherService implements IWatcherService { }); } - private _mapNsfwEventToRawFileChange(nsfwEvent: any): watcher.IRawFileChange { + private _mapNsfwEventToRawFileChanges(nsfwEvent: any): watcher.IRawFileChange[] { // TODO: Handle other event types (directory change?) + + + // Convert a rename event to a delete and a create + if (nsfwEvent.action === 3) { + console.log('rename', nsfwEvent); + return [ + { type: 2, path: path.join(nsfwEvent.directory, nsfwEvent.oldFile) }, // Delete + { type: 1, path: path.join(nsfwEvent.directory, nsfwEvent.newFile) } // Create + ]; + } + if (!nsfwEvent.directory || !nsfwEvent.file) { - return null; + throw new Error('unhandled case'); + // return null; } + const p = path.join(nsfwEvent.directory, nsfwEvent.file); + const event: watcher.IRawFileChange = { type: nsfwEventActionToRawChangeType[nsfwEvent.action], - path: path.join(nsfwEvent.directory, nsfwEvent.file) + path: p }; - if (!event.type) { - return null; - } - return event; + return [event]; } } -- GitLab From 324cd2ac55f2b99b0b5d500cdea40f732246c30d Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Thu, 15 Jun 2017 10:21:43 -0700 Subject: [PATCH 0898/1347] Remove Unused Html Content Renderer Extensibility (#28760) * Remove Unused Html Content Renderer Extensibility Removes a few options from the html content renderer that are currently not used * Fix messageList --- src/vs/base/browser/htmlContentRenderer.ts | 55 +------------------ src/vs/base/browser/ui/inputbox/inputBox.ts | 2 +- src/vs/base/common/htmlContent.ts | 12 +--- src/vs/base/test/browser/htmlContent.test.ts | 35 +----------- .../test/keyboardMapperTestUtils.ts | 8 +-- .../services/message/browser/messageList.ts | 2 +- 6 files changed, 11 insertions(+), 103 deletions(-) diff --git a/src/vs/base/browser/htmlContentRenderer.ts b/src/vs/base/browser/htmlContentRenderer.ts index 2b6cc38e2b0..c4991d77015 100644 --- a/src/vs/base/browser/htmlContentRenderer.ts +++ b/src/vs/base/browser/htmlContentRenderer.ts @@ -33,7 +33,7 @@ export function renderMarkedString(markedString: MarkedString, options: RenderOp */ export function renderHtml(content: RenderableContent, options: RenderOptions = {}): Node { if (typeof content === 'string') { - return _renderHtml({ isText: true, text: content }, options); + return document.createTextNode(content); } else if (Array.isArray(content)) { return _renderHtml({ children: content }, options); } else if (content) { @@ -46,11 +46,7 @@ function _renderHtml(content: IHTMLContentElement, options: RenderOptions = {}): let { codeBlockRenderer, actionCallback } = options; - if (content.isText) { - return document.createTextNode(content.text); - } - - var tagName = getSafeTagName(content.tagName) || 'div'; + var tagName = content.inline ? 'span' : 'div'; var element = document.createElement(tagName); if (content.className) { @@ -59,14 +55,6 @@ function _renderHtml(content: IHTMLContentElement, options: RenderOptions = {}): if (content.text) { element.textContent = content.text; } - if (content.style) { - element.setAttribute('style', content.style); - } - if (content.customStyle) { - Object.keys(content.customStyle).forEach((key) => { - element.style[key] = content.customStyle[key]; - }); - } if (content.children) { content.children.forEach((child) => { element.appendChild(renderHtml(child, options)); @@ -191,45 +179,6 @@ function _renderHtml(content: IHTMLContentElement, options: RenderOptions = {}): return element; } -var SAFE_TAG_NAMES = { - a: true, - b: true, - blockquote: true, - code: true, - del: true, - dd: true, - div: true, - dl: true, - dt: true, - em: true, - h1h2h3i: true, - img: true, - kbd: true, - li: true, - ol: true, - p: true, - pre: true, - s: true, - span: true, - sup: true, - sub: true, - strong: true, - strike: true, - ul: true, - br: true, - hr: true, -}; - -function getSafeTagName(tagName: string): string { - if (!tagName) { - return null; - } - if (SAFE_TAG_NAMES.hasOwnProperty(tagName)) { - return tagName; - } - return null; -} - // --- formatted string parsing class StringStream { diff --git a/src/vs/base/browser/ui/inputbox/inputBox.ts b/src/vs/base/browser/ui/inputbox/inputBox.ts index 87f6428e526..69ebed4e845 100644 --- a/src/vs/base/browser/ui/inputbox/inputBox.ts +++ b/src/vs/base/browser/ui/inputbox/inputBox.ts @@ -382,7 +382,7 @@ export class InputBox extends Widget { layout(); let renderOptions: IHTMLContentElement = { - tagName: 'span', + inline: true, className: 'monaco-inputbox-message', }; diff --git a/src/vs/base/common/htmlContent.ts b/src/vs/base/common/htmlContent.ts index 8dcc73fc332..da68a1f7719 100644 --- a/src/vs/base/common/htmlContent.ts +++ b/src/vs/base/common/htmlContent.ts @@ -85,12 +85,8 @@ export interface IHTMLContentElement { formattedText?: string; text?: string; className?: string; - style?: string; - customStyle?: any; - tagName?: string; + inline?: boolean; children?: IHTMLContentElement[]; - isText?: boolean; - role?: string; markdown?: string; code?: IHTMLContentElementCode; } @@ -113,11 +109,7 @@ function htmlContentElementEqual(a: IHTMLContentElement, b: IHTMLContentElement) a.formattedText === b.formattedText && a.text === b.text && a.className === b.className - && a.style === b.style - && a.customStyle === b.customStyle - && a.tagName === b.tagName - && a.isText === b.isText - && a.role === b.role + && a.inline === b.inline && a.markdown === b.markdown && htmlContentElementCodeEqual(a.code, b.code) && htmlContentElementArrEquals(a.children, b.children) diff --git a/src/vs/base/test/browser/htmlContent.test.ts b/src/vs/base/test/browser/htmlContent.test.ts index eaa12a6ba26..59caefa1d2e 100644 --- a/src/vs/base/test/browser/htmlContent.test.ts +++ b/src/vs/base/test/browser/htmlContent.test.ts @@ -10,25 +10,10 @@ import { renderHtml } from 'vs/base/browser/htmlContentRenderer'; suite('HtmlContent', () => { test('render text', () => { - var result = renderHtml({ - text: 'testing', - isText: true - }); + var result = renderHtml('testing'); assert.strictEqual(result.nodeType, document.TEXT_NODE); }); - test('cannot render script tag', function () { - var host = document.createElement('div'); - document.body.appendChild(host); - host.appendChild(renderHtml({ - tagName: 'script', - text: 'alert(\'owned -- injected script tag via htmlContent!\')' - })); - assert(true); - document.body.removeChild(host); - }); - - test('render simple element', () => { var result: HTMLElement = renderHtml({ text: 'testing' @@ -47,24 +32,6 @@ suite('HtmlContent', () => { assert.strictEqual(result.className, 'testClass'); }); - test('render element with style', () => { - var result: HTMLElement = renderHtml({ - text: 'testing', - style: 'width: 100px;' - }); - assert.strictEqual(result.getAttribute('style'), 'width: 100px;'); - }); - - test('render element with custom style', () => { - var result: HTMLElement = renderHtml({ - text: 'testing', - customStyle: { - 'width': '100px' - } - }); - assert.strictEqual(result.style.width, '100px'); - }); - test('render element with children', () => { var result: HTMLElement = renderHtml({ className: 'parent', diff --git a/src/vs/workbench/services/keybinding/test/keyboardMapperTestUtils.ts b/src/vs/workbench/services/keybinding/test/keyboardMapperTestUtils.ts index d79895b63f0..25b6f08b17d 100644 --- a/src/vs/workbench/services/keybinding/test/keyboardMapperTestUtils.ts +++ b/src/vs/workbench/services/keybinding/test/keyboardMapperTestUtils.ts @@ -56,16 +56,16 @@ function _htmlPieces(pieces: string[], OS: OperatingSystem): IHTMLContentElement let children: IHTMLContentElement[] = []; for (let i = 0, len = pieces.length; i < len; i++) { if (i !== 0 && OS !== OperatingSystem.Macintosh) { - children.push({ tagName: 'span', text: '+' }); + children.push({ inline: true, text: '+' }); } - children.push({ tagName: 'span', className: 'monaco-kbkey', text: pieces[i] }); + children.push({ inline: true, className: 'monaco-kbkey', text: pieces[i] }); } return children; } export function simpleHTMLLabel(pieces: string[], OS: OperatingSystem): IHTMLContentElement { return { - tagName: 'span', + inline: true, className: 'monaco-kb', children: _htmlPieces(pieces, OS) }; @@ -73,7 +73,7 @@ export function simpleHTMLLabel(pieces: string[], OS: OperatingSystem): IHTMLCon export function chordHTMLLabel(firstPart: string[], chordPart: string[], OS: OperatingSystem): IHTMLContentElement { return { - tagName: 'span', + inline: true, className: 'monaco-kb', children: [].concat( _htmlPieces(firstPart, OS), diff --git a/src/vs/workbench/services/message/browser/messageList.ts b/src/vs/workbench/services/message/browser/messageList.ts index 55e51942ce2..6379dbe8d2b 100644 --- a/src/vs/workbench/services/message/browser/messageList.ts +++ b/src/vs/workbench/services/message/browser/messageList.ts @@ -335,7 +335,7 @@ export class MessageList { // Error message const messageContentElement = htmlRenderer.renderHtml({ - tagName: 'span', + inline: true, className: 'message-left-side', formattedText: text }); -- GitLab From 6cc63cdf15c625337d935e979d9493d0cb401dae Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Thu, 15 Jun 2017 11:10:00 -0700 Subject: [PATCH 0899/1347] Use stream reader for TextDocument for more efficient parsing --- extensions/emmet/package.json | 2 +- extensions/emmet/src/balance.ts | 42 +++-- extensions/emmet/src/bufferStream.ts | 187 +++++++++++++++++++ extensions/emmet/src/matchTag.ts | 21 +-- extensions/emmet/src/mergeLines.ts | 11 +- extensions/emmet/src/removeTag.ts | 3 +- extensions/emmet/src/selectItem.ts | 7 +- extensions/emmet/src/selectItemHTML.ts | 74 ++++---- extensions/emmet/src/selectItemStylesheet.ts | 51 ++--- extensions/emmet/src/splitJoinTag.ts | 18 +- extensions/emmet/src/toggleComment.ts | 29 ++- extensions/emmet/src/updateTag.ts | 12 +- extensions/emmet/src/util.ts | 42 ++--- 13 files changed, 346 insertions(+), 153 deletions(-) create mode 100644 extensions/emmet/src/bufferStream.ts diff --git a/extensions/emmet/package.json b/extensions/emmet/package.json index bf96e3d75fd..719d8a9d17f 100644 --- a/extensions/emmet/package.json +++ b/extensions/emmet/package.json @@ -5,7 +5,7 @@ "version": "0.0.1", "publisher": "vscode", "engines": { - "vscode": "^1.10.0" + "vscode": "^1.13.0" }, "categories": [ "Other" diff --git a/extensions/emmet/src/balance.ts b/extensions/emmet/src/balance.ts index 02dd4c902d1..e7428bf3509 100644 --- a/extensions/emmet/src/balance.ts +++ b/extensions/emmet/src/balance.ts @@ -4,9 +4,10 @@ *--------------------------------------------------------------------------------------------*/ import * as vscode from 'vscode'; -import { getNode, getNodeOuterSelection, getNodeInnerSelection, isStyleSheet } from './util'; +import { getNode, isStyleSheet } from './util'; import parse from '@emmetio/html-matcher'; import Node from '@emmetio/node'; +import { DocumentStreamReader } from './bufferStream'; export function balanceOut() { balance(true); @@ -27,14 +28,12 @@ function balance(out: boolean) { } let getRangeFunction = out ? getRangeToBalanceOut : getRangeToBalanceIn; - let rootNode: Node = parse(editor.document.getText()); + let rootNode: Node = parse(new DocumentStreamReader(editor.document)); let newSelections: vscode.Selection[] = []; editor.selections.forEach(selection => { let range = getRangeFunction(editor.document, selection, rootNode); - if (range) { - newSelections.push(range); - } + newSelections.push(range ? range : selection); }); editor.selection = newSelections[0]; @@ -42,11 +41,16 @@ function balance(out: boolean) { } function getRangeToBalanceOut(document: vscode.TextDocument, selection: vscode.Selection, rootNode: Node): vscode.Selection { - let offset = document.offsetAt(selection.start); - let nodeToBalance = getNode(rootNode, offset); + let nodeToBalance = getNode(rootNode, selection.start); + if (!nodeToBalance) { + return; + } + if (!nodeToBalance.close) { + return new vscode.Selection(nodeToBalance.start, nodeToBalance.end); + } - let innerSelection = getNodeInnerSelection(document, nodeToBalance); - let outerSelection = getNodeOuterSelection(document, nodeToBalance); + let innerSelection = new vscode.Selection(nodeToBalance.open.end, nodeToBalance.close.start); + let outerSelection = new vscode.Selection(nodeToBalance.start, nodeToBalance.end); if (innerSelection.contains(selection) && !innerSelection.isEqual(selection)) { return innerSelection; @@ -58,18 +62,26 @@ function getRangeToBalanceOut(document: vscode.TextDocument, selection: vscode.S } function getRangeToBalanceIn(document: vscode.TextDocument, selection: vscode.Selection, rootNode: Node): vscode.Selection { - let offset = document.offsetAt(selection.start); - let nodeToBalance: Node = getNode(rootNode, offset); + let nodeToBalance: Node = getNode(rootNode, selection.start, true); + + if (!nodeToBalance) { + return; + } if (!nodeToBalance.firstChild) { - return selection; + if (nodeToBalance.close) { + return new vscode.Selection(nodeToBalance.open.end, nodeToBalance.close.start); + } + return; } - if (nodeToBalance.firstChild.start === offset && nodeToBalance.firstChild.end === document.offsetAt(selection.end)) { - return getNodeInnerSelection(document, nodeToBalance.firstChild); + if (selection.start.isEqual(nodeToBalance.firstChild.start) + && selection.end.isEqual(nodeToBalance.firstChild.end) + && nodeToBalance.firstChild.close) { + return new vscode.Selection(nodeToBalance.firstChild.open.end, nodeToBalance.firstChild.close.start); } - return new vscode.Selection(document.positionAt(nodeToBalance.firstChild.start), document.positionAt(nodeToBalance.firstChild.end)); + return new vscode.Selection(nodeToBalance.firstChild.start, nodeToBalance.firstChild.end); } diff --git a/extensions/emmet/src/bufferStream.ts b/extensions/emmet/src/bufferStream.ts new file mode 100644 index 00000000000..923c7d04d0d --- /dev/null +++ b/extensions/emmet/src/bufferStream.ts @@ -0,0 +1,187 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +'use strict'; + +import { TextDocument, Position, Range, EndOfLine } from 'vscode'; + +/** + * A stream reader for VSCode's `TextDocument` + * Based on @emmetio/stream-reader and @emmetio/atom-plugin + */ +export class DocumentStreamReader { + private document: TextDocument; + private start: Position; + private _eof: Position; + private pos: Position; + private _eol: string; + + /** + * @param {TextDocument} buffer + * @param {Position} pos + * @param {Range} limit + */ + constructor(document: TextDocument, pos?: Position, limit?: Range) { + + this.document = document; + this.start = this.pos = pos ? pos : new Position(0, 0); + this._eof = limit ? limit.end : new Position(this.document.lineCount - 1, this._lineLength(this.document.lineCount - 1)); + this._eol = this.document.eol === EndOfLine.LF ? '\n' : '\r\n'; + } + + /** + * Returns true only if the stream is at the end of the file. + * @returns {Boolean} + */ + eof() { + return this.pos.isAfterOrEqual(this._eof); + } + + /** + * Creates a new stream instance which is limited to given range for given document + * @param {Position} start + * @param {Position} end + * @return {DocumentStreamReader} + */ + limit(start, end) { + return new DocumentStreamReader(this.document, start, new Range(start, end)); + } + + /** + * Returns the next character code in the stream without advancing it. + * Will return NaN at the end of the file. + * @returns {Number} + */ + peek() { + if (this.eof()) { + return NaN; + } + const line = this.document.lineAt(this.pos.line).text; + return this.pos.character < line.length ? line.charCodeAt(this.pos.character) : this._eol.charCodeAt(this.pos.character - line.length); + } + + /** + * Returns the next character in the stream and advances it. + * Also returns NaN when no more characters are available. + * @returns {Number} + */ + next() { + if (this.eof()) { + return NaN; + } + + const line = this.document.lineAt(this.pos.line).text; + let code: number; + if (this.pos.character < line.length) { + code = line.charCodeAt(this.pos.character); + this.pos = this.pos.translate(0, 1); + } else { + code = this._eol.charCodeAt(this.pos.character - line.length); + this.pos = new Position(this.pos.line + 1, 0); + } + + if (this.eof()) { + // restrict pos to eof, if in case it got moved beyond eof + this.pos = new Position(this._eof.line, this._eof.character); + } + + return code; + } + + /** + * Backs up the stream n characters. Backing it up further than the + * start of the current token will cause things to break, so be careful. + * @param {Number} n + */ + backUp(n) { + let row = this.pos.line; + let column = this.pos.character; + column -= (n || 1); + + while (row >= 0 && column < 0) { + row--; + column += this._lineLength(row); + } + + this.pos = row < 0 || column < 0 + ? new Position(0, 0) + : new Position(row, column); + + return this.peek(); + } + + /** + * Get the string between the start of the current token and the + * current stream position. + * @returns {String} + */ + current() { + return this.substring(this.start, this.pos); + } + + /** + * Returns contents for given range + * @param {Position} from + * @param {Position} to + * @return {String} + */ + substring(from, to) { + return this.document.getText(new Range(from, to)); + } + + /** + * Creates error object with current stream state + * @param {String} message + * @return {Error} + */ + error(message) { + const err = new Error(`${message} at row ${this.pos.line}, column ${this.pos.character}`); + + return err; + } + + /** + * Returns line length of given row, including line ending + * @param {Number} row + * @return {Number} + */ + _lineLength(row) { + if (row === this.document.lineCount - 1) { + return this.document.lineAt(row).text.length; + } + return this.document.lineAt(row).text.length + this._eol.length; + } + + /** + * `match` can be a character code or a function that takes a character code + * and returns a boolean. If the next character in the stream 'matches' + * the given argument, it is consumed and returned. + * Otherwise, `false` is returned. + * @param {Number|Function} match + * @returns {Boolean} + */ + eat(match) { + const ch = this.peek(); + const ok = typeof match === 'function' ? match(ch) : ch === match; + + if (ok) { + this.next(); + } + + return ok; + } + + /** + * Repeatedly calls eat with the given argument, until it + * fails. Returns true if any characters were eaten. + * @param {Object} match + * @returns {Boolean} + */ + eatWhile(match) { + const start = this.pos; + while (!this.eof() && this.eat(match)) { } + return !this.pos.isEqual(start); + } +} diff --git a/extensions/emmet/src/matchTag.ts b/extensions/emmet/src/matchTag.ts index 8037ca97d95..af72138240c 100644 --- a/extensions/emmet/src/matchTag.ts +++ b/extensions/emmet/src/matchTag.ts @@ -7,6 +7,7 @@ import * as vscode from 'vscode'; import { getNode } from './util'; import parse from '@emmetio/html-matcher'; import Node from '@emmetio/node'; +import { DocumentStreamReader } from './bufferStream'; export function matchTag() { let editor = vscode.window.activeTextEditor; @@ -15,10 +16,10 @@ export function matchTag() { return; } - let rootNode: Node = parse(editor.document.getText()); + let rootNode: Node = parse(new DocumentStreamReader(editor.document)); let updatedSelections = []; editor.selections.forEach(selection => { - let updatedSelection = getUpdatedSelections(editor, editor.document.offsetAt(selection.start), rootNode); + let updatedSelection = getUpdatedSelections(editor, selection.start, rootNode); if (updatedSelection) { updatedSelections.push(updatedSelection); } @@ -29,22 +30,16 @@ export function matchTag() { } } -function getUpdatedSelections(editor: vscode.TextEditor, offset: number, rootNode: Node): vscode.Selection { - let currentNode = getNode(rootNode, offset, true); +function getUpdatedSelections(editor: vscode.TextEditor, position: vscode.Position, rootNode: Node): vscode.Selection { + let currentNode = getNode(rootNode, position, true); // If no closing tag or cursor is between open and close tag, then no-op - if (!currentNode.close || (currentNode.open.end < offset && currentNode.close.start > offset)) { + if (!currentNode.close || (position.isAfter(currentNode.open.end) && position.isBefore(currentNode.close.start))) { return; } - if (offset <= currentNode.open.end) { - let matchingPosition = editor.document.positionAt(currentNode.close.start); - return new vscode.Selection(matchingPosition, matchingPosition); - } else { - let matchingPosition = editor.document.positionAt(currentNode.open.start); - return new vscode.Selection(matchingPosition, matchingPosition); - } - + let finalPosition = position.isBeforeOrEqual(currentNode.open.end) ? currentNode.close.start : currentNode.open.start; + return new vscode.Selection(finalPosition, finalPosition); } diff --git a/extensions/emmet/src/mergeLines.ts b/extensions/emmet/src/mergeLines.ts index fd63a2d36d4..6d01107cfe0 100644 --- a/extensions/emmet/src/mergeLines.ts +++ b/extensions/emmet/src/mergeLines.ts @@ -7,6 +7,7 @@ import * as vscode from 'vscode'; import { isStyleSheet, getNode } from './util'; import parse from '@emmetio/html-matcher'; import Node from '@emmetio/node'; +import { DocumentStreamReader } from './bufferStream'; export function mergeLines() { let editor = vscode.window.activeTextEditor; @@ -18,7 +19,7 @@ export function mergeLines() { return; } - let rootNode: Node = parse(editor.document.getText()); + let rootNode: Node = parse(new DocumentStreamReader(editor.document)); editor.edit(editBuilder => { editor.selections.reverse().forEach(selection => { @@ -33,13 +34,13 @@ function getRangesToReplace(document: vscode.TextDocument, selection: vscode.Sel let endNodeToUpdate: Node; if (selection.isEmpty) { - startNodeToUpdate = endNodeToUpdate = getNode(rootNode, document.offsetAt(selection.start)); + startNodeToUpdate = endNodeToUpdate = getNode(rootNode, selection.start); } else { - startNodeToUpdate = getNode(rootNode, document.offsetAt(selection.start), true); - endNodeToUpdate = getNode(rootNode, document.offsetAt(selection.end), true); + startNodeToUpdate = getNode(rootNode, selection.start, true); + endNodeToUpdate = getNode(rootNode, selection.end, true); } - let rangeToReplace = new vscode.Range(document.positionAt(startNodeToUpdate.start), document.positionAt(endNodeToUpdate.end)); + let rangeToReplace = new vscode.Range(startNodeToUpdate.start, endNodeToUpdate.end); let textToReplaceWith = document.getText(rangeToReplace).replace(/\r\n|\n/g, '').replace(/>\s*<'); return [rangeToReplace, textToReplaceWith]; diff --git a/extensions/emmet/src/removeTag.ts b/extensions/emmet/src/removeTag.ts index 600557fd7a1..1987fba5066 100644 --- a/extensions/emmet/src/removeTag.ts +++ b/extensions/emmet/src/removeTag.ts @@ -31,8 +31,7 @@ export function removeTag() { } function getRangeToRemove(editor: vscode.TextEditor, selection: vscode.Selection, indentInSpaces: string): vscode.Range[] { - let offset = editor.document.offsetAt(selection.start); - let [openRange, closeRange] = getOpenCloseRange(editor.document, offset); + let [openRange, closeRange] = getOpenCloseRange(editor.document, selection.start); if (!openRange.contains(selection.start) && !closeRange.contains(selection.start)) { return []; } diff --git a/extensions/emmet/src/selectItem.ts b/extensions/emmet/src/selectItem.ts index 961f3a0dfa5..3280627a63a 100644 --- a/extensions/emmet/src/selectItem.ts +++ b/extensions/emmet/src/selectItem.ts @@ -10,6 +10,7 @@ import { nextItemStylesheet, prevItemStylesheet } from './selectItemStylesheet'; import parseStylesheet from '@emmetio/css-parser'; import parse from '@emmetio/html-matcher'; import Node from '@emmetio/node'; +import { DocumentStreamReader } from './bufferStream'; export function fetchSelectItem(direction: string): void { let editor = vscode.window.activeTextEditor; @@ -31,11 +32,11 @@ export function fetchSelectItem(direction: string): void { parseContent = parse; } - let rootNode: Node = parseContent(editor.document.getText()); + let rootNode: Node = parseContent(new DocumentStreamReader(editor.document)); let newSelections: vscode.Selection[] = []; editor.selections.forEach(selection => { - const selectionStart = editor.document.offsetAt(selection.isReversed ? selection.active : selection.anchor); - const selectionEnd = editor.document.offsetAt(selection.isReversed ? selection.anchor : selection.active); + const selectionStart = selection.isReversed ? selection.active : selection.anchor; + const selectionEnd = selection.isReversed ? selection.anchor : selection.active; let updatedSelection = direction === 'next' ? nextItem(selectionStart, selectionEnd, editor, rootNode) : prevItem(selectionStart, selectionEnd, editor, rootNode); newSelections.push(updatedSelection ? updatedSelection : selection); diff --git a/extensions/emmet/src/selectItemHTML.ts b/extensions/emmet/src/selectItemHTML.ts index 7aad3f9c2a9..7dcd14b740c 100644 --- a/extensions/emmet/src/selectItemHTML.ts +++ b/extensions/emmet/src/selectItemHTML.ts @@ -7,18 +7,18 @@ import * as vscode from 'vscode'; import { getNode, getDeepestNode, findNextWord, findPrevWord } from './util'; import Node from '@emmetio/node'; -export function nextItemHTML(selectionStart: number, selectionEnd: number, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { +export function nextItemHTML(selectionStart: vscode.Position, selectionEnd: vscode.Position, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { let currentNode = getNode(rootNode, selectionEnd); let nextNode: Node; if (currentNode.type !== 'comment') { // If cursor is in the tag name, select tag - if (selectionEnd < currentNode.open.start + currentNode.name.length) { + if (selectionEnd.translate(0, -currentNode.name.length).isBefore(currentNode.open.start)) { return getSelectionFromNode(currentNode, editor.document); } // If cursor is in the open tag, look for attributes - if (selectionEnd < currentNode.open.end) { + if (selectionEnd.isBefore(currentNode.open.end)) { let attrSelection = getNextAttribute(selectionStart, selectionEnd, editor.document, currentNode); if (attrSelection) { return attrSelection; @@ -27,7 +27,7 @@ export function nextItemHTML(selectionStart: number, selectionEnd: number, edito // Get the first child of current node which is right after the cursor and is not a comment nextNode = currentNode.firstChild; - while (nextNode && (nextNode.start < selectionEnd || nextNode.type === 'comment')) { + while (nextNode && (selectionEnd.isAfterOrEqual(nextNode.start) || nextNode.type === 'comment')) { nextNode = nextNode.nextSibling; } } @@ -49,19 +49,19 @@ export function nextItemHTML(selectionStart: number, selectionEnd: number, edito return getSelectionFromNode(nextNode, editor.document); } -export function prevItemHTML(selectionStart: number, selectionEnd: number, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { +export function prevItemHTML(selectionStart: vscode.Position, selectionEnd: vscode.Position, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { let currentNode = getNode(rootNode, selectionStart); let prevNode: Node; - if (currentNode.type !== 'comment' && selectionStart > currentNode.open.start + 1) { + if (currentNode.type !== 'comment' && selectionStart.translate(0, -1).isAfter(currentNode.open.start)) { - if (selectionStart < currentNode.open.end || !currentNode.firstChild) { + if (selectionStart.isBefore(currentNode.open.end) || !currentNode.firstChild) { prevNode = currentNode; } else { // Select the child that appears just before the cursor and is not a comment prevNode = currentNode.firstChild; let oldOption: Node; - while (prevNode.nextSibling && prevNode.nextSibling.end < selectionStart) { + while (prevNode.nextSibling && selectionStart.isAfterOrEqual(prevNode.nextSibling.end)) { if (prevNode && prevNode.type !== 'comment') { oldOption = prevNode; } @@ -92,14 +92,14 @@ export function prevItemHTML(selectionStart: number, selectionEnd: number, edito function getSelectionFromNode(node: Node, document: vscode.TextDocument): vscode.Selection { if (node && node.open) { - let selectionStart = document.positionAt(node.open.start + 1); + let selectionStart = (node.open.start).translate(0, 1); let selectionEnd = selectionStart.translate(0, node.name.length); return new vscode.Selection(selectionStart, selectionEnd); } } -function getNextAttribute(selectionStart: number, selectionEnd: number, document: vscode.TextDocument, node: Node): vscode.Selection { +function getNextAttribute(selectionStart: vscode.Position, selectionEnd: vscode.Position, document: vscode.TextDocument, node: Node): vscode.Selection { if (!node.attributes || node.attributes.length === 0 || node.type === 'comment') { return; @@ -108,19 +108,19 @@ function getNextAttribute(selectionStart: number, selectionEnd: number, document for (let i = 0; i < node.attributes.length; i++) { let attr = node.attributes[i]; - if (selectionEnd < attr.start) { + if (selectionEnd.isBefore(attr.start)) { // select full attr - return new vscode.Selection(document.positionAt(attr.start), document.positionAt(attr.end)); + return new vscode.Selection(attr.start, attr.end); } - if (attr.value.start === attr.value.end) { + if ((attr.value.start).isEqual(attr.value.end)) { // No attr value to select continue; } - if ((selectionStart === attr.start && selectionEnd === attr.end) || selectionEnd < attr.value.start) { + if ((selectionStart.isEqual(attr.start) && selectionEnd.isEqual(attr.end)) || selectionEnd.isBefore(attr.value.start)) { // cursor is in attr name, so select full attr value - return new vscode.Selection(document.positionAt(attr.value.start), document.positionAt(attr.value.end)); + return new vscode.Selection(attr.value.start, attr.value.end); } // Fetch the next word in the attr value @@ -131,26 +131,26 @@ function getNextAttribute(selectionStart: number, selectionEnd: number, document } let pos = undefined; - if (selectionStart === attr.value.start && selectionEnd === attr.value.end) { + if (selectionStart.isEqual(attr.value.start) && selectionEnd.isEqual(attr.value.end)) { pos = -1; } - if (pos === undefined && selectionEnd < attr.end) { - pos = selectionEnd - attr.value.start - 1; + if (pos === undefined && selectionEnd.isBefore(attr.end)) { + pos = selectionEnd.character - attr.value.start.character - 1; } if (pos !== undefined) { - let [newSelectionStart, newSelectionEnd] = findNextWord(attr.value.toString(), pos); - if (newSelectionStart >= 0 && newSelectionEnd >= 0) { - newSelectionStart += attr.value.start; - newSelectionEnd += attr.value.start; - return new vscode.Selection(document.positionAt(newSelectionStart), document.positionAt(newSelectionEnd)); + let [newSelectionStartOffset, newSelectionEndOffset] = findNextWord(attr.value.toString(), pos); + if (newSelectionStartOffset >= 0 && newSelectionEndOffset >= 0) { + const newSelectionStart = (attr.value.start).translate(0, newSelectionStartOffset); + const newSelectionEnd = (attr.value.start).translate(0, newSelectionEndOffset); + return new vscode.Selection(newSelectionStart, newSelectionEnd); } } } } -function getPrevAttribute(selectionStart: number, selectionEnd: number, document: vscode.TextDocument, node: Node): vscode.Selection { +function getPrevAttribute(selectionStart: vscode.Position, selectionEnd: vscode.Position, document: vscode.TextDocument, node: Node): vscode.Selection { if (!node.attributes || node.attributes.length === 0 || node.type === 'comment') { return; @@ -159,32 +159,32 @@ function getPrevAttribute(selectionStart: number, selectionEnd: number, document for (let i = node.attributes.length - 1; i >= 0; i--) { let attr = node.attributes[i]; - if (selectionStart <= attr.start) { + if (selectionStart.isBeforeOrEqual(attr.start)) { continue; } - if (attr.value.start === attr.value.end || selectionStart < attr.value.start) { + if ((attr.value.start).isEqual(attr.value.end) || selectionStart.isBefore(attr.value.start)) { // select full attr - return new vscode.Selection(document.positionAt(attr.start), document.positionAt(attr.end)); + return new vscode.Selection(attr.start, attr.end); } - if (selectionStart === attr.value.start) { - if (selectionEnd >= attr.value.end) { + if (selectionStart.isEqual(attr.value.start)) { + if (selectionEnd.isAfterOrEqual(attr.value.end)) { // select full attr - return new vscode.Selection(document.positionAt(attr.start), document.positionAt(attr.end)); + return new vscode.Selection(attr.start, attr.end); } // select attr value - return new vscode.Selection(document.positionAt(attr.value.start), document.positionAt(attr.value.end)); + return new vscode.Selection(attr.value.start, attr.value.end); } // Fetch the prev word in the attr value - let pos = selectionStart > attr.value.end ? attr.value.toString().length : selectionStart - attr.value.start; - let [newSelectionStart, newSelectionEnd] = findPrevWord(attr.value.toString(), pos); - if (newSelectionStart >= 0 && newSelectionEnd >= 0) { - newSelectionStart += attr.value.start; - newSelectionEnd += attr.value.start; - return new vscode.Selection(document.positionAt(newSelectionStart), document.positionAt(newSelectionEnd)); + let pos = selectionStart.isAfter(attr.value.end) ? attr.value.toString().length : selectionStart.character - attr.value.start.character; + let [newSelectionStartOffset, newSelectionEndOffset] = findPrevWord(attr.value.toString(), pos); + if (newSelectionStartOffset >= 0 && newSelectionEndOffset >= 0) { + const newSelectionStart = (attr.value.start).translate(0, newSelectionStartOffset); + const newSelectionEnd = (attr.value.start).translate(0, newSelectionEndOffset); + return new vscode.Selection(newSelectionStart, newSelectionEnd); } diff --git a/extensions/emmet/src/selectItemStylesheet.ts b/extensions/emmet/src/selectItemStylesheet.ts index 0a11f5e5e33..a40cb9d0736 100644 --- a/extensions/emmet/src/selectItemStylesheet.ts +++ b/extensions/emmet/src/selectItemStylesheet.ts @@ -7,16 +7,19 @@ import * as vscode from 'vscode'; import { getNode, getDeepestNode, findNextWord, findPrevWord } from './util'; import Node from '@emmetio/node'; -export function nextItemStylesheet(startOffset: number, endOffset: number, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { +export function nextItemStylesheet(startOffset: vscode.Position, endOffset: vscode.Position, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { let currentNode = getNode(rootNode, endOffset, true); + if (!currentNode) { + currentNode = rootNode; + } // Full property is selected, so select full property value next - if (currentNode.type === 'property' && startOffset === currentNode.start && endOffset === currentNode.end) { + if (currentNode.type === 'property' && startOffset.isEqual(currentNode.start) && endOffset.isEqual(currentNode.end)) { return getSelectionFromProperty(currentNode, editor.document, startOffset, endOffset, true, 'next'); } // Part or whole of propertyValue is selected, so select the next word in the propertyValue - if (currentNode.type === 'property' && startOffset >= currentNode.valueToken.start && endOffset <= currentNode.valueToken.end) { + if (currentNode.type === 'property' && startOffset.isAfterOrEqual(currentNode.valueToken.start) && endOffset.isBeforeOrEqual(currentNode.valueToken.end)) { let singlePropertyValue = getSelectionFromProperty(currentNode, editor.document, startOffset, endOffset, false, 'next'); if (singlePropertyValue) { return singlePropertyValue; @@ -24,14 +27,14 @@ export function nextItemStylesheet(startOffset: number, endOffset: number, edito } // Cursor is in the selector or in a property - if ((currentNode.type === 'rule' && endOffset < currentNode.selectorToken.end) - || (currentNode.type === 'property' && endOffset < currentNode.valueToken.end)) { + if ((currentNode.type === 'rule' && endOffset.isBefore(currentNode.selectorToken.end)) + || (currentNode.type === 'property' && endOffset.isBefore(currentNode.valueToken.end))) { return getSelectionFromNode(currentNode, editor.document); } // Get the first child of current node which is right after the cursor let nextNode = currentNode.firstChild; - while (nextNode && endOffset >= nextNode.end) { + while (nextNode && endOffset.isAfterOrEqual(nextNode.end)) { nextNode = nextNode.nextSibling; } @@ -45,32 +48,32 @@ export function nextItemStylesheet(startOffset: number, endOffset: number, edito } -export function prevItemStylesheet(startOffset: number, endOffset: number, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { +export function prevItemStylesheet(startOffset: vscode.Position, endOffset: vscode.Position, editor: vscode.TextEditor, rootNode: Node): vscode.Selection { let currentNode = getNode(rootNode, startOffset); if (!currentNode) { currentNode = rootNode; } // Full property value is selected, so select the whole property next - if (currentNode.type === 'property' && startOffset === currentNode.valueToken.start && endOffset === currentNode.valueToken.end) { + if (currentNode.type === 'property' && startOffset.isEqual(currentNode.valueToken.start) && endOffset.isEqual(currentNode.valueToken.end)) { return getSelectionFromNode(currentNode, editor.document); } // Part of propertyValue is selected, so select the prev word in the propertyValue - if (currentNode.type === 'property' && startOffset >= currentNode.valueToken.start && endOffset <= currentNode.valueToken.end) { + if (currentNode.type === 'property' && startOffset.isAfterOrEqual(currentNode.valueToken.start) && endOffset.isBeforeOrEqual(currentNode.valueToken.end)) { let singlePropertyValue = getSelectionFromProperty(currentNode, editor.document, startOffset, endOffset, false, 'prev'); if (singlePropertyValue) { return singlePropertyValue; } } - if (currentNode.type === 'property' || !currentNode.firstChild || (currentNode.type === 'rule' && startOffset <= currentNode.firstChild.start)) { + if (currentNode.type === 'property' || !currentNode.firstChild || (currentNode.type === 'rule' && startOffset.isBeforeOrEqual(currentNode.firstChild.start))) { return getSelectionFromNode(currentNode, editor.document); } // Select the child that appears just before the cursor let prevNode = currentNode.firstChild; - while (prevNode.nextSibling && prevNode.nextSibling.end <= startOffset) { + while (prevNode.nextSibling && startOffset.isAfterOrEqual(prevNode.nextSibling.end)) { prevNode = prevNode.nextSibling; } prevNode = getDeepestNode(prevNode); @@ -86,47 +89,47 @@ function getSelectionFromNode(node: Node, document: vscode.TextDocument): vscode } let nodeToSelect = node.type === 'rule' ? node.selectorToken : node; - return new vscode.Selection(document.positionAt(nodeToSelect.start), document.positionAt(nodeToSelect.end)); + return new vscode.Selection(nodeToSelect.start, nodeToSelect.end); } -function getSelectionFromProperty(node: Node, document: vscode.TextDocument, selectionStart: number, selectionEnd: number, selectFullValue: boolean, direction: string): vscode.Selection { +function getSelectionFromProperty(node: Node, document: vscode.TextDocument, selectionStart: vscode.Position, selectionEnd: vscode.Position, selectFullValue: boolean, direction: string): vscode.Selection { if (!node || node.type !== 'property') { return; } let propertyValue = node.valueToken.stream.substring(node.valueToken.start, node.valueToken.end); - selectFullValue = selectFullValue || (direction === 'prev' && selectionStart === node.valueToken.start && selectionEnd < node.valueToken.end); + selectFullValue = selectFullValue || (direction === 'prev' && selectionStart.isEqual(node.valueToken.start) && selectionEnd.isBefore(node.valueToken.end)); if (selectFullValue) { - return new vscode.Selection(document.positionAt(node.valueToken.start), document.positionAt(node.valueToken.end)); + return new vscode.Selection(node.valueToken.start, node.valueToken.end); } let pos; if (direction === 'prev') { - if (selectionStart === node.valueToken.start) { + if (selectionStart.isEqual(node.valueToken.start)) { return; } - pos = selectionStart > node.valueToken.end ? propertyValue.length : selectionStart - node.valueToken.start; + pos = selectionStart.isAfter(node.valueToken.end) ? propertyValue.length : selectionStart.character - node.valueToken.start.character; } if (direction === 'next') { - if (selectionEnd === node.valueToken.end && (selectionStart > node.valueToken.start || propertyValue.indexOf(' ') === -1)) { + if (selectionEnd.isEqual(node.valueToken.end) && (selectionStart.isAfter(node.valueToken.start) || propertyValue.indexOf(' ') === -1)) { return; } - pos = selectionEnd === node.valueToken.end ? -1 : selectionEnd - node.valueToken.start - 1; + pos = selectionEnd.isEqual(node.valueToken.end) ? -1 : selectionEnd.character - node.valueToken.start.character - 1; } - let [newSelectionStart, newSelectionEnd] = direction === 'prev' ? findPrevWord(propertyValue, pos) : findNextWord(propertyValue, pos); - if (!newSelectionStart && !newSelectionEnd) { + let [newSelectionStartOffset, newSelectionEndOffset] = direction === 'prev' ? findPrevWord(propertyValue, pos) : findNextWord(propertyValue, pos); + if (!newSelectionStartOffset && !newSelectionEndOffset) { return; } - newSelectionStart += node.valueToken.start; - newSelectionEnd += node.valueToken.start; + const newSelectionStart = (node.valueToken.start).translate(0, newSelectionStartOffset); + const newSelectionEnd = (node.valueToken.start).translate(0, newSelectionEndOffset); - return new vscode.Selection(document.positionAt(newSelectionStart), document.positionAt(newSelectionEnd)); + return new vscode.Selection(newSelectionStart, newSelectionEnd); } diff --git a/extensions/emmet/src/splitJoinTag.ts b/extensions/emmet/src/splitJoinTag.ts index 1886ca2472c..cbd02ef81cd 100644 --- a/extensions/emmet/src/splitJoinTag.ts +++ b/extensions/emmet/src/splitJoinTag.ts @@ -7,6 +7,7 @@ import * as vscode from 'vscode'; import { isStyleSheet, getNode } from './util'; import parse from '@emmetio/html-matcher'; import Node from '@emmetio/node'; +import { DocumentStreamReader } from './bufferStream'; export function splitJoinTag() { let editor = vscode.window.activeTextEditor; @@ -18,7 +19,7 @@ export function splitJoinTag() { return; } - let rootNode: Node = parse(editor.document.getText()); + let rootNode: Node = parse(new DocumentStreamReader(editor.document)); editor.edit(editBuilder => { editor.selections.reverse().forEach(selection => { @@ -29,23 +30,24 @@ export function splitJoinTag() { } function getRangesToReplace(document: vscode.TextDocument, selection: vscode.Selection, rootNode: Node): [vscode.Range, string] { - let offset = document.offsetAt(selection.start); - let nodeToUpdate: Node = getNode(rootNode, offset); + let nodeToUpdate: Node = getNode(rootNode, selection.start); let rangeToReplace: vscode.Range; let textToReplaceWith: string; if (!nodeToUpdate.close) { // Split Tag - let nodeText = document.getText(new vscode.Range(document.positionAt(nodeToUpdate.start), document.positionAt(nodeToUpdate.end))); + let nodeText = document.getText(new vscode.Range(nodeToUpdate.start, nodeToUpdate.end)); let m = nodeText.match(/(\s*\/)?>$/); - let end = nodeToUpdate.open.end; - let start = m ? end - m[0].length : end; + let end = nodeToUpdate.end; + let start = m ? end.translate(0, -m[0].length) : end; - rangeToReplace = new vscode.Range(document.positionAt(start), document.positionAt(end)); + rangeToReplace = new vscode.Range(start, end); textToReplaceWith = `>`; } else { // Join Tag - rangeToReplace = new vscode.Range(document.positionAt(nodeToUpdate.open.end - 1), document.positionAt(nodeToUpdate.close.end)); + let start = (nodeToUpdate.open.end).translate(0, -1); + let end = nodeToUpdate.end; + rangeToReplace = new vscode.Range(start, end); textToReplaceWith = '/>'; } diff --git a/extensions/emmet/src/toggleComment.ts b/extensions/emmet/src/toggleComment.ts index 1849535420c..6a91dc081e4 100644 --- a/extensions/emmet/src/toggleComment.ts +++ b/extensions/emmet/src/toggleComment.ts @@ -8,7 +8,7 @@ import { getNode, isStyleSheet, getNodesInBetween } from './util'; import parse from '@emmetio/html-matcher'; import parseStylesheet from '@emmetio/css-parser'; import Node from '@emmetio/node'; - +import { DocumentStreamReader } from './bufferStream'; const startCommentStylesheet = '/*'; const endCommentStylesheet = '*/'; @@ -39,7 +39,7 @@ export function toggleComment() { endComment = endCommentHTML; } - let rootNode = parseContent(editor.document.getText()); + let rootNode = parseContent(new DocumentStreamReader(editor.document)); editor.edit(editBuilder => { editor.selections.reverse().forEach(selection => { @@ -58,8 +58,8 @@ export function toggleComment() { } function toggleCommentHTML(document: vscode.TextDocument, selection: vscode.Selection, rootNode: Node): [vscode.Range[], vscode.Range] { - const selectionStart = document.offsetAt(selection.isReversed ? selection.active : selection.anchor); - const selectionEnd = document.offsetAt(selection.isReversed ? selection.anchor : selection.active); + const selectionStart = selection.isReversed ? selection.active : selection.anchor; + const selectionEnd = selection.isReversed ? selection.anchor : selection.active; let startNode = getNode(rootNode, selectionStart, true); let endNode = getNode(rootNode, selectionEnd, true); @@ -79,7 +79,7 @@ function toggleCommentHTML(document: vscode.TextDocument, selection: vscode.Sele return [rangesToUnComment, null]; } - let rangeToComment = new vscode.Range(document.positionAt(allNodes[0].start), document.positionAt(allNodes[allNodes.length - 1].end)); + let rangeToComment = new vscode.Range(allNodes[0].start, allNodes[allNodes.length - 1].end); return [rangesToUnComment, rangeToComment]; } @@ -88,7 +88,7 @@ function getRangesToUnCommentHTML(node: Node, document: vscode.TextDocument): vs // If current node is commented, then uncomment and return if (node.type === 'comment') { - rangesToUnComment.push(new vscode.Range(document.positionAt(node.start), document.positionAt(node.end))); + rangesToUnComment.push(new vscode.Range(node.start, node.end)); return rangesToUnComment; } @@ -103,8 +103,8 @@ function getRangesToUnCommentHTML(node: Node, document: vscode.TextDocument): vs function toggleCommentStylesheet(document: vscode.TextDocument, selection: vscode.Selection, rootNode: Node): [vscode.Range[], vscode.Range] { - const selectionStart = document.offsetAt(selection.isReversed ? selection.active : selection.anchor); - const selectionEnd = document.offsetAt(selection.isReversed ? selection.anchor : selection.active); + const selectionStart = selection.isReversed ? selection.active : selection.anchor; + const selectionEnd = selection.isReversed ? selection.anchor : selection.active; let startNode = getNode(rootNode, selectionStart, true); let endNode = getNode(rootNode, selectionEnd, true); @@ -114,19 +114,18 @@ function toggleCommentStylesheet(document: vscode.TextDocument, selection: vscod // Uncomment the comments that intersect with the selection. rootNode.comments.forEach(comment => { - let commentStart = document.positionAt(comment.start); - let commentEnd = document.positionAt(comment.end); - if (!isFirstNodeCommented) { - isFirstNodeCommented = (comment.start <= selectionStart && comment.end >= selectionEnd); + isFirstNodeCommented = (selectionStart.isAfterOrEqual(comment.start) && selectionEnd.isBefore(comment.end)); } - if (selection.contains(commentStart) || selection.contains(commentEnd) || (comment.start <= selectionStart && comment.end >= selectionEnd)) { - rangesToUnComment.push(new vscode.Range(document.positionAt(comment.start), document.positionAt(comment.end))); + if (selection.contains(comment.start) + || selection.contains(comment.end) + || (selectionStart.isAfterOrEqual(comment.start) && selectionEnd.isBefore(comment.end))) { + rangesToUnComment.push(new vscode.Range(comment.start, comment.end)); } }); - let rangeToComment = isFirstNodeCommented ? null : new vscode.Range(document.positionAt(startNode.start), document.positionAt(endNode.end)); + let rangeToComment = isFirstNodeCommented ? null : new vscode.Range(startNode ? startNode.start : selectionStart, endNode ? endNode.end : selectionEnd); return [rangesToUnComment, rangeToComment]; diff --git a/extensions/emmet/src/updateTag.ts b/extensions/emmet/src/updateTag.ts index 43efb2cc285..b4450eba283 100644 --- a/extensions/emmet/src/updateTag.ts +++ b/extensions/emmet/src/updateTag.ts @@ -7,6 +7,7 @@ import * as vscode from 'vscode'; import { getNode } from './util'; import parse from '@emmetio/html-matcher'; import Node from '@emmetio/node'; +import { DocumentStreamReader } from './bufferStream'; export function updateTag(tagName: string) { let editor = vscode.window.activeTextEditor; @@ -15,7 +16,7 @@ export function updateTag(tagName: string) { return; } - let rootNode: Node = parse(editor.document.getText()); + let rootNode: Node = parse(new DocumentStreamReader(editor.document)); let rangesToUpdate = []; editor.selections.reverse().forEach(selection => { rangesToUpdate = rangesToUpdate.concat(getRangesToUpdate(editor, selection, rootNode)); @@ -29,16 +30,15 @@ export function updateTag(tagName: string) { } function getRangesToUpdate(editor: vscode.TextEditor, selection: vscode.Selection, rootNode: Node): vscode.Range[] { - let offset = editor.document.offsetAt(selection.start); - let nodeToUpdate = getNode(rootNode, offset); + let nodeToUpdate = getNode(rootNode, selection.start); - let openStart = editor.document.positionAt(nodeToUpdate.open.start + 1); + let openStart = (nodeToUpdate.open.start).translate(0, 1); let openEnd = openStart.translate(0, nodeToUpdate.name.length); let ranges = [new vscode.Range(openStart, openEnd)]; if (nodeToUpdate.close) { - let closeStart = editor.document.positionAt(nodeToUpdate.close.start + 2); - let closeEnd = editor.document.positionAt(nodeToUpdate.close.end - 1); + let closeStart = (nodeToUpdate.close.start).translate(0, 2); + let closeEnd = (nodeToUpdate.close.end).translate(0, -1); ranges.push(new vscode.Range(closeStart, closeEnd)); } return ranges; diff --git a/extensions/emmet/src/util.ts b/extensions/emmet/src/util.ts index bc3f3893e89..a6200a2455d 100644 --- a/extensions/emmet/src/util.ts +++ b/extensions/emmet/src/util.ts @@ -7,7 +7,7 @@ import * as vscode from 'vscode'; import parse from '@emmetio/html-matcher'; import Node from '@emmetio/node'; import * as extract from '@emmetio/extract-abbreviation'; - +import { DocumentStreamReader } from './bufferStream'; export function validate(allowStylesheet: boolean = true): boolean { let editor = vscode.window.activeTextEditor; @@ -80,24 +80,26 @@ export function getProfile(syntax: string): any { return newOptions; } -export function getOpenCloseRange(document: vscode.TextDocument, offset: number): [vscode.Range, vscode.Range] { - let rootNode: Node = parse(document.getText()); - let nodeToUpdate = getNode(rootNode, offset); - let openRange = new vscode.Range(document.positionAt(nodeToUpdate.open.start), document.positionAt(nodeToUpdate.open.end)); +export function getOpenCloseRange(document: vscode.TextDocument, position: vscode.Position): [vscode.Range, vscode.Range] { + let rootNode: Node = parse(new DocumentStreamReader(document)); + let nodeToUpdate = getNode(rootNode, position); + let openRange = new vscode.Range(nodeToUpdate.open.start, nodeToUpdate.open.end); let closeRange = null; if (nodeToUpdate.close) { - closeRange = new vscode.Range(document.positionAt(nodeToUpdate.close.start), document.positionAt(nodeToUpdate.close.end)); + closeRange = new vscode.Range(nodeToUpdate.close.start, nodeToUpdate.close.end); } return [openRange, closeRange]; } -export function getNode(root: Node, offset: number, includeNodeBoundary: boolean = false) { +export function getNode(root: Node, position: vscode.Position, includeNodeBoundary: boolean = false) { let currentNode: Node = root.firstChild; let foundNode: Node = null; while (currentNode) { - if ((currentNode.start < offset && currentNode.end > offset) - || (includeNodeBoundary && (currentNode.start <= offset && currentNode.end >= offset))) { + const nodeStart: vscode.Position = currentNode.start; + const nodeEnd: vscode.Position = currentNode.end; + if ((nodeStart.isBefore(position) && nodeEnd.isAfter(position)) + || (includeNodeBoundary && (nodeStart.isBeforeOrEqual(position) && nodeEnd.isAfterOrEqual(position)))) { foundNode = currentNode; // Dig deeper @@ -110,14 +112,6 @@ export function getNode(root: Node, offset: number, includeNodeBoundary: boolean return foundNode; } -export function getNodeOuterSelection(document: vscode.TextDocument, node: Node): vscode.Selection { - return new vscode.Selection(document.positionAt(node.start), document.positionAt(node.end)); -} - -export function getNodeInnerSelection(document: vscode.TextDocument, node: Node): vscode.Selection { - return new vscode.Selection(document.positionAt(node.open.end), document.positionAt(node.close.start)); -} - export function extractAbbreviation(position: vscode.Position): [vscode.Range, string] { let editor = vscode.window.activeTextEditor; let currentLine = editor.document.lineAt(position.line).text; @@ -229,32 +223,32 @@ export function getNodesInBetween(node1: Node, node2: Node): Node[] { } // node2 is ancestor of node1 - if (node2.start < node1.start) { + if (node2.start.isBefore(node1.start)) { return [node2]; } // node1 is ancestor of node2 - if (node2.start < node1.end) { + if (node2.start.isBefore(node1.end)) { return [node1]; } // Get the highest ancestor of node1 that should be commented - while (node1.parent && node1.parent.end < node2.start) { + while (node1.parent && node1.parent.end.isBefore(node2.start)) { node1 = node1.parent; } // Get the highest ancestor of node2 that should be commented - while (node2.parent && node2.parent.start > node1.start) { + while (node2.parent && node2.parent.start.isAfter(node1.start)) { node2 = node2.parent; } return getNextSiblingsTillPosition(node1, node2.end); } -function getNextSiblingsTillPosition(node: Node, position: number): Node[] { +function getNextSiblingsTillPosition(node: Node, position: vscode.Position): Node[] { let siblings: Node[] = []; let currentNode = node; - while (currentNode && currentNode.start < position) { + while (currentNode && position.isAfter(currentNode.start)) { siblings.push(currentNode); currentNode = currentNode.nextSibling; } @@ -265,5 +259,5 @@ export function sameNodes(node1: Node, node2: Node): boolean { if (!node1 || !node2) { return false; } - return node1.start === node2.start && node1.end === node2.end; + return (node1.start).isEqual(node2.start) && (node1.end).isEqual(node2.end); } \ No newline at end of file -- GitLab From 720c49692f74285178902d9ef8f1db571f3cd92a Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Thu, 15 Jun 2017 18:42:08 +0200 Subject: [PATCH 0900/1347] #28538 Simplify workspace configuration service api --- .../browser/standalone/simpleServices.ts | 6 ++++- .../configuration/common/configuration.ts | 5 ++++ .../node/configurationService.ts | 6 ++++- .../test/common/testConfigurationService.ts | 6 ++++- .../electron-browser/telemetryService.test.ts | 1 + src/vs/workbench/api/node/extHost.protocol.ts | 6 ++--- .../api/node/extHostConfiguration.ts | 10 +++---- .../terminalConfigHelper.test.ts | 1 + .../configuration/common/configuration.ts | 26 +------------------ .../configuration/node/configuration.ts | 6 ++--- .../node/configurationResolverService.test.ts | 1 + .../api/extHostConfiguration.test.ts | 6 ++--- 12 files changed, 38 insertions(+), 42 deletions(-) diff --git a/src/vs/editor/browser/standalone/simpleServices.ts b/src/vs/editor/browser/standalone/simpleServices.ts index 92970b62b40..97d0459cc8c 100644 --- a/src/vs/editor/browser/standalone/simpleServices.ts +++ b/src/vs/editor/browser/standalone/simpleServices.ts @@ -8,7 +8,7 @@ import { Schemas } from 'vs/base/common/network'; import Severity from 'vs/base/common/severity'; import URI from 'vs/base/common/uri'; import { TPromise } from 'vs/base/common/winjs.base'; -import { IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, getConfigurationValue, IConfigurationKeys } from 'vs/platform/configuration/common/configuration'; +import { IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, getConfigurationValue, IConfigurationKeys, IConfigurationValues } from 'vs/platform/configuration/common/configuration'; import { IEditor, IEditorInput, IEditorOptions, IEditorService, IResourceInput, Position } from 'vs/platform/editor/common/editor'; import { ICommandService, ICommand, ICommandEvent, ICommandHandler, CommandsRegistry } from 'vs/platform/commands/common/commands'; import { AbstractKeybindingService } from 'vs/platform/keybinding/common/abstractKeybindingService'; @@ -458,6 +458,10 @@ export class SimpleConfigurationService implements IConfigurationService { public keys(): IConfigurationKeys { return { default: [], user: [], workspace: [] }; } + + public values(): IConfigurationValues { + return {}; + } } export class SimpleMenuService implements IMenuService { diff --git a/src/vs/platform/configuration/common/configuration.ts b/src/vs/platform/configuration/common/configuration.ts index 988c167e791..018e7339ab7 100644 --- a/src/vs/platform/configuration/common/configuration.ts +++ b/src/vs/platform/configuration/common/configuration.ts @@ -54,6 +54,11 @@ export interface IConfigurationService { * Event that fires when the configuration changes. */ onDidUpdateConfiguration: Event; + + /** + * Returns the defined values of configurations in the different scopes. + */ + values(): IConfigurationValues; } export enum ConfigurationSource { diff --git a/src/vs/platform/configuration/node/configurationService.ts b/src/vs/platform/configuration/node/configurationService.ts index c89737df2a2..a241cc876a3 100644 --- a/src/vs/platform/configuration/node/configurationService.ts +++ b/src/vs/platform/configuration/node/configurationService.ts @@ -9,7 +9,7 @@ import { ConfigWatcher } from 'vs/base/node/config'; import { Registry } from 'vs/platform/platform'; import { IConfigurationRegistry, Extensions } from 'vs/platform/configuration/common/configurationRegistry'; import { IDisposable, toDisposable, Disposable } from 'vs/base/common/lifecycle'; -import { ConfigurationSource, IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, IConfigurationKeys, ConfigurationModel, IConfigurationOptions, Configuration } from 'vs/platform/configuration/common/configuration'; +import { ConfigurationSource, IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, IConfigurationKeys, ConfigurationModel, IConfigurationOptions, Configuration, IConfigurationValues } from 'vs/platform/configuration/common/configuration'; import { CustomConfigurationModel, DefaultConfigurationModel } from 'vs/platform/configuration/common/model'; import Event, { Emitter } from 'vs/base/common/event'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; @@ -77,6 +77,10 @@ export class ConfigurationService extends Disposable implements IConfiguratio return this.getConfiguration2().keys(); } + public values(): IConfigurationValues { + return this._configuration.values(); + } + public getConfiguration2(): Configuration { return this._configuration || (this._configuration = this.consolidateConfigurations()); } diff --git a/src/vs/platform/configuration/test/common/testConfigurationService.ts b/src/vs/platform/configuration/test/common/testConfigurationService.ts index 06be8aa2346..7d493764ef2 100644 --- a/src/vs/platform/configuration/test/common/testConfigurationService.ts +++ b/src/vs/platform/configuration/test/common/testConfigurationService.ts @@ -8,7 +8,7 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { EventEmitter } from 'vs/base/common/eventEmitter'; import { getConfigurationKeys } from 'vs/platform/configuration/common/model'; -import { IConfigurationService, getConfigurationValue, IConfigurationValue, IConfigurationKeys } from 'vs/platform/configuration/common/configuration'; +import { IConfigurationService, getConfigurationValue, IConfigurationValue, IConfigurationKeys, IConfigurationValues } from 'vs/platform/configuration/common/configuration'; export class TestConfigurationService extends EventEmitter implements IConfigurationService { public _serviceBrand: any; @@ -48,4 +48,8 @@ export class TestConfigurationService extends EventEmitter implements IConfigura workspace: [] }; } + + public values(): IConfigurationValues { + return {}; + } } diff --git a/src/vs/platform/telemetry/test/electron-browser/telemetryService.test.ts b/src/vs/platform/telemetry/test/electron-browser/telemetryService.test.ts index 814428897c6..478619bb599 100644 --- a/src/vs/platform/telemetry/test/electron-browser/telemetryService.test.ts +++ b/src/vs/platform/telemetry/test/electron-browser/telemetryService.test.ts @@ -693,6 +693,7 @@ suite('TelemetryService', () => { }; }, keys() { return { default: [], user: [], workspace: [] }; }, + values() { return {}; }, onDidUpdateConfiguration: emitter.event }); diff --git a/src/vs/workbench/api/node/extHost.protocol.ts b/src/vs/workbench/api/node/extHost.protocol.ts index 9cb2b395ee6..bed2bbb9b76 100644 --- a/src/vs/workbench/api/node/extHost.protocol.ts +++ b/src/vs/workbench/api/node/extHost.protocol.ts @@ -30,7 +30,7 @@ import { IResourceEdit } from 'vs/editor/common/services/bulkEdit'; import { ITextSource } from 'vs/editor/common/model/textSource'; import { ConfigurationTarget } from 'vs/workbench/services/configuration/common/configurationEditing'; -import { IWorkspaceConfigurationValues } from 'vs/workbench/services/configuration/common/configuration'; +import { IConfigurationValues } from 'vs/platform/configuration/common/configuration'; import { IPickOpenEntry, IPickOptions } from 'vs/platform/quickOpen/common/quickOpen'; import { SaveReason } from 'vs/workbench/services/textfile/common/textfiles'; @@ -67,7 +67,7 @@ export interface IInitData { environment: IEnvironment; workspace: IWorkspaceData; extensions: IExtensionDescription[]; - configuration: IWorkspaceConfigurationValues; + configuration: IConfigurationValues; telemetryInfo: ITelemetryInfo; } @@ -349,7 +349,7 @@ export abstract class ExtHostCommandsShape { } export abstract class ExtHostConfigurationShape { - $acceptConfigurationChanged(values: IWorkspaceConfigurationValues) { throw ni(); } + $acceptConfigurationChanged(values: IConfigurationValues) { throw ni(); } } export abstract class ExtHostDiagnosticsShape { diff --git a/src/vs/workbench/api/node/extHostConfiguration.ts b/src/vs/workbench/api/node/extHostConfiguration.ts index 84b4d218335..3147509dde8 100644 --- a/src/vs/workbench/api/node/extHostConfiguration.ts +++ b/src/vs/workbench/api/node/extHostConfiguration.ts @@ -8,8 +8,8 @@ import { mixin } from 'vs/base/common/objects'; import Event, { Emitter } from 'vs/base/common/event'; import { WorkspaceConfiguration } from 'vscode'; import { ExtHostConfigurationShape, MainThreadConfigurationShape } from './extHost.protocol'; +import { IConfigurationValues } from 'vs/platform/configuration/common/configuration'; import { ConfigurationTarget } from 'vs/workbench/services/configuration/common/configurationEditing'; -import { IWorkspaceConfigurationValues } from 'vs/workbench/services/configuration/common/configuration'; import { toValuesTree } from 'vs/platform/configuration/common/model'; function lookUp(tree: any, key: string) { @@ -24,11 +24,11 @@ function lookUp(tree: any, key: string) { } interface UsefulConfiguration { - data: IWorkspaceConfigurationValues; + data: IConfigurationValues; valueTree: any; } -function createUsefulConfiguration(data: IWorkspaceConfigurationValues): { data: IWorkspaceConfigurationValues, valueTree: any } { +function createUsefulConfiguration(data: IConfigurationValues): { data: IConfigurationValues, valueTree: any } { const valueMap: { [key: string]: any } = Object.create(null); for (let key in data) { if (Object.prototype.hasOwnProperty.call(data, key)) { @@ -48,7 +48,7 @@ export class ExtHostConfiguration extends ExtHostConfigurationShape { private _proxy: MainThreadConfigurationShape; private _configuration: UsefulConfiguration; - constructor(proxy: MainThreadConfigurationShape, data: IWorkspaceConfigurationValues) { + constructor(proxy: MainThreadConfigurationShape, data: IConfigurationValues) { super(); this._proxy = proxy; this._configuration = createUsefulConfiguration(data); @@ -58,7 +58,7 @@ export class ExtHostConfiguration extends ExtHostConfigurationShape { return this._onDidChangeConfiguration && this._onDidChangeConfiguration.event; } - public $acceptConfigurationChanged(data: IWorkspaceConfigurationValues) { + public $acceptConfigurationChanged(data: IConfigurationValues) { this._configuration = createUsefulConfiguration(data); this._onDidChangeConfiguration.fire(undefined); } diff --git a/src/vs/workbench/parts/terminal/test/electron-browser/terminalConfigHelper.test.ts b/src/vs/workbench/parts/terminal/test/electron-browser/terminalConfigHelper.test.ts index 80da83ff489..5c907435679 100644 --- a/src/vs/workbench/parts/terminal/test/electron-browser/terminalConfigHelper.test.ts +++ b/src/vs/workbench/parts/terminal/test/electron-browser/terminalConfigHelper.test.ts @@ -20,6 +20,7 @@ class MockConfigurationService implements IConfigurationService { public reloadConfiguration(section?: string): TPromise { return TPromise.as(this.getConfiguration()); } public lookup(key: string) { return { value: getConfigurationValue(this.getConfiguration(), key), default: getConfigurationValue(this.getConfiguration(), key), user: getConfigurationValue(this.getConfiguration(), key), workspace: void 0 }; } public keys() { return { default: [], user: [], workspace: [] }; } + public values() { return {}; } public getConfiguration(): any { return this.configuration; } public onDidUpdateConfiguration() { return { dispose() { } }; } } diff --git a/src/vs/workbench/services/configuration/common/configuration.ts b/src/vs/workbench/services/configuration/common/configuration.ts index 0038822ee90..c38ff73b6d6 100644 --- a/src/vs/workbench/services/configuration/common/configuration.ts +++ b/src/vs/workbench/services/configuration/common/configuration.ts @@ -3,7 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import { IConfigurationService, IConfigurationValue, IConfigurationKeys } from 'vs/platform/configuration/common/configuration'; +import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; export const CONFIG_DEFAULT_NAME = 'settings'; @@ -12,8 +12,6 @@ export const WORKSPACE_CONFIG_DEFAULT_PATH = `${WORKSPACE_CONFIG_FOLDER_DEFAULT_ export const IWorkspaceConfigurationService = createDecorator('configurationService'); -export type IWorkspaceConfigurationValues = { [key: string]: IWorkspaceConfigurationValue }; - export interface IWorkspaceConfigurationService extends IConfigurationService { /** @@ -21,28 +19,6 @@ export interface IWorkspaceConfigurationService extends IConfigurationService { */ getUnsupportedWorkspaceKeys(): string[]; - /** - * Override for the IConfigurationService#lookup() method that adds information about workspace settings. - */ - lookup(key: string): IWorkspaceConfigurationValue; - - /** - * Override for the IConfigurationService#keys() method that adds information about workspace settings. - */ - keys(): IWorkspaceConfigurationKeys; - - /** - * Returns the defined values of configurations in the different scopes. - */ - values(): IWorkspaceConfigurationValues; -} - -export interface IWorkspaceConfigurationValue extends IConfigurationValue { - workspace: T; -} - -export interface IWorkspaceConfigurationKeys extends IConfigurationKeys { - workspace: string[]; } export const WORKSPACE_STANDALONE_CONFIGURATIONS = { diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index 03d82070727..d165e84b81f 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -24,8 +24,8 @@ import { isLinux } from 'vs/base/common/platform'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { CustomConfigurationModel } from 'vs/platform/configuration/common/model'; import { ScopedConfigurationModel, FolderConfigurationModel, FolderSettingsModel } from 'vs/workbench/services/configuration/common/configurationModels'; -import { IConfigurationServiceEvent, ConfigurationSource, IConfigurationKeys, IConfigurationValue, ConfigurationModel, IConfigurationOptions, Configuration as BaseConfiguration } from 'vs/platform/configuration/common/configuration'; -import { IWorkspaceConfigurationService, WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME, WORKSPACE_STANDALONE_CONFIGURATIONS, WORKSPACE_CONFIG_DEFAULT_PATH, IWorkspaceConfigurationValues } from 'vs/workbench/services/configuration/common/configuration'; +import { IConfigurationServiceEvent, ConfigurationSource, IConfigurationKeys, IConfigurationValue, ConfigurationModel, IConfigurationOptions, Configuration as BaseConfiguration, IConfigurationValues } from 'vs/platform/configuration/common/configuration'; +import { IWorkspaceConfigurationService, WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME, WORKSPACE_STANDALONE_CONFIGURATIONS, WORKSPACE_CONFIG_DEFAULT_PATH } from 'vs/workbench/services/configuration/common/configuration'; import { ConfigurationService as GlobalConfigurationService } from 'vs/platform/configuration/node/configurationService'; import { createHash } from "crypto"; import { basename } from "path"; @@ -211,7 +211,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp return this._configuration.keys(); } - public values(): IWorkspaceConfigurationValues { + public values(): IConfigurationValues { return this._configuration.values(); } diff --git a/src/vs/workbench/services/configurationResolver/test/node/configurationResolverService.test.ts b/src/vs/workbench/services/configurationResolver/test/node/configurationResolverService.test.ts index df5b6f68b63..dfc7ac05d9a 100644 --- a/src/vs/workbench/services/configurationResolver/test/node/configurationResolverService.test.ts +++ b/src/vs/workbench/services/configurationResolver/test/node/configurationResolverService.test.ts @@ -342,6 +342,7 @@ class MockConfigurationService implements IConfigurationService { public reloadConfiguration(section?: string): TPromise { return TPromise.as(this.getConfiguration()); } public lookup(key: string) { return { value: getConfigurationValue(this.getConfiguration(), key), default: getConfigurationValue(this.getConfiguration(), key), user: getConfigurationValue(this.getConfiguration(), key), workspace: void 0 }; } public keys() { return { default: [], user: [], workspace: [] }; } + public values() { return {}; } public getConfiguration(): any { return this.configuration; } public onDidUpdateConfiguration() { return { dispose() { } }; } } diff --git a/src/vs/workbench/test/electron-browser/api/extHostConfiguration.test.ts b/src/vs/workbench/test/electron-browser/api/extHostConfiguration.test.ts index ff48c392466..d449d5627ad 100644 --- a/src/vs/workbench/test/electron-browser/api/extHostConfiguration.test.ts +++ b/src/vs/workbench/test/electron-browser/api/extHostConfiguration.test.ts @@ -10,7 +10,7 @@ import { ExtHostConfiguration } from 'vs/workbench/api/node/extHostConfiguration import { MainThreadConfigurationShape } from 'vs/workbench/api/node/extHost.protocol'; import { TPromise } from 'vs/base/common/winjs.base'; import { ConfigurationTarget, ConfigurationEditingErrorCode, IConfigurationEditingError } from 'vs/workbench/services/configuration/common/configurationEditing'; -import { IWorkspaceConfigurationValues, IWorkspaceConfigurationValue } from 'vs/workbench/services/configuration/common/configuration'; +import { IConfigurationValues, IConfigurationValue } from 'vs/platform/configuration/common/configuration'; suite('ExtHostConfiguration', function () { @@ -22,14 +22,14 @@ suite('ExtHostConfiguration', function () { } }; - function createExtHostConfiguration(data: IWorkspaceConfigurationValues = Object.create(null), shape?: MainThreadConfigurationShape) { + function createExtHostConfiguration(data: IConfigurationValues = Object.create(null), shape?: MainThreadConfigurationShape) { if (!shape) { shape = new class extends MainThreadConfigurationShape { }; } return new ExtHostConfiguration(shape, data); } - function createConfigurationValue(value: T): IWorkspaceConfigurationValue { + function createConfigurationValue(value: T): IConfigurationValue { return { value, default: value, -- GitLab From 4f888ef65d7078577d3d4c15a6818492dcdcd2bf Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Thu, 15 Jun 2017 19:20:51 +0200 Subject: [PATCH 0901/1347] #28538 Expose Configuration Data through Configuration service --- .../browser/standalone/simpleServices.ts | 6 +- .../configuration/common/configuration.ts | 56 ++++++++++++++++++- .../node/configurationService.ts | 18 +++--- .../test/common/testConfigurationService.ts | 6 +- .../electron-browser/telemetryService.test.ts | 3 + .../terminalConfigHelper.test.ts | 1 + .../configuration/node/configuration.ts | 14 ++--- .../node/configurationResolverService.test.ts | 1 + 8 files changed, 85 insertions(+), 20 deletions(-) diff --git a/src/vs/editor/browser/standalone/simpleServices.ts b/src/vs/editor/browser/standalone/simpleServices.ts index 97d0459cc8c..990e6cf2109 100644 --- a/src/vs/editor/browser/standalone/simpleServices.ts +++ b/src/vs/editor/browser/standalone/simpleServices.ts @@ -8,7 +8,7 @@ import { Schemas } from 'vs/base/common/network'; import Severity from 'vs/base/common/severity'; import URI from 'vs/base/common/uri'; import { TPromise } from 'vs/base/common/winjs.base'; -import { IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, getConfigurationValue, IConfigurationKeys, IConfigurationValues } from 'vs/platform/configuration/common/configuration'; +import { IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, getConfigurationValue, IConfigurationKeys, IConfigurationValues, ConfigurationData, ConfigurationModel } from 'vs/platform/configuration/common/configuration'; import { IEditor, IEditorInput, IEditorOptions, IEditorService, IResourceInput, Position } from 'vs/platform/editor/common/editor'; import { ICommandService, ICommand, ICommandEvent, ICommandHandler, CommandsRegistry } from 'vs/platform/commands/common/commands'; import { AbstractKeybindingService } from 'vs/platform/keybinding/common/abstractKeybindingService'; @@ -442,6 +442,10 @@ export class SimpleConfigurationService implements IConfigurationService { return this._config; } + public getConfigurationData(): ConfigurationData { + return new ConfigurationData(new ConfigurationModel(this._config), new ConfigurationModel()); + } + public reloadConfiguration(section?: string): TPromise { return TPromise.as(this.getConfiguration(section)); } diff --git a/src/vs/platform/configuration/common/configuration.ts b/src/vs/platform/configuration/common/configuration.ts index 018e7339ab7..4aee67a6091 100644 --- a/src/vs/platform/configuration/common/configuration.ts +++ b/src/vs/platform/configuration/common/configuration.ts @@ -25,6 +25,8 @@ export type IConfigurationValues = { [key: string]: IConfigurationValue }; export interface IConfigurationService { _serviceBrand: any; + getConfigurationData(): ConfigurationData; + /** * Fetches the appropriate section of the configuration JSON file. * This will be an object keyed off the section name. @@ -126,12 +128,17 @@ export function merge(base: any, add: any, overwrite: boolean): void { }); } +export interface IConfiguraionModel { + contents: T; + overrides: IOverrides[]; +} + export interface IOverrides { contents: T; identifiers: string[]; } -export class ConfigurationModel { +export class ConfigurationModel implements IConfiguraionModel { protected _keys: string[] = []; @@ -142,6 +149,10 @@ export class ConfigurationModel { return this._contents; } + public get overrides(): IOverrides[] { + return this._overrides; + } + public get keys(): string[] { return this._keys; } @@ -186,7 +197,14 @@ export class ConfigurationModel { } } -export class Configuration { +export interface IConfigurationData { + defaults: IConfiguraionModel; + user: IConfiguraionModel; + folders: { [folder: string]: IConfiguraionModel }; + workspaceUri: string; +} + +export class ConfigurationData { private _global: ConfigurationModel; private _workspace: ConfigurationModel; @@ -284,4 +302,38 @@ export class Configuration { let configurationModel = (options.resource ? this._foldersConsolidated.get(options.resource) : this._workspace) || new ConfigurationModel(); return options.overrideIdentifier ? configurationModel.override(options.overrideIdentifier) : configurationModel; } + + public toJSON(): IConfigurationData { + return { + defaults: { + contents: this._defaults.contents, + overrides: this._defaults.overrides + }, + user: { + contents: this._user.contents, + overrides: this._user.overrides + }, + folders: this.folders.keys().reduce((result, folder) => { + const { contents, overrides } = this.folders.get(folder); + result[folder.toString()] = { contents, overrides }; + return result; + }, Object.create({})), + workspaceUri: this.workspaceUri.toString() + }; + } + + public static parse(data: IConfigurationData): ConfigurationData { + const defaults = ConfigurationData.parseConfigurationModel(data.defaults); + const user = ConfigurationData.parseConfigurationModel(data.user); + const folders: StrictResourceMap> = Object.keys(data.folders).reduce((result, key) => { + result.set(URI.parse(key), ConfigurationData.parseConfigurationModel(data.folders[key])); + return result; + }, new StrictResourceMap>()); + const workspaceUri = data.workspaceUri ? URI.parse(data.workspaceUri) : void 0; + return new ConfigurationData(defaults, user, folders, workspaceUri); + } + + private static parseConfigurationModel(model: IConfiguraionModel): ConfigurationModel { + return new ConfigurationModel(model.contents, model.overrides); + } } \ No newline at end of file diff --git a/src/vs/platform/configuration/node/configurationService.ts b/src/vs/platform/configuration/node/configurationService.ts index a241cc876a3..f5775b842c1 100644 --- a/src/vs/platform/configuration/node/configurationService.ts +++ b/src/vs/platform/configuration/node/configurationService.ts @@ -9,7 +9,7 @@ import { ConfigWatcher } from 'vs/base/node/config'; import { Registry } from 'vs/platform/platform'; import { IConfigurationRegistry, Extensions } from 'vs/platform/configuration/common/configurationRegistry'; import { IDisposable, toDisposable, Disposable } from 'vs/base/common/lifecycle'; -import { ConfigurationSource, IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, IConfigurationKeys, ConfigurationModel, IConfigurationOptions, Configuration, IConfigurationValues } from 'vs/platform/configuration/common/configuration'; +import { ConfigurationSource, IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, IConfigurationKeys, ConfigurationModel, IConfigurationOptions, ConfigurationData, IConfigurationValues } from 'vs/platform/configuration/common/configuration'; import { CustomConfigurationModel, DefaultConfigurationModel } from 'vs/platform/configuration/common/model'; import Event, { Emitter } from 'vs/base/common/event'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; @@ -18,7 +18,7 @@ export class ConfigurationService extends Disposable implements IConfiguratio _serviceBrand: any; - private _configuration: Configuration; + private _configuration: ConfigurationData; private userConfigModelWatcher: ConfigWatcher>; private _onDidUpdateConfiguration: Emitter = this._register(new Emitter()); @@ -46,7 +46,7 @@ export class ConfigurationService extends Disposable implements IConfiguratio private onConfigurationChange(source: ConfigurationSource): void { this.reset(); // reset our caches - const cache = this.getConfiguration2(); + const cache = this.getConfigurationData(); this._onDidUpdateConfiguration.fire({ source, @@ -66,22 +66,22 @@ export class ConfigurationService extends Disposable implements IConfiguratio public getConfiguration(section?: string): C public getConfiguration(options?: IConfigurationOptions): C public getConfiguration(arg?: any): C { - return this.getConfiguration2().getValue(this.toOptions(arg)); + return this.getConfigurationData().getValue(this.toOptions(arg)); } public lookup(key: string, overrideIdentifier?: string): IConfigurationValue { - return this.getConfiguration2().lookup(key, overrideIdentifier); + return this.getConfigurationData().lookup(key, overrideIdentifier); } public keys(): IConfigurationKeys { - return this.getConfiguration2().keys(); + return this.getConfigurationData().keys(); } public values(): IConfigurationValues { return this._configuration.values(); } - public getConfiguration2(): Configuration { + public getConfigurationData(): ConfigurationData { return this._configuration || (this._configuration = this.consolidateConfigurations()); } @@ -99,9 +99,9 @@ export class ConfigurationService extends Disposable implements IConfiguratio return {}; } - private consolidateConfigurations(): Configuration { + private consolidateConfigurations(): ConfigurationData { const defaults = new DefaultConfigurationModel(); const user = this.userConfigModelWatcher.getConfig(); - return new Configuration(defaults, user); + return new ConfigurationData(defaults, user); } } \ No newline at end of file diff --git a/src/vs/platform/configuration/test/common/testConfigurationService.ts b/src/vs/platform/configuration/test/common/testConfigurationService.ts index 7d493764ef2..91823b939bf 100644 --- a/src/vs/platform/configuration/test/common/testConfigurationService.ts +++ b/src/vs/platform/configuration/test/common/testConfigurationService.ts @@ -8,7 +8,7 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { EventEmitter } from 'vs/base/common/eventEmitter'; import { getConfigurationKeys } from 'vs/platform/configuration/common/model'; -import { IConfigurationService, getConfigurationValue, IConfigurationValue, IConfigurationKeys, IConfigurationValues } from 'vs/platform/configuration/common/configuration'; +import { IConfigurationService, getConfigurationValue, IConfigurationValue, IConfigurationKeys, IConfigurationValues, ConfigurationData, ConfigurationModel } from 'vs/platform/configuration/common/configuration'; export class TestConfigurationService extends EventEmitter implements IConfigurationService { public _serviceBrand: any; @@ -23,6 +23,10 @@ export class TestConfigurationService extends EventEmitter implements IConfigura return this.configuration; } + public getConfigurationData(): ConfigurationData { + return new ConfigurationData(new ConfigurationModel(), new ConfigurationModel(this.configuration)); + } + public setUserConfiguration(key: any, value: any): Thenable { this.configuration[key] = value; return TPromise.as(null); diff --git a/src/vs/platform/telemetry/test/electron-browser/telemetryService.test.ts b/src/vs/platform/telemetry/test/electron-browser/telemetryService.test.ts index 478619bb599..b80b748e9d1 100644 --- a/src/vs/platform/telemetry/test/electron-browser/telemetryService.test.ts +++ b/src/vs/platform/telemetry/test/electron-browser/telemetryService.test.ts @@ -681,6 +681,9 @@ suite('TelemetryService', () => { enableTelemetry }; }, + getConfigurationData(): any { + return null; + }, reloadConfiguration() { return TPromise.as(this.getConfiguration()); }, diff --git a/src/vs/workbench/parts/terminal/test/electron-browser/terminalConfigHelper.test.ts b/src/vs/workbench/parts/terminal/test/electron-browser/terminalConfigHelper.test.ts index 5c907435679..71e80be84f0 100644 --- a/src/vs/workbench/parts/terminal/test/electron-browser/terminalConfigHelper.test.ts +++ b/src/vs/workbench/parts/terminal/test/electron-browser/terminalConfigHelper.test.ts @@ -22,6 +22,7 @@ class MockConfigurationService implements IConfigurationService { public keys() { return { default: [], user: [], workspace: [] }; } public values() { return {}; } public getConfiguration(): any { return this.configuration; } + public getConfigurationData(): any { return null; } public onDidUpdateConfiguration() { return { dispose() { } }; } } diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index d165e84b81f..367c9ae2c24 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -24,7 +24,7 @@ import { isLinux } from 'vs/base/common/platform'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { CustomConfigurationModel } from 'vs/platform/configuration/common/model'; import { ScopedConfigurationModel, FolderConfigurationModel, FolderSettingsModel } from 'vs/workbench/services/configuration/common/configurationModels'; -import { IConfigurationServiceEvent, ConfigurationSource, IConfigurationKeys, IConfigurationValue, ConfigurationModel, IConfigurationOptions, Configuration as BaseConfiguration, IConfigurationValues } from 'vs/platform/configuration/common/configuration'; +import { IConfigurationServiceEvent, ConfigurationSource, IConfigurationKeys, IConfigurationValue, ConfigurationModel, IConfigurationOptions, ConfigurationData, IConfigurationValues } from 'vs/platform/configuration/common/configuration'; import { IWorkspaceConfigurationService, WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME, WORKSPACE_STANDALONE_CONFIGURATIONS, WORKSPACE_CONFIG_DEFAULT_PATH } from 'vs/workbench/services/configuration/common/configuration'; import { ConfigurationService as GlobalConfigurationService } from 'vs/platform/configuration/node/configurationService'; import { createHash } from "crypto"; @@ -193,7 +193,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp return this.workspace ? this.legacyWorkspace.toResource(workspaceRelativePath) : null; } - public get configuration(): BaseConfiguration { + public getConfigurationData(): ConfigurationData { return this._configuration; } @@ -275,7 +275,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp private initCaches(): void { this.cachedFolderConfigs = new StrictResourceMap>(); - this._configuration = new Configuration(this.baseConfigurationService.getConfiguration2(), new StrictResourceMap>(), this.workspaceUri); + this._configuration = new Configuration(this.baseConfigurationService.getConfigurationData(), new StrictResourceMap>(), this.workspaceUri); this.initCachesForFolders(this.workspace ? this.workspace.roots : []); } @@ -298,7 +298,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } } - if (this._configuration.updateBaseConfiguration(this.baseConfigurationService.getConfiguration2())) { + if (this._configuration.updateBaseConfiguration(this.baseConfigurationService.getConfigurationData())) { this.trigger(event.source, event.sourceConfig); } } @@ -517,13 +517,13 @@ function resolveStat(resource: URI): TPromise { }); } -class Configuration extends BaseConfiguration { +class Configuration extends ConfigurationData { - constructor(private _baseConfiguration: BaseConfiguration, protected folders: StrictResourceMap>, workspaceUri: URI) { + constructor(private _baseConfiguration: ConfigurationData, protected folders: StrictResourceMap>, workspaceUri: URI) { super(_baseConfiguration.defaults, _baseConfiguration.user, folders, workspaceUri); } - updateBaseConfiguration(baseConfiguration: BaseConfiguration): boolean { + updateBaseConfiguration(baseConfiguration: ConfigurationData): boolean { const current = new Configuration(this._baseConfiguration, this.folders, this.workspaceUri); this._defaults = baseConfiguration.defaults; diff --git a/src/vs/workbench/services/configurationResolver/test/node/configurationResolverService.test.ts b/src/vs/workbench/services/configurationResolver/test/node/configurationResolverService.test.ts index dfc7ac05d9a..39c416f2f1a 100644 --- a/src/vs/workbench/services/configurationResolver/test/node/configurationResolverService.test.ts +++ b/src/vs/workbench/services/configurationResolver/test/node/configurationResolverService.test.ts @@ -344,6 +344,7 @@ class MockConfigurationService implements IConfigurationService { public keys() { return { default: [], user: [], workspace: [] }; } public values() { return {}; } public getConfiguration(): any { return this.configuration; } + public getConfigurationData(): any { return null; } public onDidUpdateConfiguration() { return { dispose() { } }; } } -- GitLab From b3191eecc16b2fcdc613ec00b23b2e2b7ee40880 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Thu, 15 Jun 2017 20:27:16 +0200 Subject: [PATCH 0902/1347] #28538 Prepare for sending configuration data to extension host --- .../browser/standalone/simpleServices.ts | 6 ++--- .../configuration/common/configuration.ts | 18 +++++++------- .../node/configurationService.ts | 24 +++++++++++-------- .../test/common/testConfigurationService.ts | 6 ++--- .../configuration/node/configuration.ts | 18 ++++++++------ 5 files changed, 40 insertions(+), 32 deletions(-) diff --git a/src/vs/editor/browser/standalone/simpleServices.ts b/src/vs/editor/browser/standalone/simpleServices.ts index 990e6cf2109..7365d6ccdb5 100644 --- a/src/vs/editor/browser/standalone/simpleServices.ts +++ b/src/vs/editor/browser/standalone/simpleServices.ts @@ -8,7 +8,7 @@ import { Schemas } from 'vs/base/common/network'; import Severity from 'vs/base/common/severity'; import URI from 'vs/base/common/uri'; import { TPromise } from 'vs/base/common/winjs.base'; -import { IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, getConfigurationValue, IConfigurationKeys, IConfigurationValues, ConfigurationData, ConfigurationModel } from 'vs/platform/configuration/common/configuration'; +import { IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, getConfigurationValue, IConfigurationKeys, IConfigurationValues, Configuration, IConfigurationData, ConfigurationModel } from 'vs/platform/configuration/common/configuration'; import { IEditor, IEditorInput, IEditorOptions, IEditorService, IResourceInput, Position } from 'vs/platform/editor/common/editor'; import { ICommandService, ICommand, ICommandEvent, ICommandHandler, CommandsRegistry } from 'vs/platform/commands/common/commands'; import { AbstractKeybindingService } from 'vs/platform/keybinding/common/abstractKeybindingService'; @@ -442,8 +442,8 @@ export class SimpleConfigurationService implements IConfigurationService { return this._config; } - public getConfigurationData(): ConfigurationData { - return new ConfigurationData(new ConfigurationModel(this._config), new ConfigurationModel()); + public getConfigurationData(): IConfigurationData { + return new Configuration(new ConfigurationModel(this._config), new ConfigurationModel()).toData(); } public reloadConfiguration(section?: string): TPromise { diff --git a/src/vs/platform/configuration/common/configuration.ts b/src/vs/platform/configuration/common/configuration.ts index 4aee67a6091..35d4dd6762e 100644 --- a/src/vs/platform/configuration/common/configuration.ts +++ b/src/vs/platform/configuration/common/configuration.ts @@ -25,7 +25,7 @@ export type IConfigurationValues = { [key: string]: IConfigurationValue }; export interface IConfigurationService { _serviceBrand: any; - getConfigurationData(): ConfigurationData; + getConfigurationData(): IConfigurationData; /** * Fetches the appropriate section of the configuration JSON file. @@ -204,7 +204,7 @@ export interface IConfigurationData { workspaceUri: string; } -export class ConfigurationData { +export class Configuration { private _global: ConfigurationModel; private _workspace: ConfigurationModel; @@ -303,7 +303,7 @@ export class ConfigurationData { return options.overrideIdentifier ? configurationModel.override(options.overrideIdentifier) : configurationModel; } - public toJSON(): IConfigurationData { + public toData(): IConfigurationData { return { defaults: { contents: this._defaults.contents, @@ -318,19 +318,19 @@ export class ConfigurationData { result[folder.toString()] = { contents, overrides }; return result; }, Object.create({})), - workspaceUri: this.workspaceUri.toString() + workspaceUri: this.workspaceUri ? this.workspaceUri.toString() : void 0 }; } - public static parse(data: IConfigurationData): ConfigurationData { - const defaults = ConfigurationData.parseConfigurationModel(data.defaults); - const user = ConfigurationData.parseConfigurationModel(data.user); + public static parse(data: IConfigurationData): Configuration { + const defaults = Configuration.parseConfigurationModel(data.defaults); + const user = Configuration.parseConfigurationModel(data.user); const folders: StrictResourceMap> = Object.keys(data.folders).reduce((result, key) => { - result.set(URI.parse(key), ConfigurationData.parseConfigurationModel(data.folders[key])); + result.set(URI.parse(key), Configuration.parseConfigurationModel(data.folders[key])); return result; }, new StrictResourceMap>()); const workspaceUri = data.workspaceUri ? URI.parse(data.workspaceUri) : void 0; - return new ConfigurationData(defaults, user, folders, workspaceUri); + return new Configuration(defaults, user, folders, workspaceUri); } private static parseConfigurationModel(model: IConfiguraionModel): ConfigurationModel { diff --git a/src/vs/platform/configuration/node/configurationService.ts b/src/vs/platform/configuration/node/configurationService.ts index f5775b842c1..d93ccf72d91 100644 --- a/src/vs/platform/configuration/node/configurationService.ts +++ b/src/vs/platform/configuration/node/configurationService.ts @@ -9,7 +9,7 @@ import { ConfigWatcher } from 'vs/base/node/config'; import { Registry } from 'vs/platform/platform'; import { IConfigurationRegistry, Extensions } from 'vs/platform/configuration/common/configurationRegistry'; import { IDisposable, toDisposable, Disposable } from 'vs/base/common/lifecycle'; -import { ConfigurationSource, IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, IConfigurationKeys, ConfigurationModel, IConfigurationOptions, ConfigurationData, IConfigurationValues } from 'vs/platform/configuration/common/configuration'; +import { ConfigurationSource, IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, IConfigurationKeys, ConfigurationModel, IConfigurationOptions, Configuration, IConfigurationValues, IConfigurationData } from 'vs/platform/configuration/common/configuration'; import { CustomConfigurationModel, DefaultConfigurationModel } from 'vs/platform/configuration/common/model'; import Event, { Emitter } from 'vs/base/common/event'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; @@ -18,7 +18,7 @@ export class ConfigurationService extends Disposable implements IConfiguratio _serviceBrand: any; - private _configuration: ConfigurationData; + private _configuration: Configuration; private userConfigModelWatcher: ConfigWatcher>; private _onDidUpdateConfiguration: Emitter = this._register(new Emitter()); @@ -43,10 +43,14 @@ export class ConfigurationService extends Disposable implements IConfiguratio this._register(Registry.as(Extensions.Configuration).onDidRegisterConfiguration(() => this.onConfigurationChange(ConfigurationSource.Default))); } + public get configuration(): Configuration { + return this._configuration || (this._configuration = this.consolidateConfigurations()); + } + private onConfigurationChange(source: ConfigurationSource): void { this.reset(); // reset our caches - const cache = this.getConfigurationData(); + const cache = this.configuration; this._onDidUpdateConfiguration.fire({ source, @@ -66,23 +70,23 @@ export class ConfigurationService extends Disposable implements IConfiguratio public getConfiguration(section?: string): C public getConfiguration(options?: IConfigurationOptions): C public getConfiguration(arg?: any): C { - return this.getConfigurationData().getValue(this.toOptions(arg)); + return this.configuration.getValue(this.toOptions(arg)); } public lookup(key: string, overrideIdentifier?: string): IConfigurationValue { - return this.getConfigurationData().lookup(key, overrideIdentifier); + return this.configuration.lookup(key, overrideIdentifier); } public keys(): IConfigurationKeys { - return this.getConfigurationData().keys(); + return this.configuration.keys(); } public values(): IConfigurationValues { return this._configuration.values(); } - public getConfigurationData(): ConfigurationData { - return this._configuration || (this._configuration = this.consolidateConfigurations()); + public getConfigurationData(): IConfigurationData { + return this.configuration.toData(); } private reset(): void { @@ -99,9 +103,9 @@ export class ConfigurationService extends Disposable implements IConfiguratio return {}; } - private consolidateConfigurations(): ConfigurationData { + private consolidateConfigurations(): Configuration { const defaults = new DefaultConfigurationModel(); const user = this.userConfigModelWatcher.getConfig(); - return new ConfigurationData(defaults, user); + return new Configuration(defaults, user); } } \ No newline at end of file diff --git a/src/vs/platform/configuration/test/common/testConfigurationService.ts b/src/vs/platform/configuration/test/common/testConfigurationService.ts index 91823b939bf..31c59305997 100644 --- a/src/vs/platform/configuration/test/common/testConfigurationService.ts +++ b/src/vs/platform/configuration/test/common/testConfigurationService.ts @@ -8,7 +8,7 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { EventEmitter } from 'vs/base/common/eventEmitter'; import { getConfigurationKeys } from 'vs/platform/configuration/common/model'; -import { IConfigurationService, getConfigurationValue, IConfigurationValue, IConfigurationKeys, IConfigurationValues, ConfigurationData, ConfigurationModel } from 'vs/platform/configuration/common/configuration'; +import { IConfigurationService, getConfigurationValue, IConfigurationValue, IConfigurationKeys, IConfigurationValues, IConfigurationData, Configuration, ConfigurationModel } from 'vs/platform/configuration/common/configuration'; export class TestConfigurationService extends EventEmitter implements IConfigurationService { public _serviceBrand: any; @@ -23,8 +23,8 @@ export class TestConfigurationService extends EventEmitter implements IConfigura return this.configuration; } - public getConfigurationData(): ConfigurationData { - return new ConfigurationData(new ConfigurationModel(), new ConfigurationModel(this.configuration)); + public getConfigurationData(): IConfigurationData { + return new Configuration(new ConfigurationModel(), new ConfigurationModel(this.configuration)).toData(); } public setUserConfiguration(key: any, value: any): Thenable { diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index 367c9ae2c24..dfd762bf308 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -24,7 +24,7 @@ import { isLinux } from 'vs/base/common/platform'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { CustomConfigurationModel } from 'vs/platform/configuration/common/model'; import { ScopedConfigurationModel, FolderConfigurationModel, FolderSettingsModel } from 'vs/workbench/services/configuration/common/configurationModels'; -import { IConfigurationServiceEvent, ConfigurationSource, IConfigurationKeys, IConfigurationValue, ConfigurationModel, IConfigurationOptions, ConfigurationData, IConfigurationValues } from 'vs/platform/configuration/common/configuration'; +import { IConfigurationServiceEvent, ConfigurationSource, IConfigurationKeys, IConfigurationValue, ConfigurationModel, IConfigurationOptions, Configuration as BaseConfiguration, IConfigurationValues, IConfigurationData } from 'vs/platform/configuration/common/configuration'; import { IWorkspaceConfigurationService, WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME, WORKSPACE_STANDALONE_CONFIGURATIONS, WORKSPACE_CONFIG_DEFAULT_PATH } from 'vs/workbench/services/configuration/common/configuration'; import { ConfigurationService as GlobalConfigurationService } from 'vs/platform/configuration/node/configurationService'; import { createHash } from "crypto"; @@ -193,7 +193,11 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp return this.workspace ? this.legacyWorkspace.toResource(workspaceRelativePath) : null; } - public getConfigurationData(): ConfigurationData { + public getConfigurationData(): IConfigurationData { + return this._configuration.toData(); + } + + public get configuration(): BaseConfiguration { return this._configuration; } @@ -275,7 +279,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp private initCaches(): void { this.cachedFolderConfigs = new StrictResourceMap>(); - this._configuration = new Configuration(this.baseConfigurationService.getConfigurationData(), new StrictResourceMap>(), this.workspaceUri); + this._configuration = new Configuration(this.baseConfigurationService.configuration, new StrictResourceMap>(), this.workspaceUri); this.initCachesForFolders(this.workspace ? this.workspace.roots : []); } @@ -298,7 +302,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } } - if (this._configuration.updateBaseConfiguration(this.baseConfigurationService.getConfigurationData())) { + if (this._configuration.updateBaseConfiguration(this.baseConfigurationService.configuration)) { this.trigger(event.source, event.sourceConfig); } } @@ -517,13 +521,13 @@ function resolveStat(resource: URI): TPromise { }); } -class Configuration extends ConfigurationData { +class Configuration extends BaseConfiguration { - constructor(private _baseConfiguration: ConfigurationData, protected folders: StrictResourceMap>, workspaceUri: URI) { + constructor(private _baseConfiguration: Configuration, protected folders: StrictResourceMap>, workspaceUri: URI) { super(_baseConfiguration.defaults, _baseConfiguration.user, folders, workspaceUri); } - updateBaseConfiguration(baseConfiguration: ConfigurationData): boolean { + updateBaseConfiguration(baseConfiguration: Configuration): boolean { const current = new Configuration(this._baseConfiguration, this.folders, this.workspaceUri); this._defaults = baseConfiguration.defaults; -- GitLab From c2d0d459cc8dca66f579a4663c08f30c311a80ca Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Thu, 15 Jun 2017 20:34:50 +0200 Subject: [PATCH 0903/1347] #27823 Fix tests --- .../configuration/node/configurationService.ts | 12 ++++++------ .../services/configuration/node/configuration.ts | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/vs/platform/configuration/node/configurationService.ts b/src/vs/platform/configuration/node/configurationService.ts index d93ccf72d91..a8f4443b4e3 100644 --- a/src/vs/platform/configuration/node/configurationService.ts +++ b/src/vs/platform/configuration/node/configurationService.ts @@ -43,14 +43,14 @@ export class ConfigurationService extends Disposable implements IConfiguratio this._register(Registry.as(Extensions.Configuration).onDidRegisterConfiguration(() => this.onConfigurationChange(ConfigurationSource.Default))); } - public get configuration(): Configuration { + public configuration(): Configuration { return this._configuration || (this._configuration = this.consolidateConfigurations()); } private onConfigurationChange(source: ConfigurationSource): void { this.reset(); // reset our caches - const cache = this.configuration; + const cache = this.configuration(); this._onDidUpdateConfiguration.fire({ source, @@ -70,15 +70,15 @@ export class ConfigurationService extends Disposable implements IConfiguratio public getConfiguration(section?: string): C public getConfiguration(options?: IConfigurationOptions): C public getConfiguration(arg?: any): C { - return this.configuration.getValue(this.toOptions(arg)); + return this.configuration().getValue(this.toOptions(arg)); } public lookup(key: string, overrideIdentifier?: string): IConfigurationValue { - return this.configuration.lookup(key, overrideIdentifier); + return this.configuration().lookup(key, overrideIdentifier); } public keys(): IConfigurationKeys { - return this.configuration.keys(); + return this.configuration().keys(); } public values(): IConfigurationValues { @@ -86,7 +86,7 @@ export class ConfigurationService extends Disposable implements IConfiguratio } public getConfigurationData(): IConfigurationData { - return this.configuration.toData(); + return this.configuration().toData(); } private reset(): void { diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index dfd762bf308..2970fb389cd 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -279,7 +279,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp private initCaches(): void { this.cachedFolderConfigs = new StrictResourceMap>(); - this._configuration = new Configuration(this.baseConfigurationService.configuration, new StrictResourceMap>(), this.workspaceUri); + this._configuration = new Configuration(this.baseConfigurationService.configuration(), new StrictResourceMap>(), this.workspaceUri); this.initCachesForFolders(this.workspace ? this.workspace.roots : []); } @@ -302,7 +302,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } } - if (this._configuration.updateBaseConfiguration(this.baseConfigurationService.configuration)) { + if (this._configuration.updateBaseConfiguration(this.baseConfigurationService.configuration())) { this.trigger(event.source, event.sourceConfig); } } -- GitLab From 69fd57e4dc6613d430fe8b7012de70013c811a9b Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Thu, 15 Jun 2017 13:04:08 -0700 Subject: [PATCH 0904/1347] Add CSP To Root Document (#28670) * Add CSP To Root Document Adds a content security policy to the root vscode document. This limits what can be loaded. Important changes: * Connect-src is limited to `self` or `https:` * script-src is limited to `self` * object and child-src are limited to `self` * Media allows `self` `http` `https` and `data` * Add preload to gulp * Default to none * Don't use let in preload --- build/gulpfile.vscode.js | 3 +- .../electron-browser/bootstrap/index.html | 37 +----------------- .../electron-browser/bootstrap/preload.js | 39 +++++++++++++++++++ 3 files changed, 43 insertions(+), 36 deletions(-) create mode 100644 src/vs/workbench/electron-browser/bootstrap/preload.js diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index 1af153e1e81..453b44df066 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -214,7 +214,8 @@ function packageTask(platform, arch, opts) { 'vs/workbench/electron-browser/workbench.main.js', 'vs/workbench/electron-browser/workbench.main.css', 'vs/workbench/electron-browser/bootstrap/index.html', - 'vs/workbench/electron-browser/bootstrap/index.js' + 'vs/workbench/electron-browser/bootstrap/index.js', + 'vs/workbench/electron-browser/bootstrap/preload.js' ]); const src = gulp.src(out + '/**', { base: '.' }) diff --git a/src/vs/workbench/electron-browser/bootstrap/index.html b/src/vs/workbench/electron-browser/bootstrap/index.html index 1474a70e097..29b73eae7c1 100644 --- a/src/vs/workbench/electron-browser/bootstrap/index.html +++ b/src/vs/workbench/electron-browser/bootstrap/index.html @@ -3,43 +3,10 @@ + - + diff --git a/src/vs/workbench/electron-browser/bootstrap/preload.js b/src/vs/workbench/electron-browser/bootstrap/preload.js new file mode 100644 index 00000000000..d451c2d5fb7 --- /dev/null +++ b/src/vs/workbench/electron-browser/bootstrap/preload.js @@ -0,0 +1,39 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +'use strict'; + +(function() { + function getConfig() { + const queryParams = window.location.search.substring(1).split('&'); + for (var i = 0; i < queryParams.length; i++) { + var kv = queryParams[i].split('='); + if (kv[0] === 'config' && kv[1]) { + return JSON.parse(decodeURIComponent(kv[1])); + } + } + return {}; + } + try { + const config = getConfig(); + const document = window.document; + + // sets the base theme class ('vs', 'vs-dark', 'hc-black') + const baseTheme = config.baseTheme || 'vs'; + document.body.className = 'monaco-shell ' + baseTheme; + + // adds a stylesheet with the backgrdound color + var backgroundColor = config.backgroundColor; + if (!backgroundColor) { + backgroundColor = baseTheme === 'hc-black' ? '#000000' : (baseTheme === 'vs' ? '#FFFFFF' : '#1E1E1E'); + } + const foregroundColor = baseTheme === 'hc-black' ? '#FFFFFF' : (baseTheme === 'vs' ? '#6C6C6C' : '#CCCCCC'); + const style = document.createElement('style'); + style.innerHTML = '.monaco-shell { background-color:' + backgroundColor + '; color:' + foregroundColor + '; }'; + document.head.appendChild(style); + + } catch (error) { + console.error(error); + } +})(); \ No newline at end of file -- GitLab From 00400d8fa6f221b418524566005c371615cff6d3 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Thu, 15 Jun 2017 22:13:53 +0200 Subject: [PATCH 0905/1347] #28538 API to get settings by override identifiers - language - resource --- .../services/editorWorkerServiceImpl.ts | 5 ++-- .../common/services/modelServiceImpl.ts | 2 +- .../configuration/common/configuration.ts | 16 ++++++------- .../node/configurationService.ts | 18 +++----------- .../browser/parts/editor/textDiffEditor.ts | 2 +- .../browser/parts/editor/textEditor.ts | 2 +- .../electron-browser/walkThroughPart.ts | 2 +- .../configuration/node/configuration.ts | 24 +++++-------------- .../keybinding/common/keybindingEditing.ts | 2 +- 9 files changed, 23 insertions(+), 50 deletions(-) diff --git a/src/vs/editor/common/services/editorWorkerServiceImpl.ts b/src/vs/editor/common/services/editorWorkerServiceImpl.ts index 77afcaec5de..aac6b88d9ff 100644 --- a/src/vs/editor/common/services/editorWorkerServiceImpl.ts +++ b/src/vs/editor/common/services/editorWorkerServiceImpl.ts @@ -17,7 +17,7 @@ import { IEditorWorkerService } from 'vs/editor/common/services/editorWorkerServ import { IModelService } from 'vs/editor/common/services/modelService'; import { EditorSimpleWorkerImpl } from 'vs/editor/common/services/editorSimpleWorker'; import { LanguageConfigurationRegistry } from 'vs/editor/common/modes/languageConfigurationRegistry'; -import { IConfigurationService, IConfigurationOptions } from 'vs/platform/configuration/common/configuration'; +import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; import { IEditorOptions } from 'vs/editor/common/config/editorOptions'; import { IRange } from 'vs/editor/common/core/range'; import { IModeService } from 'vs/editor/common/services/modeService'; @@ -93,8 +93,7 @@ class WordBasedCompletionItemProvider implements modes.ISuggestSupport { provideCompletionItems(model: editorCommon.IModel, position: Position): TPromise { const { language } = this._modeService.getLanguageIdentifier(model.getLanguageIdAtPosition(position.lineNumber, position.column)); - const options = { section: 'editor', overrideIdentifier: language }; - const { wordBasedSuggestions } = this._configurationService.getConfiguration(options); + const { wordBasedSuggestions } = this._configurationService.getConfiguration('editor', { language }); if (!wordBasedSuggestions) { return undefined; } diff --git a/src/vs/editor/common/services/modelServiceImpl.ts b/src/vs/editor/common/services/modelServiceImpl.ts index 5bcb68eba4b..da1b0a8207e 100644 --- a/src/vs/editor/common/services/modelServiceImpl.ts +++ b/src/vs/editor/common/services/modelServiceImpl.ts @@ -267,7 +267,7 @@ export class ModelServiceImpl implements IModelService { public getCreationOptions(language: string): editorCommon.ITextModelCreationOptions { let creationOptions = this._modelCreationOptionsByLanguage[language]; if (!creationOptions) { - creationOptions = ModelServiceImpl._readModelOptions(this._configurationService.getConfiguration({ overrideIdentifier: language })); + creationOptions = ModelServiceImpl._readModelOptions(this._configurationService.getConfiguration(null, { language })); this._modelCreationOptionsByLanguage[language] = creationOptions; } return creationOptions; diff --git a/src/vs/platform/configuration/common/configuration.ts b/src/vs/platform/configuration/common/configuration.ts index 35d4dd6762e..ac8016e30ab 100644 --- a/src/vs/platform/configuration/common/configuration.ts +++ b/src/vs/platform/configuration/common/configuration.ts @@ -14,10 +14,9 @@ import Event from 'vs/base/common/event'; export const IConfigurationService = createDecorator('configurationService'); -export interface IConfigurationOptions { - overrideIdentifier?: string; +export interface IConfigurationOverrides { + language?: string; resource?: URI; - section?: string; } export type IConfigurationValues = { [key: string]: IConfigurationValue }; @@ -31,8 +30,7 @@ export interface IConfigurationService { * Fetches the appropriate section of the configuration JSON file. * This will be an object keyed off the section name. */ - getConfiguration(section?: string): T; - getConfiguration(options?: IConfigurationOptions): T; + getConfiguration(section?: string, overrides?: IConfigurationOverrides): T; /** * Resolves a configuration key to its values in the different scopes @@ -243,9 +241,9 @@ export class Configuration { } } - getValue(options: IConfigurationOptions = {}): C { + getValue(section: string = '', options: IConfigurationOverrides = {}): C { const configModel = this.getConfigurationModel(options); - return options.section ? configModel.getContentsFor(options.section) : configModel.contents; + return section ? configModel.getContentsFor(section) : configModel.contents; } lookup(key: string, overrideIdentifier?: string): IConfigurationValue { @@ -298,9 +296,9 @@ export class Configuration { return result; } - private getConfigurationModel(options: IConfigurationOptions): ConfigurationModel { + private getConfigurationModel(options: IConfigurationOverrides): ConfigurationModel { let configurationModel = (options.resource ? this._foldersConsolidated.get(options.resource) : this._workspace) || new ConfigurationModel(); - return options.overrideIdentifier ? configurationModel.override(options.overrideIdentifier) : configurationModel; + return options.language ? configurationModel.override(options.language) : configurationModel; } public toData(): IConfigurationData { diff --git a/src/vs/platform/configuration/node/configurationService.ts b/src/vs/platform/configuration/node/configurationService.ts index a8f4443b4e3..a0060b1759a 100644 --- a/src/vs/platform/configuration/node/configurationService.ts +++ b/src/vs/platform/configuration/node/configurationService.ts @@ -9,7 +9,7 @@ import { ConfigWatcher } from 'vs/base/node/config'; import { Registry } from 'vs/platform/platform'; import { IConfigurationRegistry, Extensions } from 'vs/platform/configuration/common/configurationRegistry'; import { IDisposable, toDisposable, Disposable } from 'vs/base/common/lifecycle'; -import { ConfigurationSource, IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, IConfigurationKeys, ConfigurationModel, IConfigurationOptions, Configuration, IConfigurationValues, IConfigurationData } from 'vs/platform/configuration/common/configuration'; +import { ConfigurationSource, IConfigurationService, IConfigurationServiceEvent, IConfigurationValue, IConfigurationKeys, ConfigurationModel, IConfigurationOverrides, Configuration, IConfigurationValues, IConfigurationData } from 'vs/platform/configuration/common/configuration'; import { CustomConfigurationModel, DefaultConfigurationModel } from 'vs/platform/configuration/common/model'; import Event, { Emitter } from 'vs/base/common/event'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; @@ -67,10 +67,8 @@ export class ConfigurationService extends Disposable implements IConfiguratio }); } - public getConfiguration(section?: string): C - public getConfiguration(options?: IConfigurationOptions): C - public getConfiguration(arg?: any): C { - return this.configuration().getValue(this.toOptions(arg)); + public getConfiguration(section?: string, options?: IConfigurationOverrides): C { + return this.configuration().getValue(section, options); } public lookup(key: string, overrideIdentifier?: string): IConfigurationValue { @@ -93,16 +91,6 @@ export class ConfigurationService extends Disposable implements IConfiguratio this._configuration = this.consolidateConfigurations(); } - private toOptions(arg: any): IConfigurationOptions { - if (typeof arg === 'string') { - return { section: arg }; - } - if (typeof arg === 'object') { - return arg; - } - return {}; - } - private consolidateConfigurations(): Configuration { const defaults = new DefaultConfigurationModel(); const user = this.userConfigModelWatcher.getConfig(); diff --git a/src/vs/workbench/browser/parts/editor/textDiffEditor.ts b/src/vs/workbench/browser/parts/editor/textDiffEditor.ts index e22ac2936ab..c9eb1f6aa13 100644 --- a/src/vs/workbench/browser/parts/editor/textDiffEditor.ts +++ b/src/vs/workbench/browser/parts/editor/textDiffEditor.ts @@ -217,7 +217,7 @@ export class TextDiffEditor extends BaseTextEditor { const language = this.getLanguage(); if (language) { - objects.assign(editorConfiguration, this.configurationService.getConfiguration({ overrideIdentifier: language, section: 'diffEditor' })); + objects.assign(editorConfiguration, this.configurationService.getConfiguration('diffEditor', { language })); } return editorConfiguration; diff --git a/src/vs/workbench/browser/parts/editor/textEditor.ts b/src/vs/workbench/browser/parts/editor/textEditor.ts index c926a9d2e17..c344a1c89a3 100644 --- a/src/vs/workbench/browser/parts/editor/textEditor.ts +++ b/src/vs/workbench/browser/parts/editor/textEditor.ts @@ -119,7 +119,7 @@ export abstract class BaseTextEditor extends BaseEditor { const overrides = {}; const resource = this.getResource(); if (resource) { - objects.assign(overrides, this.configurationService.getConfiguration({ /*resource: this.getResource(), */overrideIdentifier: this.getLanguage(), section: 'editor' })); + objects.assign(overrides, this.configurationService.getConfiguration('editor', { language: this.getLanguage(), /*resource: this.getResource(), */ })); } objects.assign(overrides, { diff --git a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts index 1187473c057..ac247b050eb 100644 --- a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts +++ b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts @@ -419,7 +419,7 @@ export class WalkThroughPart extends BaseEditor { } private getEditorOptions(language: string): IEditorOptions { - const config = this.configurationService.getConfiguration({ overrideIdentifier: language, section: 'editor' }); + const config = this.configurationService.getConfiguration('editor', { language }); return { ...isObject(config) ? config : Object.create(null), scrollBeyondLastLine: false, diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index 2970fb389cd..d5e4872ebdf 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -24,7 +24,7 @@ import { isLinux } from 'vs/base/common/platform'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { CustomConfigurationModel } from 'vs/platform/configuration/common/model'; import { ScopedConfigurationModel, FolderConfigurationModel, FolderSettingsModel } from 'vs/workbench/services/configuration/common/configurationModels'; -import { IConfigurationServiceEvent, ConfigurationSource, IConfigurationKeys, IConfigurationValue, ConfigurationModel, IConfigurationOptions, Configuration as BaseConfiguration, IConfigurationValues, IConfigurationData } from 'vs/platform/configuration/common/configuration'; +import { IConfigurationServiceEvent, ConfigurationSource, IConfigurationKeys, IConfigurationValue, ConfigurationModel, IConfigurationOverrides, Configuration as BaseConfiguration, IConfigurationValues, IConfigurationData } from 'vs/platform/configuration/common/configuration'; import { IWorkspaceConfigurationService, WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME, WORKSPACE_STANDALONE_CONFIGURATIONS, WORKSPACE_CONFIG_DEFAULT_PATH } from 'vs/workbench/services/configuration/common/configuration'; import { ConfigurationService as GlobalConfigurationService } from 'vs/platform/configuration/node/configurationService'; import { createHash } from "crypto"; @@ -201,10 +201,8 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp return this._configuration; } - public getConfiguration(section?: string): C - public getConfiguration(options?: IConfigurationOptions): C - public getConfiguration(arg?: any): C { - return this._configuration.getValue(this.toOptions(arg)); + public getConfiguration(section?: string, overrides?: IConfigurationOverrides): C { + return this._configuration.getValue(section, overrides); } public lookup(key: string, overrideIdentifier?: string): IConfigurationValue { @@ -310,16 +308,6 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp private trigger(source: ConfigurationSource, sourceConfig: any = this._configuration.getFolderConfigurationModel(this.workspace.roots[0]).contents): void { this._onDidUpdateConfiguration.fire({ source, sourceConfig }); } - - private toOptions(arg: any): IConfigurationOptions { - if (typeof arg === 'string') { - return { section: arg }; - } - if (typeof arg === 'object') { - return arg; - } - return {}; - } } class FolderConfiguration extends Disposable { @@ -539,9 +527,9 @@ class Configuration extends BaseConfiguration { updateFolderConfiguration(resource: URI, configuration: FolderConfigurationModel): boolean { this.folders.set(resource, configuration); - const current = this.getValue({ resource }); + const current = this.getValue(null, { resource }); this.mergeFolder(resource); - return !objects.equals(current, this.getValue({ resource })); + return !objects.equals(current, this.getValue(null, { resource })); } deleteFolderConfiguration(folder: URI): boolean { @@ -572,7 +560,7 @@ class Configuration extends BaseConfiguration { } for (const resource of this._foldersConsolidated.keys()) { - if (!objects.equals(this.getValue({ resource }), other.getValue({ resource }))) { + if (!objects.equals(this.getValue(null, { resource }), other.getValue(null, { resource }))) { return false; } } diff --git a/src/vs/workbench/services/keybinding/common/keybindingEditing.ts b/src/vs/workbench/services/keybinding/common/keybindingEditing.ts index abfa76b0210..e947aa7dc94 100644 --- a/src/vs/workbench/services/keybinding/common/keybindingEditing.ts +++ b/src/vs/workbench/services/keybinding/common/keybindingEditing.ts @@ -215,7 +215,7 @@ export class KeybindingsEditingService extends Disposable implements IKeybinding private resolveModelReference(): TPromise> { return this.fileService.existsFile(this.resource) .then(exists => { - const EOL = this.configurationService.getConfiguration({ section: 'files', overrideIdentifier: 'json' })['eol']; + const EOL = this.configurationService.getConfiguration('files', { language: 'json' })['eol']; const result = exists ? TPromise.as(null) : this.fileService.updateContent(this.resource, this.getEmptyContent(EOL), { encoding: 'utf8' }); return result.then(() => this.textModelResolverService.createModelReference(this.resource)); }); -- GitLab From ee2de29cf0416107559a71c911b111aa1335872b Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Thu, 15 Jun 2017 22:44:14 +0200 Subject: [PATCH 0906/1347] #28538 Implement resource overrides for settings --- src/vs/platform/configuration/common/configuration.ts | 10 +++++----- src/vs/workbench/browser/parts/editor/textEditor.ts | 2 +- .../services/configuration/node/configuration.ts | 1 + 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/src/vs/platform/configuration/common/configuration.ts b/src/vs/platform/configuration/common/configuration.ts index ac8016e30ab..94e02b37a29 100644 --- a/src/vs/platform/configuration/common/configuration.ts +++ b/src/vs/platform/configuration/common/configuration.ts @@ -241,8 +241,8 @@ export class Configuration { } } - getValue(section: string = '', options: IConfigurationOverrides = {}): C { - const configModel = this.getConfigurationModel(options); + getValue(section: string = '', overrides: IConfigurationOverrides = {}): C { + const configModel = this.getConfigurationModel(overrides); return section ? configModel.getContentsFor(section) : configModel.contents; } @@ -296,9 +296,9 @@ export class Configuration { return result; } - private getConfigurationModel(options: IConfigurationOverrides): ConfigurationModel { - let configurationModel = (options.resource ? this._foldersConsolidated.get(options.resource) : this._workspace) || new ConfigurationModel(); - return options.language ? configurationModel.override(options.language) : configurationModel; + private getConfigurationModel(overrides: IConfigurationOverrides): ConfigurationModel { + let configurationModel = overrides.resource ? this._foldersConsolidated.get(overrides.resource) || this._workspace : this._workspace; + return overrides.language ? configurationModel.override(overrides.language) : configurationModel; } public toData(): IConfigurationData { diff --git a/src/vs/workbench/browser/parts/editor/textEditor.ts b/src/vs/workbench/browser/parts/editor/textEditor.ts index c344a1c89a3..4cbf6a0caf0 100644 --- a/src/vs/workbench/browser/parts/editor/textEditor.ts +++ b/src/vs/workbench/browser/parts/editor/textEditor.ts @@ -119,7 +119,7 @@ export abstract class BaseTextEditor extends BaseEditor { const overrides = {}; const resource = this.getResource(); if (resource) { - objects.assign(overrides, this.configurationService.getConfiguration('editor', { language: this.getLanguage(), /*resource: this.getResource(), */ })); + objects.assign(overrides, this.configurationService.getConfiguration('editor', { language: this.getLanguage(), resource: this.getResource() })); } objects.assign(overrides, { diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index d5e4872ebdf..e5613d3190b 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -202,6 +202,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } public getConfiguration(section?: string, overrides?: IConfigurationOverrides): C { + overrides = overrides && overrides.resource ? { ...overrides, resource: this.getRoot(overrides.resource) } : overrides; return this._configuration.getValue(section, overrides); } -- GitLab From 540930d5909093926b3534b1a81dbbce4dcae62f Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Thu, 15 Jun 2017 16:28:31 -0700 Subject: [PATCH 0907/1347] Pick up TS 2.4.1 insiders --- extensions/npm-shrinkwrap.json | 6 +++--- extensions/package.json | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/extensions/npm-shrinkwrap.json b/extensions/npm-shrinkwrap.json index 278e305e39b..25febab5619 100644 --- a/extensions/npm-shrinkwrap.json +++ b/extensions/npm-shrinkwrap.json @@ -3,9 +3,9 @@ "version": "0.0.1", "dependencies": { "typescript": { - "version": "2.3.4", - "from": "typescript@2.3.4", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-2.3.4.tgz" + "version": "2.4.1-insiders.20170615", + "from": "typescript@2.4.1-insiders.20170615", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-2.4.1-insiders.20170615.tgz" } } } diff --git a/extensions/package.json b/extensions/package.json index 180253c59ae..29c909ce5cc 100644 --- a/extensions/package.json +++ b/extensions/package.json @@ -3,7 +3,7 @@ "version": "0.0.1", "description": "Dependencies shared by all extensions", "dependencies": { - "typescript": "2.3.4" + "typescript": "2.4.1-insiders.20170615" }, "scripts": { "postinstall": "node ./postinstall" -- GitLab From 137b31c4ae2134e62168525c07e5cd970fb4dce5 Mon Sep 17 00:00:00 2001 From: aefernandes Date: Thu, 15 Jun 2017 16:32:33 -0700 Subject: [PATCH 0908/1347] changed command palette text --- .../parts/welcome/page/electron-browser/vs_code_welcome_page.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.ts b/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.ts index 2fe5fc81aa1..bf03a6df344 100644 --- a/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.ts +++ b/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.ts @@ -66,7 +66,7 @@ export default () => `

    ${escape(localize('welcomePage.learn', "Learn"))}

      -
    • +
    -- GitLab From baf54ef06f24cfc92f6c49cd2b972f8bec34f7e2 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Thu, 15 Jun 2017 17:20:00 -0700 Subject: [PATCH 0909/1347] Collapse html,css completion provider for emmet --- .../emmet/src/emmetCompletionProvider.ts | 51 +++++++------------ extensions/emmet/src/extension.ts | 21 +++----- 2 files changed, 23 insertions(+), 49 deletions(-) diff --git a/extensions/emmet/src/emmetCompletionProvider.ts b/extensions/emmet/src/emmetCompletionProvider.ts index 84d762988d2..3ba492bbf12 100644 --- a/extensions/emmet/src/emmetCompletionProvider.ts +++ b/extensions/emmet/src/emmetCompletionProvider.ts @@ -6,12 +6,12 @@ import * as vscode from 'vscode'; import { expand, createSnippetsRegistry } from '@emmetio/expand-abbreviation'; -import { getSyntax, getProfile, extractAbbreviation } from './util'; +import { getSyntax, getProfile, extractAbbreviation, isStyleSheet } from './util'; const field = (index, placeholder) => `\${${index}${placeholder ? ':' + placeholder : ''}}`; const snippetCompletionsCache = new Map(); -export abstract class EmmetCompletionItemProviderBase implements vscode.CompletionItemProvider { +export class EmmetCompletionItemProvider implements vscode.CompletionItemProvider { public provideCompletionItems(document: vscode.TextDocument, position: vscode.Position, token: vscode.CancellationToken): Thenable { @@ -19,15 +19,27 @@ export abstract class EmmetCompletionItemProviderBase implements vscode.Completi return Promise.resolve(null); } + let completionItems: vscode.CompletionItem[] = []; + let syntax = getSyntax(document); let currentWord = getCurrentWord(document, position); let expandedAbbr = this.getExpandedAbbreviation(document, position); - let abbreviationSuggestions = this.getAbbreviationSuggestions(getSyntax(document), currentWord, (expandedAbbr && currentWord === expandedAbbr.label)); - let completionItems = expandedAbbr ? [expandedAbbr, ...abbreviationSuggestions] : abbreviationSuggestions; + + if (!isStyleSheet(syntax)) { + if (expandedAbbr) { + // In non stylesheet like syntax, this extension returns expanded abbr plus posssible abbr completions + // To differentiate between the 2, the former is given CompletionItemKind.Value so that it gets a different icon + expandedAbbr.kind = vscode.CompletionItemKind.Value; + } + let abbreviationSuggestions = this.getAbbreviationSuggestions(syntax, currentWord, (expandedAbbr && currentWord === expandedAbbr.label)); + completionItems = expandedAbbr ? [expandedAbbr, ...abbreviationSuggestions] : abbreviationSuggestions; + } else { + completionItems = expandedAbbr ? [expandedAbbr] : []; + } return Promise.resolve(new vscode.CompletionList(completionItems, true)); } - protected getExpandedAbbreviation(document: vscode.TextDocument, position: vscode.Position): vscode.CompletionItem { + getExpandedAbbreviation(document: vscode.TextDocument, position: vscode.Position): vscode.CompletionItem { if (!vscode.workspace.getConfiguration('emmet')['showExpandedAbbreviation']) { return; } @@ -53,25 +65,6 @@ export abstract class EmmetCompletionItemProviderBase implements vscode.Completi return completionitem; } - abstract getAbbreviationSuggestions(syntax: string, prefix: string, skipExactMatch: boolean): vscode.CompletionItem[]; - -} - -export class EmmetCompletionItemProviderHtml extends EmmetCompletionItemProviderBase { - - protected getExpandedAbbreviation(document: vscode.TextDocument, position: vscode.Position): vscode.CompletionItem { - let completionItem = super.getExpandedAbbreviation(document, position); - - if (completionItem) { - // In non stylesheet like syntax, this extension returns expanded abbr plus posssible abbr completions - // To differentiate between the 2, the former is given CompletionItemKind.Value so that it gets a different icon - completionItem.kind = vscode.CompletionItemKind.Value; - } - - - return completionItem; - } - getAbbreviationSuggestions(syntax: string, prefix: string, skipExactMatch: boolean) { if (!vscode.workspace.getConfiguration('emmet')['showAbbreviationSuggestions'] || !prefix) { return []; @@ -102,19 +95,9 @@ export class EmmetCompletionItemProviderHtml extends EmmetCompletionItemProvider } - } -export class EmmetCompletionItemProviderCss extends EmmetCompletionItemProviderBase { - public provideCompletionItems(document: vscode.TextDocument, position: vscode.Position, token: vscode.CancellationToken): Thenable { - return super.provideCompletionItems(document, position, token); - } - - getAbbreviationSuggestions(syntax: string, prefix: string, skipExactMatch: boolean) { - return []; - } -} function getCurrentWord(document: vscode.TextDocument, position: vscode.Position): string { let wordAtPosition = document.getWordRangeAtPosition(position); diff --git a/extensions/emmet/src/extension.ts b/extensions/emmet/src/extension.ts index 23f9190743d..da9ce80a275 100644 --- a/extensions/emmet/src/extension.ts +++ b/extensions/emmet/src/extension.ts @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ import * as vscode from 'vscode'; -import { EmmetCompletionItemProviderHtml, EmmetCompletionItemProviderCss } from './emmetCompletionProvider'; +import { EmmetCompletionItemProvider } from './emmetCompletionProvider'; import { expandAbbreviation, wrapWithAbbreviation } from './abbreviationActions'; import { removeTag } from './removeTag'; import { updateTag } from './updateTag'; @@ -21,7 +21,7 @@ interface ISupportedLanguageMode { triggerCharacters: string[]; } -const HTML_LANGUAGE_MODES: ISupportedLanguageMode[] = [ +const LANGUAGE_MODES: ISupportedLanguageMode[] = [ { id: 'html', triggerCharacters: ['!', '.', '}'] }, { id: 'jade', triggerCharacters: ['!', '.', '}'] }, { id: 'slim', triggerCharacters: ['!', '.', '}'] }, @@ -30,10 +30,8 @@ const HTML_LANGUAGE_MODES: ISupportedLanguageMode[] = [ { id: 'xsl', triggerCharacters: ['.', '}'] }, { id: 'javascriptreact', triggerCharacters: ['.'] }, - { id: 'typescriptreact', triggerCharacters: ['.'] } -]; + { id: 'typescriptreact', triggerCharacters: ['.'] }, -const CSS_LANGUAGE_MODES: ISupportedLanguageMode[] = [ { id: 'css', triggerCharacters: [':'] }, { id: 'scss', triggerCharacters: [':'] }, { id: 'sass', triggerCharacters: [':'] }, @@ -42,16 +40,9 @@ const CSS_LANGUAGE_MODES: ISupportedLanguageMode[] = [ ]; export function activate(context: vscode.ExtensionContext) { - let completionProviderHtml = new EmmetCompletionItemProviderHtml(); - let completionProviderCss = new EmmetCompletionItemProviderCss(); - - for (let language of HTML_LANGUAGE_MODES) { - const provider = vscode.languages.registerCompletionItemProvider({ language: language.id }, completionProviderHtml, ...language.triggerCharacters); - context.subscriptions.push(provider); - } - - for (let language of CSS_LANGUAGE_MODES) { - const provider = vscode.languages.registerCompletionItemProvider({ language: language.id }, completionProviderCss, ...language.triggerCharacters); + let completionProvider = new EmmetCompletionItemProvider(); + for (let language of LANGUAGE_MODES) { + const provider = vscode.languages.registerCompletionItemProvider({ language: language.id }, completionProvider, ...language.triggerCharacters); context.subscriptions.push(provider); } -- GitLab From e9ec53eb7acec373912d1eda5bf61fed594d223d Mon Sep 17 00:00:00 2001 From: Rohith Reddy Kumbharkar Date: Fri, 16 Jun 2017 05:54:47 +0530 Subject: [PATCH 0910/1347] Added functionality to toggle break rendering mode for markdown preview (#28713) --- extensions/markdown/package.json | 5 +++++ extensions/markdown/package.nls.json | 1 + extensions/markdown/src/markdownEngine.ts | 3 +++ extensions/markdown/src/previewContentProvider.ts | 2 ++ 4 files changed, 11 insertions(+) diff --git a/extensions/markdown/package.json b/extensions/markdown/package.json index cbcb63c5531..06f6b18e44f 100644 --- a/extensions/markdown/package.json +++ b/extensions/markdown/package.json @@ -159,6 +159,11 @@ "default": "hide", "description": "%markdown.previewFrontMatter.dec%" }, + "markdown.preview.breaks": { + "type": "boolean", + "default": false, + "description": "%markdown.preview.breaks.desc%" + }, "markdown.preview.fontFamily": { "type": "string", "default": "-apple-system, BlinkMacSystemFont, 'Segoe WPC', 'Segoe UI', 'HelveticaNeue-Light', 'Ubuntu', 'Droid Sans', sans-serif", diff --git a/extensions/markdown/package.nls.json b/extensions/markdown/package.nls.json index b58fe4c5e40..11e191a7732 100644 --- a/extensions/markdown/package.nls.json +++ b/extensions/markdown/package.nls.json @@ -1,4 +1,5 @@ { + "markdown.preview.breaks.desc": "Sets how line-breaks are rendered in the markdown preview. Setting it to 'true' creates a
    for every newline.", "markdown.preview.doubleClickToSwitchToEditor.desc": "Double click in the markdown preview to switch to the editor.", "markdown.preview.fontFamily.desc": "Controls the font family used in the markdown preview.", "markdown.preview.fontSize.desc": "Controls the font size in pixels used in the markdown preview.", diff --git a/extensions/markdown/src/markdownEngine.ts b/extensions/markdown/src/markdownEngine.ts index aad5d484645..c13130b98b9 100644 --- a/extensions/markdown/src/markdownEngine.ts +++ b/extensions/markdown/src/markdownEngine.ts @@ -20,6 +20,8 @@ interface MarkdownIt { parse(text: string, env: any): IToken[]; utils: any; + + set(options: any): MarkdownIt; } const FrontMatterRegex = /^---\s*[^]*?(-{3}|\.{3})\s*/; @@ -79,6 +81,7 @@ export class MarkdownEngine { this.addLinkNormalizer(this.md); this.addLinkValidator(this.md); } + this.md.set({ breaks: vscode.workspace.getConfiguration('markdown').get('preview.breaks', false) }); return this.md; } diff --git a/extensions/markdown/src/previewContentProvider.ts b/extensions/markdown/src/previewContentProvider.ts index 8f6d925059c..346232bbc51 100644 --- a/extensions/markdown/src/previewContentProvider.ts +++ b/extensions/markdown/src/previewContentProvider.ts @@ -52,6 +52,7 @@ class MarkdownPreviewConfig { public readonly scrollBeyondLastLine: boolean; public readonly wordWrap: boolean; public readonly previewFrontMatter: string; + public readonly lineBreaks: boolean; public readonly doubleClickToSwitchToEditor: boolean; public readonly scrollEditorWithPreview: boolean; public readonly scrollPreviewWithEditorSelection: boolean; @@ -77,6 +78,7 @@ class MarkdownPreviewConfig { this.previewFrontMatter = markdownConfig.get('previewFrontMatter', 'hide'); this.scrollPreviewWithEditorSelection = !!markdownConfig.get('preview.scrollPreviewWithEditorSelection', true); this.scrollEditorWithPreview = !!markdownConfig.get('preview.scrollEditorWithPreview', true); + this.lineBreaks = !!markdownConfig.get('preview.breaks', false); this.doubleClickToSwitchToEditor = !!markdownConfig.get('preview.doubleClickToSwitchToEditor', true); this.markEditorSelection = !!markdownConfig.get('preview.markEditorSelection', true); -- GitLab From 73015a5e052e6de8ecd60eed2670bea81fad8cac Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Thu, 15 Jun 2017 17:27:12 -0700 Subject: [PATCH 0911/1347] Restrict index csp --- src/vs/workbench/electron-browser/bootstrap/index.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/electron-browser/bootstrap/index.html b/src/vs/workbench/electron-browser/bootstrap/index.html index 29b73eae7c1..c14ebbe8653 100644 --- a/src/vs/workbench/electron-browser/bootstrap/index.html +++ b/src/vs/workbench/electron-browser/bootstrap/index.html @@ -3,7 +3,7 @@ - + -- GitLab From 5059f47ee2220e3ccd500b29d81c97036c134a16 Mon Sep 17 00:00:00 2001 From: Rohith Reddy Kumbharkar Date: Fri, 16 Jun 2017 11:17:38 +0530 Subject: [PATCH 0912/1347] Fixes issue #28695 with tooltips in Activity Bar (#28783) --- src/vs/workbench/browser/parts/activitybar/activitybarActions.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts b/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts index 6deb54dcab2..17d00aba4da 100644 --- a/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts +++ b/src/vs/workbench/browser/parts/activitybar/activitybarActions.ts @@ -445,6 +445,7 @@ export class ViewletActionItem extends ActivityActionItem { this.$label.title(title); this.$badge.title(title); + this.$container.title(title); } protected _updateClass(): void { -- GitLab From 81b98b8870e78acf055d3753f86cd82c10839873 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Fri, 16 Jun 2017 07:49:51 +0200 Subject: [PATCH 0913/1347] Adopt ext host to use configuration tree data --- .../mainThreadConfiguration.ts | 2 +- src/vs/workbench/api/node/extHost.protocol.ts | 6 +- .../api/node/extHostConfiguration.ts | 47 +++----- .../electron-browser/extensionHost.ts | 2 +- .../api/extHostConfiguration.test.ts | 110 ++++++++++-------- 5 files changed, 86 insertions(+), 81 deletions(-) diff --git a/src/vs/workbench/api/electron-browser/mainThreadConfiguration.ts b/src/vs/workbench/api/electron-browser/mainThreadConfiguration.ts index f3d1533b7db..b08d8877d07 100644 --- a/src/vs/workbench/api/electron-browser/mainThreadConfiguration.ts +++ b/src/vs/workbench/api/electron-browser/mainThreadConfiguration.ts @@ -26,7 +26,7 @@ export class MainThreadConfiguration extends MainThreadConfigurationShape { const proxy = threadService.get(ExtHostContext.ExtHostConfiguration); this._toDispose = configurationService.onDidUpdateConfiguration(() => { - proxy.$acceptConfigurationChanged(configurationService.values()); + proxy.$acceptConfigurationChanged(configurationService.getConfigurationData()); }); } diff --git a/src/vs/workbench/api/node/extHost.protocol.ts b/src/vs/workbench/api/node/extHost.protocol.ts index bed2bbb9b76..0cd7ab1785a 100644 --- a/src/vs/workbench/api/node/extHost.protocol.ts +++ b/src/vs/workbench/api/node/extHost.protocol.ts @@ -30,7 +30,7 @@ import { IResourceEdit } from 'vs/editor/common/services/bulkEdit'; import { ITextSource } from 'vs/editor/common/model/textSource'; import { ConfigurationTarget } from 'vs/workbench/services/configuration/common/configurationEditing'; -import { IConfigurationValues } from 'vs/platform/configuration/common/configuration'; +import { IConfigurationData } from 'vs/platform/configuration/common/configuration'; import { IPickOpenEntry, IPickOptions } from 'vs/platform/quickOpen/common/quickOpen'; import { SaveReason } from 'vs/workbench/services/textfile/common/textfiles'; @@ -67,7 +67,7 @@ export interface IInitData { environment: IEnvironment; workspace: IWorkspaceData; extensions: IExtensionDescription[]; - configuration: IConfigurationValues; + configuration: IConfigurationData; telemetryInfo: ITelemetryInfo; } @@ -349,7 +349,7 @@ export abstract class ExtHostCommandsShape { } export abstract class ExtHostConfigurationShape { - $acceptConfigurationChanged(values: IConfigurationValues) { throw ni(); } + $acceptConfigurationChanged(data: IConfigurationData) { throw ni(); } } export abstract class ExtHostDiagnosticsShape { diff --git a/src/vs/workbench/api/node/extHostConfiguration.ts b/src/vs/workbench/api/node/extHostConfiguration.ts index 3147509dde8..5ee24322929 100644 --- a/src/vs/workbench/api/node/extHostConfiguration.ts +++ b/src/vs/workbench/api/node/extHostConfiguration.ts @@ -8,9 +8,8 @@ import { mixin } from 'vs/base/common/objects'; import Event, { Emitter } from 'vs/base/common/event'; import { WorkspaceConfiguration } from 'vscode'; import { ExtHostConfigurationShape, MainThreadConfigurationShape } from './extHost.protocol'; -import { IConfigurationValues } from 'vs/platform/configuration/common/configuration'; +import { IConfigurationData, Configuration } from 'vs/platform/configuration/common/configuration'; import { ConfigurationTarget } from 'vs/workbench/services/configuration/common/configurationEditing'; -import { toValuesTree } from 'vs/platform/configuration/common/model'; function lookUp(tree: any, key: string) { if (key) { @@ -23,51 +22,41 @@ function lookUp(tree: any, key: string) { } } -interface UsefulConfiguration { - data: IConfigurationValues; - valueTree: any; -} - -function createUsefulConfiguration(data: IConfigurationValues): { data: IConfigurationValues, valueTree: any } { - const valueMap: { [key: string]: any } = Object.create(null); - for (let key in data) { - if (Object.prototype.hasOwnProperty.call(data, key)) { - valueMap[key] = data[key].value; - } - } - const valueTree = toValuesTree(valueMap, message => console.error(`Conflict in configuration settings: ${message}`)); - return { - data, - valueTree - }; -} - export class ExtHostConfiguration extends ExtHostConfigurationShape { private _onDidChangeConfiguration = new Emitter(); private _proxy: MainThreadConfigurationShape; - private _configuration: UsefulConfiguration; + private _data: IConfigurationData; + private _configuration: Configuration; - constructor(proxy: MainThreadConfigurationShape, data: IConfigurationValues) { + constructor(proxy: MainThreadConfigurationShape, data: IConfigurationData) { super(); this._proxy = proxy; - this._configuration = createUsefulConfiguration(data); + this._data = data; } get onDidChangeConfiguration(): Event { return this._onDidChangeConfiguration && this._onDidChangeConfiguration.event; } - public $acceptConfigurationChanged(data: IConfigurationValues) { - this._configuration = createUsefulConfiguration(data); + public $acceptConfigurationChanged(data: IConfigurationData) { + this._configuration = null; + this._data = data; this._onDidChangeConfiguration.fire(undefined); } + private get configuration(): Configuration { + if (!this._configuration) { + this._configuration = Configuration.parse(this._data); + } + return this._configuration; + } + public getConfiguration(section?: string): WorkspaceConfiguration { const config = section - ? lookUp(this._configuration.valueTree, section) - : this._configuration.valueTree; + ? lookUp(this.configuration.getValue(), section) + : this.configuration.getValue(); const result: WorkspaceConfiguration = { has(key: string): boolean { @@ -91,7 +80,7 @@ export class ExtHostConfiguration extends ExtHostConfigurationShape { }, inspect: (key: string): { key: string; defaultValue?: T; globalValue?: T; workspaceValue?: T } => { key = section ? `${section}.${key}` : key; - const config = this._configuration.data[key]; + const config = this.configuration.values()[key]; if (config) { return { key, diff --git a/src/vs/workbench/electron-browser/extensionHost.ts b/src/vs/workbench/electron-browser/extensionHost.ts index 0e29ffee236..7c29456900e 100644 --- a/src/vs/workbench/electron-browser/extensionHost.ts +++ b/src/vs/workbench/electron-browser/extensionHost.ts @@ -290,7 +290,7 @@ export class ExtensionHostProcessWorker { }, workspace: this.contextService.getWorkspace2(), extensions: extensionDescriptions, - configuration: this.configurationService.values(), + configuration: this.configurationService.getConfigurationData(), telemetryInfo }; }); diff --git a/src/vs/workbench/test/electron-browser/api/extHostConfiguration.test.ts b/src/vs/workbench/test/electron-browser/api/extHostConfiguration.test.ts index d449d5627ad..acdf7e0de9f 100644 --- a/src/vs/workbench/test/electron-browser/api/extHostConfiguration.test.ts +++ b/src/vs/workbench/test/electron-browser/api/extHostConfiguration.test.ts @@ -10,7 +10,7 @@ import { ExtHostConfiguration } from 'vs/workbench/api/node/extHostConfiguration import { MainThreadConfigurationShape } from 'vs/workbench/api/node/extHost.protocol'; import { TPromise } from 'vs/base/common/winjs.base'; import { ConfigurationTarget, ConfigurationEditingErrorCode, IConfigurationEditingError } from 'vs/workbench/services/configuration/common/configurationEditing'; -import { IConfigurationValues, IConfigurationValue } from 'vs/platform/configuration/common/configuration'; +import { ConfigurationModel } from 'vs/platform/configuration/common/configuration'; suite('ExtHostConfiguration', function () { @@ -22,25 +22,25 @@ suite('ExtHostConfiguration', function () { } }; - function createExtHostConfiguration(data: IConfigurationValues = Object.create(null), shape?: MainThreadConfigurationShape) { + function createExtHostConfiguration(contents: any = Object.create(null), shape?: MainThreadConfigurationShape) { if (!shape) { shape = new class extends MainThreadConfigurationShape { }; } - return new ExtHostConfiguration(shape, data); - } - - function createConfigurationValue(value: T): IConfigurationValue { - return { - value, - default: value, - user: undefined, - workspace: undefined - }; + return new ExtHostConfiguration(shape, { + defaults: new ConfigurationModel(contents), + user: new ConfigurationModel(contents), + folders: Object.create(null), + workspaceUri: void 0 + }); } test('getConfiguration fails regression test 1.7.1 -> 1.8 #15552', function () { const extHostConfig = createExtHostConfiguration({ - ['search.exclude']: createConfigurationValue({ '**/node_modules': true }) + 'search': { + 'exclude': { + '**/node_modules': true + } + } }); assert.equal(extHostConfig.getConfiguration('search.exclude')['**/node_modules'], true); @@ -54,10 +54,14 @@ suite('ExtHostConfiguration', function () { test('has/get', function () { const all = createExtHostConfiguration({ - ['farboo.config0']: createConfigurationValue(true), - ['farboo.nested.config1']: createConfigurationValue(42), - ['farboo.nested.config2']: createConfigurationValue('Das Pferd frisst kein Reis.'), - ['farboo.config4']: createConfigurationValue('') + 'farboo': { + 'config0': true, + 'nested': { + 'config1': 42, + 'config2': 'Das Pferd frisst kein Reis.' + }, + 'config4': '' + } }); const config = all.getConfiguration('farboo'); @@ -80,8 +84,10 @@ suite('ExtHostConfiguration', function () { test('getConfiguration vs get', function () { const all = createExtHostConfiguration({ - ['farboo.config0']: createConfigurationValue(true), - ['farboo.config4']: createConfigurationValue(38) + 'farboo': { + 'config0': true, + 'config4': 38 + } }); let config = all.getConfiguration('farboo.config0'); @@ -96,8 +102,10 @@ suite('ExtHostConfiguration', function () { test('getConfiguration vs get', function () { const all = createExtHostConfiguration({ - ['farboo.config0']: createConfigurationValue(true), - ['farboo.config4']: createConfigurationValue(38) + 'farboo': { + 'config0': true, + 'config4': 38 + } }); let config = all.getConfiguration('farboo.config0'); @@ -111,7 +119,9 @@ suite('ExtHostConfiguration', function () { test('name vs property', function () { const all = createExtHostConfiguration({ - ['farboo.get']: createConfigurationValue('get-prop') + 'farboo': { + 'get': 'get-prop' + } }); const config = all.getConfiguration('farboo'); @@ -125,8 +135,10 @@ suite('ExtHostConfiguration', function () { const shape = new RecordingShape(); const allConfig = createExtHostConfiguration({ - ['foo.bar']: createConfigurationValue(1), - ['foo.far']: createConfigurationValue(1) + 'foo': { + 'bar': 1, + 'far': 1 + } }, shape); let config = allConfig.getConfiguration('foo'); @@ -146,7 +158,9 @@ suite('ExtHostConfiguration', function () { test('update, what is #15834', function () { const shape = new RecordingShape(); const allConfig = createExtHostConfiguration({ - ['editor.formatOnSave']: createConfigurationValue(true) + 'editor': { + 'formatOnSave': true + } }, shape); allConfig.getConfiguration('editor').update('formatOnSave', { extensions: ['ts'] }); @@ -154,28 +168,30 @@ suite('ExtHostConfiguration', function () { assert.deepEqual(shape.lastArgs[2], { extensions: ['ts'] }); }); - test('bogous data, #15834', function () { - let oldLogger = console.error; - let errorLogged = false; - - // workaround until we have a proper logging story - console.error = (message, args) => { - errorLogged = true; - }; - let allConfig; - try { - const shape = new RecordingShape(); - allConfig = createExtHostConfiguration({ - ['editor.formatOnSave']: createConfigurationValue(true), - ['editor.formatOnSave.extensions']: createConfigurationValue(['ts']) - }, shape); - } finally { - console.error = oldLogger; - } - assert.ok(errorLogged); - assert.ok(allConfig.getConfiguration('').has('editor.formatOnSave')); - assert.ok(!allConfig.getConfiguration('').has('editor.formatOnSave.extensions')); - }); + /* + test('bogous data, #15834', function () { + let oldLogger = console.error; + let errorLogged = false; + + // workaround until we have a proper logging story + console.error = (message, args) => { + errorLogged = true; + }; + let allConfig; + try { + const shape = new RecordingShape(); + allConfig = createExtHostConfiguration({ + ['editor.formatOnSave']: createConfigurationValue(true), + ['editor.formatOnSave.extensions']: createConfigurationValue(['ts']) + }, shape); + } finally { + console.error = oldLogger; + } + assert.ok(errorLogged); + assert.ok(allConfig.getConfiguration('').has('editor.formatOnSave')); + assert.ok(!allConfig.getConfiguration('').has('editor.formatOnSave.extensions')); + }); + */ test('update/error-state not OK', function () { -- GitLab From 8f2523c4b12efa371ff16b0acc77099f378bc7d2 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Fri, 16 Jun 2017 07:52:32 +0200 Subject: [PATCH 0914/1347] fix potential npe in editor.hide() --- .../workbench/browser/parts/editor/editorGroupsControl.ts | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/browser/parts/editor/editorGroupsControl.ts b/src/vs/workbench/browser/parts/editor/editorGroupsControl.ts index 4bc4a3b143a..2f9f4224462 100644 --- a/src/vs/workbench/browser/parts/editor/editorGroupsControl.ts +++ b/src/vs/workbench/browser/parts/editor/editorGroupsControl.ts @@ -519,8 +519,12 @@ export class EditorGroupsControl extends Themable implements IEditorGroupsContro // Clear Position this.clearPosition(position); - // Take editor container offdom and hide - editor.getContainer().offDOM().hide(); + // Take editor container offdom and hide. Check if the editor container + // exists in case someone manages to hide an editor before it was created + const editorContainer = editor.getContainer(); + if (editorContainer) { + editorContainer.offDOM().hide(); + } // Adjust layout and rochade if instructed to do so if (layoutAndRochade) { -- GitLab From 42d3d54267972869376b4cc8aa84bbb4fe602a14 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Fri, 16 Jun 2017 08:57:51 +0200 Subject: [PATCH 0915/1347] suggest: improve element aria label --- src/vs/editor/contrib/suggest/browser/suggestWidget.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index 5ab85e8bf03..a1f36edca85 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -134,7 +134,7 @@ class Renderer implements IRenderer { const suggestion = (element).suggestion; if (canExpandCompletionItem(element)) { - data.root.setAttribute('aria-label', nls.localize('suggestionWithDetailsAriaLabel', "{0}, suggestion, has details", suggestion.label)); + data.root.setAttribute('aria-label', nls.localize('suggestionWithDetailsAriaLabel', "{0}, suggestion, has details, press {1} to read more", suggestion.label, this.triggerKeybindingLabel)); } else { data.root.setAttribute('aria-label', nls.localize('suggestionAriaLabel', "{0}, suggestion", suggestion.label)); } -- GitLab From 1ddc7d4e7908caab71279ef5fba0a63c22ffdd15 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Thu, 15 Jun 2017 16:20:11 +0200 Subject: [PATCH 0916/1347] Fix TS 2.4 monarch issues --- .../common/modes/monarch/monarchCommon.ts | 26 ++++++++++++++++--- .../common/modes/monarch/monarchCompile.ts | 8 +++--- .../common/modes/monarch/monarchLexer.ts | 12 ++++----- 3 files changed, 32 insertions(+), 14 deletions(-) diff --git a/src/vs/editor/common/modes/monarch/monarchCommon.ts b/src/vs/editor/common/modes/monarch/monarchCommon.ts index fd72d1d0cad..070d3572d34 100644 --- a/src/vs/editor/common/modes/monarch/monarchCommon.ts +++ b/src/vs/editor/common/modes/monarch/monarchCommon.ts @@ -46,19 +46,37 @@ export interface IBracket { close: string; } +export type FuzzyAction = IAction | string; + +export function isFuzzyActionArr(what: FuzzyAction | FuzzyAction[]): what is FuzzyAction[] { + return (Array.isArray(what)); +} + +export function isFuzzyAction(what: FuzzyAction | FuzzyAction[]): what is FuzzyAction { + return !isFuzzyActionArr(what); +} + +export function isString(what: FuzzyAction): what is string { + return (typeof what === 'string'); +} + +export function isIAction(what: FuzzyAction): what is IAction { + return !isString(what); +} + export interface IRule { regex: RegExp; - action: IAction; + action: FuzzyAction; matchOnlyAtLineStart: boolean; name: string; } export interface IAction { // an action is either a group of actions - group?: IAction[]; + group?: FuzzyAction[]; // or a function that returns a fresh action - test?: (id: string, matches: string[], state: string, eos: boolean) => IAction; + test?: (id: string, matches: string[], state: string, eos: boolean) => FuzzyAction; // or it is a declarative action with a token value and various other attributes token?: string; @@ -74,7 +92,7 @@ export interface IAction { export interface IBranch { name: string; - value: IAction; + value: FuzzyAction; test: (id: string, matches: string[], state: string, eos: boolean) => boolean; } diff --git a/src/vs/editor/common/modes/monarch/monarchCompile.ts b/src/vs/editor/common/modes/monarch/monarchCompile.ts index 7f5fc6ebf60..7a41ee1a0be 100644 --- a/src/vs/editor/common/modes/monarch/monarchCompile.ts +++ b/src/vs/editor/common/modes/monarch/monarchCompile.ts @@ -118,7 +118,7 @@ function selectScrutinee(id: string, matches: string[], state: string, num: numb return null; } -function createGuard(lexer: monarchCommon.ILexerMin, ruleName: string, tkey: string, val: monarchCommon.IAction): monarchCommon.IBranch { +function createGuard(lexer: monarchCommon.ILexerMin, ruleName: string, tkey: string, val: monarchCommon.FuzzyAction): monarchCommon.IBranch { // get the scrutinee and pattern var scrut = -1; // -1: $!, 0-99: $n, 100+n: $Sn var oppat = tkey; @@ -222,7 +222,7 @@ function createGuard(lexer: monarchCommon.ILexerMin, ruleName: string, tkey: str * contains user functions as actions (which is usually not allowed), then this * may be called during lexing. It is important therefore to compile common cases efficiently */ -function compileAction(lexer: monarchCommon.ILexerMin, ruleName: string, action: any): monarchCommon.IAction { +function compileAction(lexer: monarchCommon.ILexerMin, ruleName: string, action: any): monarchCommon.FuzzyAction { if (!action) { return { token: '' }; } @@ -285,7 +285,7 @@ function compileAction(lexer: monarchCommon.ILexerMin, ruleName: string, action: } } else if (Array.isArray(action)) { - var results = []; + var results: monarchCommon.FuzzyAction[] = []; var idx: string; for (idx in action) { if (action.hasOwnProperty(idx)) { @@ -345,7 +345,7 @@ function compileAction(lexer: monarchCommon.ILexerMin, ruleName: string, action: */ class Rule implements monarchCommon.IRule { public regex: RegExp = new RegExp(''); - public action: monarchCommon.IAction = { token: '' }; + public action: monarchCommon.FuzzyAction = { token: '' }; public matchOnlyAtLineStart: boolean = false; public name: string = ''; diff --git a/src/vs/editor/common/modes/monarch/monarchLexer.ts b/src/vs/editor/common/modes/monarch/monarchLexer.ts index bc6f6381138..daf73aae631 100644 --- a/src/vs/editor/common/modes/monarch/monarchLexer.ts +++ b/src/vs/editor/common/modes/monarch/monarchLexer.ts @@ -459,7 +459,7 @@ export class MonarchTokenizer implements modes.ITokenizationSupport { continue; } let rule: monarchCommon.IRule = rules[idx]; - if (rule.action.nextEmbedded !== '@pop') { + if (monarchCommon.isIAction(rule.action) && rule.action.nextEmbedded !== '@pop') { continue; } hasEmbeddedPopRule = true; @@ -518,7 +518,7 @@ export class MonarchTokenizer implements modes.ITokenizationSupport { // regular expression group matching // these never need cloning or equality since they are only used within a line match - let groupActions: monarchCommon.IAction[] = null; + let groupActions: monarchCommon.FuzzyAction[] = null; let groupMatches: string[] = null; let groupMatched: string[] = null; let groupRule: monarchCommon.IRule = null; @@ -531,7 +531,7 @@ export class MonarchTokenizer implements modes.ITokenizationSupport { let matches: string[] = null; let matched: string = null; - let action: monarchCommon.IAction = null; + let action: monarchCommon.FuzzyAction | monarchCommon.FuzzyAction[] = null; let rule: monarchCommon.IRule = null; let enteringEmbeddedMode: string = null; @@ -604,11 +604,11 @@ export class MonarchTokenizer implements modes.ITokenizationSupport { pos += matched.length; // maybe call action function (used for 'cases') - while (action.test) { + while (monarchCommon.isFuzzyAction(action) && monarchCommon.isIAction(action) && action.test) { action = action.test(matched, matches, state, pos === lineLength); } - let result: string | monarchCommon.IAction[] = null; + let result: monarchCommon.FuzzyAction | monarchCommon.FuzzyAction[] = null; // set the result: either a string or an array of actions if (typeof action === 'string' || Array.isArray(action)) { result = action; @@ -739,7 +739,7 @@ export class MonarchTokenizer implements modes.ITokenizationSupport { // return the result (and check for brace matching) // todo: for efficiency we could pre-sanitize tokenPostfix and substitutions let tokenType: string = null; - if (result.indexOf('@brackets') === 0) { + if (monarchCommon.isString(result) && result.indexOf('@brackets') === 0) { let rest = result.substr('@brackets'.length); let bracket = findBracket(this._lexer, matched); if (!bracket) { -- GitLab From c0bd80f7f5af25a8bafc1ecaff9e867545a7a5fc Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Thu, 15 Jun 2017 16:28:15 +0200 Subject: [PATCH 0917/1347] More TS 2.4 --- src/vs/editor/common/modes/monarch/monarchLexer.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/vs/editor/common/modes/monarch/monarchLexer.ts b/src/vs/editor/common/modes/monarch/monarchLexer.ts index daf73aae631..c13adda147b 100644 --- a/src/vs/editor/common/modes/monarch/monarchLexer.ts +++ b/src/vs/editor/common/modes/monarch/monarchLexer.ts @@ -615,11 +615,12 @@ export class MonarchTokenizer implements modes.ITokenizationSupport { } else if (action.group) { result = action.group; } else if (action.token !== null && action.token !== undefined) { - result = action.token; // do $n replacements? if (action.tokenSubst) { - result = monarchCommon.substituteMatches(this._lexer, result, matched, matches, state); + result = monarchCommon.substituteMatches(this._lexer, action.token, matched, matches, state); + } else { + result = action.token; } // enter embedded mode? -- GitLab From 8abdf3bd50f7da6df85c85319004105fa9cbdde2 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Thu, 15 Jun 2017 16:54:05 +0200 Subject: [PATCH 0918/1347] Remove outdated explanations --- .../browser/controller/textAreaHandler.ts | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/src/vs/editor/browser/controller/textAreaHandler.ts b/src/vs/editor/browser/controller/textAreaHandler.ts index 40166317cbb..23acec9b604 100644 --- a/src/vs/editor/browser/controller/textAreaHandler.ts +++ b/src/vs/editor/browser/controller/textAreaHandler.ts @@ -420,25 +420,6 @@ export class TextAreaHandler extends ViewPart { Configuration.applyFontInfo(ta, this._fontInfo); } else { ta.setFontSize(1); - // Chrome does not generate input events in empty textareas that end - // up having a line height smaller than 1 screen pixel. - - // The problem is that I could not find any formula to explain how Chromium converts css px to screen px in the DOM. - // Observed values on a retina screen (by taking screenshots): - // |--------|-----------|------------|------------|-----------| - // | css px | zoomLevel | zoomFactor | pixelRatio | screen px | - // |--------|-----------|------------|------------|-----------| - // | 18 | -8 | 0.2325 | 0.5000 | 8 | - // | 18 | -7 | 0.2790 | 0.5581 | 10 | - // | 18 | -6 | 0.3348 | 0.6697 | 12 | - // | 18 | -5 | 0.4018 | 0.8037 | 14 | - // | 18 | -4 | 0.4822 | 0.9645 | 18 | - // | 18 | -3 | 0.5787 | 1.1574 | 20 | - // | 18 | -2 | 0.6944 | 1.3888 | 26 | - // | 18 | -1 | 0.8333 | 1.6666 | 30 | - // | 18 | 0 | 1.0000 | 2.0000 | 36 | - // |--------|-----------|------------|------------|-----------| - ta.setLineHeight(this._fontInfo.lineHeight); } -- GitLab From a0cf115d01069e93d438223d33c6fc6168788cfe Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 16 Jun 2017 09:18:31 +0200 Subject: [PATCH 0919/1347] Fixes #28694: Call `conf.setMaxLineNumber` before using the computed layout info --- src/vs/editor/common/commonCodeEditor.ts | 1 + src/vs/editor/common/viewModel/viewModelImpl.ts | 2 -- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/vs/editor/common/commonCodeEditor.ts b/src/vs/editor/common/commonCodeEditor.ts index c5285a83724..c636c9f8f5f 100644 --- a/src/vs/editor/common/commonCodeEditor.ts +++ b/src/vs/editor/common/commonCodeEditor.ts @@ -858,6 +858,7 @@ export abstract class CommonCodeEditor extends Disposable implements editorCommo if (this.model) { this.domElement.setAttribute('data-mode-id', this.model.getLanguageIdentifier().language); this._configuration.setIsDominatedByLongLines(this.model.isDominatedByLongLines()); + this._configuration.setMaxLineNumber(this.model.getLineCount()); this.model.onBeforeAttached(); diff --git a/src/vs/editor/common/viewModel/viewModelImpl.ts b/src/vs/editor/common/viewModel/viewModelImpl.ts index a7a7297e881..c05068d4a83 100644 --- a/src/vs/editor/common/viewModel/viewModelImpl.ts +++ b/src/vs/editor/common/viewModel/viewModelImpl.ts @@ -120,8 +120,6 @@ export class ViewModel extends viewEvents.ViewEventEmitter implements IViewModel conf.wrappingInfo.wrappingIndent ); - this.configuration.setMaxLineNumber(this.model.getLineCount()); - this.coordinatesConverter = new CoordinatesConverter(this.lines); this.viewLayout = this._register(new ViewLayout(this.configuration, this.getLineCount())); -- GitLab From fd2dac6d5833ae422c2ede9c93a761bc4bcdb45a Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Fri, 16 Jun 2017 10:00:52 +0200 Subject: [PATCH 0920/1347] fixes #28506 --- extensions/git/src/commands.ts | 21 ++++++++++++++++----- 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/extensions/git/src/commands.ts b/extensions/git/src/commands.ts index 127544276ab..05a93640ca1 100644 --- a/extensions/git/src/commands.ts +++ b/extensions/git/src/commands.ts @@ -5,7 +5,7 @@ 'use strict'; -import { Uri, commands, scm, Disposable, window, workspace, QuickPickItem, OutputChannel, Range, WorkspaceEdit, Position, LineChange, SourceControlResourceState } from 'vscode'; +import { Uri, commands, scm, Disposable, window, workspace, QuickPickItem, OutputChannel, Range, WorkspaceEdit, Position, LineChange, SourceControlResourceState, TextDocumentShowOptions, ViewColumn } from 'vscode'; import { Ref, RefType, Git, GitErrorCodes } from './git'; import { Model, Resource, Status, CommitOptions, WorkingTreeGroup, IndexGroup, MergeGroup } from './model'; import { toGitUri, fromGitUri } from './uri'; @@ -145,11 +145,18 @@ export class CommandCenter { return; } + const viewColumn = window.activeTextEditor && window.activeTextEditor.viewColumn || ViewColumn.One; + if (!left) { - return await commands.executeCommand('vscode.open', right); + return await commands.executeCommand('vscode.open', right, viewColumn); } - return await commands.executeCommand('vscode.diff', left, right, title, { preview: true }); + const opts: TextDocumentShowOptions = { + preview: true, + viewColumn + }; + + return await commands.executeCommand('vscode.diff', left, right, title, opts); } private getLeftResource(resource: Resource): Uri | undefined { @@ -289,7 +296,9 @@ export class CommandCenter { return; } - return await commands.executeCommand('vscode.open', uri); + const viewColumn = window.activeTextEditor && window.activeTextEditor.viewColumn || ViewColumn.One; + + return await commands.executeCommand('vscode.open', uri, viewColumn); } @command('git.openChange') @@ -329,7 +338,9 @@ export class CommandCenter { return; } - return await commands.executeCommand('vscode.open', uriToOpen); + const viewColumn = window.activeTextEditor && window.activeTextEditor.viewColumn || ViewColumn.One; + + return await commands.executeCommand('vscode.open', uriToOpen, viewColumn); } @command('git.stage') -- GitLab From 36ae1a6f81d0fb8930cc3ca6a2a01e72ca4ac024 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Fri, 16 Jun 2017 10:08:02 +0200 Subject: [PATCH 0921/1347] update distro related to #20732 --- package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index 6536cecc87a..109118846bd 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "code-oss-dev", "version": "1.14.0", "electronVersion": "1.6.6", - "distro": "cb257c519d1ee526acfd00c0a7adc6b0fa4c18d2", + "distro": "652d5121d4004df51b085158050ea4a4af10693d", "author": { "name": "Microsoft Corporation" }, @@ -124,4 +124,4 @@ "windows-mutex": "^0.2.0", "fsevents": "0.3.8" } -} +} \ No newline at end of file -- GitLab From 7b3daf20432c1710f1c78ae34732d0e0dffbb762 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 16 Jun 2017 10:13:18 +0200 Subject: [PATCH 0922/1347] Small tweaks --- src/vs/editor/common/model/editableTextModel.ts | 7 +++++-- src/vs/editor/common/model/modelLine.ts | 7 ------- 2 files changed, 5 insertions(+), 9 deletions(-) diff --git a/src/vs/editor/common/model/editableTextModel.ts b/src/vs/editor/common/model/editableTextModel.ts index cbc963424da..34f1fdfe804 100644 --- a/src/vs/editor/common/model/editableTextModel.ts +++ b/src/vs/editor/common/model/editableTextModel.ts @@ -581,7 +581,7 @@ export class EditableTextModel extends TextModelWithDecorations implements edito const spliceStartLineNumber = startLineNumber + editingLinesCnt; const spliceStartColumn = this.getLineMaxColumn(spliceStartLineNumber); - let endLineRemains = this._lines[endLineNumber - 1].split(markersTracker, endColumn, false, tabSize); + const endLineRemains = this._lines[endLineNumber - 1].split(markersTracker, endColumn, false, tabSize); this._invalidateLine(spliceStartLineNumber - 1); const spliceCnt = endLineNumber - spliceStartLineNumber; @@ -590,7 +590,10 @@ export class EditableTextModel extends TextModelWithDecorations implements edito let markersOnDeletedLines: LineMarker[] = []; for (let j = 0; j < spliceCnt; j++) { const deleteLineIndex = spliceStartLineNumber + j; - markersOnDeletedLines = markersOnDeletedLines.concat(this._lines[deleteLineIndex].deleteLine()); + const deleteLineMarkers = this._lines[deleteLineIndex].getMarkers(); + if (deleteLineMarkers) { + markersOnDeletedLines = markersOnDeletedLines.concat(deleteLineMarkers); + } } this._lines.splice(spliceStartLineNumber, spliceCnt); diff --git a/src/vs/editor/common/model/modelLine.ts b/src/vs/editor/common/model/modelLine.ts index b2d1b3eeea0..4a1b012f60d 100644 --- a/src/vs/editor/common/model/modelLine.ts +++ b/src/vs/editor/common/model/modelLine.ts @@ -741,13 +741,6 @@ export class ModelLine { this._lineNumber = newLineNumber; } - public deleteLine(): LineMarker[] { - if (!this._markers) { - return []; - } - return this._markers; - } - private _indexOfMarkerId(markerId: string): number { let markers = this._markers; for (let i = 0, len = markers.length; i < len; i++) { -- GitLab From d3c2ba364264db396d4eed1e9b27b8f8c223ffce Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Fri, 16 Jun 2017 10:16:11 +0200 Subject: [PATCH 0923/1347] better fix for NPE in editor.hide() --- .../browser/parts/editor/editorGroupsControl.ts | 8 ++------ src/vs/workbench/browser/parts/editor/editorPart.ts | 12 +++++++----- 2 files changed, 9 insertions(+), 11 deletions(-) diff --git a/src/vs/workbench/browser/parts/editor/editorGroupsControl.ts b/src/vs/workbench/browser/parts/editor/editorGroupsControl.ts index 2f9f4224462..4bc4a3b143a 100644 --- a/src/vs/workbench/browser/parts/editor/editorGroupsControl.ts +++ b/src/vs/workbench/browser/parts/editor/editorGroupsControl.ts @@ -519,12 +519,8 @@ export class EditorGroupsControl extends Themable implements IEditorGroupsContro // Clear Position this.clearPosition(position); - // Take editor container offdom and hide. Check if the editor container - // exists in case someone manages to hide an editor before it was created - const editorContainer = editor.getContainer(); - if (editorContainer) { - editorContainer.offDOM().hide(); - } + // Take editor container offdom and hide + editor.getContainer().offDOM().hide(); // Adjust layout and rochade if instructed to do so if (layoutAndRochade) { diff --git a/src/vs/workbench/browser/parts/editor/editorPart.ts b/src/vs/workbench/browser/parts/editor/editorPart.ts index 7c4fdc9653b..2f7ff00c9be 100644 --- a/src/vs/workbench/browser/parts/editor/editorPart.ts +++ b/src/vs/workbench/browser/parts/editor/editorPart.ts @@ -361,7 +361,7 @@ export class EditorPart extends Part implements IEditorPart, IEditorGroupService // Hide active one first if (editorAtPosition) { - this.doHideEditor(position, false); + this.doHideEditor(editorAtPosition, position, false); } // Create Editor @@ -592,8 +592,11 @@ export class EditorPart extends Part implements IEditorPart, IEditorGroupService // Update stacks model this.modifyGroups(() => this.stacks.closeGroup(group)); - // Hide Editor - this.doHideEditor(position, true); + // Hide Editor if there is one + const editor = this.visibleEditors[position]; + if (editor) { + this.doHideEditor(editor, position, true); + } // Emit Change Event this._onEditorsChanged.fire(); @@ -613,8 +616,7 @@ export class EditorPart extends Part implements IEditorPart, IEditorGroupService } } - private doHideEditor(position: Position, layoutAndRochade: boolean): void { - const editor = this.visibleEditors[position]; + private doHideEditor(editor: BaseEditor, position: Position, layoutAndRochade: boolean): void { // Hide in side by side control const rochade = this.editorGroupsControl.hide(editor, position, layoutAndRochade); -- GitLab From f02a1aced95318f93513bd44d14a9623434b58a9 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Fri, 16 Jun 2017 10:16:40 +0200 Subject: [PATCH 0924/1347] #27823 Prepare views to suppor toggling --- src/vs/base/browser/ui/splitview/splitview.ts | 1 + .../parts/files/browser/explorerViewlet.ts | 36 ++- .../parts/files/browser/views/emptyView.ts | 3 +- .../files/browser/views/openEditorsView.ts | 3 +- src/vs/workbench/parts/files/common/files.ts | 3 + src/vs/workbench/parts/views/browser/views.ts | 218 +++++++++++------- 6 files changed, 152 insertions(+), 112 deletions(-) diff --git a/src/vs/base/browser/ui/splitview/splitview.ts b/src/vs/base/browser/ui/splitview/splitview.ts index 31710fb3489..6b2a1d5b20d 100644 --- a/src/vs/base/browser/ui/splitview/splitview.ts +++ b/src/vs/base/browser/ui/splitview/splitview.ts @@ -617,6 +617,7 @@ export class SplitView implements this.viewFocusNextListeners.splice(index, 1); this.views.splice(index, 1); + this.initialWeights.splice(index, 1); this.el.removeChild(this.viewElements[index]); this.viewElements.splice(index, 1); diff --git a/src/vs/workbench/parts/files/browser/explorerViewlet.ts b/src/vs/workbench/parts/files/browser/explorerViewlet.ts index eaea1615ad2..43a1d644a1d 100644 --- a/src/vs/workbench/parts/files/browser/explorerViewlet.ts +++ b/src/vs/workbench/parts/files/browser/explorerViewlet.ts @@ -10,9 +10,10 @@ import { IActionRunner } from 'vs/base/common/actions'; import { TPromise } from 'vs/base/common/winjs.base'; import * as DOM from 'vs/base/browser/dom'; import { Builder } from 'vs/base/browser/builder'; -import { VIEWLET_ID, ExplorerViewletVisibleContext, IFilesConfiguration } from 'vs/workbench/parts/files/common/files'; +import { VIEWLET_ID, ExplorerViewletVisibleContext, IFilesConfiguration, OpenEditorsVisibleContext, OpenEditorsVisibleCondition } from 'vs/workbench/parts/files/common/files'; import { ComposedViewsViewlet, IView, IViewletViewOptions } from 'vs/workbench/parts/views/browser/views'; import { IConfigurationService } from 'vs/platform/configuration/common/configuration'; +import { IConfigurationEditingService } from 'vs/workbench/services/configuration/common/configurationEditing'; import { ActionRunner, FileViewletState } from 'vs/workbench/parts/files/browser/views/explorerViewer'; import { ExplorerView, IExplorerViewOptions } from 'vs/workbench/parts/files/browser/views/explorerView'; import { EmptyView } from 'vs/workbench/parts/files/browser/views/emptyView'; @@ -37,6 +38,7 @@ export class ExplorerViewlet extends ComposedViewsViewlet { private viewletState: FileViewletState; private viewletVisibleContextKey: IContextKey; + private openEditorsVisibleContextKey: IContextKey; constructor( @ITelemetryService telemetryService: ITelemetryService, @@ -47,14 +49,17 @@ export class ExplorerViewlet extends ComposedViewsViewlet { @IConfigurationService private configurationService: IConfigurationService, @IInstantiationService protected instantiationService: IInstantiationService, @IContextKeyService contextKeyService: IContextKeyService, + @IConfigurationEditingService private configurationEditingService: IConfigurationEditingService, @IThemeService themeService: IThemeService ) { super(VIEWLET_ID, ViewLocation.Explorer, ExplorerViewlet.EXPLORER_VIEWS_STATE, telemetryService, storageService, instantiationService, themeService, contextService, contextKeyService); this.viewletState = new FileViewletState(); this.viewletVisibleContextKey = ExplorerViewletVisibleContext.bindTo(contextKeyService); + this.openEditorsVisibleContextKey = OpenEditorsVisibleContext.bindTo(contextKeyService); this.registerViews(); + this.onConfigurationUpdated(); this._register(this.configurationService.onDidUpdateConfiguration(e => this.onConfigurationUpdated())); } @@ -64,9 +69,9 @@ export class ExplorerViewlet extends ComposedViewsViewlet { private registerViews(): void { let viewDescriptors = []; - if (this.isOpenEditorsVisible()) { - viewDescriptors.push(this.createOpenEditorsViewDescriptor()); - } + + viewDescriptors.push(this.createOpenEditorsViewDescriptor()); + if (this.contextService.hasWorkspace()) { viewDescriptors.push(this.createExplorerViewDescriptor()); } else { @@ -79,17 +84,18 @@ export class ExplorerViewlet extends ComposedViewsViewlet { private createOpenEditorsViewDescriptor(): IViewDescriptor { return { id: OpenEditorsView.ID, - name: '', + name: OpenEditorsView.NAME, location: ViewLocation.Explorer, ctor: OpenEditorsView, - order: 0 + order: 0, + when: OpenEditorsVisibleCondition }; } private createEmptyViewDescriptor(): IViewDescriptor { return { id: EmptyView.ID, - name: '', + name: EmptyView.NAME, location: ViewLocation.Explorer, ctor: EmptyView, order: 1 @@ -107,21 +113,7 @@ export class ExplorerViewlet extends ComposedViewsViewlet { } private onConfigurationUpdated(): void { - let openEditorsViewDescriptor = ViewsRegistry.getViews(ViewLocation.Explorer).filter(viewDescriptor => viewDescriptor.id === OpenEditorsView.ID)[0]; - let isOpenEditorsVisible = this.isOpenEditorsVisible(); - if (isOpenEditorsVisible) { - if (!openEditorsViewDescriptor) { - ViewsRegistry.registerViews([this.createOpenEditorsViewDescriptor()]); - } - } else { - if (openEditorsViewDescriptor) { - ViewsRegistry.deregisterViews([OpenEditorsView.ID], ViewLocation.Explorer); - } - } - } - - private isOpenEditorsVisible(): boolean { - return !this.contextService.hasWorkspace() || (this.configurationService.getConfiguration()).explorer.openEditors.visible !== 0; + this.openEditorsVisibleContextKey.set(!this.contextService.hasWorkspace() || (this.configurationService.getConfiguration()).explorer.openEditors.visible !== 0); } protected createView(viewDescriptor: IViewDescriptor, options: IViewletViewOptions): IView { diff --git a/src/vs/workbench/parts/files/browser/views/emptyView.ts b/src/vs/workbench/parts/files/browser/views/emptyView.ts index 7cecda136e6..287fce66845 100644 --- a/src/vs/workbench/parts/files/browser/views/emptyView.ts +++ b/src/vs/workbench/parts/files/browser/views/emptyView.ts @@ -25,6 +25,7 @@ import { ViewSizing } from 'vs/base/browser/ui/splitview/splitview'; export class EmptyView extends CollapsibleView { public static ID: string = 'workbench.explorer.emptyView'; + public static NAME = nls.localize('noWorkspace', "No Folder Opened"); private openFolderButton: Button; @@ -40,7 +41,7 @@ export class EmptyView extends CollapsibleView { public renderHeader(container: HTMLElement): void { let titleDiv = $('div.title').appendTo(container); - $('span').text(nls.localize('noWorkspace', "No Folder Opened")).appendTo(titleDiv); + $('span').text(this.name).appendTo(titleDiv); } protected renderBody(container: HTMLElement): void { diff --git a/src/vs/workbench/parts/files/browser/views/openEditorsView.ts b/src/vs/workbench/parts/files/browser/views/openEditorsView.ts index 10c10b7736f..2b1f079b929 100644 --- a/src/vs/workbench/parts/files/browser/views/openEditorsView.ts +++ b/src/vs/workbench/parts/files/browser/views/openEditorsView.ts @@ -42,6 +42,7 @@ export class OpenEditorsView extends CollapsibleView { private static DEFAULT_VISIBLE_OPEN_EDITORS = 9; private static DEFAULT_DYNAMIC_HEIGHT = true; static ID = 'workbench.explorer.openEditorsView'; + static NAME = nls.localize({ key: 'openEditors', comment: ['Open is an adjective'] }, "Open Editors"); private visibleOpenEditors: number; private dynamicHeight: boolean; @@ -88,7 +89,7 @@ export class OpenEditorsView extends CollapsibleView { public renderHeader(container: HTMLElement): void { const titleDiv = dom.append(container, $('.title')); const titleSpan = dom.append(titleDiv, $('span')); - titleSpan.textContent = nls.localize({ key: 'openEditors', comment: ['Open is an adjective'] }, "Open Editors"); + titleSpan.textContent = this.name; this.dirtyCountElement = dom.append(titleDiv, $('.monaco-count-badge')); diff --git a/src/vs/workbench/parts/files/common/files.ts b/src/vs/workbench/parts/files/common/files.ts index dc8cd834b61..fcb7b317468 100644 --- a/src/vs/workbench/parts/files/common/files.ts +++ b/src/vs/workbench/parts/files/common/files.ts @@ -21,6 +21,7 @@ export const VIEWLET_ID = 'workbench.view.explorer'; */ const explorerViewletVisibleId = 'explorerViewletVisible'; const filesExplorerFocusId = 'filesExplorerFocus'; +const openEditorsVisibleId = 'openEditorsVisible'; const openEditorsFocusId = 'openEditorsFocus'; const explorerViewletFocusId = 'explorerViewletFocus'; const explorerResourceIsFolderId = 'explorerResourceIsFolder'; @@ -28,9 +29,11 @@ const explorerResourceIsFolderId = 'explorerResourceIsFolder'; export const ExplorerViewletVisibleContext = new RawContextKey(explorerViewletVisibleId, true); export const ExplorerFolderContext = new RawContextKey(explorerResourceIsFolderId, false); export const FilesExplorerFocussedContext = new RawContextKey(filesExplorerFocusId, false); +export const OpenEditorsVisibleContext = new RawContextKey(openEditorsVisibleId, false); export const OpenEditorsFocussedContext = new RawContextKey(openEditorsFocusId, false); export const ExplorerFocussedContext = new RawContextKey(explorerViewletFocusId, false); +export const OpenEditorsVisibleCondition = ContextKeyExpr.has(openEditorsVisibleId); export const FilesExplorerFocusCondition = ContextKeyExpr.and(ContextKeyExpr.has(explorerViewletVisibleId), ContextKeyExpr.has(filesExplorerFocusId)); export const ExplorerFocusCondition = ContextKeyExpr.and(ContextKeyExpr.has(explorerViewletVisibleId), ContextKeyExpr.has(explorerViewletFocusId)); diff --git a/src/vs/workbench/parts/views/browser/views.ts b/src/vs/workbench/parts/views/browser/views.ts index 382e14ed695..f263f1c7352 100644 --- a/src/vs/workbench/parts/views/browser/views.ts +++ b/src/vs/workbench/parts/views/browser/views.ts @@ -51,6 +51,8 @@ export interface IView extends IBaseView, IThemable { id: string; + name: string; + create(): TPromise; setVisible(visible: boolean): TPromise; @@ -89,8 +91,8 @@ export interface ICollapsibleViewOptions extends IViewOptions { export abstract class CollapsibleView extends AbstractCollapsibleView implements IView { readonly id: string; + readonly name: string; - protected viewName: string; protected treeContainer: HTMLElement; protected tree: ITree; protected toDispose: IDisposable[]; @@ -114,7 +116,7 @@ export abstract class CollapsibleView extends AbstractCollapsibleView implements }); this.id = options.id; - this.viewName = options.name; + this.name = options.name; this.actionRunner = options.actionRunner; this.toDispose = []; } @@ -135,7 +137,7 @@ export abstract class CollapsibleView extends AbstractCollapsibleView implements this.toolBar = new ToolBar($('div.actions').appendTo(container).getHTMLElement(), this.contextMenuService, { orientation: ActionsOrientation.HORIZONTAL, actionItemProvider: (action) => this.getActionItem(action), - ariaLabel: nls.localize('viewToolbarAriaLabel', "{0} actions", this.viewName), + ariaLabel: nls.localize('viewToolbarAriaLabel', "{0} actions", this.name), getKeyBinding: (action) => this.keybindingService.lookupKeybinding(action.id) }); this.toolBar.actionRunner = this.actionRunner; @@ -213,7 +215,10 @@ export abstract class CollapsibleView extends AbstractCollapsibleView implements public dispose(): void { this.isDisposed = true; this.treeContainer = null; - this.tree.dispose(); + + if (this.tree) { + this.tree.dispose(); + } if (this.dragHandler) { this.dragHandler.dispose(); @@ -268,11 +273,12 @@ export interface IViewletViewOptions extends IViewOptions { } -export interface IViewState { +interface IViewState { collapsed: boolean; size: number; + } export class ComposedViewsViewlet extends Viewlet { @@ -285,6 +291,7 @@ export class ComposedViewsViewlet extends Viewlet { private dimension: Dimension; private viewletSettings: any; + private readonly viewsContextKeys: Set = new Set(); private readonly viewsStates: Map; constructor( @@ -304,8 +311,8 @@ export class ComposedViewsViewlet extends Viewlet { this.viewletSettings = this.getMemento(storageService, Scope.WORKSPACE); this.viewsStates = this.loadViewsStates(); - this._register(ViewsRegistry.onViewsRegistered(viewDescriptors => this.addViews(viewDescriptors.filter(viewDescriptor => this.location === viewDescriptor.location)))); - this._register(ViewsRegistry.onViewsDeregistered(viewDescriptors => this.updateViews([], viewDescriptors.filter(viewDescriptor => this.location === viewDescriptor.location)))); + this._register(ViewsRegistry.onViewsRegistered(() => this.onViewDescriptorsChanged())); + this._register(ViewsRegistry.onViewsDeregistered(() => this.onViewDescriptorsChanged())); this._register(contextKeyService.onDidChangeContext(keys => this.onContextChanged(keys))); } @@ -316,7 +323,7 @@ export class ComposedViewsViewlet extends Viewlet { this.splitView = this._register(new SplitView(this.viewletContainer)); this._register(this.splitView.onFocus((view: IView) => this.lastFocusedView = view)); - return this.addViews(ViewsRegistry.getViews(this.location)) + return this.onViewDescriptorsChanged() .then(() => { this.lastFocusedView = this.views[0]; this.focus(); @@ -337,20 +344,101 @@ export class ComposedViewsViewlet extends Viewlet { return []; } - private addViews(viewDescriptors: IViewDescriptor[]): TPromise { - viewDescriptors = viewDescriptors.filter(viewDescriptor => this.contextKeyService.contextMatchesRules(viewDescriptor.when)); - return this.updateViews(viewDescriptors, []); + public setVisible(visible: boolean): TPromise { + return super.setVisible(visible) + .then(() => TPromise.join(this.views.map((view) => view.setVisible(visible)))) + .then(() => void 0); + } + + public focus(): void { + super.focus(); + if (this.lastFocusedView) { + this.lastFocusedView.focus(); + } + } + + public layout(dimension: Dimension): void { + this.dimension = dimension; + this.splitView.layout(dimension.height); + for (const view of this.views) { + let viewState = this.createViewState(view); + this.viewsStates.set(view.id, viewState); + } + } + + public getOptimalWidth(): number { + const additionalMargin = 16; + const optimalWidth = Math.max(...this.views.map(view => view.getOptimalWidth() || 0)); + return optimalWidth + additionalMargin; + } + + public shutdown(): void { + this.saveViewsStates(); + this.views.forEach((view) => view.shutdown()); + super.shutdown(); + } + + private onViewDescriptorsChanged(): TPromise { + this.viewsContextKeys.clear(); + for (const viewDescriptor of this.getViewDescriptorsFromRegistry()) { + if (viewDescriptor.when) { + for (const key of viewDescriptor.when.keys()) { + this.viewsContextKeys.add(key); + } + } + } + return this.updateViews(); + } + + private onContextChanged(keys: string[]): void { + let hasToUpdate: boolean = false; + for (const key of keys) { + if (this.viewsContextKeys.has(key)) { + hasToUpdate = true; + break; + } + } + + if (hasToUpdate) { + this.updateViews(); + } } - private updateViews(toAdd: IViewDescriptor[], toRemove: IViewDescriptor[]): TPromise { - if (!this.splitView || (!toAdd.length && !toRemove.length)) { + private updateViews(): TPromise { + + if (!this.splitView) { + return TPromise.as(null); + } + + const registeredViews = this.getViewDescriptorsFromRegistry(); + const [visible, toAdd, toRemove] = registeredViews.reduce<[IViewDescriptor[], IViewDescriptor[], IViewDescriptor[]]>((result, viewDescriptor) => { + const isCurrentlyVisible = !!this.getView(viewDescriptor.id); + const canBeVisible = this.canBeVisible(viewDescriptor); + + if (canBeVisible) { + result[0].push(viewDescriptor); + } + + if (!isCurrentlyVisible && canBeVisible) { + result[1].push(viewDescriptor); + } + + if (isCurrentlyVisible && !canBeVisible) { + result[2].push(viewDescriptor); + } + + return result; + + }, [[], [], []]); + + if (!toAdd.length && !toRemove.length) { return TPromise.as(null); } for (const view of this.views) { let viewState = this.viewsStates.get(view.id); if (!viewState || view.size !== viewState.size || !view.isExpanded() !== viewState.collapsed) { - viewState = this.getViewState(view); + viewState = this.createViewState(view); this.viewsStates.set(view.id, viewState); this.splitView.updateWeight(view, viewState.size); } @@ -359,29 +447,16 @@ export class ComposedViewsViewlet extends Viewlet { if (toRemove.length) { for (const viewDescriptor of toRemove) { let view = this.getView(viewDescriptor.id); - if (view) { - this.views.splice(this.views.indexOf(view), 1); - this.splitView.removeView(view); - } + this.views.splice(this.views.indexOf(view), 1); + this.splitView.removeView(view); } } const toCreate = []; - const viewsInOrder = ViewsRegistry.getViews(this.location) - .filter(viewDescriptor => this.contextKeyService.contextMatchesRules(viewDescriptor.when)) - .sort((a, b) => { - if (b.order === void 0 || b.order === null) { - return -1; - } - if (a.order === void 0 || a.order === null) { - return 1; - } - return a.order - b.order; - }); for (const viewDescriptor of toAdd) { let viewState = this.viewsStates.get(viewDescriptor.id); - let index = viewsInOrder.indexOf(viewDescriptor); + let index = visible.indexOf(viewDescriptor); const view = this.createView(viewDescriptor, { id: viewDescriptor.id, name: viewDescriptor.name, @@ -400,6 +475,10 @@ export class ComposedViewsViewlet extends Viewlet { .then(() => this.onViewsUpdated()); } + private canBeVisible(viewDescriptor: IViewDescriptor): boolean { + return this.contextKeyService.contextMatchesRules(viewDescriptor.when); + } + private onViewsUpdated(): TPromise { if (this.views.length === 1) { this.views[0].hideHeader(); @@ -422,72 +501,35 @@ export class ComposedViewsViewlet extends Viewlet { return this.setVisible(this.isVisible()); } - private onContextChanged(keys: string[]): void { - let viewsToCreate: IViewDescriptor[] = []; - let viewsToRemove: IViewDescriptor[] = []; - - for (const viewDescriptor of ViewsRegistry.getViews(this.location)) { - const view = this.getView(viewDescriptor.id); - if (this.contextKeyService.contextMatchesRules(viewDescriptor.when)) { - if (!view) { - viewsToCreate.push(viewDescriptor); + private getViewDescriptorsFromRegistry(): IViewDescriptor[] { + return ViewsRegistry.getViews(this.location) + .sort((a, b) => { + if (b.order === void 0 || b.order === null) { + return -1; } - } else { - if (view) { - viewsToRemove.push(viewDescriptor); + if (a.order === void 0 || a.order === null) { + return 1; } - } - } - - this.updateViews(viewsToCreate, viewsToRemove); - } - - public setVisible(visible: boolean): TPromise { - return super.setVisible(visible) - .then(() => TPromise.join(this.views.map((view) => view.setVisible(visible)))) - .then(() => void 0); - } - - public focus(): void { - super.focus(); - if (this.lastFocusedView) { - this.lastFocusedView.focus(); - } - } - - public layout(dimension: Dimension): void { - this.dimension = dimension; - this.splitView.layout(dimension.height); - for (const view of this.views) { - let viewState = this.getViewState(view); - this.viewsStates.set(view.id, viewState); - } - } - - public getOptimalWidth(): number { - const additionalMargin = 16; - const optimalWidth = Math.max(...this.views.map(view => view.getOptimalWidth() || 0)); - return optimalWidth + additionalMargin; + return a.order - b.order; + }); } - public shutdown(): void { - this.saveViewsStates(); - this.views.forEach((view) => view.shutdown()); - super.shutdown(); - } + private saveViewsStates(): void { + const viewsStates = {}; + this.viewsStates.forEach((viewState, id) => { + const view = this.getView(id); + viewState = view ? this.createViewState(view) : viewState; + viewsStates[id] = { size: viewState.size, collapsed: viewState.collapsed }; + }); - protected saveViewsStates(): void { - const viewletState = this.views.reduce((result, view) => { - result[view.id] = this.getViewState(view); - return result; - }, {}); - this.storageService.store(this.viewletStateStorageId, JSON.stringify(viewletState), this.contextService.hasWorkspace() ? StorageScope.WORKSPACE : StorageScope.GLOBAL); + this.storageService.store(this.viewletStateStorageId, JSON.stringify(viewsStates), this.contextService.hasWorkspace() ? StorageScope.WORKSPACE : StorageScope.GLOBAL); } - protected loadViewsStates(): Map { + private loadViewsStates(): Map { const viewsStates = JSON.parse(this.storageService.get(this.viewletStateStorageId, this.contextService.hasWorkspace() ? StorageScope.WORKSPACE : StorageScope.GLOBAL, '{}')); return Object.keys(viewsStates).reduce((result, id) => { - result.set(id, viewsStates[id]); + const viewState = viewsStates[id]; + result.set(id, viewState); return result; }, new Map()); } @@ -500,7 +542,7 @@ export class ComposedViewsViewlet extends Viewlet { return this.views.filter(view => view.id === id)[0]; } - private getViewState(view: IView): IViewState { + private createViewState(view: IView): IViewState { const collapsed = !view.isExpanded(); const size = collapsed && view instanceof CollapsibleView ? view.previousSize : view.size; return { -- GitLab From 735de9f1d76b0a2da7fb95495bbccbf540d73629 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Fri, 16 Jun 2017 11:02:36 +0200 Subject: [PATCH 0925/1347] remove tree.refreshAll --- src/vs/base/parts/tree/browser/tree.ts | 5 --- src/vs/base/parts/tree/browser/treeImpl.ts | 4 --- src/vs/base/parts/tree/browser/treeModel.ts | 17 --------- .../parts/tree/test/browser/treeModel.test.ts | 36 ------------------- 4 files changed, 62 deletions(-) diff --git a/src/vs/base/parts/tree/browser/tree.ts b/src/vs/base/parts/tree/browser/tree.ts index 2b03b5f138b..30435a9ddb0 100644 --- a/src/vs/base/parts/tree/browser/tree.ts +++ b/src/vs/base/parts/tree/browser/tree.ts @@ -76,11 +76,6 @@ export interface ITree extends Events.IEventEmitter { */ refresh(element?: any, recursive?: boolean): WinJS.Promise; - /** - * Refreshes all given elements. - */ - refreshAll(elements: any[], recursive?: boolean): WinJS.Promise; - /** * Expands an element. * The returned promise returns a boolean for whether the element was expanded or not. diff --git a/src/vs/base/parts/tree/browser/treeImpl.ts b/src/vs/base/parts/tree/browser/treeImpl.ts index ea81d203047..8bd11197560 100644 --- a/src/vs/base/parts/tree/browser/treeImpl.ts +++ b/src/vs/base/parts/tree/browser/treeImpl.ts @@ -170,10 +170,6 @@ export class Tree extends Events.EventEmitter implements _.ITree { return this.model.refresh(element, recursive); } - public refreshAll(elements: any[], recursive = true): WinJS.Promise { - return this.model.refreshAll(elements, recursive); - } - public expand(element: any): WinJS.Promise { return this.model.expand(element); } diff --git a/src/vs/base/parts/tree/browser/treeModel.ts b/src/vs/base/parts/tree/browser/treeModel.ts index a3fbdfa04d5..9ca9f059c72 100644 --- a/src/vs/base/parts/tree/browser/treeModel.ts +++ b/src/vs/base/parts/tree/browser/treeModel.ts @@ -839,23 +839,6 @@ export class TreeModel extends Events.EventEmitter { }); } - public refreshAll(elements: any[], recursive: boolean = true): WinJS.Promise { - try { - this.beginDeferredEmit(); - return this._refreshAll(elements, recursive); - } finally { - this.endDeferredEmit(); - } - } - - private _refreshAll(elements: any[], recursive: boolean): WinJS.Promise { - var promises = []; - for (var i = 0, len = elements.length; i < len; i++) { - promises.push(this.refresh(elements[i], recursive)); - } - return WinJS.Promise.join(promises); - } - public expand(element: any): WinJS.Promise { var item = this.getItem(element); diff --git a/src/vs/base/parts/tree/test/browser/treeModel.test.ts b/src/vs/base/parts/tree/test/browser/treeModel.test.ts index efb3c25a5b8..c9c890127e2 100644 --- a/src/vs/base/parts/tree/test/browser/treeModel.test.ts +++ b/src/vs/base/parts/tree/test/browser/treeModel.test.ts @@ -293,42 +293,6 @@ suite('TreeModel', () => { }); }); - test('refreshAll(...) refreshes the elements and descendants', (done) => { - model.setInput(SAMPLE.AB).then(() => { - model.expand(SAMPLE.AB.children[0]); - model.expand(SAMPLE.AB.children[2]); - - counter.listen(model, 'refreshing'); // 3 - counter.listen(model, 'refreshed'); // 3 - counter.listen(model, 'item:refresh'); // 7 - counter.listen(model, 'item:childrenRefreshing'); // 2 - counter.listen(model, 'item:childrenRefreshed'); // 2 - - return model.refreshAll([SAMPLE.AB.children[0], SAMPLE.AB.children[1], SAMPLE.AB.children[2]]); - }).done(() => { - assert.equal(counter.count, 17); - done(); - }); - }); - - test('refreshAll(..., false) refreshes the elements', (done) => { - model.setInput(SAMPLE.AB).then(() => { - model.expand(SAMPLE.AB.children[0]); - model.expand(SAMPLE.AB.children[2]); - - counter.listen(model, 'refreshing'); // 3 - counter.listen(model, 'refreshed'); // 3 - counter.listen(model, 'item:refresh'); // 3 - counter.listen(model, 'item:childrenRefreshing'); // 2 - counter.listen(model, 'item:childrenRefreshed'); // 2 - - return model.refreshAll([SAMPLE.AB.children[0], SAMPLE.AB.children[1], SAMPLE.AB.children[2]], false); - }).done(() => { - assert.equal(counter.count, 13); - done(); - }); - }); - test('depths', (done) => { model.setInput(SAMPLE.AB).then(() => { model.expandAll(['a', 'c']); -- GitLab From 1cc1b75d78c7b2cf2e5922ba7afcf072826d232a Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Fri, 16 Jun 2017 11:04:16 +0200 Subject: [PATCH 0926/1347] tfs: fix concurrent windows builds --- build/tfs/win32/lib.ps1 | 5 ++++- scripts/env.ps1 | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/build/tfs/win32/lib.ps1 b/build/tfs/win32/lib.ps1 index 610b4d7fcdf..ed8407b7013 100644 --- a/build/tfs/win32/lib.ps1 +++ b/build/tfs/win32/lib.ps1 @@ -1,8 +1,11 @@ # stop when there's an error $ErrorActionPreference = 'Stop' -# set agent specific npm cache if (Test-Path env:AGENT_WORKFOLDER) { + # will be used by node-gyp + $env:HOME = "${env:AGENT_WORKFOLDER}\home" + + # will be used by npm $env:npm_config_cache = "${env:AGENT_WORKFOLDER}\npm-cache" } diff --git a/scripts/env.ps1 b/scripts/env.ps1 index 3d34630f391..f05a5680644 100644 --- a/scripts/env.ps1 +++ b/scripts/env.ps1 @@ -1,5 +1,5 @@ $env:npm_config_disturl="https://atom.io/download/electron" $env:npm_config_target=(node -p "require('./package.json').electronVersion") $env:npm_config_runtime="electron" -$env:npm_config_cache="$HOME/.npm-electron" +$env:npm_config_cache="${env:USERPROFILE}/.npm-electron" New-Item -Path "$env:npm_config_cache" -Type directory -Force | out-null \ No newline at end of file -- GitLab From 7e70dc1a47c0a637fa81c46496533f860555ac49 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Fri, 16 Jun 2017 11:13:11 +0200 Subject: [PATCH 0927/1347] tfs: fix windows build --- build/tfs/win32/1_build.ps1 | 3 +-- build/tfs/win32/lib.ps1 | 4 ++++ 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/build/tfs/win32/1_build.ps1 b/build/tfs/win32/1_build.ps1 index 0f473ddeff5..34b44826fc0 100644 --- a/build/tfs/win32/1_build.ps1 +++ b/build/tfs/win32/1_build.ps1 @@ -9,8 +9,7 @@ Param( # Create a _netrc file to download distro dependencies # In order to get _netrc to work, we need a HOME variable setup -$env:HOME=$env:USERPROFILE -"machine monacotools.visualstudio.com password ${vsoPAT}" | Out-File "$env:USERPROFILE\_netrc" -Encoding ASCII +"machine monacotools.visualstudio.com password ${vsoPAT}" | Out-File "$env:HOME\_netrc" -Encoding ASCII # Set the right architecture $env:npm_config_arch="$arch" diff --git a/build/tfs/win32/lib.ps1 b/build/tfs/win32/lib.ps1 index ed8407b7013..c2e9c1d83ef 100644 --- a/build/tfs/win32/lib.ps1 +++ b/build/tfs/win32/lib.ps1 @@ -1,12 +1,16 @@ # stop when there's an error $ErrorActionPreference = 'Stop' +$env:HOME=$env:USERPROFILE + if (Test-Path env:AGENT_WORKFOLDER) { # will be used by node-gyp $env:HOME = "${env:AGENT_WORKFOLDER}\home" + New-Item -Path "$env:HOME" -Type directory -Force | out-null # will be used by npm $env:npm_config_cache = "${env:AGENT_WORKFOLDER}\npm-cache" + New-Item -Path "$env:npm_config_cache" -Type directory -Force | out-null } # throw when a process exits with something other than 0 -- GitLab From 3462fd14bea6c93d3829a38e9c38d31b164a8e82 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Fri, 16 Jun 2017 11:22:32 +0200 Subject: [PATCH 0928/1347] tfs: windows build --- build/tfs/win32/lib.ps1 | 11 ++++------- scripts/env.ps1 | 4 +--- 2 files changed, 5 insertions(+), 10 deletions(-) diff --git a/build/tfs/win32/lib.ps1 b/build/tfs/win32/lib.ps1 index c2e9c1d83ef..9dfaeabf7a6 100644 --- a/build/tfs/win32/lib.ps1 +++ b/build/tfs/win32/lib.ps1 @@ -3,13 +3,10 @@ $ErrorActionPreference = 'Stop' $env:HOME=$env:USERPROFILE -if (Test-Path env:AGENT_WORKFOLDER) { - # will be used by node-gyp - $env:HOME = "${env:AGENT_WORKFOLDER}\home" - New-Item -Path "$env:HOME" -Type directory -Force | out-null - - # will be used by npm - $env:npm_config_cache = "${env:AGENT_WORKFOLDER}\npm-cache" +if (Test-Path env:AGENT_HOMEDIRECTORY) { + $env:USERPROFILE="${env:AGENT_HOMEDIRECTORY}" + $env:HOME="${env:AGENT_HOMEDIRECTORY}" + $env:npm_config_cache="${env:AGENT_HOMEDIRECTORY}/.npm-electron" New-Item -Path "$env:npm_config_cache" -Type directory -Force | out-null } diff --git a/scripts/env.ps1 b/scripts/env.ps1 index f05a5680644..afd26f17baa 100644 --- a/scripts/env.ps1 +++ b/scripts/env.ps1 @@ -1,5 +1,3 @@ $env:npm_config_disturl="https://atom.io/download/electron" $env:npm_config_target=(node -p "require('./package.json').electronVersion") -$env:npm_config_runtime="electron" -$env:npm_config_cache="${env:USERPROFILE}/.npm-electron" -New-Item -Path "$env:npm_config_cache" -Type directory -Force | out-null \ No newline at end of file +$env:npm_config_runtime="electron" \ No newline at end of file -- GitLab From 5ed899192b6d5735370ef95105a98c20da38e423 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Fri, 16 Jun 2017 11:25:16 +0200 Subject: [PATCH 0929/1347] tfs: windows build --- build/tfs/win32/lib.ps1 | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/build/tfs/win32/lib.ps1 b/build/tfs/win32/lib.ps1 index 9dfaeabf7a6..ed7b80fc7d7 100644 --- a/build/tfs/win32/lib.ps1 +++ b/build/tfs/win32/lib.ps1 @@ -3,10 +3,11 @@ $ErrorActionPreference = 'Stop' $env:HOME=$env:USERPROFILE -if (Test-Path env:AGENT_HOMEDIRECTORY) { - $env:USERPROFILE="${env:AGENT_HOMEDIRECTORY}" - $env:HOME="${env:AGENT_HOMEDIRECTORY}" - $env:npm_config_cache="${env:AGENT_HOMEDIRECTORY}/.npm-electron" +if (Test-Path env:AGENT_WORKFOLDER) { + $env:USERPROFILE="${env:AGENT_WORKFOLDER}/home" + $env:HOME="${env:USERPROFILE}" + $env:npm_config_cache="${env:USERPROFILE}/.npm-electron" + New-Item -Path "$env:USERPROFILE" -Type directory -Force | out-null New-Item -Path "$env:npm_config_cache" -Type directory -Force | out-null } -- GitLab From 01c71c1a7eb8a3c76e45b6fe317cc0f9045b48ac Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Fri, 16 Jun 2017 11:26:55 +0200 Subject: [PATCH 0930/1347] tfs: windows build --- build/tfs/win32/lib.ps1 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/build/tfs/win32/lib.ps1 b/build/tfs/win32/lib.ps1 index ed7b80fc7d7..c35f6935081 100644 --- a/build/tfs/win32/lib.ps1 +++ b/build/tfs/win32/lib.ps1 @@ -4,9 +4,9 @@ $ErrorActionPreference = 'Stop' $env:HOME=$env:USERPROFILE if (Test-Path env:AGENT_WORKFOLDER) { - $env:USERPROFILE="${env:AGENT_WORKFOLDER}/home" + $env:USERPROFILE="${env:AGENT_WORKFOLDER}\home" $env:HOME="${env:USERPROFILE}" - $env:npm_config_cache="${env:USERPROFILE}/.npm-electron" + $env:npm_config_cache="${env:USERPROFILE}\.npm-electron" New-Item -Path "$env:USERPROFILE" -Type directory -Force | out-null New-Item -Path "$env:npm_config_cache" -Type directory -Force | out-null } -- GitLab From 88fd820176280fdc3fd7015dc17cf5e71282c728 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Fri, 16 Jun 2017 11:27:41 +0200 Subject: [PATCH 0931/1347] tfs: windows build --- build/tfs/win32/lib.ps1 | 2 -- 1 file changed, 2 deletions(-) diff --git a/build/tfs/win32/lib.ps1 b/build/tfs/win32/lib.ps1 index c35f6935081..7bac6c3eccd 100644 --- a/build/tfs/win32/lib.ps1 +++ b/build/tfs/win32/lib.ps1 @@ -6,9 +6,7 @@ $env:HOME=$env:USERPROFILE if (Test-Path env:AGENT_WORKFOLDER) { $env:USERPROFILE="${env:AGENT_WORKFOLDER}\home" $env:HOME="${env:USERPROFILE}" - $env:npm_config_cache="${env:USERPROFILE}\.npm-electron" New-Item -Path "$env:USERPROFILE" -Type directory -Force | out-null - New-Item -Path "$env:npm_config_cache" -Type directory -Force | out-null } # throw when a process exits with something other than 0 -- GitLab From e239a4512ed7fa27f9a8f1ccea33f8544dd5c381 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Fri, 16 Jun 2017 11:29:34 +0200 Subject: [PATCH 0932/1347] tfs: windows build --- build/tfs/win32/lib.ps1 | 2 ++ 1 file changed, 2 insertions(+) diff --git a/build/tfs/win32/lib.ps1 b/build/tfs/win32/lib.ps1 index 7bac6c3eccd..3f5b13a02e1 100644 --- a/build/tfs/win32/lib.ps1 +++ b/build/tfs/win32/lib.ps1 @@ -6,7 +6,9 @@ $env:HOME=$env:USERPROFILE if (Test-Path env:AGENT_WORKFOLDER) { $env:USERPROFILE="${env:AGENT_WORKFOLDER}\home" $env:HOME="${env:USERPROFILE}" + $env:npm_config_cache="${env:USERPROFILE}\npm-cache" New-Item -Path "$env:USERPROFILE" -Type directory -Force | out-null + New-Item -Path "$env:npm_config_cache" -Type directory -Force | out-null } # throw when a process exits with something other than 0 -- GitLab From 6d96b62559b055ffe60738171e52cf7a7dc97125 Mon Sep 17 00:00:00 2001 From: isidor Date: Fri, 16 Jun 2017 11:33:54 +0200 Subject: [PATCH 0933/1347] refresh all parants properly --- .../parts/files/browser/views/explorerView.ts | 12 ++++++------ .../parts/files/browser/views/explorerViewer.ts | 3 ++- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index a0003873dda..14c57378a42 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -438,7 +438,7 @@ export class ExplorerView extends CollapsibleView { parents[0].addChild(childElement); // Refresh the Parent (View) - this.explorerViewer.refresh(parents).then(() => { + TPromise.join(parents.map(p => this.explorerViewer.refresh(p))).then(() => { return this.reveal(childElement, 0.5).then(() => { // Focus new element @@ -474,7 +474,7 @@ export class ExplorerView extends CollapsibleView { // Update Parent (View) parents = this.model.findAll(modelElement.parent.resource); if (parents.length) { - this.explorerViewer.refresh(parents).done(() => { + TPromise.join(parents.map(p => this.explorerViewer.refresh(p))).done(() => { // Select in Viewer if set if (restoreFocus) { @@ -497,11 +497,11 @@ export class ExplorerView extends CollapsibleView { modelElement.move(newParents[0], (callback: () => void) => { // Update old parent - this.explorerViewer.refresh(oldParents, true).done(callback, errors.onUnexpectedError); + TPromise.join(oldParents.map(p => this.explorerViewer.refresh(p))).done(callback, errors.onUnexpectedError); }, () => { // Update new parent - this.explorerViewer.refresh(newParents, true).done(() => this.explorerViewer.expand(newParents[0]), errors.onUnexpectedError); + TPromise.join(newParents.map(p => this.explorerViewer.refresh(p, true))).done(() => this.explorerViewer.expand(newParents[0]), errors.onUnexpectedError); }); } } @@ -518,7 +518,7 @@ export class ExplorerView extends CollapsibleView { // Refresh Parent (View) const restoreFocus = this.explorerViewer.isDOMFocused(); - this.explorerViewer.refresh(parents).done(() => { + TPromise.join(parents.map(p => this.explorerViewer.refresh(p))).done(() => { // Ensure viewer has keyboard focus if event originates from viewer if (restoreFocus) { @@ -806,7 +806,7 @@ export class ExplorerView extends CollapsibleView { // Stat needs to be resolved first and then revealed const options: IResolveFileOptions = { resolveTo: [resource] }; - const rootUri = this.contextService.getRoot(resource); + const rootUri = this.contextService.getRoot(resource) || this.model.roots[0].resource; return this.fileService.resolveFile(rootUri, options).then(stat => { // Convert to model diff --git a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts index 39890cff44e..f81588d6649 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts @@ -75,7 +75,8 @@ export class FileDataSource implements IDataSource { return 'model'; } - return `${this.contextService.getRoot(stat.resource).toString()}:${stat.getId()}`; + const root = this.contextService.getRoot(stat.resource); + return `${root ? root.toString() : ''}:${stat.getId()}`; } public hasChildren(tree: ITree, stat: FileStat | Model): boolean { -- GitLab From 66c4bd5e9640d66216d40643a91038002b565623 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Fri, 16 Jun 2017 11:45:54 +0200 Subject: [PATCH 0934/1347] Revert "suggest: improve element aria label" This reverts commit 42d3d54267972869376b4cc8aa84bbb4fe602a14. --- src/vs/editor/contrib/suggest/browser/suggestWidget.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts index a1f36edca85..5ab85e8bf03 100644 --- a/src/vs/editor/contrib/suggest/browser/suggestWidget.ts +++ b/src/vs/editor/contrib/suggest/browser/suggestWidget.ts @@ -134,7 +134,7 @@ class Renderer implements IRenderer { const suggestion = (element).suggestion; if (canExpandCompletionItem(element)) { - data.root.setAttribute('aria-label', nls.localize('suggestionWithDetailsAriaLabel', "{0}, suggestion, has details, press {1} to read more", suggestion.label, this.triggerKeybindingLabel)); + data.root.setAttribute('aria-label', nls.localize('suggestionWithDetailsAriaLabel', "{0}, suggestion, has details", suggestion.label)); } else { data.root.setAttribute('aria-label', nls.localize('suggestionAriaLabel', "{0}, suggestion", suggestion.label)); } -- GitLab From e7fc27d746ffc5ad490814d24d49c699213024a8 Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Fri, 16 Jun 2017 11:48:53 +0200 Subject: [PATCH 0935/1347] :lipstick: --- .../services/textfile/common/textFileService.ts | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/src/vs/workbench/services/textfile/common/textFileService.ts b/src/vs/workbench/services/textfile/common/textFileService.ts index 515c976f07e..07ffc8ceeb7 100644 --- a/src/vs/workbench/services/textfile/common/textFileService.ts +++ b/src/vs/workbench/services/textfile/common/textFileService.ts @@ -342,14 +342,11 @@ export abstract class TextFileService implements ITextFileService { } // Hot exit - const hotExitMode = configuration && configuration.files ? configuration.files.hotExit : HotExitConfiguration.OFF; - // Handle the legacy case where hot exit was a boolean - if (hotExitMode === false) { - this.configuredHotExit = HotExitConfiguration.OFF; - } else if (hotExitMode === true) { - this.configuredHotExit = HotExitConfiguration.ON_EXIT; - } else { + const hotExitMode = configuration && configuration.files && configuration.files.hotExit; + if (hotExitMode === HotExitConfiguration.OFF || hotExitMode === HotExitConfiguration.ON_EXIT_AND_WINDOW_CLOSE) { this.configuredHotExit = hotExitMode; + } else { + this.configuredHotExit = HotExitConfiguration.ON_EXIT; } } @@ -469,8 +466,8 @@ export abstract class TextFileService implements ITextFileService { }); } - private doSaveAllFiles(arg1?: any /* URI[] */, reason?: SaveReason): TPromise { - const dirtyFileModels = this.getDirtyFileModels(Array.isArray(arg1) ? arg1 : void 0 /* Save All */) + private doSaveAllFiles(resources?: URI[], reason?: SaveReason): TPromise { + const dirtyFileModels = this.getDirtyFileModels(Array.isArray(resources) ? resources : void 0 /* Save All */) .filter(model => { if (model.hasState(ModelState.CONFLICT) && (reason === SaveReason.AUTO || reason === SaveReason.FOCUS_CHANGE || reason === SaveReason.WINDOW_CHANGE)) { return false; // if model is in save conflict, do not save unless save reason is explicit or not provided at all -- GitLab From d53d2d7ef859c5a9c348e761ae1eb1236afc031a Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Fri, 16 Jun 2017 12:16:07 +0200 Subject: [PATCH 0936/1347] fixes #28393 --- .../parameterHints/browser/parameterHintsWidget.ts | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.ts b/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.ts index 7c4e88e035e..d5ee521195b 100644 --- a/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.ts +++ b/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.ts @@ -81,7 +81,7 @@ export class ParameterHintsModel extends Disposable { } trigger(delay = ParameterHintsModel.DELAY): void { - if (!this.enabled || !SignatureHelpProviderRegistry.has(this.editor.getModel())) { + if (!SignatureHelpProviderRegistry.has(this.editor.getModel())) { return; } @@ -132,8 +132,11 @@ export class ParameterHintsModel extends Disposable { } this.triggerCharactersListeners.push(this.editor.onDidType((text: string) => { - let lastCharCode = text.charCodeAt(text.length - 1); - if (triggerChars.has(lastCharCode)) { + if (!this.enabled) { + return; + } + + if (triggerChars.has(text.charCodeAt(text.length - 1))) { this.trigger(); } })); -- GitLab From 38f0cf830e919d93f489d259945f80525b9e93a0 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Fri, 16 Jun 2017 10:39:41 +0200 Subject: [PATCH 0937/1347] #28538 Rename old workspaces to legacy --- src/vs/editor/browser/standalone/simpleServices.ts | 2 +- .../common/extensionEnablementService.ts | 4 ++-- src/vs/platform/storage/test/storageService.test.ts | 4 ++-- src/vs/platform/workspace/common/workspace.ts | 6 +++--- .../platform/workspace/test/common/testWorkspace.ts | 4 ++-- src/vs/workbench/electron-browser/main.ts | 2 +- .../terminal/electron-browser/terminalInstance.ts | 6 +++--- .../test/electron-browser/terminalInstance.test.ts | 6 +++--- .../electron-browser/terminalLinkHandler.test.ts | 4 ++-- .../services/configuration/node/configuration.ts | 2 +- .../configuration/test/node/configuration.test.ts | 12 ++++++------ .../test/node/configurationEditingService.test.ts | 4 ++-- .../quickopen.perf.integrationTest.ts | 4 ++-- .../textsearch.perf.integrationTest.ts | 4 ++-- src/vs/workbench/test/workbenchTestServices.ts | 6 +++--- 15 files changed, 35 insertions(+), 35 deletions(-) diff --git a/src/vs/editor/browser/standalone/simpleServices.ts b/src/vs/editor/browser/standalone/simpleServices.ts index 7365d6ccdb5..4fad640c21e 100644 --- a/src/vs/editor/browser/standalone/simpleServices.ts +++ b/src/vs/editor/browser/standalone/simpleServices.ts @@ -17,7 +17,7 @@ import { KeybindingResolver } from 'vs/platform/keybinding/common/keybindingReso import { IKeybindingEvent, KeybindingSource, IKeyboardEvent } from 'vs/platform/keybinding/common/keybinding'; import { ContextKeyExpr, IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; import { IConfirmation, IMessageService } from 'vs/platform/message/common/message'; -import { IWorkspaceContextService, IWorkspace as ILegacyWorkspace, IWorkspace2 } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService, ILegacyWorkspace, IWorkspace2 } from 'vs/platform/workspace/common/workspace'; import * as editorCommon from 'vs/editor/common/editorCommon'; import { ICodeEditor, IDiffEditor } from 'vs/editor/browser/editorBrowser'; import { Selection } from 'vs/editor/common/core/selection'; diff --git a/src/vs/platform/extensionManagement/common/extensionEnablementService.ts b/src/vs/platform/extensionManagement/common/extensionEnablementService.ts index 689c192d03a..786e1be59b7 100644 --- a/src/vs/platform/extensionManagement/common/extensionEnablementService.ts +++ b/src/vs/platform/extensionManagement/common/extensionEnablementService.ts @@ -10,7 +10,7 @@ import Event, { Emitter } from 'vs/base/common/event'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { IExtensionManagementService, DidUninstallExtensionEvent, IExtensionEnablementService } from 'vs/platform/extensionManagement/common/extensionManagement'; import { adoptToGalleryExtensionId, getIdAndVersionFromLocalExtensionId } from 'vs/platform/extensionManagement/common/extensionManagementUtil'; -import { IWorkspaceContextService, IWorkspace } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService, ILegacyWorkspace } from 'vs/platform/workspace/common/workspace'; import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; @@ -34,7 +34,7 @@ export class ExtensionEnablementService implements IExtensionEnablementService { extensionManagementService.onDidUninstallExtension(this.onDidUninstallExtension, this, this.disposables); } - private get workspace(): IWorkspace { + private get workspace(): ILegacyWorkspace { return this.contextService.getWorkspace(); } diff --git a/src/vs/platform/storage/test/storageService.test.ts b/src/vs/platform/storage/test/storageService.test.ts index 2893d767a27..a32ef2f398f 100644 --- a/src/vs/platform/storage/test/storageService.test.ts +++ b/src/vs/platform/storage/test/storageService.test.ts @@ -8,7 +8,7 @@ import * as assert from 'assert'; import { TestInstantiationService } from 'vs/platform/instantiation/test/common/instantiationServiceMock'; import { StorageScope } from 'vs/platform/storage/common/storage'; -import { IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService, LegacyWorkspace } from 'vs/platform/workspace/common/workspace'; import { StorageService, InMemoryLocalStorage } from 'vs/platform/storage/common/storageService'; import { TestContextService } from 'vs/workbench/test/workbenchTestServices'; import { TestWorkspace } from 'vs/platform/workspace/test/common/testWorkspace'; @@ -95,7 +95,7 @@ suite('Workbench StorageSevice', () => { assert.strictEqual(s.get('wkey1', StorageScope.WORKSPACE), 'foo'); assert.strictEqual(s.get('wkey2', StorageScope.WORKSPACE), 'foo2'); - ws = new Workspace(TestWorkspace.resource, Date.now()); + ws = new LegacyWorkspace(TestWorkspace.resource, Date.now()); ws.uid = new Date().getTime() + 100; s = new StorageService(storageImpl, null, ws); diff --git a/src/vs/platform/workspace/common/workspace.ts b/src/vs/platform/workspace/common/workspace.ts index d6bfd45a243..25ac39d2716 100644 --- a/src/vs/platform/workspace/common/workspace.ts +++ b/src/vs/platform/workspace/common/workspace.ts @@ -25,7 +25,7 @@ export interface IWorkspaceContextService { * Provides access to the workspace object the platform is running with. This may be null if the workbench was opened * without workspace (empty); */ - getWorkspace(): IWorkspace; + getWorkspace(): ILegacyWorkspace; /** * Provides access to the workspace object the platform is running with. This may be null if the workbench was opened @@ -62,7 +62,7 @@ export interface IWorkspaceContextService { toResource: (workspaceRelativePath: string) => URI; } -export interface IWorkspace { +export interface ILegacyWorkspace { /** * the full uri of the workspace. this is a file:// URL to the location @@ -99,7 +99,7 @@ export interface IWorkspace2 { readonly roots: URI[]; } -export class Workspace implements IWorkspace { +export class LegacyWorkspace implements ILegacyWorkspace { private _name: string; constructor(private _resource: URI, private _ctime?: number) { diff --git a/src/vs/platform/workspace/test/common/testWorkspace.ts b/src/vs/platform/workspace/test/common/testWorkspace.ts index 8933555a376..ed097d9c90b 100644 --- a/src/vs/platform/workspace/test/common/testWorkspace.ts +++ b/src/vs/platform/workspace/test/common/testWorkspace.ts @@ -3,10 +3,10 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import { Workspace } from 'vs/platform/workspace/common/workspace'; +import { LegacyWorkspace } from 'vs/platform/workspace/common/workspace'; import URI from 'vs/base/common/uri'; -export const TestWorkspace = new Workspace( +export const TestWorkspace = new LegacyWorkspace( URI.file('C:\\testWorkspace'), Date.now() ); diff --git a/src/vs/workbench/electron-browser/main.ts b/src/vs/workbench/electron-browser/main.ts index c447bf78692..450e01cd4e7 100644 --- a/src/vs/workbench/electron-browser/main.ts +++ b/src/vs/workbench/electron-browser/main.ts @@ -18,7 +18,7 @@ import paths = require('vs/base/common/paths'); import uri from 'vs/base/common/uri'; import strings = require('vs/base/common/strings'); import { IResourceInput } from 'vs/platform/editor/common/editor'; -import { Workspace as LegacyWorkspace } from "vs/platform/workspace/common/workspace"; +import { LegacyWorkspace } from "vs/platform/workspace/common/workspace"; import { WorkspaceConfigurationService } from 'vs/workbench/services/configuration/node/configuration'; import { realpath, stat } from 'vs/base/node/pfs'; import { EnvironmentService } from 'vs/platform/environment/node/environmentService'; diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts index 54989b2c496..8d15110ad5e 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.ts @@ -21,7 +21,7 @@ import { IPanelService } from 'vs/workbench/services/panel/common/panelService'; import { IStringDictionary } from 'vs/base/common/collections'; import { ITerminalInstance, KEYBINDING_CONTEXT_TERMINAL_TEXT_SELECTED, TERMINAL_PANEL_ID, IShellLaunchConfig } from 'vs/workbench/parts/terminal/common/terminal'; import { ITerminalProcessFactory } from 'vs/workbench/parts/terminal/electron-browser/terminal'; -import { IWorkspace, IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { ILegacyWorkspace, IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { StandardKeyboardEvent } from 'vs/base/browser/keyboardEvent'; @@ -464,7 +464,7 @@ export class TerminalInstance implements ITerminalInstance { return typeof data === 'string' ? data.replace(TerminalInstance.WINDOWS_EOL_REGEX, '\r') : data; } - protected _getCwd(shell: IShellLaunchConfig, workspace: IWorkspace): string { + protected _getCwd(shell: IShellLaunchConfig, workspace: ILegacyWorkspace): string { if (shell.cwd) { return shell.cwd; } @@ -492,7 +492,7 @@ export class TerminalInstance implements ITerminalInstance { return TerminalInstance._sanitizeCwd(cwd); } - protected _createProcess(workspace: IWorkspace, shell: IShellLaunchConfig): void { + protected _createProcess(workspace: ILegacyWorkspace, shell: IShellLaunchConfig): void { const locale = this._configHelper.config.setLocaleVariables ? platform.locale : undefined; if (!shell.executable) { this._configHelper.mergeDefaultShellPathAndArgs(shell); diff --git a/src/vs/workbench/parts/terminal/test/electron-browser/terminalInstance.test.ts b/src/vs/workbench/parts/terminal/test/electron-browser/terminalInstance.test.ts index df83db52ee2..d85abe821f8 100644 --- a/src/vs/workbench/parts/terminal/test/electron-browser/terminalInstance.test.ts +++ b/src/vs/workbench/parts/terminal/test/electron-browser/terminalInstance.test.ts @@ -10,7 +10,7 @@ import * as os from 'os'; import Uri from 'vs/base/common/uri'; import { IMessageService } from 'vs/platform/message/common/message'; import { IStringDictionary } from 'vs/base/common/collections'; -import { IWorkspace, IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; +import { ILegacyWorkspace, IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { TerminalInstance } from 'vs/workbench/parts/terminal/electron-browser/terminalInstance'; import { IShellLaunchConfig } from 'vs/workbench/parts/terminal/common/terminal'; import { TestInstantiationService } from 'vs/platform/instantiation/test/common/instantiationServiceMock'; @@ -20,11 +20,11 @@ import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding'; import { IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; class TestTerminalInstance extends TerminalInstance { - public _getCwd(shell: IShellLaunchConfig, workspace: IWorkspace): string { + public _getCwd(shell: IShellLaunchConfig, workspace: ILegacyWorkspace): string { return super._getCwd(shell, workspace); } - protected _createProcess(workspace: IWorkspace, shell: IShellLaunchConfig): void { } + protected _createProcess(workspace: ILegacyWorkspace, shell: IShellLaunchConfig): void { } protected _createXterm(): void { } } diff --git a/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts b/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts index 1c6a4f13b79..220f2adccfd 100644 --- a/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts +++ b/src/vs/workbench/parts/terminal/test/electron-browser/terminalLinkHandler.test.ts @@ -8,7 +8,7 @@ import * as assert from 'assert'; import { Platform } from 'vs/base/common/platform'; import { TerminalLinkHandler, LineColumnInfo } from 'vs/workbench/parts/terminal/electron-browser/terminalLinkHandler'; -import { Workspace } from 'vs/platform/workspace/common/workspace'; +import { LegacyWorkspace } from 'vs/platform/workspace/common/workspace'; import { TestContextService } from 'vs/workbench/test/workbenchTestServices'; import URI from 'vs/base/common/uri'; import * as strings from 'vs/base/common/strings'; @@ -45,7 +45,7 @@ interface LinkFormatInfo { column?: string; } -class TestWorkspace extends Workspace { +class TestWorkspace extends LegacyWorkspace { constructor(private basePath: string) { super(new TestURI(basePath)); } diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index e5613d3190b..8c1142fa18a 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -18,7 +18,7 @@ import { Schemas } from "vs/base/common/network"; import { RunOnceScheduler } from 'vs/base/common/async'; import { readFile } from 'vs/base/node/pfs'; import * as extfs from 'vs/base/node/extfs'; -import { IWorkspaceContextService, IWorkspace2, Workspace as LegacyWorkspace, IWorkspace as ILegacyWorkspace } from "vs/platform/workspace/common/workspace"; +import { IWorkspaceContextService, IWorkspace2, LegacyWorkspace, ILegacyWorkspace } from "vs/platform/workspace/common/workspace"; import { FileChangeType, FileChangesEvent, isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; import { isLinux } from 'vs/base/common/platform'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; diff --git a/src/vs/workbench/services/configuration/test/node/configuration.test.ts b/src/vs/workbench/services/configuration/test/node/configuration.test.ts index 6a2ec1f6cd1..96370af434b 100644 --- a/src/vs/workbench/services/configuration/test/node/configuration.test.ts +++ b/src/vs/workbench/services/configuration/test/node/configuration.test.ts @@ -13,7 +13,7 @@ import * as sinon from 'sinon'; import { TPromise } from 'vs/base/common/winjs.base'; import { Registry } from 'vs/platform/platform'; import { ParsedArgs } from 'vs/platform/environment/common/environment'; -import { Workspace } from 'vs/platform/workspace/common/workspace'; +import { LegacyWorkspace } from 'vs/platform/workspace/common/workspace'; import { EnvironmentService } from 'vs/platform/environment/node/environmentService'; import { parseArgs } from 'vs/platform/environment/node/argv'; import extfs = require('vs/base/node/extfs'); @@ -47,7 +47,7 @@ suite('WorkspaceConfigurationService - Node', () => { } function createService(workspaceDir: string, globalSettingsFile: string): TPromise { - const workspace = new Workspace(URI.file(workspaceDir)); + const workspace = new LegacyWorkspace(URI.file(workspaceDir)); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); const service = new WorkspaceConfigurationService(environmentService, workspace); @@ -204,7 +204,7 @@ suite('WorkspaceConfigurationService - Node', () => { test('workspace change triggers event', (done: () => void) => { createWorkspace((workspaceDir, globalSettingsFile, cleanUp) => { - const workspace = new Workspace(URI.file(workspaceDir)); + const workspace = new LegacyWorkspace(URI.file(workspaceDir)); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); const service = new WorkspaceConfigurationService(environmentService, workspace); @@ -230,7 +230,7 @@ suite('WorkspaceConfigurationService - Node', () => { test('workspace reload should triggers event if content changed', (done: () => void) => { createWorkspace((workspaceDir, globalSettingsFile, cleanUp) => { - const workspace = new Workspace(URI.file(workspaceDir)); + const workspace = new LegacyWorkspace(URI.file(workspaceDir)); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); const service = new WorkspaceConfigurationService(environmentService, workspace); @@ -255,7 +255,7 @@ suite('WorkspaceConfigurationService - Node', () => { test('workspace reload should not trigger event if nothing changed', (done: () => void) => { createWorkspace((workspaceDir, globalSettingsFile, cleanUp) => { - const workspace = new Workspace(URI.file(workspaceDir)); + const workspace = new LegacyWorkspace(URI.file(workspaceDir)); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); const service = new WorkspaceConfigurationService(environmentService, workspace); @@ -280,7 +280,7 @@ suite('WorkspaceConfigurationService - Node', () => { test('workspace reload should not trigger event if there is no model', (done: () => void) => { createWorkspace((workspaceDir, globalSettingsFile, cleanUp) => { - const workspace = new Workspace(URI.file(workspaceDir)); + const workspace = new LegacyWorkspace(URI.file(workspaceDir)); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); const service = new WorkspaceConfigurationService(environmentService, workspace); diff --git a/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts b/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts index 9ce0d3b7fd5..8ad27dc8ed3 100644 --- a/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts +++ b/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts @@ -15,7 +15,7 @@ import { TPromise } from 'vs/base/common/winjs.base'; import { Registry } from 'vs/platform/platform'; import { ParsedArgs, IEnvironmentService } from 'vs/platform/environment/common/environment'; import { parseArgs } from 'vs/platform/environment/node/argv'; -import { IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService, LegacyWorkspace } from 'vs/platform/workspace/common/workspace'; import { EnvironmentService } from 'vs/platform/environment/node/environmentService'; import extfs = require('vs/base/node/extfs'); import { TestTextFileService, TestEditorGroupService, TestLifecycleService, TestBackupFileService } from 'vs/workbench/test/workbenchTestServices'; @@ -115,7 +115,7 @@ suite('ConfigurationEditingService', () => { instantiationService = new TestInstantiationService(); const environmentService = new SettingsTestEnvironmentService(parseArgs(process.argv), process.execPath, globalSettingsFile); instantiationService.stub(IEnvironmentService, environmentService); - const workspace = noWorkspace ? null : new Workspace(URI.file(workspaceDir)); + const workspace = noWorkspace ? null : new LegacyWorkspace(URI.file(workspaceDir)); const workspaceService = new WorkspaceConfigurationService(environmentService, workspace); instantiationService.stub(IWorkspaceContextService, workspaceService); instantiationService.stub(IConfigurationService, workspaceService); diff --git a/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts b/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts index c0c8221a118..e47e2448e0a 100644 --- a/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts +++ b/src/vs/workbench/test/electron-browser/quickopen.perf.integrationTest.ts @@ -7,7 +7,7 @@ import 'vs/workbench/parts/search/browser/search.contribution'; // load contributions import * as assert from 'assert'; -import { IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService, LegacyWorkspace } from 'vs/platform/workspace/common/workspace'; import { createSyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { ISearchService } from 'vs/platform/search/common/search'; @@ -72,7 +72,7 @@ suite('QuickOpen performance (integration)', () => { [ITelemetryService, telemetryService], [IConfigurationService, configurationService], [IModelService, new ModelServiceImpl(null, configurationService)], - [IWorkspaceContextService, new TestContextService(new Workspace(URI.file(testWorkspacePath)))], + [IWorkspaceContextService, new TestContextService(new LegacyWorkspace(URI.file(testWorkspacePath)))], [IWorkbenchEditorService, new TestEditorService()], [IEditorGroupService, new TestEditorGroupService()], [IEnvironmentService, TestEnvironmentService], diff --git a/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts b/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts index cda4052f987..40c99b3e650 100644 --- a/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts +++ b/src/vs/workbench/test/electron-browser/textsearch.perf.integrationTest.ts @@ -8,7 +8,7 @@ import 'vs/workbench/parts/search/browser/search.contribution'; // load contributions import * as assert from 'assert'; import * as fs from 'fs'; -import { IWorkspaceContextService, Workspace } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService, LegacyWorkspace } from 'vs/platform/workspace/common/workspace'; import { createSyncDescriptor } from 'vs/platform/instantiation/common/descriptors'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { ISearchService, IQueryOptions } from 'vs/platform/search/common/search'; @@ -62,7 +62,7 @@ suite('TextSearch performance (integration)', () => { [ITelemetryService, telemetryService], [IConfigurationService, configurationService], [IModelService, new ModelServiceImpl(null, configurationService)], - [IWorkspaceContextService, new TestContextService(new Workspace(URI.file(testWorkspacePath)))], + [IWorkspaceContextService, new TestContextService(new LegacyWorkspace(URI.file(testWorkspacePath)))], [IWorkbenchEditorService, new TestEditorService()], [IEditorGroupService, new TestEditorGroupService()], [IEnvironmentService, TestEnvironmentService], diff --git a/src/vs/workbench/test/workbenchTestServices.ts b/src/vs/workbench/test/workbenchTestServices.ts index fed3804bdff..623981f2b7b 100644 --- a/src/vs/workbench/test/workbenchTestServices.ts +++ b/src/vs/workbench/test/workbenchTestServices.ts @@ -27,7 +27,7 @@ import { ITextModelService } from 'vs/editor/common/services/resolverService'; import { IEditorInput, IEditorOptions, Position, Direction, IEditor, IResourceInput } from 'vs/platform/editor/common/editor'; import { IUntitledEditorService, UntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; import { IMessageService, IConfirmation } from 'vs/platform/message/common/message'; -import { IWorkspace, IWorkspaceContextService, IWorkspace2 } from 'vs/platform/workspace/common/workspace'; +import { ILegacyWorkspace, IWorkspaceContextService, IWorkspace2 } from 'vs/platform/workspace/common/workspace'; import { ILifecycleService, ShutdownEvent, ShutdownReason, StartupKind, LifecyclePhase } from 'vs/platform/lifecycle/common/lifecycle'; import { EditorStacksModel } from 'vs/workbench/common/editor/editorStacksModel'; import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; @@ -64,7 +64,7 @@ export const TestEnvironmentService = new EnvironmentService(parseArgs(process.a export class TestContextService implements IWorkspaceContextService { public _serviceBrand: any; - private workspace: IWorkspace; + private workspace: ILegacyWorkspace; private id: string; private options: any; @@ -89,7 +89,7 @@ export class TestContextService implements IWorkspaceContextService { return !!this.workspace; } - public getWorkspace(): IWorkspace { + public getWorkspace(): ILegacyWorkspace { return this.workspace; } -- GitLab From c0317cbdc8aba10ae292ebcf3d6c1693ff9c9e46 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Fri, 16 Jun 2017 10:40:55 +0200 Subject: [PATCH 0938/1347] #28538 Rename new IWorkspace2 to IWorkspace --- src/vs/editor/browser/standalone/simpleServices.ts | 6 +++--- src/vs/platform/workspace/common/workspace.ts | 4 ++-- .../services/configuration/node/configuration.ts | 8 ++++---- src/vs/workbench/test/workbenchTestServices.ts | 4 ++-- 4 files changed, 11 insertions(+), 11 deletions(-) diff --git a/src/vs/editor/browser/standalone/simpleServices.ts b/src/vs/editor/browser/standalone/simpleServices.ts index 4fad640c21e..13e9ebf2401 100644 --- a/src/vs/editor/browser/standalone/simpleServices.ts +++ b/src/vs/editor/browser/standalone/simpleServices.ts @@ -17,7 +17,7 @@ import { KeybindingResolver } from 'vs/platform/keybinding/common/keybindingReso import { IKeybindingEvent, KeybindingSource, IKeyboardEvent } from 'vs/platform/keybinding/common/keybinding'; import { ContextKeyExpr, IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; import { IConfirmation, IMessageService } from 'vs/platform/message/common/message'; -import { IWorkspaceContextService, ILegacyWorkspace, IWorkspace2 } from 'vs/platform/workspace/common/workspace'; +import { IWorkspaceContextService, ILegacyWorkspace, IWorkspace } from 'vs/platform/workspace/common/workspace'; import * as editorCommon from 'vs/editor/common/editorCommon'; import { ICodeEditor, IDiffEditor } from 'vs/editor/browser/editorBrowser'; import { Selection } from 'vs/editor/common/core/selection'; @@ -511,7 +511,7 @@ export class SimpleWorkspaceContextService implements IWorkspaceContextService { public readonly onDidChangeWorkspaceRoots: Event = this._onDidChangeWorkspaceRoots.event; private readonly legacyWorkspace: ILegacyWorkspace; - private readonly workspace: IWorkspace2; + private readonly workspace: IWorkspace; constructor() { this.legacyWorkspace = { resource: URI.from({ scheme: SimpleWorkspaceContextService.SCHEME, authority: 'model', path: '/' }), ctime: Date.now() }; @@ -522,7 +522,7 @@ export class SimpleWorkspaceContextService implements IWorkspaceContextService { return this.legacyWorkspace; } - public getWorkspace2(): IWorkspace2 { + public getWorkspace2(): IWorkspace { return this.workspace; } diff --git a/src/vs/platform/workspace/common/workspace.ts b/src/vs/platform/workspace/common/workspace.ts index 25ac39d2716..3cd9b028cef 100644 --- a/src/vs/platform/workspace/common/workspace.ts +++ b/src/vs/platform/workspace/common/workspace.ts @@ -31,7 +31,7 @@ export interface IWorkspaceContextService { * Provides access to the workspace object the platform is running with. This may be null if the workbench was opened * without workspace (empty); */ - getWorkspace2(): IWorkspace2; + getWorkspace2(): IWorkspace; /** * An event which fires on workspace roots change. @@ -81,7 +81,7 @@ export interface ILegacyWorkspace { name?: string; } -export interface IWorkspace2 { +export interface IWorkspace { /** * the unique identifier of the workspace. diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index 8c1142fa18a..e7845a1264b 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -18,7 +18,7 @@ import { Schemas } from "vs/base/common/network"; import { RunOnceScheduler } from 'vs/base/common/async'; import { readFile } from 'vs/base/node/pfs'; import * as extfs from 'vs/base/node/extfs'; -import { IWorkspaceContextService, IWorkspace2, LegacyWorkspace, ILegacyWorkspace } from "vs/platform/workspace/common/workspace"; +import { IWorkspaceContextService, IWorkspace, LegacyWorkspace, ILegacyWorkspace } from "vs/platform/workspace/common/workspace"; import { FileChangeType, FileChangesEvent, isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; import { isLinux } from 'vs/base/common/platform'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; @@ -48,7 +48,7 @@ interface IWorkspaceConfiguration { type IWorkspaceFoldersConfiguration = { [rootFolder: string]: { folders: string[]; } }; -class Workspace implements IWorkspace2 { +class Workspace implements IWorkspace { private _name: string; constructor( @@ -75,7 +75,7 @@ class Workspace implements IWorkspace2 { return this._name; } - public toJSON(): IWorkspace2 { + public toJSON(): IWorkspace { return { id: this.id, roots: this.roots, name: this.name }; } } @@ -165,7 +165,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp return this.legacyWorkspace; } - public getWorkspace2(): IWorkspace2 { + public getWorkspace2(): IWorkspace { return this.workspace; } diff --git a/src/vs/workbench/test/workbenchTestServices.ts b/src/vs/workbench/test/workbenchTestServices.ts index 623981f2b7b..cff7f145626 100644 --- a/src/vs/workbench/test/workbenchTestServices.ts +++ b/src/vs/workbench/test/workbenchTestServices.ts @@ -27,7 +27,7 @@ import { ITextModelService } from 'vs/editor/common/services/resolverService'; import { IEditorInput, IEditorOptions, Position, Direction, IEditor, IResourceInput } from 'vs/platform/editor/common/editor'; import { IUntitledEditorService, UntitledEditorService } from 'vs/workbench/services/untitled/common/untitledEditorService'; import { IMessageService, IConfirmation } from 'vs/platform/message/common/message'; -import { ILegacyWorkspace, IWorkspaceContextService, IWorkspace2 } from 'vs/platform/workspace/common/workspace'; +import { ILegacyWorkspace, IWorkspaceContextService, IWorkspace } from 'vs/platform/workspace/common/workspace'; import { ILifecycleService, ShutdownEvent, ShutdownReason, StartupKind, LifecyclePhase } from 'vs/platform/lifecycle/common/lifecycle'; import { EditorStacksModel } from 'vs/workbench/common/editor/editorStacksModel'; import { ServiceCollection } from 'vs/platform/instantiation/common/serviceCollection'; @@ -93,7 +93,7 @@ export class TestContextService implements IWorkspaceContextService { return this.workspace; } - public getWorkspace2(): IWorkspace2 { + public getWorkspace2(): IWorkspace { return this.workspace ? { id: this.id, roots: [this.workspace.resource], name: this.workspace.resource.fsPath } : void 0; } -- GitLab From c2901b2b392d059415a7ab880785d11518e03628 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Fri, 16 Jun 2017 11:27:43 +0200 Subject: [PATCH 0939/1347] #28538 Extract and expose new Workspace object --- src/vs/platform/workspace/common/workspace.ts | 30 ++++++++++++ .../configuration/node/configuration.ts | 49 +++---------------- 2 files changed, 37 insertions(+), 42 deletions(-) diff --git a/src/vs/platform/workspace/common/workspace.ts b/src/vs/platform/workspace/common/workspace.ts index 3cd9b028cef..7534ba70696 100644 --- a/src/vs/platform/workspace/common/workspace.ts +++ b/src/vs/platform/workspace/common/workspace.ts @@ -141,4 +141,34 @@ export class LegacyWorkspace implements ILegacyWorkspace { return null; } +} + +export class Workspace implements IWorkspace { + + constructor( + public readonly id: string, + private _name: string, + private _roots: URI[] + ) { + } + + public get roots(): URI[] { + return this._roots; + } + + public set roots(roots: URI[]) { + this._roots = roots; + } + + public get name(): string { + return this._name; + } + + public set name(name: string) { + this._name = name; + } + + public toJSON(): IWorkspace { + return { id: this.id, roots: this.roots, name: this.name }; + } } \ No newline at end of file diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index e7845a1264b..0a959e38a65 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -18,7 +18,7 @@ import { Schemas } from "vs/base/common/network"; import { RunOnceScheduler } from 'vs/base/common/async'; import { readFile } from 'vs/base/node/pfs'; import * as extfs from 'vs/base/node/extfs'; -import { IWorkspaceContextService, IWorkspace, LegacyWorkspace, ILegacyWorkspace } from "vs/platform/workspace/common/workspace"; +import { IWorkspaceContextService, IWorkspace, Workspace, ILegacyWorkspace, LegacyWorkspace } from "vs/platform/workspace/common/workspace"; import { FileChangeType, FileChangesEvent, isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; import { isLinux } from 'vs/base/common/platform'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; @@ -48,38 +48,6 @@ interface IWorkspaceConfiguration { type IWorkspaceFoldersConfiguration = { [rootFolder: string]: { folders: string[]; } }; -class Workspace implements IWorkspace { - private _name: string; - - constructor( - public readonly id: string, - private _roots: URI[] - ) { - // - } - - public set roots(roots: URI[]) { - this._roots = roots; - this._name = null; // will be recomputed based on roots next time accessed - } - - public get roots(): URI[] { - return this._roots; - } - - public get name(): string { - if (!this._name) { - this._name = this.roots.map(root => basename(root.fsPath) || root.fsPath).join(', '); - } - - return this._name; - } - - public toJSON(): IWorkspace { - return { id: this.id, roots: this.roots, name: this.name }; - } -} - export class WorkspaceConfigurationService extends Disposable implements IWorkspaceContextService, IWorkspaceConfigurationService { public _serviceBrand: any; @@ -98,15 +66,10 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp private rootsTrieMap: TrieMap = new TrieMap(TrieMap.PathSplitter); private _configuration: Configuration; - constructor(private environmentService: IEnvironmentService, private legacyWorkspace?: LegacyWorkspace, private workspaceSettingsRootFolder: string = WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME) { + constructor(private environmentService: IEnvironmentService, private readonly legacyWorkspace?: LegacyWorkspace, private workspaceSettingsRootFolder: string = WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME) { super(); - if (legacyWorkspace) { - const workspaceId = createHash('md5').update(legacyWorkspace.resource.fsPath).update(legacyWorkspace.ctime ? String(legacyWorkspace.ctime) : '').digest('hex'); - this.workspace = new Workspace(workspaceId, [legacyWorkspace.resource]); - } else { - this.workspace = null; - } + this.workspace = legacyWorkspace ? new Workspace(createHash('md5').update(legacyWorkspace.resource.fsPath).update(legacyWorkspace.ctime ? String(legacyWorkspace.ctime) : '').digest('hex'), basename(legacyWorkspace.resource.fsPath), [legacyWorkspace.resource]) : null; this.rootsTrieMap = new TrieMap(TrieMap.PathSplitter); if (this.workspace) { @@ -147,9 +110,11 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp // Find changes const changed = !equals(this.workspace.roots, configuredFolders, (r1, r2) => r1.toString() === r2.toString()); - this.workspace.roots = configuredFolders; - if (changed) { + + this.workspace.roots = configuredFolders; + this.workspace.name = configuredFolders.map(root => basename(root.fsPath) || root.fsPath).join(', '); + this.rootsTrieMap = new TrieMap(TrieMap.PathSplitter); for (const folder of this.workspace.roots) { this.rootsTrieMap.insert(folder.fsPath, folder); -- GitLab From 4e963d7592cd4649181bd562e8dfd74669b24a85 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Fri, 16 Jun 2017 11:32:38 +0200 Subject: [PATCH 0940/1347] #28538 Move getRoot method to Workspace object --- src/vs/platform/workspace/common/workspace.ts | 18 +++++++++++++++++- .../configuration/node/configuration.ts | 16 +++------------- 2 files changed, 20 insertions(+), 14 deletions(-) diff --git a/src/vs/platform/workspace/common/workspace.ts b/src/vs/platform/workspace/common/workspace.ts index 7534ba70696..7733f14a34c 100644 --- a/src/vs/platform/workspace/common/workspace.ts +++ b/src/vs/platform/workspace/common/workspace.ts @@ -6,7 +6,8 @@ import URI from 'vs/base/common/uri'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; -import paths = require('vs/base/common/paths'); +import * as paths from 'vs/base/common/paths'; +import { TrieMap } from 'vs/base/common/map'; import { isEqualOrParent } from 'vs/platform/files/common/files'; import { isLinux } from 'vs/base/common/platform'; import Event from 'vs/base/common/event'; @@ -145,11 +146,14 @@ export class LegacyWorkspace implements ILegacyWorkspace { export class Workspace implements IWorkspace { + private _rootsMap: TrieMap = new TrieMap(TrieMap.PathSplitter); + constructor( public readonly id: string, private _name: string, private _roots: URI[] ) { + this.updateRootsMap(); } public get roots(): URI[] { @@ -158,6 +162,7 @@ export class Workspace implements IWorkspace { public set roots(roots: URI[]) { this._roots = roots; + this.updateRootsMap(); } public get name(): string { @@ -168,6 +173,17 @@ export class Workspace implements IWorkspace { this._name = name; } + public getRoot(resource: URI): URI { + return this._rootsMap.findSubstr(resource.fsPath); + } + + private updateRootsMap(): void { + this._rootsMap = new TrieMap(TrieMap.PathSplitter); + for (const root of this.roots) { + this._rootsMap.insert(root.fsPath, root); + } + } + public toJSON(): IWorkspace { return { id: this.id, roots: this.roots, name: this.name }; } diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index 0a959e38a65..cd6fa13bedc 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -8,7 +8,7 @@ import URI from 'vs/base/common/uri'; import * as paths from 'vs/base/common/paths'; import { TPromise } from 'vs/base/common/winjs.base'; import Event, { Emitter } from 'vs/base/common/event'; -import { StrictResourceMap, TrieMap } from 'vs/base/common/map'; +import { StrictResourceMap } from 'vs/base/common/map'; import { distinct, equals } from "vs/base/common/arrays"; import * as objects from 'vs/base/common/objects'; import * as errors from 'vs/base/common/errors'; @@ -63,18 +63,13 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp private cachedFolderConfigs: StrictResourceMap>; private readonly workspace: Workspace; - private rootsTrieMap: TrieMap = new TrieMap(TrieMap.PathSplitter); + private _configuration: Configuration; constructor(private environmentService: IEnvironmentService, private readonly legacyWorkspace?: LegacyWorkspace, private workspaceSettingsRootFolder: string = WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME) { super(); this.workspace = legacyWorkspace ? new Workspace(createHash('md5').update(legacyWorkspace.resource.fsPath).update(legacyWorkspace.ctime ? String(legacyWorkspace.ctime) : '').digest('hex'), basename(legacyWorkspace.resource.fsPath), [legacyWorkspace.resource]) : null; - - this.rootsTrieMap = new TrieMap(TrieMap.PathSplitter); - if (this.workspace) { - this.rootsTrieMap.insert(this.workspace.roots[0].fsPath, this.workspace.roots[0]); - } this._register(this.onDidUpdateConfiguration(e => this.resolveAdditionalFolders(true))); this.baseConfigurationService = this._register(new GlobalConfigurationService(environmentService)); @@ -115,11 +110,6 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp this.workspace.roots = configuredFolders; this.workspace.name = configuredFolders.map(root => basename(root.fsPath) || root.fsPath).join(', '); - this.rootsTrieMap = new TrieMap(TrieMap.PathSplitter); - for (const folder of this.workspace.roots) { - this.rootsTrieMap.insert(folder.fsPath, folder); - } - if (notify) { this._onDidChangeWorkspaceRoots.fire(configuredFolders); } @@ -139,7 +129,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } public getRoot(resource: URI): URI { - return this.rootsTrieMap.findSubstr(resource.fsPath); + return this.workspace ? this.workspace.getRoot(resource) : null; } private get workspaceUri(): URI { -- GitLab From a4b6dc95324cbdbe03e6292bb4a15db131339333 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Fri, 16 Jun 2017 12:19:21 +0200 Subject: [PATCH 0941/1347] #28538 Take workspace as input in Configuration model --- .../configuration/common/configuration.ts | 44 ++++++++++--------- src/vs/workbench/api/node/extHost.api.impl.ts | 4 +- .../api/node/extHostConfiguration.ts | 5 ++- src/vs/workbench/api/node/extHostWorkspace.ts | 15 ++++--- .../configuration/node/configuration.ts | 22 ++++++---- .../api/extHostConfiguration.test.ts | 7 +-- 6 files changed, 55 insertions(+), 42 deletions(-) diff --git a/src/vs/platform/configuration/common/configuration.ts b/src/vs/platform/configuration/common/configuration.ts index 94e02b37a29..8216a7805f0 100644 --- a/src/vs/platform/configuration/common/configuration.ts +++ b/src/vs/platform/configuration/common/configuration.ts @@ -9,6 +9,7 @@ import * as types from 'vs/base/common/types'; import * as objects from 'vs/base/common/objects'; import URI from 'vs/base/common/uri'; import { StrictResourceMap } from 'vs/base/common/map'; +import { Workspace } from 'vs/platform/workspace/common/workspace'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; import Event from 'vs/base/common/event'; @@ -199,16 +200,15 @@ export interface IConfigurationData { defaults: IConfiguraionModel; user: IConfiguraionModel; folders: { [folder: string]: IConfiguraionModel }; - workspaceUri: string; } export class Configuration { - private _global: ConfigurationModel; - private _workspace: ConfigurationModel; - protected _foldersConsolidated: StrictResourceMap>; + private _globalConfiguration: ConfigurationModel; + private _workspaceConfiguration: ConfigurationModel; + protected _foldersConsolidatedConfigurations: StrictResourceMap>; - constructor(protected _defaults: ConfigurationModel, protected _user: ConfigurationModel, protected folders: StrictResourceMap> = new StrictResourceMap>(), protected workspaceUri?: URI) { + constructor(protected _defaults: ConfigurationModel, protected _user: ConfigurationModel, protected folders: StrictResourceMap> = new StrictResourceMap>(), protected _workspace?: Workspace) { this.merge(); } @@ -221,23 +221,23 @@ export class Configuration { } get workspace(): ConfigurationModel { - return this._workspace; + return this._workspaceConfiguration; } protected merge(): void { - this._global = this._workspace = new ConfigurationModel().merge(this._defaults).merge(this._user); - this._foldersConsolidated = new StrictResourceMap>(); + this._globalConfiguration = this._workspaceConfiguration = new ConfigurationModel().merge(this._defaults).merge(this._user); + this._foldersConsolidatedConfigurations = new StrictResourceMap>(); for (const folder of this.folders.keys()) { this.mergeFolder(folder); } } protected mergeFolder(folder: URI) { - if (this.workspaceUri && this.workspaceUri.fsPath === folder.fsPath) { - this._workspace = new ConfigurationModel().merge(this._global).merge(this.folders.get(this.workspaceUri)); - this._foldersConsolidated.set(folder, this._workspace); + if (this._workspace && this.workspaceUri.fsPath === folder.fsPath) { + this._workspaceConfiguration = new ConfigurationModel().merge(this._globalConfiguration).merge(this.folders.get(this.workspaceUri)); + this._foldersConsolidatedConfigurations.set(folder, this._workspaceConfiguration); } else { - this._foldersConsolidated.set(folder, new ConfigurationModel().merge(this._workspace).merge(this.folders.get(folder))); + this._foldersConsolidatedConfigurations.set(folder, new ConfigurationModel().merge(this._workspaceConfiguration).merge(this.folders.get(folder))); } } @@ -251,8 +251,8 @@ export class Configuration { return { default: objects.clone(getConfigurationValue(overrideIdentifier ? this._defaults.override(overrideIdentifier).contents : this._defaults.contents, key)), user: objects.clone(getConfigurationValue(overrideIdentifier ? this._user.override(overrideIdentifier).contents : this._user.contents, key)), - workspace: objects.clone(this.workspaceUri ? getConfigurationValue(overrideIdentifier ? this.folders.get(this.workspaceUri).override(overrideIdentifier).contents : this.folders.get(this.workspaceUri).contents, key) : void 0), - value: objects.clone(getConfigurationValue(overrideIdentifier ? this._workspace.override(overrideIdentifier).contents : this._workspace.contents, key)) + workspace: objects.clone(this._workspace ? getConfigurationValue(overrideIdentifier ? this.folders.get(this.workspaceUri).override(overrideIdentifier).contents : this.folders.get(this.workspaceUri).contents, key) : void 0), + value: objects.clone(getConfigurationValue(overrideIdentifier ? this._workspaceConfiguration.override(overrideIdentifier).contents : this._workspaceConfiguration.contents, key)) }; } @@ -260,7 +260,7 @@ export class Configuration { return { default: this._defaults.keys, user: this._user.keys, - workspace: this.workspaceUri ? this.folders.get(this.workspaceUri).keys : [] + workspace: this._workspace ? this.folders.get(this.workspaceUri).keys : [] }; } @@ -296,8 +296,12 @@ export class Configuration { return result; } + protected get workspaceUri(): URI { + return this.workspace ? this._workspace.roots[0] : null; + } + private getConfigurationModel(overrides: IConfigurationOverrides): ConfigurationModel { - let configurationModel = overrides.resource ? this._foldersConsolidated.get(overrides.resource) || this._workspace : this._workspace; + let configurationModel = overrides.resource ? this._foldersConsolidatedConfigurations.get(overrides.resource) || this._workspaceConfiguration : this._workspaceConfiguration; return overrides.language ? configurationModel.override(overrides.language) : configurationModel; } @@ -315,20 +319,18 @@ export class Configuration { const { contents, overrides } = this.folders.get(folder); result[folder.toString()] = { contents, overrides }; return result; - }, Object.create({})), - workspaceUri: this.workspaceUri ? this.workspaceUri.toString() : void 0 + }, Object.create({})) }; } - public static parse(data: IConfigurationData): Configuration { + public static parse(data: IConfigurationData, workspace: Workspace): Configuration { const defaults = Configuration.parseConfigurationModel(data.defaults); const user = Configuration.parseConfigurationModel(data.user); const folders: StrictResourceMap> = Object.keys(data.folders).reduce((result, key) => { result.set(URI.parse(key), Configuration.parseConfigurationModel(data.folders[key])); return result; }, new StrictResourceMap>()); - const workspaceUri = data.workspaceUri ? URI.parse(data.workspaceUri) : void 0; - return new Configuration(defaults, user, folders, workspaceUri); + return new Configuration(defaults, user, folders, workspace); } private static parseConfigurationModel(model: IConfiguraionModel): ConfigurationModel { diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index 4b1429aa294..7c4e72c853d 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -83,7 +83,8 @@ export function createApiFactory( const extHostEditors = col.define(ExtHostContext.ExtHostEditors).set(new ExtHostEditors(threadService, extHostDocumentsAndEditors)); const extHostCommands = col.define(ExtHostContext.ExtHostCommands).set(new ExtHostCommands(threadService, extHostHeapService)); const extHostTreeViews = col.define(ExtHostContext.ExtHostTreeViews).set(new ExtHostTreeViews(threadService, extHostCommands)); - const extHostConfiguration = col.define(ExtHostContext.ExtHostConfiguration).set(new ExtHostConfiguration(threadService.get(MainContext.MainThreadConfiguration), initData.configuration)); + const extHostWorkspace = col.define(ExtHostContext.ExtHostWorkspace).set(new ExtHostWorkspace(threadService, initData.workspace)); + const extHostConfiguration = col.define(ExtHostContext.ExtHostConfiguration).set(new ExtHostConfiguration(threadService.get(MainContext.MainThreadConfiguration), initData.configuration, extHostWorkspace)); const extHostDiagnostics = col.define(ExtHostContext.ExtHostDiagnostics).set(new ExtHostDiagnostics(threadService)); const languageFeatures = col.define(ExtHostContext.ExtHostLanguageFeatures).set(new ExtHostLanguageFeatures(threadService, extHostDocuments, extHostCommands, extHostHeapService, extHostDiagnostics)); const extHostFileSystemEvent = col.define(ExtHostContext.ExtHostFileSystemEventService).set(new ExtHostFileSystemEventService()); @@ -91,7 +92,6 @@ export function createApiFactory( const extHostTerminalService = col.define(ExtHostContext.ExtHostTerminalService).set(new ExtHostTerminalService(threadService)); const extHostSCM = col.define(ExtHostContext.ExtHostSCM).set(new ExtHostSCM(threadService, extHostCommands)); const extHostTask = col.define(ExtHostContext.ExtHostTask).set(new ExtHostTask(threadService)); - const extHostWorkspace = col.define(ExtHostContext.ExtHostWorkspace).set(new ExtHostWorkspace(threadService, initData.workspace)); col.define(ExtHostContext.ExtHostExtensionService).set(extensionService); col.finish(false, threadService); diff --git a/src/vs/workbench/api/node/extHostConfiguration.ts b/src/vs/workbench/api/node/extHostConfiguration.ts index 5ee24322929..da84ebf96ba 100644 --- a/src/vs/workbench/api/node/extHostConfiguration.ts +++ b/src/vs/workbench/api/node/extHostConfiguration.ts @@ -7,6 +7,7 @@ import { mixin } from 'vs/base/common/objects'; import Event, { Emitter } from 'vs/base/common/event'; import { WorkspaceConfiguration } from 'vscode'; +import { ExtHostWorkspace } from 'vs/workbench/api/node/extHostWorkspace'; import { ExtHostConfigurationShape, MainThreadConfigurationShape } from './extHost.protocol'; import { IConfigurationData, Configuration } from 'vs/platform/configuration/common/configuration'; import { ConfigurationTarget } from 'vs/workbench/services/configuration/common/configurationEditing'; @@ -29,7 +30,7 @@ export class ExtHostConfiguration extends ExtHostConfigurationShape { private _data: IConfigurationData; private _configuration: Configuration; - constructor(proxy: MainThreadConfigurationShape, data: IConfigurationData) { + constructor(proxy: MainThreadConfigurationShape, data: IConfigurationData, private extWorkspace: ExtHostWorkspace) { super(); this._proxy = proxy; this._data = data; @@ -47,7 +48,7 @@ export class ExtHostConfiguration extends ExtHostConfigurationShape { private get configuration(): Configuration { if (!this._configuration) { - this._configuration = Configuration.parse(this._data); + this._configuration = Configuration.parse(this._data, this.extWorkspace.workspace); } return this._configuration; } diff --git a/src/vs/workbench/api/node/extHostWorkspace.ts b/src/vs/workbench/api/node/extHostWorkspace.ts index e222fb03816..8cb2947fe41 100644 --- a/src/vs/workbench/api/node/extHostWorkspace.ts +++ b/src/vs/workbench/api/node/extHostWorkspace.ts @@ -9,6 +9,7 @@ import Event, { Emitter } from 'vs/base/common/event'; import { normalize } from 'vs/base/common/paths'; import { isFalsyOrEmpty } from 'vs/base/common/arrays'; import { relative } from 'path'; +import { Workspace } from 'vs/platform/workspace/common/workspace'; import { IThreadService } from 'vs/workbench/services/thread/common/threadService'; import { IResourceEdit } from 'vs/editor/common/services/bulkEdit'; import { TPromise } from 'vs/base/common/winjs.base'; @@ -22,18 +23,22 @@ export class ExtHostWorkspace extends ExtHostWorkspaceShape { private readonly _onDidChangeWorkspace = new Emitter(); private readonly _proxy: MainThreadWorkspaceShape; - private _workspace: IWorkspaceData; + private _workspace: Workspace; readonly onDidChangeWorkspace: Event = this._onDidChangeWorkspace.event; - constructor(threadService: IThreadService, workspace: IWorkspaceData) { + constructor(threadService: IThreadService, data: IWorkspaceData) { super(); this._proxy = threadService.get(MainContext.MainThreadWorkspace); - this._workspace = workspace; + this._workspace = data ? new Workspace(data.id, data.name, data.roots) : null; } // --- workspace --- + get workspace(): Workspace { + return this._workspace; + } + getPath(): string { // this is legacy from the days before having // multi-root and we keep it only alive if there @@ -69,8 +74,8 @@ export class ExtHostWorkspace extends ExtHostWorkspaceShape { return normalize(path); } - $acceptWorkspaceData(workspace: IWorkspaceData): void { - this._workspace = workspace; + $acceptWorkspaceData(data: IWorkspaceData): void { + this._workspace = data ? new Workspace(data.id, data.name, data.roots) : null; this._onDidChangeWorkspace.fire(this); } diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index cd6fa13bedc..28a61bbc46c 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -69,7 +69,11 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp constructor(private environmentService: IEnvironmentService, private readonly legacyWorkspace?: LegacyWorkspace, private workspaceSettingsRootFolder: string = WORKSPACE_CONFIG_FOLDER_DEFAULT_NAME) { super(); - this.workspace = legacyWorkspace ? new Workspace(createHash('md5').update(legacyWorkspace.resource.fsPath).update(legacyWorkspace.ctime ? String(legacyWorkspace.ctime) : '').digest('hex'), basename(legacyWorkspace.resource.fsPath), [legacyWorkspace.resource]) : null; + this.workspace = legacyWorkspace ? new Workspace( + createHash('md5').update(legacyWorkspace.resource.fsPath).update(legacyWorkspace.ctime ? String(legacyWorkspace.ctime) : '').digest('hex'), + basename(legacyWorkspace.resource.fsPath), + [legacyWorkspace.resource] + ) : null; this._register(this.onDidUpdateConfiguration(e => this.resolveAdditionalFolders(true))); this.baseConfigurationService = this._register(new GlobalConfigurationService(environmentService)); @@ -233,7 +237,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp private initCaches(): void { this.cachedFolderConfigs = new StrictResourceMap>(); - this._configuration = new Configuration(this.baseConfigurationService.configuration(), new StrictResourceMap>(), this.workspaceUri); + this._configuration = new Configuration(this.baseConfigurationService.configuration(), new StrictResourceMap>(), this.workspace); this.initCachesForFolders(this.workspace ? this.workspace.roots : []); } @@ -467,12 +471,12 @@ function resolveStat(resource: URI): TPromise { class Configuration extends BaseConfiguration { - constructor(private _baseConfiguration: Configuration, protected folders: StrictResourceMap>, workspaceUri: URI) { - super(_baseConfiguration.defaults, _baseConfiguration.user, folders, workspaceUri); + constructor(private _baseConfiguration: Configuration, protected folders: StrictResourceMap>, workspace: Workspace) { + super(_baseConfiguration.defaults, _baseConfiguration.user, folders, workspace); } updateBaseConfiguration(baseConfiguration: Configuration): boolean { - const current = new Configuration(this._baseConfiguration, this.folders, this.workspaceUri); + const current = new Configuration(this._baseConfiguration, this.folders, this._workspace); this._defaults = baseConfiguration.defaults; this._user = baseConfiguration.user; @@ -489,13 +493,13 @@ class Configuration extends BaseConfiguration { } deleteFolderConfiguration(folder: URI): boolean { - if (this.workspaceUri && this.workspaceUri.fsPath === folder.fsPath) { + if (this.workspace && this.workspaceUri.fsPath === folder.fsPath) { // Do not remove workspace configuration return false; } this.folders.delete(folder); - return this._foldersConsolidated.delete(folder); + return this._foldersConsolidatedConfigurations.delete(folder); } getFolderConfigurationModel(folder: URI): FolderConfigurationModel { @@ -511,11 +515,11 @@ class Configuration extends BaseConfiguration { return false; } - if (this._foldersConsolidated.size !== other._foldersConsolidated.size) { + if (this._foldersConsolidatedConfigurations.size !== other._foldersConsolidatedConfigurations.size) { return false; } - for (const resource of this._foldersConsolidated.keys()) { + for (const resource of this._foldersConsolidatedConfigurations.keys()) { if (!objects.equals(this.getValue(null, { resource }), other.getValue(null, { resource }))) { return false; } diff --git a/src/vs/workbench/test/electron-browser/api/extHostConfiguration.test.ts b/src/vs/workbench/test/electron-browser/api/extHostConfiguration.test.ts index acdf7e0de9f..a07b32c76b4 100644 --- a/src/vs/workbench/test/electron-browser/api/extHostConfiguration.test.ts +++ b/src/vs/workbench/test/electron-browser/api/extHostConfiguration.test.ts @@ -6,11 +6,13 @@ 'use strict'; import * as assert from 'assert'; +import { ExtHostWorkspace } from 'vs/workbench/api/node/extHostWorkspace'; import { ExtHostConfiguration } from 'vs/workbench/api/node/extHostConfiguration'; import { MainThreadConfigurationShape } from 'vs/workbench/api/node/extHost.protocol'; import { TPromise } from 'vs/base/common/winjs.base'; import { ConfigurationTarget, ConfigurationEditingErrorCode, IConfigurationEditingError } from 'vs/workbench/services/configuration/common/configurationEditing'; import { ConfigurationModel } from 'vs/platform/configuration/common/configuration'; +import { TestThreadService } from './testThreadService'; suite('ExtHostConfiguration', function () { @@ -29,9 +31,8 @@ suite('ExtHostConfiguration', function () { return new ExtHostConfiguration(shape, { defaults: new ConfigurationModel(contents), user: new ConfigurationModel(contents), - folders: Object.create(null), - workspaceUri: void 0 - }); + folders: Object.create(null) + }, new ExtHostWorkspace(new TestThreadService(), null)); } test('getConfiguration fails regression test 1.7.1 -> 1.8 #15552', function () { -- GitLab From c635d7a23f666c6730dba30cf254950b0865e3c2 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Fri, 16 Jun 2017 12:29:54 +0200 Subject: [PATCH 0942/1347] #28538 Let Configuration object gets the root given the resource from workspace --- .../configuration/common/configuration.ts | 19 ++++++++++++++++++- .../configuration/node/configuration.ts | 1 - 2 files changed, 18 insertions(+), 2 deletions(-) diff --git a/src/vs/platform/configuration/common/configuration.ts b/src/vs/platform/configuration/common/configuration.ts index 8216a7805f0..1b31073ea9f 100644 --- a/src/vs/platform/configuration/common/configuration.ts +++ b/src/vs/platform/configuration/common/configuration.ts @@ -301,10 +301,27 @@ export class Configuration { } private getConfigurationModel(overrides: IConfigurationOverrides): ConfigurationModel { - let configurationModel = overrides.resource ? this._foldersConsolidatedConfigurations.get(overrides.resource) || this._workspaceConfiguration : this._workspaceConfiguration; + let configurationModel = this.getConfigurationForResource(overrides); return overrides.language ? configurationModel.override(overrides.language) : configurationModel; } + private getConfigurationForResource({ resource }: IConfigurationOverrides): ConfigurationModel { + if (!this.workspace) { + return this._globalConfiguration; + } + + if (!resource) { + return this._workspaceConfiguration; + } + + const root = this._workspace.getRoot(resource); + if (!root) { + return this._workspaceConfiguration; + } + + return this._foldersConsolidatedConfigurations.get(root) || this._workspaceConfiguration; + } + public toData(): IConfigurationData { return { defaults: { diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index 28a61bbc46c..6da212e044e 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -161,7 +161,6 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp } public getConfiguration(section?: string, overrides?: IConfigurationOverrides): C { - overrides = overrides && overrides.resource ? { ...overrides, resource: this.getRoot(overrides.resource) } : overrides; return this._configuration.getValue(section, overrides); } -- GitLab From d26fecce8527072d3e67179fc574103812cc85dc Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 16 Jun 2017 11:02:48 +0200 Subject: [PATCH 0943/1347] Move SelectionClipboard up to /workbench/ --- src/vs/workbench/electron-browser/workbench.main.ts | 1 - src/vs/workbench/parts/codeEditor/codeEditor.contribution.ts | 3 ++- .../parts/codeEditor}/electron-browser/selectionClipboard.ts | 0 src/vs/workbench/parts/debug/electron-browser/replEditor.ts | 2 +- 4 files changed, 3 insertions(+), 3 deletions(-) rename src/vs/{editor/contrib/selectionClipboard => workbench/parts/codeEditor}/electron-browser/selectionClipboard.ts (100%) diff --git a/src/vs/workbench/electron-browser/workbench.main.ts b/src/vs/workbench/electron-browser/workbench.main.ts index d68ce2e3acf..9eac4e5637b 100644 --- a/src/vs/workbench/electron-browser/workbench.main.ts +++ b/src/vs/workbench/electron-browser/workbench.main.ts @@ -11,7 +11,6 @@ import 'vs/base/common/errors'; // Editor import 'vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes'; -import 'vs/editor/contrib/selectionClipboard/electron-browser/selectionClipboard'; import 'vs/editor/browser/editor.all'; // Menus/Actions diff --git a/src/vs/workbench/parts/codeEditor/codeEditor.contribution.ts b/src/vs/workbench/parts/codeEditor/codeEditor.contribution.ts index f8b57c7352d..2bb951551fb 100644 --- a/src/vs/workbench/parts/codeEditor/codeEditor.contribution.ts +++ b/src/vs/workbench/parts/codeEditor/codeEditor.contribution.ts @@ -4,9 +4,10 @@ *--------------------------------------------------------------------------------------------*/ import './electron-browser/accessibility'; +import './electron-browser/inspectKeybindings'; +import './electron-browser/selectionClipboard'; import './electron-browser/toggleMultiCursorModifier'; import './electron-browser/toggleRenderControlCharacter'; import './electron-browser/toggleRenderWhitespace'; import './electron-browser/toggleWordWrap'; import './electron-browser/wordWrapMigration'; -import './electron-browser/inspectKeybindings'; diff --git a/src/vs/editor/contrib/selectionClipboard/electron-browser/selectionClipboard.ts b/src/vs/workbench/parts/codeEditor/electron-browser/selectionClipboard.ts similarity index 100% rename from src/vs/editor/contrib/selectionClipboard/electron-browser/selectionClipboard.ts rename to src/vs/workbench/parts/codeEditor/electron-browser/selectionClipboard.ts diff --git a/src/vs/workbench/parts/debug/electron-browser/replEditor.ts b/src/vs/workbench/parts/debug/electron-browser/replEditor.ts index dfa70d783bd..160dad9e10d 100644 --- a/src/vs/workbench/parts/debug/electron-browser/replEditor.ts +++ b/src/vs/workbench/parts/debug/electron-browser/replEditor.ts @@ -14,7 +14,7 @@ import { ICommandService } from 'vs/platform/commands/common/commands'; // Allowed Editor Contributions: import { MenuPreventer } from 'vs/editor/contrib/multicursor/browser/menuPreventer'; -import { SelectionClipboard } from 'vs/editor/contrib/selectionClipboard/electron-browser/selectionClipboard'; +import { SelectionClipboard } from 'vs/workbench/parts/codeEditor/electron-browser/selectionClipboard'; import { ContextMenuController } from 'vs/editor/contrib/contextmenu/browser/contextmenu'; import { SuggestController } from 'vs/editor/contrib/suggest/browser/suggestController'; import { SnippetController2 } from 'vs/editor/contrib/snippet/browser/snippetController2'; -- GitLab From 31382db17cfbb3327c39013279abf299dbffa20b Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 16 Jun 2017 11:10:48 +0200 Subject: [PATCH 0944/1347] Move InspectTMScopes up to /workbench/ --- src/vs/workbench/electron-browser/workbench.main.ts | 1 - src/vs/workbench/parts/codeEditor/codeEditor.contribution.ts | 1 + .../parts/codeEditor}/electron-browser/inspectTMScopes.css | 0 .../parts/codeEditor}/electron-browser/inspectTMScopes.ts | 0 4 files changed, 1 insertion(+), 1 deletion(-) rename src/vs/{editor/contrib/inspectTMScopes => workbench/parts/codeEditor}/electron-browser/inspectTMScopes.css (100%) rename src/vs/{editor/contrib/inspectTMScopes => workbench/parts/codeEditor}/electron-browser/inspectTMScopes.ts (100%) diff --git a/src/vs/workbench/electron-browser/workbench.main.ts b/src/vs/workbench/electron-browser/workbench.main.ts index 9eac4e5637b..7a9035a8e92 100644 --- a/src/vs/workbench/electron-browser/workbench.main.ts +++ b/src/vs/workbench/electron-browser/workbench.main.ts @@ -10,7 +10,6 @@ import 'vs/base/common/strings'; import 'vs/base/common/errors'; // Editor -import 'vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes'; import 'vs/editor/browser/editor.all'; // Menus/Actions diff --git a/src/vs/workbench/parts/codeEditor/codeEditor.contribution.ts b/src/vs/workbench/parts/codeEditor/codeEditor.contribution.ts index 2bb951551fb..0866df08008 100644 --- a/src/vs/workbench/parts/codeEditor/codeEditor.contribution.ts +++ b/src/vs/workbench/parts/codeEditor/codeEditor.contribution.ts @@ -5,6 +5,7 @@ import './electron-browser/accessibility'; import './electron-browser/inspectKeybindings'; +import './electron-browser/inspectTMScopes'; import './electron-browser/selectionClipboard'; import './electron-browser/toggleMultiCursorModifier'; import './electron-browser/toggleRenderControlCharacter'; diff --git a/src/vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes.css b/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.css similarity index 100% rename from src/vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes.css rename to src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.css diff --git a/src/vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes.ts b/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.ts similarity index 100% rename from src/vs/editor/contrib/inspectTMScopes/electron-browser/inspectTMScopes.ts rename to src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.ts -- GitLab From 19dff43f673e84ab6cd5065fd28ab3e8f25f353b Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 16 Jun 2017 11:15:42 +0200 Subject: [PATCH 0945/1347] Add the possibility for restrictions to be an OR array --- build/lib/tslint/importPatternsRule.js | 20 ++++++++++++++++++-- build/lib/tslint/importPatternsRule.ts | 22 +++++++++++++++++++--- 2 files changed, 37 insertions(+), 5 deletions(-) diff --git a/build/lib/tslint/importPatternsRule.js b/build/lib/tslint/importPatternsRule.js index 6bd94309cf8..9a6284febef 100644 --- a/build/lib/tslint/importPatternsRule.js +++ b/build/lib/tslint/importPatternsRule.js @@ -49,8 +49,24 @@ var ImportPatterns = (function (_super) { if (path[0] === '.') { return; } - if (!minimatch(path, this._config.restrictions)) { - this.addFailure(this.createFailure(node.getStart(), node.getWidth(), "Imports violates '" + this._config.restrictions + "'-restriction.")); + var restrictions; + if (typeof this._config.restrictions === 'string') { + restrictions = [this._config.restrictions]; + } + else { + restrictions = this._config.restrictions; + } + var matched = false; + for (var _i = 0, restrictions_1 = restrictions; _i < restrictions_1.length; _i++) { + var pattern = restrictions_1[_i]; + if (minimatch(path, pattern)) { + matched = true; + break; + } + } + if (!matched) { + // None of the restrictions matched + this.addFailure(this.createFailure(node.getStart(), node.getWidth(), "Imports violates '" + restrictions.join(' or ') + "' restrictions.")); } }; return ImportPatterns; diff --git a/build/lib/tslint/importPatternsRule.ts b/build/lib/tslint/importPatternsRule.ts index 469ceec743c..47f56627efd 100644 --- a/build/lib/tslint/importPatternsRule.ts +++ b/build/lib/tslint/importPatternsRule.ts @@ -9,7 +9,7 @@ import * as minimatch from 'minimatch'; interface ImportPatternsConfig { target: string; - restrictions: string; + restrictions: string | string[]; } export class Rule extends Lint.Rules.AbstractRule { @@ -45,8 +45,24 @@ class ImportPatterns extends Lint.RuleWalker { return; } - if (!minimatch(path, this._config.restrictions)) { - this.addFailure(this.createFailure(node.getStart(), node.getWidth(), `Imports violates '${this._config.restrictions}'-restriction.`)); + let restrictions: string[]; + if (typeof this._config.restrictions === 'string') { + restrictions = [this._config.restrictions]; + } else { + restrictions = this._config.restrictions; + } + + let matched = false; + for (const pattern of restrictions) { + if (minimatch(path, pattern)) { + matched = true; + break; + } + } + + if (!matched) { + // None of the restrictions matched + this.addFailure(this.createFailure(node.getStart(), node.getWidth(), `Imports violates '${restrictions.join(' or ')}' restrictions.`)); } } } -- GitLab From f6e52ec2933e2b3af08a85104257fd8ab6b5a114 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 16 Jun 2017 12:06:51 +0200 Subject: [PATCH 0946/1347] Add support for old-style require statements in linters --- build/lib/tslint/importPatternsRule.js | 15 ++++++++++++--- build/lib/tslint/importPatternsRule.ts | 15 ++++++++++++--- build/lib/tslint/layeringRule.js | 10 +++++++++- build/lib/tslint/layeringRule.ts | 10 +++++++++- .../test/{ => node}/backupFileService.test.ts | 0 .../test/{ => node}/keybindingEditing.test.ts | 0 6 files changed, 42 insertions(+), 8 deletions(-) rename src/vs/workbench/services/backup/test/{ => node}/backupFileService.test.ts (100%) rename src/vs/workbench/services/keybinding/test/{ => node}/keybindingEditing.test.ts (100%) diff --git a/build/lib/tslint/importPatternsRule.js b/build/lib/tslint/importPatternsRule.js index 9a6284febef..f2c6fd56233 100644 --- a/build/lib/tslint/importPatternsRule.js +++ b/build/lib/tslint/importPatternsRule.js @@ -14,8 +14,10 @@ var __extends = (this && this.__extends) || (function () { }; })(); Object.defineProperty(exports, "__esModule", { value: true }); +var ts = require("typescript"); var Lint = require("tslint"); var minimatch = require("minimatch"); +var path_1 = require("path"); var Rule = (function (_super) { __extends(Rule, _super); function Rule() { @@ -41,13 +43,20 @@ var ImportPatterns = (function (_super) { _this._config = _config; return _this; } + ImportPatterns.prototype.visitImportEqualsDeclaration = function (node) { + if (node.moduleReference.kind === ts.SyntaxKind.ExternalModuleReference) { + this._validateImport(node.moduleReference.expression.getText(), node); + } + }; ImportPatterns.prototype.visitImportDeclaration = function (node) { - var path = node.moduleSpecifier.getText(); + this._validateImport(node.moduleSpecifier.getText(), node); + }; + ImportPatterns.prototype._validateImport = function (path, node) { // remove quotes path = path.slice(1, -1); - // ignore relative paths + // resolve relative paths if (path[0] === '.') { - return; + path = path_1.join(this.getSourceFile().fileName, path); } var restrictions; if (typeof this._config.restrictions === 'string') { diff --git a/build/lib/tslint/importPatternsRule.ts b/build/lib/tslint/importPatternsRule.ts index 47f56627efd..6365e2d96b3 100644 --- a/build/lib/tslint/importPatternsRule.ts +++ b/build/lib/tslint/importPatternsRule.ts @@ -6,6 +6,7 @@ import * as ts from 'typescript'; import * as Lint from 'tslint'; import * as minimatch from 'minimatch'; +import { join } from 'path'; interface ImportPatternsConfig { target: string; @@ -34,15 +35,23 @@ class ImportPatterns extends Lint.RuleWalker { super(file, opts); } + protected visitImportEqualsDeclaration(node: ts.ImportEqualsDeclaration): void { + if (node.moduleReference.kind === ts.SyntaxKind.ExternalModuleReference) { + this._validateImport(node.moduleReference.expression.getText(), node); + } + } + protected visitImportDeclaration(node: ts.ImportDeclaration): void { - let path = node.moduleSpecifier.getText(); + this._validateImport(node.moduleSpecifier.getText(), node); + } + private _validateImport(path: string, node: ts.Node): void { // remove quotes path = path.slice(1, -1); - // ignore relative paths + // resolve relative paths if (path[0] === '.') { - return; + path = join(this.getSourceFile().fileName, path); } let restrictions: string[]; diff --git a/build/lib/tslint/layeringRule.js b/build/lib/tslint/layeringRule.js index 37a60b2b44f..31b19f3fb10 100644 --- a/build/lib/tslint/layeringRule.js +++ b/build/lib/tslint/layeringRule.js @@ -14,6 +14,7 @@ var __extends = (this && this.__extends) || (function () { }; })(); Object.defineProperty(exports, "__esModule", { value: true }); +var ts = require("typescript"); var Lint = require("tslint"); var path_1 = require("path"); var Rule = (function (_super) { @@ -54,8 +55,15 @@ var LayeringRule = (function (_super) { _this._config = config; return _this; } + LayeringRule.prototype.visitImportEqualsDeclaration = function (node) { + if (node.moduleReference.kind === ts.SyntaxKind.ExternalModuleReference) { + this._validateImport(node.moduleReference.expression.getText(), node); + } + }; LayeringRule.prototype.visitImportDeclaration = function (node) { - var path = node.moduleSpecifier.getText(); + this._validateImport(node.moduleSpecifier.getText(), node); + }; + LayeringRule.prototype._validateImport = function (path, node) { // remove quotes path = path.slice(1, -1); if (path[0] === '.') { diff --git a/build/lib/tslint/layeringRule.ts b/build/lib/tslint/layeringRule.ts index c6e34623b2b..8217f11d923 100644 --- a/build/lib/tslint/layeringRule.ts +++ b/build/lib/tslint/layeringRule.ts @@ -51,9 +51,17 @@ class LayeringRule extends Lint.RuleWalker { this._config = config; } + protected visitImportEqualsDeclaration(node: ts.ImportEqualsDeclaration): void { + if (node.moduleReference.kind === ts.SyntaxKind.ExternalModuleReference) { + this._validateImport(node.moduleReference.expression.getText(), node); + } + } + protected visitImportDeclaration(node: ts.ImportDeclaration): void { - let path = node.moduleSpecifier.getText(); + this._validateImport(node.moduleSpecifier.getText(), node); + } + private _validateImport(path: string, node: ts.Node): void { // remove quotes path = path.slice(1, -1); diff --git a/src/vs/workbench/services/backup/test/backupFileService.test.ts b/src/vs/workbench/services/backup/test/node/backupFileService.test.ts similarity index 100% rename from src/vs/workbench/services/backup/test/backupFileService.test.ts rename to src/vs/workbench/services/backup/test/node/backupFileService.test.ts diff --git a/src/vs/workbench/services/keybinding/test/keybindingEditing.test.ts b/src/vs/workbench/services/keybinding/test/node/keybindingEditing.test.ts similarity index 100% rename from src/vs/workbench/services/keybinding/test/keybindingEditing.test.ts rename to src/vs/workbench/services/keybinding/test/node/keybindingEditing.test.ts -- GitLab From fb48a513d87bf9118d21f8a5e9400e74cc681373 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 16 Jun 2017 12:27:26 +0200 Subject: [PATCH 0947/1347] Fix layering issues in vs/base/common --- src/vs/base/common/actions.ts | 7 ++- src/vs/base/common/labels.ts | 3 +- src/vs/base/common/paths.ts | 55 ++++++++++++++++++- src/vs/code/electron-main/app.ts | 3 +- src/vs/code/electron-main/windows.ts | 2 +- src/vs/code/node/windowsUtils.ts | 3 +- src/vs/platform/files/common/files.ts | 55 +------------------ src/vs/platform/files/test/files.test.ts | 4 +- src/vs/platform/workspace/common/workspace.ts | 3 +- .../common/editor/rangeDecorations.ts | 2 +- .../parts/files/browser/fileActions.ts | 10 ++-- .../parts/files/browser/views/explorerView.ts | 4 +- .../files/browser/views/explorerViewer.ts | 12 ++-- .../files/common/editors/fileEditorTracker.ts | 10 ++-- .../parts/files/common/explorerViewModel.ts | 8 +-- .../parts/search/browser/searchActions.ts | 3 +- .../configuration/node/configuration.ts | 6 +- .../services/files/node/fileService.ts | 3 +- .../textfile/common/textFileEditorModel.ts | 4 +- .../workbench/test/workbenchTestServices.ts | 4 +- 20 files changed, 103 insertions(+), 98 deletions(-) diff --git a/src/vs/base/common/actions.ts b/src/vs/base/common/actions.ts index b51eac17ddb..1a5e7e1acd1 100644 --- a/src/vs/base/common/actions.ts +++ b/src/vs/base/common/actions.ts @@ -9,7 +9,12 @@ import { IEventEmitter, EventEmitter } from 'vs/base/common/eventEmitter'; import { IDisposable } from 'vs/base/common/lifecycle'; import * as Events from 'vs/base/common/events'; import Event, { Emitter } from 'vs/base/common/event'; -import { ITelemetryData } from 'vs/platform/telemetry/common/telemetry'; + +export interface ITelemetryData { + from?: string; + target?: string; + [key: string]: any; +} export interface IAction extends IDisposable { id: string; diff --git a/src/vs/base/common/labels.ts b/src/vs/base/common/labels.ts index ce95b07160c..e7b950da577 100644 --- a/src/vs/base/common/labels.ts +++ b/src/vs/base/common/labels.ts @@ -7,9 +7,8 @@ import URI from 'vs/base/common/uri'; import platform = require('vs/base/common/platform'); import types = require('vs/base/common/types'); -import { nativeSep, normalize } from 'vs/base/common/paths'; +import { nativeSep, normalize, isEqualOrParent, isEqual } from 'vs/base/common/paths'; import { endsWith, ltrim } from 'vs/base/common/strings'; -import { isEqualOrParent, isEqual } from 'vs/platform/files/common/files'; export interface ILabelProvider { diff --git a/src/vs/base/common/paths.ts b/src/vs/base/common/paths.ts index 3ad625b3653..be13cd187ef 100644 --- a/src/vs/base/common/paths.ts +++ b/src/vs/base/common/paths.ts @@ -6,7 +6,7 @@ import { isLinux, isWindows } from 'vs/base/common/platform'; import { fill } from 'vs/base/common/arrays'; -import { rtrim } from 'vs/base/common/strings'; +import { rtrim, beginsWithIgnoreCase, equalsIgnoreCase } from 'vs/base/common/strings'; import { CharCode } from 'vs/base/common/charCode'; /** @@ -341,4 +341,55 @@ export function isValidBasename(name: string): boolean { } return true; -} \ No newline at end of file +} + +export function isEqual(pathA: string, pathB: string, ignoreCase?: boolean): boolean { + const identityEquals = (pathA === pathB); + if (!ignoreCase || identityEquals) { + return identityEquals; + } + + if (!pathA || !pathB) { + return false; + } + + return equalsIgnoreCase(pathA, pathB); +} + +export function isEqualOrParent(path: string, candidate: string, ignoreCase?: boolean): boolean { + if (path === candidate) { + return true; + } + + if (!path || !candidate) { + return false; + } + + if (candidate.length > path.length) { + return false; + } + + if (ignoreCase) { + const beginsWith = beginsWithIgnoreCase(path, candidate); + if (!beginsWith) { + return false; + } + + if (candidate.length === path.length) { + return true; // same path, different casing + } + + let sepOffset = candidate.length; + if (candidate.charAt(candidate.length - 1) === nativeSep) { + sepOffset--; // adjust the expected sep offset in case our candidate already ends in separator character + } + + return path.charAt(sepOffset) === nativeSep; + } + + if (candidate.charAt(candidate.length - 1) !== nativeSep) { + candidate += nativeSep; + } + + return path.indexOf(candidate) === 0; +} diff --git a/src/vs/code/electron-main/app.ts b/src/vs/code/electron-main/app.ts index a9adcc1e33a..98474156ee0 100644 --- a/src/vs/code/electron-main/app.ts +++ b/src/vs/code/electron-main/app.ts @@ -46,7 +46,8 @@ import { IWindowsMainService } from "vs/platform/windows/electron-main/windows"; import { IHistoryMainService } from "vs/platform/history/electron-main/historyMainService"; import { isUndefinedOrNull } from "vs/base/common/types"; import { CodeWindow } from "vs/code/electron-main/window"; -import { isEqual, isParent } from "vs/platform/files/common/files"; +import { isParent } from "vs/platform/files/common/files"; +import { isEqual } from "vs/base/common/paths"; import { KeyboardLayoutMonitor } from "vs/code/electron-main/keyboard"; import URI from 'vs/base/common/uri'; diff --git a/src/vs/code/electron-main/windows.ts b/src/vs/code/electron-main/windows.ts index 12a7337fb3d..f291a2e6c7c 100644 --- a/src/vs/code/electron-main/windows.ts +++ b/src/vs/code/electron-main/windows.ts @@ -24,7 +24,7 @@ import { getLastActiveWindow, findBestWindowOrFolder } from 'vs/code/node/window import CommonEvent, { Emitter } from 'vs/base/common/event'; import product from 'vs/platform/node/product'; import { ITelemetryService, ITelemetryData } from 'vs/platform/telemetry/common/telemetry'; -import { isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; +import { isEqual, isEqualOrParent } from 'vs/base/common/paths'; import { IWindowsMainService, IOpenConfiguration } from "vs/platform/windows/electron-main/windows"; import { IHistoryMainService } from "vs/platform/history/electron-main/historyMainService"; import { IProcessEnvironment, isLinux, isMacintosh } from "vs/base/common/platform"; diff --git a/src/vs/code/node/windowsUtils.ts b/src/vs/code/node/windowsUtils.ts index f7a75f9a85b..0727611a543 100644 --- a/src/vs/code/node/windowsUtils.ts +++ b/src/vs/code/node/windowsUtils.ts @@ -10,7 +10,6 @@ import * as fs from 'fs'; import * as platform from 'vs/base/common/platform'; import * as paths from 'vs/base/common/paths'; import { OpenContext } from 'vs/platform/windows/common/windows'; -import { isEqualOrParent } from 'vs/platform/files/common/files'; /** * Exported subset of CodeWindow for testing. @@ -48,7 +47,7 @@ export function findBestWindowOrFolder({ win } function findBestWindow(windows: WINDOW[], filePath: string): WINDOW { - const containers = windows.filter(window => typeof window.openedWorkspacePath === 'string' && isEqualOrParent(filePath, window.openedWorkspacePath, !platform.isLinux /* ignorecase */)); + const containers = windows.filter(window => typeof window.openedWorkspacePath === 'string' && paths.isEqualOrParent(filePath, window.openedWorkspacePath, !platform.isLinux /* ignorecase */)); if (containers.length) { return containers.sort((a, b) => -(a.openedWorkspacePath.length - b.openedWorkspacePath.length))[0]; } diff --git a/src/vs/platform/files/common/files.ts b/src/vs/platform/files/common/files.ts index 099b40f2dbf..f5616b353fb 100644 --- a/src/vs/platform/files/common/files.ts +++ b/src/vs/platform/files/common/files.ts @@ -12,7 +12,7 @@ import events = require('vs/base/common/events'); import { isLinux } from 'vs/base/common/platform'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; import Event from 'vs/base/common/event'; -import { equalsIgnoreCase, beginsWithIgnoreCase } from 'vs/base/common/strings'; +import { beginsWithIgnoreCase } from 'vs/base/common/strings'; export const IFileService = createDecorator('fileService'); @@ -231,10 +231,10 @@ export class FileChangesEvent extends events.Event { // For deleted also return true when deleted folder is parent of target path if (type === FileChangeType.DELETED) { - return isEqualOrParent(resource.fsPath, change.resource.fsPath, !isLinux /* ignorecase */); + return paths.isEqualOrParent(resource.fsPath, change.resource.fsPath, !isLinux /* ignorecase */); } - return isEqual(resource.fsPath, change.resource.fsPath, !isLinux /* ignorecase */); + return paths.isEqual(resource.fsPath, change.resource.fsPath, !isLinux /* ignorecase */); }); } @@ -291,19 +291,6 @@ export class FileChangesEvent extends events.Event { } } -export function isEqual(pathA: string, pathB: string, ignoreCase?: boolean): boolean { - const identityEquals = (pathA === pathB); - if (!ignoreCase || identityEquals) { - return identityEquals; - } - - if (!pathA || !pathB) { - return false; - } - - return equalsIgnoreCase(pathA, pathB); -} - export function isParent(path: string, candidate: string, ignoreCase?: boolean): boolean { if (!path || !candidate || path === candidate) { return false; @@ -324,43 +311,7 @@ export function isParent(path: string, candidate: string, ignoreCase?: boolean): return path.indexOf(candidate) === 0; } -export function isEqualOrParent(path: string, candidate: string, ignoreCase?: boolean): boolean { - if (path === candidate) { - return true; - } - - if (!path || !candidate) { - return false; - } - - if (candidate.length > path.length) { - return false; - } - - if (ignoreCase) { - const beginsWith = beginsWithIgnoreCase(path, candidate); - if (!beginsWith) { - return false; - } - - if (candidate.length === path.length) { - return true; // same path, different casing - } - - let sepOffset = candidate.length; - if (candidate.charAt(candidate.length - 1) === paths.nativeSep) { - sepOffset--; // adjust the expected sep offset in case our candidate already ends in separator character - } - - return path.charAt(sepOffset) === paths.nativeSep; - } - - if (candidate.charAt(candidate.length - 1) !== paths.nativeSep) { - candidate += paths.nativeSep; - } - return path.indexOf(candidate) === 0; -} export function indexOf(path: string, candidate: string, ignoreCase?: boolean): number { if (candidate.length > path.length) { diff --git a/src/vs/platform/files/test/files.test.ts b/src/vs/platform/files/test/files.test.ts index 14f4643f749..305db3647cd 100644 --- a/src/vs/platform/files/test/files.test.ts +++ b/src/vs/platform/files/test/files.test.ts @@ -7,8 +7,8 @@ import * as assert from 'assert'; import URI from 'vs/base/common/uri'; -import { join } from 'vs/base/common/paths'; -import { FileChangeType, FileChangesEvent, isEqual, isParent, isEqualOrParent, indexOf } from 'vs/platform/files/common/files'; +import { join, isEqual, isEqualOrParent } from 'vs/base/common/paths'; +import { FileChangeType, FileChangesEvent, isParent, indexOf } from 'vs/platform/files/common/files'; import { isLinux, isMacintosh, isWindows } from 'vs/base/common/platform'; suite('Files', () => { diff --git a/src/vs/platform/workspace/common/workspace.ts b/src/vs/platform/workspace/common/workspace.ts index 7733f14a34c..d4b971d9bbd 100644 --- a/src/vs/platform/workspace/common/workspace.ts +++ b/src/vs/platform/workspace/common/workspace.ts @@ -8,7 +8,6 @@ import URI from 'vs/base/common/uri'; import { createDecorator } from 'vs/platform/instantiation/common/instantiation'; import * as paths from 'vs/base/common/paths'; import { TrieMap } from 'vs/base/common/map'; -import { isEqualOrParent } from 'vs/platform/files/common/files'; import { isLinux } from 'vs/base/common/platform'; import Event from 'vs/base/common/event'; @@ -129,7 +128,7 @@ export class LegacyWorkspace implements ILegacyWorkspace { private contains(resource: URI): boolean { if (resource) { - return isEqualOrParent(resource.fsPath, this._resource.fsPath, !isLinux /* ignorecase */); + return paths.isEqualOrParent(resource.fsPath, this._resource.fsPath, !isLinux /* ignorecase */); } return false; diff --git a/src/vs/workbench/common/editor/rangeDecorations.ts b/src/vs/workbench/common/editor/rangeDecorations.ts index 70a95b14274..730062404f4 100644 --- a/src/vs/workbench/common/editor/rangeDecorations.ts +++ b/src/vs/workbench/common/editor/rangeDecorations.ts @@ -9,7 +9,7 @@ import Event, { Emitter } from 'vs/base/common/event'; import * as editorCommon from 'vs/editor/common/editorCommon'; import { IWorkbenchEditorService } from 'vs/workbench/services/editor/common/editorService'; import { toResource } from 'vs/workbench/common/editor'; -import { isEqual } from 'vs/platform/files/common/files'; +import { isEqual } from 'vs/base/common/paths'; import { IRange } from 'vs/editor/common/core/range'; import { CursorChangeReason, ICursorPositionChangedEvent } from 'vs/editor/common/controller/cursorEvents'; import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; diff --git a/src/vs/workbench/parts/files/browser/fileActions.ts b/src/vs/workbench/parts/files/browser/fileActions.ts index 378a32e3889..d66bf8e86c3 100644 --- a/src/vs/workbench/parts/files/browser/fileActions.ts +++ b/src/vs/workbench/parts/files/browser/fileActions.ts @@ -25,7 +25,7 @@ import { dispose, IDisposable } from 'vs/base/common/lifecycle'; import { VIEWLET_ID } from 'vs/workbench/parts/files/common/files'; import labels = require('vs/base/common/labels'); import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; -import { IFileService, IFileStat, isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; +import { IFileService, IFileStat } from 'vs/platform/files/common/files'; import { toResource, IEditorIdentifier, EditorInput } from 'vs/workbench/common/editor'; import { FileStat, NewStatPlaceholder } from 'vs/workbench/parts/files/common/explorerViewModel'; import { ExplorerView } from 'vs/workbench/parts/files/browser/views/explorerView'; @@ -285,7 +285,7 @@ class RenameFileAction extends BaseRenameAction { public runAction(newName: string): TPromise { - const dirty = this.textFileService.getDirty().filter(d => isEqualOrParent(d.fsPath, this.element.resource.fsPath, !isLinux /* ignorecase */)); + const dirty = this.textFileService.getDirty().filter(d => paths.isEqualOrParent(d.fsPath, this.element.resource.fsPath, !isLinux /* ignorecase */)); const dirtyRenamed: URI[] = []; return TPromise.join(dirty.map(d => { @@ -293,7 +293,7 @@ class RenameFileAction extends BaseRenameAction { let renamed: URI; // If the dirty file itself got moved, just reparent it to the target folder - if (isEqual(this.element.resource.fsPath, d.fsPath)) { + if (paths.isEqual(this.element.resource.fsPath, d.fsPath)) { renamed = URI.file(targetPath); } @@ -660,7 +660,7 @@ export class BaseDeleteFileAction extends BaseFileAction { // Handle dirty let revertPromise: TPromise = TPromise.as(null); - const dirty = this.textFileService.getDirty().filter(d => isEqualOrParent(d.fsPath, this.element.resource.fsPath, !isLinux /* ignorecase */)); + const dirty = this.textFileService.getDirty().filter(d => paths.isEqualOrParent(d.fsPath, this.element.resource.fsPath, !isLinux /* ignorecase */)); if (dirty.length) { let message: string; if (this.element.isDirectory) { @@ -955,7 +955,7 @@ export class PasteFileAction extends BaseFileAction { } // Check if target is ancestor of pasted folder - if (!isEqual(this.element.resource.fsPath, fileToCopy.resource.fsPath) && isEqualOrParent(this.element.resource.fsPath, fileToCopy.resource.fsPath, !isLinux /* ignorecase */)) { + if (!paths.isEqual(this.element.resource.fsPath, fileToCopy.resource.fsPath) && paths.isEqualOrParent(this.element.resource.fsPath, fileToCopy.resource.fsPath, !isLinux /* ignorecase */)) { return false; } diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index 37d52b0f58e..bbbae2286f2 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -17,7 +17,7 @@ import { prepareActions } from 'vs/workbench/browser/actions'; import { ITree } from 'vs/base/parts/tree/browser/tree'; import { Tree } from 'vs/base/parts/tree/browser/treeImpl'; import { IFilesConfiguration, ExplorerFolderContext, FilesExplorerFocussedContext, ExplorerFocussedContext } from 'vs/workbench/parts/files/common/files'; -import { FileOperation, FileOperationEvent, IResolveFileOptions, FileChangeType, FileChangesEvent, IFileChange, IFileService, isEqualOrParent } from 'vs/platform/files/common/files'; +import { FileOperation, FileOperationEvent, IResolveFileOptions, FileChangeType, FileChangesEvent, IFileChange, IFileService } from 'vs/platform/files/common/files'; import { RefreshViewExplorerAction, NewFolderAction, NewFileAction } from 'vs/workbench/parts/files/browser/fileActions'; import { FileDragAndDrop, FileFilter, FileSorter, FileController, FileRenderer, FileDataSource, FileViewletState, FileAccessibilityProvider } from 'vs/workbench/parts/files/browser/views/explorerViewer'; import { toResource } from 'vs/workbench/common/editor'; @@ -743,7 +743,7 @@ export class ExplorerView extends CollapsibleView { // Drop those path which are parents of the current one for (let i = resolvedDirectories.length - 1; i >= 0; i--) { const resource = resolvedDirectories[i]; - if (isEqualOrParent(stat.resource.fsPath, resource.fsPath, !isLinux /* ignorecase */)) { + if (paths.isEqualOrParent(stat.resource.fsPath, resource.fsPath, !isLinux /* ignorecase */)) { resolvedDirectories.splice(i); } } diff --git a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts index e46282959a5..da54911c078 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts @@ -25,7 +25,7 @@ import { IDisposable } from 'vs/base/common/lifecycle'; import { ContributableActionProvider } from 'vs/workbench/browser/actions'; import { IFilesConfiguration } from 'vs/workbench/parts/files/common/files'; import { ITextFileService } from 'vs/workbench/services/textfile/common/textfiles'; -import { IFileOperationResult, FileOperationResult, IFileService, isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; +import { IFileOperationResult, FileOperationResult, IFileService } from 'vs/platform/files/common/files'; import { ResourceMap } from 'vs/base/common/map'; import { DuplicateFileAction, ImportFileAction, IEditableData, IFileViewletState } from 'vs/workbench/parts/files/browser/fileActions'; import { IDataSource, ITree, IAccessibilityProvider, IRenderer, ContextMenuEvent, ISorter, IFilter, IDragAndDrop, IDragAndDropData, IDragOverReaction, DRAG_OVER_ACCEPT_BUBBLE_DOWN, DRAG_OVER_ACCEPT_BUBBLE_DOWN_COPY, DRAG_OVER_ACCEPT_BUBBLE_UP, DRAG_OVER_ACCEPT_BUBBLE_UP_COPY, DRAG_OVER_REJECT } from 'vs/base/parts/tree/browser/tree'; @@ -700,11 +700,11 @@ export class FileDragAndDrop implements IDragAndDrop { return true; // Can not move anything onto itself } - if (!isCopy && isEqual(paths.dirname(source.resource.fsPath), target.resource.fsPath)) { + if (!isCopy && paths.isEqual(paths.dirname(source.resource.fsPath), target.resource.fsPath)) { return true; // Can not move a file to the same parent unless we copy } - if (isEqualOrParent(target.resource.fsPath, source.resource.fsPath, !isLinux /* ignorecase */)) { + if (paths.isEqualOrParent(target.resource.fsPath, source.resource.fsPath, !isLinux /* ignorecase */)) { return true; // Can not move a parent folder into one of its children } @@ -766,12 +766,12 @@ export class FileDragAndDrop implements IDragAndDrop { }; // 1. check for dirty files that are being moved and backup to new target - const dirty = this.textFileService.getDirty().filter(d => isEqualOrParent(d.fsPath, source.resource.fsPath, !isLinux /* ignorecase */)); + const dirty = this.textFileService.getDirty().filter(d => paths.isEqualOrParent(d.fsPath, source.resource.fsPath, !isLinux /* ignorecase */)); return TPromise.join(dirty.map(d => { let moved: URI; // If the dirty file itself got moved, just reparent it to the target folder - if (isEqual(source.resource.fsPath, d.fsPath)) { + if (paths.isEqual(source.resource.fsPath, d.fsPath)) { moved = URI.file(paths.join(target.resource.fsPath, source.name)); } @@ -810,7 +810,7 @@ export class FileDragAndDrop implements IDragAndDrop { // Move with overwrite if the user confirms if (this.messageService.confirm(confirm)) { - const targetDirty = this.textFileService.getDirty().filter(d => isEqualOrParent(d.fsPath, targetResource.fsPath, !isLinux /* ignorecase */)); + const targetDirty = this.textFileService.getDirty().filter(d => paths.isEqualOrParent(d.fsPath, targetResource.fsPath, !isLinux /* ignorecase */)); // Make sure to revert all dirty in target first to be able to overwrite properly return this.textFileService.revertAll(targetDirty, { soft: true /* do not attempt to load content from disk */ }).then(() => { diff --git a/src/vs/workbench/parts/files/common/editors/fileEditorTracker.ts b/src/vs/workbench/parts/files/common/editors/fileEditorTracker.ts index b87ea5f7ab6..35e38eb9805 100644 --- a/src/vs/workbench/parts/files/common/editors/fileEditorTracker.ts +++ b/src/vs/workbench/parts/files/common/editors/fileEditorTracker.ts @@ -13,7 +13,7 @@ import { IEditor, IEditorViewState, isCommonCodeEditor } from 'vs/editor/common/ import { toResource, IEditorStacksModel, SideBySideEditorInput, IEditorGroup, IWorkbenchEditorConfiguration } from 'vs/workbench/common/editor'; import { BINARY_FILE_EDITOR_ID } from 'vs/workbench/parts/files/common/files'; import { ITextFileService, ITextFileEditorModel } from 'vs/workbench/services/textfile/common/textfiles'; -import { FileOperationEvent, FileOperation, IFileService, FileChangeType, FileChangesEvent, isEqual, indexOf, isEqualOrParent } from 'vs/platform/files/common/files'; +import { FileOperationEvent, FileOperation, IFileService, FileChangeType, FileChangesEvent, indexOf } from 'vs/platform/files/common/files'; import { FileEditorInput } from 'vs/workbench/parts/files/common/editors/fileEditorInput'; import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService'; import { ILifecycleService } from 'vs/platform/lifecycle/common/lifecycle'; @@ -115,7 +115,7 @@ export class FileEditorTracker implements IWorkbenchContribution { // Do NOT close any opened editor that matches the resource path (either equal or being parent) of the // resource we move to (movedTo). Otherwise we would close a resource that has been renamed to the same // path but different casing. - if (movedTo && isEqualOrParent(resource.fsPath, movedTo.fsPath, !isLinux /* ignorecase */) && resource.fsPath.indexOf(movedTo.fsPath) === 0) { + if (movedTo && paths.isEqualOrParent(resource.fsPath, movedTo.fsPath, !isLinux /* ignorecase */) && resource.fsPath.indexOf(movedTo.fsPath) === 0) { return; } @@ -123,7 +123,7 @@ export class FileEditorTracker implements IWorkbenchContribution { if (arg1 instanceof FileChangesEvent) { matches = arg1.contains(resource, FileChangeType.DELETED); } else { - matches = isEqualOrParent(resource.fsPath, arg1.fsPath, !isLinux /* ignorecase */); + matches = paths.isEqualOrParent(resource.fsPath, arg1.fsPath, !isLinux /* ignorecase */); } if (!matches) { @@ -195,7 +195,7 @@ export class FileEditorTracker implements IWorkbenchContribution { const resource = input.getResource(); // Update Editor if file (or any parent of the input) got renamed or moved - if (isEqualOrParent(resource.fsPath, oldResource.fsPath, !isLinux /* ignorecase */)) { + if (paths.isEqualOrParent(resource.fsPath, oldResource.fsPath, !isLinux /* ignorecase */)) { let reopenFileResource: URI; if (oldResource.toString() === resource.toString()) { reopenFileResource = newResource; // file got moved @@ -229,7 +229,7 @@ export class FileEditorTracker implements IWorkbenchContribution { const editor = editors[i]; if (editor && editor.position === stacks.positionOfGroup(group)) { const resource = toResource(editor.input, { filter: 'file' }); - if (resource && isEqual(resource.fsPath, resource.fsPath)) { + if (resource && paths.isEqual(resource.fsPath, resource.fsPath)) { const control = editor.getControl(); if (isCommonCodeEditor(control)) { return control.saveViewState(); diff --git a/src/vs/workbench/parts/files/common/explorerViewModel.ts b/src/vs/workbench/parts/files/common/explorerViewModel.ts index f7463ababd9..e8fb2b614c8 100644 --- a/src/vs/workbench/parts/files/common/explorerViewModel.ts +++ b/src/vs/workbench/parts/files/common/explorerViewModel.ts @@ -7,7 +7,7 @@ import URI from 'vs/base/common/uri'; import paths = require('vs/base/common/paths'); -import { IFileStat, isEqual, isParent, isEqualOrParent } from 'vs/platform/files/common/files'; +import { IFileStat, isParent } from 'vs/platform/files/common/files'; import { IEditorInput } from 'vs/platform/editor/common/editor'; import { IEditorGroup, toResource } from 'vs/workbench/common/editor'; import { ResourceMap } from 'vs/base/common/map'; @@ -61,7 +61,7 @@ export class FileStat implements IFileStat { // the folder is fully resolved if either it has a list of children or the client requested this by using the resolveTo // array of resource path to resolve. stat.isDirectoryResolved = !!raw.children || (!!resolveTo && resolveTo.some((r) => { - return isEqualOrParent(r.fsPath, stat.resource.fsPath, !isLinux /* ignorecase */); + return paths.isEqualOrParent(r.fsPath, stat.resource.fsPath, !isLinux /* ignorecase */); })); // Recurse into children @@ -241,7 +241,7 @@ export class FileStat implements IFileStat { public find(resource: URI): FileStat { // Return if path found - if (isEqual(resource.fsPath, this.resource.fsPath, !isLinux /* ignorecase */)) { + if (paths.isEqual(resource.fsPath, this.resource.fsPath, !isLinux /* ignorecase */)) { return this; } @@ -253,7 +253,7 @@ export class FileStat implements IFileStat { for (let i = 0; i < this.children.length; i++) { const child = this.children[i]; - if (isEqual(resource.fsPath, child.resource.fsPath, !isLinux /* ignorecase */)) { + if (paths.isEqual(resource.fsPath, child.resource.fsPath, !isLinux /* ignorecase */)) { return child; } diff --git a/src/vs/workbench/parts/search/browser/searchActions.ts b/src/vs/workbench/parts/search/browser/searchActions.ts index 46e865e5b8a..256f1ec1a2d 100644 --- a/src/vs/workbench/parts/search/browser/searchActions.ts +++ b/src/vs/workbench/parts/search/browser/searchActions.ts @@ -29,7 +29,6 @@ import { ServicesAccessor, IInstantiationService } from 'vs/platform/instantiati import { IListService } from 'vs/platform/list/browser/listService'; import { explorerItemToFileResource } from 'vs/workbench/parts/files/common/files'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; -import { isEqual } from 'vs/platform/files/common/files'; import { OS } from 'vs/base/common/platform'; export function isSearchViewletFocussed(viewletService: IViewletService): boolean { @@ -525,7 +524,7 @@ export class ReplaceAction extends AbstractSearchAndReplaceAction { private hasToOpenFile(): boolean { const file = toResource(this.editorService.getActiveEditorInput(), { filter: 'file' }); if (file) { - return isEqual(file.fsPath, this.element.parent().resource().fsPath); + return paths.isEqual(file.fsPath, this.element.parent().resource().fsPath); } return false; } diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index 6da212e044e..8f299b58732 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -19,7 +19,7 @@ import { RunOnceScheduler } from 'vs/base/common/async'; import { readFile } from 'vs/base/node/pfs'; import * as extfs from 'vs/base/node/extfs'; import { IWorkspaceContextService, IWorkspace, Workspace, ILegacyWorkspace, LegacyWorkspace } from "vs/platform/workspace/common/workspace"; -import { FileChangeType, FileChangesEvent, isEqual, isEqualOrParent } from 'vs/platform/files/common/files'; +import { FileChangeType, FileChangesEvent } from 'vs/platform/files/common/files'; import { isLinux } from 'vs/base/common/platform'; import { IEnvironmentService } from 'vs/platform/environment/common/environment'; import { CustomConfigurationModel } from 'vs/platform/configuration/common/model'; @@ -339,7 +339,7 @@ class FolderConfiguration extends Disposable { for (let i = 0, len = events.length; i < len; i++) { const resource = events[i].resource; const isJson = paths.extname(resource.fsPath) === '.json'; - const isDeletedSettingsFolder = (events[i].type === FileChangeType.DELETED && isEqual(paths.basename(resource.fsPath), this.configFolderRelativePath)); + const isDeletedSettingsFolder = (events[i].type === FileChangeType.DELETED && paths.isEqual(paths.basename(resource.fsPath), this.configFolderRelativePath)); if (!isJson && !isDeletedSettingsFolder) { continue; // only JSON files or the actual settings folder } @@ -425,7 +425,7 @@ class FolderConfiguration extends Disposable { private contains(resource: URI): boolean { if (resource) { - return isEqualOrParent(resource.fsPath, this.folder.fsPath, !isLinux /* ignorecase */); + return paths.isEqualOrParent(resource.fsPath, this.folder.fsPath, !isLinux /* ignorecase */); } return false; diff --git a/src/vs/workbench/services/files/node/fileService.ts b/src/vs/workbench/services/files/node/fileService.ts index a00926d40bb..11154b8e8c4 100644 --- a/src/vs/workbench/services/files/node/fileService.ts +++ b/src/vs/workbench/services/files/node/fileService.ts @@ -11,8 +11,9 @@ import os = require('os'); import crypto = require('crypto'); import assert = require('assert'); -import { isParent, FileOperation, FileOperationEvent, IContent, IFileService, IResolveFileOptions, IResolveContentOptions, IFileStat, IStreamContent, IFileOperationResult, FileOperationResult, IUpdateContentOptions, FileChangeType, IImportResult, MAX_FILE_SIZE, FileChangesEvent, isEqualOrParent } from 'vs/platform/files/common/files'; +import { isParent, FileOperation, FileOperationEvent, IContent, IFileService, IResolveFileOptions, IResolveContentOptions, IFileStat, IStreamContent, IFileOperationResult, FileOperationResult, IUpdateContentOptions, FileChangeType, IImportResult, MAX_FILE_SIZE, FileChangesEvent } from 'vs/platform/files/common/files'; import strings = require('vs/base/common/strings'); +import { isEqualOrParent } from 'vs/base/common/paths'; import { ResourceMap } from 'vs/base/common/map'; import arrays = require('vs/base/common/arrays'); import baseMime = require('vs/base/common/mime'); diff --git a/src/vs/workbench/services/textfile/common/textFileEditorModel.ts b/src/vs/workbench/services/textfile/common/textFileEditorModel.ts index d200639a975..126ce625264 100644 --- a/src/vs/workbench/services/textfile/common/textFileEditorModel.ts +++ b/src/vs/workbench/services/textfile/common/textFileEditorModel.ts @@ -24,7 +24,7 @@ import { ITextFileService, IAutoSaveConfiguration, ModelState, ITextFileEditorMo import { EncodingMode } from 'vs/workbench/common/editor'; import { BaseTextEditorModel } from 'vs/workbench/common/editor/textEditorModel'; import { IBackupFileService, BACKUP_FILE_RESOLVE_OPTIONS } from 'vs/workbench/services/backup/common/backup'; -import { IFileService, IFileStat, IFileOperationResult, FileOperationResult, IContent, CONTENT_CHANGE_EVENT_BUFFER_DELAY, FileChangesEvent, FileChangeType, isEqualOrParent } from 'vs/platform/files/common/files'; +import { IFileService, IFileStat, IFileOperationResult, FileOperationResult, IContent, CONTENT_CHANGE_EVENT_BUFFER_DELAY, FileChangesEvent, FileChangeType } from 'vs/platform/files/common/files'; import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation'; import { IMessageService, Severity } from 'vs/platform/message/common/message'; import { IModeService } from 'vs/editor/common/services/modeService'; @@ -669,7 +669,7 @@ export class TextFileEditorModel extends BaseTextEditorModel implements ITextFil diag(`doSave(${versionId}) - after updateContent()`, this.resource, new Date()); // Telemetry - if ((this.contextService.hasWorkspace() && isEqualOrParent(this.resource.fsPath, this.contextService.toResource('.vscode').fsPath)) || + if ((this.contextService.hasWorkspace() && paths.isEqualOrParent(this.resource.fsPath, this.contextService.toResource('.vscode').fsPath)) || this.resource.fsPath === this.environmentService.appSettingsPath) { // Do not log write to user settings.json and .vscode folder as a filePUT event as it ruins our JSON usage data this.telemetryService.publicLog('settingsWritten'); diff --git a/src/vs/workbench/test/workbenchTestServices.ts b/src/vs/workbench/test/workbenchTestServices.ts index cff7f145626..d4cb1601f7b 100644 --- a/src/vs/workbench/test/workbenchTestServices.ts +++ b/src/vs/workbench/test/workbenchTestServices.ts @@ -34,7 +34,7 @@ import { ServiceCollection } from 'vs/platform/instantiation/common/serviceColle import { InstantiationService } from 'vs/platform/instantiation/common/instantiationService'; import { IEditorGroupService, GroupArrangement, GroupOrientation, ITabOptions, IMoveOptions } from 'vs/workbench/services/group/common/groupService'; import { TextFileService } from 'vs/workbench/services/textfile/common/textFileService'; -import { FileOperationEvent, IFileService, IResolveContentOptions, IFileOperationResult, IFileStat, IImportResult, FileChangesEvent, IResolveFileOptions, IContent, IUpdateContentOptions, IStreamContent, isEqualOrParent } from 'vs/platform/files/common/files'; +import { FileOperationEvent, IFileService, IResolveContentOptions, IFileOperationResult, IFileStat, IImportResult, FileChangesEvent, IResolveFileOptions, IContent, IUpdateContentOptions, IStreamContent } from 'vs/platform/files/common/files'; import { IModelService } from 'vs/editor/common/services/modelService'; import { ModeServiceImpl } from 'vs/editor/common/services/modeServiceImpl'; import { ModelServiceImpl } from 'vs/editor/common/services/modelServiceImpl'; @@ -115,7 +115,7 @@ export class TestContextService implements IWorkspaceContextService { public isInsideWorkspace(resource: URI): boolean { if (resource && this.workspace) { - return isEqualOrParent(resource.fsPath, this.workspace.resource.fsPath, !isLinux /* ignorecase */); + return paths.isEqualOrParent(resource.fsPath, this.workspace.resource.fsPath, !isLinux /* ignorecase */); } return false; -- GitLab From 30972ec993923c0d23f179f6223c039440623a1c Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 16 Jun 2017 12:27:50 +0200 Subject: [PATCH 0948/1347] Remove unused code --- src/vs/base/common/errorMessage.ts | 9 ++++- src/vs/base/common/http.ts | 54 ------------------------------ 2 files changed, 8 insertions(+), 55 deletions(-) delete mode 100644 src/vs/base/common/http.ts diff --git a/src/vs/base/common/errorMessage.ts b/src/vs/base/common/errorMessage.ts index 3c882cba229..1f587120c5e 100644 --- a/src/vs/base/common/errorMessage.ts +++ b/src/vs/base/common/errorMessage.ts @@ -9,7 +9,14 @@ import objects = require('vs/base/common/objects'); import types = require('vs/base/common/types'); import arrays = require('vs/base/common/arrays'); import strings = require('vs/base/common/strings'); -import { IXHRResponse } from 'vs/base/common/http'; + +export interface IXHRResponse { + responseText: string; + status: number; + + readyState: number; + getResponseHeader: (header: string) => string; +} export interface IConnectionErrorData { status: number; diff --git a/src/vs/base/common/http.ts b/src/vs/base/common/http.ts deleted file mode 100644 index 59feccf6e04..00000000000 --- a/src/vs/base/common/http.ts +++ /dev/null @@ -1,54 +0,0 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ -'use strict'; - -import * as nls from 'vs/nls'; - -export interface IXHROptions { - type?: string; - url?: string; - user?: string; - password?: string; - responseType?: string; - headers?: any; - timeout?: number; - followRedirects?: number; - data?: any; -} - -export interface IXHRResponse { - responseText: string; - status: number; - - readyState: number; - getResponseHeader: (header: string) => string; -} - -export function getErrorStatusDescription(status: number): string { - if (status < 400) { - return void 0; - } - switch (status) { - case 400: return nls.localize('status.400', 'Bad request. The request cannot be fulfilled due to bad syntax.'); - case 401: return nls.localize('status.401', 'Unauthorized. The server is refusing to respond.'); - case 403: return nls.localize('status.403', 'Forbidden. The server is refusing to respond.'); - case 404: return nls.localize('status.404', 'Not Found. The requested location could not be found.'); - case 405: return nls.localize('status.405', 'Method not allowed. A request was made using a request method not supported by that location.'); - case 406: return nls.localize('status.406', 'Not Acceptable. The server can only generate a response that is not accepted by the client.'); - case 407: return nls.localize('status.407', 'Proxy Authentication Required. The client must first authenticate itself with the proxy.'); - case 408: return nls.localize('status.408', 'Request Timeout. The server timed out waiting for the request.'); - case 409: return nls.localize('status.409', 'Conflict. The request could not be completed because of a conflict in the request.'); - case 410: return nls.localize('status.410', 'Gone. The requested page is no longer available.'); - case 411: return nls.localize('status.411', 'Length Required. The "Content-Length" is not defined.'); - case 412: return nls.localize('status.412', 'Precondition Failed. The precondition given in the request evaluated to false by the server.'); - case 413: return nls.localize('status.413', 'Request Entity Too Large. The server will not accept the request, because the request entity is too large.'); - case 414: return nls.localize('status.414', 'Request-URI Too Long. The server will not accept the request, because the URL is too long.'); - case 415: return nls.localize('status.415', 'Unsupported Media Type. The server will not accept the request, because the media type is not supported.'); - case 500: return nls.localize('status.500', 'Internal Server Error.'); - case 501: return nls.localize('status.501', 'Not Implemented. The server either does not recognize the request method, or it lacks the ability to fulfill the request.'); - case 503: return nls.localize('status.503', 'Service Unavailable. The server is currently unavailable (overloaded or down).'); - default: return nls.localize('status.416', 'HTTP status code {0}', status); - } -} -- GitLab From 2f7da22b04b6b6e4ac1ed455f6a421c1fc2c05d0 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 16 Jun 2017 12:28:38 +0200 Subject: [PATCH 0949/1347] Remove unnecessary import --- src/vs/editor/contrib/hover/browser/modesContentHover.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/src/vs/editor/contrib/hover/browser/modesContentHover.ts b/src/vs/editor/contrib/hover/browser/modesContentHover.ts index 0814b278789..ff8f4d98be7 100644 --- a/src/vs/editor/contrib/hover/browser/modesContentHover.ts +++ b/src/vs/editor/contrib/hover/browser/modesContentHover.ts @@ -4,7 +4,6 @@ *--------------------------------------------------------------------------------------------*/ 'use strict'; -import 'vs/css!vs/base/browser/ui/progressbar/progressbar'; import * as nls from 'vs/nls'; import URI from 'vs/base/common/uri'; import { onUnexpectedError } from 'vs/base/common/errors'; -- GitLab From 0287c3cb40e4e8304f4c791cb2ef7a14a4630f4b Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 16 Jun 2017 12:29:28 +0200 Subject: [PATCH 0950/1347] Better TS Lint import enforcement rules for vs/base and vs/editor/contrib --- tslint.json | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/tslint.json b/tslint.json index 84c20b3d478..5f48c5e2439 100644 --- a/tslint.json +++ b/tslint.json @@ -46,6 +46,23 @@ ], "import-patterns": [ true, + { + "target": "**/vs/base/common/**", + "restrictions": [ + "vs/nls", + "**/vs/base/common/**" + ] + }, + { + "target": "**/vs/editor/contrib/**", + "restrictions": [ + "**/vs/css!./**/*", + "**/vs/nls", + "**/vs/{base,platform}/**/{common,browser}/**", + "**/vs/editor/**", + "assert" + ] + }, { "target": "**/{node,electron-browser,electron-main,extensions}/**", "restrictions": "**/*" -- GitLab From 05f96d11819cb3d39872381d1315801b7f162b14 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Fri, 16 Jun 2017 12:45:54 +0200 Subject: [PATCH 0951/1347] #28538 Initialize all folder configurations at once --- .../workbench/services/configuration/node/configuration.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/services/configuration/node/configuration.ts b/src/vs/workbench/services/configuration/node/configuration.ts index 8f299b58732..7aa393fc2ac 100644 --- a/src/vs/workbench/services/configuration/node/configuration.ts +++ b/src/vs/workbench/services/configuration/node/configuration.ts @@ -243,6 +243,7 @@ export class WorkspaceConfigurationService extends Disposable implements IWorksp private initCachesForFolders(folders: URI[]): void { for (const folder of folders) { this.cachedFolderConfigs.set(folder, new FolderConfiguration(folder, this.workspaceSettingsRootFolder, this.workspace)); + this._configuration.updateFolderConfiguration(folder, new FolderConfigurationModel(new FolderSettingsModel(null), []), false); } } @@ -484,11 +485,11 @@ class Configuration extends BaseConfiguration { return !this.equals(current); } - updateFolderConfiguration(resource: URI, configuration: FolderConfigurationModel): boolean { + updateFolderConfiguration(resource: URI, configuration: FolderConfigurationModel, compare: boolean = true): boolean { this.folders.set(resource, configuration); const current = this.getValue(null, { resource }); this.mergeFolder(resource); - return !objects.equals(current, this.getValue(null, { resource })); + return compare && !objects.equals(current, this.getValue(null, { resource })); } deleteFolderConfiguration(folder: URI): boolean { -- GitLab From c1b48cb26810d78b6375040c8e18470e5171d964 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 16 Jun 2017 12:53:55 +0200 Subject: [PATCH 0952/1347] Fix and enforce layering rules in vs/base/browser --- .../ui/keybindingLabel/keybindingLabel.ts | 2 +- .../common/keybindingLabels.ts | 0 src/vs/base/node/startupTimers.d.ts | 2 +- .../browser/ui/list}/rangeMap.test.ts | 2 +- .../common/usLayoutResolvedKeybinding.ts | 2 +- .../common/keybindingsEditorModel.ts | 2 +- .../electron-browser/walkThroughPart.ts | 2 +- .../common/macLinuxKeyboardMapper.ts | 2 +- .../common/windowsKeyboardMapper.ts | 2 +- .../test/macLinuxKeyboardMapper.test.ts | 2 +- tslint.json | 22 ++++++++++++++++--- 11 files changed, 28 insertions(+), 12 deletions(-) rename src/vs/{platform/keybinding => base}/common/keybindingLabels.ts (100%) rename src/vs/base/{browser/ui/list/test => test/browser/ui/list}/rangeMap.test.ts (99%) diff --git a/src/vs/base/browser/ui/keybindingLabel/keybindingLabel.ts b/src/vs/base/browser/ui/keybindingLabel/keybindingLabel.ts index cee68a0de3a..f59b0385811 100644 --- a/src/vs/base/browser/ui/keybindingLabel/keybindingLabel.ts +++ b/src/vs/base/browser/ui/keybindingLabel/keybindingLabel.ts @@ -9,7 +9,7 @@ import { IDisposable } from 'vs/base/common/lifecycle'; import { equals } from 'vs/base/common/objects'; import { OperatingSystem } from 'vs/base/common/platform'; import { ResolvedKeybinding, ResolvedKeybindingPart } from 'vs/base/common/keyCodes'; -import { UILabelProvider } from 'vs/platform/keybinding/common/keybindingLabels'; +import { UILabelProvider } from 'vs/base/common/keybindingLabels'; import * as dom from 'vs/base/browser/dom'; const $ = dom.$; diff --git a/src/vs/platform/keybinding/common/keybindingLabels.ts b/src/vs/base/common/keybindingLabels.ts similarity index 100% rename from src/vs/platform/keybinding/common/keybindingLabels.ts rename to src/vs/base/common/keybindingLabels.ts diff --git a/src/vs/base/node/startupTimers.d.ts b/src/vs/base/node/startupTimers.d.ts index 5a04270f4b6..2fae1f8eab1 100644 --- a/src/vs/base/node/startupTimers.d.ts +++ b/src/vs/base/node/startupTimers.d.ts @@ -3,7 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -import { Profile } from './profiler' +import { Profile } from './profiler'; declare interface TickStart { name: string; diff --git a/src/vs/base/browser/ui/list/test/rangeMap.test.ts b/src/vs/base/test/browser/ui/list/rangeMap.test.ts similarity index 99% rename from src/vs/base/browser/ui/list/test/rangeMap.test.ts rename to src/vs/base/test/browser/ui/list/rangeMap.test.ts index 0ad8b350bef..e5121fd5106 100644 --- a/src/vs/base/browser/ui/list/test/rangeMap.test.ts +++ b/src/vs/base/test/browser/ui/list/rangeMap.test.ts @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ import assert = require('assert'); -import { RangeMap, intersect, groupIntersect, consolidate } from '../rangeMap'; +import { RangeMap, intersect, groupIntersect, consolidate } from 'vs/base/browser/ui/list/rangeMap'; suite('RangeMap', () => { var rangeMap: RangeMap; diff --git a/src/vs/platform/keybinding/common/usLayoutResolvedKeybinding.ts b/src/vs/platform/keybinding/common/usLayoutResolvedKeybinding.ts index 08d67882828..78861625e1a 100644 --- a/src/vs/platform/keybinding/common/usLayoutResolvedKeybinding.ts +++ b/src/vs/platform/keybinding/common/usLayoutResolvedKeybinding.ts @@ -5,7 +5,7 @@ 'use strict'; import { ResolvedKeybinding, ResolvedKeybindingPart, KeyCode, KeyCodeUtils, Keybinding, KeybindingType, SimpleKeybinding } from 'vs/base/common/keyCodes'; -import { UILabelProvider, AriaLabelProvider, ElectronAcceleratorLabelProvider, UserSettingsLabelProvider } from 'vs/platform/keybinding/common/keybindingLabels'; +import { UILabelProvider, AriaLabelProvider, ElectronAcceleratorLabelProvider, UserSettingsLabelProvider } from 'vs/base/common/keybindingLabels'; import { OperatingSystem } from 'vs/base/common/platform'; /** diff --git a/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.ts b/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.ts index cce68a1ae07..d9ab87baa3e 100644 --- a/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.ts +++ b/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.ts @@ -11,7 +11,7 @@ import { OperatingSystem, language, LANGUAGE_DEFAULT } from 'vs/base/common/plat import { IMatch, IFilter, or, matchesContiguousSubString, matchesPrefix, matchesCamelCase, matchesWords } from 'vs/base/common/filters'; import { Registry } from 'vs/platform/platform'; import { ResolvedKeybinding, ResolvedKeybindingPart } from 'vs/base/common/keyCodes'; -import { AriaLabelProvider, UserSettingsLabelProvider, UILabelProvider, ModifierLabels as ModLabels } from 'vs/platform/keybinding/common/keybindingLabels'; +import { AriaLabelProvider, UserSettingsLabelProvider, UILabelProvider, ModifierLabels as ModLabels } from 'vs/base/common/keybindingLabels'; import { CommonEditorRegistry, EditorAction } from 'vs/editor/common/editorCommonExtensions'; import { MenuRegistry, ILocalizedString, SyncActionDescriptor, ICommandAction } from 'vs/platform/actions/common/actions'; import { IWorkbenchActionRegistry, Extensions as ActionExtensions } from 'vs/workbench/common/actionRegistry'; diff --git a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts index ac247b050eb..5bbbccb4d93 100644 --- a/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts +++ b/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.ts @@ -40,7 +40,7 @@ import { IMessageService, Severity } from 'vs/platform/message/common/message'; import { IThemeService, registerThemingParticipant } from 'vs/platform/theme/common/themeService'; import { registerColor, focusBorder, textLinkForeground, textLinkActiveForeground, textPreformatForeground, contrastBorder, textBlockQuoteBackground, textBlockQuoteBorder } from 'vs/platform/theme/common/colorRegistry'; import { getExtraColor } from 'vs/workbench/parts/welcome/walkThrough/node/walkThroughUtils'; -import { UILabelProvider } from 'vs/platform/keybinding/common/keybindingLabels'; +import { UILabelProvider } from 'vs/base/common/keybindingLabels'; import { OS, OperatingSystem } from 'vs/base/common/platform'; export const WALK_THROUGH_FOCUS = new RawContextKey('interactivePlaygroundFocus', false); diff --git a/src/vs/workbench/services/keybinding/common/macLinuxKeyboardMapper.ts b/src/vs/workbench/services/keybinding/common/macLinuxKeyboardMapper.ts index bf911f28c13..a7790298f37 100644 --- a/src/vs/workbench/services/keybinding/common/macLinuxKeyboardMapper.ts +++ b/src/vs/workbench/services/keybinding/common/macLinuxKeyboardMapper.ts @@ -9,7 +9,7 @@ import { OperatingSystem } from 'vs/base/common/platform'; import { KeyCode, ResolvedKeybinding, KeyCodeUtils, SimpleKeybinding, Keybinding, KeybindingType, ResolvedKeybindingPart } from 'vs/base/common/keyCodes'; import { ScanCode, ScanCodeUtils, IMMUTABLE_CODE_TO_KEY_CODE, IMMUTABLE_KEY_CODE_TO_CODE, ScanCodeBinding } from 'vs/workbench/services/keybinding/common/scanCode'; import { CharCode } from 'vs/base/common/charCode'; -import { UILabelProvider, AriaLabelProvider, UserSettingsLabelProvider, ElectronAcceleratorLabelProvider } from 'vs/platform/keybinding/common/keybindingLabels'; +import { UILabelProvider, AriaLabelProvider, UserSettingsLabelProvider, ElectronAcceleratorLabelProvider } from 'vs/base/common/keybindingLabels'; import { IKeyboardMapper } from 'vs/workbench/services/keybinding/common/keyboardMapper'; import { IKeyboardEvent } from 'vs/platform/keybinding/common/keybinding'; diff --git a/src/vs/workbench/services/keybinding/common/windowsKeyboardMapper.ts b/src/vs/workbench/services/keybinding/common/windowsKeyboardMapper.ts index 1eeb5b682b5..02c1dac816c 100644 --- a/src/vs/workbench/services/keybinding/common/windowsKeyboardMapper.ts +++ b/src/vs/workbench/services/keybinding/common/windowsKeyboardMapper.ts @@ -8,7 +8,7 @@ import { KeyCode, KeyCodeUtils, ResolvedKeybinding, Keybinding, SimpleKeybinding, KeybindingType, ResolvedKeybindingPart } from 'vs/base/common/keyCodes'; import { ScanCode, ScanCodeUtils, IMMUTABLE_CODE_TO_KEY_CODE, ScanCodeBinding } from 'vs/workbench/services/keybinding/common/scanCode'; import { CharCode } from 'vs/base/common/charCode'; -import { UILabelProvider, AriaLabelProvider, ElectronAcceleratorLabelProvider, UserSettingsLabelProvider } from 'vs/platform/keybinding/common/keybindingLabels'; +import { UILabelProvider, AriaLabelProvider, ElectronAcceleratorLabelProvider, UserSettingsLabelProvider } from 'vs/base/common/keybindingLabels'; import { OperatingSystem } from 'vs/base/common/platform'; import { IKeyboardMapper } from 'vs/workbench/services/keybinding/common/keyboardMapper'; import { IKeyboardEvent } from 'vs/platform/keybinding/common/keybinding'; diff --git a/src/vs/workbench/services/keybinding/test/macLinuxKeyboardMapper.test.ts b/src/vs/workbench/services/keybinding/test/macLinuxKeyboardMapper.test.ts index f168b02ef2f..cc84bdadcce 100644 --- a/src/vs/workbench/services/keybinding/test/macLinuxKeyboardMapper.test.ts +++ b/src/vs/workbench/services/keybinding/test/macLinuxKeyboardMapper.test.ts @@ -9,7 +9,7 @@ import * as assert from 'assert'; import { KeyMod, KeyCode, createKeybinding, SimpleKeybinding, KeyChord } from 'vs/base/common/keyCodes'; import { MacLinuxKeyboardMapper, IMacLinuxKeyboardMapping } from 'vs/workbench/services/keybinding/common/macLinuxKeyboardMapper'; import { OperatingSystem } from 'vs/base/common/platform'; -import { UserSettingsLabelProvider } from 'vs/platform/keybinding/common/keybindingLabels'; +import { UserSettingsLabelProvider } from 'vs/base/common/keybindingLabels'; import { USLayoutResolvedKeybinding } from 'vs/platform/keybinding/common/usLayoutResolvedKeybinding'; import { ScanCodeUtils, ScanCodeBinding, ScanCode } from 'vs/workbench/services/keybinding/common/scanCode'; import { TPromise } from 'vs/base/common/winjs.base'; diff --git a/tslint.json b/tslint.json index 5f48c5e2439..3cb9ec3a3e3 100644 --- a/tslint.json +++ b/tslint.json @@ -46,19 +46,35 @@ ], "import-patterns": [ true, + // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + // !!! Do not relax these rules !!! + // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! { + // vs/base/common cannot depend on anything else "target": "**/vs/base/common/**", "restrictions": [ "vs/nls", "**/vs/base/common/**" ] }, + { + // vs/base/browser can only depend on vs/base/common + "target": "**/vs/base/browser/**", + "restrictions": [ + "vs/nls", + "vs/css!./**/*", + "**/vs/base/common/**", + "**/vs/base/browser/**" + ] + }, { "target": "**/vs/editor/contrib/**", "restrictions": [ - "**/vs/css!./**/*", - "**/vs/nls", - "**/vs/{base,platform}/**/{common,browser}/**", + "vs/nls", + "vs/css!./**/*", + "**/vs/base/{common,browser}/**", + "**/vs/base/parts/{tree,quickopen}/{common,browser}/**", + "**/vs/platform/**/{common,browser}/**", "**/vs/editor/**", "assert" ] -- GitLab From 49d5cc6e4398491e33ad81d87b2c8cd4b2f56d85 Mon Sep 17 00:00:00 2001 From: Dirk Baeumer Date: Fri, 16 Jun 2017 13:01:58 +0200 Subject: [PATCH 0953/1347] Remove 'terminal' as a used term from tasks. --- src/vs/base/common/map.ts | 8 +- src/vs/vscode.proposed.d.ts | 35 ++++--- src/vs/workbench/api/node/extHost.api.impl.ts | 2 +- src/vs/workbench/api/node/extHostTask.ts | 28 +++--- src/vs/workbench/api/node/extHostTypes.ts | 16 +-- .../parts/tasks/browser/buildQuickOpen.ts | 2 +- .../parts/tasks/browser/taskQuickOpen.ts | 2 +- .../parts/tasks/browser/testQuickOpen.ts | 2 +- .../parts/tasks/common/taskConfiguration.ts | 98 +++++++++++-------- src/vs/workbench/parts/tasks/common/tasks.ts | 43 ++++---- .../tasks/electron-browser/jsonSchema_v2.ts | 22 ++++- .../electron-browser/terminalTaskSystem.ts | 89 +++++++++-------- .../parts/tasks/node/processTaskSystem.ts | 4 +- .../tasks/test/node/configuration.test.ts | 52 +++++----- 14 files changed, 224 insertions(+), 179 deletions(-) diff --git a/src/vs/base/common/map.ts b/src/vs/base/common/map.ts index 9b5804ee96f..55ad91bee3e 100644 --- a/src/vs/base/common/map.ts +++ b/src/vs/base/common/map.ts @@ -485,14 +485,18 @@ export class LinkedMap { } public delete(key: K): boolean { + return !!this.remove(key); + } + + public remove(key: K): V | undefined { const item = this._map.get(key); if (!item) { - return false; + return undefined; } this._map.delete(key); this.removeItem(item); this._size--; - return true; + return item.value; } public shift(): V | undefined { diff --git a/src/vs/vscode.proposed.d.ts b/src/vs/vscode.proposed.d.ts index 29bde57d318..fecdcb110fc 100644 --- a/src/vs/vscode.proposed.d.ts +++ b/src/vs/vscode.proposed.d.ts @@ -31,49 +31,52 @@ declare module 'vscode' { /** * Controls how the task channel is used between tasks */ - export enum TaskInstanceKind { + export enum TaskPanelKind { /** - * Shares a channel with other tasks. This is the default. + * Shares a panel with other tasks. This is the default. */ Shared = 1, /** - * Uses the same task channel for every run if possible. The task channel is not + * Uses a dedicated panel for this tasks. The panel is not * shared with other tasks. */ - Same = 2, + Dedicated = 2, /** - * Creates a new task channel whenever that task is executed + * Creates a new panel whenever this task is executed. */ New = 3 } /** - * Controls terminal specific behavior. + * Controls how the task is presented in the UI. */ - export interface TaskTerminalBehavior { + export interface TaskPresentationOptions { /** - * Controls whether the terminal executing a task is brought to front or not. + * Controls whether the task output is reveal in the user interface. * Defaults to `RevealKind.Always`. */ reveal?: TaskRevealKind; /** - * Controls whether the command is echoed in the terminal or not. + * Controls whether the command associated with the task is echoed + * in the user interface. */ echo?: boolean; /** - * Controls whether the task pane takes focus when the task is executed + * Controls whether the panel showing the task output is taking focus. */ focus?: boolean; /** - * Controls in which pane the task is executed. + * Controls if the task panel is used for this task only (dedicated), + * shared between tasks (shared) or if a new panel is created on + * every task execution (new). Defaults to `TaskInstanceKind.Shared` */ - instance?: TaskInstanceKind; + panel?: TaskPanelKind; } export interface ProcessTaskOptions { @@ -200,9 +203,9 @@ declare module 'vscode' { options: ProcessTaskOptions; /** - * The terminal behavior. Defaults to an empty object literal. + * The presentation options. Defaults to an empty literal. */ - terminalBehavior: TaskTerminalBehavior; + presentationOptions: TaskPresentationOptions; /** * The problem matchers attached to the task. Defaults to an empty @@ -332,9 +335,9 @@ declare module 'vscode' { options: ShellTaskOptions; /** - * The terminal behavior. Defaults to an empty object literal. + * The presentation options. Defaults to an empty literal. */ - terminalBehavior: TaskTerminalBehavior; + presentationOptions: TaskPresentationOptions; /** * The problem matchers attached to the task. Defaults to an empty diff --git a/src/vs/workbench/api/node/extHost.api.impl.ts b/src/vs/workbench/api/node/extHost.api.impl.ts index 7c4e72c853d..fbaaaaa5897 100644 --- a/src/vs/workbench/api/node/extHost.api.impl.ts +++ b/src/vs/workbench/api/node/extHost.api.impl.ts @@ -489,7 +489,7 @@ export function createApiFactory( ThemeColor: extHostTypes.ThemeColor, // functions TaskRevealKind: extHostTypes.TaskRevealKind, - TaskInstanceKind: extHostTypes.TaskInstanceKind, + TaskPanelKind: extHostTypes.TaskPanelKind, TaskGroup: extHostTypes.TaskGroup, ShellTask: extHostTypes.ShellTask, ProcessTask: extHostTypes.ProcessTask diff --git a/src/vs/workbench/api/node/extHostTask.ts b/src/vs/workbench/api/node/extHostTask.ts index 28721295f7d..6fbc70d641e 100644 --- a/src/vs/workbench/api/node/extHostTask.ts +++ b/src/vs/workbench/api/node/extHostTask.ts @@ -207,32 +207,32 @@ namespace TaskRevealKind { } } -namespace TaskInstanceKind { - export function from(value: vscode.TaskInstanceKind): TaskSystem.InstanceKind { +namespace TaskPanelKind { + export function from(value: vscode.TaskPanelKind): TaskSystem.PanelKind { if (value === void 0 || value === null) { - return TaskSystem.InstanceKind.Shared; + return TaskSystem.PanelKind.Shared; } switch (value) { - case types.TaskInstanceKind.Same: - return TaskSystem.InstanceKind.Same; - case types.TaskInstanceKind.New: - return TaskSystem.InstanceKind.New; + case types.TaskPanelKind.Dedicated: + return TaskSystem.PanelKind.Dedicated; + case types.TaskPanelKind.New: + return TaskSystem.PanelKind.New; default: - return TaskSystem.InstanceKind.Shared; + return TaskSystem.PanelKind.Shared; } } } -namespace TerminalBehaviour { - export function from(value: vscode.TaskTerminalBehavior): TaskSystem.TerminalBehavior { +namespace PresentationOptions { + export function from(value: vscode.TaskPresentationOptions): TaskSystem.PresentationOptions { if (value === void 0 || value === null) { - return { reveal: TaskSystem.RevealKind.Always, echo: true, focus: false, instance: TaskSystem.InstanceKind.Shared }; + return { reveal: TaskSystem.RevealKind.Always, echo: true, focus: false, panel: TaskSystem.PanelKind.Shared }; } return { reveal: TaskRevealKind.from(value.reveal), echo: value.echo === void 0 ? true : !!value.echo, focus: !!value.focus, - instance: TaskInstanceKind.from(value.instance) + panel: TaskPanelKind.from(value.panel) }; } } @@ -359,7 +359,7 @@ namespace Tasks { args: Strings.from(value.args), type: TaskSystem.CommandType.Process, suppressTaskName: true, - terminalBehavior: TerminalBehaviour.from(value.terminalBehavior) + presentation: PresentationOptions.from(value.presentationOptions) }; if (value.options) { result.options = CommandOptions.from(value.options); @@ -374,7 +374,7 @@ namespace Tasks { let result: TaskSystem.CommandConfiguration = { name: value.commandLine, type: TaskSystem.CommandType.Shell, - terminalBehavior: TerminalBehaviour.from(value.terminalBehavior) + presentation: PresentationOptions.from(value.presentationOptions) }; if (value.options) { result.options = CommandOptions.from(value.options); diff --git a/src/vs/workbench/api/node/extHostTypes.ts b/src/vs/workbench/api/node/extHostTypes.ts index 5b60f3cff85..ed530ee907a 100644 --- a/src/vs/workbench/api/node/extHostTypes.ts +++ b/src/vs/workbench/api/node/extHostTypes.ts @@ -1037,10 +1037,10 @@ export enum TaskRevealKind { Never = 3 } -export enum TaskInstanceKind { +export enum TaskPanelKind { Shared = 1, - Same = 2, + Dedicated = 2, New = 3 } @@ -1053,7 +1053,7 @@ export class BaseTask { private _isBackground: boolean; private _source: string; private _group: string; - private _terminalBehavior: vscode.TaskTerminalBehavior; + private _presentationOptions: vscode.TaskPresentationOptions; constructor(name: string, problemMatchers: string[]) { if (typeof name !== 'string') { @@ -1062,7 +1062,7 @@ export class BaseTask { this._name = name; this._problemMatchers = problemMatchers || []; this._isBackground = false; - this._terminalBehavior = Object.create(null); + this._presentationOptions = Object.create(null); } get identifier(): string { @@ -1124,15 +1124,15 @@ export class BaseTask { this._group = value; } - get terminalBehavior(): vscode.TaskTerminalBehavior { - return this._terminalBehavior; + get presentationOptions(): vscode.TaskPresentationOptions { + return this._presentationOptions; } - set terminalBehavior(value: vscode.TaskTerminalBehavior) { + set presentationOptions(value: vscode.TaskPresentationOptions) { if (value === void 0 || value === null) { value = Object.create(null); } - this._terminalBehavior = value; + this._presentationOptions = value; } get problemMatchers(): string[] { diff --git a/src/vs/workbench/parts/tasks/browser/buildQuickOpen.ts b/src/vs/workbench/parts/tasks/browser/buildQuickOpen.ts index 0ef0d65fb3e..22e0bd0cd00 100644 --- a/src/vs/workbench/parts/tasks/browser/buildQuickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/buildQuickOpen.ts @@ -26,7 +26,7 @@ class TaskEntry extends base.TaskEntry { } let task = this._task; this.taskService.run(task); - if (task.command.terminalBehavior.focus) { + if (task.command.presentation.focus) { this.quickOpenService.close(); return false; } diff --git a/src/vs/workbench/parts/tasks/browser/taskQuickOpen.ts b/src/vs/workbench/parts/tasks/browser/taskQuickOpen.ts index 544826907d4..e48d1d7d55c 100644 --- a/src/vs/workbench/parts/tasks/browser/taskQuickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/taskQuickOpen.ts @@ -28,7 +28,7 @@ class TaskEntry extends base.TaskEntry { } let task = this._task; this.taskService.run(task); - if (task.command.terminalBehavior.focus) { + if (task.command.presentation.focus) { this.quickOpenService.close(); return false; } diff --git a/src/vs/workbench/parts/tasks/browser/testQuickOpen.ts b/src/vs/workbench/parts/tasks/browser/testQuickOpen.ts index ff9b506b36e..4c7f59844b0 100644 --- a/src/vs/workbench/parts/tasks/browser/testQuickOpen.ts +++ b/src/vs/workbench/parts/tasks/browser/testQuickOpen.ts @@ -26,7 +26,7 @@ class TaskEntry extends base.TaskEntry { } let task = this._task; this.taskService.run(task); - if (task.command.terminalBehavior.focus) { + if (task.command.presentation.focus) { this.quickOpenService.close(); return false; } diff --git a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts index 9b07f84f16f..75422d4ef67 100644 --- a/src/vs/workbench/parts/tasks/common/taskConfiguration.ts +++ b/src/vs/workbench/parts/tasks/common/taskConfiguration.ts @@ -234,16 +234,27 @@ export interface BaseTaskRunnerConfiguration { /** * Controls the behavior of the used terminal */ - terminal?: { + presentation?: { /** - * The terminal should echo the run command. + * Controls whether the terminal executing a task is brought to front or not. + * Defaults to `RevealKind.Always`. + */ + reveal?: string; + + /** + * Controls whether the executed command is printed to the output window or terminal as well. */ echo?: boolean; + /** - * Controls whether or not the terminal is reveal if a task - * is executed. + * Controls whether the terminal is focus when this task is executed */ - reveal?: string; + focus?: boolean; + + /** + * Controls whether the task runs in a new terminal + */ + panel?: string; }; /** @@ -596,11 +607,11 @@ namespace CommandOptions { namespace CommandConfiguration { - interface TerminalBehavior { + interface PresentationOptions { echo?: boolean; reveal?: string; focus?: boolean; - instance?: string; + panel?: string; } interface BaseCommandConfiguationShape { @@ -611,7 +622,11 @@ namespace CommandConfiguration { options?: CommandOptions; echoCommand?: boolean; showOutput?: string; - terminal?: TerminalBehavior; + /** + * @deprecated Use panel instead. + */ + terminal?: PresentationOptions; + presentation?: PresentationOptions; taskSelector?: string; suppressTaskName?: boolean; } @@ -622,66 +637,67 @@ namespace CommandConfiguration { linux?: BaseCommandConfiguationShape; } - export namespace TerminalBehavior { - const properties: MetaData[] = [{ property: 'echo' }, { property: 'reveal' }, { property: 'focus' }, { property: 'instance' }]; + export namespace PresentationOptions { + const properties: MetaData[] = [{ property: 'echo' }, { property: 'reveal' }, { property: 'focus' }, { property: 'panel' }]; - export function from(this: void, config: BaseCommandConfiguationShape, context: ParseContext): Tasks.TerminalBehavior { + export function from(this: void, config: BaseCommandConfiguationShape, context: ParseContext): Tasks.PresentationOptions { let echo: boolean; let reveal: Tasks.RevealKind; let focus: boolean; - let instance: Tasks.InstanceKind; + let panel: Tasks.PanelKind; if (Types.isBoolean(config.echoCommand)) { echo = config.echoCommand; } if (Types.isString(config.showOutput)) { reveal = Tasks.RevealKind.fromString(config.showOutput); } - if (config.terminal) { - if (Types.isBoolean(config.terminal.echo)) { - echo = config.terminal.echo; + let presentation = config.presentation || config.terminal; + if (presentation) { + if (Types.isBoolean(presentation.echo)) { + echo = presentation.echo; } - if (Types.isString(config.terminal.reveal)) { - reveal = Tasks.RevealKind.fromString(config.terminal.reveal); + if (Types.isString(presentation.reveal)) { + reveal = Tasks.RevealKind.fromString(presentation.reveal); } - if (Types.isBoolean(config.terminal.focus)) { - focus = config.terminal.focus; + if (Types.isBoolean(presentation.focus)) { + focus = presentation.focus; } - if (Types.isString(config.terminal.instance)) { - instance = Tasks.InstanceKind.fromString(config.terminal.instance); + if (Types.isString(presentation.panel)) { + panel = Tasks.PanelKind.fromString(presentation.panel); } } - if (echo === void 0 && reveal === void 0 && focus === void 0 && instance === void 0) { + if (echo === void 0 && reveal === void 0 && focus === void 0 && panel === void 0) { return undefined; } - return { echo, reveal, focus, instance }; + return { echo, reveal, focus, panel }; } - export function assignProperties(target: Tasks.TerminalBehavior, source: Tasks.TerminalBehavior): Tasks.TerminalBehavior { + export function assignProperties(target: Tasks.PresentationOptions, source: Tasks.PresentationOptions): Tasks.PresentationOptions { return _assignProperties(target, source, properties); } - export function fillProperties(target: Tasks.TerminalBehavior, source: Tasks.TerminalBehavior): Tasks.TerminalBehavior { + export function fillProperties(target: Tasks.PresentationOptions, source: Tasks.PresentationOptions): Tasks.PresentationOptions { return _fillProperties(target, source, properties); } - export function fillDefaults(value: Tasks.TerminalBehavior, context: ParseContext): Tasks.TerminalBehavior { + export function fillDefaults(value: Tasks.PresentationOptions, context: ParseContext): Tasks.PresentationOptions { let defaultEcho = context.engine === Tasks.ExecutionEngine.Terminal ? true : false; - return _fillDefaults(value, { echo: defaultEcho, reveal: Tasks.RevealKind.Always, focus: false, instance: Tasks.InstanceKind.Shared }, properties, context); + return _fillDefaults(value, { echo: defaultEcho, reveal: Tasks.RevealKind.Always, focus: false, panel: Tasks.PanelKind.Shared }, properties, context); } - export function freeze(value: Tasks.TerminalBehavior): Readonly { + export function freeze(value: Tasks.PresentationOptions): Readonly { return _freeze(value, properties); } - export function isEmpty(this: void, value: Tasks.TerminalBehavior): boolean { + export function isEmpty(this: void, value: Tasks.PresentationOptions): boolean { return _isEmpty(value, properties); } } - const properties: MetaData[] = [ + const properties: MetaData[] = [ { property: 'type' }, { property: 'name' }, { property: 'options', type: CommandOptions }, { property: 'args' }, { property: 'taskSelector' }, { property: 'suppressTaskName' }, - { property: 'terminalBehavior', type: TerminalBehavior } + { property: 'presentation', type: PresentationOptions } ]; export function from(this: void, config: CommandConfiguationShape, context: ParseContext): Tasks.CommandConfiguration { @@ -705,7 +721,7 @@ namespace CommandConfiguration { let result: Tasks.CommandConfiguration = { name: undefined, type: undefined, - terminalBehavior: undefined + presentation: undefined }; if (Types.isString(config.command)) { result.name = config.command; @@ -735,9 +751,9 @@ namespace CommandConfiguration { } } } - let terminal = TerminalBehavior.from(config, context); - if (terminal) { - result.terminalBehavior = terminal; + let panel = PresentationOptions.from(config, context); + if (panel) { + result.presentation = panel; } if (Types.isString(config.taskSelector)) { result.taskSelector = config.taskSelector; @@ -754,7 +770,7 @@ namespace CommandConfiguration { export function onlyTerminalBehaviour(value: Tasks.CommandConfiguration): boolean { return value && - value.terminalBehavior && (value.terminalBehavior.echo !== void 0 || value.terminalBehavior.reveal !== void 0) && + value.presentation && (value.presentation.echo !== void 0 || value.presentation.reveal !== void 0) && value.name === void 0 && value.type === void 0 && value.args === void 0 && CommandOptions.isEmpty(value.options); } @@ -776,7 +792,7 @@ namespace CommandConfiguration { target.args = target.args.concat(source.args); } } - target.terminalBehavior = TerminalBehavior.assignProperties(target.terminalBehavior, source.terminalBehavior); + target.presentation = PresentationOptions.assignProperties(target.presentation, source.presentation); target.options = CommandOptions.assignProperties(target.options, source.options); return target; } @@ -788,14 +804,14 @@ namespace CommandConfiguration { target = target || { name: undefined, type: undefined, - terminalBehavior: undefined + presentation: undefined }; fillProperty(target, source, 'name'); fillProperty(target, source, 'type'); fillProperty(target, source, 'taskSelector'); fillProperty(target, source, 'suppressTaskName'); - target.terminalBehavior = TerminalBehavior.fillProperties(target.terminalBehavior, source.terminalBehavior); + target.presentation = PresentationOptions.fillProperties(target.presentation, source.presentation); target.options = CommandOptions.fillProperties(target.options, source.options); let args: string[] = source.args ? source.args.slice() : []; @@ -820,7 +836,7 @@ namespace CommandConfiguration { if (value.name !== void 0 && value.type === void 0) { value.type = Tasks.CommandType.Process; } - value.terminalBehavior = TerminalBehavior.fillDefaults(value.terminalBehavior, context); + value.presentation = PresentationOptions.fillDefaults(value.presentation, context); if (!isEmpty(value)) { value.options = CommandOptions.fillDefaults(value.options, context); } @@ -1415,7 +1431,7 @@ class ConfigurationParser { command: { name: undefined, type: undefined, - terminalBehavior: undefined, + presentation: undefined, suppressTaskName: true }, isBackground: isBackground, diff --git a/src/vs/workbench/parts/tasks/common/tasks.ts b/src/vs/workbench/parts/tasks/common/tasks.ts index ca4b93f5422..d84a4ce1f14 100644 --- a/src/vs/workbench/parts/tasks/common/tasks.ts +++ b/src/vs/workbench/parts/tasks/common/tasks.ts @@ -80,61 +80,64 @@ export namespace RevealKind { } } -export enum InstanceKind { +export enum PanelKind { /** - * Shares a terminal with other tasks. This is the default. + * Shares a panel with other tasks. This is the default. */ Shared = 1, /** - * Uses the same terminal for every run if possible. The terminal is not + * Uses a dedicated panel for this tasks. The panel is not * shared with other tasks. */ - Same = 2, + Dedicated = 2, /** - * Creates a new terminal whenever that task is executed + * Creates a new panel whenever this task is executed. */ New = 3 } -export namespace InstanceKind { - export function fromString(value: string): InstanceKind { +export namespace PanelKind { + export function fromString(value: string): PanelKind { switch (value.toLowerCase()) { case 'shared': - return InstanceKind.Shared; - case 'same': - return InstanceKind.Same; + return PanelKind.Shared; + case 'dedicated': + return PanelKind.Dedicated; case 'new': - return InstanceKind.New; + return PanelKind.New; default: - return InstanceKind.Shared; + return PanelKind.Shared; } } } -export interface TerminalBehavior { +export interface PresentationOptions { /** - * Controls whether the terminal executing a task is brought to front or not. + * Controls whether the task output is reveal in the user interface. * Defaults to `RevealKind.Always`. */ reveal: RevealKind; /** - * Controls whether the executed command is printed to the output window or terminal as well. + * Controls whether the command associated with the task is echoed + * in the user interface. */ echo: boolean; /** - * Controls whether the terminal is focus when this task is executed + * Controls whether the panel showing the task output is taking focus. */ focus: boolean; /** - * Controls whether the task runs in a new terminal + * Controls if the task panel is used for this task only (dedicated), + * shared between tasks (shared) or if a new panel is created on + * every task execution (new). Defaults to `TaskInstanceKind.Shared` */ - instance: InstanceKind; + panel: PanelKind; } export enum CommandType { @@ -189,9 +192,9 @@ export interface CommandConfiguration { suppressTaskName?: boolean; /** - * Describes how the terminal is supposed to behave. + * Describes how the task is presented in the UI. */ - terminalBehavior: TerminalBehavior; + presentation: PresentationOptions; } export namespace TaskGroup { diff --git a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts index 554f6a9bc39..f9c2f251a89 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.ts @@ -43,23 +43,35 @@ const dependsOn: IJSONSchema = { ] }; -const terminal: IJSONSchema = { +const presentation: IJSONSchema = { type: 'object', default: { reveal: 'always' }, - description: nls.localize('JsonSchema.tasks.terminal', 'Configures the terminal that is used to execute the task.'), + description: nls.localize('JsonSchema.tasks.terminal', 'Configures the panel that is used to present the task\'s ouput and reads its input.'), + additionalProperties: false, properties: { echo: { + type: 'boolean', + default: true, + description: nls.localize('JsonSchema.tasks.terminal.echo', 'Controls whether the executed command is echoed to the panel. Default is true.') + }, + focus: { type: 'boolean', default: false, - description: nls.localize('JsonSchema.tasks.terminal.echo', 'Controls whether the executed command is echoed to the terminal. Default is false.') + description: nls.localize('JsonSchema.tasks.terminal.focus', 'Controls whether the panel takes focus. Default is false. If set to true the panel is revealed as well.') }, reveal: { type: 'string', enum: ['always', 'silent', 'never'], default: 'always', - description: nls.localize('JsonSchema.tasks.terminal.reveals', 'Controls whether the terminal running the task is revealed or not. Default is \"always\".') + description: nls.localize('JsonSchema.tasks.terminal.reveals', 'Controls whether the panel running the task is revealed or not. Default is \"always\".') + }, + panel: { + type: 'string', + enum: ['shared', 'dedicated', 'new'], + default: 'shared', + description: nls.localize('JsonSchema.tasks.terminal.instance', 'Controls if the panel is shared between tasks, dedicated to this task or a new one is created on every run.') } } }; @@ -131,7 +143,7 @@ definitions.taskDescription.properties.dependsOn = dependsOn; // definitions.taskDescription.properties.isTestCommand.deprecationMessage = nls.localize('JsonSchema.tasks.isTestCommand.deprecated', 'The property isTestCommand is deprecated. Use the group property instead.'); definitions.taskDescription.properties.customize = customize; definitions.taskDescription.properties.type = Objects.deepClone(taskType); -definitions.taskDescription.properties.terminal = terminal; +definitions.taskDescription.properties.presentation = presentation; definitions.taskDescription.properties.group = group; definitions.options.properties.shell = { $ref: '#/definitions/shellConfiguration' diff --git a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts index 8f43026ea21..30ff0d963ae 100644 --- a/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.ts @@ -15,6 +15,7 @@ import * as Platform from 'vs/base/common/platform'; import * as Async from 'vs/base/common/async'; import { TPromise } from 'vs/base/common/winjs.base'; import { IStringDictionary } from 'vs/base/common/collections'; +import { LinkedMap, Touch } from 'vs/base/common/map'; import Severity from 'vs/base/common/severity'; import { EventEmitter } from 'vs/base/common/eventEmitter'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; @@ -33,7 +34,7 @@ import { IConfigurationResolverService } from 'vs/workbench/services/configurati import { ITerminalService, ITerminalInstance, IShellLaunchConfig } from 'vs/workbench/parts/terminal/common/terminal'; import { IOutputService, IOutputChannel } from 'vs/workbench/parts/output/common/output'; import { StartStopProblemCollector, WatchingProblemCollector, ProblemCollectorEvents } from 'vs/workbench/parts/tasks/common/problemCollectors'; -import { Task, RevealKind, CommandOptions, ShellConfiguration, CommandType } from 'vs/workbench/parts/tasks/common/tasks'; +import { Task, RevealKind, CommandOptions, ShellConfiguration, CommandType, PanelKind } from 'vs/workbench/parts/tasks/common/tasks'; import { ITaskSystem, ITaskSummary, ITaskExecuteResult, TaskExecuteKind, TaskError, TaskErrors, ITaskResolver, TelemetryEvent, Triggers, TaskSystemEvents, TaskEvent, TaskType @@ -105,9 +106,9 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { private outputChannel: IOutputChannel; private activeTasks: IStringDictionary; - private primaryTerminal: PrimaryTerminal; private terminals: IStringDictionary; - private idleTaskTerminals: IStringDictionary; + private idleTaskTerminals: LinkedMap; + private sameTaskTerminals: IStringDictionary; constructor(private terminalService: ITerminalService, private outputService: IOutputService, private markerService: IMarkerService, private modelService: IModelService, @@ -120,7 +121,8 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { this.outputChannel = this.outputService.getChannel(outputChannelId); this.activeTasks = Object.create(null); this.terminals = Object.create(null); - this.idleTaskTerminals = Object.create(null); + this.idleTaskTerminals = new LinkedMap(); + this.sameTaskTerminals = Object.create(null); } public log(value: string): void { @@ -134,8 +136,8 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { public run(task: Task, resolver: ITaskResolver, trigger: string = Triggers.command): ITaskExecuteResult { let terminalData = this.activeTasks[task._id]; if (terminalData && terminalData.promise) { - let reveal = task.command.terminalBehavior.reveal; - let focus = task.command.terminalBehavior.focus; + let reveal = task.command.presentation.reveal; + let focus = task.command.presentation.focus; if (reveal === RevealKind.Always || focus) { this.terminalService.setActiveInstance(terminalData.terminal); this.terminalService.showPanel(focus); @@ -275,10 +277,14 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { onData.dispose(); onExit.dispose(); delete this.activeTasks[task._id]; - if (this.primaryTerminal && this.primaryTerminal.terminal === terminal) { - this.primaryTerminal.busy = false; + switch (task.command.presentation.panel) { + case PanelKind.Dedicated: + this.sameTaskTerminals[task._id] = terminal.id.toString(); + break; + case PanelKind.Shared: + this.idleTaskTerminals.set(task._id, terminal.id.toString(), Touch.First); + break; } - this.idleTaskTerminals[task._id] = terminal.id.toString(); let remaining = decoder.end(); if (remaining) { watchingProblemMatcher.processLine(remaining); @@ -291,7 +297,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { this.emit(TaskSystemEvents.Inactive, event); } eventCounter = 0; - let reveal = task.command.terminalBehavior.reveal; + let reveal = task.command.presentation.reveal; if (exitCode && exitCode === 1 && watchingProblemMatcher.numberOfMatches === 0 && reveal !== RevealKind.Never) { this.terminalService.setActiveInstance(terminal); this.terminalService.showPanel(false); @@ -317,10 +323,14 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { onData.dispose(); onExit.dispose(); delete this.activeTasks[task._id]; - if (this.primaryTerminal && this.primaryTerminal.terminal === terminal) { - this.primaryTerminal.busy = false; + switch (task.command.presentation.panel) { + case PanelKind.Dedicated: + this.sameTaskTerminals[task._id] = terminal.id.toString(); + break; + case PanelKind.Shared: + this.idleTaskTerminals.set(task._id, terminal.id.toString(), Touch.First); + break; } - this.idleTaskTerminals[task._id] = terminal.id.toString(); let remaining = decoder.end(); if (remaining) { startStopProblemMatcher.processLine(remaining); @@ -334,8 +344,8 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { }); } this.terminalService.setActiveInstance(terminal); - if (task.command.terminalBehavior.reveal === RevealKind.Always || (task.command.terminalBehavior.reveal === RevealKind.Silent && task.problemMatchers.length === 0)) { - this.terminalService.showPanel(task.command.terminalBehavior.focus); + if (task.command.presentation.reveal === RevealKind.Always || (task.command.presentation.reveal === RevealKind.Silent && task.problemMatchers.length === 0)) { + this.terminalService.showPanel(task.command.presentation.focus); } this.activeTasks[task._id] = { terminal, task, promise }; return promise.then((summary) => { @@ -371,7 +381,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { let { command, args } = this.resolveCommandAndArgs(task); let terminalName = nls.localize('TerminalTaskSystem.terminalName', 'Task - {0}', task.name); let waitOnExit: boolean | string = false; - if (task.command.terminalBehavior.reveal !== RevealKind.Never || !task.isBackground) { + if (task.command.presentation.reveal !== RevealKind.Never || !task.isBackground) { waitOnExit = nls.localize('reuseTerminal', 'Terminal will be reused by tasks, press any key to close it.'); }; let shellLaunchConfig: IShellLaunchConfig = undefined; @@ -424,7 +434,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { }); shellArgs.push(commandLine); shellLaunchConfig.args = Platform.isWindows ? shellArgs.join(' ') : shellArgs; - if (task.command.terminalBehavior.echo) { + if (task.command.presentation.echo) { shellLaunchConfig.initialText = `\x1b[1m> Executing task: ${commandLine} <\x1b[0m\n`; } } else { @@ -438,7 +448,7 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { args, waitOnExit }; - if (task.command.terminalBehavior.echo) { + if (task.command.presentation.echo) { let getArgsToEcho = (args: string | string[]): string => { if (!args || args.length === 0) { return ''; @@ -464,41 +474,38 @@ export class TerminalTaskSystem extends EventEmitter implements ITaskSystem { }); shellLaunchConfig.env = env; } - let terminalId = this.idleTaskTerminals[task._id]; - if (terminalId) { - let taskTerminal = this.terminals[terminalId]; - if (taskTerminal) { - delete this.idleTaskTerminals[task._id]; - taskTerminal.terminal.reuseTerminal(shellLaunchConfig); - return [taskTerminal.terminal, command]; + let prefersSameTerminal = task.command.presentation.panel === PanelKind.Dedicated; + let allowsSharedTerminal = task.command.presentation.panel === PanelKind.Shared; + + let terminalToReuse: TerminalData; + if (prefersSameTerminal) { + let terminalId = this.sameTaskTerminals[task._id]; + if (terminalId) { + terminalToReuse = this.terminals[terminalId]; + delete this.sameTaskTerminals[task._id]; } - } - if (this.primaryTerminal && !this.primaryTerminal.busy) { - // We reuse the primary terminal. Make sure the last running task isn't referenced in the idle terminals - let terminalData = this.terminals[this.primaryTerminal.terminal.id.toString()]; - if (terminalData) { - delete this.idleTaskTerminals[terminalData.lastTask]; + } else if (allowsSharedTerminal) { + let terminalId = this.idleTaskTerminals.remove(task._id) || this.idleTaskTerminals.shift(); + if (terminalId) { + terminalToReuse = this.terminals[terminalId]; } - this.primaryTerminal.terminal.reuseTerminal(shellLaunchConfig); - this.primaryTerminal.busy = true; - return [this.primaryTerminal.terminal, command]; } + if (terminalToReuse) { + terminalToReuse.terminal.reuseTerminal(shellLaunchConfig); + return [terminalToReuse.terminal, command]; + } + const result = this.terminalService.createInstance(shellLaunchConfig); const key = result.id.toString(); result.onDisposed((terminal) => { let terminalData = this.terminals[key]; if (terminalData) { delete this.terminals[key]; - delete this.idleTaskTerminals[terminalData.lastTask]; - } - if (this.primaryTerminal && this.primaryTerminal.terminal === terminal) { - this.primaryTerminal = undefined; + delete this.sameTaskTerminals[terminalData.lastTask]; + this.idleTaskTerminals.delete(terminalData.lastTask); } }); this.terminals[key] = { terminal: result, lastTask: task._id }; - if (!task.isBackground && !this.primaryTerminal) { - this.primaryTerminal = { terminal: result, busy: true }; - } return [result, command]; } diff --git a/src/vs/workbench/parts/tasks/node/processTaskSystem.ts b/src/vs/workbench/parts/tasks/node/processTaskSystem.ts index 0db8946a2d2..56bb36e3745 100644 --- a/src/vs/workbench/parts/tasks/node/processTaskSystem.ts +++ b/src/vs/workbench/parts/tasks/node/processTaskSystem.ts @@ -167,12 +167,12 @@ export class ProcessTaskSystem extends EventEmitter implements ITaskSystem { this.childProcess = new LineProcess(command, args, commandConfig.type === CommandType.Shell, this.resolveOptions(commandConfig.options)); telemetryEvent.command = this.childProcess.getSanitizedCommand(); // we have no problem matchers defined. So show the output log - let reveal = task.command.terminalBehavior.reveal; + let reveal = task.command.presentation.reveal; if (reveal === RevealKind.Always || (reveal === RevealKind.Silent && task.problemMatchers.length === 0)) { this.showOutput(); } - if (commandConfig.terminalBehavior.echo) { + if (commandConfig.presentation.echo) { let prompt: string = Platform.isWindows ? '>' : '$'; this.log(`running command${prompt} ${command} ${args.join(' ')}`); } diff --git a/src/vs/workbench/parts/tasks/test/node/configuration.test.ts b/src/vs/workbench/parts/tasks/test/node/configuration.test.ts index 2d60a06a146..9c12f67048d 100644 --- a/src/vs/workbench/parts/tasks/test/node/configuration.test.ts +++ b/src/vs/workbench/parts/tasks/test/node/configuration.test.ts @@ -77,31 +77,31 @@ class ConfiguationBuilder { } } -class TerminalBehaviorBuilder { +class PresentationBuilder { - public result: Tasks.TerminalBehavior; + public result: Tasks.PresentationOptions; constructor(public parent: CommandConfigurationBuilder) { - this.result = { echo: false, reveal: Tasks.RevealKind.Always, focus: false, instance: Tasks.InstanceKind.Shared }; + this.result = { echo: false, reveal: Tasks.RevealKind.Always, focus: false, panel: Tasks.PanelKind.Shared }; } - public echo(value: boolean): TerminalBehaviorBuilder { + public echo(value: boolean): PresentationBuilder { this.result.echo = value; return this; } - public reveal(value: Tasks.RevealKind): TerminalBehaviorBuilder { + public reveal(value: Tasks.RevealKind): PresentationBuilder { this.result.reveal = value; return this; } - public focus(value: boolean): TerminalBehaviorBuilder { + public focus(value: boolean): PresentationBuilder { this.result.focus = value; return this; } - public instance(value: Tasks.InstanceKind): TerminalBehaviorBuilder { - this.result.instance = value; + public instance(value: Tasks.PanelKind): PresentationBuilder { + this.result.panel = value; return this; } @@ -112,10 +112,10 @@ class TerminalBehaviorBuilder { class CommandConfigurationBuilder { public result: Tasks.CommandConfiguration; - private terminalBuilder: TerminalBehaviorBuilder; + private presentationBuilder: PresentationBuilder; constructor(public parent: TaskBuilder, command: string) { - this.terminalBuilder = new TerminalBehaviorBuilder(this); + this.presentationBuilder = new PresentationBuilder(this); this.result = { name: command, type: Tasks.CommandType.Process, @@ -123,7 +123,7 @@ class CommandConfigurationBuilder { options: { cwd: '${workspaceRoot}' }, - terminalBehavior: this.terminalBuilder.result, + presentation: this.presentationBuilder.result, suppressTaskName: false }; } @@ -158,13 +158,13 @@ class CommandConfigurationBuilder { return this; } - public terminal(): TerminalBehaviorBuilder { - return this.terminalBuilder; + public presentation(): PresentationBuilder { + return this.presentationBuilder; } public done(taskName: string): void { this.result.args = this.result.args.map(arg => arg === '$name' ? taskName : arg); - this.terminalBuilder.done(); + this.presentationBuilder.done(); } } @@ -458,7 +458,7 @@ function assertTask(actual: Tasks.Task, expected: Tasks.Task) { function assertCommandConfiguration(actual: Tasks.CommandConfiguration, expected: Tasks.CommandConfiguration) { assert.strictEqual(typeof actual, typeof expected); if (actual && expected) { - assertTerminalBehavior(actual.terminalBehavior, expected.terminalBehavior); + assertPresentation(actual.presentation, expected.presentation); assert.strictEqual(actual.name, expected.name, 'name'); assert.strictEqual(actual.type, expected.type, 'task type'); assert.strictEqual(actual.suppressTaskName, expected.suppressTaskName, 'suppressTaskName'); @@ -475,7 +475,7 @@ function assertCommandConfiguration(actual: Tasks.CommandConfiguration, expected } } -function assertTerminalBehavior(actual: Tasks.TerminalBehavior, expected: Tasks.TerminalBehavior) { +function assertPresentation(actual: Tasks.PresentationOptions, expected: Tasks.PresentationOptions) { assert.strictEqual(typeof actual, typeof expected); if (actual && expected) { assert.strictEqual(actual.echo, expected.echo); @@ -574,7 +574,7 @@ suite('Tasks version 0.1.0', () => { task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). command().suppressTaskName(true). - terminal().reveal(Tasks.RevealKind.Silent); + presentation().reveal(Tasks.RevealKind.Silent); testConfiguration( { version: '0.1.0', @@ -639,7 +639,7 @@ suite('Tasks version 0.1.0', () => { task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). command().suppressTaskName(true). - terminal().reveal(Tasks.RevealKind.Never); + presentation().reveal(Tasks.RevealKind.Never); testConfiguration( { version: '0.1.0', @@ -656,7 +656,7 @@ suite('Tasks version 0.1.0', () => { task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). command().suppressTaskName(true). - terminal(). + presentation(). echo(true); testConfiguration( { @@ -805,7 +805,7 @@ suite('Tasks version 0.1.0', () => { task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). command().suppressTaskName(true). - terminal().reveal(Platform.isWindows ? Tasks.RevealKind.Always : Tasks.RevealKind.Never); + presentation().reveal(Platform.isWindows ? Tasks.RevealKind.Always : Tasks.RevealKind.Never); let external: ExternalTaskRunnerConfiguration = { version: '0.1.0', command: 'tsc', @@ -823,7 +823,7 @@ suite('Tasks version 0.1.0', () => { task('tsc', 'tsc'). group(Tasks.TaskGroup.Build). command().suppressTaskName(true). - terminal(). + presentation(). echo(Platform.isWindows ? false : true); let external: ExternalTaskRunnerConfiguration = { version: '0.1.0', @@ -951,7 +951,7 @@ suite('Tasks version 0.1.0', () => { isBackground(true). promptOnClose(false). command().args(['$name', '--p']). - terminal(). + presentation(). echo(true).reveal(Tasks.RevealKind.Never); testConfiguration(external, builder); @@ -972,7 +972,7 @@ suite('Tasks version 0.1.0', () => { let builder = new ConfiguationBuilder(); builder.task('test', 'tsc'). group(Tasks.TaskGroup.Test). - command().args(['$name']).terminal(). + command().args(['$name']).presentation(). echo(true).reveal(Tasks.RevealKind.Never); testConfiguration(external, builder); @@ -1457,7 +1457,7 @@ suite('Tasks version 2.0.0', () => { group(Tasks.TaskGroup.Build). command().suppressTaskName(true). type(Tasks.CommandType.Shell). - terminal().echo(true); + presentation().echo(true); testConfiguration(external, builder); }); @@ -1518,14 +1518,14 @@ suite('Bugs / regression tests', () => { command().suppressTaskName(true). args(['-ExecutionPolicy', 'RemoteSigned', '.\\dockerTask.ps1', '-ComposeForDebug', '-Environment', 'debug']). options({ cwd: '${workspaceRoot}' }). - terminal().echo(true).reveal(Tasks.RevealKind.Always); + presentation().echo(true).reveal(Tasks.RevealKind.Always); testConfiguration(external, builder); } else if (Platform.isMacintosh) { builder.task('composeForDebug', '/bin/bash'). command().suppressTaskName(true). args(['-c', './dockerTask.sh composeForDebug debug']). options({ cwd: '${workspaceRoot}' }). - terminal().reveal(Tasks.RevealKind.Always); + presentation().reveal(Tasks.RevealKind.Always); testConfiguration(external, builder); } }); -- GitLab From 93f625294826c2b07fad4578ba612bc2083e3a22 Mon Sep 17 00:00:00 2001 From: Andre Weinand Date: Fri, 16 Jun 2017 13:21:42 +0200 Subject: [PATCH 0954/1347] update DAP --- src/vs/workbench/parts/debug/common/debugProtocol.d.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/vs/workbench/parts/debug/common/debugProtocol.d.ts b/src/vs/workbench/parts/debug/common/debugProtocol.d.ts index a8ec4386a55..04ae77ec97e 100644 --- a/src/vs/workbench/parts/debug/common/debugProtocol.d.ts +++ b/src/vs/workbench/parts/debug/common/debugProtocol.d.ts @@ -988,6 +988,8 @@ declare module DebugProtocol { supportsExceptionInfoRequest?: boolean; /** The debug adapter supports the 'terminateDebuggee' attribute on the 'disconnect' request. */ supportTerminateDebuggee?: boolean; + /** The debug adapter supports the delayed loading of parts of the stack, which requires that both the 'startFrame' and 'levels' arguments and the 'totalFrames' result of the 'StackTrace' request are supported. */ + supportsDelayedStackTraceLoading?: boolean; } /** An ExceptionBreakpointsFilter is shown in the UI as an option for configuring how exceptions are dealt with. */ @@ -1305,6 +1307,8 @@ declare module DebugProtocol { line?: boolean; /** Displays the module of the stack frame. */ module?: boolean; + /** Includes all stack frames, including those the debug adapter might otherwise hide. */ + includeAll?: boolean; } /** An ExceptionOptions assigns configuration options to a set of exceptions. */ -- GitLab From a01a40522289f086eab5e4b97ac64c7d8800a078 Mon Sep 17 00:00:00 2001 From: Andre Weinand Date: Fri, 16 Jun 2017 15:19:26 +0200 Subject: [PATCH 0955/1347] node-debug@1.14.3 --- build/gulpfile.vscode.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index 453b44df066..89cd47827bb 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -42,7 +42,7 @@ const nodeModules = ['electron', 'original-fs'] // Build const builtInExtensions = [ - { name: 'ms-vscode.node-debug', version: '1.14.2' }, + { name: 'ms-vscode.node-debug', version: '1.14.3' }, { name: 'ms-vscode.node-debug2', version: '1.14.0' } ]; -- GitLab From fede6134bb068e7010f2a3b39222fe88d4af98dc Mon Sep 17 00:00:00 2001 From: isidor Date: Fri, 16 Jun 2017 15:30:10 +0200 Subject: [PATCH 0956/1347] properly react to workspace change events --- .../workbench/parts/files/browser/views/explorerView.ts | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index 8c51e4d9789..4550bab1e12 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -146,6 +146,7 @@ export class ExplorerView extends CollapsibleView { }; this.toDispose.push(this.themeService.onDidFileIconThemeChange(onFileIconThemeChange)); + this.toDispose.push(this.contextService.onDidChangeWorkspaceRoots(() => this.refreshFromEvent())); onFileIconThemeChange(this.themeService.getFileIconTheme()); } @@ -341,7 +342,7 @@ export class ExplorerView extends CollapsibleView { } private get isCreated(): boolean { - return this.explorerViewer && this.explorerViewer.getInput(); + return !!(this.explorerViewer && this.explorerViewer.getInput()); } @memoize @@ -728,13 +729,14 @@ export class ExplorerView extends CollapsibleView { // Subsequent refresh: Merge stat into our local model and refresh tree modelStats.forEach((modelStat, index) => FileStat.mergeLocalWithDisk(modelStat, this.model.roots[index])); - if (this.isCreated) { + const input = this.model.roots.length === 1 ? this.model.roots[0] : this.model; + if (input === this.explorerViewer.getInput()) { return this.explorerViewer.refresh(); } // First time refresh: The stat becomes the input of the viewer // Display roots only when there is more than 1 root - return this.explorerViewer.setInput(this.model.roots.length === 1 ? this.model.roots[0] : this.model).then(() => { + return this.explorerViewer.setInput(input).then(() => { // Make sure to expand all folders that where expanded in the previous session if (targetsToExpand) { -- GitLab From 644a48af847c31e39d6609cd9979eadde4756ab0 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 16 Jun 2017 15:30:12 +0200 Subject: [PATCH 0957/1347] fix #28880 --- .../contrib/zoneWidget/browser/zoneWidget.css | 7 -- .../contrib/zoneWidget/browser/zoneWidget.ts | 92 ++++++++++++++----- 2 files changed, 69 insertions(+), 30 deletions(-) diff --git a/src/vs/editor/contrib/zoneWidget/browser/zoneWidget.css b/src/vs/editor/contrib/zoneWidget/browser/zoneWidget.css index 38b3e43abd8..b9d960656ed 100644 --- a/src/vs/editor/contrib/zoneWidget/browser/zoneWidget.css +++ b/src/vs/editor/contrib/zoneWidget/browser/zoneWidget.css @@ -7,13 +7,6 @@ z-index: 10; } -.monaco-editor .zone-widget-arrow.below { - width: 0; - height: 0; - border-color: transparent; - border-style: solid; - position: absolute; -} .monaco-editor .zone-widget .zone-widget-container { border-top-style: solid; diff --git a/src/vs/editor/contrib/zoneWidget/browser/zoneWidget.ts b/src/vs/editor/contrib/zoneWidget/browser/zoneWidget.ts index 4764ae690e5..eabf84bb282 100644 --- a/src/vs/editor/contrib/zoneWidget/browser/zoneWidget.ts +++ b/src/vs/editor/contrib/zoneWidget/browser/zoneWidget.ts @@ -17,6 +17,7 @@ import { Color, RGBA } from 'vs/base/common/color'; import { EditorLayoutInfo } from 'vs/editor/common/config/editorOptions'; import { Position, IPosition } from 'vs/editor/common/core/position'; import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; +import { IdGenerator } from "vs/base/common/idGenerator"; export interface IOptions { showFrame?: boolean; @@ -99,23 +100,77 @@ export class OverlayWidgetDelegate implements IOverlayWidget { public getPosition(): IOverlayWidgetPosition { return null; } +} + +class Arrow { + + private static _IdGenerator = new IdGenerator('.arrow-decoration-'); + + private readonly _ruleName = Arrow._IdGenerator.nextId(); + private _decorations: string[] = []; + private _color: string; + private _height: number; + + constructor( + private readonly _editor: ICodeEditor + ) { + // + } + + dispose(): void { + this.hide(); + dom.removeCSSRulesContainingSelector(this._ruleName); + } + + set color(value: string) { + if (this._color !== value) { + this._color = value; + this._updateStyle(); + } + } + + set height(value: number) { + if (this._height !== value) { + this._height = value; + this._updateStyle(); + } + } + + private _updateStyle(): void { + dom.removeCSSRulesContainingSelector(this._ruleName); + dom.createCSSRule( + `.monaco-editor ${this._ruleName}`, + `border-style: solid; border-color: transparent; border-bottom-color: ${this._color}; border-width: ${this._height}px; bottom: -${this._height}px; margin-left: -${this._height}px; ` + ); + } + show(where: IPosition): void { + this._decorations = this._editor.deltaDecorations( + this._decorations, + [{ range: Range.fromPositions(where), options: { className: this._ruleName } }] + ); + } + + hide(): void { + this._editor.deltaDecorations(this._decorations, []); + } } export abstract class ZoneWidget extends Widget implements IHorizontalSashLayoutProvider { - private _overlayWidget: OverlayWidgetDelegate = null; + private _arrow: Arrow; + private _overlayWidget: OverlayWidgetDelegate; private _resizeSash: Sash; private _positionMarkerId: string[] = []; - protected _viewZone: ViewZoneDelegate = null; + protected _viewZone: ViewZoneDelegate; protected _disposables: IDisposable[] = []; - public container: HTMLElement = null; + public container: HTMLElement; public domNode: HTMLElement; public editor: ICodeEditor; public options: IOptions; - private arrow: HTMLElement = null; + constructor(editor: ICodeEditor, options: IOptions = {}) { super(); @@ -163,8 +218,8 @@ export abstract class ZoneWidget extends Widget implements IHorizontalSashLayout dom.addClass(this.container, 'zone-widget-container'); this.domNode.appendChild(this.container); if (this.options.showArrow) { - this.arrow = document.createElement('div'); - this.arrow.className = 'zone-widget-arrow below'; + this._arrow = new Arrow(this.editor); + this._disposables.push(this._arrow); } this._fillContainer(this.container); this._initSash(); @@ -187,9 +242,9 @@ export abstract class ZoneWidget extends Widget implements IHorizontalSashLayout this.container.style.borderTopColor = frameColor; this.container.style.borderBottomColor = frameColor; } - if (this.arrow) { + if (this._arrow) { let arrowColor = this.options.arrowColor.toString(); - this.arrow.style.borderBottomColor = arrowColor; + this._arrow.color = arrowColor; } } @@ -243,6 +298,9 @@ export abstract class ZoneWidget extends Widget implements IHorizontalSashLayout this.editor.removeOverlayWidget(this._overlayWidget); this._overlayWidget = null; } + if (this._arrow) { + this._arrow.hide(); + } } private _decoratingElementsHeight(): number { @@ -271,9 +329,6 @@ export abstract class ZoneWidget extends Widget implements IHorizontalSashLayout const width = this._getWidth(); this.domNode.style.width = `${width}px`; - // Reveal position, to get the line rendered, such that the arrow can be positioned properly - this.editor.revealPosition(position); - // Render the widget as zone (rendering) and widget (lifecycle) const viewZoneDomNode = document.createElement('div'); viewZoneDomNode.style.overflow = 'hidden'; @@ -291,11 +346,8 @@ export abstract class ZoneWidget extends Widget implements IHorizontalSashLayout // Render the arrow one 1/3 of an editor line height if (this.options.showArrow) { arrowHeight = Math.round(lineHeight / 3); - this.arrow.style.top = -arrowHeight + 'px'; - this.arrow.style.borderWidth = arrowHeight + 'px'; - this.arrow.style.left = this.editor.getOffsetForColumn(position.lineNumber, position.column) + 'px'; - - viewZoneDomNode.appendChild(this.arrow); + this._arrow.height = arrowHeight; + this._arrow.show(position); } // Render the frame as 1/9 of an editor line height @@ -326,7 +378,6 @@ export abstract class ZoneWidget extends Widget implements IHorizontalSashLayout this.editor.addOverlayWidget(this._overlayWidget); }); - if (this.options.showFrame) { const width = this.options.frameWidth ? this.options.frameWidth : frameThickness; this.container.style.borderTopWidth = width + 'px'; @@ -351,15 +402,10 @@ export abstract class ZoneWidget extends Widget implements IHorizontalSashLayout protected setCssClass(className: string, classToReplace?: string): void { if (classToReplace) { this.container.classList.remove(classToReplace); - if (this.arrow) { - this.arrow.classList.remove(classToReplace); - } } dom.addClass(this.container, className); - if (this.arrow) { - dom.addClass(this.arrow, className); - } + } protected abstract _fillContainer(container: HTMLElement): void; -- GitLab From 3370fc8a0e1de103bf86281517461891a52cd78d Mon Sep 17 00:00:00 2001 From: isidor Date: Fri, 16 Jun 2017 15:30:31 +0200 Subject: [PATCH 0958/1347] fix revealing of elements --- .../workbench/parts/files/browser/views/explorerViewer.ts | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts index 79da4419afe..53df7dd08af 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts @@ -122,19 +122,18 @@ export class FileDataSource implements IDataSource { } } - public getParent(tree: ITree, stat: FileStat): TPromise { + public getParent(tree: ITree, stat: FileStat | Model): TPromise { if (!stat) { return TPromise.as(null); // can be null if nothing selected in the tree } // Return if root reached - const workspace = this.contextService.getWorkspace2(); - if (workspace && workspace.roots.filter(root => root.toString() === stat.resource.toString())) { + if (tree.getInput() === stat) { return TPromise.as(null); } // Return if parent already resolved - if (stat.parent) { + if (stat instanceof FileStat && stat.parent) { return TPromise.as(stat.parent); } -- GitLab From a416029addda0e965ce7ddfac5daa24316703b5d Mon Sep 17 00:00:00 2001 From: isidor Date: Fri, 16 Jun 2017 15:48:53 +0200 Subject: [PATCH 0959/1347] fix drag and drop --- .../parts/files/browser/views/explorerViewer.ts | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts index 53df7dd08af..16708df7b4f 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts @@ -636,6 +636,9 @@ export class FileDragAndDrop implements IDragAndDrop { } public getDragURI(tree: ITree, stat: FileStat): string { + if (this.contextService.getWorkspace2().roots.some(r => r.toString() === stat.resource.toString())) { + return null; // Can not move root folder + } if (stat.isDirectory) { return URI.from({ scheme: 'folder', path: stat.resource.fsPath }).toString(); // indicates that we are dragging a folder } @@ -673,8 +676,8 @@ export class FileDragAndDrop implements IDragAndDrop { } } - public onDragOver(tree: ITree, data: IDragAndDropData, target: FileStat, originalEvent: DragMouseEvent): IDragOverReaction { - if (!this.dropEnabled) { + public onDragOver(tree: ITree, data: IDragAndDropData, target: FileStat | Model, originalEvent: DragMouseEvent): IDragOverReaction { + if (!this.dropEnabled || target instanceof Model) { return DRAG_OVER_REJECT; } @@ -736,8 +739,8 @@ export class FileDragAndDrop implements IDragAndDrop { return fromDesktop || isCopy ? DRAG_OVER_ACCEPT_BUBBLE_DOWN_COPY(true) : DRAG_OVER_ACCEPT_BUBBLE_DOWN(true); } - const workspace = this.contextService.getWorkspace(); - if (workspace && target.resource.toString() !== workspace.resource.toString()) { + const workspace = this.contextService.getWorkspace2(); + if (workspace && workspace.roots.every(r => r.toString() !== target.resource.toString())) { return fromDesktop || isCopy ? DRAG_OVER_ACCEPT_BUBBLE_UP_COPY : DRAG_OVER_ACCEPT_BUBBLE_UP; } -- GitLab From 8c7689c9252919b785029d882bef442c08f23e06 Mon Sep 17 00:00:00 2001 From: Joao Moreno Date: Fri, 16 Jun 2017 16:09:03 +0200 Subject: [PATCH 0960/1347] fixes #28650 --- build/lib/nls.js | 26 +- build/lib/nls.ts | 9 +- build/lib/typescript/OSSREADME.json | 70 - build/lib/typescript/typescriptServices.d.ts | 1994 - build/lib/typescript/typescriptServices.js | 44323 ----------------- 5 files changed, 22 insertions(+), 46400 deletions(-) delete mode 100644 build/lib/typescript/OSSREADME.json delete mode 100644 build/lib/typescript/typescriptServices.d.ts delete mode 100644 build/lib/typescript/typescriptServices.js diff --git a/build/lib/nls.js b/build/lib/nls.js index da8e6a27a53..99a77feb182 100644 --- a/build/lib/nls.js +++ b/build/lib/nls.js @@ -1,5 +1,9 @@ "use strict"; -var ts = require("./typescript/typescriptServices"); +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +var ts = require("typescript"); var lazy = require("lazy.js"); var event_stream_1 = require("event-stream"); var File = require("vinyl"); @@ -69,7 +73,7 @@ function nls() { return event_stream_1.duplex(input, output); } function isImportNode(node) { - return node.kind === 212 /* ImportDeclaration */ || node.kind === 211 /* ImportEqualsDeclaration */; + return node.kind === ts.SyntaxKind.ImportDeclaration || node.kind === ts.SyntaxKind.ImportEqualsDeclaration; } (function (nls_1) { function fileFrom(file, contents, path) { @@ -111,27 +115,27 @@ function isImportNode(node) { if (!ts.textSpanContainsTextSpan({ start: node.pos, length: node.end - node.pos }, textSpan)) { return CollectStepResult.No; } - return node.kind === 160 /* CallExpression */ ? CollectStepResult.YesAndRecurse : CollectStepResult.NoAndRecurse; + return node.kind === ts.SyntaxKind.CallExpression ? CollectStepResult.YesAndRecurse : CollectStepResult.NoAndRecurse; } function analyze(contents, options) { if (options === void 0) { options = {}; } var filename = 'file.ts'; var serviceHost = new SingleFileServiceHost(assign(clone(options), { noResolve: true }), filename, contents); var service = ts.createLanguageService(serviceHost); - var sourceFile = service.getSourceFile(filename); + var sourceFile = ts.createSourceFile(filename, contents, ts.ScriptTarget.ES5, true); // all imports var imports = lazy(collect(sourceFile, function (n) { return isImportNode(n) ? CollectStepResult.YesAndRecurse : CollectStepResult.NoAndRecurse; })); // import nls = require('vs/nls'); var importEqualsDeclarations = imports - .filter(function (n) { return n.kind === 211 /* ImportEqualsDeclaration */; }) + .filter(function (n) { return n.kind === ts.SyntaxKind.ImportEqualsDeclaration; }) .map(function (n) { return n; }) - .filter(function (d) { return d.moduleReference.kind === 222 /* ExternalModuleReference */; }) + .filter(function (d) { return d.moduleReference.kind === ts.SyntaxKind.ExternalModuleReference; }) .filter(function (d) { return d.moduleReference.expression.getText() === '\'vs/nls\''; }); // import ... from 'vs/nls'; var importDeclarations = imports - .filter(function (n) { return n.kind === 212 /* ImportDeclaration */; }) + .filter(function (n) { return n.kind === ts.SyntaxKind.ImportDeclaration; }) .map(function (n) { return n; }) - .filter(function (d) { return d.moduleSpecifier.kind === 8 /* StringLiteral */; }) + .filter(function (d) { return d.moduleSpecifier.kind === ts.SyntaxKind.StringLiteral; }) .filter(function (d) { return d.moduleSpecifier.getText() === '\'vs/nls\''; }) .filter(function (d) { return !!d.importClause && !!d.importClause.namedBindings; }); var nlsExpressions = importEqualsDeclarations @@ -143,7 +147,7 @@ function isImportNode(node) { }); }); // `nls.localize(...)` calls var nlsLocalizeCallExpressions = importDeclarations - .filter(function (d) { return d.importClause.namedBindings.kind === 214 /* NamespaceImport */; }) + .filter(function (d) { return d.importClause.namedBindings.kind === ts.SyntaxKind.NamespaceImport; }) .map(function (d) { return d.importClause.namedBindings.name; }) .concat(importEqualsDeclarations.map(function (d) { return d.name; })) .map(function (n) { return service.getReferencesAtPosition(filename, n.pos + 1); }) @@ -153,10 +157,10 @@ function isImportNode(node) { .map(function (a) { return lazy(a).last(); }) .filter(function (n) { return !!n; }) .map(function (n) { return n; }) - .filter(function (n) { return n.expression.kind === 158 /* PropertyAccessExpression */ && n.expression.name.getText() === 'localize'; }); + .filter(function (n) { return n.expression.kind === ts.SyntaxKind.PropertyAccessExpression && n.expression.name.getText() === 'localize'; }); // `localize` named imports var allLocalizeImportDeclarations = importDeclarations - .filter(function (d) { return d.importClause.namedBindings.kind === 215 /* NamedImports */; }) + .filter(function (d) { return d.importClause.namedBindings.kind === ts.SyntaxKind.NamedImports; }) .map(function (d) { return d.importClause.namedBindings.elements; }) .flatten(); // `localize` read-only references diff --git a/build/lib/nls.ts b/build/lib/nls.ts index 9fdc15dd0e7..fcba7ac6e5e 100644 --- a/build/lib/nls.ts +++ b/build/lib/nls.ts @@ -1,4 +1,9 @@ -import * as ts from './typescript/typescriptServices'; +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +import * as ts from 'typescript'; import * as lazy from 'lazy.js'; import { duplex, through } from 'event-stream'; import File = require('vinyl'); @@ -171,7 +176,7 @@ module nls { const filename = 'file.ts'; const serviceHost = new SingleFileServiceHost(assign(clone(options), { noResolve: true }), filename, contents); const service = ts.createLanguageService(serviceHost); - const sourceFile = service.getSourceFile(filename); + const sourceFile = ts.createSourceFile(filename, contents, ts.ScriptTarget.ES5, true); // all imports const imports = lazy(collect(sourceFile, n => isImportNode(n) ? CollectStepResult.YesAndRecurse : CollectStepResult.NoAndRecurse)); diff --git a/build/lib/typescript/OSSREADME.json b/build/lib/typescript/OSSREADME.json deleted file mode 100644 index 6fa824225ad..00000000000 --- a/build/lib/typescript/OSSREADME.json +++ /dev/null @@ -1,70 +0,0 @@ -// ATTENTION - THIS DIRECTORY CONTAINS THIRD PARTY OPEN SOURCE MATERIALS: -[ - { - "name": "typescript-legacy", - "version": "1.5", - "license": "Apache2", - "repositoryURL": "https://github.com/Microsoft/TypeScript", - // Reason: LICENSE file does not include Copyright statement - "licenseDetail": [ - "Copyright (c) Microsoft Corporation. All rights reserved. ", - "", - "Apache License", - "", - "Version 2.0, January 2004", - "", - "http://www.apache.org/licenses/", - "", - "TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION", - "", - "1. Definitions.", - "", - "\"License\" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document.", - "", - "\"Licensor\" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License.", - "", - "\"Legal Entity\" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, \"control\" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity.", - "", - "\"You\" (or \"Your\") shall mean an individual or Legal Entity exercising permissions granted by this License.", - "", - "\"Source\" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files.", - "", - "\"Object\" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types.", - "", - "\"Work\" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below).", - "", - "\"Derivative Works\" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof.", - "", - "\"Contribution\" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, \"submitted\" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as \"Not a Contribution.\"", - "", - "\"Contributor\" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work.", - "", - "2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form.", - "", - "3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed.", - "", - "4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions:", - "", - "You must give any other recipients of the Work or Derivative Works a copy of this License; and", - "", - "You must cause any modified files to carry prominent notices stating that You changed the files; and", - "", - "You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and", - "", - "If the Work includes a \"NOTICE\" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License.", - "", - "5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions.", - "", - "6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file.", - "", - "7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License.", - "", - "8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages.", - "", - "9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability.", - "", - "END OF TERMS AND CONDITIONS" - ], - "isDev": true - } -] \ No newline at end of file diff --git a/build/lib/typescript/typescriptServices.d.ts b/build/lib/typescript/typescriptServices.d.ts deleted file mode 100644 index 9b5cf8c4d50..00000000000 --- a/build/lib/typescript/typescriptServices.d.ts +++ /dev/null @@ -1,1994 +0,0 @@ -/*! ***************************************************************************** -Copyright (c) Microsoft Corporation. All rights reserved. -Licensed under the Apache License, Version 2.0 (the "License"); you may not use -this file except in compliance with the License. You may obtain a copy of the -License at http://www.apache.org/licenses/LICENSE-2.0 - -THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED -WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE, -MERCHANTABLITY OR NON-INFRINGEMENT. - -See the Apache Version 2.0 License for specific language governing permissions -and limitations under the License. -***************************************************************************** */ - -declare module ts { - interface Map { - [index: string]: T; - } - interface FileMap { - get(fileName: string): T; - set(fileName: string, value: T): void; - contains(fileName: string): boolean; - remove(fileName: string): void; - forEachValue(f: (v: T) => void): void; - } - interface TextRange { - pos: number; - end: number; - } - const enum SyntaxKind { - Unknown = 0, - EndOfFileToken = 1, - SingleLineCommentTrivia = 2, - MultiLineCommentTrivia = 3, - NewLineTrivia = 4, - WhitespaceTrivia = 5, - ConflictMarkerTrivia = 6, - NumericLiteral = 7, - StringLiteral = 8, - RegularExpressionLiteral = 9, - NoSubstitutionTemplateLiteral = 10, - TemplateHead = 11, - TemplateMiddle = 12, - TemplateTail = 13, - OpenBraceToken = 14, - CloseBraceToken = 15, - OpenParenToken = 16, - CloseParenToken = 17, - OpenBracketToken = 18, - CloseBracketToken = 19, - DotToken = 20, - DotDotDotToken = 21, - SemicolonToken = 22, - CommaToken = 23, - LessThanToken = 24, - GreaterThanToken = 25, - LessThanEqualsToken = 26, - GreaterThanEqualsToken = 27, - EqualsEqualsToken = 28, - ExclamationEqualsToken = 29, - EqualsEqualsEqualsToken = 30, - ExclamationEqualsEqualsToken = 31, - EqualsGreaterThanToken = 32, - PlusToken = 33, - MinusToken = 34, - AsteriskToken = 35, - SlashToken = 36, - PercentToken = 37, - PlusPlusToken = 38, - MinusMinusToken = 39, - LessThanLessThanToken = 40, - GreaterThanGreaterThanToken = 41, - GreaterThanGreaterThanGreaterThanToken = 42, - AmpersandToken = 43, - BarToken = 44, - CaretToken = 45, - ExclamationToken = 46, - TildeToken = 47, - AmpersandAmpersandToken = 48, - BarBarToken = 49, - QuestionToken = 50, - ColonToken = 51, - AtToken = 52, - EqualsToken = 53, - PlusEqualsToken = 54, - MinusEqualsToken = 55, - AsteriskEqualsToken = 56, - SlashEqualsToken = 57, - PercentEqualsToken = 58, - LessThanLessThanEqualsToken = 59, - GreaterThanGreaterThanEqualsToken = 60, - GreaterThanGreaterThanGreaterThanEqualsToken = 61, - AmpersandEqualsToken = 62, - BarEqualsToken = 63, - CaretEqualsToken = 64, - Identifier = 65, - BreakKeyword = 66, - CaseKeyword = 67, - CatchKeyword = 68, - ClassKeyword = 69, - ConstKeyword = 70, - ContinueKeyword = 71, - DebuggerKeyword = 72, - DefaultKeyword = 73, - DeleteKeyword = 74, - DoKeyword = 75, - ElseKeyword = 76, - EnumKeyword = 77, - ExportKeyword = 78, - ExtendsKeyword = 79, - FalseKeyword = 80, - FinallyKeyword = 81, - ForKeyword = 82, - FunctionKeyword = 83, - IfKeyword = 84, - ImportKeyword = 85, - InKeyword = 86, - InstanceOfKeyword = 87, - NewKeyword = 88, - NullKeyword = 89, - ReturnKeyword = 90, - SuperKeyword = 91, - SwitchKeyword = 92, - ThisKeyword = 93, - ThrowKeyword = 94, - TrueKeyword = 95, - TryKeyword = 96, - TypeOfKeyword = 97, - VarKeyword = 98, - VoidKeyword = 99, - WhileKeyword = 100, - WithKeyword = 101, - ImplementsKeyword = 102, - InterfaceKeyword = 103, - LetKeyword = 104, - PackageKeyword = 105, - PrivateKeyword = 106, - ProtectedKeyword = 107, - PublicKeyword = 108, - StaticKeyword = 109, - YieldKeyword = 110, - AsKeyword = 111, - AnyKeyword = 112, - BooleanKeyword = 113, - ConstructorKeyword = 114, - DeclareKeyword = 115, - GetKeyword = 116, - IsKeyword = 117, - ModuleKeyword = 118, - NamespaceKeyword = 119, - RequireKeyword = 120, - NumberKeyword = 121, - SetKeyword = 122, - StringKeyword = 123, - SymbolKeyword = 124, - TypeKeyword = 125, - FromKeyword = 126, - OfKeyword = 127, - QualifiedName = 128, - ComputedPropertyName = 129, - TypeParameter = 130, - Parameter = 131, - Decorator = 132, - PropertySignature = 133, - PropertyDeclaration = 134, - MethodSignature = 135, - MethodDeclaration = 136, - Constructor = 137, - GetAccessor = 138, - SetAccessor = 139, - CallSignature = 140, - ConstructSignature = 141, - IndexSignature = 142, - TypePredicate = 143, - TypeReference = 144, - FunctionType = 145, - ConstructorType = 146, - TypeQuery = 147, - TypeLiteral = 148, - ArrayType = 149, - TupleType = 150, - UnionType = 151, - ParenthesizedType = 152, - ObjectBindingPattern = 153, - ArrayBindingPattern = 154, - BindingElement = 155, - ArrayLiteralExpression = 156, - ObjectLiteralExpression = 157, - PropertyAccessExpression = 158, - ElementAccessExpression = 159, - CallExpression = 160, - NewExpression = 161, - TaggedTemplateExpression = 162, - TypeAssertionExpression = 163, - ParenthesizedExpression = 164, - FunctionExpression = 165, - ArrowFunction = 166, - DeleteExpression = 167, - TypeOfExpression = 168, - VoidExpression = 169, - PrefixUnaryExpression = 170, - PostfixUnaryExpression = 171, - BinaryExpression = 172, - ConditionalExpression = 173, - TemplateExpression = 174, - YieldExpression = 175, - SpreadElementExpression = 176, - ClassExpression = 177, - OmittedExpression = 178, - ExpressionWithTypeArguments = 179, - TemplateSpan = 180, - SemicolonClassElement = 181, - Block = 182, - VariableStatement = 183, - EmptyStatement = 184, - ExpressionStatement = 185, - IfStatement = 186, - DoStatement = 187, - WhileStatement = 188, - ForStatement = 189, - ForInStatement = 190, - ForOfStatement = 191, - ContinueStatement = 192, - BreakStatement = 193, - ReturnStatement = 194, - WithStatement = 195, - SwitchStatement = 196, - LabeledStatement = 197, - ThrowStatement = 198, - TryStatement = 199, - DebuggerStatement = 200, - VariableDeclaration = 201, - VariableDeclarationList = 202, - FunctionDeclaration = 203, - ClassDeclaration = 204, - InterfaceDeclaration = 205, - TypeAliasDeclaration = 206, - EnumDeclaration = 207, - ModuleDeclaration = 208, - ModuleBlock = 209, - CaseBlock = 210, - ImportEqualsDeclaration = 211, - ImportDeclaration = 212, - ImportClause = 213, - NamespaceImport = 214, - NamedImports = 215, - ImportSpecifier = 216, - ExportAssignment = 217, - ExportDeclaration = 218, - NamedExports = 219, - ExportSpecifier = 220, - MissingDeclaration = 221, - ExternalModuleReference = 222, - CaseClause = 223, - DefaultClause = 224, - HeritageClause = 225, - CatchClause = 226, - PropertyAssignment = 227, - ShorthandPropertyAssignment = 228, - EnumMember = 229, - SourceFile = 230, - JSDocTypeExpression = 231, - JSDocAllType = 232, - JSDocUnknownType = 233, - JSDocArrayType = 234, - JSDocUnionType = 235, - JSDocTupleType = 236, - JSDocNullableType = 237, - JSDocNonNullableType = 238, - JSDocRecordType = 239, - JSDocRecordMember = 240, - JSDocTypeReference = 241, - JSDocOptionalType = 242, - JSDocFunctionType = 243, - JSDocVariadicType = 244, - JSDocConstructorType = 245, - JSDocThisType = 246, - JSDocComment = 247, - JSDocTag = 248, - JSDocParameterTag = 249, - JSDocReturnTag = 250, - JSDocTypeTag = 251, - JSDocTemplateTag = 252, - SyntaxList = 253, - Count = 254, - FirstAssignment = 53, - LastAssignment = 64, - FirstReservedWord = 66, - LastReservedWord = 101, - FirstKeyword = 66, - LastKeyword = 127, - FirstFutureReservedWord = 102, - LastFutureReservedWord = 110, - FirstTypeNode = 144, - LastTypeNode = 152, - FirstPunctuation = 14, - LastPunctuation = 64, - FirstToken = 0, - LastToken = 127, - FirstTriviaToken = 2, - LastTriviaToken = 6, - FirstLiteralToken = 7, - LastLiteralToken = 10, - FirstTemplateToken = 10, - LastTemplateToken = 13, - FirstBinaryOperator = 24, - LastBinaryOperator = 64, - FirstNode = 128, - } - const enum NodeFlags { - Export = 1, - Ambient = 2, - Public = 16, - Private = 32, - Protected = 64, - Static = 128, - Default = 256, - MultiLine = 512, - Synthetic = 1024, - DeclarationFile = 2048, - Let = 4096, - Const = 8192, - OctalLiteral = 16384, - Namespace = 32768, - ExportContext = 65536, - Modifier = 499, - AccessibilityModifier = 112, - BlockScoped = 12288, - } - interface Node extends TextRange { - kind: SyntaxKind; - flags: NodeFlags; - decorators?: NodeArray; - modifiers?: ModifiersArray; - parent?: Node; - } - interface NodeArray extends Array, TextRange { - hasTrailingComma?: boolean; - } - interface ModifiersArray extends NodeArray { - flags: number; - } - interface Identifier extends PrimaryExpression { - text: string; - originalKeywordKind?: SyntaxKind; - } - interface QualifiedName extends Node { - left: EntityName; - right: Identifier; - } - type EntityName = Identifier | QualifiedName; - type DeclarationName = Identifier | LiteralExpression | ComputedPropertyName | BindingPattern; - interface Declaration extends Node { - _declarationBrand: any; - name?: DeclarationName; - } - interface ComputedPropertyName extends Node { - expression: Expression; - } - interface Decorator extends Node { - expression: LeftHandSideExpression; - } - interface TypeParameterDeclaration extends Declaration { - name: Identifier; - constraint?: TypeNode; - expression?: Expression; - } - interface SignatureDeclaration extends Declaration { - typeParameters?: NodeArray; - parameters: NodeArray; - type?: TypeNode; - } - interface VariableDeclaration extends Declaration { - parent?: VariableDeclarationList; - name: Identifier | BindingPattern; - type?: TypeNode; - initializer?: Expression; - } - interface VariableDeclarationList extends Node { - declarations: NodeArray; - } - interface ParameterDeclaration extends Declaration { - dotDotDotToken?: Node; - name: Identifier | BindingPattern; - questionToken?: Node; - type?: TypeNode; - initializer?: Expression; - } - interface BindingElement extends Declaration { - propertyName?: Identifier; - dotDotDotToken?: Node; - name: Identifier | BindingPattern; - initializer?: Expression; - } - interface PropertyDeclaration extends Declaration, ClassElement { - name: DeclarationName; - questionToken?: Node; - type?: TypeNode; - initializer?: Expression; - } - interface ObjectLiteralElement extends Declaration { - _objectLiteralBrandBrand: any; - } - interface PropertyAssignment extends ObjectLiteralElement { - _propertyAssignmentBrand: any; - name: DeclarationName; - questionToken?: Node; - initializer: Expression; - } - interface ShorthandPropertyAssignment extends ObjectLiteralElement { - name: Identifier; - questionToken?: Node; - } - interface VariableLikeDeclaration extends Declaration { - propertyName?: Identifier; - dotDotDotToken?: Node; - name: DeclarationName; - questionToken?: Node; - type?: TypeNode; - initializer?: Expression; - } - interface BindingPattern extends Node { - elements: NodeArray; - } - /** - * Several node kinds share function-like features such as a signature, - * a name, and a body. These nodes should extend FunctionLikeDeclaration. - * Examples: - * FunctionDeclaration - * MethodDeclaration - * AccessorDeclaration - */ - interface FunctionLikeDeclaration extends SignatureDeclaration { - _functionLikeDeclarationBrand: any; - asteriskToken?: Node; - questionToken?: Node; - body?: Block | Expression; - } - interface FunctionDeclaration extends FunctionLikeDeclaration, Statement { - name?: Identifier; - body?: Block; - } - interface MethodDeclaration extends FunctionLikeDeclaration, ClassElement, ObjectLiteralElement { - body?: Block; - } - interface ConstructorDeclaration extends FunctionLikeDeclaration, ClassElement { - body?: Block; - } - interface SemicolonClassElement extends ClassElement { - _semicolonClassElementBrand: any; - } - interface AccessorDeclaration extends FunctionLikeDeclaration, ClassElement, ObjectLiteralElement { - _accessorDeclarationBrand: any; - body: Block; - } - interface IndexSignatureDeclaration extends SignatureDeclaration, ClassElement { - _indexSignatureDeclarationBrand: any; - } - interface TypeNode extends Node { - _typeNodeBrand: any; - } - interface FunctionOrConstructorTypeNode extends TypeNode, SignatureDeclaration { - _functionOrConstructorTypeNodeBrand: any; - } - interface TypeReferenceNode extends TypeNode { - typeName: EntityName; - typeArguments?: NodeArray; - } - interface TypePredicateNode extends TypeNode { - parameterName: Identifier; - type: TypeNode; - } - interface TypeQueryNode extends TypeNode { - exprName: EntityName; - } - interface TypeLiteralNode extends TypeNode, Declaration { - members: NodeArray; - } - interface ArrayTypeNode extends TypeNode { - elementType: TypeNode; - } - interface TupleTypeNode extends TypeNode { - elementTypes: NodeArray; - } - interface UnionTypeNode extends TypeNode { - types: NodeArray; - } - interface ParenthesizedTypeNode extends TypeNode { - type: TypeNode; - } - interface StringLiteral extends LiteralExpression, TypeNode { - _stringLiteralBrand: any; - } - interface Expression extends Node { - _expressionBrand: any; - contextualType?: Type; - } - interface UnaryExpression extends Expression { - _unaryExpressionBrand: any; - } - interface PrefixUnaryExpression extends UnaryExpression { - operator: SyntaxKind; - operand: UnaryExpression; - } - interface PostfixUnaryExpression extends PostfixExpression { - operand: LeftHandSideExpression; - operator: SyntaxKind; - } - interface PostfixExpression extends UnaryExpression { - _postfixExpressionBrand: any; - } - interface LeftHandSideExpression extends PostfixExpression { - _leftHandSideExpressionBrand: any; - } - interface MemberExpression extends LeftHandSideExpression { - _memberExpressionBrand: any; - } - interface PrimaryExpression extends MemberExpression { - _primaryExpressionBrand: any; - } - interface DeleteExpression extends UnaryExpression { - expression: UnaryExpression; - } - interface TypeOfExpression extends UnaryExpression { - expression: UnaryExpression; - } - interface VoidExpression extends UnaryExpression { - expression: UnaryExpression; - } - interface YieldExpression extends Expression { - asteriskToken?: Node; - expression?: Expression; - } - interface BinaryExpression extends Expression { - left: Expression; - operatorToken: Node; - right: Expression; - } - interface ConditionalExpression extends Expression { - condition: Expression; - questionToken: Node; - whenTrue: Expression; - colonToken: Node; - whenFalse: Expression; - } - interface FunctionExpression extends PrimaryExpression, FunctionLikeDeclaration { - name?: Identifier; - body: Block | Expression; - } - interface ArrowFunction extends Expression, FunctionLikeDeclaration { - equalsGreaterThanToken: Node; - } - interface LiteralExpression extends PrimaryExpression { - text: string; - isUnterminated?: boolean; - hasExtendedUnicodeEscape?: boolean; - } - interface TemplateExpression extends PrimaryExpression { - head: LiteralExpression; - templateSpans: NodeArray; - } - interface TemplateSpan extends Node { - expression: Expression; - literal: LiteralExpression; - } - interface ParenthesizedExpression extends PrimaryExpression { - expression: Expression; - } - interface ArrayLiteralExpression extends PrimaryExpression { - elements: NodeArray; - } - interface SpreadElementExpression extends Expression { - expression: Expression; - } - interface ObjectLiteralExpression extends PrimaryExpression, Declaration { - properties: NodeArray; - } - interface PropertyAccessExpression extends MemberExpression { - expression: LeftHandSideExpression; - dotToken: Node; - name: Identifier; - } - interface ElementAccessExpression extends MemberExpression { - expression: LeftHandSideExpression; - argumentExpression?: Expression; - } - interface CallExpression extends LeftHandSideExpression { - expression: LeftHandSideExpression; - typeArguments?: NodeArray; - arguments: NodeArray; - } - interface ExpressionWithTypeArguments extends TypeNode { - expression: LeftHandSideExpression; - typeArguments?: NodeArray; - } - interface NewExpression extends CallExpression, PrimaryExpression { - } - interface TaggedTemplateExpression extends MemberExpression { - tag: LeftHandSideExpression; - template: LiteralExpression | TemplateExpression; - } - type CallLikeExpression = CallExpression | NewExpression | TaggedTemplateExpression; - interface TypeAssertion extends UnaryExpression { - type: TypeNode; - expression: UnaryExpression; - } - interface Statement extends Node { - _statementBrand: any; - } - interface Block extends Statement { - statements: NodeArray; - } - interface VariableStatement extends Statement { - declarationList: VariableDeclarationList; - } - interface ExpressionStatement extends Statement { - expression: Expression; - } - interface IfStatement extends Statement { - expression: Expression; - thenStatement: Statement; - elseStatement?: Statement; - } - interface IterationStatement extends Statement { - statement: Statement; - } - interface DoStatement extends IterationStatement { - expression: Expression; - } - interface WhileStatement extends IterationStatement { - expression: Expression; - } - interface ForStatement extends IterationStatement { - initializer?: VariableDeclarationList | Expression; - condition?: Expression; - incrementor?: Expression; - } - interface ForInStatement extends IterationStatement { - initializer: VariableDeclarationList | Expression; - expression: Expression; - } - interface ForOfStatement extends IterationStatement { - initializer: VariableDeclarationList | Expression; - expression: Expression; - } - interface BreakOrContinueStatement extends Statement { - label?: Identifier; - } - interface ReturnStatement extends Statement { - expression?: Expression; - } - interface WithStatement extends Statement { - expression: Expression; - statement: Statement; - } - interface SwitchStatement extends Statement { - expression: Expression; - caseBlock: CaseBlock; - } - interface CaseBlock extends Node { - clauses: NodeArray; - } - interface CaseClause extends Node { - expression?: Expression; - statements: NodeArray; - } - interface DefaultClause extends Node { - statements: NodeArray; - } - type CaseOrDefaultClause = CaseClause | DefaultClause; - interface LabeledStatement extends Statement { - label: Identifier; - statement: Statement; - } - interface ThrowStatement extends Statement { - expression: Expression; - } - interface TryStatement extends Statement { - tryBlock: Block; - catchClause?: CatchClause; - finallyBlock?: Block; - } - interface CatchClause extends Node { - variableDeclaration: VariableDeclaration; - block: Block; - } - interface ClassLikeDeclaration extends Declaration { - name?: Identifier; - typeParameters?: NodeArray; - heritageClauses?: NodeArray; - members: NodeArray; - } - interface ClassDeclaration extends ClassLikeDeclaration, Statement { - } - interface ClassExpression extends ClassLikeDeclaration, PrimaryExpression { - } - interface ClassElement extends Declaration { - _classElementBrand: any; - } - interface InterfaceDeclaration extends Declaration, Statement { - name: Identifier; - typeParameters?: NodeArray; - heritageClauses?: NodeArray; - members: NodeArray; - } - interface HeritageClause extends Node { - token: SyntaxKind; - types?: NodeArray; - } - interface TypeAliasDeclaration extends Declaration, Statement { - name: Identifier; - typeParameters?: NodeArray; - type: TypeNode; - } - interface EnumMember extends Declaration { - name: DeclarationName; - initializer?: Expression; - } - interface EnumDeclaration extends Declaration, Statement { - name: Identifier; - members: NodeArray; - } - interface ModuleDeclaration extends Declaration, Statement { - name: Identifier | LiteralExpression; - body: ModuleBlock | ModuleDeclaration; - } - interface ModuleBlock extends Node, Statement { - statements: NodeArray; - } - interface ImportEqualsDeclaration extends Declaration, Statement { - name: Identifier; - moduleReference: EntityName | ExternalModuleReference; - } - interface ExternalModuleReference extends Node { - expression?: Expression; - } - interface ImportDeclaration extends Statement { - importClause?: ImportClause; - moduleSpecifier: Expression; - } - interface ImportClause extends Declaration { - name?: Identifier; - namedBindings?: NamespaceImport | NamedImports; - } - interface NamespaceImport extends Declaration { - name: Identifier; - } - interface ExportDeclaration extends Declaration, Statement { - exportClause?: NamedExports; - moduleSpecifier?: Expression; - } - interface NamedImportsOrExports extends Node { - elements: NodeArray; - } - type NamedImports = NamedImportsOrExports; - type NamedExports = NamedImportsOrExports; - interface ImportOrExportSpecifier extends Declaration { - propertyName?: Identifier; - name: Identifier; - } - type ImportSpecifier = ImportOrExportSpecifier; - type ExportSpecifier = ImportOrExportSpecifier; - interface ExportAssignment extends Declaration, Statement { - isExportEquals?: boolean; - expression: Expression; - } - interface FileReference extends TextRange { - fileName: string; - } - interface CommentRange extends TextRange { - hasTrailingNewLine?: boolean; - kind: SyntaxKind; - } - interface JSDocTypeExpression extends Node { - type: JSDocType; - } - interface JSDocType extends TypeNode { - _jsDocTypeBrand: any; - } - interface JSDocAllType extends JSDocType { - _JSDocAllTypeBrand: any; - } - interface JSDocUnknownType extends JSDocType { - _JSDocUnknownTypeBrand: any; - } - interface JSDocArrayType extends JSDocType { - elementType: JSDocType; - } - interface JSDocUnionType extends JSDocType { - types: NodeArray; - } - interface JSDocTupleType extends JSDocType { - types: NodeArray; - } - interface JSDocNonNullableType extends JSDocType { - type: JSDocType; - } - interface JSDocNullableType extends JSDocType { - type: JSDocType; - } - interface JSDocRecordType extends JSDocType, TypeLiteralNode { - members: NodeArray; - } - interface JSDocTypeReference extends JSDocType { - name: EntityName; - typeArguments: NodeArray; - } - interface JSDocOptionalType extends JSDocType { - type: JSDocType; - } - interface JSDocFunctionType extends JSDocType, SignatureDeclaration { - parameters: NodeArray; - type: JSDocType; - } - interface JSDocVariadicType extends JSDocType { - type: JSDocType; - } - interface JSDocConstructorType extends JSDocType { - type: JSDocType; - } - interface JSDocThisType extends JSDocType { - type: JSDocType; - } - interface JSDocRecordMember extends PropertyDeclaration { - name: Identifier | LiteralExpression; - type?: JSDocType; - } - interface JSDocComment extends Node { - tags: NodeArray; - } - interface JSDocTag extends Node { - atToken: Node; - tagName: Identifier; - } - interface JSDocTemplateTag extends JSDocTag { - typeParameters: NodeArray; - } - interface JSDocReturnTag extends JSDocTag { - typeExpression: JSDocTypeExpression; - } - interface JSDocTypeTag extends JSDocTag { - typeExpression: JSDocTypeExpression; - } - interface JSDocParameterTag extends JSDocTag { - preParameterName?: Identifier; - typeExpression?: JSDocTypeExpression; - postParameterName?: Identifier; - isBracketed: boolean; - } - interface SourceFile extends Declaration { - statements: NodeArray; - endOfFileToken: Node; - fileName: string; - text: string; - amdDependencies: { - path: string; - name: string; - }[]; - moduleName: string; - referencedFiles: FileReference[]; - /** - * lib.d.ts should have a reference comment like - * - * /// - * - * If any other file has this comment, it signals not to include lib.d.ts - * because this containing file is intended to act as a default library. - */ - hasNoDefaultLib: boolean; - languageVersion: ScriptTarget; - } - interface ScriptReferenceHost { - getCompilerOptions(): CompilerOptions; - getSourceFile(fileName: string): SourceFile; - getCurrentDirectory(): string; - } - interface ParseConfigHost { - readDirectory(rootDir: string, extension: string, exclude: string[]): string[]; - } - interface WriteFileCallback { - (fileName: string, data: string, writeByteOrderMark: boolean, onError?: (message: string) => void): void; - } - interface Program extends ScriptReferenceHost { - /** - * Get a list of files in the program - */ - getSourceFiles(): SourceFile[]; - /** - * Emits the JavaScript and declaration files. If targetSourceFile is not specified, then - * the JavaScript and declaration files will be produced for all the files in this program. - * If targetSourceFile is specified, then only the JavaScript and declaration for that - * specific file will be generated. - * - * If writeFile is not specified then the writeFile callback from the compiler host will be - * used for writing the JavaScript and declaration files. Otherwise, the writeFile parameter - * will be invoked when writing the JavaScript and declaration files. - */ - emit(targetSourceFile?: SourceFile, writeFile?: WriteFileCallback): EmitResult; - getSyntacticDiagnostics(sourceFile?: SourceFile): Diagnostic[]; - getGlobalDiagnostics(): Diagnostic[]; - getSemanticDiagnostics(sourceFile?: SourceFile): Diagnostic[]; - getDeclarationDiagnostics(sourceFile?: SourceFile): Diagnostic[]; - /** - * Gets a type checker that can be used to semantically analyze source fils in the program. - */ - getTypeChecker(): TypeChecker; - } - interface SourceMapSpan { - /** Line number in the .js file. */ - emittedLine: number; - /** Column number in the .js file. */ - emittedColumn: number; - /** Line number in the .ts file. */ - sourceLine: number; - /** Column number in the .ts file. */ - sourceColumn: number; - /** Optional name (index into names array) associated with this span. */ - nameIndex?: number; - /** .ts file (index into sources array) associated with this span */ - sourceIndex: number; - } - interface SourceMapData { - sourceMapFilePath: string; - jsSourceMappingURL: string; - sourceMapFile: string; - sourceMapSourceRoot: string; - sourceMapSources: string[]; - sourceMapSourcesContent?: string[]; - inputSourceFileNames: string[]; - sourceMapNames?: string[]; - sourceMapMappings: string; - sourceMapDecodedMappings: SourceMapSpan[]; - } - /** Return code used by getEmitOutput function to indicate status of the function */ - enum ExitStatus { - Success = 0, - DiagnosticsPresent_OutputsSkipped = 1, - DiagnosticsPresent_OutputsGenerated = 2, - } - interface EmitResult { - emitSkipped: boolean; - diagnostics: Diagnostic[]; - } - interface TypeCheckerHost { - getCompilerOptions(): CompilerOptions; - getSourceFiles(): SourceFile[]; - getSourceFile(fileName: string): SourceFile; - } - interface TypeChecker { - getTypeOfSymbolAtLocation(symbol: Symbol, node: Node): Type; - getDeclaredTypeOfSymbol(symbol: Symbol): Type; - getPropertiesOfType(type: Type): Symbol[]; - getPropertyOfType(type: Type, propertyName: string): Symbol; - getSignaturesOfType(type: Type, kind: SignatureKind): Signature[]; - getIndexTypeOfType(type: Type, kind: IndexKind): Type; - getReturnTypeOfSignature(signature: Signature): Type; - getSymbolsInScope(location: Node, meaning: SymbolFlags): Symbol[]; - getSymbolAtLocation(node: Node): Symbol; - getShorthandAssignmentValueSymbol(location: Node): Symbol; - getTypeAtLocation(node: Node): Type; - typeToString(type: Type, enclosingDeclaration?: Node, flags?: TypeFormatFlags): string; - symbolToString(symbol: Symbol, enclosingDeclaration?: Node, meaning?: SymbolFlags): string; - getSymbolDisplayBuilder(): SymbolDisplayBuilder; - getFullyQualifiedName(symbol: Symbol): string; - getAugmentedPropertiesOfType(type: Type): Symbol[]; - getRootSymbols(symbol: Symbol): Symbol[]; - getContextualType(node: Expression): Type; - getResolvedSignature(node: CallLikeExpression, candidatesOutArray?: Signature[]): Signature; - getSignatureFromDeclaration(declaration: SignatureDeclaration): Signature; - isImplementationOfOverload(node: FunctionLikeDeclaration): boolean; - isUndefinedSymbol(symbol: Symbol): boolean; - isArgumentsSymbol(symbol: Symbol): boolean; - getConstantValue(node: EnumMember | PropertyAccessExpression | ElementAccessExpression): number; - isValidPropertyAccess(node: PropertyAccessExpression | QualifiedName, propertyName: string): boolean; - getAliasedSymbol(symbol: Symbol): Symbol; - getExportsOfModule(moduleSymbol: Symbol): Symbol[]; - } - interface SymbolDisplayBuilder { - buildTypeDisplay(type: Type, writer: SymbolWriter, enclosingDeclaration?: Node, flags?: TypeFormatFlags): void; - buildSymbolDisplay(symbol: Symbol, writer: SymbolWriter, enclosingDeclaration?: Node, meaning?: SymbolFlags, flags?: SymbolFormatFlags): void; - buildSignatureDisplay(signatures: Signature, writer: SymbolWriter, enclosingDeclaration?: Node, flags?: TypeFormatFlags): void; - buildParameterDisplay(parameter: Symbol, writer: SymbolWriter, enclosingDeclaration?: Node, flags?: TypeFormatFlags): void; - buildTypeParameterDisplay(tp: TypeParameter, writer: SymbolWriter, enclosingDeclaration?: Node, flags?: TypeFormatFlags): void; - buildTypeParameterDisplayFromSymbol(symbol: Symbol, writer: SymbolWriter, enclosingDeclaraiton?: Node, flags?: TypeFormatFlags): void; - buildDisplayForParametersAndDelimiters(parameters: Symbol[], writer: SymbolWriter, enclosingDeclaration?: Node, flags?: TypeFormatFlags): void; - buildDisplayForTypeParametersAndDelimiters(typeParameters: TypeParameter[], writer: SymbolWriter, enclosingDeclaration?: Node, flags?: TypeFormatFlags): void; - buildReturnTypeDisplay(signature: Signature, writer: SymbolWriter, enclosingDeclaration?: Node, flags?: TypeFormatFlags): void; - } - interface SymbolWriter { - writeKeyword(text: string): void; - writeOperator(text: string): void; - writePunctuation(text: string): void; - writeSpace(text: string): void; - writeStringLiteral(text: string): void; - writeParameter(text: string): void; - writeSymbol(text: string, symbol: Symbol): void; - writeLine(): void; - increaseIndent(): void; - decreaseIndent(): void; - clear(): void; - trackSymbol(symbol: Symbol, enclosingDeclaration?: Node, meaning?: SymbolFlags): void; - } - const enum TypeFormatFlags { - None = 0, - WriteArrayAsGenericType = 1, - UseTypeOfFunction = 2, - NoTruncation = 4, - WriteArrowStyleSignature = 8, - WriteOwnNameForAnyLike = 16, - WriteTypeArgumentsOfSignature = 32, - InElementType = 64, - UseFullyQualifiedType = 128, - } - const enum SymbolFormatFlags { - None = 0, - WriteTypeParametersOrArguments = 1, - UseOnlyExternalAliasing = 2, - } - interface TypePredicate { - parameterName: string; - parameterIndex: number; - type: Type; - } - const enum SymbolFlags { - None = 0, - FunctionScopedVariable = 1, - BlockScopedVariable = 2, - Property = 4, - EnumMember = 8, - Function = 16, - Class = 32, - Interface = 64, - ConstEnum = 128, - RegularEnum = 256, - ValueModule = 512, - NamespaceModule = 1024, - TypeLiteral = 2048, - ObjectLiteral = 4096, - Method = 8192, - Constructor = 16384, - GetAccessor = 32768, - SetAccessor = 65536, - Signature = 131072, - TypeParameter = 262144, - TypeAlias = 524288, - ExportValue = 1048576, - ExportType = 2097152, - ExportNamespace = 4194304, - Alias = 8388608, - Instantiated = 16777216, - Merged = 33554432, - Transient = 67108864, - Prototype = 134217728, - UnionProperty = 268435456, - Optional = 536870912, - ExportStar = 1073741824, - Enum = 384, - Variable = 3, - Value = 107455, - Type = 793056, - Namespace = 1536, - Module = 1536, - Accessor = 98304, - FunctionScopedVariableExcludes = 107454, - BlockScopedVariableExcludes = 107455, - ParameterExcludes = 107455, - PropertyExcludes = 107455, - EnumMemberExcludes = 107455, - FunctionExcludes = 106927, - ClassExcludes = 899583, - InterfaceExcludes = 792992, - RegularEnumExcludes = 899327, - ConstEnumExcludes = 899967, - ValueModuleExcludes = 106639, - NamespaceModuleExcludes = 0, - MethodExcludes = 99263, - GetAccessorExcludes = 41919, - SetAccessorExcludes = 74687, - TypeParameterExcludes = 530912, - TypeAliasExcludes = 793056, - AliasExcludes = 8388608, - ModuleMember = 8914931, - ExportHasLocal = 944, - HasExports = 1952, - HasMembers = 6240, - BlockScoped = 418, - PropertyOrAccessor = 98308, - Export = 7340032, - } - interface Symbol { - flags: SymbolFlags; - name: string; - declarations?: Declaration[]; - valueDeclaration?: Declaration; - members?: SymbolTable; - exports?: SymbolTable; - } - interface SymbolTable { - [index: string]: Symbol; - } - const enum TypeFlags { - Any = 1, - String = 2, - Number = 4, - Boolean = 8, - Void = 16, - Undefined = 32, - Null = 64, - Enum = 128, - StringLiteral = 256, - TypeParameter = 512, - Class = 1024, - Interface = 2048, - Reference = 4096, - Tuple = 8192, - Union = 16384, - Anonymous = 32768, - Instantiated = 65536, - ObjectLiteral = 262144, - ESSymbol = 2097152, - StringLike = 258, - NumberLike = 132, - ObjectType = 48128, - } - interface Type { - flags: TypeFlags; - symbol?: Symbol; - } - interface StringLiteralType extends Type { - text: string; - } - interface ObjectType extends Type { - } - interface InterfaceType extends ObjectType { - typeParameters: TypeParameter[]; - outerTypeParameters: TypeParameter[]; - localTypeParameters: TypeParameter[]; - } - interface InterfaceTypeWithBaseTypes extends InterfaceType { - baseTypes: ObjectType[]; - } - interface InterfaceTypeWithDeclaredMembers extends InterfaceType { - declaredProperties: Symbol[]; - declaredCallSignatures: Signature[]; - declaredConstructSignatures: Signature[]; - declaredStringIndexType: Type; - declaredNumberIndexType: Type; - } - interface TypeReference extends ObjectType { - target: GenericType; - typeArguments: Type[]; - } - interface GenericType extends InterfaceType, TypeReference { - } - interface TupleType extends ObjectType { - elementTypes: Type[]; - baseArrayType: TypeReference; - } - interface UnionType extends Type { - types: Type[]; - } - interface TypeParameter extends Type { - constraint: Type; - } - const enum SignatureKind { - Call = 0, - Construct = 1, - } - interface Signature { - declaration: SignatureDeclaration; - typeParameters: TypeParameter[]; - parameters: Symbol[]; - typePredicate?: TypePredicate; - } - const enum IndexKind { - String = 0, - Number = 1, - } - interface DiagnosticMessage { - key: string; - category: DiagnosticCategory; - code: number; - } - /** - * A linked list of formatted diagnostic messages to be used as part of a multiline message. - * It is built from the bottom up, leaving the head to be the "main" diagnostic. - * While it seems that DiagnosticMessageChain is structurally similar to DiagnosticMessage, - * the difference is that messages are all preformatted in DMC. - */ - interface DiagnosticMessageChain { - messageText: string; - category: DiagnosticCategory; - code: number; - next?: DiagnosticMessageChain; - } - interface Diagnostic { - file: SourceFile; - start: number; - length: number; - messageText: string | DiagnosticMessageChain; - category: DiagnosticCategory; - code: number; - } - enum DiagnosticCategory { - Warning = 0, - Error = 1, - Message = 2, - } - interface CompilerOptions { - allowNonTsExtensions?: boolean; - charset?: string; - declaration?: boolean; - dependency?: boolean; - diagnostics?: boolean; - emitBOM?: boolean; - help?: boolean; - inlineSourceMap?: boolean; - inlineSources?: boolean; - listFiles?: boolean; - locale?: string; - mapRoot?: string; - module?: ModuleKind; - newLine?: NewLineKind; - noEmit?: boolean; - noEmitHelpers?: boolean; - noEmitOnError?: boolean; - noErrorTruncation?: boolean; - noImplicitAny?: boolean; - noLib?: boolean; - noResolve?: boolean; - out?: string; - outDir?: string; - preserveConstEnums?: boolean; - project?: string; - removeComments?: boolean; - rootDir?: string; - sourceMap?: boolean; - sourceRoot?: string; - suppressImplicitAnyIndexErrors?: boolean; - target?: ScriptTarget; - version?: boolean; - watch?: boolean; - isolatedModules?: boolean; - experimentalDecorators?: boolean; - emitDecoratorMetadata?: boolean; - [option: string]: string | number | boolean; - } - const enum ModuleKind { - None = 0, - CommonJS = 1, - AMD = 2, - UMD = 3, - System = 4, - } - const enum NewLineKind { - CarriageReturnLineFeed = 0, - LineFeed = 1, - } - interface LineAndCharacter { - line: number; - character: number; - } - const enum ScriptTarget { - ES3 = 0, - ES5 = 1, - ES6 = 2, - Latest = 2, - } - interface ParsedCommandLine { - options: CompilerOptions; - fileNames: string[]; - errors: Diagnostic[]; - } - interface CancellationToken { - isCancellationRequested(): boolean; - } - interface CompilerHost { - getSourceFile(fileName: string, languageVersion: ScriptTarget, onError?: (message: string) => void): SourceFile; - getDefaultLibFileName(options: CompilerOptions): string; - getCancellationToken?(): CancellationToken; - writeFile: WriteFileCallback; - getCurrentDirectory(): string; - getCanonicalFileName(fileName: string): string; - useCaseSensitiveFileNames(): boolean; - getNewLine(): string; - } - interface TextSpan { - start: number; - length: number; - } - interface TextChangeRange { - span: TextSpan; - newLength: number; - } -} -declare module ts { - interface System { - args: string[]; - newLine: string; - useCaseSensitiveFileNames: boolean; - write(s: string): void; - readFile(path: string, encoding?: string): string; - writeFile(path: string, data: string, writeByteOrderMark?: boolean): void; - watchFile?(path: string, callback: (path: string) => void): FileWatcher; - resolvePath(path: string): string; - fileExists(path: string): boolean; - directoryExists(path: string): boolean; - createDirectory(path: string): void; - getExecutingFilePath(): string; - getCurrentDirectory(): string; - readDirectory(path: string, extension?: string, exclude?: string[]): string[]; - getMemoryUsage?(): number; - exit(exitCode?: number): void; - } - interface FileWatcher { - close(): void; - } - var sys: System; -} -declare module ts { - interface ErrorCallback { - (message: DiagnosticMessage, length: number): void; - } - interface Scanner { - getStartPos(): number; - getToken(): SyntaxKind; - getTextPos(): number; - getTokenPos(): number; - getTokenText(): string; - getTokenValue(): string; - hasExtendedUnicodeEscape(): boolean; - hasPrecedingLineBreak(): boolean; - isIdentifier(): boolean; - isReservedWord(): boolean; - isUnterminated(): boolean; - reScanGreaterToken(): SyntaxKind; - reScanSlashToken(): SyntaxKind; - reScanTemplateToken(): SyntaxKind; - scan(): SyntaxKind; - setText(text: string, start?: number, length?: number): void; - setOnError(onError: ErrorCallback): void; - setScriptTarget(scriptTarget: ScriptTarget): void; - setTextPos(textPos: number): void; - lookAhead(callback: () => T): T; - tryScan(callback: () => T): T; - } - function tokenToString(t: SyntaxKind): string; - function getPositionOfLineAndCharacter(sourceFile: SourceFile, line: number, character: number): number; - function getLineAndCharacterOfPosition(sourceFile: SourceFile, position: number): LineAndCharacter; - function isWhiteSpace(ch: number): boolean; - function isLineBreak(ch: number): boolean; - function getLeadingCommentRanges(text: string, pos: number): CommentRange[]; - function getTrailingCommentRanges(text: string, pos: number): CommentRange[]; - function isIdentifierStart(ch: number, languageVersion: ScriptTarget): boolean; - function isIdentifierPart(ch: number, languageVersion: ScriptTarget): boolean; -} -declare module ts { - function getDefaultLibFileName(options: CompilerOptions): string; - function textSpanEnd(span: TextSpan): number; - function textSpanIsEmpty(span: TextSpan): boolean; - function textSpanContainsPosition(span: TextSpan, position: number): boolean; - function textSpanContainsTextSpan(span: TextSpan, other: TextSpan): boolean; - function textSpanOverlapsWith(span: TextSpan, other: TextSpan): boolean; - function textSpanOverlap(span1: TextSpan, span2: TextSpan): TextSpan; - function textSpanIntersectsWithTextSpan(span: TextSpan, other: TextSpan): boolean; - function textSpanIntersectsWith(span: TextSpan, start: number, length: number): boolean; - function textSpanIntersectsWithPosition(span: TextSpan, position: number): boolean; - function textSpanIntersection(span1: TextSpan, span2: TextSpan): TextSpan; - function createTextSpan(start: number, length: number): TextSpan; - function createTextSpanFromBounds(start: number, end: number): TextSpan; - function textChangeRangeNewSpan(range: TextChangeRange): TextSpan; - function textChangeRangeIsUnchanged(range: TextChangeRange): boolean; - function createTextChangeRange(span: TextSpan, newLength: number): TextChangeRange; - let unchangedTextChangeRange: TextChangeRange; - /** - * Called to merge all the changes that occurred across several versions of a script snapshot - * into a single change. i.e. if a user keeps making successive edits to a script we will - * have a text change from V1 to V2, V2 to V3, ..., Vn. - * - * This function will then merge those changes into a single change range valid between V1 and - * Vn. - */ - function collapseTextChangeRangesAcrossMultipleVersions(changes: TextChangeRange[]): TextChangeRange; - function getTypeParameterOwner(d: Declaration): Declaration; -} -declare module ts { - function getNodeConstructor(kind: SyntaxKind): new () => Node; - function createNode(kind: SyntaxKind): Node; - function forEachChild(node: Node, cbNode: (node: Node) => T, cbNodeArray?: (nodes: Node[]) => T): T; - function createSourceFile(fileName: string, sourceText: string, languageVersion: ScriptTarget, setParentNodes?: boolean): SourceFile; - function updateSourceFile(sourceFile: SourceFile, newText: string, textChangeRange: TextChangeRange, aggressiveChecks?: boolean): SourceFile; -} -declare module ts { - /** The version of the TypeScript compiler release */ - const version: string; - function findConfigFile(searchPath: string): string; - function createCompilerHost(options: CompilerOptions, setParentNodes?: boolean): CompilerHost; - function getPreEmitDiagnostics(program: Program, sourceFile?: SourceFile): Diagnostic[]; - function flattenDiagnosticMessageText(messageText: string | DiagnosticMessageChain, newLine: string): string; - function createProgram(rootNames: string[], options: CompilerOptions, host?: CompilerHost): Program; -} -declare module ts { - function parseCommandLine(commandLine: string[]): ParsedCommandLine; - /** - * Read tsconfig.json file - * @param fileName The path to the config file - */ - function readConfigFile(fileName: string): { - config?: any; - error?: Diagnostic; - }; - /** - * Parse the text of the tsconfig.json file - * @param fileName The path to the config file - * @param jsonText The text of the config file - */ - function parseConfigFileText(fileName: string, jsonText: string): { - config?: any; - error?: Diagnostic; - }; - /** - * Parse the contents of a config file (tsconfig.json). - * @param json The contents of the config file to parse - * @param basePath A root directory to resolve relative path entries in the config - * file to. e.g. outDir - */ - function parseConfigFile(json: any, host: ParseConfigHost, basePath: string): ParsedCommandLine; -} -declare module ts { - /** The version of the language service API */ - let servicesVersion: string; - interface Node { - getSourceFile(): SourceFile; - getChildCount(sourceFile?: SourceFile): number; - getChildAt(index: number, sourceFile?: SourceFile): Node; - getChildren(sourceFile?: SourceFile): Node[]; - getStart(sourceFile?: SourceFile): number; - getFullStart(): number; - getEnd(): number; - getWidth(sourceFile?: SourceFile): number; - getFullWidth(): number; - getLeadingTriviaWidth(sourceFile?: SourceFile): number; - getFullText(sourceFile?: SourceFile): string; - getText(sourceFile?: SourceFile): string; - getFirstToken(sourceFile?: SourceFile): Node; - getLastToken(sourceFile?: SourceFile): Node; - } - interface Symbol { - getFlags(): SymbolFlags; - getName(): string; - getDeclarations(): Declaration[]; - getDocumentationComment(): SymbolDisplayPart[]; - } - interface Type { - getFlags(): TypeFlags; - getSymbol(): Symbol; - getProperties(): Symbol[]; - getProperty(propertyName: string): Symbol; - getApparentProperties(): Symbol[]; - getCallSignatures(): Signature[]; - getConstructSignatures(): Signature[]; - getStringIndexType(): Type; - getNumberIndexType(): Type; - } - interface Signature { - getDeclaration(): SignatureDeclaration; - getTypeParameters(): Type[]; - getParameters(): Symbol[]; - getReturnType(): Type; - getDocumentationComment(): SymbolDisplayPart[]; - } - interface SourceFile { - getLineAndCharacterOfPosition(pos: number): LineAndCharacter; - getLineStarts(): number[]; - getPositionOfLineAndCharacter(line: number, character: number): number; - update(newText: string, textChangeRange: TextChangeRange): SourceFile; - } - /** - * Represents an immutable snapshot of a script at a specified time.Once acquired, the - * snapshot is observably immutable. i.e. the same calls with the same parameters will return - * the same values. - */ - interface IScriptSnapshot { - /** Gets a portion of the script snapshot specified by [start, end). */ - getText(start: number, end: number): string; - /** Gets the length of this script snapshot. */ - getLength(): number; - /** - * Gets the TextChangeRange that describe how the text changed between this text and - * an older version. This information is used by the incremental parser to determine - * what sections of the script need to be re-parsed. 'undefined' can be returned if the - * change range cannot be determined. However, in that case, incremental parsing will - * not happen and the entire document will be re - parsed. - */ - getChangeRange(oldSnapshot: IScriptSnapshot): TextChangeRange; - } - module ScriptSnapshot { - function fromString(text: string): IScriptSnapshot; - } - interface PreProcessedFileInfo { - referencedFiles: FileReference[]; - importedFiles: FileReference[]; - isLibFile: boolean; - } - interface LanguageServiceHost { - getCompilationSettings(): CompilerOptions; - getNewLine?(): string; - getProjectVersion?(): string; - getScriptFileNames(): string[]; - getScriptVersion(fileName: string): string; - getScriptSnapshot(fileName: string): IScriptSnapshot; - getLocalizedDiagnosticMessages?(): any; - getCancellationToken?(): CancellationToken; - getCurrentDirectory(): string; - getDefaultLibFileName(options: CompilerOptions): string; - log?(s: string): void; - trace?(s: string): void; - error?(s: string): void; - useCaseSensitiveFileNames?(): boolean; - } - interface LanguageService { - cleanupSemanticCache(): void; - getSyntacticDiagnostics(fileName: string): Diagnostic[]; - getSemanticDiagnostics(fileName: string): Diagnostic[]; - getCompilerOptionsDiagnostics(): Diagnostic[]; - /** - * @deprecated Use getEncodedSyntacticClassifications instead. - */ - getSyntacticClassifications(fileName: string, span: TextSpan): ClassifiedSpan[]; - /** - * @deprecated Use getEncodedSemanticClassifications instead. - */ - getSemanticClassifications(fileName: string, span: TextSpan): ClassifiedSpan[]; - getEncodedSyntacticClassifications(fileName: string, span: TextSpan): Classifications; - getEncodedSemanticClassifications(fileName: string, span: TextSpan): Classifications; - getCompletionsAtPosition(fileName: string, position: number): CompletionInfo; - getCompletionEntryDetails(fileName: string, position: number, entryName: string): CompletionEntryDetails; - getQuickInfoAtPosition(fileName: string, position: number): QuickInfo; - getNameOrDottedNameSpan(fileName: string, startPos: number, endPos: number): TextSpan; - getBreakpointStatementAtPosition(fileName: string, position: number): TextSpan; - getSignatureHelpItems(fileName: string, position: number): SignatureHelpItems; - getRenameInfo(fileName: string, position: number): RenameInfo; - findRenameLocations(fileName: string, position: number, findInStrings: boolean, findInComments: boolean): RenameLocation[]; - getDefinitionAtPosition(fileName: string, position: number): DefinitionInfo[]; - getTypeDefinitionAtPosition(fileName: string, position: number): DefinitionInfo[]; - getReferencesAtPosition(fileName: string, position: number): ReferenceEntry[]; - findReferences(fileName: string, position: number): ReferencedSymbol[]; - getDocumentHighlights(fileName: string, position: number, filesToSearch: string[]): DocumentHighlights[]; - /** @deprecated */ - getOccurrencesAtPosition(fileName: string, position: number): ReferenceEntry[]; - getNavigateToItems(searchValue: string, maxResultCount?: number): NavigateToItem[]; - getNavigationBarItems(fileName: string): NavigationBarItem[]; - getOutliningSpans(fileName: string): OutliningSpan[]; - getTodoComments(fileName: string, descriptors: TodoCommentDescriptor[]): TodoComment[]; - getBraceMatchingAtPosition(fileName: string, position: number): TextSpan[]; - getIndentationAtPosition(fileName: string, position: number, options: EditorOptions): number; - getFormattingEditsForRange(fileName: string, start: number, end: number, options: FormatCodeOptions): TextChange[]; - getFormattingEditsForDocument(fileName: string, options: FormatCodeOptions): TextChange[]; - getFormattingEditsAfterKeystroke(fileName: string, position: number, key: string, options: FormatCodeOptions): TextChange[]; - getEmitOutput(fileName: string): EmitOutput; - getProgram(): Program; - getSourceFile(fileName: string): SourceFile; - dispose(): void; - } - interface Classifications { - spans: number[]; - endOfLineState: EndOfLineState; - } - interface ClassifiedSpan { - textSpan: TextSpan; - classificationType: string; - } - interface NavigationBarItem { - text: string; - kind: string; - kindModifiers: string; - spans: TextSpan[]; - childItems: NavigationBarItem[]; - indent: number; - bolded: boolean; - grayed: boolean; - } - interface TodoCommentDescriptor { - text: string; - priority: number; - } - interface TodoComment { - descriptor: TodoCommentDescriptor; - message: string; - position: number; - } - class TextChange { - span: TextSpan; - newText: string; - } - interface RenameLocation { - textSpan: TextSpan; - fileName: string; - } - interface ReferenceEntry { - textSpan: TextSpan; - fileName: string; - isWriteAccess: boolean; - } - interface DocumentHighlights { - fileName: string; - highlightSpans: HighlightSpan[]; - } - module HighlightSpanKind { - const none: string; - const definition: string; - const reference: string; - const writtenReference: string; - } - interface HighlightSpan { - textSpan: TextSpan; - kind: string; - } - interface NavigateToItem { - name: string; - kind: string; - kindModifiers: string; - matchKind: string; - isCaseSensitive: boolean; - fileName: string; - textSpan: TextSpan; - containerName: string; - containerKind: string; - } - interface EditorOptions { - IndentSize: number; - TabSize: number; - NewLineCharacter: string; - ConvertTabsToSpaces: boolean; - } - interface FormatCodeOptions extends EditorOptions { - InsertSpaceAfterCommaDelimiter: boolean; - InsertSpaceAfterSemicolonInForStatements: boolean; - InsertSpaceBeforeAndAfterBinaryOperators: boolean; - InsertSpaceAfterKeywordsInControlFlowStatements: boolean; - InsertSpaceAfterFunctionKeywordForAnonymousFunctions: boolean; - InsertSpaceAfterOpeningAndBeforeClosingNonemptyParenthesis: boolean; - PlaceOpenBraceOnNewLineForFunctions: boolean; - PlaceOpenBraceOnNewLineForControlBlocks: boolean; - [s: string]: boolean | number | string; - } - interface DefinitionInfo { - fileName: string; - textSpan: TextSpan; - kind: string; - name: string; - containerKind: string; - containerName: string; - } - interface ReferencedSymbol { - definition: DefinitionInfo; - references: ReferenceEntry[]; - } - enum SymbolDisplayPartKind { - aliasName = 0, - className = 1, - enumName = 2, - fieldName = 3, - interfaceName = 4, - keyword = 5, - lineBreak = 6, - numericLiteral = 7, - stringLiteral = 8, - localName = 9, - methodName = 10, - moduleName = 11, - operator = 12, - parameterName = 13, - propertyName = 14, - punctuation = 15, - space = 16, - text = 17, - typeParameterName = 18, - enumMemberName = 19, - functionName = 20, - regularExpressionLiteral = 21, - } - interface SymbolDisplayPart { - text: string; - kind: string; - } - interface QuickInfo { - kind: string; - kindModifiers: string; - textSpan: TextSpan; - displayParts: SymbolDisplayPart[]; - documentation: SymbolDisplayPart[]; - } - interface RenameInfo { - canRename: boolean; - localizedErrorMessage: string; - displayName: string; - fullDisplayName: string; - kind: string; - kindModifiers: string; - triggerSpan: TextSpan; - } - interface SignatureHelpParameter { - name: string; - documentation: SymbolDisplayPart[]; - displayParts: SymbolDisplayPart[]; - isOptional: boolean; - } - /** - * Represents a single signature to show in signature help. - * The id is used for subsequent calls into the language service to ask questions about the - * signature help item in the context of any documents that have been updated. i.e. after - * an edit has happened, while signature help is still active, the host can ask important - * questions like 'what parameter is the user currently contained within?'. - */ - interface SignatureHelpItem { - isVariadic: boolean; - prefixDisplayParts: SymbolDisplayPart[]; - suffixDisplayParts: SymbolDisplayPart[]; - separatorDisplayParts: SymbolDisplayPart[]; - parameters: SignatureHelpParameter[]; - documentation: SymbolDisplayPart[]; - } - /** - * Represents a set of signature help items, and the preferred item that should be selected. - */ - interface SignatureHelpItems { - items: SignatureHelpItem[]; - applicableSpan: TextSpan; - selectedItemIndex: number; - argumentIndex: number; - argumentCount: number; - } - interface CompletionInfo { - isMemberCompletion: boolean; - isNewIdentifierLocation: boolean; - entries: CompletionEntry[]; - } - interface CompletionEntry { - name: string; - kind: string; - kindModifiers: string; - sortText: string; - } - interface CompletionEntryDetails { - name: string; - kind: string; - kindModifiers: string; - displayParts: SymbolDisplayPart[]; - documentation: SymbolDisplayPart[]; - } - interface OutliningSpan { - /** The span of the document to actually collapse. */ - textSpan: TextSpan; - /** The span of the document to display when the user hovers over the collapsed span. */ - hintSpan: TextSpan; - /** The text to display in the editor for the collapsed region. */ - bannerText: string; - /** - * Whether or not this region should be automatically collapsed when - * the 'Collapse to Definitions' command is invoked. - */ - autoCollapse: boolean; - } - interface EmitOutput { - outputFiles: OutputFile[]; - emitSkipped: boolean; - } - const enum OutputFileType { - JavaScript = 0, - SourceMap = 1, - Declaration = 2, - } - interface OutputFile { - name: string; - writeByteOrderMark: boolean; - text: string; - } - const enum EndOfLineState { - None = 0, - InMultiLineCommentTrivia = 1, - InSingleQuoteStringLiteral = 2, - InDoubleQuoteStringLiteral = 3, - InTemplateHeadOrNoSubstitutionTemplate = 4, - InTemplateMiddleOrTail = 5, - InTemplateSubstitutionPosition = 6, - } - enum TokenClass { - Punctuation = 0, - Keyword = 1, - Operator = 2, - Comment = 3, - Whitespace = 4, - Identifier = 5, - NumberLiteral = 6, - StringLiteral = 7, - RegExpLiteral = 8, - } - interface ClassificationResult { - finalLexState: EndOfLineState; - entries: ClassificationInfo[]; - } - interface ClassificationInfo { - length: number; - classification: TokenClass; - } - interface Classifier { - /** - * Gives lexical classifications of tokens on a line without any syntactic context. - * For instance, a token consisting of the text 'string' can be either an identifier - * named 'string' or the keyword 'string', however, because this classifier is not aware, - * it relies on certain heuristics to give acceptable results. For classifications where - * speed trumps accuracy, this function is preferable; however, for true accuracy, the - * syntactic classifier is ideal. In fact, in certain editing scenarios, combining the - * lexical, syntactic, and semantic classifiers may issue the best user experience. - * - * @param text The text of a line to classify. - * @param lexState The state of the lexical classifier at the end of the previous line. - * @param syntacticClassifierAbsent Whether the client is *not* using a syntactic classifier. - * If there is no syntactic classifier (syntacticClassifierAbsent=true), - * certain heuristics may be used in its place; however, if there is a - * syntactic classifier (syntacticClassifierAbsent=false), certain - * classifications which may be incorrectly categorized will be given - * back as Identifiers in order to allow the syntactic classifier to - * subsume the classification. - * @deprecated Use getLexicalClassifications instead. - */ - getClassificationsForLine(text: string, lexState: EndOfLineState, syntacticClassifierAbsent: boolean): ClassificationResult; - getEncodedLexicalClassifications(text: string, endOfLineState: EndOfLineState, syntacticClassifierAbsent: boolean): Classifications; - } - /** - * The document registry represents a store of SourceFile objects that can be shared between - * multiple LanguageService instances. A LanguageService instance holds on the SourceFile (AST) - * of files in the context. - * SourceFile objects account for most of the memory usage by the language service. Sharing - * the same DocumentRegistry instance between different instances of LanguageService allow - * for more efficient memory utilization since all projects will share at least the library - * file (lib.d.ts). - * - * A more advanced use of the document registry is to serialize sourceFile objects to disk - * and re-hydrate them when needed. - * - * To create a default DocumentRegistry, use createDocumentRegistry to create one, and pass it - * to all subsequent createLanguageService calls. - */ - interface DocumentRegistry { - /** - * Request a stored SourceFile with a given fileName and compilationSettings. - * The first call to acquire will call createLanguageServiceSourceFile to generate - * the SourceFile if was not found in the registry. - * - * @param fileName The name of the file requested - * @param compilationSettings Some compilation settings like target affects the - * shape of a the resulting SourceFile. This allows the DocumentRegistry to store - * multiple copies of the same file for different compilation settings. - * @parm scriptSnapshot Text of the file. Only used if the file was not found - * in the registry and a new one was created. - * @parm version Current version of the file. Only used if the file was not found - * in the registry and a new one was created. - */ - acquireDocument(fileName: string, compilationSettings: CompilerOptions, scriptSnapshot: IScriptSnapshot, version: string): SourceFile; - /** - * Request an updated version of an already existing SourceFile with a given fileName - * and compilationSettings. The update will in-turn call updateLanguageServiceSourceFile - * to get an updated SourceFile. - * - * @param fileName The name of the file requested - * @param compilationSettings Some compilation settings like target affects the - * shape of a the resulting SourceFile. This allows the DocumentRegistry to store - * multiple copies of the same file for different compilation settings. - * @param scriptSnapshot Text of the file. - * @param version Current version of the file. - */ - updateDocument(fileName: string, compilationSettings: CompilerOptions, scriptSnapshot: IScriptSnapshot, version: string): SourceFile; - /** - * Informs the DocumentRegistry that a file is not needed any longer. - * - * Note: It is not allowed to call release on a SourceFile that was not acquired from - * this registry originally. - * - * @param fileName The name of the file to be released - * @param compilationSettings The compilation settings used to acquire the file - */ - releaseDocument(fileName: string, compilationSettings: CompilerOptions): void; - } - module ScriptElementKind { - const unknown: string; - const warning: string; - const keyword: string; - const scriptElement: string; - const moduleElement: string; - const classElement: string; - const interfaceElement: string; - const typeElement: string; - const enumElement: string; - const variableElement: string; - const localVariableElement: string; - const functionElement: string; - const localFunctionElement: string; - const memberFunctionElement: string; - const memberGetAccessorElement: string; - const memberSetAccessorElement: string; - const memberVariableElement: string; - const constructorImplementationElement: string; - const callSignatureElement: string; - const indexSignatureElement: string; - const constructSignatureElement: string; - const parameterElement: string; - const typeParameterElement: string; - const primitiveType: string; - const label: string; - const alias: string; - const constElement: string; - const letElement: string; - } - module ScriptElementKindModifier { - const none: string; - const publicMemberModifier: string; - const privateMemberModifier: string; - const protectedMemberModifier: string; - const exportedModifier: string; - const ambientModifier: string; - const staticModifier: string; - } - class ClassificationTypeNames { - static comment: string; - static identifier: string; - static keyword: string; - static numericLiteral: string; - static operator: string; - static stringLiteral: string; - static whiteSpace: string; - static text: string; - static punctuation: string; - static className: string; - static enumName: string; - static interfaceName: string; - static moduleName: string; - static typeParameterName: string; - static typeAliasName: string; - static parameterName: string; - static docCommentTagName: string; - } - const enum ClassificationType { - comment = 1, - identifier = 2, - keyword = 3, - numericLiteral = 4, - operator = 5, - stringLiteral = 6, - regularExpressionLiteral = 7, - whiteSpace = 8, - text = 9, - punctuation = 10, - className = 11, - enumName = 12, - interfaceName = 13, - moduleName = 14, - typeParameterName = 15, - typeAliasName = 16, - parameterName = 17, - docCommentTagName = 18, - } - interface DisplayPartsSymbolWriter extends SymbolWriter { - displayParts(): SymbolDisplayPart[]; - } - function displayPartsToString(displayParts: SymbolDisplayPart[]): string; - function getDefaultCompilerOptions(): CompilerOptions; - class OperationCanceledException { - } - class CancellationTokenObject { - private cancellationToken; - static None: CancellationTokenObject; - constructor(cancellationToken: CancellationToken); - isCancellationRequested(): boolean; - throwIfCancellationRequested(): void; - } - function transpile(input: string, compilerOptions?: CompilerOptions, fileName?: string, diagnostics?: Diagnostic[], moduleName?: string): string; - function createLanguageServiceSourceFile(fileName: string, scriptSnapshot: IScriptSnapshot, scriptTarget: ScriptTarget, version: string, setNodeParents: boolean): SourceFile; - let disableIncrementalParsing: boolean; - function updateLanguageServiceSourceFile(sourceFile: SourceFile, scriptSnapshot: IScriptSnapshot, version: string, textChangeRange: TextChangeRange, aggressiveChecks?: boolean): SourceFile; - function createDocumentRegistry(useCaseSensitiveFileNames?: boolean): DocumentRegistry; - function preProcessFile(sourceText: string, readImportFiles?: boolean): PreProcessedFileInfo; - function createLanguageService(host: LanguageServiceHost, documentRegistry?: DocumentRegistry): LanguageService; - function createClassifier(): Classifier; - /** - * Get the path of the default library file (lib.d.ts) as distributed with the typescript - * node package. - * The functionality is not supported if the ts module is consumed outside of a node module. - */ - function getDefaultLibFilePath(options: CompilerOptions): string; -} -export = ts; \ No newline at end of file diff --git a/build/lib/typescript/typescriptServices.js b/build/lib/typescript/typescriptServices.js deleted file mode 100644 index 349ff6ad391..00000000000 --- a/build/lib/typescript/typescriptServices.js +++ /dev/null @@ -1,44323 +0,0 @@ -var ts; -(function (ts) { - // token > SyntaxKind.Identifer => token is a keyword - (function (SyntaxKind) { - SyntaxKind[SyntaxKind["Unknown"] = 0] = "Unknown"; - SyntaxKind[SyntaxKind["EndOfFileToken"] = 1] = "EndOfFileToken"; - SyntaxKind[SyntaxKind["SingleLineCommentTrivia"] = 2] = "SingleLineCommentTrivia"; - SyntaxKind[SyntaxKind["MultiLineCommentTrivia"] = 3] = "MultiLineCommentTrivia"; - SyntaxKind[SyntaxKind["NewLineTrivia"] = 4] = "NewLineTrivia"; - SyntaxKind[SyntaxKind["WhitespaceTrivia"] = 5] = "WhitespaceTrivia"; - // We detect and provide better error recovery when we encounter a git merge marker. This - // allows us to edit files with git-conflict markers in them in a much more pleasant manner. - SyntaxKind[SyntaxKind["ConflictMarkerTrivia"] = 6] = "ConflictMarkerTrivia"; - // Literals - SyntaxKind[SyntaxKind["NumericLiteral"] = 7] = "NumericLiteral"; - SyntaxKind[SyntaxKind["StringLiteral"] = 8] = "StringLiteral"; - SyntaxKind[SyntaxKind["RegularExpressionLiteral"] = 9] = "RegularExpressionLiteral"; - SyntaxKind[SyntaxKind["NoSubstitutionTemplateLiteral"] = 10] = "NoSubstitutionTemplateLiteral"; - // Pseudo-literals - SyntaxKind[SyntaxKind["TemplateHead"] = 11] = "TemplateHead"; - SyntaxKind[SyntaxKind["TemplateMiddle"] = 12] = "TemplateMiddle"; - SyntaxKind[SyntaxKind["TemplateTail"] = 13] = "TemplateTail"; - // Punctuation - SyntaxKind[SyntaxKind["OpenBraceToken"] = 14] = "OpenBraceToken"; - SyntaxKind[SyntaxKind["CloseBraceToken"] = 15] = "CloseBraceToken"; - SyntaxKind[SyntaxKind["OpenParenToken"] = 16] = "OpenParenToken"; - SyntaxKind[SyntaxKind["CloseParenToken"] = 17] = "CloseParenToken"; - SyntaxKind[SyntaxKind["OpenBracketToken"] = 18] = "OpenBracketToken"; - SyntaxKind[SyntaxKind["CloseBracketToken"] = 19] = "CloseBracketToken"; - SyntaxKind[SyntaxKind["DotToken"] = 20] = "DotToken"; - SyntaxKind[SyntaxKind["DotDotDotToken"] = 21] = "DotDotDotToken"; - SyntaxKind[SyntaxKind["SemicolonToken"] = 22] = "SemicolonToken"; - SyntaxKind[SyntaxKind["CommaToken"] = 23] = "CommaToken"; - SyntaxKind[SyntaxKind["LessThanToken"] = 24] = "LessThanToken"; - SyntaxKind[SyntaxKind["GreaterThanToken"] = 25] = "GreaterThanToken"; - SyntaxKind[SyntaxKind["LessThanEqualsToken"] = 26] = "LessThanEqualsToken"; - SyntaxKind[SyntaxKind["GreaterThanEqualsToken"] = 27] = "GreaterThanEqualsToken"; - SyntaxKind[SyntaxKind["EqualsEqualsToken"] = 28] = "EqualsEqualsToken"; - SyntaxKind[SyntaxKind["ExclamationEqualsToken"] = 29] = "ExclamationEqualsToken"; - SyntaxKind[SyntaxKind["EqualsEqualsEqualsToken"] = 30] = "EqualsEqualsEqualsToken"; - SyntaxKind[SyntaxKind["ExclamationEqualsEqualsToken"] = 31] = "ExclamationEqualsEqualsToken"; - SyntaxKind[SyntaxKind["EqualsGreaterThanToken"] = 32] = "EqualsGreaterThanToken"; - SyntaxKind[SyntaxKind["PlusToken"] = 33] = "PlusToken"; - SyntaxKind[SyntaxKind["MinusToken"] = 34] = "MinusToken"; - SyntaxKind[SyntaxKind["AsteriskToken"] = 35] = "AsteriskToken"; - SyntaxKind[SyntaxKind["SlashToken"] = 36] = "SlashToken"; - SyntaxKind[SyntaxKind["PercentToken"] = 37] = "PercentToken"; - SyntaxKind[SyntaxKind["PlusPlusToken"] = 38] = "PlusPlusToken"; - SyntaxKind[SyntaxKind["MinusMinusToken"] = 39] = "MinusMinusToken"; - SyntaxKind[SyntaxKind["LessThanLessThanToken"] = 40] = "LessThanLessThanToken"; - SyntaxKind[SyntaxKind["GreaterThanGreaterThanToken"] = 41] = "GreaterThanGreaterThanToken"; - SyntaxKind[SyntaxKind["GreaterThanGreaterThanGreaterThanToken"] = 42] = "GreaterThanGreaterThanGreaterThanToken"; - SyntaxKind[SyntaxKind["AmpersandToken"] = 43] = "AmpersandToken"; - SyntaxKind[SyntaxKind["BarToken"] = 44] = "BarToken"; - SyntaxKind[SyntaxKind["CaretToken"] = 45] = "CaretToken"; - SyntaxKind[SyntaxKind["ExclamationToken"] = 46] = "ExclamationToken"; - SyntaxKind[SyntaxKind["TildeToken"] = 47] = "TildeToken"; - SyntaxKind[SyntaxKind["AmpersandAmpersandToken"] = 48] = "AmpersandAmpersandToken"; - SyntaxKind[SyntaxKind["BarBarToken"] = 49] = "BarBarToken"; - SyntaxKind[SyntaxKind["QuestionToken"] = 50] = "QuestionToken"; - SyntaxKind[SyntaxKind["ColonToken"] = 51] = "ColonToken"; - SyntaxKind[SyntaxKind["AtToken"] = 52] = "AtToken"; - // Assignments - SyntaxKind[SyntaxKind["EqualsToken"] = 53] = "EqualsToken"; - SyntaxKind[SyntaxKind["PlusEqualsToken"] = 54] = "PlusEqualsToken"; - SyntaxKind[SyntaxKind["MinusEqualsToken"] = 55] = "MinusEqualsToken"; - SyntaxKind[SyntaxKind["AsteriskEqualsToken"] = 56] = "AsteriskEqualsToken"; - SyntaxKind[SyntaxKind["SlashEqualsToken"] = 57] = "SlashEqualsToken"; - SyntaxKind[SyntaxKind["PercentEqualsToken"] = 58] = "PercentEqualsToken"; - SyntaxKind[SyntaxKind["LessThanLessThanEqualsToken"] = 59] = "LessThanLessThanEqualsToken"; - SyntaxKind[SyntaxKind["GreaterThanGreaterThanEqualsToken"] = 60] = "GreaterThanGreaterThanEqualsToken"; - SyntaxKind[SyntaxKind["GreaterThanGreaterThanGreaterThanEqualsToken"] = 61] = "GreaterThanGreaterThanGreaterThanEqualsToken"; - SyntaxKind[SyntaxKind["AmpersandEqualsToken"] = 62] = "AmpersandEqualsToken"; - SyntaxKind[SyntaxKind["BarEqualsToken"] = 63] = "BarEqualsToken"; - SyntaxKind[SyntaxKind["CaretEqualsToken"] = 64] = "CaretEqualsToken"; - // Identifiers - SyntaxKind[SyntaxKind["Identifier"] = 65] = "Identifier"; - // Reserved words - SyntaxKind[SyntaxKind["BreakKeyword"] = 66] = "BreakKeyword"; - SyntaxKind[SyntaxKind["CaseKeyword"] = 67] = "CaseKeyword"; - SyntaxKind[SyntaxKind["CatchKeyword"] = 68] = "CatchKeyword"; - SyntaxKind[SyntaxKind["ClassKeyword"] = 69] = "ClassKeyword"; - SyntaxKind[SyntaxKind["ConstKeyword"] = 70] = "ConstKeyword"; - SyntaxKind[SyntaxKind["ContinueKeyword"] = 71] = "ContinueKeyword"; - SyntaxKind[SyntaxKind["DebuggerKeyword"] = 72] = "DebuggerKeyword"; - SyntaxKind[SyntaxKind["DefaultKeyword"] = 73] = "DefaultKeyword"; - SyntaxKind[SyntaxKind["DeleteKeyword"] = 74] = "DeleteKeyword"; - SyntaxKind[SyntaxKind["DoKeyword"] = 75] = "DoKeyword"; - SyntaxKind[SyntaxKind["ElseKeyword"] = 76] = "ElseKeyword"; - SyntaxKind[SyntaxKind["EnumKeyword"] = 77] = "EnumKeyword"; - SyntaxKind[SyntaxKind["ExportKeyword"] = 78] = "ExportKeyword"; - SyntaxKind[SyntaxKind["ExtendsKeyword"] = 79] = "ExtendsKeyword"; - SyntaxKind[SyntaxKind["FalseKeyword"] = 80] = "FalseKeyword"; - SyntaxKind[SyntaxKind["FinallyKeyword"] = 81] = "FinallyKeyword"; - SyntaxKind[SyntaxKind["ForKeyword"] = 82] = "ForKeyword"; - SyntaxKind[SyntaxKind["FunctionKeyword"] = 83] = "FunctionKeyword"; - SyntaxKind[SyntaxKind["IfKeyword"] = 84] = "IfKeyword"; - SyntaxKind[SyntaxKind["ImportKeyword"] = 85] = "ImportKeyword"; - SyntaxKind[SyntaxKind["InKeyword"] = 86] = "InKeyword"; - SyntaxKind[SyntaxKind["InstanceOfKeyword"] = 87] = "InstanceOfKeyword"; - SyntaxKind[SyntaxKind["NewKeyword"] = 88] = "NewKeyword"; - SyntaxKind[SyntaxKind["NullKeyword"] = 89] = "NullKeyword"; - SyntaxKind[SyntaxKind["ReturnKeyword"] = 90] = "ReturnKeyword"; - SyntaxKind[SyntaxKind["SuperKeyword"] = 91] = "SuperKeyword"; - SyntaxKind[SyntaxKind["SwitchKeyword"] = 92] = "SwitchKeyword"; - SyntaxKind[SyntaxKind["ThisKeyword"] = 93] = "ThisKeyword"; - SyntaxKind[SyntaxKind["ThrowKeyword"] = 94] = "ThrowKeyword"; - SyntaxKind[SyntaxKind["TrueKeyword"] = 95] = "TrueKeyword"; - SyntaxKind[SyntaxKind["TryKeyword"] = 96] = "TryKeyword"; - SyntaxKind[SyntaxKind["TypeOfKeyword"] = 97] = "TypeOfKeyword"; - SyntaxKind[SyntaxKind["VarKeyword"] = 98] = "VarKeyword"; - SyntaxKind[SyntaxKind["VoidKeyword"] = 99] = "VoidKeyword"; - SyntaxKind[SyntaxKind["WhileKeyword"] = 100] = "WhileKeyword"; - SyntaxKind[SyntaxKind["WithKeyword"] = 101] = "WithKeyword"; - // Strict mode reserved words - SyntaxKind[SyntaxKind["ImplementsKeyword"] = 102] = "ImplementsKeyword"; - SyntaxKind[SyntaxKind["InterfaceKeyword"] = 103] = "InterfaceKeyword"; - SyntaxKind[SyntaxKind["LetKeyword"] = 104] = "LetKeyword"; - SyntaxKind[SyntaxKind["PackageKeyword"] = 105] = "PackageKeyword"; - SyntaxKind[SyntaxKind["PrivateKeyword"] = 106] = "PrivateKeyword"; - SyntaxKind[SyntaxKind["ProtectedKeyword"] = 107] = "ProtectedKeyword"; - SyntaxKind[SyntaxKind["PublicKeyword"] = 108] = "PublicKeyword"; - SyntaxKind[SyntaxKind["StaticKeyword"] = 109] = "StaticKeyword"; - SyntaxKind[SyntaxKind["YieldKeyword"] = 110] = "YieldKeyword"; - // Contextual keywords - SyntaxKind[SyntaxKind["AsKeyword"] = 111] = "AsKeyword"; - SyntaxKind[SyntaxKind["AnyKeyword"] = 112] = "AnyKeyword"; - SyntaxKind[SyntaxKind["BooleanKeyword"] = 113] = "BooleanKeyword"; - SyntaxKind[SyntaxKind["ConstructorKeyword"] = 114] = "ConstructorKeyword"; - SyntaxKind[SyntaxKind["DeclareKeyword"] = 115] = "DeclareKeyword"; - SyntaxKind[SyntaxKind["GetKeyword"] = 116] = "GetKeyword"; - SyntaxKind[SyntaxKind["IsKeyword"] = 117] = "IsKeyword"; - SyntaxKind[SyntaxKind["ModuleKeyword"] = 118] = "ModuleKeyword"; - SyntaxKind[SyntaxKind["NamespaceKeyword"] = 119] = "NamespaceKeyword"; - SyntaxKind[SyntaxKind["RequireKeyword"] = 120] = "RequireKeyword"; - SyntaxKind[SyntaxKind["NumberKeyword"] = 121] = "NumberKeyword"; - SyntaxKind[SyntaxKind["SetKeyword"] = 122] = "SetKeyword"; - SyntaxKind[SyntaxKind["StringKeyword"] = 123] = "StringKeyword"; - SyntaxKind[SyntaxKind["SymbolKeyword"] = 124] = "SymbolKeyword"; - SyntaxKind[SyntaxKind["TypeKeyword"] = 125] = "TypeKeyword"; - SyntaxKind[SyntaxKind["FromKeyword"] = 126] = "FromKeyword"; - SyntaxKind[SyntaxKind["OfKeyword"] = 127] = "OfKeyword"; - // Parse tree nodes - // Names - SyntaxKind[SyntaxKind["QualifiedName"] = 128] = "QualifiedName"; - SyntaxKind[SyntaxKind["ComputedPropertyName"] = 129] = "ComputedPropertyName"; - // Signature elements - SyntaxKind[SyntaxKind["TypeParameter"] = 130] = "TypeParameter"; - SyntaxKind[SyntaxKind["Parameter"] = 131] = "Parameter"; - SyntaxKind[SyntaxKind["Decorator"] = 132] = "Decorator"; - // TypeMember - SyntaxKind[SyntaxKind["PropertySignature"] = 133] = "PropertySignature"; - SyntaxKind[SyntaxKind["PropertyDeclaration"] = 134] = "PropertyDeclaration"; - SyntaxKind[SyntaxKind["MethodSignature"] = 135] = "MethodSignature"; - SyntaxKind[SyntaxKind["MethodDeclaration"] = 136] = "MethodDeclaration"; - SyntaxKind[SyntaxKind["Constructor"] = 137] = "Constructor"; - SyntaxKind[SyntaxKind["GetAccessor"] = 138] = "GetAccessor"; - SyntaxKind[SyntaxKind["SetAccessor"] = 139] = "SetAccessor"; - SyntaxKind[SyntaxKind["CallSignature"] = 140] = "CallSignature"; - SyntaxKind[SyntaxKind["ConstructSignature"] = 141] = "ConstructSignature"; - SyntaxKind[SyntaxKind["IndexSignature"] = 142] = "IndexSignature"; - // Type - SyntaxKind[SyntaxKind["TypePredicate"] = 143] = "TypePredicate"; - SyntaxKind[SyntaxKind["TypeReference"] = 144] = "TypeReference"; - SyntaxKind[SyntaxKind["FunctionType"] = 145] = "FunctionType"; - SyntaxKind[SyntaxKind["ConstructorType"] = 146] = "ConstructorType"; - SyntaxKind[SyntaxKind["TypeQuery"] = 147] = "TypeQuery"; - SyntaxKind[SyntaxKind["TypeLiteral"] = 148] = "TypeLiteral"; - SyntaxKind[SyntaxKind["ArrayType"] = 149] = "ArrayType"; - SyntaxKind[SyntaxKind["TupleType"] = 150] = "TupleType"; - SyntaxKind[SyntaxKind["UnionType"] = 151] = "UnionType"; - SyntaxKind[SyntaxKind["ParenthesizedType"] = 152] = "ParenthesizedType"; - // Binding patterns - SyntaxKind[SyntaxKind["ObjectBindingPattern"] = 153] = "ObjectBindingPattern"; - SyntaxKind[SyntaxKind["ArrayBindingPattern"] = 154] = "ArrayBindingPattern"; - SyntaxKind[SyntaxKind["BindingElement"] = 155] = "BindingElement"; - // Expression - SyntaxKind[SyntaxKind["ArrayLiteralExpression"] = 156] = "ArrayLiteralExpression"; - SyntaxKind[SyntaxKind["ObjectLiteralExpression"] = 157] = "ObjectLiteralExpression"; - SyntaxKind[SyntaxKind["PropertyAccessExpression"] = 158] = "PropertyAccessExpression"; - SyntaxKind[SyntaxKind["ElementAccessExpression"] = 159] = "ElementAccessExpression"; - SyntaxKind[SyntaxKind["CallExpression"] = 160] = "CallExpression"; - SyntaxKind[SyntaxKind["NewExpression"] = 161] = "NewExpression"; - SyntaxKind[SyntaxKind["TaggedTemplateExpression"] = 162] = "TaggedTemplateExpression"; - SyntaxKind[SyntaxKind["TypeAssertionExpression"] = 163] = "TypeAssertionExpression"; - SyntaxKind[SyntaxKind["ParenthesizedExpression"] = 164] = "ParenthesizedExpression"; - SyntaxKind[SyntaxKind["FunctionExpression"] = 165] = "FunctionExpression"; - SyntaxKind[SyntaxKind["ArrowFunction"] = 166] = "ArrowFunction"; - SyntaxKind[SyntaxKind["DeleteExpression"] = 167] = "DeleteExpression"; - SyntaxKind[SyntaxKind["TypeOfExpression"] = 168] = "TypeOfExpression"; - SyntaxKind[SyntaxKind["VoidExpression"] = 169] = "VoidExpression"; - SyntaxKind[SyntaxKind["PrefixUnaryExpression"] = 170] = "PrefixUnaryExpression"; - SyntaxKind[SyntaxKind["PostfixUnaryExpression"] = 171] = "PostfixUnaryExpression"; - SyntaxKind[SyntaxKind["BinaryExpression"] = 172] = "BinaryExpression"; - SyntaxKind[SyntaxKind["ConditionalExpression"] = 173] = "ConditionalExpression"; - SyntaxKind[SyntaxKind["TemplateExpression"] = 174] = "TemplateExpression"; - SyntaxKind[SyntaxKind["YieldExpression"] = 175] = "YieldExpression"; - SyntaxKind[SyntaxKind["SpreadElementExpression"] = 176] = "SpreadElementExpression"; - SyntaxKind[SyntaxKind["ClassExpression"] = 177] = "ClassExpression"; - SyntaxKind[SyntaxKind["OmittedExpression"] = 178] = "OmittedExpression"; - SyntaxKind[SyntaxKind["ExpressionWithTypeArguments"] = 179] = "ExpressionWithTypeArguments"; - // Misc - SyntaxKind[SyntaxKind["TemplateSpan"] = 180] = "TemplateSpan"; - SyntaxKind[SyntaxKind["SemicolonClassElement"] = 181] = "SemicolonClassElement"; - // Element - SyntaxKind[SyntaxKind["Block"] = 182] = "Block"; - SyntaxKind[SyntaxKind["VariableStatement"] = 183] = "VariableStatement"; - SyntaxKind[SyntaxKind["EmptyStatement"] = 184] = "EmptyStatement"; - SyntaxKind[SyntaxKind["ExpressionStatement"] = 185] = "ExpressionStatement"; - SyntaxKind[SyntaxKind["IfStatement"] = 186] = "IfStatement"; - SyntaxKind[SyntaxKind["DoStatement"] = 187] = "DoStatement"; - SyntaxKind[SyntaxKind["WhileStatement"] = 188] = "WhileStatement"; - SyntaxKind[SyntaxKind["ForStatement"] = 189] = "ForStatement"; - SyntaxKind[SyntaxKind["ForInStatement"] = 190] = "ForInStatement"; - SyntaxKind[SyntaxKind["ForOfStatement"] = 191] = "ForOfStatement"; - SyntaxKind[SyntaxKind["ContinueStatement"] = 192] = "ContinueStatement"; - SyntaxKind[SyntaxKind["BreakStatement"] = 193] = "BreakStatement"; - SyntaxKind[SyntaxKind["ReturnStatement"] = 194] = "ReturnStatement"; - SyntaxKind[SyntaxKind["WithStatement"] = 195] = "WithStatement"; - SyntaxKind[SyntaxKind["SwitchStatement"] = 196] = "SwitchStatement"; - SyntaxKind[SyntaxKind["LabeledStatement"] = 197] = "LabeledStatement"; - SyntaxKind[SyntaxKind["ThrowStatement"] = 198] = "ThrowStatement"; - SyntaxKind[SyntaxKind["TryStatement"] = 199] = "TryStatement"; - SyntaxKind[SyntaxKind["DebuggerStatement"] = 200] = "DebuggerStatement"; - SyntaxKind[SyntaxKind["VariableDeclaration"] = 201] = "VariableDeclaration"; - SyntaxKind[SyntaxKind["VariableDeclarationList"] = 202] = "VariableDeclarationList"; - SyntaxKind[SyntaxKind["FunctionDeclaration"] = 203] = "FunctionDeclaration"; - SyntaxKind[SyntaxKind["ClassDeclaration"] = 204] = "ClassDeclaration"; - SyntaxKind[SyntaxKind["InterfaceDeclaration"] = 205] = "InterfaceDeclaration"; - SyntaxKind[SyntaxKind["TypeAliasDeclaration"] = 206] = "TypeAliasDeclaration"; - SyntaxKind[SyntaxKind["EnumDeclaration"] = 207] = "EnumDeclaration"; - SyntaxKind[SyntaxKind["ModuleDeclaration"] = 208] = "ModuleDeclaration"; - SyntaxKind[SyntaxKind["ModuleBlock"] = 209] = "ModuleBlock"; - SyntaxKind[SyntaxKind["CaseBlock"] = 210] = "CaseBlock"; - SyntaxKind[SyntaxKind["ImportEqualsDeclaration"] = 211] = "ImportEqualsDeclaration"; - SyntaxKind[SyntaxKind["ImportDeclaration"] = 212] = "ImportDeclaration"; - SyntaxKind[SyntaxKind["ImportClause"] = 213] = "ImportClause"; - SyntaxKind[SyntaxKind["NamespaceImport"] = 214] = "NamespaceImport"; - SyntaxKind[SyntaxKind["NamedImports"] = 215] = "NamedImports"; - SyntaxKind[SyntaxKind["ImportSpecifier"] = 216] = "ImportSpecifier"; - SyntaxKind[SyntaxKind["ExportAssignment"] = 217] = "ExportAssignment"; - SyntaxKind[SyntaxKind["ExportDeclaration"] = 218] = "ExportDeclaration"; - SyntaxKind[SyntaxKind["NamedExports"] = 219] = "NamedExports"; - SyntaxKind[SyntaxKind["ExportSpecifier"] = 220] = "ExportSpecifier"; - SyntaxKind[SyntaxKind["MissingDeclaration"] = 221] = "MissingDeclaration"; - // Module references - SyntaxKind[SyntaxKind["ExternalModuleReference"] = 222] = "ExternalModuleReference"; - // Clauses - SyntaxKind[SyntaxKind["CaseClause"] = 223] = "CaseClause"; - SyntaxKind[SyntaxKind["DefaultClause"] = 224] = "DefaultClause"; - SyntaxKind[SyntaxKind["HeritageClause"] = 225] = "HeritageClause"; - SyntaxKind[SyntaxKind["CatchClause"] = 226] = "CatchClause"; - // Property assignments - SyntaxKind[SyntaxKind["PropertyAssignment"] = 227] = "PropertyAssignment"; - SyntaxKind[SyntaxKind["ShorthandPropertyAssignment"] = 228] = "ShorthandPropertyAssignment"; - // Enum - SyntaxKind[SyntaxKind["EnumMember"] = 229] = "EnumMember"; - // Top-level nodes - SyntaxKind[SyntaxKind["SourceFile"] = 230] = "SourceFile"; - // JSDoc nodes. - SyntaxKind[SyntaxKind["JSDocTypeExpression"] = 231] = "JSDocTypeExpression"; - // The * type. - SyntaxKind[SyntaxKind["JSDocAllType"] = 232] = "JSDocAllType"; - // The ? type. - SyntaxKind[SyntaxKind["JSDocUnknownType"] = 233] = "JSDocUnknownType"; - SyntaxKind[SyntaxKind["JSDocArrayType"] = 234] = "JSDocArrayType"; - SyntaxKind[SyntaxKind["JSDocUnionType"] = 235] = "JSDocUnionType"; - SyntaxKind[SyntaxKind["JSDocTupleType"] = 236] = "JSDocTupleType"; - SyntaxKind[SyntaxKind["JSDocNullableType"] = 237] = "JSDocNullableType"; - SyntaxKind[SyntaxKind["JSDocNonNullableType"] = 238] = "JSDocNonNullableType"; - SyntaxKind[SyntaxKind["JSDocRecordType"] = 239] = "JSDocRecordType"; - SyntaxKind[SyntaxKind["JSDocRecordMember"] = 240] = "JSDocRecordMember"; - SyntaxKind[SyntaxKind["JSDocTypeReference"] = 241] = "JSDocTypeReference"; - SyntaxKind[SyntaxKind["JSDocOptionalType"] = 242] = "JSDocOptionalType"; - SyntaxKind[SyntaxKind["JSDocFunctionType"] = 243] = "JSDocFunctionType"; - SyntaxKind[SyntaxKind["JSDocVariadicType"] = 244] = "JSDocVariadicType"; - SyntaxKind[SyntaxKind["JSDocConstructorType"] = 245] = "JSDocConstructorType"; - SyntaxKind[SyntaxKind["JSDocThisType"] = 246] = "JSDocThisType"; - SyntaxKind[SyntaxKind["JSDocComment"] = 247] = "JSDocComment"; - SyntaxKind[SyntaxKind["JSDocTag"] = 248] = "JSDocTag"; - SyntaxKind[SyntaxKind["JSDocParameterTag"] = 249] = "JSDocParameterTag"; - SyntaxKind[SyntaxKind["JSDocReturnTag"] = 250] = "JSDocReturnTag"; - SyntaxKind[SyntaxKind["JSDocTypeTag"] = 251] = "JSDocTypeTag"; - SyntaxKind[SyntaxKind["JSDocTemplateTag"] = 252] = "JSDocTemplateTag"; - // Synthesized list - SyntaxKind[SyntaxKind["SyntaxList"] = 253] = "SyntaxList"; - // Enum value count - SyntaxKind[SyntaxKind["Count"] = 254] = "Count"; - // Markers - SyntaxKind[SyntaxKind["FirstAssignment"] = 53] = "FirstAssignment"; - SyntaxKind[SyntaxKind["LastAssignment"] = 64] = "LastAssignment"; - SyntaxKind[SyntaxKind["FirstReservedWord"] = 66] = "FirstReservedWord"; - SyntaxKind[SyntaxKind["LastReservedWord"] = 101] = "LastReservedWord"; - SyntaxKind[SyntaxKind["FirstKeyword"] = 66] = "FirstKeyword"; - SyntaxKind[SyntaxKind["LastKeyword"] = 127] = "LastKeyword"; - SyntaxKind[SyntaxKind["FirstFutureReservedWord"] = 102] = "FirstFutureReservedWord"; - SyntaxKind[SyntaxKind["LastFutureReservedWord"] = 110] = "LastFutureReservedWord"; - SyntaxKind[SyntaxKind["FirstTypeNode"] = 144] = "FirstTypeNode"; - SyntaxKind[SyntaxKind["LastTypeNode"] = 152] = "LastTypeNode"; - SyntaxKind[SyntaxKind["FirstPunctuation"] = 14] = "FirstPunctuation"; - SyntaxKind[SyntaxKind["LastPunctuation"] = 64] = "LastPunctuation"; - SyntaxKind[SyntaxKind["FirstToken"] = 0] = "FirstToken"; - SyntaxKind[SyntaxKind["LastToken"] = 127] = "LastToken"; - SyntaxKind[SyntaxKind["FirstTriviaToken"] = 2] = "FirstTriviaToken"; - SyntaxKind[SyntaxKind["LastTriviaToken"] = 6] = "LastTriviaToken"; - SyntaxKind[SyntaxKind["FirstLiteralToken"] = 7] = "FirstLiteralToken"; - SyntaxKind[SyntaxKind["LastLiteralToken"] = 10] = "LastLiteralToken"; - SyntaxKind[SyntaxKind["FirstTemplateToken"] = 10] = "FirstTemplateToken"; - SyntaxKind[SyntaxKind["LastTemplateToken"] = 13] = "LastTemplateToken"; - SyntaxKind[SyntaxKind["FirstBinaryOperator"] = 24] = "FirstBinaryOperator"; - SyntaxKind[SyntaxKind["LastBinaryOperator"] = 64] = "LastBinaryOperator"; - SyntaxKind[SyntaxKind["FirstNode"] = 128] = "FirstNode"; - })(ts.SyntaxKind || (ts.SyntaxKind = {})); - var SyntaxKind = ts.SyntaxKind; - (function (NodeFlags) { - NodeFlags[NodeFlags["Export"] = 1] = "Export"; - NodeFlags[NodeFlags["Ambient"] = 2] = "Ambient"; - NodeFlags[NodeFlags["Public"] = 16] = "Public"; - NodeFlags[NodeFlags["Private"] = 32] = "Private"; - NodeFlags[NodeFlags["Protected"] = 64] = "Protected"; - NodeFlags[NodeFlags["Static"] = 128] = "Static"; - NodeFlags[NodeFlags["Default"] = 256] = "Default"; - NodeFlags[NodeFlags["MultiLine"] = 512] = "MultiLine"; - NodeFlags[NodeFlags["Synthetic"] = 1024] = "Synthetic"; - NodeFlags[NodeFlags["DeclarationFile"] = 2048] = "DeclarationFile"; - NodeFlags[NodeFlags["Let"] = 4096] = "Let"; - NodeFlags[NodeFlags["Const"] = 8192] = "Const"; - NodeFlags[NodeFlags["OctalLiteral"] = 16384] = "OctalLiteral"; - NodeFlags[NodeFlags["Namespace"] = 32768] = "Namespace"; - NodeFlags[NodeFlags["ExportContext"] = 65536] = "ExportContext"; - NodeFlags[NodeFlags["Modifier"] = 499] = "Modifier"; - NodeFlags[NodeFlags["AccessibilityModifier"] = 112] = "AccessibilityModifier"; - NodeFlags[NodeFlags["BlockScoped"] = 12288] = "BlockScoped"; - })(ts.NodeFlags || (ts.NodeFlags = {})); - var NodeFlags = ts.NodeFlags; - /* @internal */ - (function (ParserContextFlags) { - ParserContextFlags[ParserContextFlags["None"] = 0] = "None"; - // Set if this node was parsed in strict mode. Used for grammar error checks, as well as - // checking if the node can be reused in incremental settings. - ParserContextFlags[ParserContextFlags["StrictMode"] = 1] = "StrictMode"; - // If this node was parsed in a context where 'in-expressions' are not allowed. - ParserContextFlags[ParserContextFlags["DisallowIn"] = 2] = "DisallowIn"; - // If this node was parsed in the 'yield' context created when parsing a generator. - ParserContextFlags[ParserContextFlags["Yield"] = 4] = "Yield"; - // If this node was parsed in the parameters of a generator. - ParserContextFlags[ParserContextFlags["GeneratorParameter"] = 8] = "GeneratorParameter"; - // If this node was parsed as part of a decorator - ParserContextFlags[ParserContextFlags["Decorator"] = 16] = "Decorator"; - // If the parser encountered an error when parsing the code that created this node. Note - // the parser only sets this directly on the node it creates right after encountering the - // error. - ParserContextFlags[ParserContextFlags["ThisNodeHasError"] = 32] = "ThisNodeHasError"; - // This node was parsed in a JavaScript file and can be processed differently. For example - // its type can be specified usign a JSDoc comment. - ParserContextFlags[ParserContextFlags["JavaScriptFile"] = 64] = "JavaScriptFile"; - // Context flags set directly by the parser. - ParserContextFlags[ParserContextFlags["ParserGeneratedFlags"] = 63] = "ParserGeneratedFlags"; - // Context flags computed by aggregating child flags upwards. - // Used during incremental parsing to determine if this node or any of its children had an - // error. Computed only once and then cached. - ParserContextFlags[ParserContextFlags["ThisNodeOrAnySubNodesHasError"] = 128] = "ThisNodeOrAnySubNodesHasError"; - // Used to know if we've computed data from children and cached it in this node. - ParserContextFlags[ParserContextFlags["HasAggregatedChildData"] = 256] = "HasAggregatedChildData"; - })(ts.ParserContextFlags || (ts.ParserContextFlags = {})); - var ParserContextFlags = ts.ParserContextFlags; - /* @internal */ - (function (RelationComparisonResult) { - RelationComparisonResult[RelationComparisonResult["Succeeded"] = 1] = "Succeeded"; - RelationComparisonResult[RelationComparisonResult["Failed"] = 2] = "Failed"; - RelationComparisonResult[RelationComparisonResult["FailedAndReported"] = 3] = "FailedAndReported"; - })(ts.RelationComparisonResult || (ts.RelationComparisonResult = {})); - var RelationComparisonResult = ts.RelationComparisonResult; - /** Return code used by getEmitOutput function to indicate status of the function */ - (function (ExitStatus) { - // Compiler ran successfully. Either this was a simple do-nothing compilation (for example, - // when -version or -help was provided, or this was a normal compilation, no diagnostics - // were produced, and all outputs were generated successfully. - ExitStatus[ExitStatus["Success"] = 0] = "Success"; - // Diagnostics were produced and because of them no code was generated. - ExitStatus[ExitStatus["DiagnosticsPresent_OutputsSkipped"] = 1] = "DiagnosticsPresent_OutputsSkipped"; - // Diagnostics were produced and outputs were generated in spite of them. - ExitStatus[ExitStatus["DiagnosticsPresent_OutputsGenerated"] = 2] = "DiagnosticsPresent_OutputsGenerated"; - })(ts.ExitStatus || (ts.ExitStatus = {})); - var ExitStatus = ts.ExitStatus; - (function (TypeFormatFlags) { - TypeFormatFlags[TypeFormatFlags["None"] = 0] = "None"; - TypeFormatFlags[TypeFormatFlags["WriteArrayAsGenericType"] = 1] = "WriteArrayAsGenericType"; - TypeFormatFlags[TypeFormatFlags["UseTypeOfFunction"] = 2] = "UseTypeOfFunction"; - TypeFormatFlags[TypeFormatFlags["NoTruncation"] = 4] = "NoTruncation"; - TypeFormatFlags[TypeFormatFlags["WriteArrowStyleSignature"] = 8] = "WriteArrowStyleSignature"; - TypeFormatFlags[TypeFormatFlags["WriteOwnNameForAnyLike"] = 16] = "WriteOwnNameForAnyLike"; - TypeFormatFlags[TypeFormatFlags["WriteTypeArgumentsOfSignature"] = 32] = "WriteTypeArgumentsOfSignature"; - TypeFormatFlags[TypeFormatFlags["InElementType"] = 64] = "InElementType"; - TypeFormatFlags[TypeFormatFlags["UseFullyQualifiedType"] = 128] = "UseFullyQualifiedType"; - })(ts.TypeFormatFlags || (ts.TypeFormatFlags = {})); - var TypeFormatFlags = ts.TypeFormatFlags; - (function (SymbolFormatFlags) { - SymbolFormatFlags[SymbolFormatFlags["None"] = 0] = "None"; - // Write symbols's type argument if it is instantiated symbol - // eg. class C { p: T } <-- Show p as C.p here - // var a: C; - // var p = a.p; <--- Here p is property of C so show it as C.p instead of just C.p - SymbolFormatFlags[SymbolFormatFlags["WriteTypeParametersOrArguments"] = 1] = "WriteTypeParametersOrArguments"; - // Use only external alias information to get the symbol name in the given context - // eg. module m { export class c { } } import x = m.c; - // When this flag is specified m.c will be used to refer to the class instead of alias symbol x - SymbolFormatFlags[SymbolFormatFlags["UseOnlyExternalAliasing"] = 2] = "UseOnlyExternalAliasing"; - })(ts.SymbolFormatFlags || (ts.SymbolFormatFlags = {})); - var SymbolFormatFlags = ts.SymbolFormatFlags; - /* @internal */ - (function (SymbolAccessibility) { - SymbolAccessibility[SymbolAccessibility["Accessible"] = 0] = "Accessible"; - SymbolAccessibility[SymbolAccessibility["NotAccessible"] = 1] = "NotAccessible"; - SymbolAccessibility[SymbolAccessibility["CannotBeNamed"] = 2] = "CannotBeNamed"; - })(ts.SymbolAccessibility || (ts.SymbolAccessibility = {})); - var SymbolAccessibility = ts.SymbolAccessibility; - (function (SymbolFlags) { - SymbolFlags[SymbolFlags["None"] = 0] = "None"; - SymbolFlags[SymbolFlags["FunctionScopedVariable"] = 1] = "FunctionScopedVariable"; - SymbolFlags[SymbolFlags["BlockScopedVariable"] = 2] = "BlockScopedVariable"; - SymbolFlags[SymbolFlags["Property"] = 4] = "Property"; - SymbolFlags[SymbolFlags["EnumMember"] = 8] = "EnumMember"; - SymbolFlags[SymbolFlags["Function"] = 16] = "Function"; - SymbolFlags[SymbolFlags["Class"] = 32] = "Class"; - SymbolFlags[SymbolFlags["Interface"] = 64] = "Interface"; - SymbolFlags[SymbolFlags["ConstEnum"] = 128] = "ConstEnum"; - SymbolFlags[SymbolFlags["RegularEnum"] = 256] = "RegularEnum"; - SymbolFlags[SymbolFlags["ValueModule"] = 512] = "ValueModule"; - SymbolFlags[SymbolFlags["NamespaceModule"] = 1024] = "NamespaceModule"; - SymbolFlags[SymbolFlags["TypeLiteral"] = 2048] = "TypeLiteral"; - SymbolFlags[SymbolFlags["ObjectLiteral"] = 4096] = "ObjectLiteral"; - SymbolFlags[SymbolFlags["Method"] = 8192] = "Method"; - SymbolFlags[SymbolFlags["Constructor"] = 16384] = "Constructor"; - SymbolFlags[SymbolFlags["GetAccessor"] = 32768] = "GetAccessor"; - SymbolFlags[SymbolFlags["SetAccessor"] = 65536] = "SetAccessor"; - SymbolFlags[SymbolFlags["Signature"] = 131072] = "Signature"; - SymbolFlags[SymbolFlags["TypeParameter"] = 262144] = "TypeParameter"; - SymbolFlags[SymbolFlags["TypeAlias"] = 524288] = "TypeAlias"; - SymbolFlags[SymbolFlags["ExportValue"] = 1048576] = "ExportValue"; - SymbolFlags[SymbolFlags["ExportType"] = 2097152] = "ExportType"; - SymbolFlags[SymbolFlags["ExportNamespace"] = 4194304] = "ExportNamespace"; - SymbolFlags[SymbolFlags["Alias"] = 8388608] = "Alias"; - SymbolFlags[SymbolFlags["Instantiated"] = 16777216] = "Instantiated"; - SymbolFlags[SymbolFlags["Merged"] = 33554432] = "Merged"; - SymbolFlags[SymbolFlags["Transient"] = 67108864] = "Transient"; - SymbolFlags[SymbolFlags["Prototype"] = 134217728] = "Prototype"; - SymbolFlags[SymbolFlags["UnionProperty"] = 268435456] = "UnionProperty"; - SymbolFlags[SymbolFlags["Optional"] = 536870912] = "Optional"; - SymbolFlags[SymbolFlags["ExportStar"] = 1073741824] = "ExportStar"; - SymbolFlags[SymbolFlags["Enum"] = 384] = "Enum"; - SymbolFlags[SymbolFlags["Variable"] = 3] = "Variable"; - SymbolFlags[SymbolFlags["Value"] = 107455] = "Value"; - SymbolFlags[SymbolFlags["Type"] = 793056] = "Type"; - SymbolFlags[SymbolFlags["Namespace"] = 1536] = "Namespace"; - SymbolFlags[SymbolFlags["Module"] = 1536] = "Module"; - SymbolFlags[SymbolFlags["Accessor"] = 98304] = "Accessor"; - // Variables can be redeclared, but can not redeclare a block-scoped declaration with the - // same name, or any other value that is not a variable, e.g. ValueModule or Class - SymbolFlags[SymbolFlags["FunctionScopedVariableExcludes"] = 107454] = "FunctionScopedVariableExcludes"; - // Block-scoped declarations are not allowed to be re-declared - // they can not merge with anything in the value space - SymbolFlags[SymbolFlags["BlockScopedVariableExcludes"] = 107455] = "BlockScopedVariableExcludes"; - SymbolFlags[SymbolFlags["ParameterExcludes"] = 107455] = "ParameterExcludes"; - SymbolFlags[SymbolFlags["PropertyExcludes"] = 107455] = "PropertyExcludes"; - SymbolFlags[SymbolFlags["EnumMemberExcludes"] = 107455] = "EnumMemberExcludes"; - SymbolFlags[SymbolFlags["FunctionExcludes"] = 106927] = "FunctionExcludes"; - SymbolFlags[SymbolFlags["ClassExcludes"] = 899583] = "ClassExcludes"; - SymbolFlags[SymbolFlags["InterfaceExcludes"] = 792992] = "InterfaceExcludes"; - SymbolFlags[SymbolFlags["RegularEnumExcludes"] = 899327] = "RegularEnumExcludes"; - SymbolFlags[SymbolFlags["ConstEnumExcludes"] = 899967] = "ConstEnumExcludes"; - SymbolFlags[SymbolFlags["ValueModuleExcludes"] = 106639] = "ValueModuleExcludes"; - SymbolFlags[SymbolFlags["NamespaceModuleExcludes"] = 0] = "NamespaceModuleExcludes"; - SymbolFlags[SymbolFlags["MethodExcludes"] = 99263] = "MethodExcludes"; - SymbolFlags[SymbolFlags["GetAccessorExcludes"] = 41919] = "GetAccessorExcludes"; - SymbolFlags[SymbolFlags["SetAccessorExcludes"] = 74687] = "SetAccessorExcludes"; - SymbolFlags[SymbolFlags["TypeParameterExcludes"] = 530912] = "TypeParameterExcludes"; - SymbolFlags[SymbolFlags["TypeAliasExcludes"] = 793056] = "TypeAliasExcludes"; - SymbolFlags[SymbolFlags["AliasExcludes"] = 8388608] = "AliasExcludes"; - SymbolFlags[SymbolFlags["ModuleMember"] = 8914931] = "ModuleMember"; - SymbolFlags[SymbolFlags["ExportHasLocal"] = 944] = "ExportHasLocal"; - SymbolFlags[SymbolFlags["HasExports"] = 1952] = "HasExports"; - SymbolFlags[SymbolFlags["HasMembers"] = 6240] = "HasMembers"; - SymbolFlags[SymbolFlags["BlockScoped"] = 418] = "BlockScoped"; - SymbolFlags[SymbolFlags["PropertyOrAccessor"] = 98308] = "PropertyOrAccessor"; - SymbolFlags[SymbolFlags["Export"] = 7340032] = "Export"; - /* @internal */ - // The set of things we consider semantically classifiable. Used to speed up the LS during - // classification. - SymbolFlags[SymbolFlags["Classifiable"] = 788448] = "Classifiable"; - })(ts.SymbolFlags || (ts.SymbolFlags = {})); - var SymbolFlags = ts.SymbolFlags; - /* @internal */ - (function (NodeCheckFlags) { - NodeCheckFlags[NodeCheckFlags["TypeChecked"] = 1] = "TypeChecked"; - NodeCheckFlags[NodeCheckFlags["LexicalThis"] = 2] = "LexicalThis"; - NodeCheckFlags[NodeCheckFlags["CaptureThis"] = 4] = "CaptureThis"; - NodeCheckFlags[NodeCheckFlags["EmitExtends"] = 8] = "EmitExtends"; - NodeCheckFlags[NodeCheckFlags["SuperInstance"] = 16] = "SuperInstance"; - NodeCheckFlags[NodeCheckFlags["SuperStatic"] = 32] = "SuperStatic"; - NodeCheckFlags[NodeCheckFlags["ContextChecked"] = 64] = "ContextChecked"; - // Values for enum members have been computed, and any errors have been reported for them. - NodeCheckFlags[NodeCheckFlags["EnumValuesComputed"] = 128] = "EnumValuesComputed"; - NodeCheckFlags[NodeCheckFlags["BlockScopedBindingInLoop"] = 256] = "BlockScopedBindingInLoop"; - NodeCheckFlags[NodeCheckFlags["EmitDecorate"] = 512] = "EmitDecorate"; - NodeCheckFlags[NodeCheckFlags["EmitParam"] = 1024] = "EmitParam"; - NodeCheckFlags[NodeCheckFlags["LexicalModuleMergesWithClass"] = 2048] = "LexicalModuleMergesWithClass"; - })(ts.NodeCheckFlags || (ts.NodeCheckFlags = {})); - var NodeCheckFlags = ts.NodeCheckFlags; - (function (TypeFlags) { - TypeFlags[TypeFlags["Any"] = 1] = "Any"; - TypeFlags[TypeFlags["String"] = 2] = "String"; - TypeFlags[TypeFlags["Number"] = 4] = "Number"; - TypeFlags[TypeFlags["Boolean"] = 8] = "Boolean"; - TypeFlags[TypeFlags["Void"] = 16] = "Void"; - TypeFlags[TypeFlags["Undefined"] = 32] = "Undefined"; - TypeFlags[TypeFlags["Null"] = 64] = "Null"; - TypeFlags[TypeFlags["Enum"] = 128] = "Enum"; - TypeFlags[TypeFlags["StringLiteral"] = 256] = "StringLiteral"; - TypeFlags[TypeFlags["TypeParameter"] = 512] = "TypeParameter"; - TypeFlags[TypeFlags["Class"] = 1024] = "Class"; - TypeFlags[TypeFlags["Interface"] = 2048] = "Interface"; - TypeFlags[TypeFlags["Reference"] = 4096] = "Reference"; - TypeFlags[TypeFlags["Tuple"] = 8192] = "Tuple"; - TypeFlags[TypeFlags["Union"] = 16384] = "Union"; - TypeFlags[TypeFlags["Anonymous"] = 32768] = "Anonymous"; - TypeFlags[TypeFlags["Instantiated"] = 65536] = "Instantiated"; - /* @internal */ - TypeFlags[TypeFlags["FromSignature"] = 131072] = "FromSignature"; - TypeFlags[TypeFlags["ObjectLiteral"] = 262144] = "ObjectLiteral"; - /* @internal */ - TypeFlags[TypeFlags["ContainsUndefinedOrNull"] = 524288] = "ContainsUndefinedOrNull"; - /* @internal */ - TypeFlags[TypeFlags["ContainsObjectLiteral"] = 1048576] = "ContainsObjectLiteral"; - TypeFlags[TypeFlags["ESSymbol"] = 2097152] = "ESSymbol"; - /* @internal */ - TypeFlags[TypeFlags["Intrinsic"] = 2097279] = "Intrinsic"; - /* @internal */ - TypeFlags[TypeFlags["Primitive"] = 2097662] = "Primitive"; - TypeFlags[TypeFlags["StringLike"] = 258] = "StringLike"; - TypeFlags[TypeFlags["NumberLike"] = 132] = "NumberLike"; - TypeFlags[TypeFlags["ObjectType"] = 48128] = "ObjectType"; - /* @internal */ - TypeFlags[TypeFlags["RequiresWidening"] = 1572864] = "RequiresWidening"; - })(ts.TypeFlags || (ts.TypeFlags = {})); - var TypeFlags = ts.TypeFlags; - (function (SignatureKind) { - SignatureKind[SignatureKind["Call"] = 0] = "Call"; - SignatureKind[SignatureKind["Construct"] = 1] = "Construct"; - })(ts.SignatureKind || (ts.SignatureKind = {})); - var SignatureKind = ts.SignatureKind; - (function (IndexKind) { - IndexKind[IndexKind["String"] = 0] = "String"; - IndexKind[IndexKind["Number"] = 1] = "Number"; - })(ts.IndexKind || (ts.IndexKind = {})); - var IndexKind = ts.IndexKind; - (function (DiagnosticCategory) { - DiagnosticCategory[DiagnosticCategory["Warning"] = 0] = "Warning"; - DiagnosticCategory[DiagnosticCategory["Error"] = 1] = "Error"; - DiagnosticCategory[DiagnosticCategory["Message"] = 2] = "Message"; - })(ts.DiagnosticCategory || (ts.DiagnosticCategory = {})); - var DiagnosticCategory = ts.DiagnosticCategory; - (function (ModuleKind) { - ModuleKind[ModuleKind["None"] = 0] = "None"; - ModuleKind[ModuleKind["CommonJS"] = 1] = "CommonJS"; - ModuleKind[ModuleKind["AMD"] = 2] = "AMD"; - ModuleKind[ModuleKind["UMD"] = 3] = "UMD"; - ModuleKind[ModuleKind["System"] = 4] = "System"; - })(ts.ModuleKind || (ts.ModuleKind = {})); - var ModuleKind = ts.ModuleKind; - (function (NewLineKind) { - NewLineKind[NewLineKind["CarriageReturnLineFeed"] = 0] = "CarriageReturnLineFeed"; - NewLineKind[NewLineKind["LineFeed"] = 1] = "LineFeed"; - })(ts.NewLineKind || (ts.NewLineKind = {})); - var NewLineKind = ts.NewLineKind; - (function (ScriptTarget) { - ScriptTarget[ScriptTarget["ES3"] = 0] = "ES3"; - ScriptTarget[ScriptTarget["ES5"] = 1] = "ES5"; - ScriptTarget[ScriptTarget["ES6"] = 2] = "ES6"; - ScriptTarget[ScriptTarget["Latest"] = 2] = "Latest"; - })(ts.ScriptTarget || (ts.ScriptTarget = {})); - var ScriptTarget = ts.ScriptTarget; - /* @internal */ - (function (CharacterCodes) { - CharacterCodes[CharacterCodes["nullCharacter"] = 0] = "nullCharacter"; - CharacterCodes[CharacterCodes["maxAsciiCharacter"] = 127] = "maxAsciiCharacter"; - CharacterCodes[CharacterCodes["lineFeed"] = 10] = "lineFeed"; - CharacterCodes[CharacterCodes["carriageReturn"] = 13] = "carriageReturn"; - CharacterCodes[CharacterCodes["lineSeparator"] = 8232] = "lineSeparator"; - CharacterCodes[CharacterCodes["paragraphSeparator"] = 8233] = "paragraphSeparator"; - CharacterCodes[CharacterCodes["nextLine"] = 133] = "nextLine"; - // Unicode 3.0 space characters - CharacterCodes[CharacterCodes["space"] = 32] = "space"; - CharacterCodes[CharacterCodes["nonBreakingSpace"] = 160] = "nonBreakingSpace"; - CharacterCodes[CharacterCodes["enQuad"] = 8192] = "enQuad"; - CharacterCodes[CharacterCodes["emQuad"] = 8193] = "emQuad"; - CharacterCodes[CharacterCodes["enSpace"] = 8194] = "enSpace"; - CharacterCodes[CharacterCodes["emSpace"] = 8195] = "emSpace"; - CharacterCodes[CharacterCodes["threePerEmSpace"] = 8196] = "threePerEmSpace"; - CharacterCodes[CharacterCodes["fourPerEmSpace"] = 8197] = "fourPerEmSpace"; - CharacterCodes[CharacterCodes["sixPerEmSpace"] = 8198] = "sixPerEmSpace"; - CharacterCodes[CharacterCodes["figureSpace"] = 8199] = "figureSpace"; - CharacterCodes[CharacterCodes["punctuationSpace"] = 8200] = "punctuationSpace"; - CharacterCodes[CharacterCodes["thinSpace"] = 8201] = "thinSpace"; - CharacterCodes[CharacterCodes["hairSpace"] = 8202] = "hairSpace"; - CharacterCodes[CharacterCodes["zeroWidthSpace"] = 8203] = "zeroWidthSpace"; - CharacterCodes[CharacterCodes["narrowNoBreakSpace"] = 8239] = "narrowNoBreakSpace"; - CharacterCodes[CharacterCodes["ideographicSpace"] = 12288] = "ideographicSpace"; - CharacterCodes[CharacterCodes["mathematicalSpace"] = 8287] = "mathematicalSpace"; - CharacterCodes[CharacterCodes["ogham"] = 5760] = "ogham"; - CharacterCodes[CharacterCodes["_"] = 95] = "_"; - CharacterCodes[CharacterCodes["$"] = 36] = "$"; - CharacterCodes[CharacterCodes["_0"] = 48] = "_0"; - CharacterCodes[CharacterCodes["_1"] = 49] = "_1"; - CharacterCodes[CharacterCodes["_2"] = 50] = "_2"; - CharacterCodes[CharacterCodes["_3"] = 51] = "_3"; - CharacterCodes[CharacterCodes["_4"] = 52] = "_4"; - CharacterCodes[CharacterCodes["_5"] = 53] = "_5"; - CharacterCodes[CharacterCodes["_6"] = 54] = "_6"; - CharacterCodes[CharacterCodes["_7"] = 55] = "_7"; - CharacterCodes[CharacterCodes["_8"] = 56] = "_8"; - CharacterCodes[CharacterCodes["_9"] = 57] = "_9"; - CharacterCodes[CharacterCodes["a"] = 97] = "a"; - CharacterCodes[CharacterCodes["b"] = 98] = "b"; - CharacterCodes[CharacterCodes["c"] = 99] = "c"; - CharacterCodes[CharacterCodes["d"] = 100] = "d"; - CharacterCodes[CharacterCodes["e"] = 101] = "e"; - CharacterCodes[CharacterCodes["f"] = 102] = "f"; - CharacterCodes[CharacterCodes["g"] = 103] = "g"; - CharacterCodes[CharacterCodes["h"] = 104] = "h"; - CharacterCodes[CharacterCodes["i"] = 105] = "i"; - CharacterCodes[CharacterCodes["j"] = 106] = "j"; - CharacterCodes[CharacterCodes["k"] = 107] = "k"; - CharacterCodes[CharacterCodes["l"] = 108] = "l"; - CharacterCodes[CharacterCodes["m"] = 109] = "m"; - CharacterCodes[CharacterCodes["n"] = 110] = "n"; - CharacterCodes[CharacterCodes["o"] = 111] = "o"; - CharacterCodes[CharacterCodes["p"] = 112] = "p"; - CharacterCodes[CharacterCodes["q"] = 113] = "q"; - CharacterCodes[CharacterCodes["r"] = 114] = "r"; - CharacterCodes[CharacterCodes["s"] = 115] = "s"; - CharacterCodes[CharacterCodes["t"] = 116] = "t"; - CharacterCodes[CharacterCodes["u"] = 117] = "u"; - CharacterCodes[CharacterCodes["v"] = 118] = "v"; - CharacterCodes[CharacterCodes["w"] = 119] = "w"; - CharacterCodes[CharacterCodes["x"] = 120] = "x"; - CharacterCodes[CharacterCodes["y"] = 121] = "y"; - CharacterCodes[CharacterCodes["z"] = 122] = "z"; - CharacterCodes[CharacterCodes["A"] = 65] = "A"; - CharacterCodes[CharacterCodes["B"] = 66] = "B"; - CharacterCodes[CharacterCodes["C"] = 67] = "C"; - CharacterCodes[CharacterCodes["D"] = 68] = "D"; - CharacterCodes[CharacterCodes["E"] = 69] = "E"; - CharacterCodes[CharacterCodes["F"] = 70] = "F"; - CharacterCodes[CharacterCodes["G"] = 71] = "G"; - CharacterCodes[CharacterCodes["H"] = 72] = "H"; - CharacterCodes[CharacterCodes["I"] = 73] = "I"; - CharacterCodes[CharacterCodes["J"] = 74] = "J"; - CharacterCodes[CharacterCodes["K"] = 75] = "K"; - CharacterCodes[CharacterCodes["L"] = 76] = "L"; - CharacterCodes[CharacterCodes["M"] = 77] = "M"; - CharacterCodes[CharacterCodes["N"] = 78] = "N"; - CharacterCodes[CharacterCodes["O"] = 79] = "O"; - CharacterCodes[CharacterCodes["P"] = 80] = "P"; - CharacterCodes[CharacterCodes["Q"] = 81] = "Q"; - CharacterCodes[CharacterCodes["R"] = 82] = "R"; - CharacterCodes[CharacterCodes["S"] = 83] = "S"; - CharacterCodes[CharacterCodes["T"] = 84] = "T"; - CharacterCodes[CharacterCodes["U"] = 85] = "U"; - CharacterCodes[CharacterCodes["V"] = 86] = "V"; - CharacterCodes[CharacterCodes["W"] = 87] = "W"; - CharacterCodes[CharacterCodes["X"] = 88] = "X"; - CharacterCodes[CharacterCodes["Y"] = 89] = "Y"; - CharacterCodes[CharacterCodes["Z"] = 90] = "Z"; - CharacterCodes[CharacterCodes["ampersand"] = 38] = "ampersand"; - CharacterCodes[CharacterCodes["asterisk"] = 42] = "asterisk"; - CharacterCodes[CharacterCodes["at"] = 64] = "at"; - CharacterCodes[CharacterCodes["backslash"] = 92] = "backslash"; - CharacterCodes[CharacterCodes["backtick"] = 96] = "backtick"; - CharacterCodes[CharacterCodes["bar"] = 124] = "bar"; - CharacterCodes[CharacterCodes["caret"] = 94] = "caret"; - CharacterCodes[CharacterCodes["closeBrace"] = 125] = "closeBrace"; - CharacterCodes[CharacterCodes["closeBracket"] = 93] = "closeBracket"; - CharacterCodes[CharacterCodes["closeParen"] = 41] = "closeParen"; - CharacterCodes[CharacterCodes["colon"] = 58] = "colon"; - CharacterCodes[CharacterCodes["comma"] = 44] = "comma"; - CharacterCodes[CharacterCodes["dot"] = 46] = "dot"; - CharacterCodes[CharacterCodes["doubleQuote"] = 34] = "doubleQuote"; - CharacterCodes[CharacterCodes["equals"] = 61] = "equals"; - CharacterCodes[CharacterCodes["exclamation"] = 33] = "exclamation"; - CharacterCodes[CharacterCodes["greaterThan"] = 62] = "greaterThan"; - CharacterCodes[CharacterCodes["hash"] = 35] = "hash"; - CharacterCodes[CharacterCodes["lessThan"] = 60] = "lessThan"; - CharacterCodes[CharacterCodes["minus"] = 45] = "minus"; - CharacterCodes[CharacterCodes["openBrace"] = 123] = "openBrace"; - CharacterCodes[CharacterCodes["openBracket"] = 91] = "openBracket"; - CharacterCodes[CharacterCodes["openParen"] = 40] = "openParen"; - CharacterCodes[CharacterCodes["percent"] = 37] = "percent"; - CharacterCodes[CharacterCodes["plus"] = 43] = "plus"; - CharacterCodes[CharacterCodes["question"] = 63] = "question"; - CharacterCodes[CharacterCodes["semicolon"] = 59] = "semicolon"; - CharacterCodes[CharacterCodes["singleQuote"] = 39] = "singleQuote"; - CharacterCodes[CharacterCodes["slash"] = 47] = "slash"; - CharacterCodes[CharacterCodes["tilde"] = 126] = "tilde"; - CharacterCodes[CharacterCodes["backspace"] = 8] = "backspace"; - CharacterCodes[CharacterCodes["formFeed"] = 12] = "formFeed"; - CharacterCodes[CharacterCodes["byteOrderMark"] = 65279] = "byteOrderMark"; - CharacterCodes[CharacterCodes["tab"] = 9] = "tab"; - CharacterCodes[CharacterCodes["verticalTab"] = 11] = "verticalTab"; - })(ts.CharacterCodes || (ts.CharacterCodes = {})); - var CharacterCodes = ts.CharacterCodes; -})(ts || (ts = {})); -/// -/* @internal */ -var ts; -(function (ts) { - // Ternary values are defined such that - // x & y is False if either x or y is False. - // x & y is Maybe if either x or y is Maybe, but neither x or y is False. - // x & y is True if both x and y are True. - // x | y is False if both x and y are False. - // x | y is Maybe if either x or y is Maybe, but neither x or y is True. - // x | y is True if either x or y is True. - (function (Ternary) { - Ternary[Ternary["False"] = 0] = "False"; - Ternary[Ternary["Maybe"] = 1] = "Maybe"; - Ternary[Ternary["True"] = -1] = "True"; - })(ts.Ternary || (ts.Ternary = {})); - var Ternary = ts.Ternary; - function createFileMap(getCanonicalFileName) { - var files = {}; - return { - get: get, - set: set, - contains: contains, - remove: remove, - forEachValue: forEachValueInMap - }; - function set(fileName, value) { - files[normalizeKey(fileName)] = value; - } - function get(fileName) { - return files[normalizeKey(fileName)]; - } - function contains(fileName) { - return hasProperty(files, normalizeKey(fileName)); - } - function remove(fileName) { - var key = normalizeKey(fileName); - delete files[key]; - } - function forEachValueInMap(f) { - forEachValue(files, f); - } - function normalizeKey(key) { - return getCanonicalFileName(normalizeSlashes(key)); - } - } - ts.createFileMap = createFileMap; - (function (Comparison) { - Comparison[Comparison["LessThan"] = -1] = "LessThan"; - Comparison[Comparison["EqualTo"] = 0] = "EqualTo"; - Comparison[Comparison["GreaterThan"] = 1] = "GreaterThan"; - })(ts.Comparison || (ts.Comparison = {})); - var Comparison = ts.Comparison; - function forEach(array, callback) { - if (array) { - for (var i = 0, len = array.length; i < len; i++) { - var result = callback(array[i], i); - if (result) { - return result; - } - } - } - return undefined; - } - ts.forEach = forEach; - function contains(array, value) { - if (array) { - for (var _i = 0; _i < array.length; _i++) { - var v = array[_i]; - if (v === value) { - return true; - } - } - } - return false; - } - ts.contains = contains; - function indexOf(array, value) { - if (array) { - for (var i = 0, len = array.length; i < len; i++) { - if (array[i] === value) { - return i; - } - } - } - return -1; - } - ts.indexOf = indexOf; - function countWhere(array, predicate) { - var count = 0; - if (array) { - for (var _i = 0; _i < array.length; _i++) { - var v = array[_i]; - if (predicate(v)) { - count++; - } - } - } - return count; - } - ts.countWhere = countWhere; - function filter(array, f) { - var result; - if (array) { - result = []; - for (var _i = 0; _i < array.length; _i++) { - var item = array[_i]; - if (f(item)) { - result.push(item); - } - } - } - return result; - } - ts.filter = filter; - function map(array, f) { - var result; - if (array) { - result = []; - for (var _i = 0; _i < array.length; _i++) { - var v = array[_i]; - result.push(f(v)); - } - } - return result; - } - ts.map = map; - function concatenate(array1, array2) { - if (!array2 || !array2.length) - return array1; - if (!array1 || !array1.length) - return array2; - return array1.concat(array2); - } - ts.concatenate = concatenate; - function deduplicate(array) { - var result; - if (array) { - result = []; - for (var _i = 0; _i < array.length; _i++) { - var item = array[_i]; - if (!contains(result, item)) { - result.push(item); - } - } - } - return result; - } - ts.deduplicate = deduplicate; - function sum(array, prop) { - var result = 0; - for (var _i = 0; _i < array.length; _i++) { - var v = array[_i]; - result += v[prop]; - } - return result; - } - ts.sum = sum; - function addRange(to, from) { - if (to && from) { - for (var _i = 0; _i < from.length; _i++) { - var v = from[_i]; - to.push(v); - } - } - } - ts.addRange = addRange; - function rangeEquals(array1, array2, pos, end) { - while (pos < end) { - if (array1[pos] !== array2[pos]) { - return false; - } - pos++; - } - return true; - } - ts.rangeEquals = rangeEquals; - /** - * Returns the last element of an array if non-empty, undefined otherwise. - */ - function lastOrUndefined(array) { - if (array.length === 0) { - return undefined; - } - return array[array.length - 1]; - } - ts.lastOrUndefined = lastOrUndefined; - function binarySearch(array, value) { - var low = 0; - var high = array.length - 1; - while (low <= high) { - var middle = low + ((high - low) >> 1); - var midValue = array[middle]; - if (midValue === value) { - return middle; - } - else if (midValue > value) { - high = middle - 1; - } - else { - low = middle + 1; - } - } - return ~low; - } - ts.binarySearch = binarySearch; - function reduceLeft(array, f, initial) { - if (array) { - var count = array.length; - if (count > 0) { - var pos = 0; - var result = arguments.length <= 2 ? array[pos++] : initial; - while (pos < count) { - result = f(result, array[pos++]); - } - return result; - } - } - return initial; - } - ts.reduceLeft = reduceLeft; - function reduceRight(array, f, initial) { - if (array) { - var pos = array.length - 1; - if (pos >= 0) { - var result = arguments.length <= 2 ? array[pos--] : initial; - while (pos >= 0) { - result = f(result, array[pos--]); - } - return result; - } - } - return initial; - } - ts.reduceRight = reduceRight; - var hasOwnProperty = Object.prototype.hasOwnProperty; - function hasProperty(map, key) { - return hasOwnProperty.call(map, key); - } - ts.hasProperty = hasProperty; - function getProperty(map, key) { - return hasOwnProperty.call(map, key) ? map[key] : undefined; - } - ts.getProperty = getProperty; - function isEmpty(map) { - for (var id in map) { - if (hasProperty(map, id)) { - return false; - } - } - return true; - } - ts.isEmpty = isEmpty; - function clone(object) { - var result = {}; - for (var id in object) { - result[id] = object[id]; - } - return result; - } - ts.clone = clone; - function extend(first, second) { - var result = {}; - for (var id in first) { - result[id] = first[id]; - } - for (var id in second) { - if (!hasProperty(result, id)) { - result[id] = second[id]; - } - } - return result; - } - ts.extend = extend; - function forEachValue(map, callback) { - var result; - for (var id in map) { - if (result = callback(map[id])) - break; - } - return result; - } - ts.forEachValue = forEachValue; - function forEachKey(map, callback) { - var result; - for (var id in map) { - if (result = callback(id)) - break; - } - return result; - } - ts.forEachKey = forEachKey; - function lookUp(map, key) { - return hasProperty(map, key) ? map[key] : undefined; - } - ts.lookUp = lookUp; - function copyMap(source, target) { - for (var p in source) { - target[p] = source[p]; - } - } - ts.copyMap = copyMap; - /** - * Creates a map from the elements of an array. - * - * @param array the array of input elements. - * @param makeKey a function that produces a key for a given element. - * - * This function makes no effort to avoid collisions; if any two elements produce - * the same key with the given 'makeKey' function, then the element with the higher - * index in the array will be the one associated with the produced key. - */ - function arrayToMap(array, makeKey) { - var result = {}; - forEach(array, function (value) { - result[makeKey(value)] = value; - }); - return result; - } - ts.arrayToMap = arrayToMap; - function memoize(callback) { - var value; - return function () { - if (callback) { - value = callback(); - callback = undefined; - } - return value; - }; - } - ts.memoize = memoize; - function formatStringFromArgs(text, args, baseIndex) { - baseIndex = baseIndex || 0; - return text.replace(/{(\d+)}/g, function (match, index) { return args[+index + baseIndex]; }); - } - ts.localizedDiagnosticMessages = undefined; - function getLocaleSpecificMessage(message) { - return ts.localizedDiagnosticMessages && ts.localizedDiagnosticMessages[message] - ? ts.localizedDiagnosticMessages[message] - : message; - } - ts.getLocaleSpecificMessage = getLocaleSpecificMessage; - function createFileDiagnostic(file, start, length, message) { - var end = start + length; - Debug.assert(start >= 0, "start must be non-negative, is " + start); - Debug.assert(length >= 0, "length must be non-negative, is " + length); - if (file) { - Debug.assert(start <= file.text.length, "start must be within the bounds of the file. " + start + " > " + file.text.length); - Debug.assert(end <= file.text.length, "end must be the bounds of the file. " + end + " > " + file.text.length); - } - var text = getLocaleSpecificMessage(message.key); - if (arguments.length > 4) { - text = formatStringFromArgs(text, arguments, 4); - } - return { - file: file, - start: start, - length: length, - messageText: text, - category: message.category, - code: message.code - }; - } - ts.createFileDiagnostic = createFileDiagnostic; - function createCompilerDiagnostic(message) { - var text = getLocaleSpecificMessage(message.key); - if (arguments.length > 1) { - text = formatStringFromArgs(text, arguments, 1); - } - return { - file: undefined, - start: undefined, - length: undefined, - messageText: text, - category: message.category, - code: message.code - }; - } - ts.createCompilerDiagnostic = createCompilerDiagnostic; - function chainDiagnosticMessages(details, message) { - var text = getLocaleSpecificMessage(message.key); - if (arguments.length > 2) { - text = formatStringFromArgs(text, arguments, 2); - } - return { - messageText: text, - category: message.category, - code: message.code, - next: details - }; - } - ts.chainDiagnosticMessages = chainDiagnosticMessages; - function concatenateDiagnosticMessageChains(headChain, tailChain) { - Debug.assert(!headChain.next); - headChain.next = tailChain; - return headChain; - } - ts.concatenateDiagnosticMessageChains = concatenateDiagnosticMessageChains; - function compareValues(a, b) { - if (a === b) - return 0 /* EqualTo */; - if (a === undefined) - return -1 /* LessThan */; - if (b === undefined) - return 1 /* GreaterThan */; - return a < b ? -1 /* LessThan */ : 1 /* GreaterThan */; - } - ts.compareValues = compareValues; - function getDiagnosticFileName(diagnostic) { - return diagnostic.file ? diagnostic.file.fileName : undefined; - } - function compareDiagnostics(d1, d2) { - return compareValues(getDiagnosticFileName(d1), getDiagnosticFileName(d2)) || - compareValues(d1.start, d2.start) || - compareValues(d1.length, d2.length) || - compareValues(d1.code, d2.code) || - compareMessageText(d1.messageText, d2.messageText) || - 0 /* EqualTo */; - } - ts.compareDiagnostics = compareDiagnostics; - function compareMessageText(text1, text2) { - while (text1 && text2) { - // We still have both chains. - var string1 = typeof text1 === "string" ? text1 : text1.messageText; - var string2 = typeof text2 === "string" ? text2 : text2.messageText; - var res = compareValues(string1, string2); - if (res) { - return res; - } - text1 = typeof text1 === "string" ? undefined : text1.next; - text2 = typeof text2 === "string" ? undefined : text2.next; - } - if (!text1 && !text2) { - // if the chains are done, then these messages are the same. - return 0 /* EqualTo */; - } - // We still have one chain remaining. The shorter chain should come first. - return text1 ? 1 /* GreaterThan */ : -1 /* LessThan */; - } - function sortAndDeduplicateDiagnostics(diagnostics) { - return deduplicateSortedDiagnostics(diagnostics.sort(compareDiagnostics)); - } - ts.sortAndDeduplicateDiagnostics = sortAndDeduplicateDiagnostics; - function deduplicateSortedDiagnostics(diagnostics) { - if (diagnostics.length < 2) { - return diagnostics; - } - var newDiagnostics = [diagnostics[0]]; - var previousDiagnostic = diagnostics[0]; - for (var i = 1; i < diagnostics.length; i++) { - var currentDiagnostic = diagnostics[i]; - var isDupe = compareDiagnostics(currentDiagnostic, previousDiagnostic) === 0 /* EqualTo */; - if (!isDupe) { - newDiagnostics.push(currentDiagnostic); - previousDiagnostic = currentDiagnostic; - } - } - return newDiagnostics; - } - ts.deduplicateSortedDiagnostics = deduplicateSortedDiagnostics; - function normalizeSlashes(path) { - return path.replace(/\\/g, "/"); - } - ts.normalizeSlashes = normalizeSlashes; - // Returns length of path root (i.e. length of "/", "x:/", "//server/share/, file:///user/files") - function getRootLength(path) { - if (path.charCodeAt(0) === 47 /* slash */) { - if (path.charCodeAt(1) !== 47 /* slash */) - return 1; - var p1 = path.indexOf("/", 2); - if (p1 < 0) - return 2; - var p2 = path.indexOf("/", p1 + 1); - if (p2 < 0) - return p1 + 1; - return p2 + 1; - } - if (path.charCodeAt(1) === 58 /* colon */) { - if (path.charCodeAt(2) === 47 /* slash */) - return 3; - return 2; - } - // Per RFC 1738 'file' URI schema has the shape file:/// - // if is omitted then it is assumed that host value is 'localhost', - // however slash after the omitted is not removed. - // file:///folder1/file1 - this is a correct URI - // file://folder2/file2 - this is an incorrect URI - if (path.lastIndexOf("file:///", 0) === 0) { - return "file:///".length; - } - var idx = path.indexOf('://'); - if (idx !== -1) { - return idx + "://".length; - } - return 0; - } - ts.getRootLength = getRootLength; - ts.directorySeparator = "/"; - function getNormalizedParts(normalizedSlashedPath, rootLength) { - var parts = normalizedSlashedPath.substr(rootLength).split(ts.directorySeparator); - var normalized = []; - for (var _i = 0; _i < parts.length; _i++) { - var part = parts[_i]; - if (part !== ".") { - if (part === ".." && normalized.length > 0 && lastOrUndefined(normalized) !== "..") { - normalized.pop(); - } - else { - // A part may be an empty string (which is 'falsy') if the path had consecutive slashes, - // e.g. "path//file.ts". Drop these before re-joining the parts. - if (part) { - normalized.push(part); - } - } - } - } - return normalized; - } - function normalizePath(path) { - path = normalizeSlashes(path); - var rootLength = getRootLength(path); - var normalized = getNormalizedParts(path, rootLength); - return path.substr(0, rootLength) + normalized.join(ts.directorySeparator); - } - ts.normalizePath = normalizePath; - function getDirectoryPath(path) { - return path.substr(0, Math.max(getRootLength(path), path.lastIndexOf(ts.directorySeparator))); - } - ts.getDirectoryPath = getDirectoryPath; - function isUrl(path) { - return path && !isRootedDiskPath(path) && path.indexOf("://") !== -1; - } - ts.isUrl = isUrl; - function isRootedDiskPath(path) { - return getRootLength(path) !== 0; - } - ts.isRootedDiskPath = isRootedDiskPath; - function normalizedPathComponents(path, rootLength) { - var normalizedParts = getNormalizedParts(path, rootLength); - return [path.substr(0, rootLength)].concat(normalizedParts); - } - function getNormalizedPathComponents(path, currentDirectory) { - path = normalizeSlashes(path); - var rootLength = getRootLength(path); - if (rootLength == 0) { - // If the path is not rooted it is relative to current directory - path = combinePaths(normalizeSlashes(currentDirectory), path); - rootLength = getRootLength(path); - } - return normalizedPathComponents(path, rootLength); - } - ts.getNormalizedPathComponents = getNormalizedPathComponents; - function getNormalizedAbsolutePath(fileName, currentDirectory) { - return getNormalizedPathFromPathComponents(getNormalizedPathComponents(fileName, currentDirectory)); - } - ts.getNormalizedAbsolutePath = getNormalizedAbsolutePath; - function getNormalizedPathFromPathComponents(pathComponents) { - if (pathComponents && pathComponents.length) { - return pathComponents[0] + pathComponents.slice(1).join(ts.directorySeparator); - } - } - ts.getNormalizedPathFromPathComponents = getNormalizedPathFromPathComponents; - function getNormalizedPathComponentsOfUrl(url) { - // Get root length of http://www.website.com/folder1/foler2/ - // In this example the root is: http://www.website.com/ - // normalized path components should be ["http://www.website.com/", "folder1", "folder2"] - var urlLength = url.length; - // Initial root length is http:// part - var rootLength = url.indexOf("://") + "://".length; - while (rootLength < urlLength) { - // Consume all immediate slashes in the protocol - // eg.initial rootlength is just file:// but it needs to consume another "/" in file:/// - if (url.charCodeAt(rootLength) === 47 /* slash */) { - rootLength++; - } - else { - // non slash character means we continue proceeding to next component of root search - break; - } - } - // there are no parts after http:// just return current string as the pathComponent - if (rootLength === urlLength) { - return [url]; - } - // Find the index of "/" after website.com so the root can be http://www.website.com/ (from existing http://) - var indexOfNextSlash = url.indexOf(ts.directorySeparator, rootLength); - if (indexOfNextSlash !== -1) { - // Found the "/" after the website.com so the root is length of http://www.website.com/ - // and get components afetr the root normally like any other folder components - rootLength = indexOfNextSlash + 1; - return normalizedPathComponents(url, rootLength); - } - else { - // Can't find the host assume the rest of the string as component - // but make sure we append "/" to it as root is not joined using "/" - // eg. if url passed in was http://website.com we want to use root as [http://website.com/] - // so that other path manipulations will be correct and it can be merged with relative paths correctly - return [url + ts.directorySeparator]; - } - } - function getNormalizedPathOrUrlComponents(pathOrUrl, currentDirectory) { - if (isUrl(pathOrUrl)) { - return getNormalizedPathComponentsOfUrl(pathOrUrl); - } - else { - return getNormalizedPathComponents(pathOrUrl, currentDirectory); - } - } - function getRelativePathToDirectoryOrUrl(directoryPathOrUrl, relativeOrAbsolutePath, currentDirectory, getCanonicalFileName, isAbsolutePathAnUrl) { - var pathComponents = getNormalizedPathOrUrlComponents(relativeOrAbsolutePath, currentDirectory); - var directoryComponents = getNormalizedPathOrUrlComponents(directoryPathOrUrl, currentDirectory); - if (directoryComponents.length > 1 && lastOrUndefined(directoryComponents) === "") { - // If the directory path given was of type test/cases/ then we really need components of directory to be only till its name - // that is ["test", "cases", ""] needs to be actually ["test", "cases"] - directoryComponents.length--; - } - // Find the component that differs - for (var joinStartIndex = 0; joinStartIndex < pathComponents.length && joinStartIndex < directoryComponents.length; joinStartIndex++) { - if (getCanonicalFileName(directoryComponents[joinStartIndex]) !== getCanonicalFileName(pathComponents[joinStartIndex])) { - break; - } - } - // Get the relative path - if (joinStartIndex) { - var relativePath = ""; - var relativePathComponents = pathComponents.slice(joinStartIndex, pathComponents.length); - for (; joinStartIndex < directoryComponents.length; joinStartIndex++) { - if (directoryComponents[joinStartIndex] !== "") { - relativePath = relativePath + ".." + ts.directorySeparator; - } - } - return relativePath + relativePathComponents.join(ts.directorySeparator); - } - // Cant find the relative path, get the absolute path - var absolutePath = getNormalizedPathFromPathComponents(pathComponents); - if (isAbsolutePathAnUrl && isRootedDiskPath(absolutePath)) { - absolutePath = "file:///" + absolutePath; - } - return absolutePath; - } - ts.getRelativePathToDirectoryOrUrl = getRelativePathToDirectoryOrUrl; - function getBaseFileName(path) { - var i = path.lastIndexOf(ts.directorySeparator); - return i < 0 ? path : path.substring(i + 1); - } - ts.getBaseFileName = getBaseFileName; - function combinePaths(path1, path2) { - if (!(path1 && path1.length)) - return path2; - if (!(path2 && path2.length)) - return path1; - if (getRootLength(path2) !== 0) - return path2; - if (path1.charAt(path1.length - 1) === ts.directorySeparator) - return path1 + path2; - return path1 + ts.directorySeparator + path2; - } - ts.combinePaths = combinePaths; - function fileExtensionIs(path, extension) { - var pathLen = path.length; - var extLen = extension.length; - return pathLen > extLen && path.substr(pathLen - extLen, extLen) === extension; - } - ts.fileExtensionIs = fileExtensionIs; - /** - * List of supported extensions in order of file resolution precedence. - */ - ts.supportedExtensions = [".ts", ".d.ts"]; - var extensionsToRemove = [".d.ts", ".ts", ".js"]; - function removeFileExtension(path) { - for (var _i = 0; _i < extensionsToRemove.length; _i++) { - var ext = extensionsToRemove[_i]; - if (fileExtensionIs(path, ext)) { - return path.substr(0, path.length - ext.length); - } - } - return path; - } - ts.removeFileExtension = removeFileExtension; - var backslashOrDoubleQuote = /[\"\\]/g; - var escapedCharsRegExp = /[\u0000-\u001f\t\v\f\b\r\n\u2028\u2029\u0085]/g; - var escapedCharsMap = { - "\0": "\\0", - "\t": "\\t", - "\v": "\\v", - "\f": "\\f", - "\b": "\\b", - "\r": "\\r", - "\n": "\\n", - "\\": "\\\\", - "\"": "\\\"", - "\u2028": "\\u2028", - "\u2029": "\\u2029", - "\u0085": "\\u0085" // nextLine - }; - function Symbol(flags, name) { - this.flags = flags; - this.name = name; - this.declarations = undefined; - } - function Type(checker, flags) { - this.flags = flags; - } - function Signature(checker) { - } - ts.objectAllocator = { - getNodeConstructor: function (kind) { - function Node() { - } - Node.prototype = { - kind: kind, - pos: 0, - end: 0, - flags: 0, - parent: undefined - }; - return Node; - }, - getSymbolConstructor: function () { return Symbol; }, - getTypeConstructor: function () { return Type; }, - getSignatureConstructor: function () { return Signature; } - }; - (function (AssertionLevel) { - AssertionLevel[AssertionLevel["None"] = 0] = "None"; - AssertionLevel[AssertionLevel["Normal"] = 1] = "Normal"; - AssertionLevel[AssertionLevel["Aggressive"] = 2] = "Aggressive"; - AssertionLevel[AssertionLevel["VeryAggressive"] = 3] = "VeryAggressive"; - })(ts.AssertionLevel || (ts.AssertionLevel = {})); - var AssertionLevel = ts.AssertionLevel; - var Debug; - (function (Debug) { - var currentAssertionLevel = 0 /* None */; - function shouldAssert(level) { - return currentAssertionLevel >= level; - } - Debug.shouldAssert = shouldAssert; - function assert(expression, message, verboseDebugInfo) { - if (!expression) { - var verboseDebugString = ""; - if (verboseDebugInfo) { - verboseDebugString = "\r\nVerbose Debug Information: " + verboseDebugInfo(); - } - throw new Error("Debug Failure. False expression: " + (message || "") + verboseDebugString); - } - } - Debug.assert = assert; - function fail(message) { - Debug.assert(false, message); - } - Debug.fail = fail; - })(Debug = ts.Debug || (ts.Debug = {})); -})(ts || (ts = {})); -/// -var ts; -(function (ts) { - ts.sys = (function () { - function getWScriptSystem() { - var fso = new ActiveXObject("Scripting.FileSystemObject"); - var fileStream = new ActiveXObject("ADODB.Stream"); - fileStream.Type = 2 /*text*/; - var binaryStream = new ActiveXObject("ADODB.Stream"); - binaryStream.Type = 1 /*binary*/; - var args = []; - for (var i = 0; i < WScript.Arguments.length; i++) { - args[i] = WScript.Arguments.Item(i); - } - function readFile(fileName, encoding) { - if (!fso.FileExists(fileName)) { - return undefined; - } - fileStream.Open(); - try { - if (encoding) { - fileStream.Charset = encoding; - fileStream.LoadFromFile(fileName); - } - else { - // Load file and read the first two bytes into a string with no interpretation - fileStream.Charset = "x-ansi"; - fileStream.LoadFromFile(fileName); - var bom = fileStream.ReadText(2) || ""; - // Position must be at 0 before encoding can be changed - fileStream.Position = 0; - // [0xFF,0xFE] and [0xFE,0xFF] mean utf-16 (little or big endian), otherwise default to utf-8 - fileStream.Charset = bom.length >= 2 && (bom.charCodeAt(0) === 0xFF && bom.charCodeAt(1) === 0xFE || bom.charCodeAt(0) === 0xFE && bom.charCodeAt(1) === 0xFF) ? "unicode" : "utf-8"; - } - // ReadText method always strips byte order mark from resulting string - return fileStream.ReadText(); - } - catch (e) { - throw e; - } - finally { - fileStream.Close(); - } - } - function writeFile(fileName, data, writeByteOrderMark) { - fileStream.Open(); - binaryStream.Open(); - try { - // Write characters in UTF-8 encoding - fileStream.Charset = "utf-8"; - fileStream.WriteText(data); - // If we don't want the BOM, then skip it by setting the starting location to 3 (size of BOM). - // If not, start from position 0, as the BOM will be added automatically when charset==utf8. - if (writeByteOrderMark) { - fileStream.Position = 0; - } - else { - fileStream.Position = 3; - } - fileStream.CopyTo(binaryStream); - binaryStream.SaveToFile(fileName, 2 /*overwrite*/); - } - finally { - binaryStream.Close(); - fileStream.Close(); - } - } - function getCanonicalPath(path) { - return path.toLowerCase(); - } - function getNames(collection) { - var result = []; - for (var e = new Enumerator(collection); !e.atEnd(); e.moveNext()) { - result.push(e.item().Name); - } - return result.sort(); - } - function readDirectory(path, extension, exclude) { - var result = []; - exclude = ts.map(exclude, function (s) { return getCanonicalPath(ts.combinePaths(path, s)); }); - visitDirectory(path); - return result; - function visitDirectory(path) { - var folder = fso.GetFolder(path || "."); - var files = getNames(folder.files); - for (var _i = 0; _i < files.length; _i++) { - var current = files[_i]; - var name_1 = ts.combinePaths(path, current); - if ((!extension || ts.fileExtensionIs(name_1, extension)) && !ts.contains(exclude, getCanonicalPath(name_1))) { - result.push(name_1); - } - } - var subfolders = getNames(folder.subfolders); - for (var _a = 0; _a < subfolders.length; _a++) { - var current = subfolders[_a]; - var name_2 = ts.combinePaths(path, current); - if (!ts.contains(exclude, getCanonicalPath(name_2))) { - visitDirectory(name_2); - } - } - } - } - return { - args: args, - newLine: "\r\n", - useCaseSensitiveFileNames: false, - write: function (s) { - WScript.StdOut.Write(s); - }, - readFile: readFile, - writeFile: writeFile, - resolvePath: function (path) { - return fso.GetAbsolutePathName(path); - }, - fileExists: function (path) { - return fso.FileExists(path); - }, - directoryExists: function (path) { - return fso.FolderExists(path); - }, - createDirectory: function (directoryName) { - if (!this.directoryExists(directoryName)) { - fso.CreateFolder(directoryName); - } - }, - getExecutingFilePath: function () { - return WScript.ScriptFullName; - }, - getCurrentDirectory: function () { - return new ActiveXObject("WScript.Shell").CurrentDirectory; - }, - readDirectory: readDirectory, - exit: function (exitCode) { - try { - WScript.Quit(exitCode); - } - catch (e) { - } - } - }; - } - function getNodeSystem() { - var _fs = require("fs"); - var _path = require("path"); - var _os = require('os'); - var platform = _os.platform(); - // win32\win64 are case insensitive platforms, MacOS (darwin) by default is also case insensitive - var useCaseSensitiveFileNames = platform !== "win32" && platform !== "win64" && platform !== "darwin"; - function readFile(fileName, encoding) { - if (!_fs.existsSync(fileName)) { - return undefined; - } - var buffer = _fs.readFileSync(fileName); - var len = buffer.length; - if (len >= 2 && buffer[0] === 0xFE && buffer[1] === 0xFF) { - // Big endian UTF-16 byte order mark detected. Since big endian is not supported by node.js, - // flip all byte pairs and treat as little endian. - len &= ~1; - for (var i = 0; i < len; i += 2) { - var temp = buffer[i]; - buffer[i] = buffer[i + 1]; - buffer[i + 1] = temp; - } - return buffer.toString("utf16le", 2); - } - if (len >= 2 && buffer[0] === 0xFF && buffer[1] === 0xFE) { - // Little endian UTF-16 byte order mark detected - return buffer.toString("utf16le", 2); - } - if (len >= 3 && buffer[0] === 0xEF && buffer[1] === 0xBB && buffer[2] === 0xBF) { - // UTF-8 byte order mark detected - return buffer.toString("utf8", 3); - } - // Default is UTF-8 with no byte order mark - return buffer.toString("utf8"); - } - function writeFile(fileName, data, writeByteOrderMark) { - // If a BOM is required, emit one - if (writeByteOrderMark) { - data = '\uFEFF' + data; - } - _fs.writeFileSync(fileName, data, "utf8"); - } - function getCanonicalPath(path) { - return useCaseSensitiveFileNames ? path.toLowerCase() : path; - } - function readDirectory(path, extension, exclude) { - var result = []; - exclude = ts.map(exclude, function (s) { return getCanonicalPath(ts.combinePaths(path, s)); }); - visitDirectory(path); - return result; - function visitDirectory(path) { - var files = _fs.readdirSync(path || ".").sort(); - var directories = []; - for (var _i = 0; _i < files.length; _i++) { - var current = files[_i]; - var name = ts.combinePaths(path, current); - if (!ts.contains(exclude, getCanonicalPath(name))) { - var stat = _fs.statSync(name); - if (stat.isFile()) { - if (!extension || ts.fileExtensionIs(name, extension)) { - result.push(name); - } - } - else if (stat.isDirectory()) { - directories.push(name); - } - } - } - for (var _a = 0; _a < directories.length; _a++) { - var current = directories[_a]; - visitDirectory(current); - } - } - } - return { - args: process.argv.slice(2), - newLine: _os.EOL, - useCaseSensitiveFileNames: useCaseSensitiveFileNames, - write: function (s) { - // 1 is a standard descriptor for stdout - _fs.writeSync(1, s); - }, - readFile: readFile, - writeFile: writeFile, - watchFile: function (fileName, callback) { - // watchFile polls a file every 250ms, picking up file notifications. - _fs.watchFile(fileName, { persistent: true, interval: 250 }, fileChanged); - return { - close: function () { _fs.unwatchFile(fileName, fileChanged); } - }; - function fileChanged(curr, prev) { - if (+curr.mtime <= +prev.mtime) { - return; - } - callback(fileName); - } - ; - }, - resolvePath: function (path) { - return _path.resolve(path); - }, - fileExists: function (path) { - return _fs.existsSync(path); - }, - directoryExists: function (path) { - return _fs.existsSync(path) && _fs.statSync(path).isDirectory(); - }, - createDirectory: function (directoryName) { - if (!this.directoryExists(directoryName)) { - _fs.mkdirSync(directoryName); - } - }, - getExecutingFilePath: function () { - return __filename; - }, - getCurrentDirectory: function () { - return process.cwd(); - }, - readDirectory: readDirectory, - getMemoryUsage: function () { - if (global.gc) { - global.gc(); - } - return process.memoryUsage().heapUsed; - }, - exit: function (exitCode) { - process.exit(exitCode); - } - }; - } - if (typeof WScript !== "undefined" && typeof ActiveXObject === "function") { - return getWScriptSystem(); - } - else if (typeof module !== "undefined" && module.exports) { - return getNodeSystem(); - } - else { - return undefined; // Unsupported host - } - })(); -})(ts || (ts = {})); -// -/// -/* @internal */ -var ts; -(function (ts) { - ts.Diagnostics = { - Unterminated_string_literal: { code: 1002, category: ts.DiagnosticCategory.Error, key: "Unterminated string literal." }, - Identifier_expected: { code: 1003, category: ts.DiagnosticCategory.Error, key: "Identifier expected." }, - _0_expected: { code: 1005, category: ts.DiagnosticCategory.Error, key: "'{0}' expected." }, - A_file_cannot_have_a_reference_to_itself: { code: 1006, category: ts.DiagnosticCategory.Error, key: "A file cannot have a reference to itself." }, - Trailing_comma_not_allowed: { code: 1009, category: ts.DiagnosticCategory.Error, key: "Trailing comma not allowed." }, - Asterisk_Slash_expected: { code: 1010, category: ts.DiagnosticCategory.Error, key: "'*/' expected." }, - Unexpected_token: { code: 1012, category: ts.DiagnosticCategory.Error, key: "Unexpected token." }, - A_rest_parameter_must_be_last_in_a_parameter_list: { code: 1014, category: ts.DiagnosticCategory.Error, key: "A rest parameter must be last in a parameter list." }, - Parameter_cannot_have_question_mark_and_initializer: { code: 1015, category: ts.DiagnosticCategory.Error, key: "Parameter cannot have question mark and initializer." }, - A_required_parameter_cannot_follow_an_optional_parameter: { code: 1016, category: ts.DiagnosticCategory.Error, key: "A required parameter cannot follow an optional parameter." }, - An_index_signature_cannot_have_a_rest_parameter: { code: 1017, category: ts.DiagnosticCategory.Error, key: "An index signature cannot have a rest parameter." }, - An_index_signature_parameter_cannot_have_an_accessibility_modifier: { code: 1018, category: ts.DiagnosticCategory.Error, key: "An index signature parameter cannot have an accessibility modifier." }, - An_index_signature_parameter_cannot_have_a_question_mark: { code: 1019, category: ts.DiagnosticCategory.Error, key: "An index signature parameter cannot have a question mark." }, - An_index_signature_parameter_cannot_have_an_initializer: { code: 1020, category: ts.DiagnosticCategory.Error, key: "An index signature parameter cannot have an initializer." }, - An_index_signature_must_have_a_type_annotation: { code: 1021, category: ts.DiagnosticCategory.Error, key: "An index signature must have a type annotation." }, - An_index_signature_parameter_must_have_a_type_annotation: { code: 1022, category: ts.DiagnosticCategory.Error, key: "An index signature parameter must have a type annotation." }, - An_index_signature_parameter_type_must_be_string_or_number: { code: 1023, category: ts.DiagnosticCategory.Error, key: "An index signature parameter type must be 'string' or 'number'." }, - A_class_or_interface_declaration_can_only_have_one_extends_clause: { code: 1024, category: ts.DiagnosticCategory.Error, key: "A class or interface declaration can only have one 'extends' clause." }, - An_extends_clause_must_precede_an_implements_clause: { code: 1025, category: ts.DiagnosticCategory.Error, key: "An 'extends' clause must precede an 'implements' clause." }, - A_class_can_only_extend_a_single_class: { code: 1026, category: ts.DiagnosticCategory.Error, key: "A class can only extend a single class." }, - A_class_declaration_can_only_have_one_implements_clause: { code: 1027, category: ts.DiagnosticCategory.Error, key: "A class declaration can only have one 'implements' clause." }, - Accessibility_modifier_already_seen: { code: 1028, category: ts.DiagnosticCategory.Error, key: "Accessibility modifier already seen." }, - _0_modifier_must_precede_1_modifier: { code: 1029, category: ts.DiagnosticCategory.Error, key: "'{0}' modifier must precede '{1}' modifier." }, - _0_modifier_already_seen: { code: 1030, category: ts.DiagnosticCategory.Error, key: "'{0}' modifier already seen." }, - _0_modifier_cannot_appear_on_a_class_element: { code: 1031, category: ts.DiagnosticCategory.Error, key: "'{0}' modifier cannot appear on a class element." }, - An_interface_declaration_cannot_have_an_implements_clause: { code: 1032, category: ts.DiagnosticCategory.Error, key: "An interface declaration cannot have an 'implements' clause." }, - super_must_be_followed_by_an_argument_list_or_member_access: { code: 1034, category: ts.DiagnosticCategory.Error, key: "'super' must be followed by an argument list or member access." }, - Only_ambient_modules_can_use_quoted_names: { code: 1035, category: ts.DiagnosticCategory.Error, key: "Only ambient modules can use quoted names." }, - Statements_are_not_allowed_in_ambient_contexts: { code: 1036, category: ts.DiagnosticCategory.Error, key: "Statements are not allowed in ambient contexts." }, - A_declare_modifier_cannot_be_used_in_an_already_ambient_context: { code: 1038, category: ts.DiagnosticCategory.Error, key: "A 'declare' modifier cannot be used in an already ambient context." }, - Initializers_are_not_allowed_in_ambient_contexts: { code: 1039, category: ts.DiagnosticCategory.Error, key: "Initializers are not allowed in ambient contexts." }, - _0_modifier_cannot_appear_on_a_module_element: { code: 1044, category: ts.DiagnosticCategory.Error, key: "'{0}' modifier cannot appear on a module element." }, - A_declare_modifier_cannot_be_used_with_an_interface_declaration: { code: 1045, category: ts.DiagnosticCategory.Error, key: "A 'declare' modifier cannot be used with an interface declaration." }, - A_declare_modifier_is_required_for_a_top_level_declaration_in_a_d_ts_file: { code: 1046, category: ts.DiagnosticCategory.Error, key: "A 'declare' modifier is required for a top level declaration in a .d.ts file." }, - A_rest_parameter_cannot_be_optional: { code: 1047, category: ts.DiagnosticCategory.Error, key: "A rest parameter cannot be optional." }, - A_rest_parameter_cannot_have_an_initializer: { code: 1048, category: ts.DiagnosticCategory.Error, key: "A rest parameter cannot have an initializer." }, - A_set_accessor_must_have_exactly_one_parameter: { code: 1049, category: ts.DiagnosticCategory.Error, key: "A 'set' accessor must have exactly one parameter." }, - A_set_accessor_cannot_have_an_optional_parameter: { code: 1051, category: ts.DiagnosticCategory.Error, key: "A 'set' accessor cannot have an optional parameter." }, - A_set_accessor_parameter_cannot_have_an_initializer: { code: 1052, category: ts.DiagnosticCategory.Error, key: "A 'set' accessor parameter cannot have an initializer." }, - A_set_accessor_cannot_have_rest_parameter: { code: 1053, category: ts.DiagnosticCategory.Error, key: "A 'set' accessor cannot have rest parameter." }, - A_get_accessor_cannot_have_parameters: { code: 1054, category: ts.DiagnosticCategory.Error, key: "A 'get' accessor cannot have parameters." }, - Accessors_are_only_available_when_targeting_ECMAScript_5_and_higher: { code: 1056, category: ts.DiagnosticCategory.Error, key: "Accessors are only available when targeting ECMAScript 5 and higher." }, - Enum_member_must_have_initializer: { code: 1061, category: ts.DiagnosticCategory.Error, key: "Enum member must have initializer." }, - An_export_assignment_cannot_be_used_in_a_namespace: { code: 1063, category: ts.DiagnosticCategory.Error, key: "An export assignment cannot be used in a namespace." }, - Ambient_enum_elements_can_only_have_integer_literal_initializers: { code: 1066, category: ts.DiagnosticCategory.Error, key: "Ambient enum elements can only have integer literal initializers." }, - Unexpected_token_A_constructor_method_accessor_or_property_was_expected: { code: 1068, category: ts.DiagnosticCategory.Error, key: "Unexpected token. A constructor, method, accessor, or property was expected." }, - A_declare_modifier_cannot_be_used_with_an_import_declaration: { code: 1079, category: ts.DiagnosticCategory.Error, key: "A 'declare' modifier cannot be used with an import declaration." }, - Invalid_reference_directive_syntax: { code: 1084, category: ts.DiagnosticCategory.Error, key: "Invalid 'reference' directive syntax." }, - Octal_literals_are_not_available_when_targeting_ECMAScript_5_and_higher: { code: 1085, category: ts.DiagnosticCategory.Error, key: "Octal literals are not available when targeting ECMAScript 5 and higher." }, - An_accessor_cannot_be_declared_in_an_ambient_context: { code: 1086, category: ts.DiagnosticCategory.Error, key: "An accessor cannot be declared in an ambient context." }, - _0_modifier_cannot_appear_on_a_constructor_declaration: { code: 1089, category: ts.DiagnosticCategory.Error, key: "'{0}' modifier cannot appear on a constructor declaration." }, - _0_modifier_cannot_appear_on_a_parameter: { code: 1090, category: ts.DiagnosticCategory.Error, key: "'{0}' modifier cannot appear on a parameter." }, - Only_a_single_variable_declaration_is_allowed_in_a_for_in_statement: { code: 1091, category: ts.DiagnosticCategory.Error, key: "Only a single variable declaration is allowed in a 'for...in' statement." }, - Type_parameters_cannot_appear_on_a_constructor_declaration: { code: 1092, category: ts.DiagnosticCategory.Error, key: "Type parameters cannot appear on a constructor declaration." }, - Type_annotation_cannot_appear_on_a_constructor_declaration: { code: 1093, category: ts.DiagnosticCategory.Error, key: "Type annotation cannot appear on a constructor declaration." }, - An_accessor_cannot_have_type_parameters: { code: 1094, category: ts.DiagnosticCategory.Error, key: "An accessor cannot have type parameters." }, - A_set_accessor_cannot_have_a_return_type_annotation: { code: 1095, category: ts.DiagnosticCategory.Error, key: "A 'set' accessor cannot have a return type annotation." }, - An_index_signature_must_have_exactly_one_parameter: { code: 1096, category: ts.DiagnosticCategory.Error, key: "An index signature must have exactly one parameter." }, - _0_list_cannot_be_empty: { code: 1097, category: ts.DiagnosticCategory.Error, key: "'{0}' list cannot be empty." }, - Type_parameter_list_cannot_be_empty: { code: 1098, category: ts.DiagnosticCategory.Error, key: "Type parameter list cannot be empty." }, - Type_argument_list_cannot_be_empty: { code: 1099, category: ts.DiagnosticCategory.Error, key: "Type argument list cannot be empty." }, - Invalid_use_of_0_in_strict_mode: { code: 1100, category: ts.DiagnosticCategory.Error, key: "Invalid use of '{0}' in strict mode." }, - with_statements_are_not_allowed_in_strict_mode: { code: 1101, category: ts.DiagnosticCategory.Error, key: "'with' statements are not allowed in strict mode." }, - delete_cannot_be_called_on_an_identifier_in_strict_mode: { code: 1102, category: ts.DiagnosticCategory.Error, key: "'delete' cannot be called on an identifier in strict mode." }, - A_continue_statement_can_only_be_used_within_an_enclosing_iteration_statement: { code: 1104, category: ts.DiagnosticCategory.Error, key: "A 'continue' statement can only be used within an enclosing iteration statement." }, - A_break_statement_can_only_be_used_within_an_enclosing_iteration_or_switch_statement: { code: 1105, category: ts.DiagnosticCategory.Error, key: "A 'break' statement can only be used within an enclosing iteration or switch statement." }, - Jump_target_cannot_cross_function_boundary: { code: 1107, category: ts.DiagnosticCategory.Error, key: "Jump target cannot cross function boundary." }, - A_return_statement_can_only_be_used_within_a_function_body: { code: 1108, category: ts.DiagnosticCategory.Error, key: "A 'return' statement can only be used within a function body." }, - Expression_expected: { code: 1109, category: ts.DiagnosticCategory.Error, key: "Expression expected." }, - Type_expected: { code: 1110, category: ts.DiagnosticCategory.Error, key: "Type expected." }, - A_class_member_cannot_be_declared_optional: { code: 1112, category: ts.DiagnosticCategory.Error, key: "A class member cannot be declared optional." }, - A_default_clause_cannot_appear_more_than_once_in_a_switch_statement: { code: 1113, category: ts.DiagnosticCategory.Error, key: "A 'default' clause cannot appear more than once in a 'switch' statement." }, - Duplicate_label_0: { code: 1114, category: ts.DiagnosticCategory.Error, key: "Duplicate label '{0}'" }, - A_continue_statement_can_only_jump_to_a_label_of_an_enclosing_iteration_statement: { code: 1115, category: ts.DiagnosticCategory.Error, key: "A 'continue' statement can only jump to a label of an enclosing iteration statement." }, - A_break_statement_can_only_jump_to_a_label_of_an_enclosing_statement: { code: 1116, category: ts.DiagnosticCategory.Error, key: "A 'break' statement can only jump to a label of an enclosing statement." }, - An_object_literal_cannot_have_multiple_properties_with_the_same_name_in_strict_mode: { code: 1117, category: ts.DiagnosticCategory.Error, key: "An object literal cannot have multiple properties with the same name in strict mode." }, - An_object_literal_cannot_have_multiple_get_Slashset_accessors_with_the_same_name: { code: 1118, category: ts.DiagnosticCategory.Error, key: "An object literal cannot have multiple get/set accessors with the same name." }, - An_object_literal_cannot_have_property_and_accessor_with_the_same_name: { code: 1119, category: ts.DiagnosticCategory.Error, key: "An object literal cannot have property and accessor with the same name." }, - An_export_assignment_cannot_have_modifiers: { code: 1120, category: ts.DiagnosticCategory.Error, key: "An export assignment cannot have modifiers." }, - Octal_literals_are_not_allowed_in_strict_mode: { code: 1121, category: ts.DiagnosticCategory.Error, key: "Octal literals are not allowed in strict mode." }, - A_tuple_type_element_list_cannot_be_empty: { code: 1122, category: ts.DiagnosticCategory.Error, key: "A tuple type element list cannot be empty." }, - Variable_declaration_list_cannot_be_empty: { code: 1123, category: ts.DiagnosticCategory.Error, key: "Variable declaration list cannot be empty." }, - Digit_expected: { code: 1124, category: ts.DiagnosticCategory.Error, key: "Digit expected." }, - Hexadecimal_digit_expected: { code: 1125, category: ts.DiagnosticCategory.Error, key: "Hexadecimal digit expected." }, - Unexpected_end_of_text: { code: 1126, category: ts.DiagnosticCategory.Error, key: "Unexpected end of text." }, - Invalid_character: { code: 1127, category: ts.DiagnosticCategory.Error, key: "Invalid character." }, - Declaration_or_statement_expected: { code: 1128, category: ts.DiagnosticCategory.Error, key: "Declaration or statement expected." }, - Statement_expected: { code: 1129, category: ts.DiagnosticCategory.Error, key: "Statement expected." }, - case_or_default_expected: { code: 1130, category: ts.DiagnosticCategory.Error, key: "'case' or 'default' expected." }, - Property_or_signature_expected: { code: 1131, category: ts.DiagnosticCategory.Error, key: "Property or signature expected." }, - Enum_member_expected: { code: 1132, category: ts.DiagnosticCategory.Error, key: "Enum member expected." }, - Type_reference_expected: { code: 1133, category: ts.DiagnosticCategory.Error, key: "Type reference expected." }, - Variable_declaration_expected: { code: 1134, category: ts.DiagnosticCategory.Error, key: "Variable declaration expected." }, - Argument_expression_expected: { code: 1135, category: ts.DiagnosticCategory.Error, key: "Argument expression expected." }, - Property_assignment_expected: { code: 1136, category: ts.DiagnosticCategory.Error, key: "Property assignment expected." }, - Expression_or_comma_expected: { code: 1137, category: ts.DiagnosticCategory.Error, key: "Expression or comma expected." }, - Parameter_declaration_expected: { code: 1138, category: ts.DiagnosticCategory.Error, key: "Parameter declaration expected." }, - Type_parameter_declaration_expected: { code: 1139, category: ts.DiagnosticCategory.Error, key: "Type parameter declaration expected." }, - Type_argument_expected: { code: 1140, category: ts.DiagnosticCategory.Error, key: "Type argument expected." }, - String_literal_expected: { code: 1141, category: ts.DiagnosticCategory.Error, key: "String literal expected." }, - Line_break_not_permitted_here: { code: 1142, category: ts.DiagnosticCategory.Error, key: "Line break not permitted here." }, - or_expected: { code: 1144, category: ts.DiagnosticCategory.Error, key: "'{' or ';' expected." }, - Modifiers_not_permitted_on_index_signature_members: { code: 1145, category: ts.DiagnosticCategory.Error, key: "Modifiers not permitted on index signature members." }, - Declaration_expected: { code: 1146, category: ts.DiagnosticCategory.Error, key: "Declaration expected." }, - Import_declarations_in_a_namespace_cannot_reference_a_module: { code: 1147, category: ts.DiagnosticCategory.Error, key: "Import declarations in a namespace cannot reference a module." }, - Cannot_compile_modules_unless_the_module_flag_is_provided: { code: 1148, category: ts.DiagnosticCategory.Error, key: "Cannot compile modules unless the '--module' flag is provided." }, - File_name_0_differs_from_already_included_file_name_1_only_in_casing: { code: 1149, category: ts.DiagnosticCategory.Error, key: "File name '{0}' differs from already included file name '{1}' only in casing" }, - new_T_cannot_be_used_to_create_an_array_Use_new_Array_T_instead: { code: 1150, category: ts.DiagnosticCategory.Error, key: "'new T[]' cannot be used to create an array. Use 'new Array()' instead." }, - var_let_or_const_expected: { code: 1152, category: ts.DiagnosticCategory.Error, key: "'var', 'let' or 'const' expected." }, - let_declarations_are_only_available_when_targeting_ECMAScript_6_and_higher: { code: 1153, category: ts.DiagnosticCategory.Error, key: "'let' declarations are only available when targeting ECMAScript 6 and higher." }, - const_declarations_are_only_available_when_targeting_ECMAScript_6_and_higher: { code: 1154, category: ts.DiagnosticCategory.Error, key: "'const' declarations are only available when targeting ECMAScript 6 and higher." }, - const_declarations_must_be_initialized: { code: 1155, category: ts.DiagnosticCategory.Error, key: "'const' declarations must be initialized" }, - const_declarations_can_only_be_declared_inside_a_block: { code: 1156, category: ts.DiagnosticCategory.Error, key: "'const' declarations can only be declared inside a block." }, - let_declarations_can_only_be_declared_inside_a_block: { code: 1157, category: ts.DiagnosticCategory.Error, key: "'let' declarations can only be declared inside a block." }, - Unterminated_template_literal: { code: 1160, category: ts.DiagnosticCategory.Error, key: "Unterminated template literal." }, - Unterminated_regular_expression_literal: { code: 1161, category: ts.DiagnosticCategory.Error, key: "Unterminated regular expression literal." }, - An_object_member_cannot_be_declared_optional: { code: 1162, category: ts.DiagnosticCategory.Error, key: "An object member cannot be declared optional." }, - A_yield_expression_is_only_allowed_in_a_generator_body: { code: 1163, category: ts.DiagnosticCategory.Error, key: "A 'yield' expression is only allowed in a generator body." }, - Computed_property_names_are_not_allowed_in_enums: { code: 1164, category: ts.DiagnosticCategory.Error, key: "Computed property names are not allowed in enums." }, - A_computed_property_name_in_an_ambient_context_must_directly_refer_to_a_built_in_symbol: { code: 1165, category: ts.DiagnosticCategory.Error, key: "A computed property name in an ambient context must directly refer to a built-in symbol." }, - A_computed_property_name_in_a_class_property_declaration_must_directly_refer_to_a_built_in_symbol: { code: 1166, category: ts.DiagnosticCategory.Error, key: "A computed property name in a class property declaration must directly refer to a built-in symbol." }, - Computed_property_names_are_only_available_when_targeting_ECMAScript_6_and_higher: { code: 1167, category: ts.DiagnosticCategory.Error, key: "Computed property names are only available when targeting ECMAScript 6 and higher." }, - A_computed_property_name_in_a_method_overload_must_directly_refer_to_a_built_in_symbol: { code: 1168, category: ts.DiagnosticCategory.Error, key: "A computed property name in a method overload must directly refer to a built-in symbol." }, - A_computed_property_name_in_an_interface_must_directly_refer_to_a_built_in_symbol: { code: 1169, category: ts.DiagnosticCategory.Error, key: "A computed property name in an interface must directly refer to a built-in symbol." }, - A_computed_property_name_in_a_type_literal_must_directly_refer_to_a_built_in_symbol: { code: 1170, category: ts.DiagnosticCategory.Error, key: "A computed property name in a type literal must directly refer to a built-in symbol." }, - A_comma_expression_is_not_allowed_in_a_computed_property_name: { code: 1171, category: ts.DiagnosticCategory.Error, key: "A comma expression is not allowed in a computed property name." }, - extends_clause_already_seen: { code: 1172, category: ts.DiagnosticCategory.Error, key: "'extends' clause already seen." }, - extends_clause_must_precede_implements_clause: { code: 1173, category: ts.DiagnosticCategory.Error, key: "'extends' clause must precede 'implements' clause." }, - Classes_can_only_extend_a_single_class: { code: 1174, category: ts.DiagnosticCategory.Error, key: "Classes can only extend a single class." }, - implements_clause_already_seen: { code: 1175, category: ts.DiagnosticCategory.Error, key: "'implements' clause already seen." }, - Interface_declaration_cannot_have_implements_clause: { code: 1176, category: ts.DiagnosticCategory.Error, key: "Interface declaration cannot have 'implements' clause." }, - Binary_digit_expected: { code: 1177, category: ts.DiagnosticCategory.Error, key: "Binary digit expected." }, - Octal_digit_expected: { code: 1178, category: ts.DiagnosticCategory.Error, key: "Octal digit expected." }, - Unexpected_token_expected: { code: 1179, category: ts.DiagnosticCategory.Error, key: "Unexpected token. '{' expected." }, - Property_destructuring_pattern_expected: { code: 1180, category: ts.DiagnosticCategory.Error, key: "Property destructuring pattern expected." }, - Array_element_destructuring_pattern_expected: { code: 1181, category: ts.DiagnosticCategory.Error, key: "Array element destructuring pattern expected." }, - A_destructuring_declaration_must_have_an_initializer: { code: 1182, category: ts.DiagnosticCategory.Error, key: "A destructuring declaration must have an initializer." }, - Destructuring_declarations_are_not_allowed_in_ambient_contexts: { code: 1183, category: ts.DiagnosticCategory.Error, key: "Destructuring declarations are not allowed in ambient contexts." }, - An_implementation_cannot_be_declared_in_ambient_contexts: { code: 1184, category: ts.DiagnosticCategory.Error, key: "An implementation cannot be declared in ambient contexts." }, - Modifiers_cannot_appear_here: { code: 1184, category: ts.DiagnosticCategory.Error, key: "Modifiers cannot appear here." }, - Merge_conflict_marker_encountered: { code: 1185, category: ts.DiagnosticCategory.Error, key: "Merge conflict marker encountered." }, - A_rest_element_cannot_have_an_initializer: { code: 1186, category: ts.DiagnosticCategory.Error, key: "A rest element cannot have an initializer." }, - A_parameter_property_may_not_be_a_binding_pattern: { code: 1187, category: ts.DiagnosticCategory.Error, key: "A parameter property may not be a binding pattern." }, - Only_a_single_variable_declaration_is_allowed_in_a_for_of_statement: { code: 1188, category: ts.DiagnosticCategory.Error, key: "Only a single variable declaration is allowed in a 'for...of' statement." }, - The_variable_declaration_of_a_for_in_statement_cannot_have_an_initializer: { code: 1189, category: ts.DiagnosticCategory.Error, key: "The variable declaration of a 'for...in' statement cannot have an initializer." }, - The_variable_declaration_of_a_for_of_statement_cannot_have_an_initializer: { code: 1190, category: ts.DiagnosticCategory.Error, key: "The variable declaration of a 'for...of' statement cannot have an initializer." }, - An_import_declaration_cannot_have_modifiers: { code: 1191, category: ts.DiagnosticCategory.Error, key: "An import declaration cannot have modifiers." }, - Module_0_has_no_default_export: { code: 1192, category: ts.DiagnosticCategory.Error, key: "Module '{0}' has no default export." }, - An_export_declaration_cannot_have_modifiers: { code: 1193, category: ts.DiagnosticCategory.Error, key: "An export declaration cannot have modifiers." }, - Export_declarations_are_not_permitted_in_a_namespace: { code: 1194, category: ts.DiagnosticCategory.Error, key: "Export declarations are not permitted in a namespace." }, - Catch_clause_variable_name_must_be_an_identifier: { code: 1195, category: ts.DiagnosticCategory.Error, key: "Catch clause variable name must be an identifier." }, - Catch_clause_variable_cannot_have_a_type_annotation: { code: 1196, category: ts.DiagnosticCategory.Error, key: "Catch clause variable cannot have a type annotation." }, - Catch_clause_variable_cannot_have_an_initializer: { code: 1197, category: ts.DiagnosticCategory.Error, key: "Catch clause variable cannot have an initializer." }, - An_extended_Unicode_escape_value_must_be_between_0x0_and_0x10FFFF_inclusive: { code: 1198, category: ts.DiagnosticCategory.Error, key: "An extended Unicode escape value must be between 0x0 and 0x10FFFF inclusive." }, - Unterminated_Unicode_escape_sequence: { code: 1199, category: ts.DiagnosticCategory.Error, key: "Unterminated Unicode escape sequence." }, - Line_terminator_not_permitted_before_arrow: { code: 1200, category: ts.DiagnosticCategory.Error, key: "Line terminator not permitted before arrow." }, - Import_assignment_cannot_be_used_when_targeting_ECMAScript_6_or_higher_Consider_using_import_Asterisk_as_ns_from_mod_import_a_from_mod_or_import_d_from_mod_instead: { code: 1202, category: ts.DiagnosticCategory.Error, key: "Import assignment cannot be used when targeting ECMAScript 6 or higher. Consider using 'import * as ns from \"mod\"', 'import {a} from \"mod\"' or 'import d from \"mod\"' instead." }, - Export_assignment_cannot_be_used_when_targeting_ECMAScript_6_or_higher_Consider_using_export_default_instead: { code: 1203, category: ts.DiagnosticCategory.Error, key: "Export assignment cannot be used when targeting ECMAScript 6 or higher. Consider using 'export default' instead." }, - Cannot_compile_modules_into_commonjs_amd_system_or_umd_when_targeting_ES6_or_higher: { code: 1204, category: ts.DiagnosticCategory.Error, key: "Cannot compile modules into 'commonjs', 'amd', 'system' or 'umd' when targeting 'ES6' or higher." }, - Decorators_are_only_available_when_targeting_ECMAScript_5_and_higher: { code: 1205, category: ts.DiagnosticCategory.Error, key: "Decorators are only available when targeting ECMAScript 5 and higher." }, - Decorators_are_not_valid_here: { code: 1206, category: ts.DiagnosticCategory.Error, key: "Decorators are not valid here." }, - Decorators_cannot_be_applied_to_multiple_get_Slashset_accessors_of_the_same_name: { code: 1207, category: ts.DiagnosticCategory.Error, key: "Decorators cannot be applied to multiple get/set accessors of the same name." }, - Cannot_compile_namespaces_when_the_isolatedModules_flag_is_provided: { code: 1208, category: ts.DiagnosticCategory.Error, key: "Cannot compile namespaces when the '--isolatedModules' flag is provided." }, - Ambient_const_enums_are_not_allowed_when_the_isolatedModules_flag_is_provided: { code: 1209, category: ts.DiagnosticCategory.Error, key: "Ambient const enums are not allowed when the '--isolatedModules' flag is provided." }, - Invalid_use_of_0_Class_definitions_are_automatically_in_strict_mode: { code: 1210, category: ts.DiagnosticCategory.Error, key: "Invalid use of '{0}'. Class definitions are automatically in strict mode." }, - A_class_declaration_without_the_default_modifier_must_have_a_name: { code: 1211, category: ts.DiagnosticCategory.Error, key: "A class declaration without the 'default' modifier must have a name" }, - Identifier_expected_0_is_a_reserved_word_in_strict_mode: { code: 1212, category: ts.DiagnosticCategory.Error, key: "Identifier expected. '{0}' is a reserved word in strict mode" }, - Identifier_expected_0_is_a_reserved_word_in_strict_mode_Class_definitions_are_automatically_in_strict_mode: { code: 1213, category: ts.DiagnosticCategory.Error, key: "Identifier expected. '{0}' is a reserved word in strict mode. Class definitions are automatically in strict mode." }, - Type_expected_0_is_a_reserved_word_in_strict_mode: { code: 1215, category: ts.DiagnosticCategory.Error, key: "Type expected. '{0}' is a reserved word in strict mode" }, - Type_expected_0_is_a_reserved_word_in_strict_mode_Class_definitions_are_automatically_in_strict_mode: { code: 1216, category: ts.DiagnosticCategory.Error, key: "Type expected. '{0}' is a reserved word in strict mode. Class definitions are automatically in strict mode." }, - Export_assignment_is_not_supported_when_module_flag_is_system: { code: 1218, category: ts.DiagnosticCategory.Error, key: "Export assignment is not supported when '--module' flag is 'system'." }, - Experimental_support_for_decorators_is_a_feature_that_is_subject_to_change_in_a_future_release_Specify_experimentalDecorators_to_remove_this_warning: { code: 1219, category: ts.DiagnosticCategory.Error, key: "Experimental support for decorators is a feature that is subject to change in a future release. Specify '--experimentalDecorators' to remove this warning." }, - Generators_are_only_available_when_targeting_ECMAScript_6_or_higher: { code: 1220, category: ts.DiagnosticCategory.Error, key: "Generators are only available when targeting ECMAScript 6 or higher." }, - Generators_are_not_allowed_in_an_ambient_context: { code: 1221, category: ts.DiagnosticCategory.Error, key: "Generators are not allowed in an ambient context." }, - An_overload_signature_cannot_be_declared_as_a_generator: { code: 1222, category: ts.DiagnosticCategory.Error, key: "An overload signature cannot be declared as a generator." }, - _0_tag_already_specified: { code: 1223, category: ts.DiagnosticCategory.Error, key: "'{0}' tag already specified." }, - Signature_0_must_have_a_type_predicate: { code: 1224, category: ts.DiagnosticCategory.Error, key: "Signature '{0}' must have a type predicate." }, - Cannot_find_parameter_0: { code: 1225, category: ts.DiagnosticCategory.Error, key: "Cannot find parameter '{0}'." }, - Type_predicate_0_is_not_assignable_to_1: { code: 1226, category: ts.DiagnosticCategory.Error, key: "Type predicate '{0}' is not assignable to '{1}'." }, - Parameter_0_is_not_in_the_same_position_as_parameter_1: { code: 1227, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' is not in the same position as parameter '{1}'." }, - A_type_predicate_is_only_allowed_in_return_type_position_for_functions_and_methods: { code: 1228, category: ts.DiagnosticCategory.Error, key: "A type predicate is only allowed in return type position for functions and methods." }, - A_type_predicate_cannot_reference_a_rest_parameter: { code: 1229, category: ts.DiagnosticCategory.Error, key: "A type predicate cannot reference a rest parameter." }, - A_type_predicate_cannot_reference_element_0_in_a_binding_pattern: { code: 1230, category: ts.DiagnosticCategory.Error, key: "A type predicate cannot reference element '{0}' in a binding pattern." }, - An_export_assignment_can_only_be_used_in_a_module: { code: 1231, category: ts.DiagnosticCategory.Error, key: "An export assignment can only be used in a module." }, - An_import_declaration_can_only_be_used_in_a_namespace_or_module: { code: 1232, category: ts.DiagnosticCategory.Error, key: "An import declaration can only be used in a namespace or module." }, - An_export_declaration_can_only_be_used_in_a_module: { code: 1233, category: ts.DiagnosticCategory.Error, key: "An export declaration can only be used in a module." }, - An_ambient_module_declaration_is_only_allowed_at_the_top_level_in_a_file: { code: 1234, category: ts.DiagnosticCategory.Error, key: "An ambient module declaration is only allowed at the top level in a file." }, - A_namespace_declaration_is_only_allowed_in_a_namespace_or_module: { code: 1235, category: ts.DiagnosticCategory.Error, key: "A namespace declaration is only allowed in a namespace or module." }, - Duplicate_identifier_0: { code: 2300, category: ts.DiagnosticCategory.Error, key: "Duplicate identifier '{0}'." }, - Initializer_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor: { code: 2301, category: ts.DiagnosticCategory.Error, key: "Initializer of instance member variable '{0}' cannot reference identifier '{1}' declared in the constructor." }, - Static_members_cannot_reference_class_type_parameters: { code: 2302, category: ts.DiagnosticCategory.Error, key: "Static members cannot reference class type parameters." }, - Circular_definition_of_import_alias_0: { code: 2303, category: ts.DiagnosticCategory.Error, key: "Circular definition of import alias '{0}'." }, - Cannot_find_name_0: { code: 2304, category: ts.DiagnosticCategory.Error, key: "Cannot find name '{0}'." }, - Module_0_has_no_exported_member_1: { code: 2305, category: ts.DiagnosticCategory.Error, key: "Module '{0}' has no exported member '{1}'." }, - File_0_is_not_a_module: { code: 2306, category: ts.DiagnosticCategory.Error, key: "File '{0}' is not a module." }, - Cannot_find_module_0: { code: 2307, category: ts.DiagnosticCategory.Error, key: "Cannot find module '{0}'." }, - A_module_cannot_have_more_than_one_export_assignment: { code: 2308, category: ts.DiagnosticCategory.Error, key: "A module cannot have more than one export assignment." }, - An_export_assignment_cannot_be_used_in_a_module_with_other_exported_elements: { code: 2309, category: ts.DiagnosticCategory.Error, key: "An export assignment cannot be used in a module with other exported elements." }, - Type_0_recursively_references_itself_as_a_base_type: { code: 2310, category: ts.DiagnosticCategory.Error, key: "Type '{0}' recursively references itself as a base type." }, - A_class_may_only_extend_another_class: { code: 2311, category: ts.DiagnosticCategory.Error, key: "A class may only extend another class." }, - An_interface_may_only_extend_a_class_or_another_interface: { code: 2312, category: ts.DiagnosticCategory.Error, key: "An interface may only extend a class or another interface." }, - Constraint_of_a_type_parameter_cannot_reference_any_type_parameter_from_the_same_type_parameter_list: { code: 2313, category: ts.DiagnosticCategory.Error, key: "Constraint of a type parameter cannot reference any type parameter from the same type parameter list." }, - Generic_type_0_requires_1_type_argument_s: { code: 2314, category: ts.DiagnosticCategory.Error, key: "Generic type '{0}' requires {1} type argument(s)." }, - Type_0_is_not_generic: { code: 2315, category: ts.DiagnosticCategory.Error, key: "Type '{0}' is not generic." }, - Global_type_0_must_be_a_class_or_interface_type: { code: 2316, category: ts.DiagnosticCategory.Error, key: "Global type '{0}' must be a class or interface type." }, - Global_type_0_must_have_1_type_parameter_s: { code: 2317, category: ts.DiagnosticCategory.Error, key: "Global type '{0}' must have {1} type parameter(s)." }, - Cannot_find_global_type_0: { code: 2318, category: ts.DiagnosticCategory.Error, key: "Cannot find global type '{0}'." }, - Named_property_0_of_types_1_and_2_are_not_identical: { code: 2319, category: ts.DiagnosticCategory.Error, key: "Named property '{0}' of types '{1}' and '{2}' are not identical." }, - Interface_0_cannot_simultaneously_extend_types_1_and_2: { code: 2320, category: ts.DiagnosticCategory.Error, key: "Interface '{0}' cannot simultaneously extend types '{1}' and '{2}'." }, - Excessive_stack_depth_comparing_types_0_and_1: { code: 2321, category: ts.DiagnosticCategory.Error, key: "Excessive stack depth comparing types '{0}' and '{1}'." }, - Type_0_is_not_assignable_to_type_1: { code: 2322, category: ts.DiagnosticCategory.Error, key: "Type '{0}' is not assignable to type '{1}'." }, - Property_0_is_missing_in_type_1: { code: 2324, category: ts.DiagnosticCategory.Error, key: "Property '{0}' is missing in type '{1}'." }, - Property_0_is_private_in_type_1_but_not_in_type_2: { code: 2325, category: ts.DiagnosticCategory.Error, key: "Property '{0}' is private in type '{1}' but not in type '{2}'." }, - Types_of_property_0_are_incompatible: { code: 2326, category: ts.DiagnosticCategory.Error, key: "Types of property '{0}' are incompatible." }, - Property_0_is_optional_in_type_1_but_required_in_type_2: { code: 2327, category: ts.DiagnosticCategory.Error, key: "Property '{0}' is optional in type '{1}' but required in type '{2}'." }, - Types_of_parameters_0_and_1_are_incompatible: { code: 2328, category: ts.DiagnosticCategory.Error, key: "Types of parameters '{0}' and '{1}' are incompatible." }, - Index_signature_is_missing_in_type_0: { code: 2329, category: ts.DiagnosticCategory.Error, key: "Index signature is missing in type '{0}'." }, - Index_signatures_are_incompatible: { code: 2330, category: ts.DiagnosticCategory.Error, key: "Index signatures are incompatible." }, - this_cannot_be_referenced_in_a_module_or_namespace_body: { code: 2331, category: ts.DiagnosticCategory.Error, key: "'this' cannot be referenced in a module or namespace body." }, - this_cannot_be_referenced_in_current_location: { code: 2332, category: ts.DiagnosticCategory.Error, key: "'this' cannot be referenced in current location." }, - this_cannot_be_referenced_in_constructor_arguments: { code: 2333, category: ts.DiagnosticCategory.Error, key: "'this' cannot be referenced in constructor arguments." }, - this_cannot_be_referenced_in_a_static_property_initializer: { code: 2334, category: ts.DiagnosticCategory.Error, key: "'this' cannot be referenced in a static property initializer." }, - super_can_only_be_referenced_in_a_derived_class: { code: 2335, category: ts.DiagnosticCategory.Error, key: "'super' can only be referenced in a derived class." }, - super_cannot_be_referenced_in_constructor_arguments: { code: 2336, category: ts.DiagnosticCategory.Error, key: "'super' cannot be referenced in constructor arguments." }, - Super_calls_are_not_permitted_outside_constructors_or_in_nested_functions_inside_constructors: { code: 2337, category: ts.DiagnosticCategory.Error, key: "Super calls are not permitted outside constructors or in nested functions inside constructors" }, - super_property_access_is_permitted_only_in_a_constructor_member_function_or_member_accessor_of_a_derived_class: { code: 2338, category: ts.DiagnosticCategory.Error, key: "'super' property access is permitted only in a constructor, member function, or member accessor of a derived class" }, - Property_0_does_not_exist_on_type_1: { code: 2339, category: ts.DiagnosticCategory.Error, key: "Property '{0}' does not exist on type '{1}'." }, - Only_public_and_protected_methods_of_the_base_class_are_accessible_via_the_super_keyword: { code: 2340, category: ts.DiagnosticCategory.Error, key: "Only public and protected methods of the base class are accessible via the 'super' keyword" }, - Property_0_is_private_and_only_accessible_within_class_1: { code: 2341, category: ts.DiagnosticCategory.Error, key: "Property '{0}' is private and only accessible within class '{1}'." }, - An_index_expression_argument_must_be_of_type_string_number_symbol_or_any: { code: 2342, category: ts.DiagnosticCategory.Error, key: "An index expression argument must be of type 'string', 'number', 'symbol, or 'any'." }, - Type_0_does_not_satisfy_the_constraint_1: { code: 2344, category: ts.DiagnosticCategory.Error, key: "Type '{0}' does not satisfy the constraint '{1}'." }, - Argument_of_type_0_is_not_assignable_to_parameter_of_type_1: { code: 2345, category: ts.DiagnosticCategory.Error, key: "Argument of type '{0}' is not assignable to parameter of type '{1}'." }, - Supplied_parameters_do_not_match_any_signature_of_call_target: { code: 2346, category: ts.DiagnosticCategory.Error, key: "Supplied parameters do not match any signature of call target." }, - Untyped_function_calls_may_not_accept_type_arguments: { code: 2347, category: ts.DiagnosticCategory.Error, key: "Untyped function calls may not accept type arguments." }, - Value_of_type_0_is_not_callable_Did_you_mean_to_include_new: { code: 2348, category: ts.DiagnosticCategory.Error, key: "Value of type '{0}' is not callable. Did you mean to include 'new'?" }, - Cannot_invoke_an_expression_whose_type_lacks_a_call_signature: { code: 2349, category: ts.DiagnosticCategory.Error, key: "Cannot invoke an expression whose type lacks a call signature." }, - Only_a_void_function_can_be_called_with_the_new_keyword: { code: 2350, category: ts.DiagnosticCategory.Error, key: "Only a void function can be called with the 'new' keyword." }, - Cannot_use_new_with_an_expression_whose_type_lacks_a_call_or_construct_signature: { code: 2351, category: ts.DiagnosticCategory.Error, key: "Cannot use 'new' with an expression whose type lacks a call or construct signature." }, - Neither_type_0_nor_type_1_is_assignable_to_the_other: { code: 2352, category: ts.DiagnosticCategory.Error, key: "Neither type '{0}' nor type '{1}' is assignable to the other." }, - No_best_common_type_exists_among_return_expressions: { code: 2354, category: ts.DiagnosticCategory.Error, key: "No best common type exists among return expressions." }, - A_function_whose_declared_type_is_neither_void_nor_any_must_return_a_value_or_consist_of_a_single_throw_statement: { code: 2355, category: ts.DiagnosticCategory.Error, key: "A function whose declared type is neither 'void' nor 'any' must return a value or consist of a single 'throw' statement." }, - An_arithmetic_operand_must_be_of_type_any_number_or_an_enum_type: { code: 2356, category: ts.DiagnosticCategory.Error, key: "An arithmetic operand must be of type 'any', 'number' or an enum type." }, - The_operand_of_an_increment_or_decrement_operator_must_be_a_variable_property_or_indexer: { code: 2357, category: ts.DiagnosticCategory.Error, key: "The operand of an increment or decrement operator must be a variable, property or indexer." }, - The_left_hand_side_of_an_instanceof_expression_must_be_of_type_any_an_object_type_or_a_type_parameter: { code: 2358, category: ts.DiagnosticCategory.Error, key: "The left-hand side of an 'instanceof' expression must be of type 'any', an object type or a type parameter." }, - The_right_hand_side_of_an_instanceof_expression_must_be_of_type_any_or_of_a_type_assignable_to_the_Function_interface_type: { code: 2359, category: ts.DiagnosticCategory.Error, key: "The right-hand side of an 'instanceof' expression must be of type 'any' or of a type assignable to the 'Function' interface type." }, - The_left_hand_side_of_an_in_expression_must_be_of_type_any_string_number_or_symbol: { code: 2360, category: ts.DiagnosticCategory.Error, key: "The left-hand side of an 'in' expression must be of type 'any', 'string', 'number', or 'symbol'." }, - The_right_hand_side_of_an_in_expression_must_be_of_type_any_an_object_type_or_a_type_parameter: { code: 2361, category: ts.DiagnosticCategory.Error, key: "The right-hand side of an 'in' expression must be of type 'any', an object type or a type parameter" }, - The_left_hand_side_of_an_arithmetic_operation_must_be_of_type_any_number_or_an_enum_type: { code: 2362, category: ts.DiagnosticCategory.Error, key: "The left-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type." }, - The_right_hand_side_of_an_arithmetic_operation_must_be_of_type_any_number_or_an_enum_type: { code: 2363, category: ts.DiagnosticCategory.Error, key: "The right-hand side of an arithmetic operation must be of type 'any', 'number' or an enum type." }, - Invalid_left_hand_side_of_assignment_expression: { code: 2364, category: ts.DiagnosticCategory.Error, key: "Invalid left-hand side of assignment expression." }, - Operator_0_cannot_be_applied_to_types_1_and_2: { code: 2365, category: ts.DiagnosticCategory.Error, key: "Operator '{0}' cannot be applied to types '{1}' and '{2}'." }, - Type_parameter_name_cannot_be_0: { code: 2368, category: ts.DiagnosticCategory.Error, key: "Type parameter name cannot be '{0}'" }, - A_parameter_property_is_only_allowed_in_a_constructor_implementation: { code: 2369, category: ts.DiagnosticCategory.Error, key: "A parameter property is only allowed in a constructor implementation." }, - A_rest_parameter_must_be_of_an_array_type: { code: 2370, category: ts.DiagnosticCategory.Error, key: "A rest parameter must be of an array type." }, - A_parameter_initializer_is_only_allowed_in_a_function_or_constructor_implementation: { code: 2371, category: ts.DiagnosticCategory.Error, key: "A parameter initializer is only allowed in a function or constructor implementation." }, - Parameter_0_cannot_be_referenced_in_its_initializer: { code: 2372, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' cannot be referenced in its initializer." }, - Initializer_of_parameter_0_cannot_reference_identifier_1_declared_after_it: { code: 2373, category: ts.DiagnosticCategory.Error, key: "Initializer of parameter '{0}' cannot reference identifier '{1}' declared after it." }, - Duplicate_string_index_signature: { code: 2374, category: ts.DiagnosticCategory.Error, key: "Duplicate string index signature." }, - Duplicate_number_index_signature: { code: 2375, category: ts.DiagnosticCategory.Error, key: "Duplicate number index signature." }, - A_super_call_must_be_the_first_statement_in_the_constructor_when_a_class_contains_initialized_properties_or_has_parameter_properties: { code: 2376, category: ts.DiagnosticCategory.Error, key: "A 'super' call must be the first statement in the constructor when a class contains initialized properties or has parameter properties." }, - Constructors_for_derived_classes_must_contain_a_super_call: { code: 2377, category: ts.DiagnosticCategory.Error, key: "Constructors for derived classes must contain a 'super' call." }, - A_get_accessor_must_return_a_value_or_consist_of_a_single_throw_statement: { code: 2378, category: ts.DiagnosticCategory.Error, key: "A 'get' accessor must return a value or consist of a single 'throw' statement." }, - Getter_and_setter_accessors_do_not_agree_in_visibility: { code: 2379, category: ts.DiagnosticCategory.Error, key: "Getter and setter accessors do not agree in visibility." }, - get_and_set_accessor_must_have_the_same_type: { code: 2380, category: ts.DiagnosticCategory.Error, key: "'get' and 'set' accessor must have the same type." }, - A_signature_with_an_implementation_cannot_use_a_string_literal_type: { code: 2381, category: ts.DiagnosticCategory.Error, key: "A signature with an implementation cannot use a string literal type." }, - Specialized_overload_signature_is_not_assignable_to_any_non_specialized_signature: { code: 2382, category: ts.DiagnosticCategory.Error, key: "Specialized overload signature is not assignable to any non-specialized signature." }, - Overload_signatures_must_all_be_exported_or_not_exported: { code: 2383, category: ts.DiagnosticCategory.Error, key: "Overload signatures must all be exported or not exported." }, - Overload_signatures_must_all_be_ambient_or_non_ambient: { code: 2384, category: ts.DiagnosticCategory.Error, key: "Overload signatures must all be ambient or non-ambient." }, - Overload_signatures_must_all_be_public_private_or_protected: { code: 2385, category: ts.DiagnosticCategory.Error, key: "Overload signatures must all be public, private or protected." }, - Overload_signatures_must_all_be_optional_or_required: { code: 2386, category: ts.DiagnosticCategory.Error, key: "Overload signatures must all be optional or required." }, - Function_overload_must_be_static: { code: 2387, category: ts.DiagnosticCategory.Error, key: "Function overload must be static." }, - Function_overload_must_not_be_static: { code: 2388, category: ts.DiagnosticCategory.Error, key: "Function overload must not be static." }, - Function_implementation_name_must_be_0: { code: 2389, category: ts.DiagnosticCategory.Error, key: "Function implementation name must be '{0}'." }, - Constructor_implementation_is_missing: { code: 2390, category: ts.DiagnosticCategory.Error, key: "Constructor implementation is missing." }, - Function_implementation_is_missing_or_not_immediately_following_the_declaration: { code: 2391, category: ts.DiagnosticCategory.Error, key: "Function implementation is missing or not immediately following the declaration." }, - Multiple_constructor_implementations_are_not_allowed: { code: 2392, category: ts.DiagnosticCategory.Error, key: "Multiple constructor implementations are not allowed." }, - Duplicate_function_implementation: { code: 2393, category: ts.DiagnosticCategory.Error, key: "Duplicate function implementation." }, - Overload_signature_is_not_compatible_with_function_implementation: { code: 2394, category: ts.DiagnosticCategory.Error, key: "Overload signature is not compatible with function implementation." }, - Individual_declarations_in_merged_declaration_0_must_be_all_exported_or_all_local: { code: 2395, category: ts.DiagnosticCategory.Error, key: "Individual declarations in merged declaration {0} must be all exported or all local." }, - Duplicate_identifier_arguments_Compiler_uses_arguments_to_initialize_rest_parameters: { code: 2396, category: ts.DiagnosticCategory.Error, key: "Duplicate identifier 'arguments'. Compiler uses 'arguments' to initialize rest parameters." }, - Duplicate_identifier_this_Compiler_uses_variable_declaration_this_to_capture_this_reference: { code: 2399, category: ts.DiagnosticCategory.Error, key: "Duplicate identifier '_this'. Compiler uses variable declaration '_this' to capture 'this' reference." }, - Expression_resolves_to_variable_declaration_this_that_compiler_uses_to_capture_this_reference: { code: 2400, category: ts.DiagnosticCategory.Error, key: "Expression resolves to variable declaration '_this' that compiler uses to capture 'this' reference." }, - Duplicate_identifier_super_Compiler_uses_super_to_capture_base_class_reference: { code: 2401, category: ts.DiagnosticCategory.Error, key: "Duplicate identifier '_super'. Compiler uses '_super' to capture base class reference." }, - Expression_resolves_to_super_that_compiler_uses_to_capture_base_class_reference: { code: 2402, category: ts.DiagnosticCategory.Error, key: "Expression resolves to '_super' that compiler uses to capture base class reference." }, - Subsequent_variable_declarations_must_have_the_same_type_Variable_0_must_be_of_type_1_but_here_has_type_2: { code: 2403, category: ts.DiagnosticCategory.Error, key: "Subsequent variable declarations must have the same type. Variable '{0}' must be of type '{1}', but here has type '{2}'." }, - The_left_hand_side_of_a_for_in_statement_cannot_use_a_type_annotation: { code: 2404, category: ts.DiagnosticCategory.Error, key: "The left-hand side of a 'for...in' statement cannot use a type annotation." }, - The_left_hand_side_of_a_for_in_statement_must_be_of_type_string_or_any: { code: 2405, category: ts.DiagnosticCategory.Error, key: "The left-hand side of a 'for...in' statement must be of type 'string' or 'any'." }, - Invalid_left_hand_side_in_for_in_statement: { code: 2406, category: ts.DiagnosticCategory.Error, key: "Invalid left-hand side in 'for...in' statement." }, - The_right_hand_side_of_a_for_in_statement_must_be_of_type_any_an_object_type_or_a_type_parameter: { code: 2407, category: ts.DiagnosticCategory.Error, key: "The right-hand side of a 'for...in' statement must be of type 'any', an object type or a type parameter." }, - Setters_cannot_return_a_value: { code: 2408, category: ts.DiagnosticCategory.Error, key: "Setters cannot return a value." }, - Return_type_of_constructor_signature_must_be_assignable_to_the_instance_type_of_the_class: { code: 2409, category: ts.DiagnosticCategory.Error, key: "Return type of constructor signature must be assignable to the instance type of the class" }, - All_symbols_within_a_with_block_will_be_resolved_to_any: { code: 2410, category: ts.DiagnosticCategory.Error, key: "All symbols within a 'with' block will be resolved to 'any'." }, - Property_0_of_type_1_is_not_assignable_to_string_index_type_2: { code: 2411, category: ts.DiagnosticCategory.Error, key: "Property '{0}' of type '{1}' is not assignable to string index type '{2}'." }, - Property_0_of_type_1_is_not_assignable_to_numeric_index_type_2: { code: 2412, category: ts.DiagnosticCategory.Error, key: "Property '{0}' of type '{1}' is not assignable to numeric index type '{2}'." }, - Numeric_index_type_0_is_not_assignable_to_string_index_type_1: { code: 2413, category: ts.DiagnosticCategory.Error, key: "Numeric index type '{0}' is not assignable to string index type '{1}'." }, - Class_name_cannot_be_0: { code: 2414, category: ts.DiagnosticCategory.Error, key: "Class name cannot be '{0}'" }, - Class_0_incorrectly_extends_base_class_1: { code: 2415, category: ts.DiagnosticCategory.Error, key: "Class '{0}' incorrectly extends base class '{1}'." }, - Class_static_side_0_incorrectly_extends_base_class_static_side_1: { code: 2417, category: ts.DiagnosticCategory.Error, key: "Class static side '{0}' incorrectly extends base class static side '{1}'." }, - Type_name_0_in_extends_clause_does_not_reference_constructor_function_for_0: { code: 2419, category: ts.DiagnosticCategory.Error, key: "Type name '{0}' in extends clause does not reference constructor function for '{0}'." }, - Class_0_incorrectly_implements_interface_1: { code: 2420, category: ts.DiagnosticCategory.Error, key: "Class '{0}' incorrectly implements interface '{1}'." }, - A_class_may_only_implement_another_class_or_interface: { code: 2422, category: ts.DiagnosticCategory.Error, key: "A class may only implement another class or interface." }, - Class_0_defines_instance_member_function_1_but_extended_class_2_defines_it_as_instance_member_accessor: { code: 2423, category: ts.DiagnosticCategory.Error, key: "Class '{0}' defines instance member function '{1}', but extended class '{2}' defines it as instance member accessor." }, - Class_0_defines_instance_member_function_1_but_extended_class_2_defines_it_as_instance_member_property: { code: 2424, category: ts.DiagnosticCategory.Error, key: "Class '{0}' defines instance member function '{1}', but extended class '{2}' defines it as instance member property." }, - Class_0_defines_instance_member_property_1_but_extended_class_2_defines_it_as_instance_member_function: { code: 2425, category: ts.DiagnosticCategory.Error, key: "Class '{0}' defines instance member property '{1}', but extended class '{2}' defines it as instance member function." }, - Class_0_defines_instance_member_accessor_1_but_extended_class_2_defines_it_as_instance_member_function: { code: 2426, category: ts.DiagnosticCategory.Error, key: "Class '{0}' defines instance member accessor '{1}', but extended class '{2}' defines it as instance member function." }, - Interface_name_cannot_be_0: { code: 2427, category: ts.DiagnosticCategory.Error, key: "Interface name cannot be '{0}'" }, - All_declarations_of_an_interface_must_have_identical_type_parameters: { code: 2428, category: ts.DiagnosticCategory.Error, key: "All declarations of an interface must have identical type parameters." }, - Interface_0_incorrectly_extends_interface_1: { code: 2430, category: ts.DiagnosticCategory.Error, key: "Interface '{0}' incorrectly extends interface '{1}'." }, - Enum_name_cannot_be_0: { code: 2431, category: ts.DiagnosticCategory.Error, key: "Enum name cannot be '{0}'" }, - In_an_enum_with_multiple_declarations_only_one_declaration_can_omit_an_initializer_for_its_first_enum_element: { code: 2432, category: ts.DiagnosticCategory.Error, key: "In an enum with multiple declarations, only one declaration can omit an initializer for its first enum element." }, - A_namespace_declaration_cannot_be_in_a_different_file_from_a_class_or_function_with_which_it_is_merged: { code: 2433, category: ts.DiagnosticCategory.Error, key: "A namespace declaration cannot be in a different file from a class or function with which it is merged" }, - A_namespace_declaration_cannot_be_located_prior_to_a_class_or_function_with_which_it_is_merged: { code: 2434, category: ts.DiagnosticCategory.Error, key: "A namespace declaration cannot be located prior to a class or function with which it is merged" }, - Ambient_modules_cannot_be_nested_in_other_modules: { code: 2435, category: ts.DiagnosticCategory.Error, key: "Ambient modules cannot be nested in other modules." }, - Ambient_module_declaration_cannot_specify_relative_module_name: { code: 2436, category: ts.DiagnosticCategory.Error, key: "Ambient module declaration cannot specify relative module name." }, - Module_0_is_hidden_by_a_local_declaration_with_the_same_name: { code: 2437, category: ts.DiagnosticCategory.Error, key: "Module '{0}' is hidden by a local declaration with the same name" }, - Import_name_cannot_be_0: { code: 2438, category: ts.DiagnosticCategory.Error, key: "Import name cannot be '{0}'" }, - Import_or_export_declaration_in_an_ambient_module_declaration_cannot_reference_module_through_relative_module_name: { code: 2439, category: ts.DiagnosticCategory.Error, key: "Import or export declaration in an ambient module declaration cannot reference module through relative module name." }, - Import_declaration_conflicts_with_local_declaration_of_0: { code: 2440, category: ts.DiagnosticCategory.Error, key: "Import declaration conflicts with local declaration of '{0}'" }, - Duplicate_identifier_0_Compiler_reserves_name_1_in_top_level_scope_of_a_module: { code: 2441, category: ts.DiagnosticCategory.Error, key: "Duplicate identifier '{0}'. Compiler reserves name '{1}' in top level scope of a module." }, - Types_have_separate_declarations_of_a_private_property_0: { code: 2442, category: ts.DiagnosticCategory.Error, key: "Types have separate declarations of a private property '{0}'." }, - Property_0_is_protected_but_type_1_is_not_a_class_derived_from_2: { code: 2443, category: ts.DiagnosticCategory.Error, key: "Property '{0}' is protected but type '{1}' is not a class derived from '{2}'." }, - Property_0_is_protected_in_type_1_but_public_in_type_2: { code: 2444, category: ts.DiagnosticCategory.Error, key: "Property '{0}' is protected in type '{1}' but public in type '{2}'." }, - Property_0_is_protected_and_only_accessible_within_class_1_and_its_subclasses: { code: 2445, category: ts.DiagnosticCategory.Error, key: "Property '{0}' is protected and only accessible within class '{1}' and its subclasses." }, - Property_0_is_protected_and_only_accessible_through_an_instance_of_class_1: { code: 2446, category: ts.DiagnosticCategory.Error, key: "Property '{0}' is protected and only accessible through an instance of class '{1}'." }, - The_0_operator_is_not_allowed_for_boolean_types_Consider_using_1_instead: { code: 2447, category: ts.DiagnosticCategory.Error, key: "The '{0}' operator is not allowed for boolean types. Consider using '{1}' instead." }, - Block_scoped_variable_0_used_before_its_declaration: { code: 2448, category: ts.DiagnosticCategory.Error, key: "Block-scoped variable '{0}' used before its declaration." }, - The_operand_of_an_increment_or_decrement_operator_cannot_be_a_constant: { code: 2449, category: ts.DiagnosticCategory.Error, key: "The operand of an increment or decrement operator cannot be a constant." }, - Left_hand_side_of_assignment_expression_cannot_be_a_constant: { code: 2450, category: ts.DiagnosticCategory.Error, key: "Left-hand side of assignment expression cannot be a constant." }, - Cannot_redeclare_block_scoped_variable_0: { code: 2451, category: ts.DiagnosticCategory.Error, key: "Cannot redeclare block-scoped variable '{0}'." }, - An_enum_member_cannot_have_a_numeric_name: { code: 2452, category: ts.DiagnosticCategory.Error, key: "An enum member cannot have a numeric name." }, - The_type_argument_for_type_parameter_0_cannot_be_inferred_from_the_usage_Consider_specifying_the_type_arguments_explicitly: { code: 2453, category: ts.DiagnosticCategory.Error, key: "The type argument for type parameter '{0}' cannot be inferred from the usage. Consider specifying the type arguments explicitly." }, - Type_argument_candidate_1_is_not_a_valid_type_argument_because_it_is_not_a_supertype_of_candidate_0: { code: 2455, category: ts.DiagnosticCategory.Error, key: "Type argument candidate '{1}' is not a valid type argument because it is not a supertype of candidate '{0}'." }, - Type_alias_0_circularly_references_itself: { code: 2456, category: ts.DiagnosticCategory.Error, key: "Type alias '{0}' circularly references itself." }, - Type_alias_name_cannot_be_0: { code: 2457, category: ts.DiagnosticCategory.Error, key: "Type alias name cannot be '{0}'" }, - An_AMD_module_cannot_have_multiple_name_assignments: { code: 2458, category: ts.DiagnosticCategory.Error, key: "An AMD module cannot have multiple name assignments." }, - Type_0_has_no_property_1_and_no_string_index_signature: { code: 2459, category: ts.DiagnosticCategory.Error, key: "Type '{0}' has no property '{1}' and no string index signature." }, - Type_0_has_no_property_1: { code: 2460, category: ts.DiagnosticCategory.Error, key: "Type '{0}' has no property '{1}'." }, - Type_0_is_not_an_array_type: { code: 2461, category: ts.DiagnosticCategory.Error, key: "Type '{0}' is not an array type." }, - A_rest_element_must_be_last_in_an_array_destructuring_pattern: { code: 2462, category: ts.DiagnosticCategory.Error, key: "A rest element must be last in an array destructuring pattern" }, - A_binding_pattern_parameter_cannot_be_optional_in_an_implementation_signature: { code: 2463, category: ts.DiagnosticCategory.Error, key: "A binding pattern parameter cannot be optional in an implementation signature." }, - A_computed_property_name_must_be_of_type_string_number_symbol_or_any: { code: 2464, category: ts.DiagnosticCategory.Error, key: "A computed property name must be of type 'string', 'number', 'symbol', or 'any'." }, - this_cannot_be_referenced_in_a_computed_property_name: { code: 2465, category: ts.DiagnosticCategory.Error, key: "'this' cannot be referenced in a computed property name." }, - super_cannot_be_referenced_in_a_computed_property_name: { code: 2466, category: ts.DiagnosticCategory.Error, key: "'super' cannot be referenced in a computed property name." }, - A_computed_property_name_cannot_reference_a_type_parameter_from_its_containing_type: { code: 2467, category: ts.DiagnosticCategory.Error, key: "A computed property name cannot reference a type parameter from its containing type." }, - Cannot_find_global_value_0: { code: 2468, category: ts.DiagnosticCategory.Error, key: "Cannot find global value '{0}'." }, - The_0_operator_cannot_be_applied_to_type_symbol: { code: 2469, category: ts.DiagnosticCategory.Error, key: "The '{0}' operator cannot be applied to type 'symbol'." }, - Symbol_reference_does_not_refer_to_the_global_Symbol_constructor_object: { code: 2470, category: ts.DiagnosticCategory.Error, key: "'Symbol' reference does not refer to the global Symbol constructor object." }, - A_computed_property_name_of_the_form_0_must_be_of_type_symbol: { code: 2471, category: ts.DiagnosticCategory.Error, key: "A computed property name of the form '{0}' must be of type 'symbol'." }, - Spread_operator_in_new_expressions_is_only_available_when_targeting_ECMAScript_5_and_higher: { code: 2472, category: ts.DiagnosticCategory.Error, key: "Spread operator in 'new' expressions is only available when targeting ECMAScript 5 and higher." }, - Enum_declarations_must_all_be_const_or_non_const: { code: 2473, category: ts.DiagnosticCategory.Error, key: "Enum declarations must all be const or non-const." }, - In_const_enum_declarations_member_initializer_must_be_constant_expression: { code: 2474, category: ts.DiagnosticCategory.Error, key: "In 'const' enum declarations member initializer must be constant expression." }, - const_enums_can_only_be_used_in_property_or_index_access_expressions_or_the_right_hand_side_of_an_import_declaration_or_export_assignment: { code: 2475, category: ts.DiagnosticCategory.Error, key: "'const' enums can only be used in property or index access expressions or the right hand side of an import declaration or export assignment." }, - A_const_enum_member_can_only_be_accessed_using_a_string_literal: { code: 2476, category: ts.DiagnosticCategory.Error, key: "A const enum member can only be accessed using a string literal." }, - const_enum_member_initializer_was_evaluated_to_a_non_finite_value: { code: 2477, category: ts.DiagnosticCategory.Error, key: "'const' enum member initializer was evaluated to a non-finite value." }, - const_enum_member_initializer_was_evaluated_to_disallowed_value_NaN: { code: 2478, category: ts.DiagnosticCategory.Error, key: "'const' enum member initializer was evaluated to disallowed value 'NaN'." }, - Property_0_does_not_exist_on_const_enum_1: { code: 2479, category: ts.DiagnosticCategory.Error, key: "Property '{0}' does not exist on 'const' enum '{1}'." }, - let_is_not_allowed_to_be_used_as_a_name_in_let_or_const_declarations: { code: 2480, category: ts.DiagnosticCategory.Error, key: "'let' is not allowed to be used as a name in 'let' or 'const' declarations." }, - Cannot_initialize_outer_scoped_variable_0_in_the_same_scope_as_block_scoped_declaration_1: { code: 2481, category: ts.DiagnosticCategory.Error, key: "Cannot initialize outer scoped variable '{0}' in the same scope as block scoped declaration '{1}'." }, - The_left_hand_side_of_a_for_of_statement_cannot_use_a_type_annotation: { code: 2483, category: ts.DiagnosticCategory.Error, key: "The left-hand side of a 'for...of' statement cannot use a type annotation." }, - Export_declaration_conflicts_with_exported_declaration_of_0: { code: 2484, category: ts.DiagnosticCategory.Error, key: "Export declaration conflicts with exported declaration of '{0}'" }, - The_left_hand_side_of_a_for_of_statement_cannot_be_a_previously_defined_constant: { code: 2485, category: ts.DiagnosticCategory.Error, key: "The left-hand side of a 'for...of' statement cannot be a previously defined constant." }, - The_left_hand_side_of_a_for_in_statement_cannot_be_a_previously_defined_constant: { code: 2486, category: ts.DiagnosticCategory.Error, key: "The left-hand side of a 'for...in' statement cannot be a previously defined constant." }, - Invalid_left_hand_side_in_for_of_statement: { code: 2487, category: ts.DiagnosticCategory.Error, key: "Invalid left-hand side in 'for...of' statement." }, - Type_must_have_a_Symbol_iterator_method_that_returns_an_iterator: { code: 2488, category: ts.DiagnosticCategory.Error, key: "Type must have a '[Symbol.iterator]()' method that returns an iterator." }, - An_iterator_must_have_a_next_method: { code: 2489, category: ts.DiagnosticCategory.Error, key: "An iterator must have a 'next()' method." }, - The_type_returned_by_the_next_method_of_an_iterator_must_have_a_value_property: { code: 2490, category: ts.DiagnosticCategory.Error, key: "The type returned by the 'next()' method of an iterator must have a 'value' property." }, - The_left_hand_side_of_a_for_in_statement_cannot_be_a_destructuring_pattern: { code: 2491, category: ts.DiagnosticCategory.Error, key: "The left-hand side of a 'for...in' statement cannot be a destructuring pattern." }, - Cannot_redeclare_identifier_0_in_catch_clause: { code: 2492, category: ts.DiagnosticCategory.Error, key: "Cannot redeclare identifier '{0}' in catch clause" }, - Tuple_type_0_with_length_1_cannot_be_assigned_to_tuple_with_length_2: { code: 2493, category: ts.DiagnosticCategory.Error, key: "Tuple type '{0}' with length '{1}' cannot be assigned to tuple with length '{2}'." }, - Using_a_string_in_a_for_of_statement_is_only_supported_in_ECMAScript_5_and_higher: { code: 2494, category: ts.DiagnosticCategory.Error, key: "Using a string in a 'for...of' statement is only supported in ECMAScript 5 and higher." }, - Type_0_is_not_an_array_type_or_a_string_type: { code: 2495, category: ts.DiagnosticCategory.Error, key: "Type '{0}' is not an array type or a string type." }, - The_arguments_object_cannot_be_referenced_in_an_arrow_function_in_ES3_and_ES5_Consider_using_a_standard_function_expression: { code: 2496, category: ts.DiagnosticCategory.Error, key: "The 'arguments' object cannot be referenced in an arrow function in ES3 and ES5. Consider using a standard function expression." }, - Module_0_resolves_to_a_non_module_entity_and_cannot_be_imported_using_this_construct: { code: 2497, category: ts.DiagnosticCategory.Error, key: "Module '{0}' resolves to a non-module entity and cannot be imported using this construct." }, - Module_0_uses_export_and_cannot_be_used_with_export_Asterisk: { code: 2498, category: ts.DiagnosticCategory.Error, key: "Module '{0}' uses 'export =' and cannot be used with 'export *'." }, - An_interface_can_only_extend_an_identifier_Slashqualified_name_with_optional_type_arguments: { code: 2499, category: ts.DiagnosticCategory.Error, key: "An interface can only extend an identifier/qualified-name with optional type arguments." }, - A_class_can_only_implement_an_identifier_Slashqualified_name_with_optional_type_arguments: { code: 2500, category: ts.DiagnosticCategory.Error, key: "A class can only implement an identifier/qualified-name with optional type arguments." }, - A_rest_element_cannot_contain_a_binding_pattern: { code: 2501, category: ts.DiagnosticCategory.Error, key: "A rest element cannot contain a binding pattern." }, - _0_is_referenced_directly_or_indirectly_in_its_own_type_annotation: { code: 2502, category: ts.DiagnosticCategory.Error, key: "'{0}' is referenced directly or indirectly in its own type annotation." }, - Cannot_find_namespace_0: { code: 2503, category: ts.DiagnosticCategory.Error, key: "Cannot find namespace '{0}'." }, - No_best_common_type_exists_among_yield_expressions: { code: 2504, category: ts.DiagnosticCategory.Error, key: "No best common type exists among yield expressions." }, - A_generator_cannot_have_a_void_type_annotation: { code: 2505, category: ts.DiagnosticCategory.Error, key: "A generator cannot have a 'void' type annotation." }, - Import_declaration_0_is_using_private_name_1: { code: 4000, category: ts.DiagnosticCategory.Error, key: "Import declaration '{0}' is using private name '{1}'." }, - Type_parameter_0_of_exported_class_has_or_is_using_private_name_1: { code: 4002, category: ts.DiagnosticCategory.Error, key: "Type parameter '{0}' of exported class has or is using private name '{1}'." }, - Type_parameter_0_of_exported_interface_has_or_is_using_private_name_1: { code: 4004, category: ts.DiagnosticCategory.Error, key: "Type parameter '{0}' of exported interface has or is using private name '{1}'." }, - Type_parameter_0_of_constructor_signature_from_exported_interface_has_or_is_using_private_name_1: { code: 4006, category: ts.DiagnosticCategory.Error, key: "Type parameter '{0}' of constructor signature from exported interface has or is using private name '{1}'." }, - Type_parameter_0_of_call_signature_from_exported_interface_has_or_is_using_private_name_1: { code: 4008, category: ts.DiagnosticCategory.Error, key: "Type parameter '{0}' of call signature from exported interface has or is using private name '{1}'." }, - Type_parameter_0_of_public_static_method_from_exported_class_has_or_is_using_private_name_1: { code: 4010, category: ts.DiagnosticCategory.Error, key: "Type parameter '{0}' of public static method from exported class has or is using private name '{1}'." }, - Type_parameter_0_of_public_method_from_exported_class_has_or_is_using_private_name_1: { code: 4012, category: ts.DiagnosticCategory.Error, key: "Type parameter '{0}' of public method from exported class has or is using private name '{1}'." }, - Type_parameter_0_of_method_from_exported_interface_has_or_is_using_private_name_1: { code: 4014, category: ts.DiagnosticCategory.Error, key: "Type parameter '{0}' of method from exported interface has or is using private name '{1}'." }, - Type_parameter_0_of_exported_function_has_or_is_using_private_name_1: { code: 4016, category: ts.DiagnosticCategory.Error, key: "Type parameter '{0}' of exported function has or is using private name '{1}'." }, - Implements_clause_of_exported_class_0_has_or_is_using_private_name_1: { code: 4019, category: ts.DiagnosticCategory.Error, key: "Implements clause of exported class '{0}' has or is using private name '{1}'." }, - Extends_clause_of_exported_class_0_has_or_is_using_private_name_1: { code: 4020, category: ts.DiagnosticCategory.Error, key: "Extends clause of exported class '{0}' has or is using private name '{1}'." }, - Extends_clause_of_exported_interface_0_has_or_is_using_private_name_1: { code: 4022, category: ts.DiagnosticCategory.Error, key: "Extends clause of exported interface '{0}' has or is using private name '{1}'." }, - Exported_variable_0_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named: { code: 4023, category: ts.DiagnosticCategory.Error, key: "Exported variable '{0}' has or is using name '{1}' from external module {2} but cannot be named." }, - Exported_variable_0_has_or_is_using_name_1_from_private_module_2: { code: 4024, category: ts.DiagnosticCategory.Error, key: "Exported variable '{0}' has or is using name '{1}' from private module '{2}'." }, - Exported_variable_0_has_or_is_using_private_name_1: { code: 4025, category: ts.DiagnosticCategory.Error, key: "Exported variable '{0}' has or is using private name '{1}'." }, - Public_static_property_0_of_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named: { code: 4026, category: ts.DiagnosticCategory.Error, key: "Public static property '{0}' of exported class has or is using name '{1}' from external module {2} but cannot be named." }, - Public_static_property_0_of_exported_class_has_or_is_using_name_1_from_private_module_2: { code: 4027, category: ts.DiagnosticCategory.Error, key: "Public static property '{0}' of exported class has or is using name '{1}' from private module '{2}'." }, - Public_static_property_0_of_exported_class_has_or_is_using_private_name_1: { code: 4028, category: ts.DiagnosticCategory.Error, key: "Public static property '{0}' of exported class has or is using private name '{1}'." }, - Public_property_0_of_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named: { code: 4029, category: ts.DiagnosticCategory.Error, key: "Public property '{0}' of exported class has or is using name '{1}' from external module {2} but cannot be named." }, - Public_property_0_of_exported_class_has_or_is_using_name_1_from_private_module_2: { code: 4030, category: ts.DiagnosticCategory.Error, key: "Public property '{0}' of exported class has or is using name '{1}' from private module '{2}'." }, - Public_property_0_of_exported_class_has_or_is_using_private_name_1: { code: 4031, category: ts.DiagnosticCategory.Error, key: "Public property '{0}' of exported class has or is using private name '{1}'." }, - Property_0_of_exported_interface_has_or_is_using_name_1_from_private_module_2: { code: 4032, category: ts.DiagnosticCategory.Error, key: "Property '{0}' of exported interface has or is using name '{1}' from private module '{2}'." }, - Property_0_of_exported_interface_has_or_is_using_private_name_1: { code: 4033, category: ts.DiagnosticCategory.Error, key: "Property '{0}' of exported interface has or is using private name '{1}'." }, - Parameter_0_of_public_static_property_setter_from_exported_class_has_or_is_using_name_1_from_private_module_2: { code: 4034, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of public static property setter from exported class has or is using name '{1}' from private module '{2}'." }, - Parameter_0_of_public_static_property_setter_from_exported_class_has_or_is_using_private_name_1: { code: 4035, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of public static property setter from exported class has or is using private name '{1}'." }, - Parameter_0_of_public_property_setter_from_exported_class_has_or_is_using_name_1_from_private_module_2: { code: 4036, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of public property setter from exported class has or is using name '{1}' from private module '{2}'." }, - Parameter_0_of_public_property_setter_from_exported_class_has_or_is_using_private_name_1: { code: 4037, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of public property setter from exported class has or is using private name '{1}'." }, - Return_type_of_public_static_property_getter_from_exported_class_has_or_is_using_name_0_from_external_module_1_but_cannot_be_named: { code: 4038, category: ts.DiagnosticCategory.Error, key: "Return type of public static property getter from exported class has or is using name '{0}' from external module {1} but cannot be named." }, - Return_type_of_public_static_property_getter_from_exported_class_has_or_is_using_name_0_from_private_module_1: { code: 4039, category: ts.DiagnosticCategory.Error, key: "Return type of public static property getter from exported class has or is using name '{0}' from private module '{1}'." }, - Return_type_of_public_static_property_getter_from_exported_class_has_or_is_using_private_name_0: { code: 4040, category: ts.DiagnosticCategory.Error, key: "Return type of public static property getter from exported class has or is using private name '{0}'." }, - Return_type_of_public_property_getter_from_exported_class_has_or_is_using_name_0_from_external_module_1_but_cannot_be_named: { code: 4041, category: ts.DiagnosticCategory.Error, key: "Return type of public property getter from exported class has or is using name '{0}' from external module {1} but cannot be named." }, - Return_type_of_public_property_getter_from_exported_class_has_or_is_using_name_0_from_private_module_1: { code: 4042, category: ts.DiagnosticCategory.Error, key: "Return type of public property getter from exported class has or is using name '{0}' from private module '{1}'." }, - Return_type_of_public_property_getter_from_exported_class_has_or_is_using_private_name_0: { code: 4043, category: ts.DiagnosticCategory.Error, key: "Return type of public property getter from exported class has or is using private name '{0}'." }, - Return_type_of_constructor_signature_from_exported_interface_has_or_is_using_name_0_from_private_module_1: { code: 4044, category: ts.DiagnosticCategory.Error, key: "Return type of constructor signature from exported interface has or is using name '{0}' from private module '{1}'." }, - Return_type_of_constructor_signature_from_exported_interface_has_or_is_using_private_name_0: { code: 4045, category: ts.DiagnosticCategory.Error, key: "Return type of constructor signature from exported interface has or is using private name '{0}'." }, - Return_type_of_call_signature_from_exported_interface_has_or_is_using_name_0_from_private_module_1: { code: 4046, category: ts.DiagnosticCategory.Error, key: "Return type of call signature from exported interface has or is using name '{0}' from private module '{1}'." }, - Return_type_of_call_signature_from_exported_interface_has_or_is_using_private_name_0: { code: 4047, category: ts.DiagnosticCategory.Error, key: "Return type of call signature from exported interface has or is using private name '{0}'." }, - Return_type_of_index_signature_from_exported_interface_has_or_is_using_name_0_from_private_module_1: { code: 4048, category: ts.DiagnosticCategory.Error, key: "Return type of index signature from exported interface has or is using name '{0}' from private module '{1}'." }, - Return_type_of_index_signature_from_exported_interface_has_or_is_using_private_name_0: { code: 4049, category: ts.DiagnosticCategory.Error, key: "Return type of index signature from exported interface has or is using private name '{0}'." }, - Return_type_of_public_static_method_from_exported_class_has_or_is_using_name_0_from_external_module_1_but_cannot_be_named: { code: 4050, category: ts.DiagnosticCategory.Error, key: "Return type of public static method from exported class has or is using name '{0}' from external module {1} but cannot be named." }, - Return_type_of_public_static_method_from_exported_class_has_or_is_using_name_0_from_private_module_1: { code: 4051, category: ts.DiagnosticCategory.Error, key: "Return type of public static method from exported class has or is using name '{0}' from private module '{1}'." }, - Return_type_of_public_static_method_from_exported_class_has_or_is_using_private_name_0: { code: 4052, category: ts.DiagnosticCategory.Error, key: "Return type of public static method from exported class has or is using private name '{0}'." }, - Return_type_of_public_method_from_exported_class_has_or_is_using_name_0_from_external_module_1_but_cannot_be_named: { code: 4053, category: ts.DiagnosticCategory.Error, key: "Return type of public method from exported class has or is using name '{0}' from external module {1} but cannot be named." }, - Return_type_of_public_method_from_exported_class_has_or_is_using_name_0_from_private_module_1: { code: 4054, category: ts.DiagnosticCategory.Error, key: "Return type of public method from exported class has or is using name '{0}' from private module '{1}'." }, - Return_type_of_public_method_from_exported_class_has_or_is_using_private_name_0: { code: 4055, category: ts.DiagnosticCategory.Error, key: "Return type of public method from exported class has or is using private name '{0}'." }, - Return_type_of_method_from_exported_interface_has_or_is_using_name_0_from_private_module_1: { code: 4056, category: ts.DiagnosticCategory.Error, key: "Return type of method from exported interface has or is using name '{0}' from private module '{1}'." }, - Return_type_of_method_from_exported_interface_has_or_is_using_private_name_0: { code: 4057, category: ts.DiagnosticCategory.Error, key: "Return type of method from exported interface has or is using private name '{0}'." }, - Return_type_of_exported_function_has_or_is_using_name_0_from_external_module_1_but_cannot_be_named: { code: 4058, category: ts.DiagnosticCategory.Error, key: "Return type of exported function has or is using name '{0}' from external module {1} but cannot be named." }, - Return_type_of_exported_function_has_or_is_using_name_0_from_private_module_1: { code: 4059, category: ts.DiagnosticCategory.Error, key: "Return type of exported function has or is using name '{0}' from private module '{1}'." }, - Return_type_of_exported_function_has_or_is_using_private_name_0: { code: 4060, category: ts.DiagnosticCategory.Error, key: "Return type of exported function has or is using private name '{0}'." }, - Parameter_0_of_constructor_from_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named: { code: 4061, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of constructor from exported class has or is using name '{1}' from external module {2} but cannot be named." }, - Parameter_0_of_constructor_from_exported_class_has_or_is_using_name_1_from_private_module_2: { code: 4062, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of constructor from exported class has or is using name '{1}' from private module '{2}'." }, - Parameter_0_of_constructor_from_exported_class_has_or_is_using_private_name_1: { code: 4063, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of constructor from exported class has or is using private name '{1}'." }, - Parameter_0_of_constructor_signature_from_exported_interface_has_or_is_using_name_1_from_private_module_2: { code: 4064, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of constructor signature from exported interface has or is using name '{1}' from private module '{2}'." }, - Parameter_0_of_constructor_signature_from_exported_interface_has_or_is_using_private_name_1: { code: 4065, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of constructor signature from exported interface has or is using private name '{1}'." }, - Parameter_0_of_call_signature_from_exported_interface_has_or_is_using_name_1_from_private_module_2: { code: 4066, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of call signature from exported interface has or is using name '{1}' from private module '{2}'." }, - Parameter_0_of_call_signature_from_exported_interface_has_or_is_using_private_name_1: { code: 4067, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of call signature from exported interface has or is using private name '{1}'." }, - Parameter_0_of_public_static_method_from_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named: { code: 4068, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of public static method from exported class has or is using name '{1}' from external module {2} but cannot be named." }, - Parameter_0_of_public_static_method_from_exported_class_has_or_is_using_name_1_from_private_module_2: { code: 4069, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of public static method from exported class has or is using name '{1}' from private module '{2}'." }, - Parameter_0_of_public_static_method_from_exported_class_has_or_is_using_private_name_1: { code: 4070, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of public static method from exported class has or is using private name '{1}'." }, - Parameter_0_of_public_method_from_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named: { code: 4071, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of public method from exported class has or is using name '{1}' from external module {2} but cannot be named." }, - Parameter_0_of_public_method_from_exported_class_has_or_is_using_name_1_from_private_module_2: { code: 4072, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of public method from exported class has or is using name '{1}' from private module '{2}'." }, - Parameter_0_of_public_method_from_exported_class_has_or_is_using_private_name_1: { code: 4073, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of public method from exported class has or is using private name '{1}'." }, - Parameter_0_of_method_from_exported_interface_has_or_is_using_name_1_from_private_module_2: { code: 4074, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of method from exported interface has or is using name '{1}' from private module '{2}'." }, - Parameter_0_of_method_from_exported_interface_has_or_is_using_private_name_1: { code: 4075, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of method from exported interface has or is using private name '{1}'." }, - Parameter_0_of_exported_function_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named: { code: 4076, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of exported function has or is using name '{1}' from external module {2} but cannot be named." }, - Parameter_0_of_exported_function_has_or_is_using_name_1_from_private_module_2: { code: 4077, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of exported function has or is using name '{1}' from private module '{2}'." }, - Parameter_0_of_exported_function_has_or_is_using_private_name_1: { code: 4078, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' of exported function has or is using private name '{1}'." }, - Exported_type_alias_0_has_or_is_using_private_name_1: { code: 4081, category: ts.DiagnosticCategory.Error, key: "Exported type alias '{0}' has or is using private name '{1}'." }, - Default_export_of_the_module_has_or_is_using_private_name_0: { code: 4082, category: ts.DiagnosticCategory.Error, key: "Default export of the module has or is using private name '{0}'." }, - Loop_contains_block_scoped_variable_0_referenced_by_a_function_in_the_loop_This_is_only_supported_in_ECMAScript_6_or_higher: { code: 4091, category: ts.DiagnosticCategory.Error, key: "Loop contains block-scoped variable '{0}' referenced by a function in the loop. This is only supported in ECMAScript 6 or higher." }, - The_current_host_does_not_support_the_0_option: { code: 5001, category: ts.DiagnosticCategory.Error, key: "The current host does not support the '{0}' option." }, - Cannot_find_the_common_subdirectory_path_for_the_input_files: { code: 5009, category: ts.DiagnosticCategory.Error, key: "Cannot find the common subdirectory path for the input files." }, - Cannot_read_file_0_Colon_1: { code: 5012, category: ts.DiagnosticCategory.Error, key: "Cannot read file '{0}': {1}" }, - Unsupported_file_encoding: { code: 5013, category: ts.DiagnosticCategory.Error, key: "Unsupported file encoding." }, - Failed_to_parse_file_0_Colon_1: { code: 5014, category: ts.DiagnosticCategory.Error, key: "Failed to parse file '{0}': {1}." }, - Unknown_compiler_option_0: { code: 5023, category: ts.DiagnosticCategory.Error, key: "Unknown compiler option '{0}'." }, - Compiler_option_0_requires_a_value_of_type_1: { code: 5024, category: ts.DiagnosticCategory.Error, key: "Compiler option '{0}' requires a value of type {1}." }, - Could_not_write_file_0_Colon_1: { code: 5033, category: ts.DiagnosticCategory.Error, key: "Could not write file '{0}': {1}" }, - Option_mapRoot_cannot_be_specified_without_specifying_sourceMap_option: { code: 5038, category: ts.DiagnosticCategory.Error, key: "Option 'mapRoot' cannot be specified without specifying 'sourceMap' option." }, - Option_sourceRoot_cannot_be_specified_without_specifying_sourceMap_option: { code: 5039, category: ts.DiagnosticCategory.Error, key: "Option 'sourceRoot' cannot be specified without specifying 'sourceMap' option." }, - Option_noEmit_cannot_be_specified_with_option_out_or_outDir: { code: 5040, category: ts.DiagnosticCategory.Error, key: "Option 'noEmit' cannot be specified with option 'out' or 'outDir'." }, - Option_noEmit_cannot_be_specified_with_option_declaration: { code: 5041, category: ts.DiagnosticCategory.Error, key: "Option 'noEmit' cannot be specified with option 'declaration'." }, - Option_project_cannot_be_mixed_with_source_files_on_a_command_line: { code: 5042, category: ts.DiagnosticCategory.Error, key: "Option 'project' cannot be mixed with source files on a command line." }, - Option_sourceMap_cannot_be_specified_with_option_isolatedModules: { code: 5043, category: ts.DiagnosticCategory.Error, key: "Option 'sourceMap' cannot be specified with option 'isolatedModules'." }, - Option_declaration_cannot_be_specified_with_option_isolatedModules: { code: 5044, category: ts.DiagnosticCategory.Error, key: "Option 'declaration' cannot be specified with option 'isolatedModules'." }, - Option_noEmitOnError_cannot_be_specified_with_option_isolatedModules: { code: 5045, category: ts.DiagnosticCategory.Error, key: "Option 'noEmitOnError' cannot be specified with option 'isolatedModules'." }, - Option_out_cannot_be_specified_with_option_isolatedModules: { code: 5046, category: ts.DiagnosticCategory.Error, key: "Option 'out' cannot be specified with option 'isolatedModules'." }, - Option_isolatedModules_can_only_be_used_when_either_option_module_is_provided_or_option_target_is_ES6_or_higher: { code: 5047, category: ts.DiagnosticCategory.Error, key: "Option 'isolatedModules' can only be used when either option'--module' is provided or option 'target' is 'ES6' or higher." }, - Option_sourceMap_cannot_be_specified_with_option_inlineSourceMap: { code: 5048, category: ts.DiagnosticCategory.Error, key: "Option 'sourceMap' cannot be specified with option 'inlineSourceMap'." }, - Option_sourceRoot_cannot_be_specified_with_option_inlineSourceMap: { code: 5049, category: ts.DiagnosticCategory.Error, key: "Option 'sourceRoot' cannot be specified with option 'inlineSourceMap'." }, - Option_mapRoot_cannot_be_specified_with_option_inlineSourceMap: { code: 5050, category: ts.DiagnosticCategory.Error, key: "Option 'mapRoot' cannot be specified with option 'inlineSourceMap'." }, - Option_inlineSources_can_only_be_used_when_either_option_inlineSourceMap_or_option_sourceMap_is_provided: { code: 5051, category: ts.DiagnosticCategory.Error, key: "Option 'inlineSources' can only be used when either option '--inlineSourceMap' or option '--sourceMap' is provided." }, - Concatenate_and_emit_output_to_single_file: { code: 6001, category: ts.DiagnosticCategory.Message, key: "Concatenate and emit output to single file." }, - Generates_corresponding_d_ts_file: { code: 6002, category: ts.DiagnosticCategory.Message, key: "Generates corresponding '.d.ts' file." }, - Specifies_the_location_where_debugger_should_locate_map_files_instead_of_generated_locations: { code: 6003, category: ts.DiagnosticCategory.Message, key: "Specifies the location where debugger should locate map files instead of generated locations." }, - Specifies_the_location_where_debugger_should_locate_TypeScript_files_instead_of_source_locations: { code: 6004, category: ts.DiagnosticCategory.Message, key: "Specifies the location where debugger should locate TypeScript files instead of source locations." }, - Watch_input_files: { code: 6005, category: ts.DiagnosticCategory.Message, key: "Watch input files." }, - Redirect_output_structure_to_the_directory: { code: 6006, category: ts.DiagnosticCategory.Message, key: "Redirect output structure to the directory." }, - Do_not_erase_const_enum_declarations_in_generated_code: { code: 6007, category: ts.DiagnosticCategory.Message, key: "Do not erase const enum declarations in generated code." }, - Do_not_emit_outputs_if_any_errors_were_reported: { code: 6008, category: ts.DiagnosticCategory.Message, key: "Do not emit outputs if any errors were reported." }, - Do_not_emit_comments_to_output: { code: 6009, category: ts.DiagnosticCategory.Message, key: "Do not emit comments to output." }, - Do_not_emit_outputs: { code: 6010, category: ts.DiagnosticCategory.Message, key: "Do not emit outputs." }, - Specify_ECMAScript_target_version_Colon_ES3_default_ES5_or_ES6_experimental: { code: 6015, category: ts.DiagnosticCategory.Message, key: "Specify ECMAScript target version: 'ES3' (default), 'ES5', or 'ES6' (experimental)" }, - Specify_module_code_generation_Colon_commonjs_amd_system_or_umd: { code: 6016, category: ts.DiagnosticCategory.Message, key: "Specify module code generation: 'commonjs', 'amd', 'system' or 'umd'" }, - Print_this_message: { code: 6017, category: ts.DiagnosticCategory.Message, key: "Print this message." }, - Print_the_compiler_s_version: { code: 6019, category: ts.DiagnosticCategory.Message, key: "Print the compiler's version." }, - Compile_the_project_in_the_given_directory: { code: 6020, category: ts.DiagnosticCategory.Message, key: "Compile the project in the given directory." }, - Syntax_Colon_0: { code: 6023, category: ts.DiagnosticCategory.Message, key: "Syntax: {0}" }, - options: { code: 6024, category: ts.DiagnosticCategory.Message, key: "options" }, - file: { code: 6025, category: ts.DiagnosticCategory.Message, key: "file" }, - Examples_Colon_0: { code: 6026, category: ts.DiagnosticCategory.Message, key: "Examples: {0}" }, - Options_Colon: { code: 6027, category: ts.DiagnosticCategory.Message, key: "Options:" }, - Version_0: { code: 6029, category: ts.DiagnosticCategory.Message, key: "Version {0}" }, - Insert_command_line_options_and_files_from_a_file: { code: 6030, category: ts.DiagnosticCategory.Message, key: "Insert command line options and files from a file." }, - File_change_detected_Starting_incremental_compilation: { code: 6032, category: ts.DiagnosticCategory.Message, key: "File change detected. Starting incremental compilation..." }, - KIND: { code: 6034, category: ts.DiagnosticCategory.Message, key: "KIND" }, - FILE: { code: 6035, category: ts.DiagnosticCategory.Message, key: "FILE" }, - VERSION: { code: 6036, category: ts.DiagnosticCategory.Message, key: "VERSION" }, - LOCATION: { code: 6037, category: ts.DiagnosticCategory.Message, key: "LOCATION" }, - DIRECTORY: { code: 6038, category: ts.DiagnosticCategory.Message, key: "DIRECTORY" }, - Compilation_complete_Watching_for_file_changes: { code: 6042, category: ts.DiagnosticCategory.Message, key: "Compilation complete. Watching for file changes." }, - Generates_corresponding_map_file: { code: 6043, category: ts.DiagnosticCategory.Message, key: "Generates corresponding '.map' file." }, - Compiler_option_0_expects_an_argument: { code: 6044, category: ts.DiagnosticCategory.Error, key: "Compiler option '{0}' expects an argument." }, - Unterminated_quoted_string_in_response_file_0: { code: 6045, category: ts.DiagnosticCategory.Error, key: "Unterminated quoted string in response file '{0}'." }, - Argument_for_module_option_must_be_commonjs_amd_system_or_umd: { code: 6046, category: ts.DiagnosticCategory.Error, key: "Argument for '--module' option must be 'commonjs', 'amd', 'system' or 'umd'." }, - Argument_for_target_option_must_be_ES3_ES5_or_ES6: { code: 6047, category: ts.DiagnosticCategory.Error, key: "Argument for '--target' option must be 'ES3', 'ES5', or 'ES6'." }, - Locale_must_be_of_the_form_language_or_language_territory_For_example_0_or_1: { code: 6048, category: ts.DiagnosticCategory.Error, key: "Locale must be of the form or -. For example '{0}' or '{1}'." }, - Unsupported_locale_0: { code: 6049, category: ts.DiagnosticCategory.Error, key: "Unsupported locale '{0}'." }, - Unable_to_open_file_0: { code: 6050, category: ts.DiagnosticCategory.Error, key: "Unable to open file '{0}'." }, - Corrupted_locale_file_0: { code: 6051, category: ts.DiagnosticCategory.Error, key: "Corrupted locale file {0}." }, - Raise_error_on_expressions_and_declarations_with_an_implied_any_type: { code: 6052, category: ts.DiagnosticCategory.Message, key: "Raise error on expressions and declarations with an implied 'any' type." }, - File_0_not_found: { code: 6053, category: ts.DiagnosticCategory.Error, key: "File '{0}' not found." }, - File_0_has_unsupported_extension_The_only_supported_extensions_are_1: { code: 6054, category: ts.DiagnosticCategory.Error, key: "File '{0}' has unsupported extension. The only supported extensions are {1}." }, - Suppress_noImplicitAny_errors_for_indexing_objects_lacking_index_signatures: { code: 6055, category: ts.DiagnosticCategory.Message, key: "Suppress noImplicitAny errors for indexing objects lacking index signatures." }, - Do_not_emit_declarations_for_code_that_has_an_internal_annotation: { code: 6056, category: ts.DiagnosticCategory.Message, key: "Do not emit declarations for code that has an '@internal' annotation." }, - Preserve_new_lines_when_emitting_code: { code: 6057, category: ts.DiagnosticCategory.Message, key: "Preserve new-lines when emitting code." }, - Specifies_the_root_directory_of_input_files_Use_to_control_the_output_directory_structure_with_outDir: { code: 6058, category: ts.DiagnosticCategory.Message, key: "Specifies the root directory of input files. Use to control the output directory structure with --outDir." }, - File_0_is_not_under_rootDir_1_rootDir_is_expected_to_contain_all_source_files: { code: 6059, category: ts.DiagnosticCategory.Error, key: "File '{0}' is not under 'rootDir' '{1}'. 'rootDir' is expected to contain all source files." }, - Specifies_the_end_of_line_sequence_to_be_used_when_emitting_files_Colon_CRLF_dos_or_LF_unix: { code: 6060, category: ts.DiagnosticCategory.Message, key: "Specifies the end of line sequence to be used when emitting files: 'CRLF' (dos) or 'LF' (unix)." }, - NEWLINE: { code: 6061, category: ts.DiagnosticCategory.Message, key: "NEWLINE" }, - Argument_for_newLine_option_must_be_CRLF_or_LF: { code: 6062, category: ts.DiagnosticCategory.Error, key: "Argument for '--newLine' option must be 'CRLF' or 'LF'." }, - Option_experimentalDecorators_must_also_be_specified_when_option_emitDecoratorMetadata_is_specified: { code: 6064, category: ts.DiagnosticCategory.Error, key: "Option 'experimentalDecorators' must also be specified when option 'emitDecoratorMetadata' is specified." }, - Enables_experimental_support_for_ES7_decorators: { code: 6065, category: ts.DiagnosticCategory.Message, key: "Enables experimental support for ES7 decorators." }, - Enables_experimental_support_for_emitting_type_metadata_for_decorators: { code: 6066, category: ts.DiagnosticCategory.Message, key: "Enables experimental support for emitting type metadata for decorators." }, - Variable_0_implicitly_has_an_1_type: { code: 7005, category: ts.DiagnosticCategory.Error, key: "Variable '{0}' implicitly has an '{1}' type." }, - Parameter_0_implicitly_has_an_1_type: { code: 7006, category: ts.DiagnosticCategory.Error, key: "Parameter '{0}' implicitly has an '{1}' type." }, - Member_0_implicitly_has_an_1_type: { code: 7008, category: ts.DiagnosticCategory.Error, key: "Member '{0}' implicitly has an '{1}' type." }, - new_expression_whose_target_lacks_a_construct_signature_implicitly_has_an_any_type: { code: 7009, category: ts.DiagnosticCategory.Error, key: "'new' expression, whose target lacks a construct signature, implicitly has an 'any' type." }, - _0_which_lacks_return_type_annotation_implicitly_has_an_1_return_type: { code: 7010, category: ts.DiagnosticCategory.Error, key: "'{0}', which lacks return-type annotation, implicitly has an '{1}' return type." }, - Function_expression_which_lacks_return_type_annotation_implicitly_has_an_0_return_type: { code: 7011, category: ts.DiagnosticCategory.Error, key: "Function expression, which lacks return-type annotation, implicitly has an '{0}' return type." }, - Construct_signature_which_lacks_return_type_annotation_implicitly_has_an_any_return_type: { code: 7013, category: ts.DiagnosticCategory.Error, key: "Construct signature, which lacks return-type annotation, implicitly has an 'any' return type." }, - Property_0_implicitly_has_type_any_because_its_set_accessor_lacks_a_type_annotation: { code: 7016, category: ts.DiagnosticCategory.Error, key: "Property '{0}' implicitly has type 'any', because its 'set' accessor lacks a type annotation." }, - Index_signature_of_object_type_implicitly_has_an_any_type: { code: 7017, category: ts.DiagnosticCategory.Error, key: "Index signature of object type implicitly has an 'any' type." }, - Object_literal_s_property_0_implicitly_has_an_1_type: { code: 7018, category: ts.DiagnosticCategory.Error, key: "Object literal's property '{0}' implicitly has an '{1}' type." }, - Rest_parameter_0_implicitly_has_an_any_type: { code: 7019, category: ts.DiagnosticCategory.Error, key: "Rest parameter '{0}' implicitly has an 'any[]' type." }, - Call_signature_which_lacks_return_type_annotation_implicitly_has_an_any_return_type: { code: 7020, category: ts.DiagnosticCategory.Error, key: "Call signature, which lacks return-type annotation, implicitly has an 'any' return type." }, - _0_implicitly_has_type_any_because_it_does_not_have_a_type_annotation_and_is_referenced_directly_or_indirectly_in_its_own_initializer: { code: 7022, category: ts.DiagnosticCategory.Error, key: "'{0}' implicitly has type 'any' because it does not have a type annotation and is referenced directly or indirectly in its own initializer." }, - _0_implicitly_has_return_type_any_because_it_does_not_have_a_return_type_annotation_and_is_referenced_directly_or_indirectly_in_one_of_its_return_expressions: { code: 7023, category: ts.DiagnosticCategory.Error, key: "'{0}' implicitly has return type 'any' because it does not have a return type annotation and is referenced directly or indirectly in one of its return expressions." }, - Function_implicitly_has_return_type_any_because_it_does_not_have_a_return_type_annotation_and_is_referenced_directly_or_indirectly_in_one_of_its_return_expressions: { code: 7024, category: ts.DiagnosticCategory.Error, key: "Function implicitly has return type 'any' because it does not have a return type annotation and is referenced directly or indirectly in one of its return expressions." }, - Generator_implicitly_has_type_0_because_it_does_not_yield_any_values_Consider_supplying_a_return_type: { code: 7025, category: ts.DiagnosticCategory.Error, key: "Generator implicitly has type '{0}' because it does not yield any values. Consider supplying a return type." }, - You_cannot_rename_this_element: { code: 8000, category: ts.DiagnosticCategory.Error, key: "You cannot rename this element." }, - You_cannot_rename_elements_that_are_defined_in_the_standard_TypeScript_library: { code: 8001, category: ts.DiagnosticCategory.Error, key: "You cannot rename elements that are defined in the standard TypeScript library." }, - import_can_only_be_used_in_a_ts_file: { code: 8002, category: ts.DiagnosticCategory.Error, key: "'import ... =' can only be used in a .ts file." }, - export_can_only_be_used_in_a_ts_file: { code: 8003, category: ts.DiagnosticCategory.Error, key: "'export=' can only be used in a .ts file." }, - type_parameter_declarations_can_only_be_used_in_a_ts_file: { code: 8004, category: ts.DiagnosticCategory.Error, key: "'type parameter declarations' can only be used in a .ts file." }, - implements_clauses_can_only_be_used_in_a_ts_file: { code: 8005, category: ts.DiagnosticCategory.Error, key: "'implements clauses' can only be used in a .ts file." }, - interface_declarations_can_only_be_used_in_a_ts_file: { code: 8006, category: ts.DiagnosticCategory.Error, key: "'interface declarations' can only be used in a .ts file." }, - module_declarations_can_only_be_used_in_a_ts_file: { code: 8007, category: ts.DiagnosticCategory.Error, key: "'module declarations' can only be used in a .ts file." }, - type_aliases_can_only_be_used_in_a_ts_file: { code: 8008, category: ts.DiagnosticCategory.Error, key: "'type aliases' can only be used in a .ts file." }, - _0_can_only_be_used_in_a_ts_file: { code: 8009, category: ts.DiagnosticCategory.Error, key: "'{0}' can only be used in a .ts file." }, - types_can_only_be_used_in_a_ts_file: { code: 8010, category: ts.DiagnosticCategory.Error, key: "'types' can only be used in a .ts file." }, - type_arguments_can_only_be_used_in_a_ts_file: { code: 8011, category: ts.DiagnosticCategory.Error, key: "'type arguments' can only be used in a .ts file." }, - parameter_modifiers_can_only_be_used_in_a_ts_file: { code: 8012, category: ts.DiagnosticCategory.Error, key: "'parameter modifiers' can only be used in a .ts file." }, - property_declarations_can_only_be_used_in_a_ts_file: { code: 8014, category: ts.DiagnosticCategory.Error, key: "'property declarations' can only be used in a .ts file." }, - enum_declarations_can_only_be_used_in_a_ts_file: { code: 8015, category: ts.DiagnosticCategory.Error, key: "'enum declarations' can only be used in a .ts file." }, - type_assertion_expressions_can_only_be_used_in_a_ts_file: { code: 8016, category: ts.DiagnosticCategory.Error, key: "'type assertion expressions' can only be used in a .ts file." }, - decorators_can_only_be_used_in_a_ts_file: { code: 8017, category: ts.DiagnosticCategory.Error, key: "'decorators' can only be used in a .ts file." }, - Only_identifiers_Slashqualified_names_with_optional_type_arguments_are_currently_supported_in_a_class_extends_clauses: { code: 9002, category: ts.DiagnosticCategory.Error, key: "Only identifiers/qualified-names with optional type arguments are currently supported in a class 'extends' clauses." }, - class_expressions_are_not_currently_supported: { code: 9003, category: ts.DiagnosticCategory.Error, key: "'class' expressions are not currently supported." } - }; -})(ts || (ts = {})); -/// -/// -var ts; -(function (ts) { - var textToToken = { - "any": 112 /* AnyKeyword */, - "as": 111 /* AsKeyword */, - "boolean": 113 /* BooleanKeyword */, - "break": 66 /* BreakKeyword */, - "case": 67 /* CaseKeyword */, - "catch": 68 /* CatchKeyword */, - "class": 69 /* ClassKeyword */, - "continue": 71 /* ContinueKeyword */, - "const": 70 /* ConstKeyword */, - "constructor": 114 /* ConstructorKeyword */, - "debugger": 72 /* DebuggerKeyword */, - "declare": 115 /* DeclareKeyword */, - "default": 73 /* DefaultKeyword */, - "delete": 74 /* DeleteKeyword */, - "do": 75 /* DoKeyword */, - "else": 76 /* ElseKeyword */, - "enum": 77 /* EnumKeyword */, - "export": 78 /* ExportKeyword */, - "extends": 79 /* ExtendsKeyword */, - "false": 80 /* FalseKeyword */, - "finally": 81 /* FinallyKeyword */, - "for": 82 /* ForKeyword */, - "from": 126 /* FromKeyword */, - "function": 83 /* FunctionKeyword */, - "get": 116 /* GetKeyword */, - "if": 84 /* IfKeyword */, - "implements": 102 /* ImplementsKeyword */, - "import": 85 /* ImportKeyword */, - "in": 86 /* InKeyword */, - "instanceof": 87 /* InstanceOfKeyword */, - "interface": 103 /* InterfaceKeyword */, - "is": 117 /* IsKeyword */, - "let": 104 /* LetKeyword */, - "module": 118 /* ModuleKeyword */, - "namespace": 119 /* NamespaceKeyword */, - "new": 88 /* NewKeyword */, - "null": 89 /* NullKeyword */, - "number": 121 /* NumberKeyword */, - "package": 105 /* PackageKeyword */, - "private": 106 /* PrivateKeyword */, - "protected": 107 /* ProtectedKeyword */, - "public": 108 /* PublicKeyword */, - "require": 120 /* RequireKeyword */, - "return": 90 /* ReturnKeyword */, - "set": 122 /* SetKeyword */, - "static": 109 /* StaticKeyword */, - "string": 123 /* StringKeyword */, - "super": 91 /* SuperKeyword */, - "switch": 92 /* SwitchKeyword */, - "symbol": 124 /* SymbolKeyword */, - "this": 93 /* ThisKeyword */, - "throw": 94 /* ThrowKeyword */, - "true": 95 /* TrueKeyword */, - "try": 96 /* TryKeyword */, - "type": 125 /* TypeKeyword */, - "typeof": 97 /* TypeOfKeyword */, - "var": 98 /* VarKeyword */, - "void": 99 /* VoidKeyword */, - "while": 100 /* WhileKeyword */, - "with": 101 /* WithKeyword */, - "yield": 110 /* YieldKeyword */, - "of": 127 /* OfKeyword */, - "{": 14 /* OpenBraceToken */, - "}": 15 /* CloseBraceToken */, - "(": 16 /* OpenParenToken */, - ")": 17 /* CloseParenToken */, - "[": 18 /* OpenBracketToken */, - "]": 19 /* CloseBracketToken */, - ".": 20 /* DotToken */, - "...": 21 /* DotDotDotToken */, - ";": 22 /* SemicolonToken */, - ",": 23 /* CommaToken */, - "<": 24 /* LessThanToken */, - ">": 25 /* GreaterThanToken */, - "<=": 26 /* LessThanEqualsToken */, - ">=": 27 /* GreaterThanEqualsToken */, - "==": 28 /* EqualsEqualsToken */, - "!=": 29 /* ExclamationEqualsToken */, - "===": 30 /* EqualsEqualsEqualsToken */, - "!==": 31 /* ExclamationEqualsEqualsToken */, - "=>": 32 /* EqualsGreaterThanToken */, - "+": 33 /* PlusToken */, - "-": 34 /* MinusToken */, - "*": 35 /* AsteriskToken */, - "/": 36 /* SlashToken */, - "%": 37 /* PercentToken */, - "++": 38 /* PlusPlusToken */, - "--": 39 /* MinusMinusToken */, - "<<": 40 /* LessThanLessThanToken */, - ">>": 41 /* GreaterThanGreaterThanToken */, - ">>>": 42 /* GreaterThanGreaterThanGreaterThanToken */, - "&": 43 /* AmpersandToken */, - "|": 44 /* BarToken */, - "^": 45 /* CaretToken */, - "!": 46 /* ExclamationToken */, - "~": 47 /* TildeToken */, - "&&": 48 /* AmpersandAmpersandToken */, - "||": 49 /* BarBarToken */, - "?": 50 /* QuestionToken */, - ":": 51 /* ColonToken */, - "=": 53 /* EqualsToken */, - "+=": 54 /* PlusEqualsToken */, - "-=": 55 /* MinusEqualsToken */, - "*=": 56 /* AsteriskEqualsToken */, - "/=": 57 /* SlashEqualsToken */, - "%=": 58 /* PercentEqualsToken */, - "<<=": 59 /* LessThanLessThanEqualsToken */, - ">>=": 60 /* GreaterThanGreaterThanEqualsToken */, - ">>>=": 61 /* GreaterThanGreaterThanGreaterThanEqualsToken */, - "&=": 62 /* AmpersandEqualsToken */, - "|=": 63 /* BarEqualsToken */, - "^=": 64 /* CaretEqualsToken */, - "@": 52 /* AtToken */ - }; - /* - As per ECMAScript Language Specification 3th Edition, Section 7.6: Identifiers - IdentifierStart :: - Can contain Unicode 3.0.0 categories: - Uppercase letter (Lu), - Lowercase letter (Ll), - Titlecase letter (Lt), - Modifier letter (Lm), - Other letter (Lo), or - Letter number (Nl). - IdentifierPart :: = - Can contain IdentifierStart + Unicode 3.0.0 categories: - Non-spacing mark (Mn), - Combining spacing mark (Mc), - Decimal number (Nd), or - Connector punctuation (Pc). - - Codepoint ranges for ES3 Identifiers are extracted from the Unicode 3.0.0 specification at: - http://www.unicode.org/Public/3.0-Update/UnicodeData-3.0.0.txt - */ - var unicodeES3IdentifierStart = [170, 170, 181, 181, 186, 186, 192, 214, 216, 246, 248, 543, 546, 563, 592, 685, 688, 696, 699, 705, 720, 721, 736, 740, 750, 750, 890, 890, 902, 902, 904, 906, 908, 908, 910, 929, 931, 974, 976, 983, 986, 1011, 1024, 1153, 1164, 1220, 1223, 1224, 1227, 1228, 1232, 1269, 1272, 1273, 1329, 1366, 1369, 1369, 1377, 1415, 1488, 1514, 1520, 1522, 1569, 1594, 1600, 1610, 1649, 1747, 1749, 1749, 1765, 1766, 1786, 1788, 1808, 1808, 1810, 1836, 1920, 1957, 2309, 2361, 2365, 2365, 2384, 2384, 2392, 2401, 2437, 2444, 2447, 2448, 2451, 2472, 2474, 2480, 2482, 2482, 2486, 2489, 2524, 2525, 2527, 2529, 2544, 2545, 2565, 2570, 2575, 2576, 2579, 2600, 2602, 2608, 2610, 2611, 2613, 2614, 2616, 2617, 2649, 2652, 2654, 2654, 2674, 2676, 2693, 2699, 2701, 2701, 2703, 2705, 2707, 2728, 2730, 2736, 2738, 2739, 2741, 2745, 2749, 2749, 2768, 2768, 2784, 2784, 2821, 2828, 2831, 2832, 2835, 2856, 2858, 2864, 2866, 2867, 2870, 2873, 2877, 2877, 2908, 2909, 2911, 2913, 2949, 2954, 2958, 2960, 2962, 2965, 2969, 2970, 2972, 2972, 2974, 2975, 2979, 2980, 2984, 2986, 2990, 2997, 2999, 3001, 3077, 3084, 3086, 3088, 3090, 3112, 3114, 3123, 3125, 3129, 3168, 3169, 3205, 3212, 3214, 3216, 3218, 3240, 3242, 3251, 3253, 3257, 3294, 3294, 3296, 3297, 3333, 3340, 3342, 3344, 3346, 3368, 3370, 3385, 3424, 3425, 3461, 3478, 3482, 3505, 3507, 3515, 3517, 3517, 3520, 3526, 3585, 3632, 3634, 3635, 3648, 3654, 3713, 3714, 3716, 3716, 3719, 3720, 3722, 3722, 3725, 3725, 3732, 3735, 3737, 3743, 3745, 3747, 3749, 3749, 3751, 3751, 3754, 3755, 3757, 3760, 3762, 3763, 3773, 3773, 3776, 3780, 3782, 3782, 3804, 3805, 3840, 3840, 3904, 3911, 3913, 3946, 3976, 3979, 4096, 4129, 4131, 4135, 4137, 4138, 4176, 4181, 4256, 4293, 4304, 4342, 4352, 4441, 4447, 4514, 4520, 4601, 4608, 4614, 4616, 4678, 4680, 4680, 4682, 4685, 4688, 4694, 4696, 4696, 4698, 4701, 4704, 4742, 4744, 4744, 4746, 4749, 4752, 4782, 4784, 4784, 4786, 4789, 4792, 4798, 4800, 4800, 4802, 4805, 4808, 4814, 4816, 4822, 4824, 4846, 4848, 4878, 4880, 4880, 4882, 4885, 4888, 4894, 4896, 4934, 4936, 4954, 5024, 5108, 5121, 5740, 5743, 5750, 5761, 5786, 5792, 5866, 6016, 6067, 6176, 6263, 6272, 6312, 7680, 7835, 7840, 7929, 7936, 7957, 7960, 7965, 7968, 8005, 8008, 8013, 8016, 8023, 8025, 8025, 8027, 8027, 8029, 8029, 8031, 8061, 8064, 8116, 8118, 8124, 8126, 8126, 8130, 8132, 8134, 8140, 8144, 8147, 8150, 8155, 8160, 8172, 8178, 8180, 8182, 8188, 8319, 8319, 8450, 8450, 8455, 8455, 8458, 8467, 8469, 8469, 8473, 8477, 8484, 8484, 8486, 8486, 8488, 8488, 8490, 8493, 8495, 8497, 8499, 8505, 8544, 8579, 12293, 12295, 12321, 12329, 12337, 12341, 12344, 12346, 12353, 12436, 12445, 12446, 12449, 12538, 12540, 12542, 12549, 12588, 12593, 12686, 12704, 12727, 13312, 19893, 19968, 40869, 40960, 42124, 44032, 55203, 63744, 64045, 64256, 64262, 64275, 64279, 64285, 64285, 64287, 64296, 64298, 64310, 64312, 64316, 64318, 64318, 64320, 64321, 64323, 64324, 64326, 64433, 64467, 64829, 64848, 64911, 64914, 64967, 65008, 65019, 65136, 65138, 65140, 65140, 65142, 65276, 65313, 65338, 65345, 65370, 65382, 65470, 65474, 65479, 65482, 65487, 65490, 65495, 65498, 65500,]; - var unicodeES3IdentifierPart = [170, 170, 181, 181, 186, 186, 192, 214, 216, 246, 248, 543, 546, 563, 592, 685, 688, 696, 699, 705, 720, 721, 736, 740, 750, 750, 768, 846, 864, 866, 890, 890, 902, 902, 904, 906, 908, 908, 910, 929, 931, 974, 976, 983, 986, 1011, 1024, 1153, 1155, 1158, 1164, 1220, 1223, 1224, 1227, 1228, 1232, 1269, 1272, 1273, 1329, 1366, 1369, 1369, 1377, 1415, 1425, 1441, 1443, 1465, 1467, 1469, 1471, 1471, 1473, 1474, 1476, 1476, 1488, 1514, 1520, 1522, 1569, 1594, 1600, 1621, 1632, 1641, 1648, 1747, 1749, 1756, 1759, 1768, 1770, 1773, 1776, 1788, 1808, 1836, 1840, 1866, 1920, 1968, 2305, 2307, 2309, 2361, 2364, 2381, 2384, 2388, 2392, 2403, 2406, 2415, 2433, 2435, 2437, 2444, 2447, 2448, 2451, 2472, 2474, 2480, 2482, 2482, 2486, 2489, 2492, 2492, 2494, 2500, 2503, 2504, 2507, 2509, 2519, 2519, 2524, 2525, 2527, 2531, 2534, 2545, 2562, 2562, 2565, 2570, 2575, 2576, 2579, 2600, 2602, 2608, 2610, 2611, 2613, 2614, 2616, 2617, 2620, 2620, 2622, 2626, 2631, 2632, 2635, 2637, 2649, 2652, 2654, 2654, 2662, 2676, 2689, 2691, 2693, 2699, 2701, 2701, 2703, 2705, 2707, 2728, 2730, 2736, 2738, 2739, 2741, 2745, 2748, 2757, 2759, 2761, 2763, 2765, 2768, 2768, 2784, 2784, 2790, 2799, 2817, 2819, 2821, 2828, 2831, 2832, 2835, 2856, 2858, 2864, 2866, 2867, 2870, 2873, 2876, 2883, 2887, 2888, 2891, 2893, 2902, 2903, 2908, 2909, 2911, 2913, 2918, 2927, 2946, 2947, 2949, 2954, 2958, 2960, 2962, 2965, 2969, 2970, 2972, 2972, 2974, 2975, 2979, 2980, 2984, 2986, 2990, 2997, 2999, 3001, 3006, 3010, 3014, 3016, 3018, 3021, 3031, 3031, 3047, 3055, 3073, 3075, 3077, 3084, 3086, 3088, 3090, 3112, 3114, 3123, 3125, 3129, 3134, 3140, 3142, 3144, 3146, 3149, 3157, 3158, 3168, 3169, 3174, 3183, 3202, 3203, 3205, 3212, 3214, 3216, 3218, 3240, 3242, 3251, 3253, 3257, 3262, 3268, 3270, 3272, 3274, 3277, 3285, 3286, 3294, 3294, 3296, 3297, 3302, 3311, 3330, 3331, 3333, 3340, 3342, 3344, 3346, 3368, 3370, 3385, 3390, 3395, 3398, 3400, 3402, 3405, 3415, 3415, 3424, 3425, 3430, 3439, 3458, 3459, 3461, 3478, 3482, 3505, 3507, 3515, 3517, 3517, 3520, 3526, 3530, 3530, 3535, 3540, 3542, 3542, 3544, 3551, 3570, 3571, 3585, 3642, 3648, 3662, 3664, 3673, 3713, 3714, 3716, 3716, 3719, 3720, 3722, 3722, 3725, 3725, 3732, 3735, 3737, 3743, 3745, 3747, 3749, 3749, 3751, 3751, 3754, 3755, 3757, 3769, 3771, 3773, 3776, 3780, 3782, 3782, 3784, 3789, 3792, 3801, 3804, 3805, 3840, 3840, 3864, 3865, 3872, 3881, 3893, 3893, 3895, 3895, 3897, 3897, 3902, 3911, 3913, 3946, 3953, 3972, 3974, 3979, 3984, 3991, 3993, 4028, 4038, 4038, 4096, 4129, 4131, 4135, 4137, 4138, 4140, 4146, 4150, 4153, 4160, 4169, 4176, 4185, 4256, 4293, 4304, 4342, 4352, 4441, 4447, 4514, 4520, 4601, 4608, 4614, 4616, 4678, 4680, 4680, 4682, 4685, 4688, 4694, 4696, 4696, 4698, 4701, 4704, 4742, 4744, 4744, 4746, 4749, 4752, 4782, 4784, 4784, 4786, 4789, 4792, 4798, 4800, 4800, 4802, 4805, 4808, 4814, 4816, 4822, 4824, 4846, 4848, 4878, 4880, 4880, 4882, 4885, 4888, 4894, 4896, 4934, 4936, 4954, 4969, 4977, 5024, 5108, 5121, 5740, 5743, 5750, 5761, 5786, 5792, 5866, 6016, 6099, 6112, 6121, 6160, 6169, 6176, 6263, 6272, 6313, 7680, 7835, 7840, 7929, 7936, 7957, 7960, 7965, 7968, 8005, 8008, 8013, 8016, 8023, 8025, 8025, 8027, 8027, 8029, 8029, 8031, 8061, 8064, 8116, 8118, 8124, 8126, 8126, 8130, 8132, 8134, 8140, 8144, 8147, 8150, 8155, 8160, 8172, 8178, 8180, 8182, 8188, 8255, 8256, 8319, 8319, 8400, 8412, 8417, 8417, 8450, 8450, 8455, 8455, 8458, 8467, 8469, 8469, 8473, 8477, 8484, 8484, 8486, 8486, 8488, 8488, 8490, 8493, 8495, 8497, 8499, 8505, 8544, 8579, 12293, 12295, 12321, 12335, 12337, 12341, 12344, 12346, 12353, 12436, 12441, 12442, 12445, 12446, 12449, 12542, 12549, 12588, 12593, 12686, 12704, 12727, 13312, 19893, 19968, 40869, 40960, 42124, 44032, 55203, 63744, 64045, 64256, 64262, 64275, 64279, 64285, 64296, 64298, 64310, 64312, 64316, 64318, 64318, 64320, 64321, 64323, 64324, 64326, 64433, 64467, 64829, 64848, 64911, 64914, 64967, 65008, 65019, 65056, 65059, 65075, 65076, 65101, 65103, 65136, 65138, 65140, 65140, 65142, 65276, 65296, 65305, 65313, 65338, 65343, 65343, 65345, 65370, 65381, 65470, 65474, 65479, 65482, 65487, 65490, 65495, 65498, 65500,]; - /* - As per ECMAScript Language Specification 5th Edition, Section 7.6: ISyntaxToken Names and Identifiers - IdentifierStart :: - Can contain Unicode 6.2 categories: - Uppercase letter (Lu), - Lowercase letter (Ll), - Titlecase letter (Lt), - Modifier letter (Lm), - Other letter (Lo), or - Letter number (Nl). - IdentifierPart :: - Can contain IdentifierStart + Unicode 6.2 categories: - Non-spacing mark (Mn), - Combining spacing mark (Mc), - Decimal number (Nd), - Connector punctuation (Pc), - , or - . - - Codepoint ranges for ES5 Identifiers are extracted from the Unicode 6.2 specification at: - http://www.unicode.org/Public/6.2.0/ucd/UnicodeData.txt - */ - var unicodeES5IdentifierStart = [170, 170, 181, 181, 186, 186, 192, 214, 216, 246, 248, 705, 710, 721, 736, 740, 748, 748, 750, 750, 880, 884, 886, 887, 890, 893, 902, 902, 904, 906, 908, 908, 910, 929, 931, 1013, 1015, 1153, 1162, 1319, 1329, 1366, 1369, 1369, 1377, 1415, 1488, 1514, 1520, 1522, 1568, 1610, 1646, 1647, 1649, 1747, 1749, 1749, 1765, 1766, 1774, 1775, 1786, 1788, 1791, 1791, 1808, 1808, 1810, 1839, 1869, 1957, 1969, 1969, 1994, 2026, 2036, 2037, 2042, 2042, 2048, 2069, 2074, 2074, 2084, 2084, 2088, 2088, 2112, 2136, 2208, 2208, 2210, 2220, 2308, 2361, 2365, 2365, 2384, 2384, 2392, 2401, 2417, 2423, 2425, 2431, 2437, 2444, 2447, 2448, 2451, 2472, 2474, 2480, 2482, 2482, 2486, 2489, 2493, 2493, 2510, 2510, 2524, 2525, 2527, 2529, 2544, 2545, 2565, 2570, 2575, 2576, 2579, 2600, 2602, 2608, 2610, 2611, 2613, 2614, 2616, 2617, 2649, 2652, 2654, 2654, 2674, 2676, 2693, 2701, 2703, 2705, 2707, 2728, 2730, 2736, 2738, 2739, 2741, 2745, 2749, 2749, 2768, 2768, 2784, 2785, 2821, 2828, 2831, 2832, 2835, 2856, 2858, 2864, 2866, 2867, 2869, 2873, 2877, 2877, 2908, 2909, 2911, 2913, 2929, 2929, 2947, 2947, 2949, 2954, 2958, 2960, 2962, 2965, 2969, 2970, 2972, 2972, 2974, 2975, 2979, 2980, 2984, 2986, 2990, 3001, 3024, 3024, 3077, 3084, 3086, 3088, 3090, 3112, 3114, 3123, 3125, 3129, 3133, 3133, 3160, 3161, 3168, 3169, 3205, 3212, 3214, 3216, 3218, 3240, 3242, 3251, 3253, 3257, 3261, 3261, 3294, 3294, 3296, 3297, 3313, 3314, 3333, 3340, 3342, 3344, 3346, 3386, 3389, 3389, 3406, 3406, 3424, 3425, 3450, 3455, 3461, 3478, 3482, 3505, 3507, 3515, 3517, 3517, 3520, 3526, 3585, 3632, 3634, 3635, 3648, 3654, 3713, 3714, 3716, 3716, 3719, 3720, 3722, 3722, 3725, 3725, 3732, 3735, 3737, 3743, 3745, 3747, 3749, 3749, 3751, 3751, 3754, 3755, 3757, 3760, 3762, 3763, 3773, 3773, 3776, 3780, 3782, 3782, 3804, 3807, 3840, 3840, 3904, 3911, 3913, 3948, 3976, 3980, 4096, 4138, 4159, 4159, 4176, 4181, 4186, 4189, 4193, 4193, 4197, 4198, 4206, 4208, 4213, 4225, 4238, 4238, 4256, 4293, 4295, 4295, 4301, 4301, 4304, 4346, 4348, 4680, 4682, 4685, 4688, 4694, 4696, 4696, 4698, 4701, 4704, 4744, 4746, 4749, 4752, 4784, 4786, 4789, 4792, 4798, 4800, 4800, 4802, 4805, 4808, 4822, 4824, 4880, 4882, 4885, 4888, 4954, 4992, 5007, 5024, 5108, 5121, 5740, 5743, 5759, 5761, 5786, 5792, 5866, 5870, 5872, 5888, 5900, 5902, 5905, 5920, 5937, 5952, 5969, 5984, 5996, 5998, 6000, 6016, 6067, 6103, 6103, 6108, 6108, 6176, 6263, 6272, 6312, 6314, 6314, 6320, 6389, 6400, 6428, 6480, 6509, 6512, 6516, 6528, 6571, 6593, 6599, 6656, 6678, 6688, 6740, 6823, 6823, 6917, 6963, 6981, 6987, 7043, 7072, 7086, 7087, 7098, 7141, 7168, 7203, 7245, 7247, 7258, 7293, 7401, 7404, 7406, 7409, 7413, 7414, 7424, 7615, 7680, 7957, 7960, 7965, 7968, 8005, 8008, 8013, 8016, 8023, 8025, 8025, 8027, 8027, 8029, 8029, 8031, 8061, 8064, 8116, 8118, 8124, 8126, 8126, 8130, 8132, 8134, 8140, 8144, 8147, 8150, 8155, 8160, 8172, 8178, 8180, 8182, 8188, 8305, 8305, 8319, 8319, 8336, 8348, 8450, 8450, 8455, 8455, 8458, 8467, 8469, 8469, 8473, 8477, 8484, 8484, 8486, 8486, 8488, 8488, 8490, 8493, 8495, 8505, 8508, 8511, 8517, 8521, 8526, 8526, 8544, 8584, 11264, 11310, 11312, 11358, 11360, 11492, 11499, 11502, 11506, 11507, 11520, 11557, 11559, 11559, 11565, 11565, 11568, 11623, 11631, 11631, 11648, 11670, 11680, 11686, 11688, 11694, 11696, 11702, 11704, 11710, 11712, 11718, 11720, 11726, 11728, 11734, 11736, 11742, 11823, 11823, 12293, 12295, 12321, 12329, 12337, 12341, 12344, 12348, 12353, 12438, 12445, 12447, 12449, 12538, 12540, 12543, 12549, 12589, 12593, 12686, 12704, 12730, 12784, 12799, 13312, 19893, 19968, 40908, 40960, 42124, 42192, 42237, 42240, 42508, 42512, 42527, 42538, 42539, 42560, 42606, 42623, 42647, 42656, 42735, 42775, 42783, 42786, 42888, 42891, 42894, 42896, 42899, 42912, 42922, 43000, 43009, 43011, 43013, 43015, 43018, 43020, 43042, 43072, 43123, 43138, 43187, 43250, 43255, 43259, 43259, 43274, 43301, 43312, 43334, 43360, 43388, 43396, 43442, 43471, 43471, 43520, 43560, 43584, 43586, 43588, 43595, 43616, 43638, 43642, 43642, 43648, 43695, 43697, 43697, 43701, 43702, 43705, 43709, 43712, 43712, 43714, 43714, 43739, 43741, 43744, 43754, 43762, 43764, 43777, 43782, 43785, 43790, 43793, 43798, 43808, 43814, 43816, 43822, 43968, 44002, 44032, 55203, 55216, 55238, 55243, 55291, 63744, 64109, 64112, 64217, 64256, 64262, 64275, 64279, 64285, 64285, 64287, 64296, 64298, 64310, 64312, 64316, 64318, 64318, 64320, 64321, 64323, 64324, 64326, 64433, 64467, 64829, 64848, 64911, 64914, 64967, 65008, 65019, 65136, 65140, 65142, 65276, 65313, 65338, 65345, 65370, 65382, 65470, 65474, 65479, 65482, 65487, 65490, 65495, 65498, 65500,]; - var unicodeES5IdentifierPart = [170, 170, 181, 181, 186, 186, 192, 214, 216, 246, 248, 705, 710, 721, 736, 740, 748, 748, 750, 750, 768, 884, 886, 887, 890, 893, 902, 902, 904, 906, 908, 908, 910, 929, 931, 1013, 1015, 1153, 1155, 1159, 1162, 1319, 1329, 1366, 1369, 1369, 1377, 1415, 1425, 1469, 1471, 1471, 1473, 1474, 1476, 1477, 1479, 1479, 1488, 1514, 1520, 1522, 1552, 1562, 1568, 1641, 1646, 1747, 1749, 1756, 1759, 1768, 1770, 1788, 1791, 1791, 1808, 1866, 1869, 1969, 1984, 2037, 2042, 2042, 2048, 2093, 2112, 2139, 2208, 2208, 2210, 2220, 2276, 2302, 2304, 2403, 2406, 2415, 2417, 2423, 2425, 2431, 2433, 2435, 2437, 2444, 2447, 2448, 2451, 2472, 2474, 2480, 2482, 2482, 2486, 2489, 2492, 2500, 2503, 2504, 2507, 2510, 2519, 2519, 2524, 2525, 2527, 2531, 2534, 2545, 2561, 2563, 2565, 2570, 2575, 2576, 2579, 2600, 2602, 2608, 2610, 2611, 2613, 2614, 2616, 2617, 2620, 2620, 2622, 2626, 2631, 2632, 2635, 2637, 2641, 2641, 2649, 2652, 2654, 2654, 2662, 2677, 2689, 2691, 2693, 2701, 2703, 2705, 2707, 2728, 2730, 2736, 2738, 2739, 2741, 2745, 2748, 2757, 2759, 2761, 2763, 2765, 2768, 2768, 2784, 2787, 2790, 2799, 2817, 2819, 2821, 2828, 2831, 2832, 2835, 2856, 2858, 2864, 2866, 2867, 2869, 2873, 2876, 2884, 2887, 2888, 2891, 2893, 2902, 2903, 2908, 2909, 2911, 2915, 2918, 2927, 2929, 2929, 2946, 2947, 2949, 2954, 2958, 2960, 2962, 2965, 2969, 2970, 2972, 2972, 2974, 2975, 2979, 2980, 2984, 2986, 2990, 3001, 3006, 3010, 3014, 3016, 3018, 3021, 3024, 3024, 3031, 3031, 3046, 3055, 3073, 3075, 3077, 3084, 3086, 3088, 3090, 3112, 3114, 3123, 3125, 3129, 3133, 3140, 3142, 3144, 3146, 3149, 3157, 3158, 3160, 3161, 3168, 3171, 3174, 3183, 3202, 3203, 3205, 3212, 3214, 3216, 3218, 3240, 3242, 3251, 3253, 3257, 3260, 3268, 3270, 3272, 3274, 3277, 3285, 3286, 3294, 3294, 3296, 3299, 3302, 3311, 3313, 3314, 3330, 3331, 3333, 3340, 3342, 3344, 3346, 3386, 3389, 3396, 3398, 3400, 3402, 3406, 3415, 3415, 3424, 3427, 3430, 3439, 3450, 3455, 3458, 3459, 3461, 3478, 3482, 3505, 3507, 3515, 3517, 3517, 3520, 3526, 3530, 3530, 3535, 3540, 3542, 3542, 3544, 3551, 3570, 3571, 3585, 3642, 3648, 3662, 3664, 3673, 3713, 3714, 3716, 3716, 3719, 3720, 3722, 3722, 3725, 3725, 3732, 3735, 3737, 3743, 3745, 3747, 3749, 3749, 3751, 3751, 3754, 3755, 3757, 3769, 3771, 3773, 3776, 3780, 3782, 3782, 3784, 3789, 3792, 3801, 3804, 3807, 3840, 3840, 3864, 3865, 3872, 3881, 3893, 3893, 3895, 3895, 3897, 3897, 3902, 3911, 3913, 3948, 3953, 3972, 3974, 3991, 3993, 4028, 4038, 4038, 4096, 4169, 4176, 4253, 4256, 4293, 4295, 4295, 4301, 4301, 4304, 4346, 4348, 4680, 4682, 4685, 4688, 4694, 4696, 4696, 4698, 4701, 4704, 4744, 4746, 4749, 4752, 4784, 4786, 4789, 4792, 4798, 4800, 4800, 4802, 4805, 4808, 4822, 4824, 4880, 4882, 4885, 4888, 4954, 4957, 4959, 4992, 5007, 5024, 5108, 5121, 5740, 5743, 5759, 5761, 5786, 5792, 5866, 5870, 5872, 5888, 5900, 5902, 5908, 5920, 5940, 5952, 5971, 5984, 5996, 5998, 6000, 6002, 6003, 6016, 6099, 6103, 6103, 6108, 6109, 6112, 6121, 6155, 6157, 6160, 6169, 6176, 6263, 6272, 6314, 6320, 6389, 6400, 6428, 6432, 6443, 6448, 6459, 6470, 6509, 6512, 6516, 6528, 6571, 6576, 6601, 6608, 6617, 6656, 6683, 6688, 6750, 6752, 6780, 6783, 6793, 6800, 6809, 6823, 6823, 6912, 6987, 6992, 7001, 7019, 7027, 7040, 7155, 7168, 7223, 7232, 7241, 7245, 7293, 7376, 7378, 7380, 7414, 7424, 7654, 7676, 7957, 7960, 7965, 7968, 8005, 8008, 8013, 8016, 8023, 8025, 8025, 8027, 8027, 8029, 8029, 8031, 8061, 8064, 8116, 8118, 8124, 8126, 8126, 8130, 8132, 8134, 8140, 8144, 8147, 8150, 8155, 8160, 8172, 8178, 8180, 8182, 8188, 8204, 8205, 8255, 8256, 8276, 8276, 8305, 8305, 8319, 8319, 8336, 8348, 8400, 8412, 8417, 8417, 8421, 8432, 8450, 8450, 8455, 8455, 8458, 8467, 8469, 8469, 8473, 8477, 8484, 8484, 8486, 8486, 8488, 8488, 8490, 8493, 8495, 8505, 8508, 8511, 8517, 8521, 8526, 8526, 8544, 8584, 11264, 11310, 11312, 11358, 11360, 11492, 11499, 11507, 11520, 11557, 11559, 11559, 11565, 11565, 11568, 11623, 11631, 11631, 11647, 11670, 11680, 11686, 11688, 11694, 11696, 11702, 11704, 11710, 11712, 11718, 11720, 11726, 11728, 11734, 11736, 11742, 11744, 11775, 11823, 11823, 12293, 12295, 12321, 12335, 12337, 12341, 12344, 12348, 12353, 12438, 12441, 12442, 12445, 12447, 12449, 12538, 12540, 12543, 12549, 12589, 12593, 12686, 12704, 12730, 12784, 12799, 13312, 19893, 19968, 40908, 40960, 42124, 42192, 42237, 42240, 42508, 42512, 42539, 42560, 42607, 42612, 42621, 42623, 42647, 42655, 42737, 42775, 42783, 42786, 42888, 42891, 42894, 42896, 42899, 42912, 42922, 43000, 43047, 43072, 43123, 43136, 43204, 43216, 43225, 43232, 43255, 43259, 43259, 43264, 43309, 43312, 43347, 43360, 43388, 43392, 43456, 43471, 43481, 43520, 43574, 43584, 43597, 43600, 43609, 43616, 43638, 43642, 43643, 43648, 43714, 43739, 43741, 43744, 43759, 43762, 43766, 43777, 43782, 43785, 43790, 43793, 43798, 43808, 43814, 43816, 43822, 43968, 44010, 44012, 44013, 44016, 44025, 44032, 55203, 55216, 55238, 55243, 55291, 63744, 64109, 64112, 64217, 64256, 64262, 64275, 64279, 64285, 64296, 64298, 64310, 64312, 64316, 64318, 64318, 64320, 64321, 64323, 64324, 64326, 64433, 64467, 64829, 64848, 64911, 64914, 64967, 65008, 65019, 65024, 65039, 65056, 65062, 65075, 65076, 65101, 65103, 65136, 65140, 65142, 65276, 65296, 65305, 65313, 65338, 65343, 65343, 65345, 65370, 65382, 65470, 65474, 65479, 65482, 65487, 65490, 65495, 65498, 65500,]; - function lookupInUnicodeMap(code, map) { - // Bail out quickly if it couldn't possibly be in the map. - if (code < map[0]) { - return false; - } - // Perform binary search in one of the Unicode range maps - var lo = 0; - var hi = map.length; - var mid; - while (lo + 1 < hi) { - mid = lo + (hi - lo) / 2; - // mid has to be even to catch a range's beginning - mid -= mid % 2; - if (map[mid] <= code && code <= map[mid + 1]) { - return true; - } - if (code < map[mid]) { - hi = mid; - } - else { - lo = mid + 2; - } - } - return false; - } - /* @internal */ function isUnicodeIdentifierStart(code, languageVersion) { - return languageVersion >= 1 /* ES5 */ ? - lookupInUnicodeMap(code, unicodeES5IdentifierStart) : - lookupInUnicodeMap(code, unicodeES3IdentifierStart); - } - ts.isUnicodeIdentifierStart = isUnicodeIdentifierStart; - function isUnicodeIdentifierPart(code, languageVersion) { - return languageVersion >= 1 /* ES5 */ ? - lookupInUnicodeMap(code, unicodeES5IdentifierPart) : - lookupInUnicodeMap(code, unicodeES3IdentifierPart); - } - function makeReverseMap(source) { - var result = []; - for (var name_3 in source) { - if (source.hasOwnProperty(name_3)) { - result[source[name_3]] = name_3; - } - } - return result; - } - var tokenStrings = makeReverseMap(textToToken); - function tokenToString(t) { - return tokenStrings[t]; - } - ts.tokenToString = tokenToString; - /* @internal */ - function stringToToken(s) { - return textToToken[s]; - } - ts.stringToToken = stringToToken; - /* @internal */ - function computeLineStarts(text) { - var result = new Array(); - var pos = 0; - var lineStart = 0; - while (pos < text.length) { - var ch = text.charCodeAt(pos++); - switch (ch) { - case 13 /* carriageReturn */: - if (text.charCodeAt(pos) === 10 /* lineFeed */) { - pos++; - } - case 10 /* lineFeed */: - result.push(lineStart); - lineStart = pos; - break; - default: - if (ch > 127 /* maxAsciiCharacter */ && isLineBreak(ch)) { - result.push(lineStart); - lineStart = pos; - } - break; - } - } - result.push(lineStart); - return result; - } - ts.computeLineStarts = computeLineStarts; - function getPositionOfLineAndCharacter(sourceFile, line, character) { - return computePositionOfLineAndCharacter(getLineStarts(sourceFile), line, character); - } - ts.getPositionOfLineAndCharacter = getPositionOfLineAndCharacter; - /* @internal */ - function computePositionOfLineAndCharacter(lineStarts, line, character) { - ts.Debug.assert(line >= 0 && line < lineStarts.length); - return lineStarts[line] + character; - } - ts.computePositionOfLineAndCharacter = computePositionOfLineAndCharacter; - /* @internal */ - function getLineStarts(sourceFile) { - return sourceFile.lineMap || (sourceFile.lineMap = computeLineStarts(sourceFile.text)); - } - ts.getLineStarts = getLineStarts; - /* @internal */ - function computeLineAndCharacterOfPosition(lineStarts, position) { - var lineNumber = ts.binarySearch(lineStarts, position); - if (lineNumber < 0) { - // If the actual position was not found, - // the binary search returns the negative value of the next line start - // e.g. if the line starts at [5, 10, 23, 80] and the position requested was 20 - // then the search will return -2 - lineNumber = ~lineNumber - 1; - } - return { - line: lineNumber, - character: position - lineStarts[lineNumber] - }; - } - ts.computeLineAndCharacterOfPosition = computeLineAndCharacterOfPosition; - function getLineAndCharacterOfPosition(sourceFile, position) { - return computeLineAndCharacterOfPosition(getLineStarts(sourceFile), position); - } - ts.getLineAndCharacterOfPosition = getLineAndCharacterOfPosition; - var hasOwnProperty = Object.prototype.hasOwnProperty; - function isWhiteSpace(ch) { - // Note: nextLine is in the Zs space, and should be considered to be a whitespace. - // It is explicitly not a line-break as it isn't in the exact set specified by EcmaScript. - return ch === 32 /* space */ || - ch === 9 /* tab */ || - ch === 11 /* verticalTab */ || - ch === 12 /* formFeed */ || - ch === 160 /* nonBreakingSpace */ || - ch === 133 /* nextLine */ || - ch === 5760 /* ogham */ || - ch >= 8192 /* enQuad */ && ch <= 8203 /* zeroWidthSpace */ || - ch === 8239 /* narrowNoBreakSpace */ || - ch === 8287 /* mathematicalSpace */ || - ch === 12288 /* ideographicSpace */ || - ch === 65279 /* byteOrderMark */; - } - ts.isWhiteSpace = isWhiteSpace; - function isLineBreak(ch) { - // ES5 7.3: - // The ECMAScript line terminator characters are listed in Table 3. - // Table 3: Line Terminator Characters - // Code Unit Value Name Formal Name - // \u000A Line Feed - // \u000D Carriage Return - // \u2028 Line separator - // \u2029 Paragraph separator - // Only the characters in Table 3 are treated as line terminators. Other new line or line - // breaking characters are treated as white space but not as line terminators. - return ch === 10 /* lineFeed */ || - ch === 13 /* carriageReturn */ || - ch === 8232 /* lineSeparator */ || - ch === 8233 /* paragraphSeparator */; - } - ts.isLineBreak = isLineBreak; - function isDigit(ch) { - return ch >= 48 /* _0 */ && ch <= 57 /* _9 */; - } - /* @internal */ - function isOctalDigit(ch) { - return ch >= 48 /* _0 */ && ch <= 55 /* _7 */; - } - ts.isOctalDigit = isOctalDigit; - /* @internal */ - function skipTrivia(text, pos, stopAfterLineBreak) { - while (true) { - var ch = text.charCodeAt(pos); - switch (ch) { - case 13 /* carriageReturn */: - if (text.charCodeAt(pos + 1) === 10 /* lineFeed */) { - pos++; - } - case 10 /* lineFeed */: - pos++; - if (stopAfterLineBreak) { - return pos; - } - continue; - case 9 /* tab */: - case 11 /* verticalTab */: - case 12 /* formFeed */: - case 32 /* space */: - pos++; - continue; - case 47 /* slash */: - if (text.charCodeAt(pos + 1) === 47 /* slash */) { - pos += 2; - while (pos < text.length) { - if (isLineBreak(text.charCodeAt(pos))) { - break; - } - pos++; - } - continue; - } - if (text.charCodeAt(pos + 1) === 42 /* asterisk */) { - pos += 2; - while (pos < text.length) { - if (text.charCodeAt(pos) === 42 /* asterisk */ && text.charCodeAt(pos + 1) === 47 /* slash */) { - pos += 2; - break; - } - pos++; - } - continue; - } - break; - case 60 /* lessThan */: - case 61 /* equals */: - case 62 /* greaterThan */: - if (isConflictMarkerTrivia(text, pos)) { - pos = scanConflictMarkerTrivia(text, pos); - continue; - } - break; - default: - if (ch > 127 /* maxAsciiCharacter */ && (isWhiteSpace(ch) || isLineBreak(ch))) { - pos++; - continue; - } - break; - } - return pos; - } - } - ts.skipTrivia = skipTrivia; - // All conflict markers consist of the same character repeated seven times. If it is - // a <<<<<<< or >>>>>>> marker then it is also followd by a space. - var mergeConflictMarkerLength = "<<<<<<<".length; - function isConflictMarkerTrivia(text, pos) { - ts.Debug.assert(pos >= 0); - // Conflict markers must be at the start of a line. - if (pos === 0 || isLineBreak(text.charCodeAt(pos - 1))) { - var ch = text.charCodeAt(pos); - if ((pos + mergeConflictMarkerLength) < text.length) { - for (var i = 0, n = mergeConflictMarkerLength; i < n; i++) { - if (text.charCodeAt(pos + i) !== ch) { - return false; - } - } - return ch === 61 /* equals */ || - text.charCodeAt(pos + mergeConflictMarkerLength) === 32 /* space */; - } - } - return false; - } - function scanConflictMarkerTrivia(text, pos, error) { - if (error) { - error(ts.Diagnostics.Merge_conflict_marker_encountered, mergeConflictMarkerLength); - } - var ch = text.charCodeAt(pos); - var len = text.length; - if (ch === 60 /* lessThan */ || ch === 62 /* greaterThan */) { - while (pos < len && !isLineBreak(text.charCodeAt(pos))) { - pos++; - } - } - else { - ts.Debug.assert(ch === 61 /* equals */); - // Consume everything from the start of the mid-conlict marker to the start of the next - // end-conflict marker. - while (pos < len) { - var ch_1 = text.charCodeAt(pos); - if (ch_1 === 62 /* greaterThan */ && isConflictMarkerTrivia(text, pos)) { - break; - } - pos++; - } - } - return pos; - } - // Extract comments from the given source text starting at the given position. If trailing is - // false, whitespace is skipped until the first line break and comments between that location - // and the next token are returned.If trailing is true, comments occurring between the given - // position and the next line break are returned.The return value is an array containing a - // TextRange for each comment. Single-line comment ranges include the beginning '//' characters - // but not the ending line break. Multi - line comment ranges include the beginning '/* and - // ending '*/' characters.The return value is undefined if no comments were found. - function getCommentRanges(text, pos, trailing) { - var result; - var collecting = trailing || pos === 0; - while (true) { - var ch = text.charCodeAt(pos); - switch (ch) { - case 13 /* carriageReturn */: - if (text.charCodeAt(pos + 1) === 10 /* lineFeed */) { - pos++; - } - case 10 /* lineFeed */: - pos++; - if (trailing) { - return result; - } - collecting = true; - if (result && result.length) { - ts.lastOrUndefined(result).hasTrailingNewLine = true; - } - continue; - case 9 /* tab */: - case 11 /* verticalTab */: - case 12 /* formFeed */: - case 32 /* space */: - pos++; - continue; - case 47 /* slash */: - var nextChar = text.charCodeAt(pos + 1); - var hasTrailingNewLine = false; - if (nextChar === 47 /* slash */ || nextChar === 42 /* asterisk */) { - var kind = nextChar === 47 /* slash */ ? 2 /* SingleLineCommentTrivia */ : 3 /* MultiLineCommentTrivia */; - var startPos = pos; - pos += 2; - if (nextChar === 47 /* slash */) { - while (pos < text.length) { - if (isLineBreak(text.charCodeAt(pos))) { - hasTrailingNewLine = true; - break; - } - pos++; - } - } - else { - while (pos < text.length) { - if (text.charCodeAt(pos) === 42 /* asterisk */ && text.charCodeAt(pos + 1) === 47 /* slash */) { - pos += 2; - break; - } - pos++; - } - } - if (collecting) { - if (!result) { - result = []; - } - result.push({ pos: startPos, end: pos, hasTrailingNewLine: hasTrailingNewLine, kind: kind }); - } - continue; - } - break; - default: - if (ch > 127 /* maxAsciiCharacter */ && (isWhiteSpace(ch) || isLineBreak(ch))) { - if (result && result.length && isLineBreak(ch)) { - ts.lastOrUndefined(result).hasTrailingNewLine = true; - } - pos++; - continue; - } - break; - } - return result; - } - } - function getLeadingCommentRanges(text, pos) { - return getCommentRanges(text, pos, false); - } - ts.getLeadingCommentRanges = getLeadingCommentRanges; - function getTrailingCommentRanges(text, pos) { - return getCommentRanges(text, pos, true); - } - ts.getTrailingCommentRanges = getTrailingCommentRanges; - function isIdentifierStart(ch, languageVersion) { - return ch >= 65 /* A */ && ch <= 90 /* Z */ || ch >= 97 /* a */ && ch <= 122 /* z */ || - ch === 36 /* $ */ || ch === 95 /* _ */ || - ch > 127 /* maxAsciiCharacter */ && isUnicodeIdentifierStart(ch, languageVersion); - } - ts.isIdentifierStart = isIdentifierStart; - function isIdentifierPart(ch, languageVersion) { - return ch >= 65 /* A */ && ch <= 90 /* Z */ || ch >= 97 /* a */ && ch <= 122 /* z */ || - ch >= 48 /* _0 */ && ch <= 57 /* _9 */ || ch === 36 /* $ */ || ch === 95 /* _ */ || - ch > 127 /* maxAsciiCharacter */ && isUnicodeIdentifierPart(ch, languageVersion); - } - ts.isIdentifierPart = isIdentifierPart; - /* @internal */ - // Creates a scanner over a (possibly unspecified) range of a piece of text. - function createScanner(languageVersion, skipTrivia, text, onError, start, length) { - // Current position (end position of text of current token) - var pos; - // end of text - var end; - // Start position of whitespace before current token - var startPos; - // Start position of text of current token - var tokenPos; - var token; - var tokenValue; - var precedingLineBreak; - var hasExtendedUnicodeEscape; - var tokenIsUnterminated; - setText(text, start, length); - return { - getStartPos: function () { return startPos; }, - getTextPos: function () { return pos; }, - getToken: function () { return token; }, - getTokenPos: function () { return tokenPos; }, - getTokenText: function () { return text.substring(tokenPos, pos); }, - getTokenValue: function () { return tokenValue; }, - hasExtendedUnicodeEscape: function () { return hasExtendedUnicodeEscape; }, - hasPrecedingLineBreak: function () { return precedingLineBreak; }, - isIdentifier: function () { return token === 65 /* Identifier */ || token > 101 /* LastReservedWord */; }, - isReservedWord: function () { return token >= 66 /* FirstReservedWord */ && token <= 101 /* LastReservedWord */; }, - isUnterminated: function () { return tokenIsUnterminated; }, - reScanGreaterToken: reScanGreaterToken, - reScanSlashToken: reScanSlashToken, - reScanTemplateToken: reScanTemplateToken, - scan: scan, - setText: setText, - setScriptTarget: setScriptTarget, - setOnError: setOnError, - setTextPos: setTextPos, - tryScan: tryScan, - lookAhead: lookAhead - }; - function error(message, length) { - if (onError) { - onError(message, length || 0); - } - } - function isIdentifierStart(ch) { - return ch >= 65 /* A */ && ch <= 90 /* Z */ || ch >= 97 /* a */ && ch <= 122 /* z */ || - ch === 36 /* $ */ || ch === 95 /* _ */ || - ch > 127 /* maxAsciiCharacter */ && isUnicodeIdentifierStart(ch, languageVersion); - } - function isIdentifierPart(ch) { - return ch >= 65 /* A */ && ch <= 90 /* Z */ || ch >= 97 /* a */ && ch <= 122 /* z */ || - ch >= 48 /* _0 */ && ch <= 57 /* _9 */ || ch === 36 /* $ */ || ch === 95 /* _ */ || - ch > 127 /* maxAsciiCharacter */ && isUnicodeIdentifierPart(ch, languageVersion); - } - function scanNumber() { - var start = pos; - while (isDigit(text.charCodeAt(pos))) - pos++; - if (text.charCodeAt(pos) === 46 /* dot */) { - pos++; - while (isDigit(text.charCodeAt(pos))) - pos++; - } - var end = pos; - if (text.charCodeAt(pos) === 69 /* E */ || text.charCodeAt(pos) === 101 /* e */) { - pos++; - if (text.charCodeAt(pos) === 43 /* plus */ || text.charCodeAt(pos) === 45 /* minus */) - pos++; - if (isDigit(text.charCodeAt(pos))) { - pos++; - while (isDigit(text.charCodeAt(pos))) - pos++; - end = pos; - } - else { - error(ts.Diagnostics.Digit_expected); - } - } - return +(text.substring(start, end)); - } - function scanOctalDigits() { - var start = pos; - while (isOctalDigit(text.charCodeAt(pos))) { - pos++; - } - return +(text.substring(start, pos)); - } - /** - * Scans the given number of hexadecimal digits in the text, - * returning -1 if the given number is unavailable. - */ - function scanExactNumberOfHexDigits(count) { - return scanHexDigits(count, false); - } - /** - * Scans as many hexadecimal digits as are available in the text, - * returning -1 if the given number of digits was unavailable. - */ - function scanMinimumNumberOfHexDigits(count) { - return scanHexDigits(count, true); - } - function scanHexDigits(minCount, scanAsManyAsPossible) { - var digits = 0; - var value = 0; - while (digits < minCount || scanAsManyAsPossible) { - var ch = text.charCodeAt(pos); - if (ch >= 48 /* _0 */ && ch <= 57 /* _9 */) { - value = value * 16 + ch - 48 /* _0 */; - } - else if (ch >= 65 /* A */ && ch <= 70 /* F */) { - value = value * 16 + ch - 65 /* A */ + 10; - } - else if (ch >= 97 /* a */ && ch <= 102 /* f */) { - value = value * 16 + ch - 97 /* a */ + 10; - } - else { - break; - } - pos++; - digits++; - } - if (digits < minCount) { - value = -1; - } - return value; - } - function scanString() { - var quote = text.charCodeAt(pos++); - var result = ""; - var start = pos; - while (true) { - if (pos >= end) { - result += text.substring(start, pos); - tokenIsUnterminated = true; - error(ts.Diagnostics.Unterminated_string_literal); - break; - } - var ch = text.charCodeAt(pos); - if (ch === quote) { - result += text.substring(start, pos); - pos++; - break; - } - if (ch === 92 /* backslash */) { - result += text.substring(start, pos); - result += scanEscapeSequence(); - start = pos; - continue; - } - if (isLineBreak(ch)) { - result += text.substring(start, pos); - tokenIsUnterminated = true; - error(ts.Diagnostics.Unterminated_string_literal); - break; - } - pos++; - } - return result; - } - /** - * Sets the current 'tokenValue' and returns a NoSubstitutionTemplateLiteral or - * a literal component of a TemplateExpression. - */ - function scanTemplateAndSetTokenValue() { - var startedWithBacktick = text.charCodeAt(pos) === 96 /* backtick */; - pos++; - var start = pos; - var contents = ""; - var resultingToken; - while (true) { - if (pos >= end) { - contents += text.substring(start, pos); - tokenIsUnterminated = true; - error(ts.Diagnostics.Unterminated_template_literal); - resultingToken = startedWithBacktick ? 10 /* NoSubstitutionTemplateLiteral */ : 13 /* TemplateTail */; - break; - } - var currChar = text.charCodeAt(pos); - // '`' - if (currChar === 96 /* backtick */) { - contents += text.substring(start, pos); - pos++; - resultingToken = startedWithBacktick ? 10 /* NoSubstitutionTemplateLiteral */ : 13 /* TemplateTail */; - break; - } - // '${' - if (currChar === 36 /* $ */ && pos + 1 < end && text.charCodeAt(pos + 1) === 123 /* openBrace */) { - contents += text.substring(start, pos); - pos += 2; - resultingToken = startedWithBacktick ? 11 /* TemplateHead */ : 12 /* TemplateMiddle */; - break; - } - // Escape character - if (currChar === 92 /* backslash */) { - contents += text.substring(start, pos); - contents += scanEscapeSequence(); - start = pos; - continue; - } - // Speculated ECMAScript 6 Spec 11.8.6.1: - // and LineTerminatorSequences are normalized to for Template Values - if (currChar === 13 /* carriageReturn */) { - contents += text.substring(start, pos); - pos++; - if (pos < end && text.charCodeAt(pos) === 10 /* lineFeed */) { - pos++; - } - contents += "\n"; - start = pos; - continue; - } - pos++; - } - ts.Debug.assert(resultingToken !== undefined); - tokenValue = contents; - return resultingToken; - } - function scanEscapeSequence() { - pos++; - if (pos >= end) { - error(ts.Diagnostics.Unexpected_end_of_text); - return ""; - } - var ch = text.charCodeAt(pos++); - switch (ch) { - case 48 /* _0 */: - return "\0"; - case 98 /* b */: - return "\b"; - case 116 /* t */: - return "\t"; - case 110 /* n */: - return "\n"; - case 118 /* v */: - return "\v"; - case 102 /* f */: - return "\f"; - case 114 /* r */: - return "\r"; - case 39 /* singleQuote */: - return "\'"; - case 34 /* doubleQuote */: - return "\""; - case 117 /* u */: - // '\u{DDDDDDDD}' - if (pos < end && text.charCodeAt(pos) === 123 /* openBrace */) { - hasExtendedUnicodeEscape = true; - pos++; - return scanExtendedUnicodeEscape(); - } - // '\uDDDD' - return scanHexadecimalEscape(4); - case 120 /* x */: - // '\xDD' - return scanHexadecimalEscape(2); - // when encountering a LineContinuation (i.e. a backslash and a line terminator sequence), - // the line terminator is interpreted to be "the empty code unit sequence". - case 13 /* carriageReturn */: - if (pos < end && text.charCodeAt(pos) === 10 /* lineFeed */) { - pos++; - } - // fall through - case 10 /* lineFeed */: - case 8232 /* lineSeparator */: - case 8233 /* paragraphSeparator */: - return ""; - default: - return String.fromCharCode(ch); - } - } - function scanHexadecimalEscape(numDigits) { - var escapedValue = scanExactNumberOfHexDigits(numDigits); - if (escapedValue >= 0) { - return String.fromCharCode(escapedValue); - } - else { - error(ts.Diagnostics.Hexadecimal_digit_expected); - return ""; - } - } - function scanExtendedUnicodeEscape() { - var escapedValue = scanMinimumNumberOfHexDigits(1); - var isInvalidExtendedEscape = false; - // Validate the value of the digit - if (escapedValue < 0) { - error(ts.Diagnostics.Hexadecimal_digit_expected); - isInvalidExtendedEscape = true; - } - else if (escapedValue > 0x10FFFF) { - error(ts.Diagnostics.An_extended_Unicode_escape_value_must_be_between_0x0_and_0x10FFFF_inclusive); - isInvalidExtendedEscape = true; - } - if (pos >= end) { - error(ts.Diagnostics.Unexpected_end_of_text); - isInvalidExtendedEscape = true; - } - else if (text.charCodeAt(pos) == 125 /* closeBrace */) { - // Only swallow the following character up if it's a '}'. - pos++; - } - else { - error(ts.Diagnostics.Unterminated_Unicode_escape_sequence); - isInvalidExtendedEscape = true; - } - if (isInvalidExtendedEscape) { - return ""; - } - return utf16EncodeAsString(escapedValue); - } - // Derived from the 10.1.1 UTF16Encoding of the ES6 Spec. - function utf16EncodeAsString(codePoint) { - ts.Debug.assert(0x0 <= codePoint && codePoint <= 0x10FFFF); - if (codePoint <= 65535) { - return String.fromCharCode(codePoint); - } - var codeUnit1 = Math.floor((codePoint - 65536) / 1024) + 0xD800; - var codeUnit2 = ((codePoint - 65536) % 1024) + 0xDC00; - return String.fromCharCode(codeUnit1, codeUnit2); - } - // Current character is known to be a backslash. Check for Unicode escape of the form '\uXXXX' - // and return code point value if valid Unicode escape is found. Otherwise return -1. - function peekUnicodeEscape() { - if (pos + 5 < end && text.charCodeAt(pos + 1) === 117 /* u */) { - var start_1 = pos; - pos += 2; - var value = scanExactNumberOfHexDigits(4); - pos = start_1; - return value; - } - return -1; - } - function scanIdentifierParts() { - var result = ""; - var start = pos; - while (pos < end) { - var ch = text.charCodeAt(pos); - if (isIdentifierPart(ch)) { - pos++; - } - else if (ch === 92 /* backslash */) { - ch = peekUnicodeEscape(); - if (!(ch >= 0 && isIdentifierPart(ch))) { - break; - } - result += text.substring(start, pos); - result += String.fromCharCode(ch); - // Valid Unicode escape is always six characters - pos += 6; - start = pos; - } - else { - break; - } - } - result += text.substring(start, pos); - return result; - } - function getIdentifierToken() { - // Reserved words are between 2 and 11 characters long and start with a lowercase letter - var len = tokenValue.length; - if (len >= 2 && len <= 11) { - var ch = tokenValue.charCodeAt(0); - if (ch >= 97 /* a */ && ch <= 122 /* z */ && hasOwnProperty.call(textToToken, tokenValue)) { - return token = textToToken[tokenValue]; - } - } - return token = 65 /* Identifier */; - } - function scanBinaryOrOctalDigits(base) { - ts.Debug.assert(base !== 2 || base !== 8, "Expected either base 2 or base 8"); - var value = 0; - // For counting number of digits; Valid binaryIntegerLiteral must have at least one binary digit following B or b. - // Similarly valid octalIntegerLiteral must have at least one octal digit following o or O. - var numberOfDigits = 0; - while (true) { - var ch = text.charCodeAt(pos); - var valueOfCh = ch - 48 /* _0 */; - if (!isDigit(ch) || valueOfCh >= base) { - break; - } - value = value * base + valueOfCh; - pos++; - numberOfDigits++; - } - // Invalid binaryIntegerLiteral or octalIntegerLiteral - if (numberOfDigits === 0) { - return -1; - } - return value; - } - function scan() { - startPos = pos; - hasExtendedUnicodeEscape = false; - precedingLineBreak = false; - tokenIsUnterminated = false; - while (true) { - tokenPos = pos; - if (pos >= end) { - return token = 1 /* EndOfFileToken */; - } - var ch = text.charCodeAt(pos); - switch (ch) { - case 10 /* lineFeed */: - case 13 /* carriageReturn */: - precedingLineBreak = true; - if (skipTrivia) { - pos++; - continue; - } - else { - if (ch === 13 /* carriageReturn */ && pos + 1 < end && text.charCodeAt(pos + 1) === 10 /* lineFeed */) { - // consume both CR and LF - pos += 2; - } - else { - pos++; - } - return token = 4 /* NewLineTrivia */; - } - case 9 /* tab */: - case 11 /* verticalTab */: - case 12 /* formFeed */: - case 32 /* space */: - if (skipTrivia) { - pos++; - continue; - } - else { - while (pos < end && isWhiteSpace(text.charCodeAt(pos))) { - pos++; - } - return token = 5 /* WhitespaceTrivia */; - } - case 33 /* exclamation */: - if (text.charCodeAt(pos + 1) === 61 /* equals */) { - if (text.charCodeAt(pos + 2) === 61 /* equals */) { - return pos += 3, token = 31 /* ExclamationEqualsEqualsToken */; - } - return pos += 2, token = 29 /* ExclamationEqualsToken */; - } - return pos++, token = 46 /* ExclamationToken */; - case 34 /* doubleQuote */: - case 39 /* singleQuote */: - tokenValue = scanString(); - return token = 8 /* StringLiteral */; - case 96 /* backtick */: - return token = scanTemplateAndSetTokenValue(); - case 37 /* percent */: - if (text.charCodeAt(pos + 1) === 61 /* equals */) { - return pos += 2, token = 58 /* PercentEqualsToken */; - } - return pos++, token = 37 /* PercentToken */; - case 38 /* ampersand */: - if (text.charCodeAt(pos + 1) === 38 /* ampersand */) { - return pos += 2, token = 48 /* AmpersandAmpersandToken */; - } - if (text.charCodeAt(pos + 1) === 61 /* equals */) { - return pos += 2, token = 62 /* AmpersandEqualsToken */; - } - return pos++, token = 43 /* AmpersandToken */; - case 40 /* openParen */: - return pos++, token = 16 /* OpenParenToken */; - case 41 /* closeParen */: - return pos++, token = 17 /* CloseParenToken */; - case 42 /* asterisk */: - if (text.charCodeAt(pos + 1) === 61 /* equals */) { - return pos += 2, token = 56 /* AsteriskEqualsToken */; - } - return pos++, token = 35 /* AsteriskToken */; - case 43 /* plus */: - if (text.charCodeAt(pos + 1) === 43 /* plus */) { - return pos += 2, token = 38 /* PlusPlusToken */; - } - if (text.charCodeAt(pos + 1) === 61 /* equals */) { - return pos += 2, token = 54 /* PlusEqualsToken */; - } - return pos++, token = 33 /* PlusToken */; - case 44 /* comma */: - return pos++, token = 23 /* CommaToken */; - case 45 /* minus */: - if (text.charCodeAt(pos + 1) === 45 /* minus */) { - return pos += 2, token = 39 /* MinusMinusToken */; - } - if (text.charCodeAt(pos + 1) === 61 /* equals */) { - return pos += 2, token = 55 /* MinusEqualsToken */; - } - return pos++, token = 34 /* MinusToken */; - case 46 /* dot */: - if (isDigit(text.charCodeAt(pos + 1))) { - tokenValue = "" + scanNumber(); - return token = 7 /* NumericLiteral */; - } - if (text.charCodeAt(pos + 1) === 46 /* dot */ && text.charCodeAt(pos + 2) === 46 /* dot */) { - return pos += 3, token = 21 /* DotDotDotToken */; - } - return pos++, token = 20 /* DotToken */; - case 47 /* slash */: - // Single-line comment - if (text.charCodeAt(pos + 1) === 47 /* slash */) { - pos += 2; - while (pos < end) { - if (isLineBreak(text.charCodeAt(pos))) { - break; - } - pos++; - } - if (skipTrivia) { - continue; - } - else { - return token = 2 /* SingleLineCommentTrivia */; - } - } - // Multi-line comment - if (text.charCodeAt(pos + 1) === 42 /* asterisk */) { - pos += 2; - var commentClosed = false; - while (pos < end) { - var ch_2 = text.charCodeAt(pos); - if (ch_2 === 42 /* asterisk */ && text.charCodeAt(pos + 1) === 47 /* slash */) { - pos += 2; - commentClosed = true; - break; - } - if (isLineBreak(ch_2)) { - precedingLineBreak = true; - } - pos++; - } - if (!commentClosed) { - error(ts.Diagnostics.Asterisk_Slash_expected); - } - if (skipTrivia) { - continue; - } - else { - tokenIsUnterminated = !commentClosed; - return token = 3 /* MultiLineCommentTrivia */; - } - } - if (text.charCodeAt(pos + 1) === 61 /* equals */) { - return pos += 2, token = 57 /* SlashEqualsToken */; - } - return pos++, token = 36 /* SlashToken */; - case 48 /* _0 */: - if (pos + 2 < end && (text.charCodeAt(pos + 1) === 88 /* X */ || text.charCodeAt(pos + 1) === 120 /* x */)) { - pos += 2; - var value = scanMinimumNumberOfHexDigits(1); - if (value < 0) { - error(ts.Diagnostics.Hexadecimal_digit_expected); - value = 0; - } - tokenValue = "" + value; - return token = 7 /* NumericLiteral */; - } - else if (pos + 2 < end && (text.charCodeAt(pos + 1) === 66 /* B */ || text.charCodeAt(pos + 1) === 98 /* b */)) { - pos += 2; - var value = scanBinaryOrOctalDigits(2); - if (value < 0) { - error(ts.Diagnostics.Binary_digit_expected); - value = 0; - } - tokenValue = "" + value; - return token = 7 /* NumericLiteral */; - } - else if (pos + 2 < end && (text.charCodeAt(pos + 1) === 79 /* O */ || text.charCodeAt(pos + 1) === 111 /* o */)) { - pos += 2; - var value = scanBinaryOrOctalDigits(8); - if (value < 0) { - error(ts.Diagnostics.Octal_digit_expected); - value = 0; - } - tokenValue = "" + value; - return token = 7 /* NumericLiteral */; - } - // Try to parse as an octal - if (pos + 1 < end && isOctalDigit(text.charCodeAt(pos + 1))) { - tokenValue = "" + scanOctalDigits(); - return token = 7 /* NumericLiteral */; - } - // This fall-through is a deviation from the EcmaScript grammar. The grammar says that a leading zero - // can only be followed by an octal digit, a dot, or the end of the number literal. However, we are being - // permissive and allowing decimal digits of the form 08* and 09* (which many browsers also do). - case 49 /* _1 */: - case 50 /* _2 */: - case 51 /* _3 */: - case 52 /* _4 */: - case 53 /* _5 */: - case 54 /* _6 */: - case 55 /* _7 */: - case 56 /* _8 */: - case 57 /* _9 */: - tokenValue = "" + scanNumber(); - return token = 7 /* NumericLiteral */; - case 58 /* colon */: - return pos++, token = 51 /* ColonToken */; - case 59 /* semicolon */: - return pos++, token = 22 /* SemicolonToken */; - case 60 /* lessThan */: - if (isConflictMarkerTrivia(text, pos)) { - pos = scanConflictMarkerTrivia(text, pos, error); - if (skipTrivia) { - continue; - } - else { - return token = 6 /* ConflictMarkerTrivia */; - } - } - if (text.charCodeAt(pos + 1) === 60 /* lessThan */) { - if (text.charCodeAt(pos + 2) === 61 /* equals */) { - return pos += 3, token = 59 /* LessThanLessThanEqualsToken */; - } - return pos += 2, token = 40 /* LessThanLessThanToken */; - } - if (text.charCodeAt(pos + 1) === 61 /* equals */) { - return pos += 2, token = 26 /* LessThanEqualsToken */; - } - return pos++, token = 24 /* LessThanToken */; - case 61 /* equals */: - if (isConflictMarkerTrivia(text, pos)) { - pos = scanConflictMarkerTrivia(text, pos, error); - if (skipTrivia) { - continue; - } - else { - return token = 6 /* ConflictMarkerTrivia */; - } - } - if (text.charCodeAt(pos + 1) === 61 /* equals */) { - if (text.charCodeAt(pos + 2) === 61 /* equals */) { - return pos += 3, token = 30 /* EqualsEqualsEqualsToken */; - } - return pos += 2, token = 28 /* EqualsEqualsToken */; - } - if (text.charCodeAt(pos + 1) === 62 /* greaterThan */) { - return pos += 2, token = 32 /* EqualsGreaterThanToken */; - } - return pos++, token = 53 /* EqualsToken */; - case 62 /* greaterThan */: - if (isConflictMarkerTrivia(text, pos)) { - pos = scanConflictMarkerTrivia(text, pos, error); - if (skipTrivia) { - continue; - } - else { - return token = 6 /* ConflictMarkerTrivia */; - } - } - return pos++, token = 25 /* GreaterThanToken */; - case 63 /* question */: - return pos++, token = 50 /* QuestionToken */; - case 91 /* openBracket */: - return pos++, token = 18 /* OpenBracketToken */; - case 93 /* closeBracket */: - return pos++, token = 19 /* CloseBracketToken */; - case 94 /* caret */: - if (text.charCodeAt(pos + 1) === 61 /* equals */) { - return pos += 2, token = 64 /* CaretEqualsToken */; - } - return pos++, token = 45 /* CaretToken */; - case 123 /* openBrace */: - return pos++, token = 14 /* OpenBraceToken */; - case 124 /* bar */: - if (text.charCodeAt(pos + 1) === 124 /* bar */) { - return pos += 2, token = 49 /* BarBarToken */; - } - if (text.charCodeAt(pos + 1) === 61 /* equals */) { - return pos += 2, token = 63 /* BarEqualsToken */; - } - return pos++, token = 44 /* BarToken */; - case 125 /* closeBrace */: - return pos++, token = 15 /* CloseBraceToken */; - case 126 /* tilde */: - return pos++, token = 47 /* TildeToken */; - case 64 /* at */: - return pos++, token = 52 /* AtToken */; - case 92 /* backslash */: - var cookedChar = peekUnicodeEscape(); - if (cookedChar >= 0 && isIdentifierStart(cookedChar)) { - pos += 6; - tokenValue = String.fromCharCode(cookedChar) + scanIdentifierParts(); - return token = getIdentifierToken(); - } - error(ts.Diagnostics.Invalid_character); - return pos++, token = 0 /* Unknown */; - default: - if (isIdentifierStart(ch)) { - pos++; - while (pos < end && isIdentifierPart(ch = text.charCodeAt(pos))) - pos++; - tokenValue = text.substring(tokenPos, pos); - if (ch === 92 /* backslash */) { - tokenValue += scanIdentifierParts(); - } - return token = getIdentifierToken(); - } - else if (isWhiteSpace(ch)) { - pos++; - continue; - } - else if (isLineBreak(ch)) { - precedingLineBreak = true; - pos++; - continue; - } - error(ts.Diagnostics.Invalid_character); - return pos++, token = 0 /* Unknown */; - } - } - } - function reScanGreaterToken() { - if (token === 25 /* GreaterThanToken */) { - if (text.charCodeAt(pos) === 62 /* greaterThan */) { - if (text.charCodeAt(pos + 1) === 62 /* greaterThan */) { - if (text.charCodeAt(pos + 2) === 61 /* equals */) { - return pos += 3, token = 61 /* GreaterThanGreaterThanGreaterThanEqualsToken */; - } - return pos += 2, token = 42 /* GreaterThanGreaterThanGreaterThanToken */; - } - if (text.charCodeAt(pos + 1) === 61 /* equals */) { - return pos += 2, token = 60 /* GreaterThanGreaterThanEqualsToken */; - } - return pos++, token = 41 /* GreaterThanGreaterThanToken */; - } - if (text.charCodeAt(pos) === 61 /* equals */) { - return pos++, token = 27 /* GreaterThanEqualsToken */; - } - } - return token; - } - function reScanSlashToken() { - if (token === 36 /* SlashToken */ || token === 57 /* SlashEqualsToken */) { - var p = tokenPos + 1; - var inEscape = false; - var inCharacterClass = false; - while (true) { - // If we reach the end of a file, or hit a newline, then this is an unterminated - // regex. Report error and return what we have so far. - if (p >= end) { - tokenIsUnterminated = true; - error(ts.Diagnostics.Unterminated_regular_expression_literal); - break; - } - var ch = text.charCodeAt(p); - if (isLineBreak(ch)) { - tokenIsUnterminated = true; - error(ts.Diagnostics.Unterminated_regular_expression_literal); - break; - } - if (inEscape) { - // Parsing an escape character; - // reset the flag and just advance to the next char. - inEscape = false; - } - else if (ch === 47 /* slash */ && !inCharacterClass) { - // A slash within a character class is permissible, - // but in general it signals the end of the regexp literal. - p++; - break; - } - else if (ch === 91 /* openBracket */) { - inCharacterClass = true; - } - else if (ch === 92 /* backslash */) { - inEscape = true; - } - else if (ch === 93 /* closeBracket */) { - inCharacterClass = false; - } - p++; - } - while (p < end && isIdentifierPart(text.charCodeAt(p))) { - p++; - } - pos = p; - tokenValue = text.substring(tokenPos, pos); - token = 9 /* RegularExpressionLiteral */; - } - return token; - } - /** - * Unconditionally back up and scan a template expression portion. - */ - function reScanTemplateToken() { - ts.Debug.assert(token === 15 /* CloseBraceToken */, "'reScanTemplateToken' should only be called on a '}'"); - pos = tokenPos; - return token = scanTemplateAndSetTokenValue(); - } - function speculationHelper(callback, isLookahead) { - var savePos = pos; - var saveStartPos = startPos; - var saveTokenPos = tokenPos; - var saveToken = token; - var saveTokenValue = tokenValue; - var savePrecedingLineBreak = precedingLineBreak; - var result = callback(); - // If our callback returned something 'falsy' or we're just looking ahead, - // then unconditionally restore us to where we were. - if (!result || isLookahead) { - pos = savePos; - startPos = saveStartPos; - tokenPos = saveTokenPos; - token = saveToken; - tokenValue = saveTokenValue; - precedingLineBreak = savePrecedingLineBreak; - } - return result; - } - function lookAhead(callback) { - return speculationHelper(callback, true); - } - function tryScan(callback) { - return speculationHelper(callback, false); - } - function setText(newText, start, length) { - text = newText || ""; - end = length === undefined ? text.length : start + length; - setTextPos(start || 0); - } - function setOnError(errorCallback) { - onError = errorCallback; - } - function setScriptTarget(scriptTarget) { - languageVersion = scriptTarget; - } - function setTextPos(textPos) { - ts.Debug.assert(textPos >= 0); - pos = textPos; - startPos = textPos; - tokenPos = textPos; - token = 0 /* Unknown */; - precedingLineBreak = false; - tokenValue = undefined; - hasExtendedUnicodeEscape = false; - tokenIsUnterminated = false; - } - } - ts.createScanner = createScanner; -})(ts || (ts = {})); -/// -/* @internal */ -var ts; -(function (ts) { - ts.bindTime = 0; - (function (ModuleInstanceState) { - ModuleInstanceState[ModuleInstanceState["NonInstantiated"] = 0] = "NonInstantiated"; - ModuleInstanceState[ModuleInstanceState["Instantiated"] = 1] = "Instantiated"; - ModuleInstanceState[ModuleInstanceState["ConstEnumOnly"] = 2] = "ConstEnumOnly"; - })(ts.ModuleInstanceState || (ts.ModuleInstanceState = {})); - var ModuleInstanceState = ts.ModuleInstanceState; - function getModuleInstanceState(node) { - // A module is uninstantiated if it contains only - // 1. interface declarations, type alias declarations - if (node.kind === 205 /* InterfaceDeclaration */ || node.kind === 206 /* TypeAliasDeclaration */) { - return 0 /* NonInstantiated */; - } - else if (ts.isConstEnumDeclaration(node)) { - return 2 /* ConstEnumOnly */; - } - else if ((node.kind === 212 /* ImportDeclaration */ || node.kind === 211 /* ImportEqualsDeclaration */) && !(node.flags & 1 /* Export */)) { - return 0 /* NonInstantiated */; - } - else if (node.kind === 209 /* ModuleBlock */) { - var state = 0 /* NonInstantiated */; - ts.forEachChild(node, function (n) { - switch (getModuleInstanceState(n)) { - case 0 /* NonInstantiated */: - // child is non-instantiated - continue searching - return false; - case 2 /* ConstEnumOnly */: - // child is const enum only - record state and continue searching - state = 2 /* ConstEnumOnly */; - return false; - case 1 /* Instantiated */: - // child is instantiated - record state and stop - state = 1 /* Instantiated */; - return true; - } - }); - return state; - } - else if (node.kind === 208 /* ModuleDeclaration */) { - return getModuleInstanceState(node.body); - } - else { - return 1 /* Instantiated */; - } - } - ts.getModuleInstanceState = getModuleInstanceState; - var ContainerFlags; - (function (ContainerFlags) { - // The current node is not a container, and no container manipulation should happen before - // recursing into it. - ContainerFlags[ContainerFlags["None"] = 0] = "None"; - // The current node is a container. It should be set as the current container (and block- - // container) before recursing into it. The current node does not have locals. Examples: - // - // Classes, ObjectLiterals, TypeLiterals, Interfaces... - ContainerFlags[ContainerFlags["IsContainer"] = 1] = "IsContainer"; - // The current node is a block-scoped-container. It should be set as the current block- - // container before recursing into it. Examples: - // - // Blocks (when not parented by functions), Catch clauses, For/For-in/For-of statements... - ContainerFlags[ContainerFlags["IsBlockScopedContainer"] = 2] = "IsBlockScopedContainer"; - ContainerFlags[ContainerFlags["HasLocals"] = 4] = "HasLocals"; - // If the current node is a container that also container that also contains locals. Examples: - // - // Functions, Methods, Modules, Source-files. - ContainerFlags[ContainerFlags["IsContainerWithLocals"] = 5] = "IsContainerWithLocals"; - })(ContainerFlags || (ContainerFlags = {})); - function bindSourceFile(file) { - var start = new Date().getTime(); - bindSourceFileWorker(file); - ts.bindTime += new Date().getTime() - start; - } - ts.bindSourceFile = bindSourceFile; - function bindSourceFileWorker(file) { - var parent; - var container; - var blockScopeContainer; - var lastContainer; - var symbolCount = 0; - var Symbol = ts.objectAllocator.getSymbolConstructor(); - var classifiableNames = {}; - if (!file.locals) { - bind(file); - file.symbolCount = symbolCount; - file.classifiableNames = classifiableNames; - } - return; - function createSymbol(flags, name) { - symbolCount++; - return new Symbol(flags, name); - } - function addDeclarationToSymbol(symbol, node, symbolFlags) { - symbol.flags |= symbolFlags; - node.symbol = symbol; - if (!symbol.declarations) { - symbol.declarations = []; - } - symbol.declarations.push(node); - if (symbolFlags & 1952 /* HasExports */ && !symbol.exports) { - symbol.exports = {}; - } - if (symbolFlags & 6240 /* HasMembers */ && !symbol.members) { - symbol.members = {}; - } - if (symbolFlags & 107455 /* Value */ && !symbol.valueDeclaration) { - symbol.valueDeclaration = node; - } - } - // Should not be called on a declaration with a computed property name, - // unless it is a well known Symbol. - function getDeclarationName(node) { - if (node.name) { - if (node.kind === 208 /* ModuleDeclaration */ && node.name.kind === 8 /* StringLiteral */) { - return '"' + node.name.text + '"'; - } - if (node.name.kind === 129 /* ComputedPropertyName */) { - var nameExpression = node.name.expression; - ts.Debug.assert(ts.isWellKnownSymbolSyntactically(nameExpression)); - return ts.getPropertyNameForKnownSymbolName(nameExpression.name.text); - } - return node.name.text; - } - switch (node.kind) { - case 137 /* Constructor */: - return "__constructor"; - case 145 /* FunctionType */: - case 140 /* CallSignature */: - return "__call"; - case 146 /* ConstructorType */: - case 141 /* ConstructSignature */: - return "__new"; - case 142 /* IndexSignature */: - return "__index"; - case 218 /* ExportDeclaration */: - return "__export"; - case 217 /* ExportAssignment */: - return node.isExportEquals ? "export=" : "default"; - case 203 /* FunctionDeclaration */: - case 204 /* ClassDeclaration */: - return node.flags & 256 /* Default */ ? "default" : undefined; - } - } - function getDisplayName(node) { - return node.name ? ts.declarationNameToString(node.name) : getDeclarationName(node); - } - function declareSymbol(symbolTable, parent, node, includes, excludes) { - ts.Debug.assert(!ts.hasDynamicName(node)); - // The exported symbol for an export default function/class node is always named "default" - var name = node.flags & 256 /* Default */ && parent ? "default" : getDeclarationName(node); - var symbol; - if (name !== undefined) { - // Check and see if the symbol table already has a symbol with this name. If not, - // create a new symbol with this name and add it to the table. Note that we don't - // give the new symbol any flags *yet*. This ensures that it will not conflict - // witht he 'excludes' flags we pass in. - // - // If we do get an existing symbol, see if it conflicts with the new symbol we're - // creating. For example, a 'var' symbol and a 'class' symbol will conflict within - // the same symbol table. If we have a conflict, report the issue on each - // declaration we have for this symbol, and then create a new symbol for this - // declaration. - // - // If we created a new symbol, either because we didn't have a symbol with this name - // in the symbol table, or we conflicted with an existing symbol, then just add this - // node as the sole declaration of the new symbol. - // - // Otherwise, we'll be merging into a compatible existing symbol (for example when - // you have multiple 'vars' with the same name in the same container). In this case - // just add this node into the declarations list of the symbol. - symbol = ts.hasProperty(symbolTable, name) - ? symbolTable[name] - : (symbolTable[name] = createSymbol(0 /* None */, name)); - if (name && (includes & 788448 /* Classifiable */)) { - classifiableNames[name] = name; - } - if (symbol.flags & excludes) { - if (node.name) { - node.name.parent = node; - } - // Report errors every position with duplicate declaration - // Report errors on previous encountered declarations - var message = symbol.flags & 2 /* BlockScopedVariable */ - ? ts.Diagnostics.Cannot_redeclare_block_scoped_variable_0 - : ts.Diagnostics.Duplicate_identifier_0; - ts.forEach(symbol.declarations, function (declaration) { - file.bindDiagnostics.push(ts.createDiagnosticForNode(declaration.name || declaration, message, getDisplayName(declaration))); - }); - file.bindDiagnostics.push(ts.createDiagnosticForNode(node.name || node, message, getDisplayName(node))); - symbol = createSymbol(0 /* None */, name); - } - } - else { - symbol = createSymbol(0 /* None */, "__missing"); - } - addDeclarationToSymbol(symbol, node, includes); - symbol.parent = parent; - return symbol; - } - function declareModuleMember(node, symbolFlags, symbolExcludes) { - var hasExportModifier = ts.getCombinedNodeFlags(node) & 1 /* Export */; - if (symbolFlags & 8388608 /* Alias */) { - if (node.kind === 220 /* ExportSpecifier */ || (node.kind === 211 /* ImportEqualsDeclaration */ && hasExportModifier)) { - return declareSymbol(container.symbol.exports, container.symbol, node, symbolFlags, symbolExcludes); - } - else { - return declareSymbol(container.locals, undefined, node, symbolFlags, symbolExcludes); - } - } - else { - // Exported module members are given 2 symbols: A local symbol that is classified with an ExportValue, - // ExportType, or ExportContainer flag, and an associated export symbol with all the correct flags set - // on it. There are 2 main reasons: - // - // 1. We treat locals and exports of the same name as mutually exclusive within a container. - // That means the binder will issue a Duplicate Identifier error if you mix locals and exports - // with the same name in the same container. - // TODO: Make this a more specific error and decouple it from the exclusion logic. - // 2. When we checkIdentifier in the checker, we set its resolved symbol to the local symbol, - // but return the export symbol (by calling getExportSymbolOfValueSymbolIfExported). That way - // when the emitter comes back to it, it knows not to qualify the name if it was found in a containing scope. - if (hasExportModifier || container.flags & 65536 /* ExportContext */) { - var exportKind = (symbolFlags & 107455 /* Value */ ? 1048576 /* ExportValue */ : 0) | - (symbolFlags & 793056 /* Type */ ? 2097152 /* ExportType */ : 0) | - (symbolFlags & 1536 /* Namespace */ ? 4194304 /* ExportNamespace */ : 0); - var local = declareSymbol(container.locals, undefined, node, exportKind, symbolExcludes); - local.exportSymbol = declareSymbol(container.symbol.exports, container.symbol, node, symbolFlags, symbolExcludes); - node.localSymbol = local; - return local; - } - else { - return declareSymbol(container.locals, undefined, node, symbolFlags, symbolExcludes); - } - } - } - // All container nodes are kept on a linked list in declaration order. This list is used by - // the getLocalNameOfContainer function in the type checker to validate that the local name - // used for a container is unique. - function bindChildren(node) { - // Before we recurse into a node's chilren, we first save the existing parent, container - // and block-container. Then after we pop out of processing the children, we restore - // these saved values. - var saveParent = parent; - var saveContainer = container; - var savedBlockScopeContainer = blockScopeContainer; - // This node will now be set as the parent of all of its children as we recurse into them. - parent = node; - // Depending on what kind of node this is, we may have to adjust the current container - // and block-container. If the current node is a container, then it is automatically - // considered the current block-container as well. Also, for containers that we know - // may contain locals, we proactively initialize the .locals field. We do this because - // it's highly likely that the .locals will be needed to place some child in (for example, - // a parameter, or variable declaration). - // - // However, we do not proactively create the .locals for block-containers because it's - // totally normal and common for block-containers to never actually have a block-scoped - // variable in them. We don't want to end up allocating an object for every 'block' we - // run into when most of them won't be necessary. - // - // Finally, if this is a block-container, then we clear out any existing .locals object - // it may contain within it. This happens in incremental scenarios. Because we can be - // reusing a node from a previous compilation, that node may have had 'locals' created - // for it. We must clear this so we don't accidently move any stale data forward from - // a previous compilation. - var containerFlags = getContainerFlags(node); - if (containerFlags & 1 /* IsContainer */) { - container = blockScopeContainer = node; - if (containerFlags & 4 /* HasLocals */) { - container.locals = {}; - } - addToContainerChain(container); - } - else if (containerFlags & 2 /* IsBlockScopedContainer */) { - blockScopeContainer = node; - blockScopeContainer.locals = undefined; - } - ts.forEachChild(node, bind); - container = saveContainer; - parent = saveParent; - blockScopeContainer = savedBlockScopeContainer; - } - function getContainerFlags(node) { - switch (node.kind) { - case 177 /* ClassExpression */: - case 204 /* ClassDeclaration */: - case 205 /* InterfaceDeclaration */: - case 207 /* EnumDeclaration */: - case 148 /* TypeLiteral */: - case 157 /* ObjectLiteralExpression */: - return 1 /* IsContainer */; - case 140 /* CallSignature */: - case 141 /* ConstructSignature */: - case 142 /* IndexSignature */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 203 /* FunctionDeclaration */: - case 137 /* Constructor */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 145 /* FunctionType */: - case 146 /* ConstructorType */: - case 165 /* FunctionExpression */: - case 166 /* ArrowFunction */: - case 208 /* ModuleDeclaration */: - case 230 /* SourceFile */: - case 206 /* TypeAliasDeclaration */: - return 5 /* IsContainerWithLocals */; - case 226 /* CatchClause */: - case 189 /* ForStatement */: - case 190 /* ForInStatement */: - case 191 /* ForOfStatement */: - case 210 /* CaseBlock */: - return 2 /* IsBlockScopedContainer */; - case 182 /* Block */: - // do not treat blocks directly inside a function as a block-scoped-container. - // Locals that reside in this block should go to the function locals. Othewise 'x' - // would not appear to be a redeclaration of a block scoped local in the following - // example: - // - // function foo() { - // var x; - // let x; - // } - // - // If we placed 'var x' into the function locals and 'let x' into the locals of - // the block, then there would be no collision. - // - // By not creating a new block-scoped-container here, we ensure that both 'var x' - // and 'let x' go into the Function-container's locals, and we do get a collision - // conflict. - return ts.isFunctionLike(node.parent) ? 0 /* None */ : 2 /* IsBlockScopedContainer */; - } - return 0 /* None */; - } - function addToContainerChain(next) { - if (lastContainer) { - lastContainer.nextContainer = next; - } - lastContainer = next; - } - function declareSymbolAndAddToSymbolTable(node, symbolFlags, symbolExcludes) { - // Just call this directly so that the return type of this function stays "void". - declareSymbolAndAddToSymbolTableWorker(node, symbolFlags, symbolExcludes); - } - function declareSymbolAndAddToSymbolTableWorker(node, symbolFlags, symbolExcludes) { - switch (container.kind) { - // Modules, source files, and classes need specialized handling for how their - // members are declared (for example, a member of a class will go into a specific - // symbol table depending on if it is static or not). We defer to specialized - // handlers to take care of declaring these child members. - case 208 /* ModuleDeclaration */: - return declareModuleMember(node, symbolFlags, symbolExcludes); - case 230 /* SourceFile */: - return declareSourceFileMember(node, symbolFlags, symbolExcludes); - case 177 /* ClassExpression */: - case 204 /* ClassDeclaration */: - return declareClassMember(node, symbolFlags, symbolExcludes); - case 207 /* EnumDeclaration */: - return declareSymbol(container.symbol.exports, container.symbol, node, symbolFlags, symbolExcludes); - case 148 /* TypeLiteral */: - case 157 /* ObjectLiteralExpression */: - case 205 /* InterfaceDeclaration */: - // Interface/Object-types always have their children added to the 'members' of - // their container. They are only accessible through an instance of their - // container, and are never in scope otherwise (even inside the body of the - // object / type / interface declaring them). An exception is type parameters, - // which are in scope without qualification (similar to 'locals'). - return declareSymbol(container.symbol.members, container.symbol, node, symbolFlags, symbolExcludes); - case 145 /* FunctionType */: - case 146 /* ConstructorType */: - case 140 /* CallSignature */: - case 141 /* ConstructSignature */: - case 142 /* IndexSignature */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 137 /* Constructor */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 203 /* FunctionDeclaration */: - case 165 /* FunctionExpression */: - case 166 /* ArrowFunction */: - case 206 /* TypeAliasDeclaration */: - // All the children of these container types are never visible through another - // symbol (i.e. through another symbol's 'exports' or 'members'). Instead, - // they're only accessed 'lexically' (i.e. from code that exists underneath - // their container in the tree. To accomplish this, we simply add their declared - // symbol to the 'locals' of the container. These symbols can then be found as - // the type checker walks up the containers, checking them for matching names. - return declareSymbol(container.locals, undefined, node, symbolFlags, symbolExcludes); - } - } - function declareClassMember(node, symbolFlags, symbolExcludes) { - return node.flags & 128 /* Static */ - ? declareSymbol(container.symbol.exports, container.symbol, node, symbolFlags, symbolExcludes) - : declareSymbol(container.symbol.members, container.symbol, node, symbolFlags, symbolExcludes); - } - function declareSourceFileMember(node, symbolFlags, symbolExcludes) { - return ts.isExternalModule(file) - ? declareModuleMember(node, symbolFlags, symbolExcludes) - : declareSymbol(file.locals, undefined, node, symbolFlags, symbolExcludes); - } - function isAmbientContext(node) { - while (node) { - if (node.flags & 2 /* Ambient */) { - return true; - } - node = node.parent; - } - return false; - } - function hasExportDeclarations(node) { - var body = node.kind === 230 /* SourceFile */ ? node : node.body; - if (body.kind === 230 /* SourceFile */ || body.kind === 209 /* ModuleBlock */) { - for (var _i = 0, _a = body.statements; _i < _a.length; _i++) { - var stat = _a[_i]; - if (stat.kind === 218 /* ExportDeclaration */ || stat.kind === 217 /* ExportAssignment */) { - return true; - } - } - } - return false; - } - function setExportContextFlag(node) { - // A declaration source file or ambient module declaration that contains no export declarations (but possibly regular - // declarations with export modifiers) is an export context in which declarations are implicitly exported. - if (isAmbientContext(node) && !hasExportDeclarations(node)) { - node.flags |= 65536 /* ExportContext */; - } - else { - node.flags &= ~65536 /* ExportContext */; - } - } - function bindModuleDeclaration(node) { - setExportContextFlag(node); - if (node.name.kind === 8 /* StringLiteral */) { - declareSymbolAndAddToSymbolTable(node, 512 /* ValueModule */, 106639 /* ValueModuleExcludes */); - } - else { - var state = getModuleInstanceState(node); - if (state === 0 /* NonInstantiated */) { - declareSymbolAndAddToSymbolTable(node, 1024 /* NamespaceModule */, 0 /* NamespaceModuleExcludes */); - } - else { - declareSymbolAndAddToSymbolTable(node, 512 /* ValueModule */, 106639 /* ValueModuleExcludes */); - var currentModuleIsConstEnumOnly = state === 2 /* ConstEnumOnly */; - if (node.symbol.constEnumOnlyModule === undefined) { - // non-merged case - use the current state - node.symbol.constEnumOnlyModule = currentModuleIsConstEnumOnly; - } - else { - // merged case: module is const enum only if all its pieces are non-instantiated or const enum - node.symbol.constEnumOnlyModule = node.symbol.constEnumOnlyModule && currentModuleIsConstEnumOnly; - } - } - } - } - function bindFunctionOrConstructorType(node) { - // For a given function symbol "<...>(...) => T" we want to generate a symbol identical - // to the one we would get for: { <...>(...): T } - // - // We do that by making an anonymous type literal symbol, and then setting the function - // symbol as its sole member. To the rest of the system, this symbol will be indistinguishable - // from an actual type literal symbol you would have gotten had you used the long form. - var symbol = createSymbol(131072 /* Signature */, getDeclarationName(node)); - addDeclarationToSymbol(symbol, node, 131072 /* Signature */); - var typeLiteralSymbol = createSymbol(2048 /* TypeLiteral */, "__type"); - addDeclarationToSymbol(typeLiteralSymbol, node, 2048 /* TypeLiteral */); - typeLiteralSymbol.members = (_a = {}, _a[symbol.name] = symbol, _a); - var _a; - } - function bindAnonymousDeclaration(node, symbolFlags, name) { - var symbol = createSymbol(symbolFlags, name); - addDeclarationToSymbol(symbol, node, symbolFlags); - } - function bindBlockScopedDeclaration(node, symbolFlags, symbolExcludes) { - switch (blockScopeContainer.kind) { - case 208 /* ModuleDeclaration */: - declareModuleMember(node, symbolFlags, symbolExcludes); - break; - case 230 /* SourceFile */: - if (ts.isExternalModule(container)) { - declareModuleMember(node, symbolFlags, symbolExcludes); - break; - } - // fall through. - default: - if (!blockScopeContainer.locals) { - blockScopeContainer.locals = {}; - addToContainerChain(blockScopeContainer); - } - declareSymbol(blockScopeContainer.locals, undefined, node, symbolFlags, symbolExcludes); - } - } - function bindBlockScopedVariableDeclaration(node) { - bindBlockScopedDeclaration(node, 2 /* BlockScopedVariable */, 107455 /* BlockScopedVariableExcludes */); - } - function getDestructuringParameterName(node) { - return "__" + ts.indexOf(node.parent.parameters, node); - } - function bind(node) { - node.parent = parent; - // First we bind declaration nodes to a symbol if possible. We'll both create a symbol - // and then potentially add the symbol to an appropriate symbol table. Possible - // destination symbol tables are: - // - // 1) The 'exports' table of the current container's symbol. - // 2) The 'members' table of the current container's symbol. - // 3) The 'locals' table of the current container. - // - // However, not all symbols will end up in any of these tables. 'Anonymous' symbols - // (like TypeLiterals for example) will not be put in any table. - bindWorker(node); - // Then we recurse into the children of the node to bind them as well. For certain - // symbols we do specialized work when we recurse. For example, we'll keep track of - // the current 'container' node when it changes. This helps us know which symbol table - // a local should go into for example. - bindChildren(node); - } - function bindWorker(node) { - switch (node.kind) { - case 130 /* TypeParameter */: - return declareSymbolAndAddToSymbolTable(node, 262144 /* TypeParameter */, 530912 /* TypeParameterExcludes */); - case 131 /* Parameter */: - return bindParameter(node); - case 201 /* VariableDeclaration */: - case 155 /* BindingElement */: - return bindVariableDeclarationOrBindingElement(node); - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - return bindPropertyOrMethodOrAccessor(node, 4 /* Property */ | (node.questionToken ? 536870912 /* Optional */ : 0 /* None */), 107455 /* PropertyExcludes */); - case 227 /* PropertyAssignment */: - case 228 /* ShorthandPropertyAssignment */: - return bindPropertyOrMethodOrAccessor(node, 4 /* Property */, 107455 /* PropertyExcludes */); - case 229 /* EnumMember */: - return bindPropertyOrMethodOrAccessor(node, 8 /* EnumMember */, 107455 /* EnumMemberExcludes */); - case 140 /* CallSignature */: - case 141 /* ConstructSignature */: - case 142 /* IndexSignature */: - return declareSymbolAndAddToSymbolTable(node, 131072 /* Signature */, 0 /* None */); - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - // If this is an ObjectLiteralExpression method, then it sits in the same space - // as other properties in the object literal. So we use SymbolFlags.PropertyExcludes - // so that it will conflict with any other object literal members with the same - // name. - return bindPropertyOrMethodOrAccessor(node, 8192 /* Method */ | (node.questionToken ? 536870912 /* Optional */ : 0 /* None */), ts.isObjectLiteralMethod(node) ? 107455 /* PropertyExcludes */ : 99263 /* MethodExcludes */); - case 203 /* FunctionDeclaration */: - return declareSymbolAndAddToSymbolTable(node, 16 /* Function */, 106927 /* FunctionExcludes */); - case 137 /* Constructor */: - return declareSymbolAndAddToSymbolTable(node, 16384 /* Constructor */, 0 /* None */); - case 138 /* GetAccessor */: - return bindPropertyOrMethodOrAccessor(node, 32768 /* GetAccessor */, 41919 /* GetAccessorExcludes */); - case 139 /* SetAccessor */: - return bindPropertyOrMethodOrAccessor(node, 65536 /* SetAccessor */, 74687 /* SetAccessorExcludes */); - case 145 /* FunctionType */: - case 146 /* ConstructorType */: - return bindFunctionOrConstructorType(node); - case 148 /* TypeLiteral */: - return bindAnonymousDeclaration(node, 2048 /* TypeLiteral */, "__type"); - case 157 /* ObjectLiteralExpression */: - return bindAnonymousDeclaration(node, 4096 /* ObjectLiteral */, "__object"); - case 165 /* FunctionExpression */: - case 166 /* ArrowFunction */: - return bindAnonymousDeclaration(node, 16 /* Function */, "__function"); - case 177 /* ClassExpression */: - case 204 /* ClassDeclaration */: - return bindClassLikeDeclaration(node); - case 205 /* InterfaceDeclaration */: - return bindBlockScopedDeclaration(node, 64 /* Interface */, 792992 /* InterfaceExcludes */); - case 206 /* TypeAliasDeclaration */: - return bindBlockScopedDeclaration(node, 524288 /* TypeAlias */, 793056 /* TypeAliasExcludes */); - case 207 /* EnumDeclaration */: - return bindEnumDeclaration(node); - case 208 /* ModuleDeclaration */: - return bindModuleDeclaration(node); - case 211 /* ImportEqualsDeclaration */: - case 214 /* NamespaceImport */: - case 216 /* ImportSpecifier */: - case 220 /* ExportSpecifier */: - return declareSymbolAndAddToSymbolTable(node, 8388608 /* Alias */, 8388608 /* AliasExcludes */); - case 213 /* ImportClause */: - return bindImportClause(node); - case 218 /* ExportDeclaration */: - return bindExportDeclaration(node); - case 217 /* ExportAssignment */: - return bindExportAssignment(node); - case 230 /* SourceFile */: - return bindSourceFileIfExternalModule(); - } - } - function bindSourceFileIfExternalModule() { - setExportContextFlag(file); - if (ts.isExternalModule(file)) { - bindAnonymousDeclaration(file, 512 /* ValueModule */, '"' + ts.removeFileExtension(file.fileName) + '"'); - } - } - function bindExportAssignment(node) { - if (!container.symbol || !container.symbol.exports) { - // Export assignment in some sort of block construct - bindAnonymousDeclaration(node, 8388608 /* Alias */, getDeclarationName(node)); - } - else if (node.expression.kind === 65 /* Identifier */) { - // An export default clause with an identifier exports all meanings of that identifier - declareSymbol(container.symbol.exports, container.symbol, node, 8388608 /* Alias */, 107455 /* PropertyExcludes */ | 8388608 /* AliasExcludes */); - } - else { - // An export default clause with an expression exports a value - declareSymbol(container.symbol.exports, container.symbol, node, 4 /* Property */, 107455 /* PropertyExcludes */ | 8388608 /* AliasExcludes */); - } - } - function bindExportDeclaration(node) { - if (!container.symbol || !container.symbol.exports) { - // Export * in some sort of block construct - bindAnonymousDeclaration(node, 1073741824 /* ExportStar */, getDeclarationName(node)); - } - else if (!node.exportClause) { - // All export * declarations are collected in an __export symbol - declareSymbol(container.symbol.exports, container.symbol, node, 1073741824 /* ExportStar */, 0 /* None */); - } - } - function bindImportClause(node) { - if (node.name) { - declareSymbolAndAddToSymbolTable(node, 8388608 /* Alias */, 8388608 /* AliasExcludes */); - } - } - function bindClassLikeDeclaration(node) { - if (node.kind === 204 /* ClassDeclaration */) { - bindBlockScopedDeclaration(node, 32 /* Class */, 899583 /* ClassExcludes */); - } - else { - bindAnonymousDeclaration(node, 32 /* Class */, "__class"); - } - var symbol = node.symbol; - // TypeScript 1.0 spec (April 2014): 8.4 - // Every class automatically contains a static property member named 'prototype', the - // type of which is an instantiation of the class type with type Any supplied as a type - // argument for each type parameter. It is an error to explicitly declare a static - // property member with the name 'prototype'. - // - // Note: we check for this here because this class may be merging into a module. The - // module might have an exported variable called 'prototype'. We can't allow that as - // that would clash with the built-in 'prototype' for the class. - var prototypeSymbol = createSymbol(4 /* Property */ | 134217728 /* Prototype */, "prototype"); - if (ts.hasProperty(symbol.exports, prototypeSymbol.name)) { - if (node.name) { - node.name.parent = node; - } - file.bindDiagnostics.push(ts.createDiagnosticForNode(symbol.exports[prototypeSymbol.name].declarations[0], ts.Diagnostics.Duplicate_identifier_0, prototypeSymbol.name)); - } - symbol.exports[prototypeSymbol.name] = prototypeSymbol; - prototypeSymbol.parent = symbol; - } - function bindEnumDeclaration(node) { - return ts.isConst(node) - ? bindBlockScopedDeclaration(node, 128 /* ConstEnum */, 899967 /* ConstEnumExcludes */) - : bindBlockScopedDeclaration(node, 256 /* RegularEnum */, 899327 /* RegularEnumExcludes */); - } - function bindVariableDeclarationOrBindingElement(node) { - if (!ts.isBindingPattern(node.name)) { - if (ts.isBlockOrCatchScoped(node)) { - bindBlockScopedVariableDeclaration(node); - } - else if (ts.isParameterDeclaration(node)) { - // It is safe to walk up parent chain to find whether the node is a destructing parameter declaration - // because its parent chain has already been set up, since parents are set before descending into children. - // - // If node is a binding element in parameter declaration, we need to use ParameterExcludes. - // Using ParameterExcludes flag allows the compiler to report an error on duplicate identifiers in Parameter Declaration - // For example: - // function foo([a,a]) {} // Duplicate Identifier error - // function bar(a,a) {} // Duplicate Identifier error, parameter declaration in this case is handled in bindParameter - // // which correctly set excluded symbols - declareSymbolAndAddToSymbolTable(node, 1 /* FunctionScopedVariable */, 107455 /* ParameterExcludes */); - } - else { - declareSymbolAndAddToSymbolTable(node, 1 /* FunctionScopedVariable */, 107454 /* FunctionScopedVariableExcludes */); - } - } - } - function bindParameter(node) { - if (ts.isBindingPattern(node.name)) { - bindAnonymousDeclaration(node, 1 /* FunctionScopedVariable */, getDestructuringParameterName(node)); - } - else { - declareSymbolAndAddToSymbolTable(node, 1 /* FunctionScopedVariable */, 107455 /* ParameterExcludes */); - } - // If this is a property-parameter, then also declare the property symbol into the - // containing class. - if (node.flags & 112 /* AccessibilityModifier */ && - node.parent.kind === 137 /* Constructor */ && - (node.parent.parent.kind === 204 /* ClassDeclaration */ || node.parent.parent.kind === 177 /* ClassExpression */)) { - var classDeclaration = node.parent.parent; - declareSymbol(classDeclaration.symbol.members, classDeclaration.symbol, node, 4 /* Property */, 107455 /* PropertyExcludes */); - } - } - function bindPropertyOrMethodOrAccessor(node, symbolFlags, symbolExcludes) { - return ts.hasDynamicName(node) - ? bindAnonymousDeclaration(node, symbolFlags, "__computed") - : declareSymbolAndAddToSymbolTable(node, symbolFlags, symbolExcludes); - } - } -})(ts || (ts = {})); -/// -/* @internal */ -var ts; -(function (ts) { - function getDeclarationOfKind(symbol, kind) { - var declarations = symbol.declarations; - for (var _i = 0; _i < declarations.length; _i++) { - var declaration = declarations[_i]; - if (declaration.kind === kind) { - return declaration; - } - } - return undefined; - } - ts.getDeclarationOfKind = getDeclarationOfKind; - // Pool writers to avoid needing to allocate them for every symbol we write. - var stringWriters = []; - function getSingleLineStringWriter() { - if (stringWriters.length == 0) { - var str = ""; - var writeText = function (text) { return str += text; }; - return { - string: function () { return str; }, - writeKeyword: writeText, - writeOperator: writeText, - writePunctuation: writeText, - writeSpace: writeText, - writeStringLiteral: writeText, - writeParameter: writeText, - writeSymbol: writeText, - // Completely ignore indentation for string writers. And map newlines to - // a single space. - writeLine: function () { return str += " "; }, - increaseIndent: function () { }, - decreaseIndent: function () { }, - clear: function () { return str = ""; }, - trackSymbol: function () { } - }; - } - return stringWriters.pop(); - } - ts.getSingleLineStringWriter = getSingleLineStringWriter; - function releaseStringWriter(writer) { - writer.clear(); - stringWriters.push(writer); - } - ts.releaseStringWriter = releaseStringWriter; - function getFullWidth(node) { - return node.end - node.pos; - } - ts.getFullWidth = getFullWidth; - // Returns true if this node contains a parse error anywhere underneath it. - function containsParseError(node) { - aggregateChildData(node); - return (node.parserContextFlags & 128 /* ThisNodeOrAnySubNodesHasError */) !== 0; - } - ts.containsParseError = containsParseError; - function aggregateChildData(node) { - if (!(node.parserContextFlags & 256 /* HasAggregatedChildData */)) { - // A node is considered to contain a parse error if: - // a) the parser explicitly marked that it had an error - // b) any of it's children reported that it had an error. - var thisNodeOrAnySubNodesHasError = ((node.parserContextFlags & 32 /* ThisNodeHasError */) !== 0) || - ts.forEachChild(node, containsParseError); - // If so, mark ourselves accordingly. - if (thisNodeOrAnySubNodesHasError) { - node.parserContextFlags |= 128 /* ThisNodeOrAnySubNodesHasError */; - } - // Also mark that we've propogated the child information to this node. This way we can - // always consult the bit directly on this node without needing to check its children - // again. - node.parserContextFlags |= 256 /* HasAggregatedChildData */; - } - } - function getSourceFileOfNode(node) { - while (node && node.kind !== 230 /* SourceFile */) { - node = node.parent; - } - return node; - } - ts.getSourceFileOfNode = getSourceFileOfNode; - function getStartPositionOfLine(line, sourceFile) { - ts.Debug.assert(line >= 0); - return ts.getLineStarts(sourceFile)[line]; - } - ts.getStartPositionOfLine = getStartPositionOfLine; - // This is a useful function for debugging purposes. - function nodePosToString(node) { - var file = getSourceFileOfNode(node); - var loc = ts.getLineAndCharacterOfPosition(file, node.pos); - return file.fileName + "(" + (loc.line + 1) + "," + (loc.character + 1) + ")"; - } - ts.nodePosToString = nodePosToString; - function getStartPosOfNode(node) { - return node.pos; - } - ts.getStartPosOfNode = getStartPosOfNode; - // Returns true if this node is missing from the actual source code. 'missing' is different - // from 'undefined/defined'. When a node is undefined (which can happen for optional nodes - // in the tree), it is definitel missing. HOwever, a node may be defined, but still be - // missing. This happens whenever the parser knows it needs to parse something, but can't - // get anything in the source code that it expects at that location. For example: - // - // let a: ; - // - // Here, the Type in the Type-Annotation is not-optional (as there is a colon in the source - // code). So the parser will attempt to parse out a type, and will create an actual node. - // However, this node will be 'missing' in the sense that no actual source-code/tokens are - // contained within it. - function nodeIsMissing(node) { - if (!node) { - return true; - } - return node.pos === node.end && node.kind !== 1 /* EndOfFileToken */; - } - ts.nodeIsMissing = nodeIsMissing; - function nodeIsPresent(node) { - return !nodeIsMissing(node); - } - ts.nodeIsPresent = nodeIsPresent; - function getTokenPosOfNode(node, sourceFile) { - // With nodes that have no width (i.e. 'Missing' nodes), we actually *don't* - // want to skip trivia because this will launch us forward to the next token. - if (nodeIsMissing(node)) { - return node.pos; - } - return ts.skipTrivia((sourceFile || getSourceFileOfNode(node)).text, node.pos); - } - ts.getTokenPosOfNode = getTokenPosOfNode; - function getNonDecoratorTokenPosOfNode(node, sourceFile) { - if (nodeIsMissing(node) || !node.decorators) { - return getTokenPosOfNode(node, sourceFile); - } - return ts.skipTrivia((sourceFile || getSourceFileOfNode(node)).text, node.decorators.end); - } - ts.getNonDecoratorTokenPosOfNode = getNonDecoratorTokenPosOfNode; - function getSourceTextOfNodeFromSourceFile(sourceFile, node) { - if (nodeIsMissing(node)) { - return ""; - } - var text = sourceFile.text; - return text.substring(ts.skipTrivia(text, node.pos), node.end); - } - ts.getSourceTextOfNodeFromSourceFile = getSourceTextOfNodeFromSourceFile; - function getTextOfNodeFromSourceText(sourceText, node) { - if (nodeIsMissing(node)) { - return ""; - } - return sourceText.substring(ts.skipTrivia(sourceText, node.pos), node.end); - } - ts.getTextOfNodeFromSourceText = getTextOfNodeFromSourceText; - function getTextOfNode(node) { - return getSourceTextOfNodeFromSourceFile(getSourceFileOfNode(node), node); - } - ts.getTextOfNode = getTextOfNode; - // Add an extra underscore to identifiers that start with two underscores to avoid issues with magic names like '__proto__' - function escapeIdentifier(identifier) { - return identifier.length >= 2 && identifier.charCodeAt(0) === 95 /* _ */ && identifier.charCodeAt(1) === 95 /* _ */ ? "_" + identifier : identifier; - } - ts.escapeIdentifier = escapeIdentifier; - // Remove extra underscore from escaped identifier - function unescapeIdentifier(identifier) { - return identifier.length >= 3 && identifier.charCodeAt(0) === 95 /* _ */ && identifier.charCodeAt(1) === 95 /* _ */ && identifier.charCodeAt(2) === 95 /* _ */ ? identifier.substr(1) : identifier; - } - ts.unescapeIdentifier = unescapeIdentifier; - // Make an identifier from an external module name by extracting the string after the last "/" and replacing - // all non-alphanumeric characters with underscores - function makeIdentifierFromModuleName(moduleName) { - return ts.getBaseFileName(moduleName).replace(/\W/g, "_"); - } - ts.makeIdentifierFromModuleName = makeIdentifierFromModuleName; - function isBlockOrCatchScoped(declaration) { - return (getCombinedNodeFlags(declaration) & 12288 /* BlockScoped */) !== 0 || - isCatchClauseVariableDeclaration(declaration); - } - ts.isBlockOrCatchScoped = isBlockOrCatchScoped; - // Gets the nearest enclosing block scope container that has the provided node - // as a descendant, that is not the provided node. - function getEnclosingBlockScopeContainer(node) { - var current = node.parent; - while (current) { - if (isFunctionLike(current)) { - return current; - } - switch (current.kind) { - case 230 /* SourceFile */: - case 210 /* CaseBlock */: - case 226 /* CatchClause */: - case 208 /* ModuleDeclaration */: - case 189 /* ForStatement */: - case 190 /* ForInStatement */: - case 191 /* ForOfStatement */: - return current; - case 182 /* Block */: - // function block is not considered block-scope container - // see comment in binder.ts: bind(...), case for SyntaxKind.Block - if (!isFunctionLike(current.parent)) { - return current; - } - } - current = current.parent; - } - } - ts.getEnclosingBlockScopeContainer = getEnclosingBlockScopeContainer; - function isCatchClauseVariableDeclaration(declaration) { - return declaration && - declaration.kind === 201 /* VariableDeclaration */ && - declaration.parent && - declaration.parent.kind === 226 /* CatchClause */; - } - ts.isCatchClauseVariableDeclaration = isCatchClauseVariableDeclaration; - // Return display name of an identifier - // Computed property names will just be emitted as "[]", where is the source - // text of the expression in the computed property. - function declarationNameToString(name) { - return getFullWidth(name) === 0 ? "(Missing)" : getTextOfNode(name); - } - ts.declarationNameToString = declarationNameToString; - function createDiagnosticForNode(node, message, arg0, arg1, arg2) { - var sourceFile = getSourceFileOfNode(node); - var span = getErrorSpanForNode(sourceFile, node); - return ts.createFileDiagnostic(sourceFile, span.start, span.length, message, arg0, arg1, arg2); - } - ts.createDiagnosticForNode = createDiagnosticForNode; - function createDiagnosticForNodeFromMessageChain(node, messageChain) { - var sourceFile = getSourceFileOfNode(node); - var span = getErrorSpanForNode(sourceFile, node); - return { - file: sourceFile, - start: span.start, - length: span.length, - code: messageChain.code, - category: messageChain.category, - messageText: messageChain.next ? messageChain : messageChain.messageText - }; - } - ts.createDiagnosticForNodeFromMessageChain = createDiagnosticForNodeFromMessageChain; - function getSpanOfTokenAtPosition(sourceFile, pos) { - var scanner = ts.createScanner(sourceFile.languageVersion, true, sourceFile.text, undefined, pos); - scanner.scan(); - var start = scanner.getTokenPos(); - return ts.createTextSpanFromBounds(start, scanner.getTextPos()); - } - ts.getSpanOfTokenAtPosition = getSpanOfTokenAtPosition; - function getErrorSpanForNode(sourceFile, node) { - var errorNode = node; - switch (node.kind) { - case 230 /* SourceFile */: - var pos_1 = ts.skipTrivia(sourceFile.text, 0, false); - if (pos_1 === sourceFile.text.length) { - // file is empty - return span for the beginning of the file - return ts.createTextSpan(0, 0); - } - return getSpanOfTokenAtPosition(sourceFile, pos_1); - // This list is a work in progress. Add missing node kinds to improve their error - // spans. - case 201 /* VariableDeclaration */: - case 155 /* BindingElement */: - case 204 /* ClassDeclaration */: - case 177 /* ClassExpression */: - case 205 /* InterfaceDeclaration */: - case 208 /* ModuleDeclaration */: - case 207 /* EnumDeclaration */: - case 229 /* EnumMember */: - case 203 /* FunctionDeclaration */: - case 165 /* FunctionExpression */: - errorNode = node.name; - break; - } - if (errorNode === undefined) { - // If we don't have a better node, then just set the error on the first token of - // construct. - return getSpanOfTokenAtPosition(sourceFile, node.pos); - } - var pos = nodeIsMissing(errorNode) - ? errorNode.pos - : ts.skipTrivia(sourceFile.text, errorNode.pos); - return ts.createTextSpanFromBounds(pos, errorNode.end); - } - ts.getErrorSpanForNode = getErrorSpanForNode; - function isExternalModule(file) { - return file.externalModuleIndicator !== undefined; - } - ts.isExternalModule = isExternalModule; - function isDeclarationFile(file) { - return (file.flags & 2048 /* DeclarationFile */) !== 0; - } - ts.isDeclarationFile = isDeclarationFile; - function isConstEnumDeclaration(node) { - return node.kind === 207 /* EnumDeclaration */ && isConst(node); - } - ts.isConstEnumDeclaration = isConstEnumDeclaration; - function walkUpBindingElementsAndPatterns(node) { - while (node && (node.kind === 155 /* BindingElement */ || isBindingPattern(node))) { - node = node.parent; - } - return node; - } - // Returns the node flags for this node and all relevant parent nodes. This is done so that - // nodes like variable declarations and binding elements can returned a view of their flags - // that includes the modifiers from their container. i.e. flags like export/declare aren't - // stored on the variable declaration directly, but on the containing variable statement - // (if it has one). Similarly, flags for let/const are store on the variable declaration - // list. By calling this function, all those flags are combined so that the client can treat - // the node as if it actually had those flags. - function getCombinedNodeFlags(node) { - node = walkUpBindingElementsAndPatterns(node); - var flags = node.flags; - if (node.kind === 201 /* VariableDeclaration */) { - node = node.parent; - } - if (node && node.kind === 202 /* VariableDeclarationList */) { - flags |= node.flags; - node = node.parent; - } - if (node && node.kind === 183 /* VariableStatement */) { - flags |= node.flags; - } - return flags; - } - ts.getCombinedNodeFlags = getCombinedNodeFlags; - function isConst(node) { - return !!(getCombinedNodeFlags(node) & 8192 /* Const */); - } - ts.isConst = isConst; - function isLet(node) { - return !!(getCombinedNodeFlags(node) & 4096 /* Let */); - } - ts.isLet = isLet; - function isPrologueDirective(node) { - return node.kind === 185 /* ExpressionStatement */ && node.expression.kind === 8 /* StringLiteral */; - } - ts.isPrologueDirective = isPrologueDirective; - function getLeadingCommentRangesOfNode(node, sourceFileOfNode) { - // If parameter/type parameter, the prev token trailing comments are part of this node too - if (node.kind === 131 /* Parameter */ || node.kind === 130 /* TypeParameter */) { - // e.g. (/** blah */ a, /** blah */ b); - // e.g.: ( - // /** blah */ a, - // /** blah */ b); - return ts.concatenate(ts.getTrailingCommentRanges(sourceFileOfNode.text, node.pos), ts.getLeadingCommentRanges(sourceFileOfNode.text, node.pos)); - } - else { - return ts.getLeadingCommentRanges(sourceFileOfNode.text, node.pos); - } - } - ts.getLeadingCommentRangesOfNode = getLeadingCommentRangesOfNode; - function getJsDocComments(node, sourceFileOfNode) { - return ts.filter(getLeadingCommentRangesOfNode(node, sourceFileOfNode), isJsDocComment); - function isJsDocComment(comment) { - // True if the comment starts with '/**' but not if it is '/**/' - return sourceFileOfNode.text.charCodeAt(comment.pos + 1) === 42 /* asterisk */ && - sourceFileOfNode.text.charCodeAt(comment.pos + 2) === 42 /* asterisk */ && - sourceFileOfNode.text.charCodeAt(comment.pos + 3) !== 47 /* slash */; - } - } - ts.getJsDocComments = getJsDocComments; - ts.fullTripleSlashReferencePathRegEx = /^(\/\/\/\s*/; - function isTypeNode(node) { - if (144 /* FirstTypeNode */ <= node.kind && node.kind <= 152 /* LastTypeNode */) { - return true; - } - switch (node.kind) { - case 112 /* AnyKeyword */: - case 121 /* NumberKeyword */: - case 123 /* StringKeyword */: - case 113 /* BooleanKeyword */: - case 124 /* SymbolKeyword */: - return true; - case 99 /* VoidKeyword */: - return node.parent.kind !== 169 /* VoidExpression */; - case 8 /* StringLiteral */: - // Specialized signatures can have string literals as their parameters' type names - return node.parent.kind === 131 /* Parameter */; - case 179 /* ExpressionWithTypeArguments */: - return true; - // Identifiers and qualified names may be type nodes, depending on their context. Climb - // above them to find the lowest container - case 65 /* Identifier */: - // If the identifier is the RHS of a qualified name, then it's a type iff its parent is. - if (node.parent.kind === 128 /* QualifiedName */ && node.parent.right === node) { - node = node.parent; - } - else if (node.parent.kind === 158 /* PropertyAccessExpression */ && node.parent.name === node) { - node = node.parent; - } - // fall through - case 128 /* QualifiedName */: - case 158 /* PropertyAccessExpression */: - // At this point, node is either a qualified name or an identifier - ts.Debug.assert(node.kind === 65 /* Identifier */ || node.kind === 128 /* QualifiedName */ || node.kind === 158 /* PropertyAccessExpression */, "'node' was expected to be a qualified name, identifier or property access in 'isTypeNode'."); - var parent_1 = node.parent; - if (parent_1.kind === 147 /* TypeQuery */) { - return false; - } - // Do not recursively call isTypeNode on the parent. In the example: - // - // let a: A.B.C; - // - // Calling isTypeNode would consider the qualified name A.B a type node. Only C or - // A.B.C is a type node. - if (144 /* FirstTypeNode */ <= parent_1.kind && parent_1.kind <= 152 /* LastTypeNode */) { - return true; - } - switch (parent_1.kind) { - case 179 /* ExpressionWithTypeArguments */: - return true; - case 130 /* TypeParameter */: - return node === parent_1.constraint; - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - case 131 /* Parameter */: - case 201 /* VariableDeclaration */: - return node === parent_1.type; - case 203 /* FunctionDeclaration */: - case 165 /* FunctionExpression */: - case 166 /* ArrowFunction */: - case 137 /* Constructor */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - return node === parent_1.type; - case 140 /* CallSignature */: - case 141 /* ConstructSignature */: - case 142 /* IndexSignature */: - return node === parent_1.type; - case 163 /* TypeAssertionExpression */: - return node === parent_1.type; - case 160 /* CallExpression */: - case 161 /* NewExpression */: - return parent_1.typeArguments && ts.indexOf(parent_1.typeArguments, node) >= 0; - case 162 /* TaggedTemplateExpression */: - // TODO (drosen): TaggedTemplateExpressions may eventually support type arguments. - return false; - } - } - return false; - } - ts.isTypeNode = isTypeNode; - // Warning: This has the same semantics as the forEach family of functions, - // in that traversal terminates in the event that 'visitor' supplies a truthy value. - function forEachReturnStatement(body, visitor) { - return traverse(body); - function traverse(node) { - switch (node.kind) { - case 194 /* ReturnStatement */: - return visitor(node); - case 210 /* CaseBlock */: - case 182 /* Block */: - case 186 /* IfStatement */: - case 187 /* DoStatement */: - case 188 /* WhileStatement */: - case 189 /* ForStatement */: - case 190 /* ForInStatement */: - case 191 /* ForOfStatement */: - case 195 /* WithStatement */: - case 196 /* SwitchStatement */: - case 223 /* CaseClause */: - case 224 /* DefaultClause */: - case 197 /* LabeledStatement */: - case 199 /* TryStatement */: - case 226 /* CatchClause */: - return ts.forEachChild(node, traverse); - } - } - } - ts.forEachReturnStatement = forEachReturnStatement; - function forEachYieldExpression(body, visitor) { - return traverse(body); - function traverse(node) { - switch (node.kind) { - case 175 /* YieldExpression */: - visitor(node); - var operand = node.expression; - if (operand) { - traverse(operand); - } - case 207 /* EnumDeclaration */: - case 205 /* InterfaceDeclaration */: - case 208 /* ModuleDeclaration */: - case 206 /* TypeAliasDeclaration */: - case 204 /* ClassDeclaration */: - // These are not allowed inside a generator now, but eventually they may be allowed - // as local types. Regardless, any yield statements contained within them should be - // skipped in this traversal. - return; - default: - if (isFunctionLike(node)) { - var name_4 = node.name; - if (name_4 && name_4.kind === 129 /* ComputedPropertyName */) { - // Note that we will not include methods/accessors of a class because they would require - // first descending into the class. This is by design. - traverse(name_4.expression); - return; - } - } - else if (!isTypeNode(node)) { - // This is the general case, which should include mostly expressions and statements. - // Also includes NodeArrays. - ts.forEachChild(node, traverse); - } - } - } - } - ts.forEachYieldExpression = forEachYieldExpression; - function isVariableLike(node) { - if (node) { - switch (node.kind) { - case 155 /* BindingElement */: - case 229 /* EnumMember */: - case 131 /* Parameter */: - case 227 /* PropertyAssignment */: - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - case 228 /* ShorthandPropertyAssignment */: - case 201 /* VariableDeclaration */: - return true; - } - } - return false; - } - ts.isVariableLike = isVariableLike; - function isAccessor(node) { - if (node) { - switch (node.kind) { - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - return true; - } - } - return false; - } - ts.isAccessor = isAccessor; - function isClassLike(node) { - if (node) { - return node.kind === 204 /* ClassDeclaration */ || node.kind === 177 /* ClassExpression */; - } - } - ts.isClassLike = isClassLike; - function isFunctionLike(node) { - if (node) { - switch (node.kind) { - case 137 /* Constructor */: - case 165 /* FunctionExpression */: - case 203 /* FunctionDeclaration */: - case 166 /* ArrowFunction */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 140 /* CallSignature */: - case 141 /* ConstructSignature */: - case 142 /* IndexSignature */: - case 145 /* FunctionType */: - case 146 /* ConstructorType */: - return true; - } - } - return false; - } - ts.isFunctionLike = isFunctionLike; - function isFunctionBlock(node) { - return node && node.kind === 182 /* Block */ && isFunctionLike(node.parent); - } - ts.isFunctionBlock = isFunctionBlock; - function isObjectLiteralMethod(node) { - return node && node.kind === 136 /* MethodDeclaration */ && node.parent.kind === 157 /* ObjectLiteralExpression */; - } - ts.isObjectLiteralMethod = isObjectLiteralMethod; - function getContainingFunction(node) { - while (true) { - node = node.parent; - if (!node || isFunctionLike(node)) { - return node; - } - } - } - ts.getContainingFunction = getContainingFunction; - function getThisContainer(node, includeArrowFunctions) { - while (true) { - node = node.parent; - if (!node) { - return undefined; - } - switch (node.kind) { - case 129 /* ComputedPropertyName */: - // If the grandparent node is an object literal (as opposed to a class), - // then the computed property is not a 'this' container. - // A computed property name in a class needs to be a this container - // so that we can error on it. - if (node.parent.parent.kind === 204 /* ClassDeclaration */) { - return node; - } - // If this is a computed property, then the parent should not - // make it a this container. The parent might be a property - // in an object literal, like a method or accessor. But in order for - // such a parent to be a this container, the reference must be in - // the *body* of the container. - node = node.parent; - break; - case 132 /* Decorator */: - // Decorators are always applied outside of the body of a class or method. - if (node.parent.kind === 131 /* Parameter */ && isClassElement(node.parent.parent)) { - // If the decorator's parent is a Parameter, we resolve the this container from - // the grandparent class declaration. - node = node.parent.parent; - } - else if (isClassElement(node.parent)) { - // If the decorator's parent is a class element, we resolve the 'this' container - // from the parent class declaration. - node = node.parent; - } - break; - case 166 /* ArrowFunction */: - if (!includeArrowFunctions) { - continue; - } - // Fall through - case 203 /* FunctionDeclaration */: - case 165 /* FunctionExpression */: - case 208 /* ModuleDeclaration */: - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 137 /* Constructor */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 207 /* EnumDeclaration */: - case 230 /* SourceFile */: - return node; - } - } - } - ts.getThisContainer = getThisContainer; - function getSuperContainer(node, includeFunctions) { - while (true) { - node = node.parent; - if (!node) - return node; - switch (node.kind) { - case 129 /* ComputedPropertyName */: - // If the grandparent node is an object literal (as opposed to a class), - // then the computed property is not a 'super' container. - // A computed property name in a class needs to be a super container - // so that we can error on it. - if (node.parent.parent.kind === 204 /* ClassDeclaration */) { - return node; - } - // If this is a computed property, then the parent should not - // make it a super container. The parent might be a property - // in an object literal, like a method or accessor. But in order for - // such a parent to be a super container, the reference must be in - // the *body* of the container. - node = node.parent; - break; - case 132 /* Decorator */: - // Decorators are always applied outside of the body of a class or method. - if (node.parent.kind === 131 /* Parameter */ && isClassElement(node.parent.parent)) { - // If the decorator's parent is a Parameter, we resolve the this container from - // the grandparent class declaration. - node = node.parent.parent; - } - else if (isClassElement(node.parent)) { - // If the decorator's parent is a class element, we resolve the 'this' container - // from the parent class declaration. - node = node.parent; - } - break; - case 203 /* FunctionDeclaration */: - case 165 /* FunctionExpression */: - case 166 /* ArrowFunction */: - if (!includeFunctions) { - continue; - } - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 137 /* Constructor */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - return node; - } - } - } - ts.getSuperContainer = getSuperContainer; - function getInvokedExpression(node) { - if (node.kind === 162 /* TaggedTemplateExpression */) { - return node.tag; - } - // Will either be a CallExpression or NewExpression. - return node.expression; - } - ts.getInvokedExpression = getInvokedExpression; - function nodeCanBeDecorated(node) { - switch (node.kind) { - case 204 /* ClassDeclaration */: - // classes are valid targets - return true; - case 134 /* PropertyDeclaration */: - // property declarations are valid if their parent is a class declaration. - return node.parent.kind === 204 /* ClassDeclaration */; - case 131 /* Parameter */: - // if the parameter's parent has a body and its grandparent is a class declaration, this is a valid target; - return node.parent.body && node.parent.parent.kind === 204 /* ClassDeclaration */; - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 136 /* MethodDeclaration */: - // if this method has a body and its parent is a class declaration, this is a valid target. - return node.body && node.parent.kind === 204 /* ClassDeclaration */; - } - return false; - } - ts.nodeCanBeDecorated = nodeCanBeDecorated; - function nodeIsDecorated(node) { - switch (node.kind) { - case 204 /* ClassDeclaration */: - if (node.decorators) { - return true; - } - return false; - case 134 /* PropertyDeclaration */: - case 131 /* Parameter */: - if (node.decorators) { - return true; - } - return false; - case 138 /* GetAccessor */: - if (node.body && node.decorators) { - return true; - } - return false; - case 136 /* MethodDeclaration */: - case 139 /* SetAccessor */: - if (node.body && node.decorators) { - return true; - } - return false; - } - return false; - } - ts.nodeIsDecorated = nodeIsDecorated; - function childIsDecorated(node) { - switch (node.kind) { - case 204 /* ClassDeclaration */: - return ts.forEach(node.members, nodeOrChildIsDecorated); - case 136 /* MethodDeclaration */: - case 139 /* SetAccessor */: - return ts.forEach(node.parameters, nodeIsDecorated); - } - return false; - } - ts.childIsDecorated = childIsDecorated; - function nodeOrChildIsDecorated(node) { - return nodeIsDecorated(node) || childIsDecorated(node); - } - ts.nodeOrChildIsDecorated = nodeOrChildIsDecorated; - function isExpression(node) { - switch (node.kind) { - case 93 /* ThisKeyword */: - case 91 /* SuperKeyword */: - case 89 /* NullKeyword */: - case 95 /* TrueKeyword */: - case 80 /* FalseKeyword */: - case 9 /* RegularExpressionLiteral */: - case 156 /* ArrayLiteralExpression */: - case 157 /* ObjectLiteralExpression */: - case 158 /* PropertyAccessExpression */: - case 159 /* ElementAccessExpression */: - case 160 /* CallExpression */: - case 161 /* NewExpression */: - case 162 /* TaggedTemplateExpression */: - case 163 /* TypeAssertionExpression */: - case 164 /* ParenthesizedExpression */: - case 165 /* FunctionExpression */: - case 177 /* ClassExpression */: - case 166 /* ArrowFunction */: - case 169 /* VoidExpression */: - case 167 /* DeleteExpression */: - case 168 /* TypeOfExpression */: - case 170 /* PrefixUnaryExpression */: - case 171 /* PostfixUnaryExpression */: - case 172 /* BinaryExpression */: - case 173 /* ConditionalExpression */: - case 176 /* SpreadElementExpression */: - case 174 /* TemplateExpression */: - case 10 /* NoSubstitutionTemplateLiteral */: - case 178 /* OmittedExpression */: - case 175 /* YieldExpression */: - return true; - case 128 /* QualifiedName */: - while (node.parent.kind === 128 /* QualifiedName */) { - node = node.parent; - } - return node.parent.kind === 147 /* TypeQuery */; - case 65 /* Identifier */: - if (node.parent.kind === 147 /* TypeQuery */) { - return true; - } - // fall through - case 7 /* NumericLiteral */: - case 8 /* StringLiteral */: - var parent_2 = node.parent; - switch (parent_2.kind) { - case 201 /* VariableDeclaration */: - case 131 /* Parameter */: - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - case 229 /* EnumMember */: - case 227 /* PropertyAssignment */: - case 155 /* BindingElement */: - return parent_2.initializer === node; - case 185 /* ExpressionStatement */: - case 186 /* IfStatement */: - case 187 /* DoStatement */: - case 188 /* WhileStatement */: - case 194 /* ReturnStatement */: - case 195 /* WithStatement */: - case 196 /* SwitchStatement */: - case 223 /* CaseClause */: - case 198 /* ThrowStatement */: - case 196 /* SwitchStatement */: - return parent_2.expression === node; - case 189 /* ForStatement */: - var forStatement = parent_2; - return (forStatement.initializer === node && forStatement.initializer.kind !== 202 /* VariableDeclarationList */) || - forStatement.condition === node || - forStatement.incrementor === node; - case 190 /* ForInStatement */: - case 191 /* ForOfStatement */: - var forInStatement = parent_2; - return (forInStatement.initializer === node && forInStatement.initializer.kind !== 202 /* VariableDeclarationList */) || - forInStatement.expression === node; - case 163 /* TypeAssertionExpression */: - return node === parent_2.expression; - case 180 /* TemplateSpan */: - return node === parent_2.expression; - case 129 /* ComputedPropertyName */: - return node === parent_2.expression; - case 132 /* Decorator */: - return true; - default: - if (isExpression(parent_2)) { - return true; - } - } - } - return false; - } - ts.isExpression = isExpression; - function isInstantiatedModule(node, preserveConstEnums) { - var moduleState = ts.getModuleInstanceState(node); - return moduleState === 1 /* Instantiated */ || - (preserveConstEnums && moduleState === 2 /* ConstEnumOnly */); - } - ts.isInstantiatedModule = isInstantiatedModule; - function isExternalModuleImportEqualsDeclaration(node) { - return node.kind === 211 /* ImportEqualsDeclaration */ && node.moduleReference.kind === 222 /* ExternalModuleReference */; - } - ts.isExternalModuleImportEqualsDeclaration = isExternalModuleImportEqualsDeclaration; - function getExternalModuleImportEqualsDeclarationExpression(node) { - ts.Debug.assert(isExternalModuleImportEqualsDeclaration(node)); - return node.moduleReference.expression; - } - ts.getExternalModuleImportEqualsDeclarationExpression = getExternalModuleImportEqualsDeclarationExpression; - function isInternalModuleImportEqualsDeclaration(node) { - return node.kind === 211 /* ImportEqualsDeclaration */ && node.moduleReference.kind !== 222 /* ExternalModuleReference */; - } - ts.isInternalModuleImportEqualsDeclaration = isInternalModuleImportEqualsDeclaration; - function getExternalModuleName(node) { - if (node.kind === 212 /* ImportDeclaration */) { - return node.moduleSpecifier; - } - if (node.kind === 211 /* ImportEqualsDeclaration */) { - var reference = node.moduleReference; - if (reference.kind === 222 /* ExternalModuleReference */) { - return reference.expression; - } - } - if (node.kind === 218 /* ExportDeclaration */) { - return node.moduleSpecifier; - } - } - ts.getExternalModuleName = getExternalModuleName; - function hasQuestionToken(node) { - if (node) { - switch (node.kind) { - case 131 /* Parameter */: - return node.questionToken !== undefined; - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - return node.questionToken !== undefined; - case 228 /* ShorthandPropertyAssignment */: - case 227 /* PropertyAssignment */: - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - return node.questionToken !== undefined; - } - } - return false; - } - ts.hasQuestionToken = hasQuestionToken; - function isJSDocConstructSignature(node) { - return node.kind === 243 /* JSDocFunctionType */ && - node.parameters.length > 0 && - node.parameters[0].type.kind === 245 /* JSDocConstructorType */; - } - ts.isJSDocConstructSignature = isJSDocConstructSignature; - function getJSDocTag(node, kind) { - if (node && node.jsDocComment) { - for (var _i = 0, _a = node.jsDocComment.tags; _i < _a.length; _i++) { - var tag = _a[_i]; - if (tag.kind === kind) { - return tag; - } - } - } - } - function getJSDocTypeTag(node) { - return getJSDocTag(node, 251 /* JSDocTypeTag */); - } - ts.getJSDocTypeTag = getJSDocTypeTag; - function getJSDocReturnTag(node) { - return getJSDocTag(node, 250 /* JSDocReturnTag */); - } - ts.getJSDocReturnTag = getJSDocReturnTag; - function getJSDocTemplateTag(node) { - return getJSDocTag(node, 252 /* JSDocTemplateTag */); - } - ts.getJSDocTemplateTag = getJSDocTemplateTag; - function getCorrespondingJSDocParameterTag(parameter) { - if (parameter.name && parameter.name.kind === 65 /* Identifier */) { - // If it's a parameter, see if the parent has a jsdoc comment with an @param - // annotation. - var parameterName = parameter.name.text; - var docComment = parameter.parent.jsDocComment; - if (docComment) { - return ts.forEach(docComment.tags, function (t) { - if (t.kind === 249 /* JSDocParameterTag */) { - var parameterTag = t; - var name_5 = parameterTag.preParameterName || parameterTag.postParameterName; - if (name_5.text === parameterName) { - return t; - } - } - }); - } - } - } - ts.getCorrespondingJSDocParameterTag = getCorrespondingJSDocParameterTag; - function hasRestParameter(s) { - return isRestParameter(ts.lastOrUndefined(s.parameters)); - } - ts.hasRestParameter = hasRestParameter; - function isRestParameter(node) { - if (node) { - if (node.parserContextFlags & 64 /* JavaScriptFile */) { - if (node.type && node.type.kind === 244 /* JSDocVariadicType */) { - return true; - } - var paramTag = getCorrespondingJSDocParameterTag(node); - if (paramTag && paramTag.typeExpression) { - return paramTag.typeExpression.type.kind === 244 /* JSDocVariadicType */; - } - } - return node.dotDotDotToken !== undefined; - } - return false; - } - ts.isRestParameter = isRestParameter; - function isLiteralKind(kind) { - return 7 /* FirstLiteralToken */ <= kind && kind <= 10 /* LastLiteralToken */; - } - ts.isLiteralKind = isLiteralKind; - function isTextualLiteralKind(kind) { - return kind === 8 /* StringLiteral */ || kind === 10 /* NoSubstitutionTemplateLiteral */; - } - ts.isTextualLiteralKind = isTextualLiteralKind; - function isTemplateLiteralKind(kind) { - return 10 /* FirstTemplateToken */ <= kind && kind <= 13 /* LastTemplateToken */; - } - ts.isTemplateLiteralKind = isTemplateLiteralKind; - function isBindingPattern(node) { - return !!node && (node.kind === 154 /* ArrayBindingPattern */ || node.kind === 153 /* ObjectBindingPattern */); - } - ts.isBindingPattern = isBindingPattern; - function isInAmbientContext(node) { - while (node) { - if (node.flags & (2 /* Ambient */ | 2048 /* DeclarationFile */)) { - return true; - } - node = node.parent; - } - return false; - } - ts.isInAmbientContext = isInAmbientContext; - function isDeclaration(node) { - switch (node.kind) { - case 166 /* ArrowFunction */: - case 155 /* BindingElement */: - case 204 /* ClassDeclaration */: - case 137 /* Constructor */: - case 207 /* EnumDeclaration */: - case 229 /* EnumMember */: - case 220 /* ExportSpecifier */: - case 203 /* FunctionDeclaration */: - case 165 /* FunctionExpression */: - case 138 /* GetAccessor */: - case 213 /* ImportClause */: - case 211 /* ImportEqualsDeclaration */: - case 216 /* ImportSpecifier */: - case 205 /* InterfaceDeclaration */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 208 /* ModuleDeclaration */: - case 214 /* NamespaceImport */: - case 131 /* Parameter */: - case 227 /* PropertyAssignment */: - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - case 139 /* SetAccessor */: - case 228 /* ShorthandPropertyAssignment */: - case 206 /* TypeAliasDeclaration */: - case 130 /* TypeParameter */: - case 201 /* VariableDeclaration */: - return true; - } - return false; - } - ts.isDeclaration = isDeclaration; - function isStatement(n) { - switch (n.kind) { - case 193 /* BreakStatement */: - case 192 /* ContinueStatement */: - case 200 /* DebuggerStatement */: - case 187 /* DoStatement */: - case 185 /* ExpressionStatement */: - case 184 /* EmptyStatement */: - case 190 /* ForInStatement */: - case 191 /* ForOfStatement */: - case 189 /* ForStatement */: - case 186 /* IfStatement */: - case 197 /* LabeledStatement */: - case 194 /* ReturnStatement */: - case 196 /* SwitchStatement */: - case 94 /* ThrowKeyword */: - case 199 /* TryStatement */: - case 183 /* VariableStatement */: - case 188 /* WhileStatement */: - case 195 /* WithStatement */: - case 217 /* ExportAssignment */: - return true; - default: - return false; - } - } - ts.isStatement = isStatement; - function isClassElement(n) { - switch (n.kind) { - case 137 /* Constructor */: - case 134 /* PropertyDeclaration */: - case 136 /* MethodDeclaration */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 135 /* MethodSignature */: - case 142 /* IndexSignature */: - return true; - default: - return false; - } - } - ts.isClassElement = isClassElement; - // True if the given identifier, string literal, or number literal is the name of a declaration node - function isDeclarationName(name) { - if (name.kind !== 65 /* Identifier */ && name.kind !== 8 /* StringLiteral */ && name.kind !== 7 /* NumericLiteral */) { - return false; - } - var parent = name.parent; - if (parent.kind === 216 /* ImportSpecifier */ || parent.kind === 220 /* ExportSpecifier */) { - if (parent.propertyName) { - return true; - } - } - if (isDeclaration(parent)) { - return parent.name === name; - } - return false; - } - ts.isDeclarationName = isDeclarationName; - // An alias symbol is created by one of the following declarations: - // import = ... - // import from ... - // import * as from ... - // import { x as } from ... - // export { x as } from ... - // export = ... - // export default ... - function isAliasSymbolDeclaration(node) { - return node.kind === 211 /* ImportEqualsDeclaration */ || - node.kind === 213 /* ImportClause */ && !!node.name || - node.kind === 214 /* NamespaceImport */ || - node.kind === 216 /* ImportSpecifier */ || - node.kind === 220 /* ExportSpecifier */ || - node.kind === 217 /* ExportAssignment */ && node.expression.kind === 65 /* Identifier */; - } - ts.isAliasSymbolDeclaration = isAliasSymbolDeclaration; - function getClassExtendsHeritageClauseElement(node) { - var heritageClause = getHeritageClause(node.heritageClauses, 79 /* ExtendsKeyword */); - return heritageClause && heritageClause.types.length > 0 ? heritageClause.types[0] : undefined; - } - ts.getClassExtendsHeritageClauseElement = getClassExtendsHeritageClauseElement; - function getClassImplementsHeritageClauseElements(node) { - var heritageClause = getHeritageClause(node.heritageClauses, 102 /* ImplementsKeyword */); - return heritageClause ? heritageClause.types : undefined; - } - ts.getClassImplementsHeritageClauseElements = getClassImplementsHeritageClauseElements; - function getInterfaceBaseTypeNodes(node) { - var heritageClause = getHeritageClause(node.heritageClauses, 79 /* ExtendsKeyword */); - return heritageClause ? heritageClause.types : undefined; - } - ts.getInterfaceBaseTypeNodes = getInterfaceBaseTypeNodes; - function getHeritageClause(clauses, kind) { - if (clauses) { - for (var _i = 0; _i < clauses.length; _i++) { - var clause = clauses[_i]; - if (clause.token === kind) { - return clause; - } - } - } - return undefined; - } - ts.getHeritageClause = getHeritageClause; - function tryResolveScriptReference(host, sourceFile, reference) { - if (!host.getCompilerOptions().noResolve) { - var referenceFileName = ts.isRootedDiskPath(reference.fileName) ? reference.fileName : ts.combinePaths(ts.getDirectoryPath(sourceFile.fileName), reference.fileName); - referenceFileName = ts.getNormalizedAbsolutePath(referenceFileName, host.getCurrentDirectory()); - return host.getSourceFile(referenceFileName); - } - } - ts.tryResolveScriptReference = tryResolveScriptReference; - function getAncestor(node, kind) { - while (node) { - if (node.kind === kind) { - return node; - } - node = node.parent; - } - return undefined; - } - ts.getAncestor = getAncestor; - function getFileReferenceFromReferencePath(comment, commentRange) { - var simpleReferenceRegEx = /^\/\/\/\s*/gim; - if (simpleReferenceRegEx.exec(comment)) { - if (isNoDefaultLibRegEx.exec(comment)) { - return { - isNoDefaultLib: true - }; - } - else { - var matchResult = ts.fullTripleSlashReferencePathRegEx.exec(comment); - if (matchResult) { - var start = commentRange.pos; - var end = commentRange.end; - return { - fileReference: { - pos: start, - end: end, - fileName: matchResult[3] - }, - isNoDefaultLib: false - }; - } - else { - return { - diagnosticMessage: ts.Diagnostics.Invalid_reference_directive_syntax, - isNoDefaultLib: false - }; - } - } - } - return undefined; - } - ts.getFileReferenceFromReferencePath = getFileReferenceFromReferencePath; - function isKeyword(token) { - return 66 /* FirstKeyword */ <= token && token <= 127 /* LastKeyword */; - } - ts.isKeyword = isKeyword; - function isTrivia(token) { - return 2 /* FirstTriviaToken */ <= token && token <= 6 /* LastTriviaToken */; - } - ts.isTrivia = isTrivia; - /** - * A declaration has a dynamic name if both of the following are true: - * 1. The declaration has a computed property name - * 2. The computed name is *not* expressed as Symbol., where name - * is a property of the Symbol constructor that denotes a built in - * Symbol. - */ - function hasDynamicName(declaration) { - return declaration.name && - declaration.name.kind === 129 /* ComputedPropertyName */ && - !isWellKnownSymbolSyntactically(declaration.name.expression); - } - ts.hasDynamicName = hasDynamicName; - /** - * Checks if the expression is of the form: - * Symbol.name - * where Symbol is literally the word "Symbol", and name is any identifierName - */ - function isWellKnownSymbolSyntactically(node) { - return node.kind === 158 /* PropertyAccessExpression */ && isESSymbolIdentifier(node.expression); - } - ts.isWellKnownSymbolSyntactically = isWellKnownSymbolSyntactically; - function getPropertyNameForPropertyNameNode(name) { - if (name.kind === 65 /* Identifier */ || name.kind === 8 /* StringLiteral */ || name.kind === 7 /* NumericLiteral */) { - return name.text; - } - if (name.kind === 129 /* ComputedPropertyName */) { - var nameExpression = name.expression; - if (isWellKnownSymbolSyntactically(nameExpression)) { - var rightHandSideName = nameExpression.name.text; - return getPropertyNameForKnownSymbolName(rightHandSideName); - } - } - return undefined; - } - ts.getPropertyNameForPropertyNameNode = getPropertyNameForPropertyNameNode; - function getPropertyNameForKnownSymbolName(symbolName) { - return "__@" + symbolName; - } - ts.getPropertyNameForKnownSymbolName = getPropertyNameForKnownSymbolName; - /** - * Includes the word "Symbol" with unicode escapes - */ - function isESSymbolIdentifier(node) { - return node.kind === 65 /* Identifier */ && node.text === "Symbol"; - } - ts.isESSymbolIdentifier = isESSymbolIdentifier; - function isModifier(token) { - switch (token) { - case 108 /* PublicKeyword */: - case 106 /* PrivateKeyword */: - case 107 /* ProtectedKeyword */: - case 109 /* StaticKeyword */: - case 78 /* ExportKeyword */: - case 115 /* DeclareKeyword */: - case 70 /* ConstKeyword */: - case 73 /* DefaultKeyword */: - return true; - } - return false; - } - ts.isModifier = isModifier; - function isParameterDeclaration(node) { - var root = getRootDeclaration(node); - return root.kind === 131 /* Parameter */; - } - ts.isParameterDeclaration = isParameterDeclaration; - function getRootDeclaration(node) { - while (node.kind === 155 /* BindingElement */) { - node = node.parent.parent; - } - return node; - } - ts.getRootDeclaration = getRootDeclaration; - function nodeStartsNewLexicalEnvironment(n) { - return isFunctionLike(n) || n.kind === 208 /* ModuleDeclaration */ || n.kind === 230 /* SourceFile */; - } - ts.nodeStartsNewLexicalEnvironment = nodeStartsNewLexicalEnvironment; - function nodeIsSynthesized(node) { - return node.pos === -1; - } - ts.nodeIsSynthesized = nodeIsSynthesized; - function createSynthesizedNode(kind, startsOnNewLine) { - var node = ts.createNode(kind); - node.pos = -1; - node.end = -1; - node.startsOnNewLine = startsOnNewLine; - return node; - } - ts.createSynthesizedNode = createSynthesizedNode; - function createSynthesizedNodeArray() { - var array = []; - array.pos = -1; - array.end = -1; - return array; - } - ts.createSynthesizedNodeArray = createSynthesizedNodeArray; - function createDiagnosticCollection() { - var nonFileDiagnostics = []; - var fileDiagnostics = {}; - var diagnosticsModified = false; - var modificationCount = 0; - return { - add: add, - getGlobalDiagnostics: getGlobalDiagnostics, - getDiagnostics: getDiagnostics, - getModificationCount: getModificationCount - }; - function getModificationCount() { - return modificationCount; - } - function add(diagnostic) { - var diagnostics; - if (diagnostic.file) { - diagnostics = fileDiagnostics[diagnostic.file.fileName]; - if (!diagnostics) { - diagnostics = []; - fileDiagnostics[diagnostic.file.fileName] = diagnostics; - } - } - else { - diagnostics = nonFileDiagnostics; - } - diagnostics.push(diagnostic); - diagnosticsModified = true; - modificationCount++; - } - function getGlobalDiagnostics() { - sortAndDeduplicate(); - return nonFileDiagnostics; - } - function getDiagnostics(fileName) { - sortAndDeduplicate(); - if (fileName) { - return fileDiagnostics[fileName] || []; - } - var allDiagnostics = []; - function pushDiagnostic(d) { - allDiagnostics.push(d); - } - ts.forEach(nonFileDiagnostics, pushDiagnostic); - for (var key in fileDiagnostics) { - if (ts.hasProperty(fileDiagnostics, key)) { - ts.forEach(fileDiagnostics[key], pushDiagnostic); - } - } - return ts.sortAndDeduplicateDiagnostics(allDiagnostics); - } - function sortAndDeduplicate() { - if (!diagnosticsModified) { - return; - } - diagnosticsModified = false; - nonFileDiagnostics = ts.sortAndDeduplicateDiagnostics(nonFileDiagnostics); - for (var key in fileDiagnostics) { - if (ts.hasProperty(fileDiagnostics, key)) { - fileDiagnostics[key] = ts.sortAndDeduplicateDiagnostics(fileDiagnostics[key]); - } - } - } - } - ts.createDiagnosticCollection = createDiagnosticCollection; - // This consists of the first 19 unprintable ASCII characters, canonical escapes, lineSeparator, - // paragraphSeparator, and nextLine. The latter three are just desirable to suppress new lines in - // the language service. These characters should be escaped when printing, and if any characters are added, - // the map below must be updated. Note that this regexp *does not* include the 'delete' character. - // There is no reason for this other than that JSON.stringify does not handle it either. - var escapedCharsRegExp = /[\\\"\u0000-\u001f\t\v\f\b\r\n\u2028\u2029\u0085]/g; - var escapedCharsMap = { - "\0": "\\0", - "\t": "\\t", - "\v": "\\v", - "\f": "\\f", - "\b": "\\b", - "\r": "\\r", - "\n": "\\n", - "\\": "\\\\", - "\"": "\\\"", - "\u2028": "\\u2028", - "\u2029": "\\u2029", - "\u0085": "\\u0085" // nextLine - }; - /** - * Based heavily on the abstract 'Quote'/'QuoteJSONString' operation from ECMA-262 (24.3.2.2), - * but augmented for a few select characters (e.g. lineSeparator, paragraphSeparator, nextLine) - * Note that this doesn't actually wrap the input in double quotes. - */ - function escapeString(s) { - s = escapedCharsRegExp.test(s) ? s.replace(escapedCharsRegExp, getReplacement) : s; - return s; - function getReplacement(c) { - return escapedCharsMap[c] || get16BitUnicodeEscapeSequence(c.charCodeAt(0)); - } - } - ts.escapeString = escapeString; - function get16BitUnicodeEscapeSequence(charCode) { - var hexCharCode = charCode.toString(16).toUpperCase(); - var paddedHexCode = ("0000" + hexCharCode).slice(-4); - return "\\u" + paddedHexCode; - } - var nonAsciiCharacters = /[^\u0000-\u007F]/g; - function escapeNonAsciiCharacters(s) { - // Replace non-ASCII characters with '\uNNNN' escapes if any exist. - // Otherwise just return the original string. - return nonAsciiCharacters.test(s) ? - s.replace(nonAsciiCharacters, function (c) { return get16BitUnicodeEscapeSequence(c.charCodeAt(0)); }) : - s; - } - ts.escapeNonAsciiCharacters = escapeNonAsciiCharacters; - var indentStrings = ["", " "]; - function getIndentString(level) { - if (indentStrings[level] === undefined) { - indentStrings[level] = getIndentString(level - 1) + indentStrings[1]; - } - return indentStrings[level]; - } - ts.getIndentString = getIndentString; - function getIndentSize() { - return indentStrings[1].length; - } - ts.getIndentSize = getIndentSize; - function createTextWriter(newLine) { - var output = ""; - var indent = 0; - var lineStart = true; - var lineCount = 0; - var linePos = 0; - function write(s) { - if (s && s.length) { - if (lineStart) { - output += getIndentString(indent); - lineStart = false; - } - output += s; - } - } - function rawWrite(s) { - if (s !== undefined) { - if (lineStart) { - lineStart = false; - } - output += s; - } - } - function writeLiteral(s) { - if (s && s.length) { - write(s); - var lineStartsOfS = ts.computeLineStarts(s); - if (lineStartsOfS.length > 1) { - lineCount = lineCount + lineStartsOfS.length - 1; - linePos = output.length - s.length + ts.lastOrUndefined(lineStartsOfS); - } - } - } - function writeLine() { - if (!lineStart) { - output += newLine; - lineCount++; - linePos = output.length; - lineStart = true; - } - } - function writeTextOfNode(sourceFile, node) { - write(getSourceTextOfNodeFromSourceFile(sourceFile, node)); - } - return { - write: write, - rawWrite: rawWrite, - writeTextOfNode: writeTextOfNode, - writeLiteral: writeLiteral, - writeLine: writeLine, - increaseIndent: function () { return indent++; }, - decreaseIndent: function () { return indent--; }, - getIndent: function () { return indent; }, - getTextPos: function () { return output.length; }, - getLine: function () { return lineCount + 1; }, - getColumn: function () { return lineStart ? indent * getIndentSize() + 1 : output.length - linePos + 1; }, - getText: function () { return output; } - }; - } - ts.createTextWriter = createTextWriter; - function getOwnEmitOutputFilePath(sourceFile, host, extension) { - var compilerOptions = host.getCompilerOptions(); - var emitOutputFilePathWithoutExtension; - if (compilerOptions.outDir) { - emitOutputFilePathWithoutExtension = ts.removeFileExtension(getSourceFilePathInNewDir(sourceFile, host, compilerOptions.outDir)); - } - else { - emitOutputFilePathWithoutExtension = ts.removeFileExtension(sourceFile.fileName); - } - return emitOutputFilePathWithoutExtension + extension; - } - ts.getOwnEmitOutputFilePath = getOwnEmitOutputFilePath; - function getSourceFilePathInNewDir(sourceFile, host, newDirPath) { - var sourceFilePath = ts.getNormalizedAbsolutePath(sourceFile.fileName, host.getCurrentDirectory()); - sourceFilePath = sourceFilePath.replace(host.getCommonSourceDirectory(), ""); - return ts.combinePaths(newDirPath, sourceFilePath); - } - ts.getSourceFilePathInNewDir = getSourceFilePathInNewDir; - function writeFile(host, diagnostics, fileName, data, writeByteOrderMark) { - host.writeFile(fileName, data, writeByteOrderMark, function (hostErrorMessage) { - diagnostics.push(ts.createCompilerDiagnostic(ts.Diagnostics.Could_not_write_file_0_Colon_1, fileName, hostErrorMessage)); - }); - } - ts.writeFile = writeFile; - function getLineOfLocalPosition(currentSourceFile, pos) { - return ts.getLineAndCharacterOfPosition(currentSourceFile, pos).line; - } - ts.getLineOfLocalPosition = getLineOfLocalPosition; - function getFirstConstructorWithBody(node) { - return ts.forEach(node.members, function (member) { - if (member.kind === 137 /* Constructor */ && nodeIsPresent(member.body)) { - return member; - } - }); - } - ts.getFirstConstructorWithBody = getFirstConstructorWithBody; - function shouldEmitToOwnFile(sourceFile, compilerOptions) { - if (!isDeclarationFile(sourceFile)) { - if ((isExternalModule(sourceFile) || !compilerOptions.out)) { - // 1. in-browser single file compilation scenario - // 2. non .js file - return compilerOptions.isolatedModules || !ts.fileExtensionIs(sourceFile.fileName, ".js"); - } - return false; - } - return false; - } - ts.shouldEmitToOwnFile = shouldEmitToOwnFile; - function getAllAccessorDeclarations(declarations, accessor) { - var firstAccessor; - var secondAccessor; - var getAccessor; - var setAccessor; - if (hasDynamicName(accessor)) { - firstAccessor = accessor; - if (accessor.kind === 138 /* GetAccessor */) { - getAccessor = accessor; - } - else if (accessor.kind === 139 /* SetAccessor */) { - setAccessor = accessor; - } - else { - ts.Debug.fail("Accessor has wrong kind"); - } - } - else { - ts.forEach(declarations, function (member) { - if ((member.kind === 138 /* GetAccessor */ || member.kind === 139 /* SetAccessor */) - && (member.flags & 128 /* Static */) === (accessor.flags & 128 /* Static */)) { - var memberName = getPropertyNameForPropertyNameNode(member.name); - var accessorName = getPropertyNameForPropertyNameNode(accessor.name); - if (memberName === accessorName) { - if (!firstAccessor) { - firstAccessor = member; - } - else if (!secondAccessor) { - secondAccessor = member; - } - if (member.kind === 138 /* GetAccessor */ && !getAccessor) { - getAccessor = member; - } - if (member.kind === 139 /* SetAccessor */ && !setAccessor) { - setAccessor = member; - } - } - } - }); - } - return { - firstAccessor: firstAccessor, - secondAccessor: secondAccessor, - getAccessor: getAccessor, - setAccessor: setAccessor - }; - } - ts.getAllAccessorDeclarations = getAllAccessorDeclarations; - function emitNewLineBeforeLeadingComments(currentSourceFile, writer, node, leadingComments) { - // If the leading comments start on different line than the start of node, write new line - if (leadingComments && leadingComments.length && node.pos !== leadingComments[0].pos && - getLineOfLocalPosition(currentSourceFile, node.pos) !== getLineOfLocalPosition(currentSourceFile, leadingComments[0].pos)) { - writer.writeLine(); - } - } - ts.emitNewLineBeforeLeadingComments = emitNewLineBeforeLeadingComments; - function emitComments(currentSourceFile, writer, comments, trailingSeparator, newLine, writeComment) { - var emitLeadingSpace = !trailingSeparator; - ts.forEach(comments, function (comment) { - if (emitLeadingSpace) { - writer.write(" "); - emitLeadingSpace = false; - } - writeComment(currentSourceFile, writer, comment, newLine); - if (comment.hasTrailingNewLine) { - writer.writeLine(); - } - else if (trailingSeparator) { - writer.write(" "); - } - else { - // Emit leading space to separate comment during next comment emit - emitLeadingSpace = true; - } - }); - } - ts.emitComments = emitComments; - function writeCommentRange(currentSourceFile, writer, comment, newLine) { - if (currentSourceFile.text.charCodeAt(comment.pos + 1) === 42 /* asterisk */) { - var firstCommentLineAndCharacter = ts.getLineAndCharacterOfPosition(currentSourceFile, comment.pos); - var lineCount = ts.getLineStarts(currentSourceFile).length; - var firstCommentLineIndent; - for (var pos = comment.pos, currentLine = firstCommentLineAndCharacter.line; pos < comment.end; currentLine++) { - var nextLineStart = (currentLine + 1) === lineCount - ? currentSourceFile.text.length + 1 - : getStartPositionOfLine(currentLine + 1, currentSourceFile); - if (pos !== comment.pos) { - // If we are not emitting first line, we need to write the spaces to adjust the alignment - if (firstCommentLineIndent === undefined) { - firstCommentLineIndent = calculateIndent(getStartPositionOfLine(firstCommentLineAndCharacter.line, currentSourceFile), comment.pos); - } - // These are number of spaces writer is going to write at current indent - var currentWriterIndentSpacing = writer.getIndent() * getIndentSize(); - // Number of spaces we want to be writing - // eg: Assume writer indent - // module m { - // /* starts at character 9 this is line 1 - // * starts at character pos 4 line --1 = 8 - 8 + 3 - // More left indented comment */ --2 = 8 - 8 + 2 - // class c { } - // } - // module m { - // /* this is line 1 -- Assume current writer indent 8 - // * line --3 = 8 - 4 + 5 - // More right indented comment */ --4 = 8 - 4 + 11 - // class c { } - // } - var spacesToEmit = currentWriterIndentSpacing - firstCommentLineIndent + calculateIndent(pos, nextLineStart); - if (spacesToEmit > 0) { - var numberOfSingleSpacesToEmit = spacesToEmit % getIndentSize(); - var indentSizeSpaceString = getIndentString((spacesToEmit - numberOfSingleSpacesToEmit) / getIndentSize()); - // Write indent size string ( in eg 1: = "", 2: "" , 3: string with 8 spaces 4: string with 12 spaces - writer.rawWrite(indentSizeSpaceString); - // Emit the single spaces (in eg: 1: 3 spaces, 2: 2 spaces, 3: 1 space, 4: 3 spaces) - while (numberOfSingleSpacesToEmit) { - writer.rawWrite(" "); - numberOfSingleSpacesToEmit--; - } - } - else { - // No spaces to emit write empty string - writer.rawWrite(""); - } - } - // Write the comment line text - writeTrimmedCurrentLine(pos, nextLineStart); - pos = nextLineStart; - } - } - else { - // Single line comment of style //.... - writer.write(currentSourceFile.text.substring(comment.pos, comment.end)); - } - function writeTrimmedCurrentLine(pos, nextLineStart) { - var end = Math.min(comment.end, nextLineStart - 1); - var currentLineText = currentSourceFile.text.substring(pos, end).replace(/^\s+|\s+$/g, ''); - if (currentLineText) { - // trimmed forward and ending spaces text - writer.write(currentLineText); - if (end !== comment.end) { - writer.writeLine(); - } - } - else { - // Empty string - make sure we write empty line - writer.writeLiteral(newLine); - } - } - function calculateIndent(pos, end) { - var currentLineIndent = 0; - for (; pos < end && ts.isWhiteSpace(currentSourceFile.text.charCodeAt(pos)); pos++) { - if (currentSourceFile.text.charCodeAt(pos) === 9 /* tab */) { - // Tabs = TabSize = indent size and go to next tabStop - currentLineIndent += getIndentSize() - (currentLineIndent % getIndentSize()); - } - else { - // Single space - currentLineIndent++; - } - } - return currentLineIndent; - } - } - ts.writeCommentRange = writeCommentRange; - function modifierToFlag(token) { - switch (token) { - case 109 /* StaticKeyword */: return 128 /* Static */; - case 108 /* PublicKeyword */: return 16 /* Public */; - case 107 /* ProtectedKeyword */: return 64 /* Protected */; - case 106 /* PrivateKeyword */: return 32 /* Private */; - case 78 /* ExportKeyword */: return 1 /* Export */; - case 115 /* DeclareKeyword */: return 2 /* Ambient */; - case 70 /* ConstKeyword */: return 8192 /* Const */; - case 73 /* DefaultKeyword */: return 256 /* Default */; - } - return 0; - } - ts.modifierToFlag = modifierToFlag; - function isLeftHandSideExpression(expr) { - if (expr) { - switch (expr.kind) { - case 158 /* PropertyAccessExpression */: - case 159 /* ElementAccessExpression */: - case 161 /* NewExpression */: - case 160 /* CallExpression */: - case 162 /* TaggedTemplateExpression */: - case 156 /* ArrayLiteralExpression */: - case 164 /* ParenthesizedExpression */: - case 157 /* ObjectLiteralExpression */: - case 177 /* ClassExpression */: - case 165 /* FunctionExpression */: - case 65 /* Identifier */: - case 9 /* RegularExpressionLiteral */: - case 7 /* NumericLiteral */: - case 8 /* StringLiteral */: - case 10 /* NoSubstitutionTemplateLiteral */: - case 174 /* TemplateExpression */: - case 80 /* FalseKeyword */: - case 89 /* NullKeyword */: - case 93 /* ThisKeyword */: - case 95 /* TrueKeyword */: - case 91 /* SuperKeyword */: - return true; - } - } - return false; - } - ts.isLeftHandSideExpression = isLeftHandSideExpression; - function isAssignmentOperator(token) { - return token >= 53 /* FirstAssignment */ && token <= 64 /* LastAssignment */; - } - ts.isAssignmentOperator = isAssignmentOperator; - // Returns false if this heritage clause element's expression contains something unsupported - // (i.e. not a name or dotted name). - function isSupportedExpressionWithTypeArguments(node) { - return isSupportedExpressionWithTypeArgumentsRest(node.expression); - } - ts.isSupportedExpressionWithTypeArguments = isSupportedExpressionWithTypeArguments; - function isSupportedExpressionWithTypeArgumentsRest(node) { - if (node.kind === 65 /* Identifier */) { - return true; - } - else if (node.kind === 158 /* PropertyAccessExpression */) { - return isSupportedExpressionWithTypeArgumentsRest(node.expression); - } - else { - return false; - } - } - function isRightSideOfQualifiedNameOrPropertyAccess(node) { - return (node.parent.kind === 128 /* QualifiedName */ && node.parent.right === node) || - (node.parent.kind === 158 /* PropertyAccessExpression */ && node.parent.name === node); - } - ts.isRightSideOfQualifiedNameOrPropertyAccess = isRightSideOfQualifiedNameOrPropertyAccess; - function getLocalSymbolForExportDefault(symbol) { - return symbol && symbol.valueDeclaration && (symbol.valueDeclaration.flags & 256 /* Default */) ? symbol.valueDeclaration.localSymbol : undefined; - } - ts.getLocalSymbolForExportDefault = getLocalSymbolForExportDefault; - function isJavaScript(fileName) { - return ts.fileExtensionIs(fileName, ".js"); - } - ts.isJavaScript = isJavaScript; - /** - * Replace each instance of non-ascii characters by one, two, three, or four escape sequences - * representing the UTF-8 encoding of the character, and return the expanded char code list. - */ - function getExpandedCharCodes(input) { - var output = []; - var length = input.length; - var leadSurrogate = undefined; - for (var i = 0; i < length; i++) { - var charCode = input.charCodeAt(i); - // handel utf8 - if (charCode < 0x80) { - output.push(charCode); - } - else if (charCode < 0x800) { - output.push((charCode >> 6) | 192); - output.push((charCode & 63) | 128); - } - else if (charCode < 0x10000) { - output.push((charCode >> 12) | 224); - output.push(((charCode >> 6) & 63) | 128); - output.push((charCode & 63) | 128); - } - else if (charCode < 0x20000) { - output.push((charCode >> 18) | 240); - output.push(((charCode >> 12) & 63) | 128); - output.push(((charCode >> 6) & 63) | 128); - output.push((charCode & 63) | 128); - } - else { - ts.Debug.assert(false, "Unexpected code point"); - } - } - return output; - } - var base64Digits = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="; - /** - * Converts a string to a base-64 encoded ASCII string. - */ - function convertToBase64(input) { - var result = ""; - var charCodes = getExpandedCharCodes(input); - var i = 0; - var length = charCodes.length; - var byte1, byte2, byte3, byte4; - while (i < length) { - // Convert every 6-bits in the input 3 character points - // into a base64 digit - byte1 = charCodes[i] >> 2; - byte2 = (charCodes[i] & 3) << 4 | charCodes[i + 1] >> 4; - byte3 = (charCodes[i + 1] & 15) << 2 | charCodes[i + 2] >> 6; - byte4 = charCodes[i + 2] & 63; - // We are out of characters in the input, set the extra - // digits to 64 (padding character). - if (i + 1 >= length) { - byte3 = byte4 = 64; - } - else if (i + 2 >= length) { - byte4 = 64; - } - // Write to the ouput - result += base64Digits.charAt(byte1) + base64Digits.charAt(byte2) + base64Digits.charAt(byte3) + base64Digits.charAt(byte4); - i += 3; - } - return result; - } - ts.convertToBase64 = convertToBase64; - var carriageReturnLineFeed = "\r\n"; - var lineFeed = "\n"; - function getNewLineCharacter(options) { - if (options.newLine === 0 /* CarriageReturnLineFeed */) { - return carriageReturnLineFeed; - } - else if (options.newLine === 1 /* LineFeed */) { - return lineFeed; - } - else if (ts.sys) { - return ts.sys.newLine; - } - return carriageReturnLineFeed; - } - ts.getNewLineCharacter = getNewLineCharacter; -})(ts || (ts = {})); -var ts; -(function (ts) { - function getDefaultLibFileName(options) { - return options.target === 2 /* ES6 */ ? "lib.es6.d.ts" : "lib.d.ts"; - } - ts.getDefaultLibFileName = getDefaultLibFileName; - function textSpanEnd(span) { - return span.start + span.length; - } - ts.textSpanEnd = textSpanEnd; - function textSpanIsEmpty(span) { - return span.length === 0; - } - ts.textSpanIsEmpty = textSpanIsEmpty; - function textSpanContainsPosition(span, position) { - return position >= span.start && position < textSpanEnd(span); - } - ts.textSpanContainsPosition = textSpanContainsPosition; - // Returns true if 'span' contains 'other'. - function textSpanContainsTextSpan(span, other) { - return other.start >= span.start && textSpanEnd(other) <= textSpanEnd(span); - } - ts.textSpanContainsTextSpan = textSpanContainsTextSpan; - function textSpanOverlapsWith(span, other) { - var overlapStart = Math.max(span.start, other.start); - var overlapEnd = Math.min(textSpanEnd(span), textSpanEnd(other)); - return overlapStart < overlapEnd; - } - ts.textSpanOverlapsWith = textSpanOverlapsWith; - function textSpanOverlap(span1, span2) { - var overlapStart = Math.max(span1.start, span2.start); - var overlapEnd = Math.min(textSpanEnd(span1), textSpanEnd(span2)); - if (overlapStart < overlapEnd) { - return createTextSpanFromBounds(overlapStart, overlapEnd); - } - return undefined; - } - ts.textSpanOverlap = textSpanOverlap; - function textSpanIntersectsWithTextSpan(span, other) { - return other.start <= textSpanEnd(span) && textSpanEnd(other) >= span.start; - } - ts.textSpanIntersectsWithTextSpan = textSpanIntersectsWithTextSpan; - function textSpanIntersectsWith(span, start, length) { - var end = start + length; - return start <= textSpanEnd(span) && end >= span.start; - } - ts.textSpanIntersectsWith = textSpanIntersectsWith; - function textSpanIntersectsWithPosition(span, position) { - return position <= textSpanEnd(span) && position >= span.start; - } - ts.textSpanIntersectsWithPosition = textSpanIntersectsWithPosition; - function textSpanIntersection(span1, span2) { - var intersectStart = Math.max(span1.start, span2.start); - var intersectEnd = Math.min(textSpanEnd(span1), textSpanEnd(span2)); - if (intersectStart <= intersectEnd) { - return createTextSpanFromBounds(intersectStart, intersectEnd); - } - return undefined; - } - ts.textSpanIntersection = textSpanIntersection; - function createTextSpan(start, length) { - if (start < 0) { - throw new Error("start < 0"); - } - if (length < 0) { - throw new Error("length < 0"); - } - return { start: start, length: length }; - } - ts.createTextSpan = createTextSpan; - function createTextSpanFromBounds(start, end) { - return createTextSpan(start, end - start); - } - ts.createTextSpanFromBounds = createTextSpanFromBounds; - function textChangeRangeNewSpan(range) { - return createTextSpan(range.span.start, range.newLength); - } - ts.textChangeRangeNewSpan = textChangeRangeNewSpan; - function textChangeRangeIsUnchanged(range) { - return textSpanIsEmpty(range.span) && range.newLength === 0; - } - ts.textChangeRangeIsUnchanged = textChangeRangeIsUnchanged; - function createTextChangeRange(span, newLength) { - if (newLength < 0) { - throw new Error("newLength < 0"); - } - return { span: span, newLength: newLength }; - } - ts.createTextChangeRange = createTextChangeRange; - ts.unchangedTextChangeRange = createTextChangeRange(createTextSpan(0, 0), 0); - /** - * Called to merge all the changes that occurred across several versions of a script snapshot - * into a single change. i.e. if a user keeps making successive edits to a script we will - * have a text change from V1 to V2, V2 to V3, ..., Vn. - * - * This function will then merge those changes into a single change range valid between V1 and - * Vn. - */ - function collapseTextChangeRangesAcrossMultipleVersions(changes) { - if (changes.length === 0) { - return ts.unchangedTextChangeRange; - } - if (changes.length === 1) { - return changes[0]; - } - // We change from talking about { { oldStart, oldLength }, newLength } to { oldStart, oldEnd, newEnd } - // as it makes things much easier to reason about. - var change0 = changes[0]; - var oldStartN = change0.span.start; - var oldEndN = textSpanEnd(change0.span); - var newEndN = oldStartN + change0.newLength; - for (var i = 1; i < changes.length; i++) { - var nextChange = changes[i]; - // Consider the following case: - // i.e. two edits. The first represents the text change range { { 10, 50 }, 30 }. i.e. The span starting - // at 10, with length 50 is reduced to length 30. The second represents the text change range { { 30, 30 }, 40 }. - // i.e. the span starting at 30 with length 30 is increased to length 40. - // - // 0 10 20 30 40 50 60 70 80 90 100 - // ------------------------------------------------------------------------------------------------------- - // | / - // | /---- - // T1 | /---- - // | /---- - // | /---- - // ------------------------------------------------------------------------------------------------------- - // | \ - // | \ - // T2 | \ - // | \ - // | \ - // ------------------------------------------------------------------------------------------------------- - // - // Merging these turns out to not be too difficult. First, determining the new start of the change is trivial - // it's just the min of the old and new starts. i.e.: - // - // 0 10 20 30 40 50 60 70 80 90 100 - // ------------------------------------------------------------*------------------------------------------ - // | / - // | /---- - // T1 | /---- - // | /---- - // | /---- - // ----------------------------------------$-------------------$------------------------------------------ - // . | \ - // . | \ - // T2 . | \ - // . | \ - // . | \ - // ----------------------------------------------------------------------*-------------------------------- - // - // (Note the dots represent the newly inferrred start. - // Determining the new and old end is also pretty simple. Basically it boils down to paying attention to the - // absolute positions at the asterixes, and the relative change between the dollar signs. Basically, we see - // which if the two $'s precedes the other, and we move that one forward until they line up. in this case that - // means: - // - // 0 10 20 30 40 50 60 70 80 90 100 - // --------------------------------------------------------------------------------*---------------------- - // | / - // | /---- - // T1 | /---- - // | /---- - // | /---- - // ------------------------------------------------------------$------------------------------------------ - // . | \ - // . | \ - // T2 . | \ - // . | \ - // . | \ - // ----------------------------------------------------------------------*-------------------------------- - // - // In other words (in this case), we're recognizing that the second edit happened after where the first edit - // ended with a delta of 20 characters (60 - 40). Thus, if we go back in time to where the first edit started - // that's the same as if we started at char 80 instead of 60. - // - // As it so happens, the same logic applies if the second edit precedes the first edit. In that case rahter - // than pusing the first edit forward to match the second, we'll push the second edit forward to match the - // first. - // - // In this case that means we have { oldStart: 10, oldEnd: 80, newEnd: 70 } or, in TextChangeRange - // semantics: { { start: 10, length: 70 }, newLength: 60 } - // - // The math then works out as follows. - // If we have { oldStart1, oldEnd1, newEnd1 } and { oldStart2, oldEnd2, newEnd2 } then we can compute the - // final result like so: - // - // { - // oldStart3: Min(oldStart1, oldStart2), - // oldEnd3 : Max(oldEnd1, oldEnd1 + (oldEnd2 - newEnd1)), - // newEnd3 : Max(newEnd2, newEnd2 + (newEnd1 - oldEnd2)) - // } - var oldStart1 = oldStartN; - var oldEnd1 = oldEndN; - var newEnd1 = newEndN; - var oldStart2 = nextChange.span.start; - var oldEnd2 = textSpanEnd(nextChange.span); - var newEnd2 = oldStart2 + nextChange.newLength; - oldStartN = Math.min(oldStart1, oldStart2); - oldEndN = Math.max(oldEnd1, oldEnd1 + (oldEnd2 - newEnd1)); - newEndN = Math.max(newEnd2, newEnd2 + (newEnd1 - oldEnd2)); - } - return createTextChangeRange(createTextSpanFromBounds(oldStartN, oldEndN), newEndN - oldStartN); - } - ts.collapseTextChangeRangesAcrossMultipleVersions = collapseTextChangeRangesAcrossMultipleVersions; - function getTypeParameterOwner(d) { - if (d && d.kind === 130 /* TypeParameter */) { - for (var current = d; current; current = current.parent) { - if (ts.isFunctionLike(current) || ts.isClassLike(current) || current.kind === 205 /* InterfaceDeclaration */) { - return current; - } - } - } - } - ts.getTypeParameterOwner = getTypeParameterOwner; -})(ts || (ts = {})); -/// -/// -var ts; -(function (ts) { - var nodeConstructors = new Array(254 /* Count */); - /* @internal */ ts.parseTime = 0; - function getNodeConstructor(kind) { - return nodeConstructors[kind] || (nodeConstructors[kind] = ts.objectAllocator.getNodeConstructor(kind)); - } - ts.getNodeConstructor = getNodeConstructor; - function createNode(kind) { - return new (getNodeConstructor(kind))(); - } - ts.createNode = createNode; - function visitNode(cbNode, node) { - if (node) { - return cbNode(node); - } - } - function visitNodeArray(cbNodes, nodes) { - if (nodes) { - return cbNodes(nodes); - } - } - function visitEachNode(cbNode, nodes) { - if (nodes) { - for (var _i = 0; _i < nodes.length; _i++) { - var node = nodes[_i]; - var result = cbNode(node); - if (result) { - return result; - } - } - } - } - // Invokes a callback for each child of the given node. The 'cbNode' callback is invoked for all child nodes - // stored in properties. If a 'cbNodes' callback is specified, it is invoked for embedded arrays; otherwise, - // embedded arrays are flattened and the 'cbNode' callback is invoked for each element. If a callback returns - // a truthy value, iteration stops and that value is returned. Otherwise, undefined is returned. - function forEachChild(node, cbNode, cbNodeArray) { - if (!node) { - return; - } - // The visitXXX functions could be written as local functions that close over the cbNode and cbNodeArray - // callback parameters, but that causes a closure allocation for each invocation with noticeable effects - // on performance. - var visitNodes = cbNodeArray ? visitNodeArray : visitEachNode; - var cbNodes = cbNodeArray || cbNode; - switch (node.kind) { - case 128 /* QualifiedName */: - return visitNode(cbNode, node.left) || - visitNode(cbNode, node.right); - case 130 /* TypeParameter */: - return visitNode(cbNode, node.name) || - visitNode(cbNode, node.constraint) || - visitNode(cbNode, node.expression); - case 131 /* Parameter */: - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - case 227 /* PropertyAssignment */: - case 228 /* ShorthandPropertyAssignment */: - case 201 /* VariableDeclaration */: - case 155 /* BindingElement */: - return visitNodes(cbNodes, node.decorators) || - visitNodes(cbNodes, node.modifiers) || - visitNode(cbNode, node.propertyName) || - visitNode(cbNode, node.dotDotDotToken) || - visitNode(cbNode, node.name) || - visitNode(cbNode, node.questionToken) || - visitNode(cbNode, node.type) || - visitNode(cbNode, node.initializer); - case 145 /* FunctionType */: - case 146 /* ConstructorType */: - case 140 /* CallSignature */: - case 141 /* ConstructSignature */: - case 142 /* IndexSignature */: - return visitNodes(cbNodes, node.decorators) || - visitNodes(cbNodes, node.modifiers) || - visitNodes(cbNodes, node.typeParameters) || - visitNodes(cbNodes, node.parameters) || - visitNode(cbNode, node.type); - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 137 /* Constructor */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 165 /* FunctionExpression */: - case 203 /* FunctionDeclaration */: - case 166 /* ArrowFunction */: - return visitNodes(cbNodes, node.decorators) || - visitNodes(cbNodes, node.modifiers) || - visitNode(cbNode, node.asteriskToken) || - visitNode(cbNode, node.name) || - visitNode(cbNode, node.questionToken) || - visitNodes(cbNodes, node.typeParameters) || - visitNodes(cbNodes, node.parameters) || - visitNode(cbNode, node.type) || - visitNode(cbNode, node.equalsGreaterThanToken) || - visitNode(cbNode, node.body); - case 144 /* TypeReference */: - return visitNode(cbNode, node.typeName) || - visitNodes(cbNodes, node.typeArguments); - case 143 /* TypePredicate */: - return visitNode(cbNode, node.parameterName) || - visitNode(cbNode, node.type); - case 147 /* TypeQuery */: - return visitNode(cbNode, node.exprName); - case 148 /* TypeLiteral */: - return visitNodes(cbNodes, node.members); - case 149 /* ArrayType */: - return visitNode(cbNode, node.elementType); - case 150 /* TupleType */: - return visitNodes(cbNodes, node.elementTypes); - case 151 /* UnionType */: - return visitNodes(cbNodes, node.types); - case 152 /* ParenthesizedType */: - return visitNode(cbNode, node.type); - case 153 /* ObjectBindingPattern */: - case 154 /* ArrayBindingPattern */: - return visitNodes(cbNodes, node.elements); - case 156 /* ArrayLiteralExpression */: - return visitNodes(cbNodes, node.elements); - case 157 /* ObjectLiteralExpression */: - return visitNodes(cbNodes, node.properties); - case 158 /* PropertyAccessExpression */: - return visitNode(cbNode, node.expression) || - visitNode(cbNode, node.dotToken) || - visitNode(cbNode, node.name); - case 159 /* ElementAccessExpression */: - return visitNode(cbNode, node.expression) || - visitNode(cbNode, node.argumentExpression); - case 160 /* CallExpression */: - case 161 /* NewExpression */: - return visitNode(cbNode, node.expression) || - visitNodes(cbNodes, node.typeArguments) || - visitNodes(cbNodes, node.arguments); - case 162 /* TaggedTemplateExpression */: - return visitNode(cbNode, node.tag) || - visitNode(cbNode, node.template); - case 163 /* TypeAssertionExpression */: - return visitNode(cbNode, node.type) || - visitNode(cbNode, node.expression); - case 164 /* ParenthesizedExpression */: - return visitNode(cbNode, node.expression); - case 167 /* DeleteExpression */: - return visitNode(cbNode, node.expression); - case 168 /* TypeOfExpression */: - return visitNode(cbNode, node.expression); - case 169 /* VoidExpression */: - return visitNode(cbNode, node.expression); - case 170 /* PrefixUnaryExpression */: - return visitNode(cbNode, node.operand); - case 175 /* YieldExpression */: - return visitNode(cbNode, node.asteriskToken) || - visitNode(cbNode, node.expression); - case 171 /* PostfixUnaryExpression */: - return visitNode(cbNode, node.operand); - case 172 /* BinaryExpression */: - return visitNode(cbNode, node.left) || - visitNode(cbNode, node.operatorToken) || - visitNode(cbNode, node.right); - case 173 /* ConditionalExpression */: - return visitNode(cbNode, node.condition) || - visitNode(cbNode, node.questionToken) || - visitNode(cbNode, node.whenTrue) || - visitNode(cbNode, node.colonToken) || - visitNode(cbNode, node.whenFalse); - case 176 /* SpreadElementExpression */: - return visitNode(cbNode, node.expression); - case 182 /* Block */: - case 209 /* ModuleBlock */: - return visitNodes(cbNodes, node.statements); - case 230 /* SourceFile */: - return visitNodes(cbNodes, node.statements) || - visitNode(cbNode, node.endOfFileToken); - case 183 /* VariableStatement */: - return visitNodes(cbNodes, node.decorators) || - visitNodes(cbNodes, node.modifiers) || - visitNode(cbNode, node.declarationList); - case 202 /* VariableDeclarationList */: - return visitNodes(cbNodes, node.declarations); - case 185 /* ExpressionStatement */: - return visitNode(cbNode, node.expression); - case 186 /* IfStatement */: - return visitNode(cbNode, node.expression) || - visitNode(cbNode, node.thenStatement) || - visitNode(cbNode, node.elseStatement); - case 187 /* DoStatement */: - return visitNode(cbNode, node.statement) || - visitNode(cbNode, node.expression); - case 188 /* WhileStatement */: - return visitNode(cbNode, node.expression) || - visitNode(cbNode, node.statement); - case 189 /* ForStatement */: - return visitNode(cbNode, node.initializer) || - visitNode(cbNode, node.condition) || - visitNode(cbNode, node.incrementor) || - visitNode(cbNode, node.statement); - case 190 /* ForInStatement */: - return visitNode(cbNode, node.initializer) || - visitNode(cbNode, node.expression) || - visitNode(cbNode, node.statement); - case 191 /* ForOfStatement */: - return visitNode(cbNode, node.initializer) || - visitNode(cbNode, node.expression) || - visitNode(cbNode, node.statement); - case 192 /* ContinueStatement */: - case 193 /* BreakStatement */: - return visitNode(cbNode, node.label); - case 194 /* ReturnStatement */: - return visitNode(cbNode, node.expression); - case 195 /* WithStatement */: - return visitNode(cbNode, node.expression) || - visitNode(cbNode, node.statement); - case 196 /* SwitchStatement */: - return visitNode(cbNode, node.expression) || - visitNode(cbNode, node.caseBlock); - case 210 /* CaseBlock */: - return visitNodes(cbNodes, node.clauses); - case 223 /* CaseClause */: - return visitNode(cbNode, node.expression) || - visitNodes(cbNodes, node.statements); - case 224 /* DefaultClause */: - return visitNodes(cbNodes, node.statements); - case 197 /* LabeledStatement */: - return visitNode(cbNode, node.label) || - visitNode(cbNode, node.statement); - case 198 /* ThrowStatement */: - return visitNode(cbNode, node.expression); - case 199 /* TryStatement */: - return visitNode(cbNode, node.tryBlock) || - visitNode(cbNode, node.catchClause) || - visitNode(cbNode, node.finallyBlock); - case 226 /* CatchClause */: - return visitNode(cbNode, node.variableDeclaration) || - visitNode(cbNode, node.block); - case 132 /* Decorator */: - return visitNode(cbNode, node.expression); - case 204 /* ClassDeclaration */: - case 177 /* ClassExpression */: - return visitNodes(cbNodes, node.decorators) || - visitNodes(cbNodes, node.modifiers) || - visitNode(cbNode, node.name) || - visitNodes(cbNodes, node.typeParameters) || - visitNodes(cbNodes, node.heritageClauses) || - visitNodes(cbNodes, node.members); - case 205 /* InterfaceDeclaration */: - return visitNodes(cbNodes, node.decorators) || - visitNodes(cbNodes, node.modifiers) || - visitNode(cbNode, node.name) || - visitNodes(cbNodes, node.typeParameters) || - visitNodes(cbNodes, node.heritageClauses) || - visitNodes(cbNodes, node.members); - case 206 /* TypeAliasDeclaration */: - return visitNodes(cbNodes, node.decorators) || - visitNodes(cbNodes, node.modifiers) || - visitNode(cbNode, node.name) || - visitNodes(cbNodes, node.typeParameters) || - visitNode(cbNode, node.type); - case 207 /* EnumDeclaration */: - return visitNodes(cbNodes, node.decorators) || - visitNodes(cbNodes, node.modifiers) || - visitNode(cbNode, node.name) || - visitNodes(cbNodes, node.members); - case 229 /* EnumMember */: - return visitNode(cbNode, node.name) || - visitNode(cbNode, node.initializer); - case 208 /* ModuleDeclaration */: - return visitNodes(cbNodes, node.decorators) || - visitNodes(cbNodes, node.modifiers) || - visitNode(cbNode, node.name) || - visitNode(cbNode, node.body); - case 211 /* ImportEqualsDeclaration */: - return visitNodes(cbNodes, node.decorators) || - visitNodes(cbNodes, node.modifiers) || - visitNode(cbNode, node.name) || - visitNode(cbNode, node.moduleReference); - case 212 /* ImportDeclaration */: - return visitNodes(cbNodes, node.decorators) || - visitNodes(cbNodes, node.modifiers) || - visitNode(cbNode, node.importClause) || - visitNode(cbNode, node.moduleSpecifier); - case 213 /* ImportClause */: - return visitNode(cbNode, node.name) || - visitNode(cbNode, node.namedBindings); - case 214 /* NamespaceImport */: - return visitNode(cbNode, node.name); - case 215 /* NamedImports */: - case 219 /* NamedExports */: - return visitNodes(cbNodes, node.elements); - case 218 /* ExportDeclaration */: - return visitNodes(cbNodes, node.decorators) || - visitNodes(cbNodes, node.modifiers) || - visitNode(cbNode, node.exportClause) || - visitNode(cbNode, node.moduleSpecifier); - case 216 /* ImportSpecifier */: - case 220 /* ExportSpecifier */: - return visitNode(cbNode, node.propertyName) || - visitNode(cbNode, node.name); - case 217 /* ExportAssignment */: - return visitNodes(cbNodes, node.decorators) || - visitNodes(cbNodes, node.modifiers) || - visitNode(cbNode, node.expression); - case 174 /* TemplateExpression */: - return visitNode(cbNode, node.head) || visitNodes(cbNodes, node.templateSpans); - case 180 /* TemplateSpan */: - return visitNode(cbNode, node.expression) || visitNode(cbNode, node.literal); - case 129 /* ComputedPropertyName */: - return visitNode(cbNode, node.expression); - case 225 /* HeritageClause */: - return visitNodes(cbNodes, node.types); - case 179 /* ExpressionWithTypeArguments */: - return visitNode(cbNode, node.expression) || - visitNodes(cbNodes, node.typeArguments); - case 222 /* ExternalModuleReference */: - return visitNode(cbNode, node.expression); - case 221 /* MissingDeclaration */: - return visitNodes(cbNodes, node.decorators); - case 231 /* JSDocTypeExpression */: - return visitNode(cbNode, node.type); - case 235 /* JSDocUnionType */: - return visitNodes(cbNodes, node.types); - case 236 /* JSDocTupleType */: - return visitNodes(cbNodes, node.types); - case 234 /* JSDocArrayType */: - return visitNode(cbNode, node.elementType); - case 238 /* JSDocNonNullableType */: - return visitNode(cbNode, node.type); - case 237 /* JSDocNullableType */: - return visitNode(cbNode, node.type); - case 239 /* JSDocRecordType */: - return visitNodes(cbNodes, node.members); - case 241 /* JSDocTypeReference */: - return visitNode(cbNode, node.name) || - visitNodes(cbNodes, node.typeArguments); - case 242 /* JSDocOptionalType */: - return visitNode(cbNode, node.type); - case 243 /* JSDocFunctionType */: - return visitNodes(cbNodes, node.parameters) || - visitNode(cbNode, node.type); - case 244 /* JSDocVariadicType */: - return visitNode(cbNode, node.type); - case 245 /* JSDocConstructorType */: - return visitNode(cbNode, node.type); - case 246 /* JSDocThisType */: - return visitNode(cbNode, node.type); - case 240 /* JSDocRecordMember */: - return visitNode(cbNode, node.name) || - visitNode(cbNode, node.type); - case 247 /* JSDocComment */: - return visitNodes(cbNodes, node.tags); - case 249 /* JSDocParameterTag */: - return visitNode(cbNode, node.preParameterName) || - visitNode(cbNode, node.typeExpression) || - visitNode(cbNode, node.postParameterName); - case 250 /* JSDocReturnTag */: - return visitNode(cbNode, node.typeExpression); - case 251 /* JSDocTypeTag */: - return visitNode(cbNode, node.typeExpression); - case 252 /* JSDocTemplateTag */: - return visitNodes(cbNodes, node.typeParameters); - } - } - ts.forEachChild = forEachChild; - function createSourceFile(fileName, sourceText, languageVersion, setParentNodes) { - if (setParentNodes === void 0) { setParentNodes = false; } - var start = new Date().getTime(); - var result = Parser.parseSourceFile(fileName, sourceText, languageVersion, undefined, setParentNodes); - ts.parseTime += new Date().getTime() - start; - return result; - } - ts.createSourceFile = createSourceFile; - // Produces a new SourceFile for the 'newText' provided. The 'textChangeRange' parameter - // indicates what changed between the 'text' that this SourceFile has and the 'newText'. - // The SourceFile will be created with the compiler attempting to reuse as many nodes from - // this file as possible. - // - // Note: this function mutates nodes from this SourceFile. That means any existing nodes - // from this SourceFile that are being held onto may change as a result (including - // becoming detached from any SourceFile). It is recommended that this SourceFile not - // be used once 'update' is called on it. - function updateSourceFile(sourceFile, newText, textChangeRange, aggressiveChecks) { - return IncrementalParser.updateSourceFile(sourceFile, newText, textChangeRange, aggressiveChecks); - } - ts.updateSourceFile = updateSourceFile; - /* @internal */ - function parseIsolatedJSDocComment(content, start, length) { - return Parser.JSDocParser.parseIsolatedJSDocComment(content, start, length); - } - ts.parseIsolatedJSDocComment = parseIsolatedJSDocComment; - /* @internal */ - // Exposed only for testing. - function parseJSDocTypeExpressionForTests(content, start, length) { - return Parser.JSDocParser.parseJSDocTypeExpressionForTests(content, start, length); - } - ts.parseJSDocTypeExpressionForTests = parseJSDocTypeExpressionForTests; - // Implement the parser as a singleton module. We do this for perf reasons because creating - // parser instances can actually be expensive enough to impact us on projects with many source - // files. - var Parser; - (function (Parser) { - // Share a single scanner across all calls to parse a source file. This helps speed things - // up by avoiding the cost of creating/compiling scanners over and over again. - var scanner = ts.createScanner(2 /* Latest */, true); - var disallowInAndDecoratorContext = 2 /* DisallowIn */ | 16 /* Decorator */; - var sourceFile; - var parseDiagnostics; - var syntaxCursor; - var token; - var sourceText; - var nodeCount; - var identifiers; - var identifierCount; - var parsingContext; - // Flags that dictate what parsing context we're in. For example: - // Whether or not we are in strict parsing mode. All that changes in strict parsing mode is - // that some tokens that would be considered identifiers may be considered keywords. - // - // When adding more parser context flags, consider which is the more common case that the - // flag will be in. This should be the 'false' state for that flag. The reason for this is - // that we don't store data in our nodes unless the value is in the *non-default* state. So, - // for example, more often than code 'allows-in' (or doesn't 'disallow-in'). We opt for - // 'disallow-in' set to 'false'. Otherwise, if we had 'allowsIn' set to 'true', then almost - // all nodes would need extra state on them to store this info. - // - // Note: 'allowIn' and 'allowYield' track 1:1 with the [in] and [yield] concepts in the ES6 - // grammar specification. - // - // An important thing about these context concepts. By default they are effectively inherited - // while parsing through every grammar production. i.e. if you don't change them, then when - // you parse a sub-production, it will have the same context values as the parent production. - // This is great most of the time. After all, consider all the 'expression' grammar productions - // and how nearly all of them pass along the 'in' and 'yield' context values: - // - // EqualityExpression[In, Yield] : - // RelationalExpression[?In, ?Yield] - // EqualityExpression[?In, ?Yield] == RelationalExpression[?In, ?Yield] - // EqualityExpression[?In, ?Yield] != RelationalExpression[?In, ?Yield] - // EqualityExpression[?In, ?Yield] === RelationalExpression[?In, ?Yield] - // EqualityExpression[?In, ?Yield] !== RelationalExpression[?In, ?Yield] - // - // Where you have to be careful is then understanding what the points are in the grammar - // where the values are *not* passed along. For example: - // - // SingleNameBinding[Yield,GeneratorParameter] - // [+GeneratorParameter]BindingIdentifier[Yield] Initializer[In]opt - // [~GeneratorParameter]BindingIdentifier[?Yield]Initializer[In, ?Yield]opt - // - // Here this is saying that if the GeneratorParameter context flag is set, that we should - // explicitly set the 'yield' context flag to false before calling into the BindingIdentifier - // and we should explicitly unset the 'yield' context flag before calling into the Initializer. - // production. Conversely, if the GeneratorParameter context flag is not set, then we - // should leave the 'yield' context flag alone. - // - // Getting this all correct is tricky and requires careful reading of the grammar to - // understand when these values should be changed versus when they should be inherited. - // - // Note: it should not be necessary to save/restore these flags during speculative/lookahead - // parsing. These context flags are naturally stored and restored through normal recursive - // descent parsing and unwinding. - var contextFlags; - // Whether or not we've had a parse error since creating the last AST node. If we have - // encountered an error, it will be stored on the next AST node we create. Parse errors - // can be broken down into three categories: - // - // 1) An error that occurred during scanning. For example, an unterminated literal, or a - // character that was completely not understood. - // - // 2) A token was expected, but was not present. This type of error is commonly produced - // by the 'parseExpected' function. - // - // 3) A token was present that no parsing function was able to consume. This type of error - // only occurs in the 'abortParsingListOrMoveToNextToken' function when the parser - // decides to skip the token. - // - // In all of these cases, we want to mark the next node as having had an error before it. - // With this mark, we can know in incremental settings if this node can be reused, or if - // we have to reparse it. If we don't keep this information around, we may just reuse the - // node. in that event we would then not produce the same errors as we did before, causing - // significant confusion problems. - // - // Note: it is necessary that this value be saved/restored during speculative/lookahead - // parsing. During lookahead parsing, we will often create a node. That node will have - // this value attached, and then this value will be set back to 'false'. If we decide to - // rewind, we must get back to the same value we had prior to the lookahead. - // - // Note: any errors at the end of the file that do not precede a regular node, should get - // attached to the EOF token. - var parseErrorBeforeNextFinishedNode = false; - function parseSourceFile(fileName, _sourceText, languageVersion, _syntaxCursor, setParentNodes) { - initializeState(fileName, _sourceText, languageVersion, _syntaxCursor); - var result = parseSourceFileWorker(fileName, languageVersion, setParentNodes); - clearState(); - return result; - } - Parser.parseSourceFile = parseSourceFile; - function initializeState(fileName, _sourceText, languageVersion, _syntaxCursor) { - sourceText = _sourceText; - syntaxCursor = _syntaxCursor; - parseDiagnostics = []; - parsingContext = 0; - identifiers = {}; - identifierCount = 0; - nodeCount = 0; - contextFlags = ts.isJavaScript(fileName) ? 64 /* JavaScriptFile */ : 0 /* None */; - parseErrorBeforeNextFinishedNode = false; - // Initialize and prime the scanner before parsing the source elements. - scanner.setText(sourceText); - scanner.setOnError(scanError); - scanner.setScriptTarget(languageVersion); - } - function clearState() { - // Clear out the text the scanner is pointing at, so it doesn't keep anything alive unnecessarily. - scanner.setText(""); - scanner.setOnError(undefined); - // Clear any data. We don't want to accidently hold onto it for too long. - parseDiagnostics = undefined; - sourceFile = undefined; - identifiers = undefined; - syntaxCursor = undefined; - sourceText = undefined; - } - function parseSourceFileWorker(fileName, languageVersion, setParentNodes) { - sourceFile = createSourceFile(fileName, languageVersion); - // Prime the scanner. - token = nextToken(); - processReferenceComments(sourceFile); - sourceFile.statements = parseList(0 /* SourceElements */, true, parseStatement); - ts.Debug.assert(token === 1 /* EndOfFileToken */); - sourceFile.endOfFileToken = parseTokenNode(); - setExternalModuleIndicator(sourceFile); - sourceFile.nodeCount = nodeCount; - sourceFile.identifierCount = identifierCount; - sourceFile.identifiers = identifiers; - sourceFile.parseDiagnostics = parseDiagnostics; - if (setParentNodes) { - fixupParentReferences(sourceFile); - } - // If this is a javascript file, proactively see if we can get JSDoc comments for - // relevant nodes in the file. We'll use these to provide typing informaion if they're - // available. - if (ts.isJavaScript(fileName)) { - addJSDocComments(); - } - return sourceFile; - } - function addJSDocComments() { - forEachChild(sourceFile, visit); - return; - function visit(node) { - // Add additional cases as necessary depending on how we see JSDoc comments used - // in the wild. - switch (node.kind) { - case 183 /* VariableStatement */: - case 203 /* FunctionDeclaration */: - case 131 /* Parameter */: - addJSDocComment(node); - } - forEachChild(node, visit); - } - } - function addJSDocComment(node) { - var comments = ts.getLeadingCommentRangesOfNode(node, sourceFile); - if (comments) { - for (var _i = 0; _i < comments.length; _i++) { - var comment = comments[_i]; - var jsDocComment = JSDocParser.parseJSDocComment(node, comment.pos, comment.end - comment.pos); - if (jsDocComment) { - node.jsDocComment = jsDocComment; - } - } - } - } - function fixupParentReferences(sourceFile) { - // normally parent references are set during binding. However, for clients that only need - // a syntax tree, and no semantic features, then the binding process is an unnecessary - // overhead. This functions allows us to set all the parents, without all the expense of - // binding. - var parent = sourceFile; - forEachChild(sourceFile, visitNode); - return; - function visitNode(n) { - // walk down setting parents that differ from the parent we think it should be. This - // allows us to quickly bail out of setting parents for subtrees during incremental - // parsing - if (n.parent !== parent) { - n.parent = parent; - var saveParent = parent; - parent = n; - forEachChild(n, visitNode); - parent = saveParent; - } - } - } - Parser.fixupParentReferences = fixupParentReferences; - function createSourceFile(fileName, languageVersion) { - var sourceFile = createNode(230 /* SourceFile */, 0); - sourceFile.pos = 0; - sourceFile.end = sourceText.length; - sourceFile.text = sourceText; - sourceFile.bindDiagnostics = []; - sourceFile.languageVersion = languageVersion; - sourceFile.fileName = ts.normalizePath(fileName); - sourceFile.flags = ts.fileExtensionIs(sourceFile.fileName, ".d.ts") ? 2048 /* DeclarationFile */ : 0; - return sourceFile; - } - function setContextFlag(val, flag) { - if (val) { - contextFlags |= flag; - } - else { - contextFlags &= ~flag; - } - } - function setStrictModeContext(val) { - setContextFlag(val, 1 /* StrictMode */); - } - function setDisallowInContext(val) { - setContextFlag(val, 2 /* DisallowIn */); - } - function setYieldContext(val) { - setContextFlag(val, 4 /* Yield */); - } - function setGeneratorParameterContext(val) { - setContextFlag(val, 8 /* GeneratorParameter */); - } - function setDecoratorContext(val) { - setContextFlag(val, 16 /* Decorator */); - } - function doOutsideOfContext(flags, func) { - var currentContextFlags = contextFlags & flags; - if (currentContextFlags) { - setContextFlag(false, currentContextFlags); - var result = func(); - setContextFlag(true, currentContextFlags); - return result; - } - // no need to do anything special as we are not in any of the requested contexts - return func(); - } - function allowInAnd(func) { - if (contextFlags & 2 /* DisallowIn */) { - setDisallowInContext(false); - var result = func(); - setDisallowInContext(true); - return result; - } - // no need to do anything special if 'in' is already allowed. - return func(); - } - function disallowInAnd(func) { - if (contextFlags & 2 /* DisallowIn */) { - // no need to do anything special if 'in' is already disallowed. - return func(); - } - setDisallowInContext(true); - var result = func(); - setDisallowInContext(false); - return result; - } - function doInYieldContext(func) { - if (contextFlags & 4 /* Yield */) { - // no need to do anything special if we're already in the [Yield] context. - return func(); - } - setYieldContext(true); - var result = func(); - setYieldContext(false); - return result; - } - function doOutsideOfYieldContext(func) { - if (contextFlags & 4 /* Yield */) { - setYieldContext(false); - var result = func(); - setYieldContext(true); - return result; - } - // no need to do anything special if we're not in the [Yield] context. - return func(); - } - function doInDecoratorContext(func) { - if (contextFlags & 16 /* Decorator */) { - // no need to do anything special if we're already in the [Decorator] context. - return func(); - } - setDecoratorContext(true); - var result = func(); - setDecoratorContext(false); - return result; - } - function inYieldContext() { - return (contextFlags & 4 /* Yield */) !== 0; - } - function inStrictModeContext() { - return (contextFlags & 1 /* StrictMode */) !== 0; - } - function inGeneratorParameterContext() { - return (contextFlags & 8 /* GeneratorParameter */) !== 0; - } - function inDisallowInContext() { - return (contextFlags & 2 /* DisallowIn */) !== 0; - } - function inDecoratorContext() { - return (contextFlags & 16 /* Decorator */) !== 0; - } - function parseErrorAtCurrentToken(message, arg0) { - var start = scanner.getTokenPos(); - var length = scanner.getTextPos() - start; - parseErrorAtPosition(start, length, message, arg0); - } - function parseErrorAtPosition(start, length, message, arg0) { - // Don't report another error if it would just be at the same position as the last error. - var lastError = ts.lastOrUndefined(parseDiagnostics); - if (!lastError || start !== lastError.start) { - parseDiagnostics.push(ts.createFileDiagnostic(sourceFile, start, length, message, arg0)); - } - // Mark that we've encountered an error. We'll set an appropriate bit on the next - // node we finish so that it can't be reused incrementally. - parseErrorBeforeNextFinishedNode = true; - } - function scanError(message, length) { - var pos = scanner.getTextPos(); - parseErrorAtPosition(pos, length || 0, message); - } - function getNodePos() { - return scanner.getStartPos(); - } - function getNodeEnd() { - return scanner.getStartPos(); - } - function nextToken() { - return token = scanner.scan(); - } - function getTokenPos(pos) { - return ts.skipTrivia(sourceText, pos); - } - function reScanGreaterToken() { - return token = scanner.reScanGreaterToken(); - } - function reScanSlashToken() { - return token = scanner.reScanSlashToken(); - } - function reScanTemplateToken() { - return token = scanner.reScanTemplateToken(); - } - function speculationHelper(callback, isLookAhead) { - // Keep track of the state we'll need to rollback to if lookahead fails (or if the - // caller asked us to always reset our state). - var saveToken = token; - var saveParseDiagnosticsLength = parseDiagnostics.length; - var saveParseErrorBeforeNextFinishedNode = parseErrorBeforeNextFinishedNode; - // Note: it is not actually necessary to save/restore the context flags here. That's - // because the saving/restorating of these flags happens naturally through the recursive - // descent nature of our parser. However, we still store this here just so we can - // assert that that invariant holds. - var saveContextFlags = contextFlags; - // If we're only looking ahead, then tell the scanner to only lookahead as well. - // Otherwise, if we're actually speculatively parsing, then tell the scanner to do the - // same. - var result = isLookAhead - ? scanner.lookAhead(callback) - : scanner.tryScan(callback); - ts.Debug.assert(saveContextFlags === contextFlags); - // If our callback returned something 'falsy' or we're just looking ahead, - // then unconditionally restore us to where we were. - if (!result || isLookAhead) { - token = saveToken; - parseDiagnostics.length = saveParseDiagnosticsLength; - parseErrorBeforeNextFinishedNode = saveParseErrorBeforeNextFinishedNode; - } - return result; - } - // Invokes the provided callback then unconditionally restores the parser to the state it - // was in immediately prior to invoking the callback. The result of invoking the callback - // is returned from this function. - function lookAhead(callback) { - return speculationHelper(callback, true); - } - // Invokes the provided callback. If the callback returns something falsy, then it restores - // the parser to the state it was in immediately prior to invoking the callback. If the - // callback returns something truthy, then the parser state is not rolled back. The result - // of invoking the callback is returned from this function. - function tryParse(callback) { - return speculationHelper(callback, false); - } - // Ignore strict mode flag because we will report an error in type checker instead. - function isIdentifier() { - if (token === 65 /* Identifier */) { - return true; - } - // If we have a 'yield' keyword, and we're in the [yield] context, then 'yield' is - // considered a keyword and is not an identifier. - if (token === 110 /* YieldKeyword */ && inYieldContext()) { - return false; - } - return token > 101 /* LastReservedWord */; - } - function parseExpected(kind, diagnosticMessage) { - if (token === kind) { - nextToken(); - return true; - } - // Report specific message if provided with one. Otherwise, report generic fallback message. - if (diagnosticMessage) { - parseErrorAtCurrentToken(diagnosticMessage); - } - else { - parseErrorAtCurrentToken(ts.Diagnostics._0_expected, ts.tokenToString(kind)); - } - return false; - } - function parseOptional(t) { - if (token === t) { - nextToken(); - return true; - } - return false; - } - function parseOptionalToken(t) { - if (token === t) { - return parseTokenNode(); - } - return undefined; - } - function parseExpectedToken(t, reportAtCurrentPosition, diagnosticMessage, arg0) { - return parseOptionalToken(t) || - createMissingNode(t, reportAtCurrentPosition, diagnosticMessage, arg0); - } - function parseTokenNode() { - var node = createNode(token); - nextToken(); - return finishNode(node); - } - function canParseSemicolon() { - // If there's a real semicolon, then we can always parse it out. - if (token === 22 /* SemicolonToken */) { - return true; - } - // We can parse out an optional semicolon in ASI cases in the following cases. - return token === 15 /* CloseBraceToken */ || token === 1 /* EndOfFileToken */ || scanner.hasPrecedingLineBreak(); - } - function parseSemicolon() { - if (canParseSemicolon()) { - if (token === 22 /* SemicolonToken */) { - // consume the semicolon if it was explicitly provided. - nextToken(); - } - return true; - } - else { - return parseExpected(22 /* SemicolonToken */); - } - } - function createNode(kind, pos) { - nodeCount++; - var node = new (nodeConstructors[kind] || (nodeConstructors[kind] = ts.objectAllocator.getNodeConstructor(kind)))(); - if (!(pos >= 0)) { - pos = scanner.getStartPos(); - } - node.pos = pos; - node.end = pos; - return node; - } - function finishNode(node, end) { - node.end = end === undefined ? scanner.getStartPos() : end; - if (contextFlags) { - node.parserContextFlags = contextFlags; - } - // Keep track on the node if we encountered an error while parsing it. If we did, then - // we cannot reuse the node incrementally. Once we've marked this node, clear out the - // flag so that we don't mark any subsequent nodes. - if (parseErrorBeforeNextFinishedNode) { - parseErrorBeforeNextFinishedNode = false; - node.parserContextFlags |= 32 /* ThisNodeHasError */; - } - return node; - } - function createMissingNode(kind, reportAtCurrentPosition, diagnosticMessage, arg0) { - if (reportAtCurrentPosition) { - parseErrorAtPosition(scanner.getStartPos(), 0, diagnosticMessage, arg0); - } - else { - parseErrorAtCurrentToken(diagnosticMessage, arg0); - } - var result = createNode(kind, scanner.getStartPos()); - result.text = ""; - return finishNode(result); - } - function internIdentifier(text) { - text = ts.escapeIdentifier(text); - return ts.hasProperty(identifiers, text) ? identifiers[text] : (identifiers[text] = text); - } - // An identifier that starts with two underscores has an extra underscore character prepended to it to avoid issues - // with magic property names like '__proto__'. The 'identifiers' object is used to share a single string instance for - // each identifier in order to reduce memory consumption. - function createIdentifier(isIdentifier, diagnosticMessage) { - identifierCount++; - if (isIdentifier) { - var node = createNode(65 /* Identifier */); - // Store original token kind if it is not just an Identifier so we can report appropriate error later in type checker - if (token !== 65 /* Identifier */) { - node.originalKeywordKind = token; - } - node.text = internIdentifier(scanner.getTokenValue()); - nextToken(); - return finishNode(node); - } - return createMissingNode(65 /* Identifier */, false, diagnosticMessage || ts.Diagnostics.Identifier_expected); - } - function parseIdentifier(diagnosticMessage) { - return createIdentifier(isIdentifier(), diagnosticMessage); - } - function parseIdentifierName() { - return createIdentifier(isIdentifierOrKeyword()); - } - function isLiteralPropertyName() { - return isIdentifierOrKeyword() || - token === 8 /* StringLiteral */ || - token === 7 /* NumericLiteral */; - } - function parsePropertyNameWorker(allowComputedPropertyNames) { - if (token === 8 /* StringLiteral */ || token === 7 /* NumericLiteral */) { - return parseLiteralNode(true); - } - if (allowComputedPropertyNames && token === 18 /* OpenBracketToken */) { - return parseComputedPropertyName(); - } - return parseIdentifierName(); - } - function parsePropertyName() { - return parsePropertyNameWorker(true); - } - function parseSimplePropertyName() { - return parsePropertyNameWorker(false); - } - function isSimplePropertyName() { - return token === 8 /* StringLiteral */ || token === 7 /* NumericLiteral */ || isIdentifierOrKeyword(); - } - function parseComputedPropertyName() { - // PropertyName[Yield,GeneratorParameter] : - // LiteralPropertyName - // [+GeneratorParameter] ComputedPropertyName - // [~GeneratorParameter] ComputedPropertyName[?Yield] - // - // ComputedPropertyName[Yield] : - // [ AssignmentExpression[In, ?Yield] ] - // - var node = createNode(129 /* ComputedPropertyName */); - parseExpected(18 /* OpenBracketToken */); - // We parse any expression (including a comma expression). But the grammar - // says that only an assignment expression is allowed, so the grammar checker - // will error if it sees a comma expression. - var yieldContext = inYieldContext(); - if (inGeneratorParameterContext()) { - setYieldContext(false); - } - node.expression = allowInAnd(parseExpression); - if (inGeneratorParameterContext()) { - setYieldContext(yieldContext); - } - parseExpected(19 /* CloseBracketToken */); - return finishNode(node); - } - function parseContextualModifier(t) { - return token === t && tryParse(nextTokenCanFollowModifier); - } - function nextTokenCanFollowModifier() { - if (token === 70 /* ConstKeyword */) { - // 'const' is only a modifier if followed by 'enum'. - return nextToken() === 77 /* EnumKeyword */; - } - if (token === 78 /* ExportKeyword */) { - nextToken(); - if (token === 73 /* DefaultKeyword */) { - return lookAhead(nextTokenIsClassOrFunction); - } - return token !== 35 /* AsteriskToken */ && token !== 14 /* OpenBraceToken */ && canFollowModifier(); - } - if (token === 73 /* DefaultKeyword */) { - return nextTokenIsClassOrFunction(); - } - nextToken(); - return canFollowModifier(); - } - function parseAnyContextualModifier() { - return ts.isModifier(token) && tryParse(nextTokenCanFollowModifier); - } - function canFollowModifier() { - return token === 18 /* OpenBracketToken */ - || token === 14 /* OpenBraceToken */ - || token === 35 /* AsteriskToken */ - || isLiteralPropertyName(); - } - function nextTokenIsClassOrFunction() { - nextToken(); - return token === 69 /* ClassKeyword */ || token === 83 /* FunctionKeyword */; - } - // True if positioned at the start of a list element - function isListElement(parsingContext, inErrorRecovery) { - var node = currentNode(parsingContext); - if (node) { - return true; - } - switch (parsingContext) { - case 0 /* SourceElements */: - case 1 /* BlockStatements */: - case 3 /* SwitchClauseStatements */: - // If we're in error recovery, then we don't want to treat ';' as an empty statement. - // The problem is that ';' can show up in far too many contexts, and if we see one - // and assume it's a statement, then we may bail out inappropriately from whatever - // we're parsing. For example, if we have a semicolon in the middle of a class, then - // we really don't want to assume the class is over and we're on a statement in the - // outer module. We just want to consume and move on. - return !(token === 22 /* SemicolonToken */ && inErrorRecovery) && isStartOfStatement(); - case 2 /* SwitchClauses */: - return token === 67 /* CaseKeyword */ || token === 73 /* DefaultKeyword */; - case 4 /* TypeMembers */: - return isStartOfTypeMember(); - case 5 /* ClassMembers */: - // We allow semicolons as class elements (as specified by ES6) as long as we're - // not in error recovery. If we're in error recovery, we don't want an errant - // semicolon to be treated as a class member (since they're almost always used - // for statements. - return lookAhead(isClassMemberStart) || (token === 22 /* SemicolonToken */ && !inErrorRecovery); - case 6 /* EnumMembers */: - // Include open bracket computed properties. This technically also lets in indexers, - // which would be a candidate for improved error reporting. - return token === 18 /* OpenBracketToken */ || isLiteralPropertyName(); - case 12 /* ObjectLiteralMembers */: - return token === 18 /* OpenBracketToken */ || token === 35 /* AsteriskToken */ || isLiteralPropertyName(); - case 9 /* ObjectBindingElements */: - return isLiteralPropertyName(); - case 7 /* HeritageClauseElement */: - // If we see { } then only consume it as an expression if it is followed by , or { - // That way we won't consume the body of a class in its heritage clause. - if (token === 14 /* OpenBraceToken */) { - return lookAhead(isValidHeritageClauseObjectLiteral); - } - if (!inErrorRecovery) { - return isStartOfLeftHandSideExpression() && !isHeritageClauseExtendsOrImplementsKeyword(); - } - else { - // If we're in error recovery we tighten up what we're willing to match. - // That way we don't treat something like "this" as a valid heritage clause - // element during recovery. - return isIdentifier() && !isHeritageClauseExtendsOrImplementsKeyword(); - } - case 8 /* VariableDeclarations */: - return isIdentifierOrPattern(); - case 10 /* ArrayBindingElements */: - return token === 23 /* CommaToken */ || token === 21 /* DotDotDotToken */ || isIdentifierOrPattern(); - case 15 /* TypeParameters */: - return isIdentifier(); - case 11 /* ArgumentExpressions */: - case 13 /* ArrayLiteralMembers */: - return token === 23 /* CommaToken */ || token === 21 /* DotDotDotToken */ || isStartOfExpression(); - case 14 /* Parameters */: - return isStartOfParameter(); - case 16 /* TypeArguments */: - case 17 /* TupleElementTypes */: - return token === 23 /* CommaToken */ || isStartOfType(); - case 18 /* HeritageClauses */: - return isHeritageClause(); - case 19 /* ImportOrExportSpecifiers */: - return isIdentifierOrKeyword(); - case 20 /* JSDocFunctionParameters */: - case 21 /* JSDocTypeArguments */: - case 23 /* JSDocTupleTypes */: - return JSDocParser.isJSDocType(); - case 22 /* JSDocRecordMembers */: - return isSimplePropertyName(); - } - ts.Debug.fail("Non-exhaustive case in 'isListElement'."); - } - function isValidHeritageClauseObjectLiteral() { - ts.Debug.assert(token === 14 /* OpenBraceToken */); - if (nextToken() === 15 /* CloseBraceToken */) { - // if we see "extends {}" then only treat the {} as what we're extending (and not - // the class body) if we have: - // - // extends {} { - // extends {}, - // extends {} extends - // extends {} implements - var next = nextToken(); - return next === 23 /* CommaToken */ || next === 14 /* OpenBraceToken */ || next === 79 /* ExtendsKeyword */ || next === 102 /* ImplementsKeyword */; - } - return true; - } - function nextTokenIsIdentifier() { - nextToken(); - return isIdentifier(); - } - function isHeritageClauseExtendsOrImplementsKeyword() { - if (token === 102 /* ImplementsKeyword */ || - token === 79 /* ExtendsKeyword */) { - return lookAhead(nextTokenIsStartOfExpression); - } - return false; - } - function nextTokenIsStartOfExpression() { - nextToken(); - return isStartOfExpression(); - } - // True if positioned at a list terminator - function isListTerminator(kind) { - if (token === 1 /* EndOfFileToken */) { - // Being at the end of the file ends all lists. - return true; - } - switch (kind) { - case 1 /* BlockStatements */: - case 2 /* SwitchClauses */: - case 4 /* TypeMembers */: - case 5 /* ClassMembers */: - case 6 /* EnumMembers */: - case 12 /* ObjectLiteralMembers */: - case 9 /* ObjectBindingElements */: - case 19 /* ImportOrExportSpecifiers */: - return token === 15 /* CloseBraceToken */; - case 3 /* SwitchClauseStatements */: - return token === 15 /* CloseBraceToken */ || token === 67 /* CaseKeyword */ || token === 73 /* DefaultKeyword */; - case 7 /* HeritageClauseElement */: - return token === 14 /* OpenBraceToken */ || token === 79 /* ExtendsKeyword */ || token === 102 /* ImplementsKeyword */; - case 8 /* VariableDeclarations */: - return isVariableDeclaratorListTerminator(); - case 15 /* TypeParameters */: - // Tokens other than '>' are here for better error recovery - return token === 25 /* GreaterThanToken */ || token === 16 /* OpenParenToken */ || token === 14 /* OpenBraceToken */ || token === 79 /* ExtendsKeyword */ || token === 102 /* ImplementsKeyword */; - case 11 /* ArgumentExpressions */: - // Tokens other than ')' are here for better error recovery - return token === 17 /* CloseParenToken */ || token === 22 /* SemicolonToken */; - case 13 /* ArrayLiteralMembers */: - case 17 /* TupleElementTypes */: - case 10 /* ArrayBindingElements */: - return token === 19 /* CloseBracketToken */; - case 14 /* Parameters */: - // Tokens other than ')' and ']' (the latter for index signatures) are here for better error recovery - return token === 17 /* CloseParenToken */ || token === 19 /* CloseBracketToken */ /*|| token === SyntaxKind.OpenBraceToken*/; - case 16 /* TypeArguments */: - // Tokens other than '>' are here for better error recovery - return token === 25 /* GreaterThanToken */ || token === 16 /* OpenParenToken */; - case 18 /* HeritageClauses */: - return token === 14 /* OpenBraceToken */ || token === 15 /* CloseBraceToken */; - case 20 /* JSDocFunctionParameters */: - return token === 17 /* CloseParenToken */ || token === 51 /* ColonToken */ || token === 15 /* CloseBraceToken */; - case 21 /* JSDocTypeArguments */: - return token === 25 /* GreaterThanToken */ || token === 15 /* CloseBraceToken */; - case 23 /* JSDocTupleTypes */: - return token === 19 /* CloseBracketToken */ || token === 15 /* CloseBraceToken */; - case 22 /* JSDocRecordMembers */: - return token === 15 /* CloseBraceToken */; - } - } - function isVariableDeclaratorListTerminator() { - // If we can consume a semicolon (either explicitly, or with ASI), then consider us done - // with parsing the list of variable declarators. - if (canParseSemicolon()) { - return true; - } - // in the case where we're parsing the variable declarator of a 'for-in' statement, we - // are done if we see an 'in' keyword in front of us. Same with for-of - if (isInOrOfKeyword(token)) { - return true; - } - // ERROR RECOVERY TWEAK: - // For better error recovery, if we see an '=>' then we just stop immediately. We've got an - // arrow function here and it's going to be very unlikely that we'll resynchronize and get - // another variable declaration. - if (token === 32 /* EqualsGreaterThanToken */) { - return true; - } - // Keep trying to parse out variable declarators. - return false; - } - // True if positioned at element or terminator of the current list or any enclosing list - function isInSomeParsingContext() { - for (var kind = 0; kind < 24 /* Count */; kind++) { - if (parsingContext & (1 << kind)) { - if (isListElement(kind, true) || isListTerminator(kind)) { - return true; - } - } - } - return false; - } - // Parses a list of elements - function parseList(kind, checkForStrictMode, parseElement) { - var saveParsingContext = parsingContext; - parsingContext |= 1 << kind; - var result = []; - result.pos = getNodePos(); - var savedStrictModeContext = inStrictModeContext(); - while (!isListTerminator(kind)) { - if (isListElement(kind, false)) { - var element = parseListElement(kind, parseElement); - result.push(element); - // test elements only if we are not already in strict mode - if (checkForStrictMode && !inStrictModeContext()) { - if (ts.isPrologueDirective(element)) { - if (isUseStrictPrologueDirective(element)) { - setStrictModeContext(true); - checkForStrictMode = false; - } - } - else { - checkForStrictMode = false; - } - } - continue; - } - if (abortParsingListOrMoveToNextToken(kind)) { - break; - } - } - setStrictModeContext(savedStrictModeContext); - result.end = getNodeEnd(); - parsingContext = saveParsingContext; - return result; - } - /// Should be called only on prologue directives (isPrologueDirective(node) should be true) - function isUseStrictPrologueDirective(node) { - ts.Debug.assert(ts.isPrologueDirective(node)); - var nodeText = ts.getTextOfNodeFromSourceText(sourceText, node.expression); - // Note: the node text must be exactly "use strict" or 'use strict'. It is not ok for the - // string to contain unicode escapes (as per ES5). - return nodeText === '"use strict"' || nodeText === "'use strict'"; - } - function parseListElement(parsingContext, parseElement) { - var node = currentNode(parsingContext); - if (node) { - return consumeNode(node); - } - return parseElement(); - } - function currentNode(parsingContext) { - // If there is an outstanding parse error that we've encountered, but not attached to - // some node, then we cannot get a node from the old source tree. This is because we - // want to mark the next node we encounter as being unusable. - // - // Note: This may be too conservative. Perhaps we could reuse the node and set the bit - // on it (or its leftmost child) as having the error. For now though, being conservative - // is nice and likely won't ever affect perf. - if (parseErrorBeforeNextFinishedNode) { - return undefined; - } - if (!syntaxCursor) { - // if we don't have a cursor, we could never return a node from the old tree. - return undefined; - } - var node = syntaxCursor.currentNode(scanner.getStartPos()); - // Can't reuse a missing node. - if (ts.nodeIsMissing(node)) { - return undefined; - } - // Can't reuse a node that intersected the change range. - if (node.intersectsChange) { - return undefined; - } - // Can't reuse a node that contains a parse error. This is necessary so that we - // produce the same set of errors again. - if (ts.containsParseError(node)) { - return undefined; - } - // We can only reuse a node if it was parsed under the same strict mode that we're - // currently in. i.e. if we originally parsed a node in non-strict mode, but then - // the user added 'using strict' at the top of the file, then we can't use that node - // again as the presense of strict mode may cause us to parse the tokens in the file - // differetly. - // - // Note: we *can* reuse tokens when the strict mode changes. That's because tokens - // are unaffected by strict mode. It's just the parser will decide what to do with it - // differently depending on what mode it is in. - // - // This also applies to all our other context flags as well. - var nodeContextFlags = node.parserContextFlags & 63 /* ParserGeneratedFlags */; - if (nodeContextFlags !== contextFlags) { - return undefined; - } - // Ok, we have a node that looks like it could be reused. Now verify that it is valid - // in the currest list parsing context that we're currently at. - if (!canReuseNode(node, parsingContext)) { - return undefined; - } - return node; - } - function consumeNode(node) { - // Move the scanner so it is after the node we just consumed. - scanner.setTextPos(node.end); - nextToken(); - return node; - } - function canReuseNode(node, parsingContext) { - switch (parsingContext) { - case 5 /* ClassMembers */: - return isReusableClassMember(node); - case 2 /* SwitchClauses */: - return isReusableSwitchClause(node); - case 0 /* SourceElements */: - case 1 /* BlockStatements */: - case 3 /* SwitchClauseStatements */: - return isReusableStatement(node); - case 6 /* EnumMembers */: - return isReusableEnumMember(node); - case 4 /* TypeMembers */: - return isReusableTypeMember(node); - case 8 /* VariableDeclarations */: - return isReusableVariableDeclaration(node); - case 14 /* Parameters */: - return isReusableParameter(node); - // Any other lists we do not care about reusing nodes in. But feel free to add if - // you can do so safely. Danger areas involve nodes that may involve speculative - // parsing. If speculative parsing is involved with the node, then the range the - // parser reached while looking ahead might be in the edited range (see the example - // in canReuseVariableDeclaratorNode for a good case of this). - case 18 /* HeritageClauses */: - // This would probably be safe to reuse. There is no speculative parsing with - // heritage clauses. - case 15 /* TypeParameters */: - // This would probably be safe to reuse. There is no speculative parsing with - // type parameters. Note that that's because type *parameters* only occur in - // unambiguous *type* contexts. While type *arguments* occur in very ambiguous - // *expression* contexts. - case 17 /* TupleElementTypes */: - // This would probably be safe to reuse. There is no speculative parsing with - // tuple types. - // Technically, type argument list types are probably safe to reuse. While - // speculative parsing is involved with them (since type argument lists are only - // produced from speculative parsing a < as a type argument list), we only have - // the types because speculative parsing succeeded. Thus, the lookahead never - // went past the end of the list and rewound. - case 16 /* TypeArguments */: - // Note: these are almost certainly not safe to ever reuse. Expressions commonly - // need a large amount of lookahead, and we should not reuse them as they may - // have actually intersected the edit. - case 11 /* ArgumentExpressions */: - // This is not safe to reuse for the same reason as the 'AssignmentExpression' - // cases. i.e. a property assignment may end with an expression, and thus might - // have lookahead far beyond it's old node. - case 12 /* ObjectLiteralMembers */: - // This is probably not safe to reuse. There can be speculative parsing with - // type names in a heritage clause. There can be generic names in the type - // name list, and there can be left hand side expressions (which can have type - // arguments.) - case 7 /* HeritageClauseElement */: - } - return false; - } - function isReusableClassMember(node) { - if (node) { - switch (node.kind) { - case 137 /* Constructor */: - case 142 /* IndexSignature */: - case 136 /* MethodDeclaration */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 134 /* PropertyDeclaration */: - case 181 /* SemicolonClassElement */: - return true; - } - } - return false; - } - function isReusableSwitchClause(node) { - if (node) { - switch (node.kind) { - case 223 /* CaseClause */: - case 224 /* DefaultClause */: - return true; - } - } - return false; - } - function isReusableStatement(node) { - if (node) { - switch (node.kind) { - case 203 /* FunctionDeclaration */: - case 183 /* VariableStatement */: - case 182 /* Block */: - case 186 /* IfStatement */: - case 185 /* ExpressionStatement */: - case 198 /* ThrowStatement */: - case 194 /* ReturnStatement */: - case 196 /* SwitchStatement */: - case 193 /* BreakStatement */: - case 192 /* ContinueStatement */: - case 190 /* ForInStatement */: - case 191 /* ForOfStatement */: - case 189 /* ForStatement */: - case 188 /* WhileStatement */: - case 195 /* WithStatement */: - case 184 /* EmptyStatement */: - case 199 /* TryStatement */: - case 197 /* LabeledStatement */: - case 187 /* DoStatement */: - case 200 /* DebuggerStatement */: - case 212 /* ImportDeclaration */: - case 211 /* ImportEqualsDeclaration */: - case 218 /* ExportDeclaration */: - case 217 /* ExportAssignment */: - case 208 /* ModuleDeclaration */: - case 204 /* ClassDeclaration */: - case 205 /* InterfaceDeclaration */: - case 207 /* EnumDeclaration */: - case 206 /* TypeAliasDeclaration */: - return true; - } - } - return false; - } - function isReusableEnumMember(node) { - return node.kind === 229 /* EnumMember */; - } - function isReusableTypeMember(node) { - if (node) { - switch (node.kind) { - case 141 /* ConstructSignature */: - case 135 /* MethodSignature */: - case 142 /* IndexSignature */: - case 133 /* PropertySignature */: - case 140 /* CallSignature */: - return true; - } - } - return false; - } - function isReusableVariableDeclaration(node) { - if (node.kind !== 201 /* VariableDeclaration */) { - return false; - } - // Very subtle incremental parsing bug. Consider the following code: - // - // let v = new List < A, B - // - // This is actually legal code. It's a list of variable declarators "v = new List() - // - // then we have a problem. "v = new List= 0) { - // Always preserve a trailing comma by marking it on the NodeArray - result.hasTrailingComma = true; - } - result.end = getNodeEnd(); - parsingContext = saveParsingContext; - return result; - } - function createMissingList() { - var pos = getNodePos(); - var result = []; - result.pos = pos; - result.end = pos; - return result; - } - function parseBracketedList(kind, parseElement, open, close) { - if (parseExpected(open)) { - var result = parseDelimitedList(kind, parseElement); - parseExpected(close); - return result; - } - return createMissingList(); - } - // The allowReservedWords parameter controls whether reserved words are permitted after the first dot - function parseEntityName(allowReservedWords, diagnosticMessage) { - var entity = parseIdentifier(diagnosticMessage); - while (parseOptional(20 /* DotToken */)) { - var node = createNode(128 /* QualifiedName */, entity.pos); - node.left = entity; - node.right = parseRightSideOfDot(allowReservedWords); - entity = finishNode(node); - } - return entity; - } - function parseRightSideOfDot(allowIdentifierNames) { - // Technically a keyword is valid here as all identifiers and keywords are identifier names. - // However, often we'll encounter this in error situations when the identifier or keyword - // is actually starting another valid construct. - // - // So, we check for the following specific case: - // - // name. - // identifierOrKeyword identifierNameOrKeyword - // - // Note: the newlines are important here. For example, if that above code - // were rewritten into: - // - // name.identifierOrKeyword - // identifierNameOrKeyword - // - // Then we would consider it valid. That's because ASI would take effect and - // the code would be implicitly: "name.identifierOrKeyword; identifierNameOrKeyword". - // In the first case though, ASI will not take effect because there is not a - // line terminator after the identifier or keyword. - if (scanner.hasPrecedingLineBreak() && isIdentifierOrKeyword()) { - var matchesPattern = lookAhead(nextTokenIsIdentifierOrKeywordOnSameLine); - if (matchesPattern) { - // Report that we need an identifier. However, report it right after the dot, - // and not on the next token. This is because the next token might actually - // be an identifier and the error would be quite confusing. - return createMissingNode(65 /* Identifier */, true, ts.Diagnostics.Identifier_expected); - } - } - return allowIdentifierNames ? parseIdentifierName() : parseIdentifier(); - } - function parseTemplateExpression() { - var template = createNode(174 /* TemplateExpression */); - template.head = parseLiteralNode(); - ts.Debug.assert(template.head.kind === 11 /* TemplateHead */, "Template head has wrong token kind"); - var templateSpans = []; - templateSpans.pos = getNodePos(); - do { - templateSpans.push(parseTemplateSpan()); - } while (ts.lastOrUndefined(templateSpans).literal.kind === 12 /* TemplateMiddle */); - templateSpans.end = getNodeEnd(); - template.templateSpans = templateSpans; - return finishNode(template); - } - function parseTemplateSpan() { - var span = createNode(180 /* TemplateSpan */); - span.expression = allowInAnd(parseExpression); - var literal; - if (token === 15 /* CloseBraceToken */) { - reScanTemplateToken(); - literal = parseLiteralNode(); - } - else { - literal = parseExpectedToken(13 /* TemplateTail */, false, ts.Diagnostics._0_expected, ts.tokenToString(15 /* CloseBraceToken */)); - } - span.literal = literal; - return finishNode(span); - } - function parseLiteralNode(internName) { - var node = createNode(token); - var text = scanner.getTokenValue(); - node.text = internName ? internIdentifier(text) : text; - if (scanner.hasExtendedUnicodeEscape()) { - node.hasExtendedUnicodeEscape = true; - } - if (scanner.isUnterminated()) { - node.isUnterminated = true; - } - var tokenPos = scanner.getTokenPos(); - nextToken(); - finishNode(node); - // Octal literals are not allowed in strict mode or ES5 - // Note that theoretically the following condition would hold true literals like 009, - // which is not octal.But because of how the scanner separates the tokens, we would - // never get a token like this. Instead, we would get 00 and 9 as two separate tokens. - // We also do not need to check for negatives because any prefix operator would be part of a - // parent unary expression. - if (node.kind === 7 /* NumericLiteral */ - && sourceText.charCodeAt(tokenPos) === 48 /* _0 */ - && ts.isOctalDigit(sourceText.charCodeAt(tokenPos + 1))) { - node.flags |= 16384 /* OctalLiteral */; - } - return node; - } - // TYPES - function parseTypeReferenceOrTypePredicate() { - var typeName = parseEntityName(false, ts.Diagnostics.Type_expected); - if (typeName.kind === 65 /* Identifier */ && token === 117 /* IsKeyword */ && !scanner.hasPrecedingLineBreak()) { - nextToken(); - var node_1 = createNode(143 /* TypePredicate */, typeName.pos); - node_1.parameterName = typeName; - node_1.type = parseType(); - return finishNode(node_1); - } - var node = createNode(144 /* TypeReference */, typeName.pos); - node.typeName = typeName; - if (!scanner.hasPrecedingLineBreak() && token === 24 /* LessThanToken */) { - node.typeArguments = parseBracketedList(16 /* TypeArguments */, parseType, 24 /* LessThanToken */, 25 /* GreaterThanToken */); - } - return finishNode(node); - } - function parseTypeQuery() { - var node = createNode(147 /* TypeQuery */); - parseExpected(97 /* TypeOfKeyword */); - node.exprName = parseEntityName(true); - return finishNode(node); - } - function parseTypeParameter() { - var node = createNode(130 /* TypeParameter */); - node.name = parseIdentifier(); - if (parseOptional(79 /* ExtendsKeyword */)) { - // It's not uncommon for people to write improper constraints to a generic. If the - // user writes a constraint that is an expression and not an actual type, then parse - // it out as an expression (so we can recover well), but report that a type is needed - // instead. - if (isStartOfType() || !isStartOfExpression()) { - node.constraint = parseType(); - } - else { - // It was not a type, and it looked like an expression. Parse out an expression - // here so we recover well. Note: it is important that we call parseUnaryExpression - // and not parseExpression here. If the user has: - // - // - // - // We do *not* want to consume the > as we're consuming the expression for "". - node.expression = parseUnaryExpressionOrHigher(); - } - } - return finishNode(node); - } - function parseTypeParameters() { - if (token === 24 /* LessThanToken */) { - return parseBracketedList(15 /* TypeParameters */, parseTypeParameter, 24 /* LessThanToken */, 25 /* GreaterThanToken */); - } - } - function parseParameterType() { - if (parseOptional(51 /* ColonToken */)) { - return token === 8 /* StringLiteral */ - ? parseLiteralNode(true) - : parseType(); - } - return undefined; - } - function isStartOfParameter() { - return token === 21 /* DotDotDotToken */ || isIdentifierOrPattern() || ts.isModifier(token) || token === 52 /* AtToken */; - } - function setModifiers(node, modifiers) { - if (modifiers) { - node.flags |= modifiers.flags; - node.modifiers = modifiers; - } - } - function parseParameter() { - var node = createNode(131 /* Parameter */); - node.decorators = parseDecorators(); - setModifiers(node, parseModifiers()); - node.dotDotDotToken = parseOptionalToken(21 /* DotDotDotToken */); - // SingleNameBinding[Yield,GeneratorParameter] : See 13.2.3 - // [+GeneratorParameter]BindingIdentifier[Yield]Initializer[In]opt - // [~GeneratorParameter]BindingIdentifier[?Yield]Initializer[In, ?Yield]opt - node.name = inGeneratorParameterContext() ? doInYieldContext(parseIdentifierOrPattern) : parseIdentifierOrPattern(); - if (ts.getFullWidth(node.name) === 0 && node.flags === 0 && ts.isModifier(token)) { - // in cases like - // 'use strict' - // function foo(static) - // isParameter('static') === true, because of isModifier('static') - // however 'static' is not a legal identifier in a strict mode. - // so result of this function will be ParameterDeclaration (flags = 0, name = missing, type = undefined, initializer = undefined) - // and current token will not change => parsing of the enclosing parameter list will last till the end of time (or OOM) - // to avoid this we'll advance cursor to the next token. - nextToken(); - } - node.questionToken = parseOptionalToken(50 /* QuestionToken */); - node.type = parseParameterType(); - node.initializer = inGeneratorParameterContext() ? doOutsideOfYieldContext(parseParameterInitializer) : parseParameterInitializer(); - // Do not check for initializers in an ambient context for parameters. This is not - // a grammar error because the grammar allows arbitrary call signatures in - // an ambient context. - // It is actually not necessary for this to be an error at all. The reason is that - // function/constructor implementations are syntactically disallowed in ambient - // contexts. In addition, parameter initializers are semantically disallowed in - // overload signatures. So parameter initializers are transitively disallowed in - // ambient contexts. - return finishNode(node); - } - function parseParameterInitializer() { - return parseInitializer(true); - } - function fillSignature(returnToken, yieldAndGeneratorParameterContext, requireCompleteParameterList, signature) { - var returnTokenRequired = returnToken === 32 /* EqualsGreaterThanToken */; - signature.typeParameters = parseTypeParameters(); - signature.parameters = parseParameterList(yieldAndGeneratorParameterContext, requireCompleteParameterList); - if (returnTokenRequired) { - parseExpected(returnToken); - signature.type = parseType(); - } - else if (parseOptional(returnToken)) { - signature.type = parseType(); - } - } - // Note: after careful analysis of the grammar, it does not appear to be possible to - // have 'Yield' And 'GeneratorParameter' not in sync. i.e. any production calling - // this FormalParameters production either always sets both to true, or always sets - // both to false. As such we only have a single parameter to represent both. - function parseParameterList(yieldAndGeneratorParameterContext, requireCompleteParameterList) { - // FormalParameters[Yield,GeneratorParameter] : - // ... - // - // FormalParameter[Yield,GeneratorParameter] : - // BindingElement[?Yield, ?GeneratorParameter] - // - // BindingElement[Yield, GeneratorParameter ] : See 13.2.3 - // SingleNameBinding[?Yield, ?GeneratorParameter] - // [+GeneratorParameter]BindingPattern[?Yield, GeneratorParameter]Initializer[In]opt - // [~GeneratorParameter]BindingPattern[?Yield]Initializer[In, ?Yield]opt - // - // SingleNameBinding[Yield, GeneratorParameter] : See 13.2.3 - // [+GeneratorParameter]BindingIdentifier[Yield]Initializer[In]opt - // [~GeneratorParameter]BindingIdentifier[?Yield]Initializer[In, ?Yield]opt - if (parseExpected(16 /* OpenParenToken */)) { - var savedYieldContext = inYieldContext(); - var savedGeneratorParameterContext = inGeneratorParameterContext(); - setYieldContext(yieldAndGeneratorParameterContext); - setGeneratorParameterContext(yieldAndGeneratorParameterContext); - var result = parseDelimitedList(14 /* Parameters */, parseParameter); - setYieldContext(savedYieldContext); - setGeneratorParameterContext(savedGeneratorParameterContext); - if (!parseExpected(17 /* CloseParenToken */) && requireCompleteParameterList) { - // Caller insisted that we had to end with a ) We didn't. So just return - // undefined here. - return undefined; - } - return result; - } - // We didn't even have an open paren. If the caller requires a complete parameter list, - // we definitely can't provide that. However, if they're ok with an incomplete one, - // then just return an empty set of parameters. - return requireCompleteParameterList ? undefined : createMissingList(); - } - function parseTypeMemberSemicolon() { - // We allow type members to be separated by commas or (possibly ASI) semicolons. - // First check if it was a comma. If so, we're done with the member. - if (parseOptional(23 /* CommaToken */)) { - return; - } - // Didn't have a comma. We must have a (possible ASI) semicolon. - parseSemicolon(); - } - function parseSignatureMember(kind) { - var node = createNode(kind); - if (kind === 141 /* ConstructSignature */) { - parseExpected(88 /* NewKeyword */); - } - fillSignature(51 /* ColonToken */, false, false, node); - parseTypeMemberSemicolon(); - return finishNode(node); - } - function isIndexSignature() { - if (token !== 18 /* OpenBracketToken */) { - return false; - } - return lookAhead(isUnambiguouslyIndexSignature); - } - function isUnambiguouslyIndexSignature() { - // The only allowed sequence is: - // - // [id: - // - // However, for error recovery, we also check the following cases: - // - // [... - // [id, - // [id?, - // [id?: - // [id?] - // [public id - // [private id - // [protected id - // [] - // - nextToken(); - if (token === 21 /* DotDotDotToken */ || token === 19 /* CloseBracketToken */) { - return true; - } - if (ts.isModifier(token)) { - nextToken(); - if (isIdentifier()) { - return true; - } - } - else if (!isIdentifier()) { - return false; - } - else { - // Skip the identifier - nextToken(); - } - // A colon signifies a well formed indexer - // A comma should be a badly formed indexer because comma expressions are not allowed - // in computed properties. - if (token === 51 /* ColonToken */ || token === 23 /* CommaToken */) { - return true; - } - // Question mark could be an indexer with an optional property, - // or it could be a conditional expression in a computed property. - if (token !== 50 /* QuestionToken */) { - return false; - } - // If any of the following tokens are after the question mark, it cannot - // be a conditional expression, so treat it as an indexer. - nextToken(); - return token === 51 /* ColonToken */ || token === 23 /* CommaToken */ || token === 19 /* CloseBracketToken */; - } - function parseIndexSignatureDeclaration(fullStart, decorators, modifiers) { - var node = createNode(142 /* IndexSignature */, fullStart); - node.decorators = decorators; - setModifiers(node, modifiers); - node.parameters = parseBracketedList(14 /* Parameters */, parseParameter, 18 /* OpenBracketToken */, 19 /* CloseBracketToken */); - node.type = parseTypeAnnotation(); - parseTypeMemberSemicolon(); - return finishNode(node); - } - function parsePropertyOrMethodSignature() { - var fullStart = scanner.getStartPos(); - var name = parsePropertyName(); - var questionToken = parseOptionalToken(50 /* QuestionToken */); - if (token === 16 /* OpenParenToken */ || token === 24 /* LessThanToken */) { - var method = createNode(135 /* MethodSignature */, fullStart); - method.name = name; - method.questionToken = questionToken; - // Method signatues don't exist in expression contexts. So they have neither - // [Yield] nor [GeneratorParameter] - fillSignature(51 /* ColonToken */, false, false, method); - parseTypeMemberSemicolon(); - return finishNode(method); - } - else { - var property = createNode(133 /* PropertySignature */, fullStart); - property.name = name; - property.questionToken = questionToken; - property.type = parseTypeAnnotation(); - parseTypeMemberSemicolon(); - return finishNode(property); - } - } - function isStartOfTypeMember() { - switch (token) { - case 16 /* OpenParenToken */: - case 24 /* LessThanToken */: - case 18 /* OpenBracketToken */: - return true; - default: - if (ts.isModifier(token)) { - var result = lookAhead(isStartOfIndexSignatureDeclaration); - if (result) { - return result; - } - } - return isLiteralPropertyName() && lookAhead(isTypeMemberWithLiteralPropertyName); - } - } - function isStartOfIndexSignatureDeclaration() { - while (ts.isModifier(token)) { - nextToken(); - } - return isIndexSignature(); - } - function isTypeMemberWithLiteralPropertyName() { - nextToken(); - return token === 16 /* OpenParenToken */ || - token === 24 /* LessThanToken */ || - token === 50 /* QuestionToken */ || - token === 51 /* ColonToken */ || - canParseSemicolon(); - } - function parseTypeMember() { - switch (token) { - case 16 /* OpenParenToken */: - case 24 /* LessThanToken */: - return parseSignatureMember(140 /* CallSignature */); - case 18 /* OpenBracketToken */: - // Indexer or computed property - return isIndexSignature() - ? parseIndexSignatureDeclaration(scanner.getStartPos(), undefined, undefined) - : parsePropertyOrMethodSignature(); - case 88 /* NewKeyword */: - if (lookAhead(isStartOfConstructSignature)) { - return parseSignatureMember(141 /* ConstructSignature */); - } - // fall through. - case 8 /* StringLiteral */: - case 7 /* NumericLiteral */: - return parsePropertyOrMethodSignature(); - default: - // Index declaration as allowed as a type member. But as per the grammar, - // they also allow modifiers. So we have to check for an index declaration - // that might be following modifiers. This ensures that things work properly - // when incrementally parsing as the parser will produce the Index declaration - // if it has the same text regardless of whether it is inside a class or an - // object type. - if (ts.isModifier(token)) { - var result = tryParse(parseIndexSignatureWithModifiers); - if (result) { - return result; - } - } - if (isIdentifierOrKeyword()) { - return parsePropertyOrMethodSignature(); - } - } - } - function parseIndexSignatureWithModifiers() { - var fullStart = scanner.getStartPos(); - var decorators = parseDecorators(); - var modifiers = parseModifiers(); - return isIndexSignature() - ? parseIndexSignatureDeclaration(fullStart, decorators, modifiers) - : undefined; - } - function isStartOfConstructSignature() { - nextToken(); - return token === 16 /* OpenParenToken */ || token === 24 /* LessThanToken */; - } - function parseTypeLiteral() { - var node = createNode(148 /* TypeLiteral */); - node.members = parseObjectTypeMembers(); - return finishNode(node); - } - function parseObjectTypeMembers() { - var members; - if (parseExpected(14 /* OpenBraceToken */)) { - members = parseList(4 /* TypeMembers */, false, parseTypeMember); - parseExpected(15 /* CloseBraceToken */); - } - else { - members = createMissingList(); - } - return members; - } - function parseTupleType() { - var node = createNode(150 /* TupleType */); - node.elementTypes = parseBracketedList(17 /* TupleElementTypes */, parseType, 18 /* OpenBracketToken */, 19 /* CloseBracketToken */); - return finishNode(node); - } - function parseParenthesizedType() { - var node = createNode(152 /* ParenthesizedType */); - parseExpected(16 /* OpenParenToken */); - node.type = parseType(); - parseExpected(17 /* CloseParenToken */); - return finishNode(node); - } - function parseFunctionOrConstructorType(kind) { - var node = createNode(kind); - if (kind === 146 /* ConstructorType */) { - parseExpected(88 /* NewKeyword */); - } - fillSignature(32 /* EqualsGreaterThanToken */, false, false, node); - return finishNode(node); - } - function parseKeywordAndNoDot() { - var node = parseTokenNode(); - return token === 20 /* DotToken */ ? undefined : node; - } - function parseNonArrayType() { - switch (token) { - case 112 /* AnyKeyword */: - case 123 /* StringKeyword */: - case 121 /* NumberKeyword */: - case 113 /* BooleanKeyword */: - case 124 /* SymbolKeyword */: - // If these are followed by a dot, then parse these out as a dotted type reference instead. - var node = tryParse(parseKeywordAndNoDot); - return node || parseTypeReferenceOrTypePredicate(); - case 99 /* VoidKeyword */: - return parseTokenNode(); - case 97 /* TypeOfKeyword */: - return parseTypeQuery(); - case 14 /* OpenBraceToken */: - return parseTypeLiteral(); - case 18 /* OpenBracketToken */: - return parseTupleType(); - case 16 /* OpenParenToken */: - return parseParenthesizedType(); - default: - return parseTypeReferenceOrTypePredicate(); - } - } - function isStartOfType() { - switch (token) { - case 112 /* AnyKeyword */: - case 123 /* StringKeyword */: - case 121 /* NumberKeyword */: - case 113 /* BooleanKeyword */: - case 124 /* SymbolKeyword */: - case 99 /* VoidKeyword */: - case 97 /* TypeOfKeyword */: - case 14 /* OpenBraceToken */: - case 18 /* OpenBracketToken */: - case 24 /* LessThanToken */: - case 88 /* NewKeyword */: - return true; - case 16 /* OpenParenToken */: - // Only consider '(' the start of a type if followed by ')', '...', an identifier, a modifier, - // or something that starts a type. We don't want to consider things like '(1)' a type. - return lookAhead(isStartOfParenthesizedOrFunctionType); - default: - return isIdentifier(); - } - } - function isStartOfParenthesizedOrFunctionType() { - nextToken(); - return token === 17 /* CloseParenToken */ || isStartOfParameter() || isStartOfType(); - } - function parseArrayTypeOrHigher() { - var type = parseNonArrayType(); - while (!scanner.hasPrecedingLineBreak() && parseOptional(18 /* OpenBracketToken */)) { - parseExpected(19 /* CloseBracketToken */); - var node = createNode(149 /* ArrayType */, type.pos); - node.elementType = type; - type = finishNode(node); - } - return type; - } - function parseUnionTypeOrHigher() { - var type = parseArrayTypeOrHigher(); - if (token === 44 /* BarToken */) { - var types = [type]; - types.pos = type.pos; - while (parseOptional(44 /* BarToken */)) { - types.push(parseArrayTypeOrHigher()); - } - types.end = getNodeEnd(); - var node = createNode(151 /* UnionType */, type.pos); - node.types = types; - type = finishNode(node); - } - return type; - } - function isStartOfFunctionType() { - if (token === 24 /* LessThanToken */) { - return true; - } - return token === 16 /* OpenParenToken */ && lookAhead(isUnambiguouslyStartOfFunctionType); - } - function isUnambiguouslyStartOfFunctionType() { - nextToken(); - if (token === 17 /* CloseParenToken */ || token === 21 /* DotDotDotToken */) { - // ( ) - // ( ... - return true; - } - if (isIdentifier() || ts.isModifier(token)) { - nextToken(); - if (token === 51 /* ColonToken */ || token === 23 /* CommaToken */ || - token === 50 /* QuestionToken */ || token === 53 /* EqualsToken */ || - isIdentifier() || ts.isModifier(token)) { - // ( id : - // ( id , - // ( id ? - // ( id = - // ( modifier id - return true; - } - if (token === 17 /* CloseParenToken */) { - nextToken(); - if (token === 32 /* EqualsGreaterThanToken */) { - // ( id ) => - return true; - } - } - } - return false; - } - function parseType() { - // The rules about 'yield' only apply to actual code/expression contexts. They don't - // apply to 'type' contexts. So we disable these parameters here before moving on. - var savedYieldContext = inYieldContext(); - var savedGeneratorParameterContext = inGeneratorParameterContext(); - setYieldContext(false); - setGeneratorParameterContext(false); - var result = parseTypeWorker(); - setYieldContext(savedYieldContext); - setGeneratorParameterContext(savedGeneratorParameterContext); - return result; - } - function parseTypeWorker() { - if (isStartOfFunctionType()) { - return parseFunctionOrConstructorType(145 /* FunctionType */); - } - if (token === 88 /* NewKeyword */) { - return parseFunctionOrConstructorType(146 /* ConstructorType */); - } - return parseUnionTypeOrHigher(); - } - function parseTypeAnnotation() { - return parseOptional(51 /* ColonToken */) ? parseType() : undefined; - } - // EXPRESSIONS - function isStartOfLeftHandSideExpression() { - switch (token) { - case 93 /* ThisKeyword */: - case 91 /* SuperKeyword */: - case 89 /* NullKeyword */: - case 95 /* TrueKeyword */: - case 80 /* FalseKeyword */: - case 7 /* NumericLiteral */: - case 8 /* StringLiteral */: - case 10 /* NoSubstitutionTemplateLiteral */: - case 11 /* TemplateHead */: - case 16 /* OpenParenToken */: - case 18 /* OpenBracketToken */: - case 14 /* OpenBraceToken */: - case 83 /* FunctionKeyword */: - case 69 /* ClassKeyword */: - case 88 /* NewKeyword */: - case 36 /* SlashToken */: - case 57 /* SlashEqualsToken */: - case 65 /* Identifier */: - return true; - default: - return isIdentifier(); - } - } - function isStartOfExpression() { - if (isStartOfLeftHandSideExpression()) { - return true; - } - switch (token) { - case 33 /* PlusToken */: - case 34 /* MinusToken */: - case 47 /* TildeToken */: - case 46 /* ExclamationToken */: - case 74 /* DeleteKeyword */: - case 97 /* TypeOfKeyword */: - case 99 /* VoidKeyword */: - case 38 /* PlusPlusToken */: - case 39 /* MinusMinusToken */: - case 24 /* LessThanToken */: - case 110 /* YieldKeyword */: - // Yield always starts an expression. Either it is an identifier (in which case - // it is definitely an expression). Or it's a keyword (either because we're in - // a generator, or in strict mode (or both)) and it started a yield expression. - return true; - default: - // Error tolerance. If we see the start of some binary operator, we consider - // that the start of an expression. That way we'll parse out a missing identifier, - // give a good message about an identifier being missing, and then consume the - // rest of the binary expression. - if (isBinaryOperator()) { - return true; - } - return isIdentifier(); - } - } - function isStartOfExpressionStatement() { - // As per the grammar, none of '{' or 'function' or 'class' can start an expression statement. - return token !== 14 /* OpenBraceToken */ && - token !== 83 /* FunctionKeyword */ && - token !== 69 /* ClassKeyword */ && - token !== 52 /* AtToken */ && - isStartOfExpression(); - } - function parseExpression() { - // Expression[in]: - // AssignmentExpression[in] - // Expression[in] , AssignmentExpression[in] - // clear the decorator context when parsing Expression, as it should be unambiguous when parsing a decorator - var saveDecoratorContext = inDecoratorContext(); - if (saveDecoratorContext) { - setDecoratorContext(false); - } - var expr = parseAssignmentExpressionOrHigher(); - var operatorToken; - while ((operatorToken = parseOptionalToken(23 /* CommaToken */))) { - expr = makeBinaryExpression(expr, operatorToken, parseAssignmentExpressionOrHigher()); - } - if (saveDecoratorContext) { - setDecoratorContext(true); - } - return expr; - } - function parseInitializer(inParameter) { - if (token !== 53 /* EqualsToken */) { - // It's not uncommon during typing for the user to miss writing the '=' token. Check if - // there is no newline after the last token and if we're on an expression. If so, parse - // this as an equals-value clause with a missing equals. - // NOTE: There are two places where we allow equals-value clauses. The first is in a - // variable declarator. The second is with a parameter. For variable declarators - // it's more likely that a { would be a allowed (as an object literal). While this - // is also allowed for parameters, the risk is that we consume the { as an object - // literal when it really will be for the block following the parameter. - if (scanner.hasPrecedingLineBreak() || (inParameter && token === 14 /* OpenBraceToken */) || !isStartOfExpression()) { - // preceding line break, open brace in a parameter (likely a function body) or current token is not an expression - - // do not try to parse initializer - return undefined; - } - } - // Initializer[In, Yield] : - // = AssignmentExpression[?In, ?Yield] - parseExpected(53 /* EqualsToken */); - return parseAssignmentExpressionOrHigher(); - } - function parseAssignmentExpressionOrHigher() { - // AssignmentExpression[in,yield]: - // 1) ConditionalExpression[?in,?yield] - // 2) LeftHandSideExpression = AssignmentExpression[?in,?yield] - // 3) LeftHandSideExpression AssignmentOperator AssignmentExpression[?in,?yield] - // 4) ArrowFunctionExpression[?in,?yield] - // 5) [+Yield] YieldExpression[?In] - // - // Note: for ease of implementation we treat productions '2' and '3' as the same thing. - // (i.e. they're both BinaryExpressions with an assignment operator in it). - // First, do the simple check if we have a YieldExpression (production '5'). - if (isYieldExpression()) { - return parseYieldExpression(); - } - // Then, check if we have an arrow function (production '4') that starts with a parenthesized - // parameter list. If we do, we must *not* recurse for productions 1, 2 or 3. An ArrowFunction is - // not a LeftHandSideExpression, nor does it start a ConditionalExpression. So we are done - // with AssignmentExpression if we see one. - var arrowExpression = tryParseParenthesizedArrowFunctionExpression(); - if (arrowExpression) { - return arrowExpression; - } - // Now try to see if we're in production '1', '2' or '3'. A conditional expression can - // start with a LogicalOrExpression, while the assignment productions can only start with - // LeftHandSideExpressions. - // - // So, first, we try to just parse out a BinaryExpression. If we get something that is a - // LeftHandSide or higher, then we can try to parse out the assignment expression part. - // Otherwise, we try to parse out the conditional expression bit. We want to allow any - // binary expression here, so we pass in the 'lowest' precedence here so that it matches - // and consumes anything. - var expr = parseBinaryExpressionOrHigher(0); - // To avoid a look-ahead, we did not handle the case of an arrow function with a single un-parenthesized - // parameter ('x => ...') above. We handle it here by checking if the parsed expression was a single - // identifier and the current token is an arrow. - if (expr.kind === 65 /* Identifier */ && token === 32 /* EqualsGreaterThanToken */) { - return parseSimpleArrowFunctionExpression(expr); - } - // Now see if we might be in cases '2' or '3'. - // If the expression was a LHS expression, and we have an assignment operator, then - // we're in '2' or '3'. Consume the assignment and return. - // - // Note: we call reScanGreaterToken so that we get an appropriately merged token - // for cases like > > = becoming >>= - if (ts.isLeftHandSideExpression(expr) && ts.isAssignmentOperator(reScanGreaterToken())) { - return makeBinaryExpression(expr, parseTokenNode(), parseAssignmentExpressionOrHigher()); - } - // It wasn't an assignment or a lambda. This is a conditional expression: - return parseConditionalExpressionRest(expr); - } - function isYieldExpression() { - if (token === 110 /* YieldKeyword */) { - // If we have a 'yield' keyword, and htis is a context where yield expressions are - // allowed, then definitely parse out a yield expression. - if (inYieldContext()) { - return true; - } - if (inStrictModeContext()) { - // If we're in strict mode, then 'yield' is a keyword, could only ever start - // a yield expression. - return true; - } - // We're in a context where 'yield expr' is not allowed. However, if we can - // definitely tell that the user was trying to parse a 'yield expr' and not - // just a normal expr that start with a 'yield' identifier, then parse out - // a 'yield expr'. We can then report an error later that they are only - // allowed in generator expressions. - // - // for example, if we see 'yield(foo)', then we'll have to treat that as an - // invocation expression of something called 'yield'. However, if we have - // 'yield foo' then that is not legal as a normal expression, so we can - // definitely recognize this as a yield expression. - // - // for now we just check if the next token is an identifier. More heuristics - // can be added here later as necessary. We just need to make sure that we - // don't accidently consume something legal. - return lookAhead(nextTokenIsIdentifierOnSameLine); - } - return false; - } - function nextTokenIsIdentifierOnSameLine() { - nextToken(); - return !scanner.hasPrecedingLineBreak() && isIdentifier(); - } - function parseYieldExpression() { - var node = createNode(175 /* YieldExpression */); - // YieldExpression[In] : - // yield - // yield [no LineTerminator here] [Lexical goal InputElementRegExp]AssignmentExpression[?In, Yield] - // yield [no LineTerminator here] * [Lexical goal InputElementRegExp]AssignmentExpression[?In, Yield] - nextToken(); - if (!scanner.hasPrecedingLineBreak() && - (token === 35 /* AsteriskToken */ || isStartOfExpression())) { - node.asteriskToken = parseOptionalToken(35 /* AsteriskToken */); - node.expression = parseAssignmentExpressionOrHigher(); - return finishNode(node); - } - else { - // if the next token is not on the same line as yield. or we don't have an '*' or - // the start of an expressin, then this is just a simple "yield" expression. - return finishNode(node); - } - } - function parseSimpleArrowFunctionExpression(identifier) { - ts.Debug.assert(token === 32 /* EqualsGreaterThanToken */, "parseSimpleArrowFunctionExpression should only have been called if we had a =>"); - var node = createNode(166 /* ArrowFunction */, identifier.pos); - var parameter = createNode(131 /* Parameter */, identifier.pos); - parameter.name = identifier; - finishNode(parameter); - node.parameters = [parameter]; - node.parameters.pos = parameter.pos; - node.parameters.end = parameter.end; - node.equalsGreaterThanToken = parseExpectedToken(32 /* EqualsGreaterThanToken */, false, ts.Diagnostics._0_expected, "=>"); - node.body = parseArrowFunctionExpressionBody(); - return finishNode(node); - } - function tryParseParenthesizedArrowFunctionExpression() { - var triState = isParenthesizedArrowFunctionExpression(); - if (triState === 0 /* False */) { - // It's definitely not a parenthesized arrow function expression. - return undefined; - } - // If we definitely have an arrow function, then we can just parse one, not requiring a - // following => or { token. Otherwise, we *might* have an arrow function. Try to parse - // it out, but don't allow any ambiguity, and return 'undefined' if this could be an - // expression instead. - var arrowFunction = triState === 1 /* True */ - ? parseParenthesizedArrowFunctionExpressionHead(true) - : tryParse(parsePossibleParenthesizedArrowFunctionExpressionHead); - if (!arrowFunction) { - // Didn't appear to actually be a parenthesized arrow function. Just bail out. - return undefined; - } - // If we have an arrow, then try to parse the body. Even if not, try to parse if we - // have an opening brace, just in case we're in an error state. - var lastToken = token; - arrowFunction.equalsGreaterThanToken = parseExpectedToken(32 /* EqualsGreaterThanToken */, false, ts.Diagnostics._0_expected, "=>"); - arrowFunction.body = (lastToken === 32 /* EqualsGreaterThanToken */ || lastToken === 14 /* OpenBraceToken */) - ? parseArrowFunctionExpressionBody() - : parseIdentifier(); - return finishNode(arrowFunction); - } - // True -> We definitely expect a parenthesized arrow function here. - // False -> There *cannot* be a parenthesized arrow function here. - // Unknown -> There *might* be a parenthesized arrow function here. - // Speculatively look ahead to be sure, and rollback if not. - function isParenthesizedArrowFunctionExpression() { - if (token === 16 /* OpenParenToken */ || token === 24 /* LessThanToken */) { - return lookAhead(isParenthesizedArrowFunctionExpressionWorker); - } - if (token === 32 /* EqualsGreaterThanToken */) { - // ERROR RECOVERY TWEAK: - // If we see a standalone => try to parse it as an arrow function expression as that's - // likely what the user intended to write. - return 1 /* True */; - } - // Definitely not a parenthesized arrow function. - return 0 /* False */; - } - function isParenthesizedArrowFunctionExpressionWorker() { - var first = token; - var second = nextToken(); - if (first === 16 /* OpenParenToken */) { - if (second === 17 /* CloseParenToken */) { - // Simple cases: "() =>", "(): ", and "() {". - // This is an arrow function with no parameters. - // The last one is not actually an arrow function, - // but this is probably what the user intended. - var third = nextToken(); - switch (third) { - case 32 /* EqualsGreaterThanToken */: - case 51 /* ColonToken */: - case 14 /* OpenBraceToken */: - return 1 /* True */; - default: - return 0 /* False */; - } - } - // If encounter "([" or "({", this could be the start of a binding pattern. - // Examples: - // ([ x ]) => { } - // ({ x }) => { } - // ([ x ]) - // ({ x }) - if (second === 18 /* OpenBracketToken */ || second === 14 /* OpenBraceToken */) { - return 2 /* Unknown */; - } - // Simple case: "(..." - // This is an arrow function with a rest parameter. - if (second === 21 /* DotDotDotToken */) { - return 1 /* True */; - } - // If we had "(" followed by something that's not an identifier, - // then this definitely doesn't look like a lambda. - // Note: we could be a little more lenient and allow - // "(public" or "(private". These would not ever actually be allowed, - // but we could provide a good error message instead of bailing out. - if (!isIdentifier()) { - return 0 /* False */; - } - // If we have something like "(a:", then we must have a - // type-annotated parameter in an arrow function expression. - if (nextToken() === 51 /* ColonToken */) { - return 1 /* True */; - } - // This *could* be a parenthesized arrow function. - // Return Unknown to let the caller know. - return 2 /* Unknown */; - } - else { - ts.Debug.assert(first === 24 /* LessThanToken */); - // If we have "<" not followed by an identifier, - // then this definitely is not an arrow function. - if (!isIdentifier()) { - return 0 /* False */; - } - // This *could* be a parenthesized arrow function. - return 2 /* Unknown */; - } - } - function parsePossibleParenthesizedArrowFunctionExpressionHead() { - return parseParenthesizedArrowFunctionExpressionHead(false); - } - function parseParenthesizedArrowFunctionExpressionHead(allowAmbiguity) { - var node = createNode(166 /* ArrowFunction */); - // Arrow functions are never generators. - // - // If we're speculatively parsing a signature for a parenthesized arrow function, then - // we have to have a complete parameter list. Otherwise we might see something like - // a => (b => c) - // And think that "(b =>" was actually a parenthesized arrow function with a missing - // close paren. - fillSignature(51 /* ColonToken */, false, !allowAmbiguity, node); - // If we couldn't get parameters, we definitely could not parse out an arrow function. - if (!node.parameters) { - return undefined; - } - // Parsing a signature isn't enough. - // Parenthesized arrow signatures often look like other valid expressions. - // For instance: - // - "(x = 10)" is an assignment expression parsed as a signature with a default parameter value. - // - "(x,y)" is a comma expression parsed as a signature with two parameters. - // - "a ? (b): c" will have "(b):" parsed as a signature with a return type annotation. - // - // So we need just a bit of lookahead to ensure that it can only be a signature. - if (!allowAmbiguity && token !== 32 /* EqualsGreaterThanToken */ && token !== 14 /* OpenBraceToken */) { - // Returning undefined here will cause our caller to rewind to where we started from. - return undefined; - } - return node; - } - function parseArrowFunctionExpressionBody() { - if (token === 14 /* OpenBraceToken */) { - return parseFunctionBlock(false, false); - } - if (token !== 22 /* SemicolonToken */ && - token !== 83 /* FunctionKeyword */ && - token !== 69 /* ClassKeyword */ && - isStartOfStatement() && - !isStartOfExpressionStatement()) { - // Check if we got a plain statement (i.e. no expression-statements, no function/class expressions/declarations) - // - // Here we try to recover from a potential error situation in the case where the - // user meant to supply a block. For example, if the user wrote: - // - // a => - // let v = 0; - // } - // - // they may be missing an open brace. Check to see if that's the case so we can - // try to recover better. If we don't do this, then the next close curly we see may end - // up preemptively closing the containing construct. - // - // Note: even when 'ignoreMissingOpenBrace' is passed as true, parseBody will still error. - return parseFunctionBlock(false, true); - } - return parseAssignmentExpressionOrHigher(); - } - function parseConditionalExpressionRest(leftOperand) { - // Note: we are passed in an expression which was produced from parseBinaryExpressionOrHigher. - var questionToken = parseOptionalToken(50 /* QuestionToken */); - if (!questionToken) { - return leftOperand; - } - // Note: we explicitly 'allowIn' in the whenTrue part of the condition expression, and - // we do not that for the 'whenFalse' part. - var node = createNode(173 /* ConditionalExpression */, leftOperand.pos); - node.condition = leftOperand; - node.questionToken = questionToken; - node.whenTrue = doOutsideOfContext(disallowInAndDecoratorContext, parseAssignmentExpressionOrHigher); - node.colonToken = parseExpectedToken(51 /* ColonToken */, false, ts.Diagnostics._0_expected, ts.tokenToString(51 /* ColonToken */)); - node.whenFalse = parseAssignmentExpressionOrHigher(); - return finishNode(node); - } - function parseBinaryExpressionOrHigher(precedence) { - var leftOperand = parseUnaryExpressionOrHigher(); - return parseBinaryExpressionRest(precedence, leftOperand); - } - function isInOrOfKeyword(t) { - return t === 86 /* InKeyword */ || t === 127 /* OfKeyword */; - } - function parseBinaryExpressionRest(precedence, leftOperand) { - while (true) { - // We either have a binary operator here, or we're finished. We call - // reScanGreaterToken so that we merge token sequences like > and = into >= - reScanGreaterToken(); - var newPrecedence = getBinaryOperatorPrecedence(); - // Check the precedence to see if we should "take" this operator - if (newPrecedence <= precedence) { - break; - } - if (token === 86 /* InKeyword */ && inDisallowInContext()) { - break; - } - leftOperand = makeBinaryExpression(leftOperand, parseTokenNode(), parseBinaryExpressionOrHigher(newPrecedence)); - } - return leftOperand; - } - function isBinaryOperator() { - if (inDisallowInContext() && token === 86 /* InKeyword */) { - return false; - } - return getBinaryOperatorPrecedence() > 0; - } - function getBinaryOperatorPrecedence() { - switch (token) { - case 49 /* BarBarToken */: - return 1; - case 48 /* AmpersandAmpersandToken */: - return 2; - case 44 /* BarToken */: - return 3; - case 45 /* CaretToken */: - return 4; - case 43 /* AmpersandToken */: - return 5; - case 28 /* EqualsEqualsToken */: - case 29 /* ExclamationEqualsToken */: - case 30 /* EqualsEqualsEqualsToken */: - case 31 /* ExclamationEqualsEqualsToken */: - return 6; - case 24 /* LessThanToken */: - case 25 /* GreaterThanToken */: - case 26 /* LessThanEqualsToken */: - case 27 /* GreaterThanEqualsToken */: - case 87 /* InstanceOfKeyword */: - case 86 /* InKeyword */: - return 7; - case 40 /* LessThanLessThanToken */: - case 41 /* GreaterThanGreaterThanToken */: - case 42 /* GreaterThanGreaterThanGreaterThanToken */: - return 8; - case 33 /* PlusToken */: - case 34 /* MinusToken */: - return 9; - case 35 /* AsteriskToken */: - case 36 /* SlashToken */: - case 37 /* PercentToken */: - return 10; - } - // -1 is lower than all other precedences. Returning it will cause binary expression - // parsing to stop. - return -1; - } - function makeBinaryExpression(left, operatorToken, right) { - var node = createNode(172 /* BinaryExpression */, left.pos); - node.left = left; - node.operatorToken = operatorToken; - node.right = right; - return finishNode(node); - } - function parsePrefixUnaryExpression() { - var node = createNode(170 /* PrefixUnaryExpression */); - node.operator = token; - nextToken(); - node.operand = parseUnaryExpressionOrHigher(); - return finishNode(node); - } - function parseDeleteExpression() { - var node = createNode(167 /* DeleteExpression */); - nextToken(); - node.expression = parseUnaryExpressionOrHigher(); - return finishNode(node); - } - function parseTypeOfExpression() { - var node = createNode(168 /* TypeOfExpression */); - nextToken(); - node.expression = parseUnaryExpressionOrHigher(); - return finishNode(node); - } - function parseVoidExpression() { - var node = createNode(169 /* VoidExpression */); - nextToken(); - node.expression = parseUnaryExpressionOrHigher(); - return finishNode(node); - } - function parseUnaryExpressionOrHigher() { - switch (token) { - case 33 /* PlusToken */: - case 34 /* MinusToken */: - case 47 /* TildeToken */: - case 46 /* ExclamationToken */: - case 38 /* PlusPlusToken */: - case 39 /* MinusMinusToken */: - return parsePrefixUnaryExpression(); - case 74 /* DeleteKeyword */: - return parseDeleteExpression(); - case 97 /* TypeOfKeyword */: - return parseTypeOfExpression(); - case 99 /* VoidKeyword */: - return parseVoidExpression(); - case 24 /* LessThanToken */: - return parseTypeAssertion(); - default: - return parsePostfixExpressionOrHigher(); - } - } - function parsePostfixExpressionOrHigher() { - var expression = parseLeftHandSideExpressionOrHigher(); - ts.Debug.assert(ts.isLeftHandSideExpression(expression)); - if ((token === 38 /* PlusPlusToken */ || token === 39 /* MinusMinusToken */) && !scanner.hasPrecedingLineBreak()) { - var node = createNode(171 /* PostfixUnaryExpression */, expression.pos); - node.operand = expression; - node.operator = token; - nextToken(); - return finishNode(node); - } - return expression; - } - function parseLeftHandSideExpressionOrHigher() { - // Original Ecma: - // LeftHandSideExpression: See 11.2 - // NewExpression - // CallExpression - // - // Our simplification: - // - // LeftHandSideExpression: See 11.2 - // MemberExpression - // CallExpression - // - // See comment in parseMemberExpressionOrHigher on how we replaced NewExpression with - // MemberExpression to make our lives easier. - // - // to best understand the below code, it's important to see how CallExpression expands - // out into its own productions: - // - // CallExpression: - // MemberExpression Arguments - // CallExpression Arguments - // CallExpression[Expression] - // CallExpression.IdentifierName - // super ( ArgumentListopt ) - // super.IdentifierName - // - // Because of the recursion in these calls, we need to bottom out first. There are two - // bottom out states we can run into. Either we see 'super' which must start either of - // the last two CallExpression productions. Or we have a MemberExpression which either - // completes the LeftHandSideExpression, or starts the beginning of the first four - // CallExpression productions. - var expression = token === 91 /* SuperKeyword */ - ? parseSuperExpression() - : parseMemberExpressionOrHigher(); - // Now, we *may* be complete. However, we might have consumed the start of a - // CallExpression. As such, we need to consume the rest of it here to be complete. - return parseCallExpressionRest(expression); - } - function parseMemberExpressionOrHigher() { - // Note: to make our lives simpler, we decompose the the NewExpression productions and - // place ObjectCreationExpression and FunctionExpression into PrimaryExpression. - // like so: - // - // PrimaryExpression : See 11.1 - // this - // Identifier - // Literal - // ArrayLiteral - // ObjectLiteral - // (Expression) - // FunctionExpression - // new MemberExpression Arguments? - // - // MemberExpression : See 11.2 - // PrimaryExpression - // MemberExpression[Expression] - // MemberExpression.IdentifierName - // - // CallExpression : See 11.2 - // MemberExpression - // CallExpression Arguments - // CallExpression[Expression] - // CallExpression.IdentifierName - // - // Technically this is ambiguous. i.e. CallExpression defines: - // - // CallExpression: - // CallExpression Arguments - // - // If you see: "new Foo()" - // - // Then that could be treated as a single ObjectCreationExpression, or it could be - // treated as the invocation of "new Foo". We disambiguate that in code (to match - // the original grammar) by making sure that if we see an ObjectCreationExpression - // we always consume arguments if they are there. So we treat "new Foo()" as an - // object creation only, and not at all as an invocation) Another way to think - // about this is that for every "new" that we see, we will consume an argument list if - // it is there as part of the *associated* object creation node. Any additional - // argument lists we see, will become invocation expressions. - // - // Because there are no other places in the grammar now that refer to FunctionExpression - // or ObjectCreationExpression, it is safe to push down into the PrimaryExpression - // production. - // - // Because CallExpression and MemberExpression are left recursive, we need to bottom out - // of the recursion immediately. So we parse out a primary expression to start with. - var expression = parsePrimaryExpression(); - return parseMemberExpressionRest(expression); - } - function parseSuperExpression() { - var expression = parseTokenNode(); - if (token === 16 /* OpenParenToken */ || token === 20 /* DotToken */) { - return expression; - } - // If we have seen "super" it must be followed by '(' or '.'. - // If it wasn't then just try to parse out a '.' and report an error. - var node = createNode(158 /* PropertyAccessExpression */, expression.pos); - node.expression = expression; - node.dotToken = parseExpectedToken(20 /* DotToken */, false, ts.Diagnostics.super_must_be_followed_by_an_argument_list_or_member_access); - node.name = parseRightSideOfDot(true); - return finishNode(node); - } - function parseTypeAssertion() { - var node = createNode(163 /* TypeAssertionExpression */); - parseExpected(24 /* LessThanToken */); - node.type = parseType(); - parseExpected(25 /* GreaterThanToken */); - node.expression = parseUnaryExpressionOrHigher(); - return finishNode(node); - } - function parseMemberExpressionRest(expression) { - while (true) { - var dotToken = parseOptionalToken(20 /* DotToken */); - if (dotToken) { - var propertyAccess = createNode(158 /* PropertyAccessExpression */, expression.pos); - propertyAccess.expression = expression; - propertyAccess.dotToken = dotToken; - propertyAccess.name = parseRightSideOfDot(true); - expression = finishNode(propertyAccess); - continue; - } - // when in the [Decorator] context, we do not parse ElementAccess as it could be part of a ComputedPropertyName - if (!inDecoratorContext() && parseOptional(18 /* OpenBracketToken */)) { - var indexedAccess = createNode(159 /* ElementAccessExpression */, expression.pos); - indexedAccess.expression = expression; - // It's not uncommon for a user to write: "new Type[]". - // Check for that common pattern and report a better error message. - if (token !== 19 /* CloseBracketToken */) { - indexedAccess.argumentExpression = allowInAnd(parseExpression); - if (indexedAccess.argumentExpression.kind === 8 /* StringLiteral */ || indexedAccess.argumentExpression.kind === 7 /* NumericLiteral */) { - var literal = indexedAccess.argumentExpression; - literal.text = internIdentifier(literal.text); - } - } - parseExpected(19 /* CloseBracketToken */); - expression = finishNode(indexedAccess); - continue; - } - if (token === 10 /* NoSubstitutionTemplateLiteral */ || token === 11 /* TemplateHead */) { - var tagExpression = createNode(162 /* TaggedTemplateExpression */, expression.pos); - tagExpression.tag = expression; - tagExpression.template = token === 10 /* NoSubstitutionTemplateLiteral */ - ? parseLiteralNode() - : parseTemplateExpression(); - expression = finishNode(tagExpression); - continue; - } - return expression; - } - } - function parseCallExpressionRest(expression) { - while (true) { - expression = parseMemberExpressionRest(expression); - if (token === 24 /* LessThanToken */) { - // See if this is the start of a generic invocation. If so, consume it and - // keep checking for postfix expressions. Otherwise, it's just a '<' that's - // part of an arithmetic expression. Break out so we consume it higher in the - // stack. - var typeArguments = tryParse(parseTypeArgumentsInExpression); - if (!typeArguments) { - return expression; - } - var callExpr = createNode(160 /* CallExpression */, expression.pos); - callExpr.expression = expression; - callExpr.typeArguments = typeArguments; - callExpr.arguments = parseArgumentList(); - expression = finishNode(callExpr); - continue; - } - else if (token === 16 /* OpenParenToken */) { - var callExpr = createNode(160 /* CallExpression */, expression.pos); - callExpr.expression = expression; - callExpr.arguments = parseArgumentList(); - expression = finishNode(callExpr); - continue; - } - return expression; - } - } - function parseArgumentList() { - parseExpected(16 /* OpenParenToken */); - var result = parseDelimitedList(11 /* ArgumentExpressions */, parseArgumentExpression); - parseExpected(17 /* CloseParenToken */); - return result; - } - function parseTypeArgumentsInExpression() { - if (!parseOptional(24 /* LessThanToken */)) { - return undefined; - } - var typeArguments = parseDelimitedList(16 /* TypeArguments */, parseType); - if (!parseExpected(25 /* GreaterThanToken */)) { - // If it doesn't have the closing > then it's definitely not an type argument list. - return undefined; - } - // If we have a '<', then only parse this as a arugment list if the type arguments - // are complete and we have an open paren. if we don't, rewind and return nothing. - return typeArguments && canFollowTypeArgumentsInExpression() - ? typeArguments - : undefined; - } - function canFollowTypeArgumentsInExpression() { - switch (token) { - case 16 /* OpenParenToken */: // foo( - // this case are the only case where this token can legally follow a type argument - // list. So we definitely want to treat this as a type arg list. - case 20 /* DotToken */: // foo. - case 17 /* CloseParenToken */: // foo) - case 19 /* CloseBracketToken */: // foo] - case 51 /* ColonToken */: // foo: - case 22 /* SemicolonToken */: // foo; - case 50 /* QuestionToken */: // foo? - case 28 /* EqualsEqualsToken */: // foo == - case 30 /* EqualsEqualsEqualsToken */: // foo === - case 29 /* ExclamationEqualsToken */: // foo != - case 31 /* ExclamationEqualsEqualsToken */: // foo !== - case 48 /* AmpersandAmpersandToken */: // foo && - case 49 /* BarBarToken */: // foo || - case 45 /* CaretToken */: // foo ^ - case 43 /* AmpersandToken */: // foo & - case 44 /* BarToken */: // foo | - case 15 /* CloseBraceToken */: // foo } - case 1 /* EndOfFileToken */: - // these cases can't legally follow a type arg list. However, they're not legal - // expressions either. The user is probably in the middle of a generic type. So - // treat it as such. - return true; - case 23 /* CommaToken */: // foo, - case 14 /* OpenBraceToken */: // foo { - // We don't want to treat these as type arguments. Otherwise we'll parse this - // as an invocation expression. Instead, we want to parse out the expression - // in isolation from the type arguments. - default: - // Anything else treat as an expression. - return false; - } - } - function parsePrimaryExpression() { - switch (token) { - case 7 /* NumericLiteral */: - case 8 /* StringLiteral */: - case 10 /* NoSubstitutionTemplateLiteral */: - return parseLiteralNode(); - case 93 /* ThisKeyword */: - case 91 /* SuperKeyword */: - case 89 /* NullKeyword */: - case 95 /* TrueKeyword */: - case 80 /* FalseKeyword */: - return parseTokenNode(); - case 16 /* OpenParenToken */: - return parseParenthesizedExpression(); - case 18 /* OpenBracketToken */: - return parseArrayLiteralExpression(); - case 14 /* OpenBraceToken */: - return parseObjectLiteralExpression(); - case 69 /* ClassKeyword */: - return parseClassExpression(); - case 83 /* FunctionKeyword */: - return parseFunctionExpression(); - case 88 /* NewKeyword */: - return parseNewExpression(); - case 36 /* SlashToken */: - case 57 /* SlashEqualsToken */: - if (reScanSlashToken() === 9 /* RegularExpressionLiteral */) { - return parseLiteralNode(); - } - break; - case 11 /* TemplateHead */: - return parseTemplateExpression(); - } - return parseIdentifier(ts.Diagnostics.Expression_expected); - } - function parseParenthesizedExpression() { - var node = createNode(164 /* ParenthesizedExpression */); - parseExpected(16 /* OpenParenToken */); - node.expression = allowInAnd(parseExpression); - parseExpected(17 /* CloseParenToken */); - return finishNode(node); - } - function parseSpreadElement() { - var node = createNode(176 /* SpreadElementExpression */); - parseExpected(21 /* DotDotDotToken */); - node.expression = parseAssignmentExpressionOrHigher(); - return finishNode(node); - } - function parseArgumentOrArrayLiteralElement() { - return token === 21 /* DotDotDotToken */ ? parseSpreadElement() : - token === 23 /* CommaToken */ ? createNode(178 /* OmittedExpression */) : - parseAssignmentExpressionOrHigher(); - } - function parseArgumentExpression() { - return doOutsideOfContext(disallowInAndDecoratorContext, parseArgumentOrArrayLiteralElement); - } - function parseArrayLiteralExpression() { - var node = createNode(156 /* ArrayLiteralExpression */); - parseExpected(18 /* OpenBracketToken */); - if (scanner.hasPrecedingLineBreak()) - node.flags |= 512 /* MultiLine */; - node.elements = parseDelimitedList(13 /* ArrayLiteralMembers */, parseArgumentOrArrayLiteralElement); - parseExpected(19 /* CloseBracketToken */); - return finishNode(node); - } - function tryParseAccessorDeclaration(fullStart, decorators, modifiers) { - if (parseContextualModifier(116 /* GetKeyword */)) { - return parseAccessorDeclaration(138 /* GetAccessor */, fullStart, decorators, modifiers); - } - else if (parseContextualModifier(122 /* SetKeyword */)) { - return parseAccessorDeclaration(139 /* SetAccessor */, fullStart, decorators, modifiers); - } - return undefined; - } - function parseObjectLiteralElement() { - var fullStart = scanner.getStartPos(); - var decorators = parseDecorators(); - var modifiers = parseModifiers(); - var accessor = tryParseAccessorDeclaration(fullStart, decorators, modifiers); - if (accessor) { - return accessor; - } - var asteriskToken = parseOptionalToken(35 /* AsteriskToken */); - var tokenIsIdentifier = isIdentifier(); - var nameToken = token; - var propertyName = parsePropertyName(); - // Disallowing of optional property assignments happens in the grammar checker. - var questionToken = parseOptionalToken(50 /* QuestionToken */); - if (asteriskToken || token === 16 /* OpenParenToken */ || token === 24 /* LessThanToken */) { - return parseMethodDeclaration(fullStart, decorators, modifiers, asteriskToken, propertyName, questionToken); - } - // Parse to check if it is short-hand property assignment or normal property assignment - if ((token === 23 /* CommaToken */ || token === 15 /* CloseBraceToken */) && tokenIsIdentifier) { - var shorthandDeclaration = createNode(228 /* ShorthandPropertyAssignment */, fullStart); - shorthandDeclaration.name = propertyName; - shorthandDeclaration.questionToken = questionToken; - return finishNode(shorthandDeclaration); - } - else { - var propertyAssignment = createNode(227 /* PropertyAssignment */, fullStart); - propertyAssignment.name = propertyName; - propertyAssignment.questionToken = questionToken; - parseExpected(51 /* ColonToken */); - propertyAssignment.initializer = allowInAnd(parseAssignmentExpressionOrHigher); - return finishNode(propertyAssignment); - } - } - function parseObjectLiteralExpression() { - var node = createNode(157 /* ObjectLiteralExpression */); - parseExpected(14 /* OpenBraceToken */); - if (scanner.hasPrecedingLineBreak()) { - node.flags |= 512 /* MultiLine */; - } - node.properties = parseDelimitedList(12 /* ObjectLiteralMembers */, parseObjectLiteralElement, true); - parseExpected(15 /* CloseBraceToken */); - return finishNode(node); - } - function parseFunctionExpression() { - // GeneratorExpression : - // function * BindingIdentifier[Yield]opt (FormalParameters[Yield, GeneratorParameter]) { GeneratorBody[Yield] } - // FunctionExpression: - // function BindingIdentifieropt(FormalParameters) { FunctionBody } - var saveDecoratorContext = inDecoratorContext(); - if (saveDecoratorContext) { - setDecoratorContext(false); - } - var node = createNode(165 /* FunctionExpression */); - parseExpected(83 /* FunctionKeyword */); - node.asteriskToken = parseOptionalToken(35 /* AsteriskToken */); - node.name = node.asteriskToken ? doInYieldContext(parseOptionalIdentifier) : parseOptionalIdentifier(); - fillSignature(51 /* ColonToken */, !!node.asteriskToken, false, node); - node.body = parseFunctionBlock(!!node.asteriskToken, false); - if (saveDecoratorContext) { - setDecoratorContext(true); - } - return finishNode(node); - } - function parseOptionalIdentifier() { - return isIdentifier() ? parseIdentifier() : undefined; - } - function parseNewExpression() { - var node = createNode(161 /* NewExpression */); - parseExpected(88 /* NewKeyword */); - node.expression = parseMemberExpressionOrHigher(); - node.typeArguments = tryParse(parseTypeArgumentsInExpression); - if (node.typeArguments || token === 16 /* OpenParenToken */) { - node.arguments = parseArgumentList(); - } - return finishNode(node); - } - // STATEMENTS - function parseBlock(ignoreMissingOpenBrace, checkForStrictMode, diagnosticMessage) { - var node = createNode(182 /* Block */); - if (parseExpected(14 /* OpenBraceToken */, diagnosticMessage) || ignoreMissingOpenBrace) { - node.statements = parseList(1 /* BlockStatements */, checkForStrictMode, parseStatement); - parseExpected(15 /* CloseBraceToken */); - } - else { - node.statements = createMissingList(); - } - return finishNode(node); - } - function parseFunctionBlock(allowYield, ignoreMissingOpenBrace, diagnosticMessage) { - var savedYieldContext = inYieldContext(); - setYieldContext(allowYield); - // We may be in a [Decorator] context when parsing a function expression or - // arrow function. The body of the function is not in [Decorator] context. - var saveDecoratorContext = inDecoratorContext(); - if (saveDecoratorContext) { - setDecoratorContext(false); - } - var block = parseBlock(ignoreMissingOpenBrace, true, diagnosticMessage); - if (saveDecoratorContext) { - setDecoratorContext(true); - } - setYieldContext(savedYieldContext); - return block; - } - function parseEmptyStatement() { - var node = createNode(184 /* EmptyStatement */); - parseExpected(22 /* SemicolonToken */); - return finishNode(node); - } - function parseIfStatement() { - var node = createNode(186 /* IfStatement */); - parseExpected(84 /* IfKeyword */); - parseExpected(16 /* OpenParenToken */); - node.expression = allowInAnd(parseExpression); - parseExpected(17 /* CloseParenToken */); - node.thenStatement = parseStatement(); - node.elseStatement = parseOptional(76 /* ElseKeyword */) ? parseStatement() : undefined; - return finishNode(node); - } - function parseDoStatement() { - var node = createNode(187 /* DoStatement */); - parseExpected(75 /* DoKeyword */); - node.statement = parseStatement(); - parseExpected(100 /* WhileKeyword */); - parseExpected(16 /* OpenParenToken */); - node.expression = allowInAnd(parseExpression); - parseExpected(17 /* CloseParenToken */); - // From: https://mail.mozilla.org/pipermail/es-discuss/2011-August/016188.html - // 157 min --- All allen at wirfs-brock.com CONF --- "do{;}while(false)false" prohibited in - // spec but allowed in consensus reality. Approved -- this is the de-facto standard whereby - // do;while(0)x will have a semicolon inserted before x. - parseOptional(22 /* SemicolonToken */); - return finishNode(node); - } - function parseWhileStatement() { - var node = createNode(188 /* WhileStatement */); - parseExpected(100 /* WhileKeyword */); - parseExpected(16 /* OpenParenToken */); - node.expression = allowInAnd(parseExpression); - parseExpected(17 /* CloseParenToken */); - node.statement = parseStatement(); - return finishNode(node); - } - function parseForOrForInOrForOfStatement() { - var pos = getNodePos(); - parseExpected(82 /* ForKeyword */); - parseExpected(16 /* OpenParenToken */); - var initializer = undefined; - if (token !== 22 /* SemicolonToken */) { - if (token === 98 /* VarKeyword */ || token === 104 /* LetKeyword */ || token === 70 /* ConstKeyword */) { - initializer = parseVariableDeclarationList(true); - } - else { - initializer = disallowInAnd(parseExpression); - } - } - var forOrForInOrForOfStatement; - if (parseOptional(86 /* InKeyword */)) { - var forInStatement = createNode(190 /* ForInStatement */, pos); - forInStatement.initializer = initializer; - forInStatement.expression = allowInAnd(parseExpression); - parseExpected(17 /* CloseParenToken */); - forOrForInOrForOfStatement = forInStatement; - } - else if (parseOptional(127 /* OfKeyword */)) { - var forOfStatement = createNode(191 /* ForOfStatement */, pos); - forOfStatement.initializer = initializer; - forOfStatement.expression = allowInAnd(parseAssignmentExpressionOrHigher); - parseExpected(17 /* CloseParenToken */); - forOrForInOrForOfStatement = forOfStatement; - } - else { - var forStatement = createNode(189 /* ForStatement */, pos); - forStatement.initializer = initializer; - parseExpected(22 /* SemicolonToken */); - if (token !== 22 /* SemicolonToken */ && token !== 17 /* CloseParenToken */) { - forStatement.condition = allowInAnd(parseExpression); - } - parseExpected(22 /* SemicolonToken */); - if (token !== 17 /* CloseParenToken */) { - forStatement.incrementor = allowInAnd(parseExpression); - } - parseExpected(17 /* CloseParenToken */); - forOrForInOrForOfStatement = forStatement; - } - forOrForInOrForOfStatement.statement = parseStatement(); - return finishNode(forOrForInOrForOfStatement); - } - function parseBreakOrContinueStatement(kind) { - var node = createNode(kind); - parseExpected(kind === 193 /* BreakStatement */ ? 66 /* BreakKeyword */ : 71 /* ContinueKeyword */); - if (!canParseSemicolon()) { - node.label = parseIdentifier(); - } - parseSemicolon(); - return finishNode(node); - } - function parseReturnStatement() { - var node = createNode(194 /* ReturnStatement */); - parseExpected(90 /* ReturnKeyword */); - if (!canParseSemicolon()) { - node.expression = allowInAnd(parseExpression); - } - parseSemicolon(); - return finishNode(node); - } - function parseWithStatement() { - var node = createNode(195 /* WithStatement */); - parseExpected(101 /* WithKeyword */); - parseExpected(16 /* OpenParenToken */); - node.expression = allowInAnd(parseExpression); - parseExpected(17 /* CloseParenToken */); - node.statement = parseStatement(); - return finishNode(node); - } - function parseCaseClause() { - var node = createNode(223 /* CaseClause */); - parseExpected(67 /* CaseKeyword */); - node.expression = allowInAnd(parseExpression); - parseExpected(51 /* ColonToken */); - node.statements = parseList(3 /* SwitchClauseStatements */, false, parseStatement); - return finishNode(node); - } - function parseDefaultClause() { - var node = createNode(224 /* DefaultClause */); - parseExpected(73 /* DefaultKeyword */); - parseExpected(51 /* ColonToken */); - node.statements = parseList(3 /* SwitchClauseStatements */, false, parseStatement); - return finishNode(node); - } - function parseCaseOrDefaultClause() { - return token === 67 /* CaseKeyword */ ? parseCaseClause() : parseDefaultClause(); - } - function parseSwitchStatement() { - var node = createNode(196 /* SwitchStatement */); - parseExpected(92 /* SwitchKeyword */); - parseExpected(16 /* OpenParenToken */); - node.expression = allowInAnd(parseExpression); - parseExpected(17 /* CloseParenToken */); - var caseBlock = createNode(210 /* CaseBlock */, scanner.getStartPos()); - parseExpected(14 /* OpenBraceToken */); - caseBlock.clauses = parseList(2 /* SwitchClauses */, false, parseCaseOrDefaultClause); - parseExpected(15 /* CloseBraceToken */); - node.caseBlock = finishNode(caseBlock); - return finishNode(node); - } - function parseThrowStatement() { - // ThrowStatement[Yield] : - // throw [no LineTerminator here]Expression[In, ?Yield]; - // Because of automatic semicolon insertion, we need to report error if this - // throw could be terminated with a semicolon. Note: we can't call 'parseExpression' - // directly as that might consume an expression on the following line. - // We just return 'undefined' in that case. The actual error will be reported in the - // grammar walker. - var node = createNode(198 /* ThrowStatement */); - parseExpected(94 /* ThrowKeyword */); - node.expression = scanner.hasPrecedingLineBreak() ? undefined : allowInAnd(parseExpression); - parseSemicolon(); - return finishNode(node); - } - // TODO: Review for error recovery - function parseTryStatement() { - var node = createNode(199 /* TryStatement */); - parseExpected(96 /* TryKeyword */); - node.tryBlock = parseBlock(false, false); - node.catchClause = token === 68 /* CatchKeyword */ ? parseCatchClause() : undefined; - // If we don't have a catch clause, then we must have a finally clause. Try to parse - // one out no matter what. - if (!node.catchClause || token === 81 /* FinallyKeyword */) { - parseExpected(81 /* FinallyKeyword */); - node.finallyBlock = parseBlock(false, false); - } - return finishNode(node); - } - function parseCatchClause() { - var result = createNode(226 /* CatchClause */); - parseExpected(68 /* CatchKeyword */); - if (parseExpected(16 /* OpenParenToken */)) { - result.variableDeclaration = parseVariableDeclaration(); - } - parseExpected(17 /* CloseParenToken */); - result.block = parseBlock(false, false); - return finishNode(result); - } - function parseDebuggerStatement() { - var node = createNode(200 /* DebuggerStatement */); - parseExpected(72 /* DebuggerKeyword */); - parseSemicolon(); - return finishNode(node); - } - function parseExpressionOrLabeledStatement() { - // Avoiding having to do the lookahead for a labeled statement by just trying to parse - // out an expression, seeing if it is identifier and then seeing if it is followed by - // a colon. - var fullStart = scanner.getStartPos(); - var expression = allowInAnd(parseExpression); - if (expression.kind === 65 /* Identifier */ && parseOptional(51 /* ColonToken */)) { - var labeledStatement = createNode(197 /* LabeledStatement */, fullStart); - labeledStatement.label = expression; - labeledStatement.statement = parseStatement(); - return finishNode(labeledStatement); - } - else { - var expressionStatement = createNode(185 /* ExpressionStatement */, fullStart); - expressionStatement.expression = expression; - parseSemicolon(); - return finishNode(expressionStatement); - } - } - function isIdentifierOrKeyword() { - return token >= 65 /* Identifier */; - } - function nextTokenIsIdentifierOrKeywordOnSameLine() { - nextToken(); - return isIdentifierOrKeyword() && !scanner.hasPrecedingLineBreak(); - } - function isDeclaration() { - while (true) { - switch (token) { - case 98 /* VarKeyword */: - case 104 /* LetKeyword */: - case 70 /* ConstKeyword */: - case 83 /* FunctionKeyword */: - case 69 /* ClassKeyword */: - case 77 /* EnumKeyword */: - return true; - // 'declare', 'module', 'namespace', 'interface'* and 'type' are all legal JavaScript identifiers; - // however, an identifier cannot be followed by another identifier on the same line. This is what we - // count on to parse out the respective declarations. For instance, we exploit this to say that - // - // namespace n - // - // can be none other than the beginning of a namespace declaration, but need to respect that JavaScript sees - // - // namespace - // n - // - // as the identifier 'namespace' on one line followed by the identifier 'n' on another. - // We need to look one token ahead to see if it permissible to try parsing a declaration. - // - // *Note*: 'interface' is actually a strict mode reserved word. So while - // - // "use strict" - // interface - // I {} - // - // could be legal, it would add complexity for very little gain. - case 103 /* InterfaceKeyword */: - case 125 /* TypeKeyword */: - return nextTokenIsIdentifierOnSameLine(); - case 118 /* ModuleKeyword */: - case 119 /* NamespaceKeyword */: - return nextTokenIsIdentifierOrStringLiteralOnSameLine(); - case 115 /* DeclareKeyword */: - nextToken(); - // ASI takes effect for this modifier. - if (scanner.hasPrecedingLineBreak()) { - return false; - } - continue; - case 85 /* ImportKeyword */: - nextToken(); - return token === 8 /* StringLiteral */ || token === 35 /* AsteriskToken */ || - token === 14 /* OpenBraceToken */ || isIdentifierOrKeyword(); - case 78 /* ExportKeyword */: - nextToken(); - if (token === 53 /* EqualsToken */ || token === 35 /* AsteriskToken */ || - token === 14 /* OpenBraceToken */ || token === 73 /* DefaultKeyword */) { - return true; - } - continue; - case 108 /* PublicKeyword */: - case 106 /* PrivateKeyword */: - case 107 /* ProtectedKeyword */: - case 109 /* StaticKeyword */: - nextToken(); - continue; - default: - return false; - } - } - } - function isStartOfDeclaration() { - return lookAhead(isDeclaration); - } - function isStartOfStatement() { - switch (token) { - case 52 /* AtToken */: - case 22 /* SemicolonToken */: - case 14 /* OpenBraceToken */: - case 98 /* VarKeyword */: - case 104 /* LetKeyword */: - case 83 /* FunctionKeyword */: - case 69 /* ClassKeyword */: - case 77 /* EnumKeyword */: - case 84 /* IfKeyword */: - case 75 /* DoKeyword */: - case 100 /* WhileKeyword */: - case 82 /* ForKeyword */: - case 71 /* ContinueKeyword */: - case 66 /* BreakKeyword */: - case 90 /* ReturnKeyword */: - case 101 /* WithKeyword */: - case 92 /* SwitchKeyword */: - case 94 /* ThrowKeyword */: - case 96 /* TryKeyword */: - case 72 /* DebuggerKeyword */: - // 'catch' and 'finally' do not actually indicate that the code is part of a statement, - // however, we say they are here so that we may gracefully parse them and error later. - case 68 /* CatchKeyword */: - case 81 /* FinallyKeyword */: - return true; - case 70 /* ConstKeyword */: - case 78 /* ExportKeyword */: - case 85 /* ImportKeyword */: - return isStartOfDeclaration(); - case 115 /* DeclareKeyword */: - case 103 /* InterfaceKeyword */: - case 118 /* ModuleKeyword */: - case 119 /* NamespaceKeyword */: - case 125 /* TypeKeyword */: - // When these don't start a declaration, they're an identifier in an expression statement - return true; - case 108 /* PublicKeyword */: - case 106 /* PrivateKeyword */: - case 107 /* ProtectedKeyword */: - case 109 /* StaticKeyword */: - // When these don't start a declaration, they may be the start of a class member if an identifier - // immediately follows. Otherwise they're an identifier in an expression statement. - return isStartOfDeclaration() || !lookAhead(nextTokenIsIdentifierOrKeywordOnSameLine); - default: - return isStartOfExpression(); - } - } - function nextTokenIsIdentifierOrStartOfDestructuringOnTheSameLine() { - nextToken(); - return !scanner.hasPrecedingLineBreak() && - (isIdentifier() || token === 14 /* OpenBraceToken */ || token === 18 /* OpenBracketToken */); - } - function isLetDeclaration() { - // It is let declaration if in strict mode or next token is identifier\open bracket\open curly on same line. - // otherwise it needs to be treated like identifier - return inStrictModeContext() || lookAhead(nextTokenIsIdentifierOrStartOfDestructuringOnTheSameLine); - } - function parseStatement() { - switch (token) { - case 22 /* SemicolonToken */: - return parseEmptyStatement(); - case 14 /* OpenBraceToken */: - return parseBlock(false, false); - case 98 /* VarKeyword */: - return parseVariableStatement(scanner.getStartPos(), undefined, undefined); - case 104 /* LetKeyword */: - if (isLetDeclaration()) { - return parseVariableStatement(scanner.getStartPos(), undefined, undefined); - } - break; - case 83 /* FunctionKeyword */: - return parseFunctionDeclaration(scanner.getStartPos(), undefined, undefined); - case 69 /* ClassKeyword */: - return parseClassDeclaration(scanner.getStartPos(), undefined, undefined); - case 84 /* IfKeyword */: - return parseIfStatement(); - case 75 /* DoKeyword */: - return parseDoStatement(); - case 100 /* WhileKeyword */: - return parseWhileStatement(); - case 82 /* ForKeyword */: - return parseForOrForInOrForOfStatement(); - case 71 /* ContinueKeyword */: - return parseBreakOrContinueStatement(192 /* ContinueStatement */); - case 66 /* BreakKeyword */: - return parseBreakOrContinueStatement(193 /* BreakStatement */); - case 90 /* ReturnKeyword */: - return parseReturnStatement(); - case 101 /* WithKeyword */: - return parseWithStatement(); - case 92 /* SwitchKeyword */: - return parseSwitchStatement(); - case 94 /* ThrowKeyword */: - return parseThrowStatement(); - case 96 /* TryKeyword */: - // Include 'catch' and 'finally' for error recovery. - case 68 /* CatchKeyword */: - case 81 /* FinallyKeyword */: - return parseTryStatement(); - case 72 /* DebuggerKeyword */: - return parseDebuggerStatement(); - case 52 /* AtToken */: - return parseDeclaration(); - case 103 /* InterfaceKeyword */: - case 125 /* TypeKeyword */: - case 118 /* ModuleKeyword */: - case 119 /* NamespaceKeyword */: - case 115 /* DeclareKeyword */: - case 70 /* ConstKeyword */: - case 77 /* EnumKeyword */: - case 78 /* ExportKeyword */: - case 85 /* ImportKeyword */: - case 106 /* PrivateKeyword */: - case 107 /* ProtectedKeyword */: - case 108 /* PublicKeyword */: - case 109 /* StaticKeyword */: - if (isStartOfDeclaration()) { - return parseDeclaration(); - } - break; - } - return parseExpressionOrLabeledStatement(); - } - function parseDeclaration() { - var fullStart = getNodePos(); - var decorators = parseDecorators(); - var modifiers = parseModifiers(); - switch (token) { - case 98 /* VarKeyword */: - case 104 /* LetKeyword */: - case 70 /* ConstKeyword */: - return parseVariableStatement(fullStart, decorators, modifiers); - case 83 /* FunctionKeyword */: - return parseFunctionDeclaration(fullStart, decorators, modifiers); - case 69 /* ClassKeyword */: - return parseClassDeclaration(fullStart, decorators, modifiers); - case 103 /* InterfaceKeyword */: - return parseInterfaceDeclaration(fullStart, decorators, modifiers); - case 125 /* TypeKeyword */: - return parseTypeAliasDeclaration(fullStart, decorators, modifiers); - case 77 /* EnumKeyword */: - return parseEnumDeclaration(fullStart, decorators, modifiers); - case 118 /* ModuleKeyword */: - case 119 /* NamespaceKeyword */: - return parseModuleDeclaration(fullStart, decorators, modifiers); - case 85 /* ImportKeyword */: - return parseImportDeclarationOrImportEqualsDeclaration(fullStart, decorators, modifiers); - case 78 /* ExportKeyword */: - nextToken(); - return token === 73 /* DefaultKeyword */ || token === 53 /* EqualsToken */ ? - parseExportAssignment(fullStart, decorators, modifiers) : - parseExportDeclaration(fullStart, decorators, modifiers); - default: - if (decorators) { - // We reached this point because we encountered decorators and/or modifiers and assumed a declaration - // would follow. For recovery and error reporting purposes, return an incomplete declaration. - var node = createMissingNode(221 /* MissingDeclaration */, true, ts.Diagnostics.Declaration_expected); - node.pos = fullStart; - node.decorators = decorators; - setModifiers(node, modifiers); - return finishNode(node); - } - } - } - function nextTokenIsIdentifierOrStringLiteralOnSameLine() { - nextToken(); - return !scanner.hasPrecedingLineBreak() && (isIdentifier() || token === 8 /* StringLiteral */); - } - function parseFunctionBlockOrSemicolon(isGenerator, diagnosticMessage) { - if (token !== 14 /* OpenBraceToken */ && canParseSemicolon()) { - parseSemicolon(); - return; - } - return parseFunctionBlock(isGenerator, false, diagnosticMessage); - } - // DECLARATIONS - function parseArrayBindingElement() { - if (token === 23 /* CommaToken */) { - return createNode(178 /* OmittedExpression */); - } - var node = createNode(155 /* BindingElement */); - node.dotDotDotToken = parseOptionalToken(21 /* DotDotDotToken */); - node.name = parseIdentifierOrPattern(); - node.initializer = parseInitializer(false); - return finishNode(node); - } - function parseObjectBindingElement() { - var node = createNode(155 /* BindingElement */); - // TODO(andersh): Handle computed properties - var tokenIsIdentifier = isIdentifier(); - var propertyName = parsePropertyName(); - if (tokenIsIdentifier && token !== 51 /* ColonToken */) { - node.name = propertyName; - } - else { - parseExpected(51 /* ColonToken */); - node.propertyName = propertyName; - node.name = parseIdentifierOrPattern(); - } - node.initializer = parseInitializer(false); - return finishNode(node); - } - function parseObjectBindingPattern() { - var node = createNode(153 /* ObjectBindingPattern */); - parseExpected(14 /* OpenBraceToken */); - node.elements = parseDelimitedList(9 /* ObjectBindingElements */, parseObjectBindingElement); - parseExpected(15 /* CloseBraceToken */); - return finishNode(node); - } - function parseArrayBindingPattern() { - var node = createNode(154 /* ArrayBindingPattern */); - parseExpected(18 /* OpenBracketToken */); - node.elements = parseDelimitedList(10 /* ArrayBindingElements */, parseArrayBindingElement); - parseExpected(19 /* CloseBracketToken */); - return finishNode(node); - } - function isIdentifierOrPattern() { - return token === 14 /* OpenBraceToken */ || token === 18 /* OpenBracketToken */ || isIdentifier(); - } - function parseIdentifierOrPattern() { - if (token === 18 /* OpenBracketToken */) { - return parseArrayBindingPattern(); - } - if (token === 14 /* OpenBraceToken */) { - return parseObjectBindingPattern(); - } - return parseIdentifier(); - } - function parseVariableDeclaration() { - var node = createNode(201 /* VariableDeclaration */); - node.name = parseIdentifierOrPattern(); - node.type = parseTypeAnnotation(); - if (!isInOrOfKeyword(token)) { - node.initializer = parseInitializer(false); - } - return finishNode(node); - } - function parseVariableDeclarationList(inForStatementInitializer) { - var node = createNode(202 /* VariableDeclarationList */); - switch (token) { - case 98 /* VarKeyword */: - break; - case 104 /* LetKeyword */: - node.flags |= 4096 /* Let */; - break; - case 70 /* ConstKeyword */: - node.flags |= 8192 /* Const */; - break; - default: - ts.Debug.fail(); - } - nextToken(); - // The user may have written the following: - // - // for (let of X) { } - // - // In this case, we want to parse an empty declaration list, and then parse 'of' - // as a keyword. The reason this is not automatic is that 'of' is a valid identifier. - // So we need to look ahead to determine if 'of' should be treated as a keyword in - // this context. - // The checker will then give an error that there is an empty declaration list. - if (token === 127 /* OfKeyword */ && lookAhead(canFollowContextualOfKeyword)) { - node.declarations = createMissingList(); - } - else { - var savedDisallowIn = inDisallowInContext(); - setDisallowInContext(inForStatementInitializer); - node.declarations = parseDelimitedList(8 /* VariableDeclarations */, parseVariableDeclaration); - setDisallowInContext(savedDisallowIn); - } - return finishNode(node); - } - function canFollowContextualOfKeyword() { - return nextTokenIsIdentifier() && nextToken() === 17 /* CloseParenToken */; - } - function parseVariableStatement(fullStart, decorators, modifiers) { - var node = createNode(183 /* VariableStatement */, fullStart); - node.decorators = decorators; - setModifiers(node, modifiers); - node.declarationList = parseVariableDeclarationList(false); - parseSemicolon(); - return finishNode(node); - } - function parseFunctionDeclaration(fullStart, decorators, modifiers) { - var node = createNode(203 /* FunctionDeclaration */, fullStart); - node.decorators = decorators; - setModifiers(node, modifiers); - parseExpected(83 /* FunctionKeyword */); - node.asteriskToken = parseOptionalToken(35 /* AsteriskToken */); - node.name = node.flags & 256 /* Default */ ? parseOptionalIdentifier() : parseIdentifier(); - fillSignature(51 /* ColonToken */, !!node.asteriskToken, false, node); - node.body = parseFunctionBlockOrSemicolon(!!node.asteriskToken, ts.Diagnostics.or_expected); - return finishNode(node); - } - function parseConstructorDeclaration(pos, decorators, modifiers) { - var node = createNode(137 /* Constructor */, pos); - node.decorators = decorators; - setModifiers(node, modifiers); - parseExpected(114 /* ConstructorKeyword */); - fillSignature(51 /* ColonToken */, false, false, node); - node.body = parseFunctionBlockOrSemicolon(false, ts.Diagnostics.or_expected); - return finishNode(node); - } - function parseMethodDeclaration(fullStart, decorators, modifiers, asteriskToken, name, questionToken, diagnosticMessage) { - var method = createNode(136 /* MethodDeclaration */, fullStart); - method.decorators = decorators; - setModifiers(method, modifiers); - method.asteriskToken = asteriskToken; - method.name = name; - method.questionToken = questionToken; - fillSignature(51 /* ColonToken */, !!asteriskToken, false, method); - method.body = parseFunctionBlockOrSemicolon(!!asteriskToken, diagnosticMessage); - return finishNode(method); - } - function parsePropertyDeclaration(fullStart, decorators, modifiers, name, questionToken) { - var property = createNode(134 /* PropertyDeclaration */, fullStart); - property.decorators = decorators; - setModifiers(property, modifiers); - property.name = name; - property.questionToken = questionToken; - property.type = parseTypeAnnotation(); - // For instance properties specifically, since they are evaluated inside the constructor, - // we do *not * want to parse yield expressions, so we specifically turn the yield context - // off. The grammar would look something like this: - // - // MemberVariableDeclaration[Yield]: - // AccessibilityModifier_opt PropertyName TypeAnnotation_opt Initialiser_opt[In]; - // AccessibilityModifier_opt static_opt PropertyName TypeAnnotation_opt Initialiser_opt[In, ?Yield]; - // - // The checker may still error in the static case to explicitly disallow the yield expression. - property.initializer = modifiers && modifiers.flags & 128 /* Static */ - ? allowInAnd(parseNonParameterInitializer) - : doOutsideOfContext(4 /* Yield */ | 2 /* DisallowIn */, parseNonParameterInitializer); - parseSemicolon(); - return finishNode(property); - } - function parsePropertyOrMethodDeclaration(fullStart, decorators, modifiers) { - var asteriskToken = parseOptionalToken(35 /* AsteriskToken */); - var name = parsePropertyName(); - // Note: this is not legal as per the grammar. But we allow it in the parser and - // report an error in the grammar checker. - var questionToken = parseOptionalToken(50 /* QuestionToken */); - if (asteriskToken || token === 16 /* OpenParenToken */ || token === 24 /* LessThanToken */) { - return parseMethodDeclaration(fullStart, decorators, modifiers, asteriskToken, name, questionToken, ts.Diagnostics.or_expected); - } - else { - return parsePropertyDeclaration(fullStart, decorators, modifiers, name, questionToken); - } - } - function parseNonParameterInitializer() { - return parseInitializer(false); - } - function parseAccessorDeclaration(kind, fullStart, decorators, modifiers) { - var node = createNode(kind, fullStart); - node.decorators = decorators; - setModifiers(node, modifiers); - node.name = parsePropertyName(); - fillSignature(51 /* ColonToken */, false, false, node); - node.body = parseFunctionBlockOrSemicolon(false); - return finishNode(node); - } - function isClassMemberModifier(idToken) { - switch (idToken) { - case 108 /* PublicKeyword */: - case 106 /* PrivateKeyword */: - case 107 /* ProtectedKeyword */: - case 109 /* StaticKeyword */: - return true; - default: - return false; - } - } - function isClassMemberStart() { - var idToken; - if (token === 52 /* AtToken */) { - return true; - } - // Eat up all modifiers, but hold on to the last one in case it is actually an identifier. - while (ts.isModifier(token)) { - idToken = token; - // If the idToken is a class modifier (protected, private, public, and static), it is - // certain that we are starting to parse class member. This allows better error recovery - // Example: - // public foo() ... // true - // public @dec blah ... // true; we will then report an error later - // export public ... // true; we will then report an error later - if (isClassMemberModifier(idToken)) { - return true; - } - nextToken(); - } - if (token === 35 /* AsteriskToken */) { - return true; - } - // Try to get the first property-like token following all modifiers. - // This can either be an identifier or the 'get' or 'set' keywords. - if (isLiteralPropertyName()) { - idToken = token; - nextToken(); - } - // Index signatures and computed properties are class members; we can parse. - if (token === 18 /* OpenBracketToken */) { - return true; - } - // If we were able to get any potential identifier... - if (idToken !== undefined) { - // If we have a non-keyword identifier, or if we have an accessor, then it's safe to parse. - if (!ts.isKeyword(idToken) || idToken === 122 /* SetKeyword */ || idToken === 116 /* GetKeyword */) { - return true; - } - // If it *is* a keyword, but not an accessor, check a little farther along - // to see if it should actually be parsed as a class member. - switch (token) { - case 16 /* OpenParenToken */: // Method declaration - case 24 /* LessThanToken */: // Generic Method declaration - case 51 /* ColonToken */: // Type Annotation for declaration - case 53 /* EqualsToken */: // Initializer for declaration - case 50 /* QuestionToken */: - return true; - default: - // Covers - // - Semicolons (declaration termination) - // - Closing braces (end-of-class, must be declaration) - // - End-of-files (not valid, but permitted so that it gets caught later on) - // - Line-breaks (enabling *automatic semicolon insertion*) - return canParseSemicolon(); - } - } - return false; - } - function parseDecorators() { - var decorators; - while (true) { - var decoratorStart = getNodePos(); - if (!parseOptional(52 /* AtToken */)) { - break; - } - if (!decorators) { - decorators = []; - decorators.pos = scanner.getStartPos(); - } - var decorator = createNode(132 /* Decorator */, decoratorStart); - decorator.expression = doInDecoratorContext(parseLeftHandSideExpressionOrHigher); - decorators.push(finishNode(decorator)); - } - if (decorators) { - decorators.end = getNodeEnd(); - } - return decorators; - } - function parseModifiers() { - var flags = 0; - var modifiers; - while (true) { - var modifierStart = scanner.getStartPos(); - var modifierKind = token; - if (!parseAnyContextualModifier()) { - break; - } - if (!modifiers) { - modifiers = []; - modifiers.pos = modifierStart; - } - flags |= ts.modifierToFlag(modifierKind); - modifiers.push(finishNode(createNode(modifierKind, modifierStart))); - } - if (modifiers) { - modifiers.flags = flags; - modifiers.end = scanner.getStartPos(); - } - return modifiers; - } - function parseClassElement() { - if (token === 22 /* SemicolonToken */) { - var result = createNode(181 /* SemicolonClassElement */); - nextToken(); - return finishNode(result); - } - var fullStart = getNodePos(); - var decorators = parseDecorators(); - var modifiers = parseModifiers(); - var accessor = tryParseAccessorDeclaration(fullStart, decorators, modifiers); - if (accessor) { - return accessor; - } - if (token === 114 /* ConstructorKeyword */) { - return parseConstructorDeclaration(fullStart, decorators, modifiers); - } - if (isIndexSignature()) { - return parseIndexSignatureDeclaration(fullStart, decorators, modifiers); - } - // It is very important that we check this *after* checking indexers because - // the [ token can start an index signature or a computed property name - if (isIdentifierOrKeyword() || - token === 8 /* StringLiteral */ || - token === 7 /* NumericLiteral */ || - token === 35 /* AsteriskToken */ || - token === 18 /* OpenBracketToken */) { - return parsePropertyOrMethodDeclaration(fullStart, decorators, modifiers); - } - if (decorators) { - // treat this as a property declaration with a missing name. - var name_6 = createMissingNode(65 /* Identifier */, true, ts.Diagnostics.Declaration_expected); - return parsePropertyDeclaration(fullStart, decorators, modifiers, name_6, undefined); - } - // 'isClassMemberStart' should have hinted not to attempt parsing. - ts.Debug.fail("Should not have attempted to parse class member declaration."); - } - function parseClassExpression() { - return parseClassDeclarationOrExpression( - /*fullStart*/ scanner.getStartPos(), - /*decorators*/ undefined, - /*modifiers*/ undefined, 177 /* ClassExpression */); - } - function parseClassDeclaration(fullStart, decorators, modifiers) { - return parseClassDeclarationOrExpression(fullStart, decorators, modifiers, 204 /* ClassDeclaration */); - } - function parseClassDeclarationOrExpression(fullStart, decorators, modifiers, kind) { - // In ES6 specification, All parts of a ClassDeclaration or a ClassExpression are strict mode code - var savedStrictModeContext = inStrictModeContext(); - setStrictModeContext(true); - var node = createNode(kind, fullStart); - node.decorators = decorators; - setModifiers(node, modifiers); - parseExpected(69 /* ClassKeyword */); - node.name = parseOptionalIdentifier(); - node.typeParameters = parseTypeParameters(); - node.heritageClauses = parseHeritageClauses(true); - if (parseExpected(14 /* OpenBraceToken */)) { - // ClassTail[Yield,GeneratorParameter] : See 14.5 - // [~GeneratorParameter]ClassHeritage[?Yield]opt { ClassBody[?Yield]opt } - // [+GeneratorParameter] ClassHeritageopt { ClassBodyopt } - node.members = inGeneratorParameterContext() - ? doOutsideOfYieldContext(parseClassMembers) - : parseClassMembers(); - parseExpected(15 /* CloseBraceToken */); - } - else { - node.members = createMissingList(); - } - var finishedNode = finishNode(node); - setStrictModeContext(savedStrictModeContext); - return finishedNode; - } - function parseHeritageClauses(isClassHeritageClause) { - // ClassTail[Yield,GeneratorParameter] : See 14.5 - // [~GeneratorParameter]ClassHeritage[?Yield]opt { ClassBody[?Yield]opt } - // [+GeneratorParameter] ClassHeritageopt { ClassBodyopt } - if (isHeritageClause()) { - return isClassHeritageClause && inGeneratorParameterContext() - ? doOutsideOfYieldContext(parseHeritageClausesWorker) - : parseHeritageClausesWorker(); - } - return undefined; - } - function parseHeritageClausesWorker() { - return parseList(18 /* HeritageClauses */, false, parseHeritageClause); - } - function parseHeritageClause() { - if (token === 79 /* ExtendsKeyword */ || token === 102 /* ImplementsKeyword */) { - var node = createNode(225 /* HeritageClause */); - node.token = token; - nextToken(); - node.types = parseDelimitedList(7 /* HeritageClauseElement */, parseExpressionWithTypeArguments); - return finishNode(node); - } - return undefined; - } - function parseExpressionWithTypeArguments() { - var node = createNode(179 /* ExpressionWithTypeArguments */); - node.expression = parseLeftHandSideExpressionOrHigher(); - if (token === 24 /* LessThanToken */) { - node.typeArguments = parseBracketedList(16 /* TypeArguments */, parseType, 24 /* LessThanToken */, 25 /* GreaterThanToken */); - } - return finishNode(node); - } - function isHeritageClause() { - return token === 79 /* ExtendsKeyword */ || token === 102 /* ImplementsKeyword */; - } - function parseClassMembers() { - return parseList(5 /* ClassMembers */, false, parseClassElement); - } - function parseInterfaceDeclaration(fullStart, decorators, modifiers) { - var node = createNode(205 /* InterfaceDeclaration */, fullStart); - node.decorators = decorators; - setModifiers(node, modifiers); - parseExpected(103 /* InterfaceKeyword */); - node.name = parseIdentifier(); - node.typeParameters = parseTypeParameters(); - node.heritageClauses = parseHeritageClauses(false); - node.members = parseObjectTypeMembers(); - return finishNode(node); - } - function parseTypeAliasDeclaration(fullStart, decorators, modifiers) { - var node = createNode(206 /* TypeAliasDeclaration */, fullStart); - node.decorators = decorators; - setModifiers(node, modifiers); - parseExpected(125 /* TypeKeyword */); - node.name = parseIdentifier(); - node.typeParameters = parseTypeParameters(); - parseExpected(53 /* EqualsToken */); - node.type = parseType(); - parseSemicolon(); - return finishNode(node); - } - // In an ambient declaration, the grammar only allows integer literals as initializers. - // In a non-ambient declaration, the grammar allows uninitialized members only in a - // ConstantEnumMemberSection, which starts at the beginning of an enum declaration - // or any time an integer literal initializer is encountered. - function parseEnumMember() { - var node = createNode(229 /* EnumMember */, scanner.getStartPos()); - node.name = parsePropertyName(); - node.initializer = allowInAnd(parseNonParameterInitializer); - return finishNode(node); - } - function parseEnumDeclaration(fullStart, decorators, modifiers) { - var node = createNode(207 /* EnumDeclaration */, fullStart); - node.decorators = decorators; - setModifiers(node, modifiers); - parseExpected(77 /* EnumKeyword */); - node.name = parseIdentifier(); - if (parseExpected(14 /* OpenBraceToken */)) { - node.members = parseDelimitedList(6 /* EnumMembers */, parseEnumMember); - parseExpected(15 /* CloseBraceToken */); - } - else { - node.members = createMissingList(); - } - return finishNode(node); - } - function parseModuleBlock() { - var node = createNode(209 /* ModuleBlock */, scanner.getStartPos()); - if (parseExpected(14 /* OpenBraceToken */)) { - node.statements = parseList(1 /* BlockStatements */, false, parseStatement); - parseExpected(15 /* CloseBraceToken */); - } - else { - node.statements = createMissingList(); - } - return finishNode(node); - } - function parseModuleOrNamespaceDeclaration(fullStart, decorators, modifiers, flags) { - var node = createNode(208 /* ModuleDeclaration */, fullStart); - node.decorators = decorators; - setModifiers(node, modifiers); - node.flags |= flags; - node.name = parseIdentifier(); - node.body = parseOptional(20 /* DotToken */) - ? parseModuleOrNamespaceDeclaration(getNodePos(), undefined, undefined, 1 /* Export */) - : parseModuleBlock(); - return finishNode(node); - } - function parseAmbientExternalModuleDeclaration(fullStart, decorators, modifiers) { - var node = createNode(208 /* ModuleDeclaration */, fullStart); - node.decorators = decorators; - setModifiers(node, modifiers); - node.name = parseLiteralNode(true); - node.body = parseModuleBlock(); - return finishNode(node); - } - function parseModuleDeclaration(fullStart, decorators, modifiers) { - var flags = modifiers ? modifiers.flags : 0; - if (parseOptional(119 /* NamespaceKeyword */)) { - flags |= 32768 /* Namespace */; - } - else { - parseExpected(118 /* ModuleKeyword */); - if (token === 8 /* StringLiteral */) { - return parseAmbientExternalModuleDeclaration(fullStart, decorators, modifiers); - } - } - return parseModuleOrNamespaceDeclaration(fullStart, decorators, modifiers, flags); - } - function isExternalModuleReference() { - return token === 120 /* RequireKeyword */ && - lookAhead(nextTokenIsOpenParen); - } - function nextTokenIsOpenParen() { - return nextToken() === 16 /* OpenParenToken */; - } - function nextTokenIsCommaOrFromKeyword() { - nextToken(); - return token === 23 /* CommaToken */ || - token === 126 /* FromKeyword */; - } - function parseImportDeclarationOrImportEqualsDeclaration(fullStart, decorators, modifiers) { - parseExpected(85 /* ImportKeyword */); - var afterImportPos = scanner.getStartPos(); - var identifier; - if (isIdentifier()) { - identifier = parseIdentifier(); - if (token !== 23 /* CommaToken */ && token !== 126 /* FromKeyword */) { - // ImportEquals declaration of type: - // import x = require("mod"); or - // import x = M.x; - var importEqualsDeclaration = createNode(211 /* ImportEqualsDeclaration */, fullStart); - importEqualsDeclaration.decorators = decorators; - setModifiers(importEqualsDeclaration, modifiers); - importEqualsDeclaration.name = identifier; - parseExpected(53 /* EqualsToken */); - importEqualsDeclaration.moduleReference = parseModuleReference(); - parseSemicolon(); - return finishNode(importEqualsDeclaration); - } - } - // Import statement - var importDeclaration = createNode(212 /* ImportDeclaration */, fullStart); - importDeclaration.decorators = decorators; - setModifiers(importDeclaration, modifiers); - // ImportDeclaration: - // import ImportClause from ModuleSpecifier ; - // import ModuleSpecifier; - if (identifier || - token === 35 /* AsteriskToken */ || - token === 14 /* OpenBraceToken */) { - importDeclaration.importClause = parseImportClause(identifier, afterImportPos); - parseExpected(126 /* FromKeyword */); - } - importDeclaration.moduleSpecifier = parseModuleSpecifier(); - parseSemicolon(); - return finishNode(importDeclaration); - } - function parseImportClause(identifier, fullStart) { - //ImportClause: - // ImportedDefaultBinding - // NameSpaceImport - // NamedImports - // ImportedDefaultBinding, NameSpaceImport - // ImportedDefaultBinding, NamedImports - var importClause = createNode(213 /* ImportClause */, fullStart); - if (identifier) { - // ImportedDefaultBinding: - // ImportedBinding - importClause.name = identifier; - } - // If there was no default import or if there is comma token after default import - // parse namespace or named imports - if (!importClause.name || - parseOptional(23 /* CommaToken */)) { - importClause.namedBindings = token === 35 /* AsteriskToken */ ? parseNamespaceImport() : parseNamedImportsOrExports(215 /* NamedImports */); - } - return finishNode(importClause); - } - function parseModuleReference() { - return isExternalModuleReference() - ? parseExternalModuleReference() - : parseEntityName(false); - } - function parseExternalModuleReference() { - var node = createNode(222 /* ExternalModuleReference */); - parseExpected(120 /* RequireKeyword */); - parseExpected(16 /* OpenParenToken */); - node.expression = parseModuleSpecifier(); - parseExpected(17 /* CloseParenToken */); - return finishNode(node); - } - function parseModuleSpecifier() { - // We allow arbitrary expressions here, even though the grammar only allows string - // literals. We check to ensure that it is only a string literal later in the grammar - // walker. - var result = parseExpression(); - // Ensure the string being required is in our 'identifier' table. This will ensure - // that features like 'find refs' will look inside this file when search for its name. - if (result.kind === 8 /* StringLiteral */) { - internIdentifier(result.text); - } - return result; - } - function parseNamespaceImport() { - // NameSpaceImport: - // * as ImportedBinding - var namespaceImport = createNode(214 /* NamespaceImport */); - parseExpected(35 /* AsteriskToken */); - parseExpected(111 /* AsKeyword */); - namespaceImport.name = parseIdentifier(); - return finishNode(namespaceImport); - } - function parseNamedImportsOrExports(kind) { - var node = createNode(kind); - // NamedImports: - // { } - // { ImportsList } - // { ImportsList, } - // ImportsList: - // ImportSpecifier - // ImportsList, ImportSpecifier - node.elements = parseBracketedList(19 /* ImportOrExportSpecifiers */, kind === 215 /* NamedImports */ ? parseImportSpecifier : parseExportSpecifier, 14 /* OpenBraceToken */, 15 /* CloseBraceToken */); - return finishNode(node); - } - function parseExportSpecifier() { - return parseImportOrExportSpecifier(220 /* ExportSpecifier */); - } - function parseImportSpecifier() { - return parseImportOrExportSpecifier(216 /* ImportSpecifier */); - } - function parseImportOrExportSpecifier(kind) { - var node = createNode(kind); - // ImportSpecifier: - // BindingIdentifier - // IdentifierName as BindingIdentifier - // ExportSpecififer: - // IdentifierName - // IdentifierName as IdentifierName - var checkIdentifierIsKeyword = ts.isKeyword(token) && !isIdentifier(); - var checkIdentifierStart = scanner.getTokenPos(); - var checkIdentifierEnd = scanner.getTextPos(); - var identifierName = parseIdentifierName(); - if (token === 111 /* AsKeyword */) { - node.propertyName = identifierName; - parseExpected(111 /* AsKeyword */); - checkIdentifierIsKeyword = ts.isKeyword(token) && !isIdentifier(); - checkIdentifierStart = scanner.getTokenPos(); - checkIdentifierEnd = scanner.getTextPos(); - node.name = parseIdentifierName(); - } - else { - node.name = identifierName; - } - if (kind === 216 /* ImportSpecifier */ && checkIdentifierIsKeyword) { - // Report error identifier expected - parseErrorAtPosition(checkIdentifierStart, checkIdentifierEnd - checkIdentifierStart, ts.Diagnostics.Identifier_expected); - } - return finishNode(node); - } - function parseExportDeclaration(fullStart, decorators, modifiers) { - var node = createNode(218 /* ExportDeclaration */, fullStart); - node.decorators = decorators; - setModifiers(node, modifiers); - if (parseOptional(35 /* AsteriskToken */)) { - parseExpected(126 /* FromKeyword */); - node.moduleSpecifier = parseModuleSpecifier(); - } - else { - node.exportClause = parseNamedImportsOrExports(219 /* NamedExports */); - if (parseOptional(126 /* FromKeyword */)) { - node.moduleSpecifier = parseModuleSpecifier(); - } - } - parseSemicolon(); - return finishNode(node); - } - function parseExportAssignment(fullStart, decorators, modifiers) { - var node = createNode(217 /* ExportAssignment */, fullStart); - node.decorators = decorators; - setModifiers(node, modifiers); - if (parseOptional(53 /* EqualsToken */)) { - node.isExportEquals = true; - } - else { - parseExpected(73 /* DefaultKeyword */); - } - node.expression = parseAssignmentExpressionOrHigher(); - parseSemicolon(); - return finishNode(node); - } - function processReferenceComments(sourceFile) { - var triviaScanner = ts.createScanner(sourceFile.languageVersion, false, sourceText); - var referencedFiles = []; - var amdDependencies = []; - var amdModuleName; - // Keep scanning all the leading trivia in the file until we get to something that - // isn't trivia. Any single line comment will be analyzed to see if it is a - // reference comment. - while (true) { - var kind = triviaScanner.scan(); - if (kind === 5 /* WhitespaceTrivia */ || kind === 4 /* NewLineTrivia */ || kind === 3 /* MultiLineCommentTrivia */) { - continue; - } - if (kind !== 2 /* SingleLineCommentTrivia */) { - break; - } - var range = { pos: triviaScanner.getTokenPos(), end: triviaScanner.getTextPos(), kind: triviaScanner.getToken() }; - var comment = sourceText.substring(range.pos, range.end); - var referencePathMatchResult = ts.getFileReferenceFromReferencePath(comment, range); - if (referencePathMatchResult) { - var fileReference = referencePathMatchResult.fileReference; - sourceFile.hasNoDefaultLib = referencePathMatchResult.isNoDefaultLib; - var diagnosticMessage = referencePathMatchResult.diagnosticMessage; - if (fileReference) { - referencedFiles.push(fileReference); - } - if (diagnosticMessage) { - parseDiagnostics.push(ts.createFileDiagnostic(sourceFile, range.pos, range.end - range.pos, diagnosticMessage)); - } - } - else { - var amdModuleNameRegEx = /^\/\/\/\s*".length; - return parseErrorAtPosition(start, end - start, ts.Diagnostics.Type_argument_list_cannot_be_empty); - } - } - function parseQualifiedName(left) { - var result = createNode(128 /* QualifiedName */, left.pos); - result.left = left; - result.right = parseIdentifierName(); - return finishNode(result); - } - function parseJSDocRecordType() { - var result = createNode(239 /* JSDocRecordType */); - nextToken(); - result.members = parseDelimitedList(22 /* JSDocRecordMembers */, parseJSDocRecordMember); - checkForTrailingComma(result.members); - parseExpected(15 /* CloseBraceToken */); - return finishNode(result); - } - function parseJSDocRecordMember() { - var result = createNode(240 /* JSDocRecordMember */); - result.name = parseSimplePropertyName(); - if (token === 51 /* ColonToken */) { - nextToken(); - result.type = parseJSDocType(); - } - return finishNode(result); - } - function parseJSDocNonNullableType() { - var result = createNode(238 /* JSDocNonNullableType */); - nextToken(); - result.type = parseJSDocType(); - return finishNode(result); - } - function parseJSDocTupleType() { - var result = createNode(236 /* JSDocTupleType */); - nextToken(); - result.types = parseDelimitedList(23 /* JSDocTupleTypes */, parseJSDocType); - checkForTrailingComma(result.types); - parseExpected(19 /* CloseBracketToken */); - return finishNode(result); - } - function checkForTrailingComma(list) { - if (parseDiagnostics.length === 0 && list.hasTrailingComma) { - var start = list.end - ",".length; - parseErrorAtPosition(start, ",".length, ts.Diagnostics.Trailing_comma_not_allowed); - } - } - function parseJSDocUnionType() { - var result = createNode(235 /* JSDocUnionType */); - nextToken(); - result.types = parseJSDocTypeList(parseJSDocType()); - parseExpected(17 /* CloseParenToken */); - return finishNode(result); - } - function parseJSDocTypeList(firstType) { - ts.Debug.assert(!!firstType); - var types = []; - types.pos = firstType.pos; - types.push(firstType); - while (parseOptional(44 /* BarToken */)) { - types.push(parseJSDocType()); - } - types.end = scanner.getStartPos(); - return types; - } - function parseJSDocAllType() { - var result = createNode(232 /* JSDocAllType */); - nextToken(); - return finishNode(result); - } - function parseJSDocUnknownOrNullableType() { - var pos = scanner.getStartPos(); - // skip the ? - nextToken(); - // Need to lookahead to decide if this is a nullable or unknown type. - // Here are cases where we'll pick the unknown type: - // - // Foo(?, - // { a: ? } - // Foo(?) - // Foo - // Foo(?= - // (?| - if (token === 23 /* CommaToken */ || - token === 15 /* CloseBraceToken */ || - token === 17 /* CloseParenToken */ || - token === 25 /* GreaterThanToken */ || - token === 53 /* EqualsToken */ || - token === 44 /* BarToken */) { - var result = createNode(233 /* JSDocUnknownType */, pos); - return finishNode(result); - } - else { - var result = createNode(237 /* JSDocNullableType */, pos); - result.type = parseJSDocType(); - return finishNode(result); - } - } - function parseIsolatedJSDocComment(content, start, length) { - initializeState("file.js", content, 2 /* Latest */, undefined); - var jsDocComment = parseJSDocComment(undefined, start, length); - var diagnostics = parseDiagnostics; - clearState(); - return jsDocComment ? { jsDocComment: jsDocComment, diagnostics: diagnostics } : undefined; - } - JSDocParser.parseIsolatedJSDocComment = parseIsolatedJSDocComment; - function parseJSDocComment(parent, start, length) { - var comment = parseJSDocCommentWorker(start, length); - if (comment) { - fixupParentReferences(comment); - comment.parent = parent; - } - return comment; - } - JSDocParser.parseJSDocComment = parseJSDocComment; - function parseJSDocCommentWorker(start, length) { - var content = sourceText; - start = start || 0; - var end = length === undefined ? content.length : start + length; - length = end - start; - ts.Debug.assert(start >= 0); - ts.Debug.assert(start <= end); - ts.Debug.assert(end <= content.length); - var tags; - var pos; - // NOTE(cyrusn): This is essentially a handwritten scanner for JSDocComments. I - // considered using an actual Scanner, but this would complicate things. The - // scanner would need to know it was in a Doc Comment. Otherwise, it would then - // produce comments *inside* the doc comment. In the end it was just easier to - // write a simple scanner rather than go that route. - if (length >= "/** */".length) { - if (content.charCodeAt(start) === 47 /* slash */ && - content.charCodeAt(start + 1) === 42 /* asterisk */ && - content.charCodeAt(start + 2) === 42 /* asterisk */ && - content.charCodeAt(start + 3) !== 42 /* asterisk */) { - // Initially we can parse out a tag. We also have seen a starting asterisk. - // This is so that /** * @type */ doesn't parse. - var canParseTag = true; - var seenAsterisk = true; - for (pos = start + "/**".length; pos < end;) { - var ch = content.charCodeAt(pos); - pos++; - if (ch === 64 /* at */ && canParseTag) { - parseTag(); - // Once we parse out a tag, we cannot keep parsing out tags on this line. - canParseTag = false; - continue; - } - if (ts.isLineBreak(ch)) { - // After a line break, we can parse a tag, and we haven't seen as asterisk - // on the next line yet. - canParseTag = true; - seenAsterisk = false; - continue; - } - if (ts.isWhiteSpace(ch)) { - // Whitespace doesn't affect any of our parsing. - continue; - } - // Ignore the first asterisk on a line. - if (ch === 42 /* asterisk */) { - if (seenAsterisk) { - // If we've already seen an asterisk, then we can no longer parse a tag - // on this line. - canParseTag = false; - } - seenAsterisk = true; - continue; - } - // Anything else is doc comment text. We can't do anything with it. Because it - // wasn't a tag, we can no longer parse a tag on this line until we hit the next - // line break. - canParseTag = false; - } - } - } - return createJSDocComment(); - function createJSDocComment() { - if (!tags) { - return undefined; - } - var result = createNode(247 /* JSDocComment */, start); - result.tags = tags; - return finishNode(result, end); - } - function skipWhitespace() { - while (pos < end && ts.isWhiteSpace(content.charCodeAt(pos))) { - pos++; - } - } - function parseTag() { - ts.Debug.assert(content.charCodeAt(pos - 1) === 64 /* at */); - var atToken = createNode(52 /* AtToken */, pos - 1); - atToken.end = pos; - var startPos = pos; - var tagName = scanIdentifier(); - if (!tagName) { - return; - } - var tag = handleTag(atToken, tagName) || handleUnknownTag(atToken, tagName); - addTag(tag); - } - function handleTag(atToken, tagName) { - if (tagName) { - switch (tagName.text) { - case "param": - return handleParamTag(atToken, tagName); - case "return": - case "returns": - return handleReturnTag(atToken, tagName); - case "template": - return handleTemplateTag(atToken, tagName); - case "type": - return handleTypeTag(atToken, tagName); - } - } - return undefined; - } - function handleUnknownTag(atToken, tagName) { - var result = createNode(248 /* JSDocTag */, atToken.pos); - result.atToken = atToken; - result.tagName = tagName; - return finishNode(result, pos); - } - function addTag(tag) { - if (tag) { - if (!tags) { - tags = []; - tags.pos = tag.pos; - } - tags.push(tag); - tags.end = tag.end; - } - } - function tryParseTypeExpression() { - skipWhitespace(); - if (content.charCodeAt(pos) !== 123 /* openBrace */) { - return undefined; - } - var typeExpression = parseJSDocTypeExpression(pos, end - pos); - pos = typeExpression.end; - return typeExpression; - } - function handleParamTag(atToken, tagName) { - var typeExpression = tryParseTypeExpression(); - skipWhitespace(); - var name; - var isBracketed; - if (content.charCodeAt(pos) === 91 /* openBracket */) { - pos++; - skipWhitespace(); - name = scanIdentifier(); - isBracketed = true; - } - else { - name = scanIdentifier(); - } - if (!name) { - parseErrorAtPosition(pos, 0, ts.Diagnostics.Identifier_expected); - return undefined; - } - var preName, postName; - if (typeExpression) { - postName = name; - } - else { - preName = name; - } - if (!typeExpression) { - typeExpression = tryParseTypeExpression(); - } - var result = createNode(249 /* JSDocParameterTag */, atToken.pos); - result.atToken = atToken; - result.tagName = tagName; - result.preParameterName = preName; - result.typeExpression = typeExpression; - result.postParameterName = postName; - result.isBracketed = isBracketed; - return finishNode(result, pos); - } - function handleReturnTag(atToken, tagName) { - if (ts.forEach(tags, function (t) { return t.kind === 250 /* JSDocReturnTag */; })) { - parseErrorAtPosition(tagName.pos, pos - tagName.pos, ts.Diagnostics._0_tag_already_specified, tagName.text); - } - var result = createNode(250 /* JSDocReturnTag */, atToken.pos); - result.atToken = atToken; - result.tagName = tagName; - result.typeExpression = tryParseTypeExpression(); - return finishNode(result, pos); - } - function handleTypeTag(atToken, tagName) { - if (ts.forEach(tags, function (t) { return t.kind === 251 /* JSDocTypeTag */; })) { - parseErrorAtPosition(tagName.pos, pos - tagName.pos, ts.Diagnostics._0_tag_already_specified, tagName.text); - } - var result = createNode(251 /* JSDocTypeTag */, atToken.pos); - result.atToken = atToken; - result.tagName = tagName; - result.typeExpression = tryParseTypeExpression(); - return finishNode(result, pos); - } - function handleTemplateTag(atToken, tagName) { - if (ts.forEach(tags, function (t) { return t.kind === 252 /* JSDocTemplateTag */; })) { - parseErrorAtPosition(tagName.pos, pos - tagName.pos, ts.Diagnostics._0_tag_already_specified, tagName.text); - } - var typeParameters = []; - typeParameters.pos = pos; - while (true) { - skipWhitespace(); - var startPos = pos; - var name_7 = scanIdentifier(); - if (!name_7) { - parseErrorAtPosition(startPos, 0, ts.Diagnostics.Identifier_expected); - return undefined; - } - var typeParameter = createNode(130 /* TypeParameter */, name_7.pos); - typeParameter.name = name_7; - finishNode(typeParameter, pos); - typeParameters.push(typeParameter); - skipWhitespace(); - if (content.charCodeAt(pos) !== 44 /* comma */) { - break; - } - pos++; - } - typeParameters.end = pos; - var result = createNode(252 /* JSDocTemplateTag */, atToken.pos); - result.atToken = atToken; - result.tagName = tagName; - result.typeParameters = typeParameters; - return finishNode(result, pos); - } - function scanIdentifier() { - var startPos = pos; - for (; pos < end; pos++) { - var ch = content.charCodeAt(pos); - if (pos === startPos && ts.isIdentifierStart(ch, 2 /* Latest */)) { - continue; - } - else if (pos > startPos && ts.isIdentifierPart(ch, 2 /* Latest */)) { - continue; - } - break; - } - if (startPos === pos) { - return undefined; - } - var result = createNode(65 /* Identifier */, startPos); - result.text = content.substring(startPos, pos); - return finishNode(result, pos); - } - } - JSDocParser.parseJSDocCommentWorker = parseJSDocCommentWorker; - })(JSDocParser = Parser.JSDocParser || (Parser.JSDocParser = {})); - })(Parser || (Parser = {})); - var IncrementalParser; - (function (IncrementalParser) { - function updateSourceFile(sourceFile, newText, textChangeRange, aggressiveChecks) { - aggressiveChecks = aggressiveChecks || ts.Debug.shouldAssert(2 /* Aggressive */); - checkChangeRange(sourceFile, newText, textChangeRange, aggressiveChecks); - if (ts.textChangeRangeIsUnchanged(textChangeRange)) { - // if the text didn't change, then we can just return our current source file as-is. - return sourceFile; - } - if (sourceFile.statements.length === 0) { - // If we don't have any statements in the current source file, then there's no real - // way to incrementally parse. So just do a full parse instead. - return Parser.parseSourceFile(sourceFile.fileName, newText, sourceFile.languageVersion, undefined, true); - } - // Make sure we're not trying to incrementally update a source file more than once. Once - // we do an update the original source file is considered unusbale from that point onwards. - // - // This is because we do incremental parsing in-place. i.e. we take nodes from the old - // tree and give them new positions and parents. From that point on, trusting the old - // tree at all is not possible as far too much of it may violate invariants. - var incrementalSourceFile = sourceFile; - ts.Debug.assert(!incrementalSourceFile.hasBeenIncrementallyParsed); - incrementalSourceFile.hasBeenIncrementallyParsed = true; - var oldText = sourceFile.text; - var syntaxCursor = createSyntaxCursor(sourceFile); - // Make the actual change larger so that we know to reparse anything whose lookahead - // might have intersected the change. - var changeRange = extendToAffectedRange(sourceFile, textChangeRange); - checkChangeRange(sourceFile, newText, changeRange, aggressiveChecks); - // Ensure that extending the affected range only moved the start of the change range - // earlier in the file. - ts.Debug.assert(changeRange.span.start <= textChangeRange.span.start); - ts.Debug.assert(ts.textSpanEnd(changeRange.span) === ts.textSpanEnd(textChangeRange.span)); - ts.Debug.assert(ts.textSpanEnd(ts.textChangeRangeNewSpan(changeRange)) === ts.textSpanEnd(ts.textChangeRangeNewSpan(textChangeRange))); - // The is the amount the nodes after the edit range need to be adjusted. It can be - // positive (if the edit added characters), negative (if the edit deleted characters) - // or zero (if this was a pure overwrite with nothing added/removed). - var delta = ts.textChangeRangeNewSpan(changeRange).length - changeRange.span.length; - // If we added or removed characters during the edit, then we need to go and adjust all - // the nodes after the edit. Those nodes may move forward (if we inserted chars) or they - // may move backward (if we deleted chars). - // - // Doing this helps us out in two ways. First, it means that any nodes/tokens we want - // to reuse are already at the appropriate position in the new text. That way when we - // reuse them, we don't have to figure out if they need to be adjusted. Second, it makes - // it very easy to determine if we can reuse a node. If the node's position is at where - // we are in the text, then we can reuse it. Otherwise we can't. If the node's position - // is ahead of us, then we'll need to rescan tokens. If the node's position is behind - // us, then we'll need to skip it or crumble it as appropriate - // - // We will also adjust the positions of nodes that intersect the change range as well. - // By doing this, we ensure that all the positions in the old tree are consistent, not - // just the positions of nodes entirely before/after the change range. By being - // consistent, we can then easily map from positions to nodes in the old tree easily. - // - // Also, mark any syntax elements that intersect the changed span. We know, up front, - // that we cannot reuse these elements. - updateTokenPositionsAndMarkElements(incrementalSourceFile, changeRange.span.start, ts.textSpanEnd(changeRange.span), ts.textSpanEnd(ts.textChangeRangeNewSpan(changeRange)), delta, oldText, newText, aggressiveChecks); - // Now that we've set up our internal incremental state just proceed and parse the - // source file in the normal fashion. When possible the parser will retrieve and - // reuse nodes from the old tree. - // - // Note: passing in 'true' for setNodeParents is very important. When incrementally - // parsing, we will be reusing nodes from the old tree, and placing it into new - // parents. If we don't set the parents now, we'll end up with an observably - // inconsistent tree. Setting the parents on the new tree should be very fast. We - // will immediately bail out of walking any subtrees when we can see that their parents - // are already correct. - var result = Parser.parseSourceFile(sourceFile.fileName, newText, sourceFile.languageVersion, syntaxCursor, true); - return result; - } - IncrementalParser.updateSourceFile = updateSourceFile; - function moveElementEntirelyPastChangeRange(element, isArray, delta, oldText, newText, aggressiveChecks) { - if (isArray) { - visitArray(element); - } - else { - visitNode(element); - } - return; - function visitNode(node) { - if (aggressiveChecks && shouldCheckNode(node)) { - var text = oldText.substring(node.pos, node.end); - } - // Ditch any existing LS children we may have created. This way we can avoid - // moving them forward. - if (node._children) { - node._children = undefined; - } - if (node.jsDocComment) { - node.jsDocComment = undefined; - } - node.pos += delta; - node.end += delta; - if (aggressiveChecks && shouldCheckNode(node)) { - ts.Debug.assert(text === newText.substring(node.pos, node.end)); - } - forEachChild(node, visitNode, visitArray); - checkNodePositions(node, aggressiveChecks); - } - function visitArray(array) { - array._children = undefined; - array.pos += delta; - array.end += delta; - for (var _i = 0; _i < array.length; _i++) { - var node = array[_i]; - visitNode(node); - } - } - } - function shouldCheckNode(node) { - switch (node.kind) { - case 8 /* StringLiteral */: - case 7 /* NumericLiteral */: - case 65 /* Identifier */: - return true; - } - return false; - } - function adjustIntersectingElement(element, changeStart, changeRangeOldEnd, changeRangeNewEnd, delta) { - ts.Debug.assert(element.end >= changeStart, "Adjusting an element that was entirely before the change range"); - ts.Debug.assert(element.pos <= changeRangeOldEnd, "Adjusting an element that was entirely after the change range"); - ts.Debug.assert(element.pos <= element.end); - // We have an element that intersects the change range in some way. It may have its - // start, or its end (or both) in the changed range. We want to adjust any part - // that intersects such that the final tree is in a consistent state. i.e. all - // chlidren have spans within the span of their parent, and all siblings are ordered - // properly. - // We may need to update both the 'pos' and the 'end' of the element. - // If the 'pos' is before the start of the change, then we don't need to touch it. - // If it isn't, then the 'pos' must be inside the change. How we update it will - // depend if delta is positive or negative. If delta is positive then we have - // something like: - // - // -------------------AAA----------------- - // -------------------BBBCCCCCCC----------------- - // - // In this case, we consider any node that started in the change range to still be - // starting at the same position. - // - // however, if the delta is negative, then we instead have something like this: - // - // -------------------XXXYYYYYYY----------------- - // -------------------ZZZ----------------- - // - // In this case, any element that started in the 'X' range will keep its position. - // However any element htat started after that will have their pos adjusted to be - // at the end of the new range. i.e. any node that started in the 'Y' range will - // be adjusted to have their start at the end of the 'Z' range. - // - // The element will keep its position if possible. Or Move backward to the new-end - // if it's in the 'Y' range. - element.pos = Math.min(element.pos, changeRangeNewEnd); - // If the 'end' is after the change range, then we always adjust it by the delta - // amount. However, if the end is in the change range, then how we adjust it - // will depend on if delta is positive or negative. If delta is positive then we - // have something like: - // - // -------------------AAA----------------- - // -------------------BBBCCCCCCC----------------- - // - // In this case, we consider any node that ended inside the change range to keep its - // end position. - // - // however, if the delta is negative, then we instead have something like this: - // - // -------------------XXXYYYYYYY----------------- - // -------------------ZZZ----------------- - // - // In this case, any element that ended in the 'X' range will keep its position. - // However any element htat ended after that will have their pos adjusted to be - // at the end of the new range. i.e. any node that ended in the 'Y' range will - // be adjusted to have their end at the end of the 'Z' range. - if (element.end >= changeRangeOldEnd) { - // Element ends after the change range. Always adjust the end pos. - element.end += delta; - } - else { - // Element ends in the change range. The element will keep its position if - // possible. Or Move backward to the new-end if it's in the 'Y' range. - element.end = Math.min(element.end, changeRangeNewEnd); - } - ts.Debug.assert(element.pos <= element.end); - if (element.parent) { - ts.Debug.assert(element.pos >= element.parent.pos); - ts.Debug.assert(element.end <= element.parent.end); - } - } - function checkNodePositions(node, aggressiveChecks) { - if (aggressiveChecks) { - var pos = node.pos; - forEachChild(node, function (child) { - ts.Debug.assert(child.pos >= pos); - pos = child.end; - }); - ts.Debug.assert(pos <= node.end); - } - } - function updateTokenPositionsAndMarkElements(sourceFile, changeStart, changeRangeOldEnd, changeRangeNewEnd, delta, oldText, newText, aggressiveChecks) { - visitNode(sourceFile); - return; - function visitNode(child) { - ts.Debug.assert(child.pos <= child.end); - if (child.pos > changeRangeOldEnd) { - // Node is entirely past the change range. We need to move both its pos and - // end, forward or backward appropriately. - moveElementEntirelyPastChangeRange(child, false, delta, oldText, newText, aggressiveChecks); - return; - } - // Check if the element intersects the change range. If it does, then it is not - // reusable. Also, we'll need to recurse to see what constituent portions we may - // be able to use. - var fullEnd = child.end; - if (fullEnd >= changeStart) { - child.intersectsChange = true; - child._children = undefined; - // Adjust the pos or end (or both) of the intersecting element accordingly. - adjustIntersectingElement(child, changeStart, changeRangeOldEnd, changeRangeNewEnd, delta); - forEachChild(child, visitNode, visitArray); - checkNodePositions(child, aggressiveChecks); - return; - } - // Otherwise, the node is entirely before the change range. No need to do anything with it. - ts.Debug.assert(fullEnd < changeStart); - } - function visitArray(array) { - ts.Debug.assert(array.pos <= array.end); - if (array.pos > changeRangeOldEnd) { - // Array is entirely after the change range. We need to move it, and move any of - // its children. - moveElementEntirelyPastChangeRange(array, true, delta, oldText, newText, aggressiveChecks); - return; - } - // Check if the element intersects the change range. If it does, then it is not - // reusable. Also, we'll need to recurse to see what constituent portions we may - // be able to use. - var fullEnd = array.end; - if (fullEnd >= changeStart) { - array.intersectsChange = true; - array._children = undefined; - // Adjust the pos or end (or both) of the intersecting array accordingly. - adjustIntersectingElement(array, changeStart, changeRangeOldEnd, changeRangeNewEnd, delta); - for (var _i = 0; _i < array.length; _i++) { - var node = array[_i]; - visitNode(node); - } - return; - } - // Otherwise, the array is entirely before the change range. No need to do anything with it. - ts.Debug.assert(fullEnd < changeStart); - } - } - function extendToAffectedRange(sourceFile, changeRange) { - // Consider the following code: - // void foo() { /; } - // - // If the text changes with an insertion of / just before the semicolon then we end up with: - // void foo() { //; } - // - // If we were to just use the changeRange a is, then we would not rescan the { token - // (as it does not intersect the actual original change range). Because an edit may - // change the token touching it, we actually need to look back *at least* one token so - // that the prior token sees that change. - var maxLookahead = 1; - var start = changeRange.span.start; - // the first iteration aligns us with the change start. subsequent iteration move us to - // the left by maxLookahead tokens. We only need to do this as long as we're not at the - // start of the tree. - for (var i = 0; start > 0 && i <= maxLookahead; i++) { - var nearestNode = findNearestNodeStartingBeforeOrAtPosition(sourceFile, start); - ts.Debug.assert(nearestNode.pos <= start); - var position = nearestNode.pos; - start = Math.max(0, position - 1); - } - var finalSpan = ts.createTextSpanFromBounds(start, ts.textSpanEnd(changeRange.span)); - var finalLength = changeRange.newLength + (changeRange.span.start - start); - return ts.createTextChangeRange(finalSpan, finalLength); - } - function findNearestNodeStartingBeforeOrAtPosition(sourceFile, position) { - var bestResult = sourceFile; - var lastNodeEntirelyBeforePosition; - forEachChild(sourceFile, visit); - if (lastNodeEntirelyBeforePosition) { - var lastChildOfLastEntireNodeBeforePosition = getLastChild(lastNodeEntirelyBeforePosition); - if (lastChildOfLastEntireNodeBeforePosition.pos > bestResult.pos) { - bestResult = lastChildOfLastEntireNodeBeforePosition; - } - } - return bestResult; - function getLastChild(node) { - while (true) { - var lastChild = getLastChildWorker(node); - if (lastChild) { - node = lastChild; - } - else { - return node; - } - } - } - function getLastChildWorker(node) { - var last = undefined; - forEachChild(node, function (child) { - if (ts.nodeIsPresent(child)) { - last = child; - } - }); - return last; - } - function visit(child) { - if (ts.nodeIsMissing(child)) { - // Missing nodes are effectively invisible to us. We never even consider them - // When trying to find the nearest node before us. - return; - } - // If the child intersects this position, then this node is currently the nearest - // node that starts before the position. - if (child.pos <= position) { - if (child.pos >= bestResult.pos) { - // This node starts before the position, and is closer to the position than - // the previous best node we found. It is now the new best node. - bestResult = child; - } - // Now, the node may overlap the position, or it may end entirely before the - // position. If it overlaps with the position, then either it, or one of its - // children must be the nearest node before the position. So we can just - // recurse into this child to see if we can find something better. - if (position < child.end) { - // The nearest node is either this child, or one of the children inside - // of it. We've already marked this child as the best so far. Recurse - // in case one of the children is better. - forEachChild(child, visit); - // Once we look at the children of this node, then there's no need to - // continue any further. - return true; - } - else { - ts.Debug.assert(child.end <= position); - // The child ends entirely before this position. Say you have the following - // (where $ is the position) - // - // ? $ : <...> <...> - // - // We would want to find the nearest preceding node in "complex expr 2". - // To support that, we keep track of this node, and once we're done searching - // for a best node, we recurse down this node to see if we can find a good - // result in it. - // - // This approach allows us to quickly skip over nodes that are entirely - // before the position, while still allowing us to find any nodes in the - // last one that might be what we want. - lastNodeEntirelyBeforePosition = child; - } - } - else { - ts.Debug.assert(child.pos > position); - // We're now at a node that is entirely past the position we're searching for. - // This node (and all following nodes) could never contribute to the result, - // so just skip them by returning 'true' here. - return true; - } - } - } - function checkChangeRange(sourceFile, newText, textChangeRange, aggressiveChecks) { - var oldText = sourceFile.text; - if (textChangeRange) { - ts.Debug.assert((oldText.length - textChangeRange.span.length + textChangeRange.newLength) === newText.length); - if (aggressiveChecks || ts.Debug.shouldAssert(3 /* VeryAggressive */)) { - var oldTextPrefix = oldText.substr(0, textChangeRange.span.start); - var newTextPrefix = newText.substr(0, textChangeRange.span.start); - ts.Debug.assert(oldTextPrefix === newTextPrefix); - var oldTextSuffix = oldText.substring(ts.textSpanEnd(textChangeRange.span), oldText.length); - var newTextSuffix = newText.substring(ts.textSpanEnd(ts.textChangeRangeNewSpan(textChangeRange)), newText.length); - ts.Debug.assert(oldTextSuffix === newTextSuffix); - } - } - } - function createSyntaxCursor(sourceFile) { - var currentArray = sourceFile.statements; - var currentArrayIndex = 0; - ts.Debug.assert(currentArrayIndex < currentArray.length); - var current = currentArray[currentArrayIndex]; - var lastQueriedPosition = -1 /* Value */; - return { - currentNode: function (position) { - // Only compute the current node if the position is different than the last time - // we were asked. The parser commonly asks for the node at the same position - // twice. Once to know if can read an appropriate list element at a certain point, - // and then to actually read and consume the node. - if (position !== lastQueriedPosition) { - // Much of the time the parser will need the very next node in the array that - // we just returned a node from.So just simply check for that case and move - // forward in the array instead of searching for the node again. - if (current && current.end === position && currentArrayIndex < (currentArray.length - 1)) { - currentArrayIndex++; - current = currentArray[currentArrayIndex]; - } - // If we don't have a node, or the node we have isn't in the right position, - // then try to find a viable node at the position requested. - if (!current || current.pos !== position) { - findHighestListElementThatStartsAtPosition(position); - } - } - // Cache this query so that we don't do any extra work if the parser calls back - // into us. Note: this is very common as the parser will make pairs of calls like - // 'isListElement -> parseListElement'. If we were unable to find a node when - // called with 'isListElement', we don't want to redo the work when parseListElement - // is called immediately after. - lastQueriedPosition = position; - // Either we don'd have a node, or we have a node at the position being asked for. - ts.Debug.assert(!current || current.pos === position); - return current; - } - }; - // Finds the highest element in the tree we can find that starts at the provided position. - // The element must be a direct child of some node list in the tree. This way after we - // return it, we can easily return its next sibling in the list. - function findHighestListElementThatStartsAtPosition(position) { - // Clear out any cached state about the last node we found. - currentArray = undefined; - currentArrayIndex = -1 /* Value */; - current = undefined; - // Recurse into the source file to find the highest node at this position. - forEachChild(sourceFile, visitNode, visitArray); - return; - function visitNode(node) { - if (position >= node.pos && position < node.end) { - // Position was within this node. Keep searching deeper to find the node. - forEachChild(node, visitNode, visitArray); - // don't procede any futher in the search. - return true; - } - // position wasn't in this node, have to keep searching. - return false; - } - function visitArray(array) { - if (position >= array.pos && position < array.end) { - // position was in this array. Search through this array to see if we find a - // viable element. - for (var i = 0, n = array.length; i < n; i++) { - var child = array[i]; - if (child) { - if (child.pos === position) { - // Found the right node. We're done. - currentArray = array; - currentArrayIndex = i; - current = child; - return true; - } - else { - if (child.pos < position && position < child.end) { - // Position in somewhere within this child. Search in it and - // stop searching in this array. - forEachChild(child, visitNode, visitArray); - return true; - } - } - } - } - } - // position wasn't in this array, have to keep searching. - return false; - } - } - } - var InvalidPosition; - (function (InvalidPosition) { - InvalidPosition[InvalidPosition["Value"] = -1] = "Value"; - })(InvalidPosition || (InvalidPosition = {})); - })(IncrementalParser || (IncrementalParser = {})); -})(ts || (ts = {})); -/// -/* @internal */ -var ts; -(function (ts) { - var nextSymbolId = 1; - var nextNodeId = 1; - var nextMergeId = 1; - function getNodeId(node) { - if (!node.id) - node.id = nextNodeId++; - return node.id; - } - ts.getNodeId = getNodeId; - ts.checkTime = 0; - function getSymbolId(symbol) { - if (!symbol.id) { - symbol.id = nextSymbolId++; - } - return symbol.id; - } - ts.getSymbolId = getSymbolId; - function createTypeChecker(host, produceDiagnostics) { - var Symbol = ts.objectAllocator.getSymbolConstructor(); - var Type = ts.objectAllocator.getTypeConstructor(); - var Signature = ts.objectAllocator.getSignatureConstructor(); - var typeCount = 0; - var emptyArray = []; - var emptySymbols = {}; - var compilerOptions = host.getCompilerOptions(); - var languageVersion = compilerOptions.target || 0 /* ES3 */; - var emitResolver = createResolver(); - var undefinedSymbol = createSymbol(4 /* Property */ | 67108864 /* Transient */, "undefined"); - var argumentsSymbol = createSymbol(4 /* Property */ | 67108864 /* Transient */, "arguments"); - var checker = { - getNodeCount: function () { return ts.sum(host.getSourceFiles(), "nodeCount"); }, - getIdentifierCount: function () { return ts.sum(host.getSourceFiles(), "identifierCount"); }, - getSymbolCount: function () { return ts.sum(host.getSourceFiles(), "symbolCount"); }, - getTypeCount: function () { return typeCount; }, - isUndefinedSymbol: function (symbol) { return symbol === undefinedSymbol; }, - isArgumentsSymbol: function (symbol) { return symbol === argumentsSymbol; }, - getDiagnostics: getDiagnostics, - getGlobalDiagnostics: getGlobalDiagnostics, - getTypeOfSymbolAtLocation: getTypeOfSymbolAtLocation, - getDeclaredTypeOfSymbol: getDeclaredTypeOfSymbol, - getPropertiesOfType: getPropertiesOfType, - getPropertyOfType: getPropertyOfType, - getSignaturesOfType: getSignaturesOfType, - getIndexTypeOfType: getIndexTypeOfType, - getReturnTypeOfSignature: getReturnTypeOfSignature, - getSymbolsInScope: getSymbolsInScope, - getSymbolAtLocation: getSymbolAtLocation, - getShorthandAssignmentValueSymbol: getShorthandAssignmentValueSymbol, - getTypeAtLocation: getTypeAtLocation, - typeToString: typeToString, - getSymbolDisplayBuilder: getSymbolDisplayBuilder, - symbolToString: symbolToString, - getAugmentedPropertiesOfType: getAugmentedPropertiesOfType, - getRootSymbols: getRootSymbols, - getContextualType: getContextualType, - getFullyQualifiedName: getFullyQualifiedName, - getResolvedSignature: getResolvedSignature, - getConstantValue: getConstantValue, - isValidPropertyAccess: isValidPropertyAccess, - getSignatureFromDeclaration: getSignatureFromDeclaration, - isImplementationOfOverload: isImplementationOfOverload, - getAliasedSymbol: resolveAlias, - getEmitResolver: getEmitResolver, - getExportsOfModule: getExportsOfModuleAsArray - }; - var unknownSymbol = createSymbol(4 /* Property */ | 67108864 /* Transient */, "unknown"); - var resolvingSymbol = createSymbol(67108864 /* Transient */, "__resolving__"); - var anyType = createIntrinsicType(1 /* Any */, "any"); - var stringType = createIntrinsicType(2 /* String */, "string"); - var numberType = createIntrinsicType(4 /* Number */, "number"); - var booleanType = createIntrinsicType(8 /* Boolean */, "boolean"); - var esSymbolType = createIntrinsicType(2097152 /* ESSymbol */, "symbol"); - var voidType = createIntrinsicType(16 /* Void */, "void"); - var undefinedType = createIntrinsicType(32 /* Undefined */ | 524288 /* ContainsUndefinedOrNull */, "undefined"); - var nullType = createIntrinsicType(64 /* Null */ | 524288 /* ContainsUndefinedOrNull */, "null"); - var unknownType = createIntrinsicType(1 /* Any */, "unknown"); - var circularType = createIntrinsicType(1 /* Any */, "__circular__"); - var emptyObjectType = createAnonymousType(undefined, emptySymbols, emptyArray, emptyArray, undefined, undefined); - var emptyGenericType = createAnonymousType(undefined, emptySymbols, emptyArray, emptyArray, undefined, undefined); - emptyGenericType.instantiations = {}; - var anyFunctionType = createAnonymousType(undefined, emptySymbols, emptyArray, emptyArray, undefined, undefined); - var noConstraintType = createAnonymousType(undefined, emptySymbols, emptyArray, emptyArray, undefined, undefined); - var anySignature = createSignature(undefined, undefined, emptyArray, anyType, undefined, 0, false, false); - var unknownSignature = createSignature(undefined, undefined, emptyArray, unknownType, undefined, 0, false, false); - var globals = {}; - var globalESSymbolConstructorSymbol; - var globalObjectType; - var globalFunctionType; - var globalArrayType; - var globalStringType; - var globalNumberType; - var globalBooleanType; - var globalRegExpType; - var globalTemplateStringsArrayType; - var globalESSymbolType; - var globalIterableType; - var globalIteratorType; - var globalIterableIteratorType; - var anyArrayType; - var getGlobalClassDecoratorType; - var getGlobalParameterDecoratorType; - var getGlobalPropertyDecoratorType; - var getGlobalMethodDecoratorType; - var tupleTypes = {}; - var unionTypes = {}; - var stringLiteralTypes = {}; - var emitExtends = false; - var emitDecorate = false; - var emitParam = false; - var resolutionTargets = []; - var resolutionResults = []; - var mergedSymbols = []; - var symbolLinks = []; - var nodeLinks = []; - var potentialThisCollisions = []; - var diagnostics = ts.createDiagnosticCollection(); - var primitiveTypeInfo = { - "string": { - type: stringType, - flags: 258 /* StringLike */ - }, - "number": { - type: numberType, - flags: 132 /* NumberLike */ - }, - "boolean": { - type: booleanType, - flags: 8 /* Boolean */ - }, - "symbol": { - type: esSymbolType, - flags: 2097152 /* ESSymbol */ - } - }; - function getEmitResolver(sourceFile) { - // Ensure we have all the type information in place for this file so that all the - // emitter questions of this resolver will return the right information. - getDiagnostics(sourceFile); - return emitResolver; - } - function error(location, message, arg0, arg1, arg2) { - var diagnostic = location - ? ts.createDiagnosticForNode(location, message, arg0, arg1, arg2) - : ts.createCompilerDiagnostic(message, arg0, arg1, arg2); - diagnostics.add(diagnostic); - } - function createSymbol(flags, name) { - return new Symbol(flags, name); - } - function getExcludedSymbolFlags(flags) { - var result = 0; - if (flags & 2 /* BlockScopedVariable */) - result |= 107455 /* BlockScopedVariableExcludes */; - if (flags & 1 /* FunctionScopedVariable */) - result |= 107454 /* FunctionScopedVariableExcludes */; - if (flags & 4 /* Property */) - result |= 107455 /* PropertyExcludes */; - if (flags & 8 /* EnumMember */) - result |= 107455 /* EnumMemberExcludes */; - if (flags & 16 /* Function */) - result |= 106927 /* FunctionExcludes */; - if (flags & 32 /* Class */) - result |= 899583 /* ClassExcludes */; - if (flags & 64 /* Interface */) - result |= 792992 /* InterfaceExcludes */; - if (flags & 256 /* RegularEnum */) - result |= 899327 /* RegularEnumExcludes */; - if (flags & 128 /* ConstEnum */) - result |= 899967 /* ConstEnumExcludes */; - if (flags & 512 /* ValueModule */) - result |= 106639 /* ValueModuleExcludes */; - if (flags & 8192 /* Method */) - result |= 99263 /* MethodExcludes */; - if (flags & 32768 /* GetAccessor */) - result |= 41919 /* GetAccessorExcludes */; - if (flags & 65536 /* SetAccessor */) - result |= 74687 /* SetAccessorExcludes */; - if (flags & 262144 /* TypeParameter */) - result |= 530912 /* TypeParameterExcludes */; - if (flags & 524288 /* TypeAlias */) - result |= 793056 /* TypeAliasExcludes */; - if (flags & 8388608 /* Alias */) - result |= 8388608 /* AliasExcludes */; - return result; - } - function recordMergedSymbol(target, source) { - if (!source.mergeId) - source.mergeId = nextMergeId++; - mergedSymbols[source.mergeId] = target; - } - function cloneSymbol(symbol) { - var result = createSymbol(symbol.flags | 33554432 /* Merged */, symbol.name); - result.declarations = symbol.declarations.slice(0); - result.parent = symbol.parent; - if (symbol.valueDeclaration) - result.valueDeclaration = symbol.valueDeclaration; - if (symbol.constEnumOnlyModule) - result.constEnumOnlyModule = true; - if (symbol.members) - result.members = cloneSymbolTable(symbol.members); - if (symbol.exports) - result.exports = cloneSymbolTable(symbol.exports); - recordMergedSymbol(result, symbol); - return result; - } - function mergeSymbol(target, source) { - if (!(target.flags & getExcludedSymbolFlags(source.flags))) { - if (source.flags & 512 /* ValueModule */ && target.flags & 512 /* ValueModule */ && target.constEnumOnlyModule && !source.constEnumOnlyModule) { - // reset flag when merging instantiated module into value module that has only const enums - target.constEnumOnlyModule = false; - } - target.flags |= source.flags; - if (!target.valueDeclaration && source.valueDeclaration) - target.valueDeclaration = source.valueDeclaration; - ts.forEach(source.declarations, function (node) { - target.declarations.push(node); - }); - if (source.members) { - if (!target.members) - target.members = {}; - mergeSymbolTable(target.members, source.members); - } - if (source.exports) { - if (!target.exports) - target.exports = {}; - mergeSymbolTable(target.exports, source.exports); - } - recordMergedSymbol(target, source); - } - else { - var message = target.flags & 2 /* BlockScopedVariable */ || source.flags & 2 /* BlockScopedVariable */ - ? ts.Diagnostics.Cannot_redeclare_block_scoped_variable_0 : ts.Diagnostics.Duplicate_identifier_0; - ts.forEach(source.declarations, function (node) { - error(node.name ? node.name : node, message, symbolToString(source)); - }); - ts.forEach(target.declarations, function (node) { - error(node.name ? node.name : node, message, symbolToString(source)); - }); - } - } - function cloneSymbolTable(symbolTable) { - var result = {}; - for (var id in symbolTable) { - if (ts.hasProperty(symbolTable, id)) { - result[id] = symbolTable[id]; - } - } - return result; - } - function mergeSymbolTable(target, source) { - for (var id in source) { - if (ts.hasProperty(source, id)) { - if (!ts.hasProperty(target, id)) { - target[id] = source[id]; - } - else { - var symbol = target[id]; - if (!(symbol.flags & 33554432 /* Merged */)) { - target[id] = symbol = cloneSymbol(symbol); - } - mergeSymbol(symbol, source[id]); - } - } - } - } - function getSymbolLinks(symbol) { - if (symbol.flags & 67108864 /* Transient */) - return symbol; - var id = getSymbolId(symbol); - return symbolLinks[id] || (symbolLinks[id] = {}); - } - function getNodeLinks(node) { - var nodeId = getNodeId(node); - return nodeLinks[nodeId] || (nodeLinks[nodeId] = {}); - } - function getSourceFile(node) { - return ts.getAncestor(node, 230 /* SourceFile */); - } - function isGlobalSourceFile(node) { - return node.kind === 230 /* SourceFile */ && !ts.isExternalModule(node); - } - function getSymbol(symbols, name, meaning) { - if (meaning && ts.hasProperty(symbols, name)) { - var symbol = symbols[name]; - ts.Debug.assert((symbol.flags & 16777216 /* Instantiated */) === 0, "Should never get an instantiated symbol here."); - if (symbol.flags & meaning) { - return symbol; - } - if (symbol.flags & 8388608 /* Alias */) { - var target = resolveAlias(symbol); - // Unknown symbol means an error occurred in alias resolution, treat it as positive answer to avoid cascading errors - if (target === unknownSymbol || target.flags & meaning) { - return symbol; - } - } - } - // return undefined if we can't find a symbol. - } - /** Returns true if node1 is defined before node 2**/ - function isDefinedBefore(node1, node2) { - var file1 = ts.getSourceFileOfNode(node1); - var file2 = ts.getSourceFileOfNode(node2); - if (file1 === file2) { - return node1.pos <= node2.pos; - } - if (!compilerOptions.out) { - return true; - } - var sourceFiles = host.getSourceFiles(); - return sourceFiles.indexOf(file1) <= sourceFiles.indexOf(file2); - } - // Resolve a given name for a given meaning at a given location. An error is reported if the name was not found and - // the nameNotFoundMessage argument is not undefined. Returns the resolved symbol, or undefined if no symbol with - // the given name can be found. - function resolveName(location, name, meaning, nameNotFoundMessage, nameArg) { - var result; - var lastLocation; - var propertyWithInvalidInitializer; - var errorLocation = location; - var grandparent; - loop: while (location) { - // Locals of a source file are not in scope (because they get merged into the global symbol table) - if (location.locals && !isGlobalSourceFile(location)) { - if (result = getSymbol(location.locals, name, meaning)) { - // Type parameters of a function are in scope in the entire function declaration, including the parameter - // list and return type. However, local types are only in scope in the function body. - if (!(meaning & 793056 /* Type */) || - !(result.flags & (793056 /* Type */ & ~262144 /* TypeParameter */)) || - !ts.isFunctionLike(location) || - lastLocation === location.body) { - break loop; - } - result = undefined; - } - } - switch (location.kind) { - case 230 /* SourceFile */: - if (!ts.isExternalModule(location)) - break; - case 208 /* ModuleDeclaration */: - if (result = getSymbol(getSymbolOfNode(location).exports, name, meaning & 8914931 /* ModuleMember */)) { - if (result.flags & meaning || !(result.flags & 8388608 /* Alias */ && getDeclarationOfAliasSymbol(result).kind === 220 /* ExportSpecifier */)) { - break loop; - } - result = undefined; - } - else if (location.kind === 230 /* SourceFile */ || - (location.kind === 208 /* ModuleDeclaration */ && location.name.kind === 8 /* StringLiteral */)) { - result = getSymbolOfNode(location).exports["default"]; - var localSymbol = ts.getLocalSymbolForExportDefault(result); - if (result && localSymbol && (result.flags & meaning) && localSymbol.name === name) { - break loop; - } - result = undefined; - } - break; - case 207 /* EnumDeclaration */: - if (result = getSymbol(getSymbolOfNode(location).exports, name, meaning & 8 /* EnumMember */)) { - break loop; - } - break; - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - // TypeScript 1.0 spec (April 2014): 8.4.1 - // Initializer expressions for instance member variables are evaluated in the scope - // of the class constructor body but are not permitted to reference parameters or - // local variables of the constructor. This effectively means that entities from outer scopes - // by the same name as a constructor parameter or local variable are inaccessible - // in initializer expressions for instance member variables. - if (location.parent.kind === 204 /* ClassDeclaration */ && !(location.flags & 128 /* Static */)) { - var ctor = findConstructorDeclaration(location.parent); - if (ctor && ctor.locals) { - if (getSymbol(ctor.locals, name, meaning & 107455 /* Value */)) { - // Remember the property node, it will be used later to report appropriate error - propertyWithInvalidInitializer = location; - } - } - } - break; - case 204 /* ClassDeclaration */: - case 205 /* InterfaceDeclaration */: - if (result = getSymbol(getSymbolOfNode(location).members, name, meaning & 793056 /* Type */)) { - if (lastLocation && lastLocation.flags & 128 /* Static */) { - // TypeScript 1.0 spec (April 2014): 3.4.1 - // The scope of a type parameter extends over the entire declaration with which the type - // parameter list is associated, with the exception of static member declarations in classes. - error(errorLocation, ts.Diagnostics.Static_members_cannot_reference_class_type_parameters); - return undefined; - } - break loop; - } - break; - // It is not legal to reference a class's own type parameters from a computed property name that - // belongs to the class. For example: - // - // function foo() { return '' } - // class C { // <-- Class's own type parameter T - // [foo()]() { } // <-- Reference to T from class's own computed property - // } - // - case 129 /* ComputedPropertyName */: - grandparent = location.parent.parent; - if (grandparent.kind === 204 /* ClassDeclaration */ || grandparent.kind === 205 /* InterfaceDeclaration */) { - // A reference to this grandparent's type parameters would be an error - if (result = getSymbol(getSymbolOfNode(grandparent).members, name, meaning & 793056 /* Type */)) { - error(errorLocation, ts.Diagnostics.A_computed_property_name_cannot_reference_a_type_parameter_from_its_containing_type); - return undefined; - } - } - break; - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 137 /* Constructor */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 203 /* FunctionDeclaration */: - case 166 /* ArrowFunction */: - if (meaning & 3 /* Variable */ && name === "arguments") { - result = argumentsSymbol; - break loop; - } - break; - case 165 /* FunctionExpression */: - if (meaning & 3 /* Variable */ && name === "arguments") { - result = argumentsSymbol; - break loop; - } - if (meaning & 16 /* Function */) { - var functionName = location.name; - if (functionName && name === functionName.text) { - result = location.symbol; - break loop; - } - } - break; - case 177 /* ClassExpression */: - if (meaning & 32 /* Class */) { - var className = location.name; - if (className && name === className.text) { - result = location.symbol; - break loop; - } - } - break; - case 132 /* Decorator */: - // Decorators are resolved at the class declaration. Resolving at the parameter - // or member would result in looking up locals in the method. - // - // function y() {} - // class C { - // method(@y x, y) {} // <-- decorator y should be resolved at the class declaration, not the parameter. - // } - // - if (location.parent && location.parent.kind === 131 /* Parameter */) { - location = location.parent; - } - // - // function y() {} - // class C { - // @y method(x, y) {} // <-- decorator y should be resolved at the class declaration, not the method. - // } - // - if (location.parent && ts.isClassElement(location.parent)) { - location = location.parent; - } - break; - } - lastLocation = location; - location = location.parent; - } - if (!result) { - result = getSymbol(globals, name, meaning); - } - if (!result) { - if (nameNotFoundMessage) { - error(errorLocation, nameNotFoundMessage, typeof nameArg === "string" ? nameArg : ts.declarationNameToString(nameArg)); - } - return undefined; - } - // Perform extra checks only if error reporting was requested - if (nameNotFoundMessage) { - if (propertyWithInvalidInitializer) { - // We have a match, but the reference occurred within a property initializer and the identifier also binds - // to a local variable in the constructor where the code will be emitted. - var propertyName = propertyWithInvalidInitializer.name; - error(errorLocation, ts.Diagnostics.Initializer_of_instance_member_variable_0_cannot_reference_identifier_1_declared_in_the_constructor, ts.declarationNameToString(propertyName), typeof nameArg === "string" ? nameArg : ts.declarationNameToString(nameArg)); - return undefined; - } - if (result.flags & 2 /* BlockScopedVariable */) { - checkResolvedBlockScopedVariable(result, errorLocation); - } - } - return result; - } - function checkResolvedBlockScopedVariable(result, errorLocation) { - ts.Debug.assert((result.flags & 2 /* BlockScopedVariable */) !== 0); - // Block-scoped variables cannot be used before their definition - var declaration = ts.forEach(result.declarations, function (d) { return ts.isBlockOrCatchScoped(d) ? d : undefined; }); - ts.Debug.assert(declaration !== undefined, "Block-scoped variable declaration is undefined"); - // first check if usage is lexically located after the declaration - var isUsedBeforeDeclaration = !isDefinedBefore(declaration, errorLocation); - if (!isUsedBeforeDeclaration) { - // lexical check succeeded however code still can be illegal. - // - block scoped variables cannot be used in its initializers - // let x = x; // illegal but usage is lexically after definition - // - in ForIn/ForOf statements variable cannot be contained in expression part - // for (let x in x) - // for (let x of x) - // climb up to the variable declaration skipping binding patterns - var variableDeclaration = ts.getAncestor(declaration, 201 /* VariableDeclaration */); - var container = ts.getEnclosingBlockScopeContainer(variableDeclaration); - if (variableDeclaration.parent.parent.kind === 183 /* VariableStatement */ || - variableDeclaration.parent.parent.kind === 189 /* ForStatement */) { - // variable statement/for statement case, - // use site should not be inside variable declaration (initializer of declaration or binding element) - isUsedBeforeDeclaration = isSameScopeDescendentOf(errorLocation, variableDeclaration, container); - } - else if (variableDeclaration.parent.parent.kind === 191 /* ForOfStatement */ || - variableDeclaration.parent.parent.kind === 190 /* ForInStatement */) { - // ForIn/ForOf case - use site should not be used in expression part - var expression = variableDeclaration.parent.parent.expression; - isUsedBeforeDeclaration = isSameScopeDescendentOf(errorLocation, expression, container); - } - } - if (isUsedBeforeDeclaration) { - error(errorLocation, ts.Diagnostics.Block_scoped_variable_0_used_before_its_declaration, ts.declarationNameToString(declaration.name)); - } - } - /* Starting from 'initial' node walk up the parent chain until 'stopAt' node is reached. - * If at any point current node is equal to 'parent' node - return true. - * Return false if 'stopAt' node is reached or isFunctionLike(current) === true. - */ - function isSameScopeDescendentOf(initial, parent, stopAt) { - if (!parent) { - return false; - } - for (var current = initial; current && current !== stopAt && !ts.isFunctionLike(current); current = current.parent) { - if (current === parent) { - return true; - } - } - return false; - } - function getAnyImportSyntax(node) { - if (ts.isAliasSymbolDeclaration(node)) { - if (node.kind === 211 /* ImportEqualsDeclaration */) { - return node; - } - while (node && node.kind !== 212 /* ImportDeclaration */) { - node = node.parent; - } - return node; - } - } - function getDeclarationOfAliasSymbol(symbol) { - return ts.forEach(symbol.declarations, function (d) { return ts.isAliasSymbolDeclaration(d) ? d : undefined; }); - } - function getTargetOfImportEqualsDeclaration(node) { - if (node.moduleReference.kind === 222 /* ExternalModuleReference */) { - return resolveExternalModuleSymbol(resolveExternalModuleName(node, ts.getExternalModuleImportEqualsDeclarationExpression(node))); - } - return getSymbolOfPartOfRightHandSideOfImportEquals(node.moduleReference, node); - } - function getTargetOfImportClause(node) { - var moduleSymbol = resolveExternalModuleName(node, node.parent.moduleSpecifier); - if (moduleSymbol) { - var exportDefaultSymbol = resolveSymbol(moduleSymbol.exports["default"]); - if (!exportDefaultSymbol) { - error(node.name, ts.Diagnostics.Module_0_has_no_default_export, symbolToString(moduleSymbol)); - } - return exportDefaultSymbol; - } - } - function getTargetOfNamespaceImport(node) { - var moduleSpecifier = node.parent.parent.moduleSpecifier; - return resolveESModuleSymbol(resolveExternalModuleName(node, moduleSpecifier), moduleSpecifier); - } - function getMemberOfModuleVariable(moduleSymbol, name) { - if (moduleSymbol.flags & 3 /* Variable */) { - var typeAnnotation = moduleSymbol.valueDeclaration.type; - if (typeAnnotation) { - return getPropertyOfType(getTypeFromTypeNode(typeAnnotation), name); - } - } - } - // This function creates a synthetic symbol that combines the value side of one symbol with the - // type/namespace side of another symbol. Consider this example: - // - // declare module graphics { - // interface Point { - // x: number; - // y: number; - // } - // } - // declare var graphics: { - // Point: new (x: number, y: number) => graphics.Point; - // } - // declare module "graphics" { - // export = graphics; - // } - // - // An 'import { Point } from "graphics"' needs to create a symbol that combines the value side 'Point' - // property with the type/namespace side interface 'Point'. - function combineValueAndTypeSymbols(valueSymbol, typeSymbol) { - if (valueSymbol.flags & (793056 /* Type */ | 1536 /* Namespace */)) { - return valueSymbol; - } - var result = createSymbol(valueSymbol.flags | typeSymbol.flags, valueSymbol.name); - result.declarations = ts.concatenate(valueSymbol.declarations, typeSymbol.declarations); - result.parent = valueSymbol.parent || typeSymbol.parent; - if (valueSymbol.valueDeclaration) - result.valueDeclaration = valueSymbol.valueDeclaration; - if (typeSymbol.members) - result.members = typeSymbol.members; - if (valueSymbol.exports) - result.exports = valueSymbol.exports; - return result; - } - function getExportOfModule(symbol, name) { - if (symbol.flags & 1536 /* Module */) { - var exports = getExportsOfSymbol(symbol); - if (ts.hasProperty(exports, name)) { - return resolveSymbol(exports[name]); - } - } - } - function getPropertyOfVariable(symbol, name) { - if (symbol.flags & 3 /* Variable */) { - var typeAnnotation = symbol.valueDeclaration.type; - if (typeAnnotation) { - return resolveSymbol(getPropertyOfType(getTypeFromTypeNode(typeAnnotation), name)); - } - } - } - function getExternalModuleMember(node, specifier) { - var moduleSymbol = resolveExternalModuleName(node, node.moduleSpecifier); - var targetSymbol = resolveESModuleSymbol(moduleSymbol, node.moduleSpecifier); - if (targetSymbol) { - var name_8 = specifier.propertyName || specifier.name; - if (name_8.text) { - var symbolFromModule = getExportOfModule(targetSymbol, name_8.text); - var symbolFromVariable = getPropertyOfVariable(targetSymbol, name_8.text); - var symbol = symbolFromModule && symbolFromVariable ? - combineValueAndTypeSymbols(symbolFromVariable, symbolFromModule) : - symbolFromModule || symbolFromVariable; - if (!symbol) { - error(name_8, ts.Diagnostics.Module_0_has_no_exported_member_1, getFullyQualifiedName(moduleSymbol), ts.declarationNameToString(name_8)); - } - return symbol; - } - } - } - function getTargetOfImportSpecifier(node) { - return getExternalModuleMember(node.parent.parent.parent, node); - } - function getTargetOfExportSpecifier(node) { - return node.parent.parent.moduleSpecifier ? - getExternalModuleMember(node.parent.parent, node) : - resolveEntityName(node.propertyName || node.name, 107455 /* Value */ | 793056 /* Type */ | 1536 /* Namespace */); - } - function getTargetOfExportAssignment(node) { - return resolveEntityName(node.expression, 107455 /* Value */ | 793056 /* Type */ | 1536 /* Namespace */); - } - function getTargetOfAliasDeclaration(node) { - switch (node.kind) { - case 211 /* ImportEqualsDeclaration */: - return getTargetOfImportEqualsDeclaration(node); - case 213 /* ImportClause */: - return getTargetOfImportClause(node); - case 214 /* NamespaceImport */: - return getTargetOfNamespaceImport(node); - case 216 /* ImportSpecifier */: - return getTargetOfImportSpecifier(node); - case 220 /* ExportSpecifier */: - return getTargetOfExportSpecifier(node); - case 217 /* ExportAssignment */: - return getTargetOfExportAssignment(node); - } - } - function resolveSymbol(symbol) { - return symbol && symbol.flags & 8388608 /* Alias */ && !(symbol.flags & (107455 /* Value */ | 793056 /* Type */ | 1536 /* Namespace */)) ? resolveAlias(symbol) : symbol; - } - function resolveAlias(symbol) { - ts.Debug.assert((symbol.flags & 8388608 /* Alias */) !== 0, "Should only get Alias here."); - var links = getSymbolLinks(symbol); - if (!links.target) { - links.target = resolvingSymbol; - var node = getDeclarationOfAliasSymbol(symbol); - var target = getTargetOfAliasDeclaration(node); - if (links.target === resolvingSymbol) { - links.target = target || unknownSymbol; - } - else { - error(node, ts.Diagnostics.Circular_definition_of_import_alias_0, symbolToString(symbol)); - } - } - else if (links.target === resolvingSymbol) { - links.target = unknownSymbol; - } - return links.target; - } - function markExportAsReferenced(node) { - var symbol = getSymbolOfNode(node); - var target = resolveAlias(symbol); - if (target) { - var markAlias = (target === unknownSymbol && compilerOptions.isolatedModules) || - (target !== unknownSymbol && (target.flags & 107455 /* Value */) && !isConstEnumOrConstEnumOnlyModule(target)); - if (markAlias) { - markAliasSymbolAsReferenced(symbol); - } - } - } - // When an alias symbol is referenced, we need to mark the entity it references as referenced and in turn repeat that until - // we reach a non-alias or an exported entity (which is always considered referenced). We do this by checking the target of - // the alias as an expression (which recursively takes us back here if the target references another alias). - function markAliasSymbolAsReferenced(symbol) { - var links = getSymbolLinks(symbol); - if (!links.referenced) { - links.referenced = true; - var node = getDeclarationOfAliasSymbol(symbol); - if (node.kind === 217 /* ExportAssignment */) { - // export default - checkExpressionCached(node.expression); - } - else if (node.kind === 220 /* ExportSpecifier */) { - // export { } or export { as foo } - checkExpressionCached(node.propertyName || node.name); - } - else if (ts.isInternalModuleImportEqualsDeclaration(node)) { - // import foo = - checkExpressionCached(node.moduleReference); - } - } - } - // This function is only for imports with entity names - function getSymbolOfPartOfRightHandSideOfImportEquals(entityName, importDeclaration) { - if (!importDeclaration) { - importDeclaration = ts.getAncestor(entityName, 211 /* ImportEqualsDeclaration */); - ts.Debug.assert(importDeclaration !== undefined); - } - // There are three things we might try to look for. In the following examples, - // the search term is enclosed in |...|: - // - // import a = |b|; // Namespace - // import a = |b.c|; // Value, type, namespace - // import a = |b.c|.d; // Namespace - if (entityName.kind === 65 /* Identifier */ && ts.isRightSideOfQualifiedNameOrPropertyAccess(entityName)) { - entityName = entityName.parent; - } - // Check for case 1 and 3 in the above example - if (entityName.kind === 65 /* Identifier */ || entityName.parent.kind === 128 /* QualifiedName */) { - return resolveEntityName(entityName, 1536 /* Namespace */); - } - else { - // Case 2 in above example - // entityName.kind could be a QualifiedName or a Missing identifier - ts.Debug.assert(entityName.parent.kind === 211 /* ImportEqualsDeclaration */); - return resolveEntityName(entityName, 107455 /* Value */ | 793056 /* Type */ | 1536 /* Namespace */); - } - } - function getFullyQualifiedName(symbol) { - return symbol.parent ? getFullyQualifiedName(symbol.parent) + "." + symbolToString(symbol) : symbolToString(symbol); - } - // Resolves a qualified name and any involved aliases - function resolveEntityName(name, meaning) { - if (ts.nodeIsMissing(name)) { - return undefined; - } - var symbol; - if (name.kind === 65 /* Identifier */) { - var message = meaning === 1536 /* Namespace */ ? ts.Diagnostics.Cannot_find_namespace_0 : ts.Diagnostics.Cannot_find_name_0; - symbol = resolveName(name, name.text, meaning, message, name); - if (!symbol) { - return undefined; - } - } - else if (name.kind === 128 /* QualifiedName */ || name.kind === 158 /* PropertyAccessExpression */) { - var left = name.kind === 128 /* QualifiedName */ ? name.left : name.expression; - var right = name.kind === 128 /* QualifiedName */ ? name.right : name.name; - var namespace = resolveEntityName(left, 1536 /* Namespace */); - if (!namespace || namespace === unknownSymbol || ts.nodeIsMissing(right)) { - return undefined; - } - symbol = getSymbol(getExportsOfSymbol(namespace), right.text, meaning); - if (!symbol) { - error(right, ts.Diagnostics.Module_0_has_no_exported_member_1, getFullyQualifiedName(namespace), ts.declarationNameToString(right)); - return undefined; - } - } - else { - ts.Debug.fail("Unknown entity name kind."); - } - ts.Debug.assert((symbol.flags & 16777216 /* Instantiated */) === 0, "Should never get an instantiated symbol here."); - return symbol.flags & meaning ? symbol : resolveAlias(symbol); - } - function isExternalModuleNameRelative(moduleName) { - // TypeScript 1.0 spec (April 2014): 11.2.1 - // An external module name is "relative" if the first term is "." or "..". - return moduleName.substr(0, 2) === "./" || moduleName.substr(0, 3) === "../" || moduleName.substr(0, 2) === ".\\" || moduleName.substr(0, 3) === "..\\"; - } - function resolveExternalModuleName(location, moduleReferenceExpression) { - if (moduleReferenceExpression.kind !== 8 /* StringLiteral */) { - return; - } - var moduleReferenceLiteral = moduleReferenceExpression; - var searchPath = ts.getDirectoryPath(getSourceFile(location).fileName); - // Module names are escaped in our symbol table. However, string literal values aren't. - // Escape the name in the "require(...)" clause to ensure we find the right symbol. - var moduleName = ts.escapeIdentifier(moduleReferenceLiteral.text); - if (!moduleName) - return; - var isRelative = isExternalModuleNameRelative(moduleName); - if (!isRelative) { - var symbol = getSymbol(globals, '"' + moduleName + '"', 512 /* ValueModule */); - if (symbol) { - return symbol; - } - } - var fileName; - var sourceFile; - while (true) { - fileName = ts.normalizePath(ts.combinePaths(searchPath, moduleName)); - sourceFile = ts.forEach(ts.supportedExtensions, function (extension) { return host.getSourceFile(fileName + extension); }); - if (sourceFile || isRelative) { - break; - } - var parentPath = ts.getDirectoryPath(searchPath); - if (parentPath === searchPath) { - break; - } - searchPath = parentPath; - } - if (sourceFile) { - if (sourceFile.symbol) { - return sourceFile.symbol; - } - error(moduleReferenceLiteral, ts.Diagnostics.File_0_is_not_a_module, sourceFile.fileName); - return; - } - error(moduleReferenceLiteral, ts.Diagnostics.Cannot_find_module_0, moduleName); - } - // An external module with an 'export =' declaration resolves to the target of the 'export =' declaration, - // and an external module with no 'export =' declaration resolves to the module itself. - function resolveExternalModuleSymbol(moduleSymbol) { - return moduleSymbol && resolveSymbol(moduleSymbol.exports["export="]) || moduleSymbol; - } - // An external module with an 'export =' declaration may be referenced as an ES6 module provided the 'export =' - // references a symbol that is at least declared as a module or a variable. The target of the 'export =' may - // combine other declarations with the module or variable (e.g. a class/module, function/module, interface/variable). - function resolveESModuleSymbol(moduleSymbol, moduleReferenceExpression) { - var symbol = resolveExternalModuleSymbol(moduleSymbol); - if (symbol && !(symbol.flags & (1536 /* Module */ | 3 /* Variable */))) { - error(moduleReferenceExpression, ts.Diagnostics.Module_0_resolves_to_a_non_module_entity_and_cannot_be_imported_using_this_construct, symbolToString(moduleSymbol)); - symbol = undefined; - } - return symbol; - } - function getExportAssignmentSymbol(moduleSymbol) { - return moduleSymbol.exports["export="]; - } - function getExportsOfModuleAsArray(moduleSymbol) { - return symbolsToArray(getExportsOfModule(moduleSymbol)); - } - function getExportsOfSymbol(symbol) { - return symbol.flags & 1536 /* Module */ ? getExportsOfModule(symbol) : symbol.exports || emptySymbols; - } - function getExportsOfModule(moduleSymbol) { - var links = getSymbolLinks(moduleSymbol); - return links.resolvedExports || (links.resolvedExports = getExportsForModule(moduleSymbol)); - } - function extendExportSymbols(target, source) { - for (var id in source) { - if (id !== "default" && !ts.hasProperty(target, id)) { - target[id] = source[id]; - } - } - } - function getExportsForModule(moduleSymbol) { - var result; - var visitedSymbols = []; - visit(moduleSymbol); - return result || moduleSymbol.exports; - // The ES6 spec permits export * declarations in a module to circularly reference the module itself. For example, - // module 'a' can 'export * from "b"' and 'b' can 'export * from "a"' without error. - function visit(symbol) { - if (symbol && symbol.flags & 1952 /* HasExports */ && !ts.contains(visitedSymbols, symbol)) { - visitedSymbols.push(symbol); - if (symbol !== moduleSymbol) { - if (!result) { - result = cloneSymbolTable(moduleSymbol.exports); - } - extendExportSymbols(result, symbol.exports); - } - // All export * declarations are collected in an __export symbol by the binder - var exportStars = symbol.exports["__export"]; - if (exportStars) { - for (var _i = 0, _a = exportStars.declarations; _i < _a.length; _i++) { - var node = _a[_i]; - visit(resolveExternalModuleName(node, node.moduleSpecifier)); - } - } - } - } - } - function getMergedSymbol(symbol) { - var merged; - return symbol && symbol.mergeId && (merged = mergedSymbols[symbol.mergeId]) ? merged : symbol; - } - function getSymbolOfNode(node) { - return getMergedSymbol(node.symbol); - } - function getParentOfSymbol(symbol) { - return getMergedSymbol(symbol.parent); - } - function getExportSymbolOfValueSymbolIfExported(symbol) { - return symbol && (symbol.flags & 1048576 /* ExportValue */) !== 0 - ? getMergedSymbol(symbol.exportSymbol) - : symbol; - } - function symbolIsValue(symbol) { - // If it is an instantiated symbol, then it is a value if the symbol it is an - // instantiation of is a value. - if (symbol.flags & 16777216 /* Instantiated */) { - return symbolIsValue(getSymbolLinks(symbol).target); - } - // If the symbol has the value flag, it is trivially a value. - if (symbol.flags & 107455 /* Value */) { - return true; - } - // If it is an alias, then it is a value if the symbol it resolves to is a value. - if (symbol.flags & 8388608 /* Alias */) { - return (resolveAlias(symbol).flags & 107455 /* Value */) !== 0; - } - return false; - } - function findConstructorDeclaration(node) { - var members = node.members; - for (var _i = 0; _i < members.length; _i++) { - var member = members[_i]; - if (member.kind === 137 /* Constructor */ && ts.nodeIsPresent(member.body)) { - return member; - } - } - } - function createType(flags) { - var result = new Type(checker, flags); - result.id = typeCount++; - return result; - } - function createIntrinsicType(kind, intrinsicName) { - var type = createType(kind); - type.intrinsicName = intrinsicName; - return type; - } - function createObjectType(kind, symbol) { - var type = createType(kind); - type.symbol = symbol; - return type; - } - // A reserved member name starts with two underscores, but the third character cannot be an underscore - // or the @ symbol. A third underscore indicates an escaped form of an identifer that started - // with at least two underscores. The @ character indicates that the name is denoted by a well known ES - // Symbol instance. - function isReservedMemberName(name) { - return name.charCodeAt(0) === 95 /* _ */ && - name.charCodeAt(1) === 95 /* _ */ && - name.charCodeAt(2) !== 95 /* _ */ && - name.charCodeAt(2) !== 64 /* at */; - } - function getNamedMembers(members) { - var result; - for (var id in members) { - if (ts.hasProperty(members, id)) { - if (!isReservedMemberName(id)) { - if (!result) - result = []; - var symbol = members[id]; - if (symbolIsValue(symbol)) { - result.push(symbol); - } - } - } - } - return result || emptyArray; - } - function setObjectTypeMembers(type, members, callSignatures, constructSignatures, stringIndexType, numberIndexType) { - type.members = members; - type.properties = getNamedMembers(members); - type.callSignatures = callSignatures; - type.constructSignatures = constructSignatures; - if (stringIndexType) - type.stringIndexType = stringIndexType; - if (numberIndexType) - type.numberIndexType = numberIndexType; - return type; - } - function createAnonymousType(symbol, members, callSignatures, constructSignatures, stringIndexType, numberIndexType) { - return setObjectTypeMembers(createObjectType(32768 /* Anonymous */, symbol), members, callSignatures, constructSignatures, stringIndexType, numberIndexType); - } - function forEachSymbolTableInScope(enclosingDeclaration, callback) { - var result; - for (var location_1 = enclosingDeclaration; location_1; location_1 = location_1.parent) { - // Locals of a source file are not in scope (because they get merged into the global symbol table) - if (location_1.locals && !isGlobalSourceFile(location_1)) { - if (result = callback(location_1.locals)) { - return result; - } - } - switch (location_1.kind) { - case 230 /* SourceFile */: - if (!ts.isExternalModule(location_1)) { - break; - } - case 208 /* ModuleDeclaration */: - if (result = callback(getSymbolOfNode(location_1).exports)) { - return result; - } - break; - case 204 /* ClassDeclaration */: - case 205 /* InterfaceDeclaration */: - if (result = callback(getSymbolOfNode(location_1).members)) { - return result; - } - break; - } - } - return callback(globals); - } - function getQualifiedLeftMeaning(rightMeaning) { - // If we are looking in value space, the parent meaning is value, other wise it is namespace - return rightMeaning === 107455 /* Value */ ? 107455 /* Value */ : 1536 /* Namespace */; - } - function getAccessibleSymbolChain(symbol, enclosingDeclaration, meaning, useOnlyExternalAliasing) { - function getAccessibleSymbolChainFromSymbolTable(symbols) { - function canQualifySymbol(symbolFromSymbolTable, meaning) { - // If the symbol is equivalent and doesn't need further qualification, this symbol is accessible - if (!needsQualification(symbolFromSymbolTable, enclosingDeclaration, meaning)) { - return true; - } - // If symbol needs qualification, make sure that parent is accessible, if it is then this symbol is accessible too - var accessibleParent = getAccessibleSymbolChain(symbolFromSymbolTable.parent, enclosingDeclaration, getQualifiedLeftMeaning(meaning), useOnlyExternalAliasing); - return !!accessibleParent; - } - function isAccessible(symbolFromSymbolTable, resolvedAliasSymbol) { - if (symbol === (resolvedAliasSymbol || symbolFromSymbolTable)) { - // if the symbolFromSymbolTable is not external module (it could be if it was determined as ambient external module and would be in globals table) - // and if symbolfrom symbolTable or alias resolution matches the symbol, - // check the symbol can be qualified, it is only then this symbol is accessible - return !ts.forEach(symbolFromSymbolTable.declarations, hasExternalModuleSymbol) && - canQualifySymbol(symbolFromSymbolTable, meaning); - } - } - // If symbol is directly available by its name in the symbol table - if (isAccessible(ts.lookUp(symbols, symbol.name))) { - return [symbol]; - } - // Check if symbol is any of the alias - return ts.forEachValue(symbols, function (symbolFromSymbolTable) { - if (symbolFromSymbolTable.flags & 8388608 /* Alias */ && symbolFromSymbolTable.name !== "export=") { - if (!useOnlyExternalAliasing || - // Is this external alias, then use it to name - ts.forEach(symbolFromSymbolTable.declarations, ts.isExternalModuleImportEqualsDeclaration)) { - var resolvedImportedSymbol = resolveAlias(symbolFromSymbolTable); - if (isAccessible(symbolFromSymbolTable, resolveAlias(symbolFromSymbolTable))) { - return [symbolFromSymbolTable]; - } - // Look in the exported members, if we can find accessibleSymbolChain, symbol is accessible using this chain - // but only if the symbolFromSymbolTable can be qualified - var accessibleSymbolsFromExports = resolvedImportedSymbol.exports ? getAccessibleSymbolChainFromSymbolTable(resolvedImportedSymbol.exports) : undefined; - if (accessibleSymbolsFromExports && canQualifySymbol(symbolFromSymbolTable, getQualifiedLeftMeaning(meaning))) { - return [symbolFromSymbolTable].concat(accessibleSymbolsFromExports); - } - } - } - }); - } - if (symbol) { - return forEachSymbolTableInScope(enclosingDeclaration, getAccessibleSymbolChainFromSymbolTable); - } - } - function needsQualification(symbol, enclosingDeclaration, meaning) { - var qualify = false; - forEachSymbolTableInScope(enclosingDeclaration, function (symbolTable) { - // If symbol of this name is not available in the symbol table we are ok - if (!ts.hasProperty(symbolTable, symbol.name)) { - // Continue to the next symbol table - return false; - } - // If the symbol with this name is present it should refer to the symbol - var symbolFromSymbolTable = symbolTable[symbol.name]; - if (symbolFromSymbolTable === symbol) { - // No need to qualify - return true; - } - // Qualify if the symbol from symbol table has same meaning as expected - symbolFromSymbolTable = (symbolFromSymbolTable.flags & 8388608 /* Alias */) ? resolveAlias(symbolFromSymbolTable) : symbolFromSymbolTable; - if (symbolFromSymbolTable.flags & meaning) { - qualify = true; - return true; - } - // Continue to the next symbol table - return false; - }); - return qualify; - } - function isSymbolAccessible(symbol, enclosingDeclaration, meaning) { - if (symbol && enclosingDeclaration && !(symbol.flags & 262144 /* TypeParameter */)) { - var initialSymbol = symbol; - var meaningToLook = meaning; - while (symbol) { - // Symbol is accessible if it by itself is accessible - var accessibleSymbolChain = getAccessibleSymbolChain(symbol, enclosingDeclaration, meaningToLook, false); - if (accessibleSymbolChain) { - var hasAccessibleDeclarations = hasVisibleDeclarations(accessibleSymbolChain[0]); - if (!hasAccessibleDeclarations) { - return { - accessibility: 1 /* NotAccessible */, - errorSymbolName: symbolToString(initialSymbol, enclosingDeclaration, meaning), - errorModuleName: symbol !== initialSymbol ? symbolToString(symbol, enclosingDeclaration, 1536 /* Namespace */) : undefined - }; - } - return hasAccessibleDeclarations; - } - // If we haven't got the accessible symbol, it doesn't mean the symbol is actually inaccessible. - // It could be a qualified symbol and hence verify the path - // e.g.: - // module m { - // export class c { - // } - // } - // let x: typeof m.c - // In the above example when we start with checking if typeof m.c symbol is accessible, - // we are going to see if c can be accessed in scope directly. - // But it can't, hence the accessible is going to be undefined, but that doesn't mean m.c is inaccessible - // It is accessible if the parent m is accessible because then m.c can be accessed through qualification - meaningToLook = getQualifiedLeftMeaning(meaning); - symbol = getParentOfSymbol(symbol); - } - // This could be a symbol that is not exported in the external module - // or it could be a symbol from different external module that is not aliased and hence cannot be named - var symbolExternalModule = ts.forEach(initialSymbol.declarations, getExternalModuleContainer); - if (symbolExternalModule) { - var enclosingExternalModule = getExternalModuleContainer(enclosingDeclaration); - if (symbolExternalModule !== enclosingExternalModule) { - // name from different external module that is not visible - return { - accessibility: 2 /* CannotBeNamed */, - errorSymbolName: symbolToString(initialSymbol, enclosingDeclaration, meaning), - errorModuleName: symbolToString(symbolExternalModule) - }; - } - } - // Just a local name that is not accessible - return { - accessibility: 1 /* NotAccessible */, - errorSymbolName: symbolToString(initialSymbol, enclosingDeclaration, meaning) - }; - } - return { accessibility: 0 /* Accessible */ }; - function getExternalModuleContainer(declaration) { - for (; declaration; declaration = declaration.parent) { - if (hasExternalModuleSymbol(declaration)) { - return getSymbolOfNode(declaration); - } - } - } - } - function hasExternalModuleSymbol(declaration) { - return (declaration.kind === 208 /* ModuleDeclaration */ && declaration.name.kind === 8 /* StringLiteral */) || - (declaration.kind === 230 /* SourceFile */ && ts.isExternalModule(declaration)); - } - function hasVisibleDeclarations(symbol) { - var aliasesToMakeVisible; - if (ts.forEach(symbol.declarations, function (declaration) { return !getIsDeclarationVisible(declaration); })) { - return undefined; - } - return { accessibility: 0 /* Accessible */, aliasesToMakeVisible: aliasesToMakeVisible }; - function getIsDeclarationVisible(declaration) { - if (!isDeclarationVisible(declaration)) { - // Mark the unexported alias as visible if its parent is visible - // because these kind of aliases can be used to name types in declaration file - var anyImportSyntax = getAnyImportSyntax(declaration); - if (anyImportSyntax && - !(anyImportSyntax.flags & 1 /* Export */) && - isDeclarationVisible(anyImportSyntax.parent)) { - getNodeLinks(declaration).isVisible = true; - if (aliasesToMakeVisible) { - if (!ts.contains(aliasesToMakeVisible, anyImportSyntax)) { - aliasesToMakeVisible.push(anyImportSyntax); - } - } - else { - aliasesToMakeVisible = [anyImportSyntax]; - } - return true; - } - // Declaration is not visible - return false; - } - return true; - } - } - function isEntityNameVisible(entityName, enclosingDeclaration) { - // get symbol of the first identifier of the entityName - var meaning; - if (entityName.parent.kind === 147 /* TypeQuery */) { - // Typeof value - meaning = 107455 /* Value */ | 1048576 /* ExportValue */; - } - else if (entityName.kind === 128 /* QualifiedName */ || entityName.kind === 158 /* PropertyAccessExpression */ || - entityName.parent.kind === 211 /* ImportEqualsDeclaration */) { - // Left identifier from type reference or TypeAlias - // Entity name of the import declaration - meaning = 1536 /* Namespace */; - } - else { - // Type Reference or TypeAlias entity = Identifier - meaning = 793056 /* Type */; - } - var firstIdentifier = getFirstIdentifier(entityName); - var symbol = resolveName(enclosingDeclaration, firstIdentifier.text, meaning, undefined, undefined); - // Verify if the symbol is accessible - return (symbol && hasVisibleDeclarations(symbol)) || { - accessibility: 1 /* NotAccessible */, - errorSymbolName: ts.getTextOfNode(firstIdentifier), - errorNode: firstIdentifier - }; - } - function writeKeyword(writer, kind) { - writer.writeKeyword(ts.tokenToString(kind)); - } - function writePunctuation(writer, kind) { - writer.writePunctuation(ts.tokenToString(kind)); - } - function writeSpace(writer) { - writer.writeSpace(" "); - } - function symbolToString(symbol, enclosingDeclaration, meaning) { - var writer = ts.getSingleLineStringWriter(); - getSymbolDisplayBuilder().buildSymbolDisplay(symbol, writer, enclosingDeclaration, meaning); - var result = writer.string(); - ts.releaseStringWriter(writer); - return result; - } - function signatureToString(signature, enclosingDeclaration, flags) { - var writer = ts.getSingleLineStringWriter(); - getSymbolDisplayBuilder().buildSignatureDisplay(signature, writer, enclosingDeclaration, flags); - var result = writer.string(); - ts.releaseStringWriter(writer); - return result; - } - function typeToString(type, enclosingDeclaration, flags) { - var writer = ts.getSingleLineStringWriter(); - getSymbolDisplayBuilder().buildTypeDisplay(type, writer, enclosingDeclaration, flags); - var result = writer.string(); - ts.releaseStringWriter(writer); - var maxLength = compilerOptions.noErrorTruncation || flags & 4 /* NoTruncation */ ? undefined : 100; - if (maxLength && result.length >= maxLength) { - result = result.substr(0, maxLength - "...".length) + "..."; - } - return result; - } - function getTypeAliasForTypeLiteral(type) { - if (type.symbol && type.symbol.flags & 2048 /* TypeLiteral */) { - var node = type.symbol.declarations[0].parent; - while (node.kind === 152 /* ParenthesizedType */) { - node = node.parent; - } - if (node.kind === 206 /* TypeAliasDeclaration */) { - return getSymbolOfNode(node); - } - } - return undefined; - } - // This is for caching the result of getSymbolDisplayBuilder. Do not access directly. - var _displayBuilder; - function getSymbolDisplayBuilder() { - /** - * Writes only the name of the symbol out to the writer. Uses the original source text - * for the name of the symbol if it is available to match how the user inputted the name. - */ - function appendSymbolNameOnly(symbol, writer) { - if (symbol.declarations && symbol.declarations.length > 0) { - var declaration = symbol.declarations[0]; - if (declaration.name) { - writer.writeSymbol(ts.declarationNameToString(declaration.name), symbol); - return; - } - } - writer.writeSymbol(symbol.name, symbol); - } - /** - * Enclosing declaration is optional when we don't want to get qualified name in the enclosing declaration scope - * Meaning needs to be specified if the enclosing declaration is given - */ - function buildSymbolDisplay(symbol, writer, enclosingDeclaration, meaning, flags, typeFlags) { - var parentSymbol; - function appendParentTypeArgumentsAndSymbolName(symbol) { - if (parentSymbol) { - // Write type arguments of instantiated class/interface here - if (flags & 1 /* WriteTypeParametersOrArguments */) { - if (symbol.flags & 16777216 /* Instantiated */) { - buildDisplayForTypeArgumentsAndDelimiters(getTypeParametersOfClassOrInterface(parentSymbol), symbol.mapper, writer, enclosingDeclaration); - } - else { - buildTypeParameterDisplayFromSymbol(parentSymbol, writer, enclosingDeclaration); - } - } - writePunctuation(writer, 20 /* DotToken */); - } - parentSymbol = symbol; - appendSymbolNameOnly(symbol, writer); - } - // Let the writer know we just wrote out a symbol. The declaration emitter writer uses - // this to determine if an import it has previously seen (and not written out) needs - // to be written to the file once the walk of the tree is complete. - // - // NOTE(cyrusn): This approach feels somewhat unfortunate. A simple pass over the tree - // up front (for example, during checking) could determine if we need to emit the imports - // and we could then access that data during declaration emit. - writer.trackSymbol(symbol, enclosingDeclaration, meaning); - function walkSymbol(symbol, meaning) { - if (symbol) { - var accessibleSymbolChain = getAccessibleSymbolChain(symbol, enclosingDeclaration, meaning, !!(flags & 2 /* UseOnlyExternalAliasing */)); - if (!accessibleSymbolChain || - needsQualification(accessibleSymbolChain[0], enclosingDeclaration, accessibleSymbolChain.length === 1 ? meaning : getQualifiedLeftMeaning(meaning))) { - // Go up and add our parent. - walkSymbol(getParentOfSymbol(accessibleSymbolChain ? accessibleSymbolChain[0] : symbol), getQualifiedLeftMeaning(meaning)); - } - if (accessibleSymbolChain) { - for (var _i = 0; _i < accessibleSymbolChain.length; _i++) { - var accessibleSymbol = accessibleSymbolChain[_i]; - appendParentTypeArgumentsAndSymbolName(accessibleSymbol); - } - } - else { - // If we didn't find accessible symbol chain for this symbol, break if this is external module - if (!parentSymbol && ts.forEach(symbol.declarations, hasExternalModuleSymbol)) { - return; - } - // if this is anonymous type break - if (symbol.flags & 2048 /* TypeLiteral */ || symbol.flags & 4096 /* ObjectLiteral */) { - return; - } - appendParentTypeArgumentsAndSymbolName(symbol); - } - } - } - // Get qualified name if the symbol is not a type parameter - // and there is an enclosing declaration or we specifically - // asked for it - var isTypeParameter = symbol.flags & 262144 /* TypeParameter */; - var typeFormatFlag = 128 /* UseFullyQualifiedType */ & typeFlags; - if (!isTypeParameter && (enclosingDeclaration || typeFormatFlag)) { - walkSymbol(symbol, meaning); - return; - } - return appendParentTypeArgumentsAndSymbolName(symbol); - } - function buildTypeDisplay(type, writer, enclosingDeclaration, globalFlags, symbolStack) { - var globalFlagsToPass = globalFlags & 16 /* WriteOwnNameForAnyLike */; - return writeType(type, globalFlags); - function writeType(type, flags) { - // Write undefined/null type as any - if (type.flags & 2097279 /* Intrinsic */) { - // Special handling for unknown / resolving types, they should show up as any and not unknown or __resolving - writer.writeKeyword(!(globalFlags & 16 /* WriteOwnNameForAnyLike */) && isTypeAny(type) - ? "any" - : type.intrinsicName); - } - else if (type.flags & 4096 /* Reference */) { - writeTypeReference(type, flags); - } - else if (type.flags & (1024 /* Class */ | 2048 /* Interface */ | 128 /* Enum */ | 512 /* TypeParameter */)) { - // The specified symbol flags need to be reinterpreted as type flags - buildSymbolDisplay(type.symbol, writer, enclosingDeclaration, 793056 /* Type */, 0 /* None */, flags); - } - else if (type.flags & 8192 /* Tuple */) { - writeTupleType(type); - } - else if (type.flags & 16384 /* Union */) { - writeUnionType(type, flags); - } - else if (type.flags & 32768 /* Anonymous */) { - writeAnonymousType(type, flags); - } - else if (type.flags & 256 /* StringLiteral */) { - writer.writeStringLiteral(type.text); - } - else { - // Should never get here - // { ... } - writePunctuation(writer, 14 /* OpenBraceToken */); - writeSpace(writer); - writePunctuation(writer, 21 /* DotDotDotToken */); - writeSpace(writer); - writePunctuation(writer, 15 /* CloseBraceToken */); - } - } - function writeTypeList(types, union) { - for (var i = 0; i < types.length; i++) { - if (i > 0) { - if (union) { - writeSpace(writer); - } - writePunctuation(writer, union ? 44 /* BarToken */ : 23 /* CommaToken */); - writeSpace(writer); - } - writeType(types[i], union ? 64 /* InElementType */ : 0 /* None */); - } - } - function writeSymbolTypeReference(symbol, typeArguments, pos, end) { - // Unnamed function expressions, arrow functions, and unnamed class expressions have reserved names that - // we don't want to display - if (!isReservedMemberName(symbol.name)) { - buildSymbolDisplay(symbol, writer, enclosingDeclaration, 793056 /* Type */); - } - if (pos < end) { - writePunctuation(writer, 24 /* LessThanToken */); - writeType(typeArguments[pos++], 0 /* None */); - while (pos < end) { - writePunctuation(writer, 23 /* CommaToken */); - writeSpace(writer); - writeType(typeArguments[pos++], 0 /* None */); - } - writePunctuation(writer, 25 /* GreaterThanToken */); - } - } - function writeTypeReference(type, flags) { - var typeArguments = type.typeArguments; - if (type.target === globalArrayType && !(flags & 1 /* WriteArrayAsGenericType */)) { - writeType(typeArguments[0], 64 /* InElementType */); - writePunctuation(writer, 18 /* OpenBracketToken */); - writePunctuation(writer, 19 /* CloseBracketToken */); - } - else { - // Write the type reference in the format f.g.C where A and B are type arguments - // for outer type parameters, and f and g are the respective declaring containers of those - // type parameters. - var outerTypeParameters = type.target.outerTypeParameters; - var i = 0; - if (outerTypeParameters) { - var length_1 = outerTypeParameters.length; - while (i < length_1) { - // Find group of type arguments for type parameters with the same declaring container. - var start = i; - var parent_3 = getParentSymbolOfTypeParameter(outerTypeParameters[i]); - do { - i++; - } while (i < length_1 && getParentSymbolOfTypeParameter(outerTypeParameters[i]) === parent_3); - // When type parameters are their own type arguments for the whole group (i.e. we have - // the default outer type arguments), we don't show the group. - if (!ts.rangeEquals(outerTypeParameters, typeArguments, start, i)) { - writeSymbolTypeReference(parent_3, typeArguments, start, i); - writePunctuation(writer, 20 /* DotToken */); - } - } - } - writeSymbolTypeReference(type.symbol, typeArguments, i, typeArguments.length); - } - } - function writeTupleType(type) { - writePunctuation(writer, 18 /* OpenBracketToken */); - writeTypeList(type.elementTypes, false); - writePunctuation(writer, 19 /* CloseBracketToken */); - } - function writeUnionType(type, flags) { - if (flags & 64 /* InElementType */) { - writePunctuation(writer, 16 /* OpenParenToken */); - } - writeTypeList(type.types, true); - if (flags & 64 /* InElementType */) { - writePunctuation(writer, 17 /* CloseParenToken */); - } - } - function writeAnonymousType(type, flags) { - var symbol = type.symbol; - if (symbol) { - // Always use 'typeof T' for type of class, enum, and module objects - if (symbol.flags & (32 /* Class */ | 384 /* Enum */ | 512 /* ValueModule */)) { - writeTypeofSymbol(type, flags); - } - else if (shouldWriteTypeOfFunctionSymbol()) { - writeTypeofSymbol(type, flags); - } - else if (ts.contains(symbolStack, symbol)) { - // If type is an anonymous type literal in a type alias declaration, use type alias name - var typeAlias = getTypeAliasForTypeLiteral(type); - if (typeAlias) { - // The specified symbol flags need to be reinterpreted as type flags - buildSymbolDisplay(typeAlias, writer, enclosingDeclaration, 793056 /* Type */, 0 /* None */, flags); - } - else { - // Recursive usage, use any - writeKeyword(writer, 112 /* AnyKeyword */); - } - } - else { - // Since instantiations of the same anonymous type have the same symbol, tracking symbols instead - // of types allows us to catch circular references to instantiations of the same anonymous type - if (!symbolStack) { - symbolStack = []; - } - symbolStack.push(symbol); - writeLiteralType(type, flags); - symbolStack.pop(); - } - } - else { - // Anonymous types with no symbol are never circular - writeLiteralType(type, flags); - } - function shouldWriteTypeOfFunctionSymbol() { - var isStaticMethodSymbol = !!(symbol.flags & 8192 /* Method */ && - ts.forEach(symbol.declarations, function (declaration) { return declaration.flags & 128 /* Static */; })); - var isNonLocalFunctionSymbol = !!(symbol.flags & 16 /* Function */) && - (symbol.parent || - ts.forEach(symbol.declarations, function (declaration) { - return declaration.parent.kind === 230 /* SourceFile */ || declaration.parent.kind === 209 /* ModuleBlock */; - })); - if (isStaticMethodSymbol || isNonLocalFunctionSymbol) { - // typeof is allowed only for static/non local functions - return !!(flags & 2 /* UseTypeOfFunction */) || - (ts.contains(symbolStack, symbol)); // it is type of the symbol uses itself recursively - } - } - } - function writeTypeofSymbol(type, typeFormatFlags) { - writeKeyword(writer, 97 /* TypeOfKeyword */); - writeSpace(writer); - buildSymbolDisplay(type.symbol, writer, enclosingDeclaration, 107455 /* Value */, 0 /* None */, typeFormatFlags); - } - function getIndexerParameterName(type, indexKind, fallbackName) { - var declaration = getIndexDeclarationOfSymbol(type.symbol, indexKind); - if (!declaration) { - // declaration might not be found if indexer was added from the contextual type. - // in this case use fallback name - return fallbackName; - } - ts.Debug.assert(declaration.parameters.length !== 0); - return ts.declarationNameToString(declaration.parameters[0].name); - } - function writeLiteralType(type, flags) { - var resolved = resolveObjectOrUnionTypeMembers(type); - if (!resolved.properties.length && !resolved.stringIndexType && !resolved.numberIndexType) { - if (!resolved.callSignatures.length && !resolved.constructSignatures.length) { - writePunctuation(writer, 14 /* OpenBraceToken */); - writePunctuation(writer, 15 /* CloseBraceToken */); - return; - } - if (resolved.callSignatures.length === 1 && !resolved.constructSignatures.length) { - if (flags & 64 /* InElementType */) { - writePunctuation(writer, 16 /* OpenParenToken */); - } - buildSignatureDisplay(resolved.callSignatures[0], writer, enclosingDeclaration, globalFlagsToPass | 8 /* WriteArrowStyleSignature */, symbolStack); - if (flags & 64 /* InElementType */) { - writePunctuation(writer, 17 /* CloseParenToken */); - } - return; - } - if (resolved.constructSignatures.length === 1 && !resolved.callSignatures.length) { - if (flags & 64 /* InElementType */) { - writePunctuation(writer, 16 /* OpenParenToken */); - } - writeKeyword(writer, 88 /* NewKeyword */); - writeSpace(writer); - buildSignatureDisplay(resolved.constructSignatures[0], writer, enclosingDeclaration, globalFlagsToPass | 8 /* WriteArrowStyleSignature */, symbolStack); - if (flags & 64 /* InElementType */) { - writePunctuation(writer, 17 /* CloseParenToken */); - } - return; - } - } - writePunctuation(writer, 14 /* OpenBraceToken */); - writer.writeLine(); - writer.increaseIndent(); - for (var _i = 0, _a = resolved.callSignatures; _i < _a.length; _i++) { - var signature = _a[_i]; - buildSignatureDisplay(signature, writer, enclosingDeclaration, globalFlagsToPass, symbolStack); - writePunctuation(writer, 22 /* SemicolonToken */); - writer.writeLine(); - } - for (var _b = 0, _c = resolved.constructSignatures; _b < _c.length; _b++) { - var signature = _c[_b]; - writeKeyword(writer, 88 /* NewKeyword */); - writeSpace(writer); - buildSignatureDisplay(signature, writer, enclosingDeclaration, globalFlagsToPass, symbolStack); - writePunctuation(writer, 22 /* SemicolonToken */); - writer.writeLine(); - } - if (resolved.stringIndexType) { - // [x: string]: - writePunctuation(writer, 18 /* OpenBracketToken */); - writer.writeParameter(getIndexerParameterName(resolved, 0 /* String */, "x")); - writePunctuation(writer, 51 /* ColonToken */); - writeSpace(writer); - writeKeyword(writer, 123 /* StringKeyword */); - writePunctuation(writer, 19 /* CloseBracketToken */); - writePunctuation(writer, 51 /* ColonToken */); - writeSpace(writer); - writeType(resolved.stringIndexType, 0 /* None */); - writePunctuation(writer, 22 /* SemicolonToken */); - writer.writeLine(); - } - if (resolved.numberIndexType) { - // [x: number]: - writePunctuation(writer, 18 /* OpenBracketToken */); - writer.writeParameter(getIndexerParameterName(resolved, 1 /* Number */, "x")); - writePunctuation(writer, 51 /* ColonToken */); - writeSpace(writer); - writeKeyword(writer, 121 /* NumberKeyword */); - writePunctuation(writer, 19 /* CloseBracketToken */); - writePunctuation(writer, 51 /* ColonToken */); - writeSpace(writer); - writeType(resolved.numberIndexType, 0 /* None */); - writePunctuation(writer, 22 /* SemicolonToken */); - writer.writeLine(); - } - for (var _d = 0, _e = resolved.properties; _d < _e.length; _d++) { - var p = _e[_d]; - var t = getTypeOfSymbol(p); - if (p.flags & (16 /* Function */ | 8192 /* Method */) && !getPropertiesOfObjectType(t).length) { - var signatures = getSignaturesOfType(t, 0 /* Call */); - for (var _f = 0; _f < signatures.length; _f++) { - var signature = signatures[_f]; - buildSymbolDisplay(p, writer); - if (p.flags & 536870912 /* Optional */) { - writePunctuation(writer, 50 /* QuestionToken */); - } - buildSignatureDisplay(signature, writer, enclosingDeclaration, globalFlagsToPass, symbolStack); - writePunctuation(writer, 22 /* SemicolonToken */); - writer.writeLine(); - } - } - else { - buildSymbolDisplay(p, writer); - if (p.flags & 536870912 /* Optional */) { - writePunctuation(writer, 50 /* QuestionToken */); - } - writePunctuation(writer, 51 /* ColonToken */); - writeSpace(writer); - writeType(t, 0 /* None */); - writePunctuation(writer, 22 /* SemicolonToken */); - writer.writeLine(); - } - } - writer.decreaseIndent(); - writePunctuation(writer, 15 /* CloseBraceToken */); - } - } - function buildTypeParameterDisplayFromSymbol(symbol, writer, enclosingDeclaraiton, flags) { - var targetSymbol = getTargetSymbol(symbol); - if (targetSymbol.flags & 32 /* Class */ || targetSymbol.flags & 64 /* Interface */) { - buildDisplayForTypeParametersAndDelimiters(getLocalTypeParametersOfClassOrInterfaceOrTypeAlias(symbol), writer, enclosingDeclaraiton, flags); - } - } - function buildTypeParameterDisplay(tp, writer, enclosingDeclaration, flags, symbolStack) { - appendSymbolNameOnly(tp.symbol, writer); - var constraint = getConstraintOfTypeParameter(tp); - if (constraint) { - writeSpace(writer); - writeKeyword(writer, 79 /* ExtendsKeyword */); - writeSpace(writer); - buildTypeDisplay(constraint, writer, enclosingDeclaration, flags, symbolStack); - } - } - function buildParameterDisplay(p, writer, enclosingDeclaration, flags, symbolStack) { - var parameterNode = p.valueDeclaration; - if (ts.isRestParameter(parameterNode)) { - writePunctuation(writer, 21 /* DotDotDotToken */); - } - appendSymbolNameOnly(p, writer); - if (isOptionalParameter(parameterNode)) { - writePunctuation(writer, 50 /* QuestionToken */); - } - writePunctuation(writer, 51 /* ColonToken */); - writeSpace(writer); - buildTypeDisplay(getTypeOfSymbol(p), writer, enclosingDeclaration, flags, symbolStack); - } - function buildDisplayForTypeParametersAndDelimiters(typeParameters, writer, enclosingDeclaration, flags, symbolStack) { - if (typeParameters && typeParameters.length) { - writePunctuation(writer, 24 /* LessThanToken */); - for (var i = 0; i < typeParameters.length; i++) { - if (i > 0) { - writePunctuation(writer, 23 /* CommaToken */); - writeSpace(writer); - } - buildTypeParameterDisplay(typeParameters[i], writer, enclosingDeclaration, flags, symbolStack); - } - writePunctuation(writer, 25 /* GreaterThanToken */); - } - } - function buildDisplayForTypeArgumentsAndDelimiters(typeParameters, mapper, writer, enclosingDeclaration, flags, symbolStack) { - if (typeParameters && typeParameters.length) { - writePunctuation(writer, 24 /* LessThanToken */); - for (var i = 0; i < typeParameters.length; i++) { - if (i > 0) { - writePunctuation(writer, 23 /* CommaToken */); - writeSpace(writer); - } - buildTypeDisplay(mapper(typeParameters[i]), writer, enclosingDeclaration, 0 /* None */); - } - writePunctuation(writer, 25 /* GreaterThanToken */); - } - } - function buildDisplayForParametersAndDelimiters(parameters, writer, enclosingDeclaration, flags, symbolStack) { - writePunctuation(writer, 16 /* OpenParenToken */); - for (var i = 0; i < parameters.length; i++) { - if (i > 0) { - writePunctuation(writer, 23 /* CommaToken */); - writeSpace(writer); - } - buildParameterDisplay(parameters[i], writer, enclosingDeclaration, flags, symbolStack); - } - writePunctuation(writer, 17 /* CloseParenToken */); - } - function buildReturnTypeDisplay(signature, writer, enclosingDeclaration, flags, symbolStack) { - if (flags & 8 /* WriteArrowStyleSignature */) { - writeSpace(writer); - writePunctuation(writer, 32 /* EqualsGreaterThanToken */); - } - else { - writePunctuation(writer, 51 /* ColonToken */); - } - writeSpace(writer); - buildTypeDisplay(getReturnTypeOfSignature(signature), writer, enclosingDeclaration, flags, symbolStack); - } - function buildSignatureDisplay(signature, writer, enclosingDeclaration, flags, symbolStack) { - if (signature.target && (flags & 32 /* WriteTypeArgumentsOfSignature */)) { - // Instantiated signature, write type arguments instead - // This is achieved by passing in the mapper separately - buildDisplayForTypeArgumentsAndDelimiters(signature.target.typeParameters, signature.mapper, writer, enclosingDeclaration); - } - else { - buildDisplayForTypeParametersAndDelimiters(signature.typeParameters, writer, enclosingDeclaration, flags, symbolStack); - } - buildDisplayForParametersAndDelimiters(signature.parameters, writer, enclosingDeclaration, flags, symbolStack); - buildReturnTypeDisplay(signature, writer, enclosingDeclaration, flags, symbolStack); - } - return _displayBuilder || (_displayBuilder = { - symbolToString: symbolToString, - typeToString: typeToString, - buildSymbolDisplay: buildSymbolDisplay, - buildTypeDisplay: buildTypeDisplay, - buildTypeParameterDisplay: buildTypeParameterDisplay, - buildParameterDisplay: buildParameterDisplay, - buildDisplayForParametersAndDelimiters: buildDisplayForParametersAndDelimiters, - buildDisplayForTypeParametersAndDelimiters: buildDisplayForTypeParametersAndDelimiters, - buildDisplayForTypeArgumentsAndDelimiters: buildDisplayForTypeArgumentsAndDelimiters, - buildTypeParameterDisplayFromSymbol: buildTypeParameterDisplayFromSymbol, - buildSignatureDisplay: buildSignatureDisplay, - buildReturnTypeDisplay: buildReturnTypeDisplay - }); - } - function isDeclarationVisible(node) { - function getContainingExternalModule(node) { - for (; node; node = node.parent) { - if (node.kind === 208 /* ModuleDeclaration */) { - if (node.name.kind === 8 /* StringLiteral */) { - return node; - } - } - else if (node.kind === 230 /* SourceFile */) { - return ts.isExternalModule(node) ? node : undefined; - } - } - ts.Debug.fail("getContainingModule cant reach here"); - } - function isUsedInExportAssignment(node) { - // Get source File and see if it is external module and has export assigned symbol - var externalModule = getContainingExternalModule(node); - var exportAssignmentSymbol; - var resolvedExportSymbol; - if (externalModule) { - // This is export assigned symbol node - var externalModuleSymbol = getSymbolOfNode(externalModule); - exportAssignmentSymbol = getExportAssignmentSymbol(externalModuleSymbol); - var symbolOfNode = getSymbolOfNode(node); - if (isSymbolUsedInExportAssignment(symbolOfNode)) { - return true; - } - // if symbolOfNode is alias declaration, resolve the symbol declaration and check - if (symbolOfNode.flags & 8388608 /* Alias */) { - return isSymbolUsedInExportAssignment(resolveAlias(symbolOfNode)); - } - } - // Check if the symbol is used in export assignment - function isSymbolUsedInExportAssignment(symbol) { - if (exportAssignmentSymbol === symbol) { - return true; - } - if (exportAssignmentSymbol && !!(exportAssignmentSymbol.flags & 8388608 /* Alias */)) { - // if export assigned symbol is alias declaration, resolve the alias - resolvedExportSymbol = resolvedExportSymbol || resolveAlias(exportAssignmentSymbol); - if (resolvedExportSymbol === symbol) { - return true; - } - // Container of resolvedExportSymbol is visible - return ts.forEach(resolvedExportSymbol.declarations, function (current) { - while (current) { - if (current === node) { - return true; - } - current = current.parent; - } - }); - } - } - } - function determineIfDeclarationIsVisible() { - switch (node.kind) { - case 155 /* BindingElement */: - return isDeclarationVisible(node.parent.parent); - case 201 /* VariableDeclaration */: - if (ts.isBindingPattern(node.name) && - !node.name.elements.length) { - // If the binding pattern is empty, this variable declaration is not visible - return false; - } - // Otherwise fall through - case 208 /* ModuleDeclaration */: - case 204 /* ClassDeclaration */: - case 205 /* InterfaceDeclaration */: - case 206 /* TypeAliasDeclaration */: - case 203 /* FunctionDeclaration */: - case 207 /* EnumDeclaration */: - case 211 /* ImportEqualsDeclaration */: - var parent_4 = getDeclarationContainer(node); - // If the node is not exported or it is not ambient module element (except import declaration) - if (!(ts.getCombinedNodeFlags(node) & 1 /* Export */) && - !(node.kind !== 211 /* ImportEqualsDeclaration */ && parent_4.kind !== 230 /* SourceFile */ && ts.isInAmbientContext(parent_4))) { - return isGlobalSourceFile(parent_4); - } - // Exported members/ambient module elements (exception import declaration) are visible if parent is visible - return isDeclarationVisible(parent_4); - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - if (node.flags & (32 /* Private */ | 64 /* Protected */)) { - // Private/protected properties/methods are not visible - return false; - } - // Public properties/methods are visible if its parents are visible, so let it fall into next case statement - case 137 /* Constructor */: - case 141 /* ConstructSignature */: - case 140 /* CallSignature */: - case 142 /* IndexSignature */: - case 131 /* Parameter */: - case 209 /* ModuleBlock */: - case 145 /* FunctionType */: - case 146 /* ConstructorType */: - case 148 /* TypeLiteral */: - case 144 /* TypeReference */: - case 149 /* ArrayType */: - case 150 /* TupleType */: - case 151 /* UnionType */: - case 152 /* ParenthesizedType */: - return isDeclarationVisible(node.parent); - // Default binding, import specifier and namespace import is visible - // only on demand so by default it is not visible - case 213 /* ImportClause */: - case 214 /* NamespaceImport */: - case 216 /* ImportSpecifier */: - return false; - // Type parameters are always visible - case 130 /* TypeParameter */: - // Source file is always visible - case 230 /* SourceFile */: - return true; - // Export assignements do not create name bindings outside the module - case 217 /* ExportAssignment */: - return false; - default: - ts.Debug.fail("isDeclarationVisible unknown: SyntaxKind: " + node.kind); - } - } - if (node) { - var links = getNodeLinks(node); - if (links.isVisible === undefined) { - links.isVisible = !!determineIfDeclarationIsVisible(); - } - return links.isVisible; - } - } - function collectLinkedAliases(node) { - var exportSymbol; - if (node.parent && node.parent.kind === 217 /* ExportAssignment */) { - exportSymbol = resolveName(node.parent, node.text, 107455 /* Value */ | 793056 /* Type */ | 1536 /* Namespace */, ts.Diagnostics.Cannot_find_name_0, node); - } - else if (node.parent.kind === 220 /* ExportSpecifier */) { - exportSymbol = getTargetOfExportSpecifier(node.parent); - } - var result = []; - if (exportSymbol) { - buildVisibleNodeList(exportSymbol.declarations); - } - return result; - function buildVisibleNodeList(declarations) { - ts.forEach(declarations, function (declaration) { - getNodeLinks(declaration).isVisible = true; - var resultNode = getAnyImportSyntax(declaration) || declaration; - if (!ts.contains(result, resultNode)) { - result.push(resultNode); - } - if (ts.isInternalModuleImportEqualsDeclaration(declaration)) { - // Add the referenced top container visible - var internalModuleReference = declaration.moduleReference; - var firstIdentifier = getFirstIdentifier(internalModuleReference); - var importSymbol = resolveName(declaration, firstIdentifier.text, 107455 /* Value */ | 793056 /* Type */ | 1536 /* Namespace */, ts.Diagnostics.Cannot_find_name_0, firstIdentifier); - buildVisibleNodeList(importSymbol.declarations); - } - }); - } - } - // Push an entry on the type resolution stack. If an entry with the given target is not already on the stack, - // a new entry with that target and an associated result value of true is pushed on the stack, and the value - // true is returned. Otherwise, a circularity has occurred and the result values of the existing entry and - // all entries pushed after it are changed to false, and the value false is returned. The target object provides - // a unique identity for a particular type resolution result: Symbol instances are used to track resolution of - // SymbolLinks.type, SymbolLinks instances are used to track resolution of SymbolLinks.declaredType, and - // Signature instances are used to track resolution of Signature.resolvedReturnType. - function pushTypeResolution(target) { - var i = 0; - var count = resolutionTargets.length; - while (i < count && resolutionTargets[i] !== target) { - i++; - } - if (i < count) { - do { - resolutionResults[i++] = false; - } while (i < count); - return false; - } - resolutionTargets.push(target); - resolutionResults.push(true); - return true; - } - // Pop an entry from the type resolution stack and return its associated result value. The result value will - // be true if no circularities were detected, or false if a circularity was found. - function popTypeResolution() { - resolutionTargets.pop(); - return resolutionResults.pop(); - } - function getDeclarationContainer(node) { - node = ts.getRootDeclaration(node); - // Parent chain: - // VaribleDeclaration -> VariableDeclarationList -> VariableStatement -> 'Declaration Container' - return node.kind === 201 /* VariableDeclaration */ ? node.parent.parent.parent : node.parent; - } - function getTypeOfPrototypeProperty(prototype) { - // TypeScript 1.0 spec (April 2014): 8.4 - // Every class automatically contains a static property member named 'prototype', - // the type of which is an instantiation of the class type with type Any supplied as a type argument for each type parameter. - // It is an error to explicitly declare a static property member with the name 'prototype'. - var classType = getDeclaredTypeOfSymbol(prototype.parent); - return classType.typeParameters ? createTypeReference(classType, ts.map(classType.typeParameters, function (_) { return anyType; })) : classType; - } - // Return the type of the given property in the given type, or undefined if no such property exists - function getTypeOfPropertyOfType(type, name) { - var prop = getPropertyOfType(type, name); - return prop ? getTypeOfSymbol(prop) : undefined; - } - function isTypeAny(type) { - return type && (type.flags & 1 /* Any */) !== 0; - } - // Return the inferred type for a binding element - function getTypeForBindingElement(declaration) { - var pattern = declaration.parent; - var parentType = getTypeForVariableLikeDeclaration(pattern.parent); - // If parent has the unknown (error) type, then so does this binding element - if (parentType === unknownType) { - return unknownType; - } - // If no type was specified or inferred for parent, or if the specified or inferred type is any, - // infer from the initializer of the binding element if one is present. Otherwise, go with the - // undefined or any type of the parent. - if (!parentType || isTypeAny(parentType)) { - if (declaration.initializer) { - return checkExpressionCached(declaration.initializer); - } - return parentType; - } - var type; - if (pattern.kind === 153 /* ObjectBindingPattern */) { - // Use explicitly specified property name ({ p: xxx } form), or otherwise the implied name ({ p } form) - var name_9 = declaration.propertyName || declaration.name; - // Use type of the specified property, or otherwise, for a numeric name, the type of the numeric index signature, - // or otherwise the type of the string index signature. - type = getTypeOfPropertyOfType(parentType, name_9.text) || - isNumericLiteralName(name_9.text) && getIndexTypeOfType(parentType, 1 /* Number */) || - getIndexTypeOfType(parentType, 0 /* String */); - if (!type) { - error(name_9, ts.Diagnostics.Type_0_has_no_property_1_and_no_string_index_signature, typeToString(parentType), ts.declarationNameToString(name_9)); - return unknownType; - } - } - else { - // This elementType will be used if the specific property corresponding to this index is not - // present (aka the tuple element property). This call also checks that the parentType is in - // fact an iterable or array (depending on target language). - var elementType = checkIteratedTypeOrElementType(parentType, pattern, false); - if (!declaration.dotDotDotToken) { - if (isTypeAny(elementType)) { - return elementType; - } - // Use specific property type when parent is a tuple or numeric index type when parent is an array - var propName = "" + ts.indexOf(pattern.elements, declaration); - type = isTupleLikeType(parentType) - ? getTypeOfPropertyOfType(parentType, propName) - : elementType; - if (!type) { - if (isTupleType(parentType)) { - error(declaration, ts.Diagnostics.Tuple_type_0_with_length_1_cannot_be_assigned_to_tuple_with_length_2, typeToString(parentType), parentType.elementTypes.length, pattern.elements.length); - } - else { - error(declaration, ts.Diagnostics.Type_0_has_no_property_1, typeToString(parentType), propName); - } - return unknownType; - } - } - else { - // Rest element has an array type with the same element type as the parent type - type = createArrayType(elementType); - } - } - return type; - } - // Return the inferred type for a variable, parameter, or property declaration - function getTypeForVariableLikeDeclaration(declaration) { - // A variable declared in a for..in statement is always of type any - if (declaration.parent.parent.kind === 190 /* ForInStatement */) { - return anyType; - } - if (declaration.parent.parent.kind === 191 /* ForOfStatement */) { - // checkRightHandSideOfForOf will return undefined if the for-of expression type was - // missing properties/signatures required to get its iteratedType (like - // [Symbol.iterator] or next). This may be because we accessed properties from anyType, - // or it may have led to an error inside getElementTypeOfIterable. - return checkRightHandSideOfForOf(declaration.parent.parent.expression) || anyType; - } - if (ts.isBindingPattern(declaration.parent)) { - return getTypeForBindingElement(declaration); - } - // Use type from type annotation if one is present - if (declaration.type) { - return getTypeFromTypeNode(declaration.type); - } - if (declaration.kind === 131 /* Parameter */) { - var func = declaration.parent; - // For a parameter of a set accessor, use the type of the get accessor if one is present - if (func.kind === 139 /* SetAccessor */ && !ts.hasDynamicName(func)) { - var getter = ts.getDeclarationOfKind(declaration.parent.symbol, 138 /* GetAccessor */); - if (getter) { - return getReturnTypeOfSignature(getSignatureFromDeclaration(getter)); - } - } - // Use contextual parameter type if one is available - var type = getContextuallyTypedParameterType(declaration); - if (type) { - return type; - } - } - // Use the type of the initializer expression if one is present - if (declaration.initializer) { - return checkExpressionCached(declaration.initializer); - } - // If it is a short-hand property assignment, use the type of the identifier - if (declaration.kind === 228 /* ShorthandPropertyAssignment */) { - return checkIdentifier(declaration.name); - } - // No type specified and nothing can be inferred - return undefined; - } - // Return the type implied by a binding pattern element. This is the type of the initializer of the element if - // one is present. Otherwise, if the element is itself a binding pattern, it is the type implied by the binding - // pattern. Otherwise, it is the type any. - function getTypeFromBindingElement(element) { - if (element.initializer) { - return getWidenedType(checkExpressionCached(element.initializer)); - } - if (ts.isBindingPattern(element.name)) { - return getTypeFromBindingPattern(element.name); - } - return anyType; - } - // Return the type implied by an object binding pattern - function getTypeFromObjectBindingPattern(pattern) { - var members = {}; - ts.forEach(pattern.elements, function (e) { - var flags = 4 /* Property */ | 67108864 /* Transient */ | (e.initializer ? 536870912 /* Optional */ : 0); - var name = e.propertyName || e.name; - var symbol = createSymbol(flags, name.text); - symbol.type = getTypeFromBindingElement(e); - members[symbol.name] = symbol; - }); - return createAnonymousType(undefined, members, emptyArray, emptyArray, undefined, undefined); - } - // Return the type implied by an array binding pattern - function getTypeFromArrayBindingPattern(pattern) { - var hasSpreadElement = false; - var elementTypes = []; - ts.forEach(pattern.elements, function (e) { - elementTypes.push(e.kind === 178 /* OmittedExpression */ || e.dotDotDotToken ? anyType : getTypeFromBindingElement(e)); - if (e.dotDotDotToken) { - hasSpreadElement = true; - } - }); - if (!elementTypes.length) { - return languageVersion >= 2 /* ES6 */ ? createIterableType(anyType) : anyArrayType; - } - else if (hasSpreadElement) { - var unionOfElements = getUnionType(elementTypes); - return languageVersion >= 2 /* ES6 */ ? createIterableType(unionOfElements) : createArrayType(unionOfElements); - } - // If the pattern has at least one element, and no rest element, then it should imply a tuple type. - return createTupleType(elementTypes); - } - // Return the type implied by a binding pattern. This is the type implied purely by the binding pattern itself - // and without regard to its context (i.e. without regard any type annotation or initializer associated with the - // declaration in which the binding pattern is contained). For example, the implied type of [x, y] is [any, any] - // and the implied type of { x, y: z = 1 } is { x: any; y: number; }. The type implied by a binding pattern is - // used as the contextual type of an initializer associated with the binding pattern. Also, for a destructuring - // parameter with no type annotation or initializer, the type implied by the binding pattern becomes the type of - // the parameter. - function getTypeFromBindingPattern(pattern) { - return pattern.kind === 153 /* ObjectBindingPattern */ - ? getTypeFromObjectBindingPattern(pattern) - : getTypeFromArrayBindingPattern(pattern); - } - // Return the type associated with a variable, parameter, or property declaration. In the simple case this is the type - // specified in a type annotation or inferred from an initializer. However, in the case of a destructuring declaration it - // is a bit more involved. For example: - // - // var [x, s = ""] = [1, "one"]; - // - // Here, the array literal [1, "one"] is contextually typed by the type [any, string], which is the implied type of the - // binding pattern [x, s = ""]. Because the contextual type is a tuple type, the resulting type of [1, "one"] is the - // tuple type [number, string]. Thus, the type inferred for 'x' is number and the type inferred for 's' is string. - function getWidenedTypeForVariableLikeDeclaration(declaration, reportErrors) { - var type = getTypeForVariableLikeDeclaration(declaration); - if (type) { - if (reportErrors) { - reportErrorsFromWidening(declaration, type); - } - // During a normal type check we'll never get to here with a property assignment (the check of the containing - // object literal uses a different path). We exclude widening only so that language services and type verification - // tools see the actual type. - return declaration.kind !== 227 /* PropertyAssignment */ ? getWidenedType(type) : type; - } - // If no type was specified and nothing could be inferred, and if the declaration specifies a binding pattern, use - // the type implied by the binding pattern - if (ts.isBindingPattern(declaration.name)) { - return getTypeFromBindingPattern(declaration.name); - } - // Rest parameters default to type any[], other parameters default to type any - type = declaration.dotDotDotToken ? anyArrayType : anyType; - // Report implicit any errors unless this is a private property within an ambient declaration - if (reportErrors && compilerOptions.noImplicitAny) { - var root = ts.getRootDeclaration(declaration); - if (!isPrivateWithinAmbient(root) && !(root.kind === 131 /* Parameter */ && isPrivateWithinAmbient(root.parent))) { - reportImplicitAnyError(declaration, type); - } - } - return type; - } - function getTypeOfVariableOrParameterOrProperty(symbol) { - var links = getSymbolLinks(symbol); - if (!links.type) { - // Handle prototype property - if (symbol.flags & 134217728 /* Prototype */) { - return links.type = getTypeOfPrototypeProperty(symbol); - } - // Handle catch clause variables - var declaration = symbol.valueDeclaration; - if (declaration.parent.kind === 226 /* CatchClause */) { - return links.type = anyType; - } - // Handle export default expressions - if (declaration.kind === 217 /* ExportAssignment */) { - return links.type = checkExpression(declaration.expression); - } - // Handle variable, parameter or property - if (!pushTypeResolution(symbol)) { - return unknownType; - } - var type = getWidenedTypeForVariableLikeDeclaration(declaration, true); - if (!popTypeResolution()) { - if (symbol.valueDeclaration.type) { - // Variable has type annotation that circularly references the variable itself - type = unknownType; - error(symbol.valueDeclaration, ts.Diagnostics._0_is_referenced_directly_or_indirectly_in_its_own_type_annotation, symbolToString(symbol)); - } - else { - // Variable has initializer that circularly references the variable itself - type = anyType; - if (compilerOptions.noImplicitAny) { - error(symbol.valueDeclaration, ts.Diagnostics._0_implicitly_has_type_any_because_it_does_not_have_a_type_annotation_and_is_referenced_directly_or_indirectly_in_its_own_initializer, symbolToString(symbol)); - } - } - } - links.type = type; - } - return links.type; - } - function getSetAccessorTypeAnnotationNode(accessor) { - return accessor && accessor.parameters.length > 0 && accessor.parameters[0].type; - } - function getAnnotatedAccessorType(accessor) { - if (accessor) { - if (accessor.kind === 138 /* GetAccessor */) { - return accessor.type && getTypeFromTypeNode(accessor.type); - } - else { - var setterTypeAnnotation = getSetAccessorTypeAnnotationNode(accessor); - return setterTypeAnnotation && getTypeFromTypeNode(setterTypeAnnotation); - } - } - return undefined; - } - function getTypeOfAccessors(symbol) { - var links = getSymbolLinks(symbol); - if (!links.type) { - if (!pushTypeResolution(symbol)) { - return unknownType; - } - var getter = ts.getDeclarationOfKind(symbol, 138 /* GetAccessor */); - var setter = ts.getDeclarationOfKind(symbol, 139 /* SetAccessor */); - var type; - // First try to see if the user specified a return type on the get-accessor. - var getterReturnType = getAnnotatedAccessorType(getter); - if (getterReturnType) { - type = getterReturnType; - } - else { - // If the user didn't specify a return type, try to use the set-accessor's parameter type. - var setterParameterType = getAnnotatedAccessorType(setter); - if (setterParameterType) { - type = setterParameterType; - } - else { - // If there are no specified types, try to infer it from the body of the get accessor if it exists. - if (getter && getter.body) { - type = getReturnTypeFromBody(getter); - } - else { - if (compilerOptions.noImplicitAny) { - error(setter, ts.Diagnostics.Property_0_implicitly_has_type_any_because_its_set_accessor_lacks_a_type_annotation, symbolToString(symbol)); - } - type = anyType; - } - } - } - if (!popTypeResolution()) { - type = anyType; - if (compilerOptions.noImplicitAny) { - var getter_1 = ts.getDeclarationOfKind(symbol, 138 /* GetAccessor */); - error(getter_1, ts.Diagnostics._0_implicitly_has_return_type_any_because_it_does_not_have_a_return_type_annotation_and_is_referenced_directly_or_indirectly_in_one_of_its_return_expressions, symbolToString(symbol)); - } - } - links.type = type; - } - return links.type; - } - function getTypeOfFuncClassEnumModule(symbol) { - var links = getSymbolLinks(symbol); - if (!links.type) { - links.type = createObjectType(32768 /* Anonymous */, symbol); - } - return links.type; - } - function getTypeOfEnumMember(symbol) { - var links = getSymbolLinks(symbol); - if (!links.type) { - links.type = getDeclaredTypeOfEnum(getParentOfSymbol(symbol)); - } - return links.type; - } - function getTypeOfAlias(symbol) { - var links = getSymbolLinks(symbol); - if (!links.type) { - var targetSymbol = resolveAlias(symbol); - // It only makes sense to get the type of a value symbol. If the result of resolving - // the alias is not a value, then it has no type. To get the type associated with a - // type symbol, call getDeclaredTypeOfSymbol. - // This check is important because without it, a call to getTypeOfSymbol could end - // up recursively calling getTypeOfAlias, causing a stack overflow. - links.type = targetSymbol.flags & 107455 /* Value */ - ? getTypeOfSymbol(targetSymbol) - : unknownType; - } - return links.type; - } - function getTypeOfInstantiatedSymbol(symbol) { - var links = getSymbolLinks(symbol); - if (!links.type) { - links.type = instantiateType(getTypeOfSymbol(links.target), links.mapper); - } - return links.type; - } - function getTypeOfSymbol(symbol) { - if (symbol.flags & 16777216 /* Instantiated */) { - return getTypeOfInstantiatedSymbol(symbol); - } - if (symbol.flags & (3 /* Variable */ | 4 /* Property */)) { - return getTypeOfVariableOrParameterOrProperty(symbol); - } - if (symbol.flags & (16 /* Function */ | 8192 /* Method */ | 32 /* Class */ | 384 /* Enum */ | 512 /* ValueModule */)) { - return getTypeOfFuncClassEnumModule(symbol); - } - if (symbol.flags & 8 /* EnumMember */) { - return getTypeOfEnumMember(symbol); - } - if (symbol.flags & 98304 /* Accessor */) { - return getTypeOfAccessors(symbol); - } - if (symbol.flags & 8388608 /* Alias */) { - return getTypeOfAlias(symbol); - } - return unknownType; - } - function getTargetType(type) { - return type.flags & 4096 /* Reference */ ? type.target : type; - } - function hasBaseType(type, checkBase) { - return check(type); - function check(type) { - var target = getTargetType(type); - return target === checkBase || ts.forEach(getBaseTypes(target), check); - } - } - // Appends the type parameters given by a list of declarations to a set of type parameters and returns the resulting set. - // The function allocates a new array if the input type parameter set is undefined, but otherwise it modifies the set - // in-place and returns the same array. - function appendTypeParameters(typeParameters, declarations) { - for (var _i = 0; _i < declarations.length; _i++) { - var declaration = declarations[_i]; - var tp = getDeclaredTypeOfTypeParameter(getSymbolOfNode(declaration)); - if (!typeParameters) { - typeParameters = [tp]; - } - else if (!ts.contains(typeParameters, tp)) { - typeParameters.push(tp); - } - } - return typeParameters; - } - // Appends the outer type parameters of a node to a set of type parameters and returns the resulting set. The function - // allocates a new array if the input type parameter set is undefined, but otherwise it modifies the set in-place and - // returns the same array. - function appendOuterTypeParameters(typeParameters, node) { - while (true) { - node = node.parent; - if (!node) { - return typeParameters; - } - if (node.kind === 204 /* ClassDeclaration */ || node.kind === 203 /* FunctionDeclaration */ || - node.kind === 165 /* FunctionExpression */ || node.kind === 136 /* MethodDeclaration */ || - node.kind === 166 /* ArrowFunction */) { - var declarations = node.typeParameters; - if (declarations) { - return appendTypeParameters(appendOuterTypeParameters(typeParameters, node), declarations); - } - } - } - } - // The outer type parameters are those defined by enclosing generic classes, methods, or functions. - function getOuterTypeParametersOfClassOrInterface(symbol) { - var kind = symbol.flags & 32 /* Class */ ? 204 /* ClassDeclaration */ : 205 /* InterfaceDeclaration */; - return appendOuterTypeParameters(undefined, ts.getDeclarationOfKind(symbol, kind)); - } - // The local type parameters are the combined set of type parameters from all declarations of the class, - // interface, or type alias. - function getLocalTypeParametersOfClassOrInterfaceOrTypeAlias(symbol) { - var result; - for (var _i = 0, _a = symbol.declarations; _i < _a.length; _i++) { - var node = _a[_i]; - if (node.kind === 205 /* InterfaceDeclaration */ || node.kind === 204 /* ClassDeclaration */ || node.kind === 206 /* TypeAliasDeclaration */) { - var declaration = node; - if (declaration.typeParameters) { - result = appendTypeParameters(result, declaration.typeParameters); - } - } - } - return result; - } - // The full set of type parameters for a generic class or interface type consists of its outer type parameters plus - // its locally declared type parameters. - function getTypeParametersOfClassOrInterface(symbol) { - return ts.concatenate(getOuterTypeParametersOfClassOrInterface(symbol), getLocalTypeParametersOfClassOrInterfaceOrTypeAlias(symbol)); - } - function getBaseTypes(type) { - var typeWithBaseTypes = type; - if (!typeWithBaseTypes.baseTypes) { - if (type.symbol.flags & 32 /* Class */) { - resolveBaseTypesOfClass(typeWithBaseTypes); - } - else if (type.symbol.flags & 64 /* Interface */) { - resolveBaseTypesOfInterface(typeWithBaseTypes); - } - else { - ts.Debug.fail("type must be class or interface"); - } - } - return typeWithBaseTypes.baseTypes; - } - function resolveBaseTypesOfClass(type) { - type.baseTypes = []; - var declaration = ts.getDeclarationOfKind(type.symbol, 204 /* ClassDeclaration */); - var baseTypeNode = ts.getClassExtendsHeritageClauseElement(declaration); - if (baseTypeNode) { - var baseType = getTypeFromTypeNode(baseTypeNode); - if (baseType !== unknownType) { - if (getTargetType(baseType).flags & 1024 /* Class */) { - if (type !== baseType && !hasBaseType(baseType, type)) { - type.baseTypes.push(baseType); - } - else { - error(declaration, ts.Diagnostics.Type_0_recursively_references_itself_as_a_base_type, typeToString(type, undefined, 1 /* WriteArrayAsGenericType */)); - } - } - else { - error(baseTypeNode, ts.Diagnostics.A_class_may_only_extend_another_class); - } - } - } - } - function resolveBaseTypesOfInterface(type) { - type.baseTypes = []; - for (var _i = 0, _a = type.symbol.declarations; _i < _a.length; _i++) { - var declaration = _a[_i]; - if (declaration.kind === 205 /* InterfaceDeclaration */ && ts.getInterfaceBaseTypeNodes(declaration)) { - for (var _b = 0, _c = ts.getInterfaceBaseTypeNodes(declaration); _b < _c.length; _b++) { - var node = _c[_b]; - var baseType = getTypeFromTypeNode(node); - if (baseType !== unknownType) { - if (getTargetType(baseType).flags & (1024 /* Class */ | 2048 /* Interface */)) { - if (type !== baseType && !hasBaseType(baseType, type)) { - type.baseTypes.push(baseType); - } - else { - error(declaration, ts.Diagnostics.Type_0_recursively_references_itself_as_a_base_type, typeToString(type, undefined, 1 /* WriteArrayAsGenericType */)); - } - } - else { - error(node, ts.Diagnostics.An_interface_may_only_extend_a_class_or_another_interface); - } - } - } - } - } - } - function getDeclaredTypeOfClassOrInterface(symbol) { - var links = getSymbolLinks(symbol); - if (!links.declaredType) { - var kind = symbol.flags & 32 /* Class */ ? 1024 /* Class */ : 2048 /* Interface */; - var type = links.declaredType = createObjectType(kind, symbol); - var outerTypeParameters = getOuterTypeParametersOfClassOrInterface(symbol); - var localTypeParameters = getLocalTypeParametersOfClassOrInterfaceOrTypeAlias(symbol); - if (outerTypeParameters || localTypeParameters) { - type.flags |= 4096 /* Reference */; - type.typeParameters = ts.concatenate(outerTypeParameters, localTypeParameters); - type.outerTypeParameters = outerTypeParameters; - type.localTypeParameters = localTypeParameters; - type.instantiations = {}; - type.instantiations[getTypeListId(type.typeParameters)] = type; - type.target = type; - type.typeArguments = type.typeParameters; - } - } - return links.declaredType; - } - function getDeclaredTypeOfTypeAlias(symbol) { - var links = getSymbolLinks(symbol); - if (!links.declaredType) { - // Note that we use the links object as the target here because the symbol object is used as the unique - // identity for resolution of the 'type' property in SymbolLinks. - if (!pushTypeResolution(links)) { - return unknownType; - } - var declaration = ts.getDeclarationOfKind(symbol, 206 /* TypeAliasDeclaration */); - var type = getTypeFromTypeNode(declaration.type); - if (popTypeResolution()) { - links.typeParameters = getLocalTypeParametersOfClassOrInterfaceOrTypeAlias(symbol); - if (links.typeParameters) { - // Initialize the instantiation cache for generic type aliases. The declared type corresponds to - // an instantiation of the type alias with the type parameters supplied as type arguments. - links.instantiations = {}; - links.instantiations[getTypeListId(links.typeParameters)] = type; - } - } - else { - type = unknownType; - error(declaration.name, ts.Diagnostics.Type_alias_0_circularly_references_itself, symbolToString(symbol)); - } - links.declaredType = type; - } - return links.declaredType; - } - function getDeclaredTypeOfEnum(symbol) { - var links = getSymbolLinks(symbol); - if (!links.declaredType) { - var type = createType(128 /* Enum */); - type.symbol = symbol; - links.declaredType = type; - } - return links.declaredType; - } - function getDeclaredTypeOfTypeParameter(symbol) { - var links = getSymbolLinks(symbol); - if (!links.declaredType) { - var type = createType(512 /* TypeParameter */); - type.symbol = symbol; - if (!ts.getDeclarationOfKind(symbol, 130 /* TypeParameter */).constraint) { - type.constraint = noConstraintType; - } - links.declaredType = type; - } - return links.declaredType; - } - function getDeclaredTypeOfAlias(symbol) { - var links = getSymbolLinks(symbol); - if (!links.declaredType) { - links.declaredType = getDeclaredTypeOfSymbol(resolveAlias(symbol)); - } - return links.declaredType; - } - function getDeclaredTypeOfSymbol(symbol) { - ts.Debug.assert((symbol.flags & 16777216 /* Instantiated */) === 0); - if (symbol.flags & (32 /* Class */ | 64 /* Interface */)) { - return getDeclaredTypeOfClassOrInterface(symbol); - } - if (symbol.flags & 524288 /* TypeAlias */) { - return getDeclaredTypeOfTypeAlias(symbol); - } - if (symbol.flags & 384 /* Enum */) { - return getDeclaredTypeOfEnum(symbol); - } - if (symbol.flags & 262144 /* TypeParameter */) { - return getDeclaredTypeOfTypeParameter(symbol); - } - if (symbol.flags & 8388608 /* Alias */) { - return getDeclaredTypeOfAlias(symbol); - } - return unknownType; - } - function createSymbolTable(symbols) { - var result = {}; - for (var _i = 0; _i < symbols.length; _i++) { - var symbol = symbols[_i]; - result[symbol.name] = symbol; - } - return result; - } - function createInstantiatedSymbolTable(symbols, mapper) { - var result = {}; - for (var _i = 0; _i < symbols.length; _i++) { - var symbol = symbols[_i]; - result[symbol.name] = instantiateSymbol(symbol, mapper); - } - return result; - } - function addInheritedMembers(symbols, baseSymbols) { - for (var _i = 0; _i < baseSymbols.length; _i++) { - var s = baseSymbols[_i]; - if (!ts.hasProperty(symbols, s.name)) { - symbols[s.name] = s; - } - } - } - function addInheritedSignatures(signatures, baseSignatures) { - if (baseSignatures) { - for (var _i = 0; _i < baseSignatures.length; _i++) { - var signature = baseSignatures[_i]; - signatures.push(signature); - } - } - } - function resolveDeclaredMembers(type) { - if (!type.declaredProperties) { - var symbol = type.symbol; - type.declaredProperties = getNamedMembers(symbol.members); - type.declaredCallSignatures = getSignaturesOfSymbol(symbol.members["__call"]); - type.declaredConstructSignatures = getSignaturesOfSymbol(symbol.members["__new"]); - type.declaredStringIndexType = getIndexTypeOfSymbol(symbol, 0 /* String */); - type.declaredNumberIndexType = getIndexTypeOfSymbol(symbol, 1 /* Number */); - } - return type; - } - function resolveClassOrInterfaceMembers(type) { - var target = resolveDeclaredMembers(type); - var members = target.symbol.members; - var callSignatures = target.declaredCallSignatures; - var constructSignatures = target.declaredConstructSignatures; - var stringIndexType = target.declaredStringIndexType; - var numberIndexType = target.declaredNumberIndexType; - var baseTypes = getBaseTypes(target); - if (baseTypes.length) { - members = createSymbolTable(target.declaredProperties); - for (var _i = 0; _i < baseTypes.length; _i++) { - var baseType = baseTypes[_i]; - addInheritedMembers(members, getPropertiesOfObjectType(baseType)); - callSignatures = ts.concatenate(callSignatures, getSignaturesOfType(baseType, 0 /* Call */)); - constructSignatures = ts.concatenate(constructSignatures, getSignaturesOfType(baseType, 1 /* Construct */)); - stringIndexType = stringIndexType || getIndexTypeOfType(baseType, 0 /* String */); - numberIndexType = numberIndexType || getIndexTypeOfType(baseType, 1 /* Number */); - } - } - setObjectTypeMembers(type, members, callSignatures, constructSignatures, stringIndexType, numberIndexType); - } - function resolveTypeReferenceMembers(type) { - var target = resolveDeclaredMembers(type.target); - var mapper = createTypeMapper(target.typeParameters, type.typeArguments); - var members = createInstantiatedSymbolTable(target.declaredProperties, mapper); - var callSignatures = instantiateList(target.declaredCallSignatures, mapper, instantiateSignature); - var constructSignatures = instantiateList(target.declaredConstructSignatures, mapper, instantiateSignature); - var stringIndexType = target.declaredStringIndexType ? instantiateType(target.declaredStringIndexType, mapper) : undefined; - var numberIndexType = target.declaredNumberIndexType ? instantiateType(target.declaredNumberIndexType, mapper) : undefined; - ts.forEach(getBaseTypes(target), function (baseType) { - var instantiatedBaseType = instantiateType(baseType, mapper); - addInheritedMembers(members, getPropertiesOfObjectType(instantiatedBaseType)); - callSignatures = ts.concatenate(callSignatures, getSignaturesOfType(instantiatedBaseType, 0 /* Call */)); - constructSignatures = ts.concatenate(constructSignatures, getSignaturesOfType(instantiatedBaseType, 1 /* Construct */)); - stringIndexType = stringIndexType || getIndexTypeOfType(instantiatedBaseType, 0 /* String */); - numberIndexType = numberIndexType || getIndexTypeOfType(instantiatedBaseType, 1 /* Number */); - }); - setObjectTypeMembers(type, members, callSignatures, constructSignatures, stringIndexType, numberIndexType); - } - function createSignature(declaration, typeParameters, parameters, resolvedReturnType, typePredicate, minArgumentCount, hasRestParameter, hasStringLiterals) { - var sig = new Signature(checker); - sig.declaration = declaration; - sig.typeParameters = typeParameters; - sig.parameters = parameters; - sig.resolvedReturnType = resolvedReturnType; - sig.typePredicate = typePredicate; - sig.minArgumentCount = minArgumentCount; - sig.hasRestParameter = hasRestParameter; - sig.hasStringLiterals = hasStringLiterals; - return sig; - } - function cloneSignature(sig) { - return createSignature(sig.declaration, sig.typeParameters, sig.parameters, sig.resolvedReturnType, sig.typePredicate, sig.minArgumentCount, sig.hasRestParameter, sig.hasStringLiterals); - } - function getDefaultConstructSignatures(classType) { - var baseTypes = getBaseTypes(classType); - if (baseTypes.length) { - var baseType = baseTypes[0]; - var baseSignatures = getSignaturesOfType(getTypeOfSymbol(baseType.symbol), 1 /* Construct */); - return ts.map(baseSignatures, function (baseSignature) { - var signature = baseType.flags & 4096 /* Reference */ ? - getSignatureInstantiation(baseSignature, baseType.typeArguments) : cloneSignature(baseSignature); - signature.typeParameters = classType.localTypeParameters; - signature.resolvedReturnType = classType; - return signature; - }); - } - return [createSignature(undefined, classType.localTypeParameters, emptyArray, classType, undefined, 0, false, false)]; - } - function createTupleTypeMemberSymbols(memberTypes) { - var members = {}; - for (var i = 0; i < memberTypes.length; i++) { - var symbol = createSymbol(4 /* Property */ | 67108864 /* Transient */, "" + i); - symbol.type = memberTypes[i]; - members[i] = symbol; - } - return members; - } - function resolveTupleTypeMembers(type) { - var arrayType = resolveObjectOrUnionTypeMembers(createArrayType(getUnionType(type.elementTypes))); - var members = createTupleTypeMemberSymbols(type.elementTypes); - addInheritedMembers(members, arrayType.properties); - setObjectTypeMembers(type, members, arrayType.callSignatures, arrayType.constructSignatures, arrayType.stringIndexType, arrayType.numberIndexType); - } - function signatureListsIdentical(s, t) { - if (s.length !== t.length) { - return false; - } - for (var i = 0; i < s.length; i++) { - if (!compareSignatures(s[i], t[i], false, compareTypes)) { - return false; - } - } - return true; - } - // If the lists of call or construct signatures in the given types are all identical except for return types, - // and if none of the signatures are generic, return a list of signatures that has substitutes a union of the - // return types of the corresponding signatures in each resulting signature. - function getUnionSignatures(types, kind) { - var signatureLists = ts.map(types, function (t) { return getSignaturesOfType(t, kind); }); - var signatures = signatureLists[0]; - for (var _i = 0; _i < signatures.length; _i++) { - var signature = signatures[_i]; - if (signature.typeParameters) { - return emptyArray; - } - } - for (var i_1 = 1; i_1 < signatureLists.length; i_1++) { - if (!signatureListsIdentical(signatures, signatureLists[i_1])) { - return emptyArray; - } - } - var result = ts.map(signatures, cloneSignature); - for (var i = 0; i < result.length; i++) { - var s = result[i]; - // Clear resolved return type we possibly got from cloneSignature - s.resolvedReturnType = undefined; - s.unionSignatures = ts.map(signatureLists, function (signatures) { return signatures[i]; }); - } - return result; - } - function getUnionIndexType(types, kind) { - var indexTypes = []; - for (var _i = 0; _i < types.length; _i++) { - var type = types[_i]; - var indexType = getIndexTypeOfType(type, kind); - if (!indexType) { - return undefined; - } - indexTypes.push(indexType); - } - return getUnionType(indexTypes); - } - function resolveUnionTypeMembers(type) { - // The members and properties collections are empty for union types. To get all properties of a union - // type use getPropertiesOfType (only the language service uses this). - var callSignatures = getUnionSignatures(type.types, 0 /* Call */); - var constructSignatures = getUnionSignatures(type.types, 1 /* Construct */); - var stringIndexType = getUnionIndexType(type.types, 0 /* String */); - var numberIndexType = getUnionIndexType(type.types, 1 /* Number */); - setObjectTypeMembers(type, emptySymbols, callSignatures, constructSignatures, stringIndexType, numberIndexType); - } - function resolveAnonymousTypeMembers(type) { - var symbol = type.symbol; - var members; - var callSignatures; - var constructSignatures; - var stringIndexType; - var numberIndexType; - if (symbol.flags & 2048 /* TypeLiteral */) { - members = symbol.members; - callSignatures = getSignaturesOfSymbol(members["__call"]); - constructSignatures = getSignaturesOfSymbol(members["__new"]); - stringIndexType = getIndexTypeOfSymbol(symbol, 0 /* String */); - numberIndexType = getIndexTypeOfSymbol(symbol, 1 /* Number */); - } - else { - // Combinations of function, class, enum and module - members = emptySymbols; - callSignatures = emptyArray; - constructSignatures = emptyArray; - if (symbol.flags & 1952 /* HasExports */) { - members = getExportsOfSymbol(symbol); - } - if (symbol.flags & (16 /* Function */ | 8192 /* Method */)) { - callSignatures = getSignaturesOfSymbol(symbol); - } - if (symbol.flags & 32 /* Class */) { - var classType = getDeclaredTypeOfClassOrInterface(symbol); - constructSignatures = getSignaturesOfSymbol(symbol.members["__constructor"]); - if (!constructSignatures.length) { - constructSignatures = getDefaultConstructSignatures(classType); - } - var baseTypes = getBaseTypes(classType); - if (baseTypes.length) { - members = createSymbolTable(getNamedMembers(members)); - addInheritedMembers(members, getPropertiesOfObjectType(getTypeOfSymbol(baseTypes[0].symbol))); - } - } - stringIndexType = undefined; - numberIndexType = (symbol.flags & 384 /* Enum */) ? stringType : undefined; - } - setObjectTypeMembers(type, members, callSignatures, constructSignatures, stringIndexType, numberIndexType); - } - function resolveObjectOrUnionTypeMembers(type) { - if (!type.members) { - if (type.flags & (1024 /* Class */ | 2048 /* Interface */)) { - resolveClassOrInterfaceMembers(type); - } - else if (type.flags & 32768 /* Anonymous */) { - resolveAnonymousTypeMembers(type); - } - else if (type.flags & 8192 /* Tuple */) { - resolveTupleTypeMembers(type); - } - else if (type.flags & 16384 /* Union */) { - resolveUnionTypeMembers(type); - } - else { - resolveTypeReferenceMembers(type); - } - } - return type; - } - // Return properties of an object type or an empty array for other types - function getPropertiesOfObjectType(type) { - if (type.flags & 48128 /* ObjectType */) { - return resolveObjectOrUnionTypeMembers(type).properties; - } - return emptyArray; - } - // If the given type is an object type and that type has a property by the given name, return - // the symbol for that property. Otherwise return undefined. - function getPropertyOfObjectType(type, name) { - if (type.flags & 48128 /* ObjectType */) { - var resolved = resolveObjectOrUnionTypeMembers(type); - if (ts.hasProperty(resolved.members, name)) { - var symbol = resolved.members[name]; - if (symbolIsValue(symbol)) { - return symbol; - } - } - } - } - function getPropertiesOfUnionType(type) { - var result = []; - ts.forEach(getPropertiesOfType(type.types[0]), function (prop) { - var unionProp = getPropertyOfUnionType(type, prop.name); - if (unionProp) { - result.push(unionProp); - } - }); - return result; - } - function getPropertiesOfType(type) { - type = getApparentType(type); - return type.flags & 16384 /* Union */ ? getPropertiesOfUnionType(type) : getPropertiesOfObjectType(type); - } - // For a type parameter, return the base constraint of the type parameter. For the string, number, - // boolean, and symbol primitive types, return the corresponding object types. Otherwise return the - // type itself. Note that the apparent type of a union type is the union type itself. - function getApparentType(type) { - if (type.flags & 16384 /* Union */) { - type = getReducedTypeOfUnionType(type); - } - if (type.flags & 512 /* TypeParameter */) { - do { - type = getConstraintOfTypeParameter(type); - } while (type && type.flags & 512 /* TypeParameter */); - if (!type) { - type = emptyObjectType; - } - } - if (type.flags & 258 /* StringLike */) { - type = globalStringType; - } - else if (type.flags & 132 /* NumberLike */) { - type = globalNumberType; - } - else if (type.flags & 8 /* Boolean */) { - type = globalBooleanType; - } - else if (type.flags & 2097152 /* ESSymbol */) { - type = globalESSymbolType; - } - return type; - } - function createUnionProperty(unionType, name) { - var types = unionType.types; - var props; - for (var _i = 0; _i < types.length; _i++) { - var current = types[_i]; - var type = getApparentType(current); - if (type !== unknownType) { - var prop = getPropertyOfType(type, name); - if (!prop || getDeclarationFlagsFromSymbol(prop) & (32 /* Private */ | 64 /* Protected */)) { - return undefined; - } - if (!props) { - props = [prop]; - } - else { - props.push(prop); - } - } - } - var propTypes = []; - var declarations = []; - for (var _a = 0; _a < props.length; _a++) { - var prop = props[_a]; - if (prop.declarations) { - declarations.push.apply(declarations, prop.declarations); - } - propTypes.push(getTypeOfSymbol(prop)); - } - var result = createSymbol(4 /* Property */ | 67108864 /* Transient */ | 268435456 /* UnionProperty */, name); - result.unionType = unionType; - result.declarations = declarations; - result.type = getUnionType(propTypes); - return result; - } - function getPropertyOfUnionType(type, name) { - var properties = type.resolvedProperties || (type.resolvedProperties = {}); - if (ts.hasProperty(properties, name)) { - return properties[name]; - } - var property = createUnionProperty(type, name); - if (property) { - properties[name] = property; - } - return property; - } - // Return the symbol for the property with the given name in the given type. Creates synthetic union properties when - // necessary, maps primitive types and type parameters are to their apparent types, and augments with properties from - // Object and Function as appropriate. - function getPropertyOfType(type, name) { - type = getApparentType(type); - if (type.flags & 48128 /* ObjectType */) { - var resolved = resolveObjectOrUnionTypeMembers(type); - if (ts.hasProperty(resolved.members, name)) { - var symbol = resolved.members[name]; - if (symbolIsValue(symbol)) { - return symbol; - } - } - if (resolved === anyFunctionType || resolved.callSignatures.length || resolved.constructSignatures.length) { - var symbol = getPropertyOfObjectType(globalFunctionType, name); - if (symbol) { - return symbol; - } - } - return getPropertyOfObjectType(globalObjectType, name); - } - if (type.flags & 16384 /* Union */) { - return getPropertyOfUnionType(type, name); - } - return undefined; - } - function getSignaturesOfObjectOrUnionType(type, kind) { - if (type.flags & (48128 /* ObjectType */ | 16384 /* Union */)) { - var resolved = resolveObjectOrUnionTypeMembers(type); - return kind === 0 /* Call */ ? resolved.callSignatures : resolved.constructSignatures; - } - return emptyArray; - } - // Return the signatures of the given kind in the given type. Creates synthetic union signatures when necessary and - // maps primitive types and type parameters are to their apparent types. - function getSignaturesOfType(type, kind) { - return getSignaturesOfObjectOrUnionType(getApparentType(type), kind); - } - function typeHasCallOrConstructSignatures(type) { - var apparentType = getApparentType(type); - if (apparentType.flags & (48128 /* ObjectType */ | 16384 /* Union */)) { - var resolved = resolveObjectOrUnionTypeMembers(type); - return resolved.callSignatures.length > 0 - || resolved.constructSignatures.length > 0; - } - return false; - } - function getIndexTypeOfObjectOrUnionType(type, kind) { - if (type.flags & (48128 /* ObjectType */ | 16384 /* Union */)) { - var resolved = resolveObjectOrUnionTypeMembers(type); - return kind === 0 /* String */ ? resolved.stringIndexType : resolved.numberIndexType; - } - } - // Return the index type of the given kind in the given type. Creates synthetic union index types when necessary and - // maps primitive types and type parameters are to their apparent types. - function getIndexTypeOfType(type, kind) { - return getIndexTypeOfObjectOrUnionType(getApparentType(type), kind); - } - // Return list of type parameters with duplicates removed (duplicate identifier errors are generated in the actual - // type checking functions). - function getTypeParametersFromDeclaration(typeParameterDeclarations) { - var result = []; - ts.forEach(typeParameterDeclarations, function (node) { - var tp = getDeclaredTypeOfTypeParameter(node.symbol); - if (!ts.contains(result, tp)) { - result.push(tp); - } - }); - return result; - } - function symbolsToArray(symbols) { - var result = []; - for (var id in symbols) { - if (!isReservedMemberName(id)) { - result.push(symbols[id]); - } - } - return result; - } - function isOptionalParameter(node) { - return ts.hasQuestionToken(node) || !!node.initializer; - } - function getSignatureFromDeclaration(declaration) { - var links = getNodeLinks(declaration); - if (!links.resolvedSignature) { - var classType = declaration.kind === 137 /* Constructor */ ? getDeclaredTypeOfClassOrInterface(declaration.parent.symbol) : undefined; - var typeParameters = classType ? classType.localTypeParameters : - declaration.typeParameters ? getTypeParametersFromDeclaration(declaration.typeParameters) : undefined; - var parameters = []; - var hasStringLiterals = false; - var minArgumentCount = -1; - for (var i = 0, n = declaration.parameters.length; i < n; i++) { - var param = declaration.parameters[i]; - parameters.push(param.symbol); - if (param.type && param.type.kind === 8 /* StringLiteral */) { - hasStringLiterals = true; - } - if (minArgumentCount < 0) { - if (param.initializer || param.questionToken || param.dotDotDotToken) { - minArgumentCount = i; - } - } - } - if (minArgumentCount < 0) { - minArgumentCount = declaration.parameters.length; - } - var returnType; - var typePredicate; - if (classType) { - returnType = classType; - } - else if (declaration.type) { - returnType = getTypeFromTypeNode(declaration.type); - if (declaration.type.kind === 143 /* TypePredicate */) { - var typePredicateNode = declaration.type; - typePredicate = { - parameterName: typePredicateNode.parameterName ? typePredicateNode.parameterName.text : undefined, - parameterIndex: typePredicateNode.parameterName ? getTypePredicateParameterIndex(declaration.parameters, typePredicateNode.parameterName) : undefined, - type: getTypeFromTypeNode(typePredicateNode.type) - }; - } - } - else { - // TypeScript 1.0 spec (April 2014): - // If only one accessor includes a type annotation, the other behaves as if it had the same type annotation. - if (declaration.kind === 138 /* GetAccessor */ && !ts.hasDynamicName(declaration)) { - var setter = ts.getDeclarationOfKind(declaration.symbol, 139 /* SetAccessor */); - returnType = getAnnotatedAccessorType(setter); - } - if (!returnType && ts.nodeIsMissing(declaration.body)) { - returnType = anyType; - } - } - links.resolvedSignature = createSignature(declaration, typeParameters, parameters, returnType, typePredicate, minArgumentCount, ts.hasRestParameter(declaration), hasStringLiterals); - } - return links.resolvedSignature; - } - function getSignaturesOfSymbol(symbol) { - if (!symbol) - return emptyArray; - var result = []; - for (var i = 0, len = symbol.declarations.length; i < len; i++) { - var node = symbol.declarations[i]; - switch (node.kind) { - case 145 /* FunctionType */: - case 146 /* ConstructorType */: - case 203 /* FunctionDeclaration */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 137 /* Constructor */: - case 140 /* CallSignature */: - case 141 /* ConstructSignature */: - case 142 /* IndexSignature */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 165 /* FunctionExpression */: - case 166 /* ArrowFunction */: - // Don't include signature if node is the implementation of an overloaded function. A node is considered - // an implementation node if it has a body and the previous node is of the same kind and immediately - // precedes the implementation node (i.e. has the same parent and ends where the implementation starts). - if (i > 0 && node.body) { - var previous = symbol.declarations[i - 1]; - if (node.parent === previous.parent && node.kind === previous.kind && node.pos === previous.end) { - break; - } - } - result.push(getSignatureFromDeclaration(node)); - } - } - return result; - } - function getReturnTypeOfSignature(signature) { - if (!signature.resolvedReturnType) { - if (!pushTypeResolution(signature)) { - return unknownType; - } - var type; - if (signature.target) { - type = instantiateType(getReturnTypeOfSignature(signature.target), signature.mapper); - } - else if (signature.unionSignatures) { - type = getUnionType(ts.map(signature.unionSignatures, getReturnTypeOfSignature)); - } - else { - type = getReturnTypeFromBody(signature.declaration); - } - if (!popTypeResolution()) { - type = anyType; - if (compilerOptions.noImplicitAny) { - var declaration = signature.declaration; - if (declaration.name) { - error(declaration.name, ts.Diagnostics._0_implicitly_has_return_type_any_because_it_does_not_have_a_return_type_annotation_and_is_referenced_directly_or_indirectly_in_one_of_its_return_expressions, ts.declarationNameToString(declaration.name)); - } - else { - error(declaration, ts.Diagnostics.Function_implicitly_has_return_type_any_because_it_does_not_have_a_return_type_annotation_and_is_referenced_directly_or_indirectly_in_one_of_its_return_expressions); - } - } - } - signature.resolvedReturnType = type; - } - return signature.resolvedReturnType; - } - function getRestTypeOfSignature(signature) { - if (signature.hasRestParameter) { - var type = getTypeOfSymbol(ts.lastOrUndefined(signature.parameters)); - if (type.flags & 4096 /* Reference */ && type.target === globalArrayType) { - return type.typeArguments[0]; - } - } - return anyType; - } - function getSignatureInstantiation(signature, typeArguments) { - return instantiateSignature(signature, createTypeMapper(signature.typeParameters, typeArguments), true); - } - function getErasedSignature(signature) { - if (!signature.typeParameters) - return signature; - if (!signature.erasedSignatureCache) { - if (signature.target) { - signature.erasedSignatureCache = instantiateSignature(getErasedSignature(signature.target), signature.mapper); - } - else { - signature.erasedSignatureCache = instantiateSignature(signature, createTypeEraser(signature.typeParameters), true); - } - } - return signature.erasedSignatureCache; - } - function getOrCreateTypeFromSignature(signature) { - // There are two ways to declare a construct signature, one is by declaring a class constructor - // using the constructor keyword, and the other is declaring a bare construct signature in an - // object type literal or interface (using the new keyword). Each way of declaring a constructor - // will result in a different declaration kind. - if (!signature.isolatedSignatureType) { - var isConstructor = signature.declaration.kind === 137 /* Constructor */ || signature.declaration.kind === 141 /* ConstructSignature */; - var type = createObjectType(32768 /* Anonymous */ | 131072 /* FromSignature */); - type.members = emptySymbols; - type.properties = emptyArray; - type.callSignatures = !isConstructor ? [signature] : emptyArray; - type.constructSignatures = isConstructor ? [signature] : emptyArray; - signature.isolatedSignatureType = type; - } - return signature.isolatedSignatureType; - } - function getIndexSymbol(symbol) { - return symbol.members["__index"]; - } - function getIndexDeclarationOfSymbol(symbol, kind) { - var syntaxKind = kind === 1 /* Number */ ? 121 /* NumberKeyword */ : 123 /* StringKeyword */; - var indexSymbol = getIndexSymbol(symbol); - if (indexSymbol) { - var len = indexSymbol.declarations.length; - for (var _i = 0, _a = indexSymbol.declarations; _i < _a.length; _i++) { - var decl = _a[_i]; - var node = decl; - if (node.parameters.length === 1) { - var parameter = node.parameters[0]; - if (parameter && parameter.type && parameter.type.kind === syntaxKind) { - return node; - } - } - } - } - return undefined; - } - function getIndexTypeOfSymbol(symbol, kind) { - var declaration = getIndexDeclarationOfSymbol(symbol, kind); - return declaration - ? declaration.type ? getTypeFromTypeNode(declaration.type) : anyType - : undefined; - } - function getConstraintOfTypeParameter(type) { - if (!type.constraint) { - if (type.target) { - var targetConstraint = getConstraintOfTypeParameter(type.target); - type.constraint = targetConstraint ? instantiateType(targetConstraint, type.mapper) : noConstraintType; - } - else { - type.constraint = getTypeFromTypeNode(ts.getDeclarationOfKind(type.symbol, 130 /* TypeParameter */).constraint); - } - } - return type.constraint === noConstraintType ? undefined : type.constraint; - } - function getParentSymbolOfTypeParameter(typeParameter) { - return getSymbolOfNode(ts.getDeclarationOfKind(typeParameter.symbol, 130 /* TypeParameter */).parent); - } - function getTypeListId(types) { - switch (types.length) { - case 1: - return "" + types[0].id; - case 2: - return types[0].id + "," + types[1].id; - default: - var result = ""; - for (var i = 0; i < types.length; i++) { - if (i > 0) { - result += ","; - } - result += types[i].id; - } - return result; - } - } - // This function is used to propagate widening flags when creating new object types references and union types. - // It is only necessary to do so if a constituent type might be the undefined type, the null type, or the type - // of an object literal (since those types have widening related information we need to track). - function getWideningFlagsOfTypes(types) { - var result = 0; - for (var _i = 0; _i < types.length; _i++) { - var type = types[_i]; - result |= type.flags; - } - return result & 1572864 /* RequiresWidening */; - } - function createTypeReference(target, typeArguments) { - var id = getTypeListId(typeArguments); - var type = target.instantiations[id]; - if (!type) { - var flags = 4096 /* Reference */ | getWideningFlagsOfTypes(typeArguments); - type = target.instantiations[id] = createObjectType(flags, target.symbol); - type.target = target; - type.typeArguments = typeArguments; - } - return type; - } - function isTypeParameterReferenceIllegalInConstraint(typeReferenceNode, typeParameterSymbol) { - var links = getNodeLinks(typeReferenceNode); - if (links.isIllegalTypeReferenceInConstraint !== undefined) { - return links.isIllegalTypeReferenceInConstraint; - } - // bubble up to the declaration - var currentNode = typeReferenceNode; - // forEach === exists - while (!ts.forEach(typeParameterSymbol.declarations, function (d) { return d.parent === currentNode.parent; })) { - currentNode = currentNode.parent; - } - // if last step was made from the type parameter this means that path has started somewhere in constraint which is illegal - links.isIllegalTypeReferenceInConstraint = currentNode.kind === 130 /* TypeParameter */; - return links.isIllegalTypeReferenceInConstraint; - } - function checkTypeParameterHasIllegalReferencesInConstraint(typeParameter) { - var typeParameterSymbol; - function check(n) { - if (n.kind === 144 /* TypeReference */ && n.typeName.kind === 65 /* Identifier */) { - var links = getNodeLinks(n); - if (links.isIllegalTypeReferenceInConstraint === undefined) { - var symbol = resolveName(typeParameter, n.typeName.text, 793056 /* Type */, undefined, undefined); - if (symbol && (symbol.flags & 262144 /* TypeParameter */)) { - // TypeScript 1.0 spec (April 2014): 3.4.1 - // Type parameters declared in a particular type parameter list - // may not be referenced in constraints in that type parameter list - // symbol.declaration.parent === typeParameter.parent - // -> typeParameter and symbol.declaration originate from the same type parameter list - // -> illegal for all declarations in symbol - // forEach === exists - links.isIllegalTypeReferenceInConstraint = ts.forEach(symbol.declarations, function (d) { return d.parent == typeParameter.parent; }); - } - } - if (links.isIllegalTypeReferenceInConstraint) { - error(typeParameter, ts.Diagnostics.Constraint_of_a_type_parameter_cannot_reference_any_type_parameter_from_the_same_type_parameter_list); - } - } - ts.forEachChild(n, check); - } - if (typeParameter.constraint) { - typeParameterSymbol = getSymbolOfNode(typeParameter); - check(typeParameter.constraint); - } - } - // Get type from reference to class or interface - function getTypeFromClassOrInterfaceReference(node, symbol) { - var type = getDeclaredTypeOfSymbol(symbol); - var typeParameters = type.localTypeParameters; - if (typeParameters) { - if (!node.typeArguments || node.typeArguments.length !== typeParameters.length) { - error(node, ts.Diagnostics.Generic_type_0_requires_1_type_argument_s, typeToString(type, undefined, 1 /* WriteArrayAsGenericType */), typeParameters.length); - return unknownType; - } - // In a type reference, the outer type parameters of the referenced class or interface are automatically - // supplied as type arguments and the type reference only specifies arguments for the local type parameters - // of the class or interface. - return createTypeReference(type, ts.concatenate(type.outerTypeParameters, ts.map(node.typeArguments, getTypeFromTypeNode))); - } - if (node.typeArguments) { - error(node, ts.Diagnostics.Type_0_is_not_generic, typeToString(type)); - return unknownType; - } - return type; - } - // Get type from reference to type alias. When a type alias is generic, the declared type of the type alias may include - // references to the type parameters of the alias. We replace those with the actual type arguments by instantiating the - // declared type. Instantiations are cached using the type identities of the type arguments as the key. - function getTypeFromTypeAliasReference(node, symbol) { - var type = getDeclaredTypeOfSymbol(symbol); - var links = getSymbolLinks(symbol); - var typeParameters = links.typeParameters; - if (typeParameters) { - if (!node.typeArguments || node.typeArguments.length !== typeParameters.length) { - error(node, ts.Diagnostics.Generic_type_0_requires_1_type_argument_s, symbolToString(symbol), typeParameters.length); - return unknownType; - } - var typeArguments = ts.map(node.typeArguments, getTypeFromTypeNode); - var id = getTypeListId(typeArguments); - return links.instantiations[id] || (links.instantiations[id] = instantiateType(type, createTypeMapper(typeParameters, typeArguments))); - } - if (node.typeArguments) { - error(node, ts.Diagnostics.Type_0_is_not_generic, symbolToString(symbol)); - return unknownType; - } - return type; - } - // Get type from reference to named type that cannot be generic (enum or type parameter) - function getTypeFromNonGenericTypeReference(node, symbol) { - if (symbol.flags & 262144 /* TypeParameter */ && isTypeParameterReferenceIllegalInConstraint(node, symbol)) { - // TypeScript 1.0 spec (April 2014): 3.4.1 - // Type parameters declared in a particular type parameter list - // may not be referenced in constraints in that type parameter list - // Implementation: such type references are resolved to 'unknown' type that usually denotes error - return unknownType; - } - if (node.typeArguments) { - error(node, ts.Diagnostics.Type_0_is_not_generic, symbolToString(symbol)); - return unknownType; - } - return getDeclaredTypeOfSymbol(symbol); - } - function getTypeFromTypeReference(node) { - var links = getNodeLinks(node); - if (!links.resolvedType) { - // We only support expressions that are simple qualified names. For other expressions this produces undefined. - var typeNameOrExpression = node.kind === 144 /* TypeReference */ ? node.typeName : - ts.isSupportedExpressionWithTypeArguments(node) ? node.expression : - undefined; - var symbol = typeNameOrExpression && resolveEntityName(typeNameOrExpression, 793056 /* Type */) || unknownSymbol; - var type = symbol === unknownSymbol ? unknownType : - symbol.flags & (32 /* Class */ | 64 /* Interface */) ? getTypeFromClassOrInterfaceReference(node, symbol) : - symbol.flags & 524288 /* TypeAlias */ ? getTypeFromTypeAliasReference(node, symbol) : - getTypeFromNonGenericTypeReference(node, symbol); - // Cache both the resolved symbol and the resolved type. The resolved symbol is needed in when we check the - // type reference in checkTypeReferenceOrExpressionWithTypeArguments. - links.resolvedSymbol = symbol; - links.resolvedType = type; - } - return links.resolvedType; - } - function getTypeFromTypeQueryNode(node) { - var links = getNodeLinks(node); - if (!links.resolvedType) { - // TypeScript 1.0 spec (April 2014): 3.6.3 - // The expression is processed as an identifier expression (section 4.3) - // or property access expression(section 4.10), - // the widened type(section 3.9) of which becomes the result. - links.resolvedType = getWidenedType(checkExpressionOrQualifiedName(node.exprName)); - } - return links.resolvedType; - } - function getTypeOfGlobalSymbol(symbol, arity) { - function getTypeDeclaration(symbol) { - var declarations = symbol.declarations; - for (var _i = 0; _i < declarations.length; _i++) { - var declaration = declarations[_i]; - switch (declaration.kind) { - case 204 /* ClassDeclaration */: - case 205 /* InterfaceDeclaration */: - case 207 /* EnumDeclaration */: - return declaration; - } - } - } - if (!symbol) { - return arity ? emptyGenericType : emptyObjectType; - } - var type = getDeclaredTypeOfSymbol(symbol); - if (!(type.flags & 48128 /* ObjectType */)) { - error(getTypeDeclaration(symbol), ts.Diagnostics.Global_type_0_must_be_a_class_or_interface_type, symbol.name); - return arity ? emptyGenericType : emptyObjectType; - } - if ((type.typeParameters ? type.typeParameters.length : 0) !== arity) { - error(getTypeDeclaration(symbol), ts.Diagnostics.Global_type_0_must_have_1_type_parameter_s, symbol.name, arity); - return arity ? emptyGenericType : emptyObjectType; - } - return type; - } - function getGlobalValueSymbol(name) { - return getGlobalSymbol(name, 107455 /* Value */, ts.Diagnostics.Cannot_find_global_value_0); - } - function getGlobalTypeSymbol(name) { - return getGlobalSymbol(name, 793056 /* Type */, ts.Diagnostics.Cannot_find_global_type_0); - } - function getGlobalSymbol(name, meaning, diagnostic) { - return resolveName(undefined, name, meaning, diagnostic, name); - } - function getGlobalType(name, arity) { - if (arity === void 0) { arity = 0; } - return getTypeOfGlobalSymbol(getGlobalTypeSymbol(name), arity); - } - function getGlobalESSymbolConstructorSymbol() { - return globalESSymbolConstructorSymbol || (globalESSymbolConstructorSymbol = getGlobalValueSymbol("Symbol")); - } - /** - * Instantiates a global type that is generic with some element type, and returns that instantiation. - */ - function createTypeFromGenericGlobalType(genericGlobalType, elementType) { - return genericGlobalType !== emptyGenericType ? createTypeReference(genericGlobalType, [elementType]) : emptyObjectType; - } - function createIterableType(elementType) { - return createTypeFromGenericGlobalType(globalIterableType, elementType); - } - function createIterableIteratorType(elementType) { - return createTypeFromGenericGlobalType(globalIterableIteratorType, elementType); - } - function createArrayType(elementType) { - return createTypeFromGenericGlobalType(globalArrayType, elementType); - } - function getTypeFromArrayTypeNode(node) { - var links = getNodeLinks(node); - if (!links.resolvedType) { - links.resolvedType = createArrayType(getTypeFromTypeNode(node.elementType)); - } - return links.resolvedType; - } - function createTupleType(elementTypes) { - var id = getTypeListId(elementTypes); - var type = tupleTypes[id]; - if (!type) { - type = tupleTypes[id] = createObjectType(8192 /* Tuple */); - type.elementTypes = elementTypes; - } - return type; - } - function getTypeFromTupleTypeNode(node) { - var links = getNodeLinks(node); - if (!links.resolvedType) { - links.resolvedType = createTupleType(ts.map(node.elementTypes, getTypeFromTypeNode)); - } - return links.resolvedType; - } - function addTypeToSortedSet(sortedSet, type) { - if (type.flags & 16384 /* Union */) { - addTypesToSortedSet(sortedSet, type.types); - } - else { - var i = 0; - var id = type.id; - while (i < sortedSet.length && sortedSet[i].id < id) { - i++; - } - if (i === sortedSet.length || sortedSet[i].id !== id) { - sortedSet.splice(i, 0, type); - } - } - } - function addTypesToSortedSet(sortedTypes, types) { - for (var _i = 0; _i < types.length; _i++) { - var type = types[_i]; - addTypeToSortedSet(sortedTypes, type); - } - } - function isSubtypeOfAny(candidate, types) { - for (var _i = 0; _i < types.length; _i++) { - var type = types[_i]; - if (candidate !== type && isTypeSubtypeOf(candidate, type)) { - return true; - } - } - return false; - } - function removeSubtypes(types) { - var i = types.length; - while (i > 0) { - i--; - if (isSubtypeOfAny(types[i], types)) { - types.splice(i, 1); - } - } - } - function containsTypeAny(types) { - for (var _i = 0; _i < types.length; _i++) { - var type = types[_i]; - if (isTypeAny(type)) { - return true; - } - } - return false; - } - function removeAllButLast(types, typeToRemove) { - var i = types.length; - while (i > 0 && types.length > 1) { - i--; - if (types[i] === typeToRemove) { - types.splice(i, 1); - } - } - } - // The noSubtypeReduction flag is there because it isn't possible to always do subtype reduction. The flag - // is true when creating a union type from a type node and when instantiating a union type. In both of those - // cases subtype reduction has to be deferred to properly support recursive union types. For example, a - // type alias of the form "type Item = string | (() => Item)" cannot be reduced during its declaration. - function getUnionType(types, noSubtypeReduction) { - if (types.length === 0) { - return emptyObjectType; - } - var sortedTypes = []; - addTypesToSortedSet(sortedTypes, types); - if (noSubtypeReduction) { - if (containsTypeAny(sortedTypes)) { - return anyType; - } - removeAllButLast(sortedTypes, undefinedType); - removeAllButLast(sortedTypes, nullType); - } - else { - removeSubtypes(sortedTypes); - } - if (sortedTypes.length === 1) { - return sortedTypes[0]; - } - var id = getTypeListId(sortedTypes); - var type = unionTypes[id]; - if (!type) { - type = unionTypes[id] = createObjectType(16384 /* Union */ | getWideningFlagsOfTypes(sortedTypes)); - type.types = sortedTypes; - type.reducedType = noSubtypeReduction ? undefined : type; - } - return type; - } - // Subtype reduction is basically an optimization we do to avoid excessively large union types, which take longer - // to process and look strange in quick info and error messages. Semantically there is no difference between the - // reduced type and the type itself. So, when we detect a circularity we simply say that the reduced type is the - // type itself. - function getReducedTypeOfUnionType(type) { - if (!type.reducedType) { - type.reducedType = circularType; - var reducedType = getUnionType(type.types, false); - if (type.reducedType === circularType) { - type.reducedType = reducedType; - } - } - else if (type.reducedType === circularType) { - type.reducedType = type; - } - return type.reducedType; - } - function getTypeFromUnionTypeNode(node) { - var links = getNodeLinks(node); - if (!links.resolvedType) { - links.resolvedType = getUnionType(ts.map(node.types, getTypeFromTypeNode), true); - } - return links.resolvedType; - } - function getTypeFromTypeLiteralOrFunctionOrConstructorTypeNode(node) { - var links = getNodeLinks(node); - if (!links.resolvedType) { - // Deferred resolution of members is handled by resolveObjectTypeMembers - links.resolvedType = createObjectType(32768 /* Anonymous */, node.symbol); - } - return links.resolvedType; - } - function getStringLiteralType(node) { - if (ts.hasProperty(stringLiteralTypes, node.text)) { - return stringLiteralTypes[node.text]; - } - var type = stringLiteralTypes[node.text] = createType(256 /* StringLiteral */); - type.text = ts.getTextOfNode(node); - return type; - } - function getTypeFromStringLiteral(node) { - var links = getNodeLinks(node); - if (!links.resolvedType) { - links.resolvedType = getStringLiteralType(node); - } - return links.resolvedType; - } - function getTypeFromTypeNode(node) { - switch (node.kind) { - case 112 /* AnyKeyword */: - return anyType; - case 123 /* StringKeyword */: - return stringType; - case 121 /* NumberKeyword */: - return numberType; - case 113 /* BooleanKeyword */: - return booleanType; - case 124 /* SymbolKeyword */: - return esSymbolType; - case 99 /* VoidKeyword */: - return voidType; - case 8 /* StringLiteral */: - return getTypeFromStringLiteral(node); - case 144 /* TypeReference */: - return getTypeFromTypeReference(node); - case 143 /* TypePredicate */: - return booleanType; - case 179 /* ExpressionWithTypeArguments */: - return getTypeFromTypeReference(node); - case 147 /* TypeQuery */: - return getTypeFromTypeQueryNode(node); - case 149 /* ArrayType */: - return getTypeFromArrayTypeNode(node); - case 150 /* TupleType */: - return getTypeFromTupleTypeNode(node); - case 151 /* UnionType */: - return getTypeFromUnionTypeNode(node); - case 152 /* ParenthesizedType */: - return getTypeFromTypeNode(node.type); - case 145 /* FunctionType */: - case 146 /* ConstructorType */: - case 148 /* TypeLiteral */: - return getTypeFromTypeLiteralOrFunctionOrConstructorTypeNode(node); - // This function assumes that an identifier or qualified name is a type expression - // Callers should first ensure this by calling isTypeNode - case 65 /* Identifier */: - case 128 /* QualifiedName */: - var symbol = getSymbolInfo(node); - return symbol && getDeclaredTypeOfSymbol(symbol); - default: - return unknownType; - } - } - function instantiateList(items, mapper, instantiator) { - if (items && items.length) { - var result = []; - for (var _i = 0; _i < items.length; _i++) { - var v = items[_i]; - result.push(instantiator(v, mapper)); - } - return result; - } - return items; - } - function createUnaryTypeMapper(source, target) { - return function (t) { return t === source ? target : t; }; - } - function createBinaryTypeMapper(source1, target1, source2, target2) { - return function (t) { return t === source1 ? target1 : t === source2 ? target2 : t; }; - } - function createTypeMapper(sources, targets) { - switch (sources.length) { - case 1: return createUnaryTypeMapper(sources[0], targets[0]); - case 2: return createBinaryTypeMapper(sources[0], targets[0], sources[1], targets[1]); - } - return function (t) { - for (var i = 0; i < sources.length; i++) { - if (t === sources[i]) { - return targets[i]; - } - } - return t; - }; - } - function createUnaryTypeEraser(source) { - return function (t) { return t === source ? anyType : t; }; - } - function createBinaryTypeEraser(source1, source2) { - return function (t) { return t === source1 || t === source2 ? anyType : t; }; - } - function createTypeEraser(sources) { - switch (sources.length) { - case 1: return createUnaryTypeEraser(sources[0]); - case 2: return createBinaryTypeEraser(sources[0], sources[1]); - } - return function (t) { - for (var _i = 0; _i < sources.length; _i++) { - var source = sources[_i]; - if (t === source) { - return anyType; - } - } - return t; - }; - } - function createInferenceMapper(context) { - return function (t) { - for (var i = 0; i < context.typeParameters.length; i++) { - if (t === context.typeParameters[i]) { - context.inferences[i].isFixed = true; - return getInferredType(context, i); - } - } - return t; - }; - } - function identityMapper(type) { - return type; - } - function combineTypeMappers(mapper1, mapper2) { - return function (t) { return instantiateType(mapper1(t), mapper2); }; - } - function instantiateTypeParameter(typeParameter, mapper) { - var result = createType(512 /* TypeParameter */); - result.symbol = typeParameter.symbol; - if (typeParameter.constraint) { - result.constraint = instantiateType(typeParameter.constraint, mapper); - } - else { - result.target = typeParameter; - result.mapper = mapper; - } - return result; - } - function instantiateSignature(signature, mapper, eraseTypeParameters) { - var freshTypeParameters; - var freshTypePredicate; - if (signature.typeParameters && !eraseTypeParameters) { - freshTypeParameters = instantiateList(signature.typeParameters, mapper, instantiateTypeParameter); - mapper = combineTypeMappers(createTypeMapper(signature.typeParameters, freshTypeParameters), mapper); - } - if (signature.typePredicate) { - freshTypePredicate = { - parameterName: signature.typePredicate.parameterName, - parameterIndex: signature.typePredicate.parameterIndex, - type: instantiateType(signature.typePredicate.type, mapper) - }; - } - var result = createSignature(signature.declaration, freshTypeParameters, instantiateList(signature.parameters, mapper, instantiateSymbol), signature.resolvedReturnType ? instantiateType(signature.resolvedReturnType, mapper) : undefined, freshTypePredicate, signature.minArgumentCount, signature.hasRestParameter, signature.hasStringLiterals); - result.target = signature; - result.mapper = mapper; - return result; - } - function instantiateSymbol(symbol, mapper) { - if (symbol.flags & 16777216 /* Instantiated */) { - var links = getSymbolLinks(symbol); - // If symbol being instantiated is itself a instantiation, fetch the original target and combine the - // type mappers. This ensures that original type identities are properly preserved and that aliases - // always reference a non-aliases. - symbol = links.target; - mapper = combineTypeMappers(links.mapper, mapper); - } - // Keep the flags from the symbol we're instantiating. Mark that is instantiated, and - // also transient so that we can just store data on it directly. - var result = createSymbol(16777216 /* Instantiated */ | 67108864 /* Transient */ | symbol.flags, symbol.name); - result.declarations = symbol.declarations; - result.parent = symbol.parent; - result.target = symbol; - result.mapper = mapper; - if (symbol.valueDeclaration) { - result.valueDeclaration = symbol.valueDeclaration; - } - return result; - } - function instantiateAnonymousType(type, mapper) { - // Mark the anonymous type as instantiated such that our infinite instantiation detection logic can recognize it - var result = createObjectType(32768 /* Anonymous */ | 65536 /* Instantiated */, type.symbol); - result.properties = instantiateList(getPropertiesOfObjectType(type), mapper, instantiateSymbol); - result.members = createSymbolTable(result.properties); - result.callSignatures = instantiateList(getSignaturesOfType(type, 0 /* Call */), mapper, instantiateSignature); - result.constructSignatures = instantiateList(getSignaturesOfType(type, 1 /* Construct */), mapper, instantiateSignature); - var stringIndexType = getIndexTypeOfType(type, 0 /* String */); - var numberIndexType = getIndexTypeOfType(type, 1 /* Number */); - if (stringIndexType) - result.stringIndexType = instantiateType(stringIndexType, mapper); - if (numberIndexType) - result.numberIndexType = instantiateType(numberIndexType, mapper); - return result; - } - function instantiateType(type, mapper) { - if (mapper !== identityMapper) { - if (type.flags & 512 /* TypeParameter */) { - return mapper(type); - } - if (type.flags & 32768 /* Anonymous */) { - return type.symbol && type.symbol.flags & (16 /* Function */ | 8192 /* Method */ | 32 /* Class */ | 2048 /* TypeLiteral */ | 4096 /* ObjectLiteral */) ? - instantiateAnonymousType(type, mapper) : type; - } - if (type.flags & 4096 /* Reference */) { - return createTypeReference(type.target, instantiateList(type.typeArguments, mapper, instantiateType)); - } - if (type.flags & 8192 /* Tuple */) { - return createTupleType(instantiateList(type.elementTypes, mapper, instantiateType)); - } - if (type.flags & 16384 /* Union */) { - return getUnionType(instantiateList(type.types, mapper, instantiateType), true); - } - } - return type; - } - // Returns true if the given expression contains (at any level of nesting) a function or arrow expression - // that is subject to contextual typing. - function isContextSensitive(node) { - ts.Debug.assert(node.kind !== 136 /* MethodDeclaration */ || ts.isObjectLiteralMethod(node)); - switch (node.kind) { - case 165 /* FunctionExpression */: - case 166 /* ArrowFunction */: - return isContextSensitiveFunctionLikeDeclaration(node); - case 157 /* ObjectLiteralExpression */: - return ts.forEach(node.properties, isContextSensitive); - case 156 /* ArrayLiteralExpression */: - return ts.forEach(node.elements, isContextSensitive); - case 173 /* ConditionalExpression */: - return isContextSensitive(node.whenTrue) || - isContextSensitive(node.whenFalse); - case 172 /* BinaryExpression */: - return node.operatorToken.kind === 49 /* BarBarToken */ && - (isContextSensitive(node.left) || isContextSensitive(node.right)); - case 227 /* PropertyAssignment */: - return isContextSensitive(node.initializer); - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - return isContextSensitiveFunctionLikeDeclaration(node); - case 164 /* ParenthesizedExpression */: - return isContextSensitive(node.expression); - } - return false; - } - function isContextSensitiveFunctionLikeDeclaration(node) { - return !node.typeParameters && node.parameters.length && !ts.forEach(node.parameters, function (p) { return p.type; }); - } - function getTypeWithoutConstructors(type) { - if (type.flags & 48128 /* ObjectType */) { - var resolved = resolveObjectOrUnionTypeMembers(type); - if (resolved.constructSignatures.length) { - var result = createObjectType(32768 /* Anonymous */, type.symbol); - result.members = resolved.members; - result.properties = resolved.properties; - result.callSignatures = resolved.callSignatures; - result.constructSignatures = emptyArray; - type = result; - } - } - return type; - } - // TYPE CHECKING - var subtypeRelation = {}; - var assignableRelation = {}; - var identityRelation = {}; - function isTypeIdenticalTo(source, target) { - return checkTypeRelatedTo(source, target, identityRelation, undefined); - } - function compareTypes(source, target) { - return checkTypeRelatedTo(source, target, identityRelation, undefined) ? -1 /* True */ : 0 /* False */; - } - function isTypeSubtypeOf(source, target) { - return checkTypeSubtypeOf(source, target, undefined); - } - function isTypeAssignableTo(source, target) { - return checkTypeAssignableTo(source, target, undefined); - } - function checkTypeSubtypeOf(source, target, errorNode, headMessage, containingMessageChain) { - return checkTypeRelatedTo(source, target, subtypeRelation, errorNode, headMessage, containingMessageChain); - } - function checkTypeAssignableTo(source, target, errorNode, headMessage) { - return checkTypeRelatedTo(source, target, assignableRelation, errorNode, headMessage); - } - function isSignatureAssignableTo(source, target) { - var sourceType = getOrCreateTypeFromSignature(source); - var targetType = getOrCreateTypeFromSignature(target); - return checkTypeRelatedTo(sourceType, targetType, assignableRelation, undefined); - } - function checkTypeRelatedTo(source, target, relation, errorNode, headMessage, containingMessageChain) { - var errorInfo; - var sourceStack; - var targetStack; - var maybeStack; - var expandingFlags; - var depth = 0; - var overflow = false; - var elaborateErrors = false; - ts.Debug.assert(relation !== identityRelation || !errorNode, "no error reporting in identity checking"); - var result = isRelatedTo(source, target, errorNode !== undefined, headMessage); - if (overflow) { - error(errorNode, ts.Diagnostics.Excessive_stack_depth_comparing_types_0_and_1, typeToString(source), typeToString(target)); - } - else if (errorInfo) { - // If we already computed this relation, but in a context where we didn't want to report errors (e.g. overload resolution), - // then we'll only have a top-level error (e.g. 'Class X does not implement interface Y') without any details. If this happened, - // request a recompuation to get a complete error message. This will be skipped if we've already done this computation in a context - // where errors were being reported. - if (errorInfo.next === undefined) { - errorInfo = undefined; - elaborateErrors = true; - isRelatedTo(source, target, errorNode !== undefined, headMessage); - } - if (containingMessageChain) { - errorInfo = ts.concatenateDiagnosticMessageChains(containingMessageChain, errorInfo); - } - diagnostics.add(ts.createDiagnosticForNodeFromMessageChain(errorNode, errorInfo)); - } - return result !== 0 /* False */; - function reportError(message, arg0, arg1, arg2) { - errorInfo = ts.chainDiagnosticMessages(errorInfo, message, arg0, arg1, arg2); - } - // Compare two types and return - // Ternary.True if they are related with no assumptions, - // Ternary.Maybe if they are related with assumptions of other relationships, or - // Ternary.False if they are not related. - function isRelatedTo(source, target, reportErrors, headMessage) { - var result; - // both types are the same - covers 'they are the same primitive type or both are Any' or the same type parameter cases - if (source === target) - return -1 /* True */; - if (relation !== identityRelation) { - if (isTypeAny(target)) - return -1 /* True */; - if (source === undefinedType) - return -1 /* True */; - if (source === nullType && target !== undefinedType) - return -1 /* True */; - if (source.flags & 128 /* Enum */ && target === numberType) - return -1 /* True */; - if (source.flags & 256 /* StringLiteral */ && target === stringType) - return -1 /* True */; - if (relation === assignableRelation) { - if (isTypeAny(source)) - return -1 /* True */; - if (source === numberType && target.flags & 128 /* Enum */) - return -1 /* True */; - } - } - var saveErrorInfo = errorInfo; - if (source.flags & 16384 /* Union */ || target.flags & 16384 /* Union */) { - if (relation === identityRelation) { - if (source.flags & 16384 /* Union */ && target.flags & 16384 /* Union */) { - if (result = unionTypeRelatedToUnionType(source, target)) { - if (result &= unionTypeRelatedToUnionType(target, source)) { - return result; - } - } - } - else if (source.flags & 16384 /* Union */) { - if (result = unionTypeRelatedToType(source, target, reportErrors)) { - return result; - } - } - else { - if (result = unionTypeRelatedToType(target, source, reportErrors)) { - return result; - } - } - } - else { - if (source.flags & 16384 /* Union */) { - if (result = unionTypeRelatedToType(source, target, reportErrors)) { - return result; - } - } - else { - if (result = typeRelatedToUnionType(source, target, reportErrors)) { - return result; - } - } - } - } - else if (source.flags & 512 /* TypeParameter */ && target.flags & 512 /* TypeParameter */) { - if (result = typeParameterRelatedTo(source, target, reportErrors)) { - return result; - } - } - else if (source.flags & 4096 /* Reference */ && target.flags & 4096 /* Reference */ && source.target === target.target) { - // We have type references to same target type, see if relationship holds for all type arguments - if (result = typesRelatedTo(source.typeArguments, target.typeArguments, reportErrors)) { - return result; - } - } - // Even if relationship doesn't hold for unions, type parameters, or generic type references, - // it may hold in a structural comparison. - // Report structural errors only if we haven't reported any errors yet - var reportStructuralErrors = reportErrors && errorInfo === saveErrorInfo; - // identity relation does not use apparent type - var sourceOrApparentType = relation === identityRelation ? source : getApparentType(source); - if (sourceOrApparentType.flags & 48128 /* ObjectType */ && target.flags & 48128 /* ObjectType */) { - if (result = objectTypeRelatedTo(sourceOrApparentType, target, reportStructuralErrors)) { - errorInfo = saveErrorInfo; - return result; - } - } - else if (source.flags & 512 /* TypeParameter */ && sourceOrApparentType.flags & 16384 /* Union */) { - // We clear the errors first because the following check often gives a better error than - // the union comparison above if it is applicable. - errorInfo = saveErrorInfo; - if (result = isRelatedTo(sourceOrApparentType, target, reportErrors)) { - return result; - } - } - if (reportErrors) { - headMessage = headMessage || ts.Diagnostics.Type_0_is_not_assignable_to_type_1; - var sourceType = typeToString(source); - var targetType = typeToString(target); - if (sourceType === targetType) { - sourceType = typeToString(source, undefined, 128 /* UseFullyQualifiedType */); - targetType = typeToString(target, undefined, 128 /* UseFullyQualifiedType */); - } - reportError(headMessage, sourceType, targetType); - } - return 0 /* False */; - } - function unionTypeRelatedToUnionType(source, target) { - var result = -1 /* True */; - var sourceTypes = source.types; - for (var _i = 0; _i < sourceTypes.length; _i++) { - var sourceType = sourceTypes[_i]; - var related = typeRelatedToUnionType(sourceType, target, false); - if (!related) { - return 0 /* False */; - } - result &= related; - } - return result; - } - function typeRelatedToUnionType(source, target, reportErrors) { - var targetTypes = target.types; - for (var i = 0, len = targetTypes.length; i < len; i++) { - var related = isRelatedTo(source, targetTypes[i], reportErrors && i === len - 1); - if (related) { - return related; - } - } - return 0 /* False */; - } - function unionTypeRelatedToType(source, target, reportErrors) { - var result = -1 /* True */; - var sourceTypes = source.types; - for (var _i = 0; _i < sourceTypes.length; _i++) { - var sourceType = sourceTypes[_i]; - var related = isRelatedTo(sourceType, target, reportErrors); - if (!related) { - return 0 /* False */; - } - result &= related; - } - return result; - } - function typesRelatedTo(sources, targets, reportErrors) { - var result = -1 /* True */; - for (var i = 0, len = sources.length; i < len; i++) { - var related = isRelatedTo(sources[i], targets[i], reportErrors); - if (!related) { - return 0 /* False */; - } - result &= related; - } - return result; - } - function typeParameterRelatedTo(source, target, reportErrors) { - if (relation === identityRelation) { - if (source.symbol.name !== target.symbol.name) { - return 0 /* False */; - } - // covers case when both type parameters does not have constraint (both equal to noConstraintType) - if (source.constraint === target.constraint) { - return -1 /* True */; - } - if (source.constraint === noConstraintType || target.constraint === noConstraintType) { - return 0 /* False */; - } - return isRelatedTo(source.constraint, target.constraint, reportErrors); - } - else { - while (true) { - var constraint = getConstraintOfTypeParameter(source); - if (constraint === target) - return -1 /* True */; - if (!(constraint && constraint.flags & 512 /* TypeParameter */)) - break; - source = constraint; - } - return 0 /* False */; - } - } - // Determine if two object types are related by structure. First, check if the result is already available in the global cache. - // Second, check if we have already started a comparison of the given two types in which case we assume the result to be true. - // Third, check if both types are part of deeply nested chains of generic type instantiations and if so assume the types are - // equal and infinitely expanding. Fourth, if we have reached a depth of 100 nested comparisons, assume we have runaway recursion - // and issue an error. Otherwise, actually compare the structure of the two types. - function objectTypeRelatedTo(source, target, reportErrors) { - if (overflow) { - return 0 /* False */; - } - var id = relation !== identityRelation || source.id < target.id ? source.id + "," + target.id : target.id + "," + source.id; - var related = relation[id]; - //let related: RelationComparisonResult = undefined; // relation[id]; - if (related !== undefined) { - // If we computed this relation already and it was failed and reported, or if we're not being asked to elaborate - // errors, we can use the cached value. Otherwise, recompute the relation - if (!elaborateErrors || (related === 3 /* FailedAndReported */)) { - return related === 1 /* Succeeded */ ? -1 /* True */ : 0 /* False */; - } - } - if (depth > 0) { - for (var i = 0; i < depth; i++) { - // If source and target are already being compared, consider them related with assumptions - if (maybeStack[i][id]) { - return 1 /* Maybe */; - } - } - if (depth === 100) { - overflow = true; - return 0 /* False */; - } - } - else { - sourceStack = []; - targetStack = []; - maybeStack = []; - expandingFlags = 0; - } - sourceStack[depth] = source; - targetStack[depth] = target; - maybeStack[depth] = {}; - maybeStack[depth][id] = 1 /* Succeeded */; - depth++; - var saveExpandingFlags = expandingFlags; - if (!(expandingFlags & 1) && isDeeplyNestedGeneric(source, sourceStack, depth)) - expandingFlags |= 1; - if (!(expandingFlags & 2) && isDeeplyNestedGeneric(target, targetStack, depth)) - expandingFlags |= 2; - var result; - if (expandingFlags === 3) { - result = 1 /* Maybe */; - } - else { - result = propertiesRelatedTo(source, target, reportErrors); - if (result) { - result &= signaturesRelatedTo(source, target, 0 /* Call */, reportErrors); - if (result) { - result &= signaturesRelatedTo(source, target, 1 /* Construct */, reportErrors); - if (result) { - result &= stringIndexTypesRelatedTo(source, target, reportErrors); - if (result) { - result &= numberIndexTypesRelatedTo(source, target, reportErrors); - } - } - } - } - } - expandingFlags = saveExpandingFlags; - depth--; - if (result) { - var maybeCache = maybeStack[depth]; - // If result is definitely true, copy assumptions to global cache, else copy to next level up - var destinationCache = (result === -1 /* True */ || depth === 0) ? relation : maybeStack[depth - 1]; - ts.copyMap(maybeCache, destinationCache); - } - else { - // A false result goes straight into global cache (when something is false under assumptions it - // will also be false without assumptions) - relation[id] = reportErrors ? 3 /* FailedAndReported */ : 2 /* Failed */; - } - return result; - } - function propertiesRelatedTo(source, target, reportErrors) { - if (relation === identityRelation) { - return propertiesIdenticalTo(source, target); - } - var result = -1 /* True */; - var properties = getPropertiesOfObjectType(target); - var requireOptionalProperties = relation === subtypeRelation && !(source.flags & 262144 /* ObjectLiteral */); - for (var _i = 0; _i < properties.length; _i++) { - var targetProp = properties[_i]; - var sourceProp = getPropertyOfType(source, targetProp.name); - if (sourceProp !== targetProp) { - if (!sourceProp) { - if (!(targetProp.flags & 536870912 /* Optional */) || requireOptionalProperties) { - if (reportErrors) { - reportError(ts.Diagnostics.Property_0_is_missing_in_type_1, symbolToString(targetProp), typeToString(source)); - } - return 0 /* False */; - } - } - else if (!(targetProp.flags & 134217728 /* Prototype */)) { - var sourceFlags = getDeclarationFlagsFromSymbol(sourceProp); - var targetFlags = getDeclarationFlagsFromSymbol(targetProp); - if (sourceFlags & 32 /* Private */ || targetFlags & 32 /* Private */) { - if (sourceProp.valueDeclaration !== targetProp.valueDeclaration) { - if (reportErrors) { - if (sourceFlags & 32 /* Private */ && targetFlags & 32 /* Private */) { - reportError(ts.Diagnostics.Types_have_separate_declarations_of_a_private_property_0, symbolToString(targetProp)); - } - else { - reportError(ts.Diagnostics.Property_0_is_private_in_type_1_but_not_in_type_2, symbolToString(targetProp), typeToString(sourceFlags & 32 /* Private */ ? source : target), typeToString(sourceFlags & 32 /* Private */ ? target : source)); - } - } - return 0 /* False */; - } - } - else if (targetFlags & 64 /* Protected */) { - var sourceDeclaredInClass = sourceProp.parent && sourceProp.parent.flags & 32 /* Class */; - var sourceClass = sourceDeclaredInClass ? getDeclaredTypeOfSymbol(sourceProp.parent) : undefined; - var targetClass = getDeclaredTypeOfSymbol(targetProp.parent); - if (!sourceClass || !hasBaseType(sourceClass, targetClass)) { - if (reportErrors) { - reportError(ts.Diagnostics.Property_0_is_protected_but_type_1_is_not_a_class_derived_from_2, symbolToString(targetProp), typeToString(sourceClass || source), typeToString(targetClass)); - } - return 0 /* False */; - } - } - else if (sourceFlags & 64 /* Protected */) { - if (reportErrors) { - reportError(ts.Diagnostics.Property_0_is_protected_in_type_1_but_public_in_type_2, symbolToString(targetProp), typeToString(source), typeToString(target)); - } - return 0 /* False */; - } - var related = isRelatedTo(getTypeOfSymbol(sourceProp), getTypeOfSymbol(targetProp), reportErrors); - if (!related) { - if (reportErrors) { - reportError(ts.Diagnostics.Types_of_property_0_are_incompatible, symbolToString(targetProp)); - } - return 0 /* False */; - } - result &= related; - if (sourceProp.flags & 536870912 /* Optional */ && !(targetProp.flags & 536870912 /* Optional */)) { - // TypeScript 1.0 spec (April 2014): 3.8.3 - // S is a subtype of a type T, and T is a supertype of S if ... - // S' and T are object types and, for each member M in T.. - // M is a property and S' contains a property N where - // if M is a required property, N is also a required property - // (M - property in T) - // (N - property in S) - if (reportErrors) { - reportError(ts.Diagnostics.Property_0_is_optional_in_type_1_but_required_in_type_2, symbolToString(targetProp), typeToString(source), typeToString(target)); - } - return 0 /* False */; - } - } - } - } - return result; - } - function propertiesIdenticalTo(source, target) { - var sourceProperties = getPropertiesOfObjectType(source); - var targetProperties = getPropertiesOfObjectType(target); - if (sourceProperties.length !== targetProperties.length) { - return 0 /* False */; - } - var result = -1 /* True */; - for (var _i = 0; _i < sourceProperties.length; _i++) { - var sourceProp = sourceProperties[_i]; - var targetProp = getPropertyOfObjectType(target, sourceProp.name); - if (!targetProp) { - return 0 /* False */; - } - var related = compareProperties(sourceProp, targetProp, isRelatedTo); - if (!related) { - return 0 /* False */; - } - result &= related; - } - return result; - } - function signaturesRelatedTo(source, target, kind, reportErrors) { - if (relation === identityRelation) { - return signaturesIdenticalTo(source, target, kind); - } - if (target === anyFunctionType || source === anyFunctionType) { - return -1 /* True */; - } - var sourceSignatures = getSignaturesOfType(source, kind); - var targetSignatures = getSignaturesOfType(target, kind); - var result = -1 /* True */; - var saveErrorInfo = errorInfo; - outer: for (var _i = 0; _i < targetSignatures.length; _i++) { - var t = targetSignatures[_i]; - if (!t.hasStringLiterals || target.flags & 131072 /* FromSignature */) { - var localErrors = reportErrors; - for (var _a = 0; _a < sourceSignatures.length; _a++) { - var s = sourceSignatures[_a]; - if (!s.hasStringLiterals || source.flags & 131072 /* FromSignature */) { - var related = signatureRelatedTo(s, t, localErrors); - if (related) { - result &= related; - errorInfo = saveErrorInfo; - continue outer; - } - // Only report errors from the first failure - localErrors = false; - } - } - return 0 /* False */; - } - } - return result; - } - function signatureRelatedTo(source, target, reportErrors) { - if (source === target) { - return -1 /* True */; - } - if (!target.hasRestParameter && source.minArgumentCount > target.parameters.length) { - return 0 /* False */; - } - var sourceMax = source.parameters.length; - var targetMax = target.parameters.length; - var checkCount; - if (source.hasRestParameter && target.hasRestParameter) { - checkCount = sourceMax > targetMax ? sourceMax : targetMax; - sourceMax--; - targetMax--; - } - else if (source.hasRestParameter) { - sourceMax--; - checkCount = targetMax; - } - else if (target.hasRestParameter) { - targetMax--; - checkCount = sourceMax; - } - else { - checkCount = sourceMax < targetMax ? sourceMax : targetMax; - } - // Spec 1.0 Section 3.8.3 & 3.8.4: - // M and N (the signatures) are instantiated using type Any as the type argument for all type parameters declared by M and N - source = getErasedSignature(source); - target = getErasedSignature(target); - var result = -1 /* True */; - for (var i = 0; i < checkCount; i++) { - var s_1 = i < sourceMax ? getTypeOfSymbol(source.parameters[i]) : getRestTypeOfSignature(source); - var t_1 = i < targetMax ? getTypeOfSymbol(target.parameters[i]) : getRestTypeOfSignature(target); - var saveErrorInfo = errorInfo; - var related = isRelatedTo(s_1, t_1, reportErrors); - if (!related) { - related = isRelatedTo(t_1, s_1, false); - if (!related) { - if (reportErrors) { - reportError(ts.Diagnostics.Types_of_parameters_0_and_1_are_incompatible, source.parameters[i < sourceMax ? i : sourceMax].name, target.parameters[i < targetMax ? i : targetMax].name); - } - return 0 /* False */; - } - errorInfo = saveErrorInfo; - } - result &= related; - } - if (source.typePredicate && target.typePredicate) { - var hasDifferentParameterIndex = source.typePredicate.parameterIndex !== target.typePredicate.parameterIndex; - var hasDifferentTypes; - if (hasDifferentParameterIndex || - (hasDifferentTypes = !isTypeIdenticalTo(source.typePredicate.type, target.typePredicate.type))) { - if (reportErrors) { - var sourceParamText = source.typePredicate.parameterName; - var targetParamText = target.typePredicate.parameterName; - var sourceTypeText = typeToString(source.typePredicate.type); - var targetTypeText = typeToString(target.typePredicate.type); - if (hasDifferentParameterIndex) { - reportError(ts.Diagnostics.Parameter_0_is_not_in_the_same_position_as_parameter_1, sourceParamText, targetParamText); - } - else if (hasDifferentTypes) { - reportError(ts.Diagnostics.Type_0_is_not_assignable_to_type_1, sourceTypeText, targetTypeText); - } - reportError(ts.Diagnostics.Type_predicate_0_is_not_assignable_to_1, sourceParamText + " is " + sourceTypeText, targetParamText + " is " + targetTypeText); - } - return 0 /* False */; - } - } - else if (!source.typePredicate && target.typePredicate) { - if (reportErrors) { - reportError(ts.Diagnostics.Signature_0_must_have_a_type_predicate, signatureToString(source)); - } - return 0 /* False */; - } - var t = getReturnTypeOfSignature(target); - if (t === voidType) - return result; - var s = getReturnTypeOfSignature(source); - return result & isRelatedTo(s, t, reportErrors); - } - function signaturesIdenticalTo(source, target, kind) { - var sourceSignatures = getSignaturesOfType(source, kind); - var targetSignatures = getSignaturesOfType(target, kind); - if (sourceSignatures.length !== targetSignatures.length) { - return 0 /* False */; - } - var result = -1 /* True */; - for (var i = 0, len = sourceSignatures.length; i < len; ++i) { - var related = compareSignatures(sourceSignatures[i], targetSignatures[i], true, isRelatedTo); - if (!related) { - return 0 /* False */; - } - result &= related; - } - return result; - } - function stringIndexTypesRelatedTo(source, target, reportErrors) { - if (relation === identityRelation) { - return indexTypesIdenticalTo(0 /* String */, source, target); - } - var targetType = getIndexTypeOfType(target, 0 /* String */); - if (targetType) { - var sourceType = getIndexTypeOfType(source, 0 /* String */); - if (!sourceType) { - if (reportErrors) { - reportError(ts.Diagnostics.Index_signature_is_missing_in_type_0, typeToString(source)); - } - return 0 /* False */; - } - var related = isRelatedTo(sourceType, targetType, reportErrors); - if (!related) { - if (reportErrors) { - reportError(ts.Diagnostics.Index_signatures_are_incompatible); - } - return 0 /* False */; - } - return related; - } - return -1 /* True */; - } - function numberIndexTypesRelatedTo(source, target, reportErrors) { - if (relation === identityRelation) { - return indexTypesIdenticalTo(1 /* Number */, source, target); - } - var targetType = getIndexTypeOfType(target, 1 /* Number */); - if (targetType) { - var sourceStringType = getIndexTypeOfType(source, 0 /* String */); - var sourceNumberType = getIndexTypeOfType(source, 1 /* Number */); - if (!(sourceStringType || sourceNumberType)) { - if (reportErrors) { - reportError(ts.Diagnostics.Index_signature_is_missing_in_type_0, typeToString(source)); - } - return 0 /* False */; - } - var related; - if (sourceStringType && sourceNumberType) { - // If we know for sure we're testing both string and numeric index types then only report errors from the second one - related = isRelatedTo(sourceStringType, targetType, false) || isRelatedTo(sourceNumberType, targetType, reportErrors); - } - else { - related = isRelatedTo(sourceStringType || sourceNumberType, targetType, reportErrors); - } - if (!related) { - if (reportErrors) { - reportError(ts.Diagnostics.Index_signatures_are_incompatible); - } - return 0 /* False */; - } - return related; - } - return -1 /* True */; - } - function indexTypesIdenticalTo(indexKind, source, target) { - var targetType = getIndexTypeOfType(target, indexKind); - var sourceType = getIndexTypeOfType(source, indexKind); - if (!sourceType && !targetType) { - return -1 /* True */; - } - if (sourceType && targetType) { - return isRelatedTo(sourceType, targetType); - } - return 0 /* False */; - } - } - // Return true if the given type is part of a deeply nested chain of generic instantiations. We consider this to be the case - // when structural type comparisons have been started for 10 or more instantiations of the same generic type. It is possible, - // though highly unlikely, for this test to be true in a situation where a chain of instantiations is not infinitely expanding. - // Effectively, we will generate a false positive when two types are structurally equal to at least 10 levels, but unequal at - // some level beyond that. - function isDeeplyNestedGeneric(type, stack, depth) { - // We track type references (created by createTypeReference) and instantiated types (created by instantiateType) - if (type.flags & (4096 /* Reference */ | 65536 /* Instantiated */) && depth >= 5) { - var symbol = type.symbol; - var count = 0; - for (var i = 0; i < depth; i++) { - var t = stack[i]; - if (t.flags & (4096 /* Reference */ | 65536 /* Instantiated */) && t.symbol === symbol) { - count++; - if (count >= 5) - return true; - } - } - } - return false; - } - function isPropertyIdenticalTo(sourceProp, targetProp) { - return compareProperties(sourceProp, targetProp, compareTypes) !== 0 /* False */; - } - function compareProperties(sourceProp, targetProp, compareTypes) { - // Two members are considered identical when - // - they are public properties with identical names, optionality, and types, - // - they are private or protected properties originating in the same declaration and having identical types - if (sourceProp === targetProp) { - return -1 /* True */; - } - var sourcePropAccessibility = getDeclarationFlagsFromSymbol(sourceProp) & (32 /* Private */ | 64 /* Protected */); - var targetPropAccessibility = getDeclarationFlagsFromSymbol(targetProp) & (32 /* Private */ | 64 /* Protected */); - if (sourcePropAccessibility !== targetPropAccessibility) { - return 0 /* False */; - } - if (sourcePropAccessibility) { - if (getTargetSymbol(sourceProp) !== getTargetSymbol(targetProp)) { - return 0 /* False */; - } - } - else { - if ((sourceProp.flags & 536870912 /* Optional */) !== (targetProp.flags & 536870912 /* Optional */)) { - return 0 /* False */; - } - } - return compareTypes(getTypeOfSymbol(sourceProp), getTypeOfSymbol(targetProp)); - } - function compareSignatures(source, target, compareReturnTypes, compareTypes) { - if (source === target) { - return -1 /* True */; - } - if (source.parameters.length !== target.parameters.length || - source.minArgumentCount !== target.minArgumentCount || - source.hasRestParameter !== target.hasRestParameter) { - return 0 /* False */; - } - var result = -1 /* True */; - if (source.typeParameters && target.typeParameters) { - if (source.typeParameters.length !== target.typeParameters.length) { - return 0 /* False */; - } - for (var i = 0, len = source.typeParameters.length; i < len; ++i) { - var related = compareTypes(source.typeParameters[i], target.typeParameters[i]); - if (!related) { - return 0 /* False */; - } - result &= related; - } - } - else if (source.typeParameters || target.typeParameters) { - return 0 /* False */; - } - // Spec 1.0 Section 3.8.3 & 3.8.4: - // M and N (the signatures) are instantiated using type Any as the type argument for all type parameters declared by M and N - source = getErasedSignature(source); - target = getErasedSignature(target); - for (var i = 0, len = source.parameters.length; i < len; i++) { - var s = source.hasRestParameter && i === len - 1 ? getRestTypeOfSignature(source) : getTypeOfSymbol(source.parameters[i]); - var t = target.hasRestParameter && i === len - 1 ? getRestTypeOfSignature(target) : getTypeOfSymbol(target.parameters[i]); - var related = compareTypes(s, t); - if (!related) { - return 0 /* False */; - } - result &= related; - } - if (compareReturnTypes) { - result &= compareTypes(getReturnTypeOfSignature(source), getReturnTypeOfSignature(target)); - } - return result; - } - function isSupertypeOfEach(candidate, types) { - for (var _i = 0; _i < types.length; _i++) { - var type = types[_i]; - if (candidate !== type && !isTypeSubtypeOf(type, candidate)) - return false; - } - return true; - } - function getCommonSupertype(types) { - return ts.forEach(types, function (t) { return isSupertypeOfEach(t, types) ? t : undefined; }); - } - function reportNoCommonSupertypeError(types, errorLocation, errorMessageChainHead) { - // The downfallType/bestSupertypeDownfallType is the first type that caused a particular candidate - // to not be the common supertype. So if it weren't for this one downfallType (and possibly others), - // the type in question could have been the common supertype. - var bestSupertype; - var bestSupertypeDownfallType; - var bestSupertypeScore = 0; - for (var i = 0; i < types.length; i++) { - var score = 0; - var downfallType = undefined; - for (var j = 0; j < types.length; j++) { - if (isTypeSubtypeOf(types[j], types[i])) { - score++; - } - else if (!downfallType) { - downfallType = types[j]; - } - } - ts.Debug.assert(!!downfallType, "If there is no common supertype, each type should have a downfallType"); - if (score > bestSupertypeScore) { - bestSupertype = types[i]; - bestSupertypeDownfallType = downfallType; - bestSupertypeScore = score; - } - // types.length - 1 is the maximum score, given that getCommonSupertype returned false - if (bestSupertypeScore === types.length - 1) { - break; - } - } - // In the following errors, the {1} slot is before the {0} slot because checkTypeSubtypeOf supplies the - // subtype as the first argument to the error - checkTypeSubtypeOf(bestSupertypeDownfallType, bestSupertype, errorLocation, ts.Diagnostics.Type_argument_candidate_1_is_not_a_valid_type_argument_because_it_is_not_a_supertype_of_candidate_0, errorMessageChainHead); - } - function isArrayType(type) { - return type.flags & 4096 /* Reference */ && type.target === globalArrayType; - } - function isArrayLikeType(type) { - // A type is array-like if it is not the undefined or null type and if it is assignable to any[] - return !(type.flags & (32 /* Undefined */ | 64 /* Null */)) && isTypeAssignableTo(type, anyArrayType); - } - function isTupleLikeType(type) { - return !!getPropertyOfType(type, "0"); - } - /** - * Check if a Type was written as a tuple type literal. - * Prefer using isTupleLikeType() unless the use of `elementTypes` is required. - */ - function isTupleType(type) { - return (type.flags & 8192 /* Tuple */) && !!type.elementTypes; - } - function getWidenedTypeOfObjectLiteral(type) { - var properties = getPropertiesOfObjectType(type); - var members = {}; - ts.forEach(properties, function (p) { - var propType = getTypeOfSymbol(p); - var widenedType = getWidenedType(propType); - if (propType !== widenedType) { - var symbol = createSymbol(p.flags | 67108864 /* Transient */, p.name); - symbol.declarations = p.declarations; - symbol.parent = p.parent; - symbol.type = widenedType; - symbol.target = p; - if (p.valueDeclaration) - symbol.valueDeclaration = p.valueDeclaration; - p = symbol; - } - members[p.name] = p; - }); - var stringIndexType = getIndexTypeOfType(type, 0 /* String */); - var numberIndexType = getIndexTypeOfType(type, 1 /* Number */); - if (stringIndexType) - stringIndexType = getWidenedType(stringIndexType); - if (numberIndexType) - numberIndexType = getWidenedType(numberIndexType); - return createAnonymousType(type.symbol, members, emptyArray, emptyArray, stringIndexType, numberIndexType); - } - function getWidenedType(type) { - if (type.flags & 1572864 /* RequiresWidening */) { - if (type.flags & (32 /* Undefined */ | 64 /* Null */)) { - return anyType; - } - if (type.flags & 262144 /* ObjectLiteral */) { - return getWidenedTypeOfObjectLiteral(type); - } - if (type.flags & 16384 /* Union */) { - return getUnionType(ts.map(type.types, getWidenedType)); - } - if (isArrayType(type)) { - return createArrayType(getWidenedType(type.typeArguments[0])); - } - } - return type; - } - function reportWideningErrorsInType(type) { - if (type.flags & 16384 /* Union */) { - var errorReported = false; - ts.forEach(type.types, function (t) { - if (reportWideningErrorsInType(t)) { - errorReported = true; - } - }); - return errorReported; - } - if (isArrayType(type)) { - return reportWideningErrorsInType(type.typeArguments[0]); - } - if (type.flags & 262144 /* ObjectLiteral */) { - var errorReported = false; - ts.forEach(getPropertiesOfObjectType(type), function (p) { - var t = getTypeOfSymbol(p); - if (t.flags & 524288 /* ContainsUndefinedOrNull */) { - if (!reportWideningErrorsInType(t)) { - error(p.valueDeclaration, ts.Diagnostics.Object_literal_s_property_0_implicitly_has_an_1_type, p.name, typeToString(getWidenedType(t))); - } - errorReported = true; - } - }); - return errorReported; - } - return false; - } - function reportImplicitAnyError(declaration, type) { - var typeAsString = typeToString(getWidenedType(type)); - var diagnostic; - switch (declaration.kind) { - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - diagnostic = ts.Diagnostics.Member_0_implicitly_has_an_1_type; - break; - case 131 /* Parameter */: - diagnostic = declaration.dotDotDotToken ? - ts.Diagnostics.Rest_parameter_0_implicitly_has_an_any_type : - ts.Diagnostics.Parameter_0_implicitly_has_an_1_type; - break; - case 203 /* FunctionDeclaration */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 165 /* FunctionExpression */: - case 166 /* ArrowFunction */: - if (!declaration.name) { - error(declaration, ts.Diagnostics.Function_expression_which_lacks_return_type_annotation_implicitly_has_an_0_return_type, typeAsString); - return; - } - diagnostic = ts.Diagnostics._0_which_lacks_return_type_annotation_implicitly_has_an_1_return_type; - break; - default: - diagnostic = ts.Diagnostics.Variable_0_implicitly_has_an_1_type; - } - error(declaration, diagnostic, ts.declarationNameToString(declaration.name), typeAsString); - } - function reportErrorsFromWidening(declaration, type) { - if (produceDiagnostics && compilerOptions.noImplicitAny && type.flags & 524288 /* ContainsUndefinedOrNull */) { - // Report implicit any error within type if possible, otherwise report error on declaration - if (!reportWideningErrorsInType(type)) { - reportImplicitAnyError(declaration, type); - } - } - } - function forEachMatchingParameterType(source, target, callback) { - var sourceMax = source.parameters.length; - var targetMax = target.parameters.length; - var count; - if (source.hasRestParameter && target.hasRestParameter) { - count = sourceMax > targetMax ? sourceMax : targetMax; - sourceMax--; - targetMax--; - } - else if (source.hasRestParameter) { - sourceMax--; - count = targetMax; - } - else if (target.hasRestParameter) { - targetMax--; - count = sourceMax; - } - else { - count = sourceMax < targetMax ? sourceMax : targetMax; - } - for (var i = 0; i < count; i++) { - var s = i < sourceMax ? getTypeOfSymbol(source.parameters[i]) : getRestTypeOfSignature(source); - var t = i < targetMax ? getTypeOfSymbol(target.parameters[i]) : getRestTypeOfSignature(target); - callback(s, t); - } - } - function createInferenceContext(typeParameters, inferUnionTypes) { - var inferences = []; - for (var _i = 0; _i < typeParameters.length; _i++) { - var unused = typeParameters[_i]; - inferences.push({ primary: undefined, secondary: undefined, isFixed: false }); - } - return { - typeParameters: typeParameters, - inferUnionTypes: inferUnionTypes, - inferences: inferences, - inferredTypes: new Array(typeParameters.length) - }; - } - function inferTypes(context, source, target) { - var sourceStack; - var targetStack; - var depth = 0; - var inferiority = 0; - inferFromTypes(source, target); - function isInProcess(source, target) { - for (var i = 0; i < depth; i++) { - if (source === sourceStack[i] && target === targetStack[i]) { - return true; - } - } - return false; - } - function inferFromTypes(source, target) { - if (source === anyFunctionType) { - return; - } - if (target.flags & 512 /* TypeParameter */) { - // If target is a type parameter, make an inference - var typeParameters = context.typeParameters; - for (var i = 0; i < typeParameters.length; i++) { - if (target === typeParameters[i]) { - var inferences = context.inferences[i]; - if (!inferences.isFixed) { - // Any inferences that are made to a type parameter in a union type are inferior - // to inferences made to a flat (non-union) type. This is because if we infer to - // T | string[], we really don't know if we should be inferring to T or not (because - // the correct constituent on the target side could be string[]). Therefore, we put - // such inferior inferences into a secondary bucket, and only use them if the primary - // bucket is empty. - var candidates = inferiority ? - inferences.secondary || (inferences.secondary = []) : - inferences.primary || (inferences.primary = []); - if (!ts.contains(candidates, source)) { - candidates.push(source); - } - } - return; - } - } - } - else if (source.flags & 4096 /* Reference */ && target.flags & 4096 /* Reference */ && source.target === target.target) { - // If source and target are references to the same generic type, infer from type arguments - var sourceTypes = source.typeArguments; - var targetTypes = target.typeArguments; - for (var i = 0; i < sourceTypes.length; i++) { - inferFromTypes(sourceTypes[i], targetTypes[i]); - } - } - else if (target.flags & 16384 /* Union */) { - var targetTypes = target.types; - var typeParameterCount = 0; - var typeParameter; - // First infer to each type in union that isn't a type parameter - for (var _i = 0; _i < targetTypes.length; _i++) { - var t = targetTypes[_i]; - if (t.flags & 512 /* TypeParameter */ && ts.contains(context.typeParameters, t)) { - typeParameter = t; - typeParameterCount++; - } - else { - inferFromTypes(source, t); - } - } - // If union contains a single naked type parameter, make a secondary inference to that type parameter - if (typeParameterCount === 1) { - inferiority++; - inferFromTypes(source, typeParameter); - inferiority--; - } - } - else if (source.flags & 16384 /* Union */) { - // Source is a union type, infer from each consituent type - var sourceTypes = source.types; - for (var _a = 0; _a < sourceTypes.length; _a++) { - var sourceType = sourceTypes[_a]; - inferFromTypes(sourceType, target); - } - } - else if (source.flags & 48128 /* ObjectType */ && (target.flags & (4096 /* Reference */ | 8192 /* Tuple */) || - (target.flags & 32768 /* Anonymous */) && target.symbol && target.symbol.flags & (8192 /* Method */ | 2048 /* TypeLiteral */))) { - // If source is an object type, and target is a type reference, a tuple type, the type of a method, or a type literal, infer from members - if (isInProcess(source, target)) { - return; - } - if (isDeeplyNestedGeneric(source, sourceStack, depth) && isDeeplyNestedGeneric(target, targetStack, depth)) { - return; - } - if (depth === 0) { - sourceStack = []; - targetStack = []; - } - sourceStack[depth] = source; - targetStack[depth] = target; - depth++; - inferFromProperties(source, target); - inferFromSignatures(source, target, 0 /* Call */); - inferFromSignatures(source, target, 1 /* Construct */); - inferFromIndexTypes(source, target, 0 /* String */, 0 /* String */); - inferFromIndexTypes(source, target, 1 /* Number */, 1 /* Number */); - inferFromIndexTypes(source, target, 0 /* String */, 1 /* Number */); - depth--; - } - } - function inferFromProperties(source, target) { - var properties = getPropertiesOfObjectType(target); - for (var _i = 0; _i < properties.length; _i++) { - var targetProp = properties[_i]; - var sourceProp = getPropertyOfObjectType(source, targetProp.name); - if (sourceProp) { - inferFromTypes(getTypeOfSymbol(sourceProp), getTypeOfSymbol(targetProp)); - } - } - } - function inferFromSignatures(source, target, kind) { - var sourceSignatures = getSignaturesOfType(source, kind); - var targetSignatures = getSignaturesOfType(target, kind); - var sourceLen = sourceSignatures.length; - var targetLen = targetSignatures.length; - var len = sourceLen < targetLen ? sourceLen : targetLen; - for (var i = 0; i < len; i++) { - inferFromSignature(getErasedSignature(sourceSignatures[sourceLen - len + i]), getErasedSignature(targetSignatures[targetLen - len + i])); - } - } - function inferFromSignature(source, target) { - forEachMatchingParameterType(source, target, inferFromTypes); - if (source.typePredicate && target.typePredicate) { - if (target.typePredicate.parameterIndex === source.typePredicate.parameterIndex) { - // Return types from type predicates are treated as booleans. In order to infer types - // from type predicates we would need to infer using the type within the type predicate - // (i.e. 'Foo' from 'x is Foo'). - inferFromTypes(source.typePredicate.type, target.typePredicate.type); - } - } - else { - inferFromTypes(getReturnTypeOfSignature(source), getReturnTypeOfSignature(target)); - } - } - function inferFromIndexTypes(source, target, sourceKind, targetKind) { - var targetIndexType = getIndexTypeOfType(target, targetKind); - if (targetIndexType) { - var sourceIndexType = getIndexTypeOfType(source, sourceKind); - if (sourceIndexType) { - inferFromTypes(sourceIndexType, targetIndexType); - } - } - } - } - function getInferenceCandidates(context, index) { - var inferences = context.inferences[index]; - return inferences.primary || inferences.secondary || emptyArray; - } - function getInferredType(context, index) { - var inferredType = context.inferredTypes[index]; - var inferenceSucceeded; - if (!inferredType) { - var inferences = getInferenceCandidates(context, index); - if (inferences.length) { - // Infer widened union or supertype, or the unknown type for no common supertype - var unionOrSuperType = context.inferUnionTypes ? getUnionType(inferences) : getCommonSupertype(inferences); - inferredType = unionOrSuperType ? getWidenedType(unionOrSuperType) : unknownType; - inferenceSucceeded = !!unionOrSuperType; - } - else { - // Infer the empty object type when no inferences were made. It is important to remember that - // in this case, inference still succeeds, meaning there is no error for not having inference - // candidates. An inference error only occurs when there are *conflicting* candidates, i.e. - // candidates with no common supertype. - inferredType = emptyObjectType; - inferenceSucceeded = true; - } - // Only do the constraint check if inference succeeded (to prevent cascading errors) - if (inferenceSucceeded) { - var constraint = getConstraintOfTypeParameter(context.typeParameters[index]); - inferredType = constraint && !isTypeAssignableTo(inferredType, constraint) ? constraint : inferredType; - } - else if (context.failedTypeParameterIndex === undefined || context.failedTypeParameterIndex > index) { - // If inference failed, it is necessary to record the index of the failed type parameter (the one we are on). - // It might be that inference has already failed on a later type parameter on a previous call to inferTypeArguments. - // So if this failure is on preceding type parameter, this type parameter is the new failure index. - context.failedTypeParameterIndex = index; - } - context.inferredTypes[index] = inferredType; - } - return inferredType; - } - function getInferredTypes(context) { - for (var i = 0; i < context.inferredTypes.length; i++) { - getInferredType(context, i); - } - return context.inferredTypes; - } - function hasAncestor(node, kind) { - return ts.getAncestor(node, kind) !== undefined; - } - // EXPRESSION TYPE CHECKING - function getResolvedSymbol(node) { - var links = getNodeLinks(node); - if (!links.resolvedSymbol) { - links.resolvedSymbol = (!ts.nodeIsMissing(node) && resolveName(node, node.text, 107455 /* Value */ | 1048576 /* ExportValue */, ts.Diagnostics.Cannot_find_name_0, node)) || unknownSymbol; - } - return links.resolvedSymbol; - } - function isInTypeQuery(node) { - // TypeScript 1.0 spec (April 2014): 3.6.3 - // A type query consists of the keyword typeof followed by an expression. - // The expression is restricted to a single identifier or a sequence of identifiers separated by periods - while (node) { - switch (node.kind) { - case 147 /* TypeQuery */: - return true; - case 65 /* Identifier */: - case 128 /* QualifiedName */: - node = node.parent; - continue; - default: - return false; - } - } - ts.Debug.fail("should not get here"); - } - // For a union type, remove all constituent types that are of the given type kind (when isOfTypeKind is true) - // or not of the given type kind (when isOfTypeKind is false) - function removeTypesFromUnionType(type, typeKind, isOfTypeKind, allowEmptyUnionResult) { - if (type.flags & 16384 /* Union */) { - var types = type.types; - if (ts.forEach(types, function (t) { return !!(t.flags & typeKind) === isOfTypeKind; })) { - // Above we checked if we have anything to remove, now use the opposite test to do the removal - var narrowedType = getUnionType(ts.filter(types, function (t) { return !(t.flags & typeKind) === isOfTypeKind; })); - if (allowEmptyUnionResult || narrowedType !== emptyObjectType) { - return narrowedType; - } - } - } - else if (allowEmptyUnionResult && !!(type.flags & typeKind) === isOfTypeKind) { - // Use getUnionType(emptyArray) instead of emptyObjectType in case the way empty union types - // are represented ever changes. - return getUnionType(emptyArray); - } - return type; - } - function hasInitializer(node) { - return !!(node.initializer || ts.isBindingPattern(node.parent) && hasInitializer(node.parent.parent)); - } - // Check if a given variable is assigned within a given syntax node - function isVariableAssignedWithin(symbol, node) { - var links = getNodeLinks(node); - if (links.assignmentChecks) { - var cachedResult = links.assignmentChecks[symbol.id]; - if (cachedResult !== undefined) { - return cachedResult; - } - } - else { - links.assignmentChecks = {}; - } - return links.assignmentChecks[symbol.id] = isAssignedIn(node); - function isAssignedInBinaryExpression(node) { - if (node.operatorToken.kind >= 53 /* FirstAssignment */ && node.operatorToken.kind <= 64 /* LastAssignment */) { - var n = node.left; - while (n.kind === 164 /* ParenthesizedExpression */) { - n = n.expression; - } - if (n.kind === 65 /* Identifier */ && getResolvedSymbol(n) === symbol) { - return true; - } - } - return ts.forEachChild(node, isAssignedIn); - } - function isAssignedInVariableDeclaration(node) { - if (!ts.isBindingPattern(node.name) && getSymbolOfNode(node) === symbol && hasInitializer(node)) { - return true; - } - return ts.forEachChild(node, isAssignedIn); - } - function isAssignedIn(node) { - switch (node.kind) { - case 172 /* BinaryExpression */: - return isAssignedInBinaryExpression(node); - case 201 /* VariableDeclaration */: - case 155 /* BindingElement */: - return isAssignedInVariableDeclaration(node); - case 153 /* ObjectBindingPattern */: - case 154 /* ArrayBindingPattern */: - case 156 /* ArrayLiteralExpression */: - case 157 /* ObjectLiteralExpression */: - case 158 /* PropertyAccessExpression */: - case 159 /* ElementAccessExpression */: - case 160 /* CallExpression */: - case 161 /* NewExpression */: - case 163 /* TypeAssertionExpression */: - case 164 /* ParenthesizedExpression */: - case 170 /* PrefixUnaryExpression */: - case 167 /* DeleteExpression */: - case 168 /* TypeOfExpression */: - case 169 /* VoidExpression */: - case 171 /* PostfixUnaryExpression */: - case 173 /* ConditionalExpression */: - case 176 /* SpreadElementExpression */: - case 182 /* Block */: - case 183 /* VariableStatement */: - case 185 /* ExpressionStatement */: - case 186 /* IfStatement */: - case 187 /* DoStatement */: - case 188 /* WhileStatement */: - case 189 /* ForStatement */: - case 190 /* ForInStatement */: - case 191 /* ForOfStatement */: - case 194 /* ReturnStatement */: - case 195 /* WithStatement */: - case 196 /* SwitchStatement */: - case 223 /* CaseClause */: - case 224 /* DefaultClause */: - case 197 /* LabeledStatement */: - case 198 /* ThrowStatement */: - case 199 /* TryStatement */: - case 226 /* CatchClause */: - return ts.forEachChild(node, isAssignedIn); - } - return false; - } - } - function resolveLocation(node) { - // Resolve location from top down towards node if it is a context sensitive expression - // That helps in making sure not assigning types as any when resolved out of order - var containerNodes = []; - for (var parent_5 = node.parent; parent_5; parent_5 = parent_5.parent) { - if ((ts.isExpression(parent_5) || ts.isObjectLiteralMethod(node)) && - isContextSensitive(parent_5)) { - containerNodes.unshift(parent_5); - } - } - ts.forEach(containerNodes, function (node) { getTypeOfNode(node); }); - } - function getSymbolAtLocation(node) { - resolveLocation(node); - return getSymbolInfo(node); - } - function getTypeAtLocation(node) { - resolveLocation(node); - return getTypeOfNode(node); - } - function getTypeOfSymbolAtLocation(symbol, node) { - resolveLocation(node); - // Get the narrowed type of symbol at given location instead of just getting - // the type of the symbol. - // eg. - // function foo(a: string | number) { - // if (typeof a === "string") { - // a/**/ - // } - // } - // getTypeOfSymbol for a would return type of parameter symbol string | number - // Unless we provide location /**/, checker wouldn't know how to narrow the type - // By using getNarrowedTypeOfSymbol would return string since it would be able to narrow - // it by typeguard in the if true condition - return getNarrowedTypeOfSymbol(symbol, node); - } - // Get the narrowed type of a given symbol at a given location - function getNarrowedTypeOfSymbol(symbol, node) { - var type = getTypeOfSymbol(symbol); - // Only narrow when symbol is variable of type any or an object, union, or type parameter type - if (node && symbol.flags & 3 /* Variable */) { - if (isTypeAny(type) || type.flags & (48128 /* ObjectType */ | 16384 /* Union */ | 512 /* TypeParameter */)) { - loop: while (node.parent) { - var child = node; - node = node.parent; - var narrowedType = type; - switch (node.kind) { - case 186 /* IfStatement */: - // In a branch of an if statement, narrow based on controlling expression - if (child !== node.expression) { - narrowedType = narrowType(type, node.expression, child === node.thenStatement); - } - break; - case 173 /* ConditionalExpression */: - // In a branch of a conditional expression, narrow based on controlling condition - if (child !== node.condition) { - narrowedType = narrowType(type, node.condition, child === node.whenTrue); - } - break; - case 172 /* BinaryExpression */: - // In the right operand of an && or ||, narrow based on left operand - if (child === node.right) { - if (node.operatorToken.kind === 48 /* AmpersandAmpersandToken */) { - narrowedType = narrowType(type, node.left, true); - } - else if (node.operatorToken.kind === 49 /* BarBarToken */) { - narrowedType = narrowType(type, node.left, false); - } - } - break; - case 230 /* SourceFile */: - case 208 /* ModuleDeclaration */: - case 203 /* FunctionDeclaration */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 137 /* Constructor */: - // Stop at the first containing function or module declaration - break loop; - } - // Use narrowed type if construct contains no assignments to variable - if (narrowedType !== type) { - if (isVariableAssignedWithin(symbol, node)) { - break; - } - type = narrowedType; - } - } - } - } - return type; - function narrowTypeByEquality(type, expr, assumeTrue) { - // Check that we have 'typeof ' on the left and string literal on the right - if (expr.left.kind !== 168 /* TypeOfExpression */ || expr.right.kind !== 8 /* StringLiteral */) { - return type; - } - var left = expr.left; - var right = expr.right; - if (left.expression.kind !== 65 /* Identifier */ || getResolvedSymbol(left.expression) !== symbol) { - return type; - } - var typeInfo = primitiveTypeInfo[right.text]; - if (expr.operatorToken.kind === 31 /* ExclamationEqualsEqualsToken */) { - assumeTrue = !assumeTrue; - } - if (assumeTrue) { - // Assumed result is true. If check was not for a primitive type, remove all primitive types - if (!typeInfo) { - return removeTypesFromUnionType(type, 258 /* StringLike */ | 132 /* NumberLike */ | 8 /* Boolean */ | 2097152 /* ESSymbol */, - /*isOfTypeKind*/ true, false); - } - // Check was for a primitive type, return that primitive type if it is a subtype - if (isTypeSubtypeOf(typeInfo.type, type)) { - return typeInfo.type; - } - // Otherwise, remove all types that aren't of the primitive type kind. This can happen when the type is - // union of enum types and other types. - return removeTypesFromUnionType(type, typeInfo.flags, false, false); - } - else { - // Assumed result is false. If check was for a primitive type, remove that primitive type - if (typeInfo) { - return removeTypesFromUnionType(type, typeInfo.flags, true, false); - } - // Otherwise we don't have enough information to do anything. - return type; - } - } - function narrowTypeByAnd(type, expr, assumeTrue) { - if (assumeTrue) { - // The assumed result is true, therefore we narrow assuming each operand to be true. - return narrowType(narrowType(type, expr.left, true), expr.right, true); - } - else { - // The assumed result is false. This means either the first operand was false, or the first operand was true - // and the second operand was false. We narrow with those assumptions and union the two resulting types. - return getUnionType([ - narrowType(type, expr.left, false), - narrowType(narrowType(type, expr.left, true), expr.right, false) - ]); - } - } - function narrowTypeByOr(type, expr, assumeTrue) { - if (assumeTrue) { - // The assumed result is true. This means either the first operand was true, or the first operand was false - // and the second operand was true. We narrow with those assumptions and union the two resulting types. - return getUnionType([ - narrowType(type, expr.left, true), - narrowType(narrowType(type, expr.left, false), expr.right, true) - ]); - } - else { - // The assumed result is false, therefore we narrow assuming each operand to be false. - return narrowType(narrowType(type, expr.left, false), expr.right, false); - } - } - function narrowTypeByInstanceof(type, expr, assumeTrue) { - // Check that type is not any, assumed result is true, and we have variable symbol on the left - if (isTypeAny(type) || !assumeTrue || expr.left.kind !== 65 /* Identifier */ || getResolvedSymbol(expr.left) !== symbol) { - return type; - } - // Check that right operand is a function type with a prototype property - var rightType = checkExpression(expr.right); - if (!isTypeSubtypeOf(rightType, globalFunctionType)) { - return type; - } - var targetType; - var prototypeProperty = getPropertyOfType(rightType, "prototype"); - if (prototypeProperty) { - // Target type is type of the prototype property - var prototypePropertyType = getTypeOfSymbol(prototypeProperty); - if (!isTypeAny(prototypePropertyType)) { - targetType = prototypePropertyType; - } - } - if (!targetType) { - // Target type is type of construct signature - var constructSignatures; - if (rightType.flags & 2048 /* Interface */) { - constructSignatures = resolveDeclaredMembers(rightType).declaredConstructSignatures; - } - else if (rightType.flags & 32768 /* Anonymous */) { - constructSignatures = getSignaturesOfType(rightType, 1 /* Construct */); - } - if (constructSignatures && constructSignatures.length) { - targetType = getUnionType(ts.map(constructSignatures, function (signature) { return getReturnTypeOfSignature(getErasedSignature(signature)); })); - } - } - if (targetType) { - return getNarrowedType(type, targetType); - } - return type; - } - function getNarrowedType(originalType, narrowedTypeCandidate) { - // Narrow to the target type if it's a subtype of the current type - if (isTypeSubtypeOf(narrowedTypeCandidate, originalType)) { - return narrowedTypeCandidate; - } - // If the current type is a union type, remove all constituents that aren't subtypes of the target. - if (originalType.flags & 16384 /* Union */) { - return getUnionType(ts.filter(originalType.types, function (t) { return isTypeSubtypeOf(t, narrowedTypeCandidate); })); - } - return originalType; - } - function narrowTypeByTypePredicate(type, expr, assumeTrue) { - if (type.flags & 1 /* Any */) { - return type; - } - var signature = getResolvedSignature(expr); - if (signature.typePredicate && - getSymbolAtLocation(expr.arguments[signature.typePredicate.parameterIndex]) === symbol) { - if (!assumeTrue) { - if (type.flags & 16384 /* Union */) { - return getUnionType(ts.filter(type.types, function (t) { return !isTypeSubtypeOf(t, signature.typePredicate.type); })); - } - return type; - } - return getNarrowedType(type, signature.typePredicate.type); - } - return type; - } - // Narrow the given type based on the given expression having the assumed boolean value. The returned type - // will be a subtype or the same type as the argument. - function narrowType(type, expr, assumeTrue) { - switch (expr.kind) { - case 160 /* CallExpression */: - return narrowTypeByTypePredicate(type, expr, assumeTrue); - case 164 /* ParenthesizedExpression */: - return narrowType(type, expr.expression, assumeTrue); - case 172 /* BinaryExpression */: - var operator = expr.operatorToken.kind; - if (operator === 30 /* EqualsEqualsEqualsToken */ || operator === 31 /* ExclamationEqualsEqualsToken */) { - return narrowTypeByEquality(type, expr, assumeTrue); - } - else if (operator === 48 /* AmpersandAmpersandToken */) { - return narrowTypeByAnd(type, expr, assumeTrue); - } - else if (operator === 49 /* BarBarToken */) { - return narrowTypeByOr(type, expr, assumeTrue); - } - else if (operator === 87 /* InstanceOfKeyword */) { - return narrowTypeByInstanceof(type, expr, assumeTrue); - } - break; - case 170 /* PrefixUnaryExpression */: - if (expr.operator === 46 /* ExclamationToken */) { - return narrowType(type, expr.operand, !assumeTrue); - } - break; - } - return type; - } - } - function checkIdentifier(node) { - var symbol = getResolvedSymbol(node); - // As noted in ECMAScript 6 language spec, arrow functions never have an arguments objects. - // Although in down-level emit of arrow function, we emit it using function expression which means that - // arguments objects will be bound to the inner object; emitting arrow function natively in ES6, arguments objects - // will be bound to non-arrow function that contain this arrow function. This results in inconsistent behavior. - // To avoid that we will give an error to users if they use arguments objects in arrow function so that they - // can explicitly bound arguments objects - if (symbol === argumentsSymbol && ts.getContainingFunction(node).kind === 166 /* ArrowFunction */ && languageVersion < 2 /* ES6 */) { - error(node, ts.Diagnostics.The_arguments_object_cannot_be_referenced_in_an_arrow_function_in_ES3_and_ES5_Consider_using_a_standard_function_expression); - } - if (symbol.flags & 8388608 /* Alias */ && !isInTypeQuery(node) && !isConstEnumOrConstEnumOnlyModule(resolveAlias(symbol))) { - markAliasSymbolAsReferenced(symbol); - } - checkCollisionWithCapturedSuperVariable(node, node); - checkCollisionWithCapturedThisVariable(node, node); - checkBlockScopedBindingCapturedInLoop(node, symbol); - return getNarrowedTypeOfSymbol(getExportSymbolOfValueSymbolIfExported(symbol), node); - } - function isInsideFunction(node, threshold) { - var current = node; - while (current && current !== threshold) { - if (ts.isFunctionLike(current)) { - return true; - } - current = current.parent; - } - return false; - } - function checkBlockScopedBindingCapturedInLoop(node, symbol) { - if (languageVersion >= 2 /* ES6 */ || - (symbol.flags & 2 /* BlockScopedVariable */) === 0 || - symbol.valueDeclaration.parent.kind === 226 /* CatchClause */) { - return; - } - // - check if binding is used in some function - // (stop the walk when reaching container of binding declaration) - // - if first check succeeded - check if variable is declared inside the loop - // nesting structure: - // (variable declaration or binding element) -> variable declaration list -> container - var container = symbol.valueDeclaration; - while (container.kind !== 202 /* VariableDeclarationList */) { - container = container.parent; - } - // get the parent of variable declaration list - container = container.parent; - if (container.kind === 183 /* VariableStatement */) { - // if parent is variable statement - get its parent - container = container.parent; - } - var inFunction = isInsideFunction(node.parent, container); - var current = container; - while (current && !ts.nodeStartsNewLexicalEnvironment(current)) { - if (isIterationStatement(current, false)) { - if (inFunction) { - grammarErrorOnFirstToken(current, ts.Diagnostics.Loop_contains_block_scoped_variable_0_referenced_by_a_function_in_the_loop_This_is_only_supported_in_ECMAScript_6_or_higher, ts.declarationNameToString(node)); - } - // mark value declaration so during emit they can have a special handling - getNodeLinks(symbol.valueDeclaration).flags |= 256 /* BlockScopedBindingInLoop */; - break; - } - current = current.parent; - } - } - function captureLexicalThis(node, container) { - var classNode = container.parent && container.parent.kind === 204 /* ClassDeclaration */ ? container.parent : undefined; - getNodeLinks(node).flags |= 2 /* LexicalThis */; - if (container.kind === 134 /* PropertyDeclaration */ || container.kind === 137 /* Constructor */) { - getNodeLinks(classNode).flags |= 4 /* CaptureThis */; - } - else { - getNodeLinks(container).flags |= 4 /* CaptureThis */; - } - } - function checkThisExpression(node) { - // Stop at the first arrow function so that we can - // tell whether 'this' needs to be captured. - var container = ts.getThisContainer(node, true); - var needToCaptureLexicalThis = false; - // Now skip arrow functions to get the "real" owner of 'this'. - if (container.kind === 166 /* ArrowFunction */) { - container = ts.getThisContainer(container, false); - // When targeting es6, arrow function lexically bind "this" so we do not need to do the work of binding "this" in emitted code - needToCaptureLexicalThis = (languageVersion < 2 /* ES6 */); - } - switch (container.kind) { - case 208 /* ModuleDeclaration */: - error(node, ts.Diagnostics.this_cannot_be_referenced_in_a_module_or_namespace_body); - // do not return here so in case if lexical this is captured - it will be reflected in flags on NodeLinks - break; - case 207 /* EnumDeclaration */: - error(node, ts.Diagnostics.this_cannot_be_referenced_in_current_location); - // do not return here so in case if lexical this is captured - it will be reflected in flags on NodeLinks - break; - case 137 /* Constructor */: - if (isInConstructorArgumentInitializer(node, container)) { - error(node, ts.Diagnostics.this_cannot_be_referenced_in_constructor_arguments); - } - break; - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - if (container.flags & 128 /* Static */) { - error(node, ts.Diagnostics.this_cannot_be_referenced_in_a_static_property_initializer); - } - break; - case 129 /* ComputedPropertyName */: - error(node, ts.Diagnostics.this_cannot_be_referenced_in_a_computed_property_name); - break; - } - if (needToCaptureLexicalThis) { - captureLexicalThis(node, container); - } - var classNode = container.parent && container.parent.kind === 204 /* ClassDeclaration */ ? container.parent : undefined; - if (classNode) { - var symbol = getSymbolOfNode(classNode); - return container.flags & 128 /* Static */ ? getTypeOfSymbol(symbol) : getDeclaredTypeOfSymbol(symbol); - } - return anyType; - } - function isInConstructorArgumentInitializer(node, constructorDecl) { - for (var n = node; n && n !== constructorDecl; n = n.parent) { - if (n.kind === 131 /* Parameter */) { - return true; - } - } - return false; - } - function checkSuperExpression(node) { - var isCallExpression = node.parent.kind === 160 /* CallExpression */ && node.parent.expression === node; - var enclosingClass = ts.getAncestor(node, 204 /* ClassDeclaration */); - var baseClass; - if (enclosingClass && ts.getClassExtendsHeritageClauseElement(enclosingClass)) { - var classType = getDeclaredTypeOfSymbol(getSymbolOfNode(enclosingClass)); - var baseTypes = getBaseTypes(classType); - baseClass = baseTypes.length && baseTypes[0]; - } - if (!baseClass) { - error(node, ts.Diagnostics.super_can_only_be_referenced_in_a_derived_class); - return unknownType; - } - var container = ts.getSuperContainer(node, true); - if (container) { - var canUseSuperExpression = false; - var needToCaptureLexicalThis; - if (isCallExpression) { - // TS 1.0 SPEC (April 2014): 4.8.1 - // Super calls are only permitted in constructors of derived classes - canUseSuperExpression = container.kind === 137 /* Constructor */; - } - else { - // TS 1.0 SPEC (April 2014) - // 'super' property access is allowed - // - In a constructor, instance member function, instance member accessor, or instance member variable initializer where this references a derived class instance - // - In a static member function or static member accessor - // super property access might appear in arrow functions with arbitrary deep nesting - needToCaptureLexicalThis = false; - while (container && container.kind === 166 /* ArrowFunction */) { - container = ts.getSuperContainer(container, true); - needToCaptureLexicalThis = languageVersion < 2 /* ES6 */; - } - // topmost container must be something that is directly nested in the class declaration - if (container && container.parent && container.parent.kind === 204 /* ClassDeclaration */) { - if (container.flags & 128 /* Static */) { - canUseSuperExpression = - container.kind === 136 /* MethodDeclaration */ || - container.kind === 135 /* MethodSignature */ || - container.kind === 138 /* GetAccessor */ || - container.kind === 139 /* SetAccessor */; - } - else { - canUseSuperExpression = - container.kind === 136 /* MethodDeclaration */ || - container.kind === 135 /* MethodSignature */ || - container.kind === 138 /* GetAccessor */ || - container.kind === 139 /* SetAccessor */ || - container.kind === 134 /* PropertyDeclaration */ || - container.kind === 133 /* PropertySignature */ || - container.kind === 137 /* Constructor */; - } - } - } - if (canUseSuperExpression) { - var returnType; - if ((container.flags & 128 /* Static */) || isCallExpression) { - getNodeLinks(node).flags |= 32 /* SuperStatic */; - returnType = getTypeOfSymbol(baseClass.symbol); - } - else { - getNodeLinks(node).flags |= 16 /* SuperInstance */; - returnType = baseClass; - } - if (container.kind === 137 /* Constructor */ && isInConstructorArgumentInitializer(node, container)) { - // issue custom error message for super property access in constructor arguments (to be aligned with old compiler) - error(node, ts.Diagnostics.super_cannot_be_referenced_in_constructor_arguments); - returnType = unknownType; - } - if (!isCallExpression && needToCaptureLexicalThis) { - // call expressions are allowed only in constructors so they should always capture correct 'this' - // super property access expressions can also appear in arrow functions - - // in this case they should also use correct lexical this - captureLexicalThis(node.parent, container); - } - return returnType; - } - } - if (container && container.kind === 129 /* ComputedPropertyName */) { - error(node, ts.Diagnostics.super_cannot_be_referenced_in_a_computed_property_name); - } - else if (isCallExpression) { - error(node, ts.Diagnostics.Super_calls_are_not_permitted_outside_constructors_or_in_nested_functions_inside_constructors); - } - else { - error(node, ts.Diagnostics.super_property_access_is_permitted_only_in_a_constructor_member_function_or_member_accessor_of_a_derived_class); - } - return unknownType; - } - // Return contextual type of parameter or undefined if no contextual type is available - function getContextuallyTypedParameterType(parameter) { - if (isFunctionExpressionOrArrowFunction(parameter.parent)) { - var func = parameter.parent; - if (isContextSensitive(func)) { - var contextualSignature = getContextualSignature(func); - if (contextualSignature) { - var funcHasRestParameters = ts.hasRestParameter(func); - var len = func.parameters.length - (funcHasRestParameters ? 1 : 0); - var indexOfParameter = ts.indexOf(func.parameters, parameter); - if (indexOfParameter < len) { - return getTypeAtPosition(contextualSignature, indexOfParameter); - } - // If last parameter is contextually rest parameter get its type - if (indexOfParameter === (func.parameters.length - 1) && - funcHasRestParameters && contextualSignature.hasRestParameter && func.parameters.length >= contextualSignature.parameters.length) { - return getTypeOfSymbol(ts.lastOrUndefined(contextualSignature.parameters)); - } - } - } - } - return undefined; - } - // In a variable, parameter or property declaration with a type annotation, the contextual type of an initializer - // expression is the type of the variable, parameter or property. Otherwise, in a parameter declaration of a - // contextually typed function expression, the contextual type of an initializer expression is the contextual type - // of the parameter. Otherwise, in a variable or parameter declaration with a binding pattern name, the contextual - // type of an initializer expression is the type implied by the binding pattern. - function getContextualTypeForInitializerExpression(node) { - var declaration = node.parent; - if (node === declaration.initializer) { - if (declaration.type) { - return getTypeFromTypeNode(declaration.type); - } - if (declaration.kind === 131 /* Parameter */) { - var type = getContextuallyTypedParameterType(declaration); - if (type) { - return type; - } - } - if (ts.isBindingPattern(declaration.name)) { - return getTypeFromBindingPattern(declaration.name); - } - } - return undefined; - } - function getContextualTypeForReturnExpression(node) { - var func = ts.getContainingFunction(node); - if (func && !func.asteriskToken) { - return getContextualReturnType(func); - } - return undefined; - } - function getContextualTypeForYieldOperand(node) { - var func = ts.getContainingFunction(node); - if (func) { - var contextualReturnType = getContextualReturnType(func); - if (contextualReturnType) { - return node.asteriskToken - ? contextualReturnType - : getElementTypeOfIterableIterator(contextualReturnType); - } - } - return undefined; - } - function getContextualReturnType(functionDecl) { - // If the containing function has a return type annotation, is a constructor, or is a get accessor whose - // corresponding set accessor has a type annotation, return statements in the function are contextually typed - if (functionDecl.type || - functionDecl.kind === 137 /* Constructor */ || - functionDecl.kind === 138 /* GetAccessor */ && getSetAccessorTypeAnnotationNode(ts.getDeclarationOfKind(functionDecl.symbol, 139 /* SetAccessor */))) { - return getReturnTypeOfSignature(getSignatureFromDeclaration(functionDecl)); - } - // Otherwise, if the containing function is contextually typed by a function type with exactly one call signature - // and that call signature is non-generic, return statements are contextually typed by the return type of the signature - var signature = getContextualSignatureForFunctionLikeDeclaration(functionDecl); - if (signature) { - return getReturnTypeOfSignature(signature); - } - return undefined; - } - // In a typed function call, an argument or substitution expression is contextually typed by the type of the corresponding parameter. - function getContextualTypeForArgument(callTarget, arg) { - var args = getEffectiveCallArguments(callTarget); - var argIndex = ts.indexOf(args, arg); - if (argIndex >= 0) { - var signature = getResolvedSignature(callTarget); - return getTypeAtPosition(signature, argIndex); - } - return undefined; - } - function getContextualTypeForSubstitutionExpression(template, substitutionExpression) { - if (template.parent.kind === 162 /* TaggedTemplateExpression */) { - return getContextualTypeForArgument(template.parent, substitutionExpression); - } - return undefined; - } - function getContextualTypeForBinaryOperand(node) { - var binaryExpression = node.parent; - var operator = binaryExpression.operatorToken.kind; - if (operator >= 53 /* FirstAssignment */ && operator <= 64 /* LastAssignment */) { - // In an assignment expression, the right operand is contextually typed by the type of the left operand. - if (node === binaryExpression.right) { - return checkExpression(binaryExpression.left); - } - } - else if (operator === 49 /* BarBarToken */) { - // When an || expression has a contextual type, the operands are contextually typed by that type. When an || - // expression has no contextual type, the right operand is contextually typed by the type of the left operand. - var type = getContextualType(binaryExpression); - if (!type && node === binaryExpression.right) { - type = checkExpression(binaryExpression.left); - } - return type; - } - return undefined; - } - // Apply a mapping function to a contextual type and return the resulting type. If the contextual type - // is a union type, the mapping function is applied to each constituent type and a union of the resulting - // types is returned. - function applyToContextualType(type, mapper) { - if (!(type.flags & 16384 /* Union */)) { - return mapper(type); - } - var types = type.types; - var mappedType; - var mappedTypes; - for (var _i = 0; _i < types.length; _i++) { - var current = types[_i]; - var t = mapper(current); - if (t) { - if (!mappedType) { - mappedType = t; - } - else if (!mappedTypes) { - mappedTypes = [mappedType, t]; - } - else { - mappedTypes.push(t); - } - } - } - return mappedTypes ? getUnionType(mappedTypes) : mappedType; - } - function getTypeOfPropertyOfContextualType(type, name) { - return applyToContextualType(type, function (t) { - var prop = getPropertyOfObjectType(t, name); - return prop ? getTypeOfSymbol(prop) : undefined; - }); - } - function getIndexTypeOfContextualType(type, kind) { - return applyToContextualType(type, function (t) { return getIndexTypeOfObjectOrUnionType(t, kind); }); - } - // Return true if the given contextual type is a tuple-like type - function contextualTypeIsTupleLikeType(type) { - return !!(type.flags & 16384 /* Union */ ? ts.forEach(type.types, isTupleLikeType) : isTupleLikeType(type)); - } - // Return true if the given contextual type provides an index signature of the given kind - function contextualTypeHasIndexSignature(type, kind) { - return !!(type.flags & 16384 /* Union */ ? ts.forEach(type.types, function (t) { return getIndexTypeOfObjectOrUnionType(t, kind); }) : getIndexTypeOfObjectOrUnionType(type, kind)); - } - // In an object literal contextually typed by a type T, the contextual type of a property assignment is the type of - // the matching property in T, if one exists. Otherwise, it is the type of the numeric index signature in T, if one - // exists. Otherwise, it is the type of the string index signature in T, if one exists. - function getContextualTypeForObjectLiteralMethod(node) { - ts.Debug.assert(ts.isObjectLiteralMethod(node)); - if (isInsideWithStatementBody(node)) { - // We cannot answer semantic questions within a with block, do not proceed any further - return undefined; - } - return getContextualTypeForObjectLiteralElement(node); - } - function getContextualTypeForObjectLiteralElement(element) { - var objectLiteral = element.parent; - var type = getContextualType(objectLiteral); - if (type) { - if (!ts.hasDynamicName(element)) { - // For a (non-symbol) computed property, there is no reason to look up the name - // in the type. It will just be "__computed", which does not appear in any - // SymbolTable. - var symbolName = getSymbolOfNode(element).name; - var propertyType = getTypeOfPropertyOfContextualType(type, symbolName); - if (propertyType) { - return propertyType; - } - } - return isNumericName(element.name) && getIndexTypeOfContextualType(type, 1 /* Number */) || - getIndexTypeOfContextualType(type, 0 /* String */); - } - return undefined; - } - // In an array literal contextually typed by a type T, the contextual type of an element expression at index N is - // the type of the property with the numeric name N in T, if one exists. Otherwise, if T has a numeric index signature, - // it is the type of the numeric index signature in T. Otherwise, in ES6 and higher, the contextual type is the iterated - // type of T. - function getContextualTypeForElementExpression(node) { - var arrayLiteral = node.parent; - var type = getContextualType(arrayLiteral); - if (type) { - var index = ts.indexOf(arrayLiteral.elements, node); - return getTypeOfPropertyOfContextualType(type, "" + index) - || getIndexTypeOfContextualType(type, 1 /* Number */) - || (languageVersion >= 2 /* ES6 */ ? getElementTypeOfIterable(type, undefined) : undefined); - } - return undefined; - } - // In a contextually typed conditional expression, the true/false expressions are contextually typed by the same type. - function getContextualTypeForConditionalOperand(node) { - var conditional = node.parent; - return node === conditional.whenTrue || node === conditional.whenFalse ? getContextualType(conditional) : undefined; - } - // Return the contextual type for a given expression node. During overload resolution, a contextual type may temporarily - // be "pushed" onto a node using the contextualType property. - function getContextualType(node) { - if (isInsideWithStatementBody(node)) { - // We cannot answer semantic questions within a with block, do not proceed any further - return undefined; - } - if (node.contextualType) { - return node.contextualType; - } - var parent = node.parent; - switch (parent.kind) { - case 201 /* VariableDeclaration */: - case 131 /* Parameter */: - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - case 155 /* BindingElement */: - return getContextualTypeForInitializerExpression(node); - case 166 /* ArrowFunction */: - case 194 /* ReturnStatement */: - return getContextualTypeForReturnExpression(node); - case 175 /* YieldExpression */: - return getContextualTypeForYieldOperand(parent); - case 160 /* CallExpression */: - case 161 /* NewExpression */: - return getContextualTypeForArgument(parent, node); - case 163 /* TypeAssertionExpression */: - return getTypeFromTypeNode(parent.type); - case 172 /* BinaryExpression */: - return getContextualTypeForBinaryOperand(node); - case 227 /* PropertyAssignment */: - return getContextualTypeForObjectLiteralElement(parent); - case 156 /* ArrayLiteralExpression */: - return getContextualTypeForElementExpression(node); - case 173 /* ConditionalExpression */: - return getContextualTypeForConditionalOperand(node); - case 180 /* TemplateSpan */: - ts.Debug.assert(parent.parent.kind === 174 /* TemplateExpression */); - return getContextualTypeForSubstitutionExpression(parent.parent, node); - case 164 /* ParenthesizedExpression */: - return getContextualType(parent); - } - return undefined; - } - // If the given type is an object or union type, if that type has a single signature, and if - // that signature is non-generic, return the signature. Otherwise return undefined. - function getNonGenericSignature(type) { - var signatures = getSignaturesOfObjectOrUnionType(type, 0 /* Call */); - if (signatures.length === 1) { - var signature = signatures[0]; - if (!signature.typeParameters) { - return signature; - } - } - } - function isFunctionExpressionOrArrowFunction(node) { - return node.kind === 165 /* FunctionExpression */ || node.kind === 166 /* ArrowFunction */; - } - function getContextualSignatureForFunctionLikeDeclaration(node) { - // Only function expressions, arrow functions, and object literal methods are contextually typed. - return isFunctionExpressionOrArrowFunction(node) || ts.isObjectLiteralMethod(node) - ? getContextualSignature(node) - : undefined; - } - // Return the contextual signature for a given expression node. A contextual type provides a - // contextual signature if it has a single call signature and if that call signature is non-generic. - // If the contextual type is a union type, get the signature from each type possible and if they are - // all identical ignoring their return type, the result is same signature but with return type as - // union type of return types from these signatures - function getContextualSignature(node) { - ts.Debug.assert(node.kind !== 136 /* MethodDeclaration */ || ts.isObjectLiteralMethod(node)); - var type = ts.isObjectLiteralMethod(node) - ? getContextualTypeForObjectLiteralMethod(node) - : getContextualType(node); - if (!type) { - return undefined; - } - if (!(type.flags & 16384 /* Union */)) { - return getNonGenericSignature(type); - } - var signatureList; - var types = type.types; - for (var _i = 0; _i < types.length; _i++) { - var current = types[_i]; - // The signature set of all constituent type with call signatures should match - // So number of signatures allowed is either 0 or 1 - if (signatureList && - getSignaturesOfObjectOrUnionType(current, 0 /* Call */).length > 1) { - return undefined; - } - var signature = getNonGenericSignature(current); - if (signature) { - if (!signatureList) { - // This signature will contribute to contextual union signature - signatureList = [signature]; - } - else if (!compareSignatures(signatureList[0], signature, false, compareTypes)) { - // Signatures aren't identical, do not use - return undefined; - } - else { - // Use this signature for contextual union signature - signatureList.push(signature); - } - } - } - // Result is union of signatures collected (return type is union of return types of this signature set) - var result; - if (signatureList) { - result = cloneSignature(signatureList[0]); - // Clear resolved return type we possibly got from cloneSignature - result.resolvedReturnType = undefined; - result.unionSignatures = signatureList; - } - return result; - } - // Presence of a contextual type mapper indicates inferential typing, except the identityMapper object is - // used as a special marker for other purposes. - function isInferentialContext(mapper) { - return mapper && mapper !== identityMapper; - } - // A node is an assignment target if it is on the left hand side of an '=' token, if it is parented by a property - // assignment in an object literal that is an assignment target, or if it is parented by an array literal that is - // an assignment target. Examples include 'a = xxx', '{ p: a } = xxx', '[{ p: a}] = xxx'. - function isAssignmentTarget(node) { - var parent = node.parent; - if (parent.kind === 172 /* BinaryExpression */ && parent.operatorToken.kind === 53 /* EqualsToken */ && parent.left === node) { - return true; - } - if (parent.kind === 227 /* PropertyAssignment */) { - return isAssignmentTarget(parent.parent); - } - if (parent.kind === 156 /* ArrayLiteralExpression */) { - return isAssignmentTarget(parent); - } - return false; - } - function checkSpreadElementExpression(node, contextualMapper) { - // It is usually not safe to call checkExpressionCached if we can be contextually typing. - // You can tell that we are contextually typing because of the contextualMapper parameter. - // While it is true that a spread element can have a contextual type, it does not do anything - // with this type. It is neither affected by it, nor does it propagate it to its operand. - // So the fact that contextualMapper is passed is not important, because the operand of a spread - // element is not contextually typed. - var arrayOrIterableType = checkExpressionCached(node.expression, contextualMapper); - return checkIteratedTypeOrElementType(arrayOrIterableType, node.expression, false); - } - function checkArrayLiteral(node, contextualMapper) { - var elements = node.elements; - if (!elements.length) { - return createArrayType(undefinedType); - } - var hasSpreadElement = false; - var elementTypes = []; - var inDestructuringPattern = isAssignmentTarget(node); - for (var _i = 0; _i < elements.length; _i++) { - var e = elements[_i]; - if (inDestructuringPattern && e.kind === 176 /* SpreadElementExpression */) { - // Given the following situation: - // var c: {}; - // [...c] = ["", 0]; - // - // c is represented in the tree as a spread element in an array literal. - // But c really functions as a rest element, and its purpose is to provide - // a contextual type for the right hand side of the assignment. Therefore, - // instead of calling checkExpression on "...c", which will give an error - // if c is not iterable/array-like, we need to act as if we are trying to - // get the contextual element type from it. So we do something similar to - // getContextualTypeForElementExpression, which will crucially not error - // if there is no index type / iterated type. - var restArrayType = checkExpression(e.expression, contextualMapper); - var restElementType = getIndexTypeOfType(restArrayType, 1 /* Number */) || - (languageVersion >= 2 /* ES6 */ ? getElementTypeOfIterable(restArrayType, undefined) : undefined); - if (restElementType) { - elementTypes.push(restElementType); - } - } - else { - var type = checkExpression(e, contextualMapper); - elementTypes.push(type); - } - hasSpreadElement = hasSpreadElement || e.kind === 176 /* SpreadElementExpression */; - } - if (!hasSpreadElement) { - var contextualType = getContextualType(node); - if (contextualType && contextualTypeIsTupleLikeType(contextualType) || inDestructuringPattern) { - return createTupleType(elementTypes); - } - } - return createArrayType(getUnionType(elementTypes)); - } - function isNumericName(name) { - return name.kind === 129 /* ComputedPropertyName */ ? isNumericComputedName(name) : isNumericLiteralName(name.text); - } - function isNumericComputedName(name) { - // It seems odd to consider an expression of type Any to result in a numeric name, - // but this behavior is consistent with checkIndexedAccess - return isTypeAnyOrAllConstituentTypesHaveKind(checkComputedPropertyName(name), 132 /* NumberLike */); - } - function isTypeAnyOrAllConstituentTypesHaveKind(type, kind) { - return isTypeAny(type) || allConstituentTypesHaveKind(type, kind); - } - function isNumericLiteralName(name) { - // The intent of numeric names is that - // - they are names with text in a numeric form, and that - // - setting properties/indexing with them is always equivalent to doing so with the numeric literal 'numLit', - // acquired by applying the abstract 'ToNumber' operation on the name's text. - // - // The subtlety is in the latter portion, as we cannot reliably say that anything that looks like a numeric literal is a numeric name. - // In fact, it is the case that the text of the name must be equal to 'ToString(numLit)' for this to hold. - // - // Consider the property name '"0xF00D"'. When one indexes with '0xF00D', they are actually indexing with the value of 'ToString(0xF00D)' - // according to the ECMAScript specification, so it is actually as if the user indexed with the string '"61453"'. - // Thus, the text of all numeric literals equivalent to '61543' such as '0xF00D', '0xf00D', '0170015', etc. are not valid numeric names - // because their 'ToString' representation is not equal to their original text. - // This is motivated by ECMA-262 sections 9.3.1, 9.8.1, 11.1.5, and 11.2.1. - // - // Here, we test whether 'ToString(ToNumber(name))' is exactly equal to 'name'. - // The '+' prefix operator is equivalent here to applying the abstract ToNumber operation. - // Applying the 'toString()' method on a number gives us the abstract ToString operation on a number. - // - // Note that this accepts the values 'Infinity', '-Infinity', and 'NaN', and that this is intentional. - // This is desired behavior, because when indexing with them as numeric entities, you are indexing - // with the strings '"Infinity"', '"-Infinity"', and '"NaN"' respectively. - return (+name).toString() === name; - } - function checkComputedPropertyName(node) { - var links = getNodeLinks(node.expression); - if (!links.resolvedType) { - links.resolvedType = checkExpression(node.expression); - // This will allow types number, string, symbol or any. It will also allow enums, the unknown - // type, and any union of these types (like string | number). - if (!isTypeAnyOrAllConstituentTypesHaveKind(links.resolvedType, 132 /* NumberLike */ | 258 /* StringLike */ | 2097152 /* ESSymbol */)) { - error(node, ts.Diagnostics.A_computed_property_name_must_be_of_type_string_number_symbol_or_any); - } - else { - checkThatExpressionIsProperSymbolReference(node.expression, links.resolvedType, true); - } - } - return links.resolvedType; - } - function checkObjectLiteral(node, contextualMapper) { - // Grammar checking - checkGrammarObjectLiteralExpression(node); - var propertiesTable = {}; - var propertiesArray = []; - var contextualType = getContextualType(node); - var typeFlags; - for (var _i = 0, _a = node.properties; _i < _a.length; _i++) { - var memberDecl = _a[_i]; - var member = memberDecl.symbol; - if (memberDecl.kind === 227 /* PropertyAssignment */ || - memberDecl.kind === 228 /* ShorthandPropertyAssignment */ || - ts.isObjectLiteralMethod(memberDecl)) { - var type = void 0; - if (memberDecl.kind === 227 /* PropertyAssignment */) { - type = checkPropertyAssignment(memberDecl, contextualMapper); - } - else if (memberDecl.kind === 136 /* MethodDeclaration */) { - type = checkObjectLiteralMethod(memberDecl, contextualMapper); - } - else { - ts.Debug.assert(memberDecl.kind === 228 /* ShorthandPropertyAssignment */); - type = checkExpression(memberDecl.name, contextualMapper); - } - typeFlags |= type.flags; - var prop = createSymbol(4 /* Property */ | 67108864 /* Transient */ | member.flags, member.name); - prop.declarations = member.declarations; - prop.parent = member.parent; - if (member.valueDeclaration) { - prop.valueDeclaration = member.valueDeclaration; - } - prop.type = type; - prop.target = member; - member = prop; - } - else { - // TypeScript 1.0 spec (April 2014) - // A get accessor declaration is processed in the same manner as - // an ordinary function declaration(section 6.1) with no parameters. - // A set accessor declaration is processed in the same manner - // as an ordinary function declaration with a single parameter and a Void return type. - ts.Debug.assert(memberDecl.kind === 138 /* GetAccessor */ || memberDecl.kind === 139 /* SetAccessor */); - checkAccessorDeclaration(memberDecl); - } - if (!ts.hasDynamicName(memberDecl)) { - propertiesTable[member.name] = member; - } - propertiesArray.push(member); - } - var stringIndexType = getIndexType(0 /* String */); - var numberIndexType = getIndexType(1 /* Number */); - var result = createAnonymousType(node.symbol, propertiesTable, emptyArray, emptyArray, stringIndexType, numberIndexType); - result.flags |= 262144 /* ObjectLiteral */ | 1048576 /* ContainsObjectLiteral */ | (typeFlags & 524288 /* ContainsUndefinedOrNull */); - return result; - function getIndexType(kind) { - if (contextualType && contextualTypeHasIndexSignature(contextualType, kind)) { - var propTypes = []; - for (var i = 0; i < propertiesArray.length; i++) { - var propertyDecl = node.properties[i]; - if (kind === 0 /* String */ || isNumericName(propertyDecl.name)) { - // Do not call getSymbolOfNode(propertyDecl), as that will get the - // original symbol for the node. We actually want to get the symbol - // created by checkObjectLiteral, since that will be appropriately - // contextually typed and resolved. - var type = getTypeOfSymbol(propertiesArray[i]); - if (!ts.contains(propTypes, type)) { - propTypes.push(type); - } - } - } - var result_1 = propTypes.length ? getUnionType(propTypes) : undefinedType; - typeFlags |= result_1.flags; - return result_1; - } - return undefined; - } - } - // If a symbol is a synthesized symbol with no value declaration, we assume it is a property. Example of this are the synthesized - // '.prototype' property as well as synthesized tuple index properties. - function getDeclarationKindFromSymbol(s) { - return s.valueDeclaration ? s.valueDeclaration.kind : 134 /* PropertyDeclaration */; - } - function getDeclarationFlagsFromSymbol(s) { - return s.valueDeclaration ? ts.getCombinedNodeFlags(s.valueDeclaration) : s.flags & 134217728 /* Prototype */ ? 16 /* Public */ | 128 /* Static */ : 0; - } - function checkClassPropertyAccess(node, left, type, prop) { - var flags = getDeclarationFlagsFromSymbol(prop); - // Public properties are always accessible - if (!(flags & (32 /* Private */ | 64 /* Protected */))) { - return; - } - // Property is known to be private or protected at this point - // Get the declaring and enclosing class instance types - var enclosingClassDeclaration = ts.getAncestor(node, 204 /* ClassDeclaration */); - var enclosingClass = enclosingClassDeclaration ? getDeclaredTypeOfSymbol(getSymbolOfNode(enclosingClassDeclaration)) : undefined; - var declaringClass = getDeclaredTypeOfSymbol(prop.parent); - // Private property is accessible if declaring and enclosing class are the same - if (flags & 32 /* Private */) { - if (declaringClass !== enclosingClass) { - error(node, ts.Diagnostics.Property_0_is_private_and_only_accessible_within_class_1, symbolToString(prop), typeToString(declaringClass)); - } - return; - } - // Property is known to be protected at this point - // All protected properties of a supertype are accessible in a super access - if (left.kind === 91 /* SuperKeyword */) { - return; - } - // A protected property is accessible in the declaring class and classes derived from it - if (!enclosingClass || !hasBaseType(enclosingClass, declaringClass)) { - error(node, ts.Diagnostics.Property_0_is_protected_and_only_accessible_within_class_1_and_its_subclasses, symbolToString(prop), typeToString(declaringClass)); - return; - } - // No further restrictions for static properties - if (flags & 128 /* Static */) { - return; - } - // An instance property must be accessed through an instance of the enclosing class - if (!(getTargetType(type).flags & (1024 /* Class */ | 2048 /* Interface */) && hasBaseType(type, enclosingClass))) { - error(node, ts.Diagnostics.Property_0_is_protected_and_only_accessible_through_an_instance_of_class_1, symbolToString(prop), typeToString(enclosingClass)); - } - } - function checkPropertyAccessExpression(node) { - return checkPropertyAccessExpressionOrQualifiedName(node, node.expression, node.name); - } - function checkQualifiedName(node) { - return checkPropertyAccessExpressionOrQualifiedName(node, node.left, node.right); - } - function checkPropertyAccessExpressionOrQualifiedName(node, left, right) { - var type = checkExpressionOrQualifiedName(left); - if (isTypeAny(type)) { - return type; - } - var apparentType = getApparentType(getWidenedType(type)); - if (apparentType === unknownType) { - // handle cases when type is Type parameter with invalid constraint - return unknownType; - } - var prop = getPropertyOfType(apparentType, right.text); - if (!prop) { - if (right.text) { - error(right, ts.Diagnostics.Property_0_does_not_exist_on_type_1, ts.declarationNameToString(right), typeToString(type)); - } - return unknownType; - } - getNodeLinks(node).resolvedSymbol = prop; - if (prop.parent && prop.parent.flags & 32 /* Class */) { - // TS 1.0 spec (April 2014): 4.8.2 - // - In a constructor, instance member function, instance member accessor, or - // instance member variable initializer where this references a derived class instance, - // a super property access is permitted and must specify a public instance member function of the base class. - // - In a static member function or static member accessor - // where this references the constructor function object of a derived class, - // a super property access is permitted and must specify a public static member function of the base class. - if (left.kind === 91 /* SuperKeyword */ && getDeclarationKindFromSymbol(prop) !== 136 /* MethodDeclaration */) { - error(right, ts.Diagnostics.Only_public_and_protected_methods_of_the_base_class_are_accessible_via_the_super_keyword); - } - else { - checkClassPropertyAccess(node, left, type, prop); - } - } - return getTypeOfSymbol(prop); - } - function isValidPropertyAccess(node, propertyName) { - var left = node.kind === 158 /* PropertyAccessExpression */ - ? node.expression - : node.left; - var type = checkExpressionOrQualifiedName(left); - if (type !== unknownType && !isTypeAny(type)) { - var prop = getPropertyOfType(getWidenedType(type), propertyName); - if (prop && prop.parent && prop.parent.flags & 32 /* Class */) { - if (left.kind === 91 /* SuperKeyword */ && getDeclarationKindFromSymbol(prop) !== 136 /* MethodDeclaration */) { - return false; - } - else { - var modificationCount = diagnostics.getModificationCount(); - checkClassPropertyAccess(node, left, type, prop); - return diagnostics.getModificationCount() === modificationCount; - } - } - } - return true; - } - function checkIndexedAccess(node) { - // Grammar checking - if (!node.argumentExpression) { - var sourceFile = getSourceFile(node); - if (node.parent.kind === 161 /* NewExpression */ && node.parent.expression === node) { - var start = ts.skipTrivia(sourceFile.text, node.expression.end); - var end = node.end; - grammarErrorAtPos(sourceFile, start, end - start, ts.Diagnostics.new_T_cannot_be_used_to_create_an_array_Use_new_Array_T_instead); - } - else { - var start = node.end - "]".length; - var end = node.end; - grammarErrorAtPos(sourceFile, start, end - start, ts.Diagnostics.Expression_expected); - } - } - // Obtain base constraint such that we can bail out if the constraint is an unknown type - var objectType = getApparentType(checkExpression(node.expression)); - var indexType = node.argumentExpression ? checkExpression(node.argumentExpression) : unknownType; - if (objectType === unknownType) { - return unknownType; - } - var isConstEnum = isConstEnumObjectType(objectType); - if (isConstEnum && - (!node.argumentExpression || node.argumentExpression.kind !== 8 /* StringLiteral */)) { - error(node.argumentExpression, ts.Diagnostics.A_const_enum_member_can_only_be_accessed_using_a_string_literal); - return unknownType; - } - // TypeScript 1.0 spec (April 2014): 4.10 Property Access - // - If IndexExpr is a string literal or a numeric literal and ObjExpr's apparent type has a property with the name - // given by that literal(converted to its string representation in the case of a numeric literal), the property access is of the type of that property. - // - Otherwise, if ObjExpr's apparent type has a numeric index signature and IndexExpr is of type Any, the Number primitive type, or an enum type, - // the property access is of the type of that index signature. - // - Otherwise, if ObjExpr's apparent type has a string index signature and IndexExpr is of type Any, the String or Number primitive type, or an enum type, - // the property access is of the type of that index signature. - // - Otherwise, if IndexExpr is of type Any, the String or Number primitive type, or an enum type, the property access is of type Any. - // See if we can index as a property. - if (node.argumentExpression) { - var name_10 = getPropertyNameForIndexedAccess(node.argumentExpression, indexType); - if (name_10 !== undefined) { - var prop = getPropertyOfType(objectType, name_10); - if (prop) { - getNodeLinks(node).resolvedSymbol = prop; - return getTypeOfSymbol(prop); - } - else if (isConstEnum) { - error(node.argumentExpression, ts.Diagnostics.Property_0_does_not_exist_on_const_enum_1, name_10, symbolToString(objectType.symbol)); - return unknownType; - } - } - } - // Check for compatible indexer types. - if (isTypeAnyOrAllConstituentTypesHaveKind(indexType, 258 /* StringLike */ | 132 /* NumberLike */ | 2097152 /* ESSymbol */)) { - // Try to use a number indexer. - if (isTypeAnyOrAllConstituentTypesHaveKind(indexType, 132 /* NumberLike */)) { - var numberIndexType = getIndexTypeOfType(objectType, 1 /* Number */); - if (numberIndexType) { - return numberIndexType; - } - } - // Try to use string indexing. - var stringIndexType = getIndexTypeOfType(objectType, 0 /* String */); - if (stringIndexType) { - return stringIndexType; - } - // Fall back to any. - if (compilerOptions.noImplicitAny && !compilerOptions.suppressImplicitAnyIndexErrors && !isTypeAny(objectType)) { - error(node, ts.Diagnostics.Index_signature_of_object_type_implicitly_has_an_any_type); - } - return anyType; - } - // REVIEW: Users should know the type that was actually used. - error(node, ts.Diagnostics.An_index_expression_argument_must_be_of_type_string_number_symbol_or_any); - return unknownType; - } - /** - * If indexArgumentExpression is a string literal or number literal, returns its text. - * If indexArgumentExpression is a well known symbol, returns the property name corresponding - * to this symbol, as long as it is a proper symbol reference. - * Otherwise, returns undefined. - */ - function getPropertyNameForIndexedAccess(indexArgumentExpression, indexArgumentType) { - if (indexArgumentExpression.kind === 8 /* StringLiteral */ || indexArgumentExpression.kind === 7 /* NumericLiteral */) { - return indexArgumentExpression.text; - } - if (checkThatExpressionIsProperSymbolReference(indexArgumentExpression, indexArgumentType, false)) { - var rightHandSideName = indexArgumentExpression.name.text; - return ts.getPropertyNameForKnownSymbolName(rightHandSideName); - } - return undefined; - } - /** - * A proper symbol reference requires the following: - * 1. The property access denotes a property that exists - * 2. The expression is of the form Symbol. - * 3. The property access is of the primitive type symbol. - * 4. Symbol in this context resolves to the global Symbol object - */ - function checkThatExpressionIsProperSymbolReference(expression, expressionType, reportError) { - if (expressionType === unknownType) { - // There is already an error, so no need to report one. - return false; - } - if (!ts.isWellKnownSymbolSyntactically(expression)) { - return false; - } - // Make sure the property type is the primitive symbol type - if ((expressionType.flags & 2097152 /* ESSymbol */) === 0) { - if (reportError) { - error(expression, ts.Diagnostics.A_computed_property_name_of_the_form_0_must_be_of_type_symbol, ts.getTextOfNode(expression)); - } - return false; - } - // The name is Symbol., so make sure Symbol actually resolves to the - // global Symbol object - var leftHandSide = expression.expression; - var leftHandSideSymbol = getResolvedSymbol(leftHandSide); - if (!leftHandSideSymbol) { - return false; - } - var globalESSymbol = getGlobalESSymbolConstructorSymbol(); - if (!globalESSymbol) { - // Already errored when we tried to look up the symbol - return false; - } - if (leftHandSideSymbol !== globalESSymbol) { - if (reportError) { - error(leftHandSide, ts.Diagnostics.Symbol_reference_does_not_refer_to_the_global_Symbol_constructor_object); - } - return false; - } - return true; - } - function resolveUntypedCall(node) { - if (node.kind === 162 /* TaggedTemplateExpression */) { - checkExpression(node.template); - } - else { - ts.forEach(node.arguments, function (argument) { - checkExpression(argument); - }); - } - return anySignature; - } - function resolveErrorCall(node) { - resolveUntypedCall(node); - return unknownSignature; - } - // Re-order candidate signatures into the result array. Assumes the result array to be empty. - // The candidate list orders groups in reverse, but within a group signatures are kept in declaration order - // A nit here is that we reorder only signatures that belong to the same symbol, - // so order how inherited signatures are processed is still preserved. - // interface A { (x: string): void } - // interface B extends A { (x: 'foo'): string } - // let b: B; - // b('foo') // <- here overloads should be processed as [(x:'foo'): string, (x: string): void] - function reorderCandidates(signatures, result) { - var lastParent; - var lastSymbol; - var cutoffIndex = 0; - var index; - var specializedIndex = -1; - var spliceIndex; - ts.Debug.assert(!result.length); - for (var _i = 0; _i < signatures.length; _i++) { - var signature = signatures[_i]; - var symbol = signature.declaration && getSymbolOfNode(signature.declaration); - var parent_6 = signature.declaration && signature.declaration.parent; - if (!lastSymbol || symbol === lastSymbol) { - if (lastParent && parent_6 === lastParent) { - index++; - } - else { - lastParent = parent_6; - index = cutoffIndex; - } - } - else { - // current declaration belongs to a different symbol - // set cutoffIndex so re-orderings in the future won't change result set from 0 to cutoffIndex - index = cutoffIndex = result.length; - lastParent = parent_6; - } - lastSymbol = symbol; - // specialized signatures always need to be placed before non-specialized signatures regardless - // of the cutoff position; see GH#1133 - if (signature.hasStringLiterals) { - specializedIndex++; - spliceIndex = specializedIndex; - // The cutoff index always needs to be greater than or equal to the specialized signature index - // in order to prevent non-specialized signatures from being added before a specialized - // signature. - cutoffIndex++; - } - else { - spliceIndex = index; - } - result.splice(spliceIndex, 0, signature); - } - } - function getSpreadArgumentIndex(args) { - for (var i = 0; i < args.length; i++) { - if (args[i].kind === 176 /* SpreadElementExpression */) { - return i; - } - } - return -1; - } - function hasCorrectArity(node, args, signature) { - var adjustedArgCount; // Apparent number of arguments we will have in this call - var typeArguments; // Type arguments (undefined if none) - var callIsIncomplete; // In incomplete call we want to be lenient when we have too few arguments - if (node.kind === 162 /* TaggedTemplateExpression */) { - var tagExpression = node; - // Even if the call is incomplete, we'll have a missing expression as our last argument, - // so we can say the count is just the arg list length - adjustedArgCount = args.length; - typeArguments = undefined; - if (tagExpression.template.kind === 174 /* TemplateExpression */) { - // If a tagged template expression lacks a tail literal, the call is incomplete. - // Specifically, a template only can end in a TemplateTail or a Missing literal. - var templateExpression = tagExpression.template; - var lastSpan = ts.lastOrUndefined(templateExpression.templateSpans); - ts.Debug.assert(lastSpan !== undefined); // we should always have at least one span. - callIsIncomplete = ts.nodeIsMissing(lastSpan.literal) || !!lastSpan.literal.isUnterminated; - } - else { - // If the template didn't end in a backtick, or its beginning occurred right prior to EOF, - // then this might actually turn out to be a TemplateHead in the future; - // so we consider the call to be incomplete. - var templateLiteral = tagExpression.template; - ts.Debug.assert(templateLiteral.kind === 10 /* NoSubstitutionTemplateLiteral */); - callIsIncomplete = !!templateLiteral.isUnterminated; - } - } - else { - var callExpression = node; - if (!callExpression.arguments) { - // This only happens when we have something of the form: 'new C' - ts.Debug.assert(callExpression.kind === 161 /* NewExpression */); - return signature.minArgumentCount === 0; - } - // For IDE scenarios we may have an incomplete call, so a trailing comma is tantamount to adding another argument. - adjustedArgCount = callExpression.arguments.hasTrailingComma ? args.length + 1 : args.length; - // If we are missing the close paren, the call is incomplete. - callIsIncomplete = callExpression.arguments.end === callExpression.end; - typeArguments = callExpression.typeArguments; - } - // If the user supplied type arguments, but the number of type arguments does not match - // the declared number of type parameters, the call has an incorrect arity. - var hasRightNumberOfTypeArgs = !typeArguments || - (signature.typeParameters && typeArguments.length === signature.typeParameters.length); - if (!hasRightNumberOfTypeArgs) { - return false; - } - // If spread arguments are present, check that they correspond to a rest parameter. If so, no - // further checking is necessary. - var spreadArgIndex = getSpreadArgumentIndex(args); - if (spreadArgIndex >= 0) { - return signature.hasRestParameter && spreadArgIndex >= signature.parameters.length - 1; - } - // Too many arguments implies incorrect arity. - if (!signature.hasRestParameter && adjustedArgCount > signature.parameters.length) { - return false; - } - // If the call is incomplete, we should skip the lower bound check. - var hasEnoughArguments = adjustedArgCount >= signature.minArgumentCount; - return callIsIncomplete || hasEnoughArguments; - } - // If type has a single call signature and no other members, return that signature. Otherwise, return undefined. - function getSingleCallSignature(type) { - if (type.flags & 48128 /* ObjectType */) { - var resolved = resolveObjectOrUnionTypeMembers(type); - if (resolved.callSignatures.length === 1 && resolved.constructSignatures.length === 0 && - resolved.properties.length === 0 && !resolved.stringIndexType && !resolved.numberIndexType) { - return resolved.callSignatures[0]; - } - } - return undefined; - } - // Instantiate a generic signature in the context of a non-generic signature (section 3.8.5 in TypeScript spec) - function instantiateSignatureInContextOf(signature, contextualSignature, contextualMapper) { - var context = createInferenceContext(signature.typeParameters, true); - forEachMatchingParameterType(contextualSignature, signature, function (source, target) { - // Type parameters from outer context referenced by source type are fixed by instantiation of the source type - inferTypes(context, instantiateType(source, contextualMapper), target); - }); - return getSignatureInstantiation(signature, getInferredTypes(context)); - } - function inferTypeArguments(signature, args, excludeArgument, context) { - var typeParameters = signature.typeParameters; - var inferenceMapper = createInferenceMapper(context); - // Clear out all the inference results from the last time inferTypeArguments was called on this context - for (var i = 0; i < typeParameters.length; i++) { - // As an optimization, we don't have to clear (and later recompute) inferred types - // for type parameters that have already been fixed on the previous call to inferTypeArguments. - // It would be just as correct to reset all of them. But then we'd be repeating the same work - // for the type parameters that were fixed, namely the work done by getInferredType. - if (!context.inferences[i].isFixed) { - context.inferredTypes[i] = undefined; - } - } - // On this call to inferTypeArguments, we may get more inferences for certain type parameters that were not - // fixed last time. This means that a type parameter that failed inference last time may succeed this time, - // or vice versa. Therefore, the failedTypeParameterIndex is useless if it points to an unfixed type parameter, - // because it may change. So here we reset it. However, getInferredType will not revisit any type parameters - // that were previously fixed. So if a fixed type parameter failed previously, it will fail again because - // it will contain the exact same set of inferences. So if we reset the index from a fixed type parameter, - // we will lose information that we won't recover this time around. - if (context.failedTypeParameterIndex !== undefined && !context.inferences[context.failedTypeParameterIndex].isFixed) { - context.failedTypeParameterIndex = undefined; - } - // We perform two passes over the arguments. In the first pass we infer from all arguments, but use - // wildcards for all context sensitive function expressions. - for (var i = 0; i < args.length; i++) { - var arg = args[i]; - if (arg.kind !== 178 /* OmittedExpression */) { - var paramType = getTypeAtPosition(signature, i); - var argType = void 0; - if (i === 0 && args[i].parent.kind === 162 /* TaggedTemplateExpression */) { - argType = globalTemplateStringsArrayType; - } - else { - // For context sensitive arguments we pass the identityMapper, which is a signal to treat all - // context sensitive function expressions as wildcards - var mapper = excludeArgument && excludeArgument[i] !== undefined ? identityMapper : inferenceMapper; - argType = checkExpressionWithContextualType(arg, paramType, mapper); - } - inferTypes(context, argType, paramType); - } - } - // In the second pass we visit only context sensitive arguments, and only those that aren't excluded, this - // time treating function expressions normally (which may cause previously inferred type arguments to be fixed - // as we construct types for contextually typed parameters) - if (excludeArgument) { - for (var i = 0; i < args.length; i++) { - // No need to check for omitted args and template expressions, their exlusion value is always undefined - if (excludeArgument[i] === false) { - var arg = args[i]; - var paramType = getTypeAtPosition(signature, i); - inferTypes(context, checkExpressionWithContextualType(arg, paramType, inferenceMapper), paramType); - } - } - } - getInferredTypes(context); - } - function checkTypeArguments(signature, typeArguments, typeArgumentResultTypes, reportErrors) { - var typeParameters = signature.typeParameters; - var typeArgumentsAreAssignable = true; - for (var i = 0; i < typeParameters.length; i++) { - var typeArgNode = typeArguments[i]; - var typeArgument = getTypeFromTypeNode(typeArgNode); - // Do not push on this array! It has a preallocated length - typeArgumentResultTypes[i] = typeArgument; - if (typeArgumentsAreAssignable /* so far */) { - var constraint = getConstraintOfTypeParameter(typeParameters[i]); - if (constraint) { - typeArgumentsAreAssignable = checkTypeAssignableTo(typeArgument, constraint, reportErrors ? typeArgNode : undefined, ts.Diagnostics.Type_0_does_not_satisfy_the_constraint_1); - } - } - } - return typeArgumentsAreAssignable; - } - function checkApplicableSignature(node, args, signature, relation, excludeArgument, reportErrors) { - for (var i = 0; i < args.length; i++) { - var arg = args[i]; - if (arg.kind !== 178 /* OmittedExpression */) { - // Check spread elements against rest type (from arity check we know spread argument corresponds to a rest parameter) - var paramType = getTypeAtPosition(signature, i); - // A tagged template expression provides a special first argument, and string literals get string literal types - // unless we're reporting errors - var argType = i === 0 && node.kind === 162 /* TaggedTemplateExpression */ - ? globalTemplateStringsArrayType - : arg.kind === 8 /* StringLiteral */ && !reportErrors - ? getStringLiteralType(arg) - : checkExpressionWithContextualType(arg, paramType, excludeArgument && excludeArgument[i] ? identityMapper : undefined); - // Use argument expression as error location when reporting errors - if (!checkTypeRelatedTo(argType, paramType, relation, reportErrors ? arg : undefined, ts.Diagnostics.Argument_of_type_0_is_not_assignable_to_parameter_of_type_1)) { - return false; - } - } - } - return true; - } - /** - * Returns the effective arguments for an expression that works like a function invocation. - * - * If 'node' is a CallExpression or a NewExpression, then its argument list is returned. - * If 'node' is a TaggedTemplateExpression, a new argument list is constructed from the substitution - * expressions, where the first element of the list is the template for error reporting purposes. - */ - function getEffectiveCallArguments(node) { - var args; - if (node.kind === 162 /* TaggedTemplateExpression */) { - var template = node.template; - args = [template]; - if (template.kind === 174 /* TemplateExpression */) { - ts.forEach(template.templateSpans, function (span) { - args.push(span.expression); - }); - } - } - else { - args = node.arguments || emptyArray; - } - return args; - } - /** - * In a 'super' call, type arguments are not provided within the CallExpression node itself. - * Instead, they must be fetched from the class declaration's base type node. - * - * If 'node' is a 'super' call (e.g. super(...), new super(...)), then we attempt to fetch - * the type arguments off the containing class's first heritage clause (if one exists). Note that if - * type arguments are supplied on the 'super' call, they are ignored (though this is syntactically incorrect). - * - * In all other cases, the call's explicit type arguments are returned. - */ - function getEffectiveTypeArguments(callExpression) { - if (callExpression.expression.kind === 91 /* SuperKeyword */) { - var containingClass = ts.getAncestor(callExpression, 204 /* ClassDeclaration */); - var baseClassTypeNode = containingClass && ts.getClassExtendsHeritageClauseElement(containingClass); - return baseClassTypeNode && baseClassTypeNode.typeArguments; - } - else { - // Ordinary case - simple function invocation. - return callExpression.typeArguments; - } - } - function resolveCall(node, signatures, candidatesOutArray) { - var isTaggedTemplate = node.kind === 162 /* TaggedTemplateExpression */; - var typeArguments; - if (!isTaggedTemplate) { - typeArguments = getEffectiveTypeArguments(node); - // We already perform checking on the type arguments on the class declaration itself. - if (node.expression.kind !== 91 /* SuperKeyword */) { - ts.forEach(typeArguments, checkSourceElement); - } - } - var candidates = candidatesOutArray || []; - // reorderCandidates fills up the candidates array directly - reorderCandidates(signatures, candidates); - if (!candidates.length) { - error(node, ts.Diagnostics.Supplied_parameters_do_not_match_any_signature_of_call_target); - return resolveErrorCall(node); - } - var args = getEffectiveCallArguments(node); - // The following applies to any value of 'excludeArgument[i]': - // - true: the argument at 'i' is susceptible to a one-time permanent contextual typing. - // - undefined: the argument at 'i' is *not* susceptible to permanent contextual typing. - // - false: the argument at 'i' *was* and *has been* permanently contextually typed. - // - // The idea is that we will perform type argument inference & assignability checking once - // without using the susceptible parameters that are functions, and once more for each of those - // parameters, contextually typing each as we go along. - // - // For a tagged template, then the first argument be 'undefined' if necessary - // because it represents a TemplateStringsArray. - var excludeArgument; - for (var i = isTaggedTemplate ? 1 : 0; i < args.length; i++) { - if (isContextSensitive(args[i])) { - if (!excludeArgument) { - excludeArgument = new Array(args.length); - } - excludeArgument[i] = true; - } - } - // The following variables are captured and modified by calls to chooseOverload. - // If overload resolution or type argument inference fails, we want to report the - // best error possible. The best error is one which says that an argument was not - // assignable to a parameter. This implies that everything else about the overload - // was fine. So if there is any overload that is only incorrect because of an - // argument, we will report an error on that one. - // - // function foo(s: string) {} - // function foo(n: number) {} // Report argument error on this overload - // function foo() {} - // foo(true); - // - // If none of the overloads even made it that far, there are two possibilities. - // There was a problem with type arguments for some overload, in which case - // report an error on that. Or none of the overloads even had correct arity, - // in which case give an arity error. - // - // function foo(x: T, y: T) {} // Report type argument inference error - // function foo() {} - // foo(0, true); - // - var candidateForArgumentError; - var candidateForTypeArgumentError; - var resultOfFailedInference; - var result; - // Section 4.12.1: - // if the candidate list contains one or more signatures for which the type of each argument - // expression is a subtype of each corresponding parameter type, the return type of the first - // of those signatures becomes the return type of the function call. - // Otherwise, the return type of the first signature in the candidate list becomes the return - // type of the function call. - // - // Whether the call is an error is determined by assignability of the arguments. The subtype pass - // is just important for choosing the best signature. So in the case where there is only one - // signature, the subtype pass is useless. So skipping it is an optimization. - if (candidates.length > 1) { - result = chooseOverload(candidates, subtypeRelation); - } - if (!result) { - // Reinitialize these pointers for round two - candidateForArgumentError = undefined; - candidateForTypeArgumentError = undefined; - resultOfFailedInference = undefined; - result = chooseOverload(candidates, assignableRelation); - } - if (result) { - return result; - } - // No signatures were applicable. Now report errors based on the last applicable signature with - // no arguments excluded from assignability checks. - // If candidate is undefined, it means that no candidates had a suitable arity. In that case, - // skip the checkApplicableSignature check. - if (candidateForArgumentError) { - // excludeArgument is undefined, in this case also equivalent to [undefined, undefined, ...] - // The importance of excludeArgument is to prevent us from typing function expression parameters - // in arguments too early. If possible, we'd like to only type them once we know the correct - // overload. However, this matters for the case where the call is correct. When the call is - // an error, we don't need to exclude any arguments, although it would cause no harm to do so. - checkApplicableSignature(node, args, candidateForArgumentError, assignableRelation, undefined, true); - } - else if (candidateForTypeArgumentError) { - if (!isTaggedTemplate && typeArguments) { - checkTypeArguments(candidateForTypeArgumentError, typeArguments, [], true); - } - else { - ts.Debug.assert(resultOfFailedInference.failedTypeParameterIndex >= 0); - var failedTypeParameter = candidateForTypeArgumentError.typeParameters[resultOfFailedInference.failedTypeParameterIndex]; - var inferenceCandidates = getInferenceCandidates(resultOfFailedInference, resultOfFailedInference.failedTypeParameterIndex); - var diagnosticChainHead = ts.chainDiagnosticMessages(undefined, ts.Diagnostics.The_type_argument_for_type_parameter_0_cannot_be_inferred_from_the_usage_Consider_specifying_the_type_arguments_explicitly, typeToString(failedTypeParameter)); - reportNoCommonSupertypeError(inferenceCandidates, node.expression || node.tag, diagnosticChainHead); - } - } - else { - error(node, ts.Diagnostics.Supplied_parameters_do_not_match_any_signature_of_call_target); - } - // No signature was applicable. We have already reported the errors for the invalid signature. - // If this is a type resolution session, e.g. Language Service, try to get better information that anySignature. - // Pick the first candidate that matches the arity. This way we can get a contextual type for cases like: - // declare function f(a: { xa: number; xb: number; }); - // f({ | - if (!produceDiagnostics) { - for (var _i = 0; _i < candidates.length; _i++) { - var candidate = candidates[_i]; - if (hasCorrectArity(node, args, candidate)) { - return candidate; - } - } - } - return resolveErrorCall(node); - function chooseOverload(candidates, relation) { - for (var _i = 0; _i < candidates.length; _i++) { - var originalCandidate = candidates[_i]; - if (!hasCorrectArity(node, args, originalCandidate)) { - continue; - } - var candidate = void 0; - var typeArgumentsAreValid = void 0; - var inferenceContext = originalCandidate.typeParameters - ? createInferenceContext(originalCandidate.typeParameters, false) - : undefined; - while (true) { - candidate = originalCandidate; - if (candidate.typeParameters) { - var typeArgumentTypes = void 0; - if (typeArguments) { - typeArgumentTypes = new Array(candidate.typeParameters.length); - typeArgumentsAreValid = checkTypeArguments(candidate, typeArguments, typeArgumentTypes, false); - } - else { - inferTypeArguments(candidate, args, excludeArgument, inferenceContext); - typeArgumentsAreValid = inferenceContext.failedTypeParameterIndex === undefined; - typeArgumentTypes = inferenceContext.inferredTypes; - } - if (!typeArgumentsAreValid) { - break; - } - candidate = getSignatureInstantiation(candidate, typeArgumentTypes); - } - if (!checkApplicableSignature(node, args, candidate, relation, excludeArgument, false)) { - break; - } - var index = excludeArgument ? ts.indexOf(excludeArgument, true) : -1; - if (index < 0) { - return candidate; - } - excludeArgument[index] = false; - } - // A post-mortem of this iteration of the loop. The signature was not applicable, - // so we want to track it as a candidate for reporting an error. If the candidate - // had no type parameters, or had no issues related to type arguments, we can - // report an error based on the arguments. If there was an issue with type - // arguments, then we can only report an error based on the type arguments. - if (originalCandidate.typeParameters) { - var instantiatedCandidate = candidate; - if (typeArgumentsAreValid) { - candidateForArgumentError = instantiatedCandidate; - } - else { - candidateForTypeArgumentError = originalCandidate; - if (!typeArguments) { - resultOfFailedInference = inferenceContext; - } - } - } - else { - ts.Debug.assert(originalCandidate === candidate); - candidateForArgumentError = originalCandidate; - } - } - return undefined; - } - } - function resolveCallExpression(node, candidatesOutArray) { - if (node.expression.kind === 91 /* SuperKeyword */) { - var superType = checkSuperExpression(node.expression); - if (superType !== unknownType) { - return resolveCall(node, getSignaturesOfType(superType, 1 /* Construct */), candidatesOutArray); - } - return resolveUntypedCall(node); - } - var funcType = checkExpression(node.expression); - var apparentType = getApparentType(funcType); - if (apparentType === unknownType) { - // Another error has already been reported - return resolveErrorCall(node); - } - // Technically, this signatures list may be incomplete. We are taking the apparent type, - // but we are not including call signatures that may have been added to the Object or - // Function interface, since they have none by default. This is a bit of a leap of faith - // that the user will not add any. - var callSignatures = getSignaturesOfType(apparentType, 0 /* Call */); - var constructSignatures = getSignaturesOfType(apparentType, 1 /* Construct */); - // TS 1.0 spec: 4.12 - // If FuncExpr is of type Any, or of an object type that has no call or construct signatures - // but is a subtype of the Function interface, the call is an untyped function call. In an - // untyped function call no TypeArgs are permitted, Args can be any argument list, no contextual - // types are provided for the argument expressions, and the result is always of type Any. - // We exclude union types because we may have a union of function types that happen to have - // no common signatures. - if (isTypeAny(funcType) || (!callSignatures.length && !constructSignatures.length && !(funcType.flags & 16384 /* Union */) && isTypeAssignableTo(funcType, globalFunctionType))) { - // The unknownType indicates that an error already occured (and was reported). No - // need to report another error in this case. - if (funcType !== unknownType && node.typeArguments) { - error(node, ts.Diagnostics.Untyped_function_calls_may_not_accept_type_arguments); - } - return resolveUntypedCall(node); - } - // If FuncExpr's apparent type(section 3.8.1) is a function type, the call is a typed function call. - // TypeScript employs overload resolution in typed function calls in order to support functions - // with multiple call signatures. - if (!callSignatures.length) { - if (constructSignatures.length) { - error(node, ts.Diagnostics.Value_of_type_0_is_not_callable_Did_you_mean_to_include_new, typeToString(funcType)); - } - else { - error(node, ts.Diagnostics.Cannot_invoke_an_expression_whose_type_lacks_a_call_signature); - } - return resolveErrorCall(node); - } - return resolveCall(node, callSignatures, candidatesOutArray); - } - function resolveNewExpression(node, candidatesOutArray) { - if (node.arguments && languageVersion < 1 /* ES5 */) { - var spreadIndex = getSpreadArgumentIndex(node.arguments); - if (spreadIndex >= 0) { - error(node.arguments[spreadIndex], ts.Diagnostics.Spread_operator_in_new_expressions_is_only_available_when_targeting_ECMAScript_5_and_higher); - } - } - var expressionType = checkExpression(node.expression); - // If ConstructExpr's apparent type(section 3.8.1) is an object type with one or - // more construct signatures, the expression is processed in the same manner as a - // function call, but using the construct signatures as the initial set of candidate - // signatures for overload resolution. The result type of the function call becomes - // the result type of the operation. - expressionType = getApparentType(expressionType); - if (expressionType === unknownType) { - // Another error has already been reported - return resolveErrorCall(node); - } - // TS 1.0 spec: 4.11 - // If ConstructExpr is of type Any, Args can be any argument - // list and the result of the operation is of type Any. - if (isTypeAny(expressionType)) { - if (node.typeArguments) { - error(node, ts.Diagnostics.Untyped_function_calls_may_not_accept_type_arguments); - } - return resolveUntypedCall(node); - } - // Technically, this signatures list may be incomplete. We are taking the apparent type, - // but we are not including construct signatures that may have been added to the Object or - // Function interface, since they have none by default. This is a bit of a leap of faith - // that the user will not add any. - var constructSignatures = getSignaturesOfType(expressionType, 1 /* Construct */); - if (constructSignatures.length) { - return resolveCall(node, constructSignatures, candidatesOutArray); - } - // If ConstructExpr's apparent type is an object type with no construct signatures but - // one or more call signatures, the expression is processed as a function call. A compile-time - // error occurs if the result of the function call is not Void. The type of the result of the - // operation is Any. - var callSignatures = getSignaturesOfType(expressionType, 0 /* Call */); - if (callSignatures.length) { - var signature = resolveCall(node, callSignatures, candidatesOutArray); - if (getReturnTypeOfSignature(signature) !== voidType) { - error(node, ts.Diagnostics.Only_a_void_function_can_be_called_with_the_new_keyword); - } - return signature; - } - error(node, ts.Diagnostics.Cannot_use_new_with_an_expression_whose_type_lacks_a_call_or_construct_signature); - return resolveErrorCall(node); - } - function resolveTaggedTemplateExpression(node, candidatesOutArray) { - var tagType = checkExpression(node.tag); - var apparentType = getApparentType(tagType); - if (apparentType === unknownType) { - // Another error has already been reported - return resolveErrorCall(node); - } - var callSignatures = getSignaturesOfType(apparentType, 0 /* Call */); - if (isTypeAny(tagType) || (!callSignatures.length && !(tagType.flags & 16384 /* Union */) && isTypeAssignableTo(tagType, globalFunctionType))) { - return resolveUntypedCall(node); - } - if (!callSignatures.length) { - error(node, ts.Diagnostics.Cannot_invoke_an_expression_whose_type_lacks_a_call_signature); - return resolveErrorCall(node); - } - return resolveCall(node, callSignatures, candidatesOutArray); - } - // candidatesOutArray is passed by signature help in the language service, and collectCandidates - // must fill it up with the appropriate candidate signatures - function getResolvedSignature(node, candidatesOutArray) { - var links = getNodeLinks(node); - // If getResolvedSignature has already been called, we will have cached the resolvedSignature. - // However, it is possible that either candidatesOutArray was not passed in the first time, - // or that a different candidatesOutArray was passed in. Therefore, we need to redo the work - // to correctly fill the candidatesOutArray. - if (!links.resolvedSignature || candidatesOutArray) { - links.resolvedSignature = anySignature; - if (node.kind === 160 /* CallExpression */) { - links.resolvedSignature = resolveCallExpression(node, candidatesOutArray); - } - else if (node.kind === 161 /* NewExpression */) { - links.resolvedSignature = resolveNewExpression(node, candidatesOutArray); - } - else if (node.kind === 162 /* TaggedTemplateExpression */) { - links.resolvedSignature = resolveTaggedTemplateExpression(node, candidatesOutArray); - } - else { - ts.Debug.fail("Branch in 'getResolvedSignature' should be unreachable."); - } - } - return links.resolvedSignature; - } - function checkCallExpression(node) { - // Grammar checking; stop grammar-checking if checkGrammarTypeArguments return true - checkGrammarTypeArguments(node, node.typeArguments) || checkGrammarArguments(node, node.arguments); - var signature = getResolvedSignature(node); - if (node.expression.kind === 91 /* SuperKeyword */) { - return voidType; - } - if (node.kind === 161 /* NewExpression */) { - var declaration = signature.declaration; - if (declaration && - declaration.kind !== 137 /* Constructor */ && - declaration.kind !== 141 /* ConstructSignature */ && - declaration.kind !== 146 /* ConstructorType */) { - // When resolved signature is a call signature (and not a construct signature) the result type is any - if (compilerOptions.noImplicitAny) { - error(node, ts.Diagnostics.new_expression_whose_target_lacks_a_construct_signature_implicitly_has_an_any_type); - } - return anyType; - } - } - return getReturnTypeOfSignature(signature); - } - function checkTaggedTemplateExpression(node) { - return getReturnTypeOfSignature(getResolvedSignature(node)); - } - function checkTypeAssertion(node) { - var exprType = checkExpression(node.expression); - var targetType = getTypeFromTypeNode(node.type); - if (produceDiagnostics && targetType !== unknownType) { - var widenedType = getWidenedType(exprType); - if (!(isTypeAssignableTo(targetType, widenedType))) { - checkTypeAssignableTo(exprType, targetType, node, ts.Diagnostics.Neither_type_0_nor_type_1_is_assignable_to_the_other); - } - } - return targetType; - } - function getTypeAtPosition(signature, pos) { - return signature.hasRestParameter ? - pos < signature.parameters.length - 1 ? getTypeOfSymbol(signature.parameters[pos]) : getRestTypeOfSignature(signature) : - pos < signature.parameters.length ? getTypeOfSymbol(signature.parameters[pos]) : anyType; - } - function assignContextualParameterTypes(signature, context, mapper) { - var len = signature.parameters.length - (signature.hasRestParameter ? 1 : 0); - for (var i = 0; i < len; i++) { - var parameter = signature.parameters[i]; - var links = getSymbolLinks(parameter); - links.type = instantiateType(getTypeAtPosition(context, i), mapper); - } - if (signature.hasRestParameter && context.hasRestParameter && signature.parameters.length >= context.parameters.length) { - var parameter = ts.lastOrUndefined(signature.parameters); - var links = getSymbolLinks(parameter); - links.type = instantiateType(getTypeOfSymbol(ts.lastOrUndefined(context.parameters)), mapper); - } - } - function getReturnTypeFromBody(func, contextualMapper) { - var contextualSignature = getContextualSignatureForFunctionLikeDeclaration(func); - if (!func.body) { - return unknownType; - } - var type; - if (func.body.kind !== 182 /* Block */) { - type = checkExpressionCached(func.body, contextualMapper); - } - else { - var types; - var funcIsGenerator = !!func.asteriskToken; - if (funcIsGenerator) { - types = checkAndAggregateYieldOperandTypes(func.body, contextualMapper); - if (types.length === 0) { - var iterableIteratorAny = createIterableIteratorType(anyType); - if (compilerOptions.noImplicitAny) { - error(func.asteriskToken, ts.Diagnostics.Generator_implicitly_has_type_0_because_it_does_not_yield_any_values_Consider_supplying_a_return_type, typeToString(iterableIteratorAny)); - } - return iterableIteratorAny; - } - } - else { - types = checkAndAggregateReturnExpressionTypes(func.body, contextualMapper); - if (types.length === 0) { - return voidType; - } - } - // When yield/return statements are contextually typed we allow the return type to be a union type. - // Otherwise we require the yield/return expressions to have a best common supertype. - type = contextualSignature ? getUnionType(types) : getCommonSupertype(types); - if (!type) { - if (funcIsGenerator) { - error(func, ts.Diagnostics.No_best_common_type_exists_among_yield_expressions); - return createIterableIteratorType(unknownType); - } - else { - error(func, ts.Diagnostics.No_best_common_type_exists_among_return_expressions); - return unknownType; - } - } - if (funcIsGenerator) { - type = createIterableIteratorType(type); - } - } - if (!contextualSignature) { - reportErrorsFromWidening(func, type); - } - return getWidenedType(type); - } - function checkAndAggregateYieldOperandTypes(body, contextualMapper) { - var aggregatedTypes = []; - ts.forEachYieldExpression(body, function (yieldExpression) { - var expr = yieldExpression.expression; - if (expr) { - var type = checkExpressionCached(expr, contextualMapper); - if (yieldExpression.asteriskToken) { - // A yield* expression effectively yields everything that its operand yields - type = checkElementTypeOfIterable(type, yieldExpression.expression); - } - if (!ts.contains(aggregatedTypes, type)) { - aggregatedTypes.push(type); - } - } - }); - return aggregatedTypes; - } - function checkAndAggregateReturnExpressionTypes(body, contextualMapper) { - var aggregatedTypes = []; - ts.forEachReturnStatement(body, function (returnStatement) { - var expr = returnStatement.expression; - if (expr) { - var type = checkExpressionCached(expr, contextualMapper); - if (!ts.contains(aggregatedTypes, type)) { - aggregatedTypes.push(type); - } - } - }); - return aggregatedTypes; - } - function bodyContainsAReturnStatement(funcBody) { - return ts.forEachReturnStatement(funcBody, function (returnStatement) { - return true; - }); - } - function bodyContainsSingleThrowStatement(body) { - return (body.statements.length === 1) && (body.statements[0].kind === 198 /* ThrowStatement */); - } - // TypeScript Specification 1.0 (6.3) - July 2014 - // An explicitly typed function whose return type isn't the Void or the Any type - // must have at least one return statement somewhere in its body. - // An exception to this rule is if the function implementation consists of a single 'throw' statement. - function checkIfNonVoidFunctionHasReturnExpressionsOrSingleThrowStatment(func, returnType) { - if (!produceDiagnostics) { - return; - } - // Functions that return 'void' or 'any' don't need any return expressions. - if (returnType === voidType || isTypeAny(returnType)) { - return; - } - // If all we have is a function signature, or an arrow function with an expression body, then there is nothing to check. - if (ts.nodeIsMissing(func.body) || func.body.kind !== 182 /* Block */) { - return; - } - var bodyBlock = func.body; - // Ensure the body has at least one return expression. - if (bodyContainsAReturnStatement(bodyBlock)) { - return; - } - // If there are no return expressions, then we need to check if - // the function body consists solely of a throw statement; - // this is to make an exception for unimplemented functions. - if (bodyContainsSingleThrowStatement(bodyBlock)) { - return; - } - // This function does not conform to the specification. - error(func.type, ts.Diagnostics.A_function_whose_declared_type_is_neither_void_nor_any_must_return_a_value_or_consist_of_a_single_throw_statement); - } - function checkFunctionExpressionOrObjectLiteralMethod(node, contextualMapper) { - ts.Debug.assert(node.kind !== 136 /* MethodDeclaration */ || ts.isObjectLiteralMethod(node)); - // Grammar checking - var hasGrammarError = checkGrammarDeclarationNameInStrictMode(node) || checkGrammarFunctionLikeDeclaration(node); - if (!hasGrammarError && node.kind === 165 /* FunctionExpression */) { - checkGrammarFunctionName(node.name) || checkGrammarForGenerator(node); - } - // The identityMapper object is used to indicate that function expressions are wildcards - if (contextualMapper === identityMapper && isContextSensitive(node)) { - return anyFunctionType; - } - var links = getNodeLinks(node); - var type = getTypeOfSymbol(node.symbol); - // Check if function expression is contextually typed and assign parameter types if so - if (!(links.flags & 64 /* ContextChecked */)) { - var contextualSignature = getContextualSignature(node); - // If a type check is started at a function expression that is an argument of a function call, obtaining the - // contextual type may recursively get back to here during overload resolution of the call. If so, we will have - // already assigned contextual types. - if (!(links.flags & 64 /* ContextChecked */)) { - links.flags |= 64 /* ContextChecked */; - if (contextualSignature) { - var signature = getSignaturesOfType(type, 0 /* Call */)[0]; - if (isContextSensitive(node)) { - assignContextualParameterTypes(signature, contextualSignature, contextualMapper || identityMapper); - } - if (!node.type && !signature.resolvedReturnType) { - var returnType = getReturnTypeFromBody(node, contextualMapper); - if (!signature.resolvedReturnType) { - signature.resolvedReturnType = returnType; - } - } - } - checkSignatureDeclaration(node); - } - } - if (produceDiagnostics && node.kind !== 136 /* MethodDeclaration */ && node.kind !== 135 /* MethodSignature */) { - checkCollisionWithCapturedSuperVariable(node, node.name); - checkCollisionWithCapturedThisVariable(node, node.name); - } - return type; - } - function checkFunctionExpressionOrObjectLiteralMethodBody(node) { - ts.Debug.assert(node.kind !== 136 /* MethodDeclaration */ || ts.isObjectLiteralMethod(node)); - if (node.type && !node.asteriskToken) { - checkIfNonVoidFunctionHasReturnExpressionsOrSingleThrowStatment(node, getTypeFromTypeNode(node.type)); - } - if (node.body) { - if (!node.type) { - // There are some checks that are only performed in getReturnTypeFromBody, that may produce errors - // we need. An example is the noImplicitAny errors resulting from widening the return expression - // of a function. Because checking of function expression bodies is deferred, there was never an - // appropriate time to do this during the main walk of the file (see the comment at the top of - // checkFunctionExpressionBodies). So it must be done now. - getReturnTypeOfSignature(getSignatureFromDeclaration(node)); - } - if (node.body.kind === 182 /* Block */) { - checkSourceElement(node.body); - } - else { - var exprType = checkExpression(node.body); - if (node.type) { - checkTypeAssignableTo(exprType, getTypeFromTypeNode(node.type), node.body, undefined); - } - checkFunctionExpressionBodies(node.body); - } - } - } - function checkArithmeticOperandType(operand, type, diagnostic) { - if (!isTypeAnyOrAllConstituentTypesHaveKind(type, 132 /* NumberLike */)) { - error(operand, diagnostic); - return false; - } - return true; - } - function checkReferenceExpression(n, invalidReferenceMessage, constantVariableMessage) { - function findSymbol(n) { - var symbol = getNodeLinks(n).resolvedSymbol; - // Because we got the symbol from the resolvedSymbol property, it might be of kind - // SymbolFlags.ExportValue. In this case it is necessary to get the actual export - // symbol, which will have the correct flags set on it. - return symbol && getExportSymbolOfValueSymbolIfExported(symbol); - } - function isReferenceOrErrorExpression(n) { - // TypeScript 1.0 spec (April 2014): - // Expressions are classified as values or references. - // References are the subset of expressions that are permitted as the target of an assignment. - // Specifically, references are combinations of identifiers(section 4.3), parentheses(section 4.7), - // and property accesses(section 4.10). - // All other expression constructs described in this chapter are classified as values. - switch (n.kind) { - case 65 /* Identifier */: { - var symbol = findSymbol(n); - // TypeScript 1.0 spec (April 2014): 4.3 - // An identifier expression that references a variable or parameter is classified as a reference. - // An identifier expression that references any other kind of entity is classified as a value(and therefore cannot be the target of an assignment). - return !symbol || symbol === unknownSymbol || symbol === argumentsSymbol || (symbol.flags & 3 /* Variable */) !== 0; - } - case 158 /* PropertyAccessExpression */: { - var symbol = findSymbol(n); - // TypeScript 1.0 spec (April 2014): 4.10 - // A property access expression is always classified as a reference. - // NOTE (not in spec): assignment to enum members should not be allowed - return !symbol || symbol === unknownSymbol || (symbol.flags & ~8 /* EnumMember */) !== 0; - } - case 159 /* ElementAccessExpression */: - // old compiler doesn't check indexed assess - return true; - case 164 /* ParenthesizedExpression */: - return isReferenceOrErrorExpression(n.expression); - default: - return false; - } - } - function isConstVariableReference(n) { - switch (n.kind) { - case 65 /* Identifier */: - case 158 /* PropertyAccessExpression */: { - var symbol = findSymbol(n); - return symbol && (symbol.flags & 3 /* Variable */) !== 0 && (getDeclarationFlagsFromSymbol(symbol) & 8192 /* Const */) !== 0; - } - case 159 /* ElementAccessExpression */: { - var index = n.argumentExpression; - var symbol = findSymbol(n.expression); - if (symbol && index && index.kind === 8 /* StringLiteral */) { - var name_11 = index.text; - var prop = getPropertyOfType(getTypeOfSymbol(symbol), name_11); - return prop && (prop.flags & 3 /* Variable */) !== 0 && (getDeclarationFlagsFromSymbol(prop) & 8192 /* Const */) !== 0; - } - return false; - } - case 164 /* ParenthesizedExpression */: - return isConstVariableReference(n.expression); - default: - return false; - } - } - if (!isReferenceOrErrorExpression(n)) { - error(n, invalidReferenceMessage); - return false; - } - if (isConstVariableReference(n)) { - error(n, constantVariableMessage); - return false; - } - return true; - } - function checkDeleteExpression(node) { - // Grammar checking - if (node.parserContextFlags & 1 /* StrictMode */ && node.expression.kind === 65 /* Identifier */) { - // When a delete operator occurs within strict mode code, a SyntaxError is thrown if its - // UnaryExpression is a direct reference to a variable, function argument, or function name - grammarErrorOnNode(node.expression, ts.Diagnostics.delete_cannot_be_called_on_an_identifier_in_strict_mode); - } - var operandType = checkExpression(node.expression); - return booleanType; - } - function checkTypeOfExpression(node) { - var operandType = checkExpression(node.expression); - return stringType; - } - function checkVoidExpression(node) { - var operandType = checkExpression(node.expression); - return undefinedType; - } - function checkPrefixUnaryExpression(node) { - // Grammar checking - // The identifier eval or arguments may not appear as the LeftHandSideExpression of an - // Assignment operator(11.13) or of a PostfixExpression(11.3) or as the UnaryExpression - // operated upon by a Prefix Increment(11.4.4) or a Prefix Decrement(11.4.5) operator - if ((node.operator === 38 /* PlusPlusToken */ || node.operator === 39 /* MinusMinusToken */)) { - checkGrammarEvalOrArgumentsInStrictMode(node, node.operand); - } - var operandType = checkExpression(node.operand); - switch (node.operator) { - case 33 /* PlusToken */: - case 34 /* MinusToken */: - case 47 /* TildeToken */: - if (someConstituentTypeHasKind(operandType, 2097152 /* ESSymbol */)) { - error(node.operand, ts.Diagnostics.The_0_operator_cannot_be_applied_to_type_symbol, ts.tokenToString(node.operator)); - } - return numberType; - case 46 /* ExclamationToken */: - return booleanType; - case 38 /* PlusPlusToken */: - case 39 /* MinusMinusToken */: - var ok = checkArithmeticOperandType(node.operand, operandType, ts.Diagnostics.An_arithmetic_operand_must_be_of_type_any_number_or_an_enum_type); - if (ok) { - // run check only if former checks succeeded to avoid reporting cascading errors - checkReferenceExpression(node.operand, ts.Diagnostics.The_operand_of_an_increment_or_decrement_operator_must_be_a_variable_property_or_indexer, ts.Diagnostics.The_operand_of_an_increment_or_decrement_operator_cannot_be_a_constant); - } - return numberType; - } - return unknownType; - } - function checkPostfixUnaryExpression(node) { - // Grammar checking - // The identifier eval or arguments may not appear as the LeftHandSideExpression of an - // Assignment operator(11.13) or of a PostfixExpression(11.3) or as the UnaryExpression - // operated upon by a Prefix Increment(11.4.4) or a Prefix Decrement(11.4.5) operator. - checkGrammarEvalOrArgumentsInStrictMode(node, node.operand); - var operandType = checkExpression(node.operand); - var ok = checkArithmeticOperandType(node.operand, operandType, ts.Diagnostics.An_arithmetic_operand_must_be_of_type_any_number_or_an_enum_type); - if (ok) { - // run check only if former checks succeeded to avoid reporting cascading errors - checkReferenceExpression(node.operand, ts.Diagnostics.The_operand_of_an_increment_or_decrement_operator_must_be_a_variable_property_or_indexer, ts.Diagnostics.The_operand_of_an_increment_or_decrement_operator_cannot_be_a_constant); - } - return numberType; - } - // Just like isTypeOfKind below, except that it returns true if *any* constituent - // has this kind. - function someConstituentTypeHasKind(type, kind) { - if (type.flags & kind) { - return true; - } - if (type.flags & 16384 /* Union */) { - var types = type.types; - for (var _i = 0; _i < types.length; _i++) { - var current = types[_i]; - if (current.flags & kind) { - return true; - } - } - return false; - } - return false; - } - // Return true if type has the given flags, or is a union type composed of types that all have those flags. - function allConstituentTypesHaveKind(type, kind) { - if (type.flags & kind) { - return true; - } - if (type.flags & 16384 /* Union */) { - var types = type.types; - for (var _i = 0; _i < types.length; _i++) { - var current = types[_i]; - if (!(current.flags & kind)) { - return false; - } - } - return true; - } - return false; - } - function isConstEnumObjectType(type) { - return type.flags & (48128 /* ObjectType */ | 32768 /* Anonymous */) && type.symbol && isConstEnumSymbol(type.symbol); - } - function isConstEnumSymbol(symbol) { - return (symbol.flags & 128 /* ConstEnum */) !== 0; - } - function checkInstanceOfExpression(node, leftType, rightType) { - // TypeScript 1.0 spec (April 2014): 4.15.4 - // The instanceof operator requires the left operand to be of type Any, an object type, or a type parameter type, - // and the right operand to be of type Any or a subtype of the 'Function' interface type. - // The result is always of the Boolean primitive type. - // NOTE: do not raise error if leftType is unknown as related error was already reported - if (allConstituentTypesHaveKind(leftType, 2097662 /* Primitive */)) { - error(node.left, ts.Diagnostics.The_left_hand_side_of_an_instanceof_expression_must_be_of_type_any_an_object_type_or_a_type_parameter); - } - // NOTE: do not raise error if right is unknown as related error was already reported - if (!(isTypeAny(rightType) || isTypeSubtypeOf(rightType, globalFunctionType))) { - error(node.right, ts.Diagnostics.The_right_hand_side_of_an_instanceof_expression_must_be_of_type_any_or_of_a_type_assignable_to_the_Function_interface_type); - } - return booleanType; - } - function checkInExpression(node, leftType, rightType) { - // TypeScript 1.0 spec (April 2014): 4.15.5 - // The in operator requires the left operand to be of type Any, the String primitive type, or the Number primitive type, - // and the right operand to be of type Any, an object type, or a type parameter type. - // The result is always of the Boolean primitive type. - if (!isTypeAnyOrAllConstituentTypesHaveKind(leftType, 258 /* StringLike */ | 132 /* NumberLike */ | 2097152 /* ESSymbol */)) { - error(node.left, ts.Diagnostics.The_left_hand_side_of_an_in_expression_must_be_of_type_any_string_number_or_symbol); - } - if (!isTypeAnyOrAllConstituentTypesHaveKind(rightType, 48128 /* ObjectType */ | 512 /* TypeParameter */)) { - error(node.right, ts.Diagnostics.The_right_hand_side_of_an_in_expression_must_be_of_type_any_an_object_type_or_a_type_parameter); - } - return booleanType; - } - function checkObjectLiteralAssignment(node, sourceType, contextualMapper) { - var properties = node.properties; - for (var _i = 0; _i < properties.length; _i++) { - var p = properties[_i]; - if (p.kind === 227 /* PropertyAssignment */ || p.kind === 228 /* ShorthandPropertyAssignment */) { - // TODO(andersh): Computed property support - var name_12 = p.name; - var type = isTypeAny(sourceType) - ? sourceType - : getTypeOfPropertyOfType(sourceType, name_12.text) || - isNumericLiteralName(name_12.text) && getIndexTypeOfType(sourceType, 1 /* Number */) || - getIndexTypeOfType(sourceType, 0 /* String */); - if (type) { - checkDestructuringAssignment(p.initializer || name_12, type); - } - else { - error(name_12, ts.Diagnostics.Type_0_has_no_property_1_and_no_string_index_signature, typeToString(sourceType), ts.declarationNameToString(name_12)); - } - } - else { - error(p, ts.Diagnostics.Property_assignment_expected); - } - } - return sourceType; - } - function checkArrayLiteralAssignment(node, sourceType, contextualMapper) { - // This elementType will be used if the specific property corresponding to this index is not - // present (aka the tuple element property). This call also checks that the parentType is in - // fact an iterable or array (depending on target language). - var elementType = checkIteratedTypeOrElementType(sourceType, node, false) || unknownType; - var elements = node.elements; - for (var i = 0; i < elements.length; i++) { - var e = elements[i]; - if (e.kind !== 178 /* OmittedExpression */) { - if (e.kind !== 176 /* SpreadElementExpression */) { - var propName = "" + i; - var type = isTypeAny(sourceType) - ? sourceType - : isTupleLikeType(sourceType) - ? getTypeOfPropertyOfType(sourceType, propName) - : elementType; - if (type) { - checkDestructuringAssignment(e, type, contextualMapper); - } - else { - if (isTupleType(sourceType)) { - error(e, ts.Diagnostics.Tuple_type_0_with_length_1_cannot_be_assigned_to_tuple_with_length_2, typeToString(sourceType), sourceType.elementTypes.length, elements.length); - } - else { - error(e, ts.Diagnostics.Type_0_has_no_property_1, typeToString(sourceType), propName); - } - } - } - else { - if (i < elements.length - 1) { - error(e, ts.Diagnostics.A_rest_element_must_be_last_in_an_array_destructuring_pattern); - } - else { - var restExpression = e.expression; - if (restExpression.kind === 172 /* BinaryExpression */ && restExpression.operatorToken.kind === 53 /* EqualsToken */) { - error(restExpression.operatorToken, ts.Diagnostics.A_rest_element_cannot_have_an_initializer); - } - else { - checkDestructuringAssignment(restExpression, createArrayType(elementType), contextualMapper); - } - } - } - } - } - return sourceType; - } - function checkDestructuringAssignment(target, sourceType, contextualMapper) { - if (target.kind === 172 /* BinaryExpression */ && target.operatorToken.kind === 53 /* EqualsToken */) { - checkBinaryExpression(target, contextualMapper); - target = target.left; - } - if (target.kind === 157 /* ObjectLiteralExpression */) { - return checkObjectLiteralAssignment(target, sourceType, contextualMapper); - } - if (target.kind === 156 /* ArrayLiteralExpression */) { - return checkArrayLiteralAssignment(target, sourceType, contextualMapper); - } - return checkReferenceAssignment(target, sourceType, contextualMapper); - } - function checkReferenceAssignment(target, sourceType, contextualMapper) { - var targetType = checkExpression(target, contextualMapper); - if (checkReferenceExpression(target, ts.Diagnostics.Invalid_left_hand_side_of_assignment_expression, ts.Diagnostics.Left_hand_side_of_assignment_expression_cannot_be_a_constant)) { - checkTypeAssignableTo(sourceType, targetType, target, undefined); - } - return sourceType; - } - function checkBinaryExpression(node, contextualMapper) { - // Grammar checking - if (ts.isLeftHandSideExpression(node.left) && ts.isAssignmentOperator(node.operatorToken.kind)) { - // ECMA 262 (Annex C) The identifier eval or arguments may not appear as the LeftHandSideExpression of an - // Assignment operator(11.13) or of a PostfixExpression(11.3) - checkGrammarEvalOrArgumentsInStrictMode(node, node.left); - } - var operator = node.operatorToken.kind; - if (operator === 53 /* EqualsToken */ && (node.left.kind === 157 /* ObjectLiteralExpression */ || node.left.kind === 156 /* ArrayLiteralExpression */)) { - return checkDestructuringAssignment(node.left, checkExpression(node.right, contextualMapper), contextualMapper); - } - var leftType = checkExpression(node.left, contextualMapper); - var rightType = checkExpression(node.right, contextualMapper); - switch (operator) { - case 35 /* AsteriskToken */: - case 56 /* AsteriskEqualsToken */: - case 36 /* SlashToken */: - case 57 /* SlashEqualsToken */: - case 37 /* PercentToken */: - case 58 /* PercentEqualsToken */: - case 34 /* MinusToken */: - case 55 /* MinusEqualsToken */: - case 40 /* LessThanLessThanToken */: - case 59 /* LessThanLessThanEqualsToken */: - case 41 /* GreaterThanGreaterThanToken */: - case 60 /* GreaterThanGreaterThanEqualsToken */: - case 42 /* GreaterThanGreaterThanGreaterThanToken */: - case 61 /* GreaterThanGreaterThanGreaterThanEqualsToken */: - case 44 /* BarToken */: - case 63 /* BarEqualsToken */: - case 45 /* CaretToken */: - case 64 /* CaretEqualsToken */: - case 43 /* AmpersandToken */: - case 62 /* AmpersandEqualsToken */: - // TypeScript 1.0 spec (April 2014): 4.15.1 - // These operators require their operands to be of type Any, the Number primitive type, - // or an enum type. Operands of an enum type are treated - // as having the primitive type Number. If one operand is the null or undefined value, - // it is treated as having the type of the other operand. - // The result is always of the Number primitive type. - if (leftType.flags & (32 /* Undefined */ | 64 /* Null */)) - leftType = rightType; - if (rightType.flags & (32 /* Undefined */ | 64 /* Null */)) - rightType = leftType; - var suggestedOperator; - // if a user tries to apply a bitwise operator to 2 boolean operands - // try and return them a helpful suggestion - if ((leftType.flags & 8 /* Boolean */) && - (rightType.flags & 8 /* Boolean */) && - (suggestedOperator = getSuggestedBooleanOperator(node.operatorToken.kind)) !== undefined) { - error(node, ts.Diagnostics.The_0_operator_is_not_allowed_for_boolean_types_Consider_using_1_instead, ts.tokenToString(node.operatorToken.kind), ts.tokenToString(suggestedOperator)); - } - else { - // otherwise just check each operand separately and report errors as normal - var leftOk = checkArithmeticOperandType(node.left, leftType, ts.Diagnostics.The_left_hand_side_of_an_arithmetic_operation_must_be_of_type_any_number_or_an_enum_type); - var rightOk = checkArithmeticOperandType(node.right, rightType, ts.Diagnostics.The_right_hand_side_of_an_arithmetic_operation_must_be_of_type_any_number_or_an_enum_type); - if (leftOk && rightOk) { - checkAssignmentOperator(numberType); - } - } - return numberType; - case 33 /* PlusToken */: - case 54 /* PlusEqualsToken */: - // TypeScript 1.0 spec (April 2014): 4.15.2 - // The binary + operator requires both operands to be of the Number primitive type or an enum type, - // or at least one of the operands to be of type Any or the String primitive type. - // If one operand is the null or undefined value, it is treated as having the type of the other operand. - if (leftType.flags & (32 /* Undefined */ | 64 /* Null */)) - leftType = rightType; - if (rightType.flags & (32 /* Undefined */ | 64 /* Null */)) - rightType = leftType; - var resultType; - if (allConstituentTypesHaveKind(leftType, 132 /* NumberLike */) && allConstituentTypesHaveKind(rightType, 132 /* NumberLike */)) { - // Operands of an enum type are treated as having the primitive type Number. - // If both operands are of the Number primitive type, the result is of the Number primitive type. - resultType = numberType; - } - else { - if (allConstituentTypesHaveKind(leftType, 258 /* StringLike */) || allConstituentTypesHaveKind(rightType, 258 /* StringLike */)) { - // If one or both operands are of the String primitive type, the result is of the String primitive type. - resultType = stringType; - } - else if (isTypeAny(leftType) || isTypeAny(rightType)) { - // Otherwise, the result is of type Any. - // NOTE: unknown type here denotes error type. Old compiler treated this case as any type so do we. - resultType = leftType === unknownType || rightType === unknownType ? unknownType : anyType; - } - // Symbols are not allowed at all in arithmetic expressions - if (resultType && !checkForDisallowedESSymbolOperand(operator)) { - return resultType; - } - } - if (!resultType) { - reportOperatorError(); - return anyType; - } - if (operator === 54 /* PlusEqualsToken */) { - checkAssignmentOperator(resultType); - } - return resultType; - case 24 /* LessThanToken */: - case 25 /* GreaterThanToken */: - case 26 /* LessThanEqualsToken */: - case 27 /* GreaterThanEqualsToken */: - if (!checkForDisallowedESSymbolOperand(operator)) { - return booleanType; - } - // Fall through - case 28 /* EqualsEqualsToken */: - case 29 /* ExclamationEqualsToken */: - case 30 /* EqualsEqualsEqualsToken */: - case 31 /* ExclamationEqualsEqualsToken */: - if (!isTypeAssignableTo(leftType, rightType) && !isTypeAssignableTo(rightType, leftType)) { - reportOperatorError(); - } - return booleanType; - case 87 /* InstanceOfKeyword */: - return checkInstanceOfExpression(node, leftType, rightType); - case 86 /* InKeyword */: - return checkInExpression(node, leftType, rightType); - case 48 /* AmpersandAmpersandToken */: - return rightType; - case 49 /* BarBarToken */: - return getUnionType([leftType, rightType]); - case 53 /* EqualsToken */: - checkAssignmentOperator(rightType); - return rightType; - case 23 /* CommaToken */: - return rightType; - } - // Return true if there was no error, false if there was an error. - function checkForDisallowedESSymbolOperand(operator) { - var offendingSymbolOperand = someConstituentTypeHasKind(leftType, 2097152 /* ESSymbol */) ? node.left : - someConstituentTypeHasKind(rightType, 2097152 /* ESSymbol */) ? node.right : - undefined; - if (offendingSymbolOperand) { - error(offendingSymbolOperand, ts.Diagnostics.The_0_operator_cannot_be_applied_to_type_symbol, ts.tokenToString(operator)); - return false; - } - return true; - } - function getSuggestedBooleanOperator(operator) { - switch (operator) { - case 44 /* BarToken */: - case 63 /* BarEqualsToken */: - return 49 /* BarBarToken */; - case 45 /* CaretToken */: - case 64 /* CaretEqualsToken */: - return 31 /* ExclamationEqualsEqualsToken */; - case 43 /* AmpersandToken */: - case 62 /* AmpersandEqualsToken */: - return 48 /* AmpersandAmpersandToken */; - default: - return undefined; - } - } - function checkAssignmentOperator(valueType) { - if (produceDiagnostics && operator >= 53 /* FirstAssignment */ && operator <= 64 /* LastAssignment */) { - // TypeScript 1.0 spec (April 2014): 4.17 - // An assignment of the form - // VarExpr = ValueExpr - // requires VarExpr to be classified as a reference - // A compound assignment furthermore requires VarExpr to be classified as a reference (section 4.1) - // and the type of the non - compound operation to be assignable to the type of VarExpr. - var ok = checkReferenceExpression(node.left, ts.Diagnostics.Invalid_left_hand_side_of_assignment_expression, ts.Diagnostics.Left_hand_side_of_assignment_expression_cannot_be_a_constant); - // Use default messages - if (ok) { - // to avoid cascading errors check assignability only if 'isReference' check succeeded and no errors were reported - checkTypeAssignableTo(valueType, leftType, node.left, undefined); - } - } - } - function reportOperatorError() { - error(node, ts.Diagnostics.Operator_0_cannot_be_applied_to_types_1_and_2, ts.tokenToString(node.operatorToken.kind), typeToString(leftType), typeToString(rightType)); - } - } - function isYieldExpressionInClass(node) { - var current = node; - var parent = node.parent; - while (parent) { - if (ts.isFunctionLike(parent) && current === parent.body) { - return false; - } - else if (current.kind === 204 /* ClassDeclaration */ || current.kind === 177 /* ClassExpression */) { - return true; - } - current = parent; - parent = parent.parent; - } - return false; - } - function checkYieldExpression(node) { - // Grammar checking - if (!(node.parserContextFlags & 4 /* Yield */) || isYieldExpressionInClass(node)) { - grammarErrorOnFirstToken(node, ts.Diagnostics.A_yield_expression_is_only_allowed_in_a_generator_body); - } - if (node.expression) { - var func = ts.getContainingFunction(node); - // If the user's code is syntactically correct, the func should always have a star. After all, - // we are in a yield context. - if (func && func.asteriskToken) { - var expressionType = checkExpressionCached(node.expression, undefined); - var expressionElementType; - var nodeIsYieldStar = !!node.asteriskToken; - if (nodeIsYieldStar) { - expressionElementType = checkElementTypeOfIterable(expressionType, node.expression); - } - // There is no point in doing an assignability check if the function - // has no explicit return type because the return type is directly computed - // from the yield expressions. - if (func.type) { - var signatureElementType = getElementTypeOfIterableIterator(getTypeFromTypeNode(func.type)) || anyType; - if (nodeIsYieldStar) { - checkTypeAssignableTo(expressionElementType, signatureElementType, node.expression, undefined); - } - else { - checkTypeAssignableTo(expressionType, signatureElementType, node.expression, undefined); - } - } - } - } - // Both yield and yield* expressions have type 'any' - return anyType; - } - function checkConditionalExpression(node, contextualMapper) { - checkExpression(node.condition); - var type1 = checkExpression(node.whenTrue, contextualMapper); - var type2 = checkExpression(node.whenFalse, contextualMapper); - return getUnionType([type1, type2]); - } - function checkTemplateExpression(node) { - // We just want to check each expressions, but we are unconcerned with - // the type of each expression, as any value may be coerced into a string. - // It is worth asking whether this is what we really want though. - // A place where we actually *are* concerned with the expressions' types are - // in tagged templates. - ts.forEach(node.templateSpans, function (templateSpan) { - checkExpression(templateSpan.expression); - }); - return stringType; - } - function checkExpressionWithContextualType(node, contextualType, contextualMapper) { - var saveContextualType = node.contextualType; - node.contextualType = contextualType; - var result = checkExpression(node, contextualMapper); - node.contextualType = saveContextualType; - return result; - } - function checkExpressionCached(node, contextualMapper) { - var links = getNodeLinks(node); - if (!links.resolvedType) { - links.resolvedType = checkExpression(node, contextualMapper); - } - return links.resolvedType; - } - function checkPropertyAssignment(node, contextualMapper) { - // Do not use hasDynamicName here, because that returns false for well known symbols. - // We want to perform checkComputedPropertyName for all computed properties, including - // well known symbols. - if (node.name.kind === 129 /* ComputedPropertyName */) { - checkComputedPropertyName(node.name); - } - return checkExpression(node.initializer, contextualMapper); - } - function checkObjectLiteralMethod(node, contextualMapper) { - // Grammar checking - checkGrammarMethod(node); - // Do not use hasDynamicName here, because that returns false for well known symbols. - // We want to perform checkComputedPropertyName for all computed properties, including - // well known symbols. - if (node.name.kind === 129 /* ComputedPropertyName */) { - checkComputedPropertyName(node.name); - } - var uninstantiatedType = checkFunctionExpressionOrObjectLiteralMethod(node, contextualMapper); - return instantiateTypeWithSingleGenericCallSignature(node, uninstantiatedType, contextualMapper); - } - function instantiateTypeWithSingleGenericCallSignature(node, type, contextualMapper) { - if (contextualMapper && contextualMapper !== identityMapper) { - var signature = getSingleCallSignature(type); - if (signature && signature.typeParameters) { - var contextualType = getContextualType(node); - if (contextualType) { - var contextualSignature = getSingleCallSignature(contextualType); - if (contextualSignature && !contextualSignature.typeParameters) { - return getOrCreateTypeFromSignature(instantiateSignatureInContextOf(signature, contextualSignature, contextualMapper)); - } - } - } - } - return type; - } - function checkExpression(node, contextualMapper) { - checkGrammarIdentifierInStrictMode(node); - return checkExpressionOrQualifiedName(node, contextualMapper); - } - // Checks an expression and returns its type. The contextualMapper parameter serves two purposes: When - // contextualMapper is not undefined and not equal to the identityMapper function object it indicates that the - // expression is being inferentially typed (section 4.12.2 in spec) and provides the type mapper to use in - // conjunction with the generic contextual type. When contextualMapper is equal to the identityMapper function - // object, it serves as an indicator that all contained function and arrow expressions should be considered to - // have the wildcard function type; this form of type check is used during overload resolution to exclude - // contextually typed function and arrow expressions in the initial phase. - function checkExpressionOrQualifiedName(node, contextualMapper) { - var type; - if (node.kind == 128 /* QualifiedName */) { - type = checkQualifiedName(node); - } - else { - var uninstantiatedType = checkExpressionWorker(node, contextualMapper); - type = instantiateTypeWithSingleGenericCallSignature(node, uninstantiatedType, contextualMapper); - } - if (isConstEnumObjectType(type)) { - // enum object type for const enums are only permitted in: - // - 'left' in property access - // - 'object' in indexed access - // - target in rhs of import statement - var ok = (node.parent.kind === 158 /* PropertyAccessExpression */ && node.parent.expression === node) || - (node.parent.kind === 159 /* ElementAccessExpression */ && node.parent.expression === node) || - ((node.kind === 65 /* Identifier */ || node.kind === 128 /* QualifiedName */) && isInRightSideOfImportOrExportAssignment(node)); - if (!ok) { - error(node, ts.Diagnostics.const_enums_can_only_be_used_in_property_or_index_access_expressions_or_the_right_hand_side_of_an_import_declaration_or_export_assignment); - } - } - return type; - } - function checkNumericLiteral(node) { - // Grammar checking - checkGrammarNumericLiteral(node); - return numberType; - } - function checkExpressionWorker(node, contextualMapper) { - switch (node.kind) { - case 65 /* Identifier */: - return checkIdentifier(node); - case 93 /* ThisKeyword */: - return checkThisExpression(node); - case 91 /* SuperKeyword */: - return checkSuperExpression(node); - case 89 /* NullKeyword */: - return nullType; - case 95 /* TrueKeyword */: - case 80 /* FalseKeyword */: - return booleanType; - case 7 /* NumericLiteral */: - return checkNumericLiteral(node); - case 174 /* TemplateExpression */: - return checkTemplateExpression(node); - case 8 /* StringLiteral */: - case 10 /* NoSubstitutionTemplateLiteral */: - return stringType; - case 9 /* RegularExpressionLiteral */: - return globalRegExpType; - case 156 /* ArrayLiteralExpression */: - return checkArrayLiteral(node, contextualMapper); - case 157 /* ObjectLiteralExpression */: - return checkObjectLiteral(node, contextualMapper); - case 158 /* PropertyAccessExpression */: - return checkPropertyAccessExpression(node); - case 159 /* ElementAccessExpression */: - return checkIndexedAccess(node); - case 160 /* CallExpression */: - case 161 /* NewExpression */: - return checkCallExpression(node); - case 162 /* TaggedTemplateExpression */: - return checkTaggedTemplateExpression(node); - case 163 /* TypeAssertionExpression */: - return checkTypeAssertion(node); - case 164 /* ParenthesizedExpression */: - return checkExpression(node.expression, contextualMapper); - case 177 /* ClassExpression */: - return checkClassExpression(node); - case 165 /* FunctionExpression */: - case 166 /* ArrowFunction */: - return checkFunctionExpressionOrObjectLiteralMethod(node, contextualMapper); - case 168 /* TypeOfExpression */: - return checkTypeOfExpression(node); - case 167 /* DeleteExpression */: - return checkDeleteExpression(node); - case 169 /* VoidExpression */: - return checkVoidExpression(node); - case 170 /* PrefixUnaryExpression */: - return checkPrefixUnaryExpression(node); - case 171 /* PostfixUnaryExpression */: - return checkPostfixUnaryExpression(node); - case 172 /* BinaryExpression */: - return checkBinaryExpression(node, contextualMapper); - case 173 /* ConditionalExpression */: - return checkConditionalExpression(node, contextualMapper); - case 176 /* SpreadElementExpression */: - return checkSpreadElementExpression(node, contextualMapper); - case 178 /* OmittedExpression */: - return undefinedType; - case 175 /* YieldExpression */: - return checkYieldExpression(node); - } - return unknownType; - } - // DECLARATION AND STATEMENT TYPE CHECKING - function checkTypeParameter(node) { - checkGrammarDeclarationNameInStrictMode(node); - // Grammar Checking - if (node.expression) { - grammarErrorOnFirstToken(node.expression, ts.Diagnostics.Type_expected); - } - checkSourceElement(node.constraint); - if (produceDiagnostics) { - checkTypeParameterHasIllegalReferencesInConstraint(node); - checkTypeNameIsReserved(node.name, ts.Diagnostics.Type_parameter_name_cannot_be_0); - } - // TODO: Check multiple declarations are identical - } - function checkParameter(node) { - // Grammar checking - // It is a SyntaxError if the Identifier "eval" or the Identifier "arguments" occurs as the - // Identifier in a PropertySetParameterList of a PropertyAssignment that is contained in strict code - // or if its FunctionBody is strict code(11.1.5). - // It is a SyntaxError if the identifier eval or arguments appears within a FormalParameterList of a - // strict mode FunctionLikeDeclaration or FunctionExpression(13.1) - // Grammar checking - checkGrammarDecorators(node) || checkGrammarModifiers(node) || checkGrammarEvalOrArgumentsInStrictMode(node, node.name); - checkVariableLikeDeclaration(node); - var func = ts.getContainingFunction(node); - if (node.flags & 112 /* AccessibilityModifier */) { - func = ts.getContainingFunction(node); - if (!(func.kind === 137 /* Constructor */ && ts.nodeIsPresent(func.body))) { - error(node, ts.Diagnostics.A_parameter_property_is_only_allowed_in_a_constructor_implementation); - } - } - if (node.questionToken && ts.isBindingPattern(node.name) && func.body) { - error(node, ts.Diagnostics.A_binding_pattern_parameter_cannot_be_optional_in_an_implementation_signature); - } - // Only check rest parameter type if it's not a binding pattern. Since binding patterns are - // not allowed in a rest parameter, we already have an error from checkGrammarParameterList. - if (node.dotDotDotToken && !ts.isBindingPattern(node.name) && !isArrayType(getTypeOfSymbol(node.symbol))) { - error(node, ts.Diagnostics.A_rest_parameter_must_be_of_an_array_type); - } - } - function isSyntacticallyValidGenerator(node) { - if (!node.asteriskToken || !node.body) { - return false; - } - return node.kind === 136 /* MethodDeclaration */ || - node.kind === 203 /* FunctionDeclaration */ || - node.kind === 165 /* FunctionExpression */; - } - function getTypePredicateParameterIndex(parameterList, parameter) { - if (parameterList) { - for (var i = 0; i < parameterList.length; i++) { - var param = parameterList[i]; - if (param.name.kind === 65 /* Identifier */ && - param.name.text === parameter.text) { - return i; - } - } - } - return -1; - } - function isInLegalTypePredicatePosition(node) { - switch (node.parent.kind) { - case 166 /* ArrowFunction */: - case 140 /* CallSignature */: - case 203 /* FunctionDeclaration */: - case 165 /* FunctionExpression */: - case 145 /* FunctionType */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - return node === node.parent.type; - } - return false; - } - function checkSignatureDeclaration(node) { - // Grammar checking - if (node.kind === 142 /* IndexSignature */) { - checkGrammarIndexSignature(node); - } - else if (node.kind === 145 /* FunctionType */ || node.kind === 203 /* FunctionDeclaration */ || node.kind === 146 /* ConstructorType */ || - node.kind === 140 /* CallSignature */ || node.kind === 137 /* Constructor */ || - node.kind === 141 /* ConstructSignature */) { - checkGrammarFunctionLikeDeclaration(node); - } - checkTypeParameters(node.typeParameters); - ts.forEach(node.parameters, checkParameter); - if (node.type) { - if (node.type.kind === 143 /* TypePredicate */) { - var typePredicate = getSignatureFromDeclaration(node).typePredicate; - var typePredicateNode = node.type; - if (isInLegalTypePredicatePosition(typePredicateNode)) { - if (typePredicate.parameterIndex >= 0) { - if (node.parameters[typePredicate.parameterIndex].dotDotDotToken) { - error(typePredicateNode.parameterName, ts.Diagnostics.A_type_predicate_cannot_reference_a_rest_parameter); - } - else { - checkTypeAssignableTo(typePredicate.type, getTypeAtLocation(node.parameters[typePredicate.parameterIndex]), typePredicateNode.type); - } - } - else if (typePredicateNode.parameterName) { - var hasReportedError = false; - for (var _i = 0, _a = node.parameters; _i < _a.length; _i++) { - var param = _a[_i]; - if (hasReportedError) { - break; - } - if (param.name.kind === 153 /* ObjectBindingPattern */ || - param.name.kind === 154 /* ArrayBindingPattern */) { - (function checkBindingPattern(pattern) { - for (var _i = 0, _a = pattern.elements; _i < _a.length; _i++) { - var element = _a[_i]; - if (element.name.kind === 65 /* Identifier */ && - element.name.text === typePredicate.parameterName) { - error(typePredicateNode.parameterName, ts.Diagnostics.A_type_predicate_cannot_reference_element_0_in_a_binding_pattern, typePredicate.parameterName); - hasReportedError = true; - break; - } - else if (element.name.kind === 154 /* ArrayBindingPattern */ || - element.name.kind === 153 /* ObjectBindingPattern */) { - checkBindingPattern(element.name); - } - } - })(param.name); - } - } - if (!hasReportedError) { - error(typePredicateNode.parameterName, ts.Diagnostics.Cannot_find_parameter_0, typePredicate.parameterName); - } - } - } - else { - error(typePredicateNode, ts.Diagnostics.A_type_predicate_is_only_allowed_in_return_type_position_for_functions_and_methods); - } - } - else { - checkSourceElement(node.type); - } - } - if (produceDiagnostics) { - checkCollisionWithArgumentsInGeneratedCode(node); - if (compilerOptions.noImplicitAny && !node.type) { - switch (node.kind) { - case 141 /* ConstructSignature */: - error(node, ts.Diagnostics.Construct_signature_which_lacks_return_type_annotation_implicitly_has_an_any_return_type); - break; - case 140 /* CallSignature */: - error(node, ts.Diagnostics.Call_signature_which_lacks_return_type_annotation_implicitly_has_an_any_return_type); - break; - } - } - if (node.type) { - if (languageVersion >= 2 /* ES6 */ && isSyntacticallyValidGenerator(node)) { - var returnType = getTypeFromTypeNode(node.type); - if (returnType === voidType) { - error(node.type, ts.Diagnostics.A_generator_cannot_have_a_void_type_annotation); - } - else { - var generatorElementType = getElementTypeOfIterableIterator(returnType) || anyType; - var iterableIteratorInstantiation = createIterableIteratorType(generatorElementType); - // Naively, one could check that IterableIterator is assignable to the return type annotation. - // However, that would not catch the error in the following case. - // - // interface BadGenerator extends Iterable, Iterator { } - // function* g(): BadGenerator { } // Iterable and Iterator have different types! - // - checkTypeAssignableTo(iterableIteratorInstantiation, returnType, node.type); - } - } - } - } - checkSpecializedSignatureDeclaration(node); - } - function checkTypeForDuplicateIndexSignatures(node) { - if (node.kind === 205 /* InterfaceDeclaration */) { - var nodeSymbol = getSymbolOfNode(node); - // in case of merging interface declaration it is possible that we'll enter this check procedure several times for every declaration - // to prevent this run check only for the first declaration of a given kind - if (nodeSymbol.declarations.length > 0 && nodeSymbol.declarations[0] !== node) { - return; - } - } - // TypeScript 1.0 spec (April 2014) - // 3.7.4: An object type can contain at most one string index signature and one numeric index signature. - // 8.5: A class declaration can have at most one string index member declaration and one numeric index member declaration - var indexSymbol = getIndexSymbol(getSymbolOfNode(node)); - if (indexSymbol) { - var seenNumericIndexer = false; - var seenStringIndexer = false; - for (var _i = 0, _a = indexSymbol.declarations; _i < _a.length; _i++) { - var decl = _a[_i]; - var declaration = decl; - if (declaration.parameters.length === 1 && declaration.parameters[0].type) { - switch (declaration.parameters[0].type.kind) { - case 123 /* StringKeyword */: - if (!seenStringIndexer) { - seenStringIndexer = true; - } - else { - error(declaration, ts.Diagnostics.Duplicate_string_index_signature); - } - break; - case 121 /* NumberKeyword */: - if (!seenNumericIndexer) { - seenNumericIndexer = true; - } - else { - error(declaration, ts.Diagnostics.Duplicate_number_index_signature); - } - break; - } - } - } - } - } - function checkPropertyDeclaration(node) { - // Grammar checking - checkGrammarDecorators(node) || checkGrammarModifiers(node) || checkGrammarProperty(node) || checkGrammarComputedPropertyName(node.name); - checkVariableLikeDeclaration(node); - } - function checkMethodDeclaration(node) { - // Grammar checking - checkGrammarMethod(node) || checkGrammarComputedPropertyName(node.name); - // Grammar checking for modifiers is done inside the function checkGrammarFunctionLikeDeclaration - checkFunctionLikeDeclaration(node); - } - function checkConstructorDeclaration(node) { - // Grammar check on signature of constructor and modifier of the constructor is done in checkSignatureDeclaration function. - checkSignatureDeclaration(node); - // Grammar check for checking only related to constructoDeclaration - checkGrammarConstructorTypeParameters(node) || checkGrammarConstructorTypeAnnotation(node); - checkSourceElement(node.body); - var symbol = getSymbolOfNode(node); - var firstDeclaration = ts.getDeclarationOfKind(symbol, node.kind); - // Only type check the symbol once - if (node === firstDeclaration) { - checkFunctionOrConstructorSymbol(symbol); - } - // exit early in the case of signature - super checks are not relevant to them - if (ts.nodeIsMissing(node.body)) { - return; - } - if (!produceDiagnostics) { - return; - } - function isSuperCallExpression(n) { - return n.kind === 160 /* CallExpression */ && n.expression.kind === 91 /* SuperKeyword */; - } - function containsSuperCall(n) { - if (isSuperCallExpression(n)) { - return true; - } - switch (n.kind) { - case 165 /* FunctionExpression */: - case 203 /* FunctionDeclaration */: - case 166 /* ArrowFunction */: - case 157 /* ObjectLiteralExpression */: return false; - default: return ts.forEachChild(n, containsSuperCall); - } - } - function markThisReferencesAsErrors(n) { - if (n.kind === 93 /* ThisKeyword */) { - error(n, ts.Diagnostics.this_cannot_be_referenced_in_current_location); - } - else if (n.kind !== 165 /* FunctionExpression */ && n.kind !== 203 /* FunctionDeclaration */) { - ts.forEachChild(n, markThisReferencesAsErrors); - } - } - function isInstancePropertyWithInitializer(n) { - return n.kind === 134 /* PropertyDeclaration */ && - !(n.flags & 128 /* Static */) && - !!n.initializer; - } - // TS 1.0 spec (April 2014): 8.3.2 - // Constructors of classes with no extends clause may not contain super calls, whereas - // constructors of derived classes must contain at least one super call somewhere in their function body. - if (ts.getClassExtendsHeritageClauseElement(node.parent)) { - if (containsSuperCall(node.body)) { - // The first statement in the body of a constructor must be a super call if both of the following are true: - // - The containing class is a derived class. - // - The constructor declares parameter properties - // or the containing class declares instance member variables with initializers. - var superCallShouldBeFirst = ts.forEach(node.parent.members, isInstancePropertyWithInitializer) || - ts.forEach(node.parameters, function (p) { return p.flags & (16 /* Public */ | 32 /* Private */ | 64 /* Protected */); }); - if (superCallShouldBeFirst) { - var statements = node.body.statements; - if (!statements.length || statements[0].kind !== 185 /* ExpressionStatement */ || !isSuperCallExpression(statements[0].expression)) { - error(node, ts.Diagnostics.A_super_call_must_be_the_first_statement_in_the_constructor_when_a_class_contains_initialized_properties_or_has_parameter_properties); - } - else { - // In such a required super call, it is a compile-time error for argument expressions to reference this. - markThisReferencesAsErrors(statements[0].expression); - } - } - } - else { - error(node, ts.Diagnostics.Constructors_for_derived_classes_must_contain_a_super_call); - } - } - } - function checkAccessorDeclaration(node) { - if (produceDiagnostics) { - // Grammar checking accessors - checkGrammarFunctionLikeDeclaration(node) || checkGrammarAccessor(node) || checkGrammarComputedPropertyName(node.name); - if (node.kind === 138 /* GetAccessor */) { - if (!ts.isInAmbientContext(node) && ts.nodeIsPresent(node.body) && !(bodyContainsAReturnStatement(node.body) || bodyContainsSingleThrowStatement(node.body))) { - error(node.name, ts.Diagnostics.A_get_accessor_must_return_a_value_or_consist_of_a_single_throw_statement); - } - } - if (!ts.hasDynamicName(node)) { - // TypeScript 1.0 spec (April 2014): 8.4.3 - // Accessors for the same member name must specify the same accessibility. - var otherKind = node.kind === 138 /* GetAccessor */ ? 139 /* SetAccessor */ : 138 /* GetAccessor */; - var otherAccessor = ts.getDeclarationOfKind(node.symbol, otherKind); - if (otherAccessor) { - if (((node.flags & 112 /* AccessibilityModifier */) !== (otherAccessor.flags & 112 /* AccessibilityModifier */))) { - error(node.name, ts.Diagnostics.Getter_and_setter_accessors_do_not_agree_in_visibility); - } - var currentAccessorType = getAnnotatedAccessorType(node); - var otherAccessorType = getAnnotatedAccessorType(otherAccessor); - // TypeScript 1.0 spec (April 2014): 4.5 - // If both accessors include type annotations, the specified types must be identical. - if (currentAccessorType && otherAccessorType) { - if (!isTypeIdenticalTo(currentAccessorType, otherAccessorType)) { - error(node, ts.Diagnostics.get_and_set_accessor_must_have_the_same_type); - } - } - } - } - getTypeOfAccessors(getSymbolOfNode(node)); - } - checkFunctionLikeDeclaration(node); - } - function checkMissingDeclaration(node) { - checkDecorators(node); - } - function checkTypeReferenceNode(node) { - checkGrammarTypeReferenceInStrictMode(node.typeName); - return checkTypeReferenceOrExpressionWithTypeArguments(node); - } - function checkExpressionWithTypeArguments(node) { - checkGrammarExpressionWithTypeArgumentsInStrictMode(node.expression); - return checkTypeReferenceOrExpressionWithTypeArguments(node); - } - function checkTypeReferenceOrExpressionWithTypeArguments(node) { - // Grammar checking - checkGrammarTypeArguments(node, node.typeArguments); - var type = getTypeFromTypeReference(node); - if (type !== unknownType && node.typeArguments) { - // Do type argument local checks only if referenced type is successfully resolved - var symbol = getNodeLinks(node).resolvedSymbol; - var typeParameters = symbol.flags & 524288 /* TypeAlias */ ? getSymbolLinks(symbol).typeParameters : type.target.localTypeParameters; - var len = node.typeArguments.length; - for (var i = 0; i < len; i++) { - checkSourceElement(node.typeArguments[i]); - var constraint = getConstraintOfTypeParameter(typeParameters[i]); - if (produceDiagnostics && constraint) { - var typeArgument = type.typeArguments[i]; - checkTypeAssignableTo(typeArgument, constraint, node, ts.Diagnostics.Type_0_does_not_satisfy_the_constraint_1); - } - } - } - } - function checkTypeQuery(node) { - getTypeFromTypeQueryNode(node); - } - function checkTypeLiteral(node) { - ts.forEach(node.members, checkSourceElement); - if (produceDiagnostics) { - var type = getTypeFromTypeLiteralOrFunctionOrConstructorTypeNode(node); - checkIndexConstraints(type); - checkTypeForDuplicateIndexSignatures(node); - } - } - function checkArrayType(node) { - checkSourceElement(node.elementType); - } - function checkTupleType(node) { - // Grammar checking - var hasErrorFromDisallowedTrailingComma = checkGrammarForDisallowedTrailingComma(node.elementTypes); - if (!hasErrorFromDisallowedTrailingComma && node.elementTypes.length === 0) { - grammarErrorOnNode(node, ts.Diagnostics.A_tuple_type_element_list_cannot_be_empty); - } - ts.forEach(node.elementTypes, checkSourceElement); - } - function checkUnionType(node) { - ts.forEach(node.types, checkSourceElement); - } - function isPrivateWithinAmbient(node) { - return (node.flags & 32 /* Private */) && ts.isInAmbientContext(node); - } - function checkSpecializedSignatureDeclaration(signatureDeclarationNode) { - if (!produceDiagnostics) { - return; - } - var signature = getSignatureFromDeclaration(signatureDeclarationNode); - if (!signature.hasStringLiterals) { - return; - } - // TypeScript 1.0 spec (April 2014): 3.7.2.2 - // Specialized signatures are not permitted in conjunction with a function body - if (ts.nodeIsPresent(signatureDeclarationNode.body)) { - error(signatureDeclarationNode, ts.Diagnostics.A_signature_with_an_implementation_cannot_use_a_string_literal_type); - return; - } - // TypeScript 1.0 spec (April 2014): 3.7.2.4 - // Every specialized call or construct signature in an object type must be assignable - // to at least one non-specialized call or construct signature in the same object type - var signaturesToCheck; - // Unnamed (call\construct) signatures in interfaces are inherited and not shadowed so examining just node symbol won't give complete answer. - // Use declaring type to obtain full list of signatures. - if (!signatureDeclarationNode.name && signatureDeclarationNode.parent && signatureDeclarationNode.parent.kind === 205 /* InterfaceDeclaration */) { - ts.Debug.assert(signatureDeclarationNode.kind === 140 /* CallSignature */ || signatureDeclarationNode.kind === 141 /* ConstructSignature */); - var signatureKind = signatureDeclarationNode.kind === 140 /* CallSignature */ ? 0 /* Call */ : 1 /* Construct */; - var containingSymbol = getSymbolOfNode(signatureDeclarationNode.parent); - var containingType = getDeclaredTypeOfSymbol(containingSymbol); - signaturesToCheck = getSignaturesOfType(containingType, signatureKind); - } - else { - signaturesToCheck = getSignaturesOfSymbol(getSymbolOfNode(signatureDeclarationNode)); - } - for (var _i = 0; _i < signaturesToCheck.length; _i++) { - var otherSignature = signaturesToCheck[_i]; - if (!otherSignature.hasStringLiterals && isSignatureAssignableTo(signature, otherSignature)) { - return; - } - } - error(signatureDeclarationNode, ts.Diagnostics.Specialized_overload_signature_is_not_assignable_to_any_non_specialized_signature); - } - function getEffectiveDeclarationFlags(n, flagsToCheck) { - var flags = ts.getCombinedNodeFlags(n); - if (n.parent.kind !== 205 /* InterfaceDeclaration */ && ts.isInAmbientContext(n)) { - if (!(flags & 2 /* Ambient */)) { - // It is nested in an ambient context, which means it is automatically exported - flags |= 1 /* Export */; - } - flags |= 2 /* Ambient */; - } - return flags & flagsToCheck; - } - function checkFunctionOrConstructorSymbol(symbol) { - if (!produceDiagnostics) { - return; - } - function getCanonicalOverload(overloads, implementation) { - // Consider the canonical set of flags to be the flags of the bodyDeclaration or the first declaration - // Error on all deviations from this canonical set of flags - // The caveat is that if some overloads are defined in lib.d.ts, we don't want to - // report the errors on those. To achieve this, we will say that the implementation is - // the canonical signature only if it is in the same container as the first overload - var implementationSharesContainerWithFirstOverload = implementation !== undefined && implementation.parent === overloads[0].parent; - return implementationSharesContainerWithFirstOverload ? implementation : overloads[0]; - } - function checkFlagAgreementBetweenOverloads(overloads, implementation, flagsToCheck, someOverloadFlags, allOverloadFlags) { - // Error if some overloads have a flag that is not shared by all overloads. To find the - // deviations, we XOR someOverloadFlags with allOverloadFlags - var someButNotAllOverloadFlags = someOverloadFlags ^ allOverloadFlags; - if (someButNotAllOverloadFlags !== 0) { - var canonicalFlags = getEffectiveDeclarationFlags(getCanonicalOverload(overloads, implementation), flagsToCheck); - ts.forEach(overloads, function (o) { - var deviation = getEffectiveDeclarationFlags(o, flagsToCheck) ^ canonicalFlags; - if (deviation & 1 /* Export */) { - error(o.name, ts.Diagnostics.Overload_signatures_must_all_be_exported_or_not_exported); - } - else if (deviation & 2 /* Ambient */) { - error(o.name, ts.Diagnostics.Overload_signatures_must_all_be_ambient_or_non_ambient); - } - else if (deviation & (32 /* Private */ | 64 /* Protected */)) { - error(o.name, ts.Diagnostics.Overload_signatures_must_all_be_public_private_or_protected); - } - }); - } - } - function checkQuestionTokenAgreementBetweenOverloads(overloads, implementation, someHaveQuestionToken, allHaveQuestionToken) { - if (someHaveQuestionToken !== allHaveQuestionToken) { - var canonicalHasQuestionToken = ts.hasQuestionToken(getCanonicalOverload(overloads, implementation)); - ts.forEach(overloads, function (o) { - var deviation = ts.hasQuestionToken(o) !== canonicalHasQuestionToken; - if (deviation) { - error(o.name, ts.Diagnostics.Overload_signatures_must_all_be_optional_or_required); - } - }); - } - } - var flagsToCheck = 1 /* Export */ | 2 /* Ambient */ | 32 /* Private */ | 64 /* Protected */; - var someNodeFlags = 0; - var allNodeFlags = flagsToCheck; - var someHaveQuestionToken = false; - var allHaveQuestionToken = true; - var hasOverloads = false; - var bodyDeclaration; - var lastSeenNonAmbientDeclaration; - var previousDeclaration; - var declarations = symbol.declarations; - var isConstructor = (symbol.flags & 16384 /* Constructor */) !== 0; - function reportImplementationExpectedError(node) { - if (node.name && ts.nodeIsMissing(node.name)) { - return; - } - var seen = false; - var subsequentNode = ts.forEachChild(node.parent, function (c) { - if (seen) { - return c; - } - else { - seen = c === node; - } - }); - if (subsequentNode) { - if (subsequentNode.kind === node.kind) { - var errorNode_1 = subsequentNode.name || subsequentNode; - // TODO(jfreeman): These are methods, so handle computed name case - if (node.name && subsequentNode.name && node.name.text === subsequentNode.name.text) { - // the only situation when this is possible (same kind\same name but different symbol) - mixed static and instance class members - ts.Debug.assert(node.kind === 136 /* MethodDeclaration */ || node.kind === 135 /* MethodSignature */); - ts.Debug.assert((node.flags & 128 /* Static */) !== (subsequentNode.flags & 128 /* Static */)); - var diagnostic = node.flags & 128 /* Static */ ? ts.Diagnostics.Function_overload_must_be_static : ts.Diagnostics.Function_overload_must_not_be_static; - error(errorNode_1, diagnostic); - return; - } - else if (ts.nodeIsPresent(subsequentNode.body)) { - error(errorNode_1, ts.Diagnostics.Function_implementation_name_must_be_0, ts.declarationNameToString(node.name)); - return; - } - } - } - var errorNode = node.name || node; - if (isConstructor) { - error(errorNode, ts.Diagnostics.Constructor_implementation_is_missing); - } - else { - error(errorNode, ts.Diagnostics.Function_implementation_is_missing_or_not_immediately_following_the_declaration); - } - } - // when checking exported function declarations across modules check only duplicate implementations - // names and consistency of modifiers are verified when we check local symbol - var isExportSymbolInsideModule = symbol.parent && symbol.parent.flags & 1536 /* Module */; - var duplicateFunctionDeclaration = false; - var multipleConstructorImplementation = false; - for (var _i = 0; _i < declarations.length; _i++) { - var current = declarations[_i]; - var node = current; - var inAmbientContext = ts.isInAmbientContext(node); - var inAmbientContextOrInterface = node.parent.kind === 205 /* InterfaceDeclaration */ || node.parent.kind === 148 /* TypeLiteral */ || inAmbientContext; - if (inAmbientContextOrInterface) { - // check if declarations are consecutive only if they are non-ambient - // 1. ambient declarations can be interleaved - // i.e. this is legal - // declare function foo(); - // declare function bar(); - // declare function foo(); - // 2. mixing ambient and non-ambient declarations is a separate error that will be reported - do not want to report an extra one - previousDeclaration = undefined; - } - if (node.kind === 203 /* FunctionDeclaration */ || node.kind === 136 /* MethodDeclaration */ || node.kind === 135 /* MethodSignature */ || node.kind === 137 /* Constructor */) { - var currentNodeFlags = getEffectiveDeclarationFlags(node, flagsToCheck); - someNodeFlags |= currentNodeFlags; - allNodeFlags &= currentNodeFlags; - someHaveQuestionToken = someHaveQuestionToken || ts.hasQuestionToken(node); - allHaveQuestionToken = allHaveQuestionToken && ts.hasQuestionToken(node); - if (ts.nodeIsPresent(node.body) && bodyDeclaration) { - if (isConstructor) { - multipleConstructorImplementation = true; - } - else { - duplicateFunctionDeclaration = true; - } - } - else if (!isExportSymbolInsideModule && previousDeclaration && previousDeclaration.parent === node.parent && previousDeclaration.end !== node.pos) { - reportImplementationExpectedError(previousDeclaration); - } - if (ts.nodeIsPresent(node.body)) { - if (!bodyDeclaration) { - bodyDeclaration = node; - } - } - else { - hasOverloads = true; - } - previousDeclaration = node; - if (!inAmbientContextOrInterface) { - lastSeenNonAmbientDeclaration = node; - } - } - } - if (multipleConstructorImplementation) { - ts.forEach(declarations, function (declaration) { - error(declaration, ts.Diagnostics.Multiple_constructor_implementations_are_not_allowed); - }); - } - if (duplicateFunctionDeclaration) { - ts.forEach(declarations, function (declaration) { - error(declaration.name, ts.Diagnostics.Duplicate_function_implementation); - }); - } - if (!isExportSymbolInsideModule && lastSeenNonAmbientDeclaration && !lastSeenNonAmbientDeclaration.body) { - reportImplementationExpectedError(lastSeenNonAmbientDeclaration); - } - if (hasOverloads) { - checkFlagAgreementBetweenOverloads(declarations, bodyDeclaration, flagsToCheck, someNodeFlags, allNodeFlags); - checkQuestionTokenAgreementBetweenOverloads(declarations, bodyDeclaration, someHaveQuestionToken, allHaveQuestionToken); - if (bodyDeclaration) { - var signatures = getSignaturesOfSymbol(symbol); - var bodySignature = getSignatureFromDeclaration(bodyDeclaration); - // If the implementation signature has string literals, we will have reported an error in - // checkSpecializedSignatureDeclaration - if (!bodySignature.hasStringLiterals) { - // TypeScript 1.0 spec (April 2014): 6.1 - // If a function declaration includes overloads, the overloads determine the call - // signatures of the type given to the function object - // and the function implementation signature must be assignable to that type - // - // TypeScript 1.0 spec (April 2014): 3.8.4 - // Note that specialized call and construct signatures (section 3.7.2.4) are not significant when determining assignment compatibility - // Consider checking against specialized signatures too. Not doing so creates a type hole: - // - // function g(x: "hi", y: boolean); - // function g(x: string, y: {}); - // function g(x: string, y: string) { } - // - // The implementation is completely unrelated to the specialized signature, yet we do not check this. - for (var _a = 0; _a < signatures.length; _a++) { - var signature = signatures[_a]; - if (!signature.hasStringLiterals && !isSignatureAssignableTo(bodySignature, signature)) { - error(signature.declaration, ts.Diagnostics.Overload_signature_is_not_compatible_with_function_implementation); - break; - } - } - } - } - } - } - function checkExportsOnMergedDeclarations(node) { - if (!produceDiagnostics) { - return; - } - // Exports should be checked only if enclosing module contains both exported and non exported declarations. - // In case if all declarations are non-exported check is unnecessary. - // if localSymbol is defined on node then node itself is exported - check is required - var symbol = node.localSymbol; - if (!symbol) { - // local symbol is undefined => this declaration is non-exported. - // however symbol might contain other declarations that are exported - symbol = getSymbolOfNode(node); - if (!(symbol.flags & 7340032 /* Export */)) { - // this is a pure local symbol (all declarations are non-exported) - no need to check anything - return; - } - } - // run the check only for the first declaration in the list - if (ts.getDeclarationOfKind(symbol, node.kind) !== node) { - return; - } - // we use SymbolFlags.ExportValue, SymbolFlags.ExportType and SymbolFlags.ExportNamespace - // to denote disjoint declarationSpaces (without making new enum type). - var exportedDeclarationSpaces = 0; - var nonExportedDeclarationSpaces = 0; - ts.forEach(symbol.declarations, function (d) { - var declarationSpaces = getDeclarationSpaces(d); - if (getEffectiveDeclarationFlags(d, 1 /* Export */)) { - exportedDeclarationSpaces |= declarationSpaces; - } - else { - nonExportedDeclarationSpaces |= declarationSpaces; - } - }); - var commonDeclarationSpace = exportedDeclarationSpaces & nonExportedDeclarationSpaces; - if (commonDeclarationSpace) { - // declaration spaces for exported and non-exported declarations intersect - ts.forEach(symbol.declarations, function (d) { - if (getDeclarationSpaces(d) & commonDeclarationSpace) { - error(d.name, ts.Diagnostics.Individual_declarations_in_merged_declaration_0_must_be_all_exported_or_all_local, ts.declarationNameToString(d.name)); - } - }); - } - function getDeclarationSpaces(d) { - switch (d.kind) { - case 205 /* InterfaceDeclaration */: - return 2097152 /* ExportType */; - case 208 /* ModuleDeclaration */: - return d.name.kind === 8 /* StringLiteral */ || ts.getModuleInstanceState(d) !== 0 /* NonInstantiated */ - ? 4194304 /* ExportNamespace */ | 1048576 /* ExportValue */ - : 4194304 /* ExportNamespace */; - case 204 /* ClassDeclaration */: - case 207 /* EnumDeclaration */: - return 2097152 /* ExportType */ | 1048576 /* ExportValue */; - case 211 /* ImportEqualsDeclaration */: - var result = 0; - var target = resolveAlias(getSymbolOfNode(d)); - ts.forEach(target.declarations, function (d) { result |= getDeclarationSpaces(d); }); - return result; - default: - return 1048576 /* ExportValue */; - } - } - } - /** Check a decorator */ - function checkDecorator(node) { - var expression = node.expression; - var exprType = checkExpression(expression); - switch (node.parent.kind) { - case 204 /* ClassDeclaration */: - var classSymbol = getSymbolOfNode(node.parent); - var classConstructorType = getTypeOfSymbol(classSymbol); - var classDecoratorType = instantiateSingleCallFunctionType(getGlobalClassDecoratorType(), [classConstructorType]); - checkTypeAssignableTo(exprType, classDecoratorType, node); - break; - case 134 /* PropertyDeclaration */: - checkTypeAssignableTo(exprType, getGlobalPropertyDecoratorType(), node); - break; - case 136 /* MethodDeclaration */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - var methodType = getTypeOfNode(node.parent); - var methodDecoratorType = instantiateSingleCallFunctionType(getGlobalMethodDecoratorType(), [methodType]); - checkTypeAssignableTo(exprType, methodDecoratorType, node); - break; - case 131 /* Parameter */: - checkTypeAssignableTo(exprType, getGlobalParameterDecoratorType(), node); - break; - } - } - /** Checks a type reference node as an expression. */ - function checkTypeNodeAsExpression(node) { - // When we are emitting type metadata for decorators, we need to try to check the type - // as if it were an expression so that we can emit the type in a value position when we - // serialize the type metadata. - if (node && node.kind === 144 /* TypeReference */) { - var type = getTypeFromTypeNode(node); - var shouldCheckIfUnknownType = type === unknownType && compilerOptions.isolatedModules; - if (!type || (!shouldCheckIfUnknownType && type.flags & (2097279 /* Intrinsic */ | 132 /* NumberLike */ | 258 /* StringLike */))) { - return; - } - if (shouldCheckIfUnknownType || type.symbol.valueDeclaration) { - checkExpressionOrQualifiedName(node.typeName); - } - } - } - /** - * Checks the type annotation of an accessor declaration or property declaration as - * an expression if it is a type reference to a type with a value declaration. - */ - function checkTypeAnnotationAsExpression(node) { - switch (node.kind) { - case 134 /* PropertyDeclaration */: - checkTypeNodeAsExpression(node.type); - break; - case 131 /* Parameter */: - checkTypeNodeAsExpression(node.type); - break; - case 136 /* MethodDeclaration */: - checkTypeNodeAsExpression(node.type); - break; - case 138 /* GetAccessor */: - checkTypeNodeAsExpression(node.type); - break; - case 139 /* SetAccessor */: - checkTypeNodeAsExpression(getSetAccessorTypeAnnotationNode(node)); - break; - } - } - /** Checks the type annotation of the parameters of a function/method or the constructor of a class as expressions */ - function checkParameterTypeAnnotationsAsExpressions(node) { - // ensure all type annotations with a value declaration are checked as an expression - for (var _i = 0, _a = node.parameters; _i < _a.length; _i++) { - var parameter = _a[_i]; - checkTypeAnnotationAsExpression(parameter); - } - } - /** Check the decorators of a node */ - function checkDecorators(node) { - if (!node.decorators) { - return; - } - // skip this check for nodes that cannot have decorators. These should have already had an error reported by - // checkGrammarDecorators. - if (!ts.nodeCanBeDecorated(node)) { - return; - } - if (!compilerOptions.experimentalDecorators) { - error(node, ts.Diagnostics.Experimental_support_for_decorators_is_a_feature_that_is_subject_to_change_in_a_future_release_Specify_experimentalDecorators_to_remove_this_warning); - } - if (compilerOptions.emitDecoratorMetadata) { - // we only need to perform these checks if we are emitting serialized type metadata for the target of a decorator. - switch (node.kind) { - case 204 /* ClassDeclaration */: - var constructor = ts.getFirstConstructorWithBody(node); - if (constructor) { - checkParameterTypeAnnotationsAsExpressions(constructor); - } - break; - case 136 /* MethodDeclaration */: - checkParameterTypeAnnotationsAsExpressions(node); - // fall-through - case 139 /* SetAccessor */: - case 138 /* GetAccessor */: - case 134 /* PropertyDeclaration */: - case 131 /* Parameter */: - checkTypeAnnotationAsExpression(node); - break; - } - } - emitDecorate = true; - if (node.kind === 131 /* Parameter */) { - emitParam = true; - } - ts.forEach(node.decorators, checkDecorator); - } - function checkFunctionDeclaration(node) { - if (produceDiagnostics) { - checkFunctionLikeDeclaration(node) || - checkGrammarFunctionName(node.name) || - checkGrammarForGenerator(node); - checkCollisionWithCapturedSuperVariable(node, node.name); - checkCollisionWithCapturedThisVariable(node, node.name); - checkCollisionWithRequireExportsInGeneratedCode(node, node.name); - } - } - function checkFunctionLikeDeclaration(node) { - checkGrammarDeclarationNameInStrictMode(node); - checkDecorators(node); - checkSignatureDeclaration(node); - // Do not use hasDynamicName here, because that returns false for well known symbols. - // We want to perform checkComputedPropertyName for all computed properties, including - // well known symbols. - if (node.name && node.name.kind === 129 /* ComputedPropertyName */) { - // This check will account for methods in class/interface declarations, - // as well as accessors in classes/object literals - checkComputedPropertyName(node.name); - } - if (!ts.hasDynamicName(node)) { - // first we want to check the local symbol that contain this declaration - // - if node.localSymbol !== undefined - this is current declaration is exported and localSymbol points to the local symbol - // - if node.localSymbol === undefined - this node is non-exported so we can just pick the result of getSymbolOfNode - var symbol = getSymbolOfNode(node); - var localSymbol = node.localSymbol || symbol; - var firstDeclaration = ts.getDeclarationOfKind(localSymbol, node.kind); - // Only type check the symbol once - if (node === firstDeclaration) { - checkFunctionOrConstructorSymbol(localSymbol); - } - if (symbol.parent) { - // run check once for the first declaration - if (ts.getDeclarationOfKind(symbol, node.kind) === node) { - // run check on export symbol to check that modifiers agree across all exported declarations - checkFunctionOrConstructorSymbol(symbol); - } - } - } - checkSourceElement(node.body); - if (node.type && !isAccessor(node.kind) && !node.asteriskToken) { - checkIfNonVoidFunctionHasReturnExpressionsOrSingleThrowStatment(node, getTypeFromTypeNode(node.type)); - } - if (produceDiagnostics && !node.type) { - // Report an implicit any error if there is no body, no explicit return type, and node is not a private method - // in an ambient context - if (compilerOptions.noImplicitAny && ts.nodeIsMissing(node.body) && !isPrivateWithinAmbient(node)) { - reportImplicitAnyError(node, anyType); - } - if (node.asteriskToken && ts.nodeIsPresent(node.body)) { - // A generator with a body and no type annotation can still cause errors. It can error if the - // yielded values have no common supertype, or it can give an implicit any error if it has no - // yielded values. The only way to trigger these errors is to try checking its return type. - getReturnTypeOfSignature(getSignatureFromDeclaration(node)); - } - } - } - function checkBlock(node) { - // Grammar checking for SyntaxKind.Block - if (node.kind === 182 /* Block */) { - checkGrammarStatementInAmbientContext(node); - } - ts.forEach(node.statements, checkSourceElement); - if (ts.isFunctionBlock(node) || node.kind === 209 /* ModuleBlock */) { - checkFunctionExpressionBodies(node); - } - } - function checkCollisionWithArgumentsInGeneratedCode(node) { - // no rest parameters \ declaration context \ overload - no codegen impact - if (!ts.hasRestParameter(node) || ts.isInAmbientContext(node) || ts.nodeIsMissing(node.body)) { - return; - } - ts.forEach(node.parameters, function (p) { - if (p.name && !ts.isBindingPattern(p.name) && p.name.text === argumentsSymbol.name) { - error(p, ts.Diagnostics.Duplicate_identifier_arguments_Compiler_uses_arguments_to_initialize_rest_parameters); - } - }); - } - function needCollisionCheckForIdentifier(node, identifier, name) { - if (!(identifier && identifier.text === name)) { - return false; - } - if (node.kind === 134 /* PropertyDeclaration */ || - node.kind === 133 /* PropertySignature */ || - node.kind === 136 /* MethodDeclaration */ || - node.kind === 135 /* MethodSignature */ || - node.kind === 138 /* GetAccessor */ || - node.kind === 139 /* SetAccessor */) { - // it is ok to have member named '_super' or '_this' - member access is always qualified - return false; - } - if (ts.isInAmbientContext(node)) { - // ambient context - no codegen impact - return false; - } - var root = ts.getRootDeclaration(node); - if (root.kind === 131 /* Parameter */ && ts.nodeIsMissing(root.parent.body)) { - // just an overload - no codegen impact - return false; - } - return true; - } - function checkCollisionWithCapturedThisVariable(node, name) { - if (needCollisionCheckForIdentifier(node, name, "_this")) { - potentialThisCollisions.push(node); - } - } - // this function will run after checking the source file so 'CaptureThis' is correct for all nodes - function checkIfThisIsCapturedInEnclosingScope(node) { - var current = node; - while (current) { - if (getNodeCheckFlags(current) & 4 /* CaptureThis */) { - var isDeclaration_1 = node.kind !== 65 /* Identifier */; - if (isDeclaration_1) { - error(node.name, ts.Diagnostics.Duplicate_identifier_this_Compiler_uses_variable_declaration_this_to_capture_this_reference); - } - else { - error(node, ts.Diagnostics.Expression_resolves_to_variable_declaration_this_that_compiler_uses_to_capture_this_reference); - } - return; - } - current = current.parent; - } - } - function checkCollisionWithCapturedSuperVariable(node, name) { - if (!needCollisionCheckForIdentifier(node, name, "_super")) { - return; - } - // bubble up and find containing type - var enclosingClass = ts.getAncestor(node, 204 /* ClassDeclaration */); - // if containing type was not found or it is ambient - exit (no codegen) - if (!enclosingClass || ts.isInAmbientContext(enclosingClass)) { - return; - } - if (ts.getClassExtendsHeritageClauseElement(enclosingClass)) { - var isDeclaration_2 = node.kind !== 65 /* Identifier */; - if (isDeclaration_2) { - error(node, ts.Diagnostics.Duplicate_identifier_super_Compiler_uses_super_to_capture_base_class_reference); - } - else { - error(node, ts.Diagnostics.Expression_resolves_to_super_that_compiler_uses_to_capture_base_class_reference); - } - } - } - function checkCollisionWithRequireExportsInGeneratedCode(node, name) { - if (!needCollisionCheckForIdentifier(node, name, "require") && !needCollisionCheckForIdentifier(node, name, "exports")) { - return; - } - // Uninstantiated modules shouldnt do this check - if (node.kind === 208 /* ModuleDeclaration */ && ts.getModuleInstanceState(node) !== 1 /* Instantiated */) { - return; - } - // In case of variable declaration, node.parent is variable statement so look at the variable statement's parent - var parent = getDeclarationContainer(node); - if (parent.kind === 230 /* SourceFile */ && ts.isExternalModule(parent)) { - // If the declaration happens to be in external module, report error that require and exports are reserved keywords - error(name, ts.Diagnostics.Duplicate_identifier_0_Compiler_reserves_name_1_in_top_level_scope_of_a_module, ts.declarationNameToString(name), ts.declarationNameToString(name)); - } - } - function checkVarDeclaredNamesNotShadowed(node) { - // - ScriptBody : StatementList - // It is a Syntax Error if any element of the LexicallyDeclaredNames of StatementList - // also occurs in the VarDeclaredNames of StatementList. - // - Block : { StatementList } - // It is a Syntax Error if any element of the LexicallyDeclaredNames of StatementList - // also occurs in the VarDeclaredNames of StatementList. - // Variable declarations are hoisted to the top of their function scope. They can shadow - // block scoped declarations, which bind tighter. this will not be flagged as duplicate definition - // by the binder as the declaration scope is different. - // A non-initialized declaration is a no-op as the block declaration will resolve before the var - // declaration. the problem is if the declaration has an initializer. this will act as a write to the - // block declared value. this is fine for let, but not const. - // Only consider declarations with initializers, uninitialized let declarations will not - // step on a let/const variable. - // Do not consider let and const declarations, as duplicate block-scoped declarations - // are handled by the binder. - // We are only looking for let declarations that step on let\const declarations from a - // different scope. e.g.: - // { - // const x = 0; // localDeclarationSymbol obtained after name resolution will correspond to this declaration - // let x = 0; // symbol for this declaration will be 'symbol' - // } - // skip block-scoped variables and parameters - if ((ts.getCombinedNodeFlags(node) & 12288 /* BlockScoped */) !== 0 || ts.isParameterDeclaration(node)) { - return; - } - // skip variable declarations that don't have initializers - // NOTE: in ES6 spec initializer is required in variable declarations where name is binding pattern - // so we'll always treat binding elements as initialized - if (node.kind === 201 /* VariableDeclaration */ && !node.initializer) { - return; - } - var symbol = getSymbolOfNode(node); - if (symbol.flags & 1 /* FunctionScopedVariable */) { - var localDeclarationSymbol = resolveName(node, node.name.text, 3 /* Variable */, undefined, undefined); - if (localDeclarationSymbol && - localDeclarationSymbol !== symbol && - localDeclarationSymbol.flags & 2 /* BlockScopedVariable */) { - if (getDeclarationFlagsFromSymbol(localDeclarationSymbol) & 12288 /* BlockScoped */) { - var varDeclList = ts.getAncestor(localDeclarationSymbol.valueDeclaration, 202 /* VariableDeclarationList */); - var container = varDeclList.parent.kind === 183 /* VariableStatement */ && varDeclList.parent.parent - ? varDeclList.parent.parent - : undefined; - // names of block-scoped and function scoped variables can collide only - // if block scoped variable is defined in the function\module\source file scope (because of variable hoisting) - var namesShareScope = container && - (container.kind === 182 /* Block */ && ts.isFunctionLike(container.parent) || - container.kind === 209 /* ModuleBlock */ || - container.kind === 208 /* ModuleDeclaration */ || - container.kind === 230 /* SourceFile */); - // here we know that function scoped variable is shadowed by block scoped one - // if they are defined in the same scope - binder has already reported redeclaration error - // otherwise if variable has an initializer - show error that initialization will fail - // since LHS will be block scoped name instead of function scoped - if (!namesShareScope) { - var name_13 = symbolToString(localDeclarationSymbol); - error(node, ts.Diagnostics.Cannot_initialize_outer_scoped_variable_0_in_the_same_scope_as_block_scoped_declaration_1, name_13, name_13); - } - } - } - } - } - // Check that a parameter initializer contains no references to parameters declared to the right of itself - function checkParameterInitializer(node) { - if (ts.getRootDeclaration(node).kind !== 131 /* Parameter */) { - return; - } - var func = ts.getContainingFunction(node); - visit(node.initializer); - function visit(n) { - if (n.kind === 65 /* Identifier */) { - var referencedSymbol = getNodeLinks(n).resolvedSymbol; - // check FunctionLikeDeclaration.locals (stores parameters\function local variable) - // if it contains entry with a specified name and if this entry matches the resolved symbol - if (referencedSymbol && referencedSymbol !== unknownSymbol && getSymbol(func.locals, referencedSymbol.name, 107455 /* Value */) === referencedSymbol) { - if (referencedSymbol.valueDeclaration.kind === 131 /* Parameter */) { - if (referencedSymbol.valueDeclaration === node) { - error(n, ts.Diagnostics.Parameter_0_cannot_be_referenced_in_its_initializer, ts.declarationNameToString(node.name)); - return; - } - if (referencedSymbol.valueDeclaration.pos < node.pos) { - // legal case - parameter initializer references some parameter strictly on left of current parameter declaration - return; - } - } - error(n, ts.Diagnostics.Initializer_of_parameter_0_cannot_reference_identifier_1_declared_after_it, ts.declarationNameToString(node.name), ts.declarationNameToString(n)); - } - } - else { - ts.forEachChild(n, visit); - } - } - } - // Check variable, parameter, or property declaration - function checkVariableLikeDeclaration(node) { - checkGrammarDeclarationNameInStrictMode(node); - checkDecorators(node); - checkSourceElement(node.type); - // For a computed property, just check the initializer and exit - // Do not use hasDynamicName here, because that returns false for well known symbols. - // We want to perform checkComputedPropertyName for all computed properties, including - // well known symbols. - if (node.name.kind === 129 /* ComputedPropertyName */) { - checkComputedPropertyName(node.name); - if (node.initializer) { - checkExpressionCached(node.initializer); - } - } - // For a binding pattern, check contained binding elements - if (ts.isBindingPattern(node.name)) { - ts.forEach(node.name.elements, checkSourceElement); - } - // For a parameter declaration with an initializer, error and exit if the containing function doesn't have a body - if (node.initializer && ts.getRootDeclaration(node).kind === 131 /* Parameter */ && ts.nodeIsMissing(ts.getContainingFunction(node).body)) { - error(node, ts.Diagnostics.A_parameter_initializer_is_only_allowed_in_a_function_or_constructor_implementation); - return; - } - // For a binding pattern, validate the initializer and exit - if (ts.isBindingPattern(node.name)) { - if (node.initializer) { - checkTypeAssignableTo(checkExpressionCached(node.initializer), getWidenedTypeForVariableLikeDeclaration(node), node, undefined); - checkParameterInitializer(node); - } - return; - } - var symbol = getSymbolOfNode(node); - var type = getTypeOfVariableOrParameterOrProperty(symbol); - if (node === symbol.valueDeclaration) { - // Node is the primary declaration of the symbol, just validate the initializer - if (node.initializer) { - checkTypeAssignableTo(checkExpressionCached(node.initializer), type, node, undefined); - checkParameterInitializer(node); - } - } - else { - // Node is a secondary declaration, check that type is identical to primary declaration and check that - // initializer is consistent with type associated with the node - var declarationType = getWidenedTypeForVariableLikeDeclaration(node); - if (type !== unknownType && declarationType !== unknownType && !isTypeIdenticalTo(type, declarationType)) { - error(node.name, ts.Diagnostics.Subsequent_variable_declarations_must_have_the_same_type_Variable_0_must_be_of_type_1_but_here_has_type_2, ts.declarationNameToString(node.name), typeToString(type), typeToString(declarationType)); - } - if (node.initializer) { - checkTypeAssignableTo(checkExpressionCached(node.initializer), declarationType, node, undefined); - } - } - if (node.kind !== 134 /* PropertyDeclaration */ && node.kind !== 133 /* PropertySignature */) { - // We know we don't have a binding pattern or computed name here - checkExportsOnMergedDeclarations(node); - if (node.kind === 201 /* VariableDeclaration */ || node.kind === 155 /* BindingElement */) { - checkVarDeclaredNamesNotShadowed(node); - } - checkCollisionWithCapturedSuperVariable(node, node.name); - checkCollisionWithCapturedThisVariable(node, node.name); - checkCollisionWithRequireExportsInGeneratedCode(node, node.name); - } - } - function checkVariableDeclaration(node) { - checkGrammarVariableDeclaration(node); - return checkVariableLikeDeclaration(node); - } - function checkBindingElement(node) { - checkGrammarBindingElement(node); - return checkVariableLikeDeclaration(node); - } - function checkVariableStatement(node) { - // Grammar checking - checkGrammarDecorators(node) || checkGrammarModifiers(node) || checkGrammarVariableDeclarationList(node.declarationList) || checkGrammarForDisallowedLetOrConstStatement(node); - ts.forEach(node.declarationList.declarations, checkSourceElement); - } - function checkGrammarDisallowedModifiersInBlockOrObjectLiteralExpression(node) { - if (node.modifiers) { - if (inBlockOrObjectLiteralExpression(node)) { - return grammarErrorOnFirstToken(node, ts.Diagnostics.Modifiers_cannot_appear_here); - } - } - } - function inBlockOrObjectLiteralExpression(node) { - while (node) { - if (node.kind === 182 /* Block */ || node.kind === 157 /* ObjectLiteralExpression */) { - return true; - } - node = node.parent; - } - } - function checkExpressionStatement(node) { - // Grammar checking - checkGrammarStatementInAmbientContext(node); - checkExpression(node.expression); - } - function checkIfStatement(node) { - // Grammar checking - checkGrammarStatementInAmbientContext(node); - checkExpression(node.expression); - checkSourceElement(node.thenStatement); - checkSourceElement(node.elseStatement); - } - function checkDoStatement(node) { - // Grammar checking - checkGrammarStatementInAmbientContext(node); - checkSourceElement(node.statement); - checkExpression(node.expression); - } - function checkWhileStatement(node) { - // Grammar checking - checkGrammarStatementInAmbientContext(node); - checkExpression(node.expression); - checkSourceElement(node.statement); - } - function checkForStatement(node) { - // Grammar checking - if (!checkGrammarStatementInAmbientContext(node)) { - if (node.initializer && node.initializer.kind == 202 /* VariableDeclarationList */) { - checkGrammarVariableDeclarationList(node.initializer); - } - } - if (node.initializer) { - if (node.initializer.kind === 202 /* VariableDeclarationList */) { - ts.forEach(node.initializer.declarations, checkVariableDeclaration); - } - else { - checkExpression(node.initializer); - } - } - if (node.condition) - checkExpression(node.condition); - if (node.incrementor) - checkExpression(node.incrementor); - checkSourceElement(node.statement); - } - function checkForOfStatement(node) { - checkGrammarForInOrForOfStatement(node); - // Check the LHS and RHS - // If the LHS is a declaration, just check it as a variable declaration, which will in turn check the RHS - // via checkRightHandSideOfForOf. - // If the LHS is an expression, check the LHS, as a destructuring assignment or as a reference. - // Then check that the RHS is assignable to it. - if (node.initializer.kind === 202 /* VariableDeclarationList */) { - checkForInOrForOfVariableDeclaration(node); - } - else { - var varExpr = node.initializer; - var iteratedType = checkRightHandSideOfForOf(node.expression); - // There may be a destructuring assignment on the left side - if (varExpr.kind === 156 /* ArrayLiteralExpression */ || varExpr.kind === 157 /* ObjectLiteralExpression */) { - // iteratedType may be undefined. In this case, we still want to check the structure of - // varExpr, in particular making sure it's a valid LeftHandSideExpression. But we'd like - // to short circuit the type relation checking as much as possible, so we pass the unknownType. - checkDestructuringAssignment(varExpr, iteratedType || unknownType); - } - else { - var leftType = checkExpression(varExpr); - checkReferenceExpression(varExpr, ts.Diagnostics.Invalid_left_hand_side_in_for_of_statement, - /*constantVariableMessage*/ ts.Diagnostics.The_left_hand_side_of_a_for_of_statement_cannot_be_a_previously_defined_constant); - // iteratedType will be undefined if the rightType was missing properties/signatures - // required to get its iteratedType (like [Symbol.iterator] or next). This may be - // because we accessed properties from anyType, or it may have led to an error inside - // getElementTypeOfIterable. - if (iteratedType) { - checkTypeAssignableTo(iteratedType, leftType, varExpr, undefined); - } - } - } - checkSourceElement(node.statement); - } - function checkForInStatement(node) { - // Grammar checking - checkGrammarForInOrForOfStatement(node); - // TypeScript 1.0 spec (April 2014): 5.4 - // In a 'for-in' statement of the form - // for (let VarDecl in Expr) Statement - // VarDecl must be a variable declaration without a type annotation that declares a variable of type Any, - // and Expr must be an expression of type Any, an object type, or a type parameter type. - if (node.initializer.kind === 202 /* VariableDeclarationList */) { - var variable = node.initializer.declarations[0]; - if (variable && ts.isBindingPattern(variable.name)) { - error(variable.name, ts.Diagnostics.The_left_hand_side_of_a_for_in_statement_cannot_be_a_destructuring_pattern); - } - checkForInOrForOfVariableDeclaration(node); - } - else { - // In a 'for-in' statement of the form - // for (Var in Expr) Statement - // Var must be an expression classified as a reference of type Any or the String primitive type, - // and Expr must be an expression of type Any, an object type, or a type parameter type. - var varExpr = node.initializer; - var leftType = checkExpression(varExpr); - if (varExpr.kind === 156 /* ArrayLiteralExpression */ || varExpr.kind === 157 /* ObjectLiteralExpression */) { - error(varExpr, ts.Diagnostics.The_left_hand_side_of_a_for_in_statement_cannot_be_a_destructuring_pattern); - } - else if (!isTypeAnyOrAllConstituentTypesHaveKind(leftType, 258 /* StringLike */)) { - error(varExpr, ts.Diagnostics.The_left_hand_side_of_a_for_in_statement_must_be_of_type_string_or_any); - } - else { - // run check only former check succeeded to avoid cascading errors - checkReferenceExpression(varExpr, ts.Diagnostics.Invalid_left_hand_side_in_for_in_statement, ts.Diagnostics.The_left_hand_side_of_a_for_in_statement_cannot_be_a_previously_defined_constant); - } - } - var rightType = checkExpression(node.expression); - // unknownType is returned i.e. if node.expression is identifier whose name cannot be resolved - // in this case error about missing name is already reported - do not report extra one - if (!isTypeAnyOrAllConstituentTypesHaveKind(rightType, 48128 /* ObjectType */ | 512 /* TypeParameter */)) { - error(node.expression, ts.Diagnostics.The_right_hand_side_of_a_for_in_statement_must_be_of_type_any_an_object_type_or_a_type_parameter); - } - checkSourceElement(node.statement); - } - function checkForInOrForOfVariableDeclaration(iterationStatement) { - var variableDeclarationList = iterationStatement.initializer; - // checkGrammarForInOrForOfStatement will check that there is exactly one declaration. - if (variableDeclarationList.declarations.length >= 1) { - var decl = variableDeclarationList.declarations[0]; - checkVariableDeclaration(decl); - } - } - function checkRightHandSideOfForOf(rhsExpression) { - var expressionType = getTypeOfExpression(rhsExpression); - return checkIteratedTypeOrElementType(expressionType, rhsExpression, true); - } - function checkIteratedTypeOrElementType(inputType, errorNode, allowStringInput) { - if (isTypeAny(inputType)) { - return inputType; - } - if (languageVersion >= 2 /* ES6 */) { - return checkElementTypeOfIterable(inputType, errorNode); - } - if (allowStringInput) { - return checkElementTypeOfArrayOrString(inputType, errorNode); - } - if (isArrayLikeType(inputType)) { - var indexType = getIndexTypeOfType(inputType, 1 /* Number */); - if (indexType) { - return indexType; - } - } - error(errorNode, ts.Diagnostics.Type_0_is_not_an_array_type, typeToString(inputType)); - return unknownType; - } - /** - * When errorNode is undefined, it means we should not report any errors. - */ - function checkElementTypeOfIterable(iterable, errorNode) { - var elementType = getElementTypeOfIterable(iterable, errorNode); - // Now even though we have extracted the iteratedType, we will have to validate that the type - // passed in is actually an Iterable. - if (errorNode && elementType) { - checkTypeAssignableTo(iterable, createIterableType(elementType), errorNode); - } - return elementType || anyType; - } - /** - * We want to treat type as an iterable, and get the type it is an iterable of. The iterable - * must have the following structure (annotated with the names of the variables below): - * - * { // iterable - * [Symbol.iterator]: { // iteratorFunction - * (): Iterator - * } - * } - * - * T is the type we are after. At every level that involves analyzing return types - * of signatures, we union the return types of all the signatures. - * - * Another thing to note is that at any step of this process, we could run into a dead end, - * meaning either the property is missing, or we run into the anyType. If either of these things - * happens, we return undefined to signal that we could not find the iterated type. If a property - * is missing, and the previous step did not result in 'any', then we also give an error if the - * caller requested it. Then the caller can decide what to do in the case where there is no iterated - * type. This is different from returning anyType, because that would signify that we have matched the - * whole pattern and that T (above) is 'any'. - */ - function getElementTypeOfIterable(type, errorNode) { - if (isTypeAny(type)) { - return undefined; - } - var typeAsIterable = type; - if (!typeAsIterable.iterableElementType) { - // As an optimization, if the type is instantiated directly using the globalIterableType (Iterable), - // then just grab its type argument. - if ((type.flags & 4096 /* Reference */) && type.target === globalIterableType) { - typeAsIterable.iterableElementType = type.typeArguments[0]; - } - else { - var iteratorFunction = getTypeOfPropertyOfType(type, ts.getPropertyNameForKnownSymbolName("iterator")); - if (isTypeAny(iteratorFunction)) { - return undefined; - } - var iteratorFunctionSignatures = iteratorFunction ? getSignaturesOfType(iteratorFunction, 0 /* Call */) : emptyArray; - if (iteratorFunctionSignatures.length === 0) { - if (errorNode) { - error(errorNode, ts.Diagnostics.Type_must_have_a_Symbol_iterator_method_that_returns_an_iterator); - } - return undefined; - } - typeAsIterable.iterableElementType = getElementTypeOfIterator(getUnionType(ts.map(iteratorFunctionSignatures, getReturnTypeOfSignature)), errorNode); - } - } - return typeAsIterable.iterableElementType; - } - /** - * This function has very similar logic as getElementTypeOfIterable, except that it operates on - * Iterators instead of Iterables. Here is the structure: - * - * { // iterator - * next: { // iteratorNextFunction - * (): { // iteratorNextResult - * value: T // iteratorNextValue - * } - * } - * } - * - */ - function getElementTypeOfIterator(type, errorNode) { - if (isTypeAny(type)) { - return undefined; - } - var typeAsIterator = type; - if (!typeAsIterator.iteratorElementType) { - // As an optimization, if the type is instantiated directly using the globalIteratorType (Iterator), - // then just grab its type argument. - if ((type.flags & 4096 /* Reference */) && type.target === globalIteratorType) { - typeAsIterator.iteratorElementType = type.typeArguments[0]; - } - else { - var iteratorNextFunction = getTypeOfPropertyOfType(type, "next"); - if (isTypeAny(iteratorNextFunction)) { - return undefined; - } - var iteratorNextFunctionSignatures = iteratorNextFunction ? getSignaturesOfType(iteratorNextFunction, 0 /* Call */) : emptyArray; - if (iteratorNextFunctionSignatures.length === 0) { - if (errorNode) { - error(errorNode, ts.Diagnostics.An_iterator_must_have_a_next_method); - } - return undefined; - } - var iteratorNextResult = getUnionType(ts.map(iteratorNextFunctionSignatures, getReturnTypeOfSignature)); - if (isTypeAny(iteratorNextResult)) { - return undefined; - } - var iteratorNextValue = getTypeOfPropertyOfType(iteratorNextResult, "value"); - if (!iteratorNextValue) { - if (errorNode) { - error(errorNode, ts.Diagnostics.The_type_returned_by_the_next_method_of_an_iterator_must_have_a_value_property); - } - return undefined; - } - typeAsIterator.iteratorElementType = iteratorNextValue; - } - } - return typeAsIterator.iteratorElementType; - } - function getElementTypeOfIterableIterator(type) { - if (isTypeAny(type)) { - return undefined; - } - // As an optimization, if the type is instantiated directly using the globalIterableIteratorType (IterableIterator), - // then just grab its type argument. - if ((type.flags & 4096 /* Reference */) && type.target === globalIterableIteratorType) { - return type.typeArguments[0]; - } - return getElementTypeOfIterable(type, undefined) || - getElementTypeOfIterator(type, undefined); - } - /** - * This function does the following steps: - * 1. Break up arrayOrStringType (possibly a union) into its string constituents and array constituents. - * 2. Take the element types of the array constituents. - * 3. Return the union of the element types, and string if there was a string constitutent. - * - * For example: - * string -> string - * number[] -> number - * string[] | number[] -> string | number - * string | number[] -> string | number - * string | string[] | number[] -> string | number - * - * It also errors if: - * 1. Some constituent is neither a string nor an array. - * 2. Some constituent is a string and target is less than ES5 (because in ES3 string is not indexable). - */ - function checkElementTypeOfArrayOrString(arrayOrStringType, errorNode) { - ts.Debug.assert(languageVersion < 2 /* ES6 */); - // After we remove all types that are StringLike, we will know if there was a string constituent - // based on whether the remaining type is the same as the initial type. - var arrayType = removeTypesFromUnionType(arrayOrStringType, 258 /* StringLike */, true, true); - var hasStringConstituent = arrayOrStringType !== arrayType; - var reportedError = false; - if (hasStringConstituent) { - if (languageVersion < 1 /* ES5 */) { - error(errorNode, ts.Diagnostics.Using_a_string_in_a_for_of_statement_is_only_supported_in_ECMAScript_5_and_higher); - reportedError = true; - } - // Now that we've removed all the StringLike types, if no constituents remain, then the entire - // arrayOrStringType was a string. - if (arrayType === emptyObjectType) { - return stringType; - } - } - if (!isArrayLikeType(arrayType)) { - if (!reportedError) { - // Which error we report depends on whether there was a string constituent. For example, - // if the input type is number | string, we want to say that number is not an array type. - // But if the input was just number, we want to say that number is not an array type - // or a string type. - var diagnostic = hasStringConstituent - ? ts.Diagnostics.Type_0_is_not_an_array_type - : ts.Diagnostics.Type_0_is_not_an_array_type_or_a_string_type; - error(errorNode, diagnostic, typeToString(arrayType)); - } - return hasStringConstituent ? stringType : unknownType; - } - var arrayElementType = getIndexTypeOfType(arrayType, 1 /* Number */) || unknownType; - if (hasStringConstituent) { - // This is just an optimization for the case where arrayOrStringType is string | string[] - if (arrayElementType.flags & 258 /* StringLike */) { - return stringType; - } - return getUnionType([arrayElementType, stringType]); - } - return arrayElementType; - } - function checkBreakOrContinueStatement(node) { - // Grammar checking - checkGrammarStatementInAmbientContext(node) || checkGrammarBreakOrContinueStatement(node); - // TODO: Check that target label is valid - } - function isGetAccessorWithAnnotatatedSetAccessor(node) { - return !!(node.kind === 138 /* GetAccessor */ && getSetAccessorTypeAnnotationNode(ts.getDeclarationOfKind(node.symbol, 139 /* SetAccessor */))); - } - function checkReturnStatement(node) { - // Grammar checking - if (!checkGrammarStatementInAmbientContext(node)) { - var functionBlock = ts.getContainingFunction(node); - if (!functionBlock) { - grammarErrorOnFirstToken(node, ts.Diagnostics.A_return_statement_can_only_be_used_within_a_function_body); - } - } - if (node.expression) { - var func = ts.getContainingFunction(node); - if (func) { - var signature = getSignatureFromDeclaration(func); - var returnType = getReturnTypeOfSignature(signature); - var exprType = checkExpressionCached(node.expression); - if (func.asteriskToken) { - // A generator does not need its return expressions checked against its return type. - // Instead, the yield expressions are checked against the element type. - // TODO: Check return expressions of generators when return type tracking is added - // for generators. - return; - } - if (func.kind === 139 /* SetAccessor */) { - error(node.expression, ts.Diagnostics.Setters_cannot_return_a_value); - } - else if (func.kind === 137 /* Constructor */) { - if (!isTypeAssignableTo(exprType, returnType)) { - error(node.expression, ts.Diagnostics.Return_type_of_constructor_signature_must_be_assignable_to_the_instance_type_of_the_class); - } - } - else if (func.type || isGetAccessorWithAnnotatatedSetAccessor(func) || signature.typePredicate) { - checkTypeAssignableTo(exprType, returnType, node.expression, undefined); - } - } - } - } - function checkWithStatement(node) { - // Grammar checking for withStatement - if (!checkGrammarStatementInAmbientContext(node)) { - if (node.parserContextFlags & 1 /* StrictMode */) { - grammarErrorOnFirstToken(node, ts.Diagnostics.with_statements_are_not_allowed_in_strict_mode); - } - } - checkExpression(node.expression); - error(node.expression, ts.Diagnostics.All_symbols_within_a_with_block_will_be_resolved_to_any); - } - function checkSwitchStatement(node) { - // Grammar checking - checkGrammarStatementInAmbientContext(node); - var firstDefaultClause; - var hasDuplicateDefaultClause = false; - var expressionType = checkExpression(node.expression); - ts.forEach(node.caseBlock.clauses, function (clause) { - // Grammar check for duplicate default clauses, skip if we already report duplicate default clause - if (clause.kind === 224 /* DefaultClause */ && !hasDuplicateDefaultClause) { - if (firstDefaultClause === undefined) { - firstDefaultClause = clause; - } - else { - var sourceFile = ts.getSourceFileOfNode(node); - var start = ts.skipTrivia(sourceFile.text, clause.pos); - var end = clause.statements.length > 0 ? clause.statements[0].pos : clause.end; - grammarErrorAtPos(sourceFile, start, end - start, ts.Diagnostics.A_default_clause_cannot_appear_more_than_once_in_a_switch_statement); - hasDuplicateDefaultClause = true; - } - } - if (produceDiagnostics && clause.kind === 223 /* CaseClause */) { - var caseClause = clause; - // TypeScript 1.0 spec (April 2014):5.9 - // In a 'switch' statement, each 'case' expression must be of a type that is assignable to or from the type of the 'switch' expression. - var caseType = checkExpression(caseClause.expression); - if (!isTypeAssignableTo(expressionType, caseType)) { - // check 'expressionType isAssignableTo caseType' failed, try the reversed check and report errors if it fails - checkTypeAssignableTo(caseType, expressionType, caseClause.expression, undefined); - } - } - ts.forEach(clause.statements, checkSourceElement); - }); - } - function checkLabeledStatement(node) { - // Grammar checking - if (!checkGrammarStatementInAmbientContext(node)) { - var current = node.parent; - while (current) { - if (ts.isFunctionLike(current)) { - break; - } - if (current.kind === 197 /* LabeledStatement */ && current.label.text === node.label.text) { - var sourceFile = ts.getSourceFileOfNode(node); - grammarErrorOnNode(node.label, ts.Diagnostics.Duplicate_label_0, ts.getTextOfNodeFromSourceText(sourceFile.text, node.label)); - break; - } - current = current.parent; - } - } - // ensure that label is unique - checkSourceElement(node.statement); - } - function checkThrowStatement(node) { - // Grammar checking - if (!checkGrammarStatementInAmbientContext(node)) { - if (node.expression === undefined) { - grammarErrorAfterFirstToken(node, ts.Diagnostics.Line_break_not_permitted_here); - } - } - if (node.expression) { - checkExpression(node.expression); - } - } - function checkTryStatement(node) { - // Grammar checking - checkGrammarStatementInAmbientContext(node); - checkBlock(node.tryBlock); - var catchClause = node.catchClause; - if (catchClause) { - // Grammar checking - if (catchClause.variableDeclaration) { - if (catchClause.variableDeclaration.name.kind !== 65 /* Identifier */) { - grammarErrorOnFirstToken(catchClause.variableDeclaration.name, ts.Diagnostics.Catch_clause_variable_name_must_be_an_identifier); - } - else if (catchClause.variableDeclaration.type) { - grammarErrorOnFirstToken(catchClause.variableDeclaration.type, ts.Diagnostics.Catch_clause_variable_cannot_have_a_type_annotation); - } - else if (catchClause.variableDeclaration.initializer) { - grammarErrorOnFirstToken(catchClause.variableDeclaration.initializer, ts.Diagnostics.Catch_clause_variable_cannot_have_an_initializer); - } - else { - var identifierName = catchClause.variableDeclaration.name.text; - var locals = catchClause.block.locals; - if (locals && ts.hasProperty(locals, identifierName)) { - var localSymbol = locals[identifierName]; - if (localSymbol && (localSymbol.flags & 2 /* BlockScopedVariable */) !== 0) { - grammarErrorOnNode(localSymbol.valueDeclaration, ts.Diagnostics.Cannot_redeclare_identifier_0_in_catch_clause, identifierName); - } - } - // It is a SyntaxError if a TryStatement with a Catch occurs within strict code and the Identifier of the - // Catch production is eval or arguments - checkGrammarEvalOrArgumentsInStrictMode(node, catchClause.variableDeclaration.name); - } - } - checkBlock(catchClause.block); - } - if (node.finallyBlock) { - checkBlock(node.finallyBlock); - } - } - function checkIndexConstraints(type) { - var declaredNumberIndexer = getIndexDeclarationOfSymbol(type.symbol, 1 /* Number */); - var declaredStringIndexer = getIndexDeclarationOfSymbol(type.symbol, 0 /* String */); - var stringIndexType = getIndexTypeOfType(type, 0 /* String */); - var numberIndexType = getIndexTypeOfType(type, 1 /* Number */); - if (stringIndexType || numberIndexType) { - ts.forEach(getPropertiesOfObjectType(type), function (prop) { - var propType = getTypeOfSymbol(prop); - checkIndexConstraintForProperty(prop, propType, type, declaredStringIndexer, stringIndexType, 0 /* String */); - checkIndexConstraintForProperty(prop, propType, type, declaredNumberIndexer, numberIndexType, 1 /* Number */); - }); - if (type.flags & 1024 /* Class */ && type.symbol.valueDeclaration.kind === 204 /* ClassDeclaration */) { - var classDeclaration = type.symbol.valueDeclaration; - for (var _i = 0, _a = classDeclaration.members; _i < _a.length; _i++) { - var member = _a[_i]; - // Only process instance properties with computed names here. - // Static properties cannot be in conflict with indexers, - // and properties with literal names were already checked. - if (!(member.flags & 128 /* Static */) && ts.hasDynamicName(member)) { - var propType = getTypeOfSymbol(member.symbol); - checkIndexConstraintForProperty(member.symbol, propType, type, declaredStringIndexer, stringIndexType, 0 /* String */); - checkIndexConstraintForProperty(member.symbol, propType, type, declaredNumberIndexer, numberIndexType, 1 /* Number */); - } - } - } - } - var errorNode; - if (stringIndexType && numberIndexType) { - errorNode = declaredNumberIndexer || declaredStringIndexer; - // condition 'errorNode === undefined' may appear if types does not declare nor string neither number indexer - if (!errorNode && (type.flags & 2048 /* Interface */)) { - var someBaseTypeHasBothIndexers = ts.forEach(getBaseTypes(type), function (base) { return getIndexTypeOfType(base, 0 /* String */) && getIndexTypeOfType(base, 1 /* Number */); }); - errorNode = someBaseTypeHasBothIndexers ? undefined : type.symbol.declarations[0]; - } - } - if (errorNode && !isTypeAssignableTo(numberIndexType, stringIndexType)) { - error(errorNode, ts.Diagnostics.Numeric_index_type_0_is_not_assignable_to_string_index_type_1, typeToString(numberIndexType), typeToString(stringIndexType)); - } - function checkIndexConstraintForProperty(prop, propertyType, containingType, indexDeclaration, indexType, indexKind) { - if (!indexType) { - return; - } - // index is numeric and property name is not valid numeric literal - if (indexKind === 1 /* Number */ && !isNumericName(prop.valueDeclaration.name)) { - return; - } - // perform property check if property or indexer is declared in 'type' - // this allows to rule out cases when both property and indexer are inherited from the base class - var errorNode; - if (prop.valueDeclaration.name.kind === 129 /* ComputedPropertyName */ || prop.parent === containingType.symbol) { - errorNode = prop.valueDeclaration; - } - else if (indexDeclaration) { - errorNode = indexDeclaration; - } - else if (containingType.flags & 2048 /* Interface */) { - // for interfaces property and indexer might be inherited from different bases - // check if any base class already has both property and indexer. - // check should be performed only if 'type' is the first type that brings property\indexer together - var someBaseClassHasBothPropertyAndIndexer = ts.forEach(getBaseTypes(containingType), function (base) { return getPropertyOfObjectType(base, prop.name) && getIndexTypeOfType(base, indexKind); }); - errorNode = someBaseClassHasBothPropertyAndIndexer ? undefined : containingType.symbol.declarations[0]; - } - if (errorNode && !isTypeAssignableTo(propertyType, indexType)) { - var errorMessage = indexKind === 0 /* String */ - ? ts.Diagnostics.Property_0_of_type_1_is_not_assignable_to_string_index_type_2 - : ts.Diagnostics.Property_0_of_type_1_is_not_assignable_to_numeric_index_type_2; - error(errorNode, errorMessage, symbolToString(prop), typeToString(propertyType), typeToString(indexType)); - } - } - } - function checkTypeNameIsReserved(name, message) { - // TS 1.0 spec (April 2014): 3.6.1 - // The predefined type keywords are reserved and cannot be used as names of user defined types. - switch (name.text) { - case "any": - case "number": - case "boolean": - case "string": - case "symbol": - case "void": - error(name, message, name.text); - } - } - // Check each type parameter and check that list has no duplicate type parameter declarations - function checkTypeParameters(typeParameterDeclarations) { - if (typeParameterDeclarations) { - for (var i = 0, n = typeParameterDeclarations.length; i < n; i++) { - var node = typeParameterDeclarations[i]; - checkTypeParameter(node); - if (produceDiagnostics) { - for (var j = 0; j < i; j++) { - if (typeParameterDeclarations[j].symbol === node.symbol) { - error(node.name, ts.Diagnostics.Duplicate_identifier_0, ts.declarationNameToString(node.name)); - } - } - } - } - } - } - function checkClassExpression(node) { - grammarErrorOnNode(node, ts.Diagnostics.class_expressions_are_not_currently_supported); - ts.forEach(node.members, checkSourceElement); - return unknownType; - } - function checkClassDeclaration(node) { - checkGrammarDeclarationNameInStrictMode(node); - // Grammar checking - if (!node.name && !(node.flags & 256 /* Default */)) { - grammarErrorOnFirstToken(node, ts.Diagnostics.A_class_declaration_without_the_default_modifier_must_have_a_name); - } - checkGrammarClassDeclarationHeritageClauses(node); - checkDecorators(node); - if (node.name) { - checkTypeNameIsReserved(node.name, ts.Diagnostics.Class_name_cannot_be_0); - checkCollisionWithCapturedThisVariable(node, node.name); - checkCollisionWithRequireExportsInGeneratedCode(node, node.name); - } - checkTypeParameters(node.typeParameters); - checkExportsOnMergedDeclarations(node); - var symbol = getSymbolOfNode(node); - var type = getDeclaredTypeOfSymbol(symbol); - var staticType = getTypeOfSymbol(symbol); - var baseTypeNode = ts.getClassExtendsHeritageClauseElement(node); - if (baseTypeNode) { - if (!ts.isSupportedExpressionWithTypeArguments(baseTypeNode)) { - error(baseTypeNode.expression, ts.Diagnostics.Only_identifiers_Slashqualified_names_with_optional_type_arguments_are_currently_supported_in_a_class_extends_clauses); - } - emitExtends = emitExtends || !ts.isInAmbientContext(node); - checkExpressionWithTypeArguments(baseTypeNode); - } - var baseTypes = getBaseTypes(type); - if (baseTypes.length) { - if (produceDiagnostics) { - var baseType = baseTypes[0]; - checkTypeAssignableTo(type, baseType, node.name || node, ts.Diagnostics.Class_0_incorrectly_extends_base_class_1); - var staticBaseType = getTypeOfSymbol(baseType.symbol); - checkTypeAssignableTo(staticType, getTypeWithoutConstructors(staticBaseType), node.name || node, ts.Diagnostics.Class_static_side_0_incorrectly_extends_base_class_static_side_1); - if (baseType.symbol !== resolveEntityName(baseTypeNode.expression, 107455 /* Value */)) { - error(baseTypeNode, ts.Diagnostics.Type_name_0_in_extends_clause_does_not_reference_constructor_function_for_0, typeToString(baseType)); - } - checkKindsOfPropertyMemberOverrides(type, baseType); - } - } - if (baseTypes.length || (baseTypeNode && compilerOptions.isolatedModules)) { - // Check that base type can be evaluated as expression - checkExpressionOrQualifiedName(baseTypeNode.expression); - } - var implementedTypeNodes = ts.getClassImplementsHeritageClauseElements(node); - if (implementedTypeNodes) { - ts.forEach(implementedTypeNodes, function (typeRefNode) { - if (!ts.isSupportedExpressionWithTypeArguments(typeRefNode)) { - error(typeRefNode.expression, ts.Diagnostics.A_class_can_only_implement_an_identifier_Slashqualified_name_with_optional_type_arguments); - } - checkExpressionWithTypeArguments(typeRefNode); - if (produceDiagnostics) { - var t = getTypeFromTypeNode(typeRefNode); - if (t !== unknownType) { - var declaredType = (t.flags & 4096 /* Reference */) ? t.target : t; - if (declaredType.flags & (1024 /* Class */ | 2048 /* Interface */)) { - checkTypeAssignableTo(type, t, node.name || node, ts.Diagnostics.Class_0_incorrectly_implements_interface_1); - } - else { - error(typeRefNode, ts.Diagnostics.A_class_may_only_implement_another_class_or_interface); - } - } - } - }); - } - ts.forEach(node.members, checkSourceElement); - if (produceDiagnostics) { - checkIndexConstraints(type); - checkTypeForDuplicateIndexSignatures(node); - } - } - function getTargetSymbol(s) { - // if symbol is instantiated its flags are not copied from the 'target' - // so we'll need to get back original 'target' symbol to work with correct set of flags - return s.flags & 16777216 /* Instantiated */ ? getSymbolLinks(s).target : s; - } - function checkKindsOfPropertyMemberOverrides(type, baseType) { - // TypeScript 1.0 spec (April 2014): 8.2.3 - // A derived class inherits all members from its base class it doesn't override. - // Inheritance means that a derived class implicitly contains all non - overridden members of the base class. - // Both public and private property members are inherited, but only public property members can be overridden. - // A property member in a derived class is said to override a property member in a base class - // when the derived class property member has the same name and kind(instance or static) - // as the base class property member. - // The type of an overriding property member must be assignable(section 3.8.4) - // to the type of the overridden property member, or otherwise a compile - time error occurs. - // Base class instance member functions can be overridden by derived class instance member functions, - // but not by other kinds of members. - // Base class instance member variables and accessors can be overridden by - // derived class instance member variables and accessors, but not by other kinds of members. - // NOTE: assignability is checked in checkClassDeclaration - var baseProperties = getPropertiesOfObjectType(baseType); - for (var _i = 0; _i < baseProperties.length; _i++) { - var baseProperty = baseProperties[_i]; - var base = getTargetSymbol(baseProperty); - if (base.flags & 134217728 /* Prototype */) { - continue; - } - var derived = getTargetSymbol(getPropertyOfObjectType(type, base.name)); - if (derived) { - var baseDeclarationFlags = getDeclarationFlagsFromSymbol(base); - var derivedDeclarationFlags = getDeclarationFlagsFromSymbol(derived); - if ((baseDeclarationFlags & 32 /* Private */) || (derivedDeclarationFlags & 32 /* Private */)) { - // either base or derived property is private - not override, skip it - continue; - } - if ((baseDeclarationFlags & 128 /* Static */) !== (derivedDeclarationFlags & 128 /* Static */)) { - // value of 'static' is not the same for properties - not override, skip it - continue; - } - if ((base.flags & derived.flags & 8192 /* Method */) || ((base.flags & 98308 /* PropertyOrAccessor */) && (derived.flags & 98308 /* PropertyOrAccessor */))) { - // method is overridden with method or property/accessor is overridden with property/accessor - correct case - continue; - } - var errorMessage = void 0; - if (base.flags & 8192 /* Method */) { - if (derived.flags & 98304 /* Accessor */) { - errorMessage = ts.Diagnostics.Class_0_defines_instance_member_function_1_but_extended_class_2_defines_it_as_instance_member_accessor; - } - else { - ts.Debug.assert((derived.flags & 4 /* Property */) !== 0); - errorMessage = ts.Diagnostics.Class_0_defines_instance_member_function_1_but_extended_class_2_defines_it_as_instance_member_property; - } - } - else if (base.flags & 4 /* Property */) { - ts.Debug.assert((derived.flags & 8192 /* Method */) !== 0); - errorMessage = ts.Diagnostics.Class_0_defines_instance_member_property_1_but_extended_class_2_defines_it_as_instance_member_function; - } - else { - ts.Debug.assert((base.flags & 98304 /* Accessor */) !== 0); - ts.Debug.assert((derived.flags & 8192 /* Method */) !== 0); - errorMessage = ts.Diagnostics.Class_0_defines_instance_member_accessor_1_but_extended_class_2_defines_it_as_instance_member_function; - } - error(derived.valueDeclaration.name, errorMessage, typeToString(baseType), symbolToString(base), typeToString(type)); - } - } - } - function isAccessor(kind) { - return kind === 138 /* GetAccessor */ || kind === 139 /* SetAccessor */; - } - function areTypeParametersIdentical(list1, list2) { - if (!list1 && !list2) { - return true; - } - if (!list1 || !list2 || list1.length !== list2.length) { - return false; - } - // TypeScript 1.0 spec (April 2014): - // When a generic interface has multiple declarations, all declarations must have identical type parameter - // lists, i.e. identical type parameter names with identical constraints in identical order. - for (var i = 0, len = list1.length; i < len; i++) { - var tp1 = list1[i]; - var tp2 = list2[i]; - if (tp1.name.text !== tp2.name.text) { - return false; - } - if (!tp1.constraint && !tp2.constraint) { - continue; - } - if (!tp1.constraint || !tp2.constraint) { - return false; - } - if (!isTypeIdenticalTo(getTypeFromTypeNode(tp1.constraint), getTypeFromTypeNode(tp2.constraint))) { - return false; - } - } - return true; - } - function checkInheritedPropertiesAreIdentical(type, typeNode) { - var baseTypes = getBaseTypes(type); - if (baseTypes.length < 2) { - return true; - } - var seen = {}; - ts.forEach(resolveDeclaredMembers(type).declaredProperties, function (p) { seen[p.name] = { prop: p, containingType: type }; }); - var ok = true; - for (var _i = 0; _i < baseTypes.length; _i++) { - var base = baseTypes[_i]; - var properties = getPropertiesOfObjectType(base); - for (var _a = 0; _a < properties.length; _a++) { - var prop = properties[_a]; - if (!ts.hasProperty(seen, prop.name)) { - seen[prop.name] = { prop: prop, containingType: base }; - } - else { - var existing = seen[prop.name]; - var isInheritedProperty = existing.containingType !== type; - if (isInheritedProperty && !isPropertyIdenticalTo(existing.prop, prop)) { - ok = false; - var typeName1 = typeToString(existing.containingType); - var typeName2 = typeToString(base); - var errorInfo = ts.chainDiagnosticMessages(undefined, ts.Diagnostics.Named_property_0_of_types_1_and_2_are_not_identical, symbolToString(prop), typeName1, typeName2); - errorInfo = ts.chainDiagnosticMessages(errorInfo, ts.Diagnostics.Interface_0_cannot_simultaneously_extend_types_1_and_2, typeToString(type), typeName1, typeName2); - diagnostics.add(ts.createDiagnosticForNodeFromMessageChain(typeNode, errorInfo)); - } - } - } - } - return ok; - } - function checkInterfaceDeclaration(node) { - // Grammar checking - checkGrammarDeclarationNameInStrictMode(node) || checkGrammarDecorators(node) || checkGrammarModifiers(node) || checkGrammarInterfaceDeclaration(node); - checkTypeParameters(node.typeParameters); - if (produceDiagnostics) { - checkTypeNameIsReserved(node.name, ts.Diagnostics.Interface_name_cannot_be_0); - checkExportsOnMergedDeclarations(node); - var symbol = getSymbolOfNode(node); - var firstInterfaceDecl = ts.getDeclarationOfKind(symbol, 205 /* InterfaceDeclaration */); - if (symbol.declarations.length > 1) { - if (node !== firstInterfaceDecl && !areTypeParametersIdentical(firstInterfaceDecl.typeParameters, node.typeParameters)) { - error(node.name, ts.Diagnostics.All_declarations_of_an_interface_must_have_identical_type_parameters); - } - } - // Only check this symbol once - if (node === firstInterfaceDecl) { - var type = getDeclaredTypeOfSymbol(symbol); - // run subsequent checks only if first set succeeded - if (checkInheritedPropertiesAreIdentical(type, node.name)) { - ts.forEach(getBaseTypes(type), function (baseType) { - checkTypeAssignableTo(type, baseType, node.name, ts.Diagnostics.Interface_0_incorrectly_extends_interface_1); - }); - checkIndexConstraints(type); - } - } - } - ts.forEach(ts.getInterfaceBaseTypeNodes(node), function (heritageElement) { - if (!ts.isSupportedExpressionWithTypeArguments(heritageElement)) { - error(heritageElement.expression, ts.Diagnostics.An_interface_can_only_extend_an_identifier_Slashqualified_name_with_optional_type_arguments); - } - checkExpressionWithTypeArguments(heritageElement); - }); - ts.forEach(node.members, checkSourceElement); - if (produceDiagnostics) { - checkTypeForDuplicateIndexSignatures(node); - } - } - function checkTypeAliasDeclaration(node) { - // Grammar checking - checkGrammarDecorators(node) || checkGrammarModifiers(node); - checkTypeNameIsReserved(node.name, ts.Diagnostics.Type_alias_name_cannot_be_0); - checkSourceElement(node.type); - } - function computeEnumMemberValues(node) { - var nodeLinks = getNodeLinks(node); - if (!(nodeLinks.flags & 128 /* EnumValuesComputed */)) { - var enumSymbol = getSymbolOfNode(node); - var enumType = getDeclaredTypeOfSymbol(enumSymbol); - var autoValue = 0; - var ambient = ts.isInAmbientContext(node); - var enumIsConst = ts.isConst(node); - ts.forEach(node.members, function (member) { - if (member.name.kind !== 129 /* ComputedPropertyName */ && isNumericLiteralName(member.name.text)) { - error(member.name, ts.Diagnostics.An_enum_member_cannot_have_a_numeric_name); - } - var initializer = member.initializer; - if (initializer) { - autoValue = getConstantValueForEnumMemberInitializer(initializer); - if (autoValue === undefined) { - if (enumIsConst) { - error(initializer, ts.Diagnostics.In_const_enum_declarations_member_initializer_must_be_constant_expression); - } - else if (!ambient) { - // Only here do we need to check that the initializer is assignable to the enum type. - // If it is a constant value (not undefined), it is syntactically constrained to be a number. - // Also, we do not need to check this for ambients because there is already - // a syntax error if it is not a constant. - checkTypeAssignableTo(checkExpression(initializer), enumType, initializer, undefined); - } - } - else if (enumIsConst) { - if (isNaN(autoValue)) { - error(initializer, ts.Diagnostics.const_enum_member_initializer_was_evaluated_to_disallowed_value_NaN); - } - else if (!isFinite(autoValue)) { - error(initializer, ts.Diagnostics.const_enum_member_initializer_was_evaluated_to_a_non_finite_value); - } - } - } - else if (ambient && !enumIsConst) { - autoValue = undefined; - } - if (autoValue !== undefined) { - getNodeLinks(member).enumMemberValue = autoValue++; - } - }); - nodeLinks.flags |= 128 /* EnumValuesComputed */; - } - function getConstantValueForEnumMemberInitializer(initializer) { - return evalConstant(initializer); - function evalConstant(e) { - switch (e.kind) { - case 170 /* PrefixUnaryExpression */: - var value = evalConstant(e.operand); - if (value === undefined) { - return undefined; - } - switch (e.operator) { - case 33 /* PlusToken */: return value; - case 34 /* MinusToken */: return -value; - case 47 /* TildeToken */: return ~value; - } - return undefined; - case 172 /* BinaryExpression */: - var left = evalConstant(e.left); - if (left === undefined) { - return undefined; - } - var right = evalConstant(e.right); - if (right === undefined) { - return undefined; - } - switch (e.operatorToken.kind) { - case 44 /* BarToken */: return left | right; - case 43 /* AmpersandToken */: return left & right; - case 41 /* GreaterThanGreaterThanToken */: return left >> right; - case 42 /* GreaterThanGreaterThanGreaterThanToken */: return left >>> right; - case 40 /* LessThanLessThanToken */: return left << right; - case 45 /* CaretToken */: return left ^ right; - case 35 /* AsteriskToken */: return left * right; - case 36 /* SlashToken */: return left / right; - case 33 /* PlusToken */: return left + right; - case 34 /* MinusToken */: return left - right; - case 37 /* PercentToken */: return left % right; - } - return undefined; - case 7 /* NumericLiteral */: - return +e.text; - case 164 /* ParenthesizedExpression */: - return evalConstant(e.expression); - case 65 /* Identifier */: - case 159 /* ElementAccessExpression */: - case 158 /* PropertyAccessExpression */: - var member = initializer.parent; - var currentType = getTypeOfSymbol(getSymbolOfNode(member.parent)); - var enumType; - var propertyName; - if (e.kind === 65 /* Identifier */) { - // unqualified names can refer to member that reside in different declaration of the enum so just doing name resolution won't work. - // instead pick current enum type and later try to fetch member from the type - enumType = currentType; - propertyName = e.text; - } - else { - var expression; - if (e.kind === 159 /* ElementAccessExpression */) { - if (e.argumentExpression === undefined || - e.argumentExpression.kind !== 8 /* StringLiteral */) { - return undefined; - } - expression = e.expression; - propertyName = e.argumentExpression.text; - } - else { - expression = e.expression; - propertyName = e.name.text; - } - // expression part in ElementAccess\PropertyAccess should be either identifier or dottedName - var current = expression; - while (current) { - if (current.kind === 65 /* Identifier */) { - break; - } - else if (current.kind === 158 /* PropertyAccessExpression */) { - current = current.expression; - } - else { - return undefined; - } - } - enumType = checkExpression(expression); - // allow references to constant members of other enums - if (!(enumType.symbol && (enumType.symbol.flags & 384 /* Enum */))) { - return undefined; - } - } - if (propertyName === undefined) { - return undefined; - } - var property = getPropertyOfObjectType(enumType, propertyName); - if (!property || !(property.flags & 8 /* EnumMember */)) { - return undefined; - } - var propertyDecl = property.valueDeclaration; - // self references are illegal - if (member === propertyDecl) { - return undefined; - } - // illegal case: forward reference - if (!isDefinedBefore(propertyDecl, member)) { - return undefined; - } - return getNodeLinks(propertyDecl).enumMemberValue; - } - } - } - } - function checkEnumDeclaration(node) { - if (!produceDiagnostics) { - return; - } - // Grammar checking - checkGrammarDeclarationNameInStrictMode(node) || checkGrammarDecorators(node) || checkGrammarModifiers(node) || checkGrammarEnumDeclaration(node); - checkTypeNameIsReserved(node.name, ts.Diagnostics.Enum_name_cannot_be_0); - checkCollisionWithCapturedThisVariable(node, node.name); - checkCollisionWithRequireExportsInGeneratedCode(node, node.name); - checkExportsOnMergedDeclarations(node); - computeEnumMemberValues(node); - var enumIsConst = ts.isConst(node); - if (compilerOptions.isolatedModules && enumIsConst && ts.isInAmbientContext(node)) { - error(node.name, ts.Diagnostics.Ambient_const_enums_are_not_allowed_when_the_isolatedModules_flag_is_provided); - } - // Spec 2014 - Section 9.3: - // It isn't possible for one enum declaration to continue the automatic numbering sequence of another, - // and when an enum type has multiple declarations, only one declaration is permitted to omit a value - // for the first member. - // - // Only perform this check once per symbol - var enumSymbol = getSymbolOfNode(node); - var firstDeclaration = ts.getDeclarationOfKind(enumSymbol, node.kind); - if (node === firstDeclaration) { - if (enumSymbol.declarations.length > 1) { - // check that const is placed\omitted on all enum declarations - ts.forEach(enumSymbol.declarations, function (decl) { - if (ts.isConstEnumDeclaration(decl) !== enumIsConst) { - error(decl.name, ts.Diagnostics.Enum_declarations_must_all_be_const_or_non_const); - } - }); - } - var seenEnumMissingInitialInitializer = false; - ts.forEach(enumSymbol.declarations, function (declaration) { - // return true if we hit a violation of the rule, false otherwise - if (declaration.kind !== 207 /* EnumDeclaration */) { - return false; - } - var enumDeclaration = declaration; - if (!enumDeclaration.members.length) { - return false; - } - var firstEnumMember = enumDeclaration.members[0]; - if (!firstEnumMember.initializer) { - if (seenEnumMissingInitialInitializer) { - error(firstEnumMember.name, ts.Diagnostics.In_an_enum_with_multiple_declarations_only_one_declaration_can_omit_an_initializer_for_its_first_enum_element); - } - else { - seenEnumMissingInitialInitializer = true; - } - } - }); - } - } - function getFirstNonAmbientClassOrFunctionDeclaration(symbol) { - var declarations = symbol.declarations; - for (var _i = 0; _i < declarations.length; _i++) { - var declaration = declarations[_i]; - if ((declaration.kind === 204 /* ClassDeclaration */ || - (declaration.kind === 203 /* FunctionDeclaration */ && ts.nodeIsPresent(declaration.body))) && - !ts.isInAmbientContext(declaration)) { - return declaration; - } - } - return undefined; - } - function inSameLexicalScope(node1, node2) { - var container1 = ts.getEnclosingBlockScopeContainer(node1); - var container2 = ts.getEnclosingBlockScopeContainer(node2); - if (isGlobalSourceFile(container1)) { - return isGlobalSourceFile(container2); - } - else if (isGlobalSourceFile(container2)) { - return false; - } - else { - return container1 === container2; - } - } - function checkModuleDeclaration(node) { - if (produceDiagnostics) { - // Grammar checking - var isAmbientExternalModule = node.name.kind === 8 /* StringLiteral */; - var contextErrorMessage = isAmbientExternalModule - ? ts.Diagnostics.An_ambient_module_declaration_is_only_allowed_at_the_top_level_in_a_file - : ts.Diagnostics.A_namespace_declaration_is_only_allowed_in_a_namespace_or_module; - if (checkGrammarModuleElementContext(node, contextErrorMessage)) { - // If we hit a module declaration in an illegal context, just bail out to avoid cascading errors. - return; - } - if (!checkGrammarDeclarationNameInStrictMode(node) && !checkGrammarDecorators(node) && !checkGrammarModifiers(node)) { - if (!ts.isInAmbientContext(node) && node.name.kind === 8 /* StringLiteral */) { - grammarErrorOnNode(node.name, ts.Diagnostics.Only_ambient_modules_can_use_quoted_names); - } - } - checkCollisionWithCapturedThisVariable(node, node.name); - checkCollisionWithRequireExportsInGeneratedCode(node, node.name); - checkExportsOnMergedDeclarations(node); - var symbol = getSymbolOfNode(node); - // The following checks only apply on a non-ambient instantiated module declaration. - if (symbol.flags & 512 /* ValueModule */ - && symbol.declarations.length > 1 - && !ts.isInAmbientContext(node) - && ts.isInstantiatedModule(node, compilerOptions.preserveConstEnums || compilerOptions.isolatedModules)) { - var firstNonAmbientClassOrFunc = getFirstNonAmbientClassOrFunctionDeclaration(symbol); - if (firstNonAmbientClassOrFunc) { - if (ts.getSourceFileOfNode(node) !== ts.getSourceFileOfNode(firstNonAmbientClassOrFunc)) { - error(node.name, ts.Diagnostics.A_namespace_declaration_cannot_be_in_a_different_file_from_a_class_or_function_with_which_it_is_merged); - } - else if (node.pos < firstNonAmbientClassOrFunc.pos) { - error(node.name, ts.Diagnostics.A_namespace_declaration_cannot_be_located_prior_to_a_class_or_function_with_which_it_is_merged); - } - } - // if the module merges with a class declaration in the same lexical scope, - // we need to track this to ensure the correct emit. - var mergedClass = ts.getDeclarationOfKind(symbol, 204 /* ClassDeclaration */); - if (mergedClass && - inSameLexicalScope(node, mergedClass)) { - getNodeLinks(node).flags |= 2048 /* LexicalModuleMergesWithClass */; - } - } - // Checks for ambient external modules. - if (isAmbientExternalModule) { - if (!isGlobalSourceFile(node.parent)) { - error(node.name, ts.Diagnostics.Ambient_modules_cannot_be_nested_in_other_modules); - } - if (isExternalModuleNameRelative(node.name.text)) { - error(node.name, ts.Diagnostics.Ambient_module_declaration_cannot_specify_relative_module_name); - } - } - } - checkSourceElement(node.body); - } - function getFirstIdentifier(node) { - while (true) { - if (node.kind === 128 /* QualifiedName */) { - node = node.left; - } - else if (node.kind === 158 /* PropertyAccessExpression */) { - node = node.expression; - } - else { - break; - } - } - ts.Debug.assert(node.kind === 65 /* Identifier */); - return node; - } - function checkExternalImportOrExportDeclaration(node) { - var moduleName = ts.getExternalModuleName(node); - if (!ts.nodeIsMissing(moduleName) && moduleName.kind !== 8 /* StringLiteral */) { - error(moduleName, ts.Diagnostics.String_literal_expected); - return false; - } - var inAmbientExternalModule = node.parent.kind === 209 /* ModuleBlock */ && node.parent.parent.name.kind === 8 /* StringLiteral */; - if (node.parent.kind !== 230 /* SourceFile */ && !inAmbientExternalModule) { - error(moduleName, node.kind === 218 /* ExportDeclaration */ ? - ts.Diagnostics.Export_declarations_are_not_permitted_in_a_namespace : - ts.Diagnostics.Import_declarations_in_a_namespace_cannot_reference_a_module); - return false; - } - if (inAmbientExternalModule && isExternalModuleNameRelative(moduleName.text)) { - // TypeScript 1.0 spec (April 2013): 12.1.6 - // An ExternalImportDeclaration in an AmbientExternalModuleDeclaration may reference - // other external modules only through top - level external module names. - // Relative external module names are not permitted. - error(node, ts.Diagnostics.Import_or_export_declaration_in_an_ambient_module_declaration_cannot_reference_module_through_relative_module_name); - return false; - } - return true; - } - function checkAliasSymbol(node) { - var symbol = getSymbolOfNode(node); - var target = resolveAlias(symbol); - if (target !== unknownSymbol) { - var excludedMeanings = (symbol.flags & 107455 /* Value */ ? 107455 /* Value */ : 0) | - (symbol.flags & 793056 /* Type */ ? 793056 /* Type */ : 0) | - (symbol.flags & 1536 /* Namespace */ ? 1536 /* Namespace */ : 0); - if (target.flags & excludedMeanings) { - var message = node.kind === 220 /* ExportSpecifier */ ? - ts.Diagnostics.Export_declaration_conflicts_with_exported_declaration_of_0 : - ts.Diagnostics.Import_declaration_conflicts_with_local_declaration_of_0; - error(node, message, symbolToString(symbol)); - } - } - } - function checkImportBinding(node) { - checkCollisionWithCapturedThisVariable(node, node.name); - checkCollisionWithRequireExportsInGeneratedCode(node, node.name); - checkAliasSymbol(node); - } - function checkImportDeclaration(node) { - if (checkGrammarModuleElementContext(node, ts.Diagnostics.An_import_declaration_can_only_be_used_in_a_namespace_or_module)) { - // If we hit an import declaration in an illegal context, just bail out to avoid cascading errors. - return; - } - if (!checkGrammarImportDeclarationNameInStrictMode(node) && !checkGrammarDecorators(node) && !checkGrammarModifiers(node) && (node.flags & 499 /* Modifier */)) { - grammarErrorOnFirstToken(node, ts.Diagnostics.An_import_declaration_cannot_have_modifiers); - } - if (checkExternalImportOrExportDeclaration(node)) { - var importClause = node.importClause; - if (importClause) { - if (importClause.name) { - checkImportBinding(importClause); - } - if (importClause.namedBindings) { - if (importClause.namedBindings.kind === 214 /* NamespaceImport */) { - checkImportBinding(importClause.namedBindings); - } - else { - ts.forEach(importClause.namedBindings.elements, checkImportBinding); - } - } - } - } - } - function checkImportEqualsDeclaration(node) { - if (checkGrammarModuleElementContext(node, ts.Diagnostics.An_import_declaration_can_only_be_used_in_a_namespace_or_module)) { - // If we hit an import declaration in an illegal context, just bail out to avoid cascading errors. - return; - } - checkGrammarDeclarationNameInStrictMode(node) || checkGrammarDecorators(node) || checkGrammarModifiers(node); - if (ts.isInternalModuleImportEqualsDeclaration(node) || checkExternalImportOrExportDeclaration(node)) { - checkImportBinding(node); - if (node.flags & 1 /* Export */) { - markExportAsReferenced(node); - } - if (ts.isInternalModuleImportEqualsDeclaration(node)) { - var target = resolveAlias(getSymbolOfNode(node)); - if (target !== unknownSymbol) { - if (target.flags & 107455 /* Value */) { - // Target is a value symbol, check that it is not hidden by a local declaration with the same name - var moduleName = getFirstIdentifier(node.moduleReference); - if (!(resolveEntityName(moduleName, 107455 /* Value */ | 1536 /* Namespace */).flags & 1536 /* Namespace */)) { - error(moduleName, ts.Diagnostics.Module_0_is_hidden_by_a_local_declaration_with_the_same_name, ts.declarationNameToString(moduleName)); - } - } - if (target.flags & 793056 /* Type */) { - checkTypeNameIsReserved(node.name, ts.Diagnostics.Import_name_cannot_be_0); - } - } - } - else { - if (languageVersion >= 2 /* ES6 */) { - // Import equals declaration is deprecated in es6 or above - grammarErrorOnNode(node, ts.Diagnostics.Import_assignment_cannot_be_used_when_targeting_ECMAScript_6_or_higher_Consider_using_import_Asterisk_as_ns_from_mod_import_a_from_mod_or_import_d_from_mod_instead); - } - } - } - } - function checkExportDeclaration(node) { - if (checkGrammarModuleElementContext(node, ts.Diagnostics.An_export_declaration_can_only_be_used_in_a_module)) { - // If we hit an export in an illegal context, just bail out to avoid cascading errors. - return; - } - if (!checkGrammarDecorators(node) && !checkGrammarModifiers(node) && (node.flags & 499 /* Modifier */)) { - grammarErrorOnFirstToken(node, ts.Diagnostics.An_export_declaration_cannot_have_modifiers); - } - if (!node.moduleSpecifier || checkExternalImportOrExportDeclaration(node)) { - if (node.exportClause) { - // export { x, y } - // export { x, y } from "foo" - ts.forEach(node.exportClause.elements, checkExportSpecifier); - var inAmbientExternalModule = node.parent.kind === 209 /* ModuleBlock */ && node.parent.parent.name.kind === 8 /* StringLiteral */; - if (node.parent.kind !== 230 /* SourceFile */ && !inAmbientExternalModule) { - error(node, ts.Diagnostics.Export_declarations_are_not_permitted_in_a_namespace); - } - } - else { - // export * from "foo" - var moduleSymbol = resolveExternalModuleName(node, node.moduleSpecifier); - if (moduleSymbol && moduleSymbol.exports["export="]) { - error(node.moduleSpecifier, ts.Diagnostics.Module_0_uses_export_and_cannot_be_used_with_export_Asterisk, symbolToString(moduleSymbol)); - } - } - } - } - function checkGrammarModuleElementContext(node, errorMessage) { - if (node.parent.kind !== 230 /* SourceFile */ && node.parent.kind !== 209 /* ModuleBlock */ && node.parent.kind !== 208 /* ModuleDeclaration */) { - return grammarErrorOnFirstToken(node, errorMessage); - } - } - function checkExportSpecifier(node) { - checkAliasSymbol(node); - if (!node.parent.parent.moduleSpecifier) { - markExportAsReferenced(node); - } - } - function checkExportAssignment(node) { - if (checkGrammarModuleElementContext(node, ts.Diagnostics.An_export_assignment_can_only_be_used_in_a_module)) { - // If we hit an export assignment in an illegal context, just bail out to avoid cascading errors. - return; - } - var container = node.parent.kind === 230 /* SourceFile */ ? node.parent : node.parent.parent; - if (container.kind === 208 /* ModuleDeclaration */ && container.name.kind === 65 /* Identifier */) { - error(node, ts.Diagnostics.An_export_assignment_cannot_be_used_in_a_namespace); - return; - } - // Grammar checking - if (!checkGrammarDecorators(node) && !checkGrammarModifiers(node) && (node.flags & 499 /* Modifier */)) { - grammarErrorOnFirstToken(node, ts.Diagnostics.An_export_assignment_cannot_have_modifiers); - } - if (node.expression.kind === 65 /* Identifier */) { - markExportAsReferenced(node); - } - else { - checkExpressionCached(node.expression); - } - checkExternalModuleExports(container); - if (node.isExportEquals && !ts.isInAmbientContext(node)) { - if (languageVersion >= 2 /* ES6 */) { - // export assignment is deprecated in es6 or above - grammarErrorOnNode(node, ts.Diagnostics.Export_assignment_cannot_be_used_when_targeting_ECMAScript_6_or_higher_Consider_using_export_default_instead); - } - else if (compilerOptions.module === 4 /* System */) { - // system modules does not support export assignment - grammarErrorOnNode(node, ts.Diagnostics.Export_assignment_is_not_supported_when_module_flag_is_system); - } - } - } - function getModuleStatements(node) { - if (node.kind === 230 /* SourceFile */) { - return node.statements; - } - if (node.kind === 208 /* ModuleDeclaration */ && node.body.kind === 209 /* ModuleBlock */) { - return node.body.statements; - } - return emptyArray; - } - function hasExportedMembers(moduleSymbol) { - for (var id in moduleSymbol.exports) { - if (id !== "export=") { - return true; - } - } - return false; - } - function checkExternalModuleExports(node) { - var moduleSymbol = getSymbolOfNode(node); - var links = getSymbolLinks(moduleSymbol); - if (!links.exportsChecked) { - var exportEqualsSymbol = moduleSymbol.exports["export="]; - if (exportEqualsSymbol && hasExportedMembers(moduleSymbol)) { - var declaration = getDeclarationOfAliasSymbol(exportEqualsSymbol) || exportEqualsSymbol.valueDeclaration; - error(declaration, ts.Diagnostics.An_export_assignment_cannot_be_used_in_a_module_with_other_exported_elements); - } - links.exportsChecked = true; - } - } - function checkTypePredicate(node) { - if (!isInLegalTypePredicatePosition(node)) { - error(node, ts.Diagnostics.A_type_predicate_is_only_allowed_in_return_type_position_for_functions_and_methods); - } - } - function checkSourceElement(node) { - if (!node) - return; - switch (node.kind) { - case 130 /* TypeParameter */: - return checkTypeParameter(node); - case 131 /* Parameter */: - return checkParameter(node); - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - return checkPropertyDeclaration(node); - case 145 /* FunctionType */: - case 146 /* ConstructorType */: - case 140 /* CallSignature */: - case 141 /* ConstructSignature */: - return checkSignatureDeclaration(node); - case 142 /* IndexSignature */: - return checkSignatureDeclaration(node); - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - return checkMethodDeclaration(node); - case 137 /* Constructor */: - return checkConstructorDeclaration(node); - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - return checkAccessorDeclaration(node); - case 144 /* TypeReference */: - return checkTypeReferenceNode(node); - case 143 /* TypePredicate */: - return checkTypePredicate(node); - case 147 /* TypeQuery */: - return checkTypeQuery(node); - case 148 /* TypeLiteral */: - return checkTypeLiteral(node); - case 149 /* ArrayType */: - return checkArrayType(node); - case 150 /* TupleType */: - return checkTupleType(node); - case 151 /* UnionType */: - return checkUnionType(node); - case 152 /* ParenthesizedType */: - return checkSourceElement(node.type); - case 203 /* FunctionDeclaration */: - return checkFunctionDeclaration(node); - case 182 /* Block */: - case 209 /* ModuleBlock */: - return checkBlock(node); - case 183 /* VariableStatement */: - return checkVariableStatement(node); - case 185 /* ExpressionStatement */: - return checkExpressionStatement(node); - case 186 /* IfStatement */: - return checkIfStatement(node); - case 187 /* DoStatement */: - return checkDoStatement(node); - case 188 /* WhileStatement */: - return checkWhileStatement(node); - case 189 /* ForStatement */: - return checkForStatement(node); - case 190 /* ForInStatement */: - return checkForInStatement(node); - case 191 /* ForOfStatement */: - return checkForOfStatement(node); - case 192 /* ContinueStatement */: - case 193 /* BreakStatement */: - return checkBreakOrContinueStatement(node); - case 194 /* ReturnStatement */: - return checkReturnStatement(node); - case 195 /* WithStatement */: - return checkWithStatement(node); - case 196 /* SwitchStatement */: - return checkSwitchStatement(node); - case 197 /* LabeledStatement */: - return checkLabeledStatement(node); - case 198 /* ThrowStatement */: - return checkThrowStatement(node); - case 199 /* TryStatement */: - return checkTryStatement(node); - case 201 /* VariableDeclaration */: - return checkVariableDeclaration(node); - case 155 /* BindingElement */: - return checkBindingElement(node); - case 204 /* ClassDeclaration */: - return checkClassDeclaration(node); - case 205 /* InterfaceDeclaration */: - return checkInterfaceDeclaration(node); - case 206 /* TypeAliasDeclaration */: - return checkTypeAliasDeclaration(node); - case 207 /* EnumDeclaration */: - return checkEnumDeclaration(node); - case 208 /* ModuleDeclaration */: - return checkModuleDeclaration(node); - case 212 /* ImportDeclaration */: - return checkImportDeclaration(node); - case 211 /* ImportEqualsDeclaration */: - return checkImportEqualsDeclaration(node); - case 218 /* ExportDeclaration */: - return checkExportDeclaration(node); - case 217 /* ExportAssignment */: - return checkExportAssignment(node); - case 184 /* EmptyStatement */: - checkGrammarStatementInAmbientContext(node); - return; - case 200 /* DebuggerStatement */: - checkGrammarStatementInAmbientContext(node); - return; - case 221 /* MissingDeclaration */: - return checkMissingDeclaration(node); - } - } - // Function expression bodies are checked after all statements in the enclosing body. This is to ensure - // constructs like the following are permitted: - // let foo = function () { - // let s = foo(); - // return "hello"; - // } - // Here, performing a full type check of the body of the function expression whilst in the process of - // determining the type of foo would cause foo to be given type any because of the recursive reference. - // Delaying the type check of the body ensures foo has been assigned a type. - function checkFunctionExpressionBodies(node) { - switch (node.kind) { - case 165 /* FunctionExpression */: - case 166 /* ArrowFunction */: - ts.forEach(node.parameters, checkFunctionExpressionBodies); - checkFunctionExpressionOrObjectLiteralMethodBody(node); - break; - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - ts.forEach(node.decorators, checkFunctionExpressionBodies); - ts.forEach(node.parameters, checkFunctionExpressionBodies); - if (ts.isObjectLiteralMethod(node)) { - checkFunctionExpressionOrObjectLiteralMethodBody(node); - } - break; - case 137 /* Constructor */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 203 /* FunctionDeclaration */: - ts.forEach(node.parameters, checkFunctionExpressionBodies); - break; - case 195 /* WithStatement */: - checkFunctionExpressionBodies(node.expression); - break; - case 132 /* Decorator */: - case 131 /* Parameter */: - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - case 153 /* ObjectBindingPattern */: - case 154 /* ArrayBindingPattern */: - case 155 /* BindingElement */: - case 156 /* ArrayLiteralExpression */: - case 157 /* ObjectLiteralExpression */: - case 227 /* PropertyAssignment */: - case 158 /* PropertyAccessExpression */: - case 159 /* ElementAccessExpression */: - case 160 /* CallExpression */: - case 161 /* NewExpression */: - case 162 /* TaggedTemplateExpression */: - case 174 /* TemplateExpression */: - case 180 /* TemplateSpan */: - case 163 /* TypeAssertionExpression */: - case 164 /* ParenthesizedExpression */: - case 168 /* TypeOfExpression */: - case 169 /* VoidExpression */: - case 167 /* DeleteExpression */: - case 170 /* PrefixUnaryExpression */: - case 171 /* PostfixUnaryExpression */: - case 172 /* BinaryExpression */: - case 173 /* ConditionalExpression */: - case 176 /* SpreadElementExpression */: - case 182 /* Block */: - case 209 /* ModuleBlock */: - case 183 /* VariableStatement */: - case 185 /* ExpressionStatement */: - case 186 /* IfStatement */: - case 187 /* DoStatement */: - case 188 /* WhileStatement */: - case 189 /* ForStatement */: - case 190 /* ForInStatement */: - case 191 /* ForOfStatement */: - case 192 /* ContinueStatement */: - case 193 /* BreakStatement */: - case 194 /* ReturnStatement */: - case 196 /* SwitchStatement */: - case 210 /* CaseBlock */: - case 223 /* CaseClause */: - case 224 /* DefaultClause */: - case 197 /* LabeledStatement */: - case 198 /* ThrowStatement */: - case 199 /* TryStatement */: - case 226 /* CatchClause */: - case 201 /* VariableDeclaration */: - case 202 /* VariableDeclarationList */: - case 204 /* ClassDeclaration */: - case 207 /* EnumDeclaration */: - case 229 /* EnumMember */: - case 217 /* ExportAssignment */: - case 230 /* SourceFile */: - ts.forEachChild(node, checkFunctionExpressionBodies); - break; - } - } - function checkSourceFile(node) { - var start = new Date().getTime(); - checkSourceFileWorker(node); - ts.checkTime += new Date().getTime() - start; - } - // Fully type check a source file and collect the relevant diagnostics. - function checkSourceFileWorker(node) { - var links = getNodeLinks(node); - if (!(links.flags & 1 /* TypeChecked */)) { - // Check whether the file has declared it is the default lib, - // and whether the user has specifically chosen to avoid checking it. - if (node.isDefaultLib && compilerOptions.skipDefaultLibCheck) { - return; - } - // Grammar checking - checkGrammarSourceFile(node); - emitExtends = false; - emitDecorate = false; - emitParam = false; - potentialThisCollisions.length = 0; - ts.forEach(node.statements, checkSourceElement); - checkFunctionExpressionBodies(node); - if (ts.isExternalModule(node)) { - checkExternalModuleExports(node); - } - if (potentialThisCollisions.length) { - ts.forEach(potentialThisCollisions, checkIfThisIsCapturedInEnclosingScope); - potentialThisCollisions.length = 0; - } - if (emitExtends) { - links.flags |= 8 /* EmitExtends */; - } - if (emitDecorate) { - links.flags |= 512 /* EmitDecorate */; - } - if (emitParam) { - links.flags |= 1024 /* EmitParam */; - } - links.flags |= 1 /* TypeChecked */; - } - } - function getDiagnostics(sourceFile) { - throwIfNonDiagnosticsProducing(); - if (sourceFile) { - checkSourceFile(sourceFile); - return diagnostics.getDiagnostics(sourceFile.fileName); - } - ts.forEach(host.getSourceFiles(), checkSourceFile); - return diagnostics.getDiagnostics(); - } - function getGlobalDiagnostics() { - throwIfNonDiagnosticsProducing(); - return diagnostics.getGlobalDiagnostics(); - } - function throwIfNonDiagnosticsProducing() { - if (!produceDiagnostics) { - throw new Error("Trying to get diagnostics from a type checker that does not produce them."); - } - } - // Language service support - function isInsideWithStatementBody(node) { - if (node) { - while (node.parent) { - if (node.parent.kind === 195 /* WithStatement */ && node.parent.statement === node) { - return true; - } - node = node.parent; - } - } - return false; - } - function getSymbolsInScope(location, meaning) { - var symbols = {}; - var memberFlags = 0; - if (isInsideWithStatementBody(location)) { - // We cannot answer semantic questions within a with block, do not proceed any further - return []; - } - populateSymbols(); - return symbolsToArray(symbols); - function populateSymbols() { - while (location) { - if (location.locals && !isGlobalSourceFile(location)) { - copySymbols(location.locals, meaning); - } - switch (location.kind) { - case 230 /* SourceFile */: - if (!ts.isExternalModule(location)) { - break; - } - case 208 /* ModuleDeclaration */: - copySymbols(getSymbolOfNode(location).exports, meaning & 8914931 /* ModuleMember */); - break; - case 207 /* EnumDeclaration */: - copySymbols(getSymbolOfNode(location).exports, meaning & 8 /* EnumMember */); - break; - case 204 /* ClassDeclaration */: - case 205 /* InterfaceDeclaration */: - if (!(memberFlags & 128 /* Static */)) { - copySymbols(getSymbolOfNode(location).members, meaning & 793056 /* Type */); - } - break; - case 165 /* FunctionExpression */: - if (location.name) { - copySymbol(location.symbol, meaning); - } - break; - } - memberFlags = location.flags; - location = location.parent; - } - copySymbols(globals, meaning); - } - // Returns 'true' if we should stop processing symbols. - function copySymbol(symbol, meaning) { - if (symbol.flags & meaning) { - var id = symbol.name; - if (!isReservedMemberName(id) && !ts.hasProperty(symbols, id)) { - symbols[id] = symbol; - } - } - } - function copySymbols(source, meaning) { - if (meaning) { - for (var id in source) { - if (ts.hasProperty(source, id)) { - copySymbol(source[id], meaning); - } - } - } - } - if (isInsideWithStatementBody(location)) { - // We cannot answer semantic questions within a with block, do not proceed any further - return []; - } - while (location) { - if (location.locals && !isGlobalSourceFile(location)) { - copySymbols(location.locals, meaning); - } - switch (location.kind) { - case 230 /* SourceFile */: - if (!ts.isExternalModule(location)) - break; - case 208 /* ModuleDeclaration */: - copySymbols(getSymbolOfNode(location).exports, meaning & 8914931 /* ModuleMember */); - break; - case 207 /* EnumDeclaration */: - copySymbols(getSymbolOfNode(location).exports, meaning & 8 /* EnumMember */); - break; - case 204 /* ClassDeclaration */: - case 205 /* InterfaceDeclaration */: - if (!(memberFlags & 128 /* Static */)) { - copySymbols(getSymbolOfNode(location).members, meaning & 793056 /* Type */); - } - break; - case 165 /* FunctionExpression */: - if (location.name) { - copySymbol(location.symbol, meaning); - } - break; - } - memberFlags = location.flags; - location = location.parent; - } - copySymbols(globals, meaning); - return symbolsToArray(symbols); - } - function isTypeDeclarationName(name) { - return name.kind == 65 /* Identifier */ && - isTypeDeclaration(name.parent) && - name.parent.name === name; - } - function isTypeDeclaration(node) { - switch (node.kind) { - case 130 /* TypeParameter */: - case 204 /* ClassDeclaration */: - case 205 /* InterfaceDeclaration */: - case 206 /* TypeAliasDeclaration */: - case 207 /* EnumDeclaration */: - return true; - } - } - // True if the given identifier is part of a type reference - function isTypeReferenceIdentifier(entityName) { - var node = entityName; - while (node.parent && node.parent.kind === 128 /* QualifiedName */) { - node = node.parent; - } - return node.parent && node.parent.kind === 144 /* TypeReference */; - } - function isHeritageClauseElementIdentifier(entityName) { - var node = entityName; - while (node.parent && node.parent.kind === 158 /* PropertyAccessExpression */) { - node = node.parent; - } - return node.parent && node.parent.kind === 179 /* ExpressionWithTypeArguments */; - } - function getLeftSideOfImportEqualsOrExportAssignment(nodeOnRightSide) { - while (nodeOnRightSide.parent.kind === 128 /* QualifiedName */) { - nodeOnRightSide = nodeOnRightSide.parent; - } - if (nodeOnRightSide.parent.kind === 211 /* ImportEqualsDeclaration */) { - return nodeOnRightSide.parent.moduleReference === nodeOnRightSide && nodeOnRightSide.parent; - } - if (nodeOnRightSide.parent.kind === 217 /* ExportAssignment */) { - return nodeOnRightSide.parent.expression === nodeOnRightSide && nodeOnRightSide.parent; - } - return undefined; - } - function isInRightSideOfImportOrExportAssignment(node) { - return getLeftSideOfImportEqualsOrExportAssignment(node) !== undefined; - } - function getSymbolOfEntityNameOrPropertyAccessExpression(entityName) { - if (ts.isDeclarationName(entityName)) { - return getSymbolOfNode(entityName.parent); - } - if (entityName.parent.kind === 217 /* ExportAssignment */) { - return resolveEntityName(entityName, - /*all meanings*/ 107455 /* Value */ | 793056 /* Type */ | 1536 /* Namespace */ | 8388608 /* Alias */); - } - if (entityName.kind !== 158 /* PropertyAccessExpression */) { - if (isInRightSideOfImportOrExportAssignment(entityName)) { - // Since we already checked for ExportAssignment, this really could only be an Import - return getSymbolOfPartOfRightHandSideOfImportEquals(entityName); - } - } - if (ts.isRightSideOfQualifiedNameOrPropertyAccess(entityName)) { - entityName = entityName.parent; - } - if (isHeritageClauseElementIdentifier(entityName)) { - var meaning = entityName.parent.kind === 179 /* ExpressionWithTypeArguments */ ? 793056 /* Type */ : 1536 /* Namespace */; - meaning |= 8388608 /* Alias */; - return resolveEntityName(entityName, meaning); - } - else if (ts.isExpression(entityName)) { - if (ts.nodeIsMissing(entityName)) { - // Missing entity name. - return undefined; - } - if (entityName.kind === 65 /* Identifier */) { - // Include aliases in the meaning, this ensures that we do not follow aliases to where they point and instead - // return the alias symbol. - var meaning = 107455 /* Value */ | 8388608 /* Alias */; - return resolveEntityName(entityName, meaning); - } - else if (entityName.kind === 158 /* PropertyAccessExpression */) { - var symbol = getNodeLinks(entityName).resolvedSymbol; - if (!symbol) { - checkPropertyAccessExpression(entityName); - } - return getNodeLinks(entityName).resolvedSymbol; - } - else if (entityName.kind === 128 /* QualifiedName */) { - var symbol = getNodeLinks(entityName).resolvedSymbol; - if (!symbol) { - checkQualifiedName(entityName); - } - return getNodeLinks(entityName).resolvedSymbol; - } - } - else if (isTypeReferenceIdentifier(entityName)) { - var meaning = entityName.parent.kind === 144 /* TypeReference */ ? 793056 /* Type */ : 1536 /* Namespace */; - // Include aliases in the meaning, this ensures that we do not follow aliases to where they point and instead - // return the alias symbol. - meaning |= 8388608 /* Alias */; - return resolveEntityName(entityName, meaning); - } - // Do we want to return undefined here? - return undefined; - } - function getSymbolInfo(node) { - if (isInsideWithStatementBody(node)) { - // We cannot answer semantic questions within a with block, do not proceed any further - return undefined; - } - if (ts.isDeclarationName(node)) { - // This is a declaration, call getSymbolOfNode - return getSymbolOfNode(node.parent); - } - if (node.kind === 65 /* Identifier */ && isInRightSideOfImportOrExportAssignment(node)) { - return node.parent.kind === 217 /* ExportAssignment */ - ? getSymbolOfEntityNameOrPropertyAccessExpression(node) - : getSymbolOfPartOfRightHandSideOfImportEquals(node); - } - switch (node.kind) { - case 65 /* Identifier */: - case 158 /* PropertyAccessExpression */: - case 128 /* QualifiedName */: - return getSymbolOfEntityNameOrPropertyAccessExpression(node); - case 93 /* ThisKeyword */: - case 91 /* SuperKeyword */: - var type = checkExpression(node); - return type.symbol; - case 114 /* ConstructorKeyword */: - // constructor keyword for an overload, should take us to the definition if it exist - var constructorDeclaration = node.parent; - if (constructorDeclaration && constructorDeclaration.kind === 137 /* Constructor */) { - return constructorDeclaration.parent.symbol; - } - return undefined; - case 8 /* StringLiteral */: - // External module name in an import declaration - var moduleName; - if ((ts.isExternalModuleImportEqualsDeclaration(node.parent.parent) && - ts.getExternalModuleImportEqualsDeclarationExpression(node.parent.parent) === node) || - ((node.parent.kind === 212 /* ImportDeclaration */ || node.parent.kind === 218 /* ExportDeclaration */) && - node.parent.moduleSpecifier === node)) { - return resolveExternalModuleName(node, node); - } - // Intentional fall-through - case 7 /* NumericLiteral */: - // index access - if (node.parent.kind == 159 /* ElementAccessExpression */ && node.parent.argumentExpression === node) { - var objectType = checkExpression(node.parent.expression); - if (objectType === unknownType) - return undefined; - var apparentType = getApparentType(objectType); - if (apparentType === unknownType) - return undefined; - return getPropertyOfType(apparentType, node.text); - } - break; - } - return undefined; - } - function getShorthandAssignmentValueSymbol(location) { - // The function returns a value symbol of an identifier in the short-hand property assignment. - // This is necessary as an identifier in short-hand property assignment can contains two meaning: - // property name and property value. - if (location && location.kind === 228 /* ShorthandPropertyAssignment */) { - return resolveEntityName(location.name, 107455 /* Value */); - } - return undefined; - } - function getTypeOfNode(node) { - if (isInsideWithStatementBody(node)) { - // We cannot answer semantic questions within a with block, do not proceed any further - return unknownType; - } - if (ts.isTypeNode(node)) { - return getTypeFromTypeNode(node); - } - if (ts.isExpression(node)) { - return getTypeOfExpression(node); - } - if (isTypeDeclaration(node)) { - // In this case, we call getSymbolOfNode instead of getSymbolInfo because it is a declaration - var symbol = getSymbolOfNode(node); - return getDeclaredTypeOfSymbol(symbol); - } - if (isTypeDeclarationName(node)) { - var symbol = getSymbolInfo(node); - return symbol && getDeclaredTypeOfSymbol(symbol); - } - if (ts.isDeclaration(node)) { - // In this case, we call getSymbolOfNode instead of getSymbolInfo because it is a declaration - var symbol = getSymbolOfNode(node); - return getTypeOfSymbol(symbol); - } - if (ts.isDeclarationName(node)) { - var symbol = getSymbolInfo(node); - return symbol && getTypeOfSymbol(symbol); - } - if (isInRightSideOfImportOrExportAssignment(node)) { - var symbol = getSymbolInfo(node); - var declaredType = symbol && getDeclaredTypeOfSymbol(symbol); - return declaredType !== unknownType ? declaredType : getTypeOfSymbol(symbol); - } - return unknownType; - } - function getTypeOfExpression(expr) { - if (ts.isRightSideOfQualifiedNameOrPropertyAccess(expr)) { - expr = expr.parent; - } - return checkExpression(expr); - } - // Return the list of properties of the given type, augmented with properties from Function - // if the type has call or construct signatures - function getAugmentedPropertiesOfType(type) { - type = getApparentType(type); - var propsByName = createSymbolTable(getPropertiesOfType(type)); - if (getSignaturesOfType(type, 0 /* Call */).length || getSignaturesOfType(type, 1 /* Construct */).length) { - ts.forEach(getPropertiesOfType(globalFunctionType), function (p) { - if (!ts.hasProperty(propsByName, p.name)) { - propsByName[p.name] = p; - } - }); - } - return getNamedMembers(propsByName); - } - function getRootSymbols(symbol) { - if (symbol.flags & 268435456 /* UnionProperty */) { - var symbols = []; - var name_14 = symbol.name; - ts.forEach(getSymbolLinks(symbol).unionType.types, function (t) { - symbols.push(getPropertyOfType(t, name_14)); - }); - return symbols; - } - else if (symbol.flags & 67108864 /* Transient */) { - var target = getSymbolLinks(symbol).target; - if (target) { - return [target]; - } - } - return [symbol]; - } - // Emitter support - // When resolved as an expression identifier, if the given node references an exported entity, return the declaration - // node of the exported entity's container. Otherwise, return undefined. - function getReferencedExportContainer(node) { - var symbol = getReferencedValueSymbol(node); - if (symbol) { - if (symbol.flags & 1048576 /* ExportValue */) { - // If we reference an exported entity within the same module declaration, then whether - // we prefix depends on the kind of entity. SymbolFlags.ExportHasLocal encompasses all the - // kinds that we do NOT prefix. - var exportSymbol = getMergedSymbol(symbol.exportSymbol); - if (exportSymbol.flags & 944 /* ExportHasLocal */) { - return undefined; - } - symbol = exportSymbol; - } - var parentSymbol = getParentOfSymbol(symbol); - if (parentSymbol) { - if (parentSymbol.flags & 512 /* ValueModule */ && parentSymbol.valueDeclaration.kind === 230 /* SourceFile */) { - return parentSymbol.valueDeclaration; - } - for (var n = node.parent; n; n = n.parent) { - if ((n.kind === 208 /* ModuleDeclaration */ || n.kind === 207 /* EnumDeclaration */) && getSymbolOfNode(n) === parentSymbol) { - return n; - } - } - } - } - } - // When resolved as an expression identifier, if the given node references an import, return the declaration of - // that import. Otherwise, return undefined. - function getReferencedImportDeclaration(node) { - var symbol = getReferencedValueSymbol(node); - return symbol && symbol.flags & 8388608 /* Alias */ ? getDeclarationOfAliasSymbol(symbol) : undefined; - } - function isStatementWithLocals(node) { - switch (node.kind) { - case 182 /* Block */: - case 210 /* CaseBlock */: - case 189 /* ForStatement */: - case 190 /* ForInStatement */: - case 191 /* ForOfStatement */: - return true; - } - return false; - } - function isNestedRedeclarationSymbol(symbol) { - if (symbol.flags & 418 /* BlockScoped */) { - var links = getSymbolLinks(symbol); - if (links.isNestedRedeclaration === undefined) { - var container = ts.getEnclosingBlockScopeContainer(symbol.valueDeclaration); - links.isNestedRedeclaration = isStatementWithLocals(container) && - !!resolveName(container.parent, symbol.name, 107455 /* Value */, undefined, undefined); - } - return links.isNestedRedeclaration; - } - return false; - } - // When resolved as an expression identifier, if the given node references a nested block scoped entity with - // a name that hides an existing name, return the declaration of that entity. Otherwise, return undefined. - function getReferencedNestedRedeclaration(node) { - var symbol = getReferencedValueSymbol(node); - return symbol && isNestedRedeclarationSymbol(symbol) ? symbol.valueDeclaration : undefined; - } - // Return true if the given node is a declaration of a nested block scoped entity with a name that hides an - // existing name. - function isNestedRedeclaration(node) { - return isNestedRedeclarationSymbol(getSymbolOfNode(node)); - } - function isValueAliasDeclaration(node) { - switch (node.kind) { - case 211 /* ImportEqualsDeclaration */: - case 213 /* ImportClause */: - case 214 /* NamespaceImport */: - case 216 /* ImportSpecifier */: - case 220 /* ExportSpecifier */: - return isAliasResolvedToValue(getSymbolOfNode(node)); - case 218 /* ExportDeclaration */: - var exportClause = node.exportClause; - return exportClause && ts.forEach(exportClause.elements, isValueAliasDeclaration); - case 217 /* ExportAssignment */: - return node.expression && node.expression.kind === 65 /* Identifier */ ? isAliasResolvedToValue(getSymbolOfNode(node)) : true; - } - return false; - } - function isTopLevelValueImportEqualsWithEntityName(node) { - if (node.parent.kind !== 230 /* SourceFile */ || !ts.isInternalModuleImportEqualsDeclaration(node)) { - // parent is not source file or it is not reference to internal module - return false; - } - var isValue = isAliasResolvedToValue(getSymbolOfNode(node)); - return isValue && node.moduleReference && !ts.nodeIsMissing(node.moduleReference); - } - function isAliasResolvedToValue(symbol) { - var target = resolveAlias(symbol); - if (target === unknownSymbol && compilerOptions.isolatedModules) { - return true; - } - // const enums and modules that contain only const enums are not considered values from the emit perespective - return target !== unknownSymbol && target && target.flags & 107455 /* Value */ && !isConstEnumOrConstEnumOnlyModule(target); - } - function isConstEnumOrConstEnumOnlyModule(s) { - return isConstEnumSymbol(s) || s.constEnumOnlyModule; - } - function isReferencedAliasDeclaration(node, checkChildren) { - if (ts.isAliasSymbolDeclaration(node)) { - var symbol = getSymbolOfNode(node); - if (getSymbolLinks(symbol).referenced) { - return true; - } - } - if (checkChildren) { - return ts.forEachChild(node, function (node) { return isReferencedAliasDeclaration(node, checkChildren); }); - } - return false; - } - function isImplementationOfOverload(node) { - if (ts.nodeIsPresent(node.body)) { - var symbol = getSymbolOfNode(node); - var signaturesOfSymbol = getSignaturesOfSymbol(symbol); - // If this function body corresponds to function with multiple signature, it is implementation of overload - // e.g.: function foo(a: string): string; - // function foo(a: number): number; - // function foo(a: any) { // This is implementation of the overloads - // return a; - // } - return signaturesOfSymbol.length > 1 || - // If there is single signature for the symbol, it is overload if that signature isn't coming from the node - // e.g.: function foo(a: string): string; - // function foo(a: any) { // This is implementation of the overloads - // return a; - // } - (signaturesOfSymbol.length === 1 && signaturesOfSymbol[0].declaration !== node); - } - return false; - } - function getNodeCheckFlags(node) { - return getNodeLinks(node).flags; - } - function getEnumMemberValue(node) { - computeEnumMemberValues(node.parent); - return getNodeLinks(node).enumMemberValue; - } - function getConstantValue(node) { - if (node.kind === 229 /* EnumMember */) { - return getEnumMemberValue(node); - } - var symbol = getNodeLinks(node).resolvedSymbol; - if (symbol && (symbol.flags & 8 /* EnumMember */)) { - // inline property\index accesses only for const enums - if (ts.isConstEnumDeclaration(symbol.valueDeclaration.parent)) { - return getEnumMemberValue(symbol.valueDeclaration); - } - } - return undefined; - } - /** Serializes an EntityName (with substitutions) to an appropriate JS constructor value. Used by the __metadata decorator. */ - function serializeEntityName(node, fallbackPath) { - if (node.kind === 65 /* Identifier */) { - // TODO(ron.buckton): The getExpressionNameSubstitution function has been removed, but calling it - // here has no effect anyway as an identifier in a type name is not an expression. - // var substitution = getExpressionNameSubstitution(node, getGeneratedNameForNode); - // var text = substitution || (node).text; - var text = node.text; - if (fallbackPath) { - fallbackPath.push(text); - } - else { - return text; - } - } - else { - var left = serializeEntityName(node.left, fallbackPath); - var right = serializeEntityName(node.right, fallbackPath); - if (!fallbackPath) { - return left + "." + right; - } - } - } - /** Serializes a TypeReferenceNode to an appropriate JS constructor value. Used by the __metadata decorator. */ - function serializeTypeReferenceNode(node) { - // serialization of a TypeReferenceNode uses the following rules: - // - // * The serialized type of a TypeReference that is `void` is "void 0". - // * The serialized type of a TypeReference that is a `boolean` is "Boolean". - // * The serialized type of a TypeReference that is an enum or `number` is "Number". - // * The serialized type of a TypeReference that is a string literal or `string` is "String". - // * The serialized type of a TypeReference that is a tuple is "Array". - // * The serialized type of a TypeReference that is a `symbol` is "Symbol". - // * The serialized type of a TypeReference with a value declaration is its entity name. - // * The serialized type of a TypeReference with a call or construct signature is "Function". - // * The serialized type of any other type is "Object". - var type = getTypeFromTypeNode(node); - if (type.flags & 16 /* Void */) { - return "void 0"; - } - else if (type.flags & 8 /* Boolean */) { - return "Boolean"; - } - else if (type.flags & 132 /* NumberLike */) { - return "Number"; - } - else if (type.flags & 258 /* StringLike */) { - return "String"; - } - else if (type.flags & 8192 /* Tuple */) { - return "Array"; - } - else if (type.flags & 2097152 /* ESSymbol */) { - return "Symbol"; - } - else if (type === unknownType) { - var fallbackPath = []; - serializeEntityName(node.typeName, fallbackPath); - return fallbackPath; - } - else if (type.symbol && type.symbol.valueDeclaration) { - return serializeEntityName(node.typeName); - } - else if (typeHasCallOrConstructSignatures(type)) { - return "Function"; - } - return "Object"; - } - /** Serializes a TypeNode to an appropriate JS constructor value. Used by the __metadata decorator. */ - function serializeTypeNode(node) { - // serialization of a TypeNode uses the following rules: - // - // * The serialized type of `void` is "void 0" (undefined). - // * The serialized type of a parenthesized type is the serialized type of its nested type. - // * The serialized type of a Function or Constructor type is "Function". - // * The serialized type of an Array or Tuple type is "Array". - // * The serialized type of `boolean` is "Boolean". - // * The serialized type of `string` or a string-literal type is "String". - // * The serialized type of a type reference is handled by `serializeTypeReferenceNode`. - // * The serialized type of any other type node is "Object". - if (node) { - switch (node.kind) { - case 99 /* VoidKeyword */: - return "void 0"; - case 152 /* ParenthesizedType */: - return serializeTypeNode(node.type); - case 145 /* FunctionType */: - case 146 /* ConstructorType */: - return "Function"; - case 149 /* ArrayType */: - case 150 /* TupleType */: - return "Array"; - case 113 /* BooleanKeyword */: - return "Boolean"; - case 123 /* StringKeyword */: - case 8 /* StringLiteral */: - return "String"; - case 121 /* NumberKeyword */: - return "Number"; - case 144 /* TypeReference */: - return serializeTypeReferenceNode(node); - case 147 /* TypeQuery */: - case 148 /* TypeLiteral */: - case 151 /* UnionType */: - case 112 /* AnyKeyword */: - break; - default: - ts.Debug.fail("Cannot serialize unexpected type node."); - break; - } - } - return "Object"; - } - /** Serializes the type of a declaration to an appropriate JS constructor value. Used by the __metadata decorator for a class member. */ - function serializeTypeOfNode(node) { - // serialization of the type of a declaration uses the following rules: - // - // * The serialized type of a ClassDeclaration is "Function" - // * The serialized type of a ParameterDeclaration is the serialized type of its type annotation. - // * The serialized type of a PropertyDeclaration is the serialized type of its type annotation. - // * The serialized type of an AccessorDeclaration is the serialized type of the return type annotation of its getter or parameter type annotation of its setter. - // * The serialized type of any other FunctionLikeDeclaration is "Function". - // * The serialized type of any other node is "void 0". - // - // For rules on serializing type annotations, see `serializeTypeNode`. - switch (node.kind) { - case 204 /* ClassDeclaration */: return "Function"; - case 134 /* PropertyDeclaration */: return serializeTypeNode(node.type); - case 131 /* Parameter */: return serializeTypeNode(node.type); - case 138 /* GetAccessor */: return serializeTypeNode(node.type); - case 139 /* SetAccessor */: return serializeTypeNode(getSetAccessorTypeAnnotationNode(node)); - } - if (ts.isFunctionLike(node)) { - return "Function"; - } - return "void 0"; - } - /** Serializes the parameter types of a function or the constructor of a class. Used by the __metadata decorator for a method or set accessor. */ - function serializeParameterTypesOfNode(node) { - // serialization of parameter types uses the following rules: - // - // * If the declaration is a class, the parameters of the first constructor with a body are used. - // * If the declaration is function-like and has a body, the parameters of the function are used. - // - // For the rules on serializing the type of each parameter declaration, see `serializeTypeOfDeclaration`. - if (node) { - var valueDeclaration; - if (node.kind === 204 /* ClassDeclaration */) { - valueDeclaration = ts.getFirstConstructorWithBody(node); - } - else if (ts.isFunctionLike(node) && ts.nodeIsPresent(node.body)) { - valueDeclaration = node; - } - if (valueDeclaration) { - var result; - var parameters = valueDeclaration.parameters; - var parameterCount = parameters.length; - if (parameterCount > 0) { - result = new Array(parameterCount); - for (var i = 0; i < parameterCount; i++) { - if (parameters[i].dotDotDotToken) { - var parameterType = parameters[i].type; - if (parameterType.kind === 149 /* ArrayType */) { - parameterType = parameterType.elementType; - } - else if (parameterType.kind === 144 /* TypeReference */ && parameterType.typeArguments && parameterType.typeArguments.length === 1) { - parameterType = parameterType.typeArguments[0]; - } - else { - parameterType = undefined; - } - result[i] = serializeTypeNode(parameterType); - } - else { - result[i] = serializeTypeOfNode(parameters[i]); - } - } - return result; - } - } - } - return emptyArray; - } - /** Serializes the return type of function. Used by the __metadata decorator for a method. */ - function serializeReturnTypeOfNode(node) { - if (node && ts.isFunctionLike(node)) { - return serializeTypeNode(node.type); - } - return "void 0"; - } - function writeTypeOfDeclaration(declaration, enclosingDeclaration, flags, writer) { - // Get type of the symbol if this is the valid symbol otherwise get type at location - var symbol = getSymbolOfNode(declaration); - var type = symbol && !(symbol.flags & (2048 /* TypeLiteral */ | 131072 /* Signature */)) - ? getTypeOfSymbol(symbol) - : unknownType; - getSymbolDisplayBuilder().buildTypeDisplay(type, writer, enclosingDeclaration, flags); - } - function writeReturnTypeOfSignatureDeclaration(signatureDeclaration, enclosingDeclaration, flags, writer) { - var signature = getSignatureFromDeclaration(signatureDeclaration); - getSymbolDisplayBuilder().buildTypeDisplay(getReturnTypeOfSignature(signature), writer, enclosingDeclaration, flags); - } - function writeTypeOfExpression(expr, enclosingDeclaration, flags, writer) { - var type = getTypeOfExpression(expr); - getSymbolDisplayBuilder().buildTypeDisplay(type, writer, enclosingDeclaration, flags); - } - function hasGlobalName(name) { - return ts.hasProperty(globals, name); - } - function getReferencedValueSymbol(reference) { - return getNodeLinks(reference).resolvedSymbol || - resolveName(reference, reference.text, 107455 /* Value */ | 1048576 /* ExportValue */ | 8388608 /* Alias */, - /*nodeNotFoundMessage*/ undefined, undefined); - } - function getReferencedValueDeclaration(reference) { - ts.Debug.assert(!ts.nodeIsSynthesized(reference)); - var symbol = getReferencedValueSymbol(reference); - return symbol && getExportSymbolOfValueSymbolIfExported(symbol).valueDeclaration; - } - function getBlockScopedVariableId(n) { - ts.Debug.assert(!ts.nodeIsSynthesized(n)); - var isVariableDeclarationOrBindingElement = n.parent.kind === 155 /* BindingElement */ || (n.parent.kind === 201 /* VariableDeclaration */ && n.parent.name === n); - var symbol = (isVariableDeclarationOrBindingElement ? getSymbolOfNode(n.parent) : undefined) || - getNodeLinks(n).resolvedSymbol || - resolveName(n, n.text, 107455 /* Value */ | 8388608 /* Alias */, undefined, undefined); - var isLetOrConst = symbol && - (symbol.flags & 2 /* BlockScopedVariable */) && - symbol.valueDeclaration.parent.kind !== 226 /* CatchClause */; - if (isLetOrConst) { - // side-effect of calling this method: - // assign id to symbol if it was not yet set - getSymbolLinks(symbol); - return symbol.id; - } - return undefined; - } - function instantiateSingleCallFunctionType(functionType, typeArguments) { - if (functionType === unknownType) { - return unknownType; - } - var signature = getSingleCallSignature(functionType); - if (!signature) { - return unknownType; - } - var instantiatedSignature = getSignatureInstantiation(signature, typeArguments); - return getOrCreateTypeFromSignature(instantiatedSignature); - } - function createResolver() { - return { - getReferencedExportContainer: getReferencedExportContainer, - getReferencedImportDeclaration: getReferencedImportDeclaration, - getReferencedNestedRedeclaration: getReferencedNestedRedeclaration, - isNestedRedeclaration: isNestedRedeclaration, - isValueAliasDeclaration: isValueAliasDeclaration, - hasGlobalName: hasGlobalName, - isReferencedAliasDeclaration: isReferencedAliasDeclaration, - getNodeCheckFlags: getNodeCheckFlags, - isTopLevelValueImportEqualsWithEntityName: isTopLevelValueImportEqualsWithEntityName, - isDeclarationVisible: isDeclarationVisible, - isImplementationOfOverload: isImplementationOfOverload, - writeTypeOfDeclaration: writeTypeOfDeclaration, - writeReturnTypeOfSignatureDeclaration: writeReturnTypeOfSignatureDeclaration, - writeTypeOfExpression: writeTypeOfExpression, - isSymbolAccessible: isSymbolAccessible, - isEntityNameVisible: isEntityNameVisible, - getConstantValue: getConstantValue, - collectLinkedAliases: collectLinkedAliases, - getBlockScopedVariableId: getBlockScopedVariableId, - getReferencedValueDeclaration: getReferencedValueDeclaration, - serializeTypeOfNode: serializeTypeOfNode, - serializeParameterTypesOfNode: serializeParameterTypesOfNode, - serializeReturnTypeOfNode: serializeReturnTypeOfNode - }; - } - function initializeTypeChecker() { - // Bind all source files and propagate errors - ts.forEach(host.getSourceFiles(), function (file) { - ts.bindSourceFile(file); - }); - // Initialize global symbol table - ts.forEach(host.getSourceFiles(), function (file) { - if (!ts.isExternalModule(file)) { - mergeSymbolTable(globals, file.locals); - } - }); - // Initialize special symbols - getSymbolLinks(undefinedSymbol).type = undefinedType; - getSymbolLinks(argumentsSymbol).type = getGlobalType("IArguments"); - getSymbolLinks(unknownSymbol).type = unknownType; - globals[undefinedSymbol.name] = undefinedSymbol; - // Initialize special types - globalArrayType = getGlobalType("Array", 1); - globalObjectType = getGlobalType("Object"); - globalFunctionType = getGlobalType("Function"); - globalStringType = getGlobalType("String"); - globalNumberType = getGlobalType("Number"); - globalBooleanType = getGlobalType("Boolean"); - globalRegExpType = getGlobalType("RegExp"); - getGlobalClassDecoratorType = ts.memoize(function () { return getGlobalType("ClassDecorator"); }); - getGlobalPropertyDecoratorType = ts.memoize(function () { return getGlobalType("PropertyDecorator"); }); - getGlobalMethodDecoratorType = ts.memoize(function () { return getGlobalType("MethodDecorator"); }); - getGlobalParameterDecoratorType = ts.memoize(function () { return getGlobalType("ParameterDecorator"); }); - // If we're in ES6 mode, load the TemplateStringsArray. - // Otherwise, default to 'unknown' for the purposes of type checking in LS scenarios. - if (languageVersion >= 2 /* ES6 */) { - globalTemplateStringsArrayType = getGlobalType("TemplateStringsArray"); - globalESSymbolType = getGlobalType("Symbol"); - globalESSymbolConstructorSymbol = getGlobalValueSymbol("Symbol"); - globalIterableType = getGlobalType("Iterable", 1); - globalIteratorType = getGlobalType("Iterator", 1); - globalIterableIteratorType = getGlobalType("IterableIterator", 1); - } - else { - globalTemplateStringsArrayType = unknownType; - // Consider putting Symbol interface in lib.d.ts. On the plus side, putting it in lib.d.ts would make it - // extensible for Polyfilling Symbols. But putting it into lib.d.ts could also break users that have - // a global Symbol already, particularly if it is a class. - globalESSymbolType = createAnonymousType(undefined, emptySymbols, emptyArray, emptyArray, undefined, undefined); - globalESSymbolConstructorSymbol = undefined; - globalIterableType = emptyGenericType; - globalIteratorType = emptyGenericType; - globalIterableIteratorType = emptyGenericType; - } - anyArrayType = createArrayType(anyType); - } - // GRAMMAR CHECKING - function isReservedWordInStrictMode(node) { - // Check that originalKeywordKind is less than LastFutureReservedWord to see if an Identifier is a strict-mode reserved word - return (node.parserContextFlags & 1 /* StrictMode */) && - (102 /* FirstFutureReservedWord */ <= node.originalKeywordKind && node.originalKeywordKind <= 110 /* LastFutureReservedWord */); - } - function reportStrictModeGrammarErrorInClassDeclaration(identifier, message, arg0, arg1, arg2) { - // We are checking if this name is inside class declaration or class expression (which are under class definitions inside ES6 spec.) - // if so, we would like to give more explicit invalid usage error. - if (ts.getAncestor(identifier, 204 /* ClassDeclaration */) || ts.getAncestor(identifier, 177 /* ClassExpression */)) { - return grammarErrorOnNode(identifier, message, arg0); - } - return false; - } - function checkGrammarImportDeclarationNameInStrictMode(node) { - // Check if the import declaration used strict-mode reserved word in its names bindings - if (node.importClause) { - var impotClause = node.importClause; - if (impotClause.namedBindings) { - var nameBindings = impotClause.namedBindings; - if (nameBindings.kind === 214 /* NamespaceImport */) { - var name_15 = nameBindings.name; - if (isReservedWordInStrictMode(name_15)) { - var nameText = ts.declarationNameToString(name_15); - return grammarErrorOnNode(name_15, ts.Diagnostics.Identifier_expected_0_is_a_reserved_word_in_strict_mode, nameText); - } - } - else if (nameBindings.kind === 215 /* NamedImports */) { - var reportError = false; - for (var _i = 0, _a = nameBindings.elements; _i < _a.length; _i++) { - var element = _a[_i]; - var name_16 = element.name; - if (isReservedWordInStrictMode(name_16)) { - var nameText = ts.declarationNameToString(name_16); - reportError = reportError || grammarErrorOnNode(name_16, ts.Diagnostics.Identifier_expected_0_is_a_reserved_word_in_strict_mode, nameText); - } - } - return reportError; - } - } - } - return false; - } - function checkGrammarDeclarationNameInStrictMode(node) { - var name = node.name; - if (name && name.kind === 65 /* Identifier */ && isReservedWordInStrictMode(name)) { - var nameText = ts.declarationNameToString(name); - switch (node.kind) { - case 131 /* Parameter */: - case 201 /* VariableDeclaration */: - case 203 /* FunctionDeclaration */: - case 130 /* TypeParameter */: - case 155 /* BindingElement */: - case 205 /* InterfaceDeclaration */: - case 206 /* TypeAliasDeclaration */: - case 207 /* EnumDeclaration */: - return checkGrammarIdentifierInStrictMode(name); - case 204 /* ClassDeclaration */: - // Report an error if the class declaration uses strict-mode reserved word. - return grammarErrorOnNode(name, ts.Diagnostics.Identifier_expected_0_is_a_reserved_word_in_strict_mode_Class_definitions_are_automatically_in_strict_mode, nameText); - case 208 /* ModuleDeclaration */: - // Report an error if the module declaration uses strict-mode reserved word. - // TODO(yuisu): fix this when having external module in strict mode - return grammarErrorOnNode(name, ts.Diagnostics.Identifier_expected_0_is_a_reserved_word_in_strict_mode, nameText); - case 211 /* ImportEqualsDeclaration */: - // TODO(yuisu): fix this when having external module in strict mode - return grammarErrorOnNode(name, ts.Diagnostics.Identifier_expected_0_is_a_reserved_word_in_strict_mode, nameText); - } - } - return false; - } - function checkGrammarTypeReferenceInStrictMode(typeName) { - // Check if the type reference is using strict mode keyword - // Example: - // class C { - // foo(x: public){} // Error. - // } - if (typeName.kind === 65 /* Identifier */) { - checkGrammarTypeNameInStrictMode(typeName); - } - else if (typeName.kind === 128 /* QualifiedName */) { - // Walk from right to left and report a possible error at each Identifier in QualifiedName - // Example: - // x1: public.private.package // error at public and private - checkGrammarTypeNameInStrictMode(typeName.right); - checkGrammarTypeReferenceInStrictMode(typeName.left); - } - } - // This function will report an error for every identifier in property access expression - // whether it violates strict mode reserved words. - // Example: - // public // error at public - // public.private.package // error at public - // B.private.B // no error - function checkGrammarExpressionWithTypeArgumentsInStrictMode(expression) { - // Example: - // class C extends public // error at public - if (expression && expression.kind === 65 /* Identifier */) { - return checkGrammarIdentifierInStrictMode(expression); - } - else if (expression && expression.kind === 158 /* PropertyAccessExpression */) { - // Walk from left to right in PropertyAccessExpression until we are at the left most expression - // in PropertyAccessExpression. According to grammar production of MemberExpression, - // the left component expression is a PrimaryExpression (i.e. Identifier) while the other - // component after dots can be IdentifierName. - checkGrammarExpressionWithTypeArgumentsInStrictMode(expression.expression); - } - } - // The function takes an identifier itself or an expression which has SyntaxKind.Identifier. - function checkGrammarIdentifierInStrictMode(node, nameText) { - if (node && node.kind === 65 /* Identifier */ && isReservedWordInStrictMode(node)) { - if (!nameText) { - nameText = ts.declarationNameToString(node); - } - // TODO (yuisu): Fix when module is a strict mode - var errorReport = reportStrictModeGrammarErrorInClassDeclaration(node, ts.Diagnostics.Identifier_expected_0_is_a_reserved_word_in_strict_mode_Class_definitions_are_automatically_in_strict_mode, nameText) || - grammarErrorOnNode(node, ts.Diagnostics.Identifier_expected_0_is_a_reserved_word_in_strict_mode, nameText); - return errorReport; - } - return false; - } - // The function takes an identifier when uses as a typeName in TypeReferenceNode - function checkGrammarTypeNameInStrictMode(node) { - if (node && node.kind === 65 /* Identifier */ && isReservedWordInStrictMode(node)) { - var nameText = ts.declarationNameToString(node); - // TODO (yuisu): Fix when module is a strict mode - var errorReport = reportStrictModeGrammarErrorInClassDeclaration(node, ts.Diagnostics.Type_expected_0_is_a_reserved_word_in_strict_mode_Class_definitions_are_automatically_in_strict_mode, nameText) || - grammarErrorOnNode(node, ts.Diagnostics.Type_expected_0_is_a_reserved_word_in_strict_mode, nameText); - return errorReport; - } - return false; - } - function checkGrammarDecorators(node) { - if (!node.decorators) { - return false; - } - if (!ts.nodeCanBeDecorated(node)) { - return grammarErrorOnFirstToken(node, ts.Diagnostics.Decorators_are_not_valid_here); - } - else if (languageVersion < 1 /* ES5 */) { - return grammarErrorOnFirstToken(node, ts.Diagnostics.Decorators_are_only_available_when_targeting_ECMAScript_5_and_higher); - } - else if (node.kind === 138 /* GetAccessor */ || node.kind === 139 /* SetAccessor */) { - var accessors = ts.getAllAccessorDeclarations(node.parent.members, node); - if (accessors.firstAccessor.decorators && node === accessors.secondAccessor) { - return grammarErrorOnFirstToken(node, ts.Diagnostics.Decorators_cannot_be_applied_to_multiple_get_Slashset_accessors_of_the_same_name); - } - } - return false; - } - function checkGrammarModifiers(node) { - switch (node.kind) { - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 137 /* Constructor */: - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 142 /* IndexSignature */: - case 208 /* ModuleDeclaration */: - case 212 /* ImportDeclaration */: - case 211 /* ImportEqualsDeclaration */: - case 218 /* ExportDeclaration */: - case 217 /* ExportAssignment */: - case 131 /* Parameter */: - break; - case 204 /* ClassDeclaration */: - case 205 /* InterfaceDeclaration */: - case 183 /* VariableStatement */: - case 203 /* FunctionDeclaration */: - case 206 /* TypeAliasDeclaration */: - if (node.modifiers && node.parent.kind !== 209 /* ModuleBlock */ && node.parent.kind !== 230 /* SourceFile */) { - return grammarErrorOnFirstToken(node, ts.Diagnostics.Modifiers_cannot_appear_here); - } - break; - case 207 /* EnumDeclaration */: - if (node.modifiers && (node.modifiers.length > 1 || node.modifiers[0].kind !== 70 /* ConstKeyword */) && - node.parent.kind !== 209 /* ModuleBlock */ && node.parent.kind !== 230 /* SourceFile */) { - return grammarErrorOnFirstToken(node, ts.Diagnostics.Modifiers_cannot_appear_here); - } - break; - default: - return false; - } - if (!node.modifiers) { - return; - } - var lastStatic, lastPrivate, lastProtected, lastDeclare; - var flags = 0; - for (var _i = 0, _a = node.modifiers; _i < _a.length; _i++) { - var modifier = _a[_i]; - switch (modifier.kind) { - case 108 /* PublicKeyword */: - case 107 /* ProtectedKeyword */: - case 106 /* PrivateKeyword */: - var text = void 0; - if (modifier.kind === 108 /* PublicKeyword */) { - text = "public"; - } - else if (modifier.kind === 107 /* ProtectedKeyword */) { - text = "protected"; - lastProtected = modifier; - } - else { - text = "private"; - lastPrivate = modifier; - } - if (flags & 112 /* AccessibilityModifier */) { - return grammarErrorOnNode(modifier, ts.Diagnostics.Accessibility_modifier_already_seen); - } - else if (flags & 128 /* Static */) { - return grammarErrorOnNode(modifier, ts.Diagnostics._0_modifier_must_precede_1_modifier, text, "static"); - } - else if (node.parent.kind === 209 /* ModuleBlock */ || node.parent.kind === 230 /* SourceFile */) { - return grammarErrorOnNode(modifier, ts.Diagnostics._0_modifier_cannot_appear_on_a_module_element, text); - } - flags |= ts.modifierToFlag(modifier.kind); - break; - case 109 /* StaticKeyword */: - if (flags & 128 /* Static */) { - return grammarErrorOnNode(modifier, ts.Diagnostics._0_modifier_already_seen, "static"); - } - else if (node.parent.kind === 209 /* ModuleBlock */ || node.parent.kind === 230 /* SourceFile */) { - return grammarErrorOnNode(modifier, ts.Diagnostics._0_modifier_cannot_appear_on_a_module_element, "static"); - } - else if (node.kind === 131 /* Parameter */) { - return grammarErrorOnNode(modifier, ts.Diagnostics._0_modifier_cannot_appear_on_a_parameter, "static"); - } - flags |= 128 /* Static */; - lastStatic = modifier; - break; - case 78 /* ExportKeyword */: - if (flags & 1 /* Export */) { - return grammarErrorOnNode(modifier, ts.Diagnostics._0_modifier_already_seen, "export"); - } - else if (flags & 2 /* Ambient */) { - return grammarErrorOnNode(modifier, ts.Diagnostics._0_modifier_must_precede_1_modifier, "export", "declare"); - } - else if (node.parent.kind === 204 /* ClassDeclaration */) { - return grammarErrorOnNode(modifier, ts.Diagnostics._0_modifier_cannot_appear_on_a_class_element, "export"); - } - else if (node.kind === 131 /* Parameter */) { - return grammarErrorOnNode(modifier, ts.Diagnostics._0_modifier_cannot_appear_on_a_parameter, "export"); - } - flags |= 1 /* Export */; - break; - case 115 /* DeclareKeyword */: - if (flags & 2 /* Ambient */) { - return grammarErrorOnNode(modifier, ts.Diagnostics._0_modifier_already_seen, "declare"); - } - else if (node.parent.kind === 204 /* ClassDeclaration */) { - return grammarErrorOnNode(modifier, ts.Diagnostics._0_modifier_cannot_appear_on_a_class_element, "declare"); - } - else if (node.kind === 131 /* Parameter */) { - return grammarErrorOnNode(modifier, ts.Diagnostics._0_modifier_cannot_appear_on_a_parameter, "declare"); - } - else if (ts.isInAmbientContext(node.parent) && node.parent.kind === 209 /* ModuleBlock */) { - return grammarErrorOnNode(modifier, ts.Diagnostics.A_declare_modifier_cannot_be_used_in_an_already_ambient_context); - } - flags |= 2 /* Ambient */; - lastDeclare = modifier; - break; - } - } - if (node.kind === 137 /* Constructor */) { - if (flags & 128 /* Static */) { - return grammarErrorOnNode(lastStatic, ts.Diagnostics._0_modifier_cannot_appear_on_a_constructor_declaration, "static"); - } - else if (flags & 64 /* Protected */) { - return grammarErrorOnNode(lastProtected, ts.Diagnostics._0_modifier_cannot_appear_on_a_constructor_declaration, "protected"); - } - else if (flags & 32 /* Private */) { - return grammarErrorOnNode(lastPrivate, ts.Diagnostics._0_modifier_cannot_appear_on_a_constructor_declaration, "private"); - } - } - else if ((node.kind === 212 /* ImportDeclaration */ || node.kind === 211 /* ImportEqualsDeclaration */) && flags & 2 /* Ambient */) { - return grammarErrorOnNode(lastDeclare, ts.Diagnostics.A_declare_modifier_cannot_be_used_with_an_import_declaration, "declare"); - } - else if (node.kind === 131 /* Parameter */ && (flags & 112 /* AccessibilityModifier */) && ts.isBindingPattern(node.name)) { - return grammarErrorOnNode(node, ts.Diagnostics.A_parameter_property_may_not_be_a_binding_pattern); - } - } - function checkGrammarForDisallowedTrailingComma(list) { - if (list && list.hasTrailingComma) { - var start = list.end - ",".length; - var end = list.end; - var sourceFile = ts.getSourceFileOfNode(list[0]); - return grammarErrorAtPos(sourceFile, start, end - start, ts.Diagnostics.Trailing_comma_not_allowed); - } - } - function checkGrammarTypeParameterList(node, typeParameters, file) { - if (checkGrammarForDisallowedTrailingComma(typeParameters)) { - return true; - } - if (typeParameters && typeParameters.length === 0) { - var start = typeParameters.pos - "<".length; - var end = ts.skipTrivia(file.text, typeParameters.end) + ">".length; - return grammarErrorAtPos(file, start, end - start, ts.Diagnostics.Type_parameter_list_cannot_be_empty); - } - } - function checkGrammarParameterList(parameters) { - if (checkGrammarForDisallowedTrailingComma(parameters)) { - return true; - } - var seenOptionalParameter = false; - var parameterCount = parameters.length; - for (var i = 0; i < parameterCount; i++) { - var parameter = parameters[i]; - if (parameter.dotDotDotToken) { - if (i !== (parameterCount - 1)) { - return grammarErrorOnNode(parameter.dotDotDotToken, ts.Diagnostics.A_rest_parameter_must_be_last_in_a_parameter_list); - } - if (ts.isBindingPattern(parameter.name)) { - return grammarErrorOnNode(parameter.name, ts.Diagnostics.A_rest_element_cannot_contain_a_binding_pattern); - } - if (parameter.questionToken) { - return grammarErrorOnNode(parameter.questionToken, ts.Diagnostics.A_rest_parameter_cannot_be_optional); - } - if (parameter.initializer) { - return grammarErrorOnNode(parameter.name, ts.Diagnostics.A_rest_parameter_cannot_have_an_initializer); - } - } - else if (parameter.questionToken || parameter.initializer) { - seenOptionalParameter = true; - if (parameter.questionToken && parameter.initializer) { - return grammarErrorOnNode(parameter.name, ts.Diagnostics.Parameter_cannot_have_question_mark_and_initializer); - } - } - else { - if (seenOptionalParameter) { - return grammarErrorOnNode(parameter.name, ts.Diagnostics.A_required_parameter_cannot_follow_an_optional_parameter); - } - } - } - } - function checkGrammarFunctionLikeDeclaration(node) { - // Prevent cascading error by short-circuit - var file = ts.getSourceFileOfNode(node); - return checkGrammarDecorators(node) || checkGrammarModifiers(node) || checkGrammarTypeParameterList(node, node.typeParameters, file) || - checkGrammarParameterList(node.parameters) || checkGrammarArrowFunction(node, file); - } - function checkGrammarArrowFunction(node, file) { - if (node.kind === 166 /* ArrowFunction */) { - var arrowFunction = node; - var startLine = ts.getLineAndCharacterOfPosition(file, arrowFunction.equalsGreaterThanToken.pos).line; - var endLine = ts.getLineAndCharacterOfPosition(file, arrowFunction.equalsGreaterThanToken.end).line; - if (startLine !== endLine) { - return grammarErrorOnNode(arrowFunction.equalsGreaterThanToken, ts.Diagnostics.Line_terminator_not_permitted_before_arrow); - } - } - return false; - } - function checkGrammarIndexSignatureParameters(node) { - var parameter = node.parameters[0]; - if (node.parameters.length !== 1) { - if (parameter) { - return grammarErrorOnNode(parameter.name, ts.Diagnostics.An_index_signature_must_have_exactly_one_parameter); - } - else { - return grammarErrorOnNode(node, ts.Diagnostics.An_index_signature_must_have_exactly_one_parameter); - } - } - if (parameter.dotDotDotToken) { - return grammarErrorOnNode(parameter.dotDotDotToken, ts.Diagnostics.An_index_signature_cannot_have_a_rest_parameter); - } - if (parameter.flags & 499 /* Modifier */) { - return grammarErrorOnNode(parameter.name, ts.Diagnostics.An_index_signature_parameter_cannot_have_an_accessibility_modifier); - } - if (parameter.questionToken) { - return grammarErrorOnNode(parameter.questionToken, ts.Diagnostics.An_index_signature_parameter_cannot_have_a_question_mark); - } - if (parameter.initializer) { - return grammarErrorOnNode(parameter.name, ts.Diagnostics.An_index_signature_parameter_cannot_have_an_initializer); - } - if (!parameter.type) { - return grammarErrorOnNode(parameter.name, ts.Diagnostics.An_index_signature_parameter_must_have_a_type_annotation); - } - if (parameter.type.kind !== 123 /* StringKeyword */ && parameter.type.kind !== 121 /* NumberKeyword */) { - return grammarErrorOnNode(parameter.name, ts.Diagnostics.An_index_signature_parameter_type_must_be_string_or_number); - } - if (!node.type) { - return grammarErrorOnNode(node, ts.Diagnostics.An_index_signature_must_have_a_type_annotation); - } - } - function checkGrammarForIndexSignatureModifier(node) { - if (node.flags & 499 /* Modifier */) { - grammarErrorOnFirstToken(node, ts.Diagnostics.Modifiers_not_permitted_on_index_signature_members); - } - } - function checkGrammarIndexSignature(node) { - // Prevent cascading error by short-circuit - return checkGrammarDecorators(node) || checkGrammarModifiers(node) || checkGrammarIndexSignatureParameters(node) || checkGrammarForIndexSignatureModifier(node); - } - function checkGrammarForAtLeastOneTypeArgument(node, typeArguments) { - if (typeArguments && typeArguments.length === 0) { - var sourceFile = ts.getSourceFileOfNode(node); - var start = typeArguments.pos - "<".length; - var end = ts.skipTrivia(sourceFile.text, typeArguments.end) + ">".length; - return grammarErrorAtPos(sourceFile, start, end - start, ts.Diagnostics.Type_argument_list_cannot_be_empty); - } - } - function checkGrammarTypeArguments(node, typeArguments) { - return checkGrammarForDisallowedTrailingComma(typeArguments) || - checkGrammarForAtLeastOneTypeArgument(node, typeArguments); - } - function checkGrammarForOmittedArgument(node, arguments) { - if (arguments) { - var sourceFile = ts.getSourceFileOfNode(node); - for (var _i = 0; _i < arguments.length; _i++) { - var arg = arguments[_i]; - if (arg.kind === 178 /* OmittedExpression */) { - return grammarErrorAtPos(sourceFile, arg.pos, 0, ts.Diagnostics.Argument_expression_expected); - } - } - } - } - function checkGrammarArguments(node, arguments) { - return checkGrammarForDisallowedTrailingComma(arguments) || - checkGrammarForOmittedArgument(node, arguments); - } - function checkGrammarHeritageClause(node) { - var types = node.types; - if (checkGrammarForDisallowedTrailingComma(types)) { - return true; - } - if (types && types.length === 0) { - var listType = ts.tokenToString(node.token); - var sourceFile = ts.getSourceFileOfNode(node); - return grammarErrorAtPos(sourceFile, types.pos, 0, ts.Diagnostics._0_list_cannot_be_empty, listType); - } - } - function checkGrammarClassDeclarationHeritageClauses(node) { - var seenExtendsClause = false; - var seenImplementsClause = false; - if (!checkGrammarDecorators(node) && !checkGrammarModifiers(node) && node.heritageClauses) { - for (var _i = 0, _a = node.heritageClauses; _i < _a.length; _i++) { - var heritageClause = _a[_i]; - if (heritageClause.token === 79 /* ExtendsKeyword */) { - if (seenExtendsClause) { - return grammarErrorOnFirstToken(heritageClause, ts.Diagnostics.extends_clause_already_seen); - } - if (seenImplementsClause) { - return grammarErrorOnFirstToken(heritageClause, ts.Diagnostics.extends_clause_must_precede_implements_clause); - } - if (heritageClause.types.length > 1) { - return grammarErrorOnFirstToken(heritageClause.types[1], ts.Diagnostics.Classes_can_only_extend_a_single_class); - } - seenExtendsClause = true; - } - else { - ts.Debug.assert(heritageClause.token === 102 /* ImplementsKeyword */); - if (seenImplementsClause) { - return grammarErrorOnFirstToken(heritageClause, ts.Diagnostics.implements_clause_already_seen); - } - seenImplementsClause = true; - } - // Grammar checking heritageClause inside class declaration - checkGrammarHeritageClause(heritageClause); - } - } - } - function checkGrammarInterfaceDeclaration(node) { - var seenExtendsClause = false; - if (node.heritageClauses) { - for (var _i = 0, _a = node.heritageClauses; _i < _a.length; _i++) { - var heritageClause = _a[_i]; - if (heritageClause.token === 79 /* ExtendsKeyword */) { - if (seenExtendsClause) { - return grammarErrorOnFirstToken(heritageClause, ts.Diagnostics.extends_clause_already_seen); - } - seenExtendsClause = true; - } - else { - ts.Debug.assert(heritageClause.token === 102 /* ImplementsKeyword */); - return grammarErrorOnFirstToken(heritageClause, ts.Diagnostics.Interface_declaration_cannot_have_implements_clause); - } - // Grammar checking heritageClause inside class declaration - checkGrammarHeritageClause(heritageClause); - } - } - return false; - } - function checkGrammarComputedPropertyName(node) { - // If node is not a computedPropertyName, just skip the grammar checking - if (node.kind !== 129 /* ComputedPropertyName */) { - return false; - } - var computedPropertyName = node; - if (computedPropertyName.expression.kind === 172 /* BinaryExpression */ && computedPropertyName.expression.operatorToken.kind === 23 /* CommaToken */) { - return grammarErrorOnNode(computedPropertyName.expression, ts.Diagnostics.A_comma_expression_is_not_allowed_in_a_computed_property_name); - } - } - function checkGrammarForGenerator(node) { - if (node.asteriskToken) { - ts.Debug.assert(node.kind === 203 /* FunctionDeclaration */ || - node.kind === 165 /* FunctionExpression */ || - node.kind === 136 /* MethodDeclaration */); - if (ts.isInAmbientContext(node)) { - return grammarErrorOnNode(node.asteriskToken, ts.Diagnostics.Generators_are_not_allowed_in_an_ambient_context); - } - if (!node.body) { - return grammarErrorOnNode(node.asteriskToken, ts.Diagnostics.An_overload_signature_cannot_be_declared_as_a_generator); - } - if (languageVersion < 2 /* ES6 */) { - return grammarErrorOnNode(node.asteriskToken, ts.Diagnostics.Generators_are_only_available_when_targeting_ECMAScript_6_or_higher); - } - } - } - function checkGrammarFunctionName(name) { - // It is a SyntaxError if the identifier eval or arguments appears within a FormalParameterList of a strict mode FunctionDeclaration or FunctionExpression (13.1)) - return checkGrammarEvalOrArgumentsInStrictMode(name, name); - } - function checkGrammarForInvalidQuestionMark(node, questionToken, message) { - if (questionToken) { - return grammarErrorOnNode(questionToken, message); - } - } - function checkGrammarObjectLiteralExpression(node) { - var seen = {}; - var Property = 1; - var GetAccessor = 2; - var SetAccesor = 4; - var GetOrSetAccessor = GetAccessor | SetAccesor; - var inStrictMode = (node.parserContextFlags & 1 /* StrictMode */) !== 0; - for (var _i = 0, _a = node.properties; _i < _a.length; _i++) { - var prop = _a[_i]; - var name_17 = prop.name; - if (prop.kind === 178 /* OmittedExpression */ || - name_17.kind === 129 /* ComputedPropertyName */) { - // If the name is not a ComputedPropertyName, the grammar checking will skip it - checkGrammarComputedPropertyName(name_17); - continue; - } - // ECMA-262 11.1.5 Object Initialiser - // If previous is not undefined then throw a SyntaxError exception if any of the following conditions are true - // a.This production is contained in strict code and IsDataDescriptor(previous) is true and - // IsDataDescriptor(propId.descriptor) is true. - // b.IsDataDescriptor(previous) is true and IsAccessorDescriptor(propId.descriptor) is true. - // c.IsAccessorDescriptor(previous) is true and IsDataDescriptor(propId.descriptor) is true. - // d.IsAccessorDescriptor(previous) is true and IsAccessorDescriptor(propId.descriptor) is true - // and either both previous and propId.descriptor have[[Get]] fields or both previous and propId.descriptor have[[Set]] fields - var currentKind = void 0; - if (prop.kind === 227 /* PropertyAssignment */ || prop.kind === 228 /* ShorthandPropertyAssignment */) { - // Grammar checking for computedPropertName and shorthandPropertyAssignment - checkGrammarForInvalidQuestionMark(prop, prop.questionToken, ts.Diagnostics.An_object_member_cannot_be_declared_optional); - if (name_17.kind === 7 /* NumericLiteral */) { - checkGrammarNumericLiteral(name_17); - } - currentKind = Property; - } - else if (prop.kind === 136 /* MethodDeclaration */) { - currentKind = Property; - } - else if (prop.kind === 138 /* GetAccessor */) { - currentKind = GetAccessor; - } - else if (prop.kind === 139 /* SetAccessor */) { - currentKind = SetAccesor; - } - else { - ts.Debug.fail("Unexpected syntax kind:" + prop.kind); - } - if (!ts.hasProperty(seen, name_17.text)) { - seen[name_17.text] = currentKind; - } - else { - var existingKind = seen[name_17.text]; - if (currentKind === Property && existingKind === Property) { - if (inStrictMode) { - grammarErrorOnNode(name_17, ts.Diagnostics.An_object_literal_cannot_have_multiple_properties_with_the_same_name_in_strict_mode); - } - } - else if ((currentKind & GetOrSetAccessor) && (existingKind & GetOrSetAccessor)) { - if (existingKind !== GetOrSetAccessor && currentKind !== existingKind) { - seen[name_17.text] = currentKind | existingKind; - } - else { - return grammarErrorOnNode(name_17, ts.Diagnostics.An_object_literal_cannot_have_multiple_get_Slashset_accessors_with_the_same_name); - } - } - else { - return grammarErrorOnNode(name_17, ts.Diagnostics.An_object_literal_cannot_have_property_and_accessor_with_the_same_name); - } - } - } - } - function checkGrammarForInOrForOfStatement(forInOrOfStatement) { - if (checkGrammarStatementInAmbientContext(forInOrOfStatement)) { - return true; - } - if (forInOrOfStatement.initializer.kind === 202 /* VariableDeclarationList */) { - var variableList = forInOrOfStatement.initializer; - if (!checkGrammarVariableDeclarationList(variableList)) { - if (variableList.declarations.length > 1) { - var diagnostic = forInOrOfStatement.kind === 190 /* ForInStatement */ - ? ts.Diagnostics.Only_a_single_variable_declaration_is_allowed_in_a_for_in_statement - : ts.Diagnostics.Only_a_single_variable_declaration_is_allowed_in_a_for_of_statement; - return grammarErrorOnFirstToken(variableList.declarations[1], diagnostic); - } - var firstDeclaration = variableList.declarations[0]; - if (firstDeclaration.initializer) { - var diagnostic = forInOrOfStatement.kind === 190 /* ForInStatement */ - ? ts.Diagnostics.The_variable_declaration_of_a_for_in_statement_cannot_have_an_initializer - : ts.Diagnostics.The_variable_declaration_of_a_for_of_statement_cannot_have_an_initializer; - return grammarErrorOnNode(firstDeclaration.name, diagnostic); - } - if (firstDeclaration.type) { - var diagnostic = forInOrOfStatement.kind === 190 /* ForInStatement */ - ? ts.Diagnostics.The_left_hand_side_of_a_for_in_statement_cannot_use_a_type_annotation - : ts.Diagnostics.The_left_hand_side_of_a_for_of_statement_cannot_use_a_type_annotation; - return grammarErrorOnNode(firstDeclaration, diagnostic); - } - } - } - return false; - } - function checkGrammarAccessor(accessor) { - var kind = accessor.kind; - if (languageVersion < 1 /* ES5 */) { - return grammarErrorOnNode(accessor.name, ts.Diagnostics.Accessors_are_only_available_when_targeting_ECMAScript_5_and_higher); - } - else if (ts.isInAmbientContext(accessor)) { - return grammarErrorOnNode(accessor.name, ts.Diagnostics.An_accessor_cannot_be_declared_in_an_ambient_context); - } - else if (accessor.body === undefined) { - return grammarErrorAtPos(ts.getSourceFileOfNode(accessor), accessor.end - 1, ";".length, ts.Diagnostics._0_expected, "{"); - } - else if (accessor.typeParameters) { - return grammarErrorOnNode(accessor.name, ts.Diagnostics.An_accessor_cannot_have_type_parameters); - } - else if (kind === 138 /* GetAccessor */ && accessor.parameters.length) { - return grammarErrorOnNode(accessor.name, ts.Diagnostics.A_get_accessor_cannot_have_parameters); - } - else if (kind === 139 /* SetAccessor */) { - if (accessor.type) { - return grammarErrorOnNode(accessor.name, ts.Diagnostics.A_set_accessor_cannot_have_a_return_type_annotation); - } - else if (accessor.parameters.length !== 1) { - return grammarErrorOnNode(accessor.name, ts.Diagnostics.A_set_accessor_must_have_exactly_one_parameter); - } - else { - var parameter = accessor.parameters[0]; - if (parameter.dotDotDotToken) { - return grammarErrorOnNode(parameter.dotDotDotToken, ts.Diagnostics.A_set_accessor_cannot_have_rest_parameter); - } - else if (parameter.flags & 499 /* Modifier */) { - return grammarErrorOnNode(accessor.name, ts.Diagnostics.A_parameter_property_is_only_allowed_in_a_constructor_implementation); - } - else if (parameter.questionToken) { - return grammarErrorOnNode(parameter.questionToken, ts.Diagnostics.A_set_accessor_cannot_have_an_optional_parameter); - } - else if (parameter.initializer) { - return grammarErrorOnNode(accessor.name, ts.Diagnostics.A_set_accessor_parameter_cannot_have_an_initializer); - } - } - } - } - function checkGrammarForNonSymbolComputedProperty(node, message) { - if (node.kind === 129 /* ComputedPropertyName */ && !ts.isWellKnownSymbolSyntactically(node.expression)) { - return grammarErrorOnNode(node, message); - } - } - function checkGrammarMethod(node) { - if (checkGrammarDisallowedModifiersInBlockOrObjectLiteralExpression(node) || - checkGrammarFunctionLikeDeclaration(node) || - checkGrammarForGenerator(node)) { - return true; - } - if (node.parent.kind === 157 /* ObjectLiteralExpression */) { - if (checkGrammarForInvalidQuestionMark(node, node.questionToken, ts.Diagnostics.A_class_member_cannot_be_declared_optional)) { - return true; - } - else if (node.body === undefined) { - return grammarErrorAtPos(getSourceFile(node), node.end - 1, ";".length, ts.Diagnostics._0_expected, "{"); - } - } - if (node.parent.kind === 204 /* ClassDeclaration */) { - if (checkGrammarForInvalidQuestionMark(node, node.questionToken, ts.Diagnostics.A_class_member_cannot_be_declared_optional)) { - return true; - } - // Technically, computed properties in ambient contexts is disallowed - // for property declarations and accessors too, not just methods. - // However, property declarations disallow computed names in general, - // and accessors are not allowed in ambient contexts in general, - // so this error only really matters for methods. - if (ts.isInAmbientContext(node)) { - return checkGrammarForNonSymbolComputedProperty(node.name, ts.Diagnostics.A_computed_property_name_in_an_ambient_context_must_directly_refer_to_a_built_in_symbol); - } - else if (!node.body) { - return checkGrammarForNonSymbolComputedProperty(node.name, ts.Diagnostics.A_computed_property_name_in_a_method_overload_must_directly_refer_to_a_built_in_symbol); - } - } - else if (node.parent.kind === 205 /* InterfaceDeclaration */) { - return checkGrammarForNonSymbolComputedProperty(node.name, ts.Diagnostics.A_computed_property_name_in_an_interface_must_directly_refer_to_a_built_in_symbol); - } - else if (node.parent.kind === 148 /* TypeLiteral */) { - return checkGrammarForNonSymbolComputedProperty(node.name, ts.Diagnostics.A_computed_property_name_in_a_type_literal_must_directly_refer_to_a_built_in_symbol); - } - } - function isIterationStatement(node, lookInLabeledStatements) { - switch (node.kind) { - case 189 /* ForStatement */: - case 190 /* ForInStatement */: - case 191 /* ForOfStatement */: - case 187 /* DoStatement */: - case 188 /* WhileStatement */: - return true; - case 197 /* LabeledStatement */: - return lookInLabeledStatements && isIterationStatement(node.statement, lookInLabeledStatements); - } - return false; - } - function checkGrammarBreakOrContinueStatement(node) { - var current = node; - while (current) { - if (ts.isFunctionLike(current)) { - return grammarErrorOnNode(node, ts.Diagnostics.Jump_target_cannot_cross_function_boundary); - } - switch (current.kind) { - case 197 /* LabeledStatement */: - if (node.label && current.label.text === node.label.text) { - // found matching label - verify that label usage is correct - // continue can only target labels that are on iteration statements - var isMisplacedContinueLabel = node.kind === 192 /* ContinueStatement */ - && !isIterationStatement(current.statement, true); - if (isMisplacedContinueLabel) { - return grammarErrorOnNode(node, ts.Diagnostics.A_continue_statement_can_only_jump_to_a_label_of_an_enclosing_iteration_statement); - } - return false; - } - break; - case 196 /* SwitchStatement */: - if (node.kind === 193 /* BreakStatement */ && !node.label) { - // unlabeled break within switch statement - ok - return false; - } - break; - default: - if (isIterationStatement(current, false) && !node.label) { - // unlabeled break or continue within iteration statement - ok - return false; - } - break; - } - current = current.parent; - } - if (node.label) { - var message = node.kind === 193 /* BreakStatement */ - ? ts.Diagnostics.A_break_statement_can_only_jump_to_a_label_of_an_enclosing_statement - : ts.Diagnostics.A_continue_statement_can_only_jump_to_a_label_of_an_enclosing_iteration_statement; - return grammarErrorOnNode(node, message); - } - else { - var message = node.kind === 193 /* BreakStatement */ - ? ts.Diagnostics.A_break_statement_can_only_be_used_within_an_enclosing_iteration_or_switch_statement - : ts.Diagnostics.A_continue_statement_can_only_be_used_within_an_enclosing_iteration_statement; - return grammarErrorOnNode(node, message); - } - } - function checkGrammarBindingElement(node) { - if (node.dotDotDotToken) { - var elements = node.parent.elements; - if (node !== ts.lastOrUndefined(elements)) { - return grammarErrorOnNode(node, ts.Diagnostics.A_rest_element_must_be_last_in_an_array_destructuring_pattern); - } - if (node.name.kind === 154 /* ArrayBindingPattern */ || node.name.kind === 153 /* ObjectBindingPattern */) { - return grammarErrorOnNode(node.name, ts.Diagnostics.A_rest_element_cannot_contain_a_binding_pattern); - } - if (node.initializer) { - // Error on equals token which immediate precedes the initializer - return grammarErrorAtPos(ts.getSourceFileOfNode(node), node.initializer.pos - 1, 1, ts.Diagnostics.A_rest_element_cannot_have_an_initializer); - } - } - // It is a SyntaxError if a VariableDeclaration or VariableDeclarationNoIn occurs within strict code - // and its Identifier is eval or arguments - return checkGrammarEvalOrArgumentsInStrictMode(node, node.name); - } - function checkGrammarVariableDeclaration(node) { - if (node.parent.parent.kind !== 190 /* ForInStatement */ && node.parent.parent.kind !== 191 /* ForOfStatement */) { - if (ts.isInAmbientContext(node)) { - if (node.initializer) { - // Error on equals token which immediate precedes the initializer - var equalsTokenLength = "=".length; - return grammarErrorAtPos(ts.getSourceFileOfNode(node), node.initializer.pos - equalsTokenLength, equalsTokenLength, ts.Diagnostics.Initializers_are_not_allowed_in_ambient_contexts); - } - } - else if (!node.initializer) { - if (ts.isBindingPattern(node.name) && !ts.isBindingPattern(node.parent)) { - return grammarErrorOnNode(node, ts.Diagnostics.A_destructuring_declaration_must_have_an_initializer); - } - if (ts.isConst(node)) { - return grammarErrorOnNode(node, ts.Diagnostics.const_declarations_must_be_initialized); - } - } - } - var checkLetConstNames = languageVersion >= 2 /* ES6 */ && (ts.isLet(node) || ts.isConst(node)); - // 1. LexicalDeclaration : LetOrConst BindingList ; - // It is a Syntax Error if the BoundNames of BindingList contains "let". - // 2. ForDeclaration: ForDeclaration : LetOrConst ForBinding - // It is a Syntax Error if the BoundNames of ForDeclaration contains "let". - // It is a SyntaxError if a VariableDeclaration or VariableDeclarationNoIn occurs within strict code - // and its Identifier is eval or arguments - return (checkLetConstNames && checkGrammarNameInLetOrConstDeclarations(node.name)) || - checkGrammarEvalOrArgumentsInStrictMode(node, node.name); - } - function checkGrammarNameInLetOrConstDeclarations(name) { - if (name.kind === 65 /* Identifier */) { - if (name.text === "let") { - return grammarErrorOnNode(name, ts.Diagnostics.let_is_not_allowed_to_be_used_as_a_name_in_let_or_const_declarations); - } - } - else { - var elements = name.elements; - for (var _i = 0; _i < elements.length; _i++) { - var element = elements[_i]; - if (element.kind !== 178 /* OmittedExpression */) { - checkGrammarNameInLetOrConstDeclarations(element.name); - } - } - } - } - function checkGrammarVariableDeclarationList(declarationList) { - var declarations = declarationList.declarations; - if (checkGrammarForDisallowedTrailingComma(declarationList.declarations)) { - return true; - } - if (!declarationList.declarations.length) { - return grammarErrorAtPos(ts.getSourceFileOfNode(declarationList), declarations.pos, declarations.end - declarations.pos, ts.Diagnostics.Variable_declaration_list_cannot_be_empty); - } - } - function allowLetAndConstDeclarations(parent) { - switch (parent.kind) { - case 186 /* IfStatement */: - case 187 /* DoStatement */: - case 188 /* WhileStatement */: - case 195 /* WithStatement */: - case 189 /* ForStatement */: - case 190 /* ForInStatement */: - case 191 /* ForOfStatement */: - return false; - case 197 /* LabeledStatement */: - return allowLetAndConstDeclarations(parent.parent); - } - return true; - } - function checkGrammarForDisallowedLetOrConstStatement(node) { - if (!allowLetAndConstDeclarations(node.parent)) { - if (ts.isLet(node.declarationList)) { - return grammarErrorOnNode(node, ts.Diagnostics.let_declarations_can_only_be_declared_inside_a_block); - } - else if (ts.isConst(node.declarationList)) { - return grammarErrorOnNode(node, ts.Diagnostics.const_declarations_can_only_be_declared_inside_a_block); - } - } - } - function isIntegerLiteral(expression) { - if (expression.kind === 170 /* PrefixUnaryExpression */) { - var unaryExpression = expression; - if (unaryExpression.operator === 33 /* PlusToken */ || unaryExpression.operator === 34 /* MinusToken */) { - expression = unaryExpression.operand; - } - } - if (expression.kind === 7 /* NumericLiteral */) { - // Allows for scientific notation since literalExpression.text was formed by - // coercing a number to a string. Sometimes this coercion can yield a string - // in scientific notation. - // We also don't need special logic for hex because a hex integer is converted - // to decimal when it is coerced. - return /^[0-9]+([eE]\+?[0-9]+)?$/.test(expression.text); - } - return false; - } - function checkGrammarEnumDeclaration(enumDecl) { - var enumIsConst = (enumDecl.flags & 8192 /* Const */) !== 0; - var hasError = false; - // skip checks below for const enums - they allow arbitrary initializers as long as they can be evaluated to constant expressions. - // since all values are known in compile time - it is not necessary to check that constant enum section precedes computed enum members. - if (!enumIsConst) { - var inConstantEnumMemberSection = true; - var inAmbientContext = ts.isInAmbientContext(enumDecl); - for (var _i = 0, _a = enumDecl.members; _i < _a.length; _i++) { - var node = _a[_i]; - // Do not use hasDynamicName here, because that returns false for well known symbols. - // We want to perform checkComputedPropertyName for all computed properties, including - // well known symbols. - if (node.name.kind === 129 /* ComputedPropertyName */) { - hasError = grammarErrorOnNode(node.name, ts.Diagnostics.Computed_property_names_are_not_allowed_in_enums); - } - else if (inAmbientContext) { - if (node.initializer && !isIntegerLiteral(node.initializer)) { - hasError = grammarErrorOnNode(node.name, ts.Diagnostics.Ambient_enum_elements_can_only_have_integer_literal_initializers) || hasError; - } - } - else if (node.initializer) { - inConstantEnumMemberSection = isIntegerLiteral(node.initializer); - } - else if (!inConstantEnumMemberSection) { - hasError = grammarErrorOnNode(node.name, ts.Diagnostics.Enum_member_must_have_initializer) || hasError; - } - } - } - return hasError; - } - function hasParseDiagnostics(sourceFile) { - return sourceFile.parseDiagnostics.length > 0; - } - function grammarErrorOnFirstToken(node, message, arg0, arg1, arg2) { - var sourceFile = ts.getSourceFileOfNode(node); - if (!hasParseDiagnostics(sourceFile)) { - var span = ts.getSpanOfTokenAtPosition(sourceFile, node.pos); - diagnostics.add(ts.createFileDiagnostic(sourceFile, span.start, span.length, message, arg0, arg1, arg2)); - return true; - } - } - function grammarErrorAtPos(sourceFile, start, length, message, arg0, arg1, arg2) { - if (!hasParseDiagnostics(sourceFile)) { - diagnostics.add(ts.createFileDiagnostic(sourceFile, start, length, message, arg0, arg1, arg2)); - return true; - } - } - function grammarErrorOnNode(node, message, arg0, arg1, arg2) { - var sourceFile = ts.getSourceFileOfNode(node); - if (!hasParseDiagnostics(sourceFile)) { - diagnostics.add(ts.createDiagnosticForNode(node, message, arg0, arg1, arg2)); - return true; - } - } - function checkGrammarEvalOrArgumentsInStrictMode(contextNode, name) { - if (name && name.kind === 65 /* Identifier */) { - var identifier = name; - if (contextNode && (contextNode.parserContextFlags & 1 /* StrictMode */) && isEvalOrArgumentsIdentifier(identifier)) { - var nameText = ts.declarationNameToString(identifier); - // We check first if the name is inside class declaration or class expression; if so give explicit message - // otherwise report generic error message. - // reportGrammarErrorInClassDeclaration only return true if grammar error is successfully reported and false otherwise - var reportErrorInClassDeclaration = reportStrictModeGrammarErrorInClassDeclaration(identifier, ts.Diagnostics.Invalid_use_of_0_Class_definitions_are_automatically_in_strict_mode, nameText); - if (!reportErrorInClassDeclaration) { - return grammarErrorOnNode(identifier, ts.Diagnostics.Invalid_use_of_0_in_strict_mode, nameText); - } - return reportErrorInClassDeclaration; - } - } - } - function isEvalOrArgumentsIdentifier(node) { - return node.kind === 65 /* Identifier */ && - (node.text === "eval" || node.text === "arguments"); - } - function checkGrammarConstructorTypeParameters(node) { - if (node.typeParameters) { - return grammarErrorAtPos(ts.getSourceFileOfNode(node), node.typeParameters.pos, node.typeParameters.end - node.typeParameters.pos, ts.Diagnostics.Type_parameters_cannot_appear_on_a_constructor_declaration); - } - } - function checkGrammarConstructorTypeAnnotation(node) { - if (node.type) { - return grammarErrorOnNode(node.type, ts.Diagnostics.Type_annotation_cannot_appear_on_a_constructor_declaration); - } - } - function checkGrammarProperty(node) { - if (node.parent.kind === 204 /* ClassDeclaration */) { - if (checkGrammarForInvalidQuestionMark(node, node.questionToken, ts.Diagnostics.A_class_member_cannot_be_declared_optional) || - checkGrammarForNonSymbolComputedProperty(node.name, ts.Diagnostics.A_computed_property_name_in_a_class_property_declaration_must_directly_refer_to_a_built_in_symbol)) { - return true; - } - } - else if (node.parent.kind === 205 /* InterfaceDeclaration */) { - if (checkGrammarForNonSymbolComputedProperty(node.name, ts.Diagnostics.A_computed_property_name_in_an_interface_must_directly_refer_to_a_built_in_symbol)) { - return true; - } - } - else if (node.parent.kind === 148 /* TypeLiteral */) { - if (checkGrammarForNonSymbolComputedProperty(node.name, ts.Diagnostics.A_computed_property_name_in_a_type_literal_must_directly_refer_to_a_built_in_symbol)) { - return true; - } - } - if (ts.isInAmbientContext(node) && node.initializer) { - return grammarErrorOnFirstToken(node.initializer, ts.Diagnostics.Initializers_are_not_allowed_in_ambient_contexts); - } - } - function checkGrammarTopLevelElementForRequiredDeclareModifier(node) { - // A declare modifier is required for any top level .d.ts declaration except export=, export default, - // interfaces and imports categories: - // - // DeclarationElement: - // ExportAssignment - // export_opt InterfaceDeclaration - // export_opt ImportDeclaration - // export_opt ExternalImportDeclaration - // export_opt AmbientDeclaration - // - if (node.kind === 205 /* InterfaceDeclaration */ || - node.kind === 212 /* ImportDeclaration */ || - node.kind === 211 /* ImportEqualsDeclaration */ || - node.kind === 218 /* ExportDeclaration */ || - node.kind === 217 /* ExportAssignment */ || - (node.flags & 2 /* Ambient */) || - (node.flags & (1 /* Export */ | 256 /* Default */))) { - return false; - } - return grammarErrorOnFirstToken(node, ts.Diagnostics.A_declare_modifier_is_required_for_a_top_level_declaration_in_a_d_ts_file); - } - function checkGrammarTopLevelElementsForRequiredDeclareModifier(file) { - for (var _i = 0, _a = file.statements; _i < _a.length; _i++) { - var decl = _a[_i]; - if (ts.isDeclaration(decl) || decl.kind === 183 /* VariableStatement */) { - if (checkGrammarTopLevelElementForRequiredDeclareModifier(decl)) { - return true; - } - } - } - } - function checkGrammarSourceFile(node) { - return ts.isInAmbientContext(node) && checkGrammarTopLevelElementsForRequiredDeclareModifier(node); - } - function checkGrammarStatementInAmbientContext(node) { - if (ts.isInAmbientContext(node)) { - // An accessors is already reported about the ambient context - if (isAccessor(node.parent.kind)) { - return getNodeLinks(node).hasReportedStatementInAmbientContext = true; - } - // Find containing block which is either Block, ModuleBlock, SourceFile - var links = getNodeLinks(node); - if (!links.hasReportedStatementInAmbientContext && ts.isFunctionLike(node.parent)) { - return getNodeLinks(node).hasReportedStatementInAmbientContext = grammarErrorOnFirstToken(node, ts.Diagnostics.An_implementation_cannot_be_declared_in_ambient_contexts); - } - // We are either parented by another statement, or some sort of block. - // If we're in a block, we only want to really report an error once - // to prevent noisyness. So use a bit on the block to indicate if - // this has already been reported, and don't report if it has. - // - if (node.parent.kind === 182 /* Block */ || node.parent.kind === 209 /* ModuleBlock */ || node.parent.kind === 230 /* SourceFile */) { - var links_1 = getNodeLinks(node.parent); - // Check if the containing block ever report this error - if (!links_1.hasReportedStatementInAmbientContext) { - return links_1.hasReportedStatementInAmbientContext = grammarErrorOnFirstToken(node, ts.Diagnostics.Statements_are_not_allowed_in_ambient_contexts); - } - } - else { - } - } - } - function checkGrammarNumericLiteral(node) { - // Grammar checking - if (node.flags & 16384 /* OctalLiteral */) { - if (node.parserContextFlags & 1 /* StrictMode */) { - return grammarErrorOnNode(node, ts.Diagnostics.Octal_literals_are_not_allowed_in_strict_mode); - } - else if (languageVersion >= 1 /* ES5 */) { - return grammarErrorOnNode(node, ts.Diagnostics.Octal_literals_are_not_available_when_targeting_ECMAScript_5_and_higher); - } - } - } - function grammarErrorAfterFirstToken(node, message, arg0, arg1, arg2) { - var sourceFile = ts.getSourceFileOfNode(node); - if (!hasParseDiagnostics(sourceFile)) { - var span = ts.getSpanOfTokenAtPosition(sourceFile, node.pos); - diagnostics.add(ts.createFileDiagnostic(sourceFile, ts.textSpanEnd(span), 0, message, arg0, arg1, arg2)); - return true; - } - } - initializeTypeChecker(); - return checker; - } - ts.createTypeChecker = createTypeChecker; -})(ts || (ts = {})); -/// -/* @internal */ -var ts; -(function (ts) { - function getDeclarationDiagnostics(host, resolver, targetSourceFile) { - var diagnostics = []; - var jsFilePath = ts.getOwnEmitOutputFilePath(targetSourceFile, host, ".js"); - emitDeclarations(host, resolver, diagnostics, jsFilePath, targetSourceFile); - return diagnostics; - } - ts.getDeclarationDiagnostics = getDeclarationDiagnostics; - function emitDeclarations(host, resolver, diagnostics, jsFilePath, root) { - var newLine = host.getNewLine(); - var compilerOptions = host.getCompilerOptions(); - var languageVersion = compilerOptions.target || 0 /* ES3 */; - var write; - var writeLine; - var increaseIndent; - var decreaseIndent; - var writeTextOfNode; - var writer = createAndSetNewTextWriterWithSymbolWriter(); - var enclosingDeclaration; - var currentSourceFile; - var reportedDeclarationError = false; - var emitJsDocComments = compilerOptions.removeComments ? function (declaration) { } : writeJsDocComments; - var emit = compilerOptions.stripInternal ? stripInternal : emitNode; - var moduleElementDeclarationEmitInfo = []; - var asynchronousSubModuleDeclarationEmitInfo; - // Contains the reference paths that needs to go in the declaration file. - // Collecting this separately because reference paths need to be first thing in the declaration file - // and we could be collecting these paths from multiple files into single one with --out option - var referencePathsOutput = ""; - if (root) { - // Emitting just a single file, so emit references in this file only - if (!compilerOptions.noResolve) { - var addedGlobalFileReference = false; - ts.forEach(root.referencedFiles, function (fileReference) { - var referencedFile = ts.tryResolveScriptReference(host, root, fileReference); - // All the references that are not going to be part of same file - if (referencedFile && ((referencedFile.flags & 2048 /* DeclarationFile */) || - ts.shouldEmitToOwnFile(referencedFile, compilerOptions) || - !addedGlobalFileReference)) { - writeReferencePath(referencedFile); - if (!ts.isExternalModuleOrDeclarationFile(referencedFile)) { - addedGlobalFileReference = true; - } - } - }); - } - emitSourceFile(root); - // create asynchronous output for the importDeclarations - if (moduleElementDeclarationEmitInfo.length) { - var oldWriter = writer; - ts.forEach(moduleElementDeclarationEmitInfo, function (aliasEmitInfo) { - if (aliasEmitInfo.isVisible) { - ts.Debug.assert(aliasEmitInfo.node.kind === 212 /* ImportDeclaration */); - createAndSetNewTextWriterWithSymbolWriter(); - ts.Debug.assert(aliasEmitInfo.indent === 0); - writeImportDeclaration(aliasEmitInfo.node); - aliasEmitInfo.asynchronousOutput = writer.getText(); - } - }); - setWriter(oldWriter); - } - } - else { - // Emit references corresponding to this file - var emittedReferencedFiles = []; - ts.forEach(host.getSourceFiles(), function (sourceFile) { - if (!ts.isExternalModuleOrDeclarationFile(sourceFile)) { - // Check what references need to be added - if (!compilerOptions.noResolve) { - ts.forEach(sourceFile.referencedFiles, function (fileReference) { - var referencedFile = ts.tryResolveScriptReference(host, sourceFile, fileReference); - // If the reference file is a declaration file or an external module, emit that reference - if (referencedFile && (ts.isExternalModuleOrDeclarationFile(referencedFile) && - !ts.contains(emittedReferencedFiles, referencedFile))) { - writeReferencePath(referencedFile); - emittedReferencedFiles.push(referencedFile); - } - }); - } - emitSourceFile(sourceFile); - } - }); - } - return { - reportedDeclarationError: reportedDeclarationError, - moduleElementDeclarationEmitInfo: moduleElementDeclarationEmitInfo, - synchronousDeclarationOutput: writer.getText(), - referencePathsOutput: referencePathsOutput - }; - function hasInternalAnnotation(range) { - var text = currentSourceFile.text; - var comment = text.substring(range.pos, range.end); - return comment.indexOf("@internal") >= 0; - } - function stripInternal(node) { - if (node) { - var leadingCommentRanges = ts.getLeadingCommentRanges(currentSourceFile.text, node.pos); - if (ts.forEach(leadingCommentRanges, hasInternalAnnotation)) { - return; - } - emitNode(node); - } - } - function createAndSetNewTextWriterWithSymbolWriter() { - var writer = ts.createTextWriter(newLine); - writer.trackSymbol = trackSymbol; - writer.writeKeyword = writer.write; - writer.writeOperator = writer.write; - writer.writePunctuation = writer.write; - writer.writeSpace = writer.write; - writer.writeStringLiteral = writer.writeLiteral; - writer.writeParameter = writer.write; - writer.writeSymbol = writer.write; - setWriter(writer); - return writer; - } - function setWriter(newWriter) { - writer = newWriter; - write = newWriter.write; - writeTextOfNode = newWriter.writeTextOfNode; - writeLine = newWriter.writeLine; - increaseIndent = newWriter.increaseIndent; - decreaseIndent = newWriter.decreaseIndent; - } - function writeAsynchronousModuleElements(nodes) { - var oldWriter = writer; - ts.forEach(nodes, function (declaration) { - var nodeToCheck; - if (declaration.kind === 201 /* VariableDeclaration */) { - nodeToCheck = declaration.parent.parent; - } - else if (declaration.kind === 215 /* NamedImports */ || declaration.kind === 216 /* ImportSpecifier */ || declaration.kind === 213 /* ImportClause */) { - ts.Debug.fail("We should be getting ImportDeclaration instead to write"); - } - else { - nodeToCheck = declaration; - } - var moduleElementEmitInfo = ts.forEach(moduleElementDeclarationEmitInfo, function (declEmitInfo) { return declEmitInfo.node === nodeToCheck ? declEmitInfo : undefined; }); - if (!moduleElementEmitInfo && asynchronousSubModuleDeclarationEmitInfo) { - moduleElementEmitInfo = ts.forEach(asynchronousSubModuleDeclarationEmitInfo, function (declEmitInfo) { return declEmitInfo.node === nodeToCheck ? declEmitInfo : undefined; }); - } - // If the alias was marked as not visible when we saw its declaration, we would have saved the aliasEmitInfo, but if we haven't yet visited the alias declaration - // then we don't need to write it at this point. We will write it when we actually see its declaration - // Eg. - // export function bar(a: foo.Foo) { } - // import foo = require("foo"); - // Writing of function bar would mark alias declaration foo as visible but we haven't yet visited that declaration so do nothing, - // we would write alias foo declaration when we visit it since it would now be marked as visible - if (moduleElementEmitInfo) { - if (moduleElementEmitInfo.node.kind === 212 /* ImportDeclaration */) { - // we have to create asynchronous output only after we have collected complete information - // because it is possible to enable multiple bindings as asynchronously visible - moduleElementEmitInfo.isVisible = true; - } - else { - createAndSetNewTextWriterWithSymbolWriter(); - for (var declarationIndent = moduleElementEmitInfo.indent; declarationIndent; declarationIndent--) { - increaseIndent(); - } - if (nodeToCheck.kind === 208 /* ModuleDeclaration */) { - ts.Debug.assert(asynchronousSubModuleDeclarationEmitInfo === undefined); - asynchronousSubModuleDeclarationEmitInfo = []; - } - writeModuleElement(nodeToCheck); - if (nodeToCheck.kind === 208 /* ModuleDeclaration */) { - moduleElementEmitInfo.subModuleElementDeclarationEmitInfo = asynchronousSubModuleDeclarationEmitInfo; - asynchronousSubModuleDeclarationEmitInfo = undefined; - } - moduleElementEmitInfo.asynchronousOutput = writer.getText(); - } - } - }); - setWriter(oldWriter); - } - function handleSymbolAccessibilityError(symbolAccesibilityResult) { - if (symbolAccesibilityResult.accessibility === 0 /* Accessible */) { - // write the aliases - if (symbolAccesibilityResult && symbolAccesibilityResult.aliasesToMakeVisible) { - writeAsynchronousModuleElements(symbolAccesibilityResult.aliasesToMakeVisible); - } - } - else { - // Report error - reportedDeclarationError = true; - var errorInfo = writer.getSymbolAccessibilityDiagnostic(symbolAccesibilityResult); - if (errorInfo) { - if (errorInfo.typeName) { - diagnostics.push(ts.createDiagnosticForNode(symbolAccesibilityResult.errorNode || errorInfo.errorNode, errorInfo.diagnosticMessage, ts.getSourceTextOfNodeFromSourceFile(currentSourceFile, errorInfo.typeName), symbolAccesibilityResult.errorSymbolName, symbolAccesibilityResult.errorModuleName)); - } - else { - diagnostics.push(ts.createDiagnosticForNode(symbolAccesibilityResult.errorNode || errorInfo.errorNode, errorInfo.diagnosticMessage, symbolAccesibilityResult.errorSymbolName, symbolAccesibilityResult.errorModuleName)); - } - } - } - } - function trackSymbol(symbol, enclosingDeclaration, meaning) { - handleSymbolAccessibilityError(resolver.isSymbolAccessible(symbol, enclosingDeclaration, meaning)); - } - function writeTypeOfDeclaration(declaration, type, getSymbolAccessibilityDiagnostic) { - writer.getSymbolAccessibilityDiagnostic = getSymbolAccessibilityDiagnostic; - write(": "); - if (type) { - // Write the type - emitType(type); - } - else { - resolver.writeTypeOfDeclaration(declaration, enclosingDeclaration, 2 /* UseTypeOfFunction */, writer); - } - } - function writeReturnTypeAtSignature(signature, getSymbolAccessibilityDiagnostic) { - writer.getSymbolAccessibilityDiagnostic = getSymbolAccessibilityDiagnostic; - write(": "); - if (signature.type) { - // Write the type - emitType(signature.type); - } - else { - resolver.writeReturnTypeOfSignatureDeclaration(signature, enclosingDeclaration, 2 /* UseTypeOfFunction */, writer); - } - } - function emitLines(nodes) { - for (var _i = 0; _i < nodes.length; _i++) { - var node = nodes[_i]; - emit(node); - } - } - function emitSeparatedList(nodes, separator, eachNodeEmitFn, canEmitFn) { - var currentWriterPos = writer.getTextPos(); - for (var _i = 0; _i < nodes.length; _i++) { - var node = nodes[_i]; - if (!canEmitFn || canEmitFn(node)) { - if (currentWriterPos !== writer.getTextPos()) { - write(separator); - } - currentWriterPos = writer.getTextPos(); - eachNodeEmitFn(node); - } - } - } - function emitCommaList(nodes, eachNodeEmitFn, canEmitFn) { - emitSeparatedList(nodes, ", ", eachNodeEmitFn, canEmitFn); - } - function writeJsDocComments(declaration) { - if (declaration) { - var jsDocComments = ts.getJsDocComments(declaration, currentSourceFile); - ts.emitNewLineBeforeLeadingComments(currentSourceFile, writer, declaration, jsDocComments); - // jsDoc comments are emitted at /*leading comment1 */space/*leading comment*/space - ts.emitComments(currentSourceFile, writer, jsDocComments, true, newLine, ts.writeCommentRange); - } - } - function emitTypeWithNewGetSymbolAccessibilityDiagnostic(type, getSymbolAccessibilityDiagnostic) { - writer.getSymbolAccessibilityDiagnostic = getSymbolAccessibilityDiagnostic; - emitType(type); - } - function emitType(type) { - switch (type.kind) { - case 112 /* AnyKeyword */: - case 123 /* StringKeyword */: - case 121 /* NumberKeyword */: - case 113 /* BooleanKeyword */: - case 124 /* SymbolKeyword */: - case 99 /* VoidKeyword */: - case 8 /* StringLiteral */: - return writeTextOfNode(currentSourceFile, type); - case 179 /* ExpressionWithTypeArguments */: - return emitExpressionWithTypeArguments(type); - case 144 /* TypeReference */: - return emitTypeReference(type); - case 147 /* TypeQuery */: - return emitTypeQuery(type); - case 149 /* ArrayType */: - return emitArrayType(type); - case 150 /* TupleType */: - return emitTupleType(type); - case 151 /* UnionType */: - return emitUnionType(type); - case 152 /* ParenthesizedType */: - return emitParenType(type); - case 145 /* FunctionType */: - case 146 /* ConstructorType */: - return emitSignatureDeclarationWithJsDocComments(type); - case 148 /* TypeLiteral */: - return emitTypeLiteral(type); - case 65 /* Identifier */: - return emitEntityName(type); - case 128 /* QualifiedName */: - return emitEntityName(type); - } - function emitEntityName(entityName) { - var visibilityResult = resolver.isEntityNameVisible(entityName, - // Aliases can be written asynchronously so use correct enclosing declaration - entityName.parent.kind === 211 /* ImportEqualsDeclaration */ ? entityName.parent : enclosingDeclaration); - handleSymbolAccessibilityError(visibilityResult); - writeEntityName(entityName); - function writeEntityName(entityName) { - if (entityName.kind === 65 /* Identifier */) { - writeTextOfNode(currentSourceFile, entityName); - } - else { - var left = entityName.kind === 128 /* QualifiedName */ ? entityName.left : entityName.expression; - var right = entityName.kind === 128 /* QualifiedName */ ? entityName.right : entityName.name; - writeEntityName(left); - write("."); - writeTextOfNode(currentSourceFile, right); - } - } - } - function emitExpressionWithTypeArguments(node) { - if (ts.isSupportedExpressionWithTypeArguments(node)) { - ts.Debug.assert(node.expression.kind === 65 /* Identifier */ || node.expression.kind === 158 /* PropertyAccessExpression */); - emitEntityName(node.expression); - if (node.typeArguments) { - write("<"); - emitCommaList(node.typeArguments, emitType); - write(">"); - } - } - } - function emitTypeReference(type) { - emitEntityName(type.typeName); - if (type.typeArguments) { - write("<"); - emitCommaList(type.typeArguments, emitType); - write(">"); - } - } - function emitTypeQuery(type) { - write("typeof "); - emitEntityName(type.exprName); - } - function emitArrayType(type) { - emitType(type.elementType); - write("[]"); - } - function emitTupleType(type) { - write("["); - emitCommaList(type.elementTypes, emitType); - write("]"); - } - function emitUnionType(type) { - emitSeparatedList(type.types, " | ", emitType); - } - function emitParenType(type) { - write("("); - emitType(type.type); - write(")"); - } - function emitTypeLiteral(type) { - write("{"); - if (type.members.length) { - writeLine(); - increaseIndent(); - // write members - emitLines(type.members); - decreaseIndent(); - } - write("}"); - } - } - function emitSourceFile(node) { - currentSourceFile = node; - enclosingDeclaration = node; - emitLines(node.statements); - } - // Return a temp variable name to be used in `export default` statements. - // The temp name will be of the form _default_counter. - // Note that export default is only allowed at most once in a module, so we - // do not need to keep track of created temp names. - function getExportDefaultTempVariableName() { - var baseName = "_default"; - if (!ts.hasProperty(currentSourceFile.identifiers, baseName)) { - return baseName; - } - var count = 0; - while (true) { - var name_18 = baseName + "_" + (++count); - if (!ts.hasProperty(currentSourceFile.identifiers, name_18)) { - return name_18; - } - } - } - function emitExportAssignment(node) { - if (node.expression.kind === 65 /* Identifier */) { - write(node.isExportEquals ? "export = " : "export default "); - writeTextOfNode(currentSourceFile, node.expression); - } - else { - // Expression - var tempVarName = getExportDefaultTempVariableName(); - write("declare var "); - write(tempVarName); - write(": "); - writer.getSymbolAccessibilityDiagnostic = getDefaultExportAccessibilityDiagnostic; - resolver.writeTypeOfExpression(node.expression, enclosingDeclaration, 2 /* UseTypeOfFunction */, writer); - write(";"); - writeLine(); - write(node.isExportEquals ? "export = " : "export default "); - write(tempVarName); - } - write(";"); - writeLine(); - // Make all the declarations visible for the export name - if (node.expression.kind === 65 /* Identifier */) { - var nodes = resolver.collectLinkedAliases(node.expression); - // write each of these declarations asynchronously - writeAsynchronousModuleElements(nodes); - } - function getDefaultExportAccessibilityDiagnostic(diagnostic) { - return { - diagnosticMessage: ts.Diagnostics.Default_export_of_the_module_has_or_is_using_private_name_0, - errorNode: node - }; - } - } - function isModuleElementVisible(node) { - return resolver.isDeclarationVisible(node); - } - function emitModuleElement(node, isModuleElementVisible) { - if (isModuleElementVisible) { - writeModuleElement(node); - } - else if (node.kind === 211 /* ImportEqualsDeclaration */ || - (node.parent.kind === 230 /* SourceFile */ && ts.isExternalModule(currentSourceFile))) { - var isVisible; - if (asynchronousSubModuleDeclarationEmitInfo && node.parent.kind !== 230 /* SourceFile */) { - // Import declaration of another module that is visited async so lets put it in right spot - asynchronousSubModuleDeclarationEmitInfo.push({ - node: node, - outputPos: writer.getTextPos(), - indent: writer.getIndent(), - isVisible: isVisible - }); - } - else { - if (node.kind === 212 /* ImportDeclaration */) { - var importDeclaration = node; - if (importDeclaration.importClause) { - isVisible = (importDeclaration.importClause.name && resolver.isDeclarationVisible(importDeclaration.importClause)) || - isVisibleNamedBinding(importDeclaration.importClause.namedBindings); - } - } - moduleElementDeclarationEmitInfo.push({ - node: node, - outputPos: writer.getTextPos(), - indent: writer.getIndent(), - isVisible: isVisible - }); - } - } - } - function writeModuleElement(node) { - switch (node.kind) { - case 203 /* FunctionDeclaration */: - return writeFunctionDeclaration(node); - case 183 /* VariableStatement */: - return writeVariableStatement(node); - case 205 /* InterfaceDeclaration */: - return writeInterfaceDeclaration(node); - case 204 /* ClassDeclaration */: - return writeClassDeclaration(node); - case 206 /* TypeAliasDeclaration */: - return writeTypeAliasDeclaration(node); - case 207 /* EnumDeclaration */: - return writeEnumDeclaration(node); - case 208 /* ModuleDeclaration */: - return writeModuleDeclaration(node); - case 211 /* ImportEqualsDeclaration */: - return writeImportEqualsDeclaration(node); - case 212 /* ImportDeclaration */: - return writeImportDeclaration(node); - default: - ts.Debug.fail("Unknown symbol kind"); - } - } - function emitModuleElementDeclarationFlags(node) { - // If the node is parented in the current source file we need to emit export declare or just export - if (node.parent === currentSourceFile) { - // If the node is exported - if (node.flags & 1 /* Export */) { - write("export "); - } - if (node.flags & 256 /* Default */) { - write("default "); - } - else if (node.kind !== 205 /* InterfaceDeclaration */) { - write("declare "); - } - } - } - function emitClassMemberDeclarationFlags(node) { - if (node.flags & 32 /* Private */) { - write("private "); - } - else if (node.flags & 64 /* Protected */) { - write("protected "); - } - if (node.flags & 128 /* Static */) { - write("static "); - } - } - function writeImportEqualsDeclaration(node) { - // note usage of writer. methods instead of aliases created, just to make sure we are using - // correct writer especially to handle asynchronous alias writing - emitJsDocComments(node); - if (node.flags & 1 /* Export */) { - write("export "); - } - write("import "); - writeTextOfNode(currentSourceFile, node.name); - write(" = "); - if (ts.isInternalModuleImportEqualsDeclaration(node)) { - emitTypeWithNewGetSymbolAccessibilityDiagnostic(node.moduleReference, getImportEntityNameVisibilityError); - write(";"); - } - else { - write("require("); - writeTextOfNode(currentSourceFile, ts.getExternalModuleImportEqualsDeclarationExpression(node)); - write(");"); - } - writer.writeLine(); - function getImportEntityNameVisibilityError(symbolAccesibilityResult) { - return { - diagnosticMessage: ts.Diagnostics.Import_declaration_0_is_using_private_name_1, - errorNode: node, - typeName: node.name - }; - } - } - function isVisibleNamedBinding(namedBindings) { - if (namedBindings) { - if (namedBindings.kind === 214 /* NamespaceImport */) { - return resolver.isDeclarationVisible(namedBindings); - } - else { - return ts.forEach(namedBindings.elements, function (namedImport) { return resolver.isDeclarationVisible(namedImport); }); - } - } - } - function writeImportDeclaration(node) { - if (!node.importClause && !(node.flags & 1 /* Export */)) { - // do not write non-exported import declarations that don't have import clauses - return; - } - emitJsDocComments(node); - if (node.flags & 1 /* Export */) { - write("export "); - } - write("import "); - if (node.importClause) { - var currentWriterPos = writer.getTextPos(); - if (node.importClause.name && resolver.isDeclarationVisible(node.importClause)) { - writeTextOfNode(currentSourceFile, node.importClause.name); - } - if (node.importClause.namedBindings && isVisibleNamedBinding(node.importClause.namedBindings)) { - if (currentWriterPos !== writer.getTextPos()) { - // If the default binding was emitted, write the separated - write(", "); - } - if (node.importClause.namedBindings.kind === 214 /* NamespaceImport */) { - write("* as "); - writeTextOfNode(currentSourceFile, node.importClause.namedBindings.name); - } - else { - write("{ "); - emitCommaList(node.importClause.namedBindings.elements, emitImportOrExportSpecifier, resolver.isDeclarationVisible); - write(" }"); - } - } - write(" from "); - } - writeTextOfNode(currentSourceFile, node.moduleSpecifier); - write(";"); - writer.writeLine(); - } - function emitImportOrExportSpecifier(node) { - if (node.propertyName) { - writeTextOfNode(currentSourceFile, node.propertyName); - write(" as "); - } - writeTextOfNode(currentSourceFile, node.name); - } - function emitExportSpecifier(node) { - emitImportOrExportSpecifier(node); - // Make all the declarations visible for the export name - var nodes = resolver.collectLinkedAliases(node.propertyName || node.name); - // write each of these declarations asynchronously - writeAsynchronousModuleElements(nodes); - } - function emitExportDeclaration(node) { - emitJsDocComments(node); - write("export "); - if (node.exportClause) { - write("{ "); - emitCommaList(node.exportClause.elements, emitExportSpecifier); - write(" }"); - } - else { - write("*"); - } - if (node.moduleSpecifier) { - write(" from "); - writeTextOfNode(currentSourceFile, node.moduleSpecifier); - } - write(";"); - writer.writeLine(); - } - function writeModuleDeclaration(node) { - emitJsDocComments(node); - emitModuleElementDeclarationFlags(node); - write("module "); - writeTextOfNode(currentSourceFile, node.name); - while (node.body.kind !== 209 /* ModuleBlock */) { - node = node.body; - write("."); - writeTextOfNode(currentSourceFile, node.name); - } - var prevEnclosingDeclaration = enclosingDeclaration; - enclosingDeclaration = node; - write(" {"); - writeLine(); - increaseIndent(); - emitLines(node.body.statements); - decreaseIndent(); - write("}"); - writeLine(); - enclosingDeclaration = prevEnclosingDeclaration; - } - function writeTypeAliasDeclaration(node) { - emitJsDocComments(node); - emitModuleElementDeclarationFlags(node); - write("type "); - writeTextOfNode(currentSourceFile, node.name); - write(" = "); - emitTypeWithNewGetSymbolAccessibilityDiagnostic(node.type, getTypeAliasDeclarationVisibilityError); - write(";"); - writeLine(); - function getTypeAliasDeclarationVisibilityError(symbolAccesibilityResult) { - return { - diagnosticMessage: ts.Diagnostics.Exported_type_alias_0_has_or_is_using_private_name_1, - errorNode: node.type, - typeName: node.name - }; - } - } - function writeEnumDeclaration(node) { - emitJsDocComments(node); - emitModuleElementDeclarationFlags(node); - if (ts.isConst(node)) { - write("const "); - } - write("enum "); - writeTextOfNode(currentSourceFile, node.name); - write(" {"); - writeLine(); - increaseIndent(); - emitLines(node.members); - decreaseIndent(); - write("}"); - writeLine(); - } - function emitEnumMemberDeclaration(node) { - emitJsDocComments(node); - writeTextOfNode(currentSourceFile, node.name); - var enumMemberValue = resolver.getConstantValue(node); - if (enumMemberValue !== undefined) { - write(" = "); - write(enumMemberValue.toString()); - } - write(","); - writeLine(); - } - function isPrivateMethodTypeParameter(node) { - return node.parent.kind === 136 /* MethodDeclaration */ && (node.parent.flags & 32 /* Private */); - } - function emitTypeParameters(typeParameters) { - function emitTypeParameter(node) { - increaseIndent(); - emitJsDocComments(node); - decreaseIndent(); - writeTextOfNode(currentSourceFile, node.name); - // If there is constraint present and this is not a type parameter of the private method emit the constraint - if (node.constraint && !isPrivateMethodTypeParameter(node)) { - write(" extends "); - if (node.parent.kind === 145 /* FunctionType */ || - node.parent.kind === 146 /* ConstructorType */ || - (node.parent.parent && node.parent.parent.kind === 148 /* TypeLiteral */)) { - ts.Debug.assert(node.parent.kind === 136 /* MethodDeclaration */ || - node.parent.kind === 135 /* MethodSignature */ || - node.parent.kind === 145 /* FunctionType */ || - node.parent.kind === 146 /* ConstructorType */ || - node.parent.kind === 140 /* CallSignature */ || - node.parent.kind === 141 /* ConstructSignature */); - emitType(node.constraint); - } - else { - emitTypeWithNewGetSymbolAccessibilityDiagnostic(node.constraint, getTypeParameterConstraintVisibilityError); - } - } - function getTypeParameterConstraintVisibilityError(symbolAccesibilityResult) { - // Type parameter constraints are named by user so we should always be able to name it - var diagnosticMessage; - switch (node.parent.kind) { - case 204 /* ClassDeclaration */: - diagnosticMessage = ts.Diagnostics.Type_parameter_0_of_exported_class_has_or_is_using_private_name_1; - break; - case 205 /* InterfaceDeclaration */: - diagnosticMessage = ts.Diagnostics.Type_parameter_0_of_exported_interface_has_or_is_using_private_name_1; - break; - case 141 /* ConstructSignature */: - diagnosticMessage = ts.Diagnostics.Type_parameter_0_of_constructor_signature_from_exported_interface_has_or_is_using_private_name_1; - break; - case 140 /* CallSignature */: - diagnosticMessage = ts.Diagnostics.Type_parameter_0_of_call_signature_from_exported_interface_has_or_is_using_private_name_1; - break; - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - if (node.parent.flags & 128 /* Static */) { - diagnosticMessage = ts.Diagnostics.Type_parameter_0_of_public_static_method_from_exported_class_has_or_is_using_private_name_1; - } - else if (node.parent.parent.kind === 204 /* ClassDeclaration */) { - diagnosticMessage = ts.Diagnostics.Type_parameter_0_of_public_method_from_exported_class_has_or_is_using_private_name_1; - } - else { - diagnosticMessage = ts.Diagnostics.Type_parameter_0_of_method_from_exported_interface_has_or_is_using_private_name_1; - } - break; - case 203 /* FunctionDeclaration */: - diagnosticMessage = ts.Diagnostics.Type_parameter_0_of_exported_function_has_or_is_using_private_name_1; - break; - default: - ts.Debug.fail("This is unknown parent for type parameter: " + node.parent.kind); - } - return { - diagnosticMessage: diagnosticMessage, - errorNode: node, - typeName: node.name - }; - } - } - if (typeParameters) { - write("<"); - emitCommaList(typeParameters, emitTypeParameter); - write(">"); - } - } - function emitHeritageClause(typeReferences, isImplementsList) { - if (typeReferences) { - write(isImplementsList ? " implements " : " extends "); - emitCommaList(typeReferences, emitTypeOfTypeReference); - } - function emitTypeOfTypeReference(node) { - if (ts.isSupportedExpressionWithTypeArguments(node)) { - emitTypeWithNewGetSymbolAccessibilityDiagnostic(node, getHeritageClauseVisibilityError); - } - function getHeritageClauseVisibilityError(symbolAccesibilityResult) { - var diagnosticMessage; - // Heritage clause is written by user so it can always be named - if (node.parent.parent.kind === 204 /* ClassDeclaration */) { - // Class or Interface implemented/extended is inaccessible - diagnosticMessage = isImplementsList ? - ts.Diagnostics.Implements_clause_of_exported_class_0_has_or_is_using_private_name_1 : - ts.Diagnostics.Extends_clause_of_exported_class_0_has_or_is_using_private_name_1; - } - else { - // interface is inaccessible - diagnosticMessage = ts.Diagnostics.Extends_clause_of_exported_interface_0_has_or_is_using_private_name_1; - } - return { - diagnosticMessage: diagnosticMessage, - errorNode: node, - typeName: node.parent.parent.name - }; - } - } - } - function writeClassDeclaration(node) { - function emitParameterProperties(constructorDeclaration) { - if (constructorDeclaration) { - ts.forEach(constructorDeclaration.parameters, function (param) { - if (param.flags & 112 /* AccessibilityModifier */) { - emitPropertyDeclaration(param); - } - }); - } - } - emitJsDocComments(node); - emitModuleElementDeclarationFlags(node); - write("class "); - writeTextOfNode(currentSourceFile, node.name); - var prevEnclosingDeclaration = enclosingDeclaration; - enclosingDeclaration = node; - emitTypeParameters(node.typeParameters); - var baseTypeNode = ts.getClassExtendsHeritageClauseElement(node); - if (baseTypeNode) { - emitHeritageClause([baseTypeNode], false); - } - emitHeritageClause(ts.getClassImplementsHeritageClauseElements(node), true); - write(" {"); - writeLine(); - increaseIndent(); - emitParameterProperties(ts.getFirstConstructorWithBody(node)); - emitLines(node.members); - decreaseIndent(); - write("}"); - writeLine(); - enclosingDeclaration = prevEnclosingDeclaration; - } - function writeInterfaceDeclaration(node) { - emitJsDocComments(node); - emitModuleElementDeclarationFlags(node); - write("interface "); - writeTextOfNode(currentSourceFile, node.name); - var prevEnclosingDeclaration = enclosingDeclaration; - enclosingDeclaration = node; - emitTypeParameters(node.typeParameters); - emitHeritageClause(ts.getInterfaceBaseTypeNodes(node), false); - write(" {"); - writeLine(); - increaseIndent(); - emitLines(node.members); - decreaseIndent(); - write("}"); - writeLine(); - enclosingDeclaration = prevEnclosingDeclaration; - } - function emitPropertyDeclaration(node) { - if (ts.hasDynamicName(node)) { - return; - } - emitJsDocComments(node); - emitClassMemberDeclarationFlags(node); - emitVariableDeclaration(node); - write(";"); - writeLine(); - } - function emitVariableDeclaration(node) { - // If we are emitting property it isn't moduleElement and hence we already know it needs to be emitted - // so there is no check needed to see if declaration is visible - if (node.kind !== 201 /* VariableDeclaration */ || resolver.isDeclarationVisible(node)) { - if (ts.isBindingPattern(node.name)) { - emitBindingPattern(node.name); - } - else { - // If this node is a computed name, it can only be a symbol, because we've already skipped - // it if it's not a well known symbol. In that case, the text of the name will be exactly - // what we want, namely the name expression enclosed in brackets. - writeTextOfNode(currentSourceFile, node.name); - // If optional property emit ? - if ((node.kind === 134 /* PropertyDeclaration */ || node.kind === 133 /* PropertySignature */) && ts.hasQuestionToken(node)) { - write("?"); - } - if ((node.kind === 134 /* PropertyDeclaration */ || node.kind === 133 /* PropertySignature */) && node.parent.kind === 148 /* TypeLiteral */) { - emitTypeOfVariableDeclarationFromTypeLiteral(node); - } - else if (!(node.flags & 32 /* Private */)) { - writeTypeOfDeclaration(node, node.type, getVariableDeclarationTypeVisibilityError); - } - } - } - function getVariableDeclarationTypeVisibilityDiagnosticMessage(symbolAccesibilityResult) { - if (node.kind === 201 /* VariableDeclaration */) { - return symbolAccesibilityResult.errorModuleName ? - symbolAccesibilityResult.accessibility === 2 /* CannotBeNamed */ ? - ts.Diagnostics.Exported_variable_0_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named : - ts.Diagnostics.Exported_variable_0_has_or_is_using_name_1_from_private_module_2 : - ts.Diagnostics.Exported_variable_0_has_or_is_using_private_name_1; - } - else if (node.kind === 134 /* PropertyDeclaration */ || node.kind === 133 /* PropertySignature */) { - // TODO(jfreeman): Deal with computed properties in error reporting. - if (node.flags & 128 /* Static */) { - return symbolAccesibilityResult.errorModuleName ? - symbolAccesibilityResult.accessibility === 2 /* CannotBeNamed */ ? - ts.Diagnostics.Public_static_property_0_of_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named : - ts.Diagnostics.Public_static_property_0_of_exported_class_has_or_is_using_name_1_from_private_module_2 : - ts.Diagnostics.Public_static_property_0_of_exported_class_has_or_is_using_private_name_1; - } - else if (node.parent.kind === 204 /* ClassDeclaration */) { - return symbolAccesibilityResult.errorModuleName ? - symbolAccesibilityResult.accessibility === 2 /* CannotBeNamed */ ? - ts.Diagnostics.Public_property_0_of_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named : - ts.Diagnostics.Public_property_0_of_exported_class_has_or_is_using_name_1_from_private_module_2 : - ts.Diagnostics.Public_property_0_of_exported_class_has_or_is_using_private_name_1; - } - else { - // Interfaces cannot have types that cannot be named - return symbolAccesibilityResult.errorModuleName ? - ts.Diagnostics.Property_0_of_exported_interface_has_or_is_using_name_1_from_private_module_2 : - ts.Diagnostics.Property_0_of_exported_interface_has_or_is_using_private_name_1; - } - } - } - function getVariableDeclarationTypeVisibilityError(symbolAccesibilityResult) { - var diagnosticMessage = getVariableDeclarationTypeVisibilityDiagnosticMessage(symbolAccesibilityResult); - return diagnosticMessage !== undefined ? { - diagnosticMessage: diagnosticMessage, - errorNode: node, - typeName: node.name - } : undefined; - } - function emitBindingPattern(bindingPattern) { - // Only select non-omitted expression from the bindingPattern's elements. - // We have to do this to avoid emitting trailing commas. - // For example: - // original: var [, c,,] = [ 2,3,4] - // emitted: declare var c: number; // instead of declare var c:number, ; - var elements = []; - for (var _i = 0, _a = bindingPattern.elements; _i < _a.length; _i++) { - var element = _a[_i]; - if (element.kind !== 178 /* OmittedExpression */) { - elements.push(element); - } - } - emitCommaList(elements, emitBindingElement); - } - function emitBindingElement(bindingElement) { - function getBindingElementTypeVisibilityError(symbolAccesibilityResult) { - var diagnosticMessage = getVariableDeclarationTypeVisibilityDiagnosticMessage(symbolAccesibilityResult); - return diagnosticMessage !== undefined ? { - diagnosticMessage: diagnosticMessage, - errorNode: bindingElement, - typeName: bindingElement.name - } : undefined; - } - if (bindingElement.name) { - if (ts.isBindingPattern(bindingElement.name)) { - emitBindingPattern(bindingElement.name); - } - else { - writeTextOfNode(currentSourceFile, bindingElement.name); - writeTypeOfDeclaration(bindingElement, undefined, getBindingElementTypeVisibilityError); - } - } - } - } - function emitTypeOfVariableDeclarationFromTypeLiteral(node) { - // if this is property of type literal, - // or is parameter of method/call/construct/index signature of type literal - // emit only if type is specified - if (node.type) { - write(": "); - emitType(node.type); - } - } - function isVariableStatementVisible(node) { - return ts.forEach(node.declarationList.declarations, function (varDeclaration) { return resolver.isDeclarationVisible(varDeclaration); }); - } - function writeVariableStatement(node) { - emitJsDocComments(node); - emitModuleElementDeclarationFlags(node); - if (ts.isLet(node.declarationList)) { - write("let "); - } - else if (ts.isConst(node.declarationList)) { - write("const "); - } - else { - write("var "); - } - emitCommaList(node.declarationList.declarations, emitVariableDeclaration, resolver.isDeclarationVisible); - write(";"); - writeLine(); - } - function emitAccessorDeclaration(node) { - if (ts.hasDynamicName(node)) { - return; - } - var accessors = ts.getAllAccessorDeclarations(node.parent.members, node); - var accessorWithTypeAnnotation; - if (node === accessors.firstAccessor) { - emitJsDocComments(accessors.getAccessor); - emitJsDocComments(accessors.setAccessor); - emitClassMemberDeclarationFlags(node); - writeTextOfNode(currentSourceFile, node.name); - if (!(node.flags & 32 /* Private */)) { - accessorWithTypeAnnotation = node; - var type = getTypeAnnotationFromAccessor(node); - if (!type) { - // couldn't get type for the first accessor, try the another one - var anotherAccessor = node.kind === 138 /* GetAccessor */ ? accessors.setAccessor : accessors.getAccessor; - type = getTypeAnnotationFromAccessor(anotherAccessor); - if (type) { - accessorWithTypeAnnotation = anotherAccessor; - } - } - writeTypeOfDeclaration(node, type, getAccessorDeclarationTypeVisibilityError); - } - write(";"); - writeLine(); - } - function getTypeAnnotationFromAccessor(accessor) { - if (accessor) { - return accessor.kind === 138 /* GetAccessor */ - ? accessor.type // Getter - return type - : accessor.parameters.length > 0 - ? accessor.parameters[0].type // Setter parameter type - : undefined; - } - } - function getAccessorDeclarationTypeVisibilityError(symbolAccesibilityResult) { - var diagnosticMessage; - if (accessorWithTypeAnnotation.kind === 139 /* SetAccessor */) { - // Setters have to have type named and cannot infer it so, the type should always be named - if (accessorWithTypeAnnotation.parent.flags & 128 /* Static */) { - diagnosticMessage = symbolAccesibilityResult.errorModuleName ? - ts.Diagnostics.Parameter_0_of_public_static_property_setter_from_exported_class_has_or_is_using_name_1_from_private_module_2 : - ts.Diagnostics.Parameter_0_of_public_static_property_setter_from_exported_class_has_or_is_using_private_name_1; - } - else { - diagnosticMessage = symbolAccesibilityResult.errorModuleName ? - ts.Diagnostics.Parameter_0_of_public_property_setter_from_exported_class_has_or_is_using_name_1_from_private_module_2 : - ts.Diagnostics.Parameter_0_of_public_property_setter_from_exported_class_has_or_is_using_private_name_1; - } - return { - diagnosticMessage: diagnosticMessage, - errorNode: accessorWithTypeAnnotation.parameters[0], - // TODO(jfreeman): Investigate why we are passing node.name instead of node.parameters[0].name - typeName: accessorWithTypeAnnotation.name - }; - } - else { - if (accessorWithTypeAnnotation.flags & 128 /* Static */) { - diagnosticMessage = symbolAccesibilityResult.errorModuleName ? - symbolAccesibilityResult.accessibility === 2 /* CannotBeNamed */ ? - ts.Diagnostics.Return_type_of_public_static_property_getter_from_exported_class_has_or_is_using_name_0_from_external_module_1_but_cannot_be_named : - ts.Diagnostics.Return_type_of_public_static_property_getter_from_exported_class_has_or_is_using_name_0_from_private_module_1 : - ts.Diagnostics.Return_type_of_public_static_property_getter_from_exported_class_has_or_is_using_private_name_0; - } - else { - diagnosticMessage = symbolAccesibilityResult.errorModuleName ? - symbolAccesibilityResult.accessibility === 2 /* CannotBeNamed */ ? - ts.Diagnostics.Return_type_of_public_property_getter_from_exported_class_has_or_is_using_name_0_from_external_module_1_but_cannot_be_named : - ts.Diagnostics.Return_type_of_public_property_getter_from_exported_class_has_or_is_using_name_0_from_private_module_1 : - ts.Diagnostics.Return_type_of_public_property_getter_from_exported_class_has_or_is_using_private_name_0; - } - return { - diagnosticMessage: diagnosticMessage, - errorNode: accessorWithTypeAnnotation.name, - typeName: undefined - }; - } - } - } - function writeFunctionDeclaration(node) { - if (ts.hasDynamicName(node)) { - return; - } - // If we are emitting Method/Constructor it isn't moduleElement and hence already determined to be emitting - // so no need to verify if the declaration is visible - if (!resolver.isImplementationOfOverload(node)) { - emitJsDocComments(node); - if (node.kind === 203 /* FunctionDeclaration */) { - emitModuleElementDeclarationFlags(node); - } - else if (node.kind === 136 /* MethodDeclaration */) { - emitClassMemberDeclarationFlags(node); - } - if (node.kind === 203 /* FunctionDeclaration */) { - write("function "); - writeTextOfNode(currentSourceFile, node.name); - } - else if (node.kind === 137 /* Constructor */) { - write("constructor"); - } - else { - writeTextOfNode(currentSourceFile, node.name); - if (ts.hasQuestionToken(node)) { - write("?"); - } - } - emitSignatureDeclaration(node); - } - } - function emitSignatureDeclarationWithJsDocComments(node) { - emitJsDocComments(node); - emitSignatureDeclaration(node); - } - function emitSignatureDeclaration(node) { - // Construct signature or constructor type write new Signature - if (node.kind === 141 /* ConstructSignature */ || node.kind === 146 /* ConstructorType */) { - write("new "); - } - emitTypeParameters(node.typeParameters); - if (node.kind === 142 /* IndexSignature */) { - write("["); - } - else { - write("("); - } - var prevEnclosingDeclaration = enclosingDeclaration; - enclosingDeclaration = node; - // Parameters - emitCommaList(node.parameters, emitParameterDeclaration); - if (node.kind === 142 /* IndexSignature */) { - write("]"); - } - else { - write(")"); - } - // If this is not a constructor and is not private, emit the return type - var isFunctionTypeOrConstructorType = node.kind === 145 /* FunctionType */ || node.kind === 146 /* ConstructorType */; - if (isFunctionTypeOrConstructorType || node.parent.kind === 148 /* TypeLiteral */) { - // Emit type literal signature return type only if specified - if (node.type) { - write(isFunctionTypeOrConstructorType ? " => " : ": "); - emitType(node.type); - } - } - else if (node.kind !== 137 /* Constructor */ && !(node.flags & 32 /* Private */)) { - writeReturnTypeAtSignature(node, getReturnTypeVisibilityError); - } - enclosingDeclaration = prevEnclosingDeclaration; - if (!isFunctionTypeOrConstructorType) { - write(";"); - writeLine(); - } - function getReturnTypeVisibilityError(symbolAccesibilityResult) { - var diagnosticMessage; - switch (node.kind) { - case 141 /* ConstructSignature */: - // Interfaces cannot have return types that cannot be named - diagnosticMessage = symbolAccesibilityResult.errorModuleName ? - ts.Diagnostics.Return_type_of_constructor_signature_from_exported_interface_has_or_is_using_name_0_from_private_module_1 : - ts.Diagnostics.Return_type_of_constructor_signature_from_exported_interface_has_or_is_using_private_name_0; - break; - case 140 /* CallSignature */: - // Interfaces cannot have return types that cannot be named - diagnosticMessage = symbolAccesibilityResult.errorModuleName ? - ts.Diagnostics.Return_type_of_call_signature_from_exported_interface_has_or_is_using_name_0_from_private_module_1 : - ts.Diagnostics.Return_type_of_call_signature_from_exported_interface_has_or_is_using_private_name_0; - break; - case 142 /* IndexSignature */: - // Interfaces cannot have return types that cannot be named - diagnosticMessage = symbolAccesibilityResult.errorModuleName ? - ts.Diagnostics.Return_type_of_index_signature_from_exported_interface_has_or_is_using_name_0_from_private_module_1 : - ts.Diagnostics.Return_type_of_index_signature_from_exported_interface_has_or_is_using_private_name_0; - break; - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - if (node.flags & 128 /* Static */) { - diagnosticMessage = symbolAccesibilityResult.errorModuleName ? - symbolAccesibilityResult.accessibility === 2 /* CannotBeNamed */ ? - ts.Diagnostics.Return_type_of_public_static_method_from_exported_class_has_or_is_using_name_0_from_external_module_1_but_cannot_be_named : - ts.Diagnostics.Return_type_of_public_static_method_from_exported_class_has_or_is_using_name_0_from_private_module_1 : - ts.Diagnostics.Return_type_of_public_static_method_from_exported_class_has_or_is_using_private_name_0; - } - else if (node.parent.kind === 204 /* ClassDeclaration */) { - diagnosticMessage = symbolAccesibilityResult.errorModuleName ? - symbolAccesibilityResult.accessibility === 2 /* CannotBeNamed */ ? - ts.Diagnostics.Return_type_of_public_method_from_exported_class_has_or_is_using_name_0_from_external_module_1_but_cannot_be_named : - ts.Diagnostics.Return_type_of_public_method_from_exported_class_has_or_is_using_name_0_from_private_module_1 : - ts.Diagnostics.Return_type_of_public_method_from_exported_class_has_or_is_using_private_name_0; - } - else { - // Interfaces cannot have return types that cannot be named - diagnosticMessage = symbolAccesibilityResult.errorModuleName ? - ts.Diagnostics.Return_type_of_method_from_exported_interface_has_or_is_using_name_0_from_private_module_1 : - ts.Diagnostics.Return_type_of_method_from_exported_interface_has_or_is_using_private_name_0; - } - break; - case 203 /* FunctionDeclaration */: - diagnosticMessage = symbolAccesibilityResult.errorModuleName ? - symbolAccesibilityResult.accessibility === 2 /* CannotBeNamed */ ? - ts.Diagnostics.Return_type_of_exported_function_has_or_is_using_name_0_from_external_module_1_but_cannot_be_named : - ts.Diagnostics.Return_type_of_exported_function_has_or_is_using_name_0_from_private_module_1 : - ts.Diagnostics.Return_type_of_exported_function_has_or_is_using_private_name_0; - break; - default: - ts.Debug.fail("This is unknown kind for signature: " + node.kind); - } - return { - diagnosticMessage: diagnosticMessage, - errorNode: node.name || node - }; - } - } - function emitParameterDeclaration(node) { - increaseIndent(); - emitJsDocComments(node); - if (node.dotDotDotToken) { - write("..."); - } - if (ts.isBindingPattern(node.name)) { - // For bindingPattern, we can't simply writeTextOfNode from the source file - // because we want to omit the initializer and using writeTextOfNode will result in initializer get emitted. - // Therefore, we will have to recursively emit each element in the bindingPattern. - emitBindingPattern(node.name); - } - else { - writeTextOfNode(currentSourceFile, node.name); - } - if (node.initializer || ts.hasQuestionToken(node)) { - write("?"); - } - decreaseIndent(); - if (node.parent.kind === 145 /* FunctionType */ || - node.parent.kind === 146 /* ConstructorType */ || - node.parent.parent.kind === 148 /* TypeLiteral */) { - emitTypeOfVariableDeclarationFromTypeLiteral(node); - } - else if (!(node.parent.flags & 32 /* Private */)) { - writeTypeOfDeclaration(node, node.type, getParameterDeclarationTypeVisibilityError); - } - function getParameterDeclarationTypeVisibilityError(symbolAccesibilityResult) { - var diagnosticMessage = getParameterDeclarationTypeVisibilityDiagnosticMessage(symbolAccesibilityResult); - return diagnosticMessage !== undefined ? { - diagnosticMessage: diagnosticMessage, - errorNode: node, - typeName: node.name - } : undefined; - } - function getParameterDeclarationTypeVisibilityDiagnosticMessage(symbolAccesibilityResult) { - switch (node.parent.kind) { - case 137 /* Constructor */: - return symbolAccesibilityResult.errorModuleName ? - symbolAccesibilityResult.accessibility === 2 /* CannotBeNamed */ ? - ts.Diagnostics.Parameter_0_of_constructor_from_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named : - ts.Diagnostics.Parameter_0_of_constructor_from_exported_class_has_or_is_using_name_1_from_private_module_2 : - ts.Diagnostics.Parameter_0_of_constructor_from_exported_class_has_or_is_using_private_name_1; - case 141 /* ConstructSignature */: - // Interfaces cannot have parameter types that cannot be named - return symbolAccesibilityResult.errorModuleName ? - ts.Diagnostics.Parameter_0_of_constructor_signature_from_exported_interface_has_or_is_using_name_1_from_private_module_2 : - ts.Diagnostics.Parameter_0_of_constructor_signature_from_exported_interface_has_or_is_using_private_name_1; - case 140 /* CallSignature */: - // Interfaces cannot have parameter types that cannot be named - return symbolAccesibilityResult.errorModuleName ? - ts.Diagnostics.Parameter_0_of_call_signature_from_exported_interface_has_or_is_using_name_1_from_private_module_2 : - ts.Diagnostics.Parameter_0_of_call_signature_from_exported_interface_has_or_is_using_private_name_1; - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - if (node.parent.flags & 128 /* Static */) { - return symbolAccesibilityResult.errorModuleName ? - symbolAccesibilityResult.accessibility === 2 /* CannotBeNamed */ ? - ts.Diagnostics.Parameter_0_of_public_static_method_from_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named : - ts.Diagnostics.Parameter_0_of_public_static_method_from_exported_class_has_or_is_using_name_1_from_private_module_2 : - ts.Diagnostics.Parameter_0_of_public_static_method_from_exported_class_has_or_is_using_private_name_1; - } - else if (node.parent.parent.kind === 204 /* ClassDeclaration */) { - return symbolAccesibilityResult.errorModuleName ? - symbolAccesibilityResult.accessibility === 2 /* CannotBeNamed */ ? - ts.Diagnostics.Parameter_0_of_public_method_from_exported_class_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named : - ts.Diagnostics.Parameter_0_of_public_method_from_exported_class_has_or_is_using_name_1_from_private_module_2 : - ts.Diagnostics.Parameter_0_of_public_method_from_exported_class_has_or_is_using_private_name_1; - } - else { - // Interfaces cannot have parameter types that cannot be named - return symbolAccesibilityResult.errorModuleName ? - ts.Diagnostics.Parameter_0_of_method_from_exported_interface_has_or_is_using_name_1_from_private_module_2 : - ts.Diagnostics.Parameter_0_of_method_from_exported_interface_has_or_is_using_private_name_1; - } - case 203 /* FunctionDeclaration */: - return symbolAccesibilityResult.errorModuleName ? - symbolAccesibilityResult.accessibility === 2 /* CannotBeNamed */ ? - ts.Diagnostics.Parameter_0_of_exported_function_has_or_is_using_name_1_from_external_module_2_but_cannot_be_named : - ts.Diagnostics.Parameter_0_of_exported_function_has_or_is_using_name_1_from_private_module_2 : - ts.Diagnostics.Parameter_0_of_exported_function_has_or_is_using_private_name_1; - default: - ts.Debug.fail("This is unknown parent for parameter: " + node.parent.kind); - } - } - function emitBindingPattern(bindingPattern) { - // We have to explicitly emit square bracket and bracket because these tokens are not store inside the node. - if (bindingPattern.kind === 153 /* ObjectBindingPattern */) { - write("{"); - emitCommaList(bindingPattern.elements, emitBindingElement); - write("}"); - } - else if (bindingPattern.kind === 154 /* ArrayBindingPattern */) { - write("["); - var elements = bindingPattern.elements; - emitCommaList(elements, emitBindingElement); - if (elements && elements.hasTrailingComma) { - write(", "); - } - write("]"); - } - } - function emitBindingElement(bindingElement) { - function getBindingElementTypeVisibilityError(symbolAccesibilityResult) { - var diagnosticMessage = getParameterDeclarationTypeVisibilityDiagnosticMessage(symbolAccesibilityResult); - return diagnosticMessage !== undefined ? { - diagnosticMessage: diagnosticMessage, - errorNode: bindingElement, - typeName: bindingElement.name - } : undefined; - } - if (bindingElement.kind === 178 /* OmittedExpression */) { - // If bindingElement is an omittedExpression (i.e. containing elision), - // we will emit blank space (although this may differ from users' original code, - // it allows emitSeparatedList to write separator appropriately) - // Example: - // original: function foo([, x, ,]) {} - // emit : function foo([ , x, , ]) {} - write(" "); - } - else if (bindingElement.kind === 155 /* BindingElement */) { - if (bindingElement.propertyName) { - // bindingElement has propertyName property in the following case: - // { y: [a,b,c] ...} -> bindingPattern will have a property called propertyName for "y" - // We have to explicitly emit the propertyName before descending into its binding elements. - // Example: - // original: function foo({y: [a,b,c]}) {} - // emit : declare function foo({y: [a, b, c]}: { y: [any, any, any] }) void; - writeTextOfNode(currentSourceFile, bindingElement.propertyName); - write(": "); - // If bindingElement has propertyName property, then its name must be another bindingPattern of SyntaxKind.ObjectBindingPattern - emitBindingPattern(bindingElement.name); - } - else if (bindingElement.name) { - if (ts.isBindingPattern(bindingElement.name)) { - // If it is a nested binding pattern, we will recursively descend into each element and emit each one separately. - // In the case of rest element, we will omit rest element. - // Example: - // original: function foo([a, [[b]], c] = [1,[["string"]], 3]) {} - // emit : declare function foo([a, [[b]], c]: [number, [[string]], number]): void; - // original with rest: function foo([a, ...c]) {} - // emit : declare function foo([a, ...c]): void; - emitBindingPattern(bindingElement.name); - } - else { - ts.Debug.assert(bindingElement.name.kind === 65 /* Identifier */); - // If the node is just an identifier, we will simply emit the text associated with the node's name - // Example: - // original: function foo({y = 10, x}) {} - // emit : declare function foo({y, x}: {number, any}): void; - if (bindingElement.dotDotDotToken) { - write("..."); - } - writeTextOfNode(currentSourceFile, bindingElement.name); - } - } - } - } - } - function emitNode(node) { - switch (node.kind) { - case 203 /* FunctionDeclaration */: - case 208 /* ModuleDeclaration */: - case 211 /* ImportEqualsDeclaration */: - case 205 /* InterfaceDeclaration */: - case 204 /* ClassDeclaration */: - case 206 /* TypeAliasDeclaration */: - case 207 /* EnumDeclaration */: - return emitModuleElement(node, isModuleElementVisible(node)); - case 183 /* VariableStatement */: - return emitModuleElement(node, isVariableStatementVisible(node)); - case 212 /* ImportDeclaration */: - // Import declaration without import clause is visible, otherwise it is not visible - return emitModuleElement(node, !node.importClause); - case 218 /* ExportDeclaration */: - return emitExportDeclaration(node); - case 137 /* Constructor */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - return writeFunctionDeclaration(node); - case 141 /* ConstructSignature */: - case 140 /* CallSignature */: - case 142 /* IndexSignature */: - return emitSignatureDeclarationWithJsDocComments(node); - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - return emitAccessorDeclaration(node); - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - return emitPropertyDeclaration(node); - case 229 /* EnumMember */: - return emitEnumMemberDeclaration(node); - case 217 /* ExportAssignment */: - return emitExportAssignment(node); - case 230 /* SourceFile */: - return emitSourceFile(node); - } - } - function writeReferencePath(referencedFile) { - var declFileName = referencedFile.flags & 2048 /* DeclarationFile */ - ? referencedFile.fileName // Declaration file, use declaration file name - : ts.shouldEmitToOwnFile(referencedFile, compilerOptions) - ? ts.getOwnEmitOutputFilePath(referencedFile, host, ".d.ts") // Own output file so get the .d.ts file - : ts.removeFileExtension(compilerOptions.out) + ".d.ts"; // Global out file - declFileName = ts.getRelativePathToDirectoryOrUrl(ts.getDirectoryPath(ts.normalizeSlashes(jsFilePath)), declFileName, host.getCurrentDirectory(), host.getCanonicalFileName, - /*isAbsolutePathAnUrl*/ false); - referencePathsOutput += "/// " + newLine; - } - } - /* @internal */ - function writeDeclarationFile(jsFilePath, sourceFile, host, resolver, diagnostics) { - var emitDeclarationResult = emitDeclarations(host, resolver, diagnostics, jsFilePath, sourceFile); - // TODO(shkamat): Should we not write any declaration file if any of them can produce error, - // or should we just not write this file like we are doing now - if (!emitDeclarationResult.reportedDeclarationError) { - var declarationOutput = emitDeclarationResult.referencePathsOutput - + getDeclarationOutput(emitDeclarationResult.synchronousDeclarationOutput, emitDeclarationResult.moduleElementDeclarationEmitInfo); - ts.writeFile(host, diagnostics, ts.removeFileExtension(jsFilePath) + ".d.ts", declarationOutput, host.getCompilerOptions().emitBOM); - } - function getDeclarationOutput(synchronousDeclarationOutput, moduleElementDeclarationEmitInfo) { - var appliedSyncOutputPos = 0; - var declarationOutput = ""; - // apply asynchronous additions to the synchronous output - ts.forEach(moduleElementDeclarationEmitInfo, function (aliasEmitInfo) { - if (aliasEmitInfo.asynchronousOutput) { - declarationOutput += synchronousDeclarationOutput.substring(appliedSyncOutputPos, aliasEmitInfo.outputPos); - declarationOutput += getDeclarationOutput(aliasEmitInfo.asynchronousOutput, aliasEmitInfo.subModuleElementDeclarationEmitInfo); - appliedSyncOutputPos = aliasEmitInfo.outputPos; - } - }); - declarationOutput += synchronousDeclarationOutput.substring(appliedSyncOutputPos); - return declarationOutput; - } - } - ts.writeDeclarationFile = writeDeclarationFile; -})(ts || (ts = {})); -/// -/// -/* @internal */ -var ts; -(function (ts) { - function isExternalModuleOrDeclarationFile(sourceFile) { - return ts.isExternalModule(sourceFile) || ts.isDeclarationFile(sourceFile); - } - ts.isExternalModuleOrDeclarationFile = isExternalModuleOrDeclarationFile; - // Flags enum to track count of temp variables and a few dedicated names - var TempFlags; - (function (TempFlags) { - TempFlags[TempFlags["Auto"] = 0] = "Auto"; - TempFlags[TempFlags["CountMask"] = 268435455] = "CountMask"; - TempFlags[TempFlags["_i"] = 268435456] = "_i"; - })(TempFlags || (TempFlags = {})); - // targetSourceFile is when users only want one file in entire project to be emitted. This is used in compileOnSave feature - function emitFiles(resolver, host, targetSourceFile) { - // emit output for the __extends helper function - var extendsHelper = "\nvar __extends = (this && this.__extends) || function (d, b) {\n for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p];\n function __() { this.constructor = d; }\n __.prototype = b.prototype;\n d.prototype = new __();\n};"; - // emit output for the __decorate helper function - var decorateHelper = "\nvar __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") return Reflect.decorate(decorators, target, key, desc);\n switch (arguments.length) {\n case 2: return decorators.reduceRight(function(o, d) { return (d && d(o)) || o; }, target);\n case 3: return decorators.reduceRight(function(o, d) { return (d && d(target, key)), void 0; }, void 0);\n case 4: return decorators.reduceRight(function(o, d) { return (d && d(target, key, o)) || o; }, desc);\n }\n};"; - // emit output for the __metadata helper function - var metadataHelper = "\nvar __metadata = (this && this.__metadata) || function (k, v) {\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(k, v);\n};"; - // emit output for the __param helper function - var paramHelper = "\nvar __param = (this && this.__param) || function (paramIndex, decorator) {\n return function (target, key) { decorator(target, key, paramIndex); }\n};"; - var compilerOptions = host.getCompilerOptions(); - var languageVersion = compilerOptions.target || 0 /* ES3 */; - var sourceMapDataList = compilerOptions.sourceMap || compilerOptions.inlineSourceMap ? [] : undefined; - var diagnostics = []; - var newLine = host.getNewLine(); - if (targetSourceFile === undefined) { - ts.forEach(host.getSourceFiles(), function (sourceFile) { - if (ts.shouldEmitToOwnFile(sourceFile, compilerOptions)) { - var jsFilePath = ts.getOwnEmitOutputFilePath(sourceFile, host, ".js"); - emitFile(jsFilePath, sourceFile); - } - }); - if (compilerOptions.out) { - emitFile(compilerOptions.out); - } - } - else { - // targetSourceFile is specified (e.g calling emitter from language service or calling getSemanticDiagnostic from language service) - if (ts.shouldEmitToOwnFile(targetSourceFile, compilerOptions)) { - var jsFilePath = ts.getOwnEmitOutputFilePath(targetSourceFile, host, ".js"); - emitFile(jsFilePath, targetSourceFile); - } - else if (!ts.isDeclarationFile(targetSourceFile) && compilerOptions.out) { - emitFile(compilerOptions.out); - } - } - // Sort and make the unique list of diagnostics - diagnostics = ts.sortAndDeduplicateDiagnostics(diagnostics); - return { - emitSkipped: false, - diagnostics: diagnostics, - sourceMaps: sourceMapDataList - }; - function isNodeDescendentOf(node, ancestor) { - while (node) { - if (node === ancestor) - return true; - node = node.parent; - } - return false; - } - function isUniqueLocalName(name, container) { - for (var node = container; isNodeDescendentOf(node, container); node = node.nextContainer) { - if (node.locals && ts.hasProperty(node.locals, name)) { - // We conservatively include alias symbols to cover cases where they're emitted as locals - if (node.locals[name].flags & (107455 /* Value */ | 1048576 /* ExportValue */ | 8388608 /* Alias */)) { - return false; - } - } - } - return true; - } - function emitJavaScript(jsFilePath, root) { - var writer = ts.createTextWriter(newLine); - var write = writer.write; - var writeTextOfNode = writer.writeTextOfNode; - var writeLine = writer.writeLine; - var increaseIndent = writer.increaseIndent; - var decreaseIndent = writer.decreaseIndent; - var currentSourceFile; - // name of an exporter function if file is a System external module - // System.register([...], function () {...}) - // exporting in System modules looks like: - // export var x; ... x = 1 - // => - // var x;... exporter("x", x = 1) - var exportFunctionForFile; - var generatedNameSet = {}; - var nodeToGeneratedName = []; - var computedPropertyNamesToGeneratedNames; - var extendsEmitted = false; - var decorateEmitted = false; - var paramEmitted = false; - var tempFlags = 0; - var tempVariables; - var tempParameters; - var externalImports; - var exportSpecifiers; - var exportEquals; - var hasExportStars; - /** Write emitted output to disk */ - var writeEmittedFiles = writeJavaScriptFile; - var detachedCommentsInfo; - var writeComment = ts.writeCommentRange; - /** Emit a node */ - var emit = emitNodeWithoutSourceMap; - /** Called just before starting emit of a node */ - var emitStart = function (node) { }; - /** Called once the emit of the node is done */ - var emitEnd = function (node) { }; - /** Emit the text for the given token that comes after startPos - * This by default writes the text provided with the given tokenKind - * but if optional emitFn callback is provided the text is emitted using the callback instead of default text - * @param tokenKind the kind of the token to search and emit - * @param startPos the position in the source to start searching for the token - * @param emitFn if given will be invoked to emit the text instead of actual token emit */ - var emitToken = emitTokenText; - /** Called to before starting the lexical scopes as in function/class in the emitted code because of node - * @param scopeDeclaration node that starts the lexical scope - * @param scopeName Optional name of this scope instead of deducing one from the declaration node */ - var scopeEmitStart = function (scopeDeclaration, scopeName) { }; - /** Called after coming out of the scope */ - var scopeEmitEnd = function () { }; - /** Sourcemap data that will get encoded */ - var sourceMapData; - if (compilerOptions.sourceMap || compilerOptions.inlineSourceMap) { - initializeEmitterWithSourceMaps(); - } - if (root) { - // Do not call emit directly. It does not set the currentSourceFile. - emitSourceFile(root); - } - else { - ts.forEach(host.getSourceFiles(), function (sourceFile) { - if (!isExternalModuleOrDeclarationFile(sourceFile)) { - emitSourceFile(sourceFile); - } - }); - } - writeLine(); - writeEmittedFiles(writer.getText(), compilerOptions.emitBOM); - if (compilerOptions.dependency && root && compilerOptions.module) { - emitDependencyFile(root); - } - return; - function emitDependencyFile(sourceFile) { - var depFile = ts.removeFileExtension(jsFilePath) + '.dep.json'; - var runtime = []; - var compileTime = []; - for (var _a = 0, _b = root.amdDependencies; _a < _b.length; _a++) { - var node = _b[_a]; - runtime.push(node.path); - } - function processExternalDeclaration(node) { - var name = getExternalModuleNameText(node); - if (name) { - if (name.length >= 2) { - var first = name[0]; - var last = name[name.length - 1]; - if ((first == '"' || first == "'") && (last == '"' || last == "'")) { - name = name.substring(1, name.length - 1); - } - } - if (isExternalDepedency(node)) { - runtime.push(name); - } - else { - compileTime.push(name); - } - } - } - function isExternalDepedency(node) { - for (var _a = 0; _a < externalImports.length; _a++) { - var external_1 = externalImports[_a]; - if (node === external_1) { - return true; - } - } - return false; - } - for (var _c = 0, _d = root.statements; _c < _d.length; _c++) { - var node = _d[_c]; - var name_19; - switch (node.kind) { - case 212 /* ImportDeclaration */: - processExternalDeclaration(node); - break; - case 211 /* ImportEqualsDeclaration */: - processExternalDeclaration(node); - break; - case 218 /* ExportDeclaration */: - var exportDeclaration = node; - if (exportDeclaration.moduleSpecifier) { - processExternalDeclaration(node); - } - break; - } - } - var dep = { - filePath: root.fileName, - compileTime: compileTime, - runtime: runtime - }; - ts.writeFile(host, [], depFile, JSON.stringify(dep, null, 4), compilerOptions.emitBOM); - } - function emitSourceFile(sourceFile) { - currentSourceFile = sourceFile; - exportFunctionForFile = undefined; - emit(sourceFile); - } - function isUniqueName(name) { - return !resolver.hasGlobalName(name) && - !ts.hasProperty(currentSourceFile.identifiers, name) && - !ts.hasProperty(generatedNameSet, name); - } - // Return the next available name in the pattern _a ... _z, _0, _1, ... - // TempFlags._i or TempFlags._n may be used to express a preference for that dedicated name. - // Note that names generated by makeTempVariableName and makeUniqueName will never conflict. - function makeTempVariableName(flags) { - if (flags && !(tempFlags & flags)) { - var name = flags === 268435456 /* _i */ ? "_i" : "_n"; - if (isUniqueName(name)) { - tempFlags |= flags; - return name; - } - } - while (true) { - var count = tempFlags & 268435455 /* CountMask */; - tempFlags++; - // Skip over 'i' and 'n' - if (count !== 8 && count !== 13) { - var name_20 = count < 26 ? "_" + String.fromCharCode(97 /* a */ + count) : "_" + (count - 26); - if (isUniqueName(name_20)) { - return name_20; - } - } - } - } - // Generate a name that is unique within the current file and doesn't conflict with any names - // in global scope. The name is formed by adding an '_n' suffix to the specified base name, - // where n is a positive integer. Note that names generated by makeTempVariableName and - // makeUniqueName are guaranteed to never conflict. - function makeUniqueName(baseName) { - // Find the first unique 'name_n', where n is a positive number - if (baseName.charCodeAt(baseName.length - 1) !== 95 /* _ */) { - baseName += "_"; - } - var i = 1; - while (true) { - var generatedName = baseName + i; - if (isUniqueName(generatedName)) { - return generatedNameSet[generatedName] = generatedName; - } - i++; - } - } - function generateNameForModuleOrEnum(node) { - var name = node.name.text; - // Use module/enum name itself if it is unique, otherwise make a unique variation - return isUniqueLocalName(name, node) ? name : makeUniqueName(name); - } - function generateNameForImportOrExportDeclaration(node) { - var expr = ts.getExternalModuleName(node); - var baseName = expr.kind === 8 /* StringLiteral */ ? - ts.escapeIdentifier(ts.makeIdentifierFromModuleName(expr.text)) : "module"; - return makeUniqueName(baseName); - } - function generateNameForExportDefault() { - return makeUniqueName("default"); - } - function generateNameForNode(node) { - switch (node.kind) { - case 65 /* Identifier */: - return makeUniqueName(node.text); - case 208 /* ModuleDeclaration */: - case 207 /* EnumDeclaration */: - return generateNameForModuleOrEnum(node); - case 212 /* ImportDeclaration */: - case 218 /* ExportDeclaration */: - return generateNameForImportOrExportDeclaration(node); - case 203 /* FunctionDeclaration */: - case 204 /* ClassDeclaration */: - case 177 /* ClassExpression */: - case 217 /* ExportAssignment */: - return generateNameForExportDefault(); - } - } - function getGeneratedNameForNode(node) { - var id = ts.getNodeId(node); - return nodeToGeneratedName[id] || (nodeToGeneratedName[id] = ts.unescapeIdentifier(generateNameForNode(node))); - } - function initializeEmitterWithSourceMaps() { - var sourceMapDir; // The directory in which sourcemap will be - // Current source map file and its index in the sources list - var sourceMapSourceIndex = -1; - // Names and its index map - var sourceMapNameIndexMap = {}; - var sourceMapNameIndices = []; - function getSourceMapNameIndex() { - return sourceMapNameIndices.length ? ts.lastOrUndefined(sourceMapNameIndices) : -1; - } - // Last recorded and encoded spans - var lastRecordedSourceMapSpan; - var lastEncodedSourceMapSpan = { - emittedLine: 1, - emittedColumn: 1, - sourceLine: 1, - sourceColumn: 1, - sourceIndex: 0 - }; - var lastEncodedNameIndex = 0; - // Encoding for sourcemap span - function encodeLastRecordedSourceMapSpan() { - if (!lastRecordedSourceMapSpan || lastRecordedSourceMapSpan === lastEncodedSourceMapSpan) { - return; - } - var prevEncodedEmittedColumn = lastEncodedSourceMapSpan.emittedColumn; - // Line/Comma delimiters - if (lastEncodedSourceMapSpan.emittedLine == lastRecordedSourceMapSpan.emittedLine) { - // Emit comma to separate the entry - if (sourceMapData.sourceMapMappings) { - sourceMapData.sourceMapMappings += ","; - } - } - else { - // Emit line delimiters - for (var encodedLine = lastEncodedSourceMapSpan.emittedLine; encodedLine < lastRecordedSourceMapSpan.emittedLine; encodedLine++) { - sourceMapData.sourceMapMappings += ";"; - } - prevEncodedEmittedColumn = 1; - } - // 1. Relative Column 0 based - sourceMapData.sourceMapMappings += base64VLQFormatEncode(lastRecordedSourceMapSpan.emittedColumn - prevEncodedEmittedColumn); - // 2. Relative sourceIndex - sourceMapData.sourceMapMappings += base64VLQFormatEncode(lastRecordedSourceMapSpan.sourceIndex - lastEncodedSourceMapSpan.sourceIndex); - // 3. Relative sourceLine 0 based - sourceMapData.sourceMapMappings += base64VLQFormatEncode(lastRecordedSourceMapSpan.sourceLine - lastEncodedSourceMapSpan.sourceLine); - // 4. Relative sourceColumn 0 based - sourceMapData.sourceMapMappings += base64VLQFormatEncode(lastRecordedSourceMapSpan.sourceColumn - lastEncodedSourceMapSpan.sourceColumn); - // 5. Relative namePosition 0 based - if (lastRecordedSourceMapSpan.nameIndex >= 0) { - sourceMapData.sourceMapMappings += base64VLQFormatEncode(lastRecordedSourceMapSpan.nameIndex - lastEncodedNameIndex); - lastEncodedNameIndex = lastRecordedSourceMapSpan.nameIndex; - } - lastEncodedSourceMapSpan = lastRecordedSourceMapSpan; - sourceMapData.sourceMapDecodedMappings.push(lastEncodedSourceMapSpan); - function base64VLQFormatEncode(inValue) { - function base64FormatEncode(inValue) { - if (inValue < 64) { - return 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/'.charAt(inValue); - } - throw TypeError(inValue + ": not a 64 based value"); - } - // Add a new least significant bit that has the sign of the value. - // if negative number the least significant bit that gets added to the number has value 1 - // else least significant bit value that gets added is 0 - // eg. -1 changes to binary : 01 [1] => 3 - // +1 changes to binary : 01 [0] => 2 - if (inValue < 0) { - inValue = ((-inValue) << 1) + 1; - } - else { - inValue = inValue << 1; - } - // Encode 5 bits at a time starting from least significant bits - var encodedStr = ""; - do { - var currentDigit = inValue & 31; // 11111 - inValue = inValue >> 5; - if (inValue > 0) { - // There are still more digits to decode, set the msb (6th bit) - currentDigit = currentDigit | 32; - } - encodedStr = encodedStr + base64FormatEncode(currentDigit); - } while (inValue > 0); - return encodedStr; - } - } - function recordSourceMapSpan(pos) { - var sourceLinePos = ts.getLineAndCharacterOfPosition(currentSourceFile, pos); - // Convert the location to be one-based. - sourceLinePos.line++; - sourceLinePos.character++; - var emittedLine = writer.getLine(); - var emittedColumn = writer.getColumn(); - // If this location wasn't recorded or the location in source is going backwards, record the span - if (!lastRecordedSourceMapSpan || - lastRecordedSourceMapSpan.emittedLine != emittedLine || - lastRecordedSourceMapSpan.emittedColumn != emittedColumn || - (lastRecordedSourceMapSpan.sourceIndex === sourceMapSourceIndex && - (lastRecordedSourceMapSpan.sourceLine > sourceLinePos.line || - (lastRecordedSourceMapSpan.sourceLine === sourceLinePos.line && lastRecordedSourceMapSpan.sourceColumn > sourceLinePos.character)))) { - // Encode the last recordedSpan before assigning new - encodeLastRecordedSourceMapSpan(); - // New span - lastRecordedSourceMapSpan = { - emittedLine: emittedLine, - emittedColumn: emittedColumn, - sourceLine: sourceLinePos.line, - sourceColumn: sourceLinePos.character, - nameIndex: getSourceMapNameIndex(), - sourceIndex: sourceMapSourceIndex - }; - } - else { - // Take the new pos instead since there is no change in emittedLine and column since last location - lastRecordedSourceMapSpan.sourceLine = sourceLinePos.line; - lastRecordedSourceMapSpan.sourceColumn = sourceLinePos.character; - lastRecordedSourceMapSpan.sourceIndex = sourceMapSourceIndex; - } - } - function recordEmitNodeStartSpan(node) { - // Get the token pos after skipping to the token (ignoring the leading trivia) - recordSourceMapSpan(ts.skipTrivia(currentSourceFile.text, node.pos)); - } - function recordEmitNodeEndSpan(node) { - recordSourceMapSpan(node.end); - } - function writeTextWithSpanRecord(tokenKind, startPos, emitFn) { - var tokenStartPos = ts.skipTrivia(currentSourceFile.text, startPos); - recordSourceMapSpan(tokenStartPos); - var tokenEndPos = emitTokenText(tokenKind, tokenStartPos, emitFn); - recordSourceMapSpan(tokenEndPos); - return tokenEndPos; - } - function recordNewSourceFileStart(node) { - // Add the file to tsFilePaths - // If sourceroot option: Use the relative path corresponding to the common directory path - // otherwise source locations relative to map file location - var sourcesDirectoryPath = compilerOptions.sourceRoot ? host.getCommonSourceDirectory() : sourceMapDir; - sourceMapData.sourceMapSources.push(ts.getRelativePathToDirectoryOrUrl(sourcesDirectoryPath, node.fileName, host.getCurrentDirectory(), host.getCanonicalFileName, - /*isAbsolutePathAnUrl*/ true)); - sourceMapSourceIndex = sourceMapData.sourceMapSources.length - 1; - // The one that can be used from program to get the actual source file - sourceMapData.inputSourceFileNames.push(node.fileName); - if (compilerOptions.inlineSources) { - if (!sourceMapData.sourceMapSourcesContent) { - sourceMapData.sourceMapSourcesContent = []; - } - sourceMapData.sourceMapSourcesContent.push(node.text); - } - } - function recordScopeNameOfNode(node, scopeName) { - function recordScopeNameIndex(scopeNameIndex) { - sourceMapNameIndices.push(scopeNameIndex); - } - function recordScopeNameStart(scopeName) { - var scopeNameIndex = -1; - if (scopeName) { - var parentIndex = getSourceMapNameIndex(); - if (parentIndex !== -1) { - // Child scopes are always shown with a dot (even if they have no name), - // unless it is a computed property. Then it is shown with brackets, - // but the brackets are included in the name. - var name_21 = node.name; - if (!name_21 || name_21.kind !== 129 /* ComputedPropertyName */) { - scopeName = "." + scopeName; - } - scopeName = sourceMapData.sourceMapNames[parentIndex] + scopeName; - } - scopeNameIndex = ts.getProperty(sourceMapNameIndexMap, scopeName); - if (scopeNameIndex === undefined) { - scopeNameIndex = sourceMapData.sourceMapNames.length; - sourceMapData.sourceMapNames.push(scopeName); - sourceMapNameIndexMap[scopeName] = scopeNameIndex; - } - } - recordScopeNameIndex(scopeNameIndex); - } - if (scopeName) { - // The scope was already given a name use it - recordScopeNameStart(scopeName); - } - else if (node.kind === 203 /* FunctionDeclaration */ || - node.kind === 165 /* FunctionExpression */ || - node.kind === 136 /* MethodDeclaration */ || - node.kind === 135 /* MethodSignature */ || - node.kind === 138 /* GetAccessor */ || - node.kind === 139 /* SetAccessor */ || - node.kind === 208 /* ModuleDeclaration */ || - node.kind === 204 /* ClassDeclaration */ || - node.kind === 207 /* EnumDeclaration */) { - // Declaration and has associated name use it - if (node.name) { - var name_22 = node.name; - // For computed property names, the text will include the brackets - scopeName = name_22.kind === 129 /* ComputedPropertyName */ - ? ts.getTextOfNode(name_22) - : node.name.text; - } - recordScopeNameStart(scopeName); - } - else { - // Block just use the name from upper level scope - recordScopeNameIndex(getSourceMapNameIndex()); - } - } - function recordScopeNameEnd() { - sourceMapNameIndices.pop(); - } - ; - function writeCommentRangeWithMap(curentSourceFile, writer, comment, newLine) { - recordSourceMapSpan(comment.pos); - ts.writeCommentRange(currentSourceFile, writer, comment, newLine); - recordSourceMapSpan(comment.end); - } - function serializeSourceMapContents(version, file, sourceRoot, sources, names, mappings, sourcesContent) { - if (typeof JSON !== "undefined") { - var map_1 = { - version: version, - file: file, - sourceRoot: sourceRoot, - sources: sources, - names: names, - mappings: mappings - }; - if (sourcesContent !== undefined) { - map_1.sourcesContent = sourcesContent; - } - return JSON.stringify(map_1); - } - return "{\"version\":" + version + ",\"file\":\"" + ts.escapeString(file) + "\",\"sourceRoot\":\"" + ts.escapeString(sourceRoot) + "\",\"sources\":[" + serializeStringArray(sources) + "],\"names\":[" + serializeStringArray(names) + "],\"mappings\":\"" + ts.escapeString(mappings) + "\" " + (sourcesContent !== undefined ? ",\"sourcesContent\":[" + serializeStringArray(sourcesContent) + "]" : "") + "}"; - function serializeStringArray(list) { - var output = ""; - for (var i = 0, n = list.length; i < n; i++) { - if (i) { - output += ","; - } - output += "\"" + ts.escapeString(list[i]) + "\""; - } - return output; - } - } - function writeJavaScriptAndSourceMapFile(emitOutput, writeByteOrderMark) { - encodeLastRecordedSourceMapSpan(); - var sourceMapText = serializeSourceMapContents(3, sourceMapData.sourceMapFile, sourceMapData.sourceMapSourceRoot, sourceMapData.sourceMapSources, sourceMapData.sourceMapNames, sourceMapData.sourceMapMappings, sourceMapData.sourceMapSourcesContent); - sourceMapDataList.push(sourceMapData); - var sourceMapUrl; - if (compilerOptions.inlineSourceMap) { - // Encode the sourceMap into the sourceMap url - var base64SourceMapText = ts.convertToBase64(sourceMapText); - sourceMapUrl = "//# sourceMappingURL=data:application/json;base64," + base64SourceMapText; - } - else { - // Write source map file - ts.writeFile(host, diagnostics, sourceMapData.sourceMapFilePath, sourceMapText, false); - sourceMapUrl = "//# sourceMappingURL=" + sourceMapData.jsSourceMappingURL; - } - // Write sourcemap url to the js file and write the js file - writeJavaScriptFile(emitOutput + sourceMapUrl, writeByteOrderMark); - } - // Initialize source map data - var sourceMapJsFile = ts.getBaseFileName(ts.normalizeSlashes(jsFilePath)); - sourceMapData = { - sourceMapFilePath: jsFilePath + ".map", - jsSourceMappingURL: sourceMapJsFile + ".map", - sourceMapFile: sourceMapJsFile, - sourceMapSourceRoot: compilerOptions.sourceRoot || "", - sourceMapSources: [], - inputSourceFileNames: [], - sourceMapNames: [], - sourceMapMappings: "", - sourceMapSourcesContent: undefined, - sourceMapDecodedMappings: [] - }; - // Normalize source root and make sure it has trailing "/" so that it can be used to combine paths with the - // relative paths of the sources list in the sourcemap - sourceMapData.sourceMapSourceRoot = ts.normalizeSlashes(sourceMapData.sourceMapSourceRoot); - if (sourceMapData.sourceMapSourceRoot.length && sourceMapData.sourceMapSourceRoot.charCodeAt(sourceMapData.sourceMapSourceRoot.length - 1) !== 47 /* slash */) { - sourceMapData.sourceMapSourceRoot += ts.directorySeparator; - } - if (compilerOptions.mapRoot) { - sourceMapDir = ts.normalizeSlashes(compilerOptions.mapRoot); - if (root) { - // For modules or multiple emit files the mapRoot will have directory structure like the sources - // So if src\a.ts and src\lib\b.ts are compiled together user would be moving the maps into mapRoot\a.js.map and mapRoot\lib\b.js.map - sourceMapDir = ts.getDirectoryPath(ts.getSourceFilePathInNewDir(root, host, sourceMapDir)); - } - if (!ts.isRootedDiskPath(sourceMapDir) && !ts.isUrl(sourceMapDir)) { - // The relative paths are relative to the common directory - sourceMapDir = ts.combinePaths(host.getCommonSourceDirectory(), sourceMapDir); - sourceMapData.jsSourceMappingURL = ts.getRelativePathToDirectoryOrUrl(ts.getDirectoryPath(ts.normalizePath(jsFilePath)), ts.combinePaths(sourceMapDir, sourceMapData.jsSourceMappingURL), host.getCurrentDirectory(), host.getCanonicalFileName, - /*isAbsolutePathAnUrl*/ true); - } - else { - sourceMapData.jsSourceMappingURL = ts.combinePaths(sourceMapDir, sourceMapData.jsSourceMappingURL); - } - } - else { - sourceMapDir = ts.getDirectoryPath(ts.normalizePath(jsFilePath)); - } - function emitNodeWithSourceMap(node) { - if (node) { - if (ts.nodeIsSynthesized(node)) { - return emitNodeWithoutSourceMap(node); - } - if (node.kind != 230 /* SourceFile */) { - recordEmitNodeStartSpan(node); - emitNodeWithoutSourceMap(node); - recordEmitNodeEndSpan(node); - } - else { - recordNewSourceFileStart(node); - emitNodeWithoutSourceMap(node); - } - } - } - writeEmittedFiles = writeJavaScriptAndSourceMapFile; - emit = emitNodeWithSourceMap; - emitStart = recordEmitNodeStartSpan; - emitEnd = recordEmitNodeEndSpan; - emitToken = writeTextWithSpanRecord; - scopeEmitStart = recordScopeNameOfNode; - scopeEmitEnd = recordScopeNameEnd; - writeComment = writeCommentRangeWithMap; - } - function writeJavaScriptFile(emitOutput, writeByteOrderMark) { - ts.writeFile(host, diagnostics, jsFilePath, emitOutput, writeByteOrderMark); - } - // Create a temporary variable with a unique unused name. - function createTempVariable(flags) { - var result = ts.createSynthesizedNode(65 /* Identifier */); - result.text = makeTempVariableName(flags); - return result; - } - function recordTempDeclaration(name) { - if (!tempVariables) { - tempVariables = []; - } - tempVariables.push(name); - } - function createAndRecordTempVariable(flags) { - var temp = createTempVariable(flags); - recordTempDeclaration(temp); - return temp; - } - function emitTempDeclarations(newLine) { - if (tempVariables) { - if (newLine) { - writeLine(); - } - else { - write(" "); - } - write("var "); - emitCommaList(tempVariables); - write(";"); - } - } - function emitTokenText(tokenKind, startPos, emitFn) { - var tokenString = ts.tokenToString(tokenKind); - if (emitFn) { - emitFn(); - } - else { - write(tokenString); - } - return startPos + tokenString.length; - } - function emitOptional(prefix, node) { - if (node) { - write(prefix); - emit(node); - } - } - function emitParenthesizedIf(node, parenthesized) { - if (parenthesized) { - write("("); - } - emit(node); - if (parenthesized) { - write(")"); - } - } - function emitTrailingCommaIfPresent(nodeList) { - if (nodeList.hasTrailingComma) { - write(","); - } - } - function emitLinePreservingList(parent, nodes, allowTrailingComma, spacesBetweenBraces) { - ts.Debug.assert(nodes.length > 0); - increaseIndent(); - if (nodeStartPositionsAreOnSameLine(parent, nodes[0])) { - if (spacesBetweenBraces) { - write(" "); - } - } - else { - writeLine(); - } - for (var i = 0, n = nodes.length; i < n; i++) { - if (i) { - if (nodeEndIsOnSameLineAsNodeStart(nodes[i - 1], nodes[i])) { - write(", "); - } - else { - write(","); - writeLine(); - } - } - emit(nodes[i]); - } - if (nodes.hasTrailingComma && allowTrailingComma) { - write(","); - } - decreaseIndent(); - if (nodeEndPositionsAreOnSameLine(parent, ts.lastOrUndefined(nodes))) { - if (spacesBetweenBraces) { - write(" "); - } - } - else { - writeLine(); - } - } - function emitList(nodes, start, count, multiLine, trailingComma, leadingComma, noTrailingNewLine, emitNode) { - if (!emitNode) { - emitNode = emit; - } - for (var i = 0; i < count; i++) { - if (multiLine) { - if (i || leadingComma) { - write(","); - } - writeLine(); - } - else { - if (i || leadingComma) { - write(", "); - } - } - emitNode(nodes[start + i]); - leadingComma = true; - } - if (trailingComma) { - write(","); - } - if (multiLine && !noTrailingNewLine) { - writeLine(); - } - return count; - } - function emitCommaList(nodes) { - if (nodes) { - emitList(nodes, 0, nodes.length, false, false); - } - } - function emitLines(nodes) { - emitLinesStartingAt(nodes, 0); - } - function emitLinesStartingAt(nodes, startIndex) { - for (var i = startIndex; i < nodes.length; i++) { - writeLine(); - emit(nodes[i]); - } - } - function isBinaryOrOctalIntegerLiteral(node, text) { - if (node.kind === 7 /* NumericLiteral */ && text.length > 1) { - switch (text.charCodeAt(1)) { - case 98 /* b */: - case 66 /* B */: - case 111 /* o */: - case 79 /* O */: - return true; - } - } - return false; - } - function emitLiteral(node) { - var text = getLiteralText(node); - if ((compilerOptions.sourceMap || compilerOptions.inlineSourceMap) && (node.kind === 8 /* StringLiteral */ || ts.isTemplateLiteralKind(node.kind))) { - writer.writeLiteral(text); - } - else if (languageVersion < 2 /* ES6 */ && isBinaryOrOctalIntegerLiteral(node, text)) { - write(node.text); - } - else { - write(text); - } - } - function getLiteralText(node) { - // Any template literal or string literal with an extended escape - // (e.g. "\u{0067}") will need to be downleveled as a escaped string literal. - if (languageVersion < 2 /* ES6 */ && (ts.isTemplateLiteralKind(node.kind) || node.hasExtendedUnicodeEscape)) { - return getQuotedEscapedLiteralText('"', node.text, '"'); - } - // If we don't need to downlevel and we can reach the original source text using - // the node's parent reference, then simply get the text as it was originally written. - if (node.parent) { - return ts.getSourceTextOfNodeFromSourceFile(currentSourceFile, node); - } - // If we can't reach the original source text, use the canonical form if it's a number, - // or an escaped quoted form of the original text if it's string-like. - switch (node.kind) { - case 8 /* StringLiteral */: - return getQuotedEscapedLiteralText('"', node.text, '"'); - case 10 /* NoSubstitutionTemplateLiteral */: - return getQuotedEscapedLiteralText('`', node.text, '`'); - case 11 /* TemplateHead */: - return getQuotedEscapedLiteralText('`', node.text, '${'); - case 12 /* TemplateMiddle */: - return getQuotedEscapedLiteralText('}', node.text, '${'); - case 13 /* TemplateTail */: - return getQuotedEscapedLiteralText('}', node.text, '`'); - case 7 /* NumericLiteral */: - return node.text; - } - ts.Debug.fail("Literal kind '" + node.kind + "' not accounted for."); - } - function getQuotedEscapedLiteralText(leftQuote, text, rightQuote) { - return leftQuote + ts.escapeNonAsciiCharacters(ts.escapeString(text)) + rightQuote; - } - function emitDownlevelRawTemplateLiteral(node) { - // Find original source text, since we need to emit the raw strings of the tagged template. - // The raw strings contain the (escaped) strings of what the user wrote. - // Examples: `\n` is converted to "\\n", a template string with a newline to "\n". - var text = ts.getSourceTextOfNodeFromSourceFile(currentSourceFile, node); - // text contains the original source, it will also contain quotes ("`"), dolar signs and braces ("${" and "}"), - // thus we need to remove those characters. - // First template piece starts with "`", others with "}" - // Last template piece ends with "`", others with "${" - var isLast = node.kind === 10 /* NoSubstitutionTemplateLiteral */ || node.kind === 13 /* TemplateTail */; - text = text.substring(1, text.length - (isLast ? 1 : 2)); - // Newline normalization: - // ES6 Spec 11.8.6.1 - Static Semantics of TV's and TRV's - // and LineTerminatorSequences are normalized to for both TV and TRV. - text = text.replace(/\r\n?/g, "\n"); - text = ts.escapeString(text); - write('"' + text + '"'); - } - function emitDownlevelTaggedTemplateArray(node, literalEmitter) { - write("["); - if (node.template.kind === 10 /* NoSubstitutionTemplateLiteral */) { - literalEmitter(node.template); - } - else { - literalEmitter(node.template.head); - ts.forEach(node.template.templateSpans, function (child) { - write(", "); - literalEmitter(child.literal); - }); - } - write("]"); - } - function emitDownlevelTaggedTemplate(node) { - var tempVariable = createAndRecordTempVariable(0 /* Auto */); - write("("); - emit(tempVariable); - write(" = "); - emitDownlevelTaggedTemplateArray(node, emit); - write(", "); - emit(tempVariable); - write(".raw = "); - emitDownlevelTaggedTemplateArray(node, emitDownlevelRawTemplateLiteral); - write(", "); - emitParenthesizedIf(node.tag, needsParenthesisForPropertyAccessOrInvocation(node.tag)); - write("("); - emit(tempVariable); - // Now we emit the expressions - if (node.template.kind === 174 /* TemplateExpression */) { - ts.forEach(node.template.templateSpans, function (templateSpan) { - write(", "); - var needsParens = templateSpan.expression.kind === 172 /* BinaryExpression */ - && templateSpan.expression.operatorToken.kind === 23 /* CommaToken */; - emitParenthesizedIf(templateSpan.expression, needsParens); - }); - } - write("))"); - } - function emitTemplateExpression(node) { - // In ES6 mode and above, we can simply emit each portion of a template in order, but in - // ES3 & ES5 we must convert the template expression into a series of string concatenations. - if (languageVersion >= 2 /* ES6 */) { - ts.forEachChild(node, emit); - return; - } - var emitOuterParens = ts.isExpression(node.parent) - && templateNeedsParens(node, node.parent); - if (emitOuterParens) { - write("("); - } - var headEmitted = false; - if (shouldEmitTemplateHead()) { - emitLiteral(node.head); - headEmitted = true; - } - for (var i = 0, n = node.templateSpans.length; i < n; i++) { - var templateSpan = node.templateSpans[i]; - // Check if the expression has operands and binds its operands less closely than binary '+'. - // If it does, we need to wrap the expression in parentheses. Otherwise, something like - // `abc${ 1 << 2 }` - // becomes - // "abc" + 1 << 2 + "" - // which is really - // ("abc" + 1) << (2 + "") - // rather than - // "abc" + (1 << 2) + "" - var needsParens = templateSpan.expression.kind !== 164 /* ParenthesizedExpression */ - && comparePrecedenceToBinaryPlus(templateSpan.expression) !== 1 /* GreaterThan */; - if (i > 0 || headEmitted) { - // If this is the first span and the head was not emitted, then this templateSpan's - // expression will be the first to be emitted. Don't emit the preceding ' + ' in that - // case. - write(" + "); - } - emitParenthesizedIf(templateSpan.expression, needsParens); - // Only emit if the literal is non-empty. - // The binary '+' operator is left-associative, so the first string concatenation - // with the head will force the result up to this point to be a string. - // Emitting a '+ ""' has no semantic effect for middles and tails. - if (templateSpan.literal.text.length !== 0) { - write(" + "); - emitLiteral(templateSpan.literal); - } - } - if (emitOuterParens) { - write(")"); - } - function shouldEmitTemplateHead() { - // If this expression has an empty head literal and the first template span has a non-empty - // literal, then emitting the empty head literal is not necessary. - // `${ foo } and ${ bar }` - // can be emitted as - // foo + " and " + bar - // This is because it is only required that one of the first two operands in the emit - // output must be a string literal, so that the other operand and all following operands - // are forced into strings. - // - // If the first template span has an empty literal, then the head must still be emitted. - // `${ foo }${ bar }` - // must still be emitted as - // "" + foo + bar - // There is always atleast one templateSpan in this code path, since - // NoSubstitutionTemplateLiterals are directly emitted via emitLiteral() - ts.Debug.assert(node.templateSpans.length !== 0); - return node.head.text.length !== 0 || node.templateSpans[0].literal.text.length === 0; - } - function templateNeedsParens(template, parent) { - switch (parent.kind) { - case 160 /* CallExpression */: - case 161 /* NewExpression */: - return parent.expression === template; - case 162 /* TaggedTemplateExpression */: - case 164 /* ParenthesizedExpression */: - return false; - default: - return comparePrecedenceToBinaryPlus(parent) !== -1 /* LessThan */; - } - } - /** - * Returns whether the expression has lesser, greater, - * or equal precedence to the binary '+' operator - */ - function comparePrecedenceToBinaryPlus(expression) { - // All binary expressions have lower precedence than '+' apart from '*', '/', and '%' - // which have greater precedence and '-' which has equal precedence. - // All unary operators have a higher precedence apart from yield. - // Arrow functions and conditionals have a lower precedence, - // although we convert the former into regular function expressions in ES5 mode, - // and in ES6 mode this function won't get called anyway. - // - // TODO (drosen): Note that we need to account for the upcoming 'yield' and - // spread ('...') unary operators that are anticipated for ES6. - switch (expression.kind) { - case 172 /* BinaryExpression */: - switch (expression.operatorToken.kind) { - case 35 /* AsteriskToken */: - case 36 /* SlashToken */: - case 37 /* PercentToken */: - return 1 /* GreaterThan */; - case 33 /* PlusToken */: - case 34 /* MinusToken */: - return 0 /* EqualTo */; - default: - return -1 /* LessThan */; - } - case 175 /* YieldExpression */: - case 173 /* ConditionalExpression */: - return -1 /* LessThan */; - default: - return 1 /* GreaterThan */; - } - } - } - function emitTemplateSpan(span) { - emit(span.expression); - emit(span.literal); - } - // This function specifically handles numeric/string literals for enum and accessor 'identifiers'. - // In a sense, it does not actually emit identifiers as much as it declares a name for a specific property. - // For example, this is utilized when feeding in a result to Object.defineProperty. - function emitExpressionForPropertyName(node) { - ts.Debug.assert(node.kind !== 155 /* BindingElement */); - if (node.kind === 8 /* StringLiteral */) { - emitLiteral(node); - } - else if (node.kind === 129 /* ComputedPropertyName */) { - // if this is a decorated computed property, we will need to capture the result - // of the property expression so that we can apply decorators later. This is to ensure - // we don't introduce unintended side effects: - // - // class C { - // [_a = x]() { } - // } - // - // The emit for the decorated computed property decorator is: - // - // Object.defineProperty(C.prototype, _a, __decorate([dec], C.prototype, _a, Object.getOwnPropertyDescriptor(C.prototype, _a))); - // - if (ts.nodeIsDecorated(node.parent)) { - if (!computedPropertyNamesToGeneratedNames) { - computedPropertyNamesToGeneratedNames = []; - } - var generatedName = computedPropertyNamesToGeneratedNames[ts.getNodeId(node)]; - if (generatedName) { - // we have already generated a variable for this node, write that value instead. - write(generatedName); - return; - } - generatedName = createAndRecordTempVariable(0 /* Auto */).text; - computedPropertyNamesToGeneratedNames[ts.getNodeId(node)] = generatedName; - write(generatedName); - write(" = "); - } - emit(node.expression); - } - else { - write("\""); - if (node.kind === 7 /* NumericLiteral */) { - write(node.text); - } - else { - writeTextOfNode(currentSourceFile, node); - } - write("\""); - } - } - function isExpressionIdentifier(node) { - var parent = node.parent; - switch (parent.kind) { - case 156 /* ArrayLiteralExpression */: - case 172 /* BinaryExpression */: - case 160 /* CallExpression */: - case 223 /* CaseClause */: - case 129 /* ComputedPropertyName */: - case 173 /* ConditionalExpression */: - case 132 /* Decorator */: - case 167 /* DeleteExpression */: - case 187 /* DoStatement */: - case 159 /* ElementAccessExpression */: - case 217 /* ExportAssignment */: - case 185 /* ExpressionStatement */: - case 179 /* ExpressionWithTypeArguments */: - case 189 /* ForStatement */: - case 190 /* ForInStatement */: - case 191 /* ForOfStatement */: - case 186 /* IfStatement */: - case 161 /* NewExpression */: - case 164 /* ParenthesizedExpression */: - case 171 /* PostfixUnaryExpression */: - case 170 /* PrefixUnaryExpression */: - case 194 /* ReturnStatement */: - case 228 /* ShorthandPropertyAssignment */: - case 176 /* SpreadElementExpression */: - case 196 /* SwitchStatement */: - case 162 /* TaggedTemplateExpression */: - case 180 /* TemplateSpan */: - case 198 /* ThrowStatement */: - case 163 /* TypeAssertionExpression */: - case 168 /* TypeOfExpression */: - case 169 /* VoidExpression */: - case 188 /* WhileStatement */: - case 195 /* WithStatement */: - case 175 /* YieldExpression */: - return true; - case 155 /* BindingElement */: - case 229 /* EnumMember */: - case 131 /* Parameter */: - case 227 /* PropertyAssignment */: - case 134 /* PropertyDeclaration */: - case 201 /* VariableDeclaration */: - return parent.initializer === node; - case 158 /* PropertyAccessExpression */: - return parent.expression === node; - case 166 /* ArrowFunction */: - case 165 /* FunctionExpression */: - return parent.body === node; - case 211 /* ImportEqualsDeclaration */: - return parent.moduleReference === node; - case 128 /* QualifiedName */: - return parent.left === node; - } - return false; - } - function emitExpressionIdentifier(node) { - var container = resolver.getReferencedExportContainer(node); - if (container) { - if (container.kind === 230 /* SourceFile */) { - // Identifier references module export - if (languageVersion < 2 /* ES6 */ && compilerOptions.module !== 4 /* System */) { - write("exports."); - } - } - else { - // Identifier references namespace export - write(getGeneratedNameForNode(container)); - write("."); - } - } - else if (languageVersion < 2 /* ES6 */) { - var declaration = resolver.getReferencedImportDeclaration(node); - if (declaration) { - if (declaration.kind === 213 /* ImportClause */) { - // Identifier references default import - write(getGeneratedNameForNode(declaration.parent)); - write(languageVersion === 0 /* ES3 */ ? '["default"]' : ".default"); - return; - } - else if (declaration.kind === 216 /* ImportSpecifier */) { - // Identifier references named import - write(getGeneratedNameForNode(declaration.parent.parent.parent)); - write("."); - writeTextOfNode(currentSourceFile, declaration.propertyName || declaration.name); - return; - } - } - declaration = resolver.getReferencedNestedRedeclaration(node); - if (declaration) { - write(getGeneratedNameForNode(declaration.name)); - return; - } - } - writeTextOfNode(currentSourceFile, node); - } - function isNameOfNestedRedeclaration(node) { - if (languageVersion < 2 /* ES6 */) { - var parent_7 = node.parent; - switch (parent_7.kind) { - case 155 /* BindingElement */: - case 204 /* ClassDeclaration */: - case 207 /* EnumDeclaration */: - case 201 /* VariableDeclaration */: - return parent_7.name === node && resolver.isNestedRedeclaration(parent_7); - } - } - return false; - } - function emitIdentifier(node) { - if (!node.parent) { - write(node.text); - } - else if (isExpressionIdentifier(node)) { - emitExpressionIdentifier(node); - } - else if (isNameOfNestedRedeclaration(node)) { - write(getGeneratedNameForNode(node)); - } - else { - writeTextOfNode(currentSourceFile, node); - } - } - function emitThis(node) { - if (resolver.getNodeCheckFlags(node) & 2 /* LexicalThis */) { - write("_this"); - } - else { - write("this"); - } - } - function emitSuper(node) { - if (languageVersion >= 2 /* ES6 */) { - write("super"); - } - else { - var flags = resolver.getNodeCheckFlags(node); - if (flags & 16 /* SuperInstance */) { - write("_super.prototype"); - } - else { - write("_super"); - } - } - } - function emitObjectBindingPattern(node) { - write("{ "); - var elements = node.elements; - emitList(elements, 0, elements.length, false, elements.hasTrailingComma); - write(" }"); - } - function emitArrayBindingPattern(node) { - write("["); - var elements = node.elements; - emitList(elements, 0, elements.length, false, elements.hasTrailingComma); - write("]"); - } - function emitBindingElement(node) { - if (node.propertyName) { - emit(node.propertyName); - write(": "); - } - if (node.dotDotDotToken) { - write("..."); - } - if (ts.isBindingPattern(node.name)) { - emit(node.name); - } - else { - emitModuleMemberName(node); - } - emitOptional(" = ", node.initializer); - } - function emitSpreadElementExpression(node) { - write("..."); - emit(node.expression); - } - function emitYieldExpression(node) { - write(ts.tokenToString(110 /* YieldKeyword */)); - if (node.asteriskToken) { - write("*"); - } - if (node.expression) { - write(" "); - emit(node.expression); - } - } - function needsParenthesisForPropertyAccessOrInvocation(node) { - switch (node.kind) { - case 65 /* Identifier */: - case 156 /* ArrayLiteralExpression */: - case 158 /* PropertyAccessExpression */: - case 159 /* ElementAccessExpression */: - case 160 /* CallExpression */: - case 164 /* ParenthesizedExpression */: - // This list is not exhaustive and only includes those cases that are relevant - // to the check in emitArrayLiteral. More cases can be added as needed. - return false; - } - return true; - } - function emitListWithSpread(elements, needsUniqueCopy, multiLine, trailingComma, useConcat) { - var pos = 0; - var group = 0; - var length = elements.length; - while (pos < length) { - // Emit using the pattern .concat(, , ...) - if (group === 1 && useConcat) { - write(".concat("); - } - else if (group > 0) { - write(", "); - } - var e = elements[pos]; - if (e.kind === 176 /* SpreadElementExpression */) { - e = e.expression; - emitParenthesizedIf(e, group === 0 && needsParenthesisForPropertyAccessOrInvocation(e)); - pos++; - if (pos === length && group === 0 && needsUniqueCopy && e.kind !== 156 /* ArrayLiteralExpression */) { - write(".slice()"); - } - } - else { - var i = pos; - while (i < length && elements[i].kind !== 176 /* SpreadElementExpression */) { - i++; - } - write("["); - if (multiLine) { - increaseIndent(); - } - emitList(elements, pos, i - pos, multiLine, trailingComma && i === length); - if (multiLine) { - decreaseIndent(); - } - write("]"); - pos = i; - } - group++; - } - if (group > 1) { - if (useConcat) { - write(")"); - } - } - } - function isSpreadElementExpression(node) { - return node.kind === 176 /* SpreadElementExpression */; - } - function emitArrayLiteral(node) { - var elements = node.elements; - if (elements.length === 0) { - write("[]"); - } - else if (languageVersion >= 2 /* ES6 */ || !ts.forEach(elements, isSpreadElementExpression)) { - write("["); - emitLinePreservingList(node, node.elements, elements.hasTrailingComma, false); - write("]"); - } - else { - emitListWithSpread(elements, true, (node.flags & 512 /* MultiLine */) !== 0, - /*trailingComma*/ elements.hasTrailingComma, true); - } - } - function emitObjectLiteralBody(node, numElements) { - if (numElements === 0) { - write("{}"); - return; - } - write("{"); - if (numElements > 0) { - var properties = node.properties; - // If we are not doing a downlevel transformation for object literals, - // then try to preserve the original shape of the object literal. - // Otherwise just try to preserve the formatting. - if (numElements === properties.length) { - emitLinePreservingList(node, properties, languageVersion >= 1 /* ES5 */, true); - } - else { - var multiLine = (node.flags & 512 /* MultiLine */) !== 0; - if (!multiLine) { - write(" "); - } - else { - increaseIndent(); - } - emitList(properties, 0, numElements, multiLine, false); - if (!multiLine) { - write(" "); - } - else { - decreaseIndent(); - } - } - } - write("}"); - } - function emitDownlevelObjectLiteralWithComputedProperties(node, firstComputedPropertyIndex) { - var multiLine = (node.flags & 512 /* MultiLine */) !== 0; - var properties = node.properties; - write("("); - if (multiLine) { - increaseIndent(); - } - // For computed properties, we need to create a unique handle to the object - // literal so we can modify it without risking internal assignments tainting the object. - var tempVar = createAndRecordTempVariable(0 /* Auto */); - // Write out the first non-computed properties - // (or all properties if none of them are computed), - // then emit the rest through indexing on the temp variable. - emit(tempVar); - write(" = "); - emitObjectLiteralBody(node, firstComputedPropertyIndex); - for (var i = firstComputedPropertyIndex, n = properties.length; i < n; i++) { - writeComma(); - var property = properties[i]; - emitStart(property); - if (property.kind === 138 /* GetAccessor */ || property.kind === 139 /* SetAccessor */) { - // TODO (drosen): Reconcile with 'emitMemberFunctions'. - var accessors = ts.getAllAccessorDeclarations(node.properties, property); - if (property !== accessors.firstAccessor) { - continue; - } - write("Object.defineProperty("); - emit(tempVar); - write(", "); - emitStart(node.name); - emitExpressionForPropertyName(property.name); - emitEnd(property.name); - write(", {"); - increaseIndent(); - if (accessors.getAccessor) { - writeLine(); - emitLeadingComments(accessors.getAccessor); - write("get: "); - emitStart(accessors.getAccessor); - write("function "); - emitSignatureAndBody(accessors.getAccessor); - emitEnd(accessors.getAccessor); - emitTrailingComments(accessors.getAccessor); - write(","); - } - if (accessors.setAccessor) { - writeLine(); - emitLeadingComments(accessors.setAccessor); - write("set: "); - emitStart(accessors.setAccessor); - write("function "); - emitSignatureAndBody(accessors.setAccessor); - emitEnd(accessors.setAccessor); - emitTrailingComments(accessors.setAccessor); - write(","); - } - writeLine(); - write("enumerable: true,"); - writeLine(); - write("configurable: true"); - decreaseIndent(); - writeLine(); - write("})"); - emitEnd(property); - } - else { - emitLeadingComments(property); - emitStart(property.name); - emit(tempVar); - emitMemberAccessForPropertyName(property.name); - emitEnd(property.name); - write(" = "); - if (property.kind === 227 /* PropertyAssignment */) { - emit(property.initializer); - } - else if (property.kind === 228 /* ShorthandPropertyAssignment */) { - emitExpressionIdentifier(property.name); - } - else if (property.kind === 136 /* MethodDeclaration */) { - emitFunctionDeclaration(property); - } - else { - ts.Debug.fail("ObjectLiteralElement type not accounted for: " + property.kind); - } - } - emitEnd(property); - } - writeComma(); - emit(tempVar); - if (multiLine) { - decreaseIndent(); - writeLine(); - } - write(")"); - function writeComma() { - if (multiLine) { - write(","); - writeLine(); - } - else { - write(", "); - } - } - } - function emitObjectLiteral(node) { - var properties = node.properties; - if (languageVersion < 2 /* ES6 */) { - var numProperties = properties.length; - // Find the first computed property. - // Everything until that point can be emitted as part of the initial object literal. - var numInitialNonComputedProperties = numProperties; - for (var i = 0, n = properties.length; i < n; i++) { - if (properties[i].name.kind === 129 /* ComputedPropertyName */) { - numInitialNonComputedProperties = i; - break; - } - } - var hasComputedProperty = numInitialNonComputedProperties !== properties.length; - if (hasComputedProperty) { - emitDownlevelObjectLiteralWithComputedProperties(node, numInitialNonComputedProperties); - return; - } - } - // Ordinary case: either the object has no computed properties - // or we're compiling with an ES6+ target. - emitObjectLiteralBody(node, properties.length); - } - function createBinaryExpression(left, operator, right, startsOnNewLine) { - var result = ts.createSynthesizedNode(172 /* BinaryExpression */, startsOnNewLine); - result.operatorToken = ts.createSynthesizedNode(operator); - result.left = left; - result.right = right; - return result; - } - function createPropertyAccessExpression(expression, name) { - var result = ts.createSynthesizedNode(158 /* PropertyAccessExpression */); - result.expression = parenthesizeForAccess(expression); - result.dotToken = ts.createSynthesizedNode(20 /* DotToken */); - result.name = name; - return result; - } - function createElementAccessExpression(expression, argumentExpression) { - var result = ts.createSynthesizedNode(159 /* ElementAccessExpression */); - result.expression = parenthesizeForAccess(expression); - result.argumentExpression = argumentExpression; - return result; - } - function parenthesizeForAccess(expr) { - // When diagnosing whether the expression needs parentheses, the decision should be based - // on the innermost expression in a chain of nested type assertions. - while (expr.kind === 163 /* TypeAssertionExpression */) { - expr = expr.expression; - } - // isLeftHandSideExpression is almost the correct criterion for when it is not necessary - // to parenthesize the expression before a dot. The known exceptions are: - // - // NewExpression: - // new C.x -> not the same as (new C).x - // NumberLiteral - // 1.x -> not the same as (1).x - // - if (ts.isLeftHandSideExpression(expr) && - expr.kind !== 161 /* NewExpression */ && - expr.kind !== 7 /* NumericLiteral */) { - return expr; - } - var node = ts.createSynthesizedNode(164 /* ParenthesizedExpression */); - node.expression = expr; - return node; - } - function emitComputedPropertyName(node) { - write("["); - emitExpressionForPropertyName(node); - write("]"); - } - function emitMethod(node) { - if (languageVersion >= 2 /* ES6 */ && node.asteriskToken) { - write("*"); - } - emit(node.name); - if (languageVersion < 2 /* ES6 */) { - write(": function "); - } - emitSignatureAndBody(node); - } - function emitPropertyAssignment(node) { - emit(node.name); - write(": "); - emit(node.initializer); - } - // Return true if identifier resolves to an exported member of a namespace - function isNamespaceExportReference(node) { - var container = resolver.getReferencedExportContainer(node); - return container && container.kind !== 230 /* SourceFile */; - } - function emitShorthandPropertyAssignment(node) { - // The name property of a short-hand property assignment is considered an expression position, so here - // we manually emit the identifier to avoid rewriting. - writeTextOfNode(currentSourceFile, node.name); - // If emitting pre-ES6 code, or if the name requires rewriting when resolved as an expression identifier, - // we emit a normal property assignment. For example: - // module m { - // export let y; - // } - // module m { - // let obj = { y }; - // } - // Here we need to emit obj = { y : m.y } regardless of the output target. - if (languageVersion < 2 /* ES6 */ || isNamespaceExportReference(node.name)) { - // Emit identifier as an identifier - write(": "); - emit(node.name); - } - } - function tryEmitConstantValue(node) { - if (compilerOptions.isolatedModules) { - // do not inline enum values in separate compilation mode - return false; - } - var constantValue = resolver.getConstantValue(node); - if (constantValue !== undefined) { - write(constantValue.toString()); - if (!compilerOptions.removeComments) { - var propertyName = node.kind === 158 /* PropertyAccessExpression */ ? ts.declarationNameToString(node.name) : ts.getTextOfNode(node.argumentExpression); - write(" /* " + propertyName + " */"); - } - return true; - } - return false; - } - // Returns 'true' if the code was actually indented, false otherwise. - // If the code is not indented, an optional valueToWriteWhenNotIndenting will be - // emitted instead. - function indentIfOnDifferentLines(parent, node1, node2, valueToWriteWhenNotIndenting) { - var realNodesAreOnDifferentLines = !ts.nodeIsSynthesized(parent) && !nodeEndIsOnSameLineAsNodeStart(node1, node2); - // Always use a newline for synthesized code if the synthesizer desires it. - var synthesizedNodeIsOnDifferentLine = synthesizedNodeStartsOnNewLine(node2); - if (realNodesAreOnDifferentLines || synthesizedNodeIsOnDifferentLine) { - increaseIndent(); - writeLine(); - return true; - } - else { - if (valueToWriteWhenNotIndenting) { - write(valueToWriteWhenNotIndenting); - } - return false; - } - } - function emitPropertyAccess(node) { - if (tryEmitConstantValue(node)) { - return; - } - emit(node.expression); - var indentedBeforeDot = indentIfOnDifferentLines(node, node.expression, node.dotToken); - write("."); - var indentedAfterDot = indentIfOnDifferentLines(node, node.dotToken, node.name); - emit(node.name); - decreaseIndentIf(indentedBeforeDot, indentedAfterDot); - } - function emitQualifiedName(node) { - emit(node.left); - write("."); - emit(node.right); - } - function emitIndexedAccess(node) { - if (tryEmitConstantValue(node)) { - return; - } - emit(node.expression); - write("["); - emit(node.argumentExpression); - write("]"); - } - function hasSpreadElement(elements) { - return ts.forEach(elements, function (e) { return e.kind === 176 /* SpreadElementExpression */; }); - } - function skipParentheses(node) { - while (node.kind === 164 /* ParenthesizedExpression */ || node.kind === 163 /* TypeAssertionExpression */) { - node = node.expression; - } - return node; - } - function emitCallTarget(node) { - if (node.kind === 65 /* Identifier */ || node.kind === 93 /* ThisKeyword */ || node.kind === 91 /* SuperKeyword */) { - emit(node); - return node; - } - var temp = createAndRecordTempVariable(0 /* Auto */); - write("("); - emit(temp); - write(" = "); - emit(node); - write(")"); - return temp; - } - function emitCallWithSpread(node) { - var target; - var expr = skipParentheses(node.expression); - if (expr.kind === 158 /* PropertyAccessExpression */) { - // Target will be emitted as "this" argument - target = emitCallTarget(expr.expression); - write("."); - emit(expr.name); - } - else if (expr.kind === 159 /* ElementAccessExpression */) { - // Target will be emitted as "this" argument - target = emitCallTarget(expr.expression); - write("["); - emit(expr.argumentExpression); - write("]"); - } - else if (expr.kind === 91 /* SuperKeyword */) { - target = expr; - write("_super"); - } - else { - emit(node.expression); - } - write(".apply("); - if (target) { - if (target.kind === 91 /* SuperKeyword */) { - // Calls of form super(...) and super.foo(...) - emitThis(target); - } - else { - // Calls of form obj.foo(...) - emit(target); - } - } - else { - // Calls of form foo(...) - write("void 0"); - } - write(", "); - emitListWithSpread(node.arguments, false, false, false, true); - write(")"); - } - function emitCallExpression(node) { - if (languageVersion < 2 /* ES6 */ && hasSpreadElement(node.arguments)) { - emitCallWithSpread(node); - return; - } - var superCall = false; - if (node.expression.kind === 91 /* SuperKeyword */) { - emitSuper(node.expression); - superCall = true; - } - else { - emit(node.expression); - superCall = node.expression.kind === 158 /* PropertyAccessExpression */ && node.expression.expression.kind === 91 /* SuperKeyword */; - } - if (superCall && languageVersion < 2 /* ES6 */) { - write(".call("); - emitThis(node.expression); - if (node.arguments.length) { - write(", "); - emitCommaList(node.arguments); - } - write(")"); - } - else { - write("("); - emitCommaList(node.arguments); - write(")"); - } - } - function emitNewExpression(node) { - write("new "); - // Spread operator logic is supported in new expressions in ES5 using a combination - // of Function.prototype.bind() and Function.prototype.apply(). - // - // Example: - // - // var args = [1, 2, 3, 4, 5]; - // new Array(...args); - // - // is compiled into the following ES5: - // - // var args = [1, 2, 3, 4, 5]; - // new (Array.bind.apply(Array, [void 0].concat(args))); - // - // The 'thisArg' to 'bind' is ignored when invoking the result of 'bind' with 'new', - // Thus, we set it to undefined ('void 0'). - if (languageVersion === 1 /* ES5 */ && - node.arguments && - hasSpreadElement(node.arguments)) { - write("("); - var target = emitCallTarget(node.expression); - write(".bind.apply("); - emit(target); - write(", [void 0].concat("); - emitListWithSpread(node.arguments, false, false, false, false); - write(")))"); - write("()"); - } - else { - emit(node.expression); - if (node.arguments) { - write("("); - emitCommaList(node.arguments); - write(")"); - } - } - } - function emitTaggedTemplateExpression(node) { - if (languageVersion >= 2 /* ES6 */) { - emit(node.tag); - write(" "); - emit(node.template); - } - else { - emitDownlevelTaggedTemplate(node); - } - } - function emitParenExpression(node) { - // If the node is synthesized, it means the emitter put the parentheses there, - // not the user. If we didn't want them, the emitter would not have put them - // there. - if (!ts.nodeIsSynthesized(node) && node.parent.kind !== 166 /* ArrowFunction */) { - if (node.expression.kind === 163 /* TypeAssertionExpression */) { - var operand = node.expression.expression; - // Make sure we consider all nested cast expressions, e.g.: - // (-A).x; - while (operand.kind == 163 /* TypeAssertionExpression */) { - operand = operand.expression; - } - // We have an expression of the form: (SubExpr) - // Emitting this as (SubExpr) is really not desirable. We would like to emit the subexpr as is. - // Omitting the parentheses, however, could cause change in the semantics of the generated - // code if the casted expression has a lower precedence than the rest of the expression, e.g.: - // (new A).foo should be emitted as (new A).foo and not new A.foo - // (typeof A).toString() should be emitted as (typeof A).toString() and not typeof A.toString() - // new (A()) should be emitted as new (A()) and not new A() - // (function foo() { })() should be emitted as an IIF (function foo(){})() and not declaration function foo(){} () - if (operand.kind !== 170 /* PrefixUnaryExpression */ && - operand.kind !== 169 /* VoidExpression */ && - operand.kind !== 168 /* TypeOfExpression */ && - operand.kind !== 167 /* DeleteExpression */ && - operand.kind !== 171 /* PostfixUnaryExpression */ && - operand.kind !== 161 /* NewExpression */ && - !(operand.kind === 160 /* CallExpression */ && node.parent.kind === 161 /* NewExpression */) && - !(operand.kind === 165 /* FunctionExpression */ && node.parent.kind === 160 /* CallExpression */)) { - emit(operand); - return; - } - } - } - write("("); - emit(node.expression); - write(")"); - } - function emitDeleteExpression(node) { - write(ts.tokenToString(74 /* DeleteKeyword */)); - write(" "); - emit(node.expression); - } - function emitVoidExpression(node) { - write(ts.tokenToString(99 /* VoidKeyword */)); - write(" "); - emit(node.expression); - } - function emitTypeOfExpression(node) { - write(ts.tokenToString(97 /* TypeOfKeyword */)); - write(" "); - emit(node.expression); - } - function isNameOfExportedSourceLevelDeclarationInSystemExternalModule(node) { - if (!isCurrentFileSystemExternalModule() || node.kind !== 65 /* Identifier */ || ts.nodeIsSynthesized(node)) { - return false; - } - var isVariableDeclarationOrBindingElement = node.parent && (node.parent.kind === 201 /* VariableDeclaration */ || node.parent.kind === 155 /* BindingElement */); - var targetDeclaration = isVariableDeclarationOrBindingElement - ? node.parent - : resolver.getReferencedValueDeclaration(node); - return isSourceFileLevelDeclarationInSystemJsModule(targetDeclaration, true); - } - function emitPrefixUnaryExpression(node) { - var exportChanged = isNameOfExportedSourceLevelDeclarationInSystemExternalModule(node.operand); - if (exportChanged) { - // emit - // ++x - // as - // exports('x', ++x) - write(exportFunctionForFile + "(\""); - emitNodeWithoutSourceMap(node.operand); - write("\", "); - } - write(ts.tokenToString(node.operator)); - // In some cases, we need to emit a space between the operator and the operand. One obvious case - // is when the operator is an identifier, like delete or typeof. We also need to do this for plus - // and minus expressions in certain cases. Specifically, consider the following two cases (parens - // are just for clarity of exposition, and not part of the source code): - // - // (+(+1)) - // (+(++1)) - // - // We need to emit a space in both cases. In the first case, the absence of a space will make - // the resulting expression a prefix increment operation. And in the second, it will make the resulting - // expression a prefix increment whose operand is a plus expression - (++(+x)) - // The same is true of minus of course. - if (node.operand.kind === 170 /* PrefixUnaryExpression */) { - var operand = node.operand; - if (node.operator === 33 /* PlusToken */ && (operand.operator === 33 /* PlusToken */ || operand.operator === 38 /* PlusPlusToken */)) { - write(" "); - } - else if (node.operator === 34 /* MinusToken */ && (operand.operator === 34 /* MinusToken */ || operand.operator === 39 /* MinusMinusToken */)) { - write(" "); - } - } - emit(node.operand); - if (exportChanged) { - write(")"); - } - } - function emitPostfixUnaryExpression(node) { - var exportChanged = isNameOfExportedSourceLevelDeclarationInSystemExternalModule(node.operand); - if (exportChanged) { - // export function returns the value that was passes as the second argument - // however for postfix unary expressions result value should be the value before modification. - // emit 'x++' as '(export('x', ++x) - 1)' and 'x--' as '(export('x', --x) + 1)' - write("(" + exportFunctionForFile + "(\""); - emitNodeWithoutSourceMap(node.operand); - write("\", "); - write(ts.tokenToString(node.operator)); - emit(node.operand); - if (node.operator === 38 /* PlusPlusToken */) { - write(") - 1)"); - } - else { - write(") + 1)"); - } - } - else { - emit(node.operand); - write(ts.tokenToString(node.operator)); - } - } - function shouldHoistDeclarationInSystemJsModule(node) { - return isSourceFileLevelDeclarationInSystemJsModule(node, false); - } - /* - * Checks if given node is a source file level declaration (not nested in module/function). - * If 'isExported' is true - then declaration must also be exported. - * This function is used in two cases: - * - check if node is a exported source file level value to determine - * if we should also export the value after its it changed - * - check if node is a source level declaration to emit it differently, - * i.e non-exported variable statement 'var x = 1' is hoisted so - * we we emit variable statement 'var' should be dropped. - */ - function isSourceFileLevelDeclarationInSystemJsModule(node, isExported) { - if (!node || languageVersion >= 2 /* ES6 */ || !isCurrentFileSystemExternalModule()) { - return false; - } - var current = node; - while (current) { - if (current.kind === 230 /* SourceFile */) { - return !isExported || ((ts.getCombinedNodeFlags(node) & 1 /* Export */) !== 0); - } - else if (ts.isFunctionLike(current) || current.kind === 209 /* ModuleBlock */) { - return false; - } - else { - current = current.parent; - } - } - } - function emitBinaryExpression(node) { - if (languageVersion < 2 /* ES6 */ && node.operatorToken.kind === 53 /* EqualsToken */ && - (node.left.kind === 157 /* ObjectLiteralExpression */ || node.left.kind === 156 /* ArrayLiteralExpression */)) { - emitDestructuring(node, node.parent.kind === 185 /* ExpressionStatement */); - } - else { - var exportChanged = node.operatorToken.kind >= 53 /* FirstAssignment */ && - node.operatorToken.kind <= 64 /* LastAssignment */ && - isNameOfExportedSourceLevelDeclarationInSystemExternalModule(node.left); - if (exportChanged) { - // emit assignment 'x y' as 'exports("x", x y)' - write(exportFunctionForFile + "(\""); - emitNodeWithoutSourceMap(node.left); - write("\", "); - } - emit(node.left); - var indentedBeforeOperator = indentIfOnDifferentLines(node, node.left, node.operatorToken, node.operatorToken.kind !== 23 /* CommaToken */ ? " " : undefined); - write(ts.tokenToString(node.operatorToken.kind)); - var indentedAfterOperator = indentIfOnDifferentLines(node, node.operatorToken, node.right, " "); - emit(node.right); - decreaseIndentIf(indentedBeforeOperator, indentedAfterOperator); - if (exportChanged) { - write(")"); - } - } - } - function synthesizedNodeStartsOnNewLine(node) { - return ts.nodeIsSynthesized(node) && node.startsOnNewLine; - } - function emitConditionalExpression(node) { - emit(node.condition); - var indentedBeforeQuestion = indentIfOnDifferentLines(node, node.condition, node.questionToken, " "); - write("?"); - var indentedAfterQuestion = indentIfOnDifferentLines(node, node.questionToken, node.whenTrue, " "); - emit(node.whenTrue); - decreaseIndentIf(indentedBeforeQuestion, indentedAfterQuestion); - var indentedBeforeColon = indentIfOnDifferentLines(node, node.whenTrue, node.colonToken, " "); - write(":"); - var indentedAfterColon = indentIfOnDifferentLines(node, node.colonToken, node.whenFalse, " "); - emit(node.whenFalse); - decreaseIndentIf(indentedBeforeColon, indentedAfterColon); - } - // Helper function to decrease the indent if we previously indented. Allows multiple - // previous indent values to be considered at a time. This also allows caller to just - // call this once, passing in all their appropriate indent values, instead of needing - // to call this helper function multiple times. - function decreaseIndentIf(value1, value2) { - if (value1) { - decreaseIndent(); - } - if (value2) { - decreaseIndent(); - } - } - function isSingleLineEmptyBlock(node) { - if (node && node.kind === 182 /* Block */) { - var block = node; - return block.statements.length === 0 && nodeEndIsOnSameLineAsNodeStart(block, block); - } - } - function emitBlock(node) { - if (isSingleLineEmptyBlock(node)) { - emitToken(14 /* OpenBraceToken */, node.pos); - write(" "); - emitToken(15 /* CloseBraceToken */, node.statements.end); - return; - } - emitToken(14 /* OpenBraceToken */, node.pos); - increaseIndent(); - scopeEmitStart(node.parent); - if (node.kind === 209 /* ModuleBlock */) { - ts.Debug.assert(node.parent.kind === 208 /* ModuleDeclaration */); - emitCaptureThisForNodeIfNecessary(node.parent); - } - emitLines(node.statements); - if (node.kind === 209 /* ModuleBlock */) { - emitTempDeclarations(true); - } - decreaseIndent(); - writeLine(); - emitToken(15 /* CloseBraceToken */, node.statements.end); - scopeEmitEnd(); - } - function emitEmbeddedStatement(node) { - if (node.kind === 182 /* Block */) { - write(" "); - emit(node); - } - else { - increaseIndent(); - writeLine(); - emit(node); - decreaseIndent(); - } - } - function emitExpressionStatement(node) { - emitParenthesizedIf(node.expression, node.expression.kind === 166 /* ArrowFunction */); - write(";"); - } - function emitIfStatement(node) { - var endPos = emitToken(84 /* IfKeyword */, node.pos); - write(" "); - endPos = emitToken(16 /* OpenParenToken */, endPos); - emit(node.expression); - emitToken(17 /* CloseParenToken */, node.expression.end); - emitEmbeddedStatement(node.thenStatement); - if (node.elseStatement) { - writeLine(); - emitToken(76 /* ElseKeyword */, node.thenStatement.end); - if (node.elseStatement.kind === 186 /* IfStatement */) { - write(" "); - emit(node.elseStatement); - } - else { - emitEmbeddedStatement(node.elseStatement); - } - } - } - function emitDoStatement(node) { - write("do"); - emitEmbeddedStatement(node.statement); - if (node.statement.kind === 182 /* Block */) { - write(" "); - } - else { - writeLine(); - } - write("while ("); - emit(node.expression); - write(");"); - } - function emitWhileStatement(node) { - write("while ("); - emit(node.expression); - write(")"); - emitEmbeddedStatement(node.statement); - } - /** - * Returns true if start of variable declaration list was emitted. - * Returns false if nothing was written - this can happen for source file level variable declarations - * in system modules where such variable declarations are hoisted. - */ - function tryEmitStartOfVariableDeclarationList(decl, startPos) { - if (shouldHoistVariable(decl, true)) { - // variables in variable declaration list were already hoisted - return false; - } - var tokenKind = 98 /* VarKeyword */; - if (decl && languageVersion >= 2 /* ES6 */) { - if (ts.isLet(decl)) { - tokenKind = 104 /* LetKeyword */; - } - else if (ts.isConst(decl)) { - tokenKind = 70 /* ConstKeyword */; - } - } - if (startPos !== undefined) { - emitToken(tokenKind, startPos); - write(" "); - } - else { - switch (tokenKind) { - case 98 /* VarKeyword */: - write("var "); - break; - case 104 /* LetKeyword */: - write("let "); - break; - case 70 /* ConstKeyword */: - write("const "); - break; - } - } - return true; - } - function emitVariableDeclarationListSkippingUninitializedEntries(list) { - var started = false; - for (var _a = 0, _b = list.declarations; _a < _b.length; _a++) { - var decl = _b[_a]; - if (!decl.initializer) { - continue; - } - if (!started) { - started = true; - } - else { - write(", "); - } - emit(decl); - } - return started; - } - function emitForStatement(node) { - var endPos = emitToken(82 /* ForKeyword */, node.pos); - write(" "); - endPos = emitToken(16 /* OpenParenToken */, endPos); - if (node.initializer && node.initializer.kind === 202 /* VariableDeclarationList */) { - var variableDeclarationList = node.initializer; - var startIsEmitted = tryEmitStartOfVariableDeclarationList(variableDeclarationList, endPos); - if (startIsEmitted) { - emitCommaList(variableDeclarationList.declarations); - } - else { - emitVariableDeclarationListSkippingUninitializedEntries(variableDeclarationList); - } - } - else if (node.initializer) { - emit(node.initializer); - } - write(";"); - emitOptional(" ", node.condition); - write(";"); - emitOptional(" ", node.incrementor); - write(")"); - emitEmbeddedStatement(node.statement); - } - function emitForInOrForOfStatement(node) { - if (languageVersion < 2 /* ES6 */ && node.kind === 191 /* ForOfStatement */) { - return emitDownLevelForOfStatement(node); - } - var endPos = emitToken(82 /* ForKeyword */, node.pos); - write(" "); - endPos = emitToken(16 /* OpenParenToken */, endPos); - if (node.initializer.kind === 202 /* VariableDeclarationList */) { - var variableDeclarationList = node.initializer; - if (variableDeclarationList.declarations.length >= 1) { - tryEmitStartOfVariableDeclarationList(variableDeclarationList, endPos); - emit(variableDeclarationList.declarations[0]); - } - } - else { - emit(node.initializer); - } - if (node.kind === 190 /* ForInStatement */) { - write(" in "); - } - else { - write(" of "); - } - emit(node.expression); - emitToken(17 /* CloseParenToken */, node.expression.end); - emitEmbeddedStatement(node.statement); - } - function emitDownLevelForOfStatement(node) { - // The following ES6 code: - // - // for (let v of expr) { } - // - // should be emitted as - // - // for (let _i = 0, _a = expr; _i < _a.length; _i++) { - // let v = _a[_i]; - // } - // - // where _a and _i are temps emitted to capture the RHS and the counter, - // respectively. - // When the left hand side is an expression instead of a let declaration, - // the "let v" is not emitted. - // When the left hand side is a let/const, the v is renamed if there is - // another v in scope. - // Note that all assignments to the LHS are emitted in the body, including - // all destructuring. - // Note also that because an extra statement is needed to assign to the LHS, - // for-of bodies are always emitted as blocks. - var endPos = emitToken(82 /* ForKeyword */, node.pos); - write(" "); - endPos = emitToken(16 /* OpenParenToken */, endPos); - // Do not emit the LHS let declaration yet, because it might contain destructuring. - // Do not call recordTempDeclaration because we are declaring the temps - // right here. Recording means they will be declared later. - // In the case where the user wrote an identifier as the RHS, like this: - // - // for (let v of arr) { } - // - // we don't want to emit a temporary variable for the RHS, just use it directly. - var rhsIsIdentifier = node.expression.kind === 65 /* Identifier */; - var counter = createTempVariable(268435456 /* _i */); - var rhsReference = rhsIsIdentifier ? node.expression : createTempVariable(0 /* Auto */); - // This is the let keyword for the counter and rhsReference. The let keyword for - // the LHS will be emitted inside the body. - emitStart(node.expression); - write("var "); - // _i = 0 - emitNodeWithoutSourceMap(counter); - write(" = 0"); - emitEnd(node.expression); - if (!rhsIsIdentifier) { - // , _a = expr - write(", "); - emitStart(node.expression); - emitNodeWithoutSourceMap(rhsReference); - write(" = "); - emitNodeWithoutSourceMap(node.expression); - emitEnd(node.expression); - } - write("; "); - // _i < _a.length; - emitStart(node.initializer); - emitNodeWithoutSourceMap(counter); - write(" < "); - emitNodeWithoutSourceMap(rhsReference); - write(".length"); - emitEnd(node.initializer); - write("; "); - // _i++) - emitStart(node.initializer); - emitNodeWithoutSourceMap(counter); - write("++"); - emitEnd(node.initializer); - emitToken(17 /* CloseParenToken */, node.expression.end); - // Body - write(" {"); - writeLine(); - increaseIndent(); - // Initialize LHS - // let v = _a[_i]; - var rhsIterationValue = createElementAccessExpression(rhsReference, counter); - emitStart(node.initializer); - if (node.initializer.kind === 202 /* VariableDeclarationList */) { - write("var "); - var variableDeclarationList = node.initializer; - if (variableDeclarationList.declarations.length > 0) { - var declaration = variableDeclarationList.declarations[0]; - if (ts.isBindingPattern(declaration.name)) { - // This works whether the declaration is a var, let, or const. - // It will use rhsIterationValue _a[_i] as the initializer. - emitDestructuring(declaration, false, rhsIterationValue); - } - else { - // The following call does not include the initializer, so we have - // to emit it separately. - emitNodeWithoutSourceMap(declaration); - write(" = "); - emitNodeWithoutSourceMap(rhsIterationValue); - } - } - else { - // It's an empty declaration list. This can only happen in an error case, if the user wrote - // for (let of []) {} - emitNodeWithoutSourceMap(createTempVariable(0 /* Auto */)); - write(" = "); - emitNodeWithoutSourceMap(rhsIterationValue); - } - } - else { - // Initializer is an expression. Emit the expression in the body, so that it's - // evaluated on every iteration. - var assignmentExpression = createBinaryExpression(node.initializer, 53 /* EqualsToken */, rhsIterationValue, false); - if (node.initializer.kind === 156 /* ArrayLiteralExpression */ || node.initializer.kind === 157 /* ObjectLiteralExpression */) { - // This is a destructuring pattern, so call emitDestructuring instead of emit. Calling emit will not work, because it will cause - // the BinaryExpression to be passed in instead of the expression statement, which will cause emitDestructuring to crash. - emitDestructuring(assignmentExpression, true, undefined); - } - else { - emitNodeWithoutSourceMap(assignmentExpression); - } - } - emitEnd(node.initializer); - write(";"); - if (node.statement.kind === 182 /* Block */) { - emitLines(node.statement.statements); - } - else { - writeLine(); - emit(node.statement); - } - writeLine(); - decreaseIndent(); - write("}"); - } - function emitBreakOrContinueStatement(node) { - emitToken(node.kind === 193 /* BreakStatement */ ? 66 /* BreakKeyword */ : 71 /* ContinueKeyword */, node.pos); - emitOptional(" ", node.label); - write(";"); - } - function emitReturnStatement(node) { - emitToken(90 /* ReturnKeyword */, node.pos); - emitOptional(" ", node.expression); - write(";"); - } - function emitWithStatement(node) { - write("with ("); - emit(node.expression); - write(")"); - emitEmbeddedStatement(node.statement); - } - function emitSwitchStatement(node) { - var endPos = emitToken(92 /* SwitchKeyword */, node.pos); - write(" "); - emitToken(16 /* OpenParenToken */, endPos); - emit(node.expression); - endPos = emitToken(17 /* CloseParenToken */, node.expression.end); - write(" "); - emitCaseBlock(node.caseBlock, endPos); - } - function emitCaseBlock(node, startPos) { - emitToken(14 /* OpenBraceToken */, startPos); - increaseIndent(); - emitLines(node.clauses); - decreaseIndent(); - writeLine(); - emitToken(15 /* CloseBraceToken */, node.clauses.end); - } - function nodeStartPositionsAreOnSameLine(node1, node2) { - return ts.getLineOfLocalPosition(currentSourceFile, ts.skipTrivia(currentSourceFile.text, node1.pos)) === - ts.getLineOfLocalPosition(currentSourceFile, ts.skipTrivia(currentSourceFile.text, node2.pos)); - } - function nodeEndPositionsAreOnSameLine(node1, node2) { - return ts.getLineOfLocalPosition(currentSourceFile, node1.end) === - ts.getLineOfLocalPosition(currentSourceFile, node2.end); - } - function nodeEndIsOnSameLineAsNodeStart(node1, node2) { - return ts.getLineOfLocalPosition(currentSourceFile, node1.end) === - ts.getLineOfLocalPosition(currentSourceFile, ts.skipTrivia(currentSourceFile.text, node2.pos)); - } - function emitCaseOrDefaultClause(node) { - if (node.kind === 223 /* CaseClause */) { - write("case "); - emit(node.expression); - write(":"); - } - else { - write("default:"); - } - if (node.statements.length === 1 && nodeStartPositionsAreOnSameLine(node, node.statements[0])) { - write(" "); - emit(node.statements[0]); - } - else { - increaseIndent(); - emitLines(node.statements); - decreaseIndent(); - } - } - function emitThrowStatement(node) { - write("throw "); - emit(node.expression); - write(";"); - } - function emitTryStatement(node) { - write("try "); - emit(node.tryBlock); - emit(node.catchClause); - if (node.finallyBlock) { - writeLine(); - write("finally "); - emit(node.finallyBlock); - } - } - function emitCatchClause(node) { - writeLine(); - var endPos = emitToken(68 /* CatchKeyword */, node.pos); - write(" "); - emitToken(16 /* OpenParenToken */, endPos); - emit(node.variableDeclaration); - emitToken(17 /* CloseParenToken */, node.variableDeclaration ? node.variableDeclaration.end : endPos); - write(" "); - emitBlock(node.block); - } - function emitDebuggerStatement(node) { - emitToken(72 /* DebuggerKeyword */, node.pos); - write(";"); - } - function emitLabelledStatement(node) { - emit(node.label); - write(": "); - emit(node.statement); - } - function getContainingModule(node) { - do { - node = node.parent; - } while (node && node.kind !== 208 /* ModuleDeclaration */); - return node; - } - function emitContainingModuleName(node) { - var container = getContainingModule(node); - write(container ? getGeneratedNameForNode(container) : "exports"); - } - function emitModuleMemberName(node) { - emitStart(node.name); - if (ts.getCombinedNodeFlags(node) & 1 /* Export */) { - var container = getContainingModule(node); - if (container) { - write(getGeneratedNameForNode(container)); - write("."); - } - else if (languageVersion < 2 /* ES6 */ && compilerOptions.module !== 4 /* System */) { - write("exports."); - } - } - emitNodeWithoutSourceMap(node.name); - emitEnd(node.name); - } - function createVoidZero() { - var zero = ts.createSynthesizedNode(7 /* NumericLiteral */); - zero.text = "0"; - var result = ts.createSynthesizedNode(169 /* VoidExpression */); - result.expression = zero; - return result; - } - function emitExportMemberAssignment(node) { - if (node.flags & 1 /* Export */) { - writeLine(); - emitStart(node); - // emit call to exporter only for top level nodes - if (compilerOptions.module === 4 /* System */ && node.parent === currentSourceFile) { - // emit export default as - // export("default", ) - write(exportFunctionForFile + "(\""); - if (node.flags & 256 /* Default */) { - write("default"); - } - else { - emitNodeWithoutSourceMap(node.name); - } - write("\", "); - emitDeclarationName(node); - write(")"); - } - else { - if (node.flags & 256 /* Default */) { - if (languageVersion === 0 /* ES3 */) { - write("exports[\"default\"]"); - } - else { - write("exports.default"); - } - } - else { - emitModuleMemberName(node); - } - write(" = "); - emitDeclarationName(node); - } - emitEnd(node); - write(";"); - } - } - function emitExportMemberAssignments(name) { - if (!exportEquals && exportSpecifiers && ts.hasProperty(exportSpecifiers, name.text)) { - for (var _a = 0, _b = exportSpecifiers[name.text]; _a < _b.length; _a++) { - var specifier = _b[_a]; - writeLine(); - if (compilerOptions.module === 4 /* System */) { - emitStart(specifier.name); - write(exportFunctionForFile + "(\""); - emitNodeWithoutSourceMap(specifier.name); - write("\", "); - emitExpressionIdentifier(name); - write(")"); - emitEnd(specifier.name); - } - else { - emitStart(specifier.name); - emitContainingModuleName(specifier); - write("."); - emitNodeWithoutSourceMap(specifier.name); - emitEnd(specifier.name); - write(" = "); - emitExpressionIdentifier(name); - } - write(";"); - } - } - } - function emitDestructuring(root, isAssignmentExpressionStatement, value) { - var emitCount = 0; - // An exported declaration is actually emitted as an assignment (to a property on the module object), so - // temporary variables in an exported declaration need to have real declarations elsewhere - // Also temporary variables should be explicitly allocated for source level declarations when module target is system - // because actual variable declarations are hoisted - var canDefineTempVariablesInPlace = false; - if (root.kind === 201 /* VariableDeclaration */) { - var isExported = ts.getCombinedNodeFlags(root) & 1 /* Export */; - var isSourceLevelForSystemModuleKind = shouldHoistDeclarationInSystemJsModule(root); - canDefineTempVariablesInPlace = !isExported && !isSourceLevelForSystemModuleKind; - } - else if (root.kind === 131 /* Parameter */) { - canDefineTempVariablesInPlace = true; - } - if (root.kind === 172 /* BinaryExpression */) { - emitAssignmentExpression(root); - } - else { - ts.Debug.assert(!isAssignmentExpressionStatement); - emitBindingElement(root, value); - } - function emitAssignment(name, value) { - if (emitCount++) { - write(", "); - } - var isVariableDeclarationOrBindingElement = name.parent && (name.parent.kind === 201 /* VariableDeclaration */ || name.parent.kind === 155 /* BindingElement */); - var exportChanged = isNameOfExportedSourceLevelDeclarationInSystemExternalModule(name); - if (exportChanged) { - write(exportFunctionForFile + "(\""); - emitNodeWithoutSourceMap(name); - write("\", "); - } - if (isVariableDeclarationOrBindingElement) { - emitModuleMemberName(name.parent); - } - else { - emit(name); - } - write(" = "); - emit(value); - if (exportChanged) { - write(")"); - } - } - function ensureIdentifier(expr) { - if (expr.kind !== 65 /* Identifier */) { - var identifier = createTempVariable(0 /* Auto */); - if (!canDefineTempVariablesInPlace) { - recordTempDeclaration(identifier); - } - emitAssignment(identifier, expr); - expr = identifier; - } - return expr; - } - function createDefaultValueCheck(value, defaultValue) { - // The value expression will be evaluated twice, so for anything but a simple identifier - // we need to generate a temporary variable - value = ensureIdentifier(value); - // Return the expression 'value === void 0 ? defaultValue : value' - var equals = ts.createSynthesizedNode(172 /* BinaryExpression */); - equals.left = value; - equals.operatorToken = ts.createSynthesizedNode(30 /* EqualsEqualsEqualsToken */); - equals.right = createVoidZero(); - return createConditionalExpression(equals, defaultValue, value); - } - function createConditionalExpression(condition, whenTrue, whenFalse) { - var cond = ts.createSynthesizedNode(173 /* ConditionalExpression */); - cond.condition = condition; - cond.questionToken = ts.createSynthesizedNode(50 /* QuestionToken */); - cond.whenTrue = whenTrue; - cond.colonToken = ts.createSynthesizedNode(51 /* ColonToken */); - cond.whenFalse = whenFalse; - return cond; - } - function createNumericLiteral(value) { - var node = ts.createSynthesizedNode(7 /* NumericLiteral */); - node.text = "" + value; - return node; - } - function createPropertyAccessForDestructuringProperty(object, propName) { - // We create a synthetic copy of the identifier in order to avoid the rewriting that might - // otherwise occur when the identifier is emitted. - var syntheticName = ts.createSynthesizedNode(propName.kind); - syntheticName.text = propName.text; - if (syntheticName.kind !== 65 /* Identifier */) { - return createElementAccessExpression(object, syntheticName); - } - return createPropertyAccessExpression(object, syntheticName); - } - function createSliceCall(value, sliceIndex) { - var call = ts.createSynthesizedNode(160 /* CallExpression */); - var sliceIdentifier = ts.createSynthesizedNode(65 /* Identifier */); - sliceIdentifier.text = "slice"; - call.expression = createPropertyAccessExpression(value, sliceIdentifier); - call.arguments = ts.createSynthesizedNodeArray(); - call.arguments[0] = createNumericLiteral(sliceIndex); - return call; - } - function emitObjectLiteralAssignment(target, value) { - var properties = target.properties; - if (properties.length !== 1) { - // For anything but a single element destructuring we need to generate a temporary - // to ensure value is evaluated exactly once. - value = ensureIdentifier(value); - } - for (var _a = 0; _a < properties.length; _a++) { - var p = properties[_a]; - if (p.kind === 227 /* PropertyAssignment */ || p.kind === 228 /* ShorthandPropertyAssignment */) { - var propName = p.name; - emitDestructuringAssignment(p.initializer || propName, createPropertyAccessForDestructuringProperty(value, propName)); - } - } - } - function emitArrayLiteralAssignment(target, value) { - var elements = target.elements; - if (elements.length !== 1) { - // For anything but a single element destructuring we need to generate a temporary - // to ensure value is evaluated exactly once. - value = ensureIdentifier(value); - } - for (var i = 0; i < elements.length; i++) { - var e = elements[i]; - if (e.kind !== 178 /* OmittedExpression */) { - if (e.kind !== 176 /* SpreadElementExpression */) { - emitDestructuringAssignment(e, createElementAccessExpression(value, createNumericLiteral(i))); - } - else if (i === elements.length - 1) { - emitDestructuringAssignment(e.expression, createSliceCall(value, i)); - } - } - } - } - function emitDestructuringAssignment(target, value) { - if (target.kind === 172 /* BinaryExpression */ && target.operatorToken.kind === 53 /* EqualsToken */) { - value = createDefaultValueCheck(value, target.right); - target = target.left; - } - if (target.kind === 157 /* ObjectLiteralExpression */) { - emitObjectLiteralAssignment(target, value); - } - else if (target.kind === 156 /* ArrayLiteralExpression */) { - emitArrayLiteralAssignment(target, value); - } - else { - emitAssignment(target, value); - } - } - function emitAssignmentExpression(root) { - var target = root.left; - var value = root.right; - if (isAssignmentExpressionStatement) { - emitDestructuringAssignment(target, value); - } - else { - if (root.parent.kind !== 164 /* ParenthesizedExpression */) { - write("("); - } - value = ensureIdentifier(value); - emitDestructuringAssignment(target, value); - write(", "); - emit(value); - if (root.parent.kind !== 164 /* ParenthesizedExpression */) { - write(")"); - } - } - } - function emitBindingElement(target, value) { - if (target.initializer) { - // Combine value and initializer - value = value ? createDefaultValueCheck(value, target.initializer) : target.initializer; - } - else if (!value) { - // Use 'void 0' in absence of value and initializer - value = createVoidZero(); - } - if (ts.isBindingPattern(target.name)) { - var pattern = target.name; - var elements = pattern.elements; - if (elements.length !== 1) { - // For anything but a single element destructuring we need to generate a temporary - // to ensure value is evaluated exactly once. - value = ensureIdentifier(value); - } - for (var i = 0; i < elements.length; i++) { - var element = elements[i]; - if (pattern.kind === 153 /* ObjectBindingPattern */) { - // Rewrite element to a declaration with an initializer that fetches property - var propName = element.propertyName || element.name; - emitBindingElement(element, createPropertyAccessForDestructuringProperty(value, propName)); - } - else if (element.kind !== 178 /* OmittedExpression */) { - if (!element.dotDotDotToken) { - // Rewrite element to a declaration that accesses array element at index i - emitBindingElement(element, createElementAccessExpression(value, createNumericLiteral(i))); - } - else if (i === elements.length - 1) { - emitBindingElement(element, createSliceCall(value, i)); - } - } - } - } - else { - emitAssignment(target.name, value); - } - } - } - function emitVariableDeclaration(node) { - if (ts.isBindingPattern(node.name)) { - if (languageVersion < 2 /* ES6 */) { - emitDestructuring(node, false); - } - else { - emit(node.name); - emitOptional(" = ", node.initializer); - } - } - else { - var initializer = node.initializer; - if (!initializer && languageVersion < 2 /* ES6 */) { - // downlevel emit for non-initialized let bindings defined in loops - // for (...) { let x; } - // should be - // for (...) { var = void 0; } - // this is necessary to preserve ES6 semantic in scenarios like - // for (...) { let x; console.log(x); x = 1 } // assignment on one iteration should not affect other iterations - var isUninitializedLet = (resolver.getNodeCheckFlags(node) & 256 /* BlockScopedBindingInLoop */) && - (getCombinedFlagsForIdentifier(node.name) & 4096 /* Let */); - // NOTE: default initialization should not be added to let bindings in for-in\for-of statements - if (isUninitializedLet && - node.parent.parent.kind !== 190 /* ForInStatement */ && - node.parent.parent.kind !== 191 /* ForOfStatement */) { - initializer = createVoidZero(); - } - } - var exportChanged = isNameOfExportedSourceLevelDeclarationInSystemExternalModule(node.name); - if (exportChanged) { - write(exportFunctionForFile + "(\""); - emitNodeWithoutSourceMap(node.name); - write("\", "); - } - emitModuleMemberName(node); - emitOptional(" = ", initializer); - if (exportChanged) { - write(")"); - } - } - } - function emitExportVariableAssignments(node) { - if (node.kind === 178 /* OmittedExpression */) { - return; - } - var name = node.name; - if (name.kind === 65 /* Identifier */) { - emitExportMemberAssignments(name); - } - else if (ts.isBindingPattern(name)) { - ts.forEach(name.elements, emitExportVariableAssignments); - } - } - function getCombinedFlagsForIdentifier(node) { - if (!node.parent || (node.parent.kind !== 201 /* VariableDeclaration */ && node.parent.kind !== 155 /* BindingElement */)) { - return 0; - } - return ts.getCombinedNodeFlags(node.parent); - } - function isES6ExportedDeclaration(node) { - return !!(node.flags & 1 /* Export */) && - languageVersion >= 2 /* ES6 */ && - node.parent.kind === 230 /* SourceFile */; - } - function emitVariableStatement(node) { - var startIsEmitted = false; - if (node.flags & 1 /* Export */) { - if (isES6ExportedDeclaration(node)) { - // Exported ES6 module member - write("export "); - startIsEmitted = tryEmitStartOfVariableDeclarationList(node.declarationList); - } - } - else { - startIsEmitted = tryEmitStartOfVariableDeclarationList(node.declarationList); - } - if (startIsEmitted) { - emitCommaList(node.declarationList.declarations); - write(";"); - } - else { - var atLeastOneItem = emitVariableDeclarationListSkippingUninitializedEntries(node.declarationList); - if (atLeastOneItem) { - write(";"); - } - } - if (languageVersion < 2 /* ES6 */ && node.parent === currentSourceFile) { - ts.forEach(node.declarationList.declarations, emitExportVariableAssignments); - } - } - function shouldEmitLeadingAndTrailingCommentsForVariableStatement(node) { - // If we're not exporting the variables, there's nothing special here. - // Always emit comments for these nodes. - if (!(node.flags & 1 /* Export */)) { - return true; - } - // If we are exporting, but it's a top-level ES6 module exports, - // we'll emit the declaration list verbatim, so emit comments too. - if (isES6ExportedDeclaration(node)) { - return true; - } - // Otherwise, only emit if we have at least one initializer present. - for (var _a = 0, _b = node.declarationList.declarations; _a < _b.length; _a++) { - var declaration = _b[_a]; - if (declaration.initializer) { - return true; - } - } - return false; - } - function emitParameter(node) { - if (languageVersion < 2 /* ES6 */) { - if (ts.isBindingPattern(node.name)) { - var name_23 = createTempVariable(0 /* Auto */); - if (!tempParameters) { - tempParameters = []; - } - tempParameters.push(name_23); - emit(name_23); - } - else { - emit(node.name); - } - } - else { - if (node.dotDotDotToken) { - write("..."); - } - emit(node.name); - emitOptional(" = ", node.initializer); - } - } - function emitDefaultValueAssignments(node) { - if (languageVersion < 2 /* ES6 */) { - var tempIndex = 0; - ts.forEach(node.parameters, function (p) { - // A rest parameter cannot have a binding pattern or an initializer, - // so let's just ignore it. - if (p.dotDotDotToken) { - return; - } - if (ts.isBindingPattern(p.name)) { - writeLine(); - write("var "); - emitDestructuring(p, false, tempParameters[tempIndex]); - write(";"); - tempIndex++; - } - else if (p.initializer) { - writeLine(); - emitStart(p); - write("if ("); - emitNodeWithoutSourceMap(p.name); - write(" === void 0)"); - emitEnd(p); - write(" { "); - emitStart(p); - emitNodeWithoutSourceMap(p.name); - write(" = "); - emitNodeWithoutSourceMap(p.initializer); - emitEnd(p); - write("; }"); - } - }); - } - } - function emitRestParameter(node) { - if (languageVersion < 2 /* ES6 */ && ts.hasRestParameter(node)) { - var restIndex = node.parameters.length - 1; - var restParam = node.parameters[restIndex]; - // A rest parameter cannot have a binding pattern, so let's just ignore it if it does. - if (ts.isBindingPattern(restParam.name)) { - return; - } - var tempName = createTempVariable(268435456 /* _i */).text; - writeLine(); - emitLeadingComments(restParam); - emitStart(restParam); - write("var "); - emitNodeWithoutSourceMap(restParam.name); - write(" = [];"); - emitEnd(restParam); - emitTrailingComments(restParam); - writeLine(); - write("for ("); - emitStart(restParam); - write("var " + tempName + " = " + restIndex + ";"); - emitEnd(restParam); - write(" "); - emitStart(restParam); - write(tempName + " < arguments.length;"); - emitEnd(restParam); - write(" "); - emitStart(restParam); - write(tempName + "++"); - emitEnd(restParam); - write(") {"); - increaseIndent(); - writeLine(); - emitStart(restParam); - emitNodeWithoutSourceMap(restParam.name); - write("[" + tempName + " - " + restIndex + "] = arguments[" + tempName + "];"); - emitEnd(restParam); - decreaseIndent(); - writeLine(); - write("}"); - } - } - function emitAccessor(node) { - write(node.kind === 138 /* GetAccessor */ ? "get " : "set "); - emit(node.name); - emitSignatureAndBody(node); - } - function shouldEmitAsArrowFunction(node) { - return node.kind === 166 /* ArrowFunction */ && languageVersion >= 2 /* ES6 */; - } - function emitDeclarationName(node) { - if (node.name) { - emitNodeWithoutSourceMap(node.name); - } - else { - write(getGeneratedNameForNode(node)); - } - } - function shouldEmitFunctionName(node) { - if (node.kind === 165 /* FunctionExpression */) { - // Emit name if one is present - return !!node.name; - } - if (node.kind === 203 /* FunctionDeclaration */) { - // Emit name if one is present, or emit generated name in down-level case (for export default case) - return !!node.name || languageVersion < 2 /* ES6 */; - } - } - function emitFunctionDeclaration(node) { - if (ts.nodeIsMissing(node.body)) { - return emitOnlyPinnedOrTripleSlashComments(node); - } - if (node.kind !== 136 /* MethodDeclaration */ && node.kind !== 135 /* MethodSignature */) { - // Methods will emit the comments as part of emitting method declaration - emitLeadingComments(node); - } - // For targeting below es6, emit functions-like declaration including arrow function using function keyword. - // When targeting ES6, emit arrow function natively in ES6 by omitting function keyword and using fat arrow instead - if (!shouldEmitAsArrowFunction(node)) { - if (isES6ExportedDeclaration(node)) { - write("export "); - if (node.flags & 256 /* Default */) { - write("default "); - } - } - write("function"); - if (languageVersion >= 2 /* ES6 */ && node.asteriskToken) { - write("*"); - } - write(" "); - } - if (shouldEmitFunctionName(node)) { - emitDeclarationName(node); - } - emitSignatureAndBody(node); - if (languageVersion < 2 /* ES6 */ && node.kind === 203 /* FunctionDeclaration */ && node.parent === currentSourceFile && node.name) { - emitExportMemberAssignments(node.name); - } - if (node.kind !== 136 /* MethodDeclaration */ && node.kind !== 135 /* MethodSignature */) { - emitTrailingComments(node); - } - } - function emitCaptureThisForNodeIfNecessary(node) { - if (resolver.getNodeCheckFlags(node) & 4 /* CaptureThis */) { - writeLine(); - emitStart(node); - write("var _this = this;"); - emitEnd(node); - } - } - function emitSignatureParameters(node) { - increaseIndent(); - write("("); - if (node) { - var parameters = node.parameters; - var omitCount = languageVersion < 2 /* ES6 */ && ts.hasRestParameter(node) ? 1 : 0; - emitList(parameters, 0, parameters.length - omitCount, false, false); - } - write(")"); - decreaseIndent(); - } - function emitSignatureParametersForArrow(node) { - // Check whether the parameter list needs parentheses and preserve no-parenthesis - if (node.parameters.length === 1 && node.pos === node.parameters[0].pos) { - emit(node.parameters[0]); - return; - } - emitSignatureParameters(node); - } - function emitSignatureAndBody(node) { - var saveTempFlags = tempFlags; - var saveTempVariables = tempVariables; - var saveTempParameters = tempParameters; - tempFlags = 0; - tempVariables = undefined; - tempParameters = undefined; - // When targeting ES6, emit arrow function natively in ES6 - if (shouldEmitAsArrowFunction(node)) { - emitSignatureParametersForArrow(node); - write(" =>"); - } - else { - emitSignatureParameters(node); - } - if (!node.body) { - // There can be no body when there are parse errors. Just emit an empty block - // in that case. - write(" { }"); - } - else if (node.body.kind === 182 /* Block */) { - emitBlockFunctionBody(node, node.body); - } - else { - emitExpressionFunctionBody(node, node.body); - } - if (!isES6ExportedDeclaration(node)) { - emitExportMemberAssignment(node); - } - tempFlags = saveTempFlags; - tempVariables = saveTempVariables; - tempParameters = saveTempParameters; - } - // Returns true if any preamble code was emitted. - function emitFunctionBodyPreamble(node) { - emitCaptureThisForNodeIfNecessary(node); - emitDefaultValueAssignments(node); - emitRestParameter(node); - } - function emitExpressionFunctionBody(node, body) { - if (languageVersion < 2 /* ES6 */) { - emitDownLevelExpressionFunctionBody(node, body); - return; - } - // For es6 and higher we can emit the expression as is. However, in the case - // where the expression might end up looking like a block when emitted, we'll - // also wrap it in parentheses first. For example if you have: a => {} - // then we need to generate: a => ({}) - write(" "); - // Unwrap all type assertions. - var current = body; - while (current.kind === 163 /* TypeAssertionExpression */) { - current = current.expression; - } - emitParenthesizedIf(body, current.kind === 157 /* ObjectLiteralExpression */); - } - function emitDownLevelExpressionFunctionBody(node, body) { - write(" {"); - scopeEmitStart(node); - increaseIndent(); - var outPos = writer.getTextPos(); - emitDetachedComments(node.body); - emitFunctionBodyPreamble(node); - var preambleEmitted = writer.getTextPos() !== outPos; - decreaseIndent(); - // If we didn't have to emit any preamble code, then attempt to keep the arrow - // function on one line. - if (!preambleEmitted && nodeStartPositionsAreOnSameLine(node, body)) { - write(" "); - emitStart(body); - write("return "); - emit(body); - emitEnd(body); - write(";"); - emitTempDeclarations(false); - write(" "); - } - else { - increaseIndent(); - writeLine(); - emitLeadingComments(node.body); - write("return "); - emit(body); - write(";"); - emitTrailingComments(node.body); - emitTempDeclarations(true); - decreaseIndent(); - writeLine(); - } - emitStart(node.body); - write("}"); - emitEnd(node.body); - scopeEmitEnd(); - } - function emitBlockFunctionBody(node, body) { - write(" {"); - scopeEmitStart(node); - var initialTextPos = writer.getTextPos(); - increaseIndent(); - emitDetachedComments(body.statements); - // Emit all the directive prologues (like "use strict"). These have to come before - // any other preamble code we write (like parameter initializers). - var startIndex = emitDirectivePrologues(body.statements, true); - emitFunctionBodyPreamble(node); - decreaseIndent(); - var preambleEmitted = writer.getTextPos() !== initialTextPos; - if (!preambleEmitted && nodeEndIsOnSameLineAsNodeStart(body, body)) { - for (var _a = 0, _b = body.statements; _a < _b.length; _a++) { - var statement = _b[_a]; - write(" "); - emit(statement); - } - emitTempDeclarations(false); - write(" "); - emitLeadingCommentsOfPosition(body.statements.end); - } - else { - increaseIndent(); - emitLinesStartingAt(body.statements, startIndex); - emitTempDeclarations(true); - writeLine(); - emitLeadingCommentsOfPosition(body.statements.end); - decreaseIndent(); - } - emitToken(15 /* CloseBraceToken */, body.statements.end); - scopeEmitEnd(); - } - function findInitialSuperCall(ctor) { - if (ctor.body) { - var statement = ctor.body.statements[0]; - if (statement && statement.kind === 185 /* ExpressionStatement */) { - var expr = statement.expression; - if (expr && expr.kind === 160 /* CallExpression */) { - var func = expr.expression; - if (func && func.kind === 91 /* SuperKeyword */) { - return statement; - } - } - } - } - } - function emitParameterPropertyAssignments(node) { - ts.forEach(node.parameters, function (param) { - if (param.flags & 112 /* AccessibilityModifier */) { - writeLine(); - emitStart(param); - emitStart(param.name); - write("this."); - emitNodeWithoutSourceMap(param.name); - emitEnd(param.name); - write(" = "); - emit(param.name); - write(";"); - emitEnd(param); - } - }); - } - function emitMemberAccessForPropertyName(memberName) { - // TODO: (jfreeman,drosen): comment on why this is emitNodeWithoutSourceMap instead of emit here. - if (memberName.kind === 8 /* StringLiteral */ || memberName.kind === 7 /* NumericLiteral */) { - write("["); - emitNodeWithoutSourceMap(memberName); - write("]"); - } - else if (memberName.kind === 129 /* ComputedPropertyName */) { - emitComputedPropertyName(memberName); - } - else { - write("."); - emitNodeWithoutSourceMap(memberName); - } - } - function getInitializedProperties(node, isStatic) { - var properties = []; - for (var _a = 0, _b = node.members; _a < _b.length; _a++) { - var member = _b[_a]; - if (member.kind === 134 /* PropertyDeclaration */ && isStatic === ((member.flags & 128 /* Static */) !== 0) && member.initializer) { - properties.push(member); - } - } - return properties; - } - function emitPropertyDeclarations(node, properties) { - for (var _a = 0; _a < properties.length; _a++) { - var property = properties[_a]; - emitPropertyDeclaration(node, property); - } - } - function emitPropertyDeclaration(node, property, receiver, isExpression) { - writeLine(); - emitLeadingComments(property); - emitStart(property); - emitStart(property.name); - if (receiver) { - emit(receiver); - } - else { - if (property.flags & 128 /* Static */) { - emitDeclarationName(node); - } - else { - write("this"); - } - } - emitMemberAccessForPropertyName(property.name); - emitEnd(property.name); - write(" = "); - emit(property.initializer); - if (!isExpression) { - write(";"); - } - emitEnd(property); - emitTrailingComments(property); - } - function emitMemberFunctionsForES5AndLower(node) { - ts.forEach(node.members, function (member) { - if (member.kind === 181 /* SemicolonClassElement */) { - writeLine(); - write(";"); - } - else if (member.kind === 136 /* MethodDeclaration */ || node.kind === 135 /* MethodSignature */) { - if (!member.body) { - return emitOnlyPinnedOrTripleSlashComments(member); - } - writeLine(); - emitLeadingComments(member); - emitStart(member); - emitStart(member.name); - emitClassMemberPrefix(node, member); - emitMemberAccessForPropertyName(member.name); - emitEnd(member.name); - write(" = "); - emitStart(member); - emitFunctionDeclaration(member); - emitEnd(member); - emitEnd(member); - write(";"); - emitTrailingComments(member); - } - else if (member.kind === 138 /* GetAccessor */ || member.kind === 139 /* SetAccessor */) { - var accessors = ts.getAllAccessorDeclarations(node.members, member); - if (member === accessors.firstAccessor) { - writeLine(); - emitStart(member); - write("Object.defineProperty("); - emitStart(member.name); - emitClassMemberPrefix(node, member); - write(", "); - emitExpressionForPropertyName(member.name); - emitEnd(member.name); - write(", {"); - increaseIndent(); - if (accessors.getAccessor) { - writeLine(); - emitLeadingComments(accessors.getAccessor); - write("get: "); - emitStart(accessors.getAccessor); - write("function "); - emitSignatureAndBody(accessors.getAccessor); - emitEnd(accessors.getAccessor); - emitTrailingComments(accessors.getAccessor); - write(","); - } - if (accessors.setAccessor) { - writeLine(); - emitLeadingComments(accessors.setAccessor); - write("set: "); - emitStart(accessors.setAccessor); - write("function "); - emitSignatureAndBody(accessors.setAccessor); - emitEnd(accessors.setAccessor); - emitTrailingComments(accessors.setAccessor); - write(","); - } - writeLine(); - write("enumerable: true,"); - writeLine(); - write("configurable: true"); - decreaseIndent(); - writeLine(); - write("});"); - emitEnd(member); - } - } - }); - } - function emitMemberFunctionsForES6AndHigher(node) { - for (var _a = 0, _b = node.members; _a < _b.length; _a++) { - var member = _b[_a]; - if ((member.kind === 136 /* MethodDeclaration */ || node.kind === 135 /* MethodSignature */) && !member.body) { - emitOnlyPinnedOrTripleSlashComments(member); - } - else if (member.kind === 136 /* MethodDeclaration */ || - member.kind === 138 /* GetAccessor */ || - member.kind === 139 /* SetAccessor */) { - writeLine(); - emitLeadingComments(member); - emitStart(member); - if (member.flags & 128 /* Static */) { - write("static "); - } - if (member.kind === 138 /* GetAccessor */) { - write("get "); - } - else if (member.kind === 139 /* SetAccessor */) { - write("set "); - } - if (member.asteriskToken) { - write("*"); - } - emit(member.name); - emitSignatureAndBody(member); - emitEnd(member); - emitTrailingComments(member); - } - else if (member.kind === 181 /* SemicolonClassElement */) { - writeLine(); - write(";"); - } - } - } - function emitConstructor(node, baseTypeElement) { - var saveTempFlags = tempFlags; - var saveTempVariables = tempVariables; - var saveTempParameters = tempParameters; - tempFlags = 0; - tempVariables = undefined; - tempParameters = undefined; - emitConstructorWorker(node, baseTypeElement); - tempFlags = saveTempFlags; - tempVariables = saveTempVariables; - tempParameters = saveTempParameters; - } - function emitConstructorWorker(node, baseTypeElement) { - // Check if we have property assignment inside class declaration. - // If there is property assignment, we need to emit constructor whether users define it or not - // If there is no property assignment, we can omit constructor if users do not define it - var hasInstancePropertyWithInitializer = false; - // Emit the constructor overload pinned comments - ts.forEach(node.members, function (member) { - if (member.kind === 137 /* Constructor */ && !member.body) { - emitOnlyPinnedOrTripleSlashComments(member); - } - // Check if there is any non-static property assignment - if (member.kind === 134 /* PropertyDeclaration */ && member.initializer && (member.flags & 128 /* Static */) === 0) { - hasInstancePropertyWithInitializer = true; - } - }); - var ctor = ts.getFirstConstructorWithBody(node); - // For target ES6 and above, if there is no user-defined constructor and there is no property assignment - // do not emit constructor in class declaration. - if (languageVersion >= 2 /* ES6 */ && !ctor && !hasInstancePropertyWithInitializer) { - return; - } - if (ctor) { - emitLeadingComments(ctor); - } - emitStart(ctor || node); - if (languageVersion < 2 /* ES6 */) { - write("function "); - emitDeclarationName(node); - emitSignatureParameters(ctor); - } - else { - write("constructor"); - if (ctor) { - emitSignatureParameters(ctor); - } - else { - // Based on EcmaScript6 section 14.5.14: Runtime Semantics: ClassDefinitionEvaluation. - // If constructor is empty, then, - // If ClassHeritageopt is present, then - // Let constructor be the result of parsing the String "constructor(... args){ super (...args);}" using the syntactic grammar with the goal symbol MethodDefinition. - // Else, - // Let constructor be the result of parsing the String "constructor( ){ }" using the syntactic grammar with the goal symbol MethodDefinition - if (baseTypeElement) { - write("(...args)"); - } - else { - write("()"); - } - } - } - write(" {"); - scopeEmitStart(node, "constructor"); - increaseIndent(); - if (ctor) { - emitDetachedComments(ctor.body.statements); - } - emitCaptureThisForNodeIfNecessary(node); - if (ctor) { - emitDefaultValueAssignments(ctor); - emitRestParameter(ctor); - if (baseTypeElement) { - var superCall = findInitialSuperCall(ctor); - if (superCall) { - writeLine(); - emit(superCall); - } - } - emitParameterPropertyAssignments(ctor); - } - else { - if (baseTypeElement) { - writeLine(); - emitStart(baseTypeElement); - if (languageVersion < 2 /* ES6 */) { - write("_super.apply(this, arguments);"); - } - else { - write("super(...args);"); - } - emitEnd(baseTypeElement); - } - } - emitPropertyDeclarations(node, getInitializedProperties(node, false)); - if (ctor) { - var statements = ctor.body.statements; - if (superCall) { - statements = statements.slice(1); - } - emitLines(statements); - } - emitTempDeclarations(true); - writeLine(); - if (ctor) { - emitLeadingCommentsOfPosition(ctor.body.statements.end); - } - decreaseIndent(); - emitToken(15 /* CloseBraceToken */, ctor ? ctor.body.statements.end : node.members.end); - scopeEmitEnd(); - emitEnd(ctor || node); - if (ctor) { - emitTrailingComments(ctor); - } - } - function emitClassExpression(node) { - return emitClassLikeDeclaration(node); - } - function emitClassDeclaration(node) { - return emitClassLikeDeclaration(node); - } - function emitClassLikeDeclaration(node) { - if (languageVersion < 2 /* ES6 */) { - emitClassLikeDeclarationBelowES6(node); - } - else { - emitClassLikeDeclarationForES6AndHigher(node); - } - } - function emitClassLikeDeclarationForES6AndHigher(node) { - var thisNodeIsDecorated = ts.nodeIsDecorated(node); - if (node.kind === 204 /* ClassDeclaration */) { - if (thisNodeIsDecorated) { - // To preserve the correct runtime semantics when decorators are applied to the class, - // the emit needs to follow one of the following rules: - // - // * For a local class declaration: - // - // @dec class C { - // } - // - // The emit should be: - // - // let C = class { - // }; - // Object.defineProperty(C, "name", { value: "C", configurable: true }); - // C = __decorate([dec], C); - // - // * For an exported class declaration: - // - // @dec export class C { - // } - // - // The emit should be: - // - // export let C = class { - // }; - // Object.defineProperty(C, "name", { value: "C", configurable: true }); - // C = __decorate([dec], C); - // - // * For a default export of a class declaration with a name: - // - // @dec default export class C { - // } - // - // The emit should be: - // - // let C = class { - // } - // Object.defineProperty(C, "name", { value: "C", configurable: true }); - // C = __decorate([dec], C); - // export default C; - // - // * For a default export of a class declaration without a name: - // - // @dec default export class { - // } - // - // The emit should be: - // - // let _default = class { - // } - // _default = __decorate([dec], _default); - // export default _default; - // - if (isES6ExportedDeclaration(node) && !(node.flags & 256 /* Default */)) { - write("export "); - } - write("let "); - emitDeclarationName(node); - write(" = "); - } - else if (isES6ExportedDeclaration(node)) { - write("export "); - if (node.flags & 256 /* Default */) { - write("default "); - } - } - } - // If the class has static properties, and it's a class expression, then we'll need - // to specialize the emit a bit. for a class expression of the form: - // - // class C { static a = 1; static b = 2; ... } - // - // We'll emit: - // - // (_temp = class C { ... }, _temp.a = 1, _temp.b = 2, _temp) - // - // This keeps the expression as an expression, while ensuring that the static parts - // of it have been initialized by the time it is used. - var staticProperties = getInitializedProperties(node, true); - var isClassExpressionWithStaticProperties = staticProperties.length > 0 && node.kind === 177 /* ClassExpression */; - var tempVariable; - if (isClassExpressionWithStaticProperties) { - tempVariable = createAndRecordTempVariable(0 /* Auto */); - write("("); - increaseIndent(); - emit(tempVariable); - write(" = "); - } - write("class"); - // check if this is an "export default class" as it may not have a name. Do not emit the name if the class is decorated. - if ((node.name || !(node.flags & 256 /* Default */)) && !thisNodeIsDecorated) { - write(" "); - emitDeclarationName(node); - } - var baseTypeNode = ts.getClassExtendsHeritageClauseElement(node); - if (baseTypeNode) { - write(" extends "); - emit(baseTypeNode.expression); - } - write(" {"); - increaseIndent(); - scopeEmitStart(node); - writeLine(); - emitConstructor(node, baseTypeNode); - emitMemberFunctionsForES6AndHigher(node); - decreaseIndent(); - writeLine(); - emitToken(15 /* CloseBraceToken */, node.members.end); - scopeEmitEnd(); - // TODO(rbuckton): Need to go back to `let _a = class C {}` approach, removing the defineProperty call for now. - // For a decorated class, we need to assign its name (if it has one). This is because we emit - // the class as a class expression to avoid the double-binding of the identifier: - // - // let C = class { - // } - // Object.defineProperty(C, "name", { value: "C", configurable: true }); - // - if (thisNodeIsDecorated) { - write(";"); - } - // Emit static property assignment. Because classDeclaration is lexically evaluated, - // it is safe to emit static property assignment after classDeclaration - // From ES6 specification: - // HasLexicalDeclaration (N) : Determines if the argument identifier has a binding in this environment record that was created using - // a lexical declaration such as a LexicalDeclaration or a ClassDeclaration. - if (isClassExpressionWithStaticProperties) { - for (var _a = 0; _a < staticProperties.length; _a++) { - var property = staticProperties[_a]; - write(","); - writeLine(); - emitPropertyDeclaration(node, property, tempVariable, true); - } - write(","); - writeLine(); - emit(tempVariable); - decreaseIndent(); - write(")"); - } - else { - writeLine(); - emitPropertyDeclarations(node, staticProperties); - emitDecoratorsOfClass(node); - } - // If this is an exported class, but not on the top level (i.e. on an internal - // module), export it - if (!isES6ExportedDeclaration(node) && (node.flags & 1 /* Export */)) { - writeLine(); - emitStart(node); - emitModuleMemberName(node); - write(" = "); - emitDeclarationName(node); - emitEnd(node); - write(";"); - } - else if (isES6ExportedDeclaration(node) && (node.flags & 256 /* Default */) && thisNodeIsDecorated) { - // if this is a top level default export of decorated class, write the export after the declaration. - writeLine(); - write("export default "); - emitDeclarationName(node); - write(";"); - } - } - function emitClassLikeDeclarationBelowES6(node) { - if (node.kind === 204 /* ClassDeclaration */) { - // source file level classes in system modules are hoisted so 'var's for them are already defined - if (!shouldHoistDeclarationInSystemJsModule(node)) { - write("var "); - } - emitDeclarationName(node); - write(" = "); - } - write("(function ("); - var baseTypeNode = ts.getClassExtendsHeritageClauseElement(node); - if (baseTypeNode) { - write("_super"); - } - write(") {"); - var saveTempFlags = tempFlags; - var saveTempVariables = tempVariables; - var saveTempParameters = tempParameters; - var saveComputedPropertyNamesToGeneratedNames = computedPropertyNamesToGeneratedNames; - tempFlags = 0; - tempVariables = undefined; - tempParameters = undefined; - computedPropertyNamesToGeneratedNames = undefined; - increaseIndent(); - scopeEmitStart(node); - if (baseTypeNode) { - writeLine(); - emitStart(baseTypeNode); - write("__extends("); - emitDeclarationName(node); - write(", _super);"); - emitEnd(baseTypeNode); - } - writeLine(); - emitConstructor(node, baseTypeNode); - emitMemberFunctionsForES5AndLower(node); - emitPropertyDeclarations(node, getInitializedProperties(node, true)); - writeLine(); - emitDecoratorsOfClass(node); - writeLine(); - emitToken(15 /* CloseBraceToken */, node.members.end, function () { - write("return "); - emitDeclarationName(node); - }); - write(";"); - emitTempDeclarations(true); - tempFlags = saveTempFlags; - tempVariables = saveTempVariables; - tempParameters = saveTempParameters; - computedPropertyNamesToGeneratedNames = saveComputedPropertyNamesToGeneratedNames; - decreaseIndent(); - writeLine(); - emitToken(15 /* CloseBraceToken */, node.members.end); - scopeEmitEnd(); - emitStart(node); - write(")("); - if (baseTypeNode) { - emit(baseTypeNode.expression); - } - write(")"); - if (node.kind === 204 /* ClassDeclaration */) { - write(";"); - } - emitEnd(node); - if (node.kind === 204 /* ClassDeclaration */) { - emitExportMemberAssignment(node); - } - if (languageVersion < 2 /* ES6 */ && node.parent === currentSourceFile && node.name) { - emitExportMemberAssignments(node.name); - } - } - function emitClassMemberPrefix(node, member) { - emitDeclarationName(node); - if (!(member.flags & 128 /* Static */)) { - write(".prototype"); - } - } - function emitDecoratorsOfClass(node) { - emitDecoratorsOfMembers(node, 0); - emitDecoratorsOfMembers(node, 128 /* Static */); - emitDecoratorsOfConstructor(node); - } - function emitDecoratorsOfConstructor(node) { - var decorators = node.decorators; - var constructor = ts.getFirstConstructorWithBody(node); - var hasDecoratedParameters = constructor && ts.forEach(constructor.parameters, ts.nodeIsDecorated); - // skip decoration of the constructor if neither it nor its parameters are decorated - if (!decorators && !hasDecoratedParameters) { - return; - } - // Emit the call to __decorate. Given the class: - // - // @dec - // class C { - // } - // - // The emit for the class is: - // - // C = __decorate([dec], C); - // - writeLine(); - emitStart(node); - emitDeclarationName(node); - write(" = __decorate(["); - increaseIndent(); - writeLine(); - var decoratorCount = decorators ? decorators.length : 0; - var argumentsWritten = emitList(decorators, 0, decoratorCount, true, false, false, true, function (decorator) { - emitStart(decorator); - emit(decorator.expression); - emitEnd(decorator); - }); - argumentsWritten += emitDecoratorsOfParameters(constructor, argumentsWritten > 0); - emitSerializedTypeMetadata(node, argumentsWritten >= 0); - decreaseIndent(); - writeLine(); - write("], "); - emitDeclarationName(node); - write(");"); - emitEnd(node); - writeLine(); - } - function emitDecoratorsOfMembers(node, staticFlag) { - for (var _a = 0, _b = node.members; _a < _b.length; _a++) { - var member = _b[_a]; - // only emit members in the correct group - if ((member.flags & 128 /* Static */) !== staticFlag) { - continue; - } - // skip members that cannot be decorated (such as the constructor) - if (!ts.nodeCanBeDecorated(member)) { - continue; - } - // skip a member if it or any of its parameters are not decorated - if (!ts.nodeOrChildIsDecorated(member)) { - continue; - } - // skip an accessor declaration if it is not the first accessor - var decorators = void 0; - var functionLikeMember = void 0; - if (ts.isAccessor(member)) { - var accessors = ts.getAllAccessorDeclarations(node.members, member); - if (member !== accessors.firstAccessor) { - continue; - } - // get the decorators from the first accessor with decorators - decorators = accessors.firstAccessor.decorators; - if (!decorators && accessors.secondAccessor) { - decorators = accessors.secondAccessor.decorators; - } - // we only decorate parameters of the set accessor - functionLikeMember = accessors.setAccessor; - } - else { - decorators = member.decorators; - // we only decorate the parameters here if this is a method - if (member.kind === 136 /* MethodDeclaration */) { - functionLikeMember = member; - } - } - // Emit the call to __decorate. Given the following: - // - // class C { - // @dec method(@dec2 x) {} - // @dec get accessor() {} - // @dec prop; - // } - // - // The emit for a method is: - // - // Object.defineProperty(C.prototype, "method", - // __decorate([ - // dec, - // __param(0, dec2), - // __metadata("design:type", Function), - // __metadata("design:paramtypes", [Object]), - // __metadata("design:returntype", void 0) - // ], C.prototype, "method", Object.getOwnPropertyDescriptor(C.prototype, "method"))); - // - // The emit for an accessor is: - // - // Object.defineProperty(C.prototype, "accessor", - // __decorate([ - // dec - // ], C.prototype, "accessor", Object.getOwnPropertyDescriptor(C.prototype, "accessor"))); - // - // The emit for a property is: - // - // __decorate([ - // dec - // ], C.prototype, "prop"); - // - writeLine(); - emitStart(member); - if (member.kind !== 134 /* PropertyDeclaration */) { - write("Object.defineProperty("); - emitStart(member.name); - emitClassMemberPrefix(node, member); - write(", "); - emitExpressionForPropertyName(member.name); - emitEnd(member.name); - write(","); - increaseIndent(); - writeLine(); - } - write("__decorate(["); - increaseIndent(); - writeLine(); - var decoratorCount = decorators ? decorators.length : 0; - var argumentsWritten = emitList(decorators, 0, decoratorCount, true, false, false, true, function (decorator) { - emitStart(decorator); - emit(decorator.expression); - emitEnd(decorator); - }); - argumentsWritten += emitDecoratorsOfParameters(functionLikeMember, argumentsWritten > 0); - emitSerializedTypeMetadata(member, argumentsWritten > 0); - decreaseIndent(); - writeLine(); - write("], "); - emitStart(member.name); - emitClassMemberPrefix(node, member); - write(", "); - emitExpressionForPropertyName(member.name); - emitEnd(member.name); - if (member.kind !== 134 /* PropertyDeclaration */) { - write(", Object.getOwnPropertyDescriptor("); - emitStart(member.name); - emitClassMemberPrefix(node, member); - write(", "); - emitExpressionForPropertyName(member.name); - emitEnd(member.name); - write("))"); - decreaseIndent(); - } - write(");"); - emitEnd(member); - writeLine(); - } - } - function emitDecoratorsOfParameters(node, leadingComma) { - var argumentsWritten = 0; - if (node) { - var parameterIndex = 0; - for (var _a = 0, _b = node.parameters; _a < _b.length; _a++) { - var parameter = _b[_a]; - if (ts.nodeIsDecorated(parameter)) { - var decorators = parameter.decorators; - argumentsWritten += emitList(decorators, 0, decorators.length, true, false, leadingComma, true, function (decorator) { - emitStart(decorator); - write("__param(" + parameterIndex + ", "); - emit(decorator.expression); - write(")"); - emitEnd(decorator); - }); - leadingComma = true; - } - ++parameterIndex; - } - } - return argumentsWritten; - } - function shouldEmitTypeMetadata(node) { - // This method determines whether to emit the "design:type" metadata based on the node's kind. - // The caller should have already tested whether the node has decorators and whether the emitDecoratorMetadata - // compiler option is set. - switch (node.kind) { - case 136 /* MethodDeclaration */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 134 /* PropertyDeclaration */: - return true; - } - return false; - } - function shouldEmitReturnTypeMetadata(node) { - // This method determines whether to emit the "design:returntype" metadata based on the node's kind. - // The caller should have already tested whether the node has decorators and whether the emitDecoratorMetadata - // compiler option is set. - switch (node.kind) { - case 136 /* MethodDeclaration */: - return true; - } - return false; - } - function shouldEmitParamTypesMetadata(node) { - // This method determines whether to emit the "design:paramtypes" metadata based on the node's kind. - // The caller should have already tested whether the node has decorators and whether the emitDecoratorMetadata - // compiler option is set. - switch (node.kind) { - case 204 /* ClassDeclaration */: - case 136 /* MethodDeclaration */: - case 139 /* SetAccessor */: - return true; - } - return false; - } - function emitSerializedTypeMetadata(node, writeComma) { - // This method emits the serialized type metadata for a decorator target. - // The caller should have already tested whether the node has decorators. - var argumentsWritten = 0; - if (compilerOptions.emitDecoratorMetadata) { - if (shouldEmitTypeMetadata(node)) { - var serializedType = resolver.serializeTypeOfNode(node); - if (serializedType) { - if (writeComma) { - write(", "); - } - writeLine(); - write("__metadata('design:type', "); - emitSerializedType(node, serializedType); - write(")"); - argumentsWritten++; - } - } - if (shouldEmitParamTypesMetadata(node)) { - var serializedTypes = resolver.serializeParameterTypesOfNode(node); - if (serializedTypes) { - if (writeComma || argumentsWritten) { - write(", "); - } - writeLine(); - write("__metadata('design:paramtypes', ["); - for (var i = 0; i < serializedTypes.length; ++i) { - if (i > 0) { - write(", "); - } - emitSerializedType(node, serializedTypes[i]); - } - write("])"); - argumentsWritten++; - } - } - if (shouldEmitReturnTypeMetadata(node)) { - var serializedType = resolver.serializeReturnTypeOfNode(node); - if (serializedType) { - if (writeComma || argumentsWritten) { - write(", "); - } - writeLine(); - write("__metadata('design:returntype', "); - emitSerializedType(node, serializedType); - write(")"); - argumentsWritten++; - } - } - } - return argumentsWritten; - } - function serializeTypeNameSegment(location, path, index) { - switch (index) { - case 0: - return "typeof " + path[index] + " !== 'undefined' && " + path[index]; - case 1: - return serializeTypeNameSegment(location, path, index - 1) + "." + path[index]; - default: - var temp = createAndRecordTempVariable(0 /* Auto */).text; - return "(" + temp + " = " + serializeTypeNameSegment(location, path, index - 1) + ") && " + temp + "." + path[index]; - } - } - function emitSerializedType(location, name) { - if (typeof name === "string") { - write(name); - return; - } - else { - ts.Debug.assert(name.length > 0, "Invalid serialized type name"); - write("(" + serializeTypeNameSegment(location, name, name.length - 1) + ") || Object"); - } - } - function emitInterfaceDeclaration(node) { - emitOnlyPinnedOrTripleSlashComments(node); - } - function shouldEmitEnumDeclaration(node) { - var isConstEnum = ts.isConst(node); - return !isConstEnum || compilerOptions.preserveConstEnums || compilerOptions.isolatedModules; - } - function emitEnumDeclaration(node) { - // const enums are completely erased during compilation. - if (!shouldEmitEnumDeclaration(node)) { - return; - } - if (!shouldHoistDeclarationInSystemJsModule(node)) { - // do not emit var if variable was already hoisted - if (!(node.flags & 1 /* Export */) || isES6ExportedDeclaration(node)) { - emitStart(node); - if (isES6ExportedDeclaration(node)) { - write("export "); - } - write("var "); - emit(node.name); - emitEnd(node); - write(";"); - } - } - writeLine(); - emitStart(node); - write("(function ("); - emitStart(node.name); - write(getGeneratedNameForNode(node)); - emitEnd(node.name); - write(") {"); - increaseIndent(); - scopeEmitStart(node); - emitLines(node.members); - decreaseIndent(); - writeLine(); - emitToken(15 /* CloseBraceToken */, node.members.end); - scopeEmitEnd(); - write(")("); - emitModuleMemberName(node); - write(" || ("); - emitModuleMemberName(node); - write(" = {}));"); - emitEnd(node); - if (!isES6ExportedDeclaration(node) && node.flags & 1 /* Export */ && !shouldHoistDeclarationInSystemJsModule(node)) { - // do not emit var if variable was already hoisted - writeLine(); - emitStart(node); - write("var "); - emit(node.name); - write(" = "); - emitModuleMemberName(node); - emitEnd(node); - write(";"); - } - if (languageVersion < 2 /* ES6 */ && node.parent === currentSourceFile) { - if (compilerOptions.module === 4 /* System */ && (node.flags & 1 /* Export */)) { - // write the call to exporter for enum - writeLine(); - write(exportFunctionForFile + "(\""); - emitDeclarationName(node); - write("\", "); - emitDeclarationName(node); - write(");"); - } - emitExportMemberAssignments(node.name); - } - } - function emitEnumMember(node) { - var enumParent = node.parent; - emitStart(node); - write(getGeneratedNameForNode(enumParent)); - write("["); - write(getGeneratedNameForNode(enumParent)); - write("["); - emitExpressionForPropertyName(node.name); - write("] = "); - writeEnumMemberDeclarationValue(node); - write("] = "); - emitExpressionForPropertyName(node.name); - emitEnd(node); - write(";"); - } - function writeEnumMemberDeclarationValue(member) { - var value = resolver.getConstantValue(member); - if (value !== undefined) { - write(value.toString()); - return; - } - else if (member.initializer) { - emit(member.initializer); - } - else { - write("undefined"); - } - } - function getInnerMostModuleDeclarationFromDottedModule(moduleDeclaration) { - if (moduleDeclaration.body.kind === 208 /* ModuleDeclaration */) { - var recursiveInnerModule = getInnerMostModuleDeclarationFromDottedModule(moduleDeclaration.body); - return recursiveInnerModule || moduleDeclaration.body; - } - } - function shouldEmitModuleDeclaration(node) { - return ts.isInstantiatedModule(node, compilerOptions.preserveConstEnums || compilerOptions.isolatedModules); - } - function isModuleMergedWithES6Class(node) { - return languageVersion === 2 /* ES6 */ && !!(resolver.getNodeCheckFlags(node) & 2048 /* LexicalModuleMergesWithClass */); - } - function emitModuleDeclaration(node) { - // Emit only if this module is non-ambient. - var shouldEmit = shouldEmitModuleDeclaration(node); - if (!shouldEmit) { - return emitOnlyPinnedOrTripleSlashComments(node); - } - var hoistedInDeclarationScope = shouldHoistDeclarationInSystemJsModule(node); - var emitVarForModule = !hoistedInDeclarationScope && !isModuleMergedWithES6Class(node); - if (emitVarForModule) { - emitStart(node); - if (isES6ExportedDeclaration(node)) { - write("export "); - } - write("var "); - emit(node.name); - write(";"); - emitEnd(node); - writeLine(); - } - emitStart(node); - write("(function ("); - emitStart(node.name); - write(getGeneratedNameForNode(node)); - emitEnd(node.name); - write(") "); - if (node.body.kind === 209 /* ModuleBlock */) { - var saveTempFlags = tempFlags; - var saveTempVariables = tempVariables; - tempFlags = 0; - tempVariables = undefined; - emit(node.body); - tempFlags = saveTempFlags; - tempVariables = saveTempVariables; - } - else { - write("{"); - increaseIndent(); - scopeEmitStart(node); - emitCaptureThisForNodeIfNecessary(node); - writeLine(); - emit(node.body); - decreaseIndent(); - writeLine(); - var moduleBlock = getInnerMostModuleDeclarationFromDottedModule(node).body; - emitToken(15 /* CloseBraceToken */, moduleBlock.statements.end); - scopeEmitEnd(); - } - write(")("); - // write moduleDecl = containingModule.m only if it is not exported es6 module member - if ((node.flags & 1 /* Export */) && !isES6ExportedDeclaration(node)) { - emit(node.name); - write(" = "); - } - emitModuleMemberName(node); - write(" || ("); - emitModuleMemberName(node); - write(" = {}));"); - emitEnd(node); - if (!isES6ExportedDeclaration(node) && node.name.kind === 65 /* Identifier */ && node.parent === currentSourceFile) { - if (compilerOptions.module === 4 /* System */ && (node.flags & 1 /* Export */)) { - writeLine(); - write(exportFunctionForFile + "(\""); - emitDeclarationName(node); - write("\", "); - emitDeclarationName(node); - write(");"); - } - emitExportMemberAssignments(node.name); - } - } - function emitRequire(moduleName) { - if (moduleName.kind === 8 /* StringLiteral */) { - write("require("); - emitStart(moduleName); - emitLiteral(moduleName); - emitEnd(moduleName); - emitToken(17 /* CloseParenToken */, moduleName.end); - } - else { - write("require()"); - } - } - function getNamespaceDeclarationNode(node) { - if (node.kind === 211 /* ImportEqualsDeclaration */) { - return node; - } - var importClause = node.importClause; - if (importClause && importClause.namedBindings && importClause.namedBindings.kind === 214 /* NamespaceImport */) { - return importClause.namedBindings; - } - } - function isDefaultImport(node) { - return node.kind === 212 /* ImportDeclaration */ && node.importClause && !!node.importClause.name; - } - function emitExportImportAssignments(node) { - if (ts.isAliasSymbolDeclaration(node) && resolver.isValueAliasDeclaration(node)) { - emitExportMemberAssignments(node.name); - } - ts.forEachChild(node, emitExportImportAssignments); - } - function emitImportDeclaration(node) { - if (languageVersion < 2 /* ES6 */) { - return emitExternalImportDeclaration(node); - } - // ES6 import - if (node.importClause) { - var shouldEmitDefaultBindings = resolver.isReferencedAliasDeclaration(node.importClause); - var shouldEmitNamedBindings = node.importClause.namedBindings && resolver.isReferencedAliasDeclaration(node.importClause.namedBindings, true); - if (shouldEmitDefaultBindings || shouldEmitNamedBindings) { - write("import "); - emitStart(node.importClause); - if (shouldEmitDefaultBindings) { - emit(node.importClause.name); - if (shouldEmitNamedBindings) { - write(", "); - } - } - if (shouldEmitNamedBindings) { - emitLeadingComments(node.importClause.namedBindings); - emitStart(node.importClause.namedBindings); - if (node.importClause.namedBindings.kind === 214 /* NamespaceImport */) { - write("* as "); - emit(node.importClause.namedBindings.name); - } - else { - write("{ "); - emitExportOrImportSpecifierList(node.importClause.namedBindings.elements, resolver.isReferencedAliasDeclaration); - write(" }"); - } - emitEnd(node.importClause.namedBindings); - emitTrailingComments(node.importClause.namedBindings); - } - emitEnd(node.importClause); - write(" from "); - emit(node.moduleSpecifier); - write(";"); - } - } - else { - write("import "); - emit(node.moduleSpecifier); - write(";"); - } - } - function emitExternalImportDeclaration(node) { - if (ts.contains(externalImports, node)) { - var isExportedImport = node.kind === 211 /* ImportEqualsDeclaration */ && (node.flags & 1 /* Export */) !== 0; - var namespaceDeclaration = getNamespaceDeclarationNode(node); - if (compilerOptions.module !== 2 /* AMD */) { - emitLeadingComments(node); - emitStart(node); - if (namespaceDeclaration && !isDefaultImport(node)) { - // import x = require("foo") - // import * as x from "foo" - if (!isExportedImport) - write("var "); - emitModuleMemberName(namespaceDeclaration); - write(" = "); - } - else { - // import "foo" - // import x from "foo" - // import { x, y } from "foo" - // import d, * as x from "foo" - // import d, { x, y } from "foo" - var isNakedImport = 212 /* ImportDeclaration */ && !node.importClause; - if (!isNakedImport) { - write("var "); - write(getGeneratedNameForNode(node)); - write(" = "); - } - } - emitRequire(ts.getExternalModuleName(node)); - if (namespaceDeclaration && isDefaultImport(node)) { - // import d, * as x from "foo" - write(", "); - emitModuleMemberName(namespaceDeclaration); - write(" = "); - write(getGeneratedNameForNode(node)); - } - write(";"); - emitEnd(node); - emitExportImportAssignments(node); - emitTrailingComments(node); - } - else { - if (isExportedImport) { - emitModuleMemberName(namespaceDeclaration); - write(" = "); - emit(namespaceDeclaration.name); - write(";"); - } - else if (namespaceDeclaration && isDefaultImport(node)) { - // import d, * as x from "foo" - write("var "); - emitModuleMemberName(namespaceDeclaration); - write(" = "); - write(getGeneratedNameForNode(node)); - write(";"); - } - emitExportImportAssignments(node); - } - } - } - function emitImportEqualsDeclaration(node) { - if (ts.isExternalModuleImportEqualsDeclaration(node)) { - emitExternalImportDeclaration(node); - return; - } - // preserve old compiler's behavior: emit 'var' for import declaration (even if we do not consider them referenced) when - // - current file is not external module - // - import declaration is top level and target is value imported by entity name - if (resolver.isReferencedAliasDeclaration(node) || - (!ts.isExternalModule(currentSourceFile) && resolver.isTopLevelValueImportEqualsWithEntityName(node))) { - emitLeadingComments(node); - emitStart(node); - if (isES6ExportedDeclaration(node)) { - write("export "); - write("var "); - } - else if (!(node.flags & 1 /* Export */)) { - write("var "); - } - emitModuleMemberName(node); - write(" = "); - emit(node.moduleReference); - write(";"); - emitEnd(node); - emitExportImportAssignments(node); - emitTrailingComments(node); - } - } - function emitExportDeclaration(node) { - ts.Debug.assert(compilerOptions.module !== 4 /* System */); - if (languageVersion < 2 /* ES6 */) { - if (node.moduleSpecifier && (!node.exportClause || resolver.isValueAliasDeclaration(node))) { - emitStart(node); - var generatedName = getGeneratedNameForNode(node); - if (node.exportClause) { - // export { x, y, ... } from "foo" - if (compilerOptions.module !== 2 /* AMD */) { - write("var "); - write(generatedName); - write(" = "); - emitRequire(ts.getExternalModuleName(node)); - write(";"); - } - for (var _a = 0, _b = node.exportClause.elements; _a < _b.length; _a++) { - var specifier = _b[_a]; - if (resolver.isValueAliasDeclaration(specifier)) { - writeLine(); - emitStart(specifier); - emitContainingModuleName(specifier); - write("."); - emitNodeWithoutSourceMap(specifier.name); - write(" = "); - write(generatedName); - write("."); - emitNodeWithoutSourceMap(specifier.propertyName || specifier.name); - write(";"); - emitEnd(specifier); - } - } - } - else { - // export * from "foo" - writeLine(); - write("__export("); - if (compilerOptions.module !== 2 /* AMD */) { - emitRequire(ts.getExternalModuleName(node)); - } - else { - write(generatedName); - } - write(");"); - } - emitEnd(node); - } - } - else { - if (!node.exportClause || resolver.isValueAliasDeclaration(node)) { - emitStart(node); - write("export "); - if (node.exportClause) { - // export { x, y, ... } - write("{ "); - emitExportOrImportSpecifierList(node.exportClause.elements, resolver.isValueAliasDeclaration); - write(" }"); - } - else { - write("*"); - } - if (node.moduleSpecifier) { - write(" from "); - emitNodeWithoutSourceMap(node.moduleSpecifier); - } - write(";"); - emitEnd(node); - } - } - } - function emitExportOrImportSpecifierList(specifiers, shouldEmit) { - ts.Debug.assert(languageVersion >= 2 /* ES6 */); - var needsComma = false; - for (var _a = 0; _a < specifiers.length; _a++) { - var specifier = specifiers[_a]; - if (shouldEmit(specifier)) { - if (needsComma) { - write(", "); - } - emitStart(specifier); - if (specifier.propertyName) { - emitNodeWithoutSourceMap(specifier.propertyName); - write(" as "); - } - emitNodeWithoutSourceMap(specifier.name); - emitEnd(specifier); - needsComma = true; - } - } - } - function emitExportAssignment(node) { - if (!node.isExportEquals && resolver.isValueAliasDeclaration(node)) { - if (languageVersion >= 2 /* ES6 */) { - writeLine(); - emitStart(node); - write("export default "); - var expression = node.expression; - emit(expression); - if (expression.kind !== 203 /* FunctionDeclaration */ && - expression.kind !== 204 /* ClassDeclaration */) { - write(";"); - } - emitEnd(node); - } - else { - writeLine(); - emitStart(node); - if (compilerOptions.module === 4 /* System */) { - write(exportFunctionForFile + "(\"default\","); - emit(node.expression); - write(")"); - } - else { - emitContainingModuleName(node); - if (languageVersion === 0 /* ES3 */) { - write("[\"default\"] = "); - } - else { - write(".default = "); - } - emit(node.expression); - } - write(";"); - emitEnd(node); - } - } - } - function collectExternalModuleInfo(sourceFile) { - externalImports = []; - exportSpecifiers = {}; - exportEquals = undefined; - hasExportStars = false; - for (var _a = 0, _b = sourceFile.statements; _a < _b.length; _a++) { - var node = _b[_a]; - switch (node.kind) { - case 212 /* ImportDeclaration */: - if (!node.importClause || - resolver.isReferencedAliasDeclaration(node.importClause, true)) { - // import "mod" - // import x from "mod" where x is referenced - // import * as x from "mod" where x is referenced - // import { x, y } from "mod" where at least one import is referenced - externalImports.push(node); - } - break; - case 211 /* ImportEqualsDeclaration */: - if (node.moduleReference.kind === 222 /* ExternalModuleReference */ && resolver.isReferencedAliasDeclaration(node)) { - // import x = require("mod") where x is referenced - externalImports.push(node); - } - break; - case 218 /* ExportDeclaration */: - if (node.moduleSpecifier) { - if (!node.exportClause) { - // export * from "mod" - externalImports.push(node); - hasExportStars = true; - } - else if (resolver.isValueAliasDeclaration(node)) { - // export { x, y } from "mod" where at least one export is a value symbol - externalImports.push(node); - } - } - else { - // export { x, y } - for (var _c = 0, _d = node.exportClause.elements; _c < _d.length; _c++) { - var specifier = _d[_c]; - var name_24 = (specifier.propertyName || specifier.name).text; - (exportSpecifiers[name_24] || (exportSpecifiers[name_24] = [])).push(specifier); - } - } - break; - case 217 /* ExportAssignment */: - if (node.isExportEquals && !exportEquals) { - // export = x - exportEquals = node; - } - break; - } - } - } - function emitExportStarHelper() { - if (hasExportStars) { - writeLine(); - write("function __export(m) {"); - increaseIndent(); - writeLine(); - write("for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];"); - decreaseIndent(); - writeLine(); - write("}"); - } - } - function getLocalNameForExternalImport(node) { - var namespaceDeclaration = getNamespaceDeclarationNode(node); - if (namespaceDeclaration && !isDefaultImport(node)) { - return ts.getSourceTextOfNodeFromSourceFile(currentSourceFile, namespaceDeclaration.name); - } - if (node.kind === 212 /* ImportDeclaration */ && node.importClause) { - return getGeneratedNameForNode(node); - } - if (node.kind === 218 /* ExportDeclaration */ && node.moduleSpecifier) { - return getGeneratedNameForNode(node); - } - } - function getExternalModuleNameText(importNode) { - var moduleName = ts.getExternalModuleName(importNode); - if (moduleName.kind === 8 /* StringLiteral */) { - return getLiteralText(moduleName); - } - return undefined; - } - function emitVariableDeclarationsForImports() { - if (externalImports.length === 0) { - return; - } - writeLine(); - var started = false; - for (var _a = 0; _a < externalImports.length; _a++) { - var importNode = externalImports[_a]; - // do not create variable declaration for exports and imports that lack import clause - var skipNode = importNode.kind === 218 /* ExportDeclaration */ || - (importNode.kind === 212 /* ImportDeclaration */ && !importNode.importClause); - if (skipNode) { - continue; - } - if (!started) { - write("var "); - started = true; - } - else { - write(", "); - } - write(getLocalNameForExternalImport(importNode)); - } - if (started) { - write(";"); - } - } - function emitLocalStorageForExportedNamesIfNecessary(exportedDeclarations) { - // when resolving exports local exported entries/indirect exported entries in the module - // should always win over entries with similar names that were added via star exports - // to support this we store names of local/indirect exported entries in a set. - // this set is used to filter names brought by star expors. - if (!hasExportStars) { - // local names set is needed only in presence of star exports - return undefined; - } - // local names set should only be added if we have anything exported - if (!exportedDeclarations && ts.isEmpty(exportSpecifiers)) { - // no exported declarations (export var ...) or export specifiers (export {x}) - // check if we have any non star export declarations. - var hasExportDeclarationWithExportClause = false; - for (var _a = 0; _a < externalImports.length; _a++) { - var externalImport = externalImports[_a]; - if (externalImport.kind === 218 /* ExportDeclaration */ && externalImport.exportClause) { - hasExportDeclarationWithExportClause = true; - break; - } - } - if (!hasExportDeclarationWithExportClause) { - // we still need to emit exportStar helper - return emitExportStarFunction(undefined); - } - } - var exportedNamesStorageRef = makeUniqueName("exportedNames"); - writeLine(); - write("var " + exportedNamesStorageRef + " = {"); - increaseIndent(); - var started = false; - if (exportedDeclarations) { - for (var i = 0; i < exportedDeclarations.length; ++i) { - // write name of exported declaration, i.e 'export var x...' - writeExportedName(exportedDeclarations[i]); - } - } - if (exportSpecifiers) { - for (var n in exportSpecifiers) { - for (var _b = 0, _c = exportSpecifiers[n]; _b < _c.length; _b++) { - var specifier = _c[_b]; - // write name of export specified, i.e. 'export {x}' - writeExportedName(specifier.name); - } - } - } - for (var _d = 0; _d < externalImports.length; _d++) { - var externalImport = externalImports[_d]; - if (externalImport.kind !== 218 /* ExportDeclaration */) { - continue; - } - var exportDecl = externalImport; - if (!exportDecl.exportClause) { - // export * from ... - continue; - } - for (var _e = 0, _f = exportDecl.exportClause.elements; _e < _f.length; _e++) { - var element = _f[_e]; - // write name of indirectly exported entry, i.e. 'export {x} from ...' - writeExportedName(element.name || element.propertyName); - } - } - decreaseIndent(); - writeLine(); - write("};"); - return emitExportStarFunction(exportedNamesStorageRef); - function emitExportStarFunction(localNames) { - var exportStarFunction = makeUniqueName("exportStar"); - writeLine(); - // define an export star helper function - write("function " + exportStarFunction + "(m) {"); - increaseIndent(); - writeLine(); - write("for(var n in m) {"); - increaseIndent(); - writeLine(); - write("if (n !== \"default\""); - if (localNames) { - write("&& !" + localNames + ".hasOwnProperty(n)"); - } - write(") " + exportFunctionForFile + "(n, m[n]);"); - decreaseIndent(); - writeLine(); - write("}"); - decreaseIndent(); - writeLine(); - write("}"); - return exportStarFunction; - } - function writeExportedName(node) { - // do not record default exports - // they are local to module and never overwritten (explicitly skipped) by star export - if (node.kind !== 65 /* Identifier */ && node.flags & 256 /* Default */) { - return; - } - if (started) { - write(","); - } - else { - started = true; - } - writeLine(); - write("'"); - if (node.kind === 65 /* Identifier */) { - emitNodeWithoutSourceMap(node); - } - else { - emitDeclarationName(node); - } - write("': true"); - } - } - function processTopLevelVariableAndFunctionDeclarations(node) { - // per ES6 spec: - // 15.2.1.16.4 ModuleDeclarationInstantiation() Concrete Method - // - var declarations are initialized to undefined - 14.a.ii - // - function/generator declarations are instantiated - 16.a.iv - // this means that after module is instantiated but before its evaluation - // exported functions are already accessible at import sites - // in theory we should hoist only exported functions and its dependencies - // in practice to simplify things we'll hoist all source level functions and variable declaration - // including variables declarations for module and class declarations - var hoistedVars; - var hoistedFunctionDeclarations; - var exportedDeclarations; - visit(node); - if (hoistedVars) { - writeLine(); - write("var "); - var seen = {}; - for (var i = 0; i < hoistedVars.length; ++i) { - var local = hoistedVars[i]; - var name_25 = local.kind === 65 /* Identifier */ - ? local - : local.name; - if (name_25) { - // do not emit duplicate entries (in case of declaration merging) in the list of hoisted variables - var text = ts.unescapeIdentifier(name_25.text); - if (ts.hasProperty(seen, text)) { - continue; - } - else { - seen[text] = text; - } - } - if (i !== 0) { - write(", "); - } - if (local.kind === 204 /* ClassDeclaration */ || local.kind === 208 /* ModuleDeclaration */ || local.kind === 207 /* EnumDeclaration */) { - emitDeclarationName(local); - } - else { - emit(local); - } - var flags = ts.getCombinedNodeFlags(local.kind === 65 /* Identifier */ ? local.parent : local); - if (flags & 1 /* Export */) { - if (!exportedDeclarations) { - exportedDeclarations = []; - } - exportedDeclarations.push(local); - } - } - write(";"); - } - if (hoistedFunctionDeclarations) { - for (var _a = 0; _a < hoistedFunctionDeclarations.length; _a++) { - var f = hoistedFunctionDeclarations[_a]; - writeLine(); - emit(f); - if (f.flags & 1 /* Export */) { - if (!exportedDeclarations) { - exportedDeclarations = []; - } - exportedDeclarations.push(f); - } - } - } - return exportedDeclarations; - function visit(node) { - if (node.flags & 2 /* Ambient */) { - return; - } - if (node.kind === 203 /* FunctionDeclaration */) { - if (!hoistedFunctionDeclarations) { - hoistedFunctionDeclarations = []; - } - hoistedFunctionDeclarations.push(node); - return; - } - if (node.kind === 204 /* ClassDeclaration */) { - if (!hoistedVars) { - hoistedVars = []; - } - hoistedVars.push(node); - return; - } - if (node.kind === 207 /* EnumDeclaration */) { - if (shouldEmitEnumDeclaration(node)) { - if (!hoistedVars) { - hoistedVars = []; - } - hoistedVars.push(node); - } - return; - } - if (node.kind === 208 /* ModuleDeclaration */) { - if (shouldEmitModuleDeclaration(node)) { - if (!hoistedVars) { - hoistedVars = []; - } - hoistedVars.push(node); - } - return; - } - if (node.kind === 201 /* VariableDeclaration */ || node.kind === 155 /* BindingElement */) { - if (shouldHoistVariable(node, false)) { - var name_26 = node.name; - if (name_26.kind === 65 /* Identifier */) { - if (!hoistedVars) { - hoistedVars = []; - } - hoistedVars.push(name_26); - } - else { - ts.forEachChild(name_26, visit); - } - } - return; - } - if (ts.isBindingPattern(node)) { - ts.forEach(node.elements, visit); - return; - } - if (!ts.isDeclaration(node)) { - ts.forEachChild(node, visit); - } - } - } - function shouldHoistVariable(node, checkIfSourceFileLevelDecl) { - if (checkIfSourceFileLevelDecl && !shouldHoistDeclarationInSystemJsModule(node)) { - return false; - } - // hoist variable if - // - it is not block scoped - // - it is top level block scoped - // if block scoped variables are nested in some another block then - // no other functions can use them except ones that are defined at least in the same block - return (ts.getCombinedNodeFlags(node) & 12288 /* BlockScoped */) === 0 || - ts.getEnclosingBlockScopeContainer(node).kind === 230 /* SourceFile */; - } - function isCurrentFileSystemExternalModule() { - return compilerOptions.module === 4 /* System */ && ts.isExternalModule(currentSourceFile); - } - function emitSystemModuleBody(node, startIndex) { - // shape of the body in system modules: - // function (exports) { - // - // - // - // return { - // setters: [ - // - // ], - // execute: function() { - // - // } - // } - // - // } - // I.e: - // import {x} from 'file1' - // var y = 1; - // export function foo() { return y + x(); } - // console.log(y); - // will be transformed to - // function(exports) { - // var file1; // local alias - // var y; - // function foo() { return y + file1.x(); } - // exports("foo", foo); - // return { - // setters: [ - // function(v) { file1 = v } - // ], - // execute(): function() { - // y = 1; - // console.log(y); - // } - // }; - // } - emitVariableDeclarationsForImports(); - writeLine(); - var exportedDeclarations = processTopLevelVariableAndFunctionDeclarations(node); - var exportStarFunction = emitLocalStorageForExportedNamesIfNecessary(exportedDeclarations); - writeLine(); - write("return {"); - increaseIndent(); - writeLine(); - emitSetters(exportStarFunction); - writeLine(); - emitExecute(node, startIndex); - decreaseIndent(); - writeLine(); - write("}"); // return - emitTempDeclarations(true); - } - function emitSetters(exportStarFunction) { - write("setters:["); - for (var i = 0; i < externalImports.length; ++i) { - if (i !== 0) { - write(","); - } - writeLine(); - increaseIndent(); - var importNode = externalImports[i]; - var importVariableName = getLocalNameForExternalImport(importNode) || ""; - var parameterName = "_" + importVariableName; - write("function (" + parameterName + ") {"); - switch (importNode.kind) { - case 212 /* ImportDeclaration */: - if (!importNode.importClause) { - // 'import "..."' case - // module is imported only for side-effects, setter body will be empty - break; - } - // fall-through - case 211 /* ImportEqualsDeclaration */: - ts.Debug.assert(importVariableName !== ""); - increaseIndent(); - writeLine(); - // save import into the local - write(importVariableName + " = " + parameterName + ";"); - writeLine(); - var defaultName = importNode.kind === 212 /* ImportDeclaration */ - ? importNode.importClause.name - : importNode.name; - if (defaultName) { - // emit re-export for imported default name - // import n1 from 'foo1' - // import n2 = require('foo2') - // export {n1} - // export {n2} - emitExportMemberAssignments(defaultName); - writeLine(); - } - if (importNode.kind === 212 /* ImportDeclaration */ && - importNode.importClause.namedBindings) { - var namedBindings = importNode.importClause.namedBindings; - if (namedBindings.kind === 214 /* NamespaceImport */) { - // emit re-export for namespace - // import * as n from 'foo' - // export {n} - emitExportMemberAssignments(namedBindings.name); - writeLine(); - } - else { - // emit re-exports for named imports - // import {a, b} from 'foo' - // export {a, b as c} - for (var _a = 0, _b = namedBindings.elements; _a < _b.length; _a++) { - var element = _b[_a]; - emitExportMemberAssignments(element.name || element.propertyName); - writeLine(); - } - } - } - decreaseIndent(); - break; - case 218 /* ExportDeclaration */: - ts.Debug.assert(importVariableName !== ""); - increaseIndent(); - if (importNode.exportClause) { - // export {a, b as c} from 'foo' - // emit as: - // exports('a', _foo["a"]) - // exports('c', _foo["b"]) - for (var _c = 0, _d = importNode.exportClause.elements; _c < _d.length; _c++) { - var e = _d[_c]; - writeLine(); - write(exportFunctionForFile + "(\""); - emitNodeWithoutSourceMap(e.name); - write("\", " + parameterName + "[\""); - emitNodeWithoutSourceMap(e.propertyName || e.name); - write("\"]);"); - } - } - else { - writeLine(); - // export * from 'foo' - // emit as: - // exportStar(_foo); - write(exportStarFunction + "(" + parameterName + ");"); - } - writeLine(); - decreaseIndent(); - break; - } - write("}"); - decreaseIndent(); - } - write("],"); - } - function emitExecute(node, startIndex) { - write("execute: function() {"); - increaseIndent(); - writeLine(); - for (var i = startIndex; i < node.statements.length; ++i) { - var statement = node.statements[i]; - // - imports/exports are not emitted for system modules - // - function declarations are not emitted because they were already hoisted - switch (statement.kind) { - case 218 /* ExportDeclaration */: - case 212 /* ImportDeclaration */: - case 211 /* ImportEqualsDeclaration */: - case 203 /* FunctionDeclaration */: - continue; - } - writeLine(); - emit(statement); - } - decreaseIndent(); - writeLine(); - write("}"); // execute - } - function emitSystemModule(node, startIndex) { - collectExternalModuleInfo(node); - // System modules has the following shape - // System.register(['dep-1', ... 'dep-n'], function(exports) {/* module body function */}) - // 'exports' here is a function 'exports(name: string, value: T): T' that is used to publish exported values. - // 'exports' returns its 'value' argument so in most cases expressions - // that mutate exported values can be rewritten as: - // expr -> exports('name', expr). - // The only exception in this rule is postfix unary operators, - // see comment to 'emitPostfixUnaryExpression' for more details - ts.Debug.assert(!exportFunctionForFile); - // make sure that name of 'exports' function does not conflict with existing identifiers - exportFunctionForFile = makeUniqueName("exports"); - write("System.register("); - if (node.moduleName) { - write("\"" + node.moduleName + "\", "); - } - write("["); - for (var i = 0; i < externalImports.length; ++i) { - var text = getExternalModuleNameText(externalImports[i]); - if (i !== 0) { - write(", "); - } - write(text); - } - write("], function(" + exportFunctionForFile + ") {"); - writeLine(); - increaseIndent(); - emitCaptureThisForNodeIfNecessary(node); - emitSystemModuleBody(node, startIndex); - decreaseIndent(); - writeLine(); - write("});"); - } - function emitAMDDependencies(node, includeNonAmdDependencies) { - // An AMD define function has the following shape: - // define(id?, dependencies?, factory); - // - // This has the shape of - // define(name, ["module1", "module2"], function (module1Alias) { - // The location of the alias in the parameter list in the factory function needs to - // match the position of the module name in the dependency list. - // - // To ensure this is true in cases of modules with no aliases, e.g.: - // `import "module"` or `` - // we need to add modules without alias names to the end of the dependencies list - var aliasedModuleNames = []; // names of modules with corresponding parameter in the - // factory function. - var unaliasedModuleNames = []; // names of modules with no corresponding parameters in - // factory function. - var importAliasNames = []; // names of the parameters in the factory function; these - // parameters need to match the indexes of the corresponding - // module names in aliasedModuleNames. - // Fill in amd-dependency tags - for (var _a = 0, _b = node.amdDependencies; _a < _b.length; _a++) { - var amdDependency = _b[_a]; - if (amdDependency.name) { - aliasedModuleNames.push("\"" + amdDependency.path + "\""); - importAliasNames.push(amdDependency.name); - } - else { - unaliasedModuleNames.push("\"" + amdDependency.path + "\""); - } - } - for (var _c = 0; _c < externalImports.length; _c++) { - var importNode = externalImports[_c]; - // Find the name of the external module - var externalModuleName = getExternalModuleNameText(importNode); - // Find the name of the module alias, if there is one - var importAliasName = getLocalNameForExternalImport(importNode); - if (includeNonAmdDependencies && importAliasName) { - aliasedModuleNames.push(externalModuleName); - importAliasNames.push(importAliasName); - } - else { - unaliasedModuleNames.push(externalModuleName); - } - } - write("[\"require\", \"exports\""); - if (aliasedModuleNames.length) { - write(", "); - write(aliasedModuleNames.join(", ")); - } - if (unaliasedModuleNames.length) { - write(", "); - write(unaliasedModuleNames.join(", ")); - } - write("], function (require, exports"); - if (importAliasNames.length) { - write(", "); - write(importAliasNames.join(", ")); - } - } - function emitAMDModule(node, startIndex) { - collectExternalModuleInfo(node); - writeLine(); - write("define("); - if (node.moduleName) { - write("\"" + node.moduleName + "\", "); - } - emitAMDDependencies(node, true); - write(") {"); - increaseIndent(); - emitExportStarHelper(); - emitCaptureThisForNodeIfNecessary(node); - emitLinesStartingAt(node.statements, startIndex); - emitTempDeclarations(true); - emitExportEquals(true); - decreaseIndent(); - writeLine(); - write("});"); - } - function emitCommonJSModule(node, startIndex) { - collectExternalModuleInfo(node); - emitExportStarHelper(); - emitCaptureThisForNodeIfNecessary(node); - emitLinesStartingAt(node.statements, startIndex); - emitTempDeclarations(true); - emitExportEquals(false); - } - function emitUMDModule(node, startIndex) { - collectExternalModuleInfo(node); - // Module is detected first to support Browserify users that load into a browser with an AMD loader - writeLines("(function (deps, factory) {\n if (typeof module === 'object' && typeof module.exports === 'object') {\n var v = factory(require, exports); if (v !== undefined) module.exports = v;\n }\n else if (typeof define === 'function' && define.amd) {\n define(deps, factory);\n }\n})("); - emitAMDDependencies(node, false); - write(") {"); - increaseIndent(); - emitExportStarHelper(); - emitCaptureThisForNodeIfNecessary(node); - emitLinesStartingAt(node.statements, startIndex); - emitTempDeclarations(true); - emitExportEquals(true); - decreaseIndent(); - writeLine(); - write("});"); - } - function emitES6Module(node, startIndex) { - externalImports = undefined; - exportSpecifiers = undefined; - exportEquals = undefined; - hasExportStars = false; - emitCaptureThisForNodeIfNecessary(node); - emitLinesStartingAt(node.statements, startIndex); - emitTempDeclarations(true); - // Emit exportDefault if it exists will happen as part - // or normal statement emit. - } - function emitExportEquals(emitAsReturn) { - if (exportEquals && resolver.isValueAliasDeclaration(exportEquals)) { - writeLine(); - emitStart(exportEquals); - write(emitAsReturn ? "return " : "module.exports = "); - emit(exportEquals.expression); - write(";"); - emitEnd(exportEquals); - } - } - function emitDirectivePrologues(statements, startWithNewLine) { - for (var i = 0; i < statements.length; ++i) { - if (ts.isPrologueDirective(statements[i])) { - if (startWithNewLine || i > 0) { - writeLine(); - } - emit(statements[i]); - } - else { - // return index of the first non prologue directive - return i; - } - } - return statements.length; - } - function writeLines(text) { - var lines = text.split(/\r\n|\r|\n/g); - for (var i = 0; i < lines.length; ++i) { - var line = lines[i]; - if (line.length) { - writeLine(); - write(line); - } - } - } - function emitSourceFileNode(node) { - // Start new file on new line - writeLine(); - emitDetachedComments(node); - // emit prologue directives prior to __extends - var startIndex = emitDirectivePrologues(node.statements, false); - // Only emit helpers if the user did not say otherwise. - if (!compilerOptions.noEmitHelpers) { - // Only Emit __extends function when target ES5. - // For target ES6 and above, we can emit classDeclaration as is. - if ((languageVersion < 2 /* ES6 */) && (!extendsEmitted && resolver.getNodeCheckFlags(node) & 8 /* EmitExtends */)) { - writeLines(extendsHelper); - extendsEmitted = true; - } - if (!decorateEmitted && resolver.getNodeCheckFlags(node) & 512 /* EmitDecorate */) { - writeLines(decorateHelper); - if (compilerOptions.emitDecoratorMetadata) { - writeLines(metadataHelper); - } - decorateEmitted = true; - } - if (!paramEmitted && resolver.getNodeCheckFlags(node) & 1024 /* EmitParam */) { - writeLines(paramHelper); - paramEmitted = true; - } - } - if (ts.isExternalModule(node) || compilerOptions.isolatedModules) { - if (languageVersion >= 2 /* ES6 */) { - emitES6Module(node, startIndex); - } - else if (compilerOptions.module === 2 /* AMD */) { - emitAMDModule(node, startIndex); - } - else if (compilerOptions.module === 4 /* System */) { - emitSystemModule(node, startIndex); - } - else if (compilerOptions.module === 3 /* UMD */) { - emitUMDModule(node, startIndex); - } - else { - emitCommonJSModule(node, startIndex); - } - } - else { - externalImports = undefined; - exportSpecifiers = undefined; - exportEquals = undefined; - hasExportStars = false; - emitCaptureThisForNodeIfNecessary(node); - emitLinesStartingAt(node.statements, startIndex); - emitTempDeclarations(true); - } - emitLeadingComments(node.endOfFileToken); - } - function emitNodeWithoutSourceMap(node) { - if (!node) { - return; - } - if (node.flags & 2 /* Ambient */) { - return emitOnlyPinnedOrTripleSlashComments(node); - } - var emitComments = shouldEmitLeadingAndTrailingComments(node); - if (emitComments) { - emitLeadingComments(node); - } - emitJavaScriptWorker(node); - if (emitComments) { - emitTrailingComments(node); - } - } - function shouldEmitLeadingAndTrailingComments(node) { - switch (node.kind) { - // All of these entities are emitted in a specialized fashion. As such, we allow - // the specialized methods for each to handle the comments on the nodes. - case 205 /* InterfaceDeclaration */: - case 203 /* FunctionDeclaration */: - case 212 /* ImportDeclaration */: - case 211 /* ImportEqualsDeclaration */: - case 206 /* TypeAliasDeclaration */: - case 217 /* ExportAssignment */: - return false; - case 183 /* VariableStatement */: - return shouldEmitLeadingAndTrailingCommentsForVariableStatement(node); - case 208 /* ModuleDeclaration */: - // Only emit the leading/trailing comments for a module if we're actually - // emitting the module as well. - return shouldEmitModuleDeclaration(node); - case 207 /* EnumDeclaration */: - // Only emit the leading/trailing comments for an enum if we're actually - // emitting the module as well. - return shouldEmitEnumDeclaration(node); - } - // If this is the expression body of an arrow function that we're down-leveling, - // then we don't want to emit comments when we emit the body. It will have already - // been taken care of when we emitted the 'return' statement for the function - // expression body. - if (node.kind !== 182 /* Block */ && - node.parent && - node.parent.kind === 166 /* ArrowFunction */ && - node.parent.body === node && - compilerOptions.target <= 1 /* ES5 */) { - return false; - } - // Emit comments for everything else. - return true; - } - function emitJavaScriptWorker(node) { - // Check if the node can be emitted regardless of the ScriptTarget - switch (node.kind) { - case 65 /* Identifier */: - return emitIdentifier(node); - case 131 /* Parameter */: - return emitParameter(node); - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - return emitMethod(node); - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - return emitAccessor(node); - case 93 /* ThisKeyword */: - return emitThis(node); - case 91 /* SuperKeyword */: - return emitSuper(node); - case 89 /* NullKeyword */: - return write("null"); - case 95 /* TrueKeyword */: - return write("true"); - case 80 /* FalseKeyword */: - return write("false"); - case 7 /* NumericLiteral */: - case 8 /* StringLiteral */: - case 9 /* RegularExpressionLiteral */: - case 10 /* NoSubstitutionTemplateLiteral */: - case 11 /* TemplateHead */: - case 12 /* TemplateMiddle */: - case 13 /* TemplateTail */: - return emitLiteral(node); - case 174 /* TemplateExpression */: - return emitTemplateExpression(node); - case 180 /* TemplateSpan */: - return emitTemplateSpan(node); - case 128 /* QualifiedName */: - return emitQualifiedName(node); - case 153 /* ObjectBindingPattern */: - return emitObjectBindingPattern(node); - case 154 /* ArrayBindingPattern */: - return emitArrayBindingPattern(node); - case 155 /* BindingElement */: - return emitBindingElement(node); - case 156 /* ArrayLiteralExpression */: - return emitArrayLiteral(node); - case 157 /* ObjectLiteralExpression */: - return emitObjectLiteral(node); - case 227 /* PropertyAssignment */: - return emitPropertyAssignment(node); - case 228 /* ShorthandPropertyAssignment */: - return emitShorthandPropertyAssignment(node); - case 129 /* ComputedPropertyName */: - return emitComputedPropertyName(node); - case 158 /* PropertyAccessExpression */: - return emitPropertyAccess(node); - case 159 /* ElementAccessExpression */: - return emitIndexedAccess(node); - case 160 /* CallExpression */: - return emitCallExpression(node); - case 161 /* NewExpression */: - return emitNewExpression(node); - case 162 /* TaggedTemplateExpression */: - return emitTaggedTemplateExpression(node); - case 163 /* TypeAssertionExpression */: - return emit(node.expression); - case 164 /* ParenthesizedExpression */: - return emitParenExpression(node); - case 203 /* FunctionDeclaration */: - case 165 /* FunctionExpression */: - case 166 /* ArrowFunction */: - return emitFunctionDeclaration(node); - case 167 /* DeleteExpression */: - return emitDeleteExpression(node); - case 168 /* TypeOfExpression */: - return emitTypeOfExpression(node); - case 169 /* VoidExpression */: - return emitVoidExpression(node); - case 170 /* PrefixUnaryExpression */: - return emitPrefixUnaryExpression(node); - case 171 /* PostfixUnaryExpression */: - return emitPostfixUnaryExpression(node); - case 172 /* BinaryExpression */: - return emitBinaryExpression(node); - case 173 /* ConditionalExpression */: - return emitConditionalExpression(node); - case 176 /* SpreadElementExpression */: - return emitSpreadElementExpression(node); - case 175 /* YieldExpression */: - return emitYieldExpression(node); - case 178 /* OmittedExpression */: - return; - case 182 /* Block */: - case 209 /* ModuleBlock */: - return emitBlock(node); - case 183 /* VariableStatement */: - return emitVariableStatement(node); - case 184 /* EmptyStatement */: - return write(";"); - case 185 /* ExpressionStatement */: - return emitExpressionStatement(node); - case 186 /* IfStatement */: - return emitIfStatement(node); - case 187 /* DoStatement */: - return emitDoStatement(node); - case 188 /* WhileStatement */: - return emitWhileStatement(node); - case 189 /* ForStatement */: - return emitForStatement(node); - case 191 /* ForOfStatement */: - case 190 /* ForInStatement */: - return emitForInOrForOfStatement(node); - case 192 /* ContinueStatement */: - case 193 /* BreakStatement */: - return emitBreakOrContinueStatement(node); - case 194 /* ReturnStatement */: - return emitReturnStatement(node); - case 195 /* WithStatement */: - return emitWithStatement(node); - case 196 /* SwitchStatement */: - return emitSwitchStatement(node); - case 223 /* CaseClause */: - case 224 /* DefaultClause */: - return emitCaseOrDefaultClause(node); - case 197 /* LabeledStatement */: - return emitLabelledStatement(node); - case 198 /* ThrowStatement */: - return emitThrowStatement(node); - case 199 /* TryStatement */: - return emitTryStatement(node); - case 226 /* CatchClause */: - return emitCatchClause(node); - case 200 /* DebuggerStatement */: - return emitDebuggerStatement(node); - case 201 /* VariableDeclaration */: - return emitVariableDeclaration(node); - case 177 /* ClassExpression */: - return emitClassExpression(node); - case 204 /* ClassDeclaration */: - return emitClassDeclaration(node); - case 205 /* InterfaceDeclaration */: - return emitInterfaceDeclaration(node); - case 207 /* EnumDeclaration */: - return emitEnumDeclaration(node); - case 229 /* EnumMember */: - return emitEnumMember(node); - case 208 /* ModuleDeclaration */: - return emitModuleDeclaration(node); - case 212 /* ImportDeclaration */: - return emitImportDeclaration(node); - case 211 /* ImportEqualsDeclaration */: - return emitImportEqualsDeclaration(node); - case 218 /* ExportDeclaration */: - return emitExportDeclaration(node); - case 217 /* ExportAssignment */: - return emitExportAssignment(node); - case 230 /* SourceFile */: - return emitSourceFileNode(node); - } - } - function hasDetachedComments(pos) { - return detachedCommentsInfo !== undefined && ts.lastOrUndefined(detachedCommentsInfo).nodePos === pos; - } - function getLeadingCommentsWithoutDetachedComments() { - // get the leading comments from detachedPos - var leadingComments = ts.getLeadingCommentRanges(currentSourceFile.text, ts.lastOrUndefined(detachedCommentsInfo).detachedCommentEndPos); - if (detachedCommentsInfo.length - 1) { - detachedCommentsInfo.pop(); - } - else { - detachedCommentsInfo = undefined; - } - return leadingComments; - } - function filterComments(ranges, onlyPinnedOrTripleSlashComments) { - // If we're removing comments, then we want to strip out all but the pinned or - // triple slash comments. - if (ranges && onlyPinnedOrTripleSlashComments) { - ranges = ts.filter(ranges, isPinnedOrTripleSlashComment); - if (ranges.length === 0) { - return undefined; - } - } - return ranges; - } - function getLeadingCommentsToEmit(node) { - // Emit the leading comments only if the parent's pos doesn't match because parent should take care of emitting these comments - if (node.parent) { - if (node.parent.kind === 230 /* SourceFile */ || node.pos !== node.parent.pos) { - if (hasDetachedComments(node.pos)) { - // get comments without detached comments - return getLeadingCommentsWithoutDetachedComments(); - } - else { - // get the leading comments from the node - return ts.getLeadingCommentRangesOfNode(node, currentSourceFile); - } - } - } - } - function getTrailingCommentsToEmit(node) { - // Emit the trailing comments only if the parent's pos doesn't match because parent should take care of emitting these comments - if (node.parent) { - if (node.parent.kind === 230 /* SourceFile */ || node.end !== node.parent.end) { - return ts.getTrailingCommentRanges(currentSourceFile.text, node.end); - } - } - } - function emitOnlyPinnedOrTripleSlashComments(node) { - emitLeadingCommentsWorker(node, true); - } - function emitLeadingComments(node) { - return emitLeadingCommentsWorker(node, compilerOptions.removeComments); - } - function emitLeadingCommentsWorker(node, onlyPinnedOrTripleSlashComments) { - // If the caller only wants pinned or triple slash comments, then always filter - // down to that set. Otherwise, filter based on the current compiler options. - var leadingComments = filterComments(getLeadingCommentsToEmit(node), onlyPinnedOrTripleSlashComments); - ts.emitNewLineBeforeLeadingComments(currentSourceFile, writer, node, leadingComments); - // Leading comments are emitted at /*leading comment1 */space/*leading comment*/space - ts.emitComments(currentSourceFile, writer, leadingComments, true, newLine, writeComment); - } - function emitTrailingComments(node) { - // Emit the trailing comments only if the parent's end doesn't match - var trailingComments = filterComments(getTrailingCommentsToEmit(node), compilerOptions.removeComments); - // trailing comments are emitted at space/*trailing comment1 */space/*trailing comment*/ - ts.emitComments(currentSourceFile, writer, trailingComments, false, newLine, writeComment); - } - function emitLeadingCommentsOfPosition(pos) { - var leadingComments; - if (hasDetachedComments(pos)) { - // get comments without detached comments - leadingComments = getLeadingCommentsWithoutDetachedComments(); - } - else { - // get the leading comments from the node - leadingComments = ts.getLeadingCommentRanges(currentSourceFile.text, pos); - } - leadingComments = filterComments(leadingComments, compilerOptions.removeComments); - ts.emitNewLineBeforeLeadingComments(currentSourceFile, writer, { pos: pos, end: pos }, leadingComments); - // Leading comments are emitted at /*leading comment1 */space/*leading comment*/space - ts.emitComments(currentSourceFile, writer, leadingComments, true, newLine, writeComment); - } - function emitDetachedComments(node) { - var leadingComments = ts.getLeadingCommentRanges(currentSourceFile.text, node.pos); - if (leadingComments) { - var detachedComments = []; - var lastComment; - ts.forEach(leadingComments, function (comment) { - if (lastComment) { - var lastCommentLine = ts.getLineOfLocalPosition(currentSourceFile, lastComment.end); - var commentLine = ts.getLineOfLocalPosition(currentSourceFile, comment.pos); - if (commentLine >= lastCommentLine + 2) { - // There was a blank line between the last comment and this comment. This - // comment is not part of the copyright comments. Return what we have so - // far. - return detachedComments; - } - } - detachedComments.push(comment); - lastComment = comment; - }); - if (detachedComments.length) { - // All comments look like they could have been part of the copyright header. Make - // sure there is at least one blank line between it and the node. If not, it's not - // a copyright header. - var lastCommentLine = ts.getLineOfLocalPosition(currentSourceFile, ts.lastOrUndefined(detachedComments).end); - var nodeLine = ts.getLineOfLocalPosition(currentSourceFile, ts.skipTrivia(currentSourceFile.text, node.pos)); - if (nodeLine >= lastCommentLine + 2) { - // Valid detachedComments - ts.emitNewLineBeforeLeadingComments(currentSourceFile, writer, node, leadingComments); - ts.emitComments(currentSourceFile, writer, detachedComments, true, newLine, writeComment); - var currentDetachedCommentInfo = { nodePos: node.pos, detachedCommentEndPos: ts.lastOrUndefined(detachedComments).end }; - if (detachedCommentsInfo) { - detachedCommentsInfo.push(currentDetachedCommentInfo); - } - else { - detachedCommentsInfo = [currentDetachedCommentInfo]; - } - } - } - } - } - function isPinnedOrTripleSlashComment(comment) { - if (currentSourceFile.text.charCodeAt(comment.pos + 1) === 42 /* asterisk */) { - return currentSourceFile.text.charCodeAt(comment.pos + 2) === 33 /* exclamation */; - } - else if (currentSourceFile.text.charCodeAt(comment.pos + 1) === 47 /* slash */ && - comment.pos + 2 < comment.end && - currentSourceFile.text.charCodeAt(comment.pos + 2) === 47 /* slash */ && - currentSourceFile.text.substring(comment.pos, comment.end).match(ts.fullTripleSlashReferencePathRegEx)) { - return true; - } - } - } - function emitFile(jsFilePath, sourceFile) { - emitJavaScript(jsFilePath, sourceFile); - if (compilerOptions.declaration) { - ts.writeDeclarationFile(jsFilePath, sourceFile, host, resolver, diagnostics); - } - } - } - ts.emitFiles = emitFiles; -})(ts || (ts = {})); -/// -/// -var ts; -(function (ts) { - /* @internal */ ts.programTime = 0; - /* @internal */ ts.emitTime = 0; - /* @internal */ ts.ioReadTime = 0; - /* @internal */ ts.ioWriteTime = 0; - /** The version of the TypeScript compiler release */ - ts.version = "1.5.3"; - function findConfigFile(searchPath) { - var fileName = "tsconfig.json"; - while (true) { - if (ts.sys.fileExists(fileName)) { - return fileName; - } - var parentPath = ts.getDirectoryPath(searchPath); - if (parentPath === searchPath) { - break; - } - searchPath = parentPath; - fileName = "../" + fileName; - } - return undefined; - } - ts.findConfigFile = findConfigFile; - function createCompilerHost(options, setParentNodes) { - var currentDirectory; - var existingDirectories = {}; - function getCanonicalFileName(fileName) { - // if underlying system can distinguish between two files whose names differs only in cases then file name already in canonical form. - // otherwise use toLowerCase as a canonical form. - return ts.sys.useCaseSensitiveFileNames ? fileName : fileName.toLowerCase(); - } - // returned by CScript sys environment - var unsupportedFileEncodingErrorCode = -2147024809; - function getSourceFile(fileName, languageVersion, onError) { - var text; - try { - var start = new Date().getTime(); - text = ts.sys.readFile(fileName, options.charset); - ts.ioReadTime += new Date().getTime() - start; - } - catch (e) { - if (onError) { - onError(e.number === unsupportedFileEncodingErrorCode - ? ts.createCompilerDiagnostic(ts.Diagnostics.Unsupported_file_encoding).messageText - : e.message); - } - text = ""; - } - return text !== undefined ? ts.createSourceFile(fileName, text, languageVersion, setParentNodes) : undefined; - } - function directoryExists(directoryPath) { - if (ts.hasProperty(existingDirectories, directoryPath)) { - return true; - } - if (ts.sys.directoryExists(directoryPath)) { - existingDirectories[directoryPath] = true; - return true; - } - return false; - } - function ensureDirectoriesExist(directoryPath) { - if (directoryPath.length > ts.getRootLength(directoryPath) && !directoryExists(directoryPath)) { - var parentDirectory = ts.getDirectoryPath(directoryPath); - ensureDirectoriesExist(parentDirectory); - ts.sys.createDirectory(directoryPath); - } - } - function writeFile(fileName, data, writeByteOrderMark, onError) { - try { - var start = new Date().getTime(); - ensureDirectoriesExist(ts.getDirectoryPath(ts.normalizePath(fileName))); - ts.sys.writeFile(fileName, data, writeByteOrderMark); - ts.ioWriteTime += new Date().getTime() - start; - } - catch (e) { - if (onError) { - onError(e.message); - } - } - } - var newLine = ts.getNewLineCharacter(options); - return { - getSourceFile: getSourceFile, - getDefaultLibFileName: function (options) { return ts.combinePaths(ts.getDirectoryPath(ts.normalizePath(ts.sys.getExecutingFilePath())), ts.getDefaultLibFileName(options)); }, - writeFile: writeFile, - getCurrentDirectory: function () { return currentDirectory || (currentDirectory = ts.sys.getCurrentDirectory()); }, - useCaseSensitiveFileNames: function () { return ts.sys.useCaseSensitiveFileNames; }, - getCanonicalFileName: getCanonicalFileName, - getNewLine: function () { return newLine; } - }; - } - ts.createCompilerHost = createCompilerHost; - function getPreEmitDiagnostics(program, sourceFile) { - var diagnostics = program.getSyntacticDiagnostics(sourceFile).concat(program.getGlobalDiagnostics()).concat(program.getSemanticDiagnostics(sourceFile)); - if (program.getCompilerOptions().declaration) { - diagnostics.concat(program.getDeclarationDiagnostics(sourceFile)); - } - return ts.sortAndDeduplicateDiagnostics(diagnostics); - } - ts.getPreEmitDiagnostics = getPreEmitDiagnostics; - function flattenDiagnosticMessageText(messageText, newLine) { - if (typeof messageText === "string") { - return messageText; - } - else { - var diagnosticChain = messageText; - var result = ""; - var indent = 0; - while (diagnosticChain) { - if (indent) { - result += newLine; - for (var i = 0; i < indent; i++) { - result += " "; - } - } - result += diagnosticChain.messageText; - indent++; - diagnosticChain = diagnosticChain.next; - } - return result; - } - } - ts.flattenDiagnosticMessageText = flattenDiagnosticMessageText; - function createProgram(rootNames, options, host) { - var program; - var files = []; - var diagnostics = ts.createDiagnosticCollection(); - var commonSourceDirectory; - var diagnosticsProducingTypeChecker; - var noDiagnosticsTypeChecker; - var classifiableNames; - var skipDefaultLib = options.noLib; - var start = new Date().getTime(); - host = host || createCompilerHost(options); - var filesByName = ts.createFileMap(function (fileName) { return host.getCanonicalFileName(fileName); }); - ts.forEach(rootNames, function (name) { return processRootFile(name, false); }); - // Do not process the default library if: - // - The '--noLib' flag is used. - // - A 'no-default-lib' reference comment is encountered in - // processing the root files. - if (!skipDefaultLib) { - processRootFile(host.getDefaultLibFileName(options), true); - } - verifyCompilerOptions(); - ts.programTime += new Date().getTime() - start; - program = { - getSourceFile: getSourceFile, - getSourceFiles: function () { return files; }, - getCompilerOptions: function () { return options; }, - getSyntacticDiagnostics: getSyntacticDiagnostics, - getGlobalDiagnostics: getGlobalDiagnostics, - getSemanticDiagnostics: getSemanticDiagnostics, - getDeclarationDiagnostics: getDeclarationDiagnostics, - getCompilerOptionsDiagnostics: getCompilerOptionsDiagnostics, - getTypeChecker: getTypeChecker, - getClassifiableNames: getClassifiableNames, - getDiagnosticsProducingTypeChecker: getDiagnosticsProducingTypeChecker, - getCommonSourceDirectory: function () { return commonSourceDirectory; }, - emit: emit, - getCurrentDirectory: function () { return host.getCurrentDirectory(); }, - getNodeCount: function () { return getDiagnosticsProducingTypeChecker().getNodeCount(); }, - getIdentifierCount: function () { return getDiagnosticsProducingTypeChecker().getIdentifierCount(); }, - getSymbolCount: function () { return getDiagnosticsProducingTypeChecker().getSymbolCount(); }, - getTypeCount: function () { return getDiagnosticsProducingTypeChecker().getTypeCount(); } - }; - return program; - function getClassifiableNames() { - if (!classifiableNames) { - // Initialize a checker so that all our files are bound. - getTypeChecker(); - classifiableNames = {}; - for (var _i = 0; _i < files.length; _i++) { - var sourceFile = files[_i]; - ts.copyMap(sourceFile.classifiableNames, classifiableNames); - } - } - return classifiableNames; - } - function getEmitHost(writeFileCallback) { - return { - getCanonicalFileName: function (fileName) { return host.getCanonicalFileName(fileName); }, - getCommonSourceDirectory: program.getCommonSourceDirectory, - getCompilerOptions: program.getCompilerOptions, - getCurrentDirectory: function () { return host.getCurrentDirectory(); }, - getNewLine: function () { return host.getNewLine(); }, - getSourceFile: program.getSourceFile, - getSourceFiles: program.getSourceFiles, - writeFile: writeFileCallback || (function (fileName, data, writeByteOrderMark, onError) { return host.writeFile(fileName, data, writeByteOrderMark, onError); }) - }; - } - function getDiagnosticsProducingTypeChecker() { - return diagnosticsProducingTypeChecker || (diagnosticsProducingTypeChecker = ts.createTypeChecker(program, true)); - } - function getTypeChecker() { - return noDiagnosticsTypeChecker || (noDiagnosticsTypeChecker = ts.createTypeChecker(program, false)); - } - function emit(sourceFile, writeFileCallback) { - // If the noEmitOnError flag is set, then check if we have any errors so far. If so, - // immediately bail out. - if (options.noEmitOnError && getPreEmitDiagnostics(this).length > 0) { - return { diagnostics: [], sourceMaps: undefined, emitSkipped: true }; - } - // Create the emit resolver outside of the "emitTime" tracking code below. That way - // any cost associated with it (like type checking) are appropriate associated with - // the type-checking counter. - // - // If the -out option is specified, we should not pass the source file to getEmitResolver. - // This is because in the -out scenario all files need to be emitted, and therefore all - // files need to be type checked. And the way to specify that all files need to be type - // checked is to not pass the file to getEmitResolver. - var emitResolver = getDiagnosticsProducingTypeChecker().getEmitResolver(options.out ? undefined : sourceFile); - var start = new Date().getTime(); - var emitResult = ts.emitFiles(emitResolver, getEmitHost(writeFileCallback), sourceFile); - ts.emitTime += new Date().getTime() - start; - return emitResult; - } - function getSourceFile(fileName) { - return filesByName.get(fileName); - } - function getDiagnosticsHelper(sourceFile, getDiagnostics) { - if (sourceFile) { - return getDiagnostics(sourceFile); - } - var allDiagnostics = []; - ts.forEach(program.getSourceFiles(), function (sourceFile) { - ts.addRange(allDiagnostics, getDiagnostics(sourceFile)); - }); - return ts.sortAndDeduplicateDiagnostics(allDiagnostics); - } - function getSyntacticDiagnostics(sourceFile) { - return getDiagnosticsHelper(sourceFile, getSyntacticDiagnosticsForFile); - } - function getSemanticDiagnostics(sourceFile) { - return getDiagnosticsHelper(sourceFile, getSemanticDiagnosticsForFile); - } - function getDeclarationDiagnostics(sourceFile) { - return getDiagnosticsHelper(sourceFile, getDeclarationDiagnosticsForFile); - } - function getSyntacticDiagnosticsForFile(sourceFile) { - return sourceFile.parseDiagnostics; - } - function getSemanticDiagnosticsForFile(sourceFile) { - var typeChecker = getDiagnosticsProducingTypeChecker(); - ts.Debug.assert(!!sourceFile.bindDiagnostics); - var bindDiagnostics = sourceFile.bindDiagnostics; - var checkDiagnostics = typeChecker.getDiagnostics(sourceFile); - var programDiagnostics = diagnostics.getDiagnostics(sourceFile.fileName); - return bindDiagnostics.concat(checkDiagnostics).concat(programDiagnostics); - } - function getDeclarationDiagnosticsForFile(sourceFile) { - if (!ts.isDeclarationFile(sourceFile)) { - var resolver = getDiagnosticsProducingTypeChecker().getEmitResolver(sourceFile); - // Don't actually write any files since we're just getting diagnostics. - var writeFile = function () { }; - return ts.getDeclarationDiagnostics(getEmitHost(writeFile), resolver, sourceFile); - } - } - function getCompilerOptionsDiagnostics() { - var allDiagnostics = []; - ts.addRange(allDiagnostics, diagnostics.getGlobalDiagnostics()); - return ts.sortAndDeduplicateDiagnostics(allDiagnostics); - } - function getGlobalDiagnostics() { - var typeChecker = getDiagnosticsProducingTypeChecker(); - var allDiagnostics = []; - ts.addRange(allDiagnostics, typeChecker.getGlobalDiagnostics()); - ts.addRange(allDiagnostics, diagnostics.getGlobalDiagnostics()); - return ts.sortAndDeduplicateDiagnostics(allDiagnostics); - } - function hasExtension(fileName) { - return ts.getBaseFileName(fileName).indexOf(".") >= 0; - } - function processRootFile(fileName, isDefaultLib) { - processSourceFile(ts.normalizePath(fileName), isDefaultLib); - } - function processSourceFile(fileName, isDefaultLib, refFile, refPos, refEnd) { - var start; - var length; - var extensions; - var diagnosticArgument; - if (refEnd !== undefined && refPos !== undefined) { - start = refPos; - length = refEnd - refPos; - } - var diagnostic; - if (hasExtension(fileName)) { - if (!options.allowNonTsExtensions && !ts.forEach(ts.supportedExtensions, function (extension) { return ts.fileExtensionIs(host.getCanonicalFileName(fileName), extension); })) { - diagnostic = ts.Diagnostics.File_0_has_unsupported_extension_The_only_supported_extensions_are_1; - diagnosticArgument = [fileName, "'" + ts.supportedExtensions.join("', '") + "'"]; - } - else if (!findSourceFile(fileName, isDefaultLib, refFile, refPos, refEnd)) { - diagnostic = ts.Diagnostics.File_0_not_found; - diagnosticArgument = [fileName]; - } - else if (refFile && host.getCanonicalFileName(fileName) === host.getCanonicalFileName(refFile.fileName)) { - diagnostic = ts.Diagnostics.A_file_cannot_have_a_reference_to_itself; - diagnosticArgument = [fileName]; - } - } - else { - var nonTsFile = options.allowNonTsExtensions && findSourceFile(fileName, isDefaultLib, refFile, refPos, refEnd); - if (!nonTsFile) { - if (options.allowNonTsExtensions) { - diagnostic = ts.Diagnostics.File_0_not_found; - diagnosticArgument = [fileName]; - } - else if (!ts.forEach(ts.supportedExtensions, function (extension) { return findSourceFile(fileName + extension, isDefaultLib, refFile, refPos, refEnd); })) { - diagnostic = ts.Diagnostics.File_0_not_found; - fileName += ".ts"; - diagnosticArgument = [fileName]; - } - } - } - if (diagnostic) { - if (refFile) { - diagnostics.add(ts.createFileDiagnostic.apply(void 0, [refFile, start, length, diagnostic].concat(diagnosticArgument))); - } - else { - diagnostics.add(ts.createCompilerDiagnostic.apply(void 0, [diagnostic].concat(diagnosticArgument))); - } - } - } - // Get source file from normalized fileName - function findSourceFile(fileName, isDefaultLib, refFile, refStart, refLength) { - var canonicalName = host.getCanonicalFileName(ts.normalizeSlashes(fileName)); - if (filesByName.contains(canonicalName)) { - // We've already looked for this file, use cached result - return getSourceFileFromCache(fileName, canonicalName, false); - } - else { - var normalizedAbsolutePath = ts.getNormalizedAbsolutePath(fileName, host.getCurrentDirectory()); - var canonicalAbsolutePath = host.getCanonicalFileName(normalizedAbsolutePath); - if (filesByName.contains(canonicalAbsolutePath)) { - return getSourceFileFromCache(normalizedAbsolutePath, canonicalAbsolutePath, true); - } - // We haven't looked for this file, do so now and cache result - var file = host.getSourceFile(fileName, options.target, function (hostErrorMessage) { - if (refFile) { - diagnostics.add(ts.createFileDiagnostic(refFile, refStart, refLength, ts.Diagnostics.Cannot_read_file_0_Colon_1, fileName, hostErrorMessage)); - } - else { - diagnostics.add(ts.createCompilerDiagnostic(ts.Diagnostics.Cannot_read_file_0_Colon_1, fileName, hostErrorMessage)); - } - }); - filesByName.set(canonicalName, file); - if (file) { - skipDefaultLib = skipDefaultLib || file.hasNoDefaultLib; - // Set the source file for normalized absolute path - filesByName.set(canonicalAbsolutePath, file); - if (!options.noResolve) { - var basePath = ts.getDirectoryPath(fileName); - processReferencedFiles(file, basePath); - processImportedModules(file, basePath); - } - if (isDefaultLib) { - file.isDefaultLib = true; - files.unshift(file); - } - else { - files.push(file); - } - } - return file; - } - function getSourceFileFromCache(fileName, canonicalName, useAbsolutePath) { - var file = filesByName.get(canonicalName); - if (file && host.useCaseSensitiveFileNames()) { - var sourceFileName = useAbsolutePath ? ts.getNormalizedAbsolutePath(file.fileName, host.getCurrentDirectory()) : file.fileName; - if (canonicalName !== sourceFileName) { - diagnostics.add(ts.createFileDiagnostic(refFile, refStart, refLength, ts.Diagnostics.File_name_0_differs_from_already_included_file_name_1_only_in_casing, fileName, sourceFileName)); - } - } - return file; - } - } - function processReferencedFiles(file, basePath) { - ts.forEach(file.referencedFiles, function (ref) { - var referencedFileName = ts.isRootedDiskPath(ref.fileName) ? ref.fileName : ts.combinePaths(basePath, ref.fileName); - processSourceFile(ts.normalizePath(referencedFileName), false, file, ref.pos, ref.end); - }); - } - function processImportedModules(file, basePath) { - ts.forEach(file.statements, function (node) { - if (node.kind === 212 /* ImportDeclaration */ || node.kind === 211 /* ImportEqualsDeclaration */ || node.kind === 218 /* ExportDeclaration */) { - var moduleNameExpr = ts.getExternalModuleName(node); - if (moduleNameExpr && moduleNameExpr.kind === 8 /* StringLiteral */) { - var moduleNameText = moduleNameExpr.text; - if (moduleNameText) { - var searchPath = basePath; - var searchName; - while (true) { - searchName = ts.normalizePath(ts.combinePaths(searchPath, moduleNameText)); - if (ts.forEach(ts.supportedExtensions, function (extension) { return findModuleSourceFile(searchName + extension, moduleNameExpr); })) { - break; - } - var parentPath = ts.getDirectoryPath(searchPath); - if (parentPath === searchPath) { - break; - } - searchPath = parentPath; - } - } - } - } - else if (node.kind === 208 /* ModuleDeclaration */ && node.name.kind === 8 /* StringLiteral */ && (node.flags & 2 /* Ambient */ || ts.isDeclarationFile(file))) { - // TypeScript 1.0 spec (April 2014): 12.1.6 - // An AmbientExternalModuleDeclaration declares an external module. - // This type of declaration is permitted only in the global module. - // The StringLiteral must specify a top - level external module name. - // Relative external module names are not permitted - ts.forEachChild(node.body, function (node) { - if (ts.isExternalModuleImportEqualsDeclaration(node) && - ts.getExternalModuleImportEqualsDeclarationExpression(node).kind === 8 /* StringLiteral */) { - var nameLiteral = ts.getExternalModuleImportEqualsDeclarationExpression(node); - var moduleName = nameLiteral.text; - if (moduleName) { - // TypeScript 1.0 spec (April 2014): 12.1.6 - // An ExternalImportDeclaration in anAmbientExternalModuleDeclaration may reference other external modules - // only through top - level external module names. Relative external module names are not permitted. - var searchName = ts.normalizePath(ts.combinePaths(basePath, moduleName)); - ts.forEach(ts.supportedExtensions, function (extension) { return findModuleSourceFile(searchName + extension, nameLiteral); }); - } - } - }); - } - }); - function findModuleSourceFile(fileName, nameLiteral) { - return findSourceFile(fileName, false, file, nameLiteral.pos, nameLiteral.end - nameLiteral.pos); - } - } - function computeCommonSourceDirectory(sourceFiles) { - var commonPathComponents; - var currentDirectory = host.getCurrentDirectory(); - ts.forEach(files, function (sourceFile) { - // Each file contributes into common source file path - if (ts.isDeclarationFile(sourceFile)) { - return; - } - var sourcePathComponents = ts.getNormalizedPathComponents(sourceFile.fileName, currentDirectory); - sourcePathComponents.pop(); // The base file name is not part of the common directory path - if (!commonPathComponents) { - // first file - commonPathComponents = sourcePathComponents; - return; - } - for (var i = 0, n = Math.min(commonPathComponents.length, sourcePathComponents.length); i < n; i++) { - if (commonPathComponents[i] !== sourcePathComponents[i]) { - if (i === 0) { - diagnostics.add(ts.createCompilerDiagnostic(ts.Diagnostics.Cannot_find_the_common_subdirectory_path_for_the_input_files)); - return; - } - // New common path found that is 0 -> i-1 - commonPathComponents.length = i; - break; - } - } - // If the sourcePathComponents was shorter than the commonPathComponents, truncate to the sourcePathComponents - if (sourcePathComponents.length < commonPathComponents.length) { - commonPathComponents.length = sourcePathComponents.length; - } - }); - return ts.getNormalizedPathFromPathComponents(commonPathComponents); - } - function checkSourceFilesBelongToPath(sourceFiles, rootDirectory) { - var allFilesBelongToPath = true; - if (sourceFiles) { - var currentDirectory = host.getCurrentDirectory(); - var absoluteRootDirectoryPath = host.getCanonicalFileName(ts.getNormalizedAbsolutePath(rootDirectory, currentDirectory)); - for (var _i = 0; _i < sourceFiles.length; _i++) { - var sourceFile = sourceFiles[_i]; - if (!ts.isDeclarationFile(sourceFile)) { - var absoluteSourceFilePath = host.getCanonicalFileName(ts.getNormalizedAbsolutePath(sourceFile.fileName, currentDirectory)); - if (absoluteSourceFilePath.indexOf(absoluteRootDirectoryPath) !== 0) { - diagnostics.add(ts.createCompilerDiagnostic(ts.Diagnostics.File_0_is_not_under_rootDir_1_rootDir_is_expected_to_contain_all_source_files, sourceFile.fileName, options.rootDir)); - allFilesBelongToPath = false; - } - } - } - } - return allFilesBelongToPath; - } - function verifyCompilerOptions() { - if (options.isolatedModules) { - if (options.sourceMap) { - diagnostics.add(ts.createCompilerDiagnostic(ts.Diagnostics.Option_sourceMap_cannot_be_specified_with_option_isolatedModules)); - } - if (options.declaration) { - diagnostics.add(ts.createCompilerDiagnostic(ts.Diagnostics.Option_declaration_cannot_be_specified_with_option_isolatedModules)); - } - if (options.noEmitOnError) { - diagnostics.add(ts.createCompilerDiagnostic(ts.Diagnostics.Option_noEmitOnError_cannot_be_specified_with_option_isolatedModules)); - } - if (options.out) { - diagnostics.add(ts.createCompilerDiagnostic(ts.Diagnostics.Option_out_cannot_be_specified_with_option_isolatedModules)); - } - } - if (options.inlineSourceMap) { - if (options.sourceMap) { - diagnostics.add(ts.createCompilerDiagnostic(ts.Diagnostics.Option_sourceMap_cannot_be_specified_with_option_inlineSourceMap)); - } - if (options.mapRoot) { - diagnostics.add(ts.createCompilerDiagnostic(ts.Diagnostics.Option_mapRoot_cannot_be_specified_with_option_inlineSourceMap)); - } - if (options.sourceRoot) { - diagnostics.add(ts.createCompilerDiagnostic(ts.Diagnostics.Option_sourceRoot_cannot_be_specified_with_option_inlineSourceMap)); - } - } - if (options.inlineSources) { - if (!options.sourceMap && !options.inlineSourceMap) { - diagnostics.add(ts.createCompilerDiagnostic(ts.Diagnostics.Option_inlineSources_can_only_be_used_when_either_option_inlineSourceMap_or_option_sourceMap_is_provided)); - } - } - if (!options.sourceMap && (options.mapRoot || options.sourceRoot)) { - // Error to specify --mapRoot or --sourceRoot without mapSourceFiles - if (options.mapRoot) { - diagnostics.add(ts.createCompilerDiagnostic(ts.Diagnostics.Option_mapRoot_cannot_be_specified_without_specifying_sourceMap_option)); - } - if (options.sourceRoot) { - diagnostics.add(ts.createCompilerDiagnostic(ts.Diagnostics.Option_sourceRoot_cannot_be_specified_without_specifying_sourceMap_option)); - } - return; - } - var languageVersion = options.target || 0 /* ES3 */; - var firstExternalModuleSourceFile = ts.forEach(files, function (f) { return ts.isExternalModule(f) ? f : undefined; }); - if (options.isolatedModules) { - if (!options.module && languageVersion < 2 /* ES6 */) { - diagnostics.add(ts.createCompilerDiagnostic(ts.Diagnostics.Option_isolatedModules_can_only_be_used_when_either_option_module_is_provided_or_option_target_is_ES6_or_higher)); - } - var firstNonExternalModuleSourceFile = ts.forEach(files, function (f) { return !ts.isExternalModule(f) && !ts.isDeclarationFile(f) ? f : undefined; }); - if (firstNonExternalModuleSourceFile) { - var span = ts.getErrorSpanForNode(firstNonExternalModuleSourceFile, firstNonExternalModuleSourceFile); - diagnostics.add(ts.createFileDiagnostic(firstNonExternalModuleSourceFile, span.start, span.length, ts.Diagnostics.Cannot_compile_namespaces_when_the_isolatedModules_flag_is_provided)); - } - } - else if (firstExternalModuleSourceFile && languageVersion < 2 /* ES6 */ && !options.module) { - // We cannot use createDiagnosticFromNode because nodes do not have parents yet - var span = ts.getErrorSpanForNode(firstExternalModuleSourceFile, firstExternalModuleSourceFile.externalModuleIndicator); - diagnostics.add(ts.createFileDiagnostic(firstExternalModuleSourceFile, span.start, span.length, ts.Diagnostics.Cannot_compile_modules_unless_the_module_flag_is_provided)); - } - // Cannot specify module gen target when in es6 or above - if (options.module && languageVersion >= 2 /* ES6 */) { - diagnostics.add(ts.createCompilerDiagnostic(ts.Diagnostics.Cannot_compile_modules_into_commonjs_amd_system_or_umd_when_targeting_ES6_or_higher)); - } - // there has to be common source directory if user specified --outdir || --sourceRoot - // if user specified --mapRoot, there needs to be common source directory if there would be multiple files being emitted - if (options.outDir || - options.sourceRoot || - (options.mapRoot && - (!options.out || firstExternalModuleSourceFile !== undefined))) { - if (options.rootDir && checkSourceFilesBelongToPath(files, options.rootDir)) { - // If a rootDir is specified and is valid use it as the commonSourceDirectory - commonSourceDirectory = ts.getNormalizedAbsolutePath(options.rootDir, host.getCurrentDirectory()); - } - else { - // Compute the commonSourceDirectory from the input files - commonSourceDirectory = computeCommonSourceDirectory(files); - } - if (commonSourceDirectory && commonSourceDirectory[commonSourceDirectory.length - 1] !== ts.directorySeparator) { - // Make sure directory path ends with directory separator so this string can directly - // used to replace with "" to get the relative path of the source file and the relative path doesn't - // start with / making it rooted path - commonSourceDirectory += ts.directorySeparator; - } - } - if (options.noEmit) { - if (options.out || options.outDir) { - diagnostics.add(ts.createCompilerDiagnostic(ts.Diagnostics.Option_noEmit_cannot_be_specified_with_option_out_or_outDir)); - } - if (options.declaration) { - diagnostics.add(ts.createCompilerDiagnostic(ts.Diagnostics.Option_noEmit_cannot_be_specified_with_option_declaration)); - } - } - if (options.emitDecoratorMetadata && - !options.experimentalDecorators) { - diagnostics.add(ts.createCompilerDiagnostic(ts.Diagnostics.Option_experimentalDecorators_must_also_be_specified_when_option_emitDecoratorMetadata_is_specified)); - } - } - } - ts.createProgram = createProgram; -})(ts || (ts = {})); -/// -/// -/// -/// -var ts; -(function (ts) { - /* @internal */ - ts.optionDeclarations = [ - { - name: "charset", - type: "string" - }, - { - name: "declaration", - shortName: "d", - type: "boolean", - description: ts.Diagnostics.Generates_corresponding_d_ts_file - }, - { - name: "diagnostics", - type: "boolean" - }, - { - name: "emitBOM", - type: "boolean" - }, - { - name: "help", - shortName: "h", - type: "boolean", - description: ts.Diagnostics.Print_this_message - }, - { - name: "inlineSourceMap", - type: "boolean" - }, - { - name: "inlineSources", - type: "boolean" - }, - { - name: "listFiles", - type: "boolean" - }, - { - name: "locale", - type: "string" - }, - { - name: "mapRoot", - type: "string", - isFilePath: true, - description: ts.Diagnostics.Specifies_the_location_where_debugger_should_locate_map_files_instead_of_generated_locations, - paramType: ts.Diagnostics.LOCATION - }, - { - name: "module", - shortName: "m", - type: { - "commonjs": 1 /* CommonJS */, - "amd": 2 /* AMD */, - "system": 4 /* System */, - "umd": 3 /* UMD */ - }, - description: ts.Diagnostics.Specify_module_code_generation_Colon_commonjs_amd_system_or_umd, - paramType: ts.Diagnostics.KIND, - error: ts.Diagnostics.Argument_for_module_option_must_be_commonjs_amd_system_or_umd - }, - { - name: "newLine", - type: { - "crlf": 0 /* CarriageReturnLineFeed */, - "lf": 1 /* LineFeed */ - }, - description: ts.Diagnostics.Specifies_the_end_of_line_sequence_to_be_used_when_emitting_files_Colon_CRLF_dos_or_LF_unix, - paramType: ts.Diagnostics.NEWLINE, - error: ts.Diagnostics.Argument_for_newLine_option_must_be_CRLF_or_LF - }, - { - name: "noEmit", - type: "boolean", - description: ts.Diagnostics.Do_not_emit_outputs - }, - { - name: "noEmitHelpers", - type: "boolean" - }, - { - name: "noEmitOnError", - type: "boolean", - description: ts.Diagnostics.Do_not_emit_outputs_if_any_errors_were_reported - }, - { - name: "noImplicitAny", - type: "boolean", - description: ts.Diagnostics.Raise_error_on_expressions_and_declarations_with_an_implied_any_type - }, - { - name: "noLib", - type: "boolean" - }, - { - name: "noResolve", - type: "boolean" - }, - { - name: "skipDefaultLibCheck", - type: "boolean" - }, - { - name: "out", - type: "string", - description: ts.Diagnostics.Concatenate_and_emit_output_to_single_file, - paramType: ts.Diagnostics.FILE - }, - { - name: "outDir", - type: "string", - isFilePath: true, - description: ts.Diagnostics.Redirect_output_structure_to_the_directory, - paramType: ts.Diagnostics.DIRECTORY - }, - { - name: "preserveConstEnums", - type: "boolean", - description: ts.Diagnostics.Do_not_erase_const_enum_declarations_in_generated_code - }, - { - name: "project", - shortName: "p", - type: "string", - isFilePath: true, - description: ts.Diagnostics.Compile_the_project_in_the_given_directory, - paramType: ts.Diagnostics.DIRECTORY - }, - { - name: "removeComments", - type: "boolean", - description: ts.Diagnostics.Do_not_emit_comments_to_output - }, - { - name: "rootDir", - type: "string", - isFilePath: true, - description: ts.Diagnostics.Specifies_the_root_directory_of_input_files_Use_to_control_the_output_directory_structure_with_outDir, - paramType: ts.Diagnostics.LOCATION - }, - { - name: "isolatedModules", - type: "boolean" - }, - { - name: "sourceMap", - type: "boolean", - description: ts.Diagnostics.Generates_corresponding_map_file - }, - { - name: "sourceRoot", - type: "string", - isFilePath: true, - description: ts.Diagnostics.Specifies_the_location_where_debugger_should_locate_TypeScript_files_instead_of_source_locations, - paramType: ts.Diagnostics.LOCATION - }, - { - name: "suppressImplicitAnyIndexErrors", - type: "boolean", - description: ts.Diagnostics.Suppress_noImplicitAny_errors_for_indexing_objects_lacking_index_signatures - }, - { - name: "stripInternal", - type: "boolean", - description: ts.Diagnostics.Do_not_emit_declarations_for_code_that_has_an_internal_annotation, - experimental: true - }, - { - name: "target", - shortName: "t", - type: { "es3": 0 /* ES3 */, "es5": 1 /* ES5 */, "es6": 2 /* ES6 */ }, - description: ts.Diagnostics.Specify_ECMAScript_target_version_Colon_ES3_default_ES5_or_ES6_experimental, - paramType: ts.Diagnostics.VERSION, - error: ts.Diagnostics.Argument_for_target_option_must_be_ES3_ES5_or_ES6 - }, - { - name: "version", - shortName: "v", - type: "boolean", - description: ts.Diagnostics.Print_the_compiler_s_version - }, - { - name: "watch", - shortName: "w", - type: "boolean", - description: ts.Diagnostics.Watch_input_files - }, - { - name: "experimentalDecorators", - type: "boolean", - description: ts.Diagnostics.Enables_experimental_support_for_ES7_decorators - }, - { - name: "emitDecoratorMetadata", - type: "boolean", - experimental: true, - description: ts.Diagnostics.Enables_experimental_support_for_emitting_type_metadata_for_decorators - } - ]; - function parseCommandLine(commandLine) { - var options = {}; - var fileNames = []; - var errors = []; - var shortOptionNames = {}; - var optionNameMap = {}; - ts.forEach(ts.optionDeclarations, function (option) { - optionNameMap[option.name.toLowerCase()] = option; - if (option.shortName) { - shortOptionNames[option.shortName] = option.name; - } - }); - parseStrings(commandLine); - return { - options: options, - fileNames: fileNames, - errors: errors - }; - function parseStrings(args) { - var i = 0; - while (i < args.length) { - var s = args[i++]; - if (s.charCodeAt(0) === 64 /* at */) { - parseResponseFile(s.slice(1)); - } - else if (s.charCodeAt(0) === 45 /* minus */) { - s = s.slice(s.charCodeAt(1) === 45 /* minus */ ? 2 : 1).toLowerCase(); - // Try to translate short option names to their full equivalents. - if (ts.hasProperty(shortOptionNames, s)) { - s = shortOptionNames[s]; - } - if (ts.hasProperty(optionNameMap, s)) { - var opt = optionNameMap[s]; - // Check to see if no argument was provided (e.g. "--locale" is the last command-line argument). - if (!args[i] && opt.type !== "boolean") { - errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.Compiler_option_0_expects_an_argument, opt.name)); - } - switch (opt.type) { - case "number": - options[opt.name] = parseInt(args[i++]); - break; - case "boolean": - options[opt.name] = true; - break; - case "string": - options[opt.name] = args[i++] || ""; - break; - // If not a primitive, the possible types are specified in what is effectively a map of options. - default: - var map = opt.type; - var key = (args[i++] || "").toLowerCase(); - if (ts.hasProperty(map, key)) { - options[opt.name] = map[key]; - } - else { - errors.push(ts.createCompilerDiagnostic(opt.error)); - } - } - } - else { - errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.Unknown_compiler_option_0, s)); - } - } - else { - fileNames.push(s); - } - } - } - function parseResponseFile(fileName) { - var text = ts.sys.readFile(fileName); - if (!text) { - errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.File_0_not_found, fileName)); - return; - } - var args = []; - var pos = 0; - while (true) { - while (pos < text.length && text.charCodeAt(pos) <= 32 /* space */) - pos++; - if (pos >= text.length) - break; - var start = pos; - if (text.charCodeAt(start) === 34 /* doubleQuote */) { - pos++; - while (pos < text.length && text.charCodeAt(pos) !== 34 /* doubleQuote */) - pos++; - if (pos < text.length) { - args.push(text.substring(start + 1, pos)); - pos++; - } - else { - errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.Unterminated_quoted_string_in_response_file_0, fileName)); - } - } - else { - while (text.charCodeAt(pos) > 32 /* space */) - pos++; - args.push(text.substring(start, pos)); - } - } - parseStrings(args); - } - } - ts.parseCommandLine = parseCommandLine; - /** - * Read tsconfig.json file - * @param fileName The path to the config file - */ - function readConfigFile(fileName) { - try { - var text = ts.sys.readFile(fileName); - } - catch (e) { - return { error: ts.createCompilerDiagnostic(ts.Diagnostics.Cannot_read_file_0_Colon_1, fileName, e.message) }; - } - return parseConfigFileText(fileName, text); - } - ts.readConfigFile = readConfigFile; - /** - * Parse the text of the tsconfig.json file - * @param fileName The path to the config file - * @param jsonText The text of the config file - */ - function parseConfigFileText(fileName, jsonText) { - try { - return { config: /\S/.test(jsonText) ? JSON.parse(jsonText) : {} }; - } - catch (e) { - return { error: ts.createCompilerDiagnostic(ts.Diagnostics.Failed_to_parse_file_0_Colon_1, fileName, e.message) }; - } - } - ts.parseConfigFileText = parseConfigFileText; - /** - * Parse the contents of a config file (tsconfig.json). - * @param json The contents of the config file to parse - * @param basePath A root directory to resolve relative path entries in the config - * file to. e.g. outDir - */ - function parseConfigFile(json, host, basePath) { - var errors = []; - return { - options: getCompilerOptions(), - fileNames: getFileNames(), - errors: errors - }; - function getCompilerOptions() { - var options = {}; - var optionNameMap = {}; - ts.forEach(ts.optionDeclarations, function (option) { - optionNameMap[option.name] = option; - }); - var jsonOptions = json["compilerOptions"]; - if (jsonOptions) { - for (var id in jsonOptions) { - if (ts.hasProperty(optionNameMap, id)) { - var opt = optionNameMap[id]; - var optType = opt.type; - var value = jsonOptions[id]; - var expectedType = typeof optType === "string" ? optType : "string"; - if (typeof value === expectedType) { - if (typeof optType !== "string") { - var key = value.toLowerCase(); - if (ts.hasProperty(optType, key)) { - value = optType[key]; - } - else { - errors.push(ts.createCompilerDiagnostic(opt.error)); - value = 0; - } - } - if (opt.isFilePath) { - value = ts.normalizePath(ts.combinePaths(basePath, value)); - } - options[opt.name] = value; - } - else { - errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.Compiler_option_0_requires_a_value_of_type_1, id, expectedType)); - } - } - else { - errors.push(ts.createCompilerDiagnostic(ts.Diagnostics.Unknown_compiler_option_0, id)); - } - } - } - return options; - } - function getFileNames() { - var fileNames = []; - if (ts.hasProperty(json, "files")) { - if (json["files"] instanceof Array) { - fileNames = ts.map(json["files"], function (s) { return ts.combinePaths(basePath, s); }); - } - } - else { - var exclude = json["exclude"] instanceof Array ? ts.map(json["exclude"], ts.normalizeSlashes) : undefined; - var sysFiles = host.readDirectory(basePath, ".ts", exclude); - for (var i = 0; i < sysFiles.length; i++) { - var name = sysFiles[i]; - if (!ts.fileExtensionIs(name, ".d.ts") || !ts.contains(sysFiles, name.substr(0, name.length - 5) + ".ts")) { - fileNames.push(name); - } - } - } - return fileNames; - } - } - ts.parseConfigFile = parseConfigFile; -})(ts || (ts = {})); -/* @internal */ -var ts; -(function (ts) { - var OutliningElementsCollector; - (function (OutliningElementsCollector) { - function collectElements(sourceFile) { - var elements = []; - var collapseText = "..."; - function addOutliningSpan(hintSpanNode, startElement, endElement, autoCollapse) { - if (hintSpanNode && startElement && endElement) { - var span = { - textSpan: ts.createTextSpanFromBounds(startElement.pos, endElement.end), - hintSpan: ts.createTextSpanFromBounds(hintSpanNode.getStart(), hintSpanNode.end), - bannerText: collapseText, - autoCollapse: autoCollapse - }; - elements.push(span); - } - } - function addOutliningSpanComments(commentSpan, autoCollapse) { - if (commentSpan) { - var span = { - textSpan: ts.createTextSpanFromBounds(commentSpan.pos, commentSpan.end), - hintSpan: ts.createTextSpanFromBounds(commentSpan.pos, commentSpan.end), - bannerText: collapseText, - autoCollapse: autoCollapse - }; - elements.push(span); - } - } - function addOutliningForLeadingCommentsForNode(n) { - var comments = ts.getLeadingCommentRangesOfNode(n, sourceFile); - if (comments) { - var firstSingleLineCommentStart = -1; - var lastSingleLineCommentEnd = -1; - var isFirstSingleLineComment = true; - var singleLineCommentCount = 0; - for (var _i = 0; _i < comments.length; _i++) { - var currentComment = comments[_i]; - // For single line comments, combine consecutive ones (2 or more) into - // a single span from the start of the first till the end of the last - if (currentComment.kind === 2 /* SingleLineCommentTrivia */) { - if (isFirstSingleLineComment) { - firstSingleLineCommentStart = currentComment.pos; - } - isFirstSingleLineComment = false; - lastSingleLineCommentEnd = currentComment.end; - singleLineCommentCount++; - } - else if (currentComment.kind === 3 /* MultiLineCommentTrivia */) { - combineAndAddMultipleSingleLineComments(singleLineCommentCount, firstSingleLineCommentStart, lastSingleLineCommentEnd); - addOutliningSpanComments(currentComment, false); - singleLineCommentCount = 0; - lastSingleLineCommentEnd = -1; - isFirstSingleLineComment = true; - } - } - combineAndAddMultipleSingleLineComments(singleLineCommentCount, firstSingleLineCommentStart, lastSingleLineCommentEnd); - } - } - function combineAndAddMultipleSingleLineComments(count, start, end) { - // Only outline spans of two or more consecutive single line comments - if (count > 1) { - var multipleSingleLineComments = { - pos: start, - end: end, - kind: 2 /* SingleLineCommentTrivia */ - }; - addOutliningSpanComments(multipleSingleLineComments, false); - } - } - function autoCollapse(node) { - return ts.isFunctionBlock(node) && node.parent.kind !== 166 /* ArrowFunction */; - } - var depth = 0; - var maxDepth = 20; - function walk(n) { - if (depth > maxDepth) { - return; - } - if (ts.isDeclaration(n)) { - addOutliningForLeadingCommentsForNode(n); - } - switch (n.kind) { - case 182 /* Block */: - if (!ts.isFunctionBlock(n)) { - var parent_8 = n.parent; - var openBrace = ts.findChildOfKind(n, 14 /* OpenBraceToken */, sourceFile); - var closeBrace = ts.findChildOfKind(n, 15 /* CloseBraceToken */, sourceFile); - // Check if the block is standalone, or 'attached' to some parent statement. - // If the latter, we want to collaps the block, but consider its hint span - // to be the entire span of the parent. - if (parent_8.kind === 187 /* DoStatement */ || - parent_8.kind === 190 /* ForInStatement */ || - parent_8.kind === 191 /* ForOfStatement */ || - parent_8.kind === 189 /* ForStatement */ || - parent_8.kind === 186 /* IfStatement */ || - parent_8.kind === 188 /* WhileStatement */ || - parent_8.kind === 195 /* WithStatement */ || - parent_8.kind === 226 /* CatchClause */) { - addOutliningSpan(parent_8, openBrace, closeBrace, autoCollapse(n)); - break; - } - if (parent_8.kind === 199 /* TryStatement */) { - // Could be the try-block, or the finally-block. - var tryStatement = parent_8; - if (tryStatement.tryBlock === n) { - addOutliningSpan(parent_8, openBrace, closeBrace, autoCollapse(n)); - break; - } - else if (tryStatement.finallyBlock === n) { - var finallyKeyword = ts.findChildOfKind(tryStatement, 81 /* FinallyKeyword */, sourceFile); - if (finallyKeyword) { - addOutliningSpan(finallyKeyword, openBrace, closeBrace, autoCollapse(n)); - break; - } - } - } - // Block was a standalone block. In this case we want to only collapse - // the span of the block, independent of any parent span. - var span = ts.createTextSpanFromBounds(n.getStart(), n.end); - elements.push({ - textSpan: span, - hintSpan: span, - bannerText: collapseText, - autoCollapse: autoCollapse(n) - }); - break; - } - // Fallthrough. - case 209 /* ModuleBlock */: { - var openBrace = ts.findChildOfKind(n, 14 /* OpenBraceToken */, sourceFile); - var closeBrace = ts.findChildOfKind(n, 15 /* CloseBraceToken */, sourceFile); - addOutliningSpan(n.parent, openBrace, closeBrace, autoCollapse(n)); - break; - } - case 204 /* ClassDeclaration */: - case 205 /* InterfaceDeclaration */: - case 207 /* EnumDeclaration */: - case 157 /* ObjectLiteralExpression */: - case 210 /* CaseBlock */: { - var openBrace = ts.findChildOfKind(n, 14 /* OpenBraceToken */, sourceFile); - var closeBrace = ts.findChildOfKind(n, 15 /* CloseBraceToken */, sourceFile); - addOutliningSpan(n, openBrace, closeBrace, autoCollapse(n)); - break; - } - case 156 /* ArrayLiteralExpression */: - var openBracket = ts.findChildOfKind(n, 18 /* OpenBracketToken */, sourceFile); - var closeBracket = ts.findChildOfKind(n, 19 /* CloseBracketToken */, sourceFile); - addOutliningSpan(n, openBracket, closeBracket, autoCollapse(n)); - break; - } - depth++; - ts.forEachChild(n, walk); - depth--; - } - walk(sourceFile); - return elements; - } - OutliningElementsCollector.collectElements = collectElements; - })(OutliningElementsCollector = ts.OutliningElementsCollector || (ts.OutliningElementsCollector = {})); -})(ts || (ts = {})); -/* @internal */ -var ts; -(function (ts) { - var NavigateTo; - (function (NavigateTo) { - function getNavigateToItems(program, cancellationToken, searchValue, maxResultCount) { - var patternMatcher = ts.createPatternMatcher(searchValue); - var rawItems = []; - // Search the declarations in all files and output matched NavigateToItem into array of NavigateToItem[] - ts.forEach(program.getSourceFiles(), function (sourceFile) { - cancellationToken.throwIfCancellationRequested(); - var nameToDeclarations = sourceFile.getNamedDeclarations(); - for (var name_27 in nameToDeclarations) { - var declarations = ts.getProperty(nameToDeclarations, name_27); - if (declarations) { - // First do a quick check to see if the name of the declaration matches the - // last portion of the (possibly) dotted name they're searching for. - var matches = patternMatcher.getMatchesForLastSegmentOfPattern(name_27); - if (!matches) { - continue; - } - for (var _i = 0; _i < declarations.length; _i++) { - var declaration = declarations[_i]; - // It was a match! If the pattern has dots in it, then also see if the - // declaration container matches as well. - if (patternMatcher.patternContainsDots) { - var containers = getContainers(declaration); - if (!containers) { - return undefined; - } - matches = patternMatcher.getMatches(containers, name_27); - if (!matches) { - continue; - } - } - var fileName = sourceFile.fileName; - var matchKind = bestMatchKind(matches); - rawItems.push({ name: name_27, fileName: fileName, matchKind: matchKind, isCaseSensitive: allMatchesAreCaseSensitive(matches), declaration: declaration }); - } - } - } - }); - rawItems.sort(compareNavigateToItems); - if (maxResultCount !== undefined) { - rawItems = rawItems.slice(0, maxResultCount); - } - var items = ts.map(rawItems, createNavigateToItem); - return items; - function allMatchesAreCaseSensitive(matches) { - ts.Debug.assert(matches.length > 0); - // This is a case sensitive match, only if all the submatches were case sensitive. - for (var _i = 0; _i < matches.length; _i++) { - var match = matches[_i]; - if (!match.isCaseSensitive) { - return false; - } - } - return true; - } - function getTextOfIdentifierOrLiteral(node) { - if (node) { - if (node.kind === 65 /* Identifier */ || - node.kind === 8 /* StringLiteral */ || - node.kind === 7 /* NumericLiteral */) { - return node.text; - } - } - return undefined; - } - function tryAddSingleDeclarationName(declaration, containers) { - if (declaration && declaration.name) { - var text = getTextOfIdentifierOrLiteral(declaration.name); - if (text !== undefined) { - containers.unshift(text); - } - else if (declaration.name.kind === 129 /* ComputedPropertyName */) { - return tryAddComputedPropertyName(declaration.name.expression, containers, true); - } - else { - // Don't know how to add this. - return false; - } - } - return true; - } - // Only added the names of computed properties if they're simple dotted expressions, like: - // - // [X.Y.Z]() { } - function tryAddComputedPropertyName(expression, containers, includeLastPortion) { - var text = getTextOfIdentifierOrLiteral(expression); - if (text !== undefined) { - if (includeLastPortion) { - containers.unshift(text); - } - return true; - } - if (expression.kind === 158 /* PropertyAccessExpression */) { - var propertyAccess = expression; - if (includeLastPortion) { - containers.unshift(propertyAccess.name.text); - } - return tryAddComputedPropertyName(propertyAccess.expression, containers, true); - } - return false; - } - function getContainers(declaration) { - var containers = []; - // First, if we started with a computed property name, then add all but the last - // portion into the container array. - if (declaration.name.kind === 129 /* ComputedPropertyName */) { - if (!tryAddComputedPropertyName(declaration.name.expression, containers, false)) { - return undefined; - } - } - // Now, walk up our containers, adding all their names to the container array. - declaration = ts.getContainerNode(declaration); - while (declaration) { - if (!tryAddSingleDeclarationName(declaration, containers)) { - return undefined; - } - declaration = ts.getContainerNode(declaration); - } - return containers; - } - function bestMatchKind(matches) { - ts.Debug.assert(matches.length > 0); - var bestMatchKind = ts.PatternMatchKind.camelCase; - for (var _i = 0; _i < matches.length; _i++) { - var match = matches[_i]; - var kind = match.kind; - if (kind < bestMatchKind) { - bestMatchKind = kind; - } - } - return bestMatchKind; - } - // This means "compare in a case insensitive manner." - var baseSensitivity = { sensitivity: "base" }; - function compareNavigateToItems(i1, i2) { - // TODO(cyrusn): get the gamut of comparisons that VS already uses here. - // Right now we just sort by kind first, and then by name of the item. - // We first sort case insensitively. So "Aaa" will come before "bar". - // Then we sort case sensitively, so "aaa" will come before "Aaa". - return i1.matchKind - i2.matchKind || - i1.name.localeCompare(i2.name, undefined, baseSensitivity) || - i1.name.localeCompare(i2.name); - } - function createNavigateToItem(rawItem) { - var declaration = rawItem.declaration; - var container = ts.getContainerNode(declaration); - return { - name: rawItem.name, - kind: ts.getNodeKind(declaration), - kindModifiers: ts.getNodeModifiers(declaration), - matchKind: ts.PatternMatchKind[rawItem.matchKind], - isCaseSensitive: rawItem.isCaseSensitive, - fileName: rawItem.fileName, - textSpan: ts.createTextSpanFromBounds(declaration.getStart(), declaration.getEnd()), - // TODO(jfreeman): What should be the containerName when the container has a computed name? - containerName: container && container.name ? container.name.text : "", - containerKind: container && container.name ? ts.getNodeKind(container) : "" - }; - } - } - NavigateTo.getNavigateToItems = getNavigateToItems; - })(NavigateTo = ts.NavigateTo || (ts.NavigateTo = {})); -})(ts || (ts = {})); -/// -/* @internal */ -var ts; -(function (ts) { - var NavigationBar; - (function (NavigationBar) { - function getNavigationBarItems(sourceFile) { - // If the source file has any child items, then it included in the tree - // and takes lexical ownership of all other top-level items. - var hasGlobalNode = false; - return getItemsWorker(getTopLevelNodes(sourceFile), createTopLevelItem); - function getIndent(node) { - // If we have a global node in the tree, - // then it adds an extra layer of depth to all subnodes. - var indent = hasGlobalNode ? 1 : 0; - var current = node.parent; - while (current) { - switch (current.kind) { - case 208 /* ModuleDeclaration */: - // If we have a module declared as A.B.C, it is more "intuitive" - // to say it only has a single layer of depth - do { - current = current.parent; - } while (current.kind === 208 /* ModuleDeclaration */); - // fall through - case 204 /* ClassDeclaration */: - case 207 /* EnumDeclaration */: - case 205 /* InterfaceDeclaration */: - case 203 /* FunctionDeclaration */: - indent++; - } - current = current.parent; - } - return indent; - } - function getChildNodes(nodes) { - var childNodes = []; - function visit(node) { - switch (node.kind) { - case 183 /* VariableStatement */: - ts.forEach(node.declarationList.declarations, visit); - break; - case 153 /* ObjectBindingPattern */: - case 154 /* ArrayBindingPattern */: - ts.forEach(node.elements, visit); - break; - case 218 /* ExportDeclaration */: - // Handle named exports case e.g.: - // export {a, b as B} from "mod"; - if (node.exportClause) { - ts.forEach(node.exportClause.elements, visit); - } - break; - case 212 /* ImportDeclaration */: - var importClause = node.importClause; - if (importClause) { - // Handle default import case e.g.: - // import d from "mod"; - if (importClause.name) { - childNodes.push(importClause); - } - // Handle named bindings in imports e.g.: - // import * as NS from "mod"; - // import {a, b as B} from "mod"; - if (importClause.namedBindings) { - if (importClause.namedBindings.kind === 214 /* NamespaceImport */) { - childNodes.push(importClause.namedBindings); - } - else { - ts.forEach(importClause.namedBindings.elements, visit); - } - } - } - break; - case 155 /* BindingElement */: - case 201 /* VariableDeclaration */: - if (ts.isBindingPattern(node.name)) { - visit(node.name); - break; - } - // Fall through - case 204 /* ClassDeclaration */: - case 207 /* EnumDeclaration */: - case 205 /* InterfaceDeclaration */: - case 208 /* ModuleDeclaration */: - case 203 /* FunctionDeclaration */: - case 211 /* ImportEqualsDeclaration */: - case 216 /* ImportSpecifier */: - case 220 /* ExportSpecifier */: - childNodes.push(node); - break; - } - } - //for (let i = 0, n = nodes.length; i < n; i++) { - // let node = nodes[i]; - // if (node.kind === SyntaxKind.ClassDeclaration || - // node.kind === SyntaxKind.EnumDeclaration || - // node.kind === SyntaxKind.InterfaceDeclaration || - // node.kind === SyntaxKind.ModuleDeclaration || - // node.kind === SyntaxKind.FunctionDeclaration) { - // childNodes.push(node); - // } - // else if (node.kind === SyntaxKind.VariableStatement) { - // childNodes.push.apply(childNodes, (node).declarations); - // } - //} - ts.forEach(nodes, visit); - return sortNodes(childNodes); - } - function getTopLevelNodes(node) { - var topLevelNodes = []; - topLevelNodes.push(node); - addTopLevelNodes(node.statements, topLevelNodes); - return topLevelNodes; - } - function sortNodes(nodes) { - return nodes.slice(0).sort(function (n1, n2) { - if (n1.name && n2.name) { - return ts.getPropertyNameForPropertyNameNode(n1.name).localeCompare(ts.getPropertyNameForPropertyNameNode(n2.name)); - } - else if (n1.name) { - return 1; - } - else if (n2.name) { - return -1; - } - else { - return n1.kind - n2.kind; - } - }); - } - function addTopLevelNodes(nodes, topLevelNodes) { - nodes = sortNodes(nodes); - for (var _i = 0; _i < nodes.length; _i++) { - var node = nodes[_i]; - switch (node.kind) { - case 204 /* ClassDeclaration */: - case 207 /* EnumDeclaration */: - case 205 /* InterfaceDeclaration */: - topLevelNodes.push(node); - break; - case 208 /* ModuleDeclaration */: - var moduleDeclaration = node; - topLevelNodes.push(node); - addTopLevelNodes(getInnermostModule(moduleDeclaration).body.statements, topLevelNodes); - break; - case 203 /* FunctionDeclaration */: - var functionDeclaration = node; - if (isTopLevelFunctionDeclaration(functionDeclaration)) { - topLevelNodes.push(node); - addTopLevelNodes(functionDeclaration.body.statements, topLevelNodes); - } - break; - } - } - } - function isTopLevelFunctionDeclaration(functionDeclaration) { - if (functionDeclaration.kind === 203 /* FunctionDeclaration */) { - // A function declaration is 'top level' if it contains any function declarations - // within it. - if (functionDeclaration.body && functionDeclaration.body.kind === 182 /* Block */) { - // Proper function declarations can only have identifier names - if (ts.forEach(functionDeclaration.body.statements, function (s) { return s.kind === 203 /* FunctionDeclaration */ && !isEmpty(s.name.text); })) { - return true; - } - // Or if it is not parented by another function. i.e all functions - // at module scope are 'top level'. - if (!ts.isFunctionBlock(functionDeclaration.parent)) { - return true; - } - } - } - return false; - } - function getItemsWorker(nodes, createItem) { - var items = []; - var keyToItem = {}; - for (var _i = 0; _i < nodes.length; _i++) { - var child = nodes[_i]; - var item = createItem(child); - if (item !== undefined) { - if (item.text.length > 0) { - var key = item.text + "-" + item.kind + "-" + item.indent; - var itemWithSameName = keyToItem[key]; - if (itemWithSameName) { - // We had an item with the same name. Merge these items together. - merge(itemWithSameName, item); - } - else { - keyToItem[key] = item; - items.push(item); - } - } - } - } - return items; - } - function merge(target, source) { - // First, add any spans in the source to the target. - target.spans.push.apply(target.spans, source.spans); - if (source.childItems) { - if (!target.childItems) { - target.childItems = []; - } - // Next, recursively merge or add any children in the source as appropriate. - outer: for (var _i = 0, _a = source.childItems; _i < _a.length; _i++) { - var sourceChild = _a[_i]; - for (var _b = 0, _c = target.childItems; _b < _c.length; _b++) { - var targetChild = _c[_b]; - if (targetChild.text === sourceChild.text && targetChild.kind === sourceChild.kind) { - // Found a match. merge them. - merge(targetChild, sourceChild); - continue outer; - } - } - // Didn't find a match, just add this child to the list. - target.childItems.push(sourceChild); - } - } - } - function createChildItem(node) { - switch (node.kind) { - case 131 /* Parameter */: - if (ts.isBindingPattern(node.name)) { - break; - } - if ((node.flags & 499 /* Modifier */) === 0) { - return undefined; - } - return createItem(node, getTextOfNode(node.name), ts.ScriptElementKind.memberVariableElement); - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - return createItem(node, getTextOfNode(node.name), ts.ScriptElementKind.memberFunctionElement); - case 138 /* GetAccessor */: - return createItem(node, getTextOfNode(node.name), ts.ScriptElementKind.memberGetAccessorElement); - case 139 /* SetAccessor */: - return createItem(node, getTextOfNode(node.name), ts.ScriptElementKind.memberSetAccessorElement); - case 142 /* IndexSignature */: - return createItem(node, "[]", ts.ScriptElementKind.indexSignatureElement); - case 229 /* EnumMember */: - return createItem(node, getTextOfNode(node.name), ts.ScriptElementKind.memberVariableElement); - case 140 /* CallSignature */: - return createItem(node, "()", ts.ScriptElementKind.callSignatureElement); - case 141 /* ConstructSignature */: - return createItem(node, "new()", ts.ScriptElementKind.constructSignatureElement); - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - return createItem(node, getTextOfNode(node.name), ts.ScriptElementKind.memberVariableElement); - case 203 /* FunctionDeclaration */: - return createItem(node, getTextOfNode(node.name), ts.ScriptElementKind.functionElement); - case 201 /* VariableDeclaration */: - case 155 /* BindingElement */: - var variableDeclarationNode; - var name_28; - if (node.kind === 155 /* BindingElement */) { - name_28 = node.name; - variableDeclarationNode = node; - // binding elements are added only for variable declarations - // bubble up to the containing variable declaration - while (variableDeclarationNode && variableDeclarationNode.kind !== 201 /* VariableDeclaration */) { - variableDeclarationNode = variableDeclarationNode.parent; - } - ts.Debug.assert(variableDeclarationNode !== undefined); - } - else { - ts.Debug.assert(!ts.isBindingPattern(node.name)); - variableDeclarationNode = node; - name_28 = node.name; - } - if (ts.isConst(variableDeclarationNode)) { - return createItem(node, getTextOfNode(name_28), ts.ScriptElementKind.constElement); - } - else if (ts.isLet(variableDeclarationNode)) { - return createItem(node, getTextOfNode(name_28), ts.ScriptElementKind.letElement); - } - else { - return createItem(node, getTextOfNode(name_28), ts.ScriptElementKind.variableElement); - } - case 137 /* Constructor */: - return createItem(node, "constructor", ts.ScriptElementKind.constructorImplementationElement); - case 220 /* ExportSpecifier */: - case 216 /* ImportSpecifier */: - case 211 /* ImportEqualsDeclaration */: - case 213 /* ImportClause */: - case 214 /* NamespaceImport */: - return createItem(node, getTextOfNode(node.name), ts.ScriptElementKind.alias); - } - return undefined; - function createItem(node, name, scriptElementKind) { - return getNavigationBarItem(name, scriptElementKind, ts.getNodeModifiers(node), [getNodeSpan(node)]); - } - } - function isEmpty(text) { - return !text || text.trim() === ""; - } - function getNavigationBarItem(text, kind, kindModifiers, spans, childItems, indent) { - if (childItems === void 0) { childItems = []; } - if (indent === void 0) { indent = 0; } - if (isEmpty(text)) { - return undefined; - } - return { - text: text, - kind: kind, - kindModifiers: kindModifiers, - spans: spans, - childItems: childItems, - indent: indent, - bolded: false, - grayed: false - }; - } - function createTopLevelItem(node) { - switch (node.kind) { - case 230 /* SourceFile */: - return createSourceFileItem(node); - case 204 /* ClassDeclaration */: - return createClassItem(node); - case 207 /* EnumDeclaration */: - return createEnumItem(node); - case 205 /* InterfaceDeclaration */: - return createIterfaceItem(node); - case 208 /* ModuleDeclaration */: - return createModuleItem(node); - case 203 /* FunctionDeclaration */: - return createFunctionItem(node); - } - return undefined; - function getModuleName(moduleDeclaration) { - // We want to maintain quotation marks. - if (moduleDeclaration.name.kind === 8 /* StringLiteral */) { - return getTextOfNode(moduleDeclaration.name); - } - // Otherwise, we need to aggregate each identifier to build up the qualified name. - var result = []; - result.push(moduleDeclaration.name.text); - while (moduleDeclaration.body && moduleDeclaration.body.kind === 208 /* ModuleDeclaration */) { - moduleDeclaration = moduleDeclaration.body; - result.push(moduleDeclaration.name.text); - } - return result.join("."); - } - function createModuleItem(node) { - var moduleName = getModuleName(node); - var childItems = getItemsWorker(getChildNodes(getInnermostModule(node).body.statements), createChildItem); - return getNavigationBarItem(moduleName, ts.ScriptElementKind.moduleElement, ts.getNodeModifiers(node), [getNodeSpan(node)], childItems, getIndent(node)); - } - function createFunctionItem(node) { - if (node.body && node.body.kind === 182 /* Block */) { - var childItems = getItemsWorker(sortNodes(node.body.statements), createChildItem); - return getNavigationBarItem(!node.name ? "default" : node.name.text, ts.ScriptElementKind.functionElement, ts.getNodeModifiers(node), [getNodeSpan(node)], childItems, getIndent(node)); - } - return undefined; - } - function createSourceFileItem(node) { - var childItems = getItemsWorker(getChildNodes(node.statements), createChildItem); - if (childItems === undefined || childItems.length === 0) { - return undefined; - } - hasGlobalNode = true; - var rootName = ts.isExternalModule(node) - ? "\"" + ts.escapeString(ts.getBaseFileName(ts.removeFileExtension(ts.normalizePath(node.fileName)))) + "\"" - : ""; - return getNavigationBarItem(rootName, ts.ScriptElementKind.moduleElement, ts.ScriptElementKindModifier.none, [getNodeSpan(node)], childItems); - } - function createClassItem(node) { - var childItems; - if (node.members) { - var constructor = ts.forEach(node.members, function (member) { - return member.kind === 137 /* Constructor */ && member; - }); - // Add the constructor parameters in as children of the class (for property parameters). - // Note that *all non-binding pattern named* parameters will be added to the nodes array, but parameters that - // are not properties will be filtered out later by createChildItem. - var nodes = removeDynamicallyNamedProperties(node); - if (constructor) { - nodes.push.apply(nodes, ts.filter(constructor.parameters, function (p) { return !ts.isBindingPattern(p.name); })); - } - childItems = getItemsWorker(sortNodes(nodes), createChildItem); - } - var nodeName = !node.name ? "default" : node.name.text; - return getNavigationBarItem(nodeName, ts.ScriptElementKind.classElement, ts.getNodeModifiers(node), [getNodeSpan(node)], childItems, getIndent(node)); - } - function createEnumItem(node) { - var childItems = getItemsWorker(sortNodes(removeComputedProperties(node)), createChildItem); - return getNavigationBarItem(node.name.text, ts.ScriptElementKind.enumElement, ts.getNodeModifiers(node), [getNodeSpan(node)], childItems, getIndent(node)); - } - function createIterfaceItem(node) { - var childItems = getItemsWorker(sortNodes(removeDynamicallyNamedProperties(node)), createChildItem); - return getNavigationBarItem(node.name.text, ts.ScriptElementKind.interfaceElement, ts.getNodeModifiers(node), [getNodeSpan(node)], childItems, getIndent(node)); - } - } - function removeComputedProperties(node) { - return ts.filter(node.members, function (member) { return member.name === undefined || member.name.kind !== 129 /* ComputedPropertyName */; }); - } - /** - * Like removeComputedProperties, but retains the properties with well known symbol names - */ - function removeDynamicallyNamedProperties(node) { - return ts.filter(node.members, function (member) { return !ts.hasDynamicName(member); }); - } - function getInnermostModule(node) { - while (node.body.kind === 208 /* ModuleDeclaration */) { - node = node.body; - } - return node; - } - function getNodeSpan(node) { - return node.kind === 230 /* SourceFile */ - ? ts.createTextSpanFromBounds(node.getFullStart(), node.getEnd()) - : ts.createTextSpanFromBounds(node.getStart(), node.getEnd()); - } - function getTextOfNode(node) { - return ts.getTextOfNodeFromSourceText(sourceFile.text, node); - } - } - NavigationBar.getNavigationBarItems = getNavigationBarItems; - })(NavigationBar = ts.NavigationBar || (ts.NavigationBar = {})); -})(ts || (ts = {})); -/* @internal */ -var ts; -(function (ts) { - // Note(cyrusn): this enum is ordered from strongest match type to weakest match type. - (function (PatternMatchKind) { - PatternMatchKind[PatternMatchKind["exact"] = 0] = "exact"; - PatternMatchKind[PatternMatchKind["prefix"] = 1] = "prefix"; - PatternMatchKind[PatternMatchKind["substring"] = 2] = "substring"; - PatternMatchKind[PatternMatchKind["camelCase"] = 3] = "camelCase"; - })(ts.PatternMatchKind || (ts.PatternMatchKind = {})); - var PatternMatchKind = ts.PatternMatchKind; - function createPatternMatch(kind, punctuationStripped, isCaseSensitive, camelCaseWeight) { - return { - kind: kind, - punctuationStripped: punctuationStripped, - isCaseSensitive: isCaseSensitive, - camelCaseWeight: camelCaseWeight - }; - } - function createPatternMatcher(pattern) { - // We'll often see the same candidate string many times when searching (For example, when - // we see the name of a module that is used everywhere, or the name of an overload). As - // such, we cache the information we compute about the candidate for the life of this - // pattern matcher so we don't have to compute it multiple times. - var stringToWordSpans = {}; - pattern = pattern.trim(); - var fullPatternSegment = createSegment(pattern); - var dotSeparatedSegments = pattern.split(".").map(function (p) { return createSegment(p.trim()); }); - var invalidPattern = dotSeparatedSegments.length === 0 || ts.forEach(dotSeparatedSegments, segmentIsInvalid); - return { - getMatches: getMatches, - getMatchesForLastSegmentOfPattern: getMatchesForLastSegmentOfPattern, - patternContainsDots: dotSeparatedSegments.length > 1 - }; - // Quick checks so we can bail out when asked to match a candidate. - function skipMatch(candidate) { - return invalidPattern || !candidate; - } - function getMatchesForLastSegmentOfPattern(candidate) { - if (skipMatch(candidate)) { - return undefined; - } - return matchSegment(candidate, ts.lastOrUndefined(dotSeparatedSegments)); - } - function getMatches(candidateContainers, candidate) { - if (skipMatch(candidate)) { - return undefined; - } - // First, check that the last part of the dot separated pattern matches the name of the - // candidate. If not, then there's no point in proceeding and doing the more - // expensive work. - var candidateMatch = matchSegment(candidate, ts.lastOrUndefined(dotSeparatedSegments)); - if (!candidateMatch) { - return undefined; - } - candidateContainers = candidateContainers || []; - // -1 because the last part was checked against the name, and only the rest - // of the parts are checked against the container. - if (dotSeparatedSegments.length - 1 > candidateContainers.length) { - // There weren't enough container parts to match against the pattern parts. - // So this definitely doesn't match. - return undefined; - } - // So far so good. Now break up the container for the candidate and check if all - // the dotted parts match up correctly. - var totalMatch = candidateMatch; - for (var i = dotSeparatedSegments.length - 2, j = candidateContainers.length - 1; i >= 0; i--, j--) { - var segment = dotSeparatedSegments[i]; - var containerName = candidateContainers[j]; - var containerMatch = matchSegment(containerName, segment); - if (!containerMatch) { - // This container didn't match the pattern piece. So there's no match at all. - return undefined; - } - ts.addRange(totalMatch, containerMatch); - } - // Success, this symbol's full name matched against the dotted name the user was asking - // about. - return totalMatch; - } - function getWordSpans(word) { - if (!ts.hasProperty(stringToWordSpans, word)) { - stringToWordSpans[word] = breakIntoWordSpans(word); - } - return stringToWordSpans[word]; - } - function matchTextChunk(candidate, chunk, punctuationStripped) { - var index = indexOfIgnoringCase(candidate, chunk.textLowerCase); - if (index === 0) { - if (chunk.text.length === candidate.length) { - // a) Check if the part matches the candidate entirely, in an case insensitive or - // sensitive manner. If it does, return that there was an exact match. - return createPatternMatch(PatternMatchKind.exact, punctuationStripped, candidate === chunk.text); - } - else { - // b) Check if the part is a prefix of the candidate, in a case insensitive or sensitive - // manner. If it does, return that there was a prefix match. - return createPatternMatch(PatternMatchKind.prefix, punctuationStripped, startsWith(candidate, chunk.text)); - } - } - var isLowercase = chunk.isLowerCase; - if (isLowercase) { - if (index > 0) { - // c) If the part is entirely lowercase, then check if it is contained anywhere in the - // candidate in a case insensitive manner. If so, return that there was a substring - // match. - // - // Note: We only have a substring match if the lowercase part is prefix match of some - // word part. That way we don't match something like 'Class' when the user types 'a'. - // But we would match 'FooAttribute' (since 'Attribute' starts with 'a'). - var wordSpans = getWordSpans(candidate); - for (var _i = 0; _i < wordSpans.length; _i++) { - var span = wordSpans[_i]; - if (partStartsWith(candidate, span, chunk.text, true)) { - return createPatternMatch(PatternMatchKind.substring, punctuationStripped, - /*isCaseSensitive:*/ partStartsWith(candidate, span, chunk.text, false)); - } - } - } - } - else { - // d) If the part was not entirely lowercase, then check if it is contained in the - // candidate in a case *sensitive* manner. If so, return that there was a substring - // match. - if (candidate.indexOf(chunk.text) > 0) { - return createPatternMatch(PatternMatchKind.substring, punctuationStripped, true); - } - } - if (!isLowercase) { - // e) If the part was not entirely lowercase, then attempt a camel cased match as well. - if (chunk.characterSpans.length > 0) { - var candidateParts = getWordSpans(candidate); - var camelCaseWeight = tryCamelCaseMatch(candidate, candidateParts, chunk, false); - if (camelCaseWeight !== undefined) { - return createPatternMatch(PatternMatchKind.camelCase, punctuationStripped, true, camelCaseWeight); - } - camelCaseWeight = tryCamelCaseMatch(candidate, candidateParts, chunk, true); - if (camelCaseWeight !== undefined) { - return createPatternMatch(PatternMatchKind.camelCase, punctuationStripped, false, camelCaseWeight); - } - } - } - if (isLowercase) { - // f) Is the pattern a substring of the candidate starting on one of the candidate's word boundaries? - // We could check every character boundary start of the candidate for the pattern. However, that's - // an m * n operation in the wost case. Instead, find the first instance of the pattern - // substring, and see if it starts on a capital letter. It seems unlikely that the user will try to - // filter the list based on a substring that starts on a capital letter and also with a lowercase one. - // (Pattern: fogbar, Candidate: quuxfogbarFogBar). - if (chunk.text.length < candidate.length) { - if (index > 0 && isUpperCaseLetter(candidate.charCodeAt(index))) { - return createPatternMatch(PatternMatchKind.substring, punctuationStripped, false); - } - } - } - return undefined; - } - function containsSpaceOrAsterisk(text) { - for (var i = 0; i < text.length; i++) { - var ch = text.charCodeAt(i); - if (ch === 32 /* space */ || ch === 42 /* asterisk */) { - return true; - } - } - return false; - } - function matchSegment(candidate, segment) { - // First check if the segment matches as is. This is also useful if the segment contains - // characters we would normally strip when splitting into parts that we also may want to - // match in the candidate. For example if the segment is "@int" and the candidate is - // "@int", then that will show up as an exact match here. - // - // Note: if the segment contains a space or an asterisk then we must assume that it's a - // multi-word segment. - if (!containsSpaceOrAsterisk(segment.totalTextChunk.text)) { - var match = matchTextChunk(candidate, segment.totalTextChunk, false); - if (match) { - return [match]; - } - } - // The logic for pattern matching is now as follows: - // - // 1) Break the segment passed in into words. Breaking is rather simple and a - // good way to think about it that if gives you all the individual alphanumeric words - // of the pattern. - // - // 2) For each word try to match the word against the candidate value. - // - // 3) Matching is as follows: - // - // a) Check if the word matches the candidate entirely, in an case insensitive or - // sensitive manner. If it does, return that there was an exact match. - // - // b) Check if the word is a prefix of the candidate, in a case insensitive or - // sensitive manner. If it does, return that there was a prefix match. - // - // c) If the word is entirely lowercase, then check if it is contained anywhere in the - // candidate in a case insensitive manner. If so, return that there was a substring - // match. - // - // Note: We only have a substring match if the lowercase part is prefix match of - // some word part. That way we don't match something like 'Class' when the user - // types 'a'. But we would match 'FooAttribute' (since 'Attribute' starts with - // 'a'). - // - // d) If the word was not entirely lowercase, then check if it is contained in the - // candidate in a case *sensitive* manner. If so, return that there was a substring - // match. - // - // e) If the word was not entirely lowercase, then attempt a camel cased match as - // well. - // - // f) The word is all lower case. Is it a case insensitive substring of the candidate starting - // on a part boundary of the candidate? - // - // Only if all words have some sort of match is the pattern considered matched. - var subWordTextChunks = segment.subWordTextChunks; - var matches = undefined; - for (var _i = 0; _i < subWordTextChunks.length; _i++) { - var subWordTextChunk = subWordTextChunks[_i]; - // Try to match the candidate with this word - var result = matchTextChunk(candidate, subWordTextChunk, true); - if (!result) { - return undefined; - } - matches = matches || []; - matches.push(result); - } - return matches; - } - function partStartsWith(candidate, candidateSpan, pattern, ignoreCase, patternSpan) { - var patternPartStart = patternSpan ? patternSpan.start : 0; - var patternPartLength = patternSpan ? patternSpan.length : pattern.length; - if (patternPartLength > candidateSpan.length) { - // Pattern part is longer than the candidate part. There can never be a match. - return false; - } - if (ignoreCase) { - for (var i = 0; i < patternPartLength; i++) { - var ch1 = pattern.charCodeAt(patternPartStart + i); - var ch2 = candidate.charCodeAt(candidateSpan.start + i); - if (toLowerCase(ch1) !== toLowerCase(ch2)) { - return false; - } - } - } - else { - for (var i = 0; i < patternPartLength; i++) { - var ch1 = pattern.charCodeAt(patternPartStart + i); - var ch2 = candidate.charCodeAt(candidateSpan.start + i); - if (ch1 !== ch2) { - return false; - } - } - } - return true; - } - function tryCamelCaseMatch(candidate, candidateParts, chunk, ignoreCase) { - var chunkCharacterSpans = chunk.characterSpans; - // Note: we may have more pattern parts than candidate parts. This is because multiple - // pattern parts may match a candidate part. For example "SiUI" against "SimpleUI". - // We'll have 3 pattern parts Si/U/I against two candidate parts Simple/UI. However, U - // and I will both match in UI. - var currentCandidate = 0; - var currentChunkSpan = 0; - var firstMatch = undefined; - var contiguous = undefined; - while (true) { - // Let's consider our termination cases - if (currentChunkSpan === chunkCharacterSpans.length) { - // We did match! We shall assign a weight to this - var weight = 0; - // Was this contiguous? - if (contiguous) { - weight += 1; - } - // Did we start at the beginning of the candidate? - if (firstMatch === 0) { - weight += 2; - } - return weight; - } - else if (currentCandidate === candidateParts.length) { - // No match, since we still have more of the pattern to hit - return undefined; - } - var candidatePart = candidateParts[currentCandidate]; - var gotOneMatchThisCandidate = false; - // Consider the case of matching SiUI against SimpleUIElement. The candidate parts - // will be Simple/UI/Element, and the pattern parts will be Si/U/I. We'll match 'Si' - // against 'Simple' first. Then we'll match 'U' against 'UI'. However, we want to - // still keep matching pattern parts against that candidate part. - for (; currentChunkSpan < chunkCharacterSpans.length; currentChunkSpan++) { - var chunkCharacterSpan = chunkCharacterSpans[currentChunkSpan]; - if (gotOneMatchThisCandidate) { - // We've already gotten one pattern part match in this candidate. We will - // only continue trying to consumer pattern parts if the last part and this - // part are both upper case. - if (!isUpperCaseLetter(chunk.text.charCodeAt(chunkCharacterSpans[currentChunkSpan - 1].start)) || - !isUpperCaseLetter(chunk.text.charCodeAt(chunkCharacterSpans[currentChunkSpan].start))) { - break; - } - } - if (!partStartsWith(candidate, candidatePart, chunk.text, ignoreCase, chunkCharacterSpan)) { - break; - } - gotOneMatchThisCandidate = true; - firstMatch = firstMatch === undefined ? currentCandidate : firstMatch; - // If we were contiguous, then keep that value. If we weren't, then keep that - // value. If we don't know, then set the value to 'true' as an initial match is - // obviously contiguous. - contiguous = contiguous === undefined ? true : contiguous; - candidatePart = ts.createTextSpan(candidatePart.start + chunkCharacterSpan.length, candidatePart.length - chunkCharacterSpan.length); - } - // Check if we matched anything at all. If we didn't, then we need to unset the - // contiguous bit if we currently had it set. - // If we haven't set the bit yet, then that means we haven't matched anything so - // far, and we don't want to change that. - if (!gotOneMatchThisCandidate && contiguous !== undefined) { - contiguous = false; - } - // Move onto the next candidate. - currentCandidate++; - } - } - } - ts.createPatternMatcher = createPatternMatcher; - // Helper function to compare two matches to determine which is better. Matches are first - // ordered by kind (so all prefix matches always beat all substring matches). Then, if the - // match is a camel case match, the relative weights of the match are used to determine - // which is better (with a greater weight being better). Then if the match is of the same - // type, then a case sensitive match is considered better than an insensitive one. - function patternMatchCompareTo(match1, match2) { - return compareType(match1, match2) || - compareCamelCase(match1, match2) || - compareCase(match1, match2) || - comparePunctuation(match1, match2); - } - function comparePunctuation(result1, result2) { - // Consider a match to be better if it was successful without stripping punctuation - // versus a match that had to strip punctuation to succeed. - if (result1.punctuationStripped !== result2.punctuationStripped) { - return result1.punctuationStripped ? 1 : -1; - } - return 0; - } - function compareCase(result1, result2) { - if (result1.isCaseSensitive !== result2.isCaseSensitive) { - return result1.isCaseSensitive ? -1 : 1; - } - return 0; - } - function compareType(result1, result2) { - return result1.kind - result2.kind; - } - function compareCamelCase(result1, result2) { - if (result1.kind === PatternMatchKind.camelCase && result2.kind === PatternMatchKind.camelCase) { - // Swap the values here. If result1 has a higher weight, then we want it to come - // first. - return result2.camelCaseWeight - result1.camelCaseWeight; - } - return 0; - } - function createSegment(text) { - return { - totalTextChunk: createTextChunk(text), - subWordTextChunks: breakPatternIntoTextChunks(text) - }; - } - // A segment is considered invalid if we couldn't find any words in it. - function segmentIsInvalid(segment) { - return segment.subWordTextChunks.length === 0; - } - function isUpperCaseLetter(ch) { - // Fast check for the ascii range. - if (ch >= 65 /* A */ && ch <= 90 /* Z */) { - return true; - } - if (ch < 127 /* maxAsciiCharacter */ || !ts.isUnicodeIdentifierStart(ch, 2 /* Latest */)) { - return false; - } - // TODO: find a way to determine this for any unicode characters in a - // non-allocating manner. - var str = String.fromCharCode(ch); - return str === str.toUpperCase(); - } - function isLowerCaseLetter(ch) { - // Fast check for the ascii range. - if (ch >= 97 /* a */ && ch <= 122 /* z */) { - return true; - } - if (ch < 127 /* maxAsciiCharacter */ || !ts.isUnicodeIdentifierStart(ch, 2 /* Latest */)) { - return false; - } - // TODO: find a way to determine this for any unicode characters in a - // non-allocating manner. - var str = String.fromCharCode(ch); - return str === str.toLowerCase(); - } - function containsUpperCaseLetter(string) { - for (var i = 0, n = string.length; i < n; i++) { - if (isUpperCaseLetter(string.charCodeAt(i))) { - return true; - } - } - return false; - } - function startsWith(string, search) { - for (var i = 0, n = search.length; i < n; i++) { - if (string.charCodeAt(i) !== search.charCodeAt(i)) { - return false; - } - } - return true; - } - // Assumes 'value' is already lowercase. - function indexOfIgnoringCase(string, value) { - for (var i = 0, n = string.length - value.length; i <= n; i++) { - if (startsWithIgnoringCase(string, value, i)) { - return i; - } - } - return -1; - } - // Assumes 'value' is already lowercase. - function startsWithIgnoringCase(string, value, start) { - for (var i = 0, n = value.length; i < n; i++) { - var ch1 = toLowerCase(string.charCodeAt(i + start)); - var ch2 = value.charCodeAt(i); - if (ch1 !== ch2) { - return false; - } - } - return true; - } - function toLowerCase(ch) { - // Fast convert for the ascii range. - if (ch >= 65 /* A */ && ch <= 90 /* Z */) { - return 97 /* a */ + (ch - 65 /* A */); - } - if (ch < 127 /* maxAsciiCharacter */) { - return ch; - } - // TODO: find a way to compute this for any unicode characters in a - // non-allocating manner. - return String.fromCharCode(ch).toLowerCase().charCodeAt(0); - } - function isDigit(ch) { - // TODO(cyrusn): Find a way to support this for unicode digits. - return ch >= 48 /* _0 */ && ch <= 57 /* _9 */; - } - function isWordChar(ch) { - return isUpperCaseLetter(ch) || isLowerCaseLetter(ch) || isDigit(ch) || ch === 95 /* _ */ || ch === 36 /* $ */; - } - function breakPatternIntoTextChunks(pattern) { - var result = []; - var wordStart = 0; - var wordLength = 0; - for (var i = 0; i < pattern.length; i++) { - var ch = pattern.charCodeAt(i); - if (isWordChar(ch)) { - if (wordLength++ === 0) { - wordStart = i; - } - } - else { - if (wordLength > 0) { - result.push(createTextChunk(pattern.substr(wordStart, wordLength))); - wordLength = 0; - } - } - } - if (wordLength > 0) { - result.push(createTextChunk(pattern.substr(wordStart, wordLength))); - } - return result; - } - function createTextChunk(text) { - var textLowerCase = text.toLowerCase(); - return { - text: text, - textLowerCase: textLowerCase, - isLowerCase: text === textLowerCase, - characterSpans: breakIntoCharacterSpans(text) - }; - } - /* @internal */ function breakIntoCharacterSpans(identifier) { - return breakIntoSpans(identifier, false); - } - ts.breakIntoCharacterSpans = breakIntoCharacterSpans; - /* @internal */ function breakIntoWordSpans(identifier) { - return breakIntoSpans(identifier, true); - } - ts.breakIntoWordSpans = breakIntoWordSpans; - function breakIntoSpans(identifier, word) { - var result = []; - var wordStart = 0; - for (var i = 1, n = identifier.length; i < n; i++) { - var lastIsDigit = isDigit(identifier.charCodeAt(i - 1)); - var currentIsDigit = isDigit(identifier.charCodeAt(i)); - var hasTransitionFromLowerToUpper = transitionFromLowerToUpper(identifier, word, i); - var hasTransitionFromUpperToLower = transitionFromUpperToLower(identifier, word, i, wordStart); - if (charIsPunctuation(identifier.charCodeAt(i - 1)) || - charIsPunctuation(identifier.charCodeAt(i)) || - lastIsDigit != currentIsDigit || - hasTransitionFromLowerToUpper || - hasTransitionFromUpperToLower) { - if (!isAllPunctuation(identifier, wordStart, i)) { - result.push(ts.createTextSpan(wordStart, i - wordStart)); - } - wordStart = i; - } - } - if (!isAllPunctuation(identifier, wordStart, identifier.length)) { - result.push(ts.createTextSpan(wordStart, identifier.length - wordStart)); - } - return result; - } - function charIsPunctuation(ch) { - switch (ch) { - case 33 /* exclamation */: - case 34 /* doubleQuote */: - case 35 /* hash */: - case 37 /* percent */: - case 38 /* ampersand */: - case 39 /* singleQuote */: - case 40 /* openParen */: - case 41 /* closeParen */: - case 42 /* asterisk */: - case 44 /* comma */: - case 45 /* minus */: - case 46 /* dot */: - case 47 /* slash */: - case 58 /* colon */: - case 59 /* semicolon */: - case 63 /* question */: - case 64 /* at */: - case 91 /* openBracket */: - case 92 /* backslash */: - case 93 /* closeBracket */: - case 95 /* _ */: - case 123 /* openBrace */: - case 125 /* closeBrace */: - return true; - } - return false; - } - function isAllPunctuation(identifier, start, end) { - for (var i = start; i < end; i++) { - var ch = identifier.charCodeAt(i); - // We don't consider _ or $ as punctuation as there may be things with that name. - if (!charIsPunctuation(ch) || ch === 95 /* _ */ || ch === 36 /* $ */) { - return false; - } - } - return true; - } - function transitionFromUpperToLower(identifier, word, index, wordStart) { - if (word) { - // Cases this supports: - // 1) IDisposable -> I, Disposable - // 2) UIElement -> UI, Element - // 3) HTMLDocument -> HTML, Document - // - // etc. - if (index != wordStart && - index + 1 < identifier.length) { - var currentIsUpper = isUpperCaseLetter(identifier.charCodeAt(index)); - var nextIsLower = isLowerCaseLetter(identifier.charCodeAt(index + 1)); - if (currentIsUpper && nextIsLower) { - // We have a transition from an upper to a lower letter here. But we only - // want to break if all the letters that preceded are uppercase. i.e. if we - // have "Foo" we don't want to break that into "F, oo". But if we have - // "IFoo" or "UIFoo", then we want to break that into "I, Foo" and "UI, - // Foo". i.e. the last uppercase letter belongs to the lowercase letters - // that follows. Note: this will make the following not split properly: - // "HELLOthere". However, these sorts of names do not show up in .Net - // programs. - for (var i = wordStart; i < index; i++) { - if (!isUpperCaseLetter(identifier.charCodeAt(i))) { - return false; - } - } - return true; - } - } - } - return false; - } - function transitionFromLowerToUpper(identifier, word, index) { - var lastIsUpper = isUpperCaseLetter(identifier.charCodeAt(index - 1)); - var currentIsUpper = isUpperCaseLetter(identifier.charCodeAt(index)); - // See if the casing indicates we're starting a new word. Note: if we're breaking on - // words, then just seeing an upper case character isn't enough. Instead, it has to - // be uppercase and the previous character can't be uppercase. - // - // For example, breaking "AddMetadata" on words would make: Add Metadata - // - // on characters would be: A dd M etadata - // - // Break "AM" on words would be: AM - // - // on characters would be: A M - // - // We break the search string on characters. But we break the symbol name on words. - var transition = word - ? (currentIsUpper && !lastIsUpper) - : currentIsUpper; - return transition; - } -})(ts || (ts = {})); -/// -/* @internal */ -var ts; -(function (ts) { - var SignatureHelp; - (function (SignatureHelp) { - // A partially written generic type expression is not guaranteed to have the correct syntax tree. the expression could be parsed as less than/greater than expression or a comma expression - // or some other combination depending on what the user has typed so far. For the purposes of signature help we need to consider any location after "<" as a possible generic type reference. - // To do this, the method will back parse the expression starting at the position required. it will try to parse the current expression as a generic type expression, if it did succeed it - // will return the generic identifier that started the expression (e.g. "foo" in "foo(#a, b) -> The token introduces a list, and should begin a sig help session - // Case 2: - // fo#o#(a, b)# -> The token is either not associated with a list, or ends a list, so the session should end - // Case 3: - // foo(a#, #b#) -> The token is buried inside a list, and should give sig help - // Find out if 'node' is an argument, a type argument, or neither - if (node.kind === 24 /* LessThanToken */ || - node.kind === 16 /* OpenParenToken */) { - // Find the list that starts right *after* the < or ( token. - // If the user has just opened a list, consider this item 0. - var list = getChildListThatStartsWithOpenerToken(callExpression, node, sourceFile); - var isTypeArgList = callExpression.typeArguments && callExpression.typeArguments.pos === list.pos; - ts.Debug.assert(list !== undefined); - return { - kind: isTypeArgList ? 0 /* TypeArguments */ : 1 /* CallArguments */, - invocation: callExpression, - argumentsSpan: getApplicableSpanForArguments(list), - argumentIndex: 0, - argumentCount: getArgumentCount(list) - }; - } - // findListItemInfo can return undefined if we are not in parent's argument list - // or type argument list. This includes cases where the cursor is: - // - To the right of the closing paren, non-substitution template, or template tail. - // - Between the type arguments and the arguments (greater than token) - // - On the target of the call (parent.func) - // - On the 'new' keyword in a 'new' expression - var listItemInfo = ts.findListItemInfo(node); - if (listItemInfo) { - var list = listItemInfo.list; - var isTypeArgList = callExpression.typeArguments && callExpression.typeArguments.pos === list.pos; - var argumentIndex = getArgumentIndex(list, node); - var argumentCount = getArgumentCount(list); - ts.Debug.assert(argumentIndex === 0 || argumentIndex < argumentCount, "argumentCount < argumentIndex, " + argumentCount + " < " + argumentIndex); - return { - kind: isTypeArgList ? 0 /* TypeArguments */ : 1 /* CallArguments */, - invocation: callExpression, - argumentsSpan: getApplicableSpanForArguments(list), - argumentIndex: argumentIndex, - argumentCount: argumentCount - }; - } - } - else if (node.kind === 10 /* NoSubstitutionTemplateLiteral */ && node.parent.kind === 162 /* TaggedTemplateExpression */) { - // Check if we're actually inside the template; - // otherwise we'll fall out and return undefined. - if (ts.isInsideTemplateLiteral(node, position)) { - return getArgumentListInfoForTemplate(node.parent, 0); - } - } - else if (node.kind === 11 /* TemplateHead */ && node.parent.parent.kind === 162 /* TaggedTemplateExpression */) { - var templateExpression = node.parent; - var tagExpression = templateExpression.parent; - ts.Debug.assert(templateExpression.kind === 174 /* TemplateExpression */); - var argumentIndex = ts.isInsideTemplateLiteral(node, position) ? 0 : 1; - return getArgumentListInfoForTemplate(tagExpression, argumentIndex); - } - else if (node.parent.kind === 180 /* TemplateSpan */ && node.parent.parent.parent.kind === 162 /* TaggedTemplateExpression */) { - var templateSpan = node.parent; - var templateExpression = templateSpan.parent; - var tagExpression = templateExpression.parent; - ts.Debug.assert(templateExpression.kind === 174 /* TemplateExpression */); - // If we're just after a template tail, don't show signature help. - if (node.kind === 13 /* TemplateTail */ && !ts.isInsideTemplateLiteral(node, position)) { - return undefined; - } - var spanIndex = templateExpression.templateSpans.indexOf(templateSpan); - var argumentIndex = getArgumentIndexForTemplatePiece(spanIndex, node); - return getArgumentListInfoForTemplate(tagExpression, argumentIndex); - } - return undefined; - } - function getArgumentIndex(argumentsList, node) { - // The list we got back can include commas. In the presence of errors it may - // also just have nodes without commas. For example "Foo(a b c)" will have 3 - // args without commas. We want to find what index we're at. So we count - // forward until we hit ourselves, only incrementing the index if it isn't a - // comma. - // - // Note: the subtlety around trailing commas (in getArgumentCount) does not apply - // here. That's because we're only walking forward until we hit the node we're - // on. In that case, even if we're after the trailing comma, we'll still see - // that trailing comma in the list, and we'll have generated the appropriate - // arg index. - var argumentIndex = 0; - var listChildren = argumentsList.getChildren(); - for (var _i = 0; _i < listChildren.length; _i++) { - var child = listChildren[_i]; - if (child === node) { - break; - } - if (child.kind !== 23 /* CommaToken */) { - argumentIndex++; - } - } - return argumentIndex; - } - function getArgumentCount(argumentsList) { - // The argument count for a list is normally the number of non-comma children it has. - // For example, if you have "Foo(a,b)" then there will be three children of the arg - // list 'a' '' 'b'. So, in this case the arg count will be 2. However, there - // is a small subtlety. If you have "Foo(a,)", then the child list will just have - // 'a' ''. So, in the case where the last child is a comma, we increase the - // arg count by one to compensate. - // - // Note: this subtlety only applies to the last comma. If you had "Foo(a,," then - // we'll have: 'a' '' '' - // That will give us 2 non-commas. We then add one for the last comma, givin us an - // arg count of 3. - var listChildren = argumentsList.getChildren(); - var argumentCount = ts.countWhere(listChildren, function (arg) { return arg.kind !== 23 /* CommaToken */; }); - if (listChildren.length > 0 && ts.lastOrUndefined(listChildren).kind === 23 /* CommaToken */) { - argumentCount++; - } - return argumentCount; - } - // spanIndex is either the index for a given template span. - // This does not give appropriate results for a NoSubstitutionTemplateLiteral - function getArgumentIndexForTemplatePiece(spanIndex, node) { - // Because the TemplateStringsArray is the first argument, we have to offset each substitution expression by 1. - // There are three cases we can encounter: - // 1. We are precisely in the template literal (argIndex = 0). - // 2. We are in or to the right of the substitution expression (argIndex = spanIndex + 1). - // 3. We are directly to the right of the template literal, but because we look for the token on the left, - // not enough to put us in the substitution expression; we should consider ourselves part of - // the *next* span's expression by offsetting the index (argIndex = (spanIndex + 1) + 1). - // - // Example: f `# abcd $#{# 1 + 1# }# efghi ${ #"#hello"# } # ` - // ^ ^ ^ ^ ^ ^ ^ ^ ^ - // Case: 1 1 3 2 1 3 2 2 1 - ts.Debug.assert(position >= node.getStart(), "Assumed 'position' could not occur before node."); - if (ts.isTemplateLiteralKind(node.kind)) { - if (ts.isInsideTemplateLiteral(node, position)) { - return 0; - } - return spanIndex + 2; - } - return spanIndex + 1; - } - function getArgumentListInfoForTemplate(tagExpression, argumentIndex) { - // argumentCount is either 1 or (numSpans + 1) to account for the template strings array argument. - var argumentCount = tagExpression.template.kind === 10 /* NoSubstitutionTemplateLiteral */ - ? 1 - : tagExpression.template.templateSpans.length + 1; - ts.Debug.assert(argumentIndex === 0 || argumentIndex < argumentCount, "argumentCount < argumentIndex, " + argumentCount + " < " + argumentIndex); - return { - kind: 2 /* TaggedTemplateArguments */, - invocation: tagExpression, - argumentsSpan: getApplicableSpanForTaggedTemplate(tagExpression), - argumentIndex: argumentIndex, - argumentCount: argumentCount - }; - } - function getApplicableSpanForArguments(argumentsList) { - // We use full start and skip trivia on the end because we want to include trivia on - // both sides. For example, - // - // foo( /*comment */ a, b, c /*comment*/ ) - // | | - // - // The applicable span is from the first bar to the second bar (inclusive, - // but not including parentheses) - var applicableSpanStart = argumentsList.getFullStart(); - var applicableSpanEnd = ts.skipTrivia(sourceFile.text, argumentsList.getEnd(), false); - return ts.createTextSpan(applicableSpanStart, applicableSpanEnd - applicableSpanStart); - } - function getApplicableSpanForTaggedTemplate(taggedTemplate) { - var template = taggedTemplate.template; - var applicableSpanStart = template.getStart(); - var applicableSpanEnd = template.getEnd(); - // We need to adjust the end position for the case where the template does not have a tail. - // Otherwise, we will not show signature help past the expression. - // For example, - // - // ` ${ 1 + 1 foo(10) - // | | - // - // This is because a Missing node has no width. However, what we actually want is to include trivia - // leading up to the next token in case the user is about to type in a TemplateMiddle or TemplateTail. - if (template.kind === 174 /* TemplateExpression */) { - var lastSpan = ts.lastOrUndefined(template.templateSpans); - if (lastSpan.literal.getFullWidth() === 0) { - applicableSpanEnd = ts.skipTrivia(sourceFile.text, applicableSpanEnd, false); - } - } - return ts.createTextSpan(applicableSpanStart, applicableSpanEnd - applicableSpanStart); - } - function getContainingArgumentInfo(node) { - for (var n = node; n.kind !== 230 /* SourceFile */; n = n.parent) { - if (ts.isFunctionBlock(n)) { - return undefined; - } - // If the node is not a subspan of its parent, this is a big problem. - // There have been crashes that might be caused by this violation. - if (n.pos < n.parent.pos || n.end > n.parent.end) { - ts.Debug.fail("Node of kind " + n.kind + " is not a subspan of its parent of kind " + n.parent.kind); - } - var argumentInfo_1 = getImmediatelyContainingArgumentInfo(n); - if (argumentInfo_1) { - return argumentInfo_1; - } - } - return undefined; - } - function getChildListThatStartsWithOpenerToken(parent, openerToken, sourceFile) { - var children = parent.getChildren(sourceFile); - var indexOfOpenerToken = children.indexOf(openerToken); - ts.Debug.assert(indexOfOpenerToken >= 0 && children.length > indexOfOpenerToken + 1); - return children[indexOfOpenerToken + 1]; - } - /** - * The selectedItemIndex could be negative for several reasons. - * 1. There are too many arguments for all of the overloads - * 2. None of the overloads were type compatible - * The solution here is to try to pick the best overload by picking - * either the first one that has an appropriate number of parameters, - * or the one with the most parameters. - */ - function selectBestInvalidOverloadIndex(candidates, argumentCount) { - var maxParamsSignatureIndex = -1; - var maxParams = -1; - for (var i = 0; i < candidates.length; i++) { - var candidate = candidates[i]; - if (candidate.hasRestParameter || candidate.parameters.length >= argumentCount) { - return i; - } - if (candidate.parameters.length > maxParams) { - maxParams = candidate.parameters.length; - maxParamsSignatureIndex = i; - } - } - return maxParamsSignatureIndex; - } - function createSignatureHelpItems(candidates, bestSignature, argumentListInfo) { - var applicableSpan = argumentListInfo.argumentsSpan; - var isTypeParameterList = argumentListInfo.kind === 0 /* TypeArguments */; - var invocation = argumentListInfo.invocation; - var callTarget = ts.getInvokedExpression(invocation); - var callTargetSymbol = typeChecker.getSymbolAtLocation(callTarget); - var callTargetDisplayParts = callTargetSymbol && ts.symbolToDisplayParts(typeChecker, callTargetSymbol, undefined, undefined); - var items = ts.map(candidates, function (candidateSignature) { - var signatureHelpParameters; - var prefixDisplayParts = []; - var suffixDisplayParts = []; - if (callTargetDisplayParts) { - prefixDisplayParts.push.apply(prefixDisplayParts, callTargetDisplayParts); - } - if (isTypeParameterList) { - prefixDisplayParts.push(ts.punctuationPart(24 /* LessThanToken */)); - var typeParameters = candidateSignature.typeParameters; - signatureHelpParameters = typeParameters && typeParameters.length > 0 ? ts.map(typeParameters, createSignatureHelpParameterForTypeParameter) : emptyArray; - suffixDisplayParts.push(ts.punctuationPart(25 /* GreaterThanToken */)); - var parameterParts = ts.mapToDisplayParts(function (writer) { - return typeChecker.getSymbolDisplayBuilder().buildDisplayForParametersAndDelimiters(candidateSignature.parameters, writer, invocation); - }); - suffixDisplayParts.push.apply(suffixDisplayParts, parameterParts); - } - else { - var typeParameterParts = ts.mapToDisplayParts(function (writer) { - return typeChecker.getSymbolDisplayBuilder().buildDisplayForTypeParametersAndDelimiters(candidateSignature.typeParameters, writer, invocation); - }); - prefixDisplayParts.push.apply(prefixDisplayParts, typeParameterParts); - prefixDisplayParts.push(ts.punctuationPart(16 /* OpenParenToken */)); - var parameters = candidateSignature.parameters; - signatureHelpParameters = parameters.length > 0 ? ts.map(parameters, createSignatureHelpParameterForParameter) : emptyArray; - suffixDisplayParts.push(ts.punctuationPart(17 /* CloseParenToken */)); - } - var returnTypeParts = ts.mapToDisplayParts(function (writer) { - return typeChecker.getSymbolDisplayBuilder().buildReturnTypeDisplay(candidateSignature, writer, invocation); - }); - suffixDisplayParts.push.apply(suffixDisplayParts, returnTypeParts); - return { - isVariadic: candidateSignature.hasRestParameter, - prefixDisplayParts: prefixDisplayParts, - suffixDisplayParts: suffixDisplayParts, - separatorDisplayParts: [ts.punctuationPart(23 /* CommaToken */), ts.spacePart()], - parameters: signatureHelpParameters, - documentation: candidateSignature.getDocumentationComment() - }; - }); - var argumentIndex = argumentListInfo.argumentIndex; - // argumentCount is the *apparent* number of arguments. - var argumentCount = argumentListInfo.argumentCount; - var selectedItemIndex = candidates.indexOf(bestSignature); - if (selectedItemIndex < 0) { - selectedItemIndex = selectBestInvalidOverloadIndex(candidates, argumentCount); - } - ts.Debug.assert(argumentIndex === 0 || argumentIndex < argumentCount, "argumentCount < argumentIndex, " + argumentCount + " < " + argumentIndex); - return { - items: items, - applicableSpan: applicableSpan, - selectedItemIndex: selectedItemIndex, - argumentIndex: argumentIndex, - argumentCount: argumentCount - }; - function createSignatureHelpParameterForParameter(parameter) { - var displayParts = ts.mapToDisplayParts(function (writer) { - return typeChecker.getSymbolDisplayBuilder().buildParameterDisplay(parameter, writer, invocation); - }); - var isOptional = ts.hasQuestionToken(parameter.valueDeclaration); - return { - name: parameter.name, - documentation: parameter.getDocumentationComment(), - displayParts: displayParts, - isOptional: isOptional - }; - } - function createSignatureHelpParameterForTypeParameter(typeParameter) { - var displayParts = ts.mapToDisplayParts(function (writer) { - return typeChecker.getSymbolDisplayBuilder().buildTypeParameterDisplay(typeParameter, writer, invocation); - }); - return { - name: typeParameter.symbol.name, - documentation: emptyArray, - displayParts: displayParts, - isOptional: false - }; - } - } - } - SignatureHelp.getSignatureHelpItems = getSignatureHelpItems; - })(SignatureHelp = ts.SignatureHelp || (ts.SignatureHelp = {})); -})(ts || (ts = {})); -// These utilities are common to multiple language service features. -/* @internal */ -var ts; -(function (ts) { - function getEndLinePosition(line, sourceFile) { - ts.Debug.assert(line >= 0); - var lineStarts = sourceFile.getLineStarts(); - var lineIndex = line; - if (lineIndex + 1 === lineStarts.length) { - // last line - return EOF - return sourceFile.text.length - 1; - } - else { - // current line start - var start = lineStarts[lineIndex]; - // take the start position of the next line -1 = it should be some line break - var pos = lineStarts[lineIndex + 1] - 1; - ts.Debug.assert(ts.isLineBreak(sourceFile.text.charCodeAt(pos))); - // walk backwards skipping line breaks, stop the the beginning of current line. - // i.e: - // - // $ <- end of line for this position should match the start position - while (start <= pos && ts.isLineBreak(sourceFile.text.charCodeAt(pos))) { - pos--; - } - return pos; - } - } - ts.getEndLinePosition = getEndLinePosition; - function getLineStartPositionForPosition(position, sourceFile) { - var lineStarts = sourceFile.getLineStarts(); - var line = sourceFile.getLineAndCharacterOfPosition(position).line; - return lineStarts[line]; - } - ts.getLineStartPositionForPosition = getLineStartPositionForPosition; - function rangeContainsRange(r1, r2) { - return startEndContainsRange(r1.pos, r1.end, r2); - } - ts.rangeContainsRange = rangeContainsRange; - function startEndContainsRange(start, end, range) { - return start <= range.pos && end >= range.end; - } - ts.startEndContainsRange = startEndContainsRange; - function rangeContainsStartEnd(range, start, end) { - return range.pos <= start && range.end >= end; - } - ts.rangeContainsStartEnd = rangeContainsStartEnd; - function rangeOverlapsWithStartEnd(r1, start, end) { - return startEndOverlapsWithStartEnd(r1.pos, r1.end, start, end); - } - ts.rangeOverlapsWithStartEnd = rangeOverlapsWithStartEnd; - function startEndOverlapsWithStartEnd(start1, end1, start2, end2) { - var start = Math.max(start1, start2); - var end = Math.min(end1, end2); - return start < end; - } - ts.startEndOverlapsWithStartEnd = startEndOverlapsWithStartEnd; - function positionBelongsToNode(candidate, position, sourceFile) { - return candidate.end > position || !isCompletedNode(candidate, sourceFile); - } - ts.positionBelongsToNode = positionBelongsToNode; - function isCompletedNode(n, sourceFile) { - if (ts.nodeIsMissing(n)) { - return false; - } - switch (n.kind) { - case 204 /* ClassDeclaration */: - case 205 /* InterfaceDeclaration */: - case 207 /* EnumDeclaration */: - case 157 /* ObjectLiteralExpression */: - case 153 /* ObjectBindingPattern */: - case 148 /* TypeLiteral */: - case 182 /* Block */: - case 209 /* ModuleBlock */: - case 210 /* CaseBlock */: - return nodeEndsWith(n, 15 /* CloseBraceToken */, sourceFile); - case 226 /* CatchClause */: - return isCompletedNode(n.block, sourceFile); - case 161 /* NewExpression */: - if (!n.arguments) { - return true; - } - // fall through - case 160 /* CallExpression */: - case 164 /* ParenthesizedExpression */: - case 152 /* ParenthesizedType */: - return nodeEndsWith(n, 17 /* CloseParenToken */, sourceFile); - case 145 /* FunctionType */: - case 146 /* ConstructorType */: - return isCompletedNode(n.type, sourceFile); - case 137 /* Constructor */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 203 /* FunctionDeclaration */: - case 165 /* FunctionExpression */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 141 /* ConstructSignature */: - case 140 /* CallSignature */: - case 166 /* ArrowFunction */: - if (n.body) { - return isCompletedNode(n.body, sourceFile); - } - if (n.type) { - return isCompletedNode(n.type, sourceFile); - } - // Even though type parameters can be unclosed, we can get away with - // having at least a closing paren. - return hasChildOfKind(n, 17 /* CloseParenToken */, sourceFile); - case 208 /* ModuleDeclaration */: - return n.body && isCompletedNode(n.body, sourceFile); - case 186 /* IfStatement */: - if (n.elseStatement) { - return isCompletedNode(n.elseStatement, sourceFile); - } - return isCompletedNode(n.thenStatement, sourceFile); - case 185 /* ExpressionStatement */: - return isCompletedNode(n.expression, sourceFile); - case 156 /* ArrayLiteralExpression */: - case 154 /* ArrayBindingPattern */: - case 159 /* ElementAccessExpression */: - case 129 /* ComputedPropertyName */: - case 150 /* TupleType */: - return nodeEndsWith(n, 19 /* CloseBracketToken */, sourceFile); - case 142 /* IndexSignature */: - if (n.type) { - return isCompletedNode(n.type, sourceFile); - } - return hasChildOfKind(n, 19 /* CloseBracketToken */, sourceFile); - case 223 /* CaseClause */: - case 224 /* DefaultClause */: - // there is no such thing as terminator token for CaseClause/DefaultClause so for simplicitly always consider them non-completed - return false; - case 189 /* ForStatement */: - case 190 /* ForInStatement */: - case 191 /* ForOfStatement */: - case 188 /* WhileStatement */: - return isCompletedNode(n.statement, sourceFile); - case 187 /* DoStatement */: - // rough approximation: if DoStatement has While keyword - then if node is completed is checking the presence of ')'; - var hasWhileKeyword = findChildOfKind(n, 100 /* WhileKeyword */, sourceFile); - if (hasWhileKeyword) { - return nodeEndsWith(n, 17 /* CloseParenToken */, sourceFile); - } - return isCompletedNode(n.statement, sourceFile); - case 147 /* TypeQuery */: - return isCompletedNode(n.exprName, sourceFile); - case 168 /* TypeOfExpression */: - case 167 /* DeleteExpression */: - case 169 /* VoidExpression */: - case 175 /* YieldExpression */: - case 176 /* SpreadElementExpression */: - var unaryWordExpression = n; - return isCompletedNode(unaryWordExpression.expression, sourceFile); - case 162 /* TaggedTemplateExpression */: - return isCompletedNode(n.template, sourceFile); - case 174 /* TemplateExpression */: - var lastSpan = ts.lastOrUndefined(n.templateSpans); - return isCompletedNode(lastSpan, sourceFile); - case 180 /* TemplateSpan */: - return ts.nodeIsPresent(n.literal); - case 170 /* PrefixUnaryExpression */: - return isCompletedNode(n.operand, sourceFile); - case 172 /* BinaryExpression */: - return isCompletedNode(n.right, sourceFile); - case 173 /* ConditionalExpression */: - return isCompletedNode(n.whenFalse, sourceFile); - default: - return true; - } - } - ts.isCompletedNode = isCompletedNode; - /* - * Checks if node ends with 'expectedLastToken'. - * If child at position 'length - 1' is 'SemicolonToken' it is skipped and 'expectedLastToken' is compared with child at position 'length - 2'. - */ - function nodeEndsWith(n, expectedLastToken, sourceFile) { - var children = n.getChildren(sourceFile); - if (children.length) { - var last = ts.lastOrUndefined(children); - if (last.kind === expectedLastToken) { - return true; - } - else if (last.kind === 22 /* SemicolonToken */ && children.length !== 1) { - return children[children.length - 2].kind === expectedLastToken; - } - } - return false; - } - function findListItemInfo(node) { - var list = findContainingList(node); - // It is possible at this point for syntaxList to be undefined, either if - // node.parent had no list child, or if none of its list children contained - // the span of node. If this happens, return undefined. The caller should - // handle this case. - if (!list) { - return undefined; - } - var children = list.getChildren(); - var listItemIndex = ts.indexOf(children, node); - return { - listItemIndex: listItemIndex, - list: list - }; - } - ts.findListItemInfo = findListItemInfo; - function hasChildOfKind(n, kind, sourceFile) { - return !!findChildOfKind(n, kind, sourceFile); - } - ts.hasChildOfKind = hasChildOfKind; - function findChildOfKind(n, kind, sourceFile) { - return ts.forEach(n.getChildren(sourceFile), function (c) { return c.kind === kind && c; }); - } - ts.findChildOfKind = findChildOfKind; - function findContainingList(node) { - // The node might be a list element (nonsynthetic) or a comma (synthetic). Either way, it will - // be parented by the container of the SyntaxList, not the SyntaxList itself. - // In order to find the list item index, we first need to locate SyntaxList itself and then search - // for the position of the relevant node (or comma). - var syntaxList = ts.forEach(node.parent.getChildren(), function (c) { - // find syntax list that covers the span of the node - if (c.kind === 253 /* SyntaxList */ && c.pos <= node.pos && c.end >= node.end) { - return c; - } - }); - // Either we didn't find an appropriate list, or the list must contain us. - ts.Debug.assert(!syntaxList || ts.contains(syntaxList.getChildren(), node)); - return syntaxList; - } - ts.findContainingList = findContainingList; - /* Gets the token whose text has range [start, end) and - * position >= start and (position < end or (position === end && token is keyword or identifier)) - */ - function getTouchingWord(sourceFile, position) { - return getTouchingToken(sourceFile, position, function (n) { return isWord(n.kind); }); - } - ts.getTouchingWord = getTouchingWord; - /* Gets the token whose text has range [start, end) and position >= start - * and (position < end or (position === end && token is keyword or identifier or numeric\string litera)) - */ - function getTouchingPropertyName(sourceFile, position) { - return getTouchingToken(sourceFile, position, function (n) { return isPropertyName(n.kind); }); - } - ts.getTouchingPropertyName = getTouchingPropertyName; - /** Returns the token if position is in [start, end) or if position === end and includeItemAtEndPosition(token) === true */ - function getTouchingToken(sourceFile, position, includeItemAtEndPosition) { - return getTokenAtPositionWorker(sourceFile, position, false, includeItemAtEndPosition); - } - ts.getTouchingToken = getTouchingToken; - /** Returns a token if position is in [start-of-leading-trivia, end) */ - function getTokenAtPosition(sourceFile, position) { - return getTokenAtPositionWorker(sourceFile, position, true, undefined); - } - ts.getTokenAtPosition = getTokenAtPosition; - /** Get the token whose text contains the position */ - function getTokenAtPositionWorker(sourceFile, position, allowPositionInLeadingTrivia, includeItemAtEndPosition) { - var current = sourceFile; - outer: while (true) { - if (isToken(current)) { - // exit early - return current; - } - // find the child that contains 'position' - for (var i = 0, n = current.getChildCount(sourceFile); i < n; i++) { - var child = current.getChildAt(i); - var start = allowPositionInLeadingTrivia ? child.getFullStart() : child.getStart(sourceFile); - if (start <= position) { - var end = child.getEnd(); - if (position < end || (position === end && child.kind === 1 /* EndOfFileToken */)) { - current = child; - continue outer; - } - else if (includeItemAtEndPosition && end === position) { - var previousToken = findPrecedingToken(position, sourceFile, child); - if (previousToken && includeItemAtEndPosition(previousToken)) { - return previousToken; - } - } - } - } - return current; - } - } - /** - * The token on the left of the position is the token that strictly includes the position - * or sits to the left of the cursor if it is on a boundary. For example - * - * fo|o -> will return foo - * foo |bar -> will return foo - * - */ - function findTokenOnLeftOfPosition(file, position) { - // Ideally, getTokenAtPosition should return a token. However, it is currently - // broken, so we do a check to make sure the result was indeed a token. - var tokenAtPosition = getTokenAtPosition(file, position); - if (isToken(tokenAtPosition) && position > tokenAtPosition.getStart(file) && position < tokenAtPosition.getEnd()) { - return tokenAtPosition; - } - return findPrecedingToken(position, file); - } - ts.findTokenOnLeftOfPosition = findTokenOnLeftOfPosition; - function findNextToken(previousToken, parent) { - return find(parent); - function find(n) { - if (isToken(n) && n.pos === previousToken.end) { - // this is token that starts at the end of previous token - return it - return n; - } - var children = n.getChildren(); - for (var _i = 0; _i < children.length; _i++) { - var child = children[_i]; - var shouldDiveInChildNode = - // previous token is enclosed somewhere in the child - (child.pos <= previousToken.pos && child.end > previousToken.end) || - // previous token ends exactly at the beginning of child - (child.pos === previousToken.end); - if (shouldDiveInChildNode && nodeHasTokens(child)) { - return find(child); - } - } - return undefined; - } - } - ts.findNextToken = findNextToken; - function findPrecedingToken(position, sourceFile, startNode) { - return find(startNode || sourceFile); - function findRightmostToken(n) { - if (isToken(n)) { - return n; - } - var children = n.getChildren(); - var candidate = findRightmostChildNodeWithTokens(children, children.length); - return candidate && findRightmostToken(candidate); - } - function find(n) { - if (isToken(n)) { - return n; - } - var children = n.getChildren(); - for (var i = 0, len = children.length; i < len; i++) { - var child = children[i]; - if (nodeHasTokens(child)) { - if (position <= child.end) { - if (child.getStart(sourceFile) >= position) { - // actual start of the node is past the position - previous token should be at the end of previous child - var candidate = findRightmostChildNodeWithTokens(children, i); - return candidate && findRightmostToken(candidate); - } - else { - // candidate should be in this node - return find(child); - } - } - } - } - ts.Debug.assert(startNode !== undefined || n.kind === 230 /* SourceFile */); - // Here we know that none of child token nodes embrace the position, - // the only known case is when position is at the end of the file. - // Try to find the rightmost token in the file without filtering. - // Namely we are skipping the check: 'position < node.end' - if (children.length) { - var candidate = findRightmostChildNodeWithTokens(children, children.length); - return candidate && findRightmostToken(candidate); - } - } - /// finds last node that is considered as candidate for search (isCandidate(node) === true) starting from 'exclusiveStartPosition' - function findRightmostChildNodeWithTokens(children, exclusiveStartPosition) { - for (var i = exclusiveStartPosition - 1; i >= 0; --i) { - if (nodeHasTokens(children[i])) { - return children[i]; - } - } - } - } - ts.findPrecedingToken = findPrecedingToken; - function nodeHasTokens(n) { - // If we have a token or node that has a non-zero width, it must have tokens. - // Note, that getWidth() does not take trivia into account. - return n.getWidth() !== 0; - } - function getNodeModifiers(node) { - var flags = ts.getCombinedNodeFlags(node); - var result = []; - if (flags & 32 /* Private */) - result.push(ts.ScriptElementKindModifier.privateMemberModifier); - if (flags & 64 /* Protected */) - result.push(ts.ScriptElementKindModifier.protectedMemberModifier); - if (flags & 16 /* Public */) - result.push(ts.ScriptElementKindModifier.publicMemberModifier); - if (flags & 128 /* Static */) - result.push(ts.ScriptElementKindModifier.staticModifier); - if (flags & 1 /* Export */) - result.push(ts.ScriptElementKindModifier.exportedModifier); - if (ts.isInAmbientContext(node)) - result.push(ts.ScriptElementKindModifier.ambientModifier); - return result.length > 0 ? result.join(',') : ts.ScriptElementKindModifier.none; - } - ts.getNodeModifiers = getNodeModifiers; - function getTypeArgumentOrTypeParameterList(node) { - if (node.kind === 144 /* TypeReference */ || node.kind === 160 /* CallExpression */) { - return node.typeArguments; - } - if (ts.isFunctionLike(node) || node.kind === 204 /* ClassDeclaration */ || node.kind === 205 /* InterfaceDeclaration */) { - return node.typeParameters; - } - return undefined; - } - ts.getTypeArgumentOrTypeParameterList = getTypeArgumentOrTypeParameterList; - function isToken(n) { - return n.kind >= 0 /* FirstToken */ && n.kind <= 127 /* LastToken */; - } - ts.isToken = isToken; - function isWord(kind) { - return kind === 65 /* Identifier */ || ts.isKeyword(kind); - } - ts.isWord = isWord; - function isPropertyName(kind) { - return kind === 8 /* StringLiteral */ || kind === 7 /* NumericLiteral */ || isWord(kind); - } - function isComment(kind) { - return kind === 2 /* SingleLineCommentTrivia */ || kind === 3 /* MultiLineCommentTrivia */; - } - ts.isComment = isComment; - function isPunctuation(kind) { - return 14 /* FirstPunctuation */ <= kind && kind <= 64 /* LastPunctuation */; - } - ts.isPunctuation = isPunctuation; - function isInsideTemplateLiteral(node, position) { - return ts.isTemplateLiteralKind(node.kind) - && (node.getStart() < position && position < node.getEnd()) || (!!node.isUnterminated && position === node.getEnd()); - } - ts.isInsideTemplateLiteral = isInsideTemplateLiteral; - function isAccessibilityModifier(kind) { - switch (kind) { - case 108 /* PublicKeyword */: - case 106 /* PrivateKeyword */: - case 107 /* ProtectedKeyword */: - return true; - } - return false; - } - ts.isAccessibilityModifier = isAccessibilityModifier; - function compareDataObjects(dst, src) { - for (var e in dst) { - if (typeof dst[e] === "object") { - if (!compareDataObjects(dst[e], src[e])) { - return false; - } - } - else if (typeof dst[e] !== "function") { - if (dst[e] !== src[e]) { - return false; - } - } - } - return true; - } - ts.compareDataObjects = compareDataObjects; -})(ts || (ts = {})); -// Display-part writer helpers -/* @internal */ -var ts; -(function (ts) { - function isFirstDeclarationOfSymbolParameter(symbol) { - return symbol.declarations && symbol.declarations.length > 0 && symbol.declarations[0].kind === 131 /* Parameter */; - } - ts.isFirstDeclarationOfSymbolParameter = isFirstDeclarationOfSymbolParameter; - var displayPartWriter = getDisplayPartWriter(); - function getDisplayPartWriter() { - var displayParts; - var lineStart; - var indent; - resetWriter(); - return { - displayParts: function () { return displayParts; }, - writeKeyword: function (text) { return writeKind(text, ts.SymbolDisplayPartKind.keyword); }, - writeOperator: function (text) { return writeKind(text, ts.SymbolDisplayPartKind.operator); }, - writePunctuation: function (text) { return writeKind(text, ts.SymbolDisplayPartKind.punctuation); }, - writeSpace: function (text) { return writeKind(text, ts.SymbolDisplayPartKind.space); }, - writeStringLiteral: function (text) { return writeKind(text, ts.SymbolDisplayPartKind.stringLiteral); }, - writeParameter: function (text) { return writeKind(text, ts.SymbolDisplayPartKind.parameterName); }, - writeSymbol: writeSymbol, - writeLine: writeLine, - increaseIndent: function () { indent++; }, - decreaseIndent: function () { indent--; }, - clear: resetWriter, - trackSymbol: function () { } - }; - function writeIndent() { - if (lineStart) { - var indentString = ts.getIndentString(indent); - if (indentString) { - displayParts.push(displayPart(indentString, ts.SymbolDisplayPartKind.space)); - } - lineStart = false; - } - } - function writeKind(text, kind) { - writeIndent(); - displayParts.push(displayPart(text, kind)); - } - function writeSymbol(text, symbol) { - writeIndent(); - displayParts.push(symbolPart(text, symbol)); - } - function writeLine() { - displayParts.push(lineBreakPart()); - lineStart = true; - } - function resetWriter() { - displayParts = []; - lineStart = true; - indent = 0; - } - } - function symbolPart(text, symbol) { - return displayPart(text, displayPartKind(symbol), symbol); - function displayPartKind(symbol) { - var flags = symbol.flags; - if (flags & 3 /* Variable */) { - return isFirstDeclarationOfSymbolParameter(symbol) ? ts.SymbolDisplayPartKind.parameterName : ts.SymbolDisplayPartKind.localName; - } - else if (flags & 4 /* Property */) { - return ts.SymbolDisplayPartKind.propertyName; - } - else if (flags & 32768 /* GetAccessor */) { - return ts.SymbolDisplayPartKind.propertyName; - } - else if (flags & 65536 /* SetAccessor */) { - return ts.SymbolDisplayPartKind.propertyName; - } - else if (flags & 8 /* EnumMember */) { - return ts.SymbolDisplayPartKind.enumMemberName; - } - else if (flags & 16 /* Function */) { - return ts.SymbolDisplayPartKind.functionName; - } - else if (flags & 32 /* Class */) { - return ts.SymbolDisplayPartKind.className; - } - else if (flags & 64 /* Interface */) { - return ts.SymbolDisplayPartKind.interfaceName; - } - else if (flags & 384 /* Enum */) { - return ts.SymbolDisplayPartKind.enumName; - } - else if (flags & 1536 /* Module */) { - return ts.SymbolDisplayPartKind.moduleName; - } - else if (flags & 8192 /* Method */) { - return ts.SymbolDisplayPartKind.methodName; - } - else if (flags & 262144 /* TypeParameter */) { - return ts.SymbolDisplayPartKind.typeParameterName; - } - else if (flags & 524288 /* TypeAlias */) { - return ts.SymbolDisplayPartKind.aliasName; - } - else if (flags & 8388608 /* Alias */) { - return ts.SymbolDisplayPartKind.aliasName; - } - return ts.SymbolDisplayPartKind.text; - } - } - ts.symbolPart = symbolPart; - function displayPart(text, kind, symbol) { - return { - text: text, - kind: ts.SymbolDisplayPartKind[kind] - }; - } - ts.displayPart = displayPart; - function spacePart() { - return displayPart(" ", ts.SymbolDisplayPartKind.space); - } - ts.spacePart = spacePart; - function keywordPart(kind) { - return displayPart(ts.tokenToString(kind), ts.SymbolDisplayPartKind.keyword); - } - ts.keywordPart = keywordPart; - function punctuationPart(kind) { - return displayPart(ts.tokenToString(kind), ts.SymbolDisplayPartKind.punctuation); - } - ts.punctuationPart = punctuationPart; - function operatorPart(kind) { - return displayPart(ts.tokenToString(kind), ts.SymbolDisplayPartKind.operator); - } - ts.operatorPart = operatorPart; - function textOrKeywordPart(text) { - var kind = ts.stringToToken(text); - return kind === undefined - ? textPart(text) - : keywordPart(kind); - } - ts.textOrKeywordPart = textOrKeywordPart; - function textPart(text) { - return displayPart(text, ts.SymbolDisplayPartKind.text); - } - ts.textPart = textPart; - function lineBreakPart() { - return displayPart("\n", ts.SymbolDisplayPartKind.lineBreak); - } - ts.lineBreakPart = lineBreakPart; - function mapToDisplayParts(writeDisplayParts) { - writeDisplayParts(displayPartWriter); - var result = displayPartWriter.displayParts(); - displayPartWriter.clear(); - return result; - } - ts.mapToDisplayParts = mapToDisplayParts; - function typeToDisplayParts(typechecker, type, enclosingDeclaration, flags) { - return mapToDisplayParts(function (writer) { - typechecker.getSymbolDisplayBuilder().buildTypeDisplay(type, writer, enclosingDeclaration, flags); - }); - } - ts.typeToDisplayParts = typeToDisplayParts; - function symbolToDisplayParts(typeChecker, symbol, enclosingDeclaration, meaning, flags) { - return mapToDisplayParts(function (writer) { - typeChecker.getSymbolDisplayBuilder().buildSymbolDisplay(symbol, writer, enclosingDeclaration, meaning, flags); - }); - } - ts.symbolToDisplayParts = symbolToDisplayParts; - function signatureToDisplayParts(typechecker, signature, enclosingDeclaration, flags) { - return mapToDisplayParts(function (writer) { - typechecker.getSymbolDisplayBuilder().buildSignatureDisplay(signature, writer, enclosingDeclaration, flags); - }); - } - ts.signatureToDisplayParts = signatureToDisplayParts; -})(ts || (ts = {})); -/// -/// -/* @internal */ -var ts; -(function (ts) { - var formatting; - (function (formatting) { - var scanner = ts.createScanner(2 /* Latest */, false); - var ScanAction; - (function (ScanAction) { - ScanAction[ScanAction["Scan"] = 0] = "Scan"; - ScanAction[ScanAction["RescanGreaterThanToken"] = 1] = "RescanGreaterThanToken"; - ScanAction[ScanAction["RescanSlashToken"] = 2] = "RescanSlashToken"; - ScanAction[ScanAction["RescanTemplateToken"] = 3] = "RescanTemplateToken"; - })(ScanAction || (ScanAction = {})); - function getFormattingScanner(sourceFile, startPos, endPos) { - scanner.setText(sourceFile.text); - scanner.setTextPos(startPos); - var wasNewLine = true; - var leadingTrivia; - var trailingTrivia; - var savedPos; - var lastScanAction; - var lastTokenInfo; - return { - advance: advance, - readTokenInfo: readTokenInfo, - isOnToken: isOnToken, - lastTrailingTriviaWasNewLine: function () { return wasNewLine; }, - close: function () { - lastTokenInfo = undefined; - scanner.setText(undefined); - } - }; - function advance() { - lastTokenInfo = undefined; - var isStarted = scanner.getStartPos() !== startPos; - if (isStarted) { - if (trailingTrivia) { - ts.Debug.assert(trailingTrivia.length !== 0); - wasNewLine = ts.lastOrUndefined(trailingTrivia).kind === 4 /* NewLineTrivia */; - } - else { - wasNewLine = false; - } - } - leadingTrivia = undefined; - trailingTrivia = undefined; - if (!isStarted) { - scanner.scan(); - } - var t; - var pos = scanner.getStartPos(); - // Read leading trivia and token - while (pos < endPos) { - var t_2 = scanner.getToken(); - if (!ts.isTrivia(t_2)) { - break; - } - // consume leading trivia - scanner.scan(); - var item = { - pos: pos, - end: scanner.getStartPos(), - kind: t_2 - }; - pos = scanner.getStartPos(); - if (!leadingTrivia) { - leadingTrivia = []; - } - leadingTrivia.push(item); - } - savedPos = scanner.getStartPos(); - } - function shouldRescanGreaterThanToken(node) { - if (node) { - switch (node.kind) { - case 27 /* GreaterThanEqualsToken */: - case 60 /* GreaterThanGreaterThanEqualsToken */: - case 61 /* GreaterThanGreaterThanGreaterThanEqualsToken */: - case 42 /* GreaterThanGreaterThanGreaterThanToken */: - case 41 /* GreaterThanGreaterThanToken */: - return true; - } - } - return false; - } - function shouldRescanSlashToken(container) { - return container.kind === 9 /* RegularExpressionLiteral */; - } - function shouldRescanTemplateToken(container) { - return container.kind === 12 /* TemplateMiddle */ || - container.kind === 13 /* TemplateTail */; - } - function startsWithSlashToken(t) { - return t === 36 /* SlashToken */ || t === 57 /* SlashEqualsToken */; - } - function readTokenInfo(n) { - if (!isOnToken()) { - // scanner is not on the token (either advance was not called yet or scanner is already past the end position) - return { - leadingTrivia: leadingTrivia, - trailingTrivia: undefined, - token: undefined - }; - } - // normally scanner returns the smallest available token - // check the kind of context node to determine if scanner should have more greedy behavior and consume more text. - var expectedScanAction = shouldRescanGreaterThanToken(n) - ? 1 /* RescanGreaterThanToken */ - : shouldRescanSlashToken(n) - ? 2 /* RescanSlashToken */ - : shouldRescanTemplateToken(n) - ? 3 /* RescanTemplateToken */ - : 0 /* Scan */; - if (lastTokenInfo && expectedScanAction === lastScanAction) { - // readTokenInfo was called before with the same expected scan action. - // No need to re-scan text, return existing 'lastTokenInfo' - // it is ok to call fixTokenKind here since it does not affect - // what portion of text is consumed. In opposize rescanning can change it, - // i.e. for '>=' when originally scanner eats just one character - // and rescanning forces it to consume more. - return fixTokenKind(lastTokenInfo, n); - } - if (scanner.getStartPos() !== savedPos) { - ts.Debug.assert(lastTokenInfo !== undefined); - // readTokenInfo was called before but scan action differs - rescan text - scanner.setTextPos(savedPos); - scanner.scan(); - } - var currentToken = scanner.getToken(); - if (expectedScanAction === 1 /* RescanGreaterThanToken */ && currentToken === 25 /* GreaterThanToken */) { - currentToken = scanner.reScanGreaterToken(); - ts.Debug.assert(n.kind === currentToken); - lastScanAction = 1 /* RescanGreaterThanToken */; - } - else if (expectedScanAction === 2 /* RescanSlashToken */ && startsWithSlashToken(currentToken)) { - currentToken = scanner.reScanSlashToken(); - ts.Debug.assert(n.kind === currentToken); - lastScanAction = 2 /* RescanSlashToken */; - } - else if (expectedScanAction === 3 /* RescanTemplateToken */ && currentToken === 15 /* CloseBraceToken */) { - currentToken = scanner.reScanTemplateToken(); - lastScanAction = 3 /* RescanTemplateToken */; - } - else { - lastScanAction = 0 /* Scan */; - } - var token = { - pos: scanner.getStartPos(), - end: scanner.getTextPos(), - kind: currentToken - }; - // consume trailing trivia - if (trailingTrivia) { - trailingTrivia = undefined; - } - while (scanner.getStartPos() < endPos) { - currentToken = scanner.scan(); - if (!ts.isTrivia(currentToken)) { - break; - } - var trivia = { - pos: scanner.getStartPos(), - end: scanner.getTextPos(), - kind: currentToken - }; - if (!trailingTrivia) { - trailingTrivia = []; - } - trailingTrivia.push(trivia); - if (currentToken === 4 /* NewLineTrivia */) { - // move past new line - scanner.scan(); - break; - } - } - lastTokenInfo = { - leadingTrivia: leadingTrivia, - trailingTrivia: trailingTrivia, - token: token - }; - return fixTokenKind(lastTokenInfo, n); - } - function isOnToken() { - var current = (lastTokenInfo && lastTokenInfo.token.kind) || scanner.getToken(); - var startPos = (lastTokenInfo && lastTokenInfo.token.pos) || scanner.getStartPos(); - return startPos < endPos && current !== 1 /* EndOfFileToken */ && !ts.isTrivia(current); - } - // when containing node in the tree is token - // but its kind differs from the kind that was returned by the scanner, - // then kind needs to be fixed. This might happen in cases - // when parser interprets token differently, i.e keyword treated as identifier - function fixTokenKind(tokenInfo, container) { - if (ts.isToken(container) && tokenInfo.token.kind !== container.kind) { - tokenInfo.token.kind = container.kind; - } - return tokenInfo; - } - } - formatting.getFormattingScanner = getFormattingScanner; - })(formatting = ts.formatting || (ts.formatting = {})); -})(ts || (ts = {})); -/// -/* @internal */ -var ts; -(function (ts) { - var formatting; - (function (formatting) { - var FormattingContext = (function () { - function FormattingContext(sourceFile, formattingRequestKind) { - this.sourceFile = sourceFile; - this.formattingRequestKind = formattingRequestKind; - } - FormattingContext.prototype.updateContext = function (currentRange, currentTokenParent, nextRange, nextTokenParent, commonParent) { - ts.Debug.assert(currentRange !== undefined, "currentTokenSpan is null"); - ts.Debug.assert(currentTokenParent !== undefined, "currentTokenParent is null"); - ts.Debug.assert(nextRange !== undefined, "nextTokenSpan is null"); - ts.Debug.assert(nextTokenParent !== undefined, "nextTokenParent is null"); - ts.Debug.assert(commonParent !== undefined, "commonParent is null"); - this.currentTokenSpan = currentRange; - this.currentTokenParent = currentTokenParent; - this.nextTokenSpan = nextRange; - this.nextTokenParent = nextTokenParent; - this.contextNode = commonParent; - // drop cached results - this.contextNodeAllOnSameLine = undefined; - this.nextNodeAllOnSameLine = undefined; - this.tokensAreOnSameLine = undefined; - this.contextNodeBlockIsOnOneLine = undefined; - this.nextNodeBlockIsOnOneLine = undefined; - }; - FormattingContext.prototype.ContextNodeAllOnSameLine = function () { - if (this.contextNodeAllOnSameLine === undefined) { - this.contextNodeAllOnSameLine = this.NodeIsOnOneLine(this.contextNode); - } - return this.contextNodeAllOnSameLine; - }; - FormattingContext.prototype.NextNodeAllOnSameLine = function () { - if (this.nextNodeAllOnSameLine === undefined) { - this.nextNodeAllOnSameLine = this.NodeIsOnOneLine(this.nextTokenParent); - } - return this.nextNodeAllOnSameLine; - }; - FormattingContext.prototype.TokensAreOnSameLine = function () { - if (this.tokensAreOnSameLine === undefined) { - var startLine = this.sourceFile.getLineAndCharacterOfPosition(this.currentTokenSpan.pos).line; - var endLine = this.sourceFile.getLineAndCharacterOfPosition(this.nextTokenSpan.pos).line; - this.tokensAreOnSameLine = (startLine == endLine); - } - return this.tokensAreOnSameLine; - }; - FormattingContext.prototype.ContextNodeBlockIsOnOneLine = function () { - if (this.contextNodeBlockIsOnOneLine === undefined) { - this.contextNodeBlockIsOnOneLine = this.BlockIsOnOneLine(this.contextNode); - } - return this.contextNodeBlockIsOnOneLine; - }; - FormattingContext.prototype.NextNodeBlockIsOnOneLine = function () { - if (this.nextNodeBlockIsOnOneLine === undefined) { - this.nextNodeBlockIsOnOneLine = this.BlockIsOnOneLine(this.nextTokenParent); - } - return this.nextNodeBlockIsOnOneLine; - }; - FormattingContext.prototype.NodeIsOnOneLine = function (node) { - var startLine = this.sourceFile.getLineAndCharacterOfPosition(node.getStart(this.sourceFile)).line; - var endLine = this.sourceFile.getLineAndCharacterOfPosition(node.getEnd()).line; - return startLine == endLine; - }; - FormattingContext.prototype.BlockIsOnOneLine = function (node) { - var openBrace = ts.findChildOfKind(node, 14 /* OpenBraceToken */, this.sourceFile); - var closeBrace = ts.findChildOfKind(node, 15 /* CloseBraceToken */, this.sourceFile); - if (openBrace && closeBrace) { - var startLine = this.sourceFile.getLineAndCharacterOfPosition(openBrace.getEnd()).line; - var endLine = this.sourceFile.getLineAndCharacterOfPosition(closeBrace.getStart(this.sourceFile)).line; - return startLine === endLine; - } - return false; - }; - return FormattingContext; - })(); - formatting.FormattingContext = FormattingContext; - })(formatting = ts.formatting || (ts.formatting = {})); -})(ts || (ts = {})); -/// -/* @internal */ -var ts; -(function (ts) { - var formatting; - (function (formatting) { - (function (FormattingRequestKind) { - FormattingRequestKind[FormattingRequestKind["FormatDocument"] = 0] = "FormatDocument"; - FormattingRequestKind[FormattingRequestKind["FormatSelection"] = 1] = "FormatSelection"; - FormattingRequestKind[FormattingRequestKind["FormatOnEnter"] = 2] = "FormatOnEnter"; - FormattingRequestKind[FormattingRequestKind["FormatOnSemicolon"] = 3] = "FormatOnSemicolon"; - FormattingRequestKind[FormattingRequestKind["FormatOnClosingCurlyBrace"] = 4] = "FormatOnClosingCurlyBrace"; - })(formatting.FormattingRequestKind || (formatting.FormattingRequestKind = {})); - var FormattingRequestKind = formatting.FormattingRequestKind; - })(formatting = ts.formatting || (ts.formatting = {})); -})(ts || (ts = {})); -/// -/* @internal */ -var ts; -(function (ts) { - var formatting; - (function (formatting) { - var Rule = (function () { - function Rule(Descriptor, Operation, Flag) { - if (Flag === void 0) { Flag = 0 /* None */; } - this.Descriptor = Descriptor; - this.Operation = Operation; - this.Flag = Flag; - } - Rule.prototype.toString = function () { - return "[desc=" + this.Descriptor + "," + - "operation=" + this.Operation + "," + - "flag=" + this.Flag + "]"; - }; - return Rule; - })(); - formatting.Rule = Rule; - })(formatting = ts.formatting || (ts.formatting = {})); -})(ts || (ts = {})); -/// -/* @internal */ -var ts; -(function (ts) { - var formatting; - (function (formatting) { - (function (RuleAction) { - RuleAction[RuleAction["Ignore"] = 1] = "Ignore"; - RuleAction[RuleAction["Space"] = 2] = "Space"; - RuleAction[RuleAction["NewLine"] = 4] = "NewLine"; - RuleAction[RuleAction["Delete"] = 8] = "Delete"; - })(formatting.RuleAction || (formatting.RuleAction = {})); - var RuleAction = formatting.RuleAction; - })(formatting = ts.formatting || (ts.formatting = {})); -})(ts || (ts = {})); -/// -/* @internal */ -var ts; -(function (ts) { - var formatting; - (function (formatting) { - var RuleDescriptor = (function () { - function RuleDescriptor(LeftTokenRange, RightTokenRange) { - this.LeftTokenRange = LeftTokenRange; - this.RightTokenRange = RightTokenRange; - } - RuleDescriptor.prototype.toString = function () { - return "[leftRange=" + this.LeftTokenRange + "," + - "rightRange=" + this.RightTokenRange + "]"; - }; - RuleDescriptor.create1 = function (left, right) { - return RuleDescriptor.create4(formatting.Shared.TokenRange.FromToken(left), formatting.Shared.TokenRange.FromToken(right)); - }; - RuleDescriptor.create2 = function (left, right) { - return RuleDescriptor.create4(left, formatting.Shared.TokenRange.FromToken(right)); - }; - RuleDescriptor.create3 = function (left, right) { - return RuleDescriptor.create4(formatting.Shared.TokenRange.FromToken(left), right); - }; - RuleDescriptor.create4 = function (left, right) { - return new RuleDescriptor(left, right); - }; - return RuleDescriptor; - })(); - formatting.RuleDescriptor = RuleDescriptor; - })(formatting = ts.formatting || (ts.formatting = {})); -})(ts || (ts = {})); -/// -/* @internal */ -var ts; -(function (ts) { - var formatting; - (function (formatting) { - (function (RuleFlags) { - RuleFlags[RuleFlags["None"] = 0] = "None"; - RuleFlags[RuleFlags["CanDeleteNewLines"] = 1] = "CanDeleteNewLines"; - })(formatting.RuleFlags || (formatting.RuleFlags = {})); - var RuleFlags = formatting.RuleFlags; - })(formatting = ts.formatting || (ts.formatting = {})); -})(ts || (ts = {})); -/// -/* @internal */ -var ts; -(function (ts) { - var formatting; - (function (formatting) { - var RuleOperation = (function () { - function RuleOperation() { - this.Context = null; - this.Action = null; - } - RuleOperation.prototype.toString = function () { - return "[context=" + this.Context + "," + - "action=" + this.Action + "]"; - }; - RuleOperation.create1 = function (action) { - return RuleOperation.create2(formatting.RuleOperationContext.Any, action); - }; - RuleOperation.create2 = function (context, action) { - var result = new RuleOperation(); - result.Context = context; - result.Action = action; - return result; - }; - return RuleOperation; - })(); - formatting.RuleOperation = RuleOperation; - })(formatting = ts.formatting || (ts.formatting = {})); -})(ts || (ts = {})); -/// -/* @internal */ -var ts; -(function (ts) { - var formatting; - (function (formatting) { - var RuleOperationContext = (function () { - function RuleOperationContext() { - var funcs = []; - for (var _i = 0; _i < arguments.length; _i++) { - funcs[_i - 0] = arguments[_i]; - } - this.customContextChecks = funcs; - } - RuleOperationContext.prototype.IsAny = function () { - return this == RuleOperationContext.Any; - }; - RuleOperationContext.prototype.InContext = function (context) { - if (this.IsAny()) { - return true; - } - for (var _i = 0, _a = this.customContextChecks; _i < _a.length; _i++) { - var check = _a[_i]; - if (!check(context)) { - return false; - } - } - return true; - }; - RuleOperationContext.Any = new RuleOperationContext(); - return RuleOperationContext; - })(); - formatting.RuleOperationContext = RuleOperationContext; - })(formatting = ts.formatting || (ts.formatting = {})); -})(ts || (ts = {})); -/// -/* @internal */ -var ts; -(function (ts) { - var formatting; - (function (formatting) { - var Rules = (function () { - function Rules() { - /// - /// Common Rules - /// - // Leave comments alone - this.IgnoreBeforeComment = new formatting.Rule(formatting.RuleDescriptor.create4(formatting.Shared.TokenRange.Any, formatting.Shared.TokenRange.Comments), formatting.RuleOperation.create1(1 /* Ignore */)); - this.IgnoreAfterLineComment = new formatting.Rule(formatting.RuleDescriptor.create3(2 /* SingleLineCommentTrivia */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create1(1 /* Ignore */)); - // Space after keyword but not before ; or : or ? - this.NoSpaceBeforeSemicolon = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.Any, 22 /* SemicolonToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - this.NoSpaceBeforeColon = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.Any, 51 /* ColonToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsNotBinaryOpContext), 8 /* Delete */)); - this.NoSpaceBeforeQuestionMark = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.Any, 50 /* QuestionToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsNotBinaryOpContext), 8 /* Delete */)); - this.SpaceAfterColon = new formatting.Rule(formatting.RuleDescriptor.create3(51 /* ColonToken */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsNotBinaryOpContext), 2 /* Space */)); - this.SpaceAfterQuestionMarkInConditionalOperator = new formatting.Rule(formatting.RuleDescriptor.create3(50 /* QuestionToken */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsConditionalOperatorContext), 2 /* Space */)); - this.NoSpaceAfterQuestionMark = new formatting.Rule(formatting.RuleDescriptor.create3(50 /* QuestionToken */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - this.SpaceAfterSemicolon = new formatting.Rule(formatting.RuleDescriptor.create3(22 /* SemicolonToken */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 2 /* Space */)); - // Space after }. - this.SpaceAfterCloseBrace = new formatting.Rule(formatting.RuleDescriptor.create3(15 /* CloseBraceToken */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsAfterCodeBlockContext), 2 /* Space */)); - // Special case for (}, else) and (}, while) since else & while tokens are not part of the tree which makes SpaceAfterCloseBrace rule not applied - this.SpaceBetweenCloseBraceAndElse = new formatting.Rule(formatting.RuleDescriptor.create1(15 /* CloseBraceToken */, 76 /* ElseKeyword */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 2 /* Space */)); - this.SpaceBetweenCloseBraceAndWhile = new formatting.Rule(formatting.RuleDescriptor.create1(15 /* CloseBraceToken */, 100 /* WhileKeyword */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 2 /* Space */)); - this.NoSpaceAfterCloseBrace = new formatting.Rule(formatting.RuleDescriptor.create3(15 /* CloseBraceToken */, formatting.Shared.TokenRange.FromTokens([17 /* CloseParenToken */, 19 /* CloseBracketToken */, 23 /* CommaToken */, 22 /* SemicolonToken */])), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - // No space for indexer and dot - this.NoSpaceBeforeDot = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.Any, 20 /* DotToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - this.NoSpaceAfterDot = new formatting.Rule(formatting.RuleDescriptor.create3(20 /* DotToken */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - this.NoSpaceBeforeOpenBracket = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.Any, 18 /* OpenBracketToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - this.NoSpaceAfterOpenBracket = new formatting.Rule(formatting.RuleDescriptor.create3(18 /* OpenBracketToken */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - this.NoSpaceBeforeCloseBracket = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.Any, 19 /* CloseBracketToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - this.NoSpaceAfterCloseBracket = new formatting.Rule(formatting.RuleDescriptor.create3(19 /* CloseBracketToken */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsNotBeforeBlockInFunctionDeclarationContext), 8 /* Delete */)); - // Place a space before open brace in a function declaration - this.FunctionOpenBraceLeftTokenRange = formatting.Shared.TokenRange.AnyIncludingMultilineComments; - this.SpaceBeforeOpenBraceInFunction = new formatting.Rule(formatting.RuleDescriptor.create2(this.FunctionOpenBraceLeftTokenRange, 14 /* OpenBraceToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsFunctionDeclContext, Rules.IsBeforeBlockContext, Rules.IsNotFormatOnEnter, Rules.IsSameLineTokenOrBeforeMultilineBlockContext), 2 /* Space */), 1 /* CanDeleteNewLines */); - // Place a space before open brace in a TypeScript declaration that has braces as children (class, module, enum, etc) - this.TypeScriptOpenBraceLeftTokenRange = formatting.Shared.TokenRange.FromTokens([65 /* Identifier */, 3 /* MultiLineCommentTrivia */]); - this.SpaceBeforeOpenBraceInTypeScriptDeclWithBlock = new formatting.Rule(formatting.RuleDescriptor.create2(this.TypeScriptOpenBraceLeftTokenRange, 14 /* OpenBraceToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsTypeScriptDeclWithBlockContext, Rules.IsNotFormatOnEnter, Rules.IsSameLineTokenOrBeforeMultilineBlockContext), 2 /* Space */), 1 /* CanDeleteNewLines */); - // Place a space before open brace in a control flow construct - this.ControlOpenBraceLeftTokenRange = formatting.Shared.TokenRange.FromTokens([17 /* CloseParenToken */, 3 /* MultiLineCommentTrivia */, 75 /* DoKeyword */, 96 /* TryKeyword */, 81 /* FinallyKeyword */, 76 /* ElseKeyword */]); - this.SpaceBeforeOpenBraceInControl = new formatting.Rule(formatting.RuleDescriptor.create2(this.ControlOpenBraceLeftTokenRange, 14 /* OpenBraceToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsControlDeclContext, Rules.IsNotFormatOnEnter, Rules.IsSameLineTokenOrBeforeMultilineBlockContext), 2 /* Space */), 1 /* CanDeleteNewLines */); - // Insert a space after { and before } in single-line contexts, but remove space from empty object literals {}. - this.SpaceAfterOpenBrace = new formatting.Rule(formatting.RuleDescriptor.create3(14 /* OpenBraceToken */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSingleLineBlockContext), 2 /* Space */)); - this.SpaceBeforeCloseBrace = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.Any, 15 /* CloseBraceToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSingleLineBlockContext), 2 /* Space */)); - this.NoSpaceBetweenEmptyBraceBrackets = new formatting.Rule(formatting.RuleDescriptor.create1(14 /* OpenBraceToken */, 15 /* CloseBraceToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsObjectContext), 8 /* Delete */)); - // Insert new line after { and before } in multi-line contexts. - this.NewLineAfterOpenBraceInBlockContext = new formatting.Rule(formatting.RuleDescriptor.create3(14 /* OpenBraceToken */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsMultilineBlockContext), 4 /* NewLine */)); - // For functions and control block place } on a new line [multi-line rule] - this.NewLineBeforeCloseBraceInBlockContext = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.AnyIncludingMultilineComments, 15 /* CloseBraceToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsMultilineBlockContext), 4 /* NewLine */)); - // Special handling of unary operators. - // Prefix operators generally shouldn't have a space between - // them and their target unary expression. - this.NoSpaceAfterUnaryPrefixOperator = new formatting.Rule(formatting.RuleDescriptor.create4(formatting.Shared.TokenRange.UnaryPrefixOperators, formatting.Shared.TokenRange.UnaryPrefixExpressions), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsNotBinaryOpContext), 8 /* Delete */)); - this.NoSpaceAfterUnaryPreincrementOperator = new formatting.Rule(formatting.RuleDescriptor.create3(38 /* PlusPlusToken */, formatting.Shared.TokenRange.UnaryPreincrementExpressions), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - this.NoSpaceAfterUnaryPredecrementOperator = new formatting.Rule(formatting.RuleDescriptor.create3(39 /* MinusMinusToken */, formatting.Shared.TokenRange.UnaryPredecrementExpressions), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - this.NoSpaceBeforeUnaryPostincrementOperator = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.UnaryPostincrementExpressions, 38 /* PlusPlusToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - this.NoSpaceBeforeUnaryPostdecrementOperator = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.UnaryPostdecrementExpressions, 39 /* MinusMinusToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - // More unary operator special-casing. - // DevDiv 181814: Be careful when removing leading whitespace - // around unary operators. Examples: - // 1 - -2 --X--> 1--2 - // a + ++b --X--> a+++b - this.SpaceAfterPostincrementWhenFollowedByAdd = new formatting.Rule(formatting.RuleDescriptor.create1(38 /* PlusPlusToken */, 33 /* PlusToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsBinaryOpContext), 2 /* Space */)); - this.SpaceAfterAddWhenFollowedByUnaryPlus = new formatting.Rule(formatting.RuleDescriptor.create1(33 /* PlusToken */, 33 /* PlusToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsBinaryOpContext), 2 /* Space */)); - this.SpaceAfterAddWhenFollowedByPreincrement = new formatting.Rule(formatting.RuleDescriptor.create1(33 /* PlusToken */, 38 /* PlusPlusToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsBinaryOpContext), 2 /* Space */)); - this.SpaceAfterPostdecrementWhenFollowedBySubtract = new formatting.Rule(formatting.RuleDescriptor.create1(39 /* MinusMinusToken */, 34 /* MinusToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsBinaryOpContext), 2 /* Space */)); - this.SpaceAfterSubtractWhenFollowedByUnaryMinus = new formatting.Rule(formatting.RuleDescriptor.create1(34 /* MinusToken */, 34 /* MinusToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsBinaryOpContext), 2 /* Space */)); - this.SpaceAfterSubtractWhenFollowedByPredecrement = new formatting.Rule(formatting.RuleDescriptor.create1(34 /* MinusToken */, 39 /* MinusMinusToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsBinaryOpContext), 2 /* Space */)); - this.NoSpaceBeforeComma = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.Any, 23 /* CommaToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - this.SpaceAfterCertainKeywords = new formatting.Rule(formatting.RuleDescriptor.create4(formatting.Shared.TokenRange.FromTokens([98 /* VarKeyword */, 94 /* ThrowKeyword */, 88 /* NewKeyword */, 74 /* DeleteKeyword */, 90 /* ReturnKeyword */, 97 /* TypeOfKeyword */]), formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 2 /* Space */)); - this.SpaceAfterLetConstInVariableDeclaration = new formatting.Rule(formatting.RuleDescriptor.create4(formatting.Shared.TokenRange.FromTokens([104 /* LetKeyword */, 70 /* ConstKeyword */]), formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsStartOfVariableDeclarationList), 2 /* Space */)); - this.NoSpaceBeforeOpenParenInFuncCall = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.Any, 16 /* OpenParenToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsFunctionCallOrNewContext, Rules.IsPreviousTokenNotComma), 8 /* Delete */)); - this.SpaceAfterFunctionInFuncDecl = new formatting.Rule(formatting.RuleDescriptor.create3(83 /* FunctionKeyword */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsFunctionDeclContext), 2 /* Space */)); - this.NoSpaceBeforeOpenParenInFuncDecl = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.Any, 16 /* OpenParenToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsFunctionDeclContext), 8 /* Delete */)); - this.SpaceAfterVoidOperator = new formatting.Rule(formatting.RuleDescriptor.create3(99 /* VoidKeyword */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsVoidOpContext), 2 /* Space */)); - this.NoSpaceBetweenReturnAndSemicolon = new formatting.Rule(formatting.RuleDescriptor.create1(90 /* ReturnKeyword */, 22 /* SemicolonToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - // Add a space between statements. All keywords except (do,else,case) has open/close parens after them. - // So, we have a rule to add a space for [),Any], [do,Any], [else,Any], and [case,Any] - this.SpaceBetweenStatements = new formatting.Rule(formatting.RuleDescriptor.create4(formatting.Shared.TokenRange.FromTokens([17 /* CloseParenToken */, 75 /* DoKeyword */, 76 /* ElseKeyword */, 67 /* CaseKeyword */]), formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsNotForContext), 2 /* Space */)); - // This low-pri rule takes care of "try {" and "finally {" in case the rule SpaceBeforeOpenBraceInControl didn't execute on FormatOnEnter. - this.SpaceAfterTryFinally = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.FromTokens([96 /* TryKeyword */, 81 /* FinallyKeyword */]), 14 /* OpenBraceToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 2 /* Space */)); - // get x() {} - // set x(val) {} - this.SpaceAfterGetSetInMember = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.FromTokens([116 /* GetKeyword */, 122 /* SetKeyword */]), 65 /* Identifier */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsFunctionDeclContext), 2 /* Space */)); - // Special case for binary operators (that are keywords). For these we have to add a space and shouldn't follow any user options. - this.SpaceBeforeBinaryKeywordOperator = new formatting.Rule(formatting.RuleDescriptor.create4(formatting.Shared.TokenRange.Any, formatting.Shared.TokenRange.BinaryKeywordOperators), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsBinaryOpContext), 2 /* Space */)); - this.SpaceAfterBinaryKeywordOperator = new formatting.Rule(formatting.RuleDescriptor.create4(formatting.Shared.TokenRange.BinaryKeywordOperators, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsBinaryOpContext), 2 /* Space */)); - // TypeScript-specific higher priority rules - // Treat constructor as an identifier in a function declaration, and remove spaces between constructor and following left parentheses - this.NoSpaceAfterConstructor = new formatting.Rule(formatting.RuleDescriptor.create1(114 /* ConstructorKeyword */, 16 /* OpenParenToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - // Use of module as a function call. e.g.: import m2 = module("m2"); - this.NoSpaceAfterModuleImport = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.FromTokens([118 /* ModuleKeyword */, 120 /* RequireKeyword */]), 16 /* OpenParenToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - // Add a space around certain TypeScript keywords - this.SpaceAfterCertainTypeScriptKeywords = new formatting.Rule(formatting.RuleDescriptor.create4(formatting.Shared.TokenRange.FromTokens([69 /* ClassKeyword */, 115 /* DeclareKeyword */, 77 /* EnumKeyword */, 78 /* ExportKeyword */, 79 /* ExtendsKeyword */, 116 /* GetKeyword */, 102 /* ImplementsKeyword */, 85 /* ImportKeyword */, 103 /* InterfaceKeyword */, 118 /* ModuleKeyword */, 119 /* NamespaceKeyword */, 106 /* PrivateKeyword */, 108 /* PublicKeyword */, 122 /* SetKeyword */, 109 /* StaticKeyword */]), formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 2 /* Space */)); - this.SpaceBeforeCertainTypeScriptKeywords = new formatting.Rule(formatting.RuleDescriptor.create4(formatting.Shared.TokenRange.Any, formatting.Shared.TokenRange.FromTokens([79 /* ExtendsKeyword */, 102 /* ImplementsKeyword */])), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 2 /* Space */)); - // Treat string literals in module names as identifiers, and add a space between the literal and the opening Brace braces, e.g.: module "m2" { - this.SpaceAfterModuleName = new formatting.Rule(formatting.RuleDescriptor.create1(8 /* StringLiteral */, 14 /* OpenBraceToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsModuleDeclContext), 2 /* Space */)); - // Lambda expressions - this.SpaceAfterArrow = new formatting.Rule(formatting.RuleDescriptor.create3(32 /* EqualsGreaterThanToken */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 2 /* Space */)); - // Optional parameters and let args - this.NoSpaceAfterEllipsis = new formatting.Rule(formatting.RuleDescriptor.create1(21 /* DotDotDotToken */, 65 /* Identifier */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - this.NoSpaceAfterOptionalParameters = new formatting.Rule(formatting.RuleDescriptor.create3(50 /* QuestionToken */, formatting.Shared.TokenRange.FromTokens([17 /* CloseParenToken */, 23 /* CommaToken */])), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsNotBinaryOpContext), 8 /* Delete */)); - // generics - this.NoSpaceBeforeOpenAngularBracket = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.TypeNames, 24 /* LessThanToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsTypeArgumentOrParameterContext), 8 /* Delete */)); - this.NoSpaceBetweenCloseParenAndAngularBracket = new formatting.Rule(formatting.RuleDescriptor.create1(17 /* CloseParenToken */, 24 /* LessThanToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsTypeArgumentOrParameterContext), 8 /* Delete */)); - this.NoSpaceAfterOpenAngularBracket = new formatting.Rule(formatting.RuleDescriptor.create3(24 /* LessThanToken */, formatting.Shared.TokenRange.TypeNames), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsTypeArgumentOrParameterContext), 8 /* Delete */)); - this.NoSpaceBeforeCloseAngularBracket = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.Any, 25 /* GreaterThanToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsTypeArgumentOrParameterContext), 8 /* Delete */)); - this.NoSpaceAfterCloseAngularBracket = new formatting.Rule(formatting.RuleDescriptor.create3(25 /* GreaterThanToken */, formatting.Shared.TokenRange.FromTokens([16 /* OpenParenToken */, 18 /* OpenBracketToken */, 25 /* GreaterThanToken */, 23 /* CommaToken */])), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsTypeArgumentOrParameterContext), 8 /* Delete */)); - // Remove spaces in empty interface literals. e.g.: x: {} - this.NoSpaceBetweenEmptyInterfaceBraceBrackets = new formatting.Rule(formatting.RuleDescriptor.create1(14 /* OpenBraceToken */, 15 /* CloseBraceToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsObjectTypeContext), 8 /* Delete */)); - // decorators - this.SpaceBeforeAt = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.Any, 52 /* AtToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 2 /* Space */)); - this.NoSpaceAfterAt = new formatting.Rule(formatting.RuleDescriptor.create3(52 /* AtToken */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - this.SpaceAfterDecorator = new formatting.Rule(formatting.RuleDescriptor.create4(formatting.Shared.TokenRange.Any, formatting.Shared.TokenRange.FromTokens([65 /* Identifier */, 78 /* ExportKeyword */, 73 /* DefaultKeyword */, 69 /* ClassKeyword */, 109 /* StaticKeyword */, 108 /* PublicKeyword */, 106 /* PrivateKeyword */, 107 /* ProtectedKeyword */, 116 /* GetKeyword */, 122 /* SetKeyword */, 18 /* OpenBracketToken */, 35 /* AsteriskToken */])), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsEndOfDecoratorContextOnSameLine), 2 /* Space */)); - this.NoSpaceBetweenFunctionKeywordAndStar = new formatting.Rule(formatting.RuleDescriptor.create1(83 /* FunctionKeyword */, 35 /* AsteriskToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsFunctionDeclarationOrFunctionExpressionContext), 8 /* Delete */)); - this.SpaceAfterStarInGeneratorDeclaration = new formatting.Rule(formatting.RuleDescriptor.create3(35 /* AsteriskToken */, formatting.Shared.TokenRange.FromTokens([65 /* Identifier */, 16 /* OpenParenToken */])), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsFunctionDeclarationOrFunctionExpressionContext), 2 /* Space */)); - this.NoSpaceBetweenYieldKeywordAndStar = new formatting.Rule(formatting.RuleDescriptor.create1(110 /* YieldKeyword */, 35 /* AsteriskToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsYieldOrYieldStarWithOperand), 8 /* Delete */)); - this.SpaceBetweenYieldOrYieldStarAndOperand = new formatting.Rule(formatting.RuleDescriptor.create4(formatting.Shared.TokenRange.FromTokens([110 /* YieldKeyword */, 35 /* AsteriskToken */]), formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsYieldOrYieldStarWithOperand), 2 /* Space */)); - // These rules are higher in priority than user-configurable rules. - this.HighPriorityCommonRules = - [ - this.IgnoreBeforeComment, this.IgnoreAfterLineComment, - this.NoSpaceBeforeColon, this.SpaceAfterColon, this.NoSpaceBeforeQuestionMark, this.SpaceAfterQuestionMarkInConditionalOperator, - this.NoSpaceAfterQuestionMark, - this.NoSpaceBeforeDot, this.NoSpaceAfterDot, - this.NoSpaceAfterUnaryPrefixOperator, - this.NoSpaceAfterUnaryPreincrementOperator, this.NoSpaceAfterUnaryPredecrementOperator, - this.NoSpaceBeforeUnaryPostincrementOperator, this.NoSpaceBeforeUnaryPostdecrementOperator, - this.SpaceAfterPostincrementWhenFollowedByAdd, - this.SpaceAfterAddWhenFollowedByUnaryPlus, this.SpaceAfterAddWhenFollowedByPreincrement, - this.SpaceAfterPostdecrementWhenFollowedBySubtract, - this.SpaceAfterSubtractWhenFollowedByUnaryMinus, this.SpaceAfterSubtractWhenFollowedByPredecrement, - this.NoSpaceAfterCloseBrace, - this.SpaceAfterOpenBrace, this.SpaceBeforeCloseBrace, this.NewLineBeforeCloseBraceInBlockContext, - this.SpaceAfterCloseBrace, this.SpaceBetweenCloseBraceAndElse, this.SpaceBetweenCloseBraceAndWhile, this.NoSpaceBetweenEmptyBraceBrackets, - this.NoSpaceBetweenFunctionKeywordAndStar, this.SpaceAfterStarInGeneratorDeclaration, - this.SpaceAfterFunctionInFuncDecl, this.NewLineAfterOpenBraceInBlockContext, this.SpaceAfterGetSetInMember, - this.NoSpaceBetweenYieldKeywordAndStar, this.SpaceBetweenYieldOrYieldStarAndOperand, - this.NoSpaceBetweenReturnAndSemicolon, - this.SpaceAfterCertainKeywords, - this.SpaceAfterLetConstInVariableDeclaration, - this.NoSpaceBeforeOpenParenInFuncCall, - this.SpaceBeforeBinaryKeywordOperator, this.SpaceAfterBinaryKeywordOperator, - this.SpaceAfterVoidOperator, - // TypeScript-specific rules - this.NoSpaceAfterConstructor, this.NoSpaceAfterModuleImport, - this.SpaceAfterCertainTypeScriptKeywords, this.SpaceBeforeCertainTypeScriptKeywords, - this.SpaceAfterModuleName, - this.SpaceAfterArrow, - this.NoSpaceAfterEllipsis, - this.NoSpaceAfterOptionalParameters, - this.NoSpaceBetweenEmptyInterfaceBraceBrackets, - this.NoSpaceBeforeOpenAngularBracket, - this.NoSpaceBetweenCloseParenAndAngularBracket, - this.NoSpaceAfterOpenAngularBracket, - this.NoSpaceBeforeCloseAngularBracket, - this.NoSpaceAfterCloseAngularBracket, - this.SpaceBeforeAt, - this.NoSpaceAfterAt, - this.SpaceAfterDecorator, - ]; - // These rules are lower in priority than user-configurable rules. - this.LowPriorityCommonRules = - [ - this.NoSpaceBeforeSemicolon, - this.SpaceBeforeOpenBraceInControl, this.SpaceBeforeOpenBraceInFunction, this.SpaceBeforeOpenBraceInTypeScriptDeclWithBlock, - this.NoSpaceBeforeComma, - this.NoSpaceBeforeOpenBracket, this.NoSpaceAfterOpenBracket, - this.NoSpaceBeforeCloseBracket, this.NoSpaceAfterCloseBracket, - this.SpaceAfterSemicolon, - this.NoSpaceBeforeOpenParenInFuncDecl, - this.SpaceBetweenStatements, this.SpaceAfterTryFinally - ]; - /// - /// Rules controlled by user options - /// - // Insert space after comma delimiter - this.SpaceAfterComma = new formatting.Rule(formatting.RuleDescriptor.create3(23 /* CommaToken */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 2 /* Space */)); - this.NoSpaceAfterComma = new formatting.Rule(formatting.RuleDescriptor.create3(23 /* CommaToken */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - // Insert space before and after binary operators - this.SpaceBeforeBinaryOperator = new formatting.Rule(formatting.RuleDescriptor.create4(formatting.Shared.TokenRange.Any, formatting.Shared.TokenRange.BinaryOperators), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsBinaryOpContext), 2 /* Space */)); - this.SpaceAfterBinaryOperator = new formatting.Rule(formatting.RuleDescriptor.create4(formatting.Shared.TokenRange.BinaryOperators, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsBinaryOpContext), 2 /* Space */)); - this.NoSpaceBeforeBinaryOperator = new formatting.Rule(formatting.RuleDescriptor.create4(formatting.Shared.TokenRange.Any, formatting.Shared.TokenRange.BinaryOperators), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsBinaryOpContext), 8 /* Delete */)); - this.NoSpaceAfterBinaryOperator = new formatting.Rule(formatting.RuleDescriptor.create4(formatting.Shared.TokenRange.BinaryOperators, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsBinaryOpContext), 8 /* Delete */)); - // Insert space after keywords in control flow statements - this.SpaceAfterKeywordInControl = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.Keywords, 16 /* OpenParenToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsControlDeclContext), 2 /* Space */)); - this.NoSpaceAfterKeywordInControl = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.Keywords, 16 /* OpenParenToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsControlDeclContext), 8 /* Delete */)); - // Open Brace braces after function - //TypeScript: Function can have return types, which can be made of tons of different token kinds - this.NewLineBeforeOpenBraceInFunction = new formatting.Rule(formatting.RuleDescriptor.create2(this.FunctionOpenBraceLeftTokenRange, 14 /* OpenBraceToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsFunctionDeclContext, Rules.IsBeforeMultilineBlockContext), 4 /* NewLine */), 1 /* CanDeleteNewLines */); - // Open Brace braces after TypeScript module/class/interface - this.NewLineBeforeOpenBraceInTypeScriptDeclWithBlock = new formatting.Rule(formatting.RuleDescriptor.create2(this.TypeScriptOpenBraceLeftTokenRange, 14 /* OpenBraceToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsTypeScriptDeclWithBlockContext, Rules.IsBeforeMultilineBlockContext), 4 /* NewLine */), 1 /* CanDeleteNewLines */); - // Open Brace braces after control block - this.NewLineBeforeOpenBraceInControl = new formatting.Rule(formatting.RuleDescriptor.create2(this.ControlOpenBraceLeftTokenRange, 14 /* OpenBraceToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsControlDeclContext, Rules.IsBeforeMultilineBlockContext), 4 /* NewLine */), 1 /* CanDeleteNewLines */); - // Insert space after semicolon in for statement - this.SpaceAfterSemicolonInFor = new formatting.Rule(formatting.RuleDescriptor.create3(22 /* SemicolonToken */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsForContext), 2 /* Space */)); - this.NoSpaceAfterSemicolonInFor = new formatting.Rule(formatting.RuleDescriptor.create3(22 /* SemicolonToken */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext, Rules.IsForContext), 8 /* Delete */)); - // Insert space after opening and before closing nonempty parenthesis - this.SpaceAfterOpenParen = new formatting.Rule(formatting.RuleDescriptor.create3(16 /* OpenParenToken */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 2 /* Space */)); - this.SpaceBeforeCloseParen = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.Any, 17 /* CloseParenToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 2 /* Space */)); - this.NoSpaceBetweenParens = new formatting.Rule(formatting.RuleDescriptor.create1(16 /* OpenParenToken */, 17 /* CloseParenToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - this.NoSpaceAfterOpenParen = new formatting.Rule(formatting.RuleDescriptor.create3(16 /* OpenParenToken */, formatting.Shared.TokenRange.Any), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - this.NoSpaceBeforeCloseParen = new formatting.Rule(formatting.RuleDescriptor.create2(formatting.Shared.TokenRange.Any, 17 /* CloseParenToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsSameLineTokenContext), 8 /* Delete */)); - // Insert space after function keyword for anonymous functions - this.SpaceAfterAnonymousFunctionKeyword = new formatting.Rule(formatting.RuleDescriptor.create1(83 /* FunctionKeyword */, 16 /* OpenParenToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsFunctionDeclContext), 2 /* Space */)); - this.NoSpaceAfterAnonymousFunctionKeyword = new formatting.Rule(formatting.RuleDescriptor.create1(83 /* FunctionKeyword */, 16 /* OpenParenToken */), formatting.RuleOperation.create2(new formatting.RuleOperationContext(Rules.IsFunctionDeclContext), 8 /* Delete */)); - } - Rules.prototype.getRuleName = function (rule) { - var o = this; - for (var name_29 in o) { - if (o[name_29] === rule) { - return name_29; - } - } - throw new Error("Unknown rule"); - }; - /// - /// Contexts - /// - Rules.IsForContext = function (context) { - return context.contextNode.kind === 189 /* ForStatement */; - }; - Rules.IsNotForContext = function (context) { - return !Rules.IsForContext(context); - }; - Rules.IsBinaryOpContext = function (context) { - switch (context.contextNode.kind) { - case 172 /* BinaryExpression */: - case 173 /* ConditionalExpression */: - case 143 /* TypePredicate */: - return true; - // equals in binding elements: function foo([[x, y] = [1, 2]]) - case 155 /* BindingElement */: - // equals in type X = ... - case 206 /* TypeAliasDeclaration */: - // equal in import a = module('a'); - case 211 /* ImportEqualsDeclaration */: - // equal in let a = 0; - case 201 /* VariableDeclaration */: - // equal in p = 0; - case 131 /* Parameter */: - case 229 /* EnumMember */: - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - return context.currentTokenSpan.kind === 53 /* EqualsToken */ || context.nextTokenSpan.kind === 53 /* EqualsToken */; - // "in" keyword in for (let x in []) { } - case 190 /* ForInStatement */: - return context.currentTokenSpan.kind === 86 /* InKeyword */ || context.nextTokenSpan.kind === 86 /* InKeyword */; - // Technically, "of" is not a binary operator, but format it the same way as "in" - case 191 /* ForOfStatement */: - return context.currentTokenSpan.kind === 127 /* OfKeyword */ || context.nextTokenSpan.kind === 127 /* OfKeyword */; - } - return false; - }; - Rules.IsNotBinaryOpContext = function (context) { - return !Rules.IsBinaryOpContext(context); - }; - Rules.IsConditionalOperatorContext = function (context) { - return context.contextNode.kind === 173 /* ConditionalExpression */; - }; - Rules.IsSameLineTokenOrBeforeMultilineBlockContext = function (context) { - //// This check is mainly used inside SpaceBeforeOpenBraceInControl and SpaceBeforeOpenBraceInFunction. - //// - //// Ex: - //// if (1) { .... - //// * ) and { are on the same line so apply the rule. Here we don't care whether it's same or multi block context - //// - //// Ex: - //// if (1) - //// { ... } - //// * ) and { are on differnet lines. We only need to format if the block is multiline context. So in this case we don't format. - //// - //// Ex: - //// if (1) - //// { ... - //// } - //// * ) and { are on differnet lines. We only need to format if the block is multiline context. So in this case we format. - return context.TokensAreOnSameLine() || Rules.IsBeforeMultilineBlockContext(context); - }; - // This check is done before an open brace in a control construct, a function, or a typescript block declaration - Rules.IsBeforeMultilineBlockContext = function (context) { - return Rules.IsBeforeBlockContext(context) && !(context.NextNodeAllOnSameLine() || context.NextNodeBlockIsOnOneLine()); - }; - Rules.IsMultilineBlockContext = function (context) { - return Rules.IsBlockContext(context) && !(context.ContextNodeAllOnSameLine() || context.ContextNodeBlockIsOnOneLine()); - }; - Rules.IsSingleLineBlockContext = function (context) { - return Rules.IsBlockContext(context) && (context.ContextNodeAllOnSameLine() || context.ContextNodeBlockIsOnOneLine()); - }; - Rules.IsBlockContext = function (context) { - return Rules.NodeIsBlockContext(context.contextNode); - }; - Rules.IsBeforeBlockContext = function (context) { - return Rules.NodeIsBlockContext(context.nextTokenParent); - }; - // IMPORTANT!!! This method must return true ONLY for nodes with open and close braces as immediate children - Rules.NodeIsBlockContext = function (node) { - if (Rules.NodeIsTypeScriptDeclWithBlockContext(node)) { - // This means we are in a context that looks like a block to the user, but in the grammar is actually not a node (it's a class, module, enum, object type literal, etc). - return true; - } - switch (node.kind) { - case 182 /* Block */: - case 210 /* CaseBlock */: - case 157 /* ObjectLiteralExpression */: - case 209 /* ModuleBlock */: - return true; - } - return false; - }; - Rules.IsFunctionDeclContext = function (context) { - switch (context.contextNode.kind) { - case 203 /* FunctionDeclaration */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - //case SyntaxKind.MemberFunctionDeclaration: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - ///case SyntaxKind.MethodSignature: - case 140 /* CallSignature */: - case 165 /* FunctionExpression */: - case 137 /* Constructor */: - case 166 /* ArrowFunction */: - //case SyntaxKind.ConstructorDeclaration: - //case SyntaxKind.SimpleArrowFunctionExpression: - //case SyntaxKind.ParenthesizedArrowFunctionExpression: - case 205 /* InterfaceDeclaration */: - return true; - } - return false; - }; - Rules.IsFunctionDeclarationOrFunctionExpressionContext = function (context) { - return context.contextNode.kind === 203 /* FunctionDeclaration */ || context.contextNode.kind === 165 /* FunctionExpression */; - }; - Rules.IsTypeScriptDeclWithBlockContext = function (context) { - return Rules.NodeIsTypeScriptDeclWithBlockContext(context.contextNode); - }; - Rules.NodeIsTypeScriptDeclWithBlockContext = function (node) { - switch (node.kind) { - case 204 /* ClassDeclaration */: - case 205 /* InterfaceDeclaration */: - case 207 /* EnumDeclaration */: - case 148 /* TypeLiteral */: - case 208 /* ModuleDeclaration */: - return true; - } - return false; - }; - Rules.IsAfterCodeBlockContext = function (context) { - switch (context.currentTokenParent.kind) { - case 204 /* ClassDeclaration */: - case 208 /* ModuleDeclaration */: - case 207 /* EnumDeclaration */: - case 182 /* Block */: - case 226 /* CatchClause */: - case 209 /* ModuleBlock */: - case 196 /* SwitchStatement */: - return true; - } - return false; - }; - Rules.IsControlDeclContext = function (context) { - switch (context.contextNode.kind) { - case 186 /* IfStatement */: - case 196 /* SwitchStatement */: - case 189 /* ForStatement */: - case 190 /* ForInStatement */: - case 191 /* ForOfStatement */: - case 188 /* WhileStatement */: - case 199 /* TryStatement */: - case 187 /* DoStatement */: - case 195 /* WithStatement */: - // TODO - // case SyntaxKind.ElseClause: - case 226 /* CatchClause */: - return true; - default: - return false; - } - }; - Rules.IsObjectContext = function (context) { - return context.contextNode.kind === 157 /* ObjectLiteralExpression */; - }; - Rules.IsFunctionCallContext = function (context) { - return context.contextNode.kind === 160 /* CallExpression */; - }; - Rules.IsNewContext = function (context) { - return context.contextNode.kind === 161 /* NewExpression */; - }; - Rules.IsFunctionCallOrNewContext = function (context) { - return Rules.IsFunctionCallContext(context) || Rules.IsNewContext(context); - }; - Rules.IsPreviousTokenNotComma = function (context) { - return context.currentTokenSpan.kind !== 23 /* CommaToken */; - }; - Rules.IsSameLineTokenContext = function (context) { - return context.TokensAreOnSameLine(); - }; - Rules.IsNotBeforeBlockInFunctionDeclarationContext = function (context) { - return !Rules.IsFunctionDeclContext(context) && !Rules.IsBeforeBlockContext(context); - }; - Rules.IsEndOfDecoratorContextOnSameLine = function (context) { - return context.TokensAreOnSameLine() && - context.contextNode.decorators && - Rules.NodeIsInDecoratorContext(context.currentTokenParent) && - !Rules.NodeIsInDecoratorContext(context.nextTokenParent); - }; - Rules.NodeIsInDecoratorContext = function (node) { - while (ts.isExpression(node)) { - node = node.parent; - } - return node.kind === 132 /* Decorator */; - }; - Rules.IsStartOfVariableDeclarationList = function (context) { - return context.currentTokenParent.kind === 202 /* VariableDeclarationList */ && - context.currentTokenParent.getStart(context.sourceFile) === context.currentTokenSpan.pos; - }; - Rules.IsNotFormatOnEnter = function (context) { - return context.formattingRequestKind != 2 /* FormatOnEnter */; - }; - Rules.IsModuleDeclContext = function (context) { - return context.contextNode.kind === 208 /* ModuleDeclaration */; - }; - Rules.IsObjectTypeContext = function (context) { - return context.contextNode.kind === 148 /* TypeLiteral */; // && context.contextNode.parent.kind !== SyntaxKind.InterfaceDeclaration; - }; - Rules.IsTypeArgumentOrParameter = function (token, parent) { - if (token.kind !== 24 /* LessThanToken */ && token.kind !== 25 /* GreaterThanToken */) { - return false; - } - switch (parent.kind) { - case 144 /* TypeReference */: - case 204 /* ClassDeclaration */: - case 205 /* InterfaceDeclaration */: - case 203 /* FunctionDeclaration */: - case 165 /* FunctionExpression */: - case 166 /* ArrowFunction */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 140 /* CallSignature */: - case 141 /* ConstructSignature */: - case 160 /* CallExpression */: - case 161 /* NewExpression */: - return true; - default: - return false; - } - }; - Rules.IsTypeArgumentOrParameterContext = function (context) { - return Rules.IsTypeArgumentOrParameter(context.currentTokenSpan, context.currentTokenParent) || - Rules.IsTypeArgumentOrParameter(context.nextTokenSpan, context.nextTokenParent); - }; - Rules.IsVoidOpContext = function (context) { - return context.currentTokenSpan.kind === 99 /* VoidKeyword */ && context.currentTokenParent.kind === 169 /* VoidExpression */; - }; - Rules.IsYieldOrYieldStarWithOperand = function (context) { - return context.contextNode.kind === 175 /* YieldExpression */ && context.contextNode.expression !== undefined; - }; - return Rules; - })(); - formatting.Rules = Rules; - })(formatting = ts.formatting || (ts.formatting = {})); -})(ts || (ts = {})); -/// -/* @internal */ -var ts; -(function (ts) { - var formatting; - (function (formatting) { - var RulesMap = (function () { - function RulesMap() { - this.map = []; - this.mapRowLength = 0; - } - RulesMap.create = function (rules) { - var result = new RulesMap(); - result.Initialize(rules); - return result; - }; - RulesMap.prototype.Initialize = function (rules) { - this.mapRowLength = 127 /* LastToken */ + 1; - this.map = new Array(this.mapRowLength * this.mapRowLength); //new Array(this.mapRowLength * this.mapRowLength); - // This array is used only during construction of the rulesbucket in the map - var rulesBucketConstructionStateList = new Array(this.map.length); //new Array(this.map.length); - this.FillRules(rules, rulesBucketConstructionStateList); - return this.map; - }; - RulesMap.prototype.FillRules = function (rules, rulesBucketConstructionStateList) { - var _this = this; - rules.forEach(function (rule) { - _this.FillRule(rule, rulesBucketConstructionStateList); - }); - }; - RulesMap.prototype.GetRuleBucketIndex = function (row, column) { - var rulesBucketIndex = (row * this.mapRowLength) + column; - //Debug.Assert(rulesBucketIndex < this.map.Length, "Trying to access an index outside the array."); - return rulesBucketIndex; - }; - RulesMap.prototype.FillRule = function (rule, rulesBucketConstructionStateList) { - var _this = this; - var specificRule = rule.Descriptor.LeftTokenRange != formatting.Shared.TokenRange.Any && - rule.Descriptor.RightTokenRange != formatting.Shared.TokenRange.Any; - rule.Descriptor.LeftTokenRange.GetTokens().forEach(function (left) { - rule.Descriptor.RightTokenRange.GetTokens().forEach(function (right) { - var rulesBucketIndex = _this.GetRuleBucketIndex(left, right); - var rulesBucket = _this.map[rulesBucketIndex]; - if (rulesBucket == undefined) { - rulesBucket = _this.map[rulesBucketIndex] = new RulesBucket(); - } - rulesBucket.AddRule(rule, specificRule, rulesBucketConstructionStateList, rulesBucketIndex); - }); - }); - }; - RulesMap.prototype.GetRule = function (context) { - var bucketIndex = this.GetRuleBucketIndex(context.currentTokenSpan.kind, context.nextTokenSpan.kind); - var bucket = this.map[bucketIndex]; - if (bucket != null) { - for (var _i = 0, _a = bucket.Rules(); _i < _a.length; _i++) { - var rule = _a[_i]; - if (rule.Operation.Context.InContext(context)) { - return rule; - } - } - } - return null; - }; - return RulesMap; - })(); - formatting.RulesMap = RulesMap; - var MaskBitSize = 5; - var Mask = 0x1f; - (function (RulesPosition) { - RulesPosition[RulesPosition["IgnoreRulesSpecific"] = 0] = "IgnoreRulesSpecific"; - RulesPosition[RulesPosition["IgnoreRulesAny"] = MaskBitSize * 1] = "IgnoreRulesAny"; - RulesPosition[RulesPosition["ContextRulesSpecific"] = MaskBitSize * 2] = "ContextRulesSpecific"; - RulesPosition[RulesPosition["ContextRulesAny"] = MaskBitSize * 3] = "ContextRulesAny"; - RulesPosition[RulesPosition["NoContextRulesSpecific"] = MaskBitSize * 4] = "NoContextRulesSpecific"; - RulesPosition[RulesPosition["NoContextRulesAny"] = MaskBitSize * 5] = "NoContextRulesAny"; - })(formatting.RulesPosition || (formatting.RulesPosition = {})); - var RulesPosition = formatting.RulesPosition; - var RulesBucketConstructionState = (function () { - function RulesBucketConstructionState() { - //// The Rules list contains all the inserted rules into a rulebucket in the following order: - //// 1- Ignore rules with specific token combination - //// 2- Ignore rules with any token combination - //// 3- Context rules with specific token combination - //// 4- Context rules with any token combination - //// 5- Non-context rules with specific token combination - //// 6- Non-context rules with any token combination - //// - //// The member rulesInsertionIndexBitmap is used to describe the number of rules - //// in each sub-bucket (above) hence can be used to know the index of where to insert - //// the next rule. It's a bitmap which contains 6 different sections each is given 5 bits. - //// - //// Example: - //// In order to insert a rule to the end of sub-bucket (3), we get the index by adding - //// the values in the bitmap segments 3rd, 2nd, and 1st. - this.rulesInsertionIndexBitmap = 0; - } - RulesBucketConstructionState.prototype.GetInsertionIndex = function (maskPosition) { - var index = 0; - var pos = 0; - var indexBitmap = this.rulesInsertionIndexBitmap; - while (pos <= maskPosition) { - index += (indexBitmap & Mask); - indexBitmap >>= MaskBitSize; - pos += MaskBitSize; - } - return index; - }; - RulesBucketConstructionState.prototype.IncreaseInsertionIndex = function (maskPosition) { - var value = (this.rulesInsertionIndexBitmap >> maskPosition) & Mask; - value++; - ts.Debug.assert((value & Mask) == value, "Adding more rules into the sub-bucket than allowed. Maximum allowed is 32 rules."); - var temp = this.rulesInsertionIndexBitmap & ~(Mask << maskPosition); - temp |= value << maskPosition; - this.rulesInsertionIndexBitmap = temp; - }; - return RulesBucketConstructionState; - })(); - formatting.RulesBucketConstructionState = RulesBucketConstructionState; - var RulesBucket = (function () { - function RulesBucket() { - this.rules = []; - } - RulesBucket.prototype.Rules = function () { - return this.rules; - }; - RulesBucket.prototype.AddRule = function (rule, specificTokens, constructionState, rulesBucketIndex) { - var position; - if (rule.Operation.Action == 1 /* Ignore */) { - position = specificTokens ? - RulesPosition.IgnoreRulesSpecific : - RulesPosition.IgnoreRulesAny; - } - else if (!rule.Operation.Context.IsAny()) { - position = specificTokens ? - RulesPosition.ContextRulesSpecific : - RulesPosition.ContextRulesAny; - } - else { - position = specificTokens ? - RulesPosition.NoContextRulesSpecific : - RulesPosition.NoContextRulesAny; - } - var state = constructionState[rulesBucketIndex]; - if (state === undefined) { - state = constructionState[rulesBucketIndex] = new RulesBucketConstructionState(); - } - var index = state.GetInsertionIndex(position); - this.rules.splice(index, 0, rule); - state.IncreaseInsertionIndex(position); - }; - return RulesBucket; - })(); - formatting.RulesBucket = RulesBucket; - })(formatting = ts.formatting || (ts.formatting = {})); -})(ts || (ts = {})); -/// -/* @internal */ -var ts; -(function (ts) { - var formatting; - (function (formatting) { - var Shared; - (function (Shared) { - var TokenRangeAccess = (function () { - function TokenRangeAccess(from, to, except) { - this.tokens = []; - for (var token = from; token <= to; token++) { - if (except.indexOf(token) < 0) { - this.tokens.push(token); - } - } - } - TokenRangeAccess.prototype.GetTokens = function () { - return this.tokens; - }; - TokenRangeAccess.prototype.Contains = function (token) { - return this.tokens.indexOf(token) >= 0; - }; - return TokenRangeAccess; - })(); - Shared.TokenRangeAccess = TokenRangeAccess; - var TokenValuesAccess = (function () { - function TokenValuesAccess(tks) { - this.tokens = tks && tks.length ? tks : []; - } - TokenValuesAccess.prototype.GetTokens = function () { - return this.tokens; - }; - TokenValuesAccess.prototype.Contains = function (token) { - return this.tokens.indexOf(token) >= 0; - }; - return TokenValuesAccess; - })(); - Shared.TokenValuesAccess = TokenValuesAccess; - var TokenSingleValueAccess = (function () { - function TokenSingleValueAccess(token) { - this.token = token; - } - TokenSingleValueAccess.prototype.GetTokens = function () { - return [this.token]; - }; - TokenSingleValueAccess.prototype.Contains = function (tokenValue) { - return tokenValue == this.token; - }; - return TokenSingleValueAccess; - })(); - Shared.TokenSingleValueAccess = TokenSingleValueAccess; - var TokenAllAccess = (function () { - function TokenAllAccess() { - } - TokenAllAccess.prototype.GetTokens = function () { - var result = []; - for (var token = 0 /* FirstToken */; token <= 127 /* LastToken */; token++) { - result.push(token); - } - return result; - }; - TokenAllAccess.prototype.Contains = function (tokenValue) { - return true; - }; - TokenAllAccess.prototype.toString = function () { - return "[allTokens]"; - }; - return TokenAllAccess; - })(); - Shared.TokenAllAccess = TokenAllAccess; - var TokenRange = (function () { - function TokenRange(tokenAccess) { - this.tokenAccess = tokenAccess; - } - TokenRange.FromToken = function (token) { - return new TokenRange(new TokenSingleValueAccess(token)); - }; - TokenRange.FromTokens = function (tokens) { - return new TokenRange(new TokenValuesAccess(tokens)); - }; - TokenRange.FromRange = function (f, to, except) { - if (except === void 0) { except = []; } - return new TokenRange(new TokenRangeAccess(f, to, except)); - }; - TokenRange.AllTokens = function () { - return new TokenRange(new TokenAllAccess()); - }; - TokenRange.prototype.GetTokens = function () { - return this.tokenAccess.GetTokens(); - }; - TokenRange.prototype.Contains = function (token) { - return this.tokenAccess.Contains(token); - }; - TokenRange.prototype.toString = function () { - return this.tokenAccess.toString(); - }; - TokenRange.Any = TokenRange.AllTokens(); - TokenRange.AnyIncludingMultilineComments = TokenRange.FromTokens(TokenRange.Any.GetTokens().concat([3 /* MultiLineCommentTrivia */])); - TokenRange.Keywords = TokenRange.FromRange(66 /* FirstKeyword */, 127 /* LastKeyword */); - TokenRange.BinaryOperators = TokenRange.FromRange(24 /* FirstBinaryOperator */, 64 /* LastBinaryOperator */); - TokenRange.BinaryKeywordOperators = TokenRange.FromTokens([86 /* InKeyword */, 87 /* InstanceOfKeyword */, 127 /* OfKeyword */, 117 /* IsKeyword */]); - TokenRange.UnaryPrefixOperators = TokenRange.FromTokens([38 /* PlusPlusToken */, 39 /* MinusMinusToken */, 47 /* TildeToken */, 46 /* ExclamationToken */]); - TokenRange.UnaryPrefixExpressions = TokenRange.FromTokens([7 /* NumericLiteral */, 65 /* Identifier */, 16 /* OpenParenToken */, 18 /* OpenBracketToken */, 14 /* OpenBraceToken */, 93 /* ThisKeyword */, 88 /* NewKeyword */]); - TokenRange.UnaryPreincrementExpressions = TokenRange.FromTokens([65 /* Identifier */, 16 /* OpenParenToken */, 93 /* ThisKeyword */, 88 /* NewKeyword */]); - TokenRange.UnaryPostincrementExpressions = TokenRange.FromTokens([65 /* Identifier */, 17 /* CloseParenToken */, 19 /* CloseBracketToken */, 88 /* NewKeyword */]); - TokenRange.UnaryPredecrementExpressions = TokenRange.FromTokens([65 /* Identifier */, 16 /* OpenParenToken */, 93 /* ThisKeyword */, 88 /* NewKeyword */]); - TokenRange.UnaryPostdecrementExpressions = TokenRange.FromTokens([65 /* Identifier */, 17 /* CloseParenToken */, 19 /* CloseBracketToken */, 88 /* NewKeyword */]); - TokenRange.Comments = TokenRange.FromTokens([2 /* SingleLineCommentTrivia */, 3 /* MultiLineCommentTrivia */]); - TokenRange.TypeNames = TokenRange.FromTokens([65 /* Identifier */, 121 /* NumberKeyword */, 123 /* StringKeyword */, 113 /* BooleanKeyword */, 124 /* SymbolKeyword */, 99 /* VoidKeyword */, 112 /* AnyKeyword */]); - return TokenRange; - })(); - Shared.TokenRange = TokenRange; - })(Shared = formatting.Shared || (formatting.Shared = {})); - })(formatting = ts.formatting || (ts.formatting = {})); -})(ts || (ts = {})); -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/* @internal */ -var ts; -(function (ts) { - var formatting; - (function (formatting) { - var RulesProvider = (function () { - function RulesProvider() { - this.globalRules = new formatting.Rules(); - } - RulesProvider.prototype.getRuleName = function (rule) { - return this.globalRules.getRuleName(rule); - }; - RulesProvider.prototype.getRuleByName = function (name) { - return this.globalRules[name]; - }; - RulesProvider.prototype.getRulesMap = function () { - return this.rulesMap; - }; - RulesProvider.prototype.ensureUpToDate = function (options) { - if (this.options == null || !ts.compareDataObjects(this.options, options)) { - var activeRules = this.createActiveRules(options); - var rulesMap = formatting.RulesMap.create(activeRules); - this.activeRules = activeRules; - this.rulesMap = rulesMap; - this.options = ts.clone(options); - } - }; - RulesProvider.prototype.createActiveRules = function (options) { - var rules = this.globalRules.HighPriorityCommonRules.slice(0); - if (options.InsertSpaceAfterCommaDelimiter) { - rules.push(this.globalRules.SpaceAfterComma); - } - else { - rules.push(this.globalRules.NoSpaceAfterComma); - } - if (options.InsertSpaceAfterFunctionKeywordForAnonymousFunctions) { - rules.push(this.globalRules.SpaceAfterAnonymousFunctionKeyword); - } - else { - rules.push(this.globalRules.NoSpaceAfterAnonymousFunctionKeyword); - } - if (options.InsertSpaceAfterKeywordsInControlFlowStatements) { - rules.push(this.globalRules.SpaceAfterKeywordInControl); - } - else { - rules.push(this.globalRules.NoSpaceAfterKeywordInControl); - } - if (options.InsertSpaceAfterOpeningAndBeforeClosingNonemptyParenthesis) { - rules.push(this.globalRules.SpaceAfterOpenParen); - rules.push(this.globalRules.SpaceBeforeCloseParen); - rules.push(this.globalRules.NoSpaceBetweenParens); - } - else { - rules.push(this.globalRules.NoSpaceAfterOpenParen); - rules.push(this.globalRules.NoSpaceBeforeCloseParen); - rules.push(this.globalRules.NoSpaceBetweenParens); - } - if (options.InsertSpaceAfterSemicolonInForStatements) { - rules.push(this.globalRules.SpaceAfterSemicolonInFor); - } - else { - rules.push(this.globalRules.NoSpaceAfterSemicolonInFor); - } - if (options.InsertSpaceBeforeAndAfterBinaryOperators) { - rules.push(this.globalRules.SpaceBeforeBinaryOperator); - rules.push(this.globalRules.SpaceAfterBinaryOperator); - } - else { - rules.push(this.globalRules.NoSpaceBeforeBinaryOperator); - rules.push(this.globalRules.NoSpaceAfterBinaryOperator); - } - if (options.PlaceOpenBraceOnNewLineForControlBlocks) { - rules.push(this.globalRules.NewLineBeforeOpenBraceInControl); - } - if (options.PlaceOpenBraceOnNewLineForFunctions) { - rules.push(this.globalRules.NewLineBeforeOpenBraceInFunction); - rules.push(this.globalRules.NewLineBeforeOpenBraceInTypeScriptDeclWithBlock); - } - rules = rules.concat(this.globalRules.LowPriorityCommonRules); - return rules; - }; - return RulesProvider; - })(); - formatting.RulesProvider = RulesProvider; - })(formatting = ts.formatting || (ts.formatting = {})); -})(ts || (ts = {})); -/// -/// -/// -/// -/* @internal */ -var ts; -(function (ts) { - var formatting; - (function (formatting) { - var Constants; - (function (Constants) { - Constants[Constants["Unknown"] = -1] = "Unknown"; - })(Constants || (Constants = {})); - function formatOnEnter(position, sourceFile, rulesProvider, options) { - var line = sourceFile.getLineAndCharacterOfPosition(position).line; - if (line === 0) { - return []; - } - // get the span for the previous\current line - var span = { - // get start position for the previous line - pos: ts.getStartPositionOfLine(line - 1, sourceFile), - // get end position for the current line (end value is exclusive so add 1 to the result) - end: ts.getEndLinePosition(line, sourceFile) + 1 - }; - return formatSpan(span, sourceFile, options, rulesProvider, 2 /* FormatOnEnter */); - } - formatting.formatOnEnter = formatOnEnter; - function formatOnSemicolon(position, sourceFile, rulesProvider, options) { - return formatOutermostParent(position, 22 /* SemicolonToken */, sourceFile, options, rulesProvider, 3 /* FormatOnSemicolon */); - } - formatting.formatOnSemicolon = formatOnSemicolon; - function formatOnClosingCurly(position, sourceFile, rulesProvider, options) { - return formatOutermostParent(position, 15 /* CloseBraceToken */, sourceFile, options, rulesProvider, 4 /* FormatOnClosingCurlyBrace */); - } - formatting.formatOnClosingCurly = formatOnClosingCurly; - function formatDocument(sourceFile, rulesProvider, options) { - var span = { - pos: 0, - end: sourceFile.text.length - }; - return formatSpan(span, sourceFile, options, rulesProvider, 0 /* FormatDocument */); - } - formatting.formatDocument = formatDocument; - function formatSelection(start, end, sourceFile, rulesProvider, options) { - // format from the beginning of the line - var span = { - pos: ts.getLineStartPositionForPosition(start, sourceFile), - end: end - }; - return formatSpan(span, sourceFile, options, rulesProvider, 1 /* FormatSelection */); - } - formatting.formatSelection = formatSelection; - function formatOutermostParent(position, expectedLastToken, sourceFile, options, rulesProvider, requestKind) { - var parent = findOutermostParent(position, expectedLastToken, sourceFile); - if (!parent) { - return []; - } - var span = { - pos: ts.getLineStartPositionForPosition(parent.getStart(sourceFile), sourceFile), - end: parent.end - }; - return formatSpan(span, sourceFile, options, rulesProvider, requestKind); - } - function findOutermostParent(position, expectedTokenKind, sourceFile) { - var precedingToken = ts.findPrecedingToken(position, sourceFile); - // when it is claimed that trigger character was typed at given position - // we verify that there is a token with a matching kind whose end is equal to position (because the character was just typed). - // If this condition is not hold - then trigger character was typed in some other context, - // i.e.in comment and thus should not trigger autoformatting - if (!precedingToken || - precedingToken.kind !== expectedTokenKind || - position !== precedingToken.getEnd()) { - return undefined; - } - // walk up and search for the parent node that ends at the same position with precedingToken. - // for cases like this - // - // let x = 1; - // while (true) { - // } - // after typing close curly in while statement we want to reformat just the while statement. - // However if we just walk upwards searching for the parent that has the same end value - - // we'll end up with the whole source file. isListElement allows to stop on the list element level - var current = precedingToken; - while (current && - current.parent && - current.parent.end === precedingToken.end && - !isListElement(current.parent, current)) { - current = current.parent; - } - return current; - } - // Returns true if node is a element in some list in parent - // i.e. parent is class declaration with the list of members and node is one of members. - function isListElement(parent, node) { - switch (parent.kind) { - case 204 /* ClassDeclaration */: - case 205 /* InterfaceDeclaration */: - return ts.rangeContainsRange(parent.members, node); - case 208 /* ModuleDeclaration */: - var body = parent.body; - return body && body.kind === 182 /* Block */ && ts.rangeContainsRange(body.statements, node); - case 230 /* SourceFile */: - case 182 /* Block */: - case 209 /* ModuleBlock */: - return ts.rangeContainsRange(parent.statements, node); - case 226 /* CatchClause */: - return ts.rangeContainsRange(parent.block.statements, node); - } - return false; - } - /** find node that fully contains given text range */ - function findEnclosingNode(range, sourceFile) { - return find(sourceFile); - function find(n) { - var candidate = ts.forEachChild(n, function (c) { return ts.startEndContainsRange(c.getStart(sourceFile), c.end, range) && c; }); - if (candidate) { - var result = find(candidate); - if (result) { - return result; - } - } - return n; - } - } - /** formatting is not applied to ranges that contain parse errors. - * This function will return a predicate that for a given text range will tell - * if there are any parse errors that overlap with the range. - */ - function prepareRangeContainsErrorFunction(errors, originalRange) { - if (!errors.length) { - return rangeHasNoErrors; - } - // pick only errors that fall in range - var sorted = errors - .filter(function (d) { return ts.rangeOverlapsWithStartEnd(originalRange, d.start, d.start + d.length); }) - .sort(function (e1, e2) { return e1.start - e2.start; }); - if (!sorted.length) { - return rangeHasNoErrors; - } - var index = 0; - return function (r) { - // in current implementation sequence of arguments [r1, r2...] is monotonically increasing. - // 'index' tracks the index of the most recent error that was checked. - while (true) { - if (index >= sorted.length) { - // all errors in the range were already checked -> no error in specified range - return false; - } - var error = sorted[index]; - if (r.end <= error.start) { - // specified range ends before the error refered by 'index' - no error in range - return false; - } - if (ts.startEndOverlapsWithStartEnd(r.pos, r.end, error.start, error.start + error.length)) { - // specified range overlaps with error range - return true; - } - index++; - } - }; - function rangeHasNoErrors(r) { - return false; - } - } - /** - * Start of the original range might fall inside the comment - scanner will not yield appropriate results - * This function will look for token that is located before the start of target range - * and return its end as start position for the scanner. - */ - function getScanStartPosition(enclosingNode, originalRange, sourceFile) { - var start = enclosingNode.getStart(sourceFile); - if (start === originalRange.pos && enclosingNode.end === originalRange.end) { - return start; - } - var precedingToken = ts.findPrecedingToken(originalRange.pos, sourceFile); - if (!precedingToken) { - // no preceding token found - start from the beginning of enclosing node - return enclosingNode.pos; - } - // preceding token ends after the start of original range (i.e when originaRange.pos falls in the middle of literal) - // start from the beginning of enclosingNode to handle the entire 'originalRange' - if (precedingToken.end >= originalRange.pos) { - return enclosingNode.pos; - } - return precedingToken.end; - } - /* - * For cases like - * if (a || - * b ||$ - * c) {...} - * If we hit Enter at $ we want line ' b ||' to be indented. - * Formatting will be applied to the last two lines. - * Node that fully encloses these lines is binary expression 'a ||...'. - * Initial indentation for this node will be 0. - * Binary expressions don't introduce new indentation scopes, however it is possible - * that some parent node on the same line does - like if statement in this case. - * Note that we are considering parents only from the same line with initial node - - * if parent is on the different line - its delta was already contributed - * to the initial indentation. - */ - function getOwnOrInheritedDelta(n, options, sourceFile) { - var previousLine = -1 /* Unknown */; - var childKind = 0 /* Unknown */; - while (n) { - var line = sourceFile.getLineAndCharacterOfPosition(n.getStart(sourceFile)).line; - if (previousLine !== -1 /* Unknown */ && line !== previousLine) { - break; - } - if (formatting.SmartIndenter.shouldIndentChildNode(n.kind, childKind)) { - return options.IndentSize; - } - previousLine = line; - childKind = n.kind; - n = n.parent; - } - return 0; - } - function formatSpan(originalRange, sourceFile, options, rulesProvider, requestKind) { - var rangeContainsError = prepareRangeContainsErrorFunction(sourceFile.parseDiagnostics, originalRange); - // formatting context is used by rules provider - var formattingContext = new formatting.FormattingContext(sourceFile, requestKind); - // find the smallest node that fully wraps the range and compute the initial indentation for the node - var enclosingNode = findEnclosingNode(originalRange, sourceFile); - var formattingScanner = formatting.getFormattingScanner(sourceFile, getScanStartPosition(enclosingNode, originalRange, sourceFile), originalRange.end); - var initialIndentation = formatting.SmartIndenter.getIndentationForNode(enclosingNode, originalRange, sourceFile, options); - var previousRangeHasError; - var previousRange; - var previousParent; - var previousRangeStartLine; - var lastIndentedLine; - var indentationOnLastIndentedLine; - var edits = []; - formattingScanner.advance(); - if (formattingScanner.isOnToken()) { - var startLine = sourceFile.getLineAndCharacterOfPosition(enclosingNode.getStart(sourceFile)).line; - var undecoratedStartLine = startLine; - if (enclosingNode.decorators) { - undecoratedStartLine = sourceFile.getLineAndCharacterOfPosition(ts.getNonDecoratorTokenPosOfNode(enclosingNode, sourceFile)).line; - } - var delta = getOwnOrInheritedDelta(enclosingNode, options, sourceFile); - processNode(enclosingNode, enclosingNode, startLine, undecoratedStartLine, initialIndentation, delta); - } - formattingScanner.close(); - return edits; - // local functions - /** Tries to compute the indentation for a list element. - * If list element is not in range then - * function will pick its actual indentation - * so it can be pushed downstream as inherited indentation. - * If list element is in the range - its indentation will be equal - * to inherited indentation from its predecessors. - */ - function tryComputeIndentationForListItem(startPos, endPos, parentStartLine, range, inheritedIndentation) { - if (ts.rangeOverlapsWithStartEnd(range, startPos, endPos)) { - if (inheritedIndentation !== -1 /* Unknown */) { - return inheritedIndentation; - } - } - else { - var startLine = sourceFile.getLineAndCharacterOfPosition(startPos).line; - var startLinePosition = ts.getLineStartPositionForPosition(startPos, sourceFile); - var column = formatting.SmartIndenter.findFirstNonWhitespaceColumn(startLinePosition, startPos, sourceFile, options); - if (startLine !== parentStartLine || startPos === column) { - return column; - } - } - return -1 /* Unknown */; - } - function computeIndentation(node, startLine, inheritedIndentation, parent, parentDynamicIndentation, effectiveParentStartLine) { - var indentation = inheritedIndentation; - if (indentation === -1 /* Unknown */) { - if (isSomeBlock(node.kind)) { - // blocks should be indented in - // - other blocks - // - source file - // - switch\default clauses - if (isSomeBlock(parent.kind) || - parent.kind === 230 /* SourceFile */ || - parent.kind === 223 /* CaseClause */ || - parent.kind === 224 /* DefaultClause */) { - indentation = parentDynamicIndentation.getIndentation() + parentDynamicIndentation.getDelta(); - } - else { - indentation = parentDynamicIndentation.getIndentation(); - } - } - else { - if (formatting.SmartIndenter.childStartsOnTheSameLineWithElseInIfStatement(parent, node, startLine, sourceFile)) { - indentation = parentDynamicIndentation.getIndentation(); - } - else { - indentation = parentDynamicIndentation.getIndentation() + parentDynamicIndentation.getDelta(); - } - } - } - var delta = formatting.SmartIndenter.shouldIndentChildNode(node.kind, 0 /* Unknown */) ? options.IndentSize : 0; - if (effectiveParentStartLine === startLine) { - // if node is located on the same line with the parent - // - inherit indentation from the parent - // - push children if either parent of node itself has non-zero delta - indentation = startLine === lastIndentedLine - ? indentationOnLastIndentedLine - : parentDynamicIndentation.getIndentation(); - delta = Math.min(options.IndentSize, parentDynamicIndentation.getDelta() + delta); - } - return { - indentation: indentation, - delta: delta - }; - } - function getFirstNonDecoratorTokenOfNode(node) { - if (node.modifiers && node.modifiers.length) { - return node.modifiers[0].kind; - } - switch (node.kind) { - case 204 /* ClassDeclaration */: return 69 /* ClassKeyword */; - case 205 /* InterfaceDeclaration */: return 103 /* InterfaceKeyword */; - case 203 /* FunctionDeclaration */: return 83 /* FunctionKeyword */; - case 207 /* EnumDeclaration */: return 207 /* EnumDeclaration */; - case 138 /* GetAccessor */: return 116 /* GetKeyword */; - case 139 /* SetAccessor */: return 122 /* SetKeyword */; - case 136 /* MethodDeclaration */: - if (node.asteriskToken) { - return 35 /* AsteriskToken */; - } - // fall-through - case 134 /* PropertyDeclaration */: - case 131 /* Parameter */: - return node.name.kind; - } - } - function getDynamicIndentation(node, nodeStartLine, indentation, delta) { - return { - getIndentationForComment: function (kind) { - switch (kind) { - // preceding comment to the token that closes the indentation scope inherits the indentation from the scope - // .. { - // // comment - // } - case 15 /* CloseBraceToken */: - case 19 /* CloseBracketToken */: - return indentation + delta; - } - return indentation; - }, - getIndentationForToken: function (line, kind) { - if (nodeStartLine !== line && node.decorators) { - if (kind === getFirstNonDecoratorTokenOfNode(node)) { - // if this token is the first token following the list of decorators, we do not need to indent - return indentation; - } - } - switch (kind) { - // open and close brace, 'else' and 'while' (in do statement) tokens has indentation of the parent - case 14 /* OpenBraceToken */: - case 15 /* CloseBraceToken */: - case 18 /* OpenBracketToken */: - case 19 /* CloseBracketToken */: - case 76 /* ElseKeyword */: - case 100 /* WhileKeyword */: - case 52 /* AtToken */: - return indentation; - default: - // if token line equals to the line of containing node (this is a first token in the node) - use node indentation - return nodeStartLine !== line ? indentation + delta : indentation; - } - }, - getIndentation: function () { return indentation; }, - getDelta: function () { return delta; }, - recomputeIndentation: function (lineAdded) { - if (node.parent && formatting.SmartIndenter.shouldIndentChildNode(node.parent.kind, node.kind)) { - if (lineAdded) { - indentation += options.IndentSize; - } - else { - indentation -= options.IndentSize; - } - if (formatting.SmartIndenter.shouldIndentChildNode(node.kind, 0 /* Unknown */)) { - delta = options.IndentSize; - } - else { - delta = 0; - } - } - } - }; - } - function processNode(node, contextNode, nodeStartLine, undecoratedNodeStartLine, indentation, delta) { - if (!ts.rangeOverlapsWithStartEnd(originalRange, node.getStart(sourceFile), node.getEnd())) { - return; - } - var nodeDynamicIndentation = getDynamicIndentation(node, nodeStartLine, indentation, delta); - // a useful observations when tracking context node - // / - // [a] - // / | \ - // [b] [c] [d] - // node 'a' is a context node for nodes 'b', 'c', 'd' - // except for the leftmost leaf token in [b] - in this case context node ('e') is located somewhere above 'a' - // this rule can be applied recursively to child nodes of 'a'. - // - // context node is set to parent node value after processing every child node - // context node is set to parent of the token after processing every token - var childContextNode = contextNode; - // if there are any tokens that logically belong to node and interleave child nodes - // such tokens will be consumed in processChildNode for for the child that follows them - ts.forEachChild(node, function (child) { - processChildNode(child, -1 /* Unknown */, node, nodeDynamicIndentation, nodeStartLine, undecoratedNodeStartLine, false); - }, function (nodes) { - processChildNodes(nodes, node, nodeStartLine, nodeDynamicIndentation); - }); - // proceed any tokens in the node that are located after child nodes - while (formattingScanner.isOnToken()) { - var tokenInfo = formattingScanner.readTokenInfo(node); - if (tokenInfo.token.end > node.end) { - break; - } - consumeTokenAndAdvanceScanner(tokenInfo, node, nodeDynamicIndentation); - } - function processChildNode(child, inheritedIndentation, parent, parentDynamicIndentation, parentStartLine, undecoratedParentStartLine, isListItem) { - var childStartPos = child.getStart(sourceFile); - var childStartLine = sourceFile.getLineAndCharacterOfPosition(childStartPos).line; - var undecoratedChildStartLine = childStartLine; - if (child.decorators) { - undecoratedChildStartLine = sourceFile.getLineAndCharacterOfPosition(ts.getNonDecoratorTokenPosOfNode(child, sourceFile)).line; - } - // if child is a list item - try to get its indentation - var childIndentationAmount = -1 /* Unknown */; - if (isListItem) { - childIndentationAmount = tryComputeIndentationForListItem(childStartPos, child.end, parentStartLine, originalRange, inheritedIndentation); - if (childIndentationAmount !== -1 /* Unknown */) { - inheritedIndentation = childIndentationAmount; - } - } - // child node is outside the target range - do not dive inside - if (!ts.rangeOverlapsWithStartEnd(originalRange, child.pos, child.end)) { - return inheritedIndentation; - } - if (child.getFullWidth() === 0) { - return inheritedIndentation; - } - while (formattingScanner.isOnToken()) { - // proceed any parent tokens that are located prior to child.getStart() - var tokenInfo = formattingScanner.readTokenInfo(node); - if (tokenInfo.token.end > childStartPos) { - // stop when formatting scanner advances past the beginning of the child - break; - } - consumeTokenAndAdvanceScanner(tokenInfo, node, parentDynamicIndentation); - } - if (!formattingScanner.isOnToken()) { - return inheritedIndentation; - } - if (ts.isToken(child)) { - // if child node is a token, it does not impact indentation, proceed it using parent indentation scope rules - var tokenInfo = formattingScanner.readTokenInfo(child); - ts.Debug.assert(tokenInfo.token.end === child.end); - consumeTokenAndAdvanceScanner(tokenInfo, node, parentDynamicIndentation); - return inheritedIndentation; - } - var effectiveParentStartLine = child.kind === 132 /* Decorator */ ? childStartLine : undecoratedParentStartLine; - var childIndentation = computeIndentation(child, childStartLine, childIndentationAmount, node, parentDynamicIndentation, effectiveParentStartLine); - processNode(child, childContextNode, childStartLine, undecoratedChildStartLine, childIndentation.indentation, childIndentation.delta); - childContextNode = node; - return inheritedIndentation; - } - function processChildNodes(nodes, parent, parentStartLine, parentDynamicIndentation) { - var listStartToken = getOpenTokenForList(parent, nodes); - var listEndToken = getCloseTokenForOpenToken(listStartToken); - var listDynamicIndentation = parentDynamicIndentation; - var startLine = parentStartLine; - if (listStartToken !== 0 /* Unknown */) { - // introduce a new indentation scope for lists (including list start and end tokens) - while (formattingScanner.isOnToken()) { - var tokenInfo = formattingScanner.readTokenInfo(parent); - if (tokenInfo.token.end > nodes.pos) { - // stop when formatting scanner moves past the beginning of node list - break; - } - else if (tokenInfo.token.kind === listStartToken) { - // consume list start token - startLine = sourceFile.getLineAndCharacterOfPosition(tokenInfo.token.pos).line; - var indentation_1 = computeIndentation(tokenInfo.token, startLine, -1 /* Unknown */, parent, parentDynamicIndentation, startLine); - listDynamicIndentation = getDynamicIndentation(parent, parentStartLine, indentation_1.indentation, indentation_1.delta); - consumeTokenAndAdvanceScanner(tokenInfo, parent, listDynamicIndentation); - } - else { - // consume any tokens that precede the list as child elements of 'node' using its indentation scope - consumeTokenAndAdvanceScanner(tokenInfo, parent, parentDynamicIndentation); - } - } - } - var inheritedIndentation = -1 /* Unknown */; - for (var _i = 0; _i < nodes.length; _i++) { - var child = nodes[_i]; - inheritedIndentation = processChildNode(child, inheritedIndentation, node, listDynamicIndentation, startLine, startLine, true); - } - if (listEndToken !== 0 /* Unknown */) { - if (formattingScanner.isOnToken()) { - var tokenInfo = formattingScanner.readTokenInfo(parent); - // consume the list end token only if it is still belong to the parent - // there might be the case when current token matches end token but does not considered as one - // function (x: function) <-- - // without this check close paren will be interpreted as list end token for function expression which is wrong - if (tokenInfo.token.kind === listEndToken && ts.rangeContainsRange(parent, tokenInfo.token)) { - // consume list end token - consumeTokenAndAdvanceScanner(tokenInfo, parent, listDynamicIndentation); - } - } - } - } - function consumeTokenAndAdvanceScanner(currentTokenInfo, parent, dynamicIndentation) { - ts.Debug.assert(ts.rangeContainsRange(parent, currentTokenInfo.token)); - var lastTriviaWasNewLine = formattingScanner.lastTrailingTriviaWasNewLine(); - var indentToken = false; - if (currentTokenInfo.leadingTrivia) { - processTrivia(currentTokenInfo.leadingTrivia, parent, childContextNode, dynamicIndentation); - } - var lineAdded; - var isTokenInRange = ts.rangeContainsRange(originalRange, currentTokenInfo.token); - var tokenStart = sourceFile.getLineAndCharacterOfPosition(currentTokenInfo.token.pos); - if (isTokenInRange) { - var rangeHasError = rangeContainsError(currentTokenInfo.token); - // save prevStartLine since processRange will overwrite this value with current ones - var prevStartLine = previousRangeStartLine; - lineAdded = processRange(currentTokenInfo.token, tokenStart, parent, childContextNode, dynamicIndentation); - if (rangeHasError) { - // do not indent comments\token if token range overlaps with some error - indentToken = false; - } - else { - if (lineAdded !== undefined) { - indentToken = lineAdded; - } - else { - indentToken = lastTriviaWasNewLine && tokenStart.line !== prevStartLine; - } - } - } - if (currentTokenInfo.trailingTrivia) { - processTrivia(currentTokenInfo.trailingTrivia, parent, childContextNode, dynamicIndentation); - } - if (indentToken) { - var indentNextTokenOrTrivia = true; - if (currentTokenInfo.leadingTrivia) { - for (var _i = 0, _a = currentTokenInfo.leadingTrivia; _i < _a.length; _i++) { - var triviaItem = _a[_i]; - if (!ts.rangeContainsRange(originalRange, triviaItem)) { - continue; - } - switch (triviaItem.kind) { - case 3 /* MultiLineCommentTrivia */: - var commentIndentation = dynamicIndentation.getIndentationForComment(currentTokenInfo.token.kind); - indentMultilineComment(triviaItem, commentIndentation, !indentNextTokenOrTrivia); - indentNextTokenOrTrivia = false; - break; - case 2 /* SingleLineCommentTrivia */: - if (indentNextTokenOrTrivia) { - var commentIndentation_1 = dynamicIndentation.getIndentationForComment(currentTokenInfo.token.kind); - insertIndentation(triviaItem.pos, commentIndentation_1, false); - indentNextTokenOrTrivia = false; - } - break; - case 4 /* NewLineTrivia */: - indentNextTokenOrTrivia = true; - break; - } - } - } - // indent token only if is it is in target range and does not overlap with any error ranges - if (isTokenInRange && !rangeContainsError(currentTokenInfo.token)) { - var tokenIndentation = dynamicIndentation.getIndentationForToken(tokenStart.line, currentTokenInfo.token.kind); - insertIndentation(currentTokenInfo.token.pos, tokenIndentation, lineAdded); - lastIndentedLine = tokenStart.line; - indentationOnLastIndentedLine = tokenIndentation; - } - } - formattingScanner.advance(); - childContextNode = parent; - } - } - function processTrivia(trivia, parent, contextNode, dynamicIndentation) { - for (var _i = 0; _i < trivia.length; _i++) { - var triviaItem = trivia[_i]; - if (ts.isComment(triviaItem.kind) && ts.rangeContainsRange(originalRange, triviaItem)) { - var triviaItemStart = sourceFile.getLineAndCharacterOfPosition(triviaItem.pos); - processRange(triviaItem, triviaItemStart, parent, contextNode, dynamicIndentation); - } - } - } - function processRange(range, rangeStart, parent, contextNode, dynamicIndentation) { - var rangeHasError = rangeContainsError(range); - var lineAdded; - if (!rangeHasError && !previousRangeHasError) { - if (!previousRange) { - // trim whitespaces starting from the beginning of the span up to the current line - var originalStart = sourceFile.getLineAndCharacterOfPosition(originalRange.pos); - trimTrailingWhitespacesForLines(originalStart.line, rangeStart.line); - } - else { - lineAdded = - processPair(range, rangeStart.line, parent, previousRange, previousRangeStartLine, previousParent, contextNode, dynamicIndentation); - } - } - previousRange = range; - previousParent = parent; - previousRangeStartLine = rangeStart.line; - previousRangeHasError = rangeHasError; - return lineAdded; - } - function processPair(currentItem, currentStartLine, currentParent, previousItem, previousStartLine, previousParent, contextNode, dynamicIndentation) { - formattingContext.updateContext(previousItem, previousParent, currentItem, currentParent, contextNode); - var rule = rulesProvider.getRulesMap().GetRule(formattingContext); - var trimTrailingWhitespaces; - var lineAdded; - if (rule) { - applyRuleEdits(rule, previousItem, previousStartLine, currentItem, currentStartLine); - if (rule.Operation.Action & (2 /* Space */ | 8 /* Delete */) && currentStartLine !== previousStartLine) { - lineAdded = false; - // Handle the case where the next line is moved to be the end of this line. - // In this case we don't indent the next line in the next pass. - if (currentParent.getStart(sourceFile) === currentItem.pos) { - dynamicIndentation.recomputeIndentation(false); - } - } - else if (rule.Operation.Action & 4 /* NewLine */ && currentStartLine === previousStartLine) { - lineAdded = true; - // Handle the case where token2 is moved to the new line. - // In this case we indent token2 in the next pass but we set - // sameLineIndent flag to notify the indenter that the indentation is within the line. - if (currentParent.getStart(sourceFile) === currentItem.pos) { - dynamicIndentation.recomputeIndentation(true); - } - } - // We need to trim trailing whitespace between the tokens if they were on different lines, and no rule was applied to put them on the same line - trimTrailingWhitespaces = - (rule.Operation.Action & (4 /* NewLine */ | 2 /* Space */)) && - rule.Flag !== 1 /* CanDeleteNewLines */; - } - else { - trimTrailingWhitespaces = true; - } - if (currentStartLine !== previousStartLine && trimTrailingWhitespaces) { - // We need to trim trailing whitespace between the tokens if they were on different lines, and no rule was applied to put them on the same line - trimTrailingWhitespacesForLines(previousStartLine, currentStartLine, previousItem); - } - return lineAdded; - } - function insertIndentation(pos, indentation, lineAdded) { - var indentationString = getIndentationString(indentation, options); - if (lineAdded) { - // new line is added before the token by the formatting rules - // insert indentation string at the very beginning of the token - recordReplace(pos, 0, indentationString); - } - else { - var tokenStart = sourceFile.getLineAndCharacterOfPosition(pos); - if (indentation !== tokenStart.character) { - var startLinePosition = ts.getStartPositionOfLine(tokenStart.line, sourceFile); - recordReplace(startLinePosition, tokenStart.character, indentationString); - } - } - } - function indentMultilineComment(commentRange, indentation, firstLineIsIndented) { - // split comment in lines - var startLine = sourceFile.getLineAndCharacterOfPosition(commentRange.pos).line; - var endLine = sourceFile.getLineAndCharacterOfPosition(commentRange.end).line; - var parts; - if (startLine === endLine) { - if (!firstLineIsIndented) { - // treat as single line comment - insertIndentation(commentRange.pos, indentation, false); - } - return; - } - else { - parts = []; - var startPos = commentRange.pos; - for (var line = startLine; line < endLine; ++line) { - var endOfLine = ts.getEndLinePosition(line, sourceFile); - parts.push({ pos: startPos, end: endOfLine }); - startPos = ts.getStartPositionOfLine(line + 1, sourceFile); - } - parts.push({ pos: startPos, end: commentRange.end }); - } - var startLinePos = ts.getStartPositionOfLine(startLine, sourceFile); - var nonWhitespaceColumnInFirstPart = formatting.SmartIndenter.findFirstNonWhitespaceCharacterAndColumn(startLinePos, parts[0].pos, sourceFile, options); - if (indentation === nonWhitespaceColumnInFirstPart.column) { - return; - } - var startIndex = 0; - if (firstLineIsIndented) { - startIndex = 1; - startLine++; - } - // shift all parts on the delta size - var delta = indentation - nonWhitespaceColumnInFirstPart.column; - for (var i = startIndex, len = parts.length; i < len; ++i, ++startLine) { - var startLinePos_1 = ts.getStartPositionOfLine(startLine, sourceFile); - var nonWhitespaceCharacterAndColumn = i === 0 - ? nonWhitespaceColumnInFirstPart - : formatting.SmartIndenter.findFirstNonWhitespaceCharacterAndColumn(parts[i].pos, parts[i].end, sourceFile, options); - var newIndentation = nonWhitespaceCharacterAndColumn.column + delta; - if (newIndentation > 0) { - var indentationString = getIndentationString(newIndentation, options); - recordReplace(startLinePos_1, nonWhitespaceCharacterAndColumn.character, indentationString); - } - else { - recordDelete(startLinePos_1, nonWhitespaceCharacterAndColumn.character); - } - } - } - function trimTrailingWhitespacesForLines(line1, line2, range) { - for (var line = line1; line < line2; ++line) { - var lineStartPosition = ts.getStartPositionOfLine(line, sourceFile); - var lineEndPosition = ts.getEndLinePosition(line, sourceFile); - // do not trim whitespaces in comments - if (range && ts.isComment(range.kind) && range.pos <= lineEndPosition && range.end > lineEndPosition) { - continue; - } - var pos = lineEndPosition; - while (pos >= lineStartPosition && ts.isWhiteSpace(sourceFile.text.charCodeAt(pos))) { - pos--; - } - if (pos !== lineEndPosition) { - ts.Debug.assert(pos === lineStartPosition || !ts.isWhiteSpace(sourceFile.text.charCodeAt(pos))); - recordDelete(pos + 1, lineEndPosition - pos); - } - } - } - function newTextChange(start, len, newText) { - return { span: ts.createTextSpan(start, len), newText: newText }; - } - function recordDelete(start, len) { - if (len) { - edits.push(newTextChange(start, len, "")); - } - } - function recordReplace(start, len, newText) { - if (len || newText) { - edits.push(newTextChange(start, len, newText)); - } - } - function applyRuleEdits(rule, previousRange, previousStartLine, currentRange, currentStartLine) { - var between; - switch (rule.Operation.Action) { - case 1 /* Ignore */: - // no action required - return; - case 8 /* Delete */: - if (previousRange.end !== currentRange.pos) { - // delete characters starting from t1.end up to t2.pos exclusive - recordDelete(previousRange.end, currentRange.pos - previousRange.end); - } - break; - case 4 /* NewLine */: - // exit early if we on different lines and rule cannot change number of newlines - // if line1 and line2 are on subsequent lines then no edits are required - ok to exit - // if line1 and line2 are separated with more than one newline - ok to exit since we cannot delete extra new lines - if (rule.Flag !== 1 /* CanDeleteNewLines */ && previousStartLine !== currentStartLine) { - return; - } - // edit should not be applied only if we have one line feed between elements - var lineDelta = currentStartLine - previousStartLine; - if (lineDelta !== 1) { - recordReplace(previousRange.end, currentRange.pos - previousRange.end, options.NewLineCharacter); - } - break; - case 2 /* Space */: - // exit early if we on different lines and rule cannot change number of newlines - if (rule.Flag !== 1 /* CanDeleteNewLines */ && previousStartLine !== currentStartLine) { - return; - } - var posDelta = currentRange.pos - previousRange.end; - if (posDelta !== 1 || sourceFile.text.charCodeAt(previousRange.end) !== 32 /* space */) { - recordReplace(previousRange.end, currentRange.pos - previousRange.end, " "); - } - break; - } - } - } - function isSomeBlock(kind) { - switch (kind) { - case 182 /* Block */: - case 209 /* ModuleBlock */: - return true; - } - return false; - } - function getOpenTokenForList(node, list) { - switch (node.kind) { - case 137 /* Constructor */: - case 203 /* FunctionDeclaration */: - case 165 /* FunctionExpression */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 166 /* ArrowFunction */: - if (node.typeParameters === list) { - return 24 /* LessThanToken */; - } - else if (node.parameters === list) { - return 16 /* OpenParenToken */; - } - break; - case 160 /* CallExpression */: - case 161 /* NewExpression */: - if (node.typeArguments === list) { - return 24 /* LessThanToken */; - } - else if (node.arguments === list) { - return 16 /* OpenParenToken */; - } - break; - case 144 /* TypeReference */: - if (node.typeArguments === list) { - return 24 /* LessThanToken */; - } - } - return 0 /* Unknown */; - } - function getCloseTokenForOpenToken(kind) { - switch (kind) { - case 16 /* OpenParenToken */: - return 17 /* CloseParenToken */; - case 24 /* LessThanToken */: - return 25 /* GreaterThanToken */; - } - return 0 /* Unknown */; - } - var internedSizes; - var internedTabsIndentation; - var internedSpacesIndentation; - function getIndentationString(indentation, options) { - // reset interned strings if FormatCodeOptions were changed - var resetInternedStrings = !internedSizes || (internedSizes.tabSize !== options.TabSize || internedSizes.indentSize !== options.IndentSize); - if (resetInternedStrings) { - internedSizes = { tabSize: options.TabSize, indentSize: options.IndentSize }; - internedTabsIndentation = internedSpacesIndentation = undefined; - } - if (!options.ConvertTabsToSpaces) { - var tabs = Math.floor(indentation / options.TabSize); - var spaces = indentation - tabs * options.TabSize; - var tabString; - if (!internedTabsIndentation) { - internedTabsIndentation = []; - } - if (internedTabsIndentation[tabs] === undefined) { - internedTabsIndentation[tabs] = tabString = repeat('\t', tabs); - } - else { - tabString = internedTabsIndentation[tabs]; - } - return spaces ? tabString + repeat(" ", spaces) : tabString; - } - else { - var spacesString; - var quotient = Math.floor(indentation / options.IndentSize); - var remainder = indentation % options.IndentSize; - if (!internedSpacesIndentation) { - internedSpacesIndentation = []; - } - if (internedSpacesIndentation[quotient] === undefined) { - spacesString = repeat(" ", options.IndentSize * quotient); - internedSpacesIndentation[quotient] = spacesString; - } - else { - spacesString = internedSpacesIndentation[quotient]; - } - return remainder ? spacesString + repeat(" ", remainder) : spacesString; - } - function repeat(value, count) { - var s = ""; - for (var i = 0; i < count; ++i) { - s += value; - } - return s; - } - } - formatting.getIndentationString = getIndentationString; - })(formatting = ts.formatting || (ts.formatting = {})); -})(ts || (ts = {})); -/// -/* @internal */ -var ts; -(function (ts) { - var formatting; - (function (formatting) { - var SmartIndenter; - (function (SmartIndenter) { - var Value; - (function (Value) { - Value[Value["Unknown"] = -1] = "Unknown"; - })(Value || (Value = {})); - function getIndentation(position, sourceFile, options) { - if (position > sourceFile.text.length) { - return 0; // past EOF - } - var precedingToken = ts.findPrecedingToken(position, sourceFile); - if (!precedingToken) { - return 0; - } - // no indentation in string \regex\template literals - var precedingTokenIsLiteral = precedingToken.kind === 8 /* StringLiteral */ || - precedingToken.kind === 9 /* RegularExpressionLiteral */ || - precedingToken.kind === 10 /* NoSubstitutionTemplateLiteral */ || - precedingToken.kind === 11 /* TemplateHead */ || - precedingToken.kind === 12 /* TemplateMiddle */ || - precedingToken.kind === 13 /* TemplateTail */; - if (precedingTokenIsLiteral && precedingToken.getStart(sourceFile) <= position && precedingToken.end > position) { - return 0; - } - var lineAtPosition = sourceFile.getLineAndCharacterOfPosition(position).line; - if (precedingToken.kind === 23 /* CommaToken */ && precedingToken.parent.kind !== 172 /* BinaryExpression */) { - // previous token is comma that separates items in list - find the previous item and try to derive indentation from it - var actualIndentation = getActualIndentationForListItemBeforeComma(precedingToken, sourceFile, options); - if (actualIndentation !== -1 /* Unknown */) { - return actualIndentation; - } - } - // try to find node that can contribute to indentation and includes 'position' starting from 'precedingToken' - // if such node is found - compute initial indentation for 'position' inside this node - var previous; - var current = precedingToken; - var currentStart; - var indentationDelta; - while (current) { - if (ts.positionBelongsToNode(current, position, sourceFile) && shouldIndentChildNode(current.kind, previous ? previous.kind : 0 /* Unknown */)) { - currentStart = getStartLineAndCharacterForNode(current, sourceFile); - if (nextTokenIsCurlyBraceOnSameLineAsCursor(precedingToken, current, lineAtPosition, sourceFile)) { - indentationDelta = 0; - } - else { - indentationDelta = lineAtPosition !== currentStart.line ? options.IndentSize : 0; - } - break; - } - // check if current node is a list item - if yes, take indentation from it - var actualIndentation = getActualIndentationForListItem(current, sourceFile, options); - if (actualIndentation !== -1 /* Unknown */) { - return actualIndentation; - } - previous = current; - current = current.parent; - } - if (!current) { - // no parent was found - return 0 to be indented on the level of SourceFile - return 0; - } - return getIndentationForNodeWorker(current, currentStart, undefined, indentationDelta, sourceFile, options); - } - SmartIndenter.getIndentation = getIndentation; - function getIndentationForNode(n, ignoreActualIndentationRange, sourceFile, options) { - var start = sourceFile.getLineAndCharacterOfPosition(n.getStart(sourceFile)); - return getIndentationForNodeWorker(n, start, ignoreActualIndentationRange, 0, sourceFile, options); - } - SmartIndenter.getIndentationForNode = getIndentationForNode; - function getIndentationForNodeWorker(current, currentStart, ignoreActualIndentationRange, indentationDelta, sourceFile, options) { - var parent = current.parent; - var parentStart; - // walk upwards and collect indentations for pairs of parent-child nodes - // indentation is not added if parent and child nodes start on the same line or if parent is IfStatement and child starts on the same line with 'else clause' - while (parent) { - var useActualIndentation = true; - if (ignoreActualIndentationRange) { - var start = current.getStart(sourceFile); - useActualIndentation = start < ignoreActualIndentationRange.pos || start > ignoreActualIndentationRange.end; - } - if (useActualIndentation) { - // check if current node is a list item - if yes, take indentation from it - var actualIndentation = getActualIndentationForListItem(current, sourceFile, options); - if (actualIndentation !== -1 /* Unknown */) { - return actualIndentation + indentationDelta; - } - } - parentStart = getParentStart(parent, current, sourceFile); - var parentAndChildShareLine = parentStart.line === currentStart.line || - childStartsOnTheSameLineWithElseInIfStatement(parent, current, currentStart.line, sourceFile); - if (useActualIndentation) { - // try to fetch actual indentation for current node from source text - var actualIndentation = getActualIndentationForNode(current, parent, currentStart, parentAndChildShareLine, sourceFile, options); - if (actualIndentation !== -1 /* Unknown */) { - return actualIndentation + indentationDelta; - } - } - // increase indentation if parent node wants its content to be indented and parent and child nodes don't start on the same line - if (shouldIndentChildNode(parent.kind, current.kind) && !parentAndChildShareLine) { - indentationDelta += options.IndentSize; - } - current = parent; - currentStart = parentStart; - parent = current.parent; - } - return indentationDelta; - } - function getParentStart(parent, child, sourceFile) { - var containingList = getContainingList(child, sourceFile); - if (containingList) { - return sourceFile.getLineAndCharacterOfPosition(containingList.pos); - } - return sourceFile.getLineAndCharacterOfPosition(parent.getStart(sourceFile)); - } - /* - * Function returns Value.Unknown if indentation cannot be determined - */ - function getActualIndentationForListItemBeforeComma(commaToken, sourceFile, options) { - // previous token is comma that separates items in list - find the previous item and try to derive indentation from it - var commaItemInfo = ts.findListItemInfo(commaToken); - if (commaItemInfo && commaItemInfo.listItemIndex > 0) { - return deriveActualIndentationFromList(commaItemInfo.list.getChildren(), commaItemInfo.listItemIndex - 1, sourceFile, options); - } - else { - // handle broken code gracefully - return -1 /* Unknown */; - } - } - /* - * Function returns Value.Unknown if actual indentation for node should not be used (i.e because node is nested expression) - */ - function getActualIndentationForNode(current, parent, currentLineAndChar, parentAndChildShareLine, sourceFile, options) { - // actual indentation is used for statements\declarations if one of cases below is true: - // - parent is SourceFile - by default immediate children of SourceFile are not indented except when user indents them manually - // - parent and child are not on the same line - var useActualIndentation = (ts.isDeclaration(current) || ts.isStatement(current)) && - (parent.kind === 230 /* SourceFile */ || !parentAndChildShareLine); - if (!useActualIndentation) { - return -1 /* Unknown */; - } - return findColumnForFirstNonWhitespaceCharacterInLine(currentLineAndChar, sourceFile, options); - } - function nextTokenIsCurlyBraceOnSameLineAsCursor(precedingToken, current, lineAtPosition, sourceFile) { - var nextToken = ts.findNextToken(precedingToken, current); - if (!nextToken) { - return false; - } - if (nextToken.kind === 14 /* OpenBraceToken */) { - // open braces are always indented at the parent level - return true; - } - else if (nextToken.kind === 15 /* CloseBraceToken */) { - // close braces are indented at the parent level if they are located on the same line with cursor - // this means that if new line will be added at $ position, this case will be indented - // class A { - // $ - // } - /// and this one - not - // class A { - // $} - var nextTokenStartLine = getStartLineAndCharacterForNode(nextToken, sourceFile).line; - return lineAtPosition === nextTokenStartLine; - } - return false; - } - function getStartLineAndCharacterForNode(n, sourceFile) { - return sourceFile.getLineAndCharacterOfPosition(n.getStart(sourceFile)); - } - function childStartsOnTheSameLineWithElseInIfStatement(parent, child, childStartLine, sourceFile) { - if (parent.kind === 186 /* IfStatement */ && parent.elseStatement === child) { - var elseKeyword = ts.findChildOfKind(parent, 76 /* ElseKeyword */, sourceFile); - ts.Debug.assert(elseKeyword !== undefined); - var elseKeywordStartLine = getStartLineAndCharacterForNode(elseKeyword, sourceFile).line; - return elseKeywordStartLine === childStartLine; - } - return false; - } - SmartIndenter.childStartsOnTheSameLineWithElseInIfStatement = childStartsOnTheSameLineWithElseInIfStatement; - function getContainingList(node, sourceFile) { - if (node.parent) { - switch (node.parent.kind) { - case 144 /* TypeReference */: - if (node.parent.typeArguments && - ts.rangeContainsStartEnd(node.parent.typeArguments, node.getStart(sourceFile), node.getEnd())) { - return node.parent.typeArguments; - } - break; - case 157 /* ObjectLiteralExpression */: - return node.parent.properties; - case 156 /* ArrayLiteralExpression */: - return node.parent.elements; - case 203 /* FunctionDeclaration */: - case 165 /* FunctionExpression */: - case 166 /* ArrowFunction */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 140 /* CallSignature */: - case 141 /* ConstructSignature */: { - var start = node.getStart(sourceFile); - if (node.parent.typeParameters && - ts.rangeContainsStartEnd(node.parent.typeParameters, start, node.getEnd())) { - return node.parent.typeParameters; - } - if (ts.rangeContainsStartEnd(node.parent.parameters, start, node.getEnd())) { - return node.parent.parameters; - } - break; - } - case 161 /* NewExpression */: - case 160 /* CallExpression */: { - var start = node.getStart(sourceFile); - if (node.parent.typeArguments && - ts.rangeContainsStartEnd(node.parent.typeArguments, start, node.getEnd())) { - return node.parent.typeArguments; - } - if (node.parent.arguments && - ts.rangeContainsStartEnd(node.parent.arguments, start, node.getEnd())) { - return node.parent.arguments; - } - break; - } - } - } - return undefined; - } - function getActualIndentationForListItem(node, sourceFile, options) { - var containingList = getContainingList(node, sourceFile); - return containingList ? getActualIndentationFromList(containingList) : -1 /* Unknown */; - function getActualIndentationFromList(list) { - var index = ts.indexOf(list, node); - return index !== -1 ? deriveActualIndentationFromList(list, index, sourceFile, options) : -1 /* Unknown */; - } - } - function deriveActualIndentationFromList(list, index, sourceFile, options) { - ts.Debug.assert(index >= 0 && index < list.length); - var node = list[index]; - // walk toward the start of the list starting from current node and check if the line is the same for all items. - // if end line for item [i - 1] differs from the start line for item [i] - find column of the first non-whitespace character on the line of item [i] - var lineAndCharacter = getStartLineAndCharacterForNode(node, sourceFile); - for (var i = index - 1; i >= 0; --i) { - if (list[i].kind === 23 /* CommaToken */) { - continue; - } - // skip list items that ends on the same line with the current list element - var prevEndLine = sourceFile.getLineAndCharacterOfPosition(list[i].end).line; - if (prevEndLine !== lineAndCharacter.line) { - return findColumnForFirstNonWhitespaceCharacterInLine(lineAndCharacter, sourceFile, options); - } - lineAndCharacter = getStartLineAndCharacterForNode(list[i], sourceFile); - } - return -1 /* Unknown */; - } - function findColumnForFirstNonWhitespaceCharacterInLine(lineAndCharacter, sourceFile, options) { - var lineStart = sourceFile.getPositionOfLineAndCharacter(lineAndCharacter.line, 0); - return findFirstNonWhitespaceColumn(lineStart, lineStart + lineAndCharacter.character, sourceFile, options); - } - /* - Character is the actual index of the character since the beginning of the line. - Column - position of the character after expanding tabs to spaces - "0\t2$" - value of 'character' for '$' is 3 - value of 'column' for '$' is 6 (assuming that tab size is 4) - */ - function findFirstNonWhitespaceCharacterAndColumn(startPos, endPos, sourceFile, options) { - var character = 0; - var column = 0; - for (var pos = startPos; pos < endPos; ++pos) { - var ch = sourceFile.text.charCodeAt(pos); - if (!ts.isWhiteSpace(ch)) { - break; - } - if (ch === 9 /* tab */) { - column += options.TabSize + (column % options.TabSize); - } - else { - column++; - } - character++; - } - return { column: column, character: character }; - } - SmartIndenter.findFirstNonWhitespaceCharacterAndColumn = findFirstNonWhitespaceCharacterAndColumn; - function findFirstNonWhitespaceColumn(startPos, endPos, sourceFile, options) { - return findFirstNonWhitespaceCharacterAndColumn(startPos, endPos, sourceFile, options).column; - } - SmartIndenter.findFirstNonWhitespaceColumn = findFirstNonWhitespaceColumn; - function nodeContentIsAlwaysIndented(kind) { - switch (kind) { - case 204 /* ClassDeclaration */: - case 205 /* InterfaceDeclaration */: - case 207 /* EnumDeclaration */: - case 156 /* ArrayLiteralExpression */: - case 182 /* Block */: - case 209 /* ModuleBlock */: - case 157 /* ObjectLiteralExpression */: - case 148 /* TypeLiteral */: - case 150 /* TupleType */: - case 210 /* CaseBlock */: - case 224 /* DefaultClause */: - case 223 /* CaseClause */: - case 164 /* ParenthesizedExpression */: - case 160 /* CallExpression */: - case 161 /* NewExpression */: - case 183 /* VariableStatement */: - case 201 /* VariableDeclaration */: - case 217 /* ExportAssignment */: - case 194 /* ReturnStatement */: - case 173 /* ConditionalExpression */: - case 154 /* ArrayBindingPattern */: - case 153 /* ObjectBindingPattern */: - return true; - } - return false; - } - function shouldIndentChildNode(parent, child) { - if (nodeContentIsAlwaysIndented(parent)) { - return true; - } - switch (parent) { - case 187 /* DoStatement */: - case 188 /* WhileStatement */: - case 190 /* ForInStatement */: - case 191 /* ForOfStatement */: - case 189 /* ForStatement */: - case 186 /* IfStatement */: - case 203 /* FunctionDeclaration */: - case 165 /* FunctionExpression */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 140 /* CallSignature */: - case 166 /* ArrowFunction */: - case 137 /* Constructor */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - return child !== 182 /* Block */; - default: - return false; - } - } - SmartIndenter.shouldIndentChildNode = shouldIndentChildNode; - })(SmartIndenter = formatting.SmartIndenter || (formatting.SmartIndenter = {})); - })(formatting = ts.formatting || (ts.formatting = {})); -})(ts || (ts = {})); -/// -var __extends = (this && this.__extends) || function (d, b) { - for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; - function __() { this.constructor = d; } - __.prototype = b.prototype; - d.prototype = new __(); -}; -/// -/// -/// -/// -/// -/// -/// -/// -/// -var ts; -(function (ts) { - /** The version of the language service API */ - ts.servicesVersion = "0.4"; - var ScriptSnapshot; - (function (ScriptSnapshot) { - var StringScriptSnapshot = (function () { - function StringScriptSnapshot(text) { - this.text = text; - this._lineStartPositions = undefined; - } - StringScriptSnapshot.prototype.getText = function (start, end) { - return this.text.substring(start, end); - }; - StringScriptSnapshot.prototype.getLength = function () { - return this.text.length; - }; - StringScriptSnapshot.prototype.getChangeRange = function (oldSnapshot) { - // Text-based snapshots do not support incremental parsing. Return undefined - // to signal that to the caller. - return undefined; - }; - return StringScriptSnapshot; - })(); - function fromString(text) { - return new StringScriptSnapshot(text); - } - ScriptSnapshot.fromString = fromString; - })(ScriptSnapshot = ts.ScriptSnapshot || (ts.ScriptSnapshot = {})); - var scanner = ts.createScanner(2 /* Latest */, true); - var emptyArray = []; - function createNode(kind, pos, end, flags, parent) { - var node = new (ts.getNodeConstructor(kind))(); - node.pos = pos; - node.end = end; - node.flags = flags; - node.parent = parent; - return node; - } - var NodeObject = (function () { - function NodeObject() { - } - NodeObject.prototype.getSourceFile = function () { - return ts.getSourceFileOfNode(this); - }; - NodeObject.prototype.getStart = function (sourceFile) { - return ts.getTokenPosOfNode(this, sourceFile); - }; - NodeObject.prototype.getFullStart = function () { - return this.pos; - }; - NodeObject.prototype.getEnd = function () { - return this.end; - }; - NodeObject.prototype.getWidth = function (sourceFile) { - return this.getEnd() - this.getStart(sourceFile); - }; - NodeObject.prototype.getFullWidth = function () { - return this.end - this.getFullStart(); - }; - NodeObject.prototype.getLeadingTriviaWidth = function (sourceFile) { - return this.getStart(sourceFile) - this.pos; - }; - NodeObject.prototype.getFullText = function (sourceFile) { - return (sourceFile || this.getSourceFile()).text.substring(this.pos, this.end); - }; - NodeObject.prototype.getText = function (sourceFile) { - return (sourceFile || this.getSourceFile()).text.substring(this.getStart(), this.getEnd()); - }; - NodeObject.prototype.addSyntheticNodes = function (nodes, pos, end) { - scanner.setTextPos(pos); - while (pos < end) { - var token = scanner.scan(); - var textPos = scanner.getTextPos(); - nodes.push(createNode(token, pos, textPos, 1024 /* Synthetic */, this)); - pos = textPos; - } - return pos; - }; - NodeObject.prototype.createSyntaxList = function (nodes) { - var list = createNode(253 /* SyntaxList */, nodes.pos, nodes.end, 1024 /* Synthetic */, this); - list._children = []; - var pos = nodes.pos; - for (var _i = 0; _i < nodes.length; _i++) { - var node = nodes[_i]; - if (pos < node.pos) { - pos = this.addSyntheticNodes(list._children, pos, node.pos); - } - list._children.push(node); - pos = node.end; - } - if (pos < nodes.end) { - this.addSyntheticNodes(list._children, pos, nodes.end); - } - return list; - }; - NodeObject.prototype.createChildren = function (sourceFile) { - var _this = this; - var children; - if (this.kind >= 128 /* FirstNode */) { - scanner.setText((sourceFile || this.getSourceFile()).text); - children = []; - var pos = this.pos; - var processNode = function (node) { - if (pos < node.pos) { - pos = _this.addSyntheticNodes(children, pos, node.pos); - } - children.push(node); - pos = node.end; - }; - var processNodes = function (nodes) { - if (pos < nodes.pos) { - pos = _this.addSyntheticNodes(children, pos, nodes.pos); - } - children.push(_this.createSyntaxList(nodes)); - pos = nodes.end; - }; - ts.forEachChild(this, processNode, processNodes); - if (pos < this.end) { - this.addSyntheticNodes(children, pos, this.end); - } - scanner.setText(undefined); - } - this._children = children || emptyArray; - }; - NodeObject.prototype.getChildCount = function (sourceFile) { - if (!this._children) - this.createChildren(sourceFile); - return this._children.length; - }; - NodeObject.prototype.getChildAt = function (index, sourceFile) { - if (!this._children) - this.createChildren(sourceFile); - return this._children[index]; - }; - NodeObject.prototype.getChildren = function (sourceFile) { - if (!this._children) - this.createChildren(sourceFile); - return this._children; - }; - NodeObject.prototype.getFirstToken = function (sourceFile) { - var children = this.getChildren(); - for (var _i = 0; _i < children.length; _i++) { - var child = children[_i]; - if (child.kind < 128 /* FirstNode */) { - return child; - } - return child.getFirstToken(sourceFile); - } - }; - NodeObject.prototype.getLastToken = function (sourceFile) { - var children = this.getChildren(sourceFile); - for (var i = children.length - 1; i >= 0; i--) { - var child = children[i]; - if (child.kind < 128 /* FirstNode */) { - return child; - } - return child.getLastToken(sourceFile); - } - }; - return NodeObject; - })(); - var SymbolObject = (function () { - function SymbolObject(flags, name) { - this.flags = flags; - this.name = name; - } - SymbolObject.prototype.getFlags = function () { - return this.flags; - }; - SymbolObject.prototype.getName = function () { - return this.name; - }; - SymbolObject.prototype.getDeclarations = function () { - return this.declarations; - }; - SymbolObject.prototype.getDocumentationComment = function () { - if (this.documentationComment === undefined) { - this.documentationComment = getJsDocCommentsFromDeclarations(this.declarations, this.name, !(this.flags & 4 /* Property */)); - } - return this.documentationComment; - }; - return SymbolObject; - })(); - function getJsDocCommentsFromDeclarations(declarations, name, canUseParsedParamTagComments) { - var documentationComment = []; - var docComments = getJsDocCommentsSeparatedByNewLines(); - ts.forEach(docComments, function (docComment) { - if (documentationComment.length) { - documentationComment.push(ts.lineBreakPart()); - } - documentationComment.push(docComment); - }); - return documentationComment; - function getJsDocCommentsSeparatedByNewLines() { - var paramTag = "@param"; - var jsDocCommentParts = []; - ts.forEach(declarations, function (declaration, indexOfDeclaration) { - // Make sure we are collecting doc comment from declaration once, - // In case of union property there might be same declaration multiple times - // which only varies in type parameter - // Eg. let a: Array | Array; a.length - // The property length will have two declarations of property length coming - // from Array - Array and Array - if (ts.indexOf(declarations, declaration) === indexOfDeclaration) { - var sourceFileOfDeclaration = ts.getSourceFileOfNode(declaration); - // If it is parameter - try and get the jsDoc comment with @param tag from function declaration's jsDoc comments - if (canUseParsedParamTagComments && declaration.kind === 131 /* Parameter */) { - ts.forEach(getJsDocCommentTextRange(declaration.parent, sourceFileOfDeclaration), function (jsDocCommentTextRange) { - var cleanedParamJsDocComment = getCleanedParamJsDocComment(jsDocCommentTextRange.pos, jsDocCommentTextRange.end, sourceFileOfDeclaration); - if (cleanedParamJsDocComment) { - jsDocCommentParts.push.apply(jsDocCommentParts, cleanedParamJsDocComment); - } - }); - } - // If this is left side of dotted module declaration, there is no doc comments associated with this node - if (declaration.kind === 208 /* ModuleDeclaration */ && declaration.body.kind === 208 /* ModuleDeclaration */) { - return; - } - // If this is dotted module name, get the doc comments from the parent - while (declaration.kind === 208 /* ModuleDeclaration */ && declaration.parent.kind === 208 /* ModuleDeclaration */) { - declaration = declaration.parent; - } - // Get the cleaned js doc comment text from the declaration - ts.forEach(getJsDocCommentTextRange(declaration.kind === 201 /* VariableDeclaration */ ? declaration.parent.parent : declaration, sourceFileOfDeclaration), function (jsDocCommentTextRange) { - var cleanedJsDocComment = getCleanedJsDocComment(jsDocCommentTextRange.pos, jsDocCommentTextRange.end, sourceFileOfDeclaration); - if (cleanedJsDocComment) { - jsDocCommentParts.push.apply(jsDocCommentParts, cleanedJsDocComment); - } - }); - } - }); - return jsDocCommentParts; - function getJsDocCommentTextRange(node, sourceFile) { - return ts.map(ts.getJsDocComments(node, sourceFile), function (jsDocComment) { - return { - pos: jsDocComment.pos + "/*".length, - end: jsDocComment.end - "*/".length // Trim off comment end indicator - }; - }); - } - function consumeWhiteSpacesOnTheLine(pos, end, sourceFile, maxSpacesToRemove) { - if (maxSpacesToRemove !== undefined) { - end = Math.min(end, pos + maxSpacesToRemove); - } - for (; pos < end; pos++) { - var ch = sourceFile.text.charCodeAt(pos); - if (!ts.isWhiteSpace(ch) || ts.isLineBreak(ch)) { - // Either found lineBreak or non whiteSpace - return pos; - } - } - return end; - } - function consumeLineBreaks(pos, end, sourceFile) { - while (pos < end && ts.isLineBreak(sourceFile.text.charCodeAt(pos))) { - pos++; - } - return pos; - } - function isName(pos, end, sourceFile, name) { - return pos + name.length < end && - sourceFile.text.substr(pos, name.length) === name && - (ts.isWhiteSpace(sourceFile.text.charCodeAt(pos + name.length)) || - ts.isLineBreak(sourceFile.text.charCodeAt(pos + name.length))); - } - function isParamTag(pos, end, sourceFile) { - // If it is @param tag - return isName(pos, end, sourceFile, paramTag); - } - function pushDocCommentLineText(docComments, text, blankLineCount) { - // Add the empty lines in between texts - while (blankLineCount--) { - docComments.push(ts.textPart("")); - } - docComments.push(ts.textPart(text)); - } - function getCleanedJsDocComment(pos, end, sourceFile) { - var spacesToRemoveAfterAsterisk; - var docComments = []; - var blankLineCount = 0; - var isInParamTag = false; - while (pos < end) { - var docCommentTextOfLine = ""; - // First consume leading white space - pos = consumeWhiteSpacesOnTheLine(pos, end, sourceFile); - // If the comment starts with '*' consume the spaces on this line - if (pos < end && sourceFile.text.charCodeAt(pos) === 42 /* asterisk */) { - var lineStartPos = pos + 1; - pos = consumeWhiteSpacesOnTheLine(pos + 1, end, sourceFile, spacesToRemoveAfterAsterisk); - // Set the spaces to remove after asterisk as margin if not already set - if (spacesToRemoveAfterAsterisk === undefined && pos < end && !ts.isLineBreak(sourceFile.text.charCodeAt(pos))) { - spacesToRemoveAfterAsterisk = pos - lineStartPos; - } - } - else if (spacesToRemoveAfterAsterisk === undefined) { - spacesToRemoveAfterAsterisk = 0; - } - // Analyse text on this line - while (pos < end && !ts.isLineBreak(sourceFile.text.charCodeAt(pos))) { - var ch = sourceFile.text.charAt(pos); - if (ch === "@") { - // If it is @param tag - if (isParamTag(pos, end, sourceFile)) { - isInParamTag = true; - pos += paramTag.length; - continue; - } - else { - isInParamTag = false; - } - } - // Add the ch to doc text if we arent in param tag - if (!isInParamTag) { - docCommentTextOfLine += ch; - } - // Scan next character - pos++; - } - // Continue with next line - pos = consumeLineBreaks(pos, end, sourceFile); - if (docCommentTextOfLine) { - pushDocCommentLineText(docComments, docCommentTextOfLine, blankLineCount); - blankLineCount = 0; - } - else if (!isInParamTag && docComments.length) { - // This is blank line when there is text already parsed - blankLineCount++; - } - } - return docComments; - } - function getCleanedParamJsDocComment(pos, end, sourceFile) { - var paramHelpStringMargin; - var paramDocComments = []; - while (pos < end) { - if (isParamTag(pos, end, sourceFile)) { - var blankLineCount = 0; - var recordedParamTag = false; - // Consume leading spaces - pos = consumeWhiteSpaces(pos + paramTag.length); - if (pos >= end) { - break; - } - // Ignore type expression - if (sourceFile.text.charCodeAt(pos) === 123 /* openBrace */) { - pos++; - for (var curlies = 1; pos < end; pos++) { - var charCode = sourceFile.text.charCodeAt(pos); - // { character means we need to find another } to match the found one - if (charCode === 123 /* openBrace */) { - curlies++; - continue; - } - // } char - if (charCode === 125 /* closeBrace */) { - curlies--; - if (curlies === 0) { - // We do not have any more } to match the type expression is ignored completely - pos++; - break; - } - else { - // there are more { to be matched with } - continue; - } - } - // Found start of another tag - if (charCode === 64 /* at */) { - break; - } - } - // Consume white spaces - pos = consumeWhiteSpaces(pos); - if (pos >= end) { - break; - } - } - // Parameter name - if (isName(pos, end, sourceFile, name)) { - // Found the parameter we are looking for consume white spaces - pos = consumeWhiteSpaces(pos + name.length); - if (pos >= end) { - break; - } - var paramHelpString = ""; - var firstLineParamHelpStringPos = pos; - while (pos < end) { - var ch = sourceFile.text.charCodeAt(pos); - // at line break, set this comment line text and go to next line - if (ts.isLineBreak(ch)) { - if (paramHelpString) { - pushDocCommentLineText(paramDocComments, paramHelpString, blankLineCount); - paramHelpString = ""; - blankLineCount = 0; - recordedParamTag = true; - } - else if (recordedParamTag) { - blankLineCount++; - } - // Get the pos after cleaning start of the line - setPosForParamHelpStringOnNextLine(firstLineParamHelpStringPos); - continue; - } - // Done scanning param help string - next tag found - if (ch === 64 /* at */) { - break; - } - paramHelpString += sourceFile.text.charAt(pos); - // Go to next character - pos++; - } - // If there is param help text, add it top the doc comments - if (paramHelpString) { - pushDocCommentLineText(paramDocComments, paramHelpString, blankLineCount); - } - paramHelpStringMargin = undefined; - } - // If this is the start of another tag, continue with the loop in seach of param tag with symbol name - if (sourceFile.text.charCodeAt(pos) === 64 /* at */) { - continue; - } - } - // Next character - pos++; - } - return paramDocComments; - function consumeWhiteSpaces(pos) { - while (pos < end && ts.isWhiteSpace(sourceFile.text.charCodeAt(pos))) { - pos++; - } - return pos; - } - function setPosForParamHelpStringOnNextLine(firstLineParamHelpStringPos) { - // Get the pos after consuming line breaks - pos = consumeLineBreaks(pos, end, sourceFile); - if (pos >= end) { - return; - } - if (paramHelpStringMargin === undefined) { - paramHelpStringMargin = sourceFile.getLineAndCharacterOfPosition(firstLineParamHelpStringPos).character; - } - // Now consume white spaces max - var startOfLinePos = pos; - pos = consumeWhiteSpacesOnTheLine(pos, end, sourceFile, paramHelpStringMargin); - if (pos >= end) { - return; - } - var consumedSpaces = pos - startOfLinePos; - if (consumedSpaces < paramHelpStringMargin) { - var ch = sourceFile.text.charCodeAt(pos); - if (ch === 42 /* asterisk */) { - // Consume more spaces after asterisk - pos = consumeWhiteSpacesOnTheLine(pos + 1, end, sourceFile, paramHelpStringMargin - consumedSpaces - 1); - } - } - } - } - } - } - var TypeObject = (function () { - function TypeObject(checker, flags) { - this.checker = checker; - this.flags = flags; - } - TypeObject.prototype.getFlags = function () { - return this.flags; - }; - TypeObject.prototype.getSymbol = function () { - return this.symbol; - }; - TypeObject.prototype.getProperties = function () { - return this.checker.getPropertiesOfType(this); - }; - TypeObject.prototype.getProperty = function (propertyName) { - return this.checker.getPropertyOfType(this, propertyName); - }; - TypeObject.prototype.getApparentProperties = function () { - return this.checker.getAugmentedPropertiesOfType(this); - }; - TypeObject.prototype.getCallSignatures = function () { - return this.checker.getSignaturesOfType(this, 0 /* Call */); - }; - TypeObject.prototype.getConstructSignatures = function () { - return this.checker.getSignaturesOfType(this, 1 /* Construct */); - }; - TypeObject.prototype.getStringIndexType = function () { - return this.checker.getIndexTypeOfType(this, 0 /* String */); - }; - TypeObject.prototype.getNumberIndexType = function () { - return this.checker.getIndexTypeOfType(this, 1 /* Number */); - }; - return TypeObject; - })(); - var SignatureObject = (function () { - function SignatureObject(checker) { - this.checker = checker; - } - SignatureObject.prototype.getDeclaration = function () { - return this.declaration; - }; - SignatureObject.prototype.getTypeParameters = function () { - return this.typeParameters; - }; - SignatureObject.prototype.getParameters = function () { - return this.parameters; - }; - SignatureObject.prototype.getReturnType = function () { - return this.checker.getReturnTypeOfSignature(this); - }; - SignatureObject.prototype.getDocumentationComment = function () { - if (this.documentationComment === undefined) { - this.documentationComment = this.declaration ? getJsDocCommentsFromDeclarations([this.declaration], - /*name*/ undefined, - /*canUseParsedParamTagComments*/ false) : []; - } - return this.documentationComment; - }; - return SignatureObject; - })(); - var SourceFileObject = (function (_super) { - __extends(SourceFileObject, _super); - function SourceFileObject() { - _super.apply(this, arguments); - } - SourceFileObject.prototype.update = function (newText, textChangeRange) { - return ts.updateSourceFile(this, newText, textChangeRange); - }; - SourceFileObject.prototype.getLineAndCharacterOfPosition = function (position) { - return ts.getLineAndCharacterOfPosition(this, position); - }; - SourceFileObject.prototype.getLineStarts = function () { - return ts.getLineStarts(this); - }; - SourceFileObject.prototype.getPositionOfLineAndCharacter = function (line, character) { - return ts.getPositionOfLineAndCharacter(this, line, character); - }; - SourceFileObject.prototype.getNamedDeclarations = function () { - if (!this.namedDeclarations) { - this.namedDeclarations = this.computeNamedDeclarations(); - } - return this.namedDeclarations; - }; - SourceFileObject.prototype.computeNamedDeclarations = function () { - var result = {}; - ts.forEachChild(this, visit); - return result; - function addDeclaration(declaration) { - var name = getDeclarationName(declaration); - if (name) { - var declarations = getDeclarations(name); - declarations.push(declaration); - } - } - function getDeclarations(name) { - return ts.getProperty(result, name) || (result[name] = []); - } - function getDeclarationName(declaration) { - if (declaration.name) { - var result_2 = getTextOfIdentifierOrLiteral(declaration.name); - if (result_2 !== undefined) { - return result_2; - } - if (declaration.name.kind === 129 /* ComputedPropertyName */) { - var expr = declaration.name.expression; - if (expr.kind === 158 /* PropertyAccessExpression */) { - return expr.name.text; - } - return getTextOfIdentifierOrLiteral(expr); - } - } - return undefined; - } - function getTextOfIdentifierOrLiteral(node) { - if (node) { - if (node.kind === 65 /* Identifier */ || - node.kind === 8 /* StringLiteral */ || - node.kind === 7 /* NumericLiteral */) { - return node.text; - } - } - return undefined; - } - function visit(node) { - switch (node.kind) { - case 203 /* FunctionDeclaration */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - var functionDeclaration = node; - var declarationName = getDeclarationName(functionDeclaration); - if (declarationName) { - var declarations = getDeclarations(declarationName); - var lastDeclaration = ts.lastOrUndefined(declarations); - // Check whether this declaration belongs to an "overload group". - if (lastDeclaration && functionDeclaration.parent === lastDeclaration.parent && functionDeclaration.symbol === lastDeclaration.symbol) { - // Overwrite the last declaration if it was an overload - // and this one is an implementation. - if (functionDeclaration.body && !lastDeclaration.body) { - declarations[declarations.length - 1] = functionDeclaration; - } - } - else { - declarations.push(functionDeclaration); - } - ts.forEachChild(node, visit); - } - break; - case 204 /* ClassDeclaration */: - case 205 /* InterfaceDeclaration */: - case 206 /* TypeAliasDeclaration */: - case 207 /* EnumDeclaration */: - case 208 /* ModuleDeclaration */: - case 211 /* ImportEqualsDeclaration */: - case 220 /* ExportSpecifier */: - case 216 /* ImportSpecifier */: - case 211 /* ImportEqualsDeclaration */: - case 213 /* ImportClause */: - case 214 /* NamespaceImport */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 148 /* TypeLiteral */: - addDeclaration(node); - // fall through - case 137 /* Constructor */: - case 183 /* VariableStatement */: - case 202 /* VariableDeclarationList */: - case 153 /* ObjectBindingPattern */: - case 154 /* ArrayBindingPattern */: - case 209 /* ModuleBlock */: - ts.forEachChild(node, visit); - break; - case 182 /* Block */: - if (ts.isFunctionBlock(node)) { - ts.forEachChild(node, visit); - } - break; - case 131 /* Parameter */: - // Only consider properties defined as constructor parameters - if (!(node.flags & 112 /* AccessibilityModifier */)) { - break; - } - // fall through - case 201 /* VariableDeclaration */: - case 155 /* BindingElement */: - if (ts.isBindingPattern(node.name)) { - ts.forEachChild(node.name, visit); - break; - } - case 229 /* EnumMember */: - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - addDeclaration(node); - break; - case 218 /* ExportDeclaration */: - // Handle named exports case e.g.: - // export {a, b as B} from "mod"; - if (node.exportClause) { - ts.forEach(node.exportClause.elements, visit); - } - break; - case 212 /* ImportDeclaration */: - var importClause = node.importClause; - if (importClause) { - // Handle default import case e.g.: - // import d from "mod"; - if (importClause.name) { - addDeclaration(importClause); - } - // Handle named bindings in imports e.g.: - // import * as NS from "mod"; - // import {a, b as B} from "mod"; - if (importClause.namedBindings) { - if (importClause.namedBindings.kind === 214 /* NamespaceImport */) { - addDeclaration(importClause.namedBindings); - } - else { - ts.forEach(importClause.namedBindings.elements, visit); - } - } - } - break; - } - } - }; - return SourceFileObject; - })(NodeObject); - var TextChange = (function () { - function TextChange() { - } - return TextChange; - })(); - ts.TextChange = TextChange; - var HighlightSpanKind; - (function (HighlightSpanKind) { - HighlightSpanKind.none = "none"; - HighlightSpanKind.definition = "definition"; - HighlightSpanKind.reference = "reference"; - HighlightSpanKind.writtenReference = "writtenReference"; - })(HighlightSpanKind = ts.HighlightSpanKind || (ts.HighlightSpanKind = {})); - (function (SymbolDisplayPartKind) { - SymbolDisplayPartKind[SymbolDisplayPartKind["aliasName"] = 0] = "aliasName"; - SymbolDisplayPartKind[SymbolDisplayPartKind["className"] = 1] = "className"; - SymbolDisplayPartKind[SymbolDisplayPartKind["enumName"] = 2] = "enumName"; - SymbolDisplayPartKind[SymbolDisplayPartKind["fieldName"] = 3] = "fieldName"; - SymbolDisplayPartKind[SymbolDisplayPartKind["interfaceName"] = 4] = "interfaceName"; - SymbolDisplayPartKind[SymbolDisplayPartKind["keyword"] = 5] = "keyword"; - SymbolDisplayPartKind[SymbolDisplayPartKind["lineBreak"] = 6] = "lineBreak"; - SymbolDisplayPartKind[SymbolDisplayPartKind["numericLiteral"] = 7] = "numericLiteral"; - SymbolDisplayPartKind[SymbolDisplayPartKind["stringLiteral"] = 8] = "stringLiteral"; - SymbolDisplayPartKind[SymbolDisplayPartKind["localName"] = 9] = "localName"; - SymbolDisplayPartKind[SymbolDisplayPartKind["methodName"] = 10] = "methodName"; - SymbolDisplayPartKind[SymbolDisplayPartKind["moduleName"] = 11] = "moduleName"; - SymbolDisplayPartKind[SymbolDisplayPartKind["operator"] = 12] = "operator"; - SymbolDisplayPartKind[SymbolDisplayPartKind["parameterName"] = 13] = "parameterName"; - SymbolDisplayPartKind[SymbolDisplayPartKind["propertyName"] = 14] = "propertyName"; - SymbolDisplayPartKind[SymbolDisplayPartKind["punctuation"] = 15] = "punctuation"; - SymbolDisplayPartKind[SymbolDisplayPartKind["space"] = 16] = "space"; - SymbolDisplayPartKind[SymbolDisplayPartKind["text"] = 17] = "text"; - SymbolDisplayPartKind[SymbolDisplayPartKind["typeParameterName"] = 18] = "typeParameterName"; - SymbolDisplayPartKind[SymbolDisplayPartKind["enumMemberName"] = 19] = "enumMemberName"; - SymbolDisplayPartKind[SymbolDisplayPartKind["functionName"] = 20] = "functionName"; - SymbolDisplayPartKind[SymbolDisplayPartKind["regularExpressionLiteral"] = 21] = "regularExpressionLiteral"; - })(ts.SymbolDisplayPartKind || (ts.SymbolDisplayPartKind = {})); - var SymbolDisplayPartKind = ts.SymbolDisplayPartKind; - (function (OutputFileType) { - OutputFileType[OutputFileType["JavaScript"] = 0] = "JavaScript"; - OutputFileType[OutputFileType["SourceMap"] = 1] = "SourceMap"; - OutputFileType[OutputFileType["Declaration"] = 2] = "Declaration"; - })(ts.OutputFileType || (ts.OutputFileType = {})); - var OutputFileType = ts.OutputFileType; - (function (EndOfLineState) { - EndOfLineState[EndOfLineState["None"] = 0] = "None"; - EndOfLineState[EndOfLineState["InMultiLineCommentTrivia"] = 1] = "InMultiLineCommentTrivia"; - EndOfLineState[EndOfLineState["InSingleQuoteStringLiteral"] = 2] = "InSingleQuoteStringLiteral"; - EndOfLineState[EndOfLineState["InDoubleQuoteStringLiteral"] = 3] = "InDoubleQuoteStringLiteral"; - EndOfLineState[EndOfLineState["InTemplateHeadOrNoSubstitutionTemplate"] = 4] = "InTemplateHeadOrNoSubstitutionTemplate"; - EndOfLineState[EndOfLineState["InTemplateMiddleOrTail"] = 5] = "InTemplateMiddleOrTail"; - EndOfLineState[EndOfLineState["InTemplateSubstitutionPosition"] = 6] = "InTemplateSubstitutionPosition"; - })(ts.EndOfLineState || (ts.EndOfLineState = {})); - var EndOfLineState = ts.EndOfLineState; - (function (TokenClass) { - TokenClass[TokenClass["Punctuation"] = 0] = "Punctuation"; - TokenClass[TokenClass["Keyword"] = 1] = "Keyword"; - TokenClass[TokenClass["Operator"] = 2] = "Operator"; - TokenClass[TokenClass["Comment"] = 3] = "Comment"; - TokenClass[TokenClass["Whitespace"] = 4] = "Whitespace"; - TokenClass[TokenClass["Identifier"] = 5] = "Identifier"; - TokenClass[TokenClass["NumberLiteral"] = 6] = "NumberLiteral"; - TokenClass[TokenClass["StringLiteral"] = 7] = "StringLiteral"; - TokenClass[TokenClass["RegExpLiteral"] = 8] = "RegExpLiteral"; - })(ts.TokenClass || (ts.TokenClass = {})); - var TokenClass = ts.TokenClass; - // TODO: move these to enums - var ScriptElementKind; - (function (ScriptElementKind) { - ScriptElementKind.unknown = ""; - ScriptElementKind.warning = "warning"; - // predefined type (void) or keyword (class) - ScriptElementKind.keyword = "keyword"; - // top level script node - ScriptElementKind.scriptElement = "script"; - // module foo {} - ScriptElementKind.moduleElement = "module"; - // class X {} - ScriptElementKind.classElement = "class"; - // interface Y {} - ScriptElementKind.interfaceElement = "interface"; - // type T = ... - ScriptElementKind.typeElement = "type"; - // enum E - ScriptElementKind.enumElement = "enum"; - // Inside module and script only - // let v = .. - ScriptElementKind.variableElement = "var"; - // Inside function - ScriptElementKind.localVariableElement = "local var"; - // Inside module and script only - // function f() { } - ScriptElementKind.functionElement = "function"; - // Inside function - ScriptElementKind.localFunctionElement = "local function"; - // class X { [public|private]* foo() {} } - ScriptElementKind.memberFunctionElement = "method"; - // class X { [public|private]* [get|set] foo:number; } - ScriptElementKind.memberGetAccessorElement = "getter"; - ScriptElementKind.memberSetAccessorElement = "setter"; - // class X { [public|private]* foo:number; } - // interface Y { foo:number; } - ScriptElementKind.memberVariableElement = "property"; - // class X { constructor() { } } - ScriptElementKind.constructorImplementationElement = "constructor"; - // interface Y { ():number; } - ScriptElementKind.callSignatureElement = "call"; - // interface Y { []:number; } - ScriptElementKind.indexSignatureElement = "index"; - // interface Y { new():Y; } - ScriptElementKind.constructSignatureElement = "construct"; - // function foo(*Y*: string) - ScriptElementKind.parameterElement = "parameter"; - ScriptElementKind.typeParameterElement = "type parameter"; - ScriptElementKind.primitiveType = "primitive type"; - ScriptElementKind.label = "label"; - ScriptElementKind.alias = "alias"; - ScriptElementKind.constElement = "const"; - ScriptElementKind.letElement = "let"; - })(ScriptElementKind = ts.ScriptElementKind || (ts.ScriptElementKind = {})); - var ScriptElementKindModifier; - (function (ScriptElementKindModifier) { - ScriptElementKindModifier.none = ""; - ScriptElementKindModifier.publicMemberModifier = "public"; - ScriptElementKindModifier.privateMemberModifier = "private"; - ScriptElementKindModifier.protectedMemberModifier = "protected"; - ScriptElementKindModifier.exportedModifier = "export"; - ScriptElementKindModifier.ambientModifier = "declare"; - ScriptElementKindModifier.staticModifier = "static"; - })(ScriptElementKindModifier = ts.ScriptElementKindModifier || (ts.ScriptElementKindModifier = {})); - var ClassificationTypeNames = (function () { - function ClassificationTypeNames() { - } - ClassificationTypeNames.comment = "comment"; - ClassificationTypeNames.identifier = "identifier"; - ClassificationTypeNames.keyword = "keyword"; - ClassificationTypeNames.numericLiteral = "number"; - ClassificationTypeNames.operator = "operator"; - ClassificationTypeNames.stringLiteral = "string"; - ClassificationTypeNames.whiteSpace = "whitespace"; - ClassificationTypeNames.text = "text"; - ClassificationTypeNames.punctuation = "punctuation"; - ClassificationTypeNames.className = "class name"; - ClassificationTypeNames.enumName = "enum name"; - ClassificationTypeNames.interfaceName = "interface name"; - ClassificationTypeNames.moduleName = "module name"; - ClassificationTypeNames.typeParameterName = "type parameter name"; - ClassificationTypeNames.typeAliasName = "type alias name"; - ClassificationTypeNames.parameterName = "parameter name"; - ClassificationTypeNames.docCommentTagName = "doc comment tag name"; - return ClassificationTypeNames; - })(); - ts.ClassificationTypeNames = ClassificationTypeNames; - (function (ClassificationType) { - ClassificationType[ClassificationType["comment"] = 1] = "comment"; - ClassificationType[ClassificationType["identifier"] = 2] = "identifier"; - ClassificationType[ClassificationType["keyword"] = 3] = "keyword"; - ClassificationType[ClassificationType["numericLiteral"] = 4] = "numericLiteral"; - ClassificationType[ClassificationType["operator"] = 5] = "operator"; - ClassificationType[ClassificationType["stringLiteral"] = 6] = "stringLiteral"; - ClassificationType[ClassificationType["regularExpressionLiteral"] = 7] = "regularExpressionLiteral"; - ClassificationType[ClassificationType["whiteSpace"] = 8] = "whiteSpace"; - ClassificationType[ClassificationType["text"] = 9] = "text"; - ClassificationType[ClassificationType["punctuation"] = 10] = "punctuation"; - ClassificationType[ClassificationType["className"] = 11] = "className"; - ClassificationType[ClassificationType["enumName"] = 12] = "enumName"; - ClassificationType[ClassificationType["interfaceName"] = 13] = "interfaceName"; - ClassificationType[ClassificationType["moduleName"] = 14] = "moduleName"; - ClassificationType[ClassificationType["typeParameterName"] = 15] = "typeParameterName"; - ClassificationType[ClassificationType["typeAliasName"] = 16] = "typeAliasName"; - ClassificationType[ClassificationType["parameterName"] = 17] = "parameterName"; - ClassificationType[ClassificationType["docCommentTagName"] = 18] = "docCommentTagName"; - })(ts.ClassificationType || (ts.ClassificationType = {})); - var ClassificationType = ts.ClassificationType; - function displayPartsToString(displayParts) { - if (displayParts) { - return ts.map(displayParts, function (displayPart) { return displayPart.text; }).join(""); - } - return ""; - } - ts.displayPartsToString = displayPartsToString; - function isLocalVariableOrFunction(symbol) { - if (symbol.parent) { - return false; // This is exported symbol - } - return ts.forEach(symbol.declarations, function (declaration) { - // Function expressions are local - if (declaration.kind === 165 /* FunctionExpression */) { - return true; - } - if (declaration.kind !== 201 /* VariableDeclaration */ && declaration.kind !== 203 /* FunctionDeclaration */) { - return false; - } - // If the parent is not sourceFile or module block it is local variable - for (var parent_9 = declaration.parent; !ts.isFunctionBlock(parent_9); parent_9 = parent_9.parent) { - // Reached source file or module block - if (parent_9.kind === 230 /* SourceFile */ || parent_9.kind === 209 /* ModuleBlock */) { - return false; - } - } - // parent is in function block - return true; - }); - } - function getDefaultCompilerOptions() { - // Always default to "ScriptTarget.ES5" for the language service - return { - target: 1 /* ES5 */, - module: 0 /* None */ - }; - } - ts.getDefaultCompilerOptions = getDefaultCompilerOptions; - var OperationCanceledException = (function () { - function OperationCanceledException() { - } - return OperationCanceledException; - })(); - ts.OperationCanceledException = OperationCanceledException; - var CancellationTokenObject = (function () { - function CancellationTokenObject(cancellationToken) { - this.cancellationToken = cancellationToken; - } - CancellationTokenObject.prototype.isCancellationRequested = function () { - return this.cancellationToken && this.cancellationToken.isCancellationRequested(); - }; - CancellationTokenObject.prototype.throwIfCancellationRequested = function () { - if (this.isCancellationRequested()) { - throw new OperationCanceledException(); - } - }; - CancellationTokenObject.None = new CancellationTokenObject(null); - return CancellationTokenObject; - })(); - ts.CancellationTokenObject = CancellationTokenObject; - // Cache host information about scrip Should be refreshed - // at each language service public entry point, since we don't know when - // set of scripts handled by the host changes. - var HostCache = (function () { - function HostCache(host, getCanonicalFileName) { - this.host = host; - // script id => script index - this.fileNameToEntry = ts.createFileMap(getCanonicalFileName); - // Initialize the list with the root file names - var rootFileNames = host.getScriptFileNames(); - for (var _i = 0; _i < rootFileNames.length; _i++) { - var fileName = rootFileNames[_i]; - this.createEntry(fileName); - } - // store the compilation settings - this._compilationSettings = host.getCompilationSettings() || getDefaultCompilerOptions(); - } - HostCache.prototype.compilationSettings = function () { - return this._compilationSettings; - }; - HostCache.prototype.createEntry = function (fileName) { - var entry; - var scriptSnapshot = this.host.getScriptSnapshot(fileName); - if (scriptSnapshot) { - entry = { - hostFileName: fileName, - version: this.host.getScriptVersion(fileName), - scriptSnapshot: scriptSnapshot - }; - } - this.fileNameToEntry.set(fileName, entry); - return entry; - }; - HostCache.prototype.getEntry = function (fileName) { - return this.fileNameToEntry.get(fileName); - }; - HostCache.prototype.contains = function (fileName) { - return this.fileNameToEntry.contains(fileName); - }; - HostCache.prototype.getOrCreateEntry = function (fileName) { - if (this.contains(fileName)) { - return this.getEntry(fileName); - } - return this.createEntry(fileName); - }; - HostCache.prototype.getRootFileNames = function () { - var fileNames = []; - this.fileNameToEntry.forEachValue(function (value) { - if (value) { - fileNames.push(value.hostFileName); - } - }); - return fileNames; - }; - HostCache.prototype.getVersion = function (fileName) { - var file = this.getEntry(fileName); - return file && file.version; - }; - HostCache.prototype.getScriptSnapshot = function (fileName) { - var file = this.getEntry(fileName); - return file && file.scriptSnapshot; - }; - return HostCache; - })(); - var SyntaxTreeCache = (function () { - function SyntaxTreeCache(host) { - this.host = host; - } - SyntaxTreeCache.prototype.getCurrentSourceFile = function (fileName) { - var scriptSnapshot = this.host.getScriptSnapshot(fileName); - if (!scriptSnapshot) { - // The host does not know about this file. - throw new Error("Could not find file: '" + fileName + "'."); - } - var version = this.host.getScriptVersion(fileName); - var sourceFile; - if (this.currentFileName !== fileName) { - // This is a new file, just parse it - sourceFile = createLanguageServiceSourceFile(fileName, scriptSnapshot, 2 /* Latest */, version, true); - } - else if (this.currentFileVersion !== version) { - // This is the same file, just a newer version. Incrementally parse the file. - var editRange = scriptSnapshot.getChangeRange(this.currentFileScriptSnapshot); - sourceFile = updateLanguageServiceSourceFile(this.currentSourceFile, scriptSnapshot, version, editRange); - } - if (sourceFile) { - // All done, ensure state is up to date - this.currentFileVersion = version; - this.currentFileName = fileName; - this.currentFileScriptSnapshot = scriptSnapshot; - this.currentSourceFile = sourceFile; - } - return this.currentSourceFile; - }; - return SyntaxTreeCache; - })(); - function setSourceFileFields(sourceFile, scriptSnapshot, version) { - sourceFile.version = version; - sourceFile.scriptSnapshot = scriptSnapshot; - } - /* - * This function will compile source text from 'input' argument using specified compiler options. - * If not options are provided - it will use a set of default compiler options. - * Extra compiler options that will unconditionally be used bu this function are: - * - isolatedModules = true - * - allowNonTsExtensions = true - * - noLib = true - * - noResolve = true - */ - function transpile(input, compilerOptions, fileName, diagnostics, moduleName) { - var options = compilerOptions ? ts.clone(compilerOptions) : getDefaultCompilerOptions(); - options.isolatedModules = true; - // Filename can be non-ts file. - options.allowNonTsExtensions = true; - // We are not returning a sourceFile for lib file when asked by the program, - // so pass --noLib to avoid reporting a file not found error. - options.noLib = true; - // We are not doing a full typecheck, we are not resolving the whole context, - // so pass --noResolve to avoid reporting missing file errors. - options.noResolve = true; - // Parse - var inputFileName = fileName || "module.ts"; - var sourceFile = ts.createSourceFile(inputFileName, input, options.target); - if (moduleName) { - sourceFile.moduleName = moduleName; - } - // Store syntactic diagnostics - if (diagnostics && sourceFile.parseDiagnostics) { - diagnostics.push.apply(diagnostics, sourceFile.parseDiagnostics); - } - var newLine = ts.getNewLineCharacter(options); - // Output - var outputText; - // Create a compilerHost object to allow the compiler to read and write files - var compilerHost = { - getSourceFile: function (fileName, target) { return fileName === inputFileName ? sourceFile : undefined; }, - writeFile: function (name, text, writeByteOrderMark) { - ts.Debug.assert(outputText === undefined, "Unexpected multiple outputs for the file: " + name); - outputText = text; - }, - getDefaultLibFileName: function () { return "lib.d.ts"; }, - useCaseSensitiveFileNames: function () { return false; }, - getCanonicalFileName: function (fileName) { return fileName; }, - getCurrentDirectory: function () { return ""; }, - getNewLine: function () { return newLine; } - }; - var program = ts.createProgram([inputFileName], options, compilerHost); - if (diagnostics) { - diagnostics.push.apply(diagnostics, program.getCompilerOptionsDiagnostics()); - } - // Emit - program.emit(); - ts.Debug.assert(outputText !== undefined, "Output generation failed"); - return outputText; - } - ts.transpile = transpile; - function createLanguageServiceSourceFile(fileName, scriptSnapshot, scriptTarget, version, setNodeParents) { - var text = scriptSnapshot.getText(0, scriptSnapshot.getLength()); - var sourceFile = ts.createSourceFile(fileName, text, scriptTarget, setNodeParents); - setSourceFileFields(sourceFile, scriptSnapshot, version); - // after full parsing we can use table with interned strings as name table - sourceFile.nameTable = sourceFile.identifiers; - return sourceFile; - } - ts.createLanguageServiceSourceFile = createLanguageServiceSourceFile; - ts.disableIncrementalParsing = false; - function updateLanguageServiceSourceFile(sourceFile, scriptSnapshot, version, textChangeRange, aggressiveChecks) { - // If we were given a text change range, and our version or open-ness changed, then - // incrementally parse this file. - if (textChangeRange) { - if (version !== sourceFile.version) { - // Once incremental parsing is ready, then just call into this function. - if (!ts.disableIncrementalParsing) { - var newText; - // grab the fragment from the beginning of the original text to the beginning of the span - var prefix = textChangeRange.span.start !== 0 - ? sourceFile.text.substr(0, textChangeRange.span.start) - : ""; - // grab the fragment from the end of the span till the end of the original text - var suffix = ts.textSpanEnd(textChangeRange.span) !== sourceFile.text.length - ? sourceFile.text.substr(ts.textSpanEnd(textChangeRange.span)) - : ""; - if (textChangeRange.newLength === 0) { - // edit was a deletion - just combine prefix and suffix - newText = prefix && suffix ? prefix + suffix : prefix || suffix; - } - else { - // it was actual edit, fetch the fragment of new text that correspond to new span - var changedText = scriptSnapshot.getText(textChangeRange.span.start, textChangeRange.span.start + textChangeRange.newLength); - // combine prefix, changed text and suffix - newText = prefix && suffix - ? prefix + changedText + suffix - : prefix - ? (prefix + changedText) - : (changedText + suffix); - } - var newSourceFile = ts.updateSourceFile(sourceFile, newText, textChangeRange, aggressiveChecks); - setSourceFileFields(newSourceFile, scriptSnapshot, version); - // after incremental parsing nameTable might not be up-to-date - // drop it so it can be lazily recreated later - newSourceFile.nameTable = undefined; - return newSourceFile; - } - } - } - // Otherwise, just create a new source file. - return createLanguageServiceSourceFile(sourceFile.fileName, scriptSnapshot, sourceFile.languageVersion, version, true); - } - ts.updateLanguageServiceSourceFile = updateLanguageServiceSourceFile; - function createGetCanonicalFileName(useCaseSensitivefileNames) { - return useCaseSensitivefileNames - ? (function (fileName) { return fileName; }) - : (function (fileName) { return fileName.toLowerCase(); }); - } - function createDocumentRegistry(useCaseSensitiveFileNames) { - // Maps from compiler setting target (ES3, ES5, etc.) to all the cached documents we have - // for those settings. - var buckets = {}; - var getCanonicalFileName = createGetCanonicalFileName(!!useCaseSensitiveFileNames); - function getKeyFromCompilationSettings(settings) { - return "_" + settings.target; // + "|" + settings.propagateEnumConstantoString() - } - function getBucketForCompilationSettings(settings, createIfMissing) { - var key = getKeyFromCompilationSettings(settings); - var bucket = ts.lookUp(buckets, key); - if (!bucket && createIfMissing) { - buckets[key] = bucket = ts.createFileMap(getCanonicalFileName); - } - return bucket; - } - function reportStats() { - var bucketInfoArray = Object.keys(buckets).filter(function (name) { return name && name.charAt(0) === '_'; }).map(function (name) { - var entries = ts.lookUp(buckets, name); - var sourceFiles = []; - for (var i in entries) { - var entry = entries.get(i); - sourceFiles.push({ - name: i, - refCount: entry.languageServiceRefCount, - references: entry.owners.slice(0) - }); - } - sourceFiles.sort(function (x, y) { return y.refCount - x.refCount; }); - return { - bucket: name, - sourceFiles: sourceFiles - }; - }); - return JSON.stringify(bucketInfoArray, null, 2); - } - function acquireDocument(fileName, compilationSettings, scriptSnapshot, version) { - return acquireOrUpdateDocument(fileName, compilationSettings, scriptSnapshot, version, true); - } - function updateDocument(fileName, compilationSettings, scriptSnapshot, version) { - return acquireOrUpdateDocument(fileName, compilationSettings, scriptSnapshot, version, false); - } - function acquireOrUpdateDocument(fileName, compilationSettings, scriptSnapshot, version, acquiring) { - var bucket = getBucketForCompilationSettings(compilationSettings, true); - var entry = bucket.get(fileName); - if (!entry) { - ts.Debug.assert(acquiring, "How could we be trying to update a document that the registry doesn't have?"); - // Have never seen this file with these settings. Create a new source file for it. - var sourceFile = createLanguageServiceSourceFile(fileName, scriptSnapshot, compilationSettings.target, version, false); - entry = { - sourceFile: sourceFile, - languageServiceRefCount: 0, - owners: [] - }; - bucket.set(fileName, entry); - } - else { - // We have an entry for this file. However, it may be for a different version of - // the script snapshot. If so, update it appropriately. Otherwise, we can just - // return it as is. - if (entry.sourceFile.version !== version) { - entry.sourceFile = updateLanguageServiceSourceFile(entry.sourceFile, scriptSnapshot, version, scriptSnapshot.getChangeRange(entry.sourceFile.scriptSnapshot)); - } - } - // If we're acquiring, then this is the first time this LS is asking for this document. - // Increase our ref count so we know there's another LS using the document. If we're - // not acquiring, then that means the LS is 'updating' the file instead, and that means - // it has already acquired the document previously. As such, we do not need to increase - // the ref count. - if (acquiring) { - entry.languageServiceRefCount++; - } - return entry.sourceFile; - } - function releaseDocument(fileName, compilationSettings) { - var bucket = getBucketForCompilationSettings(compilationSettings, false); - ts.Debug.assert(bucket !== undefined); - var entry = bucket.get(fileName); - entry.languageServiceRefCount--; - ts.Debug.assert(entry.languageServiceRefCount >= 0); - if (entry.languageServiceRefCount === 0) { - bucket.remove(fileName); - } - } - return { - acquireDocument: acquireDocument, - updateDocument: updateDocument, - releaseDocument: releaseDocument, - reportStats: reportStats - }; - } - ts.createDocumentRegistry = createDocumentRegistry; - function preProcessFile(sourceText, readImportFiles) { - if (readImportFiles === void 0) { readImportFiles = true; } - var referencedFiles = []; - var importedFiles = []; - var isNoDefaultLib = false; - function processTripleSlashDirectives() { - var commentRanges = ts.getLeadingCommentRanges(sourceText, 0); - ts.forEach(commentRanges, function (commentRange) { - var comment = sourceText.substring(commentRange.pos, commentRange.end); - var referencePathMatchResult = ts.getFileReferenceFromReferencePath(comment, commentRange); - if (referencePathMatchResult) { - isNoDefaultLib = referencePathMatchResult.isNoDefaultLib; - var fileReference = referencePathMatchResult.fileReference; - if (fileReference) { - referencedFiles.push(fileReference); - } - } - }); - } - function recordModuleName() { - var importPath = scanner.getTokenValue(); - var pos = scanner.getTokenPos(); - importedFiles.push({ - fileName: importPath, - pos: pos, - end: pos + importPath.length - }); - } - function processImport() { - scanner.setText(sourceText); - var token = scanner.scan(); - // Look for: - // import "mod"; - // import d from "mod" - // import {a as A } from "mod"; - // import * as NS from "mod" - // import d, {a, b as B} from "mod" - // import i = require("mod"); - // - // export * from "mod" - // export {a as b} from "mod" - while (token !== 1 /* EndOfFileToken */) { - if (token === 85 /* ImportKeyword */) { - token = scanner.scan(); - if (token === 8 /* StringLiteral */) { - // import "mod"; - recordModuleName(); - continue; - } - else { - if (token === 65 /* Identifier */) { - token = scanner.scan(); - if (token === 126 /* FromKeyword */) { - token = scanner.scan(); - if (token === 8 /* StringLiteral */) { - // import d from "mod"; - recordModuleName(); - continue; - } - } - else if (token === 53 /* EqualsToken */) { - token = scanner.scan(); - if (token === 120 /* RequireKeyword */) { - token = scanner.scan(); - if (token === 16 /* OpenParenToken */) { - token = scanner.scan(); - if (token === 8 /* StringLiteral */) { - // import i = require("mod"); - recordModuleName(); - continue; - } - } - } - } - else if (token === 23 /* CommaToken */) { - // consume comma and keep going - token = scanner.scan(); - } - else { - // unknown syntax - continue; - } - } - if (token === 14 /* OpenBraceToken */) { - token = scanner.scan(); - // consume "{ a as B, c, d as D}" clauses - while (token !== 15 /* CloseBraceToken */) { - token = scanner.scan(); - } - if (token === 15 /* CloseBraceToken */) { - token = scanner.scan(); - if (token === 126 /* FromKeyword */) { - token = scanner.scan(); - if (token === 8 /* StringLiteral */) { - // import {a as A} from "mod"; - // import d, {a, b as B} from "mod" - recordModuleName(); - } - } - } - } - else if (token === 35 /* AsteriskToken */) { - token = scanner.scan(); - if (token === 111 /* AsKeyword */) { - token = scanner.scan(); - if (token === 65 /* Identifier */) { - token = scanner.scan(); - if (token === 126 /* FromKeyword */) { - token = scanner.scan(); - if (token === 8 /* StringLiteral */) { - // import * as NS from "mod" - // import d, * as NS from "mod" - recordModuleName(); - } - } - } - } - } - } - } - else if (token === 78 /* ExportKeyword */) { - token = scanner.scan(); - if (token === 14 /* OpenBraceToken */) { - token = scanner.scan(); - // consume "{ a as B, c, d as D}" clauses - while (token !== 15 /* CloseBraceToken */) { - token = scanner.scan(); - } - if (token === 15 /* CloseBraceToken */) { - token = scanner.scan(); - if (token === 126 /* FromKeyword */) { - token = scanner.scan(); - if (token === 8 /* StringLiteral */) { - // export {a as A} from "mod"; - // export {a, b as B} from "mod" - recordModuleName(); - } - } - } - } - else if (token === 35 /* AsteriskToken */) { - token = scanner.scan(); - if (token === 126 /* FromKeyword */) { - token = scanner.scan(); - if (token === 8 /* StringLiteral */) { - // export * from "mod" - recordModuleName(); - } - } - } - } - token = scanner.scan(); - } - scanner.setText(undefined); - } - if (readImportFiles) { - processImport(); - } - processTripleSlashDirectives(); - return { referencedFiles: referencedFiles, importedFiles: importedFiles, isLibFile: isNoDefaultLib }; - } - ts.preProcessFile = preProcessFile; - /// Helpers - function getTargetLabel(referenceNode, labelName) { - while (referenceNode) { - if (referenceNode.kind === 197 /* LabeledStatement */ && referenceNode.label.text === labelName) { - return referenceNode.label; - } - referenceNode = referenceNode.parent; - } - return undefined; - } - function isJumpStatementTarget(node) { - return node.kind === 65 /* Identifier */ && - (node.parent.kind === 193 /* BreakStatement */ || node.parent.kind === 192 /* ContinueStatement */) && - node.parent.label === node; - } - function isLabelOfLabeledStatement(node) { - return node.kind === 65 /* Identifier */ && - node.parent.kind === 197 /* LabeledStatement */ && - node.parent.label === node; - } - /** - * Whether or not a 'node' is preceded by a label of the given string. - * Note: 'node' cannot be a SourceFile. - */ - function isLabeledBy(node, labelName) { - for (var owner = node.parent; owner.kind === 197 /* LabeledStatement */; owner = owner.parent) { - if (owner.label.text === labelName) { - return true; - } - } - return false; - } - function isLabelName(node) { - return isLabelOfLabeledStatement(node) || isJumpStatementTarget(node); - } - function isRightSideOfQualifiedName(node) { - return node.parent.kind === 128 /* QualifiedName */ && node.parent.right === node; - } - function isRightSideOfPropertyAccess(node) { - return node && node.parent && node.parent.kind === 158 /* PropertyAccessExpression */ && node.parent.name === node; - } - function isCallExpressionTarget(node) { - if (isRightSideOfPropertyAccess(node)) { - node = node.parent; - } - return node && node.parent && node.parent.kind === 160 /* CallExpression */ && node.parent.expression === node; - } - function isNewExpressionTarget(node) { - if (isRightSideOfPropertyAccess(node)) { - node = node.parent; - } - return node && node.parent && node.parent.kind === 161 /* NewExpression */ && node.parent.expression === node; - } - function isNameOfModuleDeclaration(node) { - return node.parent.kind === 208 /* ModuleDeclaration */ && node.parent.name === node; - } - function isNameOfFunctionDeclaration(node) { - return node.kind === 65 /* Identifier */ && - ts.isFunctionLike(node.parent) && node.parent.name === node; - } - /** Returns true if node is a name of an object literal property, e.g. "a" in x = { "a": 1 } */ - function isNameOfPropertyAssignment(node) { - return (node.kind === 65 /* Identifier */ || node.kind === 8 /* StringLiteral */ || node.kind === 7 /* NumericLiteral */) && - (node.parent.kind === 227 /* PropertyAssignment */ || node.parent.kind === 228 /* ShorthandPropertyAssignment */) && node.parent.name === node; - } - function isLiteralNameOfPropertyDeclarationOrIndexAccess(node) { - if (node.kind === 8 /* StringLiteral */ || node.kind === 7 /* NumericLiteral */) { - switch (node.parent.kind) { - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - case 227 /* PropertyAssignment */: - case 229 /* EnumMember */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 208 /* ModuleDeclaration */: - return node.parent.name === node; - case 159 /* ElementAccessExpression */: - return node.parent.argumentExpression === node; - } - } - return false; - } - function isNameOfExternalModuleImportOrDeclaration(node) { - if (node.kind === 8 /* StringLiteral */) { - return isNameOfModuleDeclaration(node) || - (ts.isExternalModuleImportEqualsDeclaration(node.parent.parent) && ts.getExternalModuleImportEqualsDeclarationExpression(node.parent.parent) === node); - } - return false; - } - /** Returns true if the position is within a comment */ - function isInsideComment(sourceFile, token, position) { - // The position has to be: 1. in the leading trivia (before token.getStart()), and 2. within a comment - return position <= token.getStart(sourceFile) && - (isInsideCommentRange(ts.getTrailingCommentRanges(sourceFile.text, token.getFullStart())) || - isInsideCommentRange(ts.getLeadingCommentRanges(sourceFile.text, token.getFullStart()))); - function isInsideCommentRange(comments) { - return ts.forEach(comments, function (comment) { - // either we are 1. completely inside the comment, or 2. at the end of the comment - if (comment.pos < position && position < comment.end) { - return true; - } - else if (position === comment.end) { - var text = sourceFile.text; - var width = comment.end - comment.pos; - // is single line comment or just /* - if (width <= 2 || text.charCodeAt(comment.pos + 1) === 47 /* slash */) { - return true; - } - else { - // is unterminated multi-line comment - return !(text.charCodeAt(comment.end - 1) === 47 /* slash */ && - text.charCodeAt(comment.end - 2) === 42 /* asterisk */); - } - } - return false; - }); - } - } - var SemanticMeaning; - (function (SemanticMeaning) { - SemanticMeaning[SemanticMeaning["None"] = 0] = "None"; - SemanticMeaning[SemanticMeaning["Value"] = 1] = "Value"; - SemanticMeaning[SemanticMeaning["Type"] = 2] = "Type"; - SemanticMeaning[SemanticMeaning["Namespace"] = 4] = "Namespace"; - SemanticMeaning[SemanticMeaning["All"] = 7] = "All"; - })(SemanticMeaning || (SemanticMeaning = {})); - var BreakContinueSearchType; - (function (BreakContinueSearchType) { - BreakContinueSearchType[BreakContinueSearchType["None"] = 0] = "None"; - BreakContinueSearchType[BreakContinueSearchType["Unlabeled"] = 1] = "Unlabeled"; - BreakContinueSearchType[BreakContinueSearchType["Labeled"] = 2] = "Labeled"; - BreakContinueSearchType[BreakContinueSearchType["All"] = 3] = "All"; - })(BreakContinueSearchType || (BreakContinueSearchType = {})); - // A cache of completion entries for keywords, these do not change between sessions - var keywordCompletions = []; - for (var i = 66 /* FirstKeyword */; i <= 127 /* LastKeyword */; i++) { - keywordCompletions.push({ - name: ts.tokenToString(i), - kind: ScriptElementKind.keyword, - kindModifiers: ScriptElementKindModifier.none, - sortText: "0" - }); - } - /* @internal */ function getContainerNode(node) { - while (true) { - node = node.parent; - if (!node) { - return undefined; - } - switch (node.kind) { - case 230 /* SourceFile */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 203 /* FunctionDeclaration */: - case 165 /* FunctionExpression */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 204 /* ClassDeclaration */: - case 205 /* InterfaceDeclaration */: - case 207 /* EnumDeclaration */: - case 208 /* ModuleDeclaration */: - return node; - } - } - } - ts.getContainerNode = getContainerNode; - /* @internal */ function getNodeKind(node) { - switch (node.kind) { - case 208 /* ModuleDeclaration */: return ScriptElementKind.moduleElement; - case 204 /* ClassDeclaration */: return ScriptElementKind.classElement; - case 205 /* InterfaceDeclaration */: return ScriptElementKind.interfaceElement; - case 206 /* TypeAliasDeclaration */: return ScriptElementKind.typeElement; - case 207 /* EnumDeclaration */: return ScriptElementKind.enumElement; - case 201 /* VariableDeclaration */: - return ts.isConst(node) - ? ScriptElementKind.constElement - : ts.isLet(node) - ? ScriptElementKind.letElement - : ScriptElementKind.variableElement; - case 203 /* FunctionDeclaration */: return ScriptElementKind.functionElement; - case 138 /* GetAccessor */: return ScriptElementKind.memberGetAccessorElement; - case 139 /* SetAccessor */: return ScriptElementKind.memberSetAccessorElement; - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - return ScriptElementKind.memberFunctionElement; - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - return ScriptElementKind.memberVariableElement; - case 142 /* IndexSignature */: return ScriptElementKind.indexSignatureElement; - case 141 /* ConstructSignature */: return ScriptElementKind.constructSignatureElement; - case 140 /* CallSignature */: return ScriptElementKind.callSignatureElement; - case 137 /* Constructor */: return ScriptElementKind.constructorImplementationElement; - case 130 /* TypeParameter */: return ScriptElementKind.typeParameterElement; - case 229 /* EnumMember */: return ScriptElementKind.variableElement; - case 131 /* Parameter */: return (node.flags & 112 /* AccessibilityModifier */) ? ScriptElementKind.memberVariableElement : ScriptElementKind.parameterElement; - case 211 /* ImportEqualsDeclaration */: - case 216 /* ImportSpecifier */: - case 213 /* ImportClause */: - case 220 /* ExportSpecifier */: - case 214 /* NamespaceImport */: - return ScriptElementKind.alias; - } - return ScriptElementKind.unknown; - } - ts.getNodeKind = getNodeKind; - function createLanguageService(host, documentRegistry) { - if (documentRegistry === void 0) { documentRegistry = createDocumentRegistry(); } - var syntaxTreeCache = new SyntaxTreeCache(host); - var ruleProvider; - var program; - var lastProjectVersion; - var useCaseSensitivefileNames = false; - var cancellationToken = new CancellationTokenObject(host.getCancellationToken && host.getCancellationToken()); - // Check if the localized messages json is set, otherwise query the host for it - if (!ts.localizedDiagnosticMessages && host.getLocalizedDiagnosticMessages) { - ts.localizedDiagnosticMessages = host.getLocalizedDiagnosticMessages(); - } - function log(message) { - if (host.log) { - host.log(message); - } - } - var getCanonicalFileName = createGetCanonicalFileName(useCaseSensitivefileNames); - function getValidSourceFile(fileName) { - fileName = ts.normalizeSlashes(fileName); - var sourceFile = program.getSourceFile(getCanonicalFileName(fileName)); - if (!sourceFile) { - throw new Error("Could not find file: '" + fileName + "'."); - } - return sourceFile; - } - function getRuleProvider(options) { - // Ensure rules are initialized and up to date wrt to formatting options - if (!ruleProvider) { - ruleProvider = new ts.formatting.RulesProvider(); - } - ruleProvider.ensureUpToDate(options); - return ruleProvider; - } - function synchronizeHostData() { - // perform fast check if host supports it - if (host.getProjectVersion) { - var hostProjectVersion = host.getProjectVersion(); - if (hostProjectVersion) { - if (lastProjectVersion === hostProjectVersion) { - return; - } - lastProjectVersion = hostProjectVersion; - } - } - // Get a fresh cache of the host information - var hostCache = new HostCache(host, getCanonicalFileName); - // If the program is already up-to-date, we can reuse it - if (programUpToDate()) { - return; - } - // IMPORTANT - It is critical from this moment onward that we do not check - // cancellation tokens. We are about to mutate source files from a previous program - // instance. If we cancel midway through, we may end up in an inconsistent state where - // the program points to old source files that have been invalidated because of - // incremental parsing. - var oldSettings = program && program.getCompilerOptions(); - var newSettings = hostCache.compilationSettings(); - var changesInCompilationSettingsAffectSyntax = oldSettings && oldSettings.target !== newSettings.target; - // Now create a new compiler - var newProgram = ts.createProgram(hostCache.getRootFileNames(), newSettings, { - getSourceFile: getOrCreateSourceFile, - getCancellationToken: function () { return cancellationToken; }, - getCanonicalFileName: getCanonicalFileName, - useCaseSensitiveFileNames: function () { return useCaseSensitivefileNames; }, - getNewLine: function () { return host.getNewLine ? host.getNewLine() : "\r\n"; }, - getDefaultLibFileName: function (options) { return host.getDefaultLibFileName(options); }, - writeFile: function (fileName, data, writeByteOrderMark) { }, - getCurrentDirectory: function () { return host.getCurrentDirectory(); } - }); - // Release any files we have acquired in the old program but are - // not part of the new program. - if (program) { - var oldSourceFiles = program.getSourceFiles(); - for (var _i = 0; _i < oldSourceFiles.length; _i++) { - var oldSourceFile = oldSourceFiles[_i]; - var fileName = oldSourceFile.fileName; - if (!newProgram.getSourceFile(fileName) || changesInCompilationSettingsAffectSyntax) { - documentRegistry.releaseDocument(fileName, oldSettings); - } - } - } - // hostCache is captured in the closure for 'getOrCreateSourceFile' but it should not be used past this point. - // It needs to be cleared to allow all collected snapshots to be released - hostCache = undefined; - program = newProgram; - // Make sure all the nodes in the program are both bound, and have their parent - // pointers set property. - program.getTypeChecker(); - return; - function getOrCreateSourceFile(fileName) { - ts.Debug.assert(hostCache !== undefined); - // The program is asking for this file, check first if the host can locate it. - // If the host can not locate the file, then it does not exist. return undefined - // to the program to allow reporting of errors for missing files. - var hostFileInformation = hostCache.getOrCreateEntry(fileName); - if (!hostFileInformation) { - return undefined; - } - // Check if the language version has changed since we last created a program; if they are the same, - // it is safe to reuse the souceFiles; if not, then the shape of the AST can change, and the oldSourceFile - // can not be reused. we have to dump all syntax trees and create new ones. - if (!changesInCompilationSettingsAffectSyntax) { - // Check if the old program had this file already - var oldSourceFile = program && program.getSourceFile(fileName); - if (oldSourceFile) { - // We already had a source file for this file name. Go to the registry to - // ensure that we get the right up to date version of it. We need this to - // address the following 'race'. Specifically, say we have the following: - // - // LS1 - // \ - // DocumentRegistry - // / - // LS2 - // - // Each LS has a reference to file 'foo.ts' at version 1. LS2 then updates - // it's version of 'foo.ts' to version 2. This will cause LS2 and the - // DocumentRegistry to have version 2 of the document. HOwever, LS1 will - // have version 1. And *importantly* this source file will be *corrupt*. - // The act of creating version 2 of the file irrevocably damages the version - // 1 file. - // - // So, later when we call into LS1, we need to make sure that it doesn't use - // it's source file any more, and instead defers to DocumentRegistry to get - // either version 1, version 2 (or some other version) depending on what the - // host says should be used. - return documentRegistry.updateDocument(fileName, newSettings, hostFileInformation.scriptSnapshot, hostFileInformation.version); - } - } - // Could not find this file in the old program, create a new SourceFile for it. - return documentRegistry.acquireDocument(fileName, newSettings, hostFileInformation.scriptSnapshot, hostFileInformation.version); - } - function sourceFileUpToDate(sourceFile) { - return sourceFile && sourceFile.version === hostCache.getVersion(sourceFile.fileName); - } - function programUpToDate() { - // If we haven't create a program yet, then it is not up-to-date - if (!program) { - return false; - } - // If number of files in the program do not match, it is not up-to-date - var rootFileNames = hostCache.getRootFileNames(); - if (program.getSourceFiles().length !== rootFileNames.length) { - return false; - } - // If any file is not up-to-date, then the whole program is not up-to-date - for (var _i = 0; _i < rootFileNames.length; _i++) { - var fileName = rootFileNames[_i]; - if (!sourceFileUpToDate(program.getSourceFile(fileName))) { - return false; - } - } - // If the compilation settings do no match, then the program is not up-to-date - return ts.compareDataObjects(program.getCompilerOptions(), hostCache.compilationSettings()); - } - } - function getProgram() { - synchronizeHostData(); - return program; - } - function cleanupSemanticCache() { - // TODO: Should we jettison the program (or it's type checker) here? - } - function dispose() { - if (program) { - ts.forEach(program.getSourceFiles(), function (f) { - return documentRegistry.releaseDocument(f.fileName, program.getCompilerOptions()); - }); - } - } - /// Diagnostics - function getSyntacticDiagnostics(fileName) { - synchronizeHostData(); - return program.getSyntacticDiagnostics(getValidSourceFile(fileName)); - } - /** - * getSemanticDiagnostiscs return array of Diagnostics. If '-d' is not enabled, only report semantic errors - * If '-d' enabled, report both semantic and emitter errors - */ - function getSemanticDiagnostics(fileName) { - synchronizeHostData(); - var targetSourceFile = getValidSourceFile(fileName); - // For JavaScript files, we don't want to report the normal typescript semantic errors. - // Instead, we just report errors for using TypeScript-only constructs from within a - // JavaScript file. - if (ts.isJavaScript(fileName)) { - return getJavaScriptSemanticDiagnostics(targetSourceFile); - } - // Only perform the action per file regardless of '-out' flag as LanguageServiceHost is expected to call this function per file. - // Therefore only get diagnostics for given file. - var semanticDiagnostics = program.getSemanticDiagnostics(targetSourceFile); - if (!program.getCompilerOptions().declaration) { - return semanticDiagnostics; - } - // If '-d' is enabled, check for emitter error. One example of emitter error is export class implements non-export interface - var declarationDiagnostics = program.getDeclarationDiagnostics(targetSourceFile); - return ts.concatenate(semanticDiagnostics, declarationDiagnostics); - } - function getJavaScriptSemanticDiagnostics(sourceFile) { - var diagnostics = []; - walk(sourceFile); - return diagnostics; - function walk(node) { - if (!node) { - return false; - } - switch (node.kind) { - case 211 /* ImportEqualsDeclaration */: - diagnostics.push(ts.createDiagnosticForNode(node, ts.Diagnostics.import_can_only_be_used_in_a_ts_file)); - return true; - case 217 /* ExportAssignment */: - diagnostics.push(ts.createDiagnosticForNode(node, ts.Diagnostics.export_can_only_be_used_in_a_ts_file)); - return true; - case 204 /* ClassDeclaration */: - var classDeclaration = node; - if (checkModifiers(classDeclaration.modifiers) || - checkTypeParameters(classDeclaration.typeParameters)) { - return true; - } - break; - case 225 /* HeritageClause */: - var heritageClause = node; - if (heritageClause.token === 102 /* ImplementsKeyword */) { - diagnostics.push(ts.createDiagnosticForNode(node, ts.Diagnostics.implements_clauses_can_only_be_used_in_a_ts_file)); - return true; - } - break; - case 205 /* InterfaceDeclaration */: - diagnostics.push(ts.createDiagnosticForNode(node, ts.Diagnostics.interface_declarations_can_only_be_used_in_a_ts_file)); - return true; - case 208 /* ModuleDeclaration */: - diagnostics.push(ts.createDiagnosticForNode(node, ts.Diagnostics.module_declarations_can_only_be_used_in_a_ts_file)); - return true; - case 206 /* TypeAliasDeclaration */: - diagnostics.push(ts.createDiagnosticForNode(node, ts.Diagnostics.type_aliases_can_only_be_used_in_a_ts_file)); - return true; - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 137 /* Constructor */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 165 /* FunctionExpression */: - case 203 /* FunctionDeclaration */: - case 166 /* ArrowFunction */: - case 203 /* FunctionDeclaration */: - var functionDeclaration = node; - if (checkModifiers(functionDeclaration.modifiers) || - checkTypeParameters(functionDeclaration.typeParameters) || - checkTypeAnnotation(functionDeclaration.type)) { - return true; - } - break; - case 183 /* VariableStatement */: - var variableStatement = node; - if (checkModifiers(variableStatement.modifiers)) { - return true; - } - break; - case 201 /* VariableDeclaration */: - var variableDeclaration = node; - if (checkTypeAnnotation(variableDeclaration.type)) { - return true; - } - break; - case 160 /* CallExpression */: - case 161 /* NewExpression */: - var expression = node; - if (expression.typeArguments && expression.typeArguments.length > 0) { - var start = expression.typeArguments.pos; - diagnostics.push(ts.createFileDiagnostic(sourceFile, start, expression.typeArguments.end - start, ts.Diagnostics.type_arguments_can_only_be_used_in_a_ts_file)); - return true; - } - break; - case 131 /* Parameter */: - var parameter = node; - if (parameter.modifiers) { - var start = parameter.modifiers.pos; - diagnostics.push(ts.createFileDiagnostic(sourceFile, start, parameter.modifiers.end - start, ts.Diagnostics.parameter_modifiers_can_only_be_used_in_a_ts_file)); - return true; - } - if (parameter.questionToken) { - diagnostics.push(ts.createDiagnosticForNode(parameter.questionToken, ts.Diagnostics._0_can_only_be_used_in_a_ts_file, '?')); - return true; - } - if (parameter.type) { - diagnostics.push(ts.createDiagnosticForNode(parameter.type, ts.Diagnostics.types_can_only_be_used_in_a_ts_file)); - return true; - } - break; - case 134 /* PropertyDeclaration */: - diagnostics.push(ts.createDiagnosticForNode(node, ts.Diagnostics.property_declarations_can_only_be_used_in_a_ts_file)); - return true; - case 207 /* EnumDeclaration */: - diagnostics.push(ts.createDiagnosticForNode(node, ts.Diagnostics.enum_declarations_can_only_be_used_in_a_ts_file)); - return true; - case 163 /* TypeAssertionExpression */: - var typeAssertionExpression = node; - diagnostics.push(ts.createDiagnosticForNode(typeAssertionExpression.type, ts.Diagnostics.type_assertion_expressions_can_only_be_used_in_a_ts_file)); - return true; - case 132 /* Decorator */: - diagnostics.push(ts.createDiagnosticForNode(node, ts.Diagnostics.decorators_can_only_be_used_in_a_ts_file)); - return true; - } - return ts.forEachChild(node, walk); - } - function checkTypeParameters(typeParameters) { - if (typeParameters) { - var start = typeParameters.pos; - diagnostics.push(ts.createFileDiagnostic(sourceFile, start, typeParameters.end - start, ts.Diagnostics.type_parameter_declarations_can_only_be_used_in_a_ts_file)); - return true; - } - return false; - } - function checkTypeAnnotation(type) { - if (type) { - diagnostics.push(ts.createDiagnosticForNode(type, ts.Diagnostics.types_can_only_be_used_in_a_ts_file)); - return true; - } - return false; - } - function checkModifiers(modifiers) { - if (modifiers) { - for (var _i = 0; _i < modifiers.length; _i++) { - var modifier = modifiers[_i]; - switch (modifier.kind) { - case 108 /* PublicKeyword */: - case 106 /* PrivateKeyword */: - case 107 /* ProtectedKeyword */: - case 115 /* DeclareKeyword */: - diagnostics.push(ts.createDiagnosticForNode(modifier, ts.Diagnostics._0_can_only_be_used_in_a_ts_file, ts.tokenToString(modifier.kind))); - return true; - // These are all legal modifiers. - case 109 /* StaticKeyword */: - case 78 /* ExportKeyword */: - case 70 /* ConstKeyword */: - case 73 /* DefaultKeyword */: - } - } - } - return false; - } - } - function getCompilerOptionsDiagnostics() { - synchronizeHostData(); - return program.getGlobalDiagnostics(); - } - /// Completion - function getCompletionEntryDisplayNameForSymbol(symbol, target, performCharacterChecks) { - var displayName = symbol.getName(); - if (displayName) { - // If this is the default export, get the name of the declaration if it exists - if (displayName === "default") { - var localSymbol = ts.getLocalSymbolForExportDefault(symbol); - if (localSymbol && localSymbol.name) { - displayName = symbol.valueDeclaration.localSymbol.name; - } - } - var firstCharCode = displayName.charCodeAt(0); - // First check of the displayName is not external module; if it is an external module, it is not valid entry - if ((symbol.flags & 1536 /* Namespace */) && (firstCharCode === 39 /* singleQuote */ || firstCharCode === 34 /* doubleQuote */)) { - // If the symbol is external module, don't show it in the completion list - // (i.e declare module "http" { let x; } | // <= request completion here, "http" should not be there) - return undefined; - } - } - return getCompletionEntryDisplayName(displayName, target, performCharacterChecks); - } - function getCompletionEntryDisplayName(displayName, target, performCharacterChecks) { - if (!displayName) { - return undefined; - } - var firstCharCode = displayName.charCodeAt(0); - if (displayName.length >= 2 && - firstCharCode === displayName.charCodeAt(displayName.length - 1) && - (firstCharCode === 39 /* singleQuote */ || firstCharCode === 34 /* doubleQuote */)) { - // If the user entered name for the symbol was quoted, removing the quotes is not enough, as the name could be an - // invalid identifier name. We need to check if whatever was inside the quotes is actually a valid identifier name. - displayName = displayName.substring(1, displayName.length - 1); - } - if (!displayName) { - return undefined; - } - if (performCharacterChecks) { - if (!ts.isIdentifierStart(displayName.charCodeAt(0), target)) { - return undefined; - } - for (var i = 1, n = displayName.length; i < n; i++) { - if (!ts.isIdentifierPart(displayName.charCodeAt(i), target)) { - return undefined; - } - } - } - return ts.unescapeIdentifier(displayName); - } - function getCompletionData(fileName, position) { - var typeChecker = program.getTypeChecker(); - var syntacticStart = new Date().getTime(); - var sourceFile = getValidSourceFile(fileName); - var isJavaScriptFile = ts.isJavaScript(fileName); - var start = new Date().getTime(); - var currentToken = ts.getTokenAtPosition(sourceFile, position); - log("getCompletionData: Get current token: " + (new Date().getTime() - start)); - start = new Date().getTime(); - // Completion not allowed inside comments, bail out if this is the case - var insideComment = isInsideComment(sourceFile, currentToken, position); - log("getCompletionData: Is inside comment: " + (new Date().getTime() - start)); - if (insideComment) { - log("Returning an empty list because completion was inside a comment."); - return undefined; - } - start = new Date().getTime(); - var previousToken = ts.findPrecedingToken(position, sourceFile); - log("getCompletionData: Get previous token 1: " + (new Date().getTime() - start)); - // The decision to provide completion depends on the contextToken, which is determined through the previousToken. - // Note: 'previousToken' (and thus 'contextToken') can be undefined if we are the beginning of the file - var contextToken = previousToken; - // Check if the caret is at the end of an identifier; this is a partial identifier that we want to complete: e.g. a.toS| - // Skip this partial identifier and adjust the contextToken to the token that precedes it. - if (contextToken && position <= contextToken.end && ts.isWord(contextToken.kind)) { - var start_2 = new Date().getTime(); - contextToken = ts.findPrecedingToken(contextToken.getFullStart(), sourceFile); - log("getCompletionData: Get previous token 2: " + (new Date().getTime() - start_2)); - } - // Check if this is a valid completion location - if (contextToken && isCompletionListBlocker(contextToken)) { - log("Returning an empty list because completion was requested in an invalid position."); - return undefined; - } - // Find the node where completion is requested on, in the case of a completion after - // a dot, it is the member access expression other wise, it is a request for all - // visible symbols in the scope, and the node is the current location. - var node = currentToken; - var isRightOfDot = false; - if (contextToken && contextToken.kind === 20 /* DotToken */ && contextToken.parent.kind === 158 /* PropertyAccessExpression */) { - node = contextToken.parent.expression; - isRightOfDot = true; - } - else if (contextToken && contextToken.kind === 20 /* DotToken */ && contextToken.parent.kind === 128 /* QualifiedName */) { - node = contextToken.parent.left; - isRightOfDot = true; - } - var location = ts.getTouchingPropertyName(sourceFile, position); - var target = program.getCompilerOptions().target; - var semanticStart = new Date().getTime(); - var isMemberCompletion; - var isNewIdentifierLocation; - var symbols = []; - if (isRightOfDot) { - getTypeScriptMemberSymbols(); - } - else { - // For JavaScript or TypeScript, if we're not after a dot, then just try to get the - // global symbols in scope. These results should be valid for either language as - // the set of symbols that can be referenced from this location. - if (!tryGetGlobalSymbols()) { - return undefined; - } - } - log("getCompletionData: Semantic work: " + (new Date().getTime() - semanticStart)); - return { symbols: symbols, isMemberCompletion: isMemberCompletion, isNewIdentifierLocation: isNewIdentifierLocation, location: location, isRightOfDot: isRightOfDot }; - function getTypeScriptMemberSymbols() { - // Right of dot member completion list - isMemberCompletion = true; - isNewIdentifierLocation = false; - if (node.kind === 65 /* Identifier */ || node.kind === 128 /* QualifiedName */ || node.kind === 158 /* PropertyAccessExpression */) { - var symbol = typeChecker.getSymbolAtLocation(node); - // This is an alias, follow what it aliases - if (symbol && symbol.flags & 8388608 /* Alias */) { - symbol = typeChecker.getAliasedSymbol(symbol); - } - if (symbol && symbol.flags & 1952 /* HasExports */) { - // Extract module or enum members - var exportedSymbols = typeChecker.getExportsOfModule(symbol); - ts.forEach(exportedSymbols, function (symbol) { - if (typeChecker.isValidPropertyAccess((node.parent), symbol.name)) { - symbols.push(symbol); - } - }); - } - } - var type = typeChecker.getTypeAtLocation(node); - addTypeProperties(type); - } - function addTypeProperties(type) { - if (type) { - // Filter private properties - for (var _i = 0, _a = type.getApparentProperties(); _i < _a.length; _i++) { - var symbol = _a[_i]; - if (typeChecker.isValidPropertyAccess((node.parent), symbol.name)) { - symbols.push(symbol); - } - } - if (isJavaScriptFile && type.flags & 16384 /* Union */) { - // In javascript files, for union types, we don't just get the members that - // the individual types have in common, we also include all the members that - // each individual type has. This is because we're going to add all identifiers - // anyways. So we might as well elevate the members that were at least part - // of the individual types to a higher status since we know what they are. - var unionType = type; - for (var _b = 0, _c = unionType.types; _b < _c.length; _b++) { - var elementType = _c[_b]; - addTypeProperties(elementType); - } - } - } - } - function tryGetGlobalSymbols() { - var containingObjectLiteral = getContainingObjectLiteralApplicableForCompletion(contextToken); - if (containingObjectLiteral) { - // Object literal expression, look up possible property names from contextual type - isMemberCompletion = true; - isNewIdentifierLocation = true; - var contextualType = typeChecker.getContextualType(containingObjectLiteral); - if (!contextualType) { - return false; - } - var contextualTypeMembers = typeChecker.getPropertiesOfType(contextualType); - if (contextualTypeMembers && contextualTypeMembers.length > 0) { - // Add filtered items to the completion list - symbols = filterContextualMembersList(contextualTypeMembers, containingObjectLiteral.properties); - } - } - else if (ts.getAncestor(contextToken, 213 /* ImportClause */)) { - // cursor is in import clause - // try to show exported member for imported module - isMemberCompletion = true; - isNewIdentifierLocation = true; - if (showCompletionsInImportsClause(contextToken)) { - var importDeclaration = ts.getAncestor(contextToken, 212 /* ImportDeclaration */); - ts.Debug.assert(importDeclaration !== undefined); - var exports; - if (importDeclaration.moduleSpecifier) { - var moduleSpecifierSymbol = typeChecker.getSymbolAtLocation(importDeclaration.moduleSpecifier); - if (moduleSpecifierSymbol) { - exports = typeChecker.getExportsOfModule(moduleSpecifierSymbol); - } - } - //let exports = typeInfoResolver.getExportsOfImportDeclaration(importDeclaration); - symbols = exports ? filterModuleExports(exports, importDeclaration) : emptyArray; - } - } - else { - // Get all entities in the current scope. - isMemberCompletion = false; - isNewIdentifierLocation = isNewIdentifierDefinitionLocation(contextToken); - if (previousToken !== contextToken) { - ts.Debug.assert(!!previousToken, "Expected 'contextToken' to be defined when different from 'previousToken'."); - } - // We need to find the node that will give us an appropriate scope to begin - // aggregating completion candidates. This is achieved in 'getScopeNode' - // by finding the first node that encompasses a position, accounting for whether a node - // is "complete" to decide whether a position belongs to the node. - // - // However, at the end of an identifier, we are interested in the scope of the identifier - // itself, but fall outside of the identifier. For instance: - // - // xyz => x$ - // - // the cursor is outside of both the 'x' and the arrow function 'xyz => x', - // so 'xyz' is not returned in our results. - // - // We define 'adjustedPosition' so that we may appropriately account for - // being at the end of an identifier. The intention is that if requesting completion - // at the end of an identifier, it should be effectively equivalent to requesting completion - // anywhere inside/at the beginning of the identifier. So in the previous case, the - // 'adjustedPosition' will work as if requesting completion in the following: - // - // xyz => $x - // - // If previousToken !== contextToken, then - // - 'contextToken' was adjusted to the token prior to 'previousToken' - // because we were at the end of an identifier. - // - 'previousToken' is defined. - var adjustedPosition = previousToken !== contextToken ? - previousToken.getStart() : - position; - var scopeNode = getScopeNode(contextToken, adjustedPosition, sourceFile) || sourceFile; - /// TODO filter meaning based on the current context - var symbolMeanings = 793056 /* Type */ | 107455 /* Value */ | 1536 /* Namespace */ | 8388608 /* Alias */; - symbols = typeChecker.getSymbolsInScope(scopeNode, symbolMeanings); - } - return true; - } - /** - * Finds the first node that "embraces" the position, so that one may - * accurately aggregate locals from the closest containing scope. - */ - function getScopeNode(initialToken, position, sourceFile) { - var scope = initialToken; - while (scope && !ts.positionBelongsToNode(scope, position, sourceFile)) { - scope = scope.parent; - } - return scope; - } - function isCompletionListBlocker(previousToken) { - var start = new Date().getTime(); - var result = isInStringOrRegularExpressionOrTemplateLiteral(previousToken) || - isIdentifierDefinitionLocation(previousToken) || - isRightOfIllegalDot(previousToken); - log("getCompletionsAtPosition: isCompletionListBlocker: " + (new Date().getTime() - start)); - return result; - } - function showCompletionsInImportsClause(node) { - if (node) { - // import {| - // import {a,| - if (node.kind === 14 /* OpenBraceToken */ || node.kind === 23 /* CommaToken */) { - return node.parent.kind === 215 /* NamedImports */; - } - } - return false; - } - function isNewIdentifierDefinitionLocation(previousToken) { - if (previousToken) { - var containingNodeKind = previousToken.parent.kind; - switch (previousToken.kind) { - case 23 /* CommaToken */: - return containingNodeKind === 160 /* CallExpression */ // func( a, | - || containingNodeKind === 137 /* Constructor */ // constructor( a, | public, protected, private keywords are allowed here, so show completion - || containingNodeKind === 161 /* NewExpression */ // new C(a, | - || containingNodeKind === 156 /* ArrayLiteralExpression */ // [a, | - || containingNodeKind === 172 /* BinaryExpression */ // let x = (a, | - || containingNodeKind === 145 /* FunctionType */; // var x: (s: string, list| - case 16 /* OpenParenToken */: - return containingNodeKind === 160 /* CallExpression */ // func( | - || containingNodeKind === 137 /* Constructor */ // constructor( | - || containingNodeKind === 161 /* NewExpression */ // new C(a| - || containingNodeKind === 164 /* ParenthesizedExpression */ // let x = (a| - || containingNodeKind === 152 /* ParenthesizedType */; // function F(pred: (a| this can become an arrow function, where 'a' is the argument - case 18 /* OpenBracketToken */: - return containingNodeKind === 156 /* ArrayLiteralExpression */; // [ | - case 118 /* ModuleKeyword */: // module | - case 119 /* NamespaceKeyword */: - return true; - case 20 /* DotToken */: - return containingNodeKind === 208 /* ModuleDeclaration */; // module A.| - case 14 /* OpenBraceToken */: - return containingNodeKind === 204 /* ClassDeclaration */; // class A{ | - case 53 /* EqualsToken */: - return containingNodeKind === 201 /* VariableDeclaration */ // let x = a| - || containingNodeKind === 172 /* BinaryExpression */; // x = a| - case 11 /* TemplateHead */: - return containingNodeKind === 174 /* TemplateExpression */; // `aa ${| - case 12 /* TemplateMiddle */: - return containingNodeKind === 180 /* TemplateSpan */; // `aa ${10} dd ${| - case 108 /* PublicKeyword */: - case 106 /* PrivateKeyword */: - case 107 /* ProtectedKeyword */: - return containingNodeKind === 134 /* PropertyDeclaration */; // class A{ public | - } - // Previous token may have been a keyword that was converted to an identifier. - switch (previousToken.getText()) { - case "public": - case "protected": - case "private": - return true; - } - } - return false; - } - function isInStringOrRegularExpressionOrTemplateLiteral(previousToken) { - if (previousToken.kind === 8 /* StringLiteral */ - || previousToken.kind === 9 /* RegularExpressionLiteral */ - || ts.isTemplateLiteralKind(previousToken.kind)) { - var start_3 = previousToken.getStart(); - var end = previousToken.getEnd(); - // To be "in" one of these literals, the position has to be: - // 1. entirely within the token text. - // 2. at the end position of an unterminated token. - // 3. at the end of a regular expression (due to trailing flags like '/foo/g'). - if (start_3 < position && position < end) { - return true; - } - if (position === end) { - return !!previousToken.isUnterminated || - previousToken.kind === 9 /* RegularExpressionLiteral */; - } - } - return false; - } - function getContainingObjectLiteralApplicableForCompletion(previousToken) { - // The locations in an object literal expression that are applicable for completion are property name definition locations. - if (previousToken) { - var parent_10 = previousToken.parent; - switch (previousToken.kind) { - case 14 /* OpenBraceToken */: // let x = { | - case 23 /* CommaToken */: - if (parent_10 && parent_10.kind === 157 /* ObjectLiteralExpression */) { - return parent_10; - } - break; - } - } - return undefined; - } - function isFunction(kind) { - switch (kind) { - case 165 /* FunctionExpression */: - case 166 /* ArrowFunction */: - case 203 /* FunctionDeclaration */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 140 /* CallSignature */: - case 141 /* ConstructSignature */: - case 142 /* IndexSignature */: - return true; - } - return false; - } - function isIdentifierDefinitionLocation(previousToken) { - if (previousToken) { - var containingNodeKind = previousToken.parent.kind; - switch (previousToken.kind) { - case 23 /* CommaToken */: - return containingNodeKind === 201 /* VariableDeclaration */ || - containingNodeKind === 202 /* VariableDeclarationList */ || - containingNodeKind === 183 /* VariableStatement */ || - containingNodeKind === 207 /* EnumDeclaration */ || - isFunction(containingNodeKind) || - containingNodeKind === 204 /* ClassDeclaration */ || - containingNodeKind === 203 /* FunctionDeclaration */ || - containingNodeKind === 205 /* InterfaceDeclaration */ || - containingNodeKind === 154 /* ArrayBindingPattern */ || - containingNodeKind === 153 /* ObjectBindingPattern */; // function func({ x, y| - case 20 /* DotToken */: - return containingNodeKind === 154 /* ArrayBindingPattern */; // var [.| - case 51 /* ColonToken */: - return containingNodeKind === 155 /* BindingElement */; // var {x :html| - case 18 /* OpenBracketToken */: - return containingNodeKind === 154 /* ArrayBindingPattern */; // var [x| - case 16 /* OpenParenToken */: - return containingNodeKind === 226 /* CatchClause */ || - isFunction(containingNodeKind); - case 14 /* OpenBraceToken */: - return containingNodeKind === 207 /* EnumDeclaration */ || - containingNodeKind === 205 /* InterfaceDeclaration */ || - containingNodeKind === 148 /* TypeLiteral */ || - containingNodeKind === 153 /* ObjectBindingPattern */; // function func({ x| - case 22 /* SemicolonToken */: - return containingNodeKind === 133 /* PropertySignature */ && - previousToken.parent && previousToken.parent.parent && - (previousToken.parent.parent.kind === 205 /* InterfaceDeclaration */ || - previousToken.parent.parent.kind === 148 /* TypeLiteral */); // let x : { a; | - case 24 /* LessThanToken */: - return containingNodeKind === 204 /* ClassDeclaration */ || - containingNodeKind === 203 /* FunctionDeclaration */ || - containingNodeKind === 205 /* InterfaceDeclaration */ || - isFunction(containingNodeKind); - case 109 /* StaticKeyword */: - return containingNodeKind === 134 /* PropertyDeclaration */; - case 21 /* DotDotDotToken */: - return containingNodeKind === 131 /* Parameter */ || - containingNodeKind === 137 /* Constructor */ || - (previousToken.parent && previousToken.parent.parent && - previousToken.parent.parent.kind === 154 /* ArrayBindingPattern */); // var [...z| - case 108 /* PublicKeyword */: - case 106 /* PrivateKeyword */: - case 107 /* ProtectedKeyword */: - return containingNodeKind === 131 /* Parameter */; - case 69 /* ClassKeyword */: - case 77 /* EnumKeyword */: - case 103 /* InterfaceKeyword */: - case 83 /* FunctionKeyword */: - case 98 /* VarKeyword */: - case 116 /* GetKeyword */: - case 122 /* SetKeyword */: - case 85 /* ImportKeyword */: - case 104 /* LetKeyword */: - case 70 /* ConstKeyword */: - case 110 /* YieldKeyword */: - case 125 /* TypeKeyword */: - return true; - } - // Previous token may have been a keyword that was converted to an identifier. - switch (previousToken.getText()) { - case "class": - case "interface": - case "enum": - case "function": - case "var": - case "static": - case "let": - case "const": - case "yield": - return true; - } - } - return false; - } - function isRightOfIllegalDot(previousToken) { - if (previousToken && previousToken.kind === 7 /* NumericLiteral */) { - var text = previousToken.getFullText(); - return text.charAt(text.length - 1) === "."; - } - return false; - } - function filterModuleExports(exports, importDeclaration) { - var exisingImports = {}; - if (!importDeclaration.importClause) { - return exports; - } - if (importDeclaration.importClause.namedBindings && - importDeclaration.importClause.namedBindings.kind === 215 /* NamedImports */) { - ts.forEach(importDeclaration.importClause.namedBindings.elements, function (el) { - var name = el.propertyName || el.name; - exisingImports[name.text] = true; - }); - } - if (ts.isEmpty(exisingImports)) { - return exports; - } - return ts.filter(exports, function (e) { return !ts.lookUp(exisingImports, e.name); }); - } - function filterContextualMembersList(contextualMemberSymbols, existingMembers) { - if (!existingMembers || existingMembers.length === 0) { - return contextualMemberSymbols; - } - var existingMemberNames = {}; - ts.forEach(existingMembers, function (m) { - if (m.kind !== 227 /* PropertyAssignment */ && m.kind !== 228 /* ShorthandPropertyAssignment */) { - // Ignore omitted expressions for missing members in the object literal - return; - } - if (m.getStart() <= position && position <= m.getEnd()) { - // If this is the current item we are editing right now, do not filter it out - return; - } - // TODO(jfreeman): Account for computed property name - existingMemberNames[m.name.text] = true; - }); - var filteredMembers = []; - ts.forEach(contextualMemberSymbols, function (s) { - if (!existingMemberNames[s.name]) { - filteredMembers.push(s); - } - }); - return filteredMembers; - } - } - function getCompletionsAtPosition(fileName, position) { - synchronizeHostData(); - var completionData = getCompletionData(fileName, position); - if (!completionData) { - return undefined; - } - var symbols = completionData.symbols, isMemberCompletion = completionData.isMemberCompletion, isNewIdentifierLocation = completionData.isNewIdentifierLocation, location = completionData.location, isRightOfDot = completionData.isRightOfDot; - var entries; - if (isRightOfDot && ts.isJavaScript(fileName)) { - entries = getCompletionEntriesFromSymbols(symbols); - ts.addRange(entries, getJavaScriptCompletionEntries()); - } - else { - if (!symbols || symbols.length === 0) { - return undefined; - } - entries = getCompletionEntriesFromSymbols(symbols); - } - // Add keywords if this is not a member completion list - if (!isMemberCompletion) { - ts.addRange(entries, keywordCompletions); - } - return { isMemberCompletion: isMemberCompletion, isNewIdentifierLocation: isNewIdentifierLocation, entries: entries }; - function getJavaScriptCompletionEntries() { - var entries = []; - var allNames = {}; - var target = program.getCompilerOptions().target; - for (var _i = 0, _a = program.getSourceFiles(); _i < _a.length; _i++) { - var sourceFile = _a[_i]; - var nameTable = getNameTable(sourceFile); - for (var name_30 in nameTable) { - if (!allNames[name_30]) { - allNames[name_30] = name_30; - var displayName = getCompletionEntryDisplayName(name_30, target, true); - if (displayName) { - var entry = { - name: displayName, - kind: ScriptElementKind.warning, - kindModifiers: "", - sortText: "1" - }; - entries.push(entry); - } - } - } - } - return entries; - } - function createCompletionEntry(symbol, location) { - // Try to get a valid display name for this symbol, if we could not find one, then ignore it. - // We would like to only show things that can be added after a dot, so for instance numeric properties can - // not be accessed with a dot (a.1 <- invalid) - var displayName = getCompletionEntryDisplayNameForSymbol(symbol, program.getCompilerOptions().target, true); - if (!displayName) { - return undefined; - } - // TODO(drosen): Right now we just permit *all* semantic meanings when calling - // 'getSymbolKind' which is permissible given that it is backwards compatible; but - // really we should consider passing the meaning for the node so that we don't report - // that a suggestion for a value is an interface. We COULD also just do what - // 'getSymbolModifiers' does, which is to use the first declaration. - // Use a 'sortText' of 0' so that all symbol completion entries come before any other - // entries (like JavaScript identifier entries). - return { - name: displayName, - kind: getSymbolKind(symbol, location), - kindModifiers: getSymbolModifiers(symbol), - sortText: "0" - }; - } - function getCompletionEntriesFromSymbols(symbols) { - var start = new Date().getTime(); - var entries = []; - if (symbols) { - var nameToSymbol = {}; - for (var _i = 0; _i < symbols.length; _i++) { - var symbol = symbols[_i]; - var entry = createCompletionEntry(symbol, location); - if (entry) { - var id = ts.escapeIdentifier(entry.name); - if (!ts.lookUp(nameToSymbol, id)) { - entries.push(entry); - nameToSymbol[id] = symbol; - } - } - } - } - log("getCompletionsAtPosition: getCompletionEntriesFromSymbols: " + (new Date().getTime() - start)); - return entries; - } - } - function getCompletionEntryDetails(fileName, position, entryName) { - synchronizeHostData(); - // Compute all the completion symbols again. - var completionData = getCompletionData(fileName, position); - if (completionData) { - var symbols = completionData.symbols, location_2 = completionData.location; - // Find the symbol with the matching entry name. - var target = program.getCompilerOptions().target; - // We don't need to perform character checks here because we're only comparing the - // name against 'entryName' (which is known to be good), not building a new - // completion entry. - var symbol = ts.forEach(symbols, function (s) { return getCompletionEntryDisplayNameForSymbol(s, target, false) === entryName ? s : undefined; }); - if (symbol) { - var displayPartsDocumentationsAndSymbolKind = getSymbolDisplayPartsDocumentationAndSymbolKind(symbol, getValidSourceFile(fileName), location_2, location_2, 7 /* All */); - return { - name: entryName, - kind: displayPartsDocumentationsAndSymbolKind.symbolKind, - kindModifiers: getSymbolModifiers(symbol), - displayParts: displayPartsDocumentationsAndSymbolKind.displayParts, - documentation: displayPartsDocumentationsAndSymbolKind.documentation - }; - } - } - // Didn't find a symbol with this name. See if we can find a keyword instead. - var keywordCompletion = ts.forEach(keywordCompletions, function (c) { return c.name === entryName; }); - if (keywordCompletion) { - return { - name: entryName, - kind: ScriptElementKind.keyword, - kindModifiers: ScriptElementKindModifier.none, - displayParts: [ts.displayPart(entryName, SymbolDisplayPartKind.keyword)], - documentation: undefined - }; - } - return undefined; - } - // TODO(drosen): use contextual SemanticMeaning. - function getSymbolKind(symbol, location) { - var flags = symbol.getFlags(); - if (flags & 32 /* Class */) - return ScriptElementKind.classElement; - if (flags & 384 /* Enum */) - return ScriptElementKind.enumElement; - if (flags & 524288 /* TypeAlias */) - return ScriptElementKind.typeElement; - if (flags & 64 /* Interface */) - return ScriptElementKind.interfaceElement; - if (flags & 262144 /* TypeParameter */) - return ScriptElementKind.typeParameterElement; - var result = getSymbolKindOfConstructorPropertyMethodAccessorFunctionOrVar(symbol, flags, location); - if (result === ScriptElementKind.unknown) { - if (flags & 262144 /* TypeParameter */) - return ScriptElementKind.typeParameterElement; - if (flags & 8 /* EnumMember */) - return ScriptElementKind.variableElement; - if (flags & 8388608 /* Alias */) - return ScriptElementKind.alias; - if (flags & 1536 /* Module */) - return ScriptElementKind.moduleElement; - } - return result; - } - function getSymbolKindOfConstructorPropertyMethodAccessorFunctionOrVar(symbol, flags, location) { - var typeChecker = program.getTypeChecker(); - if (typeChecker.isUndefinedSymbol(symbol)) { - return ScriptElementKind.variableElement; - } - if (typeChecker.isArgumentsSymbol(symbol)) { - return ScriptElementKind.localVariableElement; - } - if (flags & 3 /* Variable */) { - if (ts.isFirstDeclarationOfSymbolParameter(symbol)) { - return ScriptElementKind.parameterElement; - } - else if (symbol.valueDeclaration && ts.isConst(symbol.valueDeclaration)) { - return ScriptElementKind.constElement; - } - else if (ts.forEach(symbol.declarations, ts.isLet)) { - return ScriptElementKind.letElement; - } - return isLocalVariableOrFunction(symbol) ? ScriptElementKind.localVariableElement : ScriptElementKind.variableElement; - } - if (flags & 16 /* Function */) - return isLocalVariableOrFunction(symbol) ? ScriptElementKind.localFunctionElement : ScriptElementKind.functionElement; - if (flags & 32768 /* GetAccessor */) - return ScriptElementKind.memberGetAccessorElement; - if (flags & 65536 /* SetAccessor */) - return ScriptElementKind.memberSetAccessorElement; - if (flags & 8192 /* Method */) - return ScriptElementKind.memberFunctionElement; - if (flags & 16384 /* Constructor */) - return ScriptElementKind.constructorImplementationElement; - if (flags & 4 /* Property */) { - if (flags & 268435456 /* UnionProperty */) { - // If union property is result of union of non method (property/accessors/variables), it is labeled as property - var unionPropertyKind = ts.forEach(typeChecker.getRootSymbols(symbol), function (rootSymbol) { - var rootSymbolFlags = rootSymbol.getFlags(); - if (rootSymbolFlags & (98308 /* PropertyOrAccessor */ | 3 /* Variable */)) { - return ScriptElementKind.memberVariableElement; - } - ts.Debug.assert(!!(rootSymbolFlags & 8192 /* Method */)); - }); - if (!unionPropertyKind) { - // If this was union of all methods, - //make sure it has call signatures before we can label it as method - var typeOfUnionProperty = typeChecker.getTypeOfSymbolAtLocation(symbol, location); - if (typeOfUnionProperty.getCallSignatures().length) { - return ScriptElementKind.memberFunctionElement; - } - return ScriptElementKind.memberVariableElement; - } - return unionPropertyKind; - } - return ScriptElementKind.memberVariableElement; - } - return ScriptElementKind.unknown; - } - function getSymbolModifiers(symbol) { - return symbol && symbol.declarations && symbol.declarations.length > 0 - ? ts.getNodeModifiers(symbol.declarations[0]) - : ScriptElementKindModifier.none; - } - // TODO(drosen): Currently completion entry details passes the SemanticMeaning.All instead of using semanticMeaning of location - function getSymbolDisplayPartsDocumentationAndSymbolKind(symbol, sourceFile, enclosingDeclaration, location, semanticMeaning) { - if (semanticMeaning === void 0) { semanticMeaning = getMeaningFromLocation(location); } - var typeChecker = program.getTypeChecker(); - var displayParts = []; - var documentation; - var symbolFlags = symbol.flags; - var symbolKind = getSymbolKindOfConstructorPropertyMethodAccessorFunctionOrVar(symbol, symbolFlags, location); - var hasAddedSymbolInfo; - var type; - // Class at constructor site need to be shown as constructor apart from property,method, vars - if (symbolKind !== ScriptElementKind.unknown || symbolFlags & 32 /* Class */ || symbolFlags & 8388608 /* Alias */) { - // If it is accessor they are allowed only if location is at name of the accessor - if (symbolKind === ScriptElementKind.memberGetAccessorElement || symbolKind === ScriptElementKind.memberSetAccessorElement) { - symbolKind = ScriptElementKind.memberVariableElement; - } - var signature; - type = typeChecker.getTypeOfSymbolAtLocation(symbol, location); - if (type) { - if (location.parent && location.parent.kind === 158 /* PropertyAccessExpression */) { - var right = location.parent.name; - // Either the location is on the right of a property access, or on the left and the right is missing - if (right === location || (right && right.getFullWidth() === 0)) { - location = location.parent; - } - } - // try get the call/construct signature from the type if it matches - var callExpression; - if (location.kind === 160 /* CallExpression */ || location.kind === 161 /* NewExpression */) { - callExpression = location; - } - else if (isCallExpressionTarget(location) || isNewExpressionTarget(location)) { - callExpression = location.parent; - } - if (callExpression) { - var candidateSignatures = []; - signature = typeChecker.getResolvedSignature(callExpression, candidateSignatures); - if (!signature && candidateSignatures.length) { - // Use the first candidate: - signature = candidateSignatures[0]; - } - var useConstructSignatures = callExpression.kind === 161 /* NewExpression */ || callExpression.expression.kind === 91 /* SuperKeyword */; - var allSignatures = useConstructSignatures ? type.getConstructSignatures() : type.getCallSignatures(); - if (!ts.contains(allSignatures, signature.target || signature)) { - // Get the first signature if there - signature = allSignatures.length ? allSignatures[0] : undefined; - } - if (signature) { - if (useConstructSignatures && (symbolFlags & 32 /* Class */)) { - // Constructor - symbolKind = ScriptElementKind.constructorImplementationElement; - addPrefixForAnyFunctionOrVar(type.symbol, symbolKind); - } - else if (symbolFlags & 8388608 /* Alias */) { - symbolKind = ScriptElementKind.alias; - pushTypePart(symbolKind); - displayParts.push(ts.spacePart()); - if (useConstructSignatures) { - displayParts.push(ts.keywordPart(88 /* NewKeyword */)); - displayParts.push(ts.spacePart()); - } - addFullSymbolName(symbol); - } - else { - addPrefixForAnyFunctionOrVar(symbol, symbolKind); - } - switch (symbolKind) { - case ScriptElementKind.memberVariableElement: - case ScriptElementKind.variableElement: - case ScriptElementKind.constElement: - case ScriptElementKind.letElement: - case ScriptElementKind.parameterElement: - case ScriptElementKind.localVariableElement: - // If it is call or construct signature of lambda's write type name - displayParts.push(ts.punctuationPart(51 /* ColonToken */)); - displayParts.push(ts.spacePart()); - if (useConstructSignatures) { - displayParts.push(ts.keywordPart(88 /* NewKeyword */)); - displayParts.push(ts.spacePart()); - } - if (!(type.flags & 32768 /* Anonymous */)) { - displayParts.push.apply(displayParts, ts.symbolToDisplayParts(typeChecker, type.symbol, enclosingDeclaration, undefined, 1 /* WriteTypeParametersOrArguments */)); - } - addSignatureDisplayParts(signature, allSignatures, 8 /* WriteArrowStyleSignature */); - break; - default: - // Just signature - addSignatureDisplayParts(signature, allSignatures); - } - hasAddedSymbolInfo = true; - } - } - else if ((isNameOfFunctionDeclaration(location) && !(symbol.flags & 98304 /* Accessor */)) || - (location.kind === 114 /* ConstructorKeyword */ && location.parent.kind === 137 /* Constructor */)) { - // get the signature from the declaration and write it - var functionDeclaration = location.parent; - var allSignatures = functionDeclaration.kind === 137 /* Constructor */ ? type.getConstructSignatures() : type.getCallSignatures(); - if (!typeChecker.isImplementationOfOverload(functionDeclaration)) { - signature = typeChecker.getSignatureFromDeclaration(functionDeclaration); - } - else { - signature = allSignatures[0]; - } - if (functionDeclaration.kind === 137 /* Constructor */) { - // show (constructor) Type(...) signature - symbolKind = ScriptElementKind.constructorImplementationElement; - addPrefixForAnyFunctionOrVar(type.symbol, symbolKind); - } - else { - // (function/method) symbol(..signature) - addPrefixForAnyFunctionOrVar(functionDeclaration.kind === 140 /* CallSignature */ && - !(type.symbol.flags & 2048 /* TypeLiteral */ || type.symbol.flags & 4096 /* ObjectLiteral */) ? type.symbol : symbol, symbolKind); - } - addSignatureDisplayParts(signature, allSignatures); - hasAddedSymbolInfo = true; - } - } - } - if (symbolFlags & 32 /* Class */ && !hasAddedSymbolInfo) { - displayParts.push(ts.keywordPart(69 /* ClassKeyword */)); - displayParts.push(ts.spacePart()); - addFullSymbolName(symbol); - writeTypeParametersOfSymbol(symbol, sourceFile); - } - if ((symbolFlags & 64 /* Interface */) && (semanticMeaning & 2 /* Type */)) { - addNewLineIfDisplayPartsExist(); - displayParts.push(ts.keywordPart(103 /* InterfaceKeyword */)); - displayParts.push(ts.spacePart()); - addFullSymbolName(symbol); - writeTypeParametersOfSymbol(symbol, sourceFile); - } - if (symbolFlags & 524288 /* TypeAlias */) { - addNewLineIfDisplayPartsExist(); - displayParts.push(ts.keywordPart(125 /* TypeKeyword */)); - displayParts.push(ts.spacePart()); - addFullSymbolName(symbol); - displayParts.push(ts.spacePart()); - displayParts.push(ts.operatorPart(53 /* EqualsToken */)); - displayParts.push(ts.spacePart()); - displayParts.push.apply(displayParts, ts.typeToDisplayParts(typeChecker, typeChecker.getDeclaredTypeOfSymbol(symbol), enclosingDeclaration)); - } - if (symbolFlags & 384 /* Enum */) { - addNewLineIfDisplayPartsExist(); - if (ts.forEach(symbol.declarations, ts.isConstEnumDeclaration)) { - displayParts.push(ts.keywordPart(70 /* ConstKeyword */)); - displayParts.push(ts.spacePart()); - } - displayParts.push(ts.keywordPart(77 /* EnumKeyword */)); - displayParts.push(ts.spacePart()); - addFullSymbolName(symbol); - } - if (symbolFlags & 1536 /* Module */) { - addNewLineIfDisplayPartsExist(); - var declaration = ts.getDeclarationOfKind(symbol, 208 /* ModuleDeclaration */); - var isNamespace = declaration && declaration.name && declaration.name.kind === 65 /* Identifier */; - displayParts.push(ts.keywordPart(isNamespace ? 119 /* NamespaceKeyword */ : 118 /* ModuleKeyword */)); - displayParts.push(ts.spacePart()); - addFullSymbolName(symbol); - } - if ((symbolFlags & 262144 /* TypeParameter */) && (semanticMeaning & 2 /* Type */)) { - addNewLineIfDisplayPartsExist(); - displayParts.push(ts.punctuationPart(16 /* OpenParenToken */)); - displayParts.push(ts.textPart("type parameter")); - displayParts.push(ts.punctuationPart(17 /* CloseParenToken */)); - displayParts.push(ts.spacePart()); - addFullSymbolName(symbol); - displayParts.push(ts.spacePart()); - displayParts.push(ts.keywordPart(86 /* InKeyword */)); - displayParts.push(ts.spacePart()); - if (symbol.parent) { - // Class/Interface type parameter - addFullSymbolName(symbol.parent, enclosingDeclaration); - writeTypeParametersOfSymbol(symbol.parent, enclosingDeclaration); - } - else { - // Method/function type parameter - var signatureDeclaration = ts.getDeclarationOfKind(symbol, 130 /* TypeParameter */).parent; - var signature = typeChecker.getSignatureFromDeclaration(signatureDeclaration); - if (signatureDeclaration.kind === 141 /* ConstructSignature */) { - displayParts.push(ts.keywordPart(88 /* NewKeyword */)); - displayParts.push(ts.spacePart()); - } - else if (signatureDeclaration.kind !== 140 /* CallSignature */ && signatureDeclaration.name) { - addFullSymbolName(signatureDeclaration.symbol); - } - displayParts.push.apply(displayParts, ts.signatureToDisplayParts(typeChecker, signature, sourceFile, 32 /* WriteTypeArgumentsOfSignature */)); - } - } - if (symbolFlags & 8 /* EnumMember */) { - addPrefixForAnyFunctionOrVar(symbol, "enum member"); - var declaration = symbol.declarations[0]; - if (declaration.kind === 229 /* EnumMember */) { - var constantValue = typeChecker.getConstantValue(declaration); - if (constantValue !== undefined) { - displayParts.push(ts.spacePart()); - displayParts.push(ts.operatorPart(53 /* EqualsToken */)); - displayParts.push(ts.spacePart()); - displayParts.push(ts.displayPart(constantValue.toString(), SymbolDisplayPartKind.numericLiteral)); - } - } - } - if (symbolFlags & 8388608 /* Alias */) { - addNewLineIfDisplayPartsExist(); - displayParts.push(ts.keywordPart(85 /* ImportKeyword */)); - displayParts.push(ts.spacePart()); - addFullSymbolName(symbol); - ts.forEach(symbol.declarations, function (declaration) { - if (declaration.kind === 211 /* ImportEqualsDeclaration */) { - var importEqualsDeclaration = declaration; - if (ts.isExternalModuleImportEqualsDeclaration(importEqualsDeclaration)) { - displayParts.push(ts.spacePart()); - displayParts.push(ts.operatorPart(53 /* EqualsToken */)); - displayParts.push(ts.spacePart()); - displayParts.push(ts.keywordPart(120 /* RequireKeyword */)); - displayParts.push(ts.punctuationPart(16 /* OpenParenToken */)); - displayParts.push(ts.displayPart(ts.getTextOfNode(ts.getExternalModuleImportEqualsDeclarationExpression(importEqualsDeclaration)), SymbolDisplayPartKind.stringLiteral)); - displayParts.push(ts.punctuationPart(17 /* CloseParenToken */)); - } - else { - var internalAliasSymbol = typeChecker.getSymbolAtLocation(importEqualsDeclaration.moduleReference); - if (internalAliasSymbol) { - displayParts.push(ts.spacePart()); - displayParts.push(ts.operatorPart(53 /* EqualsToken */)); - displayParts.push(ts.spacePart()); - addFullSymbolName(internalAliasSymbol, enclosingDeclaration); - } - } - return true; - } - }); - } - if (!hasAddedSymbolInfo) { - if (symbolKind !== ScriptElementKind.unknown) { - if (type) { - addPrefixForAnyFunctionOrVar(symbol, symbolKind); - // For properties, variables and local vars: show the type - if (symbolKind === ScriptElementKind.memberVariableElement || - symbolFlags & 3 /* Variable */ || - symbolKind === ScriptElementKind.localVariableElement) { - displayParts.push(ts.punctuationPart(51 /* ColonToken */)); - displayParts.push(ts.spacePart()); - // If the type is type parameter, format it specially - if (type.symbol && type.symbol.flags & 262144 /* TypeParameter */) { - var typeParameterParts = ts.mapToDisplayParts(function (writer) { - typeChecker.getSymbolDisplayBuilder().buildTypeParameterDisplay(type, writer, enclosingDeclaration); - }); - displayParts.push.apply(displayParts, typeParameterParts); - } - else { - displayParts.push.apply(displayParts, ts.typeToDisplayParts(typeChecker, type, enclosingDeclaration)); - } - } - else if (symbolFlags & 16 /* Function */ || - symbolFlags & 8192 /* Method */ || - symbolFlags & 16384 /* Constructor */ || - symbolFlags & 131072 /* Signature */ || - symbolFlags & 98304 /* Accessor */ || - symbolKind === ScriptElementKind.memberFunctionElement) { - var allSignatures = type.getCallSignatures(); - addSignatureDisplayParts(allSignatures[0], allSignatures); - } - } - } - else { - symbolKind = getSymbolKind(symbol, location); - } - } - if (!documentation) { - documentation = symbol.getDocumentationComment(); - } - return { displayParts: displayParts, documentation: documentation, symbolKind: symbolKind }; - function addNewLineIfDisplayPartsExist() { - if (displayParts.length) { - displayParts.push(ts.lineBreakPart()); - } - } - function addFullSymbolName(symbol, enclosingDeclaration) { - var fullSymbolDisplayParts = ts.symbolToDisplayParts(typeChecker, symbol, enclosingDeclaration || sourceFile, undefined, 1 /* WriteTypeParametersOrArguments */ | 2 /* UseOnlyExternalAliasing */); - displayParts.push.apply(displayParts, fullSymbolDisplayParts); - } - function addPrefixForAnyFunctionOrVar(symbol, symbolKind) { - addNewLineIfDisplayPartsExist(); - if (symbolKind) { - pushTypePart(symbolKind); - displayParts.push(ts.spacePart()); - addFullSymbolName(symbol); - } - } - function pushTypePart(symbolKind) { - switch (symbolKind) { - case ScriptElementKind.variableElement: - case ScriptElementKind.functionElement: - case ScriptElementKind.letElement: - case ScriptElementKind.constElement: - case ScriptElementKind.constructorImplementationElement: - displayParts.push(ts.textOrKeywordPart(symbolKind)); - return; - default: - displayParts.push(ts.punctuationPart(16 /* OpenParenToken */)); - displayParts.push(ts.textOrKeywordPart(symbolKind)); - displayParts.push(ts.punctuationPart(17 /* CloseParenToken */)); - return; - } - } - function addSignatureDisplayParts(signature, allSignatures, flags) { - displayParts.push.apply(displayParts, ts.signatureToDisplayParts(typeChecker, signature, enclosingDeclaration, flags | 32 /* WriteTypeArgumentsOfSignature */)); - if (allSignatures.length > 1) { - displayParts.push(ts.spacePart()); - displayParts.push(ts.punctuationPart(16 /* OpenParenToken */)); - displayParts.push(ts.operatorPart(33 /* PlusToken */)); - displayParts.push(ts.displayPart((allSignatures.length - 1).toString(), SymbolDisplayPartKind.numericLiteral)); - displayParts.push(ts.spacePart()); - displayParts.push(ts.textPart(allSignatures.length === 2 ? "overload" : "overloads")); - displayParts.push(ts.punctuationPart(17 /* CloseParenToken */)); - } - documentation = signature.getDocumentationComment(); - } - function writeTypeParametersOfSymbol(symbol, enclosingDeclaration) { - var typeParameterParts = ts.mapToDisplayParts(function (writer) { - typeChecker.getSymbolDisplayBuilder().buildTypeParameterDisplayFromSymbol(symbol, writer, enclosingDeclaration); - }); - displayParts.push.apply(displayParts, typeParameterParts); - } - } - function getQuickInfoAtPosition(fileName, position) { - synchronizeHostData(); - var sourceFile = getValidSourceFile(fileName); - var node = ts.getTouchingPropertyName(sourceFile, position); - if (!node) { - return undefined; - } - if (isLabelName(node)) { - return undefined; - } - var typeChecker = program.getTypeChecker(); - var symbol = typeChecker.getSymbolAtLocation(node); - if (!symbol) { - // Try getting just type at this position and show - switch (node.kind) { - case 65 /* Identifier */: - case 158 /* PropertyAccessExpression */: - case 128 /* QualifiedName */: - case 93 /* ThisKeyword */: - case 91 /* SuperKeyword */: - // For the identifiers/this/super etc get the type at position - var type = typeChecker.getTypeAtLocation(node); - if (type) { - return { - kind: ScriptElementKind.unknown, - kindModifiers: ScriptElementKindModifier.none, - textSpan: ts.createTextSpan(node.getStart(), node.getWidth()), - displayParts: ts.typeToDisplayParts(typeChecker, type, getContainerNode(node)), - documentation: type.symbol ? type.symbol.getDocumentationComment() : undefined - }; - } - } - return undefined; - } - var displayPartsDocumentationsAndKind = getSymbolDisplayPartsDocumentationAndSymbolKind(symbol, sourceFile, getContainerNode(node), node); - return { - kind: displayPartsDocumentationsAndKind.symbolKind, - kindModifiers: getSymbolModifiers(symbol), - textSpan: ts.createTextSpan(node.getStart(), node.getWidth()), - displayParts: displayPartsDocumentationsAndKind.displayParts, - documentation: displayPartsDocumentationsAndKind.documentation - }; - } - function createDefinitionInfo(node, symbolKind, symbolName, containerName) { - return { - fileName: node.getSourceFile().fileName, - textSpan: ts.createTextSpanFromBounds(node.getStart(), node.getEnd()), - kind: symbolKind, - name: symbolName, - containerKind: undefined, - containerName: containerName - }; - } - function getDefinitionFromSymbol(symbol, node) { - var typeChecker = program.getTypeChecker(); - var result = []; - var declarations = symbol.getDeclarations(); - var symbolName = typeChecker.symbolToString(symbol); // Do not get scoped name, just the name of the symbol - var symbolKind = getSymbolKind(symbol, node); - var containerSymbol = symbol.parent; - var containerName = containerSymbol ? typeChecker.symbolToString(containerSymbol, node) : ""; - if (!tryAddConstructSignature(symbol, node, symbolKind, symbolName, containerName, result) && - !tryAddCallSignature(symbol, node, symbolKind, symbolName, containerName, result)) { - // Just add all the declarations. - ts.forEach(declarations, function (declaration) { - result.push(createDefinitionInfo(declaration, symbolKind, symbolName, containerName)); - }); - } - return result; - function tryAddConstructSignature(symbol, location, symbolKind, symbolName, containerName, result) { - // Applicable only if we are in a new expression, or we are on a constructor declaration - // and in either case the symbol has a construct signature definition, i.e. class - if (isNewExpressionTarget(location) || location.kind === 114 /* ConstructorKeyword */) { - if (symbol.flags & 32 /* Class */) { - var classDeclaration = symbol.getDeclarations()[0]; - ts.Debug.assert(classDeclaration && classDeclaration.kind === 204 /* ClassDeclaration */); - return tryAddSignature(classDeclaration.members, true, symbolKind, symbolName, containerName, result); - } - } - return false; - } - function tryAddCallSignature(symbol, location, symbolKind, symbolName, containerName, result) { - if (isCallExpressionTarget(location) || isNewExpressionTarget(location) || isNameOfFunctionDeclaration(location)) { - return tryAddSignature(symbol.declarations, false, symbolKind, symbolName, containerName, result); - } - return false; - } - function tryAddSignature(signatureDeclarations, selectConstructors, symbolKind, symbolName, containerName, result) { - var declarations = []; - var definition; - ts.forEach(signatureDeclarations, function (d) { - if ((selectConstructors && d.kind === 137 /* Constructor */) || - (!selectConstructors && (d.kind === 203 /* FunctionDeclaration */ || d.kind === 136 /* MethodDeclaration */ || d.kind === 135 /* MethodSignature */))) { - declarations.push(d); - if (d.body) - definition = d; - } - }); - if (definition) { - result.push(createDefinitionInfo(definition, symbolKind, symbolName, containerName)); - return true; - } - else if (declarations.length) { - result.push(createDefinitionInfo(ts.lastOrUndefined(declarations), symbolKind, symbolName, containerName)); - return true; - } - return false; - } - } - /// Goto definition - function getDefinitionAtPosition(fileName, position) { - synchronizeHostData(); - var sourceFile = getValidSourceFile(fileName); - var node = ts.getTouchingPropertyName(sourceFile, position); - if (!node) { - return undefined; - } - // Labels - if (isJumpStatementTarget(node)) { - var labelName = node.text; - var label = getTargetLabel(node.parent, node.text); - return label ? [createDefinitionInfo(label, ScriptElementKind.label, labelName, undefined)] : undefined; - } - /// Triple slash reference comments - var comment = ts.forEach(sourceFile.referencedFiles, function (r) { return (r.pos <= position && position < r.end) ? r : undefined; }); - if (comment) { - var referenceFile = ts.tryResolveScriptReference(program, sourceFile, comment); - if (referenceFile) { - return [{ - fileName: referenceFile.fileName, - textSpan: ts.createTextSpanFromBounds(0, 0), - kind: ScriptElementKind.scriptElement, - name: comment.fileName, - containerName: undefined, - containerKind: undefined - }]; - } - return undefined; - } - var typeChecker = program.getTypeChecker(); - var symbol = typeChecker.getSymbolAtLocation(node); - // Could not find a symbol e.g. node is string or number keyword, - // or the symbol was an internal symbol and does not have a declaration e.g. undefined symbol - if (!symbol) { - return undefined; - } - // If this is an alias, and the request came at the declaration location - // get the aliased symbol instead. This allows for goto def on an import e.g. - // import {A, B} from "mod"; - // to jump to the implementation directly. - if (symbol.flags & 8388608 /* Alias */) { - var declaration = symbol.declarations[0]; - if (node.kind === 65 /* Identifier */ && node.parent === declaration) { - symbol = typeChecker.getAliasedSymbol(symbol); - } - } - // Because name in short-hand property assignment has two different meanings: property name and property value, - // using go-to-definition at such position should go to the variable declaration of the property value rather than - // go to the declaration of the property name (in this case stay at the same position). However, if go-to-definition - // is performed at the location of property access, we would like to go to definition of the property in the short-hand - // assignment. This case and others are handled by the following code. - if (node.parent.kind === 228 /* ShorthandPropertyAssignment */) { - var shorthandSymbol = typeChecker.getShorthandAssignmentValueSymbol(symbol.valueDeclaration); - if (!shorthandSymbol) { - return []; - } - var shorthandDeclarations = shorthandSymbol.getDeclarations(); - var shorthandSymbolKind = getSymbolKind(shorthandSymbol, node); - var shorthandSymbolName = typeChecker.symbolToString(shorthandSymbol); - var shorthandContainerName = typeChecker.symbolToString(symbol.parent, node); - return ts.map(shorthandDeclarations, function (declaration) { return createDefinitionInfo(declaration, shorthandSymbolKind, shorthandSymbolName, shorthandContainerName); }); - } - return getDefinitionFromSymbol(symbol, node); - } - /// Goto type - function getTypeDefinitionAtPosition(fileName, position) { - synchronizeHostData(); - var sourceFile = getValidSourceFile(fileName); - var node = ts.getTouchingPropertyName(sourceFile, position); - if (!node) { - return undefined; - } - var typeChecker = program.getTypeChecker(); - var symbol = typeChecker.getSymbolAtLocation(node); - if (!symbol) { - return undefined; - } - var type = typeChecker.getTypeOfSymbolAtLocation(symbol, node); - if (!type) { - return undefined; - } - if (type.flags & 16384 /* Union */) { - var result = []; - ts.forEach(type.types, function (t) { - if (t.symbol) { - result.push.apply(result, getDefinitionFromSymbol(t.symbol, node)); - } - }); - return result; - } - if (!type.symbol) { - return undefined; - } - return getDefinitionFromSymbol(type.symbol, node); - } - function getOccurrencesAtPosition(fileName, position) { - var results = getOccurrencesAtPositionCore(fileName, position); - if (results) { - var sourceFile = getCanonicalFileName(ts.normalizeSlashes(fileName)); - // Get occurrences only supports reporting occurrences for the file queried. So - // filter down to that list. - results = ts.filter(results, function (r) { return getCanonicalFileName(ts.normalizeSlashes(r.fileName)) === sourceFile; }); - } - return results; - } - function getDocumentHighlights(fileName, position, filesToSearch) { - synchronizeHostData(); - filesToSearch = ts.map(filesToSearch, ts.normalizeSlashes); - var sourceFilesToSearch = ts.filter(program.getSourceFiles(), function (f) { return ts.contains(filesToSearch, f.fileName); }); - var sourceFile = getValidSourceFile(fileName); - var node = ts.getTouchingWord(sourceFile, position); - if (!node) { - return undefined; - } - return getSemanticDocumentHighlights(node) || getSyntacticDocumentHighlights(node); - function getHighlightSpanForNode(node) { - var start = node.getStart(); - var end = node.getEnd(); - return { - fileName: sourceFile.fileName, - textSpan: ts.createTextSpanFromBounds(start, end), - kind: HighlightSpanKind.none - }; - } - function getSemanticDocumentHighlights(node) { - if (node.kind === 65 /* Identifier */ || - node.kind === 93 /* ThisKeyword */ || - node.kind === 91 /* SuperKeyword */ || - isLiteralNameOfPropertyDeclarationOrIndexAccess(node) || - isNameOfExternalModuleImportOrDeclaration(node)) { - var referencedSymbols = getReferencedSymbolsForNodes(node, sourceFilesToSearch, false, false); - return convertReferencedSymbols(referencedSymbols); - } - return undefined; - function convertReferencedSymbols(referencedSymbols) { - if (!referencedSymbols) { - return undefined; - } - var fileNameToDocumentHighlights = {}; - var result = []; - for (var _i = 0; _i < referencedSymbols.length; _i++) { - var referencedSymbol = referencedSymbols[_i]; - for (var _a = 0, _b = referencedSymbol.references; _a < _b.length; _a++) { - var referenceEntry = _b[_a]; - var fileName_1 = referenceEntry.fileName; - var documentHighlights = ts.getProperty(fileNameToDocumentHighlights, fileName_1); - if (!documentHighlights) { - documentHighlights = { fileName: fileName_1, highlightSpans: [] }; - fileNameToDocumentHighlights[fileName_1] = documentHighlights; - result.push(documentHighlights); - } - documentHighlights.highlightSpans.push({ - textSpan: referenceEntry.textSpan, - kind: referenceEntry.isWriteAccess ? HighlightSpanKind.writtenReference : HighlightSpanKind.reference - }); - } - } - return result; - } - } - function getSyntacticDocumentHighlights(node) { - var fileName = sourceFile.fileName; - var highlightSpans = getHighlightSpans(node); - if (!highlightSpans || highlightSpans.length === 0) { - return undefined; - } - return [{ fileName: fileName, highlightSpans: highlightSpans }]; - // returns true if 'node' is defined and has a matching 'kind'. - function hasKind(node, kind) { - return node !== undefined && node.kind === kind; - } - // Null-propagating 'parent' function. - function parent(node) { - return node && node.parent; - } - function getHighlightSpans(node) { - if (node) { - switch (node.kind) { - case 84 /* IfKeyword */: - case 76 /* ElseKeyword */: - if (hasKind(node.parent, 186 /* IfStatement */)) { - return getIfElseOccurrences(node.parent); - } - break; - case 90 /* ReturnKeyword */: - if (hasKind(node.parent, 194 /* ReturnStatement */)) { - return getReturnOccurrences(node.parent); - } - break; - case 94 /* ThrowKeyword */: - if (hasKind(node.parent, 198 /* ThrowStatement */)) { - return getThrowOccurrences(node.parent); - } - break; - case 68 /* CatchKeyword */: - if (hasKind(parent(parent(node)), 199 /* TryStatement */)) { - return getTryCatchFinallyOccurrences(node.parent.parent); - } - break; - case 96 /* TryKeyword */: - case 81 /* FinallyKeyword */: - if (hasKind(parent(node), 199 /* TryStatement */)) { - return getTryCatchFinallyOccurrences(node.parent); - } - break; - case 92 /* SwitchKeyword */: - if (hasKind(node.parent, 196 /* SwitchStatement */)) { - return getSwitchCaseDefaultOccurrences(node.parent); - } - break; - case 67 /* CaseKeyword */: - case 73 /* DefaultKeyword */: - if (hasKind(parent(parent(parent(node))), 196 /* SwitchStatement */)) { - return getSwitchCaseDefaultOccurrences(node.parent.parent.parent); - } - break; - case 66 /* BreakKeyword */: - case 71 /* ContinueKeyword */: - if (hasKind(node.parent, 193 /* BreakStatement */) || hasKind(node.parent, 192 /* ContinueStatement */)) { - return getBreakOrContinueStatementOccurences(node.parent); - } - break; - case 82 /* ForKeyword */: - if (hasKind(node.parent, 189 /* ForStatement */) || - hasKind(node.parent, 190 /* ForInStatement */) || - hasKind(node.parent, 191 /* ForOfStatement */)) { - return getLoopBreakContinueOccurrences(node.parent); - } - break; - case 100 /* WhileKeyword */: - case 75 /* DoKeyword */: - if (hasKind(node.parent, 188 /* WhileStatement */) || hasKind(node.parent, 187 /* DoStatement */)) { - return getLoopBreakContinueOccurrences(node.parent); - } - break; - case 114 /* ConstructorKeyword */: - if (hasKind(node.parent, 137 /* Constructor */)) { - return getConstructorOccurrences(node.parent); - } - break; - case 116 /* GetKeyword */: - case 122 /* SetKeyword */: - if (hasKind(node.parent, 138 /* GetAccessor */) || hasKind(node.parent, 139 /* SetAccessor */)) { - return getGetAndSetOccurrences(node.parent); - } - default: - if (ts.isModifier(node.kind) && node.parent && - (ts.isDeclaration(node.parent) || node.parent.kind === 183 /* VariableStatement */)) { - return getModifierOccurrences(node.kind, node.parent); - } - } - } - return undefined; - } - /** - * Aggregates all throw-statements within this node *without* crossing - * into function boundaries and try-blocks with catch-clauses. - */ - function aggregateOwnedThrowStatements(node) { - var statementAccumulator = []; - aggregate(node); - return statementAccumulator; - function aggregate(node) { - if (node.kind === 198 /* ThrowStatement */) { - statementAccumulator.push(node); - } - else if (node.kind === 199 /* TryStatement */) { - var tryStatement = node; - if (tryStatement.catchClause) { - aggregate(tryStatement.catchClause); - } - else { - // Exceptions thrown within a try block lacking a catch clause - // are "owned" in the current context. - aggregate(tryStatement.tryBlock); - } - if (tryStatement.finallyBlock) { - aggregate(tryStatement.finallyBlock); - } - } - else if (!ts.isFunctionLike(node)) { - ts.forEachChild(node, aggregate); - } - } - ; - } - /** - * For lack of a better name, this function takes a throw statement and returns the - * nearest ancestor that is a try-block (whose try statement has a catch clause), - * function-block, or source file. - */ - function getThrowStatementOwner(throwStatement) { - var child = throwStatement; - while (child.parent) { - var parent_11 = child.parent; - if (ts.isFunctionBlock(parent_11) || parent_11.kind === 230 /* SourceFile */) { - return parent_11; - } - // A throw-statement is only owned by a try-statement if the try-statement has - // a catch clause, and if the throw-statement occurs within the try block. - if (parent_11.kind === 199 /* TryStatement */) { - var tryStatement = parent_11; - if (tryStatement.tryBlock === child && tryStatement.catchClause) { - return child; - } - } - child = parent_11; - } - return undefined; - } - function aggregateAllBreakAndContinueStatements(node) { - var statementAccumulator = []; - aggregate(node); - return statementAccumulator; - function aggregate(node) { - if (node.kind === 193 /* BreakStatement */ || node.kind === 192 /* ContinueStatement */) { - statementAccumulator.push(node); - } - else if (!ts.isFunctionLike(node)) { - ts.forEachChild(node, aggregate); - } - } - ; - } - function ownsBreakOrContinueStatement(owner, statement) { - var actualOwner = getBreakOrContinueOwner(statement); - return actualOwner && actualOwner === owner; - } - function getBreakOrContinueOwner(statement) { - for (var node_2 = statement.parent; node_2; node_2 = node_2.parent) { - switch (node_2.kind) { - case 196 /* SwitchStatement */: - if (statement.kind === 192 /* ContinueStatement */) { - continue; - } - // Fall through. - case 189 /* ForStatement */: - case 190 /* ForInStatement */: - case 191 /* ForOfStatement */: - case 188 /* WhileStatement */: - case 187 /* DoStatement */: - if (!statement.label || isLabeledBy(node_2, statement.label.text)) { - return node_2; - } - break; - default: - // Don't cross function boundaries. - if (ts.isFunctionLike(node_2)) { - return undefined; - } - break; - } - } - return undefined; - } - function getModifierOccurrences(modifier, declaration) { - var container = declaration.parent; - // Make sure we only highlight the keyword when it makes sense to do so. - if (ts.isAccessibilityModifier(modifier)) { - if (!(container.kind === 204 /* ClassDeclaration */ || - (declaration.kind === 131 /* Parameter */ && hasKind(container, 137 /* Constructor */)))) { - return undefined; - } - } - else if (modifier === 109 /* StaticKeyword */) { - if (container.kind !== 204 /* ClassDeclaration */) { - return undefined; - } - } - else if (modifier === 78 /* ExportKeyword */ || modifier === 115 /* DeclareKeyword */) { - if (!(container.kind === 209 /* ModuleBlock */ || container.kind === 230 /* SourceFile */)) { - return undefined; - } - } - else { - // unsupported modifier - return undefined; - } - var keywords = []; - var modifierFlag = getFlagFromModifier(modifier); - var nodes; - switch (container.kind) { - case 209 /* ModuleBlock */: - case 230 /* SourceFile */: - nodes = container.statements; - break; - case 137 /* Constructor */: - nodes = container.parameters.concat(container.parent.members); - break; - case 204 /* ClassDeclaration */: - nodes = container.members; - // If we're an accessibility modifier, we're in an instance member and should search - // the constructor's parameter list for instance members as well. - if (modifierFlag & 112 /* AccessibilityModifier */) { - var constructor = ts.forEach(container.members, function (member) { - return member.kind === 137 /* Constructor */ && member; - }); - if (constructor) { - nodes = nodes.concat(constructor.parameters); - } - } - break; - default: - ts.Debug.fail("Invalid container kind."); - } - ts.forEach(nodes, function (node) { - if (node.modifiers && node.flags & modifierFlag) { - ts.forEach(node.modifiers, function (child) { return pushKeywordIf(keywords, child, modifier); }); - } - }); - return ts.map(keywords, getHighlightSpanForNode); - function getFlagFromModifier(modifier) { - switch (modifier) { - case 108 /* PublicKeyword */: - return 16 /* Public */; - case 106 /* PrivateKeyword */: - return 32 /* Private */; - case 107 /* ProtectedKeyword */: - return 64 /* Protected */; - case 109 /* StaticKeyword */: - return 128 /* Static */; - case 78 /* ExportKeyword */: - return 1 /* Export */; - case 115 /* DeclareKeyword */: - return 2 /* Ambient */; - default: - ts.Debug.fail(); - } - } - } - function pushKeywordIf(keywordList, token) { - var expected = []; - for (var _i = 2; _i < arguments.length; _i++) { - expected[_i - 2] = arguments[_i]; - } - if (token && ts.contains(expected, token.kind)) { - keywordList.push(token); - return true; - } - return false; - } - function getGetAndSetOccurrences(accessorDeclaration) { - var keywords = []; - tryPushAccessorKeyword(accessorDeclaration.symbol, 138 /* GetAccessor */); - tryPushAccessorKeyword(accessorDeclaration.symbol, 139 /* SetAccessor */); - return ts.map(keywords, getHighlightSpanForNode); - function tryPushAccessorKeyword(accessorSymbol, accessorKind) { - var accessor = ts.getDeclarationOfKind(accessorSymbol, accessorKind); - if (accessor) { - ts.forEach(accessor.getChildren(), function (child) { return pushKeywordIf(keywords, child, 116 /* GetKeyword */, 122 /* SetKeyword */); }); - } - } - } - function getConstructorOccurrences(constructorDeclaration) { - var declarations = constructorDeclaration.symbol.getDeclarations(); - var keywords = []; - ts.forEach(declarations, function (declaration) { - ts.forEach(declaration.getChildren(), function (token) { - return pushKeywordIf(keywords, token, 114 /* ConstructorKeyword */); - }); - }); - return ts.map(keywords, getHighlightSpanForNode); - } - function getLoopBreakContinueOccurrences(loopNode) { - var keywords = []; - if (pushKeywordIf(keywords, loopNode.getFirstToken(), 82 /* ForKeyword */, 100 /* WhileKeyword */, 75 /* DoKeyword */)) { - // If we succeeded and got a do-while loop, then start looking for a 'while' keyword. - if (loopNode.kind === 187 /* DoStatement */) { - var loopTokens = loopNode.getChildren(); - for (var i = loopTokens.length - 1; i >= 0; i--) { - if (pushKeywordIf(keywords, loopTokens[i], 100 /* WhileKeyword */)) { - break; - } - } - } - } - var breaksAndContinues = aggregateAllBreakAndContinueStatements(loopNode.statement); - ts.forEach(breaksAndContinues, function (statement) { - if (ownsBreakOrContinueStatement(loopNode, statement)) { - pushKeywordIf(keywords, statement.getFirstToken(), 66 /* BreakKeyword */, 71 /* ContinueKeyword */); - } - }); - return ts.map(keywords, getHighlightSpanForNode); - } - function getBreakOrContinueStatementOccurences(breakOrContinueStatement) { - var owner = getBreakOrContinueOwner(breakOrContinueStatement); - if (owner) { - switch (owner.kind) { - case 189 /* ForStatement */: - case 190 /* ForInStatement */: - case 191 /* ForOfStatement */: - case 187 /* DoStatement */: - case 188 /* WhileStatement */: - return getLoopBreakContinueOccurrences(owner); - case 196 /* SwitchStatement */: - return getSwitchCaseDefaultOccurrences(owner); - } - } - return undefined; - } - function getSwitchCaseDefaultOccurrences(switchStatement) { - var keywords = []; - pushKeywordIf(keywords, switchStatement.getFirstToken(), 92 /* SwitchKeyword */); - // Go through each clause in the switch statement, collecting the 'case'/'default' keywords. - ts.forEach(switchStatement.caseBlock.clauses, function (clause) { - pushKeywordIf(keywords, clause.getFirstToken(), 67 /* CaseKeyword */, 73 /* DefaultKeyword */); - var breaksAndContinues = aggregateAllBreakAndContinueStatements(clause); - ts.forEach(breaksAndContinues, function (statement) { - if (ownsBreakOrContinueStatement(switchStatement, statement)) { - pushKeywordIf(keywords, statement.getFirstToken(), 66 /* BreakKeyword */); - } - }); - }); - return ts.map(keywords, getHighlightSpanForNode); - } - function getTryCatchFinallyOccurrences(tryStatement) { - var keywords = []; - pushKeywordIf(keywords, tryStatement.getFirstToken(), 96 /* TryKeyword */); - if (tryStatement.catchClause) { - pushKeywordIf(keywords, tryStatement.catchClause.getFirstToken(), 68 /* CatchKeyword */); - } - if (tryStatement.finallyBlock) { - var finallyKeyword = ts.findChildOfKind(tryStatement, 81 /* FinallyKeyword */, sourceFile); - pushKeywordIf(keywords, finallyKeyword, 81 /* FinallyKeyword */); - } - return ts.map(keywords, getHighlightSpanForNode); - } - function getThrowOccurrences(throwStatement) { - var owner = getThrowStatementOwner(throwStatement); - if (!owner) { - return undefined; - } - var keywords = []; - ts.forEach(aggregateOwnedThrowStatements(owner), function (throwStatement) { - pushKeywordIf(keywords, throwStatement.getFirstToken(), 94 /* ThrowKeyword */); - }); - // If the "owner" is a function, then we equate 'return' and 'throw' statements in their - // ability to "jump out" of the function, and include occurrences for both. - if (ts.isFunctionBlock(owner)) { - ts.forEachReturnStatement(owner, function (returnStatement) { - pushKeywordIf(keywords, returnStatement.getFirstToken(), 90 /* ReturnKeyword */); - }); - } - return ts.map(keywords, getHighlightSpanForNode); - } - function getReturnOccurrences(returnStatement) { - var func = ts.getContainingFunction(returnStatement); - // If we didn't find a containing function with a block body, bail out. - if (!(func && hasKind(func.body, 182 /* Block */))) { - return undefined; - } - var keywords = []; - ts.forEachReturnStatement(func.body, function (returnStatement) { - pushKeywordIf(keywords, returnStatement.getFirstToken(), 90 /* ReturnKeyword */); - }); - // Include 'throw' statements that do not occur within a try block. - ts.forEach(aggregateOwnedThrowStatements(func.body), function (throwStatement) { - pushKeywordIf(keywords, throwStatement.getFirstToken(), 94 /* ThrowKeyword */); - }); - return ts.map(keywords, getHighlightSpanForNode); - } - function getIfElseOccurrences(ifStatement) { - var keywords = []; - // Traverse upwards through all parent if-statements linked by their else-branches. - while (hasKind(ifStatement.parent, 186 /* IfStatement */) && ifStatement.parent.elseStatement === ifStatement) { - ifStatement = ifStatement.parent; - } - // Now traverse back down through the else branches, aggregating if/else keywords of if-statements. - while (ifStatement) { - var children = ifStatement.getChildren(); - pushKeywordIf(keywords, children[0], 84 /* IfKeyword */); - // Generally the 'else' keyword is second-to-last, so we traverse backwards. - for (var i = children.length - 1; i >= 0; i--) { - if (pushKeywordIf(keywords, children[i], 76 /* ElseKeyword */)) { - break; - } - } - if (!hasKind(ifStatement.elseStatement, 186 /* IfStatement */)) { - break; - } - ifStatement = ifStatement.elseStatement; - } - var result = []; - // We'd like to highlight else/ifs together if they are only separated by whitespace - // (i.e. the keywords are separated by no comments, no newlines). - for (var i = 0; i < keywords.length; i++) { - if (keywords[i].kind === 76 /* ElseKeyword */ && i < keywords.length - 1) { - var elseKeyword = keywords[i]; - var ifKeyword = keywords[i + 1]; // this *should* always be an 'if' keyword. - var shouldCombindElseAndIf = true; - // Avoid recalculating getStart() by iterating backwards. - for (var j = ifKeyword.getStart() - 1; j >= elseKeyword.end; j--) { - if (!ts.isWhiteSpace(sourceFile.text.charCodeAt(j))) { - shouldCombindElseAndIf = false; - break; - } - } - if (shouldCombindElseAndIf) { - result.push({ - fileName: fileName, - textSpan: ts.createTextSpanFromBounds(elseKeyword.getStart(), ifKeyword.end), - kind: HighlightSpanKind.reference - }); - i++; // skip the next keyword - continue; - } - } - // Ordinary case: just highlight the keyword. - result.push(getHighlightSpanForNode(keywords[i])); - } - return result; - } - } - } - /// References and Occurrences - function getOccurrencesAtPositionCore(fileName, position) { - synchronizeHostData(); - return convertDocumentHighlights(getDocumentHighlights(fileName, position, [fileName])); - function convertDocumentHighlights(documentHighlights) { - if (!documentHighlights) { - return undefined; - } - var result = []; - for (var _i = 0; _i < documentHighlights.length; _i++) { - var entry = documentHighlights[_i]; - for (var _a = 0, _b = entry.highlightSpans; _a < _b.length; _a++) { - var highlightSpan = _b[_a]; - result.push({ - fileName: entry.fileName, - textSpan: highlightSpan.textSpan, - isWriteAccess: highlightSpan.kind === HighlightSpanKind.writtenReference - }); - } - } - return result; - } - } - function convertReferences(referenceSymbols) { - if (!referenceSymbols) { - return undefined; - } - var referenceEntries = []; - for (var _i = 0; _i < referenceSymbols.length; _i++) { - var referenceSymbol = referenceSymbols[_i]; - ts.addRange(referenceEntries, referenceSymbol.references); - } - return referenceEntries; - } - function findRenameLocations(fileName, position, findInStrings, findInComments) { - var referencedSymbols = findReferencedSymbols(fileName, position, findInStrings, findInComments); - return convertReferences(referencedSymbols); - } - function getReferencesAtPosition(fileName, position) { - var referencedSymbols = findReferencedSymbols(fileName, position, false, false); - return convertReferences(referencedSymbols); - } - function findReferences(fileName, position) { - var referencedSymbols = findReferencedSymbols(fileName, position, false, false); - // Only include referenced symbols that have a valid definition. - return ts.filter(referencedSymbols, function (rs) { return !!rs.definition; }); - } - function findReferencedSymbols(fileName, position, findInStrings, findInComments) { - synchronizeHostData(); - var sourceFile = getValidSourceFile(fileName); - var node = ts.getTouchingPropertyName(sourceFile, position); - if (!node) { - return undefined; - } - if (node.kind !== 65 /* Identifier */ && - // TODO (drosen): This should be enabled in a later release - currently breaks rename. - //node.kind !== SyntaxKind.ThisKeyword && - //node.kind !== SyntaxKind.SuperKeyword && - !isLiteralNameOfPropertyDeclarationOrIndexAccess(node) && - !isNameOfExternalModuleImportOrDeclaration(node)) { - return undefined; - } - ts.Debug.assert(node.kind === 65 /* Identifier */ || node.kind === 7 /* NumericLiteral */ || node.kind === 8 /* StringLiteral */); - return getReferencedSymbolsForNodes(node, program.getSourceFiles(), findInStrings, findInComments); - } - function getReferencedSymbolsForNodes(node, sourceFiles, findInStrings, findInComments) { - var typeChecker = program.getTypeChecker(); - // Labels - if (isLabelName(node)) { - if (isJumpStatementTarget(node)) { - var labelDefinition = getTargetLabel(node.parent, node.text); - // if we have a label definition, look within its statement for references, if not, then - // the label is undefined and we have no results.. - return labelDefinition ? getLabelReferencesInNode(labelDefinition.parent, labelDefinition) : undefined; - } - else { - // it is a label definition and not a target, search within the parent labeledStatement - return getLabelReferencesInNode(node.parent, node); - } - } - if (node.kind === 93 /* ThisKeyword */) { - return getReferencesForThisKeyword(node, sourceFiles); - } - if (node.kind === 91 /* SuperKeyword */) { - return getReferencesForSuperKeyword(node); - } - var symbol = typeChecker.getSymbolAtLocation(node); - // Could not find a symbol e.g. unknown identifier - if (!symbol) { - // Can't have references to something that we have no symbol for. - return undefined; - } - var declarations = symbol.declarations; - // The symbol was an internal symbol and does not have a declaration e.g.undefined symbol - if (!declarations || !declarations.length) { - return undefined; - } - var result; - // Compute the meaning from the location and the symbol it references - var searchMeaning = getIntersectingMeaningFromDeclarations(getMeaningFromLocation(node), declarations); - // Get the text to search for, we need to normalize it as external module names will have quote - var declaredName = getDeclaredName(symbol, node); - // Try to get the smallest valid scope that we can limit our search to; - // otherwise we'll need to search globally (i.e. include each file). - var scope = getSymbolScope(symbol); - // Maps from a symbol ID to the ReferencedSymbol entry in 'result'. - var symbolToIndex = []; - if (scope) { - result = []; - getReferencesInNode(scope, symbol, declaredName, node, searchMeaning, findInStrings, findInComments, result, symbolToIndex); - } - else { - var internedName = getInternedName(symbol, node, declarations); - for (var _i = 0; _i < sourceFiles.length; _i++) { - var sourceFile = sourceFiles[_i]; - cancellationToken.throwIfCancellationRequested(); - var nameTable = getNameTable(sourceFile); - if (ts.lookUp(nameTable, internedName)) { - result = result || []; - getReferencesInNode(sourceFile, symbol, declaredName, node, searchMeaning, findInStrings, findInComments, result, symbolToIndex); - } - } - } - return result; - function getDefinition(symbol) { - var info = getSymbolDisplayPartsDocumentationAndSymbolKind(symbol, node.getSourceFile(), getContainerNode(node), node); - var name = ts.map(info.displayParts, function (p) { return p.text; }).join(""); - var declarations = symbol.declarations; - if (!declarations || declarations.length === 0) { - return undefined; - } - return { - containerKind: "", - containerName: "", - name: name, - kind: info.symbolKind, - fileName: declarations[0].getSourceFile().fileName, - textSpan: ts.createTextSpan(declarations[0].getStart(), 0) - }; - } - function isImportOrExportSpecifierName(location) { - return location.parent && - (location.parent.kind === 216 /* ImportSpecifier */ || location.parent.kind === 220 /* ExportSpecifier */) && - location.parent.propertyName === location; - } - function isImportOrExportSpecifierImportSymbol(symbol) { - return (symbol.flags & 8388608 /* Alias */) && ts.forEach(symbol.declarations, function (declaration) { - return declaration.kind === 216 /* ImportSpecifier */ || declaration.kind === 220 /* ExportSpecifier */; - }); - } - function getDeclaredName(symbol, location) { - // Special case for function expressions, whose names are solely local to their bodies. - var functionExpression = ts.forEach(symbol.declarations, function (d) { return d.kind === 165 /* FunctionExpression */ ? d : undefined; }); - // When a name gets interned into a SourceFile's 'identifiers' Map, - // its name is escaped and stored in the same way its symbol name/identifier - // name should be stored. Function expressions, however, are a special case, - // because despite sometimes having a name, the binder unconditionally binds them - // to a symbol with the name "__function". - var name; - if (functionExpression && functionExpression.name) { - name = functionExpression.name.text; - } - // If this is an export or import specifier it could have been renamed using the as syntax. - // if so we want to search for whatever under the cursor, the symbol is pointing to the alias (name) - // so check for the propertyName. - if (isImportOrExportSpecifierName(location)) { - return location.getText(); - } - name = typeChecker.symbolToString(symbol); - return stripQuotes(name); - } - function getInternedName(symbol, location, declarations) { - // If this is an export or import specifier it could have been renamed using the as syntax. - // if so we want to search for whatever under the cursor, the symbol is pointing to the alias (name) - // so check for the propertyName. - if (isImportOrExportSpecifierName(location)) { - return location.getText(); - } - // Special case for function expressions, whose names are solely local to their bodies. - var functionExpression = ts.forEach(declarations, function (d) { return d.kind === 165 /* FunctionExpression */ ? d : undefined; }); - // When a name gets interned into a SourceFile's 'identifiers' Map, - // its name is escaped and stored in the same way its symbol name/identifier - // name should be stored. Function expressions, however, are a special case, - // because despite sometimes having a name, the binder unconditionally binds them - // to a symbol with the name "__function". - var name = functionExpression && functionExpression.name - ? functionExpression.name.text - : symbol.name; - return stripQuotes(name); - } - function stripQuotes(name) { - var length = name.length; - if (length >= 2 && name.charCodeAt(0) === 34 /* doubleQuote */ && name.charCodeAt(length - 1) === 34 /* doubleQuote */) { - return name.substring(1, length - 1); - } - ; - return name; - } - function getSymbolScope(symbol) { - // If this is private property or method, the scope is the containing class - if (symbol.flags & (4 /* Property */ | 8192 /* Method */)) { - var privateDeclaration = ts.forEach(symbol.getDeclarations(), function (d) { return (d.flags & 32 /* Private */) ? d : undefined; }); - if (privateDeclaration) { - return ts.getAncestor(privateDeclaration, 204 /* ClassDeclaration */); - } - } - // If the symbol is an import we would like to find it if we are looking for what it imports. - // So consider it visibile outside its declaration scope. - if (symbol.flags & 8388608 /* Alias */) { - return undefined; - } - // if this symbol is visible from its parent container, e.g. exported, then bail out - // if symbol correspond to the union property - bail out - if (symbol.parent || (symbol.flags & 268435456 /* UnionProperty */)) { - return undefined; - } - var scope = undefined; - var declarations = symbol.getDeclarations(); - if (declarations) { - for (var _i = 0; _i < declarations.length; _i++) { - var declaration = declarations[_i]; - var container = getContainerNode(declaration); - if (!container) { - return undefined; - } - if (scope && scope !== container) { - // Different declarations have different containers, bail out - return undefined; - } - if (container.kind === 230 /* SourceFile */ && !ts.isExternalModule(container)) { - // This is a global variable and not an external module, any declaration defined - // within this scope is visible outside the file - return undefined; - } - // The search scope is the container node - scope = container; - } - } - return scope; - } - function getPossibleSymbolReferencePositions(sourceFile, symbolName, start, end) { - var positions = []; - /// TODO: Cache symbol existence for files to save text search - // Also, need to make this work for unicode escapes. - // Be resilient in the face of a symbol with no name or zero length name - if (!symbolName || !symbolName.length) { - return positions; - } - var text = sourceFile.text; - var sourceLength = text.length; - var symbolNameLength = symbolName.length; - var position = text.indexOf(symbolName, start); - while (position >= 0) { - cancellationToken.throwIfCancellationRequested(); - // If we are past the end, stop looking - if (position > end) - break; - // We found a match. Make sure it's not part of a larger word (i.e. the char - // before and after it have to be a non-identifier char). - var endPosition = position + symbolNameLength; - if ((position === 0 || !ts.isIdentifierPart(text.charCodeAt(position - 1), 2 /* Latest */)) && - (endPosition === sourceLength || !ts.isIdentifierPart(text.charCodeAt(endPosition), 2 /* Latest */))) { - // Found a real match. Keep searching. - positions.push(position); - } - position = text.indexOf(symbolName, position + symbolNameLength + 1); - } - return positions; - } - function getLabelReferencesInNode(container, targetLabel) { - var references = []; - var sourceFile = container.getSourceFile(); - var labelName = targetLabel.text; - var possiblePositions = getPossibleSymbolReferencePositions(sourceFile, labelName, container.getStart(), container.getEnd()); - ts.forEach(possiblePositions, function (position) { - cancellationToken.throwIfCancellationRequested(); - var node = ts.getTouchingWord(sourceFile, position); - if (!node || node.getWidth() !== labelName.length) { - return; - } - // Only pick labels that are either the target label, or have a target that is the target label - if (node === targetLabel || - (isJumpStatementTarget(node) && getTargetLabel(node, labelName) === targetLabel)) { - references.push(getReferenceEntryFromNode(node)); - } - }); - var definition = { - containerKind: "", - containerName: "", - fileName: targetLabel.getSourceFile().fileName, - kind: ScriptElementKind.label, - name: labelName, - textSpan: ts.createTextSpanFromBounds(targetLabel.getStart(), targetLabel.getEnd()) - }; - return [{ definition: definition, references: references }]; - } - function isValidReferencePosition(node, searchSymbolName) { - if (node) { - // Compare the length so we filter out strict superstrings of the symbol we are looking for - switch (node.kind) { - case 65 /* Identifier */: - return node.getWidth() === searchSymbolName.length; - case 8 /* StringLiteral */: - if (isLiteralNameOfPropertyDeclarationOrIndexAccess(node) || - isNameOfExternalModuleImportOrDeclaration(node)) { - // For string literals we have two additional chars for the quotes - return node.getWidth() === searchSymbolName.length + 2; - } - break; - case 7 /* NumericLiteral */: - if (isLiteralNameOfPropertyDeclarationOrIndexAccess(node)) { - return node.getWidth() === searchSymbolName.length; - } - break; - } - } - return false; - } - /** Search within node "container" for references for a search value, where the search value is defined as a - * tuple of(searchSymbol, searchText, searchLocation, and searchMeaning). - * searchLocation: a node where the search value - */ - function getReferencesInNode(container, searchSymbol, searchText, searchLocation, searchMeaning, findInStrings, findInComments, result, symbolToIndex) { - var sourceFile = container.getSourceFile(); - var tripleSlashDirectivePrefixRegex = /^\/\/\/\s*= 0) { - var referencedSymbol = getReferencedSymbol(shorthandValueSymbol); - referencedSymbol.references.push(getReferenceEntryFromNode(referenceSymbolDeclaration.name)); - } - } - }); - } - return; - function getReferencedSymbol(symbol) { - var symbolId = ts.getSymbolId(symbol); - var index = symbolToIndex[symbolId]; - if (index === undefined) { - index = result.length; - symbolToIndex[symbolId] = index; - result.push({ - definition: getDefinition(symbol), - references: [] - }); - } - return result[index]; - } - function isInString(position) { - var token = ts.getTokenAtPosition(sourceFile, position); - return token && token.kind === 8 /* StringLiteral */ && position > token.getStart(); - } - function isInComment(position) { - var token = ts.getTokenAtPosition(sourceFile, position); - if (token && position < token.getStart()) { - // First, we have to see if this position actually landed in a comment. - var commentRanges = ts.getLeadingCommentRanges(sourceFile.text, token.pos); - // Then we want to make sure that it wasn't in a "///<" directive comment - // We don't want to unintentionally update a file name. - return ts.forEach(commentRanges, function (c) { - if (c.pos < position && position < c.end) { - var commentText = sourceFile.text.substring(c.pos, c.end); - if (!tripleSlashDirectivePrefixRegex.test(commentText)) { - return true; - } - } - }); - } - return false; - } - } - function getReferencesForSuperKeyword(superKeyword) { - var searchSpaceNode = ts.getSuperContainer(superKeyword, false); - if (!searchSpaceNode) { - return undefined; - } - // Whether 'super' occurs in a static context within a class. - var staticFlag = 128 /* Static */; - switch (searchSpaceNode.kind) { - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 137 /* Constructor */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - staticFlag &= searchSpaceNode.flags; - searchSpaceNode = searchSpaceNode.parent; // re-assign to be the owning class - break; - default: - return undefined; - } - var references = []; - var sourceFile = searchSpaceNode.getSourceFile(); - var possiblePositions = getPossibleSymbolReferencePositions(sourceFile, "super", searchSpaceNode.getStart(), searchSpaceNode.getEnd()); - ts.forEach(possiblePositions, function (position) { - cancellationToken.throwIfCancellationRequested(); - var node = ts.getTouchingWord(sourceFile, position); - if (!node || node.kind !== 91 /* SuperKeyword */) { - return; - } - var container = ts.getSuperContainer(node, false); - // If we have a 'super' container, we must have an enclosing class. - // Now make sure the owning class is the same as the search-space - // and has the same static qualifier as the original 'super's owner. - if (container && (128 /* Static */ & container.flags) === staticFlag && container.parent.symbol === searchSpaceNode.symbol) { - references.push(getReferenceEntryFromNode(node)); - } - }); - var definition = getDefinition(searchSpaceNode.symbol); - return [{ definition: definition, references: references }]; - } - function getReferencesForThisKeyword(thisOrSuperKeyword, sourceFiles) { - var searchSpaceNode = ts.getThisContainer(thisOrSuperKeyword, false); - // Whether 'this' occurs in a static context within a class. - var staticFlag = 128 /* Static */; - switch (searchSpaceNode.kind) { - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - if (ts.isObjectLiteralMethod(searchSpaceNode)) { - break; - } - // fall through - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - case 137 /* Constructor */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - staticFlag &= searchSpaceNode.flags; - searchSpaceNode = searchSpaceNode.parent; // re-assign to be the owning class - break; - case 230 /* SourceFile */: - if (ts.isExternalModule(searchSpaceNode)) { - return undefined; - } - // Fall through - case 203 /* FunctionDeclaration */: - case 165 /* FunctionExpression */: - break; - // Computed properties in classes are not handled here because references to this are illegal, - // so there is no point finding references to them. - default: - return undefined; - } - var references = []; - var possiblePositions; - if (searchSpaceNode.kind === 230 /* SourceFile */) { - ts.forEach(sourceFiles, function (sourceFile) { - possiblePositions = getPossibleSymbolReferencePositions(sourceFile, "this", sourceFile.getStart(), sourceFile.getEnd()); - getThisReferencesInFile(sourceFile, sourceFile, possiblePositions, references); - }); - } - else { - var sourceFile = searchSpaceNode.getSourceFile(); - possiblePositions = getPossibleSymbolReferencePositions(sourceFile, "this", searchSpaceNode.getStart(), searchSpaceNode.getEnd()); - getThisReferencesInFile(sourceFile, searchSpaceNode, possiblePositions, references); - } - return [{ - definition: { - containerKind: "", - containerName: "", - fileName: node.getSourceFile().fileName, - kind: ScriptElementKind.variableElement, - name: "this", - textSpan: ts.createTextSpanFromBounds(node.getStart(), node.getEnd()) - }, - references: references - }]; - function getThisReferencesInFile(sourceFile, searchSpaceNode, possiblePositions, result) { - ts.forEach(possiblePositions, function (position) { - cancellationToken.throwIfCancellationRequested(); - var node = ts.getTouchingWord(sourceFile, position); - if (!node || node.kind !== 93 /* ThisKeyword */) { - return; - } - var container = ts.getThisContainer(node, false); - switch (searchSpaceNode.kind) { - case 165 /* FunctionExpression */: - case 203 /* FunctionDeclaration */: - if (searchSpaceNode.symbol === container.symbol) { - result.push(getReferenceEntryFromNode(node)); - } - break; - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - if (ts.isObjectLiteralMethod(searchSpaceNode) && searchSpaceNode.symbol === container.symbol) { - result.push(getReferenceEntryFromNode(node)); - } - break; - case 204 /* ClassDeclaration */: - // Make sure the container belongs to the same class - // and has the appropriate static modifier from the original container. - if (container.parent && searchSpaceNode.symbol === container.parent.symbol && (container.flags & 128 /* Static */) === staticFlag) { - result.push(getReferenceEntryFromNode(node)); - } - break; - case 230 /* SourceFile */: - if (container.kind === 230 /* SourceFile */ && !ts.isExternalModule(container)) { - result.push(getReferenceEntryFromNode(node)); - } - break; - } - }); - } - } - function populateSearchSymbolSet(symbol, location) { - // The search set contains at least the current symbol - var result = [symbol]; - // If the symbol is an alias, add what it alaises to the list - if (isImportOrExportSpecifierImportSymbol(symbol)) { - result.push(typeChecker.getAliasedSymbol(symbol)); - } - // If the location is in a context sensitive location (i.e. in an object literal) try - // to get a contextual type for it, and add the property symbol from the contextual - // type to the search set - if (isNameOfPropertyAssignment(location)) { - ts.forEach(getPropertySymbolsFromContextualType(location), function (contextualSymbol) { - result.push.apply(result, typeChecker.getRootSymbols(contextualSymbol)); - }); - /* Because in short-hand property assignment, location has two meaning : property name and as value of the property - * When we do findAllReference at the position of the short-hand property assignment, we would want to have references to position of - * property name and variable declaration of the identifier. - * Like in below example, when querying for all references for an identifier 'name', of the property assignment, the language service - * should show both 'name' in 'obj' and 'name' in variable declaration - * let name = "Foo"; - * let obj = { name }; - * In order to do that, we will populate the search set with the value symbol of the identifier as a value of the property assignment - * so that when matching with potential reference symbol, both symbols from property declaration and variable declaration - * will be included correctly. - */ - var shorthandValueSymbol = typeChecker.getShorthandAssignmentValueSymbol(location.parent); - if (shorthandValueSymbol) { - result.push(shorthandValueSymbol); - } - } - // If this is a union property, add all the symbols from all its source symbols in all unioned types. - // If the symbol is an instantiation from a another symbol (e.g. widened symbol) , add the root the list - ts.forEach(typeChecker.getRootSymbols(symbol), function (rootSymbol) { - if (rootSymbol !== symbol) { - result.push(rootSymbol); - } - // Add symbol of properties/methods of the same name in base classes and implemented interfaces definitions - if (rootSymbol.parent && rootSymbol.parent.flags & (32 /* Class */ | 64 /* Interface */)) { - getPropertySymbolsFromBaseTypes(rootSymbol.parent, rootSymbol.getName(), result); - } - }); - return result; - } - function getPropertySymbolsFromBaseTypes(symbol, propertyName, result) { - if (symbol && symbol.flags & (32 /* Class */ | 64 /* Interface */)) { - ts.forEach(symbol.getDeclarations(), function (declaration) { - if (declaration.kind === 204 /* ClassDeclaration */) { - getPropertySymbolFromTypeReference(ts.getClassExtendsHeritageClauseElement(declaration)); - ts.forEach(ts.getClassImplementsHeritageClauseElements(declaration), getPropertySymbolFromTypeReference); - } - else if (declaration.kind === 205 /* InterfaceDeclaration */) { - ts.forEach(ts.getInterfaceBaseTypeNodes(declaration), getPropertySymbolFromTypeReference); - } - }); - } - return; - function getPropertySymbolFromTypeReference(typeReference) { - if (typeReference) { - var type = typeChecker.getTypeAtLocation(typeReference); - if (type) { - var propertySymbol = typeChecker.getPropertyOfType(type, propertyName); - if (propertySymbol) { - result.push(propertySymbol); - } - // Visit the typeReference as well to see if it directly or indirectly use that property - getPropertySymbolsFromBaseTypes(type.symbol, propertyName, result); - } - } - } - } - function getRelatedSymbol(searchSymbols, referenceSymbol, referenceLocation) { - if (searchSymbols.indexOf(referenceSymbol) >= 0) { - return referenceSymbol; - } - // If the reference symbol is an alias, check if what it is aliasing is one of the search - // symbols. - if (isImportOrExportSpecifierImportSymbol(referenceSymbol)) { - var aliasedSymbol = typeChecker.getAliasedSymbol(referenceSymbol); - if (searchSymbols.indexOf(aliasedSymbol) >= 0) { - return aliasedSymbol; - } - } - // If the reference location is in an object literal, try to get the contextual type for the - // object literal, lookup the property symbol in the contextual type, and use this symbol to - // compare to our searchSymbol - if (isNameOfPropertyAssignment(referenceLocation)) { - return ts.forEach(getPropertySymbolsFromContextualType(referenceLocation), function (contextualSymbol) { - return ts.forEach(typeChecker.getRootSymbols(contextualSymbol), function (s) { return searchSymbols.indexOf(s) >= 0 ? s : undefined; }); - }); - } - // Unwrap symbols to get to the root (e.g. transient symbols as a result of widening) - // Or a union property, use its underlying unioned symbols - return ts.forEach(typeChecker.getRootSymbols(referenceSymbol), function (rootSymbol) { - // if it is in the list, then we are done - if (searchSymbols.indexOf(rootSymbol) >= 0) { - return rootSymbol; - } - // Finally, try all properties with the same name in any type the containing type extended or implemented, and - // see if any is in the list - if (rootSymbol.parent && rootSymbol.parent.flags & (32 /* Class */ | 64 /* Interface */)) { - var result_3 = []; - getPropertySymbolsFromBaseTypes(rootSymbol.parent, rootSymbol.getName(), result_3); - return ts.forEach(result_3, function (s) { return searchSymbols.indexOf(s) >= 0 ? s : undefined; }); - } - return undefined; - }); - } - function getPropertySymbolsFromContextualType(node) { - if (isNameOfPropertyAssignment(node)) { - var objectLiteral = node.parent.parent; - var contextualType = typeChecker.getContextualType(objectLiteral); - var name_31 = node.text; - if (contextualType) { - if (contextualType.flags & 16384 /* Union */) { - // This is a union type, first see if the property we are looking for is a union property (i.e. exists in all types) - // if not, search the constituent types for the property - var unionProperty = contextualType.getProperty(name_31); - if (unionProperty) { - return [unionProperty]; - } - else { - var result_4 = []; - ts.forEach(contextualType.types, function (t) { - var symbol = t.getProperty(name_31); - if (symbol) { - result_4.push(symbol); - } - }); - return result_4; - } - } - else { - var symbol_1 = contextualType.getProperty(name_31); - if (symbol_1) { - return [symbol_1]; - } - } - } - } - return undefined; - } - /** Given an initial searchMeaning, extracted from a location, widen the search scope based on the declarations - * of the corresponding symbol. e.g. if we are searching for "Foo" in value position, but "Foo" references a class - * then we need to widen the search to include type positions as well. - * On the contrary, if we are searching for "Bar" in type position and we trace bar to an interface, and an uninstantiated - * module, we want to keep the search limited to only types, as the two declarations (interface and uninstantiated module) - * do not intersect in any of the three spaces. - */ - function getIntersectingMeaningFromDeclarations(meaning, declarations) { - if (declarations) { - var lastIterationMeaning; - do { - // The result is order-sensitive, for instance if initialMeaning === Namespace, and declarations = [class, instantiated module] - // we need to consider both as they initialMeaning intersects with the module in the namespace space, and the module - // intersects with the class in the value space. - // To achieve that we will keep iterating until the result stabilizes. - // Remember the last meaning - lastIterationMeaning = meaning; - for (var _i = 0; _i < declarations.length; _i++) { - var declaration = declarations[_i]; - var declarationMeaning = getMeaningFromDeclaration(declaration); - if (declarationMeaning & meaning) { - meaning |= declarationMeaning; - } - } - } while (meaning !== lastIterationMeaning); - } - return meaning; - } - } - function getReferenceEntryFromNode(node) { - var start = node.getStart(); - var end = node.getEnd(); - if (node.kind === 8 /* StringLiteral */) { - start += 1; - end -= 1; - } - return { - fileName: node.getSourceFile().fileName, - textSpan: ts.createTextSpanFromBounds(start, end), - isWriteAccess: isWriteAccess(node) - }; - } - /** A node is considered a writeAccess iff it is a name of a declaration or a target of an assignment */ - function isWriteAccess(node) { - if (node.kind === 65 /* Identifier */ && ts.isDeclarationName(node)) { - return true; - } - var parent = node.parent; - if (parent) { - if (parent.kind === 171 /* PostfixUnaryExpression */ || parent.kind === 170 /* PrefixUnaryExpression */) { - return true; - } - else if (parent.kind === 172 /* BinaryExpression */ && parent.left === node) { - var operator = parent.operatorToken.kind; - return 53 /* FirstAssignment */ <= operator && operator <= 64 /* LastAssignment */; - } - } - return false; - } - /// NavigateTo - function getNavigateToItems(searchValue, maxResultCount) { - synchronizeHostData(); - return ts.NavigateTo.getNavigateToItems(program, cancellationToken, searchValue, maxResultCount); - } - function containErrors(diagnostics) { - return ts.forEach(diagnostics, function (diagnostic) { return diagnostic.category === ts.DiagnosticCategory.Error; }); - } - function getEmitOutput(fileName) { - synchronizeHostData(); - var sourceFile = getValidSourceFile(fileName); - var outputFiles = []; - function writeFile(fileName, data, writeByteOrderMark) { - outputFiles.push({ - name: fileName, - writeByteOrderMark: writeByteOrderMark, - text: data - }); - } - var emitOutput = program.emit(sourceFile, writeFile); - return { - outputFiles: outputFiles, - emitSkipped: emitOutput.emitSkipped - }; - } - function getMeaningFromDeclaration(node) { - switch (node.kind) { - case 131 /* Parameter */: - case 201 /* VariableDeclaration */: - case 155 /* BindingElement */: - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - case 227 /* PropertyAssignment */: - case 228 /* ShorthandPropertyAssignment */: - case 229 /* EnumMember */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 137 /* Constructor */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 203 /* FunctionDeclaration */: - case 165 /* FunctionExpression */: - case 166 /* ArrowFunction */: - case 226 /* CatchClause */: - return 1 /* Value */; - case 130 /* TypeParameter */: - case 205 /* InterfaceDeclaration */: - case 206 /* TypeAliasDeclaration */: - case 148 /* TypeLiteral */: - return 2 /* Type */; - case 204 /* ClassDeclaration */: - case 207 /* EnumDeclaration */: - return 1 /* Value */ | 2 /* Type */; - case 208 /* ModuleDeclaration */: - if (node.name.kind === 8 /* StringLiteral */) { - return 4 /* Namespace */ | 1 /* Value */; - } - else if (ts.getModuleInstanceState(node) === 1 /* Instantiated */) { - return 4 /* Namespace */ | 1 /* Value */; - } - else { - return 4 /* Namespace */; - } - case 215 /* NamedImports */: - case 216 /* ImportSpecifier */: - case 211 /* ImportEqualsDeclaration */: - case 212 /* ImportDeclaration */: - case 217 /* ExportAssignment */: - case 218 /* ExportDeclaration */: - return 1 /* Value */ | 2 /* Type */ | 4 /* Namespace */; - // An external module can be a Value - case 230 /* SourceFile */: - return 4 /* Namespace */ | 1 /* Value */; - } - return 1 /* Value */ | 2 /* Type */ | 4 /* Namespace */; - ts.Debug.fail("Unknown declaration type"); - } - function isTypeReference(node) { - if (ts.isRightSideOfQualifiedNameOrPropertyAccess(node)) { - node = node.parent; - } - return node.parent.kind === 144 /* TypeReference */ || node.parent.kind === 179 /* ExpressionWithTypeArguments */; - } - function isNamespaceReference(node) { - return isQualifiedNameNamespaceReference(node) || isPropertyAccessNamespaceReference(node); - } - function isPropertyAccessNamespaceReference(node) { - var root = node; - var isLastClause = true; - if (root.parent.kind === 158 /* PropertyAccessExpression */) { - while (root.parent && root.parent.kind === 158 /* PropertyAccessExpression */) { - root = root.parent; - } - isLastClause = root.name === node; - } - if (!isLastClause && root.parent.kind === 179 /* ExpressionWithTypeArguments */ && root.parent.parent.kind === 225 /* HeritageClause */) { - var decl = root.parent.parent.parent; - return (decl.kind === 204 /* ClassDeclaration */ && root.parent.parent.token === 102 /* ImplementsKeyword */) || - (decl.kind === 205 /* InterfaceDeclaration */ && root.parent.parent.token === 79 /* ExtendsKeyword */); - } - return false; - } - function isQualifiedNameNamespaceReference(node) { - var root = node; - var isLastClause = true; - if (root.parent.kind === 128 /* QualifiedName */) { - while (root.parent && root.parent.kind === 128 /* QualifiedName */) { - root = root.parent; - } - isLastClause = root.right === node; - } - return root.parent.kind === 144 /* TypeReference */ && !isLastClause; - } - function isInRightSideOfImport(node) { - while (node.parent.kind === 128 /* QualifiedName */) { - node = node.parent; - } - return ts.isInternalModuleImportEqualsDeclaration(node.parent) && node.parent.moduleReference === node; - } - function getMeaningFromRightHandSideOfImportEquals(node) { - ts.Debug.assert(node.kind === 65 /* Identifier */); - // import a = |b|; // Namespace - // import a = |b.c|; // Value, type, namespace - // import a = |b.c|.d; // Namespace - if (node.parent.kind === 128 /* QualifiedName */ && - node.parent.right === node && - node.parent.parent.kind === 211 /* ImportEqualsDeclaration */) { - return 1 /* Value */ | 2 /* Type */ | 4 /* Namespace */; - } - return 4 /* Namespace */; - } - function getMeaningFromLocation(node) { - if (node.parent.kind === 217 /* ExportAssignment */) { - return 1 /* Value */ | 2 /* Type */ | 4 /* Namespace */; - } - else if (isInRightSideOfImport(node)) { - return getMeaningFromRightHandSideOfImportEquals(node); - } - else if (ts.isDeclarationName(node)) { - return getMeaningFromDeclaration(node.parent); - } - else if (isTypeReference(node)) { - return 2 /* Type */; - } - else if (isNamespaceReference(node)) { - return 4 /* Namespace */; - } - else { - return 1 /* Value */; - } - } - // Signature help - /** - * This is a semantic operation. - */ - function getSignatureHelpItems(fileName, position) { - synchronizeHostData(); - var sourceFile = getValidSourceFile(fileName); - return ts.SignatureHelp.getSignatureHelpItems(program, sourceFile, position, cancellationToken); - } - /// Syntactic features - function getSourceFile(fileName) { - return syntaxTreeCache.getCurrentSourceFile(fileName); - } - function getNameOrDottedNameSpan(fileName, startPos, endPos) { - var sourceFile = syntaxTreeCache.getCurrentSourceFile(fileName); - // Get node at the location - var node = ts.getTouchingPropertyName(sourceFile, startPos); - if (!node) { - return; - } - switch (node.kind) { - case 158 /* PropertyAccessExpression */: - case 128 /* QualifiedName */: - case 8 /* StringLiteral */: - case 80 /* FalseKeyword */: - case 95 /* TrueKeyword */: - case 89 /* NullKeyword */: - case 91 /* SuperKeyword */: - case 93 /* ThisKeyword */: - case 65 /* Identifier */: - break; - // Cant create the text span - default: - return; - } - var nodeForStartPos = node; - while (true) { - if (isRightSideOfPropertyAccess(nodeForStartPos) || isRightSideOfQualifiedName(nodeForStartPos)) { - // If on the span is in right side of the the property or qualified name, return the span from the qualified name pos to end of this node - nodeForStartPos = nodeForStartPos.parent; - } - else if (isNameOfModuleDeclaration(nodeForStartPos)) { - // If this is name of a module declarations, check if this is right side of dotted module name - // If parent of the module declaration which is parent of this node is module declaration and its body is the module declaration that this node is name of - // Then this name is name from dotted module - if (nodeForStartPos.parent.parent.kind === 208 /* ModuleDeclaration */ && - nodeForStartPos.parent.parent.body === nodeForStartPos.parent) { - // Use parent module declarations name for start pos - nodeForStartPos = nodeForStartPos.parent.parent.name; - } - else { - // We have to use this name for start pos - break; - } - } - else { - // Is not a member expression so we have found the node for start pos - break; - } - } - return ts.createTextSpanFromBounds(nodeForStartPos.getStart(), node.getEnd()); - } - function getBreakpointStatementAtPosition(fileName, position) { - // doesn't use compiler - no need to synchronize with host - var sourceFile = syntaxTreeCache.getCurrentSourceFile(fileName); - return ts.BreakpointResolver.spanInSourceFileAtLocation(sourceFile, position); - } - function getNavigationBarItems(fileName) { - var sourceFile = syntaxTreeCache.getCurrentSourceFile(fileName); - return ts.NavigationBar.getNavigationBarItems(sourceFile); - } - function getSemanticClassifications(fileName, span) { - return convertClassifications(getEncodedSemanticClassifications(fileName, span)); - } - function getEncodedSemanticClassifications(fileName, span) { - synchronizeHostData(); - var sourceFile = getValidSourceFile(fileName); - var typeChecker = program.getTypeChecker(); - var result = []; - var classifiableNames = program.getClassifiableNames(); - processNode(sourceFile); - return { spans: result, endOfLineState: 0 /* None */ }; - function pushClassification(start, length, type) { - result.push(start); - result.push(length); - result.push(type); - } - function classifySymbol(symbol, meaningAtPosition) { - var flags = symbol.getFlags(); - if ((flags & 788448 /* Classifiable */) === 0 /* None */) { - return; - } - if (flags & 32 /* Class */) { - return 11 /* className */; - } - else if (flags & 384 /* Enum */) { - return 12 /* enumName */; - } - else if (flags & 524288 /* TypeAlias */) { - return 16 /* typeAliasName */; - } - else if (meaningAtPosition & 2 /* Type */) { - if (flags & 64 /* Interface */) { - return 13 /* interfaceName */; - } - else if (flags & 262144 /* TypeParameter */) { - return 15 /* typeParameterName */; - } - } - else if (flags & 1536 /* Module */) { - // Only classify a module as such if - // - It appears in a namespace context. - // - There exists a module declaration which actually impacts the value side. - if (meaningAtPosition & 4 /* Namespace */ || - (meaningAtPosition & 1 /* Value */ && hasValueSideModule(symbol))) { - return 14 /* moduleName */; - } - } - return undefined; - /** - * Returns true if there exists a module that introduces entities on the value side. - */ - function hasValueSideModule(symbol) { - return ts.forEach(symbol.declarations, function (declaration) { - return declaration.kind === 208 /* ModuleDeclaration */ && ts.getModuleInstanceState(declaration) == 1 /* Instantiated */; - }); - } - } - function processNode(node) { - // Only walk into nodes that intersect the requested span. - if (node && ts.textSpanIntersectsWith(span, node.getFullStart(), node.getFullWidth())) { - if (node.kind === 65 /* Identifier */ && !ts.nodeIsMissing(node)) { - var identifier = node; - // Only bother calling into the typechecker if this is an identifier that - // could possibly resolve to a type name. This makes classification run - // in a third of the time it would normally take. - if (classifiableNames[identifier.text]) { - var symbol = typeChecker.getSymbolAtLocation(node); - if (symbol) { - var type = classifySymbol(symbol, getMeaningFromLocation(node)); - if (type) { - pushClassification(node.getStart(), node.getWidth(), type); - } - } - } - } - ts.forEachChild(node, processNode); - } - } - } - function getClassificationTypeName(type) { - switch (type) { - case 1 /* comment */: return ClassificationTypeNames.comment; - case 2 /* identifier */: return ClassificationTypeNames.identifier; - case 3 /* keyword */: return ClassificationTypeNames.keyword; - case 4 /* numericLiteral */: return ClassificationTypeNames.numericLiteral; - case 5 /* operator */: return ClassificationTypeNames.operator; - case 6 /* stringLiteral */: return ClassificationTypeNames.stringLiteral; - case 8 /* whiteSpace */: return ClassificationTypeNames.whiteSpace; - case 9 /* text */: return ClassificationTypeNames.text; - case 10 /* punctuation */: return ClassificationTypeNames.punctuation; - case 11 /* className */: return ClassificationTypeNames.className; - case 12 /* enumName */: return ClassificationTypeNames.enumName; - case 13 /* interfaceName */: return ClassificationTypeNames.interfaceName; - case 14 /* moduleName */: return ClassificationTypeNames.moduleName; - case 15 /* typeParameterName */: return ClassificationTypeNames.typeParameterName; - case 16 /* typeAliasName */: return ClassificationTypeNames.typeAliasName; - case 17 /* parameterName */: return ClassificationTypeNames.parameterName; - case 18 /* docCommentTagName */: return ClassificationTypeNames.docCommentTagName; - } - } - function convertClassifications(classifications) { - ts.Debug.assert(classifications.spans.length % 3 === 0); - var dense = classifications.spans; - var result = []; - for (var i = 0, n = dense.length; i < n; i += 3) { - result.push({ - textSpan: ts.createTextSpan(dense[i], dense[i + 1]), - classificationType: getClassificationTypeName(dense[i + 2]) - }); - } - return result; - } - function getSyntacticClassifications(fileName, span) { - return convertClassifications(getEncodedSyntacticClassifications(fileName, span)); - } - function getEncodedSyntacticClassifications(fileName, span) { - // doesn't use compiler - no need to synchronize with host - var sourceFile = syntaxTreeCache.getCurrentSourceFile(fileName); - // Make a scanner we can get trivia from. - var triviaScanner = ts.createScanner(2 /* Latest */, false, sourceFile.text); - var mergeConflictScanner = ts.createScanner(2 /* Latest */, false, sourceFile.text); - var result = []; - processElement(sourceFile); - return { spans: result, endOfLineState: 0 /* None */ }; - function pushClassification(start, length, type) { - result.push(start); - result.push(length); - result.push(type); - } - function classifyLeadingTrivia(token) { - var tokenStart = ts.skipTrivia(sourceFile.text, token.pos, false); - if (tokenStart === token.pos) { - return; - } - // token has trivia. Classify them appropriately. - triviaScanner.setTextPos(token.pos); - while (true) { - var start = triviaScanner.getTextPos(); - var kind = triviaScanner.scan(); - var end = triviaScanner.getTextPos(); - var width = end - start; - // The moment we get something that isn't trivia, then stop processing. - if (!ts.isTrivia(kind)) { - return; - } - // Only bother with the trivia if it at least intersects the span of interest. - if (ts.textSpanIntersectsWith(span, start, width)) { - if (ts.isComment(kind)) { - classifyComment(token, kind, start, width); - continue; - } - if (kind === 6 /* ConflictMarkerTrivia */) { - var text = sourceFile.text; - var ch = text.charCodeAt(start); - // for the <<<<<<< and >>>>>>> markers, we just add them in as comments - // in the classification stream. - if (ch === 60 /* lessThan */ || ch === 62 /* greaterThan */) { - pushClassification(start, width, 1 /* comment */); - continue; - } - // for the ======== add a comment for the first line, and then lex all - // subsequent lines up until the end of the conflict marker. - ts.Debug.assert(ch === 61 /* equals */); - classifyDisabledMergeCode(text, start, end); - } - } - } - } - function classifyComment(token, kind, start, width) { - if (kind === 3 /* MultiLineCommentTrivia */) { - // See if this is a doc comment. If so, we'll classify certain portions of it - // specially. - var docCommentAndDiagnostics = ts.parseIsolatedJSDocComment(sourceFile.text, start, width); - if (docCommentAndDiagnostics && docCommentAndDiagnostics.jsDocComment) { - docCommentAndDiagnostics.jsDocComment.parent = token; - classifyJSDocComment(docCommentAndDiagnostics.jsDocComment); - return; - } - } - // Simple comment. Just add as is. - pushCommentRange(start, width); - } - function pushCommentRange(start, width) { - pushClassification(start, width, 1 /* comment */); - } - function classifyJSDocComment(docComment) { - var pos = docComment.pos; - for (var _i = 0, _a = docComment.tags; _i < _a.length; _i++) { - var tag = _a[_i]; - // As we walk through each tag, classify the portion of text from the end of - // the last tag (or the start of the entire doc comment) as 'comment'. - if (tag.pos !== pos) { - pushCommentRange(pos, tag.pos - pos); - } - pushClassification(tag.atToken.pos, tag.atToken.end - tag.atToken.pos, 10 /* punctuation */); - pushClassification(tag.tagName.pos, tag.tagName.end - tag.tagName.pos, 18 /* docCommentTagName */); - pos = tag.tagName.end; - switch (tag.kind) { - case 249 /* JSDocParameterTag */: - processJSDocParameterTag(tag); - break; - case 252 /* JSDocTemplateTag */: - processJSDocTemplateTag(tag); - break; - case 251 /* JSDocTypeTag */: - processElement(tag.typeExpression); - break; - case 250 /* JSDocReturnTag */: - processElement(tag.typeExpression); - break; - } - pos = tag.end; - } - if (pos !== docComment.end) { - pushCommentRange(pos, docComment.end - pos); - } - return; - function processJSDocParameterTag(tag) { - if (tag.preParameterName) { - pushCommentRange(pos, tag.preParameterName.pos - pos); - pushClassification(tag.preParameterName.pos, tag.preParameterName.end - tag.preParameterName.pos, 17 /* parameterName */); - pos = tag.preParameterName.end; - } - if (tag.typeExpression) { - pushCommentRange(pos, tag.typeExpression.pos - pos); - processElement(tag.typeExpression); - pos = tag.typeExpression.end; - } - if (tag.postParameterName) { - pushCommentRange(pos, tag.postParameterName.pos - pos); - pushClassification(tag.postParameterName.pos, tag.postParameterName.end - tag.postParameterName.pos, 17 /* parameterName */); - pos = tag.postParameterName.end; - } - } - } - function processJSDocTemplateTag(tag) { - for (var _i = 0, _a = tag.getChildren(); _i < _a.length; _i++) { - var child = _a[_i]; - processElement(child); - } - } - function classifyDisabledMergeCode(text, start, end) { - // Classify the line that the ======= marker is on as a comment. Then just lex - // all further tokens and add them to the result. - for (var i = start; i < end; i++) { - if (ts.isLineBreak(text.charCodeAt(i))) { - break; - } - } - pushClassification(start, i - start, 1 /* comment */); - mergeConflictScanner.setTextPos(i); - while (mergeConflictScanner.getTextPos() < end) { - classifyDisabledCodeToken(); - } - } - function classifyDisabledCodeToken() { - var start = mergeConflictScanner.getTextPos(); - var tokenKind = mergeConflictScanner.scan(); - var end = mergeConflictScanner.getTextPos(); - var type = classifyTokenType(tokenKind); - if (type) { - pushClassification(start, end - start, type); - } - } - function classifyToken(token) { - classifyLeadingTrivia(token); - if (token.getWidth() > 0) { - var type = classifyTokenType(token.kind, token); - if (type) { - pushClassification(token.getStart(), token.getWidth(), type); - } - } - } - // for accurate classification, the actual token should be passed in. however, for - // cases like 'disabled merge code' classification, we just get the token kind and - // classify based on that instead. - function classifyTokenType(tokenKind, token) { - if (ts.isKeyword(tokenKind)) { - return 3 /* keyword */; - } - // Special case < and > If they appear in a generic context they are punctuation, - // not operators. - if (tokenKind === 24 /* LessThanToken */ || tokenKind === 25 /* GreaterThanToken */) { - // If the node owning the token has a type argument list or type parameter list, then - // we can effectively assume that a '<' and '>' belong to those lists. - if (token && ts.getTypeArgumentOrTypeParameterList(token.parent)) { - return 10 /* punctuation */; - } - } - if (ts.isPunctuation(tokenKind)) { - if (token) { - if (tokenKind === 53 /* EqualsToken */) { - // the '=' in a variable declaration is special cased here. - if (token.parent.kind === 201 /* VariableDeclaration */ || - token.parent.kind === 134 /* PropertyDeclaration */ || - token.parent.kind === 131 /* Parameter */) { - return 5 /* operator */; - } - } - if (token.parent.kind === 172 /* BinaryExpression */ || - token.parent.kind === 170 /* PrefixUnaryExpression */ || - token.parent.kind === 171 /* PostfixUnaryExpression */ || - token.parent.kind === 173 /* ConditionalExpression */) { - return 5 /* operator */; - } - } - return 10 /* punctuation */; - } - else if (tokenKind === 7 /* NumericLiteral */) { - return 4 /* numericLiteral */; - } - else if (tokenKind === 8 /* StringLiteral */) { - return 6 /* stringLiteral */; - } - else if (tokenKind === 9 /* RegularExpressionLiteral */) { - // TODO: we should get another classification type for these literals. - return 6 /* stringLiteral */; - } - else if (ts.isTemplateLiteralKind(tokenKind)) { - // TODO (drosen): we should *also* get another classification type for these literals. - return 6 /* stringLiteral */; - } - else if (tokenKind === 65 /* Identifier */) { - if (token) { - switch (token.parent.kind) { - case 204 /* ClassDeclaration */: - if (token.parent.name === token) { - return 11 /* className */; - } - return; - case 130 /* TypeParameter */: - if (token.parent.name === token) { - return 15 /* typeParameterName */; - } - return; - case 205 /* InterfaceDeclaration */: - if (token.parent.name === token) { - return 13 /* interfaceName */; - } - return; - case 207 /* EnumDeclaration */: - if (token.parent.name === token) { - return 12 /* enumName */; - } - return; - case 208 /* ModuleDeclaration */: - if (token.parent.name === token) { - return 14 /* moduleName */; - } - return; - case 131 /* Parameter */: - if (token.parent.name === token) { - return 17 /* parameterName */; - } - return; - } - } - return 9 /* text */; - } - } - function processElement(element) { - if (!element) { - return; - } - // Ignore nodes that don't intersect the original span to classify. - if (ts.textSpanIntersectsWith(span, element.getFullStart(), element.getFullWidth())) { - var children = element.getChildren(sourceFile); - for (var _i = 0; _i < children.length; _i++) { - var child = children[_i]; - if (ts.isToken(child)) { - classifyToken(child); - } - else { - // Recurse into our child nodes. - processElement(child); - } - } - } - } - } - function getOutliningSpans(fileName) { - // doesn't use compiler - no need to synchronize with host - var sourceFile = syntaxTreeCache.getCurrentSourceFile(fileName); - return ts.OutliningElementsCollector.collectElements(sourceFile); - } - function getBraceMatchingAtPosition(fileName, position) { - var sourceFile = syntaxTreeCache.getCurrentSourceFile(fileName); - var result = []; - var token = ts.getTouchingToken(sourceFile, position); - if (token.getStart(sourceFile) === position) { - var matchKind = getMatchingTokenKind(token); - // Ensure that there is a corresponding token to match ours. - if (matchKind) { - var parentElement = token.parent; - var childNodes = parentElement.getChildren(sourceFile); - for (var _i = 0; _i < childNodes.length; _i++) { - var current = childNodes[_i]; - if (current.kind === matchKind) { - var range1 = ts.createTextSpan(token.getStart(sourceFile), token.getWidth(sourceFile)); - var range2 = ts.createTextSpan(current.getStart(sourceFile), current.getWidth(sourceFile)); - // We want to order the braces when we return the result. - if (range1.start < range2.start) { - result.push(range1, range2); - } - else { - result.push(range2, range1); - } - break; - } - } - } - } - return result; - function getMatchingTokenKind(token) { - switch (token.kind) { - case 14 /* OpenBraceToken */: return 15 /* CloseBraceToken */; - case 16 /* OpenParenToken */: return 17 /* CloseParenToken */; - case 18 /* OpenBracketToken */: return 19 /* CloseBracketToken */; - case 24 /* LessThanToken */: return 25 /* GreaterThanToken */; - case 15 /* CloseBraceToken */: return 14 /* OpenBraceToken */; - case 17 /* CloseParenToken */: return 16 /* OpenParenToken */; - case 19 /* CloseBracketToken */: return 18 /* OpenBracketToken */; - case 25 /* GreaterThanToken */: return 24 /* LessThanToken */; - } - return undefined; - } - } - function getIndentationAtPosition(fileName, position, editorOptions) { - var start = new Date().getTime(); - var sourceFile = syntaxTreeCache.getCurrentSourceFile(fileName); - log("getIndentationAtPosition: getCurrentSourceFile: " + (new Date().getTime() - start)); - start = new Date().getTime(); - var result = ts.formatting.SmartIndenter.getIndentation(position, sourceFile, editorOptions); - log("getIndentationAtPosition: computeIndentation : " + (new Date().getTime() - start)); - return result; - } - function getFormattingEditsForRange(fileName, start, end, options) { - var sourceFile = syntaxTreeCache.getCurrentSourceFile(fileName); - return ts.formatting.formatSelection(start, end, sourceFile, getRuleProvider(options), options); - } - function getFormattingEditsForDocument(fileName, options) { - var sourceFile = syntaxTreeCache.getCurrentSourceFile(fileName); - return ts.formatting.formatDocument(sourceFile, getRuleProvider(options), options); - } - function getFormattingEditsAfterKeystroke(fileName, position, key, options) { - var sourceFile = syntaxTreeCache.getCurrentSourceFile(fileName); - if (key === "}") { - return ts.formatting.formatOnClosingCurly(position, sourceFile, getRuleProvider(options), options); - } - else if (key === ";") { - return ts.formatting.formatOnSemicolon(position, sourceFile, getRuleProvider(options), options); - } - else if (key === "\n") { - return ts.formatting.formatOnEnter(position, sourceFile, getRuleProvider(options), options); - } - return []; - } - function getTodoComments(fileName, descriptors) { - // Note: while getting todo comments seems like a syntactic operation, we actually - // treat it as a semantic operation here. This is because we expect our host to call - // this on every single file. If we treat this syntactically, then that will cause - // us to populate and throw away the tree in our syntax tree cache for each file. By - // treating this as a semantic operation, we can access any tree without throwing - // anything away. - synchronizeHostData(); - var sourceFile = getValidSourceFile(fileName); - cancellationToken.throwIfCancellationRequested(); - var fileContents = sourceFile.text; - var result = []; - if (descriptors.length > 0) { - var regExp = getTodoCommentsRegExp(); - var matchArray; - while (matchArray = regExp.exec(fileContents)) { - cancellationToken.throwIfCancellationRequested(); - // If we got a match, here is what the match array will look like. Say the source text is: - // - // " // hack 1" - // - // The result array with the regexp: will be: - // - // ["// hack 1", "// ", "hack 1", undefined, "hack"] - // - // Here are the relevant capture groups: - // 0) The full match for the entire regexp. - // 1) The preamble to the message portion. - // 2) The message portion. - // 3...N) The descriptor that was matched - by index. 'undefined' for each - // descriptor that didn't match. an actual value if it did match. - // - // i.e. 'undefined' in position 3 above means TODO(jason) didn't match. - // "hack" in position 4 means HACK did match. - var firstDescriptorCaptureIndex = 3; - ts.Debug.assert(matchArray.length === descriptors.length + firstDescriptorCaptureIndex); - var preamble = matchArray[1]; - var matchPosition = matchArray.index + preamble.length; - // OK, we have found a match in the file. This is only an acceptable match if - // it is contained within a comment. - var token = ts.getTokenAtPosition(sourceFile, matchPosition); - if (!isInsideComment(sourceFile, token, matchPosition)) { - continue; - } - var descriptor = undefined; - for (var i = 0, n = descriptors.length; i < n; i++) { - if (matchArray[i + firstDescriptorCaptureIndex]) { - descriptor = descriptors[i]; - } - } - ts.Debug.assert(descriptor !== undefined); - // We don't want to match something like 'TODOBY', so we make sure a non - // letter/digit follows the match. - if (isLetterOrDigit(fileContents.charCodeAt(matchPosition + descriptor.text.length))) { - continue; - } - var message = matchArray[2]; - result.push({ - descriptor: descriptor, - message: message, - position: matchPosition - }); - } - } - return result; - function escapeRegExp(str) { - return str.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g, "\\$&"); - } - function getTodoCommentsRegExp() { - // NOTE: ?: means 'non-capture group'. It allows us to have groups without having to - // filter them out later in the final result array. - // TODO comments can appear in one of the following forms: - // - // 1) // TODO or /////////// TODO - // - // 2) /* TODO or /********** TODO - // - // 3) /* - // * TODO - // */ - // - // The following three regexps are used to match the start of the text up to the TODO - // comment portion. - var singleLineCommentStart = /(?:\/\/+\s*)/.source; - var multiLineCommentStart = /(?:\/\*+\s*)/.source; - var anyNumberOfSpacesAndAsterixesAtStartOfLine = /(?:^(?:\s|\*)*)/.source; - // Match any of the above three TODO comment start regexps. - // Note that the outermost group *is* a capture group. We want to capture the preamble - // so that we can determine the starting position of the TODO comment match. - var preamble = "(" + anyNumberOfSpacesAndAsterixesAtStartOfLine + "|" + singleLineCommentStart + "|" + multiLineCommentStart + ")"; - // Takes the descriptors and forms a regexp that matches them as if they were literals. - // For example, if the descriptors are "TODO(jason)" and "HACK", then this will be: - // - // (?:(TODO\(jason\))|(HACK)) - // - // Note that the outermost group is *not* a capture group, but the innermost groups - // *are* capture groups. By capturing the inner literals we can determine after - // matching which descriptor we are dealing with. - var literals = "(?:" + ts.map(descriptors, function (d) { return "(" + escapeRegExp(d.text) + ")"; }).join("|") + ")"; - // After matching a descriptor literal, the following regexp matches the rest of the - // text up to the end of the line (or */). - var endOfLineOrEndOfComment = /(?:$|\*\/)/.source; - var messageRemainder = /(?:.*?)/.source; - // This is the portion of the match we'll return as part of the TODO comment result. We - // match the literal portion up to the end of the line or end of comment. - var messagePortion = "(" + literals + messageRemainder + ")"; - var regExpString = preamble + messagePortion + endOfLineOrEndOfComment; - // The final regexp will look like this: - // /((?:\/\/+\s*)|(?:\/\*+\s*)|(?:^(?:\s|\*)*))((?:(TODO\(jason\))|(HACK))(?:.*?))(?:$|\*\/)/gim - // The flags of the regexp are important here. - // 'g' is so that we are doing a global search and can find matches several times - // in the input. - // - // 'i' is for case insensitivity (We do this to match C# TODO comment code). - // - // 'm' is so we can find matches in a multi-line input. - return new RegExp(regExpString, "gim"); - } - function isLetterOrDigit(char) { - return (char >= 97 /* a */ && char <= 122 /* z */) || - (char >= 65 /* A */ && char <= 90 /* Z */) || - (char >= 48 /* _0 */ && char <= 57 /* _9 */); - } - } - function getRenameInfo(fileName, position) { - synchronizeHostData(); - var sourceFile = getValidSourceFile(fileName); - var typeChecker = program.getTypeChecker(); - var node = ts.getTouchingWord(sourceFile, position); - // Can only rename an identifier. - if (node && node.kind === 65 /* Identifier */) { - var symbol = typeChecker.getSymbolAtLocation(node); - // Only allow a symbol to be renamed if it actually has at least one declaration. - if (symbol) { - var declarations = symbol.getDeclarations(); - if (declarations && declarations.length > 0) { - // Disallow rename for elements that are defined in the standard TypeScript library. - var defaultLibFileName = host.getDefaultLibFileName(host.getCompilationSettings()); - if (defaultLibFileName) { - for (var _i = 0; _i < declarations.length; _i++) { - var current = declarations[_i]; - var sourceFile_2 = current.getSourceFile(); - if (sourceFile_2 && getCanonicalFileName(ts.normalizePath(sourceFile_2.fileName)) === getCanonicalFileName(ts.normalizePath(defaultLibFileName))) { - return getRenameInfoError(ts.getLocaleSpecificMessage(ts.Diagnostics.You_cannot_rename_elements_that_are_defined_in_the_standard_TypeScript_library.key)); - } - } - } - var kind = getSymbolKind(symbol, node); - if (kind) { - return { - canRename: true, - localizedErrorMessage: undefined, - displayName: symbol.name, - fullDisplayName: typeChecker.getFullyQualifiedName(symbol), - kind: kind, - kindModifiers: getSymbolModifiers(symbol), - triggerSpan: ts.createTextSpan(node.getStart(), node.getWidth()) - }; - } - } - } - } - return getRenameInfoError(ts.getLocaleSpecificMessage(ts.Diagnostics.You_cannot_rename_this_element.key)); - function getRenameInfoError(localizedErrorMessage) { - return { - canRename: false, - localizedErrorMessage: localizedErrorMessage, - displayName: undefined, - fullDisplayName: undefined, - kind: undefined, - kindModifiers: undefined, - triggerSpan: undefined - }; - } - } - return { - dispose: dispose, - cleanupSemanticCache: cleanupSemanticCache, - getSyntacticDiagnostics: getSyntacticDiagnostics, - getSemanticDiagnostics: getSemanticDiagnostics, - getCompilerOptionsDiagnostics: getCompilerOptionsDiagnostics, - getSyntacticClassifications: getSyntacticClassifications, - getSemanticClassifications: getSemanticClassifications, - getEncodedSyntacticClassifications: getEncodedSyntacticClassifications, - getEncodedSemanticClassifications: getEncodedSemanticClassifications, - getCompletionsAtPosition: getCompletionsAtPosition, - getCompletionEntryDetails: getCompletionEntryDetails, - getSignatureHelpItems: getSignatureHelpItems, - getQuickInfoAtPosition: getQuickInfoAtPosition, - getDefinitionAtPosition: getDefinitionAtPosition, - getTypeDefinitionAtPosition: getTypeDefinitionAtPosition, - getReferencesAtPosition: getReferencesAtPosition, - findReferences: findReferences, - getOccurrencesAtPosition: getOccurrencesAtPosition, - getDocumentHighlights: getDocumentHighlights, - getNameOrDottedNameSpan: getNameOrDottedNameSpan, - getBreakpointStatementAtPosition: getBreakpointStatementAtPosition, - getNavigateToItems: getNavigateToItems, - getRenameInfo: getRenameInfo, - findRenameLocations: findRenameLocations, - getNavigationBarItems: getNavigationBarItems, - getOutliningSpans: getOutliningSpans, - getTodoComments: getTodoComments, - getBraceMatchingAtPosition: getBraceMatchingAtPosition, - getIndentationAtPosition: getIndentationAtPosition, - getFormattingEditsForRange: getFormattingEditsForRange, - getFormattingEditsForDocument: getFormattingEditsForDocument, - getFormattingEditsAfterKeystroke: getFormattingEditsAfterKeystroke, - getEmitOutput: getEmitOutput, - getSourceFile: getSourceFile, - getProgram: getProgram - }; - } - ts.createLanguageService = createLanguageService; - /* @internal */ - function getNameTable(sourceFile) { - if (!sourceFile.nameTable) { - initializeNameTable(sourceFile); - } - return sourceFile.nameTable; - } - ts.getNameTable = getNameTable; - function initializeNameTable(sourceFile) { - var nameTable = {}; - walk(sourceFile); - sourceFile.nameTable = nameTable; - function walk(node) { - switch (node.kind) { - case 65 /* Identifier */: - nameTable[node.text] = node.text; - break; - case 8 /* StringLiteral */: - case 7 /* NumericLiteral */: - // We want to store any numbers/strings if they were a name that could be - // related to a declaration. So, if we have 'import x = require("something")' - // then we want 'something' to be in the name table. Similarly, if we have - // "a['propname']" then we want to store "propname" in the name table. - if (ts.isDeclarationName(node) || - node.parent.kind === 222 /* ExternalModuleReference */ || - isArgumentOfElementAccessExpression(node)) { - nameTable[node.text] = node.text; - } - break; - default: - ts.forEachChild(node, walk); - } - } - } - function isArgumentOfElementAccessExpression(node) { - return node && - node.parent && - node.parent.kind === 159 /* ElementAccessExpression */ && - node.parent.argumentExpression === node; - } - /// Classifier - function createClassifier() { - var scanner = ts.createScanner(2 /* Latest */, false); - /// We do not have a full parser support to know when we should parse a regex or not - /// If we consider every slash token to be a regex, we could be missing cases like "1/2/3", where - /// we have a series of divide operator. this list allows us to be more accurate by ruling out - /// locations where a regexp cannot exist. - var noRegexTable = []; - noRegexTable[65 /* Identifier */] = true; - noRegexTable[8 /* StringLiteral */] = true; - noRegexTable[7 /* NumericLiteral */] = true; - noRegexTable[9 /* RegularExpressionLiteral */] = true; - noRegexTable[93 /* ThisKeyword */] = true; - noRegexTable[38 /* PlusPlusToken */] = true; - noRegexTable[39 /* MinusMinusToken */] = true; - noRegexTable[17 /* CloseParenToken */] = true; - noRegexTable[19 /* CloseBracketToken */] = true; - noRegexTable[15 /* CloseBraceToken */] = true; - noRegexTable[95 /* TrueKeyword */] = true; - noRegexTable[80 /* FalseKeyword */] = true; - // Just a stack of TemplateHeads and OpenCurlyBraces, used to perform rudimentary (inexact) - // classification on template strings. Because of the context free nature of templates, - // the only precise way to classify a template portion would be by propagating the stack across - // lines, just as we do with the end-of-line state. However, this is a burden for implementers, - // and the behavior is entirely subsumed by the syntactic classifier anyway, so we instead - // flatten any nesting when the template stack is non-empty and encode it in the end-of-line state. - // Situations in which this fails are - // 1) When template strings are nested across different lines: - // `hello ${ `world - // ` }` - // - // Where on the second line, you will get the closing of a template, - // a closing curly, and a new template. - // - // 2) When substitution expressions have curly braces and the curly brace falls on the next line: - // `hello ${ () => { - // return "world" } } ` - // - // Where on the second line, you will get the 'return' keyword, - // a string literal, and a template end consisting of '} } `'. - var templateStack = []; - /** Returns true if 'keyword2' can legally follow 'keyword1' in any language construct. */ - function canFollow(keyword1, keyword2) { - if (ts.isAccessibilityModifier(keyword1)) { - if (keyword2 === 116 /* GetKeyword */ || - keyword2 === 122 /* SetKeyword */ || - keyword2 === 114 /* ConstructorKeyword */ || - keyword2 === 109 /* StaticKeyword */) { - // Allow things like "public get", "public constructor" and "public static". - // These are all legal. - return true; - } - // Any other keyword following "public" is actually an identifier an not a real - // keyword. - return false; - } - // Assume any other keyword combination is legal. This can be refined in the future - // if there are more cases we want the classifier to be better at. - return true; - } - function convertClassifications(classifications, text) { - var entries = []; - var dense = classifications.spans; - var lastEnd = 0; - for (var i = 0, n = dense.length; i < n; i += 3) { - var start = dense[i]; - var length_2 = dense[i + 1]; - var type = dense[i + 2]; - // Make a whitespace entry between the last item and this one. - if (lastEnd >= 0) { - var whitespaceLength_1 = start - lastEnd; - if (whitespaceLength_1 > 0) { - entries.push({ length: whitespaceLength_1, classification: TokenClass.Whitespace }); - } - } - entries.push({ length: length_2, classification: convertClassification(type) }); - lastEnd = start + length_2; - } - var whitespaceLength = text.length - lastEnd; - if (whitespaceLength > 0) { - entries.push({ length: whitespaceLength, classification: TokenClass.Whitespace }); - } - return { entries: entries, finalLexState: classifications.endOfLineState }; - } - function convertClassification(type) { - switch (type) { - case 1 /* comment */: return TokenClass.Comment; - case 3 /* keyword */: return TokenClass.Keyword; - case 4 /* numericLiteral */: return TokenClass.NumberLiteral; - case 5 /* operator */: return TokenClass.Operator; - case 6 /* stringLiteral */: return TokenClass.StringLiteral; - case 8 /* whiteSpace */: return TokenClass.Whitespace; - case 10 /* punctuation */: return TokenClass.Punctuation; - case 2 /* identifier */: - case 11 /* className */: - case 12 /* enumName */: - case 13 /* interfaceName */: - case 14 /* moduleName */: - case 15 /* typeParameterName */: - case 16 /* typeAliasName */: - case 9 /* text */: - case 17 /* parameterName */: - default: - return TokenClass.Identifier; - } - } - function getClassificationsForLine(text, lexState, syntacticClassifierAbsent) { - return convertClassifications(getEncodedLexicalClassifications(text, lexState, syntacticClassifierAbsent), text); - } - // If there is a syntactic classifier ('syntacticClassifierAbsent' is false), - // we will be more conservative in order to avoid conflicting with the syntactic classifier. - function getEncodedLexicalClassifications(text, lexState, syntacticClassifierAbsent) { - var offset = 0; - var token = 0 /* Unknown */; - var lastNonTriviaToken = 0 /* Unknown */; - // Empty out the template stack for reuse. - while (templateStack.length > 0) { - templateStack.pop(); - } - // If we're in a string literal, then prepend: "\ - // (and a newline). That way when we lex we'll think we're still in a string literal. - // - // If we're in a multiline comment, then prepend: /* - // (and a newline). That way when we lex we'll think we're still in a multiline comment. - switch (lexState) { - case 3 /* InDoubleQuoteStringLiteral */: - text = '"\\\n' + text; - offset = 3; - break; - case 2 /* InSingleQuoteStringLiteral */: - text = "'\\\n" + text; - offset = 3; - break; - case 1 /* InMultiLineCommentTrivia */: - text = "/*\n" + text; - offset = 3; - break; - case 4 /* InTemplateHeadOrNoSubstitutionTemplate */: - text = "`\n" + text; - offset = 2; - break; - case 5 /* InTemplateMiddleOrTail */: - text = "}\n" + text; - offset = 2; - // fallthrough - case 6 /* InTemplateSubstitutionPosition */: - templateStack.push(11 /* TemplateHead */); - break; - } - scanner.setText(text); - var result = { - endOfLineState: 0 /* None */, - spans: [] - }; - // We can run into an unfortunate interaction between the lexical and syntactic classifier - // when the user is typing something generic. Consider the case where the user types: - // - // Foo tokens. It's a weak heuristic, but should - // work well enough in practice. - var angleBracketStack = 0; - do { - token = scanner.scan(); - if (!ts.isTrivia(token)) { - if ((token === 36 /* SlashToken */ || token === 57 /* SlashEqualsToken */) && !noRegexTable[lastNonTriviaToken]) { - if (scanner.reScanSlashToken() === 9 /* RegularExpressionLiteral */) { - token = 9 /* RegularExpressionLiteral */; - } - } - else if (lastNonTriviaToken === 20 /* DotToken */ && isKeyword(token)) { - token = 65 /* Identifier */; - } - else if (isKeyword(lastNonTriviaToken) && isKeyword(token) && !canFollow(lastNonTriviaToken, token)) { - // We have two keywords in a row. Only treat the second as a keyword if - // it's a sequence that could legally occur in the language. Otherwise - // treat it as an identifier. This way, if someone writes "private var" - // we recognize that 'var' is actually an identifier here. - token = 65 /* Identifier */; - } - else if (lastNonTriviaToken === 65 /* Identifier */ && - token === 24 /* LessThanToken */) { - // Could be the start of something generic. Keep track of that by bumping - // up the current count of generic contexts we may be in. - angleBracketStack++; - } - else if (token === 25 /* GreaterThanToken */ && angleBracketStack > 0) { - // If we think we're currently in something generic, then mark that that - // generic entity is complete. - angleBracketStack--; - } - else if (token === 112 /* AnyKeyword */ || - token === 123 /* StringKeyword */ || - token === 121 /* NumberKeyword */ || - token === 113 /* BooleanKeyword */ || - token === 124 /* SymbolKeyword */) { - if (angleBracketStack > 0 && !syntacticClassifierAbsent) { - // If it looks like we're could be in something generic, don't classify this - // as a keyword. We may just get overwritten by the syntactic classifier, - // causing a noisy experience for the user. - token = 65 /* Identifier */; - } - } - else if (token === 11 /* TemplateHead */) { - templateStack.push(token); - } - else if (token === 14 /* OpenBraceToken */) { - // If we don't have anything on the template stack, - // then we aren't trying to keep track of a previously scanned template head. - if (templateStack.length > 0) { - templateStack.push(token); - } - } - else if (token === 15 /* CloseBraceToken */) { - // If we don't have anything on the template stack, - // then we aren't trying to keep track of a previously scanned template head. - if (templateStack.length > 0) { - var lastTemplateStackToken = ts.lastOrUndefined(templateStack); - if (lastTemplateStackToken === 11 /* TemplateHead */) { - token = scanner.reScanTemplateToken(); - // Only pop on a TemplateTail; a TemplateMiddle indicates there is more for us. - if (token === 13 /* TemplateTail */) { - templateStack.pop(); - } - else { - ts.Debug.assert(token === 12 /* TemplateMiddle */, "Should have been a template middle. Was " + token); - } - } - else { - ts.Debug.assert(lastTemplateStackToken === 14 /* OpenBraceToken */, "Should have been an open brace. Was: " + token); - templateStack.pop(); - } - } - } - lastNonTriviaToken = token; - } - processToken(); - } while (token !== 1 /* EndOfFileToken */); - return result; - function processToken() { - var start = scanner.getTokenPos(); - var end = scanner.getTextPos(); - addResult(start, end, classFromKind(token)); - if (end >= text.length) { - if (token === 8 /* StringLiteral */) { - // Check to see if we finished up on a multiline string literal. - var tokenText = scanner.getTokenText(); - if (scanner.isUnterminated()) { - var lastCharIndex = tokenText.length - 1; - var numBackslashes = 0; - while (tokenText.charCodeAt(lastCharIndex - numBackslashes) === 92 /* backslash */) { - numBackslashes++; - } - // If we have an odd number of backslashes, then the multiline string is unclosed - if (numBackslashes & 1) { - var quoteChar = tokenText.charCodeAt(0); - result.endOfLineState = quoteChar === 34 /* doubleQuote */ - ? 3 /* InDoubleQuoteStringLiteral */ - : 2 /* InSingleQuoteStringLiteral */; - } - } - } - else if (token === 3 /* MultiLineCommentTrivia */) { - // Check to see if the multiline comment was unclosed. - if (scanner.isUnterminated()) { - result.endOfLineState = 1 /* InMultiLineCommentTrivia */; - } - } - else if (ts.isTemplateLiteralKind(token)) { - if (scanner.isUnterminated()) { - if (token === 13 /* TemplateTail */) { - result.endOfLineState = 5 /* InTemplateMiddleOrTail */; - } - else if (token === 10 /* NoSubstitutionTemplateLiteral */) { - result.endOfLineState = 4 /* InTemplateHeadOrNoSubstitutionTemplate */; - } - else { - ts.Debug.fail("Only 'NoSubstitutionTemplateLiteral's and 'TemplateTail's can be unterminated; got SyntaxKind #" + token); - } - } - } - else if (templateStack.length > 0 && ts.lastOrUndefined(templateStack) === 11 /* TemplateHead */) { - result.endOfLineState = 6 /* InTemplateSubstitutionPosition */; - } - } - } - function addResult(start, end, classification) { - if (classification === 8 /* whiteSpace */) { - // Don't bother with whitespace classifications. They're not needed. - return; - } - if (start === 0 && offset > 0) { - // We're classifying the first token, and this was a case where we prepended - // text. We should consider the start of this token to be at the start of - // the original text. - start += offset; - } - // All our tokens are in relation to the augmented text. Move them back to be - // relative to the original text. - start -= offset; - end -= offset; - var length = end - start; - if (length > 0) { - result.spans.push(start); - result.spans.push(length); - result.spans.push(classification); - } - } - } - function isBinaryExpressionOperatorToken(token) { - switch (token) { - case 35 /* AsteriskToken */: - case 36 /* SlashToken */: - case 37 /* PercentToken */: - case 33 /* PlusToken */: - case 34 /* MinusToken */: - case 40 /* LessThanLessThanToken */: - case 41 /* GreaterThanGreaterThanToken */: - case 42 /* GreaterThanGreaterThanGreaterThanToken */: - case 24 /* LessThanToken */: - case 25 /* GreaterThanToken */: - case 26 /* LessThanEqualsToken */: - case 27 /* GreaterThanEqualsToken */: - case 87 /* InstanceOfKeyword */: - case 86 /* InKeyword */: - case 28 /* EqualsEqualsToken */: - case 29 /* ExclamationEqualsToken */: - case 30 /* EqualsEqualsEqualsToken */: - case 31 /* ExclamationEqualsEqualsToken */: - case 43 /* AmpersandToken */: - case 45 /* CaretToken */: - case 44 /* BarToken */: - case 48 /* AmpersandAmpersandToken */: - case 49 /* BarBarToken */: - case 63 /* BarEqualsToken */: - case 62 /* AmpersandEqualsToken */: - case 64 /* CaretEqualsToken */: - case 59 /* LessThanLessThanEqualsToken */: - case 60 /* GreaterThanGreaterThanEqualsToken */: - case 61 /* GreaterThanGreaterThanGreaterThanEqualsToken */: - case 54 /* PlusEqualsToken */: - case 55 /* MinusEqualsToken */: - case 56 /* AsteriskEqualsToken */: - case 57 /* SlashEqualsToken */: - case 58 /* PercentEqualsToken */: - case 53 /* EqualsToken */: - case 23 /* CommaToken */: - return true; - default: - return false; - } - } - function isPrefixUnaryExpressionOperatorToken(token) { - switch (token) { - case 33 /* PlusToken */: - case 34 /* MinusToken */: - case 47 /* TildeToken */: - case 46 /* ExclamationToken */: - case 38 /* PlusPlusToken */: - case 39 /* MinusMinusToken */: - return true; - default: - return false; - } - } - function isKeyword(token) { - return token >= 66 /* FirstKeyword */ && token <= 127 /* LastKeyword */; - } - function classFromKind(token) { - if (isKeyword(token)) { - return 3 /* keyword */; - } - else if (isBinaryExpressionOperatorToken(token) || isPrefixUnaryExpressionOperatorToken(token)) { - return 5 /* operator */; - } - else if (token >= 14 /* FirstPunctuation */ && token <= 64 /* LastPunctuation */) { - return 10 /* punctuation */; - } - switch (token) { - case 7 /* NumericLiteral */: - return 4 /* numericLiteral */; - case 8 /* StringLiteral */: - return 6 /* stringLiteral */; - case 9 /* RegularExpressionLiteral */: - return 7 /* regularExpressionLiteral */; - case 6 /* ConflictMarkerTrivia */: - case 3 /* MultiLineCommentTrivia */: - case 2 /* SingleLineCommentTrivia */: - return 1 /* comment */; - case 5 /* WhitespaceTrivia */: - case 4 /* NewLineTrivia */: - return 8 /* whiteSpace */; - case 65 /* Identifier */: - default: - if (ts.isTemplateLiteralKind(token)) { - return 6 /* stringLiteral */; - } - return 2 /* identifier */; - } - } - return { - getClassificationsForLine: getClassificationsForLine, - getEncodedLexicalClassifications: getEncodedLexicalClassifications - }; - } - ts.createClassifier = createClassifier; - /** - * Get the path of the default library file (lib.d.ts) as distributed with the typescript - * node package. - * The functionality is not supported if the ts module is consumed outside of a node module. - */ - function getDefaultLibFilePath(options) { - // Check __dirname is defined and that we are on a node.js system. - if (typeof __dirname !== "undefined") { - return __dirname + ts.directorySeparator + ts.getDefaultLibFileName(options); - } - throw new Error("getDefaultLibFilePath is only supported when consumed as a node module. "); - } - ts.getDefaultLibFilePath = getDefaultLibFilePath; - function initializeServices() { - ts.objectAllocator = { - getNodeConstructor: function (kind) { - function Node() { - } - var proto = kind === 230 /* SourceFile */ ? new SourceFileObject() : new NodeObject(); - proto.kind = kind; - proto.pos = 0; - proto.end = 0; - proto.flags = 0; - proto.parent = undefined; - Node.prototype = proto; - return Node; - }, - getSymbolConstructor: function () { return SymbolObject; }, - getTypeConstructor: function () { return TypeObject; }, - getSignatureConstructor: function () { return SignatureObject; } - }; - } - initializeServices(); -})(ts || (ts = {})); -// Copyright (c) Microsoft. All rights reserved. Licensed under the Apache License, Version 2.0. -// See LICENSE.txt in the project root for complete license information. -/// -/* @internal */ -var ts; -(function (ts) { - var BreakpointResolver; - (function (BreakpointResolver) { - /** - * Get the breakpoint span in given sourceFile - */ - function spanInSourceFileAtLocation(sourceFile, position) { - // Cannot set breakpoint in dts file - if (sourceFile.flags & 2048 /* DeclarationFile */) { - return undefined; - } - var tokenAtLocation = ts.getTokenAtPosition(sourceFile, position); - var lineOfPosition = sourceFile.getLineAndCharacterOfPosition(position).line; - if (sourceFile.getLineAndCharacterOfPosition(tokenAtLocation.getStart()).line > lineOfPosition) { - // Get previous token if the token is returned starts on new line - // eg: let x =10; |--- cursor is here - // let y = 10; - // token at position will return let keyword on second line as the token but we would like to use - // token on same line if trailing trivia (comments or white spaces on same line) part of the last token on that line - tokenAtLocation = ts.findPrecedingToken(tokenAtLocation.pos, sourceFile); - // Its a blank line - if (!tokenAtLocation || sourceFile.getLineAndCharacterOfPosition(tokenAtLocation.getEnd()).line !== lineOfPosition) { - return undefined; - } - } - // Cannot set breakpoint in ambient declarations - if (ts.isInAmbientContext(tokenAtLocation)) { - return undefined; - } - // Get the span in the node based on its syntax - return spanInNode(tokenAtLocation); - function textSpan(startNode, endNode) { - return ts.createTextSpanFromBounds(startNode.getStart(), (endNode || startNode).getEnd()); - } - function spanInNodeIfStartsOnSameLine(node, otherwiseOnNode) { - if (node && lineOfPosition === sourceFile.getLineAndCharacterOfPosition(node.getStart()).line) { - return spanInNode(node); - } - return spanInNode(otherwiseOnNode); - } - function spanInPreviousNode(node) { - return spanInNode(ts.findPrecedingToken(node.pos, sourceFile)); - } - function spanInNextNode(node) { - return spanInNode(ts.findNextToken(node, node.parent)); - } - function spanInNode(node) { - if (node) { - if (ts.isExpression(node)) { - if (node.parent.kind === 187 /* DoStatement */) { - // Set span as if on while keyword - return spanInPreviousNode(node); - } - if (node.parent.kind === 189 /* ForStatement */) { - // For now lets set the span on this expression, fix it later - return textSpan(node); - } - if (node.parent.kind === 172 /* BinaryExpression */ && node.parent.operatorToken.kind === 23 /* CommaToken */) { - // if this is comma expression, the breakpoint is possible in this expression - return textSpan(node); - } - if (node.parent.kind == 166 /* ArrowFunction */ && node.parent.body == node) { - // If this is body of arrow function, it is allowed to have the breakpoint - return textSpan(node); - } - } - switch (node.kind) { - case 183 /* VariableStatement */: - // Span on first variable declaration - return spanInVariableDeclaration(node.declarationList.declarations[0]); - case 201 /* VariableDeclaration */: - case 134 /* PropertyDeclaration */: - case 133 /* PropertySignature */: - return spanInVariableDeclaration(node); - case 131 /* Parameter */: - return spanInParameterDeclaration(node); - case 203 /* FunctionDeclaration */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 137 /* Constructor */: - case 165 /* FunctionExpression */: - case 166 /* ArrowFunction */: - return spanInFunctionDeclaration(node); - case 182 /* Block */: - if (ts.isFunctionBlock(node)) { - return spanInFunctionBlock(node); - } - // Fall through - case 209 /* ModuleBlock */: - return spanInBlock(node); - case 226 /* CatchClause */: - return spanInBlock(node.block); - case 185 /* ExpressionStatement */: - // span on the expression - return textSpan(node.expression); - case 194 /* ReturnStatement */: - // span on return keyword and expression if present - return textSpan(node.getChildAt(0), node.expression); - case 188 /* WhileStatement */: - // Span on while(...) - return textSpan(node, ts.findNextToken(node.expression, node)); - case 187 /* DoStatement */: - // span in statement of the do statement - return spanInNode(node.statement); - case 200 /* DebuggerStatement */: - // span on debugger keyword - return textSpan(node.getChildAt(0)); - case 186 /* IfStatement */: - // set on if(..) span - return textSpan(node, ts.findNextToken(node.expression, node)); - case 197 /* LabeledStatement */: - // span in statement - return spanInNode(node.statement); - case 193 /* BreakStatement */: - case 192 /* ContinueStatement */: - // On break or continue keyword and label if present - return textSpan(node.getChildAt(0), node.label); - case 189 /* ForStatement */: - return spanInForStatement(node); - case 190 /* ForInStatement */: - case 191 /* ForOfStatement */: - // span on for (a in ...) - return textSpan(node, ts.findNextToken(node.expression, node)); - case 196 /* SwitchStatement */: - // span on switch(...) - return textSpan(node, ts.findNextToken(node.expression, node)); - case 223 /* CaseClause */: - case 224 /* DefaultClause */: - // span in first statement of the clause - return spanInNode(node.statements[0]); - case 199 /* TryStatement */: - // span in try block - return spanInBlock(node.tryBlock); - case 198 /* ThrowStatement */: - // span in throw ... - return textSpan(node, node.expression); - case 217 /* ExportAssignment */: - // span on export = id - return textSpan(node, node.expression); - case 211 /* ImportEqualsDeclaration */: - // import statement without including semicolon - return textSpan(node, node.moduleReference); - case 212 /* ImportDeclaration */: - // import statement without including semicolon - return textSpan(node, node.moduleSpecifier); - case 218 /* ExportDeclaration */: - // import statement without including semicolon - return textSpan(node, node.moduleSpecifier); - case 208 /* ModuleDeclaration */: - // span on complete module if it is instantiated - if (ts.getModuleInstanceState(node) !== 1 /* Instantiated */) { - return undefined; - } - case 204 /* ClassDeclaration */: - case 207 /* EnumDeclaration */: - case 229 /* EnumMember */: - case 160 /* CallExpression */: - case 161 /* NewExpression */: - // span on complete node - return textSpan(node); - case 195 /* WithStatement */: - // span in statement - return spanInNode(node.statement); - // No breakpoint in interface, type alias - case 205 /* InterfaceDeclaration */: - case 206 /* TypeAliasDeclaration */: - return undefined; - // Tokens: - case 22 /* SemicolonToken */: - case 1 /* EndOfFileToken */: - return spanInNodeIfStartsOnSameLine(ts.findPrecedingToken(node.pos, sourceFile)); - case 23 /* CommaToken */: - return spanInPreviousNode(node); - case 14 /* OpenBraceToken */: - return spanInOpenBraceToken(node); - case 15 /* CloseBraceToken */: - return spanInCloseBraceToken(node); - case 16 /* OpenParenToken */: - return spanInOpenParenToken(node); - case 17 /* CloseParenToken */: - return spanInCloseParenToken(node); - case 51 /* ColonToken */: - return spanInColonToken(node); - case 25 /* GreaterThanToken */: - case 24 /* LessThanToken */: - return spanInGreaterThanOrLessThanToken(node); - // Keywords: - case 100 /* WhileKeyword */: - return spanInWhileKeyword(node); - case 76 /* ElseKeyword */: - case 68 /* CatchKeyword */: - case 81 /* FinallyKeyword */: - return spanInNextNode(node); - default: - // If this is name of property assignment, set breakpoint in the initializer - if (node.parent.kind === 227 /* PropertyAssignment */ && node.parent.name === node) { - return spanInNode(node.parent.initializer); - } - // Breakpoint in type assertion goes to its operand - if (node.parent.kind === 163 /* TypeAssertionExpression */ && node.parent.type === node) { - return spanInNode(node.parent.expression); - } - // return type of function go to previous token - if (ts.isFunctionLike(node.parent) && node.parent.type === node) { - return spanInPreviousNode(node); - } - // Default go to parent to set the breakpoint - return spanInNode(node.parent); - } - } - function spanInVariableDeclaration(variableDeclaration) { - // If declaration of for in statement, just set the span in parent - if (variableDeclaration.parent.parent.kind === 190 /* ForInStatement */ || - variableDeclaration.parent.parent.kind === 191 /* ForOfStatement */) { - return spanInNode(variableDeclaration.parent.parent); - } - var isParentVariableStatement = variableDeclaration.parent.parent.kind === 183 /* VariableStatement */; - var isDeclarationOfForStatement = variableDeclaration.parent.parent.kind === 189 /* ForStatement */ && ts.contains(variableDeclaration.parent.parent.initializer.declarations, variableDeclaration); - var declarations = isParentVariableStatement - ? variableDeclaration.parent.parent.declarationList.declarations - : isDeclarationOfForStatement - ? variableDeclaration.parent.parent.initializer.declarations - : undefined; - // Breakpoint is possible in variableDeclaration only if there is initialization - if (variableDeclaration.initializer || (variableDeclaration.flags & 1 /* Export */)) { - if (declarations && declarations[0] === variableDeclaration) { - if (isParentVariableStatement) { - // First declaration - include let keyword - return textSpan(variableDeclaration.parent, variableDeclaration); - } - else { - ts.Debug.assert(isDeclarationOfForStatement); - // Include let keyword from for statement declarations in the span - return textSpan(ts.findPrecedingToken(variableDeclaration.pos, sourceFile, variableDeclaration.parent), variableDeclaration); - } - } - else { - // Span only on this declaration - return textSpan(variableDeclaration); - } - } - else if (declarations && declarations[0] !== variableDeclaration) { - // If we cant set breakpoint on this declaration, set it on previous one - var indexOfCurrentDeclaration = ts.indexOf(declarations, variableDeclaration); - return spanInVariableDeclaration(declarations[indexOfCurrentDeclaration - 1]); - } - } - function canHaveSpanInParameterDeclaration(parameter) { - // Breakpoint is possible on parameter only if it has initializer, is a rest parameter, or has public or private modifier - return !!parameter.initializer || parameter.dotDotDotToken !== undefined || - !!(parameter.flags & 16 /* Public */) || !!(parameter.flags & 32 /* Private */); - } - function spanInParameterDeclaration(parameter) { - if (canHaveSpanInParameterDeclaration(parameter)) { - return textSpan(parameter); - } - else { - var functionDeclaration = parameter.parent; - var indexOfParameter = ts.indexOf(functionDeclaration.parameters, parameter); - if (indexOfParameter) { - // Not a first parameter, go to previous parameter - return spanInParameterDeclaration(functionDeclaration.parameters[indexOfParameter - 1]); - } - else { - // Set breakpoint in the function declaration body - return spanInNode(functionDeclaration.body); - } - } - } - function canFunctionHaveSpanInWholeDeclaration(functionDeclaration) { - return !!(functionDeclaration.flags & 1 /* Export */) || - (functionDeclaration.parent.kind === 204 /* ClassDeclaration */ && functionDeclaration.kind !== 137 /* Constructor */); - } - function spanInFunctionDeclaration(functionDeclaration) { - // No breakpoints in the function signature - if (!functionDeclaration.body) { - return undefined; - } - if (canFunctionHaveSpanInWholeDeclaration(functionDeclaration)) { - // Set the span on whole function declaration - return textSpan(functionDeclaration); - } - // Set span in function body - return spanInNode(functionDeclaration.body); - } - function spanInFunctionBlock(block) { - var nodeForSpanInBlock = block.statements.length ? block.statements[0] : block.getLastToken(); - if (canFunctionHaveSpanInWholeDeclaration(block.parent)) { - return spanInNodeIfStartsOnSameLine(block.parent, nodeForSpanInBlock); - } - return spanInNode(nodeForSpanInBlock); - } - function spanInBlock(block) { - switch (block.parent.kind) { - case 208 /* ModuleDeclaration */: - if (ts.getModuleInstanceState(block.parent) !== 1 /* Instantiated */) { - return undefined; - } - // Set on parent if on same line otherwise on first statement - case 188 /* WhileStatement */: - case 186 /* IfStatement */: - case 190 /* ForInStatement */: - case 191 /* ForOfStatement */: - return spanInNodeIfStartsOnSameLine(block.parent, block.statements[0]); - // Set span on previous token if it starts on same line otherwise on the first statement of the block - case 189 /* ForStatement */: - return spanInNodeIfStartsOnSameLine(ts.findPrecedingToken(block.pos, sourceFile, block.parent), block.statements[0]); - } - // Default action is to set on first statement - return spanInNode(block.statements[0]); - } - function spanInForStatement(forStatement) { - if (forStatement.initializer) { - if (forStatement.initializer.kind === 202 /* VariableDeclarationList */) { - var variableDeclarationList = forStatement.initializer; - if (variableDeclarationList.declarations.length > 0) { - return spanInNode(variableDeclarationList.declarations[0]); - } - } - else { - return spanInNode(forStatement.initializer); - } - } - if (forStatement.condition) { - return textSpan(forStatement.condition); - } - if (forStatement.incrementor) { - return textSpan(forStatement.incrementor); - } - } - // Tokens: - function spanInOpenBraceToken(node) { - switch (node.parent.kind) { - case 207 /* EnumDeclaration */: - var enumDeclaration = node.parent; - return spanInNodeIfStartsOnSameLine(ts.findPrecedingToken(node.pos, sourceFile, node.parent), enumDeclaration.members.length ? enumDeclaration.members[0] : enumDeclaration.getLastToken(sourceFile)); - case 204 /* ClassDeclaration */: - var classDeclaration = node.parent; - return spanInNodeIfStartsOnSameLine(ts.findPrecedingToken(node.pos, sourceFile, node.parent), classDeclaration.members.length ? classDeclaration.members[0] : classDeclaration.getLastToken(sourceFile)); - case 210 /* CaseBlock */: - return spanInNodeIfStartsOnSameLine(node.parent.parent, node.parent.clauses[0]); - } - // Default to parent node - return spanInNode(node.parent); - } - function spanInCloseBraceToken(node) { - switch (node.parent.kind) { - case 209 /* ModuleBlock */: - // If this is not instantiated module block no bp span - if (ts.getModuleInstanceState(node.parent.parent) !== 1 /* Instantiated */) { - return undefined; - } - case 207 /* EnumDeclaration */: - case 204 /* ClassDeclaration */: - // Span on close brace token - return textSpan(node); - case 182 /* Block */: - if (ts.isFunctionBlock(node.parent)) { - // Span on close brace token - return textSpan(node); - } - // fall through. - case 226 /* CatchClause */: - return spanInNode(ts.lastOrUndefined(node.parent.statements)); - ; - case 210 /* CaseBlock */: - // breakpoint in last statement of the last clause - var caseBlock = node.parent; - var lastClause = ts.lastOrUndefined(caseBlock.clauses); - if (lastClause) { - return spanInNode(ts.lastOrUndefined(lastClause.statements)); - } - return undefined; - // Default to parent node - default: - return spanInNode(node.parent); - } - } - function spanInOpenParenToken(node) { - if (node.parent.kind === 187 /* DoStatement */) { - // Go to while keyword and do action instead - return spanInPreviousNode(node); - } - // Default to parent node - return spanInNode(node.parent); - } - function spanInCloseParenToken(node) { - // Is this close paren token of parameter list, set span in previous token - switch (node.parent.kind) { - case 165 /* FunctionExpression */: - case 203 /* FunctionDeclaration */: - case 166 /* ArrowFunction */: - case 136 /* MethodDeclaration */: - case 135 /* MethodSignature */: - case 138 /* GetAccessor */: - case 139 /* SetAccessor */: - case 137 /* Constructor */: - case 188 /* WhileStatement */: - case 187 /* DoStatement */: - case 189 /* ForStatement */: - return spanInPreviousNode(node); - // Default to parent node - default: - return spanInNode(node.parent); - } - // Default to parent node - return spanInNode(node.parent); - } - function spanInColonToken(node) { - // Is this : specifying return annotation of the function declaration - if (ts.isFunctionLike(node.parent) || node.parent.kind === 227 /* PropertyAssignment */) { - return spanInPreviousNode(node); - } - return spanInNode(node.parent); - } - function spanInGreaterThanOrLessThanToken(node) { - if (node.parent.kind === 163 /* TypeAssertionExpression */) { - return spanInNode(node.parent.expression); - } - return spanInNode(node.parent); - } - function spanInWhileKeyword(node) { - if (node.parent.kind === 187 /* DoStatement */) { - // Set span on while expression - return textSpan(node, ts.findNextToken(node.parent.expression, node.parent)); - } - // Default to parent node - return spanInNode(node.parent); - } - } - } - BreakpointResolver.spanInSourceFileAtLocation = spanInSourceFileAtLocation; - })(BreakpointResolver = ts.BreakpointResolver || (ts.BreakpointResolver = {})); -})(ts || (ts = {})); -// -// Copyright (c) Microsoft Corporation. All rights reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// -/// -/* @internal */ -var debugObjectHost = this; -/* @internal */ -var ts; -(function (ts) { - function logInternalError(logger, err) { - if (logger) { - logger.log("*INTERNAL ERROR* - Exception in typescript services: " + err.message); - } - } - var ScriptSnapshotShimAdapter = (function () { - function ScriptSnapshotShimAdapter(scriptSnapshotShim) { - this.scriptSnapshotShim = scriptSnapshotShim; - this.lineStartPositions = null; - } - ScriptSnapshotShimAdapter.prototype.getText = function (start, end) { - return this.scriptSnapshotShim.getText(start, end); - }; - ScriptSnapshotShimAdapter.prototype.getLength = function () { - return this.scriptSnapshotShim.getLength(); - }; - ScriptSnapshotShimAdapter.prototype.getChangeRange = function (oldSnapshot) { - var oldSnapshotShim = oldSnapshot; - var encoded = this.scriptSnapshotShim.getChangeRange(oldSnapshotShim.scriptSnapshotShim); - if (encoded == null) { - return null; - } - var decoded = JSON.parse(encoded); - return ts.createTextChangeRange(ts.createTextSpan(decoded.span.start, decoded.span.length), decoded.newLength); - }; - return ScriptSnapshotShimAdapter; - })(); - var LanguageServiceShimHostAdapter = (function () { - function LanguageServiceShimHostAdapter(shimHost) { - this.shimHost = shimHost; - this.loggingEnabled = false; - this.tracingEnabled = false; - } - LanguageServiceShimHostAdapter.prototype.log = function (s) { - if (this.loggingEnabled) { - this.shimHost.log(s); - } - }; - LanguageServiceShimHostAdapter.prototype.trace = function (s) { - if (this.tracingEnabled) { - this.shimHost.trace(s); - } - }; - LanguageServiceShimHostAdapter.prototype.error = function (s) { - this.shimHost.error(s); - }; - LanguageServiceShimHostAdapter.prototype.getProjectVersion = function () { - if (!this.shimHost.getProjectVersion) { - // shimmed host does not support getProjectVersion - return undefined; - } - return this.shimHost.getProjectVersion(); - }; - LanguageServiceShimHostAdapter.prototype.useCaseSensitiveFileNames = function () { - return this.shimHost.useCaseSensitiveFileNames ? this.shimHost.useCaseSensitiveFileNames() : false; - }; - LanguageServiceShimHostAdapter.prototype.getCompilationSettings = function () { - var settingsJson = this.shimHost.getCompilationSettings(); - if (settingsJson == null || settingsJson == "") { - throw Error("LanguageServiceShimHostAdapter.getCompilationSettings: empty compilationSettings"); - return null; - } - return JSON.parse(settingsJson); - }; - LanguageServiceShimHostAdapter.prototype.getScriptFileNames = function () { - var encoded = this.shimHost.getScriptFileNames(); - return this.files = JSON.parse(encoded); - }; - LanguageServiceShimHostAdapter.prototype.getScriptSnapshot = function (fileName) { - // Shim the API changes for 1.5 release. This should be removed once - // TypeScript 1.5 has shipped. - if (this.files && this.files.indexOf(fileName) < 0) { - return undefined; - } - var scriptSnapshot = this.shimHost.getScriptSnapshot(fileName); - return scriptSnapshot && new ScriptSnapshotShimAdapter(scriptSnapshot); - }; - LanguageServiceShimHostAdapter.prototype.getScriptVersion = function (fileName) { - return this.shimHost.getScriptVersion(fileName); - }; - LanguageServiceShimHostAdapter.prototype.getLocalizedDiagnosticMessages = function () { - var diagnosticMessagesJson = this.shimHost.getLocalizedDiagnosticMessages(); - if (diagnosticMessagesJson == null || diagnosticMessagesJson == "") { - return null; - } - try { - return JSON.parse(diagnosticMessagesJson); - } - catch (e) { - this.log(e.description || "diagnosticMessages.generated.json has invalid JSON format"); - return null; - } - }; - LanguageServiceShimHostAdapter.prototype.getCancellationToken = function () { - return this.shimHost.getCancellationToken(); - }; - LanguageServiceShimHostAdapter.prototype.getCurrentDirectory = function () { - return this.shimHost.getCurrentDirectory(); - }; - LanguageServiceShimHostAdapter.prototype.getDefaultLibFileName = function (options) { - // Wrap the API changes for 1.5 release. This try/catch - // should be removed once TypeScript 1.5 has shipped. - try { - return this.shimHost.getDefaultLibFileName(JSON.stringify(options)); - } - catch (e) { - return ""; - } - }; - return LanguageServiceShimHostAdapter; - })(); - ts.LanguageServiceShimHostAdapter = LanguageServiceShimHostAdapter; - var CoreServicesShimHostAdapter = (function () { - function CoreServicesShimHostAdapter(shimHost) { - this.shimHost = shimHost; - } - CoreServicesShimHostAdapter.prototype.readDirectory = function (rootDir, extension) { - var encoded = this.shimHost.readDirectory(rootDir, extension); - return JSON.parse(encoded); - }; - return CoreServicesShimHostAdapter; - })(); - ts.CoreServicesShimHostAdapter = CoreServicesShimHostAdapter; - function simpleForwardCall(logger, actionDescription, action, logPerformance) { - if (logPerformance) { - logger.log(actionDescription); - var start = Date.now(); - } - var result = action(); - if (logPerformance) { - var end = Date.now(); - logger.log(actionDescription + " completed in " + (end - start) + " msec"); - if (typeof (result) === "string") { - var str = result; - if (str.length > 128) { - str = str.substring(0, 128) + "..."; - } - logger.log(" result.length=" + str.length + ", result='" + JSON.stringify(str) + "'"); - } - } - return result; - } - function forwardJSONCall(logger, actionDescription, action, logPerformance) { - try { - var result = simpleForwardCall(logger, actionDescription, action, logPerformance); - return JSON.stringify({ result: result }); - } - catch (err) { - if (err instanceof ts.OperationCanceledException) { - return JSON.stringify({ canceled: true }); - } - logInternalError(logger, err); - err.description = actionDescription; - return JSON.stringify({ error: err }); - } - } - var ShimBase = (function () { - function ShimBase(factory) { - this.factory = factory; - factory.registerShim(this); - } - ShimBase.prototype.dispose = function (dummy) { - this.factory.unregisterShim(this); - }; - return ShimBase; - })(); - function realizeDiagnostics(diagnostics, newLine) { - return diagnostics.map(function (d) { return realizeDiagnostic(d, newLine); }); - } - ts.realizeDiagnostics = realizeDiagnostics; - function realizeDiagnostic(diagnostic, newLine) { - return { - message: ts.flattenDiagnosticMessageText(diagnostic.messageText, newLine), - start: diagnostic.start, - length: diagnostic.length, - /// TODO: no need for the tolowerCase call - category: ts.DiagnosticCategory[diagnostic.category].toLowerCase(), - code: diagnostic.code - }; - } - var LanguageServiceShimObject = (function (_super) { - __extends(LanguageServiceShimObject, _super); - function LanguageServiceShimObject(factory, host, languageService) { - _super.call(this, factory); - this.host = host; - this.languageService = languageService; - this.logPerformance = false; - this.logger = this.host; - } - LanguageServiceShimObject.prototype.forwardJSONCall = function (actionDescription, action) { - return forwardJSONCall(this.logger, actionDescription, action, this.logPerformance); - }; - /// DISPOSE - /** - * Ensure (almost) deterministic release of internal Javascript resources when - * some external native objects holds onto us (e.g. Com/Interop). - */ - LanguageServiceShimObject.prototype.dispose = function (dummy) { - this.logger.log("dispose()"); - this.languageService.dispose(); - this.languageService = null; - // force a GC - if (debugObjectHost && debugObjectHost.CollectGarbage) { - debugObjectHost.CollectGarbage(); - this.logger.log("CollectGarbage()"); - } - this.logger = null; - _super.prototype.dispose.call(this, dummy); - }; - /// REFRESH - /** - * Update the list of scripts known to the compiler - */ - LanguageServiceShimObject.prototype.refresh = function (throwOnError) { - this.forwardJSONCall("refresh(" + throwOnError + ")", function () { - return null; - }); - }; - LanguageServiceShimObject.prototype.cleanupSemanticCache = function () { - var _this = this; - this.forwardJSONCall("cleanupSemanticCache()", function () { - _this.languageService.cleanupSemanticCache(); - return null; - }); - }; - LanguageServiceShimObject.prototype.realizeDiagnostics = function (diagnostics) { - var newLine = this.getNewLine(); - return ts.realizeDiagnostics(diagnostics, newLine); - }; - LanguageServiceShimObject.prototype.getSyntacticClassifications = function (fileName, start, length) { - var _this = this; - return this.forwardJSONCall("getSyntacticClassifications('" + fileName + "', " + start + ", " + length + ")", function () { - var classifications = _this.languageService.getSyntacticClassifications(fileName, ts.createTextSpan(start, length)); - return classifications; - }); - }; - LanguageServiceShimObject.prototype.getSemanticClassifications = function (fileName, start, length) { - var _this = this; - return this.forwardJSONCall("getSemanticClassifications('" + fileName + "', " + start + ", " + length + ")", function () { - var classifications = _this.languageService.getSemanticClassifications(fileName, ts.createTextSpan(start, length)); - return classifications; - }); - }; - LanguageServiceShimObject.prototype.getEncodedSyntacticClassifications = function (fileName, start, length) { - var _this = this; - return this.forwardJSONCall("getEncodedSyntacticClassifications('" + fileName + "', " + start + ", " + length + ")", function () { - // directly serialize the spans out to a string. This is much faster to decode - // on the managed side versus a full JSON array. - return convertClassifications(_this.languageService.getEncodedSyntacticClassifications(fileName, ts.createTextSpan(start, length))); - }); - }; - LanguageServiceShimObject.prototype.getEncodedSemanticClassifications = function (fileName, start, length) { - var _this = this; - return this.forwardJSONCall("getEncodedSemanticClassifications('" + fileName + "', " + start + ", " + length + ")", function () { - // directly serialize the spans out to a string. This is much faster to decode - // on the managed side versus a full JSON array. - return convertClassifications(_this.languageService.getEncodedSemanticClassifications(fileName, ts.createTextSpan(start, length))); - }); - }; - LanguageServiceShimObject.prototype.getNewLine = function () { - return this.host.getNewLine ? this.host.getNewLine() : "\r\n"; - }; - LanguageServiceShimObject.prototype.getSyntacticDiagnostics = function (fileName) { - var _this = this; - return this.forwardJSONCall("getSyntacticDiagnostics('" + fileName + "')", function () { - var diagnostics = _this.languageService.getSyntacticDiagnostics(fileName); - return _this.realizeDiagnostics(diagnostics); - }); - }; - LanguageServiceShimObject.prototype.getSemanticDiagnostics = function (fileName) { - var _this = this; - return this.forwardJSONCall("getSemanticDiagnostics('" + fileName + "')", function () { - var diagnostics = _this.languageService.getSemanticDiagnostics(fileName); - return _this.realizeDiagnostics(diagnostics); - }); - }; - LanguageServiceShimObject.prototype.getCompilerOptionsDiagnostics = function () { - var _this = this; - return this.forwardJSONCall("getCompilerOptionsDiagnostics()", function () { - var diagnostics = _this.languageService.getCompilerOptionsDiagnostics(); - return _this.realizeDiagnostics(diagnostics); - }); - }; - /// QUICKINFO - /** - * Computes a string representation of the type at the requested position - * in the active file. - */ - LanguageServiceShimObject.prototype.getQuickInfoAtPosition = function (fileName, position) { - var _this = this; - return this.forwardJSONCall("getQuickInfoAtPosition('" + fileName + "', " + position + ")", function () { - var quickInfo = _this.languageService.getQuickInfoAtPosition(fileName, position); - return quickInfo; - }); - }; - /// NAMEORDOTTEDNAMESPAN - /** - * Computes span information of the name or dotted name at the requested position - * in the active file. - */ - LanguageServiceShimObject.prototype.getNameOrDottedNameSpan = function (fileName, startPos, endPos) { - var _this = this; - return this.forwardJSONCall("getNameOrDottedNameSpan('" + fileName + "', " + startPos + ", " + endPos + ")", function () { - var spanInfo = _this.languageService.getNameOrDottedNameSpan(fileName, startPos, endPos); - return spanInfo; - }); - }; - /** - * STATEMENTSPAN - * Computes span information of statement at the requested position in the active file. - */ - LanguageServiceShimObject.prototype.getBreakpointStatementAtPosition = function (fileName, position) { - var _this = this; - return this.forwardJSONCall("getBreakpointStatementAtPosition('" + fileName + "', " + position + ")", function () { - var spanInfo = _this.languageService.getBreakpointStatementAtPosition(fileName, position); - return spanInfo; - }); - }; - /// SIGNATUREHELP - LanguageServiceShimObject.prototype.getSignatureHelpItems = function (fileName, position) { - var _this = this; - return this.forwardJSONCall("getSignatureHelpItems('" + fileName + "', " + position + ")", function () { - var signatureInfo = _this.languageService.getSignatureHelpItems(fileName, position); - return signatureInfo; - }); - }; - /// GOTO DEFINITION - /** - * Computes the definition location and file for the symbol - * at the requested position. - */ - LanguageServiceShimObject.prototype.getDefinitionAtPosition = function (fileName, position) { - var _this = this; - return this.forwardJSONCall("getDefinitionAtPosition('" + fileName + "', " + position + ")", function () { - return _this.languageService.getDefinitionAtPosition(fileName, position); - }); - }; - /// GOTO Type - /** - * Computes the definition location of the type of the symbol - * at the requested position. - */ - LanguageServiceShimObject.prototype.getTypeDefinitionAtPosition = function (fileName, position) { - var _this = this; - return this.forwardJSONCall("getTypeDefinitionAtPosition('" + fileName + "', " + position + ")", function () { - return _this.languageService.getTypeDefinitionAtPosition(fileName, position); - }); - }; - LanguageServiceShimObject.prototype.getRenameInfo = function (fileName, position) { - var _this = this; - return this.forwardJSONCall("getRenameInfo('" + fileName + "', " + position + ")", function () { - return _this.languageService.getRenameInfo(fileName, position); - }); - }; - LanguageServiceShimObject.prototype.findRenameLocations = function (fileName, position, findInStrings, findInComments) { - var _this = this; - return this.forwardJSONCall("findRenameLocations('" + fileName + "', " + position + ", " + findInStrings + ", " + findInComments + ")", function () { - return _this.languageService.findRenameLocations(fileName, position, findInStrings, findInComments); - }); - }; - /// GET BRACE MATCHING - LanguageServiceShimObject.prototype.getBraceMatchingAtPosition = function (fileName, position) { - var _this = this; - return this.forwardJSONCall("getBraceMatchingAtPosition('" + fileName + "', " + position + ")", function () { - var textRanges = _this.languageService.getBraceMatchingAtPosition(fileName, position); - return textRanges; - }); - }; - /// GET SMART INDENT - LanguageServiceShimObject.prototype.getIndentationAtPosition = function (fileName, position, options /*Services.EditorOptions*/) { - var _this = this; - return this.forwardJSONCall("getIndentationAtPosition('" + fileName + "', " + position + ")", function () { - var localOptions = JSON.parse(options); - return _this.languageService.getIndentationAtPosition(fileName, position, localOptions); - }); - }; - /// GET REFERENCES - LanguageServiceShimObject.prototype.getReferencesAtPosition = function (fileName, position) { - var _this = this; - return this.forwardJSONCall("getReferencesAtPosition('" + fileName + "', " + position + ")", function () { - return _this.languageService.getReferencesAtPosition(fileName, position); - }); - }; - LanguageServiceShimObject.prototype.findReferences = function (fileName, position) { - var _this = this; - return this.forwardJSONCall("findReferences('" + fileName + "', " + position + ")", function () { - return _this.languageService.findReferences(fileName, position); - }); - }; - LanguageServiceShimObject.prototype.getOccurrencesAtPosition = function (fileName, position) { - var _this = this; - return this.forwardJSONCall("getOccurrencesAtPosition('" + fileName + "', " + position + ")", function () { - return _this.languageService.getOccurrencesAtPosition(fileName, position); - }); - }; - LanguageServiceShimObject.prototype.getDocumentHighlights = function (fileName, position, filesToSearch) { - var _this = this; - return this.forwardJSONCall("getDocumentHighlights('" + fileName + "', " + position + ")", function () { - return _this.languageService.getDocumentHighlights(fileName, position, JSON.parse(filesToSearch)); - }); - }; - /// COMPLETION LISTS - /** - * Get a string based representation of the completions - * to provide at the given source position and providing a member completion - * list if requested. - */ - LanguageServiceShimObject.prototype.getCompletionsAtPosition = function (fileName, position) { - var _this = this; - return this.forwardJSONCall("getCompletionsAtPosition('" + fileName + "', " + position + ")", function () { - var completion = _this.languageService.getCompletionsAtPosition(fileName, position); - return completion; - }); - }; - /** Get a string based representation of a completion list entry details */ - LanguageServiceShimObject.prototype.getCompletionEntryDetails = function (fileName, position, entryName) { - var _this = this; - return this.forwardJSONCall("getCompletionEntryDetails('" + fileName + "', " + position + ", " + entryName + ")", function () { - var details = _this.languageService.getCompletionEntryDetails(fileName, position, entryName); - return details; - }); - }; - LanguageServiceShimObject.prototype.getFormattingEditsForRange = function (fileName, start, end, options /*Services.FormatCodeOptions*/) { - var _this = this; - return this.forwardJSONCall("getFormattingEditsForRange('" + fileName + "', " + start + ", " + end + ")", function () { - var localOptions = JSON.parse(options); - var edits = _this.languageService.getFormattingEditsForRange(fileName, start, end, localOptions); - return edits; - }); - }; - LanguageServiceShimObject.prototype.getFormattingEditsForDocument = function (fileName, options /*Services.FormatCodeOptions*/) { - var _this = this; - return this.forwardJSONCall("getFormattingEditsForDocument('" + fileName + "')", function () { - var localOptions = JSON.parse(options); - var edits = _this.languageService.getFormattingEditsForDocument(fileName, localOptions); - return edits; - }); - }; - LanguageServiceShimObject.prototype.getFormattingEditsAfterKeystroke = function (fileName, position, key, options /*Services.FormatCodeOptions*/) { - var _this = this; - return this.forwardJSONCall("getFormattingEditsAfterKeystroke('" + fileName + "', " + position + ", '" + key + "')", function () { - var localOptions = JSON.parse(options); - var edits = _this.languageService.getFormattingEditsAfterKeystroke(fileName, position, key, localOptions); - return edits; - }); - }; - /// NAVIGATE TO - /** Return a list of symbols that are interesting to navigate to */ - LanguageServiceShimObject.prototype.getNavigateToItems = function (searchValue, maxResultCount) { - var _this = this; - return this.forwardJSONCall("getNavigateToItems('" + searchValue + "', " + maxResultCount + ")", function () { - var items = _this.languageService.getNavigateToItems(searchValue, maxResultCount); - return items; - }); - }; - LanguageServiceShimObject.prototype.getNavigationBarItems = function (fileName) { - var _this = this; - return this.forwardJSONCall("getNavigationBarItems('" + fileName + "')", function () { - var items = _this.languageService.getNavigationBarItems(fileName); - return items; - }); - }; - LanguageServiceShimObject.prototype.getOutliningSpans = function (fileName) { - var _this = this; - return this.forwardJSONCall("getOutliningSpans('" + fileName + "')", function () { - var items = _this.languageService.getOutliningSpans(fileName); - return items; - }); - }; - LanguageServiceShimObject.prototype.getTodoComments = function (fileName, descriptors) { - var _this = this; - return this.forwardJSONCall("getTodoComments('" + fileName + "')", function () { - var items = _this.languageService.getTodoComments(fileName, JSON.parse(descriptors)); - return items; - }); - }; - /// Emit - LanguageServiceShimObject.prototype.getEmitOutput = function (fileName) { - var _this = this; - return this.forwardJSONCall("getEmitOutput('" + fileName + "')", function () { - var output = _this.languageService.getEmitOutput(fileName); - // Shim the API changes for 1.5 release. This should be removed once - // TypeScript 1.5 has shipped. - output.emitOutputStatus = output.emitSkipped ? 1 : 0; - return output; - }); - }; - return LanguageServiceShimObject; - })(ShimBase); - function convertClassifications(classifications) { - return { spans: classifications.spans.join(","), endOfLineState: classifications.endOfLineState }; - } - var ClassifierShimObject = (function (_super) { - __extends(ClassifierShimObject, _super); - function ClassifierShimObject(factory, logger) { - _super.call(this, factory); - this.logger = logger; - this.logPerformance = false; - this.classifier = ts.createClassifier(); - } - ClassifierShimObject.prototype.getEncodedLexicalClassifications = function (text, lexState, syntacticClassifierAbsent) { - var _this = this; - return forwardJSONCall(this.logger, "getEncodedLexicalClassifications", function () { return convertClassifications(_this.classifier.getEncodedLexicalClassifications(text, lexState, syntacticClassifierAbsent)); }, this.logPerformance); - }; - /// COLORIZATION - ClassifierShimObject.prototype.getClassificationsForLine = function (text, lexState, classifyKeywordsInGenerics) { - var classification = this.classifier.getClassificationsForLine(text, lexState, classifyKeywordsInGenerics); - var items = classification.entries; - var result = ""; - for (var i = 0; i < items.length; i++) { - result += items[i].length + "\n"; - result += items[i].classification + "\n"; - } - result += classification.finalLexState; - return result; - }; - return ClassifierShimObject; - })(ShimBase); - var CoreServicesShimObject = (function (_super) { - __extends(CoreServicesShimObject, _super); - function CoreServicesShimObject(factory, logger, host) { - _super.call(this, factory); - this.logger = logger; - this.host = host; - this.logPerformance = false; - } - CoreServicesShimObject.prototype.forwardJSONCall = function (actionDescription, action) { - return forwardJSONCall(this.logger, actionDescription, action, this.logPerformance); - }; - CoreServicesShimObject.prototype.getPreProcessedFileInfo = function (fileName, sourceTextSnapshot) { - return this.forwardJSONCall("getPreProcessedFileInfo('" + fileName + "')", function () { - var result = ts.preProcessFile(sourceTextSnapshot.getText(0, sourceTextSnapshot.getLength())); - var convertResult = { - referencedFiles: [], - importedFiles: [], - isLibFile: result.isLibFile - }; - ts.forEach(result.referencedFiles, function (refFile) { - convertResult.referencedFiles.push({ - path: ts.normalizePath(refFile.fileName), - position: refFile.pos, - length: refFile.end - refFile.pos - }); - }); - ts.forEach(result.importedFiles, function (importedFile) { - convertResult.importedFiles.push({ - path: ts.normalizeSlashes(importedFile.fileName), - position: importedFile.pos, - length: importedFile.end - importedFile.pos - }); - }); - return convertResult; - }); - }; - CoreServicesShimObject.prototype.getTSConfigFileInfo = function (fileName, sourceTextSnapshot) { - var _this = this; - return this.forwardJSONCall("getTSConfigFileInfo('" + fileName + "')", function () { - var text = sourceTextSnapshot.getText(0, sourceTextSnapshot.getLength()); - var result = ts.parseConfigFileText(fileName, text); - if (result.error) { - return { - options: {}, - files: [], - errors: [realizeDiagnostic(result.error, '\r\n')] - }; - } - var configFile = ts.parseConfigFile(result.config, _this.host, ts.getDirectoryPath(ts.normalizeSlashes(fileName))); - return { - options: configFile.options, - files: configFile.fileNames, - errors: realizeDiagnostics(configFile.errors, '\r\n') - }; - }); - }; - CoreServicesShimObject.prototype.getDefaultCompilationSettings = function () { - return this.forwardJSONCall("getDefaultCompilationSettings()", function () { - return ts.getDefaultCompilerOptions(); - }); - }; - return CoreServicesShimObject; - })(ShimBase); - var TypeScriptServicesFactory = (function () { - function TypeScriptServicesFactory() { - this._shims = []; - } - /* - * Returns script API version. - */ - TypeScriptServicesFactory.prototype.getServicesVersion = function () { - return ts.servicesVersion; - }; - TypeScriptServicesFactory.prototype.createLanguageServiceShim = function (host) { - try { - if (this.documentRegistry === undefined) { - this.documentRegistry = ts.createDocumentRegistry(host.useCaseSensitiveFileNames && host.useCaseSensitiveFileNames()); - } - var hostAdapter = new LanguageServiceShimHostAdapter(host); - var languageService = ts.createLanguageService(hostAdapter, this.documentRegistry); - return new LanguageServiceShimObject(this, host, languageService); - } - catch (err) { - logInternalError(host, err); - throw err; - } - }; - TypeScriptServicesFactory.prototype.createClassifierShim = function (logger) { - try { - return new ClassifierShimObject(this, logger); - } - catch (err) { - logInternalError(logger, err); - throw err; - } - }; - TypeScriptServicesFactory.prototype.createCoreServicesShim = function (host) { - try { - var adapter = new CoreServicesShimHostAdapter(host); - return new CoreServicesShimObject(this, host, adapter); - } - catch (err) { - logInternalError(host, err); - throw err; - } - }; - TypeScriptServicesFactory.prototype.close = function () { - // Forget all the registered shims - this._shims = []; - this.documentRegistry = ts.createDocumentRegistry(); - }; - TypeScriptServicesFactory.prototype.registerShim = function (shim) { - this._shims.push(shim); - }; - TypeScriptServicesFactory.prototype.unregisterShim = function (shim) { - for (var i = 0, n = this._shims.length; i < n; i++) { - if (this._shims[i] === shim) { - delete this._shims[i]; - return; - } - } - throw new Error("Invalid operation"); - }; - return TypeScriptServicesFactory; - })(); - ts.TypeScriptServicesFactory = TypeScriptServicesFactory; - if (typeof module !== "undefined" && module.exports) { - module.exports = ts; - } -})(ts || (ts = {})); -/// TODO: this is used by VS, clean this up on both sides of the interface -/* @internal */ -var TypeScript; -(function (TypeScript) { - var Services; - (function (Services) { - Services.TypeScriptServicesFactory = ts.TypeScriptServicesFactory; - })(Services = TypeScript.Services || (TypeScript.Services = {})); -})(TypeScript || (TypeScript = {})); -/* @internal */ -var toolsVersion = "1.5"; -module.exports = ts; \ No newline at end of file -- GitLab From b3f9d8a2831257be256fed43f9612771e1e172b4 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 16 Jun 2017 16:23:31 +0200 Subject: [PATCH 0961/1347] move codelense to /browser/-layer --- src/vs/editor/browser/editor.all.ts | 2 +- .../contrib/codelens/browser/codelens.ts | 663 ++---------------- .../{codelens.css => codelensController.css} | 0 .../codelens/browser/codelensController.ts | 641 +++++++++++++++++ .../contrib/codelens/common/codelens.ts | 72 -- .../workbench/api/node/extHostApiCommands.ts | 7 +- .../api/extHostLanguageFeatures.test.ts | 2 +- 7 files changed, 693 insertions(+), 694 deletions(-) rename src/vs/editor/contrib/codelens/browser/{codelens.css => codelensController.css} (100%) create mode 100644 src/vs/editor/contrib/codelens/browser/codelensController.ts delete mode 100644 src/vs/editor/contrib/codelens/common/codelens.ts diff --git a/src/vs/editor/browser/editor.all.ts b/src/vs/editor/browser/editor.all.ts index 4223fbac790..ba486b38181 100644 --- a/src/vs/editor/browser/editor.all.ts +++ b/src/vs/editor/browser/editor.all.ts @@ -14,7 +14,7 @@ import 'vs/css!vs/editor/contrib/bracketMatching/browser/bracketMatching'; import 'vs/editor/contrib/caretOperations/common/caretOperations'; import 'vs/editor/contrib/caretOperations/common/transpose'; import 'vs/editor/contrib/clipboard/browser/clipboard'; -import 'vs/editor/contrib/codelens/browser/codelens'; +import 'vs/editor/contrib/codelens/browser/codelensController'; import 'vs/editor/contrib/comment/common/comment'; import 'vs/editor/contrib/contextmenu/browser/contextmenu'; import 'vs/editor/contrib/cursorUndo/browser/cursorUndo'; diff --git a/src/vs/editor/contrib/codelens/browser/codelens.ts b/src/vs/editor/contrib/codelens/browser/codelens.ts index 2c7e6ff341c..2cbda09d66f 100644 --- a/src/vs/editor/contrib/codelens/browser/codelens.ts +++ b/src/vs/editor/contrib/codelens/browser/codelens.ts @@ -5,637 +5,68 @@ 'use strict'; -import 'vs/css!./codelens'; -import { RunOnceScheduler, asWinJsPromise } from 'vs/base/common/async'; -import { onUnexpectedError } from 'vs/base/common/errors'; -import { IDisposable, dispose } from 'vs/base/common/lifecycle'; -import Severity from 'vs/base/common/severity'; -import { format, escape } from 'vs/base/common/strings'; +import { illegalArgument, onUnexpectedExternalError } from 'vs/base/common/errors'; +import { stableSort } from 'vs/base/common/arrays'; +import URI from 'vs/base/common/uri'; import { TPromise } from 'vs/base/common/winjs.base'; -import * as dom from 'vs/base/browser/dom'; -import { ICommandService } from 'vs/platform/commands/common/commands'; -import { IMessageService } from 'vs/platform/message/common/message'; -import { Range } from 'vs/editor/common/core/range'; -import * as editorCommon from 'vs/editor/common/editorCommon'; -import { CodeLensProviderRegistry, ICodeLensSymbol, Command } from 'vs/editor/common/modes'; -import * as editorBrowser from 'vs/editor/browser/editorBrowser'; -import { editorContribution } from 'vs/editor/browser/editorBrowserExtensions'; -import { ICodeLensData, getCodeLensData } from '../common/codelens'; -import { IConfigurationChangedEvent } from 'vs/editor/common/config/editorOptions'; -import { editorCodeLensForeground } from 'vs/editor/common/view/editorColorRegistry'; -import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; -import { editorActiveLinkForeground } from 'vs/platform/theme/common/colorRegistry'; -import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; - - -class CodeLensViewZone implements editorBrowser.IViewZone { - - public afterLineNumber: number; - public heightInLines: number; - public suppressMouseDown: boolean; - public domNode: HTMLElement; - private _lastHeight: number; - private _onHeight: Function; - - constructor(afterLineNumber: number, onHeight: Function) { - this.afterLineNumber = afterLineNumber; - this._onHeight = onHeight; - - this.heightInLines = 1; - this.suppressMouseDown = true; - this.domNode = document.createElement('div'); - } - - public setAfterLineNumber(afterLineNumber: number): void { - this.afterLineNumber = afterLineNumber; - } - - onComputedHeight(height: number): void { - if (this._lastHeight === undefined) { - this._lastHeight = height; - } else if (this._lastHeight !== height) { - this._lastHeight = height; - this._onHeight(); - } - } - +import { IModel } from 'vs/editor/common/editorCommon'; +import { CommonEditorRegistry } from 'vs/editor/common/editorCommonExtensions'; +import { CodeLensProviderRegistry, CodeLensProvider, ICodeLensSymbol } from 'vs/editor/common/modes'; +import { IModelService } from 'vs/editor/common/services/modelService'; +import { asWinJsPromise } from 'vs/base/common/async'; + +export interface ICodeLensData { + symbol: ICodeLensSymbol; + provider: CodeLensProvider; } -class CodeLensContentWidget implements editorBrowser.IContentWidget { - - private static ID: number = 0; - - // Editor.IContentWidget.allowEditorOverflow - readonly allowEditorOverflow: boolean = false; - readonly suppressMouseDown: boolean = true; - - private _id: string; - - private _domNode: HTMLElement; - private _disposables: IDisposable[] = []; - private _symbolRange: Range; - private _widgetPosition: editorBrowser.IContentWidgetPosition; - private _editor: editorBrowser.ICodeEditor; - private _commands: { [id: string]: Command } = Object.create(null); - - public constructor( - editor: editorBrowser.ICodeEditor, - symbolRange: Range, - commandService: ICommandService, - messageService: IMessageService - ) { - - this._id = 'codeLensWidget' + (++CodeLensContentWidget.ID); - this._editor = editor; - - this.setSymbolRange(symbolRange); - - this._domNode = document.createElement('span'); - this._domNode.innerHTML = ' '; - dom.addClass(this._domNode, 'codelens-decoration'); - dom.addClass(this._domNode, 'invisible-cl'); - this._updateHeight(); - - this._disposables.push(this._editor.onDidChangeConfiguration(e => { - if (e.fontInfo) { - this._updateHeight(); - } - })); - - this._disposables.push(dom.addDisposableListener(this._domNode, 'click', e => { - let element = e.target; - if (element.tagName === 'A' && element.id) { - let command = this._commands[element.id]; - if (command) { - editor.focus(); - commandService.executeCommand(command.id, ...command.arguments).done(undefined, err => { - messageService.show(Severity.Error, err); - }); - } - } - })); - - this.updateVisibility(); - } - - public dispose(): void { - dispose(this._disposables); - this._symbolRange = null; - } - - private _updateHeight(): void { - const { fontInfo, lineHeight } = this._editor.getConfiguration(); - this._domNode.style.height = `${Math.round(lineHeight * 1.1)}px`; - this._domNode.style.lineHeight = `${lineHeight}px`; - this._domNode.style.fontSize = `${Math.round(fontInfo.fontSize * .9)}px`; - this._domNode.innerHTML = ' '; - } - - public updateVisibility(): void { - if (this.isVisible()) { - dom.removeClass(this._domNode, 'invisible-cl'); - dom.addClass(this._domNode, 'fadein'); - } - } +export function getCodeLensData(model: IModel): TPromise { - public withCommands(symbols: ICodeLensSymbol[]): void { - this._commands = Object.create(null); - if (!symbols || !symbols.length) { - this._domNode.innerHTML = 'no commands'; - return; - } + const symbols: ICodeLensData[] = []; + const provider = CodeLensProviderRegistry.ordered(model); - let html: string[] = []; - for (let i = 0; i < symbols.length; i++) { - let command = symbols[i].command; - let title = escape(command.title); - let part: string; - if (command.id) { - part = format('{1}', i, title); - this._commands[i] = command; - } else { - part = format('{0}', title); + const promises = provider.map(provider => asWinJsPromise(token => provider.provideCodeLenses(model, token)).then(result => { + if (Array.isArray(result)) { + for (let symbol of result) { + symbols.push({ symbol, provider }); } - html.push(part); - } - - this._domNode.innerHTML = html.join(' | '); - this._editor.layoutContentWidget(this); - } - - public getId(): string { - return this._id; - } - - public getDomNode(): HTMLElement { - return this._domNode; - } - - public setSymbolRange(range: Range): void { - this._symbolRange = range; - - const lineNumber = range.startLineNumber; - const column = this._editor.getModel().getLineFirstNonWhitespaceColumn(lineNumber); - this._widgetPosition = { - position: { lineNumber: lineNumber, column: column }, - preference: [editorBrowser.ContentWidgetPositionPreference.ABOVE] - }; - } - - public getPosition(): editorBrowser.IContentWidgetPosition { - return this._widgetPosition; - } - - public isVisible(): boolean { - return this._domNode.hasAttribute('monaco-visible-content-widget'); - } -} - -interface IDecorationIdCallback { - (decorationId: string): void; -} - -class CodeLensHelper { - - private _removeDecorations: string[]; - private _addDecorations: editorCommon.IModelDeltaDecoration[]; - private _addDecorationsCallbacks: IDecorationIdCallback[]; - - constructor() { - this._removeDecorations = []; - this._addDecorations = []; - this._addDecorationsCallbacks = []; - } - - public addDecoration(decoration: editorCommon.IModelDeltaDecoration, callback: IDecorationIdCallback): void { - this._addDecorations.push(decoration); - this._addDecorationsCallbacks.push(callback); - } - - public removeDecoration(decorationId: string): void { - this._removeDecorations.push(decorationId); - } - - public commit(changeAccessor: editorCommon.IModelDecorationsChangeAccessor): void { - var resultingDecorations = changeAccessor.deltaDecorations(this._removeDecorations, this._addDecorations); - for (let i = 0, len = resultingDecorations.length; i < len; i++) { - this._addDecorationsCallbacks[i](resultingDecorations[i]); } - } -} - -class CodeLens { - - private _viewZone: CodeLensViewZone; - private _viewZoneId: number; - private _contentWidget: CodeLensContentWidget; - private _decorationIds: string[]; - private _data: ICodeLensData[]; - private _editor: editorBrowser.ICodeEditor; - - public constructor( - data: ICodeLensData[], - editor: editorBrowser.ICodeEditor, - helper: CodeLensHelper, - viewZoneChangeAccessor: editorBrowser.IViewZoneChangeAccessor, - commandService: ICommandService, messageService: IMessageService, - updateCallabck: Function - ) { - - this._editor = editor; - this._data = data; - this._decorationIds = new Array(this._data.length); - - let range: Range; - this._data.forEach((codeLensData, i) => { - - helper.addDecoration({ - range: codeLensData.symbol.range, - options: ModelDecorationOptions.EMPTY - }, id => this._decorationIds[i] = id); - - // the range contains all lenses on this line - if (!range) { - range = Range.lift(codeLensData.symbol.range); + }, onUnexpectedExternalError)); + + return TPromise.join(promises).then(() => { + + return stableSort(symbols, (a, b) => { + // sort by lineNumber, provider-rank, and column + if (a.symbol.range.startLineNumber < b.symbol.range.startLineNumber) { + return -1; + } else if (a.symbol.range.startLineNumber > b.symbol.range.startLineNumber) { + return 1; + } else if (provider.indexOf(a.provider) < provider.indexOf(b.provider)) { + return -1; + } else if (provider.indexOf(a.provider) > provider.indexOf(b.provider)) { + return 1; + } else if (a.symbol.range.startColumn < b.symbol.range.startColumn) { + return -1; + } else if (a.symbol.range.startColumn > b.symbol.range.startColumn) { + return 1; } else { - range = Range.plusRange(range, codeLensData.symbol.range); + return 0; } }); - - this._contentWidget = new CodeLensContentWidget(editor, range, commandService, messageService); - this._viewZone = new CodeLensViewZone(range.startLineNumber - 1, updateCallabck); - - this._viewZoneId = viewZoneChangeAccessor.addZone(this._viewZone); - this._editor.addContentWidget(this._contentWidget); - } - - public dispose(helper: CodeLensHelper, viewZoneChangeAccessor: editorBrowser.IViewZoneChangeAccessor): void { - while (this._decorationIds.length) { - helper.removeDecoration(this._decorationIds.pop()); - } - if (viewZoneChangeAccessor) { - viewZoneChangeAccessor.removeZone(this._viewZoneId); - } - this._editor.removeContentWidget(this._contentWidget); - - this._contentWidget.dispose(); - } - - public isValid(): boolean { - return this._decorationIds.some((id, i) => { - const range = this._editor.getModel().getDecorationRange(id); - const symbol = this._data[i].symbol; - return range && Range.isEmpty(symbol.range) === range.isEmpty(); - }); - } - - public updateCodeLensSymbols(data: ICodeLensData[], helper: CodeLensHelper): void { - while (this._decorationIds.length) { - helper.removeDecoration(this._decorationIds.pop()); - } - this._data = data; - this._decorationIds = new Array(this._data.length); - this._data.forEach((codeLensData, i) => { - helper.addDecoration({ - range: codeLensData.symbol.range, - options: ModelDecorationOptions.EMPTY - }, id => this._decorationIds[i] = id); - }); - } - - public computeIfNecessary(model: editorCommon.IModel): ICodeLensData[] { - this._contentWidget.updateVisibility(); // trigger the fade in - if (!this._contentWidget.isVisible()) { - return null; - } - - // Read editor current state - for (let i = 0; i < this._decorationIds.length; i++) { - this._data[i].symbol.range = model.getDecorationRange(this._decorationIds[i]); - } - return this._data; - } - - public updateCommands(symbols: ICodeLensSymbol[]): void { - this._contentWidget.withCommands(symbols); - } - - public getLineNumber(): number { - const range = this._editor.getModel().getDecorationRange(this._decorationIds[0]); - if (range) { - return range.startLineNumber; - } - return -1; - } - - public update(viewZoneChangeAccessor: editorBrowser.IViewZoneChangeAccessor): void { - if (this.isValid()) { - const range = this._editor.getModel().getDecorationRange(this._decorationIds[0]); - - this._viewZone.setAfterLineNumber(range.startLineNumber - 1); - viewZoneChangeAccessor.layoutZone(this._viewZoneId); - - this._contentWidget.setSymbolRange(range); - this._editor.layoutContentWidget(this._contentWidget); - } - } + }); } -@editorContribution -export class CodeLensContribution implements editorCommon.IEditorContribution { - - private static ID: string = 'css.editor.codeLens'; - - private _isEnabled: boolean; - - private _globalToDispose: IDisposable[]; - private _localToDispose: IDisposable[]; - private _lenses: CodeLens[]; - private _currentFindCodeLensSymbolsPromise: TPromise; - private _modelChangeCounter: number; - private _currentFindOccPromise: TPromise; - private _detectVisibleLenses: RunOnceScheduler; - - constructor( - private _editor: editorBrowser.ICodeEditor, - @ICommandService private _commandService: ICommandService, - @IMessageService private _messageService: IMessageService - ) { - this._isEnabled = this._editor.getConfiguration().contribInfo.codeLens; - - this._globalToDispose = []; - this._localToDispose = []; - this._lenses = []; - this._currentFindCodeLensSymbolsPromise = null; - this._modelChangeCounter = 0; - - this._globalToDispose.push(this._editor.onDidChangeModel(() => this.onModelChange())); - this._globalToDispose.push(this._editor.onDidChangeModelLanguage(() => this.onModelChange())); - this._globalToDispose.push(this._editor.onDidChangeConfiguration((e: IConfigurationChangedEvent) => { - let prevIsEnabled = this._isEnabled; - this._isEnabled = this._editor.getConfiguration().contribInfo.codeLens; - if (prevIsEnabled !== this._isEnabled) { - this.onModelChange(); - } - })); - this._globalToDispose.push(CodeLensProviderRegistry.onDidChange(this.onModelChange, this)); - this.onModelChange(); - } - - public dispose(): void { - this.localDispose(); - this._globalToDispose = dispose(this._globalToDispose); - } +CommonEditorRegistry.registerLanguageCommand('_executeCodeLensProvider', function (accessor, args) { - private localDispose(): void { - if (this._currentFindCodeLensSymbolsPromise) { - this._currentFindCodeLensSymbolsPromise.cancel(); - this._currentFindCodeLensSymbolsPromise = null; - this._modelChangeCounter++; - } - if (this._currentFindOccPromise) { - this._currentFindOccPromise.cancel(); - this._currentFindOccPromise = null; - } - this._localToDispose = dispose(this._localToDispose); + const { resource } = args; + if (!(resource instanceof URI)) { + throw illegalArgument(); } - public getId(): string { - return CodeLensContribution.ID; + const model = accessor.get(IModelService).getModel(resource); + if (!model) { + throw illegalArgument(); } - private onModelChange(): void { - - this.localDispose(); - - const model = this._editor.getModel(); - if (!model) { - return; - } - - if (!this._isEnabled) { - return; - } - - if (!CodeLensProviderRegistry.has(model)) { - return; - } - - for (const provider of CodeLensProviderRegistry.all(model)) { - if (typeof provider.onDidChange === 'function') { - let registration = provider.onDidChange(() => scheduler.schedule()); - this._localToDispose.push(registration); - } - } - - this._detectVisibleLenses = new RunOnceScheduler(() => { - this._onViewportChanged(model.getLanguageIdentifier().language); - }, 500); - - const scheduler = new RunOnceScheduler(() => { - if (this._currentFindCodeLensSymbolsPromise) { - this._currentFindCodeLensSymbolsPromise.cancel(); - } - - this._currentFindCodeLensSymbolsPromise = getCodeLensData(model); - - const counterValue = ++this._modelChangeCounter; - this._currentFindCodeLensSymbolsPromise.then((result) => { - if (counterValue === this._modelChangeCounter) { // only the last one wins - this.renderCodeLensSymbols(result); - this._detectVisibleLenses.schedule(); - } - }, (error) => { - onUnexpectedError(error); - }); - }, 250); - this._localToDispose.push(scheduler); - this._localToDispose.push(this._detectVisibleLenses); - this._localToDispose.push(this._editor.onDidChangeModelContent((e) => { - this._editor.changeDecorations((changeAccessor) => { - this._editor.changeViewZones((viewAccessor) => { - const toDispose: CodeLens[] = []; - this._lenses.forEach((lens) => { - if (lens.isValid()) { - lens.update(viewAccessor); - } else { - toDispose.push(lens); - } - }); - - let helper = new CodeLensHelper(); - toDispose.forEach((l) => { - l.dispose(helper, viewAccessor); - this._lenses.splice(this._lenses.indexOf(l), 1); - }); - helper.commit(changeAccessor); - }); - }); - - // Compute new `visible` code lenses - this._detectVisibleLenses.schedule(); - // Ask for all references again - scheduler.schedule(); - })); - this._localToDispose.push(this._editor.onDidScrollChange(e => { - if (e.scrollTopChanged) { - this._detectVisibleLenses.schedule(); - } - })); - this._localToDispose.push(this._editor.onDidLayoutChange(e => { - this._detectVisibleLenses.schedule(); - })); - this._localToDispose.push({ - dispose: () => { - if (this._editor.getModel()) { - this._editor.changeDecorations((changeAccessor) => { - this._editor.changeViewZones((accessor) => { - this._disposeAllLenses(changeAccessor, accessor); - }); - }); - } else { - // No accessors available - this._disposeAllLenses(null, null); - } - } - }); - - scheduler.schedule(); - } - - private _disposeAllLenses(decChangeAccessor: editorCommon.IModelDecorationsChangeAccessor, viewZoneChangeAccessor: editorBrowser.IViewZoneChangeAccessor): void { - let helper = new CodeLensHelper(); - this._lenses.forEach((lens) => lens.dispose(helper, viewZoneChangeAccessor)); - if (decChangeAccessor) { - helper.commit(decChangeAccessor); - } - this._lenses = []; - } - - private renderCodeLensSymbols(symbols: ICodeLensData[]): void { - if (!this._editor.getModel()) { - return; - } - - let maxLineNumber = this._editor.getModel().getLineCount(); - let groups: ICodeLensData[][] = []; - let lastGroup: ICodeLensData[]; - - for (let symbol of symbols) { - let line = symbol.symbol.range.startLineNumber; - if (line < 1 || line > maxLineNumber) { - // invalid code lens - continue; - } else if (lastGroup && lastGroup[lastGroup.length - 1].symbol.range.startLineNumber === line) { - // on same line as previous - lastGroup.push(symbol); - } else { - // on later line as previous - lastGroup = [symbol]; - groups.push(lastGroup); - } - } - - const centeredRange = this._editor.getCenteredRangeInViewport(); - const shouldRestoreCenteredRange = centeredRange && (groups.length !== this._lenses.length && this._editor.getScrollTop() !== 0); - this._editor.changeDecorations((changeAccessor) => { - this._editor.changeViewZones((accessor) => { - - let codeLensIndex = 0, groupsIndex = 0, helper = new CodeLensHelper(); - - while (groupsIndex < groups.length && codeLensIndex < this._lenses.length) { - - let symbolsLineNumber = groups[groupsIndex][0].symbol.range.startLineNumber; - let codeLensLineNumber = this._lenses[codeLensIndex].getLineNumber(); - - if (codeLensLineNumber < symbolsLineNumber) { - this._lenses[codeLensIndex].dispose(helper, accessor); - this._lenses.splice(codeLensIndex, 1); - } else if (codeLensLineNumber === symbolsLineNumber) { - this._lenses[codeLensIndex].updateCodeLensSymbols(groups[groupsIndex], helper); - groupsIndex++; - codeLensIndex++; - } else { - this._lenses.splice(codeLensIndex, 0, new CodeLens(groups[groupsIndex], this._editor, helper, accessor, this._commandService, this._messageService, () => this._detectVisibleLenses.schedule())); - codeLensIndex++; - groupsIndex++; - } - } - - // Delete extra code lenses - while (codeLensIndex < this._lenses.length) { - this._lenses[codeLensIndex].dispose(helper, accessor); - this._lenses.splice(codeLensIndex, 1); - } - - // Create extra symbols - while (groupsIndex < groups.length) { - this._lenses.push(new CodeLens(groups[groupsIndex], this._editor, helper, accessor, this._commandService, this._messageService, () => this._detectVisibleLenses.schedule())); - groupsIndex++; - } - - helper.commit(changeAccessor); - }); - }); - if (shouldRestoreCenteredRange) { - this._editor.revealRangeInCenter(centeredRange); - } - } - - private _onViewportChanged(modeId: string): void { - if (this._currentFindOccPromise) { - this._currentFindOccPromise.cancel(); - this._currentFindOccPromise = null; - } - - const model = this._editor.getModel(); - if (!model) { - return; - } - - const toResolve: ICodeLensData[][] = []; - const lenses: CodeLens[] = []; - this._lenses.forEach((lens) => { - const request = lens.computeIfNecessary(model); - if (request) { - toResolve.push(request); - lenses.push(lens); - } - }); - - if (toResolve.length === 0) { - return; - } - - const promises = toResolve.map((request, i) => { - - const resolvedSymbols = new Array(request.length); - const promises = request.map((request, i) => { - return asWinJsPromise((token) => { - return request.provider.resolveCodeLens(model, request.symbol, token); - }).then(symbol => { - resolvedSymbols[i] = symbol; - }); - }); - - return TPromise.join(promises).then(() => { - lenses[i].updateCommands(resolvedSymbols); - }); - }); - - this._currentFindOccPromise = TPromise.join(promises).then(() => { - this._currentFindOccPromise = null; - }); - } -} - -registerThemingParticipant((theme, collector) => { - let codeLensForeground = theme.getColor(editorCodeLensForeground); - if (codeLensForeground) { - collector.addRule(`.monaco-editor .codelens-decoration { color: ${codeLensForeground}; }`); - } - let activeLinkForeground = theme.getColor(editorActiveLinkForeground); - if (activeLinkForeground) { - collector.addRule(`.monaco-editor .codelens-decoration > a:hover { color: ${activeLinkForeground} !important; }`); - } + return getCodeLensData(model).then(value => value.map(item => item.symbol)); }); diff --git a/src/vs/editor/contrib/codelens/browser/codelens.css b/src/vs/editor/contrib/codelens/browser/codelensController.css similarity index 100% rename from src/vs/editor/contrib/codelens/browser/codelens.css rename to src/vs/editor/contrib/codelens/browser/codelensController.css diff --git a/src/vs/editor/contrib/codelens/browser/codelensController.ts b/src/vs/editor/contrib/codelens/browser/codelensController.ts new file mode 100644 index 00000000000..c43b02b73e9 --- /dev/null +++ b/src/vs/editor/contrib/codelens/browser/codelensController.ts @@ -0,0 +1,641 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +'use strict'; + +import 'vs/css!./codelensController'; +import { RunOnceScheduler, asWinJsPromise } from 'vs/base/common/async'; +import { onUnexpectedError } from 'vs/base/common/errors'; +import { IDisposable, dispose } from 'vs/base/common/lifecycle'; +import Severity from 'vs/base/common/severity'; +import { format, escape } from 'vs/base/common/strings'; +import { TPromise } from 'vs/base/common/winjs.base'; +import * as dom from 'vs/base/browser/dom'; +import { ICommandService } from 'vs/platform/commands/common/commands'; +import { IMessageService } from 'vs/platform/message/common/message'; +import { Range } from 'vs/editor/common/core/range'; +import * as editorCommon from 'vs/editor/common/editorCommon'; +import { CodeLensProviderRegistry, ICodeLensSymbol, Command } from 'vs/editor/common/modes'; +import * as editorBrowser from 'vs/editor/browser/editorBrowser'; +import { editorContribution } from 'vs/editor/browser/editorBrowserExtensions'; +import { ICodeLensData, getCodeLensData } from './codelens'; +import { IConfigurationChangedEvent } from 'vs/editor/common/config/editorOptions'; +import { editorCodeLensForeground } from 'vs/editor/common/view/editorColorRegistry'; +import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; +import { editorActiveLinkForeground } from 'vs/platform/theme/common/colorRegistry'; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; + + +class CodeLensViewZone implements editorBrowser.IViewZone { + + public afterLineNumber: number; + public heightInLines: number; + public suppressMouseDown: boolean; + public domNode: HTMLElement; + private _lastHeight: number; + private _onHeight: Function; + + constructor(afterLineNumber: number, onHeight: Function) { + this.afterLineNumber = afterLineNumber; + this._onHeight = onHeight; + + this.heightInLines = 1; + this.suppressMouseDown = true; + this.domNode = document.createElement('div'); + } + + public setAfterLineNumber(afterLineNumber: number): void { + this.afterLineNumber = afterLineNumber; + } + + onComputedHeight(height: number): void { + if (this._lastHeight === undefined) { + this._lastHeight = height; + } else if (this._lastHeight !== height) { + this._lastHeight = height; + this._onHeight(); + } + } + +} + +class CodeLensContentWidget implements editorBrowser.IContentWidget { + + private static ID: number = 0; + + // Editor.IContentWidget.allowEditorOverflow + readonly allowEditorOverflow: boolean = false; + readonly suppressMouseDown: boolean = true; + + private _id: string; + + private _domNode: HTMLElement; + private _disposables: IDisposable[] = []; + private _symbolRange: Range; + private _widgetPosition: editorBrowser.IContentWidgetPosition; + private _editor: editorBrowser.ICodeEditor; + private _commands: { [id: string]: Command } = Object.create(null); + + public constructor( + editor: editorBrowser.ICodeEditor, + symbolRange: Range, + commandService: ICommandService, + messageService: IMessageService + ) { + + this._id = 'codeLensWidget' + (++CodeLensContentWidget.ID); + this._editor = editor; + + this.setSymbolRange(symbolRange); + + this._domNode = document.createElement('span'); + this._domNode.innerHTML = ' '; + dom.addClass(this._domNode, 'codelens-decoration'); + dom.addClass(this._domNode, 'invisible-cl'); + this._updateHeight(); + + this._disposables.push(this._editor.onDidChangeConfiguration(e => { + if (e.fontInfo) { + this._updateHeight(); + } + })); + + this._disposables.push(dom.addDisposableListener(this._domNode, 'click', e => { + let element = e.target; + if (element.tagName === 'A' && element.id) { + let command = this._commands[element.id]; + if (command) { + editor.focus(); + commandService.executeCommand(command.id, ...command.arguments).done(undefined, err => { + messageService.show(Severity.Error, err); + }); + } + } + })); + + this.updateVisibility(); + } + + public dispose(): void { + dispose(this._disposables); + this._symbolRange = null; + } + + private _updateHeight(): void { + const { fontInfo, lineHeight } = this._editor.getConfiguration(); + this._domNode.style.height = `${Math.round(lineHeight * 1.1)}px`; + this._domNode.style.lineHeight = `${lineHeight}px`; + this._domNode.style.fontSize = `${Math.round(fontInfo.fontSize * .9)}px`; + this._domNode.innerHTML = ' '; + } + + public updateVisibility(): void { + if (this.isVisible()) { + dom.removeClass(this._domNode, 'invisible-cl'); + dom.addClass(this._domNode, 'fadein'); + } + } + + public withCommands(symbols: ICodeLensSymbol[]): void { + this._commands = Object.create(null); + if (!symbols || !symbols.length) { + this._domNode.innerHTML = 'no commands'; + return; + } + + let html: string[] = []; + for (let i = 0; i < symbols.length; i++) { + let command = symbols[i].command; + let title = escape(command.title); + let part: string; + if (command.id) { + part = format('{1}', i, title); + this._commands[i] = command; + } else { + part = format('{0}', title); + } + html.push(part); + } + + this._domNode.innerHTML = html.join(' | '); + this._editor.layoutContentWidget(this); + } + + public getId(): string { + return this._id; + } + + public getDomNode(): HTMLElement { + return this._domNode; + } + + public setSymbolRange(range: Range): void { + this._symbolRange = range; + + const lineNumber = range.startLineNumber; + const column = this._editor.getModel().getLineFirstNonWhitespaceColumn(lineNumber); + this._widgetPosition = { + position: { lineNumber: lineNumber, column: column }, + preference: [editorBrowser.ContentWidgetPositionPreference.ABOVE] + }; + } + + public getPosition(): editorBrowser.IContentWidgetPosition { + return this._widgetPosition; + } + + public isVisible(): boolean { + return this._domNode.hasAttribute('monaco-visible-content-widget'); + } +} + +interface IDecorationIdCallback { + (decorationId: string): void; +} + +class CodeLensHelper { + + private _removeDecorations: string[]; + private _addDecorations: editorCommon.IModelDeltaDecoration[]; + private _addDecorationsCallbacks: IDecorationIdCallback[]; + + constructor() { + this._removeDecorations = []; + this._addDecorations = []; + this._addDecorationsCallbacks = []; + } + + public addDecoration(decoration: editorCommon.IModelDeltaDecoration, callback: IDecorationIdCallback): void { + this._addDecorations.push(decoration); + this._addDecorationsCallbacks.push(callback); + } + + public removeDecoration(decorationId: string): void { + this._removeDecorations.push(decorationId); + } + + public commit(changeAccessor: editorCommon.IModelDecorationsChangeAccessor): void { + var resultingDecorations = changeAccessor.deltaDecorations(this._removeDecorations, this._addDecorations); + for (let i = 0, len = resultingDecorations.length; i < len; i++) { + this._addDecorationsCallbacks[i](resultingDecorations[i]); + } + } +} + +class CodeLens { + + private _viewZone: CodeLensViewZone; + private _viewZoneId: number; + private _contentWidget: CodeLensContentWidget; + private _decorationIds: string[]; + private _data: ICodeLensData[]; + private _editor: editorBrowser.ICodeEditor; + + public constructor( + data: ICodeLensData[], + editor: editorBrowser.ICodeEditor, + helper: CodeLensHelper, + viewZoneChangeAccessor: editorBrowser.IViewZoneChangeAccessor, + commandService: ICommandService, messageService: IMessageService, + updateCallabck: Function + ) { + + this._editor = editor; + this._data = data; + this._decorationIds = new Array(this._data.length); + + let range: Range; + this._data.forEach((codeLensData, i) => { + + helper.addDecoration({ + range: codeLensData.symbol.range, + options: ModelDecorationOptions.EMPTY + }, id => this._decorationIds[i] = id); + + // the range contains all lenses on this line + if (!range) { + range = Range.lift(codeLensData.symbol.range); + } else { + range = Range.plusRange(range, codeLensData.symbol.range); + } + }); + + this._contentWidget = new CodeLensContentWidget(editor, range, commandService, messageService); + this._viewZone = new CodeLensViewZone(range.startLineNumber - 1, updateCallabck); + + this._viewZoneId = viewZoneChangeAccessor.addZone(this._viewZone); + this._editor.addContentWidget(this._contentWidget); + } + + public dispose(helper: CodeLensHelper, viewZoneChangeAccessor: editorBrowser.IViewZoneChangeAccessor): void { + while (this._decorationIds.length) { + helper.removeDecoration(this._decorationIds.pop()); + } + if (viewZoneChangeAccessor) { + viewZoneChangeAccessor.removeZone(this._viewZoneId); + } + this._editor.removeContentWidget(this._contentWidget); + + this._contentWidget.dispose(); + } + + public isValid(): boolean { + return this._decorationIds.some((id, i) => { + const range = this._editor.getModel().getDecorationRange(id); + const symbol = this._data[i].symbol; + return range && Range.isEmpty(symbol.range) === range.isEmpty(); + }); + } + + public updateCodeLensSymbols(data: ICodeLensData[], helper: CodeLensHelper): void { + while (this._decorationIds.length) { + helper.removeDecoration(this._decorationIds.pop()); + } + this._data = data; + this._decorationIds = new Array(this._data.length); + this._data.forEach((codeLensData, i) => { + helper.addDecoration({ + range: codeLensData.symbol.range, + options: ModelDecorationOptions.EMPTY + }, id => this._decorationIds[i] = id); + }); + } + + public computeIfNecessary(model: editorCommon.IModel): ICodeLensData[] { + this._contentWidget.updateVisibility(); // trigger the fade in + if (!this._contentWidget.isVisible()) { + return null; + } + + // Read editor current state + for (let i = 0; i < this._decorationIds.length; i++) { + this._data[i].symbol.range = model.getDecorationRange(this._decorationIds[i]); + } + return this._data; + } + + public updateCommands(symbols: ICodeLensSymbol[]): void { + this._contentWidget.withCommands(symbols); + } + + public getLineNumber(): number { + const range = this._editor.getModel().getDecorationRange(this._decorationIds[0]); + if (range) { + return range.startLineNumber; + } + return -1; + } + + public update(viewZoneChangeAccessor: editorBrowser.IViewZoneChangeAccessor): void { + if (this.isValid()) { + const range = this._editor.getModel().getDecorationRange(this._decorationIds[0]); + + this._viewZone.setAfterLineNumber(range.startLineNumber - 1); + viewZoneChangeAccessor.layoutZone(this._viewZoneId); + + this._contentWidget.setSymbolRange(range); + this._editor.layoutContentWidget(this._contentWidget); + } + } +} + +@editorContribution +export class CodeLensContribution implements editorCommon.IEditorContribution { + + private static ID: string = 'css.editor.codeLens'; + + private _isEnabled: boolean; + + private _globalToDispose: IDisposable[]; + private _localToDispose: IDisposable[]; + private _lenses: CodeLens[]; + private _currentFindCodeLensSymbolsPromise: TPromise; + private _modelChangeCounter: number; + private _currentFindOccPromise: TPromise; + private _detectVisibleLenses: RunOnceScheduler; + + constructor( + private _editor: editorBrowser.ICodeEditor, + @ICommandService private _commandService: ICommandService, + @IMessageService private _messageService: IMessageService + ) { + this._isEnabled = this._editor.getConfiguration().contribInfo.codeLens; + + this._globalToDispose = []; + this._localToDispose = []; + this._lenses = []; + this._currentFindCodeLensSymbolsPromise = null; + this._modelChangeCounter = 0; + + this._globalToDispose.push(this._editor.onDidChangeModel(() => this.onModelChange())); + this._globalToDispose.push(this._editor.onDidChangeModelLanguage(() => this.onModelChange())); + this._globalToDispose.push(this._editor.onDidChangeConfiguration((e: IConfigurationChangedEvent) => { + let prevIsEnabled = this._isEnabled; + this._isEnabled = this._editor.getConfiguration().contribInfo.codeLens; + if (prevIsEnabled !== this._isEnabled) { + this.onModelChange(); + } + })); + this._globalToDispose.push(CodeLensProviderRegistry.onDidChange(this.onModelChange, this)); + this.onModelChange(); + } + + public dispose(): void { + this.localDispose(); + this._globalToDispose = dispose(this._globalToDispose); + } + + private localDispose(): void { + if (this._currentFindCodeLensSymbolsPromise) { + this._currentFindCodeLensSymbolsPromise.cancel(); + this._currentFindCodeLensSymbolsPromise = null; + this._modelChangeCounter++; + } + if (this._currentFindOccPromise) { + this._currentFindOccPromise.cancel(); + this._currentFindOccPromise = null; + } + this._localToDispose = dispose(this._localToDispose); + } + + public getId(): string { + return CodeLensContribution.ID; + } + + private onModelChange(): void { + + this.localDispose(); + + const model = this._editor.getModel(); + if (!model) { + return; + } + + if (!this._isEnabled) { + return; + } + + if (!CodeLensProviderRegistry.has(model)) { + return; + } + + for (const provider of CodeLensProviderRegistry.all(model)) { + if (typeof provider.onDidChange === 'function') { + let registration = provider.onDidChange(() => scheduler.schedule()); + this._localToDispose.push(registration); + } + } + + this._detectVisibleLenses = new RunOnceScheduler(() => { + this._onViewportChanged(model.getLanguageIdentifier().language); + }, 500); + + const scheduler = new RunOnceScheduler(() => { + if (this._currentFindCodeLensSymbolsPromise) { + this._currentFindCodeLensSymbolsPromise.cancel(); + } + + this._currentFindCodeLensSymbolsPromise = getCodeLensData(model); + + const counterValue = ++this._modelChangeCounter; + this._currentFindCodeLensSymbolsPromise.then((result) => { + if (counterValue === this._modelChangeCounter) { // only the last one wins + this.renderCodeLensSymbols(result); + this._detectVisibleLenses.schedule(); + } + }, (error) => { + onUnexpectedError(error); + }); + }, 250); + this._localToDispose.push(scheduler); + this._localToDispose.push(this._detectVisibleLenses); + this._localToDispose.push(this._editor.onDidChangeModelContent((e) => { + this._editor.changeDecorations((changeAccessor) => { + this._editor.changeViewZones((viewAccessor) => { + const toDispose: CodeLens[] = []; + this._lenses.forEach((lens) => { + if (lens.isValid()) { + lens.update(viewAccessor); + } else { + toDispose.push(lens); + } + }); + + let helper = new CodeLensHelper(); + toDispose.forEach((l) => { + l.dispose(helper, viewAccessor); + this._lenses.splice(this._lenses.indexOf(l), 1); + }); + helper.commit(changeAccessor); + }); + }); + + // Compute new `visible` code lenses + this._detectVisibleLenses.schedule(); + // Ask for all references again + scheduler.schedule(); + })); + this._localToDispose.push(this._editor.onDidScrollChange(e => { + if (e.scrollTopChanged) { + this._detectVisibleLenses.schedule(); + } + })); + this._localToDispose.push(this._editor.onDidLayoutChange(e => { + this._detectVisibleLenses.schedule(); + })); + this._localToDispose.push({ + dispose: () => { + if (this._editor.getModel()) { + this._editor.changeDecorations((changeAccessor) => { + this._editor.changeViewZones((accessor) => { + this._disposeAllLenses(changeAccessor, accessor); + }); + }); + } else { + // No accessors available + this._disposeAllLenses(null, null); + } + } + }); + + scheduler.schedule(); + } + + private _disposeAllLenses(decChangeAccessor: editorCommon.IModelDecorationsChangeAccessor, viewZoneChangeAccessor: editorBrowser.IViewZoneChangeAccessor): void { + let helper = new CodeLensHelper(); + this._lenses.forEach((lens) => lens.dispose(helper, viewZoneChangeAccessor)); + if (decChangeAccessor) { + helper.commit(decChangeAccessor); + } + this._lenses = []; + } + + private renderCodeLensSymbols(symbols: ICodeLensData[]): void { + if (!this._editor.getModel()) { + return; + } + + let maxLineNumber = this._editor.getModel().getLineCount(); + let groups: ICodeLensData[][] = []; + let lastGroup: ICodeLensData[]; + + for (let symbol of symbols) { + let line = symbol.symbol.range.startLineNumber; + if (line < 1 || line > maxLineNumber) { + // invalid code lens + continue; + } else if (lastGroup && lastGroup[lastGroup.length - 1].symbol.range.startLineNumber === line) { + // on same line as previous + lastGroup.push(symbol); + } else { + // on later line as previous + lastGroup = [symbol]; + groups.push(lastGroup); + } + } + + const centeredRange = this._editor.getCenteredRangeInViewport(); + const shouldRestoreCenteredRange = centeredRange && (groups.length !== this._lenses.length && this._editor.getScrollTop() !== 0); + this._editor.changeDecorations((changeAccessor) => { + this._editor.changeViewZones((accessor) => { + + let codeLensIndex = 0, groupsIndex = 0, helper = new CodeLensHelper(); + + while (groupsIndex < groups.length && codeLensIndex < this._lenses.length) { + + let symbolsLineNumber = groups[groupsIndex][0].symbol.range.startLineNumber; + let codeLensLineNumber = this._lenses[codeLensIndex].getLineNumber(); + + if (codeLensLineNumber < symbolsLineNumber) { + this._lenses[codeLensIndex].dispose(helper, accessor); + this._lenses.splice(codeLensIndex, 1); + } else if (codeLensLineNumber === symbolsLineNumber) { + this._lenses[codeLensIndex].updateCodeLensSymbols(groups[groupsIndex], helper); + groupsIndex++; + codeLensIndex++; + } else { + this._lenses.splice(codeLensIndex, 0, new CodeLens(groups[groupsIndex], this._editor, helper, accessor, this._commandService, this._messageService, () => this._detectVisibleLenses.schedule())); + codeLensIndex++; + groupsIndex++; + } + } + + // Delete extra code lenses + while (codeLensIndex < this._lenses.length) { + this._lenses[codeLensIndex].dispose(helper, accessor); + this._lenses.splice(codeLensIndex, 1); + } + + // Create extra symbols + while (groupsIndex < groups.length) { + this._lenses.push(new CodeLens(groups[groupsIndex], this._editor, helper, accessor, this._commandService, this._messageService, () => this._detectVisibleLenses.schedule())); + groupsIndex++; + } + + helper.commit(changeAccessor); + }); + }); + if (shouldRestoreCenteredRange) { + this._editor.revealRangeInCenter(centeredRange); + } + } + + private _onViewportChanged(modeId: string): void { + if (this._currentFindOccPromise) { + this._currentFindOccPromise.cancel(); + this._currentFindOccPromise = null; + } + + const model = this._editor.getModel(); + if (!model) { + return; + } + + const toResolve: ICodeLensData[][] = []; + const lenses: CodeLens[] = []; + this._lenses.forEach((lens) => { + const request = lens.computeIfNecessary(model); + if (request) { + toResolve.push(request); + lenses.push(lens); + } + }); + + if (toResolve.length === 0) { + return; + } + + const promises = toResolve.map((request, i) => { + + const resolvedSymbols = new Array(request.length); + const promises = request.map((request, i) => { + return asWinJsPromise((token) => { + return request.provider.resolveCodeLens(model, request.symbol, token); + }).then(symbol => { + resolvedSymbols[i] = symbol; + }); + }); + + return TPromise.join(promises).then(() => { + lenses[i].updateCommands(resolvedSymbols); + }); + }); + + this._currentFindOccPromise = TPromise.join(promises).then(() => { + this._currentFindOccPromise = null; + }); + } +} + +registerThemingParticipant((theme, collector) => { + let codeLensForeground = theme.getColor(editorCodeLensForeground); + if (codeLensForeground) { + collector.addRule(`.monaco-editor .codelens-decoration { color: ${codeLensForeground}; }`); + } + let activeLinkForeground = theme.getColor(editorActiveLinkForeground); + if (activeLinkForeground) { + collector.addRule(`.monaco-editor .codelens-decoration > a:hover { color: ${activeLinkForeground} !important; }`); + } +}); diff --git a/src/vs/editor/contrib/codelens/common/codelens.ts b/src/vs/editor/contrib/codelens/common/codelens.ts deleted file mode 100644 index 28424195ae2..00000000000 --- a/src/vs/editor/contrib/codelens/common/codelens.ts +++ /dev/null @@ -1,72 +0,0 @@ -/*--------------------------------------------------------------------------------------------- - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. - *--------------------------------------------------------------------------------------------*/ - -'use strict'; - -import { illegalArgument, onUnexpectedExternalError } from 'vs/base/common/errors'; -import { stableSort } from 'vs/base/common/arrays'; -import URI from 'vs/base/common/uri'; -import { TPromise } from 'vs/base/common/winjs.base'; -import { IModel } from 'vs/editor/common/editorCommon'; -import { CommonEditorRegistry } from 'vs/editor/common/editorCommonExtensions'; -import { CodeLensProviderRegistry, CodeLensProvider, ICodeLensSymbol } from 'vs/editor/common/modes'; -import { IModelService } from 'vs/editor/common/services/modelService'; -import { asWinJsPromise } from 'vs/base/common/async'; - -export interface ICodeLensData { - symbol: ICodeLensSymbol; - provider: CodeLensProvider; -} - -export function getCodeLensData(model: IModel): TPromise { - - const symbols: ICodeLensData[] = []; - const provider = CodeLensProviderRegistry.ordered(model); - - const promises = provider.map(provider => asWinJsPromise(token => provider.provideCodeLenses(model, token)).then(result => { - if (Array.isArray(result)) { - for (let symbol of result) { - symbols.push({ symbol, provider }); - } - } - }, onUnexpectedExternalError)); - - return TPromise.join(promises).then(() => { - - return stableSort(symbols, (a, b) => { - // sort by lineNumber, provider-rank, and column - if (a.symbol.range.startLineNumber < b.symbol.range.startLineNumber) { - return -1; - } else if (a.symbol.range.startLineNumber > b.symbol.range.startLineNumber) { - return 1; - } else if (provider.indexOf(a.provider) < provider.indexOf(b.provider)) { - return -1; - } else if (provider.indexOf(a.provider) > provider.indexOf(b.provider)) { - return 1; - } else if (a.symbol.range.startColumn < b.symbol.range.startColumn) { - return -1; - } else if (a.symbol.range.startColumn > b.symbol.range.startColumn) { - return 1; - } else { - return 0; - } - }); - }); -} - -CommonEditorRegistry.registerLanguageCommand('_executeCodeLensProvider', function (accessor, args) { - - const { resource } = args; - if (!(resource instanceof URI)) { - throw illegalArgument(); - } - - const model = accessor.get(IModelService).getModel(resource); - if (!model) { - throw illegalArgument(); - } - - return getCodeLensData(model); -}); diff --git a/src/vs/workbench/api/node/extHostApiCommands.ts b/src/vs/workbench/api/node/extHostApiCommands.ts index aef4d71d01f..ac762cd7e05 100644 --- a/src/vs/workbench/api/node/extHostApiCommands.ts +++ b/src/vs/workbench/api/node/extHostApiCommands.ts @@ -16,7 +16,6 @@ import { ICommandHandlerDescription } from 'vs/platform/commands/common/commands import { ExtHostCommands } from 'vs/workbench/api/node/extHostCommands'; import { IOutline } from 'vs/editor/contrib/quickOpen/common/quickOpen'; import { IWorkspaceSymbolProvider } from 'vs/workbench/parts/search/common/search'; -import { ICodeLensData } from 'vs/editor/contrib/codelens/common/codelens'; import { IEditorOptions } from 'vs/platform/editor/common/editor'; export class ExtHostApiCommands { @@ -409,12 +408,12 @@ export class ExtHostApiCommands { private _executeCodeLensProvider(resource: URI): Thenable { const args = { resource }; - return this._commands.executeCommand('_executeCodeLensProvider', args).then(value => { + return this._commands.executeCommand('_executeCodeLensProvider', args).then(value => { if (Array.isArray(value)) { return value.map(item => { return new types.CodeLens( - typeConverters.toRange(item.symbol.range), - this._commands.converter.fromInternal(item.symbol.command)); + typeConverters.toRange(item.range), + this._commands.converter.fromInternal(item.command)); }); } return undefined; diff --git a/src/vs/workbench/test/electron-browser/api/extHostLanguageFeatures.test.ts b/src/vs/workbench/test/electron-browser/api/extHostLanguageFeatures.test.ts index e34efcb9297..3cfcedbac4b 100644 --- a/src/vs/workbench/test/electron-browser/api/extHostLanguageFeatures.test.ts +++ b/src/vs/workbench/test/electron-browser/api/extHostLanguageFeatures.test.ts @@ -27,7 +27,7 @@ import { ExtHostDocuments } from 'vs/workbench/api/node/extHostDocuments'; import { ExtHostDocumentsAndEditors } from 'vs/workbench/api/node/extHostDocumentsAndEditors'; import { getDocumentSymbols } from 'vs/editor/contrib/quickOpen/common/quickOpen'; import { DocumentSymbolProviderRegistry, DocumentHighlightKind } from 'vs/editor/common/modes'; -import { getCodeLensData } from 'vs/editor/contrib/codelens/common/codelens'; +import { getCodeLensData } from 'vs/editor/contrib/codelens/browser/codelens'; import { getDefinitionsAtPosition, getImplementationsAtPosition, getTypeDefinitionsAtPosition } from 'vs/editor/contrib/goToDeclaration/browser/goToDeclaration'; import { getHover } from 'vs/editor/contrib/hover/common/hover'; import { getOccurrencesAtPosition } from 'vs/editor/contrib/wordHighlighter/common/wordHighlighter'; -- GitLab From 5fccd2b92cafdaeee8ada20cddac5fd9536229b2 Mon Sep 17 00:00:00 2001 From: isidor Date: Fri, 16 Jun 2017 16:39:05 +0200 Subject: [PATCH 0962/1347] fix issues with having multiple of the same files in different roots --- .../parts/files/browser/views/explorerView.ts | 114 +++++++++--------- .../files/browser/views/explorerViewer.ts | 17 +-- 2 files changed, 64 insertions(+), 67 deletions(-) diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index 4550bab1e12..b0b6f70f947 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -421,31 +421,28 @@ export class ExplorerView extends CollapsibleView { return; // ignore if not yet created } - let modelElement: FileStat; - let parents: FileStat[]; - let parentResource: URI; - // Add if (e.operation === FileOperation.CREATE || e.operation === FileOperation.IMPORT || e.operation === FileOperation.COPY) { const addedElement = e.target; - parentResource = URI.file(paths.dirname(addedElement.resource.fsPath)); - parents = this.model.findAll(parentResource); + const parentResource = URI.file(paths.dirname(addedElement.resource.fsPath)); + const parents = this.model.findAll(parentResource); if (parents.length) { // Add the new file to its parent (Model) - const childElement = FileStat.create(addedElement); - parents[0].removeChild(childElement); // make sure to remove any previous version of the file if any - parents[0].addChild(childElement); - - // Refresh the Parent (View) - TPromise.join(parents.map(p => this.explorerViewer.refresh(p))).then(() => { - return this.reveal(childElement, 0.5).then(() => { - - // Focus new element - this.explorerViewer.setFocus(childElement); - }); - }).done(null, errors.onUnexpectedError); + parents.forEach(p => { + const childElement = FileStat.create(addedElement); + p.removeChild(childElement); // make sure to remove any previous version of the file if any + p.addChild(childElement); + // Refresh the Parent (View) + this.explorerViewer.refresh(p).then(() => { + return this.reveal(childElement, 0.5).then(() => { + + // Focus new element + this.explorerViewer.setFocus(childElement); + }); + }).done(null, errors.onUnexpectedError); + }); } } @@ -466,43 +463,39 @@ export class ExplorerView extends CollapsibleView { // Handle Rename if (oldParentResource && newParentResource && oldParentResource.toString() === newParentResource.toString()) { - modelElement = this.model.findFirst(oldResource); - if (modelElement) { - + const modelElements = this.model.findAll(oldResource); + modelElements.forEach(modelElement => { // Rename File (Model) modelElement.rename(newElement); // Update Parent (View) - parents = this.model.findAll(modelElement.parent.resource); - if (parents.length) { - TPromise.join(parents.map(p => this.explorerViewer.refresh(p))).done(() => { - - // Select in Viewer if set - if (restoreFocus) { - this.explorerViewer.setFocus(modelElement); - } - }, errors.onUnexpectedError); - } - } + this.explorerViewer.refresh(modelElement.parent).done(() => { + + // Select in Viewer if set + if (restoreFocus) { + this.explorerViewer.setFocus(modelElement); + } + }, errors.onUnexpectedError); + }); } // Handle Move else if (oldParentResource && newParentResource) { - const oldParents = this.model.findAll(oldParentResource); const newParents = this.model.findAll(newParentResource); - modelElement = this.model.findFirst(oldResource); + const modelElements = this.model.findAll(oldResource); - if (oldParents.length && newParents.length && modelElement) { + if (newParents.length && modelElements.length) { // Move in Model - modelElement.move(newParents[0], (callback: () => void) => { - - // Update old parent - TPromise.join(oldParents.map(p => this.explorerViewer.refresh(p))).done(callback, errors.onUnexpectedError); - }, () => { - - // Update new parent - TPromise.join(newParents.map(p => this.explorerViewer.refresh(p, true))).done(() => this.explorerViewer.expand(newParents[0]), errors.onUnexpectedError); + modelElements.forEach((modelElement, index) => { + const oldParent = modelElement.parent; + modelElement.move(newParents[index], (callback: () => void) => { + // Update old parent + this.explorerViewer.refresh(oldParent).done(callback, errors.onUnexpectedError); + }, () => { + // Update new parent + this.explorerViewer.refresh(newParents[index], true).done(() => this.explorerViewer.expand(newParents[index]), errors.onUnexpectedError); + }); }); } } @@ -510,23 +503,24 @@ export class ExplorerView extends CollapsibleView { // Delete else if (e.operation === FileOperation.DELETE) { - modelElement = this.model.findFirst(e.resource); - if (modelElement && modelElement.parent) { - parents = this.model.findAll(modelElement.parent.resource); - - // Remove Element from Parent (Model) - parents[0].removeChild(modelElement); - - // Refresh Parent (View) - const restoreFocus = this.explorerViewer.isDOMFocused(); - TPromise.join(parents.map(p => this.explorerViewer.refresh(p))).done(() => { - - // Ensure viewer has keyboard focus if event originates from viewer - if (restoreFocus) { - this.explorerViewer.DOMFocus(); - } - }, errors.onUnexpectedError); - } + const modelElements = this.model.findAll(e.resource); + modelElements.forEach(element => { + if (element.parent) { + const parent = element.parent; + // Remove Element from Parent (Model) + parent.removeChild(element); + + // Refresh Parent (View) + const restoreFocus = this.explorerViewer.isDOMFocused(); + this.explorerViewer.refresh(parent).done(() => { + + // Ensure viewer has keyboard focus if event originates from viewer + if (restoreFocus) { + this.explorerViewer.DOMFocus(); + } + }, errors.onUnexpectedError); + } + }); } } diff --git a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts index 16708df7b4f..f9da4103316 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerViewer.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerViewer.ts @@ -51,14 +51,10 @@ import { IBackupFileService } from 'vs/workbench/services/backup/common/backup'; import { attachInputBoxStyler } from 'vs/platform/theme/common/styler'; import { IThemeService } from 'vs/platform/theme/common/themeService'; -// Multiple of the same folder in the explorer - id needs to get more complex, add index for the parent -// check context menu actions // special context menu actions for root -// more checks might be needed for drag n drop +// expand state in second root // step2: deleting one of the root folders -// Resolve me all the expansion state in one go // revealing an element might be tricky if it is in two workspaces, in that case just reveal the first to not break. Not a common scenario - // files.exclude, for each of the roots ask the configurations service for files.exclude export class FileDataSource implements IDataSource { @@ -75,8 +71,15 @@ export class FileDataSource implements IDataSource { return 'model'; } - const root = this.contextService.getRoot(stat.resource); - return `${root ? root.toString() : ''}:${stat.getId()}`; + // TODO@Isidor each file stat should have a reference to the root, this way you do not have to walk up the parent chain + let parent = stat.parent; + let depth = 0; + while (parent) { + parent = parent.parent; + depth++; + } + + return `${depth}:${stat.getId()}`; } public hasChildren(tree: ITree, stat: FileStat | Model): boolean { -- GitLab From e3a6a37e0f5bb2cfdd8517aab31403c388be4b60 Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 16 Jun 2017 16:45:02 +0200 Subject: [PATCH 0963/1347] debt - move codeLenseWidget into its own file --- .../codelens/browser/codelensController.ts | 367 +----------------- ...elensController.css => codelensWidget.css} | 0 .../codelens/browser/codelensWidget.ts | 339 ++++++++++++++++ 3 files changed, 355 insertions(+), 351 deletions(-) rename src/vs/editor/contrib/codelens/browser/{codelensController.css => codelensWidget.css} (100%) create mode 100644 src/vs/editor/contrib/codelens/browser/codelensWidget.ts diff --git a/src/vs/editor/contrib/codelens/browser/codelensController.ts b/src/vs/editor/contrib/codelens/browser/codelensController.ts index c43b02b73e9..94875382301 100644 --- a/src/vs/editor/contrib/codelens/browser/codelensController.ts +++ b/src/vs/editor/contrib/codelens/browser/codelensController.ts @@ -5,341 +5,19 @@ 'use strict'; -import 'vs/css!./codelensController'; import { RunOnceScheduler, asWinJsPromise } from 'vs/base/common/async'; import { onUnexpectedError } from 'vs/base/common/errors'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; -import Severity from 'vs/base/common/severity'; -import { format, escape } from 'vs/base/common/strings'; import { TPromise } from 'vs/base/common/winjs.base'; -import * as dom from 'vs/base/browser/dom'; import { ICommandService } from 'vs/platform/commands/common/commands'; import { IMessageService } from 'vs/platform/message/common/message'; -import { Range } from 'vs/editor/common/core/range'; import * as editorCommon from 'vs/editor/common/editorCommon'; -import { CodeLensProviderRegistry, ICodeLensSymbol, Command } from 'vs/editor/common/modes'; +import { CodeLensProviderRegistry, ICodeLensSymbol } from 'vs/editor/common/modes'; import * as editorBrowser from 'vs/editor/browser/editorBrowser'; import { editorContribution } from 'vs/editor/browser/editorBrowserExtensions'; import { ICodeLensData, getCodeLensData } from './codelens'; import { IConfigurationChangedEvent } from 'vs/editor/common/config/editorOptions'; -import { editorCodeLensForeground } from 'vs/editor/common/view/editorColorRegistry'; -import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; -import { editorActiveLinkForeground } from 'vs/platform/theme/common/colorRegistry'; -import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; - - -class CodeLensViewZone implements editorBrowser.IViewZone { - - public afterLineNumber: number; - public heightInLines: number; - public suppressMouseDown: boolean; - public domNode: HTMLElement; - private _lastHeight: number; - private _onHeight: Function; - - constructor(afterLineNumber: number, onHeight: Function) { - this.afterLineNumber = afterLineNumber; - this._onHeight = onHeight; - - this.heightInLines = 1; - this.suppressMouseDown = true; - this.domNode = document.createElement('div'); - } - - public setAfterLineNumber(afterLineNumber: number): void { - this.afterLineNumber = afterLineNumber; - } - - onComputedHeight(height: number): void { - if (this._lastHeight === undefined) { - this._lastHeight = height; - } else if (this._lastHeight !== height) { - this._lastHeight = height; - this._onHeight(); - } - } - -} - -class CodeLensContentWidget implements editorBrowser.IContentWidget { - - private static ID: number = 0; - - // Editor.IContentWidget.allowEditorOverflow - readonly allowEditorOverflow: boolean = false; - readonly suppressMouseDown: boolean = true; - - private _id: string; - - private _domNode: HTMLElement; - private _disposables: IDisposable[] = []; - private _symbolRange: Range; - private _widgetPosition: editorBrowser.IContentWidgetPosition; - private _editor: editorBrowser.ICodeEditor; - private _commands: { [id: string]: Command } = Object.create(null); - - public constructor( - editor: editorBrowser.ICodeEditor, - symbolRange: Range, - commandService: ICommandService, - messageService: IMessageService - ) { - - this._id = 'codeLensWidget' + (++CodeLensContentWidget.ID); - this._editor = editor; - - this.setSymbolRange(symbolRange); - - this._domNode = document.createElement('span'); - this._domNode.innerHTML = ' '; - dom.addClass(this._domNode, 'codelens-decoration'); - dom.addClass(this._domNode, 'invisible-cl'); - this._updateHeight(); - - this._disposables.push(this._editor.onDidChangeConfiguration(e => { - if (e.fontInfo) { - this._updateHeight(); - } - })); - - this._disposables.push(dom.addDisposableListener(this._domNode, 'click', e => { - let element = e.target; - if (element.tagName === 'A' && element.id) { - let command = this._commands[element.id]; - if (command) { - editor.focus(); - commandService.executeCommand(command.id, ...command.arguments).done(undefined, err => { - messageService.show(Severity.Error, err); - }); - } - } - })); - - this.updateVisibility(); - } - - public dispose(): void { - dispose(this._disposables); - this._symbolRange = null; - } - - private _updateHeight(): void { - const { fontInfo, lineHeight } = this._editor.getConfiguration(); - this._domNode.style.height = `${Math.round(lineHeight * 1.1)}px`; - this._domNode.style.lineHeight = `${lineHeight}px`; - this._domNode.style.fontSize = `${Math.round(fontInfo.fontSize * .9)}px`; - this._domNode.innerHTML = ' '; - } - - public updateVisibility(): void { - if (this.isVisible()) { - dom.removeClass(this._domNode, 'invisible-cl'); - dom.addClass(this._domNode, 'fadein'); - } - } - - public withCommands(symbols: ICodeLensSymbol[]): void { - this._commands = Object.create(null); - if (!symbols || !symbols.length) { - this._domNode.innerHTML = 'no commands'; - return; - } - - let html: string[] = []; - for (let i = 0; i < symbols.length; i++) { - let command = symbols[i].command; - let title = escape(command.title); - let part: string; - if (command.id) { - part = format('{1}', i, title); - this._commands[i] = command; - } else { - part = format('{0}', title); - } - html.push(part); - } - - this._domNode.innerHTML = html.join(' | '); - this._editor.layoutContentWidget(this); - } - - public getId(): string { - return this._id; - } - - public getDomNode(): HTMLElement { - return this._domNode; - } - - public setSymbolRange(range: Range): void { - this._symbolRange = range; - - const lineNumber = range.startLineNumber; - const column = this._editor.getModel().getLineFirstNonWhitespaceColumn(lineNumber); - this._widgetPosition = { - position: { lineNumber: lineNumber, column: column }, - preference: [editorBrowser.ContentWidgetPositionPreference.ABOVE] - }; - } - - public getPosition(): editorBrowser.IContentWidgetPosition { - return this._widgetPosition; - } - - public isVisible(): boolean { - return this._domNode.hasAttribute('monaco-visible-content-widget'); - } -} - -interface IDecorationIdCallback { - (decorationId: string): void; -} - -class CodeLensHelper { - - private _removeDecorations: string[]; - private _addDecorations: editorCommon.IModelDeltaDecoration[]; - private _addDecorationsCallbacks: IDecorationIdCallback[]; - - constructor() { - this._removeDecorations = []; - this._addDecorations = []; - this._addDecorationsCallbacks = []; - } - - public addDecoration(decoration: editorCommon.IModelDeltaDecoration, callback: IDecorationIdCallback): void { - this._addDecorations.push(decoration); - this._addDecorationsCallbacks.push(callback); - } - - public removeDecoration(decorationId: string): void { - this._removeDecorations.push(decorationId); - } - - public commit(changeAccessor: editorCommon.IModelDecorationsChangeAccessor): void { - var resultingDecorations = changeAccessor.deltaDecorations(this._removeDecorations, this._addDecorations); - for (let i = 0, len = resultingDecorations.length; i < len; i++) { - this._addDecorationsCallbacks[i](resultingDecorations[i]); - } - } -} - -class CodeLens { - - private _viewZone: CodeLensViewZone; - private _viewZoneId: number; - private _contentWidget: CodeLensContentWidget; - private _decorationIds: string[]; - private _data: ICodeLensData[]; - private _editor: editorBrowser.ICodeEditor; - - public constructor( - data: ICodeLensData[], - editor: editorBrowser.ICodeEditor, - helper: CodeLensHelper, - viewZoneChangeAccessor: editorBrowser.IViewZoneChangeAccessor, - commandService: ICommandService, messageService: IMessageService, - updateCallabck: Function - ) { - - this._editor = editor; - this._data = data; - this._decorationIds = new Array(this._data.length); - - let range: Range; - this._data.forEach((codeLensData, i) => { - - helper.addDecoration({ - range: codeLensData.symbol.range, - options: ModelDecorationOptions.EMPTY - }, id => this._decorationIds[i] = id); - - // the range contains all lenses on this line - if (!range) { - range = Range.lift(codeLensData.symbol.range); - } else { - range = Range.plusRange(range, codeLensData.symbol.range); - } - }); - - this._contentWidget = new CodeLensContentWidget(editor, range, commandService, messageService); - this._viewZone = new CodeLensViewZone(range.startLineNumber - 1, updateCallabck); - - this._viewZoneId = viewZoneChangeAccessor.addZone(this._viewZone); - this._editor.addContentWidget(this._contentWidget); - } - - public dispose(helper: CodeLensHelper, viewZoneChangeAccessor: editorBrowser.IViewZoneChangeAccessor): void { - while (this._decorationIds.length) { - helper.removeDecoration(this._decorationIds.pop()); - } - if (viewZoneChangeAccessor) { - viewZoneChangeAccessor.removeZone(this._viewZoneId); - } - this._editor.removeContentWidget(this._contentWidget); - - this._contentWidget.dispose(); - } - - public isValid(): boolean { - return this._decorationIds.some((id, i) => { - const range = this._editor.getModel().getDecorationRange(id); - const symbol = this._data[i].symbol; - return range && Range.isEmpty(symbol.range) === range.isEmpty(); - }); - } - - public updateCodeLensSymbols(data: ICodeLensData[], helper: CodeLensHelper): void { - while (this._decorationIds.length) { - helper.removeDecoration(this._decorationIds.pop()); - } - this._data = data; - this._decorationIds = new Array(this._data.length); - this._data.forEach((codeLensData, i) => { - helper.addDecoration({ - range: codeLensData.symbol.range, - options: ModelDecorationOptions.EMPTY - }, id => this._decorationIds[i] = id); - }); - } - - public computeIfNecessary(model: editorCommon.IModel): ICodeLensData[] { - this._contentWidget.updateVisibility(); // trigger the fade in - if (!this._contentWidget.isVisible()) { - return null; - } - - // Read editor current state - for (let i = 0; i < this._decorationIds.length; i++) { - this._data[i].symbol.range = model.getDecorationRange(this._decorationIds[i]); - } - return this._data; - } - - public updateCommands(symbols: ICodeLensSymbol[]): void { - this._contentWidget.withCommands(symbols); - } - - public getLineNumber(): number { - const range = this._editor.getModel().getDecorationRange(this._decorationIds[0]); - if (range) { - return range.startLineNumber; - } - return -1; - } - - public update(viewZoneChangeAccessor: editorBrowser.IViewZoneChangeAccessor): void { - if (this.isValid()) { - const range = this._editor.getModel().getDecorationRange(this._decorationIds[0]); - - this._viewZone.setAfterLineNumber(range.startLineNumber - 1); - viewZoneChangeAccessor.layoutZone(this._viewZoneId); - - this._contentWidget.setSymbolRange(range); - this._editor.layoutContentWidget(this._contentWidget); - } - } -} +import { CodeLens, CodeLensHelper } from "vs/editor/contrib/codelens/browser/codelensWidget"; @editorContribution export class CodeLensContribution implements editorCommon.IEditorContribution { @@ -369,25 +47,25 @@ export class CodeLensContribution implements editorCommon.IEditorContribution { this._currentFindCodeLensSymbolsPromise = null; this._modelChangeCounter = 0; - this._globalToDispose.push(this._editor.onDidChangeModel(() => this.onModelChange())); - this._globalToDispose.push(this._editor.onDidChangeModelLanguage(() => this.onModelChange())); + this._globalToDispose.push(this._editor.onDidChangeModel(() => this._onModelChange())); + this._globalToDispose.push(this._editor.onDidChangeModelLanguage(() => this._onModelChange())); this._globalToDispose.push(this._editor.onDidChangeConfiguration((e: IConfigurationChangedEvent) => { let prevIsEnabled = this._isEnabled; this._isEnabled = this._editor.getConfiguration().contribInfo.codeLens; if (prevIsEnabled !== this._isEnabled) { - this.onModelChange(); + this._onModelChange(); } })); - this._globalToDispose.push(CodeLensProviderRegistry.onDidChange(this.onModelChange, this)); - this.onModelChange(); + this._globalToDispose.push(CodeLensProviderRegistry.onDidChange(this._onModelChange, this)); + this._onModelChange(); } - public dispose(): void { - this.localDispose(); + dispose(): void { + this._localDispose(); this._globalToDispose = dispose(this._globalToDispose); } - private localDispose(): void { + private _localDispose(): void { if (this._currentFindCodeLensSymbolsPromise) { this._currentFindCodeLensSymbolsPromise.cancel(); this._currentFindCodeLensSymbolsPromise = null; @@ -400,13 +78,13 @@ export class CodeLensContribution implements editorCommon.IEditorContribution { this._localToDispose = dispose(this._localToDispose); } - public getId(): string { + getId(): string { return CodeLensContribution.ID; } - private onModelChange(): void { + private _onModelChange(): void { - this.localDispose(); + this._localDispose(); const model = this._editor.getModel(); if (!model) { @@ -442,12 +120,10 @@ export class CodeLensContribution implements editorCommon.IEditorContribution { const counterValue = ++this._modelChangeCounter; this._currentFindCodeLensSymbolsPromise.then((result) => { if (counterValue === this._modelChangeCounter) { // only the last one wins - this.renderCodeLensSymbols(result); + this._renderCodeLensSymbols(result); this._detectVisibleLenses.schedule(); } - }, (error) => { - onUnexpectedError(error); - }); + }, onUnexpectedError); }, 250); this._localToDispose.push(scheduler); this._localToDispose.push(this._detectVisibleLenses); @@ -512,7 +188,7 @@ export class CodeLensContribution implements editorCommon.IEditorContribution { this._lenses = []; } - private renderCodeLensSymbols(symbols: ICodeLensData[]): void { + private _renderCodeLensSymbols(symbols: ICodeLensData[]): void { if (!this._editor.getModel()) { return; } @@ -628,14 +304,3 @@ export class CodeLensContribution implements editorCommon.IEditorContribution { }); } } - -registerThemingParticipant((theme, collector) => { - let codeLensForeground = theme.getColor(editorCodeLensForeground); - if (codeLensForeground) { - collector.addRule(`.monaco-editor .codelens-decoration { color: ${codeLensForeground}; }`); - } - let activeLinkForeground = theme.getColor(editorActiveLinkForeground); - if (activeLinkForeground) { - collector.addRule(`.monaco-editor .codelens-decoration > a:hover { color: ${activeLinkForeground} !important; }`); - } -}); diff --git a/src/vs/editor/contrib/codelens/browser/codelensController.css b/src/vs/editor/contrib/codelens/browser/codelensWidget.css similarity index 100% rename from src/vs/editor/contrib/codelens/browser/codelensController.css rename to src/vs/editor/contrib/codelens/browser/codelensWidget.css diff --git a/src/vs/editor/contrib/codelens/browser/codelensWidget.ts b/src/vs/editor/contrib/codelens/browser/codelensWidget.ts new file mode 100644 index 00000000000..d0c45ac46f3 --- /dev/null +++ b/src/vs/editor/contrib/codelens/browser/codelensWidget.ts @@ -0,0 +1,339 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +'use strict'; + +import 'vs/css!./codelensController'; +import { IDisposable, dispose } from 'vs/base/common/lifecycle'; +import Severity from 'vs/base/common/severity'; +import { format, escape } from 'vs/base/common/strings'; +import * as dom from 'vs/base/browser/dom'; +import { ICommandService } from 'vs/platform/commands/common/commands'; +import { IMessageService } from 'vs/platform/message/common/message'; +import { Range } from 'vs/editor/common/core/range'; +import * as editorCommon from 'vs/editor/common/editorCommon'; +import { ICodeLensSymbol, Command } from 'vs/editor/common/modes'; +import * as editorBrowser from 'vs/editor/browser/editorBrowser'; +import { ICodeLensData } from './codelens'; +import { ModelDecorationOptions } from 'vs/editor/common/model/textModelWithDecorations'; +import { editorCodeLensForeground } from 'vs/editor/common/view/editorColorRegistry'; +import { registerThemingParticipant } from 'vs/platform/theme/common/themeService'; +import { editorActiveLinkForeground } from 'vs/platform/theme/common/colorRegistry'; + +class CodeLensViewZone implements editorBrowser.IViewZone { + + readonly heightInLines: number; + readonly suppressMouseDown: boolean; + readonly domNode: HTMLElement; + + afterLineNumber: number; + + private _lastHeight: number; + private _onHeight: Function; + + constructor(afterLineNumber: number, onHeight: Function) { + this.afterLineNumber = afterLineNumber; + this._onHeight = onHeight; + + this.heightInLines = 1; + this.suppressMouseDown = true; + this.domNode = document.createElement('div'); + } + + onComputedHeight(height: number): void { + if (this._lastHeight === undefined) { + this._lastHeight = height; + } else if (this._lastHeight !== height) { + this._lastHeight = height; + this._onHeight(); + } + } +} + +class CodeLensContentWidget implements editorBrowser.IContentWidget { + + private static _idPool: number = 0; + + // Editor.IContentWidget.allowEditorOverflow + readonly allowEditorOverflow: boolean = false; + readonly suppressMouseDown: boolean = true; + + private readonly _id: string; + private readonly _domNode: HTMLElement; + private readonly _disposables: IDisposable[] = []; + private readonly _editor: editorBrowser.ICodeEditor; + + private _symbolRange: Range; + private _widgetPosition: editorBrowser.IContentWidgetPosition; + private _commands: { [id: string]: Command } = Object.create(null); + + constructor( + editor: editorBrowser.ICodeEditor, + symbolRange: Range, + commandService: ICommandService, + messageService: IMessageService + ) { + + this._id = 'codeLensWidget' + (++CodeLensContentWidget._idPool); + this._editor = editor; + + this.setSymbolRange(symbolRange); + + this._domNode = document.createElement('span'); + this._domNode.innerHTML = ' '; + dom.addClass(this._domNode, 'codelens-decoration'); + dom.addClass(this._domNode, 'invisible-cl'); + this._updateHeight(); + + this._disposables.push(this._editor.onDidChangeConfiguration(e => e.fontInfo && this._updateHeight())); + + this._disposables.push(dom.addDisposableListener(this._domNode, 'click', e => { + let element = e.target; + if (element.tagName === 'A' && element.id) { + let command = this._commands[element.id]; + if (command) { + editor.focus(); + commandService.executeCommand(command.id, ...command.arguments).done(undefined, err => { + messageService.show(Severity.Error, err); + }); + } + } + })); + + this.updateVisibility(); + } + + dispose(): void { + dispose(this._disposables); + this._symbolRange = null; + } + + private _updateHeight(): void { + const { fontInfo, lineHeight } = this._editor.getConfiguration(); + this._domNode.style.height = `${Math.round(lineHeight * 1.1)}px`; + this._domNode.style.lineHeight = `${lineHeight}px`; + this._domNode.style.fontSize = `${Math.round(fontInfo.fontSize * .9)}px`; + this._domNode.innerHTML = ' '; + } + + updateVisibility(): void { + if (this.isVisible()) { + dom.removeClass(this._domNode, 'invisible-cl'); + dom.addClass(this._domNode, 'fadein'); + } + } + + withCommands(symbols: ICodeLensSymbol[]): void { + this._commands = Object.create(null); + if (!symbols || !symbols.length) { + this._domNode.innerHTML = 'no commands'; + return; + } + + let html: string[] = []; + for (let i = 0; i < symbols.length; i++) { + let command = symbols[i].command; + let title = escape(command.title); + let part: string; + if (command.id) { + part = format('{1}', i, title); + this._commands[i] = command; + } else { + part = format('{0}', title); + } + html.push(part); + } + + this._domNode.innerHTML = html.join(' | '); + this._editor.layoutContentWidget(this); + } + + getId(): string { + return this._id; + } + + getDomNode(): HTMLElement { + return this._domNode; + } + + setSymbolRange(range: Range): void { + this._symbolRange = range; + + const lineNumber = range.startLineNumber; + const column = this._editor.getModel().getLineFirstNonWhitespaceColumn(lineNumber); + this._widgetPosition = { + position: { lineNumber: lineNumber, column: column }, + preference: [editorBrowser.ContentWidgetPositionPreference.ABOVE] + }; + } + + getPosition(): editorBrowser.IContentWidgetPosition { + return this._widgetPosition; + } + + isVisible(): boolean { + return this._domNode.hasAttribute('monaco-visible-content-widget'); + } +} + +export interface IDecorationIdCallback { + (decorationId: string): void; +} + +export class CodeLensHelper { + + private _removeDecorations: string[]; + private _addDecorations: editorCommon.IModelDeltaDecoration[]; + private _addDecorationsCallbacks: IDecorationIdCallback[]; + + constructor() { + this._removeDecorations = []; + this._addDecorations = []; + this._addDecorationsCallbacks = []; + } + + addDecoration(decoration: editorCommon.IModelDeltaDecoration, callback: IDecorationIdCallback): void { + this._addDecorations.push(decoration); + this._addDecorationsCallbacks.push(callback); + } + + removeDecoration(decorationId: string): void { + this._removeDecorations.push(decorationId); + } + + commit(changeAccessor: editorCommon.IModelDecorationsChangeAccessor): void { + var resultingDecorations = changeAccessor.deltaDecorations(this._removeDecorations, this._addDecorations); + for (let i = 0, len = resultingDecorations.length; i < len; i++) { + this._addDecorationsCallbacks[i](resultingDecorations[i]); + } + } +} + +export class CodeLens { + + private readonly _editor: editorBrowser.ICodeEditor; + private readonly _viewZone: CodeLensViewZone; + private readonly _viewZoneId: number; + private readonly _contentWidget: CodeLensContentWidget; + private _decorationIds: string[]; + private _data: ICodeLensData[]; + + constructor( + data: ICodeLensData[], + editor: editorBrowser.ICodeEditor, + helper: CodeLensHelper, + viewZoneChangeAccessor: editorBrowser.IViewZoneChangeAccessor, + commandService: ICommandService, messageService: IMessageService, + updateCallabck: Function + ) { + this._editor = editor; + this._data = data; + this._decorationIds = new Array(this._data.length); + + let range: Range; + this._data.forEach((codeLensData, i) => { + + helper.addDecoration({ + range: codeLensData.symbol.range, + options: ModelDecorationOptions.EMPTY + }, id => this._decorationIds[i] = id); + + // the range contains all lenses on this line + if (!range) { + range = Range.lift(codeLensData.symbol.range); + } else { + range = Range.plusRange(range, codeLensData.symbol.range); + } + }); + + this._contentWidget = new CodeLensContentWidget(editor, range, commandService, messageService); + this._viewZone = new CodeLensViewZone(range.startLineNumber - 1, updateCallabck); + + this._viewZoneId = viewZoneChangeAccessor.addZone(this._viewZone); + this._editor.addContentWidget(this._contentWidget); + } + + dispose(helper: CodeLensHelper, viewZoneChangeAccessor: editorBrowser.IViewZoneChangeAccessor): void { + while (this._decorationIds.length) { + helper.removeDecoration(this._decorationIds.pop()); + } + if (viewZoneChangeAccessor) { + viewZoneChangeAccessor.removeZone(this._viewZoneId); + } + this._editor.removeContentWidget(this._contentWidget); + + this._contentWidget.dispose(); + } + + isValid(): boolean { + return this._decorationIds.some((id, i) => { + const range = this._editor.getModel().getDecorationRange(id); + const symbol = this._data[i].symbol; + return range && Range.isEmpty(symbol.range) === range.isEmpty(); + }); + } + + updateCodeLensSymbols(data: ICodeLensData[], helper: CodeLensHelper): void { + while (this._decorationIds.length) { + helper.removeDecoration(this._decorationIds.pop()); + } + this._data = data; + this._decorationIds = new Array(this._data.length); + this._data.forEach((codeLensData, i) => { + helper.addDecoration({ + range: codeLensData.symbol.range, + options: ModelDecorationOptions.EMPTY + }, id => this._decorationIds[i] = id); + }); + } + + computeIfNecessary(model: editorCommon.IModel): ICodeLensData[] { + this._contentWidget.updateVisibility(); // trigger the fade in + if (!this._contentWidget.isVisible()) { + return null; + } + + // Read editor current state + for (let i = 0; i < this._decorationIds.length; i++) { + this._data[i].symbol.range = model.getDecorationRange(this._decorationIds[i]); + } + return this._data; + } + + updateCommands(symbols: ICodeLensSymbol[]): void { + this._contentWidget.withCommands(symbols); + } + + getLineNumber(): number { + const range = this._editor.getModel().getDecorationRange(this._decorationIds[0]); + if (range) { + return range.startLineNumber; + } + return -1; + } + + update(viewZoneChangeAccessor: editorBrowser.IViewZoneChangeAccessor): void { + if (this.isValid()) { + const range = this._editor.getModel().getDecorationRange(this._decorationIds[0]); + + this._viewZone.afterLineNumber = range.startLineNumber - 1; + viewZoneChangeAccessor.layoutZone(this._viewZoneId); + + this._contentWidget.setSymbolRange(range); + this._editor.layoutContentWidget(this._contentWidget); + } + } +} + +registerThemingParticipant((theme, collector) => { + let codeLensForeground = theme.getColor(editorCodeLensForeground); + if (codeLensForeground) { + collector.addRule(`.monaco-editor .codelens-decoration { color: ${codeLensForeground}; }`); + } + let activeLinkForeground = theme.getColor(editorActiveLinkForeground); + if (activeLinkForeground) { + collector.addRule(`.monaco-editor .codelens-decoration > a:hover { color: ${activeLinkForeground} !important; }`); + } +}); -- GitLab From e86733e2a0a2a48f68289ce1c59c7bf3b855bc1a Mon Sep 17 00:00:00 2001 From: Michel Kaporin Date: Fri, 16 Jun 2017 17:12:49 +0200 Subject: [PATCH 0964/1347] Added smoke test environment configuration for Linux. --- build/tfs/linux/smoketest.sh | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/build/tfs/linux/smoketest.sh b/build/tfs/linux/smoketest.sh index 54f18db1774..f9848f6b1d3 100644 --- a/build/tfs/linux/smoketest.sh +++ b/build/tfs/linux/smoketest.sh @@ -25,6 +25,13 @@ step "Install distro dependencies" \ step "Build minified" \ npm run gulp -- --max_old_space_size=4096 "vscode-linux-$ARCH-min" +step "Configure environment" \ + id -u testuser &>/dev/null || (useradd -m testuser; echo -e "testpassword\ntestpassword" | passwd testuser &>/dev/null) + su testuser + cd $BUILD_REPOSITORY_LOCALPATH + git config --global user.name "Michel Kaporin" + git config --global user.email "monacotools@microsoft.com" + step "Run smoke test" \ pushd test/smoke npm install -- GitLab From 748ceac184c45cd1297ccdd5021c0627575c8738 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 16 Jun 2017 13:05:38 +0200 Subject: [PATCH 0965/1347] Add tslint rules for vs/base/test/common and vs/base/test/browser --- .../quickopen}/test/browser/quickopen.test.ts | 0 tslint.json | 22 +++++++++++++++++++ 2 files changed, 22 insertions(+) rename src/vs/base/{ => parts/quickopen}/test/browser/quickopen.test.ts (100%) diff --git a/src/vs/base/test/browser/quickopen.test.ts b/src/vs/base/parts/quickopen/test/browser/quickopen.test.ts similarity index 100% rename from src/vs/base/test/browser/quickopen.test.ts rename to src/vs/base/parts/quickopen/test/browser/quickopen.test.ts diff --git a/tslint.json b/tslint.json index 3cb9ec3a3e3..58f72c32965 100644 --- a/tslint.json +++ b/tslint.json @@ -57,6 +57,16 @@ "**/vs/base/common/**" ] }, + { + // vs/base/test/common contains tests for vs/base/common + "target": "**/vs/base/test/common/**", + "restrictions": [ + "assert", + "vs/nls", + "**/vs/base/common/**", + "**/vs/base/test/common/**" + ] + }, { // vs/base/browser can only depend on vs/base/common "target": "**/vs/base/browser/**", @@ -67,6 +77,18 @@ "**/vs/base/browser/**" ] }, + { + // vs/base/test/browser contains tests for vs/base/browser + "target": "**/vs/base/test/browser/**", + "restrictions": [ + "assert", + "vs/nls", + "**/vs/base/common/**", + "**/vs/base/test/common/**", + "**/vs/base/browser/**", + "**/vs/base/test/browser/**" + ] + }, { "target": "**/vs/editor/contrib/**", "restrictions": [ -- GitLab From 494b7b7d0124a75cd0415cde1681e34617694f13 Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 16 Jun 2017 16:06:27 +0200 Subject: [PATCH 0966/1347] Bring "hidden" code out in the open --- src/vs/base/common/errors.ts | 53 +++++++++++++++++++++++++++++- src/vs/base/common/winjs.base.d.ts | 17 ++++++++++ src/vs/base/common/winjs.base.js | 53 ++---------------------------- 3 files changed, 71 insertions(+), 52 deletions(-) diff --git a/src/vs/base/common/errors.ts b/src/vs/base/common/errors.ts index 7367358de17..26d3df040c9 100644 --- a/src/vs/base/common/errors.ts +++ b/src/vs/base/common/errors.ts @@ -8,7 +8,58 @@ import platform = require('vs/base/common/platform'); import types = require('vs/base/common/types'); import { IAction } from 'vs/base/common/actions'; import Severity from 'vs/base/common/severity'; -import { TPromise } from 'vs/base/common/winjs.base'; +import { TPromise, IPromiseError, IPromiseErrorDetail } from 'vs/base/common/winjs.base'; + +// ------ BEGIN Hook up error listeners to winjs promises + +let outstandingPromiseErrors: { [id: string]: IPromiseErrorDetail; } = {}; +function promiseErrorHandler(e: IPromiseError): void { + + // + // e.detail looks like: { exception, error, promise, handler, id, parent } + // + var details = e.detail; + var id = details.id; + + // If the error has a parent promise then this is not the origination of the + // error so we check if it has a handler, and if so we mark that the error + // was handled by removing it from outstandingPromiseErrors + // + if (details.parent) { + if (details.handler && outstandingPromiseErrors) { + delete outstandingPromiseErrors[id]; + } + return; + } + + // Indicate that this error was originated and needs to be handled + outstandingPromiseErrors[id] = details; + + // The first time the queue fills up this iteration, schedule a timeout to + // check if any errors are still unhandled. + if (Object.keys(outstandingPromiseErrors).length === 1) { + setTimeout(function () { + var errors = outstandingPromiseErrors; + outstandingPromiseErrors = {}; + Object.keys(errors).forEach(function (errorId) { + var error = errors[errorId]; + if (error.exception) { + onUnexpectedError(error.exception); + } else if (error.error) { + onUnexpectedError(error.error); + } + console.log('WARNING: Promise with no error callback:' + error.id); + console.log(error); + if (error.exception) { + console.log(error.exception.stack); + } + }); + }, 0); + } +} +TPromise.addEventListener('error', promiseErrorHandler); + +// ------ END Hook up error listeners to winjs promises export interface ErrorListenerCallback { (error: any): void; diff --git a/src/vs/base/common/winjs.base.d.ts b/src/vs/base/common/winjs.base.d.ts index ea35630cf37..8e7a1afe3a9 100644 --- a/src/vs/base/common/winjs.base.d.ts +++ b/src/vs/base/common/winjs.base.d.ts @@ -55,6 +55,18 @@ export interface TProgressCallback { (progress: T): void; } +interface IPromiseErrorDetail { + parent: TPromise; + error: any; + id: number; + handler: Function; + exception: Error; +} + +interface IPromiseError { + detail: IPromiseErrorDetail; +} + /** * A Promise implementation that supports progress and cancelation. */ @@ -95,6 +107,11 @@ export declare class TPromise { public static wrap(value: ValueType): TPromise; public static wrapError(error: any): TPromise; + + /** + * @internal + */ + public static addEventListener(event: 'error', promiseErrorHandler: (e: IPromiseError) => void); } // --- Generic promise with generic progress value diff --git a/src/vs/base/common/winjs.base.js b/src/vs/base/common/winjs.base.js index d8e7516a0d9..aea7370ed16 100644 --- a/src/vs/base/common/winjs.base.js +++ b/src/vs/base/common/winjs.base.js @@ -3,60 +3,11 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ -define(['./winjs.base.raw', 'vs/base/common/errors'], function (winjs, __Errors__) { +define(['./winjs.base.raw'], function (winjs) { 'use strict'; - - var outstandingPromiseErrors = {}; - function promiseErrorHandler(e) { - - // - // e.detail looks like: { exception, error, promise, handler, id, parent } - // - var details = e.detail; - var id = details.id; - - // If the error has a parent promise then this is not the origination of the - // error so we check if it has a handler, and if so we mark that the error - // was handled by removing it from outstandingPromiseErrors - // - if (details.parent) { - if (details.handler && outstandingPromiseErrors) { - delete outstandingPromiseErrors[id]; - } - return; - } - - // Indicate that this error was originated and needs to be handled - outstandingPromiseErrors[id] = details; - - // The first time the queue fills up this iteration, schedule a timeout to - // check if any errors are still unhandled. - if (Object.keys(outstandingPromiseErrors).length === 1) { - setTimeout(function () { - var errors = outstandingPromiseErrors; - outstandingPromiseErrors = {}; - Object.keys(errors).forEach(function (errorId) { - var error = errors[errorId]; - if(error.exception) { - __Errors__.onUnexpectedError(error.exception); - } else if(error.error) { - __Errors__.onUnexpectedError(error.error); - } - console.log("WARNING: Promise with no error callback:" + error.id); - console.log(error); - if(error.exception) { - console.log(error.exception.stack); - } - }); - }, 0); - } - } - - winjs.Promise.addEventListener("error", promiseErrorHandler); - return { Promise: winjs.Promise, TPromise: winjs.Promise, PPromise: winjs.Promise }; -}); \ No newline at end of file +}); -- GitLab From 3d2eec85d61880c2ae53f872319484cb9a3ac83c Mon Sep 17 00:00:00 2001 From: Alex Dima Date: Fri, 16 Jun 2017 18:04:37 +0200 Subject: [PATCH 0967/1347] Enforce more dependency rules via TS Lint --- src/vs/editor/{browser => }/editor.all.ts | 0 src/vs/editor/editor.main.ts | 2 +- .../electron-browser/workbench.main.ts | 2 +- tslint.json | 74 +++++++++++++++++++ 4 files changed, 76 insertions(+), 2 deletions(-) rename src/vs/editor/{browser => }/editor.all.ts (100%) diff --git a/src/vs/editor/browser/editor.all.ts b/src/vs/editor/editor.all.ts similarity index 100% rename from src/vs/editor/browser/editor.all.ts rename to src/vs/editor/editor.all.ts diff --git a/src/vs/editor/editor.main.ts b/src/vs/editor/editor.main.ts index 012e073ff51..d8770ae5ade 100644 --- a/src/vs/editor/editor.main.ts +++ b/src/vs/editor/editor.main.ts @@ -5,7 +5,7 @@ 'use strict'; -import 'vs/editor/browser/editor.all'; +import 'vs/editor/editor.all'; import 'vs/editor/contrib/quickOpen/browser/quickOutline'; import 'vs/editor/contrib/quickOpen/browser/gotoLine'; import 'vs/editor/contrib/quickOpen/browser/quickCommand'; diff --git a/src/vs/workbench/electron-browser/workbench.main.ts b/src/vs/workbench/electron-browser/workbench.main.ts index 7a9035a8e92..5dfb796f542 100644 --- a/src/vs/workbench/electron-browser/workbench.main.ts +++ b/src/vs/workbench/electron-browser/workbench.main.ts @@ -10,7 +10,7 @@ import 'vs/base/common/strings'; import 'vs/base/common/errors'; // Editor -import 'vs/editor/browser/editor.all'; +import 'vs/editor/editor.all'; // Menus/Actions import 'vs/platform/actions/electron-browser/menusExtensionPoint'; diff --git a/tslint.json b/tslint.json index 58f72c32965..8104bad6b07 100644 --- a/tslint.json +++ b/tslint.json @@ -89,6 +89,80 @@ "**/vs/base/test/browser/**" ] }, + { + "target": "**/vs/base/parts/quickopen/common/**", + "restrictions": [ + "vs/nls", + "**/vs/base/common/**" + ] + }, + { + "target": "**/vs/base/parts/quickopen/browser/**", + "restrictions": [ + "vs/nls", + "vs/css!./**/*", + "**/vs/base/common/**", + "**/vs/base/browser/**", + "**/vs/base/parts/tree/browser/**", + "**/vs/base/parts/quickopen/common/**", + "**/vs/base/parts/quickopen/browser/**" + ] + }, + { + "target": "**/vs/base/parts/tree/browser/**", + "restrictions": [ + "vs/nls", + "vs/css!./**/*", + "**/vs/base/common/**", + "**/vs/base/browser/**", + "**/vs/base/parts/tree/browser/**" + ] + }, + // { + // "target": "**/vs/platform/test/common/**", + // "restrictions": [ + // "assert", + // "**/vs/platform/platform", + // "**/vs/base/common/**" + // ] + // }, + // { + // "target": "**/vs/platform/*/common/**", + // "restrictions": [ + // "vs/nls", + // "**/vs/base/common/**", + // "**/vs/platform/*/common/**", + // "**/vs/platform/platform", + // "**/vs/base/parts/ipc/common/**", + // "**/vs/base/parts/quickopen/common/**" + // ] + // }, + { + "target": "**/vs/editor/common/**", + "restrictions": [ + "vs/nls", + "**/vs/base/common/**", + "**/vs/base/worker/**", + "**/vs/platform/*/common/**", + "**/vs/platform/platform", + "**/vs/editor/common/**" + ] + }, + { + "target": "**/vs/editor/browser/**", + "restrictions": [ + "vs/nls", + "vs/css!./**/*", + "**/vs/base/common/**", + "**/vs/base/browser/**", + "**/vs/platform/*/common/**", + "**/vs/platform/*/browser/**", + "**/vs/platform/platform", + "**/vs/editor/common/**", + "**/vs/editor/browser/**", + "vs/editor/contrib/diffNavigator/common/diffNavigator" // TODO@Alex + ] + }, { "target": "**/vs/editor/contrib/**", "restrictions": [ -- GitLab From 4685dae198757d64ef57653d460af46c48729804 Mon Sep 17 00:00:00 2001 From: Pete Chown Date: Fri, 16 Jun 2017 18:01:56 +0100 Subject: [PATCH 0968/1347] Don't split words at U+2019, the right single quotation mark. This stops the editor splitting words at apostrophes, when editing plain text. --- src/vs/editor/common/config/editorOptions.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/editor/common/config/editorOptions.ts b/src/vs/editor/common/config/editorOptions.ts index 9835b48bc22..b610d4c1b5b 100644 --- a/src/vs/editor/common/config/editorOptions.ts +++ b/src/vs/editor/common/config/editorOptions.ts @@ -2086,7 +2086,7 @@ export const EDITOR_DEFAULTS: IValidatedEditorOptions = { wordWrapMinified: true, wrappingIndent: WrappingIndent.Same, wordWrapBreakBeforeCharacters: '([{‘“〈《「『ã€ã€”([{「£¥$£¥++', - wordWrapBreakAfterCharacters: ' \t})]?|&,;¢°′″‰℃ã€ã€‚。、¢,.:;?ï¼ï¼…・・ã‚ゞヽヾーァィゥェォッャュョヮヵヶããƒã…ã‡ã‰ã£ã‚ƒã‚…ょゎゕゖㇰㇱㇲㇳㇴㇵㇶㇷㇸㇹㇺㇻㇼㇽㇾㇿ々〻ァィゥェォャュョッー’â€ã€‰ã€‹ã€ã€ã€‘〕)]ï½ï½£', + wordWrapBreakAfterCharacters: ' \t})]?|&,;¢°′″‰℃ã€ã€‚。、¢,.:;?ï¼ï¼…・・ã‚ゞヽヾーァィゥェォッャュョヮヵヶããƒã…ã‡ã‰ã£ã‚ƒã‚…ょゎゕゖㇰㇱㇲㇳㇴㇵㇶㇷㇸㇹㇺㇻㇼㇽㇾㇿ々〻ァィゥェォャュョッーâ€ã€‰ã€‹ã€ã€ã€‘〕)]ï½ï½£', wordWrapBreakObtrusiveCharacters: '.', autoClosingBrackets: true, dragAndDrop: true, -- GitLab From 57b318b14ce43ee49304ee6246b62c66942bd57e Mon Sep 17 00:00:00 2001 From: Benjamin Pasero Date: Fri, 16 Jun 2017 19:07:10 +0200 Subject: [PATCH 0969/1347] fix build --- src/vs/editor/contrib/codelens/browser/codelensWidget.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/editor/contrib/codelens/browser/codelensWidget.ts b/src/vs/editor/contrib/codelens/browser/codelensWidget.ts index d0c45ac46f3..ac7b103cd55 100644 --- a/src/vs/editor/contrib/codelens/browser/codelensWidget.ts +++ b/src/vs/editor/contrib/codelens/browser/codelensWidget.ts @@ -5,7 +5,7 @@ 'use strict'; -import 'vs/css!./codelensController'; +import 'vs/css!./codelensWidget'; import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import Severity from 'vs/base/common/severity'; import { format, escape } from 'vs/base/common/strings'; -- GitLab From d03641774579816c6d703227db24a9b20afa6f5a Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Fri, 16 Jun 2017 19:10:05 +0200 Subject: [PATCH 0970/1347] :lipstick: no tricks, implement a stable sort --- src/vs/base/common/arrays.ts | 53 ++++++++++++------- src/vs/base/test/common/arrays.test.ts | 50 ++++++++++++++++- .../contrib/codelens/browser/codelens.ts | 4 +- .../workbench/api/node/extHostDiagnostics.ts | 4 +- 4 files changed, 87 insertions(+), 24 deletions(-) diff --git a/src/vs/base/common/arrays.ts b/src/vs/base/common/arrays.ts index 72416376659..791dd071850 100644 --- a/src/vs/base/common/arrays.ts +++ b/src/vs/base/common/arrays.ts @@ -67,30 +67,45 @@ export function findFirst(array: T[], p: (x: T) => boolean): number { } /** - * Like `Array#sort` but always stable. Comes at a cost: iterates 2n-times, - * creates n-objects in addition to sorting (log(n)) + * Like `Array#sort` but always stable. Usually runs a little slower `than Array#sort` + * so only use this when actually needing stable sort. */ -export function stableSort(data: T[], compare: (a: T, b: T) => number): T[] { - - let data2: { idx: number; e: T }[] = data; +export function mergeSort(data: T[], compare: (a: T, b: T) => number): T[] { + _divideAndMerge(data, compare); + return data; +} - for (let idx = 0; idx < data2.length; idx++) { - data2[idx] = { idx, e: data[idx] }; +function _divideAndMerge(data: T[], compare: (a: T, b: T) => number): void { + if (data.length === 1) { + // sorted + return; } - - data2.sort((a, b) => { - let ret = compare(a.e, b.e); - if (ret === 0) { - ret = a.idx - b.idx; + const p = (data.length / 2) | 0; + const left = data.slice(0, p); + const right = data.slice(p); + + _divideAndMerge(left, compare); + _divideAndMerge(right, compare); + + let leftIdx = 0; + let rightIdx = 0; + let i = 0; + while (leftIdx < left.length && rightIdx < right.length) { + let ret = compare(left[leftIdx], right[rightIdx]); + if (ret <= 0) { + // smaller_equal -> take left to preserve order + data[i++] = left[leftIdx++]; + } else { + // greater -> take right + data[i++] = right[rightIdx++]; } - return ret; - }); - - for (let idx = 0; idx < data2.length; idx++) { - data[idx] = data2[idx].e; } - - return data; + while (leftIdx < left.length) { + data[i++] = left[leftIdx++]; + } + while (rightIdx < right.length) { + data[i++] = right[rightIdx++]; + } } export function groupBy(data: T[], compare: (a: T, b: T) => number): T[][] { diff --git a/src/vs/base/test/common/arrays.test.ts b/src/vs/base/test/common/arrays.test.ts index 5037261bc73..4d1e67c20fc 100644 --- a/src/vs/base/test/common/arrays.test.ts +++ b/src/vs/base/test/common/arrays.test.ts @@ -37,7 +37,7 @@ suite('Arrays', () => { let counter = 0; let data = arrays.fill(10000, () => ({ n: 1, m: counter++ })); - arrays.stableSort(data, (a, b) => a.n - b.n); + arrays.mergeSort(data, (a, b) => a.n - b.n); let lastM = -1; for (const element of data) { @@ -46,6 +46,54 @@ suite('Arrays', () => { } }); + test('mergeSort', function () { + let data = arrays.mergeSort([6, 5, 3, 1, 8, 7, 2, 4], (a, b) => a - b); + assert.deepEqual(data, [1, 2, 3, 4, 5, 6, 7, 8]); + }); + + test('mergeSort, is stable', function () { + + let numbers = arrays.mergeSort([33, 22, 11, 4, 99, 1], (a, b) => 0); + assert.deepEqual(numbers, [33, 22, 11, 4, 99, 1]); + }); + + test('mergeSort, many random numbers', function () { + + function compare(a: number, b: number) { + if (a < b) { + return -1; + } else if (a > b) { + return 1; + } else { + return 0; + } + } + + function assertSorted(array: number[]) { + let last = array[0]; + for (let i = 1; i < array.length; i++) { + let n = array[i]; + if (last > n) { + assert.fail(array.slice(i - 10, i + 10)); + } + } + } + const MAX = 101; + const data: number[][] = []; + for (let i = 1; i < MAX; i++) { + let array: number[] = []; + for (let j = 0; j < 10 + i; j++) { + array.push(Math.random() * 10e8 | 0); + } + data.push(array); + } + + for (const array of data) { + arrays.mergeSort(array, compare); + assertSorted(array); + } + }); + test('delta', function () { function compare(a: number, b: number): number { return a - b; diff --git a/src/vs/editor/contrib/codelens/browser/codelens.ts b/src/vs/editor/contrib/codelens/browser/codelens.ts index 2cbda09d66f..0c7d563cc55 100644 --- a/src/vs/editor/contrib/codelens/browser/codelens.ts +++ b/src/vs/editor/contrib/codelens/browser/codelens.ts @@ -6,7 +6,7 @@ 'use strict'; import { illegalArgument, onUnexpectedExternalError } from 'vs/base/common/errors'; -import { stableSort } from 'vs/base/common/arrays'; +import { mergeSort } from 'vs/base/common/arrays'; import URI from 'vs/base/common/uri'; import { TPromise } from 'vs/base/common/winjs.base'; import { IModel } from 'vs/editor/common/editorCommon'; @@ -35,7 +35,7 @@ export function getCodeLensData(model: IModel): TPromise { return TPromise.join(promises).then(() => { - return stableSort(symbols, (a, b) => { + return mergeSort(symbols, (a, b) => { // sort by lineNumber, provider-rank, and column if (a.symbol.range.startLineNumber < b.symbol.range.startLineNumber) { return -1; diff --git a/src/vs/workbench/api/node/extHostDiagnostics.ts b/src/vs/workbench/api/node/extHostDiagnostics.ts index 7b720e5eec1..eeb41c0b0e9 100644 --- a/src/vs/workbench/api/node/extHostDiagnostics.ts +++ b/src/vs/workbench/api/node/extHostDiagnostics.ts @@ -12,7 +12,7 @@ import Severity from 'vs/base/common/severity'; import * as vscode from 'vscode'; import { MainContext, MainThreadDiagnosticsShape, ExtHostDiagnosticsShape } from './extHost.protocol'; import { DiagnosticSeverity } from './extHostTypes'; -import { stableSort } from 'vs/base/common/arrays'; +import { mergeSort } from 'vs/base/common/arrays'; export class DiagnosticCollection implements vscode.DiagnosticCollection { @@ -76,7 +76,7 @@ export class DiagnosticCollection implements vscode.DiagnosticCollection { let lastUri: vscode.Uri; // ensure stable-sort - stableSort(first, DiagnosticCollection._compareIndexedTuplesByUri); + mergeSort(first, DiagnosticCollection._compareIndexedTuplesByUri); for (const tuple of first) { const [uri, diagnostics] = tuple; -- GitLab From 19ae0932c45b1096443a8c1335cf1e02eb99e16d Mon Sep 17 00:00:00 2001 From: rebornix Date: Thu, 8 Jun 2017 17:53:07 -0700 Subject: [PATCH 0971/1347] AutoIndent: Enrich TypeScript and HTML rules. --- extensions/html/client/src/htmlMain.ts | 4 ++++ extensions/typescript/src/typescriptMain.ts | 5 +++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/extensions/html/client/src/htmlMain.ts b/extensions/html/client/src/htmlMain.ts index cd12405a71f..7f4c9fe3440 100644 --- a/extensions/html/client/src/htmlMain.ts +++ b/extensions/html/client/src/htmlMain.ts @@ -78,6 +78,10 @@ export function activate(context: ExtensionContext) { }); languages.setLanguageConfiguration('html', { + indentationRules: { + increaseIndentPattern: /<(?!\?|(?:area|base|br|col|frame|hr|html|img|input|link|meta|param)\b|[^>]*\/>)([-_\.A-Za-z0-9]+)(?=\s|>)\b[^>]*>(?!.*<\/\1>)|)|\{[^}"']*$/, + decreaseIndentPattern: /^\s*(<\/(?!html)[-_\.A-Za-z0-9]+\b[^>]*>|-->|\})/ + }, wordPattern: /(-?\d*\.\d\w*)|([^\`\~\!\@\$\^\&\*\(\)\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\s]+)/g, onEnterRules: [ { diff --git a/extensions/typescript/src/typescriptMain.ts b/extensions/typescript/src/typescriptMain.ts index 085e48bb40b..00db96b6663 100644 --- a/extensions/typescript/src/typescriptMain.ts +++ b/extensions/typescript/src/typescriptMain.ts @@ -283,9 +283,10 @@ class LanguageProvider { this.disposables.push(languages.setLanguageConfiguration(modeId, { indentationRules: { // ^(.*\*/)?\s*\}.*$ - decreaseIndentPattern: /^(.*\*\/)?\s*\}.*$/, + decreaseIndentPattern: /^(.*\*\/)?\s*[\}|\]|\)].*$/, // ^.*\{[^}"']*$ - increaseIndentPattern: /^.*\{[^}"'`]*$/ + increaseIndentPattern: /^.*(\{[^}"'`]*|\([^)"'`]*|\[[^\]"'`]*)$/, + indentNextLinePattern: /^\s*(for|while|if|else)\b(?!.*[;{}]\s*(\/\/.*|\/[*].*[*]\/\s*)?$)/ }, wordPattern: /(-?\d*\.\d\w*)|([^\`\~\!\@\#\%\^\&\*\(\)\-\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\?\s]+)/g, onEnterRules: [ -- GitLab From 33d8446d68a0d83bcda094a8b61d6d30edfb37d4 Mon Sep 17 00:00:00 2001 From: rebornix Date: Thu, 8 Jun 2017 18:00:23 -0700 Subject: [PATCH 0972/1347] AutoIndent. Correct behavior of indentNextLine for Enter --- .../common/controller/cursorTypeOperations.ts | 97 +++-- .../modes/languageConfigurationRegistry.ts | 362 ++++++++++++------ .../common/modes/supports/indentRules.ts | 78 ++++ .../editor/common/modes/supports/onEnter.ts | 59 --- 4 files changed, 397 insertions(+), 199 deletions(-) create mode 100644 src/vs/editor/common/modes/supports/indentRules.ts diff --git a/src/vs/editor/common/controller/cursorTypeOperations.ts b/src/vs/editor/common/controller/cursorTypeOperations.ts index 7793fe670ce..389cc03ecbb 100644 --- a/src/vs/editor/common/controller/cursorTypeOperations.ts +++ b/src/vs/editor/common/controller/cursorTypeOperations.ts @@ -144,7 +144,7 @@ export class TypeOperations { } private static _goodIndentForLine(config: CursorConfiguration, model: ITokenizedModel, lineNumber: number): string { - let expectedIndentAction = LanguageConfigurationRegistry.getGoodIndentActionForLine(model, lineNumber); + let expectedIndentAction = LanguageConfigurationRegistry.getInheritIndentForLine(model, lineNumber, false); if (expectedIndentAction) { if (expectedIndentAction.action) { @@ -265,47 +265,24 @@ export class TypeOperations { private static _enter(config: CursorConfiguration, model: ITokenizedModel, keepPosition: boolean, range: Range): ICommand { let r = LanguageConfigurationRegistry.getEnterAction(model, range); + if (r) { let enterAction = r.enterAction; let indentation = r.indentation; - let beforeText = ''; - - if (!r.ignoreCurrentLine) { - // textBeforeEnter doesn't match unIndentPattern. - let goodIndent = this._goodIndentForLine(config, model, range.startLineNumber); - - if (goodIndent !== null && goodIndent === r.indentation) { - if (enterAction.outdentCurrentLine) { - goodIndent = TypeOperations.unshiftIndent(config, goodIndent); - } - - let lineText = model.getLineContent(range.startLineNumber); - if (config.normalizeIndentation(goodIndent) !== config.normalizeIndentation(indentation)) { - beforeText = config.normalizeIndentation(goodIndent) + lineText.substring(indentation.length, range.startColumn - 1); - indentation = goodIndent; - range = new Range(range.startLineNumber, 1, range.endLineNumber, range.endColumn); - } - } - } - - if (enterAction.removeText) { - indentation = indentation.substring(0, indentation.length - enterAction.removeText); - } - if (enterAction.indentAction === IndentAction.None) { // Nothing special - return TypeOperations._typeCommand(range, beforeText + '\n' + config.normalizeIndentation(indentation + enterAction.appendText), keepPosition); + return TypeOperations._typeCommand(range, '\n' + config.normalizeIndentation(indentation + enterAction.appendText), keepPosition); } else if (enterAction.indentAction === IndentAction.Indent) { // Indent once - return TypeOperations._typeCommand(range, beforeText + '\n' + config.normalizeIndentation(indentation + enterAction.appendText), keepPosition); + return TypeOperations._typeCommand(range, '\n' + config.normalizeIndentation(indentation + enterAction.appendText), keepPosition); } else if (enterAction.indentAction === IndentAction.IndentOutdent) { // Ultra special let normalIndent = config.normalizeIndentation(indentation); let increasedIndent = config.normalizeIndentation(indentation + enterAction.appendText); - let typeText = beforeText + '\n' + increasedIndent + '\n' + normalIndent; + let typeText = '\n' + increasedIndent + '\n' + normalIndent; if (keepPosition) { return new ReplaceCommandWithoutChangingPosition(range, typeText, true); @@ -314,7 +291,69 @@ export class TypeOperations { } } else if (enterAction.indentAction === IndentAction.Outdent) { let actualIndentation = TypeOperations.unshiftIndent(config, indentation); - return TypeOperations._typeCommand(range, beforeText + '\n' + config.normalizeIndentation(actualIndentation + enterAction.appendText), keepPosition); + return TypeOperations._typeCommand(range, '\n' + config.normalizeIndentation(actualIndentation + enterAction.appendText), keepPosition); + } + } + + // no enter rules applied, we should check indentation rules then. + let ir = LanguageConfigurationRegistry.getIndentForEnter(model, range, { + unshiftIndent: (indent) => { + return TypeOperations.unshiftIndent(config, indent); + }, + shiftIndent: (indent) => { + return TypeOperations.shiftIndent(config, indent); + }, + normalizeIndentation: (indent) => { + return config.normalizeIndentation(indent); + } + }); + + let lineText = model.getLineContent(range.startLineNumber); + let indentation = strings.getLeadingWhitespace(lineText); + if (ir) { + if (/^\s+$/.test(lineText) || indentation === config.normalizeIndentation(ir.beforeEnter)) { + return TypeOperations._typeCommand(range, '\n' + config.normalizeIndentation(ir.afterEnter), keepPosition); + } + let beforeText = config.normalizeIndentation(ir.beforeEnter) + lineText.substring(indentation.length, range.startColumn - 1); + range = new Range(range.startLineNumber, 1, range.endLineNumber, range.endColumn); + return TypeOperations._typeCommand(range, beforeText + '\n' + config.normalizeIndentation(ir.afterEnter), keepPosition); + } else { + return TypeOperations._typeCommand(range, '\n' + config.normalizeIndentation(indentation), keepPosition); + } + } + + private static _runAutoIndentType(config: CursorConfiguration, model: ITokenizedModel, selections: Selection[], ch: string): ICommand { + let selection = selections[0]; + let currentIndentation = LanguageConfigurationRegistry.getIndentationAtPosition(model, selection.startLineNumber, selection.startColumn); + let actualIndentation = LanguageConfigurationRegistry.getIndentActionForType(model, selections[0].startLineNumber, selections[0].startColumn, ch, { + shiftIndent: (indentation) => { + return TypeOperations.shiftIndent(config, indentation); + }, + unshiftIndent: (indentation) => { + return TypeOperations.unshiftIndent(config, indentation); + }, + }); + + if (actualIndentation === null) { + return null; + } + + if (actualIndentation !== config.normalizeIndentation(currentIndentation)) { + let firstNonWhitespace = model.getLineFirstNonWhitespaceColumn(selection.startLineNumber); + if (firstNonWhitespace === 0) { + return TypeOperations._typeCommand( + new Range(selection.startLineNumber, 0, selection.startLineNumber, selection.startColumn), + actualIndentation + ch, + false + ); + } else { + return TypeOperations._typeCommand( + new Range(selection.startLineNumber, 0, selection.startLineNumber, selection.startColumn), + actualIndentation + + model.getLineContent(selection.startLineNumber).substring(firstNonWhitespace - 1, selection.startColumn) + ch, + false + ); + } } return null; diff --git a/src/vs/editor/common/modes/languageConfigurationRegistry.ts b/src/vs/editor/common/modes/languageConfigurationRegistry.ts index 1563ebc48de..dde5e4c57c5 100644 --- a/src/vs/editor/common/modes/languageConfigurationRegistry.ts +++ b/src/vs/editor/common/modes/languageConfigurationRegistry.ts @@ -7,6 +7,7 @@ import { CharacterPairSupport } from 'vs/editor/common/modes/supports/characterPair'; import { BracketElectricCharacterSupport, IElectricAction } from 'vs/editor/common/modes/supports/electricCharacter'; import { IOnEnterSupportOptions, OnEnterSupport } from 'vs/editor/common/modes/supports/onEnter'; +import { IndentRulesSupport } from 'vs/editor/common/modes/supports/indentRules'; import { RichEditBrackets } from 'vs/editor/common/modes/supports/richEditBrackets'; import Event, { Emitter } from 'vs/base/common/event'; import { ITokenizedModel } from 'vs/editor/common/editorCommon'; @@ -29,6 +30,13 @@ export interface ICommentsConfiguration { blockCommentEndToken?: string; } +export interface IVirtualModel { + getLineTokens(lineNumber: number): LineTokens; + getLanguageIdentifier(): LanguageIdentifier; + getLanguageIdAtPosition(lineNumber: number, column: number): LanguageId; + getLineContent(lineNumber: number): string; +} + export class RichEditSupport { private readonly _conf: LanguageConfiguration; @@ -38,6 +46,7 @@ export class RichEditSupport { public readonly characterPair: CharacterPairSupport; public readonly wordDefinition: RegExp; public readonly onEnter: OnEnterSupport; + public readonly indentRulesSupport: IndentRulesSupport; public readonly brackets: RichEditBrackets; public readonly indentationRules: IndentationRule; @@ -64,6 +73,9 @@ export class RichEditSupport { this.wordDefinition = this._conf.wordPattern || DEFAULT_WORD_REGEXP; this.indentationRules = this._conf.indentationRules; + if (this._conf.indentationRules) { + this.indentRulesSupport = new IndentRulesSupport(this._conf.indentationRules); + } } private static _mergeConf(prev: LanguageConfiguration, current: LanguageConfiguration): LanguageConfiguration { @@ -250,6 +262,236 @@ export class LanguageConfigurationRegistryImpl { return ensureValidWordDefinition(value.wordDefinition || null); } + + + // beigin Indent Rules + + private _getIndentRulesSupport(languageId: LanguageId): IndentRulesSupport { + let value = this._getRichEditSupport(languageId); + if (!value) { + return null; + } + return value.indentRulesSupport || null; + } + + /** + * Get nearest preceiding line which doesn't match unIndentPattern or contains all whitespace. + */ + private getPrecedingValidLine(model: IVirtualModel, lineNumber: number, indentRulesSupport: IndentRulesSupport) { + let languageID = model.getLanguageIdAtPosition(lineNumber, 0); + if (lineNumber > 1) { + let lastLineNumber = lineNumber - 1; + let resultLineNumber = -1; + + for (lastLineNumber = lineNumber - 1; lastLineNumber >= 1; lastLineNumber--) { + if (model.getLanguageIdAtPosition(lastLineNumber, 0) !== languageID) { + return resultLineNumber; + } + let text = model.getLineContent(lastLineNumber); + if (indentRulesSupport.shouldIgnore(text) || text === '') { + resultLineNumber = lastLineNumber; + continue; + } + + return lastLineNumber; + } + } + + return -1; + } + + /** + * Get inherited indentation from above lines. + * 1. Find the nearest preceding line which doesn't match unIndentedLinePattern. + * 2. If this line matches indentNextLinePattern or increaseIndentPattern, it means that the indent level of `lineNumber` should be 1 greater than this line. + * 3. If this line doesn't match any indent rules + * a. check whether the line above it matches indentNextLinePattern + * b. If not, the indent level of this line is the result + * c. If so, it means the indent of this line is *temporary*, go upward utill we find a line whose indent is not temporary (the same workflow a -> b -> c). + * 4. Otherwise, we fail to get an inherited indent from aboves. Return null and we should not touch the indent of `lineNumber` + * + * This function only return the inherited indent based on above lines, it doesn't check whether current line should decrease or not. + */ + public getInheritIndentForLine(model: IVirtualModel, lineNumber: number, honorIntentialIndent: boolean = true) { + let indentRulesSupport = this._getIndentRulesSupport(model.getLanguageIdentifier().id); + if (!indentRulesSupport) { + return null; + } + + if (lineNumber <= 1) { + return null; + } + + let precedingUnIgnoredLine = this.getPrecedingValidLine(model, lineNumber, indentRulesSupport); + if (precedingUnIgnoredLine < 1) { + return null; + } + + let precedingUnIgnoredLineContent = model.getLineContent(precedingUnIgnoredLine); + + if (indentRulesSupport.shouldIncrease(precedingUnIgnoredLineContent) || indentRulesSupport.shouldIndentNextLine(precedingUnIgnoredLineContent)) { + return { + indentation: strings.getLeadingWhitespace(precedingUnIgnoredLineContent), + action: IndentAction.Indent + }; + } else if (indentRulesSupport.shouldDecrease(precedingUnIgnoredLineContent)) { + return { + indentation: strings.getLeadingWhitespace(precedingUnIgnoredLineContent), + action: null + }; + } else { + // precedingUnIgnoredLine can not be ignored. + // it doesn't increase indent of following lines + // it doesn't increase just next line + // so current line is not affect by precedingUnIgnoredLine + // and then we should get a correct inheritted indentation from above lines + if (precedingUnIgnoredLine === 1) { + return { + indentation: strings.getLeadingWhitespace(model.getLineContent(precedingUnIgnoredLine)), + action: null + }; + } + + let previousLine = precedingUnIgnoredLine - 1; + + let previousLineContent = model.getLineContent(previousLine); + + if (indentRulesSupport.shouldIndentNextLine(previousLineContent)) { + let stopLine = 0; + for (let i = previousLine - 1; i > 0; i--) { + if (indentRulesSupport.shouldIndentNextLine(model.getLineContent(i))) { + continue; + } + stopLine = i; + break; + } + + return { + indentation: strings.getLeadingWhitespace(model.getLineContent(stopLine + 1)), + action: null + }; + } + + if (honorIntentialIndent) { + return { + indentation: strings.getLeadingWhitespace(model.getLineContent(precedingUnIgnoredLine)), + action: null + }; + } else { + // search from precedingUnIgnoredLine until we find one whose indent is not temporary + for (let i = precedingUnIgnoredLine; i > 0; i--) { + let lineContent = model.getLineContent(i); + if (indentRulesSupport.shouldDecrease(lineContent)) { + return { + indentation: strings.getLeadingWhitespace(lineContent), + action: null + }; + } else if (indentRulesSupport.shouldIncrease(lineContent)) { + return { + indentation: strings.getLeadingWhitespace(lineContent), + action: IndentAction.Indent + }; + } else if (indentRulesSupport.shouldIndentNextLine(lineContent)) { + let stopLine = 0; + for (let j = i - 1; j > 0; j--) { + if (indentRulesSupport.shouldIndentNextLine(model.getLineContent(i))) { + continue; + } + stopLine = j; + break; + } + + return { + indentation: strings.getLeadingWhitespace(model.getLineContent(stopLine + 1)), + action: null + }; + } + } + + return { + indentation: strings.getLeadingWhitespace(model.getLineContent(1)), + action: null + }; + } + + } + } + + public getIndentForEnter(model: ITokenizedModel, range: Range, indentConverter: any): {beforeEnter: string, afterEnter: string} { + let scopedLineTokens = this.getScopedLineTokens(model, range.startLineNumber, range.startColumn); + let scopedLineText = scopedLineTokens.getLineContent(); + let beforeEnterText = scopedLineText.substr(0, range.startColumn - 1 - scopedLineTokens.firstCharOffset); + let afterEnterText; + + if (range.isEmpty()) { + afterEnterText = scopedLineText.substr(range.startColumn - 1 - scopedLineTokens.firstCharOffset); + } else { + const endScopedLineTokens = this.getScopedLineTokens(model, range.endLineNumber, range.endColumn); + afterEnterText = endScopedLineTokens.getLineContent().substr(range.endColumn - 1 - scopedLineTokens.firstCharOffset); + } + + let indentRulesSupport = this._getIndentRulesSupport(scopedLineTokens.languageId); + + if (!indentRulesSupport) { + return null; + } + + let beforeEnterIndentAction = this.getInheritIndentForLine(model, range.startLineNumber); + let beforeEnterIndent = strings.getLeadingWhitespace(beforeEnterText); + + if (indentRulesSupport.shouldDecrease(beforeEnterText)) { + if (beforeEnterIndentAction) { + beforeEnterIndent = beforeEnterIndentAction.indentation; + if (beforeEnterIndentAction.action !== IndentAction.Indent) { + beforeEnterIndent = indentConverter.unshiftIndent(beforeEnterIndent); + } + } + } + + let beforeEnterResult = beforeEnterIndent + strings.ltrim(strings.ltrim(beforeEnterText, ' '), '\t'); + + let virtualModel: IVirtualModel = { + getLineTokens: (lineNumber: number) => { + return model.getLineTokens(lineNumber); + }, + getLanguageIdentifier: () => { + return model.getLanguageIdentifier(); + }, + getLanguageIdAtPosition: (lineNumber: number, column: number) => { + return model.getLanguageIdAtPosition(lineNumber, column); + }, + getLineContent: (lineNumber: number) => { + if (lineNumber === range.startLineNumber) { + return beforeEnterResult; + } else { + return model.getLineContent(lineNumber); + } + } + }; + + let afterEnterAction = this.getInheritIndentForLine(virtualModel, range.startLineNumber + 1); + if (!afterEnterAction) { + return { + beforeEnter: beforeEnterIndent, + afterEnter: beforeEnterIndent + }; + } + + let afterEnterIndent = afterEnterAction.indentation; + + if (afterEnterAction.action === IndentAction.Indent) { + afterEnterIndent = indentConverter.shiftIndent(afterEnterIndent); + } + + if (indentRulesSupport.shouldDecrease(afterEnterText)) { + afterEnterIndent = indentConverter.unshiftIndent(afterEnterIndent); + } + + return { + beforeEnter: beforeEnterIndent, + afterEnter: afterEnterIndent + }; + } // begin onEnter private _getOnEnterSupport(languageId: LanguageId): OnEnterSupport { @@ -266,18 +508,13 @@ export class LanguageConfigurationRegistryImpl { return r ? r.enterAction : null; } - public getEnterAction(model: ITokenizedModel, range: Range): { enterAction: EnterAction; indentation: string; ignoreCurrentLine: boolean } { + public getEnterAction(model: ITokenizedModel, range: Range): { enterAction: EnterAction; indentation: string; } { let indentation = this.getIndentationAtPosition(model, range.startLineNumber, range.startColumn); - let ignoreCurrentLine = false; let scopedLineTokens = this.getScopedLineTokens(model, range.startLineNumber, range.startColumn); let onEnterSupport = this._getOnEnterSupport(scopedLineTokens.languageId); if (!onEnterSupport) { - return { - enterAction: { indentAction: IndentAction.None, appendText: '' }, - indentation: indentation, - ignoreCurrentLine: false - }; + return null; } let scopedLineText = scopedLineTokens.getLineContent(); @@ -293,45 +530,18 @@ export class LanguageConfigurationRegistryImpl { } let lineNumber = range.startLineNumber; - - // if the text before the cursor/range start position is empty or matches `unIndentedLinePattern` - // this line is actually ignored after the enter action - if (onEnterSupport.shouldIgnore(beforeEnterText)) { - ignoreCurrentLine = true; - let lastLineNumber = this.getLastValidLine(model, lineNumber, onEnterSupport); - - if (lastLineNumber <= 0) { - return { - enterAction: { indentAction: IndentAction.None, appendText: '' }, - indentation: '', - ignoreCurrentLine: ignoreCurrentLine - }; - } - - scopedLineTokens = this.getScopedLineTokens(model, lastLineNumber); - beforeEnterText = this.getLineContent(model, lastLineNumber); - lineNumber = lastLineNumber; - indentation = this.getIndentationAtPosition(model, lineNumber, model.getLineMaxColumn(lineNumber)); - } - let oneLineAboveText = ''; if (lineNumber > 1 && scopedLineTokens.firstCharOffset === 0) { // This is not the first line and the entire line belongs to this mode - let lastLineNumber = this.getLastValidLine(model, lineNumber, onEnterSupport); - - if (lastLineNumber >= 1) { - // No previous line with content found - let oneLineAboveScopedLineTokens = this.getScopedLineTokens(model, lastLineNumber); + let oneLineAboveScopedLineTokens = this.getScopedLineTokens(model, lineNumber - 1); if (oneLineAboveScopedLineTokens.languageId === scopedLineTokens.languageId) { // The line above ends with text belonging to the same mode oneLineAboveText = oneLineAboveScopedLineTokens.getLineContent(); } } - } let enterResult: EnterAction = null; - try { enterResult = onEnterSupport.onEnter(oneLineAboveText, beforeEnterText, afterEnterText); } catch (e) { @@ -339,7 +549,7 @@ export class LanguageConfigurationRegistryImpl { } if (!enterResult) { - enterResult = { indentAction: IndentAction.None, appendText: '' }; + return null; } else { // Here we add `\t` to appendText first because enterAction is leveraging appendText and removeText to change indentation. if (!enterResult.appendText) { @@ -351,17 +561,20 @@ export class LanguageConfigurationRegistryImpl { } else { enterResult.appendText = ''; } + } } + + if (enterResult.removeText) { + indentation = indentation.substring(0, indentation.length - enterResult.removeText); } return { enterAction: enterResult, indentation: indentation, - ignoreCurrentLine: ignoreCurrentLine }; } - private getIndentationAtPosition(model: ITokenizedModel, lineNumber: number, column: number): string { + public getIndentationAtPosition(model: ITokenizedModel, lineNumber: number, column: number): string { let lineText = model.getLineContent(lineNumber); let indentation = strings.getLeadingWhitespace(lineText); if (indentation.length > column - 1) { @@ -371,33 +584,6 @@ export class LanguageConfigurationRegistryImpl { return indentation; } - private getLastValidLine(model: ITokenizedModel, lineNumber: number, onEnterSupport: OnEnterSupport): number { - if (lineNumber > 1) { - let lastLineNumber = lineNumber - 1; - - for (lastLineNumber = lineNumber - 1; lastLineNumber >= 1; lastLineNumber--) { - let lineText = model.getLineContent(lastLineNumber); - if (!onEnterSupport.shouldIgnore(lineText) && onEnterSupport.containNonWhitespace(lineText)) { - break; - } - } - - if (lastLineNumber >= 1) { - return lastLineNumber; - } - } - - return -1; - } - - private getLineContent(model: ITokenizedModel, lineNumber: number): string { - let scopedLineTokens = this.getScopedLineTokens(model, lineNumber); - let column = model.getLineMaxColumn(lineNumber); - let scopedLineText = scopedLineTokens.getLineContent(); - let lineText = scopedLineText.substr(0, column - 1 - scopedLineTokens.firstCharOffset); - return lineText; - } - private getScopedLineTokens(model: ITokenizedModel, lineNumber: number, columnNumber?: number) { model.forceTokenization(lineNumber); let lineTokens = model.getLineTokens(lineNumber); @@ -406,52 +592,6 @@ export class LanguageConfigurationRegistryImpl { return scopedLineTokens; } - public getGoodIndentActionForLine(model: ITokenizedModel, lineNumber: number) { - let onEnterSupport = this._getOnEnterSupport(model.getLanguageIdentifier().id); - if (!onEnterSupport) { - return null; - } - - /** - * In order to get correct indentation for current line - * we need to loop backwards the content from current line until - * 1. a line contains non whitespace characters, - * 2. and the line doesn't match `unIndentedLinePattern` pattern - */ - let lastLineNumber = this.getLastValidLine(model, lineNumber, onEnterSupport); - - if (lastLineNumber < 1) { - // No previous line with content found - return null; - } - - // it's Okay that lineNumber > model.getLineCount(), a good example is guessing the indentation of next potential line - // when the cursor is at the end of file. - if (lineNumber <= model.getLineCount()) { - let currentLineScopedLineTokens = this.getScopedLineTokens(model, lineNumber); - let lastLineScopedLineTokens = this.getScopedLineTokens(model, lastLineNumber); - - if (currentLineScopedLineTokens.languageId !== lastLineScopedLineTokens.languageId) { - // The language mode of last valid line is not the same as current line. - return null; - } - } - - let lineText = model.getLineContent(lastLineNumber); - let oneLineAboveText: string; - if (lastLineNumber > 1) { - oneLineAboveText = model.getLineContent(lastLineNumber - 1); - } - - let indentation = strings.getLeadingWhitespace(lineText); - let onEnterAction = onEnterSupport.onEnter(oneLineAboveText, lineText, ''); - - return { - indentation: indentation, - action: onEnterAction ? onEnterAction.indentAction : null - }; - } - // end onEnter public getBracketsSupport(languageId: LanguageId): RichEditBrackets { diff --git a/src/vs/editor/common/modes/supports/indentRules.ts b/src/vs/editor/common/modes/supports/indentRules.ts new file mode 100644 index 00000000000..ab23b19a120 --- /dev/null +++ b/src/vs/editor/common/modes/supports/indentRules.ts @@ -0,0 +1,78 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +'use strict'; + +import * as strings from 'vs/base/common/strings'; +import { IndentationRule, IndentAction } from 'vs/editor/common/modes/languageConfiguration'; + +export class IndentRulesSupport { + + private readonly _indentationRules: IndentationRule; + + constructor(indentationRules: IndentationRule) { + this._indentationRules = indentationRules; + } + + public onType(text: string): IndentAction { + if (this._indentationRules) { + if (this._indentationRules.unIndentedLinePattern && this._indentationRules.unIndentedLinePattern.test(text)) { + return null; + } + + if (this._indentationRules.decreaseIndentPattern && this._indentationRules.decreaseIndentPattern.test(text)) { + return IndentAction.Outdent; + } + } + return null; + } + + public containNonWhitespace(text: string): boolean { + // the text doesn't contain any non-whitespace character. + let nonWhitespaceIdx = strings.lastNonWhitespaceIndex(text); + + if (nonWhitespaceIdx >= 0) { + return true; + } + + return false; + } + + public shouldIncrease(text: string): boolean { + if (this._indentationRules) { + if (this._indentationRules.increaseIndentPattern && this._indentationRules.increaseIndentPattern.test(text)) { + return true; + } + // if (this._indentationRules.indentNextLinePattern && this._indentationRules.indentNextLinePattern.test(text)) { + // return true; + // } + } + return false; + } + + public shouldDecrease(text: string): boolean { + if (this._indentationRules && this._indentationRules.decreaseIndentPattern && this._indentationRules.decreaseIndentPattern.test(text)) { + return true; + } + return false; + } + + public shouldIndentNextLine(text: string): boolean { + if (this._indentationRules && this._indentationRules.indentNextLinePattern && this._indentationRules.indentNextLinePattern.test(text)) { + return true; + } + + return false; + } + + public shouldIgnore(text: string): boolean { + // the text matches `unIndentedLinePattern` + if (this._indentationRules && this._indentationRules.unIndentedLinePattern && this._indentationRules.unIndentedLinePattern.test(text)) { + return true; + } + + return false; + } +} + diff --git a/src/vs/editor/common/modes/supports/onEnter.ts b/src/vs/editor/common/modes/supports/onEnter.ts index 3bddd1f8566..2287829bb1d 100644 --- a/src/vs/editor/common/modes/supports/onEnter.ts +++ b/src/vs/editor/common/modes/supports/onEnter.ts @@ -72,45 +72,6 @@ export class OnEnterSupport { } } - // (3): Indentation Support - if (this._indentationRules) { - let indentOffset: null | number = null; - let outdentCurrentLine = false; - - if (this._indentationRules.increaseIndentPattern && this._indentationRules.increaseIndentPattern.test(beforeEnterText)) { - indentOffset = 1; - } - if (this._indentationRules.indentNextLinePattern && this._indentationRules.indentNextLinePattern.test(beforeEnterText)) { - indentOffset = 1; - } - - /** - * Since the indentation of `beforeEnterText` might not be correct, we still provide the correct indent action - * even if there is nothing to outdent from. - */ - if (this._indentationRules.decreaseIndentPattern && this._indentationRules.decreaseIndentPattern.test(afterEnterText)) { - indentOffset = indentOffset ? indentOffset - 1 : -1; - } - if (this._indentationRules.indentNextLinePattern && this._indentationRules.indentNextLinePattern.test(oneLineAboveText)) { - indentOffset = indentOffset ? indentOffset - 1 : -1; - } - if (this._indentationRules.decreaseIndentPattern && this._indentationRules.decreaseIndentPattern.test(beforeEnterText)) { - outdentCurrentLine = true; - } - - if (indentOffset !== null || outdentCurrentLine) { - // this means at least one indentation rule is matched so we should handle it - indentOffset = indentOffset || 0; - switch (indentOffset) { - case -1: - return { indentAction: IndentAction.Outdent, outdentCurrentLine: outdentCurrentLine }; - case 0: - return { indentAction: IndentAction.None, outdentCurrentLine: outdentCurrentLine }; - case 1: - return { indentAction: IndentAction.Indent, outdentCurrentLine: outdentCurrentLine }; - } - } - } // (4): Open bracket based logic if (beforeEnterText.length > 0) { @@ -125,26 +86,6 @@ export class OnEnterSupport { return null; } - public containNonWhitespace(text: string): boolean { - // the text doesn't contain any non-whitespace character. - let nonWhitespaceIdx = strings.lastNonWhitespaceIndex(text); - - if (nonWhitespaceIdx >= 0) { - return true; - } - - return false; - } - - public shouldIgnore(text: string): boolean { - // the text matches `unIndentedLinePattern` - if (this._indentationRules && this._indentationRules.unIndentedLinePattern && this._indentationRules.unIndentedLinePattern.test(text)) { - return true; - } - - return false; - } - private static _createOpenBracketRegExp(bracket: string): RegExp { var str = strings.escapeRegExpCharacters(bracket); if (!/\B/.test(str.charAt(0))) { -- GitLab From 9bda5f0d184279f8d8d20bff25181421cc705de4 Mon Sep 17 00:00:00 2001 From: rebornix Date: Thu, 8 Jun 2017 18:01:26 -0700 Subject: [PATCH 0973/1347] AutoIndent: Thanks you tests, without you I will have another sleepless night. --- .../test/common/controller/cursor.test.ts | 373 +++++++++--------- .../common/modes/supports/onEnter.test.ts | 28 -- 2 files changed, 180 insertions(+), 221 deletions(-) diff --git a/src/vs/editor/test/common/controller/cursor.test.ts b/src/vs/editor/test/common/controller/cursor.test.ts index f2456100aa3..7c9fa3076bd 100644 --- a/src/vs/editor/test/common/controller/cursor.test.ts +++ b/src/vs/editor/test/common/controller/cursor.test.ts @@ -1222,172 +1222,6 @@ suite('Editor Controller - Regression tests', () => { model.dispose(); }); - test('bug #16543: Tab should indent to correct indentation spot immediately', () => { - let mode = new OnEnterMode(IndentAction.Indent); - let model = Model.createFromString( - [ - 'function baz() {', - '\tfunction hello() { // something here', - '\t', - '', - '\t}', - '}' - ].join('\n'), - { - defaultEOL: DefaultEndOfLine.LF, - detectIndentation: false, - insertSpaces: false, - tabSize: 4, - trimAutoWhitespace: true - }, - mode.getLanguageIdentifier() - ); - - withMockCodeEditor(null, { model: model }, (editor, cursor) => { - moveTo(cursor, 4, 1, false); - assertCursor(cursor, new Selection(4, 1, 4, 1)); - - CoreEditingCommands.Tab.runEditorCommand(null, editor, null); - assert.equal(model.getLineContent(4), '\t\t'); - }); - - model.dispose(); - mode.dispose(); - }); - - test('bug #2938 (1): When pressing Tab on white-space only lines, indent straight to the right spot (similar to empty lines)', () => { - let mode = new OnEnterMode(IndentAction.Indent); - let model = Model.createFromString( - [ - '\tfunction baz() {', - '\t\tfunction hello() { // something here', - '\t\t', - '\t', - '\t\t}', - '\t}' - ].join('\n'), - { - defaultEOL: DefaultEndOfLine.LF, - detectIndentation: false, - insertSpaces: false, - tabSize: 4, - trimAutoWhitespace: true - }, - mode.getLanguageIdentifier() - ); - - withMockCodeEditor(null, { model: model }, (editor, cursor) => { - moveTo(cursor, 4, 2, false); - assertCursor(cursor, new Selection(4, 2, 4, 2)); - - CoreEditingCommands.Tab.runEditorCommand(null, editor, null); - assert.equal(model.getLineContent(4), '\t\t\t'); - }); - - model.dispose(); - mode.dispose(); - }); - - - test('bug #2938 (2): When pressing Tab on white-space only lines, indent straight to the right spot (similar to empty lines)', () => { - let mode = new OnEnterMode(IndentAction.Indent); - let model = Model.createFromString( - [ - '\tfunction baz() {', - '\t\tfunction hello() { // something here', - '\t\t', - ' ', - '\t\t}', - '\t}' - ].join('\n'), - { - defaultEOL: DefaultEndOfLine.LF, - detectIndentation: false, - insertSpaces: false, - tabSize: 4, - trimAutoWhitespace: true - }, - mode.getLanguageIdentifier() - ); - - withMockCodeEditor(null, { model: model }, (editor, cursor) => { - moveTo(cursor, 4, 1, false); - assertCursor(cursor, new Selection(4, 1, 4, 1)); - - CoreEditingCommands.Tab.runEditorCommand(null, editor, null); - assert.equal(model.getLineContent(4), '\t\t\t'); - }); - - model.dispose(); - mode.dispose(); - }); - - test('bug #2938 (3): When pressing Tab on white-space only lines, indent straight to the right spot (similar to empty lines)', () => { - let mode = new OnEnterMode(IndentAction.Indent); - let model = Model.createFromString( - [ - '\tfunction baz() {', - '\t\tfunction hello() { // something here', - '\t\t', - '\t\t\t', - '\t\t}', - '\t}' - ].join('\n'), - { - defaultEOL: DefaultEndOfLine.LF, - detectIndentation: false, - insertSpaces: false, - tabSize: 4, - trimAutoWhitespace: true - }, - mode.getLanguageIdentifier() - ); - - withMockCodeEditor(null, { model: model }, (editor, cursor) => { - moveTo(cursor, 4, 3, false); - assertCursor(cursor, new Selection(4, 3, 4, 3)); - - CoreEditingCommands.Tab.runEditorCommand(null, editor, null); - assert.equal(model.getLineContent(4), '\t\t\t\t'); - }); - - model.dispose(); - mode.dispose(); - }); - - test('bug #2938 (4): When pressing Tab on white-space only lines, indent straight to the right spot (similar to empty lines)', () => { - let mode = new OnEnterMode(IndentAction.Indent); - let model = Model.createFromString( - [ - '\tfunction baz() {', - '\t\tfunction hello() { // something here', - '\t\t', - '\t\t\t\t', - '\t\t}', - '\t}' - ].join('\n'), - { - defaultEOL: DefaultEndOfLine.LF, - detectIndentation: false, - insertSpaces: false, - tabSize: 4, - trimAutoWhitespace: true - }, - mode.getLanguageIdentifier() - ); - - withMockCodeEditor(null, { model: model }, (editor, cursor) => { - moveTo(cursor, 4, 4, false); - assertCursor(cursor, new Selection(4, 4, 4, 4)); - - CoreEditingCommands.Tab.runEditorCommand(null, editor, null); - assert.equal(model.getLineContent(4), '\t\t\t\t\t'); - }); - - model.dispose(); - mode.dispose(); - }); - test('bug #16815:Shift+Tab doesn\'t go back to tabstop', () => { let mode = new OnEnterMode(IndentAction.IndentOutdent); let model = Model.createFromString( @@ -2423,8 +2257,6 @@ suite('Editor Controller - Indentation Rules', () => { unIndentedLinePattern: /^(?!.*([;{}]|\S:)\s*(\/\/.*|\/[*].*[*]\/\s*)?$)(?!.*(\{[^}"']*|\([^)"']*|\[[^\]"']*|^\s*(\{\}|\(\)|\[\]|(case\b.*|default):))\s*(\/\/.*|\/[*].*[*]\/\s*)?$)(?!^\s*((?!\S.*\/[*]).*[*]\/\s*)?[})\]]|^\s*(case\b.*|default):\s*(\/\/.*|\/[*].*[*]\/\s*)?$)(?!^\s*(for|while|if|else)\b(?!.*[;{}]\s*(\/\/.*|\/[*].*[*]\/\s*)?$))/ }); - let emptyRulesMode = new OnEnterMode(IndentAction.None); - test('Enter honors increaseIndentPattern', () => { usingCursor({ text: [ @@ -2544,7 +2376,7 @@ suite('Editor Controller - Indentation Rules', () => { cursorCommand(cursor, H.Type, { text: '\n' }, 'keyboard'); assertCursor(cursor, new Selection(5, 1, 5, 1)); - assert.equal(model.getLineContent(4), '}', '001'); + assert.equal(model.getLineContent(4), '\t}', '001'); }); }); @@ -2661,27 +2493,27 @@ suite('Editor Controller - Indentation Rules', () => { }); }); - test('Enter supports intentional indentation', () => { - usingCursor({ - text: [ - '\tif (true) {', - '\t\tswitch(true) {', - '\t\t\tcase true:', - '\t\t\t\tbreak;', - '\t\t}', - '\t}' - ], - languageIdentifier: mode.getLanguageIdentifier(), - modelOpts: { insertSpaces: false, tabSize: 4, detectIndentation: false, defaultEOL: DefaultEndOfLine.LF, trimAutoWhitespace: true } - }, (model, cursor) => { - moveTo(cursor, 5, 4, false); - assertCursor(cursor, new Selection(5, 4, 5, 4)); - - cursorCommand(cursor, H.Type, { text: '\n' }, 'keyboard'); - assert.equal(model.getLineContent(5), '\t\t}'); - assertCursor(cursor, new Selection(6, 3, 6, 3)); - }); - }); + // test('Enter supports intentional indentation', () => { + // usingCursor({ + // text: [ + // '\tif (true) {', + // '\t\tswitch(true) {', + // '\t\t\tcase true:', + // '\t\t\t\tbreak;', + // '\t\t}', + // '\t}' + // ], + // languageIdentifier: mode.getLanguageIdentifier(), + // modelOpts: { insertSpaces: false, tabSize: 4, detectIndentation: false, defaultEOL: DefaultEndOfLine.LF, trimAutoWhitespace: true } + // }, (model, cursor) => { + // moveTo(cursor, 5, 4, false); + // assertCursor(cursor, new Selection(5, 4, 5, 4)); + + // cursorCommand(cursor, H.Type, { text: '\n' }, 'keyboard'); + // assert.equal(model.getLineContent(5), '\t\t}'); + // assertCursor(cursor, new Selection(6, 3, 6, 3)); + // }); + // }); test('issue Microsoft/monaco-editor#108 part 1/2: Auto indentation on Enter with selection is half broken', () => { usingCursor({ @@ -2747,7 +2579,6 @@ suite('Editor Controller - Indentation Rules', () => { '\t}', '?>' ], - languageIdentifier: emptyRulesMode.getLanguageIdentifier(), modelOpts: { insertSpaces: false, tabSize: 4, detectIndentation: false, defaultEOL: DefaultEndOfLine.LF, trimAutoWhitespace: true } }, (model, cursor) => { moveTo(cursor, 5, 3, false); @@ -2767,7 +2598,6 @@ suite('Editor Controller - Indentation Rules', () => { ' return 5;', ' ' ], - languageIdentifier: emptyRulesMode.getLanguageIdentifier(), modelOpts: { insertSpaces: false, tabSize: 4, detectIndentation: false, defaultEOL: DefaultEndOfLine.LF, trimAutoWhitespace: true } }, (model, cursor) => { moveTo(cursor, 3, 2, false); @@ -2778,6 +2608,163 @@ suite('Editor Controller - Indentation Rules', () => { assert.equal(model.getLineContent(4), '\t'); }); }); + + test('bug #16543: Tab should indent to correct indentation spot immediately', () => { + let model = Model.createFromString( + [ + 'function baz() {', + '\tfunction hello() { // something here', + '\t', + '', + '\t}', + '}' + ].join('\n'), + { + defaultEOL: DefaultEndOfLine.LF, + detectIndentation: false, + insertSpaces: false, + tabSize: 4, + trimAutoWhitespace: true + }, + mode.getLanguageIdentifier() + ); + + withMockCodeEditor(null, { model: model }, (editor, cursor) => { + moveTo(cursor, 4, 1, false); + assertCursor(cursor, new Selection(4, 1, 4, 1)); + + CoreEditingCommands.Tab.runEditorCommand(null, editor, null); + assert.equal(model.getLineContent(4), '\t\t'); + }); + + model.dispose(); + }); + + + test('bug #2938 (1): When pressing Tab on white-space only lines, indent straight to the right spot (similar to empty lines)', () => { + let model = Model.createFromString( + [ + '\tfunction baz() {', + '\t\tfunction hello() { // something here', + '\t\t', + '\t', + '\t\t}', + '\t}' + ].join('\n'), + { + defaultEOL: DefaultEndOfLine.LF, + detectIndentation: false, + insertSpaces: false, + tabSize: 4, + trimAutoWhitespace: true + }, + mode.getLanguageIdentifier() + ); + + withMockCodeEditor(null, { model: model }, (editor, cursor) => { + moveTo(cursor, 4, 2, false); + assertCursor(cursor, new Selection(4, 2, 4, 2)); + + CoreEditingCommands.Tab.runEditorCommand(null, editor, null); + assert.equal(model.getLineContent(4), '\t\t\t'); + }); + + model.dispose(); + }); + + + test('bug #2938 (2): When pressing Tab on white-space only lines, indent straight to the right spot (similar to empty lines)', () => { + let model = Model.createFromString( + [ + '\tfunction baz() {', + '\t\tfunction hello() { // something here', + '\t\t', + ' ', + '\t\t}', + '\t}' + ].join('\n'), + { + defaultEOL: DefaultEndOfLine.LF, + detectIndentation: false, + insertSpaces: false, + tabSize: 4, + trimAutoWhitespace: true + }, + mode.getLanguageIdentifier() + ); + + withMockCodeEditor(null, { model: model }, (editor, cursor) => { + moveTo(cursor, 4, 1, false); + assertCursor(cursor, new Selection(4, 1, 4, 1)); + + CoreEditingCommands.Tab.runEditorCommand(null, editor, null); + assert.equal(model.getLineContent(4), '\t\t\t'); + }); + + model.dispose(); + }); + + test('bug #2938 (3): When pressing Tab on white-space only lines, indent straight to the right spot (similar to empty lines)', () => { + let model = Model.createFromString( + [ + '\tfunction baz() {', + '\t\tfunction hello() { // something here', + '\t\t', + '\t\t\t', + '\t\t}', + '\t}' + ].join('\n'), + { + defaultEOL: DefaultEndOfLine.LF, + detectIndentation: false, + insertSpaces: false, + tabSize: 4, + trimAutoWhitespace: true + }, + mode.getLanguageIdentifier() + ); + + withMockCodeEditor(null, { model: model }, (editor, cursor) => { + moveTo(cursor, 4, 3, false); + assertCursor(cursor, new Selection(4, 3, 4, 3)); + + CoreEditingCommands.Tab.runEditorCommand(null, editor, null); + assert.equal(model.getLineContent(4), '\t\t\t\t'); + }); + + model.dispose(); + }); + + test('bug #2938 (4): When pressing Tab on white-space only lines, indent straight to the right spot (similar to empty lines)', () => { + let model = Model.createFromString( + [ + '\tfunction baz() {', + '\t\tfunction hello() { // something here', + '\t\t', + '\t\t\t\t', + '\t\t}', + '\t}' + ].join('\n'), + { + defaultEOL: DefaultEndOfLine.LF, + detectIndentation: false, + insertSpaces: false, + tabSize: 4, + trimAutoWhitespace: true + }, + mode.getLanguageIdentifier() + ); + + withMockCodeEditor(null, { model: model }, (editor, cursor) => { + moveTo(cursor, 4, 4, false); + assertCursor(cursor, new Selection(4, 4, 4, 4)); + + CoreEditingCommands.Tab.runEditorCommand(null, editor, null); + assert.equal(model.getLineContent(4), '\t\t\t\t\t'); + }); + + model.dispose(); + }); }); interface ICursorOpts { @@ -3061,7 +3048,7 @@ suite('autoClosingPairs', () => { class AutoClosingMode extends MockMode { - private static _id = new LanguageIdentifier('autoClosingMode', 3); + private static _id = new LanguageIdentifier('autoClosingMode', 5); constructor() { super(AutoClosingMode._id); diff --git a/src/vs/editor/test/common/modes/supports/onEnter.test.ts b/src/vs/editor/test/common/modes/supports/onEnter.test.ts index a0a6cf77fd0..8b47393c635 100644 --- a/src/vs/editor/test/common/modes/supports/onEnter.test.ts +++ b/src/vs/editor/test/common/modes/supports/onEnter.test.ts @@ -10,34 +10,6 @@ import { OnEnterSupport } from 'vs/editor/common/modes/supports/onEnter'; suite('OnEnter', () => { - test('uses indentationRules', () => { - var support = new OnEnterSupport({ - indentationRules: { - decreaseIndentPattern: /^\s*((?!\S.*\/[*]).*[*]\/\s*)?[})\]]|^\s*(case\b.*|default):\s*(\/\/.*|\/[*].*[*]\/\s*)?$/, - increaseIndentPattern: /(\{[^}"'`]*|\([^)"']*|\[[^\]"']*|^\s*(\{\}|\(\)|\[\]|(case\b.*|default):))\s*(\/\/.*|\/[*].*[*]\/\s*)?$/, - indentNextLinePattern: /^\s*(for|while|if|else)\b(?!.*[;{}]\s*(\/\/.*|\/[*].*[*]\/\s*)?$)/, - unIndentedLinePattern: /^(?!.*([;{}]|\S:)\s*(\/\/.*|\/[*].*[*]\/\s*)?$)(?!.*(\{[^}"']*|\([^)"']*|\[[^\]"']*|^\s*(\{\}|\(\)|\[\]|(case\b.*|default):))\s*(\/\/.*|\/[*].*[*]\/\s*)?$)(?!^\s*((?!\S.*\/[*]).*[*]\/\s*)?[})\]]|^\s*(case\b.*|default):\s*(\/\/.*|\/[*].*[*]\/\s*)?$)(?!^\s*(for|while|if|else)\b(?!.*[;{}]\s*(\/\/.*|\/[*].*[*]\/\s*)?$))/ - } - }); - - var testIndentAction = (oneLineAboveText: string, beforeText: string, afterText: string, expected: IndentAction) => { - var actual = support.onEnter(oneLineAboveText, beforeText, afterText); - if (expected === IndentAction.None) { - assert.equal(actual, null); - } else { - assert.equal(actual.indentAction, expected); - } - }; - - testIndentAction('', 'case', '', IndentAction.None); - testIndentAction('', 'case:', '', IndentAction.Indent); - testIndentAction('', 'if (true) {', '', IndentAction.Indent); - testIndentAction('', 'if (true)', '', IndentAction.Indent); - testIndentAction('', ' ', '}', IndentAction.Outdent); - testIndentAction('if(true)', '\treturn false', '', IndentAction.Outdent); - testIndentAction('', 'var foo = `{`;', '', IndentAction.None); - }); - test('uses brackets', () => { var brackets: CharacterPair[] = [ ['(', ')'], -- GitLab From 557f010feef1ab1029bf26f2b86b9c8a72930fdd Mon Sep 17 00:00:00 2001 From: rebornix Date: Thu, 8 Jun 2017 18:01:45 -0700 Subject: [PATCH 0974/1347] AutoIndent: Type! --- .../common/controller/cursorTypeOperations.ts | 42 ++++++++------ .../modes/languageConfigurationRegistry.ts | 55 ++++++++++++++++--- 2 files changed, 73 insertions(+), 24 deletions(-) diff --git a/src/vs/editor/common/controller/cursorTypeOperations.ts b/src/vs/editor/common/controller/cursorTypeOperations.ts index 389cc03ecbb..d10b0d5951c 100644 --- a/src/vs/editor/common/controller/cursorTypeOperations.ts +++ b/src/vs/editor/common/controller/cursorTypeOperations.ts @@ -266,31 +266,31 @@ export class TypeOperations { private static _enter(config: CursorConfiguration, model: ITokenizedModel, keepPosition: boolean, range: Range): ICommand { let r = LanguageConfigurationRegistry.getEnterAction(model, range); if (r) { - let enterAction = r.enterAction; - let indentation = r.indentation; + let enterAction = r.enterAction; + let indentation = r.indentation; - if (enterAction.indentAction === IndentAction.None) { - // Nothing special + if (enterAction.indentAction === IndentAction.None) { + // Nothing special return TypeOperations._typeCommand(range, '\n' + config.normalizeIndentation(indentation + enterAction.appendText), keepPosition); - } else if (enterAction.indentAction === IndentAction.Indent) { - // Indent once + } else if (enterAction.indentAction === IndentAction.Indent) { + // Indent once return TypeOperations._typeCommand(range, '\n' + config.normalizeIndentation(indentation + enterAction.appendText), keepPosition); - } else if (enterAction.indentAction === IndentAction.IndentOutdent) { - // Ultra special - let normalIndent = config.normalizeIndentation(indentation); - let increasedIndent = config.normalizeIndentation(indentation + enterAction.appendText); + } else if (enterAction.indentAction === IndentAction.IndentOutdent) { + // Ultra special + let normalIndent = config.normalizeIndentation(indentation); + let increasedIndent = config.normalizeIndentation(indentation + enterAction.appendText); let typeText = '\n' + increasedIndent + '\n' + normalIndent; - if (keepPosition) { - return new ReplaceCommandWithoutChangingPosition(range, typeText, true); - } else { - return new ReplaceCommandWithOffsetCursorState(range, typeText, -1, increasedIndent.length - normalIndent.length, true); - } - } else if (enterAction.indentAction === IndentAction.Outdent) { - let actualIndentation = TypeOperations.unshiftIndent(config, indentation); + if (keepPosition) { + return new ReplaceCommandWithoutChangingPosition(range, typeText, true); + } else { + return new ReplaceCommandWithOffsetCursorState(range, typeText, -1, increasedIndent.length - normalIndent.length, true); + } + } else if (enterAction.indentAction === IndentAction.Outdent) { + let actualIndentation = TypeOperations.unshiftIndent(config, indentation); return TypeOperations._typeCommand(range, '\n' + config.normalizeIndentation(actualIndentation + enterAction.appendText), keepPosition); } } @@ -596,6 +596,14 @@ export class TypeOperations { }); } + let indentCommand = this._runAutoIndentType(config, model, selections, ch); + if (indentCommand) { + return new EditOperationResult([indentCommand], { + shouldPushStackElementBefore: true, + shouldPushStackElementAfter: false, + }); + } + if (this._isAutoClosingCloseCharType(config, model, selections, ch)) { return this._runAutoClosingCloseCharType(config, model, selections, ch); } diff --git a/src/vs/editor/common/modes/languageConfigurationRegistry.ts b/src/vs/editor/common/modes/languageConfigurationRegistry.ts index dde5e4c57c5..c15da62eb22 100644 --- a/src/vs/editor/common/modes/languageConfigurationRegistry.ts +++ b/src/vs/editor/common/modes/languageConfigurationRegistry.ts @@ -75,7 +75,7 @@ export class RichEditSupport { this.indentationRules = this._conf.indentationRules; if (this._conf.indentationRules) { this.indentRulesSupport = new IndentRulesSupport(this._conf.indentationRules); - } + } } private static _mergeConf(prev: LanguageConfiguration, current: LanguageConfiguration): LanguageConfiguration { @@ -417,7 +417,7 @@ export class LanguageConfigurationRegistryImpl { } } - public getIndentForEnter(model: ITokenizedModel, range: Range, indentConverter: any): {beforeEnter: string, afterEnter: string} { + public getIndentForEnter(model: ITokenizedModel, range: Range, indentConverter: any): { beforeEnter: string, afterEnter: string } { let scopedLineTokens = this.getScopedLineTokens(model, range.startLineNumber, range.startColumn); let scopedLineText = scopedLineTokens.getLineContent(); let beforeEnterText = scopedLineText.substr(0, range.startColumn - 1 - scopedLineTokens.firstCharOffset); @@ -492,6 +492,47 @@ export class LanguageConfigurationRegistryImpl { afterEnter: afterEnterIndent }; } + + /** + * We should always allow intentional indentation. It means, if users change the indentation of `lineNumber` and the content of + * this line doesn't match decreaseIndentPattern, we should not adjust the indentation. + */ + public getIndentActionForType(model: ITokenizedModel, lineNumber: number, column: number, ch: string, indentConverter: any): string { + let maxColumn = model.getLineMaxColumn(lineNumber); + // let indentation = this.getIndentationAtPosition(model, lineNumber, column); + + let scopedLineTokens = this.getScopedLineTokens(model, lineNumber, maxColumn); + let indentRulesSupport = this._getIndentRulesSupport(scopedLineTokens.languageId); + if (!indentRulesSupport) { + return null; + } + + let scopedLineText = scopedLineTokens.getLineContent(); + let beforeTypeText = scopedLineText.substr(0, column - 1); + let afterTypeText = scopedLineText.substr(column - 1); + + if (indentRulesSupport.shouldDecrease(beforeTypeText + ch + afterTypeText)) { + // after typing `ch`, the content matches decreaseIndentPattern, we should adjust the indent to a good manner. + // 1. Get inherited indent action + let r = this.getInheritIndentForLine(model, lineNumber, false); + if (!r) { + return null; + } + + let indentation = r.indentation; + + if (r.action !== IndentAction.Indent) { + indentation = indentConverter.unshiftIndent(indentation); + } + + return indentation; + } + + return null; + } + + // end Indent Rules + // begin onEnter private _getOnEnterSupport(languageId: LanguageId): OnEnterSupport { @@ -535,11 +576,11 @@ export class LanguageConfigurationRegistryImpl { if (lineNumber > 1 && scopedLineTokens.firstCharOffset === 0) { // This is not the first line and the entire line belongs to this mode let oneLineAboveScopedLineTokens = this.getScopedLineTokens(model, lineNumber - 1); - if (oneLineAboveScopedLineTokens.languageId === scopedLineTokens.languageId) { - // The line above ends with text belonging to the same mode - oneLineAboveText = oneLineAboveScopedLineTokens.getLineContent(); - } + if (oneLineAboveScopedLineTokens.languageId === scopedLineTokens.languageId) { + // The line above ends with text belonging to the same mode + oneLineAboveText = oneLineAboveScopedLineTokens.getLineContent(); } + } let enterResult: EnterAction = null; try { @@ -561,8 +602,8 @@ export class LanguageConfigurationRegistryImpl { } else { enterResult.appendText = ''; } - } } + } if (enterResult.removeText) { indentation = indentation.substring(0, indentation.length - enterResult.removeText); -- GitLab From e82a1bef993a7499af90d2a1aa1735fd524af348 Mon Sep 17 00:00:00 2001 From: rebornix Date: Thu, 8 Jun 2017 18:16:53 -0700 Subject: [PATCH 0975/1347] AutoIndent: Type supports selection. --- .../common/controller/cursorTypeOperations.ts | 17 +++++++-------- .../modes/languageConfigurationRegistry.ts | 21 ++++++++++++------- 2 files changed, 21 insertions(+), 17 deletions(-) diff --git a/src/vs/editor/common/controller/cursorTypeOperations.ts b/src/vs/editor/common/controller/cursorTypeOperations.ts index d10b0d5951c..7f57c9f51f8 100644 --- a/src/vs/editor/common/controller/cursorTypeOperations.ts +++ b/src/vs/editor/common/controller/cursorTypeOperations.ts @@ -322,10 +322,9 @@ export class TypeOperations { } } - private static _runAutoIndentType(config: CursorConfiguration, model: ITokenizedModel, selections: Selection[], ch: string): ICommand { - let selection = selections[0]; - let currentIndentation = LanguageConfigurationRegistry.getIndentationAtPosition(model, selection.startLineNumber, selection.startColumn); - let actualIndentation = LanguageConfigurationRegistry.getIndentActionForType(model, selections[0].startLineNumber, selections[0].startColumn, ch, { + private static _runAutoIndentType(config: CursorConfiguration, model: ITokenizedModel, range: Range, ch: string): ICommand { + let currentIndentation = LanguageConfigurationRegistry.getIndentationAtPosition(model, range.startLineNumber, range.startColumn); + let actualIndentation = LanguageConfigurationRegistry.getIndentActionForType(model, range, ch, { shiftIndent: (indentation) => { return TypeOperations.shiftIndent(config, indentation); }, @@ -339,18 +338,18 @@ export class TypeOperations { } if (actualIndentation !== config.normalizeIndentation(currentIndentation)) { - let firstNonWhitespace = model.getLineFirstNonWhitespaceColumn(selection.startLineNumber); + let firstNonWhitespace = model.getLineFirstNonWhitespaceColumn(range.startLineNumber); if (firstNonWhitespace === 0) { return TypeOperations._typeCommand( - new Range(selection.startLineNumber, 0, selection.startLineNumber, selection.startColumn), + new Range(range.startLineNumber, 0, range.endLineNumber, range.endColumn), actualIndentation + ch, false ); } else { return TypeOperations._typeCommand( - new Range(selection.startLineNumber, 0, selection.startLineNumber, selection.startColumn), + new Range(range.startLineNumber, 0, range.endLineNumber, range.endColumn), actualIndentation + - model.getLineContent(selection.startLineNumber).substring(firstNonWhitespace - 1, selection.startColumn) + ch, + model.getLineContent(range.startLineNumber).substring(firstNonWhitespace - 1, range.startColumn - 1) + ch, false ); } @@ -596,7 +595,7 @@ export class TypeOperations { }); } - let indentCommand = this._runAutoIndentType(config, model, selections, ch); + let indentCommand = this._runAutoIndentType(config, model, selections[0], ch); if (indentCommand) { return new EditOperationResult([indentCommand], { shouldPushStackElementBefore: true, diff --git a/src/vs/editor/common/modes/languageConfigurationRegistry.ts b/src/vs/editor/common/modes/languageConfigurationRegistry.ts index c15da62eb22..2c9d960febc 100644 --- a/src/vs/editor/common/modes/languageConfigurationRegistry.ts +++ b/src/vs/editor/common/modes/languageConfigurationRegistry.ts @@ -497,24 +497,29 @@ export class LanguageConfigurationRegistryImpl { * We should always allow intentional indentation. It means, if users change the indentation of `lineNumber` and the content of * this line doesn't match decreaseIndentPattern, we should not adjust the indentation. */ - public getIndentActionForType(model: ITokenizedModel, lineNumber: number, column: number, ch: string, indentConverter: any): string { - let maxColumn = model.getLineMaxColumn(lineNumber); - // let indentation = this.getIndentationAtPosition(model, lineNumber, column); - - let scopedLineTokens = this.getScopedLineTokens(model, lineNumber, maxColumn); + public getIndentActionForType(model: ITokenizedModel, range: Range, ch: string, indentConverter: any): string { + let scopedLineTokens = this.getScopedLineTokens(model, range.startLineNumber, range.startColumn); let indentRulesSupport = this._getIndentRulesSupport(scopedLineTokens.languageId); if (!indentRulesSupport) { return null; } let scopedLineText = scopedLineTokens.getLineContent(); - let beforeTypeText = scopedLineText.substr(0, column - 1); - let afterTypeText = scopedLineText.substr(column - 1); + let beforeTypeText = scopedLineText.substr(0, range.startColumn - 1 - scopedLineTokens.firstCharOffset); + let afterTypeText; + + // selection support + if (range.isEmpty()) { + afterTypeText = scopedLineText.substr(range.startColumn - 1 - scopedLineTokens.firstCharOffset); + } else { + const endScopedLineTokens = this.getScopedLineTokens(model, range.endLineNumber, range.endColumn); + afterTypeText = endScopedLineTokens.getLineContent().substr(range.endColumn - 1 - scopedLineTokens.firstCharOffset); + } if (indentRulesSupport.shouldDecrease(beforeTypeText + ch + afterTypeText)) { // after typing `ch`, the content matches decreaseIndentPattern, we should adjust the indent to a good manner. // 1. Get inherited indent action - let r = this.getInheritIndentForLine(model, lineNumber, false); + let r = this.getInheritIndentForLine(model, range.startLineNumber, false); if (!r) { return null; } -- GitLab From 89a4f7a69ac9a7bbc75482951082b10c69dc6f4a Mon Sep 17 00:00:00 2001 From: rebornix Date: Thu, 8 Jun 2017 18:32:31 -0700 Subject: [PATCH 0976/1347] AutoIndent: Type, put this feature behind a flag. --- .../editor/common/config/commonEditorConfig.ts | 5 +++++ src/vs/editor/common/config/editorOptions.ts | 16 ++++++++++++++++ src/vs/editor/common/controller/cursorCommon.ts | 2 ++ .../common/controller/cursorTypeOperations.ts | 14 ++++++++------ src/vs/monaco.d.ts | 7 +++++++ .../platform/telemetry/common/telemetryUtils.ts | 1 + 6 files changed, 39 insertions(+), 6 deletions(-) diff --git a/src/vs/editor/common/config/commonEditorConfig.ts b/src/vs/editor/common/config/commonEditorConfig.ts index 9dc377162fd..a13fd48f5a7 100644 --- a/src/vs/editor/common/config/commonEditorConfig.ts +++ b/src/vs/editor/common/config/commonEditorConfig.ts @@ -401,6 +401,11 @@ const editorConfiguration: IConfigurationNode = { 'default': EDITOR_DEFAULTS.contribInfo.formatOnPaste, 'description': nls.localize('formatOnPaste', "Controls if the editor should automatically format the pasted content. A formatter must be available and the formatter should be able to format a range in a document.") }, + 'editor.autoIndent': { + 'type': 'boolean', + 'default': EDITOR_DEFAULTS.autoIndent, + 'description': nls.localize('autoIndent', "Controls if the editor should automatically adjust the indenation when users type. Indentation Rules of the language must be available. ") + }, 'editor.suggestOnTriggerCharacters': { 'type': 'boolean', 'default': EDITOR_DEFAULTS.contribInfo.suggestOnTriggerCharacters, diff --git a/src/vs/editor/common/config/editorOptions.ts b/src/vs/editor/common/config/editorOptions.ts index 9835b48bc22..53ad5cbc7a2 100644 --- a/src/vs/editor/common/config/editorOptions.ts +++ b/src/vs/editor/common/config/editorOptions.ts @@ -376,6 +376,11 @@ export interface IEditorOptions { * Defaults to true. */ autoClosingBrackets?: boolean; + /** + * Enable auto indentation adjustment. + * Defaults to false. + */ + autoIndent?: boolean; /** * Enable format on type. * Defaults to false. @@ -803,6 +808,7 @@ export interface IValidatedEditorOptions { readonly wordWrapBreakAfterCharacters: string; readonly wordWrapBreakObtrusiveCharacters: string; readonly autoClosingBrackets: boolean; + readonly autoIndent: boolean; readonly dragAndDrop: boolean; readonly emptySelectionClipboard: boolean; readonly useTabStops: boolean; @@ -833,6 +839,7 @@ export class InternalEditorOptions { // ---- cursor options readonly wordSeparators: string; readonly autoClosingBrackets: boolean; + readonly autoIndent: boolean; readonly useTabStops: boolean; readonly tabFocusMode: boolean; readonly dragAndDrop: boolean; @@ -858,6 +865,7 @@ export class InternalEditorOptions { multiCursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; wordSeparators: string; autoClosingBrackets: boolean; + autoIndent: boolean; useTabStops: boolean; tabFocusMode: boolean; dragAndDrop: boolean; @@ -877,6 +885,7 @@ export class InternalEditorOptions { this.multiCursorModifier = source.multiCursorModifier; this.wordSeparators = source.wordSeparators; this.autoClosingBrackets = source.autoClosingBrackets; + this.autoIndent = source.autoIndent; this.useTabStops = source.useTabStops; this.tabFocusMode = source.tabFocusMode; this.dragAndDrop = source.dragAndDrop; @@ -902,6 +911,7 @@ export class InternalEditorOptions { && this.multiCursorModifier === other.multiCursorModifier && this.wordSeparators === other.wordSeparators && this.autoClosingBrackets === other.autoClosingBrackets + && this.autoIndent === other.autoIndent && this.useTabStops === other.useTabStops && this.tabFocusMode === other.tabFocusMode && this.dragAndDrop === other.dragAndDrop @@ -928,6 +938,7 @@ export class InternalEditorOptions { multiCursorModifier: (this.multiCursorModifier !== newOpts.multiCursorModifier), wordSeparators: (this.wordSeparators !== newOpts.wordSeparators), autoClosingBrackets: (this.autoClosingBrackets !== newOpts.autoClosingBrackets), + autoIndent: (this.autoIndent !== newOpts.autoIndent), useTabStops: (this.useTabStops !== newOpts.useTabStops), tabFocusMode: (this.tabFocusMode !== newOpts.tabFocusMode), dragAndDrop: (this.dragAndDrop !== newOpts.dragAndDrop), @@ -1268,6 +1279,7 @@ export interface IConfigurationChangedEvent { readonly multiCursorModifier: boolean; readonly wordSeparators: boolean; readonly autoClosingBrackets: boolean; + readonly autoIndent: boolean; readonly useTabStops: boolean; readonly tabFocusMode: boolean; readonly dragAndDrop: boolean; @@ -1445,6 +1457,7 @@ export class EditorOptionsValidator { wordWrapBreakAfterCharacters: _string(opts.wordWrapBreakAfterCharacters, defaults.wordWrapBreakAfterCharacters), wordWrapBreakObtrusiveCharacters: _string(opts.wordWrapBreakObtrusiveCharacters, defaults.wordWrapBreakObtrusiveCharacters), autoClosingBrackets: _boolean(opts.autoClosingBrackets, defaults.autoClosingBrackets), + autoIndent: _boolean(opts.autoIndent, defaults.autoIndent), dragAndDrop: _boolean(opts.dragAndDrop, defaults.dragAndDrop), emptySelectionClipboard: _boolean(opts.emptySelectionClipboard, defaults.emptySelectionClipboard), useTabStops: _boolean(opts.useTabStops, defaults.useTabStops), @@ -1670,6 +1683,7 @@ export class InternalEditorOptionsFactory { wordWrapBreakAfterCharacters: opts.wordWrapBreakAfterCharacters, wordWrapBreakObtrusiveCharacters: opts.wordWrapBreakObtrusiveCharacters, autoClosingBrackets: opts.autoClosingBrackets, + autoIndent: opts.autoIndent, dragAndDrop: opts.dragAndDrop, emptySelectionClipboard: opts.emptySelectionClipboard, useTabStops: opts.useTabStops, @@ -1876,6 +1890,7 @@ export class InternalEditorOptionsFactory { multiCursorModifier: opts.multiCursorModifier, wordSeparators: opts.wordSeparators, autoClosingBrackets: opts.autoClosingBrackets, + autoIndent: opts.autoIndent, useTabStops: opts.useTabStops, tabFocusMode: opts.readOnly ? true : env.tabFocusMode, dragAndDrop: opts.dragAndDrop, @@ -2089,6 +2104,7 @@ export const EDITOR_DEFAULTS: IValidatedEditorOptions = { wordWrapBreakAfterCharacters: ' \t})]?|&,;¢°′″‰℃ã€ã€‚。、¢,.:;?ï¼ï¼…・・ã‚ゞヽヾーァィゥェォッャュョヮヵヶããƒã…ã‡ã‰ã£ã‚ƒã‚…ょゎゕゖㇰㇱㇲㇳㇴㇵㇶㇷㇸㇹㇺㇻㇼㇽㇾㇿ々〻ァィゥェォャュョッー’â€ã€‰ã€‹ã€ã€ã€‘〕)]ï½ï½£', wordWrapBreakObtrusiveCharacters: '.', autoClosingBrackets: true, + autoIndent: false, dragAndDrop: true, emptySelectionClipboard: true, useTabStops: true, diff --git a/src/vs/editor/common/controller/cursorCommon.ts b/src/vs/editor/common/controller/cursorCommon.ts index 55e00ad1e43..eb7b3771964 100644 --- a/src/vs/editor/common/controller/cursorCommon.ts +++ b/src/vs/editor/common/controller/cursorCommon.ts @@ -64,6 +64,7 @@ export class CursorConfiguration { public readonly wordSeparators: string; public readonly emptySelectionClipboard: boolean; public readonly autoClosingBrackets: boolean; + public readonly autoIndent: boolean; public readonly autoClosingPairsOpen: CharacterMap; public readonly autoClosingPairsClose: CharacterMap; public readonly surroundingPairs: CharacterMap; @@ -99,6 +100,7 @@ export class CursorConfiguration { this.wordSeparators = c.wordSeparators; this.emptySelectionClipboard = c.emptySelectionClipboard; this.autoClosingBrackets = c.autoClosingBrackets; + this.autoIndent = c.autoIndent; this.autoClosingPairsOpen = {}; this.autoClosingPairsClose = {}; diff --git a/src/vs/editor/common/controller/cursorTypeOperations.ts b/src/vs/editor/common/controller/cursorTypeOperations.ts index 7f57c9f51f8..f57b2076589 100644 --- a/src/vs/editor/common/controller/cursorTypeOperations.ts +++ b/src/vs/editor/common/controller/cursorTypeOperations.ts @@ -595,12 +595,14 @@ export class TypeOperations { }); } - let indentCommand = this._runAutoIndentType(config, model, selections[0], ch); - if (indentCommand) { - return new EditOperationResult([indentCommand], { - shouldPushStackElementBefore: true, - shouldPushStackElementAfter: false, - }); + if (config.autoIndent) { + let indentCommand = this._runAutoIndentType(config, model, selections[0], ch); + if (indentCommand) { + return new EditOperationResult([indentCommand], { + shouldPushStackElementBefore: true, + shouldPushStackElementAfter: false, + }); + } } if (this._isAutoClosingCloseCharType(config, model, selections, ch)) { diff --git a/src/vs/monaco.d.ts b/src/vs/monaco.d.ts index 5dddf0d0f3d..6a801403e30 100644 --- a/src/vs/monaco.d.ts +++ b/src/vs/monaco.d.ts @@ -2926,6 +2926,11 @@ declare module monaco.editor { * Defaults to true. */ autoClosingBrackets?: boolean; + /** + * Enable auto indentation adjustment. + * Defaults to false. + */ + autoIndent?: boolean; /** * Enable format on type. * Defaults to false. @@ -3284,6 +3289,7 @@ declare module monaco.editor { readonly multiCursorModifier: 'altKey' | 'ctrlKey' | 'metaKey'; readonly wordSeparators: string; readonly autoClosingBrackets: boolean; + readonly autoIndent: boolean; readonly useTabStops: boolean; readonly tabFocusMode: boolean; readonly dragAndDrop: boolean; @@ -3416,6 +3422,7 @@ declare module monaco.editor { readonly multiCursorModifier: boolean; readonly wordSeparators: boolean; readonly autoClosingBrackets: boolean; + readonly autoIndent: boolean; readonly useTabStops: boolean; readonly tabFocusMode: boolean; readonly dragAndDrop: boolean; diff --git a/src/vs/platform/telemetry/common/telemetryUtils.ts b/src/vs/platform/telemetry/common/telemetryUtils.ts index 516a0320f0a..4a8231e3d3a 100644 --- a/src/vs/platform/telemetry/common/telemetryUtils.ts +++ b/src/vs/platform/telemetry/common/telemetryUtils.ts @@ -219,6 +219,7 @@ const configurationValueWhitelist = [ 'editor.quickSuggestionsDelay', 'editor.parameterHints', 'editor.autoClosingBrackets', + 'editor.autoindent', 'editor.formatOnType', 'editor.formatOnPaste', 'editor.suggestOnTriggerCharacters', -- GitLab From 0b80802df6205dc9fac604e5e48e9754ffa31bfa Mon Sep 17 00:00:00 2001 From: rebornix Date: Fri, 9 Jun 2017 15:41:26 -0700 Subject: [PATCH 0977/1347] AutoIndent: MoveLines, draft version, it already works but have potential bugs. --- .../modes/languageConfigurationRegistry.ts | 27 +++ .../linesOperations/common/linesOperations.ts | 3 +- .../common/moveLinesCommand.ts | 166 +++++++++++++++++- 3 files changed, 192 insertions(+), 4 deletions(-) diff --git a/src/vs/editor/common/modes/languageConfigurationRegistry.ts b/src/vs/editor/common/modes/languageConfigurationRegistry.ts index 2c9d960febc..e7d63e773a5 100644 --- a/src/vs/editor/common/modes/languageConfigurationRegistry.ts +++ b/src/vs/editor/common/modes/languageConfigurationRegistry.ts @@ -417,6 +417,33 @@ export class LanguageConfigurationRegistryImpl { } } + public getGoodIndentForLine(virtualModel: IVirtualModel, languageId: LanguageId, lineNumber: number, indentConverter: any): string { + let indentRulesSupport = this._getIndentRulesSupport(languageId); + if (!indentRulesSupport) { + return null; + } + + let indent = this.getInheritIndentForLine(virtualModel, lineNumber); + let lineContent = virtualModel.getLineContent(lineNumber); + + if (indent) { + if (indentRulesSupport.shouldDecrease(lineContent)) { + if (indent.action === IndentAction.Indent) { + return indent.indentation; + } else { + return indentConverter.unshiftIndent(indent.indentation); + } + } else { + if (indent.action === IndentAction.Indent) { + return indentConverter.shiftIndent(indent.indentation); + } else { + return indent.indentation; + } + } + } + return null; + } + public getIndentForEnter(model: ITokenizedModel, range: Range, indentConverter: any): { beforeEnter: string, afterEnter: string } { let scopedLineTokens = this.getScopedLineTokens(model, range.startLineNumber, range.startColumn); let scopedLineText = scopedLineTokens.getLineContent(); diff --git a/src/vs/editor/contrib/linesOperations/common/linesOperations.ts b/src/vs/editor/contrib/linesOperations/common/linesOperations.ts index a41829a885b..3c5229de450 100644 --- a/src/vs/editor/contrib/linesOperations/common/linesOperations.ts +++ b/src/vs/editor/contrib/linesOperations/common/linesOperations.ts @@ -96,9 +96,10 @@ abstract class AbstractMoveLinesAction extends EditorAction { var commands: ICommand[] = []; var selections = editor.getSelections(); + var autoIndent = editor.getConfiguration().autoIndent; for (var i = 0; i < selections.length; i++) { - commands.push(new MoveLinesCommand(selections[i], this.down)); + commands.push(new MoveLinesCommand(selections[i], this.down, autoIndent)); } editor.pushUndoStop(); diff --git a/src/vs/editor/contrib/linesOperations/common/moveLinesCommand.ts b/src/vs/editor/contrib/linesOperations/common/moveLinesCommand.ts index 43ed98d212d..ef64aba88b2 100644 --- a/src/vs/editor/contrib/linesOperations/common/moveLinesCommand.ts +++ b/src/vs/editor/contrib/linesOperations/common/moveLinesCommand.ts @@ -4,21 +4,26 @@ *--------------------------------------------------------------------------------------------*/ 'use strict'; +import * as strings from 'vs/base/common/strings'; import { Range } from 'vs/editor/common/core/range'; import { Selection } from 'vs/editor/common/core/selection'; import { ICommand, ICursorStateComputerData, IEditOperationBuilder, ITokenizedModel } from 'vs/editor/common/editorCommon'; +import { LanguageConfigurationRegistry } from 'vs/editor/common/modes/languageConfigurationRegistry'; +import { ShiftCommand } from 'vs/editor/common/commands/shiftCommand'; export class MoveLinesCommand implements ICommand { private _selection: Selection; private _isMovingDown: boolean; + private _autoIndent: boolean; private _selectionId: string; private _moveEndPositionDown: boolean; - constructor(selection: Selection, isMovingDown: boolean) { + constructor(selection: Selection, isMovingDown: boolean, autoIndent: boolean) { this._selection = selection; this._isMovingDown = isMovingDown; + this._autoIndent = autoIndent; } public getEditOperations(model: ITokenizedModel, builder: IEditOperationBuilder): void { @@ -40,6 +45,41 @@ export class MoveLinesCommand implements ICommand { s = s.setEndPosition(s.endLineNumber - 1, model.getLineMaxColumn(s.endLineNumber - 1)); } + let tabSize = model.getOptions().tabSize; + let insertSpaces = model.getOptions().insertSpaces; + let indentConverter = { + shiftIndent: (indentation) => { + let desiredIndentCount = ShiftCommand.shiftIndentCount(indentation, indentation.length + 1, tabSize); + let newIndentation = ''; + for (let i = 0; i < desiredIndentCount; i++) { + newIndentation += '\t'; + } + + return newIndentation; + }, + unshiftIndent: (indentation) => { + let desiredIndentCount = ShiftCommand.unshiftIndentCount(indentation, indentation.length + 1, tabSize); + let newIndentation = ''; + for (let i = 0; i < desiredIndentCount; i++) { + newIndentation += '\t'; + } + + return newIndentation; + } + }; + let virtualModel = { + getLineTokens: (lineNumber: number) => { + return model.getLineTokens(lineNumber); + }, + getLanguageIdentifier: () => { + return model.getLanguageIdentifier(); + }, + getLanguageIdAtPosition: (lineNumber: number, column: number) => { + return model.getLanguageIdAtPosition(lineNumber, column); + }, + getLineContent: null + }; + if (s.startLineNumber === s.endLineNumber && model.getLineMaxColumn(s.startLineNumber) === 1) { // Current line is empty var lineNumber = s.startLineNumber; @@ -67,12 +107,67 @@ export class MoveLinesCommand implements ICommand { if (this._isMovingDown) { movingLineNumber = s.endLineNumber + 1; movingLineText = model.getLineContent(movingLineNumber); - // Delete line that needs to be moved builder.addEditOperation(new Range(movingLineNumber - 1, model.getLineMaxColumn(movingLineNumber - 1), movingLineNumber, model.getLineMaxColumn(movingLineNumber)), null); + let insertingText = movingLineText; // Insert line that needs to be moved before - builder.addEditOperation(new Range(s.startLineNumber, 1, s.startLineNumber, 1), movingLineText + '\n'); + + if (this._autoIndent) { + virtualModel.getLineContent = (lineNumber) => { + if (lineNumber === s.startLineNumber) { + return model.getLineContent(movingLineNumber); + } else { + return model.getLineContent(lineNumber); + } + }; + let newIndentation = LanguageConfigurationRegistry.getGoodIndentForLine(virtualModel, model.getLanguageIdAtPosition( + movingLineNumber, 1), s.startLineNumber, indentConverter); + if (newIndentation !== null) { + let oldIndentation = strings.getLeadingWhitespace(model.getLineContent(movingLineNumber)); + let newSpaceCnt = this.getSpaceCnt(newIndentation, tabSize); + let oldSpaceCnt = this.getSpaceCnt(oldIndentation, tabSize); + if (newSpaceCnt !== oldSpaceCnt) { + let newIndentation = this.generateIndent(newSpaceCnt, tabSize, insertSpaces); + insertingText = newIndentation + strings.ltrim(strings.ltrim(movingLineText), '\t'); + } + } + + virtualModel.getLineContent = (lineNumber) => { + if (lineNumber === s.startLineNumber) { + return insertingText; + } else if (lineNumber >= s.startLineNumber + 1 && lineNumber <= s.endLineNumber + 1) { + return model.getLineContent(lineNumber - 1); + } else { + return model.getLineContent(lineNumber); + } + }; + + let newIndentationForMovingBlock = LanguageConfigurationRegistry.getGoodIndentForLine(virtualModel, model.getLanguageIdAtPosition( + movingLineNumber, 1), s.startLineNumber + 1, indentConverter); + + if (newIndentationForMovingBlock !== null) { + let oldIndentation = strings.getLeadingWhitespace(model.getLineContent(s.startLineNumber)); + let newSpaceCnt = this.getSpaceCnt(newIndentationForMovingBlock, tabSize); + let oldSpaceCnt = this.getSpaceCnt(oldIndentation, tabSize); + if (newSpaceCnt !== oldSpaceCnt) { + let spaceCntOffset = newSpaceCnt - oldSpaceCnt; + + for (let i = s.startLineNumber; i <= s.endLineNumber; i++) { + let lineContent = model.getLineContent(i); + let originalIndent = strings.getLeadingWhitespace(lineContent); + let originalSpacesCnt = this.getSpaceCnt(originalIndent, tabSize); + let newSpacesCnt = originalSpacesCnt + spaceCntOffset; + let newIndent = this.generateIndent(newSpacesCnt, tabSize, insertSpaces); + + if (newIndent !== originalIndent) { + builder.addEditOperation(new Range(i, 1, i, originalIndent.length + 1), newIndent); + } + } + } + } + } + builder.addEditOperation(new Range(s.startLineNumber, 1, s.startLineNumber, 1), insertingText + '\n'); } else { movingLineNumber = s.startLineNumber - 1; movingLineText = model.getLineContent(movingLineNumber); @@ -82,12 +177,77 @@ export class MoveLinesCommand implements ICommand { // Insert line that needs to be moved after builder.addEditOperation(new Range(s.endLineNumber, model.getLineMaxColumn(s.endLineNumber), s.endLineNumber, model.getLineMaxColumn(s.endLineNumber)), '\n' + movingLineText); + + if (this._autoIndent && (model.getLanguageIdAtPosition(s.startLineNumber, 1) === model.getLanguageIdAtPosition(s.endLineNumber, 1))) { + virtualModel.getLineContent = (lineNumber: number) => { + if (lineNumber === movingLineNumber) { + return model.getLineContent(s.startLineNumber); + } else { + return model.getLineContent(lineNumber); + } + }; + let newIndentation = LanguageConfigurationRegistry.getGoodIndentForLine(virtualModel, model.getLanguageIdAtPosition(s.startLineNumber, 1), movingLineNumber, indentConverter); + if (newIndentation !== null) { + // adjust the indentation of the moving block + let oldIndentation = strings.getLeadingWhitespace(model.getLineContent(s.startLineNumber)); + let newSpaceCnt = this.getSpaceCnt(newIndentation, tabSize); + let oldSpaceCnt = this.getSpaceCnt(oldIndentation, tabSize); + if (newSpaceCnt !== oldSpaceCnt) { + let spaceCntOffset = newSpaceCnt - oldSpaceCnt; + + for (let i = s.startLineNumber; i <= s.endLineNumber; i++) { + let lineContent = model.getLineContent(i); + let originalIndent = strings.getLeadingWhitespace(lineContent); + let originalSpacesCnt = this.getSpaceCnt(originalIndent, tabSize); + let newSpacesCnt = originalSpacesCnt + spaceCntOffset; + let newIndent = this.generateIndent(newSpacesCnt, tabSize, insertSpaces); + + if (newIndent !== originalIndent) { + builder.addEditOperation(new Range(i, 1, i, originalIndent.length + 1), newIndent); + } + } + } + } + } } } this._selectionId = builder.trackSelection(s); } + private getSpaceCnt(str, tabSize) { + let spacesCnt = 0; + + for (let i = 0; i < str.length; i++) { + if (str.charAt(i) === '\t') { + spacesCnt += tabSize; + } else { + spacesCnt++; + } + } + + return spacesCnt; + } + + private generateIndent(spacesCnt: number, tabSize, insertSpaces) { + spacesCnt = spacesCnt < 0 ? 0 : spacesCnt; + + let result = ''; + if (!insertSpaces) { + let tabsCnt = Math.floor(spacesCnt / tabSize); + spacesCnt = spacesCnt % tabSize; + for (let i = 0; i < tabsCnt; i++) { + result += '\t'; + } + } + + for (let i = 0; i < spacesCnt; i++) { + result += ' '; + } + + return result; + } + public computeCursorState(model: ITokenizedModel, helper: ICursorStateComputerData): Selection { var result = helper.getTrackedSelection(this._selectionId); -- GitLab From ed09ea34f9cb5908940853cd25f9c0f3acae504d Mon Sep 17 00:00:00 2001 From: rebornix Date: Fri, 9 Jun 2017 16:53:10 -0700 Subject: [PATCH 0978/1347] AutoIndent: Indent on paste --- .../contrib/indentation/common/indentation.ts | 233 +++++++++++++++++- 1 file changed, 231 insertions(+), 2 deletions(-) diff --git a/src/vs/editor/contrib/indentation/common/indentation.ts b/src/vs/editor/contrib/indentation/common/indentation.ts index 7fb494c770d..d9c270f2464 100644 --- a/src/vs/editor/contrib/indentation/common/indentation.ts +++ b/src/vs/editor/contrib/indentation/common/indentation.ts @@ -4,11 +4,12 @@ *--------------------------------------------------------------------------------------------*/ import * as nls from 'vs/nls'; +import { IDisposable, dispose } from 'vs/base/common/lifecycle'; import { TPromise } from 'vs/base/common/winjs.base'; import * as strings from 'vs/base/common/strings'; -import { ICommonCodeEditor, IIdentifiedSingleEditOperation, ICommand, ICursorStateComputerData, IEditOperationBuilder, ITokenizedModel } from 'vs/editor/common/editorCommon'; +import { ICommonCodeEditor, IEditorContribution, IIdentifiedSingleEditOperation, ICommand, ICursorStateComputerData, IEditOperationBuilder, ITokenizedModel, EndOfLineSequence } from 'vs/editor/common/editorCommon'; import { EditorContextKeys } from 'vs/editor/common/editorContextKeys'; -import { editorAction, ServicesAccessor, IActionOptions, EditorAction } from 'vs/editor/common/editorCommonExtensions'; +import { editorAction, ServicesAccessor, IActionOptions, EditorAction, commonEditorContribution } from 'vs/editor/common/editorCommonExtensions'; import { IQuickOpenService } from 'vs/platform/quickOpen/common/quickOpen'; import { IModelService } from 'vs/editor/common/services/modelService'; import { Range } from 'vs/editor/common/core/range'; @@ -17,6 +18,7 @@ import { EditOperation } from 'vs/editor/common/core/editOperation'; import { TextModel } from 'vs/editor/common/model/textModel'; import { LanguageConfigurationRegistry } from 'vs/editor/common/modes/languageConfigurationRegistry'; import { ShiftCommand } from 'vs/editor/common/commands/shiftCommand'; +import { TextEdit } from 'vs/editor/common/modes'; export function shiftIndent(tabSize: number, indentation: string, count?: number): string { count = count || 1; @@ -325,6 +327,233 @@ export class ReindentLinesAction extends EditorAction { } } +export class AutoIndentOnPasteCommand implements ICommand { + + private _edits: TextEdit[]; + private _newEol: EndOfLineSequence; + + private _initialSelection: Selection; + private _selectionId: string; + + constructor(edits: TextEdit[], initialSelection: Selection) { + this._initialSelection = initialSelection; + this._edits = []; + this._newEol = undefined; + + for (let edit of edits) { + if (typeof edit.eol === 'number') { + this._newEol = edit.eol; + } + if (edit.range && typeof edit.text === 'string') { + this._edits.push(edit); + } + } + } + + public getEditOperations(model: ITokenizedModel, builder: IEditOperationBuilder): void { + for (let edit of this._edits) { + builder.addEditOperation(Range.lift(edit.range), edit.text); + } + + var selectionIsSet = false; + if (Array.isArray(this._edits) && this._edits.length === 1 && this._initialSelection.isEmpty()) { + if (this._edits[0].range.startColumn === this._initialSelection.endColumn && + this._edits[0].range.startLineNumber === this._initialSelection.endLineNumber) { + selectionIsSet = true; + this._selectionId = builder.trackSelection(this._initialSelection, true); + } else if (this._edits[0].range.endColumn === this._initialSelection.startColumn && + this._edits[0].range.endLineNumber === this._initialSelection.startLineNumber) { + selectionIsSet = true; + this._selectionId = builder.trackSelection(this._initialSelection, false); + } + } + + if (!selectionIsSet) { + this._selectionId = builder.trackSelection(this._initialSelection); + } + } + + public computeCursorState(model: ITokenizedModel, helper: ICursorStateComputerData): Selection { + return helper.getTrackedSelection(this._selectionId); + } +} + +@commonEditorContribution +export class AutoIndentOnPaste implements IEditorContribution { + private static ID = 'editor.contrib.autoIndentOnPaste'; + + private editor: ICommonCodeEditor; + private callOnDispose: IDisposable[]; + private callOnModel: IDisposable[]; + + constructor(editor: ICommonCodeEditor) { + this.editor = editor; + this.callOnDispose = []; + this.callOnModel = []; + + this.callOnDispose.push(editor.onDidChangeConfiguration(() => this.update())); + this.callOnDispose.push(editor.onDidChangeModel(() => this.update())); + this.callOnDispose.push(editor.onDidChangeModelLanguage(() => this.update())); + } + + private update(): void { + + // clean up + this.callOnModel = dispose(this.callOnModel); + + // we are disabled + if (!this.editor.getConfiguration().autoIndent) { + return; + } + + // no model + if (!this.editor.getModel()) { + return; + } + + this.callOnModel.push(this.editor.onDidPaste((range: Range) => { + this.trigger(range); + })); + } + + private trigger(range: Range): void { + if (this.editor.getSelections().length > 1) { + return; + } + + const model = this.editor.getModel(); + const { tabSize, insertSpaces } = model.getOptions(); + this.editor.pushUndoStop(); + let textEdits: TextEdit[] = []; + + let indentConverter = { + shiftIndent: (indentation) => { + let desiredIndentCount = ShiftCommand.shiftIndentCount(indentation, indentation.length + 1, tabSize); + let newIndentation = ''; + for (let i = 0; i < desiredIndentCount; i++) { + newIndentation += '\t'; + } + + return newIndentation; + }, + unshiftIndent: (indentation) => { + let desiredIndentCount = ShiftCommand.unshiftIndentCount(indentation, indentation.length + 1, tabSize); + let newIndentation = ''; + for (let i = 0; i < desiredIndentCount; i++) { + newIndentation += '\t'; + } + + return newIndentation; + } + }; + let indentOfFirstLine = LanguageConfigurationRegistry.getGoodIndentForLine(model, model.getLanguageIdentifier().id, range.startLineNumber, indentConverter); + + if (indentOfFirstLine !== null) { + let firstLineText = model.getLineContent(range.startLineNumber); + let oldIndentation = strings.getLeadingWhitespace(firstLineText); + let newSpaceCnt = this.getSpaceCnt(indentOfFirstLine, tabSize); + let oldSpaceCnt = this.getSpaceCnt(oldIndentation, tabSize); + + if (newSpaceCnt !== oldSpaceCnt) { + let newIndent = this.generateIndent(newSpaceCnt, tabSize, insertSpaces); + textEdits.push({ + range: new Range(range.startLineNumber, 1, range.startLineNumber, oldIndentation.length + 1), + text: newIndent + }); + firstLineText = newIndent + firstLineText.substr(oldIndentation.length + 1); + } + + if (range.startLineNumber !== range.endLineNumber) { + let virtualModel = { + getLineTokens: (lineNumber: number) => { + return model.getLineTokens(lineNumber); + }, + getLanguageIdentifier: () => { + return model.getLanguageIdentifier(); + }, + getLanguageIdAtPosition: (lineNumber: number, column: number) => { + return model.getLanguageIdAtPosition(lineNumber, column); + }, + getLineContent: (lineNumber) => { + if (lineNumber === range.startLineNumber) { + return firstLineText; + } else { + return model.getLineContent(lineNumber); + } + } + }; + let indentOfSecondLine = LanguageConfigurationRegistry.getGoodIndentForLine(virtualModel, model.getLanguageIdentifier().id, range.startLineNumber + 1, indentConverter); + let newSpaceCntOfSecondLine = this.getSpaceCnt(indentOfSecondLine, tabSize); + let oldSpaceCntOfSecondLine = this.getSpaceCnt(strings.getLeadingWhitespace(model.getLineContent(range.startLineNumber + 1)), tabSize); + + if (newSpaceCntOfSecondLine !== oldSpaceCntOfSecondLine) { + let spaceCntOffset = newSpaceCntOfSecondLine - oldSpaceCntOfSecondLine; + for (let i = range.startLineNumber + 1; i <= range.endLineNumber; i++) { + let lineContent = model.getLineContent(i); + let originalIndent = strings.getLeadingWhitespace(lineContent); + let originalSpacesCnt = this.getSpaceCnt(originalIndent, tabSize); + let newSpacesCnt = originalSpacesCnt + spaceCntOffset; + let newIndent = this.generateIndent(newSpacesCnt, tabSize, insertSpaces); + + if (newIndent !== originalIndent) { + textEdits.push({ + range: new Range(i, 1, i, originalIndent.length), + text: newIndent + }); + } + } + } + } + } + + let cmd = new AutoIndentOnPasteCommand(textEdits, this.editor.getSelection()); + this.editor.executeCommand('autoIndentOnPaste', cmd); + this.editor.pushUndoStop(); + } + + public getId(): string { + return AutoIndentOnPaste.ID; + } + + public dispose(): void { + this.callOnDispose = dispose(this.callOnDispose); + this.callOnModel = dispose(this.callOnModel); + } + + private getSpaceCnt(str, tabSize) { + let spacesCnt = 0; + + for (let i = 0; i < str.length; i++) { + if (str.charAt(i) === '\t') { + spacesCnt += tabSize; + } else { + spacesCnt++; + } + } + + return spacesCnt; + } + + private generateIndent(spacesCnt: number, tabSize, insertSpaces) { + spacesCnt = spacesCnt < 0 ? 0 : spacesCnt; + + let result = ''; + if (!insertSpaces) { + let tabsCnt = Math.floor(spacesCnt / tabSize); + spacesCnt = spacesCnt % tabSize; + for (let i = 0; i < tabsCnt; i++) { + result += '\t'; + } + } + + for (let i = 0; i < spacesCnt; i++) { + result += ' '; + } + + return result; + } +} + function getIndentationEditOperations(model: ITokenizedModel, builder: IEditOperationBuilder, tabSize: number, tabsToSpaces: boolean): void { if (model.getLineCount() === 1 && model.getLineMaxColumn(1) === 1) { // Model is empty -- GitLab From ca86a87726cf6ef8144cc64c7e2474c836ae005b Mon Sep 17 00:00:00 2001 From: rebornix Date: Sat, 10 Jun 2017 11:09:47 -0700 Subject: [PATCH 0979/1347] AutoIndent: Fix MoveLinesCommand test cases. --- .../linesOperations/test/common/moveLinesCommand.test.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/editor/contrib/linesOperations/test/common/moveLinesCommand.test.ts b/src/vs/editor/contrib/linesOperations/test/common/moveLinesCommand.test.ts index 429d896276e..31b2778901a 100644 --- a/src/vs/editor/contrib/linesOperations/test/common/moveLinesCommand.test.ts +++ b/src/vs/editor/contrib/linesOperations/test/common/moveLinesCommand.test.ts @@ -9,11 +9,11 @@ import { MoveLinesCommand } from 'vs/editor/contrib/linesOperations/common/moveL import { testCommand } from 'vs/editor/test/common/commands/commandTestUtils'; function testMoveLinesDownCommand(lines: string[], selection: Selection, expectedLines: string[], expectedSelection: Selection): void { - testCommand(lines, null, selection, (sel) => new MoveLinesCommand(sel, true), expectedLines, expectedSelection); + testCommand(lines, null, selection, (sel) => new MoveLinesCommand(sel, true, false), expectedLines, expectedSelection); } function testMoveLinesUpCommand(lines: string[], selection: Selection, expectedLines: string[], expectedSelection: Selection): void { - testCommand(lines, null, selection, (sel) => new MoveLinesCommand(sel, false), expectedLines, expectedSelection); + testCommand(lines, null, selection, (sel) => new MoveLinesCommand(sel, false, false), expectedLines, expectedSelection); } suite('Editor Contrib - Move Lines Command', () => { -- GitLab From fc326445becd7959b5d78a3de468015741a8c5b3 Mon Sep 17 00:00:00 2001 From: rebornix Date: Wed, 14 Jun 2017 13:20:38 -0700 Subject: [PATCH 0980/1347] AutoIndent on paste, remove all indent whitespaces. --- src/vs/editor/contrib/indentation/common/indentation.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/editor/contrib/indentation/common/indentation.ts b/src/vs/editor/contrib/indentation/common/indentation.ts index d9c270f2464..b44866fc582 100644 --- a/src/vs/editor/contrib/indentation/common/indentation.ts +++ b/src/vs/editor/contrib/indentation/common/indentation.ts @@ -497,7 +497,7 @@ export class AutoIndentOnPaste implements IEditorContribution { if (newIndent !== originalIndent) { textEdits.push({ - range: new Range(i, 1, i, originalIndent.length), + range: new Range(i, 1, i, originalIndent.length + 1), text: newIndent }); } -- GitLab From b59f98988ee46977dc4818f6527e3ae61efc00b4 Mon Sep 17 00:00:00 2001 From: rebornix Date: Wed, 14 Jun 2017 13:21:48 -0700 Subject: [PATCH 0981/1347] Make sure indent adjustment is executed on correct markers. --- .../contrib/linesOperations/common/moveLinesCommand.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/vs/editor/contrib/linesOperations/common/moveLinesCommand.ts b/src/vs/editor/contrib/linesOperations/common/moveLinesCommand.ts index ef64aba88b2..bf628c40a7d 100644 --- a/src/vs/editor/contrib/linesOperations/common/moveLinesCommand.ts +++ b/src/vs/editor/contrib/linesOperations/common/moveLinesCommand.ts @@ -133,6 +133,10 @@ export class MoveLinesCommand implements ICommand { } } + // add edit operations for moving line first to make sure it's executed after we make indentation change + // to s.startLineNumber + builder.addEditOperation(new Range(s.startLineNumber, 1, s.startLineNumber, 1), insertingText + '\n'); + virtualModel.getLineContent = (lineNumber) => { if (lineNumber === s.startLineNumber) { return insertingText; @@ -166,8 +170,9 @@ export class MoveLinesCommand implements ICommand { } } } + } else { + builder.addEditOperation(new Range(s.startLineNumber, 1, s.startLineNumber, 1), insertingText + '\n'); } - builder.addEditOperation(new Range(s.startLineNumber, 1, s.startLineNumber, 1), insertingText + '\n'); } else { movingLineNumber = s.startLineNumber - 1; movingLineText = model.getLineContent(movingLineNumber); @@ -186,6 +191,7 @@ export class MoveLinesCommand implements ICommand { return model.getLineContent(lineNumber); } }; + let newIndentation = LanguageConfigurationRegistry.getGoodIndentForLine(virtualModel, model.getLanguageIdAtPosition(s.startLineNumber, 1), movingLineNumber, indentConverter); if (newIndentation !== null) { // adjust the indentation of the moving block -- GitLab From 9ece2f5cad61720b8f6fc2c6fa5ee182f31f2a3e Mon Sep 17 00:00:00 2001 From: rebornix Date: Wed, 14 Jun 2017 13:22:20 -0700 Subject: [PATCH 0982/1347] Moving lines beyond the first nonempty line now uses indent 0. --- .../common/modes/languageConfigurationRegistry.ts | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/vs/editor/common/modes/languageConfigurationRegistry.ts b/src/vs/editor/common/modes/languageConfigurationRegistry.ts index e7d63e773a5..a524ea101a6 100644 --- a/src/vs/editor/common/modes/languageConfigurationRegistry.ts +++ b/src/vs/editor/common/modes/languageConfigurationRegistry.ts @@ -319,12 +319,18 @@ export class LanguageConfigurationRegistryImpl { } if (lineNumber <= 1) { - return null; + return { + indentation: '', + action: null + }; } let precedingUnIgnoredLine = this.getPrecedingValidLine(model, lineNumber, indentRulesSupport); if (precedingUnIgnoredLine < 1) { - return null; + return { + indentation: '', + action: null + }; } let precedingUnIgnoredLineContent = model.getLineContent(precedingUnIgnoredLine); -- GitLab From 4527fd7ce8a73f710775bc51a1f1eecabb68229d Mon Sep 17 00:00:00 2001 From: rebornix Date: Wed, 14 Jun 2017 14:02:17 -0700 Subject: [PATCH 0983/1347] Nested langauge issue. --- .../modes/languageConfigurationRegistry.ts | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/src/vs/editor/common/modes/languageConfigurationRegistry.ts b/src/vs/editor/common/modes/languageConfigurationRegistry.ts index a524ea101a6..5ffccd3e838 100644 --- a/src/vs/editor/common/modes/languageConfigurationRegistry.ts +++ b/src/vs/editor/common/modes/languageConfigurationRegistry.ts @@ -451,9 +451,21 @@ export class LanguageConfigurationRegistryImpl { } public getIndentForEnter(model: ITokenizedModel, range: Range, indentConverter: any): { beforeEnter: string, afterEnter: string } { - let scopedLineTokens = this.getScopedLineTokens(model, range.startLineNumber, range.startColumn); + model.forceTokenization(range.startLineNumber); + let lineTokens = model.getLineTokens(range.startLineNumber); + + let beforeEnterText; + let tokenIndexUnderCursor = lineTokens.findTokenIndexAtOffset(range.startColumn); + let tokenIndexAtBeginning = lineTokens.findTokenIndexAtOffset(0); + let scopedLineTokens = createScopedLineTokens(lineTokens, range.startColumn); let scopedLineText = scopedLineTokens.getLineContent(); - let beforeEnterText = scopedLineText.substr(0, range.startColumn - 1 - scopedLineTokens.firstCharOffset); + + if (lineTokens.getLanguageId(tokenIndexAtBeginning) === lineTokens.getLanguageId(tokenIndexUnderCursor)) { + beforeEnterText = lineTokens.getLineContent().substring(0, range.startColumn); + } else { + beforeEnterText = scopedLineText.substr(0, range.startColumn - 1 - scopedLineTokens.firstCharOffset); + } + let afterEnterText; if (range.isEmpty()) { -- GitLab From 2ddfa2ec392823e4cd5ccdfe608d38f6c4f7fff3 Mon Sep 17 00:00:00 2001 From: rebornix Date: Fri, 16 Jun 2017 12:58:19 -0700 Subject: [PATCH 0984/1347] Refactor and test cases --- .../common/config/commonEditorConfig.ts | 2 +- .../contrib/indentation/common/indentUtils.ts | 37 +++++++ .../contrib/indentation/common/indentation.ts | 50 ++-------- .../common/moveLinesCommand.ts | 98 ++++++------------- .../test/common/moveLinesCommand.test.ts | 83 +++++++++++++++- .../test/common/controller/cursor.test.ts | 85 ++++++++++++++++ 6 files changed, 246 insertions(+), 109 deletions(-) create mode 100644 src/vs/editor/contrib/indentation/common/indentUtils.ts diff --git a/src/vs/editor/common/config/commonEditorConfig.ts b/src/vs/editor/common/config/commonEditorConfig.ts index a13fd48f5a7..fb99c90e67d 100644 --- a/src/vs/editor/common/config/commonEditorConfig.ts +++ b/src/vs/editor/common/config/commonEditorConfig.ts @@ -404,7 +404,7 @@ const editorConfiguration: IConfigurationNode = { 'editor.autoIndent': { 'type': 'boolean', 'default': EDITOR_DEFAULTS.autoIndent, - 'description': nls.localize('autoIndent', "Controls if the editor should automatically adjust the indenation when users type. Indentation Rules of the language must be available. ") + 'description': nls.localize('autoIndent', "Controls if the editor should automatically adjust the indenation when users type, paste or move lines. Indentation Rules of the language must be available. ") }, 'editor.suggestOnTriggerCharacters': { 'type': 'boolean', diff --git a/src/vs/editor/contrib/indentation/common/indentUtils.ts b/src/vs/editor/contrib/indentation/common/indentUtils.ts new file mode 100644 index 00000000000..45ee5c36566 --- /dev/null +++ b/src/vs/editor/contrib/indentation/common/indentUtils.ts @@ -0,0 +1,37 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +export function getSpaceCnt(str, tabSize) { + let spacesCnt = 0; + + for (let i = 0; i < str.length; i++) { + if (str.charAt(i) === '\t') { + spacesCnt += tabSize; + } else { + spacesCnt++; + } + } + + return spacesCnt; +} + +export function generateIndent(spacesCnt: number, tabSize, insertSpaces) { + spacesCnt = spacesCnt < 0 ? 0 : spacesCnt; + + let result = ''; + if (!insertSpaces) { + let tabsCnt = Math.floor(spacesCnt / tabSize); + spacesCnt = spacesCnt % tabSize; + for (let i = 0; i < tabsCnt; i++) { + result += '\t'; + } + } + + for (let i = 0; i < spacesCnt; i++) { + result += ' '; + } + + return result; +} \ No newline at end of file diff --git a/src/vs/editor/contrib/indentation/common/indentation.ts b/src/vs/editor/contrib/indentation/common/indentation.ts index b44866fc582..9ad1fd44c5c 100644 --- a/src/vs/editor/contrib/indentation/common/indentation.ts +++ b/src/vs/editor/contrib/indentation/common/indentation.ts @@ -19,6 +19,7 @@ import { TextModel } from 'vs/editor/common/model/textModel'; import { LanguageConfigurationRegistry } from 'vs/editor/common/modes/languageConfigurationRegistry'; import { ShiftCommand } from 'vs/editor/common/commands/shiftCommand'; import { TextEdit } from 'vs/editor/common/modes'; +import * as IndentUtil from './indentUtils'; export function shiftIndent(tabSize: number, indentation: string, count?: number): string { count = count || 1; @@ -402,7 +403,7 @@ export class AutoIndentOnPaste implements IEditorContribution { this.callOnModel = dispose(this.callOnModel); // we are disabled - if (!this.editor.getConfiguration().autoIndent) { + if (!this.editor.getConfiguration().autoIndent || this.editor.getConfiguration().contribInfo.formatOnPaste) { return; } @@ -451,11 +452,11 @@ export class AutoIndentOnPaste implements IEditorContribution { if (indentOfFirstLine !== null) { let firstLineText = model.getLineContent(range.startLineNumber); let oldIndentation = strings.getLeadingWhitespace(firstLineText); - let newSpaceCnt = this.getSpaceCnt(indentOfFirstLine, tabSize); - let oldSpaceCnt = this.getSpaceCnt(oldIndentation, tabSize); + let newSpaceCnt = IndentUtil.getSpaceCnt(indentOfFirstLine, tabSize); + let oldSpaceCnt = IndentUtil.getSpaceCnt(oldIndentation, tabSize); if (newSpaceCnt !== oldSpaceCnt) { - let newIndent = this.generateIndent(newSpaceCnt, tabSize, insertSpaces); + let newIndent = IndentUtil.generateIndent(newSpaceCnt, tabSize, insertSpaces); textEdits.push({ range: new Range(range.startLineNumber, 1, range.startLineNumber, oldIndentation.length + 1), text: newIndent @@ -483,17 +484,17 @@ export class AutoIndentOnPaste implements IEditorContribution { } }; let indentOfSecondLine = LanguageConfigurationRegistry.getGoodIndentForLine(virtualModel, model.getLanguageIdentifier().id, range.startLineNumber + 1, indentConverter); - let newSpaceCntOfSecondLine = this.getSpaceCnt(indentOfSecondLine, tabSize); - let oldSpaceCntOfSecondLine = this.getSpaceCnt(strings.getLeadingWhitespace(model.getLineContent(range.startLineNumber + 1)), tabSize); + let newSpaceCntOfSecondLine = IndentUtil.getSpaceCnt(indentOfSecondLine, tabSize); + let oldSpaceCntOfSecondLine = IndentUtil.getSpaceCnt(strings.getLeadingWhitespace(model.getLineContent(range.startLineNumber + 1)), tabSize); if (newSpaceCntOfSecondLine !== oldSpaceCntOfSecondLine) { let spaceCntOffset = newSpaceCntOfSecondLine - oldSpaceCntOfSecondLine; for (let i = range.startLineNumber + 1; i <= range.endLineNumber; i++) { let lineContent = model.getLineContent(i); let originalIndent = strings.getLeadingWhitespace(lineContent); - let originalSpacesCnt = this.getSpaceCnt(originalIndent, tabSize); + let originalSpacesCnt = IndentUtil.getSpaceCnt(originalIndent, tabSize); let newSpacesCnt = originalSpacesCnt + spaceCntOffset; - let newIndent = this.generateIndent(newSpacesCnt, tabSize, insertSpaces); + let newIndent = IndentUtil.generateIndent(newSpacesCnt, tabSize, insertSpaces); if (newIndent !== originalIndent) { textEdits.push({ @@ -519,39 +520,6 @@ export class AutoIndentOnPaste implements IEditorContribution { this.callOnDispose = dispose(this.callOnDispose); this.callOnModel = dispose(this.callOnModel); } - - private getSpaceCnt(str, tabSize) { - let spacesCnt = 0; - - for (let i = 0; i < str.length; i++) { - if (str.charAt(i) === '\t') { - spacesCnt += tabSize; - } else { - spacesCnt++; - } - } - - return spacesCnt; - } - - private generateIndent(spacesCnt: number, tabSize, insertSpaces) { - spacesCnt = spacesCnt < 0 ? 0 : spacesCnt; - - let result = ''; - if (!insertSpaces) { - let tabsCnt = Math.floor(spacesCnt / tabSize); - spacesCnt = spacesCnt % tabSize; - for (let i = 0; i < tabsCnt; i++) { - result += '\t'; - } - } - - for (let i = 0; i < spacesCnt; i++) { - result += ' '; - } - - return result; - } } function getIndentationEditOperations(model: ITokenizedModel, builder: IEditOperationBuilder, tabSize: number, tabsToSpaces: boolean): void { diff --git a/src/vs/editor/contrib/linesOperations/common/moveLinesCommand.ts b/src/vs/editor/contrib/linesOperations/common/moveLinesCommand.ts index bf628c40a7d..de5613d5a5d 100644 --- a/src/vs/editor/contrib/linesOperations/common/moveLinesCommand.ts +++ b/src/vs/editor/contrib/linesOperations/common/moveLinesCommand.ts @@ -10,6 +10,7 @@ import { Selection } from 'vs/editor/common/core/selection'; import { ICommand, ICursorStateComputerData, IEditOperationBuilder, ITokenizedModel } from 'vs/editor/common/editorCommon'; import { LanguageConfigurationRegistry } from 'vs/editor/common/modes/languageConfigurationRegistry'; import { ShiftCommand } from 'vs/editor/common/commands/shiftCommand'; +import * as IndentUtil from 'vs/editor/contrib/indentation/common/indentUtils'; export class MoveLinesCommand implements ICommand { @@ -113,7 +114,7 @@ export class MoveLinesCommand implements ICommand { let insertingText = movingLineText; // Insert line that needs to be moved before - if (this._autoIndent) { + if (this.isAutoIndent(model, s)) { virtualModel.getLineContent = (lineNumber) => { if (lineNumber === s.startLineNumber) { return model.getLineContent(movingLineNumber); @@ -121,14 +122,14 @@ export class MoveLinesCommand implements ICommand { return model.getLineContent(lineNumber); } }; - let newIndentation = LanguageConfigurationRegistry.getGoodIndentForLine(virtualModel, model.getLanguageIdAtPosition( + let indentOfMovingLine = LanguageConfigurationRegistry.getGoodIndentForLine(virtualModel, model.getLanguageIdAtPosition( movingLineNumber, 1), s.startLineNumber, indentConverter); - if (newIndentation !== null) { + if (indentOfMovingLine !== null) { let oldIndentation = strings.getLeadingWhitespace(model.getLineContent(movingLineNumber)); - let newSpaceCnt = this.getSpaceCnt(newIndentation, tabSize); - let oldSpaceCnt = this.getSpaceCnt(oldIndentation, tabSize); + let newSpaceCnt = IndentUtil.getSpaceCnt(indentOfMovingLine, tabSize); + let oldSpaceCnt = IndentUtil.getSpaceCnt(oldIndentation, tabSize); if (newSpaceCnt !== oldSpaceCnt) { - let newIndentation = this.generateIndent(newSpaceCnt, tabSize, insertSpaces); + let newIndentation = IndentUtil.generateIndent(newSpaceCnt, tabSize, insertSpaces); insertingText = newIndentation + strings.ltrim(strings.ltrim(movingLineText), '\t'); } } @@ -147,27 +148,17 @@ export class MoveLinesCommand implements ICommand { } }; - let newIndentationForMovingBlock = LanguageConfigurationRegistry.getGoodIndentForLine(virtualModel, model.getLanguageIdAtPosition( + let newIndentatOfMovingBlock = LanguageConfigurationRegistry.getGoodIndentForLine(virtualModel, model.getLanguageIdAtPosition( movingLineNumber, 1), s.startLineNumber + 1, indentConverter); - if (newIndentationForMovingBlock !== null) { - let oldIndentation = strings.getLeadingWhitespace(model.getLineContent(s.startLineNumber)); - let newSpaceCnt = this.getSpaceCnt(newIndentationForMovingBlock, tabSize); - let oldSpaceCnt = this.getSpaceCnt(oldIndentation, tabSize); + if (newIndentatOfMovingBlock !== null) { + const oldIndentation = strings.getLeadingWhitespace(model.getLineContent(s.startLineNumber)); + const newSpaceCnt = IndentUtil.getSpaceCnt(newIndentatOfMovingBlock, tabSize); + const oldSpaceCnt = IndentUtil.getSpaceCnt(oldIndentation, tabSize); if (newSpaceCnt !== oldSpaceCnt) { - let spaceCntOffset = newSpaceCnt - oldSpaceCnt; + const spaceCntOffset = newSpaceCnt - oldSpaceCnt; - for (let i = s.startLineNumber; i <= s.endLineNumber; i++) { - let lineContent = model.getLineContent(i); - let originalIndent = strings.getLeadingWhitespace(lineContent); - let originalSpacesCnt = this.getSpaceCnt(originalIndent, tabSize); - let newSpacesCnt = originalSpacesCnt + spaceCntOffset; - let newIndent = this.generateIndent(newSpacesCnt, tabSize, insertSpaces); - - if (newIndent !== originalIndent) { - builder.addEditOperation(new Range(i, 1, i, originalIndent.length + 1), newIndent); - } - } + this.getIndentEditsOfMovingBlock(model, builder, s.startLineNumber, s.endLineNumber, tabSize, insertSpaces, spaceCntOffset); } } } else { @@ -183,7 +174,7 @@ export class MoveLinesCommand implements ICommand { // Insert line that needs to be moved after builder.addEditOperation(new Range(s.endLineNumber, model.getLineMaxColumn(s.endLineNumber), s.endLineNumber, model.getLineMaxColumn(s.endLineNumber)), '\n' + movingLineText); - if (this._autoIndent && (model.getLanguageIdAtPosition(s.startLineNumber, 1) === model.getLanguageIdAtPosition(s.endLineNumber, 1))) { + if (this.isAutoIndent(model, s)) { virtualModel.getLineContent = (lineNumber: number) => { if (lineNumber === movingLineNumber) { return model.getLineContent(s.startLineNumber); @@ -192,26 +183,16 @@ export class MoveLinesCommand implements ICommand { } }; - let newIndentation = LanguageConfigurationRegistry.getGoodIndentForLine(virtualModel, model.getLanguageIdAtPosition(s.startLineNumber, 1), movingLineNumber, indentConverter); - if (newIndentation !== null) { + let indentOfFirstLine = LanguageConfigurationRegistry.getGoodIndentForLine(virtualModel, model.getLanguageIdAtPosition(s.startLineNumber, 1), movingLineNumber, indentConverter); + if (indentOfFirstLine !== null) { // adjust the indentation of the moving block - let oldIndentation = strings.getLeadingWhitespace(model.getLineContent(s.startLineNumber)); - let newSpaceCnt = this.getSpaceCnt(newIndentation, tabSize); - let oldSpaceCnt = this.getSpaceCnt(oldIndentation, tabSize); + let oldIndent = strings.getLeadingWhitespace(model.getLineContent(s.startLineNumber)); + let newSpaceCnt = IndentUtil.getSpaceCnt(indentOfFirstLine, tabSize); + let oldSpaceCnt = IndentUtil.getSpaceCnt(oldIndent, tabSize); if (newSpaceCnt !== oldSpaceCnt) { let spaceCntOffset = newSpaceCnt - oldSpaceCnt; - for (let i = s.startLineNumber; i <= s.endLineNumber; i++) { - let lineContent = model.getLineContent(i); - let originalIndent = strings.getLeadingWhitespace(lineContent); - let originalSpacesCnt = this.getSpaceCnt(originalIndent, tabSize); - let newSpacesCnt = originalSpacesCnt + spaceCntOffset; - let newIndent = this.generateIndent(newSpacesCnt, tabSize, insertSpaces); - - if (newIndent !== originalIndent) { - builder.addEditOperation(new Range(i, 1, i, originalIndent.length + 1), newIndent); - } - } + this.getIndentEditsOfMovingBlock(model, builder, s.startLineNumber, s.endLineNumber, tabSize, insertSpaces, spaceCntOffset); } } } @@ -221,37 +202,22 @@ export class MoveLinesCommand implements ICommand { this._selectionId = builder.trackSelection(s); } - private getSpaceCnt(str, tabSize) { - let spacesCnt = 0; - - for (let i = 0; i < str.length; i++) { - if (str.charAt(i) === '\t') { - spacesCnt += tabSize; - } else { - spacesCnt++; - } - } - - return spacesCnt; + private isAutoIndent(model: ITokenizedModel, selection: Selection) { + return this._autoIndent && (model.getLanguageIdAtPosition(selection.startLineNumber, 1) === model.getLanguageIdAtPosition(selection.endLineNumber, 1)); } - private generateIndent(spacesCnt: number, tabSize, insertSpaces) { - spacesCnt = spacesCnt < 0 ? 0 : spacesCnt; + private getIndentEditsOfMovingBlock(model: ITokenizedModel, builder: IEditOperationBuilder, startLineNumber: number, endLineNumber: number, tabSize: number, insertSpaces: boolean, offset: number) { + for (let i = startLineNumber; i <= endLineNumber; i++) { + let lineContent = model.getLineContent(i); + let originalIndent = strings.getLeadingWhitespace(lineContent); + let originalSpacesCnt = IndentUtil.getSpaceCnt(originalIndent, tabSize); + let newSpacesCnt = originalSpacesCnt + offset; + let newIndent = IndentUtil.generateIndent(newSpacesCnt, tabSize, insertSpaces); - let result = ''; - if (!insertSpaces) { - let tabsCnt = Math.floor(spacesCnt / tabSize); - spacesCnt = spacesCnt % tabSize; - for (let i = 0; i < tabsCnt; i++) { - result += '\t'; + if (newIndent !== originalIndent) { + builder.addEditOperation(new Range(i, 1, i, originalIndent.length + 1), newIndent); } } - - for (let i = 0; i < spacesCnt; i++) { - result += ' '; - } - - return result; } public computeCursorState(model: ITokenizedModel, helper: ICursorStateComputerData): Selection { diff --git a/src/vs/editor/contrib/linesOperations/test/common/moveLinesCommand.test.ts b/src/vs/editor/contrib/linesOperations/test/common/moveLinesCommand.test.ts index 31b2778901a..518dbb2d762 100644 --- a/src/vs/editor/contrib/linesOperations/test/common/moveLinesCommand.test.ts +++ b/src/vs/editor/contrib/linesOperations/test/common/moveLinesCommand.test.ts @@ -3,10 +3,13 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ 'use strict'; - import { Selection } from 'vs/editor/common/core/selection'; import { MoveLinesCommand } from 'vs/editor/contrib/linesOperations/common/moveLinesCommand'; import { testCommand } from 'vs/editor/test/common/commands/commandTestUtils'; +import { MockMode } from 'vs/editor/test/common/mocks/mockMode'; +import { LanguageIdentifier } from 'vs/editor/common/modes'; +import { IndentationRule } from 'vs/editor/common/modes/languageConfiguration'; +import { LanguageConfigurationRegistry } from 'vs/editor/common/modes/languageConfigurationRegistry'; function testMoveLinesDownCommand(lines: string[], selection: Selection, expectedLines: string[], expectedSelection: Selection): void { testCommand(lines, null, selection, (sel) => new MoveLinesCommand(sel, true, false), expectedLines, expectedSelection); @@ -16,6 +19,14 @@ function testMoveLinesUpCommand(lines: string[], selection: Selection, expectedL testCommand(lines, null, selection, (sel) => new MoveLinesCommand(sel, false, false), expectedLines, expectedSelection); } +function testMoveLinesDownWithIndentCommand(languageId: LanguageIdentifier, lines: string[], selection: Selection, expectedLines: string[], expectedSelection: Selection): void { + testCommand(lines, languageId, selection, (sel) => new MoveLinesCommand(sel, true, true), expectedLines, expectedSelection); +} + +function testMoveLinesUpWithIndentCommand(languageId: LanguageIdentifier, lines: string[], selection: Selection, expectedLines: string[], expectedSelection: Selection): void { + testCommand(lines, languageId, selection, (sel) => new MoveLinesCommand(sel, false, true), expectedLines, expectedSelection); +} + suite('Editor Contrib - Move Lines Command', () => { test('move first up / last down disabled', function () { @@ -248,3 +259,73 @@ suite('Editor Contrib - Move Lines Command', () => { }); }); +class IndentRulesMode extends MockMode { + private static _id = new LanguageIdentifier('moveLinesIndentMode', 7); + constructor(indentationRules: IndentationRule) { + super(IndentRulesMode._id); + this._register(LanguageConfigurationRegistry.register(this.getLanguageIdentifier(), { + indentationRules: indentationRules + })); + } +} + +suite('Editor contrib - Move Lines Command honors Indentation Rules', () => { + let indentRules = { + decreaseIndentPattern: /^\s*((?!\S.*\/[*]).*[*]\/\s*)?[})\]]|^\s*(case\b.*|default):\s*(\/\/.*|\/[*].*[*]\/\s*)?$/, + increaseIndentPattern: /(\{[^}"'`]*|\([^)"']*|\[[^\]"']*|^\s*(\{\}|\(\)|\[\]|(case\b.*|default):))\s*(\/\/.*|\/[*].*[*]\/\s*)?$/, + indentNextLinePattern: /^\s*(for|while|if|else)\b(?!.*[;{}]\s*(\/\/.*|\/[*].*[*]\/\s*)?$)/, + unIndentedLinePattern: /^(?!.*([;{}]|\S:)\s*(\/\/.*|\/[*].*[*]\/\s*)?$)(?!.*(\{[^}"']*|\([^)"']*|\[[^\]"']*|^\s*(\{\}|\(\)|\[\]|(case\b.*|default):))\s*(\/\/.*|\/[*].*[*]\/\s*)?$)(?!^\s*((?!\S.*\/[*]).*[*]\/\s*)?[})\]]|^\s*(case\b.*|default):\s*(\/\/.*|\/[*].*[*]\/\s*)?$)(?!^\s*(for|while|if|else)\b(?!.*[;{}]\s*(\/\/.*|\/[*].*[*]\/\s*)?$))/ + }; + + // https://github.com/Microsoft/vscode/issues/28552#issuecomment-307862797 + test('first line indentation adjust to 0', () => { + let mode = new IndentRulesMode(indentRules); + + testMoveLinesUpWithIndentCommand( + mode.getLanguageIdentifier(), + [ + 'class X {', + '\tz = 2', + '}' + ], + new Selection(2, 1, 2, 1), + [ + 'z = 2', + 'class X {', + '}' + ], + new Selection(1, 1, 1, 1) + ); + + mode.dispose(); + }); + + // https://github.com/Microsoft/vscode/issues/28552#issuecomment-307867717 + test('move lines across block', () => { + let mode = new IndentRulesMode(indentRules); + + testMoveLinesDownWithIndentCommand( + mode.getLanguageIdentifier(), + [ + 'const value = 2;', + 'const standardLanguageDescriptions = [', + ' {', + ' diagnosticSource: \'js\',', + ' }', + '];' + ], + new Selection(1, 1, 1, 1), + [ + 'const standardLanguageDescriptions = [', + ' const value = 2;', + ' {', + ' diagnosticSource: \'js\',', + ' }', + '];' + ], + new Selection(2, 5, 2, 5) + ); + + mode.dispose(); + }); +}); \ No newline at end of file diff --git a/src/vs/editor/test/common/controller/cursor.test.ts b/src/vs/editor/test/common/controller/cursor.test.ts index 7c9fa3076bd..148e50d08ec 100644 --- a/src/vs/editor/test/common/controller/cursor.test.ts +++ b/src/vs/editor/test/common/controller/cursor.test.ts @@ -2340,6 +2340,37 @@ suite('Editor Controller - Indentation Rules', () => { }); }); + test('Enter honors indentNextLinePattern 2', () => { + let model = Model.createFromString( + [ + 'if (true)', + '\tif (true)' + ].join('\n'), + { + defaultEOL: DefaultEndOfLine.LF, + detectIndentation: false, + insertSpaces: false, + tabSize: 4, + trimAutoWhitespace: true + }, + mode.getLanguageIdentifier() + ); + + withMockCodeEditor(null, { model: model, autoIndent: true }, (editor, cursor) => { + moveTo(cursor, 2, 11, false); + assertCursor(cursor, new Selection(2, 11, 2, 11)); + + cursorCommand(cursor, H.Type, { text: '\n' }, 'keyboard'); + assertCursor(cursor, new Selection(3, 3, 3, 3)); + + cursorCommand(cursor, H.Type, { text: 'console.log();' }, 'keyboard'); + cursorCommand(cursor, H.Type, { text: '\n' }, 'keyboard'); + assertCursor(cursor, new Selection(4, 1, 4, 1)); + }); + + model.dispose(); + }); + test('Enter adjusts indentation of current line 1', () => { usingCursor({ text: [ @@ -2380,6 +2411,26 @@ suite('Editor Controller - Indentation Rules', () => { }); }); + test('Enter honors intential indent', () => { + usingCursor({ + text: [ + 'if (true) {', + '\tif (true) {', + 'return true;', + '}}' + ], + languageIdentifier: mode.getLanguageIdentifier(), + modelOpts: { insertSpaces: false, tabSize: 4, detectIndentation: false, defaultEOL: DefaultEndOfLine.LF, trimAutoWhitespace: true } + }, (model, cursor) => { + moveTo(cursor, 3, 13, false); + assertCursor(cursor, new Selection(3, 13, 3, 13)); + + cursorCommand(cursor, H.Type, { text: '\n' }, 'keyboard'); + assertCursor(cursor, new Selection(4, 1, 4, 1)); + assert.equal(model.getLineContent(3), 'return true;', '001'); + }); + }); + test('Enter supports selection 1', () => { usingCursor({ text: [ @@ -2765,6 +2816,40 @@ suite('Editor Controller - Indentation Rules', () => { model.dispose(); }); + + test('type honors indentation rules: ruby keywords', () => { + let rubyMode = new IndentRulesMode({ + increaseIndentPattern: /^\s*((begin|class|def|else|elsif|ensure|for|if|module|rescue|unless|until|when|while)|(.*\sdo\b))\b[^\{;]*$/, + decreaseIndentPattern: /^\s*([}\]]([,)]?\s*(#|$)|\.[a-zA-Z_]\w*\b)|(end|rescue|ensure|else|elsif|when)\b)/ + }); + let model = Model.createFromString( + [ + 'class Greeter', + ' def initialize(name)', + ' @name = name', + ' en' + ].join('\n'), + { + defaultEOL: DefaultEndOfLine.LF, + detectIndentation: false, + insertSpaces: true, + tabSize: 2, + trimAutoWhitespace: true + }, + rubyMode.getLanguageIdentifier() + ); + + withMockCodeEditor(null, { model: model, autoIndent: true }, (editor, cursor) => { + moveTo(cursor, 4, 7, false); + assertCursor(cursor, new Selection(4, 7, 4, 7)); + + cursorCommand(cursor, H.Type, { text: 'd' }, 'keyboard'); + assert.equal(model.getLineContent(4), ' end'); + }); + + rubyMode.dispose(); + model.dispose(); + }); }); interface ICursorOpts { -- GitLab From 1564137b95a0150db69726c75f80f53a19dafa83 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Fri, 16 Jun 2017 13:13:55 -0700 Subject: [PATCH 0985/1347] Prototype TS/JS Refactoring Provider (#27166) * Prototype TS/JS Refactoring Provider Fixes #25739, from https://github.com/Microsoft/TypeScript/pull/15569 Prototype of refactoring support for ts 2.4 * Adding error reporting * Updating for new API * show quick pick for non-inlinable refactrings --- .../src/features/refactorProvider.ts | 128 ++++++++++++++++++ extensions/typescript/src/typescriptMain.ts | 5 +- .../typescript/src/typescriptService.ts | 5 + 3 files changed, 136 insertions(+), 2 deletions(-) create mode 100644 extensions/typescript/src/features/refactorProvider.ts diff --git a/extensions/typescript/src/features/refactorProvider.ts b/extensions/typescript/src/features/refactorProvider.ts new file mode 100644 index 00000000000..4e930e09d80 --- /dev/null +++ b/extensions/typescript/src/features/refactorProvider.ts @@ -0,0 +1,128 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +'use strict'; + +import { CodeActionProvider, TextDocument, Range, CancellationToken, CodeActionContext, Command, commands, workspace, WorkspaceEdit, window, QuickPickItem } from 'vscode'; + +import * as Proto from '../protocol'; +import { ITypescriptServiceClient } from '../typescriptService'; + + +export default class TypeScriptRefactorProvider implements CodeActionProvider { + private doRefactorCommandId: string; + private selectRefactorCommandId: string; + + constructor( + private readonly client: ITypescriptServiceClient, + mode: string + ) { + this.doRefactorCommandId = `_typescript.applyRefactoring.${mode}`; + this.selectRefactorCommandId = `_typescript.selectRefactoring.${mode}`; + + commands.registerCommand(this.doRefactorCommandId, this.doRefactoring, this); + commands.registerCommand(this.selectRefactorCommandId, this.selectRefactoring, this); + + } + + public async provideCodeActions( + document: TextDocument, + range: Range, + _context: CodeActionContext, + token: CancellationToken + ): Promise { + if (!this.client.apiVersion.has240Features()) { + return []; + } + + const file = this.client.normalizePath(document.uri); + if (!file) { + return []; + } + + const args: Proto.GetApplicableRefactorsRequestArgs = { + file: file, + startLine: range.start.line + 1, + startOffset: range.start.character + 1, + endLine: range.end.line + 1, + endOffset: range.end.character + 1 + }; + + try { + const response = await this.client.execute('getApplicableRefactors', args, token); + if (!response || !response.body) { + return []; + } + + const actions: Command[] = []; + for (const info of response.body) { + if (info.inlineable === false) { + actions.push({ + title: info.description, + command: this.selectRefactorCommandId, + arguments: [file, info, range] + }); + } else { + for (const action of info.actions) { + actions.push({ + title: action.description, + command: this.doRefactorCommandId, + arguments: [file, info.name, action.name, range] + }); + } + } + } + return actions; + } catch (err) { + return []; + } + } + + private toWorkspaceEdit(edits: Proto.FileCodeEdits[]): WorkspaceEdit { + const workspaceEdit = new WorkspaceEdit(); + for (const edit of edits) { + for (const textChange of edit.textChanges) { + workspaceEdit.replace(this.client.asUrl(edit.fileName), + new Range( + textChange.start.line - 1, textChange.start.offset - 1, + textChange.end.line - 1, textChange.end.offset - 1), + textChange.newText); + } + } + return workspaceEdit; + } + + private async selectRefactoring(file: string, info: Proto.ApplicableRefactorInfo, range: Range): Promise { + return window.showQuickPick(info.actions.map((action): QuickPickItem => ({ + label: action.name, + description: action.description + }))).then(selected => { + if (!selected) { + return false; + } + return this.doRefactoring(file, info.name, selected.label, range); + }); + } + + private async doRefactoring(file: string, refactor: string, action: string, range: Range): Promise { + const args: Proto.GetEditsForRefactorRequestArgs = { + file, + refactor, + action, + startLine: range.start.line + 1, + startOffset: range.start.character + 1, + endLine: range.end.line + 1, + endOffset: range.end.character + 1 + }; + + const response = await this.client.execute('getEditsForRefactor', args); + if (!response || !response.body || !response.body.edits.length) { + return false; + } + + const edit = this.toWorkspaceEdit(response.body.edits); + return workspace.applyEdit(edit); + } +} \ No newline at end of file diff --git a/extensions/typescript/src/typescriptMain.ts b/extensions/typescript/src/typescriptMain.ts index 00db96b6663..5910f1765a3 100644 --- a/extensions/typescript/src/typescriptMain.ts +++ b/extensions/typescript/src/typescriptMain.ts @@ -38,11 +38,11 @@ import BufferSyncSupport from './features/bufferSyncSupport'; import CompletionItemProvider from './features/completionItemProvider'; import WorkspaceSymbolProvider from './features/workspaceSymbolProvider'; import CodeActionProvider from './features/codeActionProvider'; +import RefactorProvider from './features/refactorProvider'; import ReferenceCodeLensProvider from './features/referencesCodeLensProvider'; import { JsDocCompletionProvider, TryCompleteJsDocCommand } from './features/jsDocCompletionProvider'; import { DirectiveCommentCompletionProvider } from './features/directiveCommentCompletionProvider'; import TypeScriptTaskProviderManager from './features/taskProvider'; - import ImplementationCodeLensProvider from './features/implementationsCodeLensProvider'; import * as ProjectStatus from './utils/projectStatus'; @@ -167,6 +167,7 @@ export function activate(context: ExtensionContext): void { const validateSetting = 'validate.enable'; class LanguageProvider { + private syntaxDiagnostics: ObjectMap; private readonly currentDiagnostics: DiagnosticCollection; private readonly bufferSyncSupport: BufferSyncSupport; @@ -263,7 +264,7 @@ class LanguageProvider { this.disposables.push(languages.registerRenameProvider(selector, new RenameProvider(client))); this.disposables.push(languages.registerCodeActionsProvider(selector, new CodeActionProvider(client, this.description.id))); - + this.disposables.push(languages.registerCodeActionsProvider(selector, new RefactorProvider(client, this.description.id))); this.registerVersionDependentProviders(); this.description.modeIds.forEach(modeId => { diff --git a/extensions/typescript/src/typescriptService.ts b/extensions/typescript/src/typescriptService.ts index 1b545fef0ac..05b11a24f41 100644 --- a/extensions/typescript/src/typescriptService.ts +++ b/extensions/typescript/src/typescriptService.ts @@ -68,6 +68,9 @@ export class API { public has234Features(): boolean { return semver.gte(this._version, '2.3.4'); } + public has240Features(): boolean { + return semver.gte(this._version, '2.4.0'); + } } export interface ITypescriptServiceClient { @@ -115,6 +118,8 @@ export interface ITypescriptServiceClient { execute(command: 'getCodeFixes', args: Proto.CodeFixRequestArgs, token?: CancellationToken): Promise; execute(command: 'getSupportedCodeFixes', args: null, token?: CancellationToken): Promise; execute(command: 'docCommentTemplate', args: Proto.FileLocationRequestArgs, token?: CancellationToken): Promise; + execute(command: 'getApplicableRefactors', args: Proto.GetApplicableRefactorsRequestArgs, token?: CancellationToken): Promise; + execute(command: 'getEditsForRefactor', args: Proto.GetEditsForRefactorRequestArgs, token?: CancellationToken): Promise; // execute(command: 'compileOnSaveAffectedFileList', args: Proto.CompileOnSaveEmitFileRequestArgs, token?: CancellationToken): Promise; // execute(command: 'compileOnSaveEmitFile', args: Proto.CompileOnSaveEmitFileRequestArgs, token?: CancellationToken): Promise; execute(command: string, args: any, expectedResult: boolean | CancellationToken, token?: CancellationToken): Promise; -- GitLab From 062abef9eedb258936c044096d75cf75bcd73105 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Fri, 16 Jun 2017 13:28:47 -0700 Subject: [PATCH 0986/1347] Fix stable sort for zero sized array --- src/vs/base/common/arrays.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/base/common/arrays.ts b/src/vs/base/common/arrays.ts index 791dd071850..e014f37cc15 100644 --- a/src/vs/base/common/arrays.ts +++ b/src/vs/base/common/arrays.ts @@ -76,7 +76,7 @@ export function mergeSort(data: T[], compare: (a: T, b: T) => number): T[] { } function _divideAndMerge(data: T[], compare: (a: T, b: T) => number): void { - if (data.length === 1) { + if (data.length <= 1) { // sorted return; } -- GitLab From 32702189cb97575a90e188a71d7924196f90ab8c Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Fri, 16 Jun 2017 14:46:43 -0700 Subject: [PATCH 0987/1347] Add CSP to shared process --- src/vs/code/electron-browser/sharedProcess.html | 1 + src/vs/code/electron-main/sharedProcess.ts | 9 ++++++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/src/vs/code/electron-browser/sharedProcess.html b/src/vs/code/electron-browser/sharedProcess.html index 1c3da8dcb91..e4e23bf96ae 100644 --- a/src/vs/code/electron-browser/sharedProcess.html +++ b/src/vs/code/electron-browser/sharedProcess.html @@ -4,6 +4,7 @@ + diff --git a/src/vs/code/electron-main/sharedProcess.ts b/src/vs/code/electron-main/sharedProcess.ts index eb540858c6d..2422ab62c9a 100644 --- a/src/vs/code/electron-main/sharedProcess.ts +++ b/src/vs/code/electron-main/sharedProcess.ts @@ -22,7 +22,14 @@ export class SharedProcess implements ISharedProcess { @memoize private get _whenReady(): TPromise { - this.window = new BrowserWindow({ show: false }); + this.window = new BrowserWindow({ + show: false, + webPreferences: { + images: false, + webaudio: false, + webgl: false + } + }); const config = assign({ appRoot: this.environmentService.appRoot, nodeCachedDataDir: this.environmentService.nodeCachedDataDir, -- GitLab From c017db2eec80ab5c6d0b0b648444345cd749a920 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20H=C3=BCbelbauer?= Date: Fri, 16 Jun 2017 23:51:57 +0200 Subject: [PATCH 0988/1347] Add spaces, use MarkDown, recommend Help > Report Issues (#28696) --- issue_template.md | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/issue_template.md b/issue_template.md index 81a8470fc44..7747f9d3371 100644 --- a/issue_template.md +++ b/issue_template.md @@ -1,9 +1,10 @@ - +Do you have a question? Please ask it on [Stack Overflow with `vscode` tag](http://stackoverflow.com/questions/tagged/vscode) -- VSCode Version: -- OS Version: +(Use Help > Report Issues to prefill these) +- VSCode Version: +- OS Version: Steps to Reproduce: -1. -2. +1. +2. -- GitLab From c364d3a61736234361066f5859cd3c02fc114ed5 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Fri, 16 Jun 2017 15:06:04 -0700 Subject: [PATCH 0989/1347] Fixing csp for installing extensions --- src/vs/code/electron-browser/sharedProcess.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/code/electron-browser/sharedProcess.html b/src/vs/code/electron-browser/sharedProcess.html index e4e23bf96ae..be70dede202 100644 --- a/src/vs/code/electron-browser/sharedProcess.html +++ b/src/vs/code/electron-browser/sharedProcess.html @@ -4,7 +4,7 @@ - + -- GitLab From 3c4afb72d85ca93563414e4fd0cf76ff819a51df Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Fri, 16 Jun 2017 15:18:31 -0700 Subject: [PATCH 0990/1347] Rework ext install flow a bit --- .../node/extensionsWorkbenchService.ts | 27 +++++++++++++------ 1 file changed, 19 insertions(+), 8 deletions(-) diff --git a/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.ts b/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.ts index 26ce06d3634..c89324762da 100644 --- a/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.ts +++ b/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.ts @@ -811,14 +811,25 @@ export class ExtensionsWorkbenchService implements IExtensionsWorkbenchService { } const extension = result.firstPage[0]; - const promises = [this.open(extension)]; - - if (this.local.every(local => local.id !== extension.id)) { - promises.push(this.install(extension)); - } - - TPromise.join(promises) - .done(null, error => this.onError(error)); + this.open(extension).then(() => { + const message = nls.localize('installConfirmation', "Would you like to install the '{0}' extension?", extension.displayName, extension.publisher); + const options = [ + nls.localize('install', "Install"), + nls.localize('cancel', "Cancel") + ]; + this.choiceService.choose(Severity.Info, message, options, 2, false) + .then(value => { + if (value === 0) { + const promises: TPromise[] = []; + if (this.local.every(local => local.id !== extension.id)) { + promises.push(this.install(extension)); + } + + TPromise.join(promises) + .done(null, error => this.onError(error)); + } + }); + }); }); } -- GitLab From 5e0df0cf8ff7c0477ac613e01cc247e21ffd7810 Mon Sep 17 00:00:00 2001 From: Matt Bierner Date: Fri, 16 Jun 2017 15:28:42 -0700 Subject: [PATCH 0991/1347] Cleanup --- .../node/extensionsWorkbenchService.ts | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.ts b/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.ts index c89324762da..c7a025ac73a 100644 --- a/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.ts +++ b/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.ts @@ -805,32 +805,32 @@ export class ExtensionsWorkbenchService implements IExtensionsWorkbenchService { const extensionId = match[1]; this.queryGallery({ names: [extensionId] }) - .done(result => { + .then(result => { if (result.total < 1) { - return; + return TPromise.as(null); } const extension = result.firstPage[0]; - this.open(extension).then(() => { + return this.open(extension).then(() => { const message = nls.localize('installConfirmation', "Would you like to install the '{0}' extension?", extension.displayName, extension.publisher); const options = [ nls.localize('install', "Install"), nls.localize('cancel', "Cancel") ]; - this.choiceService.choose(Severity.Info, message, options, 2, false) + return this.choiceService.choose(Severity.Info, message, options, 2, false) .then(value => { if (value === 0) { const promises: TPromise[] = []; if (this.local.every(local => local.id !== extension.id)) { promises.push(this.install(extension)); } - - TPromise.join(promises) - .done(null, error => this.onError(error)); + return TPromise.join(promises); } + return TPromise.as(null); }); }); - }); + }) + .done(undefined, error => this.onError(error)); } dispose(): void { -- GitLab From b5d511e85d15bd3cf87ea19be6abd0cd329ccf78 Mon Sep 17 00:00:00 2001 From: Anjali Fernandes Date: Fri, 16 Jun 2017 16:37:30 -0700 Subject: [PATCH 0992/1347] Update vs_code_welcome_page.ts --- .../welcome/page/electron-browser/vs_code_welcome_page.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.ts b/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.ts index bf03a6df344..f554ff11596 100644 --- a/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.ts +++ b/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.ts @@ -66,7 +66,7 @@ export default () => `

    ${escape(localize('welcomePage.learn', "Learn"))}

      -
    • +
    @@ -82,4 +82,4 @@ export default () => `
    -`; \ No newline at end of file +`; -- GitLab From e72fcb6089e7e9801b666cf2733a387227a56982 Mon Sep 17 00:00:00 2001 From: Daniel Ye Date: Fri, 16 Jun 2017 18:42:44 -0700 Subject: [PATCH 0993/1347] 2017-06-16. Merged in translations from Transifex. --- build/win32/i18n/messages.hu.isl | 8 + build/win32/i18n/messages.tr.isl | 8 + i18n/chs/extensions/git/package.i18n.json | 2 +- .../out/codelensProvider.i18n.json | 7 +- .../out/commandHandler.i18n.json | 2 + .../merge-conflict/package.i18n.json | 8 + .../out/features/bufferSyncSupport.i18n.json | 2 +- .../out/utils/projectStatus.i18n.json | 1 - .../out/utils/typingsStatus.i18n.json | 1 + .../extensions/typescript/package.i18n.json | 4 +- .../src/vs/base/common/errorMessage.i18n.json | 1 - .../vs/base/common/keybindingLabels.i18n.json | 6 + .../src/vs/code/electron-main/menus.i18n.json | 18 +- .../vs/code/electron-main/windows.i18n.json | 6 +- .../config/commonEditorConfig.i18n.json | 9 +- .../common/config/editorOptions.i18n.json | 1 + .../find/common/findController.i18n.json | 1 - .../format/browser/formatActions.i18n.json | 6 +- .../browser/referencesModel.i18n.json | 4 +- .../menusExtensionPoint.i18n.json | 2 + .../common/extensionsRegistry.i18n.json | 6 + .../node/extensionValidator.i18n.json | 16 +- .../historyMainService.i18n.json | 11 ++ .../markers/common/problemMatcher.i18n.json | 2 +- .../theme/common/colorRegistry.i18n.json | 11 +- .../workbench/api/node/extHostTask.i18n.json | 4 +- .../activitybar/activitybarPart.i18n.json | 3 +- .../parts/editor/editorActions.i18n.json | 1 + .../parts/editor/editorStatus.i18n.json | 1 + .../parts/editor/titleControl.i18n.json | 1 + .../parts/quickopen/quickopen.i18n.json | 12 ++ .../vs/workbench/browser/quickopen.i18n.json | 3 +- .../vs/workbench/browser/viewlet.i18n.json | 3 +- .../src/vs/workbench/common/theme.i18n.json | 11 +- .../electron-browser/actions.i18n.json | 18 +- .../main.contribution.i18n.json | 14 +- .../electron-browser/accessibility.i18n.json | 26 +++ .../inspectTMScopes.i18n.json | 6 + .../toggleMultiCursorModifier.i18n.json | 8 + .../electron-browser/debugViews.i18n.json | 4 - .../actions/editPoints.i18n.json | 4 +- .../emmet.contribution.i18n.json | 3 +- .../browser/extensionEditor.i18n.json | 4 + .../browser/files.contribution.i18n.json | 1 - .../files/browser/views/emptyView.i18n.json | 2 - .../browser/views/openEditorsView.i18n.json | 2 +- .../browser/keybindingWidgets.i18n.json | 2 +- .../keybindingsEditorContribution.i18n.json | 4 +- .../relauncher.contribution.i18n.json | 10 + .../snippets.contribution.i18n.json | 2 +- .../languageSurveys.contribution.i18n.json | 11 ++ .../nps.contribution.i18n.json | 11 ++ .../tasks/browser/buildQuickOpen.i18n.json | 8 + .../parts/tasks/browser/quickOpen.i18n.json | 3 +- .../tasks/browser/testQuickOpen.i18n.json | 9 + .../tasks/common/taskConfiguration.i18n.json | 1 + .../jsonSchemaCommon.i18n.json | 1 + .../electron-browser/jsonSchema_v1.i18n.json | 2 + .../electron-browser/jsonSchema_v2.i18n.json | 4 + .../task.contribution.i18n.json | 7 +- .../terminalTaskSystem.i18n.json | 1 + .../terminalActions.i18n.json | 7 +- .../terminalFindWidget.i18n.json | 12 ++ .../terminalInstance.i18n.json | 1 - .../update/electron-browser/update.i18n.json | 15 +- .../parts/views/browser/views.i18n.json | 8 + .../browser/viewsExtensionPoint.i18n.json | 15 ++ .../vs_code_welcome_page.i18n.json | 1 - .../welcomePage.contribution.i18n.json | 2 - .../electron-browser/welcomePage.i18n.json | 17 +- .../common/crashReporterService.i18n.json | 9 + .../keybindingService.i18n.json | 2 +- .../browser/progressService2.i18n.json | 9 + .../cht/extensions/git/out/commands.i18n.json | 3 + .../extensions/git/out/scmProvider.i18n.json | 2 +- i18n/cht/extensions/git/package.i18n.json | 3 +- i18n/cht/extensions/jake/out/main.i18n.json | 4 +- i18n/cht/extensions/jake/package.i18n.json | 4 +- .../markdown/out/extension.i18n.json | 4 +- .../out/codelensProvider.i18n.json | 7 +- .../out/commandHandler.i18n.json | 1 + .../merge-conflict/package.i18n.json | 8 + .../out/features/bufferSyncSupport.i18n.json | 1 - ...rectiveCommentCompletionProvider.i18n.json | 6 +- .../out/utils/projectStatus.i18n.json | 1 - .../out/utils/typingsStatus.i18n.json | 1 + .../extensions/typescript/package.i18n.json | 6 +- .../src/vs/base/common/errorMessage.i18n.json | 1 - .../base/common/jsonErrorMessages.i18n.json | 12 +- .../vs/base/common/keybindingLabels.i18n.json | 6 + .../src/vs/code/electron-main/menus.i18n.json | 11 +- .../vs/code/electron-main/windows.i18n.json | 6 +- .../config/commonEditorConfig.i18n.json | 12 +- .../common/config/editorOptions.i18n.json | 1 + .../find/common/findController.i18n.json | 1 - .../contrib/links/browser/links.i18n.json | 1 + .../browser/referencesModel.i18n.json | 2 - .../suggest/browser/suggestWidget.i18n.json | 1 + ...guageConfigurationExtensionPoint.i18n.json | 1 + .../menusExtensionPoint.i18n.json | 2 + .../common/extensionsRegistry.i18n.json | 6 + .../historyMainService.i18n.json | 11 ++ .../markers/common/problemMatcher.i18n.json | 7 + .../theme/common/colorRegistry.i18n.json | 18 +- .../workbench/api/node/extHostTask.i18n.json | 4 +- .../api/node/extHostTreeViews.i18n.json | 2 + .../activitybar/activitybarPart.i18n.json | 3 +- .../parts/editor/editorStatus.i18n.json | 2 +- .../parts/quickopen/quickopen.i18n.json | 12 ++ .../vs/workbench/browser/quickopen.i18n.json | 3 +- .../vs/workbench/browser/viewlet.i18n.json | 3 +- .../src/vs/workbench/common/theme.i18n.json | 14 ++ .../electron-browser/actions.i18n.json | 9 +- .../main.contribution.i18n.json | 10 +- .../electron-browser/accessibility.i18n.json | 26 +++ .../inspectTMScopes.i18n.json | 6 + .../toggleMultiCursorModifier.i18n.json | 8 + .../debug/browser/debugActions.i18n.json | 1 + .../electron-browser/debugCommands.i18n.json | 4 +- .../electron-browser/debugViews.i18n.json | 4 - .../electronDebugActions.i18n.json | 1 + .../statusbarColorProvider.i18n.json | 3 +- .../parts/debug/node/debugAdapter.i18n.json | 1 + .../actions/editPoints.i18n.json | 4 +- .../emmet.contribution.i18n.json | 3 +- .../browser/extensionEditor.i18n.json | 4 + .../browser/extensionsActions.i18n.json | 9 +- .../extensionTipsService.i18n.json | 2 + .../extensions.contribution.i18n.json | 3 +- .../extensionsUtils.i18n.json | 2 + .../browser/files.contribution.i18n.json | 2 + .../files/browser/views/emptyView.i18n.json | 2 - .../browser/views/openEditorsView.i18n.json | 2 +- .../performance.contribution.i18n.json | 4 +- .../keybindingsEditorContribution.i18n.json | 4 +- .../browser/preferencesRenderers.i18n.json | 1 + .../browser/commandsHandler.i18n.json | 1 + .../relauncher.contribution.i18n.json | 10 + .../dirtydiffDecorator.i18n.json | 6 +- .../browser/searchResultsView.i18n.json | 4 +- .../electron-browser/TMSnippets.i18n.json | 3 +- .../snippets.contribution.i18n.json | 2 +- .../languageSurveys.contribution.i18n.json | 11 ++ .../nps.contribution.i18n.json | 11 ++ .../tasks/browser/buildQuickOpen.i18n.json | 8 + .../parts/tasks/browser/quickOpen.i18n.json | 3 +- .../tasks/browser/testQuickOpen.i18n.json | 8 + .../tasks/common/taskConfiguration.i18n.json | 1 + .../jsonSchemaCommon.i18n.json | 1 + .../electron-browser/jsonSchema_v1.i18n.json | 2 + .../electron-browser/jsonSchema_v2.i18n.json | 4 + .../task.contribution.i18n.json | 3 +- .../terminalTaskSystem.i18n.json | 4 +- .../tasks/node/processTaskSystem.i18n.json | 3 +- .../terminalActions.i18n.json | 6 +- .../terminalColorRegistry.i18n.json | 2 + .../terminalFindWidget.i18n.json | 12 ++ .../terminalInstance.i18n.json | 1 - .../update/electron-browser/update.i18n.json | 15 +- .../parts/views/browser/views.i18n.json | 8 + .../browser/viewsExtensionPoint.i18n.json | 15 ++ .../vs_code_welcome_page.i18n.json | 3 +- .../welcomePage.contribution.i18n.json | 2 - .../electron-browser/welcomePage.i18n.json | 17 +- .../configurationEditingService.i18n.json | 1 + .../common/crashReporterService.i18n.json | 9 + .../browser/progressService2.i18n.json | 9 + i18n/deu/extensions/git/package.i18n.json | 5 +- .../out/codelensProvider.i18n.json | 7 +- .../out/commandHandler.i18n.json | 3 + .../out/mergeDecorator.i18n.json | 5 +- .../merge-conflict/package.i18n.json | 12 +- .../out/features/bufferSyncSupport.i18n.json | 1 - ...rectiveCommentCompletionProvider.i18n.json | 6 +- .../out/utils/projectStatus.i18n.json | 1 - .../out/utils/typingsStatus.i18n.json | 1 + .../extensions/typescript/package.i18n.json | 9 +- .../src/vs/base/common/errorMessage.i18n.json | 1 - .../vs/base/common/keybindingLabels.i18n.json | 6 + .../src/vs/code/electron-main/menus.i18n.json | 11 +- .../vs/code/electron-main/windows.i18n.json | 6 +- .../config/commonEditorConfig.i18n.json | 12 +- .../common/config/editorOptions.i18n.json | 1 + .../common/view/editorColorRegistry.i18n.json | 10 +- .../find/common/findController.i18n.json | 1 - .../browser/referencesModel.i18n.json | 2 - .../browser/referencesWidget.i18n.json | 3 + ...guageConfigurationExtensionPoint.i18n.json | 6 +- .../menusExtensionPoint.i18n.json | 2 + .../common/extensionsRegistry.i18n.json | 6 + .../historyMainService.i18n.json | 11 ++ .../markers/common/problemMatcher.i18n.json | 7 + .../theme/common/colorRegistry.i18n.json | 13 +- .../workbench/api/node/extHostTask.i18n.json | 4 +- .../api/node/extHostTreeViews.i18n.json | 1 + .../browser/actions/configureLocale.i18n.json | 1 + .../activitybar/activitybarPart.i18n.json | 3 +- .../parts/editor/editorStatus.i18n.json | 2 +- .../parts/quickopen/quickopen.i18n.json | 12 ++ .../vs/workbench/browser/quickopen.i18n.json | 3 +- .../vs/workbench/browser/viewlet.i18n.json | 3 +- .../src/vs/workbench/common/theme.i18n.json | 15 ++ .../electron-browser/actions.i18n.json | 9 +- .../main.contribution.i18n.json | 10 +- .../electron-browser/accessibility.i18n.json | 26 +++ .../inspectTMScopes.i18n.json | 6 + .../toggleMultiCursorModifier.i18n.json | 8 + .../debug/browser/debugActions.i18n.json | 1 + .../electron-browser/debugCommands.i18n.json | 4 +- .../electron-browser/debugViews.i18n.json | 4 - .../statusbarColorProvider.i18n.json | 3 +- .../parts/debug/node/debugAdapter.i18n.json | 1 + .../actions/editPoints.i18n.json | 4 +- .../emmet.contribution.i18n.json | 3 +- .../browser/extensionEditor.i18n.json | 4 + .../browser/extensionsActions.i18n.json | 9 +- .../extensionsUtils.i18n.json | 2 + .../browser/files.contribution.i18n.json | 2 + .../files/browser/views/emptyView.i18n.json | 2 - .../browser/views/openEditorsView.i18n.json | 2 +- .../performance.contribution.i18n.json | 3 +- .../keybindingsEditorContribution.i18n.json | 4 +- .../browser/preferencesRenderers.i18n.json | 1 + .../relauncher.contribution.i18n.json | 10 + .../dirtydiffDecorator.i18n.json | 6 +- .../scm.contribution.i18n.json | 1 + .../scm/electron-browser/scmMenus.i18n.json | 1 + .../browser/searchResultsView.i18n.json | 4 +- .../electron-browser/TMSnippets.i18n.json | 3 +- .../snippets.contribution.i18n.json | 2 +- .../languageSurveys.contribution.i18n.json | 11 ++ .../nps.contribution.i18n.json | 11 ++ .../tasks/browser/buildQuickOpen.i18n.json | 8 + .../parts/tasks/browser/quickOpen.i18n.json | 3 +- .../tasks/browser/testQuickOpen.i18n.json | 8 + .../tasks/common/taskConfiguration.i18n.json | 1 + .../jsonSchemaCommon.i18n.json | 1 + .../electron-browser/jsonSchema_v1.i18n.json | 2 + .../electron-browser/jsonSchema_v2.i18n.json | 4 + .../task.contribution.i18n.json | 4 +- .../terminalTaskSystem.i18n.json | 4 +- .../tasks/node/processTaskSystem.i18n.json | 3 +- .../terminalActions.i18n.json | 6 +- .../terminalColorRegistry.i18n.json | 2 + .../terminalFindWidget.i18n.json | 12 ++ .../terminalInstance.i18n.json | 1 - .../themes.contribution.i18n.json | 1 + .../update/electron-browser/update.i18n.json | 15 +- .../parts/views/browser/views.i18n.json | 8 + .../browser/viewsExtensionPoint.i18n.json | 15 ++ .../vs_code_welcome_page.i18n.json | 5 +- .../welcomePage.contribution.i18n.json | 2 - .../electron-browser/welcomePage.i18n.json | 16 +- .../walkThroughPart.i18n.json | 3 +- .../configurationEditingService.i18n.json | 8 +- .../common/crashReporterService.i18n.json | 9 + .../browser/progressService2.i18n.json | 9 + i18n/esn/extensions/git/package.i18n.json | 2 +- .../out/codelensProvider.i18n.json | 7 +- .../out/commandHandler.i18n.json | 2 + .../merge-conflict/package.i18n.json | 8 + .../out/features/bufferSyncSupport.i18n.json | 1 - .../out/utils/projectStatus.i18n.json | 1 - .../out/utils/typingsStatus.i18n.json | 1 + .../extensions/typescript/package.i18n.json | 6 +- .../resourceviewer/resourceViewer.i18n.json | 1 + .../src/vs/base/common/errorMessage.i18n.json | 1 - .../vs/base/common/keybindingLabels.i18n.json | 6 + .../src/vs/code/electron-main/menus.i18n.json | 7 +- .../vs/code/electron-main/windows.i18n.json | 6 +- .../config/commonEditorConfig.i18n.json | 11 +- .../common/config/editorOptions.i18n.json | 1 + .../common/view/editorColorRegistry.i18n.json | 6 +- .../find/common/findController.i18n.json | 1 - .../contrib/links/browser/links.i18n.json | 1 + .../browser/referencesModel.i18n.json | 2 - .../menusExtensionPoint.i18n.json | 6 +- .../common/extensionsRegistry.i18n.json | 6 + .../historyMainService.i18n.json | 11 ++ .../theme/common/colorRegistry.i18n.json | 11 +- .../workbench/api/node/extHostTask.i18n.json | 4 +- .../activitybar/activitybarPart.i18n.json | 3 +- .../parts/editor/editorStatus.i18n.json | 2 +- .../parts/quickopen/quickopen.i18n.json | 12 ++ .../vs/workbench/browser/quickopen.i18n.json | 3 +- .../vs/workbench/browser/viewlet.i18n.json | 3 +- .../src/vs/workbench/common/theme.i18n.json | 11 ++ .../electron-browser/actions.i18n.json | 9 +- .../main.contribution.i18n.json | 8 +- .../electron-browser/accessibility.i18n.json | 26 +++ .../inspectTMScopes.i18n.json | 6 + .../toggleMultiCursorModifier.i18n.json | 8 + .../electron-browser/debugViews.i18n.json | 4 - .../actions/editPoints.i18n.json | 4 +- .../emmet.contribution.i18n.json | 3 +- .../browser/extensionEditor.i18n.json | 4 + .../browser/extensionsActions.i18n.json | 9 +- .../extensionsUtils.i18n.json | 2 + .../browser/files.contribution.i18n.json | 1 - .../files/browser/views/emptyView.i18n.json | 2 - .../browser/views/openEditorsView.i18n.json | 2 +- .../keybindingsEditorContribution.i18n.json | 4 +- .../relauncher.contribution.i18n.json | 10 + .../dirtydiffDecorator.i18n.json | 6 +- .../electron-browser/TMSnippets.i18n.json | 3 +- .../snippets.contribution.i18n.json | 2 +- .../languageSurveys.contribution.i18n.json | 11 ++ .../nps.contribution.i18n.json | 11 ++ .../tasks/browser/buildQuickOpen.i18n.json | 8 + .../parts/tasks/browser/quickOpen.i18n.json | 3 +- .../tasks/browser/testQuickOpen.i18n.json | 8 + .../tasks/common/taskConfiguration.i18n.json | 1 + .../jsonSchemaCommon.i18n.json | 1 + .../electron-browser/jsonSchema_v1.i18n.json | 2 + .../electron-browser/jsonSchema_v2.i18n.json | 4 + .../task.contribution.i18n.json | 3 +- .../terminalTaskSystem.i18n.json | 1 + .../terminalActions.i18n.json | 4 +- .../terminalFindWidget.i18n.json | 12 ++ .../terminalInstance.i18n.json | 1 - .../update/electron-browser/update.i18n.json | 15 +- .../parts/views/browser/views.i18n.json | 8 + .../browser/viewsExtensionPoint.i18n.json | 15 ++ .../vs_code_welcome_page.i18n.json | 1 - .../welcomePage.contribution.i18n.json | 2 - .../electron-browser/welcomePage.i18n.json | 17 +- .../common/crashReporterService.i18n.json | 9 + .../browser/progressService2.i18n.json | 9 + .../fra/extensions/git/out/commands.i18n.json | 4 + i18n/fra/extensions/git/package.i18n.json | 7 +- i18n/fra/extensions/jake/out/main.i18n.json | 4 +- i18n/fra/extensions/jake/package.i18n.json | 4 +- .../markdown/out/extension.i18n.json | 4 +- .../out/codelensProvider.i18n.json | 7 +- .../out/commandHandler.i18n.json | 8 +- .../out/mergeDecorator.i18n.json | 5 +- .../merge-conflict/package.i18n.json | 16 +- i18n/fra/extensions/npm/package.i18n.json | 4 +- .../out/features/bufferSyncSupport.i18n.json | 1 - ...rectiveCommentCompletionProvider.i18n.json | 6 +- .../out/utils/projectStatus.i18n.json | 1 - .../out/utils/typingsStatus.i18n.json | 1 + .../extensions/typescript/package.i18n.json | 11 +- .../resourceviewer/resourceViewer.i18n.json | 1 + .../src/vs/base/common/errorMessage.i18n.json | 1 - .../vs/base/common/keybindingLabels.i18n.json | 6 + .../src/vs/code/electron-main/menus.i18n.json | 12 +- .../vs/code/electron-main/windows.i18n.json | 6 +- .../config/commonEditorConfig.i18n.json | 12 +- .../common/config/editorOptions.i18n.json | 1 + .../common/view/editorColorRegistry.i18n.json | 6 +- .../find/common/findController.i18n.json | 1 - .../contrib/links/browser/links.i18n.json | 1 + .../browser/referencesModel.i18n.json | 2 - .../browser/referencesWidget.i18n.json | 3 + .../suggest/browser/suggestWidget.i18n.json | 1 + .../menusExtensionPoint.i18n.json | 2 + .../common/extensionsRegistry.i18n.json | 6 + .../historyMainService.i18n.json | 11 ++ .../markers/common/problemMatcher.i18n.json | 7 + .../theme/common/colorRegistry.i18n.json | 17 +- .../workbench/api/node/extHostTask.i18n.json | 4 +- .../api/node/extHostTreeViews.i18n.json | 6 +- .../browser/actions/configureLocale.i18n.json | 1 + .../activitybar/activitybarPart.i18n.json | 3 +- .../parts/editor/editorStatus.i18n.json | 2 +- .../parts/quickopen/quickopen.i18n.json | 12 ++ .../vs/workbench/browser/quickopen.i18n.json | 3 +- .../vs/workbench/browser/viewlet.i18n.json | 3 +- .../src/vs/workbench/common/theme.i18n.json | 15 ++ .../electron-browser/actions.i18n.json | 9 +- .../main.contribution.i18n.json | 10 +- .../electron-browser/accessibility.i18n.json | 26 +++ .../inspectTMScopes.i18n.json | 6 + .../toggleMultiCursorModifier.i18n.json | 8 + .../debug/browser/debugActions.i18n.json | 1 + .../electron-browser/debugCommands.i18n.json | 4 +- .../electron-browser/debugViews.i18n.json | 4 - .../electronDebugActions.i18n.json | 1 + .../statusbarColorProvider.i18n.json | 3 +- .../parts/debug/node/debugAdapter.i18n.json | 1 + .../actions/editPoints.i18n.json | 4 +- .../emmet.contribution.i18n.json | 3 +- .../browser/extensionEditor.i18n.json | 4 + .../browser/extensionsActions.i18n.json | 9 +- .../extensionTipsService.i18n.json | 2 + .../extensions.contribution.i18n.json | 3 +- .../extensionsUtils.i18n.json | 2 + .../browser/files.contribution.i18n.json | 2 + .../files/browser/views/emptyView.i18n.json | 2 - .../browser/views/openEditorsView.i18n.json | 2 +- .../performance.contribution.i18n.json | 4 +- .../keybindingsEditorContribution.i18n.json | 4 +- .../browser/preferencesRenderers.i18n.json | 1 + .../browser/commandsHandler.i18n.json | 1 + .../relauncher.contribution.i18n.json | 10 + .../dirtydiffDecorator.i18n.json | 6 +- .../scm.contribution.i18n.json | 1 + .../scm/electron-browser/scmMenus.i18n.json | 1 + .../browser/searchResultsView.i18n.json | 4 +- .../electron-browser/TMSnippets.i18n.json | 3 +- .../snippets.contribution.i18n.json | 2 +- .../languageSurveys.contribution.i18n.json | 11 ++ .../nps.contribution.i18n.json | 11 ++ .../tasks/browser/buildQuickOpen.i18n.json | 8 + .../parts/tasks/browser/quickOpen.i18n.json | 3 +- .../tasks/browser/testQuickOpen.i18n.json | 8 + .../tasks/common/taskConfiguration.i18n.json | 1 + .../jsonSchemaCommon.i18n.json | 1 + .../electron-browser/jsonSchema_v1.i18n.json | 2 + .../electron-browser/jsonSchema_v2.i18n.json | 4 + .../task.contribution.i18n.json | 4 +- .../terminalTaskSystem.i18n.json | 4 +- .../tasks/node/processTaskSystem.i18n.json | 3 +- .../terminalActions.i18n.json | 6 +- .../terminalColorRegistry.i18n.json | 2 + .../terminalFindWidget.i18n.json | 12 ++ .../terminalInstance.i18n.json | 1 - .../themes.contribution.i18n.json | 1 + .../update/electron-browser/update.i18n.json | 15 +- .../parts/views/browser/views.i18n.json | 8 + .../browser/viewsExtensionPoint.i18n.json | 15 ++ .../vs_code_welcome_page.i18n.json | 8 +- .../welcomePage.contribution.i18n.json | 2 - .../electron-browser/welcomePage.i18n.json | 20 +- .../walkThroughPart.i18n.json | 3 +- .../configurationEditingService.i18n.json | 8 +- .../common/crashReporterService.i18n.json | 9 + .../browser/progressService2.i18n.json | 9 + .../out/settingsDocumentHelper.i18n.json | 36 ++++ .../css/client/out/cssMain.i18n.json | 8 + i18n/hun/extensions/css/package.i18n.json | 67 +++++++ .../out/packageDocumentHelper.i18n.json | 9 + .../extensions/git/out/askpass-main.i18n.json | 6 + .../hun/extensions/git/out/commands.i18n.json | 17 ++ i18n/hun/extensions/git/out/main.i18n.json | 8 + i18n/hun/extensions/git/out/model.i18n.json | 11 ++ .../extensions/git/out/scmProvider.i18n.json | 8 + .../extensions/git/out/statusbar.i18n.json | 8 + i18n/hun/extensions/git/package.i18n.json | 24 +++ i18n/hun/extensions/grunt/out/main.i18n.json | 8 + i18n/hun/extensions/grunt/package.i18n.json | 8 + i18n/hun/extensions/gulp/out/main.i18n.json | 8 + i18n/hun/extensions/gulp/package.i18n.json | 8 + .../html/client/out/htmlMain.i18n.json | 8 + i18n/hun/extensions/html/package.i18n.json | 27 +++ i18n/hun/extensions/jake/out/main.i18n.json | 8 + i18n/hun/extensions/jake/package.i18n.json | 8 + .../features/bowerJSONContribution.i18n.json | 10 + .../packageJSONContribution.i18n.json | 13 ++ .../json/client/out/jsonMain.i18n.json | 8 + i18n/hun/extensions/json/package.i18n.json | 15 ++ .../markdown/out/extension.i18n.json | 8 + .../out/previewContentProvider.i18n.json | 10 + .../markdown/out/security.i18n.json | 11 ++ .../hun/extensions/markdown/package.i18n.json | 22 +++ .../out/codelensProvider.i18n.json | 11 ++ .../out/commandHandler.i18n.json | 13 ++ .../out/mergeDecorator.i18n.json | 9 + .../merge-conflict/package.i18n.json | 20 ++ i18n/hun/extensions/npm/package.i18n.json | 8 + .../out/features/validationProvider.i18n.json | 13 ++ i18n/hun/extensions/php/package.i18n.json | 14 ++ .../out/features/bufferSyncSupport.i18n.json | 12 ++ .../features/completionItemProvider.i18n.json | 9 + ...rectiveCommentCompletionProvider.i18n.json | 10 + .../implementationsCodeLensProvider.i18n.json | 10 + .../jsDocCompletionProvider.i18n.json | 8 + .../referencesCodeLensProvider.i18n.json | 10 + .../typescript/out/typescriptMain.i18n.json | 15 ++ .../out/typescriptServiceClient.i18n.json | 24 +++ .../typescript/out/utils/logger.i18n.json | 8 + .../out/utils/projectStatus.i18n.json | 11 ++ .../out/utils/typingsStatus.i18n.json | 12 ++ .../extensions/typescript/package.i18n.json | 48 +++++ .../browser/ui/actionbar/actionbar.i18n.json | 8 + .../vs/base/browser/ui/aria/aria.i18n.json | 8 + .../browser/ui/findinput/findInput.i18n.json | 8 + .../findinput/findInputCheckboxes.i18n.json | 10 + .../browser/ui/inputbox/inputBox.i18n.json | 10 + .../resourceviewer/resourceViewer.i18n.json | 16 ++ .../base/browser/ui/toolbar/toolbar.i18n.json | 8 + .../src/vs/base/common/errorMessage.i18n.json | 17 ++ .../base/common/jsonErrorMessages.i18n.json | 16 ++ .../vs/base/common/keybindingLabels.i18n.json | 6 + .../src/vs/base/common/processes.i18n.json | 11 ++ .../hun/src/vs/base/common/severity.i18n.json | 10 + i18n/hun/src/vs/base/node/processes.i18n.json | 8 + i18n/hun/src/vs/base/node/zip.i18n.json | 8 + .../browser/quickOpenModel.i18n.json | 9 + .../browser/quickOpenWidget.i18n.json | 9 + .../parts/tree/browser/treeDefaults.i18n.json | 8 + .../src/vs/code/electron-main/menus.i18n.json | 178 ++++++++++++++++++ .../vs/code/electron-main/window.i18n.json | 8 + .../vs/code/electron-main/windows.i18n.json | 17 ++ .../src/vs/code/node/cliProcessMain.i18n.json | 17 ++ .../config/commonEditorConfig.i18n.json | 88 +++++++++ .../common/config/editorOptions.i18n.json | 9 + .../editor/common/controller/cursor.i18n.json | 8 + .../model/textModelWithTokens.i18n.json | 8 + .../common/modes/modesRegistry.i18n.json | 8 + .../editor/common/services/bulkEdit.i18n.json | 11 ++ .../common/services/modeServiceImpl.i18n.json | 16 ++ .../services/modelServiceImpl.i18n.json | 9 + .../common/view/editorColorRegistry.i18n.json | 24 +++ .../common/bracketMatching.i18n.json | 8 + .../common/caretOperations.i18n.json | 9 + .../common/transpose.i18n.json | 8 + .../clipboard/browser/clipboard.i18n.json | 11 ++ .../contrib/comment/common/comment.i18n.json | 11 ++ .../contextmenu/browser/contextmenu.i18n.json | 8 + .../contrib/find/browser/findWidget.i18n.json | 21 +++ .../find/common/findController.i18n.json | 18 ++ .../contrib/folding/browser/folding.i18n.json | 14 ++ .../format/browser/formatActions.i18n.json | 13 ++ .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../gotoError/browser/gotoError.i18n.json | 13 ++ .../contrib/hover/browser/hover.i18n.json | 8 + .../hover/browser/modesContentHover.i18n.json | 8 + .../common/inPlaceReplace.i18n.json | 9 + .../indentation/common/indentation.i18n.json | 15 ++ .../common/linesOperations.i18n.json | 25 +++ .../contrib/links/browser/links.i18n.json | 13 ++ .../multicursor/common/multicursor.i18n.json | 10 + .../browser/parameterHints.i18n.json | 8 + .../browser/parameterHintsWidget.i18n.json | 8 + .../browser/quickFixCommands.i18n.json | 10 + .../browser/referenceSearch.i18n.json | 9 + .../browser/referencesController.i18n.json | 8 + .../browser/referencesModel.i18n.json | 14 ++ .../browser/referencesWidget.i18n.json | 27 +++ .../contrib/rename/browser/rename.i18n.json | 11 ++ .../rename/browser/renameInputField.i18n.json | 8 + .../smartSelect/common/smartSelect.i18n.json | 9 + .../browser/suggestController.i18n.json | 9 + .../suggest/browser/suggestWidget.i18n.json | 21 +++ .../common/toggleTabFocusMode.i18n.json | 8 + .../common/wordHighlighter.i18n.json | 9 + .../browser/peekViewWidget.i18n.json | 8 + .../textMate/TMSyntax.i18n.json | 14 ++ ...guageConfigurationExtensionPoint.i18n.json | 23 +++ .../editor/node/textMate/TMGrammars.i18n.json | 13 ++ .../browser/menuItemActionItem.i18n.json | 8 + .../menusExtensionPoint.i18n.json | 43 +++++ .../common/configurationRegistry.i18n.json | 19 ++ .../platform/environment/node/argv.i18n.json | 32 ++++ .../extensionEnablementService.i18n.json | 8 + .../common/extensionManagement.i18n.json | 9 + .../node/extensionGalleryService.i18n.json | 9 + .../node/extensionManagementService.i18n.json | 22 +++ .../common/abstractExtensionService.i18n.json | 11 ++ .../common/extensionsRegistry.i18n.json | 30 +++ .../node/extensionValidator.i18n.json | 24 +++ .../historyMainService.i18n.json | 11 ++ .../node/integrityServiceImpl.i18n.json | 11 ++ .../jsonValidationExtensionPoint.i18n.json | 15 ++ .../abstractKeybindingService.i18n.json | 9 + .../markers/common/problemMatcher.i18n.json | 61 ++++++ .../platform/message/common/message.i18n.json | 10 + .../platform/request/node/request.i18n.json | 11 ++ .../common/telemetryService.i18n.json | 9 + .../theme/common/colorRegistry.i18n.json | 88 +++++++++ .../mainThreadExtensionService.i18n.json | 9 + .../mainThreadMessageService.i18n.json | 10 + .../api/node/extHostDiagnostics.i18n.json | 8 + .../workbench/api/node/extHostTask.i18n.json | 8 + .../api/node/extHostTreeViews.i18n.json | 10 + .../browser/actions/configureLocale.i18n.json | 13 ++ .../browser/actions/fileActions.i18n.json | 9 + .../toggleActivityBarVisibility.i18n.json | 9 + .../actions/toggleEditorLayout.i18n.json | 11 ++ .../actions/toggleSidebarPosition.i18n.json | 9 + .../actions/toggleSidebarVisibility.i18n.json | 9 + .../toggleStatusbarVisibility.i18n.json | 9 + .../browser/actions/toggleZenMode.i18n.json | 9 + .../activitybar/activitybarActions.i18n.json | 14 ++ .../activitybar/activitybarPart.i18n.json | 10 + .../browser/parts/compositePart.i18n.json | 9 + .../parts/editor/binaryDiffEditor.i18n.json | 8 + .../parts/editor/binaryEditor.i18n.json | 8 + .../editor/editor.contribution.i18n.json | 16 ++ .../parts/editor/editorActions.i18n.json | 56 ++++++ .../parts/editor/editorCommands.i18n.json | 12 ++ .../browser/parts/editor/editorPart.i18n.json | 14 ++ .../parts/editor/editorPicker.i18n.json | 13 ++ .../parts/editor/editorStatus.i18n.json | 51 +++++ .../parts/editor/tabsTitleControl.i18n.json | 8 + .../parts/editor/textDiffEditor.i18n.json | 16 ++ .../browser/parts/editor/textEditor.i18n.json | 8 + .../parts/editor/textResourceEditor.i18n.json | 12 ++ .../parts/editor/titleControl.i18n.json | 15 ++ .../parts/panel/panelActions.i18n.json | 15 ++ .../browser/parts/panel/panelPart.i18n.json | 8 + .../quickopen/quickOpenController.i18n.json | 17 ++ .../parts/quickopen/quickopen.i18n.json | 12 ++ .../parts/sidebar/sidebarPart.i18n.json | 9 + .../parts/statusbar/statusbarPart.i18n.json | 9 + .../parts/titlebar/titlebarPart.i18n.json | 9 + .../vs/workbench/browser/quickopen.i18n.json | 10 + .../vs/workbench/browser/viewlet.i18n.json | 8 + .../src/vs/workbench/common/theme.i18n.json | 61 ++++++ .../electron-browser/actions.i18n.json | 43 +++++ .../electron-browser/commands.i18n.json | 8 + .../electron-browser/extensionHost.i18n.json | 11 ++ .../main.contribution.i18n.json | 69 +++++++ .../workbench/electron-browser/main.i18n.json | 9 + .../electron-browser/shell.i18n.json | 8 + .../electron-browser/window.i18n.json | 15 ++ .../electron-browser/workbench.i18n.json | 9 + .../node/extensionHostMain.i18n.json | 8 + .../workbench/node/extensionPoints.i18n.json | 11 ++ .../cli.contribution.i18n.json | 18 ++ .../electron-browser/accessibility.i18n.json | 26 +++ .../inspectKeybindings.i18n.json | 8 + .../inspectTMScopes.i18n.json | 6 + .../toggleMultiCursorModifier.i18n.json | 8 + .../toggleRenderControlCharacter.i18n.json | 8 + .../toggleRenderWhitespace.i18n.json | 8 + .../electron-browser/toggleWordWrap.i18n.json | 11 ++ .../wordWrapMigration.i18n.json | 11 ++ .../debug/browser/breakpointWidget.i18n.json | 13 ++ .../debug/browser/debugActionItems.i18n.json | 9 + .../debug/browser/debugActions.i18n.json | 49 +++++ .../browser/debugActionsWidget.i18n.json | 8 + .../browser/debugContentProvider.i18n.json | 8 + .../browser/debugEditorActions.i18n.json | 15 ++ .../browser/debugEditorModelManager.i18n.json | 11 ++ .../debug/browser/debugQuickOpen.i18n.json | 11 ++ .../debug/browser/exceptionWidget.i18n.json | 11 ++ .../debug/browser/linkDetector.i18n.json | 9 + .../parts/debug/common/debug.i18n.json | 8 + .../parts/debug/common/debugModel.i18n.json | 9 + .../parts/debug/common/debugSource.i18n.json | 8 + .../debug.contribution.i18n.json | 20 ++ .../electron-browser/debugCommands.i18n.json | 8 + .../debugConfigurationManager.i18n.json | 38 ++++ .../debugEditorContribution.i18n.json | 20 ++ .../electron-browser/debugHover.i18n.json | 8 + .../electron-browser/debugService.i18n.json | 25 +++ .../electron-browser/debugViewer.i18n.json | 28 +++ .../electron-browser/debugViews.i18n.json | 16 ++ .../electronDebugActions.i18n.json | 11 ++ .../rawDebugSession.i18n.json | 12 ++ .../debug/electron-browser/repl.i18n.json | 12 ++ .../electron-browser/replViewer.i18n.json | 12 ++ .../statusbarColorProvider.i18n.json | 9 + .../terminalSupport.i18n.json | 9 + .../parts/debug/node/debugAdapter.i18n.json | 20 ++ .../actions/showEmmetCommands.i18n.json | 8 + .../actions/balance.i18n.json | 9 + .../actions/editPoints.i18n.json | 9 + .../actions/evaluateMath.i18n.json | 8 + .../actions/expandAbbreviation.i18n.json | 8 + .../actions/incrementDecrement.i18n.json | 13 ++ .../actions/matchingPair.i18n.json | 8 + .../actions/mergeLines.i18n.json | 8 + .../actions/reflectCssValue.i18n.json | 8 + .../actions/removeTag.i18n.json | 8 + .../actions/selectItem.i18n.json | 9 + .../actions/splitJoinTag.i18n.json | 8 + .../actions/toggleComment.i18n.json | 8 + .../actions/updateImageSize.i18n.json | 8 + .../actions/updateTag.i18n.json | 10 + .../actions/wrapWithAbbreviation.i18n.json | 10 + .../emmet.contribution.i18n.json | 14 ++ .../terminal.contribution.i18n.json | 15 ++ .../terminalService.i18n.json | 12 ++ .../treeExplorer.contribution.i18n.json | 14 ++ .../browser/treeExplorerActions.i18n.json | 8 + .../browser/treeExplorerService.i18n.json | 8 + .../browser/views/treeExplorerView.i18n.json | 8 + .../browser/dependenciesViewer.i18n.json | 9 + .../browser/extensionEditor.i18n.json | 43 +++++ .../browser/extensionsActions.i18n.json | 62 ++++++ .../browser/extensionsQuickOpen.i18n.json | 10 + .../common/extensionsFileTemplate.i18n.json | 10 + .../common/extensionsInput.i18n.json | 8 + .../extensionTipsService.i18n.json | 16 ++ .../extensions.contribution.i18n.json | 15 ++ .../extensionsActions.i18n.json | 11 ++ .../extensionsUtils.i18n.json | 13 ++ .../extensionsViewlet.i18n.json | 15 ++ .../node/extensionsWorkbenchService.i18n.json | 17 ++ .../electron-browser/feedback.i18n.json | 25 +++ .../editors/binaryFileEditor.i18n.json | 8 + .../browser/editors/textFileEditor.i18n.json | 11 ++ .../fileActions.contribution.i18n.json | 11 ++ .../parts/files/browser/fileActions.i18n.json | 73 +++++++ .../files/browser/fileCommands.i18n.json | 9 + .../browser/files.contribution.i18n.json | 41 ++++ .../files/browser/saveErrorHandler.i18n.json | 16 ++ .../files/browser/views/emptyView.i18n.json | 9 + .../browser/views/explorerView.i18n.json | 9 + .../browser/views/explorerViewer.i18n.json | 12 ++ .../browser/views/openEditorsView.i18n.json | 11 ++ .../browser/views/openEditorsViewer.i18n.json | 14 ++ .../files/common/dirtyFilesTracker.i18n.json | 8 + .../common/editors/fileEditorInput.i18n.json | 8 + .../html/browser/html.contribution.i18n.json | 8 + .../html/browser/htmlPreviewPart.i18n.json | 8 + .../parts/html/browser/webview.i18n.json | 8 + .../parts/markers/common/messages.i18n.json | 39 ++++ .../markersElectronContributions.i18n.json | 8 + .../nps.contribution.i18n.json | 11 ++ .../browser/output.contribution.i18n.json | 10 + .../output/browser/outputActions.i18n.json | 11 ++ .../output/browser/outputPanel.i18n.json | 9 + .../parts/output/common/output.i18n.json | 9 + .../performance.contribution.i18n.json | 15 ++ .../browser/keybindingWidgets.i18n.json | 9 + .../browser/keybindingsEditor.i18n.json | 35 ++++ .../keybindingsEditorContribution.i18n.json | 11 ++ .../preferences.contribution.i18n.json | 10 + .../browser/preferencesActions.i18n.json | 14 ++ .../browser/preferencesEditor.i18n.json | 15 ++ .../browser/preferencesRenderers.i18n.json | 13 ++ .../browser/preferencesService.i18n.json | 13 ++ .../browser/preferencesWidgets.i18n.json | 10 + .../common/keybindingsEditorModel.i18n.json | 11 ++ .../common/preferencesModels.i18n.json | 9 + .../browser/commandsHandler.i18n.json | 19 ++ .../browser/gotoLineHandler.i18n.json | 14 ++ .../browser/gotoSymbolHandler.i18n.json | 34 ++++ .../quickopen/browser/helpHandler.i18n.json | 10 + .../browser/quickopen.contribution.i18n.json | 14 ++ .../browser/viewPickerHandler.i18n.json | 15 ++ .../relauncher.contribution.i18n.json | 10 + .../dirtydiffDecorator.i18n.json | 10 + .../scm.contribution.i18n.json | 12 ++ .../electron-browser/scmActivity.i18n.json | 8 + .../scm/electron-browser/scmMenus.i18n.json | 9 + .../scm/electron-browser/scmViewlet.i18n.json | 10 + .../browser/openAnythingHandler.i18n.json | 9 + .../search/browser/openFileHandler.i18n.json | 9 + .../browser/openSymbolHandler.i18n.json | 11 ++ .../browser/patternInputWidget.i18n.json | 12 ++ .../search/browser/replaceService.i18n.json | 8 + .../browser/search.contribution.i18n.json | 22 +++ .../search/browser/searchActions.i18n.json | 21 +++ .../browser/searchResultsView.i18n.json | 12 ++ .../search/browser/searchViewlet.i18n.json | 50 +++++ .../search/browser/searchWidget.i18n.json | 15 ++ .../electron-browser/TMSnippets.i18n.json | 14 ++ .../electron-browser/insertSnippet.i18n.json | 8 + .../snippets.contribution.i18n.json | 16 ++ .../snippetsService.i18n.json | 9 + .../electron-browser/tabCompletion.i18n.json | 8 + .../languageSurveys.contribution.i18n.json | 11 ++ .../nps.contribution.i18n.json | 11 ++ .../tasks/browser/buildQuickOpen.i18n.json | 10 + .../parts/tasks/browser/quickOpen.i18n.json | 9 + .../tasks/browser/restartQuickOpen.i18n.json | 10 + .../tasks/browser/taskQuickOpen.i18n.json | 10 + .../browser/terminateQuickOpen.i18n.json | 10 + .../tasks/browser/testQuickOpen.i18n.json | 10 + .../tasks/common/taskConfiguration.i18n.json | 17 ++ .../tasks/common/taskTemplates.i18n.json | 13 ++ .../jsonSchemaCommon.i18n.json | 39 ++++ .../electron-browser/jsonSchema_v1.i18n.json | 14 ++ .../electron-browser/jsonSchema_v2.i18n.json | 17 ++ .../task.contribution.i18n.json | 51 +++++ .../terminalTaskSystem.i18n.json | 12 ++ .../node/processRunnerDetector.i18n.json | 15 ++ .../tasks/node/processTaskSystem.i18n.json | 12 ++ .../terminal.contribution.i18n.json | 30 +++ .../terminalActions.i18n.json | 37 ++++ .../terminalColorRegistry.i18n.json | 10 + .../terminalConfigHelper.i18n.json | 10 + .../terminalFindWidget.i18n.json | 12 ++ .../terminalInstance.i18n.json | 11 ++ .../terminalLinkHandler.i18n.json | 9 + .../electron-browser/terminalPanel.i18n.json | 11 ++ .../terminalService.i18n.json | 15 ++ .../themes.contribution.i18n.json | 19 ++ ...edWorkspaceSettings.contribution.i18n.json | 11 ++ .../releaseNotesInput.i18n.json | 8 + .../update.contribution.i18n.json | 10 + .../update/electron-browser/update.i18n.json | 32 ++++ .../parts/views/browser/views.i18n.json | 8 + .../browser/viewsExtensionPoint.i18n.json | 16 ++ .../electron-browser/watermark.i18n.json | 24 +++ .../overlay/browser/welcomeOverlay.i18n.json | 17 ++ .../vs_code_welcome_page.i18n.json | 43 +++++ .../welcomePage.contribution.i18n.json | 8 + .../electron-browser/welcomePage.i18n.json | 38 ++++ .../editor/editorWalkThrough.i18n.json | 9 + .../walkThrough.contribution.i18n.json | 10 + .../walkThroughActions.i18n.json | 11 ++ .../walkThroughPart.i18n.json | 10 + .../configurationEditingService.i18n.json | 17 ++ .../common/crashReporterService.i18n.json | 9 + .../editor/browser/editorService.i18n.json | 8 + .../electron-browser/fileService.i18n.json | 11 ++ .../services/files/node/fileService.i18n.json | 14 ++ .../common/keybindingEditing.i18n.json | 11 ++ .../keybindingService.i18n.json | 26 +++ .../message/browser/messageList.i18n.json | 14 ++ .../electron-browser/messageService.i18n.json | 9 + .../common/workbenchModeService.i18n.json | 16 ++ .../browser/progressService2.i18n.json | 9 + .../common/textFileEditorModel.i18n.json | 9 + .../textfile/common/textFileService.i18n.json | 8 + .../textFileService.i18n.json | 18 ++ .../themes/common/colorThemeSchema.i18n.json | 11 ++ .../common/fileIconThemeSchema.i18n.json | 37 ++++ .../electron-browser/colorThemeData.i18n.json | 13 ++ .../workbenchThemeService.i18n.json | 32 ++++ .../extensions/git/out/statusbar.i18n.json | 2 +- i18n/ita/extensions/git/package.i18n.json | 2 +- .../out/codelensProvider.i18n.json | 7 +- .../out/commandHandler.i18n.json | 1 + .../merge-conflict/package.i18n.json | 8 + .../out/features/bufferSyncSupport.i18n.json | 1 - .../out/utils/projectStatus.i18n.json | 1 - .../out/utils/typingsStatus.i18n.json | 1 + .../extensions/typescript/package.i18n.json | 3 +- .../src/vs/base/common/errorMessage.i18n.json | 1 - .../vs/base/common/keybindingLabels.i18n.json | 6 + .../src/vs/code/electron-main/menus.i18n.json | 12 +- .../vs/code/electron-main/windows.i18n.json | 6 +- .../config/commonEditorConfig.i18n.json | 8 +- .../common/config/editorOptions.i18n.json | 1 + .../find/common/findController.i18n.json | 1 - .../browser/referencesModel.i18n.json | 2 - .../menusExtensionPoint.i18n.json | 2 + .../common/extensionsRegistry.i18n.json | 6 + .../historyMainService.i18n.json | 11 ++ .../theme/common/colorRegistry.i18n.json | 15 +- .../workbench/api/node/extHostTask.i18n.json | 4 +- .../api/node/extHostTreeViews.i18n.json | 6 +- .../browser/actions/configureLocale.i18n.json | 1 + .../activitybar/activitybarPart.i18n.json | 3 +- .../parts/editor/editorStatus.i18n.json | 2 +- .../parts/quickopen/quickopen.i18n.json | 12 ++ .../vs/workbench/browser/quickopen.i18n.json | 3 +- .../vs/workbench/browser/viewlet.i18n.json | 3 +- .../src/vs/workbench/common/theme.i18n.json | 15 ++ .../electron-browser/actions.i18n.json | 9 +- .../main.contribution.i18n.json | 10 +- .../electron-browser/accessibility.i18n.json | 26 +++ .../inspectTMScopes.i18n.json | 6 + .../toggleMultiCursorModifier.i18n.json | 8 + .../debug/browser/debugActions.i18n.json | 1 + .../electron-browser/debugCommands.i18n.json | 4 +- .../electron-browser/debugViews.i18n.json | 4 - .../electronDebugActions.i18n.json | 1 + .../statusbarColorProvider.i18n.json | 3 +- .../parts/debug/node/debugAdapter.i18n.json | 1 + .../actions/editPoints.i18n.json | 4 +- .../emmet.contribution.i18n.json | 3 +- .../browser/extensionEditor.i18n.json | 4 + .../browser/extensionsActions.i18n.json | 9 +- .../extensionTipsService.i18n.json | 2 + .../extensions.contribution.i18n.json | 3 +- .../extensionsUtils.i18n.json | 2 + .../browser/files.contribution.i18n.json | 2 + .../files/browser/views/emptyView.i18n.json | 2 - .../browser/views/openEditorsView.i18n.json | 2 +- .../keybindingsEditorContribution.i18n.json | 4 +- .../browser/preferencesRenderers.i18n.json | 1 + .../browser/commandsHandler.i18n.json | 1 + .../relauncher.contribution.i18n.json | 10 + .../dirtydiffDecorator.i18n.json | 6 +- .../scm/electron-browser/scmMenus.i18n.json | 1 + .../browser/searchResultsView.i18n.json | 4 +- .../electron-browser/TMSnippets.i18n.json | 3 +- .../snippets.contribution.i18n.json | 2 +- .../languageSurveys.contribution.i18n.json | 11 ++ .../nps.contribution.i18n.json | 11 ++ .../tasks/browser/buildQuickOpen.i18n.json | 8 + .../parts/tasks/browser/quickOpen.i18n.json | 3 +- .../tasks/browser/testQuickOpen.i18n.json | 8 + .../tasks/common/taskConfiguration.i18n.json | 1 + .../jsonSchemaCommon.i18n.json | 1 + .../electron-browser/jsonSchema_v1.i18n.json | 2 + .../electron-browser/jsonSchema_v2.i18n.json | 4 + .../task.contribution.i18n.json | 4 +- .../terminalTaskSystem.i18n.json | 4 +- .../tasks/node/processTaskSystem.i18n.json | 3 +- .../terminalActions.i18n.json | 6 +- .../terminalColorRegistry.i18n.json | 2 + .../terminalFindWidget.i18n.json | 12 ++ .../terminalInstance.i18n.json | 1 - .../update/electron-browser/update.i18n.json | 15 +- .../parts/views/browser/views.i18n.json | 8 + .../browser/viewsExtensionPoint.i18n.json | 15 ++ .../vs_code_welcome_page.i18n.json | 8 +- .../welcomePage.contribution.i18n.json | 2 - .../electron-browser/welcomePage.i18n.json | 20 +- .../walkThroughPart.i18n.json | 3 +- .../configurationEditingService.i18n.json | 3 +- .../common/crashReporterService.i18n.json | 9 + .../browser/progressService2.i18n.json | 9 + i18n/jpn/extensions/git/package.i18n.json | 2 +- .../out/codelensProvider.i18n.json | 7 +- .../out/commandHandler.i18n.json | 1 + .../merge-conflict/package.i18n.json | 8 + .../out/features/bufferSyncSupport.i18n.json | 1 - .../out/utils/projectStatus.i18n.json | 1 - .../out/utils/typingsStatus.i18n.json | 1 + .../extensions/typescript/package.i18n.json | 3 +- .../resourceviewer/resourceViewer.i18n.json | 2 +- .../src/vs/base/common/errorMessage.i18n.json | 1 - .../vs/base/common/keybindingLabels.i18n.json | 6 + .../src/vs/code/electron-main/menus.i18n.json | 4 +- .../vs/code/electron-main/windows.i18n.json | 6 +- .../config/commonEditorConfig.i18n.json | 9 +- .../common/config/editorOptions.i18n.json | 1 + .../find/common/findController.i18n.json | 1 - .../format/browser/formatActions.i18n.json | 2 +- .../gotoError/browser/gotoError.i18n.json | 3 +- .../browser/referencesModel.i18n.json | 2 - .../menusExtensionPoint.i18n.json | 2 + .../platform/environment/node/argv.i18n.json | 16 +- .../common/extensionsRegistry.i18n.json | 6 + .../historyMainService.i18n.json | 11 ++ .../markers/common/problemMatcher.i18n.json | 4 +- .../theme/common/colorRegistry.i18n.json | 12 +- .../workbench/api/node/extHostTask.i18n.json | 4 +- .../activitybar/activitybarPart.i18n.json | 3 +- .../parts/editor/editorStatus.i18n.json | 3 +- .../parts/quickopen/quickopen.i18n.json | 12 ++ .../vs/workbench/browser/quickopen.i18n.json | 3 +- .../vs/workbench/browser/viewlet.i18n.json | 3 +- .../src/vs/workbench/common/theme.i18n.json | 5 + .../electron-browser/actions.i18n.json | 9 +- .../main.contribution.i18n.json | 8 +- .../electron-browser/accessibility.i18n.json | 26 +++ .../inspectTMScopes.i18n.json | 6 + .../toggleMultiCursorModifier.i18n.json | 8 + .../electron-browser/debugViews.i18n.json | 4 - .../actions/editPoints.i18n.json | 4 +- .../emmet.contribution.i18n.json | 3 +- .../browser/extensionEditor.i18n.json | 4 + .../browser/extensionsActions.i18n.json | 8 +- .../browser/files.contribution.i18n.json | 1 - .../files/browser/views/emptyView.i18n.json | 2 - .../browser/views/openEditorsView.i18n.json | 2 +- .../keybindingsEditorContribution.i18n.json | 4 +- .../relauncher.contribution.i18n.json | 10 + .../snippets.contribution.i18n.json | 2 +- .../languageSurveys.contribution.i18n.json | 11 ++ .../nps.contribution.i18n.json | 11 ++ .../tasks/browser/buildQuickOpen.i18n.json | 8 + .../parts/tasks/browser/quickOpen.i18n.json | 3 +- .../tasks/browser/testQuickOpen.i18n.json | 8 + .../tasks/common/taskConfiguration.i18n.json | 1 + .../jsonSchemaCommon.i18n.json | 1 + .../electron-browser/jsonSchema_v1.i18n.json | 2 + .../electron-browser/jsonSchema_v2.i18n.json | 4 + .../task.contribution.i18n.json | 3 +- .../terminalTaskSystem.i18n.json | 1 + .../terminal.contribution.i18n.json | 6 +- .../terminalActions.i18n.json | 10 +- .../terminalFindWidget.i18n.json | 12 ++ .../terminalInstance.i18n.json | 1 - .../electron-browser/terminalPanel.i18n.json | 2 +- .../update/electron-browser/update.i18n.json | 15 +- .../parts/views/browser/views.i18n.json | 8 + .../browser/viewsExtensionPoint.i18n.json | 15 ++ .../vs_code_welcome_page.i18n.json | 1 - .../welcomePage.contribution.i18n.json | 2 - .../electron-browser/welcomePage.i18n.json | 17 +- .../common/crashReporterService.i18n.json | 9 + .../browser/progressService2.i18n.json | 9 + .../kor/extensions/git/out/commands.i18n.json | 4 + i18n/kor/extensions/git/package.i18n.json | 7 +- i18n/kor/extensions/jake/out/main.i18n.json | 4 +- i18n/kor/extensions/jake/package.i18n.json | 4 +- .../markdown/out/extension.i18n.json | 4 +- .../out/codelensProvider.i18n.json | 7 +- .../out/commandHandler.i18n.json | 8 +- .../out/mergeDecorator.i18n.json | 5 +- .../merge-conflict/package.i18n.json | 16 +- i18n/kor/extensions/npm/package.i18n.json | 4 +- .../out/features/bufferSyncSupport.i18n.json | 1 - ...rectiveCommentCompletionProvider.i18n.json | 6 +- .../out/utils/projectStatus.i18n.json | 1 - .../out/utils/typingsStatus.i18n.json | 1 + .../extensions/typescript/package.i18n.json | 11 +- .../resourceviewer/resourceViewer.i18n.json | 1 + .../src/vs/base/common/errorMessage.i18n.json | 1 - .../vs/base/common/keybindingLabels.i18n.json | 6 + .../src/vs/code/electron-main/menus.i18n.json | 12 +- .../vs/code/electron-main/windows.i18n.json | 6 +- .../config/commonEditorConfig.i18n.json | 13 +- .../common/config/editorOptions.i18n.json | 1 + .../common/view/editorColorRegistry.i18n.json | 12 +- .../find/common/findController.i18n.json | 1 - .../contrib/links/browser/links.i18n.json | 1 + .../browser/referencesModel.i18n.json | 2 - .../browser/referencesWidget.i18n.json | 3 + .../suggest/browser/suggestWidget.i18n.json | 1 + ...guageConfigurationExtensionPoint.i18n.json | 6 +- .../menusExtensionPoint.i18n.json | 2 + .../common/extensionsRegistry.i18n.json | 6 + .../historyMainService.i18n.json | 11 ++ .../markers/common/problemMatcher.i18n.json | 7 + .../theme/common/colorRegistry.i18n.json | 26 ++- .../workbench/api/node/extHostTask.i18n.json | 4 +- .../api/node/extHostTreeViews.i18n.json | 6 +- .../browser/actions/configureLocale.i18n.json | 1 + .../activitybar/activitybarPart.i18n.json | 3 +- .../parts/editor/editorStatus.i18n.json | 2 +- .../parts/quickopen/quickopen.i18n.json | 12 ++ .../vs/workbench/browser/quickopen.i18n.json | 3 +- .../vs/workbench/browser/viewlet.i18n.json | 3 +- .../src/vs/workbench/common/theme.i18n.json | 15 ++ .../electron-browser/actions.i18n.json | 9 +- .../main.contribution.i18n.json | 10 +- .../electron-browser/accessibility.i18n.json | 26 +++ .../inspectTMScopes.i18n.json | 6 + .../toggleMultiCursorModifier.i18n.json | 8 + .../debug/browser/debugActions.i18n.json | 1 + .../electron-browser/debugCommands.i18n.json | 4 +- .../electron-browser/debugViews.i18n.json | 4 - .../electronDebugActions.i18n.json | 1 + .../statusbarColorProvider.i18n.json | 3 +- .../parts/debug/node/debugAdapter.i18n.json | 1 + .../actions/editPoints.i18n.json | 4 +- .../emmet.contribution.i18n.json | 3 +- .../browser/extensionEditor.i18n.json | 4 + .../browser/extensionsActions.i18n.json | 9 +- .../extensionTipsService.i18n.json | 2 + .../extensions.contribution.i18n.json | 3 +- .../extensionsUtils.i18n.json | 2 + .../browser/files.contribution.i18n.json | 2 + .../files/browser/views/emptyView.i18n.json | 2 - .../browser/views/openEditorsView.i18n.json | 2 +- .../performance.contribution.i18n.json | 4 +- .../keybindingsEditorContribution.i18n.json | 4 +- .../browser/preferencesRenderers.i18n.json | 1 + .../browser/commandsHandler.i18n.json | 1 + .../relauncher.contribution.i18n.json | 10 + .../dirtydiffDecorator.i18n.json | 6 +- .../scm.contribution.i18n.json | 1 + .../scm/electron-browser/scmMenus.i18n.json | 1 + .../browser/searchResultsView.i18n.json | 4 +- .../electron-browser/TMSnippets.i18n.json | 3 +- .../snippets.contribution.i18n.json | 2 +- .../languageSurveys.contribution.i18n.json | 11 ++ .../nps.contribution.i18n.json | 11 ++ .../tasks/browser/buildQuickOpen.i18n.json | 8 + .../parts/tasks/browser/quickOpen.i18n.json | 3 +- .../tasks/browser/testQuickOpen.i18n.json | 8 + .../tasks/common/taskConfiguration.i18n.json | 1 + .../jsonSchemaCommon.i18n.json | 1 + .../electron-browser/jsonSchema_v1.i18n.json | 2 + .../electron-browser/jsonSchema_v2.i18n.json | 4 + .../task.contribution.i18n.json | 4 +- .../terminalTaskSystem.i18n.json | 4 +- .../tasks/node/processTaskSystem.i18n.json | 3 +- .../terminalActions.i18n.json | 6 +- .../terminalColorRegistry.i18n.json | 2 + .../terminalFindWidget.i18n.json | 12 ++ .../terminalInstance.i18n.json | 1 - .../themes.contribution.i18n.json | 1 + .../update/electron-browser/update.i18n.json | 15 +- .../parts/views/browser/views.i18n.json | 8 + .../browser/viewsExtensionPoint.i18n.json | 15 ++ .../vs_code_welcome_page.i18n.json | 8 +- .../welcomePage.contribution.i18n.json | 2 - .../electron-browser/welcomePage.i18n.json | 20 +- .../walkThroughPart.i18n.json | 3 +- .../configurationEditingService.i18n.json | 8 +- .../common/crashReporterService.i18n.json | 9 + .../browser/progressService2.i18n.json | 9 + .../out/settingsDocumentHelper.i18n.json | 2 +- .../extensions/git/out/statusbar.i18n.json | 4 +- i18n/ptb/extensions/git/package.i18n.json | 2 +- .../out/codelensProvider.i18n.json | 7 +- .../out/commandHandler.i18n.json | 2 + .../out/mergeDecorator.i18n.json | 4 +- .../merge-conflict/package.i18n.json | 8 + .../out/features/bufferSyncSupport.i18n.json | 2 +- .../out/utils/projectStatus.i18n.json | 1 - .../out/utils/typingsStatus.i18n.json | 1 + .../extensions/typescript/package.i18n.json | 4 +- .../src/vs/base/common/errorMessage.i18n.json | 1 - .../vs/base/common/keybindingLabels.i18n.json | 6 + .../src/vs/code/electron-main/menus.i18n.json | 15 +- .../vs/code/electron-main/windows.i18n.json | 6 +- .../config/commonEditorConfig.i18n.json | 11 +- .../common/config/editorOptions.i18n.json | 1 + .../find/common/findController.i18n.json | 1 - .../browser/referencesModel.i18n.json | 4 +- .../menusExtensionPoint.i18n.json | 2 + .../common/extensionsRegistry.i18n.json | 6 + .../historyMainService.i18n.json | 11 ++ .../theme/common/colorRegistry.i18n.json | 4 +- .../workbench/api/node/extHostTask.i18n.json | 4 +- .../activitybar/activitybarPart.i18n.json | 3 +- .../parts/editor/editorActions.i18n.json | 1 + .../parts/editor/editorStatus.i18n.json | 5 +- .../parts/editor/titleControl.i18n.json | 1 + .../parts/quickopen/quickopen.i18n.json | 12 ++ .../vs/workbench/browser/quickopen.i18n.json | 3 +- .../vs/workbench/browser/viewlet.i18n.json | 3 +- .../src/vs/workbench/common/theme.i18n.json | 16 +- .../electron-browser/actions.i18n.json | 18 +- .../main.contribution.i18n.json | 15 +- .../electron-browser/accessibility.i18n.json | 26 +++ .../inspectTMScopes.i18n.json | 6 + .../toggleMultiCursorModifier.i18n.json | 8 + .../electron-browser/debugViews.i18n.json | 4 - .../debug/electron-browser/repl.i18n.json | 3 +- .../actions/editPoints.i18n.json | 4 +- .../emmet.contribution.i18n.json | 3 +- .../browser/extensionEditor.i18n.json | 4 + .../browser/files.contribution.i18n.json | 2 +- .../files/browser/views/emptyView.i18n.json | 2 - .../browser/views/openEditorsView.i18n.json | 2 +- .../browser/views/openEditorsViewer.i18n.json | 1 + .../keybindingsEditorContribution.i18n.json | 4 +- .../browser/commandsHandler.i18n.json | 3 + .../relauncher.contribution.i18n.json | 10 + .../snippets.contribution.i18n.json | 2 +- .../languageSurveys.contribution.i18n.json | 11 ++ .../nps.contribution.i18n.json | 11 ++ .../tasks/browser/buildQuickOpen.i18n.json | 10 + .../parts/tasks/browser/quickOpen.i18n.json | 3 +- .../tasks/browser/testQuickOpen.i18n.json | 10 + .../tasks/common/taskConfiguration.i18n.json | 1 + .../jsonSchemaCommon.i18n.json | 1 + .../electron-browser/jsonSchema_v1.i18n.json | 2 + .../electron-browser/jsonSchema_v2.i18n.json | 4 + .../task.contribution.i18n.json | 8 +- .../terminalTaskSystem.i18n.json | 1 + .../terminalActions.i18n.json | 7 +- .../terminalFindWidget.i18n.json | 12 ++ .../terminalInstance.i18n.json | 2 +- .../update/electron-browser/update.i18n.json | 15 +- .../parts/views/browser/views.i18n.json | 8 + .../browser/viewsExtensionPoint.i18n.json | 16 ++ .../vs_code_welcome_page.i18n.json | 1 - .../welcomePage.contribution.i18n.json | 2 - .../electron-browser/welcomePage.i18n.json | 17 +- .../common/crashReporterService.i18n.json | 9 + .../browser/progressService2.i18n.json | 9 + .../rus/extensions/git/out/commands.i18n.json | 4 + .../extensions/git/out/statusbar.i18n.json | 2 +- i18n/rus/extensions/git/package.i18n.json | 7 +- i18n/rus/extensions/jake/out/main.i18n.json | 4 +- i18n/rus/extensions/jake/package.i18n.json | 4 +- .../markdown/out/extension.i18n.json | 4 +- .../out/codelensProvider.i18n.json | 7 +- .../out/commandHandler.i18n.json | 8 +- .../out/mergeDecorator.i18n.json | 5 +- .../merge-conflict/package.i18n.json | 16 +- i18n/rus/extensions/npm/package.i18n.json | 4 +- .../out/features/bufferSyncSupport.i18n.json | 1 - ...rectiveCommentCompletionProvider.i18n.json | 6 +- .../out/utils/projectStatus.i18n.json | 1 - .../out/utils/typingsStatus.i18n.json | 1 + .../extensions/typescript/package.i18n.json | 11 +- .../resourceviewer/resourceViewer.i18n.json | 1 + .../src/vs/base/common/errorMessage.i18n.json | 1 - .../vs/base/common/keybindingLabels.i18n.json | 6 + .../src/vs/code/electron-main/menus.i18n.json | 10 +- .../vs/code/electron-main/windows.i18n.json | 6 +- .../config/commonEditorConfig.i18n.json | 13 +- .../common/config/editorOptions.i18n.json | 1 + .../common/view/editorColorRegistry.i18n.json | 12 +- .../find/common/findController.i18n.json | 1 - .../contrib/links/browser/links.i18n.json | 1 + .../browser/referencesModel.i18n.json | 2 - .../browser/referencesWidget.i18n.json | 3 + .../suggest/browser/suggestWidget.i18n.json | 1 + ...guageConfigurationExtensionPoint.i18n.json | 6 +- .../menusExtensionPoint.i18n.json | 2 + .../common/extensionsRegistry.i18n.json | 6 + .../historyMainService.i18n.json | 11 ++ .../markers/common/problemMatcher.i18n.json | 7 + .../theme/common/colorRegistry.i18n.json | 14 +- .../workbench/api/node/extHostTask.i18n.json | 4 +- .../api/node/extHostTreeViews.i18n.json | 6 +- .../browser/actions/configureLocale.i18n.json | 1 + .../activitybar/activitybarPart.i18n.json | 3 +- .../parts/editor/editorStatus.i18n.json | 2 +- .../parts/quickopen/quickopen.i18n.json | 12 ++ .../vs/workbench/browser/quickopen.i18n.json | 3 +- .../vs/workbench/browser/viewlet.i18n.json | 3 +- .../src/vs/workbench/common/theme.i18n.json | 15 ++ .../electron-browser/actions.i18n.json | 9 +- .../main.contribution.i18n.json | 10 +- .../electron-browser/accessibility.i18n.json | 26 +++ .../inspectTMScopes.i18n.json | 6 + .../toggleMultiCursorModifier.i18n.json | 8 + .../debug/browser/debugActions.i18n.json | 1 + .../electron-browser/debugCommands.i18n.json | 4 +- .../electron-browser/debugViews.i18n.json | 4 - .../electronDebugActions.i18n.json | 1 + .../statusbarColorProvider.i18n.json | 3 +- .../parts/debug/node/debugAdapter.i18n.json | 1 + .../actions/editPoints.i18n.json | 4 +- .../emmet.contribution.i18n.json | 3 +- .../browser/extensionEditor.i18n.json | 4 + .../browser/extensionsActions.i18n.json | 9 +- .../extensionTipsService.i18n.json | 2 + .../extensions.contribution.i18n.json | 3 +- .../extensionsUtils.i18n.json | 2 + .../browser/files.contribution.i18n.json | 2 + .../files/browser/views/emptyView.i18n.json | 2 - .../browser/views/openEditorsView.i18n.json | 2 +- .../performance.contribution.i18n.json | 4 +- .../keybindingsEditorContribution.i18n.json | 4 +- .../browser/preferencesRenderers.i18n.json | 1 + .../browser/commandsHandler.i18n.json | 1 + .../relauncher.contribution.i18n.json | 10 + .../dirtydiffDecorator.i18n.json | 6 +- .../scm.contribution.i18n.json | 1 + .../scm/electron-browser/scmMenus.i18n.json | 1 + .../browser/searchResultsView.i18n.json | 4 +- .../electron-browser/TMSnippets.i18n.json | 3 +- .../snippets.contribution.i18n.json | 2 +- .../languageSurveys.contribution.i18n.json | 11 ++ .../nps.contribution.i18n.json | 11 ++ .../tasks/browser/buildQuickOpen.i18n.json | 8 + .../parts/tasks/browser/quickOpen.i18n.json | 3 +- .../tasks/browser/testQuickOpen.i18n.json | 8 + .../tasks/common/taskConfiguration.i18n.json | 1 + .../jsonSchemaCommon.i18n.json | 1 + .../electron-browser/jsonSchema_v1.i18n.json | 2 + .../electron-browser/jsonSchema_v2.i18n.json | 4 + .../task.contribution.i18n.json | 4 +- .../terminalTaskSystem.i18n.json | 4 +- .../tasks/node/processTaskSystem.i18n.json | 3 +- .../terminalActions.i18n.json | 6 +- .../terminalColorRegistry.i18n.json | 2 + .../terminalFindWidget.i18n.json | 12 ++ .../terminalInstance.i18n.json | 1 - .../themes.contribution.i18n.json | 1 + .../update/electron-browser/update.i18n.json | 15 +- .../parts/views/browser/views.i18n.json | 8 + .../browser/viewsExtensionPoint.i18n.json | 15 ++ .../vs_code_welcome_page.i18n.json | 8 +- .../welcomePage.contribution.i18n.json | 2 - .../electron-browser/welcomePage.i18n.json | 20 +- .../walkThroughPart.i18n.json | 3 +- .../configurationEditingService.i18n.json | 8 +- .../common/crashReporterService.i18n.json | 9 + .../browser/progressService2.i18n.json | 9 + .../out/settingsDocumentHelper.i18n.json | 36 ++++ .../css/client/out/cssMain.i18n.json | 8 + i18n/trk/extensions/css/package.i18n.json | 67 +++++++ .../out/packageDocumentHelper.i18n.json | 9 + .../extensions/git/out/askpass-main.i18n.json | 8 + .../trk/extensions/git/out/commands.i18n.json | 46 +++++ i18n/trk/extensions/git/out/main.i18n.json | 11 ++ i18n/trk/extensions/git/out/model.i18n.json | 14 ++ .../extensions/git/out/scmProvider.i18n.json | 8 + .../extensions/git/out/statusbar.i18n.json | 11 ++ i18n/trk/extensions/git/package.i18n.json | 49 +++++ i18n/trk/extensions/grunt/out/main.i18n.json | 8 + i18n/trk/extensions/grunt/package.i18n.json | 8 + i18n/trk/extensions/gulp/out/main.i18n.json | 8 + i18n/trk/extensions/gulp/package.i18n.json | 8 + .../html/client/out/htmlMain.i18n.json | 8 + i18n/trk/extensions/html/package.i18n.json | 27 +++ i18n/trk/extensions/jake/out/main.i18n.json | 8 + i18n/trk/extensions/jake/package.i18n.json | 8 + .../features/bowerJSONContribution.i18n.json | 10 + .../packageJSONContribution.i18n.json | 13 ++ .../json/client/out/jsonMain.i18n.json | 8 + i18n/trk/extensions/json/package.i18n.json | 15 ++ .../markdown/out/extension.i18n.json | 8 + .../out/previewContentProvider.i18n.json | 10 + .../markdown/out/security.i18n.json | 11 ++ .../trk/extensions/markdown/package.i18n.json | 22 +++ .../out/codelensProvider.i18n.json | 11 ++ .../out/commandHandler.i18n.json | 13 ++ .../out/mergeDecorator.i18n.json | 9 + .../merge-conflict/package.i18n.json | 20 ++ i18n/trk/extensions/npm/package.i18n.json | 8 + .../out/features/validationProvider.i18n.json | 13 ++ i18n/trk/extensions/php/package.i18n.json | 14 ++ .../out/features/bufferSyncSupport.i18n.json | 12 ++ .../features/completionItemProvider.i18n.json | 9 + ...rectiveCommentCompletionProvider.i18n.json | 10 + .../implementationsCodeLensProvider.i18n.json | 10 + .../jsDocCompletionProvider.i18n.json | 8 + .../referencesCodeLensProvider.i18n.json | 10 + .../typescript/out/typescriptMain.i18n.json | 15 ++ .../out/typescriptServiceClient.i18n.json | 24 +++ .../typescript/out/utils/logger.i18n.json | 8 + .../out/utils/projectStatus.i18n.json | 11 ++ .../out/utils/typingsStatus.i18n.json | 12 ++ .../extensions/typescript/package.i18n.json | 48 +++++ .../browser/ui/actionbar/actionbar.i18n.json | 8 + .../vs/base/browser/ui/aria/aria.i18n.json | 8 + .../browser/ui/findinput/findInput.i18n.json | 8 + .../findinput/findInputCheckboxes.i18n.json | 10 + .../browser/ui/inputbox/inputBox.i18n.json | 10 + .../resourceviewer/resourceViewer.i18n.json | 16 ++ .../base/browser/ui/toolbar/toolbar.i18n.json | 8 + .../src/vs/base/common/errorMessage.i18n.json | 17 ++ .../base/common/jsonErrorMessages.i18n.json | 16 ++ .../vs/base/common/keybindingLabels.i18n.json | 6 + .../src/vs/base/common/processes.i18n.json | 11 ++ .../trk/src/vs/base/common/severity.i18n.json | 10 + i18n/trk/src/vs/base/node/processes.i18n.json | 8 + i18n/trk/src/vs/base/node/zip.i18n.json | 8 + .../browser/quickOpenModel.i18n.json | 9 + .../browser/quickOpenWidget.i18n.json | 9 + .../parts/tree/browser/treeDefaults.i18n.json | 8 + .../src/vs/code/electron-main/menus.i18n.json | 178 ++++++++++++++++++ .../vs/code/electron-main/window.i18n.json | 8 + .../vs/code/electron-main/windows.i18n.json | 17 ++ .../src/vs/code/node/cliProcessMain.i18n.json | 17 ++ .../config/commonEditorConfig.i18n.json | 88 +++++++++ .../common/config/editorOptions.i18n.json | 9 + .../editor/common/controller/cursor.i18n.json | 8 + .../model/textModelWithTokens.i18n.json | 8 + .../common/modes/modesRegistry.i18n.json | 8 + .../editor/common/services/bulkEdit.i18n.json | 11 ++ .../common/services/modeServiceImpl.i18n.json | 16 ++ .../services/modelServiceImpl.i18n.json | 9 + .../common/view/editorColorRegistry.i18n.json | 24 +++ .../common/bracketMatching.i18n.json | 8 + .../common/caretOperations.i18n.json | 9 + .../common/transpose.i18n.json | 8 + .../clipboard/browser/clipboard.i18n.json | 11 ++ .../contrib/comment/common/comment.i18n.json | 11 ++ .../contextmenu/browser/contextmenu.i18n.json | 8 + .../contrib/find/browser/findWidget.i18n.json | 21 +++ .../find/common/findController.i18n.json | 18 ++ .../contrib/folding/browser/folding.i18n.json | 14 ++ .../format/browser/formatActions.i18n.json | 13 ++ .../browser/goToDeclarationCommands.i18n.json | 23 +++ .../browser/goToDeclarationMouse.i18n.json | 8 + .../gotoError/browser/gotoError.i18n.json | 13 ++ .../contrib/hover/browser/hover.i18n.json | 8 + .../hover/browser/modesContentHover.i18n.json | 8 + .../common/inPlaceReplace.i18n.json | 9 + .../indentation/common/indentation.i18n.json | 15 ++ .../common/linesOperations.i18n.json | 25 +++ .../contrib/links/browser/links.i18n.json | 13 ++ .../multicursor/common/multicursor.i18n.json | 10 + .../browser/parameterHints.i18n.json | 8 + .../browser/parameterHintsWidget.i18n.json | 8 + .../browser/quickFixCommands.i18n.json | 10 + .../browser/referenceSearch.i18n.json | 9 + .../browser/referencesController.i18n.json | 8 + .../browser/referencesModel.i18n.json | 14 ++ .../browser/referencesWidget.i18n.json | 27 +++ .../contrib/rename/browser/rename.i18n.json | 11 ++ .../rename/browser/renameInputField.i18n.json | 8 + .../smartSelect/common/smartSelect.i18n.json | 9 + .../browser/suggestController.i18n.json | 9 + .../suggest/browser/suggestWidget.i18n.json | 21 +++ .../common/toggleTabFocusMode.i18n.json | 8 + .../common/wordHighlighter.i18n.json | 9 + .../browser/peekViewWidget.i18n.json | 8 + .../textMate/TMSyntax.i18n.json | 14 ++ ...guageConfigurationExtensionPoint.i18n.json | 23 +++ .../editor/node/textMate/TMGrammars.i18n.json | 13 ++ .../browser/menuItemActionItem.i18n.json | 8 + .../menusExtensionPoint.i18n.json | 43 +++++ .../common/configurationRegistry.i18n.json | 19 ++ .../platform/environment/node/argv.i18n.json | 32 ++++ .../extensionEnablementService.i18n.json | 8 + .../common/extensionManagement.i18n.json | 9 + .../node/extensionGalleryService.i18n.json | 9 + .../node/extensionManagementService.i18n.json | 22 +++ .../common/abstractExtensionService.i18n.json | 11 ++ .../common/extensionsRegistry.i18n.json | 30 +++ .../node/extensionValidator.i18n.json | 24 +++ .../historyMainService.i18n.json | 11 ++ .../node/integrityServiceImpl.i18n.json | 11 ++ .../jsonValidationExtensionPoint.i18n.json | 15 ++ .../abstractKeybindingService.i18n.json | 9 + .../markers/common/problemMatcher.i18n.json | 61 ++++++ .../platform/message/common/message.i18n.json | 10 + .../platform/request/node/request.i18n.json | 11 ++ .../common/telemetryService.i18n.json | 9 + .../theme/common/colorRegistry.i18n.json | 88 +++++++++ .../mainThreadExtensionService.i18n.json | 9 + .../mainThreadMessageService.i18n.json | 10 + .../api/node/extHostDiagnostics.i18n.json | 8 + .../workbench/api/node/extHostTask.i18n.json | 8 + .../api/node/extHostTreeViews.i18n.json | 10 + .../browser/actions/configureLocale.i18n.json | 13 ++ .../browser/actions/fileActions.i18n.json | 9 + .../toggleActivityBarVisibility.i18n.json | 9 + .../actions/toggleEditorLayout.i18n.json | 11 ++ .../actions/toggleSidebarPosition.i18n.json | 9 + .../actions/toggleSidebarVisibility.i18n.json | 9 + .../toggleStatusbarVisibility.i18n.json | 9 + .../browser/actions/toggleZenMode.i18n.json | 9 + .../activitybar/activitybarActions.i18n.json | 14 ++ .../activitybar/activitybarPart.i18n.json | 10 + .../browser/parts/compositePart.i18n.json | 9 + .../parts/editor/binaryDiffEditor.i18n.json | 8 + .../parts/editor/binaryEditor.i18n.json | 8 + .../editor/editor.contribution.i18n.json | 16 ++ .../parts/editor/editorActions.i18n.json | 56 ++++++ .../parts/editor/editorCommands.i18n.json | 12 ++ .../browser/parts/editor/editorPart.i18n.json | 14 ++ .../parts/editor/editorPicker.i18n.json | 13 ++ .../parts/editor/editorStatus.i18n.json | 51 +++++ .../parts/editor/tabsTitleControl.i18n.json | 8 + .../parts/editor/textDiffEditor.i18n.json | 16 ++ .../browser/parts/editor/textEditor.i18n.json | 8 + .../parts/editor/textResourceEditor.i18n.json | 12 ++ .../parts/editor/titleControl.i18n.json | 15 ++ .../parts/panel/panelActions.i18n.json | 15 ++ .../browser/parts/panel/panelPart.i18n.json | 8 + .../quickopen/quickOpenController.i18n.json | 17 ++ .../parts/quickopen/quickopen.i18n.json | 12 ++ .../parts/sidebar/sidebarPart.i18n.json | 9 + .../parts/statusbar/statusbarPart.i18n.json | 9 + .../parts/titlebar/titlebarPart.i18n.json | 9 + .../vs/workbench/browser/quickopen.i18n.json | 10 + .../vs/workbench/browser/viewlet.i18n.json | 8 + .../src/vs/workbench/common/theme.i18n.json | 61 ++++++ .../electron-browser/actions.i18n.json | 43 +++++ .../electron-browser/commands.i18n.json | 8 + .../electron-browser/extensionHost.i18n.json | 11 ++ .../main.contribution.i18n.json | 69 +++++++ .../workbench/electron-browser/main.i18n.json | 9 + .../electron-browser/shell.i18n.json | 8 + .../electron-browser/window.i18n.json | 15 ++ .../electron-browser/workbench.i18n.json | 9 + .../node/extensionHostMain.i18n.json | 8 + .../workbench/node/extensionPoints.i18n.json | 11 ++ .../cli.contribution.i18n.json | 18 ++ .../electron-browser/accessibility.i18n.json | 26 +++ .../inspectKeybindings.i18n.json | 8 + .../inspectTMScopes.i18n.json | 6 + .../toggleMultiCursorModifier.i18n.json | 8 + .../toggleRenderControlCharacter.i18n.json | 8 + .../toggleRenderWhitespace.i18n.json | 8 + .../electron-browser/toggleWordWrap.i18n.json | 11 ++ .../wordWrapMigration.i18n.json | 11 ++ .../debug/browser/breakpointWidget.i18n.json | 13 ++ .../debug/browser/debugActionItems.i18n.json | 9 + .../debug/browser/debugActions.i18n.json | 49 +++++ .../browser/debugActionsWidget.i18n.json | 8 + .../browser/debugContentProvider.i18n.json | 8 + .../browser/debugEditorActions.i18n.json | 15 ++ .../browser/debugEditorModelManager.i18n.json | 11 ++ .../debug/browser/debugQuickOpen.i18n.json | 11 ++ .../debug/browser/exceptionWidget.i18n.json | 11 ++ .../debug/browser/linkDetector.i18n.json | 9 + .../parts/debug/common/debug.i18n.json | 8 + .../parts/debug/common/debugModel.i18n.json | 9 + .../parts/debug/common/debugSource.i18n.json | 8 + .../debug.contribution.i18n.json | 20 ++ .../electron-browser/debugCommands.i18n.json | 8 + .../debugConfigurationManager.i18n.json | 38 ++++ .../debugEditorContribution.i18n.json | 20 ++ .../electron-browser/debugHover.i18n.json | 8 + .../electron-browser/debugService.i18n.json | 25 +++ .../electron-browser/debugViewer.i18n.json | 28 +++ .../electron-browser/debugViews.i18n.json | 16 ++ .../electronDebugActions.i18n.json | 11 ++ .../rawDebugSession.i18n.json | 12 ++ .../debug/electron-browser/repl.i18n.json | 12 ++ .../electron-browser/replViewer.i18n.json | 12 ++ .../statusbarColorProvider.i18n.json | 9 + .../terminalSupport.i18n.json | 9 + .../parts/debug/node/debugAdapter.i18n.json | 20 ++ .../actions/showEmmetCommands.i18n.json | 8 + .../actions/balance.i18n.json | 9 + .../actions/editPoints.i18n.json | 9 + .../actions/evaluateMath.i18n.json | 8 + .../actions/expandAbbreviation.i18n.json | 8 + .../actions/incrementDecrement.i18n.json | 13 ++ .../actions/matchingPair.i18n.json | 8 + .../actions/mergeLines.i18n.json | 8 + .../actions/reflectCssValue.i18n.json | 8 + .../actions/removeTag.i18n.json | 8 + .../actions/selectItem.i18n.json | 9 + .../actions/splitJoinTag.i18n.json | 8 + .../actions/toggleComment.i18n.json | 8 + .../actions/updateImageSize.i18n.json | 8 + .../actions/updateTag.i18n.json | 10 + .../actions/wrapWithAbbreviation.i18n.json | 10 + .../emmet.contribution.i18n.json | 14 ++ .../terminal.contribution.i18n.json | 15 ++ .../terminalService.i18n.json | 12 ++ .../treeExplorer.contribution.i18n.json | 14 ++ .../browser/treeExplorerActions.i18n.json | 8 + .../browser/treeExplorerService.i18n.json | 8 + .../browser/views/treeExplorerView.i18n.json | 8 + .../browser/dependenciesViewer.i18n.json | 9 + .../browser/extensionEditor.i18n.json | 43 +++++ .../browser/extensionsActions.i18n.json | 62 ++++++ .../browser/extensionsQuickOpen.i18n.json | 10 + .../common/extensionsFileTemplate.i18n.json | 10 + .../common/extensionsInput.i18n.json | 8 + .../extensionTipsService.i18n.json | 16 ++ .../extensions.contribution.i18n.json | 15 ++ .../extensionsActions.i18n.json | 11 ++ .../extensionsUtils.i18n.json | 13 ++ .../extensionsViewlet.i18n.json | 15 ++ .../node/extensionsWorkbenchService.i18n.json | 17 ++ .../electron-browser/feedback.i18n.json | 25 +++ .../editors/binaryFileEditor.i18n.json | 8 + .../browser/editors/textFileEditor.i18n.json | 11 ++ .../fileActions.contribution.i18n.json | 11 ++ .../parts/files/browser/fileActions.i18n.json | 73 +++++++ .../files/browser/fileCommands.i18n.json | 9 + .../browser/files.contribution.i18n.json | 41 ++++ .../files/browser/saveErrorHandler.i18n.json | 16 ++ .../files/browser/views/emptyView.i18n.json | 9 + .../browser/views/explorerView.i18n.json | 9 + .../browser/views/explorerViewer.i18n.json | 12 ++ .../browser/views/openEditorsView.i18n.json | 11 ++ .../browser/views/openEditorsViewer.i18n.json | 14 ++ .../files/common/dirtyFilesTracker.i18n.json | 8 + .../common/editors/fileEditorInput.i18n.json | 8 + .../html/browser/html.contribution.i18n.json | 8 + .../html/browser/htmlPreviewPart.i18n.json | 8 + .../parts/html/browser/webview.i18n.json | 8 + .../parts/markers/common/messages.i18n.json | 39 ++++ .../markersElectronContributions.i18n.json | 8 + .../nps.contribution.i18n.json | 11 ++ .../browser/output.contribution.i18n.json | 10 + .../output/browser/outputActions.i18n.json | 11 ++ .../output/browser/outputPanel.i18n.json | 9 + .../parts/output/common/output.i18n.json | 9 + .../performance.contribution.i18n.json | 15 ++ .../browser/keybindingWidgets.i18n.json | 9 + .../browser/keybindingsEditor.i18n.json | 35 ++++ .../keybindingsEditorContribution.i18n.json | 11 ++ .../preferences.contribution.i18n.json | 10 + .../browser/preferencesActions.i18n.json | 14 ++ .../browser/preferencesEditor.i18n.json | 15 ++ .../browser/preferencesRenderers.i18n.json | 13 ++ .../browser/preferencesService.i18n.json | 13 ++ .../browser/preferencesWidgets.i18n.json | 10 + .../common/keybindingsEditorModel.i18n.json | 11 ++ .../common/preferencesModels.i18n.json | 9 + .../browser/commandsHandler.i18n.json | 19 ++ .../browser/gotoLineHandler.i18n.json | 14 ++ .../browser/gotoSymbolHandler.i18n.json | 34 ++++ .../quickopen/browser/helpHandler.i18n.json | 10 + .../browser/quickopen.contribution.i18n.json | 14 ++ .../browser/viewPickerHandler.i18n.json | 15 ++ .../relauncher.contribution.i18n.json | 10 + .../dirtydiffDecorator.i18n.json | 10 + .../scm.contribution.i18n.json | 12 ++ .../electron-browser/scmActivity.i18n.json | 8 + .../scm/electron-browser/scmMenus.i18n.json | 9 + .../scm/electron-browser/scmViewlet.i18n.json | 10 + .../browser/openAnythingHandler.i18n.json | 9 + .../search/browser/openFileHandler.i18n.json | 9 + .../browser/openSymbolHandler.i18n.json | 11 ++ .../browser/patternInputWidget.i18n.json | 12 ++ .../search/browser/replaceService.i18n.json | 8 + .../browser/search.contribution.i18n.json | 22 +++ .../search/browser/searchActions.i18n.json | 21 +++ .../browser/searchResultsView.i18n.json | 12 ++ .../search/browser/searchViewlet.i18n.json | 50 +++++ .../search/browser/searchWidget.i18n.json | 15 ++ .../electron-browser/TMSnippets.i18n.json | 14 ++ .../electron-browser/insertSnippet.i18n.json | 8 + .../snippets.contribution.i18n.json | 16 ++ .../snippetsService.i18n.json | 9 + .../electron-browser/tabCompletion.i18n.json | 8 + .../languageSurveys.contribution.i18n.json | 11 ++ .../nps.contribution.i18n.json | 11 ++ .../tasks/browser/buildQuickOpen.i18n.json | 10 + .../parts/tasks/browser/quickOpen.i18n.json | 9 + .../tasks/browser/restartQuickOpen.i18n.json | 10 + .../tasks/browser/taskQuickOpen.i18n.json | 10 + .../browser/terminateQuickOpen.i18n.json | 10 + .../tasks/browser/testQuickOpen.i18n.json | 10 + .../tasks/common/taskConfiguration.i18n.json | 17 ++ .../tasks/common/taskTemplates.i18n.json | 13 ++ .../jsonSchemaCommon.i18n.json | 39 ++++ .../electron-browser/jsonSchema_v1.i18n.json | 14 ++ .../electron-browser/jsonSchema_v2.i18n.json | 17 ++ .../task.contribution.i18n.json | 51 +++++ .../terminalTaskSystem.i18n.json | 12 ++ .../node/processRunnerDetector.i18n.json | 15 ++ .../tasks/node/processTaskSystem.i18n.json | 12 ++ .../terminal.contribution.i18n.json | 30 +++ .../terminalActions.i18n.json | 37 ++++ .../terminalColorRegistry.i18n.json | 10 + .../terminalConfigHelper.i18n.json | 10 + .../terminalFindWidget.i18n.json | 12 ++ .../terminalInstance.i18n.json | 11 ++ .../terminalLinkHandler.i18n.json | 9 + .../electron-browser/terminalPanel.i18n.json | 11 ++ .../terminalService.i18n.json | 15 ++ .../themes.contribution.i18n.json | 19 ++ ...edWorkspaceSettings.contribution.i18n.json | 11 ++ .../releaseNotesInput.i18n.json | 8 + .../update.contribution.i18n.json | 10 + .../update/electron-browser/update.i18n.json | 32 ++++ .../parts/views/browser/views.i18n.json | 8 + .../browser/viewsExtensionPoint.i18n.json | 16 ++ .../electron-browser/watermark.i18n.json | 24 +++ .../overlay/browser/welcomeOverlay.i18n.json | 17 ++ .../vs_code_welcome_page.i18n.json | 43 +++++ .../welcomePage.contribution.i18n.json | 8 + .../electron-browser/welcomePage.i18n.json | 38 ++++ .../editor/editorWalkThrough.i18n.json | 9 + .../walkThrough.contribution.i18n.json | 10 + .../walkThroughActions.i18n.json | 11 ++ .../walkThroughPart.i18n.json | 10 + .../configurationEditingService.i18n.json | 17 ++ .../common/crashReporterService.i18n.json | 9 + .../editor/browser/editorService.i18n.json | 8 + .../electron-browser/fileService.i18n.json | 11 ++ .../services/files/node/fileService.i18n.json | 14 ++ .../common/keybindingEditing.i18n.json | 11 ++ .../keybindingService.i18n.json | 26 +++ .../message/browser/messageList.i18n.json | 14 ++ .../electron-browser/messageService.i18n.json | 9 + .../common/workbenchModeService.i18n.json | 16 ++ .../browser/progressService2.i18n.json | 9 + .../common/textFileEditorModel.i18n.json | 9 + .../textfile/common/textFileService.i18n.json | 8 + .../textFileService.i18n.json | 18 ++ .../themes/common/colorThemeSchema.i18n.json | 11 ++ .../common/fileIconThemeSchema.i18n.json | 37 ++++ .../electron-browser/colorThemeData.i18n.json | 13 ++ .../workbenchThemeService.i18n.json | 32 ++++ 1622 files changed, 15568 insertions(+), 796 deletions(-) create mode 100644 build/win32/i18n/messages.hu.isl create mode 100644 build/win32/i18n/messages.tr.isl create mode 100644 i18n/chs/src/vs/base/common/keybindingLabels.i18n.json create mode 100644 i18n/chs/src/vs/platform/history/electron-main/historyMainService.i18n.json create mode 100644 i18n/chs/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json create mode 100644 i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json create mode 100644 i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json create mode 100644 i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json create mode 100644 i18n/chs/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json create mode 100644 i18n/chs/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json create mode 100644 i18n/chs/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json create mode 100644 i18n/chs/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json create mode 100644 i18n/chs/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json create mode 100644 i18n/chs/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json create mode 100644 i18n/chs/src/vs/workbench/parts/views/browser/views.i18n.json create mode 100644 i18n/chs/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json create mode 100644 i18n/chs/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json create mode 100644 i18n/chs/src/vs/workbench/services/progress/browser/progressService2.i18n.json create mode 100644 i18n/cht/src/vs/base/common/keybindingLabels.i18n.json create mode 100644 i18n/cht/src/vs/platform/history/electron-main/historyMainService.i18n.json create mode 100644 i18n/cht/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json create mode 100644 i18n/cht/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json create mode 100644 i18n/cht/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json create mode 100644 i18n/cht/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json create mode 100644 i18n/cht/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json create mode 100644 i18n/cht/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json create mode 100644 i18n/cht/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json create mode 100644 i18n/cht/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json create mode 100644 i18n/cht/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json create mode 100644 i18n/cht/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json create mode 100644 i18n/cht/src/vs/workbench/parts/views/browser/views.i18n.json create mode 100644 i18n/cht/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json create mode 100644 i18n/cht/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json create mode 100644 i18n/cht/src/vs/workbench/services/progress/browser/progressService2.i18n.json create mode 100644 i18n/deu/src/vs/base/common/keybindingLabels.i18n.json create mode 100644 i18n/deu/src/vs/platform/history/electron-main/historyMainService.i18n.json create mode 100644 i18n/deu/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json create mode 100644 i18n/deu/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json create mode 100644 i18n/deu/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json create mode 100644 i18n/deu/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json create mode 100644 i18n/deu/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json create mode 100644 i18n/deu/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json create mode 100644 i18n/deu/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json create mode 100644 i18n/deu/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json create mode 100644 i18n/deu/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json create mode 100644 i18n/deu/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json create mode 100644 i18n/deu/src/vs/workbench/parts/views/browser/views.i18n.json create mode 100644 i18n/deu/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json create mode 100644 i18n/deu/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json create mode 100644 i18n/deu/src/vs/workbench/services/progress/browser/progressService2.i18n.json create mode 100644 i18n/esn/src/vs/base/common/keybindingLabels.i18n.json create mode 100644 i18n/esn/src/vs/platform/history/electron-main/historyMainService.i18n.json create mode 100644 i18n/esn/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json create mode 100644 i18n/esn/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json create mode 100644 i18n/esn/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json create mode 100644 i18n/esn/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json create mode 100644 i18n/esn/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json create mode 100644 i18n/esn/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json create mode 100644 i18n/esn/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json create mode 100644 i18n/esn/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json create mode 100644 i18n/esn/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json create mode 100644 i18n/esn/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json create mode 100644 i18n/esn/src/vs/workbench/parts/views/browser/views.i18n.json create mode 100644 i18n/esn/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json create mode 100644 i18n/esn/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json create mode 100644 i18n/esn/src/vs/workbench/services/progress/browser/progressService2.i18n.json create mode 100644 i18n/fra/src/vs/base/common/keybindingLabels.i18n.json create mode 100644 i18n/fra/src/vs/platform/history/electron-main/historyMainService.i18n.json create mode 100644 i18n/fra/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json create mode 100644 i18n/fra/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json create mode 100644 i18n/fra/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json create mode 100644 i18n/fra/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json create mode 100644 i18n/fra/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json create mode 100644 i18n/fra/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json create mode 100644 i18n/fra/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json create mode 100644 i18n/fra/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json create mode 100644 i18n/fra/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json create mode 100644 i18n/fra/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json create mode 100644 i18n/fra/src/vs/workbench/parts/views/browser/views.i18n.json create mode 100644 i18n/fra/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json create mode 100644 i18n/fra/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json create mode 100644 i18n/fra/src/vs/workbench/services/progress/browser/progressService2.i18n.json create mode 100644 i18n/hun/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json create mode 100644 i18n/hun/extensions/css/client/out/cssMain.i18n.json create mode 100644 i18n/hun/extensions/css/package.i18n.json create mode 100644 i18n/hun/extensions/extension-editing/out/packageDocumentHelper.i18n.json create mode 100644 i18n/hun/extensions/git/out/askpass-main.i18n.json create mode 100644 i18n/hun/extensions/git/out/commands.i18n.json create mode 100644 i18n/hun/extensions/git/out/main.i18n.json create mode 100644 i18n/hun/extensions/git/out/model.i18n.json create mode 100644 i18n/hun/extensions/git/out/scmProvider.i18n.json create mode 100644 i18n/hun/extensions/git/out/statusbar.i18n.json create mode 100644 i18n/hun/extensions/git/package.i18n.json create mode 100644 i18n/hun/extensions/grunt/out/main.i18n.json create mode 100644 i18n/hun/extensions/grunt/package.i18n.json create mode 100644 i18n/hun/extensions/gulp/out/main.i18n.json create mode 100644 i18n/hun/extensions/gulp/package.i18n.json create mode 100644 i18n/hun/extensions/html/client/out/htmlMain.i18n.json create mode 100644 i18n/hun/extensions/html/package.i18n.json create mode 100644 i18n/hun/extensions/jake/out/main.i18n.json create mode 100644 i18n/hun/extensions/jake/package.i18n.json create mode 100644 i18n/hun/extensions/javascript/out/features/bowerJSONContribution.i18n.json create mode 100644 i18n/hun/extensions/javascript/out/features/packageJSONContribution.i18n.json create mode 100644 i18n/hun/extensions/json/client/out/jsonMain.i18n.json create mode 100644 i18n/hun/extensions/json/package.i18n.json create mode 100644 i18n/hun/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/hun/extensions/markdown/out/previewContentProvider.i18n.json create mode 100644 i18n/hun/extensions/markdown/out/security.i18n.json create mode 100644 i18n/hun/extensions/markdown/package.i18n.json create mode 100644 i18n/hun/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/hun/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/hun/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/hun/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/hun/extensions/npm/package.i18n.json create mode 100644 i18n/hun/extensions/php/out/features/validationProvider.i18n.json create mode 100644 i18n/hun/extensions/php/package.i18n.json create mode 100644 i18n/hun/extensions/typescript/out/features/bufferSyncSupport.i18n.json create mode 100644 i18n/hun/extensions/typescript/out/features/completionItemProvider.i18n.json create mode 100644 i18n/hun/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json create mode 100644 i18n/hun/extensions/typescript/out/features/implementationsCodeLensProvider.i18n.json create mode 100644 i18n/hun/extensions/typescript/out/features/jsDocCompletionProvider.i18n.json create mode 100644 i18n/hun/extensions/typescript/out/features/referencesCodeLensProvider.i18n.json create mode 100644 i18n/hun/extensions/typescript/out/typescriptMain.i18n.json create mode 100644 i18n/hun/extensions/typescript/out/typescriptServiceClient.i18n.json create mode 100644 i18n/hun/extensions/typescript/out/utils/logger.i18n.json create mode 100644 i18n/hun/extensions/typescript/out/utils/projectStatus.i18n.json create mode 100644 i18n/hun/extensions/typescript/out/utils/typingsStatus.i18n.json create mode 100644 i18n/hun/extensions/typescript/package.i18n.json create mode 100644 i18n/hun/src/vs/base/browser/ui/actionbar/actionbar.i18n.json create mode 100644 i18n/hun/src/vs/base/browser/ui/aria/aria.i18n.json create mode 100644 i18n/hun/src/vs/base/browser/ui/findinput/findInput.i18n.json create mode 100644 i18n/hun/src/vs/base/browser/ui/findinput/findInputCheckboxes.i18n.json create mode 100644 i18n/hun/src/vs/base/browser/ui/inputbox/inputBox.i18n.json create mode 100644 i18n/hun/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json create mode 100644 i18n/hun/src/vs/base/browser/ui/toolbar/toolbar.i18n.json create mode 100644 i18n/hun/src/vs/base/common/errorMessage.i18n.json create mode 100644 i18n/hun/src/vs/base/common/jsonErrorMessages.i18n.json create mode 100644 i18n/hun/src/vs/base/common/keybindingLabels.i18n.json create mode 100644 i18n/hun/src/vs/base/common/processes.i18n.json create mode 100644 i18n/hun/src/vs/base/common/severity.i18n.json create mode 100644 i18n/hun/src/vs/base/node/processes.i18n.json create mode 100644 i18n/hun/src/vs/base/node/zip.i18n.json create mode 100644 i18n/hun/src/vs/base/parts/quickopen/browser/quickOpenModel.i18n.json create mode 100644 i18n/hun/src/vs/base/parts/quickopen/browser/quickOpenWidget.i18n.json create mode 100644 i18n/hun/src/vs/base/parts/tree/browser/treeDefaults.i18n.json create mode 100644 i18n/hun/src/vs/code/electron-main/menus.i18n.json create mode 100644 i18n/hun/src/vs/code/electron-main/window.i18n.json create mode 100644 i18n/hun/src/vs/code/electron-main/windows.i18n.json create mode 100644 i18n/hun/src/vs/code/node/cliProcessMain.i18n.json create mode 100644 i18n/hun/src/vs/editor/common/config/commonEditorConfig.i18n.json create mode 100644 i18n/hun/src/vs/editor/common/config/editorOptions.i18n.json create mode 100644 i18n/hun/src/vs/editor/common/controller/cursor.i18n.json create mode 100644 i18n/hun/src/vs/editor/common/model/textModelWithTokens.i18n.json create mode 100644 i18n/hun/src/vs/editor/common/modes/modesRegistry.i18n.json create mode 100644 i18n/hun/src/vs/editor/common/services/bulkEdit.i18n.json create mode 100644 i18n/hun/src/vs/editor/common/services/modeServiceImpl.i18n.json create mode 100644 i18n/hun/src/vs/editor/common/services/modelServiceImpl.i18n.json create mode 100644 i18n/hun/src/vs/editor/common/view/editorColorRegistry.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/bracketMatching/common/bracketMatching.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/caretOperations/common/caretOperations.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/caretOperations/common/transpose.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/clipboard/browser/clipboard.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/comment/common/comment.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/contextmenu/browser/contextmenu.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/find/browser/findWidget.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/find/common/findController.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/folding/browser/folding.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/format/browser/formatActions.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/hover/browser/hover.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/hover/browser/modesContentHover.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/indentation/common/indentation.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/linesOperations/common/linesOperations.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/links/browser/links.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/multicursor/common/multicursor.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/parameterHints/browser/parameterHints.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/quickFix/browser/quickFixCommands.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/referenceSearch/browser/referencesController.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/rename/browser/rename.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/rename/browser/renameInputField.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/smartSelect/common/smartSelect.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/suggest/browser/suggestController.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.i18n.json create mode 100644 i18n/hun/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.i18n.json create mode 100644 i18n/hun/src/vs/editor/electron-browser/textMate/TMSyntax.i18n.json create mode 100644 i18n/hun/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json create mode 100644 i18n/hun/src/vs/editor/node/textMate/TMGrammars.i18n.json create mode 100644 i18n/hun/src/vs/platform/actions/browser/menuItemActionItem.i18n.json create mode 100644 i18n/hun/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json create mode 100644 i18n/hun/src/vs/platform/configuration/common/configurationRegistry.i18n.json create mode 100644 i18n/hun/src/vs/platform/environment/node/argv.i18n.json create mode 100644 i18n/hun/src/vs/platform/extensionManagement/common/extensionEnablementService.i18n.json create mode 100644 i18n/hun/src/vs/platform/extensionManagement/common/extensionManagement.i18n.json create mode 100644 i18n/hun/src/vs/platform/extensionManagement/node/extensionGalleryService.i18n.json create mode 100644 i18n/hun/src/vs/platform/extensionManagement/node/extensionManagementService.i18n.json create mode 100644 i18n/hun/src/vs/platform/extensions/common/abstractExtensionService.i18n.json create mode 100644 i18n/hun/src/vs/platform/extensions/common/extensionsRegistry.i18n.json create mode 100644 i18n/hun/src/vs/platform/extensions/node/extensionValidator.i18n.json create mode 100644 i18n/hun/src/vs/platform/history/electron-main/historyMainService.i18n.json create mode 100644 i18n/hun/src/vs/platform/integrity/node/integrityServiceImpl.i18n.json create mode 100644 i18n/hun/src/vs/platform/jsonschemas/common/jsonValidationExtensionPoint.i18n.json create mode 100644 i18n/hun/src/vs/platform/keybinding/common/abstractKeybindingService.i18n.json create mode 100644 i18n/hun/src/vs/platform/markers/common/problemMatcher.i18n.json create mode 100644 i18n/hun/src/vs/platform/message/common/message.i18n.json create mode 100644 i18n/hun/src/vs/platform/request/node/request.i18n.json create mode 100644 i18n/hun/src/vs/platform/telemetry/common/telemetryService.i18n.json create mode 100644 i18n/hun/src/vs/platform/theme/common/colorRegistry.i18n.json create mode 100644 i18n/hun/src/vs/workbench/api/electron-browser/mainThreadExtensionService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/api/electron-browser/mainThreadMessageService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/api/node/extHostDiagnostics.i18n.json create mode 100644 i18n/hun/src/vs/workbench/api/node/extHostTask.i18n.json create mode 100644 i18n/hun/src/vs/workbench/api/node/extHostTreeViews.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/actions/configureLocale.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/actions/fileActions.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/actions/toggleActivityBarVisibility.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/actions/toggleEditorLayout.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/actions/toggleSidebarPosition.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/actions/toggleSidebarVisibility.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/actions/toggleStatusbarVisibility.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/actions/toggleZenMode.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/activitybar/activitybarActions.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/compositePart.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/editor/binaryDiffEditor.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/editor/binaryEditor.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/editor/editor.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/editor/editorActions.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/editor/editorCommands.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/editor/editorPart.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/editor/editorPicker.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/editor/tabsTitleControl.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/editor/textDiffEditor.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/editor/textEditor.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/editor/textResourceEditor.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/editor/titleControl.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/panel/panelActions.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/panel/panelPart.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/quickopen/quickOpenController.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/sidebar/sidebarPart.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/statusbar/statusbarPart.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/parts/titlebar/titlebarPart.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/quickopen.i18n.json create mode 100644 i18n/hun/src/vs/workbench/browser/viewlet.i18n.json create mode 100644 i18n/hun/src/vs/workbench/common/theme.i18n.json create mode 100644 i18n/hun/src/vs/workbench/electron-browser/actions.i18n.json create mode 100644 i18n/hun/src/vs/workbench/electron-browser/commands.i18n.json create mode 100644 i18n/hun/src/vs/workbench/electron-browser/extensionHost.i18n.json create mode 100644 i18n/hun/src/vs/workbench/electron-browser/main.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/electron-browser/main.i18n.json create mode 100644 i18n/hun/src/vs/workbench/electron-browser/shell.i18n.json create mode 100644 i18n/hun/src/vs/workbench/electron-browser/window.i18n.json create mode 100644 i18n/hun/src/vs/workbench/electron-browser/workbench.i18n.json create mode 100644 i18n/hun/src/vs/workbench/node/extensionHostMain.i18n.json create mode 100644 i18n/hun/src/vs/workbench/node/extensionPoints.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/cli/electron-browser/cli.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderControlCharacter.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderWhitespace.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/wordWrapMigration.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/browser/breakpointWidget.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/browser/debugActionItems.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/browser/debugActions.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/browser/debugActionsWidget.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/browser/debugContentProvider.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/browser/debugEditorActions.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/browser/debugEditorModelManager.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/browser/debugQuickOpen.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/browser/exceptionWidget.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/browser/linkDetector.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/common/debug.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/common/debugModel.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/common/debugSource.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/electron-browser/debug.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugConfigurationManager.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugHover.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugViewer.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/electron-browser/repl.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/electron-browser/replViewer.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/electron-browser/terminalSupport.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/emmet/browser/actions/showEmmetCommands.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/balance.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/matchingPair.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/mergeLines.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/reflectCssValue.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/selectItem.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/toggleComment.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/execution/electron-browser/terminal.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/execution/electron-browser/terminalService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/explorers/browser/treeExplorerActions.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/explorers/browser/treeExplorerService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/explorers/browser/views/treeExplorerView.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/extensions/browser/dependenciesViewer.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/extensions/browser/extensionsQuickOpen.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/extensions/common/extensionsFileTemplate.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/extensions/common/extensionsInput.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/extensions/electron-browser/extensionsActions.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/feedback/electron-browser/feedback.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/files/browser/editors/binaryFileEditor.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/files/browser/editors/textFileEditor.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/files/browser/fileActions.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/files/browser/fileActions.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/files/browser/fileCommands.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/files/browser/files.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/files/browser/saveErrorHandler.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/files/browser/views/explorerView.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/files/browser/views/explorerViewer.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/files/browser/views/openEditorsViewer.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/files/common/dirtyFilesTracker.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/html/browser/html.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/html/browser/htmlPreviewPart.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/html/browser/webview.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/markers/common/messages.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/markers/electron-browser/markersElectronContributions.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/nps/electron-browser/nps.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/output/browser/output.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/output/browser/outputActions.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/output/browser/outputPanel.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/output/common/output.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/preferences/browser/keybindingWidgets.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/preferences/browser/preferences.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/preferences/browser/preferencesEditor.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/preferences/browser/preferencesService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/preferences/browser/preferencesWidgets.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/preferences/common/preferencesModels.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/quickopen/browser/gotoLineHandler.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/quickopen/browser/gotoSymbolHandler.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/quickopen/browser/helpHandler.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/quickopen/browser/viewPickerHandler.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/scm/electron-browser/scmActivity.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/scm/electron-browser/scmViewlet.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/search/browser/openAnythingHandler.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/search/browser/openFileHandler.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/search/browser/openSymbolHandler.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/search/browser/patternInputWidget.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/search/browser/replaceService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/search/browser/search.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/search/browser/searchActions.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/search/browser/searchViewlet.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/search/browser/searchWidget.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/snippets/electron-browser/insertSnippet.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/snippets/electron-browser/snippetsService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/snippets/electron-browser/tabCompletion.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/tasks/common/taskTemplates.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/tasks/node/processRunnerDetector.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/trust/electron-browser/unsupportedWorkspaceSettings.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/update/electron-browser/releaseNotesInput.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/update/electron-browser/update.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/update/electron-browser/update.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/views/browser/views.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/welcome/walkThrough/electron-browser/editor/editorWalkThrough.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThrough.contribution.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughActions.i18n.json create mode 100644 i18n/hun/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json create mode 100644 i18n/hun/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/services/editor/browser/editorService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/services/files/electron-browser/fileService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/services/files/node/fileService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/services/keybinding/common/keybindingEditing.i18n.json create mode 100644 i18n/hun/src/vs/workbench/services/keybinding/electron-browser/keybindingService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/services/message/browser/messageList.i18n.json create mode 100644 i18n/hun/src/vs/workbench/services/message/electron-browser/messageService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/services/mode/common/workbenchModeService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/services/progress/browser/progressService2.i18n.json create mode 100644 i18n/hun/src/vs/workbench/services/textfile/common/textFileEditorModel.i18n.json create mode 100644 i18n/hun/src/vs/workbench/services/textfile/common/textFileService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/services/textfile/electron-browser/textFileService.i18n.json create mode 100644 i18n/hun/src/vs/workbench/services/themes/common/colorThemeSchema.i18n.json create mode 100644 i18n/hun/src/vs/workbench/services/themes/common/fileIconThemeSchema.i18n.json create mode 100644 i18n/hun/src/vs/workbench/services/themes/electron-browser/colorThemeData.i18n.json create mode 100644 i18n/hun/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json create mode 100644 i18n/ita/src/vs/base/common/keybindingLabels.i18n.json create mode 100644 i18n/ita/src/vs/platform/history/electron-main/historyMainService.i18n.json create mode 100644 i18n/ita/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json create mode 100644 i18n/ita/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json create mode 100644 i18n/ita/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json create mode 100644 i18n/ita/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json create mode 100644 i18n/ita/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json create mode 100644 i18n/ita/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json create mode 100644 i18n/ita/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json create mode 100644 i18n/ita/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json create mode 100644 i18n/ita/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json create mode 100644 i18n/ita/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json create mode 100644 i18n/ita/src/vs/workbench/parts/views/browser/views.i18n.json create mode 100644 i18n/ita/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json create mode 100644 i18n/ita/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json create mode 100644 i18n/ita/src/vs/workbench/services/progress/browser/progressService2.i18n.json create mode 100644 i18n/jpn/src/vs/base/common/keybindingLabels.i18n.json create mode 100644 i18n/jpn/src/vs/platform/history/electron-main/historyMainService.i18n.json create mode 100644 i18n/jpn/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json create mode 100644 i18n/jpn/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json create mode 100644 i18n/jpn/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json create mode 100644 i18n/jpn/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json create mode 100644 i18n/jpn/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json create mode 100644 i18n/jpn/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json create mode 100644 i18n/jpn/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json create mode 100644 i18n/jpn/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json create mode 100644 i18n/jpn/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json create mode 100644 i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json create mode 100644 i18n/jpn/src/vs/workbench/parts/views/browser/views.i18n.json create mode 100644 i18n/jpn/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json create mode 100644 i18n/jpn/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json create mode 100644 i18n/jpn/src/vs/workbench/services/progress/browser/progressService2.i18n.json create mode 100644 i18n/kor/src/vs/base/common/keybindingLabels.i18n.json create mode 100644 i18n/kor/src/vs/platform/history/electron-main/historyMainService.i18n.json create mode 100644 i18n/kor/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json create mode 100644 i18n/kor/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json create mode 100644 i18n/kor/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json create mode 100644 i18n/kor/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json create mode 100644 i18n/kor/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json create mode 100644 i18n/kor/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json create mode 100644 i18n/kor/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json create mode 100644 i18n/kor/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json create mode 100644 i18n/kor/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json create mode 100644 i18n/kor/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json create mode 100644 i18n/kor/src/vs/workbench/parts/views/browser/views.i18n.json create mode 100644 i18n/kor/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json create mode 100644 i18n/kor/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json create mode 100644 i18n/kor/src/vs/workbench/services/progress/browser/progressService2.i18n.json create mode 100644 i18n/ptb/src/vs/base/common/keybindingLabels.i18n.json create mode 100644 i18n/ptb/src/vs/platform/history/electron-main/historyMainService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/views/browser/views.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json create mode 100644 i18n/ptb/src/vs/workbench/services/progress/browser/progressService2.i18n.json create mode 100644 i18n/rus/src/vs/base/common/keybindingLabels.i18n.json create mode 100644 i18n/rus/src/vs/platform/history/electron-main/historyMainService.i18n.json create mode 100644 i18n/rus/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json create mode 100644 i18n/rus/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json create mode 100644 i18n/rus/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json create mode 100644 i18n/rus/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json create mode 100644 i18n/rus/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json create mode 100644 i18n/rus/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json create mode 100644 i18n/rus/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json create mode 100644 i18n/rus/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json create mode 100644 i18n/rus/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json create mode 100644 i18n/rus/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json create mode 100644 i18n/rus/src/vs/workbench/parts/views/browser/views.i18n.json create mode 100644 i18n/rus/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json create mode 100644 i18n/rus/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json create mode 100644 i18n/rus/src/vs/workbench/services/progress/browser/progressService2.i18n.json create mode 100644 i18n/trk/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json create mode 100644 i18n/trk/extensions/css/client/out/cssMain.i18n.json create mode 100644 i18n/trk/extensions/css/package.i18n.json create mode 100644 i18n/trk/extensions/extension-editing/out/packageDocumentHelper.i18n.json create mode 100644 i18n/trk/extensions/git/out/askpass-main.i18n.json create mode 100644 i18n/trk/extensions/git/out/commands.i18n.json create mode 100644 i18n/trk/extensions/git/out/main.i18n.json create mode 100644 i18n/trk/extensions/git/out/model.i18n.json create mode 100644 i18n/trk/extensions/git/out/scmProvider.i18n.json create mode 100644 i18n/trk/extensions/git/out/statusbar.i18n.json create mode 100644 i18n/trk/extensions/git/package.i18n.json create mode 100644 i18n/trk/extensions/grunt/out/main.i18n.json create mode 100644 i18n/trk/extensions/grunt/package.i18n.json create mode 100644 i18n/trk/extensions/gulp/out/main.i18n.json create mode 100644 i18n/trk/extensions/gulp/package.i18n.json create mode 100644 i18n/trk/extensions/html/client/out/htmlMain.i18n.json create mode 100644 i18n/trk/extensions/html/package.i18n.json create mode 100644 i18n/trk/extensions/jake/out/main.i18n.json create mode 100644 i18n/trk/extensions/jake/package.i18n.json create mode 100644 i18n/trk/extensions/javascript/out/features/bowerJSONContribution.i18n.json create mode 100644 i18n/trk/extensions/javascript/out/features/packageJSONContribution.i18n.json create mode 100644 i18n/trk/extensions/json/client/out/jsonMain.i18n.json create mode 100644 i18n/trk/extensions/json/package.i18n.json create mode 100644 i18n/trk/extensions/markdown/out/extension.i18n.json create mode 100644 i18n/trk/extensions/markdown/out/previewContentProvider.i18n.json create mode 100644 i18n/trk/extensions/markdown/out/security.i18n.json create mode 100644 i18n/trk/extensions/markdown/package.i18n.json create mode 100644 i18n/trk/extensions/merge-conflict/out/codelensProvider.i18n.json create mode 100644 i18n/trk/extensions/merge-conflict/out/commandHandler.i18n.json create mode 100644 i18n/trk/extensions/merge-conflict/out/mergeDecorator.i18n.json create mode 100644 i18n/trk/extensions/merge-conflict/package.i18n.json create mode 100644 i18n/trk/extensions/npm/package.i18n.json create mode 100644 i18n/trk/extensions/php/out/features/validationProvider.i18n.json create mode 100644 i18n/trk/extensions/php/package.i18n.json create mode 100644 i18n/trk/extensions/typescript/out/features/bufferSyncSupport.i18n.json create mode 100644 i18n/trk/extensions/typescript/out/features/completionItemProvider.i18n.json create mode 100644 i18n/trk/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json create mode 100644 i18n/trk/extensions/typescript/out/features/implementationsCodeLensProvider.i18n.json create mode 100644 i18n/trk/extensions/typescript/out/features/jsDocCompletionProvider.i18n.json create mode 100644 i18n/trk/extensions/typescript/out/features/referencesCodeLensProvider.i18n.json create mode 100644 i18n/trk/extensions/typescript/out/typescriptMain.i18n.json create mode 100644 i18n/trk/extensions/typescript/out/typescriptServiceClient.i18n.json create mode 100644 i18n/trk/extensions/typescript/out/utils/logger.i18n.json create mode 100644 i18n/trk/extensions/typescript/out/utils/projectStatus.i18n.json create mode 100644 i18n/trk/extensions/typescript/out/utils/typingsStatus.i18n.json create mode 100644 i18n/trk/extensions/typescript/package.i18n.json create mode 100644 i18n/trk/src/vs/base/browser/ui/actionbar/actionbar.i18n.json create mode 100644 i18n/trk/src/vs/base/browser/ui/aria/aria.i18n.json create mode 100644 i18n/trk/src/vs/base/browser/ui/findinput/findInput.i18n.json create mode 100644 i18n/trk/src/vs/base/browser/ui/findinput/findInputCheckboxes.i18n.json create mode 100644 i18n/trk/src/vs/base/browser/ui/inputbox/inputBox.i18n.json create mode 100644 i18n/trk/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json create mode 100644 i18n/trk/src/vs/base/browser/ui/toolbar/toolbar.i18n.json create mode 100644 i18n/trk/src/vs/base/common/errorMessage.i18n.json create mode 100644 i18n/trk/src/vs/base/common/jsonErrorMessages.i18n.json create mode 100644 i18n/trk/src/vs/base/common/keybindingLabels.i18n.json create mode 100644 i18n/trk/src/vs/base/common/processes.i18n.json create mode 100644 i18n/trk/src/vs/base/common/severity.i18n.json create mode 100644 i18n/trk/src/vs/base/node/processes.i18n.json create mode 100644 i18n/trk/src/vs/base/node/zip.i18n.json create mode 100644 i18n/trk/src/vs/base/parts/quickopen/browser/quickOpenModel.i18n.json create mode 100644 i18n/trk/src/vs/base/parts/quickopen/browser/quickOpenWidget.i18n.json create mode 100644 i18n/trk/src/vs/base/parts/tree/browser/treeDefaults.i18n.json create mode 100644 i18n/trk/src/vs/code/electron-main/menus.i18n.json create mode 100644 i18n/trk/src/vs/code/electron-main/window.i18n.json create mode 100644 i18n/trk/src/vs/code/electron-main/windows.i18n.json create mode 100644 i18n/trk/src/vs/code/node/cliProcessMain.i18n.json create mode 100644 i18n/trk/src/vs/editor/common/config/commonEditorConfig.i18n.json create mode 100644 i18n/trk/src/vs/editor/common/config/editorOptions.i18n.json create mode 100644 i18n/trk/src/vs/editor/common/controller/cursor.i18n.json create mode 100644 i18n/trk/src/vs/editor/common/model/textModelWithTokens.i18n.json create mode 100644 i18n/trk/src/vs/editor/common/modes/modesRegistry.i18n.json create mode 100644 i18n/trk/src/vs/editor/common/services/bulkEdit.i18n.json create mode 100644 i18n/trk/src/vs/editor/common/services/modeServiceImpl.i18n.json create mode 100644 i18n/trk/src/vs/editor/common/services/modelServiceImpl.i18n.json create mode 100644 i18n/trk/src/vs/editor/common/view/editorColorRegistry.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/bracketMatching/common/bracketMatching.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/caretOperations/common/caretOperations.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/caretOperations/common/transpose.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/clipboard/browser/clipboard.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/comment/common/comment.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/contextmenu/browser/contextmenu.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/find/browser/findWidget.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/find/common/findController.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/folding/browser/folding.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/format/browser/formatActions.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/hover/browser/hover.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/hover/browser/modesContentHover.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/indentation/common/indentation.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/linesOperations/common/linesOperations.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/links/browser/links.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/multicursor/common/multicursor.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/parameterHints/browser/parameterHints.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/quickFix/browser/quickFixCommands.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/referenceSearch/browser/referencesController.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/rename/browser/rename.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/rename/browser/renameInputField.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/smartSelect/common/smartSelect.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/suggest/browser/suggestController.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.i18n.json create mode 100644 i18n/trk/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.i18n.json create mode 100644 i18n/trk/src/vs/editor/electron-browser/textMate/TMSyntax.i18n.json create mode 100644 i18n/trk/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json create mode 100644 i18n/trk/src/vs/editor/node/textMate/TMGrammars.i18n.json create mode 100644 i18n/trk/src/vs/platform/actions/browser/menuItemActionItem.i18n.json create mode 100644 i18n/trk/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json create mode 100644 i18n/trk/src/vs/platform/configuration/common/configurationRegistry.i18n.json create mode 100644 i18n/trk/src/vs/platform/environment/node/argv.i18n.json create mode 100644 i18n/trk/src/vs/platform/extensionManagement/common/extensionEnablementService.i18n.json create mode 100644 i18n/trk/src/vs/platform/extensionManagement/common/extensionManagement.i18n.json create mode 100644 i18n/trk/src/vs/platform/extensionManagement/node/extensionGalleryService.i18n.json create mode 100644 i18n/trk/src/vs/platform/extensionManagement/node/extensionManagementService.i18n.json create mode 100644 i18n/trk/src/vs/platform/extensions/common/abstractExtensionService.i18n.json create mode 100644 i18n/trk/src/vs/platform/extensions/common/extensionsRegistry.i18n.json create mode 100644 i18n/trk/src/vs/platform/extensions/node/extensionValidator.i18n.json create mode 100644 i18n/trk/src/vs/platform/history/electron-main/historyMainService.i18n.json create mode 100644 i18n/trk/src/vs/platform/integrity/node/integrityServiceImpl.i18n.json create mode 100644 i18n/trk/src/vs/platform/jsonschemas/common/jsonValidationExtensionPoint.i18n.json create mode 100644 i18n/trk/src/vs/platform/keybinding/common/abstractKeybindingService.i18n.json create mode 100644 i18n/trk/src/vs/platform/markers/common/problemMatcher.i18n.json create mode 100644 i18n/trk/src/vs/platform/message/common/message.i18n.json create mode 100644 i18n/trk/src/vs/platform/request/node/request.i18n.json create mode 100644 i18n/trk/src/vs/platform/telemetry/common/telemetryService.i18n.json create mode 100644 i18n/trk/src/vs/platform/theme/common/colorRegistry.i18n.json create mode 100644 i18n/trk/src/vs/workbench/api/electron-browser/mainThreadExtensionService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/api/electron-browser/mainThreadMessageService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/api/node/extHostDiagnostics.i18n.json create mode 100644 i18n/trk/src/vs/workbench/api/node/extHostTask.i18n.json create mode 100644 i18n/trk/src/vs/workbench/api/node/extHostTreeViews.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/actions/configureLocale.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/actions/fileActions.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/actions/toggleActivityBarVisibility.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/actions/toggleEditorLayout.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/actions/toggleSidebarPosition.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/actions/toggleSidebarVisibility.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/actions/toggleStatusbarVisibility.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/actions/toggleZenMode.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/activitybar/activitybarActions.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/compositePart.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/editor/binaryDiffEditor.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/editor/binaryEditor.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/editor/editor.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/editor/editorActions.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/editor/editorCommands.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/editor/editorPart.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/editor/editorPicker.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/editor/tabsTitleControl.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/editor/textDiffEditor.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/editor/textEditor.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/editor/textResourceEditor.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/editor/titleControl.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/panel/panelActions.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/panel/panelPart.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/quickopen/quickOpenController.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/sidebar/sidebarPart.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/statusbar/statusbarPart.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/parts/titlebar/titlebarPart.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/quickopen.i18n.json create mode 100644 i18n/trk/src/vs/workbench/browser/viewlet.i18n.json create mode 100644 i18n/trk/src/vs/workbench/common/theme.i18n.json create mode 100644 i18n/trk/src/vs/workbench/electron-browser/actions.i18n.json create mode 100644 i18n/trk/src/vs/workbench/electron-browser/commands.i18n.json create mode 100644 i18n/trk/src/vs/workbench/electron-browser/extensionHost.i18n.json create mode 100644 i18n/trk/src/vs/workbench/electron-browser/main.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/electron-browser/main.i18n.json create mode 100644 i18n/trk/src/vs/workbench/electron-browser/shell.i18n.json create mode 100644 i18n/trk/src/vs/workbench/electron-browser/window.i18n.json create mode 100644 i18n/trk/src/vs/workbench/electron-browser/workbench.i18n.json create mode 100644 i18n/trk/src/vs/workbench/node/extensionHostMain.i18n.json create mode 100644 i18n/trk/src/vs/workbench/node/extensionPoints.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/cli/electron-browser/cli.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderControlCharacter.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderWhitespace.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/wordWrapMigration.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/browser/breakpointWidget.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/browser/debugActionItems.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/browser/debugActions.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/browser/debugActionsWidget.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/browser/debugContentProvider.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/browser/debugEditorActions.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/browser/debugEditorModelManager.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/browser/debugQuickOpen.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/browser/exceptionWidget.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/browser/linkDetector.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/common/debug.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/common/debugModel.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/common/debugSource.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/electron-browser/debug.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugConfigurationManager.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugHover.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugViewer.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/electron-browser/repl.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/electron-browser/replViewer.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/electron-browser/terminalSupport.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/emmet/browser/actions/showEmmetCommands.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/balance.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/matchingPair.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/mergeLines.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/reflectCssValue.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/selectItem.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/toggleComment.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/execution/electron-browser/terminal.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/execution/electron-browser/terminalService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/explorers/browser/treeExplorerActions.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/explorers/browser/treeExplorerService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/explorers/browser/views/treeExplorerView.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/extensions/browser/dependenciesViewer.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/extensions/browser/extensionsQuickOpen.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/extensions/common/extensionsFileTemplate.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/extensions/common/extensionsInput.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/extensions/electron-browser/extensionsActions.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/feedback/electron-browser/feedback.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/files/browser/editors/binaryFileEditor.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/files/browser/editors/textFileEditor.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/files/browser/fileActions.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/files/browser/fileActions.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/files/browser/fileCommands.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/files/browser/files.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/files/browser/saveErrorHandler.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/files/browser/views/explorerView.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/files/browser/views/explorerViewer.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/files/browser/views/openEditorsViewer.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/files/common/dirtyFilesTracker.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/html/browser/html.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/html/browser/htmlPreviewPart.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/html/browser/webview.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/markers/common/messages.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/markers/electron-browser/markersElectronContributions.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/nps/electron-browser/nps.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/output/browser/output.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/output/browser/outputActions.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/output/browser/outputPanel.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/output/common/output.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/preferences/browser/keybindingWidgets.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/preferences/browser/preferences.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/preferences/browser/preferencesEditor.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/preferences/browser/preferencesService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/preferences/browser/preferencesWidgets.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/preferences/common/preferencesModels.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/quickopen/browser/gotoLineHandler.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/quickopen/browser/gotoSymbolHandler.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/quickopen/browser/helpHandler.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/quickopen/browser/viewPickerHandler.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/scm/electron-browser/scmActivity.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/scm/electron-browser/scmViewlet.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/search/browser/openAnythingHandler.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/search/browser/openFileHandler.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/search/browser/openSymbolHandler.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/search/browser/patternInputWidget.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/search/browser/replaceService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/search/browser/search.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/search/browser/searchActions.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/search/browser/searchViewlet.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/search/browser/searchWidget.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/snippets/electron-browser/insertSnippet.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/snippets/electron-browser/snippetsService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/snippets/electron-browser/tabCompletion.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/tasks/common/taskTemplates.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/tasks/node/processRunnerDetector.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/trust/electron-browser/unsupportedWorkspaceSettings.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/update/electron-browser/releaseNotesInput.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/update/electron-browser/update.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/update/electron-browser/update.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/views/browser/views.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/welcome/walkThrough/electron-browser/editor/editorWalkThrough.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThrough.contribution.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughActions.i18n.json create mode 100644 i18n/trk/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json create mode 100644 i18n/trk/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/services/editor/browser/editorService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/services/files/electron-browser/fileService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/services/files/node/fileService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/services/keybinding/common/keybindingEditing.i18n.json create mode 100644 i18n/trk/src/vs/workbench/services/keybinding/electron-browser/keybindingService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/services/message/browser/messageList.i18n.json create mode 100644 i18n/trk/src/vs/workbench/services/message/electron-browser/messageService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/services/mode/common/workbenchModeService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/services/progress/browser/progressService2.i18n.json create mode 100644 i18n/trk/src/vs/workbench/services/textfile/common/textFileEditorModel.i18n.json create mode 100644 i18n/trk/src/vs/workbench/services/textfile/common/textFileService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/services/textfile/electron-browser/textFileService.i18n.json create mode 100644 i18n/trk/src/vs/workbench/services/themes/common/colorThemeSchema.i18n.json create mode 100644 i18n/trk/src/vs/workbench/services/themes/common/fileIconThemeSchema.i18n.json create mode 100644 i18n/trk/src/vs/workbench/services/themes/electron-browser/colorThemeData.i18n.json create mode 100644 i18n/trk/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json diff --git a/build/win32/i18n/messages.hu.isl b/build/win32/i18n/messages.hu.isl new file mode 100644 index 00000000000..120bf8fc27b --- /dev/null +++ b/build/win32/i18n/messages.hu.isl @@ -0,0 +1,8 @@ +[CustomMessages] +AddContextMenuFiles="Megnyitás a következõvel: %1" parancs hozzáadása a fájlok helyi menüjéhez a Windows Intézõben +AddContextMenuFolders="Megnyitás a következõvel: %1" parancs hozzáadása a mappák helyi menüjéhez a Windows Intézõben +AssociateWithFiles=%1 regisztrálása szerkesztõként a támogatott fájltípusokhoz +AddToPath=Hozzáadás a PATH-hoz (újraindítás után lesz elérhetõ) +RunAfter=%1 indítása a telepítés után +Other=Egyéb: +SourceFile=%1 forrásfájl \ No newline at end of file diff --git a/build/win32/i18n/messages.tr.isl b/build/win32/i18n/messages.tr.isl new file mode 100644 index 00000000000..4e8e7bbd19b --- /dev/null +++ b/build/win32/i18n/messages.tr.isl @@ -0,0 +1,8 @@ +[CustomMessages] +AddContextMenuFiles=Windows Gezgini baðlam menüsüne "%1 Ýle Aç" eylemini ekle +AddContextMenuFolders=Windows Gezgini dizin baðlam menüsüne "%1 Ýle Aç" eylemini ekle +AssociateWithFiles=%1 uygulamasýný desteklenen dosya türleri için bir düzenleyici olarak kayýt et +AddToPath=PATH'e ekle (yeniden baþlattýktan sonra kullanýlabilir) +RunAfter=Kurulumdan sonra %1 uygulamasýný çalýþtýr. +Other=Diðer: +SourceFile=%1 Kaynak Dosyasý \ No newline at end of file diff --git a/i18n/chs/extensions/git/package.i18n.json b/i18n/chs/extensions/git/package.i18n.json index 9c65f275fd6..996b8a4173c 100644 --- a/i18n/chs/extensions/git/package.i18n.json +++ b/i18n/chs/extensions/git/package.i18n.json @@ -32,7 +32,7 @@ "command.push": "推é€", "command.pushTo": "推é€åˆ°...", "command.sync": "åŒæ­¥", - "command.publish": "å‘布", + "command.publish": "å‘布分支", "command.showOutput": "显示 GIT 输出", "config.enabled": "是å¦å·²å¯ç”¨ GIT", "config.path": "Git å¯æ‰§è¡Œæ–‡ä»¶è·¯å¾„", diff --git a/i18n/chs/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/chs/extensions/merge-conflict/out/codelensProvider.i18n.json index 8b6ad71cd4e..91a343efd7d 100644 --- a/i18n/chs/extensions/merge-conflict/out/codelensProvider.i18n.json +++ b/i18n/chs/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -3,4 +3,9 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "acceptCurrentChange": "采用当å‰æ›´æ”¹", + "acceptIncomingChange": "采用传入的更改", + "acceptBothChanges": "ä¿ç•™åŒæ–¹æ›´æ”¹", + "compareChanges": "比较å˜æ›´" +} \ No newline at end of file diff --git a/i18n/chs/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/chs/extensions/merge-conflict/out/commandHandler.i18n.json index b6f2dae32e9..836475b99dc 100644 --- a/i18n/chs/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/chs/extensions/merge-conflict/out/commandHandler.i18n.json @@ -5,6 +5,8 @@ // Do not edit this file. It is machine generated. { "cursorNotInConflict": "编辑器光标ä¸åœ¨åˆå¹¶å†²çªå†…", + "compareChangesTitle": "{0}:当å‰æ›´æ”¹ ⟷ 传入的更改", + "cursorOnCommonAncestorsRange": "编辑器光标在共åŒæ¥æºå—上,请将其移动至“当å‰â€æˆ–“传入â€åŒºåŸŸä¸­", "cursorOnSplitterRange": "编辑器光标在åˆå¹¶å†²çªåˆ†å‰²çº¿ä¸Šï¼Œè¯·å°†å…¶ç§»åŠ¨è‡³â€œå½“å‰â€æˆ–“传入â€åŒºåŸŸä¸­", "noConflicts": "没有在此文件中找到åˆå¹¶å†²çª", "noOtherConflictsInThisFile": "此文件中没有其他åˆå¹¶å†²çªäº†" diff --git a/i18n/chs/extensions/merge-conflict/package.i18n.json b/i18n/chs/extensions/merge-conflict/package.i18n.json index 7ed47cfef74..ae0c9b41704 100644 --- a/i18n/chs/extensions/merge-conflict/package.i18n.json +++ b/i18n/chs/extensions/merge-conflict/package.i18n.json @@ -5,7 +5,15 @@ // Do not edit this file. It is machine generated. { "command.category": "åˆå¹¶å†²çª", + "command.accept.all-incoming": "全部采用传入版本", + "command.accept.all-both": "全部ä¿ç•™ä¸¤è€…", + "command.accept.current": "采用当å‰å†…容", + "command.accept.incoming": "采用传入内容", + "command.accept.selection": "采用选中版本", "command.accept.both": "ä¿ç•™ä¸¤è€…", + "command.next": "下一个冲çª", + "command.previous": "上一个冲çª", + "command.compare": "比较当å‰å†²çª", "config.title": "åˆå¹¶å†²çª", "config.codeLensEnabled": "å¯ç”¨/ç¦ç”¨ç¼–辑器内åˆå¹¶å†²çªåŒºåŸŸçš„ CodeLens", "config.decoratorsEnabled": "å¯ç”¨/ç¦ç”¨ç¼–辑器内的åˆå¹¶å†²çªä¿®é¥°å™¨" diff --git a/i18n/chs/extensions/typescript/out/features/bufferSyncSupport.i18n.json b/i18n/chs/extensions/typescript/out/features/bufferSyncSupport.i18n.json index 9dcaf692d8f..2b32badbce5 100644 --- a/i18n/chs/extensions/typescript/out/features/bufferSyncSupport.i18n.json +++ b/i18n/chs/extensions/typescript/out/features/bufferSyncSupport.i18n.json @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "versionMismatch": "版本ä¸åŒ¹é…! 全局 tsc ({0}) != VS Code 的语言æœåŠ¡({1})。å¯èƒ½å‡ºçŽ°ä¸ä¸€è‡´çš„编译错误", + "versionMismatch": "正在使用 TypeScript ({1}) 实现的编辑器功能。TypeScript ({0}) å·²ç»å…¨å±€å®‰è£…在你的电脑上。VS Code 中å‘生的错误å¯èƒ½ä¼šä¸Ž TCS 中ä¸åŒ", "moreInformation": "详细信æ¯", "doNotCheckAgain": "ä¸å†æ£€æŸ¥", "close": "关闭", diff --git a/i18n/chs/extensions/typescript/out/utils/projectStatus.i18n.json b/i18n/chs/extensions/typescript/out/utils/projectStatus.i18n.json index 801a0e687c6..cd5d5f3a2ff 100644 --- a/i18n/chs/extensions/typescript/out/utils/projectStatus.i18n.json +++ b/i18n/chs/extensions/typescript/out/utils/projectStatus.i18n.json @@ -6,7 +6,6 @@ { "hintExclude": "è‹¥è¦å¯ç”¨é¡¹ç›®èŒƒå›´å†…çš„ JavaScript/TypeScript 语言功能,请排除包å«å¤šä¸ªæ–‡ä»¶çš„文件夹,例如: {0}", "hintExclude.generic": "è‹¥è¦å¯ç”¨é¡¹ç›®èŒƒå›´å†…çš„ JavaScript/TypeScript 语言功能,请排除包å«ä¸éœ€è¦å¤„ç†çš„æºæ–‡ä»¶çš„大型文件夹。", - "open": "é…置排除", "large.label": "é…置排除", "hintExclude.tooltip": "è‹¥è¦å¯ç”¨é¡¹ç›®èŒƒå›´å†…çš„ JavaScript/TypeScript 语言功能,请排除包å«ä¸éœ€è¦å¤„ç†çš„æºæ–‡ä»¶çš„大型文件夹。" } \ No newline at end of file diff --git a/i18n/chs/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/chs/extensions/typescript/out/utils/typingsStatus.i18n.json index f6ee369cc40..276914045d0 100644 --- a/i18n/chs/extensions/typescript/out/utils/typingsStatus.i18n.json +++ b/i18n/chs/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "installingPackages": "æå–æ•°æ®ä»¥å®žçŽ°æ›´å¥½çš„ TypeScript IntelliSense", + "typesInstallerInitializationFailed.title": "无法为 JavaScript 语言功能安装 typings 文件。请确认 NPM å·²ç»å®‰è£…或者在你的用户设置中é…置“typescript.npmâ€", "typesInstallerInitializationFailed.moreInformation": "详细信æ¯", "typesInstallerInitializationFailed.doNotCheckAgain": "ä¸è¦å†æ¬¡æ£€æŸ¥", "typesInstallerInitializationFailed.close": "关闭" diff --git a/i18n/chs/extensions/typescript/package.i18n.json b/i18n/chs/extensions/typescript/package.i18n.json index e5267352ece..8f30f33deda 100644 --- a/i18n/chs/extensions/typescript/package.i18n.json +++ b/i18n/chs/extensions/typescript/package.i18n.json @@ -13,11 +13,11 @@ "typescript.check.tscVersion": "检查全局安装的 TypeScript 编译器(例如 tsc )是å¦ä¸åŒäºŽä½¿ç”¨çš„ TypeScript 语言æœåŠ¡ã€‚", "typescript.tsserver.log": "å°† TS æœåŠ¡å™¨çš„日志ä¿å­˜åˆ°ä¸€ä¸ªæ–‡ä»¶ã€‚此日志å¯ç”¨äºŽè¯Šæ–­ TS æœåŠ¡å™¨é—®é¢˜ã€‚日志å¯èƒ½åŒ…å«ä½ çš„项目中的文件路径ã€æºä»£ç å’Œå…¶ä»–å¯èƒ½æ•æ„Ÿçš„ä¿¡æ¯ã€‚", "typescript.tsserver.trace": "对å‘é€åˆ° TS æœåŠ¡å™¨çš„消æ¯å¯ç”¨è·Ÿè¸ªã€‚此跟踪信æ¯å¯ç”¨äºŽè¯Šæ–­ TS æœåŠ¡å™¨é—®é¢˜ã€‚ 跟踪信æ¯å¯èƒ½åŒ…å«ä½ çš„项目中的文件路径ã€æºä»£ç å’Œå…¶ä»–å¯èƒ½æ•æ„Ÿçš„ä¿¡æ¯ã€‚", - "typescript.tsserver.experimentalAutoBuild": "å¯ç”¨å®žéªŒæ€§è‡ªåŠ¨ç”Ÿæˆã€‚è¦æ±‚安装 1.9 dev 或 2.x tsserver 版本并在更改åŽé‡å¯ VS Code。", "typescript.validate.enable": "å¯ç”¨/ç¦ç”¨ TypeScript 验è¯ã€‚", "typescript.format.enable": "å¯ç”¨/ç¦ç”¨é»˜è®¤ TypeScript æ ¼å¼åŒ–程åºã€‚", "javascript.format.enable": "å¯ç”¨/ç¦ç”¨ JavaScript æ ¼å¼åŒ–程åºã€‚", "format.insertSpaceAfterCommaDelimiter": "定义逗å·åˆ†éš”符åŽé¢çš„空格处ç†ã€‚", + "format.insertSpaceAfterConstructor": "定义构造器关键字åŽçš„空格处ç†ã€‚è¦æ±‚ TypeScript >= 2.3.0。", "format.insertSpaceAfterSemicolonInForStatements": "在 For 语å¥ä¸­ï¼Œå®šä¹‰åˆ†å·åŽé¢çš„空格处ç†ã€‚", "format.insertSpaceBeforeAndAfterBinaryOperators": "定义二进制è¿ç®—符åŽé¢çš„空格处ç†", "format.insertSpaceAfterKeywordsInControlFlowStatements": "定义控制æµè¯­å¥ä¸­å…³é”®å­—åŽé¢çš„空格处ç†ã€‚", @@ -41,6 +41,8 @@ "typescript.selectTypeScriptVersion.title": "选择 TypeScript 版本", "jsDocCompletion.enabled": "å¯ç”¨/ç¦ç”¨è‡ªåŠ¨ JSDoc 注释", "javascript.implicitProjectConfig.checkJs": "å¯ç”¨/ç¦ç”¨ JavaScript 文件的语义检查。现有的 jsconfig.json 或\n tsconfig.json 文件会覆盖此设置。è¦æ±‚ TypeScript >=2.3.1。", + "typescript.npm": "指定用于自动获å–类型的 NPM å¯æ‰§è¡Œæ–‡ä»¶çš„路径。è¦æ±‚ TypeScript >= 2.3.4。", + "typescript.check.npmIsInstalled": "检查是å¦å®‰è£…了 NPM 以自动获å–类型。", "javascript.nameSuggestions": "å¯ç”¨/ç¦ç”¨åœ¨ JavaScript 建议列表中包å«æ–‡ä»¶ä¸­çš„唯一å称。", "typescript.tsc.autoDetect": "控制自动检测 tsc 任务是å¦æ‰“开。" } \ No newline at end of file diff --git a/i18n/chs/src/vs/base/common/errorMessage.i18n.json b/i18n/chs/src/vs/base/common/errorMessage.i18n.json index 8dd95907e51..8e1a689b214 100644 --- a/i18n/chs/src/vs/base/common/errorMessage.i18n.json +++ b/i18n/chs/src/vs/base/common/errorMessage.i18n.json @@ -13,6 +13,5 @@ "error.connection.unknown": "出现未知连接错误。您的 Internet 连接已断开,或者您连接的æœåŠ¡å™¨å·²è„±æœºã€‚", "stackTrace.format": "{0}: {1}", "error.defaultMessage": "出现未知错误。有关详细信æ¯ï¼Œè¯·å‚阅日志。", - "nodeExceptionMessage": "å‘生了系统错误({0})", "error.moreErrors": "{0} 个(å…± {1} 个错误)" } \ No newline at end of file diff --git a/i18n/chs/src/vs/base/common/keybindingLabels.i18n.json b/i18n/chs/src/vs/base/common/keybindingLabels.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/chs/src/vs/base/common/keybindingLabels.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/chs/src/vs/code/electron-main/menus.i18n.json b/i18n/chs/src/vs/code/electron-main/menus.i18n.json index 10d2dd072d7..8e60bd1b82a 100644 --- a/i18n/chs/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/chs/src/vs/code/electron-main/menus.i18n.json @@ -12,6 +12,7 @@ "mDebug": "调试(&&D)", "mWindow": "窗å£", "mHelp": "帮助(&&H)", + "mTask": "任务(&&T)", "miNewWindow": "新建窗å£(&&W)", "mAbout": "关于 {0}", "mServices": "æœåŠ¡", @@ -41,6 +42,7 @@ "miSelectIconTheme": "文件图标主题(&&I)", "miPreferences": "首选项(&&P)", "miReopenClosedEditor": "é‡æ–°æ‰“开已关闭的编辑器(&&R)", + "miMore": "更多(&&M)...", "miClearRecentOpen": "清除最近使用的文件(&&C)", "miUndo": "撤消(&&U)", "miRedo": "æ¢å¤(&&R)", @@ -55,6 +57,9 @@ "miShowEmmetCommands": "Emmet(&&M)...", "miToggleLineComment": "切æ¢è¡Œæ³¨é‡Š(&&T)", "miToggleBlockComment": "切æ¢å—注释(&&B)", + "miMultiCursorAlt": "使用Alt+å•å‡»è¿›è¡Œå¤šå…‰æ ‡åŠŸèƒ½", + "miMultiCursorCmd": "使用Cmd+å•å‡»è¿›è¡Œå¤šå…‰æ ‡åŠŸèƒ½", + "miMultiCursorCtrl": "使用Ctrl+å•å‡»è¿›è¡Œå¤šå…‰æ ‡åŠŸèƒ½", "miInsertCursorAbove": "在上é¢æ·»åŠ å…‰æ ‡(&&A)", "miInsertCursorBelow": "在下é¢æ·»åŠ å…‰æ ‡(&&D)", "miInsertCursorAtEndOfEachLineSelected": "在行尾添加光标(&&U)", @@ -102,7 +107,7 @@ "miForward": "å‰è¿›(&&F)", "miNextEditor": "下一个编辑器(&&N)", "miPreviousEditor": "上一个编辑器(&&P)", - "miNextEditorInGroup": "组中上一个使用过的编辑器(&&P)", + "miNextEditorInGroup": "组中下一个使用过的编辑器(&&N)", "miPreviousEditorInGroup": "组中上一个使用过的编辑器(&&P)", "miSwitchEditor": "切æ¢ç¼–辑器(&&E)", "miFocusFirstGroup": "第一组(&&F)", @@ -133,12 +138,14 @@ "miColumnBreakpoint": "列断点(&&O)", "miFunctionBreakpoint": "函数断点(&&F)...", "miNewBreakpoint": "新建断点(&&N)", + "miEnableAllBreakpoints": "å¯ç”¨æ‰€æœ‰æ–­ç‚¹", "miDisableAllBreakpoints": "ç¦ç”¨æ‰€æœ‰æ–­ç‚¹(&&L)", "miRemoveAllBreakpoints": "删除所有断点(&&R)", "miInstallAdditionalDebuggers": "安装其他调试器(&&I)...", "mMinimize": "最å°åŒ–", - "mClose": "关闭", + "mZoom": "缩放", "mBringToFront": "全部置于顶层", + "miSwitchWindow": "切æ¢çª—å£(&&W)...", "miToggleDevTools": "切æ¢å¼€å‘人员工具(&&T)", "miAccessibilityOptions": "辅助功能选项(&&O)", "miReportIssues": "报告问题(&&I)", @@ -153,12 +160,19 @@ "miLicense": "查看许å¯è¯(&&L)", "miPrivacyStatement": "éšç§å£°æ˜Ž(&&P)", "miAbout": "关于(&&A)", + "miRunTask": "è¿è¡Œä»»åŠ¡(&&R)...", + "miRestartTask": "é‡å¯ä»»åŠ¡(&&E)", + "miTerminateTask": "终止任务(&&T)", + "miBuildTask": "生æˆä»»åŠ¡(&&B)", + "miTestTask": "测试任务(&&A)", + "miShowTaskLog": "显示任务日志(&&S)", "accessibilityOptionsWindowTitle": "辅助功能选项", "miRestartToUpdate": "é‡å¯ä»¥æ›´æ–°...", "miCheckingForUpdates": "正在检查更新...", "miDownloadUpdate": "下载å¯ç”¨æ›´æ–°", "miDownloadingUpdate": "正在下载更新...", "miInstallingUpdate": "正在安装更新...", + "miCheckForUpdates": "检查更新...", "aboutDetail": "\n版本 {0}\næ交 {1}\n日期 {2}\nShell {3}\n渲染器 {4}\nNode {5}", "okButton": "确定" } \ No newline at end of file diff --git a/i18n/chs/src/vs/code/electron-main/windows.i18n.json b/i18n/chs/src/vs/code/electron-main/windows.i18n.json index 55246096dd2..c07ddb7e29d 100644 --- a/i18n/chs/src/vs/code/electron-main/windows.i18n.json +++ b/i18n/chs/src/vs/code/electron-main/windows.i18n.json @@ -13,9 +13,5 @@ "appStalled": "窗å£ä¸å†å“应", "appStalledDetail": "å¯ä»¥é‡æ–°æ‰“开或关闭窗,或者ä¿æŒç­‰å¾…。", "appCrashed": "窗å£å‡ºçŽ°æ•…éšœ", - "appCrashedDetail": "我们对此引起的ä¸ä¾¿è¡¨ç¤ºæŠ±æ­‰! 请é‡å¯è¯¥çª—å£ä»Žä¸Šæ¬¡åœæ­¢çš„ä½ç½®ç»§ç»­ã€‚", - "newWindow": "新建窗å£", - "newWindowDesc": "打开一个新窗å£", - "recentFolders": "最近的文件夹", - "folderDesc": "{0} {1}" + "appCrashedDetail": "我们对此引起的ä¸ä¾¿è¡¨ç¤ºæŠ±æ­‰! 请é‡å¯è¯¥çª—å£ä»Žä¸Šæ¬¡åœæ­¢çš„ä½ç½®ç»§ç»­ã€‚" } \ No newline at end of file diff --git a/i18n/chs/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/chs/src/vs/editor/common/config/commonEditorConfig.i18n.json index 9943fbbaa8a..ec542efe0a0 100644 --- a/i18n/chs/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/chs/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -33,12 +33,15 @@ "wordWrapColumn": "在 \"editor.wordWrap\" 为 \"wordWrapColumn\" 或 \"bounded\" 时控制编辑器列的æ¢è¡Œã€‚", "wrappingIndent": "控制折行的缩进。å¯ä»¥æ˜¯â€œnoneâ€ã€â€œsameâ€æˆ–“indentâ€ã€‚", "mouseWheelScrollSensitivity": "è¦å¯¹é¼ æ ‡æ»šè½®æ»šåŠ¨äº‹ä»¶çš„ \"deltaX\" å’Œ \"deltaY\" 使用的乘数 ", + "multiCursorModifier.ctrlCmd": "映射到“Controlâ€ï¼ˆWindows å’Œ Linux)或“Commandâ€ï¼ˆOSX)。", + "multiCursorModifier.alt": "映射到“Altâ€ï¼ˆWindows å’Œ Linux)或“Optionâ€ï¼ˆOSX)。", + "multiCursorModifier": "用鼠标添加多个光标时使用的修改键。“ctrlCmdâ€æ˜ å°„为“Controlâ€ï¼ˆWindows å’Œ Linux)或“Commandâ€ï¼ˆOSX)。“转到定义â€å’Œâ€œæ‰“开链接â€åŠŸèƒ½çš„鼠标手势将会相应调整,ä¸ä¸Žå¤šå…‰æ ‡ä¿®æ”¹é”®å†²çªã€‚", "quickSuggestions.strings": "在字符串内å¯ç”¨å¿«é€Ÿå»ºè®®ã€‚", "quickSuggestions.comments": "在注释内å¯ç”¨å¿«é€Ÿå»ºè®®ã€‚", "quickSuggestions.other": "在字符串和注释外å¯ç”¨å¿«é€Ÿå»ºè®®ã€‚", "quickSuggestions": "控制键入时是å¦åº”自动显示建议", "quickSuggestionsDelay": "控制延迟多少毫秒åŽå°†æ˜¾ç¤ºå¿«é€Ÿå»ºè®®", - "parameterHints": "å¯ç”¨å‚æ•°æ示", + "parameterHints": "å¯ç”¨åœ¨è¾“入时显示å«æœ‰å‚数文档和类型信æ¯çš„å°é¢æ¿", "autoClosingBrackets": "控制编辑器是å¦åº”该在左括å·åŽè‡ªåŠ¨æ’å…¥å³æ‹¬å·", "formatOnType": "控制编辑器是å¦åº”在键入åŽè‡ªåŠ¨è®¾ç½®è¡Œçš„æ ¼å¼", "formatOnPaste": "控制编辑器是å¦åº”自动设置粘贴内容的格å¼ã€‚æ ¼å¼åŒ–程åºå¿…é¡»å¯ç”¨å¹¶ä¸”能设置文档中æŸä¸€èŒƒå›´çš„æ ¼å¼ã€‚", @@ -72,6 +75,10 @@ "trimAutoWhitespace": "删除尾éšè‡ªåŠ¨æ’入的空格", "stablePeek": "å³ä½¿åœ¨åŒå‡»ç¼–辑器内容或按 Esc 键时,也è¦ä¿æŒé€Ÿè§ˆç¼–辑器的打开状æ€ã€‚", "dragAndDrop": "控制编辑器是å¦åº”该å…许通过拖放移动所选项。", + "accessibilitySupport.auto": "ç¼–è¾‘å™¨å°†ä½¿ç”¨å¹³å° API 以检测是å¦é™„加了å±å¹•é˜…读器。", + "accessibilitySupport.on": "编辑器将对å±å¹•é˜…读器的使用进行永久优化。", + "accessibilitySupport.off": "编辑器将ä¸å†å¯¹å±å¹•é˜…读器的使用进行优化。", + "accessibilitySupport": "控制编辑器是å¦åº”è¿è¡Œåœ¨å¯¹å±å¹•é˜…读器进行优化的模å¼ã€‚", "sideBySide": "控制 Diff 编辑器以并排或内è”å½¢å¼æ˜¾ç¤ºå·®å¼‚", "ignoreTrimWhitespace": "控制差异编辑器是å¦å°†å¯¹å‰å¯¼ç©ºæ ¼æˆ–å°¾éšç©ºæ ¼çš„更改显示为差异", "renderIndicators": "控制差异编辑器是å¦ä¸ºå·²æ·»åŠ /删除的更改显示 +/- 指示符å·", diff --git a/i18n/chs/src/vs/editor/common/config/editorOptions.i18n.json b/i18n/chs/src/vs/editor/common/config/editorOptions.i18n.json index 9d5691d3e42..fa32e6dd252 100644 --- a/i18n/chs/src/vs/editor/common/config/editorOptions.i18n.json +++ b/i18n/chs/src/vs/editor/common/config/editorOptions.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "accessibilityOffAriaLabel": "现在无法访问编辑器。按 Alt+F1 显示选项。", "editorViewAccessibleLabel": "编辑器内容" } \ No newline at end of file diff --git a/i18n/chs/src/vs/editor/contrib/find/common/findController.i18n.json b/i18n/chs/src/vs/editor/contrib/find/common/findController.i18n.json index 0ae6f9d406d..1125fe32bcd 100644 --- a/i18n/chs/src/vs/editor/contrib/find/common/findController.i18n.json +++ b/i18n/chs/src/vs/editor/contrib/find/common/findController.i18n.json @@ -14,6 +14,5 @@ "addSelectionToPreviousFindMatch": "将选择内容添加到上一查找匹é…项", "moveSelectionToNextFindMatch": "将上次选择移动到下一个查找匹é…项", "moveSelectionToPreviousFindMatch": "将上个选择内容移动到上一查找匹é…项", - "selectAllOccurencesOfFindMatch": "选择所有找到的查找匹é…项", "changeAll.label": "更改所有匹é…项" } \ No newline at end of file diff --git a/i18n/chs/src/vs/editor/contrib/format/browser/formatActions.i18n.json b/i18n/chs/src/vs/editor/contrib/format/browser/formatActions.i18n.json index e1cac086434..7a87ba77804 100644 --- a/i18n/chs/src/vs/editor/contrib/format/browser/formatActions.i18n.json +++ b/i18n/chs/src/vs/editor/contrib/format/browser/formatActions.i18n.json @@ -4,10 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "hint11": "在第 {0} 行作出1 次格å¼ç¼–辑", + "hint11": "在第 {0} 行进行了 1 次格å¼ç¼–辑", "hintn1": "在第 {1} 行进行了 {0} 次格å¼ç¼–辑", "hint1n": "第 {0} 行到第 {1} 行间进行了 1 次格å¼ç¼–辑", - "hintnn": "Made {0} formatting edits between lines {1} and {2}", - "formatDocument.label": "Format Document", + "hintnn": "第 {1} 行到第 {2} 行间进行了 {0} 次格å¼ç¼–辑", + "formatDocument.label": "æ ¼å¼åŒ–文件", "formatSelection.label": "æ ¼å¼åŒ–选定代ç " } \ No newline at end of file diff --git a/i18n/chs/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json b/i18n/chs/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json index 26bf7a51ac5..710eeeefcfc 100644 --- a/i18n/chs/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json +++ b/i18n/chs/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json @@ -5,8 +5,8 @@ // Do not edit this file. It is machine generated. { "aria.oneReference": "在文件 {0} çš„ {1} è¡Œ {2} 列的符å·", - "aria.fileReferences.1": "{0} 中有 1 个符å·", - "aria.fileReferences.N": "{1} 中有 {0} 个符å·", + "aria.fileReferences.1": "{0} 中有 1 个符å·ï¼Œå®Œæ•´è·¯å¾„:{1}", + "aria.fileReferences.N": "{1} 中有 {0} 个符å·ï¼Œå®Œæ•´è·¯å¾„:{2}", "aria.result.0": "未找到结果", "aria.result.1": "在 {0} 中找到 1 个符å·", "aria.result.n1": "在 {1} 中找到 {0} 个符å·", diff --git a/i18n/chs/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json b/i18n/chs/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json index 806db0f0748..2e644c790f6 100644 --- a/i18n/chs/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json +++ b/i18n/chs/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json @@ -21,6 +21,8 @@ "menus.scmTitle": "æºä»£ç ç®¡ç†æ ‡é¢˜èœå•", "menus.resourceGroupContext": "æºä»£ç ç®¡ç†èµ„æºç»„上下文èœå•", "menus.resourceStateContext": "æºä»£ç ç®¡ç†èµ„æºçŠ¶æ€ä¸Šä¸‹æ–‡èœå•", + "view.viewTitle": "æ供的视图的标题èœå•", + "view.itemContext": "æ供的视图中的项目的上下文èœå•", "nonempty": "应为éžç©ºå€¼ã€‚", "opticon": "å¯ä»¥çœç•¥å±žæ€§â€œå›¾æ ‡â€æˆ–者它必须是一个字符串或类似“{dark, light}â€çš„文本", "requireStringOrObject": "属性“{0}â€ä¸ºå¿…需且其类型必须为“字符串â€æˆ–“对象â€", diff --git a/i18n/chs/src/vs/platform/extensions/common/extensionsRegistry.i18n.json b/i18n/chs/src/vs/platform/extensions/common/extensionsRegistry.i18n.json index 2c8ade8f369..feafccf3451 100644 --- a/i18n/chs/src/vs/platform/extensions/common/extensionsRegistry.i18n.json +++ b/i18n/chs/src/vs/platform/extensions/common/extensionsRegistry.i18n.json @@ -14,6 +14,12 @@ "vscode.extension.contributes": "由此包表示的 VS Code 扩展的所有贡献。", "vscode.extension.preview": "在 Marketplace 中设置扩展,将其标记为“预览â€ã€‚", "vscode.extension.activationEvents": "VS Code 扩展的激活事件。", + "vscode.extension.activationEvents.onLanguage": "在打开被解æžä¸ºæŒ‡å®šè¯­è¨€çš„文件时å‘出的激活事件。", + "vscode.extension.activationEvents.onCommand": "在调用指定命令时å‘出的激活事件。", + "vscode.extension.activationEvents.onDebug": "在指定类型的调试会è¯å¼€å§‹æ—¶å‘出的激活事件。", + "vscode.extension.activationEvents.workspaceContains": "在打开至少包å«ä¸€ä¸ªåŒ¹é…指定 glob 模å¼çš„文件的文件夹时å‘出的激活事件。", + "vscode.extension.activationEvents.onView": "在指定视图被展开时å‘出的激活事件。", + "vscode.extension.activationEvents.star": "在 VS Code å¯åŠ¨æ—¶å‘出的激活事件。为确ä¿è‰¯å¥½çš„最终用户体验,请仅在其他激活事件组åˆä¸é€‚用于你的情况时,æ‰åœ¨æ‰©å±•ä¸­ä½¿ç”¨æ­¤äº‹ä»¶ã€‚", "vscode.extension.badges": "在 Marketplace 的扩展页边æ ä¸­æ˜¾ç¤ºçš„徽章数组。", "vscode.extension.badges.url": "å¾½ç« å›¾åƒ URL。", "vscode.extension.badges.href": "徽章链接。", diff --git a/i18n/chs/src/vs/platform/extensions/node/extensionValidator.i18n.json b/i18n/chs/src/vs/platform/extensions/node/extensionValidator.i18n.json index 58daf0e1a24..73890b4a095 100644 --- a/i18n/chs/src/vs/platform/extensions/node/extensionValidator.i18n.json +++ b/i18n/chs/src/vs/platform/extensions/node/extensionValidator.i18n.json @@ -9,15 +9,15 @@ "versionSpecificity2": "\"engines.vscode\" ({0}) 中指定的版本ä¸å¤Ÿå…·ä½“。对于 1.0.0 之åŽçš„ vscode 版本,请至少定义主è¦æƒ³è¦çš„版本。例如: ^1.10.0ã€1.10.xã€1.x.xã€2.x.x 等。", "versionMismatch": "扩展与 Code {0} ä¸å…¼å®¹ã€‚扩展需è¦: {1}。", "extensionDescription.empty": "已获得空扩展说明", - "extensionDescription.publisher": "属性“{0}â€æ˜¯å¿…需的,其类型必须是“字符串â€", - "extensionDescription.name": "属性“{0}â€æ˜¯å¿…需的,其类型必须是“字符串â€", - "extensionDescription.version": "属性“{0}â€æ˜¯å¿…需的,其类型必须是“字符串â€", - "extensionDescription.engines": "属性“{0}â€ä¸ºå¿…需且其类型必须为 \"object\"", - "extensionDescription.engines.vscode": "属性“{0}â€æ˜¯å¿…需的,其类型必须是“字符串â€", - "extensionDescription.extensionDependencies": "属性“{0}â€å¯ä»¥çœç•¥æˆ–其类型必须是 \"string[]\"", - "extensionDescription.activationEvents1": "属性“{0}â€å¯ä»¥çœç•¥æˆ–其类型必须是 \"string[]\"", + "extensionDescription.publisher": "属性“{0}â€æ˜¯å¿…è¦å±žæ€§ï¼Œå…¶ç±»åž‹å¿…须是 \"string\"", + "extensionDescription.name": "属性“{0}â€æ˜¯å¿…è¦å±žæ€§ï¼Œå…¶ç±»åž‹å¿…须是 \"string\"", + "extensionDescription.version": "属性“{0}â€æ˜¯å¿…è¦å±žæ€§ï¼Œå…¶ç±»åž‹å¿…须是 \"string\"", + "extensionDescription.engines": "属性“{0}â€æ˜¯å¿…è¦å±žæ€§ï¼Œå…¶ç±»åž‹å¿…须是 \"object\"", + "extensionDescription.engines.vscode": "属性“{0}â€æ˜¯å¿…è¦å±žæ€§ï¼Œå…¶ç±»åž‹å¿…须是 \"string\"", + "extensionDescription.extensionDependencies": "属性“{0}â€å¯ä»¥çœç•¥ï¼Œå¦åˆ™å…¶ç±»åž‹å¿…须是 \"string[]\"", + "extensionDescription.activationEvents1": "属性“{0}â€å¯ä»¥çœç•¥ï¼Œå¦åˆ™å…¶ç±»åž‹å¿…须是 \"string[]\"", "extensionDescription.activationEvents2": "å¿…é¡»åŒæ—¶æŒ‡å®šæˆ–åŒæ—¶çœç•¥å±žæ€§â€{0}“和â€{1}“", - "extensionDescription.main1": "属性“{0}â€å¯ä»¥çœç•¥ï¼Œæˆ–者其类型必须是“字符串â€", + "extensionDescription.main1": "属性“{0}â€å¯ä»¥çœç•¥ï¼Œå¦åˆ™å…¶ç±»åž‹å¿…须是 \"string\"", "extensionDescription.main2": "应在扩展文件夹({1})ä¸­åŒ…å« \"main\" ({0})。这å¯èƒ½ä¼šä½¿æ‰©å±•ä¸å¯ç§»æ¤ã€‚", "extensionDescription.main3": "å¿…é¡»åŒæ—¶æŒ‡å®šæˆ–åŒæ—¶çœç•¥å±žæ€§â€{0}“和â€{1}“", "notSemver": "扩展版本与 semver ä¸å…¼å®¹ã€‚" diff --git a/i18n/chs/src/vs/platform/history/electron-main/historyMainService.i18n.json b/i18n/chs/src/vs/platform/history/electron-main/historyMainService.i18n.json new file mode 100644 index 00000000000..61b499c3553 --- /dev/null +++ b/i18n/chs/src/vs/platform/history/electron-main/historyMainService.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "newWindow": "新建窗å£", + "newWindowDesc": "打开一个新窗å£", + "recentFolders": "最近的文件夹", + "folderDesc": "{0} {1}" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/platform/markers/common/problemMatcher.i18n.json b/i18n/chs/src/vs/platform/markers/common/problemMatcher.i18n.json index b9fc2ddbbde..53f5b8e472a 100644 --- a/i18n/chs/src/vs/platform/markers/common/problemMatcher.i18n.json +++ b/i18n/chs/src/vs/platform/markers/common/problemMatcher.i18n.json @@ -29,7 +29,7 @@ "ProblemMatcherParser.noOwner": "错误: æ述未定义所有者:\n{0}\n", "ProblemMatcherParser.noFileLocation": "错误: æ述未定义文件ä½ç½®:\n{0}\n", "ProblemMatcherParser.unknownSeverity": "ä¿¡æ¯ï¼šæœªçŸ¥ä¸¥é‡æ€§ {0}。有效值为“errorâ€ã€â€œwarningâ€å’Œâ€œinfoâ€ã€‚\n", - "ProblemMatcherParser.noDefinedPatter": "错误: å«æ ‡è¯†ç¬¦ {0} 的模å¼ä¸å­˜åœ¨ã€‚", + "ProblemMatcherParser.noDefinedPatter": "错误: 标识符为 {0} 的模å¼ä¸å­˜åœ¨ã€‚", "ProblemMatcherParser.noIdentifier": "错误: 模å¼å±žæ€§å¼•ç”¨ç©ºæ ‡è¯†ç¬¦ã€‚", "ProblemMatcherParser.noValidIdentifier": "错误: 模å¼å±žæ€§ {0} 是无效的模å¼å˜é‡å。", "ProblemMatcherParser.problemPattern.watchingMatcher": "问题匹é…程åºå¿…须定义监视的开始模å¼å’Œç»“æŸæ¨¡å¼ã€‚", diff --git a/i18n/chs/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/chs/src/vs/platform/theme/common/colorRegistry.i18n.json index 37be20d77e9..2b6fb78afe8 100644 --- a/i18n/chs/src/vs/platform/theme/common/colorRegistry.i18n.json +++ b/i18n/chs/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -12,7 +12,7 @@ "focusBorder": "焦点元素的整体边框颜色。此颜色仅在ä¸è¢«å…¶ä»–组件覆盖时适用。", "contrastBorder": "在元素周围é¢å¤–的一层边框,用æ¥æ高对比度从而区别其他元素。", "activeContrastBorder": "在活动元素周围é¢å¤–的一层边框,用æ¥æ高对比度从而区别其他元素。", - "selectionBackground": "工作å°æ‰€é€‰æ–‡æœ¬çš„背景颜色(例如输入字段或文本区域)。注æ„,本设置ä¸é€‚用于编辑器和终端。", + "selectionBackground": "工作å°æ‰€é€‰æ–‡æœ¬çš„背景颜色(例如输入字段或文本区域)。注æ„,本设置ä¸é€‚用于编辑器。", "textSeparatorForeground": "文字分隔符的颜色。", "textLinkForeground": "文本中链接的å‰æ™¯è‰²ã€‚", "textLinkActiveForeground": "文本中活动链接的å‰æ™¯è‰²ã€‚", @@ -60,6 +60,7 @@ "editorBackground": "编辑器背景颜色。", "editorForeground": "编辑器默认å‰æ™¯è‰²ã€‚", "editorWidgetBackground": "编辑器组件(如查找/替æ¢)背景颜色。", + "editorWidgetBorder": "编辑器å°éƒ¨ä»¶çš„边框颜色。此颜色仅在å°éƒ¨ä»¶æœ‰è¾¹æ¡†ä¸”ä¸è¢«å°éƒ¨ä»¶é‡å†™æ—¶é€‚用。", "editorSelection": "编辑器所选内容的颜色。", "editorInactiveSelection": "éžæ´»åŠ¨ç¼–辑器中所选内容的颜色。", "editorSelectionHighlight": "与所选内容具有相åŒå†…容的区域颜色。", @@ -68,7 +69,7 @@ "findRangeHighlight": "é™åˆ¶æœç´¢çš„范围的颜色。", "hoverHighlight": "悬åœæ示显示时文本底下的高亮颜色。", "hoverBackground": "编辑器悬åœæ示的背景颜色。", - "hoverBorder": "编辑器软键盘边框颜色。", + "hoverBorder": "光标悬åœæ—¶ç¼–辑器的边框颜色。", "activeLinkForeground": "活动链接颜色。", "diffEditorInserted": "å·²æ’入文本的背景颜色。", "diffEditorRemoved": "被删除文本的背景颜色。", @@ -78,6 +79,10 @@ "mergeCurrentContentBackground": "内è”åˆå¹¶å†²çªä¸­å½“å‰ç‰ˆæœ¬åŒºåŸŸçš„内容背景色。", "mergeIncomingHeaderBackground": "内è”åˆå¹¶å†²çªä¸­ä¼ å…¥çš„版本区域的标头背景色。", "mergeIncomingContentBackground": "内è”åˆå¹¶å†²çªä¸­ä¼ å…¥çš„版本区域的内容背景色。", + "mergeCommonHeaderBackground": "内è”åˆå¹¶å†²çªä¸­å…±åŒç¥–先区域的标头背景色。", + "mergeCommonContentBackground": "内è”åˆå¹¶å†²çªä¸­å…±åŒç¥–先区域的内容背景色。", + "mergeBorder": "内è”åˆå¹¶å†²çªä¸­æ ‡å¤´å’Œåˆ†å‰²çº¿çš„边框颜色。", "overviewRulerCurrentContentForeground": "内è”åˆå¹¶å†²çªä¸­å½“å‰ç‰ˆæœ¬åŒºåŸŸçš„概览标尺å‰æ™¯è‰²ã€‚", - "overviewRulerIncomingContentForeground": "内è”åˆå¹¶å†²çªä¸­ä¼ å…¥çš„版本区域的概览标尺å‰æ™¯è‰²ã€‚" + "overviewRulerIncomingContentForeground": "内è”åˆå¹¶å†²çªä¸­ä¼ å…¥çš„版本区域的概览标尺å‰æ™¯è‰²ã€‚", + "overviewRulerCommonContentForeground": "内è”åˆå¹¶å†²çªä¸­å…±åŒç¥–先区域的概览标尺å‰æ™¯è‰²ã€‚" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/chs/src/vs/workbench/api/node/extHostTask.i18n.json index 8b6ad71cd4e..4b90a12aaf2 100644 --- a/i18n/chs/src/vs/workbench/api/node/extHostTask.i18n.json +++ b/i18n/chs/src/vs/workbench/api/node/extHostTask.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "task.label": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json b/i18n/chs/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json index 29e014471da..9b17b8e6572 100644 --- a/i18n/chs/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json +++ b/i18n/chs/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json @@ -5,5 +5,6 @@ // Do not edit this file. It is machine generated. { "hideActivitBar": "éšè—活动æ ", - "activityBarAriaLabel": "活动视图切æ¢å™¨" + "activityBarAriaLabel": "活动视图切æ¢å™¨", + "globalActions": "全局动作" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/browser/parts/editor/editorActions.i18n.json b/i18n/chs/src/vs/workbench/browser/parts/editor/editorActions.i18n.json index dc267856d02..bc03cc6b1af 100644 --- a/i18n/chs/src/vs/workbench/browser/parts/editor/editorActions.i18n.json +++ b/i18n/chs/src/vs/workbench/browser/parts/editor/editorActions.i18n.json @@ -19,6 +19,7 @@ "closeEditorsToTheLeft": "关闭左侧编辑器", "closeEditorsToTheRight": "关闭å³ä¾§ç¼–辑器", "closeAllEditors": "关闭所有编辑器", + "closeUnmodifiedEditors": "关闭组中未作更改的编辑器", "closeEditorsInOtherGroups": "关闭其他组中的编辑器", "closeOtherEditorsInGroup": "关闭其他编辑器", "closeEditorsInGroup": "关闭组中的所有编辑器", diff --git a/i18n/chs/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json b/i18n/chs/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json index 056d85f4a23..0b7d6bc441e 100644 --- a/i18n/chs/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json +++ b/i18n/chs/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json @@ -12,6 +12,7 @@ "endOfLineCarriageReturnLineFeed": "CRLF", "tabFocusModeEnabled": "按 Tab 移动焦点", "screenReaderDetected": "检测到å±å¹•é˜…读器", + "screenReaderDetectedExtra": "如果你没有使用å±å¹•é˜…读器,请将设置中的“editor.accessibilitySupportâ€æ”¹ä¸ºâ€œoffâ€ã€‚", "disableTabMode": "ç¦ç”¨è¾…助功能模å¼", "gotoLine": "转到行", "indentation": "缩进", diff --git a/i18n/chs/src/vs/workbench/browser/parts/editor/titleControl.i18n.json b/i18n/chs/src/vs/workbench/browser/parts/editor/titleControl.i18n.json index 33c78c3b911..63726f32765 100644 --- a/i18n/chs/src/vs/workbench/browser/parts/editor/titleControl.i18n.json +++ b/i18n/chs/src/vs/workbench/browser/parts/editor/titleControl.i18n.json @@ -8,6 +8,7 @@ "closeOthers": "关闭其他", "closeRight": "关闭到å³ä¾§", "closeAll": "全部关闭", + "closeAllUnmodified": "关闭未更改的", "keepOpen": "ä¿æŒæ‰“开状æ€", "showOpenedEditors": "显示打开的编辑器", "araLabelEditorActions": "编辑器æ“作" diff --git a/i18n/chs/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json b/i18n/chs/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json new file mode 100644 index 00000000000..04188ac2f79 --- /dev/null +++ b/i18n/chs/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpen": "转到文件...", + "quickNavigateNext": "在 Quick Open 中导航到下一个", + "quickNavigatePrevious": "在 Quick Open 中导航到上一个", + "quickSelectNext": "在 Quick Open 中选择“下一步â€", + "quickSelectPrevious": "在 Quick Open 中选择“上一步â€" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/browser/quickopen.i18n.json b/i18n/chs/src/vs/workbench/browser/quickopen.i18n.json index 5df82e1051d..949f6468fc2 100644 --- a/i18n/chs/src/vs/workbench/browser/quickopen.i18n.json +++ b/i18n/chs/src/vs/workbench/browser/quickopen.i18n.json @@ -6,6 +6,5 @@ { "noResultsMatching": "没有匹é…的结果", "noResultsFound2": "未找到结果", - "entryAriaLabel": "{0},命令", - "noCommands": "没有匹é…的命令" + "entryAriaLabel": "{0},命令" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/browser/viewlet.i18n.json b/i18n/chs/src/vs/workbench/browser/viewlet.i18n.json index 9f0c295e5f2..6f2dfb7174d 100644 --- a/i18n/chs/src/vs/workbench/browser/viewlet.i18n.json +++ b/i18n/chs/src/vs/workbench/browser/viewlet.i18n.json @@ -4,6 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "collapse": "全部折å ", - "viewToolbarAriaLabel": "{0} æ“作" + "collapse": "全部折å " } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/common/theme.i18n.json b/i18n/chs/src/vs/workbench/common/theme.i18n.json index e130cd7df4d..7f9baabd3e4 100644 --- a/i18n/chs/src/vs/workbench/common/theme.i18n.json +++ b/i18n/chs/src/vs/workbench/common/theme.i18n.json @@ -7,12 +7,17 @@ "tabActiveBackground": "活动选项å¡çš„背景色。在编辑器区域,选项å¡æ˜¯ç¼–辑器的容器。å¯åœ¨ä¸€ä¸ªç¼–辑器组中打开多个选项å¡ã€‚å¯ä»¥æœ‰å¤šä¸ªç¼–辑器组。", "tabInactiveBackground": "éžæ´»åŠ¨é€‰é¡¹å¡çš„背景色。在编辑器区域,选项å¡æ˜¯ç¼–辑器的容器。å¯åœ¨ä¸€ä¸ªç¼–辑器组中打开多个选项å¡ã€‚å¯ä»¥æœ‰å¤šä¸ªç¼–辑器组。", "tabBorder": "用于将选项å¡å½¼æ­¤åˆ†éš”开的边框。选项å¡æ˜¯ç¼–辑器区域中编辑器的容器。å¯åœ¨ä¸€ä¸ªç¼–辑器组中打开多个选项å¡ã€‚å¯ä»¥å­˜åœ¨å¤šä¸ªç¼–辑器组。", + "tabActiveForeground": "活动组中活动选项å¡çš„å‰æ™¯è‰²ã€‚在编辑器区域,选项å¡æ˜¯ç¼–辑器的容器。å¯åœ¨ä¸€ä¸ªç¼–辑器组中打开多个选项å¡ã€‚å¯ä»¥æœ‰å¤šä¸ªç¼–辑器组。", + "tabInactiveForeground": "活动组中éžæ´»åŠ¨é€‰é¡¹å¡çš„å‰æ™¯è‰²ã€‚在编辑器区域,选项å¡æ˜¯ç¼–辑器的容器。å¯åœ¨ä¸€ä¸ªç¼–辑器组中打开多个选项å¡ã€‚å¯ä»¥æœ‰å¤šä¸ªç¼–辑器组。", + "tabUnfocusedActiveForeground": "éžæ´»åŠ¨ç»„中活动选项å¡çš„å‰æ™¯è‰²ã€‚在编辑器区域,选项å¡æ˜¯ç¼–辑器的容器。å¯åœ¨ä¸€ä¸ªç¼–辑器组中打开多个选项å¡ã€‚å¯ä»¥æœ‰å¤šä¸ªç¼–辑器组。", + "tabUnfocusedInactiveForeground": "éžæ´»åŠ¨ç»„中éžæ´»åŠ¨é€‰é¡¹å¡çš„å‰æ™¯è‰²ã€‚在编辑器区域,选项å¡æ˜¯ç¼–辑器的容器。å¯åœ¨ä¸€ä¸ªç¼–辑器组中打开多个选项å¡ã€‚å¯ä»¥æœ‰å¤šä¸ªç¼–辑器组。", "editorGroupBackground": "编辑器组的背景颜色。编辑器组是编辑器的容器。此颜色在拖动编辑器组时显示。", "tabsContainerBackground": "å¯ç”¨é€‰é¡¹å¡æ—¶ç¼–辑器组标题的背景颜色。编辑器组是编辑器的容器。", "tabsContainerBorder": "选项å¡å¯ç”¨æ—¶ç¼–辑器组标题的边框颜色。编辑器组是编辑器的容器。", "editorGroupHeaderBackground": "ç¦ç”¨é€‰é¡¹å¡æ—¶ç¼–辑器组标题的背景颜色。编辑器组是编辑器的容器。", "editorGroupBorder": "将多个编辑器组彼此分隔开的颜色。编辑器组是编辑器的容器。", "editorDragAndDropBackground": "拖动编辑器时的背景颜色。此颜色应有é€æ˜Žåº¦ï¼Œä»¥ä¾¿ç¼–辑器内容能é€è¿‡èƒŒæ™¯ã€‚", + "panelBackground": "é¢æ¿çš„背景色。é¢æ¿æ˜¾ç¤ºåœ¨ç¼–辑器区域下方,å¯åŒ…å«è¾“出和集æˆç»ˆç«¯ç­‰è§†å›¾ã€‚", "panelBorder": "分隔到编辑器的顶部é¢æ¿è¾¹æ¡†è‰²ã€‚é¢æ¿æ˜¾ç¤ºåœ¨ç¼–辑器区域下方,å¯åŒ…å«è¾“出和集æˆç»ˆç«¯ç­‰è§†å›¾ã€‚", "panelActiveTitleForeground": "活动é¢æ¿çš„标题颜色。é¢æ¿æ˜¾ç¤ºåœ¨ç¼–辑器区域下方,并包å«è¾“出和集æˆç»ˆç«¯ç­‰è§†å›¾ã€‚", "panelInactiveTitleForeground": "éžæ´»åŠ¨é¢æ¿çš„标题颜色。é¢æ¿æ˜¾ç¤ºåœ¨ç¼–辑器区域下方,并包å«è¾“出和集æˆç»ˆç«¯ç­‰è§†å›¾ã€‚", @@ -43,5 +48,9 @@ "titleBarActiveBackground": "窗å£å¤„于活动状æ€æ—¶çš„标题æ èƒŒæ™¯è‰²ã€‚请注æ„,该颜色当å‰ä»…在 macOS 上å—支æŒã€‚", "titleBarInactiveBackground": "窗å£å¤„于éžæ´»åŠ¨çŠ¶æ€æ—¶çš„标题æ èƒŒæ™¯è‰²ã€‚请注æ„,该颜色当å‰ä»…在 macOS 上å—支æŒã€‚", "notificationsForeground": "通知å‰æ™¯è‰²ã€‚通知从窗å£é¡¶éƒ¨æ»‘入。", - "notificationsBackground": "通知背颜色。通知从窗å£é¡¶éƒ¨æ»‘入。" + "notificationsBackground": "通知背颜色。通知从窗å£é¡¶éƒ¨æ»‘入。", + "notificationsButtonForeground": "通知按钮å‰æ™¯è‰²ã€‚通知从窗å£é¡¶éƒ¨æ»‘入。", + "notificationsInfoForeground": "消æ¯é€šçŸ¥å‰æ™¯è‰²ã€‚通知从窗å£é¡¶éƒ¨æ»‘入。", + "notificationsWarningForeground": "警告通知å‰æ™¯è‰²ã€‚通知从窗å£é¡¶éƒ¨æ»‘入。", + "notificationsErrorForeground": "错误通知å‰æ™¯è‰²ã€‚通知从窗å£é¡¶éƒ¨æ»‘入。" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/electron-browser/actions.i18n.json b/i18n/chs/src/vs/workbench/electron-browser/actions.i18n.json index 7ee775d592c..0663a15d8b6 100644 --- a/i18n/chs/src/vs/workbench/electron-browser/actions.i18n.json +++ b/i18n/chs/src/vs/workbench/electron-browser/actions.i18n.json @@ -6,9 +6,6 @@ { "closeActiveEditor": "关闭编辑器", "closeWindow": "关闭窗å£", - "switchWindow": "切æ¢çª—å£", - "switchWindowPlaceHolder": "选择窗å£", - "current": "当å‰çª—å£", "closeFolder": "关闭文件夹", "noFolderOpened": "此实例中没有è¦å…³é—­çš„已打开文件夹。", "newWindow": "新建窗å£", @@ -20,11 +17,16 @@ "zoomReset": "é‡ç½®ç¼©æ”¾", "appPerf": "å¯åŠ¨æ€§èƒ½", "reloadWindow": "é‡æ–°åŠ è½½çª—å£", - "openRecent": "打开最近的文件", + "switchWindowPlaceHolder": "选择切æ¢çš„窗å£", + "current": "当å‰çª—å£", + "switchWindow": "切æ¢çª—å£...", + "quickSwitchWindow": "快速切æ¢çª—å£...", "folders": "文件夹", "files": "文件", "openRecentPlaceHolderMac": "选择路径(在新窗å£ä¸­æŒ‰ä½ Cmd 键打开)", "openRecentPlaceHolder": "选择è¦æ‰“开的路径(在新窗å£ä¸­æŒ‰ä½ Ctrl 键打开)", + "openRecent": "打开最近的文件…", + "quickOpenRecent": "快速打开最近的文件…", "closeMessages": "关闭通知消æ¯", "reportIssues": "报告问题", "reportPerformanceIssue": "报告性能问题", @@ -32,10 +34,10 @@ "openDocumentationUrl": "文档", "openIntroductoryVideosUrl": "入门视频", "toggleSharedProcess": "切æ¢å…±äº«è¿›ç¨‹", - "navigateLeft": "移动到左侧的视图部分", - "navigateRight": "移动到å³ä¾§çš„视图部分", - "navigateUp": "移动到上方的视图部分", - "navigateDown": "移动到下方的视图部分", + "navigateLeft": "导航到左侧视图", + "navigateRight": "导航到å³ä¾§è§†å›¾", + "navigateUp": "导航到上方视图", + "navigateDown": "导航到下方视图", "increaseViewSize": "增加当å‰è§†å›¾å¤§å°", "decreaseViewSize": "å‡å°å½“å‰è§†å›¾å¤§å°" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/chs/src/vs/workbench/electron-browser/main.contribution.i18n.json index 6997449c1ce..01e2a1e7dff 100644 --- a/i18n/chs/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/chs/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -31,10 +31,11 @@ "window.openFoldersInNewWindow.off": "文件夹将替æ¢ä¸Šä¸€ä¸ªæ´»åŠ¨çª—å£", "window.openFoldersInNewWindow.default": "文件夹在新窗å£ä¸­æ‰“开,除éžä»Žåº”用程åºå†…选å–一个文件夹(例如,通过“文件â€èœå•)", "openFoldersInNewWindow": "控制文件夹应在新窗å£ä¸­æ‰“开还是替æ¢ä¸Šä¸€æ´»åŠ¨çª—å£ã€‚\n- default: 文件夹将在新窗å£ä¸­æ‰“开,除éžæ–‡ä»¶æ˜¯ä»Žåº”用程åºå†…选å–çš„(例如通过“文件â€èœå•)\n- on: 文件夹将在新窗å£ä¸­æ‰“å¼€\n- off: 文件夹将替æ¢ä¸Šä¸€æ´»åŠ¨çª—å£\n注æ„,å¯èƒ½ä»ä¼šå­˜åœ¨å¿½ç•¥æ­¤è®¾ç½®çš„情况(例如当使用 -new-window 或 -reuse-window 命令行选项时)。", - "window.reopenFolders.none": "æ°¸ä¸é‡æ–°æ‰“开文件夹。", - "window.reopenFolders.one": "é‡æ–°æ‰“开上一个活动文件夹。", - "window.reopenFolders.all": "é‡æ–°æ‰“开上一个会è¯çš„所有文件夹。", - "reopenFolders": "控制é‡å¯åŽé‡æ–°æ‰“开文件夹的方å¼ã€‚选择“noneâ€è¡¨ç¤ºæ°¸ä¸é‡æ–°æ‰“开文件夹,选择“oneâ€è¡¨ç¤ºé‡æ–°æ‰“开最åŽä½¿ç”¨çš„一个文件夹,或选择“allâ€è¡¨ç¤ºæ‰“开上次会è¯çš„所有文件夹。", + "window.reopenFolders.all": "é‡æ–°æ‰“开所有窗å£ã€‚", + "window.reopenFolders.folders": "é‡æ–°æ‰“开所有文件夹。空窗å£å°†ä¸ä¼šè¢«æ¢å¤ã€‚", + "window.reopenFolders.one": "é‡æ–°æ‰“开上一个活动窗å£ã€‚", + "window.reopenFolders.none": "永远ä¸é‡æ–°æ‰“开窗å£ã€‚总是以一个空窗å£å¯åŠ¨ã€‚", + "restoreWindows": "控制é‡å¯åŽé‡æ–°æ‰“开窗å£çš„æ–¹å¼ã€‚选择“noneâ€åˆ™æ°¸è¿œåœ¨å¯åŠ¨æ—¶æ‰“开一个空窗å£ï¼›é€‰æ‹©â€œoneâ€åˆ™é‡æ–°æ‰“开最åŽä½¿ç”¨çš„窗å£ï¼›é€‰æ‹©â€œfoldersâ€åˆ™é‡æ–°æ‰“开所有你曾打开的文件夹;或选择“allâ€åˆ™é‡æ–°æ‰“开上次会è¯çš„所有窗å£ã€‚", "restoreFullscreen": "如果窗å£å·²é€€å‡ºå…¨å±æ¨¡å¼ï¼ŒæŽ§åˆ¶å…¶æ˜¯å¦åº”还原为全å±æ¨¡å¼ã€‚", "zoomLevel": "调整窗å£çš„缩放级别。原始大å°æ˜¯ 0,æ¯æ¬¡é€’增(例如 1)或递å‡(例如 -1)è¡¨ç¤ºæ”¾å¤§æˆ–ç¼©å° 20%。也å¯ä»¥è¾“å…¥å°æ•°ä»¥ä¾¿ä»¥æ›´ç²¾ç»†çš„粒度调整缩放级别。", "title": "基于活动编辑器控制窗å£æ ‡é¢˜ã€‚基于上下文替æ¢å˜é‡:\n${activeEditorShort}: 例如 myFile.txt\n${activeEditorMedium}:例如 myFolder/myFile.txt\n${activeEditorLong}: 例如 /Users/Development/myProject/myFolder/myFile.txt\n${rootName}: 例如 myProject\n${rootPath}: 例如 /Users/Development/myProject\n${appName}: 例如 VS Code\n${dirty}: 一个更新指示器,指示活动编辑器是å¦æ›´æ–°\n${separator}: 一个æ¡ä»¶åˆ†éš”符(\"-\"),仅在左å³æ˜¯å…·æœ‰å€¼çš„å˜é‡æ—¶æ‰æ˜¾ç¤º", @@ -58,5 +59,8 @@ "zenMode.hideTabs": "控制打开 Zen 模å¼æ˜¯å¦ä¹Ÿä¼šéšè—工作å°é€‰é¡¹å¡ã€‚", "zenMode.hideStatusBar": "控制打开 Zen 模å¼æ˜¯å¦ä¹Ÿä¼šéšè—工作å°åº•éƒ¨çš„状æ€æ ã€‚", "zenMode.hideActivityBar": "控制打开 Zen 模å¼æ˜¯å¦ä¹Ÿä¼šéšè—工作å°å·¦ä¾§çš„活动æ ã€‚", - "zenMode.restore": "控制如果æŸçª—å£å·²é€€å‡º zen 模å¼ï¼Œæ˜¯å¦åº”还原到 zen 模å¼ã€‚" + "zenMode.restore": "控制如果æŸçª—å£å·²é€€å‡º zen 模å¼ï¼Œæ˜¯å¦åº”还原到 zen 模å¼ã€‚", + "workspaceConfigurationTitle": "工作区", + "files.exclude.boolean": "匹é…文件路径所ä¾æ®çš„ glob 模å¼ã€‚设置为 true 或 false å¯å¯ç”¨æˆ–ç¦ç”¨è¯¥æ¨¡å¼ã€‚", + "workspaces.additionalFolders": "工作区中的文件夹" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json b/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json new file mode 100644 index 00000000000..9085c535771 --- /dev/null +++ b/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json @@ -0,0 +1,26 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "emergencyConfOn": "正在更改“editor.accessibilitySupportâ€è®¾ç½®ä¸ºâ€œonâ€ã€‚", + "openingDocs": "正在打开 VS Code 辅助功能文档页é¢ã€‚", + "introMsg": "感谢试用 VS Code 的辅助功能选项。", + "status": "状æ€:", + "changeConfigToOnMac": "è¦é…置编辑器对å±å¹•é˜…读器进行永久优化,请按 Command+E。", + "changeConfigToOnWinLinux": "è¦é…置编辑器对å±å¹•é˜…读器进行永久优化,请按 Ctrl+E。", + "auto_unknown": "编辑器被é…ç½®ä¸ºä½¿ç”¨å¹³å° API 以检测是å¦é™„加了å±å¹•é˜…读器,但当å‰è¿è¡Œæ—¶ä¸æ”¯æŒæ­¤åŠŸèƒ½ã€‚", + "auto_on": "编辑器自动检测到已附加å±å¹•é˜…读器。", + "auto_off": "编辑器被é…置为自动检测是å¦é™„加了å±å¹•é˜…读器,当å‰æœªæ£€æµ‹åˆ°ã€‚", + "configuredOn": "编辑器被é…置为对å±å¹•é˜…读器的使用进行永久优化 — ä½ å¯ä»¥ç¼–辑设置中的“editor.accessibilitySupportâ€ä»¥æ”¹å˜æ­¤è¡Œä¸ºã€‚", + "configuredOff": "编辑器被é…置为ä¸å¯¹å±å¹•é˜…读器的使用进行优化。", + "tabFocusModeOnMsg": "在当å‰ç¼–辑器中按 Tab 会将焦点移动到下一个å¯èšç„¦çš„元素。按 {0} æ¥åˆ‡æ¢æ­¤è¡Œä¸ºã€‚", + "tabFocusModeOnMsgNoKb": "在当å‰ç¼–辑器中按 Tab 会将焦点移动到下一个å¯èšç„¦çš„元素。当å‰æ— æ³•é€šè¿‡é”®ç»‘定触å‘命令 {0}。", + "tabFocusModeOffMsg": "在当å‰ç¼–辑器中按 Tab å°†æ’入制表符。按 {0} æ¥åˆ‡æ¢æ­¤è¡Œä¸ºã€‚", + "tabFocusModeOffMsgNoKb": "在当å‰ç¼–辑器中按 Tab 会æ’入制表符。当å‰æ— æ³•é€šè¿‡é”®ç»‘定触å‘命令 {0}。", + "openDocMac": "按 Command+H 以打开æµè§ˆå™¨çª—å£ï¼Œå…¶ä¸­åŒ…å«æ›´å¤šæœ‰å…³ VS Code 辅助功能的信æ¯ã€‚", + "openDocWinLinux": "按 Ctrl+H 以打开æµè§ˆå™¨çª—å£ï¼Œå…¶ä¸­åŒ…å«æ›´å¤šæœ‰å…³ VS Code 辅助功能的信æ¯ã€‚", + "outroMsg": "ä½ å¯ä»¥æŒ‰ Esc 或 Shift+Esc 消除此工具æ示并返回到编辑器。", + "ShowAccessibilityHelpAction": "显示辅助功能帮助" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json b/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json b/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json new file mode 100644 index 00000000000..90e803801d3 --- /dev/null +++ b/i18n/chs/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleLocation": "切æ¢å¤šè¡Œä¿®æ”¹é”®" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json b/i18n/chs/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json index b47d705e0f3..230f0bd8f03 100644 --- a/i18n/chs/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json @@ -5,16 +5,12 @@ // Do not edit this file. It is machine generated. { "variablesSection": "å˜é‡éƒ¨åˆ†", - "variables": "å˜é‡", "variablesAriaTreeLabel": "调试å˜é‡", "expressionsSection": "表达å¼éƒ¨åˆ†", - "watch": "监视", "watchAriaTreeLabel": "调试监视表达å¼", "callstackSection": "调用堆栈部分", "debugStopped": "å›  {0} 已暂åœ", - "callStack": "调用堆栈", "callStackAriaLabel": "调试调用堆栈", "breakpointsSection": "断点部分", - "breakpoints": "断点", "breakpointsAriaTreeLabel": "调试断点" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json index 87fec1a103c..fbb9c2b2cd2 100644 --- a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json @@ -4,6 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "previousEditPoint": "Emmet: 上一编辑点", - "nextEditPoint": "Emmet: 下一编辑点" + "previousEditPoint": "Emmet: 转到上一编辑点", + "nextEditPoint": "Emmet: 转到下一编辑点" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json index 0701c9f4ae6..2d8b8d26d44 100644 --- a/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json @@ -9,5 +9,6 @@ "emmetPreferences": "用于修改 Emmet æŸäº›æ“作和解æžç¨‹åºçš„行为的首选项。", "emmetSyntaxProfiles": "为指定的语法定义é…置文件或使用带有特定规则的é…置文件。", "emmetExclude": "ä¸åº”展开 Emmet 缩写的语言数组。", - "emmetExtensionsPath": "åŒ…å« Emmet é…置文件ã€ä»£ç æ®µå’Œé¦–选项的文件夹路径" + "emmetExtensionsPath": "åŒ…å« Emmet é…置文件ã€ä»£ç æ®µå’Œé¦–选项的文件夹路径", + "useNewEmmet": "试用新版 Emmet 模å—(最终会替æ¢æ—§ç‰ˆå•ä¸€ Emmet 库)体验所有 Emmet 功能。" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json b/i18n/chs/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json index 5e357e17480..f8c655a1a89 100644 --- a/i18n/chs/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json @@ -24,6 +24,10 @@ "default": "默认", "debuggers": "调试程åº({0})", "debugger name": "å称", + "views": "视图 ({0})", + "view id": "ID", + "view name": "å称", + "view location": "ä½ç½®", "themes": "主题({0})", "JSON Validation": "JSON 验è¯({0})", "commands": "命令({0})", diff --git a/i18n/chs/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/chs/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 955985888a9..50c0b174efa 100644 --- a/i18n/chs/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -28,7 +28,6 @@ "watcherExclude": "é…置文件路径的 glob 模å¼ä»¥ä»Žæ–‡ä»¶ç›‘视排除。更改此设置è¦æ±‚é‡å¯ã€‚如果在å¯åŠ¨æ—¶é‡åˆ° Code æ¶ˆè€—å¤§é‡ CPU 时间,则å¯ä»¥æŽ’除大型文件夹以å‡å°‘åˆå§‹åŠ è½½ã€‚", "hotExit.off": "ç¦ç”¨çƒ­é€€å‡ºã€‚", "hotExit.onExit": "应用程åºå…³é—­æ—¶å°†è§¦å‘热退出。在 Windows/Linux 上关闭最åŽä¸€ä¸ªçª—å£æˆ–è§¦å‘ workbench.action.quit 命令(命令托盘ã€é”®ç»‘定ã€èœå•ï¼‰ä¼šå¼•èµ·åº”用程åºå…³é—­ã€‚下次å¯åŠ¨æ—¶å°†è¿˜åŽŸæ‰€æœ‰å·²å¤‡ä»½çš„窗å£ã€‚", - "hotExit.onExitAndWindowClose": "应用程åºå…³é—­æ—¶å°†è§¦å‘热退出。在 Windows/Linux 上关闭最åŽä¸€ä¸ªçª—å£ã€è§¦å‘ workbench.action.quit 命令(命令托盘ã€é”®ç»‘定ã€èœå•ï¼‰ä¼šå¼•èµ·åº”用程åºå…³é—­ã€‚对于任何有文件夹打开的窗å£ï¼Œåˆ™ä¸è®ºè¯¥çª—å£æ˜¯å¦æ˜¯æœ€åŽä¸€ä¸ªçª—å£ã€‚下次å¯åŠ¨æ—¶å°†è¿˜åŽŸæ‰€æœ‰æœªæ‰“开文件夹的窗å£ã€‚è‹¥è¦è¿˜åŽŸæ‰“开有文件夹的窗å£ï¼Œè¯·å°†â€œwindow.reopenFoldersâ€è®¾ç½®ä¸ºâ€œallâ€ã€‚", "hotExit": "控制是å¦åœ¨ä¼šè¯é—´è®°ä½æœªä¿å­˜çš„文件,以å…许在退出编辑器时跳过ä¿å­˜æ示。", "defaultLanguage": "分é…给新文件的默认语言模å¼ã€‚", "editorConfigurationTitle": "编辑器", diff --git a/i18n/chs/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json b/i18n/chs/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json index 4d442c51a66..f98b4a8c007 100644 --- a/i18n/chs/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json @@ -5,7 +5,5 @@ // Do not edit this file. It is machine generated. { "explorerSection": "文件资æºç®¡ç†å™¨éƒ¨åˆ†", - "noWorkspace": "无打开的文件夹", - "noWorkspaceHelp": "尚未打开文件夹。", "openFolder": "打开文件夹" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json b/i18n/chs/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json index 33cc7fda987..1639569b110 100644 --- a/i18n/chs/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json @@ -4,8 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "openEditosrSection": "打开的编辑器部分", "openEditors": "打开的编辑器", + "openEditosrSection": "打开的编辑器部分", "treeAriaLabel": "打开的编辑器: 活动文件列表", "dirtyCounter": "{0} 个未ä¿å­˜" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/preferences/browser/keybindingWidgets.i18n.json b/i18n/chs/src/vs/workbench/parts/preferences/browser/keybindingWidgets.i18n.json index 99d48068a9a..1c5aca86231 100644 --- a/i18n/chs/src/vs/workbench/parts/preferences/browser/keybindingWidgets.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/preferences/browser/keybindingWidgets.i18n.json @@ -5,5 +5,5 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.initial": "按所需的键组åˆï¼Œç„¶åŽæŒ‰ Enter。按 Esc å¯å–消。", - "defineKeybinding.chordsTo": "弦形" + "defineKeybinding.chordsTo": "加上" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/chs/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json index 1cd8910edd8..574f03fcc12 100644 --- a/i18n/chs/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -5,5 +5,7 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.start": "定义键绑定", - "defineKeybinding.kbLayoutErrorMessage": "在当å‰é”®ç›˜å¸ƒå±€ä¸‹æ— æ³•ç”Ÿæˆæ­¤ç»„åˆé”®ã€‚" + "defineKeybinding.kbLayoutErrorMessage": "在当å‰é”®ç›˜å¸ƒå±€ä¸‹æ— æ³•ç”Ÿæˆæ­¤ç»„åˆé”®ã€‚", + "defineKeybinding.kbLayoutLocalAndUSMessage": "在你的键盘布局上为 **{0}**(美国标准布局上为 **{1}**)。", + "defineKeybinding.kbLayoutLocalMessage": "在你的键盘布局上为 **{0}**。" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json b/i18n/chs/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json new file mode 100644 index 00000000000..f3d350d6058 --- /dev/null +++ b/i18n/chs/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "relaunchMessage": "设置已更改,需è¦é‡å¯æ‰èƒ½ç”Ÿæ•ˆã€‚", + "relaunchDetail": "按下“é‡å¯â€æŒ‰é’®ä»¥é‡æ–°å¯åŠ¨ {0} 并å¯ç”¨è¯¥è®¾ç½®ã€‚", + "restart": "é‡å¯" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json b/i18n/chs/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json index 40b12587922..5a84e47f5db 100644 --- a/i18n/chs/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json @@ -11,6 +11,6 @@ "snippetSchema.json.default": "空代ç ç‰‡æ®µ", "snippetSchema.json": "用户代ç ç‰‡æ®µé…ç½®", "snippetSchema.json.prefix": "在 Intellisense 中选择代ç ç‰‡æ®µæ—¶å°†ä½¿ç”¨çš„å‰ç¼€", - "snippetSchema.json.body": "代ç ç‰‡æ®µå†…容。使用“${id}â€ã€â€œ${id:label}â€ã€â€œ${1:label}â€ä½œä¸ºå˜é‡ï¼Œä½¿ç”¨ \"$0\" å’Œ \"$1\" 作为光标ä½ç½®", + "snippetSchema.json.body": "代ç ç‰‡æ®µçš„内容。使用“$1â€å’Œâ€œ${1:defaultText}â€å®šä¹‰å…‰æ ‡ä½ç½®ï¼Œä½¿ç”¨â€œ$0â€å®šä¹‰æœ€ç»ˆå…‰æ ‡ä½ç½®ã€‚使用“${varName}â€å’Œâ€œ${varName:defaultText}â€æ’å…¥å˜é‡å€¼ï¼Œä¾‹å¦‚“这是文件:$TM_FILENAMEâ€ã€‚", "snippetSchema.json.description": "代ç ç‰‡æ®µæ述。" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json b/i18n/chs/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json new file mode 100644 index 00000000000..52ab1590ed2 --- /dev/null +++ b/i18n/chs/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "helpUs": "帮助我们改善对 {0} 的支æŒ", + "takeShortSurvey": "å‚与å°è°ƒæŸ¥", + "remindLater": "ç¨åŽæ醒", + "neverAgain": "ä¸å†æ˜¾ç¤º" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json b/i18n/chs/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json new file mode 100644 index 00000000000..36e84d84fb1 --- /dev/null +++ b/i18n/chs/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "surveyQuestion": "您愿æ„å‚与一次简短的å馈调查å—?", + "takeSurvey": "å‚与调查", + "remindLater": "ç¨åŽæ醒", + "neverAgain": "ä¸å†æ˜¾ç¤º" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json b/i18n/chs/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json new file mode 100644 index 00000000000..4ec9c9da625 --- /dev/null +++ b/i18n/chs/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noTasksMatching": "没有匹é…的任务" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/chs/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index bf5eec2631c..8c2a202c0e1 100644 --- a/i18n/chs/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0},任务" + "entryAriaLabel": "{0},任务", + "customizeTask": "自定义任务" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json b/i18n/chs/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json new file mode 100644 index 00000000000..5c6969c70d7 --- /dev/null +++ b/i18n/chs/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noTasksMatching": "没有匹é…的任务", + "noTasksFound": "没有找到测试任务" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/chs/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json index 0c2209acdb6..29d782900ad 100644 --- a/i18n/chs/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -12,5 +12,6 @@ "ConfigurationParser.invalidVaraibleReference": "错误: 无效的 problemMatcher 引用: {0}\n", "ConfigurationParser.noTaskName": "错误: 任务必须æä¾› taskName 属性。将忽略该任务。\n{0}\n", "taskConfiguration.shellArgs": "警告: 任务“{0}â€æ˜¯ shell 命令,该命令的å称或其中一个å‚数具有éžè½¬ä¹‰ç©ºæ ¼ã€‚è‹¥è¦ç¡®ä¿å‘½ä»¤è¡Œå¼•ç”¨æ­£ç¡®ï¼Œè¯·å°†å‚æ•°åˆå¹¶åˆ°è¯¥å‘½ä»¤ã€‚", + "taskConfiguration.noCommandOrDependsOn": "错误:任务“{0}â€æ—¢ä¸æŒ‡å®šå‘½ä»¤ï¼Œä¹Ÿä¸æŒ‡å®š dependsOn 属性。将忽略该任务。其定义为:\n{1}", "taskConfiguration.noCommand": "错误: 任务“{0}â€æœªå®šä¹‰å‘½ä»¤ã€‚将忽略该任务。其定义为:\n{1}" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json b/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json index 46ce4264dea..022342352e6 100644 --- a/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json @@ -7,6 +7,7 @@ "JsonSchema.options": "其他命令选项", "JsonSchema.options.cwd": "已执行程åºæˆ–脚本的当å‰å·¥ä½œç›®å½•ã€‚如果çœç•¥ï¼Œåˆ™ä½¿ç”¨ä»£ç çš„当å‰å·¥ä½œåŒºæ ¹ã€‚", "JsonSchema.options.env": "已执行程åºæˆ– shell 的环境。如果çœç•¥ï¼Œåˆ™ä½¿ç”¨çˆ¶è¿›ç¨‹çš„环境。", + "JsonSchema.shellConfiguration": "é…置使用的 shell。", "JsonSchema.shell.executable": "待使用的 shell。", "JsonSchema.shell.args": "shell å‚数。", "JsonSchema.command": "è¦æ‰§è¡Œçš„命令。å¯ä»¥æ˜¯å¤–部程åºæˆ– shell 命令。", diff --git a/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json b/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json index 739af6ee7d5..f4f41e4b5fc 100644 --- a/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json @@ -5,6 +5,8 @@ // Do not edit this file. It is machine generated. { "JsonSchema.version": "é…置的版本å·", + "JsonSchema._runner": "æ­¤ runner 已完æˆä½¿å‘½ã€‚请使用官方 runner 属性", + "JsonSchema.runner": "定义任务是å¦ä½œä¸ºè¿›ç¨‹æ‰§è¡Œï¼Œè¾“出显示在输出窗å£è¿˜æ˜¯åœ¨ç»ˆç«¯å†…。", "JsonSchema.windows": "Windows 特定的命令é…ç½®", "JsonSchema.mac": "Mac 特定的命令é…ç½®", "JsonSchema.linux": "Linux 特定的命令é…ç½®", diff --git a/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json index 0fc11b17268..17f745a9698 100644 --- a/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -7,6 +7,10 @@ "JsonSchema.shell": "指定命令是 shell 命令还是外部程åºã€‚如果çœç•¥ï¼Œé»˜è®¤å€¼æ˜¯ false。", "JsonSchema.tasks.dependsOn.string": "此任务ä¾èµ–çš„å¦ä¸€ä»»åŠ¡ã€‚", "JsonSchema.tasks.dependsOn.array": "此任务ä¾èµ–的其他任务。", + "JsonSchema.tasks.group": "定义此任务属于的执行组。如被çœç•¥ï¼Œåˆ™æ­¤ä»»åŠ¡ä¸å±žäºŽä»»ä½•ç»„。", + "JsonSchema.tasks.type": "定义任务是被作为进程è¿è¡Œè¿˜æ˜¯åœ¨ shell 中作为命令è¿è¡Œã€‚默认作为进程è¿è¡Œã€‚", + "JsonSchema.version": "é…置的版本å·ã€‚", + "JsonSchema.tasks.customize": "è¦è‡ªå®šä¹‰çš„æ供的视图。", "JsonSchema.windows": "Windows 特定的命令é…ç½®", "JsonSchema.mac": "Mac 特定的命令é…ç½®", "JsonSchema.linux": "Linux 特定的命令é…ç½®" diff --git a/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json b/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json index e8ff5a94c0b..5fc4616ea47 100644 --- a/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json @@ -22,7 +22,8 @@ "TaskService.noBuildTask": "未定义任何生æˆä»»åŠ¡ã€‚使用 \"isBuildCommand\" 在 tasks.json 文件中标记任务。", "TaskService.noTestTask": "未定义任何测试任务。使用 \"isTestCommand\" 在 tasks.json 文件中标记任务。", "TaskServer.noTask": "未找到è¦æ‰§è¡Œçš„请求任务 {0}。", - "TaskSystem.activeSame": "任务已处于活动状æ€å¹¶å¤„于监视模å¼ã€‚è‹¥è¦ç»ˆæ­¢ä»»åŠ¡ï¼Œè¯·ä½¿ç”¨ \"F1\" >“终止任务â€", + "customizeParseErrors": "当å‰ä»»åŠ¡é…置存在错误。请先更正错误,å†è‡ªå®šä¹‰ä»»åŠ¡ã€‚", + "moreThanOneBuildTask": "å½“å‰ tasks.json 中定义了多个生æˆä»»åŠ¡ã€‚正在执行第一个。\n", "TaskSystem.active": "当å‰å·²æœ‰ä»»åŠ¡æ­£åœ¨è¿è¡Œã€‚请先终止它,然åŽå†æ‰§è¡Œå¦ä¸€é¡¹ä»»åŠ¡ã€‚", "TaskSystem.restartFailed": "未能终止并é‡å¯ä»»åŠ¡ {0}", "TaskSystem.configurationErrors": "错误: æ供的任务é…置具有验è¯é”™è¯¯ï¼Œæ— æ³•ä½¿ç”¨ã€‚请首先改正错误。", @@ -43,5 +44,7 @@ "TestAction.label": "è¿è¡Œæµ‹è¯•ä»»åŠ¡", "quickOpen.task": "è¿è¡Œä»»åŠ¡", "quickOpen.terminateTask": "终止任务(&&T)", - "quickOpen.restartTask": "é‡å¯ä»»åŠ¡" + "quickOpen.restartTask": "é‡å¯ä»»åŠ¡", + "quickOpen.buildTask": "生æˆä»»åŠ¡", + "quickOpen.testTask": "测试任务" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json b/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json index f5f009904e1..007d5c51e4a 100644 --- a/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json @@ -6,6 +6,7 @@ { "TerminalTaskSystem.unknownError": "在执行任务时å‘生未知错误。请å‚è§ä»»åŠ¡è¾“出日志了解详细信æ¯ã€‚", "TerminalTaskSystem.terminalName": "任务 - {0}", + "reuseTerminal": "终端将被任务é‡ç”¨ï¼ŒæŒ‰ä»»æ„键关闭。", "TerminalTaskSystem": "无法对 UNC 驱动器执行 shell 命令。", "unkownProblemMatcher": "无法解æžé—®é¢˜åŒ¹é…ç¨‹åº {0}。此匹é…程åºå°†è¢«å¿½ç•¥" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json b/i18n/chs/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json index 3b09b277be3..c8746db7afb 100644 --- a/i18n/chs/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json @@ -8,6 +8,7 @@ "workbench.action.terminal.kill": "终止活动终端实例", "workbench.action.terminal.kill.short": "终止终端", "workbench.action.terminal.copySelection": "å¤åˆ¶æ‰€é€‰å†…容", + "workbench.action.terminal.selectAll": "全选", "workbench.action.terminal.new": "新建集æˆç»ˆç«¯", "workbench.action.terminal.new.short": "新的终端", "workbench.action.terminal.focus": "èšç„¦äºŽç»ˆç«¯", @@ -28,5 +29,9 @@ "workbench.action.terminal.scrollToTop": "滚动到顶部", "workbench.action.terminal.clear": "清除", "workbench.action.terminal.allowWorkspaceShell": "å…许é…置工作区 Shell", - "workbench.action.terminal.disallowWorkspaceShell": "ç¦æ­¢é…置工作区 Shell" + "workbench.action.terminal.disallowWorkspaceShell": "ç¦æ­¢é…置工作区 Shell", + "workbench.action.terminal.rename": "é‡å‘½å", + "workbench.action.terminal.rename.prompt": "输入终端å称", + "workbench.action.terminal.focusFindWidget": "èšç„¦äºŽæŸ¥æ‰¾å°ç»„件", + "workbench.action.terminal.hideFindWidget": "éšè—查找å°ç»„件" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json b/i18n/chs/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json new file mode 100644 index 00000000000..d650d2c5ce6 --- /dev/null +++ b/i18n/chs/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "label.find": "查找", + "placeholder.find": "查找", + "label.previousMatchButton": "上一个匹é…", + "label.nextMatchButton": "下一个匹é…", + "label.closeButton": "关闭" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json b/i18n/chs/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json index 968bdf8f6a5..c6e31e6ba8b 100644 --- a/i18n/chs/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json @@ -4,7 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "terminal.integrated.copySelection.noSelection": "当终端没有ä½äºŽç„¦ç‚¹æ—¶æ— æ³•å¤åˆ¶ç»ˆç«¯é€‰å®šå†…容", "terminal.integrated.exitedWithCode": "é€šè¿‡é€€å‡ºä»£ç  {0} 终止的终端进程", "terminal.integrated.waitOnExit": "按任æ„键以关闭终端", "terminal.integrated.launchFailed": "终端进程命令“{0} {1}â€æ— æ³•å¯åŠ¨(退出代ç : {2})" diff --git a/i18n/chs/src/vs/workbench/parts/update/electron-browser/update.i18n.json b/i18n/chs/src/vs/workbench/parts/update/electron-browser/update.i18n.json index 458a66e47a2..254f11cdeff 100644 --- a/i18n/chs/src/vs/workbench/parts/update/electron-browser/update.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/update/electron-browser/update.i18n.json @@ -15,5 +15,18 @@ "license": "读å–许å¯è¯", "updateAvailable": "{0} 将在é‡å¯åŽæ›´æ–°ã€‚", "thereIsUpdateAvailable": "存在å¯ç”¨æ›´æ–°ã€‚", - "noUpdatesAvailable": "当å‰æ²¡æœ‰å¯ç”¨çš„更新。" + "noUpdatesAvailable": "当å‰æ²¡æœ‰å¯ç”¨çš„更新。", + "updateIsReady": "有新更新å¯ç”¨ã€‚", + "commandPalette": "命令é¢æ¿...", + "settings": "设置", + "keyboardShortcuts": "键盘快æ·æ–¹å¼", + "selectTheme.label": "颜色主题", + "themes.selectIconTheme.label": "文件图标主题", + "not available": "æ›´æ–°ä¸å¯ç”¨", + "checkingForUpdates": "正在检查更新...", + "DownloadUpdate": "下载å¯ç”¨æ›´æ–°", + "DownloadingUpdate": "正在下载更新...", + "InstallingUpdate": "正在安装更新...", + "restartToUpdate": "é‡å¯ä»¥æ›´æ–°...", + "checkForUpdates": "检查更新..." } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/views/browser/views.i18n.json b/i18n/chs/src/vs/workbench/parts/views/browser/views.i18n.json new file mode 100644 index 00000000000..08ebcb29e96 --- /dev/null +++ b/i18n/chs/src/vs/workbench/parts/views/browser/views.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "viewToolbarAriaLabel": "{0} æ“作" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json b/i18n/chs/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json new file mode 100644 index 00000000000..c013ce2e6be --- /dev/null +++ b/i18n/chs/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "requirearray": "视图必须为数组", + "requirestring": "属性“{0}â€æ˜¯å¿…需的,其类型必须是“stringâ€", + "optstring": "属性“{0}â€å¯ä»¥çœç•¥ï¼Œå¦åˆ™å…¶ç±»åž‹å¿…须是 \"string\"", + "vscode.extension.contributes.view.id": "视图的标识符。使用标识符通过“vscode.window.registerTreeDataProviderForView†API 注册数æ®æ供程åºã€‚åŒæ—¶å°†â€œonView:${id}â€äº‹ä»¶æ³¨å†Œåˆ°â€œactivationEventsâ€ä»¥æ¿€æ´»ä½ çš„扩展。", + "vscode.extension.contributes.view.name": "人类å¯è¯»çš„视图å称。将会被显示", + "vscode.extension.contributes.views": "å‘编辑器æ供视图", + "views.explorer": "资æºç®¡ç†å™¨è§†å›¾", + "locationId.invalid": "“{0}â€ä¸ºæ— æ•ˆè§†å›¾ä½ç½®" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json index 3503db3576a..efc4346e634 100644 --- a/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -31,7 +31,6 @@ "welcomePage.colorThemeDescription": "使编辑器和代ç å‘ˆçŽ°ä½ å–œæ¬¢çš„外观", "welcomePage.learn": "学习", "welcomePage.showCommands": "查找并è¿è¡Œæ‰€æœ‰å‘½ä»¤", - "welcomePage.showCommandsDescription": "从控制é¢æ¿å¿«é€Ÿè®¿é—®å¹¶æœç´¢å‘½ä»¤({0})", "welcomePage.interfaceOverview": "ç•Œé¢æ¦‚è¿°", "welcomePage.interfaceOverviewDescription": "查看çªå‡ºæ˜¾ç¤ºä¸»è¦ UI 组件的å åŠ å›¾", "welcomePage.interactivePlayground": "交互å¼æ¼”练场", diff --git a/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json b/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json index 9df0fba8587..f98f5d0208e 100644 --- a/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json @@ -4,7 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "workbenchConfigurationTitle": "工作å°", - "welcomePage.enabled": "å¯ç”¨åŽï¼Œå°†åœ¨å¯åŠ¨æ—¶æ˜¾ç¤ºæ¬¢è¿Žé¡µã€‚", "help": "帮助" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 495283f621e..6180f4d0d5b 100644 --- a/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/chs/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -4,6 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "workbenchConfigurationTitle": "工作å°", + "welcomePage.enabled": "å¯ç”¨åŽï¼Œå°†åœ¨å¯åŠ¨æ—¶æ˜¾ç¤ºæ¬¢è¿Žé¡µã€‚", "welcomePage": "欢迎使用", "welcomePage.javaScript": "JavaScript", "welcomePage.typeScript": "TypeScript", @@ -14,16 +16,23 @@ "welcomePage.sublime": "Sublime", "welcomePage.atom": "Atom", "welcomePage.extensionPackAlreadyInstalled": "已安装对 {0} 的支æŒã€‚", - "welcomePage.willReloadAfterInstallingExtensionPack": "安装对 {0} 的支æŒåŽï¼Œå°†é‡è½½çª—å£ã€‚", - "welcomePage.installingExtensionPack": "正在安装对 {0} 的支æŒ...", + "welcomePage.willReloadAfterInstallingExtensionPack": "安装对 {0} çš„é¢å¤–支æŒåŽï¼Œå°†é‡è½½çª—å£ã€‚", + "welcomePage.installingExtensionPack": "正在安装对 {0} çš„é¢å¤–支æŒ...", "welcomePage.extensionPackNotFound": "找ä¸åˆ°å¯¹ {0} (ID: {1}) 的支æŒã€‚", "welcomePage.keymapAlreadyInstalled": "已安装 {0} 键盘快æ·æ–¹å¼ã€‚", "welcomePage.willReloadAfterInstallingKeymap": "安装 {0} 键盘快æ·æ–¹å¼åŽï¼Œå°†é‡è½½çª—å£ã€‚", "welcomePage.installingKeymap": "正在安装 {0} 键盘快æ·æ–¹å¼...", "welcomePage.keymapNotFound": "找ä¸åˆ° ID 为 {1} çš„ {0} 键盘快æ·æ–¹å¼ã€‚", "welcome.title": "欢迎使用", + "welcomePage.openFolderWithPath": "打开路径为 {1} 的文件夹 {0}", "welcomePage.extensionListSeparator": "ã€", - "welcomePage.installedExtension": "{0}(已安装)", + "welcomePage.installKeymap": "安装 {0} 键映射", + "welcomePage.installExtensionPack": "安装对 {0} çš„é¢å¤–支æŒ", + "welcomePage.installedKeymap": "已安装 {0} 键映射", + "welcomePage.installedExtensionPack": "已安装 {0} 支æŒ", "ok": "确定", - "cancel": "å–消" + "details": "详细信æ¯", + "cancel": "å–消", + "welcomePage.buttonBackground": "欢迎页按钮的背景色。", + "welcomePage.buttonHoverBackground": "欢迎页按钮被悬åœæ—¶çš„背景色。" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json b/i18n/chs/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json new file mode 100644 index 00000000000..0581515bc92 --- /dev/null +++ b/i18n/chs/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "telemetryConfigurationTitle": "é¥æµ‹", + "telemetry.enableCrashReporting": "å¯ç”¨è¦å‘é€ç»™ Microsoft 的故障报表。\n此选项需é‡å¯æ‰å¯ç”Ÿæ•ˆã€‚" +} \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/services/keybinding/electron-browser/keybindingService.i18n.json b/i18n/chs/src/vs/workbench/services/keybinding/electron-browser/keybindingService.i18n.json index 162baf8c31f..4d434e9c4c9 100644 --- a/i18n/chs/src/vs/workbench/services/keybinding/electron-browser/keybindingService.i18n.json +++ b/i18n/chs/src/vs/workbench/services/keybinding/electron-browser/keybindingService.i18n.json @@ -22,5 +22,5 @@ "keybindings.json.when": "键处于活动状æ€æ—¶çš„æ¡ä»¶ã€‚", "keybindings.json.args": "è¦ä¼ é€’给命令以执行的å‚数。", "keyboardConfigurationTitle": "键盘", - "dispatch": "控制按键的分派逻辑以使用 \"keydown.code\" (推è)或 \"eydown.keyCode\"。" + "dispatch": "控制按键的调度逻辑以使用“keydown.codeâ€(推è) 或“keydown.keyCodeâ€ã€‚" } \ No newline at end of file diff --git a/i18n/chs/src/vs/workbench/services/progress/browser/progressService2.i18n.json b/i18n/chs/src/vs/workbench/services/progress/browser/progressService2.i18n.json new file mode 100644 index 00000000000..6db7d6aae51 --- /dev/null +++ b/i18n/chs/src/vs/workbench/services/progress/browser/progressService2.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "progress.text": "{0} - {1}", + "progress.title": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/cht/extensions/git/out/commands.i18n.json b/i18n/cht/extensions/git/out/commands.i18n.json index 849277aa8fe..ccc4f6c757a 100644 --- a/i18n/cht/extensions/git/out/commands.i18n.json +++ b/i18n/cht/extensions/git/out/commands.i18n.json @@ -26,6 +26,9 @@ "provide commit message": "è«‹æä¾›èªå¯è¨Šæ¯", "branch name": "分支å稱", "provide branch name": "è«‹æ供分支å稱", + "select branch to delete": "é¸æ“‡åˆ†æ”¯é€²è¡Œåˆªé™¤", + "confirm force delete branch": "分支 '{0}' 尚未完整åˆä½µ. 確定刪除嗎?", + "delete branch": "刪除分支", "no remotes to pull": "您的存放庫未設定è¦æå–的來æºé ç«¯ã€‚", "no remotes to push": "您的存放庫未設定è¦æŽ¨é€çš„目標é ç«¯ã€‚", "nobranch": "請簽出分支以推é€åˆ°é ç«¯ã€‚", diff --git a/i18n/cht/extensions/git/out/scmProvider.i18n.json b/i18n/cht/extensions/git/out/scmProvider.i18n.json index 7fded37328a..e71dab52f4e 100644 --- a/i18n/cht/extensions/git/out/scmProvider.i18n.json +++ b/i18n/cht/extensions/git/out/scmProvider.i18n.json @@ -4,5 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "commit": "Commit" + "commit": "èªå¯" } \ No newline at end of file diff --git a/i18n/cht/extensions/git/package.i18n.json b/i18n/cht/extensions/git/package.i18n.json index 63f725ec183..725f33d871a 100644 --- a/i18n/cht/extensions/git/package.i18n.json +++ b/i18n/cht/extensions/git/package.i18n.json @@ -26,12 +26,13 @@ "command.undoCommit": "復原上次èªå¯", "command.checkout": "簽出至...", "command.branch": "建立分支...", + "command.deleteBranch": "刪除分支...", "command.pull": "æå–", "command.pullRebase": "æå– (é‡è¨‚基底)", "command.push": "推é€", "command.pushTo": "推é€è‡³...", "command.sync": "åŒæ­¥è™•ç†", - "command.publish": "發行", + "command.publish": "發行分支", "command.showOutput": "顯示 Git 輸出", "config.enabled": "是å¦å•Ÿç”¨ GIT", "config.path": "Git å¯åŸ·è¡Œæª”的路徑", diff --git a/i18n/cht/extensions/jake/out/main.i18n.json b/i18n/cht/extensions/jake/out/main.i18n.json index 8b6ad71cd4e..f85adc82182 100644 --- a/i18n/cht/extensions/jake/out/main.i18n.json +++ b/i18n/cht/extensions/jake/out/main.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "execFailed": "Jake 的自動åµæ¸¬å¤±æ•—。錯誤: {0}" +} \ No newline at end of file diff --git a/i18n/cht/extensions/jake/package.i18n.json b/i18n/cht/extensions/jake/package.i18n.json index 8b6ad71cd4e..ee533577d07 100644 --- a/i18n/cht/extensions/jake/package.i18n.json +++ b/i18n/cht/extensions/jake/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.jake.autoDetect": "控制 Jake 工作的自動åµæ¸¬ç‚ºé–‹å•Ÿæˆ–關閉。é è¨­ç‚ºé–‹ã€‚" +} \ No newline at end of file diff --git a/i18n/cht/extensions/markdown/out/extension.i18n.json b/i18n/cht/extensions/markdown/out/extension.i18n.json index 8b6ad71cd4e..f8b580fc8f0 100644 --- a/i18n/cht/extensions/markdown/out/extension.i18n.json +++ b/i18n/cht/extensions/markdown/out/extension.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "onPreviewStyleLoadError": "無法載入 ‘markdown.style' 樣å¼:{0}" +} \ No newline at end of file diff --git a/i18n/cht/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/cht/extensions/merge-conflict/out/codelensProvider.i18n.json index 8b6ad71cd4e..fd3fc4ee512 100644 --- a/i18n/cht/extensions/merge-conflict/out/codelensProvider.i18n.json +++ b/i18n/cht/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -3,4 +3,9 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "acceptCurrentChange": "接å—當å‰è®Šæ›´", + "acceptIncomingChange": "接å—來æºè®Šæ›´", + "acceptBothChanges": "接å—兩者變更", + "compareChanges": "比較變更" +} \ No newline at end of file diff --git a/i18n/cht/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/cht/extensions/merge-conflict/out/commandHandler.i18n.json index fe300c53427..a82efe04f8a 100644 --- a/i18n/cht/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/cht/extensions/merge-conflict/out/commandHandler.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "cursorNotInConflict": "編輯器游標ä¸åœ¨è¡çªåˆä½µç¯„åœä¹‹å…§", + "compareChangesTitle": "{0}: 當å‰è®Šæ›´âŸ·ä¾†æºè®Šæ›´", "cursorOnSplitterRange": "編輯器游標在è¡çªåˆä½µå·¥å…·ç¯„åœå…§,請移動至\"當å‰é …ç›®\"或來æºé …ç›®\"å€å¡Š", "noConflicts": "檔案內找ä¸åˆ°éœ€è¦åˆä½µè¡çªé …ç›®", "noOtherConflictsInThisFile": "此檔案內沒有其他的è¡çªåˆä½µé …ç›®" diff --git a/i18n/cht/extensions/merge-conflict/package.i18n.json b/i18n/cht/extensions/merge-conflict/package.i18n.json index 8546878e4e4..21711a0ff32 100644 --- a/i18n/cht/extensions/merge-conflict/package.i18n.json +++ b/i18n/cht/extensions/merge-conflict/package.i18n.json @@ -5,7 +5,15 @@ // Do not edit this file. It is machine generated. { "command.category": "åˆä½µè¡çª", + "command.accept.all-incoming": "接å—所有來æº", + "command.accept.all-both": "接å—兩者所有項目", + "command.accept.current": "接å—當å‰é …ç›®", + "command.accept.incoming": "接å—來æºé …ç›®", + "command.accept.selection": "接å—é¸å–é …ç›®", "command.accept.both": "接å—兩者", + "command.next": "下一個è¡çª", + "command.previous": "å‰ä¸€å€‹è¡çª", + "command.compare": "比較目å‰è¡çª", "config.title": "åˆä½µè¡çª", "config.codeLensEnabled": "啟用/åœç”¨ 編輯器CodeLensè¡çªåˆä½µ ", "config.decoratorsEnabled": "啟用/åœç”¨ 編輯器è¡çªåˆä½µè‰²å½©è£é£¾" diff --git a/i18n/cht/extensions/typescript/out/features/bufferSyncSupport.i18n.json b/i18n/cht/extensions/typescript/out/features/bufferSyncSupport.i18n.json index 94c3eb2b5b9..8d73858cf4f 100644 --- a/i18n/cht/extensions/typescript/out/features/bufferSyncSupport.i18n.json +++ b/i18n/cht/extensions/typescript/out/features/bufferSyncSupport.i18n.json @@ -4,7 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "versionMismatch": "版本ä¸ç¬¦! 全域 TSC ({0}) != VS Code 的語言æœå‹™ ({1})。å¯èƒ½æœƒç™¼ç”Ÿç·¨è­¯ä¸ä¸€è‡´çš„錯誤", "moreInformation": "詳細資訊", "doNotCheckAgain": "ä¸è¦å†æª¢æŸ¥", "close": "關閉", diff --git a/i18n/cht/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json b/i18n/cht/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json index 8b6ad71cd4e..19b6338186e 100644 --- a/i18n/cht/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json +++ b/i18n/cht/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "ts-check": "啟用 JavaScript 檔案的語æ„檢查。必須在檔案的最上é¢ã€‚", + "ts-nocheck": "åœç”¨ JavaScript 檔案的語æ„檢查。必須在檔案的最上é¢ã€‚", + "ts-ignore": "éš±è—下一行@ts-check 的錯誤警告。" +} \ No newline at end of file diff --git a/i18n/cht/extensions/typescript/out/utils/projectStatus.i18n.json b/i18n/cht/extensions/typescript/out/utils/projectStatus.i18n.json index bfe9d8300ec..3c39220ae53 100644 --- a/i18n/cht/extensions/typescript/out/utils/projectStatus.i18n.json +++ b/i18n/cht/extensions/typescript/out/utils/projectStatus.i18n.json @@ -6,7 +6,6 @@ { "hintExclude": "è‹¥è¦è®“整個專案都能使用 JavaScript/TypeScript 語言功能,請排除內å«è¨±å¤šæª”案的資料夾,例如: {0}", "hintExclude.generic": "è‹¥è¦è®“整個專案都能使用 JavaScript/TypeScript 語言功能,請排除內å«æ‚¨æœªä½¿ç”¨ä¹‹ä¾†æºæª”案的大型資料夾。", - "open": "設定排除項目", "large.label": "設定排除項目", "hintExclude.tooltip": "è‹¥è¦è®“整個專案都能使用 JavaScript/TypeScript 語言功能,請排除內å«æ‚¨æœªä½¿ç”¨ä¹‹ä¾†æºæª”案的大型資料夾。" } \ No newline at end of file diff --git a/i18n/cht/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/cht/extensions/typescript/out/utils/typingsStatus.i18n.json index 4f15ff5fc04..d487fd639bc 100644 --- a/i18n/cht/extensions/typescript/out/utils/typingsStatus.i18n.json +++ b/i18n/cht/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "installingPackages": "正在擷å–資料以改善 TypeScript IntelliSense", + "typesInstallerInitializationFailed.title": "無法安è£typings檔案Javascript語言功能,請確èªNPM是å¦å·²å®‰è£ä¸”é…ç½®'typescript.npm'", "typesInstallerInitializationFailed.moreInformation": "詳細資訊", "typesInstallerInitializationFailed.doNotCheckAgain": "ä¸è¦å†æª¢æŸ¥", "typesInstallerInitializationFailed.close": "關閉" diff --git a/i18n/cht/extensions/typescript/package.i18n.json b/i18n/cht/extensions/typescript/package.i18n.json index a9e009d33a4..349b5b03215 100644 --- a/i18n/cht/extensions/typescript/package.i18n.json +++ b/i18n/cht/extensions/typescript/package.i18n.json @@ -13,7 +13,6 @@ "typescript.check.tscVersion": "è«‹æª¢æŸ¥å…¨åŸŸå®‰è£ TypeScript 編譯器 (例如 tsc) 是å¦ä¸åŒæ–¼ä½¿ç”¨çš„ TypeScript 語言æœå‹™ã€‚", "typescript.tsserver.log": "å…許 TS 伺æœå™¨è¨˜éŒ„到檔案。此記錄å¯ç”¨ä¾†è¨ºæ–· TS 伺æœå™¨å•é¡Œã€‚記錄å¯èƒ½åŒ…å«æª”案路徑ã€åŽŸå§‹ç¨‹å¼ç¢¼åŠæ‚¨å°ˆæ¡ˆä¸­å¯èƒ½å…·æœ‰æ•æ„Ÿæ€§çš„其他資訊。", "typescript.tsserver.trace": "å…許將訊æ¯è¿½è¹¤å‚³é€åˆ° TS 伺æœå™¨ã€‚此追蹤å¯ç”¨ä¾†è¨ºæ–· TS 伺æœå™¨å•é¡Œã€‚追蹤å¯èƒ½åŒ…å«æª”案路徑ã€åŽŸå§‹ç¨‹å¼ç¢¼åŠæ‚¨å°ˆæ¡ˆä¸­å¯èƒ½å…·æœ‰æ•æ„Ÿæ€§çš„其他資訊。", - "typescript.tsserver.experimentalAutoBuild": "å•Ÿç”¨å¯¦é©—æ€§è‡ªå‹•å»ºç½®ã€‚éœ€è¦ 1.9 dev 或 2.x tsserver 版本,且在變更後必須é‡æ–°å•Ÿå‹• VS Code。", "typescript.validate.enable": "啟用/åœç”¨ TypeScript 驗證。", "typescript.format.enable": "啟用/åœç”¨é è¨­ TypeScript æ ¼å¼å™¨ã€‚", "javascript.format.enable": "啟用/åœç”¨é è¨­ JavaScript æ ¼å¼å™¨ã€‚", @@ -41,5 +40,8 @@ "typescript.selectTypeScriptVersion.title": "é¸å– TypeScript 版本", "jsDocCompletion.enabled": "啟用/åœç”¨è‡ªå‹• JSDoc 註解", "javascript.implicitProjectConfig.checkJs": "啟用/åœç”¨ JavaScript 檔案的語æ„檢查。ç¾æœ‰çš„ jsconfig.json 或 tsconfig.json æª”æ¡ˆæœƒè¦†å¯«æ­¤è¨­å®šã€‚éœ€è¦ TypeScript >=2.3.1。", - "javascript.nameSuggestions": "從JavaScript推薦表檔案中啟用/åœç”¨åŒ…å«å”¯ä¸€æª”å" + "typescript.npm": "指定用於自動類型å–å¾—çš„ NPM å¯åŸ·è¡Œæª”路徑。TypeScript å¿…é ˆ >= 2.3.4.", + "typescript.check.npmIsInstalled": "檢查是å¦å·²å®‰è£NPM用以å–得自動類型擷å–.", + "javascript.nameSuggestions": "從JavaScript推薦表檔案中啟用/åœç”¨åŒ…å«å”¯ä¸€æª”å", + "typescript.tsc.autoDetect": "控制 tsc 工作的自動åµæ¸¬ç‚ºé–‹å•Ÿæˆ–關閉。" } \ No newline at end of file diff --git a/i18n/cht/src/vs/base/common/errorMessage.i18n.json b/i18n/cht/src/vs/base/common/errorMessage.i18n.json index 0ff1888b74e..693f35b5cc0 100644 --- a/i18n/cht/src/vs/base/common/errorMessage.i18n.json +++ b/i18n/cht/src/vs/base/common/errorMessage.i18n.json @@ -13,6 +13,5 @@ "error.connection.unknown": "發生未知的連接錯誤。å¯èƒ½æ˜¯æ‚¨å·²ç¶“沒有連線到網際網路,或是您連接的伺æœå™¨å·²é›¢ç·šã€‚", "stackTrace.format": "{0}: {1}", "error.defaultMessage": "發生未知的錯誤。如需詳細資訊,請åƒé–±è¨˜éŒ„檔。", - "nodeExceptionMessage": "發生系統錯誤 ({0})", "error.moreErrors": "{0} (總計 {1} 個錯誤)" } \ No newline at end of file diff --git a/i18n/cht/src/vs/base/common/jsonErrorMessages.i18n.json b/i18n/cht/src/vs/base/common/jsonErrorMessages.i18n.json index a131a45e657..5259c9207ad 100644 --- a/i18n/cht/src/vs/base/common/jsonErrorMessages.i18n.json +++ b/i18n/cht/src/vs/base/common/jsonErrorMessages.i18n.json @@ -4,13 +4,13 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "error.invalidSymbol": "符號無效", - "error.invalidNumberFormat": "數字格å¼ç„¡æ•ˆ", - "error.propertyNameExpected": "必須有屬性å稱", + "error.invalidSymbol": "無效符號", + "error.invalidNumberFormat": "無效的數字格å¼", + "error.propertyNameExpected": "須有屬性å稱", "error.valueExpected": "必須有值", - "error.colonExpected": "必須為冒號", - "error.commaExpected": "必須為逗號", + "error.colonExpected": "必須有冒號", + "error.commaExpected": "必須有逗號", "error.closeBraceExpected": "必須為å³å¤§æ‹¬è™Ÿ", "error.closeBracketExpected": "必須為å³ä¸­æ‹¬è™Ÿ", - "error.endOfFileExpected": "必須為檔案çµå°¾" + "error.endOfFileExpected": "必須有檔案çµå°¾" } \ No newline at end of file diff --git a/i18n/cht/src/vs/base/common/keybindingLabels.i18n.json b/i18n/cht/src/vs/base/common/keybindingLabels.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/cht/src/vs/base/common/keybindingLabels.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/cht/src/vs/code/electron-main/menus.i18n.json b/i18n/cht/src/vs/code/electron-main/menus.i18n.json index 6d87a7b4902..097fbdb7250 100644 --- a/i18n/cht/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/cht/src/vs/code/electron-main/menus.i18n.json @@ -55,6 +55,9 @@ "miShowEmmetCommands": "Emmet(&&M)...", "miToggleLineComment": "切æ›è¡Œè¨»è§£(&&T)", "miToggleBlockComment": "切æ›å€å¡Šè¨»è§£(&&B)", + "miMultiCursorAlt": "é€éŽ Alt+ 按一下啟用多é‡æ¸¸æ¨™", + "miMultiCursorCmd": "é€éŽ Cmdt+ 按一下啟用多é‡æ¸¸æ¨™", + "miMultiCursorCtrl": "é€éŽ Ctrl+ 按一下啟用多é‡æ¸¸æ¨™", "miInsertCursorAbove": "在上方新增游標(&&A)", "miInsertCursorBelow": "在下方新增游標(&&D)", "miInsertCursorAtEndOfEachLineSelected": "在行尾新增游標(&&U)", @@ -70,6 +73,7 @@ "miSmartSelectShrink": "壓縮é¸å–範åœ(&&S)", "miViewExplorer": "檔案總管(&&E)", "miViewSearch": "æœå°‹(&&S)", + "miViewSCM": "SCM", "miViewDebug": "åµéŒ¯ (&&D)", "miViewExtensions": "擴充功能(&&X)", "miToggleOutput": "輸出(&&O)", @@ -114,6 +118,8 @@ "miGotoSymbolInFile": "å‰å¾€æª”案中的符號(&&S)...", "miGotoSymbolInWorkspace": "å‰å¾€å·¥ä½œå€ä¸­çš„符號(&&W)...", "miGotoDefinition": "移至定義(&&D)", + "miGotoTypeDefinition": "移至類型定義(&&T)", + "miGotoImplementation": "å‰å¾€å¯¦ä½œ(&&I)", "miGotoLine": "移至行(&&L)...", "miStartDebugging": "å•Ÿå‹•åµéŒ¯(&&S)", "miStartWithoutDebugging": "åªå•Ÿå‹•ä½†ä¸åµéŒ¯(&&W)", @@ -130,16 +136,17 @@ "miColumnBreakpoint": "資料行中斷點(&&O)", "miFunctionBreakpoint": "函å¼ä¸­æ–·é»ž(&&F}...", "miNewBreakpoint": "新增中斷點(&&N)", + "miEnableAllBreakpoints": "啟用所有中斷點", "miDisableAllBreakpoints": "åœç”¨æ‰€æœ‰ä¸­æ–·é»ž(&&L)", "miRemoveAllBreakpoints": "移除所有中斷點(&&R)", "miInstallAdditionalDebuggers": "安è£å…¶ä»–åµéŒ¯å·¥å…·(&&I)...", "mMinimize": "最å°åŒ–", - "mClose": "關閉", "mBringToFront": "全部æ到最上層", "miToggleDevTools": "切æ›é–‹ç™¼äººå“¡å·¥å…·(&&T)", "miAccessibilityOptions": "å”助工具é¸é …(&&O)", "miReportIssues": "回報å•é¡Œ(&&I)", "miWelcome": "歡迎使用(&&W)", + "miInteractivePlayground": "Interactive Playground(&&I)", "miDocumentation": "文件(&&D)", "miReleaseNotes": "版本資訊(&&R)", "miKeyboardShortcuts": "éµç›¤å¿«é€Ÿéµåƒè€ƒ(&&K)", @@ -149,12 +156,14 @@ "miLicense": "檢視授權(&&L)", "miPrivacyStatement": "éš±ç§æ¬Šè²æ˜Ž(&&P)", "miAbout": "關於(&&A)", + "miTerminateTask": "終止工作(&&T)", "accessibilityOptionsWindowTitle": "å”助工具é¸é …", "miRestartToUpdate": "é‡æ–°å•Ÿå‹•ä»¥æ›´æ–°...", "miCheckingForUpdates": "正在查看是å¦æœ‰æ›´æ–°...", "miDownloadUpdate": "下載å¯ç”¨æ›´æ–°", "miDownloadingUpdate": "正在下載更新...", "miInstallingUpdate": "正在安è£æ›´æ–°...", + "miCheckForUpdates": "查看是å¦æœ‰æ›´æ–°", "aboutDetail": "\n版本 {0}\nèªå¯ {1}\n日期 {2}\nShell {3}\n轉譯器 {4}\nNode {5}", "okButton": "確定" } \ No newline at end of file diff --git a/i18n/cht/src/vs/code/electron-main/windows.i18n.json b/i18n/cht/src/vs/code/electron-main/windows.i18n.json index 08847b4b8e4..fe29d0fb035 100644 --- a/i18n/cht/src/vs/code/electron-main/windows.i18n.json +++ b/i18n/cht/src/vs/code/electron-main/windows.i18n.json @@ -13,9 +13,5 @@ "appStalled": "視窗已沒有回應", "appStalledDetail": "您å¯ä»¥é‡æ–°é–‹å•Ÿæˆ–關閉視窗,或是繼續等候。", "appCrashed": "視窗已æ毀", - "appCrashedDetail": "很抱歉造æˆæ‚¨çš„ä¸ä¾¿! 您å¯ä»¥é‡æ–°é–‹å•Ÿè¦–窗,從您離開的地方繼續進行。", - "newWindow": "開新視窗", - "newWindowDesc": "開啟新視窗", - "recentFolders": "最近使用的資料夾", - "folderDesc": "{0} {1}" + "appCrashedDetail": "很抱歉造æˆæ‚¨çš„ä¸ä¾¿! 您å¯ä»¥é‡æ–°é–‹å•Ÿè¦–窗,從您離開的地方繼續進行。" } \ No newline at end of file diff --git a/i18n/cht/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/cht/src/vs/editor/common/config/commonEditorConfig.i18n.json index f1f6f5fa235..23812d4eed8 100644 --- a/i18n/cht/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/cht/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -23,6 +23,8 @@ "minimap.enabled": "控制是å¦æœƒé¡¯ç¤ºè¿·ä½ åœ°åœ–", "minimap.renderCharacters": "呈ç¾è¡Œå…§çš„實際字元 (而ä¸æ˜¯å½©è‰²å€å¡Š)", "minimap.maxColumn": "é™åˆ¶è¿·ä½ åœ°åœ–的寬度,以呈ç¾æœ€å¤šçš„資料行", + "find.seedSearchStringFromSelection": "控制編譯器é¸å–範åœæ˜¯å¦é è¨­ç‚ºå°‹æ‰¾å·¥å…·çš„æœå°‹å­—串", + "find.autoFindInSelection": "控制編譯器內é¸å–多字元或多行內文是å¦é–‹å•Ÿé¸å–範åœå°‹æ‰¾åŠŸèƒ½", "wordWrap.off": "一律ä¸æ›è¡Œã€‚", "wordWrap.on": "ä¾æª¢è¦–å€å¯¬åº¦æ›è¡Œã€‚", "wordWrap.wordWrapColumn": "æ–¼ 'editor.wordWrapColumn' æ›è¡Œã€‚", @@ -31,16 +33,19 @@ "wordWrapColumn": "當 `editor.wordWrap` 為 [wordWrapColumn] 或 [bounded] 時,控制編輯器中的資料行æ›è¡Œã€‚", "wrappingIndent": "控制æ›è¡Œçš„縮排。å¯ä»¥æ˜¯ [ç„¡]ã€[相åŒ] 或 [縮排]。", "mouseWheelScrollSensitivity": "滑鼠滾輪æ²å‹•äº‹ä»¶çš„ 'deltaX' 與 'deltaY' 所使用的乘數", + "multiCursorModifier.ctrlCmd": "å°æ‡‰Windowså’ŒLinuxçš„'Control'與å°æ‡‰OSXçš„'Command'", + "multiCursorModifier.alt": "å°æ‡‰Windowså’ŒLinuxçš„'Alt'與å°æ‡‰OSXçš„'Option'", + "multiCursorModifier": "用於新增多個滑鼠游標的修改程å¼ã€‚`ctrlCmd` 會å°æ‡‰åˆ° Windows åŠ Linux 上的 `Control` ä»¥åŠ OSX 上的 `Command`。[移至定義] åŠ [開啟連çµ] 滑鼠手勢將會é©æ‡‰ä»¥é¿å…å’Œ multicursor 修改程å¼è¡çªã€‚", "quickSuggestions.strings": "å…許在字串內顯示å³æ™‚建議。", "quickSuggestions.comments": "å…許在註解中顯示å³æ™‚建議。", "quickSuggestions.other": "å…許在字串與註解以外之處顯示å³æ™‚建議。", "quickSuggestions": "控制是å¦æ‡‰åœ¨è¼¸å…¥æ™‚自動顯示建議", "quickSuggestionsDelay": "控制延é²é¡¯ç¤ºå¿«é€Ÿå»ºè­°çš„毫秒數", - "parameterHints": "啟用åƒæ•¸æ示", "autoClosingBrackets": "控制編輯器是å¦æ‡‰åœ¨å·¦æ‹¬è™Ÿå¾Œè‡ªå‹•æ’å…¥å³æ‹¬è™Ÿ", "formatOnType": "控制編輯器是å¦æ‡‰åœ¨è¼¸å…¥ä¸€è¡Œå¾Œè‡ªå‹•æ ¼å¼åŒ–", "formatOnPaste": "控制編輯器是å¦æ‡‰è‡ªå‹•è¨­å®šè²¼ä¸Šçš„內容格å¼ã€‚æ ¼å¼å™¨å¿…é ˆå¯ä¾›ä½¿ç”¨ï¼Œè€Œä¸”æ ¼å¼å™¨æ‡‰è©²èƒ½å¤ è¨­å®šæ–‡ä»¶ä¸­ä¸€å€‹ç¯„åœçš„æ ¼å¼ã€‚", "suggestOnTriggerCharacters": "控制輸入觸發字元時,是å¦æ‡‰è‡ªå‹•é¡¯ç¤ºå»ºè­°", + "acceptSuggestionOnEnter": "控制除了 'Tab' 外,是å¦ä¹Ÿè—‰ç”±æŒ‰ä¸‹ 'Enter' 接å—建議。如此å¯é¿å…æ··æ·†è¦æ’入新行或接å—建議。設定值'smart'表示在文字變更åŒæ™‚,åªé€éŽEnter接å—建議。", "acceptSuggestionOnCommitCharacter": "控制èªå¯å­—元是å¦æ‡‰æŽ¥å—建議。例如在 JavaScript 中,分號 (';') å¯ä»¥æ˜¯æŽ¥å—建議並éµå…¥è©²å­—元的èªå¯å­—元。", "snippetSuggestions": "控制程å¼ç¢¼ç‰‡æ®µæ˜¯å¦éš¨å…¶ä»–建議顯示,以åŠå…¶æŽ’åºæ–¹å¼ã€‚", "emptySelectionClipboard": "控制複製時ä¸é¸å–任何項目是å¦æœƒè¤‡è£½ç›®å‰ç¨‹å¼è¡Œã€‚", @@ -62,12 +67,17 @@ "renderLineHighlight": "控制編輯器應如何轉譯目å‰å白的行,å¯èƒ½çš„值有 'none'ã€'gutter'ã€'line' å’Œ 'all'。", "codeLens": "控制編輯器是å¦é¡¯ç¤ºç¨‹å¼ç¢¼æ¿¾é¡", "folding": "控制編輯器是å¦å·²å•Ÿç”¨ç¨‹å¼ç¢¼æ‘ºç–ŠåŠŸèƒ½", + "showFoldingControls": "自動隱è—摺疊控制å‘", "matchBrackets": "當é¸å–æŸå´çš„括號時,強調顯示å¦ä¸€å´çš„é…å°æ‹¬è™Ÿã€‚", "glyphMargin": "控制編輯器是å¦æ‡‰è½‰è­¯åž‚直字符邊界。字符邊界最常用來進行åµéŒ¯ã€‚", "useTabStops": "æ’入和刪除接在定ä½åœé§é»žå¾Œçš„空白字元", "trimAutoWhitespace": "移除尾端自動æ’入的空白字元", "stablePeek": "讓é è¦½ç·¨è¼¯å™¨åœ¨ä½¿ç”¨è€…按兩下其內容或點擊 Escape 時ä¿æŒé–‹å•Ÿã€‚", "dragAndDrop": "控制編輯器是å¦å…許é€éŽæ‹–放動作移動é¸å–範åœã€‚", + "accessibilitySupport.auto": "ç·¨è¼¯å™¨å°‡ä½¿ç”¨å¹³å° API 以åµæ¸¬èž¢å¹•åŠ©è®€ç¨‹å¼é™„加。", + "accessibilitySupport.on": "編輯器將會為螢幕助讀程å¼çš„使用方å¼æ°¸ä¹…地最佳化。", + "accessibilitySupport.off": "編輯器ä¸æœƒç‚ºèž¢å¹•åŠ©è®€ç¨‹å¼çš„使用方å¼é€²è¡Œæœ€ä½³åŒ–。", + "accessibilitySupport": "控制編輯器是å¦æ‡‰æ–¼å·²ç‚ºèž¢å¹•åŠ©è®€ç¨‹å¼æœ€ä½³åŒ–的模å¼ä¸­åŸ·è¡Œã€‚", "sideBySide": "控制 Diff 編輯器è¦ä¸¦æŽ’或內嵌顯示差異", "ignoreTrimWhitespace": "控制 Diff 編輯器是å¦å°‡é–‹é ­æˆ–尾端空白字元的變更顯示為差異", "renderIndicators": "控制 Diff 編輯器是å¦è¦ç‚ºæ–°å¢žçš„/移除的變更顯示 +/- 標記", diff --git a/i18n/cht/src/vs/editor/common/config/editorOptions.i18n.json b/i18n/cht/src/vs/editor/common/config/editorOptions.i18n.json index f48289922ad..7d0a6fdde24 100644 --- a/i18n/cht/src/vs/editor/common/config/editorOptions.i18n.json +++ b/i18n/cht/src/vs/editor/common/config/editorOptions.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "accessibilityOffAriaLabel": "編輯器ç¾åœ¨ç„¡æ³•å­˜å–。按Alt+F1尋求é¸é …", "editorViewAccessibleLabel": "編輯器內容" } \ No newline at end of file diff --git a/i18n/cht/src/vs/editor/contrib/find/common/findController.i18n.json b/i18n/cht/src/vs/editor/contrib/find/common/findController.i18n.json index 29657be9ff8..515b3974962 100644 --- a/i18n/cht/src/vs/editor/contrib/find/common/findController.i18n.json +++ b/i18n/cht/src/vs/editor/contrib/find/common/findController.i18n.json @@ -14,6 +14,5 @@ "addSelectionToPreviousFindMatch": "å°‡é¸å–項目加入å‰ä¸€å€‹æ‰¾åˆ°çš„相符項中", "moveSelectionToNextFindMatch": "將最後一個é¸æ“‡é …目移至下一個找到的相符項", "moveSelectionToPreviousFindMatch": "將最後一個é¸æ“‡é …目移至å‰ä¸€å€‹æ‰¾åˆ°çš„相符項", - "selectAllOccurencesOfFindMatch": "é¸å–所有找到的相符項目", "changeAll.label": "變更所有發生次數" } \ No newline at end of file diff --git a/i18n/cht/src/vs/editor/contrib/links/browser/links.i18n.json b/i18n/cht/src/vs/editor/contrib/links/browser/links.i18n.json index 405dbdb09b9..6f5daa0aa3c 100644 --- a/i18n/cht/src/vs/editor/contrib/links/browser/links.i18n.json +++ b/i18n/cht/src/vs/editor/contrib/links/browser/links.i18n.json @@ -6,6 +6,7 @@ { "links.navigate.mac": "æŒ‰ä½ Cmd 並按一下按éµä»¥è¿½è¹¤é€£çµ", "links.navigate": "æŒ‰ä½ Ctrl 並按一下滑鼠按鈕å¯é€£å…¥é€£çµ", + "links.navigate.al": "按ä½Alt並點擊以追蹤連çµ", "invalid.url": "抱歉,因為此連çµçš„語å¼ä¸æ­£ç¢ºï¼Œæ‰€ä»¥ç„¡æ³•åŠ ä»¥é–‹å•Ÿ: {0}", "missing.url": "抱歉,因為此連çµéºå¤±ç›®æ¨™ï¼Œæ‰€ä»¥ç„¡æ³•åŠ ä»¥é–‹å•Ÿã€‚", "label": "開啟連çµ" diff --git a/i18n/cht/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json b/i18n/cht/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json index 5ee6d0db8a7..b3f68973521 100644 --- a/i18n/cht/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json +++ b/i18n/cht/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json @@ -5,8 +5,6 @@ // Do not edit this file. It is machine generated. { "aria.oneReference": "個符號ä½æ–¼ {0} 中的第 {1} 行第 {2} 欄", - "aria.fileReferences.1": "1 個符號ä½æ–¼ {0}", - "aria.fileReferences.N": "{0} 個符號ä½æ–¼ {1}", "aria.result.0": "找ä¸åˆ°çµæžœ", "aria.result.1": "在 {0} 中找到 1 個符號", "aria.result.n1": "在 {1} 中找到 {0} 個符號", diff --git a/i18n/cht/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json b/i18n/cht/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json index 28f57ee6a5f..beb2f4690fc 100644 --- a/i18n/cht/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json +++ b/i18n/cht/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json @@ -12,6 +12,7 @@ "readMore": "進一步了解...{0}", "suggestionWithDetailsAriaLabel": "{0},建議,有詳細資料", "suggestionAriaLabel": "{0},建議", + "readLess": "簡易說明...{0}", "suggestWidget.loading": "正在載入...", "suggestWidget.noSuggestions": "無建議。", "suggestionAriaAccepted": "{0},接å—", diff --git a/i18n/cht/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json b/i18n/cht/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json index 3c019fc1a1c..bf2bf87414c 100644 --- a/i18n/cht/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json +++ b/i18n/cht/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json @@ -16,6 +16,7 @@ "schema.autoClosingPairs": "定義æˆå°æ‹¬å¼§ã€‚輸入左括弧時,å³è‡ªå‹•æ’å…¥å³æ‹¬å¼§ã€‚", "schema.autoClosingPairs.notIn": "定義åœç”¨è‡ªå‹•é…å°çš„範åœæ¸…單。", "schema.surroundingPairs": "定義å¯ç”¨ä»¥æ‹¬ä½æ‰€é¸å­—串的æˆå°æ‹¬å¼§ã€‚", + "schema.wordPattern": "定義語言的文字", "schema.wordPattern.pattern": "使用正è¦è¡¨ç¤ºå¼é€²è¡Œæ–‡å­—比å°", "schema.wordPattern.flags": "使用正è¦è¡¨ç¤ºå¼æ¨™è¨˜é€²è¡Œæ–‡å­—比å°", "schema.wordPattern.flags.errorMessage": "必須符åˆæ¨£å¼ `/^([gimuy]+)$/`" diff --git a/i18n/cht/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json b/i18n/cht/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json index 993d9fa74a6..8a8133f764f 100644 --- a/i18n/cht/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json +++ b/i18n/cht/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json @@ -21,6 +21,8 @@ "menus.scmTitle": "原始檔控制標題功能表", "menus.resourceGroupContext": "原始檔控制資æºç¾¤çµ„æ“作功能表", "menus.resourceStateContext": "原始檔控制資æºç¾¤çµ„狀態æ“作功能表", + "view.viewTitle": "這有助於查看標題功能表", + "view.itemContext": "這有助於查看項目內容功能表", "nonempty": "必須是éžç©ºç™½å€¼ã€‚", "opticon": "屬性 `icon` å¯ä»¥çœç•¥ï¼Œå¦å‰‡å¿…須為字串或類似 `{dark, light}` 的常值", "requireStringOrObject": "'{0}' 為必è¦å±¬æ€§ï¼Œä¸”其類型必須是 'string' 或 'object'", diff --git a/i18n/cht/src/vs/platform/extensions/common/extensionsRegistry.i18n.json b/i18n/cht/src/vs/platform/extensions/common/extensionsRegistry.i18n.json index f1ba5247c95..8586f1686ce 100644 --- a/i18n/cht/src/vs/platform/extensions/common/extensionsRegistry.i18n.json +++ b/i18n/cht/src/vs/platform/extensions/common/extensionsRegistry.i18n.json @@ -14,6 +14,12 @@ "vscode.extension.contributes": "æ­¤å°è£æ‰€ä»£è¡¨çš„所有 VS Code 擴充功能比é‡ã€‚", "vscode.extension.preview": "將延伸模組設為在 Marketplace 中標幟為 [é è¦½]。", "vscode.extension.activationEvents": "VS Code 擴充功能的啟動事件。", + "vscode.extension.activationEvents.onLanguage": "當指定語言檔案開啟時激發該事件", + "vscode.extension.activationEvents.onCommand": "當指定的命令被調用時激發該事件", + "vscode.extension.activationEvents.onDebug": "當指定的工作åµéŒ¯éšŽæ®µé–‹å§‹æ™‚激發該事件", + "vscode.extension.activationEvents.workspaceContains": "當開啟指定的文件夾包å«glob模å¼åŒ¹é…的文件時激發該事件", + "vscode.extension.activationEvents.onView": "當指定的檢視被擴展時激發該事件", + "vscode.extension.activationEvents.star": "當VS Code啟動時激發該事件,為了確ä¿æœ€å¥½çš„使用者體驗,當您的擴充功能沒有其他組åˆä½œæ¥­æ™‚,請激活此事件.", "vscode.extension.badges": "è¦é¡¯ç¤ºæ–¼ Marketplace æ“´å……é é¢è³‡è¨Šçœ‹æ¿çš„徽章陣列。", "vscode.extension.badges.url": "å¾½ç« æ˜ åƒ URL。", "vscode.extension.badges.href": "徽章連çµã€‚", diff --git a/i18n/cht/src/vs/platform/history/electron-main/historyMainService.i18n.json b/i18n/cht/src/vs/platform/history/electron-main/historyMainService.i18n.json new file mode 100644 index 00000000000..72828dcc85c --- /dev/null +++ b/i18n/cht/src/vs/platform/history/electron-main/historyMainService.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "newWindow": "開新視窗", + "newWindowDesc": "開啟新視窗", + "recentFolders": "最近使用的資料夾", + "folderDesc": "{0} {1}" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/platform/markers/common/problemMatcher.i18n.json b/i18n/cht/src/vs/platform/markers/common/problemMatcher.i18n.json index cd3b3aa69fe..a4b2c6583cc 100644 --- a/i18n/cht/src/vs/platform/markers/common/problemMatcher.i18n.json +++ b/i18n/cht/src/vs/platform/markers/common/problemMatcher.i18n.json @@ -34,6 +34,7 @@ "ProblemMatcherParser.noValidIdentifier": "錯誤: 樣å¼å±¬æ€§ {0} ä¸æ˜¯æœ‰æ•ˆçš„樣å¼è®Šæ•¸å稱。", "ProblemMatcherParser.problemPattern.watchingMatcher": "å•é¡Œæ¯”å°å™¨å¿…é ˆåŒæ™‚定義監控的開始模å¼å’ŒçµæŸæ¨¡å¼ã€‚", "ProblemMatcherParser.invalidRegexp": "錯誤: 字串 {0} ä¸æ˜¯æœ‰æ•ˆçš„è¦å‰‡é‹ç®—å¼ã€‚\n", + "WatchingPatternSchema.regexp": "用來查看åµæ¸¬èƒŒæ™¯å·¥ä½œé–‹å§‹æˆ–çµæŸçš„æ­£è¦è¡¨é”å¼.", "WatchingPatternSchema.file": "檔案å稱的符åˆç¾¤çµ„索引。å¯ä»¥çœç•¥ã€‚", "PatternTypeSchema.name": "所æ供或é å…ˆå®šç¾©ä¹‹æ¨¡å¼çš„å稱", "PatternTypeSchema.description": "å•é¡Œæ¨¡å¼æˆ–所æ供或é å…ˆå®šç¾©ä¹‹å•é¡Œæ¨¡å¼çš„å稱。如有指定基底,å³å¯ç™¼å‡ºã€‚", @@ -42,6 +43,12 @@ "ProblemMatcherSchema.severity": "æ“·å–é …ç›®å•é¡Œçš„é è¨­åš´é‡æ€§ã€‚如果模å¼æœªå®šç¾©åš´é‡æ€§çš„符åˆç¾¤çµ„,就會加以使用。", "ProblemMatcherSchema.applyTo": "控制文字文件上所回報的å•é¡Œåƒ…會套用至開啟的文件ã€é—œé–‰çš„文件或所有文件。", "ProblemMatcherSchema.fileLocation": "定義å•é¡Œæ¨¡å¼ä¸­æ‰€å›žå ±æª”案å稱的解譯方å¼ã€‚", + "ProblemMatcherSchema.background": "åµæ¸¬å¾Œå°ä»»å‹™ä¸­åŒ¹é…程åºæ¨¡å¼çš„開始與çµæŸ.", + "ProblemMatcherSchema.background.activeOnStart": "如果設置為 True,背景監控程å¼åœ¨å·¥ä½œå•Ÿå‹•æ™‚處於主動模å¼ã€‚這相當於符åˆèµ·å§‹æ¨£å¼çš„行。", + "ProblemMatcherSchema.background.beginsPattern": "如果於輸出中相符,則會指示背景程å¼é–‹å§‹ã€‚", + "ProblemMatcherSchema.background.endsPattern": "如果於輸出中相符,則會指示背景程å¼çµæŸã€‚", + "ProblemMatcherSchema.watching.deprecated": "關注屬性已被淘汰,請改用背景å–代。", + "ProblemMatcherSchema.watching": "追蹤匹é…程åºçš„開始與çµæŸã€‚", "ProblemMatcherSchema.watching.activeOnStart": "如果設定為 True,監控程å¼åœ¨å·¥ä½œå•Ÿå‹•æ™‚處於主動模å¼ã€‚é€™ç›¸ç•¶æ–¼ç™¼å‡ºç¬¦åˆ beginPattern çš„è¡Œ", "ProblemMatcherSchema.watching.beginsPattern": "如果在輸出中相符,則會指示監看工作開始。", "ProblemMatcherSchema.watching.endsPattern": "如果在輸出中相符,則會指示監看工作çµæŸã€‚", diff --git a/i18n/cht/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/cht/src/vs/platform/theme/common/colorRegistry.i18n.json index 85fdbbbbdf2..f1a9772aec3 100644 --- a/i18n/cht/src/vs/platform/theme/common/colorRegistry.i18n.json +++ b/i18n/cht/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -9,14 +9,14 @@ "foreground": "整體的å‰æ™¯è‰²å½©ã€‚僅當未被任何元件覆疊時,æ‰æœƒä½¿ç”¨æ­¤è‰²å½©ã€‚", "errorForeground": "整體錯誤訊æ¯çš„å‰æ™¯è‰²å½©ã€‚僅當未被任何元件覆蓋時,æ‰æœƒä½¿ç”¨æ­¤è‰²å½©ã€‚", "descriptionForeground": "æ供附加訊æ¯çš„å‰æ™¯é¡è‰²,例如標籤", - "focusBorder": "焦點項目的整體邊界色彩。åªåœ¨æ²’有任何元件覆寫此色彩時,æ‰æœƒåŠ ä»¥ä½¿ç”¨ã€‚", - "contrastBorder": "項目周åœçš„é¡å¤–邊界,å¯å°‡é …目從其他項目中å€éš”出來以æ高å°æ¯”。", + "focusBorder": "焦點項目的整體框線色彩。åªåœ¨æ²’有任何元件覆寫此色彩時,æ‰æœƒåŠ ä»¥ä½¿ç”¨ã€‚", + "contrastBorder": "項目周åœçš„é¡å¤–框線,å¯å°‡é …目從其他項目中å€éš”出來以æ高å°æ¯”。", "activeContrastBorder": "使用中項目周åœçš„é¡å¤–邊界,å¯å°‡é …目從其他項目中å€éš”出來以æ高å°æ¯”。", - "selectionBackground": "作業å€åŸŸé¸å–的背景é¡è‰²(例如輸入或文字å€åŸŸ)。請注æ„,這ä¸é©ç”¨æ–¼ç·¨è¼¯å™¨èˆ‡çµ‚端機中的é¸å–。", "textSeparatorForeground": "文字分隔符號的é¡è‰²ã€‚", "textLinkForeground": "內文連çµçš„å‰æ™¯è‰²å½©", "textLinkActiveForeground": "內文使用連çµçš„å‰æ™¯è‰²å½©", "textPreformatForeground": "æ示åŠå»ºè­°æ–‡å­—çš„å‰æ™¯è‰²å½©ã€‚", + "textBlockQuoteBackground": "文內引用å€å¡ŠèƒŒæ™¯è‰²å½©ã€‚", "textBlockQuoteBorder": "引用文字的框線é¡è‰²ã€‚", "textCodeBlockBackground": "文字å€å¡Šçš„背景é¡è‰²ã€‚", "widgetShadow": "å°å·¥å…·çš„陰影色彩,例如編輯器中的尋找/å–代。", @@ -35,11 +35,13 @@ "dropdownForeground": "下拉å¼æ¸…單的å‰æ™¯ã€‚", "dropdownBorder": "下拉å¼æ¸…單的框線。", "listFocusBackground": "當清單/樹狀為使用中狀態時,焦點項目的清單/樹狀背景色彩。使用中的清單/樹狀有éµç›¤ç„¦é»žï¼Œéžä½¿ç”¨ä¸­è€…則沒有。", + "listFocusForeground": "當清單/樹狀為使用中狀態時,焦點項目的清單/樹狀å‰æ™¯è‰²å½©ã€‚使用中的清單/樹狀有éµç›¤ç„¦é»žï¼Œéžä½¿ç”¨ä¸­è€…則沒有。", "listActiveSelectionBackground": "當清單/樹狀為使用中狀態時,所é¸é …目的清單/樹狀背景色彩。使用中的清單/樹狀有éµç›¤ç„¦é»žï¼Œéžä½¿ç”¨ä¸­è€…則沒有。", "listActiveSelectionForeground": "當清單/樹狀為使用中狀態時,所é¸é …目的清單/樹狀å‰æ™¯è‰²å½©ã€‚使用中的清單/樹狀有éµç›¤ç„¦é»žï¼Œéžä½¿ç”¨ä¸­è€…則沒有。", "listInactiveSelectionBackground": "當清單/樹狀為éžä½¿ç”¨ä¸­ç‹€æ…‹æ™‚,所é¸é …目的清單/樹狀背景色彩。使用中的清單/樹狀有éµç›¤ç„¦é»žï¼Œéžä½¿ç”¨ä¸­è€…則沒有。", "listInactiveSelectionForeground": "當清單/樹狀為使用中狀態時,所é¸é …目的清單/樹狀å‰æ™¯è‰²å½©ã€‚使用中的清單/樹狀有éµç›¤ç„¦é»žï¼Œéžä½¿ç”¨ä¸­å‰‡æ²’有。", "listHoverBackground": "使用滑鼠暫留在項目時的清單/樹狀背景。", + "listHoverForeground": "滑鼠暫留在項目時的清單/樹狀å‰æ™¯ã€‚", "listDropBackground": "使用滑鼠四處移動項目時的清單/樹狀拖放背景。", "highlight": "在清單/樹狀內æœå°‹æ™‚,相符醒目æ示的清單/樹狀å‰æ™¯è‰²å½©ã€‚", "pickerGroupForeground": "分組標籤的快速é¸æ“‡å™¨è‰²å½©ã€‚", @@ -57,6 +59,7 @@ "editorBackground": "編輯器的背景色彩。", "editorForeground": "編輯器的é è¨­å‰æ™¯è‰²å½©ã€‚", "editorWidgetBackground": "編輯器å°å·¥å…·çš„背景色彩,例如尋找/å–代。", + "editorWidgetBorder": "編輯器å°å·¥å…·çš„邊界色彩。å°å·¥å…·é¸æ“‡æ“有邊界或色彩未被å°å·¥å…·è¦†å¯«æ™‚,æ‰æœƒä½¿ç”¨è‰²å½©ã€‚", "editorSelection": "編輯器é¸å–範åœçš„色彩。", "editorInactiveSelection": "éžä½¿ç”¨ä¸­ä¹‹ç·¨è¼¯å™¨é¸å–範åœçš„色彩。", "editorSelectionHighlight": "é¸å–時,內容相åŒä¹‹å€åŸŸçš„色彩。", @@ -70,5 +73,12 @@ "diffEditorInserted": "æ’入文字的背景色彩。", "diffEditorRemoved": "移除文字的背景色彩。", "diffEditorInsertedOutline": "æ’入的文字外框色彩。", - "diffEditorRemovedOutline": "移除的文字外框色彩。" + "diffEditorRemovedOutline": "移除的文字外框色彩。", + "mergeCurrentHeaderBackground": "ç›®å‰å…§åµŒåˆä½µè¡çªä¸­çš„深色標題背景。", + "mergeCurrentContentBackground": "ç›®å‰å…§åµŒåˆä½µè¡çªä¸­çš„內容背景。", + "mergeIncomingHeaderBackground": "傳入內嵌åˆä½µè¡çªä¸­çš„深色標題背景。", + "mergeIncomingContentBackground": "傳入內嵌åˆä½µè¡çªä¸­çš„內容背景。", + "mergeBorder": "內嵌åˆä½µè¡çªä¸­æ¨™é ­åŠåˆ†éš”器的邊界色彩。", + "overviewRulerCurrentContentForeground": "ç›®å‰å…§åµŒåˆä½µè¡çªçš„概觀尺è¦å‰æ™¯ã€‚", + "overviewRulerIncomingContentForeground": "傳入內嵌åˆä½µè¡çªçš„概觀尺è¦å‰æ™¯ã€‚" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/cht/src/vs/workbench/api/node/extHostTask.i18n.json index 8b6ad71cd4e..4b90a12aaf2 100644 --- a/i18n/cht/src/vs/workbench/api/node/extHostTask.i18n.json +++ b/i18n/cht/src/vs/workbench/api/node/extHostTask.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "task.label": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/api/node/extHostTreeViews.i18n.json b/i18n/cht/src/vs/workbench/api/node/extHostTreeViews.i18n.json index 028bfb1a1d0..edc32bace6e 100644 --- a/i18n/cht/src/vs/workbench/api/node/extHostTreeViews.i18n.json +++ b/i18n/cht/src/vs/workbench/api/node/extHostTreeViews.i18n.json @@ -4,5 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "treeView.notRegistered": "未註冊識別碼為 '{0}' 的樹狀檢視。", + "treeItem.notFound": "找ä¸åˆ°è­˜åˆ¥ç¢¼ç‚º '{0}' 的樹狀檢視。", "treeView.duplicateElement": "元件{0}已被註冊" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json b/i18n/cht/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json index f5d3fe58b62..e2c33864cd6 100644 --- a/i18n/cht/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json +++ b/i18n/cht/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json @@ -5,5 +5,6 @@ // Do not edit this file. It is machine generated. { "hideActivitBar": "éš±è—活動列", - "activityBarAriaLabel": "å³æ™‚檢視切æ›å™¨" + "activityBarAriaLabel": "å³æ™‚檢視切æ›å™¨", + "globalActions": "全域動作" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json b/i18n/cht/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json index 3ee2576e0d3..54beb87e59b 100644 --- a/i18n/cht/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json +++ b/i18n/cht/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json @@ -10,7 +10,7 @@ "multiSelection": "{0} 個é¸å–é …ç›®", "endOfLineLineFeed": "LF", "endOfLineCarriageReturnLineFeed": "CRLF", - "tabFocusModeEnabled": "用 Tab éµç§»å‹•ç„¦é»ž", + "screenReaderDetectedExtra": "若您ä¸æ‰“算使用螢幕助讀程å¼ï¼Œè«‹å°‡è¨­å®š `editor.accessibilitySupport` 變更為 \"off\"。", "disableTabMode": "åœç”¨å”助工具模å¼", "gotoLine": "移至行", "indentation": "縮排", diff --git a/i18n/cht/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json b/i18n/cht/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json new file mode 100644 index 00000000000..4e288801642 --- /dev/null +++ b/i18n/cht/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpen": "移至檔案...", + "quickNavigateNext": "在 Quick Open 中導覽至下一項", + "quickNavigatePrevious": "在 Quick Open 中導覽至上一項", + "quickSelectNext": "在 Quick Open 中é¸å–下一個", + "quickSelectPrevious": "在 Quick Open 中é¸å–上一個" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/browser/quickopen.i18n.json b/i18n/cht/src/vs/workbench/browser/quickopen.i18n.json index c47858a81d2..cab0a05a7b4 100644 --- a/i18n/cht/src/vs/workbench/browser/quickopen.i18n.json +++ b/i18n/cht/src/vs/workbench/browser/quickopen.i18n.json @@ -6,6 +6,5 @@ { "noResultsMatching": "沒有相符的çµæžœ", "noResultsFound2": "找ä¸åˆ°çµæžœ", - "entryAriaLabel": "{0},命令", - "noCommands": "沒有相符的命令" + "entryAriaLabel": "{0},命令" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/browser/viewlet.i18n.json b/i18n/cht/src/vs/workbench/browser/viewlet.i18n.json index 26801a4aefd..690069abe96 100644 --- a/i18n/cht/src/vs/workbench/browser/viewlet.i18n.json +++ b/i18n/cht/src/vs/workbench/browser/viewlet.i18n.json @@ -4,6 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "collapse": "全部摺疊", - "viewToolbarAriaLabel": "{0} 個動作" + "collapse": "全部摺疊" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/common/theme.i18n.json b/i18n/cht/src/vs/workbench/common/theme.i18n.json index ae6c513e6ce..938086e4262 100644 --- a/i18n/cht/src/vs/workbench/common/theme.i18n.json +++ b/i18n/cht/src/vs/workbench/common/theme.i18n.json @@ -7,28 +7,42 @@ "tabActiveBackground": "使用中之索引標籤的背景色彩。索引標籤是編輯器在編輯器å€åŸŸä¸­çš„容器。åŒä¸€å€‹ç·¨è¼¯å™¨ç¾¤çµ„中的多個索引標籤å¯ä»¥åŒæ™‚開啟。å¯èƒ½æœƒæœ‰å¤šå€‹ç·¨è¼¯å™¨ç¾¤çµ„。", "tabInactiveBackground": "éžä½¿ç”¨ä¸­ä¹‹ç´¢å¼•æ¨™ç±¤çš„背景色彩。索引標籤是編輯器在編輯器å€åŸŸä¸­çš„容器。åŒä¸€å€‹ç·¨è¼¯å™¨ç¾¤çµ„中的多個索引標籤å¯ä»¥åŒæ™‚開啟。å¯èƒ½æœƒæœ‰å¤šå€‹ç·¨è¼¯å™¨ç¾¤çµ„。", "tabBorder": "用以分隔索引標籤彼此的框線。索引標籤是編輯器在編輯器å€åŸŸä¸­çš„容器。åŒä¸€å€‹ç·¨è¼¯å™¨ç¾¤çµ„中的多個索引標籤å¯ä»¥åŒæ™‚開啟。å¯èƒ½æœƒæœ‰å¤šå€‹ç·¨è¼¯å™¨ç¾¤çµ„。", + "tabActiveForeground": "使用中的群組內,使用中之索引標籤的å‰æ™¯è‰²å½©ã€‚索引標籤是編輯器在編輯器å€åŸŸä¸­çš„容器。åŒä¸€å€‹ç·¨è¼¯å™¨ç¾¤çµ„中的多個索引標籤å¯ä»¥åŒæ™‚開啟。å¯èƒ½æœƒæœ‰å¤šå€‹ç·¨è¼¯å™¨ç¾¤çµ„。", + "tabInactiveForeground": "使用中的群組內,éžä½¿ç”¨ä¸­ä¹‹ç´¢å¼•æ¨™ç±¤çš„å‰æ™¯è‰²å½©ã€‚索引標籤是編輯器在編輯器å€åŸŸä¸­çš„容器。åŒä¸€å€‹ç·¨è¼¯å™¨ç¾¤çµ„中的多個索引標籤å¯ä»¥åŒæ™‚開啟。å¯èƒ½æœƒæœ‰å¤šå€‹ç·¨è¼¯å™¨ç¾¤çµ„。", + "tabUnfocusedActiveForeground": "éžä½¿ç”¨ä¸­çš„群組內,使用中之索引標籤的å‰æ™¯è‰²å½©ã€‚索引標籤是編輯器在編輯器å€åŸŸä¸­çš„容器。åŒä¸€å€‹ç·¨è¼¯å™¨ç¾¤çµ„中的多個索引標籤å¯ä»¥åŒæ™‚開啟。å¯èƒ½æœƒæœ‰å¤šå€‹ç·¨è¼¯å™¨ç¾¤çµ„。", + "tabUnfocusedInactiveForeground": "éžä½¿ç”¨ä¸­çš„群組內,éžä½¿ç”¨ä¸­ä¹‹ç´¢å¼•æ¨™ç±¤çš„å‰æ™¯è‰²å½©ã€‚索引標籤是編輯器在編輯器å€åŸŸä¸­çš„容器。åŒä¸€å€‹ç·¨è¼¯å™¨ç¾¤çµ„中的多個索引標籤å¯ä»¥åŒæ™‚開啟。å¯èƒ½æœƒæœ‰å¤šå€‹ç·¨è¼¯å™¨ç¾¤çµ„。", "editorGroupBackground": "編輯器群組的背景色彩。編輯器群組是編輯器的容器。當拖曳編輯器群組時會顯示背景色彩。", + "tabsContainerBackground": "當索引標籤啟用的時候編輯器群組標題的背景色彩。編輯器群組是編輯器的容器。", + "tabsContainerBorder": "當索引標籤啟用時,編輯器群組標題的框線色彩。編輯器群組是編輯器的容器。", "editorGroupHeaderBackground": "當索引標籤ç¦ç”¨çš„時候編輯器群組標題的背景é¡è‰²ã€‚編輯器群組是編輯器的容器。", "editorGroupBorder": "用以分隔多個編輯器群組彼此的色彩。編輯器群組是編輯器的容器。", + "editorDragAndDropBackground": "拖拉編輯器時的背景é¡è‰²,å¯è¨­ç½®é€æ˜Žåº¦è®“內容穿é€é¡¯ç¤º.", + "panelBackground": "é¢æ¿çš„å‰æ™¯è‰²å½©ã€‚é¢æ¿æœƒé¡¯ç¤ºåœ¨ç·¨è¼¯å™¨å€åŸŸçš„下方,其中包å«è«¸å¦‚輸出與整åˆå¼çµ‚端機等檢視。", "panelBorder": "é¢æ¿é ‚端用以分隔編輯器的邊框色彩。é¢æ¿æœƒé¡¯ç¤ºåœ¨ç·¨è¼¯å™¨å€åŸŸçš„下方,其中包å«è«¸å¦‚輸出與整åˆå¼çµ‚端機等檢視。", "panelActiveTitleForeground": "使用中之é¢æ¿æ¨™é¡Œçš„標題色彩。é¢æ¿æœƒé¡¯ç¤ºåœ¨ç·¨è¼¯å™¨å€åŸŸçš„下方,其中包å«è«¸å¦‚輸出與整åˆå¼çµ‚端機等檢視。", "panelInactiveTitleForeground": "éžä½¿ç”¨ä¸­ä¹‹é¢æ¿æ¨™é¡Œçš„標題色彩。é¢æ¿æœƒé¡¯ç¤ºåœ¨ç·¨è¼¯å™¨å€åŸŸçš„下方,其中包å«è«¸å¦‚輸出與整åˆå¼çµ‚端機等檢視。", "panelActiveTitleBorder": "使用中之é¢æ¿æ¨™é¡Œçš„框線色彩。é¢æ¿æœƒé¡¯ç¤ºåœ¨ç·¨è¼¯å™¨å€åŸŸçš„下方,其中包å«è«¸å¦‚輸出與整åˆå¼çµ‚端機等檢視。", "statusBarForeground": "狀態列的å‰æ™¯è‰²å½©ã€‚狀態列會顯示在視窗的底部。", "statusBarBackground": "標準狀態列的背景色彩。狀態列會顯示在視窗的底部。", + "statusBarBorder": "用以分隔資訊看æ¿èˆ‡ç·¨è¼¯å™¨çš„狀態列框線色彩。狀態列會顯示在視窗的底部。", "statusBarNoFolderBackground": "當未開啟任何資料夾時,狀態列的背景色彩。狀態列會顯示在視窗的底部。", + "statusBarNoFolderForeground": "當未開啟任何資料夾時,狀態列的å‰æ™¯è‰²å½©ã€‚狀態列會顯示在視窗的底部。", "statusBarItemActiveBackground": "按下滑鼠按鈕時,狀態列項目的背景色彩。狀態列會顯示在視窗的底部。", "statusBarItemHoverBackground": "動態顯示時,狀態列項目的背景色彩。狀態列會顯示在視窗的底部。", "statusBarProminentItemBackground": "狀態列çªå‡ºé …目的背景é¡è‰²ã€‚çªå‡ºé …目比狀態列的其他項目更顯眼,用於表示é‡è¦æ€§æ›´é«˜ã€‚狀態列會顯示在視窗的底部。", "statusBarProminentItemHoverBackground": "狀態列çªå‡ºé …目暫留時的背景é¡è‰²ã€‚çªå‡ºé …目比狀態列的其他項目更顯眼,用於表示é‡è¦æ€§æ›´é«˜ã€‚狀態列會顯示在視窗的底部。", "activityBarBackground": "活動列背景的色彩。活動列會顯示在最左å´æˆ–最å³å´ï¼Œä¸¦å¯åˆ‡æ›ä¸åŒçš„æè¦æ¬„ä½æª¢è¦–。", "activityBarForeground": "活動列的å‰èƒŒæ™¯è‰²å½©(例如用於圖示)。此活動列會顯示在最左å´æˆ–最å³å´ï¼Œè®“您å¯ä»¥åˆ‡æ›æè¦æ¬„ä½çš„ä¸åŒæª¢è¦–。", + "activityBarBorder": "用以分隔æè¦æ¬„ä½çš„活動列框線色彩。此活動列會顯示在最左å´æˆ–最å³å´ï¼Œè®“您å¯ä»¥åˆ‡æ›æè¦æ¬„ä½çš„ä¸åŒæª¢è¦–。", + "activityBarDragAndDropBackground": "拖拉活動徽章項目時的色彩.é¡è‰²å¯è¨­ç½®é€æ˜Žåº¦è®“原活動徽章å¯ç©¿é€é¡¯ç¤º.活動徽章列表會出ç¾åœ¨æœ€å·¦å´æˆ–最å³å´ä¸¦å…許切æ›ä¸åŒçš„檢視.", "activityBarBadgeBackground": "活動通知徽章的背景色彩。此活動列會顯示在最左å´æˆ–最å³å´ï¼Œè®“您å¯ä»¥åˆ‡æ›æè¦æ¬„ä½çš„ä¸åŒæª¢è¦–。", "activityBarBadgeForeground": "活動通知徽章的å‰èƒŒæ™¯è‰²å½©ã€‚此活動列會顯示在最左å´æˆ–最å³å´ï¼Œè®“您å¯ä»¥åˆ‡æ›æè¦æ¬„ä½çš„ä¸åŒæª¢è¦–。", "sideBarBackground": "æè¦æ¬„ä½çš„背景色彩。æè¦æ¬„ä½æ˜¯æª¢è¦– (例如 Explorer 與æœå°‹) 的容器。", "sideBarForeground": "å´æ¬„çš„å‰æ™¯é¡è‰².å´æ¬„包å«Explorer與æœå°‹.", + "sideBarBorder": "用以分隔編輯器的å´é‚Šæè¦æ¬„ä½æ¡†ç·šè‰²å½©ã€‚該æè¦æ¬„ä½æ˜¯æª¢è¦– (例如 Explorer åŠæœå°‹) 的容器。", "sideBarTitleForeground": "æè¦æ¬„ä½æ¨™é¡Œçš„å‰æ™¯è‰²å½©ã€‚æè¦æ¬„ä½æ˜¯æª¢è¦– (例如 Explorer 與æœå°‹) 的容器。", "sideBarSectionHeaderBackground": "æè¦æ¬„ä½å€æ®µæ¨™é ­çš„背景色彩。æè¦æ¬„ä½æ˜¯æª¢è¦– (例如 Explorer 與æœå°‹) 的容器。", + "sideBarSectionHeaderForeground": "æè¦æ¬„ä½å€æ®µæ¨™é ­çš„å‰æ™¯è‰²å½©ã€‚æè¦æ¬„ä½æ˜¯æª¢è¦– (例如 Explorer 與æœå°‹) 的容器。", "titleBarActiveForeground": "作用中視窗之標題列的å‰æ™¯ã€‚請注æ„,目å‰åªæœ‰ macOS 支æ´æ­¤è‰²å½©ã€‚", "titleBarInactiveForeground": "éžä½œç”¨ä¸­è¦–窗之標題列的å‰æ™¯ã€‚請注æ„,目å‰åªæœ‰ macOS 支æ´æ­¤è‰²å½©ã€‚", "titleBarActiveBackground": "作用中視窗之標題列的背景。請注æ„,目å‰åªæœ‰ macOS 支æ´æ­¤è‰²å½©ã€‚", diff --git a/i18n/cht/src/vs/workbench/electron-browser/actions.i18n.json b/i18n/cht/src/vs/workbench/electron-browser/actions.i18n.json index 5268fd64574..4bb693a3d1f 100644 --- a/i18n/cht/src/vs/workbench/electron-browser/actions.i18n.json +++ b/i18n/cht/src/vs/workbench/electron-browser/actions.i18n.json @@ -6,9 +6,6 @@ { "closeActiveEditor": "關閉編輯器", "closeWindow": "關閉視窗", - "switchWindow": "切æ›è¦–窗", - "switchWindowPlaceHolder": "é¸å–視窗", - "current": "ç›®å‰è¦–窗", "closeFolder": "關閉資料夾", "noFolderOpened": "此執行個體中目å‰æ²’有開啟的資料夾å¯ä»¥é—œé–‰ã€‚", "newWindow": "開新視窗", @@ -20,7 +17,7 @@ "zoomReset": "é‡è¨­ç¸®æ”¾", "appPerf": "啟動效能", "reloadWindow": "é‡æ–°è¼‰å…¥è¦–窗", - "openRecent": "開啟最近使用的檔案", + "current": "ç›®å‰è¦–窗", "folders": "資料夾", "files": "檔案", "openRecentPlaceHolderMac": "é¸å–路徑 (æŒ‰ä½ Cmd éµä»¥åœ¨æ–°è¦–窗開啟)", @@ -32,10 +29,6 @@ "openDocumentationUrl": "文件", "openIntroductoryVideosUrl": "簡介影片", "toggleSharedProcess": "切æ›å…±ç”¨è™•ç†åº", - "navigateLeft": "移至 [檢視左å´]", - "navigateRight": "移至 [檢視å³å´]", - "navigateUp": "移至 [檢視上方]", - "navigateDown": "移至 [檢視下方]", "increaseViewSize": "增加目å‰çš„檢視大å°", "decreaseViewSize": "縮å°ç›®å‰çš„檢視大å°" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/cht/src/vs/workbench/electron-browser/main.contribution.i18n.json index bced8b136e5..7fcb8f4533b 100644 --- a/i18n/cht/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/cht/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -31,10 +31,6 @@ "window.openFoldersInNewWindow.off": "資料夾會å–代上一個使用中的視窗", "window.openFoldersInNewWindow.default": "除éžå·²å¾žæ‡‰ç”¨ç¨‹å¼å…§æŒ‘é¸äº†è³‡æ–™å¤¾ (例如é€éŽ [檔案] 功能表),å¦å‰‡è³‡æ–™å¤¾æœƒåœ¨æ–°è¦–窗中開啟", "openFoldersInNewWindow": "控制資料夾應在新視窗中開啟或å–代上一個使用中的視窗。\n- default: 除éžå·²å¾žæ‡‰ç”¨ç¨‹å¼å…§æŒ‘é¸è³‡æ–™å¤¾ (例如,é€éŽ [檔案] 功能表),å¦å‰‡æœƒåœ¨æ–°è¦–窗開啟\n- on: 資料夾會在新視窗開啟\n- off: 資料夾會å–代上一個使用中視窗\n請注æ„,在æŸäº›æƒ…æ³ä¸‹æœƒç•¥éŽæ­¤è¨­å®š (例如,使用了 -new-window 或 -reuse-window 命令列é¸é …時)。", - "window.reopenFolders.none": "一律ä¸é‡æ–°é–‹å•Ÿè³‡æ–™å¤¾ã€‚", - "window.reopenFolders.one": "é‡æ–°é–‹å•Ÿä¸Šä¸€å€‹ä½¿ç”¨ä¸­çš„資料夾。", - "window.reopenFolders.all": "é‡æ–°é–‹å•Ÿä¸Šä¸€å€‹å·¥ä½œéšŽæ®µçš„所有資料夾。", - "reopenFolders": "控制é‡æ–°å•Ÿå‹•å¾Œé‡æ–°é–‹å•Ÿè³‡æ–™å¤¾çš„æ–¹å¼ã€‚é¸å– [none] æ°¸ä¸é‡æ–°é–‹å•Ÿè³‡æ–™å¤¾ï¼Œé¸å– [one] é‡æ–°é–‹å•Ÿæœ€è¿‘一個使用的資料夾,或é¸å– [all] é‡æ–°é–‹å•Ÿä¸Šä¸€å€‹å·¥ä½œéšŽæ®µçš„所有資料夾。", "restoreFullscreen": "控制當視窗在全螢幕模å¼ä¸‹çµæŸå¾Œï¼Œä¸‹æ¬¡æ˜¯å¦ä»ä»¥å…¨èž¢å¹•æ¨¡å¼é–‹å•Ÿã€‚", "zoomLevel": "調整視窗的縮放比例。原始大å°ç‚º 0,而且æ¯å€‹å‘ä¸Šå¢žé‡ (例如 1) 或å‘ä¸‹å¢žé‡ (例如 -1) ä»£è¡¨æ”¾å¤§æˆ–ç¸®å° 20%。您也å¯ä»¥è¼¸å…¥å°æ•¸ï¼Œæ›´ç´°å¾®åœ°èª¿æ•´ç¸®æ”¾æ¯”例。", "title": "控制使用中之編輯器上的視窗標題。變數會ä¾å…§å®¹æ›¿æ›: \n${activeEditorShort}: 例如 myFile.txt\n${activeEditorMedium}: 例如 myFolder/myFile.txt\n${activeEditorLong}: 例如 /Users/Development/myProject/myFolder/myFile.txt\n${rootName}: 例如 myProject\n${rootPath}: 例如 /Users/Development/myProject\n${appName}: 例如 VS Code\n${dirty}: 若使用中的編輯器已變更,å³ç‚ºå·²è®Šæ›´çš„指標\n${separator}: æ¢ä»¶å¼åˆ†éš”符號 (\" - \"),åªæœƒåœ¨å‰å¾Œæœ‰åŒ…å«å€¼çš„變數時顯示", @@ -42,11 +38,13 @@ "window.newWindowDimensions.inherit": "以相åŒæ–¼ä¸Šä¸€å€‹ä½¿ç”¨ä¸­ä¹‹è¦–窗的維度開啟新視窗。", "window.newWindowDimensions.maximized": "開啟並最大化新視窗。", "window.newWindowDimensions.fullscreen": "在全螢幕模å¼ä¸‹é–‹å•Ÿæ–°è¦–窗。", + "newWindowDimensions": "控制當至少一個視窗已打開的情æ³ä¸‹é–‹å•Ÿæ–°è¦–窗的維度。根據é è¨­ï¼Œæ–°è¦–窗會以å°åž‹ç¶­åº¦åœ¨ç•«é¢ä¸­å¤®é–‹å•Ÿã€‚設為 'inherit' 時,視窗的維度會和最後開啟的視窗相åŒã€‚設為 'maximized' 時,視窗會開到最大,若設為 'fullscreen' 則全螢幕開啟。", "window.menuBarVisibility.default": "åªåœ¨å…¨èž¢å¹•æ¨¡å¼æ™‚éš±è—功能表。", "window.menuBarVisibility.visible": "一律顯示功能表,å³ä½¿åœ¨å…¨èž¢å¹•æ¨¡å¼æ™‚亦然。", "window.menuBarVisibility.toggle": "éš±è—功能表,但å¯ç¶“ç”± Alt éµåŠ ä»¥é¡¯ç¤ºã€‚", "window.menuBarVisibility.hidden": "一律隱è—功能表。", "menuBarVisibility": "控制功能表列的å¯è¦‹åº¦ã€‚[切æ›] 設定表示會隱è—功能表列,按一下 Alt éµå‰‡æœƒé¡¯ç¤ºã€‚除éžè¦–窗是全螢幕,å¦å‰‡é è¨­æœƒé¡¯ç¤ºåŠŸèƒ½è¡¨åˆ—。", + "enableMenuBarMnemonics": "啟用後å¯ä»¥åˆ©ç”¨Altå¿«æ·éµæ‰“開主é¸å–®.關閉記憶é¸å–®å°‡Altå¿«æ·éµç¶å®šè‡³æ›¿ä»£çš„命令å€å¡Š.", "autoDetectHighContrast": "若啟用,如果 Windows 使用高å°æ¯”佈景主題,就會自動變更為高å°æ¯”佈景主題,切æ›æŽ‰ Windows 高å°æ¯”佈景主題時則變更為深色佈景主題。", "titleBarStyle": "調整視窗標題列的外觀。變更需è¦å®Œæ•´é‡æ–°å•Ÿå‹•æ‰æœƒå¥—用。", "window.nativeTabs": "啟用 macOS Sierra 視窗索引標籤。請注æ„需è¦å®Œå…¨é‡æ–°å•Ÿå‹•æ‰èƒ½å¥—用變更,並且完æˆè¨­å®šå¾ŒåŽŸå§‹ç´¢å¼•æ¨™ç±¤å°‡æœƒåœç”¨è‡ªè¨‚標題列樣å¼ã€‚", @@ -56,5 +54,7 @@ "zenMode.hideTabs": "控制開啟 Zen Mode 是å¦ä¹Ÿæœƒéš±è— Workbench 索引標籤。", "zenMode.hideStatusBar": "控制開啟 Zen Mode 是å¦ä¹Ÿæœƒéš±è— Workbench 底部的狀態列。", "zenMode.hideActivityBar": "控制開啟 Zen Mode 是å¦ä¹Ÿæœƒéš±è— Workbench 左方的活動列。", - "zenMode.restore": "控制視窗如果在 Zen Mode 下çµæŸï¼Œæ˜¯å¦æ‡‰é‚„原為 Zen Mode。" + "zenMode.restore": "控制視窗如果在 Zen Mode 下çµæŸï¼Œæ˜¯å¦æ‡‰é‚„原為 Zen Mode。", + "workspaceConfigurationTitle": "工作å€", + "files.exclude.boolean": "è¦ç¬¦åˆæª”案路徑的 Glob 模å¼ã€‚設為 True 或 False å¯å•Ÿç”¨æˆ–åœç”¨æ¨¡å¼ã€‚" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json b/i18n/cht/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json new file mode 100644 index 00000000000..9e13a86b296 --- /dev/null +++ b/i18n/cht/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json @@ -0,0 +1,26 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "emergencyConfOn": "ç¾åœ¨è«‹å°‡è¨­å®š `editor.accessibilitySupport` 變更為 'on'。", + "openingDocs": "ç¾åœ¨è«‹é–‹å•Ÿ VS Code å”助工具文件é é¢ã€‚", + "introMsg": "æ„Ÿè¬æ‚¨è©¦ç”¨ VS Code çš„å”助工具é¸é …。", + "status": "狀態:", + "changeConfigToOnMac": "è‹¥è¦å°‡ç·¨è¼¯å™¨ç‚ºèž¢å¹•åŠ©è®€ç¨‹å¼çš„使用方å¼è¨­å®šç‚ºæ°¸ä¹…地最佳化,ç¾åœ¨è«‹æŒ‰ Command+E。", + "changeConfigToOnWinLinux": "è‹¥è¦å°‡ç·¨è¼¯å™¨ç‚ºèž¢å¹•åŠ©è®€ç¨‹å¼çš„使用方å¼è¨­å®šç‚ºæ°¸ä¹…地最佳化,ç¾åœ¨è«‹æŒ‰ Control+E。", + "auto_unknown": "ç·¨è¼¯å™¨å·²è¨­å®šç‚ºä½¿ç”¨å¹³å° API 以åµæ¸¬èž¢å¹•åŠ©è®€ç¨‹å¼é™„加,但是目å‰çš„執行階段ä¸æ”¯æ´ã€‚", + "auto_on": "編輯器已自動åµæ¸¬åˆ°èž¢å¹•åŠ©è®€ç¨‹å¼é™„加。", + "auto_off": "編輯器已設定為自動åµæ¸¬èž¢å¹•åŠ©è®€ç¨‹å¼é™„加,但目å‰çš„實際狀æ³å»ä¸æ˜¯å¦‚此。", + "configuredOn": "編輯器已為螢幕助讀程å¼çš„使用方å¼è¨­å®šç‚ºæ°¸ä¹…地更新 - 您å¯ä»¥è—‰ç”±ç·¨è¼¯è¨­å®š `editor.accessibilitySupport` 以變更這項設定。", + "configuredOff": "編輯器已設定為ä¸æœƒç‚ºèž¢å¹•åŠ©è®€ç¨‹å¼çš„使用方å¼é€²è¡Œæœ€ä½³åŒ–。", + "tabFocusModeOnMsg": "在目å‰çš„編輯器中按 Tab éµæœƒå°‡ç„¦é»žç§»è‡³ä¸‹ä¸€å€‹å¯è¨­å®šç„¦é»žçš„元素。按 {0} å¯åˆ‡æ›æ­¤è¡Œç‚ºã€‚", + "tabFocusModeOnMsgNoKb": "在目å‰çš„編輯器中按 Tab éµæœƒå°‡ç„¦é»žç§»è‡³ä¸‹ä¸€å€‹å¯è¨­å®šç„¦é»žçš„元素。命令 {0} ç›®å‰ç„¡æ³•ç”±æŒ‰éµç¹«çµé—œä¿‚觸發。", + "tabFocusModeOffMsg": "在目å‰çš„編輯器中按 Tab éµæœƒæ’入定ä½å­—元。按 {0} å¯åˆ‡æ›æ­¤è¡Œç‚ºã€‚", + "tabFocusModeOffMsgNoKb": "在目å‰çš„編輯器中按 Tab éµæœƒæ’入定ä½å­—元。命令 {0} ç›®å‰ç„¡æ³•ç”±æŒ‰éµç¹«çµé—œä¿‚觸發。", + "openDocMac": "ç¾åœ¨è«‹æŒ‰ Command+H 以開啟具有更多與å”助工具相關 VS Code 資訊的ç€è¦½å™¨è¦–窗。", + "openDocWinLinux": "ç¾åœ¨è«‹æŒ‰ Control+H 以開啟具有更多與å”助工具相關 VS Code 資訊的ç€è¦½å™¨è¦–窗。", + "outroMsg": "您å¯ä»¥æŒ‰ Esc éµæˆ– Shift+Esc éµä¾†è§£é™¤æ­¤å·¥å…·æ示並返回編輯器。", + "ShowAccessibilityHelpAction": "顯示å”助工具說明" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json b/i18n/cht/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/cht/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json b/i18n/cht/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json new file mode 100644 index 00000000000..fef7fe532f8 --- /dev/null +++ b/i18n/cht/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleLocation": "切æ›è‡³å¤šæ¸¸æ¨™ä¿®æ”¹ç¨‹å¼" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/debug/browser/debugActions.i18n.json b/i18n/cht/src/vs/workbench/parts/debug/browser/debugActions.i18n.json index c2ab22390ca..b1e2ccbfec4 100644 --- a/i18n/cht/src/vs/workbench/parts/debug/browser/debugActions.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/debug/browser/debugActions.i18n.json @@ -6,6 +6,7 @@ { "openLaunchJson": "é–‹å•Ÿ {0}", "launchJsonNeedsConfigurtion": "設定或修正 'launch.json'", + "noFolderDebugConfig": "請先打開一個資料夾以便設定進階åµéŒ¯çµ„態。", "startDebug": "開始åµéŒ¯", "startWithoutDebugging": "開始但ä¸åµéŒ¯", "selectAndStartDebugging": "é¸å–並開始åµéŒ¯", diff --git a/i18n/cht/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json b/i18n/cht/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json index 8b6ad71cd4e..b5bfc8d474b 100644 --- a/i18n/cht/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "noFolderDebugConfig": "請先打開一個資料夾以便設定進階åµéŒ¯çµ„態。" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json b/i18n/cht/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json index e199cca6775..e6e2542dc0a 100644 --- a/i18n/cht/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json @@ -5,16 +5,12 @@ // Do not edit this file. It is machine generated. { "variablesSection": "變數å€æ®µ", - "variables": "變數", "variablesAriaTreeLabel": "åµéŒ¯è®Šæ•¸", "expressionsSection": "é‹ç®—å¼å€æ®µ", - "watch": "監看", "watchAriaTreeLabel": "å°ç›£çœ‹é‹ç®—å¼åŸ·è¡ŒåµéŒ¯", "callstackSection": "呼å«å †ç–Šå€æ®µ", "debugStopped": "æ–¼ {0} æš«åœ", - "callStack": "呼å«å †ç–Š", "callStackAriaLabel": "åµéŒ¯å‘¼å«å †ç–Š", "breakpointsSection": "中斷點å€æ®µ", - "breakpoints": "中斷點", "breakpointsAriaTreeLabel": "åµéŒ¯ä¸­æ–·é»ž" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json b/i18n/cht/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json index ae46ae65a60..d77b4677cea 100644 --- a/i18n/cht/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json @@ -6,5 +6,6 @@ { "copyValue": "複製值", "copy": "複製", + "copyAll": "全部複製", "copyStackTrace": "複製呼å«å †ç–Š" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json b/i18n/cht/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json index 259df04a8b1..81362151ea4 100644 --- a/i18n/cht/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "statusBarDebuggingBackground": "å°ç¨‹å¼åŸ·è¡ŒåµéŒ¯æ™‚狀態列的背景色彩。狀態列會顯示在視窗的底部" + "statusBarDebuggingBackground": "å°ç¨‹å¼åŸ·è¡ŒåµéŒ¯æ™‚狀態列的背景色彩。狀態列會顯示在視窗的底部", + "statusBarDebuggingForeground": "å°ç¨‹å¼åŸ·è¡ŒåµéŒ¯æ™‚狀態列的å‰æ™¯è‰²å½©ã€‚狀態列會顯示在視窗的底部" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json b/i18n/cht/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json index fbd7d7b23df..246786aab6c 100644 --- a/i18n/cht/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json @@ -7,6 +7,7 @@ "debugAdapterBinNotFound": "åµéŒ¯é…接器å¯åŸ·è¡Œæª” '{0}' ä¸å­˜åœ¨ã€‚", "debugAdapterCannotDetermineExecutable": "無法判斷åµéŒ¯é…接器 '{0}' çš„å¯åŸ·è¡Œæª”。", "debugType": "組態的類型。", + "debugTypeNotRecognised": "無法辨識此åµéŒ¯é¡žåž‹.請確èªå·²æœ‰å®‰è£ä¸¦å•Ÿç”¨ç›¸å°æ‡‰çš„åµéŒ¯æ“´å……功能.", "node2NotSupported": "\"node2\" å·²ä¸å†æ”¯æ´ï¼Œè«‹æ”¹ç”¨ \"node\",並將 \"protocol\" 屬性設為 \"inspector\"。", "debugName": "組態的å稱; 出ç¾åœ¨å•Ÿå‹•çµ„態下拉å¼åŠŸèƒ½è¡¨ä¸­ã€‚", "debugRequest": "è¦æ±‚組態的類型。å¯ä»¥æ˜¯ [å•Ÿå‹•] 或 [附加]。", diff --git a/i18n/cht/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json b/i18n/cht/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json index 9c79dedc0ca..cc8a2f38620 100644 --- a/i18n/cht/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json @@ -4,6 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "previousEditPoint": "Emmet: 上一個編輯端點", - "nextEditPoint": "Emmet: 下一個編輯端點" + "previousEditPoint": "Emmet: å‰å¾€ä¸Šä¸€å€‹ç·¨è¼¯ç«¯é»ž", + "nextEditPoint": "Emmet: å‰å¾€ä¸‹ä¸€å€‹ç·¨è¼¯ç«¯é»ž" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json b/i18n/cht/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json index fa22b35c419..0766d1cdedb 100644 --- a/i18n/cht/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json @@ -9,5 +9,6 @@ "emmetPreferences": "喜好設定,用以修改æŸäº›å‹•ä½œçš„è¡Œç‚ºåŠ Emmet 的解æžç¨‹å¼ã€‚", "emmetSyntaxProfiles": "為指定的語法定義設定檔,或é€éŽç‰¹å®šè¦å‰‡ä½¿ç”¨è‡ªå·±çš„設定檔。", "emmetExclude": "ä¸æ‡‰å±•é–‹ Emmet 縮寫的語言陣列。", - "emmetExtensionsPath": "åŒ…å« Emmet 設定檔ã€ç¨‹å¼ç¢¼ç‰‡æ®µåŠåƒè€ƒçš„資料夾路徑" + "emmetExtensionsPath": "åŒ…å« Emmet 設定檔ã€ç¨‹å¼ç¢¼ç‰‡æ®µåŠåƒè€ƒçš„資料夾路徑", + "useNewEmmet": "試試所有 Emmet 功能的新 Emmet 模組 (最終會å–代舊的單一 Emmet 程å¼åº«)。" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json b/i18n/cht/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json index 2badec430e0..3d0e6b6a5b6 100644 --- a/i18n/cht/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json @@ -24,6 +24,10 @@ "default": "é è¨­", "debuggers": "åµéŒ¯å·¥å…· ({0})", "debugger name": "å稱", + "views": "ç€è¦½æ¬¡æ•¸ ({0})", + "view id": "識別碼", + "view name": "å稱", + "view location": "ä½ç½®", "themes": "佈景主題 ({0})", "JSON Validation": "JSON é©—è­‰ ({0})", "commands": "命令 ({0})", diff --git a/i18n/cht/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json b/i18n/cht/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json index 7e0eff0f087..dce745aeaf8 100644 --- a/i18n/cht/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json @@ -22,6 +22,8 @@ "disableGloballyAction": "æ°¸é ", "disableAction": "åœç”¨", "checkForUpdates": "查看是å¦æœ‰æ›´æ–°", + "enableAutoUpdate": "啟用自動更新延伸模組", + "disableAutoUpdate": "åœç”¨è‡ªå‹•æ›´æ–°å»¶ä¼¸æ¨¡çµ„", "updateAll": "更新所有延伸模組", "reloadAction": "é‡æ–°è¼‰å…¥", "postUpdateTooltip": "é‡æ–°è¼‰å…¥ä»¥æ›´æ–°", @@ -44,6 +46,8 @@ "showWorkspaceRecommendedExtensions": "顯示工作å€çš„建議擴充功能", "showRecommendedKeymapExtensions": "顯示建議的按éµå°æ‡‰", "showRecommendedKeymapExtensionsShort": "按éµå°æ‡‰", + "showLanguageExtensions": "顯示語言擴充功能", + "showLanguageExtensionsShort": "語言擴充功能", "configureWorkspaceRecommendedExtensions": "設定建議的延伸模組 (工作å€)", "ConfigureWorkspaceRecommendations.noWorkspace": "åªæœ‰åœ¨å·¥ä½œå€è³‡æ–™å¤¾ä¸­æ‰èƒ½ä½¿ç”¨å»ºè­°ã€‚", "OpenExtensionsFile.failed": "無法在 '.vscode' 資料夾 ({0}) 中建立 'extensions.json' 檔案。", @@ -51,5 +55,8 @@ "disableAll": "åœç”¨æ‰€æœ‰å·²å®‰è£çš„延伸模組", "disableAllWorkspace": "åœç”¨æ­¤å·¥ä½œå€çš„所有已安è£å»¶ä¼¸æ¨¡çµ„", "enableAll": "啟用所有已安è£çš„延伸模組", - "enableAllWorkspace": "啟用此工作å€çš„所有已安è£å»¶ä¼¸æ¨¡çµ„" + "enableAllWorkspace": "啟用此工作å€çš„所有已安è£å»¶ä¼¸æ¨¡çµ„", + "extensionButtonProminentBackground": "çªå‡ºçš„動作延伸模組按鈕背景色彩 (例如,[安è£] 按鈕)。", + "extensionButtonProminentForeground": "çªå‡ºçš„動作延伸模組按鈕å‰æ™¯è‰²å½© (例如,[安è£] 按鈕)。", + "extensionButtonProminentHoverBackground": "çªå‡ºçš„動作延伸模組按鈕背景暫留色彩 (例如,[安è£] 按鈕)。" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json b/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json index 7855f3a13f5..9e97614cd5e 100644 --- a/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json @@ -9,6 +9,8 @@ "neverShowAgain": "ä¸è¦å†é¡¯ç¤º", "close": "關閉", "workspaceRecommended": "此工作å€å…·æœ‰æ“´å……功能建議。", + "ignoreExtensionRecommendations": "是å¦ç•¥éŽæ‰€æœ‰å»ºè­°çš„擴充功能?", + "ignoreAll": "是,略éŽå…¨éƒ¨", "no": "å¦", "cancel": "å–消" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json b/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json index ee54fc14d14..c0f0b827558 100644 --- a/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json @@ -10,5 +10,6 @@ "extensions": "擴充功能", "view": "檢視", "extensionsConfigurationTitle": "擴充功能", - "extensionsAutoUpdate": "自動更新擴充功能" + "extensionsAutoUpdate": "自動更新擴充功能", + "extensionsIgnoreRecommendations": "忽略延伸模組建議" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 6394eecabd8..8c853f39a83 100644 --- a/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -4,8 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "disableOtherKeymapsConfirmation": "è¦åœç”¨å…¶ä»–按éµå°æ‡‰ ({0}),以é¿å…按éµç¹«çµé—œä¿‚é–“çš„è¡çªå—Ž?", "yes": "是", "no": "å¦", + "betterMergeDisabled": "ç›®å‰å·²å…§å»º Better Merge 延伸模組,安è£çš„延伸模組已åœç”¨ä¸¦ä¸”å¯ä»¥ç§»é™¤ã€‚", "uninstall": "解除安è£", "later": "ç¨å¾Œ" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/cht/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 5b044579208..777013462f0 100644 --- a/i18n/cht/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,6 +16,7 @@ "associations": "將檔案關è¯è¨­å®šç‚ºèªžè¨€ (例如 \"*.extension\": \"html\")。這些語言優先於已安è£èªžè¨€çš„é è¨­é—œè¯ã€‚", "encoding": "讀å–與寫入檔案時è¦ä½¿ç”¨çš„é è¨­å­—元集編碼。", "autoGuessEncoding": "如有啟用,將會在開啟檔案時,嘗試猜測字元集編碼", + "eol": "é è¨­çµå°¾æ–·è¡Œå­—å…ƒ.LF使用 \\n , CRLF使用\\r\\n ", "trimTrailingWhitespace": "若啟用,將在儲存檔案時修剪尾端空白。", "insertFinalNewline": "啟用時,請在儲存檔案時在其çµå°¾æ’入最後一個新行。", "files.autoSave.off": "已變更的檔案一律ä¸æœƒè‡ªå‹•å„²å­˜ã€‚", @@ -26,6 +27,7 @@ "autoSaveDelay": "控制è¦è‡ªå‹•å„²å­˜å·²è®Šæ›´ä¹‹æª”案å‰å¿…須經éŽçš„延é²æ™‚é–“ (毫秒)。僅當 'files.autoSave' 設為 \"{0}\" 時æ‰é©ç”¨ã€‚", "watcherExclude": "將檔案路徑的 Glob 模å¼è¨­å®šç‚ºå¾žæª”案監控排除。需è¦é‡æ–°å•Ÿå‹•æ‰èƒ½è®Šæ›´æ­¤è¨­å®šã€‚ç•¶æ‚¨ç™¼ç¾ Code åœ¨å•Ÿå‹•æ™‚ä½¿ç”¨å¤§é‡ CPU 時間時,å¯ä»¥æŽ’除較大的資料夾以é™ä½Žåˆå§‹è² è¼‰ã€‚", "hotExit.off": "åœç”¨ Hot Exit。", + "hotExit.onExit": "Hot Exit 將會在關閉應用程å¼æ™‚觸發,也就是在 Windows/Linux 上關閉上一個視窗,或是觸發 workbench.action.quit 命令 (命令é¸æ“‡å€ã€æŒ‰éµç¹«çµé—œä¿‚ã€åŠŸèƒ½è¡¨) 時觸發。具有備份的所有視窗都會在下次啟動時還原。", "hotExit": "控制是å¦è®“ä¸åŒå·¥ä½œéšŽæ®µè¨˜ä½æœªå„²å­˜çš„檔案,並å…許在çµæŸç·¨è¼¯å™¨æ™‚è·³éŽå„²å­˜æ示。", "defaultLanguage": "指派給新檔案的é è¨­èªžè¨€æ¨¡å¼ã€‚", "editorConfigurationTitle": "編輯器", diff --git a/i18n/cht/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json b/i18n/cht/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json index daa9489ee2b..6083b4139cc 100644 --- a/i18n/cht/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json @@ -5,7 +5,5 @@ // Do not edit this file. It is machine generated. { "explorerSection": "檔案總管å€æ®µ", - "noWorkspace": "沒有開啟的資料夾", - "noWorkspaceHelp": "您尚未開啟資料夾。", "openFolder": "開啟資料夾" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json b/i18n/cht/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json index bb6c9f7b0a8..4279cc7e911 100644 --- a/i18n/cht/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json @@ -4,8 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "openEditosrSection": "開放å¼ç·¨è¼¯å™¨å€æ®µ", "openEditors": "已開啟的編輯器", + "openEditosrSection": "開放å¼ç·¨è¼¯å™¨å€æ®µ", "treeAriaLabel": "開啟的編輯器: 使用中檔案的清單", "dirtyCounter": "{0} 未儲存" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/cht/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index f36b3a04dba..2699d76ae09 100644 --- a/i18n/cht/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -9,5 +9,7 @@ "prof.message": "å·²æˆåŠŸå»ºç«‹è¨­å®šæª”。", "prof.detail": "請建立å•é¡Œï¼Œä¸¦æ‰‹å‹•é™„加下列檔案:\n{0}", "prof.restartAndFileIssue": "建立å•é¡Œä¸¦é‡æ–°å•Ÿå‹•", - "prof.restart": "é‡æ–°å•Ÿå‹•" + "prof.restart": "é‡æ–°å•Ÿå‹•", + "prof.thanks": "æ„Ÿè¬æ‚¨çš„å”助", + "prof.detail.restart": "需è¦é‡æ–°å•Ÿå‹•æ‰èƒ½å¤ ç¹¼çºŒä½¿ç”¨'{0}‘.å†æ¬¡æ„Ÿè¬æ‚¨çš„回饋." } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/cht/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json index 799796b51ff..96477e8cd28 100644 --- a/i18n/cht/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -5,5 +5,7 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.start": "定義按éµç¹«çµé—œä¿‚", - "defineKeybinding.kbLayoutErrorMessage": "您無法在目å‰çš„éµç›¤é…置下產生此按éµçµ„åˆã€‚" + "defineKeybinding.kbLayoutErrorMessage": "您無法在目å‰çš„éµç›¤é…置下產生此按éµçµ„åˆã€‚", + "defineKeybinding.kbLayoutLocalAndUSMessage": "**{0}**é‡å°æ‚¨ç›®å‰çš„按éµé…ç½®(**{1}**為美國標準)", + "defineKeybinding.kbLayoutLocalMessage": "**{0}**é‡å°æ‚¨ç›®å‰çš„éµç›¤é…ç½®" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json b/i18n/cht/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json index d55154b3d42..7179fe0d56b 100644 --- a/i18n/cht/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json @@ -4,6 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "errorInvalidConfiguration": "無法寫入設定.請開啟使用者設定並修正檔案中的錯誤/警告後å†è©¦ä¸€æ¬¡.", "editTtile": "編輯", "replaceDefaultValue": "在設定中å–代", "copyDefaultValue": "複製到設定", diff --git a/i18n/cht/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json b/i18n/cht/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json index 57c6be16105..6f93d38ba4b 100644 --- a/i18n/cht/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "showTriggerActions": "顯示所有命令", + "showCommands.label": "命令é¸æ“‡å€...", "entryAriaLabelWithKey": "{0}ã€{1}ã€å‘½ä»¤", "entryAriaLabel": "{0},命令", "canNotRun": "無法從這裡執行命令 '{0}'。", diff --git a/i18n/cht/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json b/i18n/cht/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json new file mode 100644 index 00000000000..c58e0321bac --- /dev/null +++ b/i18n/cht/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "relaunchMessage": "設定已經變更,必須é‡æ–°å•Ÿå‹•æ‰æœƒç”Ÿæ•ˆã€‚", + "relaunchDetail": "請按 [é‡æ–°å•Ÿå‹•] 按鈕以é‡æ–°å•Ÿå‹• {0} 並啟用設定。", + "restart": "é‡æ–°å•Ÿå‹•" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/cht/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json index 8b6ad71cd4e..eea295d4066 100644 --- a/i18n/cht/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "editorGutterModifiedBackground": "修改中的行於編輯器邊框的背景色彩", + "editorGutterAddedBackground": "新增後的行於編輯器邊框的背景色彩", + "editorGutterDeletedBackground": "刪除後的行於編輯器邊框的背景色彩" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json b/i18n/cht/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json index 0dacece4839..0780f0f62bd 100644 --- a/i18n/cht/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json @@ -6,5 +6,7 @@ { "searchMatches": "找到 {0} 個相符", "searchMatch": "找到 {0} 個相符", - "fileMatchAriaLabel": "資料夾 {2} 的檔案 {1} 中有 {0} 個相符,æœå°‹çµæžœ" + "fileMatchAriaLabel": "資料夾 {2} 的檔案 {1} 中有 {0} 個相符,æœå°‹çµæžœ", + "replacePreviewResultAria": "根據文字({3})在({2})欄ä½åˆ—表中將({1})替代為文字{{0}}", + "searchResultAria": "根據文字({2})並在({1})欄ä½åˆ—表中找到符åˆ({0})çš„é …ç›®" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json b/i18n/cht/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json index 4cb9c1367ee..2789a5e845e 100644 --- a/i18n/cht/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json @@ -9,5 +9,6 @@ "vscode.extension.contributes.snippets-path": "程å¼ç¢¼ç‰‡æ®µæª”案的路徑。此路徑是擴充功能資料夾的相å°è·¯å¾‘,而且一般會以 './snippets/' 開頭。", "invalid.language": "`contributes.{0}.language` 中的ä¸æ˜Žèªžè¨€ã€‚æ供的值: {1}", "invalid.path.0": "`contributes.{0}.path` 中的é æœŸå­—串。æ供的值: {1}", - "invalid.path.1": "è¦åŒ…å«åœ¨æ“´å……功能資料夾 ({2}) 中的é æœŸ `contributes.{0}.path` ({1})。這å¯èƒ½æœƒä½¿æ“´å……功能無法移æ¤ã€‚" + "invalid.path.1": "è¦åŒ…å«åœ¨æ“´å……功能資料夾 ({2}) 中的é æœŸ `contributes.{0}.path` ({1})。這å¯èƒ½æœƒä½¿æ“´å……功能無法移æ¤ã€‚", + "badVariableUse": "程å¼ç¢¼ç‰‡æ®µ \"{0}\" 很å¯èƒ½æœƒæ··æ·† snippet-variables åŠ snippet-placeholders。如需詳細資料,請åƒé–± https://code.visualstudio.com/docs/editor/userdefinedsnippets#_snippet-syntax。" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json b/i18n/cht/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json index 79eb6e8c71c..8db84c0d3eb 100644 --- a/i18n/cht/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json @@ -11,6 +11,6 @@ "snippetSchema.json.default": "空白程å¼ç¢¼ç‰‡æ®µ", "snippetSchema.json": "使用者程å¼ç¢¼ç‰‡æ®µçµ„æ…‹", "snippetSchema.json.prefix": "在 Intellisense 中é¸å–程å¼ç¢¼ç‰‡æ®µæ™‚è¦ä½¿ç”¨çš„å‰ç½®è©ž", - "snippetSchema.json.body": "程å¼ç¢¼ç‰‡æ®µå…§å®¹ã€‚è«‹é‡å°è®Šæ•¸ä½¿ç”¨ '${id}'ã€'${id:label}'ã€'${1:label}',並é‡å°æ¸¸æ¨™ä½ç½®ä½¿ç”¨ '$0'ã€'$1'", + "snippetSchema.json.body": "程å¼ç¢¼ç‰‡æ®µå…§å®¹ã€‚請使用 '$1', '${1:defaultText}' 以定義游標ä½ç½®ï¼Œä¸¦ä½¿ç”¨ '$0' 定義最終游標ä½ç½®ã€‚å°‡ '${varName}' and '${varName:defaultText}' æ’入變數值,例如 'This is file: $TM_FILENAME'。", "snippetSchema.json.description": "程å¼ç¢¼ç‰‡æ®µæ述。" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json b/i18n/cht/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json new file mode 100644 index 00000000000..a74cdd763fc --- /dev/null +++ b/i18n/cht/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "helpUs": "å”助我們改善{0}", + "takeShortSurvey": "填寫簡短調查å•å·", + "remindLater": "ç¨å¾Œå†æ醒我", + "neverAgain": "ä¸è¦å†é¡¯ç¤º" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json b/i18n/cht/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json new file mode 100644 index 00000000000..260deed4c1d --- /dev/null +++ b/i18n/cht/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "surveyQuestion": "您願æ„填寫簡短的æ„見å應å•å·å—Ž?", + "takeSurvey": "填寫å•å·", + "remindLater": "ç¨å¾Œå†æ醒我", + "neverAgain": "ä¸è¦å†é¡¯ç¤º" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json b/i18n/cht/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json new file mode 100644 index 00000000000..8ccb1a38284 --- /dev/null +++ b/i18n/cht/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noTasksMatching": "沒有工作相符" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/cht/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index e35a0884650..6a8c26e1e14 100644 --- a/i18n/cht/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0},工作" + "entryAriaLabel": "{0},工作", + "customizeTask": "自訂任務" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json b/i18n/cht/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json new file mode 100644 index 00000000000..8ccb1a38284 --- /dev/null +++ b/i18n/cht/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noTasksMatching": "沒有工作相符" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/cht/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json index e2b27a208b0..9320c66c86f 100644 --- a/i18n/cht/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -12,5 +12,6 @@ "ConfigurationParser.invalidVaraibleReference": "錯誤: problemMatcher åƒè€ƒç„¡æ•ˆ: {0}\n", "ConfigurationParser.noTaskName": "錯誤: 工作必須æä¾› taskName 屬性。å³å°‡å¿½ç•¥æ­¤å·¥ä½œã€‚\n{0}\n", "taskConfiguration.shellArgs": "警告: 工作 '{0}' 是殼層命令,但命令å稱或其中一個引數有的未逸出的空格。若è¦ç¢ºä¿å‘½ä»¤åˆ—正確引述,請將引數åˆä½µåˆ°å‘½ä»¤ä¸­ã€‚", + "taskConfiguration.noCommandOrDependsOn": "錯誤: 工作 '{0}' 未指定命令與 dependsOn 屬性。將會略éŽè©²å·¥ä½œã€‚其定義為: \n{1}", "taskConfiguration.noCommand": "錯誤: 工作 '{0}' 未定義命令。å³å°‡ç•¥éŽè©²å·¥ä½œã€‚其定義為:\n{1}" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json b/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json index a08f7bd95bc..44fe783df83 100644 --- a/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json @@ -7,6 +7,7 @@ "JsonSchema.options": "其他命令é¸é …", "JsonSchema.options.cwd": "所執行程å¼æˆ–指令碼的目å‰å·¥ä½œç›®éŒ„。如果çœç•¥ï¼Œå‰‡æœƒä½¿ç”¨ Code çš„ç›®å‰å·¥ä½œå€æ ¹ç›®éŒ„。", "JsonSchema.options.env": "所執行程å¼æˆ–殼層的環境。如果çœç•¥ï¼Œå‰‡æœƒä½¿ç”¨çˆ¶è™•ç†åºçš„環境。", + "JsonSchema.shellConfiguration": "設定è¦ä½¿ç”¨çš„殼層。", "JsonSchema.shell.executable": "è¦ä½¿ç”¨çš„殼層。", "JsonSchema.shell.args": "殼層引數。", "JsonSchema.command": "è¦åŸ·è¡Œçš„命令。å¯ä»¥æ˜¯å¤–部程å¼æˆ–殼層命令。", diff --git a/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json b/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json index b729447e979..fa2e875a18e 100644 --- a/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json @@ -5,6 +5,8 @@ // Do not edit this file. It is machine generated. { "JsonSchema.version": "組態的版本號碼", + "JsonSchema._runner": "執行器已çµæŸæ”¯æ´.è«‹åƒè€ƒå®˜æ–¹åŸ·è¡Œå™¨å±¬æ€§", + "JsonSchema.runner": "定義工作是å¦ä½œç‚ºè™•ç†åºåŸ·è¡Œï¼Œä»¥åŠè¼¸å‡ºæœƒé¡¯ç¤ºåœ¨è¼¸å‡ºè¦–窗或終端機內。", "JsonSchema.windows": "Windows 特定命令組態", "JsonSchema.mac": "Mac 特定命令組態", "JsonSchema.linux": "Linux 特定命令組態", diff --git a/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json index b24501dac4e..ad9741c08b9 100644 --- a/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -7,6 +7,10 @@ "JsonSchema.shell": "指定此命令是殼層命令或外部程å¼ã€‚如果çœç•¥ï¼Œé è¨­ç‚º False。", "JsonSchema.tasks.dependsOn.string": "此工作相ä¾çš„å¦ä¸€å€‹å·¥ä½œã€‚", "JsonSchema.tasks.dependsOn.array": "此工作相ä¾çš„其他工作。", + "JsonSchema.tasks.group": "請定義此工作所屬的執行群組。若是çœç•¥æ­¤æ­¥é©Ÿï¼Œå·¥ä½œæœƒå±¬æ–¼æ²’有群組。", + "JsonSchema.tasks.type": "定義工作是作為處ç†åºæˆ–殼層中的命令執行。é è¨­ç‚ºè™•ç†åºã€‚", + "JsonSchema.version": "組態版本號碼", + "JsonSchema.tasks.customize": "è¦è‡ªè¨‚çš„å·²æ供工作。", "JsonSchema.windows": "Windows 特定命令組態", "JsonSchema.mac": "Mac 特定命令組態", "JsonSchema.linux": "Linux 特定命令組態" diff --git a/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json b/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json index c0537ee4cdf..9604a31ff96 100644 --- a/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json @@ -22,7 +22,8 @@ "TaskService.noBuildTask": "未定義任何建置工作。請使用 'isBuildCommand' 標記 tasks.json 檔案中的工作。", "TaskService.noTestTask": "未定義任何建置工作。請使用 'isTestCommand' 標記 tasks.json 檔案中的工作。", "TaskServer.noTask": "找ä¸åˆ°æ‰€è¦æ±‚è¦åŸ·è¡Œçš„工作 {0}。", - "TaskSystem.activeSame": "工作已在使用中並處於監看模å¼ã€‚è‹¥è¦çµ‚止工作,請使用 F1 > [終止工作]", + "customizeParseErrors": "當å‰çš„工作組態存在錯誤.請更正錯誤å†åŸ·è¡Œå·¥ä½œ.", + "moreThanOneBuildTask": "定義了很多建置工作於tasks.json.執行第一個.", "TaskSystem.active": "已有工作在執行。請先終止該工作,然後å†åŸ·è¡Œå…¶ä»–工作。", "TaskSystem.restartFailed": "無法終止å†é‡æ–°å•Ÿå‹•å·¥ä½œ {0}", "TaskSystem.configurationErrors": "錯誤: æ供的工作組態具有驗證錯誤而無法使用。請先更正這些錯誤。", diff --git a/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json b/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json index 6fbf828e69e..871f4fbea5a 100644 --- a/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json @@ -6,5 +6,7 @@ { "TerminalTaskSystem.unknownError": "執行工作時發生ä¸æ˜ŽéŒ¯èª¤ã€‚如需詳細資訊,請åƒé–±å·¥ä½œè¼¸å‡ºè¨˜éŒ„檔。", "TerminalTaskSystem.terminalName": "工作 - {0}", - "TerminalTaskSystem": "無法在 UNC ç£ç¢Ÿæ©Ÿä¸ŠåŸ·è¡Œæ®¼å±¤å‘½ä»¤ã€‚" + "reuseTerminal": "工作將被é‡æ–°å•Ÿç”¨.按任æ„éµé—œé–‰.", + "TerminalTaskSystem": "無法在 UNC ç£ç¢Ÿæ©Ÿä¸ŠåŸ·è¡Œæ®¼å±¤å‘½ä»¤ã€‚", + "unkownProblemMatcher": "å•é¡Œæ¯”å°å™¨ {0} 無法解æžï¼Œæ¯”å°å™¨å°‡äºˆå¿½ç•¥ã€‚" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json b/i18n/cht/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json index 14a1145483a..a61b95cb117 100644 --- a/i18n/cht/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json @@ -7,5 +7,6 @@ "TaskRunnerSystem.unknownError": "執行工作時發生ä¸æ˜ŽéŒ¯èª¤ã€‚如需詳細資訊,請åƒé–±å·¥ä½œè¼¸å‡ºè¨˜éŒ„檔。", "TaskRunnerSystem.watchingBuildTaskFinished": "\n監看建置工作已完æˆã€‚", "TaskRunnerSystem.childProcessError": "Failed to launch external program {0} {1}.", - "TaskRunnerSystem.cancelRequested": "\n根據使用者è¦æ±‚已終止工作 '{0}'。" + "TaskRunnerSystem.cancelRequested": "\n根據使用者è¦æ±‚已終止工作 '{0}'。", + "unkownProblemMatcher": "å•é¡Œæ¯”å°å™¨ {0} 無法解æžï¼Œæ¯”å°å™¨å°‡äºˆå¿½ç•¥ã€‚" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json b/i18n/cht/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json index 1e92f6894ee..88c33527509 100644 --- a/i18n/cht/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json @@ -8,6 +8,7 @@ "workbench.action.terminal.kill": "終止使用中的終端機執行個體", "workbench.action.terminal.kill.short": "終止終端機", "workbench.action.terminal.copySelection": "複製é¸å–é …ç›®", + "workbench.action.terminal.selectAll": "å…¨é¸", "workbench.action.terminal.new": "建立新的整åˆå¼çµ‚端機", "workbench.action.terminal.new.short": "新增終端機", "workbench.action.terminal.focus": "èšç„¦çµ‚端機", @@ -26,5 +27,8 @@ "workbench.action.terminal.scrollUp": "å‘上æ²å‹• (è¡Œ)", "workbench.action.terminal.scrollUpPage": "å‘上æ²å‹• (é )", "workbench.action.terminal.scrollToTop": "æ²å‹•è‡³é ‚端", - "workbench.action.terminal.clear": "清除" + "workbench.action.terminal.clear": "清除", + "workbench.action.terminal.allowWorkspaceShell": "å…許工作å€å¤–觀é…ç½®", + "workbench.action.terminal.disallowWorkspaceShell": "ä¸å…許工作å€å¤–觀設置", + "workbench.action.terminal.rename": "é‡æ–°å‘½å" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json b/i18n/cht/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json index d6c50f67f68..6016a0077c1 100644 --- a/i18n/cht/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json @@ -4,5 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "terminal.background": "終端機的背景色彩,å…許終端機和é¢æ¿çš„色彩ä¸åŒã€‚", + "terminal.foreground": "終端機的å‰æ™¯è‰²å½©ã€‚", "terminal.ansiColor": "終端機中的 '{0}' ANSI 色彩。" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json b/i18n/cht/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json new file mode 100644 index 00000000000..f2ff92bce07 --- /dev/null +++ b/i18n/cht/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "label.find": "尋找", + "placeholder.find": "尋找", + "label.previousMatchButton": "上一個符åˆé …", + "label.nextMatchButton": "下一個相符項", + "label.closeButton": "關閉" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json b/i18n/cht/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json index d0d02ca0fc5..6ac7e3480a4 100644 --- a/i18n/cht/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json @@ -4,7 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "terminal.integrated.copySelection.noSelection": "無法在終端機沒有焦點時複製終端機é¸å–範åœ", "terminal.integrated.exitedWithCode": "終端機處ç†åºå·²çµ‚止,çµæŸä»£ç¢¼ç‚º: {0}", "terminal.integrated.waitOnExit": "按任æ„éµé—œé–‰çµ‚端機", "terminal.integrated.launchFailed": "無法啟動終端機處ç†åºå‘½ä»¤ `{0}{1}` (çµæŸä»£ç¢¼: {2})" diff --git a/i18n/cht/src/vs/workbench/parts/update/electron-browser/update.i18n.json b/i18n/cht/src/vs/workbench/parts/update/electron-browser/update.i18n.json index 942ed9430c3..763f5b45d61 100644 --- a/i18n/cht/src/vs/workbench/parts/update/electron-browser/update.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/update/electron-browser/update.i18n.json @@ -15,5 +15,18 @@ "license": "閱讀授權", "updateAvailable": "{0} é‡æ–°å•Ÿå‹•å¾Œå°‡æœƒæ›´æ–°ã€‚", "thereIsUpdateAvailable": "已有更新å¯ç”¨ã€‚", - "noUpdatesAvailable": "ç›®å‰æ²’有å¯ç”¨çš„更新。" + "noUpdatesAvailable": "ç›®å‰æ²’有å¯ç”¨çš„更新。", + "updateIsReady": "å¯ç”¨çš„æ›´æ–°", + "commandPalette": "命令é¸æ“‡å€...", + "settings": "設定", + "keyboardShortcuts": "éµç›¤å¿«é€Ÿéµ(&&K)", + "selectTheme.label": "色彩佈景主題", + "themes.selectIconTheme.label": "檔案圖示佈景主題", + "not available": "ç„¡å¯ç”¨æ›´æ–°", + "checkingForUpdates": "正在查看是å¦æœ‰æ›´æ–°...", + "DownloadUpdate": "下載å¯ç”¨æ›´æ–°", + "DownloadingUpdate": "正在下載更新...", + "InstallingUpdate": "正在安è£æ›´æ–°...", + "restartToUpdate": "é‡æ–°å•Ÿå‹•ä»¥æ›´æ–°...", + "checkForUpdates": "查看是å¦æœ‰æ›´æ–°..." } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/views/browser/views.i18n.json b/i18n/cht/src/vs/workbench/parts/views/browser/views.i18n.json new file mode 100644 index 00000000000..6894078d8f2 --- /dev/null +++ b/i18n/cht/src/vs/workbench/parts/views/browser/views.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "viewToolbarAriaLabel": "{0} 個動作" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json b/i18n/cht/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json new file mode 100644 index 00000000000..fcc72299d87 --- /dev/null +++ b/i18n/cht/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "requirearray": "項目必須為陣列", + "requirestring": "屬性 '{0}' 為強制項目且必須屬於 `string` é¡žåž‹", + "optstring": "屬性 `{0}` å¯ä»¥çœç•¥æˆ–必須屬於 `string` é¡žåž‹", + "vscode.extension.contributes.view.id": "檢視的識別碼。請使用此識別碼é€éŽ `vscode.window.registerTreeDataProviderForView` API 登錄資料æ供者。並藉由將 `onView:${id}` 事件登錄至 `activationEvents` 以觸發啟用您的延伸模組。", + "vscode.extension.contributes.view.name": "使用人性化顯示å稱.", + "vscode.extension.contributes.views": "æä¾›æ„見給編輯者", + "views.explorer": "檔案總管檢視", + "locationId.invalid": "`{0}`ä¸æ˜¯æœ‰æ•ˆçš„識別ä½ç½®" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json index 41c9f9e1a0d..440dfaba679 100644 --- a/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -14,6 +14,7 @@ "welcomePage.moreRecent": "更多...", "welcomePage.noRecentFolders": "沒有最近使用的資料夾", "welcomePage.help": "說明", + "welcomePage.keybindingsCheatsheet": "閱覽éµç›¤å¿«é€Ÿéµ", "welcomePage.introductoryVideos": "簡介影片", "welcomePage.productDocumentation": "產å“文件", "welcomePage.gitHubRepository": "GitHub 存放庫", @@ -21,6 +22,7 @@ "welcomePage.showOnStartup": "啟動時顯示歡迎é é¢", "welcomePage.customize": "自訂", "welcomePage.installExtensionPacks": "工具與語言", + "welcomePage.installExtensionPacksDescription": "安è£{0}與{1}的支æ´åŠŸèƒ½ã€‚", "welcomePage.moreExtensions": "更多", "welcomePage.installKeymapDescription": "安è£éµç›¤å¿«é€Ÿéµ", "welcomePage.installKeymapExtension": "安è£éµç›¤å¿«é€Ÿéµ{0}與{1}", @@ -29,7 +31,6 @@ "welcomePage.colorThemeDescription": "將編輯器åŠæ‚¨çš„程å¼ç¢¼è¨­å®šæˆæ‚¨å–œæ„›çš„外觀", "welcomePage.learn": "深入了解", "welcomePage.showCommands": "尋找åŠåŸ·è¡Œæ‰€æœ‰å‘½ä»¤", - "welcomePage.showCommandsDescription": "從控制å°å¿«é€Ÿå­˜å–åŠæœå°‹å‘½ä»¤ ({0})", "welcomePage.interfaceOverview": "介é¢æ¦‚觀", "welcomePage.interfaceOverviewDescription": "使用視覺覆疊效果強調顯示 UI 的主è¦å…ƒä»¶", "welcomePage.interactivePlayground": "Interactive Playground", diff --git a/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json b/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json index 2e0c06390e3..0b34cedf5f5 100644 --- a/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json @@ -4,7 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "workbenchConfigurationTitle": "工作å°", - "welcomePage.enabled": "若啟用,會在啟動時顯示歡迎é é¢ã€‚", "help": "說明" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 69d1bd41dad..815a7653f57 100644 --- a/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/cht/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -4,6 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "workbenchConfigurationTitle": "工作å°", + "welcomePage.enabled": "若啟用,會在啟動時顯示歡迎é é¢ã€‚", "welcomePage": "歡迎使用", "welcomePage.javaScript": "JavaScript", "welcomePage.typeScript": "TypeScript", @@ -13,13 +15,24 @@ "welcomePage.vim": "活力", "welcomePage.sublime": "壯麗", "welcomePage.atom": "Atom", + "welcomePage.extensionPackAlreadyInstalled": "支æ´åŠŸèƒ½{0}已被安è£ã€‚", + "welcomePage.willReloadAfterInstallingExtensionPack": "{0} 的其他支æ´å®‰è£å®Œæˆå¾Œï¼Œå°‡æœƒé‡æ–°è¼‰å…¥æ­¤è¦–窗。", + "welcomePage.installingExtensionPack": "æ­£åœ¨å®‰è£ {0} 的其他支æ´...", + "welcomePage.extensionPackNotFound": "找ä¸åˆ°ID為{1}çš„{0}支æ´åŠŸèƒ½.", "welcomePage.keymapAlreadyInstalled": "å·²å®‰è£ {0} éµç›¤å¿«é€Ÿéµã€‚", "welcomePage.willReloadAfterInstallingKeymap": "{0} éµç›¤å¿«é€Ÿéµå®‰è£å®Œæˆå¾Œï¼Œå°‡æœƒé‡æ–°è¼‰å…¥æ­¤è¦–窗。", "welcomePage.installingKeymap": "æ­£åœ¨å®‰è£ {0} éµç›¤å¿«é€Ÿéµ...", "welcomePage.keymapNotFound": "找ä¸åˆ°è­˜åˆ¥ç¢¼ç‚º {1} çš„ {0} éµç›¤å¿«é€Ÿéµã€‚", "welcome.title": "歡迎使用", + "welcomePage.openFolderWithPath": "é€éŽè·¯å¾‘ {1} 開啟資料夾 {0}", "welcomePage.extensionListSeparator": ",", - "welcomePage.installedExtension": "{0}(已安è£)", + "welcomePage.installKeymap": "å®‰è£ {0} 按éµå°æ‡‰", + "welcomePage.installExtensionPack": "å®‰è£ {0} 的其他支æ´", + "welcomePage.installedKeymap": "å·²å®‰è£ {0} 按éµå°æ‡‰", + "welcomePage.installedExtensionPack": "å·²å®‰è£ {0} 支æ´", "ok": "確定", - "cancel": "å–消" + "details": "詳細資料", + "cancel": "å–消", + "welcomePage.buttonBackground": "起始é é¢æŒ‰éˆ•çš„背景色彩.", + "welcomePage.buttonHoverBackground": "起始é é¢æš«ç•™æ–¼æŒ‰éˆ•çš„背景色彩" } \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json b/i18n/cht/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json index d1d07b14ebd..0121512656e 100644 --- a/i18n/cht/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json +++ b/i18n/cht/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json @@ -6,6 +6,7 @@ { "open": "開啟設定", "close": "關閉", + "saveAndRetry": "儲存設定並é‡å•Ÿ", "errorUnknownKey": "無法寫入組態檔 (ä¸æ˜Žçš„按éµ)", "errorInvalidTarget": "無法寫入組態檔 (目標無效)", "errorNoWorkspaceOpened": "無法寫入設定,因為沒有開啟資料夾,請開啟資料夾後å†è©¦ä¸€æ¬¡.", diff --git a/i18n/cht/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json b/i18n/cht/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json new file mode 100644 index 00000000000..e3e021a4254 --- /dev/null +++ b/i18n/cht/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "telemetryConfigurationTitle": "é™æ¸¬", + "telemetry.enableCrashReporting": "å…許將æ毀報告傳é€çµ¦ Microsoft。\næ­¤é¸é …需è¦é‡æ–°å•Ÿå‹•æ‰æœƒç”Ÿæ•ˆã€‚" +} \ No newline at end of file diff --git a/i18n/cht/src/vs/workbench/services/progress/browser/progressService2.i18n.json b/i18n/cht/src/vs/workbench/services/progress/browser/progressService2.i18n.json new file mode 100644 index 00000000000..6db7d6aae51 --- /dev/null +++ b/i18n/cht/src/vs/workbench/services/progress/browser/progressService2.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "progress.text": "{0} - {1}", + "progress.title": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/deu/extensions/git/package.i18n.json b/i18n/deu/extensions/git/package.i18n.json index 83830454714..1fe0fda130c 100644 --- a/i18n/deu/extensions/git/package.i18n.json +++ b/i18n/deu/extensions/git/package.i18n.json @@ -22,7 +22,7 @@ "command.commitStaged": "Commit bereitgestellt", "command.commitStagedSigned": "Bereitgestelltes committen (unterzeichnet)", "command.commitAll": "Commit für alle ausführen", - "command.commitAllSigned": "Alle committen (abgemeldet)", + "command.commitAllSigned": "Alle committen (unterzeichnet)", "command.undoCommit": "Letzten Commit rückgängig machen", "command.checkout": "Auschecken an...", "command.branch": "Branch erstellen...", @@ -32,7 +32,7 @@ "command.push": "Push", "command.pushTo": "Push zu...", "command.sync": "Synchronisierung", - "command.publish": "Veröffentlichen", + "command.publish": "Branch veröffentlichen", "command.showOutput": "Git-Ausgabe anzeigen", "config.enabled": "Gibt an, ob Git aktiviert ist.", "config.path": "Der Pfad zur ausführbaren Git-Datei.", @@ -44,5 +44,6 @@ "config.checkoutType": "Steuert, welcher Branchtyp beim Ausführen von \"Auschecken an...\" aufgelistet wird. \"Alle\" zeigt alle Verweise an, \"Lokal\" nur die lokalen Branches, \"Tags\" zeigt nur Tags an, und \"Remote\" zeigt nur Remotebranches an.", "config.ignoreLegacyWarning": "Ignoriert die Legacy-Git-Warnung.", "config.ignoreLimitWarning": "Ignoriert Warnung bei zu hoher Anzahl von Änderungen in einem Repository", + "config.defaultCloneDirectory": "Das Standard-Verzeichnis für einen Klon eines Git-Repositorys", "config.enableSmartCommit": "Alle Änderungen committen, wenn keine Änderungen bereitgestellt sind." } \ No newline at end of file diff --git a/i18n/deu/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/deu/extensions/merge-conflict/out/codelensProvider.i18n.json index 8b6ad71cd4e..278e924d5a5 100644 --- a/i18n/deu/extensions/merge-conflict/out/codelensProvider.i18n.json +++ b/i18n/deu/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -3,4 +3,9 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "acceptCurrentChange": "Aktuelle Änderung akzeptieren", + "acceptIncomingChange": "Eingehende Änderung akzeptieren", + "acceptBothChanges": "Beide Änderungen akzeptieren", + "compareChanges": "Änderungen vergleichen" +} \ No newline at end of file diff --git a/i18n/deu/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/deu/extensions/merge-conflict/out/commandHandler.i18n.json index f18cf168246..c33f0f8ae6c 100644 --- a/i18n/deu/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/deu/extensions/merge-conflict/out/commandHandler.i18n.json @@ -4,6 +4,9 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "cursorNotInConflict": "Der Editor-Cursor ist nicht innerhalb eines Mergingkonflikts", + "compareChangesTitle": "{0}: Aktuelle Änderungen ⟷ Eingehende Änderungen", + "cursorOnSplitterRange": "Der Editor-Cursor ist innerhalb der Mergingkonfliktaufteilung, verschieben Sie ihn entweder in den Block \"aktuell\" oder \"eingehend\".", "noConflicts": "Keine Merge-Konflikte in dieser Datei gefunden", "noOtherConflictsInThisFile": "Keine weiteren Merge-Konflikte in dieser Datei" } \ No newline at end of file diff --git a/i18n/deu/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/deu/extensions/merge-conflict/out/mergeDecorator.i18n.json index 8b6ad71cd4e..5ef895aeb90 100644 --- a/i18n/deu/extensions/merge-conflict/out/mergeDecorator.i18n.json +++ b/i18n/deu/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "currentChange": "(Aktuelle Änderung)", + "incomingChange": "(Eingehende Änderung)" +} \ No newline at end of file diff --git a/i18n/deu/extensions/merge-conflict/package.i18n.json b/i18n/deu/extensions/merge-conflict/package.i18n.json index 0875e460a99..5bbe54989dc 100644 --- a/i18n/deu/extensions/merge-conflict/package.i18n.json +++ b/i18n/deu/extensions/merge-conflict/package.i18n.json @@ -5,6 +5,16 @@ // Do not edit this file. It is machine generated. { "command.category": "Merge-Konflikt", + "command.accept.all-incoming": "Alle eingehenden akzeptieren", + "command.accept.all-both": "Alle beide akzeptieren", + "command.accept.current": "Aktuelles akzeptieren", + "command.accept.incoming": "Eingehendes akzeptieren", + "command.accept.selection": "Auswahl akzeptieren", "command.accept.both": "Beides akzeptieren", - "config.title": "Merge-Konflikt" + "command.next": "Nächster Konflikt", + "command.previous": "Vorheriger Konflikt", + "command.compare": "Aktuellen Konflikt vergleichen", + "config.title": "Merge-Konflikt", + "config.codeLensEnabled": "CodeLens-Mergingkonfliktblock im Editor aktivieren/deaktivieren", + "config.decoratorsEnabled": "Mergingkonflikt-Decorators im Editor aktivieren/deaktivieren" } \ No newline at end of file diff --git a/i18n/deu/extensions/typescript/out/features/bufferSyncSupport.i18n.json b/i18n/deu/extensions/typescript/out/features/bufferSyncSupport.i18n.json index 055c93e97a3..b8f60f73f8b 100644 --- a/i18n/deu/extensions/typescript/out/features/bufferSyncSupport.i18n.json +++ b/i18n/deu/extensions/typescript/out/features/bufferSyncSupport.i18n.json @@ -4,7 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "versionMismatch": "Versionskonflikt zwischen dem globalen TSC ({0}) und dem Sprachdienst von VS Code ({1}). Dies kann zu Kompilierungsfehlern aufgrund von Inkonsistenzen führen.", "moreInformation": "Weitere Informationen", "doNotCheckAgain": "Nicht erneut überprüfen", "close": "Schließen", diff --git a/i18n/deu/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json b/i18n/deu/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json index 8b6ad71cd4e..171e5c786af 100644 --- a/i18n/deu/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json +++ b/i18n/deu/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "ts-check": "Aktiviert die Semantiküberprüfung in einer JavaScript-Datei. Muss sich oben in einer Datei befinden.", + "ts-nocheck": "Deaktiviert die Semantiküberprüfung in einer JavaScript-Datei. Muss sich oben in einer Datei befinden.", + "ts-ignore": "Unterdrückt @ts-check-Fehler in der nächsten Zeile einer Datei." +} \ No newline at end of file diff --git a/i18n/deu/extensions/typescript/out/utils/projectStatus.i18n.json b/i18n/deu/extensions/typescript/out/utils/projectStatus.i18n.json index 2ec9b6aab9a..22d044da619 100644 --- a/i18n/deu/extensions/typescript/out/utils/projectStatus.i18n.json +++ b/i18n/deu/extensions/typescript/out/utils/projectStatus.i18n.json @@ -6,7 +6,6 @@ { "hintExclude": "Um die JavaScript/TypeScript-Sprachfunktionen für das gesamte Projekt zu aktivieren, schließen Sie Ordner mit vielen Dateien aus. Beispiel: {0}", "hintExclude.generic": "Um JavaScript/TypeScript-Sprachfunktionen für das gesamte Projekt zu aktivieren, schließen Sie große Ordner mit Quelldateien aus, an denen Sie nicht arbeiten.", - "open": "Auszuschließende Elemente konfigurieren", "large.label": "Auszuschließende Elemente konfigurieren", "hintExclude.tooltip": "Um JavaScript/TypeScript-Sprachfunktionen für das gesamte Projekt zu aktivieren, schließen Sie große Ordner mit Quelldateien aus, an denen Sie nicht arbeiten." } \ No newline at end of file diff --git a/i18n/deu/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/deu/extensions/typescript/out/utils/typingsStatus.i18n.json index 6d936266697..1f64e53eff2 100644 --- a/i18n/deu/extensions/typescript/out/utils/typingsStatus.i18n.json +++ b/i18n/deu/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "installingPackages": "Daten werden zum Optimieren von TypeScript IntelliSense abgerufen", + "typesInstallerInitializationFailed.title": "Typisierungsdateien für JavaScript-Sprachfunktionen konnten nicht installiert werden. Stellen Sie sicher, das NPM installiert ist, oder konfigurieren Sie \"typescript.npm\" in Ihren Benutzereinstellungen.", "typesInstallerInitializationFailed.moreInformation": "Weitere Informationen", "typesInstallerInitializationFailed.doNotCheckAgain": "Nicht erneut überprüfen", "typesInstallerInitializationFailed.close": "Schließen" diff --git a/i18n/deu/extensions/typescript/package.i18n.json b/i18n/deu/extensions/typescript/package.i18n.json index 451b77c6fa5..86ef4eb0ea4 100644 --- a/i18n/deu/extensions/typescript/package.i18n.json +++ b/i18n/deu/extensions/typescript/package.i18n.json @@ -13,7 +13,6 @@ "typescript.check.tscVersion": "Ãœberprüfen, ob sich ein global installierter TypeScript-Compiler (z. B. tsc) vom verwendeten TypeScript-Sprachdienst unterscheidet.", "typescript.tsserver.log": "Aktiviert die Protokollierung des TS-Servers in eine Datei. Mithilfe der Protokolldatei lassen sich Probleme beim TS-Server diagnostizieren. Die Protokolldatei kann Dateipfade, Quellcode und weitere potenziell sensible Informationen aus Ihrem Projekt enthalten.", "typescript.tsserver.trace": "Aktiviert die Ablaufverfolgung von an den TS-Server gesendeten Nachrichten. Mithilfe der Ablaufverfolgung lassen sich Probleme beim TS-Server diagnostizieren. Die Ablaufverfolgung kann Dateipfade, Quellcode und weitere potenziell sensible Informationen aus Ihrem Projekt enthalten.", - "typescript.tsserver.experimentalAutoBuild": "Ermöglicht experimentelle automatische Buildvorgänge. Erfordert Version 1.9 dev oder 2.x tsserver sowie einen Neustart von VS Code nach der Änderung.", "typescript.validate.enable": "TypeScript-Ãœberprüfung aktivieren/deaktivieren.", "typescript.format.enable": "Standardmäßigen TypeScript-Formatierer aktivieren/deaktivieren.", "javascript.format.enable": "Standardmäßigen JavaScript-Formatierer aktivieren/deaktivieren.", @@ -33,10 +32,16 @@ "javascript.validate.enable": "JavaScript-Ãœberprüfung aktivieren/deaktivieren.", "typescript.goToProjectConfig.title": "Zur Projektkonfiguration wechseln", "javascript.goToProjectConfig.title": "Zur Projektkonfiguration wechseln", + "javascript.referencesCodeLens.enabled": "Aktiviert oder deaktiviert CodeLens-Verweise in JavaScript Dateien. Erfordert TypeScript 2.0.6 oder höher.", + "typescript.referencesCodeLens.enabled": "Aktiviert oder deaktiviert CodeLens-Verweise in TypeScript Dateien. Erfordert TypeScript 2.0.6 oder höher.", "typescript.implementationsCodeLens.enabled": "Aktiviert oder deaktiviert CodeLens-Implementierungen. Erfordert TypeScript 2.2.0 oder höher.", "typescript.openTsServerLog.title": "TS Server-Protokolldatei öffnen", "typescript.restartTsServer": "TS Server neu starten", "typescript.selectTypeScriptVersion.title": "TypeScript-Version wählen", "jsDocCompletion.enabled": "Automatische JSDoc-Kommentare aktivieren/deaktivieren", - "javascript.implicitProjectConfig.checkJs": "Aktiviert/deaktiviert die Semantikprüfung bei JavaScript-Dateien. Diese Einstellung wird von vorhandenen \"jsconfig.json\"- oder \"tsconfig.json\"-Dateien außer Kraft gesetzt. Erfordert TypeScript 2.3.1 oder höher." + "javascript.implicitProjectConfig.checkJs": "Aktiviert/deaktiviert die Semantikprüfung bei JavaScript-Dateien. Diese Einstellung wird von vorhandenen \"jsconfig.json\"- oder \"tsconfig.json\"-Dateien außer Kraft gesetzt. Erfordert TypeScript 2.3.1 oder höher.", + "typescript.npm": "Gibt den Pfad zur ausführbaren NPM-Datei an, die für die automatische Typerfassung verwendet wird. Hierfür ist TypeScript 2.3.4 oder höher erforderlich.", + "typescript.check.npmIsInstalled": "Ãœberprüfen Sie, ob NPM für die automatische Typerfassung installiert ist.", + "javascript.nameSuggestions": "Das Einbeziehen eindeutiger Namen von der Datei in der JavaScript-Vorschlagsliste aktivieren/deaktivieren.", + "typescript.tsc.autoDetect": "Steuert, ob die automatische Erkennung von tsc-Tasks aktiviert oder deaktiviert ist.\n" } \ No newline at end of file diff --git a/i18n/deu/src/vs/base/common/errorMessage.i18n.json b/i18n/deu/src/vs/base/common/errorMessage.i18n.json index 4bda5bf72a2..70a2d548425 100644 --- a/i18n/deu/src/vs/base/common/errorMessage.i18n.json +++ b/i18n/deu/src/vs/base/common/errorMessage.i18n.json @@ -13,6 +13,5 @@ "error.connection.unknown": "Es ist ein unbekannter Verbindungsfehler aufgetreten. Entweder besteht keine Internetverbindung mehr, oder der verbundene Server ist offline.", "stackTrace.format": "{0}: {1}", "error.defaultMessage": "Ein unbekannter Fehler ist aufgetreten. Weitere Details dazu finden Sie im Protokoll.", - "nodeExceptionMessage": "Systemfehler ({0})", "error.moreErrors": "{0} ({1} Fehler gesamt)" } \ No newline at end of file diff --git a/i18n/deu/src/vs/base/common/keybindingLabels.i18n.json b/i18n/deu/src/vs/base/common/keybindingLabels.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/deu/src/vs/base/common/keybindingLabels.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/deu/src/vs/code/electron-main/menus.i18n.json b/i18n/deu/src/vs/code/electron-main/menus.i18n.json index 739090b7521..40280594bf9 100644 --- a/i18n/deu/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/deu/src/vs/code/electron-main/menus.i18n.json @@ -55,6 +55,9 @@ "miShowEmmetCommands": "E&&mmet...", "miToggleLineComment": "Zeilenkommen&&tar umschalten", "miToggleBlockComment": "&&Blockkommentar umschalten", + "miMultiCursorAlt": "Verwenden Sie Alt+Mausklick für Multi-Cursor", + "miMultiCursorCmd": "Verwenden Sie Befehlstaste+Mausklick für Multi-Cursor", + "miMultiCursorCtrl": "Verwenden Sie STRG+Mausklick für Multi-Cursor", "miInsertCursorAbove": "Cursor oberh&&alb hinzufügen", "miInsertCursorBelow": "Cursor unterhal&&b hinzufügen", "miInsertCursorAtEndOfEachLineSelected": "C&&ursor an Zeilenenden hinzufügen", @@ -70,6 +73,7 @@ "miSmartSelectShrink": "Au&&swahl verkleinern", "miViewExplorer": "&&Explorer", "miViewSearch": "&&Suchen", + "miViewSCM": "S&&CM", "miViewDebug": "&&Debuggen", "miViewExtensions": "E&&xtensions", "miToggleOutput": "&&Ausgabe", @@ -114,6 +118,8 @@ "miGotoSymbolInFile": "Gehe zu &&Symbol in Datei...", "miGotoSymbolInWorkspace": "Zu Symbol im &&Arbeitsbereich wechseln...", "miGotoDefinition": "Gehe &&zu Definition", + "miGotoTypeDefinition": "Wechsle zu &&Typdefinition", + "miGotoImplementation": "Wechsle zur &&Implementierung", "miGotoLine": "Gehe zu &&Zeile...", "miStartDebugging": "&&Debugging starten", "miStartWithoutDebugging": "&&Ohne Debugging starten", @@ -130,16 +136,17 @@ "miColumnBreakpoint": "S&&paltenhaltepunkt", "miFunctionBreakpoint": "&&Funktionshaltepunkt...", "miNewBreakpoint": "&&Neuer Haltepunkt", + "miEnableAllBreakpoints": "Alle Haltepunkte aktivieren", "miDisableAllBreakpoints": "A&&lle Haltepunkte deaktivieren", "miRemoveAllBreakpoints": "&&Alle Haltepunkte entfernen", "miInstallAdditionalDebuggers": "&&Zusätzliche Debugger installieren...", "mMinimize": "Minimieren", - "mClose": "Schließen", "mBringToFront": "Alle in den Vordergrund", "miToggleDevTools": "&&Entwicklungertools umschalten", "miAccessibilityOptions": "&&Optionen für erleichterte Bedienung", "miReportIssues": "&&Probleme melden", "miWelcome": "&&Willkommen", + "miInteractivePlayground": "&&Interactive Spielwiese", "miDocumentation": "&&Dokumentation", "miReleaseNotes": "&&Anmerkungen zu dieser Version", "miKeyboardShortcuts": "&&Referenz für Tastenkombinationen", @@ -149,12 +156,14 @@ "miLicense": "&&Lizenz anzeigen", "miPrivacyStatement": "&&Datenschutzerklärung", "miAbout": "&&Info", + "miTerminateTask": "&&Task beenden", "accessibilityOptionsWindowTitle": "Optionen für erleichterte Bedienung", "miRestartToUpdate": "Für Update neu starten...", "miCheckingForUpdates": "Ãœberprüfen auf Updates...", "miDownloadUpdate": "Verfügbares Update herunterladen", "miDownloadingUpdate": "Das Update wird heruntergeladen...", "miInstallingUpdate": "Update wird installiert...", + "miCheckForUpdates": "Nach Aktualisierungen suchen...", "aboutDetail": "\nVersion {0}\nCommit {1}\nDatum {2}\nShell {3}\nRenderer {4}\nNode {5}", "okButton": "OK" } \ No newline at end of file diff --git a/i18n/deu/src/vs/code/electron-main/windows.i18n.json b/i18n/deu/src/vs/code/electron-main/windows.i18n.json index b31c876e930..28895782363 100644 --- a/i18n/deu/src/vs/code/electron-main/windows.i18n.json +++ b/i18n/deu/src/vs/code/electron-main/windows.i18n.json @@ -13,9 +13,5 @@ "appStalled": "Das Fenster reagiert nicht mehr.", "appStalledDetail": "Sie können das Fenster erneut öffnen oder schließen oder weiterhin warten.", "appCrashed": "Das Fenster ist abgestürzt.", - "appCrashedDetail": "Bitte entschuldigen Sie die Unannehmlichkeiten. Sie können das Fenster erneut öffnen und dort weitermachen, wo Sie aufgehört haben.", - "newWindow": "Neues Fenster", - "newWindowDesc": "Öffnet ein neues Fenster.", - "recentFolders": "Zuletzt verwendete Ordner", - "folderDesc": "{0} {1}" + "appCrashedDetail": "Bitte entschuldigen Sie die Unannehmlichkeiten. Sie können das Fenster erneut öffnen und dort weitermachen, wo Sie aufgehört haben." } \ No newline at end of file diff --git a/i18n/deu/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/deu/src/vs/editor/common/config/commonEditorConfig.i18n.json index 15fd087f170..78d7ebc307e 100644 --- a/i18n/deu/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/deu/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -23,6 +23,8 @@ "minimap.enabled": "Steuert, ob die Minikarte angezeigt wird", "minimap.renderCharacters": "Die tatsächlichen Zeichen in einer Zeile rendern (im Gegensatz zu Farbblöcken)", "minimap.maxColumn": "Breite der Minikarte beschränken, um höchstens eine bestimmte Anzahl von Spalten zu rendern", + "find.seedSearchStringFromSelection": "Steuert, ob wir für die Suchzeichenfolge im Suchwidget aus der Editorauswahl ein Seeding ausführen.", + "find.autoFindInSelection": "Steuert, ob die Kennzeichnung \"In Auswahl suchen\" aktiviert ist, wenn mehrere Zeichen oder Textzeilen im Editor ausgewählt wurden.", "wordWrap.off": "Zeilenumbrüche erfolgen nie.", "wordWrap.on": "Der Zeilenumbruch erfolgt an der Breite des Anzeigebereichs.", "wordWrap.wordWrapColumn": "Der Zeilenbereich erfolgt bei \"editor.wordWrapColumn\".", @@ -31,16 +33,19 @@ "wordWrapColumn": "Steuert die Umbruchspalte des Editors, wenn für \"editor.wordWrap\" die Option \"wordWrapColumn\" oder \"bounded\" festgelegt ist.", "wrappingIndent": "Steuert den Einzug der umbrochenen Zeilen. Der Wert kann \"none\", \"same\" oder \"indent\" sein.", "mouseWheelScrollSensitivity": "Ein Multiplikator, der für die Mausrad-Bildlaufereignisse \"deltaX\" und \"deltaY\" verwendet werden soll.", + "multiCursorModifier.ctrlCmd": "Ist unter Windows und Linux der Taste \"STRG\" und unter OSX der Befehlstaste zugeordnet.", + "multiCursorModifier.alt": "Ist unter Windows und Linux der Taste \"Alt\" und unter OSX der Wahltaste zugeordnet. ", + "multiCursorModifier": "Der Modifizierer, der zum Hinzufügen mehrerer Cursor mit der Maus verwendet wird. \"ctrlCmd\" wird unter Windows und Linux der Taste \"STRG\" und unter OSX der Befehlstaste zugeordnet. Die Mausbewegungen \"Gehe zu Definition\" und \"Link öffnen\" werden so angepasst, dass kein Konflikt mit dem Multi-Cursor-Modifizierer entsteht.", "quickSuggestions.strings": "Schnellvorschläge innerhalb von Zeichenfolgen aktivieren.", "quickSuggestions.comments": "Schnellvorschläge innerhalb von Kommentaren aktivieren.", "quickSuggestions.other": "Schnellvorschläge außerhalb von Zeichenfolgen und Kommentaren aktivieren.", "quickSuggestions": "Steuert, ob Vorschläge während der Eingabe automatisch angezeigt werden sollen.", "quickSuggestionsDelay": "Steuert die Verzögerung in ms für die Anzeige der Schnellvorschläge.", - "parameterHints": "Aktiviert Parameterhinweise.", "autoClosingBrackets": "Steuert, ob der Editor Klammern automatisch nach dem Öffnen schließt.", "formatOnType": "Steuert, ob der Editor Zeilen automatisch nach der Eingabe formatiert.", "formatOnPaste": "Steuert, ob der Editor den eingefügten Inhalt automatisch formatiert.", "suggestOnTriggerCharacters": "Steuert, ob Vorschläge automatisch bei der Eingabe von Triggerzeichen angezeigt werden.", + "acceptSuggestionOnEnter": "Steuert, ob Vorschläge über die Eingabetaste (zusätzlich zur TAB-Taste) angenommen werden sollen. Vermeidet Mehrdeutigkeit zwischen dem Einfügen neuer Zeilen oder dem Annehmen von Vorschlägen. Der Wert \"smart\" bedeutet, dass ein Vorschlag nur über die Eingabetaste akzeptiert wird, wenn eine Textänderung vorgenommen wird.", "acceptSuggestionOnCommitCharacter": "Steuert, ob Vorschläge über Commitzeichen angenommen werden sollen. In JavaScript kann ein Semikolon (\";\") beispielsweise ein Commitzeichen sein, das einen Vorschlag annimmt und dieses Zeichen eingibt.", "snippetSuggestions": "Steuert, ob Codeausschnitte mit anderen Vorschlägen angezeigt und wie diese sortiert werden.", "emptySelectionClipboard": "Steuert, ob ein Kopiervorgang ohne Auswahl die aktuelle Zeile kopiert.", @@ -62,12 +67,17 @@ "renderLineHighlight": "Steuert, wie der Editor die aktuelle Zeilenhervorhebung rendern soll. Mögliche Werte sind \"none\", \"gutter\", \"line\" und \"all\".", "codeLens": "Steuert, ob der Editor CodeLenses anzeigt.", "folding": "Steuert, ob für den Editor Codefaltung aktiviert ist.", + "showFoldingControls": "Steuert, ob die Falt-Steuerelemente an der Leiste automatisch ausgeblendet werden.", "matchBrackets": "Ãœbereinstimmende Klammern hervorheben, wenn eine davon ausgewählt wird.", "glyphMargin": "Steuert, ob der Editor den vertikalen Glyphenrand rendert. Der Glyphenrand wird hauptsächlich zum Debuggen verwendet.", "useTabStops": "Das Einfügen und Löschen von Leerzeichen folgt auf Tabstopps.", "trimAutoWhitespace": "Nachfolgendes automatisch eingefügtes Leerzeichen entfernen", "stablePeek": "Peek-Editoren geöffnet lassen, auch wenn auf ihren Inhalt doppelgeklickt oder die ESC-TASTE gedrückt wird.", "dragAndDrop": "Steuert, ob der Editor das Verschieben einer Auswahl per Drag and Drop zulässt.", + "accessibilitySupport.auto": "Der Editor verwendet Plattform-APIs, um zu erkennen, wenn eine Sprachausgabe angefügt wird.", + "accessibilitySupport.on": "Der Editor wird durchgehend für die Verwendung mit einer Sprachausgabe optimiert.", + "accessibilitySupport.off": "Der Editor wird nie für die Verwendung mit einer Sprachausgabe optimiert. ", + "accessibilitySupport": "Steuert, ob der Editor in einem Modus ausgeführt werden soll, in dem er für die Sprachausgabe optimiert wird.", "sideBySide": "Steuert, ob der Diff-Editor das Diff nebeneinander oder inline anzeigt.", "ignoreTrimWhitespace": "Steuert, ob der Diff-Editor Änderungen in führenden oder nachgestellten Leerzeichen als Diffs anzeigt.", "renderIndicators": "Steuert, ob der Diff-Editor die Indikatoren \"+\" und \"-\" für hinzugefügte/entfernte Änderungen anzeigt.", diff --git a/i18n/deu/src/vs/editor/common/config/editorOptions.i18n.json b/i18n/deu/src/vs/editor/common/config/editorOptions.i18n.json index 2e06d6b808a..b892d619fd6 100644 --- a/i18n/deu/src/vs/editor/common/config/editorOptions.i18n.json +++ b/i18n/deu/src/vs/editor/common/config/editorOptions.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "accessibilityOffAriaLabel": "Der Editor ist zurzeit nicht verfügbar. Drücken Sie Alt+F1 für Optionen.", "editorViewAccessibleLabel": "Editor-Inhalt" } \ No newline at end of file diff --git a/i18n/deu/src/vs/editor/common/view/editorColorRegistry.i18n.json b/i18n/deu/src/vs/editor/common/view/editorColorRegistry.i18n.json index de766791c87..56e0924a36c 100644 --- a/i18n/deu/src/vs/editor/common/view/editorColorRegistry.i18n.json +++ b/i18n/deu/src/vs/editor/common/view/editorColorRegistry.i18n.json @@ -11,6 +11,14 @@ "editorWhitespaces": "Farbe der Leerzeichen im Editor.", "editorIndentGuides": "Farbe der Führungslinien für Einzüge im Editor.", "editorLineNumbers": "Zeilennummernfarbe im Editor.", + "editorRuler": "Farbe des Editor-Lineals.", "editorCodeLensForeground": "Vordergrundfarbe der CodeLens-Links im Editor", - "editorBracketMatchBackground": "Hintergrundfarbe für zusammengehörige Klammern" + "editorBracketMatchBackground": "Hintergrundfarbe für zusammengehörige Klammern", + "editorBracketMatchBorder": "Farbe für zusammengehörige Klammern", + "editorOverviewRulerBorder": "Farbe des Rahmens für das Ãœbersicht-Lineal.", + "editorGutter": "Hintergrundfarbe der Editorleiste. Die Leiste enthält die Glyphenränder und die Zeilennummern.", + "errorForeground": "Vordergrundfarbe von Fehlerunterstreichungen im Editor.", + "errorBorder": "Rahmenfarbe von Fehlerunterstreichungen im Editor.", + "warningForeground": "Vordergrundfarbe von Warnungsunterstreichungen im Editor.", + "warningBorder": "Rahmenfarbe von Warnungsunterstreichungen im Editor." } \ No newline at end of file diff --git a/i18n/deu/src/vs/editor/contrib/find/common/findController.i18n.json b/i18n/deu/src/vs/editor/contrib/find/common/findController.i18n.json index e4d42f465d1..56e65f90b2e 100644 --- a/i18n/deu/src/vs/editor/contrib/find/common/findController.i18n.json +++ b/i18n/deu/src/vs/editor/contrib/find/common/findController.i18n.json @@ -14,6 +14,5 @@ "addSelectionToPreviousFindMatch": "Letzte Auswahl zu vorheriger Ãœbereinstimmungssuche hinzufügen", "moveSelectionToNextFindMatch": "Letzte Auswahl in nächste Ãœbereinstimmungssuche verschieben", "moveSelectionToPreviousFindMatch": "Letzte Auswahl in vorherige Ãœbereinstimmungssuche verschieben", - "selectAllOccurencesOfFindMatch": "Alle Vorkommen auswählen und Ãœbereinstimmung suchen", "changeAll.label": "Alle Vorkommen ändern" } \ No newline at end of file diff --git a/i18n/deu/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json b/i18n/deu/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json index ff88046159d..5db5e40ca1e 100644 --- a/i18n/deu/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json +++ b/i18n/deu/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json @@ -5,8 +5,6 @@ // Do not edit this file. It is machine generated. { "aria.oneReference": "Symbol in {0} in Zeile {1}, Spalte {2}", - "aria.fileReferences.1": "1 Symbol in {0}", - "aria.fileReferences.N": "{0} Symbole in {1}", "aria.result.0": "Es wurden keine Ergebnisse gefunden.", "aria.result.1": "1 Symbol in {0} gefunden", "aria.result.n1": "{0} Symbole in {1} gefunden", diff --git a/i18n/deu/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json b/i18n/deu/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json index d115a4e214a..358b448e65f 100644 --- a/i18n/deu/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json +++ b/i18n/deu/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json @@ -16,9 +16,12 @@ "peekViewTitleInfoForeground": "Farbe der Titelinformationen in der Peek-Ansicht.", "peekViewBorder": "Farbe der Peek-Ansichtsränder und des Pfeils.", "peekViewResultsBackground": "Hintergrundfarbe der Ergebnisliste in der Peek-Ansicht.", + "peekViewResultsMatchForeground": "Vordergrundfarbe für Zeilenknoten in der Ergebnisliste der Peek-Ansicht.", + "peekViewResultsFileForeground": "Vordergrundfarbe für Dateiknoten in der Ergebnisliste der Peek-Ansicht.", "peekViewResultsSelectionBackground": "Hintergrundfarbe des ausgewählten Eintrags in der Ergebnisliste der Peek-Ansicht.", "peekViewResultsSelectionForeground": "Vordergrundfarbe des ausgewählten Eintrags in der Ergebnisliste der Peek-Ansicht.", "peekViewEditorBackground": "Hintergrundfarbe des Peek-Editors.", + "peekViewEditorGutterBackground": "Hintergrundfarbe der Leiste im Peek-Editor.", "peekViewResultsMatchHighlight": "Farbe für Ãœbereinstimmungsmarkierungen in der Ergebnisliste der Peek-Ansicht.", "peekViewEditorMatchHighlight": "Farbe für Ãœbereinstimmungsmarkierungen im Peek-Editor." } \ No newline at end of file diff --git a/i18n/deu/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json b/i18n/deu/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json index 0dd09877b28..91b2f0a1b1a 100644 --- a/i18n/deu/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json +++ b/i18n/deu/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json @@ -15,5 +15,9 @@ "schema.brackets": "Definiert die Klammersymbole, die den Einzug vergrößern oder verkleinern.", "schema.autoClosingPairs": "Definiert die Klammerpaare. Wenn eine öffnende Klammer eingegeben wird, wird die schließende Klammer automatisch eingefügt.", "schema.autoClosingPairs.notIn": "Definiert eine Liste von Bereichen, in denen die automatischen Paare deaktiviert sind.", - "schema.surroundingPairs": "Definiert die Klammerpaare, in die eine ausgewählte Zeichenfolge eingeschlossen werden kann." + "schema.surroundingPairs": "Definiert die Klammerpaare, in die eine ausgewählte Zeichenfolge eingeschlossen werden kann.", + "schema.wordPattern": "Die Worddefinition für die Sprache.", + "schema.wordPattern.pattern": "RegExp Muster für Wortübereinstimmungen.", + "schema.wordPattern.flags": "RegExp Kennzeichen für Wortübereinstimmungen", + "schema.wordPattern.flags.errorMessage": "Muss mit dem Muster `/^([gimuy]+)$/` übereinstimmen." } \ No newline at end of file diff --git a/i18n/deu/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json b/i18n/deu/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json index e82addc6784..e957466c8a6 100644 --- a/i18n/deu/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json +++ b/i18n/deu/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json @@ -21,6 +21,8 @@ "menus.scmTitle": "Das Titelmenü der Quellcodeverwaltung", "menus.resourceGroupContext": "Das Ressourcengruppen-Kontextmenü der Quellcodeverwaltung", "menus.resourceStateContext": "Das Ressourcenstatus-Kontextmenü der Quellcodeverwaltung", + "view.viewTitle": "Das beigetragene Editor-Titelmenü.", + "view.itemContext": "Das beigetragene Anzeigeelement-Kontextmenü.", "nonempty": "Es wurde ein nicht leerer Wert erwartet.", "opticon": "Die Eigenschaft \"icon\" kann ausgelassen werden oder muss eine Zeichenfolge oder ein Literal wie \"{dark, light}\" sein.", "requireStringOrObject": "Die Eigenschaft \"{0}\" ist obligatorisch und muss vom Typ \"Zeichenfolge\" oder \"Objekt\" sein.", diff --git a/i18n/deu/src/vs/platform/extensions/common/extensionsRegistry.i18n.json b/i18n/deu/src/vs/platform/extensions/common/extensionsRegistry.i18n.json index d6cbe93d2b6..2a33dae4abf 100644 --- a/i18n/deu/src/vs/platform/extensions/common/extensionsRegistry.i18n.json +++ b/i18n/deu/src/vs/platform/extensions/common/extensionsRegistry.i18n.json @@ -14,6 +14,12 @@ "vscode.extension.contributes": "Alle Beiträge der VS Code-Extension, die durch dieses Paket dargestellt werden.", "vscode.extension.preview": "Legt die Erweiterung fest, die im Marketplace als Vorschau gekennzeichnet werden soll.", "vscode.extension.activationEvents": "Aktivierungsereignisse für die VS Code-Extension.", + "vscode.extension.activationEvents.onLanguage": "Ein Aktivierungsereignis wird beim Öffnen einer Datei ausgegeben, die in die angegebene Sprache aufgelöst wird.", + "vscode.extension.activationEvents.onCommand": "Ein Aktivierungsereignis wird beim Aufrufen des angegebenen Befehls ausgegeben.", + "vscode.extension.activationEvents.onDebug": "Ein Aktivierungsereignis wird beim Starten einer Debugsitzung des angegebenen Typs ausgegeben.", + "vscode.extension.activationEvents.workspaceContains": "Ein Aktivierungsereignis wird beim Öffnen eines Ordners ausgegeben, der mindestens eine Datei enthält, die mit dem angegebenen Globmuster übereinstimmt.", + "vscode.extension.activationEvents.onView": "Ein Aktivierungsereignis wird beim Erweitern der angegebenen Ansicht ausgegeben.", + "vscode.extension.activationEvents.star": "Ein Aktivierungsereignis wird beim Start von VS Code ausgegeben. Damit für die Endbenutzer eine bestmögliche Benutzerfreundlichkeit sichergestellt ist, verwenden Sie dieses Aktivierungsereignis in Ihrer Erweiterung nur dann, wenn in Ihrem Anwendungsfall keine andere Kombination an Aktivierungsereignissen funktioniert.", "vscode.extension.badges": "Array aus Badges, die im Marketplace in der Seitenleiste auf der Seite mit den Erweiterungen angezeigt werden.", "vscode.extension.badges.url": "Die Bild-URL für den Badge.", "vscode.extension.badges.href": "Der Link für den Badge.", diff --git a/i18n/deu/src/vs/platform/history/electron-main/historyMainService.i18n.json b/i18n/deu/src/vs/platform/history/electron-main/historyMainService.i18n.json new file mode 100644 index 00000000000..88004b1c71e --- /dev/null +++ b/i18n/deu/src/vs/platform/history/electron-main/historyMainService.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "newWindow": "Neues Fenster", + "newWindowDesc": "Öffnet ein neues Fenster.", + "recentFolders": "Zuletzt verwendete Ordner", + "folderDesc": "{0} {1}" +} \ No newline at end of file diff --git a/i18n/deu/src/vs/platform/markers/common/problemMatcher.i18n.json b/i18n/deu/src/vs/platform/markers/common/problemMatcher.i18n.json index 565c50e40d1..d6bda033f73 100644 --- a/i18n/deu/src/vs/platform/markers/common/problemMatcher.i18n.json +++ b/i18n/deu/src/vs/platform/markers/common/problemMatcher.i18n.json @@ -34,6 +34,7 @@ "ProblemMatcherParser.noValidIdentifier": "Fehler: Die Mustereigenschaft {0} ist kein gültiger Name für eine Mustervariable.", "ProblemMatcherParser.problemPattern.watchingMatcher": "Ein Problemmatcher muss ein Anfangsmuster und ein Endmuster für die Ãœberwachung definieren.", "ProblemMatcherParser.invalidRegexp": "Fehler: Die Zeichenfolge {0} ist kein gültiger regulärer Ausdruck.\n", + "WatchingPatternSchema.regexp": "Der reguläre Ausdruck zum Erkennen des Anfangs oder Endes eines Hintergrundtasks.", "WatchingPatternSchema.file": "Der Ãœbereinstimmungsgruppenindex des Dateinamens. Kann ausgelassen werden.", "PatternTypeSchema.name": "Der Name eines beigetragenen oder vordefinierten Musters", "PatternTypeSchema.description": "Ein Problemmuster oder der Name eines beigetragenen oder vordefinierten Problemmusters. Kann ausgelassen werden, wenn die Basis angegeben ist.", @@ -42,6 +43,12 @@ "ProblemMatcherSchema.severity": "Der Standardschweregrad für Erfassungsprobleme. Dieser wird verwendet, wenn das Muster keine Ãœbereinstimmungsgruppe für den Schweregrad definiert.", "ProblemMatcherSchema.applyTo": "Steuert, ob ein für ein Textdokument gemeldetes Problem nur auf geöffnete, geschlossene oder alle Dokumente angewendet wird.", "ProblemMatcherSchema.fileLocation": "Definiert, wie Dateinamen interpretiert werden sollen, die in einem Problemmuster gemeldet werden.", + "ProblemMatcherSchema.background": "Muster zum Nachverfolgen des Beginns und Endes eines Abgleichers, der für eine Hintergrundaufgabe aktiv ist.", + "ProblemMatcherSchema.background.activeOnStart": "Wenn dieser Wert auf \"true\" festgelegt wird, befindet sich die Hintergrundüberwachung im aktiven Modus, wenn die Aufgabe gestartet wird. Dies entspricht dem Ausgeben einer Zeile, die mit dem \"beginPattern\" übereinstimmt.", + "ProblemMatcherSchema.background.beginsPattern": "Wenn eine Ãœbereinstimmung mit der Ausgabe vorliegt, wird der Start einer Hintergrundaufgabe signalisiert.", + "ProblemMatcherSchema.background.endsPattern": "Wenn eine Ãœbereinstimmung mit der Ausgabe vorliegt, wird das Ende einer Hintergrundaufgabe signalisiert.", + "ProblemMatcherSchema.watching.deprecated": "Die Ãœberwachungseigenschaft ist veraltet. Verwenden Sie stattdessen den Hintergrund.", + "ProblemMatcherSchema.watching": "Muster zum Nachverfolgen des Beginns und Endes eines Problemabgleicher.", "ProblemMatcherSchema.watching.activeOnStart": "Wenn dieser Wert auf \"true\" festgelegt wird, befindet sich die Ãœberwachung im aktiven Modus, wenn der Task gestartet wird. Dies entspricht dem Ausgeben einer Zeile, die mit dem \"beginPattern\" übereinstimmt.", "ProblemMatcherSchema.watching.beginsPattern": "Wenn eine Ãœbereinstimmung mit der Ausgabe vorliegt, wird der Start eines Ãœberwachungstasks signalisiert.", "ProblemMatcherSchema.watching.endsPattern": "Wenn eine Ãœbereinstimmung mit der Ausgabe vorliegt, wird das Ende eines Ãœberwachungstasks signalisiert.", diff --git a/i18n/deu/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/deu/src/vs/platform/theme/common/colorRegistry.i18n.json index e8bca8886d1..ccf32b58098 100644 --- a/i18n/deu/src/vs/platform/theme/common/colorRegistry.i18n.json +++ b/i18n/deu/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -35,11 +35,13 @@ "dropdownForeground": "Vordergrund für Dropdown.", "dropdownBorder": "Rahmen für Dropdown.", "listFocusBackground": "Hintergrundfarbe der Liste/Struktur für das fokussierte Element, wenn die Liste/Struktur aktiv ist. Eine aktive Liste/Struktur hat Tastaturfokus, eine inaktive hingegen nicht.", + "listFocusForeground": "Vordergrundfarbe der Liste/Struktur für das fokussierte Element, wenn die Liste/Struktur aktiv ist. Eine aktive Liste/Struktur hat Tastaturfokus, eine inaktive hingegen nicht.", "listActiveSelectionBackground": "Hintergrundfarbe der Liste/Struktur für das ausgewählte Element, wenn die Liste/Struktur aktiv ist. Eine aktive Liste/Struktur hat Tastaturfokus, eine inaktive hingegen nicht.", "listActiveSelectionForeground": "Vordergrundfarbe der Liste/Struktur für das ausgewählte Element, wenn die Liste/Struktur aktiv ist. Eine aktive Liste/Struktur hat Tastaturfokus, eine inaktive hingegen nicht.", "listInactiveSelectionBackground": "Hintergrundfarbe der Liste/Struktur für das ausgewählte Element, wenn die Liste/Struktur inaktiv ist. Eine aktive Liste/Struktur hat Tastaturfokus, eine inaktive hingegen nicht.", "listInactiveSelectionForeground": "Liste/Baumstruktur - Vordergrundfarbe für das ausgewählte Element, wenn die Liste/Baumstruktur inaktiv ist. Eine aktive Liste/Baumstruktur hat Tastaturfokus, eine inaktive hingegen nicht.", "listHoverBackground": "Hintergrund der Liste/Struktur, wenn mit der Maus auf Elemente gezeigt wird.", + "listHoverForeground": "Vordergrund der Liste/Struktur, wenn mit der Maus auf Elemente gezeigt wird.", "listDropBackground": "Drag & Drop-Hintergrund der Liste/Struktur, wenn Elemente mithilfe der Maus verschoben werden.", "highlight": "Vordergrundfarbe der Liste/Struktur zur Trefferhervorhebung beim Suchen innerhalb der Liste/Struktur.", "pickerGroupForeground": "Schnellauswahlfarbe für das Gruppieren von Bezeichnungen.", @@ -53,9 +55,11 @@ "scrollbarSliderBackground": "Hintergrundfarbe des Schiebereglers.", "scrollbarSliderHoverBackground": "Hintergrundfarbe des Schiebereglers, wenn darauf gezeigt wird.", "scrollbarSliderActiveBackground": "Hintergrundfarbe des Schiebereglers, wenn dieser aktiv ist.", + "progressBarBackground": "Hintergrundfarbe des Fortschrittbalkens, der für lang ausgeführte Vorgänge angezeigt werden kann.", "editorBackground": "Hintergrundfarbe des Editors.", "editorForeground": "Standardvordergrundfarbe des Editors.", "editorWidgetBackground": "Hintergrundfarbe von Editor-Widgets wie zum Beispiel Suchen/Ersetzen.", + "editorWidgetBorder": "Rahmenfarbe von Editorwigdets. Die Farbe wird nur verwendet, wenn für das Widget ein Rahmen verwendet wird und die Farbe nicht von einem Widget überschrieben wird.", "editorSelection": "Farbe der Editor-Auswahl.", "editorInactiveSelection": "Farbe der Auswahl in einem inaktiven Editor.", "editorSelectionHighlight": "Farbe für Bereiche, deren Inhalt der Auswahl entspricht.", @@ -69,5 +73,12 @@ "diffEditorInserted": "Hintergrundfarbe für eingefügten Text.", "diffEditorRemoved": "Hintergrundfarbe für entfernten Text.", "diffEditorInsertedOutline": "Konturfarbe für eingefügten Text.", - "diffEditorRemovedOutline": "Konturfarbe für entfernten Text." + "diffEditorRemovedOutline": "Konturfarbe für entfernten Text.", + "mergeCurrentHeaderBackground": "Aktueller Kopfzeilenhintergrund in Inline-Mergingkonflikten.", + "mergeCurrentContentBackground": "Aktueller Inhaltshintergrund in Inline-Mergingkonflikten.", + "mergeIncomingHeaderBackground": "Eingehender Kopfzeilenhintergrund in Inline-Mergingkonflikten. ", + "mergeIncomingContentBackground": "Eingehender Inhaltshintergrund in Inline-Mergingkonflikten.", + "mergeBorder": "Rahmenfarbe für Kopfzeilen und die Aufteilung in Inline-Mergingkonflikten.", + "overviewRulerCurrentContentForeground": "Aktueller Ãœbersichtslineal-Vordergrund für Inline-Mergingkonflikte.", + "overviewRulerIncomingContentForeground": "Eingehender Ãœbersichtslineal-Vordergrund für Inline-Mergingkonflikte. " } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/deu/src/vs/workbench/api/node/extHostTask.i18n.json index 8b6ad71cd4e..4b90a12aaf2 100644 --- a/i18n/deu/src/vs/workbench/api/node/extHostTask.i18n.json +++ b/i18n/deu/src/vs/workbench/api/node/extHostTask.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "task.label": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/api/node/extHostTreeViews.i18n.json b/i18n/deu/src/vs/workbench/api/node/extHostTreeViews.i18n.json index 83810e505c9..76a36688913 100644 --- a/i18n/deu/src/vs/workbench/api/node/extHostTreeViews.i18n.json +++ b/i18n/deu/src/vs/workbench/api/node/extHostTreeViews.i18n.json @@ -4,6 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "treeView.notRegistered": "Kein Treeviw mit der id '{0}' registriert.", "treeItem.notFound": "Kein Tree-Eintrag mit der id '{0}' gefunden.", "treeView.duplicateElement": "Element {0} ist bereit registriert." } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/browser/actions/configureLocale.i18n.json b/i18n/deu/src/vs/workbench/browser/actions/configureLocale.i18n.json index a6835e15a6d..f17cc2cd8aa 100644 --- a/i18n/deu/src/vs/workbench/browser/actions/configureLocale.i18n.json +++ b/i18n/deu/src/vs/workbench/browser/actions/configureLocale.i18n.json @@ -7,6 +7,7 @@ "configureLocale": "Sprache konfigurieren", "displayLanguage": "Definiert die Anzeigesprache von VSCode.", "doc": "Unter {0} finden Sie eine Liste der unterstützten Sprachen.", + "restart": "Das Ändern dieses Wertes erfordert einen Neustart von VSCode.", "fail.createSettings": "{0} ({1}) kann nicht erstellt werden.", "JsonSchema.locale": "Die zu verwendende Sprache der Benutzeroberfläche." } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json b/i18n/deu/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json index ab66bc16e2e..419bdb09927 100644 --- a/i18n/deu/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json +++ b/i18n/deu/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json @@ -5,5 +5,6 @@ // Do not edit this file. It is machine generated. { "hideActivitBar": "Aktivitätsleiste ausblenden", - "activityBarAriaLabel": "Umschaltung der aktiven Ansicht" + "activityBarAriaLabel": "Umschaltung der aktiven Ansicht", + "globalActions": "Globale Aktionen" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json b/i18n/deu/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json index 27e4ef85e7a..3bfcbf3c524 100644 --- a/i18n/deu/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json +++ b/i18n/deu/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json @@ -10,7 +10,7 @@ "multiSelection": "{0} Auswahlen", "endOfLineLineFeed": "LF", "endOfLineCarriageReturnLineFeed": "CRLF", - "tabFocusModeEnabled": "TAB-TASTE verschiebt Fokus", + "screenReaderDetectedExtra": "Wenn Sie keine Sprachausgabe verwenden, ändern Sie die Einstellung \"editor.accessibilitySupport\" in \"Aus\".", "disableTabMode": "Barrierefreiheitsmodus deaktivieren", "gotoLine": "Gehe zu Zeile", "indentation": "Einzug", diff --git a/i18n/deu/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json b/i18n/deu/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json new file mode 100644 index 00000000000..51845025d41 --- /dev/null +++ b/i18n/deu/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpen": "Gehe zu Datei...", + "quickNavigateNext": "Zum nächsten Element in Quick Open navigieren", + "quickNavigatePrevious": "Zum vorherigen Element in Quick Open navigieren", + "quickSelectNext": "Nächstes Element in Quick Open auswählen", + "quickSelectPrevious": "Vorheriges Element in Quick Open auswählen" +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/browser/quickopen.i18n.json b/i18n/deu/src/vs/workbench/browser/quickopen.i18n.json index 4283ec57cb3..89a7706d482 100644 --- a/i18n/deu/src/vs/workbench/browser/quickopen.i18n.json +++ b/i18n/deu/src/vs/workbench/browser/quickopen.i18n.json @@ -6,6 +6,5 @@ { "noResultsMatching": "Keine übereinstimmenden Ergebnisse.", "noResultsFound2": "Es wurden keine Ergebnisse gefunden.", - "entryAriaLabel": "{0}, Befehl", - "noCommands": "Keine übereinstimmenden Befehle." + "entryAriaLabel": "{0}, Befehl" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/browser/viewlet.i18n.json b/i18n/deu/src/vs/workbench/browser/viewlet.i18n.json index 14a9eb16721..97b755d5fd6 100644 --- a/i18n/deu/src/vs/workbench/browser/viewlet.i18n.json +++ b/i18n/deu/src/vs/workbench/browser/viewlet.i18n.json @@ -4,6 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "collapse": "Alle zuklappen", - "viewToolbarAriaLabel": "{0}-Aktionen" + "collapse": "Alle zuklappen" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/common/theme.i18n.json b/i18n/deu/src/vs/workbench/common/theme.i18n.json index 52d4cbaf357..01779434428 100644 --- a/i18n/deu/src/vs/workbench/common/theme.i18n.json +++ b/i18n/deu/src/vs/workbench/common/theme.i18n.json @@ -7,27 +7,42 @@ "tabActiveBackground": "Hintergrundfarbe der aktiven Registerkarte. Registerkarten sind die Container für Editors im Editorbereich. In einer Editorgruppe können mehrere Registerkarten geöffnet werden. Mehrere Editorgruppen können vorhanden sein.", "tabInactiveBackground": "Hintergrundfarbe der inaktiven Registerkarte. Registerkarten sind die Container für Editors im Editorbereich. In einer Editorgruppe können mehrere Registerkarten geöffnet werden. Mehrere Editorgruppen können vorhanden sein.", "tabBorder": "Rahmen zum Trennen von Registerkarten. Registerkarten sind die Container für Editoren im Editor-Bereich. In einer Editor-Gruppe können mehrere Registerkarten geöffnet werden. Mehrere Editor-Gruppen sind möglich.", + "tabActiveForeground": "Vordergrundfarbe der aktiven Registerkarte in einer aktiven Gruppe. Registerkarten sind die Container für Editors im Editorbereich. In einer Editorgruppe können mehrere Registerkarten geöffnet werden. Mehrere Editorgruppen können vorhanden sein.", + "tabInactiveForeground": "Vordergrundfarbe der inaktiven Registerkarte in einer aktiven Gruppe. Registerkarten sind die Container für Editors im Editorbereich. In einer Editorgruppe können mehrere Registerkarten geöffnet werden. Mehrere Editorgruppen können vorhanden sein.", + "tabUnfocusedActiveForeground": "Vordergrundfarbe der aktiven Registerkarte in einer inaktiven Gruppe. Registerkarten sind die Container für Editors im Editorbereich. In einer Editorgruppe können mehrere Registerkarten geöffnet werden. Mehrere Editorgruppen können vorhanden sein.", + "tabUnfocusedInactiveForeground": "Vordergrundfarbe der inaktiven Registerkarte in einer inaktiven Gruppe. Registerkarten sind die Container für Editors im Editorbereich. In einer Editorgruppe können mehrere Registerkarten geöffnet werden. Mehrere Editorgruppen können vorhanden sein.", "editorGroupBackground": "Hintergrundfarbe einer Editor-Gruppe. Editor-Gruppen sind die Container der Editoren. Die Hintergrundfarbe wird beim Ziehen von Editoren angezeigt.", + "tabsContainerBackground": "Hintergrundfarbe der Titelüberschrift der Editor-Gruppe, wenn die Registerkarten deaktiviert sind. Editor-Gruppen sind die Container der Editoren.", + "tabsContainerBorder": "Rahmenfarbe der Titelüberschrift der Editor-Gruppe, wenn die Registerkarten deaktiviert sind. Editor-Gruppen sind die Container der Editoren.", "editorGroupHeaderBackground": "Hintergrundfarbe der Titelüberschrift des Editors, wenn die Registerkarten deaktiviert sind. Editor-Gruppen sind die Container der Editoren.", "editorGroupBorder": "Farbe zum Trennen mehrerer Editor-Gruppen. Editor-Gruppen sind die Container der Editoren.", + "editorDragAndDropBackground": " Hintergrundfarbe beim Ziehen von Editoren. Die Farbe muss transparent sein, damit der Editor-Inhalt noch sichtbar sind.", + "panelBackground": "Hintergrundfarbe des Panels. Panels werden unter dem Editorbereich angezeigt und enthalten Ansichten wie die Ausgabe und das integrierte Terminal.", "panelBorder": "Farbe des oberen Panelrahmens, der das Panel vom Editor abtrennt. Panels werden unter dem Editorbereich angezeigt und enthalten Ansichten wie die Ausgabe und das integrierten Terminal.", "panelActiveTitleForeground": "Titelfarbe für den aktiven Bereich. Bereiche werden unter dem Editorbereich angezeigt und enthalten Ansichten wie Ausgabe und integriertes Terminal.", "panelInactiveTitleForeground": "Titelfarbe für den inaktiven Bereich. Bereiche werden unter dem Editorbereich angezeigt und enthalten Ansichten wie Ausgabe und integriertes Terminal.", "panelActiveTitleBorder": "Rahmenfarbe für den Titel des aktiven Bereichs. Bereiche werden unter dem Editorbereich angezeigt und enthalten Ansichten wie Ausgabe und integriertes Terminal.", "statusBarForeground": "Vordergrundfarbe der Statusleiste. Die Statusleiste wird unten im Fenster angezeigt.", "statusBarBackground": "Standardhintergrundfarbe der Statusleiste. Die Statusleiste wird unten im Fenster angezeigt.", + "statusBarBorder": "Rahmenfarbe der Statusleiste für die Abtrennung von der Seitenleiste und dem Editor. Die Statusleiste wird unten im Fenster angezeigt.", "statusBarNoFolderBackground": "Hintergrundfarbe der Statusleiste, wenn kein Ordner geöffnet ist. Die Statusleiste wird unten im Fenster angezeigt.", + "statusBarNoFolderForeground": "Vordergrundfarbe der Statusleiste, wenn kein Ordner geöffnet ist. Die Statusleiste wird unten im Fenster angezeigt.", "statusBarItemActiveBackground": "Hintergrundfarbe für Statusleistenelemente beim Klicken. Die Statusleiste wird am unteren Rand des Fensters angezeigt.", "statusBarItemHoverBackground": "Hintergrundfarbe der Statusleistenelemente beim Daraufzeigen. Die Statusleiste wird am unteren Seitenrand angezeigt.", "statusBarProminentItemBackground": "Hintergrundfarbe für markante Elemente der Statusleiste. Markante Elemente sind im Vergleich zu anderen Statusleisteneinträgen hervorgehoben, um auf ihre Bedeutung hinzuweisen. Die Statusleiste wird unten im Fenster angezeigt.", "statusBarProminentItemHoverBackground": "Hintergrundfarbe für markante Elemente der Statusleiste, wenn auf diese gezeigt wird. Markante Elemente sind im Vergleich zu anderen Statusleisteneinträgen hervorgehoben, um auf ihre Bedeutung hinzuweisen. Die Statusleiste wird unten im Fenster angezeigt.", "activityBarBackground": "Hintergrundfarbe der Aktivitätsleiste. Die Aktivitätsleiste wird ganz links oder rechts angezeigt und ermöglicht das Wechseln zwischen verschiedenen Ansichten der Seitenleiste.", "activityBarForeground": "Vordergrundfarbe der Aktivitätsleiste (z. B. für Symbole). Die Aktivitätsleiste wird ganz links oder rechts angezeigt und ermöglicht das Wechseln zwischen verschiedenen Ansichten der Seitenleiste.", + "activityBarBorder": "Rahmenfarbe der Aktivitätsleiste für die Abtrennung von der Seitenleiste. Die Aktivitätsleiste wird ganz links oder rechts angezeigt und ermöglicht das Wechseln zwischen verschiedenen Ansichten der Seitenleiste.", + "activityBarDragAndDropBackground": "Drag & Drop-Feedbackfarbe für Elemente der Aktivitätsleiste. Die Farbe muss transparent sein, damit die Einträge der Aktivitätsleiste noch sichtbar sind. Die Aktivitätsleiste wird ganz links oder ganz rechts angezeigt und ermöglicht den Wechsel zwischen Ansichten der Seitenleiste.", "activityBarBadgeBackground": "Hintergrundfarbe für Aktivitätsinfobadge. Die Aktivitätsleiste wird ganz links oder ganz rechts angezeigt und ermöglicht den Wechsel zwischen Ansichten der Seitenleiste.", "activityBarBadgeForeground": "Vordergrundfarbe für Aktivitätsinfobadge. Die Aktivitätsleiste wird ganz links oder ganz rechts angezeigt und ermöglicht den Wechsel zwischen Ansichten der Seitenleiste.", "sideBarBackground": "Hintergrundfarbe der Seitenleiste. Die Seitenleiste ist der Container für Ansichten wie den Explorer und die Suche.", + "sideBarForeground": "Vordergrundfarbe der Seitenleiste. Die Seitenleiste ist der Container für Ansichten wie den Explorer und die Suche.", + "sideBarBorder": "Rahmenfarbe der Seitenleiste zum Abtrennen an der Seite zum Editor. Die Seitenleiste ist der Container für Ansichten wie den Explorer und die Suche.", "sideBarTitleForeground": "Vordergrundfarbe der Seitenleiste. Die Seitenleiste ist der Container für Ansichten wie den Explorer und die Suche.", "sideBarSectionHeaderBackground": "Hintergrundfarbe der Abschnittsüberschrift der Seitenleiste. Die Seitenleiste ist der Container für Ansichten wie den Explorer und die Suche.", + "sideBarSectionHeaderForeground": "Vordergrundfarbe der Abschnittsüberschrift der Seitenleiste. Die Seitenleiste ist der Container für Ansichten wie den Explorer und die Suche.", "titleBarActiveForeground": "Vordergrund der Titelleiste, wenn das Fenster aktiv ist. Diese Farbe wird derzeit nur von MacOS unterstützt.", "titleBarInactiveForeground": "Vordergrund der Titelleiste, wenn das Fenster inaktiv ist. Diese Farbe wird derzeit nur von MacOS unterstützt.", "titleBarActiveBackground": "Hintergrund der Titelleiste, wenn das Fenster aktiv ist. Diese Farbe wird derzeit nur von MacOS unterstützt.", diff --git a/i18n/deu/src/vs/workbench/electron-browser/actions.i18n.json b/i18n/deu/src/vs/workbench/electron-browser/actions.i18n.json index 92dabcb0496..70ead81b19e 100644 --- a/i18n/deu/src/vs/workbench/electron-browser/actions.i18n.json +++ b/i18n/deu/src/vs/workbench/electron-browser/actions.i18n.json @@ -6,9 +6,6 @@ { "closeActiveEditor": "Editor schließen", "closeWindow": "Fenster schließen", - "switchWindow": "Fenster wechseln", - "switchWindowPlaceHolder": "Fenster auswählen", - "current": "Aktuelles Fenster", "closeFolder": "Ordner schließen", "noFolderOpened": "Zurzeit ist kein Ordner in dieser Instanz geöffnet, der geschlossen werden kann.", "newWindow": "Neues Fenster", @@ -20,7 +17,7 @@ "zoomReset": "Zoom zurücksetzen", "appPerf": "Startleistung", "reloadWindow": "Fenster erneut laden", - "openRecent": "Zuletzt verwendete öffnen", + "current": "Aktuelles Fenster", "folders": "Ordner", "files": "Dateien", "openRecentPlaceHolderMac": "Wählen Sie einen Pfad aus (halten Sie die BEFEHLSTASTE gedrückt, um ein neues Fenster zu öffnen).", @@ -32,10 +29,6 @@ "openDocumentationUrl": "Dokumentation", "openIntroductoryVideosUrl": "Einführungsvideos", "toggleSharedProcess": "Freigegebenen Prozess umschalten", - "navigateLeft": "Zum Ansichtsteil links verschieben", - "navigateRight": "Zum Ansichtsteil rechts verschieben", - "navigateUp": "Zum Ansichtsteil darüber verschieben", - "navigateDown": "Zum Ansichtsteil darunter verschieben", "increaseViewSize": "Aktuelle Ansicht vergrößern", "decreaseViewSize": "Aktuelle Ansicht verkleinern" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/deu/src/vs/workbench/electron-browser/main.contribution.i18n.json index 15f166829b2..40552bf6b2a 100644 --- a/i18n/deu/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/deu/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -31,10 +31,6 @@ "window.openFoldersInNewWindow.off": "Ordner ersetzen das letzte aktive Fenster.", "window.openFoldersInNewWindow.default": "Ordner werden in einem neuen Fenster geöffnet, sofern kein Ordner innerhalb der Anwendung ausgewählt wird (z. B. über das Dateimenü).", "openFoldersInNewWindow": "Steuert, ob Ordner in einem neuen Fenster geöffnet werden oder das letzte aktive Fenster ersetzen.\n- default: Die Ordner werden in einem neuen Fenster geöffnet, sofern kein Ordner innerhalb der Anwendung ausgewählt wird (z. B. über das Dateimenü).\n- on: Die Ordner werden in einem neuen Fenster geöffnet.\n- off: Die Ordner ersetzen das letzte aktive Fenster.\nIn einigen Fällen wird diese Einstellung unter Umständen ignoriert (z. B. bei der Befehlszeilenoption \"-new-window\" oder \"-reuse-window\").", - "window.reopenFolders.none": "Ordner nie erneut öffnen.", - "window.reopenFolders.one": "Den letzten aktiven Ordner erneut öffnen.", - "window.reopenFolders.all": "Alle Ordner der letzten Sitzung erneut öffnen.", - "reopenFolders": "Steuert, wie Ordner nach einem Neustart erneut geöffnet werden. Wählen Sie \"none\" aus, um Ordner nie erneut zu öffnen, \"one\", um den zuletzt bearbeiteten Ordner erneut zu öffnen, oder \"all\", um alle Ordner der letzten Sitzung erneut zu öffnen.", "restoreFullscreen": "Steuert, ob ein Fenster im Vollbildmodus wiederhergestellt wird, wenn es im Vollbildmodus beendet wurde.", "zoomLevel": "Passen Sie den Zoomfaktor des Fensters an. Die ursprüngliche Größe ist 0. Jede Inkrementierung nach oben (z. B. 1) oder unten (z. B. -1) stellt eine Vergrößerung bzw. Verkleinerung um 20 % dar. Sie können auch Dezimalwerte eingeben, um den Zoomfaktor genauer anzupassen.", "title": "Steuert den Fenstertitel abhängig vom aktiven Editor. Variablen werden abhängig vom Kontext ersetzt:\n${activeEditorShort}: z. B. myFile.txt\n${activeEditorMedium}: z. B. myFolder/myFile.txt\n${activeEditorLong}: z. B. /Users/Development/myProject/myFolder/myFile.txt\n${rootName}: z. B. myProject\n${rootPath}: z. B. /Users/Development/myProject\n${appName}: z. B. VS Code\n${dirty}: ein geänderter Indikator, wenn der aktive Editor geändert wurde\n${separator}: ein bedingtes Trennzeichen (\" - \"), das nur in der Umgebung von Variablen mit Werten angezeigt wird", @@ -42,11 +38,13 @@ "window.newWindowDimensions.inherit": "Öffnet neue Fenster mit den gleichen Abmessungen wie das letzte aktive Fenster.", "window.newWindowDimensions.maximized": "Öffnet neue Fenster maximiert.", "window.newWindowDimensions.fullscreen": "Öffnet neue Fenster im Vollbildmodus.", + "newWindowDimensions": "Steuert die Abmessungen beim Öffnen eines neuen Fensters. Standardmäßig wird in der Mitte des Bildschirms ein neues Fenster mit kleinen Abmessungen geöffnet. Bei der Einstellung \"inherit\" erhält das Fenster die gleichen Abmessungen wie das letzte aktive Fenster. Bei der Einstellung \"maximized\" wird das Fenster maximiert geöffnet, und bei \"fullscreen\" wird es im Vollbildmodus geöffnet. Die Einstellung hat keine Auswirkungen auf das zuerst geöffnete Fenster. Größe und Position des ersten Fensters werden immer so wiederhergestellt, wie sie vor dem Schließen waren.", "window.menuBarVisibility.default": "Das Menü ist nur im Vollbildmodus ausgeblendet.", "window.menuBarVisibility.visible": "Das Menu wird immer angezeigt, auch im Vollbildmodus.", "window.menuBarVisibility.toggle": "Das Menu ist ausgeblendet, kann aber mit der Alt-Taste angezeigt werden.", "window.menuBarVisibility.hidden": "Das Menü ist immer ausgeblendet.", "menuBarVisibility": "Steuert die Sichtbarkeit der Menüleiste. Die Einstellung \"Umschalten\" bedeutet, dass die Menüleiste durch einfaches Betätigen der ALT-Taste angezeigt und ausgeblendet wird. Die Menüleite wird standardmäßig angezeigt, sofern sich das Fenster nicht im Vollbildmodus befindet.", + "enableMenuBarMnemonics": "Ist dies aktiviert, können die Hauptmenüs mithilfe von Tastenkombinationen mit der Alt-Taste geöffnet werden. Wenn mnemonische Zeichen deaktiviert werden, können diese Tastenkombinationen mit der Alt-Taste stattdessen an Editor-Befehle gebunden werden.", "autoDetectHighContrast": "Ist diese Option aktiviert, erfolgt automatisch ein Wechsel zu einem Design mit hohem Kontrast, wenn Windows ein Design mit hohem Kontrast verwendet, und zu einem dunklen Design, wenn Sie für Windows kein Design mit hohem Kontrast mehr verwenden.", "titleBarStyle": "Passt das Aussehen der Titelleiste des Fensters an. Zum Anwenden der Änderungen ist ein vollständiger Neustart erforderlich.", "window.nativeTabs": "Aktiviert MacOS Sierra-Fensterregisterkarten. Beachten Sie, dass zum Ãœbernehmen von Änderungen ein vollständiger Neustart erforderlich ist und durch ggf. konfigurierte native Registerkarten ein benutzerdefinierter Titelleistenstil deaktiviert wird.", @@ -56,5 +54,7 @@ "zenMode.hideTabs": "Steuert, ob die Workbench-Registerkarten durch Aktivieren des Zen-Modus ebenfalls ausgeblendet werden.", "zenMode.hideStatusBar": "Steuert, ob die Statusleiste im unteren Bereich der Workbench durch Aktivieren des Zen-Modus ebenfalls ausgeblendet wird.", "zenMode.hideActivityBar": "Steuert, ob die Aktivitätsleiste im linken Bereich der Workbench durch Aktivieren des Zen-Modus ebenfalls ausgeblendet wird.", - "zenMode.restore": "Steuert, ob ein Fenster im Zen-Modus wiederhergestellt werden soll, wenn es im Zen-Modus beendet wurde." + "zenMode.restore": "Steuert, ob ein Fenster im Zen-Modus wiederhergestellt werden soll, wenn es im Zen-Modus beendet wurde.", + "workspaceConfigurationTitle": "Arbeitsbereich", + "files.exclude.boolean": "Das Globmuster, mit dem Dateipfade verglichen werden sollen. Legen Sie diesen Wert auf \"true\" oder \"false\" fest, um das Muster zu aktivieren bzw. zu deaktivieren." } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json b/i18n/deu/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json new file mode 100644 index 00000000000..f802905959f --- /dev/null +++ b/i18n/deu/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json @@ -0,0 +1,26 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "emergencyConfOn": "Die Einstellung \"editor.accessibilitySupport\" wird in \"Ein\" geändert.", + "openingDocs": "Die Dokumentationsseite zur Barrierefreiheit von VS Code wird jetzt geöffnet.", + "introMsg": "Vielen Dank, dass Sie die Optionen für Barrierefreiheit von VS Code testen.", + "status": "Status:", + "changeConfigToOnMac": "Betätigen Sie jetzt die Befehlstaste+E, um den Editor zu konfigurieren, sodass er permanent für die Verwendung mit einer Sprachausgabe optimiert wird.", + "changeConfigToOnWinLinux": "Betätigen Sie jetzt die Befehlstaste+E, um den Editor zu konfigurieren, sodass er permanent für die Verwendung mit einer Sprachausgabe optimiert wird.", + "auto_unknown": "Der Editor ist für die Verwendung von Plattform-APIs konfiguriert, um zu erkennen, wenn eine Sprachausgabe angefügt wird, die aktuelle Laufzeit unterstützt dies jedoch nicht.", + "auto_on": "Der Editor hat automatisch erkannt, dass eine Sprachausgabe angefügt wurde.", + "auto_off": "Der Editor ist so konfiguriert, dass er automatisch erkennt, wenn eine Sprachausgabe angefügt wird, was momentan nicht der Fall ist.", + "configuredOn": "Der Editor ist so konfiguriert, dass er für die Verwendung mit einer Sprachausgabe durchgehend optimiert wird – Sie können dies ändern, indem Sie die Einstellung \"editor.accessibilitySupport\" bearbeiten.", + "configuredOff": "Der Editor ist so konfiguriert, dass er für die Verwendung mit einer Sprachausgabe nie optimiert wird.", + "tabFocusModeOnMsg": "Durch Drücken der TAB-TASTE im aktuellen Editor wird der Fokus in das nächste Element verschoben, das den Fokus erhalten kann. Schalten Sie dieses Verhalten um, indem Sie {0} drücken.", + "tabFocusModeOnMsgNoKb": "Durch Drücken der TAB-TASTE im aktuellen Editor wird der Fokus in das nächste Element verschoben, das den Fokus erhalten kann. Der {0}-Befehl kann zurzeit nicht durch eine Tastenzuordnung ausgelöst werden.", + "tabFocusModeOffMsg": "Durch Drücken der TAB-TASTE im aktuellen Editor wird das Tabstoppzeichen eingefügt. Schalten Sie dieses Verhalten um, indem Sie {0} drücken.", + "tabFocusModeOffMsgNoKb": "Durch Drücken der TAB-TASTE im aktuellen Editor wird das Tabstoppzeichen eingefügt. Der {0}-Befehl kann zurzeit nicht durch eine Tastenzuordnung ausgelöst werden.", + "openDocMac": "Drücken Sie die Befehlstaste+H, um ein Browserfenster mit zusätzlichen VS Code-Informationen zur Barrierefreiheit zu öffnen.", + "openDocWinLinux": "Drücken Sie STRG+H, um ein Browserfenster mit zusätzlichen VS Code-Informationen zur Barrierefreiheit zu öffnen.", + "outroMsg": "Sie können diese QuickInfo schließen und durch Drücken von ESC oder UMSCHALT+ESC zum Editor zurückkehren.", + "ShowAccessibilityHelpAction": "Hilfe zur Barrierefreiheit anzeigen" +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json b/i18n/deu/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/deu/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json b/i18n/deu/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json new file mode 100644 index 00000000000..0ca859efe95 --- /dev/null +++ b/i18n/deu/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleLocation": "Multi-Curosor-Modifizierer umschalten" +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/debug/browser/debugActions.i18n.json b/i18n/deu/src/vs/workbench/parts/debug/browser/debugActions.i18n.json index 11b3d69c656..a294a18039b 100644 --- a/i18n/deu/src/vs/workbench/parts/debug/browser/debugActions.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/debug/browser/debugActions.i18n.json @@ -6,6 +6,7 @@ { "openLaunchJson": "{0} öffnen", "launchJsonNeedsConfigurtion": "Konfigurieren oder reparieren Sie \"launch.json\".", + "noFolderDebugConfig": "Öffnen Sie bitte einen Ordner, um erweitertes Debuggen zu konfigurieren.", "startDebug": "Debuggen starten", "startWithoutDebugging": "Ohne Debuggen starten", "selectAndStartDebugging": "Debugging auswählen und starten", diff --git a/i18n/deu/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json b/i18n/deu/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json index 8b6ad71cd4e..09e90db77c7 100644 --- a/i18n/deu/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "noFolderDebugConfig": "Öffnen Sie bitte einen Ordner, um erweitertes Debuggen zu konfigurieren." +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json b/i18n/deu/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json index 785ccd9e411..55c6c83a6c0 100644 --- a/i18n/deu/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json @@ -5,16 +5,12 @@ // Do not edit this file. It is machine generated. { "variablesSection": "Variablenabschnitt", - "variables": "Variablen", "variablesAriaTreeLabel": "Variablen debuggen", "expressionsSection": "Ausdrucksabschnitt", - "watch": "Ãœberwachen", "watchAriaTreeLabel": "Ãœberwachungsausdrücke debuggen", "callstackSection": "Aufruflistenabschnitt", "debugStopped": "Angehalten bei {0}", - "callStack": "Aufrufliste", "callStackAriaLabel": "Aufrufliste debuggen", "breakpointsSection": "Haltepunkteabschnitt", - "breakpoints": "Haltepunkte", "breakpointsAriaTreeLabel": "Haltepunkte debuggen" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json b/i18n/deu/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json index 83ecbf1d9c0..57d2b620042 100644 --- a/i18n/deu/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "statusBarDebuggingBackground": "Hintergrundfarbe der Statusleiste beim Debuggen eines Programms. Die Statusleiste wird unten im Fenster angezeigt." + "statusBarDebuggingBackground": "Hintergrundfarbe der Statusleiste beim Debuggen eines Programms. Die Statusleiste wird unten im Fenster angezeigt.", + "statusBarDebuggingForeground": "Vordergrundfarbe der Statusleiste beim Debuggen eines Programms. Die Statusleiste wird unten im Fenster angezeigt." } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json b/i18n/deu/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json index 094d1188c24..1bcee0dbf6e 100644 --- a/i18n/deu/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json @@ -7,6 +7,7 @@ "debugAdapterBinNotFound": "Die ausführbare Datei \"{0}\" des Debugadapters ist nicht vorhanden.", "debugAdapterCannotDetermineExecutable": "Die ausführbare Datei \"{0}\" des Debugadapters kann nicht bestimmt werden.", "debugType": "Der Typ der Konfiguration.", + "debugTypeNotRecognised": "Dieser Debugging-Typ wurde nicht erkannt. Bitte installieren und aktivieren Sie die dazugehörige Debugging-Erweiterung.", "node2NotSupported": "\"node2\" wird nicht mehr unterstützt, verwenden Sie stattdessen \"node\", und legen Sie das Attribut \"protocol\" auf \"inspector\" fest.", "debugName": "Der Name der Konfiguration. Er wird im Dropdownmenü der Startkonfiguration angezeigt.", "debugRequest": "Der Anforderungstyp der Konfiguration. Der Wert kann \"launch\" oder \"attach\" sein.", diff --git a/i18n/deu/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json b/i18n/deu/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json index 35ffc123f14..de81c8b7743 100644 --- a/i18n/deu/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json @@ -4,6 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "previousEditPoint": "Emmet: Vorheriger Bearbeitungspunkt", - "nextEditPoint": "Emmet: Nächster Bearbeitungspunkt" + "previousEditPoint": "Emmet: Zum vorherigen Bearbeitungspunkt wechseln", + "nextEditPoint": "Emmet: Zum nächsten Bearbeitungspunkt wechseln" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json b/i18n/deu/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json index 5beaa142e9f..71dbf73cb59 100644 --- a/i18n/deu/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json @@ -9,5 +9,6 @@ "emmetPreferences": "Einstellungen, die zum Ändern des Verhaltens einiger Aktionen und Konfliktlöser von Emmet verwendet werden.", "emmetSyntaxProfiles": "Definieren Sie das Profil für die angegebene Syntax, oder verwenden Sie Ihr eigenes Profil mit bestimmten Regeln.", "emmetExclude": "Ein Array von Sprachen, in dem Emmet-Abkürzungen nicht erweitert werden sollen.", - "emmetExtensionsPath": "Pfad zu einem Ordner mit Emmet-Profilen, Ausschnitten und Voreinstellungen" + "emmetExtensionsPath": "Pfad zu einem Ordner mit Emmet-Profilen, Ausschnitten und Voreinstellungen", + "useNewEmmet": "Testen Sie die neuen Emmet-Module (die letztendlich die alte einzelne Emmet-Bibliothek ersetzen) für alle Emmet-Funktionen." } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json b/i18n/deu/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json index c893534d59c..80ecb27720f 100644 --- a/i18n/deu/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json @@ -24,6 +24,10 @@ "default": "Standard", "debuggers": "Debugger ({0})", "debugger name": "Name", + "views": "Ansichten ({0})", + "view id": "ID", + "view name": "Name", + "view location": "Wo", "themes": "Designs ({0})", "JSON Validation": "JSON-Validierung ({0})", "commands": "Befehle ({0})", diff --git a/i18n/deu/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json b/i18n/deu/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json index 3fc196fe64e..0e32d73283c 100644 --- a/i18n/deu/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json @@ -22,6 +22,8 @@ "disableGloballyAction": "Immer", "disableAction": "Deaktivieren", "checkForUpdates": "Nach Updates suchen", + "enableAutoUpdate": "Aktivere die automatische Aktualisierung von Erweiterungen", + "disableAutoUpdate": "Deaktivere die automatische Aktualisierung von Erweiterungen", "updateAll": "Alle Erweiterungen aktualisieren", "reloadAction": "Neu starten", "postUpdateTooltip": "Zum Aktualisieren erneut laden", @@ -44,6 +46,8 @@ "showWorkspaceRecommendedExtensions": "Für den Arbeitsbereich empfohlene Erweiterungen anzeigen", "showRecommendedKeymapExtensions": "Empfohlene Tastenzuordnungen anzeigen", "showRecommendedKeymapExtensionsShort": "Tastenzuordnungen", + "showLanguageExtensions": "Spracherweiterungen anzeigen", + "showLanguageExtensionsShort": "Spracherweiterungen", "configureWorkspaceRecommendedExtensions": "Empfohlene Erweiterungen konfigurieren (Arbeitsbereich)", "ConfigureWorkspaceRecommendations.noWorkspace": "Empfehlungen sind nur für einen Arbeitsbereichsordner verfügbar.", "OpenExtensionsFile.failed": "Die Datei \"extensions.json\" kann nicht im Ordner \".vscode\" erstellt werden ({0}).", @@ -51,5 +55,8 @@ "disableAll": "Alle installierten Erweiterungen löschen", "disableAllWorkspace": "Alle installierten Erweiterungen für diesen Arbeitsbereich deaktivieren", "enableAll": "Alle installierten Erweiterungen aktivieren", - "enableAllWorkspace": "Alle installierten Erweiterungen für diesen Arbeitsbereich aktivieren" + "enableAllWorkspace": "Alle installierten Erweiterungen für diesen Arbeitsbereich aktivieren", + "extensionButtonProminentBackground": "Hintergrundfarbe für markante Aktionenerweiterungen (z. B. die Schaltfläche zum Installieren).", + "extensionButtonProminentForeground": "Vordergrundfarbe für markante Aktionenerweiterungen (z. B. die Schaltfläche zum Installieren).", + "extensionButtonProminentHoverBackground": "Hoverhintergrundfarbe für markante Aktionenerweiterungen (z. B. die Schaltfläche zum Installieren)." } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/deu/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 4769dc3fe1e..48aabfdf0bf 100644 --- a/i18n/deu/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -4,8 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "disableOtherKeymapsConfirmation": "Deaktivere Tastenzuordnungen ({0}) um Konfilkte mit anderen zu vermeiden?", "yes": "Ja", "no": "Nein", + "betterMergeDisabled": "Die \"Better Merge\" Erweiterung ist jetzt integriert, die alte Erweiterung wurde deaktiviert und kann deinstalliert werden.", "uninstall": "Deinstallieren", "later": "Später" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/deu/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 8153f54254b..3a26505523d 100644 --- a/i18n/deu/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,6 +16,7 @@ "associations": "Konfigurieren Sie Dateizuordnungen zu Sprachen (beispielsweise \"*.extension\": \"html\"). Diese besitzen Vorrang vor den Standardzuordnungen der installierten Sprachen.", "encoding": "Die Standardzeichensatz-Codierung, die beim Lesen und Schreiben von Dateien verwendet werden soll.", "autoGuessEncoding": "Ist diese Option aktiviert, wird beim Öffnen von Dateien versucht, die Zeichensatzcodierung automatisch zu ermitteln.", + "eol": "Das Zeilenende-Standardzeichen. Verwenden Sie \\n für LF und \\r\\n für CRLF.", "trimTrailingWhitespace": "Bei Aktivierung werden nachgestellte Leerzeichen beim Speichern einer Datei gekürzt.", "insertFinalNewline": "Bei Aktivierung wird beim Speichern einer Datei eine abschließende neue Zeile am Dateiende eingefügt.", "files.autoSave.off": "Eine geänderte Datei wird nie automatisch gespeichert.", @@ -26,6 +27,7 @@ "autoSaveDelay": "Steuert die Verzögerung in Millisekunden, nach der eine geänderte Datei automatisch gespeichert wird. Nur gültig, wenn \"files.autoSave\" auf \"{0}\" festgelegt ist.", "watcherExclude": "Konfigurieren Sie Globmuster von Dateipfaden, die aus der Dateiüberwachung ausgeschlossen werden sollen. Das Ändern dieser Einstellung erfordert einen Neustart. Wenn Ihr Code beim Starten viel CPU-Zeit benötigt, können Sie große Ordner ausschließen, um die Anfangslast zu verringern.", "hotExit.off": "Hot Exit deaktivieren.", + "hotExit.onExit": "Hot Exit wird beim Schließen der Anwendung ausgelöst, d. h. wenn unter Windows/Linux das letzte Fenster geschlossen wird oder wenn der Befehl \"workbench.action.quit\" ausgelöst wird (Befehlspalette, Tastenzuordnung, Menü). Alle Fenster mit Sicherungen werden beim nächsten Start wiederhergestellt.", "hotExit": "Steuert, ob nicht gespeicherten Dateien zwischen den Sitzungen beibehlten werden, die Aufforderung zum Speichern wird beim Beenden des Editors übersprungen.", "defaultLanguage": "Der Standardsprachmodus, der neuen Dateien zugewiesen wird.", "editorConfigurationTitle": "Editor", diff --git a/i18n/deu/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json b/i18n/deu/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json index 0402d68c71d..ed93c437e87 100644 --- a/i18n/deu/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json @@ -5,7 +5,5 @@ // Do not edit this file. It is machine generated. { "explorerSection": "Datei-Explorer-Abschnitt", - "noWorkspace": "Es ist kein Ordner geöffnet.", - "noWorkspaceHelp": "Sie haben noch keinen Ordner geöffnet.", "openFolder": "Ordner öffnen" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json b/i18n/deu/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json index 02b807c7657..ac1fd2f5acb 100644 --- a/i18n/deu/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json @@ -4,8 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "openEditosrSection": "Abschnitt \"Geöffnete Editoren\"", "openEditors": "Geöffnete Editoren", + "openEditosrSection": "Abschnitt \"Geöffnete Editoren\"", "treeAriaLabel": "Geöffnete Editoren: Liste der aktiven Dateien", "dirtyCounter": "{0} nicht gespeichert" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/deu/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index b7e6e189740..7fb4c04c827 100644 --- a/i18n/deu/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -10,5 +10,6 @@ "prof.detail": "Erstellen Sie ein Problem, und fügen Sie die folgenden Dateien manuell an:\n{0}", "prof.restartAndFileIssue": "Problem erstellen und neu starten", "prof.restart": "Neu starten", - "prof.thanks": "Danke für Ihre Hilfe." + "prof.thanks": "Danke für Ihre Hilfe.", + "prof.detail.restart": "Ein abschließender Neustart ist erforderlich um '{0}' nutzen zu können. Danke für Ihre Hilfe." } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/deu/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json index 17617151e91..959f4d64674 100644 --- a/i18n/deu/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -5,5 +5,7 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.start": "Tastenbindung definieren", - "defineKeybinding.kbLayoutErrorMessage": "Sie können diese Tastenkombination mit Ihrem aktuellen Tastaturlayout nicht generieren." + "defineKeybinding.kbLayoutErrorMessage": "Sie können diese Tastenkombination mit Ihrem aktuellen Tastaturlayout nicht generieren.", + "defineKeybinding.kbLayoutLocalAndUSMessage": "**{0}** für Ihr aktuelles Tastaturlayout (**{1}** für USA, Standard).", + "defineKeybinding.kbLayoutLocalMessage": "**{0}** für Ihr aktuelles Tastaturlayout." } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json b/i18n/deu/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json index 701fa77e7a5..409e4b05ee1 100644 --- a/i18n/deu/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json @@ -4,6 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "errorInvalidConfiguration": "Einstellungen können nicht geschrieben werden. Öffnen Sie die Datei, um Fehler/Warnungen in der Datei zu korrigieren. Versuchen Sie es anschließend noch mal.", "editTtile": "Bearbeiten", "replaceDefaultValue": "In Einstellungen ersetzen", "copyDefaultValue": "In Einstellungen kopieren", diff --git a/i18n/deu/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json b/i18n/deu/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json new file mode 100644 index 00000000000..8595fd7f9f7 --- /dev/null +++ b/i18n/deu/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "relaunchMessage": "Eine Einstellung wurde geändert, welche einen Neustart benötigt.", + "relaunchDetail": "Drücke den Neu starten-Button, um {0} neuzustarten und die Einstellung zu aktivieren.", + "restart": "Neu starten" +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/deu/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json index 8b6ad71cd4e..3a196327770 100644 --- a/i18n/deu/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "editorGutterModifiedBackground": "Hintergrundfarbe für die Editor-Leiste für Zeilen, die geändert wurden.", + "editorGutterAddedBackground": "Hintergrundfarbe für die Editor-Leiste für Zeilen, die hinzugefügt wurden.", + "editorGutterDeletedBackground": "Hintergrundfarbe für die Editor-Leiste für Zeilen, die gelöscht wurden." +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json b/i18n/deu/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json index cfb59dde790..11d322e7129 100644 --- a/i18n/deu/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "toggleGitViewlet": "Git anzeigen", + "installAdditionalSCMProviders": "Installiere weiter SCM Provider...", "source control": "Quellcodeverwaltung", "toggleSCMViewlet": "SCM anzeigen", "view": "Anzeigen" diff --git a/i18n/deu/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json b/i18n/deu/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json index 07930885971..d2a2095a234 100644 --- a/i18n/deu/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "installAdditionalSCMProviders": "Installiere weiter SCM Provider...", "switch provider": "SCM-Anbieter wechseln..." } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json b/i18n/deu/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json index e7724dc5035..8ec0049b3b3 100644 --- a/i18n/deu/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json @@ -6,5 +6,7 @@ { "searchMatches": "{0} Ãœbereinstimmungen gefunden", "searchMatch": "{0} Ãœbereinstimmung gefunden", - "fileMatchAriaLabel": "{0} Ãœbereinstimmungen in der Datei \"{1}\" des Ordners \"{2}\", Suchergebnis" + "fileMatchAriaLabel": "{0} Ãœbereinstimmungen in der Datei \"{1}\" des Ordners \"{2}\", Suchergebnis", + "replacePreviewResultAria": "Ersetze Term {0} mit {1} an Spaltenposition {2} in Zeile mit Text {3}", + "searchResultAria": "Term {0} an Spaltenposition {1} in Zeile mit Text {2} gefunden" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json b/i18n/deu/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json index 60f40269ae4..b0d6510181e 100644 --- a/i18n/deu/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json @@ -9,5 +9,6 @@ "vscode.extension.contributes.snippets-path": "Der Pfad der Codeausschnittdatei. Der Pfad ist relativ zum Extensionordner und beginnt normalerweise mit \". /snippets/\".", "invalid.language": "Unbekannte Sprache in \"contributes.{0}.language\". Bereitgestellter Wert: {1}", "invalid.path.0": "In \"contributes.{0}.path\" wurde eine Zeichenfolge erwartet. Bereitgestellter Wert: {1}", - "invalid.path.1": "Es wurde erwartet, dass \"contributes.{0}.path\" ({1}) im Ordner ({2}) der Extension enthalten ist. Dies führt ggf. dazu, dass die Extension nicht portierbar ist." + "invalid.path.1": "Es wurde erwartet, dass \"contributes.{0}.path\" ({1}) im Ordner ({2}) der Extension enthalten ist. Dies führt ggf. dazu, dass die Extension nicht portierbar ist.", + "badVariableUse": "Das \"{0}\"-Snippet verwirrt wahrscheinlich Snippet-Variablen und Snippet-Paltzhalter. Schaue https://code.visualstudio.com/docs/editor/userdefinedsnippets#_snippet-syntax für weitere Informationen." } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json b/i18n/deu/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json index 086f7561431..ff4eb3dd4ad 100644 --- a/i18n/deu/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json @@ -11,6 +11,6 @@ "snippetSchema.json.default": "Leerer Codeausschnitt", "snippetSchema.json": "Benutzerkonfiguration des Codeausschnitts", "snippetSchema.json.prefix": "Das Präfix, das beim Auswählen des Codeausschnitts in IntelliSense verwendet werden soll.", - "snippetSchema.json.body": "Der Inhalt des Codeausschnitts. Verwenden Sie \"${id}\", \"${id:label}\", \"${1:label}\" für Variablen und \"$0\", \"$1\" für die Cursorpositionen.", + "snippetSchema.json.body": "Der Inhalt des Codeausschnitts. Verwenden Sie \"$1\", \"${1:defaultText}\", um Cursorpositionen zu definieren, und \"$0\" für die finale Cursorposition. Fügen Sie mit \"${varName}\" und \"${varName:defaultText}\" Variablenwerte ein, z. B. \"This is file: $TM_FILENAME\".", "snippetSchema.json.description": "Die Beschreibung des Codeausschnitts." } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json b/i18n/deu/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json new file mode 100644 index 00000000000..b04bf830fa1 --- /dev/null +++ b/i18n/deu/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "helpUs": "Helfen Sie uns die Unterstützung für {0} zu verbessern", + "takeShortSurvey": "An kurzer Umfrage teilnehmen", + "remindLater": "Später erinnern", + "neverAgain": "Nicht mehr anzeigen" +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json b/i18n/deu/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json new file mode 100644 index 00000000000..5082c06fc4a --- /dev/null +++ b/i18n/deu/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "surveyQuestion": "Wir würden uns freuen, wenn Sie an einer schnellen Umfrage teilnehmen.", + "takeSurvey": "An Umfrage teilnehmen", + "remindLater": "Später erinnern", + "neverAgain": "Nicht mehr anzeigen" +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json b/i18n/deu/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json new file mode 100644 index 00000000000..b8a1db0f78f --- /dev/null +++ b/i18n/deu/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noTasksMatching": "Keine übereinstimmenden Aufgaben" +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/deu/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index c0432625724..b588e15359b 100644 --- a/i18n/deu/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0}, tasks" + "entryAriaLabel": "{0}, tasks", + "customizeTask": "Aufgabe anpassen" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json b/i18n/deu/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json new file mode 100644 index 00000000000..b8a1db0f78f --- /dev/null +++ b/i18n/deu/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noTasksMatching": "Keine übereinstimmenden Aufgaben" +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/deu/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json index bf5de1662ad..b78817aed4c 100644 --- a/i18n/deu/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -12,5 +12,6 @@ "ConfigurationParser.invalidVaraibleReference": "Fehler: Ungültiger ProblemMatcher-Verweis: {0}\n", "ConfigurationParser.noTaskName": "Fehler: Tasks müssen eine Eigenschaft \"TaskName\" angeben. Der Task wird ignoriert.\n{0}\n", "taskConfiguration.shellArgs": "Warnung: Die Aufgabe \"{0}\" ist ein Shellbefehl, und der Befehlsname oder eines seiner Argumente enthält Leerzeichen ohne Escapezeichen. Führen Sie Argumente im Befehl zusammen, um eine korrekte Angabe der Befehlszeile sicherzustellen.", + "taskConfiguration.noCommandOrDependsOn": "Fehler: Aufgabe \"{0}\" definiert keinen Befehl bzw. keine depondsOn-Eigenschaft. Die Aufgabe wird ignoriert. Die Definition lautet:\n{1}", "taskConfiguration.noCommand": "Fehler: Aufgabe \"{0}\" definiert keinen Befehl. Die Aufgabe wird ignoriert. Die Definition lautet:\n{1}" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json b/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json index 386f8b115b1..0570db2cdce 100644 --- a/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json @@ -7,6 +7,7 @@ "JsonSchema.options": "Weitere Befehlsoptionen", "JsonSchema.options.cwd": "Das aktuelle Arbeitsverzeichnis des ausgeführten Programms oder Skripts. Wenn keine Angabe erfolgt, wird das aktuelle Arbeitsbereich-Stammverzeichnis des Codes verwendet.", "JsonSchema.options.env": "Die Umgebung des ausgeführten Programms oder der Shell. Wenn keine Angabe erfolgt, wird Umgebung des übergeordneten Prozesses verwendet.", + "JsonSchema.shellConfiguration": "Konfiguriert die zu verwendende Shell.", "JsonSchema.shell.executable": "Die zu verwendende Shell.", "JsonSchema.shell.args": "Die Shell-Argumente.", "JsonSchema.command": "Der auszuführende Befehl. Es kann sich um ein externes Programm oder einen Shellbefehl handeln.", diff --git a/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json b/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json index ce023819c12..1bfe4d70cd9 100644 --- a/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json @@ -5,6 +5,8 @@ // Do not edit this file. It is machine generated. { "JsonSchema.version": "Die Versionsnummer der Konfiguration.", + "JsonSchema._runner": "Die Ausführung ist abgestuft. Verwenden Sie die offizielle Ausführungseigenschaft.", + "JsonSchema.runner": "Definiert, ob die Aufgabe als Prozess ausgeführt wird, und die Ausgabe wird im Ausgabefenster oder innerhalb des Terminals angezeigt.", "JsonSchema.windows": "Windows-spezifische Befehlskonfiguration", "JsonSchema.mac": "Mac-spezifische Befehlskonfiguration", "JsonSchema.linux": "Linux-spezifische Befehlskonfiguration", diff --git a/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json index 1363d395b95..433a15c4e8f 100644 --- a/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -7,6 +7,10 @@ "JsonSchema.shell": "Gibt an, ob der Befehl ein Shellbefehl oder ein externes Programm ist. Wenn keine Angabe erfolgt, ist der Standardwert \"false\".", "JsonSchema.tasks.dependsOn.string": "Eine weitere Aufgabe, von der diese Aufgabe abhängt.", "JsonSchema.tasks.dependsOn.array": "Die anderen Aufgaben, von denen diese Aufgabe abhängt.", + "JsonSchema.tasks.group": "Definiert die Ausführungsgruppe, der diese Aufgabe angehört. Wird dies ausgelassen, gehört die Aufgabe keiner Gruppe an.", + "JsonSchema.tasks.type": "Definiert, ob die Aufgabe als Prozess oder als Befehl innerhalb einer Shell ausgeführt wird. Standardmäßig wird sie als Prozess ausgeführt.", + "JsonSchema.version": "Die Versionsnummer der Konfiguration.", + "JsonSchema.tasks.customize": "Die anzupassende beigetragene Aufgabe.", "JsonSchema.windows": "Windows-spezifische Befehlskonfiguration", "JsonSchema.mac": "Mac-spezifische Befehlskonfiguration", "JsonSchema.linux": "Linux-spezifische Befehlskonfiguration" diff --git a/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json b/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json index aedbe077c16..d4db76035e5 100644 --- a/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json @@ -18,10 +18,12 @@ "problems": "Probleme", "manyMarkers": "mehr als 99", "tasks": "Aufgaben", + "TaskSystem.noHotSwap": "Zum Ändern des Aufgabenausführungsmoduls muss VS Code neu gestartet werden. Die Änderung wird ignoriert.", "TaskService.noBuildTask": "Keine Buildaufgabe definiert. Markieren Sie eine Aufgabe mit 'isBuildCommand' in der tasks.json-Datei.", "TaskService.noTestTask": "Keine Testaufgabe definiert. Markieren Sie eine Aufgabe mit 'isTestCommand' in der tasks.json-Datei.", "TaskServer.noTask": "Die angeforderte auszuführende Aufgabe {0} wurde nicht gefunden.", - "TaskSystem.activeSame": "Der Task ist bereits aktiv und im Ãœberwachungsmodus. Um den Task zu beenden, verwenden Sie \"F1 > Task beenden\".", + "customizeParseErrors": "Die aktuelle Aufgabenkonfiguration weist Fehler auf. Beheben Sie die Fehler, bevor Sie eine Aufgabe anpassen.", + "moreThanOneBuildTask": "In \"tasks.json\" sind mehrere Buildaufgaben definiert. Die erste wird ausgeführt.\n", "TaskSystem.active": "Eine aktive Aufgabe wird bereits ausgeführt. Beenden Sie diese, bevor Sie eine andere Aufgabe ausführen.", "TaskSystem.restartFailed": "Fehler beim Beenden und Neustarten der Aufgabe \"{0}\".", "TaskSystem.configurationErrors": "Fehler: Die angegebene Aufgabenkonfiguration weist Validierungsfehler auf und kann nicht verwendet werden. Beheben Sie zuerst die Fehler.", diff --git a/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json b/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json index a619f8880ba..0ad146b3785 100644 --- a/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json @@ -6,5 +6,7 @@ { "TerminalTaskSystem.unknownError": "Unbekannter Fehler beim Ausführen eines Tasks. Details finden Sie im Taskausgabeprotokoll.", "TerminalTaskSystem.terminalName": "Aufgabe - {0}", - "TerminalTaskSystem": "Ein Shell-Befehl kann nicht auf einem UNC-Laufwerk ausgeführt werden." + "reuseTerminal": "Das Terminal wird von Aufgaben wiederverwendet, drücken Sie zum Schließen eine beliebige Taste.", + "TerminalTaskSystem": "Ein Shell-Befehl kann nicht auf einem UNC-Laufwerk ausgeführt werden.", + "unkownProblemMatcher": "Der Problemabgleicher {0} kann nicht aufgelöst werden. Der Abgleicher wird ignoriert." } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json b/i18n/deu/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json index 8a66033683f..b6c2bea0eab 100644 --- a/i18n/deu/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json @@ -7,5 +7,6 @@ "TaskRunnerSystem.unknownError": "Unbekannter Fehler beim Ausführen eines Tasks. Details finden Sie im Taskausgabeprotokoll.", "TaskRunnerSystem.watchingBuildTaskFinished": "\nDie Ãœberwachung der Buildtasks wurde beendet.", "TaskRunnerSystem.childProcessError": "Failed to launch external program {0} {1}.", - "TaskRunnerSystem.cancelRequested": "\nDer Task \"{0}\" wurde durch eine Benutzeranforderung beendet." + "TaskRunnerSystem.cancelRequested": "\nDer Task \"{0}\" wurde durch eine Benutzeranforderung beendet.", + "unkownProblemMatcher": "Der Problemabgleicher {0} kann nicht aufgelöst werden. Der Abgleicher wird ignoriert." } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json b/i18n/deu/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json index 2b0635fb08d..2bbcb5a8073 100644 --- a/i18n/deu/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json @@ -8,6 +8,7 @@ "workbench.action.terminal.kill": "Aktive Terminalinstanz beenden", "workbench.action.terminal.kill.short": "Terminal beenden", "workbench.action.terminal.copySelection": "Auswahl kopieren", + "workbench.action.terminal.selectAll": "Alles auswählen", "workbench.action.terminal.new": "Neues integriertes Terminal erstellen", "workbench.action.terminal.new.short": "Neues Terminal", "workbench.action.terminal.focus": "Fokus im Terminal", @@ -26,5 +27,8 @@ "workbench.action.terminal.scrollUp": "Nach oben scrollen (Zeile)", "workbench.action.terminal.scrollUpPage": "Nach oben scrollen (Seite)", "workbench.action.terminal.scrollToTop": "Bildlauf nach oben", - "workbench.action.terminal.clear": "Löschen" + "workbench.action.terminal.clear": "Löschen", + "workbench.action.terminal.allowWorkspaceShell": "Shell-Konfiguration des Arbeitsbereichs zulassen", + "workbench.action.terminal.disallowWorkspaceShell": "Verbiete Workspace Shell Konfiguration", + "workbench.action.terminal.rename": "Umbenennen" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json b/i18n/deu/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json index 209097e71ed..9d4810761f2 100644 --- a/i18n/deu/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json @@ -4,5 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "terminal.background": "Die Hintergrundfarbe des Terminals, dies ermöglicht eine unterschiedliche Färbung des Terminals im Panel.", + "terminal.foreground": "Die Vordergrundfarbe des Terminal.", "terminal.ansiColor": "\"{0}\": ANSI-Farbe im Terminal" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json b/i18n/deu/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json new file mode 100644 index 00000000000..32db8ee0bd6 --- /dev/null +++ b/i18n/deu/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "label.find": "Suchen", + "placeholder.find": "Suchen", + "label.previousMatchButton": "Vorherige Ãœbereinstimmung", + "label.nextMatchButton": "Nächste Ãœbereinstimmung", + "label.closeButton": "Schließen" +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json b/i18n/deu/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json index 656e6a048ae..ed2d8c3d212 100644 --- a/i18n/deu/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json @@ -4,7 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "terminal.integrated.copySelection.noSelection": "Die Terminalauswahl kann nicht kopiert werden, wenn das Terminal nicht den Fokus besitzt.", "terminal.integrated.exitedWithCode": "Der Terminalprozess wurde mit folgendem Exitcode beendet: {0}", "terminal.integrated.waitOnExit": "Betätigen Sie eine beliebige Taste, um das Terminal zu schließen.", "terminal.integrated.launchFailed": "Fehler beim Starten des Terminalprozessbefehls \"{0}{1}\" (Exitcode: {2})." diff --git a/i18n/deu/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json b/i18n/deu/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json index cc616e88ee2..5b38193cdec 100644 --- a/i18n/deu/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json @@ -6,6 +6,7 @@ { "selectTheme.label": "Farbdesign", "installColorThemes": "Zusätzliche Farbschemas installieren...", + "themes.selectTheme": "Farbdesign auswählen (eine Vorschau wird mit den Tasten NACH OBEN/NACH UNTEN angezeigt)", "selectIconTheme.label": "Dateisymboldesign", "installIconThemes": "Zusätzliche Dateisymbolschemas installieren...", "noIconThemeLabel": "Keine", diff --git a/i18n/deu/src/vs/workbench/parts/update/electron-browser/update.i18n.json b/i18n/deu/src/vs/workbench/parts/update/electron-browser/update.i18n.json index 22510793b9c..80d0e1e4ecf 100644 --- a/i18n/deu/src/vs/workbench/parts/update/electron-browser/update.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/update/electron-browser/update.i18n.json @@ -15,5 +15,18 @@ "license": "Lizenz lesen", "updateAvailable": "{0} wird nach dem Neustart aktualisiert.", "thereIsUpdateAvailable": "Ein Update ist verfügbar.", - "noUpdatesAvailable": "Zurzeit sind keine Updates verfügbar." + "noUpdatesAvailable": "Zurzeit sind keine Updates verfügbar.", + "updateIsReady": "Neue Aktualisierung verfügbar.", + "commandPalette": "Befehlspalette...", + "settings": "Einstellungen", + "keyboardShortcuts": "Tastenkombinationen", + "selectTheme.label": "Farbdesign", + "themes.selectIconTheme.label": "Dateisymboldesign", + "not available": "Aktualisierungen nicht verfügbar", + "checkingForUpdates": "Ãœberprüfen auf Updates...", + "DownloadUpdate": "Verfügbares Update herunterladen", + "DownloadingUpdate": "Das Update wird heruntergeladen...", + "InstallingUpdate": "Update wird installiert...", + "restartToUpdate": "Für Update neu starten...", + "checkForUpdates": "Nach Aktualisierungen suchen..." } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/views/browser/views.i18n.json b/i18n/deu/src/vs/workbench/parts/views/browser/views.i18n.json new file mode 100644 index 00000000000..b7eb39e941e --- /dev/null +++ b/i18n/deu/src/vs/workbench/parts/views/browser/views.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "viewToolbarAriaLabel": "{0}-Aktionen" +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json b/i18n/deu/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json new file mode 100644 index 00000000000..69d939fd7d1 --- /dev/null +++ b/i18n/deu/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "requirearray": "Ansichten müssen ein Array sein.", + "requirestring": "Die Eigenschaft \"{0}\" ist erforderlich. Sie muss vom Typ \"string\" sein.", + "optstring": "Die Eigenschaft \"{0}\" kann ausgelassen werden oder muss vom Typ \"string\" sein.", + "vscode.extension.contributes.view.id": "Bezeichner der Ansicht. Damit können Sie einen Datenanbieter über die API \"vscode.window.registerTreeDataProviderForView\" registrieren. Er dient auch zum Aktivieren Ihrer Erweiterung, indem Sie das Ereignis \"onView:${id}\" für \"activationEvents\" registrieren.", + "vscode.extension.contributes.view.name": "Der visuell lesbare Name der Ansicht. Wird angezeigt", + "vscode.extension.contributes.views": "Trägt Ansichten zum Editor bei.", + "views.explorer": "Explorer-Ansicht", + "locationId.invalid": "{0}\" ist kein gültiger Ansichtenspeicherort" +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json index 57931ea4bd6..89fcf6e01ed 100644 --- a/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -14,20 +14,23 @@ "welcomePage.moreRecent": "Weitere Informationen...", "welcomePage.noRecentFolders": "Keine kürzlich verwendeten Ordner", "welcomePage.help": "Hilfe", + "welcomePage.keybindingsCheatsheet": "Druckbare Tastaturübersicht", "welcomePage.introductoryVideos": "Einführungsvideos", "welcomePage.productDocumentation": "Produktdokumentation", "welcomePage.gitHubRepository": "GitHub-Repository", "welcomePage.stackOverflow": "Stack Overflow", "welcomePage.showOnStartup": "Willkommensseite beim Start anzeigen", "welcomePage.customize": "Anpassen", + "welcomePage.installExtensionPacks": "Tools und Sprachen", + "welcomePage.installExtensionPacksDescription": "Unterstützung für {0} und {1} installieren", "welcomePage.moreExtensions": "mehr", "welcomePage.installKeymapDescription": "Tastenkombinationen installieren", + "welcomePage.installKeymapExtension": "Installieren Sie die Tastenkombinationen von {0} und {1}.", "welcomePage.others": "Andere", "welcomePage.colorTheme": "Farbdesign", "welcomePage.colorThemeDescription": "Passen Sie das Aussehen des Editors und Ihres Codes an Ihre Wünsche an.", "welcomePage.learn": "Lernen", "welcomePage.showCommands": "Alle Befehle suchen und ausführen", - "welcomePage.showCommandsDescription": "Ãœber die Einstellungen ({0}) können Sie Befehle schnell suchen und darauf zugreifen.", "welcomePage.interfaceOverview": "Ãœberblick über die Schnittstelle", "welcomePage.interfaceOverviewDescription": "Erhalten Sie eine visuelle Ãœberlagerung, die die wichtigsten Komponenten der Benutzeroberfläche hervorhebt.", "welcomePage.interactivePlayground": "Interaktiver Playground", diff --git a/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json b/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json index f83bfd761c7..399910772ce 100644 --- a/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json @@ -4,7 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "workbenchConfigurationTitle": "Workbench", - "welcomePage.enabled": "Wenn diese Option aktiviert ist, wird die Willkommensseite beim Start angezeigt.", "help": "Hilfe" } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index a6f6f26a54a..bd211db7d59 100644 --- a/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -4,6 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "workbenchConfigurationTitle": "Workbench", + "welcomePage.enabled": "Wenn diese Option aktiviert ist, wird die Willkommensseite beim Start angezeigt.", "welcomePage": "Willkommen", "welcomePage.javaScript": "JavaScript", "welcomePage.typeScript": "TypeScript", @@ -14,11 +16,23 @@ "welcomePage.sublime": "Sublime", "welcomePage.atom": "Atom", "welcomePage.extensionPackAlreadyInstalled": "Unterstützung für {0} ist bereits installiert.", + "welcomePage.willReloadAfterInstallingExtensionPack": "Nach dem Installieren zusätzlicher Unterstützung für {0} wird das Fenster neu geladen.", + "welcomePage.installingExtensionPack": "Zusätzliche Unterstützung für {0} wird installiert...", + "welcomePage.extensionPackNotFound": "Unterstützung für {0} mit der ID {1} wurde nicht gefunden.", "welcomePage.keymapAlreadyInstalled": "Die {0} Tastenkombinationen sind bereits installiert.", "welcomePage.willReloadAfterInstallingKeymap": "Das Fenster wird nach der Installation der {0}-Tastaturbefehle neu geladen.", "welcomePage.installingKeymap": "Die {0}-Tastenkombinationen werden installiert...", "welcomePage.keymapNotFound": "Die {0} Tastenkombinationen mit der ID {1} wurden nicht gefunden.", "welcome.title": "Willkommen", + "welcomePage.openFolderWithPath": "Ordner {0} mit Pfad {1} öffnen", + "welcomePage.extensionListSeparator": ",", + "welcomePage.installKeymap": "Tastenzuordnung {0} öffnen", + "welcomePage.installExtensionPack": "Zusätzliche Unterstützung für {0} installieren", + "welcomePage.installedKeymap": "Die Tastaturzuordnung {0} ist bereits installiert.", + "welcomePage.installedExtensionPack": "Unterstützung für {0} ist bereits installiert.", "ok": "OK", - "cancel": "Abbrechen" + "details": "Details", + "cancel": "Abbrechen", + "welcomePage.buttonBackground": "Hintergrundfarbe für die Schaltflächen auf der Willkommensseite.", + "welcomePage.buttonHoverBackground": "Hoverhintergrundfarbe für die Schaltflächen auf der Willkommensseite." } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json b/i18n/deu/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json index 197be5e3800..f8c9526c03a 100644 --- a/i18n/deu/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json +++ b/i18n/deu/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json @@ -5,5 +5,6 @@ // Do not edit this file. It is machine generated. { "walkThrough.unboundCommand": "Ungebunden", - "walkThrough.gitNotFound": "Git scheint auf Ihrem System nicht installiert zu sein." + "walkThrough.gitNotFound": "Git scheint auf Ihrem System nicht installiert zu sein.", + "walkThrough.embeddedEditorBackground": "Hintergrundfarbe für die eingebetteten Editoren im Interaktiven Playground." } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json b/i18n/deu/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json index 0c8e653b4e5..8f33c300c01 100644 --- a/i18n/deu/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json +++ b/i18n/deu/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json @@ -6,6 +6,12 @@ { "open": "Einstellungen öffnen", "close": "Schließen", + "saveAndRetry": "Änderungen Speichern und Wiederholen", "errorUnknownKey": "Die Konfigurationsdatei kann nicht geschrieben werden (unbekannter Schlüssel).", - "errorInvalidTarget": "In die Konfigurationsdatei kann nicht geschrieben werden (ungültiges Ziel)." + "errorInvalidTarget": "In die Konfigurationsdatei kann nicht geschrieben werden (ungültiges Ziel).", + "errorNoWorkspaceOpened": "In die Einstellungen kann nicht geschrieben werden, weil kein Ordner geöffnet ist. Öffnen Sie zuerst einen Ordner, und versuchen Sie es noch mal.", + "errorInvalidConfiguration": "In die Einstellungen kann nicht geschrieben werden. Öffnen Sie **Benutzereinstellungen**, um Fehler/Warnungen in der Datei zu korrigieren, und versuchen Sie es noch mal.", + "errorInvalidConfigurationWorkspace": "In die Einstellungen kann nicht geschrieben werden. Öffnen Sie die **Arbeitsbereichseinstellungen**, um Fehler/Warnungen in der Datei zu korrigieren, und versuchen Sie es noch mal.", + "errorConfigurationFileDirty": "In die Einstellungen kann nicht geschrieben werden, weil die Datei geändert wurde. Speichern Sie die Datei **Benutzereinstellungen**, und versuchen Sie es noch mal.", + "errorConfigurationFileDirtyWorkspace": "In die Einstellungen kann nicht geschrieben werden, weil die Datei geändert wurde. Speichern Sie die Datei **Arbeitsbereichseinstellungen**, und versuchen Sie es noch mal." } \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json b/i18n/deu/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json new file mode 100644 index 00000000000..f7a2d1f0c3f --- /dev/null +++ b/i18n/deu/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "telemetryConfigurationTitle": "Telemetrie", + "telemetry.enableCrashReporting": "Aktiviert Absturzberichte, die an Microsoft gesendet werden.\nDiese Option erfordert einen Neustart, damit sie wirksam wird." +} \ No newline at end of file diff --git a/i18n/deu/src/vs/workbench/services/progress/browser/progressService2.i18n.json b/i18n/deu/src/vs/workbench/services/progress/browser/progressService2.i18n.json new file mode 100644 index 00000000000..6db7d6aae51 --- /dev/null +++ b/i18n/deu/src/vs/workbench/services/progress/browser/progressService2.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "progress.text": "{0} - {1}", + "progress.title": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/esn/extensions/git/package.i18n.json b/i18n/esn/extensions/git/package.i18n.json index afda046fe5a..607d4f1df81 100644 --- a/i18n/esn/extensions/git/package.i18n.json +++ b/i18n/esn/extensions/git/package.i18n.json @@ -32,7 +32,7 @@ "command.push": "Insertar", "command.pushTo": "Insertar en...", "command.sync": "Sincronizar", - "command.publish": "Publicar", + "command.publish": "Publicar rama", "command.showOutput": "Mostrar salida de GIT", "config.enabled": "Si GIT está habilitado", "config.path": "Ruta de acceso del ejecutable de GIT", diff --git a/i18n/esn/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/esn/extensions/merge-conflict/out/codelensProvider.i18n.json index 8b6ad71cd4e..22ca13053b5 100644 --- a/i18n/esn/extensions/merge-conflict/out/codelensProvider.i18n.json +++ b/i18n/esn/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -3,4 +3,9 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "acceptCurrentChange": "Aceptar cambio actual", + "acceptIncomingChange": "Aceptar cambio entrante", + "acceptBothChanges": "Aceptar ambos cambios", + "compareChanges": "Comparar cambios" +} \ No newline at end of file diff --git a/i18n/esn/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/esn/extensions/merge-conflict/out/commandHandler.i18n.json index c3d2c17c302..e94eadacd8d 100644 --- a/i18n/esn/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/esn/extensions/merge-conflict/out/commandHandler.i18n.json @@ -5,6 +5,8 @@ // Do not edit this file. It is machine generated. { "cursorNotInConflict": "El cursor de edición no se encuentra en un conflicto de fusión", + "compareChangesTitle": "{0}: Cambios actuales ⟷ Cambios entrantes", + "cursorOnCommonAncestorsRange": "El cursor del editor está dentro del bloque de ancestros comunes, por favor muévalo al bloque \"actual\" o al \"entrante\"", "cursorOnSplitterRange": "El cursor del editor está dentro del separador de conflictos de fusión, muévalo al bloque \"actual\" o al \"entrante\" ", "noConflicts": "No se encontraron conflictos en este archivo", "noOtherConflictsInThisFile": "No hay más conflictos en este archivo" diff --git a/i18n/esn/extensions/merge-conflict/package.i18n.json b/i18n/esn/extensions/merge-conflict/package.i18n.json index 97bdb649962..b72c99c527d 100644 --- a/i18n/esn/extensions/merge-conflict/package.i18n.json +++ b/i18n/esn/extensions/merge-conflict/package.i18n.json @@ -5,7 +5,15 @@ // Do not edit this file. It is machine generated. { "command.category": "Fusionar conflicto", + "command.accept.all-incoming": "Aceptar todos los entrantes", + "command.accept.all-both": "Aceptar ambos", + "command.accept.current": "Aceptar actuales", + "command.accept.incoming": "Aceptar entrantes", + "command.accept.selection": "Aceptar selección", "command.accept.both": "Aceptar ambos", + "command.next": "Siguiente conflicto", + "command.previous": "Conflicto anterior", + "command.compare": "Comparar conflicto actual", "config.title": "Fusionar conflicto", "config.codeLensEnabled": "Habilitar/deshabilitar CodeLens de fusionar bloque de conflictos en el editor", "config.decoratorsEnabled": "Habilitar/deshabilitar decoradores de conflictos de fusión en el editor" diff --git a/i18n/esn/extensions/typescript/out/features/bufferSyncSupport.i18n.json b/i18n/esn/extensions/typescript/out/features/bufferSyncSupport.i18n.json index ce77997be34..11669b0c32b 100644 --- a/i18n/esn/extensions/typescript/out/features/bufferSyncSupport.i18n.json +++ b/i18n/esn/extensions/typescript/out/features/bufferSyncSupport.i18n.json @@ -4,7 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "versionMismatch": "Las versiones no coinciden; global tsc ({0}) != servicio de lenguaje de VS Code ({1}). Pueden producirse errores de compilación incoherente.", "moreInformation": "Más información", "doNotCheckAgain": "No volver a comprobar", "close": "Cerrar", diff --git a/i18n/esn/extensions/typescript/out/utils/projectStatus.i18n.json b/i18n/esn/extensions/typescript/out/utils/projectStatus.i18n.json index 22620be6b22..1248c233033 100644 --- a/i18n/esn/extensions/typescript/out/utils/projectStatus.i18n.json +++ b/i18n/esn/extensions/typescript/out/utils/projectStatus.i18n.json @@ -6,7 +6,6 @@ { "hintExclude": "Para habilitar las características de lenguaje de JavaScript/TypeScript en todo el proyecto, excluya las carpetas con muchos archivos, como: {0}", "hintExclude.generic": "Para habilitar las características de idioma de JavaScript/TypeScript IntelliSense en todo el proyecto, excluya las carpetas de tamaño grande con archivos de origen en los que no trabaje.", - "open": "Configurar exclusiones", "large.label": "Configurar exclusiones", "hintExclude.tooltip": "Para habilitar las características de idioma de JavaScript/TypeScript IntelliSense en todo el proyecto, excluya las carpetas de tamaño grande con archivos de origen en los que no trabaje." } \ No newline at end of file diff --git a/i18n/esn/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/esn/extensions/typescript/out/utils/typingsStatus.i18n.json index 0d39c772a73..0d41f3ba91c 100644 --- a/i18n/esn/extensions/typescript/out/utils/typingsStatus.i18n.json +++ b/i18n/esn/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "installingPackages": "Recuperando cambios en los datos para un mejor rendimiento de TypeScript IntelliSense", + "typesInstallerInitializationFailed.title": "No se pudieron instalar archivos de términos para las características de lenguaje de JavaScript. Asegúrese de que NPM está instalado o configure \"typescript.npm\" en la configuración de usuario", "typesInstallerInitializationFailed.moreInformation": "Más información", "typesInstallerInitializationFailed.doNotCheckAgain": "No volver a comprobar", "typesInstallerInitializationFailed.close": "Cerrar" diff --git a/i18n/esn/extensions/typescript/package.i18n.json b/i18n/esn/extensions/typescript/package.i18n.json index 3de04eb5b4a..95927c8d1dd 100644 --- a/i18n/esn/extensions/typescript/package.i18n.json +++ b/i18n/esn/extensions/typescript/package.i18n.json @@ -13,7 +13,6 @@ "typescript.check.tscVersion": "Compruebe si un compilador de TypeScript de instalación global (p. ej., tsc) difiere del servicio de lenguaje de TypeScript usado.", "typescript.tsserver.log": "votes Habilita los registros del servidor TS a un archivo. Este registro se puede utilizar para diagnosticar problemas en el servidor TS. Este registro puede contener rutas de acceso, código fuente y posiblemente otra información sensitiva acerca del proyecto.", "typescript.tsserver.trace": "Habilita el seguimiento de mensajes al servidor TS. Este seguimiento se puede utilizar para diagnosticar problemas en el servidor TS. Este seguimiento puede contener rutas de acceso, código fuente y posiblemente otra información sensitiva acerca del proyecto.", - "typescript.tsserver.experimentalAutoBuild": "Permite la generación automática experimental. Requiere la versión de desarrollo 1.9 o tsserver 2.x y un reinicio de VS Code después de modificarlo.", "typescript.validate.enable": "Habilita o deshabilita la validación de TypeScript.", "typescript.format.enable": "Habilita o deshabilita el formateador predeterminado de TypeScript.", "javascript.format.enable": "Habilita o deshabilita el formateador predeterminado de JavaScript.", @@ -41,5 +40,8 @@ "typescript.selectTypeScriptVersion.title": "Seleccionar versión de TypeScript", "jsDocCompletion.enabled": "Habilita o deshabilita comentarios automaticos de JSDoc", "javascript.implicitProjectConfig.checkJs": "Habilita/deshabilita la comprobación semántica de los archivos JavaScript. Los archivos jsconfig.json o tsconfig.json reemplazan esta configuración. Se requiere TypeScript >=2.3.1.", - "javascript.nameSuggestions": "Habilitar/deshabilitar nombres únicos de la lista de sugerencias en los archivos de JavaScript. " + "typescript.npm": "Especifica la ruta de acceso al archivo ejecutable de NPM usada para la adquisición automática de tipos. Requiere TypeScript >= 2.3.4.", + "typescript.check.npmIsInstalled": "Compruebe si NPM está instalado para la adquisición automática de tipos.", + "javascript.nameSuggestions": "Habilitar/deshabilitar nombres únicos de la lista de sugerencias en los archivos de JavaScript. ", + "typescript.tsc.autoDetect": "Controla si la detección automática de tareas TSC está activada o desactivada." } \ No newline at end of file diff --git a/i18n/esn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/esn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index 8029ab0b3bd..169c17eadd6 100644 --- a/i18n/esn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/esn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,6 +6,7 @@ { "imgMeta": "{0} x {1} {2}", "largeImageError": "La imagen es muy grande para mostrar en el editor", + "resourceOpenExternalButton": "¿Abrir la imagen mediante un programa externo?", "nativeBinaryError": "El archivo no se mostrará en el editor porque es binario, muy grande o usa una codificación de texto no compatible.", "sizeB": "{0} B", "sizeKB": "{0} KB", diff --git a/i18n/esn/src/vs/base/common/errorMessage.i18n.json b/i18n/esn/src/vs/base/common/errorMessage.i18n.json index ccfa6a32d0b..88c477aba6a 100644 --- a/i18n/esn/src/vs/base/common/errorMessage.i18n.json +++ b/i18n/esn/src/vs/base/common/errorMessage.i18n.json @@ -13,6 +13,5 @@ "error.connection.unknown": "Error de conexión desconocido. Es posible que ya no esté conectado a Internet o que el servidor al que se había conectado esté sin conexión.", "stackTrace.format": "{0}: {1}", "error.defaultMessage": "Se ha producido un error desconocido. Consulte el registro para obtener más detalles.", - "nodeExceptionMessage": "Error del sistema ({0})", "error.moreErrors": "{0} ({1} errores en total)" } \ No newline at end of file diff --git a/i18n/esn/src/vs/base/common/keybindingLabels.i18n.json b/i18n/esn/src/vs/base/common/keybindingLabels.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/esn/src/vs/base/common/keybindingLabels.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/esn/src/vs/code/electron-main/menus.i18n.json b/i18n/esn/src/vs/code/electron-main/menus.i18n.json index 4b1468558ad..52fa22103d7 100644 --- a/i18n/esn/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/esn/src/vs/code/electron-main/menus.i18n.json @@ -55,6 +55,9 @@ "miShowEmmetCommands": "E&&mmet...", "miToggleLineComment": "&&Alternar comentario de línea", "miToggleBlockComment": "Alternar &&Bloquear comentario", + "miMultiCursorAlt": "Usar Alt+Clic para multicursor", + "miMultiCursorCmd": "Usar Cmd+Clic para multicursor", + "miMultiCursorCtrl": "Usar Ctrl+Clic para multicursor", "miInsertCursorAbove": "&&Agregar cursor arriba", "miInsertCursorBelow": "A&&gregar cursor abajo", "miInsertCursorAtEndOfEachLineSelected": "Agregar c&&ursores a extremos de línea", @@ -133,11 +136,11 @@ "miColumnBreakpoint": "Punto de interrupción de c&&olumna", "miFunctionBreakpoint": "Punto de interrupción de &&función...", "miNewBreakpoint": "&&Nuevo punto de interrupción", + "miEnableAllBreakpoints": "Habilitar todos los puntos de interrupción", "miDisableAllBreakpoints": "&&Deshabilitar todos los puntos de interrupción", "miRemoveAllBreakpoints": "Quitar &&todos los puntos de interrupción", "miInstallAdditionalDebuggers": "&&Instalar los depuradores adicionales...", "mMinimize": "Minimizar", - "mClose": "Cerrar", "mBringToFront": "Traer todo al frente", "miToggleDevTools": "&&Alternar herramientas de desarrollo", "miAccessibilityOptions": "&&Opciones de accesibilidad", @@ -153,12 +156,14 @@ "miLicense": "Ver &&licencia", "miPrivacyStatement": "&&Declaración de privacidad", "miAbout": "&&Acerca de", + "miTerminateTask": "&&Finalizar tarea", "accessibilityOptionsWindowTitle": "Opciones de accesibilidad", "miRestartToUpdate": "Reiniciar para actualizar...", "miCheckingForUpdates": "Buscando actualizaciones...", "miDownloadUpdate": "Descargar actualización disponible", "miDownloadingUpdate": "Descargando actualización...", "miInstallingUpdate": "Instalando actualización...", + "miCheckForUpdates": "Buscar actualizaciones...", "aboutDetail": "\nVersión {0}\nConfirmación {1}\nFecha {2}\nShell {3}\nRepresentador {4}\nNode {5}", "okButton": "Aceptar" } \ No newline at end of file diff --git a/i18n/esn/src/vs/code/electron-main/windows.i18n.json b/i18n/esn/src/vs/code/electron-main/windows.i18n.json index 80fb2bc32dc..959ddae2446 100644 --- a/i18n/esn/src/vs/code/electron-main/windows.i18n.json +++ b/i18n/esn/src/vs/code/electron-main/windows.i18n.json @@ -13,9 +13,5 @@ "appStalled": "La ventana ha dejado de responder.", "appStalledDetail": "Puede volver a abrir la ventana, cerrarla o seguir esperando.", "appCrashed": "La ventana se bloqueó", - "appCrashedDetail": "Sentimos las molestias. Puede volver a abrir la ventana para continuar donde se detuvo.", - "newWindow": "Nueva ventana", - "newWindowDesc": "Abre una ventana nueva.", - "recentFolders": "Carpetas recientes", - "folderDesc": "{0} {1}" + "appCrashedDetail": "Sentimos las molestias. Puede volver a abrir la ventana para continuar donde se detuvo." } \ No newline at end of file diff --git a/i18n/esn/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/esn/src/vs/editor/common/config/commonEditorConfig.i18n.json index 8fe058e55ce..c70492563f8 100644 --- a/i18n/esn/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/esn/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -23,6 +23,8 @@ "minimap.enabled": "Controla si se muestra el minimapa", "minimap.renderCharacters": "Presentar los caracteres reales en una línea (por oposición a bloques de color)", "minimap.maxColumn": "Limitar el ancho del minimapa para presentar como mucho un número de columnas determinado", + "find.seedSearchStringFromSelection": "Controla si se inicializa la cadena de búsqueda en Buscar widget en la selección del editor", + "find.autoFindInSelection": "Controla si el indicador Buscar en selección se activa cuando se seleccionan varios caracteres o líneas de texto en el editor", "wordWrap.off": "Las líneas no se ajustarán nunca.", "wordWrap.on": "Las líneas se ajustarán en el ancho de la ventanilla.", "wordWrap.wordWrapColumn": "Las líneas se ajustarán en \"editor.wordWrapColumn\".", @@ -31,16 +33,19 @@ "wordWrapColumn": "Controls the wrapping column of the editor when `editor.wordWrap` is 'wordWrapColumn' or 'bounded'.", "wrappingIndent": "Controla el sangrado de las líneas ajustadas. Puede ser uno los valores 'none', 'same' o 'indent'.", "mouseWheelScrollSensitivity": "Se utilizará un multiplicador en los eventos de desplazamiento de la rueda del mouse `deltaX` y `deltaY`", + "multiCursorModifier.ctrlCmd": "Se asigna a \"Control\" en Windows y Linux y a \"Comando\" en OSX.", + "multiCursorModifier.alt": "Se asigna a \"Alt\" en Windows y Linux y a \"Opción\" en OSX.", + "multiCursorModifier": "El modificador que se usará para agregar varios cursores con el mouse. \"ctrlCmd\" se asigna a \"Control\" en Windows y Linux y a \"Comando\" en OSX. Los gestos del mouse Ir a la definición y Abrir vínculo se adaptarán de modo que no entren en conflicto con el modificador multicursor.", "quickSuggestions.strings": "Habilita sugerencias rápidas en las cadenas.", "quickSuggestions.comments": "Habilita sugerencias rápidas en los comentarios.", "quickSuggestions.other": "Habilita sugerencias rápidas fuera de las cadenas y los comentarios.", "quickSuggestions": "Controla si las sugerencias deben mostrarse automáticamente mientras se escribe", "quickSuggestionsDelay": "Controla el retardo en ms tras el cual aparecerán sugerencias rápidas", - "parameterHints": "Habilita sugerencias de parámetro", "autoClosingBrackets": "Controla si el editor debe cerrar automáticamente los corchetes después de abrirlos", "formatOnType": "Controla si el editor debe dar formato automáticamente a la línea después de escribirla", "formatOnPaste": "Controla si el editor debe formatear automáticamente el contenido pegado. Debe haber disponible un formateador capaz de aplicar formato a un intervalo dentro de un documento.", "suggestOnTriggerCharacters": "Controla si las sugerencias deben aparecer de forma automática al escribir caracteres desencadenadores", + "acceptSuggestionOnEnter": "Controla si las sugerencias deben aceptarse en \"Entrar\" (además de \"TAB\"). Ayuda a evitar la ambigüedad entre insertar nuevas líneas o aceptar sugerencias. El valor \"smart\" significa que solo se acepta una sugerencia con Entrar cuando se realiza un cambio textual.", "acceptSuggestionOnCommitCharacter": "Controla si se deben aceptar sugerencias en los caracteres de confirmación. Por ejemplo, en Javascript, el punto y coma (\";\") puede ser un carácter de confirmación que acepta una sugerencia y escribe ese carácter.", "snippetSuggestions": "Controla si se muestran los fragmentos de código con otras sugerencias y cómo se ordenan.", "emptySelectionClipboard": "Controla si al copiar sin selección se copia la línea actual.", @@ -69,6 +74,10 @@ "trimAutoWhitespace": "Quitar espacio en blanco final autoinsertado", "stablePeek": "Mantiene abierto el editor interactivo incluso al hacer doble clic en su contenido o presionar Escape.", "dragAndDrop": "Controla si el editor debe permitir mover selecciones mediante arrastrar y colocar.", + "accessibilitySupport.auto": "El editor usará API de plataforma para detectar cuándo está conectado un lector de pantalla.", + "accessibilitySupport.on": "El editor se optimizará de forma permanente para su uso con un editor de pantalla.", + "accessibilitySupport.off": "El editor nunca se optimizará para su uso con un lector de pantalla.", + "accessibilitySupport": "Controla si el editor se debe ejecutar en un modo optimizado para lectores de pantalla.", "sideBySide": "Controla si el editor de diferencias muestra las diferencias en paralelo o alineadas.", "ignoreTrimWhitespace": "Controla si el editor de diferencias muestra los cambios de espacio inicial o espacio final como diferencias.", "renderIndicators": "Controla si el editor de diff muestra indicadores +/- para cambios agregados/quitados", diff --git a/i18n/esn/src/vs/editor/common/config/editorOptions.i18n.json b/i18n/esn/src/vs/editor/common/config/editorOptions.i18n.json index b1da401aa98..c82ce873006 100644 --- a/i18n/esn/src/vs/editor/common/config/editorOptions.i18n.json +++ b/i18n/esn/src/vs/editor/common/config/editorOptions.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "accessibilityOffAriaLabel": "No se puede acceder al editor en este momento. Presione Alt+F1 para ver opciones.", "editorViewAccessibleLabel": "Contenido del editor" } \ No newline at end of file diff --git a/i18n/esn/src/vs/editor/common/view/editorColorRegistry.i18n.json b/i18n/esn/src/vs/editor/common/view/editorColorRegistry.i18n.json index fcdba2ee5ad..e5d0cfe1b5b 100644 --- a/i18n/esn/src/vs/editor/common/view/editorColorRegistry.i18n.json +++ b/i18n/esn/src/vs/editor/common/view/editorColorRegistry.i18n.json @@ -16,5 +16,9 @@ "editorBracketMatchBackground": "Color de fondo tras corchetes coincidentes", "editorBracketMatchBorder": "Color de bloques con corchetes coincidentes", "editorOverviewRulerBorder": "Color del borde de la regla de visión general.", - "editorGutter": "Color de fondo del margen del editor. Este espacio contiene los márgenes de glifos y los números de línea." + "editorGutter": "Color de fondo del margen del editor. Este espacio contiene los márgenes de glifos y los números de línea.", + "errorForeground": "Color de primer plano de squigglies de error en el editor.", + "errorBorder": "Color de borde de squigglies de error en el editor.", + "warningForeground": "Color de primer plano de squigglies de advertencia en el editor.", + "warningBorder": "Color de borde de squigglies de advertencia en el editor." } \ No newline at end of file diff --git a/i18n/esn/src/vs/editor/contrib/find/common/findController.i18n.json b/i18n/esn/src/vs/editor/contrib/find/common/findController.i18n.json index a16ef436a20..70c6090fd32 100644 --- a/i18n/esn/src/vs/editor/contrib/find/common/findController.i18n.json +++ b/i18n/esn/src/vs/editor/contrib/find/common/findController.i18n.json @@ -14,6 +14,5 @@ "addSelectionToPreviousFindMatch": "Agregar selección hasta la anterior coincidencia de búsqueda", "moveSelectionToNextFindMatch": "Mover última selección hasta la siguiente coincidencia de búsqueda", "moveSelectionToPreviousFindMatch": "Mover última selección hasta la anterior coincidencia de búsqueda", - "selectAllOccurencesOfFindMatch": "Seleccionar todas las repeticiones de coincidencia de búsqueda", "changeAll.label": "Cambiar todas las ocurrencias" } \ No newline at end of file diff --git a/i18n/esn/src/vs/editor/contrib/links/browser/links.i18n.json b/i18n/esn/src/vs/editor/contrib/links/browser/links.i18n.json index 9446261fac5..7b9ee53d86a 100644 --- a/i18n/esn/src/vs/editor/contrib/links/browser/links.i18n.json +++ b/i18n/esn/src/vs/editor/contrib/links/browser/links.i18n.json @@ -6,6 +6,7 @@ { "links.navigate.mac": "Cmd + clic para abrir el vínculo", "links.navigate": "Ctrl + clic para abrir el vínculo", + "links.navigate.al": "Alt + clic para seguir el vínculo", "invalid.url": "No se pudo abrir este vínculo porque no tiene un formato correcto: {0}", "missing.url": "No se pudo abrir este vínculo porque falta el destino.", "label": "Abrir vínculo" diff --git a/i18n/esn/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json b/i18n/esn/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json index 515c40c0c1d..2d8140e32a7 100644 --- a/i18n/esn/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json +++ b/i18n/esn/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json @@ -5,8 +5,6 @@ // Do not edit this file. It is machine generated. { "aria.oneReference": "símbolo en {0} linea {1} en la columna {2}", - "aria.fileReferences.1": "1 símbolo en {0}", - "aria.fileReferences.N": "{0} símbolos en {1}", "aria.result.0": "No se encontraron resultados", "aria.result.1": "Encontró 1 símbolo en {0}", "aria.result.n1": "Encontró {0} símbolos en {1}", diff --git a/i18n/esn/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json b/i18n/esn/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json index 963cc3dbe3d..253f50641c3 100644 --- a/i18n/esn/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json +++ b/i18n/esn/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json @@ -14,13 +14,15 @@ "vscode.extension.contributes.menus": "Contribuye con elementos de menú al editor", "menus.commandPalette": "La paleta de comandos", "menus.editorTitle": "El menú de título del editor", - "menus.editorContext": "El menú conextual del editor", + "menus.editorContext": "El menú contextual del editor", "menus.explorerContext": "El menú contextual del explorador de archivos", - "menus.editorTabContext": "Menú contextual de pestañas del editor", + "menus.editorTabContext": "El menú contextual de pestañas del editor", "menus.debugCallstackContext": "El menú contextual de la pila de llamadas de depuración", "menus.scmTitle": "El menú del título Control de código fuente", "menus.resourceGroupContext": "El menú contextual del grupo de recursos de Control de código fuente", "menus.resourceStateContext": "El menú contextual de estado de recursos de Control de código fuente", + "view.viewTitle": "El menú de título de vista contribuida", + "view.itemContext": "El menú contextual del elemento de vista contribuida", "nonempty": "se esperaba un valor no vacío.", "opticon": "la propiedad `icon` se puede omitir o debe ser una cadena o un literal como `{dark, light}`", "requireStringOrObject": "La propiedad \"{0}\" es obligatoria y debe ser de tipo \"string\" u \"object\"", diff --git a/i18n/esn/src/vs/platform/extensions/common/extensionsRegistry.i18n.json b/i18n/esn/src/vs/platform/extensions/common/extensionsRegistry.i18n.json index 09295c5362b..b7b9d3c4f35 100644 --- a/i18n/esn/src/vs/platform/extensions/common/extensionsRegistry.i18n.json +++ b/i18n/esn/src/vs/platform/extensions/common/extensionsRegistry.i18n.json @@ -14,6 +14,12 @@ "vscode.extension.contributes": "Todas las contribuciones de la extensión VS Code representadas por este paquete.", "vscode.extension.preview": "Establece la extensión que debe marcarse como versión preliminar en Marketplace.", "vscode.extension.activationEvents": "Eventos de activación de la extensión VS Code.", + "vscode.extension.activationEvents.onLanguage": "Un evento de activación emitido cada vez que se abre un archivo que se resuelve en el idioma especificado.", + "vscode.extension.activationEvents.onCommand": "Un evento de activación emitido cada vez que se invoca el comando especificado.", + "vscode.extension.activationEvents.onDebug": "Un evento de activación emitido cada vez que se inicia una sesión de depuración del tipo especificado.", + "vscode.extension.activationEvents.workspaceContains": "Un evento de activación emitido cada vez que se abre una carpeta que contiene al menos un archivo que coincide con el patrón global especificado.", + "vscode.extension.activationEvents.onView": "Un evento de activación emitido cada vez que se expande la vista especificada.", + "vscode.extension.activationEvents.star": "Un evento de activación emitido al inicio de VS Code. Para garantizar una buena experiencia para el usuario final, use este evento de activación en su extensión solo cuando no le sirva ninguna otra combinación de eventos de activación en su caso.", "vscode.extension.badges": "Matriz de distintivos que se muestran en la barra lateral de la página de extensiones de Marketplace.", "vscode.extension.badges.url": "URL de la imagen del distintivo.", "vscode.extension.badges.href": "Vínculo del distintivo.", diff --git a/i18n/esn/src/vs/platform/history/electron-main/historyMainService.i18n.json b/i18n/esn/src/vs/platform/history/electron-main/historyMainService.i18n.json new file mode 100644 index 00000000000..ef4f14a4e29 --- /dev/null +++ b/i18n/esn/src/vs/platform/history/electron-main/historyMainService.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "newWindow": "Nueva ventana", + "newWindowDesc": "Abre una ventana nueva.", + "recentFolders": "Carpetas recientes", + "folderDesc": "{0} {1}" +} \ No newline at end of file diff --git a/i18n/esn/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/esn/src/vs/platform/theme/common/colorRegistry.i18n.json index c20c4e2b34f..91c6d95a0e2 100644 --- a/i18n/esn/src/vs/platform/theme/common/colorRegistry.i18n.json +++ b/i18n/esn/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -12,7 +12,6 @@ "focusBorder": "Color de borde de los elementos con foco. Este color solo se usa si un componente no lo invalida.", "contrastBorder": "Un borde adicional alrededor de los elementos para separarlos unos de otros y así mejorar el contraste.", "activeContrastBorder": "Un borde adicional alrededor de los elementos activos para separarlos unos de otros y así mejorar el contraste.", - "selectionBackground": "El color de fondo del texto seleccionado en la área de trabajo (por ejemplo, campos de entrada o áreas de texto). Esto no se aplica a las selecciones dentro del editor o el terminal.", "textSeparatorForeground": "Color para los separadores de texto.", "textLinkForeground": "Color de primer plano para los vínculos en el texto.", "textLinkActiveForeground": "Color de primer plano para los vínculos activos en el texto.", @@ -60,6 +59,7 @@ "editorBackground": "Color de fondo del editor.", "editorForeground": "Color de primer plano predeterminado del editor.", "editorWidgetBackground": "Color de fondo del editor de widgets como buscar/reemplazar", + "editorWidgetBorder": "Color de borde de los widgets del editor. El color solo se usa si el widget elige tener un borde y no invalida el color.", "editorSelection": "Color de la selección del editor.", "editorInactiveSelection": "Color de la selección en un editor inactivo.", "editorSelectionHighlight": "Color de las regiones con el mismo contenido que la selección.", @@ -73,5 +73,12 @@ "diffEditorInserted": "Color de fondo para el texto insertado.", "diffEditorRemoved": "Color de fondo para el texto quitado.", "diffEditorInsertedOutline": "Color de contorno para el texto insertado.", - "diffEditorRemovedOutline": "Color de contorno para el texto quitado." + "diffEditorRemovedOutline": "Color de contorno para el texto quitado.", + "mergeCurrentHeaderBackground": "Fondo del encabezado actual en conflictos de combinación alineados.", + "mergeCurrentContentBackground": "Fondo del contenido actual en conflictos de combinación alineados.", + "mergeIncomingHeaderBackground": "Fondo del encabezado de entrada en conflictos de combinación alineados.", + "mergeIncomingContentBackground": "Fondo del contenido de entrada en conflcitos de combinación alineados.", + "mergeBorder": "Color del borde en los encabezados y el divisor en conflictos de combinación alineados.", + "overviewRulerCurrentContentForeground": "Primer plano de la regla de visión general actual para conflictos de combinación alineados.", + "overviewRulerIncomingContentForeground": "Primer plano de regla de visión general de entrada para conflictos de combinación alineados." } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/esn/src/vs/workbench/api/node/extHostTask.i18n.json index 8b6ad71cd4e..4b90a12aaf2 100644 --- a/i18n/esn/src/vs/workbench/api/node/extHostTask.i18n.json +++ b/i18n/esn/src/vs/workbench/api/node/extHostTask.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "task.label": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json b/i18n/esn/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json index 86c8b000ea6..bfe695f895b 100644 --- a/i18n/esn/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json +++ b/i18n/esn/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json @@ -5,5 +5,6 @@ // Do not edit this file. It is machine generated. { "hideActivitBar": "Ocultar barra de actividades", - "activityBarAriaLabel": "Modificador de vista activa" + "activityBarAriaLabel": "Modificador de vista activa", + "globalActions": "Acciones globales" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json b/i18n/esn/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json index 399678bda19..57f49827a55 100644 --- a/i18n/esn/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json +++ b/i18n/esn/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json @@ -10,7 +10,7 @@ "multiSelection": "{0} selecciones", "endOfLineLineFeed": "LF", "endOfLineCarriageReturnLineFeed": "CRLF", - "tabFocusModeEnabled": "La tabulación mueve el foco", + "screenReaderDetectedExtra": "Si no va a usar un lector de pantalla, cambie el valor de configuración \"editor.accessibilitySupport\" a \"desactivado\".", "disableTabMode": "Deshabilitar modo de accesibilidad", "gotoLine": "Ir a la línea", "indentation": "Sangría", diff --git a/i18n/esn/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json b/i18n/esn/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json new file mode 100644 index 00000000000..7a95e7a0c69 --- /dev/null +++ b/i18n/esn/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpen": "Ir al archivo...", + "quickNavigateNext": "Navegar a siguiente en Quick Open", + "quickNavigatePrevious": "Navegar a anterior en Quick Open", + "quickSelectNext": "Seleccionar Siguiente en Quick Open", + "quickSelectPrevious": "Seleccionar Anterior en Quick Open" +} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/browser/quickopen.i18n.json b/i18n/esn/src/vs/workbench/browser/quickopen.i18n.json index bc196c6f357..6677960aba0 100644 --- a/i18n/esn/src/vs/workbench/browser/quickopen.i18n.json +++ b/i18n/esn/src/vs/workbench/browser/quickopen.i18n.json @@ -6,6 +6,5 @@ { "noResultsMatching": "No hay resultados coincidentes", "noResultsFound2": "No se encontraron resultados", - "entryAriaLabel": "{0}, comando", - "noCommands": "No hay comandos coincidentes" + "entryAriaLabel": "{0}, comando" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/browser/viewlet.i18n.json b/i18n/esn/src/vs/workbench/browser/viewlet.i18n.json index 26b81eaef92..ff2c9616178 100644 --- a/i18n/esn/src/vs/workbench/browser/viewlet.i18n.json +++ b/i18n/esn/src/vs/workbench/browser/viewlet.i18n.json @@ -4,6 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "collapse": "Contraer todo", - "viewToolbarAriaLabel": "{0} acciones" + "collapse": "Contraer todo" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/common/theme.i18n.json b/i18n/esn/src/vs/workbench/common/theme.i18n.json index 9ae35bba944..5128dcdbbc0 100644 --- a/i18n/esn/src/vs/workbench/common/theme.i18n.json +++ b/i18n/esn/src/vs/workbench/common/theme.i18n.json @@ -7,31 +7,42 @@ "tabActiveBackground": "Color de fondo de la pestaña activa. Las pestañas son los contenedores de los editores en el área de editores. Se pueden abrir varias pestañas en un grupo de editores. Puede haber varios grupos de editores.", "tabInactiveBackground": "Color de fondo de la pestaña inactiva. Las pestañas son los contenedores de los editores en el área de editores. Se pueden abrir varias pestañas en un grupo de editores. Puede haber varios grupos de editores.", "tabBorder": "Borde para separar las pestañas entre sí. Las pestañas son contenedores de editores en el área de editores. Se pueden abrir varias pestañas en un grupo de editores. Puede haber varios grupos de editores.", + "tabActiveForeground": "Color de primer plano de la pestaña activa en un grupo activo. Las pestañas son los contenedores de los editores en el área de editores. Se pueden abrir varias pestañas en un grupo de editores. Puede haber varios grupos de editores.", + "tabInactiveForeground": "Color de primer plano de la pestaña inactiva en un grupo activo. Las pestañas son los contenedores de los editores en el área de editores. Se pueden abrir varias pestañas en un grupo de editores. Puede haber varios grupos de editores.", + "tabUnfocusedActiveForeground": "Color de primer plano de la pestaña activa en un grupo inactivo. Las pestañas son los contenedores de los editores en el área de editores. Se pueden abrir varias pestañas en un grupo de editores. Puede haber varios grupos de editores.", + "tabUnfocusedInactiveForeground": "Color de primer plano de la pestaña inactiva en un grupo inactivo. Las pestañas son los contenedores de los editores en el área de editores. Se pueden abrir varias pestañas en un grupo de editores. Puede haber varios grupos de editores.", "editorGroupBackground": "Color de fondo de un grupo de editores. Los grupos de editores son los contenedores de los editores. El color de fondo se ve cuando se mueven arrastrando los grupos de editores.", "tabsContainerBackground": "Color de fondo del encabezado del título del grupo de editores cuando las fichas están habilitadas. Los grupos de editores son contenedores de editores.", + "tabsContainerBorder": "Color de borde del encabezado del título del grupo de editores cuando las fichas están habilitadas. Los grupos de editores son contenedores de editores.", "editorGroupHeaderBackground": "Color de fondo del encabezado del título del grupo de editores cuando las fichas están deshabilitadas. Los grupos de editores son contenedores de editores.", "editorGroupBorder": "Color para separar varios grupos de editores entre sí. Los grupos de editores son los contenedores de los editores.", "editorDragAndDropBackground": "Color de fondo cuando se arrastran los editores. El color debería tener transparencia para que el contenido del editor pueda brillar a su través.", + "panelBackground": "Color de fondo del panel. Los paneles se muestran debajo del área de editores y contienen vistas, como Salida y Terminal integrado.", "panelBorder": "Color del borde superior del panel que lo separa del editor. Los paneles se muestran debajo del área de editores y contienen vistas, como Salida y Terminal integrado.", "panelActiveTitleForeground": "Color del título del panel activo. Los paneles se muestran debajo del área del editor y contienen vistas como Salida y Terminal integrado.", "panelInactiveTitleForeground": "Color del título del panel inactivo. Los paneles se muestran debajo del área del editor y contienen vistas como Salida y Terminal integrado.", "panelActiveTitleBorder": "Color de borde del título del panel activo. Los paneles se muestran debajo del área del editor y contienen vistas como Salida y Terminal integrado.", "statusBarForeground": "Color de primer plano de la barra de estado, que se muestra en la parte inferior de la ventana.", "statusBarBackground": "Color de fondo de la barra de estado estándar, que se muestra en la parte inferior de la ventana.", + "statusBarBorder": "Color de borde de la barra de estado que separa la barra lateral y el editor. La barra de estado se muestra en la parte inferior de la ventana.", "statusBarNoFolderBackground": "Color de fondo de la barra de estado cuando no hay ninguna carpeta abierta. La barra de estado se muestra en la parte inferior de la ventana.", + "statusBarNoFolderForeground": "Color de primer plano de la barra de estado cuando no hay ninguna carpeta abierta. La barra de estado se muestra en la parte inferior de la ventana.", "statusBarItemActiveBackground": "Color de fondo de un elemento de la barra de estado al hacer clic. La barra de estado se muestra en la parte inferior de la ventana.", "statusBarItemHoverBackground": "Color de fondo de un elemento de la barra de estado al mantener el puntero. La barra de estado se muestra en la parte inferior de la ventana.", "statusBarProminentItemBackground": "Color de fondo de los elementos destacados en la barra de estado. Estos elementos sobresalen para indicar importancia. La barra de estado está ubicada en la parte inferior de la ventana.", "statusBarProminentItemHoverBackground": "Color de fondo de los elementos destacados en la barra de estado cuando se mantiene el mouse sobre estos elementos. Estos elementos sobresalen para indicar importancia. La barra de estado está ubicada en la parte inferior de la ventana.", "activityBarBackground": "Color de fondo de la barra de actividad, que se muestra en el lado izquierdo o derecho y que permite cambiar entre diferentes vistas de la barra lateral.", "activityBarForeground": "Color de fondo de la barra de actividad (por ejemplo utilizado por los iconos). La barra de actividad muestra en el lado izquierdo o derecho y permite cambiar entre diferentes vistas de la barra lateral.", + "activityBarBorder": "Color de borde de la barra de actividad que separa la barra lateral. La barra de actividad se muestra en el extremo derecho o izquierdo y permite cambiar entre las vistas de la barra lateral.", "activityBarDragAndDropBackground": "Arrastre y suelte el color de las sugerencias para los elementos de la barra de actividad. El color debería tener transparencias, de forma que los elementos de la barra continúen siendo visibles a través de él. La barra de actividad se muestra en el extremo izquierdo o derecho y permite cambiar entre distintas vistas de la barra lateral.", "activityBarBadgeBackground": "Color de fondo de distintivo de notificación de actividad. La barra de actividad se muestra en el extremo izquierdo o derecho y permite cambiar entre vistas de la barra lateral.", "activityBarBadgeForeground": "Color de primer plano de distintivo de notificación de actividad. La barra de actividad se muestra en el extremo izquierdo o derecho y permite cambiar entre vistas de la barra lateral.", "sideBarBackground": "Color de fondo de la barra lateral, que es el contenedor de vistas como Explorador y Búsqueda.", "sideBarForeground": "Color de primer plano de la barra lateral, que es el contenedor de vistas como Explorador y Búsqueda.", + "sideBarBorder": "Color de borde de la barra lateral en el lado que separa el editor. La barra lateral es el contenedor de vistas como Explorador y Búsqueda.", "sideBarTitleForeground": "Color de primer plano del título de la barra lateral, que es el contenedor de vistas como Explorador y Búsqueda.", "sideBarSectionHeaderBackground": "Color de fondo del encabezado de sección de la barra lateral, que es el contenedor de vistas como Explorador y Búsqueda.", + "sideBarSectionHeaderForeground": "Color de primer plano del encabezado de sección de la barra lateral, que es el contenedor de vistas como Explorador y Búsqueda.", "titleBarActiveForeground": "Color de primer plano de la barra de título cuando la ventana está activa. Tenga en cuenta que, actualmente, este clor solo se admite en macOS.", "titleBarInactiveForeground": "Color de primer plano de la barra de título cuando la ventana está inactiva. Tenga en cuenta que, actualmente, este color solo se admite en macOS.", "titleBarActiveBackground": "Fondo de la barra de título cuando la ventana está activa. Tenga en cuenta que, actualmente, este color solo se admite en macOS.", diff --git a/i18n/esn/src/vs/workbench/electron-browser/actions.i18n.json b/i18n/esn/src/vs/workbench/electron-browser/actions.i18n.json index cf43b7ec441..2956c1f4a47 100644 --- a/i18n/esn/src/vs/workbench/electron-browser/actions.i18n.json +++ b/i18n/esn/src/vs/workbench/electron-browser/actions.i18n.json @@ -6,9 +6,6 @@ { "closeActiveEditor": "Cerrar editor", "closeWindow": "Cerrar ventana", - "switchWindow": "Cambiar de ventana", - "switchWindowPlaceHolder": "Seleccionar una ventana", - "current": "Ventana actual", "closeFolder": "Cerrar carpeta", "noFolderOpened": "No hay ninguna carpeta abierta en esta instancia para cerrar.", "newWindow": "Nueva ventana", @@ -20,7 +17,7 @@ "zoomReset": "Restablecer zoom", "appPerf": "Rendimiento de inicio", "reloadWindow": "Recargar ventana", - "openRecent": "Abrir recientes", + "current": "Ventana actual", "folders": "carpetas", "files": "archivos", "openRecentPlaceHolderMac": "Seleccione una ruta de acceso (mantenga presionada la tecla Cmd para abrirla en una nueva ventana)", @@ -32,10 +29,6 @@ "openDocumentationUrl": "Documentación", "openIntroductoryVideosUrl": "Vídeos de introducción", "toggleSharedProcess": "Alternar proceso compartido", - "navigateLeft": "Mover a la vista de la izquierda", - "navigateRight": "Mover a la vista de la derecha", - "navigateUp": "Mover a la vista superior", - "navigateDown": "Mover a la vista inferior", "increaseViewSize": "Aumentar tamaño de vista actual", "decreaseViewSize": "Reducir tamaño de vista actual" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/esn/src/vs/workbench/electron-browser/main.contribution.i18n.json index 543d5451907..701489feabd 100644 --- a/i18n/esn/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/esn/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -31,10 +31,6 @@ "window.openFoldersInNewWindow.off": "Las carpetas reemplazarán la ventana activa más reciente", "window.openFoldersInNewWindow.default": "Las carpetas se abrirán en una nueva ventana a menos que se seleccione una carpeta desde la aplicación (p. ej. mediante el menú Archivo)", "openFoldersInNewWindow": "Controla si las carpetas deben abrirse en una ventana nueva o reemplazar la última ventana activa.\n- default: las carpetas se abrirán en una ventana nueva, a menos que se seleccione una carpeta desde la aplicación (por ejemplo, desde el menú Archivo)\n- on: las carpetas se abrirán en una ventana nueva\n- off: las carpetas reemplazarán la última ventana activa\nTenga en cuenta que aún puede haber casos en los que este parámetro se ignore (por ejemplo, al usar la opción de la línea de comandos -new-window o -reuse-window).", - "window.reopenFolders.none": "No volver a abrir nunca una carpeta.", - "window.reopenFolders.one": "Volver a abrir la carpeta activa más reciente.", - "window.reopenFolders.all": "Volver a abrir todas las carpetas de la sesión más reciente.", - "reopenFolders": "Controla cómo se vuelven a abrir las carpetas tras un reinicio. Seleccione \"none\" para no volver a abrir jamás una carpeta, \"one\" para volver a abrir la última carpeta en la que trabajó o seleccione \"all\" para volver a abrir todas las carpetas de la última sesión.", "restoreFullscreen": "Controla si una ventana se debe restaurar al modo de pantalla completa si se salió de ella en dicho modo.", "zoomLevel": "Ajuste el nivel de zoom de la ventana. El tamaño original es 0 y cada incremento (por ejemplo, 1) o disminución (por ejemplo, -1) representa una aplicación de zoom un 20 % más grande o más pequeño. También puede especificar decimales para ajustar el nivel de zoom con una granularidad más precisa.", "title": "Controla el título de la ventana según el editor activo. Las variables se sustituyen según el contexto: ${activeEditorShort}: por ejemplo, myFile.txt ${activeEditorMedium}: por ejemplo, myFolder/myFile.txt ${activeEditorLong}: por ejemplo, /Users/Development/myProject/myFolder/myFile.txt ${rootName}: por ejemplo, myProject ${rootPath}: por ejemplo, /Users/Development/myProject ${appName}: por ejemplo, VS Code ${dirty}: un indicador con modificaciones si el editor activo está desfasado ${separator}: un separador condicional (\" - \") que solo se muestra cuando está rodeado por variables con valores", @@ -58,5 +54,7 @@ "zenMode.hideTabs": "Controla si la activación del modo zen también oculta las pestañas del área de trabajo.", "zenMode.hideStatusBar": "Controla si la activación del modo zen oculta también la barra de estado en la parte inferior del área de trabajo.", "zenMode.hideActivityBar": "Controla si la activación del modo zen oculta también la barra de estado en la parte izquierda del área de trabajo.", - "zenMode.restore": "Controla si una ventana debe restaurarse a modo zen si se cerró en modo zen." + "zenMode.restore": "Controla si una ventana debe restaurarse a modo zen si se cerró en modo zen.", + "workspaceConfigurationTitle": "Ãrea de trabajo", + "files.exclude.boolean": "El patrón global con el que se harán coincidir las rutas de acceso de los archivos. Establézcalo en true o false para habilitarlo o deshabilitarlo." } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json b/i18n/esn/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json new file mode 100644 index 00000000000..58480e0cd81 --- /dev/null +++ b/i18n/esn/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json @@ -0,0 +1,26 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "emergencyConfOn": "Se cambiará ahora el valor de configuración \"editor.accessibilitySupport\" a \"activado\".", + "openingDocs": "Se abrirá ahora la página de documentación de accesibilidad de VS Code.", + "introMsg": "Gracias por probar las opciones de accesibilidad de VS Code.", + "status": "Estado:", + "changeConfigToOnMac": "Para configurar el editor de forma que esté optimizado de permanentemente para su uso con un lector de pantalla, presione ahora Comando+E.", + "changeConfigToOnWinLinux": "Para configurar el editor de forma que esté optimizado permanentemente para su uso con un lector de pantalla, presione ahora Control+E.", + "auto_unknown": "El editor está configurado para usar API de plataforma para detectar cuándo está conectado un lector de pantalla, pero el entorno actual de tiempo de ejecución no admite esta característica.", + "auto_on": "El editor ha detectado automáticamente un lector de pantalla conectado.", + "auto_off": "El editor está configurado para detectar automáticamente cuándo está conectado un lector de pantalla, lo que no es el caso en este momento.", + "configuredOn": "El editor está configurado para optimizarse permanentemente para su uso con un lector de pantalla; para cambiar este comportamiento, edite el valor de configuración \"editor.accessibilitySupport\".", + "configuredOff": "El editor está configurado de forma que no esté nunca optimizado para su uso con un lector de pantalla.", + "tabFocusModeOnMsg": "Al presionar TAB en el editor actual, el foco se mueve al siguiente elemento activable. Presione {0} para activar o desactivar este comportamiento.", + "tabFocusModeOnMsgNoKb": "Al presionar TAB en el editor actual, el foco se mueve al siguiente elemento activable. El comando {0} no se puede desencadenar actualmente mediante un enlace de teclado.", + "tabFocusModeOffMsg": "Al presionar TAB en el editor actual, se insertará el carácter de tabulación. Presione {0} para activar o desactivar este comportamiento.", + "tabFocusModeOffMsgNoKb": "Al presionar TAB en el editor actual, se insertará el carácter de tabulación. El comando {0} no se puede desencadenar actualmente mediante un enlace de teclado.", + "openDocMac": "Presione Comando+H ahora para abrir una ventana de explorador con más información de VS Code relacionada con la accesibilidad.", + "openDocWinLinux": "Presione Control+H ahora para abrir una ventana de explorador con más información de VS Code relacionada con la accesibilidad.", + "outroMsg": "Para descartar esta información sobre herramientas y volver al editor, presione Esc o Mayús+Escape.", + "ShowAccessibilityHelpAction": "Mostrar ayuda de accesibilidad" +} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json b/i18n/esn/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/esn/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json b/i18n/esn/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json new file mode 100644 index 00000000000..6612e373361 --- /dev/null +++ b/i18n/esn/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleLocation": "Alternar modificador multicursor" +} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json b/i18n/esn/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json index 92832a7c2dc..7b12765e51e 100644 --- a/i18n/esn/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json @@ -5,16 +5,12 @@ // Do not edit this file. It is machine generated. { "variablesSection": "Sección de variables", - "variables": "Variables", "variablesAriaTreeLabel": "Variables de depuración", "expressionsSection": "Sección de expresiones", - "watch": "Inspección", "watchAriaTreeLabel": "Expresiones de inspección de la depuración", "callstackSection": "Sección de la pila de llamadas", "debugStopped": "En pausa en {0}", - "callStack": "Pila de llamadas", "callStackAriaLabel": "Pila de llamadas de la depuración", "breakpointsSection": "Sección de puntos de interrupción", - "breakpoints": "Puntos de interrupción", "breakpointsAriaTreeLabel": "Puntos de interrupción de la depuración" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json b/i18n/esn/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json index 328583915c4..a06b5c267dd 100644 --- a/i18n/esn/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json @@ -4,6 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "previousEditPoint": "Emmet: Punto de edición anterior", - "nextEditPoint": "Emmet: Punto de edición siguiente" + "previousEditPoint": "Emmet: Ir al punto de edición anterior", + "nextEditPoint": "Emmet: Ir al punto de edición siguiente" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json b/i18n/esn/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json index 176ecb884a1..a1f452f38ff 100644 --- a/i18n/esn/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json @@ -9,5 +9,6 @@ "emmetPreferences": "Preferencias usadas para modificar el comportamiento de algunas acciones y resoluciones de Emmet.", "emmetSyntaxProfiles": "Defina el perfil de la sintaxis especificada o use su propio perfil con reglas específicas.", "emmetExclude": "Matriz de lenguajes donde no deben expandirse la abreviación Emmet.", - "emmetExtensionsPath": "Ruta de acceso a una carpeta que contiene perfiles de Emmet, fragmentos de código y preferencias" + "emmetExtensionsPath": "Ruta de acceso a una carpeta que contiene perfiles de Emmet, fragmentos de código y preferencias", + "useNewEmmet": "Pruebe los nuevos módulos de Emmet (que finalmente sustituirán a la biblioteca anterior de Emmet) para conocer todas las características de Emmet." } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json b/i18n/esn/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json index bd5f70d9a8d..e68b4424c52 100644 --- a/i18n/esn/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json @@ -24,6 +24,10 @@ "default": "Predeterminado", "debuggers": "Depuradores ({0})", "debugger name": "Nombre", + "views": "Vistas ({0})", + "view id": "Id.", + "view name": "Nombre", + "view location": "Donde", "themes": "Temas ({0})", "JSON Validation": "Validación JSON ({0})", "commands": "Comandos ({0})", diff --git a/i18n/esn/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json b/i18n/esn/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json index 7da24054556..5e236865193 100644 --- a/i18n/esn/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json @@ -22,6 +22,8 @@ "disableGloballyAction": "Siempre", "disableAction": "Deshabilitar", "checkForUpdates": "Buscar actualizaciones", + "enableAutoUpdate": "Habilitar extensiones de actualización automática", + "disableAutoUpdate": "Deshabilitar extensiones de actualización automática", "updateAll": "Actualizar todas las extensiones", "reloadAction": "Recargar", "postUpdateTooltip": "Recargar para actualizar", @@ -44,6 +46,8 @@ "showWorkspaceRecommendedExtensions": "Mostrar extensiones recomendadas del área de trabajo", "showRecommendedKeymapExtensions": "Mostrar asignaciones de teclado recomendadas", "showRecommendedKeymapExtensionsShort": "Asignaciones de teclado", + "showLanguageExtensions": "Mostrar extensiones del lenguaje", + "showLanguageExtensionsShort": "Extensiones del lenguaje", "configureWorkspaceRecommendedExtensions": "Configurar extensiones recomendadas (área de trabajo)", "ConfigureWorkspaceRecommendations.noWorkspace": "Las recomendaciones solo están disponibles en una carpeta de área de trabajo.", "OpenExtensionsFile.failed": "No se puede crear el archivo \"extensions.json\" dentro de la carpeta \".vscode\" ({0}).", @@ -51,5 +55,8 @@ "disableAll": "Deshabilitar todas las extensiones instaladas", "disableAllWorkspace": "Deshabilitar todas las extensiones instaladas para esta área de trabajo", "enableAll": "Habilitar todas las extensiones instaladas", - "enableAllWorkspace": "Habilitar todas las extensiones instaladas para esta área de trabajo" + "enableAllWorkspace": "Habilitar todas las extensiones instaladas para esta área de trabajo", + "extensionButtonProminentBackground": "Color de fondo del botón para la extensión de acciones que se destacan (por ejemplo, el botón de instalación).", + "extensionButtonProminentForeground": "Color de primer plano del botón para la extensión de acciones que se destacan (por ejemplo, botón de instalación).", + "extensionButtonProminentHoverBackground": "Color de fondo del botón al mantener el mouse para la extensión de acciones que se destacan (por ejemplo, el botón de instalación)." } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/esn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index f9f715ea4a9..6151f36cc6b 100644 --- a/i18n/esn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -4,8 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "disableOtherKeymapsConfirmation": "¿Quiere deshabilitar otras asignaciones de teclas ({0}) para evitar conflictos entre enlaces de teclado?", "yes": "Sí", "no": "No", + "betterMergeDisabled": "La extensión Mejor combinación está ahora integrada, la extensión instalada se deshabilitó y no se puede desinstalar.", "uninstall": "Desinstalación", "later": "Más tarde" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/esn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 923353af133..b104c63f09f 100644 --- a/i18n/esn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -28,7 +28,6 @@ "watcherExclude": "Configure patrones globales de las rutas de acceso de archivo que se van a excluir de la inspección de archivos. Al cambiar esta configuración, es necesario reiniciar. Si observa que Code consume mucho tiempo de CPU al iniciarse, puede excluir las carpetas grandes para reducir la carga inicial.", "hotExit.off": "Deshabilita la salida rápida.", "hotExit.onExit": "hotExit se desencadena al cerrar la aplicación, es decir, al cerrarse la última ventana en Windows/Linux o cuando se desencadena el comando workbench.action.quit (paleta de comandos, enlace de teclado, menú). Todas las ventanas con copias de seguridad se restaurarán la próxima vez que se inicie.", - "hotExit.onExitAndWindowClose": "HotExit se desencadena al cerrar la aplicación, es decir, al cerrarse la última ventana en Windows/Linux o cuando se desencadena el comando workbench.action.quit (paleta de comandos, enlace de teclado, menú). También para cualquier ventana que tenga una carpeta abierta, independientemente de que sea o no la última ventana. Todas las ventanas sin carpetas abiertas se restaurarán la próxima vez que se inicie. Para restaurar las ventanas con carpetas tal cual estaban antes de cerrarse, establezca \"window.reopenFolders\" en \"all\".", "hotExit": "Controla si los archivos no guardados se recuerdan entre las sesiones, lo que permite omitir el mensaje para guardar al salir del editor.", "defaultLanguage": "El modo de lenguaje predeterminado que se asigna a nuevos archivos.", "editorConfigurationTitle": "Editor", diff --git a/i18n/esn/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json b/i18n/esn/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json index f62bf00d0eb..c2ff9cef3d7 100644 --- a/i18n/esn/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json @@ -5,7 +5,5 @@ // Do not edit this file. It is machine generated. { "explorerSection": "Sección del Explorador de archivos", - "noWorkspace": "No hay ninguna carpeta abierta", - "noWorkspaceHelp": "Todavía no ha abierto ninguna carpeta.", "openFolder": "Abrir carpeta" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json b/i18n/esn/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json index 1b3168622ee..30c064adf3d 100644 --- a/i18n/esn/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json @@ -4,8 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "openEditosrSection": "Sección Editores abiertos", "openEditors": "Editores abiertos", + "openEditosrSection": "Sección Editores abiertos", "treeAriaLabel": "Editores abiertos: lista de archivos activos", "dirtyCounter": "{0} sin guardar" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/esn/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json index 6c042c0daff..e8414e42d14 100644 --- a/i18n/esn/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -5,5 +5,7 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.start": "Definir enlace de teclado", - "defineKeybinding.kbLayoutErrorMessage": "La distribución del teclado actual no permite reproducir esta combinación de teclas." + "defineKeybinding.kbLayoutErrorMessage": "La distribución del teclado actual no permite reproducir esta combinación de teclas.", + "defineKeybinding.kbLayoutLocalAndUSMessage": "**{0}** para su distribución de teclado actual (**{1}** para EE. UU. estándar).", + "defineKeybinding.kbLayoutLocalMessage": "**{0}** para su distribución de teclado actual." } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json b/i18n/esn/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json new file mode 100644 index 00000000000..d3057c63b08 --- /dev/null +++ b/i18n/esn/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "relaunchMessage": "Ha cambiado un ajuste que requiere un reinicio para ser efectivo.", + "relaunchDetail": "Pulse el botón de reinicio para reiniciar {0} y habilitar el ajuste.", + "restart": "Reiniciar" +} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/esn/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json index 8b6ad71cd4e..5fe13ab86c4 100644 --- a/i18n/esn/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "editorGutterModifiedBackground": "Color de fondo del medianil del editor para las líneas modificadas.", + "editorGutterAddedBackground": "Color de fondo del medianil del editor para las líneas agregadas.", + "editorGutterDeletedBackground": "Color de fondo del medianil del editor para las líneas eliminadas." +} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json b/i18n/esn/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json index 2841d09230e..08084e88498 100644 --- a/i18n/esn/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json @@ -9,5 +9,6 @@ "vscode.extension.contributes.snippets-path": "Ruta de acceso del archivo de fragmentos de código. La ruta es relativa a la carpeta de extensión y normalmente empieza por \"./snippets/\".", "invalid.language": "Lenguaje desconocido en \"contributes.{0}.language\". Valor proporcionado: {1}", "invalid.path.0": "Se esperaba una cadena en \"contributes.{0}.path\". Valor proporcionado: {1}", - "invalid.path.1": "Se esperaba que \"contributes.{0}.path\" ({1}) se incluyera en la carpeta de la extensión ({2}). Esto puede hacer que la extensión no sea portátil." + "invalid.path.1": "Se esperaba que \"contributes.{0}.path\" ({1}) se incluyera en la carpeta de la extensión ({2}). Esto puede hacer que la extensión no sea portátil.", + "badVariableUse": "Es muy probable que el fragmento de código \"{0}\" confunda las variables de fragmento de código y los marcadores de posición de fragmento de código. Consulte https://code.visualstudio.com/docs/editor/userdefinedsnippets#_snippet-syntax para más informacion." } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json b/i18n/esn/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json index 6bb2b76ad2b..4a006c7f571 100644 --- a/i18n/esn/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json @@ -11,6 +11,6 @@ "snippetSchema.json.default": "Fragmento de código vacío", "snippetSchema.json": "Configuración de fragmento de código del usuario", "snippetSchema.json.prefix": "El prefijo que se debe usar al seleccionar el fragmento de código en Intellisense", - "snippetSchema.json.body": "Contenido del fragmento de código. Use '${id}', '${id:label}', '${1:label}' para las variables y '$0', '$1' para las posiciones del cursor", + "snippetSchema.json.body": "El contenido del fragmento de código. Use \"$1', \"${1:defaultText}\" para definir las posiciones del cursor, use \"$0\" para la posición final del cursor. Inserte valores de variable con \"${varName}\" y \"${varName:defaultText}\", por ejemplo, \"This is file: $TM_FILENAME\".", "snippetSchema.json.description": "La descripción del fragmento de código." } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json b/i18n/esn/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json new file mode 100644 index 00000000000..411c12dbc46 --- /dev/null +++ b/i18n/esn/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "helpUs": "Ayúdenos a mejorar nuestro soporte para {0}", + "takeShortSurvey": "Realizar una breve encuesta", + "remindLater": "Recordármelo más tarde", + "neverAgain": "No volver a mostrar" +} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json b/i18n/esn/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json new file mode 100644 index 00000000000..2e4d1ea682f --- /dev/null +++ b/i18n/esn/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "surveyQuestion": "¿Le importaría realizar una breve encuesta de opinión?", + "takeSurvey": "Realizar encuesta", + "remindLater": "Recordármelo más tarde", + "neverAgain": "No volver a mostrar" +} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json b/i18n/esn/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json new file mode 100644 index 00000000000..6574ffdaef1 --- /dev/null +++ b/i18n/esn/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noTasksMatching": "No tasks matching" +} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/esn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index e5995f59713..59b152344cf 100644 --- a/i18n/esn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0}, tareas" + "entryAriaLabel": "{0}, tareas", + "customizeTask": "Personalizar tarea" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json b/i18n/esn/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json new file mode 100644 index 00000000000..6574ffdaef1 --- /dev/null +++ b/i18n/esn/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noTasksMatching": "No tasks matching" +} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/esn/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json index 2cc7fa59535..71a6380a7ab 100644 --- a/i18n/esn/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -12,5 +12,6 @@ "ConfigurationParser.invalidVaraibleReference": "Error: Referencia a problemMatcher no válida: {0}", "ConfigurationParser.noTaskName": "Error: Las tareas deben proporcionar una propiedad taskName. La tarea se ignorará. {0}", "taskConfiguration.shellArgs": "Advertencia: La tarea \"{0}\" es un comando de shell y su nombre de comando o uno de sus argumentos tiene espacios sin escape. Para asegurarse de que la línea de comandos se cite correctamente, combine mediante fusión los argumentos en el comando.", + "taskConfiguration.noCommandOrDependsOn": "Error: La tarea \"{0}\" no especifica un comando ni una propiedad dependsOn. La tarea se ignorará. Su definición es: \n{1}", "taskConfiguration.noCommand": "Error: La tarea \"{0}\" no define un comando. La tarea se ignorará. Su definición es: {1}" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json b/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json index 20c5a4af698..b148f0ec22a 100644 --- a/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json @@ -7,6 +7,7 @@ "JsonSchema.options": "Opciones de comando adicionales", "JsonSchema.options.cwd": "Directorio de trabajo actual del script o el programa ejecutado. Si se omite, se usa la raíz del área de trabajo actual de Code.", "JsonSchema.options.env": "Entorno del shell o el programa ejecutado. Si se omite, se usa el entorno del proceso primario.", + "JsonSchema.shellConfiguration": "Configura el shell que se usará.", "JsonSchema.shell.executable": "Shell que se va a usar.", "JsonSchema.shell.args": "Argumentos de shell.", "JsonSchema.command": "El comando que se va a ejecutar. Puede ser un programa externo o un comando shell.", diff --git a/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json b/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json index 9c0e9c0db0b..d8137d279a8 100644 --- a/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json @@ -5,6 +5,8 @@ // Do not edit this file. It is machine generated. { "JsonSchema.version": "Número de versión de la configuración", + "JsonSchema._runner": "El ejecutador se ha graduado. Use el ejecutador oficial correctamente", + "JsonSchema.runner": "Define si la tarea se ejecuta como un proceso y la salida se muestra en la ventana de salida o dentro del terminal.", "JsonSchema.windows": "Configuración de comando específico de Windows", "JsonSchema.mac": "Configuración de comando específico de Mac", "JsonSchema.linux": "Configuración de comando específico de Linux", diff --git a/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json index a568620f9fe..af62585104d 100644 --- a/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -7,6 +7,10 @@ "JsonSchema.shell": "Especifica si el comando es un comando shell o un programa externo. Si se omite, el valor predeterminado es false.", "JsonSchema.tasks.dependsOn.string": "Otra tarea de la que depende esta tarea.", "JsonSchema.tasks.dependsOn.array": "Las otras tareas de las que depende esta tarea.", + "JsonSchema.tasks.group": "Define el grupo de ejecución al que pertenece esta tarea. Si se omite, la tarea no pertenece a ningún grupo.", + "JsonSchema.tasks.type": "Define si la tarea se ejecuta como un proceso o como un comando dentro de un shell. El valor predeterminado es proceso.", + "JsonSchema.version": "El número de versión de la configuración.", + "JsonSchema.tasks.customize": "La tarea contribuida que se va a personalizar.", "JsonSchema.windows": "Configuración de comando específico de Windows", "JsonSchema.mac": "Configuración de comando específico de Mac", "JsonSchema.linux": "Configuración de comando específico de Linux" diff --git a/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json b/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json index 05a4cfef6c7..7be9d7375de 100644 --- a/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json @@ -22,7 +22,8 @@ "TaskService.noBuildTask": "No se ha definido ninguna tarea de compilación. Marque una tarea con \"isBuildCommand\" en el archivo tasks.json.", "TaskService.noTestTask": "No se ha definido ninguna tarea de prueba. Marque una tarea con \"isTestCommand\" en el archivo tasks.json.", "TaskServer.noTask": "No se encuentra la tarea {0} que se ha solicitado para ejecutarla.", - "TaskSystem.activeSame": "La tarea ya está activa y en modo de inspección. Para finalizar la tarea, use \"F1 > finalizar tarea\"", + "customizeParseErrors": "La configuración actual de tareas contiene errores. Antes de personalizar una tarea, corrija los errores.", + "moreThanOneBuildTask": "Hay muchas tareas de compilación definidas en el archivo tasks.json. Se ejecutará la primera.\n", "TaskSystem.active": "Ya hay una tarea en ejecución. Finalícela antes de ejecutar otra tarea.", "TaskSystem.restartFailed": "No se pudo terminar y reiniciar la tarea {0}", "TaskSystem.configurationErrors": "Error: La configuración de la tarea proporcionada tiene errores de validación y no se puede usar. Corrija los errores primero.", diff --git a/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json b/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json index 58c4eca7cfe..99a6eef0566 100644 --- a/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json @@ -6,6 +6,7 @@ { "TerminalTaskSystem.unknownError": "Error desconocido durante la ejecución de una tarea. Vea el registro de resultados de la tarea para obtener más detalles.", "TerminalTaskSystem.terminalName": "Tarea - {0}", + "reuseTerminal": "Las tareas reutilizarán el terminal, presione cualquier tecla para cerrarlo.", "TerminalTaskSystem": "No se puede ejecutar un comando shell en una unidad UNC.", "unkownProblemMatcher": "No puede resolver el comprobador de problemas {0}. Será omitido." } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json b/i18n/esn/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json index 50e571af89f..fe23037a3ff 100644 --- a/i18n/esn/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json @@ -8,6 +8,7 @@ "workbench.action.terminal.kill": "Terminar la instancia del terminal activo", "workbench.action.terminal.kill.short": "Terminar el terminal", "workbench.action.terminal.copySelection": "Copiar selección", + "workbench.action.terminal.selectAll": "Seleccionar todo", "workbench.action.terminal.new": "Crear nuevo terminal integrado", "workbench.action.terminal.new.short": "Nuevo terminal", "workbench.action.terminal.focus": "Enfocar terminal", @@ -28,5 +29,6 @@ "workbench.action.terminal.scrollToTop": "Desplazar al principio", "workbench.action.terminal.clear": "Borrar", "workbench.action.terminal.allowWorkspaceShell": "Permitir la configuración del área de trabajo Shell", - "workbench.action.terminal.disallowWorkspaceShell": "No permitir la configuración del área de trabajo Shell" + "workbench.action.terminal.disallowWorkspaceShell": "No permitir la configuración del área de trabajo Shell", + "workbench.action.terminal.rename": "Cambiar nombre" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json b/i18n/esn/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json new file mode 100644 index 00000000000..213a60a3c4f --- /dev/null +++ b/i18n/esn/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "label.find": "Buscar", + "placeholder.find": "Buscar", + "label.previousMatchButton": "Coincidencia anterior", + "label.nextMatchButton": "Coincidencia siguiente", + "label.closeButton": "Cerrar" +} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json b/i18n/esn/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json index af3664237c8..651e16251db 100644 --- a/i18n/esn/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json @@ -4,7 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "terminal.integrated.copySelection.noSelection": "No se puede copiar la selección del terminal cuando el terminal no tiene el foco", "terminal.integrated.exitedWithCode": "El proceso del terminal finalizó con el código de salida: {0}", "terminal.integrated.waitOnExit": "Presione cualquier tecla para cerrar el terminar", "terminal.integrated.launchFailed": "No se pudo iniciar el comando de proceso terminal \"{0}{1}\" (código de salida: {2})" diff --git a/i18n/esn/src/vs/workbench/parts/update/electron-browser/update.i18n.json b/i18n/esn/src/vs/workbench/parts/update/electron-browser/update.i18n.json index 2d90eac6828..614696014d8 100644 --- a/i18n/esn/src/vs/workbench/parts/update/electron-browser/update.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/update/electron-browser/update.i18n.json @@ -15,5 +15,18 @@ "license": "Leer licencia", "updateAvailable": "{0} se actualizará después de reiniciarse.", "thereIsUpdateAvailable": "Hay una actualización disponible.", - "noUpdatesAvailable": "Actualmente no hay actualizaciones disponibles." + "noUpdatesAvailable": "Actualmente no hay actualizaciones disponibles.", + "updateIsReady": "Nueva actualización disponible.", + "commandPalette": "Paleta de comandos...", + "settings": "Configuración", + "keyboardShortcuts": "Métodos abreviados de teclado", + "selectTheme.label": "Tema de color", + "themes.selectIconTheme.label": "Tema de icono de archivo", + "not available": "Actualizaciones no disponibles", + "checkingForUpdates": "Buscando actualizaciones...", + "DownloadUpdate": "Descargar actualización disponible", + "DownloadingUpdate": "Descargando actualización...", + "InstallingUpdate": "Instalando actualización...", + "restartToUpdate": "Reiniciar para actualizar...", + "checkForUpdates": "Buscar actualizaciones..." } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/views/browser/views.i18n.json b/i18n/esn/src/vs/workbench/parts/views/browser/views.i18n.json new file mode 100644 index 00000000000..62933f6b509 --- /dev/null +++ b/i18n/esn/src/vs/workbench/parts/views/browser/views.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "viewToolbarAriaLabel": "{0} acciones" +} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json b/i18n/esn/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json new file mode 100644 index 00000000000..825009fbc6c --- /dev/null +++ b/i18n/esn/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "requirearray": "views debe ser una mariz", + "requirestring": "la propiedad `{0}` es obligatoria y debe ser de tipo \"string\"", + "optstring": "la propiedad `{0}` se puede omitir o debe ser de tipo \"string\"", + "vscode.extension.contributes.view.id": "Identificador de la vista. Úselo para registrar un proveedor de datos mediante la API \"vscode.window.registerTreeDataProviderForView\". También para desencadenar la activación de su extensión al registrar el evento \"onView:${id}\" en \"activationEvents\".", + "vscode.extension.contributes.view.name": "Nombre de la vista en lenguaje natural. Será mostrado", + "vscode.extension.contributes.views": "Aporta vistas al editor", + "views.explorer": "Vista del explorador", + "locationId.invalid": "`{0}` no es una ubicación de vista válida" +} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json index 2438b3e1709..d10b9f98464 100644 --- a/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -31,7 +31,6 @@ "welcomePage.colorThemeDescription": "Modifique a su gusto la apariencia del editor y el código", "welcomePage.learn": "Más información", "welcomePage.showCommands": "Buscar y ejecutar todos los comandos", - "welcomePage.showCommandsDescription": "Acceda rápidamente y busque comandos desde el panel de control ({0})", "welcomePage.interfaceOverview": "Introducción a la interfaz", "welcomePage.interfaceOverviewDescription": "Obtenga una superposición que resalta los componentes principales de la interfaz de usuario", "welcomePage.interactivePlayground": "Ãrea de juegos interactiva", diff --git a/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json b/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json index f366b9af6fd..7fb18c5a5ef 100644 --- a/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json @@ -4,7 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "workbenchConfigurationTitle": "Ãrea de trabajo", - "welcomePage.enabled": "Cuando está habilitado, se mostrará la página principal en el inicio.", "help": "Ayuda" } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 0ada1a16443..7542d5d3b7c 100644 --- a/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/esn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -4,6 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "workbenchConfigurationTitle": "Ãrea de trabajo", + "welcomePage.enabled": "Cuando está habilitado, se mostrará la página principal en el inicio.", "welcomePage": "Bienvenido", "welcomePage.javaScript": "JavaScript", "welcomePage.typeScript": "TypeScript", @@ -14,16 +16,23 @@ "welcomePage.sublime": "Sublime", "welcomePage.atom": "Atom", "welcomePage.extensionPackAlreadyInstalled": "El soporte para '{0}' ya está instalado.", - "welcomePage.willReloadAfterInstallingExtensionPack": "La ventana se volverá a cargar después de instalar el soporte para {0}.", - "welcomePage.installingExtensionPack": "Instalando soporte para {0}...", + "welcomePage.willReloadAfterInstallingExtensionPack": "La ventana se volverá a cargar después de instalar compatibilidad adicional con {0}.", + "welcomePage.installingExtensionPack": "Instalando compatibilidad adicional con {0}...", "welcomePage.extensionPackNotFound": "No se pudo encontrar el soporte para {0} con id {1}.", "welcomePage.keymapAlreadyInstalled": "Los métodos abreviados de teclado {0} ya están instalados.", "welcomePage.willReloadAfterInstallingKeymap": "La ventana se volverá a cargar después de instalar los métodos abreviados de teclado {0}.", "welcomePage.installingKeymap": "Instalando los métodos abreviados de teclado de {0}...", "welcomePage.keymapNotFound": "No se pudieron encontrar los métodos abreviados de teclado {0} con el identificador {1}.", "welcome.title": "Bienvenido", + "welcomePage.openFolderWithPath": "Abrir la carpeta {0} con la ruta de acceso {1}", "welcomePage.extensionListSeparator": ", ", - "welcomePage.installedExtension": "{0} (instalado)", + "welcomePage.installKeymap": "Instalar mapa de teclas de {0}", + "welcomePage.installExtensionPack": "Instalar compatibilidad adicional con {0}", + "welcomePage.installedKeymap": "El mapa de teclas de {0} ya está instalado", + "welcomePage.installedExtensionPack": "La compatibilidad con {0} ya está instalada", "ok": "Aceptar", - "cancel": "Cancelar" + "details": "Detalles", + "cancel": "Cancelar", + "welcomePage.buttonBackground": "Color de fondo de los botones en la página principal.", + "welcomePage.buttonHoverBackground": "Color de fondo al mantener el mouse en los botones de la página principal." } \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json b/i18n/esn/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json new file mode 100644 index 00000000000..fb3b052d7b4 --- /dev/null +++ b/i18n/esn/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "telemetryConfigurationTitle": "Telemetría", + "telemetry.enableCrashReporting": "Habilite los informes de bloqueo para enviarlos a Microsoft. Esta opción requiere reiniciar para que tenga efecto." +} \ No newline at end of file diff --git a/i18n/esn/src/vs/workbench/services/progress/browser/progressService2.i18n.json b/i18n/esn/src/vs/workbench/services/progress/browser/progressService2.i18n.json new file mode 100644 index 00000000000..ee9bbb9d071 --- /dev/null +++ b/i18n/esn/src/vs/workbench/services/progress/browser/progressService2.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "progress.text": "{0} - {1} ", + "progress.title": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/fra/extensions/git/out/commands.i18n.json b/i18n/fra/extensions/git/out/commands.i18n.json index 3601e044f8b..f1b007aaf1e 100644 --- a/i18n/fra/extensions/git/out/commands.i18n.json +++ b/i18n/fra/extensions/git/out/commands.i18n.json @@ -18,6 +18,7 @@ "discard": "Ignorer les modifications", "confirm discard all": "Voulez-vous vraiment ignorer TOUTES les modifications ? Cette action est IRRÉVERSIBLE.", "discardAll": "Ignorer TOUTES les modifications", + "no staged changes": "Aucune modification en attente à valider.\n\nVoulez-vous automatiquement mettre en attente toutes vos modifications et les valider directement ?", "yes": "Oui", "always": "Toujours", "no changes": "Il n'existe aucun changement à valider.", @@ -25,6 +26,9 @@ "provide commit message": "Indiquez un message de validation", "branch name": "Nom de la branche", "provide branch name": "Fournissez un nom de branche", + "select branch to delete": "Sélectionner une branche à supprimer", + "confirm force delete branch": "La branche '{0}' n'est pas complètement fusionnée. Supprimer quand même ?", + "delete branch": "Supprimer la branche", "no remotes to pull": "Votre dépôt n'a aucun dépôt distant configuré pour un Pull.", "no remotes to push": "Votre dépôt n'a aucun dépôt distant configuré pour un Push.", "nobranch": "Vous devez extraire une branche dont vous souhaitez effectuer le Push vers un emplacement distant.", diff --git a/i18n/fra/extensions/git/package.i18n.json b/i18n/fra/extensions/git/package.i18n.json index 801419a6433..16a737e5dd0 100644 --- a/i18n/fra/extensions/git/package.i18n.json +++ b/i18n/fra/extensions/git/package.i18n.json @@ -26,12 +26,13 @@ "command.undoCommit": "Annuler la dernière validation", "command.checkout": "Extraire vers...", "command.branch": "Créer une branche...", + "command.deleteBranch": "Supprimer la branche...", "command.pull": "Pull", "command.pullRebase": "Pull (rebaser)", "command.push": "Push", "command.pushTo": "Transfert (Push) vers...", "command.sync": "Synchroniser", - "command.publish": "Publier", + "command.publish": "Publier la branche", "command.showOutput": "Afficher la sortie Git", "config.enabled": "Indique si git est activé", "config.path": "Chemin d'accès à l'exécutable git", @@ -42,5 +43,7 @@ "config.countBadge": "Contrôle le compteur de badges Git. La valeur 'toutes' compte toutes les modifications. La valeur 'suivies' compte uniquement les modifications suivies. La valeur 'désactivé' désactive le compteur.", "config.checkoutType": "Contrôle le type des branches répertoriées pendant l'exécution de 'Extraire vers...'. La valeur 'toutes' montre toutes les références, la valeur 'locales' montre uniquement les branches locales, la valeur 'balises' montre uniquement les balises et la valeur 'distantes' montre uniquement les branches distantes.", "config.ignoreLegacyWarning": "Ignore l'avertissement Git hérité", - "config.ignoreLimitWarning": "Ignore l'avertissement quand il y a trop de modifications dans un dépôt" + "config.ignoreLimitWarning": "Ignore l'avertissement quand il y a trop de modifications dans un dépôt", + "config.defaultCloneDirectory": "Emplacement par défaut où cloner un dépôt git", + "config.enableSmartCommit": "Validez toutes les modifications en l'absence de modifications en attente." } \ No newline at end of file diff --git a/i18n/fra/extensions/jake/out/main.i18n.json b/i18n/fra/extensions/jake/out/main.i18n.json index 8b6ad71cd4e..4811debb9a3 100644 --- a/i18n/fra/extensions/jake/out/main.i18n.json +++ b/i18n/fra/extensions/jake/out/main.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "execFailed": "Échec de la détection automatique des tâches Jake avec l'erreur : {0}" +} \ No newline at end of file diff --git a/i18n/fra/extensions/jake/package.i18n.json b/i18n/fra/extensions/jake/package.i18n.json index 8b6ad71cd4e..0a21c419d8f 100644 --- a/i18n/fra/extensions/jake/package.i18n.json +++ b/i18n/fra/extensions/jake/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.jake.autoDetect": "Contrôle si la détection automatique des tâches Jake est activée ou désactivée. La valeur par défaut est activée." +} \ No newline at end of file diff --git a/i18n/fra/extensions/markdown/out/extension.i18n.json b/i18n/fra/extensions/markdown/out/extension.i18n.json index 8b6ad71cd4e..34001f88bb7 100644 --- a/i18n/fra/extensions/markdown/out/extension.i18n.json +++ b/i18n/fra/extensions/markdown/out/extension.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "onPreviewStyleLoadError": "Impossible de charger 'markdown.styles' : {0}" +} \ No newline at end of file diff --git a/i18n/fra/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/fra/extensions/merge-conflict/out/codelensProvider.i18n.json index 8b6ad71cd4e..96643427968 100644 --- a/i18n/fra/extensions/merge-conflict/out/codelensProvider.i18n.json +++ b/i18n/fra/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -3,4 +3,9 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "acceptCurrentChange": "Accepter la modification actuelle", + "acceptIncomingChange": "Accepter la modification entrante", + "acceptBothChanges": "Accepter les deux modifications", + "compareChanges": "Comparer les modifications" +} \ No newline at end of file diff --git a/i18n/fra/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/fra/extensions/merge-conflict/out/commandHandler.i18n.json index 8b6ad71cd4e..ef10c1f1063 100644 --- a/i18n/fra/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/fra/extensions/merge-conflict/out/commandHandler.i18n.json @@ -3,4 +3,10 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "cursorNotInConflict": "Le curseur de l'éditeur ne se trouve pas dans un conflit de fusion", + "compareChangesTitle": "{0} : Modifications actuelles ⟷ Modifications entrantes", + "cursorOnSplitterRange": "Le curseur de l'éditeur se trouve dans le séparateur du conflit de fusion, déplacez-le dans le bloc \"actuelles\" ou \"entrantes\"", + "noConflicts": "Aucun conflit de fusion dans ce fichier", + "noOtherConflictsInThisFile": "Aucun autre conflit de fusion dans ce fichier" +} \ No newline at end of file diff --git a/i18n/fra/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/fra/extensions/merge-conflict/out/mergeDecorator.i18n.json index 8b6ad71cd4e..1dfd58679b3 100644 --- a/i18n/fra/extensions/merge-conflict/out/mergeDecorator.i18n.json +++ b/i18n/fra/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "currentChange": "(Modification actuelle)", + "incomingChange": "(Modification entrante)" +} \ No newline at end of file diff --git a/i18n/fra/extensions/merge-conflict/package.i18n.json b/i18n/fra/extensions/merge-conflict/package.i18n.json index 8b6ad71cd4e..6f812b18e76 100644 --- a/i18n/fra/extensions/merge-conflict/package.i18n.json +++ b/i18n/fra/extensions/merge-conflict/package.i18n.json @@ -3,4 +3,18 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "command.category": "Conflit de fusion", + "command.accept.all-incoming": "Accepter toutes les modifications entrantes", + "command.accept.all-both": "Accepter les deux", + "command.accept.current": "Accepter les modifications actuelles", + "command.accept.incoming": "Accepter les modifications entrantes", + "command.accept.selection": "Accepter la sélection", + "command.accept.both": "Accepter les deux", + "command.next": "Conflit suivant", + "command.previous": "Conflit précédent", + "command.compare": "Conflit de comparaison des modifications actuelles", + "config.title": "Conflit de fusion", + "config.codeLensEnabled": "Activer/désactiver le bloc CodeLens du conflit de fusion dans l'éditeur", + "config.decoratorsEnabled": "Activer/désactiver les éléments décoratifs du conflit de fusion dans l'éditeur" +} \ No newline at end of file diff --git a/i18n/fra/extensions/npm/package.i18n.json b/i18n/fra/extensions/npm/package.i18n.json index 8b6ad71cd4e..df84303decb 100644 --- a/i18n/fra/extensions/npm/package.i18n.json +++ b/i18n/fra/extensions/npm/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.npm.autoDetect": "Contrôle si la détection automatique des scripts npm est activée ou désactivée. La valeur par défaut est activée." +} \ No newline at end of file diff --git a/i18n/fra/extensions/typescript/out/features/bufferSyncSupport.i18n.json b/i18n/fra/extensions/typescript/out/features/bufferSyncSupport.i18n.json index 26cde295cd5..3187cd8f22f 100644 --- a/i18n/fra/extensions/typescript/out/features/bufferSyncSupport.i18n.json +++ b/i18n/fra/extensions/typescript/out/features/bufferSyncSupport.i18n.json @@ -4,7 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "versionMismatch": "Incompatibilité de version ! global tsc ({0}) != Service de langage de VS Code ({1}). Des erreurs de compilation incohérentes risquent de se produire", "moreInformation": "Informations", "doNotCheckAgain": "Ne plus vérifier", "close": "Fermer", diff --git a/i18n/fra/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json b/i18n/fra/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json index 8b6ad71cd4e..052fa717730 100644 --- a/i18n/fra/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json +++ b/i18n/fra/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "ts-check": "Active la vérification sémantique dans un fichier JavaScript. Doit se trouver au début d'un fichier.", + "ts-nocheck": "Désactive la vérification sémantique dans un fichier JavaScript. Doit se trouver au début d'un fichier.", + "ts-ignore": "Supprime les erreurs @ts-check sur la ligne suivante d'un fichier." +} \ No newline at end of file diff --git a/i18n/fra/extensions/typescript/out/utils/projectStatus.i18n.json b/i18n/fra/extensions/typescript/out/utils/projectStatus.i18n.json index 9f6a19db97f..7890a4f6439 100644 --- a/i18n/fra/extensions/typescript/out/utils/projectStatus.i18n.json +++ b/i18n/fra/extensions/typescript/out/utils/projectStatus.i18n.json @@ -6,7 +6,6 @@ { "hintExclude": "Pour activer les fonctionnalités de langage JavaScript/TypeScript à l'échelle du projet, excluez les dossiers contenant de nombreux fichiers, par exemple : {0}", "hintExclude.generic": "Pour activer les fonctionnalités de langage JavaScript/TypeScript à l'échelle du projet, excluez les dossiers volumineux contenant des fichiers sources inutilisés.", - "open": "Configurer les exclusions", "large.label": "Configurer les exclusions", "hintExclude.tooltip": "Pour activer les fonctionnalités de langage JavaScript/TypeScript à l'échelle du projet, excluez les dossiers volumineux contenant des fichiers sources inutilisés." } \ No newline at end of file diff --git a/i18n/fra/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/fra/extensions/typescript/out/utils/typingsStatus.i18n.json index 0b61796218c..36ca9606c1c 100644 --- a/i18n/fra/extensions/typescript/out/utils/typingsStatus.i18n.json +++ b/i18n/fra/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "installingPackages": "Récupération (fetch) des données pour l'amélioration de TypeScript IntelliSense", + "typesInstallerInitializationFailed.title": "Impossible d'installer des fichiers de typages pour les fonctionnalités de langage JavaScript. Vérifiez que NPM est installé ou configurez 'typescript.npm' dans vos paramètres utilisateur", "typesInstallerInitializationFailed.moreInformation": "Informations", "typesInstallerInitializationFailed.doNotCheckAgain": "Ne plus vérifier", "typesInstallerInitializationFailed.close": "Fermer" diff --git a/i18n/fra/extensions/typescript/package.i18n.json b/i18n/fra/extensions/typescript/package.i18n.json index d672a75d013..53c76f9a4c4 100644 --- a/i18n/fra/extensions/typescript/package.i18n.json +++ b/i18n/fra/extensions/typescript/package.i18n.json @@ -13,7 +13,6 @@ "typescript.check.tscVersion": "Vérifiez si un compilateur TypeScript installé globalement (par exemple tsc) est différent du service de langage TypeScript.", "typescript.tsserver.log": "Active la journalisation du serveur TS dans un fichier. Ce journal peut être utilisé pour diagnostiquer les problèmes du serveur TS. Il peut contenir des chemins de fichier, du code source et d'autres informations potentiellement sensibles de votre projet.", "typescript.tsserver.trace": "Active le traçage des messages envoyés au serveur TS. Cette trace peut être utilisée pour diagnostiquer les problèmes du serveur TS. Elle peut contenir des chemins de fichier, du code source et d'autres informations potentiellement sensibles de votre projet.", - "typescript.tsserver.experimentalAutoBuild": "Active la build automatique expérimentale. Nécessite la version 1.9 dev ou 2.x tsserver et le redémarrage du code VS une fois celui-ci modifié.", "typescript.validate.enable": "Activez/désactivez la validation TypeScript.", "typescript.format.enable": "Activez/désactivez le formateur TypeScript par défaut.", "javascript.format.enable": "Activez/désactivez le formateur JavaScript par défaut.", @@ -33,8 +32,16 @@ "javascript.validate.enable": "Activez/désactivez la validation JavaScript.", "typescript.goToProjectConfig.title": "Accéder à la configuration du projet", "javascript.goToProjectConfig.title": "Accéder à la configuration du projet", + "javascript.referencesCodeLens.enabled": "Activez/désactivez les références CodeLens dans les fichiers JavaScript.", + "typescript.referencesCodeLens.enabled": "Activez/désactivez les références CodeLens dans les fichiers TypeScript. Nécessite TypeScript >= 2.0.6.", "typescript.implementationsCodeLens.enabled": "Activer/désactiver CodeLens dans les implémentations. Nécessite TypeScript >= 2.2.0.", + "typescript.openTsServerLog.title": "Ouvrir le journal du serveur TS", + "typescript.restartTsServer": "Redémarrer le serveur TS", "typescript.selectTypeScriptVersion.title": "Sélectionner la version de TypeScript", "jsDocCompletion.enabled": "Activer/désactiver les commentaires JSDoc automatiques", - "javascript.implicitProjectConfig.checkJs": "Activer/désactiver la vérification sémantique des fichiers JavaScript. Les fichiers jsconfig.json ou tsconfig.json existants remplacent ce paramètre. Nécessite TypeScript >=2.3.1." + "javascript.implicitProjectConfig.checkJs": "Activer/désactiver la vérification sémantique des fichiers JavaScript. Les fichiers jsconfig.json ou tsconfig.json existants remplacent ce paramètre. Nécessite TypeScript >=2.3.1.", + "typescript.npm": "Spécifie le chemin de l'exécutable NPM utilisé pour l'acquisition de type automatique. Nécessite TypeScript >= 2.3.4.", + "typescript.check.npmIsInstalled": "Vérifie si NPM est installé pour l'acquisition de type automatique.", + "javascript.nameSuggestions": "Activez/désactivez l'inclusion de noms uniques à partir du fichier dans les listes de suggestions JavaScript.", + "typescript.tsc.autoDetect": "Contrôle si la détection automatique des tâches tsc est activée ou désactivée." } \ No newline at end of file diff --git a/i18n/fra/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/fra/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index b6faf1c8af7..e5800681aa3 100644 --- a/i18n/fra/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/fra/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,6 +6,7 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "L'image est trop grande pour être affichée dans l'éditeur. ", + "resourceOpenExternalButton": " Ouvrir l'image en utilisant un programme externe ?", "nativeBinaryError": "Impossible d'afficher le fichier dans l'éditeur : soit il est binaire, soit il est très volumineux, soit il utilise un encodage de texte non pris en charge.", "sizeB": "{0} o", "sizeKB": "{0} Ko", diff --git a/i18n/fra/src/vs/base/common/errorMessage.i18n.json b/i18n/fra/src/vs/base/common/errorMessage.i18n.json index 0276e51a4a0..4871401845f 100644 --- a/i18n/fra/src/vs/base/common/errorMessage.i18n.json +++ b/i18n/fra/src/vs/base/common/errorMessage.i18n.json @@ -13,6 +13,5 @@ "error.connection.unknown": "Une erreur de connexion inconnue s'est produite. Soit vous n'êtes plus connecté à Internet, soit le serveur auquel vous êtes connecté est hors connexion.", "stackTrace.format": "{0} : {1}", "error.defaultMessage": "Une erreur inconnue s’est produite. Veuillez consulter le journal pour plus de détails.", - "nodeExceptionMessage": "Une erreur système s'est produite ({0})", "error.moreErrors": "{0} ({1} erreurs au total)" } \ No newline at end of file diff --git a/i18n/fra/src/vs/base/common/keybindingLabels.i18n.json b/i18n/fra/src/vs/base/common/keybindingLabels.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/fra/src/vs/base/common/keybindingLabels.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/fra/src/vs/code/electron-main/menus.i18n.json b/i18n/fra/src/vs/code/electron-main/menus.i18n.json index 770b210d764..15083213d9a 100644 --- a/i18n/fra/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/fra/src/vs/code/electron-main/menus.i18n.json @@ -14,6 +14,7 @@ "mHelp": "&&Aide", "miNewWindow": "Nouvelle &&fenêtre", "mAbout": "À propos de {0}", + "mServices": "Services", "mHide": "Masquer {0}", "mHideOthers": "Masquer les autres", "mShowAll": "Afficher tout", @@ -54,6 +55,9 @@ "miShowEmmetCommands": "E&&mmet...", "miToggleLineComment": "Afficher/masquer le commen&&taire de ligne", "miToggleBlockComment": "Afficher/masquer le commentaire de &&bloc", + "miMultiCursorAlt": "Utiliser Alt+Clic pour l'option multicurseur", + "miMultiCursorCmd": "Utiliser Cmd+Clic pour l'option multicurseur", + "miMultiCursorCtrl": "Utiliser Ctrl+Clic pour l'option multicurseur", "miInsertCursorAbove": "&&Ajouter un curseur au-dessus", "miInsertCursorBelow": "Aj&&outer un curseur en dessous", "miInsertCursorAtEndOfEachLineSelected": "Ajouter des c&&urseurs à la fin des lignes", @@ -69,6 +73,7 @@ "miSmartSelectShrink": "&&Réduire la sélection", "miViewExplorer": "&&Explorateur", "miViewSearch": "&&Rechercher", + "miViewSCM": "S&&CM", "miViewDebug": "&&Déboguer", "miViewExtensions": "E&&xtensions", "miToggleOutput": "&&Sortie", @@ -113,6 +118,8 @@ "miGotoSymbolInFile": "Atteindre le &&symbole dans le fichier...", "miGotoSymbolInWorkspace": "Atteindre le symbole dans l'espace de &&travail...", "miGotoDefinition": "Atteindre la &&définition", + "miGotoTypeDefinition": "Accéder à la définition de &&type", + "miGotoImplementation": "Accéder à l'&&implémentation", "miGotoLine": "Atteindre la &&ligne...", "miStartDebugging": "&&Démarrer le débogage", "miStartWithoutDebugging": "Démarrer &&sans débogage", @@ -129,16 +136,17 @@ "miColumnBreakpoint": "P&&oint d'arrêt de la colonne", "miFunctionBreakpoint": "Point d'arrêt sur &&fonction...", "miNewBreakpoint": "&&Nouveau point d'arrêt", + "miEnableAllBreakpoints": "Activer tous les points d'arrêt", "miDisableAllBreakpoints": "Désacti&&ver tous les points d'arrêt", "miRemoveAllBreakpoints": "Supprimer &&tous les points d'arrêt", "miInstallAdditionalDebuggers": "&&Installer des débogueurs supplémentaires...", "mMinimize": "Réduire", - "mClose": "Fermer", "mBringToFront": "Mettre tout au premier plan", "miToggleDevTools": "Activer/désactiver les ou&&tils de développement", "miAccessibilityOptions": "&&Options d'accessibilité", "miReportIssues": "S&&ignaler les problèmes", "miWelcome": "&&Bienvenue", + "miInteractivePlayground": "Terrain de jeu &&interactif", "miDocumentation": "&&Documentation", "miReleaseNotes": "Notes de pu&&blication", "miKeyboardShortcuts": "Référence des racco&&urcis clavier", @@ -148,12 +156,14 @@ "miLicense": "Affic&&her la licence", "miPrivacyStatement": "Déc&&laration de confidentialité", "miAbout": "À pr&&opos de", + "miTerminateTask": "&&Terminer la tâche", "accessibilityOptionsWindowTitle": "Options d'accessibilité", "miRestartToUpdate": "Redémarrer pour mettre à jour...", "miCheckingForUpdates": "Recherche des mises à jour...", "miDownloadUpdate": "Télécharger la mise à jour disponible", "miDownloadingUpdate": "Téléchargement de la mise à jour...", "miInstallingUpdate": "Installation de la mise à jour...", + "miCheckForUpdates": "Rechercher les mises à jour...", "aboutDetail": "\nVersion {0}\nValidation {1}\nDate {2}\nInterpréteur de commandes {3}\nConvertisseur {4}\nNode {5}", "okButton": "OK" } \ No newline at end of file diff --git a/i18n/fra/src/vs/code/electron-main/windows.i18n.json b/i18n/fra/src/vs/code/electron-main/windows.i18n.json index af0778db015..b1abddadd24 100644 --- a/i18n/fra/src/vs/code/electron-main/windows.i18n.json +++ b/i18n/fra/src/vs/code/electron-main/windows.i18n.json @@ -13,9 +13,5 @@ "appStalled": "La fenêtre ne répond plus", "appStalledDetail": "Vous pouvez rouvrir ou fermer la fenêtre, ou continuer à patienter.", "appCrashed": "La fenêtre s'est bloquée", - "appCrashedDetail": "Nous vous prions de nous excuser pour ce désagrément. Vous pouvez rouvrir la fenêtre pour reprendre l'action au moment où elle a été interrompue.", - "newWindow": "Nouvelle fenêtre", - "newWindowDesc": "Ouvre une nouvelle fenêtre", - "recentFolders": "Dossiers récents", - "folderDesc": "{0} {1}" + "appCrashedDetail": "Nous vous prions de nous excuser pour ce désagrément. Vous pouvez rouvrir la fenêtre pour reprendre l'action au moment où elle a été interrompue." } \ No newline at end of file diff --git a/i18n/fra/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/fra/src/vs/editor/common/config/commonEditorConfig.i18n.json index 16acf6481b0..a6f12dfbce1 100644 --- a/i18n/fra/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/fra/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -23,6 +23,8 @@ "minimap.enabled": "Contrôle si la minicarte est affichée", "minimap.renderCharacters": "Afficher les caractères réels sur une ligne (par opposition aux blocs de couleurs)", "minimap.maxColumn": "Limiter la largeur de la minicarte pour afficher au maximum un certain nombre de colonnes", + "find.seedSearchStringFromSelection": "Contrôle si nous remplissons la chaîne à rechercher dans le Widget Recherche à partir de la sélection de l'éditeur", + "find.autoFindInSelection": "Contrôle si l'indicateur Rechercher dans la sélection est activé quand plusieurs caractères ou lignes de texte sont sélectionnés dans l'éditeur", "wordWrap.off": "Le retour automatique à la ligne n'est jamais effectué.", "wordWrap.on": "Le retour automatique à la ligne s'effectue en fonction de la largeur de la fenêtre d'affichage.", "wordWrap.wordWrapColumn": "Le retour automatique à la ligne s'effectue en fonction de 'editor.wordWrapColumn'.", @@ -31,16 +33,19 @@ "wordWrapColumn": "Contrôle la colonne de retour automatique à la ligne de l'éditeur quand 'editor.wordWrap' a la valeur 'wordWrapColumn' ou 'bounded'.", "wrappingIndent": "Contrôle le retrait des lignes renvoyées. La valeur peut être 'none', 'same' ou 'indent'.", "mouseWheelScrollSensitivity": "Multiplicateur à utiliser pour le 'deltaX' et le 'deltaY' des événements de défilement de la roulette de la souris", + "multiCursorModifier.ctrlCmd": "Mappe vers 'Contrôle' dans Windows et Linux, et vers 'Commande' dans OSX.", + "multiCursorModifier.alt": "Mappe vers 'Alt' dans Windows et Linux, et vers 'Option' dans OSX.", + "multiCursorModifier": "Modificateur à utiliser pour ajouter plusieurs curseurs avec la souris. 'ctrlCmd' mappe vers 'Contrôle' dans Windows et Linux, et vers 'Commande' dans OSX. Les mouvements de souris Accéder à la définition et Ouvrir le lien s'adaptent pour ne pas entrer en conflit avec le modificateur multicurseur.", "quickSuggestions.strings": "Activez les suggestions rapides dans les chaînes.", "quickSuggestions.comments": "Activez les suggestions rapides dans les commentaires.", "quickSuggestions.other": "Activez les suggestions rapides en dehors des chaînes et des commentaires.", "quickSuggestions": "Contrôle si les suggestions doivent s'afficher automatiquement en cours de frappe", "quickSuggestionsDelay": "Contrôle le délai en ms au bout duquel les suggestions rapides s'affichent", - "parameterHints": "Active les indicateurs de paramètres", "autoClosingBrackets": "Contrôle si l'éditeur doit automatiquement fermer les crochets après les avoir ouverts", "formatOnType": "Contrôle si l'éditeur doit automatiquement mettre en forme la ligne après la saisie", "formatOnPaste": "Contrôle si l'éditeur doit automatiquement mettre en forme le contenu collé. Un formateur doit être disponible et doit pouvoir mettre en forme une plage dans un document.", "suggestOnTriggerCharacters": "Contrôle si les suggestions doivent s'afficher automatiquement durant la saisie de caractères de déclenchement", + "acceptSuggestionOnEnter": "Contrôle si les suggestions doivent être acceptées avec 'Entrée', en plus de 'Tab'. Cela permet d'éviter toute ambiguïté entre l'insertion de nouvelles lignes et l'acceptation de suggestions. La valeur 'smart' signifie que vous acceptez uniquement une suggestion avec Entrée quand elle applique une modification de texte", "acceptSuggestionOnCommitCharacter": "Contrôle si les suggestions doivent être acceptées avec des caractères de validation. Par exemple, en JavaScript, le point-virgule (';') peut être un caractère de validation qui permet d'accepter une suggestion et de taper ce caractère.", "snippetSuggestions": "Contrôle si les extraits de code s'affichent en même temps que d'autres suggestions, ainsi que leur mode de tri.", "emptySelectionClipboard": "Contrôle si la copie sans sélection permet de copier la ligne actuelle.", @@ -62,12 +67,17 @@ "renderLineHighlight": "Contrôle la façon dont l'éditeur doit afficher la surbrillance de la ligne active. Les différentes possibilités sont 'none', 'gutter', 'line' et 'all'.", "codeLens": "Contrôle si l'éditeur affiche les indicateurs CodeLens", "folding": "Contrôle si le pliage de code est activé dans l'éditeur", + "showFoldingControls": "Définit si les contrôles de réduction sur la bordure sont cachés automatiquement", "matchBrackets": "Met en surbrillance les crochets correspondants quand l'un d'eux est sélectionné.", "glyphMargin": "Contrôle si l'éditeur doit afficher la marge de glyphes verticale. La marge de glyphes sert principalement au débogage.", "useTabStops": "L'insertion et la suppression d'un espace blanc suit les taquets de tabulation", "trimAutoWhitespace": "Supprimer l'espace blanc de fin inséré automatiquement", "stablePeek": "Garder les éditeurs d'aperçu ouverts même si l'utilisateur double-clique sur son contenu ou appuie sur la touche Échap.", "dragAndDrop": "Contrôle si l'éditeur autorise le déplacement des sélections par glisser-déplacer.", + "accessibilitySupport.auto": "L'éditeur utilise les API de la plateforme pour détecter si un lecteur d'écran est attaché.", + "accessibilitySupport.on": "L'éditeur est optimisé en permanence pour une utilisation avec un lecteur d'écran.", + "accessibilitySupport.off": "L'éditeur n'est jamais optimisé pour une utilisation avec un lecteur d'écran.", + "accessibilitySupport": "Contrôle si l'éditeur doit s'exécuter dans un mode optimisé pour les lecteurs d'écran.", "sideBySide": "Contrôle si l'éditeur de différences affiche les différences en mode côte à côte ou inline", "ignoreTrimWhitespace": "Contrôle si l'éditeur de différences affiche les changements liés aux espaces blancs de début ou de fin comme des différences", "renderIndicators": "Contrôle si l'éditeur de différences affiche les indicateurs +/- pour les modifications ajoutées/supprimées", diff --git a/i18n/fra/src/vs/editor/common/config/editorOptions.i18n.json b/i18n/fra/src/vs/editor/common/config/editorOptions.i18n.json index bf45d0601aa..452e3e365b7 100644 --- a/i18n/fra/src/vs/editor/common/config/editorOptions.i18n.json +++ b/i18n/fra/src/vs/editor/common/config/editorOptions.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "accessibilityOffAriaLabel": "L'éditeur n'est pas accessible pour le moment. Appuyez sur Alt+F1 pour connaître les options.", "editorViewAccessibleLabel": "Contenu d'éditeur" } \ No newline at end of file diff --git a/i18n/fra/src/vs/editor/common/view/editorColorRegistry.i18n.json b/i18n/fra/src/vs/editor/common/view/editorColorRegistry.i18n.json index 77ca0b5bb8f..0025ed5f438 100644 --- a/i18n/fra/src/vs/editor/common/view/editorColorRegistry.i18n.json +++ b/i18n/fra/src/vs/editor/common/view/editorColorRegistry.i18n.json @@ -16,5 +16,9 @@ "editorBracketMatchBackground": "Couleur d'arrière-plan pour les accolades associées", "editorBracketMatchBorder": "Couleur pour le contour des accolades associées", "editorOverviewRulerBorder": "Couleur de la bordure de la règle d'apperçu.", - "editorGutter": "Couleur de fond pour la bordure de l'éditeur. La bordure contient les marges pour les symboles et les numéros de ligne." + "editorGutter": "Couleur de fond pour la bordure de l'éditeur. La bordure contient les marges pour les symboles et les numéros de ligne.", + "errorForeground": "Couleur de premier plan de la ligne ondulée marquant les erreurs dans l'éditeur.", + "errorBorder": "Couleur de bordure de la ligne ondulée marquant les erreurs dans l'éditeur.", + "warningForeground": "Couleur de premier plan de la ligne ondulée marquant les avertissements dans l'éditeur.", + "warningBorder": "Couleur de bordure de la ligne ondulée marquant les avertissements dans l'éditeur." } \ No newline at end of file diff --git a/i18n/fra/src/vs/editor/contrib/find/common/findController.i18n.json b/i18n/fra/src/vs/editor/contrib/find/common/findController.i18n.json index 83dcc17be9b..255c5de5a27 100644 --- a/i18n/fra/src/vs/editor/contrib/find/common/findController.i18n.json +++ b/i18n/fra/src/vs/editor/contrib/find/common/findController.i18n.json @@ -14,6 +14,5 @@ "addSelectionToPreviousFindMatch": "Ajouter la sélection à la correspondance de recherche précédente", "moveSelectionToNextFindMatch": "Déplacer la dernière sélection vers la correspondance de recherche suivante", "moveSelectionToPreviousFindMatch": "Déplacer la dernière sélection à la correspondance de recherche précédente", - "selectAllOccurencesOfFindMatch": "Sélectionner toutes les occurrences des correspondances de la recherche", "changeAll.label": "Modifier toutes les occurrences" } \ No newline at end of file diff --git a/i18n/fra/src/vs/editor/contrib/links/browser/links.i18n.json b/i18n/fra/src/vs/editor/contrib/links/browser/links.i18n.json index f16f0098955..3b71097e7df 100644 --- a/i18n/fra/src/vs/editor/contrib/links/browser/links.i18n.json +++ b/i18n/fra/src/vs/editor/contrib/links/browser/links.i18n.json @@ -6,6 +6,7 @@ { "links.navigate.mac": "Commande + clic pour suivre le lien", "links.navigate": "Ctrl + clic pour suivre le lien", + "links.navigate.al": "Alt + clic pour suivre le lien", "invalid.url": "Échec de l'ouverture de ce lien, car il n'est pas bien formé : {0}", "missing.url": "Échec de l'ouverture de ce lien, car sa cible est manquante.", "label": "Ouvrir le lien" diff --git a/i18n/fra/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json b/i18n/fra/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json index e4871d36b89..733dbb088ce 100644 --- a/i18n/fra/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json +++ b/i18n/fra/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json @@ -5,8 +5,6 @@ // Do not edit this file. It is machine generated. { "aria.oneReference": "symbole dans {0} sur la ligne {1}, colonne {2}", - "aria.fileReferences.1": "1 symbole dans {0}", - "aria.fileReferences.N": "{0} symboles dans {1}", "aria.result.0": "Résultats introuvables", "aria.result.1": "1 symbole dans {0}", "aria.result.n1": "{0} symboles dans {1}", diff --git a/i18n/fra/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json b/i18n/fra/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json index b2ba0b9ad35..498b3551c28 100644 --- a/i18n/fra/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json +++ b/i18n/fra/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json @@ -16,9 +16,12 @@ "peekViewTitleInfoForeground": "Couleur des informations sur le titre de l'affichage d'aperçu.", "peekViewBorder": "Couleur des bordures et de la flèche de l'affichage d'aperçu.", "peekViewResultsBackground": "Couleur d'arrière-plan de la liste des résultats de l'affichage d'aperçu.", + "peekViewResultsMatchForeground": "Couleur de premier plan des noeuds de lignes dans la liste des résultats de l'affichage d'aperçu.", + "peekViewResultsFileForeground": "Couleur de premier plan des noeuds de fichiers dans la liste des résultats de l'affichage d'aperçu.", "peekViewResultsSelectionBackground": "Couleur d'arrière-plan de l'entrée sélectionnée dans la liste des résultats de l'affichage d'aperçu.", "peekViewResultsSelectionForeground": "Couleur de premier plan de l'entrée sélectionnée dans la liste des résultats de l'affichage d'aperçu.", "peekViewEditorBackground": "Couleur d'arrière-plan de l'éditeur d'affichage d'aperçu.", + "peekViewEditorGutterBackground": "Couleur d'arrière-plan de la bordure de l'éditeur d'affichage d'aperçu.", "peekViewResultsMatchHighlight": "Couleur de mise en surbrillance d'une correspondance dans la liste des résultats de l'affichage d'aperçu.", "peekViewEditorMatchHighlight": "Couleur de mise en surbrillance d'une correspondance dans l'éditeur de l'affichage d'aperçu." } \ No newline at end of file diff --git a/i18n/fra/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json b/i18n/fra/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json index e38b8d1bf14..75285eb257e 100644 --- a/i18n/fra/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json +++ b/i18n/fra/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json @@ -12,6 +12,7 @@ "readMore": "En savoir plus...{0}", "suggestionWithDetailsAriaLabel": "{0}, suggestion, avec détails", "suggestionAriaLabel": "{0}, suggestion", + "readLess": "En savoir moins...{0}", "suggestWidget.loading": "Chargement...", "suggestWidget.noSuggestions": "Pas de suggestions.", "suggestionAriaAccepted": "{0}, accepté", diff --git a/i18n/fra/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json b/i18n/fra/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json index 315671f3b22..4ec0caa12c1 100644 --- a/i18n/fra/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json +++ b/i18n/fra/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json @@ -21,6 +21,8 @@ "menus.scmTitle": "Menu du titre du contrôle de code source", "menus.resourceGroupContext": "Menu contextuel du groupe de ressources du contrôle de code source", "menus.resourceStateContext": "Menu contextuel de l'état des ressources du contrôle de code source", + "view.viewTitle": "Menu de titre de la vue ajoutée", + "view.itemContext": "Menu contextuel de l'élément de vue ajoutée", "nonempty": "valeur non vide attendue.", "opticon": "la propriété 'icon' peut être omise, ou bien elle doit être une chaîne ou un littéral tel que '{dark, light}'", "requireStringOrObject": "la propriété `{0}` est obligatoire et doit être de type `string` ou `object`", diff --git a/i18n/fra/src/vs/platform/extensions/common/extensionsRegistry.i18n.json b/i18n/fra/src/vs/platform/extensions/common/extensionsRegistry.i18n.json index 23d586b47fb..1b99c644dbb 100644 --- a/i18n/fra/src/vs/platform/extensions/common/extensionsRegistry.i18n.json +++ b/i18n/fra/src/vs/platform/extensions/common/extensionsRegistry.i18n.json @@ -14,6 +14,12 @@ "vscode.extension.contributes": "Toutes les contributions de l'extension VS Code représentées par ce package.", "vscode.extension.preview": "Définit l'extension à marquer en tant que préversion dans Marketplace.", "vscode.extension.activationEvents": "Événements d'activation pour l'extension VS Code.", + "vscode.extension.activationEvents.onLanguage": "Événement d'activation envoyé quand un fichier résolu dans le langage spécifié est ouvert.", + "vscode.extension.activationEvents.onCommand": "Événement d'activation envoyé quand la commande spécifiée est appelée.", + "vscode.extension.activationEvents.onDebug": "Événement d'activation envoyé quand une session de débogage du type spécifié est démarrée.", + "vscode.extension.activationEvents.workspaceContains": "Événement d'activation envoyé quand un dossier ouvert contient au moins un fichier correspondant au modèle glob spécifié.", + "vscode.extension.activationEvents.onView": "Événement d'activation envoyé quand la vue spécifiée est développée.", + "vscode.extension.activationEvents.star": "Événement d'activation envoyé au démarrage de VS Code. Pour garantir la qualité de l'expérience utilisateur, utilisez cet événement d'activation dans votre extension uniquement quand aucune autre combinaison d'événements d'activation ne fonctionne dans votre cas d'utilisation.", "vscode.extension.badges": "Ensemble de badges à afficher dans la barre latérale de la page d'extensions de Marketplace.", "vscode.extension.badges.url": "URL de l'image du badge.", "vscode.extension.badges.href": "Lien du badge.", diff --git a/i18n/fra/src/vs/platform/history/electron-main/historyMainService.i18n.json b/i18n/fra/src/vs/platform/history/electron-main/historyMainService.i18n.json new file mode 100644 index 00000000000..316d8cd9473 --- /dev/null +++ b/i18n/fra/src/vs/platform/history/electron-main/historyMainService.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "newWindow": "Nouvelle fenêtre", + "newWindowDesc": "Ouvre une nouvelle fenêtre", + "recentFolders": "Dossiers récents", + "folderDesc": "{0} {1}" +} \ No newline at end of file diff --git a/i18n/fra/src/vs/platform/markers/common/problemMatcher.i18n.json b/i18n/fra/src/vs/platform/markers/common/problemMatcher.i18n.json index 985f7884334..42756c8837c 100644 --- a/i18n/fra/src/vs/platform/markers/common/problemMatcher.i18n.json +++ b/i18n/fra/src/vs/platform/markers/common/problemMatcher.i18n.json @@ -34,6 +34,7 @@ "ProblemMatcherParser.noValidIdentifier": "Erreur : la propriété de modèle {0} n'est pas un nom de variable de modèle valide.", "ProblemMatcherParser.problemPattern.watchingMatcher": "Un détecteur de problèmes de correspondance doit définir un modèle de début et un modèle de fin à observer.", "ProblemMatcherParser.invalidRegexp": "Erreur : la chaîne {0} est une expression régulière non valide.\n", + "WatchingPatternSchema.regexp": "Expression régulière permettant de détecter le début ou la fin d'une tâche en arrière-plan.", "WatchingPatternSchema.file": "Index de groupe de correspondance du nom de fichier. Peut être omis.", "PatternTypeSchema.name": "Nom d'un modèle faisant l'objet d'une contribution ou prédéfini", "PatternTypeSchema.description": "Modèle de problème ou bien nom d'un modèle de problème faisant l'objet d'une contribution ou prédéfini. Peut être omis si base est spécifié.", @@ -42,6 +43,12 @@ "ProblemMatcherSchema.severity": "Gravité par défaut des problèmes de capture. Est utilisé si le modèle ne définit aucun groupe de correspondance pour la gravité.", "ProblemMatcherSchema.applyTo": "Contrôle si un problème signalé pour un document texte s'applique uniquement aux documents ouverts ou fermés, ou bien à l'ensemble des documents.", "ProblemMatcherSchema.fileLocation": "Définit la façon dont les noms de fichiers signalés dans un modèle de problème doivent être interprétés.", + "ProblemMatcherSchema.background": "Modèles de suivi du début et de la fin d'un détecteur de problèmes de correspondance actif sur une tâche en arrière-plan.", + "ProblemMatcherSchema.background.activeOnStart": "Si la valeur est true, le moniteur d'arrière-plan est actif au démarrage de la tâche. Cela revient à envoyer une ligne qui correspond à beginPattern", + "ProblemMatcherSchema.background.beginsPattern": "En cas de correspondance dans la sortie, le début d'une tâche en arrière-plan est signalé.", + "ProblemMatcherSchema.background.endsPattern": "En cas de correspondance dans la sortie, la fin d'une tâche en arrière-plan est signalée.", + "ProblemMatcherSchema.watching.deprecated": "La propriété espion est déconseillée. Utilisez l'arrière-plan à la place.", + "ProblemMatcherSchema.watching": "Modèles de suivi du début et de la fin d'un détecteur de problèmes de correspondance espion.", "ProblemMatcherSchema.watching.activeOnStart": "Si la valeur est true, le mode espion est actif au démarrage de la tâche. Cela revient à émettre une ligne qui correspond à beginPattern", "ProblemMatcherSchema.watching.beginsPattern": "En cas de correspondance dans la sortie, le début d'une tâche de suivi est signalé.", "ProblemMatcherSchema.watching.endsPattern": "En cas de correspondance dans la sortie, la fin d'une tâche de suivi est signalée.", diff --git a/i18n/fra/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/fra/src/vs/platform/theme/common/colorRegistry.i18n.json index 4977fe04f0b..5d206ed6b98 100644 --- a/i18n/fra/src/vs/platform/theme/common/colorRegistry.i18n.json +++ b/i18n/fra/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -16,11 +16,15 @@ "textLinkForeground": "Couleur des liens dans le texte.", "textLinkActiveForeground": "Couleur des liens actifs dans le texte.", "textPreformatForeground": "Couleur des segments de texte préformatés.", + "textBlockQuoteBackground": "Couleur d'arrière-plan des citations dans le texte.", + "textBlockQuoteBorder": "Couleur de bordure des citations dans le texte.", + "textCodeBlockBackground": "Couleur d'arrière-plan des blocs de code dans le texte.", "widgetShadow": "Couleur de l'ombre des widgets, comme rechercher/remplacer, au sein de l'éditeur.", "inputBoxBackground": "Arrière-plan de la zone d'entrée.", "inputBoxForeground": "Premier plan de la zone d'entrée.", "inputBoxBorder": "Bordure de la zone d'entrée.", "inputBoxActiveOptionBorder": "Couleur de la bordure des options activées dans les champs d'entrée.", + "inputPlaceholderForeground": "Couleur de premier plan de la zone d'entrée pour le texte d'espace réservé.", "inputValidationInfoBackground": "Couleur d'arrière-plan de la validation d'entrée pour la gravité des informations.", "inputValidationInfoBorder": "Couleur de bordure de la validation d'entrée pour la gravité des informations.", "inputValidationWarningBackground": "Couleur d'arrière-plan de la validation d'entrée pour l'avertissement sur les informations.", @@ -31,10 +35,13 @@ "dropdownForeground": "Premier plan de la liste déroulante.", "dropdownBorder": "Bordure de la liste déroulante.", "listFocusBackground": "Couleur d'arrière-plan de la liste/l'arborescence pour l'élément ayant le focus quand la liste/l'arborescence est active. Une liste/aborescence active peut être sélectionnée au clavier, elle ne l'est pas quand elle est inactive.", + "listFocusForeground": "Couleur de premier plan de la liste/l'arborescence pour l'élément ayant le focus quand la liste/l'arborescence est active. Une liste/aborescence active peut être sélectionnée au clavier, elle ne l'est pas quand elle est inactive.", "listActiveSelectionBackground": "Couleur d'arrière-plan de la liste/l'arborescence de l'élément sélectionné quand la liste/l'arborescence est active. Une liste/arborescence active peut être sélectionnée au clavier, elle ne l'est pas quand elle est inactive.", "listActiveSelectionForeground": "Couleur de premier plan de la liste/l'arborescence pour l'élément sélectionné quand la liste/l'arborescence est active. Une liste/aborescence active peut être sélectionnée au clavier, elle ne l'est pas quand elle est inactive.", "listInactiveSelectionBackground": "Couleur d'arrière-plan de la liste/l'arborescence pour l'élément sélectionné quand la liste/l'arborescence est inactive. Une liste/aborescence active peut être sélectionnée au clavier, elle ne l'est pas quand elle est inactive.", + "listInactiveSelectionForeground": "Couleur de premier plan de la liste/l'arborescence pour l'élément sélectionné quand la liste/l'arborescence est active. Une liste/aborescence active peut être sélectionnée au clavier, elle ne l'est pas quand elle est inactive.", "listHoverBackground": "Arrière-plan de la liste/l'arborescence pendant le pointage sur des éléments avec la souris.", + "listHoverForeground": "Premier plan de la liste/l'arborescence pendant le pointage sur des éléments avec la souris.", "listDropBackground": "Arrière-plan de l'opération de glisser-déplacer dans une liste/arborescence pendant le déplacement d'éléments avec la souris.", "highlight": "Couleur de premier plan dans la liste/l'arborescence pour la surbrillance des correspondances pendant la recherche dans une liste/arborescence.", "pickerGroupForeground": "Couleur du sélecteur rapide pour les étiquettes de regroupement.", @@ -52,6 +59,7 @@ "editorBackground": "Couleur d'arrière-plan de l'éditeur.", "editorForeground": "Couleur de premier plan par défaut de l'éditeur.", "editorWidgetBackground": "Couleur d'arrière-plan des gadgets de l'éditeur tels que rechercher/remplacer.", + "editorWidgetBorder": "Couleur de bordure des widgets de l'éditeur. La couleur est utilisée uniquement si le widget choisit d'avoir une bordure et si la couleur n'est pas remplacée par un widget.", "editorSelection": "Couleur de la sélection de l'éditeur.", "editorInactiveSelection": "Couleur de la sélection dans un éditeur inactif.", "editorSelectionHighlight": "Couleur des régions dont le contenu est identique à la sélection.", @@ -65,5 +73,12 @@ "diffEditorInserted": "Couleur d'arrière-plan du texte inséré.", "diffEditorRemoved": "Couleur d'arrière-plan du texte supprimé.", "diffEditorInsertedOutline": "Couleur de contour du texte inséré.", - "diffEditorRemovedOutline": "Couleur de contour du texte supprimé." + "diffEditorRemovedOutline": "Couleur de contour du texte supprimé.", + "mergeCurrentHeaderBackground": "Arrière-plan de l'en-tête actuel dans les conflits de fusion inline.", + "mergeCurrentContentBackground": "Arrière-plan du contenu actuel dans les conflits de fusion inline.", + "mergeIncomingHeaderBackground": "Arrière-plan de l'en-tête entrant dans les conflits de fusion inline.", + "mergeIncomingContentBackground": "Arrière-plan du contenu entrant dans les conflits de fusion inline.", + "mergeBorder": "Couleur de bordure des en-têtes et du séparateur dans les conflits de fusion inline.", + "overviewRulerCurrentContentForeground": "Premier plan de la règle d'aperçu actuelle pour les conflits de fusion inline.", + "overviewRulerIncomingContentForeground": "Premier plan de la règle d'aperçu entrante pour les conflits de fusion inline." } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/fra/src/vs/workbench/api/node/extHostTask.i18n.json index 8b6ad71cd4e..c9b8882d437 100644 --- a/i18n/fra/src/vs/workbench/api/node/extHostTask.i18n.json +++ b/i18n/fra/src/vs/workbench/api/node/extHostTask.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "task.label": "{0} : {1}" +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/api/node/extHostTreeViews.i18n.json b/i18n/fra/src/vs/workbench/api/node/extHostTreeViews.i18n.json index 8b6ad71cd4e..2c25d01eeb1 100644 --- a/i18n/fra/src/vs/workbench/api/node/extHostTreeViews.i18n.json +++ b/i18n/fra/src/vs/workbench/api/node/extHostTreeViews.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "treeView.notRegistered": "Aucune arborescence avec l'ID '{0}' n'est inscrite.", + "treeItem.notFound": "L'élément d'arborescence avec l'ID '{0}' est introuvable.", + "treeView.duplicateElement": "L'élément '{0}' est déjà inscrit" +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/browser/actions/configureLocale.i18n.json b/i18n/fra/src/vs/workbench/browser/actions/configureLocale.i18n.json index ef4f2686d9e..a8e6e2e5147 100644 --- a/i18n/fra/src/vs/workbench/browser/actions/configureLocale.i18n.json +++ b/i18n/fra/src/vs/workbench/browser/actions/configureLocale.i18n.json @@ -7,6 +7,7 @@ "configureLocale": "Configurer la langue", "displayLanguage": "Définit le langage affiché par VSCode.", "doc": "Consultez {0} pour connaître la liste des langues prises en charge.", + "restart": "Le changement de la valeur nécessite le redémarrage de VS Code.", "fail.createSettings": "Impossible de créer '{0}' ({1}).", "JsonSchema.locale": "Langue d'interface utilisateur (IU) à utiliser." } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json b/i18n/fra/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json index 7b7e61c23f4..a04b897abfe 100644 --- a/i18n/fra/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json +++ b/i18n/fra/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json @@ -5,5 +5,6 @@ // Do not edit this file. It is machine generated. { "hideActivitBar": "Masquer la barre d'activités", - "activityBarAriaLabel": "Sélecteur d'affichage actif" + "activityBarAriaLabel": "Sélecteur d'affichage actif", + "globalActions": "Actions globales" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json b/i18n/fra/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json index a96ef282603..625e22d6bcd 100644 --- a/i18n/fra/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json +++ b/i18n/fra/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json @@ -10,7 +10,7 @@ "multiSelection": "{0} sélections", "endOfLineLineFeed": "LF", "endOfLineCarriageReturnLineFeed": "CRLF", - "tabFocusModeEnabled": "La touche Tab déplace le focus", + "screenReaderDetectedExtra": "Si vous n'utilisez pas de lecteur d'écran, définissez le paramètre 'editor.accessibilitySupport' sur \"désactivé\".", "disableTabMode": "Désactiver le mode d'accessibilité", "gotoLine": "Atteindre la ligne", "indentation": "Retrait", diff --git a/i18n/fra/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json b/i18n/fra/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json new file mode 100644 index 00000000000..4ae604a5c68 --- /dev/null +++ b/i18n/fra/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpen": "Atteindre le fichier...", + "quickNavigateNext": "Naviguer vers l'élément suivant dans Quick Open", + "quickNavigatePrevious": "Naviguer vers l'élément précédent dans Quick Open", + "quickSelectNext": "Sélectionner l'élément suivant dans Quick Open", + "quickSelectPrevious": "Sélectionner l'élément précédent dans Quick Open" +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/browser/quickopen.i18n.json b/i18n/fra/src/vs/workbench/browser/quickopen.i18n.json index 553ab99539c..6c5413c9c04 100644 --- a/i18n/fra/src/vs/workbench/browser/quickopen.i18n.json +++ b/i18n/fra/src/vs/workbench/browser/quickopen.i18n.json @@ -6,6 +6,5 @@ { "noResultsMatching": "Aucun résultat correspondant", "noResultsFound2": "Résultats introuvables", - "entryAriaLabel": "{0}, commande", - "noCommands": "Aucune commande correspondante" + "entryAriaLabel": "{0}, commande" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/browser/viewlet.i18n.json b/i18n/fra/src/vs/workbench/browser/viewlet.i18n.json index a2b2c00414d..0c0be9aff9b 100644 --- a/i18n/fra/src/vs/workbench/browser/viewlet.i18n.json +++ b/i18n/fra/src/vs/workbench/browser/viewlet.i18n.json @@ -4,6 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "collapse": "Réduire tout", - "viewToolbarAriaLabel": "{0} actions" + "collapse": "Réduire tout" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/common/theme.i18n.json b/i18n/fra/src/vs/workbench/common/theme.i18n.json index 541ca65cc44..33eccb30b80 100644 --- a/i18n/fra/src/vs/workbench/common/theme.i18n.json +++ b/i18n/fra/src/vs/workbench/common/theme.i18n.json @@ -7,27 +7,42 @@ "tabActiveBackground": "Couleur d'arrière-plan de l'onglet actif. Les onglets sont les conteneurs des éditeurs dans la zone d'éditeurs. Vous pouvez ouvrir plusieurs onglets dans un groupe d'éditeurs. Il peut exister plusieurs groupes d'éditeurs.", "tabInactiveBackground": "Couleur d'arrière-plan de l'onglet inactif. Les onglets sont les conteneurs des éditeurs dans la zone d'éditeurs. Vous pouvez ouvrir plusieurs onglets dans un groupe d'éditeurs. Il peut exister plusieurs groupes d'éditeurs.", "tabBorder": "Bordure séparant les onglets les uns des autres. Les onglets sont les conteneurs des éditeurs dans la zone d'éditeurs. Vous pouvez ouvrir plusieurs onglets dans un groupe d'éditeurs. Il peut exister plusieurs groupes d'éditeurs.", + "tabActiveForeground": "Couleur de premier plan de l'onglet actif dans un groupe actif. Les onglets sont les conteneurs des éditeurs dans la zone d'éditeurs. Vous pouvez ouvrir plusieurs onglets dans un groupe d'éditeurs. Il peut exister plusieurs groupes d'éditeurs.", + "tabInactiveForeground": "Couleur de premier plan de l'onglet inactif dans un groupe actif. Les onglets sont les conteneurs des éditeurs dans la zone d'éditeurs. Vous pouvez ouvrir plusieurs onglets dans un groupe d'éditeurs. Il peut exister plusieurs groupes d'éditeurs.", + "tabUnfocusedActiveForeground": "Couleur de premier plan de l'onglet actif dans un groupe inactif. Les onglets sont les conteneurs des éditeurs dans la zone d'éditeurs. Vous pouvez ouvrir plusieurs onglets dans un groupe d'éditeurs. Il peut exister plusieurs groupes d'éditeurs.", + "tabUnfocusedInactiveForeground": "Couleur de premier plan de l'onglet inactif dans un groupe inactif. Les onglets sont les conteneurs des éditeurs dans la zone d'éditeurs. Vous pouvez ouvrir plusieurs onglets dans un groupe d'éditeurs. Il peut exister plusieurs groupes d'éditeurs.", "editorGroupBackground": "Couleur d'arrière-plan d'un groupe d'éditeurs. Les groupes d'éditeurs sont les conteneurs des éditeurs. La couleur d'arrière-plan s'affiche pendant le glissement de groupes d'éditeurs.", + "tabsContainerBackground": "Couleur d'arrière-plan de l'en-tête du titre du groupe d'éditeurs quand les onglets sont activés. Les groupes d'éditeurs sont les conteneurs des éditeurs.", + "tabsContainerBorder": "Couleur de bordure de l'en-tête du titre du groupe d'éditeurs quand les onglets sont activés. Les groupes d'éditeurs sont les conteneurs des éditeurs.", "editorGroupHeaderBackground": "Couleur d'arrière-plan de l'en-tête du titre du groupe d'éditeurs quand les onglets sont désactivés. Les groupes d'éditeurs sont les conteneurs des éditeurs.", "editorGroupBorder": "Couleur séparant plusieurs groupes d'éditeurs les uns des autres. Les groupes d'éditeurs sont les conteneurs des éditeurs.", + "editorDragAndDropBackground": "Couleur d'arrière-plan lors du déplacement des éditeurs par glissement. La couleur doit avoir une transparence pour que le contenu de l'éditeur soit visible à travers.", + "panelBackground": "Couleur d'arrière-plan du panneau. Les panneaux s'affichent sous la zone d'éditeurs et contiennent des affichages tels que la sortie et le terminal intégré.", "panelBorder": "Couleur de bordure de panneau dans la partie supérieure de séparation de l'éditeur. Les panneaux s'affichent sous la zone d'éditeurs et contiennent des affichages tels que la sortie et le terminal intégré.", "panelActiveTitleForeground": "Couleur du titre du panneau actif. Les panneaux se situent sous la zone de l'éditeur et contiennent des affichages comme la sortie et le terminal intégré.", "panelInactiveTitleForeground": "Couleur du titre du panneau inactif. Les panneaux se situent sous la zone de l'éditeur et contiennent des affichages comme la sortie et le terminal intégré.", "panelActiveTitleBorder": "Couleur de la bordure du titre du panneau actif. Les panneaux se situent sous la zone de l'éditeur et contiennent des affichages comme la sortie et le terminal intégré.", "statusBarForeground": "Couleur de premier plan de la barre d'état. La barre d'état est affichée en bas de la fenêtre.", "statusBarBackground": "Couleur d'arrière-plan de la barre d'état standard. La barre d'état est affichée en bas de la fenêtre.", + "statusBarBorder": "Couleur de bordure de la barre d'état faisant la séparation avec la barre latérale et l'éditeur. La barre d'état est affichée en bas de la fenêtre.", "statusBarNoFolderBackground": "Couleur d'arrière-plan de la barre d'état quand aucun dossier n'est ouvert. La barre d'état est affichée en bas de la fenêtre.", + "statusBarNoFolderForeground": "Couleur de premier plan de la barre d'état quand aucun dossier n'est ouvert. La barre d'état est affichée en bas de la fenêtre.", "statusBarItemActiveBackground": "Couleur d'arrière-plan de l'élément de la barre d'état durant un clic. La barre d'état est affichée en bas de la fenêtre.", "statusBarItemHoverBackground": "Couleur d'arrière-plan de l'élément de la barre d'état durant un pointage. La barre d'état est affichée en bas de la fenêtre.", "statusBarProminentItemBackground": "Couleur d'arrière-plan des éléments importants de la barre d'état. Les éléments importants se différencient des autres entrées de la barre d'état pour indiquer l'importance. La barre d'état est affichée en bas de la fenêtre.", "statusBarProminentItemHoverBackground": "Couleur d'arrière-plan des éléments importants de la barre d'état pendant le pointage. Les éléments importants se différencient des autres entrées de la barre d'état pour indiquer l'importance. La barre d'état est affichée en bas de la fenêtre.", "activityBarBackground": "Couleur d'arrière-plan de la barre d'activités. La barre d'activités s'affiche complètement à gauche ou à droite, et permet de naviguer entre les affichages de la barre latérale.", "activityBarForeground": "Couleur de premier plan de la barre d'activités (par ex., utilisée pour les icônes). La barre d'activités s'affiche complètement à gauche ou à droite, et permet de parcourir les vues de la barre latérale.", + "activityBarBorder": "Couleur de bordure de la barre d'activités faisant la séparation avec la barre latérale. La barre d'activités, située à l'extrême droite ou gauche, permet de parcourir les vues de la barre latérale.", + "activityBarDragAndDropBackground": "Couleur des commentaires sur une opération de glisser-déplacer pour les éléments de la barre d'activités. La couleur doit avoir une transparence pour que les entrées de la barre d'activités soient visibles à travers. La barre d'activités, située à l'extrême droite ou gauche, permet de parcourir les vues de la barre latérale.", "activityBarBadgeBackground": "Couleur d'arrière-plan du badge de notification d'activité. La barre d'activités, située à l'extrême gauche ou droite, permet de basculer entre les affichages de la barre latérale.", "activityBarBadgeForeground": "Couleur de premier plan du badge de notification d'activité. La barre d'activités, située à l'extrême gauche ou droite, permet de basculer entre les affichages de la barre latérale.", "sideBarBackground": "Couleur d'arrière-plan de la barre latérale. La barre latérale est le conteneur des affichages tels que ceux de l'exploration et la recherche.", + "sideBarForeground": "Couleur de premier plan de la barre latérale. La barre latérale est le conteneur des vues comme celles de l'explorateur et de la recherche.", + "sideBarBorder": "Couleur de bordure de la barre latérale faisant la séparation avec l'éditeur. La barre latérale est le conteneur des vues comme celles de l'explorateur et de la recherche.", "sideBarTitleForeground": "Couleur de premier plan du titre de la barre latérale. La barre latérale est le conteneur des affichages tels que ceux de l'exploration et la recherche.", "sideBarSectionHeaderBackground": "Couleur d'arrière-plan de l'en-tête de section de la barre latérale. La barre latérale est le conteneur des vues comme celles de l'explorateur et la recherche.", + "sideBarSectionHeaderForeground": "Couleur de premier plan de l'en-tête de section de la barre latérale. La barre latérale est le conteneur des vues comme celles de l'explorateur et de la recherche.", "titleBarActiveForeground": "Premier plan de la barre de titre quand la fenêtre est active. Notez que cette couleur est uniquement prise en charge sur macOS.", "titleBarInactiveForeground": "Premier plan de la barre de titre quand la fenêtre est inactive. Notez que cette couleur est uniquement prise en charge sur macOS.", "titleBarActiveBackground": "Arrière-plan de la barre de titre quand la fenêtre est active. Notez que cette couleur est uniquement prise en charge sur macOS.", diff --git a/i18n/fra/src/vs/workbench/electron-browser/actions.i18n.json b/i18n/fra/src/vs/workbench/electron-browser/actions.i18n.json index 89d053f8d1d..96da96abc3d 100644 --- a/i18n/fra/src/vs/workbench/electron-browser/actions.i18n.json +++ b/i18n/fra/src/vs/workbench/electron-browser/actions.i18n.json @@ -6,9 +6,6 @@ { "closeActiveEditor": "Fermer l'éditeur", "closeWindow": "Fermer la fenêtre", - "switchWindow": "Changer de fenêtre", - "switchWindowPlaceHolder": "Sélectionner une fenêtre", - "current": "Fenêtre active", "closeFolder": "Fermer un dossier", "noFolderOpened": "Il n'existe actuellement aucun dossier ouvert à fermer dans cette instance.", "newWindow": "Nouvelle fenêtre", @@ -20,7 +17,7 @@ "zoomReset": "Réinitialiser le zoom", "appPerf": "Performance de démarrage", "reloadWindow": "Recharger la fenêtre", - "openRecent": "Ouvrir les éléments récents", + "current": "Fenêtre active", "folders": "dossiers", "files": "fichiers", "openRecentPlaceHolderMac": "Sélectionner un chemin (maintenir la touche Cmd enfoncée pour l'ouvrir dans une nouvelle fenêtre)", @@ -32,10 +29,6 @@ "openDocumentationUrl": "Documentation", "openIntroductoryVideosUrl": "Vidéos d'introduction", "toggleSharedProcess": "Activer/désactiver le processus partagé", - "navigateLeft": "Déplacer vers l'affichage à gauche", - "navigateRight": "Déplacer vers l'affichage à droite", - "navigateUp": "Déplacer vers l'affichage au-dessus", - "navigateDown": "Déplacer vers l'affichage en dessous", "increaseViewSize": "Augmenter la taille de l'affichage actuel", "decreaseViewSize": "Diminuer la taille de l'affichage actuel" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/fra/src/vs/workbench/electron-browser/main.contribution.i18n.json index d1fbda145ce..1d5619cef58 100644 --- a/i18n/fra/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/fra/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -31,10 +31,6 @@ "window.openFoldersInNewWindow.off": "Les dossiers remplacent la dernière fenêtre active", "window.openFoldersInNewWindow.default": "Les dossiers s'ouvrent dans une nouvelle fenêtre, sauf si un dossier est sélectionné depuis l'application (par exemple, via le menu Fichier)", "openFoldersInNewWindow": "Contrôle si les dossiers doivent s'ouvrir dans une nouvelle fenêtre ou remplacer la dernière fenêtre active.\n- default : les dossiers s'ouvrent dans une nouvelle fenêtre, sauf si un dossier est sélectionné depuis l'application (par exemple, via le menu Fichier)\n- on : les dossiers s'ouvrent dans une nouvelle fenêtre\n- off : les dossiers remplacent la dernière fenêtre active\nNotez que dans certains cas, ce paramètre est ignoré (par exemple, quand vous utilisez l'option de ligne de commande -new-window ou -reuse-window).", - "window.reopenFolders.none": "Permet de ne jamais rouvrir un dossier.", - "window.reopenFolders.one": "Permet de rouvrir le dernier dossier actif.", - "window.reopenFolders.all": "Permet de rouvrir tous les dossiers de la dernière session.", - "reopenFolders": "Contrôle la façon dont les dossiers sont rouverts après un redémarrage. Sélectionnez 'none' pour ne jamais rouvrir un dossier, 'one' pour rouvrir le dernier dossier utilisé, ou 'all' pour rouvrir tous les dossiers de votre dernière session.", "restoreFullscreen": "Contrôle si une fenêtre doit être restaurée en mode plein écran si elle a été fermée dans ce mode.", "zoomLevel": "Modifiez le niveau de zoom de la fenêtre. La taille d'origine est 0. Chaque incrément supérieur (exemple : 1) ou inférieur (exemple : -1) représente un zoom 20 % plus gros ou plus petit. Vous pouvez également entrer des décimales pour changer le niveau de zoom avec une granularité plus fine.", "title": "Contrôle le titre de la fenêtre en fonction de l'éditeur actif. Les variables sont remplacées en fonction du contexte :\n${activeEditorShort} : exemple : myFile.txt\n${activeEditorMedium} : exemple : myFolder/myFile.txt\n${activeEditorLong} : exemple : /Users/Development/myProject/myFolder/myFile.txt\n${rootName} : exemple : myProject\n${rootPath} : exemple : /Users/Development/myProject\n${appName} : exemple : VS Code\n${dirty} : indicateur d'intégrité si l'intégrité de l'éditeur actif est compromise\n${separator} : séparateur conditionnel (\" - \") qui s'affiche uniquement quand il est entouré de variables avec des valeurs", @@ -42,11 +38,13 @@ "window.newWindowDimensions.inherit": "Permet d'ouvrir les nouvelles fenêtres avec la même dimension que la dernière fenêtre active.", "window.newWindowDimensions.maximized": "Permet d'ouvrir les nouvelles fenêtres de manière agrandie.", "window.newWindowDimensions.fullscreen": "Permet d'ouvrir les nouvelles fenêtres en mode plein écran.", + "newWindowDimensions": "Contrôle les dimensions d'ouverture d'une nouvelle fenêtre quand au moins une fenêtre est déjà ouverte. Par défaut, une nouvelle fenêtre s'ouvre au centre de l'écran avec des dimensions réduites. Quand la valeur est 'inherit', la fenêtre a les mêmes dimensions que la dernière fenêtre active. Quand la valeur est 'maximized', la fenêtre s'ouvre dans sa taille maximale et quand la valeur est 'fullscreen', elle s'ouvre en mode plein écran. Notez que ce paramètre n'a aucun impact sur la première fenêtre ouverte, laquelle est toujours restaurée à la taille et l'emplacement définis au moment de sa fermeture.", "window.menuBarVisibility.default": "Le menu n'est masqué qu'en mode plein écran.", "window.menuBarVisibility.visible": "Le menu est toujours visible même en mode plein écran.", "window.menuBarVisibility.toggle": "Le menu est masqué mais il peut être affiché via la touche Alt.", "window.menuBarVisibility.hidden": "Le menu est toujours masqué.", "menuBarVisibility": "Contrôle la visibilité de la barre de menus. Le paramètre 'toggle' signifie que la barre de menus est masquée, et qu'une seule pression sur la touche Alt permet de l'afficher. Par défaut, la barre de menus est visible, sauf si la fenêtre est en mode plein écran.", + "enableMenuBarMnemonics": "S'ils sont activés, les menus principaux peuvent être ouverts via des raccourcis avec la touche Alt. La désactivation des mnémoniques permet plutôt de lier ces raccourcis avec la touche Alt aux commandes de l'éditeur.", "autoDetectHighContrast": "Si cette option est activée, le thème à contraste élevé est automatiquement choisi quand Windows utilise un thème à contraste élevé. À l'inverse, le thème sombre est automatiquement choisi quand Windows n'utilise plus le thème à contraste élevé.", "titleBarStyle": "Ajustez l'apparence de la barre de titre de la fenêtre. Vous devez effectuer un redémarrage complet pour que les changements soient appliqués.", "window.nativeTabs": "Active les onglets macOS Sierra. Notez que vous devez redémarrer l'ordinateur pour appliquer les modifications et que les onglets natifs désactivent tout style de barre de titre personnalisé configuré, le cas échéant.", @@ -56,5 +54,7 @@ "zenMode.hideTabs": "Contrôle si l'activation du mode Zen masque également les onglets du banc d'essai.", "zenMode.hideStatusBar": "Contrôle si l'activation du mode Zen masque également la barre d'état au bas du banc d'essai.", "zenMode.hideActivityBar": "Contrôle si l'activation du mode Zen masque également la barre d'activités à gauche du banc d'essai.", - "zenMode.restore": "Contrôle si une fenêtre doit être restaurée en mode zen, si elle a été fermée en mode zen." + "zenMode.restore": "Contrôle si une fenêtre doit être restaurée en mode zen, si elle a été fermée en mode zen.", + "workspaceConfigurationTitle": "Espace de travail", + "files.exclude.boolean": "Modèle Glob auquel les chemins de fichiers doivent correspondre. Affectez la valeur true ou false pour activer ou désactiver le modèle." } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json b/i18n/fra/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json new file mode 100644 index 00000000000..a99450230b2 --- /dev/null +++ b/i18n/fra/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json @@ -0,0 +1,26 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "emergencyConfOn": "Définition du paramètre 'editor.accessibilitySupport' sur 'activé'.", + "openingDocs": "Ouverture de la page de documentation sur l'accessibilité dans VS Code.", + "introMsg": "Nous vous remercions de tester les options d'accessibilité de VS Code.", + "status": "État :", + "changeConfigToOnMac": "Pour configurer l'éditeur de sorte qu'il soit optimisé en permanence pour une utilisation avec un lecteur d'écran, appuyez sur Commande+E.", + "changeConfigToOnWinLinux": "Pour configurer l'éditeur de sorte qu'il soit optimisé en permanence pour une utilisation avec un lecteur d'écran, appuyez sur Ctrl+E.", + "auto_unknown": "L'éditeur est configuré pour utiliser les API de la plateforme afin de détecter si un lecteur d'écran est attaché, mais le runtime actuel ne prend pas en charge cette configuration.", + "auto_on": "L'éditeur a automatiquement détecté qu'un lecteur d'écran est attaché.", + "auto_off": "L'éditeur est configuré pour détecter automatiquement si un lecteur d'écran est attaché, ce qui n'est pas le cas pour le moment.", + "configuredOn": "L'éditeur est configuré de sorte qu'il soit optimisé en permanence pour une utilisation avec un lecteur d'écran. Vous pouvez changer ce comportement en modifiant le paramètre 'editor.accessibilitySupport'.", + "configuredOff": "L'éditeur est configuré de sorte à ne jamais être optimisé pour une utilisation avec un lecteur d'écran.", + "tabFocusModeOnMsg": "Appuyez sur Tab dans l'éditeur pour déplacer le focus vers le prochain élément pouvant être désigné comme élément actif. Activez ou désactivez ce comportement en appuyant sur {0}.", + "tabFocusModeOnMsgNoKb": "Appuyez sur Tab dans l'éditeur pour déplacer le focus vers le prochain élément pouvant être désigné comme élément actif. La commande {0} ne peut pas être déclenchée par une combinaison de touches.", + "tabFocusModeOffMsg": "Appuyez sur Tab dans l'éditeur pour insérer le caractère de tabulation. Activez ou désactivez ce comportement en appuyant sur {0}.", + "tabFocusModeOffMsgNoKb": "Appuyez sur Tab dans l'éditeur pour insérer le caractère de tabulation. La commande {0} ne peut pas être déclenchée par une combinaison de touches.", + "openDocMac": "Appuyez sur Commande+H pour ouvrir une fenêtre de navigateur contenant plus d'informations sur l'accessibilité dans VS Code.", + "openDocWinLinux": "Appuyez sur Ctrl+H pour ouvrir une fenêtre de navigateur contenant plus d'informations sur l'accessibilité dans VS Code.", + "outroMsg": "Vous pouvez masquer cette info-bulle et revenir à l'éditeur en appuyant sur Échap ou Maj+Échap.", + "ShowAccessibilityHelpAction": "Afficher l'aide sur l'accessibilité" +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json b/i18n/fra/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/fra/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json b/i18n/fra/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json new file mode 100644 index 00000000000..a18dfa416d9 --- /dev/null +++ b/i18n/fra/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleLocation": "Changer le modificateur multicurseur" +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/debug/browser/debugActions.i18n.json b/i18n/fra/src/vs/workbench/parts/debug/browser/debugActions.i18n.json index 1783ec559cb..fd1a330f1c0 100644 --- a/i18n/fra/src/vs/workbench/parts/debug/browser/debugActions.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/debug/browser/debugActions.i18n.json @@ -6,6 +6,7 @@ { "openLaunchJson": "Ouvrir {0}", "launchJsonNeedsConfigurtion": "Configurer ou corriger 'launch.json'", + "noFolderDebugConfig": "Ouvrez d'abord un dossier pour effectuer une configuration de débogage avancée.", "startDebug": "Démarrer le débogage", "startWithoutDebugging": "Exécuter sans débogage", "selectAndStartDebugging": "Sélectionner et démarrer le débogage", diff --git a/i18n/fra/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json b/i18n/fra/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json index 8b6ad71cd4e..9ea33c457e4 100644 --- a/i18n/fra/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "noFolderDebugConfig": "Ouvrez d'abord un dossier pour effectuer une configuration de débogage avancée." +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json b/i18n/fra/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json index 810f2f0eab1..66ff22521aa 100644 --- a/i18n/fra/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json @@ -5,16 +5,12 @@ // Do not edit this file. It is machine generated. { "variablesSection": "Section des variables", - "variables": "Variables", "variablesAriaTreeLabel": "Déboguer les variables", "expressionsSection": "Section des expressions", - "watch": "Espion", "watchAriaTreeLabel": "Déboguer les expressions espionnées", "callstackSection": "Section de pile des appels", "debugStopped": "En pause sur {0}", - "callStack": "Pile des appels", "callStackAriaLabel": "Déboguer la pile des appels", "breakpointsSection": "Section des points d'arrêt", - "breakpoints": "Points d'arrêt", "breakpointsAriaTreeLabel": "Déboguer les points d'arrêt" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json b/i18n/fra/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json index 213e8a8ab69..e963a7127e7 100644 --- a/i18n/fra/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json @@ -6,5 +6,6 @@ { "copyValue": "Copier la valeur", "copy": "Copier", + "copyAll": "Copier tout", "copyStackTrace": "Copier la pile des appels" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json b/i18n/fra/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json index ea381e994a0..b4fa3eab636 100644 --- a/i18n/fra/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "statusBarDebuggingBackground": "Couleur d'arrière-plan de la barre d'état quand un programme est en cours de débogage. La barre d'état est affichée en bas de la fenêtre" + "statusBarDebuggingBackground": "Couleur d'arrière-plan de la barre d'état quand un programme est en cours de débogage. La barre d'état est affichée en bas de la fenêtre", + "statusBarDebuggingForeground": "Couleur de premier plan de la barre d'état quand un programme est en cours de débogage. La barre d'état est affichée en bas de la fenêtre" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json b/i18n/fra/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json index b52cacf9ab2..8b0cfe2f540 100644 --- a/i18n/fra/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json @@ -7,6 +7,7 @@ "debugAdapterBinNotFound": "L'exécutable d'adaptateur de débogage '{0}' n'existe pas.", "debugAdapterCannotDetermineExecutable": "Impossible de déterminer l'exécutable pour l'adaptateur de débogage '{0}'.", "debugType": "Type de configuration.", + "debugTypeNotRecognised": "Le type de débogage n'est pas reconnu. Vérifiez que vous avez installé l'extension de débogage correspondante et qu'elle est activée.", "node2NotSupported": "\"node2\" n'est plus pris en charge. Utilisez \"node\" à la place, et affectez la valeur \"inspector\" à l'attribut \"protocol\".", "debugName": "Le nom de la configuration s'affiche dans le menu déroulant de la configuration de lancement.", "debugRequest": "Type de requête de configuration. Il peut s'agir de \"launch\" ou \"attach\".", diff --git a/i18n/fra/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json b/i18n/fra/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json index a8c57987711..ad194859cdc 100644 --- a/i18n/fra/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json @@ -4,6 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "previousEditPoint": "Emmet : Previous Edit Point", - "nextEditPoint": "Emmet : Next Edit Point" + "previousEditPoint": "Emmet : Go to Previous Edit Point", + "nextEditPoint": "Emmet : Go to Next Edit Point" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json b/i18n/fra/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json index 33db3866d0c..3bd0a45f594 100644 --- a/i18n/fra/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json @@ -9,5 +9,6 @@ "emmetPreferences": "Préférences utilisées pour modifier le comportement de certaines actions et résolveurs d'Emmet.", "emmetSyntaxProfiles": "Définissez le profil pour la syntaxe spécifiée ou utilisez votre propre profil avec des règles spécifiques.", "emmetExclude": "Ensemble de langages où les abréviations emmet ne doivent pas être développées.", - "emmetExtensionsPath": "Chemin d'un dossier contenant les profils, extraits et préférences Emmet" + "emmetExtensionsPath": "Chemin d'un dossier contenant les profils, extraits et préférences Emmet", + "useNewEmmet": "Essayez les nouveaux modules Emmet (qui remplaceront à terme l'ancienne bibliothèque Emmet) pour toutes les fonctionnalités Emmet." } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json b/i18n/fra/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json index 5dd842e57ef..df8369170ce 100644 --- a/i18n/fra/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json @@ -24,6 +24,10 @@ "default": "Par défaut", "debuggers": "Débogueurs ({0})", "debugger name": "Nom", + "views": "Vues ({0})", + "view id": "ID", + "view name": "Nom", + "view location": "Emplacement", "themes": "Thèmes ({0})", "JSON Validation": "Validation JSON ({0})", "commands": "Commandes ({0})", diff --git a/i18n/fra/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json b/i18n/fra/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json index 5b7a7ecda7f..0112a21db36 100644 --- a/i18n/fra/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json @@ -22,6 +22,8 @@ "disableGloballyAction": "Toujours", "disableAction": "Désactiver", "checkForUpdates": "Rechercher les mises à jour", + "enableAutoUpdate": "Activer la mise à jour automatique des extensions", + "disableAutoUpdate": "Désactiver la mise à jour automatique des extensions", "updateAll": "Mettre à jour toutes les extensions", "reloadAction": "Recharger", "postUpdateTooltip": "Recharger pour mettre à jour", @@ -44,6 +46,8 @@ "showWorkspaceRecommendedExtensions": "Afficher les extensions recommandées pour l'espace de travail", "showRecommendedKeymapExtensions": "Afficher les mappages de touches recommandés", "showRecommendedKeymapExtensionsShort": "Mappages de touches", + "showLanguageExtensions": "Afficher les extensions de langage", + "showLanguageExtensionsShort": "Extensions de langage", "configureWorkspaceRecommendedExtensions": "Configurer les extensions recommandées (espace de travail)", "ConfigureWorkspaceRecommendations.noWorkspace": "Les recommandations ne sont disponibles que pour un dossier d'espace de travail.", "OpenExtensionsFile.failed": "Impossible de créer le fichier 'extensions.json' dans le dossier '.vscode' ({0}).", @@ -51,5 +55,8 @@ "disableAll": "Désactiver toutes les extensions installées", "disableAllWorkspace": "Désactiver toutes les extensions installées pour cet espace de travail", "enableAll": "Activer toutes les extensions installées", - "enableAllWorkspace": "Activer toutes les extensions installées pour cet espace de travail" + "enableAllWorkspace": "Activer toutes les extensions installées pour cet espace de travail", + "extensionButtonProminentBackground": "Couleur d'arrière-plan du bouton pour les extension d'actions importantes (par ex., le bouton d'installation).", + "extensionButtonProminentForeground": "Couleur d'arrière-plan du bouton pour l'extension d'actions importantes (par ex., le bouton d'installation).", + "extensionButtonProminentHoverBackground": "Couleur d'arrière-plan du pointage de bouton pour l'extension d'actions importantes (par ex., le bouton d'installation)." } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json b/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json index c4a2f4bc59d..ba4825598d4 100644 --- a/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json @@ -9,6 +9,8 @@ "neverShowAgain": "Ne plus afficher", "close": "Fermer", "workspaceRecommended": "Cet espace de travail a des recommandations d'extension.", + "ignoreExtensionRecommendations": "Voulez-vous ignorer toutes les recommandations d'extension ?", + "ignoreAll": "Oui, ignorer tout", "no": "Non", "cancel": "Annuler" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json b/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json index 89edbc50c89..be819e14deb 100644 --- a/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json @@ -10,5 +10,6 @@ "extensions": "Extensions", "view": "Affichage", "extensionsConfigurationTitle": "Extensions", - "extensionsAutoUpdate": "Mettre à jour automatiquement les extensions" + "extensionsAutoUpdate": "Mettre à jour automatiquement les extensions", + "extensionsIgnoreRecommendations": "Ignorer les recommandations d'extension" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 8fa1a11d54a..3eea012e373 100644 --- a/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -4,8 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "disableOtherKeymapsConfirmation": "Désactiver les autres mappages de touches ({0}) pour éviter les conflits de combinaisons de touches ?", "yes": "Oui", "no": "Non", + "betterMergeDisabled": "L'extension Better Merge est désormais intégrée, l'extension installée est désactivée et peut être désinstallée.", "uninstall": "Désinstaller", "later": "Plus tard" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/fra/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 6f916235625..2416f91e4c1 100644 --- a/i18n/fra/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,6 +16,7 @@ "associations": "Configurez les associations entre les fichiers et les langages (par exemple, \"*.extension\": \"html\"). Celles-ci ont priorité sur les associations par défaut des langages installés.", "encoding": "Encodage du jeu de caractères par défaut à utiliser durant la lecture et l'écriture des fichiers.", "autoGuessEncoding": "Quand cette option est activée, tente de deviner l'encodage du jeu de caractères à l'ouverture des fichiers", + "eol": "Caractère de fin de ligne par défaut. Utilisez \\n pour LF et \\r\\n pour CRLF.", "trimTrailingWhitespace": "Si l'option est activée, l'espace blanc de fin est supprimé au moment de l'enregistrement d'un fichier.", "insertFinalNewline": "Quand l'option est activée, une nouvelle ligne finale est insérée à la fin du fichier au moment de son enregistrement.", "files.autoSave.off": "Un fichier dont l'intégrité est compromise n'est jamais enregistré automatiquement.", @@ -26,6 +27,7 @@ "autoSaveDelay": "Contrôle le délai en ms au bout duquel un fichier à l'intégrité compromise est enregistré automatiquement. S'applique uniquement quand 'files.autoSave' a la valeur '{0}'", "watcherExclude": "Configurez les modèles Glob des chemins de fichiers à exclure de la surveillance des fichiers. La modification de ce paramètre nécessite un redémarrage. Si vous constatez que le code consomme beaucoup de temps processeur au démarrage, excluez les dossiers volumineux pour réduire la charge initiale.", "hotExit.off": "Désactivez la sortie à chaud.", + "hotExit.onExit": "La sortie à chaud se déclenche à la fermeture de l'application, c'est-à-dire quand la dernière fenêtre est fermée dans Windows/Linux, ou quand la commande workbench.action.quit est déclenchée (palette de commandes, combinaison de touches, menu). Toutes les fenêtres avec des sauvegardes sont restaurées au prochain lancement.", "hotExit": "Contrôle si les fichiers non enregistrés sont mémorisés entre les sessions, ce qui permet d'ignorer la demande d'enregistrement à la sortie de l'éditeur.", "defaultLanguage": "Mode de langage par défaut affecté aux nouveaux fichiers.", "editorConfigurationTitle": "Éditeur", diff --git a/i18n/fra/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json b/i18n/fra/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json index 3b4a98a5b1a..3e9166e1c44 100644 --- a/i18n/fra/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json @@ -5,7 +5,5 @@ // Do not edit this file. It is machine generated. { "explorerSection": "Section de l'Explorateur de fichiers", - "noWorkspace": "Aucun dossier ouvert", - "noWorkspaceHelp": "Vous n'avez pas encore ouvert de dossier.", "openFolder": "Ouvrir le dossier" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json b/i18n/fra/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json index 049ecf726f0..edcca33816c 100644 --- a/i18n/fra/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json @@ -4,8 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "openEditosrSection": "Section des éditeurs ouverts", "openEditors": "Éditeurs ouverts", + "openEditosrSection": "Section des éditeurs ouverts", "treeAriaLabel": "Éditeurs ouverts : liste des fichiers actifs", "dirtyCounter": "{0} non enregistré(s)" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/fra/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index 56c9603dba7..13b60d7dd5c 100644 --- a/i18n/fra/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -9,5 +9,7 @@ "prof.message": "Création réussie des profils.", "prof.detail": "Créez un problème et joignez manuellement les fichiers suivants :\n{0}", "prof.restartAndFileIssue": "Créer le problème et redémarrer", - "prof.restart": "Redémarrer" + "prof.restart": "Redémarrer", + "prof.thanks": "Merci de votre aide.", + "prof.detail.restart": "Un redémarrage final est nécessaire pour continuer à utiliser '{0}'. Nous vous remercions une fois de plus pour votre contribution." } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/fra/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json index 0a1d06c06ef..0fa91c30616 100644 --- a/i18n/fra/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -5,5 +5,7 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.start": "Définir une combinaison de touches", - "defineKeybinding.kbLayoutErrorMessage": "Vous ne pouvez pas produire cette combinaison de touches avec la disposition actuelle du clavier." + "defineKeybinding.kbLayoutErrorMessage": "Vous ne pouvez pas produire cette combinaison de touches avec la disposition actuelle du clavier.", + "defineKeybinding.kbLayoutLocalAndUSMessage": "**{0}** pour votre disposition actuelle du clavier (**{1}** pour le clavier États-Unis standard).", + "defineKeybinding.kbLayoutLocalMessage": "**{0}** pour votre disposition actuelle du clavier." } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json b/i18n/fra/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json index 6d2534d7624..26f2edae5fe 100644 --- a/i18n/fra/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json @@ -4,6 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "errorInvalidConfiguration": "Impossible d'écrire les paramètres. Corrigez les erreurs/avertissements présents dans le fichier, puis réessayez.", "editTtile": "Modifier", "replaceDefaultValue": "Remplacer dans les paramètres", "copyDefaultValue": "Copier dans Paramètres", diff --git a/i18n/fra/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json b/i18n/fra/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json index 54c588725ce..261570184f1 100644 --- a/i18n/fra/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "showTriggerActions": "Afficher toutes les commandes", + "showCommands.label": "Palette de commandes...", "entryAriaLabelWithKey": "{0}, {1}, commandes", "entryAriaLabel": "{0}, commandes", "canNotRun": "La commande '{0}' ne peut pas être exécutée à partir d'ici.", diff --git a/i18n/fra/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json b/i18n/fra/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json new file mode 100644 index 00000000000..35b4553577f --- /dev/null +++ b/i18n/fra/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "relaunchMessage": "Un paramètre a changé et nécessite un redémarrage pour être appliqué.", + "relaunchDetail": "Appuyez sur le bouton de redémarrage pour redémarrer {0} et activer le paramètre.", + "restart": "Redémarrer" +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/fra/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json index 8b6ad71cd4e..3fe2c3e213d 100644 --- a/i18n/fra/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "editorGutterModifiedBackground": "Couleur d'arrière-plan de la reliure de l'éditeur pour les lignes modifiées.", + "editorGutterAddedBackground": "Couleur d'arrière-plan de la reliure de l'éditeur pour les lignes ajoutées.", + "editorGutterDeletedBackground": "Couleur d'arrière-plan de la reliure de l'éditeur pour les lignes supprimées." +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json b/i18n/fra/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json index 015c5898f64..50606f11e00 100644 --- a/i18n/fra/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "toggleGitViewlet": "Afficher Git", + "installAdditionalSCMProviders": "Installer des fournisseurs SCM supplémentaires...", "source control": "Contrôle de code source", "toggleSCMViewlet": "Afficher SCM", "view": "Afficher" diff --git a/i18n/fra/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json b/i18n/fra/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json index 28a54af77fa..90044a6bbbc 100644 --- a/i18n/fra/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "installAdditionalSCMProviders": "Installer des fournisseurs SCM supplémentaires...", "switch provider": "Changer de fournisseur GCL..." } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json b/i18n/fra/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json index b89dba6f17f..052e41c13ac 100644 --- a/i18n/fra/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json @@ -6,5 +6,7 @@ { "searchMatches": "{0} correspondances trouvées", "searchMatch": "{0} correspondance trouvée", - "fileMatchAriaLabel": "{0} correspondances dans le fichier {1} du dossier {2}, Résultat de la recherche" + "fileMatchAriaLabel": "{0} correspondances dans le fichier {1} du dossier {2}, Résultat de la recherche", + "replacePreviewResultAria": "Remplacer le terme {0} par {1} à la position de colonne {2} dans la ligne avec le texte {3}", + "searchResultAria": "Terme {0} trouvé à la position de colonne {1} dans la ligne avec le texte {2}" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json b/i18n/fra/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json index 379815030a8..ce5cfc94849 100644 --- a/i18n/fra/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json @@ -9,5 +9,6 @@ "vscode.extension.contributes.snippets-path": "Chemin du fichier d'extraits de code. Le chemin est relatif au dossier d'extensions et commence généralement par './snippets/'.", "invalid.language": "Langage inconnu dans 'contributes.{0}.language'. Valeur fournie : {1}", "invalid.path.0": "Chaîne attendue dans 'contributes.{0}.path'. Valeur fournie : {1}", - "invalid.path.1": "'contributes.{0}.path' ({1}) est censé être inclus dans le dossier ({2}) de l'extension. Cela risque de rendre l'extension non portable." + "invalid.path.1": "'contributes.{0}.path' ({1}) est censé être inclus dans le dossier ({2}) de l'extension. Cela risque de rendre l'extension non portable.", + "badVariableUse": "L'extrait de code \"{0}\" confond très probablement les variables et les espaces réservés d'extrait de code. Consultez https://code.visualstudio.com/docs/editor/userdefinedsnippets#_snippet-syntax pour plus d'informations." } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json b/i18n/fra/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json index 0b77278c938..af0ca524f41 100644 --- a/i18n/fra/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json @@ -11,6 +11,6 @@ "snippetSchema.json.default": "Extrait de code vide", "snippetSchema.json": "Configuration de l'extrait de code utilisateur", "snippetSchema.json.prefix": "Préfixe à utiliser durant la sélection de l'extrait de code dans IntelliSense", - "snippetSchema.json.body": "Contenu de l'extrait de code. Utilisez '${id}', '${id:label}', '${1:label}' pour les variables, et '$0', '$1' pour les positions du curseur", + "snippetSchema.json.body": "Contenu de l'extrait de code. Utilisez '$1', '${1:defaultText}' pour définir les positions du curseur, utilisez '$0' pour la position finale du curseur. Insérez les valeurs de variable avec '${varName}' et '${varName:defaultText}', par ex., 'Il s'agit du fichier : $TM_FILENAME'.", "snippetSchema.json.description": "Description de l'extrait de code." } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json b/i18n/fra/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json new file mode 100644 index 00000000000..b68d1b3bcbb --- /dev/null +++ b/i18n/fra/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "helpUs": "Aidez-nous à améliorer le support de {0}", + "takeShortSurvey": "Répondre à une enquête rapide", + "remindLater": "Me le rappeler plus tard", + "neverAgain": "Ne plus afficher" +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json b/i18n/fra/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json new file mode 100644 index 00000000000..18c8f1427ff --- /dev/null +++ b/i18n/fra/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "surveyQuestion": "Acceptez-vous de répondre à une enquête rapide ?", + "takeSurvey": "Répondre à l'enquête", + "remindLater": "Me le rappeler plus tard", + "neverAgain": "Ne plus afficher" +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json b/i18n/fra/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json new file mode 100644 index 00000000000..c4f5420f096 --- /dev/null +++ b/i18n/fra/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noTasksMatching": "Aucune tâche correspondante" +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/fra/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index c0432625724..34aab6d5ccf 100644 --- a/i18n/fra/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0}, tasks" + "entryAriaLabel": "{0}, tasks", + "customizeTask": "Personnaliser la tâche" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json b/i18n/fra/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json new file mode 100644 index 00000000000..c4f5420f096 --- /dev/null +++ b/i18n/fra/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noTasksMatching": "Aucune tâche correspondante" +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/fra/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json index 5c565fd6389..cfdcd7341c0 100644 --- a/i18n/fra/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -12,5 +12,6 @@ "ConfigurationParser.invalidVaraibleReference": "Erreur : référence à problemMatcher non valide : {0}\n", "ConfigurationParser.noTaskName": "Erreur : les tâches doivent fournir une propriété taskName. La tâche va être ignorée.\n{0}\n", "taskConfiguration.shellArgs": "Avertissement : La tâche '{0}' est une commande d'interpréteur de commandes, et le nom de la commande ou l'un de ses arguments contient des espaces non précédés d'un caractère d'échappement. Pour garantir une ligne de commande correcte, fusionnez les arguments dans la commande.", + "taskConfiguration.noCommandOrDependsOn": "Erreur : La tâche '{0}' ne spécifie ni une commande, ni une propriété dependsOn. La tâche est ignorée. Sa définition est :\n{1}", "taskConfiguration.noCommand": "Erreur : La tâche '{0}' ne définit aucune commande. La tâche va être ignorée. Sa définition est :\n{1}" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json b/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json index f9b47cd0ac4..4a1e27d2714 100644 --- a/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json @@ -7,6 +7,7 @@ "JsonSchema.options": "Options de commande supplémentaires", "JsonSchema.options.cwd": "Répertoire de travail actif du programme ou script exécuté. En cas d'omission, la racine de l'espace de travail actif de Code est utilisée.", "JsonSchema.options.env": "Environnement du programme ou de l'interpréteur de commandes exécuté. En cas d'omission, l'environnement du processus parent est utilisé.", + "JsonSchema.shellConfiguration": "Configure l'interpréteur de commandes à utiliser.", "JsonSchema.shell.executable": "Interpréteur de commandes à utiliser.", "JsonSchema.shell.args": "Arguments de l'interpréteur de commandes.", "JsonSchema.command": "Commande à exécuter. Il peut s'agir d'un programme externe ou d'une commande d'interpréteur de commandes.", diff --git a/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json b/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json index c2cb490358e..d125a6f5534 100644 --- a/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json @@ -5,6 +5,8 @@ // Do not edit this file. It is machine generated. { "JsonSchema.version": "Numéro de version de la configuration", + "JsonSchema._runner": "Le runner est dégradé. Utiliser la propriété runner officielle", + "JsonSchema.runner": "Définit si la tâche est exécutée sous forme de processus, et si la sortie s'affiche dans la fenêtre de sortie ou dans le terminal.", "JsonSchema.windows": "Configuration de commande spécifique à Windows", "JsonSchema.mac": "Configuration de commande spécifique à Mac", "JsonSchema.linux": "Configuration de commande spécifique à Linux", diff --git a/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json index c95ac82e6a8..7df99994e18 100644 --- a/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -7,6 +7,10 @@ "JsonSchema.shell": "Spécifie si la commande est une commande d'interpréteur de commandes ou un programme externe. La valeur par défaut est false, en cas d'omission.", "JsonSchema.tasks.dependsOn.string": "Autre tâche dont cette tâche dépend.", "JsonSchema.tasks.dependsOn.array": "Autres tâches dont cette tâche dépend.", + "JsonSchema.tasks.group": "Définit le groupe d'exécution auquel la tâche appartient. En cas d'omission, la tâche n'appartient à aucun groupe.", + "JsonSchema.tasks.type": "Définit si la tâche est exécutée sous forme de processus ou d'une commande d'un interpréteur de commandes. La valeur par défaut est un processus.", + "JsonSchema.version": "Numéro de version de la configuration.", + "JsonSchema.tasks.customize": "Tâche ajoutée à personnaliser.", "JsonSchema.windows": "Configuration de commande spécifique à Windows", "JsonSchema.mac": "Configuration de commande spécifique à Mac", "JsonSchema.linux": "Configuration de commande spécifique à Linux" diff --git a/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json b/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json index e59f5fcb09a..f406beb28c8 100644 --- a/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json @@ -18,10 +18,12 @@ "problems": "Problèmes", "manyMarkers": "99", "tasks": "Tâches", + "TaskSystem.noHotSwap": "Le changement du moteur d'exécution de tâches nécessite le redémarrage de VS Code. Changement ignoré.", "TaskService.noBuildTask": "Aucune tâche de build définie. Marquez une tâche avec 'isBuildCommand' dans le fichier tasks.json.", "TaskService.noTestTask": "Aucune tâche de test définie. Marquez une tâche avec 'isTestCommand' dans le fichier tasks.json.", "TaskServer.noTask": "La tâche {0} à exécuter est introuvable.", - "TaskSystem.activeSame": "La tâche est déjà active et en mode espion. Pour terminer la tâche, utilisez 'F1 > terminer la tâche'", + "customizeParseErrors": "La configuration de tâche actuelle contient des erreurs. Corrigez-les avant de personnaliser une tâche. ", + "moreThanOneBuildTask": "De nombreuses tâches de génération sont définies dans le fichier tasks.json. Exécution de la première.\n", "TaskSystem.active": "Une tâche est déjà en cours d'exécution. Terminez-la avant d'exécuter une autre tâche.", "TaskSystem.restartFailed": "Échec de la fin de l'exécution de la tâche {0}", "TaskSystem.configurationErrors": "Erreur : la configuration de tâche fournie comporte des erreurs de validation et ne peut pas être utilisée. Corrigez d'abord les erreurs.", diff --git a/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json b/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json index 32ff4c480d3..413680671bf 100644 --- a/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json @@ -6,5 +6,7 @@ { "TerminalTaskSystem.unknownError": "Une erreur inconnue s'est produite durant l'exécution d'une tâche. Pour plus d'informations, consultez le journal de sortie des tâches.", "TerminalTaskSystem.terminalName": "Tâche - {0}", - "TerminalTaskSystem": "Impossible d'exécuter une commande d'interpréteur de commandes sur un lecteur UNC." + "reuseTerminal": "Le terminal sera réutilisé par les tâches, appuyez sur une touche pour le fermer.", + "TerminalTaskSystem": "Impossible d'exécuter une commande d'interpréteur de commandes sur un lecteur UNC.", + "unkownProblemMatcher": "Impossible de résoudre le détecteur de problèmes {0}. Le détecteur est ignoré" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json b/i18n/fra/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json index a2ea447d105..50a09307783 100644 --- a/i18n/fra/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json @@ -7,5 +7,6 @@ "TaskRunnerSystem.unknownError": "Une erreur inconnue s'est produite durant l'exécution d'une tâche. Pour plus d'informations, consultez le journal de sortie des tâches.", "TaskRunnerSystem.watchingBuildTaskFinished": "\nFin du suivi des tâches de génération.", "TaskRunnerSystem.childProcessError": "Failed to launch external program {0} {1}.", - "TaskRunnerSystem.cancelRequested": "\nThe task '{0}' was terminated per user request." + "TaskRunnerSystem.cancelRequested": "\nThe task '{0}' was terminated per user request.", + "unkownProblemMatcher": "Impossible de résoudre le détecteur de problèmes {0}. Le détecteur est ignoré" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json b/i18n/fra/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json index fdfee189e15..b2f5634cfe8 100644 --- a/i18n/fra/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json @@ -8,6 +8,7 @@ "workbench.action.terminal.kill": "Tuer l'instance active du terminal", "workbench.action.terminal.kill.short": "Tuer le terminal", "workbench.action.terminal.copySelection": "Copier la sélection", + "workbench.action.terminal.selectAll": "Tout Sélectionner", "workbench.action.terminal.new": "Créer un terminal intégré", "workbench.action.terminal.new.short": "Nouveau terminal", "workbench.action.terminal.focus": "Focus sur le terminal", @@ -26,5 +27,8 @@ "workbench.action.terminal.scrollUp": "Faire défiler vers le haut (ligne)", "workbench.action.terminal.scrollUpPage": "Faire défiler vers le haut (page)", "workbench.action.terminal.scrollToTop": "Faire défiler jusqu'en haut", - "workbench.action.terminal.clear": "Effacer" + "workbench.action.terminal.clear": "Effacer", + "workbench.action.terminal.allowWorkspaceShell": "Autoriser la configuration de l'interpréteur de commandes de l'espace de travail", + "workbench.action.terminal.disallowWorkspaceShell": "Interdire la configuration de l'interpréteur de commandes de l'espace de travail", + "workbench.action.terminal.rename": "Renommer" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json b/i18n/fra/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json index 24d7761697e..2a639927b49 100644 --- a/i18n/fra/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json @@ -4,5 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "terminal.background": "Couleur d'arrière-plan du terminal, permet d'appliquer au terminal une couleur différente de celle du panneau.", + "terminal.foreground": "Couleur de premier plan du terminal.", "terminal.ansiColor": "Couleur ansi '{0}' dans le terminal." } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json b/i18n/fra/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json new file mode 100644 index 00000000000..6183484b59c --- /dev/null +++ b/i18n/fra/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "label.find": "Rechercher", + "placeholder.find": "Rechercher", + "label.previousMatchButton": "Correspondance précédente", + "label.nextMatchButton": "Correspondance suivante", + "label.closeButton": "Fermer" +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json b/i18n/fra/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json index e783aa11ec0..1129e824638 100644 --- a/i18n/fra/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json @@ -4,7 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "terminal.integrated.copySelection.noSelection": "Impossible de copier la sélection du terminal quand il n'a pas le focus", "terminal.integrated.exitedWithCode": "Le processus du terminal s'est achevé avec le code de sortie {0}", "terminal.integrated.waitOnExit": "Appuyez sur une touche pour fermer le terminal", "terminal.integrated.launchFailed": "Échec du lancement de la commande de traitement du terminal '{0}{1}' (code de sortie : {2})" diff --git a/i18n/fra/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json b/i18n/fra/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json index 515d4f6f9c5..ae4ba496061 100644 --- a/i18n/fra/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json @@ -6,6 +6,7 @@ { "selectTheme.label": "Thème de couleur", "installColorThemes": "Installer des thèmes de couleurs supplémentaires...", + "themes.selectTheme": "Sélectionner un thème de couleur (flèches bas/haut pour afficher l'aperçu)", "selectIconTheme.label": "Thème d'icône de fichier", "installIconThemes": "Installer des thèmes d'icônes de fichiers supplémentaires...", "noIconThemeLabel": "Aucun", diff --git a/i18n/fra/src/vs/workbench/parts/update/electron-browser/update.i18n.json b/i18n/fra/src/vs/workbench/parts/update/electron-browser/update.i18n.json index 641b395e494..9f0475f53b4 100644 --- a/i18n/fra/src/vs/workbench/parts/update/electron-browser/update.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/update/electron-browser/update.i18n.json @@ -15,5 +15,18 @@ "license": "Lire la licence", "updateAvailable": "{0} sera mis à jour après avoir redémarré.", "thereIsUpdateAvailable": "Une mise à jour est disponible.", - "noUpdatesAvailable": "Aucune mise à jour n'est disponible actuellement." + "noUpdatesAvailable": "Aucune mise à jour n'est disponible actuellement.", + "updateIsReady": "Nouvelle mise à jour disponible.", + "commandPalette": "Palette de commandes...", + "settings": "Paramètres", + "keyboardShortcuts": "Raccourcis clavier", + "selectTheme.label": "Thème de couleur", + "themes.selectIconTheme.label": "Thème d'icône de fichier", + "not available": "Mises à jour non disponibles", + "checkingForUpdates": "Recherche des mises à jour...", + "DownloadUpdate": "Télécharger la mise à jour disponible", + "DownloadingUpdate": "Téléchargement de la mise à jour...", + "InstallingUpdate": "Installation de la mise à jour...", + "restartToUpdate": "Redémarrer pour mettre à jour...", + "checkForUpdates": "Rechercher les mises à jour..." } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/views/browser/views.i18n.json b/i18n/fra/src/vs/workbench/parts/views/browser/views.i18n.json new file mode 100644 index 00000000000..4868e0b0e11 --- /dev/null +++ b/i18n/fra/src/vs/workbench/parts/views/browser/views.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "viewToolbarAriaLabel": "{0} actions" +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json b/i18n/fra/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json new file mode 100644 index 00000000000..792b28b2682 --- /dev/null +++ b/i18n/fra/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "requirearray": "les vues doivent figurer dans un tableau", + "requirestring": "la propriété '{0}' est obligatoire et doit être de type 'string'", + "optstring": "La propriété '{0}' peut être omise ou doit être de type 'string'", + "vscode.extension.contributes.view.id": "Identificateur de la vue. Utilisez-le pour inscrire un fournisseur de données au moyen de l'API 'vscode.window.registerTreeDataProviderForView', ainsi que pour déclencher l'activation de votre extension en inscrivant l'événement 'onView:${id}' dans 'activationEvents'.", + "vscode.extension.contributes.view.name": "Nom de la vue, contrôlable de visu. Affiché", + "vscode.extension.contributes.views": "Ajoute des vues à l'éditeur", + "views.explorer": "Mode Explorateur", + "locationId.invalid": "'{0}' n'est pas un emplacement de vue valide" +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/fra/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json index 88d26394dcf..97f83a61230 100644 --- a/i18n/fra/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -11,20 +11,26 @@ "welcomePage.openFolder": "Ouvrir un dossier...", "welcomePage.cloneGitRepository": "Cloner le dépôt Git...", "welcomePage.recent": "Récent", + "welcomePage.moreRecent": "Plus...", "welcomePage.noRecentFolders": "Aucun dossier récent", "welcomePage.help": "Aide", + "welcomePage.keybindingsCheatsheet": "Fiche de révision du clavier imprimable", "welcomePage.introductoryVideos": "Vidéos d'introduction", "welcomePage.productDocumentation": "Documentation du produit", "welcomePage.gitHubRepository": "Dépôt GitHub", "welcomePage.stackOverflow": "Stack Overflow", "welcomePage.showOnStartup": "Afficher la page d'accueil au démarrage", "welcomePage.customize": "Personnaliser", + "welcomePage.installExtensionPacks": "Outils et langages", + "welcomePage.installExtensionPacksDescription": "Installer un support pour {0} et {1}", + "welcomePage.moreExtensions": "plus", "welcomePage.installKeymapDescription": "Installer les raccourcis clavier", + "welcomePage.installKeymapExtension": "Installer les raccourcis clavier de {0} et {1}", "welcomePage.others": "autres", "welcomePage.colorTheme": "Thème de couleur", "welcomePage.colorThemeDescription": "Personnalisez l'apparence de l'éditeur et de votre code", + "welcomePage.learn": "Apprendre", "welcomePage.showCommands": "Rechercher et exécuter toutes les commandes", - "welcomePage.showCommandsDescription": "Utilisez et recherchez rapidement des commandes dans le Panneau de configuration ({0})", "welcomePage.interfaceOverview": "Vue d'ensemble de l'interface", "welcomePage.interfaceOverviewDescription": "Obtenez une superposition visuelle mettant en évidence les principaux composants de l'IU", "welcomePage.interactivePlayground": "Terrain de jeu interactif", diff --git a/i18n/fra/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json b/i18n/fra/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json index 8cf53ce388e..b3c44c1bab1 100644 --- a/i18n/fra/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json @@ -4,7 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "workbenchConfigurationTitle": "Banc d'essai", - "welcomePage.enabled": "Quand cette option est activée, la page de bienvenue s'affiche au démarrage.", "help": "Aide" } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/fra/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 66bb9f2ab66..9f2d8bfccaf 100644 --- a/i18n/fra/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -4,17 +4,35 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "workbenchConfigurationTitle": "Banc d'essai", + "welcomePage.enabled": "Quand cette option est activée, la page de bienvenue s'affiche au démarrage.", "welcomePage": "Bienvenue", + "welcomePage.javaScript": "JavaScript", "welcomePage.typeScript": "TypeScript", + "welcomePage.python": "Python", "welcomePage.php": "PHP", + "welcomePage.docker": "Docker", "welcomePage.vim": "Vim", "welcomePage.sublime": "Sublime", "welcomePage.atom": "Atom", + "welcomePage.extensionPackAlreadyInstalled": "Le support pour {0} est déjà installé.", + "welcomePage.willReloadAfterInstallingExtensionPack": "La fenêtre se recharge après l'installation d'un support supplémentaire pour {0}.", + "welcomePage.installingExtensionPack": "Installation d'un support supplémentaire pour {0}...", + "welcomePage.extensionPackNotFound": "Le support pour {0} avec l'ID {1} est introuvable.", "welcomePage.keymapAlreadyInstalled": "Les raccourcis clavier {0} sont déjà installés.", "welcomePage.willReloadAfterInstallingKeymap": "La fenêtre se recharge après l'installation des raccourcis clavier {0}.", "welcomePage.installingKeymap": "Installation des raccourcis clavier de {0}...", "welcomePage.keymapNotFound": "Les raccourcis clavier {0} ayant l'ID {1} sont introuvables.", "welcome.title": "Bienvenue", + "welcomePage.openFolderWithPath": "Ouvrir le dossier {0} avec le chemin {1}", + "welcomePage.extensionListSeparator": ", ", + "welcomePage.installKeymap": "Installer le mappage de touches {0}", + "welcomePage.installExtensionPack": "Installer un support supplémentaire pour {0} ", + "welcomePage.installedKeymap": "Le mappage de touches '{0}' est déjà installé", + "welcomePage.installedExtensionPack": "Le support {0} est déjà installé.", "ok": "OK", - "cancel": "Annuler" + "details": "Détails", + "cancel": "Annuler", + "welcomePage.buttonBackground": "Couleur d'arrière-plan des boutons de la page d'accueil.", + "welcomePage.buttonHoverBackground": "Couleur d'arrière-plan du pointage des boutons de la page d'accueil." } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json b/i18n/fra/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json index a27dad756b1..4fd64e5f282 100644 --- a/i18n/fra/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json +++ b/i18n/fra/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json @@ -5,5 +5,6 @@ // Do not edit this file. It is machine generated. { "walkThrough.unboundCommand": "indépendant", - "walkThrough.gitNotFound": "Git semble ne pas être installé sur votre système." + "walkThrough.gitNotFound": "Git semble ne pas être installé sur votre système.", + "walkThrough.embeddedEditorBackground": "Couleur d'arrière-plan des éditeurs incorporés dans le terrain de jeu interactif." } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json b/i18n/fra/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json index 8c86edbfa40..1e0860c2647 100644 --- a/i18n/fra/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json +++ b/i18n/fra/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json @@ -6,6 +6,12 @@ { "open": "Ouvrir les paramètres", "close": "Fermer", + "saveAndRetry": "Enregistrer les paramètres et recommencer", "errorUnknownKey": "Impossible d'écrire dans le fichier de configuration (clé inconnue)", - "errorInvalidTarget": "Impossible d'écrire dans le fichier config (cible non valide)" + "errorInvalidTarget": "Impossible d'écrire dans le fichier config (cible non valide)", + "errorNoWorkspaceOpened": "Impossible d'écrire les paramètres, car aucun dossier n'est ouvert. Ouvrez d'abord un dossier, puis réessayez.", + "errorInvalidConfiguration": "Impossible d'écrire les paramètres. Ouvrez les **Paramètres utilisateur** pour corriger les erreurs/avertissements présents dans le fichier, puis réessayez.", + "errorInvalidConfigurationWorkspace": "Impossible d'écrire les paramètres. Ouvrez les **Paramètres d'espace de travail** pour corriger les erreurs/avertissements présents dans le fichier, puis réessayez.", + "errorConfigurationFileDirty": "Impossible d'écrire les paramètres, car l'intégrité du fichier est compromise. Enregistrez le fichier des **Paramètres utilisateur**, puis réessayez.", + "errorConfigurationFileDirtyWorkspace": "Impossible d'écrire les paramètres, car l'intégrité du fichier est compromise. Enregistrez le fichier des **Paramètres d'espace de travail**, puis réessayez." } \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json b/i18n/fra/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json new file mode 100644 index 00000000000..42bafb09091 --- /dev/null +++ b/i18n/fra/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "telemetryConfigurationTitle": "Télémétrie", + "telemetry.enableCrashReporting": "Activez l'envoi de rapports d'incidents à Microsoft.\nCette option nécessite un redémarrage pour être prise en compte." +} \ No newline at end of file diff --git a/i18n/fra/src/vs/workbench/services/progress/browser/progressService2.i18n.json b/i18n/fra/src/vs/workbench/services/progress/browser/progressService2.i18n.json new file mode 100644 index 00000000000..541b82ff55a --- /dev/null +++ b/i18n/fra/src/vs/workbench/services/progress/browser/progressService2.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "progress.text": "{0} - {1}", + "progress.title": "{0} : {1}" +} \ No newline at end of file diff --git a/i18n/hun/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json b/i18n/hun/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json new file mode 100644 index 00000000000..7521c58758c --- /dev/null +++ b/i18n/hun/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json @@ -0,0 +1,36 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "activeEditorShort": "pl.: myFile.txt", + "activeEditorMedium": "pl.: myFolder/myFile.txt", + "activeEditorLong": "pl.: /Users/Development/myProject/myFolder/myFile.txt", + "rootName": "pl.: myProject", + "rootPath": "pl.: /Users/Development/myProject", + "appName": "pl.: VS Code", + "dirty": "módosításjelzÅ‘, ami akkor jelenik meg, ha az aktív szerkesztÅ‘ablak tartalma módosítva lett", + "separator": "egy feltételes elválasztó (' - '), ami akkor jelenik meg, ha olyan változókkal van körülvéve, amelyeknek van értéke", + "assocLabelFile": "Fájlok kiterjesztésekkel", + "assocDescriptionFile": "A megadott azonosítójú nyelvhez tartozó glob mintának megfelelÅ‘ fájlok feltérképezése.", + "assocLabelPath": "Fájlok elérési úttal", + "assocDescriptionPath": "A megadott azonosítójú nyelvhez tartozó abszolút elérési utas glob mintának megfelelÅ‘ fájlok feltérképezése.", + "fileLabel": "Fájlok kiterjesztés szerint", + "fileDescription": "Adott kiterjesztéssel rendelkezÅ‘ fájlok keresése.", + "filesLabel": "Fájlok több kiterjesztés szerint", + "filesDescription": "A megadott kiterjesztések bármelyikével rendelkezÅ‘ fájlok keresése.", + "derivedLabel": "Testvérekkel rendelkezÅ‘ fájlok név szerint", + "derivedDescription": "Olyan fájlok keresése, amelyek azonos nevű, de különbözÅ‘ kiterjesztésű testvérekkel rendelkeznek.", + "topFolderLabel": "Mappák név szerint (legfelsÅ‘ szinten)", + "topFolderDescription": "Adott névvel rendelkezÅ‘, legfelsÅ‘ szintű mappák keresése", + "topFoldersLabel": "Fájlok több név szerint (legfelsÅ‘ szinten)", + "topFoldersDescription": "Több legfelsÅ‘ szintű mappa keresése.", + "folderLabel": "Mappa név szerint (bármely helyen)", + "folderDescription": "Adott névvel rendelkezÅ‘ mappa keresése helytÅ‘l függetlenül.", + "falseDescription": "A minta letiltása.", + "trueDescription": "A minta engedélyezése.", + "siblingsDescription": "Olyan fájlok keresése, amelyek azonos nevű, de különbözÅ‘ kiterjesztésű testvérekkel rendelkeznek.", + "languageSpecificEditorSettings": "Nyelvspecifikus szerkesztÅ‘beállítások", + "languageSpecificEditorSettingsDescription": "A szerkesztÅ‘ beállításainak felülírása az adott nyelvre vonatkozóan" +} \ No newline at end of file diff --git a/i18n/hun/extensions/css/client/out/cssMain.i18n.json b/i18n/hun/extensions/css/client/out/cssMain.i18n.json new file mode 100644 index 00000000000..ded2c0dd476 --- /dev/null +++ b/i18n/hun/extensions/css/client/out/cssMain.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "cssserver.name": "CSS nyelvi szerver" +} \ No newline at end of file diff --git a/i18n/hun/extensions/css/package.i18n.json b/i18n/hun/extensions/css/package.i18n.json new file mode 100644 index 00000000000..5f6b8a4014b --- /dev/null +++ b/i18n/hun/extensions/css/package.i18n.json @@ -0,0 +1,67 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "css.lint.argumentsInColorFunction.desc": "Nem megfelelÅ‘ számú paraméter", + "css.lint.boxModel.desc": "A width és a height tulajdonság kerülése a padding és a border tulajdonság használata esetén", + "css.lint.compatibleVendorPrefixes.desc": "Gyártóspecifikus elÅ‘tag használata esetén minden más gyártóspecifikus tulajdonságot is meg kell adni", + "css.lint.duplicateProperties.desc": "Duplikált stílusdefiníciók kerülése", + "css.lint.emptyRules.desc": "Ãœres szabályhalmazok kerülése", + "css.lint.float.desc": "A float tulajdonságérték kerülése, mivel könnyen váratlan eredményt idézhet elÅ‘ az elrendezés változásakor.", + "css.lint.fontFaceProperties.desc": "A @font-face szabályokban az src és a font-family tulajdonságot is definiálni kell", + "css.lint.hexColorLength.desc": "A hexadecimális formában megadott színeknek három vagy hat hexadecimális számjegybÅ‘l kell állniuk", + "css.lint.idSelector.desc": "A szelektorok nem tartalmazhatnak azonosítókat, mivel az ilyen szabályok túl szorosan kötÅ‘dnek a HTML-hez.", + "css.lint.ieHack.desc": "Az IE hangolása csak az IE7 vagy régebbi verziók támogatása esetén szükséges", + "css.lint.important.desc": "Az !important attribútum mellÅ‘zése. Az attribútum jelenléte arra utal, hogy a CSS-struktúra átláthatatlanná vált, és refaktorálásra szorul.", + "css.lint.importStatement.desc": "Ne töltÅ‘djenek párhuzamosan az importálási utasítások", + "css.lint.propertyIgnoredDueToDisplay.desc": "A megjelenítési mód miatt a megjelenítÅ‘komponensek nem fogják figyelembe venni a tulajdonságot. Ha például a display tulajdonság értéke inline, akkor a megjelenítÅ‘k figyelmen kívül hagyják a width, a height, a margin-top, a margin-bottom és a float tulajdonságot.", + "css.lint.universalSelector.desc": "Az univerzális szelektor (*) lassú működést eredményez", + "css.lint.unknownProperties.desc": "Ismeretlen tulajdonság.", + "css.lint.unknownVendorSpecificProperties.desc": "Ismeretlen gyártóspecifikus tulajdonság.", + "css.lint.vendorPrefix.desc": "Gyártóspecifikus elÅ‘tagok használata esetén az adott tulajdonság szabványos változatát is meg kell adni", + "css.lint.zeroUnits.desc": "A 0 értékhez nem szükséges mértékegység", + "css.validate.desc": "Összes validálás engedélyezése vagy letiltása", + "less.lint.argumentsInColorFunction.desc": "Nem megfelelÅ‘ számú paraméter", + "less.lint.boxModel.desc": "A width és a height tulajdonság kerülése a padding és a border tulajdonság használata esetén", + "less.lint.compatibleVendorPrefixes.desc": "Gyártóspecifikus elÅ‘tag használata esetén minden más gyártóspecifikus tulajdonságot is meg kell adni", + "less.lint.duplicateProperties.desc": "Duplikált stílusdefiníciók kerülése", + "less.lint.emptyRules.desc": "Ãœres szabályhalmazok kerülése", + "less.lint.float.desc": "A float tulajdonságérték kerülése, mivel könnyen váratlan eredményt idézhet elÅ‘ az elrendezés változásakor.", + "less.lint.fontFaceProperties.desc": "A @font-face szabályokban az src és a font-family tulajdonságot is definiálni kell", + "less.lint.hexColorLength.desc": "A hexadecimális formában megadott színeknek három vagy hat hexadecimális számjegybÅ‘l kell állniuk", + "less.lint.idSelector.desc": "A szelektorok nem tartalmazhatnak azonosítókat, mivel az ilyen szabályok túl szorosan kötÅ‘dnek a HTML-hez.", + "less.lint.ieHack.desc": "Az IE hangolása csak az IE7 vagy régebbi verziók támogatása esetén szükséges", + "less.lint.important.desc": "Az !important attribútum mellÅ‘zése. Az attribútum jelenléte arra utal, hogy a CSS-struktúra átláthatatlanná vált, és refaktorálásra szorul.", + "less.lint.importStatement.desc": "Ne töltÅ‘djenek párhuzamosan az importálási utasítások", + "less.lint.propertyIgnoredDueToDisplay.desc": "A megjelenítési mód miatt a megjelenítÅ‘komponensek nem fogják figyelembe venni a tulajdonságot. Ha például a display tulajdonság értéke inline, akkor a megjelenítÅ‘k figyelmen kívül hagyják a width, a height, a margin-top, a margin-bottom és a float tulajdonságot.", + "less.lint.universalSelector.desc": "Az univerzális szelektor (*) lassú működést eredményez", + "less.lint.unknownProperties.desc": "Ismeretlen tulajdonság.", + "less.lint.unknownVendorSpecificProperties.desc": "Ismeretlen gyártóspecifikus tulajdonság.", + "less.lint.vendorPrefix.desc": "Gyártóspecifikus elÅ‘tagok használata esetén az adott tulajdonság szabványos változatát is meg kell adni", + "less.lint.zeroUnits.desc": "A 0 értékhez nem szükséges mértékegység", + "less.validate.desc": "Összes validálás engedélyezése vagy letiltása", + "scss.lint.argumentsInColorFunction.desc": "Nem megfelelÅ‘ számú paraméter", + "scss.lint.boxModel.desc": "A width és a height tulajdonság kerülése a padding és a border tulajdonság használata esetén", + "scss.lint.compatibleVendorPrefixes.desc": "Gyártóspecifikus elÅ‘tag használata esetén minden más gyártóspecifikus tulajdonságot is meg kell adni", + "scss.lint.duplicateProperties.desc": "Duplikált stílusdefiníciók kerülése", + "scss.lint.emptyRules.desc": "Ãœres szabályhalmazok kerülése", + "scss.lint.float.desc": "A float tulajdonságérték kerülése, mivel könnyen váratlan eredményt idézhet elÅ‘ az elrendezés változásakor.", + "scss.lint.fontFaceProperties.desc": "A @font-face szabályokban az src és a font-family tulajdonságot is definiálni kell", + "scss.lint.hexColorLength.desc": "A hexadecimális formában megadott színeknek három vagy hat hexadecimális számjegybÅ‘l kell állniuk", + "scss.lint.idSelector.desc": "A szelektorok nem tartalmazhatnak azonosítókat, mivel az ilyen szabályok túl szorosan kötÅ‘dnek a HTML-hez.", + "scss.lint.ieHack.desc": "Az IE hangolása csak az IE7 vagy régebbi verziók támogatása esetén szükséges", + "scss.lint.important.desc": "Az !important attribútum mellÅ‘zése. Az attribútum jelenléte arra utal, hogy a CSS-struktúra átláthatatlanná vált, és refaktorálásra szorul.", + "scss.lint.importStatement.desc": "Ne töltÅ‘djenek párhuzamosan az importálási utasítások", + "scss.lint.propertyIgnoredDueToDisplay.desc": "A megjelenítési mód miatt a megjelenítÅ‘komponensek nem fogják figyelembe venni a tulajdonságot. Ha például a display tulajdonság értéke inline, akkor a megjelenítÅ‘k figyelmen kívül hagyják a width, a height, a margin-top, a margin-bottom és a float tulajdonságot.", + "scss.lint.universalSelector.desc": "Az univerzális szelektor (*) lassú működést eredményez", + "scss.lint.unknownProperties.desc": "Ismeretlen tulajdonság.", + "scss.lint.unknownVendorSpecificProperties.desc": "Ismeretlen gyártóspecifikus tulajdonság.", + "scss.lint.vendorPrefix.desc": "Gyártóspecifikus elÅ‘tagok használata esetén az adott tulajdonság szabványos változatát is meg kell adni", + "scss.lint.zeroUnits.desc": "A 0 értékhez nem szükséges mértékegység", + "scss.validate.desc": "Összes validálás engedélyezése vagy letiltása", + "less.colorDecorators.enable.desc": "Színdekorátorok engedélyezése vagy letiltása", + "scss.colorDecorators.enable.desc": "Színdekorátorok engedélyezése vagy letiltása", + "css.colorDecorators.enable.desc": "Színdekorátorok engedélyezése vagy letiltása" +} \ No newline at end of file diff --git a/i18n/hun/extensions/extension-editing/out/packageDocumentHelper.i18n.json b/i18n/hun/extensions/extension-editing/out/packageDocumentHelper.i18n.json new file mode 100644 index 00000000000..12ff7e4eb5a --- /dev/null +++ b/i18n/hun/extensions/extension-editing/out/packageDocumentHelper.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "languageSpecificEditorSettings": "Nyelvspecifikus szerkesztÅ‘beállítások", + "languageSpecificEditorSettingsDescription": "A szerkesztÅ‘ beállításainak felülírása az adott nyelvre vonatkozóan" +} \ No newline at end of file diff --git a/i18n/hun/extensions/git/out/askpass-main.i18n.json b/i18n/hun/extensions/git/out/askpass-main.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/hun/extensions/git/out/askpass-main.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/hun/extensions/git/out/commands.i18n.json b/i18n/hun/extensions/git/out/commands.i18n.json new file mode 100644 index 00000000000..2459ab031bd --- /dev/null +++ b/i18n/hun/extensions/git/out/commands.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tag at": "Címke, a következÅ‘re mutat: {0}", + "remote branch at": "Távoli ág, a következÅ‘re mutat: {0}", + "repourl": "Forráskódtár URL-címe", + "yes": "Igen", + "always": "Mindig", + "commit message": "Beadási üzenet", + "pick remote": "Válassza ki a távoli szervert, ahová publikálni szeretné a(z) '{0}' ágat:", + "sync is unpredictable": "Ez a művelet pusholja és pullozza a commitokat a következÅ‘ helyrÅ‘l: '{0}'.", + "ok": "OK", + "never again": "Rendben, ne jelenítse meg újra" +} \ No newline at end of file diff --git a/i18n/hun/extensions/git/out/main.i18n.json b/i18n/hun/extensions/git/out/main.i18n.json new file mode 100644 index 00000000000..024c38affd0 --- /dev/null +++ b/i18n/hun/extensions/git/out/main.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "neverShowAgain": "Ne jelenítse meg újra" +} \ No newline at end of file diff --git a/i18n/hun/extensions/git/out/model.i18n.json b/i18n/hun/extensions/git/out/model.i18n.json new file mode 100644 index 00000000000..7dece8191bd --- /dev/null +++ b/i18n/hun/extensions/git/out/model.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "merge changes": "Módosítások egyesítése", + "staged changes": "Beadásra elÅ‘jegyzett módosítások", + "changes": "Módosítások", + "ok": "OK" +} \ No newline at end of file diff --git a/i18n/hun/extensions/git/out/scmProvider.i18n.json b/i18n/hun/extensions/git/out/scmProvider.i18n.json new file mode 100644 index 00000000000..7fded37328a --- /dev/null +++ b/i18n/hun/extensions/git/out/scmProvider.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "commit": "Commit" +} \ No newline at end of file diff --git a/i18n/hun/extensions/git/out/statusbar.i18n.json b/i18n/hun/extensions/git/out/statusbar.i18n.json new file mode 100644 index 00000000000..a2c0dd5ce39 --- /dev/null +++ b/i18n/hun/extensions/git/out/statusbar.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "sync changes": "Módosítások szinkronizálása" +} \ No newline at end of file diff --git a/i18n/hun/extensions/git/package.i18n.json b/i18n/hun/extensions/git/package.i18n.json new file mode 100644 index 00000000000..9c502715934 --- /dev/null +++ b/i18n/hun/extensions/git/package.i18n.json @@ -0,0 +1,24 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "command.clone": "Klónozás", + "command.refresh": "Frissítés", + "command.openFile": "Fájl megnyitása", + "command.commit": "Commit", + "command.commitStaged": "Beadásra elÅ‘jegyezve", + "command.commitStagedSigned": "ElÅ‘jegyzettek beadása (commit) aláírással", + "command.commitAll": "Teljes beadás", + "command.commitAllSigned": "Összes beadása (commit) aláírással", + "command.undoCommit": "Legutolsó beadás (commit) visszavonása", + "command.pull": "Letöltés", + "command.push": "Feltöltés", + "command.pushTo": "Push...", + "command.sync": "Szinkronizálás", + "command.publish": "Ãg publikálása", + "command.showOutput": "Git kimenet megjelenítése", + "config.path": "Elérési út a git végrehajtható fájljához", + "config.autorefresh": "Meghatározza, hogy engedélyezve van-e az automatikus frissítés" +} \ No newline at end of file diff --git a/i18n/hun/extensions/grunt/out/main.i18n.json b/i18n/hun/extensions/grunt/out/main.i18n.json new file mode 100644 index 00000000000..9c974666315 --- /dev/null +++ b/i18n/hun/extensions/grunt/out/main.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "execFailed": "A Grunt automatikus felderítése nem sikerült a következÅ‘ hiba miatt: {0}" +} \ No newline at end of file diff --git a/i18n/hun/extensions/grunt/package.i18n.json b/i18n/hun/extensions/grunt/package.i18n.json new file mode 100644 index 00000000000..9888b20bc6a --- /dev/null +++ b/i18n/hun/extensions/grunt/package.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "config.grunt.autoDetect": "Meghatározza, hogy a Grunt feladatok automatikus felderításe be van-e kapcsolva. A beállítás alapértelmezetten aktív." +} \ No newline at end of file diff --git a/i18n/hun/extensions/gulp/out/main.i18n.json b/i18n/hun/extensions/gulp/out/main.i18n.json new file mode 100644 index 00000000000..8c8ac9db031 --- /dev/null +++ b/i18n/hun/extensions/gulp/out/main.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "execFailed": "A gulp automatikus felderítése nem sikerült a következÅ‘ hiba miatt: {0}" +} \ No newline at end of file diff --git a/i18n/hun/extensions/gulp/package.i18n.json b/i18n/hun/extensions/gulp/package.i18n.json new file mode 100644 index 00000000000..ecaab76d9c7 --- /dev/null +++ b/i18n/hun/extensions/gulp/package.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "config.gulp.autoDetect": "Meghatározza, hogy a Gulp feladatok automatikus felderításe be van-e kapcsolva. A beállítás alapértelmezetten aktív." +} \ No newline at end of file diff --git a/i18n/hun/extensions/html/client/out/htmlMain.i18n.json b/i18n/hun/extensions/html/client/out/htmlMain.i18n.json new file mode 100644 index 00000000000..3aff5dce6a0 --- /dev/null +++ b/i18n/hun/extensions/html/client/out/htmlMain.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "htmlserver.name": "HTML nyelvi szerver" +} \ No newline at end of file diff --git a/i18n/hun/extensions/html/package.i18n.json b/i18n/hun/extensions/html/package.i18n.json new file mode 100644 index 00000000000..1eea9c9eee6 --- /dev/null +++ b/i18n/hun/extensions/html/package.i18n.json @@ -0,0 +1,27 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "html.format.enable.desc": "Alapértelmezett HTML-formázó engedélyezése vagy letiltása (újraindítást igényel)", + "html.format.wrapLineLength.desc": "Maximális karakterszám soronként (0 = letiltás)", + "html.format.unformatted.desc": "Azon elemek vesszÅ‘vel elválasztott listája, melyek ne legyenek újraformázva. 'null' érték esetén a https://www.w3.org/TR/html5/dom.html#phrasing-content oldalon listázott elemek lesznek használva.", + "html.format.contentUnformatted.desc": "Azon elemek vesszÅ‘vel elválasztott listája, melyek ne legyenek újraformázva. 'null' érték esetén a 'pre' tag lesz használva.", + "html.format.indentInnerHtml.desc": "- és -szakaszok indentálása.", + "html.format.preserveNewLines.desc": "Az elemek elÅ‘tt lévÅ‘ sortörések meg legyenek-e hagyva. Csak elemek elÅ‘tt működik, elemek belsejében vagy szövegben nem.", + "html.format.maxPreserveNewLines.desc": "Az egymás után megÅ‘rzött sortörések maximális száma. Ha nem szeretné korlátozni, használja a 'null' értéket!", + "html.format.indentHandlebars.desc": "{{#foo}} és {{/foo}} formázása és indentálása.", + "html.format.endWithNewline.desc": "Lezárás új sorral.", + "html.format.extraLiners.desc": "Azon elemek veszÅ‘vel elválasztott listája, amelyek elÅ‘tt lennie kell egy extra új sornak. 'null' érték esetén a \"head,body,/html\" érték van használva.", + "html.format.wrapAttributes.desc": "Attribútumok tördelése.", + "html.format.wrapAttributes.auto": "Az attribútumok csak akkor vannak tördelve, ha a sorhossz túl lett lépve.", + "html.format.wrapAttributes.force": "Minden egyes attribútum tördelve van, kivéve az elsÅ‘t.", + "html.format.wrapAttributes.forcealign": "Minden egyes attribútum tördelve van, kivéve az elsÅ‘t, és igazítva vannak.", + "html.format.wrapAttributes.forcemultiline": "Minden egyes attribútum tördelve van.", + "html.suggest.angular1.desc": "Meghatározza, hogy a beépített HTML nyelvi támogatás ajánl-e Angular V1 elemeket és tulajdonságokat.", + "html.suggest.ionic.desc": "Meghatározza, hogy a beépített HTML nyelvi támogatás ajánl-e Ionic elemeket, tulajdonságokat és értékeket.", + "html.suggest.html5.desc": "Meghatározza, hogy a beépített HTML nyelvi támogatás ajánl-e HTML5-ös elemeket, tulajdonságokat és értékeket.", + "html.validate.scripts": "Meghatározza, hogy a beépített HTML nyelvi támogatás validálja-e a beágyazott parancsafájlokat.", + "html.validate.styles": "Meghatározza, hogy a beépített HTML nyelvi támogatás validálja-e a beágyazott stílusfájlokat." +} \ No newline at end of file diff --git a/i18n/hun/extensions/jake/out/main.i18n.json b/i18n/hun/extensions/jake/out/main.i18n.json new file mode 100644 index 00000000000..c73ae9cac7e --- /dev/null +++ b/i18n/hun/extensions/jake/out/main.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "execFailed": "A Jake automatikus felderítése nem sikerült a következÅ‘ hiba miatt: {0}" +} \ No newline at end of file diff --git a/i18n/hun/extensions/jake/package.i18n.json b/i18n/hun/extensions/jake/package.i18n.json new file mode 100644 index 00000000000..4ac74e50f94 --- /dev/null +++ b/i18n/hun/extensions/jake/package.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "config.jake.autoDetect": "Meghatározza, hogy a Jake-feladatok automatikus felderításe be van-e kapcsolva. A beállítás alapértelmezetten aktív." +} \ No newline at end of file diff --git a/i18n/hun/extensions/javascript/out/features/bowerJSONContribution.i18n.json b/i18n/hun/extensions/javascript/out/features/bowerJSONContribution.i18n.json new file mode 100644 index 00000000000..c1e4df9ef01 --- /dev/null +++ b/i18n/hun/extensions/javascript/out/features/bowerJSONContribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "json.bower.default": "Alapértelmezett bower.json", + "json.bower.error.repoaccess": "A bower-adattár lekérdezése nem sikerült: {0}", + "json.bower.latest.version": "legutóbbi" +} \ No newline at end of file diff --git a/i18n/hun/extensions/javascript/out/features/packageJSONContribution.i18n.json b/i18n/hun/extensions/javascript/out/features/packageJSONContribution.i18n.json new file mode 100644 index 00000000000..364a0ae2d17 --- /dev/null +++ b/i18n/hun/extensions/javascript/out/features/packageJSONContribution.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "json.package.default": "Alapértelmezett package.json", + "json.npm.error.repoaccess": "Az NPM-adattár lekérdezése nem sikerült: {0}", + "json.npm.latestversion": "A csomag jelenlegi legújabb verziója", + "json.npm.majorversion": "A legfrissebb fÅ‘verzió keresése (1.x.x)", + "json.npm.minorversion": "A legfrissebb alverzió keresése (1.2.x)", + "json.npm.version.hover": "Legújabb verzió: {0}" +} \ No newline at end of file diff --git a/i18n/hun/extensions/json/client/out/jsonMain.i18n.json b/i18n/hun/extensions/json/client/out/jsonMain.i18n.json new file mode 100644 index 00000000000..a71a351271b --- /dev/null +++ b/i18n/hun/extensions/json/client/out/jsonMain.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "jsonserver.name": "JSON nyelvi szerver" +} \ No newline at end of file diff --git a/i18n/hun/extensions/json/package.i18n.json b/i18n/hun/extensions/json/package.i18n.json new file mode 100644 index 00000000000..9357a63ffaf --- /dev/null +++ b/i18n/hun/extensions/json/package.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "json.schemas.desc": "Sémák hozzárendelése JSON-fájlokhoz a jelenlegi projektben", + "json.schemas.url.desc": "Egy séma URL-címe vagy egy séma relatív elérési útja az aktuális könyvtárban", + "json.schemas.fileMatch.desc": "Fájlminták tömbje, amely a JSON-fájlok sémákhoz való rendelésénél van használva.", + "json.schemas.fileMatch.item.desc": "Fájlminták tömbje, amely a JSON-fájlok sémákhoz való rendelésénél van használva. Tartalmazhat '*'-ot.", + "json.schemas.schema.desc": "Az adott URL-cím sémadefiníciója. A sémát csak a séma URL-címéhez való fölösleges lekérdezések megakadályozása érdekében kell megadni.", + "json.format.enable.desc": "Alapértelmezett JSON-formázó engedélyezése vagy letiltása (újraindítást igényel)", + "json.tracing.desc": "A VS Code és a JSON nyelvi szerver közötti kommunikáció naplózása.", + "json.colorDecorators.enable.desc": "Színdekorátorok engedélyezése vagy letiltása" +} \ No newline at end of file diff --git a/i18n/hun/extensions/markdown/out/extension.i18n.json b/i18n/hun/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..5f2c5343afb --- /dev/null +++ b/i18n/hun/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "onPreviewStyleLoadError": "A 'markdown.styles' nem tölthetÅ‘ be: {0}" +} \ No newline at end of file diff --git a/i18n/hun/extensions/markdown/out/previewContentProvider.i18n.json b/i18n/hun/extensions/markdown/out/previewContentProvider.i18n.json new file mode 100644 index 00000000000..9e943e324b8 --- /dev/null +++ b/i18n/hun/extensions/markdown/out/previewContentProvider.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "preview.securityMessage.text": "A parancsfájlok futtatása le van tiltva az aktuális dokumentumban", + "preview.securityMessage.title": "A parancsfájlok futtatása le van tiltva a markdown-elÅ‘nézetben. Módosítsa a markdown-elÅ‘nézet biztonsági beállításait a parancsfájlok engedélyezéséhez", + "preview.securityMessage.label": "Biztonsági figyelmeztetés: a parancsfájlok le vannak tiltva" +} \ No newline at end of file diff --git a/i18n/hun/extensions/markdown/out/security.i18n.json b/i18n/hun/extensions/markdown/out/security.i18n.json new file mode 100644 index 00000000000..2bba397346f --- /dev/null +++ b/i18n/hun/extensions/markdown/out/security.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "preview.showPreviewSecuritySelector.disallowScriptsForWorkspaceTitle": "Parancsfájlok futtatásának letiltása a markdown-elÅ‘nézetben ezen a munkaterületen", + "preview.showPreviewSecuritySelector.currentSelection": "Aktuális beállítás", + "preview.showPreviewSecuritySelector.allowScriptsForWorkspaceTitle": "Parancsfájlok futtatásának engedélyezése a markdown-elÅ‘nézetben ezen a munkaterületen", + "preview.showPreviewSecuritySelector.title": "A markdown-elÅ‘nézet biztonsági beállításainak módosítása" +} \ No newline at end of file diff --git a/i18n/hun/extensions/markdown/package.i18n.json b/i18n/hun/extensions/markdown/package.i18n.json new file mode 100644 index 00000000000..8c3641582cb --- /dev/null +++ b/i18n/hun/extensions/markdown/package.i18n.json @@ -0,0 +1,22 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "markdown.preview.doubleClickToSwitchToEditor.desc": "Kattintson duplán a markdown-elÅ‘nézetre a szerkesztÅ‘re való átváltáshoz.", + "markdown.preview.fontFamily.desc": "Meghatározza a markdown-elÅ‘nézeten használt betűkészletet.", + "markdown.preview.fontSize.desc": "Meghatározza a markdown-elÅ‘nézet betűméretét, pixelekben.", + "markdown.preview.lineHeight.desc": "Meghatározza a markdown-elÅ‘nézeten használt sormagasságot. Az érték relatív a betűmérethez képest.", + "markdown.preview.markEditorSelection.desc": "Az aktuális kijelölés megjelölése a markdown-elÅ‘nézeten", + "markdown.preview.scrollEditorWithPreview.desc": "Amikor a markdown-elÅ‘nézetet görgetik, a szerkesztÅ‘nézet is aktualizálódik", + "markdown.preview.scrollPreviewWithEditorSelection.desc": "A markdown-elÅ‘nézetet úgy görgeti, hogy látni lehessen az aktuálisan kijelölt sort", + "markdown.preview.title": "ElÅ‘nézet megnyitása", + "markdown.previewFrontMatter.dec": "Meghatározza, hogy a YAML konfiguráció (front matter) hogyan legyen megjelenítve a markdown-elÅ‘nézetben. A 'hide' elrejti a konfigurációt, minden más esetben a front matter markdown-tartalomként van kezelve.", + "markdown.previewSide.title": "ElÅ‘nézet megnyitása oldalt", + "markdown.showSource.title": "Forrás megjelenítése", + "markdown.styles.dec": "CSS-stíluslapok URL-címeinek vagy helyi elérési útjainak listája, amelyek a markdown-elÅ‘nézeten használva vannak. A relatív elérési utak az intézÅ‘ben megnyitott mappához képest vannak relatívan értelmezve. Ha nincs mappa megnyitva, akkor a markdown-fájl elréséi útjához képest. Minden '\\' karaktert '\\\\' formában kell megadni.", + "markdown.showPreviewSecuritySelector.title": "A markdown-elÅ‘nézet biztonsági beállításainak módosítása", + "markdown.preview.enableExperimentalExtensionApi.desc": "[Kísérleti] Kiterjesztések módosíthatják a markdown elÅ‘nézetet.", + "markdown.trace.desc": "Hibakeresési napló engedélyezése a markdown kiterjesztésben." +} \ No newline at end of file diff --git a/i18n/hun/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/hun/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..7dfc4ee0d5d --- /dev/null +++ b/i18n/hun/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "acceptCurrentChange": "Helyi változtatás elfogadása", + "acceptIncomingChange": "BeérkezÅ‘ változtatás elfogadása", + "acceptBothChanges": "Változtatások elfogadása mindkét oldalról", + "compareChanges": "Változtatások összehasonlítása" +} \ No newline at end of file diff --git a/i18n/hun/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/hun/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..16d242a669c --- /dev/null +++ b/i18n/hun/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "cursorNotInConflict": "A szerkesztÅ‘ablak kurzora nem egy összeolvasztási konfliktuson belül van.", + "compareChangesTitle": "{0}: Helyi változtatások ⟷ BeérkezÅ‘ változtatások", + "cursorOnCommonAncestorsRange": "A szerkesztÅ‘ablak kurzora a közös Å‘s blokkján van. Vigye vagy a \"helyi\" vagy a \"beérkezÅ‘\" blokkra.", + "cursorOnSplitterRange": "A szerkesztÅ‘ablak kurzora az összeolvasztási konfliktus elválasztójánál van. Vigye vagy a \"helyi\" vagy a \"beérkezÅ‘\" blokkra.", + "noConflicts": "Ebben a fájlban nincsenek összeolvasztási konfliktusok", + "noOtherConflictsInThisFile": "Ebben a fájlban nincsenek további összeolvasztási konfliktusok" +} \ No newline at end of file diff --git a/i18n/hun/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/hun/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..dac641cdd10 --- /dev/null +++ b/i18n/hun/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "currentChange": "(Helyi változtatás)", + "incomingChange": "(BeérkezÅ‘ változtatás)" +} \ No newline at end of file diff --git a/i18n/hun/extensions/merge-conflict/package.i18n.json b/i18n/hun/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..b3814f8d7e6 --- /dev/null +++ b/i18n/hun/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,20 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "command.category": "Összeolvasztási konfliktus", + "command.accept.all-incoming": "Összes beérkezÅ‘ változás elfogadása", + "command.accept.all-both": "Változások elfogadása mindkét oldalról", + "command.accept.current": "Helyi változtatás elfogadása", + "command.accept.incoming": "BeérkezÅ‘ változtatás elfogadása", + "command.accept.selection": "Kijelölt változtatás elfogadása", + "command.accept.both": "Változás elfogadása mindkét oldalról", + "command.next": "KövetkezÅ‘ konfliktus", + "command.previous": "ElÅ‘zÅ‘ konfliktus", + "command.compare": "Aktuális konfliktus összehasonlítása", + "config.title": "Összeolvasztási konfliktus", + "config.codeLensEnabled": "Összeolvasztási konfliktust jelzÅ‘ kódlencsék engedélyezése vagy letiltása a szerkesztÅ‘ablakban.", + "config.decoratorsEnabled": "Összeolvasztási konfliktust jelzÅ‘ dekorátorok engedélyezése vagy letiltása a szerkesztÅ‘ablakban." +} \ No newline at end of file diff --git a/i18n/hun/extensions/npm/package.i18n.json b/i18n/hun/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..89c11886b21 --- /dev/null +++ b/i18n/hun/extensions/npm/package.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "config.npm.autoDetect": "Meghatározza, hogy az npm-parancsfájlok automatikus felderításe be van-e kapcsolva. A beállítás alapértelmezetten aktív." +} \ No newline at end of file diff --git a/i18n/hun/extensions/php/out/features/validationProvider.i18n.json b/i18n/hun/extensions/php/out/features/validationProvider.i18n.json new file mode 100644 index 00000000000..2786c871df6 --- /dev/null +++ b/i18n/hun/extensions/php/out/features/validationProvider.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "php.useExecutablePath": "Engedélyezi a(z) {0} (munkaterületi beállításként megadott) végrehajtását a PHP-fájlok linteléséhez?", + "php.yes": "Engedélyezés", + "php.no": "Tiltás", + "wrongExecutable": "A validáció nem sikerült, mivel a(z) {0} nem egy érvényes php végrehajtható fájl. Használja a 'php.validate.executablePath' beállítást a PHP végrehajtható fájl konfigurálásához!", + "noExecutable": "A validáció nem sikerült, mivel nincs beállítva PHP végrehajtható fájl. Használja a 'php.validate.executablePath' beállítást a PHP végrehajtható fájl konfigurálásához!", + "unknownReason": "Nem sikerült futtatni a PHP-t a következÅ‘ elérési út használatával: {0}. Az ok ismeretlen." +} \ No newline at end of file diff --git a/i18n/hun/extensions/php/package.i18n.json b/i18n/hun/extensions/php/package.i18n.json new file mode 100644 index 00000000000..59e189e72c4 --- /dev/null +++ b/i18n/hun/extensions/php/package.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "configuration.suggest.basic": "Meghatározza, hogy a beépített PHP nyelvi támogatás ajánl-e PHP globálisokat és változókat.", + "configuration.validate.enable": "Beépített PHP-validáció engedélyezése vagy letiltása", + "configuration.validate.executablePath": "A PHP végrehajtható fájljának elérési útja.", + "configuration.validate.run": "A linter mentéskor vagy gépeléskor fut-e.", + "configuration.title": "PHP", + "commands.categroy.php": "PHP", + "command.untrustValidationExecutable": "PHP-validációs végrehajtható fájl letiltása (munkaterületi beállításként megadva)" +} \ No newline at end of file diff --git a/i18n/hun/extensions/typescript/out/features/bufferSyncSupport.i18n.json b/i18n/hun/extensions/typescript/out/features/bufferSyncSupport.i18n.json new file mode 100644 index 00000000000..36e9902ff5e --- /dev/null +++ b/i18n/hun/extensions/typescript/out/features/bufferSyncSupport.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "versionMismatch": "TypeScript ({1}) használata a szerkesztÅ‘funkciókhoz. A számítógére TypeScript (01}) van globálisan telepítve. A VS Code-ban látható hibák eltérhetnek a TSC által visszaadott hibáktól.", + "moreInformation": "További információ", + "doNotCheckAgain": "Ne ellenÅ‘rizze újra", + "close": "Bezárás", + "updateTscCheck": "A 'typescript.check.tscVersion' felhasználói beállítás értéke módosítva false-ra" +} \ No newline at end of file diff --git a/i18n/hun/extensions/typescript/out/features/completionItemProvider.i18n.json b/i18n/hun/extensions/typescript/out/features/completionItemProvider.i18n.json new file mode 100644 index 00000000000..69b50af008f --- /dev/null +++ b/i18n/hun/extensions/typescript/out/features/completionItemProvider.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "acquiringTypingsLabel": "Típusdefiníciók letöltése...", + "acquiringTypingsDetail": "Típusdefiníciók letöltése az IntelliSense-hez." +} \ No newline at end of file diff --git a/i18n/hun/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json b/i18n/hun/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json new file mode 100644 index 00000000000..4785b97e722 --- /dev/null +++ b/i18n/hun/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ts-check": "Engedélyezi a JavaScript-fájlok szemantikai ellenÅ‘rzését. A fájl tetején kell szerepelnie.", + "ts-nocheck": "Letiltja a JavaScript-fájlok szemantikai ellenÅ‘rzését. A fájl tetején kell szerepelnie.", + "ts-ignore": "Elfedi a fájl következÅ‘ sorában található @ts-check-hibákat." +} \ No newline at end of file diff --git a/i18n/hun/extensions/typescript/out/features/implementationsCodeLensProvider.i18n.json b/i18n/hun/extensions/typescript/out/features/implementationsCodeLensProvider.i18n.json new file mode 100644 index 00000000000..f5a576fa8a7 --- /dev/null +++ b/i18n/hun/extensions/typescript/out/features/implementationsCodeLensProvider.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "oneImplementationLabel": "1 implementáció", + "manyImplementationLabel": "{0} implementáció", + "implementationsErrorLabel": "Nem sikerült meghatározni az implementációkat" +} \ No newline at end of file diff --git a/i18n/hun/extensions/typescript/out/features/jsDocCompletionProvider.i18n.json b/i18n/hun/extensions/typescript/out/features/jsDocCompletionProvider.i18n.json new file mode 100644 index 00000000000..c1b25917e3b --- /dev/null +++ b/i18n/hun/extensions/typescript/out/features/jsDocCompletionProvider.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "typescript.jsDocCompletionItem.documentation": "JSDoc-megjegyzés" +} \ No newline at end of file diff --git a/i18n/hun/extensions/typescript/out/features/referencesCodeLensProvider.i18n.json b/i18n/hun/extensions/typescript/out/features/referencesCodeLensProvider.i18n.json new file mode 100644 index 00000000000..797518b5091 --- /dev/null +++ b/i18n/hun/extensions/typescript/out/features/referencesCodeLensProvider.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "oneReferenceLabel": "1 referencia", + "manyReferenceLabel": "{0} referencia", + "referenceErrorLabel": "Nem sikerült meghatározni a referenciákat" +} \ No newline at end of file diff --git a/i18n/hun/extensions/typescript/out/typescriptMain.i18n.json b/i18n/hun/extensions/typescript/out/typescriptMain.i18n.json new file mode 100644 index 00000000000..c521fb331a6 --- /dev/null +++ b/i18n/hun/extensions/typescript/out/typescriptMain.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "typescript.projectConfigNoWorkspace": "Nyisson meg egy mappát a VS Code-ban typescriptes vagy javascriptes projekt használatához!", + "typescript.projectConfigUnsupportedFile": "Nem sikerült meghatározni a TypeScript- vagy JavaScript-projektet. Nem támogatott fájltípus", + "typescript.projectConfigCouldNotGetInfo": "Nem sikerült meghatározni a TypeScript- vagy JavaScript-projektet", + "typescript.noTypeScriptProjectConfig": "A fájl nem része egy TypeScript-projektnek", + "typescript.noJavaScriptProjectConfig": "A fájl nem része egy JavaScript-projektnek", + "typescript.configureTsconfigQuickPick": "tsconfig.json konfigurálása", + "typescript.configureJsconfigQuickPick": "jsconfig.json konfigurálása", + "typescript.projectConfigLearnMore": "További információ" +} \ No newline at end of file diff --git a/i18n/hun/extensions/typescript/out/typescriptServiceClient.i18n.json b/i18n/hun/extensions/typescript/out/typescriptServiceClient.i18n.json new file mode 100644 index 00000000000..e46f95c0a62 --- /dev/null +++ b/i18n/hun/extensions/typescript/out/typescriptServiceClient.i18n.json @@ -0,0 +1,24 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noServerFound": "A(z) {0} elérési út nem egy érvényes tsserver-telepítésre mutat. A beépített TypeScript-verzió lesz használva.", + "noBundledServerFound": "A VSCode beépített TS-szerverét törölte egy másik alkalmazás, például egy hibásan viselkedÅ‘ víruskeresÅ‘ eszköz. Telepítse újra a VSCode-ot! ", + "versionNumber.custom": "egyedi", + "serverCouldNotBeStarted": "Nem sikerült elindítani a TypeScript nyelvi szervert. Hibaüzenet: {0}", + "useVSCodeVersionOption": "A VSCode verziójának használata", + "activeVersion": "Jelenleg aktív", + "useWorkspaceVersionOption": "A munkaterület verziójának használata", + "learnMore": "További információ", + "selectTsVersion": "Válassza ki a javascriptes és typescriptes nyelvi funkciókhoz használt TypeScript-verziót", + "typescript.openTsServerLog.notSupported": "A TS-szerver naplózáshoz TS 2.2.2+ szükséges", + "typescript.openTsServerLog.loggingNotEnabled": "A TS-szervernaplózás ki van kapcsolva. Ãllítsa be a `typescript.tsserver.log` beállítást, majd indítsa újra a TS-szervert a naplózás engedélyezéséhez!", + "typescript.openTsServerLog.enableAndReloadOption": "Naplózás engedélyezése és TS-szerver újraindítása", + "typescript.openTsServerLog.noLogFile": "A TS-szerver nem kezdett el naplózni", + "openTsServerLog.openFileFailedFailed": "A TS-szervernapló nem nyitható meg", + "serverDiedAfterStart": "A TypeScript nyelvi szolgáltatás öt alkalommal omlott össze rögtön azután, hogy el lett indítva. A szolgáltatás nem lesz újraindítva.", + "serverDiedReportIssue": "Probléma jelentése", + "serverDied": "A TypeScript nyelvi szolgáltatás öt alkalommal omlott össze az elmúlt öt percben." +} \ No newline at end of file diff --git a/i18n/hun/extensions/typescript/out/utils/logger.i18n.json b/i18n/hun/extensions/typescript/out/utils/logger.i18n.json new file mode 100644 index 00000000000..bc738f43d0c --- /dev/null +++ b/i18n/hun/extensions/typescript/out/utils/logger.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "channelName": "TypeScript" +} \ No newline at end of file diff --git a/i18n/hun/extensions/typescript/out/utils/projectStatus.i18n.json b/i18n/hun/extensions/typescript/out/utils/projectStatus.i18n.json new file mode 100644 index 00000000000..a75ecaf0598 --- /dev/null +++ b/i18n/hun/extensions/typescript/out/utils/projectStatus.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "hintExclude": "A JavaScript/TypeScript funkciók teljes projektre való engedélyezéséhez zárja ki a sok fájlt tartalmazó mappákat. Például: {0}", + "hintExclude.generic": "A JavaScript/TypeScript funkciók teljes projektre való engedélyezéséhez zárja ki azokat a mappákat, amelyben olyan forrásfájlok találhatók, melyen nem dolgozik.", + "large.label": "Kivételek konfigurálása", + "hintExclude.tooltip": "A JavaScript/TypeScript funkciók teljes projektre való engedélyezéséhez zárja ki azokat a mappákat, amelyben olyan forrásfájlok találhatók, melyen nem dolgozik. " +} \ No newline at end of file diff --git a/i18n/hun/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/hun/extensions/typescript/out/utils/typingsStatus.i18n.json new file mode 100644 index 00000000000..4b308f26e04 --- /dev/null +++ b/i18n/hun/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "installingPackages": "Adatok lekérése a jobb typescriptes IntelliSense-hez", + "typesInstallerInitializationFailed.title": "Nem sikerült telepíteni a típusdefiníciós fájlokat a javascriptes nyelvi funkciókhoz. GyÅ‘zÅ‘djön meg róla, hogy az NPM telepítve van vagy módosítsa a 'typescript.npm' beállítás értékét a felhasználói beállításokban", + "typesInstallerInitializationFailed.moreInformation": "További információ", + "typesInstallerInitializationFailed.doNotCheckAgain": "Ne ellenÅ‘rizze újra", + "typesInstallerInitializationFailed.close": "Bezárás" +} \ No newline at end of file diff --git a/i18n/hun/extensions/typescript/package.i18n.json b/i18n/hun/extensions/typescript/package.i18n.json new file mode 100644 index 00000000000..42fa728d941 --- /dev/null +++ b/i18n/hun/extensions/typescript/package.i18n.json @@ -0,0 +1,48 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "typescript.reloadProjects.title": "Projekt újratöltése", + "javascript.reloadProjects.title": "Projekt újratöltése", + "configuration.typescript": "TypeScript", + "typescript.useCodeSnippetsOnMethodSuggest.dec": "Függvények kiegészítése paraméterdefiníciójukkal.", + "typescript.tsdk.desc": "A tsservert és a lib*.d.ts fájlokat tartalmazó mappa elérési útja.", + "typescript.disableAutomaticTypeAcquisition": "Automatikus típusdefiníció-letöltés letiltása. Legalább 2.0.6-os TypeScriptet igényel, és a módosítás után újraindítás szükséges.", + "typescript.check.tscVersion": "Megvizsgálja, hogy a globálisan telepített TypeScript fordító (pl. tsc) különbözik-e a TypeScript nyelvi szolgáltatás által használttól.", + "typescript.tsserver.log": "Engedélyezi a TS-szerver naplózását egy fájlba. Ez a napló a TS-szerverrel kapcsolatos problémák diagnosztizálására használható. A napló tartalmazhat elérési utakat, forráskódot és más potenciálisan érzékeny, projekttel kapcsolatos adatot.", + "typescript.tsserver.trace": "Engedélyezi a TS-szervernek küldött üzenetek naplózását. Ez a napló a TS-szerverrel kapcsolatos problémák diagnosztizálására használható. A napló tartalmazhat elérési utakat, forráskódot és más potenciálisan érzékeny, projekttel kapcsolatos adatot. ", + "typescript.validate.enable": "TypeScript-validálás engedélyezése vagy letiltása.", + "typescript.format.enable": "Alapértelmezett TypeScript-formázó engedélyezése vagy letiltása.", + "javascript.format.enable": "Alapértelmezett JavaScript-formázó engedélyezése vagy letiltása.", + "format.insertSpaceAfterCommaDelimiter": "Meghatározza a szóközök kezelését vesszÅ‘ elválasztókarakter után.", + "format.insertSpaceAfterConstructor": "Meghatározza a szóközök kezelését a constructor kulcsszó után. TypeScript >= 2.3.0-t igényel.", + "format.insertSpaceAfterSemicolonInForStatements": "Meghatározza a szóközök kezelését pontosvesszÅ‘ után a for ciklusban.", + "format.insertSpaceBeforeAndAfterBinaryOperators": "Meghatározza a szóközök kezelését bináris operátorok után.", + "format.insertSpaceAfterKeywordsInControlFlowStatements": "Meghatározza a szóközök kezelését vezérlési szerkezetek kulcsszavai után.", + "format.insertSpaceAfterFunctionKeywordForAnonymousFunctions": "Meghatározza a szóközök kezelését a névtelen függvényekben található function kulcsszó után.", + "format.insertSpaceBeforeFunctionParenthesis": "Meghatározza a szóközök kezelését a függvényargumentumokat tartalmazó zárójel elÅ‘tt. TypeScript >= 2.1.5-öt igényel.", + "format.insertSpaceAfterOpeningAndBeforeClosingNonemptyParenthesis": "Meghatározza a szóközök kezelését nem üres zárójelek nyitása után és zárása elÅ‘tt.", + "format.insertSpaceAfterOpeningAndBeforeClosingNonemptyBrackets": "Meghatározza a szóközök kezelését nem üres szögletes zárójelek nyitása után és zárása elÅ‘tt.", + "format.insertSpaceAfterOpeningAndBeforeClosingNonemptyBraces": "Meghatározza a szóközök kezelését nem üres kapcsos zárójelek nyitása után és zárása elÅ‘tt. TypeScript >= 2.3.0-t igényel.", + "format.insertSpaceAfterOpeningAndBeforeClosingTemplateStringBraces": "Meghatározza a szóközök kezelését a sablonkarakterláncok (template stringek) kapcsos zárójeleinek nyitása után és zárása elÅ‘tt. TypeScript >= 2.0.6-ot igényel.", + "format.insertSpaceAfterOpeningAndBeforeClosingJsxExpressionBraces": "Meghatározza a szóközök kezelését JSX-kifejezések kapcsos zárójeleinek nyitása után és zárása elÅ‘tt. TypeScript >= 2.0.6-ot igényel.", + "format.placeOpenBraceOnNewLineForFunctions": "Meghatározza, hogy a függvények nyitó kapcsos zárójelei új sorba kerüljenek-e vagy sem.", + "format.placeOpenBraceOnNewLineForControlBlocks": "Meghatározza, hogy a vezérlÅ‘blokkok nyitó kapcsos zárójelei új sorba kerüljenek-e vagy sem.", + "javascript.validate.enable": "JavaScript-validálás engedélyezése vagy letiltása.", + "typescript.goToProjectConfig.title": "Projektkonfiguráció megkeresése", + "javascript.goToProjectConfig.title": "Projektkonfiguráció megkeresése", + "javascript.referencesCodeLens.enabled": "Referencia kódlencsék engedélyezése vagy letiltása a JavaScript-fájlokban.", + "typescript.referencesCodeLens.enabled": "Referencia kódlencsék engedélyezése vagy letiltása a TypeScript-fájlokban. TypeScript >= 2.0.6-ot igényel.", + "typescript.implementationsCodeLens.enabled": "Implementációs kódlencsék engedélyezése vagy letiltása. TypeScript >= 2.2.0-t igényel.", + "typescript.openTsServerLog.title": "TS-szervernapló megnyitása", + "typescript.restartTsServer": "TS-szerver újraindítása", + "typescript.selectTypeScriptVersion.title": "TypeScript-verzió kiválasztása", + "jsDocCompletion.enabled": "Automatikus JSDoc-megjegyzések engedélyezése vagy letiltása", + "javascript.implicitProjectConfig.checkJs": "JavaScript-fájlok szemantikai ellenÅ‘rzésének engedélyezése vagy letiltása. A meglévÅ‘ jsconfig.json vagy tsconfig.json fájlok felülírják ezt a beállítást. TypeScript >= 2.3.1-et igényel.", + "typescript.npm": "Az automatikus típusdefiníció-letöltéshez használt NPM végrehajtható fájl elérési útja. TypeScript 2.3.4-et igényel.", + "typescript.check.npmIsInstalled": "EllenÅ‘rizze, hogy az NPM telepítve van-e az automatikus típusdefiníció-letöltéshez.", + "javascript.nameSuggestions": "Egyedi nevek listázásának engedélyezése a javascriptes javaslati listákban.", + "typescript.tsc.autoDetect": "Meghatározza, hogy a tsc-feladatok automatikus felderítése be van-e kapcsolva." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/base/browser/ui/actionbar/actionbar.i18n.json b/i18n/hun/src/vs/base/browser/ui/actionbar/actionbar.i18n.json new file mode 100644 index 00000000000..4ecb2c803f4 --- /dev/null +++ b/i18n/hun/src/vs/base/browser/ui/actionbar/actionbar.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "titleLabel": "{0} ({1})" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/base/browser/ui/aria/aria.i18n.json b/i18n/hun/src/vs/base/browser/ui/aria/aria.i18n.json new file mode 100644 index 00000000000..3bc0f0c0e68 --- /dev/null +++ b/i18n/hun/src/vs/base/browser/ui/aria/aria.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "repeated": "{0} (ismét elÅ‘fordult)" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/base/browser/ui/findinput/findInput.i18n.json b/i18n/hun/src/vs/base/browser/ui/findinput/findInput.i18n.json new file mode 100644 index 00000000000..d43a176512b --- /dev/null +++ b/i18n/hun/src/vs/base/browser/ui/findinput/findInput.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defaultLabel": "bemeneti adat" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/base/browser/ui/findinput/findInputCheckboxes.i18n.json b/i18n/hun/src/vs/base/browser/ui/findinput/findInputCheckboxes.i18n.json new file mode 100644 index 00000000000..d165fd19024 --- /dev/null +++ b/i18n/hun/src/vs/base/browser/ui/findinput/findInputCheckboxes.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "caseDescription": "Kis- és nagybetűk megkülönböztetése", + "wordsDescription": "Csak teljes szavas egyezés", + "regexDescription": "Reguláris kifejezés használata" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/base/browser/ui/inputbox/inputBox.i18n.json b/i18n/hun/src/vs/base/browser/ui/inputbox/inputBox.i18n.json new file mode 100644 index 00000000000..f6a7c8c5b20 --- /dev/null +++ b/i18n/hun/src/vs/base/browser/ui/inputbox/inputBox.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "alertErrorMessage": "Hiba: {0}", + "alertWarningMessage": "Figyelmeztetés: {0}", + "alertInfoMessage": "Információ: {0}" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/hun/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json new file mode 100644 index 00000000000..a5030e91872 --- /dev/null +++ b/i18n/hun/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "imgMeta": "{0}x{1} {2}", + "largeImageError": "A kép túl nagy a szerkesztÅ‘ben való megjelenítéshez.", + "resourceOpenExternalButton": "Kép megnyitása külsÅ‘ program használatával?", + "nativeBinaryError": "A fájl nem jeleníthetÅ‘ meg a szerkesztÅ‘ben, mert bináris adatokat tartalmaz, túl nagy vagy nem támogatott szövegkódolást használ.", + "sizeB": "{0} B", + "sizeKB": "{0} KB", + "sizeMB": "{0} MB", + "sizeGB": "{0} GB", + "sizeTB": "{0} TB" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/base/browser/ui/toolbar/toolbar.i18n.json b/i18n/hun/src/vs/base/browser/ui/toolbar/toolbar.i18n.json new file mode 100644 index 00000000000..d28a4867625 --- /dev/null +++ b/i18n/hun/src/vs/base/browser/ui/toolbar/toolbar.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "more": "Tovább" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/base/common/errorMessage.i18n.json b/i18n/hun/src/vs/base/common/errorMessage.i18n.json new file mode 100644 index 00000000000..a5107de5d65 --- /dev/null +++ b/i18n/hun/src/vs/base/common/errorMessage.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "message": "{0}: {1}", + "error.permission.verbose": "Engedélyhiány (HTTP {0})", + "error.permission": "Engedélyhiány", + "error.http.verbose": "{0} (HTTP {1}: {2})", + "error.http": "{0} (HTTP {1})", + "error.connection.unknown.verbose": "Ismeretlen csatlakozási hiba ({0})", + "error.connection.unknown": "Ismeretlen csatlakozási hiba történt. Vagy megszakadt az internetkapcsolat, vagy a kiszolgáló vált offline-ná.", + "stackTrace.format": "{0}: {1}", + "error.defaultMessage": "Ismeretlen hiba történt. Részletek a naplóban.", + "error.moreErrors": "{0} (összesen {1} hiba)" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/base/common/jsonErrorMessages.i18n.json b/i18n/hun/src/vs/base/common/jsonErrorMessages.i18n.json new file mode 100644 index 00000000000..c73ba839ef6 --- /dev/null +++ b/i18n/hun/src/vs/base/common/jsonErrorMessages.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "error.invalidSymbol": "Érvénytelen szimbólum", + "error.invalidNumberFormat": "Érvénytelen számformátum.", + "error.propertyNameExpected": "Hiányzó tulajdonságnév", + "error.valueExpected": "Hiányzó érték.", + "error.colonExpected": "Hiányzó kettÅ‘spont.", + "error.commaExpected": "Hiányzó vesszÅ‘", + "error.closeBraceExpected": "Hiányzó záró kapcsos zárójel", + "error.closeBracketExpected": "Hiányzó záró szögletes zárójel", + "error.endOfFileExpected": "Itt fájlvége jelnek kellene szerepelnie." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/base/common/keybindingLabels.i18n.json b/i18n/hun/src/vs/base/common/keybindingLabels.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/hun/src/vs/base/common/keybindingLabels.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/hun/src/vs/base/common/processes.i18n.json b/i18n/hun/src/vs/base/common/processes.i18n.json new file mode 100644 index 00000000000..d80423e4ca7 --- /dev/null +++ b/i18n/hun/src/vs/base/common/processes.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ExecutableParser.commandMissing": "Hiba: a végrehajtási információnak definiálnia kell egy karakterlánc típusú parancsot.", + "ExecutableParser.isShellCommand": "Figyelmeztetés: az isShellCommand értékének boolean típusúnak kell lennie. A következÅ‘ érték figyelmen kívül van hagyva: {0}.", + "ExecutableParser.args": "Figyelmeztetés: az args értékének string[] típusúnak kell lennie. A következÅ‘ érték figyelmen kívül van hagyva: {0}.", + "ExecutableParser.invalidCWD": "Figyelmeztetés: az options.cwd értékének string típusúnak kell lennie. A következÅ‘ érték figyelmen kívül van hagyva: {0}." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/base/common/severity.i18n.json b/i18n/hun/src/vs/base/common/severity.i18n.json new file mode 100644 index 00000000000..5c503caf279 --- /dev/null +++ b/i18n/hun/src/vs/base/common/severity.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "sev.error": "Hiba", + "sev.warning": "Figyelmeztetés", + "sev.info": "Információ" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/base/node/processes.i18n.json b/i18n/hun/src/vs/base/node/processes.i18n.json new file mode 100644 index 00000000000..9e3ad98b69c --- /dev/null +++ b/i18n/hun/src/vs/base/node/processes.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "TaskRunner.UNC": "Rendszerparancsok UNC-meghajtókon nem hajthatók végre." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/base/node/zip.i18n.json b/i18n/hun/src/vs/base/node/zip.i18n.json new file mode 100644 index 00000000000..feb34282ee7 --- /dev/null +++ b/i18n/hun/src/vs/base/node/zip.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "notFound": "{0} nem található a zipen belül." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/base/parts/quickopen/browser/quickOpenModel.i18n.json b/i18n/hun/src/vs/base/parts/quickopen/browser/quickOpenModel.i18n.json new file mode 100644 index 00000000000..fb2705ff3c8 --- /dev/null +++ b/i18n/hun/src/vs/base/parts/quickopen/browser/quickOpenModel.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpenAriaLabelEntry": "{0}, választó", + "quickOpenAriaLabel": "választó" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/base/parts/quickopen/browser/quickOpenWidget.i18n.json b/i18n/hun/src/vs/base/parts/quickopen/browser/quickOpenWidget.i18n.json new file mode 100644 index 00000000000..095139488e0 --- /dev/null +++ b/i18n/hun/src/vs/base/parts/quickopen/browser/quickOpenWidget.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpenAriaLabel": "Gyorsválasztó. Kezdjen el gépelni a találati lista szűkítéséhez!", + "treeAriaLabel": "Gyorsválasztó" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/base/parts/tree/browser/treeDefaults.i18n.json b/i18n/hun/src/vs/base/parts/tree/browser/treeDefaults.i18n.json new file mode 100644 index 00000000000..1bb27ebb323 --- /dev/null +++ b/i18n/hun/src/vs/base/parts/tree/browser/treeDefaults.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "collapse": "Összecsukás" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/code/electron-main/menus.i18n.json b/i18n/hun/src/vs/code/electron-main/menus.i18n.json new file mode 100644 index 00000000000..72b0fe63086 --- /dev/null +++ b/i18n/hun/src/vs/code/electron-main/menus.i18n.json @@ -0,0 +1,178 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "mFile": "&&Fájl", + "mEdit": "Sz&&erkesztés", + "mSelection": "Kijelölé&&s", + "mView": "&&Nézet", + "mGoto": "U&&grás", + "mDebug": "Hi&&bakeresés", + "mWindow": "Ablak", + "mHelp": "&&Súgó", + "mTask": "&&Feladatok", + "miNewWindow": "Új &&ablak", + "mAbout": "A(z) {0} névjegye", + "mServices": "Szolgáltatások", + "mHide": "{0} elrejtése", + "mHideOthers": "Egyebek elrejtése", + "mShowAll": "Az összes megjelenítése", + "miQuit": "Kilépés innen: {0}", + "miNewFile": "Ú&&j fájl", + "miOpen": "&&Megnyitás", + "miOpenFolder": "Ma&&ppa megnyitása", + "miOpenFile": "&&Fájl megnyitása", + "miOpenRecent": "&&Legutóbbi megnyitása", + "miSave": "Menté&&s", + "miSaveAs": "M&&entés másként", + "miSaveAll": "Összes men&&tése", + "miAutoSave": "Automatikus mentés", + "miRevert": "Fájl &&visszaállítása", + "miCloseWindow": "Ablak be&&zárása", + "miCloseFolder": "Mappa &&bezárása", + "miCloseEditor": "Szer&&kesztÅ‘ablak bezárása", + "miExit": "&&Kilépés", + "miOpenSettings": "&&Beállítások", + "miOpenKeymap": "&&Billentyűparancsok", + "miOpenKeymapExtensions": "Billentyűparancs-kiegészítÅ‘&&k", + "miOpenSnippets": "Felhasználói kód&&részletek", + "miSelectColorTheme": "Szín&&téma", + "miSelectIconTheme": "Fájl&&ikonok témája", + "miPreferences": "&&Beállítások", + "miReopenClosedEditor": "Bezárt szerkesztÅ‘ablak ú&&jranyitása", + "miMore": "&&Továbbiak...", + "miClearRecentOpen": "Leg&&utóbbi fájlok listájának törlése", + "miUndo": "&&Visszavonás", + "miRedo": "Ú&&jra", + "miCut": "&&Kivágás", + "miCopy": "&&Másolás", + "miPaste": "&&Beillesztés", + "miFind": "K&&eresés", + "miReplace": "&&Csere", + "miFindInFiles": "Keresés a &&fájlokban", + "miReplaceInFiles": "Csere a fá&&jlokban", + "miEmmetExpandAbbreviation": "Emmet: Rövidítés k&&ibontása", + "miShowEmmetCommands": "E&&mmet...", + "miToggleLineComment": "&&Egysoros megjegyzés ki-/bekapcsolása", + "miToggleBlockComment": "Me&&gjegyzésblokk ki-/bekapcsolása", + "miMultiCursorAlt": "Alt+kattintás használata több kurzorhoz", + "miMultiCursorCmd": "Cmd+kattintás használata több kurzorhoz", + "miMultiCursorCtrl": "Ctrl+kattintás használata több kurzorhoz", + "miInsertCursorAbove": "&&Kurzor beszúrása egy sorral feljebb", + "miInsertCursorBelow": "Ku&&rzor beszúrása egy sorral feljebb", + "miInsertCursorAtEndOfEachLineSelected": "K&&urzor beszúrása a sorok végére", + "miAddSelectionToNextFindMatch": "&&KövetkezÅ‘ találat kijelölése", + "miAddSelectionToPreviousFindMatch": "&&ElÅ‘zÅ‘ találat kijelölése", + "miSelectHighlights": "Az összes keresési találat &&kijelölése", + "miCopyLinesUp": "Sor másolása eggyel &&feljebb", + "miCopyLinesDown": "Sor másolása eggyel &&lejjebb", + "miMoveLinesUp": "Sor feljebb &&helyezése", + "miMoveLinesDown": "Sor lejje&&bb helyezése", + "miSelectAll": "Az össze&&s kijelölése", + "miSmartSelectGrow": "Kijelölés &&bÅ‘vítése", + "miSmartSelectShrink": "Ki&&jelölés szűkítése", + "miViewExplorer": "Fájlk&&ezelÅ‘", + "miViewSearch": "&&Keresés", + "miViewSCM": "&&Verziókezelés", + "miViewDebug": "&&Hibakeresés", + "miViewExtensions": "Kiegé&&szítÅ‘k", + "miToggleOutput": "&&Kimenet", + "miToggleDebugConsole": "Hi&&bakeresési konzol", + "miToggleIntegratedTerminal": "Beépített term&&inál", + "miMarker": "&&Problémák", + "miAdditionalViews": "További &&nézetek", + "miCommandPalette": "Paran&&cskatalógus...", + "miToggleFullScreen": "&&Teljes képernyÅ‘ be- és kikapcsolása", + "miToggleZenMode": "Zen mód be- és kikapcsolása", + "miToggleMenuBar": "Menüsáv &&be- és kikapcsolása", + "miSplitEditor": "SzerkesztÅ‘ablak k&&ettéosztása", + "miToggleEditorLayout": "SzerkesztÅ‘ablak-csoport e&&lrendezésének váltása", + "miToggleSidebar": "&&Oldalsáv be- és kikapcsolása", + "miMoveSidebarRight": "Oldalsáv áthelyezése &&jobbra", + "miMoveSidebarLeft": "Oldalsáv áthelyezése &&balra", + "miTogglePanel": "&&Panel be- és kikapcsolása", + "miHideStatusbar": "Ãllapotsor &&elrejtése", + "miShowStatusbar": "Ãllapotsor &&megjelenítése", + "miHideActivityBar": "&&Tevékenységsáv elrejtése", + "miShowActivityBar": "&&Tevékenységsáv megjelenítése", + "miToggleWordWrap": "&&Sortörés be- és kikapcsolása", + "miToggleRenderWhitespace": "S&&zóközök kirajzolásának be- és kikapcsolása", + "miToggleRenderControlCharacters": "&&VezérlÅ‘karakterek kirajzolásának be- és kikapcsolása", + "miZoomIn": "&&Nagyítás", + "miZoomOut": "&&Kicsinyítés", + "miZoomReset": "&&Nagyítási szint alaphelyzetbe állítása", + "miBack": "&&Vissza", + "miForward": "&&ElÅ‘re", + "miNextEditor": "&&KövetkezÅ‘ szerkesztÅ‘ablak", + "miPreviousEditor": "&&ElÅ‘zÅ‘ szerkesztÅ‘ablak", + "miNextEditorInGroup": "KövetkezÅ‘ &&használt szerkesztÅ‘ablak a csoportban", + "miPreviousEditorInGroup": "KövetkezÅ‘ h&&asznált szerkesztÅ‘ablak a csoportban", + "miSwitchEditor": "Sz&&szerkesztÅ‘ablak váltása", + "miFocusFirstGroup": "&&ElsÅ‘ csoport", + "miFocusSecondGroup": "&&Második csoport", + "miFocusThirdGroup": "&&Harmadik csoport", + "miNextGroup": "&&KövetkezÅ‘ csoport", + "miPreviousGroup": "&&ElÅ‘zÅ‘ csoport", + "miSwitchGroup": "Csoport &&váltása", + "miGotoFile": "Ugrás &&fájlhoz...", + "miGotoSymbolInFile": "Ugrás szim&&bólumhoz egy fájlban...", + "miGotoSymbolInWorkspace": "Ugrás szimbólumhoz a &&munkaterületen...", + "miGotoDefinition": "Ugrás a &&definícióra", + "miGotoTypeDefinition": "Ugrás a &&típusdefinícióra", + "miGotoImplementation": "Ugrás az &&implementációra", + "miGotoLine": "&&Sor megkeresáse...", + "miStartDebugging": "Hibakeresés indítá&&sa", + "miStartWithoutDebugging": "Indítás hibakeresés &&nélkül", + "miStopDebugging": "Hibakeresés leállítá&&sa", + "miRestart Debugging": "Hibakeresés új&&raindítása", + "miOpenConfigurations": "&&Konfigurációk megnyitása", + "miAddConfiguration": "Konfiguráció hozzáadása...", + "miStepOver": "Ã&&tugrás", + "miStepInto": "&&Belépés", + "miStepOut": "&&Kilépés", + "miContinue": "&&Folytatás", + "miToggleBreakpoint": "&&Töréspont be- és kikapcsolása", + "miConditionalBreakpoint": "Feltételes törés&&pont", + "miColumnBreakpoint": "Töréspont &&oszlopnál", + "miFunctionBreakpoint": "Töréspont&&funkció...", + "miNewBreakpoint": "Ú&&j töréspont", + "miEnableAllBreakpoints": "Összes töréspont engedélyezése", + "miDisableAllBreakpoints": "Összes töréspont leti&<ása", + "miRemoveAllBreakpoints": "Összes töréspont eltávolítás&&a", + "miInstallAdditionalDebuggers": "Tovább&&i hibakeresÅ‘k telepítése", + "mMinimize": "Kis méret", + "mZoom": "Nagyítás", + "mBringToFront": "Legyen az összes elÅ‘térben", + "miSwitchWindow": "&&Ablak váltása...", + "miToggleDevTools": "&&FejlesztÅ‘i eszközök be- és kikapcsolása", + "miAccessibilityOptions": "&&KisegítÅ‘ lehetÅ‘ségek", + "miReportIssues": "&&Problémák jelentése", + "miWelcome": "ÃœdvözlÅ‘&&oldal", + "miInteractivePlayground": "&&Interaktív játszótér", + "miDocumentation": "&&Dokumentáció", + "miReleaseNotes": "&&Kiadási jegyzék", + "miKeyboardShortcuts": "Billentyűparancs-&&referencia", + "miIntroductoryVideos": "Bemutató&&videók", + "miTwitter": "&&Csatlakozzon hozzánk a Twitteren", + "miUserVoice": "Funkcióigények keresé&&se", + "miLicense": "&&Licenc megtekintése", + "miPrivacyStatement": "&&Adatvédelmi nyilatkozat", + "miAbout": "&&Névjegy", + "miRunTask": "&&Feladat futtatása...", + "miRestartTask": "F&&eladat újraindítása", + "miTerminateTask": "Felada&&t megszakítása", + "miBuildTask": "&&Buildelési feladat", + "miTestTask": "Tesztelési felad&&at", + "miShowTaskLog": "Feladat&&napló megtekintése", + "accessibilityOptionsWindowTitle": "KisegítÅ‘ lehetÅ‘ségek beállításai", + "miRestartToUpdate": "Újraindítás a frissítéshez...", + "miCheckingForUpdates": "Frissítések keresése...", + "miDownloadUpdate": "ElérhetÅ‘ frissítés letöltése", + "miDownloadingUpdate": "Frissítés letöltése...", + "miInstallingUpdate": "Frissítés telepítése...", + "miCheckForUpdates": "Frissítések keresése...", + "aboutDetail": "\nVerzió: {0}\nCommit: {1}\nDátum: {2}\nShell: {3}\nRendelÅ‘: {4}\nNode: {5}", + "okButton": "OK" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/code/electron-main/window.i18n.json b/i18n/hun/src/vs/code/electron-main/window.i18n.json new file mode 100644 index 00000000000..4acca80d5c4 --- /dev/null +++ b/i18n/hun/src/vs/code/electron-main/window.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "hiddenMenuBar": "A menüsáv továbbra is elréhetÅ‘ az **Alt** billentyű leütésével." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/code/electron-main/windows.i18n.json b/i18n/hun/src/vs/code/electron-main/windows.i18n.json new file mode 100644 index 00000000000..46afd591492 --- /dev/null +++ b/i18n/hun/src/vs/code/electron-main/windows.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ok": "OK", + "pathNotExistTitle": "Az elérési út nem létezik", + "pathNotExistDetail": "Úgy tűnik, hogy a(z) „{0}†elérési út már nem létezik a lemezen.", + "reopen": "Újranyitás", + "wait": "Várakozás tovább", + "close": "Bezárás", + "appStalled": "Az ablak nem válaszol", + "appStalledDetail": "Bezárhatja vagy újranyithatja az ablakot vagy várakozhat tovább.", + "appCrashed": "Az ablak összeomlott", + "appCrashedDetail": "Elnézést kérünk az okozott kellemetlenségért. Nyissa újra az ablakot, ha onnan szeretné folytatni a munkát, ahol abbahagyta." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/code/node/cliProcessMain.i18n.json b/i18n/hun/src/vs/code/node/cliProcessMain.i18n.json new file mode 100644 index 00000000000..fe8c039d35f --- /dev/null +++ b/i18n/hun/src/vs/code/node/cliProcessMain.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "notFound": "A(z) '{0}' kiegészítÅ‘ nem található.", + "notInstalled": "A(z) '{0}' kiegészítÅ‘ nincs telepítve.", + "useId": "Bizonyosodjon meg róla, hogy a kiegészítÅ‘ teljes azonosítóját használja, beleértve a kiadót, pl.: {0}", + "successVsixInstall": "A(z) '{0}' kiegszítÅ‘ sikeresen telepítve lett.", + "alreadyInstalled": "A(z) '{0}' kiegészítÅ‘ már telepítve van.", + "foundExtension": "A(z) '{0}' kiegészítÅ‘ megtalálva a piactéren.", + "installing": "Telepítés...", + "successInstall": "A(z) '{0}' v{1} kiegészítÅ‘ sikeresen telepítve lett.", + "uninstalling": "{0} eltávolítása...", + "successUninstall": "A(z) '{0}' kiegészítÅ‘ sikeresen el lett távolítva." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/hun/src/vs/editor/common/config/commonEditorConfig.i18n.json new file mode 100644 index 00000000000..1e9ce0d9025 --- /dev/null +++ b/i18n/hun/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -0,0 +1,88 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorConfigurationTitle": "SzerkesztÅ‘ablak", + "fontFamily": "Ez a beállítás a betűkészletet határozza meg.", + "fontWeight": "Meghatározza a betűvastagságot.", + "fontSize": "Meghatározza a betű méretét, pixelekben.", + "lineHeight": "Meghatározza a sormagasságot. A 0 érték használata esetén a sormagasság a fontSize értékébÅ‘l van számolva.", + "letterSpacing": "Meghatározza a betűközt, pixelekben.", + "lineNumbers": "Meghatározza, hogy megjelenjenek-e a sorszámok. A lehetséges értékek 'on', 'off' és 'relative'. A 'relative' érték használata esetén a kurzor aktuális pozíciójához képest számított sorszám jelenik meg.", + "rulers": "Azon oszlopok listája, ahol függÅ‘leges segédvonal jelenjen meg.", + "wordSeparators": "Azon karakterek listája, amelyek szóelválasztónak vannak tekintve szavakkal kapcsolatos navigáció vagy műveletek során.", + "tabSize": "Egy tabulátor hány szóköznek felel meg. Ez a beállítás felülírásra kerül a fájl tartalma alapján, ha az 'editor.detectIndentation' beállítás aktív.", + "tabSize.errorMessage": "A várt érték 'number' típusú. Megjegyzés: az \"auto\" értéket az 'editor.detectIndentation' beállítás helyettesíti.", + "insertSpaces": "Tabulátor billentyű lenyomásánál szóközök legyenek-e beszúrva. Ez a beállítás felülírásra kerül a fájl tartalma alapján, ha az 'editor.detectIndentation' beállítás aktív.", + "insertSpaces.errorMessage": "A várt érték 'boolean' típusú. Megjegyzés: az \"auto\" értéket az 'editor.detectIndentation' beállítás helyettesíti.", + "detectIndentation": "Fájl megnyitásakor az `editor.tabSize` és az `editor.insertSpaces` értéke a fájl tartalma alapján lesz meghatározva.", + "roundedSelection": "Itt adható meg, hogy a kijelölt elemek sarkai lekerekítettek legyenek-e", + "scrollBeyondLastLine": "Meghatározza, hogy a szerkesztÅ‘ablak görgethetÅ‘-e az utolsó sor után.", + "minimap.enabled": "Meghatározza, hogy megjelenjen-e a kódtérkép.", + "minimap.showSlider": "Meghatározza, hogy automatikusan el legyen-e rejtve a kódtérképes görgetÅ‘sáv.", + "minimap.renderCharacters": "Meghatározza, hogy a tényleges karakterek legyenek-e megjelenítve (színes téglalapok helyett)", + "minimap.maxColumn": "Meghatározza, hogy a kódtérképen legfeljebb hány oszlop legyen kirajzolva.", + "find.seedSearchStringFromSelection": "Meghatározza, hogy a keresés modulba automatikusan bekerüljön-e a szerkesztÅ‘ablakban kiválasztott szöveg.", + "find.autoFindInSelection": "Meghatározza, hogy a keresés a kijelölésben beállítás be van-e kapcsolva, ha több karakternyi vagy sornyi szöveg ki van jelölve a szerkesztÅ‘ablakban.", + "wordWrap.off": "A sorok soha nem lesznek tördelve.", + "wordWrap.on": "A sorok tördelve lesznek a nézetablak szélességénél.", + "wordWrap.wordWrapColumn": "A sorok tördelve lesznek az `editor.wordWrapColumn` oszlopnál.", + "wordWrap.bounded": "A sorok tördelve lesznek a nézetablak szélességének és az `editor.wordWrapColumn` értékének minimumánál.", + "wordWrap": "Ez a beállítás meghatározza, hogy a sorok hogyan legyenek tördelve. Lehetséges értékek:\n- 'off' (nincs sortörés)\n- 'on' (sortörés a nézetablakban)\n- 'wordWrapColumn' (sortörés az `editor.wordWrapColumn` oszlopnál) vagy\n- 'bounded' (sortörés az `editor.wordWrapColumn` és a nézetablak minimumánál)", + "wordWrapColumn": "Meghatározza a sortöréshez használt oszlopszámot a szerkesztÅ‘ablakban, ha az `editor.wordWrap` értéke 'wordWrapColumn' vagy 'bounded'.", + "wrappingIndent": "Meghatározza a tördelt sorok behúzását. Értéke 'none', 'same' vagy 'indent' lehet.", + "mouseWheelScrollSensitivity": "Az egér görgetési eseményeinél keletkezÅ‘ `deltaX` és `deltaY` paraméterek szorzója", + "multiCursorModifier.ctrlCmd": "Windows és Linux alatt a `Control`, OSX alatt a `Command` billentyűt jelenti.", + "multiCursorModifier.alt": "Windows és Linux alatt az `Alt`, OSX alatt az `Option` billentyűt jelenti.", + "multiCursorModifier": "Több kurzor hozzáadásához használt módosítóbillentyű. A `ctrlCmd` Windows és Linux alatt a `Control`, OSX alatt a `Command` billentyűt jelenti. A Definíció megkeresése és Hivatkozás megnyitása egérgesztusok automatikusan alkalmazkodnak úgy, hogy ne ütközzenek a többkurzorhoz tartozó módosítóval.", + "quickSuggestions.strings": "Kiegészítési javaslatok engedélyezése karakterláncokban (stringekben)", + "quickSuggestions.comments": "Kiegészítési javaslatok engedélyezése megjegyzésekben", + "quickSuggestions.other": "Kiegészítési javaslatok engedélyezése karakterláncokon (stringeken) és megjegyzéseken kívül", + "quickSuggestions": "Meghatározza, hogy automatikusan megjelenjenek-e a javaslatok gépelés közben", + "quickSuggestionsDelay": "Meghatározza, hogy hány ezredmásodperc késleltetéssel jelenjenek meg a kiegészítési javaslatok", + "parameterHints": "Paraméterinformációkat és típusinformációkat tartalmazó felugró ablak engedélyezése gépelés közben", + "autoClosingBrackets": "Meghatározza, hogy a szerkesztÅ‘ automatikusan beszúrja-e a nyitó zárójelek záró párját", + "formatOnType": "Meghatározza, hogy a szerkesztÅ‘ automatikusan formázza-e a sort a gépelés után", + "formatOnPaste": "Meghatározza, hogy a szerkesztÅ‘ automatikusan formázza-e a beillesztett tartalmat. Ehhez szükség van egy formázóra, illetve a formázónak tudnia kell a dokumentum egy részét formázni.", + "suggestOnTriggerCharacters": "Itt adható meg, hogy eseményindító karakterek beírásakor automatikusan megjelenjenek-e a javaslatok", + "acceptSuggestionOnEnter": "Meghatározza, hogy a javaslatok az 'Enter' gomb leütésére is el legyenek fogadva a 'Tab' mellett. Segít feloldani a bizonytalanságot az új sorok beillesztése és a javaslatok elfogadása között. A 'smart' érték azt jelenti, hogy csak akkor fogadja el a javaslatot az Enter leütése esetén, ha az módosítja a szöveget.", + "acceptSuggestionOnCommitCharacter": "Meghatározza, hogy a javaslaok a zárókarakterek leütésére is el legyenek fogadva. A JavaScriptben például a pontosvesszÅ‘ (';') számít zárókarakternek, leütésére a javaslat elfogadásra kerül és beillesztÅ‘dik az adott karakter. ", + "snippetSuggestions": "Meghatározza, hogy a kódtöredékek megjelenjenek-e a javaslatok között, illetve hogy hogyan legyenek rendezve.", + "emptySelectionClipboard": "Meghatározza, hogy kijelölés nélküli másolás esetén a teljes sor legyen-e másolva.", + "wordBasedSuggestions": "Meghatározza, hogy a kiegészítések listája a dokumentumban lévÅ‘ szövegek alapján legyen-e meghatározva.", + "suggestFontSize": "Az ajánlásokat tartalmazó modul betűmérete", + "suggestLineHeight": "Az ajánlásokat tartalmazó modul sormagassága", + "selectionHighlight": "Itt adható meg, hogy a szerkesztÅ‘ kiemelje-e a kijelöléshez hasonló találatokat", + "occurrencesHighlight": "Meghatározza, hogy a szerkesztÅ‘ablakban ki legyenek-e emelve a szimbólum szemantikailag hozzá tartozó elÅ‘fordulásai.", + "overviewRulerLanes": "Meghatározza, hogy hány dekoráció jelenhet meg azonos pozícióban az áttekintÅ‘ sávon.", + "overviewRulerBorder": "Meghatározza, hogy legyen-e kerete az áttekintÅ‘ sávnak.", + "cursorBlinking": "Meghatározza a kurzor animációjának stílusát. Lehetséges értékek: 'blink', 'smooth', 'phase', 'expand' vagy 'solid'", + "mouseWheelZoom": "A szerkesztÅ‘ablak betűtípusának nagyítása vagy kicsinyítése az egérgörgÅ‘ Ctrl lenyomása mellett történÅ‘ használata esetén", + "cursorStyle": "Meghatározza a kurzor stílusát. Lehetséges értékek: 'block', 'block-outline', 'line', 'line-thin', 'underline' vagy 'underline-thin'", + "fontLigatures": "Engedélyezi a betűtípusban található ligatúrák használatát", + "hideCursorInOverviewRuler": "Meghatározza, hogy a kurzor pozíciója el legyen-e rejtve az áttekintÅ‘ sávon.", + "renderWhitespace": "Meghatározza, hogy a szerkesztÅ‘ablakban hogyan legyenek kirajzolva a szóköz karakterek. Lehetséges értékek: 'none', 'boundary', vagy 'all'. A 'boundary' beállítás esetén, ha szavak között egyetlen szóköz található, akkor az nem lesz kirajzolva.", + "renderControlCharacters": "Meghatározza, hogy a szerkesztÅ‘ablakban ki legyenek-e rajzolva a vezérlÅ‘karakterek.", + "renderIndentGuides": "Meghatározza, hogy a szerkesztÅ‘ablakban ki legyenek-e rajzolva az indentálási segédvonalak.", + "renderLineHighlight": "Meghatározza, hogy a szerkesztÅ‘ablakban hogyan legyen kirajzolva az aktuális sor kiemelése. Lehetséges értékek: 'none', 'gutter', 'line', vagy 'all'.", + "codeLens": "Meghatározza, hogy megjelenjenek-e a kódlencsék", + "folding": "Meghatározza, hogy engedélyezve van-e a kódrészletek bezárása a szerkesztÅ‘ablakban.", + "showFoldingControls": "Meghatározza, hogy a kódrészletek bezárásához tartozó vezérlÅ‘elemek automatikusan el legyenek-e rejtve.", + "matchBrackets": "Zárójel kiválasztása esetén a hozzátartozó zárójel kiemelése.", + "glyphMargin": "Meghatározza, hogy legyen-e vertikális szimbólummargó a szerkesztÅ‘ablakban. A szimbólummargó elsÅ‘sorban hibakeresésnél van használva.", + "useTabStops": "Szóközök beillesztése és törlése során követve vannak a tabulátorok.", + "trimAutoWhitespace": "A sorok végén lévÅ‘, automatikusan beillesztett szóközök eltávolítása", + "stablePeek": "A betekintÅ‘ablakok maradjanak nyitva akkor is, ha duplán kattintanak a tartalmára vagy megnyomják az Escape gombot.", + "dragAndDrop": "Meghatározza, hogy a szerkesztÅ‘ablakban engedélyezett-e a kijelölt szövegrészletek áhelyezése húzással.", + "accessibilitySupport.auto": "A szerkesztÅ‘ a platform által biztosított API-kat használja annak megállapításához, hogy van-e képernyÅ‘olvasó csatlakoztatva.", + "accessibilitySupport.on": "A szerkesztÅ‘ folyamatos képernyÅ‘olvasóval való használatára van optimalizálva.", + "accessibilitySupport.off": "A szerkesztÅ‘ soha nincs képernyÅ‘olvasó használatára optimalizálva.", + "accessibilitySupport": "Meghatározza, hogy a szerkesztÅ‘ olyan módban fusson-e, ami optimalizálva van képernyÅ‘olvasóval való használathoz.", + "links": "Meghatározza, hogy a szerkesztÅ‘ablak érzékelje-e a hivatkozásokat, és kattinthatóvá tegye-e Å‘ket.", + "sideBySide": "Meghatározza, hogy a differenciaszerkesztÅ‘ ablakban egymás mellett vagy a sorban jelenjenek meg az eltérések", + "ignoreTrimWhitespace": "Meghatározza, hogy a differenciaszerkesztÅ‘ ablakban megjelenjenek-e a sor elején vagy végén a szóközökben talált különbségek", + "renderIndicators": "Meghatározza, hogy a differenciaszerkesztÅ‘ ablakban megjelenjenek-e a +/- jelzÅ‘k az hozzáadott/eltávolított változásoknál", + "selectionClipboard": "Meghatározza-e, hogy támogatva van-e az elsÅ‘dleges vágólap Linux alatt" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/common/config/editorOptions.i18n.json b/i18n/hun/src/vs/editor/common/config/editorOptions.i18n.json new file mode 100644 index 00000000000..6a2e0478211 --- /dev/null +++ b/i18n/hun/src/vs/editor/common/config/editorOptions.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "accessibilityOffAriaLabel": "A szerkesztÅ‘ablak jelenleg nem elérhetÅ‘. Nyomja meg az Alt+F1-et a beállítási lehetÅ‘ségek megjelenítéséhez!", + "editorViewAccessibleLabel": "SzerkesztÅ‘ablak tartalma" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/common/controller/cursor.i18n.json b/i18n/hun/src/vs/editor/common/controller/cursor.i18n.json new file mode 100644 index 00000000000..6b33fa4e18e --- /dev/null +++ b/i18n/hun/src/vs/editor/common/controller/cursor.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "corrupt.commands": "Váratlan kivétel egy parancs végrehajtása során." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/common/model/textModelWithTokens.i18n.json b/i18n/hun/src/vs/editor/common/model/textModelWithTokens.i18n.json new file mode 100644 index 00000000000..41687561a2e --- /dev/null +++ b/i18n/hun/src/vs/editor/common/model/textModelWithTokens.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "mode.tokenizationSupportFailed": "Ebben az üzemmódban nem sikerült lexikális elemekre bontani a bemenetet." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/common/modes/modesRegistry.i18n.json b/i18n/hun/src/vs/editor/common/modes/modesRegistry.i18n.json new file mode 100644 index 00000000000..26fe7e29f4c --- /dev/null +++ b/i18n/hun/src/vs/editor/common/modes/modesRegistry.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "plainText.alias": "Egyszerű szöveg" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/common/services/bulkEdit.i18n.json b/i18n/hun/src/vs/editor/common/services/bulkEdit.i18n.json new file mode 100644 index 00000000000..b0bbd29edb0 --- /dev/null +++ b/i18n/hun/src/vs/editor/common/services/bulkEdit.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "conflict": "A következÅ‘ fájlok módosultak idÅ‘közben: {0}", + "summary.0": "Nem történtek változtatások", + "summary.nm": "{0} változtatást végzett {0} fájlban", + "summary.n0": "{0} változtatást végzett egy fájlban" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/common/services/modeServiceImpl.i18n.json b/i18n/hun/src/vs/editor/common/services/modeServiceImpl.i18n.json new file mode 100644 index 00000000000..b85462146b6 --- /dev/null +++ b/i18n/hun/src/vs/editor/common/services/modeServiceImpl.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.languages": "Nyelvdeklarációkat szolgáltat.", + "vscode.extension.contributes.languages.id": "A nyelv azonosítója", + "vscode.extension.contributes.languages.aliases": "A nyelv kiegészítÅ‘ nevei.", + "vscode.extension.contributes.languages.extensions": "A nyelvhez hozzárendelt fájlkiterjesztések.", + "vscode.extension.contributes.languages.filenames": "A nyelvhez hozzárendelt fájlnevek.", + "vscode.extension.contributes.languages.filenamePatterns": "A nyelvhez hozzárendelt globális minták.", + "vscode.extension.contributes.languages.mimetypes": "A nyelvhez hozzárendelt MIME-típusok.", + "vscode.extension.contributes.languages.firstLine": "Reguláris kifejezés, ami az adott nyelven írt fájl elsÅ‘ sorára illeszkedik.", + "vscode.extension.contributes.languages.configuration": "A nyelvhez tartozó konfigurációkat tartalmazó fájl relatív elérési útja." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/common/services/modelServiceImpl.i18n.json b/i18n/hun/src/vs/editor/common/services/modelServiceImpl.i18n.json new file mode 100644 index 00000000000..a12e01358bb --- /dev/null +++ b/i18n/hun/src/vs/editor/common/services/modelServiceImpl.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "diagAndSourceMultiline": "[{0}]\n{1}", + "diagAndSource": "[{0}] {1}" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/common/view/editorColorRegistry.i18n.json b/i18n/hun/src/vs/editor/common/view/editorColorRegistry.i18n.json new file mode 100644 index 00000000000..94d90edc071 --- /dev/null +++ b/i18n/hun/src/vs/editor/common/view/editorColorRegistry.i18n.json @@ -0,0 +1,24 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "lineHighlight": "A kurzor pozícióján található sor kiemelési háttérszíne.", + "lineHighlightBorderBox": "A kurzor pozícióján található sor keretszíne.", + "rangeHighlight": "A kiemelt területek háttérszíne, pl. a gyors megnyitás és keresés funkcióknál.", + "caret": "A szerkesztÅ‘ablak kurzorának színe.", + "editorWhitespaces": "A szerkesztÅ‘ablakban található szóköz karakterek színe.", + "editorIndentGuides": "A szerkesztÅ‘ablak segédvonalainak színe.", + "editorLineNumbers": "A szerkesztÅ‘ablak sorszámainak színe.", + "editorRuler": "A szerkesztÅ‘ablak sávjainak színe.", + "editorCodeLensForeground": "A szerkesztÅ‘ablakban található kódlencsék elÅ‘térszíne", + "editorBracketMatchBackground": "Hozzátartozó zárójelek háttérszíne", + "editorBracketMatchBorder": "Az összetartozó zárójelek dobozának színe", + "editorOverviewRulerBorder": "Az áttekintÅ‘ sáv keretszíne.", + "editorGutter": "A szerkesztÅ‘ablag margójának háttérszíne. A margón található a szimbólummargó és a sorszámok.", + "errorForeground": "A hibákat jelzÅ‘ hullámvonal elÅ‘térszíne a szerkesztÅ‘ablakban.", + "errorBorder": "A hibákat jelzÅ‘ hullámvonal keretszíne a szerkesztÅ‘ablakban.", + "warningForeground": "A figyelmeztetéseket jelzÅ‘ hullámvonal elÅ‘térszíne a szerkesztÅ‘ablakban.", + "warningBorder": "A figyelmeztetéseket jelzÅ‘ hullámvonal keretszíne a szerkesztÅ‘ablakban." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/bracketMatching/common/bracketMatching.i18n.json b/i18n/hun/src/vs/editor/contrib/bracketMatching/common/bracketMatching.i18n.json new file mode 100644 index 00000000000..647a263affc --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/bracketMatching/common/bracketMatching.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "smartSelect.jumpBracket": "Ugrás a zárójelre" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/caretOperations/common/caretOperations.i18n.json b/i18n/hun/src/vs/editor/contrib/caretOperations/common/caretOperations.i18n.json new file mode 100644 index 00000000000..1fc37d07684 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/caretOperations/common/caretOperations.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "caret.moveLeft": "Kurzor mozgatása balra", + "caret.moveRight": "Kurzor mozgatása jobbra" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/caretOperations/common/transpose.i18n.json b/i18n/hun/src/vs/editor/contrib/caretOperations/common/transpose.i18n.json new file mode 100644 index 00000000000..e8cbbca5cf4 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/caretOperations/common/transpose.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "transposeLetters.label": "Betűk megcserélése" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/clipboard/browser/clipboard.i18n.json b/i18n/hun/src/vs/editor/contrib/clipboard/browser/clipboard.i18n.json new file mode 100644 index 00000000000..09439c237cb --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/clipboard/browser/clipboard.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "actions.clipboard.cutLabel": "Kivágás", + "actions.clipboard.copyLabel": "Másolás", + "actions.clipboard.pasteLabel": "Beillesztés", + "actions.clipboard.copyWithSyntaxHighlightingLabel": "Másolás szintaktikai kiemeléssel" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/comment/common/comment.i18n.json b/i18n/hun/src/vs/editor/contrib/comment/common/comment.i18n.json new file mode 100644 index 00000000000..219553bdc4e --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/comment/common/comment.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "comment.line": "Egysoros megjegyzés ki-/bekapcsolása", + "comment.line.add": "Egysoros megjegyzés hozzáadása", + "comment.line.remove": "Egysoros megjegyzés eltávolítása", + "comment.block": "Megjegyzésblokk ki-/bekapcsolása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/contextmenu/browser/contextmenu.i18n.json b/i18n/hun/src/vs/editor/contrib/contextmenu/browser/contextmenu.i18n.json new file mode 100644 index 00000000000..78d9a20aae1 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/contextmenu/browser/contextmenu.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "action.showContextMenu.label": "SzerkesztÅ‘ablak helyi menüjének megjelenítése" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/find/browser/findWidget.i18n.json b/i18n/hun/src/vs/editor/contrib/find/browser/findWidget.i18n.json new file mode 100644 index 00000000000..2e445d0ec2e --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/find/browser/findWidget.i18n.json @@ -0,0 +1,21 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "label.find": "Keresés", + "placeholder.find": "Keresés", + "label.previousMatchButton": "ElÅ‘zÅ‘ találat", + "label.nextMatchButton": "KövetkezÅ‘ találat", + "label.toggleSelectionFind": "Keresés kijelölésben", + "label.closeButton": "Bezárás", + "label.replace": "Csere", + "placeholder.replace": "Csere", + "label.replaceButton": "Csere", + "label.replaceAllButton": "Az összes elÅ‘fordulás cseréje", + "label.toggleReplaceButton": "Váltás csere módra", + "title.matchesCountLimit": "Csak az elsÅ‘ 999 találat van kiemelve, de minden keresési művelet a teljes szöveggel dolgozik.", + "label.matchesLocation": "{0} (összesen {1})", + "label.noResults": "Nincs eredmény" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/find/common/findController.i18n.json b/i18n/hun/src/vs/editor/contrib/find/common/findController.i18n.json new file mode 100644 index 00000000000..4b84cd4d15b --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/find/common/findController.i18n.json @@ -0,0 +1,18 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "startFindAction": "Keresés", + "findNextMatchAction": "KövetkezÅ‘ találat", + "findPreviousMatchAction": "ElÅ‘zÅ‘ találat", + "nextSelectionMatchFindAction": "KövetkezÅ‘ kijelölés", + "previousSelectionMatchFindAction": "ElÅ‘zÅ‘ kijelölés", + "startReplace": "Csere", + "addSelectionToNextFindMatch": "Kijelölés hozzáadása a következÅ‘ keresési találathoz", + "addSelectionToPreviousFindMatch": "Kijelölés hozzáadása az elÅ‘zÅ‘ keresési találathoz", + "moveSelectionToNextFindMatch": "Utolsó kijelölés áthelyezése a következÅ‘ keresési találatra", + "moveSelectionToPreviousFindMatch": "Utolsó kijelölés áthelyezése az elÅ‘zÅ‘ keresési találatra", + "changeAll.label": "Minden elÅ‘fordulás módosítása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/folding/browser/folding.i18n.json b/i18n/hun/src/vs/editor/contrib/folding/browser/folding.i18n.json new file mode 100644 index 00000000000..07da29ad41a --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/folding/browser/folding.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "unfoldAction.label": "Kibontás", + "unFoldRecursivelyAction.label": "Kibontás rekurzívan", + "foldAction.label": "Bezárás", + "foldRecursivelyAction.label": "Bezárás rekurzívan", + "foldAllAction.label": "Az összes bezárása", + "unfoldAllAction.label": "Az összes kinyitása", + "foldLevelAction.label": "{0} szintű blokkok bezárása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/format/browser/formatActions.i18n.json b/i18n/hun/src/vs/editor/contrib/format/browser/formatActions.i18n.json new file mode 100644 index 00000000000..6ef4ffd2eed --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/format/browser/formatActions.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "hint11": "Egy formázást végzett a(z) {0}. sorban", + "hintn1": "{0} formázást végzett a(z) {1}. sorban", + "hint1n": "Egy formázást végzett a(z) {0}. és {1}. sorok között", + "hintnn": "{0} formázást végzett a(z) {1}. és {2}. sorok között", + "formatDocument.label": "Dokumentum formázása", + "formatSelection.label": "Kijelölt tartalom formázása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/hun/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..50e0679aba9 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "Nem található a(z) '{0}' definíciója", + "generic.noResults": "Definíció nem található", + "meta.title": " – {0} definíció", + "actions.goToDecl.label": "Ugrás a definícióra", + "actions.goToDeclToSide.label": "Definíció megnyitása oldalt", + "actions.previewDecl.label": "Betekintés a definícióba", + "goToImplementation.noResultWord": "Nem található a(z) '{0}' implementációja", + "goToImplementation.generic.noResults": "Implementáció nem található", + "meta.implementations.title": " – {0} implementáció", + "actions.goToImplementation.label": "Ugrás az implementációra", + "actions.peekImplementation.label": "Betekintés az implementációba", + "goToTypeDefinition.noResultWord": "Nem található a(z) '{0}' típusdefiníciója", + "goToTypeDefinition.generic.noResults": "Típusdefiníció nem található", + "meta.typeDefinitions.title": " – {0} típusdefiníció", + "actions.goToTypeDefinition.label": "Ugrás a típusdefinícióra", + "actions.peekTypeDefinition.label": "Betekintés a típusdefinícióba" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/hun/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..782190fef04 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "Kattintson {0} definíció megjelenítéséhez." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json b/i18n/hun/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json new file mode 100644 index 00000000000..ce65a365e45 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "title.wo_source": "({0}/{1})", + "markerAction.next.label": "KövetkezÅ‘ hiba vagy figyelmeztetés", + "markerAction.previous.label": "ElÅ‘zÅ‘ hiba vagy figyelmeztetés", + "editorMarkerNavigationError": "A szerkesztÅ‘ablak jelzÅ‘navigációs moduljának színe hiba esetén.", + "editorMarkerNavigationWarning": "A szerkesztÅ‘ablak jelzÅ‘navigációs moduljának színe figyelmeztetés esetén.", + "editorMarkerNavigationBackground": "A szerkesztÅ‘ablak jelzÅ‘navigációs moduljának háttérszíne." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/hover/browser/hover.i18n.json b/i18n/hun/src/vs/editor/contrib/hover/browser/hover.i18n.json new file mode 100644 index 00000000000..e9de48281ee --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/hover/browser/hover.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "showHover": "Súgószöveg megjelenítése" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/hover/browser/modesContentHover.i18n.json b/i18n/hun/src/vs/editor/contrib/hover/browser/modesContentHover.i18n.json new file mode 100644 index 00000000000..a9cab1dd0d5 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/hover/browser/modesContentHover.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "modesContentHover.loading": "Betöltés..." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.i18n.json b/i18n/hun/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.i18n.json new file mode 100644 index 00000000000..0339e509b33 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "InPlaceReplaceAction.previous.label": "Csere az elÅ‘zÅ‘ értékre", + "InPlaceReplaceAction.next.label": "Csere a következÅ‘ értékre" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/indentation/common/indentation.i18n.json b/i18n/hun/src/vs/editor/contrib/indentation/common/indentation.i18n.json new file mode 100644 index 00000000000..4b8870d20ac --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/indentation/common/indentation.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "indentationToSpaces": "Indentálások átalakítása szóközökké", + "indentationToTabs": "Indentálások átalakítása tabulátorokká", + "configuredTabSize": "Beállított tabulátorméret", + "selectTabWidth": "Tabulátorméret kiválasztása az aktuális fájlhoz", + "indentUsingTabs": "Indentálás tabulátorral", + "indentUsingSpaces": "Indentálás szóközzel", + "detectIndentation": "Indentálás felismerése a tartalom alapján", + "editor.reindentlines": "Sorok újraindentálása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/linesOperations/common/linesOperations.i18n.json b/i18n/hun/src/vs/editor/contrib/linesOperations/common/linesOperations.i18n.json new file mode 100644 index 00000000000..d5c935359b0 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/linesOperations/common/linesOperations.i18n.json @@ -0,0 +1,25 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "lines.copyUp": "Sor másolása eggyel feljebb", + "lines.copyDown": "Sor másolása eggyel lejjebb", + "lines.moveUp": "Sor feljebb helyezése", + "lines.moveDown": "Sor lejjebb helyezése", + "lines.sortAscending": "Rendezés növekvÅ‘ sorrendben", + "lines.sortDescending": "Rendezés csökkenÅ‘ sorrendben", + "lines.trimTrailingWhitespace": "Sor végén található szóközök levágása", + "lines.delete": "Sor törlése", + "lines.indent": "Sor behúzása", + "lines.outdent": "Sor kihúzása", + "lines.insertBefore": "Sor beszúrása eggyel feljebb", + "lines.insertAfter": "Sor beszúrása eggyel lejjebb", + "lines.deleteAllLeft": "Balra lévÅ‘ tartalom törlése", + "lines.deleteAllRight": "Jobbra lévÅ‘ tartalom törlése", + "lines.joinLines": "Sorok egyesítése", + "editor.transpose": "A kurzor körüli karakterek felcserélése", + "editor.transformToUppercase": "Ãtalakítás nagybetűssé", + "editor.transformToLowercase": "Ãtalakítás kisbetűssé" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/links/browser/links.i18n.json b/i18n/hun/src/vs/editor/contrib/links/browser/links.i18n.json new file mode 100644 index 00000000000..ece9320a758 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/links/browser/links.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "links.navigate.mac": "Hivatkozott oldal megnyitása Cmd + kattintás paranccsal", + "links.navigate": "Hivatkozott oldal megnyitása Ctrl + kattintás paranccsal", + "links.navigate.al": "Hivatkozás megnyitása Alt + kattintás paranccsal", + "invalid.url": "A hivatkozást nem sikerült megnyitni, mert nem jól formázott: {0}", + "missing.url": "A hivatkozást nem sikerült megnyitni, hiányzik a célja.", + "label": "Hivatkozás megnyitása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/multicursor/common/multicursor.i18n.json b/i18n/hun/src/vs/editor/contrib/multicursor/common/multicursor.i18n.json new file mode 100644 index 00000000000..8aa3dbca9ff --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/multicursor/common/multicursor.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "mutlicursor.insertAbove": "Kurzor beszúrása egy sorral feljebb", + "mutlicursor.insertBelow": "Kurzor beszúrása egy sorral lejjebb", + "mutlicursor.insertAtEndOfEachLineSelected": "Kurzor beszúrása a sorok végére" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/parameterHints/browser/parameterHints.i18n.json b/i18n/hun/src/vs/editor/contrib/parameterHints/browser/parameterHints.i18n.json new file mode 100644 index 00000000000..973e6d7ae91 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/parameterHints/browser/parameterHints.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "parameterHints.trigger.label": "Paraméterinformációk megjelenítése" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.i18n.json b/i18n/hun/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.i18n.json new file mode 100644 index 00000000000..f05a169d614 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "hint": "{0}, információ" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/quickFix/browser/quickFixCommands.i18n.json b/i18n/hun/src/vs/editor/contrib/quickFix/browser/quickFixCommands.i18n.json new file mode 100644 index 00000000000..1fef02c03eb --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/quickFix/browser/quickFixCommands.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickFixWithKb": "Javítások megjelenítése ({0})", + "quickFix": "Javítások megjelenítése", + "quickfix.trigger.label": "Gyorsjavítás" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.i18n.json b/i18n/hun/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.i18n.json new file mode 100644 index 00000000000..bc4f4f5abd6 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "meta.titleReference": " – {0} referencia", + "references.action.label": "Minden hivatkozás megkeresése" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/referenceSearch/browser/referencesController.i18n.json b/i18n/hun/src/vs/editor/contrib/referenceSearch/browser/referencesController.i18n.json new file mode 100644 index 00000000000..b93a507d5d9 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/referenceSearch/browser/referencesController.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "labelLoading": "Betöltés..." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json b/i18n/hun/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json new file mode 100644 index 00000000000..4ab9002859c --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "aria.oneReference": "szimbólum a következÅ‘ helyen: {0}, sor: {1}, oszlop: {2}", + "aria.fileReferences.1": "Egy szimbólum a következÅ‘ helyen: {0}, teljes elérési út: {1}", + "aria.fileReferences.N": "{0} szimbólum a következÅ‘ helyen: {1}, teljes elérési út: {2}", + "aria.result.0": "Nincs találat", + "aria.result.1": "Egy szimbólum a következÅ‘ helyen: {0}", + "aria.result.n1": "{0} szimbólum a következÅ‘ helyen: {1}", + "aria.result.nm": "{0} szimbólum {1} fájlban" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json b/i18n/hun/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json new file mode 100644 index 00000000000..2701fadac42 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json @@ -0,0 +1,27 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "referencesFailre": "Nem sikerült feloldani a fájlt.", + "referencesCount": "{0} referencia", + "referenceCount": "{0} referencia", + "missingPreviewMessage": "elÅ‘nézet nem érhetÅ‘ el", + "treeAriaLabel": "Referenciák", + "noResults": "Nincs eredmény", + "peekView.alternateTitle": "Referenciák", + "peekViewTitleBackground": "A betekintÅ‘ablak címsorának háttérszíne.", + "peekViewTitleForeground": "A betekintÅ‘ablak címének színe.", + "peekViewTitleInfoForeground": "A betekintÅ‘ablak címsorában található információ színe.", + "peekViewBorder": "A betekintÅ‘ablak keretének és nyilainak színe.", + "peekViewResultsBackground": "A betekintÅ‘ablak eredménylistájának háttérszíne.", + "peekViewResultsMatchForeground": "A betekintÅ‘ablak eredménylistájában található sorhivatkozások elÅ‘térszíne.", + "peekViewResultsFileForeground": "A betekintÅ‘ablak eredménylistájában található fájlhivatkozások elÅ‘térszíne.", + "peekViewResultsSelectionBackground": "A betekintÅ‘ablak eredménylistájában kiválaszott elem háttérszíne.", + "peekViewResultsSelectionForeground": "A betekintÅ‘ablak eredménylistájában kiválaszott elem elÅ‘térszíne.", + "peekViewEditorBackground": "A betekintÅ‘ablak szerkesztÅ‘ablakának háttérszíne.", + "peekViewEditorGutterBackground": "A betekintÅ‘ablak szerkesztÅ‘ablakában található margó háttérszíne.", + "peekViewResultsMatchHighlight": "Kiemelt keresési eredmények színe a betekintÅ‘ablak eredménylistájában.", + "peekViewEditorMatchHighlight": "Kiemelt keresési eredmények színe a betekintÅ‘ablak szerkesztÅ‘ablakában." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/rename/browser/rename.i18n.json b/i18n/hun/src/vs/editor/contrib/rename/browser/rename.i18n.json new file mode 100644 index 00000000000..c6eac10add6 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/rename/browser/rename.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "no result": "Nincs eredmény.", + "aria": "'{0}' sikeresen át lett nevezve a következÅ‘re: '{1}'. Összefoglaló: {2}", + "rename.failed": "Az átnevezést nem sikerült végrehajtani.", + "rename.label": "Szimbólum átnevezése" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/rename/browser/renameInputField.i18n.json b/i18n/hun/src/vs/editor/contrib/rename/browser/renameInputField.i18n.json new file mode 100644 index 00000000000..cd26c078ae0 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/rename/browser/renameInputField.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "renameAriaLabel": "Ãtnevezésre szolgáló beviteli mezÅ‘. Adja meg az új nevet, majd nyomja meg az Enter gombot a változtatások elvégzéséhez." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/smartSelect/common/smartSelect.i18n.json b/i18n/hun/src/vs/editor/contrib/smartSelect/common/smartSelect.i18n.json new file mode 100644 index 00000000000..463be33cb03 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/smartSelect/common/smartSelect.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "smartSelect.grow": "Kijelölés bÅ‘vítése", + "smartSelect.shrink": "Kijelölés szűkítése" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/suggest/browser/suggestController.i18n.json b/i18n/hun/src/vs/editor/contrib/suggest/browser/suggestController.i18n.json new file mode 100644 index 00000000000..d7050253ff1 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/suggest/browser/suggestController.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "arai.alert.snippet": "A(z) '{0}' elfogadása a következÅ‘ szöveg beszúrását eredményezte: {1}", + "suggest.trigger.label": "Javaslatok megjelenítése" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json b/i18n/hun/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json new file mode 100644 index 00000000000..1ea907a2db0 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json @@ -0,0 +1,21 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorSuggestWidgetBackground": "A javaslatokat tartalmazó modul háttérszíne.", + "editorSuggestWidgetBorder": "A javaslatokat tartalmazó modul keretszíne.", + "editorSuggestWidgetForeground": "A javaslatokat tartalmazó modul elÅ‘térszíne.", + "editorSuggestWidgetSelectedBackground": "A javaslatokat tartalmazó modulban kiválasztott elem háttérszíne.", + "editorSuggestWidgetHighlightForeground": "Az illeszkedÅ‘ szövegrészletek kiemelése a javaslatok modulban.", + "readMore": "További információk megjelenítése...{0}", + "suggestionWithDetailsAriaLabel": "{0}, javaslat, részletekkel", + "suggestionAriaLabel": "{0}, javaslat", + "readLess": "Kevesebb információ megjelenítése...{0}", + "suggestWidget.loading": "Betöltés...", + "suggestWidget.noSuggestions": "Nincsenek javaslatok.", + "suggestionAriaAccepted": "{0}, elfogadva", + "ariaCurrentSuggestionWithDetails": "{0}, javaslat, részletekkel", + "ariaCurrentSuggestion": "{0}, javaslat" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode.i18n.json b/i18n/hun/src/vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode.i18n.json new file mode 100644 index 00000000000..dc4360652cb --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggle.tabMovesFocus": "Tab billentyűvel mozgatott fókusz ki- és bekapcsolása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.i18n.json b/i18n/hun/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.i18n.json new file mode 100644 index 00000000000..6192eaea44a --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "wordHighlight": "Szimbólumok háttérszíne olvasási hozzáférés, páldául változó olvasása esetén.", + "wordHighlightStrong": "Szimbólumok háttérszíne írási hozzáférés, páldául változó írása esetén." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.i18n.json b/i18n/hun/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.i18n.json new file mode 100644 index 00000000000..a40829f1ae6 --- /dev/null +++ b/i18n/hun/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "label.close": "Bezárás" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/electron-browser/textMate/TMSyntax.i18n.json b/i18n/hun/src/vs/editor/electron-browser/textMate/TMSyntax.i18n.json new file mode 100644 index 00000000000..be4ee2e7989 --- /dev/null +++ b/i18n/hun/src/vs/editor/electron-browser/textMate/TMSyntax.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "invalid.language": "Ismeretlen nyelv található a következÅ‘ben: `contributes.{0}.language`. A megadott érték: {1}", + "invalid.scopeName": "Hiányzó karakterlánc a `contributes.{0}.scopeName`-ben. A megadott érték: {1}", + "invalid.path.0": "Hiányzó karakterlánc a `contributes.{0}.path`-ban. A megadott érték: {1}", + "invalid.injectTo": "A `contributes.{0}.injectTo` értéke érvénytelen. Az értéke egy tömb lehet, ami nyelvhatókörök neveit tartalmazza. A megadott érték: {1}", + "invalid.embeddedLanguages": "A `contributes.{0}.embeddedLanguages` értéke érvénytelen. Az értéke egy hatókörnév-nyelv kulcs-érték párokat tartalmazó objektum lehet. A megadott érték: {1}", + "invalid.path.1": "A `contributes.{0}.path` ({1}) nem a kiegészítÅ‘ mappáján belül található ({2}). Emiatt elÅ‘fordulhat, hogy a kiegészítÅ‘ nem lesz hordozható.", + "no-tm-grammar": "Nincs TM Grammar regisztrálva ehhez a nyelvhez." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json b/i18n/hun/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json new file mode 100644 index 00000000000..45673b13e30 --- /dev/null +++ b/i18n/hun/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "parseErrors": "Hiba a(z) {0} feldolgozása közben: {1}", + "schema.openBracket": "A nyitó zárójelet definiáló karakter vagy karaktersorozat", + "schema.closeBracket": "A záró zárójelet definiáló karakter vagy karaktersorozat", + "schema.comments": "Meghatározza a megjegyzésszimbólumokat", + "schema.blockComments": "Meghatározza, hogyan vannak jelölve a megjegyzésblokkok.", + "schema.blockComment.begin": "A megjegyzésblokk kezdetét definiáló karaktersorozat.", + "schema.blockComment.end": "A megjegyzésblokk végét definiáló karaktersorozat.", + "schema.lineComment": "A megjegyzéssor kezdetét definiáló karaktersorozat.", + "schema.brackets": "Meghatározza azokat a zárójelszimbólumokat, amelyek növeik vagy csökkentik az indentálást.", + "schema.autoClosingPairs": "Meghatározza a zárójelpárokat. Ha egy nyitó zárójelet írnak be a szerkesztÅ‘be, a záró párja automatikusan be lesz illesztve.", + "schema.autoClosingPairs.notIn": "Azon hatókörök listája, ahol az automatikus zárójelek automatikus párosítása le van tiltve.", + "schema.surroundingPairs": "Meghatározza azok zárójelpárok listáját, melyek használhatók a kijelölt szöveg körbezárására.", + "schema.wordPattern": "A nyelvben található szavak definíciója.", + "schema.wordPattern.pattern": "A szavak illesztésére használt reguláris kifejezés.", + "schema.wordPattern.flags": "A szavak illesztésére használt reguláris kifejezés beállításai.", + "schema.wordPattern.flags.errorMessage": "Illeszkednie kell a következÅ‘ mintára: `/^([gimuy]+)$/`." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/editor/node/textMate/TMGrammars.i18n.json b/i18n/hun/src/vs/editor/node/textMate/TMGrammars.i18n.json new file mode 100644 index 00000000000..4ae6117a727 --- /dev/null +++ b/i18n/hun/src/vs/editor/node/textMate/TMGrammars.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.grammars": "TextMate-tokenizálókat szolgáltat.", + "vscode.extension.contributes.grammars.language": "Annak a nyelvnek az azonosítója, amely számára szolgáltatva van ez a szintaxis.", + "vscode.extension.contributes.grammars.scopeName": "A tmLanguage-fájl által használt TextMate-hatókör neve.", + "vscode.extension.contributes.grammars.path": "A tmLanguage-fájl elérési útja. Az elérési út relatív a kiegészítÅ‘ mappájához képest, és általában './syntaxes/'-zal kezdÅ‘dik.", + "vscode.extension.contributes.grammars.embeddedLanguages": "Hatókörnév-nyelvazonosító kulcs-érték párokat tartalmazó objektum, ha a nyelvtan tartalmaz beágyazott nyelveket.", + "vscode.extension.contributes.grammars.injectTo": "Azon nyelvi hatókörök nevei, ahová be lesz ágyazva ez a nyelvtan." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/platform/actions/browser/menuItemActionItem.i18n.json b/i18n/hun/src/vs/platform/actions/browser/menuItemActionItem.i18n.json new file mode 100644 index 00000000000..e64a7d0ed09 --- /dev/null +++ b/i18n/hun/src/vs/platform/actions/browser/menuItemActionItem.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "titleAndKb": "{0} ({1})" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json b/i18n/hun/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json new file mode 100644 index 00000000000..e935364b995 --- /dev/null +++ b/i18n/hun/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json @@ -0,0 +1,43 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "requirearray": "a menüelemeket tömbként kell megadni", + "requirestring": "a(z) `{0}` tulajdonság kötelezÅ‘ és `string` típusúnak kell lennie", + "optstring": "a(z) `{0}` tulajdonság elhagyható vagy `string` típusúnak kell lennie", + "vscode.extension.contributes.menuItem.command": "A végrehajtandó parancs azonosítója. A parancsot a 'commands'-szakaszban kell deklarálni", + "vscode.extension.contributes.menuItem.alt": "Egy alternatív végrehajtandó parancs azonosítója. A parancsot a 'commands'-szakaszban kell deklarálni", + "vscode.extension.contributes.menuItem.when": "A feltételnek igaznak kell lennie az elem megjelenítéséhez", + "vscode.extension.contributes.menuItem.group": "A csoport, amibe a parancs tartozik", + "vscode.extension.contributes.menus": "Menüket szolgáltat a szerkesztÅ‘höz", + "menus.commandPalette": "A parancskatalógus", + "menus.editorTitle": "A szerkesztÅ‘ablak címsora menüje", + "menus.editorContext": "A szerkesztÅ‘ablak helyi menüje", + "menus.explorerContext": "A fájlkezelÅ‘ helyi menüje", + "menus.editorTabContext": "A szerkesztÅ‘ablak füleinek helyi menüje", + "menus.debugCallstackContext": "A hibakeresési hívási verem helyi menüje", + "menus.scmTitle": "A verziókezelÅ‘ címsora menüje", + "menus.resourceGroupContext": "A verziókezelÅ‘ erÅ‘forráscsoportja helyi menüje", + "menus.resourceStateContext": "A verziókzeleÅ‘ erÅ‘forrásállapot helyi menüje", + "view.viewTitle": "A szolgáltatott nézet címsorának menüje", + "view.itemContext": "A szolgáltatott nézet elemének helyi menüje", + "nonempty": "az érték nem lehet üres.", + "opticon": "a(z) `icon` tulajdonság elhagyható vagy ha van értéke, akkor string vagy literál (pl. `{dark, light}`) típusúnak kell lennie", + "requireStringOrObject": "a(z) `{0}` tulajdonság kötelezÅ‘ és `string` vagy `object` típusúnak kell lennie", + "requirestrings": "a(z) `{0}` és `{1}` tulajdonságok kötelezÅ‘k és `string` típusúnak kell lenniük", + "vscode.extension.contributes.commandType.command": "A végrehajtandó parancs azonosítója", + "vscode.extension.contributes.commandType.title": "A cím, amivel a parancs meg fog jelenni a felhasználói felületen", + "vscode.extension.contributes.commandType.category": "(Nem kötelezÅ‘) Kategória neve, amibe a felületen csoportosítva lesz a parancs", + "vscode.extension.contributes.commandType.icon": "(Nem kötelezÅ‘) Ikon, ami reprezentálni fogja a parancsot a felhasználói felületen. Egy fájl elérési útja vagy egy színtéma-konfiguráció", + "vscode.extension.contributes.commandType.icon.light": "Az ikon elérési útja, ha világos téma van használatban", + "vscode.extension.contributes.commandType.icon.dark": "Az ikon elérési útja, ha sötét téma van használatban", + "vscode.extension.contributes.commands": "Parancsokat szolgáltat a parancskatalógushoz.", + "dup": "A(z) `{0}` parancs többször szerepel a `commands`-szakaszban.", + "menuId.invalid": "A(z) `{0}` nem érvényes menüazonosító", + "missing.command": "A menüpont a(z) `{0}` parancsra hivatkozik, ami nincs deklarálva a 'commands'-szakaszban.", + "missing.altCommand": "A menüpont a(z) `{0}` alternatív parancsra hivatkozik, ami nincs deklarálva a 'commands'-szakaszban.", + "dupe.command": "A menüpont ugyanazt a parancsot hivatkozza alapértelmezett és alternatív parancsként", + "nosupport.altCommand": "Jelenleg csak az 'editor/title' menü 'navigation' csoportja támogatja az alternatív parancsokat" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/platform/configuration/common/configurationRegistry.i18n.json b/i18n/hun/src/vs/platform/configuration/common/configurationRegistry.i18n.json new file mode 100644 index 00000000000..bfd5f7e168c --- /dev/null +++ b/i18n/hun/src/vs/platform/configuration/common/configurationRegistry.i18n.json @@ -0,0 +1,19 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defaultConfigurations.title": "Felülírt alapértelmezett konfigurációk", + "overrideSettings.description": "A szerkesztÅ‘ beállításainak felülírása a(z) {0} nyelvre vonatkozóan", + "overrideSettings.defaultDescription": "A szerkesztÅ‘ beállításainak felülírása egy adott nyelvre vonatkozóan", + "vscode.extension.contributes.configuration": "Konfigurációs beállításokat szolgáltat.", + "vscode.extension.contributes.configuration.title": "A beállítások összefoglaló leírása. Ez a címke jelenik meg a beállítások fájlban egy különálló megjegyzésként.", + "vscode.extension.contributes.configuration.properties": "A konfigurációs tulajdonságok leírása.", + "config.property.languageDefault": "A(z) '{0}' nem regisztrálható. Ez a beállítás illeszkedik a '\\\\[.*\\\\]$' mintára, ami a nyelvspecifikus szerkesztÅ‘beállításokhoz van használva. Használja a 'configurationDefaults' szolgáltatási lehetÅ‘séget.", + "config.property.duplicate": "A(z) '{0}' nem regisztrálható: ez a tulajdonság már regisztrálva van.", + "invalid.properties": "A 'configuration.properties' értékét egy objektumként kell megadni", + "invalid.type": "ha meg van adva, a 'configuration.type' értékét egy objektumként kell megadnii", + "invalid.title": "a 'configuration.title' értékét karakterláncként kell megadni", + "vscode.extension.contributes.defaultConfiguration": "Adott nyelvre vonatkozóan szerkesztÅ‘beállításokat szolgáltat." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/platform/environment/node/argv.i18n.json b/i18n/hun/src/vs/platform/environment/node/argv.i18n.json new file mode 100644 index 00000000000..e6ca14e40be --- /dev/null +++ b/i18n/hun/src/vs/platform/environment/node/argv.i18n.json @@ -0,0 +1,32 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "gotoValidation": "`--goto` mód esetén az argumentumokat a következÅ‘ formában kell megadni: `FÃJL(:SOR(:OSZLOP))`.", + "diff": "Megnyit egy diffszerkesztÅ‘t. Argumentumként két fájl elérési útját kell átadni.", + "goto": "Megnyitja a megadott elérési úton található fájlt a megadott sornál és oszlopnál (a :sor[:oszlop] információt az elérési út végére kell fűzni)", + "locale": "A használt lokalizáció (pl. en-US vagy zh-TW)", + "newWindow": "Mindenképp induljon új példány a Code-ból.", + "performance": "Indítás a 'Developer: Startup Performance' parancs engedélyezésével.", + "prof-startup": "Processzorhasználat profilozása induláskor", + "reuseWindow": "Fájl vagy mappa megnyitása a legutoljára aktív ablakban.", + "userDataDir": "Meghatározza a könyvtárat, ahol a felhasználói adatok vannak tárolva. Hasznás, ha rootként van futtatva.", + "verbose": "Részletes kimenet kiírása (magába foglalja a --wait kapcsolót)", + "wait": "Várjon az ablak bezárására a visszatérés elÅ‘tt.", + "extensionHomePath": "A kiegészítÅ‘k gyökérkönyvtárának beállítása.", + "listExtensions": "Telepített kiegészítÅ‘k listázása.", + "showVersions": "Telepített kiegészítÅ‘k verziójának megjelenítése a --list-extension kapcsoló használata esetén.", + "installExtension": "KiegészítÅ‘ telepítése.", + "uninstallExtension": "KiegészítÅ‘ eltávolítása.", + "experimentalApis": "Tervezett API-funkciók engedélyezése egy kiegészítÅ‘ számára.", + "disableExtensions": "Összes telepített kiegészítÅ‘ letiltása.", + "disableGPU": "Hardveres gyorsítás letiltása.", + "version": "Verzió kiírása.", + "help": "Használati útmutató kiírása.", + "usage": "Használat", + "options": "beállítások", + "paths": "elérési utak", + "optionsUpperCase": "Beálítások" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/platform/extensionManagement/common/extensionEnablementService.i18n.json b/i18n/hun/src/vs/platform/extensionManagement/common/extensionEnablementService.i18n.json new file mode 100644 index 00000000000..5da094f11e3 --- /dev/null +++ b/i18n/hun/src/vs/platform/extensionManagement/common/extensionEnablementService.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noWorkspace": "Nincs munkaterület." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/platform/extensionManagement/common/extensionManagement.i18n.json b/i18n/hun/src/vs/platform/extensionManagement/common/extensionManagement.i18n.json new file mode 100644 index 00000000000..c6aca38bd35 --- /dev/null +++ b/i18n/hun/src/vs/platform/extensionManagement/common/extensionManagement.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "extensions": "KiegészítÅ‘k", + "preferences": "Beállítások" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/platform/extensionManagement/node/extensionGalleryService.i18n.json b/i18n/hun/src/vs/platform/extensionManagement/node/extensionGalleryService.i18n.json new file mode 100644 index 00000000000..62fa385ee04 --- /dev/null +++ b/i18n/hun/src/vs/platform/extensionManagement/node/extensionGalleryService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "notFound": "KiegészítÅ‘ nem található", + "noCompatible": "A(z) {0} kiegészítÅ‘nek nincs ezzel a Code-verzióval kompatibilis változata." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/platform/extensionManagement/node/extensionManagementService.i18n.json b/i18n/hun/src/vs/platform/extensionManagement/node/extensionManagementService.i18n.json new file mode 100644 index 00000000000..9a21167685a --- /dev/null +++ b/i18n/hun/src/vs/platform/extensionManagement/node/extensionManagementService.i18n.json @@ -0,0 +1,22 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "invalidManifest": "A kiegészítÅ‘ érvénytelen: a package.json nem egy JSON-fájl.", + "restartCode": "Indítsa újra a Code-ot a(z) {0} újratelepítése elÅ‘tt.", + "installDependeciesConfirmation": "A(z) '{0}' teleítése során annak függÅ‘ségei is telepítve lesznek. Szeretné folytatni?", + "install": "Igen", + "doNotInstall": "Nem", + "uninstallDependeciesConfirmation": "Csak a(z) '{0}' kiegészítÅ‘t szeretné eltávolítani vagy annak függÅ‘ségeit is?", + "uninstallOnly": "Csak ezt", + "uninstallAll": "Mindent", + "cancel": "Mégse", + "uninstallConfirmation": "Biztosan szeretné eltávolítani a(z) '{0}' kiegészítÅ‘t?", + "ok": "OK", + "singleDependentError": "Nem sikerült eltávolítani a(z) '{0}' kiegészítÅ‘t: a(z) '{1}' kiegészítÅ‘ függ tÅ‘le.", + "twoDependentsError": "Nem sikerült eltávolítani a(z) '{0}' kiegészítÅ‘t: a(z) '{1}' és '{2}' kiegészítÅ‘k függnek tÅ‘le.", + "multipleDependentsError": "Nem sikerült eltávolítani a(z) '{0}' kiegészítÅ‘t: a(z) '{1}', '{2}' és más kiegészítÅ‘k függnek tÅ‘le.", + "notExists": "Nem sikerült megtalálni a kiegészítÅ‘t" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/platform/extensions/common/abstractExtensionService.i18n.json b/i18n/hun/src/vs/platform/extensions/common/abstractExtensionService.i18n.json new file mode 100644 index 00000000000..a4e5d9f9437 --- /dev/null +++ b/i18n/hun/src/vs/platform/extensions/common/abstractExtensionService.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "unknownDep": "A(z) `{1}` kiegészítÅ‘t nem sikerült aktiválni. Oka: ismeretlen függÅ‘ség: `{0}`.", + "failedDep1": "A(z) `{1}` kiegészítÅ‘t nem sikerült aktiválni. Oka: a(z) `{0}` függÅ‘séget nem sikerült aktiválni.", + "failedDep2": "A(z) `{0}` kiegészítÅ‘t nem sikerült aktiválni. Oka: több, mint 10 szintnyi függÅ‘ség van (nagy valószínűséggel egy függÅ‘ségi hurok miatt).", + "activationError": "A(z) `{0}` kiegészítÅ‘ aktiválása nem sikerült: {1}." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/platform/extensions/common/extensionsRegistry.i18n.json b/i18n/hun/src/vs/platform/extensions/common/extensionsRegistry.i18n.json new file mode 100644 index 00000000000..d7c85757ebd --- /dev/null +++ b/i18n/hun/src/vs/platform/extensions/common/extensionsRegistry.i18n.json @@ -0,0 +1,30 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.engines.vscode": "VS Code kiegészítÅ‘khöz. Meghatározza azt a VS Code-verziót, amivel a kiegészítÅ‘ kompatibilis. Nem lehet *. Például a ^0.10.5 a VS Code minimum 0.10.5-ös verziójával való kompatibilitást jelzi.", + "vscode.extension.publisher": "A VS Code-kiegészítÅ‘ kiadója.", + "vscode.extension.displayName": "A kiegészítÅ‘ VS Code galériában megjelenített neve.", + "vscode.extension.categories": "A VS Code-galériában való kategorizálásra használt kategóriák.", + "vscode.extension.galleryBanner": "A VS Code piactéren használt szalagcím.", + "vscode.extension.galleryBanner.color": "A VS Code piactéren használt szalagcím színe.", + "vscode.extension.galleryBanner.theme": "A szalagcímben használt betűtípus színsémája.", + "vscode.extension.contributes": "A csomagban található összes szolgáltatás, amit ez a VS Code kiterjesztés tartalmaz.", + "vscode.extension.preview": "A kiegészítÅ‘ elÅ‘nézetesnek jelölése a piactéren.", + "vscode.extension.activationEvents": "A VS Code kiegészítÅ‘ aktiválási eseményei.", + "vscode.extension.activationEvents.onLanguage": "Aktiváló esemény, ami akkor fut le, ha az adott nyelvhez társított fájl kerül megnyitásra.", + "vscode.extension.activationEvents.onCommand": "Aktiváló esemény, ami akkor fut le, amikor a megadott parancsot meghívják.", + "vscode.extension.activationEvents.onDebug": "Aktiváló esemény, ami akkor fut le, amikor elindul az adott típusú hibakeresési folyamat.", + "vscode.extension.activationEvents.workspaceContains": "Aktiváló esemény, ami akkor fut le, ha egy olyan mappa kerül megnyitásra, amiben legalább egy olyan fájl van, amely illeszkedik a megadott globális mintára.", + "vscode.extension.activationEvents.onView": "Aktiváló esemény, ami akkor fut le, amikor a megadott nézetet kiterjesztik.", + "vscode.extension.activationEvents.star": "Aktiváló esemény, ami a VS Code indításakor fut le. A jó felhasználói élmény érdekében csak akkor használja ezt az eseményt, ha más aktiváló események nem alkalmasak az adott kiegészítÅ‘ esetében.", + "vscode.extension.badges": "A kiegészítÅ‘ piactéren található oldalának oldalsávjában megjelenÅ‘ jelvények listája.", + "vscode.extension.badges.url": "A jelvény kép URL-je.", + "vscode.extension.badges.href": "A jelvény hivatkozása.", + "vscode.extension.badges.description": "A jelvény leírása.", + "vscode.extension.extensionDependencies": "Más kiegészítÅ‘k, melyek függÅ‘ségei ennek a kiegészítÅ‘nek. A kiegészítÅ‘k azonosítója mindig ${publisher}.${name} formájú. Például: vscode.csharp.", + "vscode.extension.scripts.prepublish": "A VS Code kiegészítÅ‘ publikálása elÅ‘tt végrehajtott parancsfájl.", + "vscode.extension.icon": "Egy 128x128 pixeles ikon elérési útja." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/platform/extensions/node/extensionValidator.i18n.json b/i18n/hun/src/vs/platform/extensions/node/extensionValidator.i18n.json new file mode 100644 index 00000000000..6d0f5c97cf4 --- /dev/null +++ b/i18n/hun/src/vs/platform/extensions/node/extensionValidator.i18n.json @@ -0,0 +1,24 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "versionSyntax": "Nem sikerült feldolgozni az `engines.vscode` beállítás értékét ({0}). Használja például a következÅ‘k egyikét: ^0.10.0, ^1.2.3, ^0.11.0, ^0.10.x stb.", + "versionSpecificity1": "Az `engines.vscode` beállításban megadott érték ({0}) nem elég konkrét. A vscode 1.0.0 elÅ‘tti verzióihoz legalább a kívánt fÅ‘- és alverziót is meg kell adni. Pl.: ^0.10.0, 0.10.x, 0.11.0 stb.", + "versionSpecificity2": "Az `engines.vscode` beállításban megadott érték ({0}) nem elég konkrét. A vscode 1.0.0 utáni verzióihoz legalább a kívánt fÅ‘verziót meg kell adni. Pl.: ^1.10.0, 1.10.x, 1.x.x, 2.x.x stb.", + "versionMismatch": "A kiegészítÅ‘ nem kompatibilis a Code {0} verziójával. A következÅ‘ szükséges hozzá: {1}.", + "extensionDescription.empty": "A kiegészítÅ‘ leírása üres", + "extensionDescription.publisher": "a(z) `{0}` tulajdonság kötelezÅ‘ és `string` típusúnak kell lennie", + "extensionDescription.name": "a(z) `{0}` tulajdonság kötelezÅ‘ és `string` típusúnak kell lennie", + "extensionDescription.version": "a(z) `{0}` tulajdonság kötelezÅ‘ és `string` típusúnak kell lennie", + "extensionDescription.engines": "a(z) `{0}` tulajdonság kötelezÅ‘ és `object` típusúnak kell lennie", + "extensionDescription.engines.vscode": "a(z) `{0}` tulajdonság kötelezÅ‘ és `string` típusúnak kell lennie", + "extensionDescription.extensionDependencies": "a(z) `{0}` tulajdonság elhagyható vagy `string[]` típusúnak kell lennie", + "extensionDescription.activationEvents1": "a(z) `{0}` tulajdonság elhagyható vagy `string[]` típusúnak kell lennie", + "extensionDescription.activationEvents2": "a(z) `{0}` és `{1}` megadása kötelezÅ‘ vagy mindkettÅ‘t el kell hagyni", + "extensionDescription.main1": "a(z) `{0}` tulajdonság elhagyható vagy `string` típusúnak kell lennie", + "extensionDescription.main2": "A `main` ({0}) nem a kiegészítÅ‘ mappáján belül található ({1}). Emiatt elÅ‘fordulhat, hogy a kiegészítÅ‘ nem lesz hordozható.", + "extensionDescription.main3": "a(z) `{0}` és `{1}` megadása kötelezÅ‘ vagy mindkettÅ‘t el kell hagyni", + "notSemver": "A kiegészítÅ‘ verziója nem semver-kompatibilis." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/platform/history/electron-main/historyMainService.i18n.json b/i18n/hun/src/vs/platform/history/electron-main/historyMainService.i18n.json new file mode 100644 index 00000000000..a8e30a812a2 --- /dev/null +++ b/i18n/hun/src/vs/platform/history/electron-main/historyMainService.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "newWindow": "Új ablak", + "newWindowDesc": "Nyit egy új ablakot", + "recentFolders": "Legutóbbi mappák", + "folderDesc": "{0} {1}" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/platform/integrity/node/integrityServiceImpl.i18n.json b/i18n/hun/src/vs/platform/integrity/node/integrityServiceImpl.i18n.json new file mode 100644 index 00000000000..b60e588de5f --- /dev/null +++ b/i18n/hun/src/vs/platform/integrity/node/integrityServiceImpl.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "integrity.ok": "OK", + "integrity.dontShowAgain": "Ne jelenítse meg újra", + "integrity.moreInfo": "További információ", + "integrity.prompt": "A feltelepített {0} hibásnak tűnik. Telepítse újra!" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/platform/jsonschemas/common/jsonValidationExtensionPoint.i18n.json b/i18n/hun/src/vs/platform/jsonschemas/common/jsonValidationExtensionPoint.i18n.json new file mode 100644 index 00000000000..8e300a2fd38 --- /dev/null +++ b/i18n/hun/src/vs/platform/jsonschemas/common/jsonValidationExtensionPoint.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "contributes.jsonValidation": "JSON-sémakonfigurációkat szolgáltat.", + "contributes.jsonValidation.fileMatch": "Az illesztendÅ‘ fájlok mintája, például \"package.json\" vagy \"*.launch\".", + "contributes.jsonValidation.url": "A séma URL-címe ('http:', 'https:') vagy relatív elérési útja a kiegészítÅ‘ mappájához képest ('./').", + "invalid.jsonValidation": "a 'configuration.jsonValidation' értékét tömbként kell megadni", + "invalid.fileMatch": "a 'configuration.jsonValidation.fileMatch' tulajdonság kötelezÅ‘", + "invalid.url": "a 'configuration.jsonValidation.url' értéke URL-cím vagy relatív elérési út lehet", + "invalid.url.fileschema": "a 'configuration.jsonValidation.url' érvénytelen relatív elérési utat tartalmaz: {0}", + "invalid.url.schema": "a 'configuration.jsonValidation.url' érténének 'http:'-tal, 'https:'-tal, vagy a kiegészítÅ‘ben elhelyezett sémák hivatkozása esetén './'-rel kell kezdÅ‘dnie." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/platform/keybinding/common/abstractKeybindingService.i18n.json b/i18n/hun/src/vs/platform/keybinding/common/abstractKeybindingService.i18n.json new file mode 100644 index 00000000000..3e93e9b7ff5 --- /dev/null +++ b/i18n/hun/src/vs/platform/keybinding/common/abstractKeybindingService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "first.chord": "Lenyomta a következÅ‘t: ({0}). Várakozás a kombináció második billentyűjére...", + "missing.chord": "A(z) ({0}, {1}) billentyűkombináció nem egy parancs." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/platform/markers/common/problemMatcher.i18n.json b/i18n/hun/src/vs/platform/markers/common/problemMatcher.i18n.json new file mode 100644 index 00000000000..e24a428b5f1 --- /dev/null +++ b/i18n/hun/src/vs/platform/markers/common/problemMatcher.i18n.json @@ -0,0 +1,61 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ProblemPatternParser.loopProperty.notLast": "A loop tulajdonság csak az utolsó, sorra illesztÅ‘ kifejezésnél támogatott.", + "ProblemPatternParser.problemPattern.missingRegExp": "A problémamintából hiányzik egy reguláris kifejezés.", + "ProblemPatternParser.problemPattern.missingProperty": "A probléma mintája érvénytelen. Mindenképp tartalmaznia kell egy fájlra, egy üzenetre és egy sorra vagy helyre illesztÅ‘ csoportot.", + "ProblemPatternParser.invalidRegexp": "Hiba: A(z) {0} karakterlánc nem érvényes reguláris kifejezés.\n", + "ProblemPatternSchema.regexp": "A kimenetben található hibák, figyelmeztetések és információk megkeresésére használt reguláris kifejezés.", + "ProblemPatternSchema.file": "Annak az illesztési csoportnak az indexe, amely tartalmazza azt, hogy a probléma melyik fájlban található. Ha nincs megadva, akkor az alapértelmezett érték, 1 van használva.", + "ProblemPatternSchema.location": "Annak az illesztési csoportnak az indexe, amely tartalmazza a probléma helyét. Az érvényes minták helyek illesztésére: (line), (line,column) és (startLine,startColumn,endLine,endColumn). Ha nincs megadva, akkor a (line,column) van feltételezve.", + "ProblemPatternSchema.line": "Annak az illesztési csoportnak az indexe, amely tartalmazza azt, hogy a probléma hanyadik sorban található. Alapértelmezett értéke 2.", + "ProblemPatternSchema.column": "Annak az illesztési csoportnak az indexe, amely tartalmazza azt, hogy a probléma az adott soron belül mely oszlopban található. Alapértelmezett értéke 3.", + "ProblemPatternSchema.endLine": "Annak az illesztési csoportnak az indexe, amely tartalmazza azt, hogy a probléma mely sorban ér véget. Alapértelmezett értéke határozatlan.", + "ProblemPatternSchema.endColumn": "Annak az illesztési csoportnak az indexe, amely tartalmazza azt, hogy a probléma vége a zárósoron belül mely oszlopban található. Alapértelmezett értéke határozatlan.", + "ProblemPatternSchema.severity": "Annak az illesztési csoportnak az indexe, amely tartalmazza a probléma súlyosságát. Alapértelmezett értéke határozatlan.", + "ProblemPatternSchema.code": "Annak az illesztési csoportnak az indexe, amely tartalmazza a problémás kódrészletet. Alapértelmezett értéke határozatlan.", + "ProblemPatternSchema.message": "Annak az illesztési csoportnak az indexe, amely tartalmazza az üzenetet. Ha nincs megadva, és a location paraméternek van értéke, akkor a 4, minden más esetben 5 az alapértelmezett érték.", + "ProblemPatternSchema.loop": "Több soros illesztés esetén meghatározza, hogy az aktuális minta mindaddig végre legyen-e hajtva, amíg eredményt talál. Csak többsoros minta esetén használható, utolsóként.", + "NamedProblemPatternSchema.name": "A problémaminta neve.", + "NamedMultiLineProblemPatternSchema.name": "A többsoros problémaminta neve.", + "NamedMultiLineProblemPatternSchema.patterns": "A konkrét minkák.", + "ProblemPatternExtPoint": "Problémamintákat szolgáltat.", + "ProblemPatternRegistry.error": "Érvénytelen problémaminta. A minta figyelmen kívül lesz hagyva.", + "ProblemMatcherParser.noProblemMatcher": "Hiba: a leírást nem sikerült problémaillesztÅ‘vé alakítani:\n{0}\n", + "ProblemMatcherParser.noProblemPattern": "Hiba: a leírás nem definiál érvényes problémamintát:\n{0}\n", + "ProblemMatcherParser.noOwner": "Hiba: a leírás nem határoz meg tulajdonost:\n{0}\n", + "ProblemMatcherParser.noFileLocation": "Hiba: a leírás nem határoz meg fájlhelyszínt:\n{0}\n", + "ProblemMatcherParser.unknownSeverity": "Információ: ismeretlen súlyosság: {0}. Az érvényes értékek: error, warning és info.\n", + "ProblemMatcherParser.noDefinedPatter": "Hiba: nem létezik {0} azonosítóval rendelkezÅ‘ minta.", + "ProblemMatcherParser.noIdentifier": "Hiba: a minta tulajdonság egy üres azonosítóra hivatkozik.", + "ProblemMatcherParser.noValidIdentifier": "Hiba: a minta {0} tulajdonsága nem érvényes mintaváltozónév.", + "ProblemMatcherParser.problemPattern.watchingMatcher": "A problémaillesztÅ‘nek definiálnia kell a kezdÅ‘mintát és a zárómintát is a figyeléshez.", + "ProblemMatcherParser.invalidRegexp": "Hiba: A(z) {0} karakterlánc nem érvényes reguláris kifejezés.\n", + "WatchingPatternSchema.regexp": "Reguláris kifejezés a háttérben futó feladat indulásának vagy befejezÅ‘désének detektálására.", + "WatchingPatternSchema.file": "Annak az illesztési csoportnak az indexe, amely tartalmazza azt, hogy a probléma melyik fájlban található. Elhagyható.", + "PatternTypeSchema.name": "Egy szolgáltatott vagy elÅ‘definiált minta neve", + "PatternTypeSchema.description": "Egy problémaminta vagy egy szolgáltatott vagy elÅ‘definiált problémaminta neve. Elhagyható, ha az alapként használandó minta meg van adva.", + "ProblemMatcherSchema.base": "A alapként használni kívánt problémaillesztÅ‘ neve.", + "ProblemMatcherSchema.owner": "A probléma tulajdonosa a Code-on belül. Elhagyható, ha az alapként használt minta meg van adva. Alapértelmezett értéke 'external', ha nem létezik és az alapként használt minta nincs meghatározva.", + "ProblemMatcherSchema.severity": "Az elkapott problémák alapértelmezett súlyossága. Ez az érték van használva, ha a minta nem definiál illesztési csoportot a súlyossághoz.", + "ProblemMatcherSchema.applyTo": "Meghatározza, hogy a szöveges dokumentumhoz jelentett probléma megnyitott, bezárt vagy minden dokumentumra legyen alkalmazva.", + "ProblemMatcherSchema.fileLocation": "Meghatározza, hogy a problémamintában talált fájlnevek hogyan legyenek értelmezve.", + "ProblemMatcherSchema.background": "Minták, melyekkel követhetÅ‘ egy háttérben futó feladaton aktív illesztÅ‘ indulása és befejezÅ‘dése.", + "ProblemMatcherSchema.background.activeOnStart": "Ha értéke igaz, akkor a háttérfeladat aktív módban van, amikor a feladat indul. Ez egyenlÅ‘ egy olyan sor kimenetre történÅ‘ kiírásával, ami illeszkedik a beginPatternre.", + "ProblemMatcherSchema.background.beginsPattern": "Ha illeszkedik a kimenetre, akkor a háttérben futó feladat elindulása lesz jelezve.", + "ProblemMatcherSchema.background.endsPattern": "Ha illeszkedik a kimenetre, akkor a háttérben futó feladat befejezÅ‘dése lesz jelezve.", + "ProblemMatcherSchema.watching.deprecated": "A watching tulajdonság elavult. Használja a backgroundot helyette.", + "ProblemMatcherSchema.watching": "Minták, melyekkel következÅ‘ a figyelÅ‘ illesztÅ‘k indulása és befejezÅ‘dése.", + "ProblemMatcherSchema.watching.activeOnStart": "Ha értéke igaz, akkor a figyelÅ‘ aktív módban van, amikor a feladat indul. Ez egyenlÅ‘ egy olyan sor kimenetre történÅ‘ kiírásával, ami illeszkedik a beginPatternre.", + "ProblemMatcherSchema.watching.beginsPattern": "Ha illeszkedik a kimenetre, akkor a figyelÅ‘ feladat elindulása lesz jelezve.", + "ProblemMatcherSchema.watching.endsPattern": "Ha illeszkedik a kimenetre, akkor a figyelÅ‘ feladat befejezÅ‘dése lesz jelezve.", + "LegacyProblemMatcherSchema.watchedBegin.deprecated": "Ez a tulajdonság elavult. Használja a watching tulajdonságot helyette.", + "LegacyProblemMatcherSchema.watchedBegin": "Reguláris kifejezés, mely jelzi, hogy a figyeltÅ‘ feladatok fájlmódosítás miatt éppen műveletet hajtanak végre.", + "LegacyProblemMatcherSchema.watchedEnd.deprecated": "Ez a tulajdonság elavult. Használja a watching tulajdonságot helyette.", + "LegacyProblemMatcherSchema.watchedEnd": "Reguláros kifejezés, ami jelzi, hogy a figyelÅ‘ feladat befejezte a végrehajtást.", + "NamedProblemMatcherSchema.name": "A problémaillesztÅ‘ neve.", + "ProblemMatcherExtPoint": "ProblémaillesztÅ‘ket szolgáltat." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/platform/message/common/message.i18n.json b/i18n/hun/src/vs/platform/message/common/message.i18n.json new file mode 100644 index 00000000000..a4f556eb01c --- /dev/null +++ b/i18n/hun/src/vs/platform/message/common/message.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "close": "Bezárás", + "later": "KésÅ‘bb", + "cancel": "Mégse" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/platform/request/node/request.i18n.json b/i18n/hun/src/vs/platform/request/node/request.i18n.json new file mode 100644 index 00000000000..83987512ccd --- /dev/null +++ b/i18n/hun/src/vs/platform/request/node/request.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "httpConfigurationTitle": "HTTP", + "proxy": "A használni kívánt proxybeállítás. Ha nincs beállítva, a http_proxy és a https_proxy környezeti változókból lesz átvéve", + "strictSSL": "A proxyszerver tanúsítványa hitelesítve legyen-e a megadott hitelesítésszolgáltatóknál.", + "proxyAuthorization": "Minden hálózati kérés 'Proxy-Authorization' fejlécében küldendÅ‘ érték." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/platform/telemetry/common/telemetryService.i18n.json b/i18n/hun/src/vs/platform/telemetry/common/telemetryService.i18n.json new file mode 100644 index 00000000000..312528f8891 --- /dev/null +++ b/i18n/hun/src/vs/platform/telemetry/common/telemetryService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "telemetryConfigurationTitle": "Telemetria", + "telemetry.enableTelemetry": "Használati adatok és hibák küldésének engedélyezése a Microsoft felé." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/hun/src/vs/platform/theme/common/colorRegistry.i18n.json new file mode 100644 index 00000000000..9521382b276 --- /dev/null +++ b/i18n/hun/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -0,0 +1,88 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "invalid.color": "Érvénytelen színformátum. Az #RGB, #RGBA, #RRGGBB vagy #RRGGBBAA formátum használható.", + "schema.colors": "A munkaterületen használt színek.", + "foreground": "Ãltalános elÅ‘térszín. Csak akkor van használva, ha nem írja felül az adott komponens.", + "errorForeground": "A hibaüzenetek általános elÅ‘térszíne. Csak akkor van használva, ha nem írja felül az adott komponens.", + "descriptionForeground": "A további információkat szolgáltató leíró szövegek, pl. a címkék elÅ‘térszíne.", + "focusBorder": "Fókuszált elemek keretének általános színe. Csak akkor van használva, ha nem írja felül az adott komponens.", + "contrastBorder": "Az elemek körüli extra keret, mely arra szolgál, hogy elválassza egymástól Å‘ket, így növelve a kontrasztot.", + "activeContrastBorder": "Az aktív elemek körüli extra keret, mely arra szolgál, hogy elválassza egymástól Å‘ket, így növelve a kontrasztot.", + "selectionBackground": "A munkaterületen kijelölt szövegek háttérszíne (pl. beviteli mezÅ‘k vagy szövegmezÅ‘k esetén). Ez a beállítás nem vonatkozik a szerkesztÅ‘ablakban végzett kijelölésekre. ", + "textSeparatorForeground": "A szövegelválasztók színe.", + "textLinkForeground": "A szövegben található hivatkozások elÅ‘térszíne.", + "textLinkActiveForeground": "A szövegben található aktív hivatkozások elÅ‘térszíne.", + "textPreformatForeground": "Az elÅ‘formázott szövegrészek elÅ‘térszíne.", + "textBlockQuoteBackground": "A szövegben található idézetblokkok háttérszíne.", + "textBlockQuoteBorder": "A szövegben található idézetblokkok keretszíne.", + "textCodeBlockBackground": "A szövegben található kódblokkok háttérszíne.", + "widgetShadow": "A szerkesztÅ‘ablakon belül található modulok, pl. a keresés/csere árnyékának színe.", + "inputBoxBackground": "A beviteli mezÅ‘k háttérszíne.", + "inputBoxForeground": "A beviteli mezÅ‘k elÅ‘térszíne.", + "inputBoxBorder": "A beviteli mezÅ‘k kerete.", + "inputBoxActiveOptionBorder": "A beviteli mezÅ‘ben található aktivált beállítások keretszíne.", + "inputPlaceholderForeground": "A beviteli mezÅ‘kben használt helykitöltÅ‘ szövegek elÅ‘térszíne.", + "inputValidationInfoBackground": "Beviteli mezÅ‘k háttérszíne információs szintű validációs állapot esetén.", + "inputValidationInfoBorder": "Beviteli mezÅ‘k keretszíne információs szintű validációs állapot esetén.", + "inputValidationWarningBackground": "Beviteli mezÅ‘k háttérszíne figyelmeztetés szintű validációs állapot esetén.", + "inputValidationWarningBorder": "Beviteli mezÅ‘k keretszíne figyelmeztetés szintű validációs állapot esetén.", + "inputValidationErrorBackground": "Beviteli mezÅ‘k háttérszíne hiba szintű validációs állapot esetén.", + "inputValidationErrorBorder": "Beviteli mezÅ‘k keretszíne hiba szintű validációs állapot esetén.", + "dropdownBackground": "A legördülÅ‘ menük háttérszíne.", + "dropdownForeground": "A legördülÅ‘ menük elÅ‘térszíne.", + "dropdownBorder": "A legördülÅ‘ menük kerete.", + "listFocusBackground": "Listák/fák fókuszált elemének háttérszine, amikor a lista aktív. Egy aktív listának/fának van billentyűfÅ‘kusza, míg egy inaktívnak nincs.", + "listFocusForeground": "Listák/fák fókuszált elemének elÅ‘térszíne, amikor a lista aktív. Egy aktív listának/fának van billentyűfÅ‘kusza, míg egy inaktívnak nincs.", + "listActiveSelectionBackground": "Listák/fák kiválasztott elemének háttérszíne, amikor a lista aktív. Egy aktív listának/fának van billentyűfÅ‘kusza, míg egy inaktívnak nincs.", + "listActiveSelectionForeground": "Listák/fák kiválasztott elemének elÅ‘térszíne, amikor a lista aktív. Egy aktív listának/fának van billentyűfÅ‘kusza, míg egy inaktívnak nincs.", + "listInactiveSelectionBackground": "Listák/fák kiválasztott elemének háttérszíne, amikor a lista inaktív. Egy aktív listának/fának van billentyűfÅ‘kusza, míg egy inaktívnak nincs.", + "listInactiveSelectionForeground": "Listák/fák kiválasztott elemének elÅ‘térszíne, amikor a lista inaktív. Egy aktív listának/fának van billentyűfÅ‘kusza, míg egy inaktívnak nincs.", + "listHoverBackground": "A lista/fa háttérszíne, amikor az egérkurzor egy adott elem fölé kerül.", + "listHoverForeground": "A lista/fa elÅ‘térszíne, amikor az egérkurzor egy adott elem fölé kerül.", + "listDropBackground": "A lista/fa háttérszíne, amikor az elemek az egérkurzorral vannak mozgatva egyik helyrÅ‘l a másikra.", + "highlight": "Kiemelt találatok elÅ‘térszíne a listában/fában való keresés esetén.", + "pickerGroupForeground": "Csoportcímkék színe a gyorsválasztóban.", + "pickerGroupBorder": "Csoportok keretszíne a gyorsválasztóban.", + "buttonForeground": "A gombok elÅ‘térszíne.", + "buttonBackground": "A gombok háttérszíne.", + "buttonHoverBackground": "A gomb háttérszine, ha az egérkurzor fölötte van.", + "badgeBackground": "A jelvények háttérszíne. A jelvények apró információs címkék, pl. a keresési eredmények számának jelzésére.", + "badgeForeground": "A jelvények elÅ‘térszíne. A jelvények apró információs címkék, pl. a keresési eredmények számának jelzésére.", + "scrollbarShadow": "A görgetÅ‘sáv árnyéka, ami jelzi, hogy a nézet el van görgetve.", + "scrollbarSliderBackground": "A csúszkák háttérszíne.", + "scrollbarSliderHoverBackground": "A csúszkák háttérszíne, ha az egérkurzor felette van.", + "scrollbarSliderActiveBackground": "Az aktív csúszkák háttérszíne.", + "progressBarBackground": "A hosszú ideig tartó folyamatok esetén megjelenített folyamatjelzÅ‘ háttérszíne.", + "editorBackground": "A szerkesztÅ‘ablak háttérszíne.", + "editorForeground": "A szerkesztÅ‘ablak alapértelmezett elÅ‘térszíne.", + "editorWidgetBackground": "A szerkesztÅ‘ablak moduljainak háttérszíne, pl. a keresés/cserének.", + "editorWidgetBorder": "A szerkesztÅ‘ablak-modulok keretszíne. A szín csak akkor van használva, ha a modul beállítása alapján rendelkezik kerettel, és a színt nem írja felül a modul.", + "editorSelection": "A szerkesztÅ‘ablakban található kijelölések színe.", + "editorInactiveSelection": "Az inaktív szerkesztÅ‘ablakban található kijelölések színe.", + "editorSelectionHighlight": "A kijelöléssel megegyezÅ‘ tartalmú területek színe.", + "editorFindMatch": "A keresés jelenlegi találatának színe.", + "findMatchHighlight": "A keresés további találatainak színe.", + "findRangeHighlight": "A keresést korlátozó terület színe.", + "hoverHighlight": "Kiemelés azon szó alatt, amely fölött lebegÅ‘ elem jelenik meg.", + "hoverBackground": "A szerkesztÅ‘ablakban lebegÅ‘ elemek háttérszíne.", + "hoverBorder": "A szerkesztÅ‘ablakban lebegÅ‘ elemek keretszíne.", + "activeLinkForeground": "Az aktív hivatkozások háttérszíne.", + "diffEditorInserted": "A beillesztett szövegek háttérszíne.", + "diffEditorRemoved": "Az eltávolított szövegek háttérszíne.", + "diffEditorInsertedOutline": "A beillesztett szövegek körvonalának színe.", + "diffEditorRemovedOutline": "Az eltávolított szövegek körvonalának színe.", + "mergeCurrentHeaderBackground": "A helyi tartalom fejlécének háttérszíne sorok között megjelenített összeolvasztási konfliktusok esetén.", + "mergeCurrentContentBackground": "A helyi tartalom háttérszíne sorok között megjelenített összeolvasztási konfliktusok esetén.", + "mergeIncomingHeaderBackground": "A beérkezÅ‘ tartalom fejlécének háttérszíne sorok között megjelenített összeolvasztási konfliktusok esetén.", + "mergeIncomingContentBackground": "A beérkezÅ‘ tartalom háttérszíne sorok között megjelenített összeolvasztási konfliktusok esetén.", + "mergeCommonHeaderBackground": "A közös Å‘s tartalom fejlécének háttérszíne sorok között megjelenített összeolvasztási konfliktusok esetén. ", + "mergeCommonContentBackground": "A közös Å‘s tartalom háttérszíne sorok között megjelenített összeolvasztási konfliktusok esetén. ", + "mergeBorder": "A fejlécek és az elválasztó sáv keretszíne a sorok között megjelenített összeolvasztási konfliktusok esetén.", + "overviewRulerCurrentContentForeground": "A helyi tartalom elÅ‘térszíne az áttekintÅ‘ sávon összeolvasztási konfliktusok esetén.", + "overviewRulerIncomingContentForeground": "A beérkezÅ‘ tartalom elÅ‘térszíne az áttekintÅ‘ sávon összeolvasztási konfliktusok esetén.", + "overviewRulerCommonContentForeground": "A közös Å‘s tartalom elÅ‘térszíne az áttekintÅ‘ sávon összeolvasztási konfliktusok esetén. " +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/api/electron-browser/mainThreadExtensionService.i18n.json b/i18n/hun/src/vs/workbench/api/electron-browser/mainThreadExtensionService.i18n.json new file mode 100644 index 00000000000..c9ac5c4a126 --- /dev/null +++ b/i18n/hun/src/vs/workbench/api/electron-browser/mainThreadExtensionService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "overwritingExtension": "A(z) {0} kiegészítÅ‘ felülírása a következÅ‘vel: {1}.", + "extensionUnderDevelopment": "A(z) {0} elérési úton található fejlesztÅ‘i kiegészítÅ‘ betöltése" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/api/electron-browser/mainThreadMessageService.i18n.json b/i18n/hun/src/vs/workbench/api/electron-browser/mainThreadMessageService.i18n.json new file mode 100644 index 00000000000..32ac1f41978 --- /dev/null +++ b/i18n/hun/src/vs/workbench/api/electron-browser/mainThreadMessageService.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "close": "Bezárás", + "cancel": "Mégse", + "ok": "OK" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/api/node/extHostDiagnostics.i18n.json b/i18n/hun/src/vs/workbench/api/node/extHostDiagnostics.i18n.json new file mode 100644 index 00000000000..4b78aadacde --- /dev/null +++ b/i18n/hun/src/vs/workbench/api/node/extHostDiagnostics.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "limitHit": "{0} további hiba és figyelmeztetés nem jelenik meg." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/hun/src/vs/workbench/api/node/extHostTask.i18n.json new file mode 100644 index 00000000000..4b90a12aaf2 --- /dev/null +++ b/i18n/hun/src/vs/workbench/api/node/extHostTask.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "task.label": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/api/node/extHostTreeViews.i18n.json b/i18n/hun/src/vs/workbench/api/node/extHostTreeViews.i18n.json new file mode 100644 index 00000000000..ad630367cba --- /dev/null +++ b/i18n/hun/src/vs/workbench/api/node/extHostTreeViews.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "treeView.notRegistered": "Nincs '{0}' azonosítóval regisztrált fanézet.", + "treeItem.notFound": "Nincs '{0}' azonosítójú elem a fában.", + "treeView.duplicateElement": "A(z) {0} elem már regisztrálva van" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/actions/configureLocale.i18n.json b/i18n/hun/src/vs/workbench/browser/actions/configureLocale.i18n.json new file mode 100644 index 00000000000..fde77c79014 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/actions/configureLocale.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "configureLocale": "Nyelv beállítása", + "displayLanguage": "Meghatározza a VSCode felületének nyelvét.", + "doc": "Az elérhetÅ‘ nyelvek listája a következÅ‘ címen tekinthetÅ‘ meg: {0}", + "restart": "Az érték módosítása után újra kell indítani a VSCode-ot.", + "fail.createSettings": "A(z) '{0}' nem hozható létre ({1})", + "JsonSchema.locale": "A felhasználói felületen használt nyelv." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/actions/fileActions.i18n.json b/i18n/hun/src/vs/workbench/browser/actions/fileActions.i18n.json new file mode 100644 index 00000000000..9c4fe7cdf28 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/actions/fileActions.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openFolder": "Mappa megnyitása...", + "openFileFolder": "Megnyitás..." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/actions/toggleActivityBarVisibility.i18n.json b/i18n/hun/src/vs/workbench/browser/actions/toggleActivityBarVisibility.i18n.json new file mode 100644 index 00000000000..5855d42c943 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/actions/toggleActivityBarVisibility.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleActivityBar": "Tevékenységsáv be- és kikapcsolása", + "view": "Nézet" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/actions/toggleEditorLayout.i18n.json b/i18n/hun/src/vs/workbench/browser/actions/toggleEditorLayout.i18n.json new file mode 100644 index 00000000000..3880a172e26 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/actions/toggleEditorLayout.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleEditorGroupLayout": "SzerkesztÅ‘ablak-csoport vízszintes/függÅ‘leges elrendezésének váltása", + "horizontalLayout": "SzerkesztÅ‘ablak-csoport elrendezése vízszintesen", + "verticalLayout": "SzerkesztÅ‘ablak-csoport elrendezése függÅ‘legesen", + "view": "Nézet" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/actions/toggleSidebarPosition.i18n.json b/i18n/hun/src/vs/workbench/browser/actions/toggleSidebarPosition.i18n.json new file mode 100644 index 00000000000..b5b22901d6a --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/actions/toggleSidebarPosition.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleLocation": "Oldalsáv helyének váltása", + "view": "Nézet" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/actions/toggleSidebarVisibility.i18n.json b/i18n/hun/src/vs/workbench/browser/actions/toggleSidebarVisibility.i18n.json new file mode 100644 index 00000000000..851dacaba5c --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/actions/toggleSidebarVisibility.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleSidebar": "Oldalsáv be- és kikapcsolása", + "view": "Nézet" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/actions/toggleStatusbarVisibility.i18n.json b/i18n/hun/src/vs/workbench/browser/actions/toggleStatusbarVisibility.i18n.json new file mode 100644 index 00000000000..b2087b12af6 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/actions/toggleStatusbarVisibility.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleStatusbar": "Ãllapotsor be- és kikapcsolása", + "view": "Nézet" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/actions/toggleZenMode.i18n.json b/i18n/hun/src/vs/workbench/browser/actions/toggleZenMode.i18n.json new file mode 100644 index 00000000000..de2a4b219be --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/actions/toggleZenMode.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleZenMode": "Zen mód be- és kikapcsolása", + "view": "Nézet" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/activitybar/activitybarActions.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/activitybar/activitybarActions.i18n.json new file mode 100644 index 00000000000..38f496cc0ee --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/activitybar/activitybarActions.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "removeFromActivityBar": "Eltávolítás a tevékenységsávról", + "keepInActivityBar": "Megtartás a tevékenységsávon", + "titleKeybinding": "{0} ({1})", + "additionalViews": "További nézetek", + "numberBadge": "{0} ({1})", + "manageExtension": "KiegészítÅ‘ kezelése", + "toggle": "Nézet rögzítésének be- és kikapcsolása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json new file mode 100644 index 00000000000..266ac56433e --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "hideActivitBar": "Tevékenységsáv elrejtése", + "activityBarAriaLabel": "Az aktív nézet váltása", + "globalActions": "Globális műveletek" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/compositePart.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/compositePart.i18n.json new file mode 100644 index 00000000000..46148b0c7c3 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/compositePart.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ariaCompositeToolbarLabel": "{0} művelet", + "titleTooltip": "{0} ({1})" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/editor/binaryDiffEditor.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/editor/binaryDiffEditor.i18n.json new file mode 100644 index 00000000000..a38af02d663 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/editor/binaryDiffEditor.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "metadataDiff": "{0} ↔ {1}" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/editor/binaryEditor.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/editor/binaryEditor.i18n.json new file mode 100644 index 00000000000..a8bbd66e2e8 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/editor/binaryEditor.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "binaryEditor": "Bináris megjelenítÅ‘" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/editor/editor.contribution.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/editor/editor.contribution.i18n.json new file mode 100644 index 00000000000..186c2e66b64 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/editor/editor.contribution.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "textEditor": "SzövegszerkesztÅ‘", + "textDiffEditor": "Szöveges tartalmak differenciaszerkesztÅ‘ ablaka", + "binaryDiffEditor": "Bináris tartalmak differenciaszerkesztÅ‘ ablaka", + "sideBySideEditor": "Párhuzamos szerkesztÅ‘ablakok", + "groupOnePicker": "Az elsÅ‘ csoportban található szerkesztÅ‘ablakok megjelenítése", + "groupTwoPicker": "A második csoportban található szerkesztÅ‘ablakok megjelenítése", + "groupThreePicker": "A harmadik csoportban található szerkesztÅ‘ablakok megjelenítése", + "allEditorsPicker": "Összes megnyitott szerkesztÅ‘ablak megjelenítése", + "view": "Nézet" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/editor/editorActions.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/editor/editorActions.i18n.json new file mode 100644 index 00000000000..e2495b74e21 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/editor/editorActions.i18n.json @@ -0,0 +1,56 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "splitEditor": "SzerkesztÅ‘ kettéosztása", + "joinTwoGroups": "Két szerkesztÅ‘csoport összevonása", + "navigateEditorGroups": "Váltás szerkesztÅ‘csoportok között", + "focusActiveEditorGroup": "Váltás az aktív szerkesztÅ‘csoportra", + "focusFirstEditorGroup": "Váltás az elsÅ‘ szerkesztÅ‘csoportra", + "focusSecondEditorGroup": "Váltás a második szerkesztÅ‘csoportra", + "focusThirdEditorGroup": "Váltás a harmadik szerkesztÅ‘csoportra", + "focusPreviousGroup": "Váltás az elÅ‘zÅ‘ csoportra", + "focusNextGroup": "Váltás a következÅ‘ csoportra", + "openToSide": "Megnyitás oldalt", + "closeEditor": "SzerkesztÅ‘ablak bezárása", + "revertAndCloseActiveEditor": "Visszaállítás és szerkesztÅ‘ablak bezárása", + "closeEditorsToTheLeft": "Balra lévÅ‘ szerkesztÅ‘ablakok bezárása", + "closeEditorsToTheRight": "Jobbra lévÅ‘ szerkesztÅ‘ablakok bezárása", + "closeAllEditors": "Összes szerkesztÅ‘ablak bezárása", + "closeUnmodifiedEditors": "Nem módosult szerkesztÅ‘ablakok bezárása a csoportban", + "closeEditorsInOtherGroups": "A többi csoport szerkesztÅ‘ablakainak bezárása", + "closeOtherEditorsInGroup": "Többi szerkesztÅ‘ablak bezárása", + "closeEditorsInGroup": "A csoportban lévÅ‘ összes szerkesztÅ‘ablak bezárása", + "moveActiveGroupLeft": "SzerkesztÅ‘ablak-csoport mozgatása balra", + "moveActiveGroupRight": "SzerkesztÅ‘ablak-csoport mozgatása jobbra", + "minimizeOtherEditorGroups": "Többi szerkesztÅ‘ablak-csoport kis méretűvé tétele", + "evenEditorGroups": "SzerkesztÅ‘ablak-csoportok egyenlÅ‘ méretűvé tétele", + "maximizeEditor": "SzerkesztÅ‘ablak-csoport nagy méretűvé tétele és oldalsáv elrejtése", + "keepEditor": "SzerkesztÅ‘ablak nyitva tartása", + "openNextEditor": "KövetkezÅ‘ szerkesztÅ‘ablak megnyitása", + "openPreviousEditor": "ElÅ‘zÅ‘ szerkesztÅ‘ablak megnyitása", + "nextEditorInGroup": "A csoport következÅ‘ szerkesztÅ‘ablakának megnyitása", + "openPreviousEditorInGroup": "A csoport elÅ‘zÅ‘ szerkesztÅ‘ablakának megnyitása", + "navigateNext": "Ugrás elÅ‘re", + "navigatePrevious": "Ugrás vissza", + "reopenClosedEditor": "Bezárt szerkesztÅ‘ablak újranyitása", + "clearRecentFiles": "Legutóbbi fájlok listájának törlése", + "showEditorsInFirstGroup": "Az elsÅ‘ csoportban található szerkesztÅ‘ablakok megjelenítése", + "showEditorsInSecondGroup": "A második csoportban található szerkesztÅ‘ablakok megjelenítése", + "showEditorsInThirdGroup": "A harmadik csoportban található szerkesztÅ‘ablakok megjelenítése", + "showEditorsInGroup": "A csoportban található szerkesztÅ‘ablakok megjelenítése", + "showAllEditors": "Összes szerkesztÅ‘ablak megjelenítése", + "openPreviousRecentlyUsedEditorInGroup": "A csoportban elÅ‘zÅ‘ legutoljára használt szerksztÅ‘ablak megnyitása", + "openNextRecentlyUsedEditorInGroup": "A csoportban következÅ‘ legutoljára használt szerksztÅ‘ablak megnyitása", + "navigateEditorHistoryByInput": "ElÅ‘zÅ‘ szerkesztÅ‘ablak menyitása az elÅ‘zményekbÅ‘l", + "openNextRecentlyUsedEditor": "A következÅ‘ legutoljára használt szerksztÅ‘ablak megnyitása", + "openPreviousRecentlyUsedEditor": "Az elÅ‘zÅ‘ legutoljára használt szerksztÅ‘ablak megnyitása", + "clearEditorHistory": "SzerkesztÅ‘ablak-elÅ‘zmények törlése", + "focusLastEditorInStack": "Csoport utolsó szerkesztÅ‘ablakának megnyitása", + "moveEditorLeft": "SzerkesztÅ‘ablak mozgatása balra", + "moveEditorRight": "SzerkesztÅ‘ablak mozgatása jobbra", + "moveEditorToPreviousGroup": "SzerkesztÅ‘ablak mozgatása az elÅ‘zÅ‘ csoportba", + "moveEditorToNextGroup": "SzerkesztÅ‘ablak mozgatása a következÅ‘ csoportba" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/editor/editorCommands.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/editor/editorCommands.i18n.json new file mode 100644 index 00000000000..6e6ffe92dbd --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/editor/editorCommands.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorCommand.activeEditorMove.description": "Aktív szerkesztÅ‘ablak mozgatása fülek vagy csoportok között", + "editorCommand.activeEditorMove.arg.name": "Aktív szerkesztÅ‘ablak mozgatási argumentum", + "editorCommand.activeEditorMove.arg.description": "Argumentumtulajdonságok:\n\t\t\t\t\t\t* 'to': karakterlánc, a mozgatás célpontja.\n\t\t\t\t\t\t* 'by': karakterlánc, a mozgatás egysége. Fülek (tab) vagy csoportok (group) alapján.\n\t\t\t\t\t\t* 'value': szám, ami meghatározza, hogy hány pozíciót kell mozgatni, vagy egy abszolút pozíciót, ahová mozgatni kell.\n\t\t\t\t\t", + "commandDeprecated": "A(z) **{0}** parancs el lett távolítva. A(z) **{1}** használható helyette", + "openKeybindings": "Billentyűparancsok beállítása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/editor/editorPart.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/editor/editorPart.i18n.json new file mode 100644 index 00000000000..69361037728 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/editor/editorPart.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "groupOneVertical": "Bal", + "groupTwoVertical": "KözépsÅ‘", + "groupThreeVertical": "Jobb", + "groupOneHorizontal": "FelsÅ‘", + "groupTwoHorizontal": "KözépsÅ‘", + "groupThreeHorizontal": "Alsó", + "editorOpenError": "Nem sikerült megnyitni a(z) '{0}' fájlt: {1}." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/editor/editorPicker.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/editor/editorPicker.i18n.json new file mode 100644 index 00000000000..51a1f475254 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/editor/editorPicker.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, szerkesztÅ‘csoport-választó", + "groupLabel": "Csoport: {0}", + "noResultsFoundInGroup": "A csoportban nem található ilyen nyitott szerkesztÅ‘ablak", + "noOpenedEditors": "A csoportban jelenleg nincs megnyitott szerkesztÅ‘ablak", + "noResultsFound": "Nem található ilyen nyitott szerkesztÅ‘ablak", + "noOpenedEditorsAllGroups": "Jelenleg nincs megnyitott szerkesztÅ‘ablak" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json new file mode 100644 index 00000000000..cf37b615cda --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json @@ -0,0 +1,51 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "singleSelectionRange": "{0}. sor, {1}. oszlop ({2} kijelölve)", + "singleSelection": "{0}. sor, {1}. oszlop", + "multiSelectionRange": "{0} kijelölés ({1} karakter kijelölve)", + "multiSelection": "{0} kijelölés", + "endOfLineLineFeed": "LF", + "endOfLineCarriageReturnLineFeed": "CRLF", + "tabFocusModeEnabled": "Tab fókuszt vált", + "screenReaderDetected": "KépernyÅ‘olvasó érzékelve", + "screenReaderDetectedExtra": "Ha nem használ képernyÅ‘olvasót, állítsa az `editor.accessibilitySupport` értékét \"off\"-ra.", + "disableTabMode": "KisegítÅ‘ mód letiltása", + "gotoLine": "Sor megkeresése", + "indentation": "Indentálás", + "selectEncoding": "Kódolás kiválasztása", + "selectEOL": "Sorvégjel kiválasztása", + "selectLanguageMode": "Nyelvmód kiválasztása", + "fileInfo": "Fájlinformáció", + "spacesSize": "Szóközök: {0}", + "tabSize": "Tabulátorméret: {0}", + "showLanguageExtensions": "'{0}' kiegészítÅ‘ keresése a piactéren...", + "changeMode": "Nyelvmód váltása", + "noEditor": "Jelenleg nincs aktív szerkesztÅ‘ablak", + "languageDescription": "({0}) - Beállított nyelv", + "languageDescriptionConfigured": "({0})", + "languagesPicks": "nyelvek (azonosító)", + "configureModeSettings": "'{0}' nyelvi beállítások módosítása...", + "configureAssociationsExt": "'{0}' fájlhozzárendelések módosítása...", + "autoDetect": "Automatikus felderítés", + "pickLanguage": "Nyelvmód kiválasztása", + "currentAssociation": "Jelenlegi társítás", + "pickLanguageToConfigure": "A(z) '{0}' kiterjesztéshez társított nyelvmód kiválasztása", + "changeIndentation": "Indentálás módosítása", + "noWritableCodeEditor": "Az aktív kódszerkesztÅ‘-ablak írásvédett módban van.", + "indentView": "nézet váltása", + "indentConvert": "fájl konvertálása", + "pickAction": "Művelet kiválasztása", + "changeEndOfLine": "Sorvégjel módosítása", + "pickEndOfLine": "Sorvégjel kiválasztása", + "changeEncoding": "Fájlkódolás módosítása", + "noFileEditor": "Jelenleg nincs aktív fájl", + "saveWithEncoding": "Mentés adott kódolással", + "reopenWithEncoding": "Újranyitás adott kódolással", + "guessedEncoding": "Kitalálva a tartalomból", + "pickEncodingForReopen": "Válassza ki a kódolást a fájl újranyitásához", + "pickEncodingForSave": "Válassza ki a mentéshez használandó kódolást" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/editor/tabsTitleControl.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/editor/tabsTitleControl.i18n.json new file mode 100644 index 00000000000..716abaa9fd0 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/editor/tabsTitleControl.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "araLabelTabActions": "Fülműveletek" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/editor/textDiffEditor.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/editor/textDiffEditor.i18n.json new file mode 100644 index 00000000000..0cb7c46cb05 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/editor/textDiffEditor.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "textDiffEditor": "Szöveges tartalmak differenciaszerkesztÅ‘ ablaka", + "readonlyEditorWithInputAriaLabel": "{0}. Ãrásvédett szövegösszehasonlító.", + "readonlyEditorAriaLabel": "Ãrásvédett szövegösszehasonlító.", + "editableEditorWithInputAriaLabel": "{0}. Szövegfájl-összehasonlító.", + "editableEditorAriaLabel": "Szövegfájl-összehasonlító.", + "navigate.next.label": "KövetkezÅ‘ módosítás", + "navigate.prev.label": "ElÅ‘zÅ‘ módosítás", + "inlineDiffLabel": "Váltás inline nézetre", + "sideBySideDiffLabel": "Váltás párhuzamos nézetre" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/editor/textEditor.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/editor/textEditor.i18n.json new file mode 100644 index 00000000000..bc6c6d9162f --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/editor/textEditor.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorLabelWithGroup": "{0}, {1}. csoport" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/editor/textResourceEditor.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/editor/textResourceEditor.i18n.json new file mode 100644 index 00000000000..357b1df914c --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/editor/textResourceEditor.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "textEditor": "SzövegszerkesztÅ‘", + "readonlyEditorWithInputAriaLabel": "{0}. Ãrásvédett szövegszerkesztÅ‘.", + "readonlyEditorAriaLabel": "Ãrásvédett szövegszerkesztÅ‘.", + "untitledFileEditorWithInputAriaLabel": "{0}. Névtelen szövegszerkesztÅ‘.", + "untitledFileEditorAriaLabel": "Névtelen szövegszerkesztÅ‘." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/editor/titleControl.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/editor/titleControl.i18n.json new file mode 100644 index 00000000000..0ef6405cab2 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/editor/titleControl.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "close": "Bezárás", + "closeOthers": "Többi bezárása", + "closeRight": "Jobbra lévÅ‘k bezárása", + "closeAll": "Összes bezárása", + "closeAllUnmodified": "Nem módosultak bezárása", + "keepOpen": "Maradjon nyitva", + "showOpenedEditors": "Megnyitott szerkesztÅ‘ablak megjelenítése", + "araLabelEditorActions": "SzerkesztÅ‘ablak-műveletek" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/panel/panelActions.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/panel/panelActions.i18n.json new file mode 100644 index 00000000000..79a37ed7da4 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/panel/panelActions.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "panelActionTooltip": "{0} ({1})", + "closePanel": "Panel bezárása", + "togglePanel": "Panel be- és kikapcsolása", + "focusPanel": "Váltás a panelra", + "toggleMaximizedPanel": "Teljes méretű panel be- és kikapcsolása", + "maximizePanel": "Panel teljes méretűvé tétele", + "minimizePanel": "Panel méretének visszaállítása", + "view": "Nézet" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/panel/panelPart.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/panel/panelPart.i18n.json new file mode 100644 index 00000000000..6bbddde8753 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/panel/panelPart.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "panelSwitcherBarAriaLabel": "Az aktív panel váltása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/quickopen/quickOpenController.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/quickopen/quickOpenController.i18n.json new file mode 100644 index 00000000000..d1d7a5732f9 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/quickopen/quickOpenController.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "inputModeEntryDescription": "{0} (Nyomjon 'Enter'-t a megerÅ‘sítéshez vagy 'Escape'-et a megszakításhoz)", + "inputModeEntry": "Nyomjon 'Enter'-t a megerÅ‘sítéshez vagy 'Escape'-et a megszakításhoz", + "emptyPicks": "Nincs választható elem", + "quickOpenInput": "A végrehajtható műveletek körét a ? karakter beírásával tekintheti meg", + "historyMatches": "legutóbb megnyitott", + "noResultsFound1": "Nincs találat", + "canNotRunPlaceholder": "A jelenlegi kontextusban nem használható a gyorsmegnyitási funkció", + "entryAriaLabel": "{0}, legutóbb megnyitott", + "removeFromEditorHistory": "Eltávolítás az elÅ‘zményekbÅ‘l", + "pickHistory": "Válassza ki azt a szerkesztÅ‘ablakot, amit el szeretne távolítani az elÅ‘zményekbÅ‘l" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json new file mode 100644 index 00000000000..1686ffdab02 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpen": "File megkeresése...", + "quickNavigateNext": "Ugrás a következÅ‘re a fájlok gyors megnyitásánál", + "quickNavigatePrevious": "Ugrás az elÅ‘zÅ‘re a fájlok gyors megnyitásánál", + "quickSelectNext": "KövetkezÅ‘ kiválasztása a fájlok gyors megnyitásánál", + "quickSelectPrevious": "ElÅ‘zÅ‘ kiválasztása a fájlok gyors megnyitásánál" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/sidebar/sidebarPart.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/sidebar/sidebarPart.i18n.json new file mode 100644 index 00000000000..f150e0f9ff2 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/sidebar/sidebarPart.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "focusSideBar": "Váltás az oldalsávra", + "viewCategory": "Nézet" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/statusbar/statusbarPart.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/statusbar/statusbarPart.i18n.json new file mode 100644 index 00000000000..3cc19480b62 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/statusbar/statusbarPart.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "canNotRun": "A(z) '{0}' parancs jelenleg nem engedélyezett és nem futtatható.", + "manageExtension": "KiegészítÅ‘ kezelése" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/parts/titlebar/titlebarPart.i18n.json b/i18n/hun/src/vs/workbench/browser/parts/titlebar/titlebarPart.i18n.json new file mode 100644 index 00000000000..6ed546539cf --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/parts/titlebar/titlebarPart.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "patchedWindowTitle": "[Nem támogatott]", + "devExtensionWindowTitlePrefix": "[KiegészítÅ‘ fejlesztÅ‘i példány]" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/quickopen.i18n.json b/i18n/hun/src/vs/workbench/browser/quickopen.i18n.json new file mode 100644 index 00000000000..3f67d6f3e13 --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/quickopen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultsMatching": "Nincs eredmény", + "noResultsFound2": "Nincs találat", + "entryAriaLabel": "{0}, parancs" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/browser/viewlet.i18n.json b/i18n/hun/src/vs/workbench/browser/viewlet.i18n.json new file mode 100644 index 00000000000..1d02ba8d6ee --- /dev/null +++ b/i18n/hun/src/vs/workbench/browser/viewlet.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "collapse": "Összes bezárása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/common/theme.i18n.json b/i18n/hun/src/vs/workbench/common/theme.i18n.json new file mode 100644 index 00000000000..4966ba69845 --- /dev/null +++ b/i18n/hun/src/vs/workbench/common/theme.i18n.json @@ -0,0 +1,61 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tabActiveBackground": "Az aktív fül háttérszíne. A fülek tartalmazzák a szerkesztÅ‘ablakoket a szerkesztÅ‘területen. Egy szerkesztÅ‘ablak-csoportban több fül is megnyitható. Több szerkesztÅ‘ablak-csoportot is létre lehet hozni.", + "tabInactiveBackground": "Az inaktív fülek háttérszíne. A fülek tartalmazzák a szerkesztÅ‘ablakoket a szerkesztÅ‘területen. Egy szerkesztÅ‘ablak-csoportban több fül is megnyitható. Több szerkesztÅ‘ablak-csoportot is létre lehet hozni.", + "tabBorder": "A füleket egymástól elválasztó keret színe. A fülek tartalmazzák a szerkesztÅ‘ablakoket a szerkesztÅ‘területen. Egy szerkesztÅ‘ablak-csoportban több fül is megnyitható. Több szerkesztÅ‘ablak-csoportot is létre lehet hozni.", + "tabActiveForeground": "Az aktív fül elÅ‘térszíne az aktív csoportban. A fülek tartalmazzák a szerkesztÅ‘ablakoket a szerkesztÅ‘területen. Egy szerkesztÅ‘ablak-csoportban több fül is megnyitható. Több szerkesztÅ‘ablak-csoportot is létre lehet hozni.", + "tabInactiveForeground": "Az inaktív fülek elÅ‘térszíne az aktív csoportban. A fülek tartalmazzák a szerkesztÅ‘ablakoket a szerkesztÅ‘területen. Egy szerkesztÅ‘ablak-csoportban több fül is megnyitható. Több szerkesztÅ‘ablak-csoportot is létre lehet hozni.", + "tabUnfocusedActiveForeground": "Az aktív fül elÅ‘térszíne az inaktív csoportokban. A fülek tartalmazzák a szerkesztÅ‘ablakoket a szerkesztÅ‘területen. Egy szerkesztÅ‘ablak-csoportban több fül is megnyitható. Több szerkesztÅ‘ablak-csoportot is létre lehet hozni.", + "tabUnfocusedInactiveForeground": "Az inaktív fülek elÅ‘térszíne inaktív csoportokban. A fülek tartalmazzák a szerkesztÅ‘ablakoket a szerkesztÅ‘területen. Egy szerkesztÅ‘ablak-csoportban több fül is megnyitható. Több szerkesztÅ‘ablak-csoportot is létre lehet hozni.", + "editorGroupBackground": "A szerkesztÅ‘csoportok háttérszíne. A szerkesztÅ‘csoportok szerkesztÅ‘ablakokat tartalmaznak. A háttérszín akkor jelenik meg, ha a szerkesztÅ‘csoportok mozgatva vannak.", + "tabsContainerBackground": "A szerkesztÅ‘csoport címsorának háttérszíne, ha a fülek engedélyezve vannak. A szerkesztÅ‘csoportok szerkesztÅ‘ablakokat tartalmaznak.", + "tabsContainerBorder": "A szerkesztÅ‘csoport címsorának keretszíne, ha a fülek engedélyezve vannak. A szerkesztÅ‘csoportok szerkesztÅ‘ablakokat tartalmaznak.", + "editorGroupHeaderBackground": "A szerkesztÅ‘csoport címsorának keretszíne, ha a fülek le vannak tiltva. A szerkesztÅ‘csoportok szerkesztÅ‘ablakokat tartalmaznak.", + "editorGroupBorder": "A szerkesztÅ‘csoportokat elválasztó vonal színe. A szerkesztÅ‘csoportok szerkesztÅ‘ablakokat tartalmaznak.", + "editorDragAndDropBackground": "A szerkesztÅ‘ablakok mozgatásánál használt háttérszín. Érdemes átlátszó színt választani, hogy a szerkesztÅ‘ablak tartalma továbbra is látszódjon.", + "panelBackground": "A panelek háttérszíne. A panelek a szerkesztÅ‘terület alatt jelennek meg, és pl. itt található a kimenetet és az integrált terminál.", + "panelBorder": "A panelek keretszíne, ami elválasztja Å‘ket a szerkesztÅ‘ablakoktól. A panelek a szerkesztÅ‘terület alatt jelennek meg, és pl. itt található a kimenetet és az integrált terminál.", + "panelActiveTitleForeground": "Az aktív panel címsorának színe. A panelek a szerkesztÅ‘terület alatt jelennek meg, és pl. itt található a kimenetet és az integrált terminál.", + "panelInactiveTitleForeground": "Az inaktív panelek címsorának színe. A panelek a szerkesztÅ‘terület alatt jelennek meg, és pl. itt található a kimenetet és az integrált terminál.", + "panelActiveTitleBorder": "Az aktív panel címsorának keretszíne. A panelek a szerkesztÅ‘terület alatt jelennek meg, és pl. itt található a kimenetet és az integrált terminál.", + "statusBarForeground": "Az állapotsor elÅ‘térszíne. Az állapotsor az ablak alján jelenik meg.", + "statusBarBackground": "Az állapotsor alapértelmezett háttérszíne. Az állapotsor az ablak alján jelenik meg.", + "statusBarBorder": "Az állapotsort az oldalsávtól és a szerkesztÅ‘ablakoktól elválasztó keret színe. Az állapotsor az ablak alján jelenik meg.", + "statusBarNoFolderBackground": "Az állapotsor háttérszíne, ha nincs mappa megnyitva. Az állapotsor az ablak alján jelenik meg.", + "statusBarNoFolderForeground": "Az állapotsor elÅ‘térszíne, ha nincs mappa megnyitva. Az állapotsor az ablak alján jelenik meg.", + "statusBarItemActiveBackground": "Az állapotsor elemének háttérszíne kattintás esetén. Az állapotsor az ablak alján jelenik meg.", + "statusBarItemHoverBackground": "Az állapotsor elemének háttérszíne, ha az egérkurzor fölötte van. Az állapotsor az ablak alján jelenik meg.", + "statusBarProminentItemBackground": "Az állapotsor kiemelt elemeinek háttérszíne. A kiemelt elemek kitűnnek az állapotsor többi eleme közül, így jelezve a fontosságukat. Az állapotsor az ablak alján jelenik meg.", + "statusBarProminentItemHoverBackground": "Az állapotsor kiemelt elemeinek háttérszíne, ha az egérkurzor fölöttük van. A kiemelt elemek kitűnnek az állapotsor többi eleme közül, így jelezve a fontosságukat. Az állapotsor az ablak alján jelenik meg.", + "activityBarBackground": "A tevékenységsáv háttérszíne. A tevékenységsáv az ablak legszélén jelenik meg bal vagy jobb oldalon, segítségével lehet váltani az oldalsáv nézetei között.", + "activityBarForeground": "A tevékenységsáv elÅ‘térszíne (pl. az ikonok színe). A tevékenységsáv az ablak legszélén jelenik meg bal vagy jobb oldalon, segítségével lehet váltani az oldalsáv nézetei között.", + "activityBarBorder": "A tevékenyésgsáv keretszíne, ami elválasztja az oldalsávtól. A tevékenységsáv az ablak legszélén jelenik meg bal vagy jobb oldalon, segítségével lehet váltani az oldalsáv nézetei között.", + "activityBarDragAndDropBackground": "A tevékenységsáv elemeinek mozgatásánál használt visszajelzési szín. Érdemes átlátszó színt választani, hogy a tevékenységsáv elemei láthatóak maradjanak. A tevékenységsáv az ablak legszélén jelenik meg bal vagy jobb oldalon, segítségével lehet váltani az oldalsáv nézetei között.", + "activityBarBadgeBackground": "A tevékenységsáv értesítési jelvényeinek háttérszíne. A tevékenységsáv az ablak legszélén jelenik meg bal vagy jobb oldalon, segítségével lehet váltani az oldalsáv nézetei között.", + "activityBarBadgeForeground": "A tevékenységsáv értesítési jelvényeinek elÅ‘térszíne. A tevékenységsáv az ablak legszélén jelenik meg bal vagy jobb oldalon, segítségével lehet váltani az oldalsáv nézetei között.", + "sideBarBackground": "Az oldalsáv háttérszíne. Az oldalsávon található például a fájlkezelÅ‘ és a keresés nézet.", + "sideBarForeground": "Az oldalsáv elÅ‘térszíne. Az oldalsávon található például a fájlkezelÅ‘ és a keresés nézet.", + "sideBarBorder": "Az oldalsáv keretszíne, ami elválasztja a szerkesztÅ‘ablaktól. Az oldalsávon található például a fájlkezelÅ‘ és a keresés nézet.", + "sideBarTitleForeground": "Az oldalsáv címsorának elÅ‘térszíne. Az oldalsávon található például a fájlkezelÅ‘ és a keresés nézet.", + "sideBarSectionHeaderBackground": "Az oldalsáv szakaszfejlécének háttérszíne. Az oldalsávon található például a fájlkezelÅ‘ és a keresés nézet.", + "sideBarSectionHeaderForeground": "Az oldalsáv szakaszfejlécének elÅ‘térszíne. Az oldalsávon található például a fájlkezelÅ‘ és a keresés nézet.", + "titleBarActiveForeground": "A címsor elÅ‘térszíne, ha az ablak aktív. Megjegyzés: ez a beállítás jelenleg csak macOS-en támogatott.", + "titleBarInactiveForeground": "A címsor elÅ‘térszíne, ha az ablak inaktív. Megjegyzés: ez a beállítás jelenleg csak macOS-en támogatott.", + "titleBarActiveBackground": "A címsor háttérszíne, ha az ablak aktív. Megjegyzés: ez a beállítás jelenleg csak macOS-en támogatott.", + "titleBarInactiveBackground": "A címsor háttérszíne, ha az ablak inaktív. Megjegyzés: ez a beállítás jelenleg csak macOS-en támogatott.", + "notificationsForeground": "Az értesítések elÅ‘térszíne. Az értesítések az ablak tetején ugranak fel.", + "notificationsBackground": "Az értesítések háttérszíne. Az értesítések az ablak tetején ugranak fel.", + "notificationsButtonBackground": "Az értesítések gombjainak háttérszíne. Az értesítések az ablak tetején ugranak fel.", + "notificationsButtonHoverBackground": "Az értesítések gombjainak háttérszíne, ha az egérkurzor fölöttük van. Az értesítések az ablak tetején ugranak fel.", + "notificationsButtonForeground": "Az értesítések gombjainak elÅ‘térszíne. Az értesítések az ablak tetején ugranak fel.", + "notificationsInfoBackground": "Az információs értesítések háttérszíne. Az értesítések az ablak tetején ugranak fel.", + "notificationsInfoForeground": "Az információs értesítések elÅ‘térszíne. Az értesítések az ablak tetején ugranak fel.", + "notificationsWarningBackground": "A figyelmeztetÅ‘ értesítések háttérszíne. Az értesítések az ablak tetején ugranak fel.", + "notificationsWarningForeground": "A figyelmeztetÅ‘ értesítések elÅ‘térszíne. Az értesítések az ablak tetején ugranak fel.", + "notificationsErrorBackground": "A hibajelzÅ‘ értesítések háttérszíne. Az értesítések az ablak tetején ugranak fel.", + "notificationsErrorForeground": "A hibajelzÅ‘ értesítések elÅ‘térszíne. Az értesítések az ablak tetején ugranak fel." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/electron-browser/actions.i18n.json b/i18n/hun/src/vs/workbench/electron-browser/actions.i18n.json new file mode 100644 index 00000000000..623bfad721c --- /dev/null +++ b/i18n/hun/src/vs/workbench/electron-browser/actions.i18n.json @@ -0,0 +1,43 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "closeActiveEditor": "SzerkesztÅ‘ablak bezárása", + "closeWindow": "Ablak bezárása", + "closeFolder": "Mappa bezárása", + "noFolderOpened": "Ebben a példányban nincs mappa megnyitva, amit be lehetne zárni.", + "newWindow": "Új ablak", + "toggleFullScreen": "Teljes képernyÅ‘ be- és kikapcsolása", + "toggleMenuBar": "Menüsáv be- és kikapcsolása", + "toggleDevTools": "FejlesztÅ‘i eszközök be- és kikapcsolása", + "zoomIn": "Nagyítás", + "zoomOut": "Kicsinyítés", + "zoomReset": "Nagyítási szint alaphelyzetbe állítása", + "appPerf": "Indulási teljesítmény", + "reloadWindow": "Ablak újratöltése", + "switchWindowPlaceHolder": "Válassza ki az ablakot, amire váltani szeretne", + "current": "Aktuális ablak", + "switchWindow": "Ablak váltása...", + "quickSwitchWindow": "Gyors ablakváltás...", + "folders": "mappák", + "files": "fájlok", + "openRecentPlaceHolderMac": "Válasszon egy elérési utat! (A Cmd billentyű lenyomása esetén új ablakban nyílik meg)", + "openRecentPlaceHolder": "Válasszon egy elérési utat! (A Ctrl billentyű lenyomása esetén új ablakban nyílik meg)", + "openRecent": "Legutóbbi megnyitása...", + "quickOpenRecent": "Legutóbbi gyors megnyitása...", + "closeMessages": "Értesítések törlése", + "reportIssues": "Problémák jelentése", + "reportPerformanceIssue": "Teljesítményproblémák jelentése", + "keybindingsReference": "Billentyűparancs-referencia", + "openDocumentationUrl": "Dokumentáció", + "openIntroductoryVideosUrl": "Bemutatóvideók", + "toggleSharedProcess": "Megosztott folyamat be- és klikapcsolása", + "navigateLeft": "Navigálás a balra lévÅ‘ nézetre", + "navigateRight": "Navigálás a jobbra lévÅ‘ nézetre", + "navigateUp": "Navigálás a felül lévÅ‘ nézetre", + "navigateDown": "Navigálás az alul lévÅ‘ nézetre", + "increaseViewSize": "Jelenlegi nézet méretének növelése", + "decreaseViewSize": "Jelenlegi nézet méretének csökkentése" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/electron-browser/commands.i18n.json b/i18n/hun/src/vs/workbench/electron-browser/commands.i18n.json new file mode 100644 index 00000000000..3a1051dcfda --- /dev/null +++ b/i18n/hun/src/vs/workbench/electron-browser/commands.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "diffLeftRightLabel": "{0} ⟷ {1}" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/electron-browser/extensionHost.i18n.json b/i18n/hun/src/vs/workbench/electron-browser/extensionHost.i18n.json new file mode 100644 index 00000000000..41f2c6757d6 --- /dev/null +++ b/i18n/hun/src/vs/workbench/electron-browser/extensionHost.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "extensionHostProcess.startupFailDebug": "A kiegészítÅ‘ gazdafolyamata nem idult el 10 másodperben belül. ElképzelhetÅ‘, hogy megállt az elsÅ‘ soron, és szüksége van a hibakeresÅ‘re a folytatáshoz.", + "extensionHostProcess.startupFail": "A kiegészítÅ‘ gazdafolyamata nem idult el 10 másodperben belül. Ez probléma lehet.", + "extensionHostProcess.error": "A kiegészítÅ‘ gazdafolyamatától hiba érkezett: {0}", + "extensionHostProcess.crash": "A kiegészítÅ‘ gazdafolyamata váratlanul leállt. Töltse újra az ablakot a visszaállításhoz." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/hun/src/vs/workbench/electron-browser/main.contribution.i18n.json new file mode 100644 index 00000000000..65965e2d964 --- /dev/null +++ b/i18n/hun/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -0,0 +1,69 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "view": "Nézet", + "help": "Súgó", + "file": "Fájl", + "developer": "FejlesztÅ‘i", + "showEditorTabs": "Meghatározza, hogy a megnyitott szerkesztÅ‘ablakok telején megjelenjenek-e a fülek", + "editorTabCloseButton": "Meghatározza a szerkesztÅ‘ablakok fülein található bezárógomb pozícióját vagy eltávolítja Å‘ket, ha a beállítás értéke 'off'.", + "showIcons": "Meghatározza, hogy a megnyitott szerkesztÅ‘ablakok ikonnal együtt jelenjenek-e meg. A működéshez szükséges egy ikontéma engedélyezése is.", + "enablePreview": "Meghatározza, hogy a megnyitott szerkesztÅ‘ablakok elÅ‘nézetként jelenjenek-e meg. Az elÅ‘nézetként használt szerkesztÅ‘ablakok újra vannak hasznosítva, amíg meg nem tartja Å‘ket a felhasználó (pl. dupla kattintás vagy szerkesztés esetén).", + "enablePreviewFromQuickOpen": "Meghatározza, hogy a gyors megnyitás során megnyitott szerkesztÅ‘ablakok elÅ‘nézetként jelenjenek-e meg. Az elÅ‘nézetként használt szerkesztÅ‘ablakok újra vannak hasznosítva, amíg meg nem tartja Å‘ket a felhasználó (pl. dupla kattintás vagy szerkesztés esetén).", + "editorOpenPositioning": "Meghatározza, hogy hol nyíljanak meg a szerkesztÅ‘ablakok. A 'left' vagy 'right' használata esetén az aktív szerkesztÅ‘ablaktól jobbra vagy balra nyílnak meg az újak. A 'first' vagy 'last' esetén a szerkesztÅ‘ablakok a jelenleg aktív ablaktól függetlenül nyílnak meg.", + "revealIfOpen": "Meghatározza, hogy egy szerkesztÅ‘ablak fel legyen-e fedve, ha már meg van nyitva a látható csoportok bármelyiképben. Ha le van tiltva, akkor egy új szerkesztÅ‘ablak nyílik az aktív szerkesztÅ‘ablak-csoportban. Ha engedélyezve van, akkor a már megnyitott szerkesztÅ‘ablak lesz felfedve egy új megnyitása helyett. Megjegyzés: vannak esetek, amikor ez a beállítás figyelmen kívül van hagyva, pl. ha egy adott szerkesztÅ‘ablak egy konkrét csoportban vagy a jelenleg aktív csoport mellett van menyitva.", + "commandHistory": "Meghatározza, hogy mennyi legutóbb használt parancs jelenjen meg a parancskatalógus elÅ‘zményeinek listájában. Az elÅ‘zmények kikapcsolásához állítsa az értéket 0-ra.", + "preserveInput": "Meghatározza, hogy a legutóbb beírt parancs automatikusan helyre legyen-e állítva a parancskatalógus következÅ‘ megnyitása során.", + "closeOnFocusLost": "Meghatározza, hogy a gyors megnyitás automatikusan bezáródjon-e amint elveszíti a fókuszt.", + "openDefaultSettings": "Meghatározza, hogy a beállítások megnyitásakor megnyíljon-e egy szerkesztÅ‘ az összes alapértelmezett beállítással.", + "sideBarLocation": "Meghatározza az oldalsáv helyét. Az oldalsáv megjelenhet a munkaterület bal vagy jobb oldalán.", + "statusBarVisibility": "Meghatározza, hogy megjelenjen-e az állapotsor a munkaterület alján.", + "activityBarVisibility": "Meghatározza, hogy megjelenjen-e a tevékenységsáv a munkaterületen.", + "closeOnFileDelete": "Meghatározza, hogy bezáródjanak-e azok a szerkesztÅ‘ablakok, melyekben olyan fájl van megnyitva, amelyet töröl vagy átnevez egy másik folyamat. A beállítás letiltása esetén a szerkesztÅ‘ablak nyitva marad módosított állapotban ilyen esemény után. Megjegyzés: az alkalmazáson belüli törlések esetén mindig bezáródik a szerkesztÅ‘ablakok, a módosított fájlok pedig soha nem záródnak be, hogy az adatok megmaradjanak.", + "swipeToNavigate": "Navigálás a nyitott fájlok között háromujjas, vízszintes húzással.", + "workbenchConfigurationTitle": "Munkaterület", + "window.openFilesInNewWindow.on": "A fájlok új ablakban nyílnak meg", + "window.openFilesInNewWindow.off": "A fájlok abban az ablakban nyílnak meg, ahol a mappájuk meg van nyitva vagy a legutoljára aktív ablakban", + "window.openFilesInNewWindow.default": "A fájlok abban az ablakban nyílnak meg, ahol a mappájuk meg van nyitva vagy a legutoljára aktív ablakban, kivéve, ha a dokkról vagy a FinderbÅ‘l lettek megnyitva (csak macOS-en)", + "openFilesInNewWindow": "Meghatározza, hogy a fájlok új ablakban legyenek-e megnyitva.\n- default: A fájlok abban az ablakban nyílnak meg, ahol a mappájuk meg van nyitva vagy a legutoljára aktív ablakban, kivéve, ha a dokkról vagy a FinderbÅ‘l lettek megnyitva (csak macOS-en)\n- on: A fájlok új ablakban nyílnak meg.\n- off: A fájlok abban az ablakban nyílnak meg, ahol a mappájuk meg van nyitva vagy a legutoljára aktív ablakban\nMegjegyzés: vannak esetek, amikor ez a beállítás figyelmen kívül van hagyva (pl. a -new-window vagy a -reuse-window parancssori beállítás használata esetén).", + "window.openFoldersInNewWindow.on": "A mappák új ablakban nyílnak meg", + "window.openFoldersInNewWindow.off": "A mappák lecserélik a legutoljára aktív ablakot", + "window.openFoldersInNewWindow.default": "A mappák új ablakban nyílnak meg, kivéve akkor, ha a mappát az alkalmazáson belül lett kiválasztva (pl. a Fájl menübÅ‘l)", + "openFoldersInNewWindow": "Meghatározza, hogy a mappák új ablakban legyenek-e megnyitva.\n- alapértelmezett: A mappák új ablakban nyílnak meg, kivéve akkor, ha a mappát az alkalmazáson belül lett kiválasztva (pl. a Fájl menübÅ‘l)\n- on: A mappák új ablakban nyílnak meg\n- off: A mappák lecserélik a legutoljára aktív ablakot\nMegjegyzés: vannak esetek, amikor ez a beállítás figyelmen kívül van hagyva (pl. a -new-window vagy a -reuse-window parancssori beállítás használata esetén).", + "window.reopenFolders.all": "Összes ablak újranyitása.", + "window.reopenFolders.folders": "Összes mappa újranyitása. Az üres ablakok nem lesznek helyreállítva.", + "window.reopenFolders.one": "A legutóbbi aktív ablak újranyitása.", + "window.reopenFolders.none": "Soha ne nyisson meg újra ablakot. Mindig üresen induljon.", + "restoreWindows": "Meghatározza, hogy újraindítás után hogyan vannak ismét megnyitva az ablakok. A 'none' választása esetén mindig üres ablak indul, 'one' esetén a legutóbb használt ablak nyílik meg újra, a 'folders' megnyitja az összes megnyitott mappát, míg az 'all' újranyitja az összes ablakot az elÅ‘zÅ‘ munkamenetbÅ‘l.", + "restoreFullscreen": "Meghatározza, hogy az ablak teljesképernyÅ‘s módban nyíljon-e meg, ha kilépéskor teljes képernyÅ‘s módban volt.", + "zoomLevel": "Meghatározza az ablak nagyítási szintjét. Az eredei méret 0, és minden egyes plusz (pl. 1) vagy mínusz (pl. -1) 20%-kal nagyobb vagy kisebb nagyítási szintet jelent. Tizedestört megadása esetén a nagyítási szint finomabban állítható.", + "title": "Meghatározza az ablak címét az aktív szerkesztÅ‘ablak alapján. A változók a környezet alapján vannak behelyettesítve:\n${activeEditorShort}: pl. myFile.txt\n${activeEditorMedium}: pl. myFolder/myFile.txt\n${activeEditorLong}: pl. /Users/Development/myProject/myFolder/myFile.txt\n${rootName}: pl. myProject\n${rootPath}: pl. /Users/Development/myProject\n${appName}: pl. VS Code\n${dirty}: módosításjelzÅ‘, ami jelzi, ha az aktív szerkesztÅ‘ablak tartalma módosítva lett\n${separator}: feltételes elválasztó (\" - \"), ami akkor jelenik meg, ha olyan változókkal van körülvéve, amelyeknek van értéke\n", + "window.newWindowDimensions.default": "Az új ablakok a képernyÅ‘ közepén nyílnak meg.", + "window.newWindowDimensions.inherit": "Az új ablakok ugyanolyan méretben és ugyanazon a helyen jelennek meg, mint a legutoljára aktív ablak.", + "window.newWindowDimensions.maximized": "Az új ablakok teljes méretben nyílnak meg.", + "window.newWindowDimensions.fullscreen": "Az új ablakok teljes képernyÅ‘s módban nyílnak meg.", + "newWindowDimensions": "Meghatározza az új ablakok méretét és pozícióját, ha már legalább egy ablak meg van nyitva. Az új ablakok alapértlmezetten a képernyÅ‘ közepén, kis mérettel nyílnak meg. Ha az értéke 'inherit', az ablak ugyanazon méretben és pozícióban nyílik meg, mint a legutoljára aktív. Ha az értéke 'maximized', teljes méretben, ha pedig 'fullscreen' akkor teljes képernyÅ‘s módban nyílik meg. Megjegyzés: a beállítás nincs hatással az elsÅ‘ megnyitott ablakra. Az elsÅ‘ ablak mindig a bezárás elÅ‘tti mérettel és pozícióban nyílik meg.", + "window.menuBarVisibility.default": "A menü csak teljes képernyÅ‘s mód esetén van elrejtve.", + "window.menuBarVisibility.visible": "A menü mindig látható, még teljes képernyÅ‘ módban is.", + "window.menuBarVisibility.toggle": "A menü rejtett, de megjeleníthetÅ‘ az Alt billentyű lenyomásával.", + "window.menuBarVisibility.hidden": "A menü mindig el van rejtve.", + "menuBarVisibility": "Meghatározza a menüsáv láthatóságát. A 'toggle' érték azt jelenti, hogy a menüsáv rejtett, és az Alt billentyű lenyomására megjelenik. A menüsáv alapértelmezetten látható, kivéve, ha az ablak teljes képernyÅ‘s módban van.", + "enableMenuBarMnemonics": "Ha engedélyezve van, a fÅ‘menük megnyithatók Alt-billentyűs billentyűparancsokkal. Letiltás esetén ezek az Alt-billentyűparancsok más parancsokhoz rendelhetÅ‘k.", + "autoDetectHighContrast": "Ha engedélyezve van, az alkalmazás automatikusan átvált a nagy kontrasztos témára, ha a WIndows a nagy kontrasztos témát használ, és a sötét témára, ha a Windows átvált a nagy kontrasztos témáról.", + "titleBarStyle": "Módosítja az ablak címsorának megjelenését. A változtatás teljes újraindítást igényel.", + "window.nativeTabs": "Engedélyezi a macOS Sierra ablakfüleket. Megjegyzés: a változtatás teljes újraindítást igényel, és a natív fülek letiltják az egyedi címsorstílust, ha azok be vannak konfigurálva.", + "windowConfigurationTitle": "Ablak", + "zenModeConfigurationTitle": "Zen-mód", + "zenMode.fullScreen": "Meghatározza, hogy zen-módban a munakterület teljes képernyÅ‘s módba vált-e.", + "zenMode.hideTabs": "Meghatározza, hogy zen-módban el vannak-e rejtve a munkaterület fülei.", + "zenMode.hideStatusBar": "Meghatározza, hogy zen-módban el van-e rejtve a munkaterület alján található állapotsor.", + "zenMode.hideActivityBar": "Meghatározza, hogy zen-módban el van-e rejtve a munkaterület bal oldalán található tevékenységsáv.", + "zenMode.restore": "Meghatározza, hogy az ablak zen-módban induljon-e, ha kilépéskor zen-módban volt.", + "workspaceConfigurationTitle": "Munkaterület", + "workspaces.title": "A munkaterület mappakonfiugrációja", + "files.exclude.boolean": "A globális minta, amire illesztve lesznek a fájlok elérési útjai. A minta engedélyezéséhez vagy letiltásához állítsa igaz vagy hamis értékre.", + "workspaces.additionalFolders": "A munkaterület mappái" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/electron-browser/main.i18n.json b/i18n/hun/src/vs/workbench/electron-browser/main.i18n.json new file mode 100644 index 00000000000..35ad4a784e8 --- /dev/null +++ b/i18n/hun/src/vs/workbench/electron-browser/main.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "loaderError": "Az egyik szükséges fájlt nem sikerült betölteni. Vagy megszakadt az internetkapcsolat, vagy a kiszolgáló vált offline-ná. Frissítse az oldalt a böngészÅ‘ben, és próbálkozzon újra.", + "loaderErrorNative": "Egy szükséges fájl betöltése nem sikerült. Indítsa újra az alkalmazást, és próbálkozzon újra. Részletek: {0}" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/electron-browser/shell.i18n.json b/i18n/hun/src/vs/workbench/electron-browser/shell.i18n.json new file mode 100644 index 00000000000..f9fefa3fe2d --- /dev/null +++ b/i18n/hun/src/vs/workbench/electron-browser/shell.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "runningAsRoot": "Nem ajánlott a Code-ot 'root'-ként futtatni." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/electron-browser/window.i18n.json b/i18n/hun/src/vs/workbench/electron-browser/window.i18n.json new file mode 100644 index 00000000000..13f0befdb66 --- /dev/null +++ b/i18n/hun/src/vs/workbench/electron-browser/window.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "undo": "Visszavonás", + "redo": "Újra", + "cut": "Kivágás", + "copy": "Másolás", + "paste": "Beillesztés", + "selectAll": "Összes kijelölése", + "confirmOpen": "Biztosan meg akar nyitni {0} mappát?", + "confirmOpenButton": "&&Megnyitás" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/hun/src/vs/workbench/electron-browser/workbench.i18n.json new file mode 100644 index 00000000000..e230783dedd --- /dev/null +++ b/i18n/hun/src/vs/workbench/electron-browser/workbench.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "developer": "FejlesztÅ‘i", + "file": "Fájl" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/node/extensionHostMain.i18n.json b/i18n/hun/src/vs/workbench/node/extensionHostMain.i18n.json new file mode 100644 index 00000000000..acba56dc6e9 --- /dev/null +++ b/i18n/hun/src/vs/workbench/node/extensionHostMain.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "extensionTestError": "Az {0} elérési út nem érvényes kiegészítÅ‘ tesztfuttató alkalmazásra mutat." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/node/extensionPoints.i18n.json b/i18n/hun/src/vs/workbench/node/extensionPoints.i18n.json new file mode 100644 index 00000000000..e9cae50ed45 --- /dev/null +++ b/i18n/hun/src/vs/workbench/node/extensionPoints.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "jsonParseFail": "Hiba a(z) {0} feldolgozása közben: {1}.", + "fileReadFail": "A(z) ({0}) fájl nem olvasható: {1}.", + "jsonsParseFail": "Hiba a(z) {0} vagy {1} feldolgozása közben: {2}.", + "missingNLSKey": "A(z) {0} kulcshoz tartozó üzenet nem található." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/cli/electron-browser/cli.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/cli/electron-browser/cli.contribution.i18n.json new file mode 100644 index 00000000000..371e0ad88d7 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/cli/electron-browser/cli.contribution.i18n.json @@ -0,0 +1,18 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "install": "'{0}' parancs telepítése a PATH-ba", + "not available": "Ez a parancs nem érhetÅ‘ el.", + "successIn": "A(z) '{0}' rendszerparancs sikeresen telepítve lett a PATH-ba.", + "warnEscalation": "A Code adminisztrátori jogosultságot fog kérni az 'osascript'-tel a rendszerparancs telepítéséhez.", + "ok": "OK", + "cantCreateBinFolder": "Nem sikerült létrehozni az '/usr/local/bin' könyvtárat.", + "cancel2": "Mégse", + "aborted": "Megszakítva", + "uninstall": "'{0}' parancs eltávolítása a PATH-ból", + "successFrom": "A(z) '{0}' rendszerparancs sikeresen el lett a PATH-ból.", + "shellCommand": "Rendszerparancs" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json b/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json new file mode 100644 index 00000000000..0edff5007de --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json @@ -0,0 +1,26 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "emergencyConfOn": "Az `editor.accessibilitySupport` beállítás értékének beállítása a következÅ‘re: 'on'.", + "openingDocs": "A VS Code kisegítÅ‘ lehetÅ‘ségei dokumentációjának megnyitása.", + "introMsg": "Köszönjük, hogy kipróbálta a VS Code kisegítÅ‘ lehetÅ‘ségeit.", + "status": "Ãllapot:", + "changeConfigToOnMac": "A szerkesztÅ‘ folyamatos képernyÅ‘olvasóval való használatára optimalizálásához nyomja meg a Command+E gombot!", + "changeConfigToOnWinLinux": "A szerkesztÅ‘ folyamatos képernyÅ‘olvasóval való használatára optimalizálásához nyomja meg a Control+E gombot!", + "auto_unknown": "A szerkesztÅ‘ úgy van konfigurálva, hogy a platform által biztosított API-kat használja annak megállapításához, hogy van-e képernyÅ‘olvasó csatlakoztatva, azonban a jelenlegi futtatókörnyezet ezt nem támogatja.", + "auto_on": "A szerkesztÅ‘ automatikusan észlelte a csatlakoztatott képernyÅ‘olvasót.", + "auto_off": "A szerkesztÅ‘ úgy van konfigurálva, hogy automatikusan érzékelkje, ha képernyÅ‘olvasó van csatlakoztatva. Jelenleg nincs csatlakoztatva.", + "configuredOn": "A szerkesztÅ‘ folyamatos képernyÅ‘olvasóval való használatára van optimalizálva – ez az `editor.accessibilitySupport` beállítás módosításával változtatható.", + "configuredOff": "A szerkesztÅ‘ úgy van konfigurálva, hogy soha nincs képernyÅ‘olvasó használatára optimalizálva.", + "tabFocusModeOnMsg": "Az aktuális szerkesztÅ‘ablakban a Tab billentyű lenyomása esetén a fókusz a következÅ‘ fókuszálható elemre kerül. Ez a viselkedés a(z) {0} leütésével módosítható.", + "tabFocusModeOnMsgNoKb": "Az aktuális szerkesztÅ‘ablakban a Tab billentyű lenyomása esetén a fókusz a következÅ‘ fókuszálható elemre kerül. A(z) {0} parancs jelenleg nem aktiválható billentyűkombinációval.", + "tabFocusModeOffMsg": "Az aktuális szerkesztÅ‘ablakban a Tab billentyű lenyomása esetén beszúrásra kerül egy tabulátor karakter. Ez a viselkedés a(z) {0} leütésével módosítható.", + "tabFocusModeOffMsgNoKb": "Az aktuális szerkesztÅ‘ablakban a Tab billentyű lenyomása esetén beszúrásra kerül egy tabulátor karakter. A(z) {0} parancs jelenleg nem aktiválható billentyűkombinációval.", + "openDocMac": "VS Code kisegítÅ‘ lehetÅ‘ségeivel kapcsolatos információk böngészÅ‘ben való megjelenítéséhez nyomja meg a Command+H billentyűkombinációt!", + "openDocWinLinux": "VS Code kisegítÅ‘ lehetÅ‘ségeivel kapcsolatos információk böngészÅ‘ben való megjelenítéséhez nyomja meg a Control+H billentyűkombinációt!", + "outroMsg": "A súgószöveg eltüntetéséhez és a szerkesztÅ‘ablakba való visszatéréshez nyomja meg az Escape billentyűt vagy a Shift+Escape billentyűkombinációt!", + "ShowAccessibilityHelpAction": "KisegítÅ‘ lehetÅ‘ségek súgó megjelenítése" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json b/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json new file mode 100644 index 00000000000..b01c9a81930 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "workbench.action.inspectKeyMap": "FejlesztÅ‘i: Billentyűkiosztás vizsgálata" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json b/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json b/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json new file mode 100644 index 00000000000..a0a8e4d8928 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleLocation": "Többkurzoros módosító be- és kikapcsolása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderControlCharacter.i18n.json b/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderControlCharacter.i18n.json new file mode 100644 index 00000000000..79c5e7716ee --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderControlCharacter.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleRenderControlCharacters": "VezérlÅ‘karakterek be- és kikapcsolása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderWhitespace.i18n.json b/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderWhitespace.i18n.json new file mode 100644 index 00000000000..e496d62b102 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderWhitespace.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleRenderWhitespace": "Szóközök kirajzolásának be- és kikapcsolása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json b/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json new file mode 100644 index 00000000000..02a67dbe146 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggle.wordwrap": "Nézet: Sortörés be- és kikapcsolása", + "wordWrap.notInDiffEditor": "A sortörés nem kapcsolható be vagy ki differenciaszerkesztÅ‘ben.", + "unwrapMinified": "Sortörés letiltása ebben a fájlban", + "wrapMinified": "Sortörés engedélyezése ebben a fájlban" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/wordWrapMigration.i18n.json b/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/wordWrapMigration.i18n.json new file mode 100644 index 00000000000..1631851aee5 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/codeEditor/electron-browser/wordWrapMigration.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "wordWrapMigration.ok": "OK", + "wordWrapMigration.dontShowAgain": "Ne jelenjen meg újra", + "wordWrapMigration.openSettings": "Beállítások megnyitása", + "wordWrapMigration.prompt": "Az `editor.wrappingColumn` beállítás elavult az `editor.wordWrap` bevezetése miatt." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/browser/breakpointWidget.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/browser/breakpointWidget.i18n.json new file mode 100644 index 00000000000..9a0eccdde50 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/browser/breakpointWidget.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "breakpointWidgetExpressionPlaceholder": "Futás megállítása, ha a kifejezés értéke igazra értékelÅ‘dik ki. 'Enter' a megerÅ‘sítéshez vagy 'Escape' a megszakításhoz.", + "breakpointWidgetAriaLabel": "A program csak akkor áll meg itt, ha a feltétel igaz. Nyomjon 'Enter'-t a megerÅ‘sítéshez vagy 'Escape'-et a megszakításhoz.", + "breakpointWidgetHitCountPlaceholder": "Futás megállítása, ha adott alkalommal érintve lett. 'Enter' a megerÅ‘sítéshez vagy 'Escape' a megszakításhoz.", + "breakpointWidgetHitCountAriaLabel": "A program akkor fog megállni itt, ha adott alkalommal érintette ezt a pontot. Nyomjon 'Enter'-t a megerÅ‘sítéshez vagy 'Escape'-et a megszakításhoz.", + "expression": "Kifejezés", + "hitCount": "Érintések száma" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/browser/debugActionItems.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/browser/debugActionItems.i18n.json new file mode 100644 index 00000000000..c7cfbc8b3ba --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/browser/debugActionItems.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "addConfiguration": "Konfiguráció hozzáadása...", + "noConfigurations": "Nincs konfiguráció" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/browser/debugActions.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/browser/debugActions.i18n.json new file mode 100644 index 00000000000..e98acd71fa1 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/browser/debugActions.i18n.json @@ -0,0 +1,49 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openLaunchJson": "{0} megnyitása", + "launchJsonNeedsConfigurtion": "'launch.json' konfigurálása vagy javítása", + "noFolderDebugConfig": "Fejlettebb hibakeresési konfigurációk használatához nyisson meg egy mappát!", + "startDebug": "Hibakeresés indítása", + "startWithoutDebugging": "Indítás hibakeresés nélkül", + "selectAndStartDebugging": "Hibakeresés kiválasztása és indítása", + "restartDebug": "Újraindítás", + "reconnectDebug": "Újracsatlakozás", + "stepOverDebug": "Ãtugrás", + "stepIntoDebug": "Belépés", + "stepOutDebug": "Kilépés", + "stopDebug": "Leállítás", + "disconnectDebug": "Kapcsolat bontása", + "continueDebug": "Folytatás", + "pauseDebug": "Szüneteltetés", + "restartFrame": "Keret újraindítása", + "removeBreakpoint": "Töréspont eltávolítása", + "removeAllBreakpoints": "Összes töréspont eltávolítása", + "enableBreakpoint": "Töréspont engedélyezése", + "disableBreakpoint": "Töréspont letiltása", + "enableAllBreakpoints": "Összes töréspont engedélyezése", + "disableAllBreakpoints": "Összes töréspont letiltása", + "activateBreakpoints": "Töréspontok aktiválása", + "deactivateBreakpoints": "Töréspontok deaktiválása", + "reapplyAllBreakpoints": "Töréspontok felvétele ismét", + "addFunctionBreakpoint": "Függvénytöréspont hozzáadása", + "renameFunctionBreakpoint": "Függvénytöréspont átnevezése", + "addConditionalBreakpoint": "Feltételes töréspont hozzáadása...", + "editConditionalBreakpoint": "Töréspont szerkesztése...", + "setValue": "Érték beállítása", + "addWatchExpression": "Kifejezés hozzáadása", + "editWatchExpression": "Kifejezés szerkesztése", + "addToWatchExpressions": "Hozzáadás a figyelÅ‘listához", + "removeWatchExpression": "Kifejezés eltávolítása", + "removeAllWatchExpressions": "Összes kifejezés eltávolítása", + "clearRepl": "Konzoltartalom törlése", + "debugConsoleAction": "Hibakeresési konzol", + "unreadOutput": "Új kimenet a hibakeresési konzolban", + "debugFocusConsole": "Váltás a hibakeresési konzolra", + "focusProcess": "Váltás a folyamatra", + "stepBackDebug": "Visszalépés", + "reverseContinue": "Visszafordítás" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/browser/debugActionsWidget.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/browser/debugActionsWidget.i18n.json new file mode 100644 index 00000000000..fa1bc4e164b --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/browser/debugActionsWidget.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "debugToolBarBackground": "A hibakeresési eszköztár háttérszíne." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/browser/debugContentProvider.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/browser/debugContentProvider.i18n.json new file mode 100644 index 00000000000..b66b9f52e68 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/browser/debugContentProvider.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "unable": "Az erÅ‘forrás nem oldható fel hibakeresési munkamenet nélkül" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/browser/debugEditorActions.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/browser/debugEditorActions.i18n.json new file mode 100644 index 00000000000..7d9b38824da --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/browser/debugEditorActions.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleBreakpointAction": "Hibakeresés: Töréspont be- és kikapcsolása", + "columnBreakpointAction": "Hibakeresés: Töréspont oszlopnál", + "columnBreakpoint": "Oszlop töréspont hozzáadása", + "conditionalBreakpointEditorAction": "Hibakeresés: Feltételes töréspont...", + "runToCursor": "Futtatás a kurzorig", + "debugEvaluate": "Hibakeresés: Kiértékelés", + "debugAddToWatch": "Hibakeresés: Hozzáadás a figyelÅ‘listához", + "showDebugHover": "Hibakeresés: Súgószöveg megjelenítése" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/browser/debugEditorModelManager.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/browser/debugEditorModelManager.i18n.json new file mode 100644 index 00000000000..bbe58d3ce42 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/browser/debugEditorModelManager.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "breakpointDisabledHover": "Letiltott töréspont", + "breakpointUnverifieddHover": "Nem megerÅ‘sített töréspont", + "breakpointDirtydHover": "Nem megerÅ‘sített töréspont. A fájl módosult, indítsa újra a hibakeresési munkamenetet.", + "breakpointUnsupported": "Ez a hibakeresÅ‘ nem támogatja a feltételes töréspontokat" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/browser/debugQuickOpen.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/browser/debugQuickOpen.i18n.json new file mode 100644 index 00000000000..4020242c40c --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/browser/debugQuickOpen.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, hibakeresés", + "debugAriaLabel": "Ãrja be a futtatandó konfiguráció nevét.", + "noConfigurationsMatching": "Nincs illeszkedÅ‘ hibakeresési konfiguráció", + "noConfigurationsFound": "Nem található hibakeresési konfiguráció. Készítsen egy 'launch.json' fájlt." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/browser/exceptionWidget.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/browser/exceptionWidget.i18n.json new file mode 100644 index 00000000000..37b31bfd19b --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/browser/exceptionWidget.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "debugExceptionWidgetBorder": "A kivételmodul keretszíne.", + "debugExceptionWidgetBackground": "A kivételmodul háttérszíne.", + "exceptionThrownWithId": "Kivétel következett be: {0}", + "exceptionThrown": "Kivétel következett be." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/browser/linkDetector.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/browser/linkDetector.i18n.json new file mode 100644 index 00000000000..8e0e584901b --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/browser/linkDetector.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "fileLinkMac": "Megnyitás kattintásra (Cmd + kattintásra oldalt nyitja meg)", + "fileLink": "Megnyitás kattintásra (Ctrl + kattintásra oldalt nyitja meg)" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/common/debug.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/common/debug.i18n.json new file mode 100644 index 00000000000..bceb3f2cf21 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/common/debug.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "internalConsoleOptions": "Meghatározza a belsÅ‘ hibakeresési konzol viselkedését." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/common/debugModel.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/common/debugModel.i18n.json new file mode 100644 index 00000000000..a3704d30698 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/common/debugModel.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "notAvailable": "nem elérhetÅ‘", + "startDebugFirst": "Indítson egy hibakeresési folyamatot a kiértékeléshez" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/common/debugSource.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/common/debugSource.i18n.json new file mode 100644 index 00000000000..4054145e143 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/common/debugSource.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "unknownSource": "Ismeretlen forrás" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debug.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debug.contribution.i18n.json new file mode 100644 index 00000000000..fa24086f101 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debug.contribution.i18n.json @@ -0,0 +1,20 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleDebugViewlet": "Hibakeresés megjelenítése", + "toggleDebugPanel": "Hibakeresési konzol", + "debug": "Hibakeresés", + "debugPanel": "Hibakeresési konzol", + "view": "Nézet", + "debugCategory": "Hibakeresés", + "debugCommands": "Hibakeresési konfiguráció", + "debugConfigurationTitle": "Hibakeresés", + "allowBreakpointsEverywhere": "Bármelyik fájlban helyezhetÅ‘ el töréspont", + "openExplorerOnEnd": "Hibakeresési munkamenet végén automatikusan nyíljon meg a fájlkezelÅ‘ nézet", + "inlineValues": "Változók értékének megjelenítése a sorok között hibakeresés közben", + "hideActionBar": "Meghatározza, hogy megjelenjen-e a lebegÅ‘ hibakeresési műveletsáv", + "launch": "Globális hibakeresés indítási konfiguráció. Használható a 'launch.json' alternatívájaként, ami meg van osztva több munkaterület között" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json new file mode 100644 index 00000000000..096d97567fc --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noFolderDebugConfig": "Fejlettebb hibakeresési konfigurációk használatához nyisson meg egy mappát!" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugConfigurationManager.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugConfigurationManager.i18n.json new file mode 100644 index 00000000000..7f6a09aa689 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugConfigurationManager.i18n.json @@ -0,0 +1,38 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.debuggers": "Hibakeresési illesztÅ‘ket szolgáltat.", + "vscode.extension.contributes.debuggers.type": "A hibakeresési illesztÅ‘ egyedi azonosítója.", + "vscode.extension.contributes.debuggers.label": "A hibakeresési illesztÅ‘ megjelenített neve.", + "vscode.extension.contributes.debuggers.program": "A hibakeresési illesztÅ‘ program elérési útja. Az elérési út lehet abszolút vagy relatív a kiegészítÅ‘ mappájához képest.", + "vscode.extension.contributes.debuggers.args": "Az illesztÅ‘ számára átadott argumentumok.", + "vscode.extension.contributes.debuggers.runtime": "KiegészítÅ‘ futtatókörnyezet arra az esetre, ha a program attribútum nem egy futtatható fájl, és futtatókörnyezetre van szüksége.", + "vscode.extension.contributes.debuggers.runtimeArgs": "KiegészítÅ‘ argumentumok a futtatókörnyezet számára.", + "vscode.extension.contributes.debuggers.variables": "A `launch.json`-ban található interaktív változók (pl. ${action.pickProcess}) hozzárendelése parancsokhoz.", + "vscode.extension.contributes.debuggers.initialConfigurations": "Konfigurációk a 'launch.json' elsÅ‘ változatának elkészítéséhez.", + "vscode.extension.contributes.debuggers.languages": "Azon nyelvek listája, amelyeknél ez a hibakeresési kiegészítÅ‘ alapértelmezett hibakeresÅ‘nek tekinthetÅ‘.", + "vscode.extension.contributes.debuggers.adapterExecutableCommand": "Ha meg van adva, a VS Code ezt a parancsot fogja hívni a hibakeresési illesztÅ‘ futtatható állománya elérési útjának és az átadandó argumentumok meghatározásához.", + "vscode.extension.contributes.debuggers.startSessionCommand": "Ha meg van határozva, a VS Code ezt a parancsot fogja hívni az ennek a kiegészítÅ‘nek küldött \"debug\" vagy \"run\" parancsok esetén.", + "vscode.extension.contributes.debuggers.configurationSnippets": "Kódtöredékek új 'launch.json'-konfigurációk hozzáadásához.", + "vscode.extension.contributes.debuggers.configurationAttributes": "JSON-sémakonfigurációk a 'launch.json' validálásához.", + "vscode.extension.contributes.debuggers.windows": "Windows-specifikus beállítások.", + "vscode.extension.contributes.debuggers.windows.runtime": "A Windows által használt futtatókörnyezet.", + "vscode.extension.contributes.debuggers.osx": "OS X-specifikus beállítások.", + "vscode.extension.contributes.debuggers.osx.runtime": "Az OSX által használt futtatókörnyezet.", + "vscode.extension.contributes.debuggers.linux": "Linux-specifikus beállítások.", + "vscode.extension.contributes.debuggers.linux.runtime": "A Linux által használt futtatókörnyezet.", + "vscode.extension.contributes.breakpoints": "Töréspontokat szolgáltat.", + "vscode.extension.contributes.breakpoints.language": "Töréspontok engedélyezése ennél a nyelvnél.", + "app.launch.json.title": "Indítás", + "app.launch.json.version": "A fájlformátum verziója.", + "app.launch.json.configurations": "A konfigurációk listája. Új konfigurációk hozzáadhatók vagy a meglévÅ‘k szerkeszthetÅ‘k az IntelliSense használatával.", + "app.launch.json.compounds": "A kombinációk listája. Minden kombináció több konfigurációt hivatkozik meg, melyek együtt indulnak el.", + "app.launch.json.compound.name": "A kombináció neve. Az indítási konfiguráció lenyíló menüjében jelenik meg.", + "app.launch.json.compounds.configurations": "Azon konfigurációk neve, melyek elindulnak ezen kombináció részeként.", + "debugNoType": "A hibakeresési illesztÅ‘ 'type' tulajdonsága kötelezÅ‘, és 'string' típusúnak kell lennie.", + "DebugConfig.failed": "Nem sikerült létrehozni a 'launch.json' fájlt a '.vscode' mappánan ({0}).", + "selectDebug": "Környezet kiválasztása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.i18n.json new file mode 100644 index 00000000000..dde28938129 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.i18n.json @@ -0,0 +1,20 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "removeBreakpoints": "Töréspontok eltávolítása", + "removeBreakpointOnColumn": "{0}. oszlopban található töréspont eltávolítása", + "removeLineBreakpoint": "Sorra vonatkozó töréspont eltávolítása", + "editBreakpoints": "Töréspontok szerkesztése", + "editBreakpointOnColumn": "{0}. oszlopban található töréspont szerkesztése", + "editLineBrekapoint": "Sorra vonatkozó töréspont szerkesztése", + "enableDisableBreakpoints": "Töréspontok engedélyezése/letiltása", + "disableColumnBreakpoint": "{0}. oszlopban található töréspont letiltása", + "disableBreakpointOnLine": "Sorszintű töréspont letiltása", + "enableBreakpoints": "{0}. oszlopban található töréspont engedélyezése", + "enableBreakpointOnLine": "Sorszintű töréspont engedélyezése", + "addBreakpoint": "Töréspont hozzáadása", + "addConfiguration": "Konfiguráció hozzáadása..." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugHover.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugHover.i18n.json new file mode 100644 index 00000000000..c222653e922 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugHover.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "treeAriaLabel": "Hibakeresési súgószöveg" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json new file mode 100644 index 00000000000..644abcafd01 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json @@ -0,0 +1,25 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "snapshotObj": "Ennél az objektumhoz csak a primitív értékek vannak megjelenítve.", + "debuggingPaused": "Hibakeresés szüneteltetve, oka: {0}, {1} {2}", + "debuggingStarted": "Hibakeresés elindítva.", + "debuggingStopped": "Hibakeresés leállítva.", + "breakpointAdded": "Töréspont hozzáadva, {0}. sor, fájl: {1}", + "breakpointRemoved": "Töréspont eltávoíltva, {0}. sor, fájl: {1}", + "compoundMustHaveConfigurations": "A kombinációk \"configurations\" tulajdonságát be kell állítani több konfiguráció elindításához.", + "configMissing": "A(z) '{0}' konfiguráció hiányzik a 'launch.json'-ból.", + "debugTypeNotSupported": "A megadott hibakeresési típus ('{0}') nem támogatott.", + "debugTypeMissing": "A kiválasztott indítási konfigurációnak hiányzik a 'type' tulajdonsága.", + "preLaunchTaskErrors": "Buildelési hibák léptek fel a(z) '{0}' preLaunchTask futása közben.", + "preLaunchTaskError": "Buildelési hiba lépett fel a(z) '{0}' preLaunchTask futása közben.", + "preLaunchTaskExitCode": "A(z) '{0}' preLaunchTask a következÅ‘ hibakóddal fejezÅ‘dött be: {1}.", + "debugAnyway": "Hibakeresés indítása mindenképp", + "noFolderWorkspaceDebugError": "Az aktív fájlon nem lehet hibakeresést végezni. Bizonyosodjon meg róla, hogy el van mentve a lemezre, és hogy az adott fájltípushoz telepítve van a megfelelÅ‘ hibakeresési kiegészítÅ‘.", + "NewLaunchConfig": "Ãllítson be egy indítási konfigurációt az alkalmazása számára. {0}", + "DebugTaskNotFound": "A(z) '{0}' preLaunchTask nem található.", + "differentTaskRunning": "A(z) {0} feladat már fut. Nem futtatható a(z) {1} indítás elÅ‘tti feladat." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugViewer.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugViewer.i18n.json new file mode 100644 index 00000000000..b11dd377626 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugViewer.i18n.json @@ -0,0 +1,28 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "process": "Folyamat", + "paused": "Szüneteltetve", + "running": "Fut", + "thread": "Szál", + "pausedOn": "Szüneteltetve a következÅ‘ helyen: {0}", + "loadMoreStackFrames": "További veremkeretek betöltése", + "threadAriaLabel": "Szál: {0}, hívási verem, hibakeresés", + "stackFrameAriaLabel": "{0} veremkeret, {0}. sor {1} {2}, hívási verem, hibakeresés", + "variableValueAriaLabel": "Adja meg a változó új nevét", + "variableScopeAriaLabel": "{0} hatókör, változók, hibakeresés", + "variableAriaLabel": "{0} értéke {1}, változók, hibakeresés", + "watchExpressionPlaceholder": "FigyelendÅ‘ kifejezés", + "watchExpressionInputAriaLabel": "Adja meg a figyelendÅ‘ kifejezést", + "watchExpressionAriaLabel": "{0} értéke {1}, figyelt, hibakeresés", + "watchVariableAriaLabel": "{0} értéke {1}, figyelt, hibakeresés", + "functionBreakpointPlaceholder": "A függvény, amin meg kell állni", + "functionBreakPointInputAriaLabel": "Adja meg a függvénytöréspontot", + "functionBreakpointsNotSupported": "Ez a hibakeresÅ‘ nem támogatja a függvénytöréspontokat", + "breakpointAriaLabel": "Töréspont a(z) {0}. sorban {1}, töréspontok, hibakeresés", + "functionBreakpointAriaLabel": "{0} függvénytöréspont, töréspontok, hibakeresés", + "exceptionBreakpointAriaLabel": "{0} kivételtöréspont, töréspontok, hibakeresés" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json new file mode 100644 index 00000000000..e7e17b09fd6 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "variablesSection": "Változók szakasz", + "variablesAriaTreeLabel": "Hibakeresési változók", + "expressionsSection": "Kifejezések szaszasz", + "watchAriaTreeLabel": "Hibakeresési figyelÅ‘kifejezések", + "callstackSection": "Hívási verem szakasz", + "debugStopped": "Szüneteltetve a következÅ‘ helyen: {0}", + "callStackAriaLabel": "Hibakeresési hívási verem", + "breakpointsSection": "Töréspontok szakasz", + "breakpointsAriaTreeLabel": "Hibakeresési töréspontok" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json new file mode 100644 index 00000000000..b71c6795fa6 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "copyValue": "Érték másolása", + "copy": "Másolás", + "copyAll": "Összes másolása", + "copyStackTrace": "Hívási verem másolása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.i18n.json new file mode 100644 index 00000000000..fb49eeb2cdb --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "moreInfo": "További információ", + "unableToLaunchDebugAdapter": "Nem sikerült elindítani a hibakeresési illesztÅ‘t a következÅ‘ helyrÅ‘l: '{0}'.", + "unableToLaunchDebugAdapterNoArgs": "Nem sikerült elindítani a hibakeresési illesztÅ‘t.", + "stoppingDebugAdapter": "{0}. Hibakeresési illesztÅ‘ leállítása.", + "debugAdapterCrash": "A hibakeresési illesztÅ‘ folyamata váratlanul leállt" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/electron-browser/repl.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/repl.i18n.json new file mode 100644 index 00000000000..2490789235b --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/repl.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "replAriaLabel": "REPL-panel", + "actions.repl.historyPrevious": "ElÅ‘zÅ‘ az elÅ‘zményekbÅ‘l", + "actions.repl.historyNext": "KövetkezÅ‘ az elÅ‘zményekbÅ‘l", + "actions.repl.acceptInput": "REPL bemenet elfogadása", + "actions.repl.copyAll": "Hibakeresés: Összes másolása a konzolból" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/electron-browser/replViewer.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/replViewer.i18n.json new file mode 100644 index 00000000000..929096a6c43 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/replViewer.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "stateCapture": "Az objekum állapota az elsÅ‘ kiértékelés idején", + "replVariableAriaLabel": "A(z) {0} változó értéke: {1}, REPL, hibakeresés", + "replExpressionAriaLabel": "A(z) {0} kifejezés értéke: {1}, REPL, hibakeresés", + "replValueOutputAriaLabel": "{0}, REPL, hibakeresés", + "replKeyValueOutputAriaLabel": "A(z) {0} kimeneti változó értéke: {1}, REPL, hibakeresés" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json new file mode 100644 index 00000000000..861e45437c7 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "statusBarDebuggingBackground": "Az állapotsor háttérszíne, ha a programon hibakeresés folyik. Az állapotsor az ablak alján jelenik meg.", + "statusBarDebuggingForeground": "Az állapotsor elÅ‘térszíne, ha a programon hibakeresés folyik. Az állapotsor az ablak alján jelenik meg." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/electron-browser/terminalSupport.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/terminalSupport.i18n.json new file mode 100644 index 00000000000..8e82d560ff0 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/electron-browser/terminalSupport.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "debug.terminal.title": "hibakeresÅ‘", + "debug.terminal.not.available.error": "Az integrált terminál nem elérhetÅ‘" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json b/i18n/hun/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json new file mode 100644 index 00000000000..6b2154af74d --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json @@ -0,0 +1,20 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "debugAdapterBinNotFound": "A hibakeresési illesztÅ‘ futtatható állománya ('{0}') nem létezik.", + "debugAdapterCannotDetermineExecutable": "Nem határozható meg a(z) '{0}' hibakeresési illesztÅ‘ futtatható állománya.", + "debugType": "A konfiguráció típusa.", + "debugTypeNotRecognised": "Ez a hibakeresési típus nem ismert. Bizonyosodjon meg róla, hogy telepítve és engedélyezve van a megfelelÅ‘ hibakeresési kiegészítÅ‘.", + "node2NotSupported": "A \"node2\" már nem támogatott. Használja helyette a \"node\"-ot, és állítsa a \"protocol\" attribútum értékét \"inspector\"-ra.", + "debugName": "A konfiguráció neve. Az indítási konfiguráció lenyíló menüjében jelenik meg.", + "debugRequest": "A konfiguráció kérési típusa. Lehet \"launch\" vagy \"attach\".", + "debugServer": "Csak hibakeresési kiegészítÅ‘k fejlesztéséhez: ha a port meg van adva, akkor a VS Code egy szerver módban futó hibakeresési illesztÅ‘höz próbál meg csatlakozni.", + "debugPrelaunchTask": "A hibakeresési folyamat elÅ‘tt futtatandó feladat.", + "debugWindowsConfiguration": "Windows-specifikus indítási konfigurációs attribútumok.", + "debugOSXConfiguration": "OS X-specifikus indítási konfigurációs attribútumok.", + "debugLinuxConfiguration": "Linux-specifikus indítási konfigurációs attribútumok.", + "deprecatedVariables": "Az 'env.', 'config.' és 'command.' tujdonságok elavultak, használja helyette az 'env:', 'config:' és 'command:' tulajdonságokat." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/emmet/browser/actions/showEmmetCommands.i18n.json b/i18n/hun/src/vs/workbench/parts/emmet/browser/actions/showEmmetCommands.i18n.json new file mode 100644 index 00000000000..0f5eb4400f6 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/emmet/browser/actions/showEmmetCommands.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "showEmmetCommands": "Emmet-parancsok megjelenítése" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/balance.i18n.json b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/balance.i18n.json new file mode 100644 index 00000000000..1534d8b6077 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/balance.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "balanceInward": "Emmet: Egyensúlyozás (belefé)", + "balanceOutward": "Emmet: Egyensúlyozás (kifelé)" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json new file mode 100644 index 00000000000..219aad079bd --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "previousEditPoint": "Emmet: Ugrás az elÅ‘zÅ‘ szerkesztési pontra", + "nextEditPoint": "Emmet: Ugrás a következÅ‘ szerkesztési pontra" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json new file mode 100644 index 00000000000..ab60a0c6b09 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "evaluateMathExpression": "Emmet: Matematikai kifejezés kiértékelése" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.i18n.json b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.i18n.json new file mode 100644 index 00000000000..646e5adcf6f --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "expandAbbreviationAction": "Emmet: Rövidítés kibontása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json new file mode 100644 index 00000000000..d9e318872d8 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "incrementNumberByOneTenth": "Emmet: Növelés 0,1-gyel", + "incrementNumberByOne": "Emmet: Növelés 1-gyel", + "incrementNumberByTen": "Emmet: Növelés 10-zel", + "decrementNumberByOneTenth": "Emmet: Csökkentés 0,1-gyel", + "decrementNumberByOne": "Emmet: Csökkentés 1-gyel", + "decrementNumberByTen": "Emmet: Csökkentés 10-zel" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/matchingPair.i18n.json b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/matchingPair.i18n.json new file mode 100644 index 00000000000..cec247d0e8f --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/matchingPair.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "matchingPair": "Emmet: Ugrás az illeszkedÅ‘ párra" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/mergeLines.i18n.json b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/mergeLines.i18n.json new file mode 100644 index 00000000000..de85d11a136 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/mergeLines.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "mergeLines": "Emmet: Sorok összeolvasztása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/reflectCssValue.i18n.json b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/reflectCssValue.i18n.json new file mode 100644 index 00000000000..f4fa17b2860 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/reflectCssValue.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "reflectCSSValue": "Emmet: CSS-érték tükrözése" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json new file mode 100644 index 00000000000..ee23339dfca --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "removeTag": "Emmet: Elem eltávolítása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/selectItem.i18n.json b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/selectItem.i18n.json new file mode 100644 index 00000000000..0d67ceb7a02 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/selectItem.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "selectPreviousItem": "Emmet: ElÅ‘zÅ‘ elem kiválasztása", + "selectNextItem": "Emmet: KövetkezÅ‘ elem kiválasztása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json new file mode 100644 index 00000000000..93c0cba54af --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "splitJoinTag": "Emmet: Elem szétbontása/összeolvasztása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/toggleComment.i18n.json b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/toggleComment.i18n.json new file mode 100644 index 00000000000..cd5b4fc1fe3 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/toggleComment.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleComment": "Emmet: Megjegyzés be- és kikapcsolása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json new file mode 100644 index 00000000000..82dab2c362c --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "updateImageSize": "Emmet: Képméret frissítése" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json new file mode 100644 index 00000000000..60dea6fbae0 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "updateTag": "Emmet: Elem frissítése", + "enterTag": "Adja meg az elemet", + "tag": "Elem" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json new file mode 100644 index 00000000000..7a062455c62 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "wrapWithAbbreviationAction": "Emmet: Becsomagolás rövidítéssel", + "enterAbbreviation": "Adja meg a rövidítést", + "abbreviation": "Rövidítés" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json new file mode 100644 index 00000000000..a4c1aceb7c6 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "emmetConfigurationTitle": "Emmet", + "triggerExpansionOnTab": "Ha engedélyezve van, akkor az Emmet-rövidítések a Tab billentyű lenyomásával bonthatók ki.", + "emmetPreferences": "Beállítások, melyek módosítják az Emmet műveleteinek és feloldó algoritmusainak viselkedését.", + "emmetSyntaxProfiles": "Konkrét szintaktika profiljának meghatározása vagy saját profil használata adott szabályokkal.", + "emmetExclude": "Azon nyelvek listája, ahol az Emmet-rövidítések ne legyenek kibontva.", + "emmetExtensionsPath": "Az Emmet-profilokat, -kódtöredékeket és -beállításokat tartalmazó mappa", + "useNewEmmet": "Új Emmet-modulok használata az összes Emmet-funkcióhoz (ami elÅ‘bb-utóbb helyettesíteni fogja az egyedülálló Emmet-könyvtárat)." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/execution/electron-browser/terminal.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/execution/electron-browser/terminal.contribution.i18n.json new file mode 100644 index 00000000000..91f0c001e15 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/execution/electron-browser/terminal.contribution.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminalConfigurationTitle": "KülsÅ‘ terminál", + "terminal.external.windowsExec": "Meghatározza, hogy mely terminál fusson Windowson.", + "terminal.external.osxExec": "Meghatározza, hogy mely terminál fusson OS X-en.", + "terminal.external.linuxExec": "Meghatározza, hogy mely terminál fusson Linuxon.", + "globalConsoleActionWin": "Új parancssor megnyitása", + "globalConsoleActionMacLinux": "Új terminál megnyitása", + "scopedConsoleActionWin": "Megnyitás a parancssorban", + "scopedConsoleActionMacLinux": "Megnyitás a terminálban" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/execution/electron-browser/terminalService.i18n.json b/i18n/hun/src/vs/workbench/parts/execution/electron-browser/terminalService.i18n.json new file mode 100644 index 00000000000..d8480642f68 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/execution/electron-browser/terminalService.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "console.title": "VS Code-konzol", + "mac.terminal.script.failed": "A(z) '{0}' parancsfájl a következÅ‘ hibakóddal lépett ki: {1}", + "mac.terminal.type.not.supported": "A(z) '{0}' nem támogatott", + "press.any.key": "A folytatáshoz nyomjon meg egy billentyűt...", + "linux.term.failed": "A(z) '{0}' a következÅ‘ hibakóddal lépett ki: {1}" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json new file mode 100644 index 00000000000..e441ed0dd6d --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.view": "Egyedi nézetet szolgáltat", + "vscode.extension.contributes.view.id": "A vscode.workspace.createTreeView-n keresztül létrehozott nézet azonosítására szolgáló egyedi azonosító", + "vscode.extension.contributes.view.label": "A nézet kirajzolásához használt, emberek által olvasható szöveg", + "vscode.extension.contributes.view.icon": "A nézet ikonjának elérési útja", + "vscode.extension.contributes.views": "Egyedi nézeteket szolgáltat", + "showViewlet": "{0} megjelenítése", + "view": "Nézet" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/explorers/browser/treeExplorerActions.i18n.json b/i18n/hun/src/vs/workbench/parts/explorers/browser/treeExplorerActions.i18n.json new file mode 100644 index 00000000000..982d3cebdfe --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/explorers/browser/treeExplorerActions.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "refresh": "Frissítés" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/explorers/browser/treeExplorerService.i18n.json b/i18n/hun/src/vs/workbench/parts/explorers/browser/treeExplorerService.i18n.json new file mode 100644 index 00000000000..ccb7f253610 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/explorers/browser/treeExplorerService.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "treeExplorer.noMatchingProviderId": "Nincs {0} azonosítójú TreeExplorerNodeProvider regisztrálva" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/explorers/browser/views/treeExplorerView.i18n.json b/i18n/hun/src/vs/workbench/parts/explorers/browser/views/treeExplorerView.i18n.json new file mode 100644 index 00000000000..4c975404538 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/explorers/browser/views/treeExplorerView.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "treeExplorerViewlet.tree": "Fa-alapú kezelÅ‘szakasz" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/extensions/browser/dependenciesViewer.i18n.json b/i18n/hun/src/vs/workbench/parts/extensions/browser/dependenciesViewer.i18n.json new file mode 100644 index 00000000000..0ea38cb93c4 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/extensions/browser/dependenciesViewer.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "error": "Hiba", + "Unknown Dependency": "Ismeretlen függÅ‘ség:" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json b/i18n/hun/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json new file mode 100644 index 00000000000..9e2b6f5d7a4 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json @@ -0,0 +1,43 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "name": "KiegészítÅ‘ neve", + "extension id": "KiegészítÅ‘ azonosítója", + "publisher": "Kiadó neve", + "install count": "Telepítések száma", + "rating": "Értékelés", + "license": "Licenc", + "details": "Részletek", + "contributions": "Szolgáltatások", + "changelog": "Változtatási napló", + "dependencies": "FüggÅ‘ségek", + "noReadme": "Leírás nem található.", + "noChangelog": "Változtatási napló nem található.", + "noContributions": "Nincsenek szolgáltatások", + "noDependencies": "Nincsenek függÅ‘ségek", + "settings": "Beállítások ({0})", + "setting name": "Név", + "description": "Leírás", + "default": "Alapértelmezett érték", + "debuggers": "HibakeresÅ‘k ({0})", + "debugger name": "Név", + "views": "Nézetek ({0})", + "view id": "Azonosító", + "view name": "Név", + "view location": "Hol?", + "themes": "Témák ({0})", + "JSON Validation": "JSON-validációk ({0})", + "commands": "Parancsok ({0})", + "command name": "Név", + "keyboard shortcuts": "Billentyűparancsok", + "menuContexts": "Helyi menük", + "languages": "Nyelvek ({0})", + "language id": "Azonosító", + "language name": "Név", + "file extensions": "Fájlkiterjesztések", + "grammar": "Nyelvtan", + "snippets": "Kódtöredékek" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json b/i18n/hun/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json new file mode 100644 index 00000000000..348b2ebb6af --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json @@ -0,0 +1,62 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "installAction": "Telepítés", + "installing": "Telepítés...", + "uninstallAction": "Eltávolítás", + "Uninstalling": "Eltávolítás...", + "updateAction": "Frissítés", + "updateTo": "Frissítés ({0})", + "enableForWorkspaceAction.label": "Engedélyezés a munkaterületen", + "enableAlwaysAction.label": "Engedélyezés mindig", + "disableForWorkspaceAction.label": "Letiltás a munkaterületen", + "disableAlwaysAction.label": "Letiltás mindig", + "ManageExtensionAction.uninstallingTooltip": "Eltávolítás", + "enableForWorkspaceAction": "Munkaterület", + "enableGloballyAction": "Mindig", + "enableAction": "Engedélyezés", + "disableForWorkspaceAction": "Munkaterület", + "disableGloballyAction": "Mindig", + "disableAction": "Letiltás", + "checkForUpdates": "Frissítések keresése", + "enableAutoUpdate": "KiegészítÅ‘k automatikus frissítésének engedélyezése", + "disableAutoUpdate": "KiegészítÅ‘k automatikus frissítésének letiltása", + "updateAll": "Összes kiegészítÅ‘ frissítése", + "reloadAction": "Újratöltés", + "postUpdateTooltip": "Újratöltés a frissítéshez", + "postUpdateMessage": "Újratölti az ablakot a frissített kiegészítÅ‘ ('{0}') aktiválásához?", + "postEnableTooltip": "Újratöltés az aktiváláshoz", + "postEnableMessage": "Újratölti az ablakot a kiegészítÅ‘ ('{0}') aktiválásához?", + "postDisableTooltip": "Újratöltés a kikapcsoláshoz", + "postDisableMessage": "Újratölti az ablakot a kiegészítÅ‘ ('{0}') kikapcsolásához?", + "postUninstallTooltip": "Újratöltés a kikapcsoláshoz", + "postUninstallMessage": "Újratölti az ablakot az eltávolított kiegészítÅ‘ ('{0}') kikapcsolásához?", + "reload": "Ablak új&&ratöltése", + "toggleExtensionsViewlet": "KiegészítÅ‘k megjelenítése", + "installExtensions": "KiegészítÅ‘k telepítése", + "showInstalledExtensions": "Telepített kiegészítÅ‘k megjelenítése", + "showDisabledExtensions": "Letiltott kiegészítÅ‘k megjelenítése", + "clearExtensionsInput": "KiegészítÅ‘k beviteli mezÅ‘ tartalmának törlése", + "showOutdatedExtensions": "Elavult kiegészítÅ‘k megjelenítése", + "showPopularExtensions": "Népszerű kiegészítÅ‘k megjelenítése", + "showRecommendedExtensions": "Ajánlott kiegészítÅ‘k megjelenítése", + "showWorkspaceRecommendedExtensions": "Munkaterülethez ajánlott kiegészítÅ‘k megjelenítése", + "showRecommendedKeymapExtensions": "Ajánlott billentyűkonfigurációk megjelenítése", + "showRecommendedKeymapExtensionsShort": "Billentyűkonfigurációk", + "showLanguageExtensions": "Nyelvi kiegészítÅ‘k megjelenítése", + "showLanguageExtensionsShort": "Nyelvi kiegészítÅ‘k", + "configureWorkspaceRecommendedExtensions": "Ajánlott kiegészítÅ‘k konfigurálása (munkaterületre vonatkozóan)", + "ConfigureWorkspaceRecommendations.noWorkspace": "Az ajánlatok csak egy munkaterület mappájára vonatkozóan érhetÅ‘k el.", + "OpenExtensionsFile.failed": "Nem sikerült létrehozni az 'extensions.json' fájlt a '.vscode' mappánan ({0}).", + "builtin": "Beépített", + "disableAll": "Összes telepített kiegészítÅ‘ letiltása", + "disableAllWorkspace": "Összes telepített kiegészítÅ‘ letiltása a munkaterületre vonatkozóan", + "enableAll": "Összes telepített kiegészítÅ‘ engedélyezése", + "enableAllWorkspace": "Összes telepített kiegészítÅ‘ engedélyezése a munkaterületre vonatkozóan", + "extensionButtonProminentBackground": "A kiegészítÅ‘khöz tartozó kiemelt műveletgombok (pl. a Telepítés gomb) háttérszíne.", + "extensionButtonProminentForeground": "A kiegészítÅ‘khöz tartozó kiemelt műveletgombok (pl. a Telepítés gomb) elÅ‘térszíne.", + "extensionButtonProminentHoverBackground": "A kiegészítÅ‘khöz tartozó kiemelt műveletgombok (pl. a Telepítés gomb) háttérszíne, ha az egér fölötte van." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/extensions/browser/extensionsQuickOpen.i18n.json b/i18n/hun/src/vs/workbench/parts/extensions/browser/extensionsQuickOpen.i18n.json new file mode 100644 index 00000000000..85d01b9b53e --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/extensions/browser/extensionsQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "manage": "Nyomjon Entert a kiegészítÅ‘k kezeléséhez.", + "searchFor": "Nyomja meg az Enter gombot a(z) '{0}' kiegészítÅ‘ kereséséhez a piactéren.", + "noExtensionsToInstall": "Adja meg a kiegészítÅ‘ nevét" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/extensions/common/extensionsFileTemplate.i18n.json b/i18n/hun/src/vs/workbench/parts/extensions/common/extensionsFileTemplate.i18n.json new file mode 100644 index 00000000000..81a39e83e42 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/extensions/common/extensionsFileTemplate.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "app.extensions.json.title": "KiegészítÅ‘k", + "app.extensions.json.recommendations": "Ajánlott kiegészítÅ‘k listája. A kiegészítÅ‘k azonosítója mindig '${publisher}.${name}' formában van. Példa: 'vscode.csharp'.", + "app.extension.identifier.errorMessage": "Az elvárt formátum: '${publisher}.${name}'. Példa: 'vscode.csharp'." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/extensions/common/extensionsInput.i18n.json b/i18n/hun/src/vs/workbench/parts/extensions/common/extensionsInput.i18n.json new file mode 100644 index 00000000000..ed471bc488c --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/extensions/common/extensionsInput.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "extensionsInputName": "KiegészítÅ‘: {0}" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json b/i18n/hun/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json new file mode 100644 index 00000000000..09c306397f4 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "reallyRecommended2": "Ehhez a fájltípushoz a(z) '{0}' kiegészítÅ‘ ajánlott", + "showRecommendations": "Ajánlatok megjelenítése", + "neverShowAgain": "Ne jelenítse meg újra", + "close": "Bezárás", + "workspaceRecommended": "A munkaterülethez vannak javasolt kiegészítÅ‘k", + "ignoreExtensionRecommendations": "Figyelmen kívül akarja hagyni az összes javasolt kiegészítÅ‘t?", + "ignoreAll": "Igen, az összes figyelmen kívül hagyása", + "no": "Nem", + "cancel": "Mégse" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json new file mode 100644 index 00000000000..61b346af2ed --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "extensionsCommands": "KiegészítÅ‘k kezelése", + "galleryExtensionsCommands": "KiegészítÅ‘k telepítése a galériából", + "extension": "KiegészítÅ‘", + "extensions": "KiegészítÅ‘k", + "view": "Nézet", + "extensionsConfigurationTitle": "KiegészítÅ‘k", + "extensionsAutoUpdate": "KiegészítÅ‘k automatikus frissítése", + "extensionsIgnoreRecommendations": "Ajánlott kiegészítÅ‘k figyelmen kívül hagyása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/extensions/electron-browser/extensionsActions.i18n.json b/i18n/hun/src/vs/workbench/parts/extensions/electron-browser/extensionsActions.i18n.json new file mode 100644 index 00000000000..aa157cfb84a --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/extensions/electron-browser/extensionsActions.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openExtensionsFolder": "KiegészítÅ‘k mappájának megnyitása", + "installVSIX": "Telepítés VSIX-bÅ‘l...", + "InstallVSIXAction.success": "A kiegészítÅ‘ sikeresen fel lett telepítve. Indítsa újra az engedélyezéshez.", + "InstallVSIXAction.reloadNow": "Újratöltés most" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/hun/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json new file mode 100644 index 00000000000..f71021aaf87 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "disableOtherKeymapsConfirmation": "Letiltja a többi billentyűkonfigurációt ({0}) a billentyűparancsok közötti konfliktusok megelÅ‘zése érdekében?", + "yes": "Igen", + "no": "Nem", + "betterMergeDisabled": "A Better Merge kiegészítÅ‘ most már be van építve. A telepített kiegészítÅ‘ le lett tiltva és eltávolítható.", + "uninstall": "Eltávolítás", + "later": "KésÅ‘bb" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.i18n.json b/i18n/hun/src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.i18n.json new file mode 100644 index 00000000000..b897e553bd5 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "searchExtensions": "KiegészítÅ‘k keresése a piactéren", + "extensions": "KiegészítÅ‘k", + "sort by installs": "Rendezés a telepítések száma szerint", + "sort by rating": "Rendezés értékelés szerint", + "sort by name": "Rendezés név szerint", + "no extensions found": "KiegészítÅ‘ nem található.", + "suggestProxyError": "A piactér 'ECONNREFUSED' hibával tért vissza. EllenÅ‘rizze a 'http.proxy' beállítást!", + "outdatedExtensions": "{0} elavult kiegészítÅ‘" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.i18n.json b/i18n/hun/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.i18n.json new file mode 100644 index 00000000000..c4d13294809 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "enableDependeciesConfirmation": "A(z) '{0}' engedélyezésével annak függÅ‘ségei is engedélyezve lesznek. Szeretné folytatni?", + "enable": "Igen", + "doNotEnable": "Nem", + "disableDependeciesConfirmation": "Csak a(z) '{0}' kiegészítÅ‘t szeretné letiltani vagy annak függÅ‘ségeit is?", + "disableOnly": "Csak ezt", + "disableAll": "Az összeset", + "cancel": "Mégse", + "singleDependentError": "Nem sikerült letiltani a(z) '{0}' kiegészítÅ‘t: a(z) '{1}' kiegészítÅ‘ függ tÅ‘le.", + "twoDependentsError": "Nem sikerült letiltani a(z) '{0}' kiegészítÅ‘t: a(z) '{1}' és '{2}' kiegészítÅ‘k függnek tÅ‘le.", + "multipleDependentsError": "Nem sikerült letiltani a(z) '{0}' kiegészítÅ‘t: a(z) '{1}', '{2}' és más kiegészítÅ‘k függnek tÅ‘le." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/feedback/electron-browser/feedback.i18n.json b/i18n/hun/src/vs/workbench/parts/feedback/electron-browser/feedback.i18n.json new file mode 100644 index 00000000000..d2b7c3c88fa --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/feedback/electron-browser/feedback.i18n.json @@ -0,0 +1,25 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "sendFeedback": "Visszajelzés tweetelése", + "label.sendASmile": "Küldje el nekünk egy tweetben a visszajelzését!", + "patchedVersion1": "A telepítés hibás.", + "patchedVersion2": "Az alábbiakat adja meg, ha hibát akar beküldeni.", + "sentiment": "Milyennek találja az alkalmazást?", + "smileCaption": "Elégedett", + "frownCaption": "Elégedetlen vagyok vele", + "other ways to contact us": "Más értesítési módok", + "submit a bug": "Hibajelentés küldése", + "request a missing feature": "Hiányzó funkció kérése", + "tell us why?": "Mondja el, hogy miért", + "commentsHeader": "Visszajelzés", + "tweet": "Tweer", + "character left": "karakter maradt", + "characters left": "karakter maradt", + "feedbackSending": "Küldés", + "feedbackSent": "Köszönjük!", + "feedbackSendingError": "Újrapróbálkozás" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/files/browser/editors/binaryFileEditor.i18n.json b/i18n/hun/src/vs/workbench/parts/files/browser/editors/binaryFileEditor.i18n.json new file mode 100644 index 00000000000..b0c0567e179 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/files/browser/editors/binaryFileEditor.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "binaryFileEditor": "Bináris megjelenítÅ‘" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/files/browser/editors/textFileEditor.i18n.json b/i18n/hun/src/vs/workbench/parts/files/browser/editors/textFileEditor.i18n.json new file mode 100644 index 00000000000..d37f4ed8778 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/files/browser/editors/textFileEditor.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "textFileEditor": "SzövegfájlszerkesztÅ‘", + "createFile": "Fájl létrehozása", + "fileEditorWithInputAriaLabel": "{0}. SzövegfájlszerkesztÅ‘.", + "fileEditorAriaLabel": "SzövegfájlszerkesztÅ‘" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/files/browser/fileActions.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/files/browser/fileActions.contribution.i18n.json new file mode 100644 index 00000000000..a5d582952d0 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/files/browser/fileActions.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "filesCategory": "Fájlok", + "revealInSideBar": "Megjelenítés az oldalsávon", + "acceptLocalChanges": "Helyi változtatások használata és a lemezen lévÅ‘ tartalom felülírása", + "revertLocalChanges": "Helyi változtatások eldobása és visszaállítás a lemezen lévÅ‘ tartalomra" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/files/browser/fileActions.i18n.json b/i18n/hun/src/vs/workbench/parts/files/browser/fileActions.i18n.json new file mode 100644 index 00000000000..a6ef3bb7930 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/files/browser/fileActions.i18n.json @@ -0,0 +1,73 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "retry": "Újra", + "rename": "Ãtnevezés", + "newFile": "Új fájl", + "newFolder": "Új mappa", + "openFolderFirst": "Mappák vagy fájlok létrehozásához elÅ‘ször nyisson meg egy mappát!", + "newUntitledFile": "Új, névtelen fájl", + "createNewFile": "Új fájl", + "createNewFolder": "Új mappa", + "deleteButtonLabelRecycleBin": "Ãthelyezés a lo&&mtárba", + "deleteButtonLabelTrash": "Ãthelyezés a &&kukába", + "deleteButtonLabel": "&&Törlés", + "dirtyMessageFolderOneDelete": "Törölni készül egy olyan mappát, melyben egy nem mentett változtatásokat tartalmazó fájl van. Folytatja?", + "dirtyMessageFolderDelete": "Törölni készül egy olyan mappát, melyben {0} nem mentett változtatásokat tartalmazó fájl van. Folytatja?", + "dirtyMessageFileDelete": "Törölni készül egy olyan fájlt, amely nem mentett változtatásokat tartalmaz. Folytatja?", + "dirtyWarning": "A módosítások elvesznek, ha nem menti Å‘ket.", + "confirmMoveTrashMessageFolder": "Törli a(z) '{0}' nevű mappát és a teljes tartalmát?", + "confirmMoveTrashMessageFile": "Törli a(z) '{0}' nevű fájlt?", + "undoBin": "Helyreállíthatja a lomtárból.", + "undoTrash": "Helyreállíthatja a kukából.", + "confirmDeleteMessageFolder": "Törli a(z) {0} mappát és a teljes tartalmát?", + "confirmDeleteMessageFile": "Véglegesen törli a következÅ‘t: {0}?", + "irreversible": "A művelet nem vonható vissza!", + "permDelete": "Végleges törlés", + "delete": "Törlés", + "importFiles": "Fájlok importálása", + "confirmOverwrite": "A célmappában már van ilyen nevű mappa vagy fájl. Le szeretné cserélni?", + "replaceButtonLabel": "&&Csere", + "copyFile": "Másolás", + "pasteFile": "Beillesztés", + "duplicateFile": "Duplikálás", + "openToSide": "Megnyitás oldalt", + "compareSource": "Kijelölés összehasonlításhoz", + "globalCompareFile": "Aktív fájl összehasonlítása...", + "pickHistory": "Válasszon egy korábban megnyitott fájlt az összehasonlításhoz", + "unableToFileToCompare": "A kiválasztott fájl nem hasonlítható össze a következÅ‘vel: '{0}'.", + "openFileToCompare": "Fájlok összehasonlításához elÅ‘sször nyisson meg egy fájlt.", + "compareWith": "Összehasonlítás a következÅ‘vel: '{0}'", + "compareFiles": "Fájlok összehasonlítása", + "refresh": "Frissítés", + "save": "Mentés", + "saveAs": "Mentés másként...", + "saveAll": "Összes mentése", + "saveAllInGroup": "Összes mentése a csoportban", + "saveFiles": "Módosított fájlok mentése", + "revert": "Fájl visszaállítása", + "focusOpenEditors": "Váltás a megnyitott szerkesztÅ‘ablakok nézetre", + "focusFilesExplorer": "Váltás a fájlkezelÅ‘re", + "showInExplorer": "Aktív fájl megjelenítése az oldalsávon", + "openFileToShow": "Fájl fájlkezelÅ‘ben történÅ‘ megjelenítéséhez elÅ‘ször nyisson meg egy fájlt", + "collapseExplorerFolders": "Mappák összecsukása a fájlkezelÅ‘ben", + "refreshExplorer": "FájlkezelÅ‘ frissítése", + "openFile": "Fájl megnyitása...", + "openFileInNewWindow": "Aktív fájl megnyitása új ablakban", + "openFileToShowInNewWindow": "Fájl új ablakban történÅ‘ megnyitásához elÅ‘ször nyisson meg egy fájlt", + "revealInWindows": "Megjelenítés a fájlkezelÅ‘ben", + "revealInMac": "Megjelenítés a Finderben", + "openContainer": "Tartalmazó mappa megnyitása", + "revealActiveFileInWindows": "Aktív fájl megjelenítése a Windows IntézÅ‘ben", + "revealActiveFileInMac": "Aktív fájl megjelenítése a Finderben", + "openActiveFileContainer": "Aktív fájlt tartalmazó mappa megnyitása", + "copyPath": "Elérési út másolása", + "copyPathOfActive": "Aktív fájl elérési útjának másolása", + "emptyFileNameError": "Meg kell adni egy fájl vagy mappa nevét.", + "fileNameExistsError": "Már létezik **{0}** nevű fájl vagy mappa ezen a helyszínen. Adjon meg egy másik nevet!", + "invalidFileNameError": "A(z) **{0}** név nem érvényes fájl- vagy mappanév. Adjon meg egy másik nevet!", + "filePathTooLongError": "A(z) **{0}** név egy olyan elérési utat eredményez, ami túl hosszú. Adjon meg egy másik nevet!" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/files/browser/fileCommands.i18n.json b/i18n/hun/src/vs/workbench/parts/files/browser/fileCommands.i18n.json new file mode 100644 index 00000000000..dd9057b1fa4 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/files/browser/fileCommands.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openFileToCopy": "Fájlok elérési útjának másolásához elÅ‘sször nyisson meg egy fájlt", + "openFileToReveal": "Fájlok felfedéséhez elÅ‘sször nyisson meg egy fájlt" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/files/browser/files.contribution.i18n.json new file mode 100644 index 00000000000..7a29310b0e0 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -0,0 +1,41 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "showExplorerViewlet": "FájlkezelÅ‘ megjelenítése", + "explore": "FájlkezelÅ‘", + "view": "Nézet", + "textFileEditor": "SzövegfájlszerkesztÅ‘", + "binaryFileEditor": "Bináris fájlszerkesztÅ‘", + "filesConfigurationTitle": "Fájlok", + "exclude": "Globális minták konfigurálása fájlok és mappák kiszűréséhez.", + "files.exclude.boolean": "A globális minta, amire illesztve lesznek a fájlok elérési útjai. A minta engedélyezéséhez vagy letiltásához állítsa igaz vagy hamis értékre.", + "files.exclude.when": "További ellenÅ‘rzés elvégzése egy egyezÅ‘ fájl testvérein. Az egyezÅ‘ fájlnévhez használja a $(basename) változót.", + "associations": "Rendeljen nyelveket a fájlokhoz (pl: \"*.kiterjesztés\": \"html\"). Ezek a hozzárendelések elsÅ‘bbséget élveznek a telepített nyelvek által definiált alapértelmezett beállításokkal szemben.", + "encoding": "A fájlok olvasásakor és írásakor használt alapértelmezett karakterkódolás.", + "autoGuessEncoding": "Ha engedélyezve van, az alkalmazás automatikusan megpróbálja kitalálni a fájlok kódolását megnyitáskor", + "eol": "Az alapértelmezett sorvégjel. LF-hez használjon \\n-t, CRLF-hez pedig \\r\\n-t.", + "trimTrailingWhitespace": "Ha engedélyezve van, a fájl mentésekor levágja a sor végén található szóközöket.", + "insertFinalNewline": "Ha engedélyezve van, mentéskor beszúr egy záró újsort a fájl végére.", + "files.autoSave.off": "A módosított fájlok soha nincsenek automatikusan mentve.", + "files.autoSave.afterDelay": "A módosított fájlok automatikusan mentésre kerülnek a 'files.autoSaveDelay' beállításban meghatározott idÅ‘közönként.", + "files.autoSave.onFocusChange": "A módosított fájlok automatikusan mentésre kerülnek, ha a szerkesztÅ‘ablak elveszíti a fókuszt.", + "files.autoSave.onWindowChange": "A módosított fájlok automatikusan mentésre kerülnek, ha az ablak elveszíti a fókuszt.", + "autoSave": "Meghatározza a módosított fájlok automatikus mentési stratégiáját. Elfogadott értékek: '{0}', '{1}', '{2}' (a szerkesztÅ‘ablak elveszíti a fókuszt), '{3}' (az ablak elveszíti a fókuszt). Ha az értéke '{4}', megadható a késleltetés a 'files.autoSaveDelay' beállításban.", + "autoSaveDelay": "Meghatározza ezredmásodpercben a késleltetést, ami után a módosított fájlok automatikusan mentésre kerülnek. Csak akkor van hatása, ha a 'files.autoSave' beállítás értéke '{0}'.", + "watcherExclude": "Globális minta, ami meghatározza azoknak a fájloknak a listáját, amelyek ki vannak szűrve a figyelésbÅ‘l. A beállítás módosítása újraindítást igényel. Ha úgy észleli, hogy a Code túl sok processzort használ indításnál, ki tudja szűrni a nagy mappákat a kezdeti terhelés csökkentés érdekében.", + "hotExit.off": "Gyors kilépés letiltása.", + "hotExit.onExit": "Gyors kilépésrÅ‘l akkor van szó, ha az utolsó ablakot bezárják Windowson és Linuxon, vagy ha a workbench.action.quit parancs van futtatva (a parancskatalógusból, billentyűkombinációval vagy a menübÅ‘l). Az összes biztonsági mentéssel rendelkezÅ‘ ablak helyre lesz állítva a következÅ‘ indítás során.", + "hotExit.onExitAndWindowClose": "Gyors kilépésrÅ‘l akkor van szó, ha az utolsó ablakot bezárják Windowson és Linuxon, ha a workbench.action.quit parancs van futtatva (a parancskatalógusból, billentyűkombinációval vagy a menübÅ‘l), vagy bármely ablak, amelyben mappa van megnyitva, függetlenül attól, hogy az az utolsó ablak-e. Az összes megnyitott, mappa nélküli ablak helyre lesz állítva a következÅ‘ indítás során. A megnyitott mappát tartalmazó ablakok helyreállításához állítsa a \"window.restoreWindows\" értékét \"all\"-ra.", + "hotExit": "Meghatározza, hogy a nem mentett fájlokra emlékezzen-e az alkalmazás a munkamenetek között, így ki lehet hagyni a mentéssel kapcsolatos felugró ablakokat kilépésnél.", + "defaultLanguage": "Az új fájlokhoz alapértelmezetten hozzárendelt nyelv.", + "editorConfigurationTitle": "SzerkesztÅ‘ablak", + "formatOnSave": "Fájlok formázása mentéskor. Az adott nyelvhez rendelkezésre kell állni formázónak, nem lehet beállítva automatikus mentés, és a szerkesztÅ‘ nem állhat éppen lefelé.", + "explorerConfigurationTitle": "FájlkezelÅ‘", + "openEditorsVisible": "A megnyitott szerkesztÅ‘ablakok panelen megjelenített szerkesztÅ‘ablakok száma. Ãllítsa 0-ra, ha el szeretné rejteni a panelt.", + "dynamicHeight": "Meghatározza, hogy a megnyitott szerkesztÅ‘ablakok szakasz magassága automatikusan illeszkedjen a megnyitott elemek számához vagy sem.", + "autoReveal": "Meghatározza, hogy a fájlkezelÅ‘ben automatikusan fel legyenek fedve és ki legyenek jelölve a fájlok, amikor megnyitják Å‘ket.", + "enableDragAndDrop": "Meghatározza, hogy a fájlkezelÅ‘ben áthelyezhetÅ‘k-e a fájlok és mappák húzással." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/files/browser/saveErrorHandler.i18n.json b/i18n/hun/src/vs/workbench/parts/files/browser/saveErrorHandler.i18n.json new file mode 100644 index 00000000000..bd3c645714a --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/files/browser/saveErrorHandler.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "discard": "Elvetés", + "overwrite": "Felülírás", + "retry": "Újrapróbálkozás", + "readonlySaveError": "Nem sikerült menteni a(z) '{0}' fájlt: a fájl írásvédett. Válassza a 'Felülírás' lehetÅ‘séget a védelem eltávolításához.", + "genericSaveError": "Hiba a(z) '{0}' mentése közben: {1}", + "staleSaveError": "Nem sikerült menteni a(z) '{0}' fájlt: a lemezen lévÅ‘ tartalom újabb. Kattintson az **Összehasonlítás*** gombra a helyi és a lemezen lévÅ‘ változat összehasonlításához.", + "compareChanges": "Összehasonlítás", + "saveConflictDiffLabel": "{0} (a lemezen) ↔ {1} ({2}) – Mentési konfliktus feloldása", + "userGuide": "Használja a szerkesztÅ‘i eszköztáron található műveleteket a helyi változtatások **visszavonására** vagy **írja felül** a lemezen lévÅ‘ tartalmat a változtatásokkal" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json b/i18n/hun/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json new file mode 100644 index 00000000000..e1d7ba53a99 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "explorerSection": "FájlkezelÅ‘ szakasz", + "openFolder": "Mappa megnyitása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/files/browser/views/explorerView.i18n.json b/i18n/hun/src/vs/workbench/parts/files/browser/views/explorerView.i18n.json new file mode 100644 index 00000000000..d5015512419 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/files/browser/views/explorerView.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "explorerSection": "FájlkezelÅ‘ szakasz", + "treeAriaLabel": "FájlkezelÅ‘" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/files/browser/views/explorerViewer.i18n.json b/i18n/hun/src/vs/workbench/parts/files/browser/views/explorerViewer.i18n.json new file mode 100644 index 00000000000..d2f6b36195d --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/files/browser/views/explorerViewer.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "fileInputAriaLabel": "Adja meg a fájl nevét. Nyomjon 'Enter'-t a megerÅ‘sítéshez vagy 'Escape'-et a megszakításhoz.", + "filesExplorerViewerAriaLabel": "{0}, FájlkezelÅ‘", + "confirmOverwriteMessage": "A célmappában már létezik '{0}' nevű elem. Le szeretné cserélni?", + "irreversible": "A művelet nem vonható vissza!", + "replaceButtonLabel": "&&Csere" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json b/i18n/hun/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json new file mode 100644 index 00000000000..4a7e2812057 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openEditors": "Megnyitott szerkesztÅ‘ablakok", + "openEditosrSection": "Megnyitott szerkesztÅ‘ablakok szakasz", + "treeAriaLabel": "Megnyitott szerkesztÅ‘ablakok: az aktív fájlok listája", + "dirtyCounter": "{0} nincs mentve" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/files/browser/views/openEditorsViewer.i18n.json b/i18n/hun/src/vs/workbench/parts/files/browser/views/openEditorsViewer.i18n.json new file mode 100644 index 00000000000..4ee03d3f18f --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/files/browser/views/openEditorsViewer.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorGroupAriaLabel": "{0}, SzerkesztÅ‘csoport", + "openEditorAriaLabel": "{0}, megnyitott szerkesztÅ‘ablak", + "saveAll": "Összes mentése", + "closeAllUnmodified": "Nem módosultak bezárása", + "closeAll": "Összes bezárása", + "close": "Bezárás", + "closeOthers": "Többi bezárása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/files/common/dirtyFilesTracker.i18n.json b/i18n/hun/src/vs/workbench/parts/files/common/dirtyFilesTracker.i18n.json new file mode 100644 index 00000000000..24ed237c8fe --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/files/common/dirtyFilesTracker.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "dirtyFiles": "{0} nem mentett fájl" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json b/i18n/hun/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json new file mode 100644 index 00000000000..30e3c5f45be --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "orphanedFile": "{0} (törölve a lemezrÅ‘l)" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/html/browser/html.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/html/browser/html.contribution.i18n.json new file mode 100644 index 00000000000..cd4faab7817 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/html/browser/html.contribution.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "html.editor.label": "HTML-elÅ‘nézet" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/html/browser/htmlPreviewPart.i18n.json b/i18n/hun/src/vs/workbench/parts/html/browser/htmlPreviewPart.i18n.json new file mode 100644 index 00000000000..e0ec7953f3b --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/html/browser/htmlPreviewPart.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "html.voidInput": "Érvénytelen bemenet a szerkesztÅ‘ablakból." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/html/browser/webview.i18n.json b/i18n/hun/src/vs/workbench/parts/html/browser/webview.i18n.json new file mode 100644 index 00000000000..2f238385c10 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/html/browser/webview.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "devtools.webview": "FejlesztÅ‘i: Webview-eszközök" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/markers/common/messages.i18n.json b/i18n/hun/src/vs/workbench/parts/markers/common/messages.i18n.json new file mode 100644 index 00000000000..f17c3b300c4 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/markers/common/messages.i18n.json @@ -0,0 +1,39 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "viewCategory": "Nézet", + "problems.view.show.label": "Problémák megjelenítése", + "problems.panel.configuration.title": "Problémák-nézet", + "problems.panel.configuration.autoreveal": "Meghatározza, hogy a problémák nézet automatikusan felfedje-e a fájlokat, amikor megnyitja Å‘ket.", + "markers.panel.title.problems": "Problémák", + "markers.panel.aria.label.problems.tree": "Problémák fájlonként csoportosítva", + "markers.panel.no.problems.build": "A munkaterületen eddig egyetlen hiba sem lett érzékelve.", + "markers.panel.no.problems.filters": "A megadott szűrÅ‘feltételnek egyetlen elem sem felel meg.", + "markers.panel.action.filter": "Problémák szűrése", + "markers.panel.filter.placeholder": "Szűrés típus vagy szöveg alapján", + "markers.panel.filter.errors": "hibák", + "markers.panel.filter.warnings": "figyelmeztetések", + "markers.panel.filter.infos": "információk", + "markers.panel.single.error.label": "1 hiba", + "markers.panel.multiple.errors.label": "{0} hiba", + "markers.panel.single.warning.label": "1 figyelmeztetés", + "markers.panel.multiple.warnings.label": "{0} figyelmeztetés", + "markers.panel.single.info.label": "1 információ", + "markers.panel.multiple.infos.label": "{0} információ", + "markers.panel.single.unknown.label": "1 ismeretlen", + "markers.panel.multiple.unknowns.label": "{0} ismeretlen", + "markers.panel.at.ln.col.number": "({0}, {1})", + "problems.tree.aria.label.resource": "{0} {1} problémával", + "problems.tree.aria.label.error.marker": "{0} által generált hiba: {1}, sor: {2}, oszlop: {3}", + "problems.tree.aria.label.error.marker.nosource": "Hiba: {0}, sor: {1}, oszlop: {2}", + "problems.tree.aria.label.warning.marker": "{0} által generált figyelmeztetés: {1}, sor: {2}, oszlop: {3}", + "problems.tree.aria.label.warning.marker.nosource": "Figyelmeztetés: {0}, sor: {1}, oszlop: {2}", + "problems.tree.aria.label.info.marker": "{0} által generált információ: {1}, sor: {2}, oszlop: {3}", + "problems.tree.aria.label.info.marker.nosource": "Információ: {0}, sor: {1}, oszlop: {2}", + "problems.tree.aria.label.marker": "{0} által generált probléma: {1}, sor: {2}, oszlop: {3}", + "problems.tree.aria.label.marker.nosource": "Probléma: {0}, sor: {1}, oszlop: {2}", + "errors.warnings.show.label": "Hibák és figyelmezetések megjelenítése" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/markers/electron-browser/markersElectronContributions.i18n.json b/i18n/hun/src/vs/workbench/parts/markers/electron-browser/markersElectronContributions.i18n.json new file mode 100644 index 00000000000..ef6d4a9d7db --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/markers/electron-browser/markersElectronContributions.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "copyMarker": "Másolás" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/nps/electron-browser/nps.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/nps/electron-browser/nps.contribution.i18n.json new file mode 100644 index 00000000000..bd0a0d19696 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/nps/electron-browser/nps.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "surveyQuestion": "Lenne kedve egy gyors elégedettségi felméréshez?", + "takeSurvey": "Felmérés kitöltése", + "remindLater": "Emlékeztessen késÅ‘bb", + "neverAgain": "Ne jelenjen meg újra" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/output/browser/output.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/output/browser/output.contribution.i18n.json new file mode 100644 index 00000000000..06381af2f68 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/output/browser/output.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "output": "Kimenet", + "viewCategory": "Nézet", + "clearOutput.label": "Kimenet törlése" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/output/browser/outputActions.i18n.json b/i18n/hun/src/vs/workbench/parts/output/browser/outputActions.i18n.json new file mode 100644 index 00000000000..fb409d189e4 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/output/browser/outputActions.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleOutput": "Kimenet be- és kikapcsolása", + "clearOutput": "Kimenet törlése", + "toggleOutputScrollLock": "Kimenet görgetési zárának be- és kikapcsolása", + "switchToOutput.label": "Váltás a kimenetre" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/output/browser/outputPanel.i18n.json b/i18n/hun/src/vs/workbench/parts/output/browser/outputPanel.i18n.json new file mode 100644 index 00000000000..b9102668982 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/output/browser/outputPanel.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "outputPanelWithInputAriaLabel": "{0}, kimenetpanel", + "outputPanelAriaLabel": "Kimenetpanel" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/output/common/output.i18n.json b/i18n/hun/src/vs/workbench/parts/output/common/output.i18n.json new file mode 100644 index 00000000000..6d78e77e5ec --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/output/common/output.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "output": "Kimenet", + "channel": "a következÅ‘höz: '{0}'" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json new file mode 100644 index 00000000000..497bbff0b89 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "slow": "Lassú indulás érzékelve", + "slow.detail": "Sajnáljuk, hogy lassú volt az alkalmazás indulása. Indítsa újra a(z) '{0}' alkalmazást bekapcsolt profilozással, ossza meg a profilt velünk, és keményen fogunk dolgozni azon, hogy az indulás ismét gyors legyen.", + "prof.message": "Profil sikeresen elkészítve.", + "prof.detail": "Készítsen egy hibajelentést, és manuálisan csatolja a következÅ‘ fájlokat:\n{0}", + "prof.restartAndFileIssue": "Hibajelentés létrehozása és újraindítás", + "prof.restart": "Újraindítás", + "prof.thanks": "Köszönjük a segítséget!", + "prof.detail.restart": "Egy utolsó újraindítás szükséges a(z) '{0}' használatához. Ismételten köszönjük a közreműködését!" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/preferences/browser/keybindingWidgets.i18n.json b/i18n/hun/src/vs/workbench/parts/preferences/browser/keybindingWidgets.i18n.json new file mode 100644 index 00000000000..f660711dc6b --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/preferences/browser/keybindingWidgets.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defineKeybinding.initial": "Ãœsse le a kívánt billentyűkombinációt, majd nyomjon ENTER-t. ESCAPE a megszakításhoz.", + "defineKeybinding.chordsTo": "kombináció a következÅ‘höz:" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json b/i18n/hun/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json new file mode 100644 index 00000000000..1e432a80419 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json @@ -0,0 +1,35 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "keybindingsInputName": "Billentyűparancsok", + "SearchKeybindings.AriaLabel": "Billentyűparancsok keresése", + "SearchKeybindings.Placeholder": "Billentyűparancsok keresése", + "sortByPrecedene": "Rendezés precedencia szerint", + "header-message": "Haladó beállításokhoz nyissa meg és szerkessze a következÅ‘t:", + "keybindings-file-name": "keybindings.json", + "keybindingsLabel": "Billentyűparancsok", + "changeLabel": "Billentyűparancs módosítása", + "addLabel": "Billentyűparancs hozzáadása", + "removeLabel": "Billentyűparancs eltávolítása", + "resetLabel": "Billentyűparancs visszaállítása", + "showConflictsLabel": "Konfliktusok megjelenítése", + "copyLabel": "Másolás", + "error": "'{0}' hiba a billentyűparancsok szerkesztése közben. Nyissa meg a 'keybindings.json' fájlt, és ellenÅ‘rizze!", + "command": "Parancs", + "keybinding": "Billentyűparancs", + "source": "Forrás", + "when": "Mikor?", + "editKeybindingLabelWithKey": "{0} billentyűparancs módosítása", + "editKeybindingLabel": "Billentyűparancs módosítása", + "addKeybindingLabelWithKey": "{0} billentyűparancs hozzáadása", + "addKeybindingLabel": "Billentyűparancs hozzáadása", + "commandAriaLabel": "Parancs: {0}.", + "keybindingAriaLabel": "Billentyűparancs: {0}.", + "noKeybinding": "Nincs billentyűparancs hozzárendelve.", + "sourceAriaLabel": "Forrás: {0}.", + "whenAriaLabel": "Mikor: {0}.", + "noWhen": "Nincs 'mikor'-kontextus." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/hun/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json new file mode 100644 index 00000000000..bce5ff41424 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defineKeybinding.start": "Billentyűparancs megadása", + "defineKeybinding.kbLayoutErrorMessage": "A jelenlegi billentyűkiosztással nem használható ez a billentyűkombináció.", + "defineKeybinding.kbLayoutLocalAndUSMessage": "**{0}** a jelenlegi billentyűkiosztással (**{1}** az alapértelmezett amerikaival.", + "defineKeybinding.kbLayoutLocalMessage": "**{0}** a jelenlegi billentyűkiosztással." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/preferences/browser/preferences.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/preferences/browser/preferences.contribution.i18n.json new file mode 100644 index 00000000000..b2ceafc3869 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/preferences/browser/preferences.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defaultPreferencesEditor": "Alapértelmezett beállításszerkesztÅ‘", + "keybindingsEditor": "Billentyűparancs-szerkesztÅ‘", + "preferences": "Beállítások" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json b/i18n/hun/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json new file mode 100644 index 00000000000..6b0c1dfa1da --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openGlobalSettings": "Felhasználói beállítások megnyitása", + "openGlobalKeybindings": "Billentyűparancsok megnyitása", + "openGlobalKeybindingsFile": "Billentyűparancsfájl megnyitása", + "openWorkspaceSettings": "Munkaterület beállításainak megnyitása", + "configureLanguageBasedSettings": "Nyelvspecifikus beállítások konfigurálása...", + "languageDescriptionConfigured": "(({0})", + "pickLanguage": "Nyelv kiválasztása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/preferences/browser/preferencesEditor.i18n.json b/i18n/hun/src/vs/workbench/parts/preferences/browser/preferencesEditor.i18n.json new file mode 100644 index 00000000000..f06c901c354 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/preferences/browser/preferencesEditor.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "settingsEditorName": "Alapértelmezett beállítások", + "SearchSettingsWidget.AriaLabel": "Beállítások keresése", + "SearchSettingsWidget.Placeholder": "Beállítások keresése", + "totalSettingsMessage": "Összesen {0} beállítás", + "noSettingsFound": "Nincs eredmény", + "oneSettingFound": "1 illeszkedÅ‘ beállítás", + "settingsFound": "{0} illeszkedÅ‘ beállítás", + "preferencesAriaLabel": "Az alapértelmezett beállítások. Ãrásvédett szerkesztÅ‘ablak." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json b/i18n/hun/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json new file mode 100644 index 00000000000..961013af481 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "errorInvalidConfiguration": "Nem sikerült írni a beállításokba. Javítsa a fájlban található hibákat/figyelmeztetéseket, majd próbálja újra!", + "editTtile": "Szerkesztés", + "replaceDefaultValue": "Csere a beállításokban", + "copyDefaultValue": "Másolás a beállításokba", + "unsupportedPHPExecutablePathSetting": "Ez a beállítás csak a felhasználói beállításokban szerepelhet. A PHP munkaterülethez történÅ‘ konfigurálásához nyisson meg egy PHP-fájlt, majd kattintson a PHP-elérési útra az állapotsoron!", + "unsupportedWorkspaceSetting": "Ez a beállítás csak a felhasználói beállításokban szerepelhet." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/preferences/browser/preferencesService.i18n.json b/i18n/hun/src/vs/workbench/parts/preferences/browser/preferencesService.i18n.json new file mode 100644 index 00000000000..a7800d606fb --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/preferences/browser/preferencesService.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openFolderFirst": "Munkaterületspecifikus beállítások létrehozásához nyisson meg egy mappát", + "emptyKeybindingsHeader": "Az ebben a fájlban elhelyezett billentyűparancsok felülírják az alapértelmezett beállításokat", + "defaultKeybindings": "Alapértelmezett billentyűparancsok", + "emptySettingsHeader": "Az ebben a fájlban elhelyezett beállítások felülírják az alapértelmezett beállításokat", + "emptySettingsHeader1": "Az ebben a fájlban elhelyezett beállítások felülírják az alapértelmezett és felhasználói beállításokat", + "fail.createSettings": "Nem sikerült a(z) '{0}' létrehozás ({1})." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/preferences/browser/preferencesWidgets.i18n.json b/i18n/hun/src/vs/workbench/parts/preferences/browser/preferencesWidgets.i18n.json new file mode 100644 index 00000000000..b2d1254fb58 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/preferences/browser/preferencesWidgets.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "settingsSwitcherBarAriaLabel": "Beállításkapcsoló", + "userSettings": "Felhasználói beállítások", + "workspaceSettings": "Munkaterület-beállítások" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.i18n.json b/i18n/hun/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.i18n.json new file mode 100644 index 00000000000..8fb1c627192 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "default": "Alapértelmezett", + "user": "Felhasználói", + "meta": "meta", + "option": "beállítás" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/preferences/common/preferencesModels.i18n.json b/i18n/hun/src/vs/workbench/parts/preferences/common/preferencesModels.i18n.json new file mode 100644 index 00000000000..35cc39622d0 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/preferences/common/preferencesModels.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "commonlyUsed": "Gyakran használt", + "defaultKeybindingsHeader": "A billentyűparancsok fájlban elhelyezett billentyűparancsok felülírják az alapértelmezett beállításokat" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json b/i18n/hun/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json new file mode 100644 index 00000000000..41ec82c33f7 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json @@ -0,0 +1,19 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "showTriggerActions": "Minden parancs megjelenítése", + "clearCommandHistory": "ParancselÅ‘zmények törlése", + "showCommands.label": "Parancskatalógus...", + "entryAriaLabelWithKey": "{0}, {1}, parancsok", + "entryAriaLabel": "{0}, parancs", + "canNotRun": "Innen nem futtatható a(z) {0} parancs.", + "actionNotEnabled": "Ebben a kontextusban nem engedélyezett a(z) {0} parancs futtatása.", + "recentlyUsed": "legutóbb használt", + "morecCommands": "további parancsok", + "commandLabel": "{0}: {1}", + "cat.title": "{0}: {1}", + "noCommandsMatching": "Parancs nem található" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/quickopen/browser/gotoLineHandler.i18n.json b/i18n/hun/src/vs/workbench/parts/quickopen/browser/gotoLineHandler.i18n.json new file mode 100644 index 00000000000..fca514543ea --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/quickopen/browser/gotoLineHandler.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "gotoLine": "Sor megkeresése...", + "gotoLineLabelEmptyWithLimit": "A keresett sor 1 és {0} közötti sorszáma", + "gotoLineLabelEmpty": "A keresett sor száma", + "gotoLineColumnLabel": "Ugrás a(z) {0}. sor {1}. oszlopára", + "gotoLineLabel": "Sor megkeresése {0}", + "gotoLineHandlerAriaLabel": "Adja meg a keresett sor számát!", + "cannotRunGotoLine": "Sor megkereséséhez nyisson meg egy fájlt" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/quickopen/browser/gotoSymbolHandler.i18n.json b/i18n/hun/src/vs/workbench/parts/quickopen/browser/gotoSymbolHandler.i18n.json new file mode 100644 index 00000000000..25da1f31b6b --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/quickopen/browser/gotoSymbolHandler.i18n.json @@ -0,0 +1,34 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "gotoSymbol": "Ugrás szimbólumhoz egy fájlban...", + "symbols": "szimbólumok ({0})", + "method": "metódusok ({0})", + "function": "függvények ({0})", + "_constructor": "konstruktorok ({0})", + "variable": "változók ({0})", + "class": "osztályok ({0})", + "interface": "interfészek ({0})", + "namespace": "névterek ({0})", + "package": "csomagok ({0})", + "modules": "modulok ({0})", + "property": "tulajdonságok ({0})", + "enum": "enumerátorok ({0n)", + "string": "karakterláncok ({0})", + "rule": "szabályok ({0})", + "file": "fájlok ({0})", + "array": "tömbök ({0})", + "number": "számok ({0})", + "boolean": "logikai értékek ({0})", + "object": "objektumok ({0})", + "key": "kulcsok ({0})", + "entryAriaLabel": "{0}, szimbólumok", + "noSymbolsMatching": "Nincs illeszkedÅ‘ szimbólum", + "noSymbolsFound": "Szimbólum nem található", + "gotoSymbolHandlerAriaLabel": "Ãrjon az aktív szerkesztÅ‘ablakban található szimbólumok szűréséhez.", + "cannotRunGotoSymbolInFile": "Ehhez a fájlhoz nincs szimbóluminformáció", + "cannotRunGotoSymbol": "Szimbólum megkereséséhez nyisson meg egy szövegfájlt" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/quickopen/browser/helpHandler.i18n.json b/i18n/hun/src/vs/workbench/parts/quickopen/browser/helpHandler.i18n.json new file mode 100644 index 00000000000..3b68e868532 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/quickopen/browser/helpHandler.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, választó súgó", + "globalCommands": "globális parancsok", + "editorCommands": "szerkesztÅ‘ablak parancsai" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.i18n.json new file mode 100644 index 00000000000..7e61210cdf7 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "commandsHandlerDescriptionDefault": "Parancsok megjelenítése és futtatása", + "gotoLineDescriptionMac": "Sor megkeresése", + "gotoLineDescriptionWin": "Sor megkeresése", + "gotoSymbolDescription": "Ugrás szimbólumhoz egy fájlban...", + "gotoSymbolDescriptionScoped": "Szimbólum megkeresése kategória alapján", + "helpDescription": "Súgó megjelenítése", + "viewPickerDescription": "Nézet megnyitása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/quickopen/browser/viewPickerHandler.i18n.json b/i18n/hun/src/vs/workbench/parts/quickopen/browser/viewPickerHandler.i18n.json new file mode 100644 index 00000000000..955a8d6a1ec --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/quickopen/browser/viewPickerHandler.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, nézetválasztó", + "views": "Nézetek", + "panels": "Panelek", + "terminals": "Terminál", + "terminalTitle": "{0}: {1}", + "channels": "Kimenet", + "openView": "Nézet megnyitása", + "quickOpenView": "Gyors megnyitás nézet" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json new file mode 100644 index 00000000000..757fd45ffec --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "relaunchMessage": "Egy olyan beállítás változott, melynek hatályba lépéséhez újraindítás szükséges.", + "relaunchDetail": "A beállítás engedélyezéséhez nyomja meg az újraindítás gombot a {0} újraindításához.", + "restart": "Újraindítás" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/hun/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json new file mode 100644 index 00000000000..088f4ecdf17 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorGutterModifiedBackground": "A szerkesztÅ‘ablak margójának háttérszíne a módosított soroknál.", + "editorGutterAddedBackground": "A szerkesztÅ‘ablak margójának háttérszíne a hozzáadott soroknál.", + "editorGutterDeletedBackground": "A szerkesztÅ‘ablak margójának háttérszíne a törölt soroknál." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json new file mode 100644 index 00000000000..fd2863510af --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleGitViewlet": "Git megjelenítése", + "installAdditionalSCMProviders": "További verziókezelÅ‘ rendszerek telepítése...", + "source control": "VerziókezelÅ‘ rendszer", + "toggleSCMViewlet": "VerziókezelÅ‘ megjelenítése", + "view": "Nézet" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/scm/electron-browser/scmActivity.i18n.json b/i18n/hun/src/vs/workbench/parts/scm/electron-browser/scmActivity.i18n.json new file mode 100644 index 00000000000..89a9d4e2341 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/scm/electron-browser/scmActivity.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "scmPendingChangesBadge": "{0} függÅ‘ben lévÅ‘ módosítás" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json b/i18n/hun/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json new file mode 100644 index 00000000000..a7af703f9fc --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "installAdditionalSCMProviders": "További verziókezelÅ‘ rendszerek telepítése...", + "switch provider": "Váltás más verziókezelÅ‘ rendszerre..." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/scm/electron-browser/scmViewlet.i18n.json b/i18n/hun/src/vs/workbench/parts/scm/electron-browser/scmViewlet.i18n.json new file mode 100644 index 00000000000..529d2491ca2 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/scm/electron-browser/scmViewlet.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "commitMessage": "Ãœzenet (nyomja meg a következÅ‘t a commithoz: {0})", + "source control": "VerziókezelÅ‘ rendszer", + "viewletTitle": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/search/browser/openAnythingHandler.i18n.json b/i18n/hun/src/vs/workbench/parts/search/browser/openAnythingHandler.i18n.json new file mode 100644 index 00000000000..20f5e1c646a --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/search/browser/openAnythingHandler.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "fileAndTypeResults": "fájl- és szimbólumkeresés eredménye", + "fileResults": "fájlkeresés eredménye" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/search/browser/openFileHandler.i18n.json b/i18n/hun/src/vs/workbench/parts/search/browser/openFileHandler.i18n.json new file mode 100644 index 00000000000..39b05feed4f --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/search/browser/openFileHandler.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, fájlválasztó", + "searchResults": "keresési eredmények" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/search/browser/openSymbolHandler.i18n.json b/i18n/hun/src/vs/workbench/parts/search/browser/openSymbolHandler.i18n.json new file mode 100644 index 00000000000..a8dd776594b --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/search/browser/openSymbolHandler.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, szimbólumválasztó", + "symbols": "szimbólumkeresési eredmények", + "noSymbolsMatching": "Nincs illeszkedÅ‘ szimbólum", + "noSymbolsWithoutInput": "Adja meg a keresett szimbólumot" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/search/browser/patternInputWidget.i18n.json b/i18n/hun/src/vs/workbench/parts/search/browser/patternInputWidget.i18n.json new file mode 100644 index 00000000000..0f499bf2957 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/search/browser/patternInputWidget.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defaultLabel": "bemeneti adat", + "patternDescription": "Globális minták használata", + "patternHelpInclude": "Az illesztéshez használt minta. Pl. **\\*\\*/*.js** használható az összes JavaScript-fájl, vagy a **myFolder/\\*\\*** egy adott mappa és a benne található összes fájl illesztéséhez.\n\n**Referencia**:\n**\\*** 0 vagy több karakterre illeszkedik\n**?** 1 karakterre illeszkedik\n**\\*\\*** 0 vagy több könyvtárra illeszkedik\n**[a-z]** karakterek tartományára illeszkedik\n**{a,b}** a megadott minták bármelyikére illeszkedik", + "useIgnoreFilesDescription": "Ignore-fájlok használata", + "useExcludeSettingsDescription": "Kizárási beállítások használata" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/search/browser/replaceService.i18n.json b/i18n/hun/src/vs/workbench/parts/search/browser/replaceService.i18n.json new file mode 100644 index 00000000000..7825dc551c0 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/search/browser/replaceService.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "fileReplaceChanges": "{0} ↔ {1} (csere elÅ‘nézete)" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/search/browser/search.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/search/browser/search.contribution.i18n.json new file mode 100644 index 00000000000..47387e215d8 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/search/browser/search.contribution.i18n.json @@ -0,0 +1,22 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "showTriggerActions": "Szimbólum megkeresése a munkaterületen...", + "name": "Keresés", + "showSearchViewlet": "Keresés megjelenítése", + "view": "Nézet", + "findInFiles": "Keresés a fájlokban", + "openAnythingHandlerDescription": "Fájl megkeresése", + "openSymbolDescriptionNormal": "Szimbólum megkeresése a munkaterületen", + "searchOutputChannelTitle": "Keresés", + "searchConfigurationTitle": "Keresés", + "exclude": "Globális minták konfigurálása fájlok és mappák keresésbÅ‘l való kizárásához. Örökli az összes globális mintát a fliex.exclude beállításból.", + "exclude.boolean": "A globális minta, amire illesztve lesznek a fájlok elérési útjai. A minta engedélyezéséhez vagy letiltásához állítsa igaz vagy hamis értékre.", + "exclude.when": "További ellenÅ‘rzés elvégzése az illeszkedÅ‘ fájlok testvérein. Az illeszkedÅ‘ fájl nevéhez használja a $(basename) változót!", + "useRipgrep": "Meghatározza, hogy a szövegben való kereséshez a ripgrep van-e használva.", + "useIgnoreFilesByDefault": "Meghatározza, hogy a .gitignore és .ignore fájlok használva vannak-e az új munkaterületeken a kereséshez.", + "search.quickOpen.includeSymbols": "Meghatározza, hogy a fájlok gyors megnyitásánál megjelenjenek-e a globális szimbólumkeresÅ‘ találatai." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/search/browser/searchActions.i18n.json b/i18n/hun/src/vs/workbench/parts/search/browser/searchActions.i18n.json new file mode 100644 index 00000000000..11ab7f2e40e --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/search/browser/searchActions.i18n.json @@ -0,0 +1,21 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "nextSearchTerm": "KövetkezÅ‘ keresÅ‘kifejezés megjelenítése", + "previousSearchTerm": "ElÅ‘zÅ‘ keresÅ‘kifejezés megjelenítése", + "focusNextInputBox": "Váltás a következÅ‘ beviteli mezÅ‘re", + "focusPreviousInputBox": "Váltás az elÅ‘zÅ‘ beviteli mezÅ‘re", + "replaceInFiles": "Csere a fájlokban", + "findInFolder": "Keresés mappában", + "RefreshAction.label": "Frissítés", + "ClearSearchResultsAction.label": "Keresési eredmények törlése", + "FocusNextSearchResult.label": "Váltás a következÅ‘ keresési eredményre", + "FocusPreviousSearchResult.label": "Váltás az elÅ‘zÅ‘ keresési eredményre", + "RemoveAction.label": "Eltávolítás", + "file.replaceAll.label": "Összes cseréje", + "match.replace.label": "Csere", + "ConfigureGlobalExclusionsAction.label": "Beállítások megnyitása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json b/i18n/hun/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json new file mode 100644 index 00000000000..d0aadbe17bc --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "searchMatches": "{0} találat", + "searchMatch": "{0} találat", + "fileMatchAriaLabel": "{0} találat a(z) {2} mappa {1} fájljában. Keresési eredmény", + "replacePreviewResultAria": "{0} kifejezés cseréje a következÅ‘re: {1}, a(z) {2}. oszlopban, a következÅ‘ szöveget tartalmazó sorban: {3}", + "searchResultAria": "Találat a(z) {0} kifejezésre a(z) {1}. oszlopban, a következÅ‘ szöveget tartalmazó sorban: {2}" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/search/browser/searchViewlet.i18n.json b/i18n/hun/src/vs/workbench/parts/search/browser/searchViewlet.i18n.json new file mode 100644 index 00000000000..d97ee9906db --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/search/browser/searchViewlet.i18n.json @@ -0,0 +1,50 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "moreSearch": "Keresési részletek be- és kikapcsolása", + "searchScope.includes": "bele foglalt fájlok", + "label.includes": "Keresésbe bele foglalt fájlok", + "searchScope.excludes": "kizárt fájlok", + "label.excludes": "KeresésbÅ‘l kizárt fájlok", + "global.searchScope.folders": "keresésbÅ‘l a beállítások miatt kizárt fájlok", + "label.global.excludes": "Beállított keresésbÅ‘l kizáró minták", + "replaceAll.confirmation.title": "Minden elÅ‘fordulás cseréje", + "replaceAll.confirm.button": "Csere", + "replaceAll.occurrence.file.message": "{0} elÅ‘fordulás cserélve {1} fájlban a következÅ‘re: '{2}'.", + "removeAll.occurrence.file.message": "{0} elÅ‘fordulás cserélve {1} fájlban.", + "replaceAll.occurrence.files.message": "{0} elÅ‘fordulás cserélve {1} fájlban a következÅ‘re: '{2}'.", + "removeAll.occurrence.files.message": "{0} elÅ‘fordulás cserélve {1} fájlban.", + "replaceAll.occurrences.file.message": "{0} elÅ‘fordulás cserélve {1} fájlban a következÅ‘re: '{2}'.", + "removeAll.occurrences.file.message": "{0} elÅ‘fordulás cserélve {1} fájlban.", + "replaceAll.occurrences.files.message": "{0} elÅ‘fordulás cserélve {1} fájlban a következÅ‘re: '{2}'.", + "removeAll.occurrences.files.message": "{0} elÅ‘fordulás cserélve {1} fájlban.", + "removeAll.occurrence.file.confirmation.message": "Cserél {0} elÅ‘fordulás {1} fájlban a következÅ‘re: '{2}'?", + "replaceAll.occurrence.file.confirmation.message": "Cserél {0} elÅ‘fordulást {1} fájlban?", + "removeAll.occurrence.files.confirmation.message": "Cserél {0} elÅ‘fordulás {1} fájlban a következÅ‘re: '{2}'?", + "replaceAll.occurrence.files.confirmation.message": "Cserél {0} elÅ‘fordulást {1} fájlban?", + "removeAll.occurrences.file.confirmation.message": "Cserél {0} elÅ‘fordulás {1} fájlban a következÅ‘re: '{2}'?", + "replaceAll.occurrences.file.confirmation.message": "Cserél {0} elÅ‘fordulást {1} fájlban?", + "removeAll.occurrences.files.confirmation.message": "Cserél {0} elÅ‘fordulás {1} fájlban a következÅ‘re: '{2}'?", + "replaceAll.occurrences.files.confirmation.message": "Cserél {0} elÅ‘fordulást {1} fájlban?", + "treeAriaLabel": "Keresési eredmények", + "globLabel": "{0}, ha {1}", + "searchMaxResultsWarning": "Az eredményhalmaz csak a találatok egy részét tartalmazza. Pontosítsa a keresést a keresési eredmények halmazának szűkítéséhez!", + "searchCanceled": "A keresés meg lett szakítva, mielÅ‘tt eredményt hozott volna –", + "noResultsIncludesExcludes": "Nincs találat a következÅ‘ helyen: '{0}', '{1}' kivételével –", + "noResultsIncludes": "Nincs találat a következÅ‘ helyen: '{0}' –", + "noResultsExcludes": "Nincs találat '{1}' kivételével –", + "noResultsFound": "Nincs találat. EllenÅ‘rizze a kizárási beállításokat –", + "rerunSearch.message": "Keresés megismétlése", + "rerunSearchInAll.message": "Keresés megismétlése az összes fájlban", + "openSettings.message": "Beállítások megnyitása", + "ariaSearchResultsStatus": "A keresés {0} találatot eredményezett {1} fájlban", + "search.file.result": "{0} találat {1} fájlban", + "search.files.result": "{0} találat {1} fájlban", + "search.file.results": "{0} találat {1} fájlban", + "search.files.results": "{0} találat {1} fájlban", + "searchWithoutFolder": "Még nincs mappa megnyitva. Jelenleg csak a nyitott fájlokban történik keresés –", + "openFolder": "Mappa megnyitása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/search/browser/searchWidget.i18n.json b/i18n/hun/src/vs/workbench/parts/search/browser/searchWidget.i18n.json new file mode 100644 index 00000000000..1bc0f722bcd --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/search/browser/searchWidget.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "search.action.replaceAll.disabled.label": "Összes cseréje (küldje el a keresést az engedélyezéshez)", + "search.action.replaceAll.enabled.label": "Összes cseréje", + "search.replace.toggle.button.title": "Cseremd be- és kikapcsolása", + "label.Search": "Keresés: adja meg a keresÅ‘kifejezést, majd nyomjon Entert a kereséshez vagy Escape-et a megszakításhoz", + "search.placeHolder": "Keresés", + "label.Replace": "Csere: adja meg a cerekifejezést, majd nyomjon Entert a kereséshez vagy Escape-et a megszakításhoz", + "search.replace.placeHolder": "Csere", + "regexp.validationFailure": "A kifejezés mindenre illeszkedik" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json b/i18n/hun/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json new file mode 100644 index 00000000000..161e797da75 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.snippets": "Kódrészleteket szolgáltat.", + "vscode.extension.contributes.snippets-language": "Azon nyelv azonosítója, amely számára szolgáltatva van ez a kódrészlet.", + "vscode.extension.contributes.snippets-path": "A kódrészlet-fájl elérési útja. Az elérési út relatív a kiegészítÅ‘ mappájához, és általában a következÅ‘vel kezdÅ‘dik: './snippets/',", + "invalid.language": "Ismeretlen nyelv található a következÅ‘ben: `contributes.{0}.language`. A megadott érték: {1}", + "invalid.path.0": "Hiányzó karakterlánc a `contributes.{0}.path`-ban. A megadott érték: {1}", + "invalid.path.1": "A `contributes.{0}.path` ({1}) nem a kiegészítÅ‘ mappáján belül található ({2}). Emiatt elÅ‘fordulhat, hogy a kiegészítÅ‘ nem lesz hordozható.", + "badVariableUse": "A(z) \"{0}\" kódrészlet nagy valószínűséggel keveri a kódrészletváltozók és a kódrészlet-helyjelölÅ‘k fogalmát. További információ a következÅ‘ oldalon található: https://code.visualstudio.com/docs/editor/userdefinedsnippets#_snippet-syntax" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/snippets/electron-browser/insertSnippet.i18n.json b/i18n/hun/src/vs/workbench/parts/snippets/electron-browser/insertSnippet.i18n.json new file mode 100644 index 00000000000..8a772b44962 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/snippets/electron-browser/insertSnippet.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "snippet.suggestions.label": "Kódrészlet beszúrása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json new file mode 100644 index 00000000000..b0d1519ec90 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openSnippet.label": "Felhasználói kódrészletek megnyitása", + "openSnippet.pickLanguage": "Kódrészlet nyelvének kiválasztása", + "openSnippet.errorOnCreate": "A(z) {0} nem hozható létre", + "preferences": "Beállítások", + "snippetSchema.json.default": "Ãœres kódrészlet", + "snippetSchema.json": "Felhasználói kódrészlet-konfiguráció", + "snippetSchema.json.prefix": "A kódrészlet IntelliSense-ben történÅ‘ kiválasztásánál használt elÅ‘tag", + "snippetSchema.json.body": "A kódrészlet tartalma. Kurzorpozíciók definiálásához használja a '$1' és '${1:defaultText}' jelölÅ‘ket, a '$0' pedig a végsÅ‘ kurzorpozíció. Változónevek a '${varName}' és '${varName:defaultText}' formában definiálhatók, pl.: 'Ez a fájl: $TM_FILENAME'.", + "snippetSchema.json.description": "A kódrészlet leírása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/snippets/electron-browser/snippetsService.i18n.json b/i18n/hun/src/vs/workbench/parts/snippets/electron-browser/snippetsService.i18n.json new file mode 100644 index 00000000000..eff0054bfb5 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/snippets/electron-browser/snippetsService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "detail.userSnippet": "Felhasználói kódrészlet", + "snippetSuggest.longLabel": "{0}, {1}" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/snippets/electron-browser/tabCompletion.i18n.json b/i18n/hun/src/vs/workbench/parts/snippets/electron-browser/tabCompletion.i18n.json new file mode 100644 index 00000000000..0e84caff00b --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/snippets/electron-browser/tabCompletion.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tabCompletion": "Kódrészletek beszúrása, ha az elÅ‘tagjuk illeszkedik. Legjobban akkor működik, ha a 'quickSuggestions' nincs engedélyezve." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json new file mode 100644 index 00000000000..9ed5e0feacc --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "helpUs": "Segítsen javítani a {0}-támogatásunkat", + "takeShortSurvey": "Rövid felmérés kitöltése", + "remindLater": "Emlékeztessen késÅ‘bb", + "neverAgain": "Ne jelenítse meg újra" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json new file mode 100644 index 00000000000..b4f41dcbe89 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "surveyQuestion": "Lenne kedve egy gyors elégedettségi felméréshez?", + "takeSurvey": "Felmérés kitöltése", + "remindLater": "Emlékeztessen késÅ‘bb", + "neverAgain": "Ne jelenítse meg újra" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json b/i18n/hun/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json new file mode 100644 index 00000000000..014090555b3 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksAriaLabel": "Adja meg a buildelési feladat nevét!", + "noTasksMatching": "Nincs ilyen feladat", + "noTasksFound": "Buildelési feladat nem található" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/hun/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json new file mode 100644 index 00000000000..f6eaf1f370f --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, feladatok", + "customizeTask": "Feladat testreszabása" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json b/i18n/hun/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json new file mode 100644 index 00000000000..dad5b6db3e8 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksAriaLabel": "Adja meg az újraindítandó feladat nevét!", + "noTasksMatching": "Nincs ilyen feladat", + "noTasksFound": "Újraindítandó feladat nem található" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json b/i18n/hun/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json new file mode 100644 index 00000000000..4b81a1db774 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksAriaLabel": "Adja meg a futtatandó feladat nevét!", + "noTasksMatching": "Nincs ilyen feladat", + "noTasksFound": "Feladat nem található" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.i18n.json b/i18n/hun/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.i18n.json new file mode 100644 index 00000000000..76eb0f2619d --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksAriaLabel": "Adja meg a megszakítandó feladat nevét!", + "noTasksMatching": "Nincs ilyen feladat", + "noTasksFound": "Megszakítandó feladat nem található" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json b/i18n/hun/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json new file mode 100644 index 00000000000..52db1a193d3 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksAriaLabel": "Adja meg a tesztelési feladat nevét!", + "noTasksMatching": "Nincs ilyen feladat", + "noTasksFound": "Tesztelési feladat nem találhat" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/hun/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json new file mode 100644 index 00000000000..b798f4ca94f --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ConfigurationParser.invalidCWD": "Figyelmeztetés: az options.cwd értékének string típusúnak kell lennie. A következÅ‘ érték figyelmen kívül van hagyva: {0}.", + "ConfigurationParser.noargs": "Hiba: a parancssori argumentumokat string típusú tömbként kell megadni. A megadott érték:\n{0}", + "ConfigurationParser.noShell": "Figyelmeztetés: a shellkonfiguráció csak akkor támogatott, ha a feladat a terminálban van végrehajtva.", + "ConfigurationParser.noName": "Hiba: a deklarációs hatókörben lévÅ‘ problémailleszÅ‘nek kötelezÅ‘ nevet adni:\n{0}\n", + "ConfigurationParser.unknownMatcherKind": "Figyelem: a megadott problémaillesztÅ‘ ismeretlen. A támogatott típusok: string | ProblemMatcher | (string | ProblemMatcher)[].\n{0}\n", + "ConfigurationParser.invalidVaraibleReference": "Hiba: érvénytelen problemMatcher-referencia: {0}\n", + "ConfigurationParser.noTaskName": "Hiba: a feladathoz meg kell adni a taskName tulajdonságot. A feladat figyelmen kívül lesz hagyva.\n{0}\n", + "taskConfiguration.shellArgs": "Figyelmeztetés: a(z) '{0}' feladat egy rendszerparancs, és vagy a parancs nevében vagy az argumentumok egyikében escape nélküli szóköz található. A megfelelÅ‘ idézÅ‘jelezés érdekében olvassza bele az argumentumokat a parancsba.", + "taskConfiguration.noCommandOrDependsOn": "Hiba: a(z) '{0}' feladat nem ad meg parancsot, és nem definiálja a dependsOn tulajdonságot sem. A feladat figyelmen kívül lesz hagyva. A definíciója:\n{1}", + "taskConfiguration.noCommand": "Hiba: a(z) '{0}' feladathoz nincs definiálva a parancs. A feladat figyelmen kívül lesz hagyva. A definíciója:\n{1}" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/tasks/common/taskTemplates.i18n.json b/i18n/hun/src/vs/workbench/parts/tasks/common/taskTemplates.i18n.json new file mode 100644 index 00000000000..eb7c4006c2e --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/tasks/common/taskTemplates.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tsc.config": "Lefordít egy TypeScript-projektet", + "tsc.watch": "Lefordít egy TypeScript-projektet figyelÅ‘ módban", + "dotnetCore": "Végrehajt egy .NET Core buildelési parancsot", + "msbuild": "Végrehajtja a buildelés célpontját", + "externalCommand": "Példa egy tetszÅ‘leges külsÅ‘ parancs futtatására", + "Maven": "Ãltalános maven parancsokat hajt végre" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json b/i18n/hun/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json new file mode 100644 index 00000000000..5372bc32e81 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json @@ -0,0 +1,39 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "JsonSchema.options": "További parancsbeálíltások", + "JsonSchema.options.cwd": "A végrehajtott program vagy parancsfájl munkakönyvtára. Ha nincs megadva, akkor a Code aktuális munkaterületének gyökérkönyvtára van használva.", + "JsonSchema.options.env": "A végrehajtott parancs vagy shell környezete. Ha nincs megadva, akkor a szülÅ‘folyamat környezete van használva.", + "JsonSchema.shellConfiguration": "Meghatározza a használt shellt.", + "JsonSchema.shell.executable": "A használt shell.", + "JsonSchema.shell.args": "Shellargumentumok.", + "JsonSchema.command": "A végrehajtandó parancs. Lehet egy külsÅ‘ parancs vagy egy rendszerparancs.", + "JsonSchema.tasks.args": "A parancs meghívásakor átadott argumentumok.", + "JsonSchema.tasks.taskName": "A feladat neve.", + "JsonSchema.tasks.windows": "Windows-specifikus parancskonfiguráció", + "JsonSchema.tasks.mac": "Mac-specifikus parancskonfiguráció", + "JsonSchema.tasks.linux": "Linux-specifikus parancskonfiguráció", + "JsonSchema.tasks.suppressTaskName": "Meghatározza, hogy a feladat neve hozzá van adva argumentumként a parancshoz. Ha nincs megadva, akkor a globálisan meghatározot érték van használva.", + "JsonSchema.tasks.showOutput": "Meghatározza, hogy a futó feladat kimenete meg van-e jelenítve, vagy sem. Ha nincs megadva, akkor a globálisan meghatározot érték van használva.", + "JsonSchema.echoCommand": "Meghatározza, hogy a végrehajtott parancs ki van-e írva a kimenetre. Alapértelmezett értéke hamis.", + "JsonSchema.tasks.watching.deprecation": "Elavult. Használja helyette az isBackground beállítást.", + "JsonSchema.tasks.watching": "A feladat folyamatosan fut-e és figyeli-e a fájlrendszert.", + "JsonSchema.tasks.background": "A feladat folyamatosan fut-e és a háttérben fut-e.", + "JsonSchema.tasks.promptOnClose": "A felhasználó figyelmeztetve van-e, ha a VS Code egy futó feladat közben záródik be.", + "JsonSchema.tasks.build": "A parancsot a Code alapértelmezett buildelési parancsához rendeli.", + "JsonSchema.tasks.test": "A parancsot a Code alapértelmezett tesztelési parancsához rendeli.", + "JsonSchema.tasks.matchers": "A használt problémaillesztÅ‘k. Lehet karakterlánc, problémaillesztÅ‘, vagy egy tömb, ami karakterláncokat és problémaillesztÅ‘ket tartalmaz.", + "JsonSchema.args": "A parancsnak átadott további argumentumok.", + "JsonSchema.showOutput": "Meghatározza, hogy a futó feladat kimenete megjelenjen-e vagy sem. Ha nincs megadva, az 'always' érték van használva.", + "JsonSchema.watching.deprecation": "Elavult. Használja helyette az isBackground beállítást.", + "JsonSchema.watching": "A feladat folyamatosan fut-e és figyeli-e a fájlrendszert.", + "JsonSchema.background": "A feladat folyamatosan fut-e és a háttérben fut-e.", + "JsonSchema.promptOnClose": "A felhasználó figyelmeztetve van-e, ha a VS Code egy háttérben futó feladat közben záródik be.", + "JsonSchema.suppressTaskName": "Meghatározza, hogy a feladat neve hozzá van adva argumentumként a parancshoz. Alapértelmezett értéke hamis.", + "JsonSchema.taskSelector": "ElÅ‘tag, ami jelzi, hogy az argumentum a feladat.", + "JsonSchema.matchers": "A használt problémaillesztÅ‘k. Lehet karakterlánc, problémaillesztÅ‘, vagy egy tömb, ami karakterláncokat és problémaillesztÅ‘ket tartalmaz.", + "JsonSchema.tasks": "Feladatkonfigurációk. Ãltalában egy külsÅ‘ feladatfuttató rendszerben definiált feladatok kiegészítÅ‘ beállításokkal ellátott változatai." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json b/i18n/hun/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json new file mode 100644 index 00000000000..e288243af01 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "JsonSchema.version": "A konfiguráció verziószáma", + "JsonSchema._runner": "A futtató kikerült a kísérleti állapotból. Használja a hivatalos runner tulajdonságot!", + "JsonSchema.runner": "Meghatározza, hogy a feladat folyamatként van-e végrehajtva, és a kimenet a kimeneti ablakban jelenjen-e meg, vagy a terminálban.", + "JsonSchema.windows": "Windows-specifikus parancskonfiguráció", + "JsonSchema.mac": "Mac-specifikus parancskonfiguráció", + "JsonSchema.linux": "Linux-specifikus parancskonfiguráció", + "JsonSchema.shell": "Meghatározza, hogy a parancs egy rendszerparancs vagy egy külsÅ‘ program. Alapértelmezett értéke hamis, ha nincs megadva." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/hun/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json new file mode 100644 index 00000000000..808f2879fd9 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "JsonSchema.shell": "Meghatározza, hogy a parancs egy rendszerparancs vagy egy külsÅ‘ program. Alapértelmezett értéke hamis, ha nincs megadva.", + "JsonSchema.tasks.dependsOn.string": "Egy másik feladat, amitÅ‘l ez a feladat függ.", + "JsonSchema.tasks.dependsOn.array": "Más feladatok, amiktÅ‘l ez a feladat függ.", + "JsonSchema.tasks.group": "Meghatározza a feladat végrehajtási csoportját. Ha nincs megadva, akkor a feladat nem tartozik egyetlen csoportba sem.", + "JsonSchema.tasks.type": "Meghatározza, hogy a feladat folyamatként van-e végrehajtva vagy egy parancsként a shellben. Alapértelmetten folyamatként vannak végrehajtva.", + "JsonSchema.version": "A konfiguráció verziószáma", + "JsonSchema.tasks.customize": "A szolgáltatott feladat, ami testre van szabva.", + "JsonSchema.windows": "Windows-specifikus parancskonfiguráció", + "JsonSchema.mac": "Mac-specifikus parancskonfiguráció", + "JsonSchema.linux": "Linux-specifikus parancskonfiguráció" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json new file mode 100644 index 00000000000..eb87dfa126f --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json @@ -0,0 +1,51 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksCategory": "Feladatok", + "ConfigureTaskRunnerAction.noWorkspace": "A feladatok csak egy munkaterület mappájára vonatkozóan érhetÅ‘k el.", + "ConfigureTaskRunnerAction.quickPick.template": "Feladatfuttató rendszer választása", + "ConfigureTaskRunnerAction.autoDetecting": "Feladatok automatikus felderítése a következÅ‘höz: {0}", + "ConfigureTaskRunnerAction.autoDetect": "A feladatfuttató rendszer automatikus felderítése nem sikerült. Az alapértelmezett sablon használata. Tekintse meg a feladatkimenetet a részletekért.", + "ConfigureTaskRunnerAction.autoDetectError": "A feladatfuttató rendszer automatikus felderítése hibákat eredményezett. Tekintse meg a feladatkimenetet a részletekért.", + "ConfigureTaskRunnerAction.failed": "Nem sikerült létrehozni a 'tasks.json' fájlt a '.vscode' mappában. Tekintse meg a feladatkimenetet a részletekért.", + "ConfigureTaskRunnerAction.label": "Feladatfuttató rendszer beállítása", + "ConfigureBuildTaskAction.label": "Buildelési feladat beállítása", + "CloseMessageAction.label": "Bezárás", + "ShowTerminalAction.label": "Terminál megtekintése", + "problems": "Problémák", + "manyMarkers": "99+", + "tasks": "Feladatok", + "TaskSystem.noHotSwap": "A feladatvégrehajtó motor megváltoztatása a VS Code újraindítását igényli. A módosítás figyelmen kívül van hagyva.", + "TaskService.noBuildTask": "Nincs buildelési feladat definiálva. Jelöljön meg egy feladatot az 'isBuildCommand' tulajdonsággal a tasks.json fájlban.", + "TaskService.noTestTask": "Nincs tesztelési feladat definiálva. Jelöljön meg egy feladatot az 'isTestCommand' tulajdonsággal a tasks.json fájlban.", + "TaskServer.noTask": "A futtatni kívánt feladat ({0}) nem található.", + "customizeParseErrors": "A jelenlegi feladatkonfigurációban hibák vannak. Feladat egyedivé tétele elÅ‘tt javítsa a hibákat!", + "moreThanOneBuildTask": "Túl sok buildelési feladat van definiálva a tasks.json-ban. Az elsÅ‘ lesz végrehajtva.\n", + "TaskSystem.activeSame.background": "A feladat már aktív és a háttérben fut. A feladat befejezéséhez használja az `F1 > feladat megszakítása` parancsot! ", + "TaskSystem.active": "Már fut egy feladat. Szakítsa meg, mielÅ‘tt egy másik feladatot futtatna.", + "TaskSystem.restartFailed": "Nem sikerült a(z) {0} feladat befejezése és újraindítása.", + "TaskSystem.configurationErrors": "Hiba: a megadott feladatkonfigurációban validációs hibák vannak, és nem használható. ElÅ‘ször javítsa ezeket a hibákat!", + "TaskSystem.invalidTaskJson": "Hiba. A tasks.json fájlban szintaktikai hibák találhatók. Javítsa ezeket a hibákat feladatvégrehajtás elÅ‘tt.\n", + "TaskSystem.runningTask": "Már fut egy feladat. Szeretné megszakítani?", + "TaskSystem.terminateTask": "Felada&&t megszakítása", + "TaskSystem.noProcess": "Az elindított feladat már nem létezik. Ha a feladat egy háttérfolyamatot indított, a VS Code-ból való kilépés árva folyamatokat eredményezhet. Ennek megakadályozása érdekében indítsa el a legutóbbi háttérfolyamatot a wait kapcsolóval!", + "TaskSystem.exitAnyways": "Kilépés mind&&enképp", + "TerminateAction.label": "Futó feladat megszakítása", + "TaskSystem.unknownError": "Hiba történt a feladat futtatása közben. További részletek a feladatnaplóban.", + "TaskService.noWorkspace": "A feladatok csak egy munkaterület mappájára vonatkozóan érhetÅ‘k el.", + "TerminateAction.noProcess": "Az elindított folyamat már nem létezik. Ha a feladat háttérfeladatokat indított, a VS Code-ból való kilépés árva folyamatokat eredményezhet. ", + "TerminateAction.failed": "Nem sikerült megszakítani a futó feladatot", + "ShowLogAction.label": "Feladatnapló megtekintése", + "RunTaskAction.label": "Feladat futtatása", + "RestartTaskAction.label": "Feladat újraindítása", + "BuildAction.label": "Buildelési feladat futtatása", + "TestAction.label": "Tesztelési feladat futtatása", + "quickOpen.task": "Feladat futtatása", + "quickOpen.terminateTask": "Feladat megszakítása", + "quickOpen.restartTask": "Feladat újraindítása", + "quickOpen.buildTask": "Buildelési feladat", + "quickOpen.testTask": "Tesztelési feladat" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json b/i18n/hun/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json new file mode 100644 index 00000000000..cbc547d3e4a --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "TerminalTaskSystem.unknownError": "Ismeretlen hiba történt a feladat végrehajtása közben. Részletek a feladat kimeneti naplójában találhatók.", + "TerminalTaskSystem.terminalName": "Feladat – {0}", + "reuseTerminal": "A terminál újra lesz hasznosítva a feladatok által. Nyomjon meg egy billentyűt a bezáráshoz.", + "TerminalTaskSystem": "Rendszerparancsok nem hajthatók végre UNC-meghajtókon.", + "unkownProblemMatcher": "A(z) {0} problémaillesztÅ‘ nem található. Az illesztÅ‘ figyelmen kívül lesz hagyva." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/tasks/node/processRunnerDetector.i18n.json b/i18n/hun/src/vs/workbench/parts/tasks/node/processRunnerDetector.i18n.json new file mode 100644 index 00000000000..12233f706c8 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/tasks/node/processRunnerDetector.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "TaskSystemDetector.noGulpTasks": "A gulp --tasks-simple futtatása nem listázott egyetlen feladatot sem. Futtatta az npm install parancsot?", + "TaskSystemDetector.noJakeTasks": "A jake --tasks futtatása nem listázott egyetlen feladatot sem. Futtatta az npm install parancsot?", + "TaskSystemDetector.noGulpProgram": "A Gulp nincs telepítve a rendszerre. Futtassa az npm install -g gulp parancsot a telepítéshez!", + "TaskSystemDetector.noJakeProgram": "A Jake nincs telepítve a rendszerre. Futtassa az npm install -g jake parancsot a telepítéshez!", + "TaskSystemDetector.noGruntProgram": "A Grunt nincs telepítve a rendszerre. Futtassa az npm install -g grunt parancsot a telepítéshez!", + "TaskSystemDetector.noProgram": "Az) {0} program nem található. Az üzenet: {1}", + "TaskSystemDetector.buildTaskDetected": "'{0}' nevű build feladat észlelve.", + "TaskSystemDetector.testTaskDetected": "'{0}' nevű tesztelési feladat észlelve." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json b/i18n/hun/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json new file mode 100644 index 00000000000..37fca18236d --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "TaskRunnerSystem.unknownError": "Ismeretlen hiba történt a feladat végrehajtása közben. Részletek a kimeneti naplóban találhatók.", + "TaskRunnerSystem.watchingBuildTaskFinished": "A figyelÅ‘ buildelési feladat befejezÅ‘dött.", + "TaskRunnerSystem.childProcessError": "Nem sikerült elindítani a külsÅ‘ programot: {0} {1}.", + "TaskRunnerSystem.cancelRequested": "Az) '{0}' feladat a felhasználó kérésére lett megszakítva.", + "unkownProblemMatcher": "A(z) {0} problémaillesztÅ‘t nem lehet feloldani. Az illesztÅ‘ figyelmen kívül lesz hagyva." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.i18n.json new file mode 100644 index 00000000000..47de274f4d6 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.i18n.json @@ -0,0 +1,30 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminalIntegratedConfigurationTitle": "Beépített terminál", + "terminal.integrated.shell.linux": "A terminál által használt shell elérési útja Linuxon.", + "terminal.integrated.shellArgs.linux": "Linux-terminál esetén használt parancssori argumentumok.", + "terminal.integrated.shell.osx": "A terminál által használt shell elérési útja OS X-en.", + "terminal.integrated.shellArgs.osx": "OS X-terminál esetén használt parancssori argumentumok.", + "terminal.integrated.shell.windows": "A terminál által használt shell elérési útja Windowson. Ha a Windows beépített shelljét használja (cmd-t, PowerShellt vagy Bash on Ubuntut), a C:\\Windows\\sysnative elérési utat adja meg a C:\\Windows\\System32 helyett a 64-bites verzió használatához.", + "terminal.integrated.shellArgs.windows": "Windows-terminál esetén használt parancssori argumentumok.", + "terminal.integrated.rightClickCopyPaste": "Ha be van állítva, megakadályozza a helyi menü megjelenését a terminálon történÅ‘ jobb kattintás esetén. Helyette másol, ha van kijelölés, és beilleszt, ha nincs.", + "terminal.integrated.fontFamily": "Meghatározza a terminál betűtípusát. Alapértelmezett értéke az editor.fontFamily értéke.", + "terminal.integrated.fontLigatures": "Meghatározza, hogy a terminálban engedélyezve vannak-e a betűtípus-ligatúrák.", + "terminal.integrated.fontSize": "Meghatározza a terminálban használt betű méretét, pixelekben.", + "terminal.integrated.lineHeight": "Meghatározza a sormagasságot a terminálban. A tényleges méret a megadott szám és a terminál betűméretének szorzatából jön ki.", + "terminal.integrated.enableBold": "Engedélyezve van-e a félkövér szöveg a terminálban. A működéshez szükséges, hogy a terminál shellje támogassa a félkövér betűket.", + "terminal.integrated.cursorBlinking": "Meghatározza, hogy a terminál kurzora villog-e.", + "terminal.integrated.cursorStyle": "Meghatározza a terminál kurzorának stílusát.", + "terminal.integrated.scrollback": "Meghatározza, hogy a terminál legfeljebb hány sort tárol a pufferben.", + "terminal.integrated.setLocaleVariables": "Meghatározza, hogy a lokálváltozók be vannak-e állítva a terminál indításánál. Alapértelmezett értéke igaz OS X-en, hamis más platformokon.", + "terminal.integrated.cwd": "Explicit elérési út, ahol a terminál indítva lesz. Ez a shellfolyamat munkakönyvtára (cwd) lesz. Ez a beállítás nagyon hasznos olyan munkaterületeken, ahol a gyökérkönyvtár nem felel meg munkakönyvtárnak.", + "terminal.integrated.confirmOnExit": "Meghatározza, hogy megerÅ‘sítést kér-e az alkalamzás, ha van aktív terminál-munkafolyamat.", + "terminal.integrated.commandsToSkipShell": "Olyan parancsazonosítók listája, melyek nem lesznek elküldve a shellnek, és ehelyett mindig a Code kezeli le Å‘ket. Ez lehetÅ‘vé teszi, hogy az olyan billentyűparancsok, melyeket normál esetben a shell dolgozna fel, ugyanúgy működjenek, mint mikor a terminálon nincs fókusz. Például ilyen a gyorsmegnyitás indításához használt Ctrl+P.", + "terminal": "Terminál", + "terminalCategory": "Terminál", + "viewCategory": "Nézet" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json b/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json new file mode 100644 index 00000000000..aa97cc3e570 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json @@ -0,0 +1,37 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "workbench.action.terminal.toggleTerminal": "Integrált terminál be- és kikapcsolása", + "workbench.action.terminal.kill": "Az aktív terminálpéldány leállítása", + "workbench.action.terminal.kill.short": "Terminál leállítása", + "workbench.action.terminal.copySelection": "Kijelölés másolása", + "workbench.action.terminal.selectAll": "Összes kijelölése", + "workbench.action.terminal.new": "Új integrált terminál létrehozása", + "workbench.action.terminal.new.short": "Új terminál", + "workbench.action.terminal.focus": "Váltás a terminálra", + "workbench.action.terminal.focusNext": "Váltás a következÅ‘ terminálra", + "workbench.action.terminal.focusAtIndex": "Váltás a(z) {0}. terminálra", + "workbench.action.terminal.focusPrevious": "Váltás az elÅ‘zÅ‘ terminálra", + "workbench.action.terminal.paste": "Beillesztés az aktív terminálba", + "workbench.action.terminal.DefaultShell": "Alapértelmezett shell kiválasztása", + "workbench.action.terminal.runSelectedText": "Kijelölt szöveg futtatása az aktív terminálban", + "workbench.action.terminal.runActiveFile": "Aktív fájl futtatása az az aktív terminálban", + "workbench.action.terminal.runActiveFile.noFile": "Csak a lemezen lévÅ‘ fájlok futtathatók a terminálban", + "workbench.action.terminal.switchTerminalInstance": "Terminálpéldány váltása", + "workbench.action.terminal.scrollDown": "Görgetés lefelé (soronként)", + "workbench.action.terminal.scrollDownPage": "Görgetés lefelé (oldalanként)", + "workbench.action.terminal.scrollToBottom": "Görgetés az aljára", + "workbench.action.terminal.scrollUp": "Görgetés felfelé (soronként)", + "workbench.action.terminal.scrollUpPage": "G9rgetés felfelé (oldalanként)", + "workbench.action.terminal.scrollToTop": "Görgetés a tetejére", + "workbench.action.terminal.clear": "Törlés", + "workbench.action.terminal.allowWorkspaceShell": "Munkaterületspecifikus shellkonfiguráció engedélyezése", + "workbench.action.terminal.disallowWorkspaceShell": "Munkaterületspecifikus shellkonfiguráció letiltása", + "workbench.action.terminal.rename": "Ãtnevezés", + "workbench.action.terminal.rename.prompt": "Adja meg a terminál nevét!", + "workbench.action.terminal.focusFindWidget": "Váltás a keresÅ‘modulra", + "workbench.action.terminal.hideFindWidget": "KeresÅ‘modul elrejtése" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json b/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json new file mode 100644 index 00000000000..890ebc35e3d --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminal.background": "A terminál háttérszíne. Ez lehetÅ‘vé teszi a terminál paneltÅ‘l eltérÅ‘ színezését.", + "terminal.foreground": "A terminál elÅ‘térszíne.", + "terminal.ansiColor": "A(z) '{0}' ANSI-szín a terminálban." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.i18n.json b/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.i18n.json new file mode 100644 index 00000000000..d6881142372 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminal.integrated.allowWorkspaceShell": "Engedélyezi a(z) {0} (a munkaterületi beállításokban definiálva) terminálról történÅ‘ indítását?", + "allow": "Engedélyezés", + "disallow": "Tiltás" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json b/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json new file mode 100644 index 00000000000..2d5b3af7ef7 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "label.find": "Keresés", + "placeholder.find": "Keresés", + "label.previousMatchButton": "ElÅ‘zÅ‘ találat", + "label.nextMatchButton": "KövetkezÅ‘ találat", + "label.closeButton": "Bezárás" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json b/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json new file mode 100644 index 00000000000..319655fe00e --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminal.integrated.copySelection.noSelection": "A terminálban nincs semmi kijelölve a másoláshoz", + "terminal.integrated.exitedWithCode": "A terminálfolyamat a következÅ‘ kilépési kóddal állt le: {0}", + "terminal.integrated.waitOnExit": "A folytatáshoz nyomjon meg egy billentyűt...", + "terminal.integrated.launchFailed": "A(z) `{0}{1}` terminálfolyamat-parancsot nem sikerült elindítani (kilépési kód: {2})" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.i18n.json b/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.i18n.json new file mode 100644 index 00000000000..b7e7147089a --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminalLinkHandler.followLinkCmd": "Hivatkozott oldal megnyitása Cmd + kattintás paranccsal", + "terminalLinkHandler.followLinkCtrl": "Hivatkozott oldal megnyitása Ctrl + kattintás paranccsal" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.i18n.json b/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.i18n.json new file mode 100644 index 00000000000..3b0d8ea170a --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "copy": "Másolás", + "createNewTerminal": "Új terminál", + "paste": "Beillesztés", + "clear": "Törlés" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalService.i18n.json b/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalService.i18n.json new file mode 100644 index 00000000000..babb2962c46 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/terminal/electron-browser/terminalService.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminal.integrated.chooseWindowsShellInfo": "Megváltoztathatja az alapértelmezett terminált a testreszabás gomb választásával.", + "customize": "Testreszabás", + "cancel": "Mégse", + "never again": "Rendben, ne jelenítse meg újra", + "terminal.integrated.chooseWindowsShell": "Válassza ki a preferált terminál shellt! Ez késÅ‘bb módosítható a beállításokban.", + "terminalService.terminalCloseConfirmationSingular": "Van egy aktív terminálmunkamenet. Szeretné megszakítani?", + "terminalService.terminalCloseConfirmationPlural": "{0} aktív terminálmunkamenet van. Szeretné megszakítani?", + "yes": "Igen" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json new file mode 100644 index 00000000000..f56e3fb23b9 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json @@ -0,0 +1,19 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "selectTheme.label": "Színtéma", + "installColorThemes": "További színtémák telepítése...", + "themes.selectTheme": "Válassza ki a színtémát (elÅ‘nézet a fel/le billentyűvel)", + "selectIconTheme.label": "Fájlikontéma", + "installIconThemes": "További fájlikontémák telepítése...", + "noIconThemeLabel": "Nincs", + "noIconThemeDesc": "Fájlikonok letiltása", + "problemChangingIconTheme": "Hiba történt az ikontéma beállítása közben: {0}", + "themes.selectIconTheme": "Válasszon fájlikontémát!", + "generateColorTheme.label": "Színtéma generálása az aktuális beállítások alapján", + "preferences": "Beállítások", + "developer": "FejlesztÅ‘i" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/trust/electron-browser/unsupportedWorkspaceSettings.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/trust/electron-browser/unsupportedWorkspaceSettings.contribution.i18n.json new file mode 100644 index 00000000000..977546fa1ca --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/trust/electron-browser/unsupportedWorkspaceSettings.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "unsupportedWorkspaceSettings": "A munkaterület olyan beállításokat tartalmaz, amelyet csak a felhasználói beállításoknál lehet megadni ({0})", + "openWorkspaceSettings": "Munkaterület beállításainak megnyitása", + "openDocumentation": "További információ", + "ignore": "Figyelmen kívül hagyás" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/update/electron-browser/releaseNotesInput.i18n.json b/i18n/hun/src/vs/workbench/parts/update/electron-browser/releaseNotesInput.i18n.json new file mode 100644 index 00000000000..c6ac7bd9d2f --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/update/electron-browser/releaseNotesInput.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "releaseNotesInputName": "Kiadási jegyzék: {0}" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/update/electron-browser/update.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/update/electron-browser/update.contribution.i18n.json new file mode 100644 index 00000000000..42549a7d356 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/update/electron-browser/update.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "release notes": "Kiadási jegyzék", + "updateConfigurationTitle": "Frissítés", + "updateChannel": "Meghatározza, hogy érkeznek-e automatikus frissítések a frissítési csatornáról. A beállítás módosítása után újraindítás szükséges." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/update/electron-browser/update.i18n.json b/i18n/hun/src/vs/workbench/parts/update/electron-browser/update.i18n.json new file mode 100644 index 00000000000..3184270d4e2 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/update/electron-browser/update.i18n.json @@ -0,0 +1,32 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "updateNow": "Frissítés most", + "later": "KésÅ‘bb", + "unassigned": "nincs hozzárendelve", + "releaseNotes": "Kiadási jegyzék", + "showReleaseNotes": "Kiadási jegyzék megjelenítése", + "downloadNow": "Letöltés most", + "read the release notes": "Ãœdvözöljük a {0} v{1} verziójában. Szeretné megtekinteni a kiadási jegyzéket?", + "licenseChanged": "A licencfeltételek változtak. Olvassa végig!", + "license": "Licenc elolvasása", + "updateAvailable": "A {0} frissül az újraindítás után.", + "thereIsUpdateAvailable": "Van elérhetÅ‘ frissítés.", + "noUpdatesAvailable": "Jelenleg nincs elérhetÅ‘ frissítés.", + "updateIsReady": "Új frissítés érhetÅ‘ el.", + "commandPalette": "Parancskatalógus...", + "settings": "Beállítások", + "keyboardShortcuts": "Billentyűparancsok", + "selectTheme.label": "Színtéma", + "themes.selectIconTheme.label": "Fájlikontéma", + "not available": "A frissítések nem érhetÅ‘k el", + "checkingForUpdates": "Frissítések keresése...", + "DownloadUpdate": "ElérhetÅ‘ frissítés letöltése", + "DownloadingUpdate": "Frissítés letöltése...", + "InstallingUpdate": "Frissítés telepítése...", + "restartToUpdate": "Újraindítás a frissítéshez...", + "checkForUpdates": "Frissítések keresése..." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/views/browser/views.i18n.json b/i18n/hun/src/vs/workbench/parts/views/browser/views.i18n.json new file mode 100644 index 00000000000..30ba124e291 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/views/browser/views.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "viewToolbarAriaLabel": "{0} művelet" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json b/i18n/hun/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json new file mode 100644 index 00000000000..377ac0a4b97 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "requirearray": "a nézeteket tömbként kell megadni", + "requirestring": "a(z) `{0}` tulajdonság kötelezÅ‘ és `string` típusúnak kell lennie", + "optstring": "a(z) `{0}` tulajdonság elhagyható vagy `string` típusúnak kell lennie", + "vscode.extension.contributes.view.id": "A nézet azonosítója. Ez használható az adatszolgáltató regisztrálásához a `vscode.window.registerTreeDataProviderForView` API-n keresztül. Ezen túl a kiegészítÅ‘ aktiválásához regisztrálni kell az `onView:${id}` eseményt az `activationEvents`-nél.", + "vscode.extension.contributes.view.name": "A nézet emberek számára olvasható neve. Meg fog jelenni", + "vscode.extension.contributes.view.when": "A nézet megjelenítésének feltétele", + "vscode.extension.contributes.views": "Nézeteket szolgáltat a szerkesztÅ‘höz", + "views.explorer": "FájlkezelÅ‘-nézet", + "locationId.invalid": "A(z) `{0}` nem érvényes nézethelyszín" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json b/i18n/hun/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json new file mode 100644 index 00000000000..08aec5acaf8 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json @@ -0,0 +1,24 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "watermark.showCommands": "Minden parancs megjelenítése", + "watermark.quickOpen": "Fájl megkeresése", + "watermark.openFile": "Fájl megnyitása", + "watermark.openFolder": "Mappa megnyitása", + "watermark.openFileFolder": "Fájl vagy mappa megnyitása", + "watermark.openRecent": "Legutóbbi megnyitása", + "watermark.newUntitledFile": "Új, névtelen fájl", + "watermark.toggleTerminal": "Terminál be- és kikapcsolása", + "watermark.findInFiles": "Keresés a fájlokban", + "watermark.startDebugging": "Hibakeresés indítása", + "watermark.selectTheme": "Téma módosítása", + "watermark.selectKeymap": "Billentyűkonfiguráció módosítása", + "watermark.keybindingsReference": "Billentyűparancs-referencia", + "watermark.openGlobalKeybindings": "Billentyűparancsok", + "watermark.unboundCommand": "nincs hozzárendelve", + "workbenchConfigurationTitle": "Munkaterület", + "tips.enabled": "Ha engedélyezve van, tippek jelennek meg vízjelként, ha nincs egyetlen szerkesztÅ‘ablak sem nyitva." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.i18n.json b/i18n/hun/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.i18n.json new file mode 100644 index 00000000000..9ea3e3e0530 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "welcomeOverlay.explorer": "FájlkezelÅ‘", + "welcomeOverlay.search": "Keresés a fájlok között", + "welcomeOverlay.git": "Forráskódkezelés", + "welcomeOverlay.debug": "Indítás és hibakeresés", + "welcomeOverlay.extensions": "Kiterjesztések kezelése", + "welcomeOverlay.problems": "Hibák és figyelmeztetések megtekintése", + "welcomeOverlay.commandPalette": "Összes parancs megkeresése és futtatása", + "welcomeOverlay": "Felhasználói felület áttekintése", + "hideWelcomeOverlay": "Felület áttekintésének elrejtése", + "help": "Segítség" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/hun/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json new file mode 100644 index 00000000000..ce95c6137fd --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -0,0 +1,43 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "welcomePage.vscode": "Visual Studio Code", + "welcomePage.editingEvolved": "Szerkesztés, továbbfejlesztve", + "welcomePage.start": "Start", + "welcomePage.newFile": "Új fájl", + "welcomePage.openFolder": "Mappa megnyitása...", + "welcomePage.cloneGitRepository": "Git forráskódtár klónozása...", + "welcomePage.recent": "Legutóbbi", + "welcomePage.moreRecent": "Tovább...", + "welcomePage.noRecentFolders": "Nincsenek megnyitott mappák", + "welcomePage.help": "Segítség", + "welcomePage.keybindingsCheatsheet": "Nyomatható billentyűparancs-referencia", + "welcomePage.introductoryVideos": "Bemutatóvideók", + "welcomePage.productDocumentation": "Termékdokumentáció", + "welcomePage.gitHubRepository": "GitHub-forráskódtár", + "welcomePage.stackOverflow": "Stack Overflow", + "welcomePage.showOnStartup": "ÃœdvözlÅ‘lap megjelenítése induláskor", + "welcomePage.customize": "Testreszabás", + "welcomePage.installExtensionPacks": "Eszközk és nyelvek", + "welcomePage.installExtensionPacksDescription": "{0}- és {1}-környezet telepítése", + "welcomePage.moreExtensions": "tovább", + "welcomePage.installKeymapDescription": "Billentyűparancsok telepítése", + "welcomePage.installKeymapExtension": "{0} és {1} billentyűparancsainak telepítése", + "welcomePage.others": "további", + "welcomePage.colorTheme": "Színtéma", + "welcomePage.colorThemeDescription": "Alakítsa át szeretett szerkesztÅ‘jét úgy, ahogyan szeretné!", + "welcomePage.learn": "További információ", + "welcomePage.showCommands": "Összes parancs megkeresése és futtatása", + "welcomePage.interfaceOverview": "Felhasználói felület áttekintése", + "welcomePage.interfaceOverviewDescription": "Fedvény, ami vizuálisan bemutatja a felhasználói felület legfÅ‘bb részeit.", + "welcomePage.interactivePlayground": "Interaktív játszótér", + "welcomePage.interactivePlaygroundDescription": "Próbálja ki a szerkesztÅ‘ funkcióit egy rövid bemutató keretében", + "welcomePage.quickLinks": "Gyorshivatkozások", + "welcomePage.keybindingsReference": "Billentyűparancs-referencia", + "welcomePage.keybindingsReferenceDescription": "Egy nyomtatható PDF a leggyakrabban használt billentyűparancsokkal", + "welcomePage.configureSettings": "Beállítások módosítása", + "welcomePage.configureSettingsDescription": "Szabadítsa fel a VS Code teljes tudását a beállítások személyre szabásával" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json new file mode 100644 index 00000000000..fc0d08e8847 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "help": "Segítség" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/hun/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json new file mode 100644 index 00000000000..558c35d13d2 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -0,0 +1,38 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "workbenchConfigurationTitle": "Munkaterület", + "welcomePage.enabled": "Ha engedélyezve van, indításkor megjelenik az üdvözlÅ‘lap.", + "welcomePage": "Ãœdvözöljük!", + "welcomePage.javaScript": "JavaScript", + "welcomePage.typeScript": "TypeScript", + "welcomePage.python": "Python", + "welcomePage.php": "PHP", + "welcomePage.docker": "Docker", + "welcomePage.vim": "Vim", + "welcomePage.sublime": "Sublime", + "welcomePage.atom": "Atom", + "welcomePage.extensionPackAlreadyInstalled": "A(z) {0}-környezet már telepítve van.", + "welcomePage.willReloadAfterInstallingExtensionPack": "Az ablak újratölt a(z) {0} kiegészítÅ‘ környezet telepítése után.", + "welcomePage.installingExtensionPack": "{0} kiegészítÅ‘ környezet telepítése...", + "welcomePage.extensionPackNotFound": "A(z) {1} azonosítójú {0}-környezet nem található.", + "welcomePage.keymapAlreadyInstalled": "A(z) {0} billentyűparancsok már telepítve vannak.", + "welcomePage.willReloadAfterInstallingKeymap": "Az ablak újratölt a(z) {0} billentyűparancsok telepítése után.", + "welcomePage.installingKeymap": "{0} billentyűparancsok telepítése...", + "welcomePage.keymapNotFound": "A(z) {1} azonosítójú {0} billentyűparancsok nem találhatók.", + "welcome.title": "Ãœdvözöljük!", + "welcomePage.openFolderWithPath": "{1} elérési úton található {0} mappa megnyitása", + "welcomePage.extensionListSeparator": ", ", + "welcomePage.installKeymap": "{0}-billentyűkonfiguráció telepítése", + "welcomePage.installExtensionPack": "{0} kiegészítÅ‘ környezet telepítése", + "welcomePage.installedKeymap": "A(z) {0}-billenyűkiosztás már telepítve van", + "welcomePage.installedExtensionPack": "A(z) {0}-környezet már telepítve van.", + "ok": "OK", + "details": "Részletek", + "cancel": "Mégse", + "welcomePage.buttonBackground": "Az üdvözlÅ‘lapon található gombok háttérszíne", + "welcomePage.buttonHoverBackground": "Az üdvözlÅ‘lapon található gombok háttérszíne, amikor a mutató fölöttük áll." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/welcome/walkThrough/electron-browser/editor/editorWalkThrough.i18n.json b/i18n/hun/src/vs/workbench/parts/welcome/walkThrough/electron-browser/editor/editorWalkThrough.i18n.json new file mode 100644 index 00000000000..0120c6821a0 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/welcome/walkThrough/electron-browser/editor/editorWalkThrough.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorWalkThrough": "Interaktív játszótér", + "editorWalkThrough.title": "Interaktív játszótér" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThrough.contribution.i18n.json b/i18n/hun/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThrough.contribution.i18n.json new file mode 100644 index 00000000000..493706c2601 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThrough.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "walkThrough.editor.label": "Interaktív játszótér", + "help": "Segítség", + "interactivePlayground": "Interaktív játszótér" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughActions.i18n.json b/i18n/hun/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughActions.i18n.json new file mode 100644 index 00000000000..84bb9fd9778 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughActions.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorWalkThrough.arrowUp": "Görgetés felfelé (soronként)", + "editorWalkThrough.arrowDown": "Görgetés lefelé (soronként)", + "editorWalkThrough.pageUp": "Görgetés felfelé (oldalanként)", + "editorWalkThrough.pageDown": "Görgetés lefelé (oldalanként)" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json b/i18n/hun/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json new file mode 100644 index 00000000000..027da129b61 --- /dev/null +++ b/i18n/hun/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "walkThrough.unboundCommand": "nincs hozzárendelve", + "walkThrough.gitNotFound": "Úgy tűnik, hogy a Git nincs telepítve a rendszerre.", + "walkThrough.embeddedEditorBackground": "Az interaktív játszótér szerkesztÅ‘ablakainak háttérszíne." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json b/i18n/hun/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json new file mode 100644 index 00000000000..c75e504c21c --- /dev/null +++ b/i18n/hun/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "open": "Beállítások megnyitása", + "close": "Bezárás", + "saveAndRetry": "Beállítások mentése és újrapróbálkozás", + "errorUnknownKey": "Nem sikerült írni a konfigurációs fájlt (ismeretlen kulcs)", + "errorInvalidTarget": "Nem sikerült írni a konfigurációs fájlt (érvénytelen cél)", + "errorNoWorkspaceOpened": "Nem sikerült írni a beállításokba, mert nincs mappa megnyitva. Nyisson meg egy mappát, majd próbálja újra!", + "errorInvalidConfiguration": "Nem sikerült írni a beállításokba. Nyissa meg a **Felhasználói beállításokat**, javítsa a hibákat és figyelmeztetéseket a fájlban, majd próbálja újra!", + "errorInvalidConfigurationWorkspace": "Nem sikerült írni a beállításokba. Nyissa meg a **Munkaterült beállításait**, javítsa a hibákat és figyelmeztetéseket a fájlban, majd próbálja újra!", + "errorConfigurationFileDirty": "Nem sikerült írni a beállításokba, mert a fájl módosítva lett. Mentse a **Felhasználói beállítások** fájlt, majd próbálja újra!", + "errorConfigurationFileDirtyWorkspace": "Nem sikerült írni a beállításokba, mert a fájl módosítva lett. Mentse a **Munkaterület beállításai** fájlt, majd próbálja újra!" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json b/i18n/hun/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json new file mode 100644 index 00000000000..afdabd01421 --- /dev/null +++ b/i18n/hun/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "telemetryConfigurationTitle": "Telemetria", + "telemetry.enableCrashReporting": "Összeomlási jelentések küldésének engedélyezése a Microsofthoz.\nA beállítás érvénybe lépéséhez újraindítás szükséges." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/services/editor/browser/editorService.i18n.json b/i18n/hun/src/vs/workbench/services/editor/browser/editorService.i18n.json new file mode 100644 index 00000000000..50e968f8ee3 --- /dev/null +++ b/i18n/hun/src/vs/workbench/services/editor/browser/editorService.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "compareLabels": "{0} ↔ {1}" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/services/files/electron-browser/fileService.i18n.json b/i18n/hun/src/vs/workbench/services/files/electron-browser/fileService.i18n.json new file mode 100644 index 00000000000..132ee0675af --- /dev/null +++ b/i18n/hun/src/vs/workbench/services/files/electron-browser/fileService.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "netVersionError": "A működéshez Microsoft .NET-keretrendszer 4.5 szükséges. A telepítéshez kövesse az alábbi hivatkozást!", + "installNet": ".NET Framework 4.5 letöltése", + "neverShowAgain": "Ne jelenítse meg újra", + "trashFailed": "A(z) {0} kukába helyezése nem sikerült" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/services/files/node/fileService.i18n.json b/i18n/hun/src/vs/workbench/services/files/node/fileService.i18n.json new file mode 100644 index 00000000000..3734eda6520 --- /dev/null +++ b/i18n/hun/src/vs/workbench/services/files/node/fileService.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "fileInvalidPath": "Érvénytelen fájlerÅ‘forrás ({0})", + "fileIsDirectoryError": "A fájl egy kövtár ({0})", + "fileBinaryError": "A fájl binárisnak tűnik és nem nyitható meg szövegként", + "fileNotFoundError": "Fájl nem található ({0})", + "unableToMoveCopyError": "Nem lehet áthelyezni vagy másolni. A fájl felülírná a mappát, amiben található.", + "foldersCopyError": "A munkaterületre nem másolhatók mappák. Válasszon ki egyedi fájlokat a másoláshoz.", + "fileReadOnlyError": "A fájl csak olvasható" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/services/keybinding/common/keybindingEditing.i18n.json b/i18n/hun/src/vs/workbench/services/keybinding/common/keybindingEditing.i18n.json new file mode 100644 index 00000000000..36032acbd6e --- /dev/null +++ b/i18n/hun/src/vs/workbench/services/keybinding/common/keybindingEditing.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "errorKeybindingsFileDirty": "Nem lehet írni, mert a fájl módosult. Mentse a **Billentyűparancsok** fájlt, majd próbálja újra.", + "parseErrors": "Nem lehet írni a billentyűparancsokat. Nyissa meg a**Billentyűparancsok fájl**t, javítsa a benne található hibákat vagy figyelmeztetéseket, majd próbálja újra.", + "errorInvalidConfiguration": "Nem lehet írni a billentyűparancsokat. A **Billentyűparancsok fájlban** vagy egy objektum, ami nem tömb típusú. Nyissa meg a fájlt a helyreállításhoz, majd próbálja újra.", + "emptyKeybindingsHeader": "Az ebben a fájlban elhelyezett billentyűparancsok felülírják az alapértelmezett beállításokat" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/services/keybinding/electron-browser/keybindingService.i18n.json b/i18n/hun/src/vs/workbench/services/keybinding/electron-browser/keybindingService.i18n.json new file mode 100644 index 00000000000..9ea2570fa3e --- /dev/null +++ b/i18n/hun/src/vs/workbench/services/keybinding/electron-browser/keybindingService.i18n.json @@ -0,0 +1,26 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "nonempty": "az érték nem lehet üres.", + "requirestring": "a(z) `{0}` tulajdonság kötelezÅ‘ és `string` típusúnak kell lennie", + "optstring": "a(z) `{0}` tulajdonság elhagyható vagy `string` típusúnak kell lennie", + "vscode.extension.contributes.keybindings.command": "A billentyűparancs aktiválása esetén futtatandó parancs azonosítója.", + "vscode.extension.contributes.keybindings.key": "Billenty vagy billentyűparancs (különálló billentyűk plusz jellel és sorozatok szóközzel, pl.: Crtl + O és Ctrl+L L)", + "vscode.extension.contributes.keybindings.mac": "Mac-specifikus billentyű vagy billentyűsorozat.", + "vscode.extension.contributes.keybindings.linux": "Linux-specifikus billentyű vagy billentyűsorozat.", + "vscode.extension.contributes.keybindings.win": "Windows-specifikus billentyű vagy billentyűsorozat.", + "vscode.extension.contributes.keybindings.when": "A billentyűparancs aktiválási feltétele.", + "vscode.extension.contributes.keybindings": "Billentyűparancsok kezelését teszi lehetÅ‘vé.", + "invalid.keybindings": "Érvénytelen `contributes.{0}`: {1}", + "unboundCommands": "A további elérhetÅ‘ parancsok a következÅ‘k: ", + "keybindings.json.title": "Billentyűparancsok konfigurációja", + "keybindings.json.key": "Billentyű vagy billentyűsorozat (szóközzel elválasztva)", + "keybindings.json.command": "A végrehajtandó parancs neve", + "keybindings.json.when": "A billentyűparancs aktiválási feltétele.", + "keybindings.json.args": "A végrehajtandó parancs számára átadott argumentumok", + "keyboardConfigurationTitle": "Billentyűzet", + "dispatch": "Meghatározza, hogy a billentyűleütések észleléséhez a `keydown.code` (ajánlott) vagy `keydown.keyCode` esemény legyen használva." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/services/message/browser/messageList.i18n.json b/i18n/hun/src/vs/workbench/services/message/browser/messageList.i18n.json new file mode 100644 index 00000000000..f97efd6f3ef --- /dev/null +++ b/i18n/hun/src/vs/workbench/services/message/browser/messageList.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "alertErrorMessage": "Hiba: {0}", + "alertWarningMessage": "Figyelmeztetés: {0}", + "alertInfoMessage": "Információ: {0}", + "error": "Hiba", + "warning": "Figyelmeztetés", + "info": "Információ", + "close": "Bezárás" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/services/message/electron-browser/messageService.i18n.json b/i18n/hun/src/vs/workbench/services/message/electron-browser/messageService.i18n.json new file mode 100644 index 00000000000..1da61962be2 --- /dev/null +++ b/i18n/hun/src/vs/workbench/services/message/electron-browser/messageService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "yesButton": "&&Igen", + "cancelButton": "Mégse" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/services/mode/common/workbenchModeService.i18n.json b/i18n/hun/src/vs/workbench/services/mode/common/workbenchModeService.i18n.json new file mode 100644 index 00000000000..62bcd1b704c --- /dev/null +++ b/i18n/hun/src/vs/workbench/services/mode/common/workbenchModeService.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "invalid": "Érvénytelen `contributes.{0}`: a várt érték egy tömb.", + "invalid.empty": "A `contributes.{0}` értéke üres", + "require.id": "a(z) `{0}` tulajdonság kötelezÅ‘ és `string` típusúnak kell lennie", + "opt.extensions": "a(z) `{0}` tulajdonság elhagyható és `string[]` típusúnak kell lennie", + "opt.filenames": "a(z) `{0}` tulajdonság elhagyható és `string[]` típusúnak kell lennie", + "opt.firstLine": "a(z) `{0}` tulajdonság elhagyható és `string` típusúnak kell lennie", + "opt.configuration": "a(z) `{0}` tulajdonság elhagyható és `string` típusúnak kell lennie", + "opt.aliases": "a(z) `{0}` tulajdonság elhagyható és `string[]` típusúnak kell lennie", + "opt.mimetypes": "a(z) `{0}` tulajdonság elhagyható és `string[]` típusúnak kell lennie" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/services/progress/browser/progressService2.i18n.json b/i18n/hun/src/vs/workbench/services/progress/browser/progressService2.i18n.json new file mode 100644 index 00000000000..1618012de89 --- /dev/null +++ b/i18n/hun/src/vs/workbench/services/progress/browser/progressService2.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "progress.text": "{0} – {1}", + "progress.title": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/services/textfile/common/textFileEditorModel.i18n.json b/i18n/hun/src/vs/workbench/services/textfile/common/textFileEditorModel.i18n.json new file mode 100644 index 00000000000..df0fb446988 --- /dev/null +++ b/i18n/hun/src/vs/workbench/services/textfile/common/textFileEditorModel.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "saveFileFirst": "A fájl módosítva lett. Mentse, mielÅ‘tt megnyitná egy másik kódolással.", + "genericSaveError": "Hiba a(z) {0} mentése közben ({1})." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/services/textfile/common/textFileService.i18n.json b/i18n/hun/src/vs/workbench/services/textfile/common/textFileService.i18n.json new file mode 100644 index 00000000000..53a5c4f1246 --- /dev/null +++ b/i18n/hun/src/vs/workbench/services/textfile/common/textFileService.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "files.backup.failSave": "A fájlokról nem sikerült biztonsági másolatot készíteni (Hiba: {0}). Próbálja meg menteni a fájlokat a kilépéshez." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/services/textfile/electron-browser/textFileService.i18n.json b/i18n/hun/src/vs/workbench/services/textfile/electron-browser/textFileService.i18n.json new file mode 100644 index 00000000000..a411a51ba59 --- /dev/null +++ b/i18n/hun/src/vs/workbench/services/textfile/electron-browser/textFileService.i18n.json @@ -0,0 +1,18 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "saveChangesMessage": "Szeretné menteni a(z) {0} fájlban elvégzett módosításokat?", + "saveChangesMessages": "Szeretné menteni a következÅ‘ {0} fájlban elvégzett módosításokat?", + "moreFile": "...1 további fájl nincs megjelenítve", + "moreFiles": "...{0} további fájl nincs megjelenítve", + "saveAll": "Ö&&sszes mentése", + "save": "Menté&&s", + "dontSave": "&&Ne mentse", + "cancel": "Mégse", + "saveChangesDetail": "A módosítások elvesznek, ha nem menti Å‘ket.", + "allFiles": "Összes fájl", + "noExt": "Nincs kiterjesztés" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/services/themes/common/colorThemeSchema.i18n.json b/i18n/hun/src/vs/workbench/services/themes/common/colorThemeSchema.i18n.json new file mode 100644 index 00000000000..0e909264d98 --- /dev/null +++ b/i18n/hun/src/vs/workbench/services/themes/common/colorThemeSchema.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "schema.colors": "A szintaktikai kiemeléshez használt színek", + "schema.properties.name": "A szabály leírása", + "schema.fontStyle": "A szabály betűtípusának stílusa: 'italic', 'bold', 'underline', vagy ezek kombinációja", + "schema.tokenColors.path": "A tmTheme-fájl elérési útja (az aktuális fájlhoz képest relatívan)" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/services/themes/common/fileIconThemeSchema.i18n.json b/i18n/hun/src/vs/workbench/services/themes/common/fileIconThemeSchema.i18n.json new file mode 100644 index 00000000000..b93f26958fa --- /dev/null +++ b/i18n/hun/src/vs/workbench/services/themes/common/fileIconThemeSchema.i18n.json @@ -0,0 +1,37 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "schema.folderExpanded": "Kinyitott mappánál használt ikon. A kinyitott mappa ikonját nem kötelezÅ‘ megadni. Ha nincs megadva, akkor a mappaikon lesz megjelenítve.", + "schema.folder": "A bezárt mappák ikonja, illetve ha a folderExpanded nincs megadva, akkor a kinyitott mappáké is.", + "schema.file": "Az alapértelmezett fájlikon, ami minden olyan fájlnál megjelenik, ami nem illeszkedik egyetlen kiterjesztésre, fájlnévre vagy nyelvazonosítóra sem.", + "schema.folderNames": "Ikonokat társít mappanevekhez. Az objektum kulcsa a mappa neve elérési útvonalrészletek nélkül. Nem tartalmazhat mintákat és helyettesítÅ‘ karaktereket. A mappa nevének vizsgálatánál a kis- és nagybetűk nincsenek megkülönböztetve.", + "schema.folderName": "A társításhoz tartozó ikondefiníció azonosítója.", + "schema.folderNamesExpanded": "Ikonokat társít mappanevekhez kinyitott mappák esetén. Az objektum kulcsa a mappa neve elérési útvonalrészletek nélkül. Nem tartalmazhat mintákat és helyettesítÅ‘ karaktereket. A mappa nevének vizsgálatánál a kis- és nagybetűk nincsenek megkülönböztetve.", + "schema.folderNameExpanded": "A társításhoz tartozó ikondefiníció azonosítója. ", + "schema.fileExtensions": "Ikonokat társít fájlkiterjesztésekhez. Az objektum kulcsa a fájlkiterjesztés neve. A kiterjesztés neve a fájl nevének utolsó része az utolsó pont után (a pont nélkül). A kiterjesztések vizsgálatánál a kis- és nagybetűk nincsenek megkülönböztetve. ", + "schema.fileExtension": "A társításhoz tartozó ikondefiníció azonosítója. ", + "schema.fileNames": "Ikonokat társít fájlnevekhez. Az objektum kulcsa a fájl teljes neve, az elérési út többi része nélkül. A fájlnév tartalmazhat pontokat és fájlkiterjesztést. Nem tartalmazhat mintákat és helyettesítÅ‘ karaktereket. A fájlnevek vizsgálatánál a kis- és nagybetűk nincsenek megkülönböztetve.", + "schema.fileName": "A társításhoz tartozó ikondefiníció azonosítója. ", + "schema.languageIds": "Ikonokat társít nyelvekhez. Az objektum kulcsa a nyelvet szolgáltató komponens által definiált nyelvazonosító.", + "schema.languageId": "A társításhoz tartozó ikondefiníció azonosítója. ", + "schema.fonts": "Az ikondefiníciókban használt betűkészletek.", + "schema.id": "A betűkészlet azonosítója.", + "schema.src": "A betűkészlet elérési útjai.", + "schema.font-path": "A betűkészlet elérési útja, relatívan az aktuális ikontémafájlhoz képest.", + "schema.font-format": "A betűkészlet formátuma.", + "schema.font-weight": "A betűkészlet betűvastagsága.", + "schema.font-sstyle": "A betűkészlet stílusa.", + "schema.font-size": "A betűkészlet alapértelmezett mérete.", + "schema.iconDefinitions": "A fájlok ikonokhoz történÅ‘ rendelésénél használható ikonok leírása.", + "schema.iconDefinition": "Egy ikondefiníció. Az objektum kulcsa a definíció azonosítója.", + "schema.iconPath": "SVG vagy PNG használata esetén a kép elérési útja. Az elérési út relatív az ikonkészletfájlhoz képest.", + "schema.fontCharacter": "Betűkészlet használata esetén a betűkészletbÅ‘l használandó karakter.", + "schema.fontColor": "Betűkészlet használata esetén a használt szín.", + "schema.fontSize": "Betűkészlet használata esetén a betűkészlet mérete a szöveg betűkészletének méretéhez képest, százalékban. Ha nincs megadva, akkor a betűkészlet-definícióban megadott érték van használva.", + "schema.fontId": "Betűkészlet használata esetén a betűkészlet azonosítója. Ha nincs megadva, akkor az elsÅ‘ betűkészlet-definíció van használva.", + "schema.light": "Fájlikon-társítások világos témák használata esetén. Nem kötelezÅ‘ megadni.", + "schema.highContrast": "Fájlikon-társítások nagy kontrasztú témák használata esetén. Nem kötelezÅ‘ megadni." +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/services/themes/electron-browser/colorThemeData.i18n.json b/i18n/hun/src/vs/workbench/services/themes/electron-browser/colorThemeData.i18n.json new file mode 100644 index 00000000000..88c2c741155 --- /dev/null +++ b/i18n/hun/src/vs/workbench/services/themes/electron-browser/colorThemeData.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "error.cannotparsejson": "Hiba a JSON témafájl feldolgozása közben: {0}", + "error.invalidformat.colors": "Hiba a színtémafájl feldolgozása közben: {0}. A 'colors' értéke nem 'object' típusú.", + "error.invalidformat.tokenColors": "Hiba a színtémafájl feldolgozása közben: {0}. A 'tokenColors' tulajdonság vagy egy színeket tartalmazó tömb legyen vagy egy TextMate témafájl elérési útja", + "error.plist.invalidformat": "Hiba a tmTheme-fájl feldolgozása közben: {0}. A 'settings' nem egy tömb.", + "error.cannotparse": "Hiba a tmTheme-fájl feldolgozása közben: {0}", + "error.cannotload": "Hiba a(z) {0} tmTheme fájl betöltése közben: {1}" +} \ No newline at end of file diff --git a/i18n/hun/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json b/i18n/hun/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json new file mode 100644 index 00000000000..52a7fb66fc2 --- /dev/null +++ b/i18n/hun/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json @@ -0,0 +1,32 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.themes": "TextMate-színtémákat szolgáltat.", + "vscode.extension.contributes.themes.id": "A téma felhasználói beállításokban használt azonosítója.", + "vscode.extension.contributes.themes.label": "A színtéma felhasználói felületen megjelenÅ‘ neve.", + "vscode.extension.contributes.themes.uiTheme": "A szerkesztÅ‘ablak körül megjelenÅ‘ elemek alaptémája. A 'vs' a világos, a 'vs-dark' a sötét színtéma, a 'hc-black' pedig a sötét, nagy kontrasztú téma.", + "vscode.extension.contributes.themes.path": "A tmTheme-fájl elérési útja. Az elérési út relatív a kiegészítÅ‘ mappájához képest, és általában './themes/themeFile.tmTheme'.", + "vscode.extension.contributes.iconThemes": "Fájlikontémákat szolgáltat.", + "vscode.extension.contributes.iconThemes.id": "Az ikontéma felhasználói beállításokban használt azonosítója.", + "vscode.extension.contributes.iconThemes.label": "Az ikontéma felhasználói felületen megjelenÅ‘ neve.", + "vscode.extension.contributes.iconThemes.path": "A témadefiníciós fájl elérési útja. Az elérési út relatív a kiegészítÅ‘ mappájához képest, és általában ./icons/awesome-icon-theme.json'.", + "migration.completed": "Új témabeállítások lettek hozzáadva a felhasználói beállításokhoz. Biztonsági mentés a következÅ‘ helyen érhetÅ‘ el: {0}.", + "error.cannotloadtheme": "Nem sikerült betölteni a(z) '{0}' témát: {1}.", + "reqarray": "a(z) `{0}` kiegszítési pontot tömbként kell megadni", + "reqpath": "Hiányzó karakterlánc a `contributes.{0}.path`-ban. A megadott érték: {1}", + "invalid.path.1": "A `contributes.{0}.path` ({1}) nem a kiegészítÅ‘ mappáján belül található ({2}). Emiatt elÅ‘fordulhat, hogy a kiegészítÅ‘ nem lesz hordozható.", + "reqid": "Hiányzó karakterlánc a `contributes.{0}.id`-ben. A megadott érték: {1}", + "error.cannotloadicontheme": "Nem sikerült megnyitni a(z) '{0}' témát", + "error.cannotparseicontheme": "Hiba a fájlikonokat leíró fájl feldolgozása közben: {0}", + "colorTheme": "Meghatározza a munkaterületen használt színtémát.", + "colorThemeError": "A téma ismeretlen vagy nincs telepítve.", + "iconTheme": "Meghatározza a munkaterületen használt ikontémát.", + "noIconThemeDesc": "Nincsenek fájlikonok", + "iconThemeError": "A fájlikontéma ismeretlen vagy nincs telepítve.", + "workbenchColors": "Felülírja az aktuális színtémában definiált színeket.", + "workbenchColors.deprecated": "A beállítás már nem kísérleti, és át lett nevezve 'workbench.colorCustomizations'-re.", + "workbenchColors.deprecatedDescription": "Használja a 'workbench.colorCustomizations' tulajdonságot helyette." +} \ No newline at end of file diff --git a/i18n/ita/extensions/git/out/statusbar.i18n.json b/i18n/ita/extensions/git/out/statusbar.i18n.json index 06cabeb7330..fe9c1294a41 100644 --- a/i18n/ita/extensions/git/out/statusbar.i18n.json +++ b/i18n/ita/extensions/git/out/statusbar.i18n.json @@ -7,5 +7,5 @@ "checkout": "Estrai...", "sync changes": "Sincronizza modifiche", "publish changes": "Pubblica modifiche", - "syncing changes": "Sincronizzazione delle modifiche..." + "syncing changes": "Sincronizzazione delle modifiche in corso..." } \ No newline at end of file diff --git a/i18n/ita/extensions/git/package.i18n.json b/i18n/ita/extensions/git/package.i18n.json index 9e1b703cc3d..118066c0c40 100644 --- a/i18n/ita/extensions/git/package.i18n.json +++ b/i18n/ita/extensions/git/package.i18n.json @@ -32,7 +32,7 @@ "command.push": "Esegui push", "command.pushTo": "Esegui push in...", "command.sync": "Sincronizza", - "command.publish": "Pubblica", + "command.publish": "Pubblica ramo", "command.showOutput": "Mostra output GIT", "config.enabled": "Indica se GIT è abilitato", "config.path": "Percorso dell'eseguibile di GIT", diff --git a/i18n/ita/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/ita/extensions/merge-conflict/out/codelensProvider.i18n.json index 8b6ad71cd4e..b8b557539d9 100644 --- a/i18n/ita/extensions/merge-conflict/out/codelensProvider.i18n.json +++ b/i18n/ita/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -3,4 +3,9 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "acceptCurrentChange": "Accetta modifica corrente", + "acceptIncomingChange": "Accetta modifica in ingresso", + "acceptBothChanges": "Accetta entrambe le modifiche", + "compareChanges": "Confronta le modifiche" +} \ No newline at end of file diff --git a/i18n/ita/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/ita/extensions/merge-conflict/out/commandHandler.i18n.json index 7d9e71fea31..bd26a995d32 100644 --- a/i18n/ita/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/ita/extensions/merge-conflict/out/commandHandler.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "cursorNotInConflict": "Il cursore dell'editor non si trova all'interno di un conflitto merge", + "compareChangesTitle": "{0}: modifiche correnti ⟷ modifiche in ingresso", "cursorOnSplitterRange": "Il cursore si trova sulla barra di divisione di merge conflitti, si prega di spostarlo o al blocco \"corrente\" o a quello \"in ricezione\"", "noConflicts": "Conflitti merge non trovati in questo file", "noOtherConflictsInThisFile": "Nessun altro conflitto merge trovato in questo file" diff --git a/i18n/ita/extensions/merge-conflict/package.i18n.json b/i18n/ita/extensions/merge-conflict/package.i18n.json index 7d13f05f2b3..323397967e1 100644 --- a/i18n/ita/extensions/merge-conflict/package.i18n.json +++ b/i18n/ita/extensions/merge-conflict/package.i18n.json @@ -5,7 +5,15 @@ // Do not edit this file. It is machine generated. { "command.category": "Esegui merge del conflitto", + "command.accept.all-incoming": "Accettare tutte le modifiche in ingresso", + "command.accept.all-both": "Accettare tutte in entrambe", + "command.accept.current": "Accettare corrente", + "command.accept.incoming": "Accettare modifiche in ingresso", + "command.accept.selection": "Accettare selezione", "command.accept.both": "Accettare entrambe", + "command.next": "Conflitto successivo", + "command.previous": "Conflitto precedente", + "command.compare": "Confronta il conflitto corrente", "config.title": "Esegui merge del conflitto", "config.codeLensEnabled": "Abilita/Disabilita le finestre CodeLens del blocco merge di conflitti all'interno di editor", "config.decoratorsEnabled": "Abilita/Disabilita gli elementi Decorator sul blocco merge di conflitti all'interno di editor" diff --git a/i18n/ita/extensions/typescript/out/features/bufferSyncSupport.i18n.json b/i18n/ita/extensions/typescript/out/features/bufferSyncSupport.i18n.json index 08776b11893..e6788ac396b 100644 --- a/i18n/ita/extensions/typescript/out/features/bufferSyncSupport.i18n.json +++ b/i18n/ita/extensions/typescript/out/features/bufferSyncSupport.i18n.json @@ -4,7 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "versionMismatch": "Le versioni non corrispondono. Compilatore tsc globale ({0}) != servizio di linguaggio di Visual Studio Code ({1}). Potrebbero verificarsi errori di compilazione incoerente", "moreInformation": "Altre informazioni", "doNotCheckAgain": "Non eseguire più la verifica", "close": "Chiudi", diff --git a/i18n/ita/extensions/typescript/out/utils/projectStatus.i18n.json b/i18n/ita/extensions/typescript/out/utils/projectStatus.i18n.json index 641adbe5215..2a71104630a 100644 --- a/i18n/ita/extensions/typescript/out/utils/projectStatus.i18n.json +++ b/i18n/ita/extensions/typescript/out/utils/projectStatus.i18n.json @@ -6,7 +6,6 @@ { "hintExclude": "Per abilitare le funzionalità del linguaggio JavaScript/TypeScript a livello di progetto, escludere le cartelle che contengono molti file, come {0}", "hintExclude.generic": "Per abilitare le funzionalità del linguaggio JavaScript/TypeScript a livello di progetto, escludere le cartelle di grandi dimensioni che contengono file di origine su cui non si lavora.", - "open": "Configura esclusioni", "large.label": "Configura esclusioni", "hintExclude.tooltip": "Per abilitare le funzionalità del linguaggio JavaScript/TypeScript a livello di progetto, escludere le cartelle di grandi dimensioni che contengono file di origine su cui non si lavora." } \ No newline at end of file diff --git a/i18n/ita/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/ita/extensions/typescript/out/utils/typingsStatus.i18n.json index 4cc0b902ae3..563d939145d 100644 --- a/i18n/ita/extensions/typescript/out/utils/typingsStatus.i18n.json +++ b/i18n/ita/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "installingPackages": "Recupero dei dati per ottimizzare IntelliSense in TypeScript", + "typesInstallerInitializationFailed.title": "Non è stato possibile installare i file di definizione tipi per le funzionalità del linguaggio JavaScript. Verificare che NPM sia installato e o configurare 'typescript.npm' nelle impostazioni utente", "typesInstallerInitializationFailed.moreInformation": "Altre informazioni", "typesInstallerInitializationFailed.doNotCheckAgain": "Non eseguire più la verifica", "typesInstallerInitializationFailed.close": "Chiudi" diff --git a/i18n/ita/extensions/typescript/package.i18n.json b/i18n/ita/extensions/typescript/package.i18n.json index 2b6f87e951f..7db05f3f135 100644 --- a/i18n/ita/extensions/typescript/package.i18n.json +++ b/i18n/ita/extensions/typescript/package.i18n.json @@ -13,7 +13,6 @@ "typescript.check.tscVersion": "Verifica se un compilatore TypeScript di installazione globale, ad esempio tsc, è diverso dal servizio di linguaggio TypeScript usato.", "typescript.tsserver.log": "Abilita la registrazione del server TypeScript in un file. Questo registro può essere utilizzato per diagnosticare problemi del server TypeScript. Il registro può contenere percorsi di file, codice sorgente e altre informazioni del progetto potenzialmente riservate. ", "typescript.tsserver.trace": "Abilita la traccia dei messaggi inviati al server TypeScript. Questa traccia può essere utilizzata per diagnosticare problemi del server TypeScript. La traccia può contenere percorsi di file, codice sorgente e altre informazioni del progetto potenzialmente riservate.", - "typescript.tsserver.experimentalAutoBuild": "Abilita la compilazione automatica sperimentale. Richiede la versione 1.9 dev o 2.x tsserver e il riavvio di Visual Studio Code dopo la modifica.", "typescript.validate.enable": "Abilita/Disabilita la convalida TypeScript.", "typescript.format.enable": "Abilita/Disabilita il formattatore TypeScript predefinito.", "javascript.format.enable": "Abilita/Disabilita il formattatore JavaScript predefinito.", @@ -41,6 +40,8 @@ "typescript.selectTypeScriptVersion.title": "Seleziona la versione di TypeScript", "jsDocCompletion.enabled": "Abilita/Disabilita commenti automatici JSDoc", "javascript.implicitProjectConfig.checkJs": "Abilita/disabilita il controllo semantico di file JavaScript. File jsconfig.json o tsconfig.json esistenti sovrascrivono su questa impostazione. Richiede TypeScript >= 2.3.1.", + "typescript.npm": "Specifica il percorso dell'eseguibile NPM utilizzato per l'acquisizione automatica delle definizioni di tipi. Richiede TypeScript >= 2.3.4.", + "typescript.check.npmIsInstalled": "Controlla se NPM è installato per l'acquisizione automatica delle definizioni di tipi", "javascript.nameSuggestions": "Abilita/disabilita l'inclusione di nomi univoci dal file negli elenchi di suggerimento di JavaScript.", "typescript.tsc.autoDetect": "Controlla se la rilevazione automatica di attività tsc è on/off." } \ No newline at end of file diff --git a/i18n/ita/src/vs/base/common/errorMessage.i18n.json b/i18n/ita/src/vs/base/common/errorMessage.i18n.json index 82051082729..12c07aad24d 100644 --- a/i18n/ita/src/vs/base/common/errorMessage.i18n.json +++ b/i18n/ita/src/vs/base/common/errorMessage.i18n.json @@ -13,6 +13,5 @@ "error.connection.unknown": "Si è verificato un errore di connessione sconosciuto. La connessione a Internet è stata interrotta oppure il server al quale si è connessi è offline.", "stackTrace.format": "{0}: {1}", "error.defaultMessage": "Si è verificato un errore sconosciuto. Per altri dettagli, vedere il log.", - "nodeExceptionMessage": "Si è verificato un errore di sistema ({0})", "error.moreErrors": "{0} ({1} errori in totale)" } \ No newline at end of file diff --git a/i18n/ita/src/vs/base/common/keybindingLabels.i18n.json b/i18n/ita/src/vs/base/common/keybindingLabels.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ita/src/vs/base/common/keybindingLabels.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ita/src/vs/code/electron-main/menus.i18n.json b/i18n/ita/src/vs/code/electron-main/menus.i18n.json index 8956dea0708..d83b44802e5 100644 --- a/i18n/ita/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/ita/src/vs/code/electron-main/menus.i18n.json @@ -14,6 +14,7 @@ "mHelp": "&&Guida", "miNewWindow": "&&Nuova finestra", "mAbout": "Informazioni su {0}", + "mServices": "Servizi", "mHide": "Nascondi {0}", "mHideOthers": "Nascondi altri", "mShowAll": "Mostra tutto", @@ -54,6 +55,9 @@ "miShowEmmetCommands": "E&&mmet...", "miToggleLineComment": "Attiva/Disattiva commento per &&riga", "miToggleBlockComment": "Attiva/Disattiva commento per &&blocco", + "miMultiCursorAlt": "Utilizzare Alt+clic per multi-cursore", + "miMultiCursorCmd": "Utilizzare Cmd+Click per multi-cursore", + "miMultiCursorCtrl": "Utilizzare Ctrl+clic per multi-cursore", "miInsertCursorAbove": "&&Aggiungi cursore sopra", "miInsertCursorBelow": "A&&ggiungi cursore sotto", "miInsertCursorAtEndOfEachLineSelected": "Aggiungi c&&ursori a fine riga", @@ -69,6 +73,7 @@ "miSmartSelectShrink": "&&Riduci selezione", "miViewExplorer": "&&Esplora risorse", "miViewSearch": "Cerca", + "miViewSCM": "S&&CM", "miViewDebug": "&&Debug", "miViewExtensions": "E&&stensioni", "miToggleOutput": "&&Output", @@ -113,6 +118,8 @@ "miGotoSymbolInFile": "Vai al &&simbolo nel file...", "miGotoSymbolInWorkspace": "Vai al &&simbolo nell'area di lavoro...", "miGotoDefinition": "Vai alla &&definizione", + "miGotoTypeDefinition": "Vai alla &&definizione di tipo", + "miGotoImplementation": "Vai all'&&implementazione", "miGotoLine": "Vai alla riga...", "miStartDebugging": "&&Avvia debug", "miStartWithoutDebugging": "Avvia &&senza debug", @@ -129,16 +136,17 @@ "miColumnBreakpoint": "Punto di interruzione &&colonna", "miFunctionBreakpoint": "Punto di interruzione &&funzione...", "miNewBreakpoint": "&&Nuovo punto di interruzione", + "miEnableAllBreakpoints": "Abilita tutti i punti di interruzione", "miDisableAllBreakpoints": "Disabilita tutti i &&punti di interruzione", "miRemoveAllBreakpoints": "Rimuovi &&tutti i punti di interruzione", "miInstallAdditionalDebuggers": "&&Installa debugger aggiuntivi...", "mMinimize": "Riduci a icona", - "mClose": "Chiudi", "mBringToFront": "Porta tutto in primo piano", "miToggleDevTools": "&&Attiva/Disattiva strumenti di sviluppo", "miAccessibilityOptions": "&&Opzioni accessibilità", "miReportIssues": "&&Segnala problemi", "miWelcome": "&&Benvenuti", + "miInteractivePlayground": "Playground &&interattivo", "miDocumentation": "&&Documentazione", "miReleaseNotes": "&&Note sulla versione", "miKeyboardShortcuts": "&&Riferimento per tasti di scelta rapida", @@ -148,12 +156,14 @@ "miLicense": "&&Visualizza licenza", "miPrivacyStatement": "&&Informativa sulla privacy", "miAbout": "&&Informazioni su", + "miTerminateTask": "&&Termina attività", "accessibilityOptionsWindowTitle": "Opzioni accessibilità", "miRestartToUpdate": "Riavvia per aggiornare...", "miCheckingForUpdates": "Verifica della disponibilità di aggiornamenti...", "miDownloadUpdate": "Scarica l'aggiornamento disponibile", "miDownloadingUpdate": "Download dell'aggiornamento...", "miInstallingUpdate": "Installazione dell'aggiornamento...", + "miCheckForUpdates": "Verifica disponibilità aggiornamenti...", "aboutDetail": "\nVersione {0}\nCommit {1}\nData {2}\nShell {3}\nRenderer {4}\nNode {5}", "okButton": "OK" } \ No newline at end of file diff --git a/i18n/ita/src/vs/code/electron-main/windows.i18n.json b/i18n/ita/src/vs/code/electron-main/windows.i18n.json index 6add23a4257..6481aed5875 100644 --- a/i18n/ita/src/vs/code/electron-main/windows.i18n.json +++ b/i18n/ita/src/vs/code/electron-main/windows.i18n.json @@ -13,9 +13,5 @@ "appStalled": "La finestra non risponde", "appStalledDetail": "È possibile riaprire la finestra, chiuderla oppure attendere.", "appCrashed": "Si è verificato un arresto anomalo della finestra", - "appCrashedDetail": "Ci scusiamo per l'inconveniente. Per riprendere dal punto in cui si è verificata l'interruzione, riaprire la finestra.", - "newWindow": "Nuova finestra", - "newWindowDesc": "Apre una nuova finestra", - "recentFolders": "Cartelle recenti", - "folderDesc": "{0} {1}" + "appCrashedDetail": "Ci scusiamo per l'inconveniente. Per riprendere dal punto in cui si è verificata l'interruzione, riaprire la finestra." } \ No newline at end of file diff --git a/i18n/ita/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/ita/src/vs/editor/common/config/commonEditorConfig.i18n.json index b44e9539fe0..c1b3f513186 100644 --- a/i18n/ita/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/ita/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -33,12 +33,14 @@ "wordWrapColumn": "Controlla la colonna di wrapping dell'editor quando il valore di `editor.wordWrap` è 'wordWrapColumn' o 'bounded'.", "wrappingIndent": "Controlla il rientro delle righe con ritorno a capo. Può essere uno dei valori seguenti: 'none', 'same' o 'indent'.", "mouseWheelScrollSensitivity": "Moltiplicatore da usare sui valori `deltaX` e `deltaY` degli eventi di scorrimento della rotellina del mouse", + "multiCursorModifier.ctrlCmd": "Rappresenta il tasto 'Control' (ctrl) su Windows e Linux e il tasto 'Comando' (cmd) su OSX.", + "multiCursorModifier.alt": "Rappresenta il tasto 'Alt' su Windows e Linux e il tasto 'Opzione' su OSX.", + "multiCursorModifier": "Il modificatore da utilizzare per aggiungere molteplici cursori con il mouse. 'ctrlCmd' rappresenta il tasto 'Control' su Windows e Linux e il tasto 'Comando' su OSX. I gesti del mouse Vai a definizione e Apri il Link si adatteranno in modo da non entrare in conflitto con il modificatore multi-cursore.", "quickSuggestions.strings": "Abilita i suggerimenti rapidi all'interno di stringhe.", "quickSuggestions.comments": "Abilita i suggerimenti rapidi all'interno di commenti.", "quickSuggestions.other": "Abilita i suggerimenti rapidi all'esterno di stringhe e commenti.", "quickSuggestions": "Controlla se visualizzare automaticamente i suggerimenti durante la digitazione", "quickSuggestionsDelay": "Controlla il ritardo in ms dopo il quale verranno visualizzati i suggerimenti rapidi", - "parameterHints": "Abilita i suggerimenti per i parametri", "autoClosingBrackets": "Controlla se l'editor deve chiudere automaticamente le parentesi quadre dopo che sono state aperte", "formatOnType": "Controlla se l'editor deve formattare automaticamente la riga dopo la digitazione", "formatOnPaste": "Controlla se l'editor deve formattare automaticamente il contenuto incollato. Deve essere disponibile un formattatore che deve essere in grado di formattare un intervallo in un documento.", @@ -72,6 +74,10 @@ "trimAutoWhitespace": "Rimuovi lo spazio vuoto finale inserito automaticamente", "stablePeek": "Mantiene aperti gli editor rapidi anche quando si fa doppio clic sul contenuto o si preme ESC.", "dragAndDrop": "Controlla se l'editor consentire lo spostamento di selezioni tramite trascinamento della selezione.", + "accessibilitySupport.auto": "L'editor utilizzerà API della piattaforma per rilevare quando è collegata un'utilità per la lettura dello schermo.", + "accessibilitySupport.on": "L'editor sarà definitivamente ottimizzato per l'utilizzo con un'utilità per la lettura dello schermo.", + "accessibilitySupport.off": "L'editor non sarà mai ottimizzato per l'utilizzo con un'utilità per la lettura dello schermo.", + "accessibilitySupport": "Controlla se l'editor deve essere eseguito in una modalità ottimizzata per le utilità per la lettura dello schermo.", "sideBySide": "Controlla se l'editor diff mostra le differenze affiancate o incorporate", "ignoreTrimWhitespace": "Controlla se l'editor diff mostra come differenze le modifiche relative a spazi vuoti iniziali e finali", "renderIndicators": "Consente di controllare se l'editor diff mostra gli indicatori +/- per le modifiche aggiunte/rimosse", diff --git a/i18n/ita/src/vs/editor/common/config/editorOptions.i18n.json b/i18n/ita/src/vs/editor/common/config/editorOptions.i18n.json index 9c443a0f33d..77d08c0ba72 100644 --- a/i18n/ita/src/vs/editor/common/config/editorOptions.i18n.json +++ b/i18n/ita/src/vs/editor/common/config/editorOptions.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "accessibilityOffAriaLabel": "L'editor non è accessibile in questo momento. Premere Alt+F1 per le opzioni.", "editorViewAccessibleLabel": "Contenuto editor" } \ No newline at end of file diff --git a/i18n/ita/src/vs/editor/contrib/find/common/findController.i18n.json b/i18n/ita/src/vs/editor/contrib/find/common/findController.i18n.json index 7161f553e2f..f95c682bc98 100644 --- a/i18n/ita/src/vs/editor/contrib/find/common/findController.i18n.json +++ b/i18n/ita/src/vs/editor/contrib/find/common/findController.i18n.json @@ -14,6 +14,5 @@ "addSelectionToPreviousFindMatch": "Aggiungi selezione a risultato ricerca precedente", "moveSelectionToNextFindMatch": "Sposta ultima selezione a risultato ricerca successivo", "moveSelectionToPreviousFindMatch": "Sposta ultima selezione a risultato ricerca precedente", - "selectAllOccurencesOfFindMatch": "Seleziona tutte le occorrenze del risultato ricerca", "changeAll.label": "Cambia tutte le occorrenze" } \ No newline at end of file diff --git a/i18n/ita/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json b/i18n/ita/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json index 63fbdbdb30f..2548e746317 100644 --- a/i18n/ita/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json +++ b/i18n/ita/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json @@ -5,8 +5,6 @@ // Do not edit this file. It is machine generated. { "aria.oneReference": "simbolo in {0} alla riga {1} colonna {2}", - "aria.fileReferences.1": "1 simbolo in {0}", - "aria.fileReferences.N": "{0} simboli in {1}", "aria.result.0": "Non sono stati trovati risultati", "aria.result.1": "Trovato 1 simbolo in {0}", "aria.result.n1": "Trovati {0} simboli in {1}", diff --git a/i18n/ita/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json b/i18n/ita/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json index 660d8200868..f595c9809b7 100644 --- a/i18n/ita/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json +++ b/i18n/ita/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json @@ -21,6 +21,8 @@ "menus.scmTitle": "Menu del titolo del controllo del codice sorgente", "menus.resourceGroupContext": "Menu di scelta rapida del gruppo di risorse del controllo del codice sorgente", "menus.resourceStateContext": "Menu di scelta rapida dello stato delle risorse del controllo del codice sorgente", + "view.viewTitle": "Menu del titolo della visualizzazione contribuita", + "view.itemContext": "Menu di contesto dell'elemento visualizzazione contribuita", "nonempty": "è previsto un valore non vuoto.", "opticon": "la proprietà `icon` può essere omessa o deve essere una stringa o un valore letterale come `{dark, light}`", "requireStringOrObject": "la proprietà `{0}` è obbligatoria e deve essere di tipo `object` o `string`", diff --git a/i18n/ita/src/vs/platform/extensions/common/extensionsRegistry.i18n.json b/i18n/ita/src/vs/platform/extensions/common/extensionsRegistry.i18n.json index e23bc5864c4..afe0f0f2880 100644 --- a/i18n/ita/src/vs/platform/extensions/common/extensionsRegistry.i18n.json +++ b/i18n/ita/src/vs/platform/extensions/common/extensionsRegistry.i18n.json @@ -14,6 +14,12 @@ "vscode.extension.contributes": "Tutti i contributi dell'estensione Visual Studio Code rappresentati da questo pacchetto.", "vscode.extension.preview": "Imposta l'estensione in modo che venga contrassegnata come Anteprima nel Marketplace.", "vscode.extension.activationEvents": "Eventi di attivazione per l'estensione Visual Studio Code.", + "vscode.extension.activationEvents.onLanguage": "Un evento di attivazione emesso ogni volta che viene aperto un file che risolve nella lingua specificata.", + "vscode.extension.activationEvents.onCommand": "Un evento di attivazione emesso ogni volta che viene invocato il comando specificato.", + "vscode.extension.activationEvents.onDebug": "Un evento di attivazione emesso ogni volta che viene iniziata una sessione di debug del tipo specificato.", + "vscode.extension.activationEvents.workspaceContains": "Un evento di attivazione emesso ogni volta che si apre una cartella che contiene almeno un file corrispondente al criterio GLOB specificato.", + "vscode.extension.activationEvents.onView": "Un evento di attivazione emesso ogni volta che la visualizzazione specificata viene espansa.", + "vscode.extension.activationEvents.star": "Un evento di attivazione emesso all'avvio di VS Code. Per garantire la migliore esperienza per l'utente finale, sei pregato di utilizzare questo evento di attivazione nella tua estensione solo quando nessun'altra combinazione di eventi di attivazione funziona nel tuo caso.", "vscode.extension.badges": "Matrice di notifiche da visualizzare nella barra laterale della pagina delle estensioni del Marketplace.", "vscode.extension.badges.url": "URL di immagine della notifica.", "vscode.extension.badges.href": "Collegamento della notifica.", diff --git a/i18n/ita/src/vs/platform/history/electron-main/historyMainService.i18n.json b/i18n/ita/src/vs/platform/history/electron-main/historyMainService.i18n.json new file mode 100644 index 00000000000..53a0dcd14b3 --- /dev/null +++ b/i18n/ita/src/vs/platform/history/electron-main/historyMainService.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "newWindow": "Nuova finestra", + "newWindowDesc": "Apre una nuova finestra", + "recentFolders": "Cartelle recenti", + "folderDesc": "{0} {1}" +} \ No newline at end of file diff --git a/i18n/ita/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/ita/src/vs/platform/theme/common/colorRegistry.i18n.json index 4822dfeb812..bfe7913ae5f 100644 --- a/i18n/ita/src/vs/platform/theme/common/colorRegistry.i18n.json +++ b/i18n/ita/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -12,7 +12,6 @@ "focusBorder": "Colore dei bordi degli elementi evidenziati. Questo colore è utilizzato solo se non viene sovrascritto da un componente.", "contrastBorder": "Un bordo supplementare attorno agli elementi per contrastarli maggiormente rispetto agli altri.", "activeContrastBorder": "Un bordo supplementare intorno agli elementi attivi per contrastarli maggiormente rispetto agli altri.", - "selectionBackground": "Il colore di sfondo delle selezioni di testo nel workbench (ad esempio per i campi di input o aree di testo). Si noti che questo non si applica alle selezioni all'interno dell'editor e del terminale.", "textSeparatorForeground": "Colore dei separatori di testo.", "textLinkForeground": "Colore primo piano dei link nel testo.", "textLinkActiveForeground": "Colore primo piano dei link attivi nel testo.", @@ -60,6 +59,7 @@ "editorBackground": "Colore di sfondo dell'editor.", "editorForeground": "Colore primo piano predefinito dell'editor.", "editorWidgetBackground": "Colore di sfondo dei widget dell'editor, ad esempio Trova/Sostituisci.", + "editorWidgetBorder": "Colore bordo dei widget dell'editor. Il colore viene utilizzato solo se il widget sceglie di avere un bordo e se il colore non è sottoposto a override da un widget.", "editorSelection": "Colore della selezione dell'editor.", "editorInactiveSelection": "Colore della selezione in un editor inattivo.", "editorSelectionHighlight": "Colore delle aree con lo stesso contenuto della selezione.", @@ -74,10 +74,11 @@ "diffEditorRemoved": "Colore di sfondo del testo che è stato rimosso.", "diffEditorInsertedOutline": "Colore del contorno del testo che è stato inserito.", "diffEditorRemovedOutline": "Colore del contorno del testo che è stato rimosso.", - "mergeCurrentHeaderBackground": "Sfondo intestazione corrente in conflitto di merge in linea.", - "mergeCurrentContentBackground": "Sfondo contenuto corrente in conflitto di merge in linea.", - "mergeIncomingHeaderBackground": "Sfondo intestazione modifica in ingresso in conflitto di merge in linea.", - "mergeIncomingContentBackground": "Sfondo contenuto modifica in ingresso in conflitto di merge in linea.", - "overviewRulerCurrentContentForeground": "Primo piano righello panoramica corrente per conflitto di merge in linea.", - "overviewRulerIncomingContentForeground": "Primo piano righello panoramica modifiche in ingresso per conflitto di merge in linea." + "mergeCurrentHeaderBackground": "Sfondo intestazione corrente in conflitti di merge in linea.", + "mergeCurrentContentBackground": "Sfondo contenuto corrente in conflitti di merge in linea.", + "mergeIncomingHeaderBackground": "Sfondo intestazione modifica in ingresso in conflitti di merge in linea.", + "mergeIncomingContentBackground": "Sfondo contenuto modifica in ingresso in conflitti di merge in linea.", + "mergeBorder": "Colore bordo su intestazioni e sulla barra di divisione di conflitti di merge in linea.", + "overviewRulerCurrentContentForeground": "Colore primo piano righello panoramica attuale per i conflitti di merge in linea.", + "overviewRulerIncomingContentForeground": "Colore primo piano del righello panoramica modifiche in arrivo per i conflitti di merge in linea." } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/ita/src/vs/workbench/api/node/extHostTask.i18n.json index 8b6ad71cd4e..4b90a12aaf2 100644 --- a/i18n/ita/src/vs/workbench/api/node/extHostTask.i18n.json +++ b/i18n/ita/src/vs/workbench/api/node/extHostTask.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "task.label": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/api/node/extHostTreeViews.i18n.json b/i18n/ita/src/vs/workbench/api/node/extHostTreeViews.i18n.json index 8b6ad71cd4e..04c4b11db8c 100644 --- a/i18n/ita/src/vs/workbench/api/node/extHostTreeViews.i18n.json +++ b/i18n/ita/src/vs/workbench/api/node/extHostTreeViews.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "treeView.notRegistered": "Nessuna visualizzazione di struttura ad albero con ID '{0}' registrata.", + "treeItem.notFound": "Nessun elemento di struttura ad albero con id '{0}' trovato.", + "treeView.duplicateElement": "L'elemento {0} è già registrato" +} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/browser/actions/configureLocale.i18n.json b/i18n/ita/src/vs/workbench/browser/actions/configureLocale.i18n.json index c9c8c1ec3e5..a124f7f6f31 100644 --- a/i18n/ita/src/vs/workbench/browser/actions/configureLocale.i18n.json +++ b/i18n/ita/src/vs/workbench/browser/actions/configureLocale.i18n.json @@ -7,6 +7,7 @@ "configureLocale": "Configura lingua", "displayLanguage": "Definisce la lingua visualizzata di VSCode.", "doc": "Per un elenco delle lingue supportate, vedere {0}.", + "restart": "Se si modifica il valore, è necessario riavviare VSCode.", "fail.createSettings": "Non è possibile creare '{0}' ({1}).", "JsonSchema.locale": "Linguaggio dell'interfaccia utente da usare." } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json b/i18n/ita/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json index 16c143386a8..d8cbee32bd5 100644 --- a/i18n/ita/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json +++ b/i18n/ita/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json @@ -5,5 +5,6 @@ // Do not edit this file. It is machine generated. { "hideActivitBar": "Nascondi barra attività", - "activityBarAriaLabel": "Cambio visualizzazione attiva" + "activityBarAriaLabel": "Cambio visualizzazione attiva", + "globalActions": "Azioni globali" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json b/i18n/ita/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json index 67fd42257c1..844b3b48060 100644 --- a/i18n/ita/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json +++ b/i18n/ita/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json @@ -10,7 +10,7 @@ "multiSelection": "{0} selezioni", "endOfLineLineFeed": "LF", "endOfLineCarriageReturnLineFeed": "CRLF", - "tabFocusModeEnabled": "Premere TAB per spostare lo stato attivo", + "screenReaderDetectedExtra": "Se non si utilizza un'utilità per la lettura dello schermo, si prega di impostare 'editor.accessibilitySupport' a \"off\".", "disableTabMode": "Disabilita modalità accessibilità", "gotoLine": "Vai alla riga", "indentation": "Rientro", diff --git a/i18n/ita/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json b/i18n/ita/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json new file mode 100644 index 00000000000..6a397dbe56c --- /dev/null +++ b/i18n/ita/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpen": "Vai al file...", + "quickNavigateNext": "Passa a successiva in Quick Open", + "quickNavigatePrevious": "Passa a precedente in Quick Open", + "quickSelectNext": "Seleziona successiva in Quick Open", + "quickSelectPrevious": "Seleziona precedente in Quick Open" +} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/browser/quickopen.i18n.json b/i18n/ita/src/vs/workbench/browser/quickopen.i18n.json index 5bd60920cf4..4419620dddd 100644 --- a/i18n/ita/src/vs/workbench/browser/quickopen.i18n.json +++ b/i18n/ita/src/vs/workbench/browser/quickopen.i18n.json @@ -6,6 +6,5 @@ { "noResultsMatching": "Non ci sono risultati corrispondenti", "noResultsFound2": "Non sono stati trovati risultati", - "entryAriaLabel": "{0}, comando", - "noCommands": "Non ci sono comandi corrispondenti" + "entryAriaLabel": "{0}, comando" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/browser/viewlet.i18n.json b/i18n/ita/src/vs/workbench/browser/viewlet.i18n.json index 318000e2718..7ffc4d29a97 100644 --- a/i18n/ita/src/vs/workbench/browser/viewlet.i18n.json +++ b/i18n/ita/src/vs/workbench/browser/viewlet.i18n.json @@ -4,6 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "collapse": "Comprimi tutto", - "viewToolbarAriaLabel": "Azioni di {0}" + "collapse": "Comprimi tutto" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/common/theme.i18n.json b/i18n/ita/src/vs/workbench/common/theme.i18n.json index 213ebbab5dc..bdefeb9c236 100644 --- a/i18n/ita/src/vs/workbench/common/theme.i18n.json +++ b/i18n/ita/src/vs/workbench/common/theme.i18n.json @@ -7,27 +7,42 @@ "tabActiveBackground": "Colore di sfondo delle schede attive. Le schede sono i contenitori degli editor nell'area degli editor. È possibile aprire più schede in un gruppo di editor e possono esistere più gruppi di editor.", "tabInactiveBackground": "Colore di sfondo delle schede inattive. Le schede sono i contenitori degli editor nell'area degli editor. È possibile aprire più schede in un gruppo di editor e possono esistere più gruppi di editor.", "tabBorder": "Bordo per separare le schede l'una dall'altra. Le schede sono i contenitori degli editor nell'area degli editor. È possibile aprire più schede in un gruppo di editor e possono esistere più gruppi di editor.", + "tabActiveForeground": "Colore di primo piano delle schede attive in un gruppo attivo. Le schede sono i contenitori degli editor nell'area degli editor. È possibile aprire più schede in un gruppo di editor e possono esistere più gruppi di editor.", + "tabInactiveForeground": "Colore di primo piano delle schede inattive in un gruppo attivo. Le schede sono i contenitori degli editor nell'area degli editor. È possibile aprire più schede in un gruppo di editor e possono esistere più gruppi di editor.", + "tabUnfocusedActiveForeground": "Colore di primo piano delle schede attive in un gruppo inattivo. Le schede sono i contenitori degli editor nell'area degli editor. È possibile aprire più schede in un gruppo di editor e possono esistere più gruppi di editor.", + "tabUnfocusedInactiveForeground": "Colore di primo piano delle schede inattiva in un gruppo inattivo. Le schede sono i contenitori degli editor nell'area degli editor. È possibile aprire più schede in un gruppo di editor e possono esistere più gruppi di editor.", "editorGroupBackground": "Colore di sfondo di un gruppo di editor. I gruppi di editor sono contenitori di editor. Il colore di sfondo viene visualizzato quando si trascinano i gruppi di editor in un'altra posizione.", + "tabsContainerBackground": "Colore di sfondo dell'intestazione del titolo di gruppo di editor, quando le schede sono abilitate. I gruppi di editor sono i contenitori degli editor.", + "tabsContainerBorder": "Colore del bordo dell'intestazione del titolo di gruppo di editor, quando le schede sono abilitate. I gruppi di editor sono i contenitori degli editor.", "editorGroupHeaderBackground": "Colore di sfondo dell'intestazione del titolo dell'editor quando le schede sono disabilitate. I gruppi di editor sono contenitori di editor.", "editorGroupBorder": "Colore per separare più gruppi di editor l'uno dall'altro. I gruppi di editor sono i contenitori degli editor.", + "editorDragAndDropBackground": "Colore di sfondo quando si trascinano gli editor. Il colore dovrebbe avere una trasparenza impostata in modo che il contenuto dell'editor sia ancora visibile.", + "panelBackground": "Colore di sfondo dei pannelli. I pannelli sono visualizzati sotto l'area degli editor e contengono visualizzazioni quali quella di output e del terminale integrato.", "panelBorder": "Colore del bordo dei pannelli nella parte superiore di separazione dall'editor. I pannelli sono visualizzati sotto l'area degli editor e contengono visualizzazioni quali quella di output e del terminale integrato.", "panelActiveTitleForeground": "Colore del titolo del pannello attivo. I pannelli sono visualizzati sotto l'area degli editor e contengono visualizzazioni quali quella di output e quella del terminale integrato.", "panelInactiveTitleForeground": "Colore del titolo del pannello inattivo. I pannelli sono visualizzati sotto l'area degli editor e contengono visualizzazioni quali quella di output e quella del terminale integrato.", "panelActiveTitleBorder": "Colore del bordo del titolo del pannello attivo. I pannelli sono visualizzati sotto l'area degli editor e contengono visualizzazioni quali quella di output e del terminale integrato.", "statusBarForeground": "Colore primo piano della barra di stato. La barra di stato è visualizzata nella parte inferiore della finestra.", "statusBarBackground": "Colore di sfondo della barra di stato standard. La barra di stato è visualizzata nella parte inferiore della finestra.", + "statusBarBorder": "Colore del bordo della barra di stato che la separa dalla sidebar e dall'editor. La barra di stato è visualizzata nella parte inferiore della finestra.", "statusBarNoFolderBackground": "Colore di sfondo della barra di stato quando non ci sono cartelle aperte. La barra di stato è visualizzata nella parte inferiore della finestra.", + "statusBarNoFolderForeground": "Colore primo piano quando non ci sono cartelle aperte. La barra di stato è visualizzata nella parte inferiore della finestra.", "statusBarItemActiveBackground": "Colore di sfondo degli elementi della barra di stato quando si fa clic. La barra di stato è visualizzata nella parte inferiore della finestra.", "statusBarItemHoverBackground": "Colore di sfondo degli elementi della barra di stato al passaggio del mouse. La barra di stato è visualizzata nella parte inferiore della finestra.", "statusBarProminentItemBackground": "Colore di sfondo degli elementi rilevanti della barra di stato. Gli elementi rilevanti spiccano rispetto ad altre voci della barra di stato. La barra di stato è visualizzata nella parte inferiore della finestra.", "statusBarProminentItemHoverBackground": "Colore di sfondo degli elementi rilevanti della barra di stato al passaggio del mouse. Gli elementi rilevanti spiccano rispetto ad altre voci della barra di stato. La barra di stato è visualizzata nella parte inferiore della finestra.", "activityBarBackground": "Colore di sfondo della barra attività. La barra attività viene visualizzata nella parte inferiore sinistra/destra e consente il passaggio tra diverse visualizzazioni della barra laterale", "activityBarForeground": "Colore primo piano della barra attività (ad es. quello utilizzato per le icone). La barra attività viene mostrata all'estrema sinistra o destra e permette di alternare le visualizzazioni della barra laterale.", + "activityBarBorder": "Colore del bordo della barra attività che la separa dalla barra laterale. La barra di attività viene mostrata all'estrema sinistra o destra e permette di alternare le visualizzazioni della barra laterale.", + "activityBarDragAndDropBackground": "Colore feedback drag and drop per gli elementi della barra di attività. Il colore dovrebbe avere una trasparenza impostata in modo che le voci della barra di attività possano ancora essere visibili. La barra di attività viene mostrata all'estrema sinistra o destra e permette di alternare le visualizzazioni della barra laterale.", "activityBarBadgeBackground": "Colore di sfondo della notifica utente dell'attività. La barra attività viene visualizzata all'estrema sinistra o all'estrema destra e consente di spostarsi tra le visualizzazioni della barra laterale.", "activityBarBadgeForeground": "Colore primo piano della notifica utente dell'attività. La barra attività viene visualizzata all'estrema sinistra o all'estrema destra e consente di spostarsi tra le visualizzazioni della barra laterale.", "sideBarBackground": "Colore di sfondo della barra laterale. La barra laterale è il contenitore per visualizzazioni come Explorer e ricerca.", + "sideBarForeground": "Colore primo piano della barra laterale. La barra laterale è il contenitore per le visualizzazioni come Esplora risorse e Cerca.", + "sideBarBorder": "Colore del bordo della barra laterale che la separa all'editor. La barra laterale è il contenitore per visualizzazioni come Esplora risorse e Cerca.", "sideBarTitleForeground": "Colore primo piano del titolo della barra laterale. La barra laterale è il contenitore per visualizzazioni come Explorer e ricerca.", "sideBarSectionHeaderBackground": "Colore di sfondo dell'intestazione di sezione della barra laterale. La barra laterale è il contenitore di visualizzazioni quali Esplora risorse e Cerca.", + "sideBarSectionHeaderForeground": "Colore primo piano dell'intestazione di sezione della barra laterale. La barra laterale è il contenitore di visualizzazioni come Esplora risorse e Cerca.", "titleBarActiveForeground": "Colore primo piano della barra del titolo quando la finestra è attiva. Si noti che questo colore è attualmente supportato solo su macOS.", "titleBarInactiveForeground": "Colore primo piano della barra del titolo quando la finestra è inattiva. Si noti che questo colore è attualmente supportato solo su macOS.", "titleBarActiveBackground": "Colore di sfondo della barra di titolo quando la finestra è attiva. Si noti che questo colore è attualmente solo supportati su macOS.", diff --git a/i18n/ita/src/vs/workbench/electron-browser/actions.i18n.json b/i18n/ita/src/vs/workbench/electron-browser/actions.i18n.json index c1c0558b02c..d9d488bcccd 100644 --- a/i18n/ita/src/vs/workbench/electron-browser/actions.i18n.json +++ b/i18n/ita/src/vs/workbench/electron-browser/actions.i18n.json @@ -6,9 +6,6 @@ { "closeActiveEditor": "Chiudi editor", "closeWindow": "Chiudi finestra", - "switchWindow": "Cambia finestra", - "switchWindowPlaceHolder": "Selezionare una finestra", - "current": "Finestra corrente", "closeFolder": "Chiudi cartella", "noFolderOpened": "In questa istanza non ci sono attualmente cartelle aperte da chiudere.", "newWindow": "Nuova finestra", @@ -20,7 +17,7 @@ "zoomReset": "Reimposta zoom", "appPerf": "Prestazioni all'avvio", "reloadWindow": "Ricarica finestra", - "openRecent": "Apri recenti", + "current": "Finestra corrente", "folders": "cartelle", "files": "file", "openRecentPlaceHolderMac": "Selezionare un percorso (tenere premuto CMD per aprirlo in una nuova finestra)", @@ -32,10 +29,6 @@ "openDocumentationUrl": "Documentazione", "openIntroductoryVideosUrl": "Video introduttivi", "toggleSharedProcess": "Attiva/Disattiva processo condiviso", - "navigateLeft": "Passa alla visualizzazione a sinistra", - "navigateRight": "Passa alla visualizzazione a destra", - "navigateUp": "Passa alla visualizzazione in alto", - "navigateDown": "Passa alla visualizzazione in basso", "increaseViewSize": "Aumenta la dimensione della visualizzazione corrente", "decreaseViewSize": "Diminuisce la dimensione della visualizzazione corrente" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/ita/src/vs/workbench/electron-browser/main.contribution.i18n.json index b13e3a07bdd..b12b597ea59 100644 --- a/i18n/ita/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/ita/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -31,10 +31,6 @@ "window.openFoldersInNewWindow.off": "Le cartelle sostituiranno l'ultima finestra attiva", "window.openFoldersInNewWindow.default": "Le cartelle verranno aperte in una nuova finestra a meno che non si selezioni una cartella dall'interno dell'applicazione, ad esempio tramite il menu File", "openFoldersInNewWindow": "Controlla se le cartelle devono essere aperte in una nuova finestra o sostituire l'ultima finestra attiva.\n- default: le cartelle verranno aperte in una nuova finestra a meno che non si selezioni una cartella dall'interno dell'applicazione, ad esempio tramite il menu File\n- on: le cartelle verranno aperte in una nuova finestra\n- off: le cartelle sostituiranno l'ultima finestra attiva\nNota: possono comunque verificarsi casi in cui questa impostazione viene ignorata, ad esempio quando si usa l'opzione della riga di comando -new-window o -reuse-window.", - "window.reopenFolders.none": "Non apre nessuna cartella.", - "window.reopenFolders.one": "Riapre l'ultima cartella attiva.", - "window.reopenFolders.all": "Riapre tutte le cartelle dell'ultima sessione.", - "reopenFolders": "Controlla la modalità di riapertura delle cartelle dopo un riavvio. Selezionare 'none' per non riaprire mai una cartella, 'one' per riaprire l'ultima cartella usata oppure 'all' per riaprire tutte le cartelle dell'ultima sessione.", "restoreFullscreen": "Controlla se una finestra deve essere ripristinata a schermo intero se è stata chiusa in questa modalità.", "zoomLevel": "Consente di modificare il livello di zoom della finestra. Il valore originale è 0 e ogni incremento superiore (ad esempio 1) o inferiore (ad esempio -1) rappresenta un aumento o una diminuzione del 20% della percentuale di zoom. È anche possibile immettere valori decimali per modificare il livello di zoom con maggiore granularità.", "title": "Controlla il titolo della finestra in base all'editor attivo. Le variabili vengono sostituite a seconda del contesto:\n${activeEditorShort}: ad esempio myFile.txt\n${activeEditorMedium}: ad esempio myFolder/myFile.txt\n${activeEditorLong}: ad esempio /Users/Development/myProject/myFolder/myFile.txt\n${rootName}: ad esempio myProject\n${rootPath}: ad esempio /Users/Development/myProject\n${appName}: ad esempio VS Code\n${dirty}: un indicatore dirty se l'editor attivo è dirty\n${separator}: un separatore condizionale (\" - \") visualizzato solo se circondato da variabili con valori", @@ -42,11 +38,13 @@ "window.newWindowDimensions.inherit": "Apre nuove finestre le cui dimensioni sono uguali a quelle dell'ultima finestra attiva.", "window.newWindowDimensions.maximized": "Apre nuove finestre ingrandite a schermo intero.", "window.newWindowDimensions.fullscreen": "Apre nuove finestre nella modalità a schermo intero.", + "newWindowDimensions": "Controlla le dimensioni relative all'apertura di una nuova finestra quando almeno un'altra finestra è già aperta. Per impostazione predefinita, una nuova finestra di dimensioni ridotte viene aperta al centro della schermata. Se è impostata su 'inherit', la finestra assumerà le stesse dimensioni dell'ultima finestra attiva. Se è impostata su 'maximized', la finestra aperta risulterà ingrandita, mentre con 'fullscreen' verrà visualizzata a schermo intero. Sia noti che questa impostazione non impatta sulla prima finestra che era stata aperta. La prima finestra si riaprirà sempre con la dimensione e la posizione che aveva prima della chiusura.", "window.menuBarVisibility.default": "Il menu è nascosto solo nella modalità a schermo intero.", "window.menuBarVisibility.visible": "Il menu è sempre visibile, anche nella modalità a schermo intero.", "window.menuBarVisibility.toggle": "Il menu è nascosto ma può essere visualizzato premendo ALT.", "window.menuBarVisibility.hidden": "Il menu è sempre nascosto.", "menuBarVisibility": "Controlla la visibilità della barra dei menu. L'impostazione 'toggle' indica che la barra dei menu è nascosta e che per visualizzarla è necessario premere una sola volta il tasto ALT. Per impostazione predefinita, la barra dei menu è visibile a meno che la finestra non sia a schermo intero.", + "enableMenuBarMnemonics": "Se abilitato, i menu principali possono essere aperti tramite tasti di scelta rapida Alt + tasto. Disattivare i tasti di scelta permette invece di associare questi tasti di scelta rapida Alt + tasto ai comandi dell'editor.", "autoDetectHighContrast": "Se è abilitata, passa automaticamente a un tema a contrasto elevato se Windows usa un tema di questo tipo e al tipo scuro quando non si usa più un tema a contrasto elevato Windows.", "titleBarStyle": "Consente di modificare l'aspetto della barra del titolo della finestra. Per applicare le modifiche, è necessario un riavvio completo.", "window.nativeTabs": "Abilita le finestre di tab per macOS Sierra. La modifica richiede un riavvio. Eventuali personalizzazioni della barra del titolo verranno disabilitate", @@ -56,5 +54,7 @@ "zenMode.hideTabs": "Controlla se attivando la modalità Zen vengono nascoste anche le schede del workbench.", "zenMode.hideStatusBar": "Controlla se attivando la modalità Zen viene nascosta anche la barra di stato nella parte inferiore del workbench.", "zenMode.hideActivityBar": "Controlla se attivando la modalità Zen viene nascosta anche la barra di stato alla sinistra del workbench", - "zenMode.restore": "Controlla se una finestra deve essere ripristinata nella modalità Zen se è stata chiusa in questa modalità." + "zenMode.restore": "Controlla se una finestra deve essere ripristinata nella modalità Zen se è stata chiusa in questa modalità.", + "workspaceConfigurationTitle": "Area di lavoro", + "files.exclude.boolean": "Criterio GLOB da usare per trovare percorsi file. Impostare su True o False per abilitare o disabilitare il criterio." } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json b/i18n/ita/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json new file mode 100644 index 00000000000..01386d94315 --- /dev/null +++ b/i18n/ita/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json @@ -0,0 +1,26 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "emergencyConfOn": "Modifica dell'impostazione 'editor.accessibilitySupport' a 'on' in corso.", + "openingDocs": "Apertura della pagina di documentazione sull'accessibilità di VS Code in corso.", + "introMsg": "Grazie per aver provato le opzioni di accessibilità di Visual Studio Code.", + "status": "Stato:", + "changeConfigToOnMac": "Premere Comando+E per configurare l'editor per essere definitivamente ottimizzato per l'utilizzo con un un'utilità per la lettura dello schermo.", + "changeConfigToOnWinLinux": "Premere Control+E per configurare l'editor per essere definitivamente ottimizzato per l'utilizzo con un un'utilità per la lettura dello schermo.", + "auto_unknown": "L'editor è configurato per utilizzare le API della piattaforma per rilevare quando è collegata un'utilità per la lettura dello schermo ma il runtime corrente non lo supporta.", + "auto_on": "L'editor ha rilevato automaticamente che è collegata un'utilità per la lettura dello schermo.", + "auto_off": "L'editor è configurato per rilevare automaticamente quando è collegata un'utilità per la lettura dello schermo, che non è collegata in questo momento.", + "configuredOn": "L'editor è configurato per essere definitivamente ottimizzato per l'utilizzo con un'utilità per la lettura dello schermo - è possibile modificare questo modificando l'impostazione 'editor.accessibilitySupport'.", + "configuredOff": "L'editor è configurato per non essere ottimizzato per l'utilizzo con un'utilità per la lettura dello schermo.", + "tabFocusModeOnMsg": "Premere TAB nell'editor corrente per spostare lo stato attivo sull'elemento con stato attivabile successivo. Per attivare/disattivare questo comportamento, premere {0}.", + "tabFocusModeOnMsgNoKb": "Premere TAB nell'editor corrente per spostare lo stato attivo sull'elemento con stato attivabile successivo. Il comando {0} non può essere attualmente attivato con un tasto di scelta rapida.", + "tabFocusModeOffMsg": "Premere TAB nell'editor corrente per inserire il carattere di tabulazione. Per attivare/disattivare questo comportamento, premere {0}.", + "tabFocusModeOffMsgNoKb": "Premere TAB nell'editor corrente per inserire il carattere di tabulazione. Il comando {0} non può essere attualmente attivato con un tasto di scelta rapida.", + "openDocMac": "Premere Comando+H per aprire una finestra del browser con maggiori informazioni relative all'accessibilità di VS Code.", + "openDocWinLinux": "Premere Control+H per aprire una finestra del browser con maggiori informazioni relative all'accessibilità di VS Code.", + "outroMsg": "Per chiudere questa descrizione comando e tornare all'editor, premere ESC o MAIUSC+ESC.", + "ShowAccessibilityHelpAction": "Visualizza la Guida sull'accessibilità" +} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json b/i18n/ita/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ita/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json b/i18n/ita/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json new file mode 100644 index 00000000000..839633747f5 --- /dev/null +++ b/i18n/ita/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleLocation": "Modificatore per l'attivazione/disattivazione multi-cursore" +} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/debug/browser/debugActions.i18n.json b/i18n/ita/src/vs/workbench/parts/debug/browser/debugActions.i18n.json index d4c6f2a6486..dbac73dc76f 100644 --- a/i18n/ita/src/vs/workbench/parts/debug/browser/debugActions.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/debug/browser/debugActions.i18n.json @@ -6,6 +6,7 @@ { "openLaunchJson": "Apri {0}", "launchJsonNeedsConfigurtion": "Configurare o correggere 'launch.json'", + "noFolderDebugConfig": "Si prega di aprire prima una cartella per consentire una configurazione di debug avanzato.", "startDebug": "Avvia debug", "startWithoutDebugging": "Avvia senza eseguire debug", "selectAndStartDebugging": "Seleziona e avvia il debug", diff --git a/i18n/ita/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json b/i18n/ita/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json index 8b6ad71cd4e..f521324695b 100644 --- a/i18n/ita/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "noFolderDebugConfig": "Si prega di aprire prima una cartella per consentire una configurazione di debug avanzato." +} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json b/i18n/ita/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json index 87d81fe2142..78aa8974cb4 100644 --- a/i18n/ita/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json @@ -5,16 +5,12 @@ // Do not edit this file. It is machine generated. { "variablesSection": "Sezione Variabili", - "variables": "Variabili", "variablesAriaTreeLabel": "Esegui debug variabili", "expressionsSection": "Sezione Espressioni", - "watch": "Espressione di controllo", "watchAriaTreeLabel": "Esegui debug espressioni di controllo", "callstackSection": "Sezione Stack di chiamate", "debugStopped": "In pausa su {0}", - "callStack": "Stack di chiamate", "callStackAriaLabel": "Esegui debug stack di chiamate", "breakpointsSection": "Sezione Punti di interruzione", - "breakpoints": "Punti di interruzione", "breakpointsAriaTreeLabel": "Esegui debug punti di interruzione" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json b/i18n/ita/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json index d65947bfcbc..ae849e1dfbb 100644 --- a/i18n/ita/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json @@ -6,5 +6,6 @@ { "copyValue": "Copia valore", "copy": "Copia", + "copyAll": "Copia tutti", "copyStackTrace": "Copia stack di chiamate" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json b/i18n/ita/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json index 8de054fa31b..c13997bfc29 100644 --- a/i18n/ita/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "statusBarDebuggingBackground": "Colore di sfondo della barra di stato quando è in corso il debug di un programma. La barra di stato è visualizzata nella parte inferiore della finestra" + "statusBarDebuggingBackground": "Colore di sfondo della barra di stato quando è in corso il debug di un programma. La barra di stato è visualizzata nella parte inferiore della finestra", + "statusBarDebuggingForeground": "Colore primo piano della barra di stato quando è in corso il debug di un programma. La barra di stato è visualizzata nella parte inferiore della finestra" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json b/i18n/ita/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json index 53d3bcdd1ee..d116abf4820 100644 --- a/i18n/ita/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json @@ -7,6 +7,7 @@ "debugAdapterBinNotFound": "Il file eseguibile '{0}' dell'adattatore di debug non esiste.", "debugAdapterCannotDetermineExecutable": "Non è possibile determinare il file eseguibile per l'adattatore di debug '{0}'.", "debugType": "Tipo di configurazione.", + "debugTypeNotRecognised": "Il tipo di debug non è riconosciuto. Assicurarsi di avere un'estensione appropriata per il debug installata e che sia abilitata.", "node2NotSupported": "\"node2\" non è più supportato. In alternativa, usare \"node\" e impostare l'attributo \"protocol\" su \"inspector\".", "debugName": "Nome della configurazione. Viene visualizzato nel menu a discesa della configurazione di avvio.", "debugRequest": "Tipo della richiesta di configurazione. Può essere \"launch\" o \"attach\".", diff --git a/i18n/ita/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json b/i18n/ita/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json index 1549e77ce27..34249d623c8 100644 --- a/i18n/ita/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json @@ -4,6 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "previousEditPoint": "Emmet: Punto di modifica precedente", - "nextEditPoint": "Emmet: Punto di modifica successivo" + "previousEditPoint": "Emmet: andare al punto di modifica precedente", + "nextEditPoint": "Emmet: andare al punto di modifica successivo" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json b/i18n/ita/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json index 2b16a19f047..dc9fac282b1 100644 --- a/i18n/ita/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json @@ -9,5 +9,6 @@ "emmetPreferences": "Preferenze usate per modificare il comportamento di alcune azioni e i resolver di Emmet.", "emmetSyntaxProfiles": "Consente di definire il profilo per la sintassi specificata oppure di usare un profilo personalizzato con regole specifiche.", "emmetExclude": "Matrice di linguaggi in cui le abbreviazioni Emmet non devono essere espanse.", - "emmetExtensionsPath": "Percorso di una cartella contenente snippet, preferenze e profili Emmet" + "emmetExtensionsPath": "Percorso di una cartella contenente snippet, preferenze e profili Emmet", + "useNewEmmet": "Prova i nuovi moduli emmet (che andrà a sostituire la vecchia libreria singola emmet) per tutte le funzionalità emmet." } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json b/i18n/ita/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json index 9aeb226d9a3..6302bb9a38c 100644 --- a/i18n/ita/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json @@ -24,6 +24,10 @@ "default": "Impostazione predefinita", "debuggers": "Debugger ({0})", "debugger name": "Nome", + "views": "Visualizzazioni ({0})", + "view id": "ID", + "view name": "Nome", + "view location": "Dove", "themes": "Temi ({0})", "JSON Validation": "Convalida JSON ({0})", "commands": "Comandi ({0})", diff --git a/i18n/ita/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json b/i18n/ita/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json index 2199a5e0ccc..2430ac5cd9b 100644 --- a/i18n/ita/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json @@ -22,6 +22,8 @@ "disableGloballyAction": "Sempre", "disableAction": "Disabilita", "checkForUpdates": "Controlla la disponibilità di aggiornamenti", + "enableAutoUpdate": "Abilita l'aggiornamento automatico delle estensioni", + "disableAutoUpdate": "Disabilita l'aggiornamento automatico delle estensioni", "updateAll": "Aggiorna tutte le estensioni", "reloadAction": "Ricarica", "postUpdateTooltip": "Ricaricare per aggiornare", @@ -44,6 +46,8 @@ "showWorkspaceRecommendedExtensions": "Mostra estensioni consigliate per l'area di lavoro", "showRecommendedKeymapExtensions": "Mostra mappature tastiera consigliate", "showRecommendedKeymapExtensionsShort": "Mappature tastiera", + "showLanguageExtensions": "Mostra estensioni del linguaggio", + "showLanguageExtensionsShort": "Estensioni del linguaggio", "configureWorkspaceRecommendedExtensions": "Configura estensioni consigliate (area di lavoro)", "ConfigureWorkspaceRecommendations.noWorkspace": "Gli elementi consigliati sono disponibili solo per una cartella dell'area di lavoro.", "OpenExtensionsFile.failed": "Non è possibile creare il file 'extensions.json' all'interno della cartella '.vscode' ({0}).", @@ -51,5 +55,8 @@ "disableAll": "Disabilita tutte le estensioni installate", "disableAllWorkspace": "Disabilita tutte le estensioni installate per questa area di lavoro", "enableAll": "Abilita tutte le estensioni installate", - "enableAllWorkspace": "Abilita tutte le estensioni installate per questa area di lavoro" + "enableAllWorkspace": "Abilita tutte le estensioni installate per questa area di lavoro", + "extensionButtonProminentBackground": "Colore di sfondo delle azioni di estensioni che si distinguono (es. pulsante Installa).", + "extensionButtonProminentForeground": "Colore primo piano di pulsanti per azioni di estensioni che si distinguono (es. pulsante Installa).", + "extensionButtonProminentHoverBackground": "Colore di sfondo al passaggio del mouse dei pulsanti per azioni di estensione che si distinguono (es. pulsante Installa)." } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json b/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json index f84b219fb4e..9d16c7dad0f 100644 --- a/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json @@ -9,6 +9,8 @@ "neverShowAgain": "Non visualizzare più questo messaggio", "close": "Chiudi", "workspaceRecommended": "Per questa area di lavoro sono disponibili estensioni consigliate.", + "ignoreExtensionRecommendations": "Si desidera ignorare tutte le raccomandazioni di estensioni?", + "ignoreAll": "Sì, ignora tutti", "no": "No", "cancel": "Annulla" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json b/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json index 1122eeb85cf..12c0b28e83d 100644 --- a/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json @@ -10,5 +10,6 @@ "extensions": "Estensioni", "view": "Visualizza", "extensionsConfigurationTitle": "Estensioni", - "extensionsAutoUpdate": "Aggiorna automaticamente le estensioni" + "extensionsAutoUpdate": "Aggiorna automaticamente le estensioni", + "extensionsIgnoreRecommendations": "Ignora le raccomandazioni di estensioni" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 0a6152b0c7b..4822a5d71bc 100644 --- a/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -4,8 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "disableOtherKeymapsConfirmation": "Disabilitare altre mappature tastiera ({0}) per evitare conflitti tra tasti di scelta rapida?", "yes": "Sì", "no": "No", + "betterMergeDisabled": "L'estensione Better Merge (miglior merge) è ora incorporata: l'estensione installata è stata disattivata e può essere disinstallata.", "uninstall": "Disinstalla", "later": "In seguito" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/ita/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index a3c0e1da94b..69cc6c3dca2 100644 --- a/i18n/ita/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,6 +16,7 @@ "associations": "Consente di configurare le associazioni tra file e linguaggi, ad esempio \"*.extension\": \"html\". Queste hanno la precedenza sulle associazioni predefinite dei linguaggi installate.", "encoding": "Codifica del set di caratteri predefinita da usare durante la lettura e la scrittura di file.", "autoGuessEncoding": "Quando questa opzione è abilitata, la codifica del set di caratteri viene ipotizzata all'apertura dei file", + "eol": "Il carattere di fine riga predefinito. Utilizzare \\n per LF e \\r\\n per CRLF.", "trimTrailingWhitespace": "Se è abilitato, taglierà lo spazio vuoto quando si salva un file.", "insertFinalNewline": "Se è abilitato, inserisce un carattere di nuova riga finale alla fine del file durante il salvataggio.", "files.autoSave.off": "Un file dirty non viene mai salvato automaticamente.", @@ -26,6 +27,7 @@ "autoSaveDelay": "Controlla il ritardo in ms dopo il quale un file dirty viene salvato automaticamente. Si applica solo quando 'files.autoSave' è impostato su '{0}'", "watcherExclude": "Consente di configurare i criteri GLOB dei percorsi file da escludere dal controllo dei file. Se si modifica questa impostazione, è necessario riavviare. Quando si nota che Code consuma troppo tempo della CPU all'avvio, è possibile escludere le cartelle di grandi dimensioni per ridurre il carico iniziale.", "hotExit.off": "Disabilita Hot Exit.", + "hotExit.onExit": "La funzionalità Hot Exit verrà attivata alla chiusura dell'applicazione, ovvero quando si chiude l'ultima finestra in Windows/Linux o quando si attiva il comando workbench.action.quit (riquadro comandi, tasto di scelta rapida, menu). Tutte le finestre con backup verranno ripristinate al successivo avvio.", "hotExit": "Controlla se i file non salvati verranno memorizzati tra una sessione e l'altra, consentendo di ignorare il prompt di salvataggio alla chiusura dell'editor.", "defaultLanguage": "Modalità linguaggio predefinita assegnata ai nuovi file.", "editorConfigurationTitle": "Editor", diff --git a/i18n/ita/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json b/i18n/ita/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json index 71f3a7b410e..fccf829184b 100644 --- a/i18n/ita/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json @@ -5,7 +5,5 @@ // Do not edit this file. It is machine generated. { "explorerSection": "Sezione Esplora file", - "noWorkspace": "Nessuna cartella aperta", - "noWorkspaceHelp": "Non ci sono ancora cartelle aperte.", "openFolder": "Apri cartella" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json b/i18n/ita/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json index bc5c38d3fef..1f600783232 100644 --- a/i18n/ita/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json @@ -4,8 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "openEditosrSection": "Sezione Editor aperti", "openEditors": "Editor aperti", + "openEditosrSection": "Sezione Editor aperti", "treeAriaLabel": "Editor aperti: elenco di file attivi", "dirtyCounter": "{0} non salvati" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/ita/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json index 9e7b35dce5d..92488da0463 100644 --- a/i18n/ita/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -5,5 +5,7 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.start": "Definisci tasto di scelta rapida", - "defineKeybinding.kbLayoutErrorMessage": "Non sarà possibile produrre questa combinazione di tasti con il layout di tastiera corrente." + "defineKeybinding.kbLayoutErrorMessage": "Non sarà possibile produrre questa combinazione di tasti con il layout di tastiera corrente.", + "defineKeybinding.kbLayoutLocalAndUSMessage": "**{0}** per il layout di tastiera corrente (**{1}** per quello standard US).", + "defineKeybinding.kbLayoutLocalMessage": "**{0}** per il layout di tastiera corrente." } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json b/i18n/ita/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json index a9d3b766fda..23a476fe682 100644 --- a/i18n/ita/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json @@ -4,6 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "errorInvalidConfiguration": "Impossibile scrivere nelle impostazioni. Correggere eventuali errori o avvisi nel file e riprovare.", "editTtile": "Modifica", "replaceDefaultValue": "Sostituisci nelle impostazioni", "copyDefaultValue": "Copia nelle impostazioni", diff --git a/i18n/ita/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json b/i18n/ita/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json index 5be53aa1550..35875c08105 100644 --- a/i18n/ita/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "showTriggerActions": "Mostra tutti i comandi", + "showCommands.label": "Riquadro comandi...", "entryAriaLabelWithKey": "{0}, {1}, comandi", "entryAriaLabel": "{0}, comandi", "canNotRun": "Non è possibile eseguire il comando '{0}' da questa posizione.", diff --git a/i18n/ita/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json b/i18n/ita/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json new file mode 100644 index 00000000000..85fb16da61b --- /dev/null +++ b/i18n/ita/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "relaunchMessage": "È necessario riavviare per rendere effettiva un'impostazione modificata.", + "relaunchDetail": "Fare clic sul pulsante di riavvio per riavviare {0} e abilitare l'impostazione.", + "restart": "Riavvia" +} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/ita/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json index 8b6ad71cd4e..504c42cd090 100644 --- a/i18n/ita/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "editorGutterModifiedBackground": "Colore di sfondo della barra di navigazione dell'editor per le righe che sono state modificate.", + "editorGutterAddedBackground": "Colore di sfondo della barra di navigazione dell'editor per le righe che sono state aggiunte.", + "editorGutterDeletedBackground": "Colore di sfondo della barra di navigazione dell'editor per le righe che sono state cancellate." +} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json b/i18n/ita/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json index 529f073603a..9f3adc546ff 100644 --- a/i18n/ita/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "installAdditionalSCMProviders": "Installa ulteriori provider SCM ...", "switch provider": "Cambia provider SCM" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json b/i18n/ita/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json index ef09ca3283a..13608466e81 100644 --- a/i18n/ita/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json @@ -6,5 +6,7 @@ { "searchMatches": "{0} corrispondenze trovate", "searchMatch": "{0} corrispondenza trovata", - "fileMatchAriaLabel": "{0} corrispondenze nel file {1} della cartella {2}, risultato della ricerca" + "fileMatchAriaLabel": "{0} corrispondenze nel file {1} della cartella {2}, risultato della ricerca", + "replacePreviewResultAria": "Sostituisce il termine {0} con {1} alla colonna {2} in linea con il testo {3}", + "searchResultAria": "Trovato termine {0} alla colonna {1} in linea con il testo {2}" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json b/i18n/ita/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json index 78cd10645b4..cd9b550b98a 100644 --- a/i18n/ita/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json @@ -9,5 +9,6 @@ "vscode.extension.contributes.snippets-path": "Percorso del file snippets. È relativo alla cartella delle estensioni e in genere inizia con './snippets/'.", "invalid.language": "Il linguaggio in `contributes.{0}.language` è sconosciuto. Valore specificato: {1}", "invalid.path.0": "È previsto un valore stringa in `contributes.{0}.path`. Valore specificato: {1}", - "invalid.path.1": "Valore previsto di `contributes.{0}.path` ({1}) da includere nella cartella dell'estensione ({2}). L'estensione potrebbe non essere più portatile." + "invalid.path.1": "Valore previsto di `contributes.{0}.path` ({1}) da includere nella cartella dell'estensione ({2}). L'estensione potrebbe non essere più portatile.", + "badVariableUse": "Il frammento \"{0}\" molto probabilmente confonde variabili-frammento con segnaposti-frammento. Vedere https://code.visualstudio.com/docs/editor/userdefinedsnippets#_snippet-syntax per ulteriori dettagli." } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json b/i18n/ita/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json index 89c9cdec78e..ff128cda608 100644 --- a/i18n/ita/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json @@ -11,6 +11,6 @@ "snippetSchema.json.default": "Frammento vuoto", "snippetSchema.json": "Configurazione del frammento utente", "snippetSchema.json.prefix": "Prefisso da usare quando si seleziona il frammento in IntelliSense", - "snippetSchema.json.body": "Contenuto del frammento. Usare '${id}', '${id:label}', '${1:label}' per le variabili e '$0', '$1' per le posizioni del cursore", + "snippetSchema.json.body": "Il contenuto del frammento. Usare '$1', '${1:defaultText}' per definire le posizioni del cursore, utilizzare '$0' per la posizione finale del cursore. Inserire i valori delle variabili con '${varName}' e '${varName:defaultText}', ad esempio 'Nome del file: $TM_FILENAME'.", "snippetSchema.json.description": "Descrizione del frammento." } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json b/i18n/ita/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json new file mode 100644 index 00000000000..07b53da59b3 --- /dev/null +++ b/i18n/ita/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "helpUs": "Aiutaci a migliorare il nostro supporto all'{0}", + "takeShortSurvey": "Partecipa a un breve sondaggio", + "remindLater": "Visualizza più tardi", + "neverAgain": "Non visualizzare più questo messaggio" +} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json b/i18n/ita/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json new file mode 100644 index 00000000000..f5bb473c1df --- /dev/null +++ b/i18n/ita/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "surveyQuestion": "Partecipare a un breve sondaggio?", + "takeSurvey": "Partecipa a sondaggio", + "remindLater": "Visualizza più tardi", + "neverAgain": "Non visualizzare più questo messaggio" +} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json b/i18n/ita/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json new file mode 100644 index 00000000000..6574ffdaef1 --- /dev/null +++ b/i18n/ita/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noTasksMatching": "No tasks matching" +} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/ita/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index c0432625724..0e5967d8803 100644 --- a/i18n/ita/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0}, tasks" + "entryAriaLabel": "{0}, tasks", + "customizeTask": "Personalizza attività" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json b/i18n/ita/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json new file mode 100644 index 00000000000..6574ffdaef1 --- /dev/null +++ b/i18n/ita/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noTasksMatching": "No tasks matching" +} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/ita/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json index 7a620ff7e5a..f5aa6fc8cda 100644 --- a/i18n/ita/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -12,5 +12,6 @@ "ConfigurationParser.invalidVaraibleReference": "Errore: il riferimento a problemMatcher non è valido: {0}\n", "ConfigurationParser.noTaskName": "Errore: le attività devono specificare una proprietà taskName. L'attività verrà ignorata.\n{0}\n", "taskConfiguration.shellArgs": "Avviso: l'attività '{0}' è un comando della shell e il nome del comando o uno dei relativi argomenti contiene spazi senza codice di escape. Per garantire la corretta indicazione della riga di comando, unire gli argomenti nel comando.", + "taskConfiguration.noCommandOrDependsOn": "Errore: l'attività '{0}' non specifica un comando né una proprietà dependsOn. L'attività verrà ignorata. La sua definizione è:\n{1}", "taskConfiguration.noCommand": "Errore: l'attività '{0}' non definisce un comando. L'attività verrà ignorata. Definizione dell'attività:\n{1}" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json b/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json index b14b007cde5..2c148fe4900 100644 --- a/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json @@ -7,6 +7,7 @@ "JsonSchema.options": "Opzioni dei comandi aggiuntive", "JsonSchema.options.cwd": "Directory di lavoro corrente del programma o dello script eseguito. Se omesso, viene usata la radice dell'area di lavoro corrente di Visual Studio Code.", "JsonSchema.options.env": "Ambiente della shell o del programma eseguito. Se omesso, viene usato l'ambiente del processo padre.", + "JsonSchema.shellConfiguration": "Configura la shell da utilizzare.", "JsonSchema.shell.executable": "Shell da usare.", "JsonSchema.shell.args": "Argomenti della shell.", "JsonSchema.command": "Comando da eseguire. Può essere un programma esterno o un comando della shell.", diff --git a/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json b/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json index 2d791579971..9aefb1b07c7 100644 --- a/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json @@ -5,6 +5,8 @@ // Do not edit this file. It is machine generated. { "JsonSchema.version": "Numero di versione della configurazione", + "JsonSchema._runner": "Runner è stata promossa. Utilizzare la proprietà ufficiale runner", + "JsonSchema.runner": "Definisce se l'attività viene eseguita come un processo e l'output viene visualizzato nella finestra di output o all'interno del terminale.", "JsonSchema.windows": "Configurazione dei comandi specifica di Windows", "JsonSchema.mac": "Configurazione dei comandi specifica di Mac", "JsonSchema.linux": "Configurazione dei comandi specifica di Linux", diff --git a/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json index 8d0ab5a5a75..24f8e7f95aa 100644 --- a/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -7,6 +7,10 @@ "JsonSchema.shell": "Specifica se il comando è un comando della shell o un programma esterno. Se omesso, viene usato il valore predefinito false.", "JsonSchema.tasks.dependsOn.string": "Altra attività da cui dipende questa attività.", "JsonSchema.tasks.dependsOn.array": "Altre attività da cui dipende questa attività.", + "JsonSchema.tasks.group": "Definisce a quale gruppo di esecuzione appartiene questa attività. Se omesso l'attività non appartiene ad alcun gruppo.", + "JsonSchema.tasks.type": "Definisce se l'attività viene eseguita come un processo o come un comando all'interno di una shell. L'impostazione predefinita è processo.", + "JsonSchema.version": "Numero di versione della configurazione", + "JsonSchema.tasks.customize": "L'attività contribuita da personalizzare.", "JsonSchema.windows": "Configurazione dei comandi specifica di Windows", "JsonSchema.mac": "Configurazione dei comandi specifica di Mac", "JsonSchema.linux": "Configurazione dei comandi specifica di Linux" diff --git a/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json b/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json index 7be3f013ead..adad41059d1 100644 --- a/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json @@ -18,10 +18,12 @@ "problems": "Problemi", "manyMarkers": "Più di 99", "tasks": "Attività", + "TaskSystem.noHotSwap": "Per modificare il motore di esecuzione delle attività, è necessario riavviare VS Code. La modifica verrà ignorata.", "TaskService.noBuildTask": "Non è stata definita alcuna attività di Build. Contrassegnare un'attività con 'isBuildCommand' nel file tasks.json .", "TaskService.noTestTask": "Non è stata definita alcuna attività di test. Contrassegnare un'attività con 'isTestCommand' nel file tasks.json .", "TaskServer.noTask": "Attività {0} richiesta per l'esecuzione non trovata", - "TaskSystem.activeSame": "L'attività è già attiva e in modalità espressione di controllo. Per terminarla, usare `F1 > Termina attività`", + "customizeParseErrors": "La configurazione dell'attività corrente presenta errori. Per favore correggere gli errori prima di personalizzazione un'attività.", + "moreThanOneBuildTask": "tasks.json contiene molte attività di compilazione. È in corso l'esecuzione della prima.\n", "TaskSystem.active": "Al momento c'è già un'attività in esecuzione. Terminarla prima di eseguirne un'altra.", "TaskSystem.restartFailed": "Non è stato possibile terminare e riavviare l'attività {0}", "TaskSystem.configurationErrors": "Errore: la configurazione delle attività specificata contiene errori di convalida e non è utilizzabile. Correggere prima gli errori.", diff --git a/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json b/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json index f2c65d28fb8..3d9e3d5f42b 100644 --- a/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json @@ -6,5 +6,7 @@ { "TerminalTaskSystem.unknownError": "Si è verificato un errore sconosciuto durante l'esecuzione di un'attività. Per dettagli, vedere il log di output dell'attività.", "TerminalTaskSystem.terminalName": "Attività - {0}", - "TerminalTaskSystem": "Non è possibile eseguire un comando della shell su un'unità UNC." + "reuseTerminal": "Terminale verrà riutilizzato dalle attività, premere un tasto qualsiasi per chiuderlo.", + "TerminalTaskSystem": "Non è possibile eseguire un comando della shell su un'unità UNC.", + "unkownProblemMatcher": "Il matcher problemi {0} non può essere risolto. il matcher verrà ignorato" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json b/i18n/ita/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json index 7f632a45eea..fe3fa63dc3b 100644 --- a/i18n/ita/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json @@ -7,5 +7,6 @@ "TaskRunnerSystem.unknownError": "Si è verificato un errore sconosciuto durante l'esecuzione di un'attività. Per dettagli, vedere il log di output dell'attività.", "TaskRunnerSystem.watchingBuildTaskFinished": "\nIl controllo delle attività di build è terminato.", "TaskRunnerSystem.childProcessError": "Failed to launch external program {0} {1}.", - "TaskRunnerSystem.cancelRequested": "\nL'attività '{0}' è stata terminata come richiesto dall'utente." + "TaskRunnerSystem.cancelRequested": "\nL'attività '{0}' è stata terminata come richiesto dall'utente.", + "unkownProblemMatcher": "Il matcher problemi {0} non può essere risolto. Il matcher verrà ignorato" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json b/i18n/ita/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json index 7df189ea6a7..a7393d354c7 100644 --- a/i18n/ita/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json @@ -8,6 +8,7 @@ "workbench.action.terminal.kill": "Termina istanza attiva del terminale", "workbench.action.terminal.kill.short": "Termina il terminale", "workbench.action.terminal.copySelection": "Copia selezione", + "workbench.action.terminal.selectAll": "Seleziona tutto", "workbench.action.terminal.new": "Crea nuovo terminale integrato", "workbench.action.terminal.new.short": "Nuovo terminale", "workbench.action.terminal.focus": "Sposta stato attivo su terminale", @@ -26,5 +27,8 @@ "workbench.action.terminal.scrollUp": "Scorri su (riga)", "workbench.action.terminal.scrollUpPage": "Scorri su (pagina)", "workbench.action.terminal.scrollToTop": "Scorri all'inizio", - "workbench.action.terminal.clear": "Cancella" + "workbench.action.terminal.clear": "Cancella", + "workbench.action.terminal.allowWorkspaceShell": "Consente la configurazione della Shell dell'area di lavoro", + "workbench.action.terminal.disallowWorkspaceShell": "Non consente la configurazione della Shell dell'area di lavoro", + "workbench.action.terminal.rename": "Rinomina" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json b/i18n/ita/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json index c56209ab67f..43f3afaeb30 100644 --- a/i18n/ita/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json @@ -4,5 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "terminal.background": "Il colore di sfondo del terminale, questo consente di colorare il terminale in modo diverso dal pannello.", + "terminal.foreground": "Il colore di primo piano del terminale.", "terminal.ansiColor": "Colore ANSI '{0}' nel terminale." } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json b/i18n/ita/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json new file mode 100644 index 00000000000..a930fde7ffb --- /dev/null +++ b/i18n/ita/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "label.find": "Trova", + "placeholder.find": "Trova", + "label.previousMatchButton": "Risultato precedente", + "label.nextMatchButton": "Risultato successivo", + "label.closeButton": "Chiudi" +} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json b/i18n/ita/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json index 919a2c26d3b..713819e1226 100644 --- a/i18n/ita/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json @@ -4,7 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "terminal.integrated.copySelection.noSelection": "Non è possibile copiare la selezione del terminale quando questo non ha lo stato attivo", "terminal.integrated.exitedWithCode": "Il processo del terminale è stato terminato. Codice di uscita: {0}", "terminal.integrated.waitOnExit": "Premere un tasto qualsiasi per chiudere il terminale", "terminal.integrated.launchFailed": "L'avvio del comando del processo di terminale `{0}{1}` non è riuscito. Codice di uscita: {2}" diff --git a/i18n/ita/src/vs/workbench/parts/update/electron-browser/update.i18n.json b/i18n/ita/src/vs/workbench/parts/update/electron-browser/update.i18n.json index ddd31ed976d..fdac59727b7 100644 --- a/i18n/ita/src/vs/workbench/parts/update/electron-browser/update.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/update/electron-browser/update.i18n.json @@ -15,5 +15,18 @@ "license": "Leggi licenza", "updateAvailable": "{0} verrà aggiornato dopo il riavvio.", "thereIsUpdateAvailable": "È disponibile un aggiornamento.", - "noUpdatesAvailable": "Al momento non sono disponibili aggiornamenti." + "noUpdatesAvailable": "Al momento non sono disponibili aggiornamenti.", + "updateIsReady": "Nuovo aggiornamento disponibile.", + "commandPalette": "Riquadro comandi...", + "settings": "Impostazioni", + "keyboardShortcuts": "Scelte rapide da tastiera", + "selectTheme.label": "Tema colori", + "themes.selectIconTheme.label": "Tema icona file", + "not available": "Aggiornamenti non disponibili", + "checkingForUpdates": "Verifica della disponibilità di aggiornamenti...", + "DownloadUpdate": "Scarica l'aggiornamento disponibile", + "DownloadingUpdate": "Download dell'aggiornamento...", + "InstallingUpdate": "Installazione dell'aggiornamento...", + "restartToUpdate": "Riavvia per aggiornare...", + "checkForUpdates": "Verifica disponibilità aggiornamenti..." } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/views/browser/views.i18n.json b/i18n/ita/src/vs/workbench/parts/views/browser/views.i18n.json new file mode 100644 index 00000000000..a7b1c661726 --- /dev/null +++ b/i18n/ita/src/vs/workbench/parts/views/browser/views.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "viewToolbarAriaLabel": "Azioni di {0}" +} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json b/i18n/ita/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json new file mode 100644 index 00000000000..c5e18fdd63c --- /dev/null +++ b/i18n/ita/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "requirearray": "Visualizzazioni devono essere una matrice", + "requirestring": "la proprietà `{0}` è obbligatoria e deve essere di tipo `string`", + "optstring": "la proprietà `{0}` può essere omessa o deve essere di tipo `string`", + "vscode.extension.contributes.view.id": "Identificatore della vista. Utilizzare questo per registrare un provider di dati tramite l'API 'vscode.window.registerTreeDataProviderForView'. Anche per innescare l'attivazione dell'estensione tramite la registrazione dell'evento 'onView: ${id}' a 'activationEvents'.", + "vscode.extension.contributes.view.name": "Il nome della visualizzazione. Verrà mostrato", + "vscode.extension.contributes.views": "Contribuisce visualizzazioni all'editor", + "views.explorer": "Visualizzazione di esplorazione", + "locationId.invalid": "'{0}' non è una posizione valida per la visualizzazione" +} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/ita/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json index aa2a81f6197..c3e2a0322fe 100644 --- a/i18n/ita/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -11,20 +11,26 @@ "welcomePage.openFolder": "Apri cartella...", "welcomePage.cloneGitRepository": "Clona repository GIT...", "welcomePage.recent": "Recenti", + "welcomePage.moreRecent": "Altro...", "welcomePage.noRecentFolders": "Non ci sono cartelle recenti", "welcomePage.help": "Guida", + "welcomePage.keybindingsCheatsheet": "Bigino combinazione tasti stampabile", "welcomePage.introductoryVideos": "Video introduttivi", "welcomePage.productDocumentation": "Documentazione del prodotto", "welcomePage.gitHubRepository": "Repository GitHub", "welcomePage.stackOverflow": "Stack Overflow", "welcomePage.showOnStartup": "Mostra la pagina iniziale all'avvio", "welcomePage.customize": "Personalizza", + "welcomePage.installExtensionPacks": "Strumenti e linguaggi", + "welcomePage.installExtensionPacksDescription": "Installare il supporto per {0} e {1}", + "welcomePage.moreExtensions": "altro", "welcomePage.installKeymapDescription": "Installa i tasti di scelta rapida", + "welcomePage.installKeymapExtension": "Installa i tasti di scelta rapida di {0} e {1}", "welcomePage.others": "altri", "welcomePage.colorTheme": "Tema colori", "welcomePage.colorThemeDescription": "Tutto quel che serve per configurare editor e codice nel modo desiderato", + "welcomePage.learn": "Impara", "welcomePage.showCommands": "Trova ed esegui tutti i comandi", - "welcomePage.showCommandsDescription": "Accesso e ricerca rapida di comandi dal pannello di controllo ({0})", "welcomePage.interfaceOverview": "Panoramica dell'interfaccia", "welcomePage.interfaceOverviewDescription": "Immagine in sovrimpressione che evidenzia i principali componenti dell'interfaccia utente", "welcomePage.interactivePlayground": "Playground interattivo", diff --git a/i18n/ita/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json b/i18n/ita/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json index 20dd0cb2b01..915868bb161 100644 --- a/i18n/ita/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json @@ -4,7 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "workbenchConfigurationTitle": "Area di lavoro", - "welcomePage.enabled": "Se è abilitata, visualizzerà la pagina Benvenuti all'avvio.", "help": "Guida" } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/ita/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 01f19048853..d5b9daf3103 100644 --- a/i18n/ita/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -4,17 +4,35 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "workbenchConfigurationTitle": "Area di lavoro", + "welcomePage.enabled": "Se è abilitata, visualizzerà la pagina Benvenuti all'avvio.", "welcomePage": "Benvenuti", + "welcomePage.javaScript": "JavaScript", "welcomePage.typeScript": "TypeScript", + "welcomePage.python": "Python", "welcomePage.php": "PHP", + "welcomePage.docker": "Docker", "welcomePage.vim": "Vim", "welcomePage.sublime": "Sublime", "welcomePage.atom": "Atom", + "welcomePage.extensionPackAlreadyInstalled": "Il supporto per {0} è già installato.", + "welcomePage.willReloadAfterInstallingExtensionPack": "La finestra verrà ricaricata dopo l'installazione di supporto aggiuntivo per {0}.", + "welcomePage.installingExtensionPack": "Installazione di supporto aggiuntivo per {0} in corso...", + "welcomePage.extensionPackNotFound": "Il supporto per {0} con ID {1} non è stato trovato.", "welcomePage.keymapAlreadyInstalled": "I tasti di scelta rapida di {0} sono già installati.", "welcomePage.willReloadAfterInstallingKeymap": "La finestra verrà ricaricata dopo l'installazione dei tasti di scelta rapida di {0}.", "welcomePage.installingKeymap": "Installazione dei tasti di scelta rapida di {0}...", "welcomePage.keymapNotFound": "I tasti di scelta rapida di {0} con ID {1} non sono stati trovati.", "welcome.title": "Benvenuti", + "welcomePage.openFolderWithPath": "Apri la cartella {0} con percorso {1}", + "welcomePage.extensionListSeparator": ",", + "welcomePage.installKeymap": "Installa mappatura tastiera {0}", + "welcomePage.installExtensionPack": "Installa supporto aggiuntivo per {0}", + "welcomePage.installedKeymap": "Mappatura tastiera {0} è già installata", + "welcomePage.installedExtensionPack": "Il supporto {0} è già installato", "ok": "OK", - "cancel": "Annulla" + "details": "Dettagli", + "cancel": "Annulla", + "welcomePage.buttonBackground": "Colore di sfondo dei pulsanti nella pagina di benvenuto.", + "welcomePage.buttonHoverBackground": "Colore di sfondo al passaggio del mouse dei pulsanti nella pagina di benvenuto." } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json b/i18n/ita/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json index e40df93be8d..1ee1f44cc1d 100644 --- a/i18n/ita/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json +++ b/i18n/ita/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json @@ -5,5 +5,6 @@ // Do not edit this file. It is machine generated. { "walkThrough.unboundCommand": "non associato", - "walkThrough.gitNotFound": "Sembra che GIT non sia installato nel sistema." + "walkThrough.gitNotFound": "Sembra che GIT non sia installato nel sistema.", + "walkThrough.embeddedEditorBackground": "Colore di sfondo degli editor incorporati nel playground interattivo." } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json b/i18n/ita/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json index 2c3dacb4148..4566b1bcc6f 100644 --- a/i18n/ita/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json +++ b/i18n/ita/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json @@ -12,5 +12,6 @@ "errorNoWorkspaceOpened": "Impossibile scrivere nelle impostazioni perché nessuna cartella è aperta. Si prega di aprire una cartella e riprovare.", "errorInvalidConfiguration": "Impossibile scrivere nelle impostazioni. Si prega di aprire **Impostazioni utente** per correggere eventuali errori o avvisi nel file e riprovare.", "errorInvalidConfigurationWorkspace": "Impossibile scrivere in impostazioni. Si prega di aprire **Impostazioni area di lavoro** per correggere eventuali errori o avvisi nel file e riprovare.", - "errorConfigurationFileDirty": "Impossibile scrivere nelle impostazioni perché il file è stato modificato ma non salvato. Si prega di salvare il file **impostazioni utente** e riprovare." + "errorConfigurationFileDirty": "Impossibile scrivere nelle impostazioni perché il file è stato modificato ma non salvato. Si prega di salvare il file **impostazioni utente** e riprovare.", + "errorConfigurationFileDirtyWorkspace": "Non è possibile scrivere in impostazioni perché il file è stato modificato ma non salvato. Salvare il file delle **Impostazioni area di lavoro** e riprovare." } \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json b/i18n/ita/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json new file mode 100644 index 00000000000..f3982be9f88 --- /dev/null +++ b/i18n/ita/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "telemetryConfigurationTitle": "Telemetria", + "telemetry.enableCrashReporting": "Consente l'invio di segnalazioni di arresto anomalo del sistema a Microsoft.\nPer rendere effettiva questa opzione, è necessario riavviare." +} \ No newline at end of file diff --git a/i18n/ita/src/vs/workbench/services/progress/browser/progressService2.i18n.json b/i18n/ita/src/vs/workbench/services/progress/browser/progressService2.i18n.json new file mode 100644 index 00000000000..6db7d6aae51 --- /dev/null +++ b/i18n/ita/src/vs/workbench/services/progress/browser/progressService2.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "progress.text": "{0} - {1}", + "progress.title": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/jpn/extensions/git/package.i18n.json b/i18n/jpn/extensions/git/package.i18n.json index 1c27e31a01c..f71d3d2ced6 100644 --- a/i18n/jpn/extensions/git/package.i18n.json +++ b/i18n/jpn/extensions/git/package.i18n.json @@ -32,7 +32,7 @@ "command.push": "プッシュ", "command.pushTo": "プッシュ先...", "command.sync": "åŒæœŸ", - "command.publish": "公開", + "command.publish": "ブランãƒã®ç™ºè¡Œ", "command.showOutput": "Git 出力ã®è¡¨ç¤º", "config.enabled": "Git ãŒæœ‰åŠ¹ã«ãªã£ã¦ã„ã‚‹ã‹ã©ã†ã‹", "config.path": "Git 実行å¯èƒ½ãƒ•ã‚¡ã‚¤ãƒ«ã®ãƒ‘ス", diff --git a/i18n/jpn/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/jpn/extensions/merge-conflict/out/codelensProvider.i18n.json index 8b6ad71cd4e..e4f0ccc6045 100644 --- a/i18n/jpn/extensions/merge-conflict/out/codelensProvider.i18n.json +++ b/i18n/jpn/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -3,4 +3,9 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "acceptCurrentChange": "ç¾åœ¨ã®å¤‰æ›´ã‚’å–り込む", + "acceptIncomingChange": "入力å´ã®å¤‰æ›´ã‚’å–り込む", + "acceptBothChanges": "両方ã®å¤‰æ›´ã‚’å–り込む", + "compareChanges": "変更ã®æ¯”較" +} \ No newline at end of file diff --git a/i18n/jpn/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/jpn/extensions/merge-conflict/out/commandHandler.i18n.json index d435e6965b3..aa976005ee9 100644 --- a/i18n/jpn/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/jpn/extensions/merge-conflict/out/commandHandler.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "cursorNotInConflict": "エディターã®ã‚«ãƒ¼ã‚½ãƒ«ãŒãƒžãƒ¼ã‚¸ã®ç«¶åˆã®ç¯„囲内ã«ã‚ã‚Šã¾ã›ã‚“", + "compareChangesTitle": "{0}: ç¾åœ¨ã®å¤‰æ›´ ⟷ 入力å´ã®å¤‰æ›´", "cursorOnSplitterRange": "エディターã®ã‚«ãƒ¼ã‚½ãƒ«ãŒãƒžãƒ¼ã‚¸ コンフリクトã®ã‚¹ãƒ—リッター内ã«ã‚ã‚Šã¾ã™ã€‚â€ç¾åœ¨â€ ã¾ãŸã¯ \"入力å´\" ã®ã„ãšã‚Œã‹ã®ãƒ–ロックã«ç§»å‹•ã—ã¦ãã ã•ã„", "noConflicts": "ã“ã®ãƒ•ã‚¡ã‚¤ãƒ«ã«ãƒžãƒ¼ã‚¸ã®ç«¶åˆã¯å­˜åœ¨ã—ã¾ã›ã‚“", "noOtherConflictsInThisFile": "ã“ã®ãƒ•ã‚¡ã‚¤ãƒ«ã«ä»–ã®ãƒžãƒ¼ã‚¸ã®ç«¶åˆã¯å­˜åœ¨ã—ã¾ã›ã‚“" diff --git a/i18n/jpn/extensions/merge-conflict/package.i18n.json b/i18n/jpn/extensions/merge-conflict/package.i18n.json index e2adf262063..3a6930d38af 100644 --- a/i18n/jpn/extensions/merge-conflict/package.i18n.json +++ b/i18n/jpn/extensions/merge-conflict/package.i18n.json @@ -5,7 +5,15 @@ // Do not edit this file. It is machine generated. { "command.category": "マージã®ç«¶åˆ", + "command.accept.all-incoming": "入力å´ã®ã™ã¹ã¦ã‚’å–り込む", + "command.accept.all-both": "両方をã™ã¹ã¦å–り込む", + "command.accept.current": "ç¾åœ¨ã®æ–¹ã‚’å–り込む", + "command.accept.incoming": "入力å´ã‚’å–り込む", + "command.accept.selection": "é¸æŠžé …目をå–り込む", "command.accept.both": "両方をå–り込む", + "command.next": "次ã®ç«¶åˆ", + "command.previous": "å‰ã®ç«¶åˆ", + "command.compare": "ç¾åœ¨ã®ç«¶åˆã‚’比較", "config.title": "マージã®ç«¶åˆ", "config.codeLensEnabled": "エディター内ã®ãƒžãƒ¼ã‚¸ç«¶åˆãƒ–ロック㧠CodeLens を有効/無効ã«ã—ã¾ã™", "config.decoratorsEnabled": "エディター内ã§ãƒžãƒ¼ã‚¸ã®ç«¶åˆãƒ‡ã‚³ãƒ¬ãƒ¼ã‚¿ãƒ¼ã‚’有効/無効ã«ã—ã¾ã™ã€‚" diff --git a/i18n/jpn/extensions/typescript/out/features/bufferSyncSupport.i18n.json b/i18n/jpn/extensions/typescript/out/features/bufferSyncSupport.i18n.json index 01e33938ce2..4df0b825c76 100644 --- a/i18n/jpn/extensions/typescript/out/features/bufferSyncSupport.i18n.json +++ b/i18n/jpn/extensions/typescript/out/features/bufferSyncSupport.i18n.json @@ -4,7 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "versionMismatch": "グローãƒãƒ«ãª tsc ({0}) 㨠VS Code ã®è¨€èªžã‚µãƒ¼ãƒ“ス ({1}) ã®é–“ã«ãƒãƒ¼ã‚¸ãƒ§ãƒ³ã®ä¸ä¸€è‡´ãŒã‚ã‚Šã¾ã™ã€‚éžæ•´åˆã®ã‚³ãƒ³ãƒ‘イル エラーを引ãèµ·ã“ã™å¯èƒ½æ€§ãŒã‚ã‚Šã¾ã™", "moreInformation": "詳細情報", "doNotCheckAgain": "今後確èªã—ãªã„", "close": "é–‰ã˜ã‚‹", diff --git a/i18n/jpn/extensions/typescript/out/utils/projectStatus.i18n.json b/i18n/jpn/extensions/typescript/out/utils/projectStatus.i18n.json index 2b687b8f1c5..9cd627a0d90 100644 --- a/i18n/jpn/extensions/typescript/out/utils/projectStatus.i18n.json +++ b/i18n/jpn/extensions/typescript/out/utils/projectStatus.i18n.json @@ -6,7 +6,6 @@ { "hintExclude": "プロジェクト全体㮠JavaScript/TypeScript 言語機能を有効ã«ã™ã‚‹ã«ã¯ã€å¤šæ•°ã®ãƒ•ã‚¡ã‚¤ãƒ«ãŒå«ã¾ã‚Œã‚‹ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã‚’除外ã—ã¾ã™ã€‚例: {0}", "hintExclude.generic": "プロジェクト全体㮠JavaScript/TypeScript 言語機能を有効ã«ã™ã‚‹ã«ã¯ã€ä½œæ¥­ã—ã¦ã„ãªã„ソース ファイルãŒå«ã¾ã‚Œã‚‹ã‚µã‚¤ã‚ºã®å¤§ããªãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã‚’除外ã—ã¾ã™ã€‚", - "open": "除外ã®æ§‹æˆ", "large.label": "除外ã®æ§‹æˆ", "hintExclude.tooltip": "プロジェクト全体㮠JavaScript/TypeScript 言語機能を有効ã«ã™ã‚‹ã«ã¯ã€ä½œæ¥­ã—ã¦ã„ãªã„ソース ファイルãŒå«ã¾ã‚Œã‚‹ã‚µã‚¤ã‚ºã®å¤§ããªãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã‚’除外ã—ã¾ã™ã€‚" } \ No newline at end of file diff --git a/i18n/jpn/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/jpn/extensions/typescript/out/utils/typingsStatus.i18n.json index 3a40c2e29d9..1f1eb703bd6 100644 --- a/i18n/jpn/extensions/typescript/out/utils/typingsStatus.i18n.json +++ b/i18n/jpn/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "installingPackages": "よりé©ã—㟠TypeScript IntelliSense ã«é–¢ã™ã‚‹ãƒ‡ãƒ¼ã‚¿ã‚’フェッãƒã—ã¦ã„ã¾ã™", + "typesInstallerInitializationFailed.title": "JavaScript 言語機能ã®ãŸã‚ã®åž‹å®šç¾©ãƒ•ã‚¡ã‚¤ãƒ«ã‚’インストールã§ãã¾ã›ã‚“ã§ã—ãŸã€‚NPM ã®ã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã‚’確èªã™ã‚‹ã‹ã€ãƒ¦ãƒ¼ã‚¶ãƒ¼è¨­å®šã§ 'typescript.npm' を構æˆã—ã¦ãã ã•ã„", "typesInstallerInitializationFailed.moreInformation": "詳細情報", "typesInstallerInitializationFailed.doNotCheckAgain": "今後確èªã—ãªã„", "typesInstallerInitializationFailed.close": "é–‰ã˜ã‚‹" diff --git a/i18n/jpn/extensions/typescript/package.i18n.json b/i18n/jpn/extensions/typescript/package.i18n.json index 9f60798218f..dcf8478a4d6 100644 --- a/i18n/jpn/extensions/typescript/package.i18n.json +++ b/i18n/jpn/extensions/typescript/package.i18n.json @@ -13,7 +13,6 @@ "typescript.check.tscVersion": "グローãƒãƒ« インストール TypeScript コンパイラ (tsc ãªã©) ãŒã€ä½¿ç”¨ã•ã‚ŒãŸ TypeScript 言語サービスã¨ç•°ãªã£ã¦ã„ã‚‹ã‹ã©ã†ã‹ã‚’確èªã—ã¾ã™ã€‚", "typescript.tsserver.log": "ファイルã¸ã® TS サーãƒãƒ¼ã®ãƒ­ã‚°ã‚’有効ã«ã—ã¾ã™ã€‚ã“ã®ãƒ­ã‚°ã¯ TS サーãƒãƒ¼ã®å•é¡Œã‚’診断ã™ã‚‹ãŸã‚ã«ä½¿ç”¨ã§ãã¾ã™ã€‚ログã«ã¯ã€ãƒ—ロジェクトã®ãƒ•ã‚¡ã‚¤ãƒ«ãƒ‘スã€ã‚½ãƒ¼ã‚¹ã‚³ãƒ¼ãƒ‰ã€ãã®ä»–ã®æ½œåœ¨çš„ã«æ©Ÿå¯†æ€§ã®é«˜ã„情報ãŒå«ã¾ã‚Œã¦ã„ã‚‹å ´åˆãŒã‚ã‚Šã¾ã™ã€‚", "typescript.tsserver.trace": "TS サーãƒãƒ¼ã«é€ä¿¡ã•ã‚Œã‚‹ãƒ¡ãƒƒã‚»ãƒ¼ã‚¸ã®ãƒˆãƒ¬ãƒ¼ã‚¹ã‚’有効ã«ã—ã¾ã™ã€‚ã“ã®ãƒˆãƒ¬ãƒ¼ã‚¹ã¯ TS サーãƒãƒ¼ã®å•é¡Œã‚’診断ã™ã‚‹ãŸã‚ã«ä½¿ç”¨ã§ãã¾ã™ã€‚トレースã«ã¯ã€ãƒ—ロジェクトã®ãƒ•ã‚¡ã‚¤ãƒ«ãƒ‘スã€ã‚½ãƒ¼ã‚¹ã‚³ãƒ¼ãƒ‰ã€ãã®ä»–ã®æ½œåœ¨çš„ã«æ©Ÿå¯†æ€§ã®é«˜ã„情報ãŒå«ã¾ã‚Œã¦ã„ã‚‹å ´åˆãŒã‚ã‚Šã¾ã™ã€‚", - "typescript.tsserver.experimentalAutoBuild": "試験的ãªè‡ªå‹•ãƒ“ルドを有効ã«ã—ã¾ã™ã€‚1.9 dev ã¾ãŸã¯ 2.x tsserver ãƒãƒ¼ã‚¸ãƒ§ãƒ³ã¨ã€å¤‰æ›´å¾Œã« VS Code ã®å†èµ·å‹•ãŒå¿…è¦ã§ã™ã€‚", "typescript.validate.enable": "TypeScript ã®æ¤œè¨¼ã‚’有効/無効ã«ã—ã¾ã™ã€‚", "typescript.format.enable": "既定㮠TypeScript フォーマッタを有効/無効ã«ã—ã¾ã™ã€‚", "javascript.format.enable": "既定㮠JavaScript フォーマッタを有効/無効ã«ã—ã¾ã™ã€‚", @@ -41,6 +40,8 @@ "typescript.selectTypeScriptVersion.title": "TypeScript ã®ãƒãƒ¼ã‚¸ãƒ§ãƒ³ã®é¸æŠž", "jsDocCompletion.enabled": " 自動 JSDoc コメントを有効/無効ã«ã—ã¾ã™", "javascript.implicitProjectConfig.checkJs": "JavaScript ファイルã®ã‚»ãƒžãƒ³ãƒ†ã‚£ãƒƒã‚¯ ãƒã‚§ãƒƒã‚¯ã‚’有効/無効ã«ã—ã¾ã™ã€‚既存㮠jsconfi.json ã‚„ tsconfi.json ファイルã®è¨­å®šã¯ã“れより優先ã•ã‚Œã¾ã™ã€‚TypeScript 㯠2.3.1 以上ã§ã‚ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™ã€‚", + "typescript.npm": "型定義ã®è‡ªå‹•å–å¾—ã«ä½¿ç”¨ã•ã‚Œã‚‹ NPM 実行å¯èƒ½ãƒ•ã‚¡ã‚¤ãƒ«ã¸ã®ãƒ‘スを指定ã—ã¾ã™ã€‚TypeScript 2.3.4 以上ãŒå¿…è¦ã§ã™ã€‚", + "typescript.check.npmIsInstalled": "型定義ã®è‡ªå‹•å–å¾—ã« NPM ãŒã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã¦ã„ã‚‹ã‹ã©ã†ã‹ã‚’確èªã—ã¾ã™ã€‚", "javascript.nameSuggestions": "JavaScript ã®å€™è£œãƒªã‚¹ãƒˆå†…ã§ãƒ•ã‚¡ã‚¤ãƒ«ã‹ã‚‰ä¸€æ„ã®åå‰ã‚’å«ã‚€ã‹ã©ã†ã‹ã‚’有効/無効ã«ã—ã¾ã™ã€‚", "typescript.tsc.autoDetect": "tsc タスクã®è‡ªå‹•æ¤œå‡ºã‚’オンã«ã™ã‚‹ã‹ã‚ªãƒ•ã«ã™ã‚‹ã‹ã‚’制御ã—ã¾ã™ã€‚" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/jpn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index 15d556bd644..d00ceb129a0 100644 --- a/i18n/jpn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/jpn/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -5,7 +5,7 @@ // Do not edit this file. It is machine generated. { "imgMeta": "{0}x{1} {2}", - "largeImageError": "イメージãŒå¤§ãã™ãŽã¦ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã«è¡¨ç¤ºã§ãã¾ã›ã‚“。", + "largeImageError": "ç”»åƒãŒéžå¸¸ã«å¤§ãã„ãŸã‚ã€ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã«è¡¨ç¤ºã•ã‚Œã¾ã›ã‚“。 ", "resourceOpenExternalButton": "外部ã®ãƒ—ログラムを使用ã—ã¦ç”»åƒã‚’é–‹ãã¾ã™ã‹?", "nativeBinaryError": "ã“ã®ãƒ•ã‚¡ã‚¤ãƒ«ã¯ãƒã‚¤ãƒŠãƒªã‹ã€éžå¸¸ã«å¤§ãã„ã‹ã€ã¾ãŸã¯ã‚µãƒãƒ¼ãƒˆã•ã‚Œã¦ã„ãªã„テキスト エンコードを使用ã—ã¦ã„ã‚‹ãŸã‚ã€ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã«è¡¨ç¤ºã•ã‚Œã¾ã›ã‚“。", "sizeB": "{0}B", diff --git a/i18n/jpn/src/vs/base/common/errorMessage.i18n.json b/i18n/jpn/src/vs/base/common/errorMessage.i18n.json index d233c445822..43574f420b2 100644 --- a/i18n/jpn/src/vs/base/common/errorMessage.i18n.json +++ b/i18n/jpn/src/vs/base/common/errorMessage.i18n.json @@ -13,6 +13,5 @@ "error.connection.unknown": "ä¸æ˜ŽãªæŽ¥ç¶šã‚¨ãƒ©ãƒ¼ãŒç™ºç”Ÿã—ã¾ã—ãŸã€‚インターãƒãƒƒãƒˆæŽ¥ç¶šãŒåˆ‡ã‚ŒãŸã‹ã€æŽ¥ç¶šå…ˆã®ã‚µãƒ¼ãƒãƒ¼ãŒã‚ªãƒ•ãƒ©ã‚¤ãƒ³ã§ã™ã€‚", "stackTrace.format": "{0}: {1}", "error.defaultMessage": "ä¸æ˜Žãªã‚¨ãƒ©ãƒ¼ãŒç™ºç”Ÿã—ã¾ã—ãŸã€‚ログã§è©³ç´°ã‚’確èªã—ã¦ãã ã•ã„。", - "nodeExceptionMessage": "システム エラーãŒç™ºç”Ÿã—ã¾ã—㟠({0})", "error.moreErrors": "{0} (åˆè¨ˆ {1} エラー)" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/base/common/keybindingLabels.i18n.json b/i18n/jpn/src/vs/base/common/keybindingLabels.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/jpn/src/vs/base/common/keybindingLabels.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/jpn/src/vs/code/electron-main/menus.i18n.json b/i18n/jpn/src/vs/code/electron-main/menus.i18n.json index 541c16a930c..fb8e314eb0c 100644 --- a/i18n/jpn/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/jpn/src/vs/code/electron-main/menus.i18n.json @@ -133,11 +133,11 @@ "miColumnBreakpoint": "列ã®ãƒ–レークãƒã‚¤ãƒ³ãƒˆ(&&O)", "miFunctionBreakpoint": "関数ã®ãƒ–レークãƒã‚¤ãƒ³ãƒˆ(&&F)...", "miNewBreakpoint": "æ–°ã—ã„ブレークãƒã‚¤ãƒ³ãƒˆ(&&N)", + "miEnableAllBreakpoints": "ã™ã¹ã¦ã®ãƒ–レークãƒã‚¤ãƒ³ãƒˆã‚’有効ã«ã™ã‚‹", "miDisableAllBreakpoints": "ã™ã¹ã¦ã®ãƒ–レークãƒã‚¤ãƒ³ãƒˆã‚’無効ã«ã™ã‚‹(&&L)", "miRemoveAllBreakpoints": "ã™ã¹ã¦ã®ãƒ–レークãƒã‚¤ãƒ³ãƒˆã‚’削除ã™ã‚‹(&&R)", "miInstallAdditionalDebuggers": "ãã®ä»–ã®ãƒ‡ãƒãƒƒã‚¬ãƒ¼ã‚’インストールã—ã¾ã™(&&I)...", "mMinimize": "最å°åŒ–", - "mClose": "é–‰ã˜ã‚‹", "mBringToFront": "ã™ã¹ã¦ã‚’å‰é¢ã«é…ç½®", "miToggleDevTools": "開発者ツールã®åˆ‡ã‚Šæ›¿ãˆ(&&T)", "miAccessibilityOptions": "ユーザー補助オプション(&&O)", @@ -153,12 +153,14 @@ "miLicense": "ライセンスã®è¡¨ç¤º(&&L)", "miPrivacyStatement": "プライãƒã‚·ãƒ¼ã«ã¤ã„ã¦(&&P)", "miAbout": "ãƒãƒ¼ã‚¸ãƒ§ãƒ³æƒ…å ±(&&A)", + "miTerminateTask": "タスクã®çµ‚了(&&T)", "accessibilityOptionsWindowTitle": "ユーザー補助オプション", "miRestartToUpdate": "æ›´æ–°ã®ãŸã‚ã«å†èµ·å‹•ã—ã¾ã™...", "miCheckingForUpdates": "更新を確èªã—ã¦ã„ã¾ã™...", "miDownloadUpdate": "利用å¯èƒ½ãªæ›´æ–°ãƒ—ログラムをダウンロードã—ã¾ã™", "miDownloadingUpdate": "更新をダウンロードã—ã¦ã„ã¾ã™...", "miInstallingUpdate": "更新プログラムをインストールã—ã¦ã„ã¾ã™...", + "miCheckForUpdates": "æ›´æ–°ã®ç¢ºèª...", "aboutDetail": "\nãƒãƒ¼ã‚¸ãƒ§ãƒ³{0}\nコミット{1}\n日付{2}\nシェル{3}\nレンダラー{4}\nNode {5}", "okButton": "OK" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/code/electron-main/windows.i18n.json b/i18n/jpn/src/vs/code/electron-main/windows.i18n.json index 6631797b5a4..6a230da6588 100644 --- a/i18n/jpn/src/vs/code/electron-main/windows.i18n.json +++ b/i18n/jpn/src/vs/code/electron-main/windows.i18n.json @@ -13,9 +13,5 @@ "appStalled": "ウィンドウã‹ã‚‰å¿œç­”ãŒã‚ã‚Šã¾ã›ã‚“", "appStalledDetail": "ウィンドウをå†åº¦é–‹ãã‹ã€é–‰ã˜ã‚‹ã‹ã€ã“ã®ã¾ã¾å¾…æ©Ÿã§ãã¾ã™ã€‚", "appCrashed": "ウィンドウãŒã‚¯ãƒ©ãƒƒã‚·ãƒ¥ã—ã¾ã—ãŸ", - "appCrashedDetail": "ã”ä¸ä¾¿ã‚’ãŠã‹ã‘ã—ã¦ç”³ã—訳ã‚ã‚Šã¾ã›ã‚“。ウィンドウをå†åº¦é–‹ã„ã¦ã€ä¸­æ–­ã—ãŸã¨ã“ã‚ã‹ã‚‰ç¶šè¡Œã§ãã¾ã™ã€‚", - "newWindow": "æ–°ã—ã„ウィンドウ", - "newWindowDesc": "æ–°ã—ã„ウィンドウを開ã", - "recentFolders": "最近使用ã—ãŸãƒ•ã‚©ãƒ«ãƒ€ãƒ¼", - "folderDesc": "{0} {1}" + "appCrashedDetail": "ã”ä¸ä¾¿ã‚’ãŠã‹ã‘ã—ã¦ç”³ã—訳ã‚ã‚Šã¾ã›ã‚“。ウィンドウをå†åº¦é–‹ã„ã¦ã€ä¸­æ–­ã—ãŸã¨ã“ã‚ã‹ã‚‰ç¶šè¡Œã§ãã¾ã™ã€‚" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/jpn/src/vs/editor/common/config/commonEditorConfig.i18n.json index 1fa006e9cb2..ffbae4db59c 100644 --- a/i18n/jpn/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/jpn/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -21,6 +21,7 @@ "roundedSelection": "é¸æŠžç¯„囲ã®è§’を丸ãã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™", "scrollBeyondLastLine": "エディターã§æœ€å¾Œã®è¡Œã‚’越ãˆã¦ã‚¹ã‚¯ãƒ­ãƒ¼ãƒ«ã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™", "minimap.enabled": "ミニマップを表示ã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™", + "minimap.showSlider": "ミニマップを自動的ã«éžè¡¨ç¤ºã«ã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ 。", "minimap.renderCharacters": "行㫠(カラー ブロックã§ã¯ãªã) 実際ã®æ–‡å­—を表示ã—ã¾ã™", "minimap.maxColumn": "表示ã™ã‚‹ãƒŸãƒ‹ãƒžãƒƒãƒ—ã®æœ€å¤§å¹…を特定ã®æ¡æ•°ã«åˆ¶é™ã—ã¾ã™", "find.seedSearchStringFromSelection": "エディターã®é¸æŠžã‹ã‚‰æ¤œç´¢ã‚¦ã‚£ã‚¸ã‚§ãƒƒãƒˆå†…ã®æ¤œç´¢æ–‡å­—列を与ãˆã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™", @@ -33,12 +34,14 @@ "wordWrapColumn": "'editor.wordWrap' ㌠'wordWrapColumn' ã¾ãŸã¯ 'bounded' ã®å ´åˆã«ã€ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã®æŠ˜ã‚Šè¿”ã—æ¡ã‚’制御ã—ã¾ã™ã€‚", "wrappingIndent": "折り返ã—è¡Œã®ã‚¤ãƒ³ãƒ‡ãƒ³ãƒˆã‚’制御ã—ã¾ã™ã€‚'none'ã€'same'ã€ã¾ãŸã¯ 'indent' ã®ã„ãšã‚Œã‹ã‚’指定ã§ãã¾ã™ã€‚", "mouseWheelScrollSensitivity": "マウス ホイール スクロール イベント㮠`deltaX` 㨠`deltaY` ã§ä½¿ç”¨ã•ã‚Œã‚‹ä¹—æ•°", + "multiCursorModifier.ctrlCmd": "Windows ãŠã‚ˆã³ Linux 上㮠`Control` 㨠OSX 上㮠`Command` ã«ãƒžãƒƒãƒ—ã—ã¾ã™ã€‚", + "multiCursorModifier.alt": "Windows ãŠã‚ˆã³ Linux 上㮠`Alt` 㨠OSX 上㮠`Option` ã«ãƒžãƒƒãƒ—ã—ã¾ã™ã€‚", + "multiCursorModifier": "マウスã§è¤‡æ•°ã®ã‚«ãƒ¼ã‚½ãƒ«ã‚’追加ã™ã‚‹ã¨ãã«ä½¿ç”¨ã™ã‚‹ä¿®é£¾ã‚­ãƒ¼ã§ã™ã€‚`ctrlCmd` 㯠Windows ãŠã‚ˆã³ Linux 上㮠`Control` キー㨠OSX 上㮠`Command` キーã«ãƒžãƒƒãƒ—ã—ã¾ã™ã€‚「定義ã«ç§»å‹•ã€ã‚„「リンクを開ãã€ã®ãƒžã‚¦ã‚¹æ“作ã¯ã€ãƒžãƒ«ãƒã‚«ãƒ¼ã‚½ãƒ«ã®ä¿®é£¾ã‚­ãƒ¼ã¨ç«¶åˆã—ãªã„よã†ã«é©ç”¨ã•ã‚Œã¾ã™ã€‚", "quickSuggestions.strings": "文字列内ã§ã‚¯ã‚¤ãƒƒã‚¯å€™è£œã‚’有効ã«ã—ã¾ã™ã€‚", "quickSuggestions.comments": "コメント内ã§ã‚¯ã‚¤ãƒƒã‚¯å€™è£œã‚’有効ã«ã—ã¾ã™ã€‚", "quickSuggestions.other": "文字列ãŠã‚ˆã³ã‚³ãƒ¡ãƒ³ãƒˆå¤–ã§ã‚¯ã‚¤ãƒƒã‚¯å€™è£œã‚’有効ã«ã—ã¾ã™ã€‚", "quickSuggestions": "入力中ã«å€™è£œã‚’自動的ã«è¡¨ç¤ºã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™", "quickSuggestionsDelay": "クイック候補ãŒè¡¨ç¤ºã•ã‚Œã‚‹ã¾ã§ã®å¾…ã¡æ™‚é–“ (ミリ秒) を制御ã—ã¾ã™", - "parameterHints": "パラメーター ヒントを有効ã«ã™ã‚‹", "autoClosingBrackets": "エディターã§å·¦è§’ã‹ã£ã“ã®å¾Œã«è‡ªå‹•çš„ã«å³è§’ã‹ã£ã“を挿入ã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™", "formatOnType": "エディターã§å…¥åŠ›å¾Œã«è‡ªå‹•çš„ã«è¡Œã®æ›¸å¼è¨­å®šã‚’è¡Œã†ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™", "formatOnPaste": "貼り付ã‘ãŸå†…容ãŒã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã«ã‚ˆã‚Šè‡ªå‹•çš„ã«ãƒ•ã‚©ãƒ¼ãƒžãƒƒãƒˆã•ã‚Œã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚フォーマッタを使用å¯èƒ½ã«ã™ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™ã€‚ã¾ãŸã€ãƒ•ã‚©ãƒ¼ãƒžãƒƒã‚¿ãŒãƒ‰ã‚­ãƒ¥ãƒ¡ãƒ³ãƒˆå†…ã®ç¯„囲をフォーマットã§ããªã‘ã‚Œã°ãªã‚Šã¾ã›ã‚“。", @@ -72,6 +75,10 @@ "trimAutoWhitespace": "自動挿入ã•ã‚ŒãŸæœ«å°¾ã®ç©ºç™½ã‚’削除ã™ã‚‹", "stablePeek": "エディターã®ã‚³ãƒ³ãƒ†ãƒ³ãƒ„をダブルクリックã™ã‚‹ã‹ã€Esc キーを押ã—ã¦ã‚‚ã€ãƒ”ーク エディターを開ã„ãŸã¾ã¾ã«ã—ã¾ã™ã€‚", "dragAndDrop": "ドラッグ アンド ドロップã«ã‚ˆã‚‹é¸æŠžç¯„囲ã®ç§»å‹•ã‚’エディターãŒè¨±å¯ã™ã‚‹å¿…è¦ãŒã‚ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚", + "accessibilitySupport.auto": "エディターã¯ã‚¹ã‚¯ãƒªãƒ¼ãƒ³ リーダーãŒã„ã¤æŽ¥ç¶šã•ã‚ŒãŸã‹ã‚’検出ã™ã‚‹ãŸã‚ã«ãƒ—ラットフォーム API を使用ã—ã¾ã™ã€‚", + "accessibilitySupport.on": "エディターã¯æ°¸ç¶šçš„ã«ã‚¹ã‚¯ãƒªãƒ¼ãƒ³ リーダーå‘ã‘ã«æœ€é©åŒ–ã•ã‚Œã¾ã™ã€‚", + "accessibilitySupport.off": "エディターã¯ã‚¹ã‚¯ãƒªãƒ¼ãƒ³ リーダーå‘ã‘ã«æœ€é©åŒ–ã•ã‚Œã¾ã›ã‚“。", + "accessibilitySupport": "エディターをスクリーン リーダーã«æœ€é©åŒ–ã•ã‚ŒãŸãƒ¢ãƒ¼ãƒ‰ã§å®Ÿè¡Œã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚", "sideBySide": "差分エディターãŒå·®åˆ†ã‚’横ã«ä¸¦ã¹ã¦è¡¨ç¤ºã™ã‚‹ã‹ã€è¡Œå†…ã«è¡¨ç¤ºã™ã‚‹ã‹ã‚’制御ã—ã¾ã™", "ignoreTrimWhitespace": "差分エディターãŒã€å…ˆé ­ã¾ãŸã¯æœ«å°¾ã®ç©ºç™½ã®å¤‰æ›´ã‚’差分ã¨ã—ã¦è¡¨ç¤ºã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚", "renderIndicators": "差分エディターãŒè¿½åŠ /削除ã•ã‚ŒãŸå¤‰æ›´ã« +/- インジケーターを示ã™ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™", diff --git a/i18n/jpn/src/vs/editor/common/config/editorOptions.i18n.json b/i18n/jpn/src/vs/editor/common/config/editorOptions.i18n.json index 3fdfb4e461b..be8d7821ab4 100644 --- a/i18n/jpn/src/vs/editor/common/config/editorOptions.i18n.json +++ b/i18n/jpn/src/vs/editor/common/config/editorOptions.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "accessibilityOffAriaLabel": "ç¾åœ¨ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã«ã‚¢ã‚¯ã‚»ã‚¹ã™ã‚‹ã“ã¨ã¯ã§ãã¾ã›ã‚“。 Alt + F1 キーを押ã—ã¦ã‚ªãƒ—ションをé¸æŠžã—ã¾ã™ã€‚", "editorViewAccessibleLabel": "エディターã®ã‚³ãƒ³ãƒ†ãƒ³ãƒ„" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/editor/contrib/find/common/findController.i18n.json b/i18n/jpn/src/vs/editor/contrib/find/common/findController.i18n.json index 873ccff036a..f949479f389 100644 --- a/i18n/jpn/src/vs/editor/contrib/find/common/findController.i18n.json +++ b/i18n/jpn/src/vs/editor/contrib/find/common/findController.i18n.json @@ -14,6 +14,5 @@ "addSelectionToPreviousFindMatch": "é¸ã‚“ã é …目をå‰ã®ä¸€è‡´é …ç›®ã«è¿½åŠ ã™ã‚‹", "moveSelectionToNextFindMatch": "最後ã«é¸æŠžã—ãŸé …目を次ã®ä¸€è‡´é …ç›®ã«ç§»å‹•", "moveSelectionToPreviousFindMatch": "最後ã«é¸ã‚“ã é …目をå‰ã®ä¸€è‡´é …ç›®ã«ç§»å‹•ã™ã‚‹", - "selectAllOccurencesOfFindMatch": "一致ã™ã‚‹ã™ã¹ã¦ã®å‡ºç¾ç®‡æ‰€ã‚’é¸æŠžã—ã¾ã™", "changeAll.label": "ã™ã¹ã¦ã®å‡ºç¾ç®‡æ‰€ã‚’変更" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/editor/contrib/format/browser/formatActions.i18n.json b/i18n/jpn/src/vs/editor/contrib/format/browser/formatActions.i18n.json index d1fd1741e74..6a613cb5b68 100644 --- a/i18n/jpn/src/vs/editor/contrib/format/browser/formatActions.i18n.json +++ b/i18n/jpn/src/vs/editor/contrib/format/browser/formatActions.i18n.json @@ -9,5 +9,5 @@ "hint1n": "Made 1 formatting edit between lines {0} and {1}", "hintnn": "Made {0} formatting edits between lines {1} and {2}", "formatDocument.label": "Format Document", - "formatSelection.label": "Format Selection" + "formatSelection.label": "é¸æŠžç¯„囲ã®ãƒ•ã‚©ãƒ¼ãƒžãƒƒãƒˆ" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json b/i18n/jpn/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json index 989d71f385b..4fbcbda9f94 100644 --- a/i18n/jpn/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json +++ b/i18n/jpn/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json @@ -8,5 +8,6 @@ "markerAction.next.label": "次ã®ã‚¨ãƒ©ãƒ¼ã¾ãŸã¯è­¦å‘Šã¸ç§»å‹•", "markerAction.previous.label": "å‰ã®ã‚¨ãƒ©ãƒ¼ã¾ãŸã¯è­¦å‘Šã¸ç§»å‹•", "editorMarkerNavigationError": "エディターã®ãƒžãƒ¼ã‚«ãƒ¼ ナビゲーション ウィジェットã®ã‚¨ãƒ©ãƒ¼ã®è‰²ã€‚", - "editorMarkerNavigationWarning": "エディターã®ãƒžãƒ¼ã‚«ãƒ¼ ナビゲーション ウィジェットã®è­¦å‘Šã®è‰²ã€‚" + "editorMarkerNavigationWarning": "エディターã®ãƒžãƒ¼ã‚«ãƒ¼ ナビゲーション ウィジェットã®è­¦å‘Šã®è‰²ã€‚", + "editorMarkerNavigationBackground": "エディターã®ãƒžãƒ¼ã‚«ãƒ¼ ナビゲーション ウィジェットã®èƒŒæ™¯ã€‚" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json b/i18n/jpn/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json index 0e09eb3904d..39b8edf5de2 100644 --- a/i18n/jpn/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json +++ b/i18n/jpn/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json @@ -5,8 +5,6 @@ // Do not edit this file. It is machine generated. { "aria.oneReference": "列 {2} ã® {1} 行目㫠{0} ã¤ã®ã‚·ãƒ³ãƒœãƒ«", - "aria.fileReferences.1": "{0} ã« 1 個ã®ã‚·ãƒ³ãƒœãƒ«", - "aria.fileReferences.N": "{1} ã« {0} 個ã®ã‚·ãƒ³ãƒœãƒ«", "aria.result.0": "一致ã™ã‚‹é …ç›®ã¯ã‚ã‚Šã¾ã›ã‚“", "aria.result.1": "{0} ã« 1 個ã®ã‚·ãƒ³ãƒœãƒ«ãŒè¦‹ã¤ã‹ã‚Šã¾ã—ãŸ", "aria.result.n1": "{1} ã« {0} 個ã®ã‚·ãƒ³ãƒœãƒ«ãŒè¦‹ã¤ã‹ã‚Šã¾ã—ãŸ", diff --git a/i18n/jpn/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json b/i18n/jpn/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json index 5b2270de604..36b95788727 100644 --- a/i18n/jpn/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json +++ b/i18n/jpn/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json @@ -21,6 +21,8 @@ "menus.scmTitle": "ソース管ç†ã®ã‚¿ã‚¤ãƒˆãƒ« メニュー", "menus.resourceGroupContext": "ソース管ç†ãƒªã‚½ãƒ¼ã‚¹ グループã®ã‚³ãƒ³ãƒ†ã‚­ã‚¹ãƒˆ メニュー", "menus.resourceStateContext": "ソース管ç†ãƒªã‚½ãƒ¼ã‚¹çŠ¶æ…‹ã®ã‚³ãƒ³ãƒ†ã‚­ã‚¹ãƒˆ メニュー", + "view.viewTitle": "æä¾›ã•ã‚ŒãŸãƒ“ューã®ã‚¿ã‚¤ãƒˆãƒ« メニュー", + "view.itemContext": "æä¾›ã•ã‚ŒãŸãƒ“ュー項目ã®ã‚³ãƒ³ãƒ†ã‚­ã‚¹ãƒˆ メニュー", "nonempty": "空以外ã®å€¤ãŒå¿…è¦ã§ã™ã€‚", "opticon": "`icon` プロパティã¯çœç•¥ã§ãã¾ã™ã€‚指定ã™ã‚‹å ´åˆã«ã¯ã€æ–‡å­—列ã¾ãŸã¯ `{dark, light}` ãªã©ã®ãƒªãƒ†ãƒ©ãƒ«ã«ã™ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™", "requireStringOrObject": "`{0}` プロパティã¯å¿…é ˆã§ã€`string` ã¾ãŸã¯ `object` ã®åž‹ã§ãªã‘ã‚Œã°ãªã‚Šã¾ã›ã‚“", diff --git a/i18n/jpn/src/vs/platform/environment/node/argv.i18n.json b/i18n/jpn/src/vs/platform/environment/node/argv.i18n.json index f63839a1d9b..6cd2c2e4b34 100644 --- a/i18n/jpn/src/vs/platform/environment/node/argv.i18n.json +++ b/i18n/jpn/src/vs/platform/environment/node/argv.i18n.json @@ -6,25 +6,25 @@ { "gotoValidation": "`--goto` モードã®å¼•æ•°ã¯ `FILE(:LINE(:CHARACTER))` ã®å½¢å¼ã«ã™ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™ã€‚", "diff": "差分エディターを開ãã¾ã™ã€‚引数ã¨ã—㦠2 ã¤ã®ãƒ•ã‚¡ã‚¤ãƒ« パスを渡ã™å¿…è¦ãŒã‚ã‚Šã¾ã™ã€‚", - "goto": "指定ã®è¡Œã¨æ–‡å­—ã®ãƒ‘スã®ãƒ•ã‚¡ã‚¤ãƒ«ã‚’é–‹ãã¾ã™ (パス㫠:line[:character] を追加ã—ã¾ã™)。", - "locale": "使用ã™ã‚‹ãƒ­ã‚±ãƒ¼ãƒ« (例: en-USã€zh-TW ãªã©)。", - "newWindow": "æ–°ã—ã„コード インスタンスを強制ã—ã¾ã™ã€‚", + "goto": "指定ã®è¡Œã¨æ–‡å­—ã®ä½ç½®ã§ãƒ•ã‚¡ã‚¤ãƒ«ã‚’é–‹ãã¾ã™(パス㫠:line[:character] を追加ã—ã¦ãã ã•ã„)。", + "locale": "使用ã™ã‚‹å›½ã¨åœ°åŸŸ (例:en-US ã‚„ zh-TW ãªã©)。", + "newWindow": "æ–°ã—ã„ Code ã®ã‚¤ãƒ³ã‚¹ã‚¿ãƒ³ã‚¹ã‚’強制ã—ã¾ã™ã€‚", "performance": "'Developer: Startup Performance' コマンドを有効ã«ã—ã¦é–‹å§‹ã—ã¾ã™ã€‚", "prof-startup": "起動中㫠CPU プロファイラーを実行ã™ã‚‹", "reuseWindow": "最後ã®ã‚¢ã‚¯ãƒ†ã‚£ãƒ– ウィンドウã«ãƒ•ã‚¡ã‚¤ãƒ«ã¾ãŸã¯ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã‚’強制的ã«é–‹ãã¾ã™ã€‚", "userDataDir": "ユーザー データをä¿æŒã™ã‚‹ãƒ‡ã‚£ãƒ¬ã‚¯ãƒˆãƒªã‚’指定ã—ã¾ã™ã€‚ルートã§å®Ÿè¡Œã—ã¦ã„ã‚‹å ´åˆã«å½¹ç«‹ã¡ã¾ã™ã€‚", - "verbose": "詳細出力をå°åˆ·ã—ã¾ã™ (ãŠå¾…ã¡ãã ã•ã„)。", - "wait": "戻るå‰ã«ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ãŒé–‰ã˜ã‚‹ã¾ã§ãŠå¾…ã¡ãã ã•ã„。", + "verbose": "詳細出力を表示ã—ã¾ã™ (--wait ã‚’å«ã¿ã¾ã™)。", + "wait": "ç¾åœ¨ã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ãŒé–‰ã˜ã‚‹ã¾ã§å¾…æ©Ÿã—ã¾ã™ã€‚", "extensionHomePath": "拡張機能ã®ãƒ«ãƒ¼ãƒˆ パスを設定ã—ã¾ã™ã€‚", "listExtensions": "インストールã•ã‚Œã¦ã„る拡張機能を一覧表示ã—ã¾ã™ã€‚", - "showVersions": "#NAME?", + "showVersions": "--list-extension ã¨ä½¿ç”¨ã™ã‚‹ã¨ãã€ã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã¦ã„る拡張機能ã®ãƒãƒ¼ã‚¸ãƒ§ãƒ³ã‚’表示ã—ã¾ã™ã€‚", "installExtension": "拡張機能をインストールã—ã¾ã™ã€‚", "uninstallExtension": "拡張機能をアンインストールã—ã¾ã™ã€‚", "experimentalApis": "拡張機能ã«å¯¾ã—㦠Proposed API 機能を有効ã«ã—ã¾ã™ã€‚", "disableExtensions": "インストールã•ã‚ŒãŸã™ã¹ã¦ã®æ‹¡å¼µæ©Ÿèƒ½ã‚’無効ã«ã—ã¾ã™ã€‚", "disableGPU": "GPU ãƒãƒ¼ãƒ‰ã‚¦ã‚§ã‚¢ アクセラレータを無効ã«ã—ã¾ã™ã€‚", - "version": "ãƒãƒ¼ã‚¸ãƒ§ãƒ³ã‚’å°åˆ·ã—ã¾ã™ã€‚", - "help": "使用法をå°åˆ·ã—ã¾ã™ã€‚", + "version": "ãƒãƒ¼ã‚¸ãƒ§ãƒ³ã‚’表示ã—ã¾ã™ã€‚", + "help": "使用法を表示ã—ã¾ã™ã€‚", "usage": "使用法", "options": "オプション", "paths": "パス", diff --git a/i18n/jpn/src/vs/platform/extensions/common/extensionsRegistry.i18n.json b/i18n/jpn/src/vs/platform/extensions/common/extensionsRegistry.i18n.json index ae0dfa88edb..38e5bf8d7a1 100644 --- a/i18n/jpn/src/vs/platform/extensions/common/extensionsRegistry.i18n.json +++ b/i18n/jpn/src/vs/platform/extensions/common/extensionsRegistry.i18n.json @@ -14,6 +14,12 @@ "vscode.extension.contributes": "ã“ã®ãƒ‘ッケージã§è¡¨ã•ã‚Œã‚‹ VS Code 拡張機能ã®ã™ã¹ã¦ã®ã‚³ãƒ³ãƒˆãƒªãƒ“ューション。", "vscode.extension.preview": "Marketplace 㧠Preview ã¨ã—ã¦ãƒ•ãƒ©ã‚°ãŒä»˜ã‘られるよã†ã«æ‹¡å¼µæ©Ÿèƒ½ã‚’設定ã—ã¾ã™ã€‚", "vscode.extension.activationEvents": "VS Code 拡張機能ã®ã‚¢ã‚¯ãƒ†ã‚£ãƒ–化イベント。", + "vscode.extension.activationEvents.onLanguage": "指定ã•ã‚ŒãŸè¨€èªžã‚’解決ã™ã‚‹ãƒ•ã‚¡ã‚¤ãƒ«ãŒé–‹ã‹ã‚Œã‚‹ãŸã³ã«ã‚¢ã‚¯ãƒ†ã‚£ãƒ–化イベントãŒç™ºè¡Œã•ã‚Œã¾ã™ã€‚", + "vscode.extension.activationEvents.onCommand": "指定ã—ãŸã‚³ãƒžãƒ³ãƒ‰ãŒå‘¼ã³å‡ºã•ã‚Œã‚‹ãŸã³ã«ã‚¢ã‚¯ãƒ†ã‚£ãƒ–化イベントãŒç™ºè¡Œã•ã‚Œã¾ã™ã€‚", + "vscode.extension.activationEvents.onDebug": "指定ã•ã‚ŒãŸã‚¿ã‚¤ãƒ—ã®ãƒ‡ãƒãƒƒã‚° セッションãŒé–‹å§‹ã•ã‚Œã‚‹ãŸã³ã«ã‚¢ã‚¯ãƒ†ã‚£ãƒ–化イベントãŒç™ºè¡Œã•ã‚Œã¾ã™ã€‚", + "vscode.extension.activationEvents.workspaceContains": "指定ã—㟠glob パターンã«ä¸€è‡´ã™ã‚‹ãƒ•ã‚¡ã‚¤ãƒ«ã‚’å°‘ãªãã¨ã‚‚ 1 ã¤ä»¥ä¸Šå«ã‚€ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã‚’é–‹ããŸã³ã«ã‚¢ã‚¯ãƒ†ã‚£ãƒ–化イベントãŒç™ºè¡Œã•ã‚Œã¾ã™ã€‚", + "vscode.extension.activationEvents.onView": "指定ã—ãŸãƒ“ューを展開ã™ã‚‹ãŸã³ã«ã‚¢ã‚¯ãƒ†ã‚£ãƒ–化イベントãŒç™ºè¡Œã•ã‚Œã¾ã™ã€‚", + "vscode.extension.activationEvents.star": "VS Code 起動時ã«ã‚¢ã‚¯ãƒ†ã‚£ãƒ–化イベントを発行ã—ã¾ã™ã€‚優れãŸã‚¨ãƒ³ãƒ‰ãƒ¦ãƒ¼ã‚¶ãƒ¼ エクスペリエンスを確ä¿ã™ã‚‹ãŸã‚ã«ã€ä»–ã®ã‚¢ã‚¯ãƒ†ã‚£ãƒ–化イベントã®çµ„ã¿åˆã‚ã›ã§ã¯æœ›ã‚€å‹•ä½œã«ãªã‚‰ãªã„ã¨ãã®ã¿ä½¿ç”¨ã—ã¦ãã ã•ã„。", "vscode.extension.badges": "Marketplace ã®æ‹¡å¼µæ©Ÿèƒ½ãƒšãƒ¼ã‚¸ã®ã‚µã‚¤ãƒ‰ãƒãƒ¼ã«è¡¨ç¤ºã•ã‚Œã‚‹ãƒãƒƒã‚¸ã®é…列。", "vscode.extension.badges.url": "ãƒãƒƒã‚¸ã®ã‚¤ãƒ¡ãƒ¼ã‚¸ URL。", "vscode.extension.badges.href": "ãƒãƒƒã‚¸ã®ãƒªãƒ³ã‚¯ã€‚", diff --git a/i18n/jpn/src/vs/platform/history/electron-main/historyMainService.i18n.json b/i18n/jpn/src/vs/platform/history/electron-main/historyMainService.i18n.json new file mode 100644 index 00000000000..da8dfc2d763 --- /dev/null +++ b/i18n/jpn/src/vs/platform/history/electron-main/historyMainService.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "newWindow": "æ–°ã—ã„ウィンドウ", + "newWindowDesc": "æ–°ã—ã„ウィンドウを開ã", + "recentFolders": "最近使用ã—ãŸãƒ•ã‚©ãƒ«ãƒ€ãƒ¼", + "folderDesc": "{0} {1}" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/platform/markers/common/problemMatcher.i18n.json b/i18n/jpn/src/vs/platform/markers/common/problemMatcher.i18n.json index df4f3d19acd..7d46ebd0c9b 100644 --- a/i18n/jpn/src/vs/platform/markers/common/problemMatcher.i18n.json +++ b/i18n/jpn/src/vs/platform/markers/common/problemMatcher.i18n.json @@ -52,9 +52,9 @@ "ProblemMatcherSchema.watching.activeOnStart": "true ã«è¨­å®šã™ã‚‹ã¨ã€ã‚¿ã‚¹ã‚¯ã®é–‹å§‹æ™‚ã«ã‚¦ã‚©ãƒƒãƒãƒ£ãƒ¼ãŒã‚¢ã‚¯ãƒ†ã‚£ãƒ– モードã«ãªã‚Šã¾ã™ã€‚ã“れ㯠beginPattern ã¨ä¸€è‡´ã™ã‚‹è¡Œã®ç™ºè¡Œã¨åŒç­‰ã§ã™ã€‚", "ProblemMatcherSchema.watching.beginsPattern": "出力内ã§ä¸€è‡´ã™ã‚‹ã¨ã€ã‚¦ã‚©ãƒƒãƒä¸­ã®ã‚¿ã‚¹ã‚¯ã®é–‹å§‹ãŒé€šçŸ¥ã•ã‚Œã¾ã™ã€‚", "ProblemMatcherSchema.watching.endsPattern": "出力内ã§ä¸€è‡´ã™ã‚‹ã¨ã€ã‚¦ã‚©ãƒƒãƒä¸­ã®ã‚¿ã‚¹ã‚¯ã®çµ‚了ãŒé€šçŸ¥ã•ã‚Œã¾ã™ã€‚", - "LegacyProblemMatcherSchema.watchedBegin.deprecated": "This property is deprecated. Use the watching property instead.", + "LegacyProblemMatcherSchema.watchedBegin.deprecated": "ã“ã®ãƒ—ロパティã¯éžæŽ¨å¥¨ã§ã™ã€‚代ã‚ã‚Šã« watching プロパティをã”使用ãã ã•ã„。", "LegacyProblemMatcherSchema.watchedBegin": "ファイル ウォッãƒã§ãƒˆãƒªã‚¬ãƒ¼ã•ã‚ŒãŸ ウォッãƒå¯¾è±¡ã‚¿ã‚¹ã‚¯ã®å®Ÿè¡ŒãŒé–‹å§‹ã•ã‚ŒãŸã“ã¨ã‚’ä¼é”ã™ã‚‹æ­£è¦è¡¨ç¾ã€‚", - "LegacyProblemMatcherSchema.watchedEnd.deprecated": "This property is deprecated. Use the watching property instead.", + "LegacyProblemMatcherSchema.watchedEnd.deprecated": "ã“ã®ãƒ—ロパティã¯éžæŽ¨å¥¨ã§ã™ã€‚代ã‚ã‚Šã« watching プロパティをã”使用ãã ã•ã„。", "LegacyProblemMatcherSchema.watchedEnd": "ウォッãƒå¯¾è±¡ã‚¿ã‚¹ã‚¯ã®å®Ÿè¡ŒãŒçµ‚了ã—ãŸã“ã¨ã‚’ä¼é”ã™ã‚‹æ­£è¦è¡¨ç¾ã€‚", "NamedProblemMatcherSchema.name": "å•é¡Œãƒžãƒƒãƒãƒ£ãƒ¼ã®åå‰ã€‚", "ProblemMatcherExtPoint": "å•é¡Œãƒžãƒƒãƒãƒ£ãƒ¼ã‚’æä¾›" diff --git a/i18n/jpn/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/jpn/src/vs/platform/theme/common/colorRegistry.i18n.json index 8da89f6115c..a8865bcfa0d 100644 --- a/i18n/jpn/src/vs/platform/theme/common/colorRegistry.i18n.json +++ b/i18n/jpn/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -12,7 +12,7 @@ "focusBorder": "フォーカスã•ã‚ŒãŸè¦ç´ ã®å¢ƒç•Œç·šå…¨ä½“ã®è‰²ã€‚ã“ã®è‰²ã¯ã‚³ãƒ³ãƒãƒ¼ãƒãƒ³ãƒˆã«ã‚ˆã£ã¦ä¸Šæ›¸ãã•ã‚Œã¦ã„ãªã„å ´åˆã«ã®ã¿ä½¿ç”¨ã•ã‚Œã¾ã™ã€‚", "contrastBorder": "コントラストを強ã‚ã‚‹ãŸã‚ã«ã€ä»–ã®è¦ç´ ã¨éš”ã¦ã‚‹è¿½åŠ ã®å¢ƒç•Œç·šã€‚", "activeContrastBorder": "コントラストを強ã‚ã‚‹ãŸã‚ã«ã€ã‚¢ã‚¯ãƒ†ã‚£ãƒ–ãªä»–è¦ç´ ã¨éš”ã¦ã‚‹è¿½åŠ ã®å¢ƒç•Œç·šã€‚", - "selectionBackground": "ワークベンãƒå†…ã®ãƒ†ã‚­ã‚¹ãƒˆé¸æŠžã®èƒŒæ™¯è‰² (例: 入力フィールドやテキストエリア)。エディター内やターミナル内ã®é¸æŠžã«ã¯é©ç”¨ã•ã‚Œãªã„ã“ã¨ã«æ³¨æ„ã—ã¦ãã ã•ã„。", + "selectionBackground": "ワークベンãƒå†…ã®ãƒ†ã‚­ã‚¹ãƒˆé¸æŠžã®èƒŒæ™¯è‰² (例: 入力フィールドやテキストエリア)。エディター内ã®é¸æŠžã«ã¯é©ç”¨ã•ã‚Œãªã„ã“ã¨ã«æ³¨æ„ã—ã¦ãã ã•ã„。", "textSeparatorForeground": "テキストã®åŒºåˆ‡ã‚Šæ–‡å­—ã®è‰²ã€‚", "textLinkForeground": "テキスト内ã®ãƒªãƒ³ã‚¯ã®å‰æ™¯è‰²ã€‚", "textLinkActiveForeground": "テキスト内ã®ã‚¢ã‚¯ãƒ†ã‚£ãƒ–ãªãƒªãƒ³ã‚¯ã®å‰æ™¯è‰²ã€‚", @@ -60,6 +60,7 @@ "editorBackground": "エディターã®èƒŒæ™¯è‰²ã€‚", "editorForeground": "エディターã®æ—¢å®šã®å‰æ™¯è‰²ã€‚", "editorWidgetBackground": "検索/ç½®æ›çª“ãªã©ã€ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ ウィジェットã®èƒŒæ™¯è‰²ã€‚", + "editorWidgetBorder": "エディター ウィジェットã®å¢ƒç•Œç·šè‰²ã€‚ウィジェットã«å¢ƒç•Œç·šãŒã‚ã‚Šã€ã‚¦ã‚£ã‚¸ã‚§ãƒƒãƒˆã«ã‚ˆã£ã¦é…色を上書ãã•ã‚Œã¦ã„ãªã„å ´åˆã§ã®ã¿ã“ã®é…色ã¯ä½¿ç”¨ã•ã‚Œã¾ã™ã€‚", "editorSelection": "エディターã®é¸æŠžç¯„囲ã®è‰²ã€‚", "editorInactiveSelection": "éžã‚¢ã‚¯ãƒ†ã‚£ãƒ–ãªã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã®é¸æŠžç¯„囲ã®è‰²ã€‚", "editorSelectionHighlight": "é¸æŠžç¯„囲ã¨åŒã˜ã‚³ãƒ³ãƒ†ãƒ³ãƒ„ã®é ˜åŸŸã®è‰²ã€‚", @@ -73,5 +74,12 @@ "diffEditorInserted": "挿入ã•ã‚ŒãŸãƒ†ã‚­ã‚¹ãƒˆã®èƒŒæ™¯è‰²ã€‚", "diffEditorRemoved": "削除ã•ã‚ŒãŸãƒ†ã‚­ã‚¹ãƒˆã®èƒŒæ™¯è‰²ã€‚", "diffEditorInsertedOutline": "挿入ã•ã‚ŒãŸãƒ†ã‚­ã‚¹ãƒˆã®è¼ªéƒ­ã®è‰²ã€‚", - "diffEditorRemovedOutline": "削除ã•ã‚ŒãŸãƒ†ã‚­ã‚¹ãƒˆã®è¼ªéƒ­ã®è‰²ã€‚" + "diffEditorRemovedOutline": "削除ã•ã‚ŒãŸãƒ†ã‚­ã‚¹ãƒˆã®è¼ªéƒ­ã®è‰²ã€‚", + "mergeCurrentHeaderBackground": "行内マージ競åˆã®ç¾åœ¨ã®ãƒ˜ãƒƒãƒ€ãƒ¼èƒŒæ™¯è‰²ã€‚", + "mergeCurrentContentBackground": "行内マージ競åˆã®ç¾åœ¨ã®ã‚³ãƒ³ãƒ†ãƒ³ãƒ„背景色。", + "mergeIncomingHeaderBackground": "行内マージ競åˆã®å…¥åŠ›å´ãƒ˜ãƒƒãƒ€ãƒ¼èƒŒæ™¯è‰²ã€‚", + "mergeIncomingContentBackground": "行内マージ競åˆã®å…¥åŠ›å´ã‚³ãƒ³ãƒ†ãƒ³ãƒ„背景色。", + "mergeBorder": "行内マージ競åˆã®ãƒ˜ãƒƒãƒ€ãƒ¼ã¨ã‚¹ãƒ—リッターã®å¢ƒç•Œç·šã®è‰²ã€‚", + "overviewRulerCurrentContentForeground": "行内マージ競åˆã®ç¾åœ¨ã®æ¦‚è¦ãƒ«ãƒ¼ãƒ©ãƒ¼å‰æ™¯è‰²ã€‚", + "overviewRulerIncomingContentForeground": "行内マージ競åˆã®å…¥åŠ›å´ã®æ¦‚è¦ãƒ«ãƒ¼ãƒ©ãƒ¼å‰æ™¯è‰²ã€‚" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/jpn/src/vs/workbench/api/node/extHostTask.i18n.json index 8b6ad71cd4e..4b90a12aaf2 100644 --- a/i18n/jpn/src/vs/workbench/api/node/extHostTask.i18n.json +++ b/i18n/jpn/src/vs/workbench/api/node/extHostTask.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "task.label": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json b/i18n/jpn/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json index ad17b1a0a2c..b9c158c0786 100644 --- a/i18n/jpn/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json +++ b/i18n/jpn/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json @@ -5,5 +5,6 @@ // Do not edit this file. It is machine generated. { "hideActivitBar": "アクティビティ ãƒãƒ¼ã‚’éžè¡¨ç¤ºã«ã™ã‚‹", - "activityBarAriaLabel": "アクティブãªãƒ“ュー スイッãƒãƒ£ãƒ¼" + "activityBarAriaLabel": "アクティブãªãƒ“ュー スイッãƒãƒ£ãƒ¼", + "globalActions": "グローãƒãƒ«æ“作" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json b/i18n/jpn/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json index 2b2a554b6db..b0d78c01023 100644 --- a/i18n/jpn/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json +++ b/i18n/jpn/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json @@ -10,8 +10,7 @@ "multiSelection": "{0} 個ã®é¸æŠžé …ç›®", "endOfLineLineFeed": "LF", "endOfLineCarriageReturnLineFeed": "CRLF", - "tabFocusModeEnabled": "タブã«ã‚ˆã‚‹ãƒ•ã‚©ãƒ¼ã‚«ã‚¹ã®ç§»å‹•", - "screenReaderDetected": "スクリーン リーダーãŒæ¤œå‡ºã•ã‚Œã¾ã—ãŸ", + "screenReaderDetectedExtra": "スクリーン リーダーを使用ã—ãªã„å ´åˆã€`editor.accessibilitySupport` ã‚’ \"off\" ã«ã—ã¦ãã ã•ã„。", "disableTabMode": "アクセシビリティ モードを無効ã«ã™ã‚‹", "gotoLine": "è¡Œã¸ç§»å‹•", "indentation": "インデント", diff --git a/i18n/jpn/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json b/i18n/jpn/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json new file mode 100644 index 00000000000..b1dcfefa58e --- /dev/null +++ b/i18n/jpn/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpen": "ファイルã«ç§»å‹•...", + "quickNavigateNext": "Quick Open ã§æ¬¡ã«ç§»å‹•", + "quickNavigatePrevious": "Quick Open ã§å‰ã«ç§»å‹•", + "quickSelectNext": "Quick Open 㧠[次ã¸] ã‚’é¸æŠž", + "quickSelectPrevious": "Quick Open 㧠[å‰ã¸] ã‚’é¸æŠž" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/browser/quickopen.i18n.json b/i18n/jpn/src/vs/workbench/browser/quickopen.i18n.json index 715d0b6fb80..b598142bc87 100644 --- a/i18n/jpn/src/vs/workbench/browser/quickopen.i18n.json +++ b/i18n/jpn/src/vs/workbench/browser/quickopen.i18n.json @@ -6,6 +6,5 @@ { "noResultsMatching": "一致ã™ã‚‹çµæžœã¯ã‚ã‚Šã¾ã›ã‚“", "noResultsFound2": "一致ã™ã‚‹é …ç›®ã¯ã‚ã‚Šã¾ã›ã‚“", - "entryAriaLabel": "{0}ã€ã‚³ãƒžãƒ³ãƒ‰", - "noCommands": "一致ã™ã‚‹ã‚³ãƒžãƒ³ãƒ‰ã¯ã‚ã‚Šã¾ã›ã‚“" + "entryAriaLabel": "{0}ã€ã‚³ãƒžãƒ³ãƒ‰" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/browser/viewlet.i18n.json b/i18n/jpn/src/vs/workbench/browser/viewlet.i18n.json index e44e917c23b..cd69288971a 100644 --- a/i18n/jpn/src/vs/workbench/browser/viewlet.i18n.json +++ b/i18n/jpn/src/vs/workbench/browser/viewlet.i18n.json @@ -4,6 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "collapse": "ã™ã¹ã¦æŠ˜ã‚ŠãŸãŸã‚€", - "viewToolbarAriaLabel": "{0} 個ã®ã‚¢ã‚¯ã‚·ãƒ§ãƒ³" + "collapse": "ã™ã¹ã¦æŠ˜ã‚ŠãŸãŸã‚€" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/common/theme.i18n.json b/i18n/jpn/src/vs/workbench/common/theme.i18n.json index 26f43afd107..89788c6658b 100644 --- a/i18n/jpn/src/vs/workbench/common/theme.i18n.json +++ b/i18n/jpn/src/vs/workbench/common/theme.i18n.json @@ -7,12 +7,17 @@ "tabActiveBackground": "アクティブ タブã®èƒŒæ™¯è‰²ã€‚タブã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸã«ãŠã‘るエディターã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚1 ã¤ã®ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ グループã§è¤‡æ•°ã®ã‚¿ãƒ–ã‚’é–‹ãã“ã¨ãŒã§ãã¾ã™ã€‚エディター グループを複数ã«ã™ã‚‹ã“ã¨ã‚‚ã§ãã¾ã™ã€‚", "tabInactiveBackground": "éžã‚¢ã‚¯ãƒ†ã‚£ãƒ– タブã®èƒŒæ™¯è‰²ã€‚タブã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸã«ãŠã‘るエディターã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚1 ã¤ã®ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ グループã§è¤‡æ•°ã®ã‚¿ãƒ–ã‚’é–‹ãã“ã¨ãŒã§ãã¾ã™ã€‚エディター グループを複数ã«ã™ã‚‹ã“ã¨ã‚‚ã§ãã¾ã™ã€‚", "tabBorder": "タブåŒå£«ã‚’分ã‘ã‚‹ãŸã‚ã®å¢ƒç•Œç·šã€‚タブã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸå†…ã«ã‚るエディターã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚複数ã®ã‚¿ãƒ–ã‚’ 1 ã¤ã®ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ グループã§é–‹ãã“ã¨ãŒã§ãã¾ã™ã€‚複数ã®ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ グループãŒã‚ã‚‹å¯èƒ½æ€§ãŒã‚ã‚Šã¾ã™ã€‚", + "tabActiveForeground": "アクティブ グループ内ã®ã‚¢ã‚¯ãƒ†ã‚£ãƒ– タブã®å‰æ™¯è‰²ã€‚タブã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸã«ãŠã‘るエディターã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚1 ã¤ã®ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ グループã§è¤‡æ•°ã®ã‚¿ãƒ–ã‚’é–‹ãã“ã¨ãŒã§ãã¾ã™ã€‚エディター グループを複数ã«ã™ã‚‹ã“ã¨ã‚‚ã§ãã¾ã™ã€‚", + "tabInactiveForeground": "アクティブ グループ内ã®éžã‚¢ã‚¯ãƒ†ã‚£ãƒ– タブã®å‰æ™¯è‰²ã€‚タブã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸã«ãŠã‘るエディターã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚1 ã¤ã®ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ グループã§è¤‡æ•°ã®ã‚¿ãƒ–ã‚’é–‹ãã“ã¨ãŒã§ãã¾ã™ã€‚エディター グループを複数ã«ã™ã‚‹ã“ã¨ã‚‚ã§ãã¾ã™ã€‚", + "tabUnfocusedActiveForeground": "éžã‚¢ã‚¯ãƒ†ã‚£ãƒ– グループ内ã®ã‚¢ã‚¯ãƒ†ã‚£ãƒ– タブã®å‰æ™¯è‰²ã€‚タブã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸã«ãŠã‘るエディターã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚1 ã¤ã®ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ グループã§è¤‡æ•°ã®ã‚¿ãƒ–ã‚’é–‹ãã“ã¨ãŒã§ãã¾ã™ã€‚エディター グループを複数ã«ã™ã‚‹ã“ã¨ã‚‚ã§ãã¾ã™ã€‚", + "tabUnfocusedInactiveForeground": "éžã‚¢ã‚¯ãƒ†ã‚£ãƒ– タブã®å‰æ™¯è‰²ã€‚タブã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸã«ãŠã‘るエディターã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚1 ã¤ã®ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ グループã§è¤‡æ•°ã®ã‚¿ãƒ–ã‚’é–‹ãã“ã¨ãŒã§ãã¾ã™ã€‚エディター グループを複数ã«ã™ã‚‹ã“ã¨ã‚‚ã§ãã¾ã™ã€‚", "editorGroupBackground": "エディター グループã®èƒŒæ™¯è‰²ã€‚エディター グループã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚背景色ã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ グループをドラッグã™ã‚‹ã¨è¡¨ç¤ºã•ã‚Œã¾ã™ã€‚", "tabsContainerBackground": "タブãŒæœ‰åŠ¹ãªå ´åˆã® エディター グループ タイトル ヘッダーã®èƒŒæ™¯è‰²ã€‚エディター グループã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", "tabsContainerBorder": "タブãŒæœ‰åŠ¹ãªå ´åˆã® エディター グループ タイトル ヘッダーã®å¢ƒç•Œç·šè‰²ã€‚エディター グループã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", "editorGroupHeaderBackground": "タブãŒç„¡åŠ¹ãªå ´åˆã® エディター グループ タイトル ヘッダーã®èƒŒæ™¯è‰²ã€‚エディター グループã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", "editorGroupBorder": "複数ã®ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ グループを互ã„ã«åˆ†é›¢ã™ã‚‹ãŸã‚ã®è‰²ã€‚エディター グループã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã®ã‚³ãƒ³ãƒ†ãƒŠãƒ¼ã§ã™ã€‚", "editorDragAndDropBackground": "エディターã®å‘¨å›²ã‚’ドラッグã—ã¦ã„ã‚‹ã¨ãã®èƒŒæ™¯è‰²ã€‚エディターã®ã‚³ãƒ³ãƒ†ãƒ³ãƒ„ãŒæœ€å¾Œã¾ã§è¼ããŸã‚ã«ã€è‰²ã¯é€éŽã§ã‚ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™ã€‚", + "panelBackground": "パãƒãƒ«ã®èƒŒæ™¯è‰²ã€‚パãƒãƒ«ã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸã®ä¸‹ã«è¡¨ç¤ºã•ã‚Œã€å‡ºåŠ›ã‚„çµ±åˆã‚¿ãƒ¼ãƒŸãƒŠãƒ«ãªã©ã®ãƒ“ューをå«ã¿ã¾ã™ã€‚", "panelBorder": "エディターã¨ã®åŒºåˆ‡ã‚Šã‚’示ã™ãƒ‘ãƒãƒ«ä¸Šéƒ¨ã®ç½«ç·šã®è‰²ã€‚パãƒãƒ«ã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸã®ä¸‹ã«è¡¨ç¤ºã•ã‚Œã€å‡ºåŠ›ã‚„çµ±åˆã‚¿ãƒ¼ãƒŸãƒŠãƒ«ãªã©ã®ãƒ“ューをå«ã¿ã¾ã™ã€‚", "panelActiveTitleForeground": "アクティブ パãƒãƒ«ã®ã‚¿ã‚¤ãƒˆãƒ«ã®è‰²ã€‚パãƒãƒ«ã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸã®ä¸‹ã«è¡¨ç¤ºã•ã‚Œã€å‡ºåŠ›ã‚„çµ±åˆã‚¿ãƒ¼ãƒŸãƒŠãƒ«ãªã©ã®ãƒ“ューをå«ã¿ã¾ã™ã€‚", "panelInactiveTitleForeground": "éžã‚¢ã‚¯ãƒ†ã‚£ãƒ– パãƒãƒ«ã®ã‚¿ã‚¤ãƒˆãƒ«ã®è‰²ã€‚パãƒãƒ«ã¯ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼é ˜åŸŸã®ä¸‹ã«è¡¨ç¤ºã•ã‚Œã€å‡ºåŠ›ã‚„çµ±åˆã‚¿ãƒ¼ãƒŸãƒŠãƒ«ãªã©ã®ãƒ“ューをå«ã¿ã¾ã™ã€‚", diff --git a/i18n/jpn/src/vs/workbench/electron-browser/actions.i18n.json b/i18n/jpn/src/vs/workbench/electron-browser/actions.i18n.json index 85457381110..ab86da5259e 100644 --- a/i18n/jpn/src/vs/workbench/electron-browser/actions.i18n.json +++ b/i18n/jpn/src/vs/workbench/electron-browser/actions.i18n.json @@ -6,9 +6,6 @@ { "closeActiveEditor": "エディターを閉ã˜ã‚‹", "closeWindow": "ウィンドウを閉ã˜ã‚‹", - "switchWindow": "切り替ãˆã‚¦ã‚£ãƒ³ãƒ‰ã‚¦", - "switchWindowPlaceHolder": "ウィンドウã®é¸æŠž", - "current": "ç¾åœ¨ã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦", "closeFolder": "フォルダーを閉ã˜ã‚‹", "noFolderOpened": "ã“ã®ã‚¤ãƒ³ã‚¹ã‚¿ãƒ³ã‚¹ã§ç¾åœ¨é–‹ã„ã¦ã„るフォルダーãŒãªã„ã®ã§ã€é–‰ã˜ã‚‰ã‚Œã¾ã›ã‚“。", "newWindow": "æ–°ã—ã„ウィンドウ", @@ -20,7 +17,7 @@ "zoomReset": "ズームã®ãƒªã‚»ãƒƒãƒˆ", "appPerf": "スタートアップ パフォーマンス", "reloadWindow": "ウィンドウã®å†èª­ã¿è¾¼ã¿", - "openRecent": "最近開ã„ãŸé …ç›®", + "current": "ç¾åœ¨ã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦", "folders": "フォルダー", "files": "ファイル", "openRecentPlaceHolderMac": "パスをé¸æŠž (Cmd キーを押ã—ãªãŒã‚‰æ–°ã—ã„ウィンドウã§é–‹ã)", @@ -32,10 +29,6 @@ "openDocumentationUrl": "ドキュメント", "openIntroductoryVideosUrl": "紹介ビデオ", "toggleSharedProcess": "共有プロセスを切り替ãˆã‚‹", - "navigateLeft": "å·¦ã®ãƒ“ュー部分ã«ç§»å‹•", - "navigateRight": "å³ã®ãƒ“ュー部分ã«ç§»å‹•", - "navigateUp": "上ã®ãƒ“ュー部分ã«ç§»å‹•", - "navigateDown": "下ã®ãƒ“ュー部分ã«ç§»å‹•", "increaseViewSize": "ç¾åœ¨ã®ãƒ“ューã®ã‚µã‚¤ã‚ºã®æ‹¡å¤§", "decreaseViewSize": "ç¾åœ¨ã®ãƒ“ューã®ã‚µã‚¤ã‚ºã®ç¸®å°" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/jpn/src/vs/workbench/electron-browser/main.contribution.i18n.json index d813d5f6c23..38a801fbf9b 100644 --- a/i18n/jpn/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/jpn/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -31,10 +31,6 @@ "window.openFoldersInNewWindow.off": "フォルダーã¯ã€æœ€å¾Œã®ã‚¢ã‚¯ãƒ†ã‚£ãƒ– ウィンドウã§é–‹ãã¾ã™", "window.openFoldersInNewWindow.default": "フォルダーãŒã‚¢ãƒ—リケーション内ã‹ã‚‰ (ãŸã¨ãˆã°ã€[ファイル] メニューã‹ã‚‰) é¸æŠžã•ã‚ŒãŸå ´åˆã‚’除ã„ã¦ã€æ–°ã—ã„ウィンドウã§ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã‚’é–‹ãã¾ã™", "openFoldersInNewWindow": "フォルダーを新ã—ã„ウィンドウã§é–‹ãã‹ã€æœ€å¾Œã®ã‚¢ã‚¯ãƒ†ã‚£ãƒ– ウィンドウã§é–‹ãã‹ã‚’制御ã—ã¾ã™ã€‚\n- default: アプリケーション内㧠([ファイル] メニューãªã©ã‹ã‚‰) é¸æŠžã—ãŸã‚‚ã®ã§ãªã‘ã‚Œã°ã€æ–°ã—ã„ウィンドウã§ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã‚’é–‹ã\n- on: æ–°ã—ã„ウィンドウã§ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã‚’é–‹ã\n- off: 最後ã®ã‚¢ã‚¯ãƒ†ã‚£ãƒ– ウィンドウã§ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã‚’é–‹ã\nã“ã®è¨­å®šã¯ç„¡è¦–ã•ã‚Œã‚‹å ´åˆã‚‚ã‚ã‚Šã¾ã™ (-new-window ã¾ãŸã¯ -reuse-window コマンド ライン オプションを使用ã™ã‚‹å ´åˆãªã©)。", - "window.reopenFolders.none": "フォルダーをå†åº¦é–‹ãã¾ã›ã‚“。", - "window.reopenFolders.one": "最後ã«ã‚¢ã‚¯ãƒ†ã‚£ãƒ–ã ã£ãŸãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã‚’å†ã³é–‹ãã¾ã™ã€‚", - "window.reopenFolders.all": "最後ã®ã‚»ãƒƒã‚·ãƒ§ãƒ³ã®å…¨ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã‚’å†ã³é–‹ãã¾ã™ã€‚", - "reopenFolders": "å†èµ·å‹•å¾Œã«ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã‚’å†åº¦é–‹ã方法を制御ã—ã¾ã™ã€‚'none' ã‚’é¸æŠžã™ã‚‹ã¨ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã‚’å†åº¦é–‹ãã“ã¨ã¯ã‚ã‚Šã¾ã›ã‚“。'one' ã‚’é¸æŠžã™ã‚‹ã¨æœ€å¾Œã«ä½œæ¥­ã—ãŸãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã‚’å†åº¦é–‹ãã¾ã™ã€‚'all' ã‚’é¸æŠžã™ã‚‹ã¨å‰å›žã®ã‚»ãƒƒã‚·ãƒ§ãƒ³ã®ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã™ã¹ã¦ã‚’å†åº¦é–‹ãã¾ã™ã€‚", "restoreFullscreen": "全画é¢è¡¨ç¤ºãƒ¢ãƒ¼ãƒ‰ã§çµ‚了ã—ãŸå ´åˆã«ã€ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã‚’全画é¢è¡¨ç¤ºãƒ¢ãƒ¼ãƒ‰ã«å¾©å…ƒã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚", "zoomLevel": "ウィンドウã®ã‚ºãƒ¼ãƒ  レベルを調整ã—ã¾ã™ã€‚å…ƒã®ã‚µã‚¤ã‚ºã¯ 0 ã§ã€1 ã¤ä¸Šã’ã‚‹ã”ã¨ã« (1 ãªã©) 20% ãšã¤æ‹¡å¤§ã™ã‚‹ã“ã¨ã‚’表ã—ã€1 ã¤ä¸‹ã’ã‚‹ã”ã¨ã« (-1 ãªã©) 20% ãšã¤ç¸®å°ã™ã‚‹ã“ã¨ã‚’表ã—ã¾ã™ã€‚å°æ•°ç‚¹ä»¥ä¸‹ã®æ¡æ•°ã‚’入力ã—ã¦ã€ã•ã‚‰ã«ç´°ã‹ãズーム レベルを調整ã™ã‚‹ã“ã¨ã‚‚ã§ãã¾ã™ã€‚", "title": "アクティブãªã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã«åŸºã¥ã„ã¦ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã®ã‚¿ã‚¤ãƒˆãƒ«ã‚’制御ã—ã¾ã™ã€‚変数ã¯ã€ã‚³ãƒ³ãƒ†ã‚­ã‚¹ãƒˆã«åŸºã¥ã„ã¦ç½®æ›ã•ã‚Œã¾ã™:\n${activeEditorShort}: 例: myFile.txt\n${activeEditorMedium}: 例: myFolder/myFile.txt\n${activeEditorLong}: 例: /Users/Development/myProject/myFolder/myFile.txt\n${rootName}: 例: myProject\n${rootPath}: 例: /Users/Development/myProject\n${appName}: 例: VS Code\n${dirty}: アクティブãªã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ãŒãƒ€ãƒ¼ãƒ†ã‚£ã§ã‚ã‚‹å ´åˆã®ãƒ€ãƒ¼ãƒ†ã‚£ インジケーター\n${separator}: 値ã®ã‚る変数ã§å›²ã¾ã‚ŒãŸå ´åˆã«ã®ã¿è¡¨ç¤ºã•ã‚Œã‚‹æ¡ä»¶ä»˜ãåŒºåˆ‡ã‚Šè¨˜å· (\" - \")", @@ -58,5 +54,7 @@ "zenMode.hideTabs": "Zen Mode をオンã«ã—ãŸã¨ãã«ãƒ¯ãƒ¼ã‚¯ãƒ™ãƒ³ãƒ タブもéžè¡¨ç¤ºã«ã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚", "zenMode.hideStatusBar": "Zen Mode をオンã«ã™ã‚‹ã¨ãƒ¯ãƒ¼ã‚¯ãƒ™ãƒ³ãƒã®ä¸‹éƒ¨ã«ã‚るステータス ãƒãƒ¼ã‚’éžè¡¨ç¤ºã«ã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚", "zenMode.hideActivityBar": "Zen Mode をオンã«ã™ã‚‹ã¨ãƒ¯ãƒ¼ã‚¯ãƒ™ãƒ³ãƒã®å·¦å´ã«ã‚るアクティビティ ãƒãƒ¼ã‚’éžè¡¨ç¤ºã«ã™ã‚‹ã‹ã‚’制御ã—ã¾ã™ã€‚", - "zenMode.restore": "Zen Mode ã§çµ‚了ã—ãŸã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã‚’ Zen Mode ã«å¾©å…ƒã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚" + "zenMode.restore": "Zen Mode ã§çµ‚了ã—ãŸã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã‚’ Zen Mode ã«å¾©å…ƒã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚", + "workspaceConfigurationTitle": "ワークスペース", + "files.exclude.boolean": "ファイル パスã®ç…§åˆåŸºæº–ã¨ãªã‚‹ glob パターン。ã“れを true ã¾ãŸã¯ false ã«è¨­å®šã™ã‚‹ã¨ã€ãƒ‘ターンãŒãã‚Œãžã‚Œæœ‰åŠ¹/無効ã«ãªã‚Šã¾ã™ã€‚" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json b/i18n/jpn/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json new file mode 100644 index 00000000000..1c53dd86bdd --- /dev/null +++ b/i18n/jpn/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json @@ -0,0 +1,26 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "emergencyConfOn": "ç¾åœ¨ `editor.accessibilitySupport` 設定を 'on' ã«å¤‰æ›´ã—ã¦ã„ã¾ã™ã€‚", + "openingDocs": "ç¾åœ¨ VS Code ã®ã‚¢ã‚¯ã‚»ã‚·ãƒ“リティ ドキュメントページを開ã„ã¦ã„ã¾ã™ã€‚", + "introMsg": "VS Code ã®ã‚¢ã‚¯ã‚»ã‚·ãƒ“リティ オプションをã”利用ã„ãŸã ãã€ã‚ã‚ŠãŒã¨ã†ã”ã–ã„ã¾ã™ã€‚", + "status": "ステータス:", + "changeConfigToOnMac": "スクリーン リーダーã§ä½¿ç”¨ã™ã‚‹ãŸã‚ã«ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã‚’永続的ã«æœ€é©åŒ–ã™ã‚‹ã‚ˆã†ã«è¨­å®šã™ã‚‹ã«ã¯ã€Command + E を押ã—ã¦ãã ã•ã„。", + "changeConfigToOnWinLinux": "スクリーン リーダーã§ä½¿ç”¨ã™ã‚‹ãŸã‚ã«ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã‚’永続的ã«æœ€é©åŒ–ã™ã‚‹ã‚ˆã†ã«è¨­å®šã™ã‚‹ã«ã¯ã€Control + E を押ã—ã¦ãã ã•ã„。", + "auto_unknown": "エディターã¯ã€ãƒ—ラットフォーム API を使用ã—ã¦ã‚¹ã‚¯ãƒªãƒ¼ãƒ³ リーダーãŒã„ã¤æŽ¥ç¶šã•ã‚ŒãŸã‹ã‚’検出ã™ã‚‹ã‚ˆã†ã«è¨­å®šã•ã‚Œã¦ã„ã¾ã™ãŒã€ç¾åœ¨ã®ãƒ©ãƒ³ã‚¿ã‚¤ãƒ ã¯ã“れをサãƒãƒ¼ãƒˆã—ã¦ã„ã¾ã›ã‚“。", + "auto_on": "エディターã¯ã‚¹ã‚¯ãƒªãƒ¼ãƒ³ リーダーã®æŽ¥ç¶šã‚’自動検出ã—ã¾ã—ãŸã€‚", + "auto_off": "エディターã¯ã€ã‚¹ã‚¯ãƒªãƒ¼ãƒ³ リーダーãŒæŽ¥ç¶šã•ã‚Œã‚‹ã¨è‡ªå‹•çš„ã«æ¤œå‡ºã™ã‚‹ã‚ˆã†ã«æ§‹æˆã•ã‚Œã¦ã„ã¾ã™ãŒã€ä»Šå›žã¯æ¤œå‡ºã§ãã¾ã›ã‚“ã§ã—ãŸã€‚", + "configuredOn": "エディターã¯ã‚¹ã‚¯ãƒªãƒ¼ãƒ³ リーダーã§ä½¿ç”¨ã™ã‚‹ãŸã‚ã«æ°¸ç¶šçš„ã«æœ€é©åŒ–ã•ã‚Œã‚‹ã‚ˆã†ã«è¨­å®šã•ã‚Œã¦ã„ã¾ã™ã€‚ã“れ㯠`editor.accessibilitySupport` ã®è¨­å®šã‚’編集ã™ã‚‹ã“ã¨ã§å¤‰æ›´ã§ãã¾ã™ã€‚", + "configuredOff": "エディターã¯ã‚¹ã‚¯ãƒªãƒ¼ãƒ³ リーダーå‘ã‘ã«æœ€é©åŒ–ã—ãªã„よã†ã«æ§‹æˆã•ã‚Œã¦ã„ã¾ã™ã€‚", + "tabFocusModeOnMsg": "ç¾åœ¨ã®ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã§ Tab キーを押ã™ã¨ã€æ¬¡ã®ãƒ•ã‚©ãƒ¼ã‚«ã‚¹å¯èƒ½ãªè¦ç´ ã«ãƒ•ã‚©ãƒ¼ã‚«ã‚¹ã‚’移動ã—ã¾ã™ã€‚{0} を押ã™ã¨ã€ã“ã®å‹•ä½œãŒåˆ‡ã‚Šæ›¿ã‚ã‚Šã¾ã™ã€‚", + "tabFocusModeOnMsgNoKb": "ç¾åœ¨ã®ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã§ Tab キーを押ã™ã¨ã€æ¬¡ã®ãƒ•ã‚©ãƒ¼ã‚«ã‚¹å¯èƒ½ãªè¦ç´ ã«ãƒ•ã‚©ãƒ¼ã‚«ã‚¹ã‚’移動ã—ã¾ã™ã€‚コマンド {0} ã¯ã€ã‚­ãƒ¼ ãƒã‚¤ãƒ³ãƒ‰ã§ã¯ç¾åœ¨ãƒˆãƒªã‚¬ãƒ¼ã§ãã¾ã›ã‚“。", + "tabFocusModeOffMsg": "ç¾åœ¨ã®ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã§ Tab キーを押ã™ã¨ã€ã‚¿ãƒ–文字ãŒæŒ¿å…¥ã•ã‚Œã¾ã™ã€‚{0} を押ã™ã¨ã€ã“ã®å‹•ä½œãŒåˆ‡ã‚Šæ›¿ã‚ã‚Šã¾ã™ã€‚", + "tabFocusModeOffMsgNoKb": "ç¾åœ¨ã®ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã§ Tab キーを押ã™ã¨ã€ã‚¿ãƒ–文字ãŒæŒ¿å…¥ã•ã‚Œã¾ã™ã€‚コマンド {0} ã¯ã€ã‚­ãƒ¼ ãƒã‚¤ãƒ³ãƒ‰ã§ã¯ç¾åœ¨ãƒˆãƒªã‚¬ãƒ¼ã§ãã¾ã›ã‚“。", + "openDocMac": "command + H キーを押ã—ã¦ã€ãƒ–ラウザー ウィンドウを今ã™ãé–‹ãã€ã‚¢ã‚¯ã‚»ã‚·ãƒ“リティã«é–¢é€£ã™ã‚‹ä»–ã® VS Code 情報を確èªã—ã¾ã™ã€‚", + "openDocWinLinux": "Ctrl + H キーを押ã—ã¦ã€ãƒ–ラウザー ウィンドウを今ã™ãé–‹ãã€ã‚¢ã‚¯ã‚»ã‚·ãƒ“リティã«é–¢é€£ã™ã‚‹ä»–ã® VS Code 情報を確èªã—ã¾ã™ã€‚", + "outroMsg": "Esc キー ã‹ Shift+Esc を押ã™ã¨ã€ãƒ’ントを消ã—ã¦ã‚¨ãƒ‡ã‚£ã‚¿ãƒ¼ã«æˆ»ã‚‹ã“ã¨ãŒã§ãã¾ã™ã€‚", + "ShowAccessibilityHelpAction": "アクセシビリティã®ãƒ˜ãƒ«ãƒ—を表示ã—ã¾ã™" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json b/i18n/jpn/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/jpn/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json b/i18n/jpn/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json new file mode 100644 index 00000000000..3b84ee3fdb4 --- /dev/null +++ b/i18n/jpn/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleLocation": "マルムカーソルã®ä¿®é£¾ã‚­ãƒ¼ã‚’切り替ãˆã‚‹" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json b/i18n/jpn/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json index fc8e32566a5..e6c7a195a3d 100644 --- a/i18n/jpn/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json @@ -5,16 +5,12 @@ // Do not edit this file. It is machine generated. { "variablesSection": "変数セクション", - "variables": "変数", "variablesAriaTreeLabel": "変数ã®ãƒ‡ãƒãƒƒã‚°", "expressionsSection": "å¼ã‚»ã‚¯ã‚·ãƒ§ãƒ³", - "watch": "ウォッãƒå¼", "watchAriaTreeLabel": "ウォッãƒå¼ã®ãƒ‡ãƒãƒƒã‚°", "callstackSection": "コール スタック セクション", "debugStopped": "{0} ã§ä¸€æ™‚åœæ­¢", - "callStack": "コール スタック", "callStackAriaLabel": "コール スタックã®ãƒ‡ãƒãƒƒã‚°", "breakpointsSection": "ブレークãƒã‚¤ãƒ³ãƒˆ セクション", - "breakpoints": "ブレークãƒã‚¤ãƒ³ãƒˆ", "breakpointsAriaTreeLabel": "デãƒãƒƒã‚° ブレークãƒã‚¤ãƒ³ãƒˆ" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json b/i18n/jpn/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json index cf9dccd3bbd..188f2a35673 100644 --- a/i18n/jpn/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json @@ -4,6 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "previousEditPoint": "Emmet: å‰ã®ç·¨é›†ç‚¹", - "nextEditPoint": "Emmet: 次ã®ç·¨é›†ç‚¹" + "previousEditPoint": "Emmet: å‰ã®ç·¨é›†ç‚¹ã«ç§»å‹•ã™ã‚‹", + "nextEditPoint": "Emmet: 次ã®ç·¨é›†ç‚¹ã«ç§»å‹•ã™ã‚‹" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json b/i18n/jpn/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json index f8b16e8c78d..470a456bc9d 100644 --- a/i18n/jpn/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json @@ -9,5 +9,6 @@ "emmetPreferences": "Emmet ã®ä¸€éƒ¨ã®ã‚¢ã‚¯ã‚·ãƒ§ãƒ³ã‚„リゾルãƒãƒ¼ã®å‹•ä½œã®å¤‰æ›´ã«ä½¿ç”¨ã•ã‚Œã‚‹åŸºæœ¬è¨­å®šã€‚", "emmetSyntaxProfiles": "指定ã—ãŸæ§‹æ–‡ã«å¯¾ã—ã¦ãƒ—ロファイルを定義ã™ã‚‹ã‹ã€ç‰¹å®šã®è¦å‰‡ãŒã‚る独自ã®ãƒ—ロファイルをã”使用ãã ã•ã„。", "emmetExclude": "emmet çœç•¥è¨˜æ³•ã‚’展開ã™ã¹ãã§ãªã„言語ã®é…列。", - "emmetExtensionsPath": "Emmet ã®ãƒ—ロファイルã€ã‚¹ãƒ‹ãƒšãƒƒãƒˆã€åŸºæœ¬è¨­å®šã‚’å«ã‚€ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã¸ã®ãƒ‘ス" + "emmetExtensionsPath": "Emmet ã®ãƒ—ロファイルã€ã‚¹ãƒ‹ãƒšãƒƒãƒˆã€åŸºæœ¬è¨­å®šã‚’å«ã‚€ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã¸ã®ãƒ‘ス", + "useNewEmmet": "ã™ã¹ã¦ã® emmet 機能ã«å¯¾ã—ã¦ã€æ–°ã—ã„ emmet モジュールをãŠè©¦ã—ãã ã•ã„ (最終的ã«ã€ä»¥å‰ã®å˜ä¸€ emmet ライブラリã¯ç½®ãæ›ãˆã‚‰ã‚Œã¾ã™)。" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json b/i18n/jpn/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json index 078b21ede6a..631dbad18af 100644 --- a/i18n/jpn/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json @@ -24,6 +24,10 @@ "default": "既定", "debuggers": "デãƒãƒƒã‚¬ãƒ¼ ({0})", "debugger name": "åå‰", + "views": "ビュー ({0})", + "view id": "ID", + "view name": "åå‰", + "view location": "場所", "themes": "テーマ ({0})", "JSON Validation": "JSON 検証 ({0})", "commands": "コマンド ({0})", diff --git a/i18n/jpn/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json b/i18n/jpn/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json index 51044b7942e..d37634ee485 100644 --- a/i18n/jpn/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json @@ -27,11 +27,11 @@ "updateAll": "ã™ã¹ã¦ã®æ‹¡å¼µæ©Ÿèƒ½ã‚’æ›´æ–°ã—ã¾ã™", "reloadAction": "å†èª­ã¿è¾¼ã¿", "postUpdateTooltip": "å†èª­ã¿è¾¼ã¿ã—ã¦æ›´æ–°ã™ã‚‹", - "postUpdateMessage": "ã“ã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã‚’å†åº¦èª­ã¿è¾¼ã‚“ã§ã€æ›´æ–°æ¸ˆã¿ã®æ‹¡å¼µæ©Ÿèƒ½ '{0}' をアクティブ化ã—ã¾ã™ã‹?", - "postEnableTooltip": "å†åº¦èª­ã¿è¾¼ã‚“ã§ã‚¢ã‚¯ãƒ†ã‚£ãƒ–ã«ã™ã‚‹", + "postUpdateMessage": "ã“ã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã‚’å†èª­ã¿è¾¼ã¿ã—ã¦ã€æ›´æ–°æ¸ˆã¿ã®æ‹¡å¼µæ©Ÿèƒ½ '{0}' をアクティブ化ã—ã¾ã™ã‹?", + "postEnableTooltip": "å†èª­ã¿è¾¼ã¿ã—ã¦ã‚¢ã‚¯ãƒ†ã‚£ãƒ–ã«ã™ã‚‹", "postEnableMessage": "ã“ã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã‚’å†åº¦èª­ã¿è¾¼ã‚“ã§ã€æ‹¡å¼µæ©Ÿèƒ½ '{0}' をアクティブ化ã—ã¾ã™ã‹?", - "postDisableTooltip": "読ã¿è¾¼ã‚“ã§éžã‚¢ã‚¯ãƒ†ã‚£ãƒ–化ã™ã‚‹", - "postDisableMessage": "ã“ã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã‚’å†åº¦èª­ã¿è¾¼ã‚“ã§ã€æ‹¡å¼µæ©Ÿèƒ½ '{0}' ã‚’éžã‚¢ã‚¯ãƒ†ã‚£ãƒ–化ã—ã¾ã™ã‹?", + "postDisableTooltip": "å†èª­ã¿è¾¼ã¿ã—ã¦éžã‚¢ã‚¯ãƒ†ã‚£ãƒ–化ã™ã‚‹", + "postDisableMessage": "ã“ã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã‚’å†èª­ã¿è¾¼ã¿ã—ã¦ã€æ‹¡å¼µæ©Ÿèƒ½ '{0}' ã‚’éžã‚¢ã‚¯ãƒ†ã‚£ãƒ–化ã—ã¾ã™ã‹?", "postUninstallTooltip": "å†èª­ã¿è¾¼ã¿ã—ã¦éžã‚¢ã‚¯ãƒ†ã‚£ãƒ–化ã™ã‚‹", "postUninstallMessage": "ã“ã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã‚’å†åº¦èª­ã¿è¾¼ã‚“ã§ã€ã‚¢ãƒ³ã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«æ¸ˆã¿ã®æ‹¡å¼µæ©Ÿèƒ½ '{0}' ã‚’éžã‚¢ã‚¯ãƒ†ã‚£ãƒ–化ã—ã¾ã™ã‹?", "reload": "ウィンドウã®å†èª­ã¿è¾¼ã¿(&&R)", diff --git a/i18n/jpn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/jpn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index a23d7187ba2..5d17c064fd1 100644 --- a/i18n/jpn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -28,7 +28,6 @@ "watcherExclude": "ファイル モニタリングã‹ã‚‰é™¤å¤–ã™ã‚‹ãƒ•ã‚¡ã‚¤ãƒ« パス㮠glob パターンを構æˆã—ã¾ã™ã€‚ã“ã®è¨­å®šã‚’変更ã™ã‚‹ã¨ã€å†èµ·å‹•ãŒå¿…è¦ã«ãªã‚Šã¾ã™ã€‚始動時㫠Code ãŒæ¶ˆè²»ã™ã‚‹ CPU 時間ãŒå¤šã„å ´åˆã¯ã€å¤§è¦æ¨¡ãªãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã‚’除外ã—ã¦åˆæœŸãƒ­ãƒ¼ãƒ‰ã‚’減らã›ã¾ã™ã€‚", "hotExit.off": "Hot Exit を無効ã«ã—ã¾ã™ã€‚", "hotExit.onExit": "アプリケーションãŒé–‰ã˜ã‚‹ã¨ (Windows/Linux ã§æœ€å¾Œã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ãŒé–‰ã˜ã‚‹ã¨ãã€ã¾ãŸã¯ workbench.action.quit コマンドãŒãƒˆãƒªã‚¬ãƒ¼ã•ã‚Œã‚‹ã¨ã (コマンド パレットã€ã‚­ãƒ¼ ãƒã‚¤ãƒ³ãƒ‰ã€ãƒ¡ãƒ‹ãƒ¥ãƒ¼))ã€Hot Exit ãŒãƒˆãƒªã‚¬ãƒ¼ã•ã‚Œã¾ã™ã€‚ãƒãƒƒã‚¯ã‚¢ãƒƒãƒ—ã•ã‚Œã¦ã„ã‚‹ã™ã¹ã¦ã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã¯ã€æ¬¡ã®èµ·å‹•æ™‚ã«å¾©å…ƒã•ã‚Œã¾ã™ã€‚", - "hotExit.onExitAndWindowClose": "アプリケーションãŒé–‰ã˜ã‚‹ã¨ (Windows/Linux ã§æœ€å¾Œã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ãŒé–‰ã˜ã‚‹ã¨ãã€ã¾ãŸã¯ workbench.action.quit コマンドãŒãƒˆãƒªã‚¬ãƒ¼ã™ã‚‹ã¨ã (コマンド パレットã€ã‚­ãƒ¼ ãƒã‚¤ãƒ³ãƒ‰ã€ãƒ¡ãƒ‹ãƒ¥ãƒ¼))ã€Hot Exit ãŒãƒˆãƒªã‚¬ãƒ¼ã•ã‚Œã¾ã™ã€‚ã¾ãŸã€ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ãŒé–‹ã‹ã‚Œã¦ã„るウィンドウã«ã¤ã„ã¦ã‚‚ã€ãã‚ŒãŒæœ€å¾Œã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã‹ã©ã†ã‹ã«é–¢ä¿‚ãªãã€Hot Exit ãŒãƒˆãƒªã‚¬ãƒ¼ã•ã‚Œã¾ã™ã€‚フォルダーãŒé–‹ã‹ã‚Œã¦ã„ãªã„ウィンドウã¯ã™ã¹ã¦ã€æ¬¡å›žã®èµ·å‹•æ™‚ã«å¾©å…ƒã•ã‚Œã¾ã™ã€‚フォルダーã®ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã‚’シャットダウンå‰ã¨åŒã˜çŠ¶æ…‹ã«å¾©å…ƒã™ã‚‹ã«ã¯ã€\"window.reopenFolders\" ã‚’ \"all\" ã«è¨­å®šã—ã¾ã™ã€‚", "hotExit": "エディターを終了ã™ã‚‹ã¨ãã«ä¿å­˜ã‚’確èªã™ã‚‹ãƒ€ã‚¤ã‚¢ãƒ­ã‚°ã‚’çœç•¥ã—ã€ä¿å­˜ã•ã‚Œã¦ã„ãªã„ファイルをセッション後もä¿æŒã™ã‚‹ã‹ã©ã†ã‹ã‚’制御ã—ã¾ã™ã€‚", "defaultLanguage": "æ–°ã—ã„ファイルã«å‰²ã‚Šå½“ã¦ã‚‰ã‚Œã‚‹æ—¢å®šã®è¨€èªžãƒ¢ãƒ¼ãƒ‰ã€‚", "editorConfigurationTitle": "エディター", diff --git a/i18n/jpn/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json b/i18n/jpn/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json index b6fe55337f3..6caca19da44 100644 --- a/i18n/jpn/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json @@ -5,7 +5,5 @@ // Do not edit this file. It is machine generated. { "explorerSection": "ファイル エクスプローラー セクション", - "noWorkspace": "é–‹ã„ã¦ã„るフォルダーãŒã‚ã‚Šã¾ã›ã‚“", - "noWorkspaceHelp": "ã¾ã ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ã‚’é–‹ã„ã¦ã„ã¾ã›ã‚“。", "openFolder": "フォルダーを開ã" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json b/i18n/jpn/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json index e97af3104a2..489a4baaeeb 100644 --- a/i18n/jpn/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json @@ -4,8 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "openEditosrSection": "[é–‹ã„ã¦ã„るエディター] セクション", "openEditors": "é–‹ã„ã¦ã„るエディター", + "openEditosrSection": "[é–‹ã„ã¦ã„るエディター] セクション", "treeAriaLabel": "é–‹ã„ã¦ã„るエディター: アクティブãªãƒ•ã‚¡ã‚¤ãƒ«ã®ãƒªã‚¹ãƒˆ", "dirtyCounter": "未ä¿å­˜ ({0})" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/jpn/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json index e556fff23e6..a4fef8cf3c0 100644 --- a/i18n/jpn/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -5,5 +5,7 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.start": "キー ãƒã‚¤ãƒ³ãƒ‰ã®å®šç¾©", - "defineKeybinding.kbLayoutErrorMessage": "ç¾åœ¨ã®ã‚­ãƒ¼ãƒœãƒ¼ãƒ‰ レイアウトã§ã¯ã€ã“ã®ã‚­ãƒ¼ã®çµ„ã¿åˆã‚ã›ã‚’生æˆã™ã‚‹ã“ã¨ã¯ã§ãã¾ã›ã‚“。" + "defineKeybinding.kbLayoutErrorMessage": "ç¾åœ¨ã®ã‚­ãƒ¼ãƒœãƒ¼ãƒ‰ レイアウトã§ã¯ã€ã“ã®ã‚­ãƒ¼ã®çµ„ã¿åˆã‚ã›ã‚’生æˆã™ã‚‹ã“ã¨ã¯ã§ãã¾ã›ã‚“。", + "defineKeybinding.kbLayoutLocalAndUSMessage": "ç¾åœ¨ã®ã‚­ãƒ¼ãƒœãƒ¼ãƒ‰ レイアウトã§ç¤ºã™ã¨ **{0}** ã§ã™ã€‚(US 標準: **{1}**)", + "defineKeybinding.kbLayoutLocalMessage": "ç¾åœ¨ã®ã‚­ãƒ¼ãƒœãƒ¼ãƒ‰ レイアウトã§ç¤ºã™ã¨ **{0}** ã§ã™ã€‚" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json b/i18n/jpn/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json new file mode 100644 index 00000000000..6024752558c --- /dev/null +++ b/i18n/jpn/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "relaunchMessage": "å†èµ·å‹•ãŒå¿…è¦ãªè¨­å®šã‚’変更ã—ã¾ã—ãŸã€‚", + "relaunchDetail": "{0} ã‚’å†èµ·å‹•ãƒœã‚¿ãƒ³ã§å†èµ·å‹•ã—ã¦ã€è¨­å®šã‚’有効ã«ã—ã¦ãã ã•ã„。", + "restart": "å†èµ·å‹•" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json b/i18n/jpn/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json index dbc7f6d6a36..8f9586b85f4 100644 --- a/i18n/jpn/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json @@ -11,6 +11,6 @@ "snippetSchema.json.default": "空ã®ã‚¹ãƒ‹ãƒšãƒƒãƒˆ", "snippetSchema.json": "ユーザー スニペット構æˆ", "snippetSchema.json.prefix": "intellisense ã§ã‚¹ãƒ‹ãƒšãƒƒãƒˆã‚’é¸æŠžã™ã‚‹ã¨ãã«ä½¿ç”¨ã™ã‚‹ãƒ—レフィックス", - "snippetSchema.json.body": "スニペットã®å†…容。変数ã«ã¯ '${id}'ã€'${id:label}'ã€'${1:label}' を使用ã—ã€ã‚«ãƒ¼ã‚½ãƒ«ä½ç½®ã«ã¯ '$0'ã€'$1' を使用ã—ã¾ã™", + "snippetSchema.json.body": "スニペットã®ã‚³ãƒ³ãƒ†ãƒ³ãƒ„ã§ã™ã€‚カーソルã®ä½ç½®ã‚’定義ã™ã‚‹ã«ã¯ '$1', '${1:defaultText}' を使用ã—ã€æœ€å¾Œã®ã‚«ãƒ¼ã‚½ãƒ«ã®ä½ç½®ã«ã¯ '$0' を使用ã—ã¾ã™ã€‚'${varName}' 㨠'${varName:defaultText}' を使用ã™ã‚‹ã¨å¤‰æ•°å€¤ã‚’挿入ã—ã¾ã™ã€‚例: 'This is file: $TM_FILENAME'.", "snippetSchema.json.description": "スニペットã«ã¤ã„ã¦ã®è¨˜è¿°ã€‚" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json b/i18n/jpn/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json new file mode 100644 index 00000000000..fef6bb6566b --- /dev/null +++ b/i18n/jpn/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "helpUs": "{0} ã®ã‚µãƒãƒ¼ãƒˆã®æ”¹å–„ã«ã”å”力ãã ã•ã„", + "takeShortSurvey": "ç°¡å˜ãªã‚¢ãƒ³ã‚±ãƒ¼ãƒˆã®å®Ÿæ–½", + "remindLater": "後ã§é€šçŸ¥ã™ã‚‹", + "neverAgain": "今後ã¯è¡¨ç¤ºã—ãªã„" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json b/i18n/jpn/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json new file mode 100644 index 00000000000..1b0a91d1c83 --- /dev/null +++ b/i18n/jpn/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "surveyQuestion": "短ã„フィードãƒãƒƒã‚¯ アンケートã«ã”å”力をãŠé¡˜ã„ã§ãã¾ã™ã‹?", + "takeSurvey": "アンケートã®å®Ÿæ–½", + "remindLater": "後ã§é€šçŸ¥ã™ã‚‹", + "neverAgain": "今後ã¯è¡¨ç¤ºã—ãªã„" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json new file mode 100644 index 00000000000..ac80aac08cd --- /dev/null +++ b/i18n/jpn/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noTasksMatching": "一致ã™ã‚‹ã‚¿ã‚¹ã‚¯ãŒã‚ã‚Šã¾ã›ã‚“" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index c0432625724..06f2b5a47d5 100644 --- a/i18n/jpn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0}, tasks" + "entryAriaLabel": "{0}, tasks", + "customizeTask": "タスクã®ã‚«ã‚¹ã‚¿ãƒžã‚¤ã‚º" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json new file mode 100644 index 00000000000..ac80aac08cd --- /dev/null +++ b/i18n/jpn/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noTasksMatching": "一致ã™ã‚‹ã‚¿ã‚¹ã‚¯ãŒã‚ã‚Šã¾ã›ã‚“" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json index fbd42ea691d..f4de865e7e8 100644 --- a/i18n/jpn/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -12,5 +12,6 @@ "ConfigurationParser.invalidVaraibleReference": "エラー: æ­£ã—ããªã„ problemMatcher å‚ç…§ {0}\n", "ConfigurationParser.noTaskName": "エラー: タスク㌠taskName プロパティをæä¾›ã—ãªã‘ã‚Œã°ãªã‚Šã¾ã›ã‚“。ã“ã®ã‚¿ã‚¹ã‚¯ã¯ç„¡è¦–ã•ã‚Œã¾ã™ã€‚\n{0}\n", "taskConfiguration.shellArgs": "警告: タスク '{0}' ã¯ã‚·ã‚§ãƒ« コマンドã§ã™ã€‚コマンドåã¾ãŸã¯å¼•æ•°ã® 1 ã¤ã«ã€ã‚¨ã‚¹ã‚±ãƒ¼ãƒ—ã•ã‚Œã¦ã„ãªã„スペースãŒå«ã¾ã‚Œã¦ã„ã¾ã™ã€‚コマンド ラインã®å¼•ç”¨ãŒæ­£ã—ã解釈ã•ã‚Œã‚‹ã‚ˆã†ã«ã€å¼•æ•°ã‚’コマンドã«ãƒžãƒ¼ã‚¸ã—ã¦ãã ã•ã„。", + "taskConfiguration.noCommandOrDependsOn": "エラー: タスク '{0}' ã¯ã€ã‚³ãƒžãƒ³ãƒ‰ã‚‚ dependsOn プロパティも指定ã—ã¦ã„ã¾ã›ã‚“。ã“ã®ã‚¿ã‚¹ã‚¯ã¯ç„¡è¦–ã•ã‚Œã¾ã™ã€‚定義ã¯æ¬¡ã®ã¨ãŠã‚Šã§ã™:\n{1}", "taskConfiguration.noCommand": "エラー: タスク '{0}' ã¯ã‚³ãƒžãƒ³ãƒ‰ã‚’定義ã—ã¦ã„ã¾ã›ã‚“。ã“ã®ã‚¿ã‚¹ã‚¯ã¯ç„¡è¦–ã•ã‚Œã¾ã™ã€‚定義ã¯æ¬¡ã®ã¨ãŠã‚Šã§ã™:\n{1}" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json index 522b6ddc0ea..c0f160530b6 100644 --- a/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json @@ -7,6 +7,7 @@ "JsonSchema.options": "追加ã®ã‚³ãƒžãƒ³ãƒ‰ オプション", "JsonSchema.options.cwd": "実行ã•ã‚Œã‚‹ãƒ—ログラムã¾ãŸã¯ã‚¹ã‚¯ãƒªãƒ—トã®ç¾åœ¨ã®ä½œæ¥­ãƒ‡ã‚£ãƒ¬ã‚¯ãƒˆãƒªã€‚çœç•¥ã™ã‚‹ã¨ã€Code ã®ç¾åœ¨ã®ãƒ¯ãƒ¼ã‚¯ã‚¹ãƒšãƒ¼ã‚¹ã®ãƒ«ãƒ¼ãƒˆãŒä½¿ç”¨ã•ã‚Œã¾ã™ã€‚", "JsonSchema.options.env": "実行ã•ã‚Œã‚‹ãƒ—ログラムã¾ãŸã¯ã‚·ã‚§ãƒ«ã®ç’°å¢ƒã€‚çœç•¥ã™ã‚‹ã¨ã€è¦ªãƒ—ロセスã®ç’°å¢ƒãŒä½¿ç”¨ã•ã‚Œã¾ã™ã€‚", + "JsonSchema.shellConfiguration": "使用ã™ã‚‹ã‚·ã‚§ãƒ«ã‚’構æˆã—ã¾ã™ã€‚", "JsonSchema.shell.executable": "使用ã™ã‚‹ã‚·ã‚§ãƒ«ã€‚", "JsonSchema.shell.args": "シェル引数。", "JsonSchema.command": "実行ã•ã‚Œã‚‹ã‚³ãƒžãƒ³ãƒ‰ã€‚外部プログラムã‹ã‚·ã‚§ãƒ« コマンドã§ã™ã€‚", diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json index d4e5894c8b6..fec9e120674 100644 --- a/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json @@ -5,6 +5,8 @@ // Do not edit this file. It is machine generated. { "JsonSchema.version": "構æˆã®ãƒãƒ¼ã‚¸ãƒ§ãƒ³ç•ªå·", + "JsonSchema._runner": "ランナーãŒæ–°ã—ããªã‚Šã¾ã™ã€‚æ­£å¼ãªãƒ©ãƒ³ãƒŠãƒ¼ãƒ—ロパティーを使用ã—ã¦ãã ã•ã„", + "JsonSchema.runner": "タスクをプロセスã¨ã—ã¦å®Ÿè¡Œã—ã¦ã€å‡ºåŠ›ãŒå‡ºåŠ›ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ã¾ãŸã¯ç«¯æœ«å†…ã«è¡¨ç¤ºã•ã‚Œã‚‹ã‹ã©ã†ã‹ã‚’定義ã—ã¾ã™ã€‚", "JsonSchema.windows": "Windows 固有ã®ã‚³ãƒžãƒ³ãƒ‰æ§‹æˆ", "JsonSchema.mac": "Mac 固有ã®ã‚³ãƒžãƒ³ãƒ‰æ§‹æˆ", "JsonSchema.linux": "Linux 固有ã®ã‚³ãƒžãƒ³ãƒ‰æ§‹æˆ", diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json index 063435e42d5..2b0fd3079f1 100644 --- a/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -7,6 +7,10 @@ "JsonSchema.shell": "コマンドãŒã‚·ã‚§ãƒ« コマンドã‹å¤–部プログラムã‹ã‚’指定ã—ã¾ã™ã€‚çœç•¥ã™ã‚‹ã¨ã€æ—¢å®šã¯ false ã«ãªã‚Šã¾ã™ã€‚", "JsonSchema.tasks.dependsOn.string": "ã“ã®ã‚¿ã‚¹ã‚¯ãŒä¾å­˜ã—ã¦ã„る別ã®ã‚¿ã‚¹ã‚¯ã€‚", "JsonSchema.tasks.dependsOn.array": "ã“ã®ã‚¿ã‚¹ã‚¯ãŒä¾å­˜ã—ã¦ã„ã‚‹ä»–ã®è¤‡æ•°ã®ã‚¿ã‚¹ã‚¯ã€‚", + "JsonSchema.tasks.group": "ã“ã®ã‚¿ã‚¹ã‚¯ãŒå±žã™ã‚‹å®Ÿè¡Œã‚°ãƒ«ãƒ¼ãƒ—を定義ã—ã¾ã™ã€‚çœç•¥ã—ãŸå ´åˆã€ã‚¿ã‚¹ã‚¯ã¯ã‚°ãƒ«ãƒ¼ãƒ—ã«å±žã—ã¾ã›ã‚“。", + "JsonSchema.tasks.type": "タスクをプロセスã¨ã—ã¦å®Ÿè¡Œã™ã‚‹ã‹ã€ã¾ãŸã¯ã‚·ã‚§ãƒ«å†…部ã§ã‚³ãƒžãƒ³ãƒ‰ã¨ã—ã¦å®Ÿè¡Œã™ã‚‹ã‹ã©ã†ã‹ã‚’定義ã—ã¾ã™ã€‚既定㯠process ã§ã™ã€‚", + "JsonSchema.version": "構æˆã®ãƒãƒ¼ã‚¸ãƒ§ãƒ³ç•ªå·", + "JsonSchema.tasks.customize": "カスタマイズ対象ã®æä¾›ã•ã‚ŒãŸã‚¿ã‚¹ã‚¯ã€‚", "JsonSchema.windows": "Windows 固有ã®ã‚³ãƒžãƒ³ãƒ‰æ§‹æˆ", "JsonSchema.mac": "Mac 固有ã®ã‚³ãƒžãƒ³ãƒ‰æ§‹æˆ", "JsonSchema.linux": "Linux 固有ã®ã‚³ãƒžãƒ³ãƒ‰æ§‹æˆ" diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json index 81375f18706..4d056135a7a 100644 --- a/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json @@ -22,7 +22,8 @@ "TaskService.noBuildTask": "ビルド タスクãŒå®šç¾©ã•ã‚Œã¦ã„ã¾ã›ã‚“。tasks.json ファイルã§ã‚¿ã‚¹ã‚¯ã« 'isBuildCommand' ã¨ã„ã†ãƒžãƒ¼ã‚¯ã‚’付ã‘ã¦ãã ã•ã„。", "TaskService.noTestTask": "テスト タスクãŒå®šç¾©ã•ã‚Œã¦ã„ã¾ã›ã‚“。tasks.json ファイルã§ã‚¿ã‚¹ã‚¯ã« 'isTestCommand' ã¨ã„ã†ãƒžãƒ¼ã‚¯ã‚’付ã‘ã¦ãã ã•ã„。", "TaskServer.noTask": "実行ãŒè¦æ±‚ã•ã‚ŒãŸã‚¿ã‚¹ã‚¯ {0} ãŒè¦‹ã¤ã‹ã‚Šã¾ã›ã‚“。", - "TaskSystem.activeSame": "タスクã¯æ—¢ã«ã‚¢ã‚¯ãƒ†ã‚£ãƒ–ãŠã‚ˆã³ã‚¦ã‚©ãƒƒãƒ モードã«ãªã£ã¦ã„ã¾ã™ã€‚タスクを終了ã™ã‚‹ã«ã¯ã€`F1 > タスクã®çµ‚了` を使用ã—ã¾ã™", + "customizeParseErrors": "ç¾åœ¨ã®ã‚¿ã‚¹ã‚¯ã®æ§‹æˆã«ã¯ã‚¨ãƒ©ãƒ¼ãŒã‚ã‚Šã¾ã™ã€‚タスクをカスタマイズã™ã‚‹å‰ã«ã‚¨ãƒ©ãƒ¼ã‚’修正ã—ã¦ãã ã•ã„。", + "moreThanOneBuildTask": "tasks.json ã§è¤‡æ•°ã®ãƒ“ルド タスクãŒå®šç¾©ã•ã‚Œã¦ã„ã¾ã™ã€‚最åˆã®ã‚¿ã‚¹ã‚¯ã®ã¿ã‚’実行ã—ã¾ã™ã€‚\\n", "TaskSystem.active": "æ—¢ã«å®Ÿè¡Œä¸­ã®ã‚¿ã‚¹ã‚¯ãŒã‚ã‚Šã¾ã™ã€‚ã¾ãšã“ã®ã‚¿ã‚¹ã‚¯ã‚’終了ã—ã¦ã‹ã‚‰ã€åˆ¥ã®ã‚¿ã‚¹ã‚¯ã‚’実行ã—ã¦ãã ã•ã„。", "TaskSystem.restartFailed": "タスク {0} を終了ã—ã¦å†é–‹ã§ãã¾ã›ã‚“ã§ã—ãŸ", "TaskSystem.configurationErrors": "エラー: 指定ã—ãŸã‚¿ã‚¹ã‚¯æ§‹æˆã«æ¤œè¨¼ã‚¨ãƒ©ãƒ¼ãŒã‚ã‚Šã€ä½¿ç”¨ã§ãã¾ã›ã‚“。最åˆã«ã‚¨ãƒ©ãƒ¼ã‚’修正ã—ã¦ãã ã•ã„。", diff --git a/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json b/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json index 440b92fd91d..40f8e647676 100644 --- a/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json @@ -6,6 +6,7 @@ { "TerminalTaskSystem.unknownError": "タスクã®å®Ÿè¡Œä¸­ã«ä¸æ˜Žãªã‚¨ãƒ©ãƒ¼ãŒç™ºç”Ÿã—ã¾ã—ãŸã€‚詳細ã«ã¤ã„ã¦ã¯ã€ã‚¿ã‚¹ã‚¯å‡ºåŠ›ãƒ­ã‚°ã‚’å‚ç…§ã—ã¦ãã ã•ã„。", "TerminalTaskSystem.terminalName": "タスク - {0}", + "reuseTerminal": "端末ã¯ã‚¿ã‚¹ã‚¯ã§å†åˆ©ç”¨ã•ã‚Œã¾ã™ã€é–‰ã˜ã‚‹ã«ã¯ä»»æ„ã®ã‚­ãƒ¼ã‚’押ã—ã¦ãã ã•ã„。", "TerminalTaskSystem": "UNC ドライブã§ã‚·ã‚§ãƒ« コマンドを実行ã§ãã¾ã›ã‚“。", "unkownProblemMatcher": "å•é¡Œãƒžãƒƒãƒãƒ£ãƒ¼ {0} ã¯è§£æ±ºã§ãã¾ã›ã‚“ã§ã—ãŸã€‚マッãƒãƒ£ãƒ¼ã¯ç„¡è¦–ã•ã‚Œã¾ã™" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.i18n.json b/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.i18n.json index 11afc0e1f72..1288c0d2584 100644 --- a/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.i18n.json @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "terminalIntegratedConfigurationTitle": "çµ±åˆç«¯æœ«", + "terminalIntegratedConfigurationTitle": "çµ±åˆã‚¿ãƒ¼ãƒŸãƒŠãƒ«", "terminal.integrated.shell.linux": "ターミナル㌠Linux ã§ä½¿ç”¨ã™ã‚‹ã‚·ã‚§ãƒ«ã®ãƒ‘ス。", "terminal.integrated.shellArgs.linux": "Linux ã®ã‚¿ãƒ¼ãƒŸãƒŠãƒ«ã§ä½¿ç”¨ã™ã‚‹ã‚³ãƒžãƒ³ãƒ‰ ライン引数。", "terminal.integrated.shell.osx": "ターミナル㌠OS X ã§ä½¿ç”¨ã™ã‚‹ã‚·ã‚§ãƒ«ã®ãƒ‘ス。", @@ -24,7 +24,7 @@ "terminal.integrated.cwd": "端末を起動ã™ã‚‹æ˜Žç¤ºçš„ãªé–‹å§‹ãƒ‘スã§ã™ã€‚ã“ã‚Œã¯ã‚·ã‚§ãƒ« プロセスã®ç¾åœ¨ã®ä½œæ¥­ãƒ‡ã‚£ãƒ¬ã‚¯ãƒˆãƒª (cwd) ã¨ã—ã¦ä½¿ç”¨ã•ã‚Œã¾ã™ã€‚特ã«ãƒ«ãƒ¼ãƒˆ ディレクトリ㌠cwd ã«é©ã—ã¦ã„ãªã„å ´åˆã«ã€ãƒ¯ãƒ¼ã‚¯ã‚¹ãƒšãƒ¼ã‚¹ã®è¨­å®šã§å½¹ç«‹ã¡ã¾ã™ã€‚", "terminal.integrated.confirmOnExit": "アクティブãªã‚¿ãƒ¼ãƒŸãƒŠãƒ« セッションãŒã‚ã‚‹å ´åˆã«çµ‚了ã®ç¢ºèªã‚’ã™ã‚‹ã‹ã©ã†ã‹ã€‚", "terminal.integrated.commandsToSkipShell": "キーãƒã‚¤ãƒ³ãƒ‰ãŒã‚·ã‚§ãƒ«ã«é€ä¿¡ã•ã‚Œãšã€ä»£ã‚ã‚Šã«å¸¸ã« Code ã§å‡¦ç†ã•ã‚Œã‚‹ã‚³ãƒžãƒ³ãƒ‰ ID ã®ã‚»ãƒƒãƒˆã€‚ã“ã‚Œã«ã‚ˆã‚Šã€ã‚¿ãƒ¼ãƒŸãƒŠãƒ«ãŒãƒ•ã‚©ãƒ¼ã‚«ã‚¹ã•ã‚Œã¦ã„ãªã„å ´åˆã¨åŒã˜å‹•ä½œã‚’ã™ã‚‹ã‚·ã‚§ãƒ«ã«ã‚ˆã£ã¦é€šå¸¸ä½¿ç”¨ã•ã‚Œã‚‹ã‚­ãƒ¼ãƒã‚¤ãƒ³ãƒ‰ã‚’使用ã§ãるよã†ã«ãªã‚Šã¾ã™ã€‚例: Ctrl+p 㧠Quick Open ã‚’èµ·å‹•ã—ã¾ã™ã€‚", - "terminal": "端末", - "terminalCategory": "端末", + "terminal": "ターミナル", + "terminalCategory": "ターミナル", "viewCategory": "表示" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json b/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json index e7930c9cd7a..31a4c0908cc 100644 --- a/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json @@ -6,9 +6,10 @@ { "workbench.action.terminal.toggleTerminal": "çµ±åˆã‚¿ãƒ¼ãƒŸãƒŠãƒ«ã®åˆ‡ã‚Šæ›¿ãˆ", "workbench.action.terminal.kill": "アクティブãªç«¯æœ«ã‚¤ãƒ³ã‚¹ã‚¿ãƒ³ã‚¹ã‚’強制終了", - "workbench.action.terminal.kill.short": "端末ã®å¼·åˆ¶çµ‚了", + "workbench.action.terminal.kill.short": "ターミナルã®å¼·åˆ¶çµ‚了", "workbench.action.terminal.copySelection": "é¸æŠžå†…容ã®ã‚³ãƒ”ー", - "workbench.action.terminal.new": "æ–°ã—ã„çµ±åˆç«¯æœ«ã®ä½œæˆ", + "workbench.action.terminal.selectAll": "ã™ã¹ã¦é¸æŠž", + "workbench.action.terminal.new": "æ–°ã—ã„çµ±åˆã‚¿ãƒ¼ãƒŸãƒŠãƒ«ã®ä½œæˆ", "workbench.action.terminal.new.short": "æ–°ã—ã„ターミナル", "workbench.action.terminal.focus": "端末ã«ãƒ•ã‚©ãƒ¼ã‚«ã‚¹", "workbench.action.terminal.focusNext": "次ã®ç«¯æœ«ã«ãƒ•ã‚©ãƒ¼ã‚«ã‚¹", @@ -19,7 +20,7 @@ "workbench.action.terminal.runSelectedText": "アクティブãªã‚¿ãƒ¼ãƒŸãƒŠãƒ«ã§é¸æŠžã—ãŸãƒ†ã‚­ã‚¹ãƒˆã‚’実行", "workbench.action.terminal.runActiveFile": "アクティブãªãƒ•ã‚¡ã‚¤ãƒ«ã‚’アクティブãªã‚¿ãƒ¼ãƒŸãƒŠãƒ«ã§å®Ÿè¡Œ", "workbench.action.terminal.runActiveFile.noFile": "ターミナルã§å®Ÿè¡Œã§ãã‚‹ã®ã¯ã€ãƒ‡ã‚£ã‚¹ã‚¯ä¸Šã®ãƒ•ã‚¡ã‚¤ãƒ«ã®ã¿ã§ã™", - "workbench.action.terminal.switchTerminalInstance": "端末インスタンスをスイッãƒ", + "workbench.action.terminal.switchTerminalInstance": "ターミナル インスタンスã®åˆ‡ã‚Šæ›¿ãˆ", "workbench.action.terminal.scrollDown": "下ã«ã‚¹ã‚¯ãƒ­ãƒ¼ãƒ« (è¡Œ)", "workbench.action.terminal.scrollDownPage": "スクロール ダウン (ページ)", "workbench.action.terminal.scrollToBottom": "一番下ã«ã‚¹ã‚¯ãƒ­ãƒ¼ãƒ«", @@ -28,5 +29,6 @@ "workbench.action.terminal.scrollToTop": "一番上ã«ã‚¹ã‚¯ãƒ­ãƒ¼ãƒ«", "workbench.action.terminal.clear": "クリア", "workbench.action.terminal.allowWorkspaceShell": "ワークスペースã§ã‚·ã‚§ãƒ«ã‚’構æˆã™ã‚‹ã“ã¨ã‚’許å¯ã™ã‚‹", - "workbench.action.terminal.disallowWorkspaceShell": "ワークスペースã§ã‚·ã‚§ãƒ«ã‚’構æˆã™ã‚‹ã“ã¨ã‚’許å¯ã—ãªã„" + "workbench.action.terminal.disallowWorkspaceShell": "ワークスペースã§ã‚·ã‚§ãƒ«ã‚’構æˆã™ã‚‹ã“ã¨ã‚’許å¯ã—ãªã„", + "workbench.action.terminal.rename": "åå‰å¤‰æ›´" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json b/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json new file mode 100644 index 00000000000..19f4b3b0c2d --- /dev/null +++ b/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "label.find": "検索", + "placeholder.find": "検索", + "label.previousMatchButton": "å‰ã®ä¸€è‡´é …ç›®", + "label.nextMatchButton": "次ã®ä¸€è‡´é …ç›®", + "label.closeButton": "é–‰ã˜ã‚‹" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json b/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json index a898f37da7b..94bcb838b05 100644 --- a/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json @@ -4,7 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "terminal.integrated.copySelection.noSelection": "ターミナルã«ãƒ•ã‚©ãƒ¼ã‚«ã‚¹ãŒãªã„å ´åˆã¯ã€ã‚¿ãƒ¼ãƒŸãƒŠãƒ«ã®é¸æŠžã‚’コピーã§ãã¾ã›ã‚“", "terminal.integrated.exitedWithCode": "ターミナルã®å‡¦ç†ãŒçµ‚了ã—ã¾ã—㟠(終了コード: {0})", "terminal.integrated.waitOnExit": "ä»»æ„ã®ã‚­ãƒ¼ã‚’押ã—ã¦ç«¯æœ«ã‚’終了ã—ã¾ã™", "terminal.integrated.launchFailed": "ターミナル プロセス コマンド `{0}{1}` ã‚’èµ·å‹•ã§ãã¾ã›ã‚“ã§ã—㟠(終了コード: {2})" diff --git a/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.i18n.json b/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.i18n.json index e8e8ad9346b..997819962b8 100644 --- a/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.i18n.json @@ -5,7 +5,7 @@ // Do not edit this file. It is machine generated. { "copy": "コピー", - "createNewTerminal": "æ–°ã—ã„端末", + "createNewTerminal": "æ–°ã—ã„ターミナル", "paste": "貼り付ã‘", "clear": "クリア" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/update/electron-browser/update.i18n.json b/i18n/jpn/src/vs/workbench/parts/update/electron-browser/update.i18n.json index a420d760802..a396b05a285 100644 --- a/i18n/jpn/src/vs/workbench/parts/update/electron-browser/update.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/update/electron-browser/update.i18n.json @@ -15,5 +15,18 @@ "license": "ライセンスã®é–²è¦§", "updateAvailable": "{0} ã¯å†èµ·å‹•å¾Œã«æ›´æ–°ã•ã‚Œã¾ã™ã€‚", "thereIsUpdateAvailable": "利用å¯èƒ½ãªæ›´æ–°ãƒ—ログラムãŒã‚ã‚Šã¾ã™ã€‚", - "noUpdatesAvailable": "ç¾åœ¨å…¥æ‰‹å¯èƒ½ãªæ›´æ–°ã¯ã‚ã‚Šã¾ã›ã‚“。" + "noUpdatesAvailable": "ç¾åœ¨å…¥æ‰‹å¯èƒ½ãªæ›´æ–°ã¯ã‚ã‚Šã¾ã›ã‚“。", + "updateIsReady": "æ–°ã—ã„æ›´æ–°ãŒåˆ©ç”¨å¯èƒ½ã§ã™ã€‚", + "commandPalette": "コマンド パレット...", + "settings": "設定", + "keyboardShortcuts": "キーボード ショートカット", + "selectTheme.label": "é…色テーマ", + "themes.selectIconTheme.label": "ファイル アイコンã®ãƒ†ãƒ¼ãƒž", + "not available": "æ›´æ–°ã¯åˆ©ç”¨ã§ãã¾ã›ã‚“", + "checkingForUpdates": "更新を確èªã—ã¦ã„ã¾ã™...", + "DownloadUpdate": "利用å¯èƒ½ãªæ›´æ–°ãƒ—ログラムをダウンロードã—ã¾ã™", + "DownloadingUpdate": "更新をダウンロードã—ã¦ã„ã¾ã™...", + "InstallingUpdate": "更新プログラムをインストールã—ã¦ã„ã¾ã™...", + "restartToUpdate": "æ›´æ–°ã®ãŸã‚ã«å†èµ·å‹•ã—ã¾ã™...", + "checkForUpdates": "æ›´æ–°ã®ç¢ºèª..." } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/views/browser/views.i18n.json b/i18n/jpn/src/vs/workbench/parts/views/browser/views.i18n.json new file mode 100644 index 00000000000..6bcbcb522f9 --- /dev/null +++ b/i18n/jpn/src/vs/workbench/parts/views/browser/views.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "viewToolbarAriaLabel": "{0} 個ã®ã‚¢ã‚¯ã‚·ãƒ§ãƒ³" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json b/i18n/jpn/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json new file mode 100644 index 00000000000..4a55950fc52 --- /dev/null +++ b/i18n/jpn/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "requirearray": "ビューã¯é…列ã«ã™ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™", + "requirestring": " `{0}` プロパティã¯å¿…é ˆã§ã€`string` åž‹ã§ãªã‘ã‚Œã°ãªã‚Šã¾ã›ã‚“", + "optstring": "`{0}` プロパティã¯çœç•¥ã™ã‚‹ã‹ã€`string` åž‹ã«ã™ã‚‹å¿…è¦ãŒã‚ã‚Šã¾ã™", + "vscode.extension.contributes.view.id": "ビューã®è­˜åˆ¥å­ã€‚`vscode.window.registerTreeDataProviderForView` API を介ã—ã¦ãƒ‡ãƒ¼ã‚¿ プロãƒã‚¤ãƒ€ãƒ¼ã‚’登録ã™ã‚‹ã«ã¯ã€ã“れを使用ã—ã¾ã™ã€‚ã¾ãŸã€`onView:${id}` イベントを `activationEvents` ã«ç™»éŒ²ã™ã‚‹ã“ã¨ã«ã‚ˆã£ã¦ã€æ‹¡å¼µæ©Ÿèƒ½ã®ã‚¢ã‚¯ãƒ†ã‚£ãƒ–化をトリガーã™ã‚‹ãŸã‚ã«ã‚‚使用ã§ãã¾ã™ã€‚", + "vscode.extension.contributes.view.name": "ビューã®åˆ¤èª­ã§ãã‚‹åå‰ã€‚表示ã•ã‚Œã¾ã™", + "vscode.extension.contributes.views": "ビューをエディターã«æä¾›ã—ã¾ã™", + "views.explorer": "エクスプローラー ビュー", + "locationId.invalid": "`{0}` ã¯æœ‰åŠ¹ãªãƒ“ューã®å ´æ‰€ã§ã¯ã‚ã‚Šã¾ã›ã‚“" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json index 950f340d9ae..ce85f8d6a83 100644 --- a/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -31,7 +31,6 @@ "welcomePage.colorThemeDescription": "エディターã¨ã‚³ãƒ¼ãƒ‰ã®å¤–観を自由ã«è¨­å®šã—ã¾ã™", "welcomePage.learn": "å­¦ã¶", "welcomePage.showCommands": "ã™ã¹ã¦ã®ã‚³ãƒžãƒ³ãƒ‰ã®æ¤œç´¢ã¨å®Ÿè¡Œ", - "welcomePage.showCommandsDescription": "コントロール パãƒãƒ«ã‹ã‚‰ã‚³ãƒžãƒ³ãƒ‰ã‚’検索ã—ã¦ã™ã°ã‚„ãアクセスã—ã¾ã™ ({0})", "welcomePage.interfaceOverview": "インターフェイスã®æ¦‚è¦", "welcomePage.interfaceOverviewDescription": "UI ã®ä¸»è¦ã‚³ãƒ³ãƒãƒ¼ãƒãƒ³ãƒˆã‚’解説ã—ãŸè¦–覚オーãƒãƒ¼ãƒ¬ã‚¤ã‚’表示ã—ã¾ã™", "welcomePage.interactivePlayground": "対話型プレイグラウンド", diff --git a/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json b/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json index 09458a86c49..0f4f46adf62 100644 --- a/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json @@ -4,7 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "workbenchConfigurationTitle": "ワークベンãƒ", - "welcomePage.enabled": "有効ã«ã™ã‚‹ã¨ã€èµ·å‹•æ™‚ã«ã‚¦ã‚§ãƒ«ã‚«ãƒ  ページを表示ã—ã¾ã™ã€‚", "help": "ヘルプ" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index c30717a4d73..59bc465791f 100644 --- a/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/jpn/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -4,6 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "workbenchConfigurationTitle": "ワークベンãƒ", + "welcomePage.enabled": "有効ã«ã™ã‚‹ã¨ã€èµ·å‹•æ™‚ã«ã‚¦ã‚§ãƒ«ã‚«ãƒ  ページを表示ã—ã¾ã™ã€‚", "welcomePage": "よã†ã“ã", "welcomePage.javaScript": "JavaScript", "welcomePage.typeScript": "TypeScript", @@ -14,16 +16,23 @@ "welcomePage.sublime": "Sublime", "welcomePage.atom": "Atom", "welcomePage.extensionPackAlreadyInstalled": "{0} ã®ã‚µãƒãƒ¼ãƒˆã¯æ—¢ã«ã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã¦ã„ã¾ã™ã€‚", - "welcomePage.willReloadAfterInstallingExtensionPack": "{0} ã®ã‚µãƒãƒ¼ãƒˆã‚’インストールã—ãŸå¾Œã€ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ãŒå†åº¦èª­ã¿è¾¼ã¾ã‚Œã¾ã™ã€‚", - "welcomePage.installingExtensionPack": "{0} ã®ã‚µãƒãƒ¼ãƒˆã‚’インストール...", + "welcomePage.willReloadAfterInstallingExtensionPack": "{0} ã«è¿½åŠ ã®ã‚µãƒãƒ¼ãƒˆã‚’インストールã—ãŸã‚ã¨ã€ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ãŒå†åº¦èª­ã¿è¾¼ã¾ã‚Œã¾ã™ã€‚", + "welcomePage.installingExtensionPack": "{0} ã«è¿½åŠ ã®ã‚µãƒãƒ¼ãƒˆã‚’インストールã—ã¦ã„ã¾ã™...", "welcomePage.extensionPackNotFound": "ID {1} ã®ã‚µãƒãƒ¼ãƒˆ {0} ã¯è¦‹ã¤ã‹ã‚Šã¾ã›ã‚“ã§ã—ãŸã€‚", "welcomePage.keymapAlreadyInstalled": "キーボード ショートカット {0} ã¯æ—¢ã«ã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã¦ã„ã¾ã™ã€‚", "welcomePage.willReloadAfterInstallingKeymap": "キーボード ショートカット {0} をインストールã—ãŸå¾Œã€ã‚¦ã‚£ãƒ³ãƒ‰ã‚¦ãŒå†åº¦èª­ã¿è¾¼ã¾ã‚Œã¾ã™ã€‚", "welcomePage.installingKeymap": "{0} ã®ã‚­ãƒ¼ãƒœãƒ¼ãƒ‰ ショートカットをインストールã—ã¦ã„ã¾ã™...", "welcomePage.keymapNotFound": "ID {1} ã®ã‚­ãƒ¼ãƒœãƒ¼ãƒ‰ ショートカット {0} ã¯è¦‹ã¤ã‹ã‚Šã¾ã›ã‚“ã§ã—ãŸã€‚", "welcome.title": "よã†ã“ã", + "welcomePage.openFolderWithPath": "パス {1} ã®ãƒ•ã‚©ãƒ«ãƒ€ãƒ¼ {0} ã‚’é–‹ã", "welcomePage.extensionListSeparator": ",", - "welcomePage.installedExtension": "{0} (インストール済ã¿) ", + "welcomePage.installKeymap": "{0} キーマップをインストールã™ã‚‹", + "welcomePage.installExtensionPack": "{0} ã«è¿½åŠ ã®ã‚µãƒãƒ¼ãƒˆã‚’インストールã™ã‚‹", + "welcomePage.installedKeymap": "{0} キーマップã¯æ—¢ã«ã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã¦ã„ã¾ã™", + "welcomePage.installedExtensionPack": "{0} ã®ã‚µãƒãƒ¼ãƒˆã¯æ—¢ã«ã‚¤ãƒ³ã‚¹ãƒˆãƒ¼ãƒ«ã•ã‚Œã¦ã„ã¾ã™", "ok": "OK", - "cancel": "キャンセル" + "details": "詳細", + "cancel": "キャンセル", + "welcomePage.buttonBackground": "ウェルカム ページã®ãƒœã‚¿ãƒ³ã®èƒŒæ™¯è‰²ã€‚", + "welcomePage.buttonHoverBackground": "ウェルカム ページã®ãƒœã‚¿ãƒ³ã®ãƒ›ãƒãƒ¼èƒŒæ™¯è‰²ã€‚" } \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json b/i18n/jpn/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json new file mode 100644 index 00000000000..7df1ec40941 --- /dev/null +++ b/i18n/jpn/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "telemetryConfigurationTitle": "テレメトリ", + "telemetry.enableCrashReporting": "クラッシュ レãƒãƒ¼ãƒˆã‚’ Microsoft ã«é€ä¿¡ã™ã‚‹ã‚ˆã†ã«è¨­å®šã—ã¾ã™ã€‚\nã“ã®ã‚ªãƒ—ションを有効ã«ã™ã‚‹ã«ã¯ã€å†èµ·å‹•ãŒå¿…è¦ã§ã™ã€‚" +} \ No newline at end of file diff --git a/i18n/jpn/src/vs/workbench/services/progress/browser/progressService2.i18n.json b/i18n/jpn/src/vs/workbench/services/progress/browser/progressService2.i18n.json new file mode 100644 index 00000000000..6db7d6aae51 --- /dev/null +++ b/i18n/jpn/src/vs/workbench/services/progress/browser/progressService2.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "progress.text": "{0} - {1}", + "progress.title": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/kor/extensions/git/out/commands.i18n.json b/i18n/kor/extensions/git/out/commands.i18n.json index 9798aa482fa..b60ceccaa80 100644 --- a/i18n/kor/extensions/git/out/commands.i18n.json +++ b/i18n/kor/extensions/git/out/commands.i18n.json @@ -18,6 +18,7 @@ "discard": "변경 ë‚´ìš© 취소", "confirm discard all": "모든 변경 ë‚´ìš©ì„ ì·¨ì†Œí•˜ì‹œê² ìŠµë‹ˆê¹Œ? ì´ ìž‘ì—…ì€ ë˜ëŒë¦´ 수 없습니다.", "discardAll": "모든 변경 ë‚´ìš© 취소", + "no staged changes": "저장할 ë‹¨ê³„ì  ë³€ê²½ ì‚¬í•­ì´ ì—†ìŠµë‹ˆë‹¤.\n\n모든 변경 ì‚¬í•­ì„ ìžë™ìœ¼ë¡œ 스테ì´ì§•í•˜ê³  ì§ì ‘ 저장하시겠습니까?", "yes": "예", "always": "í•­ìƒ", "no changes": "커밋할 변경 ë‚´ìš©ì´ ì—†ìŠµë‹ˆë‹¤.", @@ -25,6 +26,9 @@ "provide commit message": "커밋 메시지를 제공하세요.", "branch name": "분기 ì´ë¦„", "provide branch name": "분기 ì´ë¦„ì„ ìž…ë ¥í•˜ì„¸ìš”.", + "select branch to delete": "삭제할 분기 ì„ íƒ", + "confirm force delete branch": "'{0}' 분기가 완벽히 병합ë˜ì§€ 않았습니다. ê·¸ëž˜ë„ ì‚­ì œí• ê¹Œìš”?", + "delete branch": "분기 ì‚­ì œ", "no remotes to pull": "리í¬ì§€í† ë¦¬ì— 풀하ë„ë¡ êµ¬ì„±ëœ ì›ê²© í•­ëª©ì´ ì—†ìŠµë‹ˆë‹¤.", "no remotes to push": "리í¬ì§€í† ë¦¬ì— 푸시하ë„ë¡ êµ¬ì„±ëœ ì›ê²©ì´ 없습니다.", "nobranch": "ì›ê²©ì— 푸시할 분기를 ì²´í¬ ì•„ì›ƒí•˜ì„¸ìš”.", diff --git a/i18n/kor/extensions/git/package.i18n.json b/i18n/kor/extensions/git/package.i18n.json index aed0ca69317..115ba212220 100644 --- a/i18n/kor/extensions/git/package.i18n.json +++ b/i18n/kor/extensions/git/package.i18n.json @@ -26,12 +26,13 @@ "command.undoCommit": "마지막 커밋 실행 취소", "command.checkout": "다ìŒìœ¼ë¡œ ì²´í¬ ì•„ì›ƒ...", "command.branch": "분기 만들기...", + "command.deleteBranch": "분기 ì‚­ì œ...", "command.pull": "í’€", "command.pullRebase": "í’€(다시 지정)", "command.push": "푸시", "command.pushTo": "다ìŒìœ¼ë¡œ 푸시...", "command.sync": "ë™ê¸°í™”", - "command.publish": "게시", + "command.publish": "분기 게시", "command.showOutput": "Git 출력 표시", "config.enabled": "Git 사용 여부", "config.path": "Git 실행 파ì¼ì˜ 경로", @@ -42,5 +43,7 @@ "config.countBadge": "Git 배지 카운터를 제어합니다. `all`ì´ë©´ 변경 ë‚´ìš©ì„ ëª¨ë‘ ê³„ì‚°í•˜ê³ , `tracked`ì´ë©´ 추ì ëœ 변경 내용만 계산하고, `off`ì´ë©´ 해제합니다.", "config.checkoutType": "`다ìŒìœ¼ë¡œ ì²´í¬ ì•„ì›ƒ...`ì„ ì‹¤í–‰í•  ë•Œ 나열ë˜ëŠ” 분기 ìœ í˜•ì„ ì œì–´í•©ë‹ˆë‹¤. `all`ì´ë©´ 모든 참조를 표시하고, `local`ì´ë©´ 로컬 분기만 표시하고, `tags`ì´ë©´ 태그만 표시하고, `remote`ì´ë©´ ì›ê²© 분기만 표시합니다.", "config.ignoreLegacyWarning": "레거시 Git 경고를 무시합니다.", - "config.ignoreLimitWarning": "리í¬ì§€í† ë¦¬ì— 변경 ë‚´ìš©ì´ ë„ˆë¬´ 많으면 경고를 무시합니다." + "config.ignoreLimitWarning": "리í¬ì§€í† ë¦¬ì— 변경 ë‚´ìš©ì´ ë„ˆë¬´ 많으면 경고를 무시합니다.", + "config.defaultCloneDirectory": "git 리í¬ì§€í† ë¦¬ë¥¼ 복제할 기본 위치", + "config.enableSmartCommit": "ë‹¨ê³„ì  ë³€ê²½ ì‚¬í•­ì´ ì—†ëŠ” 경우 모든 변경 ì‚¬í•­ì„ ì €ìž¥í•©ë‹ˆë‹¤." } \ No newline at end of file diff --git a/i18n/kor/extensions/jake/out/main.i18n.json b/i18n/kor/extensions/jake/out/main.i18n.json index 8b6ad71cd4e..2e5af401ba1 100644 --- a/i18n/kor/extensions/jake/out/main.i18n.json +++ b/i18n/kor/extensions/jake/out/main.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "execFailed": "Jake ìžë™ 검색 실패 오류: {0}" +} \ No newline at end of file diff --git a/i18n/kor/extensions/jake/package.i18n.json b/i18n/kor/extensions/jake/package.i18n.json index 8b6ad71cd4e..8a1b290c1d4 100644 --- a/i18n/kor/extensions/jake/package.i18n.json +++ b/i18n/kor/extensions/jake/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.jake.autoDetect": "Jake ìž‘ì—…ì— ëŒ€í•œ ìžë™ 검색 사용 여부를 설정합니다. ê¸°ë³¸ê°’ì€ [켜기]입니다." +} \ No newline at end of file diff --git a/i18n/kor/extensions/markdown/out/extension.i18n.json b/i18n/kor/extensions/markdown/out/extension.i18n.json index 8b6ad71cd4e..f38833da5da 100644 --- a/i18n/kor/extensions/markdown/out/extension.i18n.json +++ b/i18n/kor/extensions/markdown/out/extension.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "onPreviewStyleLoadError": "'markdown.styles': {0}ì„ ë¶ˆëŸ¬ì˜¬ 수 ì—†ìŒ" +} \ No newline at end of file diff --git a/i18n/kor/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/kor/extensions/merge-conflict/out/codelensProvider.i18n.json index 8b6ad71cd4e..8b5b2b04aab 100644 --- a/i18n/kor/extensions/merge-conflict/out/codelensProvider.i18n.json +++ b/i18n/kor/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -3,4 +3,9 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "acceptCurrentChange": "현재 변경 사항 수ë½", + "acceptIncomingChange": "수신 변경 사항 수ë½", + "acceptBothChanges": "ë‘ ë³€ê²½ 사항 ëª¨ë‘ ìˆ˜ë½", + "compareChanges": "변경 사항 비êµ" +} \ No newline at end of file diff --git a/i18n/kor/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/kor/extensions/merge-conflict/out/commandHandler.i18n.json index 8b6ad71cd4e..ce73e350da6 100644 --- a/i18n/kor/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/kor/extensions/merge-conflict/out/commandHandler.i18n.json @@ -3,4 +3,10 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "cursorNotInConflict": "편집기 커서가 병합 ì¶©ëŒ ë‚´ì— ì—†ìŒ", + "compareChangesTitle": "{0}: 현재 변경 사항 ⟷ 수신 변경 사항", + "cursorOnSplitterRange": "편집기 커서가 병합 ì¶©ëŒ ìŠ¤í”Œë¦¬í„° ë‚´ì— ìžˆìŠµë‹ˆë‹¤. \"현재\" ë˜ëŠ” \"수신\" 블ë¡ìœ¼ë¡œ 옮기세요.", + "noConflicts": "ì´ íŒŒì¼ì—ì„œ ë°œê²¬ëœ ë³‘í•© ì¶©ëŒ ì—†ìŒ", + "noOtherConflictsInThisFile": "ì´ íŒŒì¼ ë‚´ì— ë‹¤ë¥¸ 병합 ì¶©ëŒ ì—†ìŒ" +} \ No newline at end of file diff --git a/i18n/kor/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/kor/extensions/merge-conflict/out/mergeDecorator.i18n.json index 8b6ad71cd4e..41b53ce1e6c 100644 --- a/i18n/kor/extensions/merge-conflict/out/mergeDecorator.i18n.json +++ b/i18n/kor/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "currentChange": "(현재 변경 사항)", + "incomingChange": "(수신 변경 사항)" +} \ No newline at end of file diff --git a/i18n/kor/extensions/merge-conflict/package.i18n.json b/i18n/kor/extensions/merge-conflict/package.i18n.json index 8b6ad71cd4e..ceb1a3d504d 100644 --- a/i18n/kor/extensions/merge-conflict/package.i18n.json +++ b/i18n/kor/extensions/merge-conflict/package.i18n.json @@ -3,4 +3,18 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "command.category": "ì¶©ëŒ ë³‘í•©", + "command.accept.all-incoming": "수신 ëª¨ë‘ ìˆ˜ë½", + "command.accept.all-both": "둘 다 ëª¨ë‘ ìˆ˜ë½", + "command.accept.current": "현재 수ë½", + "command.accept.incoming": "수신 수ë½", + "command.accept.selection": "ì„ íƒ ìˆ˜ë½", + "command.accept.both": "둘 다 수ë½", + "command.next": "ë‹¤ìŒ ì¶©ëŒ", + "command.previous": "ì´ì „ 충ëŒ", + "command.compare": "현재 ì¶©ëŒ ë¹„êµ", + "config.title": "ì¶©ëŒ ë³‘í•©", + "config.codeLensEnabled": "편집기 ë‚´ì—ì„œ ì¶©ëŒ ë¸”ë¡ CodeLense 병합 사용/사용 안 함", + "config.decoratorsEnabled": "편집기 ë‚´ì—ì„œ ì¶©ëŒ ë³‘í•© 사용/사용 안 함" +} \ No newline at end of file diff --git a/i18n/kor/extensions/npm/package.i18n.json b/i18n/kor/extensions/npm/package.i18n.json index 8b6ad71cd4e..bae4e5954d0 100644 --- a/i18n/kor/extensions/npm/package.i18n.json +++ b/i18n/kor/extensions/npm/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.npm.autoDetect": "npm 스í¬ë¦½íŠ¸ì— 대한 ìžë™ 검색 여부를 설정합니다. ê¸°ë³¸ê°’ì€ [켜기]입니다." +} \ No newline at end of file diff --git a/i18n/kor/extensions/typescript/out/features/bufferSyncSupport.i18n.json b/i18n/kor/extensions/typescript/out/features/bufferSyncSupport.i18n.json index be16b468c9a..099f0f45bd1 100644 --- a/i18n/kor/extensions/typescript/out/features/bufferSyncSupport.i18n.json +++ b/i18n/kor/extensions/typescript/out/features/bufferSyncSupport.i18n.json @@ -4,7 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "versionMismatch": "ë²„ì „ì´ ì¼ì¹˜í•˜ì§€ 않습니다. ì „ì—­ tsc({0})ê°€ VS Codeì˜ ì–¸ì–´ 서비스({1})와 다릅니다. ì¼ê´€ë˜ì§€ ì•Šì€ ì»´íŒŒì¼ ì˜¤ë¥˜ê°€ ë°œìƒí•  수 있습니다.", "moreInformation": "추가 ì •ë³´", "doNotCheckAgain": "다시 í™•ì¸ ì•ˆ 함", "close": "닫기", diff --git a/i18n/kor/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json b/i18n/kor/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json index 8b6ad71cd4e..cca18a8243e 100644 --- a/i18n/kor/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json +++ b/i18n/kor/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "ts-check": "JavaScript 파ì¼ì—ì„œ ì˜ë¯¸ 검사를 사용합니다. 파ì¼ì˜ 최ìƒë‹¨ì— 있어야 합니다.", + "ts-nocheck": "JavaScript 파ì¼ì—ì„œ ì˜ë¯¸ 검사를 사용하지 않습니다. 파ì¼ì˜ 최ìƒë‹¨ì— 있어야 합니다.", + "ts-ignore": "파ì¼ì˜ ë‹¤ìŒ í–‰ì—ì„œ @ts-check 오류를 억제합니다." +} \ No newline at end of file diff --git a/i18n/kor/extensions/typescript/out/utils/projectStatus.i18n.json b/i18n/kor/extensions/typescript/out/utils/projectStatus.i18n.json index 8702bb69360..bd907690388 100644 --- a/i18n/kor/extensions/typescript/out/utils/projectStatus.i18n.json +++ b/i18n/kor/extensions/typescript/out/utils/projectStatus.i18n.json @@ -6,7 +6,6 @@ { "hintExclude": "프로ì íŠ¸ ì „ì²´ì—ì„œ JavaScript/TypeScript 언어 ê¸°ëŠ¥ì„ ì‚¬ìš©í•˜ë„ë¡ ì„¤ì •í•˜ë ¤ë©´ {0}ê³¼(와) ê°™ì´ íŒŒì¼ì´ ë§Žì€ í´ë”를 제외하세요.", "hintExclude.generic": "프로ì íŠ¸ ì „ì²´ì—ì„œ JavaScript/TypeScript 언어 ê¸°ëŠ¥ì„ ì‚¬ìš©í•˜ë„ë¡ ì„¤ì •í•˜ë ¤ë©´ 사용하지 않는 소스 파ì¼ì´ í¬í•¨ëœ í° í´ë”를 제외하세요.", - "open": "제외 구성", "large.label": "제외 구성", "hintExclude.tooltip": "프로ì íŠ¸ ì „ì²´ì—ì„œ JavaScript/TypeScript 언어 ê¸°ëŠ¥ì„ ì‚¬ìš©í•˜ë„ë¡ ì„¤ì •í•˜ë ¤ë©´ 사용하지 않는 소스 파ì¼ì´ í¬í•¨ëœ í° í´ë”를 제외하세요." } \ No newline at end of file diff --git a/i18n/kor/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/kor/extensions/typescript/out/utils/typingsStatus.i18n.json index bba27308a23..e070552b420 100644 --- a/i18n/kor/extensions/typescript/out/utils/typingsStatus.i18n.json +++ b/i18n/kor/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "installingPackages": "TypeScript IntelliSense를 í–¥ìƒí•˜ê¸° 위해 ë°ì´í„°ë¥¼ 페치하는 중", + "typesInstallerInitializationFailed.title": "JavaScript 언어 ê¸°ëŠ¥ì— ëŒ€í•œ ìž…ë ¥ 파ì¼ì„ 설치할 수 없습니다. NPMì´ ì„¤ì¹˜ë˜ì–´ 있는지 확ì¸í•˜ê±°ë‚˜ ì‚¬ìš©ìž ì„¤ì •ì—ì„œ 'typescript.npm'ì„ êµ¬ì„±í•˜ì„¸ìš”.", "typesInstallerInitializationFailed.moreInformation": "추가 ì •ë³´", "typesInstallerInitializationFailed.doNotCheckAgain": "다시 í™•ì¸ ì•ˆ 함", "typesInstallerInitializationFailed.close": "닫기" diff --git a/i18n/kor/extensions/typescript/package.i18n.json b/i18n/kor/extensions/typescript/package.i18n.json index 348ff9b8498..f2cc400f199 100644 --- a/i18n/kor/extensions/typescript/package.i18n.json +++ b/i18n/kor/extensions/typescript/package.i18n.json @@ -13,7 +13,6 @@ "typescript.check.tscVersion": "ì „ì—­ 설치 TypeScript 컴파ì¼ëŸ¬(예: tsc)ê°€ ì‚¬ìš©ëœ TypeScript 언어 서비스와 다른지 확ì¸í•˜ì„¸ìš”.", "typescript.tsserver.log": "파ì¼ì— 대해 TS 서버 ë¡œê¹…ì„ ì‚¬ìš©í•˜ë„ë¡ ì„¤ì •í•©ë‹ˆë‹¤. ì´ ë¡œê·¸ëŠ” TS 서버 문제를 진단하는 ë° ì‚¬ìš©ë  ìˆ˜ 있습니다. 로그ì—는 íŒŒì¼ ê²½ë¡œ, 소스 코드 ë° í”„ë¡œì íŠ¸ì—ì„œ 잠재ì ìœ¼ë¡œ 중요한 기타 ì •ë³´ê°€ í¬í•¨ë  수 있습니다.", "typescript.tsserver.trace": "TS 서버로 전송한 메시지 추ì ì„ 사용하ë„ë¡ ì„¤ì •í•©ë‹ˆë‹¤. ì´\n 추ì ì€ TS 서버 문제를 진단하는 ë° ì‚¬ìš©ë  ìˆ˜ 있습니다. 추ì ì—는 íŒŒì¼ ê²½ë¡œ, 소스 코드 ë° í”„ë¡œì íŠ¸ì—ì„œ 잠재ì ìœ¼ë¡œ 중요한\n 기타 ì •ë³´ê°€ í¬í•¨ë  수 있습니다.", - "typescript.tsserver.experimentalAutoBuild": "ì‹¤í—˜ì  ìžë™ 빌드를 사용하ë„ë¡ ì„¤ì •í•©ë‹ˆë‹¤. 1.9 dev ë˜ëŠ” 2.x tsserver ë²„ì „ì´ í•„ìš”í•˜ë©° 변경 후ì—는 VS Code를 다시 시작해야 합니다.", "typescript.validate.enable": "TypeScript 유효성 검사를 사용하거나 사용하지 않습니다.", "typescript.format.enable": "기본 TypeScript í¬ë§·í„°ë¥¼ 사용하거나 사용하지 않습니다.", "javascript.format.enable": "기본 JavaScript í¬ë§·í„°ë¥¼ 사용하거나 사용하지 않습니다.", @@ -33,8 +32,16 @@ "javascript.validate.enable": "JavaScript 유효성 검사를 사용하거나 사용하지 않습니다.", "typescript.goToProjectConfig.title": "프로ì íŠ¸ 구성으로 ì´ë™", "javascript.goToProjectConfig.title": "프로ì íŠ¸ 구성으로 ì´ë™", + "javascript.referencesCodeLens.enabled": "JavaScript 파ì¼ì—ì„œ CodeLense 참조를 사용/사용 안 함으로 설정합니다.", + "typescript.referencesCodeLens.enabled": "TypeScript 파ì¼ì—ì„œ 참조 CodeLense를 사용/사용 안 함으로 설정합니다. TypeScript >= 2.0.6ì´ í•„ìš”í•©ë‹ˆë‹¤.", "typescript.implementationsCodeLens.enabled": "구현 CodeLens를 사용하거나 사용하지 ì•Šë„ë¡ ì„¤ì •í•©ë‹ˆë‹¤. TypeScript >= 2.2.0ì´ í•„ìš”í•©ë‹ˆë‹¤.", + "typescript.openTsServerLog.title": "TS 서버 로그 열기", + "typescript.restartTsServer": "TS 서버 다시 시작", "typescript.selectTypeScriptVersion.title": "TypeScript 버전 ì„ íƒ", "jsDocCompletion.enabled": "ìžë™ JSDoc ì£¼ì„ ì‚¬ìš©/사용 안 함", - "javascript.implicitProjectConfig.checkJs": "JavaScript 파ì¼ì˜ ì˜ë¯¸ 체계 검사를 사용/사용하지 않습니다. 기존 jsconfig.json ë˜ëŠ” tsconfig.json 파ì¼ì€ ì´ ì„¤ì •ì„ ìž¬ì •ì˜í•©ë‹ˆë‹¤. TypeScript >=2.3.1ì´ í•„ìš”í•©ë‹ˆë‹¤. " + "javascript.implicitProjectConfig.checkJs": "JavaScript 파ì¼ì˜ ì˜ë¯¸ 체계 검사를 사용/사용하지 않습니다. 기존 jsconfig.json ë˜ëŠ” tsconfig.json 파ì¼ì€ ì´ ì„¤ì •ì„ ìž¬ì •ì˜í•©ë‹ˆë‹¤. TypeScript >=2.3.1ì´ í•„ìš”í•©ë‹ˆë‹¤. ", + "typescript.npm": "ìžë™ ìž…ë ¥ ì¸ì‹ì— ì‚¬ìš©ëœ NPM 실행 íŒŒì¼ ê²½ë¡œë¥¼ 지정합니다. TypeScript >= 2.3.4ê°€ 필요합니다.", + "typescript.check.npmIsInstalled": "ìžë™ ìž…ë ¥ ì¸ì‹ì— 대해 NPMì´ ì„¤ì¹˜ë˜ì–´ 있는지 확ì¸í•©ë‹ˆë‹¤.", + "javascript.nameSuggestions": "JavaScript 제안 목ë¡ì˜ 파ì¼ì—ì„œ 고유한 ì´ë¦„ í¬í•¨ì„ 사용/사용 안 함으로 설정합니다.", + "typescript.tsc.autoDetect": "tsc ìž‘ì—…ì˜ ìžë™ ê²€ìƒ‰ì„ ì¼œê±°ë‚˜ ë•ë‹ˆë‹¤." } \ No newline at end of file diff --git a/i18n/kor/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/kor/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index 4266985efc9..6d1aafbc271 100644 --- a/i18n/kor/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/kor/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,6 +6,7 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "ì´ë¯¸ì§€ê°€ 너무 커서 íŽ¸ì§‘ê¸°ì— í‘œì‹œí•  수 없습니다. ", + "resourceOpenExternalButton": " 외부 프로그램으로 ì´ë¯¸ì§€ë¥¼ 열까요?", "nativeBinaryError": "파ì¼ì´ ì´ì§„ì´ê±°ë‚˜ 매우 í¬ê±°ë‚˜ 지ì›ë˜ì§€ 않는 í…스트 ì¸ì½”ë”©ì„ ì‚¬ìš©í•˜ê¸° ë•Œë¬¸ì— íŽ¸ì§‘ê¸°ì—ì„œ 표시ë˜ì§€ 않습니다.", "sizeB": "{0}B", "sizeKB": "{0}KB", diff --git a/i18n/kor/src/vs/base/common/errorMessage.i18n.json b/i18n/kor/src/vs/base/common/errorMessage.i18n.json index a1079b63959..f7f99e392a0 100644 --- a/i18n/kor/src/vs/base/common/errorMessage.i18n.json +++ b/i18n/kor/src/vs/base/common/errorMessage.i18n.json @@ -13,6 +13,5 @@ "error.connection.unknown": "ì•Œ 수 없는 ì—°ê²° 오류가 ë°œìƒí–ˆìŠµë‹ˆë‹¤. ì¸í„°ë„·ì— ì—°ê²°ë˜ì§€ 않았거나 ì—°ê²°ëœ ì„œë²„ê°€ 오프ë¼ì¸ ìƒíƒœìž…니다.", "stackTrace.format": "{0}: {1}", "error.defaultMessage": "ì•Œ 수 없는 오류가 ë°œìƒí–ˆìŠµë‹ˆë‹¤. ìžì„¸í•œ ë‚´ìš©ì€ ë¡œê·¸ë¥¼ 참조하세요.", - "nodeExceptionMessage": "시스템 오류가 ë°œìƒí–ˆìŠµë‹ˆë‹¤({0}).", "error.moreErrors": "{0}(ì´ {1}ê°œì˜ ì˜¤ë¥˜)" } \ No newline at end of file diff --git a/i18n/kor/src/vs/base/common/keybindingLabels.i18n.json b/i18n/kor/src/vs/base/common/keybindingLabels.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/kor/src/vs/base/common/keybindingLabels.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/kor/src/vs/code/electron-main/menus.i18n.json b/i18n/kor/src/vs/code/electron-main/menus.i18n.json index b293d481517..4716e6a22e5 100644 --- a/i18n/kor/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/kor/src/vs/code/electron-main/menus.i18n.json @@ -14,6 +14,7 @@ "mHelp": "ë„움ë§(&&H)", "miNewWindow": "새 ì°½(&&W)", "mAbout": "{0} ì •ë³´", + "mServices": "서비스", "mHide": "{0} 숨기기", "mHideOthers": "기타 숨기기", "mShowAll": "ëª¨ë‘ í‘œì‹œ", @@ -54,6 +55,9 @@ "miShowEmmetCommands": "Emmet(&&M)...", "miToggleLineComment": "줄 ì£¼ì„ ì„¤ì •/í•´ì œ(&&T)", "miToggleBlockComment": "ë¸”ë¡ ì£¼ì„ ì„¤ì •/í•´ì œ(&&B)", + "miMultiCursorAlt": "다중 ì»¤ì„œì— Alt+í´ë¦­ 사용", + "miMultiCursorCmd": "다중 ì»¤ì„œì— Cmd+í´ë¦­ 사용", + "miMultiCursorCtrl": "다중 ì»¤ì„œì— Ctrl+í´ë¦­ 사용", "miInsertCursorAbove": "ìœ„ì— ì»¤ì„œ 추가(&&A)", "miInsertCursorBelow": "ì•„ëž˜ì— ì»¤ì„œ 추가(&&D)", "miInsertCursorAtEndOfEachLineSelected": "줄 ëì— ì»¤ì„œ 추가(&&U)", @@ -69,6 +73,7 @@ "miSmartSelectShrink": "ì„ íƒ ì˜ì—­ 축소(&&S)", "miViewExplorer": "íƒìƒ‰ê¸°(&&E)", "miViewSearch": "검색(&&S)", + "miViewSCM": "SCM(&&C)", "miViewDebug": "디버그(&&D)", "miViewExtensions": "확장(&&X)", "miToggleOutput": "출력(&&O)", @@ -113,6 +118,8 @@ "miGotoSymbolInFile": "파ì¼ì˜ 기호로 ì´ë™(&&S)...", "miGotoSymbolInWorkspace": "ìž‘ì—… ì˜ì—­ì˜ 기호로 ì´ë™(&&W)...", "miGotoDefinition": "ì •ì˜ë¡œ ì´ë™(&&D)", + "miGotoTypeDefinition": "í˜•ì‹ ì •ì˜ë¡œ ì´ë™( &&T)", + "miGotoImplementation": "구현으로 ì´ë™( &&I)", "miGotoLine": "줄 ì´ë™(&&L)...", "miStartDebugging": "디버깅 시작(&&S)", "miStartWithoutDebugging": "디버깅하지 ì•Šê³  시작(&&W)", @@ -129,16 +136,17 @@ "miColumnBreakpoint": "ì—´ 중단ì (&&O)", "miFunctionBreakpoint": "함수 중단ì (&&F)...", "miNewBreakpoint": "새 중단ì (&&N)", + "miEnableAllBreakpoints": "모든 ì¤‘ë‹¨ì  ì„¤ì •", "miDisableAllBreakpoints": "모든 ì¤‘ë‹¨ì  ì‚¬ìš© 안 함(&&L)", "miRemoveAllBreakpoints": "모든 ì¤‘ë‹¨ì  ì œê±°(&&A)", "miInstallAdditionalDebuggers": "추가 디버거 설치(&&I)...", "mMinimize": "최소화", - "mClose": "닫기", "mBringToFront": "ëª¨ë‘ ë§¨ 앞으로 가져오기", "miToggleDevTools": "ê°œë°œìž ë„구 설정/í•´ì œ(&&T)", "miAccessibilityOptions": "접근성 옵션(&&O)", "miReportIssues": "문제 ë³´ê³ (&&I)", "miWelcome": "시작(&&W)", + "miInteractivePlayground": "대화형 실습(&&I)", "miDocumentation": "설명서(&&D)", "miReleaseNotes": "릴리스 ì •ë³´(&&R)", "miKeyboardShortcuts": "바로 가기 키 참조(&&K)", @@ -148,12 +156,14 @@ "miLicense": "ë¼ì´ì„ ìŠ¤ 보기(&&L)", "miPrivacyStatement": "ê°œì¸ì •ë³´ì²˜ë¦¬ë°©ì¹¨(&&P)", "miAbout": "ì •ë³´(&&A)", + "miTerminateTask": "ìž‘ì—… 종료(&&T)", "accessibilityOptionsWindowTitle": "접근성 옵션", "miRestartToUpdate": "ì—…ë°ì´íŠ¸í•˜ê¸° 위해 다시 시작...", "miCheckingForUpdates": "ì—…ë°ì´íŠ¸ë¥¼ 확ì¸í•˜ëŠ” 중...", "miDownloadUpdate": "사용 가능한 ì—…ë°ì´íŠ¸ 다운로드", "miDownloadingUpdate": "ì—…ë°ì´íŠ¸ë¥¼ 다운로드하는 중...", "miInstallingUpdate": "ì—…ë°ì´íŠ¸ë¥¼ 설치하는 중...", + "miCheckForUpdates": "ì—…ë°ì´íŠ¸ 확ì¸...", "aboutDetail": "\n버전 {0}\n커밋 {1}\n날짜 {2}\nì…¸{3}\në Œë”러 {4}\nNode {5}", "okButton": "확ì¸" } \ No newline at end of file diff --git a/i18n/kor/src/vs/code/electron-main/windows.i18n.json b/i18n/kor/src/vs/code/electron-main/windows.i18n.json index 474475abdb1..bad419f4787 100644 --- a/i18n/kor/src/vs/code/electron-main/windows.i18n.json +++ b/i18n/kor/src/vs/code/electron-main/windows.i18n.json @@ -13,9 +13,5 @@ "appStalled": "ì°½ì´ ë” ì´ìƒ ì‘답하지 않습니다.", "appStalledDetail": "ì°½ì„ ë‹¤ì‹œ 열거나, 닫거나, ê³„ì† ê¸°ë‹¤ë¦´ 수 있습니다.", "appCrashed": "ì°½ì´ ì¶©ëŒí–ˆìŠµë‹ˆë‹¤.", - "appCrashedDetail": "ë¶ˆíŽ¸ì„ ë“œë ¤ì„œ 죄송합니다. ì°½ì„ ë‹¤ì‹œ ì—´ë©´ ì¤‘ë‹¨ëœ ìœ„ì¹˜ì—ì„œ 계ì†í•  수 있습니다.", - "newWindow": "새 ì°½", - "newWindowDesc": "새 ì°½ì„ ì—½ë‹ˆë‹¤.", - "recentFolders": "최근 í´ë”", - "folderDesc": "{0} {1}" + "appCrashedDetail": "ë¶ˆíŽ¸ì„ ë“œë ¤ì„œ 죄송합니다. ì°½ì„ ë‹¤ì‹œ ì—´ë©´ ì¤‘ë‹¨ëœ ìœ„ì¹˜ì—ì„œ 계ì†í•  수 있습니다." } \ No newline at end of file diff --git a/i18n/kor/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/kor/src/vs/editor/common/config/commonEditorConfig.i18n.json index 18aff6704be..3baffd1c3a9 100644 --- a/i18n/kor/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/kor/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -9,6 +9,7 @@ "fontWeight": "글꼴 ë‘께를 제어합니다.", "fontSize": "글꼴 í¬ê¸°(픽셀)를 제어합니다.", "lineHeight": "줄 높ì´ë¥¼ 제어합니다. fontSizeì˜ lineHeight를 계산하려면 0ì„ ì‚¬ìš©í•©ë‹ˆë‹¤.", + "letterSpacing": "ê¸€ìž ê°„ê²©ì„ í”½ì…€ 단위로 조정합니다.", "lineNumbers": "줄 ë²ˆí˜¸ì˜ í‘œì‹œ 여부를 제어합니다. 가능한 ê°’ì€ 'on', 'off', 'relative'입니다. 'relative'는 현재 커서 위치ì—ì„œ 줄 수를 표시합니다.", "rulers": "세로 눈금ìžë¥¼ 표시할 ì—´", "wordSeparators": "단어 관련 íƒìƒ‰ ë˜ëŠ” ìž‘ì—…ì„ ìˆ˜í–‰í•  ë•Œ 단어 구분 기호로 사용ë˜ëŠ” 문ìžìž…니다.", @@ -22,6 +23,8 @@ "minimap.enabled": "미니맵 표시 여부를 제어합니다.", "minimap.renderCharacters": "ì¤„ì˜ ì‹¤ì œ 문ìž(색 ë¸”ë¡ ì•„ë‹˜) ë Œë”ë§", "minimap.maxColumn": "최대 특정 ìˆ˜ì˜ ì—´ì„ ë Œë”ë§í•˜ë„ë¡ ë¯¸ë‹ˆë§µì˜ ë„ˆë¹„ë¥¼ 제한합니다.", + "find.seedSearchStringFromSelection": "편집기 ì„ íƒì—ì„œ Find Widgetì˜ ê²€ìƒ‰ 문ìžì—´ì„ 시딩할지 설정합니다.", + "find.autoFindInSelection": "편집기ì—ì„œ 여러 ê¸€ìž ë˜ëŠ” í–‰ì„ ì„ íƒí–ˆì„ ë•Œ Find in Selection 플래그를 켤지 설정합니다.", "wordWrap.off": "ì¤„ì´ ë°”ë€Œì§€ 않습니다.", "wordWrap.on": "ë·°í¬íŠ¸ 너비ì—ì„œ ì¤„ì´ ë°”ë€ë‹ˆë‹¤.", "wordWrap.wordWrapColumn": "`editor.wordWrapColumn`ì—ì„œ ì¤„ì´ ë°”ë€ë‹ˆë‹¤.", @@ -30,16 +33,19 @@ "wordWrapColumn": "`editor.wordWrap`ì´ 'wordWrapColumn' ë˜ëŠ” 'bounded'ì¸ ê²½ìš° íŽ¸ì§‘ê¸°ì˜ ì—´ 줄 ë°”ê¿ˆì„ ì œì–´í•©ë‹ˆë‹¤.", "wrappingIndent": "줄 바꿈 í–‰ì˜ ë“¤ì—¬ì“°ê¸°ë¥¼ 제어합니다. 'none', 'same' ë˜ëŠ” 'indent' 중 í•˜ë‚˜ì¼ ìˆ˜ 있습니다.", "mouseWheelScrollSensitivity": "마우스 휠 스í¬ë¡¤ ì´ë²¤íŠ¸ì˜ `deltaX` ë° `deltaY`ì—ì„œ 사용할 승수", + "multiCursorModifier.ctrlCmd": "Windows와 Linuxì˜ 'Control'ì„ OSXì˜ 'Command'ë¡œ 매핑합니다.", + "multiCursorModifier.alt": "Windows와 Linuxì˜ 'Alt'를 OSXì˜ 'Option'으로 매핑합니다.", + "multiCursorModifier": "마우스로 여러 커서를 추가할 ë•Œ 사용할 수정ìžìž…니다. `ctrlCmd`는 Windows와 Linuxì—ì„œ `Control`ë¡œ 매핑ë˜ê³  OSXì—ì„œ `Command`ë¡œ 매핑ë©ë‹ˆë‹¤. Go To Definition ë° Open Link 마우스 제스처가 멀티커서 수정ìžì™€ 충ëŒí•˜ì§€ ì•Šë„ë¡ ì¡°ì •ë©ë‹ˆë‹¤.", "quickSuggestions.strings": "문ìžì—´ ë‚´ì—ì„œ 빠른 ì œì•ˆì„ ì‚¬ìš©í•©ë‹ˆë‹¤.", "quickSuggestions.comments": "ì£¼ì„ ë‚´ì—ì„œ 빠른 ì œì•ˆì„ ì‚¬ìš©í•©ë‹ˆë‹¤.", "quickSuggestions.other": "문ìžì—´ ë° ì£¼ì„ ì™¸ë¶€ì—ì„œ 빠른 ì œì•ˆì„ ì‚¬ìš©í•©ë‹ˆë‹¤.", "quickSuggestions": "입력하는 ë™ì•ˆ ì œì•ˆì„ ìžë™ìœ¼ë¡œ 표시할지 여부를 제어합니다.", "quickSuggestionsDelay": "빠른 ì œì•ˆì„ í‘œì‹œí•  지연 시간(ms)ì„ ì œì–´í•©ë‹ˆë‹¤.", - "parameterHints": "매개 변수 힌트를 사용하ë„ë¡ ì„¤ì •í•©ë‹ˆë‹¤.", "autoClosingBrackets": "괄호를 ì—° 다ìŒì— 편집기ì—ì„œ 괄호를 ìžë™ìœ¼ë¡œ ë‹«ì„지 여부를 제어합니다.", "formatOnType": "ìž…ë ¥ 후 편집기ì—ì„œ ìžë™ìœ¼ë¡œ ì¤„ì˜ ì„œì‹ì„ 지정할지 여부를 제어합니다.", "formatOnPaste": "ë¶™ì—¬ë„£ì€ ì½˜í…ì¸ ì˜ ì„œì‹ì„ 편집기ì—ì„œ ìžë™ìœ¼ë¡œ 지정할지 여부를 제어합니다. í¬ë§·í„°ëŠ” 반드시 사용할 수 있어야 하며 문서ì—ì„œ ë²”ìœ„ì˜ ì„œì‹ì„ 지정할 수 있어야 합니다.", "suggestOnTriggerCharacters": "트리거 문ìžë¥¼ 입력할 ë•Œ ì œì•ˆì„ ìžë™ìœ¼ë¡œ 표시할지 여부를 제어합니다.", + "acceptSuggestionOnEnter": "'Tab' 키 ì™¸ì— 'Enter' í‚¤ì— ëŒ€í•œ ì œì•ˆë„ í—ˆìš©í• ì§€ë¥¼ 제어합니다. 새 ì¤„ì„ ì‚½ìž…í•˜ëŠ” ë™ìž‘ê³¼ ì œì•ˆì„ í—ˆìš©í•˜ëŠ” ë™ìž‘ ê°„ì˜ ëª¨í˜¸í•¨ì„ ì—†ì•¨ 수 있습니다.", "acceptSuggestionOnCommitCharacter": "커밋 문ìžì— 대한 ì œì•ˆì„ í—ˆìš©í• ì§€ë¥¼ 제어합니다. 예를 들어 JavaScriptì—서는 세미콜론(';')ì´ ì œì•ˆì„ í—ˆìš©í•˜ê³  해당 문ìžë¥¼ 입력하는 커밋 문ìžì¼ 수 있습니다.", "snippetSuggestions": "코드 ì¡°ê°ì´ 다른 추천과 함께 표시ë˜ëŠ”지 여부 ë° ì •ë ¬ ë°©ë²•ì„ ì œì–´í•©ë‹ˆë‹¤.", "emptySelectionClipboard": "ì„ íƒ ì˜ì—­ ì—†ì´ í˜„ìž¬ 줄 복사 여부를 제어합니다.", @@ -61,12 +67,17 @@ "renderLineHighlight": "편집기가 현재 줄 ê°•ì¡° 표시를 ë Œë”ë§í•˜ëŠ” ë°©ì‹ì„ 제어합니다. 가능한 ê°’ì€ 'none', 'gutter', 'line' ë° 'all'입니다.", "codeLens": "편집기ì—ì„œ 코드 필터를 표시하는지 여부를 제어합니다.", "folding": "편집기ì—ì„œ 코드 접기를 사용할지 여부를 제어합니다.", + "showFoldingControls": "ê±°í„°ì˜ í´ë“œ ì»¨íŠ¸ë¡¤ì„ ìžë™ìœ¼ë¡œ 숨길지 결정합니다.", "matchBrackets": "대괄호 중 하나를 ì„ íƒí•  ë•Œ ì¼ì¹˜í•˜ëŠ” 대괄호를 ê°•ì¡° 표시합니다.", "glyphMargin": "편집기ì—ì„œ 세로 ë¬¸ìž ëª¨ì–‘ ì—¬ë°±ì„ ë Œë”ë§í• ì§€ 여부를 제어합니다. ë¬¸ìž ëª¨ì–‘ ì—¬ë°±ì€ ì£¼ë¡œ ë””ë²„ê¹…ì— ì‚¬ìš©ë©ë‹ˆë‹¤.", "useTabStops": "탭 정지 ë’¤ì— ê³µë°± 삽입 ë° ì‚­ì œ", "trimAutoWhitespace": "ëì— ìžë™ ì‚½ìž…ëœ ê³µë°± 제거", "stablePeek": "해당 콘í…츠를 ë‘ ë²ˆ í´ë¦­í•˜ê±°ë‚˜ 키를 누르ë”ë¼ë„ Peek 편집기를 열린 ìƒíƒœë¡œ 유지합니다.", "dragAndDrop": "편집기ì—ì„œ ëŒì–´ì„œ 놓기로 ì„ íƒ ì˜ì—­ì„ ì´ë™í•  수 있는지 여부를 제어합니다.", + "accessibilitySupport.auto": "편집기가 스í¬ë¦° 리ë”ê°€ ì—°ê²°ë˜ë©´ í”Œëž«í¼ API를 사용하여 ê°ì§€í•©ë‹ˆë‹¤.", + "accessibilitySupport.on": "편집기가 스í¬ë¦° ë¦¬ë” ì‚¬ìš©ì„ ìœ„í•´ ì˜êµ¬ì ìœ¼ë¡œ 최ì í™”ë©ë‹ˆë‹¤.", + "accessibilitySupport.off": "편집기가 스í¬ë¦° ë¦¬ë” ì‚¬ìš©ì„ ìœ„í•´ 최ì í™”ë˜ì§€ 않습니다.", + "accessibilitySupport": "편집기를 스í¬ë¦° 리ë”를 위해 최ì í™”ëœ ëª¨ë“œë¡œ 실행할지 결정합니다.", "sideBySide": "diff 편집기ì—ì„œ diff를 나란히 표시할지 ì¸ë¼ì¸ìœ¼ë¡œ 표시할지 여부를 제어합니다.", "ignoreTrimWhitespace": "diff 편집기ì—ì„œ ì„ í–‰ 공백 ë˜ëŠ” 후행 공백 ë³€ê²½ì„ diffsë¡œ 표시할지 여부를 제어합니다.", "renderIndicators": "diff 편집기ì—ì„œ 추가/ì œê±°ëœ ë³€ê²½ ë‚´ìš©ì— ëŒ€í•´ +/- 표시기를 표시하는지 여부를 제어합니다.", diff --git a/i18n/kor/src/vs/editor/common/config/editorOptions.i18n.json b/i18n/kor/src/vs/editor/common/config/editorOptions.i18n.json index 4118aae2aa7..f2303e9e367 100644 --- a/i18n/kor/src/vs/editor/common/config/editorOptions.i18n.json +++ b/i18n/kor/src/vs/editor/common/config/editorOptions.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "accessibilityOffAriaLabel": "ì§€ê¸ˆì€ íŽ¸ì§‘ê¸°ë¥¼ 사용할 수 없습니다. Alt+F1ì„ ëˆŒëŸ¬ ì˜µì…˜ì„ ë³´ì„¸ìš”.", "editorViewAccessibleLabel": "편집기 콘í…츠" } \ No newline at end of file diff --git a/i18n/kor/src/vs/editor/common/view/editorColorRegistry.i18n.json b/i18n/kor/src/vs/editor/common/view/editorColorRegistry.i18n.json index e45a777ecdb..dcef1416eba 100644 --- a/i18n/kor/src/vs/editor/common/view/editorColorRegistry.i18n.json +++ b/i18n/kor/src/vs/editor/common/view/editorColorRegistry.i18n.json @@ -10,5 +10,15 @@ "caret": "편집기 커서 색입니다.", "editorWhitespaces": "íŽ¸ì§‘ê¸°ì˜ ê³µë°± ë¬¸ìž ìƒ‰ìž…ë‹ˆë‹¤.", "editorIndentGuides": "편집기 들여쓰기 안내선 색입니다.", - "editorLineNumbers": "편집기 줄 번호 색입니다." + "editorLineNumbers": "편집기 줄 번호 색입니다.", + "editorRuler": "편집기 ëˆˆê¸ˆì˜ ìƒ‰ìƒìž…니다.", + "editorCodeLensForeground": "편집기 코드 ë Œì¦ˆì˜ ì „ê²½ìƒ‰ìž…ë‹ˆë‹¤.", + "editorBracketMatchBackground": "ì¼ì¹˜í•˜ëŠ” 브래킷 ë’¤ì˜ ë°°ê²½ìƒ‰ìž…ë‹ˆë‹¤.", + "editorBracketMatchBorder": "ì¼ì¹˜í•˜ëŠ” 브래킷 ë°•ìŠ¤ì˜ ìƒ‰ìƒ", + "editorOverviewRulerBorder": "개요 눈금 ê²½ê³„ì˜ ìƒ‰ìƒìž…니다.", + "editorGutter": "편집기 ê±°í„°ì˜ ë°°ê²½ìƒ‰ìž…ë‹ˆë‹¤. ê±°í„°ì—는 글리프 여백과 í–‰ 수가 있습니다.", + "errorForeground": "편집기 ë‚´ 오류 í‘œì‹œì„ ì˜ ì „ê²½ìƒ‰ìž…ë‹ˆë‹¤.", + "errorBorder": "편집기 ë‚´ 오류 í‘œì‹œì„ ì˜ í…Œë‘리 색입니다.", + "warningForeground": "편집기 ë‚´ 경고 í‘œì‹œì„ ì˜ ì „ê²½ìƒ‰ìž…ë‹ˆë‹¤.", + "warningBorder": "편집기 ë‚´ 경고 í‘œì‹œì„ ì˜ í…Œë‘리 색입니다." } \ No newline at end of file diff --git a/i18n/kor/src/vs/editor/contrib/find/common/findController.i18n.json b/i18n/kor/src/vs/editor/contrib/find/common/findController.i18n.json index e49f22d8123..468f641effe 100644 --- a/i18n/kor/src/vs/editor/contrib/find/common/findController.i18n.json +++ b/i18n/kor/src/vs/editor/contrib/find/common/findController.i18n.json @@ -14,6 +14,5 @@ "addSelectionToPreviousFindMatch": "ì´ì „ ì¼ì¹˜ 항목 ì°¾ê¸°ì— ì„ íƒ í•­ëª© 추가", "moveSelectionToNextFindMatch": "ë‹¤ìŒ ì¼ì¹˜ 항목 찾기로 마지막 ì„ íƒ í•­ëª© ì´ë™", "moveSelectionToPreviousFindMatch": "마지막 ì„ íƒ í•­ëª©ì„ ì´ì „ ì¼ì¹˜ 항목 찾기로 ì´ë™", - "selectAllOccurencesOfFindMatch": "ì¼ì¹˜ 항목 ì°¾ê¸°ì˜ ëª¨ë“  항목 ì„ íƒ", "changeAll.label": "모든 항목 변경" } \ No newline at end of file diff --git a/i18n/kor/src/vs/editor/contrib/links/browser/links.i18n.json b/i18n/kor/src/vs/editor/contrib/links/browser/links.i18n.json index e38e83f3a2f..ddf7b26a227 100644 --- a/i18n/kor/src/vs/editor/contrib/links/browser/links.i18n.json +++ b/i18n/kor/src/vs/editor/contrib/links/browser/links.i18n.json @@ -6,6 +6,7 @@ { "links.navigate.mac": "Cmd 키를 누르고 í´ë¦­í•˜ì—¬ ë§í¬ë¡œ ì´ë™", "links.navigate": "Ctrl 키를 누르고 í´ë¦­í•˜ì—¬ ë§í¬ë¡œ ì´ë™", + "links.navigate.al": "Alt 키를 누르고 í´ë¦­í•˜ì—¬ ë§í¬ë¡œ ì´ë™", "invalid.url": "죄송합니다. ì´ ë§í¬ëŠ” 형ì‹ì´ 올바르지 않으므로 열지 못했습니다. {0}", "missing.url": "죄송합니다. 대ìƒì´ 없으므로 ì´ ë§í¬ë¥¼ 열지 못했습니다.", "label": "ë§í¬ 열기" diff --git a/i18n/kor/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json b/i18n/kor/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json index 2aeba994a61..0bb0099a543 100644 --- a/i18n/kor/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json +++ b/i18n/kor/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json @@ -5,8 +5,6 @@ // Do not edit this file. It is machine generated. { "aria.oneReference": "{2}ì—´, {1}줄, {0}ì˜ ê¸°í˜¸", - "aria.fileReferences.1": "{0}ì˜ ê¸°í˜¸ 1ê°œ", - "aria.fileReferences.N": "{1}ì˜ ê¸°í˜¸ {0}ê°œ", "aria.result.0": "ê²°ê³¼ ì—†ìŒ", "aria.result.1": "{0}ì—ì„œ 기호 1개를 찾았습니다.", "aria.result.n1": "{1}ì—ì„œ 기호 {0}개를 찾았습니다.", diff --git a/i18n/kor/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json b/i18n/kor/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json index d5cc24a60e7..bebeacf6346 100644 --- a/i18n/kor/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json +++ b/i18n/kor/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json @@ -16,9 +16,12 @@ "peekViewTitleInfoForeground": "Peek ë·° 제목 ì •ë³´ 색입니다.", "peekViewBorder": "Peek ë·° í…Œë‘리 ë° í™”ì‚´í‘œ 색입니다.", "peekViewResultsBackground": "Peek ë·° ê²°ê³¼ 목ë¡ì˜ 배경색입니다.", + "peekViewResultsMatchForeground": "Peek ë·° ê²°ê³¼ 목ë¡ì—ì„œ ë¼ì¸ ë…¸ë“œì˜ ì „ê²½ìƒ‰ìž…ë‹ˆë‹¤.", + "peekViewResultsFileForeground": "Peek ë·° ê²°ê³¼ 목ë¡ì—ì„œ íŒŒì¼ ë…¸ë“œì˜ ì „ê²½ìƒ‰ìž…ë‹ˆë‹¤.", "peekViewResultsSelectionBackground": "Peek ë·° ê²°ê³¼ 목ë¡ì—ì„œ ì„ íƒëœ í•­ëª©ì˜ ë°°ê²½ìƒ‰ìž…ë‹ˆë‹¤.", "peekViewResultsSelectionForeground": "Peek ë·° ê²°ê³¼ 목ë¡ì—ì„œ ì„ íƒëœ í•­ëª©ì˜ ì „ê²½ìƒ‰ìž…ë‹ˆë‹¤.", "peekViewEditorBackground": "Peek ë·° íŽ¸ì§‘ê¸°ì˜ ë°°ê²½ìƒ‰ìž…ë‹ˆë‹¤.", + "peekViewEditorGutterBackground": "Peek ë·° íŽ¸ì§‘ê¸°ì˜ ê±°í„° 배경색입니다.", "peekViewResultsMatchHighlight": "Peek ë·° ê²°ê³¼ 목ë¡ì˜ ì¼ì¹˜ 항목 ê°•ì¡° 표시 색입니다.", "peekViewEditorMatchHighlight": "Peek ë·° íŽ¸ì§‘ê¸°ì˜ ì¼ì¹˜ 항목 ê°•ì¡° 표시 색입니다." } \ No newline at end of file diff --git a/i18n/kor/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json b/i18n/kor/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json index 8f85109ab67..db8bbbe6670 100644 --- a/i18n/kor/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json +++ b/i18n/kor/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json @@ -12,6 +12,7 @@ "readMore": "ìžì„¸ížˆ 알아보기...{0}", "suggestionWithDetailsAriaLabel": "{0}, 제안, 세부 ì •ë³´ 있ìŒ", "suggestionAriaLabel": "{0}, 제안", + "readLess": "간단히 보기...{0}", "suggestWidget.loading": "로드 중...", "suggestWidget.noSuggestions": "제안 í•­ëª©ì´ ì—†ìŠµë‹ˆë‹¤.", "suggestionAriaAccepted": "{0}, 수ë½ë¨", diff --git a/i18n/kor/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json b/i18n/kor/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json index d8b1d74b5f7..59242661db1 100644 --- a/i18n/kor/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json +++ b/i18n/kor/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json @@ -15,5 +15,9 @@ "schema.brackets": "들여쓰기를 늘리거나 줄ì´ëŠ” 대괄호 기호를 ì •ì˜í•©ë‹ˆë‹¤.", "schema.autoClosingPairs": "대괄호 ìŒì„ ì •ì˜í•©ë‹ˆë‹¤. 여는 대괄호를 입력하면 닫는 대괄호가 ìžë™ìœ¼ë¡œ 삽입ë©ë‹ˆë‹¤.", "schema.autoClosingPairs.notIn": "ìžë™ ìŒì„ 사용하지 ì•Šë„ë¡ ì„¤ì •ëœ ë²”ìœ„ 목ë¡ì„ ì •ì˜í•©ë‹ˆë‹¤.", - "schema.surroundingPairs": "ì„ íƒí•œ 문ìžì—´ì„ 둘러싸는 ë° ì‚¬ìš©í•  수 있는 대괄호 ìŒì„ ì •ì˜í•©ë‹ˆë‹¤." + "schema.surroundingPairs": "ì„ íƒí•œ 문ìžì—´ì„ 둘러싸는 ë° ì‚¬ìš©í•  수 있는 대괄호 ìŒì„ ì •ì˜í•©ë‹ˆë‹¤.", + "schema.wordPattern": "해당 ì–¸ì–´ì— ëŒ€í•œ 단어 ì •ì˜ìž…니다.", + "schema.wordPattern.pattern": "단어 ì¼ì¹˜ì— 사용하는 RegEXP 패턴입니다.", + "schema.wordPattern.flags": "단어 ì¼ì¹˜ì— 사용하는 RegExp 플래그입니다.", + "schema.wordPattern.flags.errorMessage": "`/^([gimuy]+)$/` 패턴과 ì¼ì¹˜í•´ì•¼ 합니다." } \ No newline at end of file diff --git a/i18n/kor/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json b/i18n/kor/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json index d2433872a7d..1c5f62b7b23 100644 --- a/i18n/kor/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json +++ b/i18n/kor/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json @@ -21,6 +21,8 @@ "menus.scmTitle": "소스 제어 제목 메뉴", "menus.resourceGroupContext": "소스 제어 리소스 그룹 ìƒí™©ì— 맞는 메뉴", "menus.resourceStateContext": "소스 제어 리소스 ìƒíƒœ ìƒí™©ì— 맞는 메뉴", + "view.viewTitle": "기여 조회 제목 메뉴", + "view.itemContext": "기여 조회 항목 ìƒí™©ì— 맞는 메뉴", "nonempty": "비어 있지 ì•Šì€ ê°’ì´ í•„ìš”í•©ë‹ˆë‹¤.", "opticon": "`icon` ì†ì„±ì€ ìƒëžµí•  수 있거나 문ìžì—´ ë˜ëŠ” 리터럴(예: `{dark, light}`)ì´ì–´ì•¼ 합니다.", "requireStringOrObject": "`{0}` ì†ì„±ì€ 필수ì´ë©° `string` ë˜ëŠ” `object` 형ì‹ì´ì–´ì•¼ 합니다.", diff --git a/i18n/kor/src/vs/platform/extensions/common/extensionsRegistry.i18n.json b/i18n/kor/src/vs/platform/extensions/common/extensionsRegistry.i18n.json index 2fca8d6643b..7207158c622 100644 --- a/i18n/kor/src/vs/platform/extensions/common/extensionsRegistry.i18n.json +++ b/i18n/kor/src/vs/platform/extensions/common/extensionsRegistry.i18n.json @@ -14,6 +14,12 @@ "vscode.extension.contributes": "ì´ íŒ¨í‚¤ì§€ì— í‘œì‹œëœ VS Code í™•ìž¥ì˜ ì „ì²´ 기여입니다.", "vscode.extension.preview": "마켓플레ì´ìŠ¤ì—ì„œ Previewë¡œ 플래그 지정할 í™•ìž¥ì„ ì„¤ì •í•©ë‹ˆë‹¤.", "vscode.extension.activationEvents": "VS Code í™•ìž¥ì— ëŒ€í•œ 활성화 ì´ë²¤íŠ¸ìž…니다.", + "vscode.extension.activationEvents.onLanguage": "ì§€ì •ëœ ì–¸ì–´ë¡œ 확ì¸ë˜ëŠ” 파ì¼ì„ ì—´ 때마다 활성화 ì´ë²¤íŠ¸ê°€ 발송ë©ë‹ˆë‹¤.", + "vscode.extension.activationEvents.onCommand": "ì§€ì •ëœ ëª…ë ¹ì„ í˜¸ì¶œí•  때마다 활성화 ì´ë²¤íŠ¸ê°€ 발송ë©ë‹ˆë‹¤.", + "vscode.extension.activationEvents.onDebug": "ì§€ì •ëœ ìœ í˜•ì˜ ë””ë²„ê¹… ì„¸ì…˜ì„ ì‹œìž‘í•  때마다 활성화 ì•Œë¦¼ì´ ë°œì†¡ë©ë‹ˆë‹¤.", + "vscode.extension.activationEvents.workspaceContains": "ì§€ì •ëœ glob 패턴과 ì¼ì¹˜í•˜ëŠ” 파ì¼ì´ 하나 ì´ìƒ 있는 í´ë”를 ì—´ 때마다 활성화 ì•Œë¦¼ì´ ë°œì†¡ë©ë‹ˆë‹¤.", + "vscode.extension.activationEvents.onView": "ì§€ì •ëœ ë·°ê°€ í™•ìž¥ë  ë•Œë§ˆë‹¤ 활성화 ì´ë²¤íŠ¸ê°€ ë‚´ë³´ë‚´ 집니다.", + "vscode.extension.activationEvents.star": "VS Code 시작 ì‹œ 활성화 ì´ë²¤íŠ¸ê°€ 발송ë©ë‹ˆë‹¤. 훌륭한 최종 ì‚¬ìš©ìž ê²½í—˜ì„ ë³´ìž¥í•˜ë ¤ë©´ 사용 ì¼€ì´ìŠ¤ì—ì„œ 다른 활성화 ì´ë²¤íŠ¸ ì¡°í•©ì´ ìž‘ë™í•˜ì§€ ì•Šì„ ë•Œì—만 확장ì—ì„œ ì´ í™œì„±í™” ì´ë²¤íŠ¸ë¥¼ 사용하세요.", "vscode.extension.badges": "마켓플레ì´ìŠ¤ 확장 페ì´ì§€ì˜ 사ì´ë“œë°”ì— í‘œì‹œí•  ë°°ì§€ì˜ ë°°ì—´ìž…ë‹ˆë‹¤.", "vscode.extension.badges.url": "배지 ì´ë¯¸ì§€ URL입니다.", "vscode.extension.badges.href": "배지 ë§í¬ìž…니다.", diff --git a/i18n/kor/src/vs/platform/history/electron-main/historyMainService.i18n.json b/i18n/kor/src/vs/platform/history/electron-main/historyMainService.i18n.json new file mode 100644 index 00000000000..6b87a635f59 --- /dev/null +++ b/i18n/kor/src/vs/platform/history/electron-main/historyMainService.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "newWindow": "새 ì°½", + "newWindowDesc": "새 ì°½ì„ ì—½ë‹ˆë‹¤.", + "recentFolders": "최근 í´ë”", + "folderDesc": "{0} {1}" +} \ No newline at end of file diff --git a/i18n/kor/src/vs/platform/markers/common/problemMatcher.i18n.json b/i18n/kor/src/vs/platform/markers/common/problemMatcher.i18n.json index ff679b577b2..22a96d0b0b8 100644 --- a/i18n/kor/src/vs/platform/markers/common/problemMatcher.i18n.json +++ b/i18n/kor/src/vs/platform/markers/common/problemMatcher.i18n.json @@ -34,6 +34,7 @@ "ProblemMatcherParser.noValidIdentifier": "오류: 패턴 ì†ì„± {0}ì´(ê°€) 유효한 패턴 변수 ì´ë¦„ì´ ì•„ë‹™ë‹ˆë‹¤.", "ProblemMatcherParser.problemPattern.watchingMatcher": "문제 검사기ì—ì„œ ê°ì‹œ 시작 패턴과 종료 íŒ¨í„´ì„ ëª¨ë‘ ì •ì˜í•´ì•¼ 합니다.", "ProblemMatcherParser.invalidRegexp": "오류: {0} 문ìžì—´ì€ 유효한 ì •ê·œì‹ì´ 아닙니다.\n", + "WatchingPatternSchema.regexp": "백그ë¼ìš´ë“œ ìž‘ì—…ì˜ ì‹œìž‘ ë˜ëŠ” 종료를 ê°ì§€í•˜ëŠ” ì •ê·œì‹ìž…니다.", "WatchingPatternSchema.file": "íŒŒì¼ ì´ë¦„ì˜ ì¼ì¹˜ 그룹 ì¸ë±ìŠ¤ì´ë©° ìƒëžµí•  수 있습니다.", "PatternTypeSchema.name": "제공ë˜ê±°ë‚˜ 미리 ì •ì˜ëœ íŒ¨í„´ì˜ ì´ë¦„", "PatternTypeSchema.description": "문제 패턴 ë˜ëŠ” 제공ë˜ê±°ë‚˜ 미리 ì •ì˜ëœ 문제 íŒ¨í„´ì˜ ì´ë¦„입니다. ê¸°ë³¸ì´ ì§€ì •ëœ ê²½ìš° ìƒëžµí•  수 있습니다.", @@ -42,6 +43,12 @@ "ProblemMatcherSchema.severity": "캡처 ë¬¸ì œì— ëŒ€í•œ 기본 심ê°ë„입니다. 패턴ì—ì„œ 심ê°ë„ì— ëŒ€í•œ ì¼ì¹˜ ê·¸ë£¹ì„ ì •ì˜í•˜ì§€ ì•Šì€ ê²½ìš°ì— ì‚¬ìš©ë©ë‹ˆë‹¤.", "ProblemMatcherSchema.applyTo": "í…스트 ë¬¸ì„œì— ë³µëœ ë¬¸ì œê°€ 열린 문서, 닫힌 문서 ë˜ëŠ” 모든 ë¬¸ì„œì— ì ìš©ë˜ëŠ”지를 제어합니다.", "ProblemMatcherSchema.fileLocation": "문제 íŒ¨í„´ì— ë³´ê³ ëœ íŒŒì¼ ì´ë¦„ì„ í•´ì„하는 ë°©ë²•ì„ ì •ì˜í•©ë‹ˆë‹¤.", + "ProblemMatcherSchema.background": "백그ë¼ìš´ë“œ ìž‘ì—…ì—ì„œ 활성 ìƒíƒœì¸ matcherì˜ ì‹œìž‘ê³¼ ëì„ ì¶”ì í•˜ëŠ” 패턴입니다.", + "ProblemMatcherSchema.background.activeOnStart": "trueë¡œ 설정한 경우 ìž‘ì—…ì´ ì‹œìž‘ë˜ë©´ 백그ë¼ìš´ë“œ 모니터가 활성 모드로 전환ë©ë‹ˆë‹¤. ì´ëŠ” beginPatternê³¼ ì¼ì¹˜í•˜ëŠ” ì¤„ì„ ì‹¤í–‰í•˜ëŠ” 것과 같습니다.", + "ProblemMatcherSchema.background.beginsPattern": "ì¶œë ¥ì´ ì¼ì¹˜í•˜ëŠ” 경우 백그ë¼ìš´ë“œ ìž‘ì—…ì„ ì‹œìž‘í•  ë•Œ 신호를 받습니다.", + "ProblemMatcherSchema.background.endsPattern": "ì¶œë ¥ì´ ì¼ì¹˜í•˜ëŠ” 경우 백그ë¼ìš´ë“œ ìž‘ì—…ì„ ëë‚  ë•Œ 신호를 받습니다.", + "ProblemMatcherSchema.watching.deprecated": "조사 ì†ì„±ì€ 사용ë˜ì§€ 않습니다. 백그ë¼ìš´ë“œ ì†ì„±ì„ 대신 사용하세요.", + "ProblemMatcherSchema.watching": "조사 matcherì˜ ì‹œìž‘ê³¼ ëì„ ì¶”ì í•˜ëŠ” 패턴입니다.", "ProblemMatcherSchema.watching.activeOnStart": "trueë¡œ 설정한 경우 ìž‘ì—…ì´ ì‹œìž‘ë˜ë©´ ì„ íƒê¸°ê°€ 활성 모드로 전환ë©ë‹ˆë‹¤. ì´ëŠ” beginPatternê³¼ ì¼ì¹˜í•˜ëŠ” ì¤„ì„ ì‹¤í–‰í•˜ëŠ” 것과 같습니다.", "ProblemMatcherSchema.watching.beginsPattern": "ì¶œë ¥ì´ ì¼ì¹˜í•˜ëŠ” 경우 조사 ìž‘ì—…ì„ ì‹œìž‘í•  ë•Œ 신호를 받습니다.", "ProblemMatcherSchema.watching.endsPattern": "ì¶œë ¥ì´ ì¼ì¹˜í•˜ëŠ” 경우 조사 ìž‘ì—…ì„ ëë‚  ë•Œ 신호를 받습니다.", diff --git a/i18n/kor/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/kor/src/vs/platform/theme/common/colorRegistry.i18n.json index 4ff5446bc03..bae0d085ef9 100644 --- a/i18n/kor/src/vs/platform/theme/common/colorRegistry.i18n.json +++ b/i18n/kor/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -7,14 +7,24 @@ "invalid.color": "ìž˜ëª»ëœ ìƒ‰ 형ì‹ìž…니다. #RGB, #RGBA, #RRGGBB ë˜ëŠ” #RRGGBBAA를 사용하세요.", "schema.colors": "워í¬ë²¤ì¹˜ì—ì„œ 사용ë˜ëŠ” 색입니다.", "foreground": "ì „ì²´ 전경색입니다. ì´ ìƒ‰ì€ êµ¬ì„± 요소ì—ì„œ 재정ì˜í•˜ì§€ ì•Šì€ ê²½ìš°ì—만 사용ë©ë‹ˆë‹¤.", + "errorForeground": "오류 ë©”ì‹œì§€ì— ëŒ€í•œ ì „ì²´ 전경색입니다. ì´ ìƒ‰ì€ êµ¬ì„± 요소ì—ì„œ 재정ì˜í•˜ì§€ ì•Šì€ ê²½ìš°ì—만 사용ë©ë‹ˆë‹¤.", + "descriptionForeground": "ë ˆì´ë¸”ê³¼ ê°™ì´ ì¶”ê°€ 정보를 제공하는 설명 í…ìŠ¤íŠ¸ì˜ ì „ê²½ìƒ‰ìž…ë‹ˆë‹¤.", "focusBorder": "í¬ì»¤ìŠ¤ê°€ 있는 ìš”ì†Œì˜ ì „ì²´ í…Œë‘리 색입니다. ì´ ìƒ‰ì€ êµ¬ì„± 요소ì—ì„œ 재정ì˜í•˜ì§€ ì•Šì€ ê²½ìš°ì—만 사용ë©ë‹ˆë‹¤.", "contrastBorder": "ë” ëšœë ·ì´ ëŒ€ë¹„ë˜ë„ë¡ ìš”ì†Œë¥¼ 다른 요소와 구분하는 요소 ì£¼ìœ„ì˜ ì¶”ê°€ í…Œë‘리입니다.", "activeContrastBorder": "ë” ëšœë ·ì´ ëŒ€ë¹„ë˜ë„ë¡ ìš”ì†Œë¥¼ 다른 요소와 구분하는 활성 요소 ì£¼ìœ„ì˜ ì¶”ê°€ í…Œë‘리입니다.", + "textSeparatorForeground": "í…스트 êµ¬ë¶„ìž ìƒ‰ìƒìž…니다.", + "textLinkForeground": "í…스트 ë‚´ ë§í¬ì˜ 전경색입니다.", + "textLinkActiveForeground": "í…스트 ë‚´ 활성 ë§í¬ì˜ 전경색입니다.", + "textPreformatForeground": "미리 ì„œì‹ì´ ì§€ì •ëœ í…스트 ì„¸ê·¸ë¨¼íŠ¸ì˜ ì „ê²½ìƒ‰ìž…ë‹ˆë‹¤.", + "textBlockQuoteBackground": "í…스트 ë‚´ ë¸”ë¡ ì¸ìš©ì˜ 전경색입니다.", + "textBlockQuoteBorder": "í…스트 ë‚´ ë¸”ë¡ ì¸ìš©ì˜ í…Œë‘리 색입니다.", + "textCodeBlockBackground": "í…스트 ë‚´ 코드 블ë¡ì˜ 전경색입니다.", "widgetShadow": "편집기 ë‚´ì—ì„œ 찾기/바꾸기 ê°™ì€ ìœ„ì ¯ì˜ ê·¸ë¦¼ìž ìƒ‰ìž…ë‹ˆë‹¤.", "inputBoxBackground": "ìž…ë ¥ ìƒìž 배경입니다.", "inputBoxForeground": "ìž…ë ¥ ìƒìž 전경입니다.", "inputBoxBorder": "ìž…ë ¥ ìƒìž í…Œë‘리입니다.", "inputBoxActiveOptionBorder": "ìž…ë ¥ í•„ë“œì—ì„œ í™œì„±í™”ëœ ì˜µì…˜ì˜ í…Œë‘리 색입니다.", + "inputPlaceholderForeground": "위치 í‘œì‹œìž í…ìŠ¤íŠ¸ì— ëŒ€í•œ ìž…ë ¥ ìƒìž 전경색입니다.", "inputValidationInfoBackground": "ì •ë³´ 심ê°ë„ì˜ ìž…ë ¥ 유효성 검사 배경색입니다.", "inputValidationInfoBorder": "ì •ë³´ 심ê°ë„ì˜ ìž…ë ¥ 유효성 검사 í…Œë‘리 색입니다.", "inputValidationWarningBackground": "ì •ë³´ ê²½ê³ ì˜ ìž…ë ¥ 유효성 검사 배경색입니다.", @@ -25,10 +35,13 @@ "dropdownForeground": "드롭다운 전경입니다.", "dropdownBorder": "드롭다운 í…Œë‘리입니다.", "listFocusBackground": "목ë¡/트리가 활성 ìƒíƒœì¸ 경우 í¬ì»¤ìŠ¤ê°€ 있는 í•­ëª©ì˜ ëª©ë¡/트리 배경색입니다. 목ë¡/트리가 활성 ìƒíƒœì´ë©´ 키보드 í¬ì»¤ìŠ¤ë¥¼ 가지며, 비활성 ìƒíƒœì´ë©´ í¬ì»¤ìŠ¤ê°€ 없습니다.", + "listFocusForeground": "목ë¡/트리가 활성 ìƒíƒœì¸ 경우 í¬ì»¤ìŠ¤ê°€ 있는 í•­ëª©ì˜ ëª©ë¡/트리 전경색입니다. 목ë¡/트리가 활성 ìƒíƒœì´ë©´ 키보드 í¬ì»¤ìŠ¤ë¥¼ 가지며, 비활성 ìƒíƒœì´ë©´ í¬ì»¤ìŠ¤ê°€ 없습니다.", "listActiveSelectionBackground": "목ë¡/트리가 활성 ìƒíƒœì¸ 경우 ì„ íƒí•œ í•­ëª©ì˜ ëª©ë¡/트리 배경색입니다. 목ë¡/트리가 활성 ìƒíƒœì´ë©´ 키보드 í¬ì»¤ìŠ¤ë¥¼ 가지며, 비활성 ìƒíƒœì´ë©´ í¬ì»¤ìŠ¤ê°€ 없습니다.", "listActiveSelectionForeground": "목ë¡/트리가 활성 ìƒíƒœì¸ 경우 ì„ íƒí•œ í•­ëª©ì˜ ëª©ë¡/트리 전경색입니다. 목ë¡/트리가 활성 ìƒíƒœì´ë©´ 키보드 í¬ì»¤ìŠ¤ë¥¼ 가지며, 비활성 ìƒíƒœì´ë©´ í¬ì»¤ìŠ¤ê°€ 없습니다.", "listInactiveSelectionBackground": "목ë¡/트리가 비활성 ìƒíƒœì¸ 경우 ì„ íƒí•œ í•­ëª©ì˜ ëª©ë¡/트리 배경색입니다. 목ë¡/트리가 활성 ìƒíƒœì´ë©´ 키보드 í¬ì»¤ìŠ¤ë¥¼ 가지며, 비활성 ìƒíƒœì´ë©´ í¬ì»¤ìŠ¤ê°€ 없습니다.", + "listInactiveSelectionForeground": "목ë¡/트리가 비활성 ìƒíƒœì¸ 경우 ì„ íƒí•œ í•­ëª©ì˜ ëª©ë¡/트리 전경색입니다. 목ë¡/트리가 활성 ìƒíƒœì´ë©´ 키보드 í¬ì»¤ìŠ¤ë¥¼ 가지며, 비활성 ìƒíƒœì´ë©´ í¬ì»¤ìŠ¤ê°€ 없습니다.", "listHoverBackground": "마우스로 í•­ëª©ì„ ê°€ë¦¬í‚¬ ë•Œ 목ë¡/트리 배경입니다.", + "listHoverForeground": "마우스로 í•­ëª©ì„ ê°€ë¦¬í‚¬ ë•Œ 목ë¡/트리 전경입니다.", "listDropBackground": "마우스로 í•­ëª©ì„ ì´ë™í•  ë•Œ 목ë¡/트리 ëŒì–´ì„œ 놓기 배경입니다.", "highlight": "목ë¡/트리 ë‚´ì—ì„œ 검색할 ë•Œ ì¼ì¹˜ 항목 ê°•ì¡° í‘œì‹œì˜ ëª©ë¡/트리 전경색입니다.", "pickerGroupForeground": "그룹화 ë ˆì´ë¸”ì— ëŒ€í•œ 빠른 ì„ íƒê¸° 색입니다.", @@ -36,13 +49,17 @@ "buttonForeground": "단추 기본 전경색입니다.", "buttonBackground": "단추 배경색입니다.", "buttonHoverBackground": "마우스로 가리킬 ë•Œ 단추 배경색입니다.", + "badgeBackground": "배지 배경색입니다. 배지는 검색 ê²°ê³¼ 수와 ê°™ì€ ì†ŒëŸ‰ì˜ ì •ë³´ ë ˆì´ë¸”입니다.", + "badgeForeground": "배지 전경색입니다. 배지는 검색 ê²°ê³¼ 수와 ê°™ì€ ì†ŒëŸ‰ì˜ ì •ë³´ ë ˆì´ë¸”입니다.", "scrollbarShadow": "스í¬ë¡¤ë˜ëŠ” 보기를 나타내는 스í¬ë¡¤ 막대 그림ìžìž…니다.", "scrollbarSliderBackground": "슬ë¼ì´ë” 배경색입니다.", "scrollbarSliderHoverBackground": "마우스로 가리킬 ë•Œ 슬ë¼ì´ë” 배경색입니다.", "scrollbarSliderActiveBackground": "활성 ìƒíƒœì¸ 경우 슬ë¼ì´ë” 배경색입니다.", + "progressBarBackground": "오래 실행 ì¤‘ì¸ ìž‘ì—…ì— ëŒ€í•´ 표시ë˜ëŠ” 진행률 표시 ë§‰ëŒ€ì˜ ë°°ê²½ìƒ‰ìž…ë‹ˆë‹¤.", "editorBackground": "편집기 배경색입니다.", "editorForeground": "편집기 기본 전경색입니다.", "editorWidgetBackground": "찾기/바꾸기 ê°™ì€ íŽ¸ì§‘ê¸° ìœ„ì ¯ì˜ ë°°ê²½ìƒ‰ìž…ë‹ˆë‹¤.", + "editorWidgetBorder": "편집기 ìœ„ì ¯ì˜ í…Œë‘리 색입니다. ìœ„ì ¯ì— í…Œë‘리가 있고 ìœ„ì ¯ì´ ìƒ‰ìƒì„ 무시하지 ì•Šì„ ë•Œë§Œ 사용ë©ë‹ˆë‹¤.", "editorSelection": "편집기 ì„ íƒ ì˜ì—­ì˜ 색입니다.", "editorInactiveSelection": "비활성 편집기 ì„ íƒ ì˜ì—­ì˜ 색입니다.", "editorSelectionHighlight": "ì„ íƒ ì˜ì—­ê³¼ ë™ì¼í•œ 콘í…츠가 있는 ì˜ì—­ì˜ 색입니다.", @@ -56,5 +73,12 @@ "diffEditorInserted": "ì‚½ìž…ëœ í…ìŠ¤íŠ¸ì˜ ë°°ê²½ìƒ‰ìž…ë‹ˆë‹¤.", "diffEditorRemoved": "ì œê±°ëœ í…ìŠ¤íŠ¸ì˜ ë°°ê²½ìƒ‰ìž…ë‹ˆë‹¤.", "diffEditorInsertedOutline": "ì‚½ìž…ëœ í…ìŠ¤íŠ¸ì˜ ìœ¤ê³½ì„  색입니다.", - "diffEditorRemovedOutline": "ì œê±°ëœ í…ìŠ¤íŠ¸ì˜ ìœ¤ê³½ì„  색입니다." + "diffEditorRemovedOutline": "ì œê±°ëœ í…ìŠ¤íŠ¸ì˜ ìœ¤ê³½ì„  색입니다.", + "mergeCurrentHeaderBackground": "ì¸ë¼ì¸ 병합 충ëŒì˜ 현재 í—¤ë” ë°°ê²½ìž…ë‹ˆë‹¤.", + "mergeCurrentContentBackground": "ì¸ë¼ì¸ 병합 충ëŒì˜ 현재 콘í…츠 배경입니다.", + "mergeIncomingHeaderBackground": "ì¸ë¼ì¸ 병합 충ëŒì—ì„œ 수신 í—¤ë” ë°°ê²½ìž…ë‹ˆë‹¤.", + "mergeIncomingContentBackground": "ì¸ë¼ì¸ 병합 충ëŒì—ì„œ 수신 콘í…츠 배경입니다.", + "mergeBorder": "ì¸ë¼ì¸ 병합 충ëŒì—ì„œ í—¤ë” ë° ìŠ¤í”Œë¦¬í„°ì˜ í…Œë‘리 색입니다.", + "overviewRulerCurrentContentForeground": "ì¸ë¼ì¸ 병합 충ëŒì—ì„œ 현재 개요 눈금 전경색입니다.", + "overviewRulerIncomingContentForeground": "ì¸ë¼ì¸ 병합 충ëŒì—ì„œ 수신 개요 눈금 전경색입니다." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/kor/src/vs/workbench/api/node/extHostTask.i18n.json index 8b6ad71cd4e..4b90a12aaf2 100644 --- a/i18n/kor/src/vs/workbench/api/node/extHostTask.i18n.json +++ b/i18n/kor/src/vs/workbench/api/node/extHostTask.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "task.label": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/api/node/extHostTreeViews.i18n.json b/i18n/kor/src/vs/workbench/api/node/extHostTreeViews.i18n.json index 8b6ad71cd4e..4dfa6a6e897 100644 --- a/i18n/kor/src/vs/workbench/api/node/extHostTreeViews.i18n.json +++ b/i18n/kor/src/vs/workbench/api/node/extHostTreeViews.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "treeView.notRegistered": "IDê°€ '{0}'ì¸ ë“±ë¡ëœ 트리 ë·°ê°€ 없습니다.", + "treeItem.notFound": "IDê°€ '{0}'ì¸ íŠ¸ë¦¬ í•­ëª©ì„ ì°¾ì„ ìˆ˜ 없습니다.", + "treeView.duplicateElement": "{0} 요소가 ì´ë¯¸ 등ë¡ë˜ì–´ 있습니다." +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/browser/actions/configureLocale.i18n.json b/i18n/kor/src/vs/workbench/browser/actions/configureLocale.i18n.json index 72443813473..46230055683 100644 --- a/i18n/kor/src/vs/workbench/browser/actions/configureLocale.i18n.json +++ b/i18n/kor/src/vs/workbench/browser/actions/configureLocale.i18n.json @@ -7,6 +7,7 @@ "configureLocale": "언어 구성", "displayLanguage": "VSCodeì˜ í‘œì‹œ 언어를 ì •ì˜í•©ë‹ˆë‹¤.", "doc": "지ì›ë˜ëŠ” 언어 목ë¡ì€ {0} ì„(를) 참조하세요.", + "restart": "ê°’ì„ ë³€ê²½í•˜ë ¤ë©´ VSCode를 다시 시작해야 합니다.", "fail.createSettings": "'{0}'({1})ì„(를) 만들 수 없습니다.", "JsonSchema.locale": "사용할 UI 언어입니다." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json b/i18n/kor/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json index 64445b492e0..775ac027185 100644 --- a/i18n/kor/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json +++ b/i18n/kor/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json @@ -5,5 +5,6 @@ // Do not edit this file. It is machine generated. { "hideActivitBar": "ìž‘ì—… 막대 숨기기", - "activityBarAriaLabel": "활성 ë·° 전환기" + "activityBarAriaLabel": "활성 ë·° 전환기", + "globalActions": "ì „ì—­ ìž‘ì—…" } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json b/i18n/kor/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json index 8b7506a02d0..0f9049de2ac 100644 --- a/i18n/kor/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json +++ b/i18n/kor/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json @@ -10,7 +10,7 @@ "multiSelection": "{0} ì„ íƒ í•­ëª©", "endOfLineLineFeed": "LF", "endOfLineCarriageReturnLineFeed": "CRLF", - "tabFocusModeEnabled": "Tab으로 í¬ì»¤ìŠ¤ ì´ë™", + "screenReaderDetectedExtra": "화면 ì½ê¸° í”„ë¡œê·¸ëž¨ì„ ì‚¬ìš©í•˜ì§€ 않는 경우 `editor.accessibilitySupport` ì„¤ì •ì„ \"off\"ë¡œ 변경하세요.", "disableTabMode": "접근성 모드 사용 안 함", "gotoLine": "줄 ì´ë™", "indentation": "들여쓰기", diff --git a/i18n/kor/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json b/i18n/kor/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json new file mode 100644 index 00000000000..8b1fffebc06 --- /dev/null +++ b/i18n/kor/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpen": "파ì¼ë¡œ ì´ë™...", + "quickNavigateNext": "Quick Openì—ì„œ ë‹¤ìŒ íƒìƒ‰", + "quickNavigatePrevious": "Quick Openì—ì„œ ì´ì „ íƒìƒ‰", + "quickSelectNext": "Quick Openì—ì„œ ë‹¤ìŒ ì„ íƒ", + "quickSelectPrevious": "Quick Openì—ì„œ ì´ì „ ì„ íƒ" +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/browser/quickopen.i18n.json b/i18n/kor/src/vs/workbench/browser/quickopen.i18n.json index 438739dc282..15bbb282f52 100644 --- a/i18n/kor/src/vs/workbench/browser/quickopen.i18n.json +++ b/i18n/kor/src/vs/workbench/browser/quickopen.i18n.json @@ -6,6 +6,5 @@ { "noResultsMatching": "ì¼ì¹˜í•˜ëŠ” ê²°ê³¼ ì—†ìŒ", "noResultsFound2": "ê²°ê³¼ ì—†ìŒ", - "entryAriaLabel": "{0}, 명령", - "noCommands": "ì¼ì¹˜í•˜ëŠ” 명령 ì—†ìŒ" + "entryAriaLabel": "{0}, 명령" } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/browser/viewlet.i18n.json b/i18n/kor/src/vs/workbench/browser/viewlet.i18n.json index c5364af7184..1b18c6972e4 100644 --- a/i18n/kor/src/vs/workbench/browser/viewlet.i18n.json +++ b/i18n/kor/src/vs/workbench/browser/viewlet.i18n.json @@ -4,6 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "collapse": "ëª¨ë‘ ì¶•ì†Œ", - "viewToolbarAriaLabel": "{0} ë™ìž‘" + "collapse": "ëª¨ë‘ ì¶•ì†Œ" } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/common/theme.i18n.json b/i18n/kor/src/vs/workbench/common/theme.i18n.json index 182ceaa205e..96c96b6d687 100644 --- a/i18n/kor/src/vs/workbench/common/theme.i18n.json +++ b/i18n/kor/src/vs/workbench/common/theme.i18n.json @@ -7,27 +7,42 @@ "tabActiveBackground": "활성 탭 배경색입니다. íƒ­ì€ íŽ¸ì§‘ê¸° ì˜ì—­ì—ì„œ íŽ¸ì§‘ê¸°ì˜ ì»¨í…Œì´ë„ˆìž…니다. í•œ 편집기 그룹ì—ì„œ 여러 íƒ­ì„ ì—´ 수 있습니다. 여러 편집기 ê·¸ë£¹ì´ ìžˆì„ ìˆ˜ 있습니다.", "tabInactiveBackground": "비활성 탭 배경색입니다. íƒ­ì€ íŽ¸ì§‘ê¸° ì˜ì—­ì—ì„œ íŽ¸ì§‘ê¸°ì˜ ì»¨í…Œì´ë„ˆìž…니다. í•œ 편집기 그룹ì—ì„œ 여러 íƒ­ì„ ì—´ 수 있습니다. 여러 편집기 ê·¸ë£¹ì´ ìžˆì„ ìˆ˜ 있습니다.", "tabBorder": "íƒ­ì„ ì„œë¡œ 구분하기 위한 í…Œë‘리입니다. íƒ­ì€ íŽ¸ì§‘ê¸° ì˜ì—­ì—ì„œ íŽ¸ì§‘ê¸°ì˜ ì»¨í…Œì´ë„ˆìž…니다. í•œ 편집기 ê·¸ë£¹ì— ì—¬ëŸ¬ íƒ­ì„ ì—´ 수 있습니다. 여러 편집기 ê·¸ë£¹ì´ ìžˆì„ ìˆ˜ 있습니다.", + "tabActiveForeground": "활성 ê·¸ë£¹ì˜ í™œì„± 탭 전경색입니다. íƒ­ì€ íŽ¸ì§‘ê¸° ì˜ì—­ì—ì„œ íŽ¸ì§‘ê¸°ì˜ ì»¨í…Œì´ë„ˆìž…니다. í•œ 편집기 그룹ì—ì„œ 여러 íƒ­ì„ ì—´ 수 있습니다. 여러 편집기 ê·¸ë£¹ì´ ìžˆì„ ìˆ˜ 있습니다.", + "tabInactiveForeground": "활성 ê·¸ë£¹ì˜ ë¹„í™œì„± 탭 전경색입니다. íƒ­ì€ íŽ¸ì§‘ê¸° ì˜ì—­ì—ì„œ íŽ¸ì§‘ê¸°ì˜ ì»¨í…Œì´ë„ˆìž…니다. í•œ 편집기 그룹ì—ì„œ 여러 íƒ­ì„ ì—´ 수 있습니다. 여러 편집기 ê·¸ë£¹ì´ ìžˆì„ ìˆ˜ 있습니다.", + "tabUnfocusedActiveForeground": "비활성 ê·¸ë£¹ì˜ í™œì„± 탭 전경색입니다. íƒ­ì€ íŽ¸ì§‘ê¸° ì˜ì—­ì—ì„œ íŽ¸ì§‘ê¸°ì˜ ì»¨í…Œì´ë„ˆìž…니다. í•œ 편집기 그룹ì—ì„œ 여러 íƒ­ì„ ì—´ 수 있습니다. 여러 편집기 ê·¸ë£¹ì´ ìžˆì„ ìˆ˜ 있습니다.", + "tabUnfocusedInactiveForeground": "비활성 ê·¸ë£¹ì˜ ë¹„í™œì„± 탭 전경색입니다. íƒ­ì€ íŽ¸ì§‘ê¸° ì˜ì—­ì—ì„œ íŽ¸ì§‘ê¸°ì˜ ì»¨í…Œì´ë„ˆìž…니다. í•œ 편집기 그룹ì—ì„œ 여러 íƒ­ì„ ì—´ 수 있습니다. 여러 편집기 ê·¸ë£¹ì´ ìžˆì„ ìˆ˜ 있습니다.", "editorGroupBackground": "편집기 ê·¸ë£¹ì˜ ë°°ê²½ìƒ‰ìž…ë‹ˆë‹¤. 편집기 ê·¸ë£¹ì€ íŽ¸ì§‘ê¸°ì˜ ì»¨í…Œì´ë„ˆìž…니다. ë°°ê²½ìƒ‰ì€ íŽ¸ì§‘ê¸° ê·¸ë£¹ì„ ëŒ ë•Œ 표시ë©ë‹ˆë‹¤.", + "tabsContainerBackground": "íƒ­ì„ ì‚¬ìš©ë„ë¡ ì„¤ì •í•œ 경우 편집기 그룹 제목 ë¨¸ë¦¬ê¸€ì˜ ë°°ê²½ìƒ‰ìž…ë‹ˆë‹¤. 편집기 ê·¸ë£¹ì€ íŽ¸ì§‘ê¸°ì˜ ì»¨í…Œì´ë„ˆìž…니다.", + "tabsContainerBorder": "íƒ­ì„ ì‚¬ìš©í•˜ë„ë¡ ì„¤ì •í•œ 경우 편집기 그룹 제목 ë¨¸ë¦¬ê¸€ì˜ í…Œë‘리 색입니다. 편집기 ê·¸ë£¹ì€ íŽ¸ì§‘ê¸°ì˜ ì»¨í…Œì´ë„ˆìž…니다.", "editorGroupHeaderBackground": "íƒ­ì„ ì‚¬ìš©í•˜ì§€ ì•Šë„ë¡ ì„¤ì •í•œ 경우 편집기 그룹 제목 ë¨¸ë¦¬ê¸€ì˜ ë°°ê²½ìƒ‰ìž…ë‹ˆë‹¤. 편집기 ê·¸ë£¹ì€ íŽ¸ì§‘ê¸°ì˜ ì»¨í…Œì´ë„ˆìž…니다.", "editorGroupBorder": "여러 편집기 ê·¸ë£¹ì„ ì„œë¡œ 구분하기 위한 색입니다. 편집기 ê·¸ë£¹ì€ íŽ¸ì§‘ê¸°ì˜ ì»¨í…Œì´ë„ˆìž…니다.", + "editorDragAndDropBackground": "편집기를 ëŒ ë•Œ 배경색입니다. 편집기 ë‚´ìš©ì´ ê³„ì† ë¹„ì¶”ì–´ ë³´ì´ë„ë¡ ì´ ìƒ‰ì€ íˆ¬ëª…í•´ì•¼ 합니다.", + "panelBackground": "íŒ¨ë„ ë°°ê²½ìƒ‰ìž…ë‹ˆë‹¤. 패ë„ì€ íŽ¸ì§‘ê¸° ì˜ì—­ ì•„ëž˜ì— í‘œì‹œë˜ë©° 출력 ë° í†µí•© í„°ë¯¸ë„ ê°™ì€ ë³´ê¸°ê°€ í¬í•¨ë©ë‹ˆë‹¤.", "panelBorder": "편집기와 구분ë˜ëŠ” 맨 ìœ„ì˜ íŒ¨ë„ í…Œë‘리 색입니다. 패ë„ì€ íŽ¸ì§‘ê¸° ì˜ì—­ ì•„ëž˜ì— í‘œì‹œë˜ë©° 출력 ë° í†µí•© í„°ë¯¸ë„ ê°™ì€ ë³´ê¸°ê°€ í¬í•¨ë©ë‹ˆë‹¤.", "panelActiveTitleForeground": "활성 패ë„ì˜ ì œëª© 색입니다. 패ë„ì€ íŽ¸ì§‘ê¸° ì˜ì—­ ì•„ëž˜ì— í‘œì‹œë˜ë©° 출력 ë° í†µí•© í„°ë¯¸ë„ ê°™ì€ ë³´ê¸°ê°€ í¬í•¨ë©ë‹ˆë‹¤.", "panelInactiveTitleForeground": "비활성 패ë„ì˜ ì œëª© 색입니다. 패ë„ì€ íŽ¸ì§‘ê¸° ì˜ì—­ ì•„ëž˜ì— í‘œì‹œë˜ë©° 출력 ë° í†µí•© í„°ë¯¸ë„ ê°™ì€ ë³´ê¸°ê°€ í¬í•¨ë©ë‹ˆë‹¤.", "panelActiveTitleBorder": "활성 íŒ¨ë„ ì œëª©ì˜ í…Œë‘리 색입니다. 패ë„ì€ íŽ¸ì§‘ê¸° ì˜ì—­ ì•„ëž˜ì— í‘œì‹œë˜ë©° 출력 ë° í†µí•© í„°ë¯¸ë„ ê°™ì€ ë³´ê¸°ê°€ í¬í•¨ë©ë‹ˆë‹¤.", "statusBarForeground": "ìƒíƒœ 표시줄 전경색입니다. ìƒíƒœ í‘œì‹œì¤„ì€ ì°½ì˜ ë§¨ ì•„ëž˜ì— í‘œì‹œë©ë‹ˆë‹¤.", "statusBarBackground": "표준 ìƒíƒœ 표시줄 배경색입니다. ìƒíƒœ í‘œì‹œì¤„ì€ ì°½ì˜ ë§¨ ì•„ëž˜ì— í‘œì‹œë©ë‹ˆë‹¤.", + "statusBarBorder": "사ì´ë“œë°” ë° íŽ¸ì§‘ê¸°ì™€ 구분하는 ìƒíƒœ 표시줄 í…Œë‘리 색입니다. ìƒíƒœ í‘œì‹œì¤„ì€ ì°½ì˜ ë§¨ ì•„ëž˜ì— í‘œì‹œë©ë‹ˆë‹¤.", "statusBarNoFolderBackground": "í´ë”ê°€ 열리지 ì•Šì•˜ì„ ë•Œì˜ ìƒíƒœ 표시줄 배경색입니다. ìƒíƒœ í‘œì‹œì¤„ì€ ì°½ì˜ ë§¨ ì•„ëž˜ì— í‘œì‹œë©ë‹ˆë‹¤.", + "statusBarNoFolderForeground": "í´ë”ê°€ 열리지 ì•Šì•˜ì„ ë•Œì˜ ìƒíƒœ 표시줄 전경색입니다. ìƒíƒœ í‘œì‹œì¤„ì€ ì°½ì˜ ë§¨ ì•„ëž˜ì— í‘œì‹œë©ë‹ˆë‹¤.", "statusBarItemActiveBackground": "í´ë¦­í•  ë•Œì˜ ìƒíƒœ 표시줄 항목 배경색입니다. ìƒíƒœ í‘œì‹œì¤„ì€ ì°½ì˜ ë§¨ ì•„ëž˜ì— í‘œì‹œë©ë‹ˆë‹¤.", "statusBarItemHoverBackground": "마우스로 가리킬 ë•Œì˜ ìƒíƒœ 표시줄 항목 배경색입니다. ìƒíƒœ í‘œì‹œì¤„ì€ ì°½ì˜ ë§¨ ì•„ëž˜ì— í‘œì‹œë©ë‹ˆë‹¤.", "statusBarProminentItemBackground": "ìƒíƒœ 표시줄 주요 항목 배경색입니다. 주요 í•­ëª©ì€ ì¤‘ìš”ë„를 나타내는 다른 ìƒíƒœ 표시줄 항목보다 ëˆˆì— ìž˜ ë•ë‹ˆë‹¤. ìƒíƒœ í‘œì‹œì¤„ì€ ì°½ì˜ ë§¨ ì•„ëž˜ì— í‘œì‹œë©ë‹ˆë‹¤.", "statusBarProminentItemHoverBackground": "마우스로 가리킬 ë•Œì˜ ìƒíƒœ 표시줄 주요 항목 배경색입니다. 주요 í•­ëª©ì€ ì¤‘ìš”ë„를를 나타내는 다른 ìƒíƒœ 표시줄 항목보다 ëˆˆì— ìž˜ ë•ë‹ˆë‹¤. ìƒíƒœ í‘œì‹œì¤„ì€ ì°½ì˜ ë§¨ ì•„ëž˜ì— í‘œì‹œë©ë‹ˆë‹¤.", "activityBarBackground": "ìž‘ì—… 막대 배경색입니다. ìž‘ì—… 막대는 맨 왼쪽ì´ë‚˜ ì˜¤ë¥¸ìª½ì— í‘œì‹œë˜ë©° 사ì´ë“œë°”ì˜ ë·° ê°„ì„ ì „í™˜í•˜ëŠ” ë° ì‚¬ìš©í•  수 있습니다.", "activityBarForeground": "ìž‘ì—… 막대 ì „ê²½ 색(예: ì•„ì´ì½˜ì— 사용ë¨)입니다. ìž‘ì—… 막대는 오른쪽ì´ë‚˜ 왼쪽 ëì— í‘œì‹œë˜ë©° 사ì´ë“œë°”ì˜ ë³´ê¸° ê°„ì„ ì „í™˜í•  수 있습니다.", + "activityBarBorder": "사ì´ë“œë°”와 구분하는 ìž‘ì—… 막대 í…Œë‘리색입니다. ìž‘ì—… 막대는 오른쪽ì´ë‚˜ 왼쪽 ëì— í‘œì‹œë˜ë©° 사ì´ë“œë°”ì˜ ë³´ê¸° ê°„ì„ ì „í™˜í•  수 있습니다.", + "activityBarDragAndDropBackground": "ìž‘ì—… 막대 í•­ëª©ì˜ ëŒì–´ì„œ 놓기 피드백 색입니다. ìž‘ì—… 막대 í•­ëª©ì´ ê³„ì† ë¹„ì¶”ì–´ ë³´ì´ë„ë¡ ì´ ìƒ‰ì€ íˆ¬ëª…í•´ì•¼ 합니다. ìž‘ì—… 막대는 왼쪽ì´ë‚˜ 오른쪽 ëì— í‘œì‹œë˜ë©° 사ì´ë“œë°”ì˜ ë³´ê¸°ë¥¼ 전환할 수 있습니다.", "activityBarBadgeBackground": "í™œë™ ì•Œë¦¼ 배지 배경색입니다. ìž‘ì—… 막대는 왼쪽ì´ë‚˜ 오른쪽 ëì— í‘œì‹œë˜ë©° 사ì´ë“œë°”ì˜ ë³´ê¸°ë¥¼ 전환할 수 있습니다.", "activityBarBadgeForeground": "í™œë™ ì•Œë¦¼ 배지 전경색입니다. ìž‘ì—… 막대는 왼쪽ì´ë‚˜ 오른쪽 ëì— í‘œì‹œë˜ë©° 사ì´ë“œë°”ì˜ ë³´ê¸°ë¥¼ 전환할 수 있습니다.", "sideBarBackground": "사ì´ë“œë°” 배경색입니다. 사ì´ë“œë°”는 íƒìƒ‰ê¸° ë° ê²€ìƒ‰ê³¼ ê°™ì€ ë·°ì˜ ì»¨í…Œì´ë„ˆìž…니다.", + "sideBarForeground": "사ì´ë“œë°” 전경색입니다. 사ì´ë“œë°”는 íƒìƒ‰ê¸° ë° ê²€ìƒ‰ê³¼ ê°™ì€ ë·°ì˜ ì»¨í…Œì´ë„ˆìž…니다.", + "sideBarBorder": "편집기와 구분하는 ì¸¡ë©´ì˜ ì‚¬ì´ë“œë°” í…Œë‘리 색입니다. 사ì´ë“œë°”는 íƒìƒ‰ê¸° ë° ê²€ìƒ‰ê³¼ ê°™ì€ ë·°ì˜ ì»¨í…Œì´ë„ˆìž…니다.", "sideBarTitleForeground": "사ì´ë“œë°” 제목 전경색입니다. 사ì´ë“œë°”는 íƒìƒ‰ê¸° ë° ê²€ìƒ‰ê³¼ ê°™ì€ ë·°ì˜ ì»¨í…Œì´ë„ˆìž…니다.", "sideBarSectionHeaderBackground": "사ì´ë“œë°” 섹션 í—¤ë” ë°°ê²½ìƒ‰ìž…ë‹ˆë‹¤. 사ì´ë“œë°”는 íƒìƒ‰ê¸° ë° ê²€ìƒ‰ê³¼ ê°™ì€ ë·°ì˜ ì»¨í…Œì´ë„ˆìž…니다.", + "sideBarSectionHeaderForeground": "사ì´ë“œë°” 섹션 í—¤ë” ì „ê²½ìƒ‰ìž…ë‹ˆë‹¤. 사ì´ë“œë°”는 íƒìƒ‰ê¸° ë° ê²€ìƒ‰ê³¼ ê°™ì€ ë·°ì˜ ì»¨í…Œì´ë„ˆìž…니다.", "titleBarActiveForeground": "ì°½ì´ í™œì„±í™”ëœ ê²½ìš°ì˜ ì œëª© 표시줄 전경입니다. ì´ ìƒ‰ì€ í˜„ìž¬ macOSì—서만 지ì›ë©ë‹ˆë‹¤.", "titleBarInactiveForeground": "ì°½ì´ ë¹„í™œì„±í™”ëœ ê²½ìš°ì˜ ì œëª© 표시줄 전경입니다. ì´ ìƒ‰ì€ í˜„ìž¬ macOSì—서만 지ì›ë©ë‹ˆë‹¤.", "titleBarActiveBackground": "ì°½ì„ í™œì„±í™”í•  ë•Œì˜ ì œëª© 표시줄 전경입니다. ì´ ìƒ‰ì€ í˜„ìž¬ macOSì—서만 지ì›ë©ë‹ˆë‹¤.", diff --git a/i18n/kor/src/vs/workbench/electron-browser/actions.i18n.json b/i18n/kor/src/vs/workbench/electron-browser/actions.i18n.json index dce95cceba8..f17d6eb1c6e 100644 --- a/i18n/kor/src/vs/workbench/electron-browser/actions.i18n.json +++ b/i18n/kor/src/vs/workbench/electron-browser/actions.i18n.json @@ -6,9 +6,6 @@ { "closeActiveEditor": "편집기 닫기", "closeWindow": "ì°½ 닫기", - "switchWindow": "ì°½ 전환", - "switchWindowPlaceHolder": "ì°½ ì„ íƒ", - "current": "현재 ì°½", "closeFolder": "í´ë” 닫기", "noFolderOpened": "ì´ ì¸ìŠ¤í„´ìŠ¤ì— 현재 ì—´ë ¤ 있는 ë‹«ì„ í´ë”ê°€ 없습니다.", "newWindow": "새 ì°½", @@ -20,7 +17,7 @@ "zoomReset": "확대/축소 다시 설정", "appPerf": "시작 성능", "reloadWindow": "ì°½ 다시 로드", - "openRecent": "최근 íŒŒì¼ ì—´ê¸°", + "current": "현재 ì°½", "folders": "í´ë”", "files": "파ì¼", "openRecentPlaceHolderMac": "경로 ì„ íƒ(새 ì°½ì—ì„œ 열려면 Cmd 키를 길게 누름)", @@ -32,10 +29,6 @@ "openDocumentationUrl": "설명서", "openIntroductoryVideosUrl": "소개 비디오", "toggleSharedProcess": "공유 프로세스 설정/í•´ì œ", - "navigateLeft": "ë·° 왼쪽으로 ì´ë™", - "navigateRight": "ë·° 오른쪽으로 ì´ë™", - "navigateUp": "ë·° 위로 ì´ë™", - "navigateDown": "ë·° 아래로 ì´ë™", "increaseViewSize": "현재 ë·° í¬ê¸° 늘리기", "decreaseViewSize": "현재 ë·° í¬ê¸° 줄ì´ê¸°" } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/kor/src/vs/workbench/electron-browser/main.contribution.i18n.json index 4c30f4bc75c..2bb9dd4aa48 100644 --- a/i18n/kor/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/kor/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -31,10 +31,6 @@ "window.openFoldersInNewWindow.off": "í´ë”ê°€ 마지막 활성 ì°½ì„ ë°”ê¿‰ë‹ˆë‹¤.", "window.openFoldersInNewWindow.default": "í´ë”를 ì‘ìš© 프로그램 ë‚´ì—ì„œ ì„ íƒ(예: íŒŒì¼ ë©”ë‰´ë¥¼ 통해)하는 경우를 제외하고 í´ë”ê°€ 새 ì°½ì—ì„œ 열립니다.", "openFoldersInNewWindow": "í´ë”를 새 ì°½ì—ì„œ 열지, 마지막 활성 창과 바꿀지를 제어합니다.\n- default: ì‘ìš© 프로그램 ë‚´ì—ì„œ [파ì¼] 메뉴 ë“±ì„ í†µí•´ í´ë”를 ì„ íƒí•˜ëŠ” 경우를 제외하고, í´ë”는 새 ì°½ì—ì„œ 열립니다.\n- on: í´ë”ê°€ 새 ì°½ì—ì„œ 열립니다.\n- off: í´ë”ê°€ 마지막 활성 ì°½ì„ ëŒ€ì²´í•©ë‹ˆë‹¤\nì´ ì„¤ì •ì´ ë¬´ì‹œë˜ëŠ” ê²½ìš°ë„ ìžˆì„ ìˆ˜ 있습니다(예: -new-window ë˜ëŠ” -reuse-window 명령줄 ì˜µì…˜ì„ ì‚¬ìš©í•  경우).", - "window.reopenFolders.none": "í´ë”를 다시 열지 않습니다.", - "window.reopenFolders.one": "마지막 활성 í´ë”를 다시 엽니다.", - "window.reopenFolders.all": "마지막 ì„¸ì…˜ì˜ ëª¨ë“  í´ë”를 다시 엽니다.", - "reopenFolders": "다시 시작한 ì´í›„ì— í´ë”를 다시 여는 ë°©ë²•ì„ ì œì–´í•©ë‹ˆë‹¤. í´ë”를 다시 열지 않으려면 'none'ì„ ì„ íƒí•˜ê³ , 마지막으로 ìž‘ì—…í•œ í´ë”를 다시 열려면 'one'ì„ ì„ íƒí•˜ê³ , 마지막 ì„¸ì…˜ì˜ ëª¨ë“  í´ë”를 다시 열려면 'all'ì„ ì„ íƒí•©ë‹ˆë‹¤.", "restoreFullscreen": "ì°½ì´ ì „ì²´ 화면 모드ì—ì„œ ì¢…ë£Œëœ ê²½ìš° ì°½ì„ ì „ì²´ 화면 모드로 ë³µì›í• ì§€ 여부를 제어합니다.", "zoomLevel": "ì°½ì˜ í™•ëŒ€/축소 ìˆ˜ì¤€ì„ ì¡°ì •í•©ë‹ˆë‹¤. ì›ëž˜ í¬ê¸°ëŠ” 0ì´ê³  ê° ìƒí•œ ì¦ë¶„(예: 1) ë˜ëŠ” 하한 ì¦ë¶„(예: -1)ì€ 20% ë” í¬ê±°ë‚˜ ë” ìž‘ê²Œ 확대/축소하는 ê²ƒì„ ë‚˜íƒ€ëƒ…ë‹ˆë‹¤. 10진수를 입력하여 확대/축소 ìˆ˜ì¤€ì„ ì„¸ë¶€ì ìœ¼ë¡œ ì¡°ì •í•  ìˆ˜ë„ ìžˆìŠµë‹ˆë‹¤.", "title": "활성 편집기를 기반으로 ì°½ ì œëª©ì„ ì œì–´í•©ë‹ˆë‹¤. 변수는 컨í…스트를 기반으로 대체ë©ë‹ˆë‹¤.\n${activeEditorShort}: 예: myFile.txt\n${activeEditorMedium}: 예: myFolder/myFile.txt\n${activeEditorLong}: 예: /Users/Development/myProject/myFolder/myFile.txt\n${rootName}: 예: myProject\n${rootPath}: 예: /Users/Development/myProject\n${appName}: 예: VS Code\n${dirty}: 활성 편집기가 ë”í‹°ì¸ ê²½ìš° ë”í‹° 표시기\n${separator}: ê°’ì´ ìžˆëŠ” 변수로 ë‘˜ëŸ¬ì‹¸ì¸ ê²½ìš°ì—만 표시ë˜ëŠ” 조건부 구분 기호(\" - \")", @@ -42,11 +38,13 @@ "window.newWindowDimensions.inherit": "마지막 활성 창과 ë™ì¼í•œ í¬ê¸°ë¡œ 새 ì°½ì„ ì—½ë‹ˆë‹¤.", "window.newWindowDimensions.maximized": "ìµœëŒ€í™”ëœ ìƒˆ ì°½ì„ ì—½ë‹ˆë‹¤.", "window.newWindowDimensions.fullscreen": "ì „ì²´ 화면 모드ì—ì„œ 새 ì°½ì„ ì—½ë‹ˆë‹¤.", + "newWindowDimensions": "하나 ì´ìƒì˜ ì°½ì´ ì´ë¯¸ ì—´ë ¤ ìžˆì„ ë•Œ 여는 새 새 ì°½ì˜ í¬ê¸°ë¥¼ 제어합니다. 기본ì ìœ¼ë¡œ 새 ì°½ì€ í™”ë©´ 가운ë°ì— ìž‘ì€ í¬ê¸°ë¡œ 열립니다. 'inherit'으로 설정할 경우 마지막 활성 창과 ë™ì¼í•œ í¬ê¸°ë¡œ ì°½ì´ ì—´ë¦½ë‹ˆë‹¤. 'maximized'ë¡œ 설정할 경우 ì°½ì´ ìµœëŒ€í™”ë˜ì–´ 열리고 'fullscreen'으로 구성할 경우 ì „ì²´ 화면으로 열립니다. ì´ ì„¤ì •ì€ ì—¬ëŠ” 첫 번째 ì°½ì—는 ì ìš©ë˜ì§€ 않습니다. 첫 번째 ì°½ì˜ ê²½ìš° í•­ìƒ ì°½ì„ ë‹«ê¸° ì „ì˜ í¬ê¸°ì™€ 위치가 ë³µì›ë©ë‹ˆë‹¤.", "window.menuBarVisibility.default": "메뉴가 ì „ì²´ 화면 모드ì—서만 숨겨집니다.", "window.menuBarVisibility.visible": "메뉴가 ì „ì²´ 화면 모드ì—ì„œë„ í•­ìƒ í‘œì‹œë©ë‹ˆë‹¤.", "window.menuBarVisibility.toggle": "메뉴가 숨겨져 있지만 키를 통해 메뉴를 표시할 수 있습니다.", "window.menuBarVisibility.hidden": "메뉴가 í•­ìƒ ìˆ¨ê²¨ì§‘ë‹ˆë‹¤.", "menuBarVisibility": "메뉴 모ìŒì˜ 표시 여부를 제어합니다. '설정/í•´ì œ'를 ì„¤ì •í•¨ìœ¼ë¡œì¨ ë©”ë‰´ 모ìŒì´ 숨겨지고 키를 누를 때마다 메뉴 모ìŒì´ 표시ë©ë‹ˆë‹¤. 기본값으로, ì°½ì´ ì „ì²´ í™”ë©´ì¸ ê²½ìš°ë¥¼ 제외하고 메뉴 모ìŒì´ 표시ë©ë‹ˆë‹¤.", + "enableMenuBarMnemonics": "사용하ë„ë¡ ì„¤ì •í•˜ëŠ” 경우 Alt 키 바로 가기를 통해 주 메뉴를 ì—´ 수 있습니다. ë‹ˆëª¨ë‹‰ì„ ì‚¬ìš©í•˜ì§€ ì•Šë„ë¡ ì„¤ì •í•˜ë©´ 대신 ì´ëŸ¬í•œ Alt 키 바로 가기를 편집기 ëª…ë ¹ì— ë°”ì¸ë”©í•  수 있습니다.", "autoDetectHighContrast": "사용하ë„ë¡ ì„¤ì •í•œ 경우 Windowsì—ì„œ 고대비 테마를 사용 중ì´ë©´ 고대비 테마로 ìžë™ìœ¼ë¡œ 변경ë˜ê³  Windows 고대비 테마를 해제하면 ì–´ë‘ìš´ 테마로 변경ë©ë‹ˆë‹¤.", "titleBarStyle": "ì°½ 제목 í‘œì‹œì¤„ì˜ ëª¨ì–‘ì„ ì¡°ì •í•©ë‹ˆë‹¤. 변경 ë‚´ìš©ì„ ì ìš©í•˜ë ¤ë©´ ì „ì²´ 다시 시작해야 합니다.", "window.nativeTabs": "macOS Sierra ì°½ íƒ­ì„ ì‚¬ìš©í•˜ë„ë¡ ì„¤ì •í•©ë‹ˆë‹¤. 변경\n ë‚´ìš©ì„ ì ìš©í•˜ë ¤ë©´ ì „ì²´ 다시 시작해야 하고, 기본 탭ì—ì„œ\n ì‚¬ìš©ìž ì§€ì • 제목 표시줄 스타ì¼(êµ¬ì„±ëœ ê²½ìš°)ì„ ë¹„í™œì„±í™”í•©ë‹ˆë‹¤.", @@ -56,5 +54,7 @@ "zenMode.hideTabs": "Zen 모드를 켜면 워í¬ë²¤ì¹˜ íƒ­ë„ ìˆ¨ê¸¸ì§€ë¥¼ 제어합니다.", "zenMode.hideStatusBar": "Zen 모드를 켜면 워í¬ë²¤ì¹˜ 하단ì—ì„œ ìƒíƒœ í‘œì‹œì¤„ë„ ìˆ¨ê¸¸ì§€ë¥¼ 제어합니다.", "zenMode.hideActivityBar": "Zen 모드를 켜면 워í¬ë²¤ì¹˜ì˜ ì™¼ìª½ì— ìžˆëŠ” ìž‘ì—… ë§‰ëŒ€ë„ ìˆ¨ê¸¸ì§€\n 여부를 제어합니다.", - "zenMode.restore": "ì°½ì´ Zen 모드ì—ì„œ ì¢…ë£Œëœ ê²½ìš° Zen 모드로 ë³µì›í• ì§€ 제어합니다." + "zenMode.restore": "ì°½ì´ Zen 모드ì—ì„œ ì¢…ë£Œëœ ê²½ìš° Zen 모드로 ë³µì›í• ì§€ 제어합니다.", + "workspaceConfigurationTitle": "ìž‘ì—… ì˜ì—­", + "files.exclude.boolean": "íŒŒì¼ ê²½ë¡œë¥¼ ì¼ì¹˜ì‹œí‚¬ GLOB 패턴입니다. íŒ¨í„´ì„ ì‚¬ìš©í•˜ê±°ë‚˜ 사용하지 ì•Šë„ë¡ ì„¤ì •í•˜ë ¤ë©´ true ë˜ëŠ” falseë¡œ 설정하세요." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json b/i18n/kor/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json new file mode 100644 index 00000000000..e7e010529e2 --- /dev/null +++ b/i18n/kor/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json @@ -0,0 +1,26 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "emergencyConfOn": "ì´ì œ `editor.accessibilitySupport` ì„¤ì •ì„ 'on'으로 변경합니다.", + "openingDocs": "ì´ì œ VS Code 접근성 설명서 페ì´ì§€ë¥¼ 엽니다.", + "introMsg": "VS Codeì˜ ì ‘ê·¼ì„± ì˜µì…˜ì„ ì‚¬ìš©í•´ 주셔서 ê°ì‚¬í•©ë‹ˆë‹¤.", + "status": "ìƒíƒœ:", + "changeConfigToOnMac": "화면 ì½ê¸° 프로그램ì—ì„œ ì‚¬ìš©ì— ì˜êµ¬ì ìœ¼ë¡œ 최ì í™”ë˜ë„ë¡ íŽ¸ì§‘ê¸°ë¥¼ 구성하려면 지금 Command+E를 누르세요.", + "changeConfigToOnWinLinux": "화면 ì½ê¸° 프로그램ì—ì„œ ì‚¬ìš©ì— ì˜êµ¬ì ìœ¼ë¡œ 최ì í™”ë˜ë„ë¡ íŽ¸ì§‘ê¸°ë¥¼ 구성하려면 지금 Command+E를 누르세요.", + "auto_unknown": "편집기는 í”Œëž«í¼ API를 사용하여 화면 ì½ê¸° í”„ë¡œê·¸ëž¨ì´ ì—°ê²°ë˜ëŠ” 시기를 검색하ë„ë¡ êµ¬ì„±ë˜ì–´ 있지만 현재 런타임ì—서는 ì´ êµ¬ì„±ì„ ì§€ì›í•˜ì§€ 않습니다.", + "auto_on": "편집기는 화면 ì½ê¸° í”„ë¡œê·¸ëž¨ì´ ì—°ê²°ë˜ì–´ 있ìŒì„ ìžë™ìœ¼ë¡œ\n 검색했습니다.", + "auto_off": "편집기는 화면 편집기가 ì—°ê²°ë˜ëŠ” 시기를 ìžë™ìœ¼ë¡œ 검색하ë„ë¡ êµ¬ì„±ë˜ì–´ 있지만, ì´ êµ¬ì„±ì€ í˜„ìž¬ 지ì›ë˜ì§€ 않습니다.", + "configuredOn": "편집기는 화면 ì½ê¸° 프로그램ì—ì„œ ì‚¬ìš©ì— ì˜êµ¬ì ìœ¼ë¡œ 최ì í™”ë˜ë„ë¡ íŽ¸ì§‘ê¸°ë¥¼ 구성ë˜ì–´ 있습니다. `editor.accessibilitySupport` ì„¤ì •ì„ íŽ¸ì§‘í•˜ì—¬ ì´ êµ¬ì„±ì„ ë³€ê²½í•  수 있습니다.", + "configuredOff": "편집기는 화면 ì½ê¸° 프로그램ì—ì„œ ì‚¬ìš©ì— ìµœì í™”ë˜ì§€ ì•Šë„ë¡ êµ¬ì„±ë˜ì—ˆìŠµë‹ˆë‹¤.", + "tabFocusModeOnMsg": "현재 편집기ì—ì„œ 키를 누르면 í¬ì»¤ìŠ¤ê°€ ë‹¤ìŒ í¬ì»¤ìŠ¤ 가능한 요소로 ì´ë™í•©ë‹ˆë‹¤. {0}ì„(를) 눌러서 ì´ ë™ìž‘ì„ ì„¤ì •/해제합니다.", + "tabFocusModeOnMsgNoKb": "현재 편집기ì—ì„œ 키를 누르면 í¬ì»¤ìŠ¤ê°€ ë‹¤ìŒ í¬ì»¤ìŠ¤ 가능한 요소로 ì´ë™í•©ë‹ˆë‹¤. {0} ëª…ë ¹ì€ í˜„ìž¬ 키 ë°”ì¸ë”©ìœ¼ë¡œ 트리거할 수 없습니다.", + "tabFocusModeOffMsg": "현재 편집기ì—ì„œ 키를 누르면 탭 문ìžê°€ 삽입ë©ë‹ˆë‹¤. {0}ì„(를) 눌러서 ì´ ë™ìž‘ì„ ì„¤ì •/해제합니다.", + "tabFocusModeOffMsgNoKb": "현재 편집기ì—ì„œ 키를 누르면 탭 문ìžê°€ 삽입ë©ë‹ˆë‹¤. {0} ëª…ë ¹ì€ í˜„ìž¬ 키 ë°”ì¸ë”©ìœ¼ë¡œ 트리거할 수 없습니다.", + "openDocMac": "브ë¼ìš°ì € ì°½ì— ì ‘ê·¼ì„±ê³¼ ê´€ë ¨ëœ ì¶”ê°€ VS Code 정보를 열려면 Command+H를 누르세요.", + "openDocWinLinux": "브ë¼ìš°ì € ì°½ì— ì ‘ê·¼ì„±ê³¼ ê´€ë ¨ëœ ì¶”ê°€ VS Code 정보를 열려면 지금 Control+H를 누르세요.", + "outroMsg": "ì´ ë„구 ì„¤ëª…ì„ í•´ì œí•˜ê³  Esc 키 ë˜ëŠ” Shift+Esc를 눌러서 편집기로 ëŒì•„ê°ˆ 수 있습니다.", + "ShowAccessibilityHelpAction": "접근성 ë„ì›€ë§ í‘œì‹œ" +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json b/i18n/kor/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/kor/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json b/i18n/kor/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json new file mode 100644 index 00000000000..4b0a0af7f76 --- /dev/null +++ b/i18n/kor/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleLocation": "다중 커서 í•œì •ìž ì„¤ì •/í•´ì œ" +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/debug/browser/debugActions.i18n.json b/i18n/kor/src/vs/workbench/parts/debug/browser/debugActions.i18n.json index 60f3a207808..46ca3defb9b 100644 --- a/i18n/kor/src/vs/workbench/parts/debug/browser/debugActions.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/debug/browser/debugActions.i18n.json @@ -6,6 +6,7 @@ { "openLaunchJson": "{0} 열기", "launchJsonNeedsConfigurtion": "'launch.json' 구성 ë˜ëŠ” 수정", + "noFolderDebugConfig": "고급 디버그 êµ¬ì„±ì„ ìˆ˜í–‰í•˜ë ¤ë©´ 먼저 í´ë”를 여세요.", "startDebug": "디버깅 시작", "startWithoutDebugging": "디버깅하지 ì•Šê³  시작", "selectAndStartDebugging": "디버깅 ì„ íƒ ë° ì‹œìž‘", diff --git a/i18n/kor/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json b/i18n/kor/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json index 8b6ad71cd4e..9f3ccc2a869 100644 --- a/i18n/kor/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "noFolderDebugConfig": "고급 디버그 êµ¬ì„±ì„ ìˆ˜í–‰í•˜ë ¤ë©´ 먼저 í´ë”를 여세요." +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json b/i18n/kor/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json index c9ed1bd1f22..b890a7946e2 100644 --- a/i18n/kor/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json @@ -5,16 +5,12 @@ // Do not edit this file. It is machine generated. { "variablesSection": "변수 섹션", - "variables": "변수", "variablesAriaTreeLabel": "변수 디버그", "expressionsSection": "ì‹ ì„¹ì…˜", - "watch": "조사ì‹", "watchAriaTreeLabel": "ì¡°ì‚¬ì‹ ë””ë²„ê·¸", "callstackSection": "호출 ìŠ¤íƒ ì„¹ì…˜", "debugStopped": "{0}ì—ì„œ ì¼ì‹œ 중지ë¨", - "callStack": "호출 스íƒ", "callStackAriaLabel": "호출 ìŠ¤íƒ ë””ë²„ê·¸", "breakpointsSection": "ì¤‘ë‹¨ì  ì„¹ì…˜", - "breakpoints": "중단ì ", "breakpointsAriaTreeLabel": "ì¤‘ë‹¨ì  ë””ë²„ê·¸" } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json b/i18n/kor/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json index 889e2264a01..0477024ab5d 100644 --- a/i18n/kor/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json @@ -6,5 +6,6 @@ { "copyValue": "ê°’ 복사", "copy": "복사", + "copyAll": "ëª¨ë‘ ë³µì‚¬", "copyStackTrace": "호출 ìŠ¤íƒ ë³µì‚¬" } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json b/i18n/kor/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json index fa9a8cbb690..6de8809b45e 100644 --- a/i18n/kor/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "statusBarDebuggingBackground": "í”„ë¡œê·¸ëž¨ì´ ë””ë²„ê·¸ë  ë•Œì˜ ìƒíƒœ 표시줄 배경색입니다. ìƒíƒœ í‘œì‹œì¤„ì€ ì°½ì˜ ë§¨ ì•„ëž˜ì— í‘œì‹œë©ë‹ˆë‹¤." + "statusBarDebuggingBackground": "í”„ë¡œê·¸ëž¨ì´ ë””ë²„ê·¸ë  ë•Œì˜ ìƒíƒœ 표시줄 배경색입니다. ìƒíƒœ í‘œì‹œì¤„ì€ ì°½ì˜ ë§¨ ì•„ëž˜ì— í‘œì‹œë©ë‹ˆë‹¤.", + "statusBarDebuggingForeground": "í”„ë¡œê·¸ëž¨ì´ ë””ë²„ê·¸ë  ë•Œì˜ ìƒíƒœ 표시줄 전경색입니다. ìƒíƒœ í‘œì‹œì¤„ì€ ì°½ì˜ ë§¨ ì•„ëž˜ì— í‘œì‹œë©ë‹ˆë‹¤." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json b/i18n/kor/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json index fb59d091ab9..6be8b2345df 100644 --- a/i18n/kor/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json @@ -7,6 +7,7 @@ "debugAdapterBinNotFound": "디버그 어댑터 실행 íŒŒì¼ '{0}'ì´(ê°€) 없습니다.", "debugAdapterCannotDetermineExecutable": "디버그 어댑터 '{0}'ì— ëŒ€í•œ 실행 파ì¼ì„ 확ì¸í•  수 없습니다.", "debugType": "êµ¬ì„±ì˜ í˜•ì‹ìž…니다.", + "debugTypeNotRecognised": "디버그 형ì‹ì´ ì¸ì‹ë˜ì§€ 않습니다. 해당하는 디버그 í™•ìž¥ì„ ì„¤ì¹˜í•˜ê³  사용하ë„ë¡ ì„¤ì •í–ˆëŠ”ì§€ 확ì¸í•˜ì„¸ìš”.", "node2NotSupported": "\"node2\"는 ë” ì´ìƒ 지ì›ë˜ì§€ 않습니다. 대신 \"node\"를 사용하고 \"protocol\" íŠ¹ì„±ì„ \"inspector\"ë¡œ 설정하세요.", "debugName": "구성 ì´ë¦„ì´ë©°, 구성 시작 드롭다운 ë©”ë‰´ì— í‘œì‹œë©ë‹ˆë‹¤.", "debugRequest": "구성 형ì‹ì„ 요청합니다. \"시작\" ë˜ëŠ” \"ì—°ê²°\"ì¼ ìˆ˜ 있습니다.", diff --git a/i18n/kor/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json b/i18n/kor/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json index 739aa4ea537..12f82e199c9 100644 --- a/i18n/kor/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json @@ -4,6 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "previousEditPoint": "Emmet: ì´ì „ 편집 ì ", - "nextEditPoint": "Emmet: ë‹¤ìŒ íŽ¸ì§‘ ì " + "previousEditPoint": "Emmet: ì´ì „ 편집 ì ìœ¼ë¡œ ì´ë™", + "nextEditPoint": "Emmet: ë‹¤ìŒ íŽ¸ì§‘ ì ìœ¼ë¡œ ì´ë™" } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json b/i18n/kor/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json index b4ba4df288c..5b243d9a2c5 100644 --- a/i18n/kor/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json @@ -9,5 +9,6 @@ "emmetPreferences": "Emmetì˜ ì¼ë¶€ ìž‘ì—… ë° í•´ê²° í”„ë¡œê·¸ëž¨ì˜ ë™ìž‘ì„ ìˆ˜ì •í•˜ëŠ” ë° ì‚¬ìš©ë˜ëŠ” 기본 설정입니다.", "emmetSyntaxProfiles": "ì§€ì •ëœ êµ¬ë¬¸ì— ëŒ€í•œ í”„ë¡œí•„ì„ ì •ì˜í•˜ê±°ë‚˜ 특정 ê·œì¹™ì´ í¬í•¨ëœ 고유한 í”„ë¡œí•„ì„ ì‚¬ìš©í•˜ì„¸ìš”.", "emmetExclude": "Emmet 약어를 확장하면 안 ë˜ëŠ” ì–¸ì–´ì˜ ë°°ì—´ìž…ë‹ˆë‹¤.", - "emmetExtensionsPath": "Emmet 프로필, 코드 ì¡°ê° ë° ê¸°ë³¸ ì„¤ì •ì´ í¬í•¨ëœ í´ë”ì˜ ê²½ë¡œ" + "emmetExtensionsPath": "Emmet 프로필, 코드 ì¡°ê° ë° ê¸°ë³¸ ì„¤ì •ì´ í¬í•¨ëœ í´ë”ì˜ ê²½ë¡œ", + "useNewEmmet": "모든 emmet ê¸°ëŠ¥ì— ëŒ€í•´ 새 emmet ëª¨ë“ˆì„ ì‚¬ìš©í•´ 보세요(ì´ì „ ë‹¨ì¼ emmet ë¼ì´ë¸ŒëŸ¬ë¦¬ë¥¼ 대체함)." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json b/i18n/kor/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json index e290352a801..4600edbe9fd 100644 --- a/i18n/kor/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json @@ -24,6 +24,10 @@ "default": "기본값", "debuggers": "디버거({0})", "debugger name": "ì´ë¦„", + "views": "ë·°({0})", + "view id": "ID", + "view name": "ì´ë¦„", + "view location": "위치", "themes": "테마({0})", "JSON Validation": "JSON 유효성 검사({0})", "commands": "명령({0})", diff --git a/i18n/kor/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json b/i18n/kor/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json index 02f4f024176..748fbd6e5f8 100644 --- a/i18n/kor/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json @@ -22,6 +22,8 @@ "disableGloballyAction": "í•­ìƒ", "disableAction": "사용 안 함", "checkForUpdates": "ì—…ë°ì´íŠ¸ 확ì¸", + "enableAutoUpdate": "확장 ìžë™ ì—…ë°ì´íŠ¸ 사용", + "disableAutoUpdate": "확장 ìžë™ ì—…ë°ì´íŠ¸ 사용 안 함", "updateAll": "모든 확장 ì—…ë°ì´íŠ¸", "reloadAction": "다시 로드", "postUpdateTooltip": "ì—…ë°ì´íŠ¸í•˜ë ¤ë©´ 다시 로드", @@ -44,6 +46,8 @@ "showWorkspaceRecommendedExtensions": "ìž‘ì—… ì˜ì—­ 권장 확장 표시", "showRecommendedKeymapExtensions": "권장ë˜ëŠ” 키 맵 표시", "showRecommendedKeymapExtensionsShort": "키 맵", + "showLanguageExtensions": "언어 확장 표시", + "showLanguageExtensionsShort": "언어 확장", "configureWorkspaceRecommendedExtensions": "권장 확장 구성(ìž‘ì—… ì˜ì—­)", "ConfigureWorkspaceRecommendations.noWorkspace": "권장 ì‚¬í•­ì€ ìž‘ì—… ì˜ì—­ í´ë”ì—서만 사용할 수 있습니다.", "OpenExtensionsFile.failed": "'.vscode' í´ë”({0}) ë‚´ì— 'extensions.json' 파ì¼ì„ 만들 수 없습니다.", @@ -51,5 +55,8 @@ "disableAll": "ì„¤ì¹˜ëœ ëª¨ë“  확장 사용 안 함", "disableAllWorkspace": "ì´ ìž‘ì—… ì˜ì—­ì— 대해 ì„¤ì¹˜ëœ ëª¨ë“  확장 사용 안 함", "enableAll": "ì„¤ì¹˜ëœ ëª¨ë“  확장 사용", - "enableAllWorkspace": "ì´ ìž‘ì—… ì˜ì—­ì— 대해 ì„¤ì¹˜ëœ ëª¨ë“  확장 사용" + "enableAllWorkspace": "ì´ ìž‘ì—… ì˜ì—­ì— 대해 ì„¤ì¹˜ëœ ëª¨ë“  확장 사용", + "extensionButtonProminentBackground": "ëˆˆì— ìž˜ ë„는 ìž‘ì—… í™•ìž¥ì˜ ë‹¨ì¶” 배경색입니다(예: 설치 단추).", + "extensionButtonProminentForeground": "ëˆˆì— ìž˜ ë„는 ìž‘ì—… í™•ìž¥ì˜ ë‹¨ì¶” 전경색입니다(예: 설치 단추).", + "extensionButtonProminentHoverBackground": "ëˆˆì— ìž˜ ë„는 ìž‘ì—… í™•ìž¥ì˜ ë‹¨ì¶” ë°°ê²½ 커서 올리기 색입니다(예: 설치 단추)." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json b/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json index 84dc72bd8eb..3e7d2bd101a 100644 --- a/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json @@ -9,6 +9,8 @@ "neverShowAgain": "다시 표시 안 함", "close": "닫기", "workspaceRecommended": "ì´ ìž‘ì—… ì˜ì—­ì— 확장 권장 ì‚¬í•­ì´ ìžˆìŠµë‹ˆë‹¤.", + "ignoreExtensionRecommendations": "확장 권장 ì‚¬í•­ì„ ëª¨ë‘ ë¬´ì‹œí•˜ì‹œê² ìŠµë‹ˆê¹Œ?", + "ignoreAll": "예, ëª¨ë‘ ë¬´ì‹œ", "no": "아니요", "cancel": "취소" } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json b/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json index 467a41c361a..ef99dee28ef 100644 --- a/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json @@ -10,5 +10,6 @@ "extensions": "확장", "view": "보기", "extensionsConfigurationTitle": "확장", - "extensionsAutoUpdate": "ìžë™ìœ¼ë¡œ 확장 ì—…ë°ì´íŠ¸" + "extensionsAutoUpdate": "ìžë™ìœ¼ë¡œ 확장 ì—…ë°ì´íŠ¸", + "extensionsIgnoreRecommendations": "확장 권장 사항 무시" } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 77a77543915..f2a02a3a9f9 100644 --- a/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -4,8 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "disableOtherKeymapsConfirmation": "키 ë°”ì¸ë”© ê°„ 충ëŒì„ 피하기 위해 다른 키 맵({0})ì„ ì‚¬ìš©í•˜ì§€ ì•Šë„ë¡ ì„¤ì •í• ê¹Œìš”?", "yes": "예", "no": "아니요", + "betterMergeDisabled": "Better Merge í™•ìž¥ì´ ì´ì œ 빌드ë˜ì—ˆìŠµë‹ˆë‹¤. ì„¤ì¹˜ëœ í™•ìž¥ì€ ì‚¬ìš©í•˜ì§€ ì•Šë„ë¡ ì„¤ì •ë˜ì—ˆìœ¼ë©° 제거할 수 있습니다.", "uninstall": "제거", "later": "나중ì—" } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/kor/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index fe8ef9500ce..6ad22dfdfbc 100644 --- a/i18n/kor/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,6 +16,7 @@ "associations": "파ì¼ê³¼ ì–¸ì–´ì˜ ì—°ê²°ì„ êµ¬ì„±í•˜ì„¸ìš”(예: \"*.extension\": \"html\"). ì´ëŸ¬í•œ êµ¬ì„±ì€ ì„¤ì¹˜ëœ ì–¸ì–´ì˜ ê¸°ë³¸ 연결보다 ìš°ì„  순위가 높습니다.", "encoding": "파ì¼ì„ ì½ê³  쓸 ë•Œ 사용할 기본 ë¬¸ìž ì§‘í•© ì¸ì½”딩입니다.", "autoGuessEncoding": "사용하ë„ë¡ ì„¤ì •í•˜ëŠ” 경우 파ì¼ì„ ì—´ ë•Œ ë¬¸ìž ì§‘í•© ì¸ì½”ë”©ì„ ì¶”ì¸¡í•©ë‹ˆë‹¤.", + "eol": "줄 바꿈 문ìžì˜ 기본 ë입니다. LFì—는 \\n, CRLFì—는 \\r\\nì„ ì‚¬ìš©í•˜ì„¸ìš”.", "trimTrailingWhitespace": "사용하ë„ë¡ ì„¤ì •ë˜ë©´ 파ì¼ì„ 저장할 ë•Œ 후행 ê³µë°±ì´ ìž˜ë¦½ë‹ˆë‹¤.", "insertFinalNewline": "사용하ë„ë¡ ì„¤ì •ë˜ë©´ 저장할 ë•Œ íŒŒì¼ ëì— ë§ˆì§€ë§‰ ì¤„ë°”ê¿ˆì„ ì‚½ìž…í•©ë‹ˆë‹¤.", "files.autoSave.off": "ë”í‹° 파ì¼ì´ ìžë™ìœ¼ë¡œ 저장ë˜ì§€ 않습니다.", @@ -26,6 +27,7 @@ "autoSaveDelay": "ë”í‹° 파ì¼ì„ ìžë™ìœ¼ë¡œ 저장할 ë•Œê¹Œì§€ì˜ ì§€ì—°(밀리초)ì„ ì œì–´í•©ë‹ˆë‹¤. 'files.autoSave'를 '{0}'(으)ë¡œ 설정한 경우ì—만 ì ìš©ë©ë‹ˆë‹¤.", "watcherExclude": "íŒŒì¼ ê°ì‹œì—ì„œ 제외할 íŒŒì¼ ê²½ë¡œì˜ GLOB íŒ¨í„´ì„ êµ¬ì„±í•˜ì„¸ìš”. ì´ ì„¤ì •ì„ ë³€ê²½í•˜ë ¤ë©´ 다시 시작해야 합니다. 시작 ì‹œ Codeì—ì„œ CPU ì‹œê°„ì„ ë§Žì´ ì°¨ì§€í•˜ë©´ 대용량 í´ë”를 제외하여 초기 로드를 ì¤„ì¼ ìˆ˜ 있습니다.", "hotExit.off": "í•« 종료를 사용하지 않습니다.", + "hotExit.onExit": "í•« 종료는 ì‘ìš© í”„ë¡œê·¸ëž¨ì„ ë‹«ì„ ë•Œ 트리거ë©ë‹ˆë‹¤. 즉 Windows/Linuxì—ì„œ 마지막 ì°½ì„ ë‹«ì„ ë•Œë‚˜ workbench.action.quit ëª…ë ¹ì´ íŠ¸ë¦¬ê±°ë  ë•Œ(명령 팔레트, 키 ë°”ì¸ë”©, 메뉴)입니다. ë‹¤ìŒ ì‹¤í–‰ ì‹œ ë°±ì—…ì„ í¬í•¨í•œ 모든 ì°½ì´ ë³µì›ë©ë‹ˆë‹¤.", "hotExit": "저장하지 ì•Šì€ íŒŒì¼ì„ 세션 ê°„ì— ê¸°ì–µí•˜ì—¬, 편집기를 종료할 ë•Œ 저장할지 묻는 메시지를 건너뛸지 여부를 제어합니다.", "defaultLanguage": "새 파ì¼ì— 할당ë˜ëŠ” 기본 언어 모드입니다.", "editorConfigurationTitle": "편집기", diff --git a/i18n/kor/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json b/i18n/kor/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json index 3aeececa62a..d5e1244f535 100644 --- a/i18n/kor/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json @@ -5,7 +5,5 @@ // Do not edit this file. It is machine generated. { "explorerSection": "íŒŒì¼ íƒìƒ‰ê¸° 섹션", - "noWorkspace": "열린 í´ë” ì—†ìŒ", - "noWorkspaceHelp": "ì•„ì§ í´ë”를 열지 않았습니다.", "openFolder": "í´ë” 열기" } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json b/i18n/kor/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json index a820c30095a..cb51b565b31 100644 --- a/i18n/kor/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json @@ -4,8 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "openEditosrSection": "ì—´ë ¤ 있는 편집기 섹션", "openEditors": "ì—´ë ¤ 있는 편집기", + "openEditosrSection": "ì—´ë ¤ 있는 편집기 섹션", "treeAriaLabel": "열린 편집기: 활성 íŒŒì¼ ëª©ë¡", "dirtyCounter": "{0}ì´(ê°€) 저장ë˜ì§€ ì•ŠìŒ" } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/kor/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index ef1cdc9bc09..3eaa6c83509 100644 --- a/i18n/kor/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -9,5 +9,7 @@ "prof.message": "í”„ë¡œí•„ì„ ë§Œë“¤ì—ˆìŠµë‹ˆë‹¤.", "prof.detail": "문제를 ë°œìƒì‹œí‚¤ê³  ë‹¤ìŒ íŒŒì¼ì„ 수ë™ìœ¼ë¡œ 첨부하세요.\n{0}", "prof.restartAndFileIssue": "문제 만들기 ë° ë‹¤ì‹œ 시작", - "prof.restart": "다시 시작" + "prof.restart": "다시 시작", + "prof.thanks": "ë„ì›€ì„ ì£¼ì…”ì„œ ê°ì‚¬í•©ë‹ˆë‹¤.", + "prof.detail.restart": "ê³„ì† '{0}'ì„(를) 사용하려면 마지막으로 다시 시작해야 합니다. 기여해 주셔서 다시 한번 ê°ì‚¬ë“œë¦½ë‹ˆë‹¤." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/kor/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json index fee497eeb33..aa4e75fa0bc 100644 --- a/i18n/kor/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -5,5 +5,7 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.start": "키 ë°”ì¸ë”© ì •ì˜", - "defineKeybinding.kbLayoutErrorMessage": "현재 ìžíŒ ë°°ì—´ì—서는 ì´ í‚¤ ì¡°í•©ì„ ìƒì„±í•  수 없습니다." + "defineKeybinding.kbLayoutErrorMessage": "현재 ìžíŒ ë°°ì—´ì—서는 ì´ í‚¤ ì¡°í•©ì„ ìƒì„±í•  수 없습니다.", + "defineKeybinding.kbLayoutLocalAndUSMessage": "현재 ìžíŒ ë°°ì—´ì˜ ê²½ìš° **{0}**입니다(**{1}**: 미국 표준).", + "defineKeybinding.kbLayoutLocalMessage": "현재 ìžíŒ ë°°ì—´ì˜ ê²½ìš° **{0}**입니다." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json b/i18n/kor/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json index 353737131fc..47316538920 100644 --- a/i18n/kor/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json @@ -4,6 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "errorInvalidConfiguration": "ì„¤ì •ì— ì“¸ 수 없습니다. 파ì¼ì—ì„œ 오류/경고를 해결하고 다시 ì‹œë„하세요.", "editTtile": "편집", "replaceDefaultValue": "설정ì—ì„œ 바꾸기", "copyDefaultValue": "ì„¤ì •ì— ë³µì‚¬", diff --git a/i18n/kor/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json b/i18n/kor/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json index dec2d486f02..d410308122c 100644 --- a/i18n/kor/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "showTriggerActions": "모든 명령 표시", + "showCommands.label": "명령 팔레트...", "entryAriaLabelWithKey": "{0}, {1}, 명령", "entryAriaLabel": "{0}, 명령", "canNotRun": "'{0}' ëª…ë ¹ì€ ì—¬ê¸°ì—ì„œ 실행할 수 없습니다.", diff --git a/i18n/kor/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json b/i18n/kor/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json new file mode 100644 index 00000000000..f1cc0233f25 --- /dev/null +++ b/i18n/kor/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "relaunchMessage": "ì„¤ì •ì´ ë³€ê²½ë˜ì–´ 다시 시작해야만 ì ìš©ë©ë‹ˆë‹¤.", + "relaunchDetail": "[다시 시작] 단추를 눌러 {0}ì„(를) 다시 시작하고 ì„¤ì •ì„ ì‚¬ìš©í•˜ë„ë¡ ì„¤ì •í•˜ì„¸ìš”.", + "restart": "다시 시작" +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/kor/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json index 8b6ad71cd4e..98455580521 100644 --- a/i18n/kor/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "editorGutterModifiedBackground": "ìˆ˜ì •ëœ ì¤„ì˜ íŽ¸ì§‘ê¸° 여백 배경색입니다.", + "editorGutterAddedBackground": "ì¶”ê°€ëœ ì¤„ì˜ íŽ¸ì§‘ê¸° 여백 배경색입니다.", + "editorGutterDeletedBackground": "ì‚­ì œëœ ì¤„ì˜ íŽ¸ì§‘ê¸° 여백 배경색입니다." +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json b/i18n/kor/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json index 4b848835e91..791c967182a 100644 --- a/i18n/kor/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "toggleGitViewlet": "Git 표시", + "installAdditionalSCMProviders": "추가 SCM ê³µê¸‰ìž ì„¤ì¹˜...", "source control": "소스 제어", "toggleSCMViewlet": "SCM 표시", "view": "보기" diff --git a/i18n/kor/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json b/i18n/kor/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json index 550a8745b89..2910b5c28ea 100644 --- a/i18n/kor/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "installAdditionalSCMProviders": "추가 SCM ê³µê¸‰ìž ì„¤ì¹˜...", "switch provider": "SCM ê³µê¸‰ìž ì „í™˜..." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json b/i18n/kor/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json index 5346ff5c5cf..4d21f25e146 100644 --- a/i18n/kor/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json @@ -6,5 +6,7 @@ { "searchMatches": "ì¼ì¹˜í•˜ëŠ” {0}ê°œ í•­ëª©ì„ ì°¾ìŒ", "searchMatch": "ì¼ì¹˜í•˜ëŠ” {0}ê°œ í•­ëª©ì„ ì°¾ìŒ", - "fileMatchAriaLabel": "{2} í´ë”ì˜ {1} 파ì¼ì— {0}ê°œì˜ ì¼ì¹˜ í•­ëª©ì´ ìžˆìŒ, 검색 ê²°ê³¼" + "fileMatchAriaLabel": "{2} í´ë”ì˜ {1} 파ì¼ì— {0}ê°œì˜ ì¼ì¹˜ í•­ëª©ì´ ìžˆìŒ, 검색 ê²°ê³¼", + "replacePreviewResultAria": "{3} í…스트가 있는 ì¤„ì˜ ì—´ 위치 {2}ì—ì„œ ìš©ì–´ {0}ì„(를) {1}(으)ë¡œ 바꾸기", + "searchResultAria": "{2} í…스트가 있는 ì¤„ì˜ ì—´ 위치 {1}ì—ì„œ {0} ìš©ì–´ 찾기" } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json b/i18n/kor/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json index 65bffc51443..c9ce2ccb5f3 100644 --- a/i18n/kor/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json @@ -9,5 +9,6 @@ "vscode.extension.contributes.snippets-path": "코드 ì¡°ê° íŒŒì¼ì˜ 경로입니다. ì´ ê²½ë¡œëŠ” 확장 í´ë”ì˜ ìƒëŒ€ 경로ì´ë©° ì¼ë°˜ì ìœ¼ë¡œ './snippets/'ë¡œ 시작합니다.", "invalid.language": "`contributes.{0}.language`ì— ì•Œ 수 없는 언어가 있습니다. ì œê³µëœ ê°’: {1}", "invalid.path.0": "`contributes.{0}.path`ì— ë¬¸ìžì—´ì´ 필요합니다. ì œê³µëœ ê°’: {1}", - "invalid.path.1": "확장 í´ë”({2})ì— í¬í•¨í•  `contributes.{0}.path`({1})ê°€ 필요합니다. í™•ìž¥ì´ ì´ì‹ 불가능해질 수 있습니다." + "invalid.path.1": "확장 í´ë”({2})ì— í¬í•¨í•  `contributes.{0}.path`({1})ê°€ 필요합니다. í™•ìž¥ì´ ì´ì‹ 불가능해질 수 있습니다.", + "badVariableUse": "\"{0}\"-snippetì€ snippet-variables ë° snippet-placeholders와 혼ë™í•˜ê¸° 쉽습니다. ìžì„¸í•œ ë‚´ìš©ì€\n https://code.visualstudio.com/docs/editor/userdefinedsnippets#_snippet-syntax를 참조하세요." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json b/i18n/kor/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json index 8705a3ff40b..c2a06323202 100644 --- a/i18n/kor/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json @@ -11,6 +11,6 @@ "snippetSchema.json.default": "빈 코드 ì¡°ê°", "snippetSchema.json": "ì‚¬ìš©ìž ì½”ë“œ ì¡°ê° êµ¬ì„±", "snippetSchema.json.prefix": "IntelliSenseì—ì„œ 코드 ì¡°ê°ì„ ì„ íƒí•  ë•Œ 사용할 ì ‘ë‘사입니다.", - "snippetSchema.json.body": "코드 ì¡°ê° ì½˜í…츠입니다. '${id}', '${id:label}', '${1:label}'ì„ ë³€ìˆ˜ì— ì‚¬ìš©í•˜ê³  '$0', '$1'ì„ ì»¤ì„œ ìœ„ì¹˜ì— ì‚¬ìš©í•˜ì„¸ìš”.", + "snippetSchema.json.body": "코드 ì¡°ê° ì½˜í…츠입니다. '$1', '${1:defaultText}'를 사용하여 커서 위치를 ì •ì˜í•˜ê³ , '$0'ì„ ìµœì¢… 커서 ìœ„ì¹˜ì— ì‚¬ìš©í•˜ì„¸ìš”. '${varName}' ë° '${varName:defaultText}'ì— ë³€ìˆ˜ ê°’ì„ ì‚½ìž…í•˜ì„¸ìš”(예: '$TM_FILENAME 파ì¼ìž…니다').", "snippetSchema.json.description": "코드 ì¡°ê° ì„¤ëª…ìž…ë‹ˆë‹¤." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json b/i18n/kor/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json new file mode 100644 index 00000000000..4685b4310b0 --- /dev/null +++ b/i18n/kor/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "helpUs": "{0}ì— ëŒ€í•œ 지ì›ì„ 개선하는 ë° ë„ì›€ì„ ì£¼ì„¸ìš”.", + "takeShortSurvey": "간단한 설문 조사 참여", + "remindLater": "ë‚˜ì¤‘ì— ì•Œë¦¼", + "neverAgain": "다시 표시 안 함" +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json b/i18n/kor/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json new file mode 100644 index 00000000000..9cc54c77a3c --- /dev/null +++ b/i18n/kor/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "surveyQuestion": "간단한 피드백 설문 ì¡°ì‚¬ì— ì°¸ì—¬í•˜ì‹œê² ì–´ìš”?", + "takeSurvey": "설문 조사 참여", + "remindLater": "ë‚˜ì¤‘ì— ì•Œë¦¼", + "neverAgain": "다시 표시 안 함" +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json b/i18n/kor/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json new file mode 100644 index 00000000000..1f6208b0c91 --- /dev/null +++ b/i18n/kor/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noTasksMatching": "ì¼ì¹˜í•˜ëŠ” ìž‘ì—… ì—†ìŒ" +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/kor/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index 2d6bac5e8cb..2847a251263 100644 --- a/i18n/kor/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0}, ìž‘ì—…" + "entryAriaLabel": "{0}, ìž‘ì—…", + "customizeTask": "ìž‘ì—… ì‚¬ìš©ìž ì§€ì •" } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json b/i18n/kor/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json new file mode 100644 index 00000000000..1f6208b0c91 --- /dev/null +++ b/i18n/kor/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noTasksMatching": "ì¼ì¹˜í•˜ëŠ” ìž‘ì—… ì—†ìŒ" +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/kor/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json index e34db9894ef..aa72080ed62 100644 --- a/i18n/kor/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -12,5 +12,6 @@ "ConfigurationParser.invalidVaraibleReference": "오류: ìž˜ëª»ëœ problemMatcher 참조: {0}\n", "ConfigurationParser.noTaskName": "오류: ìž‘ì—…ì—ì„œ taskName ì†ì„±ì„ 제공해야 합니다. ì´ ìž‘ì—…ì€ ë¬´ì‹œë©ë‹ˆë‹¤.\n{0}\n", "taskConfiguration.shellArgs": "경고: ìž‘ì—… '{0}'ì€(는) ì…¸ 명령ì´ë©°, 명령 ì´ë¦„ì´ë‚˜ ì¸ìˆ˜ 중 í•˜ë‚˜ì— ì´ìŠ¤ì¼€ì´í”„ë˜ì§€ ì•Šì€ ê³µë°±ì´ ìžˆìŠµë‹ˆë‹¤. 명령줄 ì¸ìš©ì„ 올바르게 하려면 ì¸ìˆ˜ë¥¼ 명령으로 병합하세요.", + "taskConfiguration.noCommandOrDependsOn": "오류: ìž‘ì—… '{0}'ì—ì„œ 명령ì´ë‚˜ dependsOn ì†ì„±ì„ 지정하지 않습니다. ì´ ìž‘ì—…ì€ ë¬´ì‹œë©ë‹ˆë‹¤. 해당 ìž‘ì—…ì˜ ì •ì˜ëŠ” {1}입니다.", "taskConfiguration.noCommand": "오류: ìž‘ì—… '{0}'ì—ì„œ ëª…ë ¹ì„ ì •ì˜í•˜ì§€ 않습니다. ì´ ìž‘ì—…ì€ ë¬´ì‹œë©ë‹ˆë‹¤. 해당 ìž‘ì—…ì˜ ì •ì˜ëŠ”\n{1}입니다." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json b/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json index c0f40665880..f07448af112 100644 --- a/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json @@ -7,6 +7,7 @@ "JsonSchema.options": "추가 명령 옵션", "JsonSchema.options.cwd": "ì‹¤í–‰ëœ í”„ë¡œê·¸ëž¨ ë˜ëŠ” 스í¬ë¦½íŠ¸ì˜ 현재 ìž‘ì—… 디렉터리입니다. ìƒëžµëœ 경우 Codeì˜ í˜„ìž¬ ìž‘ì—… ì˜ì—­ 루트가 사용ë©ë‹ˆë‹¤.", "JsonSchema.options.env": "실행할 프로그램 ë˜ëŠ” ì…¸ì˜ í™˜ê²½ìž…ë‹ˆë‹¤. ìƒëžµí•˜ë©´ 부모 í”„ë¡œì„¸ìŠ¤ì˜ í™˜ê²½ì´ ì‚¬ìš©ë©ë‹ˆë‹¤.", + "JsonSchema.shellConfiguration": "사용할 ì…¸ì„ êµ¬ì„±í•©ë‹ˆë‹¤.", "JsonSchema.shell.executable": "사용할 셸입니다.", "JsonSchema.shell.args": "ì…¸ ì¸ìˆ˜ìž…니다.", "JsonSchema.command": "실행할 명령ì´ë©°, 외부 프로그램 ë˜ëŠ” ì…¸ 명령입니다.", diff --git a/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json b/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json index 18e49dd95a0..06d667c9b13 100644 --- a/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json @@ -5,6 +5,8 @@ // Do not edit this file. It is machine generated. { "JsonSchema.version": "êµ¬ì„±ì˜ ë²„ì „ 번호입니다.", + "JsonSchema._runner": "러너가 ë” ì´ìƒ 사용ë˜ì§€ 않습니다. ê³µì‹ ëŸ¬ë„ˆ ì†ì„±ì„ 사용하세요.", + "JsonSchema.runner": "ìž‘ì—…ì´ í”„ë¡œì„¸ìŠ¤ë¡œ 실행ë˜ëŠ”지 여부와 ì¶œë ¥ì´ ì¶œë ¥ ì°½ì´ë‚˜ í„°ë¯¸ë„ ë‚´ë¶€ 중 ì–´ë””ì— í‘œì‹œë˜ëŠ”지를 ì •ì˜í•©ë‹ˆë‹¤.", "JsonSchema.windows": "Windows 특정 명령 구성", "JsonSchema.mac": "Mac 특정 명령 구성", "JsonSchema.linux": "Linux 특정 명령 구성", diff --git a/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json index 13d620361aa..00c94add47c 100644 --- a/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -7,6 +7,10 @@ "JsonSchema.shell": "ëª…ë ¹ì´ ì…¸ 명령ì¸ì§€ 외부 프로그램ì¸ì§€ 여부를 지정합니다. ìƒëžµí•˜ë©´ 기본값 falseê°€ 사용ë©ë‹ˆë‹¤.", "JsonSchema.tasks.dependsOn.string": "ì´ ìž‘ì—…ì´ ì¢…ì†ëœ ë˜ ë‹¤ë¥¸ 작업입니다.", "JsonSchema.tasks.dependsOn.array": "ì´ ìž‘ì—…ì´ ì¢…ì†ëœ 다른 여러 작업입니다.", + "JsonSchema.tasks.group": "ì´ ìž‘ì—…ì´ ì†í•œ 실행 ê·¸ë£¹ì„ ì •ì˜í•©ë‹ˆë‹¤. ìƒëžµí•˜ë©´ ìž‘ì—…ì€\n 아무 그룹ì—ë„ ì†í•˜ì§€ 않습니다.", + "JsonSchema.tasks.type": "ìž‘ì—…ì´ í”„ë¡œì„¸ìŠ¤ë¡œ 실행ë˜ëŠ”지 ë˜ëŠ” ì…¸ ë‚´ì˜ ëª…ë ¹ìœ¼ë¡œ 실행ë˜ëŠ”지를 제어합니다. ê¸°ë³¸ê°’ì€ í”„ë¡œì„¸ìŠ¤ìž…ë‹ˆë‹¤.", + "JsonSchema.version": "êµ¬ì„±ì˜ ë²„ì „ 번호입니다.", + "JsonSchema.tasks.customize": "ì‚¬ìš©ìž ì§€ì •í•  ì ìš©ëœ 작업입니다.", "JsonSchema.windows": "Windows 특정 명령 구성", "JsonSchema.mac": "Mac 특정 명령 구성", "JsonSchema.linux": "Linux 특정 명령 구성" diff --git a/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json b/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json index 4e1c891e83f..0e231caf66c 100644 --- a/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json @@ -18,10 +18,12 @@ "problems": "문제", "manyMarkers": "99+", "tasks": "ìž‘ì—…", + "TaskSystem.noHotSwap": "ìž‘ì—… 실행 ì—”ì§„ì„ ë³€ê²½í•˜ë ¤ë©´ VS Code를 다시 시작해야 합니다. ë³€ê²½ì´ ë¬´ì‹œë©ë‹ˆë‹¤.", "TaskService.noBuildTask": "ì •ì˜ëœ 빌드 ìž‘ì—…ì´ ì—†ìŠµë‹ˆë‹¤. tasks.json 파ì¼ì—ì„œ ìž‘ì—…ì„ 'isBuildCommand'ë¡œ 표시하세요.", "TaskService.noTestTask": "ì •ì˜ëœ 테스트 ìž‘ì—…ì´ ì—†ìŠµë‹ˆë‹¤. tasks.json 파ì¼ì—ì„œ ìž‘ì—…ì„ 'isTestCommand'ë¡œ 표시하세요.", "TaskServer.noTask": "실행하ë„ë¡ ìš”ì²­í•œ ìž‘ì—… {0}ì„(를) ì°¾ì„ ìˆ˜ 없습니다.", - "TaskSystem.activeSame": "ìž‘ì—…ì´ ì´ë¯¸ 활성 ìƒíƒœì´ë©° ê°ì‹œ 모드입니다. ìž‘ì—…ì„ ì¢…ë£Œí•˜ë ¤ë©´ `F1 > ìž‘ì—… 종료`를 사용하세요.", + "customizeParseErrors": "현재 작성 êµ¬ì„±ì— ì˜¤ë¥˜ê°€ 있습니다. ìž‘ì—…ì„ ì‚¬ìš©ìž ì§€ì •í•˜ê¸° ì „ì— ì˜¤ë¥˜ë¥¼ 수정하세요.\n", + "moreThanOneBuildTask": "tasks.jsonì— ì—¬ëŸ¬ 빌드 ìž‘ì—…ì´ ì •ì˜ë˜ì–´ 있습니다. 첫 번째 ìž‘ì—…ì„ ì‹¤í–‰í•©ë‹ˆë‹¤.\n", "TaskSystem.active": "ì´ë¯¸ 실행 ì¤‘ì¸ ìž‘ì—…ì´ ìžˆìŠµë‹ˆë‹¤. 다른 ìž‘ì—…ì„ ì‹¤í–‰í•˜ë ¤ë©´ 먼저 ì´ ìž‘ì—…ì„ ì¢…ë£Œí•˜ì„¸ìš”.", "TaskSystem.restartFailed": "{0} ìž‘ì—…ì„ ì¢…ë£Œí•˜ê³  다시 시작하지 못했습니다.", "TaskSystem.configurationErrors": "오류: 제공한 ìž‘ì—… êµ¬ì„±ì— ìœ íš¨ì„± 검사 오류가 있으며 사용할 수 없습니다. 먼저 오류를 수정하세요.", diff --git a/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json b/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json index 960fcef74d0..4c053b9817c 100644 --- a/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json @@ -6,5 +6,7 @@ { "TerminalTaskSystem.unknownError": "ìž‘ì—…ì„ ì‹¤í–‰í•˜ëŠ” ë™ì•ˆ ì•Œ 수 없는 오류가 ë°œìƒí–ˆìŠµë‹ˆë‹¤. ìžì„¸í•œ ë‚´ìš©ì€ ìž‘ì—… 출력 로그를 참조하세요.", "TerminalTaskSystem.terminalName": "ìž‘ì—… - {0}", - "TerminalTaskSystem": "UNC ë“œë¼ì´ë¸Œì—ì„œ ì…¸ ëª…ë ¹ì„ ì‹¤í–‰í•  수 없습니다." + "reuseTerminal": "터미ë„ì´ ìž‘ì—…ì—ì„œ 다시 사용ë©ë‹ˆë‹¤. 닫으려면 아무 키나 누르세요.", + "TerminalTaskSystem": "UNC ë“œë¼ì´ë¸Œì—ì„œ ì…¸ ëª…ë ¹ì„ ì‹¤í–‰í•  수 없습니다.", + "unkownProblemMatcher": "문제 ì„ íƒê¸° {0}ì„(를) 확ì¸í•  수 없습니다. ì´ ì„ íƒê¸°ëŠ” 무시ë©ë‹ˆë‹¤." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json b/i18n/kor/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json index 41639c4c051..e222c1b151d 100644 --- a/i18n/kor/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json @@ -7,5 +7,6 @@ "TaskRunnerSystem.unknownError": "ìž‘ì—…ì„ ì‹¤í–‰í•˜ëŠ” ë™ì•ˆ ì•Œ 수 없는 오류가 ë°œìƒí–ˆìŠµë‹ˆë‹¤. ìžì„¸í•œ ë‚´ìš©ì€ ìž‘ì—… 출력 로그를 참조하세요.", "TaskRunnerSystem.watchingBuildTaskFinished": "\n빌드 ê°ì‹œ ìž‘ì—…ì´ ì™„ë£Œë˜ì—ˆìŠµë‹ˆë‹¤.", "TaskRunnerSystem.childProcessError": "Failed to launch external program {0} {1}.", - "TaskRunnerSystem.cancelRequested": "\nì‚¬ìš©ìž ìš”ì²­ì— ë”°ë¼ '{0}' ìž‘ì—…ì´ ì¢…ë£Œë˜ì—ˆìŠµë‹ˆë‹¤." + "TaskRunnerSystem.cancelRequested": "\nì‚¬ìš©ìž ìš”ì²­ì— ë”°ë¼ '{0}' ìž‘ì—…ì´ ì¢…ë£Œë˜ì—ˆìŠµë‹ˆë‹¤.", + "unkownProblemMatcher": "문제 ì„ íƒê¸° {0}ì„(를) 확ì¸í•  수 없습니다. ì´ ì„ íƒê¸°ëŠ” 무시ë©ë‹ˆë‹¤." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json b/i18n/kor/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json index 2953f126a31..8d5763a792b 100644 --- a/i18n/kor/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json @@ -8,6 +8,7 @@ "workbench.action.terminal.kill": "활성 í„°ë¯¸ë„ ì¸ìŠ¤í„´ìŠ¤ 종료", "workbench.action.terminal.kill.short": "í„°ë¯¸ë„ ì¢…ë£Œ", "workbench.action.terminal.copySelection": "ì„ íƒ ì˜ì—­ 복사", + "workbench.action.terminal.selectAll": "ëª¨ë‘ ì„ íƒ", "workbench.action.terminal.new": "새 통합 í„°ë¯¸ë„ ë§Œë“¤ê¸°", "workbench.action.terminal.new.short": "새 터미ë„", "workbench.action.terminal.focus": "터미ë„ì— í¬ì»¤ìŠ¤", @@ -26,5 +27,8 @@ "workbench.action.terminal.scrollUp": "위로 스í¬ë¡¤(줄)", "workbench.action.terminal.scrollUpPage": "위로 스í¬ë¡¤(페ì´ì§€)", "workbench.action.terminal.scrollToTop": "맨 위로 스í¬ë¡¤", - "workbench.action.terminal.clear": "지우기" + "workbench.action.terminal.clear": "지우기", + "workbench.action.terminal.allowWorkspaceShell": "ìž‘ì—… ì˜ì—­ ì…¸ 구성 허용", + "workbench.action.terminal.disallowWorkspaceShell": "ìž‘ì—… ì˜ì—­ ì…¸ 구성 허용 안 함", + "workbench.action.terminal.rename": "ì´ë¦„ 바꾸기" } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json b/i18n/kor/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json index 0b29da8897d..5923a5bf7d5 100644 --- a/i18n/kor/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json @@ -4,5 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "terminal.background": "터미ë„ì˜ ë°°ê²½ìƒ‰ìž…ë‹ˆë‹¤. ì´ ì„¤ì •ì„ ì‚¬ìš©í•˜ë©´ 터미ë„\n ìƒ‰ì„ íŒ¨ë„ê³¼ 다르게 지정할 수 있습니다.", + "terminal.foreground": "터미ë„ì˜ ì „ê²½ìƒ‰ìž…ë‹ˆë‹¤.", "terminal.ansiColor": "터미ë„ì˜ '{0}' ANSI 색입니다." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json b/i18n/kor/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json new file mode 100644 index 00000000000..c45550055e9 --- /dev/null +++ b/i18n/kor/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "label.find": "찾기", + "placeholder.find": "찾기", + "label.previousMatchButton": "ì´ì „ 검색 ê²°ê³¼", + "label.nextMatchButton": "ë‹¤ìŒ ê²€ìƒ‰ ê²°ê³¼", + "label.closeButton": "닫기" +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json b/i18n/kor/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json index a35b2cdc8f1..7ae3f4f9275 100644 --- a/i18n/kor/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json @@ -4,7 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "terminal.integrated.copySelection.noSelection": "터미ë„ì— í¬ì»¤ìŠ¤ê°€ 없는 경우 í„°ë¯¸ë„ ì„ íƒì„ 복사할 수 없습니다.", "terminal.integrated.exitedWithCode": "í„°ë¯¸ë„ í”„ë¡œì„¸ìŠ¤ê°€ 종료 코드 {0}(으)ë¡œ 종료ë˜ì—ˆìŠµë‹ˆë‹¤.", "terminal.integrated.waitOnExit": "터미ë„ì„ ë‹«ìœ¼ë ¤ë©´ 아무 키나 누르세요.", "terminal.integrated.launchFailed": "í„°ë¯¸ë„ í”„ë¡œì„¸ìŠ¤ 명령 `{0}{1}`ì´(ê°€) 시작하지 못했습니다(종료 코드: {2})." diff --git a/i18n/kor/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json b/i18n/kor/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json index 25cf1e96203..b3a4598456f 100644 --- a/i18n/kor/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json @@ -6,6 +6,7 @@ { "selectTheme.label": "색 테마", "installColorThemes": "추가 색 테마 설치...", + "themes.selectTheme": "색 테마 ì„ íƒ(미리 보려면 위로/아래로 키 사용)", "selectIconTheme.label": "íŒŒì¼ ì•„ì´ì½˜ 테마", "installIconThemes": "추가 íŒŒì¼ ì•„ì´ì½˜ 테마 설치...", "noIconThemeLabel": "ì—†ìŒ", diff --git a/i18n/kor/src/vs/workbench/parts/update/electron-browser/update.i18n.json b/i18n/kor/src/vs/workbench/parts/update/electron-browser/update.i18n.json index 07b9da83abe..dbdb545ea20 100644 --- a/i18n/kor/src/vs/workbench/parts/update/electron-browser/update.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/update/electron-browser/update.i18n.json @@ -15,5 +15,18 @@ "license": "ë¼ì´ì„ ìŠ¤ ì½ê¸°", "updateAvailable": "다시 시작하면 {0}ì´(ê°€) ì—…ë°ì´íŠ¸ë©ë‹ˆë‹¤.", "thereIsUpdateAvailable": "사용 가능한 ì—…ë°ì´íŠ¸ê°€ 있습니다.", - "noUpdatesAvailable": "현재 사용 가능한 ì—…ë°ì´íŠ¸ê°€ 없습니다." + "noUpdatesAvailable": "현재 사용 가능한 ì—…ë°ì´íŠ¸ê°€ 없습니다.", + "updateIsReady": "새 ì—…ë°ì´íŠ¸ë¥¼ 사용할 수 있습니다.", + "commandPalette": "명령 팔레트...", + "settings": "설정", + "keyboardShortcuts": "바로 가기 키(&&K)", + "selectTheme.label": "색 테마", + "themes.selectIconTheme.label": "íŒŒì¼ ì•„ì´ì½˜ 테마", + "not available": "ì—…ë°ì´íŠ¸ë¥¼ 사용할 수 ì—†ìŒ", + "checkingForUpdates": "ì—…ë°ì´íŠ¸ë¥¼ 확ì¸í•˜ëŠ” 중...", + "DownloadUpdate": "사용 가능한 ì—…ë°ì´íŠ¸ 다운로드", + "DownloadingUpdate": "ì—…ë°ì´íŠ¸ë¥¼ 다운로드하는 중...", + "InstallingUpdate": "ì—…ë°ì´íŠ¸ë¥¼ 설치하는 중...", + "restartToUpdate": "ì—…ë°ì´íŠ¸í•˜ê¸° 위해 다시 시작...", + "checkForUpdates": "ì—…ë°ì´íŠ¸ 확ì¸..." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/views/browser/views.i18n.json b/i18n/kor/src/vs/workbench/parts/views/browser/views.i18n.json new file mode 100644 index 00000000000..8d20ba83c9a --- /dev/null +++ b/i18n/kor/src/vs/workbench/parts/views/browser/views.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "viewToolbarAriaLabel": "{0} ë™ìž‘" +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json b/i18n/kor/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json new file mode 100644 index 00000000000..cb664992fc1 --- /dev/null +++ b/i18n/kor/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "requirearray": "뷰는 ë°°ì—´ì´ì–´ì•¼ 합니다.", + "requirestring": "ì†ì„± `{0}`ì€(는) 필수ì´ë©° `string` 형ì‹ì´ì–´ì•¼ 합니다.", + "optstring": "ì†ì„± `{0}`ì€(는) ìƒëžµí•  수 있으며 `string` 형ì‹ì´ì–´ì•¼ 합니다.", + "vscode.extension.contributes.view.id": "ë·°ì˜ ì‹ë³„ìžìž…니다. 'vscode.window.registerTreeDataProviderForView` API를 통해 ë°ì´í„° 공급ìžë¥¼ 등ë¡í•˜ëŠ” ë° ì‚¬ìš©í•©ë‹ˆë‹¤. `onView:${id}` ì´ë²¤íŠ¸ë¥¼ `activationEvents`ì— ë“±ë¡í•˜ì—¬ 확장 활성화를 트리거하는 ë°ì—ë„ ì‚¬ìš©í•©ë‹ˆë‹¤.", + "vscode.extension.contributes.view.name": "사용ìžê°€ ì½ì„ 수 있는 ë·° ì´ë¦„입니다. 표시ë©ë‹ˆë‹¤.", + "vscode.extension.contributes.views": "뷰를 ì—ë””í„°ì— ì ìš©í•©ë‹ˆë‹¤.", + "views.explorer": "íƒìƒ‰ê¸° ë·°", + "locationId.invalid": "`{0}`ì€(는) 유효한 ë·° 위치가 아닙니다." +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/kor/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json index 3b4766bb5d9..abd099ba950 100644 --- a/i18n/kor/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -11,20 +11,26 @@ "welcomePage.openFolder": "í´ë” 열기...", "welcomePage.cloneGitRepository": "Git 리í¬ì§€í† ë¦¬ 복제...", "welcomePage.recent": "최근 항목", + "welcomePage.moreRecent": "ìžì„¸ížˆ...", "welcomePage.noRecentFolders": "최근 í´ë” ì—†ìŒ", "welcomePage.help": "ë„움ë§", + "welcomePage.keybindingsCheatsheet": "ì¸ì‡„ 가능 키보드 치트시트", "welcomePage.introductoryVideos": "소개 비디오", "welcomePage.productDocumentation": "제품 설명서", "welcomePage.gitHubRepository": "GitHub 리í¬ì§€í† ë¦¬", "welcomePage.stackOverflow": "Stack Overflow", "welcomePage.showOnStartup": "시작 ì‹œ 시작 페ì´ì§€ 표시", "welcomePage.customize": "ì‚¬ìš©ìž ì§€ì •", + "welcomePage.installExtensionPacks": "ë„구 ë° ì–¸ì–´", + "welcomePage.installExtensionPacksDescription": "{0} ë° {1}ì— ëŒ€í•œ ì§€ì› ì„¤ì¹˜", + "welcomePage.moreExtensions": "ìžì„¸ížˆ", "welcomePage.installKeymapDescription": "바로 가기 키 설치", + "welcomePage.installKeymapExtension": "{0} ë° {1}ì˜ ë°”ë¡œ 가기 키 설치", "welcomePage.others": "기타", "welcomePage.colorTheme": "색 테마", "welcomePage.colorThemeDescription": "편집기 ë° ì½”ë“œê°€ 좋아하는 ë°©ì‹ìœ¼ë¡œ 표시ë˜ê²Œ 만들기", + "welcomePage.learn": "알아보기", "welcomePage.showCommands": "모든 명령 찾기 ë° ì‹¤í–‰", - "welcomePage.showCommandsDescription": "제어íŒì—ì„œ ëª…ë ¹ì„ ë¹ ë¥´ê²Œ 검색 ë° ì•¡ì„¸ìŠ¤({0})", "welcomePage.interfaceOverview": "ì¸í„°íŽ˜ì´ìŠ¤ 개요", "welcomePage.interfaceOverviewDescription": "UIì˜ ì£¼ìš” 구성 요소를 ê°•ì¡° 표시하는 ì‹œê°ì  ì˜¤ë²„ë ˆì´ ê°€ì ¸ì˜¤ê¸°", "welcomePage.interactivePlayground": "대화형 실습", diff --git a/i18n/kor/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json b/i18n/kor/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json index 5f662c88c2e..d09100eafce 100644 --- a/i18n/kor/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json @@ -4,7 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "workbenchConfigurationTitle": "워í¬ë²¤ì¹˜", - "welcomePage.enabled": "사용하ë„ë¡ ì„¤ì •ë˜ë©´ 시작할 ë•Œ 시작 페ì´ì§€ë¥¼ 표시합니다.", "help": "ë„움ë§" } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/kor/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index a436e5a707b..32604316d81 100644 --- a/i18n/kor/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -4,17 +4,35 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "workbenchConfigurationTitle": "워í¬ë²¤ì¹˜", + "welcomePage.enabled": "사용하ë„ë¡ ì„¤ì •ë˜ë©´ 시작할 ë•Œ 시작 페ì´ì§€ë¥¼ 표시합니다.", "welcomePage": "시작", + "welcomePage.javaScript": "JavaScript", "welcomePage.typeScript": "TypeScript", + "welcomePage.python": "Python", "welcomePage.php": "PHP", + "welcomePage.docker": "Docker", "welcomePage.vim": "Vim", "welcomePage.sublime": "Sublime", "welcomePage.atom": "Atom", + "welcomePage.extensionPackAlreadyInstalled": "{0}ì— ëŒ€í•œ 지ì›ì´ ì´ë¯¸ 설치ë˜ì–´ 있습니다.", + "welcomePage.willReloadAfterInstallingExtensionPack": "{0}ì— ëŒ€í•œ 추가 지ì›ì„ 설치한 후 ì°½ì´ ë‹¤ì‹œ 로드ë©ë‹ˆë‹¤.", + "welcomePage.installingExtensionPack": "{0}ì— ëŒ€í•œ 추가 지ì›ì„ 설치하는 중...", + "welcomePage.extensionPackNotFound": "IDê°€ {1}ì¸ {0}ì— ëŒ€í•œ 지ì›ì„ ì°¾ì„ ìˆ˜ 없습니다.", "welcomePage.keymapAlreadyInstalled": "{0} 바로 가기 키가 ì´ë¯¸ 설치ë˜ì–´ 있습니다.", "welcomePage.willReloadAfterInstallingKeymap": "{0} 바로 가기 키를 설치한 후 ì°½ì´ ë‹¤ì‹œ 로드ë©ë‹ˆë‹¤.", "welcomePage.installingKeymap": "{0} 바로 가기 키를 설치하는 중...", "welcomePage.keymapNotFound": "IDê°€ {1}ì¸ {0} 바로 가기 키를 ì°¾ì„ ìˆ˜ 없습니다.", "welcome.title": "시작", + "welcomePage.openFolderWithPath": "경로가 {1}ì¸ {0} í´ë” 열기", + "welcomePage.extensionListSeparator": ", ", + "welcomePage.installKeymap": "{0} 키맵 설치", + "welcomePage.installExtensionPack": "{0}ì— ëŒ€í•œ 추가 ì§€ì› ì„¤ì¹˜", + "welcomePage.installedKeymap": "{0} í‚¤ë§µì´ ì´ë¯¸ 설치ë˜ì–´ 있습니다.", + "welcomePage.installedExtensionPack": "{0} 지ì›ì´ ì´ë¯¸ 설치ë˜ì–´ 있습니다.", "ok": "확ì¸", - "cancel": "취소" + "details": "세부 ì •ë³´", + "cancel": "취소", + "welcomePage.buttonBackground": "시작 페ì´ì§€ì—ì„œ ë‹¨ì¶”ì˜ ë°°ê²½ìƒ‰ìž…ë‹ˆë‹¤.", + "welcomePage.buttonHoverBackground": "시작 페ì´ì§€ì—ì„œ ë‹¨ì¶”ì˜ ì»¤ì„œ 올리기 배경색입니다." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json b/i18n/kor/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json index 7f6ec89a740..25c6b86854d 100644 --- a/i18n/kor/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json +++ b/i18n/kor/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json @@ -5,5 +5,6 @@ // Do not edit this file. It is machine generated. { "walkThrough.unboundCommand": "ë°”ì¸ë”© 안 ë¨", - "walkThrough.gitNotFound": "Gitê°€ ì‹œìŠ¤í…œì— ì„¤ì¹˜ë˜ì§€ ì•Šì€ ê²ƒ 같습니다." + "walkThrough.gitNotFound": "Gitê°€ ì‹œìŠ¤í…œì— ì„¤ì¹˜ë˜ì§€ ì•Šì€ ê²ƒ 같습니다.", + "walkThrough.embeddedEditorBackground": "대화형 실습ì—ì„œ í¬í•¨ëœ íŽ¸ì§‘ê¸°ì˜ ë°°ê²½ìƒ‰ìž…ë‹ˆë‹¤." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json b/i18n/kor/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json index 131b473a69b..fa07b04f779 100644 --- a/i18n/kor/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json +++ b/i18n/kor/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json @@ -6,6 +6,12 @@ { "open": "설정 열기", "close": "닫기", + "saveAndRetry": "설정 저장 ë° ë‹¤ì‹œ ì‹œë„", "errorUnknownKey": "구성 파ì¼ì— 쓸 수 없습니다(ì•Œ 수 없는 키).", - "errorInvalidTarget": "구성 파ì¼ì— 쓸 수 없습니다(ìž˜ëª»ëœ ëŒ€ìƒ)." + "errorInvalidTarget": "구성 파ì¼ì— 쓸 수 없습니다(ìž˜ëª»ëœ ëŒ€ìƒ).", + "errorNoWorkspaceOpened": "í´ë”ê°€ ì—´ë ¤ 있지 않으므로 ì„¤ì •ì— ì“¸ 수 없습니다. 먼저 í´ë”를 ì—´ê³  다시 ì‹œë„하세요.", + "errorInvalidConfiguration": "ì„¤ì •ì— ì“¸ 수 없습니다. **ì‚¬ìš©ìž ì„¤ì •**ì„ ì—´ì–´ 파ì¼ì—ì„œ 오류/경고를 해결하고 다시 ì‹œë„하세요.", + "errorInvalidConfigurationWorkspace": "ì„¤ì •ì— ì“¸ 수 없습니다. **ìž‘ì—… ì˜ì—­ 설정**ì„ ì—´ì–´ 파ì¼ì—ì„œ 오류/경고를 해결하고 다시 ì‹œë„하세요.", + "errorConfigurationFileDirty": "파ì¼ì´ 변경ë˜ì–´ ì„¤ì •ì— ì“¸ 수 없습니다. **ì‚¬ìš©ìž ì„¤ì •** 파ì¼ì„ 저장하고 다시 ì‹œë„하세요.", + "errorConfigurationFileDirtyWorkspace": "파ì¼ì´ 변경ë˜ì–´ ì„¤ì •ì— ì“¸ 수 없습니다. **ìž‘ì—… ì˜ì—­ 설정** 파ì¼ì„ 저장하고 다시 ì‹œë„하세요." } \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json b/i18n/kor/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json new file mode 100644 index 00000000000..cff423b1f3b --- /dev/null +++ b/i18n/kor/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "telemetryConfigurationTitle": "ì›ê²© 분ì„", + "telemetry.enableCrashReporting": "ì¶©ëŒ ë³´ê³ ì„œë¥¼ Microsoftì— ì „ì†¡í•  수 있ë„ë¡ ì„¤ì •í•©ë‹ˆë‹¤.\nì´ ì˜µì…˜ì„ ì ìš©í•˜ë ¤ë©´ 다시 시작해야 합니다." +} \ No newline at end of file diff --git a/i18n/kor/src/vs/workbench/services/progress/browser/progressService2.i18n.json b/i18n/kor/src/vs/workbench/services/progress/browser/progressService2.i18n.json new file mode 100644 index 00000000000..6db7d6aae51 --- /dev/null +++ b/i18n/kor/src/vs/workbench/services/progress/browser/progressService2.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "progress.text": "{0} - {1}", + "progress.title": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json b/i18n/ptb/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json index 3ffec1c5e87..8f2407b1dfa 100644 --- a/i18n/ptb/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json +++ b/i18n/ptb/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "activeEditorShort": "e.g. meuArquivo.txt", + "activeEditorShort": "por exemplo meuArquivo.txt", "activeEditorMedium": "e.g. minhaPasta/meuArquivo.txt", "activeEditorLong": "por exemplo /Usuários/Desenvolvimento/meuProjeto/minhaPasta/meuArquivo/txt", "rootName": "e.g. meuProjeto", diff --git a/i18n/ptb/extensions/git/out/statusbar.i18n.json b/i18n/ptb/extensions/git/out/statusbar.i18n.json index 0b6ee800ffa..a7cb7d22aae 100644 --- a/i18n/ptb/extensions/git/out/statusbar.i18n.json +++ b/i18n/ptb/extensions/git/out/statusbar.i18n.json @@ -6,6 +6,6 @@ { "checkout": "Checkout...", "sync changes": "Sincronizar alterações", - "publish changes": "Publicar alterações", - "syncing changes": "Sincronizando alterações..." + "publish changes": "Publicar Alterações", + "syncing changes": "Sincronizando Alterações..." } \ No newline at end of file diff --git a/i18n/ptb/extensions/git/package.i18n.json b/i18n/ptb/extensions/git/package.i18n.json index e3eec31c008..20e7fed4901 100644 --- a/i18n/ptb/extensions/git/package.i18n.json +++ b/i18n/ptb/extensions/git/package.i18n.json @@ -32,7 +32,7 @@ "command.push": "Enviar por push", "command.pushTo": "Enviar por push para...", "command.sync": "Sincronizar", - "command.publish": "Publicar", + "command.publish": "Publicar Ramo", "command.showOutput": "Mostrar Saída do Git", "config.enabled": "Se o git estiver habilitado", "config.path": "Caminho para o executável do git", diff --git a/i18n/ptb/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/ptb/extensions/merge-conflict/out/codelensProvider.i18n.json index 8b6ad71cd4e..e3c98669238 100644 --- a/i18n/ptb/extensions/merge-conflict/out/codelensProvider.i18n.json +++ b/i18n/ptb/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -3,4 +3,9 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "acceptCurrentChange": "Aceitar a mudança atual", + "acceptIncomingChange": "Aceitar a mudança de entrada", + "acceptBothChanges": "Aceitar as duas alterações", + "compareChanges": "Comparar as mudanças" +} \ No newline at end of file diff --git a/i18n/ptb/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/ptb/extensions/merge-conflict/out/commandHandler.i18n.json index 231dd1e64b1..6308a5d70f5 100644 --- a/i18n/ptb/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/ptb/extensions/merge-conflict/out/commandHandler.i18n.json @@ -5,6 +5,8 @@ // Do not edit this file. It is machine generated. { "cursorNotInConflict": "Cursor do editor não está dentro de um conflito de mesclagem", + "compareChangesTitle": "{0}: Alterações Atuais ⟷ Alterações de Entrada", + "cursorOnCommonAncestorsRange": "Cursor do editor está dentro do bloco comum de ancestrais, favor mover para o bloco \"atual\" ou \"entrada\"", "cursorOnSplitterRange": "Cursor do editor está dentro do separador de conflitos de mesclagem, por favor mova-o para o bloco \"atual\" ou \"entrada\"", "noConflicts": "Nenhum conflito de mesclagem encontrado neste arquivo", "noOtherConflictsInThisFile": "Não há outros conflitos de mesclagem dentro desse arquivo" diff --git a/i18n/ptb/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/ptb/extensions/merge-conflict/out/mergeDecorator.i18n.json index a3da6d4660e..2b29ae4a254 100644 --- a/i18n/ptb/extensions/merge-conflict/out/mergeDecorator.i18n.json +++ b/i18n/ptb/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -4,6 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "currentChange": "(Mudança atual)", - "incomingChange": "(Mudança de entrada)" + "currentChange": "(Mudança Atual)", + "incomingChange": "(Próxima Mudança)" } \ No newline at end of file diff --git a/i18n/ptb/extensions/merge-conflict/package.i18n.json b/i18n/ptb/extensions/merge-conflict/package.i18n.json index 1ca50299264..ad47caacee9 100644 --- a/i18n/ptb/extensions/merge-conflict/package.i18n.json +++ b/i18n/ptb/extensions/merge-conflict/package.i18n.json @@ -5,7 +5,15 @@ // Do not edit this file. It is machine generated. { "command.category": "Conflito de Mesclagem", + "command.accept.all-incoming": "Aceitar todas entradas", + "command.accept.all-both": "Aceitar todas as duas", + "command.accept.current": "Aceitar a corrente", + "command.accept.incoming": "Aceitar entrada", + "command.accept.selection": "Aceitar a seleção", "command.accept.both": "Aceitar Ambos", + "command.next": "Próximo conflito", + "command.previous": "Conflito anterior", + "command.compare": "Comparar o conflito atual", "config.title": "Mesclar conflitos", "config.codeLensEnabled": "Habilitar/Desabilitar o conflito de mesclagem no bloco CodeLens dentro do editor", "config.decoratorsEnabled": "Habilitar/Desabilitar decoradores de mesclagem de conflitos dentro do editor" diff --git a/i18n/ptb/extensions/typescript/out/features/bufferSyncSupport.i18n.json b/i18n/ptb/extensions/typescript/out/features/bufferSyncSupport.i18n.json index 1cef0c6e94a..3cc3ca76ce7 100644 --- a/i18n/ptb/extensions/typescript/out/features/bufferSyncSupport.i18n.json +++ b/i18n/ptb/extensions/typescript/out/features/bufferSyncSupport.i18n.json @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "versionMismatch": "Incompatibilidade de versão! global tsc ({0})! = serviço de linguagem do VS Code ({1}). Erros de compilação inconsistentes podem ocorrer", + "versionMismatch": "Usando o TypeScript ({1}) para recursos do editor. TypeScript ({0}) está instalado globalmente em sua máquina. Erros no VS Code podem diferir dos erros TSC", "moreInformation": "Mais informações", "doNotCheckAgain": "Não verificar novamente", "close": "Fechar", diff --git a/i18n/ptb/extensions/typescript/out/utils/projectStatus.i18n.json b/i18n/ptb/extensions/typescript/out/utils/projectStatus.i18n.json index 5cb18373637..6f06552e929 100644 --- a/i18n/ptb/extensions/typescript/out/utils/projectStatus.i18n.json +++ b/i18n/ptb/extensions/typescript/out/utils/projectStatus.i18n.json @@ -6,7 +6,6 @@ { "hintExclude": "Para habilitar os recursos de linguagem JavaScript/TypeScipt em todo o projeto, excluir pastas com muitos arquivos, como: {0}", "hintExclude.generic": "Para habilitar os recursos de linguagem JavaScript/TypeScipt em todo o projeto, excluir pastas grandes com arquivos em que você não trabalha.", - "open": "Configurar exclusões", "large.label": "Configurar exclusões", "hintExclude.tooltip": "Para habilitar os recursos de linguagem JavaScript/TypeScipt em todo o projeto, excluir pastas grandes com arquivos em que você não trabalha." } \ No newline at end of file diff --git a/i18n/ptb/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/ptb/extensions/typescript/out/utils/typingsStatus.i18n.json index 4ba4da55a07..e6e29d6431a 100644 --- a/i18n/ptb/extensions/typescript/out/utils/typingsStatus.i18n.json +++ b/i18n/ptb/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "installingPackages": "Buscando dados para melhor IntelliSense do TypeScript", + "typesInstallerInitializationFailed.title": "Não foi possível instalar arquivos de tipagens para recursos da linguagem JavaScript. Por favor, certifique-se de que a NPM está instalado ou configure 'typescript.npm' em suas configurações de usuário", "typesInstallerInitializationFailed.moreInformation": "Mais informações", "typesInstallerInitializationFailed.doNotCheckAgain": "Não verificar novamente", "typesInstallerInitializationFailed.close": "Fechar" diff --git a/i18n/ptb/extensions/typescript/package.i18n.json b/i18n/ptb/extensions/typescript/package.i18n.json index e46048cba4a..88b67be9000 100644 --- a/i18n/ptb/extensions/typescript/package.i18n.json +++ b/i18n/ptb/extensions/typescript/package.i18n.json @@ -13,11 +13,11 @@ "typescript.check.tscVersion": "Verifica se um ima instalação global do compilador TypeScript (por exemplo, tsc) difere do serviço de linguagem TypeScript usado.", "typescript.tsserver.log": "Habilita o log do servidor TS para um arquivo. Este log pode ser usado para diagnosticar problemas do servidor de TS. O log pode conter caminhos de arquivo, código-fonte e outras informações potencialmente confidenciais do seu projeto.", "typescript.tsserver.trace": "Habilita o rastreamento de mensagens enviadas para o servidor de TS. Este rastreamento pode ser usado para diagnosticar problemas do servidor de TS. O rastreamento pode conter caminhos de arquivo, código-fonte e outras informações potencialmente confidenciais do seu projeto.", - "typescript.tsserver.experimentalAutoBuild": "Habilita auto build experimental. Requer a versão 1.9 dev ou 2.x do tsserver e o reinício do VS Code depois da alteração.", "typescript.validate.enable": "Habilita/Desabilita a validação TypeScript.", "typescript.format.enable": "Habilita/Desabilita o formatador padrão TypeScript.", "javascript.format.enable": "Habilita/Desabilita o formatador padrão JavaScript.", "format.insertSpaceAfterCommaDelimiter": "Define o tratamento de espaços após um delimitador vírgula.", + "format.insertSpaceAfterConstructor": "Define a manipulação de espaços após a palavra-chave do construtor. Requer TypeScript > = 2.3.0.", "format.insertSpaceAfterSemicolonInForStatements": "Define o tratamento de espaços após um ponto e vírgula para um comando.", "format.insertSpaceBeforeAndAfterBinaryOperators": "Define o tratamento de espaços após um operador binário.", "format.insertSpaceAfterKeywordsInControlFlowStatements": "Define o tratamento de espaços após palavras-chave em um comando de controle de fluxo.", @@ -41,6 +41,8 @@ "typescript.selectTypeScriptVersion.title": "Selecionar a versão do JavaScript", "jsDocCompletion.enabled": "Habilitar/Desabilitar comentários JSDoc automáticos.", "javascript.implicitProjectConfig.checkJs": "Habilitar/desabilitar verificação semântica de arquivos JavaScript. Os arquivos existentes jsconfig.json ou tsconfig.json substituem essa configuração. Requer TypeScript > = 2.3.1.", + "typescript.npm": "Especifica o caminho para o executável do NPM usado para Aquisição de Tipo Automático. Requer TypeScript > = 2.3.4.", + "typescript.check.npmIsInstalled": "Verificar se o NPM está instalado para aquisição automática de tipo.", "javascript.nameSuggestions": "Habilitar/desabilitar incluindo nomes exclusivos do arquivo nas listas de sugestão de JavaScript.", "typescript.tsc.autoDetect": "Controla se a auto-detecção de tarefas tsc estão ligadas ou desligadas." } \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/common/errorMessage.i18n.json b/i18n/ptb/src/vs/base/common/errorMessage.i18n.json index 257ffd9e14c..8653d71b65e 100644 --- a/i18n/ptb/src/vs/base/common/errorMessage.i18n.json +++ b/i18n/ptb/src/vs/base/common/errorMessage.i18n.json @@ -13,6 +13,5 @@ "error.connection.unknown": "Ocorreu um erro de conexão desconhecido. Você não está mais conectado à Internet ou o servidor que você está conectado está offline.", "stackTrace.format": "{0}: {1}", "error.defaultMessage": "Ocorreu um erro desconhecido. Consulte o log para obter mais detalhes.", - "nodeExceptionMessage": "Ocorreu um erro de sistema ({0})", "error.moreErrors": "{0} ({1} erros no total)" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/base/common/keybindingLabels.i18n.json b/i18n/ptb/src/vs/base/common/keybindingLabels.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ptb/src/vs/base/common/keybindingLabels.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ptb/src/vs/code/electron-main/menus.i18n.json b/i18n/ptb/src/vs/code/electron-main/menus.i18n.json index 2a3b275d70d..91b837832c4 100644 --- a/i18n/ptb/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/ptb/src/vs/code/electron-main/menus.i18n.json @@ -12,6 +12,7 @@ "mDebug": "&&Depurar", "mWindow": "Janela", "mHelp": "&&Ajuda", + "mTask": "&&Tarefas", "miNewWindow": "Nova &&Janela", "mAbout": "Sobre {0}", "mServices": "Serviços", @@ -41,6 +42,7 @@ "miSelectIconTheme": "&&Ãcone de Arquivo do Tema", "miPreferences": "&&Preferências", "miReopenClosedEditor": "&&Reabrir Editor Fechado", + "miMore": "&&Mais...", "miClearRecentOpen": "&&Limpar Arquivos Recentes", "miUndo": "&&Desfazer", "miRedo": "&&Refazer", @@ -55,6 +57,9 @@ "miShowEmmetCommands": "E&&mmet...", "miToggleLineComment": "&&Alternar Comentário de Linha", "miToggleBlockComment": "Alternar Comentário de &&Bloco", + "miMultiCursorAlt": "Use Alt+clique para Multi-Cursor", + "miMultiCursorCmd": "Use o Cmd+clique para Multi-Cursor", + "miMultiCursorCtrl": "Use Ctrl+clique para Multi-Cursor", "miInsertCursorAbove": "&&Inserir cursor acima", "miInsertCursorBelow": "Inserir cursor a&&baixo", "miInsertCursorAtEndOfEachLineSelected": "Adicionar C&&ursores ao Final das Linhas", @@ -133,12 +138,13 @@ "miColumnBreakpoint": "Ponto de Parada de C&&oluna", "miFunctionBreakpoint": "Ponto de Parada de &&Função...", "miNewBreakpoint": "&&Novo Ponto de Parada", + "miEnableAllBreakpoints": "Habilitar Todos os Pontos de Parada", "miDisableAllBreakpoints": "Desabilitar T&&odos os Pontos de Parada", "miRemoveAllBreakpoints": "Remover &&Todos os Pontos de Parada", "miInstallAdditionalDebuggers": "&&Instalar Depuradores Adicionais...", "mMinimize": "Minimizar", - "mClose": "Fechar", "mBringToFront": "Trazer Tudo para a Frente", + "miSwitchWindow": "Alternar &&Janela...", "miToggleDevTools": "&&Alternar Ferramentas do Desenvolvedor", "miAccessibilityOptions": "&&Opções de Acessibilidade", "miReportIssues": "Relatar &&Problemas", @@ -153,12 +159,19 @@ "miLicense": "&&Exibir Licença", "miPrivacyStatement": "&&Política de Privacidade", "miAbout": "&&Sobre", + "miRunTask": "&&Executar Tarefa...", + "miRestartTask": "R&&einiciar Tarefa", + "miTerminateTask": "&&Finalizar Tarefa", + "miBuildTask": "&&Tarefa de Compilação.", + "miTestTask": "Tarefa de T&&este", + "miShowTaskLog": "&&Visualizar o Log de Tarefas", "accessibilityOptionsWindowTitle": "Opções de Acessibilidade", "miRestartToUpdate": "Reinicie para Atualizar...", "miCheckingForUpdates": "Verificando Atualizações...", "miDownloadUpdate": "Baixar Atualização Disponível", "miDownloadingUpdate": "Baixando Atualização...", "miInstallingUpdate": "Instalando Atualização...", + "miCheckForUpdates": "Verificar Atualizações...", "aboutDetail": "\nVersão {0}\nConfirmação {1}\nData {2}\nShell {3}\nRenderizador {4}\nNó {5}", "okButton": "OK" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/code/electron-main/windows.i18n.json b/i18n/ptb/src/vs/code/electron-main/windows.i18n.json index abf3a42e2eb..639e101557f 100644 --- a/i18n/ptb/src/vs/code/electron-main/windows.i18n.json +++ b/i18n/ptb/src/vs/code/electron-main/windows.i18n.json @@ -13,9 +13,5 @@ "appStalled": "A janela não está mais respondendo", "appStalledDetail": "Você pode reabrir, fechar a janela ou continuar esperando.", "appCrashed": "A janela foi fechada inesperadamente", - "appCrashedDetail": "Pedimos desculpas pelo inconveniente! Você pode reabrir a janela para continuar de onde parou.", - "newWindow": "Nova Janela", - "newWindowDesc": "Abrir uma nova janela", - "recentFolders": "Pastas Recentes", - "folderDesc": "{0} {1}" + "appCrashedDetail": "Pedimos desculpas pelo inconveniente! Você pode reabrir a janela para continuar de onde parou." } \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/ptb/src/vs/editor/common/config/commonEditorConfig.i18n.json index 7de4c179900..4dbd3e7153e 100644 --- a/i18n/ptb/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/ptb/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -21,6 +21,7 @@ "roundedSelection": "Controla se as seleções têm cantos arredondados", "scrollBeyondLastLine": "Controla se o editor rolará além da última linha", "minimap.enabled": "Controla se o mini mapa é exibido", + "minimap.showSlider": "Controla se o controle deslizante minimap é oculto automaticamente.", "minimap.renderCharacters": "Renderizar os caracteres em uma linha (em oposição a blocos de caracteres)", "minimap.maxColumn": "Limitar o tamanho de um mini-mapa para renderizar no máximo um número determinado de colunas", "find.seedSearchStringFromSelection": "Controla se nós inicializamos a string de pesquisa na Ferramenta de Pesquisa a partir da seleção do editor", @@ -33,12 +34,15 @@ "wordWrapColumn": "Controla a coluna de quebra de linha do editor quando editor.wordWrap` é 'wordWrapColumn' ou 'bounded'.", "wrappingIndent": "Controla o recuo de linhas quebradas. Pode ser \"none\", \"same\" ou \"indent\".", "mouseWheelScrollSensitivity": "Um multiplicador a ser usado em \"deltaX\" e \"deltaY\" dos eventos de rolagem do botão de rolagem do mouse", + "multiCursorModifier.ctrlCmd": "Mapeia para 'Control' no Windows e Linux e 'Command' no OSX.", + "multiCursorModifier.alt": "Mapeia para 'Alt' em Windows e Linux e 'Option' em OSX.", + "multiCursorModifier": "O modificador a ser usado para adicionar vários cursores com o mouse. `ctrlCmd` mapeia 'Control' no Windows e Linux e 'Command' no OSX. Os gestos do mouse Ir para definição e Abrir Link irão adaptar-se tal maneira que eles não entrem em conflito com o modificador multicursor.", "quickSuggestions.strings": "Habilitar sugestões rápidas dentro de strings.", "quickSuggestions.comments": "Habilitar sugestões rápidas dentro de comentários.", "quickSuggestions.other": "Habilitar sugestões rápidas fora de strings e comentários.", "quickSuggestions": "Controlar se sugestões devem aparecer automaticamente ao digitar", "quickSuggestionsDelay": "Controla o atraso em ms após o qual sugestões rápidas serão exibidas", - "parameterHints": "Habilita dicas de parâmetros", + "parameterHints": "Habilita pop-up que mostra documentação de parâmetros e o tipo de informação conforme você digita", "autoClosingBrackets": "Controla se o editor deve fechar colchetes automaticamente depois de abri-los", "formatOnType": "Controla se o editor deve formatar automaticamente a linha após a digitação", "formatOnPaste": "Controla se o editor deve formatar automaticamente o conteúdo colado. Um formatador deve estar disponível e o formatador deve ser capaz de formatar apenas uma parte do documento.", @@ -72,6 +76,11 @@ "trimAutoWhitespace": "Remove espaços em branco inseridos automaticamente no fim da linha", "stablePeek": "Mantém os editores de visualização abertos mesmo quando clicando seu conteúdo ou teclando Escape.", "dragAndDrop": "Controla se o editor deve permitir mover seleções via arrastar e soltar.", + "accessibilitySupport.auto": "O editor irá utilizar a plataforma da API para detectar quando um leitor de tela está conectado.", + "accessibilitySupport.on": "O editor será permanentemente otimizado para o uso de um leitor de tela.", + "accessibilitySupport.off": "O editor nunca será otimizado para o uso de um leitor de tela.", + "accessibilitySupport": "Controla quando o editor deve executar em modo otimizado para leitores de tela.", + "links": "Controla se o editor deve detectar links e torná-los clicáveis", "sideBySide": "Controla se o editor de diff mostra as diff lado a lado ou inline.", "ignoreTrimWhitespace": "Controla se o editor de diff mostra alterações nos espaços iniciais ou finais como diferenças", "renderIndicators": "Controla se o editor de diff mostra indicadores +/- para alterações adicionadas/removidas", diff --git a/i18n/ptb/src/vs/editor/common/config/editorOptions.i18n.json b/i18n/ptb/src/vs/editor/common/config/editorOptions.i18n.json index 40fed0886cc..53f11838ed4 100644 --- a/i18n/ptb/src/vs/editor/common/config/editorOptions.i18n.json +++ b/i18n/ptb/src/vs/editor/common/config/editorOptions.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "accessibilityOffAriaLabel": "O editor não está acessível neste momento. Por favor pressione Alt+F1 para opções.", "editorViewAccessibleLabel": "Conteúdo do editor" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/find/common/findController.i18n.json b/i18n/ptb/src/vs/editor/contrib/find/common/findController.i18n.json index 07397efa5fe..c8f66700ae9 100644 --- a/i18n/ptb/src/vs/editor/contrib/find/common/findController.i18n.json +++ b/i18n/ptb/src/vs/editor/contrib/find/common/findController.i18n.json @@ -14,6 +14,5 @@ "addSelectionToPreviousFindMatch": "Adicionar Seleção à Correspondência de Localização Anterior", "moveSelectionToNextFindMatch": "Mover Última Seleção para Próximo Localizar Correspondência", "moveSelectionToPreviousFindMatch": "Mover Última Seleção para Correspondência de Localização Anterior", - "selectAllOccurencesOfFindMatch": "Selecionar Todas as Ocorrências de Localizar Correspondência", "changeAll.label": "Alterar todas as ocorrências" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json b/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json index 47c3685850e..2e25322d32c 100644 --- a/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json +++ b/i18n/ptb/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json @@ -5,8 +5,8 @@ // Do not edit this file. It is machine generated. { "aria.oneReference": "símbolo em {0} na linha {1} e coluna {2}", - "aria.fileReferences.1": "1 símbolo em {0}", - "aria.fileReferences.N": "{0} símbolos em {1}", + "aria.fileReferences.1": "1 símbolo em {0}, caminho completo {1}", + "aria.fileReferences.N": "{0} símbolos em {1}, caminho completo {2}", "aria.result.0": "Nenhum resultado encontrado", "aria.result.1": "Encontrado 1 símbolo em {0}", "aria.result.n1": "Encontrados {0} símbolos em {1}", diff --git a/i18n/ptb/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json b/i18n/ptb/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json index a8ef6175a09..d7ef91038db 100644 --- a/i18n/ptb/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json +++ b/i18n/ptb/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json @@ -21,6 +21,8 @@ "menus.scmTitle": "O menu de título do controle de fonte", "menus.resourceGroupContext": "O menu de contexto do grupo de recursos de controle de fonte", "menus.resourceStateContext": "O menu de contexto de estado de recursos do controle de fonte", + "view.viewTitle": "O menu de título da visualização contribuída", + "view.itemContext": "O menu de contexto do item da visualização contribuída", "nonempty": "Esperado um valor não vazio", "opticon": "a propriedade '{0}' é opcional ou pode ser do tipo 'string'", "requireStringOrObject": "a propriedade '{0}' é obrigatória e deve ser do tipo 'string'", diff --git a/i18n/ptb/src/vs/platform/extensions/common/extensionsRegistry.i18n.json b/i18n/ptb/src/vs/platform/extensions/common/extensionsRegistry.i18n.json index 649e13b03b1..8de8bd11bbf 100644 --- a/i18n/ptb/src/vs/platform/extensions/common/extensionsRegistry.i18n.json +++ b/i18n/ptb/src/vs/platform/extensions/common/extensionsRegistry.i18n.json @@ -14,6 +14,12 @@ "vscode.extension.contributes": "Todas as contribuições da extensão VS Code representadas por este pacote.", "vscode.extension.preview": "Configura a extensão para ser marcada como pré-visualização na Loja.", "vscode.extension.activationEvents": "Eventos de ativação para a extensão VS Code.", + "vscode.extension.activationEvents.onLanguage": "Um evento de ativação emitido sempre que um arquivo que resolve para a linguagem especificada é aberto.", + "vscode.extension.activationEvents.onCommand": "Um evento de ativação emitido sempre que o comando especificado for invocado.", + "vscode.extension.activationEvents.onDebug": "Um evento de ativação emitido sempre que uma sessão de depuração do tipo especificado é iniciada.", + "vscode.extension.activationEvents.workspaceContains": "Um evento de ativação emitido quando uma pasta que contém pelo menos um arquivo correspondente ao padrão global especificado é aberta.", + "vscode.extension.activationEvents.onView": "Um evento de ativação emitido sempre que o modo de visualização especificado é expandido.", + "vscode.extension.activationEvents.star": "Um evento de ativação emitido na inicialização do VS Code. Para garantir uma ótima experiência de usuário, por favor, use este evento de ativação em sua extensão somente quando nenhuma outra combinação de eventos de ativação funcionar em seu caso de uso.", "vscode.extension.badges": "Matriz de emblemas a mostrar na barra lateral da página da extensão na Loja.", "vscode.extension.badges.url": "URL da imagem do emblema.", "vscode.extension.badges.href": "Link do emblema.", diff --git a/i18n/ptb/src/vs/platform/history/electron-main/historyMainService.i18n.json b/i18n/ptb/src/vs/platform/history/electron-main/historyMainService.i18n.json new file mode 100644 index 00000000000..05f131174ea --- /dev/null +++ b/i18n/ptb/src/vs/platform/history/electron-main/historyMainService.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "newWindow": "Nova Janela", + "newWindowDesc": "Abrir uma nova janela", + "recentFolders": "Pastas Recentes", + "folderDesc": "{0} {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/ptb/src/vs/platform/theme/common/colorRegistry.i18n.json index ca84c495b32..0cfc1a7ffbe 100644 --- a/i18n/ptb/src/vs/platform/theme/common/colorRegistry.i18n.json +++ b/i18n/ptb/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -12,7 +12,7 @@ "focusBorder": "Cor geral da borda para elementos focalizados. Essa cor é usada somente se não for substituída por um componente.", "contrastBorder": "Uma borda extra em torno de elementos para separá-los dos outros de maior contraste.", "activeContrastBorder": "Uma borda extra em torno de elementos ativos para separá-los dos outros de maior contraste.", - "selectionBackground": "A cor de fundo das seleções de texto na bancada de trabalho (por exemplo, para campos de entrada ou áreas de texto). Note que isto não se aplica a seleções dentro do editor e do terminal.", + "selectionBackground": "A cor de fundo das seleções de texto na área de trabalho (por exemplo, para campos de entrada ou áreas de texto). Note que isto não se aplica a seleções dentro do editor.", "textSeparatorForeground": "Cor para separadores de texto.", "textLinkForeground": "Cor de primeiro plano para links no texto.", "textLinkActiveForeground": "Cor de primeiro plano para links ativos no texto.", @@ -60,6 +60,7 @@ "editorBackground": "Cor de plano de fundo do editor.", "editorForeground": "Cor de primeiro plano padrão do editor.", "editorWidgetBackground": "Cor de plano de fundo das ferramentas de edição, como pesquisar/substituir.", + "editorWidgetBorder": "Cor da borda das ferramentas do editor. A cor é usada somente se a ferramenta escolhe ter uma borda e a cor não é substituída por uma ferramenta.", "editorSelection": "Cor de seleção do editor.", "editorInactiveSelection": "Cor de seleção em um editor inativo.", "editorSelectionHighlight": "Cor de regiões com o mesmo conteúdo da seleção.", @@ -78,6 +79,7 @@ "mergeCurrentContentBackground": "Cor de fundo de conteúdo atual em conflito de mesclagem em linha.", "mergeIncomingHeaderBackground": "Cor de fundo de cabeçalho de entrada em conflito de mesclagem em linha.", "mergeIncomingContentBackground": "Cor de fundo de conteúdo de entrada em conflito de mesclagem em linha.", + "mergeBorder": "Cor da borda dos cabeçalhos e separadores estão em conflito de mesclagem em linha.", "overviewRulerCurrentContentForeground": "Cor de fundo de régua de visuaização atual em conflito de mesclagem em linha.", "overviewRulerIncomingContentForeground": "Cor de fundo de régua de visuaização de entrada em conflito de mesclagem em linha." } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/ptb/src/vs/workbench/api/node/extHostTask.i18n.json index 8b6ad71cd4e..4b90a12aaf2 100644 --- a/i18n/ptb/src/vs/workbench/api/node/extHostTask.i18n.json +++ b/i18n/ptb/src/vs/workbench/api/node/extHostTask.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "task.label": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json index 5f8a7bb47de..577ad33d0b4 100644 --- a/i18n/ptb/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json +++ b/i18n/ptb/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json @@ -5,5 +5,6 @@ // Do not edit this file. It is machine generated. { "hideActivitBar": "Ocultar a Barra de Atividades", - "activityBarAriaLabel": "Chave do Modo de exibição Ativo" + "activityBarAriaLabel": "Chave do Modo de exibição Ativo", + "globalActions": "Ações globais" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/editorActions.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorActions.i18n.json index ae6f9ae84b7..b4974267667 100644 --- a/i18n/ptb/src/vs/workbench/browser/parts/editor/editorActions.i18n.json +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorActions.i18n.json @@ -19,6 +19,7 @@ "closeEditorsToTheLeft": "Fechar editores à esquerda ", "closeEditorsToTheRight": "Fechar editores à direita", "closeAllEditors": "Fechar todos editores", + "closeUnmodifiedEditors": "Fechar os Editores Não Modificados no Grupo", "closeEditorsInOtherGroups": "Fechar editores nos outros grupos", "closeOtherEditorsInGroup": "Fechar outros editores", "closeEditorsInGroup": "Fechar todos editores no grupo", diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json index ff6a038e701..7ec5ce6904c 100644 --- a/i18n/ptb/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json @@ -10,8 +10,9 @@ "multiSelection": "{0} seleções", "endOfLineLineFeed": "LF", "endOfLineCarriageReturnLineFeed": "CRLF", - "tabFocusModeEnabled": "Tabulação move o foco", - "screenReaderDetected": "Leitor de tela detectado", + "tabFocusModeEnabled": "Tabulação Move o Foco", + "screenReaderDetected": "Leitor de Tela Detectado", + "screenReaderDetectedExtra": "Se você não estiver usando um leitor de tela, por favor altere a configuração `editor.accessibilitySupport` para \"desligado\".", "disableTabMode": "Desativar o modo de acessibilidade", "gotoLine": "Ir para linha", "indentation": "Indentação", diff --git a/i18n/ptb/src/vs/workbench/browser/parts/editor/titleControl.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/editor/titleControl.i18n.json index bf8307cd384..aafa87dc9bf 100644 --- a/i18n/ptb/src/vs/workbench/browser/parts/editor/titleControl.i18n.json +++ b/i18n/ptb/src/vs/workbench/browser/parts/editor/titleControl.i18n.json @@ -8,6 +8,7 @@ "closeOthers": "Fechar Outros", "closeRight": "Fechar à direita", "closeAll": "Fechar todos", + "closeAllUnmodified": "Fechar Não Modificados", "keepOpen": "Manter aberto", "showOpenedEditors": "Mostrar editores abertos", "araLabelEditorActions": "Ações de editor" diff --git a/i18n/ptb/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json b/i18n/ptb/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json new file mode 100644 index 00000000000..57f5524e1be --- /dev/null +++ b/i18n/ptb/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpen": "Ir para o Arquivo...", + "quickNavigateNext": "Navegar ao próximo em modo de abertura rápida", + "quickNavigatePrevious": "Navegar ao anterior em modo de abertura rápida", + "quickSelectNext": "Selecionar próximo em modo de abertura rápida", + "quickSelectPrevious": "Selecionar anterior em modo de abertura rápida" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/quickopen.i18n.json b/i18n/ptb/src/vs/workbench/browser/quickopen.i18n.json index 26c5e14f367..098ead453d8 100644 --- a/i18n/ptb/src/vs/workbench/browser/quickopen.i18n.json +++ b/i18n/ptb/src/vs/workbench/browser/quickopen.i18n.json @@ -6,6 +6,5 @@ { "noResultsMatching": "Nenhum resultado encontrado", "noResultsFound2": "Nenhum resultado encontrado", - "entryAriaLabel": "{0}, comando", - "noCommands": "Não há comandos correspondentes" + "entryAriaLabel": "{0}, comando" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/browser/viewlet.i18n.json b/i18n/ptb/src/vs/workbench/browser/viewlet.i18n.json index 34655b736ba..4b960693e35 100644 --- a/i18n/ptb/src/vs/workbench/browser/viewlet.i18n.json +++ b/i18n/ptb/src/vs/workbench/browser/viewlet.i18n.json @@ -4,6 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "collapse": "Recolher tudo", - "viewToolbarAriaLabel": "{0} ações " + "collapse": "Recolher tudo" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/common/theme.i18n.json b/i18n/ptb/src/vs/workbench/common/theme.i18n.json index 0ba78701559..86cc4957066 100644 --- a/i18n/ptb/src/vs/workbench/common/theme.i18n.json +++ b/i18n/ptb/src/vs/workbench/common/theme.i18n.json @@ -7,12 +7,17 @@ "tabActiveBackground": "Cor de fundo da guia ativa. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", "tabInactiveBackground": "Cor de fundo da guia inativa. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", "tabBorder": "Borda para separar uma guia das outras. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", + "tabActiveForeground": "Cor de primeiro plano da guia ativa em um grupo ativo. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", + "tabInactiveForeground": "Cor de primeiro plano da guia inativa em um grupo ativo. As guias são os recipientes para editores na área do editor. Várias guias podem ser abertas em um grupo de editores. Podem haver vários grupos de editor.", + "tabUnfocusedActiveForeground": "Cor de primeiro plano da aba ativa em um grupo inativo. As abas são recipientes para editores na área do editor. Várias abas podem ser abertas em um grupo de editor. Pode haver vários grupos de editor.", + "tabUnfocusedInactiveForeground": "Cor de primeiro plano da aba inativa em um grupo inativo. As abas são recipientes para editores na área do editor. Várias abas podem ser abertas em um grupo de editor. Pode haver vários grupos de editor.", "editorGroupBackground": "Cor de fundo de um grupo de editor. Grupos de editor são os recipientes dos editores. A cor de fundo é mostrada ao arrastar o editor de grupos ao redor.", "tabsContainerBackground": "Cor de fundo do cabeçalho do título do grupo de editor quando as guias são habilitadas. Grupos de editor são os recipientes dos editores.", "tabsContainerBorder": "Cor da borda do cabeçalho do título do grupo de editor quando as guias estão habilitadas. Grupos de editor são os recipientes dos editores.", "editorGroupHeaderBackground": "Cor de fundo do título do cabeçalho do grupo de editor quando as guias são desabilitadas. Grupos de editor são os recipientes dos editores.", "editorGroupBorder": "Cor para separar múltiplos grupos de editor de outro. Grupos de editor são os recipientes dos editores.", "editorDragAndDropBackground": "Cor de fundo ao arrastar editores. A cor deve ter transparência para que o conteúdo do editor ainda possa ser visto.", + "panelBackground": "Cor de fundo do painel. Os painéis são mostrados abaixo da área do editor e contém visualizações como saída e terminal integrado.", "panelBorder": "Cor da borda do painel no topo separando do editor. Os painéis são mostrados abaixo da área do editor e contém visualizações como saída e terminal integrado.", "panelActiveTitleForeground": "Cor do título para o painel ativo. Os painéis são mostrados abaixo da área do editor e contém visualizações como saída e terminal integrado.", "panelInactiveTitleForeground": "Cor do título para o painel inativo. Os painéis são mostrados abaixo da área do editor e contém visualizações como saída e terminal integrado.", @@ -43,5 +48,14 @@ "titleBarActiveBackground": "Cor de fundo da barra de título quando a janela está ativa. Observe que essa cor atualmente somente é suportada no macOS.", "titleBarInactiveBackground": "Cor de fundo de barra de título quando a janela está inativa. Observe que essa cor é atualmente somente suportada no macOS.", "notificationsForeground": "Cor do primeiro plano de notificações. Notificações deslizam na parte superior da janela.", - "notificationsBackground": "Cor de fundo de notificações. Notificações deslizam na parte superior da janela." + "notificationsBackground": "Cor de fundo de notificações. Notificações deslizam na parte superior da janela.", + "notificationsButtonBackground": "Cor de fundo do botão de notificações. Notificações deslizam da parte superior da janela.", + "notificationsButtonHoverBackground": "Cor de fundo do botão de notificações quando passar sobre ele. Notificações deslizam da parte superior da janela. ", + "notificationsButtonForeground": "Cor de primeiro plano do botão de notificações. Notificações deslizam da parte superior da janela. ", + "notificationsInfoBackground": "Cor de fundo da notificação de informações. Notificações deslizam da parte superior da janela. ", + "notificationsInfoForeground": "Cor de primeiro plano das notificações de informação. Notificações deslizam da parte superior da janela. ", + "notificationsWarningBackground": "Cor de fundo das notificações de aviso. Notificações deslizam da parte superior da janela. ", + "notificationsWarningForeground": "Cor de primeiro plano das notificações de aviso. Notificações deslizam da parte superior da janela.", + "notificationsErrorBackground": "Cor de fundo das notificações de erro. Notificações deslizam da parte superior da janela. ", + "notificationsErrorForeground": "Cor de primeiro plano das notificações de erro. Notificações deslizam da parte superior da janela." } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/electron-browser/actions.i18n.json b/i18n/ptb/src/vs/workbench/electron-browser/actions.i18n.json index d829a3c8cad..d1ec3a23336 100644 --- a/i18n/ptb/src/vs/workbench/electron-browser/actions.i18n.json +++ b/i18n/ptb/src/vs/workbench/electron-browser/actions.i18n.json @@ -6,9 +6,6 @@ { "closeActiveEditor": "Fechar Editor", "closeWindow": "Fechar Janela", - "switchWindow": "Alternar Janela", - "switchWindowPlaceHolder": "Selecionar uma janela", - "current": "Janela Atual", "closeFolder": "Fechar Pasta", "noFolderOpened": "Não há nenhuma pasta aberta nesta instância para ser fechada.", "newWindow": "Nova Janela", @@ -20,11 +17,16 @@ "zoomReset": "Reinicializar Zoom", "appPerf": "Desempenho de inicialização", "reloadWindow": "Recarregar Janela", - "openRecent": "Abrir Recente", + "switchWindowPlaceHolder": "Selecionar uma janela para onde alternar", + "current": "Janela Atual", + "switchWindow": "Alternar a janela...", + "quickSwitchWindow": "Troca Rápida de Janela...", "folders": "pastas", "files": "arquivos", "openRecentPlaceHolderMac": "Selecionar um caminho (Pressione a tecla Cmd para abrir em uma nova janela)", "openRecentPlaceHolder": "Selecionar um caminho para abrir (Pressione a tecla Cmd para abrir em uma nova janela)", + "openRecent": "Abrir Recente...", + "quickOpenRecent": "Abertura Rápida de Recente...", "closeMessages": "Fechar mensagens de notificação", "reportIssues": "Reportar Problemas", "reportPerformanceIssue": "Reportar Problema de Desempenho", @@ -32,10 +34,10 @@ "openDocumentationUrl": "Documentação", "openIntroductoryVideosUrl": "Vídeos Introdutórios", "toggleSharedProcess": "Alternar processo compartilhado", - "navigateLeft": "Mover para a Visualizção à Esquerda", - "navigateRight": "Mover para a Visualização à Direita", - "navigateUp": "Mover para a Visualização Acima", - "navigateDown": "Mover para a Visualização Abaixo", + "navigateLeft": "Navegar para a Visualização à Esquerda", + "navigateRight": "Navegar para a Visualização à Direita", + "navigateUp": "Navegar para a Visualização Acima", + "navigateDown": "Navegar para a Visualização Abaixo", "increaseViewSize": "Aumentar o Tamanho da Visualização Atual", "decreaseViewSize": "Diminuir o Tamanho da Visualização Atual" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/ptb/src/vs/workbench/electron-browser/main.contribution.i18n.json index 3b9050de1af..710676ff7ae 100644 --- a/i18n/ptb/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/ptb/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -15,6 +15,8 @@ "enablePreviewFromQuickOpen": "Controla se os editores abertos da Abertura Rápida são exibidos como visualização. Os editores de visualização são reutilizados até serem preservados (por exemplo, através de um duplo clique ou edição).", "editorOpenPositioning": "Controla onde os editores serão abertos. Escolha 'esquerda' ou 'direita' para abrir os editores à esquerda ou à direita do \neditor ativo. Selecione 'primeiro' ou 'último' para abrir os editores independentemente do atual.", "revealIfOpen": "Controla se um editor é exibido em qualquer um dos grupos, se aberto. Se desabilitado, um editor será aberto preferencialmente no grupo de editores ativo. Se habilitado, um editor já aberto será exibido no grupo de editores ativo, ao invés de ser aberto novamente. Note que há alguns casos onde esta configuração é ignorada, por exemplo, quando for forçada a abertura de um editor em um grupo específico ou ao lado do grupo atualmente ativo.", + "commandHistory": "Controla o número de comandos recentemente usados mantidos no histórico para a paleta de comandos. Definir como 0 para desativar o histórico de comandos.", + "preserveInput": "Controla se a última entrada digitada na paleta de comandos deve ser restaurada ao abri-la da próxima vez.", "closeOnFocusLost": "Controla se Abertura Rápida deve fechar automaticamente caso perca o foco.", "openDefaultSettings": "Controla se a abertura de configurações também abre um editor mostrando todas as configurações padrão.", "sideBarLocation": "Controla a localização da barra lateral. Ele pode ser exibido à esquerda ou à direita da área de trabalho.", @@ -31,10 +33,10 @@ "window.openFoldersInNewWindow.off": "As pastas substituirão a última janela ativa", "window.openFoldersInNewWindow.default": "As pastas serão abertas em uma nova janela, a menos que uma pasta seja selecionada dentro do aplicativo (por exemplo, através do menu Arquivo)", "openFoldersInNewWindow": "Controla se as pastas devem ser abertas em uma nova janela ou substituir a última janela ativa\n- padrão: as pastas serão abertas em uma nova janela, a menos que seja selecionada dentro do aplicativo (por exemplo, através do menu Arquivo)\n- ligado: as pastas serão abertas em uma nova janela\n- desligado: as pastas substituirão a última janela ativa\nNote que ainda podem haver casos em que esta configuração será ignorada (por exemplo, quando estiver usando as opções de linha de comando -new-window ou -reuse-window).", - "window.reopenFolders.none": "Nunca reabra uma pasta.", - "window.reopenFolders.one": "Reabrir a última pasta ativa.", - "window.reopenFolders.all": "Reabrir todas as pastas da última sessão.", - "reopenFolders": "Controla como as pastas são reabertas depois de um reinício. Escolha 'nenhum' para nunca reabrir uma pasta, 'uma' para reabrir a última pasta que você trabalhou ou 'todas' para reabrir todas as pastas da sua última sessão.", + "window.reopenFolders.all": "Reabrir todas as janelas.", + "window.reopenFolders.folders": "Reabrir todas as pastas. Janelas vazias não serão restauradas.", + "window.reopenFolders.one": "Reabrir a última janela ativa.", + "window.reopenFolders.none": "Nunca reabrir uma janela. Sempre começar com uma janela vazia.", "restoreFullscreen": "Controla se uma janela deve ser restaurada em modo de tela cheia se ela foi finalizada em modo de tela cheia.", "zoomLevel": "Ajusta o nível de zoom da janela. O tamanho original é 0 e cada aumento (por exemplo, 1) ou redução (por exemplo, -1) representa um zoom 20% maior ou menor. Você também pode digitar decimais para ajustar o nível de zoom com uma granularidade mais fina.", "title": "Controla o título da janela com base no editor ativo. As variáveis são substituídas com base no contexto:\n$ {ActiveEditorShort}: por exemplo, meuArquivo.txt\n$ {ActiveEditorMedium}: por exemplo, minhaPasta / meuArquivo.txt\n$ {ActiveEditorLong}: por exemplo, /Usuários/Desenvolvimento/meuProjeto/minhaPasta/meuArquivo.txt\n$ {RootName}: por exemplo, meuProjeto\n$ {RootPath}: por exemplo, /Usuários/Desenvolvimento/meuProjeto\n$ {AppName}: por exemplo, VS Code\n$ {Dirty}: um indicador sujo se o editor ativo for sujo\n$ {Separator}: um separador condicional (\"-\") que só aparece quando for rodeado por variáveis com valores", @@ -58,5 +60,8 @@ "zenMode.hideTabs": "Controla se a ativação do modo Zen também oculta as abas do espaço de trabalho.", "zenMode.hideStatusBar": "Controla se a ativação do modo Zen também oculta a barra de status no rodapé do espaço de trabalho.", "zenMode.hideActivityBar": "Controla se a ativação do modo Zen também oculta a barra de atividades à esquerda do espaço de trabalho.", - "zenMode.restore": "Controla se uma janela deve ser restaurada para o modo zen se ela foi finalizada no modo zen." + "zenMode.restore": "Controla se uma janela deve ser restaurada para o modo zen se ela foi finalizada no modo zen.", + "workspaceConfigurationTitle": "Espaço de trabalho", + "workspaces.title": "Configuração de pasta da área de trabalho", + "files.exclude.boolean": "O padrão glob com o qual combinar os caminhos de arquivo. Defina para verdadeiro ou falso para habilitar ou desabilitar o padrão." } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json new file mode 100644 index 00000000000..21239364c7c --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json @@ -0,0 +1,26 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "emergencyConfOn": "Modificando a configuração 'editor.accessibilitySupport' para 'on'.", + "openingDocs": "Abrindo a página de documentação de Acessibilidade do VS Code.", + "introMsg": "Obrigado por testar a opção de acessibilidade do VS Code.", + "status": "Status", + "changeConfigToOnMac": "Para configurar o editor para ser permanentemente otimizado para uso com um leitor de tela pressione Command+E agora.", + "changeConfigToOnWinLinux": "Para configurar o editor para ser permanentemente otimizado para uso com um leitor de tela pressione Control+E agora.", + "auto_unknown": "O editor está configurado para usar as APIs de plataforma para detectar quando está conectado a um leitor de tela, mas o tempo de execução atual não oferece suporte a isso.", + "auto_on": "O editor detectou automaticamente que foi anexado um leitor de tela.", + "auto_off": "O editor está configurado para detectar automaticamente quando um leitor de tela é anexado, o que não é o caso neste momento.", + "configuredOn": "O editor está configurado para ser permanentemente otimizado para uso com um leitor de tela - você pode mudar isso editando a configuração 'editor.accessibilitySupport'.", + "configuredOff": "O editor está configurado para nunca ser otimizado para uso com um Leitor de Tela.", + "tabFocusModeOnMsg": "Pressionando Tab no editor corrente irá mover o foco para o próximo elemento focável. Mude este comportamento ao pressionar {0}.", + "tabFocusModeOnMsgNoKb": "Pressionando Tab no editor corrente irá mover o foco para o próximo elemento focável. O comando {0} não pode ser ativado atualmente por uma tecla.", + "tabFocusModeOffMsg": "Pressionando Tab no editor atual irá inserir um caractere Tab. Mude este comportamente ao pressionar {0}.", + "tabFocusModeOffMsgNoKb": "Pressionando Tab no editor atual irá inserir um caractere Tab. O comando {0} não pode ser ativado atualmente por uma tecla.", + "openDocMac": "Pressione Command+H agora para abrir uma janela do navegador com mais informação do VS Code relacionada à Acessibilidade.", + "openDocWinLinux": "Pressione Ctrl+H para abrir uma janela do navegador com mais informação do VS Code relacionada à acessibilidade.", + "outroMsg": "Você pode ignorar esta dica de ferramenta e retornar ao editor pressionando Escape ou Shift+Escape.", + "ShowAccessibilityHelpAction": "Mostrar ajuda de acessibilidade" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json new file mode 100644 index 00000000000..955efefcac9 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleLocation": "Alternar Modificador de Multi-Cursor" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json index d14c4338ceb..c981f42161e 100644 --- a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json @@ -5,16 +5,12 @@ // Do not edit this file. It is machine generated. { "variablesSection": "Seção de variáveis", - "variables": "Variáveis", "variablesAriaTreeLabel": "Variáveis de Depuração", "expressionsSection": "Seção de Expressões", - "watch": "Monitoramento", "watchAriaTreeLabel": "Depurar Expressões Monitoradas", "callstackSection": "Seção de Pilha de Chamada", "debugStopped": "Pausado em {0}", - "callStack": "Pilha de Chamadas", "callStackAriaLabel": "Depurar a Pilha de Chamadas", "breakpointsSection": "Seção de Pontos de Parada", - "breakpoints": "Pontos de Parada", "breakpointsAriaTreeLabel": "Depurar os Pontos de Parada" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/repl.i18n.json b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/repl.i18n.json index 73f6f0be4c4..86d901ff7ca 100644 --- a/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/repl.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/debug/electron-browser/repl.i18n.json @@ -7,5 +7,6 @@ "replAriaLabel": "Ler o Painel de Impressão Eval", "actions.repl.historyPrevious": "História anterior", "actions.repl.historyNext": "Próxima história", - "actions.repl.acceptInput": "REPL Aceitar Entrada" + "actions.repl.acceptInput": "REPL Aceitar Entrada", + "actions.repl.copyAll": "Depurar: Copiar Todos os Consoles" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json index cccc82d8a01..d9e3601f991 100644 --- a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json @@ -4,6 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "previousEditPoint": "Emmet: Ponto de edição anterior", - "nextEditPoint": "Emmet: Ponto próxima edição" + "previousEditPoint": "Emmet: Ir para o Ponto de Edição Anterior", + "nextEditPoint": "Emmet: Ir para o Próximo Ponto de Edição" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json index 1caebe040f5..ee08d95bf18 100644 --- a/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json @@ -9,5 +9,6 @@ "emmetPreferences": "Preferências usadas para modificar o comportamento de algumas ações e resolvedores de Emmet.", "emmetSyntaxProfiles": "Definir o perfil para a sintaxe especificada ou usar seu próprio perfil com regras específicas.", "emmetExclude": "Uma matriz de línguagens onde abreviaturas emmet não devem ser expandidas.", - "emmetExtensionsPath": "Caminho para uma pasta contendo perfis emmet, trechos e preferências" + "emmetExtensionsPath": "Caminho para uma pasta contendo perfis emmet, trechos e preferências", + "useNewEmmet": "Experimente os novos módulos emmet (que irão substituir a antiga biblioteca unica emmet) para todos os recursos emmet." } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json b/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json index 1a3b9d4cd09..9a0bba90ea2 100644 --- a/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json @@ -24,6 +24,10 @@ "default": "Valor padrão", "debuggers": "Depuradores ({0})", "debugger name": "Nome", + "views": "Visualizações ({0})", + "view id": "ID", + "view name": "Nome", + "view location": "Onde", "themes": "Temas ({0})", "JSON Validation": "Validação JSON ({0})", "commands": "Comandos ({0})", diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index f4309c6a9bc..62b98096be4 100644 --- a/i18n/ptb/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -28,7 +28,7 @@ "watcherExclude": "Configure padrões glob de caminhos de arquivo para excluir do monitoramento de arquivos. Alterar essa configuração requer uma reinicialização. Quando você tiver consumo Code muito alto de cpu na inicialização, você pode excluir pastas grandes para reduzir a carga inicial.", "hotExit.off": "Desabilitar a saída à quente.", "hotExit.onExit": "Saída à quente será acionada quando o aplicativo for fechado, ou seja, quando a última janela é fechada no Windows/Linux ou quando o comando workbench.action.quit é acionado (paleta de comandos, keybinding, menu). Todas as janelas com backups serão restauradas na próxima execução.", - "hotExit.onExitAndWindowClose": "Saída à quente será acionada quando o aplicativo for fechado, ou seja, quando a última janela é fechada no Windows/Linux ou quando o comando workbench.action.quit é acionado (paleta de comando, keybinding, menu), e também para qualquer janela com uma pasta aberta independentemente se é a última janela. Todas as janelas sem pastas abertas serão restauradas na próxima execução. Para restaurar as janelas de pastas como eram antes do desligamento configure \"window.reopenFolders\" para \"todos\".", + "hotExit.onExitAndWindowClose": "Saída à quente será acionada quando o aplicativo for fechado, ou seja, quando a última janela é fechada no Windows/Linux ou quando o comando workbench.action.quit é acionado (paleta de comando, keybinding, menu), e também para qualquer janela com uma pasta aberta independentemente se é a última janela. Todas as janelas sem pastas abertas serão restauradas no próximo lançamento. Para restaurar janelas de pastas como eram antes do desligamento configure \"window.restoreWindows\" para \"todos\".", "hotExit": "Controla se os arquivos não salvos são lembrados entre as sessões, permitindo salvar alerta ao sair do editor seja ignorada.", "defaultLanguage": "O modo de linguagem padrão que é atribuída para novos arquivos.", "editorConfigurationTitle": "Editor", diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json index 58da5446b25..c06bcff690c 100644 --- a/i18n/ptb/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json @@ -5,7 +5,5 @@ // Do not edit this file. It is machine generated. { "explorerSection": "Seção de Explorador de Arquivos", - "noWorkspace": "Nenhuma Pasta Aberta", - "noWorkspaceHelp": "Você ainda não abriu uma pasta.", "openFolder": "Abrir Pasta" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json index 4db9c1f34d8..11563199929 100644 --- a/i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json @@ -4,8 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "openEditosrSection": "Abrir Seção de Editores", "openEditors": "Abrir Editores", + "openEditosrSection": "Abrir Seção de Editores", "treeAriaLabel": "Abrir Editores: Lista de Arquivos Ativos", "dirtyCounter": "{0} não salvos" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsViewer.i18n.json b/i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsViewer.i18n.json index dbef8f2ddb5..31c95aa9bce 100644 --- a/i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsViewer.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/files/browser/views/openEditorsViewer.i18n.json @@ -7,6 +7,7 @@ "editorGroupAriaLabel": "{0}, Agrupar Editor", "openEditorAriaLabel": "{0}, Abrir Editor", "saveAll": "Salvar Todos", + "closeAllUnmodified": "Fechar Não Modificados", "closeAll": "Fechar todos", "close": "Fechar", "closeOthers": "Fechar Outros" diff --git a/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json index a4aa8b55e2f..612db32643f 100644 --- a/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -5,5 +5,7 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.start": "Definir Keybinding", - "defineKeybinding.kbLayoutErrorMessage": "Você não será capaz de produzir esta combinação de teclas sob seu layout de teclado atual." + "defineKeybinding.kbLayoutErrorMessage": "Você não será capaz de produzir esta combinação de teclas sob seu layout de teclado atual.", + "defineKeybinding.kbLayoutLocalAndUSMessage": "**{0}** para o seu layout de teclado atual (**{1}** para US padrão).", + "defineKeybinding.kbLayoutLocalMessage": "**{0}** para o seu layout de teclado atual." } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json index 7b246da25ad..b6d5cdbd2e5 100644 --- a/i18n/ptb/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json @@ -5,11 +5,14 @@ // Do not edit this file. It is machine generated. { "showTriggerActions": "Mostrar todos os comandos", + "clearCommandHistory": "Limpar o Histórico de Comandos", "showCommands.label": "Paleta de comandos...", "entryAriaLabelWithKey": "{0}, {1}, comandos", "entryAriaLabel": "{0}, comandos", "canNotRun": "O comando '{0}' não pode ser executado a partir daqui.", "actionNotEnabled": "O comando '{0}' não está habilitado no contexto atual.", + "recentlyUsed": "usados recentemente", + "morecCommands": "outros comandos", "commandLabel": "{0}: {1}", "cat.title": "{0}: {1}", "noCommandsMatching": "Não há comandos correspondentes" diff --git a/i18n/ptb/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json new file mode 100644 index 00000000000..f7269eb27eb --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "relaunchMessage": "Uma configuração que requer uma reinicialização foi alterada.", + "relaunchDetail": "Pressione o botão de reinicialização para reiniciar {0} e habilitar a configuração.", + "restart": "Reiniciar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json index 05f799f7b6a..61a06337402 100644 --- a/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json @@ -11,6 +11,6 @@ "snippetSchema.json.default": "Trecho de código vazio", "snippetSchema.json": "Configuração do trecho do usuário", "snippetSchema.json.prefix": "O prefixo usado ao selecionar o trecho no intelliSense", - "snippetSchema.json.body": "O conteúdo do trecho de código. Use '${id}', '${id: rótulo}', '${1:label}' para variáveis e '$0', '$1' para posições do cursor", + "snippetSchema.json.body": "O conteúdo do trecho. Use '$1', '${1:defaultText}' para definir as posições do cursor, use '$0' para a posição final do cursor. Insira valores de variáveis com '${varName}' e '${varName:defaultText}', por exemplo ' Este é o arquivo: $TM_FILENAME'.", "snippetSchema.json.description": "A descrição do trecho." } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json new file mode 100644 index 00000000000..b16fc8446a4 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "helpUs": "Nos ajude a melhorar o nosso apoio para {0}", + "takeShortSurvey": "Responda a uma pesquisa curta", + "remindLater": "Lembrar mais tarde", + "neverAgain": "Não mostrar novamente" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json new file mode 100644 index 00000000000..1ec18c632a4 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "surveyQuestion": "Você deseja responder a uma pequena pesquisa?", + "takeSurvey": "Responder a pesquisa", + "remindLater": "Lembrar mais tarde", + "neverAgain": "Não mostrar novamente" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json new file mode 100644 index 00000000000..ccd588d4527 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksAriaLabel": "Digite o nome de uma tarefa de compilação", + "noTasksMatching": "Não há tarefas correspondentes", + "noTasksFound": "Tarefas de compilação não encontradas" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index 32bbf24976b..85a8f22ab41 100644 --- a/i18n/ptb/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0}, tarefas" + "entryAriaLabel": "{0}, tarefas", + "customizeTask": "Personalizar Tarefa" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json new file mode 100644 index 00000000000..07d53a8ee39 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksAriaLabel": "Digite o nome de uma tarefa de teste", + "noTasksMatching": "Não há tarefas correspondentes", + "noTasksFound": "Tarefas de teste não encontradas" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json index 45308919a6e..928e36c4c9b 100644 --- a/i18n/ptb/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -12,5 +12,6 @@ "ConfigurationParser.invalidVaraibleReference": "Erro: ProblemMatcher inválido referência: {0}\n", "ConfigurationParser.noTaskName": "Erro: tarefas devem fornecer uma propriedade taskName. A tarefa será ignorada.\n{0}\n", "taskConfiguration.shellArgs": "Aviso: a tarefa '{0}' é um comando do shell e o nome de comando ou um dos seus argumentos tem espaços sem escape. Para garantir a linha de comando correta por favor mesclar argumentos no comando.", + "taskConfiguration.noCommandOrDependsOn": "Erro: a tarefa '{0}' não especifica nem um comando nem uma propriedade dependsOn. A tarefa será ignorada. Sua definição é: \n{1}", "taskConfiguration.noCommand": "Erro: a tarefa '{0}' não define um comando. A tarefa será ignorada. Sua definição é: {1}" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json index 92ae501cdc8..4980a7daaa5 100644 --- a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json @@ -7,6 +7,7 @@ "JsonSchema.options": "Opções de comando adicionais", "JsonSchema.options.cwd": "O diretório de trabalho atual do programa executado ou do script. Se omitido raiz de espaço de trabalho atual do código é usado.", "JsonSchema.options.env": "O ambiente do programa executado ou comando shell. Se omitido o ambiente do processo pai é usado.", + "JsonSchema.shellConfiguration": "Configura a shell a ser usada.", "JsonSchema.shell.executable": "O shell a ser usado.", "JsonSchema.shell.args": "Os argumentos shell.", "JsonSchema.command": "O comando a ser executado. Pode ser um programa externo ou um comando shell.", diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json index dc0695101b0..46aad8f97ea 100644 --- a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json @@ -5,6 +5,8 @@ // Do not edit this file. It is machine generated. { "JsonSchema.version": "Número da versão do config", + "JsonSchema._runner": "O runner já se formou. Use a propriedade runner oficial", + "JsonSchema.runner": "Define se a tarefa é executada como um processo e a saída é mostrada na janela de saída ou dentro do terminal.", "JsonSchema.windows": "Configuração de comando específica do Windows", "JsonSchema.mac": "Configuração de comando específica do Mac", "JsonSchema.linux": "Configuração de comando específica do Linux", diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json index 9010242ce87..9053b4d29ee 100644 --- a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -7,6 +7,10 @@ "JsonSchema.shell": "Especifica se o comando é um comando shell ou um programa externo. O padrão é falso se omitido.", "JsonSchema.tasks.dependsOn.string": "Outra tarefa da qual esta tarefa depende.", "JsonSchema.tasks.dependsOn.array": "A outra tarefa que esta tarefa depende.", + "JsonSchema.tasks.group": "Define a que grupo de execução desta tarefa pertence. Se omitido a tarefa pertence a nenhum grupo.", + "JsonSchema.tasks.type": "Define se a tarefa é executada como um processo ou como um comando dentro de uma shell. O padrão é processo.", + "JsonSchema.version": "O número da versão do config.", + "JsonSchema.tasks.customize": "A tarefa de contribuição a ser customizada.", "JsonSchema.windows": "Configuração de comando específica do Windows", "JsonSchema.mac": "Configuração de comando específica do Mac", "JsonSchema.linux": "Configuração de comando específica do Linux" diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json index a07be4d2850..439c6a386ca 100644 --- a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json @@ -22,7 +22,9 @@ "TaskService.noBuildTask": "Nenhuma tarefa de compilação definida. Marque uma tarefa com 'isBuildCommand' no arquivo tasks.json.", "TaskService.noTestTask": "Nenhuma tarefa de teste definida. Marque uma tarefa com 'isTestCommand' no arquivo tasks.json.", "TaskServer.noTask": "Tarefa {0} requisitada para execução não encontrada.", - "TaskSystem.activeSame": "A tarefa já está ativa e em modo de monitoramento. Para terminar a tarefa, use `F1 > terminar tarefa`", + "customizeParseErrors": "A configuração da tarefa atual tem erros. Por favor, corrija os erros primeiro antes de personalizar uma tarefa.", + "moreThanOneBuildTask": "Há muitas tarefas de compilação definidas em tasks.json. Executando a primeira.\n", + "TaskSystem.activeSame.background": "A tarefa já está ativa e em modo background. Para finalizar a tarefa use 'F1 > terminar tarefa'", "TaskSystem.active": "Já existe uma tarefa sendo executada. Finalize-a antes de executar outra tarefa.", "TaskSystem.restartFailed": "Falha ao finalizar e reiniciar a tarefa {0}", "TaskSystem.configurationErrors": "Erro: A configuração da tarefa informada possui erros de validação e não pode ser utilizada. Por favor, corrija os erros primeiro.", @@ -43,5 +45,7 @@ "TestAction.label": "Executar Tarefa de Teste", "quickOpen.task": "Executar Tarefa", "quickOpen.terminateTask": "Finalizar Tarefa", - "quickOpen.restartTask": "Reiniciar Tarefa" + "quickOpen.restartTask": "Reiniciar Tarefa", + "quickOpen.buildTask": "Tarefa de Compilação", + "quickOpen.testTask": "Tarefa de Teste" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json index f21b7eebc35..1421a156ef7 100644 --- a/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json @@ -6,6 +6,7 @@ { "TerminalTaskSystem.unknownError": "Um erro desconhecido ocorreu durante a execução de uma tarefa. Consulte o log de saída de tarefa para obter detalhes.", "TerminalTaskSystem.terminalName": "Tarefa - {0}", + "reuseTerminal": "Terminal será reutilizado pelas tarefas, pressione qualquer tecla para fechar.", "TerminalTaskSystem": "Não é possível executar um comando shell em uma unidade UNC.", "unkownProblemMatcher": "Problem matcher {0} não pode ser resolvido. O matcher será ignorado" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json index e63bd5db0a0..ca6ab1cb9d9 100644 --- a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json @@ -8,6 +8,7 @@ "workbench.action.terminal.kill": "Finalizar a Instância de Terminal Ativa", "workbench.action.terminal.kill.short": "Encerrar Terminal", "workbench.action.terminal.copySelection": "Copiar Seleção", + "workbench.action.terminal.selectAll": "Selecionar Tudo", "workbench.action.terminal.new": "Criar Novo Terminal Integrado", "workbench.action.terminal.new.short": "Novo Terminal", "workbench.action.terminal.focus": "Focalizar Terminal", @@ -28,5 +29,9 @@ "workbench.action.terminal.scrollToTop": "Rolar para cima", "workbench.action.terminal.clear": "Limpar", "workbench.action.terminal.allowWorkspaceShell": "Permitir a Configuração de Shell da Ãrea de Trabalho", - "workbench.action.terminal.disallowWorkspaceShell": "Não Permitir a Configuração de Shell da Ãrea de Trabalho" + "workbench.action.terminal.disallowWorkspaceShell": "Não Permitir a Configuração de Shell da Ãrea de Trabalho", + "workbench.action.terminal.rename": "Renomear", + "workbench.action.terminal.rename.prompt": "Digite o nome do terminal", + "workbench.action.terminal.focusFindWidget": "Focalizar Ferramenta de Pesquisa", + "workbench.action.terminal.hideFindWidget": "Ocultar Ferramenta de Pesquisa" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json new file mode 100644 index 00000000000..9172767f770 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "label.find": "Localizar", + "placeholder.find": "Localizar", + "label.previousMatchButton": "Correspondência anterior", + "label.nextMatchButton": "Próxima correspondência", + "label.closeButton": "Fechar" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json index 13b6933b1b9..b530cb53e9b 100644 --- a/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json @@ -4,7 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "terminal.integrated.copySelection.noSelection": "Não é possível copiar seleção do terminal quando o terminal não tem foco", + "terminal.integrated.copySelection.noSelection": "O terminal não tem nenhuma seleção para copiar", "terminal.integrated.exitedWithCode": "O processo terminal encerrado com código de saída: {0}", "terminal.integrated.waitOnExit": "Pressione qualquer tecla para fechar o terminal", "terminal.integrated.launchFailed": "O comando de processo de terminal '{0}{1}' falhou ao ser iniciado (código de saída: {2})" diff --git a/i18n/ptb/src/vs/workbench/parts/update/electron-browser/update.i18n.json b/i18n/ptb/src/vs/workbench/parts/update/electron-browser/update.i18n.json index 4199be74572..083249ec7d8 100644 --- a/i18n/ptb/src/vs/workbench/parts/update/electron-browser/update.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/update/electron-browser/update.i18n.json @@ -15,5 +15,18 @@ "license": "Ler Licença", "updateAvailable": "{0} será atualizado após reiniciar.", "thereIsUpdateAvailable": "Há uma atualização disponível.", - "noUpdatesAvailable": "Não há nenhuma atualização disponível." + "noUpdatesAvailable": "Não há nenhuma atualização disponível.", + "updateIsReady": "Nova atualização disponível.", + "commandPalette": "Paleta de comandos...", + "settings": "Configurações", + "keyboardShortcuts": "Atalhos de Teclado", + "selectTheme.label": "Tema de Cores", + "themes.selectIconTheme.label": "Arquivo de Ãcone do Tema", + "not available": "Atualizações Indisponíveis", + "checkingForUpdates": "Verificando Atualizações...", + "DownloadUpdate": "Baixar Atualização Disponível", + "DownloadingUpdate": "Baixando Atualização...", + "InstallingUpdate": "Instalando Atualização...", + "restartToUpdate": "Reinicie para Atualizar...", + "checkForUpdates": "Verificar atualizações..." } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/views/browser/views.i18n.json b/i18n/ptb/src/vs/workbench/parts/views/browser/views.i18n.json new file mode 100644 index 00000000000..32207b28d40 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/views/browser/views.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "viewToolbarAriaLabel": "{0} ações " +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json b/i18n/ptb/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json new file mode 100644 index 00000000000..5128faaa5e4 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "requirearray": "visualizações devem ser uma matriz", + "requirestring": "a propriedade `{0}` é obrigatória e deve ser do tipo `string`", + "optstring": "a propriedade `{0}` é opcional ou deve ser do tipo `string`", + "vscode.extension.contributes.view.id": "Identificador da visualiozação. Use isto para registrar um provedor de dados através de 'vscode.window.registerTreeDataProviderForView' API. Também para acionar ativando sua extensão registrando o evento 'onView: ${id}' para 'activationEvents'.", + "vscode.extension.contributes.view.name": "O nome legível da visualização. Será mostrado", + "vscode.extension.contributes.view.when": "Condição que deve ser verdadeira para mostrar esta visualização", + "vscode.extension.contributes.views": "Contribui visualizações ao editor", + "views.explorer": "Visualização do explorador", + "locationId.invalid": "'{0}' não é um local válido de visualização" +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json index a0b426025a4..d0ecebaf1bf 100644 --- a/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -31,7 +31,6 @@ "welcomePage.colorThemeDescription": "Fazer o editor e seu código parecer do jeito que você gosta", "welcomePage.learn": "Aprender", "welcomePage.showCommands": "Encontrar e executar todos os comandos", - "welcomePage.showCommandsDescription": "Comandos de rápido acesso e de pesquisar do painel de controle ({0})", "welcomePage.interfaceOverview": "Visão geral da interface", "welcomePage.interfaceOverviewDescription": "Obter uma sobreposição visual, destacando os principais componentes da interface do usuário", "welcomePage.interactivePlayground": "Playground interativo", diff --git a/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json b/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json index 7012e078815..450b1aa8f08 100644 --- a/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json @@ -4,7 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "workbenchConfigurationTitle": "Ãrea de Trabalho", - "welcomePage.enabled": "Quando habilitado, irá mostrar a página de boas-vindas na inicialização.", "help": "Ajuda" } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 396a21b1c49..5bd13096e61 100644 --- a/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/ptb/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -4,6 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "workbenchConfigurationTitle": "Ãrea de Trabalho", + "welcomePage.enabled": "Quando habilitado, irá mostrar a página de boas-vindas na inicialização.", "welcomePage": "Bem-vindo", "welcomePage.javaScript": "JavaScript", "welcomePage.typeScript": "TypeScript", @@ -14,16 +16,23 @@ "welcomePage.sublime": "Sublime", "welcomePage.atom": "Atom", "welcomePage.extensionPackAlreadyInstalled": "Suporte para {0} já está instalado.", - "welcomePage.willReloadAfterInstallingExtensionPack": "A janela irá recarregar depois de instalar o suporte para {0}.", - "welcomePage.installingExtensionPack": "Instalar o suporte para {0}...", + "welcomePage.willReloadAfterInstallingExtensionPack": "A janela irá recarregar depois de instalar o suporte adicional para {0}.", + "welcomePage.installingExtensionPack": "Instalando o suporte adicional para {0}...", "welcomePage.extensionPackNotFound": "Suporte para {0} com o id {1} não pôde ser encontrado.", "welcomePage.keymapAlreadyInstalled": "Os atalhos de teclado de {0} já estão instalados.", "welcomePage.willReloadAfterInstallingKeymap": "A janela irá recarregar depois de instalar os {0} atalhos de teclado.", "welcomePage.installingKeymap": "Instalando os {0} atalhos de teclado...", "welcomePage.keymapNotFound": "Os {0} atalhos de teclado com o id {1} não podem ser encontrados.", "welcome.title": "Bem-vindo", + "welcomePage.openFolderWithPath": "Abrir pasta {0} com o caminho {1}", "welcomePage.extensionListSeparator": ", ", - "welcomePage.installedExtension": "{0} (instalado)", + "welcomePage.installKeymap": "Instalar {0} keymap", + "welcomePage.installExtensionPack": "Instalar o suporte adicional para {0}", + "welcomePage.installedKeymap": "Mapeamento de tecla '{0}' já está instalado.", + "welcomePage.installedExtensionPack": "Suporte {0} já está instalado.", "ok": "OK", - "cancel": "Cancelar" + "details": "Detalhes", + "cancel": "Cancelar", + "welcomePage.buttonBackground": "Cor de fundo para os botões na página de boas-vindas.", + "welcomePage.buttonHoverBackground": "Cor de fundo ao passar o mouse sobre os botões na página de boas-vindas." } \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json b/i18n/ptb/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json new file mode 100644 index 00000000000..63fd1d1955d --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "telemetryConfigurationTitle": "Telemetria", + "telemetry.enableCrashReporting": "Ativar o envio de relatórios de incidentes à Microsoft. Esta opção requer reinicialização para ser efetiva." +} \ No newline at end of file diff --git a/i18n/ptb/src/vs/workbench/services/progress/browser/progressService2.i18n.json b/i18n/ptb/src/vs/workbench/services/progress/browser/progressService2.i18n.json new file mode 100644 index 00000000000..6db7d6aae51 --- /dev/null +++ b/i18n/ptb/src/vs/workbench/services/progress/browser/progressService2.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "progress.text": "{0} - {1}", + "progress.title": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/rus/extensions/git/out/commands.i18n.json b/i18n/rus/extensions/git/out/commands.i18n.json index 0e28cfd0b9a..728d6ecc109 100644 --- a/i18n/rus/extensions/git/out/commands.i18n.json +++ b/i18n/rus/extensions/git/out/commands.i18n.json @@ -18,6 +18,7 @@ "discard": "Отменить изменениÑ", "confirm discard all": "Ð’Ñ‹ дейÑтвительно хотите отменить вÑе изменениÑ? Отменить Ñто дейÑтвие нельзÑ!", "discardAll": "Отменить вÑе изменениÑ", + "no staged changes": "ОтÑутÑтвуют промежуточные Ð¸Ð·Ð¼ÐµÐ½ÐµÐ½Ð¸Ñ Ð´Ð»Ñ Ñ„Ð¸ÐºÑации.\n\nÐ’Ñ‹ хотите Ñделать вÑе Ð¸Ð·Ð¼ÐµÐ½ÐµÐ½Ð¸Ñ Ð¿Ñ€Ð¾Ð¼ÐµÐ¶ÑƒÑ‚Ð¾Ñ‡Ð½Ñ‹Ð¼Ð¸ и зафикÑировать их напрÑмую?", "yes": "Да", "always": "Ð’Ñегда", "no changes": "Ðет изменений Ð´Ð»Ñ Ñ„Ð¸ÐºÑации.", @@ -25,6 +26,9 @@ "provide commit message": "Введите Ñообщение фикÑации.", "branch name": "Ð˜Ð¼Ñ Ð²ÐµÑ‚Ð²Ð¸", "provide branch name": "Укажите Ð¸Ð¼Ñ Ð²ÐµÑ‚Ð²Ð¸.", + "select branch to delete": "Выберите ветвь Ð´Ð»Ñ ÑƒÐ´Ð°Ð»ÐµÐ½Ð¸Ñ", + "confirm force delete branch": "Ветвь '{0}' объединена не полноÑтью. Удалить ее?", + "delete branch": "Удалить ветвь", "no remotes to pull": "Ð”Ð»Ñ Ð²Ð°ÑˆÐµÐ³Ð¾ Ñ€ÐµÐ¿Ð¾Ð·Ð¸Ñ‚Ð¾Ñ€Ð¸Ñ Ð½Ðµ наÑтроены удаленные репозитории Ð´Ð»Ñ Ð¿Ð¾Ð»ÑƒÑ‡ÐµÐ½Ð¸Ñ Ð´Ð°Ð½Ð½Ñ‹Ñ….", "no remotes to push": "Ð”Ð»Ñ Ð²Ð°ÑˆÐµÐ³Ð¾ Ñ€ÐµÐ¿Ð¾Ð·Ð¸Ñ‚Ð¾Ñ€Ð¸Ñ Ð½Ðµ наÑтроены удаленные репозитории Ð´Ð»Ñ Ð¾Ñ‚Ð¿Ñ€Ð°Ð²ÐºÐ¸ данных.", "nobranch": "Извлеките ветвь, чтобы передать данные в удаленный репозиторий.", diff --git a/i18n/rus/extensions/git/out/statusbar.i18n.json b/i18n/rus/extensions/git/out/statusbar.i18n.json index e2a1fb358d8..b70a09ca508 100644 --- a/i18n/rus/extensions/git/out/statusbar.i18n.json +++ b/i18n/rus/extensions/git/out/statusbar.i18n.json @@ -6,6 +6,6 @@ { "checkout": "Извлечь...", "sync changes": "Синхронизировать изменениÑ", - "publish changes": "Публиковать изменениÑ", + "publish changes": "Опубликовать изменениÑ", "syncing changes": "Ð¡Ð¸Ð½Ñ…Ñ€Ð¾Ð½Ð¸Ð·Ð°Ñ†Ð¸Ñ Ð¸Ð·Ð¼ÐµÐ½ÐµÐ½Ð¸Ð¹..." } \ No newline at end of file diff --git a/i18n/rus/extensions/git/package.i18n.json b/i18n/rus/extensions/git/package.i18n.json index 5236c98c974..72b1271c65b 100644 --- a/i18n/rus/extensions/git/package.i18n.json +++ b/i18n/rus/extensions/git/package.i18n.json @@ -26,12 +26,13 @@ "command.undoCommit": "Отменить поÑледнюю фикÑацию", "command.checkout": "Извлечь в...", "command.branch": "Создать ветвь...", + "command.deleteBranch": "Удалить ветвь...", "command.pull": "Получить", "command.pullRebase": "Получить (перемеÑтить Ð¸Ð·Ð¼ÐµÐ½ÐµÐ½Ð¸Ñ Ð¸Ð· одной ветви в другую)", "command.push": "Отправить", "command.pushTo": "Отправить в:", "command.sync": "СинхронизациÑ", - "command.publish": "Опубликовать", + "command.publish": "Опубликовать ветвь", "command.showOutput": "Показать выходные данные GIT", "config.enabled": "Включен ли GIT", "config.path": "Путь к иÑполнÑемому файлу GIT", @@ -42,5 +43,7 @@ "config.countBadge": "\nУправлÑет Ñчетчиком Git. При указании Ð·Ð½Ð°Ñ‡ÐµÐ½Ð¸Ñ \"all\" подÑчитываютÑÑ Ð²Ñе изменениÑ, при указании Ð·Ð½Ð°Ñ‡ÐµÐ½Ð¸Ñ \"tracked\" — только отÑлеживаемые изменениÑ, при указании Ð·Ð½Ð°Ñ‡ÐµÐ½Ð¸Ñ \"off\" Ñчетчик отключаетÑÑ.", "config.checkoutType": "ОпределÑет типы ветвей, которые выводÑÑ‚ÑÑ Ð¿Ñ€Ð¸ выборе пункта меню \"Извлечь в...\". При указании Ð·Ð½Ð°Ñ‡ÐµÐ½Ð¸Ñ \"all\" отображаютÑÑ Ð²Ñе ÑÑылки, \"local\" — только локальные ветви, \"tags\" — только теги, а \"remote\" — только удаленные ветви.", "config.ignoreLegacyWarning": "Игнорирует предупреждение об уÑтаревшей верÑии Git", - "config.ignoreLimitWarning": "Игнорировать предупреждение, когда в репозитории Ñлишком много изменений" + "config.ignoreLimitWarning": "Игнорировать предупреждение, когда в репозитории Ñлишком много изменений", + "config.defaultCloneDirectory": "РаÑположение по умолчанию, в которое будет клонирован репозиторий Git", + "config.enableSmartCommit": "ЗафикÑировать вÑе Ð¸Ð·Ð¼ÐµÐ½ÐµÐ½Ð¸Ñ Ð¿Ñ€Ð¸ отÑутÑтвии промежуточных изменений." } \ No newline at end of file diff --git a/i18n/rus/extensions/jake/out/main.i18n.json b/i18n/rus/extensions/jake/out/main.i18n.json index 8b6ad71cd4e..3f8458b5b98 100644 --- a/i18n/rus/extensions/jake/out/main.i18n.json +++ b/i18n/rus/extensions/jake/out/main.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "execFailed": "Сбой автоматичеÑкого определений заданий Jake. Ошибка: {0}" +} \ No newline at end of file diff --git a/i18n/rus/extensions/jake/package.i18n.json b/i18n/rus/extensions/jake/package.i18n.json index 8b6ad71cd4e..57552487f0a 100644 --- a/i18n/rus/extensions/jake/package.i18n.json +++ b/i18n/rus/extensions/jake/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.jake.autoDetect": "Включает или отключает автоматичеÑкое определение заданий Jake. Значение по умолчанию — \"включено\"." +} \ No newline at end of file diff --git a/i18n/rus/extensions/markdown/out/extension.i18n.json b/i18n/rus/extensions/markdown/out/extension.i18n.json index 8b6ad71cd4e..5c5b3690dc6 100644 --- a/i18n/rus/extensions/markdown/out/extension.i18n.json +++ b/i18n/rus/extensions/markdown/out/extension.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "onPreviewStyleLoadError": "Ðе удалоÑÑŒ загрузить 'markdown.styles': {0}" +} \ No newline at end of file diff --git a/i18n/rus/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/rus/extensions/merge-conflict/out/codelensProvider.i18n.json index 8b6ad71cd4e..8b8980ff833 100644 --- a/i18n/rus/extensions/merge-conflict/out/codelensProvider.i18n.json +++ b/i18n/rus/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -3,4 +3,9 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "acceptCurrentChange": "ПринÑÑ‚ÑŒ текущее изменение", + "acceptIncomingChange": "ПринÑÑ‚ÑŒ входÑщее изменение", + "acceptBothChanges": "ПринÑÑ‚ÑŒ оба изменениÑ", + "compareChanges": "Сравнить изменениÑ" +} \ No newline at end of file diff --git a/i18n/rus/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/rus/extensions/merge-conflict/out/commandHandler.i18n.json index 8b6ad71cd4e..8dfda28c735 100644 --- a/i18n/rus/extensions/merge-conflict/out/commandHandler.i18n.json +++ b/i18n/rus/extensions/merge-conflict/out/commandHandler.i18n.json @@ -3,4 +3,10 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "cursorNotInConflict": "КурÑор не находитÑÑ Ð½Ð° конфликте объединениÑ", + "compareChangesTitle": "{0}: текущие Ð¸Ð·Ð¼ÐµÐ½ÐµÐ½Ð¸Ñ âŸ· входÑщие изменениÑ", + "cursorOnSplitterRange": "КурÑор редактора находитÑÑ Ð½Ð° разделителе блока Ð¾Ð±ÑŠÐµÐ´Ð¸Ð½ÐµÐ½Ð¸Ñ ÐºÐ¾Ð½Ñ„Ð»Ð¸ÐºÑ‚Ð¾Ð². ПеремеÑтите его в блок \"Текущее\" или \"ВходÑщее\"", + "noConflicts": "Конфликтов Ð¾Ð±ÑŠÐµÐ´Ð¸Ð½ÐµÐ½Ð¸Ñ Ð² Ñтом файле не обнаружено", + "noOtherConflictsInThisFile": "Других конфликтов Ð¾Ð±ÑŠÐµÐ´Ð¸Ð½ÐµÐ½Ð¸Ñ Ð² Ñтом файле не обнаружено" +} \ No newline at end of file diff --git a/i18n/rus/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/rus/extensions/merge-conflict/out/mergeDecorator.i18n.json index 8b6ad71cd4e..19166bea629 100644 --- a/i18n/rus/extensions/merge-conflict/out/mergeDecorator.i18n.json +++ b/i18n/rus/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -3,4 +3,7 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "currentChange": "(текущее изменение)", + "incomingChange": "(входÑщее изменение)" +} \ No newline at end of file diff --git a/i18n/rus/extensions/merge-conflict/package.i18n.json b/i18n/rus/extensions/merge-conflict/package.i18n.json index 8b6ad71cd4e..209c32b7d11 100644 --- a/i18n/rus/extensions/merge-conflict/package.i18n.json +++ b/i18n/rus/extensions/merge-conflict/package.i18n.json @@ -3,4 +3,18 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "command.category": "Объединить конфликт", + "command.accept.all-incoming": "ПринÑÑ‚ÑŒ вÑе входÑщие", + "command.accept.all-both": "ПринÑÑ‚ÑŒ вÑе входÑщие и текущие", + "command.accept.current": "ПринÑÑ‚ÑŒ текущее", + "command.accept.incoming": "ПринÑÑ‚ÑŒ входÑщее", + "command.accept.selection": "ПринÑÑ‚ÑŒ выделенное", + "command.accept.both": "ПринÑÑ‚ÑŒ оба", + "command.next": "Следующий конфликт", + "command.previous": "Предыдущий конфликт", + "command.compare": "Сравнить текущий конфликт", + "config.title": "Объединить конфликт", + "config.codeLensEnabled": "Включить/отключить блок Ð¾Ð±ÑŠÐµÐ´Ð¸Ð½ÐµÐ½Ð¸Ñ ÐºÐ¾Ð½Ñ„Ð»Ð¸ÐºÑ‚Ð¾Ð² CodeLens в редакторе", + "config.decoratorsEnabled": "Включить/отключить декораторы Ð¾Ð±ÑŠÐµÐ´Ð¸Ð½ÐµÐ½Ð¸Ñ ÐºÐ¾Ð½Ñ„Ð»Ð¸ÐºÑ‚Ð¾Ð² в редакторе" +} \ No newline at end of file diff --git a/i18n/rus/extensions/npm/package.i18n.json b/i18n/rus/extensions/npm/package.i18n.json index 8b6ad71cd4e..48afb646815 100644 --- a/i18n/rus/extensions/npm/package.i18n.json +++ b/i18n/rus/extensions/npm/package.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "config.npm.autoDetect": "Включает или отключает автоматичеÑкое определение Ñценариев npm. Значение по умолчанию — \"включено\"." +} \ No newline at end of file diff --git a/i18n/rus/extensions/typescript/out/features/bufferSyncSupport.i18n.json b/i18n/rus/extensions/typescript/out/features/bufferSyncSupport.i18n.json index 9107be78385..14d34e0b45e 100644 --- a/i18n/rus/extensions/typescript/out/features/bufferSyncSupport.i18n.json +++ b/i18n/rus/extensions/typescript/out/features/bufferSyncSupport.i18n.json @@ -4,7 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "versionMismatch": "Обнаружено неÑоответÑтвие глобального tsc ({0}) и Ñлужбы Ñзыка VS Code ({1}). Это может привеÑти к ошибкам ÑоглаÑованноÑти компилÑции.", "moreInformation": "Дополнительные ÑведениÑ", "doNotCheckAgain": "Больше не проверÑÑ‚ÑŒ", "close": "Закрыть", diff --git a/i18n/rus/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json b/i18n/rus/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json index 8b6ad71cd4e..5c9f3c06ffc 100644 --- a/i18n/rus/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json +++ b/i18n/rus/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "ts-check": "Включает ÑемантичеÑкую проверку в JavaScript файле. Ðеобходимо раÑположить в Ñамом начале файла.", + "ts-nocheck": "Отключает ÑемантичеÑкую проверку в JavaScript файле. Ðеобходимо раÑположить в Ñамом начале файла.", + "ts-ignore": "Отключает вывод ошибок @ts-check Ð´Ð»Ñ Ñледующей Ñтроки файла." +} \ No newline at end of file diff --git a/i18n/rus/extensions/typescript/out/utils/projectStatus.i18n.json b/i18n/rus/extensions/typescript/out/utils/projectStatus.i18n.json index 212caa515a9..436675958f9 100644 --- a/i18n/rus/extensions/typescript/out/utils/projectStatus.i18n.json +++ b/i18n/rus/extensions/typescript/out/utils/projectStatus.i18n.json @@ -6,7 +6,6 @@ { "hintExclude": "Чтобы включить Ñзыковые функции JavaScript/TypeScript IntelliSense во вÑем проекте, иÑключите папки Ñ Ð±Ð¾Ð»ÑŒÑˆÐ¸Ð¼ чиÑлом файлов, например: {0}.", "hintExclude.generic": "Чтобы включить Ñзыковые функции JavaScript/TypeScript IntelliSense во вÑем проекте, иÑключите большие папки Ñ Ð¸Ñходными файлами, Ñ ÐºÐ¾Ñ‚Ð¾Ñ€Ñ‹Ð¼Ð¸ вы не работаете.", - "open": "ÐаÑтройка иÑключений", "large.label": "ÐаÑтройка иÑключений", "hintExclude.tooltip": "Чтобы включить Ñзыковые функции JavaScript/TypeScript IntelliSense во вÑем проекте, иÑключите большие папки Ñ Ð¸Ñходными файлами, Ñ ÐºÐ¾Ñ‚Ð¾Ñ€Ñ‹Ð¼Ð¸ вы не работаете." } \ No newline at end of file diff --git a/i18n/rus/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/rus/extensions/typescript/out/utils/typingsStatus.i18n.json index 506fc2b22fb..8df62bae15b 100644 --- a/i18n/rus/extensions/typescript/out/utils/typingsStatus.i18n.json +++ b/i18n/rus/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "installingPackages": "Получение данных Ð´Ð»Ñ Ð¿Ð¾Ð²Ñ‹ÑˆÐµÐ½Ð¸Ñ ÑффективноÑти IntelliSense TypeScript", + "typesInstallerInitializationFailed.title": "Ðе удалоÑÑŒ уÑтановить файлы типизации Ð´Ð»Ñ Ñзыка JavaScript. УбедитеÑÑŒ, что NPM уÑтановлен или укажите путь к файлу 'typescript.npm' в параметрах Ñреды пользователÑ", "typesInstallerInitializationFailed.moreInformation": "Дополнительные ÑведениÑ", "typesInstallerInitializationFailed.doNotCheckAgain": "Больше не проверÑÑ‚ÑŒ", "typesInstallerInitializationFailed.close": "Закрыть" diff --git a/i18n/rus/extensions/typescript/package.i18n.json b/i18n/rus/extensions/typescript/package.i18n.json index 879f5909ede..ac2e8ab343a 100644 --- a/i18n/rus/extensions/typescript/package.i18n.json +++ b/i18n/rus/extensions/typescript/package.i18n.json @@ -13,7 +13,6 @@ "typescript.check.tscVersion": "Проверка Ð¾Ñ‚Ð»Ð¸Ñ‡Ð¸Ñ ÐºÐ¾Ð¼Ð¿Ð¸Ð»Ñтора TypeScript глобальной уÑтановки (например, tsc) от иÑпользуемой Ñзыковой Ñлужбы TypeScript.", "typescript.tsserver.log": "Включает ведение журнала Ð´Ð»Ñ Ñервера TS. Этот журнал можно иÑпользовать Ð´Ð»Ñ Ð´Ð¸Ð°Ð³Ð½Ð¾Ñтики проблем Ñервера TS. Ð’ журнале могут ÑодержатьÑÑ Ð¿ÑƒÑ‚Ð¸ к файлам, иÑходный код и другие ÑÐ²ÐµÐ´ÐµÐ½Ð¸Ñ Ð¸Ð· вашего проекта, в том чиÑле ноÑÑщие конфиденциальный характер.", "typescript.tsserver.trace": "Включает траÑÑировку Ñообщений, отправлÑемых на Ñервер TS. Эту траÑÑировку можно иÑпользовать Ð´Ð»Ñ Ð´Ð¸Ð°Ð³Ð½Ð¾Ñтики проблем Ñервера TS. ТраÑÑировка может Ñодержать пути к файлам, иÑходный код и другие ÑÐ²ÐµÐ´ÐµÐ½Ð¸Ñ Ð¸Ð· вашего проекта, в том чиÑле конфиденциальные данные.", - "typescript.tsserver.experimentalAutoBuild": "Включает ÑкÑпериментальную автоÑборку. ТребуетÑÑ Ð²ÐµÑ€ÑиÑ 1.9 dev или верÑиÑ 2.x tsserver и перезапуÑк VS Code поÑле изменениÑ.", "typescript.validate.enable": "Включение или отключение проверки TypeScript.", "typescript.format.enable": "Включение или отключение Ð¼Ð¾Ð´ÑƒÐ»Ñ Ñ„Ð¾Ñ€Ð¼Ð°Ñ‚Ð¸Ñ€Ð¾Ð²Ð°Ð½Ð¸Ñ TypeScript по умолчанию.", "javascript.format.enable": "Включение или отключение Ð¼Ð¾Ð´ÑƒÐ»Ñ Ñ„Ð¾Ñ€Ð¼Ð°Ñ‚Ð¸Ñ€Ð¾Ð²Ð°Ð½Ð¸Ñ JavaScript по умолчанию.", @@ -33,8 +32,16 @@ "javascript.validate.enable": "Включение или отключение проверки JavaScript.", "typescript.goToProjectConfig.title": "Перейти к конфигурации проекта", "javascript.goToProjectConfig.title": "Перейти к конфигурации проекта", + "javascript.referencesCodeLens.enabled": "Включить/отключить ÑÑылки CodeLens Ð´Ð»Ñ Ñ„Ð°Ð¹Ð»Ð¾Ð² JavaScript.", + "typescript.referencesCodeLens.enabled": "Включить/отключить ÑÑылки CodeLens Ð´Ð»Ñ Ñ„Ð°Ð¹Ð»Ð¾Ð² TypeScript. ТребуетÑÑ TypeScript верÑии 2.0.6 или более поздней верÑии.", "typescript.implementationsCodeLens.enabled": "Включить или отключить CodeLens Ð´Ð»Ñ Ñ€ÐµÐ°Ð»Ð¸Ð·Ð°Ñ†Ð¸Ð¹. ТребуетÑÑ TypeScript >= 2.2.0.", + "typescript.openTsServerLog.title": "Открыть журнал Ñервера TS", + "typescript.restartTsServer": "ПерезапуÑтить Ñервер TS", "typescript.selectTypeScriptVersion.title": "Выберите верÑию TypeScript.", "jsDocCompletion.enabled": "Включить или отключить JSDoc коментарии", - "javascript.implicitProjectConfig.checkJs": "Включает/отключает ÑемантичеÑкую проверку файлов JavaScript. Этот параметр может переопределÑÑ‚ÑŒÑÑ Ð² файле jsconfig.json или tsconfig.json. ТребуетÑÑ TypeScript 2.3.1 или более поздней верÑии." + "javascript.implicitProjectConfig.checkJs": "Включает/отключает ÑемантичеÑкую проверку файлов JavaScript. Этот параметр может переопределÑÑ‚ÑŒÑÑ Ð² файле jsconfig.json или tsconfig.json. ТребуетÑÑ TypeScript 2.3.1 или более поздней верÑии.", + "typescript.npm": "Указывает путь к иÑполнÑемому файлу NPM, иÑпользуемому Ð´Ð»Ñ Ð°Ð²Ñ‚Ð¾Ð¼Ð°Ñ‚Ð¸Ñ‡ÐµÑкого Ð¿Ð¾Ð»ÑƒÑ‡ÐµÐ½Ð¸Ñ Ñ‚Ð¸Ð¿Ð°. ТребуетÑÑ TypeScript верÑии 2.3.4 или более поздней верÑии.", + "typescript.check.npmIsInstalled": "ПроверÑет, уÑтановлен ли NPM Ð´Ð»Ñ Ð°Ð²Ñ‚Ð¾Ð¼Ð°Ñ‚Ð¸Ñ‡ÐµÑкого Ð¿Ð¾Ð»ÑƒÑ‡ÐµÐ½Ð¸Ñ Ñ‚Ð¸Ð¿Ð¾Ð².", + "javascript.nameSuggestions": "Включить/отключить иÑпользование уникальных имен из файла в ÑпиÑках предложений JavaScript.", + "typescript.tsc.autoDetect": "Включает или отключает автоматичеÑкое определние заданий tsc." } \ No newline at end of file diff --git a/i18n/rus/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/rus/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json index 32fb4e4b4cd..3ef6f2cac9f 100644 --- a/i18n/rus/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json +++ b/i18n/rus/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -6,6 +6,7 @@ { "imgMeta": "{0}x{1} {2}", "largeImageError": "Изображение Ñлишком велико Ð´Ð»Ñ Ð¾Ñ‚Ð¾Ð±Ñ€Ð°Ð¶ÐµÐ½Ð¸Ñ Ð² редакторе. ", + "resourceOpenExternalButton": "Открыть изображение Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ внешней программы?", "nativeBinaryError": "Файл не будет отображен в редакторе, так как он двоичный, очень большой или иÑпользует неподдерживаемую кодировку текÑта.", "sizeB": "{0} Б", "sizeKB": "{0} КБ", diff --git a/i18n/rus/src/vs/base/common/errorMessage.i18n.json b/i18n/rus/src/vs/base/common/errorMessage.i18n.json index d3403f4afa5..b1ef2e3999b 100644 --- a/i18n/rus/src/vs/base/common/errorMessage.i18n.json +++ b/i18n/rus/src/vs/base/common/errorMessage.i18n.json @@ -13,6 +13,5 @@ "error.connection.unknown": "Произошла неизвеÑÑ‚Ð½Ð°Ñ Ð¾ÑˆÐ¸Ð±ÐºÐ° подключениÑ. УтерÑно подключение к Интернету, либо Ñервер, к которому вы подключены, перешел в автономный режим.", "stackTrace.format": "{0}: {1}", "error.defaultMessage": "Произошла неизвеÑÑ‚Ð½Ð°Ñ Ð¾ÑˆÐ¸Ð±ÐºÐ°. Подробные ÑÐ²ÐµÐ´ÐµÐ½Ð¸Ñ Ñм. в журнале.", - "nodeExceptionMessage": "Произошла ÑиÑÑ‚ÐµÐ¼Ð½Ð°Ñ Ð¾ÑˆÐ¸Ð±ÐºÐ° ({0})", "error.moreErrors": "{0} (вÑего ошибок: {1})" } \ No newline at end of file diff --git a/i18n/rus/src/vs/base/common/keybindingLabels.i18n.json b/i18n/rus/src/vs/base/common/keybindingLabels.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/rus/src/vs/base/common/keybindingLabels.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/rus/src/vs/code/electron-main/menus.i18n.json b/i18n/rus/src/vs/code/electron-main/menus.i18n.json index edcee11b1f1..ac53c20ecc2 100644 --- a/i18n/rus/src/vs/code/electron-main/menus.i18n.json +++ b/i18n/rus/src/vs/code/electron-main/menus.i18n.json @@ -55,6 +55,9 @@ "miShowEmmetCommands": "E&&mmet...", "miToggleLineComment": "Переключить комментарий &&Ñтроки", "miToggleBlockComment": "Переключить комментарий &&блока", + "miMultiCursorAlt": "Ð”Ð»Ñ Ñ€Ð°Ð±Ð¾Ñ‚Ñ‹ в режиме неÑкольких курÑоров нажмите левую кнопку мыши, ÑƒÐ´ÐµÑ€Ð¶Ð¸Ð²Ð°Ñ ÐºÐ»Ð°Ð²Ð¸ÑˆÑƒ ALT", + "miMultiCursorCmd": "Ð”Ð»Ñ Ñ€Ð°Ð±Ð¾Ñ‚Ñ‹ в режиме неÑкольких курÑоров нажмите левую кнопку мыши, нажав клавишу COMMAND", + "miMultiCursorCtrl": "Ð”Ð»Ñ Ñ€Ð°Ð±Ð¾Ñ‚Ñ‹ в режиме неÑкольких курÑоров нажмите левую кнопку мыши, нажав клавишу CTRL", "miInsertCursorAbove": "Добавить курÑор &&выше", "miInsertCursorBelow": "Добавить курÑор &&ниже", "miInsertCursorAtEndOfEachLineSelected": "Добавить курÑоры в &&Ð¾ÐºÐ¾Ð½Ñ‡Ð°Ð½Ð¸Ñ Ñтрок", @@ -115,6 +118,8 @@ "miGotoSymbolInFile": "Перейти к &&Ñимволу в файле...", "miGotoSymbolInWorkspace": "Перейти к Ñимволу в &&рабочей облаÑти...", "miGotoDefinition": "Перейти к &&определению", + "miGotoTypeDefinition": "Перейти к &&определению типа", + "miGotoImplementation": "Перейти к &&реализации", "miGotoLine": "Перейти к &&Ñтроке...", "miStartDebugging": "&&ЗапуÑтить отладку", "miStartWithoutDebugging": "Ðачать &&без отладки", @@ -131,16 +136,17 @@ "miColumnBreakpoint": "Т&&очка оÑтанова Ñтолбца", "miFunctionBreakpoint": "&&Точка оÑтанова функции...", "miNewBreakpoint": "&&ÐÐ¾Ð²Ð°Ñ Ñ‚Ð¾Ñ‡ÐºÐ° оÑтанова", + "miEnableAllBreakpoints": "Включить вÑе точки оÑтанова", "miDisableAllBreakpoints": "Отключить &&вÑе точки оÑтанова", "miRemoveAllBreakpoints": "&&Удалить &&вÑе точки оÑтанова", "miInstallAdditionalDebuggers": "У&&Ñтановить дополнительные отладчики...", "mMinimize": "Свернуть", - "mClose": "Закрыть", "mBringToFront": "ПеремеÑтить вÑе на передний план", "miToggleDevTools": "&&Показать/Ñкрыть ÑредÑтва разработчика", "miAccessibilityOptions": "Специальные &&возможноÑти", "miReportIssues": "&&Сообщить о проблемах", "miWelcome": "&&ПриветÑтвие", + "miInteractivePlayground": "&&Ð˜Ð½Ñ‚ÐµÑ€Ð°ÐºÑ‚Ð¸Ð²Ð½Ð°Ñ Ð¿Ð»Ð¾Ñ‰Ð°Ð´ÐºÐ°", "miDocumentation": "&&ДокументациÑ", "miReleaseNotes": "&&Заметки о выпуÑке", "miKeyboardShortcuts": "С&&правочник по ÑочетаниÑм клавиш", @@ -150,12 +156,14 @@ "miLicense": "ПроÑмотреть &&лицензию", "miPrivacyStatement": "&&ЗаÑвление о конфиденциальноÑти", "miAbout": "&&О программе", + "miTerminateTask": "&&Завершить задачу", "accessibilityOptionsWindowTitle": "Специальные возможноÑти", "miRestartToUpdate": "ПерезапуÑтить Ð´Ð»Ñ Ð¾Ð±Ð½Ð¾Ð²Ð»ÐµÐ½Ð¸Ñ...", "miCheckingForUpdates": "Идет проверка Ð½Ð°Ð»Ð¸Ñ‡Ð¸Ñ Ð¾Ð±Ð½Ð¾Ð²Ð»ÐµÐ½Ð¸Ð¹...", "miDownloadUpdate": "Скачать доÑтупное обновление", "miDownloadingUpdate": "СкачиваетÑÑ Ð¾Ð±Ð½Ð¾Ð²Ð»ÐµÐ½Ð¸Ðµ...", "miInstallingUpdate": "Идет уÑтановка обновлениÑ...", + "miCheckForUpdates": "Проверить наличие обновлений...", "aboutDetail": "\nВерÑÐ¸Ñ {0}\nФикÑÐ°Ñ†Ð¸Ñ {1}\nДата {2}\nОболочка {3}\nОбработчик {4}\nNode {5}", "okButton": "ОК" } \ No newline at end of file diff --git a/i18n/rus/src/vs/code/electron-main/windows.i18n.json b/i18n/rus/src/vs/code/electron-main/windows.i18n.json index b1934cff062..22509376e04 100644 --- a/i18n/rus/src/vs/code/electron-main/windows.i18n.json +++ b/i18n/rus/src/vs/code/electron-main/windows.i18n.json @@ -13,9 +13,5 @@ "appStalled": "Окно не отвечает", "appStalledDetail": "Ð’Ñ‹ можете повторно открыть окно, закрыть его или продолжить ожидание.", "appCrashed": "Сбой окна", - "appCrashedDetail": "ПриноÑим Ð¸Ð·Ð²Ð¸Ð½ÐµÐ½Ð¸Ñ Ð·Ð° неудобÑтво! Ð’Ñ‹ можете повторно открыть окно, чтобы продолжить работу Ñ Ñ‚Ð¾Ð³Ð¾ меÑта, на котором оÑтановилиÑÑŒ.", - "newWindow": "Ðовое окно", - "newWindowDesc": "Открывает новое окно", - "recentFolders": "Ðедавно иÑпользованные папки", - "folderDesc": "{0} {1}" + "appCrashedDetail": "ПриноÑим Ð¸Ð·Ð²Ð¸Ð½ÐµÐ½Ð¸Ñ Ð·Ð° неудобÑтво! Ð’Ñ‹ можете повторно открыть окно, чтобы продолжить работу Ñ Ñ‚Ð¾Ð³Ð¾ меÑта, на котором оÑтановилиÑÑŒ." } \ No newline at end of file diff --git a/i18n/rus/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/rus/src/vs/editor/common/config/commonEditorConfig.i18n.json index 53078d0a5b6..64c88138d02 100644 --- a/i18n/rus/src/vs/editor/common/config/commonEditorConfig.i18n.json +++ b/i18n/rus/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -9,6 +9,7 @@ "fontWeight": "УправлÑет наÑыщенноÑтью шрифта.", "fontSize": "УправлÑет размером шрифта в пикÑелÑÑ….", "lineHeight": "УправлÑет выÑотой Ñтрок. Укажите 0 Ð´Ð»Ñ Ð²Ñ‹Ñ‡Ð¸ÑÐ»ÐµÐ½Ð¸Ñ Ð²Ñ‹Ñоты Ñтроки по размеру шрифта.", + "letterSpacing": "УправлÑет интервалом между буквами в пикÑелÑÑ….", "lineNumbers": "УправлÑет видимоÑтью номеров Ñтрок. Возможные значениÑ: \"on\", \"off\" и \"relative\". Значение \"relative\" показывает количеÑтво Ñтрок, Ð½Ð°Ñ‡Ð¸Ð½Ð°Ñ Ñ Ñ‚ÐµÐºÑƒÑ‰ÐµÐ³Ð¾ Ð¿Ð¾Ð»Ð¾Ð¶ÐµÐ½Ð¸Ñ ÐºÑƒÑ€Ñора.", "rulers": "Столбцы, в которых должны отображатьÑÑ Ð²ÐµÑ€Ñ‚Ð¸ÐºÐ°Ð»ÑŒÐ½Ñ‹Ðµ линейки", "wordSeparators": "Символы, которые будут иÑпользоватьÑÑ ÐºÐ°Ðº разделители Ñлов при выполнении навигации или других операций, ÑвÑзанных Ñо Ñловами.", @@ -22,6 +23,8 @@ "minimap.enabled": "ОпределÑет, отображаетÑÑ Ð»Ð¸ мини-карта", "minimap.renderCharacters": "Отображает фактичеÑкие Ñимволы в Ñтроке вмеÑто цветных блоков.", "minimap.maxColumn": "Ограничивает ширину мини-карты Ð´Ð»Ñ Ð¾Ñ‚Ð¾Ð±Ñ€Ð°Ð¶ÐµÐ½Ð¸Ñ Ñ‡Ð¸Ñла Ñтолбцов не больше определенного.", + "find.seedSearchStringFromSelection": "ОпределÑет, можно ли передать Ñтроку поиÑка в мини-приложение поиÑка из текÑта, выделенного в редакторе", + "find.autoFindInSelection": "ОпределÑет, будет ли ÑнÑÑ‚ флажок \"ПоиÑк в выделенном\", когда в редакторе выбрано неÑколько Ñимволов или Ñтрок текÑта", "wordWrap.off": "Строки не будут переноÑитьÑÑ Ð½Ð¸ÐºÐ¾Ð³Ð´Ð°.", "wordWrap.on": "Строки будут переноÑитьÑÑ Ð¿Ð¾ ширине окна проÑмотра.", "wordWrap.wordWrapColumn": "Строки будут переноÑитьÑÑ Ð¿Ð¾ \"editor.wordWrapColumn\".", @@ -30,16 +33,19 @@ "wordWrapColumn": "ОпределÑет Ñтолбец переноÑа редактора, еÑли значение \"editor.wordWrap\" — \"wordWrapColumn\" или \"bounded\".", "wrappingIndent": "УправлÑет отÑтупом Ñтрок Ñ Ð¿ÐµÑ€ÐµÐ½Ð¾Ñом по Ñловам. ДопуÑтимые значениÑ: \"none\", \"same\" или \"indent\".", "mouseWheelScrollSensitivity": "Множитель, иÑпользуемый Ð´Ð»Ñ Ð¿Ð°Ñ€Ð°Ð¼ÐµÑ‚Ñ€Ð¾Ð² deltaX и deltaY Ñобытий прокрутки колеÑика мыши.", + "multiCursorModifier.ctrlCmd": "СоответÑтвует клавише CTRL в Windows и Linux и клавише COMMAND в OS X.", + "multiCursorModifier.alt": "СоответÑтвует клавише ALT в Windows и Linux и клавише OPTION в OS X.", + "multiCursorModifier": "Модификатор, который будет иÑпользоватьÑÑ Ð´Ð»Ñ Ð´Ð¾Ð±Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ð½ÐµÑкольких курÑоров Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ мыши. \"ctrlCmd\" ÑоответÑтвует клавише CTRL в Windows и Linux и клавише COMMAND в OS X. ЖеÑÑ‚Ñ‹ мыши \"Перейти к определению\" и \"Открыть ÑÑылку\" будут изменены так, чтобы они не конфликтовали Ñ Ð½ÐµÑколькими курÑорами.", "quickSuggestions.strings": "Разрешение кратких предложений в Ñтроках.", "quickSuggestions.comments": "Разрешение кратких предложений в комментариÑÑ….", "quickSuggestions.other": "Разрешение кратких предложений вне Ñтрок и комментариев.", "quickSuggestions": "ОпределÑет, должны ли при вводе текÑта автоматичеÑки отображатьÑÑ Ð¿Ñ€ÐµÐ´Ð»Ð¾Ð¶ÐµÐ½Ð¸Ñ", "quickSuggestionsDelay": "УправлÑет длительноÑтью задержки (в мÑ), перед отображением кратких предложений.", - "parameterHints": "Включение подÑказок Ð´Ð»Ñ Ð¿Ð°Ñ€Ð°Ð¼ÐµÑ‚Ñ€Ð¾Ð²", "autoClosingBrackets": "ОпределÑет, должен ли редактор автоматичеÑки закрывать Ñкобки поÑле открытиÑ.", "formatOnType": "УправлÑет параметром, определÑющим, должен ли редактор автоматичеÑки форматировать Ñтроку поÑле ввода.", "formatOnPaste": "ОпределÑет, будет ли редактор автоматичеÑки форматировать вÑтавленное Ñодержимое. Модуль Ñ„Ð¾Ñ€Ð¼Ð°Ñ‚Ð¸Ñ€Ð¾Ð²Ð°Ð½Ð¸Ñ Ð´Ð¾Ð»Ð¶ÐµÐ½ быть доÑтупен и иметь возможноÑÑ‚ÑŒ форматировать диапазон в документе.", "suggestOnTriggerCharacters": "ОпределÑет, должны ли при вводе триггерных Ñимволов автоматичеÑки отображатьÑÑ Ð¿Ñ€ÐµÐ´Ð»Ð¾Ð¶ÐµÐ½Ð¸Ñ.", + "acceptSuggestionOnEnter": "ОпределÑет, будут ли Ð¿Ñ€ÐµÐ´Ð»Ð¾Ð¶ÐµÐ½Ð¸Ñ Ð¿Ñ€Ð¸Ð½Ð¸Ð¼Ð°Ñ‚ÑŒÑÑ ÐºÐ»Ð°Ð²Ð¸ÑˆÐµÐ¹ ВВОД в дополнение к клавише TAB. Это помогает избежать неоднозначноÑти между вÑтавкой новых Ñтрок и принÑтием предложений. Значение \"smart\" означает, что при изменении текÑта Ð¿Ñ€ÐµÐ´Ð»Ð¾Ð¶ÐµÐ½Ð¸Ñ Ð±ÑƒÐ´ÑƒÑ‚ приниматьÑÑ Ñ‚Ð¾Ð»ÑŒÐºÐ¾ при нажатии клавиши ВВОД.", "acceptSuggestionOnCommitCharacter": "ОпределÑет, будут ли Ð¿Ñ€ÐµÐ´Ð»Ð¾Ð¶ÐµÐ½Ð¸Ñ Ð¿Ñ€Ð¸Ð½Ð¸Ð¼Ð°Ñ‚ÑŒÑÑ Ñимволами фикÑации. Ðапример, в JavaScript точка Ñ Ð·Ð°Ð¿Ñтой (\";\") может быть Ñимволом фикÑации, принимающим предложение и вводÑщим данный Ñимвол.", "snippetSuggestions": "УправлÑет отображением фрагментов вмеÑте Ñ Ð´Ñ€ÑƒÐ³Ð¸Ð¼Ð¸ предложениÑми и их Ñортировкой.", "emptySelectionClipboard": "УправлÑет тем, копируетÑÑ Ð»Ð¸ Ñ‚ÐµÐºÑƒÑ‰Ð°Ñ Ñтрока при копировании без выделениÑ.", @@ -61,12 +67,17 @@ "renderLineHighlight": "ОпределÑет, должен ли редактор выделÑÑ‚ÑŒ текущую Ñтроку. Возможные значениÑ: none, gutter, line и all.", "codeLens": "УправлÑет показом групп ÑвÑзанных Ñлементов кода в редакторе", "folding": "ОпределÑет, включено ли Ñворачивание кода в редакторе.", + "showFoldingControls": "ОпределÑет, будут ли автоматичеÑки ÑкрыватьÑÑ Ñлементы ÑƒÐ¿Ñ€Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ñвертыванием на полÑÑ….", "matchBrackets": "ВыделÑет ÑоответÑтвующие Ñкобки при выборе одной из них.", "glyphMargin": "УправлÑет отображением вертикальных полей глифа в редакторе. ÐŸÐ¾Ð»Ñ Ð³Ð»Ð¸Ñ„Ð° в оÑновном иÑпользуютÑÑ Ð´Ð»Ñ Ð¾Ñ‚Ð»Ð°Ð´ÐºÐ¸.", "useTabStops": "Ð’Ñтавка и удаление пробелов поÑле позиции табулÑции", "trimAutoWhitespace": "Удалить автоматичеÑки вÑтавлÑемый конечный пробел", "stablePeek": "ОÑтавлÑÑ‚ÑŒ быÑтрые редакторы открытыми, даже еÑли дважды щелкнуто их Ñодержимое или нажата клавиша ESC.", "dragAndDrop": "ОпределÑет, Ñледует ли редактору разрешить перемещение выделенных Ñлементов Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ перетаÑкиваниÑ.", + "accessibilitySupport.auto": "Редактор будет определÑÑ‚ÑŒ, подключено ли ÑредÑтво Ñ‡Ñ‚ÐµÐ½Ð¸Ñ Ñ Ñкрана, Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ API-интерфейÑов платформы.", + "accessibilitySupport.on": "Редактор будет оптимизирован Ð´Ð»Ñ Ð¸ÑÐ¿Ð¾Ð»ÑŒÐ·Ð¾Ð²Ð°Ð½Ð¸Ñ Ñо ÑредÑтвом Ñ‡Ñ‚ÐµÐ½Ð¸Ñ Ñ Ñкрана в поÑтоÑнном режиме.", + "accessibilitySupport.off": "Редактор никогда не будет оптимизироватьÑÑ Ð´Ð»Ñ Ð¸ÑÐ¿Ð¾Ð»ÑŒÐ·Ð¾Ð²Ð°Ð½Ð¸Ñ Ñо ÑредÑтвом Ñ‡Ñ‚ÐµÐ½Ð¸Ñ Ñ Ñкрана.", + "accessibilitySupport": "ОпределÑет, Ñледует ли запуÑтить редактор в режиме оптимизации Ð´Ð»Ñ ÑредÑтва Ñ‡Ñ‚ÐµÐ½Ð¸Ñ Ñ Ñкрана.", "sideBySide": "ОпределÑет, как редактор неÑовпадений отображает отличиÑ: Ñ€Ñдом или в текÑте.", "ignoreTrimWhitespace": "ОпределÑет, должен ли редактор неÑовпадений трактовать неÑÐ¾Ð²Ð¿Ð°Ð´ÐµÐ½Ð¸Ñ Ñимволов-разделителей как различиÑ.", "renderIndicators": "ОпределÑет отображение редактором неÑовпадений индикаторов +/- Ð´Ð»Ñ Ð´Ð¾Ð±Ð°Ð²Ð»ÐµÐ½Ð½Ñ‹Ñ… или удаленных изменений", diff --git a/i18n/rus/src/vs/editor/common/config/editorOptions.i18n.json b/i18n/rus/src/vs/editor/common/config/editorOptions.i18n.json index 90b3992a47d..38312a5dea7 100644 --- a/i18n/rus/src/vs/editor/common/config/editorOptions.i18n.json +++ b/i18n/rus/src/vs/editor/common/config/editorOptions.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "accessibilityOffAriaLabel": "Редактор ÑÐµÐ¹Ñ‡Ð°Ñ Ð½ÐµÐ´Ð¾Ñтупен. Чтобы открыть ÑпиÑок дейÑтвий, нажмите ALT+F1.", "editorViewAccessibleLabel": "Содержимое редактора" } \ No newline at end of file diff --git a/i18n/rus/src/vs/editor/common/view/editorColorRegistry.i18n.json b/i18n/rus/src/vs/editor/common/view/editorColorRegistry.i18n.json index 84955b080fe..0292dc310ce 100644 --- a/i18n/rus/src/vs/editor/common/view/editorColorRegistry.i18n.json +++ b/i18n/rus/src/vs/editor/common/view/editorColorRegistry.i18n.json @@ -10,5 +10,15 @@ "caret": "Цвет курÑора редактора.", "editorWhitespaces": "Цвет пробелов в редакторе.", "editorIndentGuides": "Цвет направлÑющих Ð´Ð»Ñ Ð¾Ñ‚Ñтупов редактора.", - "editorLineNumbers": "Цвет номеров Ñтрок редактора." + "editorLineNumbers": "Цвет номеров Ñтрок редактора.", + "editorRuler": "Цвет линейки редактора.", + "editorCodeLensForeground": "Цвет переднего плана Ñлемента CodeLens в редакторе", + "editorBracketMatchBackground": "Цвет фона парных Ñкобок", + "editorBracketMatchBorder": "Цвет прÑмоугольников парных Ñкобок", + "editorOverviewRulerBorder": "Цвет границы Ð´Ð»Ñ Ð»Ð¸Ð½ÐµÐ¹ÐºÐ¸ в окне проÑмотра.", + "editorGutter": "Цвет фона Ð¿Ð¾Ð»Ñ Ð² редакторе. Ð’ поле размещаютÑÑ Ð¾Ñ‚Ñтупы глифов и номера Ñтрок.", + "errorForeground": "Цвет волниÑтой линии Ð´Ð»Ñ Ð²Ñ‹Ð´ÐµÐ»ÐµÐ½Ð¸Ñ Ð¾ÑˆÐ¸Ð±Ð¾Ðº в редакторе.", + "errorBorder": "Цвет границ волниÑтой линии Ð´Ð»Ñ Ð²Ñ‹Ð´ÐµÐ»ÐµÐ½Ð¸Ñ Ð¾ÑˆÐ¸Ð±Ð¾Ðº в редакторе.", + "warningForeground": "Цвет волниÑтой линии Ð´Ð»Ñ Ð²Ñ‹Ð´ÐµÐ»ÐµÐ½Ð¸Ñ Ð¿Ñ€ÐµÐ´ÑƒÐ¿Ñ€ÐµÐ¶Ð´ÐµÐ½Ð¸Ð¹ в редакторе.", + "warningBorder": "Цвет границ волниÑтой линии Ð´Ð»Ñ Ð²Ñ‹Ð´ÐµÐ»ÐµÐ½Ð¸Ñ Ð¿Ñ€ÐµÐ´ÑƒÐ¿Ñ€ÐµÐ¶Ð´ÐµÐ½Ð¸Ð¹ в редакторе." } \ No newline at end of file diff --git a/i18n/rus/src/vs/editor/contrib/find/common/findController.i18n.json b/i18n/rus/src/vs/editor/contrib/find/common/findController.i18n.json index 69fbb81b34d..d6bc631d96b 100644 --- a/i18n/rus/src/vs/editor/contrib/find/common/findController.i18n.json +++ b/i18n/rus/src/vs/editor/contrib/find/common/findController.i18n.json @@ -14,6 +14,5 @@ "addSelectionToPreviousFindMatch": "Добавить выделенный фрагмент в предыдущее найденное Ñовпадение", "moveSelectionToNextFindMatch": "ПеремеÑтить поÑледнее выделение в Ñледующее найденное Ñовпадение", "moveSelectionToPreviousFindMatch": "ПеремеÑтить поÑледний выделенный фрагмент в предыдущее найденное Ñовпадение", - "selectAllOccurencesOfFindMatch": "Выбрать вÑе Ð²Ñ…Ð¾Ð¶Ð´ÐµÐ½Ð¸Ñ Ð½Ð°Ð¹Ð´ÐµÐ½Ð½Ñ‹Ñ… Ñовпадений", "changeAll.label": "Изменить вÑе вхождениÑ" } \ No newline at end of file diff --git a/i18n/rus/src/vs/editor/contrib/links/browser/links.i18n.json b/i18n/rus/src/vs/editor/contrib/links/browser/links.i18n.json index c2c9343c9c5..9260a3d4367 100644 --- a/i18n/rus/src/vs/editor/contrib/links/browser/links.i18n.json +++ b/i18n/rus/src/vs/editor/contrib/links/browser/links.i18n.json @@ -6,6 +6,7 @@ { "links.navigate.mac": "Щелкните Ñ Ð½Ð°Ð¶Ð°Ñ‚Ð¾Ð¹ клавишей Cmd, чтобы перейти по ÑÑылке", "links.navigate": "Щелкните Ñ Ð½Ð°Ð¶Ð°Ñ‚Ð¾Ð¹ клавишей Ctrl, чтобы перейти по ÑÑылке", + "links.navigate.al": "Щелкните Ñ Ð½Ð°Ð¶Ð°Ñ‚Ð¾Ð¹ клавишей ALT, чтобы перейти по ÑÑылке.", "invalid.url": "Ðе удалоÑÑŒ открыть ÑÑылку, так как она имеет неправильный формат: {0}", "missing.url": "Ðе удалоÑÑŒ открыть ÑÑылку, у нее отÑутÑтвует целевой объект.", "label": "Открыть ÑÑылку" diff --git a/i18n/rus/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json b/i18n/rus/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json index cbed271e423..95c9ccbe774 100644 --- a/i18n/rus/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json +++ b/i18n/rus/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json @@ -5,8 +5,6 @@ // Do not edit this file. It is machine generated. { "aria.oneReference": "ÑÑылка в {0} в Ñтроке {1} и Ñимволе {2}", - "aria.fileReferences.1": "Обнаружен 1 Ñимвол в {0}", - "aria.fileReferences.N": "{0} Ñимволов в {1}", "aria.result.0": "Результаты не найдены", "aria.result.1": "Обнаружен 1 Ñимвол в {0}", "aria.result.n1": "Обнаружено {0} Ñимволов в {1}", diff --git a/i18n/rus/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json b/i18n/rus/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json index 222d24b8288..9b523c27fc1 100644 --- a/i18n/rus/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json +++ b/i18n/rus/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json @@ -16,9 +16,12 @@ "peekViewTitleInfoForeground": "Цвет Ñведений о заголовке быÑтрого редактора.", "peekViewBorder": "Цвет границ быÑтрого редактора и маÑÑива.", "peekViewResultsBackground": "Цвет фона в ÑпиÑке результатов предÑÑ‚Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ð±Ñ‹Ñтрого редактора.", + "peekViewResultsMatchForeground": "Цвет переднего плана узлов Ñтроки в ÑпиÑке результатов быÑтрого редактора.", + "peekViewResultsFileForeground": "Цвет переднего плана узлов файла в ÑпиÑке результатов быÑтрого редактора.", "peekViewResultsSelectionBackground": "Цвет фона выбранной запиÑи в ÑпиÑке результатов быÑтрого редактора.", "peekViewResultsSelectionForeground": "Цвет переднего плана выбранной запиÑи в ÑпиÑке результатов быÑтрого редактора.", "peekViewEditorBackground": "Цвет фона быÑтрого редактора.", + "peekViewEditorGutterBackground": "Цвет фона Ð¿Ð¾Ð»Ñ Ð² окне быÑтрого редактора.", "peekViewResultsMatchHighlight": "Цвет Ð²Ñ‹Ð´ÐµÐ»ÐµÐ½Ð¸Ñ Ñовпадений в ÑпиÑке результатов быÑтрого редактора.", "peekViewEditorMatchHighlight": "Цвет Ð²Ñ‹Ð´ÐµÐ»ÐµÐ½Ð¸Ñ Ñовпадений в быÑтром редакторе." } \ No newline at end of file diff --git a/i18n/rus/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json b/i18n/rus/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json index 83631e142ec..ef1bb257b47 100644 --- a/i18n/rus/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json +++ b/i18n/rus/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json @@ -12,6 +12,7 @@ "readMore": "Подробнее...{0}", "suggestionWithDetailsAriaLabel": "{0}, предложение, Ñодержит данные", "suggestionAriaLabel": "{0}, предложение", + "readLess": "Кратко...{0}", "suggestWidget.loading": "Идет загрузка...", "suggestWidget.noSuggestions": "ÐŸÑ€ÐµÐ´Ð»Ð¾Ð¶ÐµÐ½Ð¸Ñ Ð¾Ñ‚ÑутÑтвуют.", "suggestionAriaAccepted": "{0}, принÑто", diff --git a/i18n/rus/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json b/i18n/rus/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json index 103258a8625..ddeb7dc0a68 100644 --- a/i18n/rus/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json +++ b/i18n/rus/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json @@ -15,5 +15,9 @@ "schema.brackets": "ОпределÑет Ñимволы Ñкобок, увеличивающие или уменьшающие отÑтуп.", "schema.autoClosingPairs": "ОпределÑет пары Ñкобок. Когда введена Ð¾Ñ‚ÐºÑ€Ñ‹Ð²Ð°ÑŽÑ‰Ð°Ñ Ñкобка, автоматичеÑки добавлÑетÑÑ Ð·Ð°ÐºÑ€Ñ‹Ð²Ð°ÑŽÑ‰Ð°Ñ.", "schema.autoClosingPairs.notIn": "ОпределÑет ÑпиÑок облаÑтей, где автоматичеÑкие пары отключены.", - "schema.surroundingPairs": "ОпределÑет пары Ñкобок, в которые заключаетÑÑ Ð²Ñ‹Ð±Ñ€Ð°Ð½Ð½Ð°Ñ Ñтрока." + "schema.surroundingPairs": "ОпределÑет пары Ñкобок, в которые заключаетÑÑ Ð²Ñ‹Ð±Ñ€Ð°Ð½Ð½Ð°Ñ Ñтрока.", + "schema.wordPattern": "Определение Ñлова Ð´Ð»Ñ Ñзыка.", + "schema.wordPattern.pattern": "Шаблон регулÑрного выражениÑ, иÑпользуемый Ð´Ð»Ñ ÑопоÑÑ‚Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ñлов.", + "schema.wordPattern.flags": "Флаги регулÑрного выражениÑ, иÑпользуемого Ð´Ð»Ñ ÑопоÑÑ‚Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ñлов.", + "schema.wordPattern.flags.errorMessage": "Должно ÑоответÑтвовать шаблону \"/^([gimuy]+)$/\"." } \ No newline at end of file diff --git a/i18n/rus/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json b/i18n/rus/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json index 7221481729a..6b77834c391 100644 --- a/i18n/rus/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json +++ b/i18n/rus/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json @@ -21,6 +21,8 @@ "menus.scmTitle": "Меню заголовков Ð´Ð»Ñ ÑиÑтемы ÑƒÐ¿Ñ€Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ð²ÐµÑ€ÑиÑми", "menus.resourceGroupContext": "КонтекÑтное меню группы реÑурÑов Ð´Ð»Ñ ÑиÑтемы ÑƒÐ¿Ñ€Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ð²ÐµÑ€ÑиÑми", "menus.resourceStateContext": "КонтекÑтное меню ÑоÑтоÑÐ½Ð¸Ñ Ñ€ÐµÑурÑов Ð´Ð»Ñ ÑиÑтемы ÑƒÐ¿Ñ€Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ð²ÐµÑ€ÑиÑми", + "view.viewTitle": "Меню заголовка Ð´Ð»Ñ Ð¾ÐºÐ½Ð° учаÑтников", + "view.itemContext": "КонтекÑтное меню Ñлемента Ð´Ð»Ñ Ð¾ÐºÐ½Ð° учаÑтников", "nonempty": "требуетÑÑ Ð½ÐµÐ¿ÑƒÑтое значение.", "opticon": "СвойÑтво icon может быть пропущено или должно быть Ñтрокой или литералом, например \"{dark, light}\"", "requireStringOrObject": "СвойÑтво \"{0}\" обÑзательно и должно иметь тип \"string\" или \"object\"", diff --git a/i18n/rus/src/vs/platform/extensions/common/extensionsRegistry.i18n.json b/i18n/rus/src/vs/platform/extensions/common/extensionsRegistry.i18n.json index fae3024afe1..1cc3bfcebce 100644 --- a/i18n/rus/src/vs/platform/extensions/common/extensionsRegistry.i18n.json +++ b/i18n/rus/src/vs/platform/extensions/common/extensionsRegistry.i18n.json @@ -14,6 +14,12 @@ "vscode.extension.contributes": "Ð’Ñе публикации раÑÑˆÐ¸Ñ€ÐµÐ½Ð¸Ñ VS Code, предÑтавленные Ñтим пакетом.", "vscode.extension.preview": "ДобавлÑет метку \"ÐŸÑ€ÐµÐ´Ð²Ð°Ñ€Ð¸Ñ‚ÐµÐ»ÑŒÐ½Ð°Ñ Ð²ÐµÑ€ÑиÑ\" Ð´Ð»Ñ Ñ€Ð°ÑÑˆÐ¸Ñ€ÐµÐ½Ð¸Ñ Ð² Marketplace.", "vscode.extension.activationEvents": "Ð¡Ð¾Ð±Ñ‹Ñ‚Ð¸Ñ Ð°ÐºÑ‚Ð¸Ð²Ð°Ñ†Ð¸Ð¸ Ð´Ð»Ñ Ñ€Ð°ÑÑˆÐ¸Ñ€ÐµÐ½Ð¸Ñ ÐºÐ¾Ð´Ð° VS Code.", + "vscode.extension.activationEvents.onLanguage": "Событие активации выдаетÑÑ ÐºÐ°Ð¶Ð´Ñ‹Ð¹ раз, когда открываетÑÑ Ñ„Ð°Ð¹Ð», который разрешаетÑÑ Ðº указанному Ñзыку.", + "vscode.extension.activationEvents.onCommand": "Событие активации выдаетÑÑ ÐºÐ°Ð¶Ð´Ñ‹Ð¹ раз при вызове указанной команды.", + "vscode.extension.activationEvents.onDebug": "Событие активации выдаетÑÑ ÐºÐ°Ð¶Ð´Ñ‹Ð¹ раз при запуÑке ÑеанÑа отладки указанного типа.", + "vscode.extension.activationEvents.workspaceContains": "Событие активации выдаетÑÑ ÐºÐ°Ð¶Ð´Ñ‹Ð¹ раз при открытии папки, Ñодержащей по крайней мере один файл, который ÑоответÑтвует указанной Ñтандартной маÑке.", + "vscode.extension.activationEvents.onView": "Событие активации выдаетÑÑ ÐºÐ°Ð¶Ð´Ñ‹Ð¹ раз при развертывании указанного окна.", + "vscode.extension.activationEvents.star": "Событие активации выдаетÑÑ Ð¿Ñ€Ð¸ запуÑке VS Code. Ð”Ð»Ñ ÑƒÐ´Ð¾Ð±Ñтва Ð¿Ð¾Ð»ÑŒÐ·Ð¾Ð²Ð°Ñ‚ÐµÐ»Ñ Ð¸Ñпользуйте Ñто Ñобытие в Ñвоем раÑширении только в том Ñлучае, еÑли другие ÑÐ¾Ñ‡ÐµÑ‚Ð°Ð½Ð¸Ñ Ñобытий не подходÑÑ‚.", "vscode.extension.badges": "МаÑÑив Ñмблем, отображаемых на боковой панели Ñтраницы раÑÑˆÐ¸Ñ€ÐµÐ½Ð¸Ñ Marketplace.", "vscode.extension.badges.url": "URL-Ð°Ð´Ñ€ÐµÑ Ð¸Ð·Ð¾Ð±Ñ€Ð°Ð¶ÐµÐ½Ð¸Ñ Ñмблемы.", "vscode.extension.badges.href": "СÑылка на Ñмблему.", diff --git a/i18n/rus/src/vs/platform/history/electron-main/historyMainService.i18n.json b/i18n/rus/src/vs/platform/history/electron-main/historyMainService.i18n.json new file mode 100644 index 00000000000..f3243b5f3b9 --- /dev/null +++ b/i18n/rus/src/vs/platform/history/electron-main/historyMainService.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "newWindow": "Ðовое окно", + "newWindowDesc": "Открывает новое окно", + "recentFolders": "Ðедавно иÑпользованные папки", + "folderDesc": "{0} {1}" +} \ No newline at end of file diff --git a/i18n/rus/src/vs/platform/markers/common/problemMatcher.i18n.json b/i18n/rus/src/vs/platform/markers/common/problemMatcher.i18n.json index 2595229d2aa..c79907b2cf8 100644 --- a/i18n/rus/src/vs/platform/markers/common/problemMatcher.i18n.json +++ b/i18n/rus/src/vs/platform/markers/common/problemMatcher.i18n.json @@ -34,6 +34,7 @@ "ProblemMatcherParser.noValidIdentifier": "Ошибка: ÑвойÑтво шаблона {0} не ÑвлÑетÑÑ Ð´Ð¾Ð¿ÑƒÑтимым именем переменной шаблона.", "ProblemMatcherParser.problemPattern.watchingMatcher": "Ð’ ÑопоÑтавителе проблем должны быть определены как начальный, так и конечный шаблоны Ð´Ð»Ñ Ð¾Ñ‚ÑлеживаниÑ.", "ProblemMatcherParser.invalidRegexp": "Ошибка: Ñтрока {0} не ÑвлÑетÑÑ Ð´Ð¾Ð¿ÑƒÑтимым регулÑрным выражением.\n", + "WatchingPatternSchema.regexp": "РегулÑрное выражение Ð´Ð»Ñ Ð¾Ð±Ð½Ð°Ñ€ÑƒÐ¶ÐµÐ½Ð¸Ñ Ð½Ð°Ñ‡Ð°Ð»Ð° или конца фоновой задачи.", "WatchingPatternSchema.file": "Ð˜Ð½Ð´ÐµÐºÑ Ð³Ñ€ÑƒÐ¿Ð¿Ñ‹ ÑопоÑÑ‚Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ð´Ð»Ñ Ð¸Ð¼ÐµÐ½Ð¸ файла. Может быть опущен.", "PatternTypeSchema.name": "Ð˜Ð¼Ñ Ð´Ð¾Ð±Ð°Ð²Ð»ÐµÐ½Ð½Ð¾Ð³Ð¾ или предопределенного шаблона", "PatternTypeSchema.description": "Шаблон проблем либо Ð¸Ð¼Ñ Ð´Ð¾Ð±Ð°Ð²Ð»ÐµÐ½Ð½Ð¾Ð³Ð¾ или предопределенного шаблона проблем. Его можно опуÑтить, еÑли указано базовое значение.", @@ -42,6 +43,12 @@ "ProblemMatcherSchema.severity": "СерьезноÑÑ‚ÑŒ по умолчанию Ð´Ð»Ñ Ð²Ñ‹Ñвленных проблем. ИÑпользуетÑÑ, еÑли в шаблоне не определена группа ÑопоÑÑ‚Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ð´Ð»Ñ ÑерьезноÑти.", "ProblemMatcherSchema.applyTo": "ОпределÑет, отноÑитÑÑ Ð»Ð¸ проблема, о которой ÑообщаетÑÑ Ð´Ð»Ñ Ñ‚ÐµÐºÑтового документа, только к открытым, только к закрытым или ко вÑем документам.", "ProblemMatcherSchema.fileLocation": "ОпределÑет ÑпоÑоб интерпретации имен файлов, указываемых в шаблоне проблемы.", + "ProblemMatcherSchema.background": "Шаблоны Ð´Ð»Ñ Ð¾Ñ‚ÑÐ»ÐµÐ¶Ð¸Ð²Ð°Ð½Ð¸Ñ Ð½Ð°Ñ‡Ð°Ð»Ð° и Ð¾ÐºÐ¾Ð½Ñ‡Ð°Ð½Ð¸Ñ Ñ„Ð¾Ð½Ð¾Ð²Ð¾Ð¹ задачи.", + "ProblemMatcherSchema.background.activeOnStart": "ЕÑли задано значение true, ÑредÑтво мониторинга фоновых задач будет находитьÑÑ Ð² активном режиме при запуÑке задачи. Это аналогично выдаче Ñтроки, ÑоответÑтвующей шаблону начала.", + "ProblemMatcherSchema.background.beginsPattern": "При наличии ÑоответÑÑ‚Ð²Ð¸Ñ Ð² выходных данных выдаетÑÑ Ñигнал о запуÑке фоновой задачи.", + "ProblemMatcherSchema.background.endsPattern": "При наличии ÑоответÑÑ‚Ð²Ð¸Ñ Ð² выходных данных выдаетÑÑ Ñигнал о завершении фоновой задачи.", + "ProblemMatcherSchema.watching.deprecated": "Это ÑвойÑтво Ð´Ð»Ñ Ð¾Ñ‚ÑÐ»ÐµÐ¶Ð¸Ð²Ð°Ð½Ð¸Ñ ÑƒÑтарело. ИÑпользуйте цвет фона.", + "ProblemMatcherSchema.watching": "Шаблоны Ð´Ð»Ñ Ð¾Ñ‚ÑÐ»ÐµÐ¶Ð¸Ð²Ð°Ð½Ð¸Ñ Ð½Ð°Ñ‡Ð°Ð»Ð° и Ð¾ÐºÐ¾Ð½Ñ‡Ð°Ð½Ð¸Ñ ÑˆÐ°Ð±Ð»Ð¾Ð½Ð° отÑлеживаниÑ.", "ProblemMatcherSchema.watching.activeOnStart": "ЕÑли задано значение true, наблюдатель находитÑÑ Ð² активном режиме, когда задача запуÑкаетÑÑ. Это равноÑильно выдаче Ñтроки, ÑоответÑтвующей шаблону начала.", "ProblemMatcherSchema.watching.beginsPattern": "При ÑоответÑтвии в выходных данных Ñообщает о запуÑке задачи наблюдениÑ.", "ProblemMatcherSchema.watching.endsPattern": "При ÑоответÑтвии в выходных данных Ñообщает о завершении задачи наблюдениÑ.", diff --git a/i18n/rus/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/rus/src/vs/platform/theme/common/colorRegistry.i18n.json index 6d4a756ac40..232f68c8367 100644 --- a/i18n/rus/src/vs/platform/theme/common/colorRegistry.i18n.json +++ b/i18n/rus/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -12,7 +12,6 @@ "focusBorder": "Общий цвет границ Ð´Ð»Ñ Ñлементов Ñ Ñ„Ð¾ÐºÑƒÑом. Этот цвет иÑпользуетÑÑ Ñ‚Ð¾Ð»ÑŒÐºÐ¾ в том Ñлучае, еÑли не переопределен в компоненте.", "contrastBorder": "Ð”Ð¾Ð¿Ð¾Ð»Ð½Ð¸Ñ‚ÐµÐ»ÑŒÐ½Ð°Ñ Ð³Ñ€Ð°Ð½Ð¸Ñ†Ð° вокруг Ñлементов, ÐºÐ¾Ñ‚Ð¾Ñ€Ð°Ñ Ð¾Ñ‚Ð´ÐµÐ»Ñет их от других Ñлементов Ð´Ð»Ñ ÑƒÐ»ÑƒÑ‡ÑˆÐµÐ½Ð¸Ñ ÐºÐ¾Ð½Ñ‚Ñ€Ð°Ñта.", "activeContrastBorder": "Ð”Ð¾Ð¿Ð¾Ð»Ð½Ð¸Ñ‚ÐµÐ»ÑŒÐ½Ð°Ñ Ð³Ñ€Ð°Ð½Ð¸Ñ†Ð° вокруг активных Ñлементов, ÐºÐ¾Ñ‚Ð¾Ñ€Ð°Ñ Ð¾Ñ‚Ð´ÐµÐ»Ñет их от других Ñлементов Ð´Ð»Ñ ÑƒÐ»ÑƒÑ‡ÑˆÐµÐ½Ð¸Ñ ÐºÐ¾Ð½Ñ‚Ñ€Ð°Ñта.", - "selectionBackground": "Цвет фона выделенного текÑта в Ñлементах пользовательÑкого интерфейÑа (например, в поле Ð´Ð»Ñ Ð²Ð²Ð¾Ð´Ð° значений или текÑтовом поле). Ðе применÑетÑÑ Ðº облаÑти редактора и терминала.", "textSeparatorForeground": "Цвет Ð´Ð»Ñ Ñ€Ð°Ð·Ð´ÐµÐ»Ð¸Ñ‚ÐµÐ»ÐµÐ¹ текÑта.", "textLinkForeground": "Цвет переднего плана Ð´Ð»Ñ ÑÑылок в текÑте.", "textLinkActiveForeground": "Цвет переднего фона Ð´Ð»Ñ Ð°ÐºÑ‚Ð¸Ð²Ð½Ñ‹Ñ… ÑÑылок в текÑте.", @@ -36,11 +35,13 @@ "dropdownForeground": "Передний план раÑкрывающегоÑÑ ÑпиÑка.", "dropdownBorder": "Граница раÑкрывающегоÑÑ ÑпиÑка.", "listFocusBackground": "Фоновый цвет находÑщегоÑÑ Ð² фокуÑе Ñлемента List/Tree, когда Ñлемент List/Tree активен. Ðа активном Ñлементе List/Tree еÑÑ‚ÑŒ Ñ„Ð¾ÐºÑƒÑ ÐºÐ»Ð°Ð²Ð¸Ð°Ñ‚ÑƒÑ€Ñ‹, на неактивном — нет.", + "listFocusForeground": "Цвет переднего плана находÑщегоÑÑ Ð² фокуÑе Ñлемента List/Tree, когда Ñлемент List/Tree активен. Ðа активном Ñлементе List/Tree еÑÑ‚ÑŒ Ñ„Ð¾ÐºÑƒÑ ÐºÐ»Ð°Ð²Ð¸Ð°Ñ‚ÑƒÑ€Ñ‹, на неактивном — нет.", "listActiveSelectionBackground": "Фоновый цвет выбранного Ñлемента List/Tree, когда Ñлемент List/Tree активен. Ðа активном Ñлементе List/Tree еÑÑ‚ÑŒ Ñ„Ð¾ÐºÑƒÑ ÐºÐ»Ð°Ð²Ð¸Ð°Ñ‚ÑƒÑ€Ñ‹, на неактивном — нет.", "listActiveSelectionForeground": "Цвет переднего плана выбранного Ñлемента List/Tree, когда Ñлемент List/Tree активен. Ðа активном Ñлементе List/Tree еÑÑ‚ÑŒ Ñ„Ð¾ÐºÑƒÑ ÐºÐ»Ð°Ð²Ð¸Ð°Ñ‚ÑƒÑ€Ñ‹, на неактивном — нет.", "listInactiveSelectionBackground": "Фоновый цвет выбранного Ñлемента List/Tree, когда Ñлемент List/Tree неактивен. Ðа активном Ñлементе List/Tree еÑÑ‚ÑŒ Ñ„Ð¾ÐºÑƒÑ ÐºÐ»Ð°Ð²Ð¸Ð°Ñ‚ÑƒÑ€Ñ‹, на неактивном — нет.", "listInactiveSelectionForeground": "Цвет текÑта выбранного Ñлемента List/Tree, когда Ñлемент List/Tree неактивен. Ðа активном Ñлементе List/Tree еÑÑ‚ÑŒ Ñ„Ð¾ÐºÑƒÑ ÐºÐ»Ð°Ð²Ð¸Ð°Ñ‚ÑƒÑ€Ñ‹, на неактивном — нет.", "listHoverBackground": "Фоновый цвет Ñлементов List/Tree при наведении курÑора мыши.", + "listHoverForeground": "Цвет переднего плана Ñлементов List/Tree при наведении курÑора мыши.", "listDropBackground": "Фоновый цвет Ñлементов List/Tree при перемещении Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ мыши.", "highlight": "Цвет переднего плана Ð´Ð»Ñ Ð²Ñ‹Ð´ÐµÐ»ÐµÐ½Ð¸Ñ ÑоответÑÑ‚Ð²Ð¸Ñ Ð¿Ñ€Ð¸ поиÑке по Ñлементу List/Tree.", "pickerGroupForeground": "Цвет ÑредÑтва быÑтрого выбора Ð´Ð»Ñ Ð³Ñ€ÑƒÐ¿Ð¿Ð¸Ñ€Ð¾Ð²ÐºÐ¸ меток.", @@ -54,9 +55,11 @@ "scrollbarSliderBackground": "Цвет фона ползунка.", "scrollbarSliderHoverBackground": "Цвет фона ползунка при наведении.", "scrollbarSliderActiveBackground": "Цвет фона активного ползунка.", + "progressBarBackground": "Цвет фона индикатора выполнениÑ, который может отображатьÑÑ Ð´Ð»Ñ Ð´Ð»Ð¸Ñ‚ÐµÐ»ÑŒÐ½Ñ‹Ñ… операций.", "editorBackground": "Цвет фона редактора.", "editorForeground": "Цвет переднего плана редактора по умолчанию.", "editorWidgetBackground": "Цвет фона виджетов редактора, таких как найти/заменить.", + "editorWidgetBorder": "Цвет границы мини-приложений редактора. Этот цвет иÑпользуетÑÑ Ñ‚Ð¾Ð»ÑŒÐºÐ¾ в том Ñлучае, еÑли у мини-Ð¿Ñ€Ð¸Ð»Ð¾Ð¶ÐµÐ½Ð¸Ñ ÐµÑÑ‚ÑŒ граница и еÑли Ñтот цвет не переопределен мини-приложением.", "editorSelection": "Цвет Ð²Ñ‹Ð´ÐµÐ»ÐµÐ½Ð¸Ñ Ñ€ÐµÐ´Ð°ÐºÑ‚Ð¾Ñ€Ð°.", "editorInactiveSelection": "Цвет Ð²Ñ‹Ð´ÐµÐ»ÐµÐ½Ð¸Ñ Ð² неактивном редакторе.", "editorSelectionHighlight": "Цвет регионов Ñ Ñ‚ÐµÐ¼ же Ñодержимым, что и в выделении.", @@ -70,5 +73,12 @@ "diffEditorInserted": "Цвет фона Ð´Ð»Ñ Ð´Ð¾Ð±Ð°Ð²Ð»ÐµÐ½Ð½Ñ‹Ñ… Ñтрок.", "diffEditorRemoved": "Цвет фона Ð´Ð»Ñ ÑƒÐ´Ð°Ð»ÐµÐ½Ð½Ñ‹Ñ… Ñтрок.", "diffEditorInsertedOutline": "Цвет контура Ð´Ð»Ñ Ð´Ð¾Ð±Ð°Ð²Ð»ÐµÐ½Ð½Ñ‹Ñ… Ñтрок.", - "diffEditorRemovedOutline": "Цвет контура Ð´Ð»Ñ ÑƒÐ´Ð°Ð»ÐµÐ½Ð½Ñ‹Ñ… Ñтрок." + "diffEditorRemovedOutline": "Цвет контура Ð´Ð»Ñ ÑƒÐ´Ð°Ð»ÐµÐ½Ð½Ñ‹Ñ… Ñтрок.", + "mergeCurrentHeaderBackground": "Цвет фона текущего заголовка во внутренних конфликтах ÑлиÑниÑ.", + "mergeCurrentContentBackground": "Цвет фона текущего Ñодержимого во внутренних конфликтах ÑлиÑниÑ.", + "mergeIncomingHeaderBackground": "Цвет фона входÑщего заголовка во внутренних конфликтах ÑлиÑниÑ.", + "mergeIncomingContentBackground": "Цвет фона входÑщего Ñодержимого во внутренних конфликтах ÑлиÑниÑ.", + "mergeBorder": "Цвет границы заголовков и Ñ€Ð°Ð·Ð´ÐµÐ»Ð¸Ñ‚ÐµÐ»Ñ Ð²Ð¾ внутренних конфликтах ÑлиÑниÑ.", + "overviewRulerCurrentContentForeground": "Цвет переднего плана линейки текущего окна во внутренних конфликтах ÑлиÑниÑ.", + "overviewRulerIncomingContentForeground": "Цвет переднего плана линейки входÑщего окна во внутренних конфликтах ÑлиÑниÑ." } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/rus/src/vs/workbench/api/node/extHostTask.i18n.json index 8b6ad71cd4e..4b90a12aaf2 100644 --- a/i18n/rus/src/vs/workbench/api/node/extHostTask.i18n.json +++ b/i18n/rus/src/vs/workbench/api/node/extHostTask.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "task.label": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/api/node/extHostTreeViews.i18n.json b/i18n/rus/src/vs/workbench/api/node/extHostTreeViews.i18n.json index 8b6ad71cd4e..9f9c8f9221d 100644 --- a/i18n/rus/src/vs/workbench/api/node/extHostTreeViews.i18n.json +++ b/i18n/rus/src/vs/workbench/api/node/extHostTreeViews.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "treeView.notRegistered": "ОтÑутÑтвует зарегиÑтрированное предÑтавление в виде дерева Ñ Ð¸Ð´ÐµÐ½Ñ‚Ð¸Ñ„Ð¸ÐºÐ°Ñ‚Ð¾Ñ€Ð¾Ð¼ '{0}'.", + "treeItem.notFound": "ОтÑутÑтвует Ñлемент дерева Ñ Ð¸Ð´ÐµÐ½Ñ‚Ð¸Ñ„Ð¸ÐºÐ°Ñ‚Ð¾Ñ€Ð¾Ð¼ '{0}'.", + "treeView.duplicateElement": "Элемент {0} уже зарегиÑтрирован" +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/browser/actions/configureLocale.i18n.json b/i18n/rus/src/vs/workbench/browser/actions/configureLocale.i18n.json index 4b803b9827d..b6db31f0ebd 100644 --- a/i18n/rus/src/vs/workbench/browser/actions/configureLocale.i18n.json +++ b/i18n/rus/src/vs/workbench/browser/actions/configureLocale.i18n.json @@ -7,6 +7,7 @@ "configureLocale": "ÐаÑтроить Ñзык", "displayLanguage": "ОпределÑет Ñзык интерфейÑа VSCode.", "doc": "СпиÑок поддерживаемых Ñзыков Ñм. в {0}.", + "restart": "Ð”Ð»Ñ Ð¸Ð·Ð¼ÐµÐ½ÐµÐ½Ð¸Ñ Ð·Ð½Ð°Ñ‡ÐµÐ½Ð¸Ñ Ñ‚Ñ€ÐµÐ±ÑƒÐµÑ‚ÑÑ Ð¿ÐµÑ€ÐµÐ·Ð°Ð¿ÑƒÑк VSCode.", "fail.createSettings": "Ðевозможно Ñоздать \"{0}\" ({1}).", "JsonSchema.locale": "Язык пользовательÑкого интерфейÑа." } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json b/i18n/rus/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json index 8eb0fd363df..cdc81741e9e 100644 --- a/i18n/rus/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json +++ b/i18n/rus/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json @@ -5,5 +5,6 @@ // Do not edit this file. It is machine generated. { "hideActivitBar": "Скрыть панель дейÑтвий", - "activityBarAriaLabel": "Переключатель активного предÑтавлениÑ" + "activityBarAriaLabel": "Переключатель активного предÑтавлениÑ", + "globalActions": "Глобальные дейÑтвиÑ" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json b/i18n/rus/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json index fe621363ede..be54f2a8fa9 100644 --- a/i18n/rus/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json +++ b/i18n/rus/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json @@ -10,7 +10,7 @@ "multiSelection": "Выделений: {0}", "endOfLineLineFeed": "LF", "endOfLineCarriageReturnLineFeed": "CRLF", - "tabFocusModeEnabled": "Клавиша TAB перемещает фокуÑ", + "screenReaderDetectedExtra": "ЕÑли вы не иÑпользуете ÑредÑтво Ñ‡Ñ‚ÐµÐ½Ð¸Ñ Ñ Ñкрана, измените значение параметра \"editor.accessibilitySupport\" на \"off\".", "disableTabMode": "Отключить режим Ñпециальных возможноÑтей", "gotoLine": "Перейти к Ñтроке", "indentation": "ОтÑтуп", diff --git a/i18n/rus/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json b/i18n/rus/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json new file mode 100644 index 00000000000..b00914a4167 --- /dev/null +++ b/i18n/rus/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpen": "Перейти к файлу...", + "quickNavigateNext": "Перейти к Ñледующему Ñлементу в Quick Open.", + "quickNavigatePrevious": "Перейти к предыдущему Ñлементу в Quick Open.", + "quickSelectNext": "Выбрать Ñледующее в Quick Open", + "quickSelectPrevious": "Выбрать предыдущее в Quick Open" +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/browser/quickopen.i18n.json b/i18n/rus/src/vs/workbench/browser/quickopen.i18n.json index 2706fe8a1f0..b1992b59c50 100644 --- a/i18n/rus/src/vs/workbench/browser/quickopen.i18n.json +++ b/i18n/rus/src/vs/workbench/browser/quickopen.i18n.json @@ -6,6 +6,5 @@ { "noResultsMatching": "Ðет ÑоответÑтвующих результатов", "noResultsFound2": "Результаты не найдены", - "entryAriaLabel": "{0}, команда", - "noCommands": "Ðет ÑоответÑтвующих команд" + "entryAriaLabel": "{0}, команда" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/browser/viewlet.i18n.json b/i18n/rus/src/vs/workbench/browser/viewlet.i18n.json index 9df902210c7..c5dc5c2265a 100644 --- a/i18n/rus/src/vs/workbench/browser/viewlet.i18n.json +++ b/i18n/rus/src/vs/workbench/browser/viewlet.i18n.json @@ -4,6 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "collapse": "Свернуть вÑе", - "viewToolbarAriaLabel": "ДейÑтвий: {0}" + "collapse": "Свернуть вÑе" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/common/theme.i18n.json b/i18n/rus/src/vs/workbench/common/theme.i18n.json index 3939a7804fa..2addbdf6478 100644 --- a/i18n/rus/src/vs/workbench/common/theme.i18n.json +++ b/i18n/rus/src/vs/workbench/common/theme.i18n.json @@ -7,27 +7,42 @@ "tabActiveBackground": "Цвет фона активной вкладки. Вкладки — Ñто контейнеры Ð´Ð»Ñ Ñ€ÐµÐ´Ð°ÐºÑ‚Ð¾Ñ€Ð¾Ð² в облаÑти редактора. Ð’ одной группе редакторов можно открыть неÑколько вкладок. Может приÑутÑтвовать неÑколько групп редакторов.", "tabInactiveBackground": "Цвет фона неактивной вкладки. Вкладки — Ñто контейнеры Ð´Ð»Ñ Ñ€ÐµÐ´Ð°ÐºÑ‚Ð¾Ñ€Ð¾Ð² в облаÑти редактора. Ð’ одной группе редакторов можно открыть неÑколько вкладок. Может приÑутÑтвовать неÑколько групп редакторов.", "tabBorder": "Граница Ð´Ð»Ñ Ñ€Ð°Ð·Ð´ÐµÐ»ÐµÐ½Ð¸Ñ Ð²ÐºÐ»Ð°Ð´Ð¾Ðº. Вкладки — Ñто контейнеры Ð´Ð»Ñ Ñ€ÐµÐ´Ð°ÐºÑ‚Ð¾Ñ€Ð¾Ð² в облаÑти редакторов. Ð’ одной группе редакторов можно открыть неÑколько вкладок. Может быть неÑколько групп редакторов.", + "tabActiveForeground": "Цвет переднего плана активной вкладки в активной группе. Вкладки — Ñто контейнеры Ð´Ð»Ñ Ñ€ÐµÐ´Ð°ÐºÑ‚Ð¾Ñ€Ð¾Ð² в облаÑти редактора. Ð’ одной группе редакторов можно открыть неÑколько вкладок. Может приÑутÑтвовать неÑколько групп редакторов.", + "tabInactiveForeground": "Цвет переднего плана неактивной вкладки в активной группе. Вкладки — Ñто контейнеры Ð´Ð»Ñ Ñ€ÐµÐ´Ð°ÐºÑ‚Ð¾Ñ€Ð¾Ð² в облаÑти редактора. Ð’ одной группе редакторов можно открыть неÑколько вкладок. Может приÑутÑтвовать неÑколько групп редакторов.", + "tabUnfocusedActiveForeground": "Цвет переднего плана активной вкладки в неактивной группе. Вкладки — Ñто контейнеры Ð´Ð»Ñ Ñ€ÐµÐ´Ð°ÐºÑ‚Ð¾Ñ€Ð¾Ð² в облаÑти редактора. Ð’ одной группе редакторов можно открыть неÑколько вкладок. Может приÑутÑтвовать неÑколько групп редакторов.", + "tabUnfocusedInactiveForeground": "Цвет переднего плана неактивной вкладки в неактивной группе. Вкладки — Ñто контейнеры Ð´Ð»Ñ Ñ€ÐµÐ´Ð°ÐºÑ‚Ð¾Ñ€Ð¾Ð² в облаÑти редактора. Ð’ одной группе редакторов можно открыть неÑколько вкладок. Может приÑутÑтвовать неÑколько групп редакторов.", "editorGroupBackground": "Цвет фона группы редакторов. Группы редакторов предÑтавлÑÑŽÑ‚ Ñобой контейнеры редакторов. Цвет фона отображаетÑÑ Ð¿Ñ€Ð¸ перетаÑкивании групп редакторов.", + "tabsContainerBackground": "Цвет фона Ð´Ð»Ñ Ð·Ð°Ð³Ð¾Ð»Ð¾Ð²ÐºÐ° группы редакторов, когда вкладки включены. Группы редакторов предÑтавлÑÑŽÑ‚ Ñобой контейнеры редакторов.", + "tabsContainerBorder": "Цвет границы Ð´Ð»Ñ Ð·Ð°Ð³Ð¾Ð»Ð¾Ð²ÐºÐ° группы редакторов, когда вкладки включены. Группы редакторов предÑтавлÑÑŽÑ‚ Ñобой контейнеры редакторов.", "editorGroupHeaderBackground": "Цвет фона Ð´Ð»Ñ Ð·Ð°Ð³Ð¾Ð»Ð¾Ð²ÐºÐ° группы редакторов, когда вкладки отключены. Группы редакторов предÑтавлÑÑŽÑ‚ Ñобой контейнеры редакторов.", "editorGroupBorder": "Цвет Ð´Ð»Ñ Ñ€Ð°Ð·Ð´ÐµÐ»ÐµÐ½Ð¸Ñ Ð½ÐµÑкольких групп редакторов. Группы редакторов — Ñто контейнеры редакторов.", + "editorDragAndDropBackground": "Цвет фона при перетаÑкивании редакторов. Этот цвет должен обладать прозрачноÑтью, чтобы Ñодержимое редактора оÑтавалоÑÑŒ видимым.", + "panelBackground": "Цвет фона панели. Панели показаны под облаÑтью редактора и Ñодержат такие предÑтавлениÑ, как выходные данные и вÑтроенный терминал.", "panelBorder": "Цвет верхней границы панели, отделÑющей ее от редактора. Панели показаны под облаÑтью редактора и Ñодержат такие предÑтавлениÑ, как выходные данные и вÑтроенный терминал.", "panelActiveTitleForeground": "Цвет заголовка Ð´Ð»Ñ Ð°ÐºÑ‚Ð¸Ð²Ð½Ð¾Ð¹ панели. Панели отображаютÑÑ Ð¿Ð¾Ð´ облаÑтью редактора и Ñодержат такие предÑтавлениÑ, как окно вывода и вÑтроенный терминал.", "panelInactiveTitleForeground": "Цвет заголовка Ð´Ð»Ñ Ð½ÐµÐ°ÐºÑ‚Ð¸Ð²Ð½Ð¾Ð¹ панели. Панели отображаютÑÑ Ð¿Ð¾Ð´ облаÑтью редактора и Ñодержат такие предÑтавлениÑ, как окно вывода и вÑтроенный терминал.", "panelActiveTitleBorder": "Цвет границ Ð´Ð»Ñ Ð·Ð°Ð³Ð¾Ð»Ð¾Ð²ÐºÐ° активной панели. Панели отображаютÑÑ Ð¿Ð¾Ð´ облаÑтью редактора и Ñодержат такие предÑтавлениÑ, как окно вывода и вÑтроенный терминал.", "statusBarForeground": "Цвет переднего плана панели ÑоÑтоÑниÑ. Панель ÑоÑтоÑÐ½Ð¸Ñ Ð¾Ñ‚Ð¾Ð±Ñ€Ð°Ð¶Ð°ÐµÑ‚ÑÑ Ð²Ð½Ð¸Ð·Ñƒ окна.", "statusBarBackground": "Цвет фона Ñтандартной панели ÑоÑтоÑниÑ. Панель ÑоÑтоÑÐ½Ð¸Ñ Ð¾Ñ‚Ð¾Ð±Ñ€Ð°Ð¶Ð°ÐµÑ‚ÑÑ Ð²Ð½Ð¸Ð·Ñƒ окна.", + "statusBarBorder": "Цвет границы Ñтроки ÑоÑтоÑниÑ, который раÑпроÑтранÑетÑÑ Ð½Ð° боковую панель и редактор. Строка ÑоÑтоÑÐ½Ð¸Ñ Ñ€Ð°Ñположена в нижней чаÑти окна.", "statusBarNoFolderBackground": "Цвет фона панели ÑоÑтоÑниÑ, еÑли папка не открыта. Панель ÑоÑтоÑÐ½Ð¸Ñ Ð¾Ñ‚Ð¾Ð±Ñ€Ð°Ð¶Ð°ÐµÑ‚ÑÑ Ð²Ð½Ð¸Ð·Ñƒ окна.", + "statusBarNoFolderForeground": "Цвет переднего плана Ñтроки ÑоÑтоÑниÑ, еÑли папка не открыта. Строка ÑоÑтоÑÐ½Ð¸Ñ Ð¾Ñ‚Ð¾Ð±Ñ€Ð°Ð¶Ð°ÐµÑ‚ÑÑ Ð² нижней чаÑти окна.", "statusBarItemActiveBackground": "Цвет фона Ñлементов панели ÑоÑтоÑÐ½Ð¸Ñ Ð¿Ñ€Ð¸ щелчке. Панель ÑоÑтоÑÐ½Ð¸Ñ Ð¾Ñ‚Ð¾Ð±Ñ€Ð°Ð¶Ð°ÐµÑ‚ÑÑ Ð²Ð½Ð¸Ð·Ñƒ окна.", "statusBarItemHoverBackground": "Цвет фона Ñлементов панели ÑоÑтоÑÐ½Ð¸Ñ Ð¿Ñ€Ð¸ наведении. Панель ÑоÑтоÑÐ½Ð¸Ñ Ð¾Ñ‚Ð¾Ð±Ñ€Ð°Ð¶Ð°ÐµÑ‚ÑÑ Ð²Ð½Ð¸Ð·Ñƒ окна.", "statusBarProminentItemBackground": "Цвет фона приоритетных Ñлементов панели ÑоÑтоÑниÑ. Приоритетные Ñлементы выделÑÑŽÑ‚ÑÑ Ð½Ð° фоне других Ñлементов панели ÑоÑтоÑниÑ, чтобы подчеркнуть их значение. Панель ÑоÑтоÑÐ½Ð¸Ñ Ð¾Ñ‚Ð¾Ð±Ñ€Ð°Ð¶Ð°ÐµÑ‚ÑÑ Ð² нижней чаÑти окна.", "statusBarProminentItemHoverBackground": "Цвет фона приоритетных Ñлементов панели ÑоÑтоÑÐ½Ð¸Ñ Ð¿Ñ€Ð¸ наведении. Приоритетные Ñлементы выделÑÑŽÑ‚ÑÑ Ð½Ð° фоне других Ñлементов панели ÑоÑтоÑниÑ, чтобы подчеркнуть их значение. Панель ÑоÑтоÑÐ½Ð¸Ñ Ð¾Ñ‚Ð¾Ð±Ñ€Ð°Ð¶Ð°ÐµÑ‚ÑÑ Ð² нижней чаÑти окна.", "activityBarBackground": "Цвет фона панели дейÑтвий. Панель дейÑтвий отображаетÑÑ Ñлева или Ñправа и позволÑет переключатьÑÑ Ð¼ÐµÐ¶Ð´Ñƒ предÑтавлениÑми боковой панели.", "activityBarForeground": "Цвет переднего плана панели дейÑтвий (например, цвет, иÑпользуемый Ð´Ð»Ñ Ð·Ð½Ð°Ñ‡ÐºÐ¾Ð²). Панель дейÑтвий отображаетÑÑ Ñлева или Ñправа и позволÑет переключатьÑÑ Ð¼ÐµÐ¶Ð´Ñƒ предÑтавлениÑми боковой панели.", + "activityBarBorder": "Цвет границы панели дейÑтвий, который раÑпроÑтранÑетÑÑ Ð½Ð° боковую панель. Панель дейÑтвий отображаетÑÑ Ñлева или Ñправа и позволÑет переключатьÑÑ Ð¼ÐµÐ¶Ð´Ñƒ предÑтавлениÑми в боковой панели.", + "activityBarDragAndDropBackground": "Цвет панели обратной ÑвÑзи при перетаÑкивании Ð´Ð»Ñ Ñлементов панели дейÑтвий. Цвет должен обладать прозрачноÑтью, чтобы Ñодержимое панели дейÑтвий оÑтавалоÑÑŒ видимым. Панель дейÑтвий отображаетÑÑ Ñ Ð¿Ñ€Ð°Ð²Ð¾Ð³Ð¾ или Ñ Ð»ÐµÐ²Ð¾Ð³Ð¾ ÐºÑ€Ð°Ñ Ð¸ позволÑет переключатьÑÑ Ð¼ÐµÐ¶Ð´Ñƒ предÑтавлениÑми в боковой панели.", "activityBarBadgeBackground": "Цвет фона значка уведомлений о дейÑтвиÑÑ…. Панель дейÑтвий отображаетÑÑ Ñлева или Ñправа и позволÑет переключатьÑÑ Ð¼ÐµÐ¶Ð´Ñƒ предÑтавлениÑми боковой панели.", "activityBarBadgeForeground": "Цвет переднего плана значка уведомлений о дейÑтвиÑÑ…. Панель дейÑтвий отображаетÑÑ Ñлева или Ñправа и позволÑет переключатьÑÑ Ð¼ÐµÐ¶Ð´Ñƒ предÑтавлениÑми боковой панели.", "sideBarBackground": "Цвет фона боковой панели. Ð‘Ð¾ÐºÐ¾Ð²Ð°Ñ Ð¿Ð°Ð½ÐµÐ»ÑŒÂ â€” Ñто контейнер таких предÑтавлений, как проводник и поиÑк.", + "sideBarForeground": "Цвет переднего плана боковой панели. Ð‘Ð¾ÐºÐ¾Ð²Ð°Ñ Ð¿Ð°Ð½ÐµÐ»ÑŒÂ â€” Ñто контейнер Ð´Ð»Ñ Ñ‚Ð°ÐºÐ¸Ñ… предÑтавлений, как проводник и поиÑк.", + "sideBarBorder": "Цвет границы боковой панели Ñо Ñтороны редактора. Ð‘Ð¾ÐºÐ¾Ð²Ð°Ñ Ð¿Ð°Ð½ÐµÐ»ÑŒ — Ñто контейнер Ð´Ð»Ñ Ñ‚Ð°ÐºÐ¸Ñ… предÑтавлений, как проводник и поиÑк.", "sideBarTitleForeground": "Цвет переднего плана заголовка боковой панели. Ð‘Ð¾ÐºÐ¾Ð²Ð°Ñ Ð¿Ð°Ð½ÐµÐ»ÑŒÂ â€” Ñто контейнер Ð´Ð»Ñ Ñ‚Ð°ÐºÐ¸Ñ… предÑтавлений, как проводник и поиÑк.", "sideBarSectionHeaderBackground": "Цвет фона Ð´Ð»Ñ Ð·Ð°Ð³Ð¾Ð»Ð¾Ð²ÐºÐ° раздела боковой панели. Ð‘Ð¾ÐºÐ¾Ð²Ð°Ñ Ð¿Ð°Ð½ÐµÐ»ÑŒÂ â€” Ñто контейнер Ð´Ð»Ñ Ñ‚Ð°ÐºÐ¸Ñ… предÑтавлений, как проводник и поиÑк.", + "sideBarSectionHeaderForeground": "Цвет переднего плана Ð´Ð»Ñ Ð·Ð°Ð³Ð¾Ð»Ð¾Ð²ÐºÐ° раздела боковой панели. Ð‘Ð¾ÐºÐ¾Ð²Ð°Ñ Ð¿Ð°Ð½ÐµÐ»ÑŒÂ â€” Ñто контейнер Ð´Ð»Ñ Ñ‚Ð°ÐºÐ¸Ñ… предÑтавлений, как проводник и поиÑк.", "titleBarActiveForeground": "Передний план панели заголовка, еÑли окно активно. Обратите внимание, что Ñтот цвет ÑÐµÐ¹Ñ‡Ð°Ñ Ð¿Ð¾Ð´Ð´ÐµÑ€Ð¶Ð¸Ð²Ð°ÐµÑ‚ÑÑ Ñ‚Ð¾Ð»ÑŒÐºÐ¾ в macOS.", "titleBarInactiveForeground": "Передний план панели заголовка, еÑли окно неактивно. Обратите внимание, что Ñтот цвет ÑÐµÐ¹Ñ‡Ð°Ñ Ð¿Ð¾Ð´Ð´ÐµÑ€Ð¶Ð¸Ð²Ð°ÐµÑ‚ÑÑ Ñ‚Ð¾Ð»ÑŒÐºÐ¾ в macOS.", "titleBarActiveBackground": "Фон панели заголовка, еÑли окно активно. Обратите внимание, что Ñтот цвет ÑÐµÐ¹Ñ‡Ð°Ñ Ð¿Ð¾Ð´Ð´ÐµÑ€Ð¶Ð¸Ð²Ð°ÐµÑ‚ÑÑ Ñ‚Ð¾Ð»ÑŒÐºÐ¾ в macOS.", diff --git a/i18n/rus/src/vs/workbench/electron-browser/actions.i18n.json b/i18n/rus/src/vs/workbench/electron-browser/actions.i18n.json index 867ffadb0a4..5d2a1aca0bb 100644 --- a/i18n/rus/src/vs/workbench/electron-browser/actions.i18n.json +++ b/i18n/rus/src/vs/workbench/electron-browser/actions.i18n.json @@ -6,9 +6,6 @@ { "closeActiveEditor": "Закрыть редактор", "closeWindow": "Закрыть окно", - "switchWindow": "Переключить окно", - "switchWindowPlaceHolder": "Выберите окно", - "current": "Текущее окно", "closeFolder": "Закрыть папку", "noFolderOpened": "Ð’ наÑтоÑщий момент в Ñтом ÑкземплÑре нет открытой папки, которую можно было бы закрыть.", "newWindow": "Ðовое окно", @@ -20,7 +17,7 @@ "zoomReset": "СброÑить маÑштаб", "appPerf": "ПроизводительноÑÑ‚ÑŒ запуÑка", "reloadWindow": "Перезагрузить окно", - "openRecent": "Открыть поÑледний", + "current": "Текущее окно", "folders": "папки", "files": "файлы", "openRecentPlaceHolderMac": "Выбрать путь (удерживайте клавишу CMD, чтобы открыть в новом окне)", @@ -32,10 +29,6 @@ "openDocumentationUrl": "ДокументациÑ", "openIntroductoryVideosUrl": "Ð’Ñтупительные видео", "toggleSharedProcess": "Переключить общий процеÑÑ", - "navigateLeft": "Перейти к чаÑти предÑÑ‚Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ñлева", - "navigateRight": "Перейти к чаÑти предÑÑ‚Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ñправа", - "navigateUp": "Перейти к чаÑти предÑÑ‚Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ð²Ð²ÐµÑ€Ñ…Ñƒ", - "navigateDown": "Перейти к чаÑти предÑÑ‚Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ð²Ð½Ð¸Ð·Ñƒ", "increaseViewSize": "Увеличить размер текущего предÑтавлениÑ", "decreaseViewSize": "Уменьшить размер текущего предÑтавлениÑ" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/rus/src/vs/workbench/electron-browser/main.contribution.i18n.json index f2bd599c1b9..d3dd4c58f44 100644 --- a/i18n/rus/src/vs/workbench/electron-browser/main.contribution.i18n.json +++ b/i18n/rus/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -31,10 +31,6 @@ "window.openFoldersInNewWindow.off": "Папки будут заменÑÑ‚ÑŒ поÑледнее активное окно.", "window.openFoldersInNewWindow.default": "Папки будут открыватьÑÑ Ð² новом окне, еÑли папка не выбрана в приложении (например, в меню \"Файл\").", "openFoldersInNewWindow": "ОпределÑет, будут ли папки открыватьÑÑ Ð² новом окне или заменÑÑ‚ÑŒ поÑледнее активное окно.\n- default: папки будут открыватьÑÑ Ð² новом окне, еÑли папка не выбрана из Ð¿Ñ€Ð¸Ð»Ð¾Ð¶ÐµÐ½Ð¸Ñ (например, из меню \"Файл\").\n- on: папки будут открыватьÑÑ Ð² новом окне.\n- off: папки будут заменÑÑ‚ÑŒ поÑледнее активное окно.\nОбратите внимание, что возможны Ñлучаи, когда Ñтот параметр игнорируетÑÑ (например, при иÑпользовании параметра командной Ñтроки -new-window или -reuse-window).", - "window.reopenFolders.none": "Запрет повторного Ð¾Ñ‚ÐºÑ€Ñ‹Ñ‚Ð¸Ñ Ð¿Ð°Ð¿ÐºÐ¸.", - "window.reopenFolders.one": "Повторное открытие поÑледней активной папки.", - "window.reopenFolders.all": "Повторное открытие вÑех папок поÑледнего ÑеанÑа.", - "reopenFolders": "УправлÑет повторным открытием папок поÑле перезапуÑка. Выберите значение \"none\", чтобы не открывать папку повторно, \"one\", чтобы открывалаÑÑŒ поÑледнÑÑ Ð¿Ð°Ð¿ÐºÐ°, Ñ ÐºÐ¾Ñ‚Ð¾Ñ€Ð¾Ð¹ вы работали, или \"all\", чтобы открывалиÑÑŒ вÑе папки поÑледнего ÑеанÑа.", "restoreFullscreen": "ОпределÑет, должно ли окно воÑÑтанавливатьÑÑ Ð² полноÑкранном режиме, еÑли оно было закрыто в полноÑкранном режиме.", "zoomLevel": "ÐаÑтройте маÑштаб окна. ИÑходный размер равен 0. Увеличение или уменьшение Ð·Ð½Ð°Ñ‡ÐµÐ½Ð¸Ñ Ð½Ð° 1 означает увеличение или уменьшение окна на 20 %. Чтобы более точно задать маÑштаб, можно также ввеÑти деÑÑтичное чиÑло.", "title": "ОпределÑет заголовок окна в завиÑимоÑти от активного редактора. Переменные заменÑÑŽÑ‚ÑÑ Ð½Ð° оÑновании контекÑта.\n${activeEditorShort}: например, myFile.txt\n${activeEditorMedium}: например, myFolder/myFile.txt\n${activeEditorLong}: например, /Users/Development/myProject/myFolder/myFile.txt\n${rootName}: например, myProject\n${rootPath}: например, /Users/Development/myProject\n${appName}: например, VS Code\n${dirty}: индикатор \"грÑзного\", еÑли активный редактор ÑвлÑетÑÑ \"грÑзным\"\n${separator}: уÑловный разделитель (\" - \"), который отображаетÑÑ, только еÑли окружен переменными Ñо значениÑми.", @@ -42,11 +38,13 @@ "window.newWindowDimensions.inherit": "Открывать новые окна того же размера, что и поÑледнее активное окно.", "window.newWindowDimensions.maximized": "Открывать новые окна в развернутом ÑоÑтоÑнии.", "window.newWindowDimensions.fullscreen": "Открывать новые окна в полноÑкранном режиме.", + "newWindowDimensions": "ОпределÑет размеры нового открывающегоÑÑ Ð¾ÐºÐ½Ð°, еÑли по крайней мере одно окно уже открыто. По умолчанию новое окно будет открыто в центре Ñкрана в уменьшенном размере. ЕÑли указано значение \"inherit\", размеры нового окна будут равны размерам поÑледнего активного окна. ЕÑли указано значение \"maximized\", окно будет открыто в макÑимальном размере, а еÑли указано значение \"fullscreen\", окно будет открыто в полноÑкранном режиме. Обратите внимание, что Ñтот параметр не влиÑет на первое открываемое окно. Размеры и раÑположение первого окна вÑегда будут Ñовпдаать Ñ Ñ€Ð°Ð·Ð¼ÐµÑ€Ð°Ð¼Ð¸ и раÑположением Ñтого окна перед закрытием.", "window.menuBarVisibility.default": "Меню Ñкрыто только в полноÑкранном режиме.", "window.menuBarVisibility.visible": "Меню вÑегда видимо, даже в полноÑкранном режиме.", "window.menuBarVisibility.toggle": "Меню Ñкрыто, но его можно вывеÑти Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ клавиши ALT.", "window.menuBarVisibility.hidden": "Меню вÑегда Ñкрыто.", "menuBarVisibility": "ОпределÑет видимоÑÑ‚ÑŒ Ñтроки меню. Значение toggle указывает, что Ñтрока меню Ñкрыта и Ð´Ð»Ñ ÐµÐµ вывода нужно один раз нажать клавишу ALT. По умолчанию Ñтрока меню не будет отображатьÑÑ Ñ‚Ð¾Ð»ÑŒÐºÐ¾ в полноÑкранном режиме.", + "enableMenuBarMnemonics": "ЕÑли Ñтот параметр уÑтановлен, главные меню можно открыть Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ Ñочетаний клавиш Ñ ÐºÐ»Ð°Ð²Ð¸ÑˆÐµÐ¹ ALT. Отключение назначенных клавиш позволит ÑвÑзать Ñти ÑÐ¾Ñ‡ÐµÑ‚Ð°Ð½Ð¸Ñ ÐºÐ»Ð°Ð²Ð¸Ñˆ Ñ ÐºÐ»Ð°Ð²Ð¸ÑˆÐµÐ¹ ALT Ñ ÐºÐ¾Ð¼Ð°Ð½Ð´Ð°Ð¼Ð¸ редактора.", "autoDetectHighContrast": "ЕÑли включено, будет выполнÑÑ‚ÑŒÑÑ Ð°Ð²Ñ‚Ð¾Ð¼Ð°Ñ‚Ð¸Ñ‡ÐµÑкий переход к выÑококонтраÑтной теме, еÑли в Windows иÑпользуетÑÑ Ñ‚ÐµÐ¼Ð° выÑокой контраÑтноÑти, или к темной теме при выходе из темы выÑокой контраÑтноÑти Windows.", "titleBarStyle": "ÐаÑтройка внешнего вида заголовка окна. Чтобы применить изменениÑ, потребуетÑÑ Ð¿Ð¾Ð»Ð½Ñ‹Ð¹ перезапуÑк.", "window.nativeTabs": "Включает вкладки окна macOS Sierra. Обратите внимание, что Ð´Ð»Ñ Ð¿Ñ€Ð¸Ð¼ÐµÐ½ÐµÐ½Ð¸Ñ Ñтих изменений потребуетÑÑ Ð¿Ð¾Ð»Ð½Ð°Ñ Ð¿ÐµÑ€ÐµÐ·Ð°Ð³Ñ€ÑƒÐ·ÐºÐ°, и что Ð´Ð»Ñ Ð²Ñех внутренних вкладок будет отключен пользовательÑкий Ñтиль заголовка, еÑли он был наÑтроен.", @@ -56,5 +54,7 @@ "zenMode.hideTabs": "ОпределÑет, будет ли включение режима Zen также Ñкрывать вкладки рабочего меÑта.", "zenMode.hideStatusBar": "ОпределÑет, будет ли включение режима Zen также Ñкрывать Ñтроку ÑоÑтоÑÐ½Ð¸Ñ Ð² нижней чаÑти рабочего меÑта.", "zenMode.hideActivityBar": "ОпределÑет, будет ли при включении режима Zen Ñкрыта панель дейÑтвий в левой чаÑти рабочей облаÑти.", - "zenMode.restore": "ОпределÑет, должно ли окно воÑÑтанавливатьÑÑ Ð² режиме Zen, еÑли закрылоÑÑŒ в режиме Zen." + "zenMode.restore": "ОпределÑет, должно ли окно воÑÑтанавливатьÑÑ Ð² режиме Zen, еÑли закрылоÑÑŒ в режиме Zen.", + "workspaceConfigurationTitle": "Ð Ð°Ð±Ð¾Ñ‡Ð°Ñ Ð¾Ð±Ð»Ð°ÑÑ‚ÑŒ", + "files.exclude.boolean": "Ð¡Ñ‚Ð°Ð½Ð´Ð°Ñ€Ñ‚Ð½Ð°Ñ Ð¼Ð°Ñка, ÑоответÑÑ‚Ð²ÑƒÑŽÑ‰Ð°Ñ Ð¿ÑƒÑ‚Ñм к файлам. Задайте значение true или false, чтобы включить или отключить маÑку." } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json b/i18n/rus/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json new file mode 100644 index 00000000000..b6a2c9c7653 --- /dev/null +++ b/i18n/rus/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json @@ -0,0 +1,26 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "emergencyConfOn": "УÑтановка Ð·Ð½Ð°Ñ‡ÐµÐ½Ð¸Ñ \"on\" Ð´Ð»Ñ Ð¿Ð°Ñ€Ð°Ð¼ÐµÑ‚Ñ€Ð° \"editor.accessibilitySupport\".", + "openingDocs": "ОткрываетÑÑ Ñтраница документации по Ñпециальным возможноÑÑ‚Ñм VS Code.", + "introMsg": "Благодарим за ознакомление Ñо Ñпециальными возможноÑÑ‚Ñми VS Code.", + "status": "СоÑтоÑние:", + "changeConfigToOnMac": "Чтобы включить поÑтоÑнную оптимизацию редактора Ð´Ð»Ñ Ð¸ÑÐ¿Ð¾Ð»ÑŒÐ·Ð¾Ð²Ð°Ð½Ð¸Ñ Ñо ÑредÑтвами Ñ‡Ñ‚ÐµÐ½Ð¸Ñ Ñ Ñкрана, нажмите COMMMAND+E.", + "changeConfigToOnWinLinux": "Чтобы включить поÑтоÑнную оптимизацию редактора Ð´Ð»Ñ Ð¸ÑÐ¿Ð¾Ð»ÑŒÐ·Ð¾Ð²Ð°Ð½Ð¸Ñ Ñо ÑредÑтвами Ñ‡Ñ‚ÐµÐ½Ð¸Ñ Ñ Ñкрана, нажмите CTRL+E.", + "auto_unknown": "Ð’ редакторе наÑтроено определение ÑредÑтва Ñ‡Ñ‚ÐµÐ½Ð¸Ñ Ñ Ñкрана Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ API платформы, но Ñ‚ÐµÐºÑƒÑ‰Ð°Ñ Ñреда Ð²Ñ‹Ð¿Ð¾Ð»Ð½ÐµÐ½Ð¸Ñ Ñто не поддерживает.", + "auto_on": "Редактор автоматичеÑки определил, что ÑредÑтво Ñ‡Ñ‚ÐµÐ½Ð¸Ñ Ñ Ñкрана подключено.", + "auto_off": "Ð’ редакторе наÑтроено автоматичеÑкое определение ÑредÑтва Ñ‡Ñ‚ÐµÐ½Ð¸Ñ Ñ Ñкрана, но ÑÐµÐ¹Ñ‡Ð°Ñ Ñто ÑредÑтво не подключено.", + "configuredOn": "ПоÑтоÑÐ½Ð½Ð°Ñ Ð¾Ð¿Ñ‚Ð¸Ð¼Ð¸Ð·Ð°Ñ†Ð¸ÑŽ редактора Ð´Ð»Ñ Ð¸ÑÐ¿Ð¾Ð»ÑŒÐ·Ð¾Ð²Ð°Ð½Ð¸Ñ Ñо ÑредÑтвами Ñ‡Ñ‚ÐµÐ½Ð¸Ñ Ñ Ñкрана включена. Чтобы ее отключить, измените параметр \"editor.accessibilitySupport\".", + "configuredOff": "Ð”Ð»Ñ Ñ€ÐµÐ´Ð°ÐºÑ‚Ð¾Ñ€Ð° не наÑтроена Ð¾Ð¿Ñ‚Ð¸Ð¼Ð¸Ð·Ð°Ñ†Ð¸Ñ Ð´Ð»Ñ Ð¸ÑÐ¿Ð¾Ð»ÑŒÐ·Ð¾Ð²Ð°Ð½Ð¸Ñ Ñо ÑредÑтвами Ñ‡Ñ‚ÐµÐ½Ð¸Ñ Ñ Ñкрана.", + "tabFocusModeOnMsg": "При нажатии клавиши TAB в текущем редакторе Ñ„Ð¾ÐºÑƒÑ Ð²Ð²Ð¾Ð´Ð° перемеÑтитÑÑ Ð½Ð° Ñледующий Ñлемент, ÑпоÑобный его принÑÑ‚ÑŒ. Чтобы изменить Ñто поведение, нажмите клавишу {0}.", + "tabFocusModeOnMsgNoKb": "При нажатии клавиши TAB в текущем редакторе Ñ„Ð¾ÐºÑƒÑ Ð²Ð²Ð¾Ð´Ð° перемеÑтитÑÑ Ð½Ð° Ñледующий Ñлемент, ÑпоÑобный его принÑÑ‚ÑŒ. Команду {0} ÑÐµÐ¹Ñ‡Ð°Ñ Ð½ÐµÐ²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ выполнить Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ наÑтраиваемого ÑÐ¾Ñ‡ÐµÑ‚Ð°Ð½Ð¸Ñ ÐºÐ»Ð°Ð²Ð¸Ñˆ.", + "tabFocusModeOffMsg": "При нажатии клавиши TAB в текущем редакторе будет вÑтавлен Ñимвол табулÑции. Чтобы изменить Ñто поведение, нажмите клавишу {0}.", + "tabFocusModeOffMsgNoKb": "При нажатии клавиши TAB в текущем редакторе будет вÑтавлен Ñимвол табулÑции. Команду {0} ÑÐµÐ¹Ñ‡Ð°Ñ Ð½ÐµÐ²Ð¾Ð·Ð¼Ð¾Ð¶Ð½Ð¾ выполнить Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ наÑтраиваемого ÑÐ¾Ñ‡ÐµÑ‚Ð°Ð½Ð¸Ñ ÐºÐ»Ð°Ð²Ð¸Ñˆ.", + "openDocMac": "Ðажмите COMMAND+H, чтобы открыть окно браузера Ñ Ð´Ð¾Ð¿Ð¾Ð»Ð½Ð¸Ñ‚ÐµÐ»ÑŒÐ½Ñ‹Ð¼Ð¸ ÑведениÑми о Ñпециальных возможноÑÑ‚ÑÑ… VS Code.", + "openDocWinLinux": "Ðажмите CTRL+H, чтобы открыть окно браузера Ñ Ð´Ð¾Ð¿Ð¾Ð»Ð½Ð¸Ñ‚ÐµÐ»ÑŒÐ½Ñ‹Ð¼Ð¸ ÑведениÑми о Ñпециальных возможноÑÑ‚ÑÑ… VS Code.", + "outroMsg": "Ð’Ñ‹ можете закрыть Ñту подÑказку и вернутьÑÑ Ð² редактор, нажав клавиши ESCAPE или SHIFT+ESCAPE.", + "ShowAccessibilityHelpAction": "Показать Ñправку по Ñпециальным возможноÑÑ‚Ñм" +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json b/i18n/rus/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/rus/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json b/i18n/rus/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json new file mode 100644 index 00000000000..62f29e0311a --- /dev/null +++ b/i18n/rus/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleLocation": "Включить или отключить режим Ñ Ð½ÐµÑколькими курÑорами" +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/debug/browser/debugActions.i18n.json b/i18n/rus/src/vs/workbench/parts/debug/browser/debugActions.i18n.json index 0a2abc6c1db..fca987ec803 100644 --- a/i18n/rus/src/vs/workbench/parts/debug/browser/debugActions.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/debug/browser/debugActions.i18n.json @@ -6,6 +6,7 @@ { "openLaunchJson": "Открыть {0}", "launchJsonNeedsConfigurtion": "ÐаÑтройте или иÑправьте \"launch.json\"", + "noFolderDebugConfig": "Чтобы перейти к раÑширенной конфигурации отладки, Ñначала откройте папку.", "startDebug": "Ðачать отладку", "startWithoutDebugging": "Ðачать без отладки", "selectAndStartDebugging": "Выбрать и начать отладку", diff --git a/i18n/rus/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json b/i18n/rus/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json index 8b6ad71cd4e..aa388e9709f 100644 --- a/i18n/rus/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json @@ -3,4 +3,6 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "noFolderDebugConfig": "Перед раÑширенной наÑтройкой отладки откройте папку." +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json b/i18n/rus/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json index 80a8dddc840..5773174ff02 100644 --- a/i18n/rus/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json @@ -5,16 +5,12 @@ // Do not edit this file. It is machine generated. { "variablesSection": "Раздел переменных", - "variables": "Переменные", "variablesAriaTreeLabel": "Отладка переменных", "expressionsSection": "Раздел выражений", - "watch": "Контрольное значение", "watchAriaTreeLabel": "Отладка выражений контрольных значений", "callstackSection": "Раздел Ñтека вызовов", "debugStopped": "ПриоÑтановлено на {0}", - "callStack": "Стек вызовов", "callStackAriaLabel": "Отладка Ñтека вызовов", "breakpointsSection": "Раздел точек оÑтанова", - "breakpoints": "Точки оÑтанова", "breakpointsAriaTreeLabel": "Отладка точек оÑтанова" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json b/i18n/rus/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json index c4b97bcfe10..3f8d10ed5bd 100644 --- a/i18n/rus/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json @@ -6,5 +6,6 @@ { "copyValue": "Копировать значение", "copy": "Копировать", + "copyAll": "Копировать вÑе", "copyStackTrace": "Копировать Ñтек вызовов" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json b/i18n/rus/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json index fa2fb421cfc..bf63a86ed4a 100644 --- a/i18n/rus/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "statusBarDebuggingBackground": "Цвет фона панели ÑоÑтоÑÐ½Ð¸Ñ Ð¿Ñ€Ð¸ отладке программы. Панель ÑоÑтоÑÐ½Ð¸Ñ Ð¿Ð¾ÐºÐ°Ð·Ð°Ð½Ð° внизу окна." + "statusBarDebuggingBackground": "Цвет фона панели ÑоÑтоÑÐ½Ð¸Ñ Ð¿Ñ€Ð¸ отладке программы. Панель ÑоÑтоÑÐ½Ð¸Ñ Ð¿Ð¾ÐºÐ°Ð·Ð°Ð½Ð° внизу окна.", + "statusBarDebuggingForeground": "Цвет переднего плана Ñтроки ÑоÑтоÑÐ½Ð¸Ñ Ð¿Ñ€Ð¸ отладке программы. Строка ÑоÑтоÑÐ½Ð¸Ñ Ñ€Ð°Ñположена в нижней чаÑти окна." } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json b/i18n/rus/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json index 90a5d4e861e..109e9178c2d 100644 --- a/i18n/rus/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json @@ -7,6 +7,7 @@ "debugAdapterBinNotFound": "ИÑполнÑемый файл адаптера отладки \"{0}\" не ÑущеÑтвует.", "debugAdapterCannotDetermineExecutable": "Ðевозможно определить иÑполнÑемый файл Ð´Ð»Ñ Ð°Ð´Ð°Ð¿Ñ‚ÐµÑ€Ð° отладки \"{0}\".", "debugType": "Тип конфигурации.", + "debugTypeNotRecognised": "Ðе удаетÑÑ Ñ€Ð°Ñпознать тип отладки. УбедитеÑÑŒ, что ÑоответÑтвующее раÑширение отладки уÑтановлено и включено.", "node2NotSupported": "Значение \"node2\" больше не поддерживаетÑÑ; иÑпользуйте \"node\" и задайте Ð´Ð»Ñ Ð°Ñ‚Ñ€Ð¸Ð±ÑƒÑ‚Ð° \"protocol\" значение \"inspector\".", "debugName": "Ð˜Ð¼Ñ ÐºÐ¾Ð½Ñ„Ð¸Ð³ÑƒÑ€Ð°Ñ†Ð¸Ð¸; отображаетÑÑ Ð² раÑкрывающемÑÑ Ð¼ÐµÐ½ÑŽ конфигурации запуÑка.", "debugRequest": "ЗапроÑите тип конфигурации. Возможные типы: \"запуÑк\" и \"подключение\".", diff --git a/i18n/rus/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json b/i18n/rus/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json index 4a07fdffeba..c7a704d9506 100644 --- a/i18n/rus/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json @@ -4,6 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "previousEditPoint": "Emmet: Ð¿Ñ€ÐµÐ´Ñ‹Ð´ÑƒÑ‰Ð°Ñ Ñ‚Ð¾Ñ‡ÐºÐ° изменениÑ", - "nextEditPoint": "Emmet: ÑÐ»ÐµÐ´ÑƒÑŽÑ‰Ð°Ñ Ñ‚Ð¾Ñ‡ÐºÐ° изменениÑ" + "previousEditPoint": "Emmet: перейти к предыдущей точке изменениÑ", + "nextEditPoint": "Emmet: перейти к Ñледующей точке изменениÑ" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json b/i18n/rus/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json index b632b35fef6..92ea6283604 100644 --- a/i18n/rus/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json @@ -9,5 +9,6 @@ "emmetPreferences": "ÐаÑтройки, которые иÑпользуютÑÑ Ð´Ð»Ñ Ð¸Ð·Ð¼ÐµÐ½ÐµÐ½Ð¸Ñ Ð¿Ð¾Ð²ÐµÐ´ÐµÐ½Ð¸Ñ Ð½ÐµÐºÐ¾Ñ‚Ð¾Ñ€Ñ‹Ñ… дейÑтвий и ÑопоÑтавителей Emmet.", "emmetSyntaxProfiles": "Задайте профиль Ð´Ð»Ñ ÑƒÐºÐ°Ð·Ð°Ð½Ð½Ð¾Ð³Ð¾ ÑинтакÑиÑа или иÑпользуйте Ñвой ÑобÑтвенный профиль Ñ Ð¾Ð¿Ñ€ÐµÐ´ÐµÐ»ÐµÐ½Ð½Ñ‹Ð¼Ð¸ правилами.", "emmetExclude": "МаÑÑив Ñзыков, в которых не должны развертыватьÑÑ ÑÐ¾ÐºÑ€Ð°Ñ‰ÐµÐ½Ð¸Ñ Emmet.", - "emmetExtensionsPath": "Путь к папке, Ñодержащей профили Emmet, фрагменты кода и наÑтройки" + "emmetExtensionsPath": "Путь к папке, Ñодержащей профили Emmet, фрагменты кода и наÑтройки", + "useNewEmmet": "Попробуйте новые модули emmet (которые в конечном итоге заменÑÑ‚ уÑтаревшую библиотеку emmet), чтобы ознакомитьÑÑ Ñо вÑеми функциÑми emmet." } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json b/i18n/rus/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json index c74eca64051..fd46efd9954 100644 --- a/i18n/rus/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json @@ -24,6 +24,10 @@ "default": "По умолчанию", "debuggers": "Отладчики ({0})", "debugger name": "ИмÑ", + "views": "ПредÑÑ‚Ð°Ð²Ð»ÐµÐ½Ð¸Ñ ({0})", + "view id": "Идентификатор", + "view name": "ИмÑ", + "view location": "Где", "themes": "Темы ({0})", "JSON Validation": "Проверка JSON ({0})", "commands": "Команды ({0})", diff --git a/i18n/rus/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json b/i18n/rus/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json index 34a96c349af..b01a2493859 100644 --- a/i18n/rus/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json @@ -22,6 +22,8 @@ "disableGloballyAction": "Ð’Ñегда", "disableAction": "Отключить", "checkForUpdates": "Проверка обновлений", + "enableAutoUpdate": "Включить автоматичеÑкое обновление раÑширений", + "disableAutoUpdate": "Отключить автоматичеÑкое обновление раÑширений", "updateAll": "Обновить вÑе раÑширениÑ", "reloadAction": "Перезагрузка", "postUpdateTooltip": "Обновление окна Ð´Ð»Ñ Ð¾Ð±Ð½Ð¾Ð²Ð»ÐµÐ½Ð¸Ñ", @@ -44,6 +46,8 @@ "showWorkspaceRecommendedExtensions": "Показать рекомендуемые раÑÑˆÐ¸Ñ€ÐµÐ½Ð¸Ñ Ñ€Ð°Ð±Ð¾Ñ‡ÐµÐ¹ облаÑти", "showRecommendedKeymapExtensions": "Показать рекомендуемые раÑкладки клавиатуры", "showRecommendedKeymapExtensionsShort": "РаÑкладки клавиатуры", + "showLanguageExtensions": "Показать раÑÑˆÐ¸Ñ€ÐµÐ½Ð¸Ñ Ñзыка", + "showLanguageExtensionsShort": "РаÑÑˆÐ¸Ñ€ÐµÐ½Ð¸Ñ Ñзыка", "configureWorkspaceRecommendedExtensions": "ÐаÑтроить рекомендуемые раÑÑˆÐ¸Ñ€ÐµÐ½Ð¸Ñ (Ñ€Ð°Ð±Ð¾Ñ‡Ð°Ñ Ð¾Ð±Ð»Ð°ÑÑ‚ÑŒ)", "ConfigureWorkspaceRecommendations.noWorkspace": "Рекомендации доÑтупны только Ð´Ð»Ñ Ð¿Ð°Ð¿ÐºÐ¸ рабочей облаÑти.", "OpenExtensionsFile.failed": "Ðе удаетÑÑ Ñоздать файл \"extensions.json\" в папке \".vscode\" ({0}).", @@ -51,5 +55,8 @@ "disableAll": "Отключить вÑе уÑтановленные раÑширениÑ", "disableAllWorkspace": "Отключить вÑе уÑтановленные раÑÑˆÐ¸Ñ€ÐµÐ½Ð¸Ñ Ð´Ð»Ñ Ñтой рабочей облаÑти", "enableAll": "Включить вÑе уÑтановленные раÑширениÑ", - "enableAllWorkspace": "Включить вÑе уÑтановленные раÑÑˆÐ¸Ñ€ÐµÐ½Ð¸Ñ Ð´Ð»Ñ Ñтой рабочей облаÑти" + "enableAllWorkspace": "Включить вÑе уÑтановленные раÑÑˆÐ¸Ñ€ÐµÐ½Ð¸Ñ Ð´Ð»Ñ Ñтой рабочей облаÑти", + "extensionButtonProminentBackground": "Цвет фона кнопок, ÑоответÑтвующих оÑновным дейÑтвиÑм раÑÑˆÐ¸Ñ€ÐµÐ½Ð¸Ñ (например, кнопка \"УÑтановить\").", + "extensionButtonProminentForeground": "Цвет переднего плана кнопок, ÑоответÑтвующих оÑновным дейÑтвиÑм раÑÑˆÐ¸Ñ€ÐµÐ½Ð¸Ñ (например, кнопка \"УÑтановить\").", + "extensionButtonProminentHoverBackground": "Цвет фона кнопок, ÑоответÑтвующих оÑновным дейÑтвиÑм раÑширениÑ, при наведении мыши (например, кнопка \"УÑтановить\")." } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json b/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json index e3fabddede9..d91b6f99270 100644 --- a/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json @@ -9,6 +9,8 @@ "neverShowAgain": "Больше не показывать", "close": "Закрыть", "workspaceRecommended": "Эта Ñ€Ð°Ð±Ð¾Ñ‡Ð°Ñ Ð¾Ð±Ð»Ð°ÑÑ‚ÑŒ включает рекомендации по раÑширениÑм.", + "ignoreExtensionRecommendations": "Ð’Ñ‹ дейÑтвительно хотите проигнорировать вÑе рекомендации по раÑширениÑм?", + "ignoreAll": "Да, игнорировать вÑе", "no": "Ðет", "cancel": "Отмена" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json b/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json index 2796f4f1c1f..957fb1a214b 100644 --- a/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json @@ -10,5 +10,6 @@ "extensions": "РаÑширениÑ", "view": "ПроÑмотреть", "extensionsConfigurationTitle": "РаÑширениÑ", - "extensionsAutoUpdate": "ÐвтоматичеÑки обновлÑÑ‚ÑŒ раÑширениÑ" + "extensionsAutoUpdate": "ÐвтоматичеÑки обновлÑÑ‚ÑŒ раÑширениÑ", + "extensionsIgnoreRecommendations": "Игнорировать рекомендации по раÑширениÑм" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json index 82ee62547a4..0d3592d30b4 100644 --- a/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -4,8 +4,10 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "disableOtherKeymapsConfirmation": "Отключить другие раÑкладки клавиатуры ({0}), чтобы избежать конфликта между наÑтраиваемыми ÑочетаниÑми клавиш?", "yes": "Да", "no": "Ðет", + "betterMergeDisabled": "Ð’ текущую верÑию вÑтроено ÑредÑтво ÑлиÑÐ½Ð¸Ñ Ñ Ð»ÑƒÑ‡ÑˆÐµÐ¹ функциональноÑтью. УÑтановленное раÑширение было отключено и не может быть удалено.", "uninstall": "Удаление", "later": "Позже" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/rus/src/vs/workbench/parts/files/browser/files.contribution.i18n.json index 6c404cd1796..6c00f987837 100644 --- a/i18n/rus/src/vs/workbench/parts/files/browser/files.contribution.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -16,6 +16,7 @@ "associations": "ÐаÑтройте ÑопоÑÑ‚Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ñ„Ð°Ð¹Ð»Ð¾Ð² Ñ Ñзыками (например, \"*.extension\": \"html\"). У них будет приоритет перед заданными по умолчанию ÑопоÑтавлениÑми уÑтановленных Ñзыков.", "encoding": "Кодировка набора Ñимволов по умолчанию, иÑÐ¿Ð¾Ð»ÑŒÐ·ÑƒÐµÐ¼Ð°Ñ Ð¿Ñ€Ð¸ чтении и запиÑи файлов", "autoGuessEncoding": "ЕÑли параметр включен, производитÑÑ Ð¿Ð¾Ð¿Ñ‹Ñ‚ÐºÐ° определить кодировку набора Ñимволов при открытии файлов", + "eol": "Символ конца Ñтроки по умолчанию. ИÑпользуйте \\n Ð´Ð»Ñ LF и \\r\\n Ð´Ð»Ñ CRLF.", "trimTrailingWhitespace": "ЕÑли Ñтот параметр включен, при Ñохранении файла будут удалены концевые пробелы.", "insertFinalNewline": "ЕÑли Ñтот параметр включен, при Ñохранении файла в его конец вÑтавлÑетÑÑ Ñ„Ð¸Ð½Ð°Ð»ÑŒÐ½Ð°Ñ Ð½Ð¾Ð²Ð°Ñ Ñтрока.", "files.autoSave.off": "\"ГрÑзный\" файл не ÑохранÑетÑÑ Ð°Ð²Ñ‚Ð¾Ð¼Ð°Ñ‚Ð¸Ñ‡ÐµÑки.", @@ -26,6 +27,7 @@ "autoSaveDelay": "ОпределÑет задержку в мÑ, поÑле которой измененный файл ÑохранÑетÑÑ Ð°Ð²Ñ‚Ð¾Ð¼Ð°Ñ‚Ð¸Ñ‡ÐµÑки. ДейÑтвует, только еÑли параметр \"files.autoSave\" имеет значение \"{0}\".", "watcherExclude": "ÐаÑтройте Ñтандартные маÑки путей файлов, чтобы иÑключить их из ÑпиÑка отÑлеживаемых файлов. ПоÑле Ð¸Ð·Ð¼ÐµÐ½ÐµÐ½Ð¸Ñ Ñтого параметра потребуетÑÑ Ð¿ÐµÑ€ÐµÐ·Ð°Ð³Ñ€ÑƒÐ·ÐºÐ°. При отображении ÑÐ¾Ð¾Ð±Ñ‰ÐµÐ½Ð¸Ñ \"Код потреблÑет большое количеÑтво процеÑÑорного времени при запуÑке\" вы можете иÑключить большие папки, чтобы уменьшить первоначальную загрузку.", "hotExit.off": "Отключите \"горÑчий\" выход.", + "hotExit.onExit": "Ð¤ÑƒÐ½ÐºÑ†Ð¸Ñ \"горÑчий выход\" будет активирована при закрытии приложениÑ, то еÑÑ‚ÑŒ при закрытии поÑледнего окна в Windows или Linux или при активации команды workbench.action.quit (палитра команд, наÑтраиваемое Ñочетание клавиш, меню). Ð’Ñе окна Ñ Ñ€ÐµÐ·ÐµÑ€Ð²Ð½Ñ‹Ð¼Ð¸ копиÑми будут воÑÑтановлены при Ñледующем запуÑке.", "hotExit": "ОпределÑет, запоминаютÑÑ Ð»Ð¸ неÑохраненные файлы между ÑеанÑами. Ð’ Ñтом Ñлучае приглашение на их Ñохранение при выходе из редактора не поÑвлÑетÑÑ.", "defaultLanguage": "Режим Ñзыка по умолчанию, который назначаетÑÑ Ð½Ð¾Ð²Ñ‹Ð¼ файлам.", "editorConfigurationTitle": "Редактор", diff --git a/i18n/rus/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json b/i18n/rus/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json index 6926e676b12..eaee6522dac 100644 --- a/i18n/rus/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json @@ -5,7 +5,5 @@ // Do not edit this file. It is machine generated. { "explorerSection": "Раздел проводника", - "noWorkspace": "Ðет открытой папки", - "noWorkspaceHelp": "Ð’Ñ‹ еще не открыли папку.", "openFolder": "Открыть папку" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json b/i18n/rus/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json index 57e8e68aedc..908990efe61 100644 --- a/i18n/rus/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json @@ -4,8 +4,8 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "openEditosrSection": "Раздел открытых редакторов", "openEditors": "Открытые редакторы", + "openEditosrSection": "Раздел открытых редакторов", "treeAriaLabel": "Открытые редакторы: ÑпиÑок активных файлов", "dirtyCounter": "Ðе Ñохранено: {0}" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/rus/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json index 5ac046256bd..c5024f1f1d0 100644 --- a/i18n/rus/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -9,5 +9,7 @@ "prof.message": "Профили уÑпешно Ñозданы.", "prof.detail": "Создайте проблему и вручную вложите Ñледующие файлы:\n{0}", "prof.restartAndFileIssue": "Создать проблему и выполнить перезапуÑк", - "prof.restart": "ПерезапуÑтить" + "prof.restart": "ПерезапуÑтить", + "prof.thanks": "СпаÑибо за помощь.", + "prof.detail.restart": "Ð”Ð»Ñ Ð¿Ñ€Ð¾Ð´Ð¾Ð»Ð¶ÐµÐ½Ð¸Ñ Ñ€Ð°Ð±Ð¾Ñ‚Ñ‹ Ñ '{0}' необходимо еще раз перезагрузить ÑиÑтему. Благодарим Ð²Ð°Ñ Ð·Ð° учаÑтие." } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/rus/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json index 92f25868855..41c45ab216e 100644 --- a/i18n/rus/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -5,5 +5,7 @@ // Do not edit this file. It is machine generated. { "defineKeybinding.start": "Определить назначение клавиш", - "defineKeybinding.kbLayoutErrorMessage": "Ð’Ñ‹ не Ñможете нажать Ñто Ñочетание клавиш в текущей раÑкладке клавиатуры." + "defineKeybinding.kbLayoutErrorMessage": "Ð’Ñ‹ не Ñможете нажать Ñто Ñочетание клавиш в текущей раÑкладке клавиатуры.", + "defineKeybinding.kbLayoutLocalAndUSMessage": "**{0}** Ð´Ð»Ñ Ñ‚ÐµÐºÑƒÑ‰ÐµÐ¹ раÑкладки клавиатуры (**{1}** Ð´Ð»Ñ Ñтандартной раÑкладки клавиатуры \"ÐнглийÑкий, СШÐ\")", + "defineKeybinding.kbLayoutLocalMessage": "**{0}** Ð´Ð»Ñ Ñ‚ÐµÐºÑƒÑ‰ÐµÐ¹ раÑкладки клавиатуры." } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json b/i18n/rus/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json index 234e294922c..702472aecfb 100644 --- a/i18n/rus/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json @@ -4,6 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "errorInvalidConfiguration": "Ðе удаетÑÑ Ð·Ð°Ð¿Ð¸Ñать параметры. УÑтраните ошибки и Ð¿Ñ€ÐµÐ´ÑƒÐ¿Ñ€ÐµÐ¶Ð´ÐµÐ½Ð¸Ñ Ð² файле и повторите попытку.", "editTtile": "Изменить", "replaceDefaultValue": "Заменить в параметрах", "copyDefaultValue": "Копировать в параметры", diff --git a/i18n/rus/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json b/i18n/rus/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json index f6f0bf572b2..12bcf3ccba9 100644 --- a/i18n/rus/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "showTriggerActions": "Показать вÑе команды", + "showCommands.label": "Палитра команд...", "entryAriaLabelWithKey": "{0}, {1}, команды", "entryAriaLabel": "{0}, команды", "canNotRun": "Выполнить команду {0} отÑюда невозможно.", diff --git a/i18n/rus/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json b/i18n/rus/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json new file mode 100644 index 00000000000..33c1e2c5ad7 --- /dev/null +++ b/i18n/rus/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "relaunchMessage": "ПоÑле Ð¸Ð·Ð¼ÐµÐ½ÐµÐ½Ð¸Ñ Ð¿Ð°Ñ€Ð°Ð¼ÐµÑ‚Ñ€Ð° необходима выполнить перезагрузку, чтобы Ð¸Ð·Ð¼ÐµÐ½ÐµÐ½Ð¸Ñ Ð²Ñтупили в Ñилу.", + "relaunchDetail": "Ðажмите кнопку \"Перезагрузить\", чтобы перезагрузить {0} и включить параметр.", + "restart": "ПерезапуÑтить" +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/rus/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json index 8b6ad71cd4e..ce6c4c198e5 100644 --- a/i18n/rus/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -3,4 +3,8 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. -{} \ No newline at end of file +{ + "editorGutterModifiedBackground": "Цвет фона полей редактора Ð´Ð»Ñ Ð¸Ð·Ð¼ÐµÐ½ÐµÐ½Ð½Ñ‹Ñ… Ñтрок.", + "editorGutterAddedBackground": "Цвет фона полей редактора Ð´Ð»Ñ Ð´Ð¾Ð±Ð°Ð²Ð»ÐµÐ½Ð½Ñ‹Ñ… Ñтрок.", + "editorGutterDeletedBackground": "Цвет фона полей редактора Ð´Ð»Ñ ÑƒÐ´Ð°Ð»ÐµÐ½Ð½Ñ‹Ñ… Ñтрок." +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json b/i18n/rus/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json index 029a91dd121..ba48b09e263 100644 --- a/i18n/rus/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json @@ -5,6 +5,7 @@ // Do not edit this file. It is machine generated. { "toggleGitViewlet": "Показать GIT", + "installAdditionalSCMProviders": "УÑтановить дополнительных поÑтавщиков SCM...", "source control": "СиÑтема ÑƒÐ¿Ñ€Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ð²ÐµÑ€ÑиÑми", "toggleSCMViewlet": "Показать SCM", "view": "ПроÑмотреть" diff --git a/i18n/rus/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json b/i18n/rus/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json index 0d1ad24f725..f345f2df7fa 100644 --- a/i18n/rus/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "installAdditionalSCMProviders": "УÑтановить дополнительных поÑтавщиков SCM...", "switch provider": "Переключить поÑтавщик SCM..." } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json b/i18n/rus/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json index 845c4f038e9..cd394a2c256 100644 --- a/i18n/rus/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json @@ -6,5 +6,7 @@ { "searchMatches": "Ðайдено ÑоответÑтвий: {0}", "searchMatch": "Ðайдено ÑоответÑтвие: {0}", - "fileMatchAriaLabel": "Совпадений в файле {1} папки {2}: {0}, результат поиÑка" + "fileMatchAriaLabel": "Совпадений в файле {1} папки {2}: {0}, результат поиÑка", + "replacePreviewResultAria": "Заменить термин {0} на {1} в Ñтолбце {2} и Ñтроке {3}", + "searchResultAria": "Обнаружен термин {0} в Ñтолбце {1} и Ñтроке {2}" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json b/i18n/rus/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json index d4cbde5d134..1ed22c6e056 100644 --- a/i18n/rus/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json @@ -9,5 +9,6 @@ "vscode.extension.contributes.snippets-path": "Путь к файлу фрагментов. Путь указываетÑÑ Ð¾Ñ‚Ð½Ð¾Ñительно папки раÑÑˆÐ¸Ñ€ÐµÐ½Ð¸Ñ Ð¸ обычно начинаетÑÑ Ñ \"./snippets/\".", "invalid.language": "ÐеизвеÑтный Ñзык в contributes.{0}.language. Указанное значение: {1}", "invalid.path.0": "Ð’ contributes.{0}.path требуетÑÑ Ñтрока. Указанное значение: {1}", - "invalid.path.1": "contributes.{0}.path ({1}) должен был быть включен в папку раÑÑˆÐ¸Ñ€ÐµÐ½Ð¸Ñ ({2}). Это может Ñделать раÑширение непереноÑимым." + "invalid.path.1": "contributes.{0}.path ({1}) должен был быть включен в папку раÑÑˆÐ¸Ñ€ÐµÐ½Ð¸Ñ ({2}). Это может Ñделать раÑширение непереноÑимым.", + "badVariableUse": "Похоже, во фрагменте \"{0}\" перепутаны переменные и заполнители. Дополнительные ÑÐ²ÐµÐ´ÐµÐ½Ð¸Ñ Ñм. на Ñтранице https://code.visualstudio.com/docs/editor/userdefinedsnippets#_snippet-syntax." } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json b/i18n/rus/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json index 328405d58a0..cca07302e3c 100644 --- a/i18n/rus/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json @@ -11,6 +11,6 @@ "snippetSchema.json.default": "ПуÑтой фрагмент", "snippetSchema.json": "ÐаÑтройка фрагмента пользователÑ", "snippetSchema.json.prefix": "ПрефикÑ, иÑпользуемый при выборе фрагмента в Intellisense.", - "snippetSchema.json.body": "Содержимое фрагмента. ИÑпользуйте \"${id}\", \"${id:label}\", \"${1:label}\" Ð´Ð»Ñ Ð¿ÐµÑ€ÐµÐ¼ÐµÐ½Ð½Ñ‹Ñ… и \"$0\", \"$1\" Ð´Ð»Ñ Ð¿Ð¾Ð»Ð¾Ð¶ÐµÐ½Ð¸Ð¹ курÑора", + "snippetSchema.json.body": "Содержимое фрагмента. ИÑпользуйте '$1', '${1:defaultText}' Ð´Ð»Ñ Ð¾Ð¿Ñ€ÐµÐ´ÐµÐ»ÐµÐ½Ð¸Ñ Ð¿Ð¾Ð»Ð¾Ð¶ÐµÐ½Ð¸Ñ ÐºÑƒÑ€Ñора и '$0' Ð´Ð»Ñ Ð¾Ð¿Ñ€ÐµÐ´ÐµÐ»ÐµÐ½Ð¸Ñ ÐºÐ¾Ð½ÐµÑ‡Ð½Ð¾Ð³Ð¾ Ð¿Ð¾Ð»Ð¾Ð¶ÐµÐ½Ð¸Ñ ÐºÑƒÑ€Ñора. Ð”Ð»Ñ Ð²Ñтавки переменных иÑпользуйте ÑинтакÑÐ¸Ñ '${varName}' и '${varName:defaultText}', например, \"Это файл: $TM_FILENAME\".", "snippetSchema.json.description": "ОпиÑание фрагмента." } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json b/i18n/rus/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json new file mode 100644 index 00000000000..87ed9681f0c --- /dev/null +++ b/i18n/rus/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "helpUs": "Помогите нам улучшить поддержку {0}", + "takeShortSurvey": "Пройдите краткий опроÑ", + "remindLater": "Ðапомнить мне позже", + "neverAgain": "Больше не показывать" +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json b/i18n/rus/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json new file mode 100644 index 00000000000..10c206f9d2f --- /dev/null +++ b/i18n/rus/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "surveyQuestion": "Ð’Ð°Ñ Ð½Ðµ затруднит пройти краткий опроÑ?", + "takeSurvey": "Пройти опроÑ", + "remindLater": "Ðапомнить мне позже", + "neverAgain": "Больше не показывать" +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json b/i18n/rus/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json new file mode 100644 index 00000000000..2037e5496b9 --- /dev/null +++ b/i18n/rus/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noTasksMatching": "Ðет ÑоответÑтвующих задач" +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/rus/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json index 2f8e368102c..5a8464f78ea 100644 --- a/i18n/rus/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -4,5 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "entryAriaLabel": "{0}, задачи" + "entryAriaLabel": "{0}, задачи", + "customizeTask": "ÐаÑтроить задачу" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json b/i18n/rus/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json new file mode 100644 index 00000000000..2037e5496b9 --- /dev/null +++ b/i18n/rus/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noTasksMatching": "Ðет ÑоответÑтвующих задач" +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/rus/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json index 7802fd33b5d..90eadea7cc8 100644 --- a/i18n/rus/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -12,5 +12,6 @@ "ConfigurationParser.invalidVaraibleReference": "Ошибка: недопуÑÑ‚Ð¸Ð¼Ð°Ñ ÑÑылка на problemMatcher: {0}\n", "ConfigurationParser.noTaskName": "Ошибка: задачи должны предоÑтавлÑÑ‚ÑŒ ÑвойÑтво taskName. Задача будет проигнорирована.\n{0}\n", "taskConfiguration.shellArgs": "Предупреждение: задача \"{0}\" ÑвлÑетÑÑ ÐºÐ¾Ð¼Ð°Ð½Ð´Ð¾Ð¹ оболочки, и Ð¸Ð¼Ñ ÐºÐ¾Ð¼Ð°Ð½Ð´Ñ‹ или одного из ее аргументов включает пробелы без escape-поÑледовательноÑти. Чтобы обеÑпечить правильную раÑÑтановку кавычек в командной Ñтроке, объедините аргументы в команде.", + "taskConfiguration.noCommandOrDependsOn": "Ошибка: в задаче \"{0}\" не указаны ни команда, ни ÑвойÑтво dependsOn. Задача будет проигнорирована. Определение задачи:\n{1}", "taskConfiguration.noCommand": "Ошибка: задача \"{0}\" не определÑет команду. Задача будет игнорироватьÑÑ. Ее определение:\n{1}" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json b/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json index b2e6776ffda..f149850fd4c 100644 --- a/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json @@ -7,6 +7,7 @@ "JsonSchema.options": "Дополнительные параметры команды", "JsonSchema.options.cwd": "Текущий рабочий каталог выполнÑемой программы или ÑценариÑ. ЕÑли Ñтот параметр опущен, иÑпользуетÑÑ ÐºÐ¾Ñ€Ð½ÐµÐ²Ð¾Ð¹ каталог текущей рабочей облаÑти Code.", "JsonSchema.options.env": "Среда выполнÑемой программы или оболочки. ЕÑли Ñтот параметр опущен, иÑпользуетÑÑ Ñреда родительÑкого процеÑÑа.", + "JsonSchema.shellConfiguration": "Задает иÑпользуемую оболочку.", "JsonSchema.shell.executable": "ИÑÐ¿Ð¾Ð»ÑŒÐ·ÑƒÐµÐ¼Ð°Ñ Ð¾Ð±Ð¾Ð»Ð¾Ñ‡ÐºÐ°.", "JsonSchema.shell.args": "Ðргументы оболочки.", "JsonSchema.command": "ВыполнÑÐµÐ¼Ð°Ñ ÐºÐ¾Ð¼Ð°Ð½Ð´Ð°. Это может быть внешнÑÑ Ð¿Ñ€Ð¾Ð³Ñ€Ð°Ð¼Ð¼Ð° или команда оболочки.", diff --git a/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json b/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json index 02c57964831..e387db19de6 100644 --- a/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json @@ -5,6 +5,8 @@ // Do not edit this file. It is machine generated. { "JsonSchema.version": "Ðомер верÑии конфигурации", + "JsonSchema._runner": "СредÑтво запуÑка завершило работу. ИÑпользуйте официальное ÑвойÑтво ÑредÑтва запуÑка", + "JsonSchema.runner": "ОпределÑет, Ñледует ли запуÑтить задачу в качеÑтве процеÑÑа Ñ Ð¾Ñ‚Ð¾Ð±Ñ€Ð°Ð¶ÐµÐ½Ð¸ÐµÐ¼ выходных данных задачи в окне вывода или в терминале.", "JsonSchema.windows": "ÐаÑтройка команд Windows", "JsonSchema.mac": "ÐаÑтройка команд Mac", "JsonSchema.linux": "ÐаÑтройка команд Linux", diff --git a/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json index f74df060945..41c0b2f756a 100644 --- a/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -7,6 +7,10 @@ "JsonSchema.shell": "Указывает, ÑвлÑетÑÑ Ð»Ð¸ команда командой оболочки или внешней программой. ЕÑли опущено, значение по умолчанию — false.", "JsonSchema.tasks.dependsOn.string": "Ð”Ñ€ÑƒÐ³Ð°Ñ Ð·Ð°Ð´Ð°Ñ‡Ð°, от которой завиÑит Ñта задача.", "JsonSchema.tasks.dependsOn.array": "Другие задачи, от которых завиÑит Ñта задача.", + "JsonSchema.tasks.group": "ОпределÑет, к какой группе Ð²Ñ‹Ð¿Ð¾Ð»Ð½ÐµÐ½Ð¸Ñ Ð¿Ñ€Ð¸Ð½Ð°Ð´Ð»ÐµÐ¶Ð¸Ñ‚ Ñта задача. ЕÑли параметр не указан, задача не принадлежит ни к одной из групп.", + "JsonSchema.tasks.type": "ОпределÑет, выполнÑетÑÑ Ð»Ð¸ задача в виде процеÑÑа или в виде команды оболочки. Значение по умолчанию — \"процеÑÑ\".", + "JsonSchema.version": "Ðомер верÑии конфигурации.", + "JsonSchema.tasks.customize": "ПользовательÑÐºÐ°Ñ Ð·Ð°Ð´Ð°Ñ‡Ð°, ÐºÐ¾Ñ‚Ð¾Ñ€Ð°Ñ Ð±ÑƒÐ´ÐµÑ‚ наÑтраиватьÑÑ.", "JsonSchema.windows": "ÐаÑтройка команд Windows", "JsonSchema.mac": "ÐаÑтройка команд Mac", "JsonSchema.linux": "ÐаÑтройка команд Linux" diff --git a/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json b/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json index 031f694786c..53e80072245 100644 --- a/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json @@ -18,10 +18,12 @@ "problems": "Проблемы", "manyMarkers": "99+", "tasks": "Задачи", + "TaskSystem.noHotSwap": "Чтобы изменить подÑиÑтему Ð²Ñ‹Ð¿Ð¾Ð»Ð½ÐµÐ½Ð¸Ñ Ð·Ð°Ð´Ð°Ñ‡, нужно перезапуÑтить VS Code. Изменение игнорируетÑÑ.", "TaskService.noBuildTask": "Задача Ñборки не определена. Отметьте задачу Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ \"isBuildCommand\" в файле tasks.json.", "TaskService.noTestTask": "Задача теÑта не определена. Отметьте задачу Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ \"isTestCommand\" в файле tasks.json.", "TaskServer.noTask": "Ð—Ð°Ð¿Ñ€Ð¾ÑˆÐµÐ½Ð½Ð°Ñ Ð·Ð°Ð´Ð°Ñ‡Ð° {0} Ð´Ð»Ñ Ð²Ñ‹Ð¿Ð¾Ð»Ð½ÐµÐ½Ð¸Ñ Ð½Ðµ найдена.", - "TaskSystem.activeSame": "Задача уже активна и находитÑÑ Ð² режиме наблюдениÑ. Чтобы завершить задачу, выполните команду \"F1 > terminate task\"", + "customizeParseErrors": "Ð’ конфигурации текущей задачи еÑÑ‚ÑŒ ошибки. ИÑправьте ошибки перед изменением задачи.", + "moreThanOneBuildTask": "Ð’ файле tasks.json определено неÑколько задач Ñборки. ВыполнÑетÑÑ Ð¿ÐµÑ€Ð²Ð°Ñ Ð·Ð°Ð´Ð°Ñ‡Ð°.\n", "TaskSystem.active": "Уже выполнÑетÑÑ Ð·Ð°Ð´Ð°Ñ‡Ð°. Завершите ее, прежде чем выполнÑÑ‚ÑŒ другую задачу.", "TaskSystem.restartFailed": "Ðе удалоÑÑŒ завершить и перезапуÑтить задачу {0}", "TaskSystem.configurationErrors": "Ошибка: в конфигурации указанной задачи при проверке были выÑвлены ошибки, и ее невозможно иÑпользовать. Сначала уÑтраните ошибки.", diff --git a/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json b/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json index 32514c87953..922550c51cb 100644 --- a/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json @@ -6,5 +6,7 @@ { "TerminalTaskSystem.unknownError": "При выполнении задачи произошла неизвеÑÑ‚Ð½Ð°Ñ Ð¾ÑˆÐ¸Ð±ÐºÐ°. ПодробноÑти Ñм. в журнале выходных данных задач.", "TerminalTaskSystem.terminalName": "Задача — {0}", - "TerminalTaskSystem": "Ðевозможно выполнить команду оболочки на диÑке UNC." + "reuseTerminal": "Терминал будет повторно иÑпользоватьÑÑ Ð·Ð°Ð´Ð°Ñ‡Ð°Ð¼Ð¸. Чтобы закрыть его, нажмите любую клавишу.", + "TerminalTaskSystem": "Ðевозможно выполнить команду оболочки на диÑке UNC.", + "unkownProblemMatcher": "Ðе удаетÑÑ Ñ€Ð°Ð·Ñ€ÐµÑˆÐ¸Ñ‚ÑŒ ÑопоÑтавитель проблем {0}. СопоÑтавитель будет проигнорирован" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json b/i18n/rus/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json index 6aeff4e87a2..2e6dfe20c18 100644 --- a/i18n/rus/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json @@ -7,5 +7,6 @@ "TaskRunnerSystem.unknownError": "При выполнении задачи произошла неизвеÑÑ‚Ð½Ð°Ñ Ð¾ÑˆÐ¸Ð±ÐºÐ°. ПодробноÑти Ñм. в журнале выходных данных задач.", "TaskRunnerSystem.watchingBuildTaskFinished": "\nОтÑлеживание задач Ñборки завершено.", "TaskRunnerSystem.childProcessError": "Failed to launch external program {0} {1}.", - "TaskRunnerSystem.cancelRequested": "\nЗадача \"{0}\" была завершена по запроÑу пользователÑ." + "TaskRunnerSystem.cancelRequested": "\nЗадача \"{0}\" была завершена по запроÑу пользователÑ.", + "unkownProblemMatcher": "Ðе удаетÑÑ Ñ€Ð°Ð·Ñ€ÐµÑˆÐ¸Ñ‚ÑŒ ÑопоÑтавитель проблем {0}. СопоÑтавитель будет проигнорирован" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json b/i18n/rus/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json index 8104d226e88..ccd5870dca1 100644 --- a/i18n/rus/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json @@ -8,6 +8,7 @@ "workbench.action.terminal.kill": "Завершить активный ÑкземплÑÑ€ терминала", "workbench.action.terminal.kill.short": "Завершить работу терминала", "workbench.action.terminal.copySelection": "Скопировать выделение", + "workbench.action.terminal.selectAll": "Выбрать вÑе", "workbench.action.terminal.new": "Создание нового интегрированного терминала", "workbench.action.terminal.new.short": "Ðовый терминал", "workbench.action.terminal.focus": "Ð¤Ð¾ÐºÑƒÑ Ð½Ð° терминале", @@ -26,5 +27,8 @@ "workbench.action.terminal.scrollUp": "Прокрутить вверх (поÑтрочно)", "workbench.action.terminal.scrollUpPage": "Прокрутить вверх (Ñтраницу)", "workbench.action.terminal.scrollToTop": "Прокрутить до верхней границы", - "workbench.action.terminal.clear": "ОчиÑтить" + "workbench.action.terminal.clear": "ОчиÑтить", + "workbench.action.terminal.allowWorkspaceShell": "Разрешить наÑтройку оболочки в рабочей облаÑти", + "workbench.action.terminal.disallowWorkspaceShell": "Запретить наÑтройку оболочки в рабочей облаÑти", + "workbench.action.terminal.rename": "Переименовать" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json b/i18n/rus/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json index 227600f316f..a43d3077cff 100644 --- a/i18n/rus/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json @@ -4,5 +4,7 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "terminal.background": "Цвет фона терминала. С его помощью можно указать цвет терминала, отличный от цвета панели.", + "terminal.foreground": "Цвет переднего плана терминала.", "terminal.ansiColor": "Цвет ANSI \"{0}\" в терминале." } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json b/i18n/rus/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json new file mode 100644 index 00000000000..e03b15626d2 --- /dev/null +++ b/i18n/rus/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "label.find": "Ðайти", + "placeholder.find": "Ðайти", + "label.previousMatchButton": "Предыдущее ÑоответÑтвие", + "label.nextMatchButton": "Следующее ÑоответÑтвие", + "label.closeButton": "Закрыть" +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json b/i18n/rus/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json index 2034b9a4ca8..07fc306b313 100644 --- a/i18n/rus/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json @@ -4,7 +4,6 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "terminal.integrated.copySelection.noSelection": "Ðевозможно Ñкопировать выделение в терминале, когда терминал не имеет фокуÑа", "terminal.integrated.exitedWithCode": "ПроцеÑÑ Ñ‚ÐµÑ€Ð¼Ð¸Ð½Ð°Ð»Ð° завершен Ñ ÐºÐ¾Ð´Ð¾Ð¼ выхода: {0}", "terminal.integrated.waitOnExit": "Ðажмите любую клавишу, чтобы закрыть терминал.", "terminal.integrated.launchFailed": "Ðе удалоÑÑŒ запуÑтить команду процеÑÑа терминала \"{0}{1}\" (код выхода: {2})" diff --git a/i18n/rus/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json b/i18n/rus/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json index 60eb5ce7cf9..b252e0872aa 100644 --- a/i18n/rus/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json @@ -6,6 +6,7 @@ { "selectTheme.label": "Ð¦Ð²ÐµÑ‚Ð¾Ð²Ð°Ñ Ñ‚ÐµÐ¼Ð°", "installColorThemes": "УÑтановить дополнительные цветовые темы...", + "themes.selectTheme": "Выберите цветовую тему (иÑпользуйте клавиши Ñтрелок вверх и вниз Ð´Ð»Ñ Ð¿Ñ€ÐµÐ´Ð²Ð°Ñ€Ð¸Ñ‚ÐµÐ»ÑŒÐ½Ð¾Ð³Ð¾ проÑмотра)", "selectIconTheme.label": "Тема значков файлов", "installIconThemes": "УÑтановить дополнительные темы значков файлов...", "noIconThemeLabel": "Ðет", diff --git a/i18n/rus/src/vs/workbench/parts/update/electron-browser/update.i18n.json b/i18n/rus/src/vs/workbench/parts/update/electron-browser/update.i18n.json index ef31128d567..9e8608fc276 100644 --- a/i18n/rus/src/vs/workbench/parts/update/electron-browser/update.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/update/electron-browser/update.i18n.json @@ -15,5 +15,18 @@ "license": "Прочитать уÑÐ»Ð¾Ð²Ð¸Ñ Ð»Ð¸Ñ†ÐµÐ½Ð·Ð¸Ð¸", "updateAvailable": "{0} будет обновлен поÑле перезапуÑка.", "thereIsUpdateAvailable": "ДоÑтупно обновление.", - "noUpdatesAvailable": "Ð’ наÑтоÑщее Ð²Ñ€ÐµÐ¼Ñ Ð½ÐµÑ‚ доÑтупных обновлений." + "noUpdatesAvailable": "Ð’ наÑтоÑщее Ð²Ñ€ÐµÐ¼Ñ Ð½ÐµÑ‚ доÑтупных обновлений.", + "updateIsReady": "ДоÑтупно новое обновление.", + "commandPalette": "Палитра команд...", + "settings": "Параметры", + "keyboardShortcuts": "Ð¡Ð¾Ñ‡ÐµÑ‚Ð°Ð½Ð¸Ñ ÐºÐ»Ð°Ð²Ð¸Ñˆ", + "selectTheme.label": "Ð¦Ð²ÐµÑ‚Ð¾Ð²Ð°Ñ Ñ‚ÐµÐ¼Ð°", + "themes.selectIconTheme.label": "Тема значков файлов", + "not available": "ÐžÐ±Ð½Ð¾Ð²Ð»ÐµÐ½Ð¸Ñ Ð½ÐµÐ´Ð¾Ñтупны", + "checkingForUpdates": "Идет проверка Ð½Ð°Ð»Ð¸Ñ‡Ð¸Ñ Ð¾Ð±Ð½Ð¾Ð²Ð»ÐµÐ½Ð¸Ð¹...", + "DownloadUpdate": "Скачать доÑтупное обновление", + "DownloadingUpdate": "СкачиваетÑÑ Ð¾Ð±Ð½Ð¾Ð²Ð»ÐµÐ½Ð¸Ðµ...", + "InstallingUpdate": "Идет уÑтановка обновлениÑ...", + "restartToUpdate": "ПерезапуÑтить Ð´Ð»Ñ Ð¾Ð±Ð½Ð¾Ð²Ð»ÐµÐ½Ð¸Ñ...", + "checkForUpdates": "Проверить наличие обновлений..." } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/views/browser/views.i18n.json b/i18n/rus/src/vs/workbench/parts/views/browser/views.i18n.json new file mode 100644 index 00000000000..761072edd67 --- /dev/null +++ b/i18n/rus/src/vs/workbench/parts/views/browser/views.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "viewToolbarAriaLabel": "ДейÑтвий: {0}" +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json b/i18n/rus/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json new file mode 100644 index 00000000000..3c41a4d1bda --- /dev/null +++ b/i18n/rus/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "requirearray": "предÑÑ‚Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ð´Ð¾Ð»Ð¶Ð½Ñ‹ быть маÑÑивом", + "requirestring": "ÑвойÑтво \"{0}\" ÑвлÑетÑÑ Ð¾Ð±Ñзательным и должно иметь тип string", + "optstring": "ÑвойÑтво \"{0}\" может быть опущено или должно иметь тип string", + "vscode.extension.contributes.view.id": "Идентификатор предÑтавлениÑ. ИÑпользуйте его Ð´Ð»Ñ Ñ€ÐµÐ³Ð¸Ñтрации поÑтавщика данных Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ API-интерфейÑа \"vscode.window.registerTreeDataProviderForView\", а также Ð´Ð»Ñ Ð°ÐºÑ‚Ð¸Ð²Ð°Ñ†Ð¸Ð¸ раÑÑˆÐ¸Ñ€ÐµÐ½Ð¸Ñ Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ региÑтрации ÑÐ¾Ð±Ñ‹Ñ‚Ð¸Ñ \"onView:${id}\" в \"activationEvents\".", + "vscode.extension.contributes.view.name": "ПонÑтное Ð¸Ð¼Ñ Ð¿Ñ€ÐµÐ´ÑтавлениÑ. Будет отображатьÑÑ Ð½Ð° Ñкране", + "vscode.extension.contributes.views": "ДобавлÑет предÑÑ‚Ð°Ð²Ð»ÐµÐ½Ð¸Ñ Ð² редактор", + "views.explorer": "ПредÑтавление проводника", + "locationId.invalid": "\"{0}\" не ÑвлÑетÑÑ Ð´Ð¾Ð¿ÑƒÑтимым раÑположением предÑтавлениÑ" +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/rus/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json index 9cf8071dbbf..cbdb68fe6f7 100644 --- a/i18n/rus/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -11,20 +11,26 @@ "welcomePage.openFolder": "Открыть папку...", "welcomePage.cloneGitRepository": "Клонировать репозиторий Git...", "welcomePage.recent": "ПоÑледние", + "welcomePage.moreRecent": "Дополнительные ÑведениÑ...", "welcomePage.noRecentFolders": "Ðет поÑледних папок.", "welcomePage.help": "Справка", + "welcomePage.keybindingsCheatsheet": "СпиÑок Ñочетаний клавиш в печатном виде", "welcomePage.introductoryVideos": "Ð’Ñтупительные видео", "welcomePage.productDocumentation": "Ð”Ð¾ÐºÑƒÐ¼ÐµÐ½Ñ‚Ð°Ñ†Ð¸Ñ Ð¿Ð¾ продукту", "welcomePage.gitHubRepository": "Репозиторий GitHub", "welcomePage.stackOverflow": "Stack Overflow", "welcomePage.showOnStartup": "Отображать Ñтраницу приветÑÑ‚Ð²Ð¸Ñ Ð¿Ñ€Ð¸ запуÑке", "welcomePage.customize": "ÐаÑтроить", + "welcomePage.installExtensionPacks": "СредÑтва и Ñзыки", + "welcomePage.installExtensionPacksDescription": "УÑтановить поддержку Ð´Ð»Ñ {0} и {1}", + "welcomePage.moreExtensions": "Еще", "welcomePage.installKeymapDescription": "УÑтановка Ñочетаний клавиш", + "welcomePage.installKeymapExtension": "ÐаÑтроить ÑÐ¾Ñ‡ÐµÑ‚Ð°Ð½Ð¸Ñ ÐºÐ»Ð°Ð²Ð¸Ñˆ Ð´Ð»Ñ {0} и {1}", "welcomePage.others": "Другие", "welcomePage.colorTheme": "Ð¦Ð²ÐµÑ‚Ð¾Ð²Ð°Ñ Ñ‚ÐµÐ¼Ð°", "welcomePage.colorThemeDescription": "ÐаÑтройте редактор и код удобным образом.", + "welcomePage.learn": "Подробнее", "welcomePage.showCommands": "Ðайти и выполнить вÑе команды.", - "welcomePage.showCommandsDescription": "БыÑтрый доÑтуп и поиÑк команд на панели ÑƒÐ¿Ñ€Ð°Ð²Ð»ÐµÐ½Ð¸Ñ ({0})", "welcomePage.interfaceOverview": "Общие ÑÐ²ÐµÐ´ÐµÐ½Ð¸Ñ Ð¾Ð± интерфейÑе", "welcomePage.interfaceOverviewDescription": "ИÑпользуйте визуальное наложение Ñ Ð²Ñ‹Ð´ÐµÐ»ÐµÐ½Ð¸ÐµÐ¼ оÑновных компонентов пользовательÑкого интерфейÑа.", "welcomePage.interactivePlayground": "Ð˜Ð½Ñ‚ÐµÑ€Ð°ÐºÑ‚Ð¸Ð²Ð½Ð°Ñ Ð¿Ð»Ð¾Ñ‰Ð°Ð´ÐºÐ°", diff --git a/i18n/rus/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json b/i18n/rus/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json index 9927d1b163a..64481a105b1 100644 --- a/i18n/rus/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json @@ -4,7 +4,5 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { - "workbenchConfigurationTitle": "Workbench", - "welcomePage.enabled": "ЕÑли Ñтот параметр включен, Ñтраница приветÑÑ‚Ð²Ð¸Ñ Ð±ÑƒÐ´ÐµÑ‚ отображатьÑÑ Ð¿Ñ€Ð¸ запуÑке.", "help": "Справка" } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/rus/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json index 1365e07209b..b5de51bfe07 100644 --- a/i18n/rus/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -4,17 +4,35 @@ *--------------------------------------------------------------------------------------------*/ // Do not edit this file. It is machine generated. { + "workbenchConfigurationTitle": "Рабочее меÑто", + "welcomePage.enabled": "ЕÑли Ñтот параметр включен, Ñтраница приветÑÑ‚Ð²Ð¸Ñ Ð±ÑƒÐ´ÐµÑ‚ отображатьÑÑ Ð¿Ñ€Ð¸ запуÑке.", "welcomePage": "Добро пожаловать", + "welcomePage.javaScript": "JavaScript", "welcomePage.typeScript": "TypeScript", + "welcomePage.python": "Python", "welcomePage.php": "PHP", + "welcomePage.docker": "Docker", "welcomePage.vim": "Vim", "welcomePage.sublime": "Sublime", "welcomePage.atom": "Atom", + "welcomePage.extensionPackAlreadyInstalled": "Поддержка {0} уже добавлена.", + "welcomePage.willReloadAfterInstallingExtensionPack": "ПоÑле уÑтановки дополнительной поддержки Ð´Ð»Ñ {0} окно будет перезагружено.", + "welcomePage.installingExtensionPack": "УÑтановка дополнительной поддержки Ð´Ð»Ñ {0}...", + "welcomePage.extensionPackNotFound": "Ðе удаетÑÑ Ð½Ð°Ð¹Ñ‚Ð¸ поддержку Ð´Ð»Ñ {0} Ñ Ð¸Ð´ÐµÐ½Ñ‚Ð¸Ñ„Ð¸ÐºÐ°Ñ‚Ð¾Ñ€Ð¾Ð¼ {1}.", "welcomePage.keymapAlreadyInstalled": "Ð¡Ð¾Ñ‡ÐµÑ‚Ð°Ð½Ð¸Ñ ÐºÐ»Ð°Ð²Ð¸Ñˆ {0} уже уÑтановлены.", "welcomePage.willReloadAfterInstallingKeymap": "Окно перезагрузитÑÑ Ð¿Ð¾Ñле уÑтановки Ñочетаний клавиш {0}.", "welcomePage.installingKeymap": "УÑтанавливаютÑÑ ÑÐ¾Ñ‡ÐµÑ‚Ð°Ð½Ð¸Ñ ÐºÐ»Ð°Ð²Ð¸Ñˆ {0}...", "welcomePage.keymapNotFound": "Ðе удалоÑÑŒ найти ÑÐ¾Ñ‡ÐµÑ‚Ð°Ð½Ð¸Ñ ÐºÐ»Ð°Ð²Ð¸Ñˆ {0} Ñ Ð¸Ð´ÐµÐ½Ñ‚Ð¸Ñ„Ð¸ÐºÐ°Ñ‚Ð¾Ñ€Ð¾Ð¼ {1}.", "welcome.title": "Добро пожаловать", + "welcomePage.openFolderWithPath": "Открыть папку {0} Ñ Ð¿ÑƒÑ‚ÐµÐ¼ {1}", + "welcomePage.extensionListSeparator": ",", + "welcomePage.installKeymap": "УÑтановить раÑкладку клавиатуры {0}", + "welcomePage.installExtensionPack": "УÑтановить дополнительную поддержку Ð´Ð»Ñ {0}", + "welcomePage.installedKeymap": "РаÑкладка клавиатуры {0} уже уÑтановлена", + "welcomePage.installedExtensionPack": "Поддержка {0} уже уÑтановлена", "ok": "ОК", - "cancel": "Отмена" + "details": "ПодробноÑти", + "cancel": "Отмена", + "welcomePage.buttonBackground": "Цвет фона кнопок на Ñтранице приветÑтвиÑ.", + "welcomePage.buttonHoverBackground": "Цвет фона при наведении ÑƒÐºÐ°Ð·Ð°Ñ‚ÐµÐ»Ñ Ð´Ð»Ñ ÐºÐ½Ð¾Ð¿Ð¾Ðº на Ñтранице приветÑтвиÑ." } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json b/i18n/rus/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json index c86c05dcae5..e79310b57d6 100644 --- a/i18n/rus/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json +++ b/i18n/rus/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json @@ -5,5 +5,6 @@ // Do not edit this file. It is machine generated. { "walkThrough.unboundCommand": "Ñвободный", - "walkThrough.gitNotFound": "Похоже, Git не уÑтановлен в вашей ÑиÑтеме." + "walkThrough.gitNotFound": "Похоже, Git не уÑтановлен в вашей ÑиÑтеме.", + "walkThrough.embeddedEditorBackground": "Цвет фона вÑтроенных редакторов Ð´Ð»Ñ Ð¸Ð½Ñ‚ÐµÑ€Ð°ÐºÑ‚Ð¸Ð²Ð½Ñ‹Ñ… площадок." } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json b/i18n/rus/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json index e87cb2bac28..11dedf614c6 100644 --- a/i18n/rus/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json +++ b/i18n/rus/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json @@ -6,6 +6,12 @@ { "open": "Открыть параметры", "close": "Закрыть", + "saveAndRetry": "Сохранить параметры и повторить попытку", "errorUnknownKey": "Ðе удаетÑÑ Ð²Ñ‹Ð¿Ð¾Ð»Ð½Ð¸Ñ‚ÑŒ запиÑÑŒ в файл конфигурации (неизвеÑтный ключ)", - "errorInvalidTarget": "Ðе удаетÑÑ Ð²Ñ‹Ð¿Ð¾Ð»Ð½Ð¸Ñ‚ÑŒ запиÑÑŒ в файл конфигурации (недопуÑтимый целевой объект)." + "errorInvalidTarget": "Ðе удаетÑÑ Ð²Ñ‹Ð¿Ð¾Ð»Ð½Ð¸Ñ‚ÑŒ запиÑÑŒ в файл конфигурации (недопуÑтимый целевой объект).", + "errorNoWorkspaceOpened": "Ðе удаетÑÑ Ð·Ð°Ð¿Ð¸Ñать параметры, так как нет открытых папок. Откройте папку и повторите попытку.", + "errorInvalidConfiguration": "Ðе удаетÑÑ Ð·Ð°Ð¿Ð¸Ñать параметры. Откройте файл **User Settings**, уÑтраните ошибки и Ð¿Ñ€ÐµÐ´ÑƒÐ¿Ñ€ÐµÐ¶Ð´ÐµÐ½Ð¸Ñ Ð² файле и повторите попытку.", + "errorInvalidConfigurationWorkspace": "Ðе удаетÑÑ Ð·Ð°Ð¿Ð¸Ñать параметры. Откройте файл **Workspace Settings**, уÑтраните ошибки и Ð¿Ñ€ÐµÐ´ÑƒÐ¿Ñ€ÐµÐ¶Ð´ÐµÐ½Ð¸Ñ Ð² файле и повторите попытку.", + "errorConfigurationFileDirty": "Ðе удаетÑÑ Ð·Ð°Ð¿Ð¸Ñать параметры, так как файл был изменен. Сохраните файл **User Settings** и повторите попытку.", + "errorConfigurationFileDirtyWorkspace": "Ðе удаетÑÑ Ð·Ð°Ð¿Ð¸Ñать параметры, так как файл был изменен. Сохраните файл **Workspace Settings** и повторите попытку." } \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json b/i18n/rus/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json new file mode 100644 index 00000000000..b9b24e91bdb --- /dev/null +++ b/i18n/rus/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "telemetryConfigurationTitle": "ТелеметриÑ", + "telemetry.enableCrashReporting": "Разрешить отправку отчетов о ÑбоÑÑ… в МайкроÑофт.\nЧтобы Ñтот параметр вÑтупил в Ñилу, требуетÑÑ Ð¿ÐµÑ€ÐµÐ·Ð°Ð³Ñ€ÑƒÐ·ÐºÐ°." +} \ No newline at end of file diff --git a/i18n/rus/src/vs/workbench/services/progress/browser/progressService2.i18n.json b/i18n/rus/src/vs/workbench/services/progress/browser/progressService2.i18n.json new file mode 100644 index 00000000000..6db7d6aae51 --- /dev/null +++ b/i18n/rus/src/vs/workbench/services/progress/browser/progressService2.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "progress.text": "{0} - {1}", + "progress.title": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/trk/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json b/i18n/trk/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json new file mode 100644 index 00000000000..1c2d94b4c20 --- /dev/null +++ b/i18n/trk/extensions/configuration-editing/out/settingsDocumentHelper.i18n.json @@ -0,0 +1,36 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "activeEditorShort": "ör. myFile.txt", + "activeEditorMedium": "ör. myFolder/myFile.txt", + "activeEditorLong": "ör. /Users/Development/myProject/myFolder/myFile.txt", + "rootName": "ör. myProject", + "rootPath": "ör. /Users/Development/myProject", + "appName": "ör. VS Code", + "dirty": "deÄŸiÅŸiklik göstergesi, aktif düzenleyici kaydedilmemiÅŸ deÄŸiÅŸiklikler içeriyorsa", + "separator": "koÅŸullu ayırıcı ('-') sadece deÄŸiÅŸkenler tarafından deÄŸerlerle çevrildiÄŸinde gösterir", + "assocLabelFile": "Uzantılı Dosyalar", + "assocDescriptionFile": "Dosya adında glob deseniyle eÅŸleÅŸen tüm dosyaları belirtilen tanımlayıcıya sahip olan dile eÅŸleyin.", + "assocLabelPath": "Yollu Dosyalar", + "assocDescriptionPath": "Dosya yolunda mutlak yol glob deseniyle eÅŸleÅŸen tüm dosyaları belirtilen tanımlayıcıya sahip olan dile eÅŸleyin.", + "fileLabel": "Uzantıya Göre Dosyalar", + "fileDescription": "Belirli bir dosya uzantısına sahip tüm dosyaları eÅŸleÅŸtirin.", + "filesLabel": "Birden Çok Uzantılı Dosyalar", + "filesDescription": "Tüm dosyaları herhangi bir dosya uzantısıyla eÅŸleÅŸtirin.", + "derivedLabel": "Ada Göre EÅŸdüzeyi Olan Dosyalar", + "derivedDescription": "Aynı ada ancak farklı bir uzantıya sahip eÅŸdüzeyi olan dosyaları eÅŸleÅŸtirin.", + "topFolderLabel": "Ada Göre Klasör (En Ãœst Düzey)", + "topFolderDescription": "En üst düzeydeki bir klasörü belirli bir ad ile eÅŸleÅŸtirin.", + "topFoldersLabel": "Birden Çok Ada Sahip Klasör (En Ãœst Düzey)", + "topFoldersDescription": "Birden çok en üst düzey klasörü eÅŸleÅŸtirin.", + "folderLabel": "Ada Göre Klasör (Herhangi Bir Konum)", + "folderDescription": "Bir klasörü herhangi bir konumdaki belirli bir ad ile eÅŸleÅŸtirin.", + "falseDescription": "Deseni devre dışı bırakın.", + "trueDescription": "Deseni etkinleÅŸtirin.", + "siblingsDescription": "Aynı ada ancak farklı bir uzantıya sahip eÅŸdüzeyi olan dosyaları eÅŸleÅŸtirin.", + "languageSpecificEditorSettings": "Dile özel düzenleyici ayarları", + "languageSpecificEditorSettingsDescription": "Dil için düzenleyici ayarlarını geçersiz kıl" +} \ No newline at end of file diff --git a/i18n/trk/extensions/css/client/out/cssMain.i18n.json b/i18n/trk/extensions/css/client/out/cssMain.i18n.json new file mode 100644 index 00000000000..25a60c39828 --- /dev/null +++ b/i18n/trk/extensions/css/client/out/cssMain.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "cssserver.name": "CSS Dil Sunucusu" +} \ No newline at end of file diff --git a/i18n/trk/extensions/css/package.i18n.json b/i18n/trk/extensions/css/package.i18n.json new file mode 100644 index 00000000000..215750e00ed --- /dev/null +++ b/i18n/trk/extensions/css/package.i18n.json @@ -0,0 +1,67 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "css.lint.argumentsInColorFunction.desc": "Geçersiz sayıda parametre", + "css.lint.boxModel.desc": "Doldurma veya kenarlık kullanırken geniÅŸlik veya yükseklik kullanmayın", + "css.lint.compatibleVendorPrefixes.desc": "Satıcıya özgü bir ön ek kullanırken satıcıya özgü diÄŸer tüm özellikleri de dahil ettiÄŸinizden emin olun", + "css.lint.duplicateProperties.desc": "Yinelenen stil tanımları kullanmayın", + "css.lint.emptyRules.desc": "BoÅŸ kural kümeleri kullanmayın", + "css.lint.float.desc": "'float' kullanmaktan kaçının. Float'lar, düzenin herhangi bir unsuru deÄŸiÅŸtiÄŸinde kolayca bozulan kırılgan CSS ile sonuçlanır.", + "css.lint.fontFaceProperties.desc": "@font-face kuralı 'src' ve 'font-family' özelliklerini tanımlamalıdır", + "css.lint.hexColorLength.desc": "Onaltılık renkler üç veya altı onaltılık sayıdan oluÅŸmalıdır", + "css.lint.idSelector.desc": "Bu kurallar HTML'ye çok sıkı baÄŸlı olduÄŸundan seçiciler kimlikleri içermemelidir.", + "css.lint.ieHack.desc": "IE izinsiz giriÅŸleri yalnızca IE7 ve daha eski sürümler desteklenirken gereklidir", + "css.lint.important.desc": "!important kullanmaktan kaçının. Tüm CSS'nin belirginlik düzeyi üzerindeki denetimin kaybedildiÄŸinin ve yeniden düzenlenmesi gerektiÄŸinin bir belirtisidir.", + "css.lint.importStatement.desc": "İçe aktarma deyimleri paralel olarak yüklenmez", + "css.lint.propertyIgnoredDueToDisplay.desc": "Özellik gösterim nedeniyle yoksayıldı. Örn. 'display: inline' ile width, height, margin-top, margin-bottom ve float özelliklerinin hiçbir etkisi olmaz", + "css.lint.universalSelector.desc": "Evrensel seçici (*) yavaÅŸ olarak bilinir", + "css.lint.unknownProperties.desc": "Bilinmeyen özellik.", + "css.lint.unknownVendorSpecificProperties.desc": "Bilinmeyen satıcıya özel özellik.", + "css.lint.vendorPrefix.desc": "Satıcıya özgü bir ön ek kullanırken standart özelliÄŸi de dahil edin", + "css.lint.zeroUnits.desc": "Sıfır için birim gerekmez", + "css.validate.desc": "Tüm doÄŸrulamaları etkinleÅŸtirir veya devre dışı bırakır", + "less.lint.argumentsInColorFunction.desc": "Geçersiz sayıda parametre", + "less.lint.boxModel.desc": "Doldurma veya kenarlık kullanırken geniÅŸlik veya yükseklik kullanmayın", + "less.lint.compatibleVendorPrefixes.desc": "Satıcıya özgü bir ön ek kullanırken satıcıya özgü diÄŸer tüm özellikleri de dahil ettiÄŸinizden emin olun", + "less.lint.duplicateProperties.desc": "Yinelenen stil tanımları kullanmayın", + "less.lint.emptyRules.desc": "BoÅŸ kural kümeleri kullanmayın", + "less.lint.float.desc": "'float' kullanmaktan kaçının. Float'lar, düzenin herhangi bir unsuru deÄŸiÅŸtiÄŸinde kolayca bozulan kırılgan CSS ile sonuçlanır.", + "less.lint.fontFaceProperties.desc": "@font-face kuralı 'src' ve 'font-family' özelliklerini tanımlamalıdır", + "less.lint.hexColorLength.desc": "Onaltılık renkler üç veya altı onaltılık sayıdan oluÅŸmalıdır", + "less.lint.idSelector.desc": "Bu kurallar HTML'ye çok sıkı baÄŸlı olduÄŸundan seçiciler kimlikleri içermemelidir.", + "less.lint.ieHack.desc": "IE izinsiz giriÅŸleri yalnızca IE7 ve daha eski sürümler desteklenirken gereklidir", + "less.lint.important.desc": "!important kullanmaktan kaçının. Tüm CSS'nin belirginlik düzeyi üzerindeki denetimin kaybedildiÄŸinin ve yeniden düzenlenmesi gerektiÄŸinin bir belirtisidir.", + "less.lint.importStatement.desc": "İçe aktarma deyimleri paralel olarak yüklenmez", + "less.lint.propertyIgnoredDueToDisplay.desc": "Özellik gösterim nedeniyle yoksayıldı. Örn. 'display: inline' ile width, height, margin-top, margin-bottom ve float özelliklerinin hiçbir etkisi olmaz", + "less.lint.universalSelector.desc": "Evrensel seçici (*) yavaÅŸ olarak bilinir", + "less.lint.unknownProperties.desc": "Bilinmeyen özellik.", + "less.lint.unknownVendorSpecificProperties.desc": "Bilinmeyen satıcıya özel özellik.", + "less.lint.vendorPrefix.desc": "Satıcıya özgü bir ön ek kullanırken standart özelliÄŸi de dahil edin", + "less.lint.zeroUnits.desc": "Sıfır için birim gerekmez", + "less.validate.desc": "Tüm doÄŸrulamaları etkinleÅŸtirir veya devre dışı bırakır", + "scss.lint.argumentsInColorFunction.desc": "Geçersiz sayıda parametre", + "scss.lint.boxModel.desc": "Doldurma veya kenarlık kullanırken geniÅŸlik veya yükseklik kullanmayın", + "scss.lint.compatibleVendorPrefixes.desc": "Satıcıya özgü bir ön ek kullanırken satıcıya özgü diÄŸer tüm özellikleri de dahil ettiÄŸinizden emin olun", + "scss.lint.duplicateProperties.desc": "Yinelenen stil tanımları kullanmayın", + "scss.lint.emptyRules.desc": "BoÅŸ kural kümeleri kullanmayın", + "scss.lint.float.desc": "'float' kullanmaktan kaçının. Float'lar, düzenin herhangi bir unsuru deÄŸiÅŸtiÄŸinde kolayca bozulan kırılgan CSS ile sonuçlanır.", + "scss.lint.fontFaceProperties.desc": "@font-face kuralı 'src' ve 'font-family' özelliklerini tanımlamalıdır", + "scss.lint.hexColorLength.desc": "Onaltılık renkler üç veya altı onaltılık sayıdan oluÅŸmalıdır", + "scss.lint.idSelector.desc": "Bu kurallar HTML'ye çok sıkı baÄŸlı olduÄŸundan seçiciler kimlikleri içermemelidir.", + "scss.lint.ieHack.desc": "IE izinsiz giriÅŸleri yalnızca IE7 ve daha eski sürümler desteklenirken gereklidir", + "scss.lint.important.desc": "!important kullanmaktan kaçının. Tüm CSS'nin belirginlik düzeyi üzerindeki denetimin kaybedildiÄŸinin ve yeniden düzenlenmesi gerektiÄŸinin bir belirtisidir.", + "scss.lint.importStatement.desc": "İçe aktarma deyimleri paralel olarak yüklenmez", + "scss.lint.propertyIgnoredDueToDisplay.desc": "Özellik gösterim nedeniyle yoksayıldı. Örn. 'display: inline' ile width, height, margin-top, margin-bottom ve float özelliklerinin hiçbir etkisi olmaz", + "scss.lint.universalSelector.desc": "Evrensel seçici (*) yavaÅŸ olarak bilinir", + "scss.lint.unknownProperties.desc": "Bilinmeyen özellik.", + "scss.lint.unknownVendorSpecificProperties.desc": "Bilinmeyen satıcıya özel özellik.", + "scss.lint.vendorPrefix.desc": "Satıcıya özgü bir ön ek kullanırken standart özelliÄŸi de dahil edin", + "scss.lint.zeroUnits.desc": "Sıfır için birim gerekmez", + "scss.validate.desc": "Tüm doÄŸrulamaları etkinleÅŸtirir veya devre dışı bırakır", + "less.colorDecorators.enable.desc": "Renk dekoratörlerini etkinleÅŸtirir veya devre dışı bırakır", + "scss.colorDecorators.enable.desc": "Renk dekoratörlerini etkinleÅŸtirir veya devre dışı bırakır", + "css.colorDecorators.enable.desc": "Renk dekoratörlerini etkinleÅŸtirir veya devre dışı bırakır" +} \ No newline at end of file diff --git a/i18n/trk/extensions/extension-editing/out/packageDocumentHelper.i18n.json b/i18n/trk/extensions/extension-editing/out/packageDocumentHelper.i18n.json new file mode 100644 index 00000000000..727dd6640ef --- /dev/null +++ b/i18n/trk/extensions/extension-editing/out/packageDocumentHelper.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "languageSpecificEditorSettings": "Dile özel düzenleyici ayarları", + "languageSpecificEditorSettingsDescription": "Dil için düzenleyici ayarlarını geçersiz kıl" +} \ No newline at end of file diff --git a/i18n/trk/extensions/git/out/askpass-main.i18n.json b/i18n/trk/extensions/git/out/askpass-main.i18n.json new file mode 100644 index 00000000000..56e7f652dd6 --- /dev/null +++ b/i18n/trk/extensions/git/out/askpass-main.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "missOrInvalid": "Eksik veya geçersiz kimlik bilgisi." +} \ No newline at end of file diff --git a/i18n/trk/extensions/git/out/commands.i18n.json b/i18n/trk/extensions/git/out/commands.i18n.json new file mode 100644 index 00000000000..b2222807717 --- /dev/null +++ b/i18n/trk/extensions/git/out/commands.i18n.json @@ -0,0 +1,46 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tag at": "{0} üzerindeki etiket", + "remote branch at": "{0} üzerindeki uzak dal", + "repourl": "Depo URL'si", + "parent": "Ãœst Klasör", + "cloning": "Git deposu kopyalanıyor...", + "openrepo": "Depoyu Aç", + "proposeopen": "Kopyalanan depoyu açmak ister misiniz?", + "confirm revert": "{0} üzerindeki seçili deÄŸiÅŸiklikleri geri almak istediÄŸinizden emin misiniz?", + "revert": "DeÄŸiÅŸiklikleri Geri Al", + "confirm discard": "{0} üzerindeki seçili deÄŸiÅŸiklikleri göz ardı etmek istediÄŸinizden emin misiniz?", + "confirm discard multiple": "{0} dosyadaki deÄŸiÅŸiklikleri göz ardı etmek istediÄŸinizden emin misiniz?", + "discard": "DeÄŸiÅŸiklikleri Göz Ardı Et", + "confirm discard all": "TÃœM deÄŸiÅŸiklikleri göz ardı etmek istediÄŸinizden emin misiniz? Bu, GERÄ° DÖNDÃœRÃœLEMEZ!", + "discardAll": "TÃœM DeÄŸiÅŸiklikleri Göz Ardı Et", + "no staged changes": "Commit'lenecek hazırlanmış deÄŸiÅŸiklik yok.\n\nTüm deÄŸiÅŸikliklerinizi otomatik olarak hazırlamak ve direkt olarak commit'lemek ister misiniz?", + "yes": "Evet", + "always": "Her Zaman", + "no changes": "Commit'lenecek deÄŸiÅŸiklik yok.", + "commit message": "Commit mesajı", + "provide commit message": "Lütfen bir commit mesajı belirtin.", + "branch name": "Dal adı", + "provide branch name": "Lütfen bir dal adı belirtin", + "select branch to delete": "Silinecek dalı seçin", + "confirm force delete branch": "'{0}' dalı tamamen birleÅŸtirilmemiÅŸ. Yine de silinsin mi?", + "delete branch": "Dalı Sil", + "no remotes to pull": "Deponuzda çekme iÅŸleminin yapılacağı hiçbir uzak uçbirim yapılandırılmamış.", + "no remotes to push": "Deponuzda gönderimin yapılacağı hiçbir uzak uçbirim yapılandırılmamış.", + "nobranch": "Lütfen uzak uçbirime gönderilecek dala geçiÅŸ yapın.", + "pick remote": "'{0}' dalının yayınlanacağı bir uzak uçbirim seçin:", + "sync is unpredictable": "Bu eylem, '{0}' esas projesine commitleri gönderecek ve alacaktır.", + "ok": "Tamam", + "never again": "Tamam, Tekrar Gösterme", + "no remotes to publish": "Deponuzda yayınlamanın yapılacağı hiçbir uzak uçbirim yapılandırılmamış.", + "disabled": "Git, ya devre dışı bırakılmış ya da bu çalışma alanında desteklenmiyor", + "clean repo": "GeçiÅŸ yapmadan önce deponuzdaki çalışma aÄŸacınızı temizleyin.", + "cant push": "BaÅŸvurular uzak uçbirime gönderilemiyor. DeÄŸiÅŸikliklerinizi entegre etmeden, ilk olarak 'Çek'i çalıştırın. ", + "git error details": "Git: {0}", + "git error": "Git hatası", + "open git log": "Git Günlüğünü Aç" +} \ No newline at end of file diff --git a/i18n/trk/extensions/git/out/main.i18n.json b/i18n/trk/extensions/git/out/main.i18n.json new file mode 100644 index 00000000000..eda1b0cc9a9 --- /dev/null +++ b/i18n/trk/extensions/git/out/main.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "using git": "{1} yolundaki git {0} kullanılıyor", + "updateGit": "Git'i Güncelle", + "neverShowAgain": "Tekrar gösterme", + "git20": "git {0} yüklemiÅŸ olarak görünüyorsunuz. Code, git >= 2 ile en iyi ÅŸekilde çalışır" +} \ No newline at end of file diff --git a/i18n/trk/extensions/git/out/model.i18n.json b/i18n/trk/extensions/git/out/model.i18n.json new file mode 100644 index 00000000000..282a283d443 --- /dev/null +++ b/i18n/trk/extensions/git/out/model.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "open": "Aç", + "merge changes": "DeÄŸiÅŸiklikleri BirleÅŸtir", + "staged changes": "Hazırlanmış DeÄŸiÅŸiklikler", + "changes": "DeÄŸiÅŸiklikler", + "ok": "Tamam", + "neveragain": "Tekrar Gösterme", + "huge": "'{0}' yolundaki git deposunda çok fazla aktif deÄŸiÅŸikliklik var, Git özelliklerinin yalnızca bir alt kümesi etkinleÅŸtirilecektir." +} \ No newline at end of file diff --git a/i18n/trk/extensions/git/out/scmProvider.i18n.json b/i18n/trk/extensions/git/out/scmProvider.i18n.json new file mode 100644 index 00000000000..9d509d1398a --- /dev/null +++ b/i18n/trk/extensions/git/out/scmProvider.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "commit": "Commit'le" +} \ No newline at end of file diff --git a/i18n/trk/extensions/git/out/statusbar.i18n.json b/i18n/trk/extensions/git/out/statusbar.i18n.json new file mode 100644 index 00000000000..eb7a0d55141 --- /dev/null +++ b/i18n/trk/extensions/git/out/statusbar.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "checkout": "GeçiÅŸ yap...", + "sync changes": "DeÄŸiÅŸiklikleri Senkronize Et", + "publish changes": "DeÄŸiÅŸiklikleri Yayınla", + "syncing changes": "DeÄŸiÅŸiklikler Senkronize Ediliyor..." +} \ No newline at end of file diff --git a/i18n/trk/extensions/git/package.i18n.json b/i18n/trk/extensions/git/package.i18n.json new file mode 100644 index 00000000000..9789311accf --- /dev/null +++ b/i18n/trk/extensions/git/package.i18n.json @@ -0,0 +1,49 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "command.clone": "Klonla", + "command.init": "Depo OluÅŸtur", + "command.refresh": "Yenile", + "command.openChange": "DeÄŸiÅŸiklikleri Aç", + "command.openFile": "Dosya Aç", + "command.stage": "DeÄŸiÅŸiklikleri Hazırla", + "command.stageAll": "Tüm DeÄŸiÅŸiklikleri Hazırla", + "command.stageSelectedRanges": "Seçili Aralığı Hazırla", + "command.revertSelectedRanges": "Seçili Aralığı Geri Al", + "command.unstage": "DeÄŸiÅŸiklikleri Hazırlık Alanından Geri Al", + "command.unstageAll": "Tüm DeÄŸiÅŸiklikleri Hazırlık Alanından Geri Al", + "command.unstageSelectedRanges": "Seçili Alanı Hazırlık Alanından Geri Al", + "command.clean": "DeÄŸiÅŸiklikleri Göz Ardı Et", + "command.cleanAll": "Tüm DeÄŸiÅŸiklikleri Göz Ardı Et", + "command.commit": "Commit'le", + "command.commitStaged": "Hazırlananları Commit'le", + "command.commitStagedSigned": "Hazırlananları Commit'le (Ä°mzalı)", + "command.commitAll": "Tümünü Commit'le", + "command.commitAllSigned": "Tümünü Commit'le (Ä°mzalı)", + "command.undoCommit": "Son Commit'i Geri Al", + "command.checkout": "GeçiÅŸ yap...", + "command.branch": "Dal OluÅŸtur...", + "command.deleteBranch": "Dalı Sil...", + "command.pull": "Çek", + "command.pullRebase": "Çek (Yeniden Adresle)", + "command.push": "Gönder", + "command.pushTo": "Gönder...", + "command.sync": "Senkronize Et", + "command.publish": "Dalı Yayınla", + "command.showOutput": "Git Çıktısını Göster", + "config.enabled": "Git'in etkinleÅŸtirilip etkinleÅŸtirilmediÄŸi", + "config.path": "Çalıştırılabilir Git dosyasının yolu", + "config.autorefresh": "Otomatik yenilemenin etkinleÅŸtirilip etkinleÅŸtirilmediÄŸi", + "config.autofetch": "Otomatik getirmenin etkinleÅŸtirilip etkinleÅŸtirilmediÄŸi", + "config.enableLongCommitWarning": "Uzun commit mesajları hakkında uyarıda bulunulup bulunulmayacağı", + "config.confirmSync": "Git depolarını senkronize etmeden önce onaylayın", + "config.countBadge": "Git gösterge sayacını denetler. `all` tüm deÄŸiÅŸiklikleri sayar. `tracked` sadece izlenen deÄŸiÅŸikliklikleri sayar. `off` ise kapatır.", + "config.checkoutType": "`GeçiÅŸ Yap...` çalıştırılırken listelenecek dal türlerini denetler. `all` tüm baÅŸvuruları gösterir, `local` sadece yerel dalları gösterir, `tags` sadece etiketleri gösterir ve `remote` sadece uzak uçbirim dallarını gösterir.", + "config.ignoreLegacyWarning": "Eski Git uyarısını görmezden gelir", + "config.ignoreLimitWarning": "Bir depoda çok fazla deÄŸiÅŸiklik var uyarısını görmezden gelir", + "config.defaultCloneDirectory": "Bir git deposunun kopyalanacağı varsayılan konum", + "config.enableSmartCommit": "Hazırlanan deÄŸiÅŸiklik yoksa tüm deÄŸiÅŸiklikleri commit'le." +} \ No newline at end of file diff --git a/i18n/trk/extensions/grunt/out/main.i18n.json b/i18n/trk/extensions/grunt/out/main.i18n.json new file mode 100644 index 00000000000..a379bb7fabe --- /dev/null +++ b/i18n/trk/extensions/grunt/out/main.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "execFailed": "Grunt otomatik tespiti hata ile sonuçlandı: {0}" +} \ No newline at end of file diff --git a/i18n/trk/extensions/grunt/package.i18n.json b/i18n/trk/extensions/grunt/package.i18n.json new file mode 100644 index 00000000000..0a027f4d954 --- /dev/null +++ b/i18n/trk/extensions/grunt/package.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "config.grunt.autoDetect": "Grunt görevlerinin otomatik olarak algılanıp algılanmayacağını denetler. Varsayılan olarak açıktır." +} \ No newline at end of file diff --git a/i18n/trk/extensions/gulp/out/main.i18n.json b/i18n/trk/extensions/gulp/out/main.i18n.json new file mode 100644 index 00000000000..419e64b90d8 --- /dev/null +++ b/i18n/trk/extensions/gulp/out/main.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "execFailed": "Gulp otomatik tespiti hata ile sonuçlandı: {0}" +} \ No newline at end of file diff --git a/i18n/trk/extensions/gulp/package.i18n.json b/i18n/trk/extensions/gulp/package.i18n.json new file mode 100644 index 00000000000..11a00f49019 --- /dev/null +++ b/i18n/trk/extensions/gulp/package.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "config.gulp.autoDetect": "Gulp görevlerinin otomatik olarak algılanıp algılanmayacağını denetler. Varsayılan olarak açıktır." +} \ No newline at end of file diff --git a/i18n/trk/extensions/html/client/out/htmlMain.i18n.json b/i18n/trk/extensions/html/client/out/htmlMain.i18n.json new file mode 100644 index 00000000000..768300d269b --- /dev/null +++ b/i18n/trk/extensions/html/client/out/htmlMain.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "htmlserver.name": "HTML Dil Sunucusu" +} \ No newline at end of file diff --git a/i18n/trk/extensions/html/package.i18n.json b/i18n/trk/extensions/html/package.i18n.json new file mode 100644 index 00000000000..ee68938c898 --- /dev/null +++ b/i18n/trk/extensions/html/package.i18n.json @@ -0,0 +1,27 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "html.format.enable.desc": "Varsayılan HTML biçimlendiricisini etkinleÅŸtirin/devre dışı bırakın (yeniden baÅŸlatma gerektirir)", + "html.format.wrapLineLength.desc": "Satır başına en fazla karakter miktarı (0 = devre dışı bırak)", + "html.format.unformatted.desc": "Yeniden biçimlendirilmeyecek virgülle ayrılmış etiketler listesi. 'null' deÄŸeri, https://www.w3.org/TR/html5/dom.html#phrasing-content adresinde listelenen tüm etiketleri varsayılan olarak belirler.", + "html.format.contentUnformatted.desc": "İçeriÄŸin yeniden biçimlendirilmeyeceÄŸi virgülle ayrılmış etiketler listesi. 'null' deÄŸeri, 'pre' etiketini varsayılan olarak belirler.", + "html.format.indentInnerHtml.desc": " ve bölümlerini girintile.", + "html.format.preserveNewLines.desc": "Ögelerden önceki mevcut satır sonlarının korunup korunmayacağı. Yalnızca ögelerden önce çalışır, etiketler içinde veya metinde çalışmaz.", + "html.format.maxPreserveNewLines.desc": "Bir öbekte korunacak maksimum satır sonu sayısı. Sınırsız için 'null' deÄŸerini kullanın.", + "html.format.indentHandlebars.desc": "{{#foo}} ve {{/foo}}'yu biçimlendir ve girintile.", + "html.format.endWithNewline.desc": "BoÅŸ bir satırla bitir.", + "html.format.extraLiners.desc": "Kendilerinden önce ek bir boÅŸ satır bulunması gereken virgülle ayrılmış etiketler listesi. 'null' deÄŸeri, \"head, body, /html\" deÄŸerini varsayılan olarak belirler.", + "html.format.wrapAttributes.desc": "Öznitelikleri sarmala.", + "html.format.wrapAttributes.auto": "Öznitelikleri sadece satır uzunluÄŸu aşıldığında sarmala.", + "html.format.wrapAttributes.force": "Ä°lki hariç tüm öznitelikleri sarmala.", + "html.format.wrapAttributes.forcealign": "Ä°lki hariç tüm öznitelikleri sarmala ve hizada tut.", + "html.format.wrapAttributes.forcemultiline": "Tüm öznitelikleri sarmala.", + "html.suggest.angular1.desc": "YerleÅŸik HTML dili desteÄŸinin Angular V1 etiketlerini ve özelliklerini önerip önermeyeceÄŸini yapılandırır.", + "html.suggest.ionic.desc": "YerleÅŸik HTML dili desteÄŸinin Ionic etiketlerini, özelliklerini ve deÄŸerlerini önerip önermeyeceÄŸini yapılandırır.", + "html.suggest.html5.desc": "YerleÅŸik HTML dili desteÄŸinin HTML5 etiketlerini, özelliklerini ve deÄŸerlerini önerip önermeyeceÄŸini yapılandırır.", + "html.validate.scripts": "YerleÅŸik HTML dili desteÄŸinin HTML5 gömülü betikleri doÄŸrulayıp doÄŸrulamayacağını yapılandırır.", + "html.validate.styles": "YerleÅŸik HTML dili desteÄŸinin HTML5 gömülü stilleri doÄŸrulayıp doÄŸrulamayacağını yapılandırır." +} \ No newline at end of file diff --git a/i18n/trk/extensions/jake/out/main.i18n.json b/i18n/trk/extensions/jake/out/main.i18n.json new file mode 100644 index 00000000000..c94980eca2f --- /dev/null +++ b/i18n/trk/extensions/jake/out/main.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "execFailed": "Jake otomatik tespiti hata ile sonuçlandı: {0}" +} \ No newline at end of file diff --git a/i18n/trk/extensions/jake/package.i18n.json b/i18n/trk/extensions/jake/package.i18n.json new file mode 100644 index 00000000000..983e8866dea --- /dev/null +++ b/i18n/trk/extensions/jake/package.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "config.jake.autoDetect": "Jake görevlerinin otomatik olarak algılanıp algılanmayacağını denetler. Varsayılan olarak açıktır." +} \ No newline at end of file diff --git a/i18n/trk/extensions/javascript/out/features/bowerJSONContribution.i18n.json b/i18n/trk/extensions/javascript/out/features/bowerJSONContribution.i18n.json new file mode 100644 index 00000000000..8e2b17e627d --- /dev/null +++ b/i18n/trk/extensions/javascript/out/features/bowerJSONContribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "json.bower.default": "Varsayılan bower.json", + "json.bower.error.repoaccess": "Bower deposuna yapılan istek baÅŸarısız oldu: {0}", + "json.bower.latest.version": "en son" +} \ No newline at end of file diff --git a/i18n/trk/extensions/javascript/out/features/packageJSONContribution.i18n.json b/i18n/trk/extensions/javascript/out/features/packageJSONContribution.i18n.json new file mode 100644 index 00000000000..702ad94d30e --- /dev/null +++ b/i18n/trk/extensions/javascript/out/features/packageJSONContribution.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "json.package.default": "Varsayılan package.json", + "json.npm.error.repoaccess": "NPM deposuna yapılan istek baÅŸarısız oldu: {0}", + "json.npm.latestversion": "Paketin ÅŸu andaki en son sürümü", + "json.npm.majorversion": "En son birincil sürümle eÅŸleÅŸiyor (1.x.x)", + "json.npm.minorversion": "En son ikincil sürümle eÅŸleÅŸiyor (1.2.x)", + "json.npm.version.hover": "En son sürüm: {0}" +} \ No newline at end of file diff --git a/i18n/trk/extensions/json/client/out/jsonMain.i18n.json b/i18n/trk/extensions/json/client/out/jsonMain.i18n.json new file mode 100644 index 00000000000..f0d4863e745 --- /dev/null +++ b/i18n/trk/extensions/json/client/out/jsonMain.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "jsonserver.name": "JSON Dil Sunucusu" +} \ No newline at end of file diff --git a/i18n/trk/extensions/json/package.i18n.json b/i18n/trk/extensions/json/package.i18n.json new file mode 100644 index 00000000000..bc1296fa6f9 --- /dev/null +++ b/i18n/trk/extensions/json/package.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "json.schemas.desc": "Åžemaları geçerli projedeki JSON dosyalarıyla iliÅŸkilendir", + "json.schemas.url.desc": "Bir ÅŸemanın URL'si veya geçerli dizindeki bir ÅŸemanın göreli yolu", + "json.schemas.fileMatch.desc": "JSON dosyaları ÅŸemalara çözümlenirken eÅŸleÅŸme için kullanılacak bir dosya düzenleri dizisi.", + "json.schemas.fileMatch.item.desc": "JSON dosyaları ÅŸemalara çözümlenirken eÅŸleÅŸme için '*' içerebilen bir dosya düzeni.", + "json.schemas.schema.desc": "Verilen URL için ÅŸema tanımı. Åžema, yalnızca ÅŸema URL'sine eriÅŸimi önlemek için saÄŸlanmalıdır.", + "json.format.enable.desc": "Varsayılan JSON biçimlendiricisini etkinleÅŸtirin/devre dışı bırakın (yeniden baÅŸlatma gerektirir)", + "json.tracing.desc": "VS Code ve JSON dil sunucusu arasındaki iletiÅŸimi izler.", + "json.colorDecorators.enable.desc": "Renk dekoratörlerini etkinleÅŸtirir veya devre dışı bırakır" +} \ No newline at end of file diff --git a/i18n/trk/extensions/markdown/out/extension.i18n.json b/i18n/trk/extensions/markdown/out/extension.i18n.json new file mode 100644 index 00000000000..de26700eac4 --- /dev/null +++ b/i18n/trk/extensions/markdown/out/extension.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "onPreviewStyleLoadError": "'markdown.styles' yüklenemedi: {0}" +} \ No newline at end of file diff --git a/i18n/trk/extensions/markdown/out/previewContentProvider.i18n.json b/i18n/trk/extensions/markdown/out/previewContentProvider.i18n.json new file mode 100644 index 00000000000..83d25162ae3 --- /dev/null +++ b/i18n/trk/extensions/markdown/out/previewContentProvider.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "preview.securityMessage.text": "Bu belgede betikler devre dışı bırakıldı", + "preview.securityMessage.title": "Markdown önizlemesinde belgede betikler devre dışı bırakılmıştır. Betikleri etkinleÅŸtirmek için Markdown önizleme güvenlik ayarlarını deÄŸiÅŸtirin", + "preview.securityMessage.label": "Betikler Devre Dışı Güvenlik Uyarısı" +} \ No newline at end of file diff --git a/i18n/trk/extensions/markdown/out/security.i18n.json b/i18n/trk/extensions/markdown/out/security.i18n.json new file mode 100644 index 00000000000..f6bd3d45364 --- /dev/null +++ b/i18n/trk/extensions/markdown/out/security.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "preview.showPreviewSecuritySelector.disallowScriptsForWorkspaceTitle": "Bu çalışma alanındaki Markdown önizlemelerinde betik çalıştırmayı devre dışı bırak", + "preview.showPreviewSecuritySelector.currentSelection": "Geçerli ayar", + "preview.showPreviewSecuritySelector.allowScriptsForWorkspaceTitle": "Bu çalışma alanındaki Markdown önizlemelerinde betik çalıştırmayı etkinleÅŸtir", + "preview.showPreviewSecuritySelector.title": "Markdown önizlemesi için güvenlik ayarlarını deÄŸiÅŸtir" +} \ No newline at end of file diff --git a/i18n/trk/extensions/markdown/package.i18n.json b/i18n/trk/extensions/markdown/package.i18n.json new file mode 100644 index 00000000000..67c3c86ed88 --- /dev/null +++ b/i18n/trk/extensions/markdown/package.i18n.json @@ -0,0 +1,22 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "markdown.preview.doubleClickToSwitchToEditor.desc": "Düzenleyiciye geçiÅŸ yapmak için Markdown önizlemesine çift tıklayın.", + "markdown.preview.fontFamily.desc": "Markdown önizlemesinde kullanılan yazı tipi ailesini denetler.", + "markdown.preview.fontSize.desc": "Markdown önizlemesinde kullanılan yazı tipi boyutunu piksel olarak denetler.", + "markdown.preview.lineHeight.desc": "Markdown önizlemesinde kullanılan satır yüksekliÄŸini denetler. Bu sayı yazı tipi boyutuna görecelidir.", + "markdown.preview.markEditorSelection.desc": "Markdown önizlemesinde geçerli düzenleyici seçimini iÅŸaretle.", + "markdown.preview.scrollEditorWithPreview.desc": "Markdown önizlemesi kaydırıldığında, düzenleyicinin görünümünü güncelle.", + "markdown.preview.scrollPreviewWithEditorSelection.desc": "Düzenleyicide seçili satırın görünmesi için Markdown önizlemesini kaydırır.", + "markdown.preview.title": "Önizlemeyi Aç", + "markdown.previewFrontMatter.dec": "YAML ön maddesinin Markdown önizlemesinde nasıl gösterilmesi gerektiÄŸini ayarlar. 'hide' ön maddeyi kaldırır. DiÄŸer türlü; ön madde, Markdown içeriÄŸi olarak sayılır.", + "markdown.previewSide.title": "Önizlemeyi Yana Aç", + "markdown.showSource.title": "Kaynağı Göster", + "markdown.styles.dec": "Markdown önizlemesinde kullanılmak üzere CSS stil dosyalarını iÅŸaret eden bir URL'ler veya yerel yollar listesi. Göreli yollar, gezginde açılan klasöre göreli olarak yorumlanır.", + "markdown.showPreviewSecuritySelector.title": "Markdown Önizleme Güvenlik Ayarlarını DeÄŸiÅŸtir", + "markdown.preview.enableExperimentalExtensionApi.desc": "[Deneysel] Eklentilere Markdown önizlemesini geniÅŸletmek için izin ver.", + "markdown.trace.desc": "Markdown eklentisi için hata ayıklama günlüğünü etkinleÅŸtir." +} \ No newline at end of file diff --git a/i18n/trk/extensions/merge-conflict/out/codelensProvider.i18n.json b/i18n/trk/extensions/merge-conflict/out/codelensProvider.i18n.json new file mode 100644 index 00000000000..26571af8cf3 --- /dev/null +++ b/i18n/trk/extensions/merge-conflict/out/codelensProvider.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "acceptCurrentChange": "Geçerli DeÄŸiÅŸikliÄŸi Kabul Et", + "acceptIncomingChange": "Gelen DeÄŸiÅŸikliÄŸi Kabul Et", + "acceptBothChanges": "Her Ä°ki DeÄŸiÅŸikliÄŸi de Kabul Et", + "compareChanges": "DeÄŸiÅŸiklikleri KarşılaÅŸtır" +} \ No newline at end of file diff --git a/i18n/trk/extensions/merge-conflict/out/commandHandler.i18n.json b/i18n/trk/extensions/merge-conflict/out/commandHandler.i18n.json new file mode 100644 index 00000000000..3811062c8a3 --- /dev/null +++ b/i18n/trk/extensions/merge-conflict/out/commandHandler.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "cursorNotInConflict": "Düzenleyici imleci birleÅŸtirme çakışması içinde deÄŸil", + "compareChangesTitle": "{0}: Geçerli DeÄŸiÅŸiklikler ⟷ Gelen DeÄŸiÅŸiklikler", + "cursorOnCommonAncestorsRange": "Düzenleyici imleci ortak atalar bloÄŸunda, imleci lütfen \"geçerli\" veya \"gelen\" bloÄŸundan birine getirin", + "cursorOnSplitterRange": "Düzenleyici imleci birleÅŸtirme çakışması ayırıcısında, imleci lütfen \"geçerli\" veya \"gelen\" bloÄŸundan birine getirin", + "noConflicts": "Bu dosyada birleÅŸtirme çakışması bulunamadı", + "noOtherConflictsInThisFile": "Bu dosyada baÅŸka birleÅŸtirme çakışması bulunamadı" +} \ No newline at end of file diff --git a/i18n/trk/extensions/merge-conflict/out/mergeDecorator.i18n.json b/i18n/trk/extensions/merge-conflict/out/mergeDecorator.i18n.json new file mode 100644 index 00000000000..4e7bccae262 --- /dev/null +++ b/i18n/trk/extensions/merge-conflict/out/mergeDecorator.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "currentChange": "(Geçerli DeÄŸiÅŸiklik)", + "incomingChange": "(Gelen DeÄŸiÅŸiklik)" +} \ No newline at end of file diff --git a/i18n/trk/extensions/merge-conflict/package.i18n.json b/i18n/trk/extensions/merge-conflict/package.i18n.json new file mode 100644 index 00000000000..75e7f2cd722 --- /dev/null +++ b/i18n/trk/extensions/merge-conflict/package.i18n.json @@ -0,0 +1,20 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "command.category": "BirleÅŸtirme Çakışması", + "command.accept.all-incoming": "Gelen Tümünü Kabul Et", + "command.accept.all-both": "Tümünü Birden Kabul Et", + "command.accept.current": "Åžuan Geçerli Olanı Kabul Et", + "command.accept.incoming": "Geleni Kabul Et", + "command.accept.selection": "Seçimi Kabul Et", + "command.accept.both": "Her Ä°kisini de Kabul Et", + "command.next": "Sonraki Çakışma", + "command.previous": "Önceki Çakışma", + "command.compare": "Geçerli Çakışmayı KarşılaÅŸtır", + "config.title": "BirleÅŸtirme Çakışması", + "config.codeLensEnabled": "Düzenleyicideki birleÅŸtirme çakışması bloÄŸu kod objektifini etkinleÅŸtir veya devre dışı bırak", + "config.decoratorsEnabled": "Düzenleyicideki birleÅŸtirme çakışması dekoratörlerini etkinleÅŸtir veya devre dışı bırak" +} \ No newline at end of file diff --git a/i18n/trk/extensions/npm/package.i18n.json b/i18n/trk/extensions/npm/package.i18n.json new file mode 100644 index 00000000000..5bda141ad8b --- /dev/null +++ b/i18n/trk/extensions/npm/package.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "config.npm.autoDetect": "Npm betiklerinin otomatik olarak algılanıp algılanmayacağını denetler. Varsayılan olarak açıktır." +} \ No newline at end of file diff --git a/i18n/trk/extensions/php/out/features/validationProvider.i18n.json b/i18n/trk/extensions/php/out/features/validationProvider.i18n.json new file mode 100644 index 00000000000..dbfa92074c8 --- /dev/null +++ b/i18n/trk/extensions/php/out/features/validationProvider.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "php.useExecutablePath": "{0} (çalışma alanı ayarı olarak tanımlı) yürütülebilir dosyasına PHP dosyalarını doÄŸrulama izni veriyor musunuz?", + "php.yes": "Ä°zin Ver", + "php.no": "Ä°zin Verme", + "wrongExecutable": "{0} geçerli bir php yürütülebilir dosyası olmadığı için doÄŸrulanamıyor. PHP yürütülebilir dosyasını yapılandırmak için 'php.validate.executablePath' ayarını kullanın.", + "noExecutable": "Hiçbir PHP yürütülebilir dosyası ayarlanmadığı için doÄŸrulanamıyor. PHP yürütülebilir dosyasını yapılandırmak için 'php.validate.executablePath' ayarını kullanın.", + "unknownReason": "{0} yolu kullanılarak php çalıştırılamadı. Sebep bilinmiyor." +} \ No newline at end of file diff --git a/i18n/trk/extensions/php/package.i18n.json b/i18n/trk/extensions/php/package.i18n.json new file mode 100644 index 00000000000..d0a4266c125 --- /dev/null +++ b/i18n/trk/extensions/php/package.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "configuration.suggest.basic": "YerleÅŸik PHP dili önerilerinin etkinleÅŸtirilip etkinleÅŸtirilmediÄŸini yapılandırır. Destek, PHP globalleri ve deÄŸiÅŸkenleri önerir.", + "configuration.validate.enable": "YerleÅŸik PHP doÄŸrulamasını etkinleÅŸtir/devre dışı bırak.", + "configuration.validate.executablePath": "PHP çalıştırılabilir dosyasına iÅŸaret eder.", + "configuration.validate.run": "DoÄŸrulayıcının kayıt esnasında mı tuÅŸlama esnasında mı çalışacağı.", + "configuration.title": "PHP", + "commands.categroy.php": "PHP", + "command.untrustValidationExecutable": "PHP doÄŸrulama yürütülebilir dosyasına izin verme (çalışma alanı ayarı olarak tanımlanır)" +} \ No newline at end of file diff --git a/i18n/trk/extensions/typescript/out/features/bufferSyncSupport.i18n.json b/i18n/trk/extensions/typescript/out/features/bufferSyncSupport.i18n.json new file mode 100644 index 00000000000..a496aae13e0 --- /dev/null +++ b/i18n/trk/extensions/typescript/out/features/bufferSyncSupport.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "versionMismatch": "Düzenleyici özellikleri için TypeScript ({1}) kullanılıyor. TypeScript ({0}) makinanızda global olarak yüklenmiÅŸ durumda. VS Code'daki hatalar TSC hatalarından farklı olabilir", + "moreInformation": "Daha Fazla Bilgi", + "doNotCheckAgain": "Tekrar Kontrol Etme", + "close": "Kapat", + "updateTscCheck": "Kullanıcı ayarı 'typescript.check.tscVersion', \"false\" olarak güncellendi" +} \ No newline at end of file diff --git a/i18n/trk/extensions/typescript/out/features/completionItemProvider.i18n.json b/i18n/trk/extensions/typescript/out/features/completionItemProvider.i18n.json new file mode 100644 index 00000000000..de2a515d9ab --- /dev/null +++ b/i18n/trk/extensions/typescript/out/features/completionItemProvider.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "acquiringTypingsLabel": "TuÅŸlamalar alınıyor...", + "acquiringTypingsDetail": "IntelliSense için tuÅŸlama tanımları alınıyor..." +} \ No newline at end of file diff --git a/i18n/trk/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json b/i18n/trk/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json new file mode 100644 index 00000000000..de25bb3c5f8 --- /dev/null +++ b/i18n/trk/extensions/typescript/out/features/directiveCommentCompletionProvider.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ts-check": "Bir JavaScript dosyasının anlamsal kontrolünü etkinleÅŸtirir. Bir dosyanın en üstünde olmalıdır.", + "ts-nocheck": "Bir JavaScript dosyasının anlamsal kontrolünü devre dışı bırakır. Bir dosyanın en üstünde olmalıdır.", + "ts-ignore": "Bir dosyanın sonraki satırında @ts-check hatalarını bastırır." +} \ No newline at end of file diff --git a/i18n/trk/extensions/typescript/out/features/implementationsCodeLensProvider.i18n.json b/i18n/trk/extensions/typescript/out/features/implementationsCodeLensProvider.i18n.json new file mode 100644 index 00000000000..05ad64ea382 --- /dev/null +++ b/i18n/trk/extensions/typescript/out/features/implementationsCodeLensProvider.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "oneImplementationLabel": "1 uygulama", + "manyImplementationLabel": "{0} uygulama", + "implementationsErrorLabel": "Uygulamalar belirlenemedi" +} \ No newline at end of file diff --git a/i18n/trk/extensions/typescript/out/features/jsDocCompletionProvider.i18n.json b/i18n/trk/extensions/typescript/out/features/jsDocCompletionProvider.i18n.json new file mode 100644 index 00000000000..203488810a2 --- /dev/null +++ b/i18n/trk/extensions/typescript/out/features/jsDocCompletionProvider.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "typescript.jsDocCompletionItem.documentation": "JSDoc yorumu" +} \ No newline at end of file diff --git a/i18n/trk/extensions/typescript/out/features/referencesCodeLensProvider.i18n.json b/i18n/trk/extensions/typescript/out/features/referencesCodeLensProvider.i18n.json new file mode 100644 index 00000000000..34242b70057 --- /dev/null +++ b/i18n/trk/extensions/typescript/out/features/referencesCodeLensProvider.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "oneReferenceLabel": "1 baÅŸvuru", + "manyReferenceLabel": "{0} baÅŸvuru", + "referenceErrorLabel": "BaÅŸvurular belirlenemedi" +} \ No newline at end of file diff --git a/i18n/trk/extensions/typescript/out/typescriptMain.i18n.json b/i18n/trk/extensions/typescript/out/typescriptMain.i18n.json new file mode 100644 index 00000000000..2751d3bb07c --- /dev/null +++ b/i18n/trk/extensions/typescript/out/typescriptMain.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "typescript.projectConfigNoWorkspace": "Bir TypeScript veya JavaScript projesini kullanmak için lütfen bir klasör açın", + "typescript.projectConfigUnsupportedFile": "TypeScript mi yoksa JavaScript mi projesi olduÄŸu tespit edilemedi. Desteklenmeyen dosya türü", + "typescript.projectConfigCouldNotGetInfo": "TypeScript mi yoksa JavaScript mi projesi olduÄŸu tespit edilemedi", + "typescript.noTypeScriptProjectConfig": "Dosya bir TypeScript projesinin bir parçası deÄŸil", + "typescript.noJavaScriptProjectConfig": "Dosya bir JavaScript projesinin bir parçası deÄŸil", + "typescript.configureTsconfigQuickPick": "tsconfig.json'u yapılandır", + "typescript.configureJsconfigQuickPick": "jsconfig.json'u yapılandır", + "typescript.projectConfigLearnMore": "Daha Fazla Bilgi Edin" +} \ No newline at end of file diff --git a/i18n/trk/extensions/typescript/out/typescriptServiceClient.i18n.json b/i18n/trk/extensions/typescript/out/typescriptServiceClient.i18n.json new file mode 100644 index 00000000000..3cdde46b706 --- /dev/null +++ b/i18n/trk/extensions/typescript/out/typescriptServiceClient.i18n.json @@ -0,0 +1,24 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noServerFound": "{0} yolu geçerli bir tsserver kurulumuna iÅŸaret etmiyor. PaketlenmiÅŸ TypeScript sürümüne geri dönülüyor.", + "noBundledServerFound": "VSCode'un tsserver'ı hatalı bir virüs tespit aracı gibi bir uygulama tarafından silindi. Lütfen VS Code'u yeniden yükleyin", + "versionNumber.custom": "özel", + "serverCouldNotBeStarted": "TypeScript dil sunucusu baÅŸlatılamadı. Hata mesajı: {0}", + "useVSCodeVersionOption": "VSCode'un Sürümünü Kullan", + "activeVersion": "Åžu an aktif", + "useWorkspaceVersionOption": "Çalışma Alanı Sürümünü Kullan", + "learnMore": "Daha Fazla Bilgi Edin", + "selectTsVersion": "JavaScript ve TypeScript dil özellikleri için kullanılacak TypeScript sürümünü seçin", + "typescript.openTsServerLog.notSupported": "TS Sunucu günlüğü için TS 2.2.2+ gerekiyor", + "typescript.openTsServerLog.loggingNotEnabled": "TS Sunucu günlüğü kapalı. Lütfen `typescript.tsserver.log` ögesini ayarlayın ve günlüğe yazmayı etkinleÅŸtirmek için TS sunucusunu yeniden baÅŸlatın", + "typescript.openTsServerLog.enableAndReloadOption": "Günlüğe yazmayı etkinleÅŸtir ve TS sunucusunu yeniden baÅŸlat", + "typescript.openTsServerLog.noLogFile": "TS sunucu günlüğe yazmaya baÅŸlamadı.", + "openTsServerLog.openFileFailedFailed": "TS Sunucu günlük dosyası açılamadı", + "serverDiedAfterStart": "TypeScript dil hizmeti, baÅŸladıktan hemen sonra 5 kez kapandı. Hizmet yeniden baÅŸlatılmayacaktır.", + "serverDiedReportIssue": "Sorun Bildir", + "serverDied": "TypeScript dil hizmeti, son 5 dakikada 5 kez beklenmedik ÅŸekilde kapandı." +} \ No newline at end of file diff --git a/i18n/trk/extensions/typescript/out/utils/logger.i18n.json b/i18n/trk/extensions/typescript/out/utils/logger.i18n.json new file mode 100644 index 00000000000..bc738f43d0c --- /dev/null +++ b/i18n/trk/extensions/typescript/out/utils/logger.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "channelName": "TypeScript" +} \ No newline at end of file diff --git a/i18n/trk/extensions/typescript/out/utils/projectStatus.i18n.json b/i18n/trk/extensions/typescript/out/utils/projectStatus.i18n.json new file mode 100644 index 00000000000..3deea612eab --- /dev/null +++ b/i18n/trk/extensions/typescript/out/utils/projectStatus.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "hintExclude": "Proje çapında JavaScript/TypeScript dil özelliklerini etkinleÅŸtirmek için, ÅŸunlar gibi birçok dosyaya sahip klasörleri hariç tutun: {0}", + "hintExclude.generic": "Proje çapında JavaScript/TypeScript dil özelliklerini etkinleÅŸtirmek için, üzerinde çalışmadığınız kaynak dosyalar içeren büyük klasörleri hariç tutun.", + "large.label": "Hariç Tutmaları Yapılandır", + "hintExclude.tooltip": "Proje çapında JavaScript/TypeScript dil özelliklerini etkinleÅŸtirmek için, üzerinde çalışmadığınız kaynak dosyalar içeren büyük klasörleri hariç tutun." +} \ No newline at end of file diff --git a/i18n/trk/extensions/typescript/out/utils/typingsStatus.i18n.json b/i18n/trk/extensions/typescript/out/utils/typingsStatus.i18n.json new file mode 100644 index 00000000000..acdcdf70be5 --- /dev/null +++ b/i18n/trk/extensions/typescript/out/utils/typingsStatus.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "installingPackages": "Daha iyi TypeScript IntelliSense için veri alınıyor", + "typesInstallerInitializationFailed.title": "JavaScript dil özellikleri için tuÅŸlama dosyaları yüklenemedi. Lütfen NPM'in yüklenmiÅŸ olduÄŸundan veya kullanıcı ayarlarınızda 'typescript.npm' ögesini yapılandırın", + "typesInstallerInitializationFailed.moreInformation": "Daha Fazla Bilgi", + "typesInstallerInitializationFailed.doNotCheckAgain": "Tekrar Kontrol Etme", + "typesInstallerInitializationFailed.close": "Kapat" +} \ No newline at end of file diff --git a/i18n/trk/extensions/typescript/package.i18n.json b/i18n/trk/extensions/typescript/package.i18n.json new file mode 100644 index 00000000000..a730294ce6b --- /dev/null +++ b/i18n/trk/extensions/typescript/package.i18n.json @@ -0,0 +1,48 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "typescript.reloadProjects.title": "Projeyi Yeniden Yükle", + "javascript.reloadProjects.title": "Projeyi Yeniden Yükle", + "configuration.typescript": "TypeScript", + "typescript.useCodeSnippetsOnMethodSuggest.dec": "Ä°ÅŸlevleri parametre imzalarıyla tamamlayın.", + "typescript.tsdk.desc": "Kullanılacak tsserver ve lib*.d.ts dosyalarını içeren klasör yolunu belirtir.", + "typescript.disableAutomaticTypeAcquisition": "Otomatik tür kazanımını devre dışı bırakır. TypeScript >= 2.0.6 ve deÄŸiÅŸtirildikten sonra yeniden baÅŸlatma gerektirir.", + "typescript.check.tscVersion": "Global TypeScript derleyicisinin(ör. tsc) kullanılan TypeScript dil hizmetinden farklı olup olmadığını kontrol et.", + "typescript.tsserver.log": "TS sunucusunun bir dosyaya günlük yazmasını etkinleÅŸtirir. Bu günlük, TS Sunucu sorunlarını teÅŸhis etmek için kullanılabilir. Günlük dosya yollarını, kaynak kodunu ve projenizdeki diÄŸer muhtemel hassas bilgileri içerebilir.", + "typescript.tsserver.trace": "TS sunucusuna gönderilen mesajları izlemeyi etkinleÅŸtirir. Bu izleme, TS Sunucu sorunlarını teÅŸhis etmek için kullanılabilir. Ä°zleme; dosya yollarını, kaynak kodunu ve projenizdeki diÄŸer muhtemel hassas bilgileri içerebilir.", + "typescript.validate.enable": "TypeScript doÄŸrulamasını etkinleÅŸtir veya devre dışı bırak.", + "typescript.format.enable": "Varsayılan TypeScript biçimlendiricisini etkinleÅŸtirin/devre dışı bırakın.", + "javascript.format.enable": "Varsayılan JavaScript biçimlendiricisini etkinleÅŸtir veya devre dışı bırak.", + "format.insertSpaceAfterCommaDelimiter": "Virgül sınırlayıcısından sonra boÅŸluk eklenmesini tanımlar.", + "format.insertSpaceAfterConstructor": "OluÅŸturucu anahtar kelimesinden sonra boÅŸluk eklenip eklenmeyeceÄŸini tanımlar. TypeScript >= 2.3.0 gerektirir.", + "format.insertSpaceAfterSemicolonInForStatements": "Bir ifade için noktalı virgülden sonra boÅŸluk eklenmesini tanımlar.", + "format.insertSpaceBeforeAndAfterBinaryOperators": "Bir ikili operatöründen sonra boÅŸluk eklenmesini tanımlar.", + "format.insertSpaceAfterKeywordsInControlFlowStatements": "Bir kontrol akışı ifadesi için anahtar kelimelerden sonra boÅŸluk eklenmesini tanımlar.", + "format.insertSpaceAfterFunctionKeywordForAnonymousFunctions": "Anonim fonksiyonlar için \"function\" anahtar kelimesinden sonra boÅŸluk eklenmesini tanımlar.", + "format.insertSpaceBeforeFunctionParenthesis": "Fonksiyon argüman parantezlerinden önce boÅŸluk eklenmesini tanımlar. TypeScript >= 2.1.5 gerektirir.", + "format.insertSpaceAfterOpeningAndBeforeClosingNonemptyParenthesis": "BoÅŸ olmayan parantezler açıldıktan sonra ve kapatılmadan önce boÅŸluk eklenmesini tanımlar.", + "format.insertSpaceAfterOpeningAndBeforeClosingNonemptyBrackets": "BoÅŸ olmayan köşeli parantezler açıldıktan sonra ve kapatılmadan önce boÅŸluk eklenmesini tanımlar.", + "format.insertSpaceAfterOpeningAndBeforeClosingNonemptyBraces": "BoÅŸ olmayan küme parantezleri açıldıktan sonra ve kapatılmadan önce boÅŸluk eklenmesini tanımlar. TypeScript >= 2.3.0 gerektirir.", + "format.insertSpaceAfterOpeningAndBeforeClosingTemplateStringBraces": "Åžablon dizesi ayraçları açıldıktan sonra ve kapatılmadan önce boÅŸluk eklenmesini tanımlar. TypeScript >= 2.0.6 gerektirir.", + "format.insertSpaceAfterOpeningAndBeforeClosingJsxExpressionBraces": "JSX ifadesi ayraçları açıldıktan sonra ve kapatılmadan önce boÅŸluk eklenmesini tanımlar. TypeScript >= 2.0.6 gerektirir.", + "format.placeOpenBraceOnNewLineForFunctions": "Fonksiyonlarda bir açılış ayracının yeni satıra koyulup koyulmayacağını tanımlar.", + "format.placeOpenBraceOnNewLineForControlBlocks": "Kontrol bloklarında bir açılış ayracının yeni satıra koyulup koyulmayacağını tanımlar.", + "javascript.validate.enable": "JavaScript doÄŸrulamasını etkinleÅŸtir veya devre dışı bırak.", + "typescript.goToProjectConfig.title": "Proje Yapılandırmasına Git", + "javascript.goToProjectConfig.title": "Proje Yapılandırmasına Git", + "javascript.referencesCodeLens.enabled": "JavaScript dosyalarında baÅŸvuru kod objektifini etkinleÅŸtir veya devre dışı bırak.", + "typescript.referencesCodeLens.enabled": "TypeScript dosyalarında baÅŸvuru kod objektifini etkinleÅŸtir veya devre dışı bırak. TypeScript >= 2.0.6 gerektirir.", + "typescript.implementationsCodeLens.enabled": "Uygulama kod objektifini etkinleÅŸtir veya devre dışı bırak. TypeScript >= 2.2.0 gerektirir.", + "typescript.openTsServerLog.title": "TS Sunucu günlüğünü aç", + "typescript.restartTsServer": "TS sunucusunu yeniden baÅŸlat", + "typescript.selectTypeScriptVersion.title": "TypeScript Sürümünü Seç", + "jsDocCompletion.enabled": "Otomatik JSDoc yorumlarını etkinleÅŸtir veya devre dışı bırak.", + "javascript.implicitProjectConfig.checkJs": "JavaScript dosyalarının anlamsal kontrolünü etkinleÅŸtir veya devre dışı bırak. Mevcut jsconfig.json veya tsconfig.json dosyaları bu ayarı geçersiz kılar. TypeScript >= 2.3.1 gerektirir.", + "typescript.npm": "Otomatik Tür Kazanımı için kullanılacak NPM yürütülebilir dosyasının yolunu belirtir. TypeScript >= 2.3.4 gerektirir.", + "typescript.check.npmIsInstalled": "Otomatik Tür Kazanımı için NPM'in yüklü olup olmadığını kontrol et.", + "javascript.nameSuggestions": "JavaScript öneri listelerindeki dosyadan benzersiz adları eklemeyi etkinleÅŸtir veya devre dışı bırak.", + "typescript.tsc.autoDetect": "Tsc görevlerinin otomatik olarak algılanıp algılanmayacağını denetler. Varsayılan olarak açıktır." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/base/browser/ui/actionbar/actionbar.i18n.json b/i18n/trk/src/vs/base/browser/ui/actionbar/actionbar.i18n.json new file mode 100644 index 00000000000..4ecb2c803f4 --- /dev/null +++ b/i18n/trk/src/vs/base/browser/ui/actionbar/actionbar.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "titleLabel": "{0} ({1})" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/base/browser/ui/aria/aria.i18n.json b/i18n/trk/src/vs/base/browser/ui/aria/aria.i18n.json new file mode 100644 index 00000000000..4fa2c84df10 --- /dev/null +++ b/i18n/trk/src/vs/base/browser/ui/aria/aria.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "repeated": "{0} (tekrar oluÅŸtu)" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/base/browser/ui/findinput/findInput.i18n.json b/i18n/trk/src/vs/base/browser/ui/findinput/findInput.i18n.json new file mode 100644 index 00000000000..93c6910157d --- /dev/null +++ b/i18n/trk/src/vs/base/browser/ui/findinput/findInput.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defaultLabel": "giriÅŸ" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/base/browser/ui/findinput/findInputCheckboxes.i18n.json b/i18n/trk/src/vs/base/browser/ui/findinput/findInputCheckboxes.i18n.json new file mode 100644 index 00000000000..d8764ffb998 --- /dev/null +++ b/i18n/trk/src/vs/base/browser/ui/findinput/findInputCheckboxes.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "caseDescription": "Büyük/Küçük Harf EÅŸleÅŸtir", + "wordsDescription": "Sözcüğün Tamamını EÅŸleÅŸtir", + "regexDescription": "Normal Ä°fade Kullan" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/base/browser/ui/inputbox/inputBox.i18n.json b/i18n/trk/src/vs/base/browser/ui/inputbox/inputBox.i18n.json new file mode 100644 index 00000000000..3981d7f1e2d --- /dev/null +++ b/i18n/trk/src/vs/base/browser/ui/inputbox/inputBox.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "alertErrorMessage": "Hata: {0}", + "alertWarningMessage": "Uyarı: {0}", + "alertInfoMessage": "Bilgi: {0}" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json b/i18n/trk/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json new file mode 100644 index 00000000000..8da49a2d7b0 --- /dev/null +++ b/i18n/trk/src/vs/base/browser/ui/resourceviewer/resourceViewer.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "imgMeta": "{0}x{1} {2}", + "largeImageError": "Resim, düzenleyicide görüntülemek için çok büyük.", + "resourceOpenExternalButton": "Harici program kullanarak resmi aç", + "nativeBinaryError": "Dosya ikili olduÄŸu, çok büyük olduÄŸu veya desteklenmeyen bir metin kodlaması kullandığı için düzenleyicide görüntülenemiyor.", + "sizeB": "{0}B", + "sizeKB": "{0}KB", + "sizeMB": "{0}MB", + "sizeGB": "{0}GB", + "sizeTB": "{0}TB" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/base/browser/ui/toolbar/toolbar.i18n.json b/i18n/trk/src/vs/base/browser/ui/toolbar/toolbar.i18n.json new file mode 100644 index 00000000000..634046fb44b --- /dev/null +++ b/i18n/trk/src/vs/base/browser/ui/toolbar/toolbar.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "more": "DiÄŸer" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/base/common/errorMessage.i18n.json b/i18n/trk/src/vs/base/common/errorMessage.i18n.json new file mode 100644 index 00000000000..354f33fe533 --- /dev/null +++ b/i18n/trk/src/vs/base/common/errorMessage.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "message": "{0}. Hata kodu: {1}", + "error.permission.verbose": "Ä°zin Verilmedi (HTTP {0})", + "error.permission": "Ä°zin Verilmedi", + "error.http.verbose": "{0} (HTTP {1}: {2})", + "error.http": "{0} (HTTP {1})", + "error.connection.unknown.verbose": "Bilinmeyen BaÄŸlantı Hatası ({0})", + "error.connection.unknown": "Bilinmeyen bir baÄŸlantı hatası oluÅŸtu. Artık Ä°nternet'e baÄŸlı deÄŸilsiniz veya baÄŸlandığınız sunucu çevrimdışı.", + "stackTrace.format": "{0}: {1}", + "error.defaultMessage": "Bilinmeyen bir hata oluÅŸtu. Daha fazla ayrıntı için lütfen günlüğe baÅŸvurun.", + "error.moreErrors": "{0} (toplam {1} hata)" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/base/common/jsonErrorMessages.i18n.json b/i18n/trk/src/vs/base/common/jsonErrorMessages.i18n.json new file mode 100644 index 00000000000..e9ca243b511 --- /dev/null +++ b/i18n/trk/src/vs/base/common/jsonErrorMessages.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "error.invalidSymbol": "Geçersiz sembol", + "error.invalidNumberFormat": "Geçersiz sayı biçimi", + "error.propertyNameExpected": "Özellik adı bekleniyor", + "error.valueExpected": "DeÄŸer bekleniyor", + "error.colonExpected": "Ä°ki nokta üst üste bekleniyor", + "error.commaExpected": "Virgül bekleniyor", + "error.closeBraceExpected": "Kapanış ayracı bekleniyor", + "error.closeBracketExpected": "Kapanış köşeli ayracı bekleniyor", + "error.endOfFileExpected": "Dosya sonu bekleniyor" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/base/common/keybindingLabels.i18n.json b/i18n/trk/src/vs/base/common/keybindingLabels.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/trk/src/vs/base/common/keybindingLabels.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/trk/src/vs/base/common/processes.i18n.json b/i18n/trk/src/vs/base/common/processes.i18n.json new file mode 100644 index 00000000000..3ffd209b1c9 --- /dev/null +++ b/i18n/trk/src/vs/base/common/processes.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ExecutableParser.commandMissing": "Hata: yürütülebilir bilgi dize türünde bir komut tanımlamalıdır.", + "ExecutableParser.isShellCommand": "Uyarı: isShellCommand boole türünde olmalıdır. {0} deÄŸeri yok sayıldı.", + "ExecutableParser.args": "Uyarı: argümanlar \"string[]\" türünde olmalıdır. {0} deÄŸeri yok sayıldı.", + "ExecutableParser.invalidCWD": "Uyarı: options.cwd dize türünde olmalıdır. {0} deÄŸeri yok sayıldı." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/base/common/severity.i18n.json b/i18n/trk/src/vs/base/common/severity.i18n.json new file mode 100644 index 00000000000..5cd096b2c94 --- /dev/null +++ b/i18n/trk/src/vs/base/common/severity.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "sev.error": "Hata", + "sev.warning": "Uyarı", + "sev.info": "Bilgi" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/base/node/processes.i18n.json b/i18n/trk/src/vs/base/node/processes.i18n.json new file mode 100644 index 00000000000..1e9572a9b91 --- /dev/null +++ b/i18n/trk/src/vs/base/node/processes.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "TaskRunner.UNC": "UNC sürücüsünde kabuk komutu yürütülemez." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/base/node/zip.i18n.json b/i18n/trk/src/vs/base/node/zip.i18n.json new file mode 100644 index 00000000000..1094c4b1628 --- /dev/null +++ b/i18n/trk/src/vs/base/node/zip.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "notFound": "{0}, zip içerisinde bulunamadı." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/base/parts/quickopen/browser/quickOpenModel.i18n.json b/i18n/trk/src/vs/base/parts/quickopen/browser/quickOpenModel.i18n.json new file mode 100644 index 00000000000..300655f6dbd --- /dev/null +++ b/i18n/trk/src/vs/base/parts/quickopen/browser/quickOpenModel.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpenAriaLabelEntry": "{0}, seçici", + "quickOpenAriaLabel": "seçici" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/base/parts/quickopen/browser/quickOpenWidget.i18n.json b/i18n/trk/src/vs/base/parts/quickopen/browser/quickOpenWidget.i18n.json new file mode 100644 index 00000000000..5603016ef86 --- /dev/null +++ b/i18n/trk/src/vs/base/parts/quickopen/browser/quickOpenWidget.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpenAriaLabel": "Hızlı seçici. Sonuçları daraltmak için yazmaya baÅŸlayın.", + "treeAriaLabel": "Hızlı Seçici" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/base/parts/tree/browser/treeDefaults.i18n.json b/i18n/trk/src/vs/base/parts/tree/browser/treeDefaults.i18n.json new file mode 100644 index 00000000000..b6850a5f7ed --- /dev/null +++ b/i18n/trk/src/vs/base/parts/tree/browser/treeDefaults.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "collapse": "Daralt" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/code/electron-main/menus.i18n.json b/i18n/trk/src/vs/code/electron-main/menus.i18n.json new file mode 100644 index 00000000000..3864423636b --- /dev/null +++ b/i18n/trk/src/vs/code/electron-main/menus.i18n.json @@ -0,0 +1,178 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "mFile": "&&Dosya", + "mEdit": "Dü&&zen", + "mSelection": "&&Seçim", + "mView": "&&Görünüm", + "mGoto": "G&&it", + "mDebug": "&&Hata Ayıklama", + "mWindow": "Pencere", + "mHelp": "&&Yardım", + "mTask": "Gö&&revler", + "miNewWindow": "Yeni &&Pencere", + "mAbout": "{0} Hakkında", + "mServices": "Hizmetler", + "mHide": "{0} öğesini gizle", + "mHideOthers": "DiÄŸerlerini Gizle", + "mShowAll": "Tümünü Göster", + "miQuit": "{0} Öğesinden Çık", + "miNewFile": "&&Yeni Dosya", + "miOpen": "&Aç", + "miOpenFolder": "&&Klasör Aç...", + "miOpenFile": "&&Dosya Aç...", + "miOpenRecent": "&&Son Kullanılanları Aç", + "miSave": "&&Kaydet", + "miSaveAs": "&&Farklı Kaydet", + "miSaveAll": "&&Tümünü Kaydet", + "miAutoSave": "Otomatik Kaydet", + "miRevert": "Dosyayı &&Geri Al", + "miCloseWindow": "Pen&&cereyi Kapat", + "miCloseFolder": "K&&lasörü Kapat", + "miCloseEditor": "Dü&&zenleyiciyi Kapat", + "miExit": "Çı&&kış", + "miOpenSettings": "&&Ayarlar", + "miOpenKeymap": "&&Klavye Kısayolları", + "miOpenKeymapExtensions": "&&TuÅŸ Haritası Eklentileri", + "miOpenSnippets": "Kullanıcı &&Parçacıkları", + "miSelectColorTheme": "&&Renk Teması", + "miSelectIconTheme": "&&Dosya Simgesi Teması", + "miPreferences": "T&&ercihler", + "miReopenClosedEditor": "&&Kapatılan Düzenleyiciyi Tekrar Aç", + "miMore": "&&Daha Fazlası...", + "miClearRecentOpen": "&&Son Kullanılan Dosyaları Temizle", + "miUndo": "&&Geri Al", + "miRedo": "&&Yinele", + "miCut": "&&Kes", + "miCopy": "K&&opyala", + "miPaste": "Y&&apıştır", + "miFind": "&&Bul", + "miReplace": "&&DeÄŸiÅŸtir", + "miFindInFiles": "Dosyalarda B&&ul", + "miReplaceInFiles": "Dosyalarda DeÄŸiÅŸ&&tir", + "miEmmetExpandAbbreviation": "Emmet: Kı&&saltmayı GeniÅŸlet", + "miShowEmmetCommands": "E&&mmet...", + "miToggleLineComment": "Satı&&r Yorumunu Aç/Kapat", + "miToggleBlockComment": "Yorum B&&loÄŸunu Aç/Kapat", + "miMultiCursorAlt": "Birden Fazla Ä°mleç İçin Alt+Tıklama Kullan", + "miMultiCursorCmd": "Birden Fazla Ä°mleç İçin Cmd+Tıklama Kullan", + "miMultiCursorCtrl": "Birden Fazla Ä°mleç İçin Ctrl+Tıklama Kullan", + "miInsertCursorAbove": "Yukarıya &&Ä°mleç Ekle", + "miInsertCursorBelow": "AÅŸağıya Ä°&&mleç Ekle", + "miInsertCursorAtEndOfEachLineSelected": "&&Satır Sonlarına Ä°mleç Ekle", + "miAddSelectionToNextFindMatch": "S&&onraki Tekrarlamayı Ekle", + "miAddSelectionToPreviousFindMatch": "Ö&&nceki Tekrarlamayı Ekle", + "miSelectHighlights": "Tüm T&&ekrarlamaları DeÄŸiÅŸtir", + "miCopyLinesUp": "Satırı &&Yukarı Kopyala", + "miCopyLinesDown": "Satırı &&AÅŸağı Kopyala", + "miMoveLinesUp": "Satırı Y&&ukarı Taşı", + "miMoveLinesDown": "Satı&&rı AÅŸağı Taşı", + "miSelectAll": "&&Tümünü Seç", + "miSmartSelectGrow": "Seçimi &&GeniÅŸlet", + "miSmartSelectShrink": "Seçimi &&Daralt", + "miViewExplorer": "&&Gezgin", + "miViewSearch": "&&Arama", + "miViewSCM": "&&SCM", + "miViewDebug": "&&Hata Ayıklama", + "miViewExtensions": "&&Eklentiler", + "miToggleOutput": "Çı&&ktı", + "miToggleDebugConsole": "Hata &&Ayıklama Konsolu", + "miToggleIntegratedTerminal": "Entegre &&Terminal", + "miMarker": "S&&orunlar", + "miAdditionalViews": "&&Ek Görünümler", + "miCommandPalette": "Komut &&Paleti...", + "miToggleFullScreen": "Tam Ekra&&nı Aç/Kapat", + "miToggleZenMode": "Zen Modunu Aç/Kapat", + "miToggleMenuBar": "&&Menü ÇubuÄŸunu Gizle/Göster", + "miSplitEditor": "Düzenleyiciyi &&Böl", + "miToggleEditorLayout": "Dü&&zenleyici Grubu Düzenini DeÄŸiÅŸtir", + "miToggleSidebar": "Ke&&nar ÇubuÄŸunu Aç/Kapat", + "miMoveSidebarRight": "Kenar ÇubuÄŸunu S&&aÄŸa Taşı", + "miMoveSidebarLeft": "Kenar ÇubuÄŸunu S&&ola Taşı", + "miTogglePanel": "&&Paneli Aç/Kapat", + "miHideStatusbar": "&&Durum ÇubuÄŸunu Gizle", + "miShowStatusbar": "&&Du&&rum ÇubuÄŸunu Göster", + "miHideActivityBar": "Etkinlik Ç&&ubuÄŸunu Gizle", + "miShowActivityBar": "Etkinlik Çu&&buÄŸunu Göster", + "miToggleWordWrap": "&&Sözcük Kaydırmasını Aç/Kapat", + "miToggleRenderWhitespace": "&&BoÅŸlukları Görüntülemeyi Aç/Kapat", + "miToggleRenderControlCharacters": "&&Kontrol Karakterlerini Aç/Kapat", + "miZoomIn": "&&YakınlaÅŸtır", + "miZoomOut": "&&UzaklaÅŸtır", + "miZoomReset": "YakınlaÅŸtırmayı Sı&&fırla", + "miBack": "&&Geri", + "miForward": "&&Ä°leri", + "miNextEditor": "&&Sonraki Düzenleyici", + "miPreviousEditor": "Ö&&nceki Düzenleyici", + "miNextEditorInGroup": "&&Grupta Sonraki Kullanılan Düzenleyici", + "miPreviousEditorInGroup": "G&&rupta Önceki Kullanılan Düzenleyici", + "miSwitchEditor": "&&Düzenleyici DeÄŸiÅŸtir", + "miFocusFirstGroup": "Ä°&&lk Grup", + "miFocusSecondGroup": "Ä°&&kinci Grup", + "miFocusThirdGroup": "Üçün&&cü Grup", + "miNextGroup": "Sonraki Gr&&up", + "miPreviousGroup": "Önceki Gru&&p", + "miSwitchGroup": "Grup &&DeÄŸiÅŸtir", + "miGotoFile": "D&&osyaya Git...", + "miGotoSymbolInFile": "Dosyada S&&embole Git...", + "miGotoSymbolInWorkspace": "Çalışma &&Alanında Sembole Git...", + "miGotoDefinition": "&&Tanıma Git", + "miGotoTypeDefinition": "Tü&&r Tanımına Git", + "miGotoImplementation": "U&&ygulamaya Git", + "miGotoLine": "&&Satıra Git...", + "miStartDebugging": "&&Hata Ayıklamaya BaÅŸla", + "miStartWithoutDebugging": "Hata Ayıklama &&Olmadan BaÅŸlat", + "miStopDebugging": "Hata Ayıklamayı D&&urdur", + "miRestart Debugging": "Hata Ayıklamayı &&Yeniden BaÅŸlat", + "miOpenConfigurations": "Ya&&pılandırmaları Aç", + "miAddConfiguration": "Yapı&&landırma Ekle...", + "miStepOver": "&&Adım At", + "miStepInto": "&&İçine Adımla", + "miStepOut": "&&Dışına Adımla", + "miContinue": "De&&vam Et", + "miToggleBreakpoint": "Kesme &&Noktası Ekle/Kaldır", + "miConditionalBreakpoint": "&&KoÅŸullu Kesme Noktası...", + "miColumnBreakpoint": "&&Sütun Kesme Noktası", + "miFunctionBreakpoint": "&&Fonksiyon Kesme Noktası", + "miNewBreakpoint": "&&Yeni Kesme Noktası", + "miEnableAllBreakpoints": "Tüm Kesme Noktalarını EtkinleÅŸtir", + "miDisableAllBreakpoints": "&&Tüm Kesme Noktalarını Devre Dışı Bırak", + "miRemoveAllBreakpoints": "Tüm Kesme Noktalarını Kaldı&&r", + "miInstallAdditionalDebuggers": "&&Ek Hata Ayıklayıcıları Yükle", + "mMinimize": "Simge Durumuna Küçült", + "mZoom": "YakınlaÅŸtırma", + "mBringToFront": "Tümünü Öne Getir", + "miSwitchWindow": "&&Pencere DeÄŸiÅŸtir...", + "miToggleDevTools": "&&GeliÅŸtirici Araçlarını Aç/Kapat", + "miAccessibilityOptions": "&&EriÅŸilebilirlik Seçenekleri", + "miReportIssues": "So&&run Bildir", + "miWelcome": "&&HoÅŸ Geldiniz", + "miInteractivePlayground": "&&Ä°nteraktif Oyun Alanı", + "miDocumentation": "&&Belgeler", + "miReleaseNotes": "&&Sürüm Notları", + "miKeyboardShortcuts": "&&Klavye Kısayolları BaÅŸvurusu", + "miIntroductoryVideos": "Tanıtım &&Videoları", + "miTwitter": "&&Twitter'da Bize Katıl", + "miUserVoice": "Ö&&zellik Ä°steklerini Ara", + "miLicense": "&&Lisansı Görüntüle", + "miPrivacyStatement": "Gizlilik &&Beyanı", + "miAbout": "H&&akkında", + "miRunTask": "Görevi Ç&&alıştır", + "miRestartTask": "Görevi &&Yeniden BaÅŸlat", + "miTerminateTask": "&&Görevi Sonlandır", + "miBuildTask": "&&Derleme Görevi", + "miTestTask": "&&Test Görevi", + "miShowTaskLog": "&&Görev Günlüğünü Göster", + "accessibilityOptionsWindowTitle": "EriÅŸilebilirlik Seçenekleri", + "miRestartToUpdate": "GüncelleÅŸtirmek için Yeniden BaÅŸlatın...", + "miCheckingForUpdates": "GüncelleÅŸtirmeler Denetleniyor...", + "miDownloadUpdate": "Mevcut GüncelleÅŸtirmeyi Ä°ndir", + "miDownloadingUpdate": "GüncelleÅŸtirme Ä°ndiriliyor...", + "miInstallingUpdate": "GüncelleÅŸtirme Yükleniyor...", + "miCheckForUpdates": "GüncelleÅŸtirmeleri Denetle...", + "aboutDetail": "\nSürüm {0}\nCommit {1}\nTarih {2}\nKabuk {3}\nOluÅŸturucu {4}\nNode {5}", + "okButton": "Tamam" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/code/electron-main/window.i18n.json b/i18n/trk/src/vs/code/electron-main/window.i18n.json new file mode 100644 index 00000000000..ca683aad480 --- /dev/null +++ b/i18n/trk/src/vs/code/electron-main/window.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "hiddenMenuBar": "Menü çubuÄŸuna **Alt** tuÅŸuna basarak hala eriÅŸebilirsiniz." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/code/electron-main/windows.i18n.json b/i18n/trk/src/vs/code/electron-main/windows.i18n.json new file mode 100644 index 00000000000..d700eddd2d5 --- /dev/null +++ b/i18n/trk/src/vs/code/electron-main/windows.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ok": "Tamam", + "pathNotExistTitle": "Yol yok", + "pathNotExistDetail": "'{0}' yolu artık diskte deÄŸil.", + "reopen": "Yeniden Aç", + "wait": "Beklemeye Devam Et", + "close": "Kapat", + "appStalled": "Pencere artık yanıt vermiyor", + "appStalledDetail": "Pencereyi yeniden açabilir, kapatabilir veya bekleyebilirsiniz.", + "appCrashed": "Pencere kilitlendi", + "appCrashedDetail": "VerdiÄŸimiz rahatsızlıktan dolayı özür dileriz! Pencereyi yeniden açıp kaldığınız yerden devam edebilirsiniz." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/code/node/cliProcessMain.i18n.json b/i18n/trk/src/vs/code/node/cliProcessMain.i18n.json new file mode 100644 index 00000000000..8ca0b4fc0b4 --- /dev/null +++ b/i18n/trk/src/vs/code/node/cliProcessMain.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "notFound": "'{0}' eklentisi bulunamadı.", + "notInstalled": "'{0}' eklentisi yüklü deÄŸil.", + "useId": "Eklentinin tam ID'sini, yayıncı da dahil olmak üzere kullandığınızdan emin olun, ör: {0}", + "successVsixInstall": "'{0}' eklentisi baÅŸarıyla yüklendi.", + "alreadyInstalled": "'{0}' eklentisi zaten yüklü.", + "foundExtension": "'{0}' markette bulundu.", + "installing": "Yükleniyor...", + "successInstall": "'{0}' v{1} eklentisi baÅŸarıyla kuruldu!", + "uninstalling": "{0} kaldırılıyor...", + "successUninstall": "'{0}' eklentisi baÅŸarıyla kaldırıldı!" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/common/config/commonEditorConfig.i18n.json b/i18n/trk/src/vs/editor/common/config/commonEditorConfig.i18n.json new file mode 100644 index 00000000000..6da1720d79c --- /dev/null +++ b/i18n/trk/src/vs/editor/common/config/commonEditorConfig.i18n.json @@ -0,0 +1,88 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorConfigurationTitle": "Düzenleyici", + "fontFamily": "Yazı tipi ailesini denetler.", + "fontWeight": "Yazı tipi kalınlığını denetler.", + "fontSize": "Yazı tipi boyutunu piksel olarak denetler.", + "lineHeight": "Satır yüksekliÄŸini denetler. lineHeight deÄŸerini, fontSize deÄŸeri kullanarak hesaplamak için 0 girin.", + "letterSpacing": "Harfler arası boÅŸluÄŸu pixel olarak denetler.", + "lineNumbers": "Satır numaralarının görüntülenmesini denetler. Olası deÄŸerler 'on', 'off' ve 'relative'dir. 'relative' satırların geçerli imleç konumundan uzaklıklarını gösterir.", + "rulers": "Dikey cetvellerin gösterileceÄŸi sütunlar", + "wordSeparators": "Sözcüklerle ilgili gezinti veya iÅŸlem yaparken kelime ayırıcı olarak kullanılacak karakterler", + "tabSize": "Bir sekmenin eÅŸit olduÄŸu boÅŸluk sayısı. Bu ayar, `editor.detectIndentation` açıkken dosya içeriÄŸine baÄŸlı olarak geçersiz kılınır.", + "tabSize.errorMessage": "'sayı' bekleniyor. \"auto\" deÄŸerinin `editor.detectIndentation` ile deÄŸiÅŸtirildiÄŸini unutmayın.", + "insertSpaces": "Tab tuÅŸuna basınca boÅŸluk ekle. Bu ayar, `editor.detectIndentation` açıkken dosya içeriÄŸine baÄŸlı olarak geçersiz kılınır.", + "insertSpaces.errorMessage": "'boole' bekleniyor. \"auto\" deÄŸerinin `editor.detectIndentation` ile deÄŸiÅŸtirildiÄŸini unutmayın.", + "detectIndentation": "Bir dosyayı açarken, `editor.tabSize` ve `editor.insertSpaces` dosya içeriÄŸine baÄŸlı olarak algılanır.", + "roundedSelection": "Seçimlerin köşelerinin yuvarlak olup olmayacağını denetler", + "scrollBeyondLastLine": "Düzenleyicinin son satırın ötesine ilerleyip ilerlemeyeceÄŸini denetler", + "minimap.enabled": "Mini haritanın gösterilip gösterilmeyeceÄŸini denetler", + "minimap.showSlider": "Mini harita kaydıracının otomatik olarak gizlenip gizlenmeyeceÄŸini denetler.", + "minimap.renderCharacters": "(Renk blokları yerine) Bir satırdaki gerçek harfleri göster", + "minimap.maxColumn": "Hazırlanacak mini haritanın azami geniÅŸliÄŸini belirli sayıda sütunla sınırla", + "find.seedSearchStringFromSelection": "Bulma Araç ÇubuÄŸu'ndaki arama metninin, düzenleyicideki seçili alandan beslenmesini denetler", + "find.autoFindInSelection": "Seçimde bul iÅŸaretçisinin, editördeki metnin birden çok karakteri veya satırı seçildiÄŸinde açılmasını denetler.", + "wordWrap.off": "Satırlar hiçbir zaman bir sonraki satıra kaydırılmayacak.", + "wordWrap.on": "Satırlar görüntü alanı geniÅŸliÄŸinde bir sonraki satıra kaydırılacak.", + "wordWrap.wordWrapColumn": "Satırlar `editor.wordWrapColumn` deÄŸerinde bir sonraki satıra kaydırılacak.", + "wordWrap.bounded": "Satırlar en düşük görüntü alanı geniÅŸliÄŸinde ve `editor.wordWrapColumn` deÄŸerinde bir sonraki satıra kaydırılacak.", + "wordWrap": "Satırların bir sonraki satıra nasıl kaydırılacağını denetler. Seçenekler:\n - 'off' (kaydırmayı devre dışı bırak),\n - 'on' (görüntü alanında kaydır),\n - 'wordWrapColumn' (`editor.wordWrapColumn` deÄŸerinde kaydır) veya\n - 'bounded' (en düşük görüntü alanı geniÅŸliÄŸinde ve `editor.wordWrapColumn` deÄŸerinde kaydır).", + "wordWrapColumn": "`editor.wordWrap` ögesi, 'wordWrapColumn' veya 'bounded' iken düzenleyicinin kaydırma sütununu denetler.", + "wrappingIndent": "Kaydırılan satır girintisini denetler. 'none', 'same' veya 'indent' deÄŸerlerinden biri olabilir.", + "mouseWheelScrollSensitivity": "Fare tekerleÄŸi kaydırma olaylarında `deltaX` ve `deltaY` üzerinde kullanılan bir çarpan", + "multiCursorModifier.ctrlCmd": "Windows ve Linux'da `Control` ve OSX'de `Command` ile eÅŸleÅŸir.", + "multiCursorModifier.alt": "Windows ve Linux'da `Alt` ve OSX'de `Option` ile eÅŸleÅŸir.", + "multiCursorModifier": "Fare ile birden çok imleç eklenmesinde kullanılacak deÄŸiÅŸtirici. `ctrlCmd` Windows ve Linux'da `Control` ve OSX'de `Command` ile eÅŸleÅŸir. Tanıma Git ve BaÄŸlantıyı Aç fare hareketleri, birden çok imleç deÄŸiÅŸtiricisi ile çakışmayacak ÅŸekilde uyum saÄŸlarlar.", + "quickSuggestions.strings": "Dizelerin içinde hızlı önerileri etkinleÅŸtir.", + "quickSuggestions.comments": "Yorumların içinde hızlı önerileri etkinleÅŸtir.", + "quickSuggestions.other": "Dizeler ve yorumlar dışında hızlı önerileri etkinleÅŸtirin.", + "quickSuggestions": "Yazarken önerilerin otomatik olarak gösterilip gösterilmeyeceÄŸini denetler", + "quickSuggestionsDelay": "Hızlı önerilerin gösterilmesinden önce kaç ms bekleneceÄŸini denetler", + "parameterHints": "Siz tuÅŸlara bastıkça parametre belgelerini ve tür bilgisini gösteren açılır pencereyi etkinleÅŸtirir.", + "autoClosingBrackets": "Düzenleyicinin köşeli ayracı açtıktan sonra otomatik olarak kapatıp kapatmayacağını denetler", + "formatOnType": "Düzenleyicinin satırı yazıldıktan sonra otomatik biçimlendirip biçimlendirmeyeceÄŸini denetler", + "formatOnPaste": "Düzenleyicinin yapıştırılan içeriÄŸi otomatik olarak biçimlendirip biçimlendirmeyeceÄŸini denetler. Bir biçimlendirici mevcut olmalı ve belgede bir aralığı biçimlendirebilmelidir.", + "suggestOnTriggerCharacters": "Tetikleyici karakterler yazılırken otomatik olarak öneri gösterilip gösterilmeyeceÄŸini denetler", + "acceptSuggestionOnEnter": "'Tab' tuÅŸuna ek olarak - önerilerin 'Enter' tuÅŸuna basıldığında kabul edilmesini denetler. Yeni satır ekleme ya da öneri kabul etme arasındaki belirsizlikten kaçınmaya yardımcı olur. 'smart' deÄŸeri, bir öneri metinsel deÄŸiÅŸiklik yapıyorsa, onu sadece Enter tuÅŸu ile kabul etmeyi ifade eder", + "acceptSuggestionOnCommitCharacter": "Önerilerin tamamlama karakterlerinde kabul edilip edilmeyeceÄŸini denetler. Örnek olarak; JavaScript'te noktalı virgül(';') öneri kabul eden ve o karakteri giren tamamlama karakteri olabilir.", + "snippetSuggestions": "Parçacıkların diÄŸer önerilerle gösterilip gösterilmeyeceÄŸini ve bunların nasıl sıralanacaklarını denetler.", + "emptySelectionClipboard": "Bir seçim olmadan geçerli satırı kopyalayıp kopyalamamayı denetler.", + "wordBasedSuggestions": "Tamamlamaların belgedeki sözcüklere dayalı olarak hesaplanıp hesaplanmayacağını denetler.", + "suggestFontSize": "Öneri aracının yazı tipi boyutu", + "suggestLineHeight": "Öneri aracının satır yüksekliÄŸi", + "selectionHighlight": "Düzenleyicinin seçime benzer eÅŸleÅŸmeleri vurgulayıp vurgulamayacağını denetler", + "occurrencesHighlight": "Düzenleyicinin semantik sembol tekrarlamalarını vurgulayıp vurgulamayacağını denetler", + "overviewRulerLanes": "Genel bakış cetvelinde aynı konumda gösterilebilecek süsleme sayısını denetler", + "overviewRulerBorder": "Genel bakış cetvelinin etrafına bir kenarlık çizilmesi gerekip gerekmediÄŸini denetler.", + "cursorBlinking": "Ä°mleç animasyon stilini denetler, olası deÄŸerler 'blink', 'smooth', 'phase', 'expand' ve 'solid'dir", + "mouseWheelZoom": "Ctrl tuÅŸuna basarken fare tekerleÄŸi ile düzenleyici yazı tipini yakınlaÅŸtırın", + "cursorStyle": "Ä°mleç stilini denetler, kabul edilen deÄŸerler: 'block', 'block-outline', 'line', 'line-thin', 'underline' ve 'underline-thin'", + "fontLigatures": "Yazı tipi ligatürlerini etkinleÅŸtirir", + "hideCursorInOverviewRuler": "Ä°mlecin genel bakış cetvelinde gizlenip gizlenmeyeceÄŸini denetler.", + "renderWhitespace": "Düzenleyicinin boÅŸluk karakterlerini nasıl göstereceÄŸini denetler, seçenekler: 'none', 'boundary', ve 'all'. 'boundary' seçeneÄŸi sözcükler arasındaki tek boÅŸlukları göstermez.", + "renderControlCharacters": "Düzenleyicinin kontrol karakterlerini gösterip göstermemesini denetler", + "renderIndentGuides": "Düzenleyicinin girinti kılavuzlarını gösterip göstermemesini denetler", + "renderLineHighlight": "Düzenleyicinin geçerli satır vurgusunu nasıl göstereceÄŸini denetler, seçenekler: 'none', 'gutter', 'line', ve 'all'.", + "codeLens": "Düzenleyicinin kod objektiflerini gösterip göstermediÄŸini denetler", + "folding": "Düzenleyicide kod katlamanın etkin olup olmadığını denetler", + "showFoldingControls": "Oluktaki kat kontrollerinin otomatik olarak gizlenip gizlenmeyeceÄŸini denetler.", + "matchBrackets": "EÅŸleÅŸen ayraçları, onlardan biri seçildiÄŸinde vurgula.", + "glyphMargin": "Düzenleyicinin dikey glif boÅŸluÄŸunu oluÅŸturup oluÅŸturmayacağını kontrol eder. Glif boÅŸluÄŸu çoÄŸunlukla hata ayıklamak için kullanılır.", + "useTabStops": "BoÅŸluk ekleme ve silme sekme duraklarını izler", + "trimAutoWhitespace": "Sondaki otomatik eklenen boÅŸluÄŸu kaldır", + "stablePeek": "Gözetleme düzenleyicilerini, içeriklerine çift tıklandığında veya Escape tuÅŸuna basıldığında bile açık tut.", + "dragAndDrop": "Düzenleyicinin seçimleri sürükleyip bırakarak taşımaya izin verip vermeyeceÄŸini denetler.", + "accessibilitySupport.auto": "Düzenleyici, bir Ekran Okuyucu'nun ne zaman baÄŸlandığını algılamak için platform API'larını kullanacaktır.", + "accessibilitySupport.on": "Düzenleyici bir Ekran Okuyucu ile kullanılmak üzere kalıcı olarak optimize edilecektir.", + "accessibilitySupport.off": "Düzenleyici hiçbir zaman bir Ekran Okuyucu ile kullanılmak üzere optimize edilmeyecektir.", + "accessibilitySupport": "Düzenleyicinin ekran okuyucular için optimize edilmiÅŸ bir modda çalışıp çalışmayacağını denetler.", + "links": "Düzenleyicinin baÄŸlantıları otomatik algılayıp, onları tıklanabilir yapıp yapmayacağını denetler", + "sideBySide": "KarşılaÅŸtırma düzenleyicisinin farklılıkları yan yana mı yoksa satır içinde mi göstereceÄŸini denetler", + "ignoreTrimWhitespace": "KarşılaÅŸtırma düzenleyicisinin baÅŸtaki veya sondaki boÅŸluklardaki deÄŸiÅŸmeleri farklılık olarak gösterip göstermemesini denetler", + "renderIndicators": "KarşılaÅŸtırma düzenleyicisinin ekleme/çıkarma deÄŸiÅŸiklikleri için +/- göstergeleri gösterip göstermemesini denetler.", + "selectionClipboard": "Linux birincil panosunun desteklenip desteklenmeyeceÄŸini denetler." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/common/config/editorOptions.i18n.json b/i18n/trk/src/vs/editor/common/config/editorOptions.i18n.json new file mode 100644 index 00000000000..e9722574046 --- /dev/null +++ b/i18n/trk/src/vs/editor/common/config/editorOptions.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "accessibilityOffAriaLabel": "Düzenleyici ÅŸu an eriÅŸilebilir deÄŸil. Seçenekler için lütfen Alt+F1'e basın.", + "editorViewAccessibleLabel": "Düzenleyici içeriÄŸi" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/common/controller/cursor.i18n.json b/i18n/trk/src/vs/editor/common/controller/cursor.i18n.json new file mode 100644 index 00000000000..5ac37adbc12 --- /dev/null +++ b/i18n/trk/src/vs/editor/common/controller/cursor.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "corrupt.commands": "Komut yürütülürken beklenmeyen özel durum oluÅŸtu." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/common/model/textModelWithTokens.i18n.json b/i18n/trk/src/vs/editor/common/model/textModelWithTokens.i18n.json new file mode 100644 index 00000000000..4884bc2418f --- /dev/null +++ b/i18n/trk/src/vs/editor/common/model/textModelWithTokens.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "mode.tokenizationSupportFailed": "Mod, girdiyi belirteçlere ayırırken baÅŸarısız oldu." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/common/modes/modesRegistry.i18n.json b/i18n/trk/src/vs/editor/common/modes/modesRegistry.i18n.json new file mode 100644 index 00000000000..e559b828743 --- /dev/null +++ b/i18n/trk/src/vs/editor/common/modes/modesRegistry.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "plainText.alias": "Düz Metin" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/common/services/bulkEdit.i18n.json b/i18n/trk/src/vs/editor/common/services/bulkEdit.i18n.json new file mode 100644 index 00000000000..b081029e080 --- /dev/null +++ b/i18n/trk/src/vs/editor/common/services/bulkEdit.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "conflict": "Bu dosyalar bu arada değiştirildi: {0}", + "summary.0": "Düzenleme yapılmadı", + "summary.nm": "{1} dosyada {0} metin düzenlemesi yapıldı", + "summary.n0": "Bir dosyada {0} metin düzenlemesi yapıldı" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/common/services/modeServiceImpl.i18n.json b/i18n/trk/src/vs/editor/common/services/modeServiceImpl.i18n.json new file mode 100644 index 00000000000..55d69fef903 --- /dev/null +++ b/i18n/trk/src/vs/editor/common/services/modeServiceImpl.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.languages": "Dil bildirimlerine ekleme yapar.", + "vscode.extension.contributes.languages.id": "Dilin ID'si.", + "vscode.extension.contributes.languages.aliases": "Dilin takma adları.", + "vscode.extension.contributes.languages.extensions": "Dil ile ilişkili dosya uzantıları.", + "vscode.extension.contributes.languages.filenames": "Dil ile ilişkili dosya adları.", + "vscode.extension.contributes.languages.filenamePatterns": "Dil ile ilişkili dosya adı glob desenleri.", + "vscode.extension.contributes.languages.mimetypes": "Dil ile ilişkili MIME türleri.", + "vscode.extension.contributes.languages.firstLine": "Dilin bir dosyasının ilk satırıyla eşleşen bir düzenli ifade.", + "vscode.extension.contributes.languages.configuration": "Dil için yapılandırma seçenekleri içeren dosyaya, bir göreli yol." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/common/services/modelServiceImpl.i18n.json b/i18n/trk/src/vs/editor/common/services/modelServiceImpl.i18n.json new file mode 100644 index 00000000000..a12e01358bb --- /dev/null +++ b/i18n/trk/src/vs/editor/common/services/modelServiceImpl.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "diagAndSourceMultiline": "[{0}]\n{1}", + "diagAndSource": "[{0}] {1}" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/common/view/editorColorRegistry.i18n.json b/i18n/trk/src/vs/editor/common/view/editorColorRegistry.i18n.json new file mode 100644 index 00000000000..e5f9dca329b --- /dev/null +++ b/i18n/trk/src/vs/editor/common/view/editorColorRegistry.i18n.json @@ -0,0 +1,24 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "lineHighlight": "İmlecin bulunduğu satırın vurgusunun arka plan rengi.", + "lineHighlightBorderBox": "İmlecin bulunduğu satırın kenarlığının arka plan rengi.", + "rangeHighlight": "Hızlı açma ve bulma özellikleri gibi vurgulanan alanların arka plan rengi.", + "caret": "Düzenleyici imlecinin rengi.", + "editorWhitespaces": "Düzenleyicideki boşluk karakterlerinin rengi.", + "editorIndentGuides": "Düzenleyici girinti kılavuzlarının rengi.", + "editorLineNumbers": "Düzenleyici satır numaralarının rengi.", + "editorRuler": "Düzenleyici cetvellerinin rengi.", + "editorCodeLensForeground": "Düzenleyici kod objektiflerinin ön plan rengi", + "editorBracketMatchBackground": "Eşleşen parantezlerin arka plan rengi", + "editorBracketMatchBorder": "Eşleşen parantez kutularının rengi", + "editorOverviewRulerBorder": "Genel bakış cetvelinin kenarlık rengi.", + "editorGutter": "Düzenleyici oluğunun arka plan rengi. Oluk, glif boşluklarını ve satır numaralarını içerir.", + "errorForeground": "Düzenleyicideki hata karalamalarının ön plan rengi.", + "errorBorder": "Düzenleyicideki hata karalamalarının kenarlık rengi.", + "warningForeground": "Düzenleyicideki uyarı karalamalarının ön plan rengi.", + "warningBorder": "Düzenleyicideki uyarı karalamalarının kenarlık rengi." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/bracketMatching/common/bracketMatching.i18n.json b/i18n/trk/src/vs/editor/contrib/bracketMatching/common/bracketMatching.i18n.json new file mode 100644 index 00000000000..3156c395100 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/bracketMatching/common/bracketMatching.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "smartSelect.jumpBracket": "Köşeli Ayraca Git" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/caretOperations/common/caretOperations.i18n.json b/i18n/trk/src/vs/editor/contrib/caretOperations/common/caretOperations.i18n.json new file mode 100644 index 00000000000..c5196837029 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/caretOperations/common/caretOperations.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "caret.moveLeft": "İmleci Sola Taşı", + "caret.moveRight": "İmleci Sağa Taşı" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/caretOperations/common/transpose.i18n.json b/i18n/trk/src/vs/editor/contrib/caretOperations/common/transpose.i18n.json new file mode 100644 index 00000000000..5ee978f2342 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/caretOperations/common/transpose.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "transposeLetters.label": "Harfleri Birbirleriyle Değiştir" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/clipboard/browser/clipboard.i18n.json b/i18n/trk/src/vs/editor/contrib/clipboard/browser/clipboard.i18n.json new file mode 100644 index 00000000000..768e8e3511f --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/clipboard/browser/clipboard.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "actions.clipboard.cutLabel": "Kes", + "actions.clipboard.copyLabel": "Kopyala", + "actions.clipboard.pasteLabel": "Yapıştır", + "actions.clipboard.copyWithSyntaxHighlightingLabel": "Sentaks Vurgulaması İle Kopyala" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/comment/common/comment.i18n.json b/i18n/trk/src/vs/editor/contrib/comment/common/comment.i18n.json new file mode 100644 index 00000000000..30ac850837c --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/comment/common/comment.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "comment.line": "Satır Yorumunu Aç/Kapat", + "comment.line.add": "Satır Açıklaması Ekle", + "comment.line.remove": "Satır Açıklamasını Kaldır", + "comment.block": "Yorum Bloğunu Aç/Kapat" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/contextmenu/browser/contextmenu.i18n.json b/i18n/trk/src/vs/editor/contrib/contextmenu/browser/contextmenu.i18n.json new file mode 100644 index 00000000000..fbed2327052 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/contextmenu/browser/contextmenu.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "action.showContextMenu.label": "Düzenleyici Bağlam Menüsünü Göster" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/find/browser/findWidget.i18n.json b/i18n/trk/src/vs/editor/contrib/find/browser/findWidget.i18n.json new file mode 100644 index 00000000000..e483c295f19 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/find/browser/findWidget.i18n.json @@ -0,0 +1,21 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "label.find": "Bul", + "placeholder.find": "Bul", + "label.previousMatchButton": "Önceki eşleşme", + "label.nextMatchButton": "Sonraki eşleşme", + "label.toggleSelectionFind": "Seçimde bul", + "label.closeButton": "Kapat", + "label.replace": "Değiştir", + "placeholder.replace": "Değiştir", + "label.replaceButton": "Değiştir", + "label.replaceAllButton": "Tümünü Değiştir", + "label.toggleReplaceButton": "Değiştirme modunu değiştir", + "title.matchesCountLimit": "Yalnızca ilk 999 sonuç vurgulandı, ancak tüm bulma işlemleri metnin tamamı üzerinde çalışıyor.", + "label.matchesLocation": "{0}/{1}", + "label.noResults": "Sonuç Yok" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/find/common/findController.i18n.json b/i18n/trk/src/vs/editor/contrib/find/common/findController.i18n.json new file mode 100644 index 00000000000..e9808291987 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/find/common/findController.i18n.json @@ -0,0 +1,18 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "startFindAction": "Bul", + "findNextMatchAction": "Sonrakini Bul", + "findPreviousMatchAction": "Öncekini Bul", + "nextSelectionMatchFindAction": "Sonraki Seçimi Bul", + "previousSelectionMatchFindAction": "Önceki Seçimi Bul", + "startReplace": "Değiştir", + "addSelectionToNextFindMatch": "Seçimi Sonraki Bulunan Eşleşmeye Ekle", + "addSelectionToPreviousFindMatch": "Seçimi Önceki Bulunan Eşleşmeye Ekle", + "moveSelectionToNextFindMatch": "Son Seçimi Sonraki Bulunan Eşleşmeye Taşı", + "moveSelectionToPreviousFindMatch": "Son Seçimi Önceki Bulunan Eşleşmeye Taşı", + "changeAll.label": "Tüm Tekrarlamaları Değiştir" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/folding/browser/folding.i18n.json b/i18n/trk/src/vs/editor/contrib/folding/browser/folding.i18n.json new file mode 100644 index 00000000000..084b78eafff --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/folding/browser/folding.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "unfoldAction.label": "Katlamayı Aç", + "unFoldRecursivelyAction.label": "Katlamaları Özyinelemeli Olarak Aç", + "foldAction.label": "Katla", + "foldRecursivelyAction.label": "Özyinelemeli Olarak Katla", + "foldAllAction.label": "Hepsini Katla", + "unfoldAllAction.label": "Tüm Katlamaları Aç", + "foldLevelAction.label": "{0}. Düzeyi Katla" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/format/browser/formatActions.i18n.json b/i18n/trk/src/vs/editor/contrib/format/browser/formatActions.i18n.json new file mode 100644 index 00000000000..265248d706c --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/format/browser/formatActions.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "hint11": "{0}. satırda 1 biçimlendirme düzenlemesi yapıldı", + "hintn1": "{1}. satırda {0} biçimlendirme düzenlemesi yapıldı", + "hint1n": "{0} ve {1} satırları arasında 1 biçimlendirme düzenlemesi yapıldı", + "hintnn": "{1} ve {2} satırları arasında {0} biçimlendirme düzenlemesi yapıldı", + "formatDocument.label": "Belgeyi Biçimlendir", + "formatSelection.label": "Seçimi Biçimlendir" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json b/i18n/trk/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json new file mode 100644 index 00000000000..fae99c4c772 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationCommands.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultWord": "'{0}' için tanım bulunamadı", + "generic.noResults": "Tanım bulunamadı", + "meta.title": " – {0} tanım", + "actions.goToDecl.label": "Tanıma Git", + "actions.goToDeclToSide.label": "Tanımı Yana Aç", + "actions.previewDecl.label": "Tanıma Göz At", + "goToImplementation.noResultWord": "'{0}' için uygulama bulunamadı", + "goToImplementation.generic.noResults": "Uygulama bulunamadı", + "meta.implementations.title": " – {0} uygulama", + "actions.goToImplementation.label": "Uygulamaya Git", + "actions.peekImplementation.label": "Uygulamaya Göz At", + "goToTypeDefinition.noResultWord": "'{0}' için tür tanımı bulunamadı", + "goToTypeDefinition.generic.noResults": "Tür tanımı bulunamadı", + "meta.typeDefinitions.title": " – {0} tür tanımı", + "actions.goToTypeDefinition.label": "Tür Tanımına Git", + "actions.peekTypeDefinition.label": "Tür Tanımına Göz At" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json b/i18n/trk/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json new file mode 100644 index 00000000000..010de11a57d --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/goToDeclaration/browser/goToDeclarationMouse.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "multipleResults": "{0} tanımı göstermek için tıklayın." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json b/i18n/trk/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json new file mode 100644 index 00000000000..715f05193c2 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/gotoError/browser/gotoError.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "title.wo_source": "({0}/{1})", + "markerAction.next.label": "Sonraki Hata veya Uyarıya Git", + "markerAction.previous.label": "Önceki Hata veya Uyarıya Git", + "editorMarkerNavigationError": "Düzenleyicinin işaretçi gezinti aracının hata rengi.", + "editorMarkerNavigationWarning": "Düzenleyicinin işaretçi gezinti aracının uyarı rengi.", + "editorMarkerNavigationBackground": "Düzenleyicinin işaretçi gezinti aracının arka planı." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/hover/browser/hover.i18n.json b/i18n/trk/src/vs/editor/contrib/hover/browser/hover.i18n.json new file mode 100644 index 00000000000..e1a33122702 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/hover/browser/hover.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "showHover": "Bağlantı Vurgusunu Göster" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/hover/browser/modesContentHover.i18n.json b/i18n/trk/src/vs/editor/contrib/hover/browser/modesContentHover.i18n.json new file mode 100644 index 00000000000..1b70c63296f --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/hover/browser/modesContentHover.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "modesContentHover.loading": "Yükleniyor..." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.i18n.json b/i18n/trk/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.i18n.json new file mode 100644 index 00000000000..bb4caacacb1 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/inPlaceReplace/common/inPlaceReplace.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "InPlaceReplaceAction.previous.label": "Önceki Değerle Değiştir", + "InPlaceReplaceAction.next.label": "Sonraki Değerle Değiştir" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/indentation/common/indentation.i18n.json b/i18n/trk/src/vs/editor/contrib/indentation/common/indentation.i18n.json new file mode 100644 index 00000000000..76b8b3c8391 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/indentation/common/indentation.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "indentationToSpaces": "Girintiyi Boşluklara Dönüştür", + "indentationToTabs": "Girintiyi Sekmelere Dönüştür", + "configuredTabSize": "Yapılandırılmış Sekme Boyutu", + "selectTabWidth": "Geçerli Dosya İçin Sekme Boyutunu Seç", + "indentUsingTabs": "Sekme Kullanarak Girintile", + "indentUsingSpaces": "Boşluk Kullanarak Girintile", + "detectIndentation": "Girintiyi, İçeriği Kontrol Ederek Algıla", + "editor.reindentlines": "Satır Girintilerini Yeniden Ayarla" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/linesOperations/common/linesOperations.i18n.json b/i18n/trk/src/vs/editor/contrib/linesOperations/common/linesOperations.i18n.json new file mode 100644 index 00000000000..4ae7163c50c --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/linesOperations/common/linesOperations.i18n.json @@ -0,0 +1,25 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "lines.copyUp": "Satırı Yukarı Kopyala", + "lines.copyDown": "Satırı Aşağı Kopyala", + "lines.moveUp": "Satırı Yukarı Taşı", + "lines.moveDown": "Satırı Aşağı Taşı", + "lines.sortAscending": "Satırları Artan Şekilde Sırala", + "lines.sortDescending": "Satırları Azalan Şekilde Sırala", + "lines.trimTrailingWhitespace": "Sondaki Boşluğu Kırp", + "lines.delete": "Satırı Sil", + "lines.indent": "Satırı Girintile", + "lines.outdent": "Satırın Girintisini Azalt", + "lines.insertBefore": "Üste Satır Ekle", + "lines.insertAfter": "Alta Satır Ekle", + "lines.deleteAllLeft": "Soldaki Her Şeyi Sil", + "lines.deleteAllRight": "Sağdaki Her Şeyi Sil", + "lines.joinLines": "Satırları Birleştir", + "editor.transpose": "İmlecin etrafındaki karakterleri birbirleriyle değiştir", + "editor.transformToUppercase": "Büyük Harfe Dönüştür", + "editor.transformToLowercase": "Küçük Harfe Dönüştür" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/links/browser/links.i18n.json b/i18n/trk/src/vs/editor/contrib/links/browser/links.i18n.json new file mode 100644 index 00000000000..0d6ac3279c2 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/links/browser/links.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "links.navigate.mac": "Bağlantıyı izlemek için Cmd tuşuna basarak tıklayın", + "links.navigate": "Bağlantıyı izlemek için Ctrl tuşuna basarak tıklayın", + "links.navigate.al": "Bağlantıyı izlemek için Alt tuşuna basarak tıklayın", + "invalid.url": "Üzgünüz, bu bağlantı iyi oluşturulmamış olduğu için açılamadı: {0}", + "missing.url": "Üzgünüz; bu bağlantı, hedefi eksik olduğu için açılamadı.", + "label": "Bağlantıyı Aç" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/multicursor/common/multicursor.i18n.json b/i18n/trk/src/vs/editor/contrib/multicursor/common/multicursor.i18n.json new file mode 100644 index 00000000000..f3fa18b4184 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/multicursor/common/multicursor.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "mutlicursor.insertAbove": "Yukarıya İmleç Ekle", + "mutlicursor.insertBelow": "Aşağıya İmleç Ekle", + "mutlicursor.insertAtEndOfEachLineSelected": "Satır Sonlarına İmleç Ekle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/parameterHints/browser/parameterHints.i18n.json b/i18n/trk/src/vs/editor/contrib/parameterHints/browser/parameterHints.i18n.json new file mode 100644 index 00000000000..b7a4e43b2b6 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/parameterHints/browser/parameterHints.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "parameterHints.trigger.label": "Parametre İpuçlarını Tetikle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.i18n.json b/i18n/trk/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.i18n.json new file mode 100644 index 00000000000..ed56fe64626 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/parameterHints/browser/parameterHintsWidget.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "hint": "{0}, ipucu" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/quickFix/browser/quickFixCommands.i18n.json b/i18n/trk/src/vs/editor/contrib/quickFix/browser/quickFixCommands.i18n.json new file mode 100644 index 00000000000..86586e96e0a --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/quickFix/browser/quickFixCommands.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickFixWithKb": "Düzeltmeleri Göster ({0})", + "quickFix": "Düzeltmeleri Göster", + "quickfix.trigger.label": "Hızlı Düzeltme" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.i18n.json b/i18n/trk/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.i18n.json new file mode 100644 index 00000000000..9ddf0e9fbe0 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/referenceSearch/browser/referenceSearch.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "meta.titleReference": "– {0} başvuru", + "references.action.label": "Tüm Başvuruları Bul" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/referenceSearch/browser/referencesController.i18n.json b/i18n/trk/src/vs/editor/contrib/referenceSearch/browser/referencesController.i18n.json new file mode 100644 index 00000000000..14c77e0d644 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/referenceSearch/browser/referencesController.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "labelLoading": "Yükleniyor..." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json b/i18n/trk/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json new file mode 100644 index 00000000000..a3b4193dbe7 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/referenceSearch/browser/referencesModel.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "aria.oneReference": "{0} yolunda, {1}. satır {2}. sütundaki sembol", + "aria.fileReferences.1": "{0} içinde 1 sembol, tam yol {1}", + "aria.fileReferences.N": "{1} içinde {0} sembol, tam yol {2}", + "aria.result.0": "Sonuç bulunamadı", + "aria.result.1": "{0} yolunda 1 sembol bulundu", + "aria.result.n1": "{1} yolunda {0} sembol bulundu", + "aria.result.nm": "{1} dosyada {0} sembol bulundu" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json b/i18n/trk/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json new file mode 100644 index 00000000000..6165a40b9f9 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/referenceSearch/browser/referencesWidget.i18n.json @@ -0,0 +1,27 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "referencesFailre": "Dosya çözümlenemedi.", + "referencesCount": "{0} başvuru", + "referenceCount": "{0} başvuru", + "missingPreviewMessage": "önizleme yok", + "treeAriaLabel": "Başvurular", + "noResults": "Sonuç yok", + "peekView.alternateTitle": "Başvurular", + "peekViewTitleBackground": "Gözetleme görünümü başlık alanının arka plan rengi.", + "peekViewTitleForeground": "Gözetleme görünümü başlığının rengi.", + "peekViewTitleInfoForeground": "Gözetleme görünümü başlık bilgisinin rengi.", + "peekViewBorder": "Gözetleme görünümü kenarlıkları ve ok işaretinin rengi.", + "peekViewResultsBackground": "Gözetleme görünümü sonuç listesinin arka plan rengi.", + "peekViewResultsMatchForeground": "Gözetleme görünümü sonuç listesindeki satır düğümlerinin ön plan rengi.", + "peekViewResultsFileForeground": "Gözetleme görünümü sonuç listesindeki dosya düğümlerinin ön plan rengi.", + "peekViewResultsSelectionBackground": "Gözetleme görünümü sonuç listesindeki seçilen girdinin arka plan rengi.", + "peekViewResultsSelectionForeground": "Gözetleme görünümü sonuç listesindeki seçilen girdinin ön plan rengi.", + "peekViewEditorBackground": "Gözetleme görünümü düzenleyicisinin arka plan rengi.", + "peekViewEditorGutterBackground": "Gözetleme görünümü düzenleyicisindeki oluğun arka plan rengi.", + "peekViewResultsMatchHighlight": "Gözetleme görünümü sonuç listesindeki eşleşme vurgusu rengi.", + "peekViewEditorMatchHighlight": "Gözetleme görünümü düzenleyicisindeki eşleşme vurgusu rengi." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/rename/browser/rename.i18n.json b/i18n/trk/src/vs/editor/contrib/rename/browser/rename.i18n.json new file mode 100644 index 00000000000..4440b96d71b --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/rename/browser/rename.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "no result": "Sonuç yok.", + "aria": "'{0}', '{1}' olarak başarıyla yeniden adlandırıldı. Özet: {2}", + "rename.failed": "Üzgünüz, yeniden adlandırma işlemi başarısız oldu.", + "rename.label": "Sembolü Yeniden Adlandır" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/rename/browser/renameInputField.i18n.json b/i18n/trk/src/vs/editor/contrib/rename/browser/renameInputField.i18n.json new file mode 100644 index 00000000000..eea4501c3d8 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/rename/browser/renameInputField.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "renameAriaLabel": "Girdiyi yeniden adlandır. Yeni adı girin ve işlemek için Enter'a basın." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/smartSelect/common/smartSelect.i18n.json b/i18n/trk/src/vs/editor/contrib/smartSelect/common/smartSelect.i18n.json new file mode 100644 index 00000000000..b63d95ca271 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/smartSelect/common/smartSelect.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "smartSelect.grow": "Seçimi Genişlet", + "smartSelect.shrink": "Seçimi Daralt" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/suggest/browser/suggestController.i18n.json b/i18n/trk/src/vs/editor/contrib/suggest/browser/suggestController.i18n.json new file mode 100644 index 00000000000..d6c0cfacacb --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/suggest/browser/suggestController.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "arai.alert.snippet": "'{0}' kabul edildiği için şu metin eklendi: {1}", + "suggest.trigger.label": "Öneriyi Tetikle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json b/i18n/trk/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json new file mode 100644 index 00000000000..657260a0049 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/suggest/browser/suggestWidget.i18n.json @@ -0,0 +1,21 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorSuggestWidgetBackground": "Öneri aracının arka plan rengi.", + "editorSuggestWidgetBorder": "Öneri aracının kenarlık rengi.", + "editorSuggestWidgetForeground": "Öneri aracının ön plan rengi.", + "editorSuggestWidgetSelectedBackground": "Öneri aracındaki seçilen girdinin arka plan rengi.", + "editorSuggestWidgetHighlightForeground": "Öneri aracındaki eşleşme vurgularının rengi.", + "readMore": "Devamını Oku...{0}", + "suggestionWithDetailsAriaLabel": "{0}, öneri, detaylı", + "suggestionAriaLabel": "{0}, öneri", + "readLess": "Daha azını oku...{0}", + "suggestWidget.loading": "Yükleniyor...", + "suggestWidget.noSuggestions": "Öneri yok.", + "suggestionAriaAccepted": "{0}, kabul edildi", + "ariaCurrentSuggestionWithDetails": "{0}, öneri, detaylı", + "ariaCurrentSuggestion": "{0}, öneri" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode.i18n.json b/i18n/trk/src/vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode.i18n.json new file mode 100644 index 00000000000..720f500431f --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/toggleTabFocusMode/common/toggleTabFocusMode.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggle.tabMovesFocus": "Tab Tuşu İle Odak Değiştirmeyi Aç/Kapat" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.i18n.json b/i18n/trk/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.i18n.json new file mode 100644 index 00000000000..25e86b185b8 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/wordHighlighter/common/wordHighlighter.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "wordHighlight": "Bir değişkeni okumak gibi, okuma-erişimi sırasındaki bir sembolün arka plan rengi.", + "wordHighlightStrong": "Bir değişkene yazmak gibi, yazma-erişimi sırasındaki bir sembolün arka plan rengi." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.i18n.json b/i18n/trk/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.i18n.json new file mode 100644 index 00000000000..8a312782515 --- /dev/null +++ b/i18n/trk/src/vs/editor/contrib/zoneWidget/browser/peekViewWidget.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "label.close": "Kapat" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/electron-browser/textMate/TMSyntax.i18n.json b/i18n/trk/src/vs/editor/electron-browser/textMate/TMSyntax.i18n.json new file mode 100644 index 00000000000..cd8f883eda7 --- /dev/null +++ b/i18n/trk/src/vs/editor/electron-browser/textMate/TMSyntax.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "invalid.language": "`contributes.{0}.language` ögesinde bilinmeyen dil. Sağlanan değer: {1}", + "invalid.scopeName": "`contributes.{0}.scopeName` ögesinde dize bekleniyor. Sağlanan değer: {1}", + "invalid.path.0": "`contributes.{0}.path` ögesinde dize bekleniyor. Sağlanan değer: {1}", + "invalid.injectTo": "`contributes.{0}.injectTo` ögesinde geçersiz değer. Dil kapsam adlarından oluşan bir dizi olmalıdır. Sağlanan değer: {1}", + "invalid.embeddedLanguages": "`contributes.{0}.embeddedLanguages` ögesinde geçersiz değer. Kapsam adından dile kadar olan bir nesne haritası olmalıdır. Sağlanan değer: {1}", + "invalid.path.1": "`contributes.{0}.path` ögesinin ({1}) eklentinin klasöründe ({2}) yer alması bekleniyor. Bu, eklentiyi taşınamaz yapabilir.", + "no-tm-grammar": "Bu dil için kayıtlı bir TM Grameri yok." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json b/i18n/trk/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json new file mode 100644 index 00000000000..270182c4a47 --- /dev/null +++ b/i18n/trk/src/vs/editor/node/languageConfigurationExtensionPoint.i18n.json @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "parseErrors": "{0} için ayrıştırma hataları: {1}", + "schema.openBracket": "Açılış ayracı karakteri veya dize sırası.", + "schema.closeBracket": "Kapanış ayracı karakteri veya dize sırası.", + "schema.comments": "Yorum sembollerini tanımlar.", + "schema.blockComments": "Blok açıklamalarının nasıl işaretlendiğini tanımlar.", + "schema.blockComment.begin": "Blok açıklamasını başlatan karakter dizisi.", + "schema.blockComment.end": "Blok açıklamasını bitiren karakter dizisi.", + "schema.lineComment": "Satır açıklamasını başlatan karakter dizisi.", + "schema.brackets": "Girintiyi artıran veya azaltan ayraç sembollerini tanımlar.", + "schema.autoClosingPairs": "Ayraç çiftlerini tanımlar. Bir açılış ayracı girildiğinde, kapanış ayracı otomatik olarak eklenir.", + "schema.autoClosingPairs.notIn": "Otomatik çiftlerin devre dışı bırakıldığı bir kapsamlar listesi tanımlar.", + "schema.surroundingPairs": "Seçili bir dizeyi çevrelemek için kullanılabilecek ayraç çiftlerini tanımlar.", + "schema.wordPattern": "Dilin kelime tanımı.", + "schema.wordPattern.pattern": "Sözcükleri eşleştirmek için kullanılacak Düzenli İfade.", + "schema.wordPattern.flags": "Sözcükleri eşleştirmek için kullanılacak Düzenli İfade işaretleri.", + "schema.wordPattern.flags.errorMessage": "`/^([gimuy]+)$/` kalıbı ile eşleşmelidir." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/editor/node/textMate/TMGrammars.i18n.json b/i18n/trk/src/vs/editor/node/textMate/TMGrammars.i18n.json new file mode 100644 index 00000000000..60439bb3b95 --- /dev/null +++ b/i18n/trk/src/vs/editor/node/textMate/TMGrammars.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.grammars": "textmate tokenizerlere ekleme yapar.", + "vscode.extension.contributes.grammars.language": "Bu söz diziminin ekleneceği dil tanımlayıcısı.", + "vscode.extension.contributes.grammars.scopeName": "tmLanguage dosyası tarafından kullanılan Textmate kapsam adı.", + "vscode.extension.contributes.grammars.path": "tmLanguage dosyasının yolu. Yol, eklenti klasörüne görecelidir ve genellikle './syntaxes/' ile başlar.", + "vscode.extension.contributes.grammars.embeddedLanguages": "Bu dil bilgisinin gömülü dilleri içermesi durumundaki bir dil kimliğinin kapsam adı haritası.", + "vscode.extension.contributes.grammars.injectTo": "Bu dil bilgisinin yerleştirileceği dil kapsam adları listesi." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/platform/actions/browser/menuItemActionItem.i18n.json b/i18n/trk/src/vs/platform/actions/browser/menuItemActionItem.i18n.json new file mode 100644 index 00000000000..e64a7d0ed09 --- /dev/null +++ b/i18n/trk/src/vs/platform/actions/browser/menuItemActionItem.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "titleAndKb": "{0} ({1})" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json b/i18n/trk/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json new file mode 100644 index 00000000000..1fc7a735690 --- /dev/null +++ b/i18n/trk/src/vs/platform/actions/electron-browser/menusExtensionPoint.i18n.json @@ -0,0 +1,43 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "requirearray": "menü ögeleri bir dizi olmalıdır", + "requirestring": "`{0}` özelliği zorunludur ve `string` türünde olmalıdır", + "optstring": "`{0}` özelliği atlanabilir veya `string` türünde olmalıdır", + "vscode.extension.contributes.menuItem.command": "Yürütülecek komutun tanımlayıcısı. Komut 'commands' bölümünde tanımlanmalıdır", + "vscode.extension.contributes.menuItem.alt": "Yürütülecek alternatif bir komutun tanımlayıcısı. Komut 'commands' bölümünde tanımlanmalıdır", + "vscode.extension.contributes.menuItem.when": "Bu ögeyi göstermek için doğru olması gereken koşul", + "vscode.extension.contributes.menuItem.group": "Bu komutun ait olduğu gruba ekle", + "vscode.extension.contributes.menus": "Düzenleyiciye menü ögeleri ekler", + "menus.commandPalette": "Komut Paleti", + "menus.editorTitle": "Düzenleyici başlık menüsü", + "menus.editorContext": "Düzenleyici bağlam menüsü", + "menus.explorerContext": "Dosya gezgini bağlam menüsü", + "menus.editorTabContext": "Düzenleyici sekmeleri bağlam menüsü", + "menus.debugCallstackContext": "Hata ayıklama çağrı yığını bağlam menüsü", + "menus.scmTitle": "Kaynak Denetimi başlık menüsü", + "menus.resourceGroupContext": "Kaynak Denetimi kaynak grubu bağlam menüsü", + "menus.resourceStateContext": "Kaynak Denetimi kaynak durumu bağlam menüsü", + "view.viewTitle": "Katkıda bulunan görünümü başlık menüsü", + "view.itemContext": "Katkıda bulunan görünümü öge bağlam menüsü", + "nonempty": "boş olmayan değer beklendi.", + "opticon": "`icon` özelliği atlanabilir veya bir dize ya da `{dark, light}` gibi bir değişmez değer olmalıdır", + "requireStringOrObject": "`{0}` özelliği zorunludur ve `string` veya `object` türünde olmalıdır", + "requirestrings": "`{0}` ve `{1}` özellikleri zorunludur ve `string` türünde olmalıdır", + "vscode.extension.contributes.commandType.command": "Yürütülecek komutun tanımlayıcısı", + "vscode.extension.contributes.commandType.title": "Komutu kullanıcı arayüzünde temsil edecek başlık", + "vscode.extension.contributes.commandType.category": "(İsteğe Bağlı) Kullanıcı arayüzünde komutun gruplanacağı kategori dizesi", + "vscode.extension.contributes.commandType.icon": "(İsteğe Bağlı) Komutun, Kullanıcı Arayüzü'nde temsil edilmesinde kullanılacak simge. Bir dosya yolu veya tema olarak kullanılabilir bir yapılandırmadır", + "vscode.extension.contributes.commandType.icon.light": "Açık bir tema kullanıldığındaki simge yolu", + "vscode.extension.contributes.commandType.icon.dark": "Koyu bir tema kullanıldığındaki simge yolu", + "vscode.extension.contributes.commands": "Komut paletine komutlar ekler.", + "dup": "`{0}` komutu `commands` bölümünde birden çok kez görünüyor.", + "menuId.invalid": "`{0}` geçerli bir menü tanımlayıcısı değil", + "missing.command": "Menü ögesi, 'commands' bölümünde tanımlanmamış bir `{0}` komutuna başvuruyor.", + "missing.altCommand": "Menü ögesi, 'commands' bölümünde tanımlanmamış bir `{0}` alternatif komutuna başvuruyor.", + "dupe.command": "Menü ögesi, aynı varsayılan ve alternatif komutlarına başvuruyor", + "nosupport.altCommand": "Üzgünüz, fakat sadece 'editor/title' menüsünün 'navigation' grubu alternatif komutları destekliyor" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/platform/configuration/common/configurationRegistry.i18n.json b/i18n/trk/src/vs/platform/configuration/common/configurationRegistry.i18n.json new file mode 100644 index 00000000000..314a88ccc90 --- /dev/null +++ b/i18n/trk/src/vs/platform/configuration/common/configurationRegistry.i18n.json @@ -0,0 +1,19 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defaultConfigurations.title": "Varsayılan Yapılandırma Geçersiz Kılmaları", + "overrideSettings.description": "{0} dili için geçersiz kılınacak düzenleyici ayarlarını yapılandırın.", + "overrideSettings.defaultDescription": "Bir dil için geçersiz kılınacak düzenleyici ayarlarını yapılandırın.", + "vscode.extension.contributes.configuration": "Yapılandırma ayarlarına ekleme yapar.", + "vscode.extension.contributes.configuration.title": "Ayarların bir özeti. Bu etiket ayar dosyasında ayırıcı yorum olarak kullanılacaktır.", + "vscode.extension.contributes.configuration.properties": "Yapılandırma özelliklerinin açıklaması.", + "config.property.languageDefault": "'{0}' kaydedilemiyor. Bu, dile özgü düzenleyici ayarlarını tanımlamak için '\\\\[.*\\\\]$' özellik kalıbı ile eşleşir. 'configurationDefaults' ögesini kullanın.", + "config.property.duplicate": "'{0}' kaydedilemiyor. Bu özellik zaten kayıtlı.", + "invalid.properties": "'configuration.properties' bir nesne olmalıdır", + "invalid.type": "eğer ayarlanırsa, 'configuration.type' ögesi 'object' olarak ayarlanmalıdır", + "invalid.title": "'configuration.title' bir dize olmalıdır", + "vscode.extension.contributes.defaultConfiguration": "Varsayılan düzenleyici yapılandırma ayarlarına dil bazında ekleme yapar." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/platform/environment/node/argv.i18n.json b/i18n/trk/src/vs/platform/environment/node/argv.i18n.json new file mode 100644 index 00000000000..f3d197dfba2 --- /dev/null +++ b/i18n/trk/src/vs/platform/environment/node/argv.i18n.json @@ -0,0 +1,32 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "gotoValidation": "`--goto` modundaki argümanlar `FILE(:LINE(:CHARACTER))` biçiminde olmalıdır.", + "diff": "Bir karşılaştırma düzenleyicisi aç. İki dosya yolu argüman olarak iletilmelidir.", + "goto": "Yoldaki dosyayı satırda ve sütunda aç (yola :line[:character] ekleyin).", + "locale": "Kullanılacak yerel dil (örnek: en-US veya zh-TW).", + "newWindow": "Yeni bir Code örneğini zorla.", + "performance": "'Geliştirici: Başlangıç Performansı' komutu etkinleştirilmiş olarak başlat.", + "prof-startup": "Başlangıç sırasında CPU profil oluşturucusunu çalıştır", + "reuseWindow": "Bir dosya veya klasörü son etkin pencerede açmaya zorlayın.", + "userDataDir": "Kullanıcı verilerinin tutulacağı klasörü belirtir, root olarak çalışırken yararlıdır.", + "verbose": "Ayrıntılı çıktı oluştur (--wait anlamına gelir).", + "wait": "Geri dönmeden önce pencerenin kapanmasını bekle.", + "extensionHomePath": "Eklentilerin kök dizinini belirle.", + "listExtensions": "Yüklü eklentileri listele.", + "showVersions": "--list-extensions'u kullanırken, yüklü eklentilerin sürümlerini gösterir.", + "installExtension": "Bir eklenti yükler.", + "uninstallExtension": "Bir eklentiyi kaldırır.", + "experimentalApis": "Bir eklenti için önerilen API özelliklerini etkinleştirir.", + "disableExtensions": "Yüklü tüm eklentileri devre dışı bırak.", + "disableGPU": "GPU donanım hızlandırmasını devre dışı bırak.", + "version": "Sürümü göster.", + "help": "Kullanımı göster.", + "usage": "Kullanım", + "options": "seçenekler", + "paths": "yollar", + "optionsUpperCase": "Seçenekler" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/platform/extensionManagement/common/extensionEnablementService.i18n.json b/i18n/trk/src/vs/platform/extensionManagement/common/extensionEnablementService.i18n.json new file mode 100644 index 00000000000..a616c58befa --- /dev/null +++ b/i18n/trk/src/vs/platform/extensionManagement/common/extensionEnablementService.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noWorkspace": "Çalışma alanı yok." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/platform/extensionManagement/common/extensionManagement.i18n.json b/i18n/trk/src/vs/platform/extensionManagement/common/extensionManagement.i18n.json new file mode 100644 index 00000000000..b894836196d --- /dev/null +++ b/i18n/trk/src/vs/platform/extensionManagement/common/extensionManagement.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "extensions": "Eklentiler", + "preferences": "Tercihler" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/platform/extensionManagement/node/extensionGalleryService.i18n.json b/i18n/trk/src/vs/platform/extensionManagement/node/extensionGalleryService.i18n.json new file mode 100644 index 00000000000..e335acfc388 --- /dev/null +++ b/i18n/trk/src/vs/platform/extensionManagement/node/extensionGalleryService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "notFound": "Eklenti bulunamadı", + "noCompatible": "{0} eklentisinin Code'un bu sürümüyle uyumlu bir sürümü bulunamadı." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/platform/extensionManagement/node/extensionManagementService.i18n.json b/i18n/trk/src/vs/platform/extensionManagement/node/extensionManagementService.i18n.json new file mode 100644 index 00000000000..46113aaf483 --- /dev/null +++ b/i18n/trk/src/vs/platform/extensionManagement/node/extensionManagementService.i18n.json @@ -0,0 +1,22 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "invalidManifest": "Eklenti geçersiz: package.json bir JSON dosyası değil.", + "restartCode": "{0} eklentisini yeniden yüklemeden önce lütfen Code'u yeniden başlatın.", + "installDependeciesConfirmation": "'{0}' eklentisini yüklediğinizde onun bağımlılıkları da yüklenir. Devam etmek istiyor musunuz?", + "install": "Evet", + "doNotInstall": "Hayır", + "uninstallDependeciesConfirmation": "Yalnızca '{0}' eklentisini mi yoksa bağımlılıklarını da kaldırmak ister misiniz?", + "uninstallOnly": "Sadece Eklenti", + "uninstallAll": "Tümü", + "cancel": "İptal", + "uninstallConfirmation": "'{0}' eklentisini kaldırmak istediğinizden emin misiniz?", + "ok": "Tamam", + "singleDependentError": "'{0}' eklentisi kaldırılamıyor. '{1}' eklentisi buna bağlı.", + "twoDependentsError": "'{0}' eklentisi kaldırılamıyor. '{1}' ve '{2}' eklentileri buna bağlı.", + "multipleDependentsError": "'{0}' eklentisi kaldırılamıyor. '{1}, '{2}' eklentileri ve diğerleri buna bağlı.", + "notExists": "Eklenti bulunamadı" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/platform/extensions/common/abstractExtensionService.i18n.json b/i18n/trk/src/vs/platform/extensions/common/abstractExtensionService.i18n.json new file mode 100644 index 00000000000..f48bbd60795 --- /dev/null +++ b/i18n/trk/src/vs/platform/extensions/common/abstractExtensionService.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "unknownDep": "`{1}` eklentisi etkinleştirilemedi. Neden: bilinmeyen bağımlılık `{0}`.", + "failedDep1": "`{1}` eklentisi etkinleştirilemedi. Neden: bağımlılık `{0}` etkinleştirilemedi.", + "failedDep2": "`{0}` eklentisi etkinleştirilemedi. Neden: 10'dan fazla bağımlılık düzeyi (büyük olasılıkla bağımlılık döngüsü).", + "activationError": "`{0}` eklentisi etkinleştirilemedi: {1}." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/platform/extensions/common/extensionsRegistry.i18n.json b/i18n/trk/src/vs/platform/extensions/common/extensionsRegistry.i18n.json new file mode 100644 index 00000000000..64e1ebd91a4 --- /dev/null +++ b/i18n/trk/src/vs/platform/extensions/common/extensionsRegistry.i18n.json @@ -0,0 +1,30 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.engines.vscode": "Eklentinin uyumlu olduğu VS Code sürümünü belirten VS Code eklentileri için. * olamaz. Örneğin: ^0.10.5 uyumlu olduğu minimum VS Code sürümünün 0.10.5 olduğunu gösterir.", + "vscode.extension.publisher": "VS Code eklentisinin yayıncısı.", + "vscode.extension.displayName": "VS Code galerisinde kullanılan eklentinin görünen adı.", + "vscode.extension.categories": "Bu eklentiyi kategorize etmek için VS Code galerisi tarafından kullanılan kategoriler.", + "vscode.extension.galleryBanner": "VS Code markette kullanılan afiş.", + "vscode.extension.galleryBanner.color": "VS Code marketteki sayfa başlığındaki afiş rengi.", + "vscode.extension.galleryBanner.theme": "Afişte kullanılan yazı tipi için renk teması.", + "vscode.extension.contributes": "Bu paketin temsil ettiği VS Code eklentisinin tüm katkıları.", + "vscode.extension.preview": "Markette eklentinin Önizleme olarak işaretlenmesini sağlar.", + "vscode.extension.activationEvents": "VS Code eklentisi için etkinleştirme olayları.", + "vscode.extension.activationEvents.onLanguage": "Belirtilen dilde çözümlenen bir dosya her açıldığında bir etkinleştirme olayı yayınlanır.", + "vscode.extension.activationEvents.onCommand": "Belirtilen komut her çağrıldığında bir etkinleştirme olayı yayınlanır.", + "vscode.extension.activationEvents.onDebug": "Belirtilen türde bir hata ayıklama oturumu her başladığında bir etkinleştirme olayı yayınlanır.", + "vscode.extension.activationEvents.workspaceContains": "Belirtilen glob deseni ile eşleşen en az bir dosya içeren bir klasör her açıldığında bir etkinleştirme olayı yayınlanır.", + "vscode.extension.activationEvents.onView": "Belirtilen görünüm her genişletildiğinde bir etkinleştirme olayı yayınlanır.", + "vscode.extension.activationEvents.star": "VS Code başlatıldığında yayılan etkinleştirme olayı. Mükemmel bir son kullanıcı deneyimi sağlandığından emin olmak için, lütfen bu etkinleştirme olayını eklentinizde sadece kullanım durumunuzda başka hiçbir aktivasyon olayı kombinasyonu çalışmıyorsa kullanın.", + "vscode.extension.badges": "Marketin eklenti sayfasının kenar çubuğunda görüntülenecek göstergeler dizisi.", + "vscode.extension.badges.url": "Gösterge görüntüsü URL'si.", + "vscode.extension.badges.href": "Gösterge bağlantısı.", + "vscode.extension.badges.description": "Gösterge açıklaması.", + "vscode.extension.extensionDependencies": "Diğer uzantılara bağımlılıklar. Bir uzantının tanımlayıcısı her zaman ${publisher}.${name} biçimindedir. Örneğin: vscode.csharp.", + "vscode.extension.scripts.prepublish": "Paket, bir VS Code eklentisi olarak yayımlamadan önce çalıştırılacak betik.", + "vscode.extension.icon": "128x128 piksellik bir simgenin yolu." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/platform/extensions/node/extensionValidator.i18n.json b/i18n/trk/src/vs/platform/extensions/node/extensionValidator.i18n.json new file mode 100644 index 00000000000..1b6d6ecbb85 --- /dev/null +++ b/i18n/trk/src/vs/platform/extensions/node/extensionValidator.i18n.json @@ -0,0 +1,24 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "versionSyntax": "`engines.vscode` değeri {0} ayrıştırılamadı. Lütfen örnekte verilenlere benzer ifadeler kullanın: ^0.10.0, ^1.2.3, ^0.11.0, ^0.10.x, vb.", + "versionSpecificity1": "`engines.vscode`da belirtilen sürüm ({0}) yeterince belirli değil. vscode 1.0.0'dan önceki sürümler için, lütfen istenecek minimum majör ve minör sürüm numarasını tanımlayın. Örneğin: ^0.10.0, 0.10.x, 0.11.0, vb.", + "versionSpecificity2": "`engines.vscode`da belirtilen sürüm ({0}) yeterince belirli değil. vscode 1.0.0'dan sonraki sürümler için, lütfen istenecek minimum majör sürüm numarasını tanımlayın. Örneğin: ^1.10.0, 1.10.x, 1.x.x, 2.x.x, vb.", + "versionMismatch": "Eklenti, Code {0} ile uyumlu değil. Gereken sürüm: {1}.", + "extensionDescription.empty": "Boş eklenti açıklaması alındı", + "extensionDescription.publisher": "`{0}` özelliği zorunludur ve `string` türünde olmalıdır", + "extensionDescription.name": "`{0}` özelliği zorunludur ve `string` türünde olmalıdır", + "extensionDescription.version": "`{0}` özelliği zorunludur ve `string` türünde olmalıdır", + "extensionDescription.engines": "`{0}` özelliği zorunludur ve `object` türünde olmalıdır", + "extensionDescription.engines.vscode": "`{0}` özelliği zorunludur ve `string` türünde olmalıdır", + "extensionDescription.extensionDependencies": "`{0}` özelliği atlanabilir veya `string[]` türünde olmalıdır", + "extensionDescription.activationEvents1": "`{0}` özelliği atlanabilir veya `string[]` türünde olmalıdır", + "extensionDescription.activationEvents2": "`{0}` ve `{1}` özelliklerinin ikisi birden belirtilmeli veya ikisi birden atlanmalıdır", + "extensionDescription.main1": "`{0}` özelliği atlanabilir veya `string` türünde olmalıdır", + "extensionDescription.main2": "`main` ({0}) yolunun eklentinin klasörü içine ({1}) eklenmiş olacağı beklendi. Bu, eklentiyi taşınamaz yapabilir.", + "extensionDescription.main3": "`{0}` ve `{1}` özelliklerinin ikisi birden belirtilmeli veya ikisi birden atlanmalıdır", + "notSemver": "Eklenti sürümü semver ile uyumlu değil." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/platform/history/electron-main/historyMainService.i18n.json b/i18n/trk/src/vs/platform/history/electron-main/historyMainService.i18n.json new file mode 100644 index 00000000000..9e486dd5b43 --- /dev/null +++ b/i18n/trk/src/vs/platform/history/electron-main/historyMainService.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "newWindow": "Yeni Pencere", + "newWindowDesc": "Yeni bir pencere açar", + "recentFolders": "Son Kullanılan Klasörler", + "folderDesc": "{0} {1}" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/platform/integrity/node/integrityServiceImpl.i18n.json b/i18n/trk/src/vs/platform/integrity/node/integrityServiceImpl.i18n.json new file mode 100644 index 00000000000..8d0fe384379 --- /dev/null +++ b/i18n/trk/src/vs/platform/integrity/node/integrityServiceImpl.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "integrity.ok": "Tamam", + "integrity.dontShowAgain": "Tekrar gösterme", + "integrity.moreInfo": "Daha fazla bilgi", + "integrity.prompt": "{0} kurulumunuz bozuk görünüyor. Lütfen yeniden yükleyin." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/platform/jsonschemas/common/jsonValidationExtensionPoint.i18n.json b/i18n/trk/src/vs/platform/jsonschemas/common/jsonValidationExtensionPoint.i18n.json new file mode 100644 index 00000000000..8a050918f96 --- /dev/null +++ b/i18n/trk/src/vs/platform/jsonschemas/common/jsonValidationExtensionPoint.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "contributes.jsonValidation": "json şema yapılandırmasına ekleme yapar.", + "contributes.jsonValidation.fileMatch": "Eşleşecek dosya örüntüsü, örneğin \"package.json\" veya \"*.launch\".", + "contributes.jsonValidation.url": "Bir şema URL'si ('http:', 'https:') veya eklenti klasörüne ('./') göreceli yol.", + "invalid.jsonValidation": "'configuration.jsonValidation' bir dizi olmalıdır", + "invalid.fileMatch": "'configuration.jsonValidation.fileMatch' tanımlanmalıdır", + "invalid.url": "'configuration.jsonValidation.url' bir URL veya göreli yol olmalıdır", + "invalid.url.fileschema": "'configuration.jsonValidation.url' geçersiz bir göreli URL'dir: {0}", + "invalid.url.schema": "'configuration.jsonValidation.url' ögesi eklentide bulunan şemalara başvurmak için 'http:', 'https:' veya './' ile başlamalıdır" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/platform/keybinding/common/abstractKeybindingService.i18n.json b/i18n/trk/src/vs/platform/keybinding/common/abstractKeybindingService.i18n.json new file mode 100644 index 00000000000..3993824999c --- /dev/null +++ b/i18n/trk/src/vs/platform/keybinding/common/abstractKeybindingService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "first.chord": "({0}) öğesine basıldı. Akorun ikinci tuşu bekleniyor...", + "missing.chord": "({0}, {1}) tuş bileşimi bir komut değil." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/platform/markers/common/problemMatcher.i18n.json b/i18n/trk/src/vs/platform/markers/common/problemMatcher.i18n.json new file mode 100644 index 00000000000..cce6c021fdc --- /dev/null +++ b/i18n/trk/src/vs/platform/markers/common/problemMatcher.i18n.json @@ -0,0 +1,61 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ProblemPatternParser.loopProperty.notLast": "Döngü özelliği yalnızca son satır eşleştiricisinde desteklenir.", + "ProblemPatternParser.problemPattern.missingRegExp": "Sorun modelinde bir düzenli ifade eksik.", + "ProblemPatternParser.problemPattern.missingProperty": "Sorun modeli hatalı. En az bir dosya, mesaj ve satır veya konum eşleşme grubu bulundurmalıdır.", + "ProblemPatternParser.invalidRegexp": "Hata: Dize {0}, geçerli bir düzenli ifade değil.\n", + "ProblemPatternSchema.regexp": "Çıktıda bir hata, uyarı veya bilgi bulan düzenli ifade.", + "ProblemPatternSchema.file": "Dosya adının eşleştirme grubu indeksi. Atlanırsa 1 kullanılır.", + "ProblemPatternSchema.location": "Sorunun bulunduğu yerin eşleşme grubu indeksi. Geçerli konum örüntüleri şunlardır: (line), (line,column) ve (startLine,startColumn,endLine,endColumn). Atlanmışsa (line,column) varsayılır.", + "ProblemPatternSchema.line": "Sorunun satırının eşleştirme grubu indeksi. Varsayılan değeri 2'dir", + "ProblemPatternSchema.column": "Sorunun satır karakterinin eşleştirme grubu indeksi. Varsayılan değeri 3'tür", + "ProblemPatternSchema.endLine": "Sorunun satır sonunun eşleştirme grubu indeksi. Varsayılan değeri tanımsızdır", + "ProblemPatternSchema.endColumn": "Sorunun satır sonu karakterinin eşleştirme grubu indeksi. Varsayılan değeri tanımsızdır", + "ProblemPatternSchema.severity": "Sorunun öneminin eşleştirme grubu indeksi. Varsayılan değeri tanımsızdır", + "ProblemPatternSchema.code": "Sorunun kodunun eşleştirme grubu indeksi. Varsayılan değeri tanımsızdır", + "ProblemPatternSchema.message": "Mesajın eşleştirme grubu indeksi. Atlanırsa konum belirtildiğinde varsayılan olarak 4 kullanılır. Aksi taktirde varsayılan olarak 5 kullanılır.", + "ProblemPatternSchema.loop": "Birden çok satırlı eşleşmede döngü, bu kalıbın eşleştiği sürece bir döngüde yürütülüp yürütülmeyeceğini gösterir. Yalnızca birden çok satırlı bir kalıbın son kalıbında belirtilebilir.", + "NamedProblemPatternSchema.name": "Sorun modelinin adı.", + "NamedMultiLineProblemPatternSchema.name": "Birden çok satırlı sorun modelinin adı.", + "NamedMultiLineProblemPatternSchema.patterns": "Gerçek modeller.", + "ProblemPatternExtPoint": "Sorun modellerine ekleme yapar", + "ProblemPatternRegistry.error": "Geçersiz sorun modeli. Model yok sayılacaktır.", + "ProblemMatcherParser.noProblemMatcher": "Hata: açıklama bir sorun eşleştiricisine dönüştürülemez:\n{0}\n", + "ProblemMatcherParser.noProblemPattern": "Hata: açıklama geçerli bir sorun modeli tanımlamıyor:\n{0}\n", + "ProblemMatcherParser.noOwner": "Hata: açıklama bir sahip tanımlamıyor:\n{0}\n", + "ProblemMatcherParser.noFileLocation": "Hata: açıklama bir dosya yolu tanımlamıyor:\n{0}\n", + "ProblemMatcherParser.unknownSeverity": "Bilgi: bilinmeyen önem derecesi {0}. Geçerli değerler: error, warning ve info.\n", + "ProblemMatcherParser.noDefinedPatter": "Hata: tanımlayıcısı {0} olan model mevcut değil.", + "ProblemMatcherParser.noIdentifier": "Hata: model özelliği boş bir tanımlayıcıya karşılık geliyor.", + "ProblemMatcherParser.noValidIdentifier": "Hata: model özelliği {0} geçerli bir model değişkeni adı değil.", + "ProblemMatcherParser.problemPattern.watchingMatcher": "Bir sorun eşleştiricisi izlenecek bir başlangıç örüntüsü ve bir bitiş örüntüsü tanımlamalıdır.", + "ProblemMatcherParser.invalidRegexp": "Hata: Dize {0}, geçerli bir düzenli ifade değil.\n", + "WatchingPatternSchema.regexp": "Bir arka plan görevinin başlangıcını ve sonunu tespit edecek düzenli ifade.", + "WatchingPatternSchema.file": "Dosya adının eşleştirme grubu indeksi. Atlanabilir.", + "PatternTypeSchema.name": "Katkıda bulunulan veya ön tanımlı modelin adı", + "PatternTypeSchema.description": "Bir sorun modeli veya bir katkıda bulunulan veya ön tanımlı sorun modelinin adı. Temel model belirtildiyse atlanabilir.", + "ProblemMatcherSchema.base": "Kullanılacak temel sorun eşleştiricisinin adı.", + "ProblemMatcherSchema.owner": "Code'un içindeki sorunun sahibi. Temel model belirtildiyse atlanabilir. Atlanırsa ve temel belirtilmemişse 'external' varsayılır.", + "ProblemMatcherSchema.severity": "Sorun yakalamanın varsayılan önem derecesi. Model, önem derecesi için bir eşleme grubu tanımlamazsa kullanılır.", + "ProblemMatcherSchema.applyTo": "Bir metin belgesinde bildirilen bir sorunun sadece açık, kapalı veya tüm belgelere uygulanıp uygulanmadığını denetler.", + "ProblemMatcherSchema.fileLocation": "Bir sorun modelinde bildirilen dosya adlarının nasıl yorumlanacağını tanımlar.", + "ProblemMatcherSchema.background": "Bir arka plan görevinde aktif bir eşleştiricinin başlangıcını ve sonunu izlemek için kullanılan kalıplar.", + "ProblemMatcherSchema.background.activeOnStart": "\"true\" olarak ayarlanırsa, görev başladığında arka plan izleyicisi etkin modda olur. Bu, beginsPattern ile başlayan bir satırın verilmesi demektir", + "ProblemMatcherSchema.background.beginsPattern": "Çıktıda eşleşmesi halinde, arka plan görevinin başlatılması sinyali verilir.", + "ProblemMatcherSchema.background.endsPattern": "Çıktıda eşleşmesi halinde, arka plan görevinin sonu sinyali verilir.", + "ProblemMatcherSchema.watching.deprecated": "İzleme özelliği kullanım dışıdır. Onun yerine arka planı kullanın.", + "ProblemMatcherSchema.watching": "Bir izleme eşleştiricisinin başlangıcını ve sonunu izlemek için kullanılan kalıplar.", + "ProblemMatcherSchema.watching.activeOnStart": "\"true\" olarak ayarlanırsa, görev başladığında izleyici etkin modda olur. Bu, beginsPattern ile başlayan bir satırın verilmesi demektir", + "ProblemMatcherSchema.watching.beginsPattern": "Çıktıda eşleşmesi halinde, izleme görevinin başlatılması sinyali verilir.", + "ProblemMatcherSchema.watching.endsPattern": "Çıktıda eşleşmesi halinde, izleme görevinin sonu sinyali verilir.", + "LegacyProblemMatcherSchema.watchedBegin.deprecated": "Bu özellik kullanım dışıdır. Bunun yerine 'watching' özelliğini kullanın.", + "LegacyProblemMatcherSchema.watchedBegin": "İzlenen görevlerin yürütülmeye başlanmasının, dosya izleyerek tetiklendiğini işaret eden bir düzenli ifade.", + "LegacyProblemMatcherSchema.watchedEnd.deprecated": "Bu özellik kullanım dışıdır. Bunun yerine 'watching' özelliğini kullanın.", + "LegacyProblemMatcherSchema.watchedEnd": "İzlenen görevlerin yürütülmesinin sona erdiğini işaret eden bir düzenli ifade.", + "NamedProblemMatcherSchema.name": "Sorun eşleştiricisinin adı.", + "ProblemMatcherExtPoint": "Sorun eşleştiricilerine ekleme yapar" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/platform/message/common/message.i18n.json b/i18n/trk/src/vs/platform/message/common/message.i18n.json new file mode 100644 index 00000000000..4f9a44f9383 --- /dev/null +++ b/i18n/trk/src/vs/platform/message/common/message.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "close": "Kapat", + "later": "Daha Sonra", + "cancel": "İptal" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/platform/request/node/request.i18n.json b/i18n/trk/src/vs/platform/request/node/request.i18n.json new file mode 100644 index 00000000000..90faed28342 --- /dev/null +++ b/i18n/trk/src/vs/platform/request/node/request.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "httpConfigurationTitle": "HTTP", + "proxy": "Kullanılacak proxy ayarı. Ayarlanmazsa, http_proxy ve https_proxy ortam değişkenlerinden alınır", + "strictSSL": "Proxy sunucu sertifikasının verilen Sertifika Yetkilileri listesine göre doğrulanması gerekip gerekmediği.", + "proxyAuthorization": "Her ağ isteği için 'Proxy-Authorization' başlığı olarak gönderilecek değer." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/platform/telemetry/common/telemetryService.i18n.json b/i18n/trk/src/vs/platform/telemetry/common/telemetryService.i18n.json new file mode 100644 index 00000000000..6c5812585d7 --- /dev/null +++ b/i18n/trk/src/vs/platform/telemetry/common/telemetryService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "telemetryConfigurationTitle": "Telemetri", + "telemetry.enableTelemetry": "Kullanım verileri ve hataların Microsoft'a gönderilmesini etkinleştirin." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/platform/theme/common/colorRegistry.i18n.json b/i18n/trk/src/vs/platform/theme/common/colorRegistry.i18n.json new file mode 100644 index 00000000000..0c4954b0a9a --- /dev/null +++ b/i18n/trk/src/vs/platform/theme/common/colorRegistry.i18n.json @@ -0,0 +1,88 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "invalid.color": "Geçersiz renk biçimi. #RGB, #RGBA, #RRGGBB veya #RRGGBBAA kullanın", + "schema.colors": "Çalışma ekranında kullanılan renkler.", + "foreground": "Genel ön plan rengi. Bu renk, bir bileşen tarafından geçersiz kılınmadıkça kullanılır.", + "errorForeground": "Hata mesajları için genel ön plan rengi. Bu renk, bir bileşen tarafından geçersiz kılınmadıkça kullanılır.", + "descriptionForeground": "Ek bilgi sağlayan açıklama metni(örneğin bir etiket) için ön plan rengi.", + "focusBorder": "Odaklanılan ögeler için genel kenarlık rengi. Bu renk, bir bileşen tarafından geçersiz kılınmadıkça kullanılır.", + "contrastBorder": "Daha fazla kontrast için, ögelerin etrafında onları diğerlerinden ayıracak ekstra bir kenarlık.", + "activeContrastBorder": "Daha fazla kontrast için, aktif ögelerin etrafında onları diğerlerinden ayıracak ekstra bir kenarlık.", + "selectionBackground": "Çalışma ekranındaki metin seçimlerinin arka plan rengi(örneğin girdi alanları veya metin alanları). Bunun, düzenleyicideki seçimlere uygulanmayacağını unutmayın.", + "textSeparatorForeground": "Metin ayırıcıların rengi.", + "textLinkForeground": "Metindeki bağlantıların ön plan rengi.", + "textLinkActiveForeground": "Metindeki aktif bağlantıların ön plan rengi.", + "textPreformatForeground": "Önceden biçimlendirilmiş metin parçalarının ön plan rengi.", + "textBlockQuoteBackground": "Metindeki alıntı bloklarının arka plan rengi.", + "textBlockQuoteBorder": "Metindeki alıntı bloklarının kenarlık rengi.", + "textCodeBlockBackground": "Metindeki kod bloklarının arka plan rengi.", + "widgetShadow": "Bul/değiştir gibi düzenleyici içindeki araçların gölge rengi.", + "inputBoxBackground": "Giriş kutusu arka planı.", + "inputBoxForeground": "Giriş kutusu ön planı.", + "inputBoxBorder": "Giriş kutusu kenarlığı.", + "inputBoxActiveOptionBorder": "Girdi alanlarındaki aktif seçeneklerin kenarlık rengi.", + "inputPlaceholderForeground": "Yer tutucu metin için girdi kutusu ön plan rengi.", + "inputValidationInfoBackground": "Bilgi önem derecesi için girdi doğrulama arka plan rengi.", + "inputValidationInfoBorder": "Bilgi önem derecesi için girdi doğrulama kenarlık rengi.", + "inputValidationWarningBackground": "Bilgi uyarısı için girdi doğrulama arka plan rengi.", + "inputValidationWarningBorder": "Uyarı önem derecesi için girdi doğrulama kenarlık rengi.", + "inputValidationErrorBackground": "Hata önem derecesi için girdi doğrulama arka plan rengi.", + "inputValidationErrorBorder": "Hata önem derecesi için girdi doğrulama kenarlık rengi.", + "dropdownBackground": "Açılır kutu arka planı.", + "dropdownForeground": "Açılır kutu ön planı.", + "dropdownBorder": "Açılır kutu kenarlığı.", + "listFocusBackground": "Liste/Ağaç aktifken odaklanılan ögenin Lise/Ağaç arka plan rengi. Bir aktif liste/ağaç, klavye odağındadır; pasif olan odakta değildir.", + "listFocusForeground": "Liste/Ağaç aktifken odaklanılan ögenin Lise/Ağaç ön plan rengi. Bir aktif liste/ağaç, klavye odağındadır; pasif olan odakta değildir.", + "listActiveSelectionBackground": "Liste/Ağaç aktifken seçilen ögenin Lise/Ağaç arka plan rengi. Bir aktif liste/ağaç, klavye odağındadır; pasif olan odakta değildir.", + "listActiveSelectionForeground": "Liste/Ağaç aktifken seçilen ögenin Lise/Ağaç ön plan rengi. Bir aktif liste/ağaç, klavye odağındadır; pasif olan odakta değildir.", + "listInactiveSelectionBackground": "Liste/Ağaç pasifken seçilen ögenin Lise/Ağaç arka plan rengi. Bir aktif liste/ağaç, klavye odağındadır; pasif olan odakta değildir.", + "listInactiveSelectionForeground": "Liste/Ağaç pasifken seçilen ögenin Lise/Ağaç ön plan rengi. Bir aktif liste/ağaç, klavye odağındadır; pasif olan odakta değildir.", + "listHoverBackground": "Fare ile ögelerin üzerine gelindiğinde Liste/Ağaç arka planı.", + "listHoverForeground": "Fare ile ögelerin üzerine gelindiğinde Liste/Ağaç ön planı.", + "listDropBackground": "Fare ile ögeler taşınırken Liste/Ağaç sürükle ve bırak arka planı.", + "highlight": "Liste/Ağaç içinde arama yaparken eşleşme vurgularının Liste/Ağaç ön plan rengi.", + "pickerGroupForeground": "Gruplama etiketleri için hızlı seçici rengi.", + "pickerGroupBorder": "Gruplama kenarlıkları için hızlı seçici rengi.", + "buttonForeground": "Buton ön plan rengi.", + "buttonBackground": "Buton arka plan rengi.", + "buttonHoverBackground": "Fareyle üzerine gelindiğinde buton arka plan rengi.", + "badgeBackground": "Gösterge arka plan rengi. Göstergeler küçük bilgi etiketleridir, ör. arama sonucu sayısı için.", + "badgeForeground": "Gösterge ön plan rengi. Göstergeler küçük bilgi etiketleridir, ör. arama sonucu sayısı için.", + "scrollbarShadow": "Görünümün kaydırıldığını belirtmek için kaydırma çubuğu gölgesi.", + "scrollbarSliderBackground": "Kaydıraç arka plan rengi.", + "scrollbarSliderHoverBackground": "Fareyle üzerine gelindiğinde kaydıraç arka plan rengi.", + "scrollbarSliderActiveBackground": "Aktif kaydıraç arka plan rengi.", + "progressBarBackground": "Uzun süren işlemleri gösterebilen ilerleme çubuğunun arka plan rengi.", + "editorBackground": "Düzenleyici arka plan rengi.", + "editorForeground": "Düzenleyici varsayılan ön plan rengi.", + "editorWidgetBackground": "Bul/değiştir gibi düzenleyici araçlarının arka plan rengi.", + "editorWidgetBorder": "Editör araçlarının kenarlık rengi. Renk, araç bir kenarlığı olmasına karar verdiğinde ve renk hiçbir eklenti tarafından geçersiz kılınmadığında kullanılır.", + "editorSelection": "Düzenleyici seçiminin rengi.", + "editorInactiveSelection": "Bir pasif düzenleyicideki seçimin rengi.", + "editorSelectionHighlight": "Seçimle aynı içeriğe sahip bölgelerin rengi.", + "editorFindMatch": "Geçerli arama eşleşmesinin rengi.", + "findMatchHighlight": "Diğer arama eşleşmelerinin rengi.", + "findRangeHighlight": "Aramayı sınırlayan aralığı renklendirin.", + "hoverHighlight": "Bağlantı vurgusu gösterilen bir sözcüğün altını vurgulayın.", + "hoverBackground": "Düzenleyici bağlantı vurgusunun arka plan rengi.", + "hoverBorder": "Düzenleyici bağlantı vurgusunun kenarlık rengi.", + "activeLinkForeground": "Aktif bağlantıların rengi.", + "diffEditorInserted": "Eklenen metnin arka plan rengi.", + "diffEditorRemoved": "Çıkarılan metnin arka plan rengi.", + "diffEditorInsertedOutline": "Eklenen metnin ana hat rengi.", + "diffEditorRemovedOutline": "Çıkarılan metnin ana hat rengi.", + "mergeCurrentHeaderBackground": "Satır içi birleştirme çakışmalarında geçerli üstbilgi arka planı.", + "mergeCurrentContentBackground": "Satır içi birleştirme çakışmalarında geçerli içerik arka planı.", + "mergeIncomingHeaderBackground": "Satır içi birleştirme çakışmalarında gelen üstbilgi arka planı.", + "mergeIncomingContentBackground": "Satır içi birleştirme çakışmalarında gelen içerik arka planı.", + "mergeCommonHeaderBackground": "Satır içi birleştirme çakışmalarında ortak ata üstbilgisi arka planı.", + "mergeCommonContentBackground": "Satır içi birleştirme çakışmalarında ortak ata içeriği arka planı.", + "mergeBorder": "Satır içi birleştirme çakışmalarında üst bilgi ve ayırıcıdaki kenarlık rengi.", + "overviewRulerCurrentContentForeground": "Satır içi birleştirme çakışmalarında geçerli genel bakış cetveli ön planı.", + "overviewRulerIncomingContentForeground": "Satır içi birleştirme çakışmalarında gelen genel bakış cetveli ön planı.", + "overviewRulerCommonContentForeground": "Satır içi birleştirme çakışmalarında ortak ata genel bakış cetveli ön planı." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/api/electron-browser/mainThreadExtensionService.i18n.json b/i18n/trk/src/vs/workbench/api/electron-browser/mainThreadExtensionService.i18n.json new file mode 100644 index 00000000000..0a8ef8463d3 --- /dev/null +++ b/i18n/trk/src/vs/workbench/api/electron-browser/mainThreadExtensionService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "overwritingExtension": "{0} eklentisinin üzerine {1} yazılıyor.", + "extensionUnderDevelopment": "{0} konumundaki geliştirme eklentisi yükleniyor" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/api/electron-browser/mainThreadMessageService.i18n.json b/i18n/trk/src/vs/workbench/api/electron-browser/mainThreadMessageService.i18n.json new file mode 100644 index 00000000000..d3de90fb241 --- /dev/null +++ b/i18n/trk/src/vs/workbench/api/electron-browser/mainThreadMessageService.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "close": "Kapat", + "cancel": "İptal", + "ok": "Tamam" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/api/node/extHostDiagnostics.i18n.json b/i18n/trk/src/vs/workbench/api/node/extHostDiagnostics.i18n.json new file mode 100644 index 00000000000..ebbdf8fa988 --- /dev/null +++ b/i18n/trk/src/vs/workbench/api/node/extHostDiagnostics.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "limitHit": "Diğer {0} hata ve uyarılar gösterilmiyor." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/api/node/extHostTask.i18n.json b/i18n/trk/src/vs/workbench/api/node/extHostTask.i18n.json new file mode 100644 index 00000000000..4b90a12aaf2 --- /dev/null +++ b/i18n/trk/src/vs/workbench/api/node/extHostTask.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "task.label": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/api/node/extHostTreeViews.i18n.json b/i18n/trk/src/vs/workbench/api/node/extHostTreeViews.i18n.json new file mode 100644 index 00000000000..a3dd0ab5f95 --- /dev/null +++ b/i18n/trk/src/vs/workbench/api/node/extHostTreeViews.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "treeView.notRegistered": "Kayıtlı '{0}' Id'li ağaç görünümü yok.", + "treeItem.notFound": "'{0}' Id'li ağaç ögesi yok.", + "treeView.duplicateElement": "{0} ögesi zaten kayıtlı" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/actions/configureLocale.i18n.json b/i18n/trk/src/vs/workbench/browser/actions/configureLocale.i18n.json new file mode 100644 index 00000000000..d7620dc687c --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/actions/configureLocale.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "configureLocale": "Dili Yapılandır", + "displayLanguage": "VSCode'un görüntüleme dilini tanımlar.", + "doc": "Desteklenen dillerin listesi için göz atın: {0}", + "restart": "Değeri değiştirirseniz VSCode'u yeniden başlatmanız gerekir.", + "fail.createSettings": " '{0}' oluşturulamadı ({1}).", + "JsonSchema.locale": "Kullanılacak Kullanıcı Arayüzü Dili." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/actions/fileActions.i18n.json b/i18n/trk/src/vs/workbench/browser/actions/fileActions.i18n.json new file mode 100644 index 00000000000..68a8df34a5b --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/actions/fileActions.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openFolder": "Klasör Aç...", + "openFileFolder": "Aç..." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/actions/toggleActivityBarVisibility.i18n.json b/i18n/trk/src/vs/workbench/browser/actions/toggleActivityBarVisibility.i18n.json new file mode 100644 index 00000000000..1af785233f8 --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/actions/toggleActivityBarVisibility.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleActivityBar": "Etkinlik Çubuğunu Gizle/Göster", + "view": "Görüntüle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/actions/toggleEditorLayout.i18n.json b/i18n/trk/src/vs/workbench/browser/actions/toggleEditorLayout.i18n.json new file mode 100644 index 00000000000..237f4af975c --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/actions/toggleEditorLayout.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleEditorGroupLayout": "Düzenleyici Grubunu Dikey/Yatay Düzende Değiştir", + "horizontalLayout": "Yatay Düzenleyici Grubu Düzeni", + "verticalLayout": "Dikey Düzenleyici Grubu Düzeni", + "view": "Görüntüle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/actions/toggleSidebarPosition.i18n.json b/i18n/trk/src/vs/workbench/browser/actions/toggleSidebarPosition.i18n.json new file mode 100644 index 00000000000..b5c1cbc783e --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/actions/toggleSidebarPosition.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleLocation": "Kenar Çubuğu Konumunu Değiştir", + "view": "Görüntüle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/actions/toggleSidebarVisibility.i18n.json b/i18n/trk/src/vs/workbench/browser/actions/toggleSidebarVisibility.i18n.json new file mode 100644 index 00000000000..714ae09d790 --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/actions/toggleSidebarVisibility.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleSidebar": "Kenar Çubuğunu Gizle/Göster", + "view": "Görüntüle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/actions/toggleStatusbarVisibility.i18n.json b/i18n/trk/src/vs/workbench/browser/actions/toggleStatusbarVisibility.i18n.json new file mode 100644 index 00000000000..8636912355a --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/actions/toggleStatusbarVisibility.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleStatusbar": "Durum Çubuğunu Gizle/Göster", + "view": "Görüntüle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/actions/toggleZenMode.i18n.json b/i18n/trk/src/vs/workbench/browser/actions/toggleZenMode.i18n.json new file mode 100644 index 00000000000..999c18e1dbd --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/actions/toggleZenMode.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleZenMode": "Zen Modunu Aç/Kapat", + "view": "Görüntüle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/activitybar/activitybarActions.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/activitybar/activitybarActions.i18n.json new file mode 100644 index 00000000000..eaa011efe7e --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/activitybar/activitybarActions.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "removeFromActivityBar": "Etkinlik Çubuğundan Kaldır", + "keepInActivityBar": "Etkinlik Çubuğunda Tut", + "titleKeybinding": "{0} ({1})", + "additionalViews": "Ek Görünümler", + "numberBadge": "{0} ({1})", + "manageExtension": "Eklentiyi Yönet", + "toggle": "Görünüm Sabitlemeyi Aç/Kapat" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json new file mode 100644 index 00000000000..32c2c08ce4c --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/activitybar/activitybarPart.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "hideActivitBar": "Etkinlik Çubuğunu Gizle", + "activityBarAriaLabel": "Aktif Görünüm Değiştirici", + "globalActions": "Global Eylemler" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/compositePart.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/compositePart.i18n.json new file mode 100644 index 00000000000..b9eadbfaa89 --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/compositePart.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ariaCompositeToolbarLabel": "{0} eylem", + "titleTooltip": "{0} ({1})" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/editor/binaryDiffEditor.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/editor/binaryDiffEditor.i18n.json new file mode 100644 index 00000000000..a38af02d663 --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/editor/binaryDiffEditor.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "metadataDiff": "{0} ↔ {1}" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/editor/binaryEditor.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/editor/binaryEditor.i18n.json new file mode 100644 index 00000000000..23b8e1bad30 --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/editor/binaryEditor.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "binaryEditor": "İkili Görüntüleyici" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/editor/editor.contribution.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/editor/editor.contribution.i18n.json new file mode 100644 index 00000000000..9059d7f92c9 --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/editor/editor.contribution.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "textEditor": "Metin Düzenleyicisi", + "textDiffEditor": "Metin Diff Düzenleyicisi", + "binaryDiffEditor": "İkili Diff Düzenleyicisi", + "sideBySideEditor": "Yan Yana Düzenleyici", + "groupOnePicker": "İlk Gruptaki Düzenleyicileri Göster", + "groupTwoPicker": "İkinci Gruptaki Düzenleyicileri Göster", + "groupThreePicker": "Üçüncü Gruptaki Düzenleyicileri Göster", + "allEditorsPicker": "Açık Tüm Düzenleyicileri Göster", + "view": "Görüntüle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/editor/editorActions.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/editor/editorActions.i18n.json new file mode 100644 index 00000000000..01f0b8ffcc9 --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/editor/editorActions.i18n.json @@ -0,0 +1,56 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "splitEditor": "Düzenleyiciyi Böl", + "joinTwoGroups": "İki Gruptaki Düzenleyicileri Birleştir", + "navigateEditorGroups": "Düzenleyici Grupları Arasında Gezin", + "focusActiveEditorGroup": "Aktif Düzenleyici Grubuna Odakla", + "focusFirstEditorGroup": "İlk Düzenleyici Grubuna Odakla", + "focusSecondEditorGroup": "İkinci Düzenleyici Grubuna Odakla", + "focusThirdEditorGroup": "Üçüncü Düzenleyici Grubuna Odakla", + "focusPreviousGroup": "Önceki Gruba Odakla", + "focusNextGroup": "Sonraki Gruba Odakla", + "openToSide": "Yana Aç", + "closeEditor": "Düzenleyiciyi Kapat", + "revertAndCloseActiveEditor": "Geri Al ve Düzenleyiciyi Kapat", + "closeEditorsToTheLeft": "Düzenleyicinin Solundakileri Kapat", + "closeEditorsToTheRight": "Düzenleyicinin Sağındakileri Kapat", + "closeAllEditors": "Tüm Düzenleyicileri Kapat", + "closeUnmodifiedEditors": "Gruptaki Değiştirilmemiş Düzenleyicileri Kapat", + "closeEditorsInOtherGroups": "Diğer Gruplardaki Tüm Düzenleyicileri Kapat", + "closeOtherEditorsInGroup": "Diğer Düzenleyicileri Kapat", + "closeEditorsInGroup": "Gruptaki Tüm Düzenleyicileri Kapat", + "moveActiveGroupLeft": "Düzenleyici Grubunu Sola Taşı", + "moveActiveGroupRight": "Düzenleyici Grubunu Sağa Taşı", + "minimizeOtherEditorGroups": "Diğer Düzenleyici Gruplarını Küçült", + "evenEditorGroups": "Düzenleyici Grup Genişliklerini Eşitle", + "maximizeEditor": "Düzenleyici Grubunu Olabildiğince Genişlet ve Kenar Çubuğunu Gizle", + "keepEditor": "Düzenleyiciyi Tut", + "openNextEditor": "Sonraki Düzenleyiciyi Aç", + "openPreviousEditor": "Önceki Düzenleyiciyi Aç", + "nextEditorInGroup": "Gruptaki Sonraki Düzenleyiciyi Aç", + "openPreviousEditorInGroup": "Gruptaki Önceki Düzenleyiciyi Aç", + "navigateNext": "İleri Git", + "navigatePrevious": "Geri Dön", + "reopenClosedEditor": "Kapatılan Düzenleyiciyi Yeniden Aç", + "clearRecentFiles": "Son Kullanılan Dosyaları Temizle", + "showEditorsInFirstGroup": "İlk Gruptaki Düzenleyicileri Göster", + "showEditorsInSecondGroup": "İkinci Gruptaki Düzenleyicileri Göster", + "showEditorsInThirdGroup": "Üçüncü Gruptaki Düzenleyicileri Göster", + "showEditorsInGroup": "Gruptaki Düzenleyicileri Göster", + "showAllEditors": "Tüm Düzenleyicileri Göster", + "openPreviousRecentlyUsedEditorInGroup": "Gruptaki Son Kullanılan Önceki Düzenleyiciyi Aç", + "openNextRecentlyUsedEditorInGroup": "Gruptaki Son Kullanılan Sonraki Düzenleyiciyi Aç", + "navigateEditorHistoryByInput": "Geçmişteki Önceki Düzenleyiciyi Aç", + "openNextRecentlyUsedEditor": "Son Kullanılan Sonraki Düzenleyiciyi Aç", + "openPreviousRecentlyUsedEditor": "Son Kullanılan Önceki Düzenleyiciyi Aç", + "clearEditorHistory": "Düzenleyici Geçmişini Temizle", + "focusLastEditorInStack": "Gruptaki Son Düzenleyiciyi Aç", + "moveEditorLeft": "Düzenleyiciyi Sola Taşı", + "moveEditorRight": "Düzenleyiciyi Sağa Taşı", + "moveEditorToPreviousGroup": "Düzenleyiciyi Önceki Gruba Taşı", + "moveEditorToNextGroup": "Düzenleyiciyi Sonraki Gruba Taşı" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/editor/editorCommands.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/editor/editorCommands.i18n.json new file mode 100644 index 00000000000..ec6a3cb04f0 --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/editor/editorCommands.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorCommand.activeEditorMove.description": "Aktif düzenleyiciyi sekmeler veya gruplar halinde taşıyın", + "editorCommand.activeEditorMove.arg.name": "Aktif düzenleyici taşıma argümanı", + "editorCommand.activeEditorMove.arg.description": "Argüman Özellikleri:\n\t\t\t\t\t\t* 'to': Nereye taşınacağını belirten dize değeri.\n\t\t\t\t\t\t* 'by': Kaç birim taşınacağını belirten dize değeri. Sekme veya grup olarak.\n\t\t\t\t\t\t* 'value': Kaç tane pozisyonun taşınacağını belirten sayı değeri.\n\t\t\t\t\t", + "commandDeprecated": "**{0}** komutu kaldırıldı. Onun yerine **{1}** komutunu kullanabilirsiniz", + "openKeybindings": "Klavye Kısayollarını Yapılandır" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/editor/editorPart.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/editor/editorPart.i18n.json new file mode 100644 index 00000000000..11fc7d29941 --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/editor/editorPart.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "groupOneVertical": "Sol", + "groupTwoVertical": "Orta", + "groupThreeVertical": "Sağ", + "groupOneHorizontal": "En Üst", + "groupTwoHorizontal": "Orta", + "groupThreeHorizontal": "En Alt", + "editorOpenError": "'{0}' açılamadı: {1}." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/editor/editorPicker.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/editor/editorPicker.i18n.json new file mode 100644 index 00000000000..3f3f3b4d538 --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/editor/editorPicker.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, düzenleyici grubu seçici", + "groupLabel": "Grup: {0}", + "noResultsFoundInGroup": "Grupta eşleşen açık düzenleyici bulunamadı", + "noOpenedEditors": "Gruptaki açık düzenleyiciler listesi şu an boş", + "noResultsFound": "Eşleşen açık düzenleyici bulunamadı", + "noOpenedEditorsAllGroups": "Açık düzenleyiciler listesi şu an boş" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json new file mode 100644 index 00000000000..d03a6b69b6a --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/editor/editorStatus.i18n.json @@ -0,0 +1,51 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "singleSelectionRange": "Sat {0}, Süt {1} ({2} seçili)", + "singleSelection": "Sat {0}, Süt {1}", + "multiSelectionRange": "{0} seçim ({1} karakter seçildi)", + "multiSelection": "{0} seçim", + "endOfLineLineFeed": "LF", + "endOfLineCarriageReturnLineFeed": "CRLF", + "tabFocusModeEnabled": "Tab Odak Değiştirir", + "screenReaderDetected": "Ekran Okuyucu Algılandı", + "screenReaderDetectedExtra": "Bir Ekran Okuyucu kullanmıyorsanız, lütfen `editor.accessibilitySupport` ayarını \"off\" olarak değiştirin", + "disableTabMode": "Erişilebilirlik Modunu Devre Dışı Bırak", + "gotoLine": "Satıra Git", + "indentation": "Girinti", + "selectEncoding": "Kodlamayı Seç", + "selectEOL": "Satır Sonu Sıralamasını Seç", + "selectLanguageMode": "Dil Modunu Seçin", + "fileInfo": "Dosya Bilgisi", + "spacesSize": "Boşluk: {0}", + "tabSize": "Sekme Boyutu: {0}", + "showLanguageExtensions": "'{0}' için Market Eklentilerini Ara...", + "changeMode": "Dil Modunu Değiştir", + "noEditor": "Şu an aktif metin düzenleyici yok", + "languageDescription": "({0}) - Yapılandırılan Dil", + "languageDescriptionConfigured": "({0})", + "languagesPicks": "diller (tanımlayıcı)", + "configureModeSettings": "'{0}' dili tabanlı ayarları yapılandır...", + "configureAssociationsExt": "'{0}' için Dosya İlişkilendirmesini Yapılandır...", + "autoDetect": "Otomatik Algıla", + "pickLanguage": "Dil Modunu Seçin", + "currentAssociation": "Geçerli İlişkilendirme", + "pickLanguageToConfigure": " '{0}' ile İlişkilendirilecek Dil Modunu Seçin", + "changeIndentation": "Girintiyi Değiştir", + "noWritableCodeEditor": "Aktif kod düzenleyici salt okunur.", + "indentView": "görünümü değiştir", + "indentConvert": "dosyayı dönüştür", + "pickAction": "Eylem Seçin", + "changeEndOfLine": "Satır Sonu Sıralamasını Değiştir", + "pickEndOfLine": "Satır Sonu Sıralamasını Seç", + "changeEncoding": "Dosya Kodlamasını Değiştir", + "noFileEditor": "Şu an aktif dosya yok", + "saveWithEncoding": "Kodlama ile Kaydet", + "reopenWithEncoding": "Kodlama ile Yeniden Aç", + "guessedEncoding": "İçerikten tahmin edildi", + "pickEncodingForReopen": "Dosyayı Yeniden Açmak İçin Dosya Kodlaması Seçin", + "pickEncodingForSave": "Kaydedilecek Dosya Kodlamasını Seçin" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/editor/tabsTitleControl.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/editor/tabsTitleControl.i18n.json new file mode 100644 index 00000000000..43199d98868 --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/editor/tabsTitleControl.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "araLabelTabActions": "Sekme eylemleri" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/editor/textDiffEditor.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/editor/textDiffEditor.i18n.json new file mode 100644 index 00000000000..9fb7a026e34 --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/editor/textDiffEditor.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "textDiffEditor": "Metin Diff Düzenleyicisi", + "readonlyEditorWithInputAriaLabel": "{0}. Salt okunur metin dosyası karşılaştırma düzenleyicisi.", + "readonlyEditorAriaLabel": "Salt okunur metin dosyası karşılaştırma düzenleyicisi.", + "editableEditorWithInputAriaLabel": "{0}. Metin dosyası karşılaştırma düzenleyicisi.", + "editableEditorAriaLabel": "Metin dosyası karşılaştırma düzenleyicisi.", + "navigate.next.label": "Sonraki Değişiklik", + "navigate.prev.label": "Önceki Değişiklik", + "inlineDiffLabel": "Satır İçi Görünüme Geç", + "sideBySideDiffLabel": "Yan Yana Görünüme Geç" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/editor/textEditor.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/editor/textEditor.i18n.json new file mode 100644 index 00000000000..01f8e840c01 --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/editor/textEditor.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorLabelWithGroup": "{0}, Grup {1}." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/editor/textResourceEditor.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/editor/textResourceEditor.i18n.json new file mode 100644 index 00000000000..0b047605199 --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/editor/textResourceEditor.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "textEditor": "Metin Düzenleyicisi", + "readonlyEditorWithInputAriaLabel": "{0}. Salt okunur metin düzenleyici.", + "readonlyEditorAriaLabel": "Salt okunur metin düzenleyici.", + "untitledFileEditorWithInputAriaLabel": "{0}. İsimsiz dosya metin düzenleyici.", + "untitledFileEditorAriaLabel": "İsimsiz dosya metin düzenleyici." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/editor/titleControl.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/editor/titleControl.i18n.json new file mode 100644 index 00000000000..18e318decfd --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/editor/titleControl.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "close": "Kapat", + "closeOthers": "Diğerlerini Kapat", + "closeRight": "Sağdakileri Kapat", + "closeAll": "Tümünü Kapat", + "closeAllUnmodified": "Değiştirilmeyenleri Kapat", + "keepOpen": "Açık Tut", + "showOpenedEditors": "Açık Düzenleyicileri Göster", + "araLabelEditorActions": "Düzenleyici eylemleri" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/panel/panelActions.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/panel/panelActions.i18n.json new file mode 100644 index 00000000000..82be0726e3e --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/panel/panelActions.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "panelActionTooltip": "{0} ({1})", + "closePanel": "Paneli Kapat", + "togglePanel": "Paneli Aç/Kapat", + "focusPanel": "Panele Odakla", + "toggleMaximizedPanel": "Panelin Ekranı Kaplamasını Aç/Kapat", + "maximizePanel": "Panel Boyutunu Olabildiğince Genişlet", + "minimizePanel": "Panel Boyutunu Geri Al", + "view": "Görüntüle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/panel/panelPart.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/panel/panelPart.i18n.json new file mode 100644 index 00000000000..de9c6eaf586 --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/panel/panelPart.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "panelSwitcherBarAriaLabel": "Aktif Panel Değiştirici" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/quickopen/quickOpenController.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/quickopen/quickOpenController.i18n.json new file mode 100644 index 00000000000..8f88539a56e --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/quickopen/quickOpenController.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "inputModeEntryDescription": "{0} (Onaylamak için 'Enter' veya iptal etmek için 'Escape' tuşuna basın)", + "inputModeEntry": "Girdinizi onaylamak için 'Enter' veya iptal etmek için 'Escape' tuşuna basın", + "emptyPicks": "Seçilecek girdi yok", + "quickOpenInput": "Buradan gerçekleştirebileceğiniz eylemler hakkında yardım almak için '?' yazın", + "historyMatches": "yakınlarda açıldı", + "noResultsFound1": "Sonuç bulunamadı", + "canNotRunPlaceholder": "Bu hızlı açma işleyicisi geçerli bağlamda kullanılamaz", + "entryAriaLabel": "{0}, yakınlarda açıldı", + "removeFromEditorHistory": "Geçmişten Kaldır", + "pickHistory": "Geçmişten kaldırmak için bir düzenleyici girdisi seçin" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json new file mode 100644 index 00000000000..e6b6bd07b2f --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/quickopen/quickopen.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "quickOpen": "Dosyaya Git...", + "quickNavigateNext": "Hızlı Açta Sonrakine Git", + "quickNavigatePrevious": "Hızlı Açta Öncekine Git", + "quickSelectNext": "Hızlı Açta Sonrakini Seç", + "quickSelectPrevious": "Hızlı Açta Öncekini Seç" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/sidebar/sidebarPart.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/sidebar/sidebarPart.i18n.json new file mode 100644 index 00000000000..3ad0767c121 --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/sidebar/sidebarPart.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "focusSideBar": "Kenar Çubuğuna Odakla", + "viewCategory": "Görüntüle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/statusbar/statusbarPart.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/statusbar/statusbarPart.i18n.json new file mode 100644 index 00000000000..ea87cdb6229 --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/statusbar/statusbarPart.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "canNotRun": "'{0}' komutu şu an etkin değildir ve çalıştırılamaz.", + "manageExtension": "Eklentiyi Yönet" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/parts/titlebar/titlebarPart.i18n.json b/i18n/trk/src/vs/workbench/browser/parts/titlebar/titlebarPart.i18n.json new file mode 100644 index 00000000000..f143e04de94 --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/parts/titlebar/titlebarPart.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "patchedWindowTitle": "[Desteklenmiyor]", + "devExtensionWindowTitlePrefix": "[Eklenti Geliştirme Sunucusu]" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/quickopen.i18n.json b/i18n/trk/src/vs/workbench/browser/quickopen.i18n.json new file mode 100644 index 00000000000..a0b7b06168e --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/quickopen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noResultsMatching": "Eşleşen sonuç yok", + "noResultsFound2": "Sonuç bulunamadı", + "entryAriaLabel": "{0}, komut" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/browser/viewlet.i18n.json b/i18n/trk/src/vs/workbench/browser/viewlet.i18n.json new file mode 100644 index 00000000000..0d41777aa74 --- /dev/null +++ b/i18n/trk/src/vs/workbench/browser/viewlet.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "collapse": "Tümünü Daralt" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/common/theme.i18n.json b/i18n/trk/src/vs/workbench/common/theme.i18n.json new file mode 100644 index 00000000000..3c854c09486 --- /dev/null +++ b/i18n/trk/src/vs/workbench/common/theme.i18n.json @@ -0,0 +1,61 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tabActiveBackground": "Aktif sekme arka plan rengi. Sekmeler, düzenleyici alanındaki düzenleyicilerin kapsayıcılarıdır. Bir düzenleyici grubunda birden fazla sekme açılabilir. Birden fazla düzenleyici grupları var olabilir.", + "tabInactiveBackground": "Pasif sekme arka plan rengi. Sekmeler, düzenleyici alanındaki düzenleyicilerin kapsayıcılarıdır. Bir düzenleyici grubunda birden fazla sekme açılabilir. Birden fazla düzenleyici grupları var olabilir.", + "tabBorder": "Sekmeleri birbirinden ayıran kenarlığın rengi. Sekmeler, düzenleyici alanındaki düzenleyicilerin kapsayıcılarıdır. Bir düzenleyici grubunda birden fazla sekme açılabilir. Birden fazla düzenleyici grupları var olabilir.", + "tabActiveForeground": "Aktif bir gruptaki aktif sekmenin ön plan rengi. Sekmeler, düzenleyici alanındaki düzenleyicilerin kapsayıcılarıdır. Bir düzenleyici grubunda birden fazla sekme açılabilir. Birden fazla düzenleyici grupları var olabilir.", + "tabInactiveForeground": "Aktif bir gruptaki pasif sekmenin ön plan rengi. Sekmeler, düzenleyici alanındaki düzenleyicilerin kapsayıcılarıdır. Bir düzenleyici grubunda birden fazla sekme açılabilir. Birden fazla düzenleyici grupları var olabilir.", + "tabUnfocusedActiveForeground": "Pasif bir gruptaki aktif sekmenin ön plan rengi. Sekmeler, düzenleyici alanındaki düzenleyicilerin kapsayıcılarıdır. Bir düzenleyici grubunda birden fazla sekme açılabilir. Birden fazla düzenleyici grupları var olabilir.", + "tabUnfocusedInactiveForeground": "Pasif bir gruptaki pasif sekmenin ön plan rengi. Sekmeler, düzenleyici alanındaki düzenleyicilerin kapsayıcılarıdır. Bir düzenleyici grubunda birden fazla sekme açılabilir. Birden fazla düzenleyici grupları var olabilir.", + "editorGroupBackground": "Bir düzenleyici grubunun arka plan rengi. Düzenleyici grupları, düzenleyicilerin kapsayıcılarıdır. Arka plan rengi, düzenleyici grubunu sürüklerken gösterilir.", + "tabsContainerBackground": "Sekmeler etkinleştirilmiş durumdayken, düzenleyici grubu başlık üstbilgisi arka plan rengi. Düzenleyici grupları, düzenleyicilerin kapsayıcılarıdır. ", + "tabsContainerBorder": "Sekmeler etkinleştirilmiş durumdayken, düzenleyici grubu başlık üstbilgisi kenarlık rengi. Düzenleyici grupları, düzenleyicilerin kapsayıcılarıdır. ", + "editorGroupHeaderBackground": "Sekmeler devre dışı iken, düzenleyici grubu başlık üstbilgisi arka plan rengi. Düzenleyici grupları, düzenleyicilerin kapsayıcılarıdır. ", + "editorGroupBorder": "Birden fazla düzenleyici grubunu birbirinden ayıracak renk. Düzenleyici grupları, düzenleyicilerin kapsayıcılarıdır. ", + "editorDragAndDropBackground": "Düzenleyici grubunu sürüklerken gösterilecek arka plan rengi. Düzenleyici içeriğinin hâlâ iyi görünmeye devam edebilmesi için renk şeffaf olmalıdır.", + "panelBackground": "Panel arka plan rengi. Paneller düzenleyici alanının altında gösterilir ve çıktı ve entegre terminal gibi görünümler içerir.", + "panelBorder": "Paneli düzenleyiciden ayıran üstteki kenarlık rengi. Paneller düzenleyici alanının altında gösterilir ve çıktı ve entegre terminal gibi görünümler içerir.", + "panelActiveTitleForeground": "Aktif panelin başlık rengi. Paneller düzenleyici alanının altında gösterilir ve çıktı ve entegre terminal gibi görünümler içerir.", + "panelInactiveTitleForeground": "Pasif panelin başlık rengi. Paneller düzenleyici alanının altında gösterilir ve çıktı ve entegre terminal gibi görünümler içerir.", + "panelActiveTitleBorder": "Aktif başlığının kenarlık rengi. Paneller düzenleyici alanının altında gösterilir ve çıktı ve entegre terminal gibi görünümler içerir.", + "statusBarForeground": "Durum çubuğu ön plan rengi. Durum çubuğu, pencerenin alt kısmında gösterilir.", + "statusBarBackground": "Standart durum çubuğu arka plan rengi. Durum çubuğu, pencerenin alt kısmında gösterilir.", + "statusBarBorder": "Durum çubuğunu kenar çubuğundan ve düzenleyiciden ayıran kenarlık rengi. Durum çubuğu, pencerenin alt kısmında gösterilir.", + "statusBarNoFolderBackground": "Hiçbir klasör açık değilken durum çubuğu arka plan rengi. Durum çubuğu, pencerenin alt kısmında gösterilir.", + "statusBarNoFolderForeground": "Hiçbir klasör açık değilken durum çubuğu ön plan rengi. Durum çubuğu, pencerenin alt kısmında gösterilir.", + "statusBarItemActiveBackground": "Durum çubuğu ögesi tıklanırken arka plan rengi. Durum çubuğu, pencerenin alt kısmında gösterilir.", + "statusBarItemHoverBackground": "Durum çubuğu ögesinin mouse ile üzerine gelindiğindeki arka plan rengi. Durum çubuğu, pencerenin alt kısmında gösterilir.", + "statusBarProminentItemBackground": "Durum çubuğu belirgin ögelerinin arka plan rengi. Belirgin ögeler, önemi belirtmek için diğer durum çubuğu girdilerinden öne çıkarılır. Durum çubuğu, pencerenin alt kısmında gösterilir.", + "statusBarProminentItemHoverBackground": "Durum çubuğu belirgin ögelerinin mouse ile üzerine gelindiğindeki arka plan rengi. Belirgin ögeler, önemi belirtmek için diğer durum çubuğu girdilerinden öne çıkarılır. Durum çubuğu, pencerenin alt kısmında gösterilir.", + "activityBarBackground": "Etkinlik çubuğu arka plan rengi. Etkinlik çubuğu, en sol veya en sağda gösterilir ve kenar çubuğunun görünümleriyle yer değiştirmeye izin verir.", + "activityBarForeground": "Etkinlik çubuğu ön plan rengi (ör. simgeler için kullanılır). Etkinlik çubuğu, en sol veya en sağda gösterilir ve kenar çubuğunun görünümleriyle yer değiştirmeye izin verir.", + "activityBarBorder": "Etkinlik çubuğunu kenar çubuğundan ayıran kenarlığın rengi. Etkinlik çubuğu, en sol veya en sağda gösterilir ve kenar çubuğunun görünümleriyle yer değiştirmeye izin verir.", + "activityBarDragAndDropBackground": "Etkinlik çubuğu ögeleri için sürükle bırak geri bildirim rengi. Etkinlik çubuğu girdilerinin hâlâ iyi görünmeye devam edebilmesi için renk şeffaf olmalıdır. Etkinlik çubuğu, en sol veya en sağda gösterilir ve kenar çubuğunun görünümleriyle yer değiştirmeye izin verir.", + "activityBarBadgeBackground": "Etkinlik çubuğu bildirim göstergesi arka plan rengi. Etkinlik çubuğu, en sol veya en sağda gösterilir ve kenar çubuğunun görünümleriyle yer değiştirmeye izin verir.", + "activityBarBadgeForeground": "Etkinlik çubuğu bildirim göstergesi ön plan rengi. Etkinlik çubuğu, en sol veya en sağda gösterilir ve kenar çubuğunun görünümleriyle yer değiştirmeye izin verir.", + "sideBarBackground": "Kenar çubuğu arka plan rengi. Kenar çubuğu, gezgin ve arama gibi görünümlerin kapsayıcısıdır.", + "sideBarForeground": "Kenar çubuğu ön plan rengi. Kenar çubuğu, gezgin ve arama gibi görünümlerin kapsayıcısıdır.", + "sideBarBorder": "Kenar çubuğunu düzenleyiciden ayıran taraftaki kenarlığın rengi. Kenar çubuğu, gezgin ve arama gibi görünümlerin kapsayıcısıdır.", + "sideBarTitleForeground": "Kenar çubuğu başlığı ön plan rengi. Kenar çubuğu, gezgin ve arama gibi görünümlerin kapsayıcısıdır.", + "sideBarSectionHeaderBackground": "Kenar çubuğu bölüm başlığı arka plan rengi. Kenar çubuğu, gezgin ve arama gibi görünümlerin kapsayıcısıdır.", + "sideBarSectionHeaderForeground": "Kenar çubuğu bölüm başlığı ön plan rengi. Kenar çubuğu, gezgin ve arama gibi görünümlerin kapsayıcısıdır.", + "titleBarActiveForeground": "Pencere aktifken başlık çubuğu ön planı. Bu rengin sadece macOS'da destekleneceğini unutmayın.", + "titleBarInactiveForeground": "Pencere pasifken başlık çubuğu ön planı. Bu rengin sadece macOS'da destekleneceğini unutmayın.", + "titleBarActiveBackground": "Pencere aktifken başlık çubuğu arka planı. Bu rengin sadece macOS'da destekleneceğini unutmayın.", + "titleBarInactiveBackground": "Pencere pasifken başlık çubuğu arka planı. Bu rengin sadece macOS'da destekleneceğini unutmayın.", + "notificationsForeground": "Bildirim ön plan rengi. Bildirimler pencerenin üst kısmından içeri girer.", + "notificationsBackground": "Bildirim arka plan rengi. Bildirimler pencerenin üst kısmından içeri girer.", + "notificationsButtonBackground": "Bildirim butonu arka plan rengi. Bildirimler pencerenin üst kısmından içeri girer.", + "notificationsButtonHoverBackground": "Fareyle üzerine gelindiğinde bildirim butonu arka plan rengi. Bildirimler pencerenin üst kısmından içeri girer.", + "notificationsButtonForeground": "Bildirim butonu ön plan rengi. Bildirimler pencerenin üst kısmından içeri girer.", + "notificationsInfoBackground": "Bildirimlerdeki bilgi arka plan rengi. Bildirimler pencerenin üst kısmından içeri girer.", + "notificationsInfoForeground": "Bildirimlerdeki bilgi ön plan rengi. Bildirimler pencerenin üst kısmından içeri girer.", + "notificationsWarningBackground": "Bildirim uyarı arka plan rengi. Bildirimler pencerenin üst kısmından içeri girer.", + "notificationsWarningForeground": "Bildirim uyarı ön plan rengi. Bildirimler pencerenin üst kısmından içeri girer.", + "notificationsErrorBackground": "Bildirim hata arka plan rengi. Bildirimler pencerenin üst kısmından içeri girer.", + "notificationsErrorForeground": "Bildirim hata ön plan rengi. Bildirimler pencerenin üst kısmından içeri girer." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/electron-browser/actions.i18n.json b/i18n/trk/src/vs/workbench/electron-browser/actions.i18n.json new file mode 100644 index 00000000000..f4317c69378 --- /dev/null +++ b/i18n/trk/src/vs/workbench/electron-browser/actions.i18n.json @@ -0,0 +1,43 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "closeActiveEditor": "Düzenleyiciyi Kapat", + "closeWindow": "Pencereyi Kapat", + "closeFolder": "Klasörü Kapat", + "noFolderOpened": "Şu an bu örnekte kapatmak için açık bir klasör bulunmuyor.", + "newWindow": "Yeni Pencere", + "toggleFullScreen": "Tam Ekranı Aç/Kapat", + "toggleMenuBar": "Menü Çubuğunu Gizle/Göster", + "toggleDevTools": "Geliştirici Araçlarını Aç/Kapat", + "zoomIn": "Yakınlaştır", + "zoomOut": "Uzaklaştır", + "zoomReset": "Yakınlaştırmayı Sıfırla", + "appPerf": "Başlangıç Performansı", + "reloadWindow": "Pencereyi Yeniden Yükle", + "switchWindowPlaceHolder": "Geçilecek pencereyi seçin", + "current": "Geçerli Pencere", + "switchWindow": "Pencere Değiştir...", + "quickSwitchWindow": "Hızlı Pencere Değiştir...", + "folders": "klasörler", + "files": "dosyalar", + "openRecentPlaceHolderMac": "Bir yol seçin (yeni pencerede açmak için Cmd tuşunu basılı tutun)", + "openRecentPlaceHolder": "Açılacak yolu seçin (yeni pencerede açmak için Ctrl tuşunu basılı tutun)", + "openRecent": "Son Kullanılanları Aç...", + "quickOpenRecent": "Son Kullanılanları Hızlı Aç...", + "closeMessages": "Bildirim İletilerini Kapat", + "reportIssues": "Sorunları Bildir", + "reportPerformanceIssue": "Performans Sorunu Bildir", + "keybindingsReference": "Klavye Kısayolları Başvurusu", + "openDocumentationUrl": "Belgeler", + "openIntroductoryVideosUrl": "Tanıtım Videoları", + "toggleSharedProcess": "Paylaşılan İşlemi Göster/Gizle", + "navigateLeft": "Soldaki Görünüme Git", + "navigateRight": "Sağdaki Görünüme Git", + "navigateUp": "Üstteki Görünüme Git", + "navigateDown": "Alttaki Görünüme Git", + "increaseViewSize": "Geçerli Görünüm Boyutunu Artır", + "decreaseViewSize": "Geçerli Görünüm Boyutunu Azalt" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/electron-browser/commands.i18n.json b/i18n/trk/src/vs/workbench/electron-browser/commands.i18n.json new file mode 100644 index 00000000000..3a1051dcfda --- /dev/null +++ b/i18n/trk/src/vs/workbench/electron-browser/commands.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "diffLeftRightLabel": "{0} ⟷ {1}" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/electron-browser/extensionHost.i18n.json b/i18n/trk/src/vs/workbench/electron-browser/extensionHost.i18n.json new file mode 100644 index 00000000000..b13594b9af6 --- /dev/null +++ b/i18n/trk/src/vs/workbench/electron-browser/extensionHost.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "extensionHostProcess.startupFailDebug": "Eklenti sunucusu 10 saniye içinde başlamadı, ilk satırda durdurulmuş olabilir ve devam etmesi için bir hata ayıklayıcıya ihtiyacı olabilir.", + "extensionHostProcess.startupFail": "Eklenti sunucusu 10 saniye içinde başlamadı, bu bir sorun olabilir.", + "extensionHostProcess.error": "Eklenti sunucusundan hata: {0}", + "extensionHostProcess.crash": "Eklenti sunucusu beklenmeyen biçimde sonlandırıldı. Lütfen kurtarmak için pencereyi yeniden yükleyin." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/electron-browser/main.contribution.i18n.json b/i18n/trk/src/vs/workbench/electron-browser/main.contribution.i18n.json new file mode 100644 index 00000000000..aaf704581b1 --- /dev/null +++ b/i18n/trk/src/vs/workbench/electron-browser/main.contribution.i18n.json @@ -0,0 +1,69 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "view": "Görüntüle", + "help": "Yardım", + "file": "Dosya", + "developer": "Geliştirici", + "showEditorTabs": "Açık düzenleyicilerin sekmelerde gösterilip gösterilmeyeceğini denetler", + "editorTabCloseButton": "Düzenleyici sekmelerinin kapat butonlarının konumunu denetler veya 'off' olarak ayarlandığında devre dışı bırakır.", + "showIcons": "Açık düzenleyicilerin bir simge ile gösterilip gösterilmemelerini denetler. Bu, bir simge temasının etkinleştirilmesini de gerektirir.", + "enablePreview": "Açık düzenleyicilerin önizleme olarak gösterilip gösterilmeyeceğini denetler. Önizleme düzenleyicileri kalıcı olarak açılana kadar (ör. çift tıklama veya düzenleme ile) tekrar kullanılırlar.", + "enablePreviewFromQuickOpen": "Hızlı Aç'taki açık düzenleyicilerin önizleme olarak gösterilip gösterilmeyeceğini denetler. Önizleme düzenleyicileri kalıcı olarak açılana kadar (ör. çift tıklama veya düzenleme ile) tekrar kullanılırlar.", + "editorOpenPositioning": "Düzenleyicilerin nerede açılacağını denetler. Düzenleyicileri, geçerli olanın soluna veya sağına açmak için 'left' veya 'right' seçeneklerinden birini seçin. Düzenleyicileri, geçerli olandan bağımsız bir şekilde açmak için 'first' veya 'last' seçeneklerinden birini seçin.", + "revealIfOpen": "Düzenleyicinin görünen gruplardan herhangi birinde açıldıysa ortaya çıkarılıp çıkarılmayacağını denetler. Devre dışı bırakılırsa; bir düzenleyici, o an aktif düzenleyici grubunda açılmayı tercih edecektir. Etkinleştirilirse; o an aktif düzenleyici grubunda tekrar açılmak yerine, zaten açık olan düzenleyici ortaya çıkarılacaktır. Bu ayarın yok sayılacağı bazı durumların olduğunu unutmayın, ör. bir düzenleyiciyi, belirli bir grupta veya o an aktif grubun yanına açmaya zorladığınızda. ", + "commandHistory": "Komut paleti geçmişinde tutulacak son kullanılan komutların sayısını denetler. Komut geçmişini kapatmak için 0 olarak ayarlayın.", + "preserveInput": "Komut paletine son girilen girdinin, bir sonraki açılışta tekrar yer alıp almayacağını denetler.", + "closeOnFocusLost": "Hızlı Aç'ın odağını kaybettiğinde otomatik olarak kapanıp kapanmayacağını denetler.", + "openDefaultSettings": "Ayarları açmanın ayrıca tüm varsayılan ayarları gösteren bir düzenleyici açıp açmayacağını denetler.", + "sideBarLocation": "Kenar çubuğunun konumunu denetler. Çalışma ekranının ya solunda ya da sağında gösterilebilir.", + "statusBarVisibility": "Çalışma ekranının altındaki durum çubuğunun görünürlüğünü denetler.", + "activityBarVisibility": "Çalışma ekranındaki etkinlik çubuğunun görünürlüğünü denetler.", + "closeOnFileDelete": "Düzenleyicinin gösterdiği bir dosyanın, başka bir işlem tarafından silinmesi veya yeniden adlandırması durumunda dosyayı otomatik olarak kapatıp kapatmamasını denetler. Bunu devre dışı bırakmak, böyle bir durumda düzenleyicinin kaydedilmemiş değişiklikler içeriyor durumunda kalmasını sağlar. Uygulama içinde silmek, düzenleyiciyi her zaman kapatır ve kaydedilmemiş değişiklikler içeren dosyalar, verilerinizin korunması için otomatik olarak kapatılmaz.", + "swipeToNavigate": "Yatay olarak üç parmakla kaydırma ile açık dosyalar arasında gezinin.", + "workbenchConfigurationTitle": "Çalışma Ekranı", + "window.openFilesInNewWindow.on": "Dosyalar yeni bir pencerede açılacak", + "window.openFilesInNewWindow.off": "Dosyalar, dosyaların klasörünün olduğu pencerede veya son aktif pencerede açılacak", + "window.openFilesInNewWindow.default": "Dosyalar, Dock veya Finder ile açılmadıkça (sadece macOS için) dosyaların klasörünün olduğu pencerede veya son aktif pencerede açılacak", + "openFilesInNewWindow": "Dosyaların yeni bir pencerede açılıp açılmayacağını denetler.\n- default: dosyalar, Dock veya Finder ile açılmadıkça (sadece macOS için) dosyaların klasörünün olduğu pencerede veya son aktif pencerede açılacak\n- on: dosyalar yeni bir pencerede açılacak\n- off: dosyalar, dosyaların klasörünün olduğu pencerede veya son aktif pencerede açılacak\nBu ayarın halen yok sayılacağı durumlar olabilir (ör. -new-window veya -reuse-window komut satırı seçenekleri kullanılırken).", + "window.openFoldersInNewWindow.on": "Klasörler yeni bir pencerede açılacak", + "window.openFoldersInNewWindow.off": "Klasörler son aktif pencereyi değiştirir", + "window.openFoldersInNewWindow.default": "Klasörler, bir klasör uygulama içinden seçilmedikçe (ör. Dosya menüsünden) yeni bir pencerede açılır", + "openFoldersInNewWindow": "Klasörlerin yeni bir pencerede mi açılacağını yoksa son aktif pencereyi mi değiştireceğini denetler.\n- default: klasörler, bir klasör uygulama içinden seçilmedikçe (ör. Dosya menüsünden) yeni bir pencerede açılır\n- on: klasörler yeni bir pencerede açılır\n- off: klasörler son aktif pencereyi değiştirir\nBu ayarın halen yok sayılacağı durumlar olabilir (ör. -new-window veya -reuse-window komut satırı seçenekleri kullanılırken).", + "window.reopenFolders.all": "Tüm pencereleri yeniden aç.", + "window.reopenFolders.folders": "Tüm klasörleri yeniden aç. Boş pencereler eski haline dönmeyecektir.", + "window.reopenFolders.one": "Son aktif pencereyi yeniden aç.", + "window.reopenFolders.none": "Asla bir pencereyi yeniden açma. Her zaman boş bir pencereyle başla.", + "restoreWindows": "Pencerelerin, bir yeniden başlatma sonrası nasıl yeniden açılacağını denetler. Her zaman boş bir pencere ile başlamak için 'none', üzerinde çalıştığınız son pencereyi yeniden açmak için 'one', açık olan tüm klasörleri yeniden açmak için 'folders' veya son oturumunuzdaki tüm pencereleri yeniden açmak için 'all' seçeneğini seçin.", + "restoreFullscreen": "Bir pencere tam ekran modundayken çıkıldıysa, bu pencerenin tam ekran moduna geri dönüp dönmeyeceğini denetler.", + "zoomLevel": "Pencerenin yakınlaştırma düzeyini ayarlayın. Orijinal boyut 0'dır ve üstündeki (ör. 1) veya altındaki (ör. -1) her artırma 20% daha fazla veya az yakınlaştırmayı temsil eder. Yakınlaştırma düzeyini daha ince ayrıntılarla ayarlamak için ondalık değerler de girebilirsiniz.", + "title": "Pencere başlığını aktif düzenleyiciye bağlı olarak denetler. Değişkenler, bağlama göre değiştirilir:\n${activeEditorShort}: ör. myFile.txt\n${activeEditorMedium}: ör. myFolder/myFile.txt\n${activeEditorLong}: ör. /Users/Development/myProject/myFolder/myFile.txt\n${rootName}: ör. myProject\n${rootPath}: ör. /Users/Development/myProject\n${appName}: ör. VS Code\n${dirty}: değişiklik göstergesi, eğer aktif düzenleyici kaydedilmemiş değişiklikler içeriyorsa\n${separator}: şartlı ayırıcı (\" - \") yalnızca değer içeren değişkenlerle çevrili olduğunda gösterilir", + "window.newWindowDimensions.default": "Yeni pencereleri ekranın ortasında açın.", + "window.newWindowDimensions.inherit": "Yeni pencereleri son aktif pencere ile aynı ölçülerde açın.", + "window.newWindowDimensions.maximized": "Yeni pencereleri ekranı kapla modunda açın.", + "window.newWindowDimensions.fullscreen": "Yeni pencereleri tam ekran modunda açın.", + "newWindowDimensions": "En az bir pencere açıkken, açılacak yeni bir pencerenin boyutlarını denetler. Varsayılan olarak; yeni pencere ekranın ortasında küçük bir boyutta açılır. 'inherit' olarak ayarlandığında, pencere aktif olan son pencere ile aynı boyutları alacaktır. 'maximized' olarak ayarlandığında, ekranı kaplar biçimde açılır ve 'fullscreen' olarak yapılandırılmışsa, tam ekran olarak açılır. Bu ayarın açılan ilk pencere üzerinde bir etkisi olmadığını unutmayın. İlk pencere, daima boyutunu ve konumunu kapanmadan önce bıraktığınız şekilde geri yükler.", + "window.menuBarVisibility.default": "Menü, sadece tam ekran modunda gizlenir.", + "window.menuBarVisibility.visible": "Menü, tam ekran modunda bile daima görünür.", + "window.menuBarVisibility.toggle": "Menü gizlidir, fakat Alt tuşuyla görüntülenebilir.", + "window.menuBarVisibility.hidden": "Menü daima gizlidir.", + "menuBarVisibility": "Menü çubuğunun gizliliğini denetleyin. 'toggle' ayarı, menü çubuğu gizlidir ve Alt tuşuna bir kez basıldığında gösterilir anlamına gelir. Varsayılan olarak; menü çubuğu, pencere tam ekran değilse görünür durumdadır.", + "enableMenuBarMnemonics": "Etkinleştirilirse, ana menüler Alt tuşu kısayollarıyla açılabilir. Anımsatıcıları devre dışı bırakmak, bu Alt tuşu kısayollarının düzenleyici komutlarının yerine kullanılmasını sağlar.", + "autoDetectHighContrast": "Etkinleştirilirse; eğer Windows bir yüksek karşıtlık teması kullanıyorsa, otomatik olarak yüksek karşıtlık temasına geçiş yapılır; ve Windows, yüksek karşıtlık temasını kullanmayı bıraktığında koyu temaya geçiş yapılır.", + "titleBarStyle": "Pencere başlık çubuğunun görünümünü ayarlayın. Değişikliklerin uygulanması için tam yeniden başlatma gerekir.", + "window.nativeTabs": "macOS Sierra pencere sekmelerini etkinleştirir. Değişikliklerin uygulanması için tam yeniden başlatma gerekeceğini ve yerel sekmelerin, eğer yapılandırılmışsa özel başlık çubuğu stilini devre dışı bıracağını unutmayın.", + "windowConfigurationTitle": "Pencere", + "zenModeConfigurationTitle": "Zen Modu", + "zenMode.fullScreen": "Zen Moduna geçmenin ayrıca çalışma ekranını tam ekran moduna geçirip geçirmeyeceğini denetler.", + "zenMode.hideTabs": "Zen Moduna geçmenin ayrıca çalışma ekranı sekmelerini gizleyip gizlemeyeceğini denetler.", + "zenMode.hideStatusBar": "Zen Moduna geçmenin ayrıca çalışma ekranının altındaki durum çubuğunu gizleyip gizlemeyeceğini denetler.", + "zenMode.hideActivityBar": "Zen Moduna geçmenin ayrıca çalışma ekranının solundaki etkinlik çubuğunu gizleyip gizlemeyeceğini denetler.", + "zenMode.restore": "Bir pencere Zen modundayken çıkıldıysa, bu pencerenin Zen moduna geri dönüp dönmeyeceğini denetler.", + "workspaceConfigurationTitle": "Çalışma Alanı", + "workspaces.title": "Bu çalışma alanının klasör yapılandırması", + "files.exclude.boolean": "Dosya yollarının eşleştirileceği glob deseni. Deseni etkinleştirmek veya devre dışı bırakmak için true veya false olarak ayarlayın.", + "workspaces.additionalFolders": "Bu çalışma alanının klasörleri" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/electron-browser/main.i18n.json b/i18n/trk/src/vs/workbench/electron-browser/main.i18n.json new file mode 100644 index 00000000000..35eeb336c57 --- /dev/null +++ b/i18n/trk/src/vs/workbench/electron-browser/main.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "loaderError": "Gerekli bir dosya yüklenemedi. Artık İnternet'e bağlı değilsiniz veya bağlı olduğunuz sunucu çevrimdışı. Yeniden denemek için lütfen tarayıcıyı yenileyin.", + "loaderErrorNative": "Gerekli bir dosya yüklenemedi. Yeniden denemek için lütfen uygulamayı yeniden başlatın. Ayrıntılar: {0}" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/electron-browser/shell.i18n.json b/i18n/trk/src/vs/workbench/electron-browser/shell.i18n.json new file mode 100644 index 00000000000..ef01873077f --- /dev/null +++ b/i18n/trk/src/vs/workbench/electron-browser/shell.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "runningAsRoot": "Code'u 'root' olarak çalıştırmamanız önerilir." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/electron-browser/window.i18n.json b/i18n/trk/src/vs/workbench/electron-browser/window.i18n.json new file mode 100644 index 00000000000..b4855a5a6d2 --- /dev/null +++ b/i18n/trk/src/vs/workbench/electron-browser/window.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "undo": "Geri Al", + "redo": "Yinele", + "cut": "Kes", + "copy": "Kopyala", + "paste": "Yapıştır", + "selectAll": "Tümünü Seç", + "confirmOpen": "{0} klasörü açmak istediğinizden emin misiniz?", + "confirmOpenButton": "&&Aç" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/electron-browser/workbench.i18n.json b/i18n/trk/src/vs/workbench/electron-browser/workbench.i18n.json new file mode 100644 index 00000000000..d50ab8c8955 --- /dev/null +++ b/i18n/trk/src/vs/workbench/electron-browser/workbench.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "developer": "Geliştirici", + "file": "Dosya" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/node/extensionHostMain.i18n.json b/i18n/trk/src/vs/workbench/node/extensionHostMain.i18n.json new file mode 100644 index 00000000000..5c33200c410 --- /dev/null +++ b/i18n/trk/src/vs/workbench/node/extensionHostMain.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "extensionTestError": "{0} yolu, geçerli bir eklenti test çalıştırıcısına işaret etmiyor." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/node/extensionPoints.i18n.json b/i18n/trk/src/vs/workbench/node/extensionPoints.i18n.json new file mode 100644 index 00000000000..17cb5965e96 --- /dev/null +++ b/i18n/trk/src/vs/workbench/node/extensionPoints.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "jsonParseFail": "{0} ayrıştırılamadı: {1}.", + "fileReadFail": "{0} dosyası okunamadı: {1}.", + "jsonsParseFail": "{0} veya {1} ayrıştırılamadı: {2}.", + "missingNLSKey": "{0} anahtarı için mesaj bulunamadı." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/cli/electron-browser/cli.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/cli/electron-browser/cli.contribution.i18n.json new file mode 100644 index 00000000000..11fb1d3f1d6 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/cli/electron-browser/cli.contribution.i18n.json @@ -0,0 +1,18 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "install": "'{0}' kabuk komutunu PATH'e yükle", + "not available": "Bu komut mevcut değil", + "successIn": "'{0}' kabuk komutu PATH'e başarıyla yüklendi.", + "warnEscalation": "Code, şimdi kabuk komutunu yüklemek üzere yönetici ayrıcalıkları için 'osascript' ile izin isteyecektir.", + "ok": "Tamam", + "cantCreateBinFolder": "'/usr/local/bin' oluşturulamadı.", + "cancel2": "İptal", + "aborted": "Durduruldu", + "uninstall": "'{0}' kabuk komutunu PATH'den kaldır", + "successFrom": "'{0}' kabuk komutu PATH'den başarıyla kaldırıldı.", + "shellCommand": "Kabuk Komutu" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json b/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json new file mode 100644 index 00000000000..d8f733ac179 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/accessibility.i18n.json @@ -0,0 +1,26 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "emergencyConfOn": "Şu an `editor.accessibilitySupport` ayarı 'on' olarak değiştiriliyor.", + "openingDocs": "Şu an VS Code Erişilebilirlik döküman sayfası açılıyor.", + "introMsg": "VS Code'un erişilebilirlik seçeneklerini denediğiniz için teşekkür ederiz.", + "status": "Durum:", + "changeConfigToOnMac": "Düzenleyicinin kalıcı olarak bir Ekran Okuyucu ile kullanılmak üzere optimize edilmesini ayarlamak için Command+E tuşlarına basın.", + "changeConfigToOnWinLinux": "Düzenleyicinin kalıcı olarak bir Ekran Okuyucu ile kullanılmak üzere optimize edilmesini ayarlamak için Control+E tuşlarına basın.", + "auto_unknown": "Düzenleyici, bir Ekran Okuyucu'nun ne zaman bağlandığını algılamak için platform API'larını kullanmak üzere ayarlanmış, fakat geçerli çalışma zamanı bunu desteklemiyor.", + "auto_on": "Düzenleyici, bir Ekran Okuyucu'nun bağlandığını otomatik olarak algıladı.", + "auto_off": "Düzenleyici, bir Ekran Okuyucu'nun ne zaman bağlandığını otomatik olarak algılamak için yapılandırılmış, şu anki durum böyle değil.", + "configuredOn": "Düzenleyici kalıcı olarak bir Ekran Okuyucu ile kullanılmak üzere optimize edilmesi için yapılandırılmış - bunu, `editor.accessibilitySupport` ayarını düzenleyerek değiştirebilirsiniz.", + "configuredOff": "Düzenleyici hiçbir zaman bir Ekran Okuyucu ile kullanılmak üzere optimize edilmemesi için yapılandırılmış.", + "tabFocusModeOnMsg": "Geçerli düzenleyicide Tab tuşuna basmak odağı bir sonraki odaklanabilir ögeye kaydıracaktır. {0} tuşuna basarak bu davranışı açıp kapatın.", + "tabFocusModeOnMsgNoKb": "Geçerli düzenleyicide Tab tuşuna basmak odağı bir sonraki odaklanabilir ögeye kaydıracaktır. {0} komutu, şu an bir tuş bağı ile tetiklenemez.", + "tabFocusModeOffMsg": "Geçerli düzenleyicide Tab tuşuna basmak bir sekme karakteri ekleyecektir. {0} tuşuna basarak bu davranışı açıp kapatın.", + "tabFocusModeOffMsgNoKb": "Geçerli düzenleyicide Tab tuşuna basmak bir sekme karakteri ekleyecektir. {0} komutu, şu an bir tuş bağı ile tetiklenemez.", + "openDocMac": "Erişilebilirlik ile ilgili daha fazla VS Code bilgisi içeren bir tarayıcı penceresi açmak için Command+H tuşlarına basın.", + "openDocWinLinux": "Erişilebilirlik ile ilgili daha fazla VS Code bilgisi içeren bir tarayıcı penceresi açmak için Control+H tuşlarına basın.", + "outroMsg": "Escape veya Shift+Escape tuşlarına basarak bu ipucunu kapatabilir ve düzenleyiciye dönebilirsiniz.", + "ShowAccessibilityHelpAction": "Erişilebilirlik Yardımını Göster" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json b/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json new file mode 100644 index 00000000000..670ac261349 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/inspectKeybindings.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "workbench.action.inspectKeyMap": "Geliştirici: Tuş Eşlemelerini Denetle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json b/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json new file mode 100644 index 00000000000..8b6ad71cd4e --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/inspectTMScopes.i18n.json @@ -0,0 +1,6 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json b/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json new file mode 100644 index 00000000000..e65b16db179 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/toggleMultiCursorModifier.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleLocation": "Çoklu İmleç Değiştiricisini Aç/Kapat" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderControlCharacter.i18n.json b/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderControlCharacter.i18n.json new file mode 100644 index 00000000000..5c757ea1565 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderControlCharacter.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleRenderControlCharacters": "Kontrol Karakterlerini Aç/Kapat" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderWhitespace.i18n.json b/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderWhitespace.i18n.json new file mode 100644 index 00000000000..87c50ce4488 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/toggleRenderWhitespace.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleRenderWhitespace": "Boşlukları Görüntülemeyi Aç/Kapat" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json b/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json new file mode 100644 index 00000000000..44a5560df38 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/toggleWordWrap.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggle.wordwrap": "Görünüm: Sözcük Kaydırmasını Aç/Kapat", + "wordWrap.notInDiffEditor": "Diff düzenleyicisinde sözcük kaydırma açılıp kapatılamıyor", + "unwrapMinified": "Bu dosya için sonraki satıra kaydırmayı devre dışı bırak", + "wrapMinified": "Bu dosya için sonraki satıra kaydırmayı etkinleştir" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/wordWrapMigration.i18n.json b/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/wordWrapMigration.i18n.json new file mode 100644 index 00000000000..01e4868daa1 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/codeEditor/electron-browser/wordWrapMigration.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "wordWrapMigration.ok": "Tamam", + "wordWrapMigration.dontShowAgain": "Tekrar gösterme", + "wordWrapMigration.openSettings": "Ayarları Aç", + "wordWrapMigration.prompt": "`editor.wrappingColumn` ayarı, `editor.wordWrap` yüzünden kullanım dışıdır." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/browser/breakpointWidget.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/browser/breakpointWidget.i18n.json new file mode 100644 index 00000000000..a6f34090c4d --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/browser/breakpointWidget.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "breakpointWidgetExpressionPlaceholder": "İfade değerlendirmesi doğru olduğunda mola ver. Kabul etmek için 'Enter', iptal etmek için 'Esc' tuşuna basın.", + "breakpointWidgetAriaLabel": "Program, burada sadece bu koşul doğruysa durur. Kabul etmek için Enter veya iptal etmek için Escape tuşuna basın. ", + "breakpointWidgetHitCountPlaceholder": "İsabet sayısı koşulu sağlandığında mola ver. Kabul etmek için 'Enter', iptal etmek için 'Esc' tuşuna basın.", + "breakpointWidgetHitCountAriaLabel": "Program, burada sadece isabet sayısı koşulu sağlandığında durur. Kabul etmek için Enter veya iptal etmek için Escape tuşuna basın. ", + "expression": "İfade", + "hitCount": "İsabet Sayısı" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/browser/debugActionItems.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/browser/debugActionItems.i18n.json new file mode 100644 index 00000000000..8a17f02344d --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/browser/debugActionItems.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "addConfiguration": "Yapılandırma Ekle...", + "noConfigurations": "Yapılandırma Yok" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/browser/debugActions.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/browser/debugActions.i18n.json new file mode 100644 index 00000000000..3f796ff047d --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/browser/debugActions.i18n.json @@ -0,0 +1,49 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openLaunchJson": "{0} Dosyasını Aç", + "launchJsonNeedsConfigurtion": "'launch.json'u Yapılandır veya Düzelt", + "noFolderDebugConfig": "Gelişmiş hata ayıklama yapılandırması yapmak için lütfen ilk olarak bir klasör açın.", + "startDebug": "Hata Ayıklamaya Başla", + "startWithoutDebugging": "Hata Ayıklama Olmadan Başlat", + "selectAndStartDebugging": "Seç ve Hata Ayıklamaya Başla", + "restartDebug": "Yeniden Başlat", + "reconnectDebug": "Yeniden Bağlan", + "stepOverDebug": "Adım At", + "stepIntoDebug": "İçine Adımla", + "stepOutDebug": "Dışına Adımla", + "stopDebug": "Durdur", + "disconnectDebug": "Bağlantıyı Kes", + "continueDebug": "Devam Et", + "pauseDebug": "Duraklat", + "restartFrame": "Çerçeveyi Yeniden Başlat", + "removeBreakpoint": "Kesme Noktasını Kaldır", + "removeAllBreakpoints": "Tüm Kesme Noktalarını Kaldır", + "enableBreakpoint": "Kesme Noktasını Etkinleştir", + "disableBreakpoint": "Kesme Noktasını Devre Dışı Bırak", + "enableAllBreakpoints": "Tüm Kesme Noktalarını Etkinleştir", + "disableAllBreakpoints": "Tüm Kesme Noktalarını Devre Dışı Bırak", + "activateBreakpoints": "Kesme Noktalarını Etkinleştir", + "deactivateBreakpoints": "Kesme Noktalarını Devre Dışı Bırak", + "reapplyAllBreakpoints": "Tüm Kesme Noktalarını Yeniden Uygula", + "addFunctionBreakpoint": "Fonksiyon Kesme Noktası Ekle", + "renameFunctionBreakpoint": "Fonksiyon Kesme Noktasını Kaldır", + "addConditionalBreakpoint": "Koşullu Kesme Noktası Ekle...", + "editConditionalBreakpoint": "Kesme Noktasını Düzenle...", + "setValue": "Değeri Ayarla", + "addWatchExpression": "İfade Ekle", + "editWatchExpression": "İfadeyi Düzenle", + "addToWatchExpressions": "İzlemeye Ekle", + "removeWatchExpression": "İfadeyi Kaldır", + "removeAllWatchExpressions": "Tüm İfadeleri Kaldır", + "clearRepl": "Konsolu Temizle", + "debugConsoleAction": "Hata Ayıklama Konsolu", + "unreadOutput": "Hata Ayıklama Konsolunda Yeni Çıktı", + "debugFocusConsole": "Hata Ayıklama Konsoluna Odakla", + "focusProcess": "İşleme Odakla", + "stepBackDebug": "Geri Adım At", + "reverseContinue": "Tersine Çevir" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/browser/debugActionsWidget.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/browser/debugActionsWidget.i18n.json new file mode 100644 index 00000000000..a9c04322e91 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/browser/debugActionsWidget.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "debugToolBarBackground": "Hata ayıklama araç çubuğu arka plan rengi." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/browser/debugContentProvider.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/browser/debugContentProvider.i18n.json new file mode 100644 index 00000000000..647215e664e --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/browser/debugContentProvider.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "unable": "Hata ayıklama oturumu olmadan kaynak çözümlenemiyor" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/browser/debugEditorActions.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/browser/debugEditorActions.i18n.json new file mode 100644 index 00000000000..a5745c5e39e --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/browser/debugEditorActions.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleBreakpointAction": "Hata Ayıklama: Kesme Noktası Ekle/Kaldır", + "columnBreakpointAction": "Hata Ayıklama: Sütun Kesme Noktası", + "columnBreakpoint": "Sütun Kesme Noktası Ekle", + "conditionalBreakpointEditorAction": "Hata Ayıklama: Koşullu Kesme Noktası Ekle...", + "runToCursor": "İmlece Kadar Çalıştır", + "debugEvaluate": "Hata Ayıklama: Değerlendir", + "debugAddToWatch": "Hata Ayıklama: İzlemeye Ekle", + "showDebugHover": "Hata Ayıklama: Bağlantı Vurgusunu Göster" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/browser/debugEditorModelManager.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/browser/debugEditorModelManager.i18n.json new file mode 100644 index 00000000000..a9c06322151 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/browser/debugEditorModelManager.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "breakpointDisabledHover": "Devre Dışı Bırakılmış Kesme Noktası", + "breakpointUnverifieddHover": "Doğrulanmamış Kesme Noktası", + "breakpointDirtydHover": "Doğrulanmamış Kesme Noktası Dosya düzenlendi, lütfen hata ayıklama oturumunu yeniden başlatın.", + "breakpointUnsupported": "Koşullu kesme noktaları bu hata ayıklama türü tarafından desteklenmiyor" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/browser/debugQuickOpen.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/browser/debugQuickOpen.i18n.json new file mode 100644 index 00000000000..6a22d71e97d --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/browser/debugQuickOpen.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, hata ayıklama", + "debugAriaLabel": "Çalıştırılacak bir başlatma yapılandırması adı girin.", + "noConfigurationsMatching": "Eşleyen hata ayıklama yapılandırması yok", + "noConfigurationsFound": "Hiçbir hata ayıklama yapılandırması bulunamadı. Lütfen bir 'launch.json' dosyası oluşturun." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/browser/exceptionWidget.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/browser/exceptionWidget.i18n.json new file mode 100644 index 00000000000..3f777293285 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/browser/exceptionWidget.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "debugExceptionWidgetBorder": "İstisna aracı kenarlık rengi.", + "debugExceptionWidgetBackground": "İstisna aracı arka plan rengi.", + "exceptionThrownWithId": "İstisna oluştu: {0}", + "exceptionThrown": "İstisna oluştu." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/browser/linkDetector.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/browser/linkDetector.i18n.json new file mode 100644 index 00000000000..a5db6507a72 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/browser/linkDetector.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "fileLinkMac": "Takip etmek için tıklayın (Cmd + tıklama yana açar)", + "fileLink": "Takip etmek için tıklayın (Ctrl + tıklama yana açar)" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/common/debug.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/common/debug.i18n.json new file mode 100644 index 00000000000..52e048c8832 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/common/debug.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "internalConsoleOptions": "Dahili hata ayıklama konsolunun davranışlarını denetler." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/common/debugModel.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/common/debugModel.i18n.json new file mode 100644 index 00000000000..67633f8688f --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/common/debugModel.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "notAvailable": "mevcut değil", + "startDebugFirst": "Lütfen değerlendirilecek bir hata ayıklama oturumu başlatın" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/common/debugSource.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/common/debugSource.i18n.json new file mode 100644 index 00000000000..6d75e323512 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/common/debugSource.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "unknownSource": "Bilinmeyen Kaynak" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debug.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debug.contribution.i18n.json new file mode 100644 index 00000000000..14c96d48f15 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debug.contribution.i18n.json @@ -0,0 +1,20 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleDebugViewlet": "Hata Ayıklamayı Göster", + "toggleDebugPanel": "Hata Ayıklama Konsolu", + "debug": "Hata Ayıklama", + "debugPanel": "Hata Ayıklama Konsolu", + "view": "Görüntüle", + "debugCategory": "Hata Ayıklama", + "debugCommands": "Hata Ayıklama Yapılandırması", + "debugConfigurationTitle": "Hata Ayıklama", + "allowBreakpointsEverywhere": "Herhangi bir dosyada kesme noktası ayarlamaya izin verir", + "openExplorerOnEnd": "Bir hata ayıklama oturumunun sonunda otomatik olarak gezgin görünümünü açın", + "inlineValues": "Hata ayıklama sırasında değişken değerlerini düzenleyicide satır içinde göster", + "hideActionBar": "Dolaştırılabilir hata ayıklama eylem çubuğunun gizlenip gizlenmeyeceğini denetler", + "launch": "Global hata ayıklama başlatma yapılandırması. Çalışma alanlarında paylaşılan 'launch.json'a alternatif olarak kullanılmalıdır" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json new file mode 100644 index 00000000000..614f97b48db --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugCommands.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "noFolderDebugConfig": "Gelişmiş hata ayıklama yapılandırması yapmak için lütfen ilk olarak bir klasör açın." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugConfigurationManager.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugConfigurationManager.i18n.json new file mode 100644 index 00000000000..594cc3a08e1 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugConfigurationManager.i18n.json @@ -0,0 +1,38 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.debuggers": "Hata ayıklama bağdaştırıcılarına ekleme yapar.", + "vscode.extension.contributes.debuggers.type": "Bu hata ayıklama bağdaştırıcısnın benzersiz tanımlayıcısı.", + "vscode.extension.contributes.debuggers.label": "Bu hata ayıklama bağdaştırıcısnın görünen adı.", + "vscode.extension.contributes.debuggers.program": "Hata ayıklama bağdaştırıcı programının yolu. Yol, ya mutlak ya da eklenti klasörüne görelidir.", + "vscode.extension.contributes.debuggers.args": "Bağdaştırıcıya iletilecek ek argümanlar.", + "vscode.extension.contributes.debuggers.runtime": "Program özniteliğinin yürütülebilir olmadığı halde bir çalışma zamanını gerektirmesi durumu için isteğe bağlı çalışma zamanı.", + "vscode.extension.contributes.debuggers.runtimeArgs": "İsteğe bağlı çalışma zamanı argümanları.", + "vscode.extension.contributes.debuggers.variables": "`launch.json` dosyasındaki interaktif değişkenlerin (ör. ${action.pickProcess}) bir komuta eşlenmesi.", + "vscode.extension.contributes.debuggers.initialConfigurations": "İlk 'launch.json' dosyasının üretimi için yapılandırmalar.", + "vscode.extension.contributes.debuggers.languages": "Hata ayıklama eklentisinin, \"varsayılan hata ayıklayıcı\" olarak değerlendirilebileceği diller listesi.", + "vscode.extension.contributes.debuggers.adapterExecutableCommand": "Belirtilirse; VS Code, hata ayıklama bağdaştırıcısı yürütülebilir dosyasının yolunu ve ona gönderilecek argümanları belirlemek için bu komutu çağırır.", + "vscode.extension.contributes.debuggers.startSessionCommand": "Belirtilirse; VS Code, bu eklenti için hedeflenen \"hata ayıklama\" ve \"çalıştır\" eylemleri için bu komutu çağırır.", + "vscode.extension.contributes.debuggers.configurationSnippets": "'launch.json' dosyasına yeni yapılandırmalar ekleme parçacıkları.", + "vscode.extension.contributes.debuggers.configurationAttributes": "'launch.json' dosyasını doğrulayacak JSON şema yapılandırmaları.", + "vscode.extension.contributes.debuggers.windows": "Windows'a özel ayarlar.", + "vscode.extension.contributes.debuggers.windows.runtime": "Windows'da kullanılacak çalışma zamanı.", + "vscode.extension.contributes.debuggers.osx": "OS X'e özel ayarlar.", + "vscode.extension.contributes.debuggers.osx.runtime": "OS X'de kullanılacak çalışma zamanı.", + "vscode.extension.contributes.debuggers.linux": "Linux'a özel ayarlar.", + "vscode.extension.contributes.debuggers.linux.runtime": "Linux'da kullanılacak çalışma zamanı.", + "vscode.extension.contributes.breakpoints": "Kesme noktalarına ekleme yapar.", + "vscode.extension.contributes.breakpoints.language": "Bu dil için kesme noktalarını etkinleştir.", + "app.launch.json.title": "Başlat", + "app.launch.json.version": "Bu dosya biçiminin sürümü.", + "app.launch.json.configurations": "Yapılandırma listesi. IntelliSense kullanarak yeni yapılandırmalar ekleyin veya mevcut olanları düzenleyin.", + "app.launch.json.compounds": "Bileşikler listesi. Her bileşik, birlikte çalıştırılacak birden çok yapılandırmaya başvurur.", + "app.launch.json.compound.name": "Bileşiğin adı. Başlatma yapılandırması açılır kutu menüsünde görünür.", + "app.launch.json.compounds.configurations": "Bu bileşiğin parçası olarak başlatılacak yapılandırmaların adları.", + "debugNoType": "Hata ayıklama bağdaştırıcısının 'type' ögesi atlanabilir veya 'dize' türünde olmalıdır.", + "DebugConfig.failed": " '.vscode' klasörü içinde 'launch.json' dosyası oluşturulamıyor ({0}).", + "selectDebug": "Ortam Seçin" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.i18n.json new file mode 100644 index 00000000000..dd1bf89582d --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugEditorContribution.i18n.json @@ -0,0 +1,20 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "removeBreakpoints": "Kesme Noktalarını Kaldır", + "removeBreakpointOnColumn": "{0}. Sütundaki Kesme Noktasını Kaldır", + "removeLineBreakpoint": "Satır Kesme Noktasını Kaldır", + "editBreakpoints": "Kesme Noktalarını Düzenle", + "editBreakpointOnColumn": "{0}. Sütundaki Kesme Noktasını Düzenle", + "editLineBrekapoint": "Satır Kesme Noktasını Düzenle", + "enableDisableBreakpoints": "Kesme Noktalarını Etkinleştir/Devre Dışı Bırak", + "disableColumnBreakpoint": "{0}. Sütundaki Kesme Noktasını Devre Dışı Bırak", + "disableBreakpointOnLine": "Satır Kesme Noktasını Devre Dışı Bırak", + "enableBreakpoints": "{0}. Sütundaki Kesme Noktasını Etkinleştir", + "enableBreakpointOnLine": "Satır Kesme Noktasını Etkinleştir", + "addBreakpoint": "Kesme Noktası Ekle", + "addConfiguration": "Yapılandırma Ekle..." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugHover.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugHover.i18n.json new file mode 100644 index 00000000000..f805425af14 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugHover.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "treeAriaLabel": "Hata Ayıklama Bağlantı Vurgusu" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json new file mode 100644 index 00000000000..d90aab83c4c --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugService.i18n.json @@ -0,0 +1,25 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "snapshotObj": "Bu nesne için sadece ilkel türler gösterilir.", + "debuggingPaused": "Hata ayıklama duraklatıldı, sebep {0}, {1} {2}", + "debuggingStarted": "Hata ayıklama başlatıldı.", + "debuggingStopped": "Hata ayıklama durduruldu.", + "breakpointAdded": "Kesme noktası eklendi, {0}. satır, {1} dosyası", + "breakpointRemoved": "Kesme noktası kaldırıldı, {0}. satır, {1} dosyası", + "compoundMustHaveConfigurations": "Bileşik, birden çok yapılandırmayı başlatmak için \"configurations\" özniteliği bulundurmalıdır.", + "configMissing": "'launch.json' dosyasında '{0}' yapılandırması eksik.", + "debugTypeNotSupported": "Yapılandırılan hata ayıklama türü '{0}', desteklenmiyor.", + "debugTypeMissing": "Seçilen başlatma yapılandırması için 'type' özelliği eksik.", + "preLaunchTaskErrors": "'{0}' ön başlatma görevi sırasında derleme hataları algılandı.", + "preLaunchTaskError": "'{0}' ön başlatma görevi sırasında derleme hatası algılandı.", + "preLaunchTaskExitCode": "'{0}' ön başlatma görevi {1} çıkış koduyla sonlandı.", + "debugAnyway": "Yine de Hata Ayıkla", + "noFolderWorkspaceDebugError": "Aktif dosyada hata ayıklama yapılamıyor. Lütfen, dosyanın diskte kayıtlı olduğundan ve bu dosya türü için hata ayıklama eklentinizin olduğundan emin olun.", + "NewLaunchConfig": "Lütfen uygulamanızın başlatma yapılandırması dosyasını ayarlayın. {0}", + "DebugTaskNotFound": "'{0}' ön başlatma görevi bulunamadı.", + "differentTaskRunning": "Çalışan bir {0} görevi var. Ön başlatma görevi {1} çalıştırılamıyor." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugViewer.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugViewer.i18n.json new file mode 100644 index 00000000000..823377981dd --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugViewer.i18n.json @@ -0,0 +1,28 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "process": "İşlem", + "paused": "Duraklatıldı", + "running": "Çalışıyor", + "thread": "İş Parçacığı", + "pausedOn": "{0} Üzerinde Duraklatıldı", + "loadMoreStackFrames": "Daha Fazla Yığın Çerçevesi Yükleyin", + "threadAriaLabel": "{0} iş parçacığı, çağrı yığını, hata ayıklama", + "stackFrameAriaLabel": "Yığın Çerçevesi {0} satır {1} {2}, çağrı yığını, hata ayıklama", + "variableValueAriaLabel": "Yeni değişken adını girin", + "variableScopeAriaLabel": "{0} kapsamı, değişkenler, hata ayıklama", + "variableAriaLabel": "{0} değeri {1}, değişkenler, hata ayıklama", + "watchExpressionPlaceholder": "İzlenecek ifade", + "watchExpressionInputAriaLabel": "İzleme ifadesi girin", + "watchExpressionAriaLabel": "{0} değeri {1}, izleme, hata ayıklama", + "watchVariableAriaLabel": "{0} değeri {1}, izleme, hata ayıklama", + "functionBreakpointPlaceholder": "Mola verilecek fonksiyon", + "functionBreakPointInputAriaLabel": "Fonksiyon kesme noktasını girin", + "functionBreakpointsNotSupported": "Fonksiyon kesme noktaları bu hata ayıklama türü tarafından desteklenmiyor", + "breakpointAriaLabel": "Kesme noktası satır {0} {1}, kesme noktaları, hata ayıklama", + "functionBreakpointAriaLabel": "Fonksiyon kesme noktası {0}, kesme noktaları, hata ayıklama", + "exceptionBreakpointAriaLabel": "İstisna kesme noktası {0}, kesme noktaları, hata ayıklama" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json new file mode 100644 index 00000000000..8a92525c7f5 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/debugViews.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "variablesSection": "Değişkenler Bölümü", + "variablesAriaTreeLabel": "Hata Ayıklama Değişkenleri", + "expressionsSection": "İfadeler Bölümü", + "watchAriaTreeLabel": "Hata Ayıklama İzleme İfadeleri", + "callstackSection": "Çağrı Yığını Bölümü", + "debugStopped": "{0} Üzerinde Duraklatıldı", + "callStackAriaLabel": "Hata Ayıklama Çağrı Yığını", + "breakpointsSection": "Kesme Noktaları Bölümü", + "breakpointsAriaTreeLabel": "Hata Ayıklama Kesme Noktaları" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json new file mode 100644 index 00000000000..52d6e60d750 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/electronDebugActions.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "copyValue": "Değeri Kopyala", + "copy": "Kopyala", + "copyAll": "Tümünü Kopyala", + "copyStackTrace": "Çağrı Yığınını Kopyala" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.i18n.json new file mode 100644 index 00000000000..68bc0009a9c --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/rawDebugSession.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "moreInfo": "Daha Fazla Bilgi", + "unableToLaunchDebugAdapter": "'{0}' tarafından hata ayıklama bağdaştırıcısı başlatılamadı.", + "unableToLaunchDebugAdapterNoArgs": "Hata ayıklama bağdaştırıcısı başlatılamıyor.", + "stoppingDebugAdapter": "{0}. Hata ayıklama bağdaştırıcısı durduruluyor.", + "debugAdapterCrash": "Hata ayıklama bağdaştırıcısı beklenmeyen biçimde sonlandırıldı" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/electron-browser/repl.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/repl.i18n.json new file mode 100644 index 00000000000..f3b84b06d7c --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/repl.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "replAriaLabel": "Oku Değerlendir Yaz Döngüsü Paneli", + "actions.repl.historyPrevious": "Önceki Geçmiş", + "actions.repl.historyNext": "Sonraki Geçmiş", + "actions.repl.acceptInput": "REPL Girdiyi Kabul Et", + "actions.repl.copyAll": "Hata Ayıklama: Konsol Tümünü Kopyala" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/electron-browser/replViewer.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/replViewer.i18n.json new file mode 100644 index 00000000000..3ee7a241566 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/replViewer.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "stateCapture": "Nesne durumu ilk değerlendirmeden alındı", + "replVariableAriaLabel": "{0} değişkeni, {1} değerine sahip, oku değerlendir yaz döngüsü, hata ayıklama", + "replExpressionAriaLabel": "{0} ifadesi, {1} değerine sahip, oku değerlendir yaz döngüsü, hata ayıklama", + "replValueOutputAriaLabel": "{0}, oku değerlendir yaz döngüsü, hata ayıklama", + "replKeyValueOutputAriaLabel": "{0} çıktı değişkeni, {1} değerine sahip, oku değerlendir yaz döngüsü, hata ayıklama" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json new file mode 100644 index 00000000000..9d6394edd4c --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/statusbarColorProvider.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "statusBarDebuggingBackground": "Bir programda hata ayıklama yapılırken durum çubuğu arka plan rengi. Durum çubuğu, pencerenin alt kısmında gösterilir.", + "statusBarDebuggingForeground": "Bir programda hata ayıklama yapılırken durum çubuğu ön plan rengi. Durum çubuğu, pencerenin alt kısmında gösterilir." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/electron-browser/terminalSupport.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/terminalSupport.i18n.json new file mode 100644 index 00000000000..b5f38fd9078 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/electron-browser/terminalSupport.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "debug.terminal.title": "hata ayıklanan", + "debug.terminal.not.available.error": "Entegre terminal mevcut değil" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json b/i18n/trk/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json new file mode 100644 index 00000000000..6d21fb46e92 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/debug/node/debugAdapter.i18n.json @@ -0,0 +1,20 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "debugAdapterBinNotFound": "Hata ayıklama bağdaştırıcısı yürütülebilir dosyası '{0}', mevcut değil.", + "debugAdapterCannotDetermineExecutable": "Hata ayıklama bağdaştırıcısı yürütülebilir dosyası '{0}' belirlenemedi.", + "debugType": "Yapılandırma türü.", + "debugTypeNotRecognised": "Hata ayıklama türü tanınmıyor. Karşılık gelen hata ayıklama uzantısı yüklemiş olduğunuzdan ve etkinleştirildiğinden emin olun.", + "node2NotSupported": "\"node2\" artık desteklenmiyor, bunun yerine \"node\" kullanın ve \"protocol\" özniteliğini \"inspector\" olarak ayarlayın.", + "debugName": "Yapılandırmanın adı; başlatma yapılandırması açılır kutu menüsünde görünür.", + "debugRequest": "Yapılandırmanın istek türü. \"launch\" veya \"attach\" olabilir.", + "debugServer": "Sadece eklenti geliştirme hata ayıklaması için: eğer port belirtildiyse; Vs Code, bir hata ayıklama bağdaştırıcısına sunucu modunda bağlanmayı dener", + "debugPrelaunchTask": "Hata ayıklama oturumu başlamadan önce çalıştırılacak görev.", + "debugWindowsConfiguration": "Windows'a özel başlangıç yapılandırması öznitelikleri.", + "debugOSXConfiguration": "OS X'e özel başlangıç yapılandırması öznitelikleri.", + "debugLinuxConfiguration": "Linux'a özel başlangıç yapılandırması öznitelikleri.", + "deprecatedVariables": "'env.', 'config.' ve 'command.' kullanım dışıdır, bunların yerine 'env:', 'config:' ve 'command:' kulanın." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/emmet/browser/actions/showEmmetCommands.i18n.json b/i18n/trk/src/vs/workbench/parts/emmet/browser/actions/showEmmetCommands.i18n.json new file mode 100644 index 00000000000..7e019e4d696 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/emmet/browser/actions/showEmmetCommands.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "showEmmetCommands": "Emmet Komutlarını Göster" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/balance.i18n.json b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/balance.i18n.json new file mode 100644 index 00000000000..7f2cf686977 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/balance.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "balanceInward": "Emmet: Dengele (içe)", + "balanceOutward": "Emmet: Dengele (dışa)" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json new file mode 100644 index 00000000000..7832e967688 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/editPoints.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "previousEditPoint": "Emmet: Önceki Düzenleme Noktasına Git", + "nextEditPoint": "Emmet: Sonraki Düzenleme Noktasına Git" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json new file mode 100644 index 00000000000..77713e86bc0 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/evaluateMath.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "evaluateMathExpression": "Emmet: Matematik İfadesini Değerlendir" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.i18n.json b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.i18n.json new file mode 100644 index 00000000000..53b34ac42e8 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/expandAbbreviation.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "expandAbbreviationAction": "Emmet: Kısaltmayı Genişlet" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json new file mode 100644 index 00000000000..6692ba5badb --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/incrementDecrement.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "incrementNumberByOneTenth": "Emmet: 0.1 Arttır", + "incrementNumberByOne": "Emmet: 1 Arttır", + "incrementNumberByTen": "Emmet: 10 Arttır", + "decrementNumberByOneTenth": "Emmet: 0.1 Azalt", + "decrementNumberByOne": "Emmet: 1 Azalt", + "decrementNumberByTen": "Emmet: 10 Azalt" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/matchingPair.i18n.json b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/matchingPair.i18n.json new file mode 100644 index 00000000000..0bae8eb938d --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/matchingPair.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "matchingPair": "Emmet: Eşleşen Çifte Git" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/mergeLines.i18n.json b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/mergeLines.i18n.json new file mode 100644 index 00000000000..a083c13f1e5 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/mergeLines.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "mergeLines": "Emmet: Satırları Birleştir" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/reflectCssValue.i18n.json b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/reflectCssValue.i18n.json new file mode 100644 index 00000000000..8cceaedbe4b --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/reflectCssValue.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "reflectCSSValue": "Emmet: CSS Değerini Yansıt" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json new file mode 100644 index 00000000000..13f4115a719 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/removeTag.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "removeTag": "Emmet: Etiketi Sil" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/selectItem.i18n.json b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/selectItem.i18n.json new file mode 100644 index 00000000000..2507b6d025b --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/selectItem.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "selectPreviousItem": "Emmet: Önceki Ögeyi Seç", + "selectNextItem": "Emmet: Sonraki Ögeyi Seç" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json new file mode 100644 index 00000000000..c64d4ead154 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/splitJoinTag.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "splitJoinTag": "Emmet: Etiketi Böl/Birleştir" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/toggleComment.i18n.json b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/toggleComment.i18n.json new file mode 100644 index 00000000000..4f88ade10dc --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/toggleComment.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleComment": "Emmet: Yorumu Aç/Kapat" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json new file mode 100644 index 00000000000..862f8163fb4 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/updateImageSize.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "updateImageSize": "Emmet: Görüntü Boyutunu Güncelle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json new file mode 100644 index 00000000000..48f15952492 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/updateTag.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "updateTag": "Emmet: Etiketi Güncelle", + "enterTag": "Etiketi Gir", + "tag": "Etiket" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json new file mode 100644 index 00000000000..678b349f571 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/actions/wrapWithAbbreviation.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "wrapWithAbbreviationAction": "Emmet: Kısaltma ile Sarmala", + "enterAbbreviation": "Kısaltmayı Gir", + "abbreviation": "Kısaltma" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json new file mode 100644 index 00000000000..bbcfad4c7f4 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/emmet/electron-browser/emmet.contribution.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "emmetConfigurationTitle": "Emmet", + "triggerExpansionOnTab": "Etkinleştirildiğinde, emmet kısaltmaları TAB tuşuna basıldığında genişletilir.", + "emmetPreferences": "Emmet'in bazı eylemleri ve çözümleyicilerinin davranışını değiştirmek için kullanılacak tercihler.", + "emmetSyntaxProfiles": "Belirtilen sentaks için profil tanımlayın veya kendi profilinizi belirli kurallarla kullanın.", + "emmetExclude": "Emmet kısaltmalarının genişletilmeyeceği bir diller dizisi.", + "emmetExtensionsPath": "Emmet profileri, parçacıkları ve tercihlerini içeren bir klasör yolu.", + "useNewEmmet": "Tüm emmet özellikleri için yeni emmet modüllerini deneyin(sonunda eski tekil emmet kütüphanesinin yerini alacaktır)." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/execution/electron-browser/terminal.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/execution/electron-browser/terminal.contribution.i18n.json new file mode 100644 index 00000000000..72d4755b5b4 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/execution/electron-browser/terminal.contribution.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminalConfigurationTitle": "Harici Terminal", + "terminal.external.windowsExec": "Windows'da hangi terminalin çalışacağını ayarlar.", + "terminal.external.osxExec": "OS X'de hangi terminalin çalışacağını ayarlar.", + "terminal.external.linuxExec": "Linux'da hangi terminalin çalışacağını ayarlar.", + "globalConsoleActionWin": "Yeni Komut İstemi Aç", + "globalConsoleActionMacLinux": "Yeni Terminal Aç", + "scopedConsoleActionWin": "Komut İsteminde Aç", + "scopedConsoleActionMacLinux": "Terminalde Aç" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/execution/electron-browser/terminalService.i18n.json b/i18n/trk/src/vs/workbench/parts/execution/electron-browser/terminalService.i18n.json new file mode 100644 index 00000000000..6e763ea8681 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/execution/electron-browser/terminalService.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "console.title": "VS Code Konsolu", + "mac.terminal.script.failed": "'{0}' betiği, {1} çıkış koduyla başarısız oldu", + "mac.terminal.type.not.supported": "'{0}' desteklenmiyor", + "press.any.key": "Devam etmek için bir tuşa basın ...", + "linux.term.failed": "'{0}', {1} çıkış koduyla başarısız oldu" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json new file mode 100644 index 00000000000..1341aa7a5fa --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/explorers/browser/treeExplorer.contribution.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.view": "Özel görünüme ekleme yapar", + "vscode.extension.contributes.view.id": "vscode.workspace.createTreeView aracılığıyla oluşturulan görünümü tanımlamak için kullanılan benzersiz kimlik", + "vscode.extension.contributes.view.label": "Görünümde gösterilecek insanlar tarafından okunabilir dize", + "vscode.extension.contributes.view.icon": "Görünüm simgesinin yolu", + "vscode.extension.contributes.views": "Özel görünümlere ekleme yapar", + "showViewlet": "{0}'i Göster", + "view": "Görüntüle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/explorers/browser/treeExplorerActions.i18n.json b/i18n/trk/src/vs/workbench/parts/explorers/browser/treeExplorerActions.i18n.json new file mode 100644 index 00000000000..f9ce5d1c2d7 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/explorers/browser/treeExplorerActions.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "refresh": "Yenile" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/explorers/browser/treeExplorerService.i18n.json b/i18n/trk/src/vs/workbench/parts/explorers/browser/treeExplorerService.i18n.json new file mode 100644 index 00000000000..25fbff908a0 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/explorers/browser/treeExplorerService.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "treeExplorer.noMatchingProviderId": "{providerId} kimliği ile kayıtlı \"TreeExplorerNodeProvider\" yok." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/explorers/browser/views/treeExplorerView.i18n.json b/i18n/trk/src/vs/workbench/parts/explorers/browser/views/treeExplorerView.i18n.json new file mode 100644 index 00000000000..bc360a62ef3 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/explorers/browser/views/treeExplorerView.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "treeExplorerViewlet.tree": "Ağaç Gezgini Bölümü" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/extensions/browser/dependenciesViewer.i18n.json b/i18n/trk/src/vs/workbench/parts/extensions/browser/dependenciesViewer.i18n.json new file mode 100644 index 00000000000..36f005e07fc --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/extensions/browser/dependenciesViewer.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "error": "Hata", + "Unknown Dependency": "Bilinmeyen Bağımlılık:" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json b/i18n/trk/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json new file mode 100644 index 00000000000..fd30d687af2 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/extensions/browser/extensionEditor.i18n.json @@ -0,0 +1,43 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "name": "Eklenti adı", + "extension id": "Eklenti tanımlayıcısı", + "publisher": "Yayıncı adı", + "install count": "Yüklenme sayısı", + "rating": "Derecelendirme", + "license": "Lisans", + "details": "Detaylar", + "contributions": "Eklemeler", + "changelog": "Değişim Günlüğü", + "dependencies": "Bağımlılıklar", + "noReadme": "README dosyası yok.", + "noChangelog": "Değişim günlüğü yok.", + "noContributions": "Hiçbir Ekleme Yapmıyor", + "noDependencies": "Bağımlılık Yok", + "settings": "Ayarlar ({0})", + "setting name": "Adı", + "description": "Açıklama", + "default": "Varsayılan", + "debuggers": "Hata Ayıklayıcılar ({0})", + "debugger name": "Adı", + "views": "Görünümler ({0})", + "view id": "ID", + "view name": "Adı", + "view location": "Yeri", + "themes": "Temalar ({0})", + "JSON Validation": "JSON Doğrulama ({0})", + "commands": "Komutlar ({0})", + "command name": "Adı", + "keyboard shortcuts": "Klavye Kısayolları", + "menuContexts": "Menü Bağlamları", + "languages": "Diller ({0})", + "language id": "ID", + "language name": "Adı", + "file extensions": "Dosya Uzantıları", + "grammar": "Gramer", + "snippets": "Parçacıklar" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json b/i18n/trk/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json new file mode 100644 index 00000000000..c76e1470bfc --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/extensions/browser/extensionsActions.i18n.json @@ -0,0 +1,62 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "installAction": "Yükle", + "installing": "Yükleniyor", + "uninstallAction": "Kaldır", + "Uninstalling": "Kaldırılıyor", + "updateAction": "Güncelle", + "updateTo": "{0} sürümüne güncelle", + "enableForWorkspaceAction.label": "Etkinleştir (Çalışma Alanı)", + "enableAlwaysAction.label": "Etkinleştir (Daima)", + "disableForWorkspaceAction.label": "Devre Dışı Bırak (Çalışma Alanı)", + "disableAlwaysAction.label": "Devre Dışı Bırak (Daima)", + "ManageExtensionAction.uninstallingTooltip": "Kaldırılıyor", + "enableForWorkspaceAction": "Çalışma Alanı", + "enableGloballyAction": "Daima", + "enableAction": "Etkinleştir", + "disableForWorkspaceAction": "Çalışma Alanı", + "disableGloballyAction": "Daima", + "disableAction": "Devre Dışı Bırak", + "checkForUpdates": "Güncelleştirmeleri Denetle", + "enableAutoUpdate": "Eklentileri Otomatik Olarak Güncelleştirmeyi Etkinleştir", + "disableAutoUpdate": "Eklentileri Otomatik Olarak Güncelleştirmeyi Devre Dışı Bırak", + "updateAll": "Tüm Eklentileri Güncelle", + "reloadAction": "Yeniden Yükle", + "postUpdateTooltip": "Güncellemek için yeniden yükleyin", + "postUpdateMessage": "Güncellenen '{0}' eklentisini etkinleştirmek için bu pencere yeniden yüklensin mi?", + "postEnableTooltip": "Etkinleştirmek için yeniden yükleyin", + "postEnableMessage": "'{0}' eklentisini etkinleştirmek için bu pencere yeniden yüklensin mi?", + "postDisableTooltip": "Devre dışı bırakmak için yeniden yükleyin", + "postDisableMessage": "'{0}' eklentisini devre dışı bırakmak için bu pencere yeniden yüklensin mi?", + "postUninstallTooltip": "Devre dışı bırakmak için yeniden yükleyin", + "postUninstallMessage": "Kaldırılan '{0}' eklentisini devre dışı bırakmak için bu pencere yeniden yüklensin mi?", + "reload": "Pencereyi &&Yeniden Yükle", + "toggleExtensionsViewlet": "Eklentileri Göster", + "installExtensions": "Eklenti Yükle", + "showInstalledExtensions": "Yüklenen Eklentileri Göster", + "showDisabledExtensions": "Devre Dışı Bırakılan Eklentileri Göster", + "clearExtensionsInput": "Eklenti Girdisini Temizle", + "showOutdatedExtensions": "Eski Eklentileri Göster", + "showPopularExtensions": "Popüler Eklentileri Göster", + "showRecommendedExtensions": "Tavsiye Edilen Eklentileri Göster", + "showWorkspaceRecommendedExtensions": "Çalışma Alanının Tavsiye Ettiği Eklentileri Göster", + "showRecommendedKeymapExtensions": "Tavsiye Edilen Tuş Haritalarını Göster", + "showRecommendedKeymapExtensionsShort": "Tuş Haritaları", + "showLanguageExtensions": "Dil Eklentilerini Göster", + "showLanguageExtensionsShort": "Dil Eklentileri", + "configureWorkspaceRecommendedExtensions": "Tavsiye Edilen Eklentileri Yapılandır (Çalışma Alanı)", + "ConfigureWorkspaceRecommendations.noWorkspace": "Tavsiyeler, sadece çalışma alanı klasöründe mevcuttur.", + "OpenExtensionsFile.failed": " '.vscode' klasörü içinde 'extensions.json' dosyası oluşturulamıyor ({0}).", + "builtin": "Yerleşik", + "disableAll": "Yüklü Tüm Eklentileri Devre Dışı Bırak", + "disableAllWorkspace": "Bu Çalışma Alanı için Yüklü Tüm Eklentileri Devre Dışı Bırak", + "enableAll": "Yüklü Tüm Eklentileri Etkinleştir", + "enableAllWorkspace": "Bu Çalışma Alanı için Yüklü Tüm Eklentileri Etkinleştir", + "extensionButtonProminentBackground": "Dikkat çeken eklenti eylemleri için buton arka plan rengi (ör. yükle butonu)", + "extensionButtonProminentForeground": "Dikkat çeken eklenti eylemleri için buton ön plan rengi (ör. yükle butonu)", + "extensionButtonProminentHoverBackground": "Dikkat çeken eklenti eylemleri için buton bağlantı vurgusu arka plan rengi (ör. yükle butonu)" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/extensions/browser/extensionsQuickOpen.i18n.json b/i18n/trk/src/vs/workbench/parts/extensions/browser/extensionsQuickOpen.i18n.json new file mode 100644 index 00000000000..1ac44b7c83d --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/extensions/browser/extensionsQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "manage": "Eklentilerinizi yönetmek için Enter'a basın.", + "searchFor": "Markette '{0}' için arama yapmak için Enter'a basın.", + "noExtensionsToInstall": "Bir eklenti adı girin" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/extensions/common/extensionsFileTemplate.i18n.json b/i18n/trk/src/vs/workbench/parts/extensions/common/extensionsFileTemplate.i18n.json new file mode 100644 index 00000000000..00655354629 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/extensions/common/extensionsFileTemplate.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "app.extensions.json.title": "Eklentiler", + "app.extensions.json.recommendations": "Eklenti tavsiyelerinin listesi. Bir eklentinin tanımlayıcısı daima '${yayinci}.${ad}' şeklindedir. Örnek: 'vscode.csharp'.", + "app.extension.identifier.errorMessage": "'${yayinci}.${ad}' biçimi bekleniyor. Örnek: 'vscode.csharp'." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/extensions/common/extensionsInput.i18n.json b/i18n/trk/src/vs/workbench/parts/extensions/common/extensionsInput.i18n.json new file mode 100644 index 00000000000..93faa852946 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/extensions/common/extensionsInput.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "extensionsInputName": "Eklenti: {0}" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json b/i18n/trk/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json new file mode 100644 index 00000000000..640d11588c6 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/extensions/electron-browser/extensionTipsService.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "reallyRecommended2": "'{0}' eklentisi bu dosya türü için tavsiye edilir.", + "showRecommendations": "Tavsiyeleri Göster", + "neverShowAgain": "Tekrar gösterme", + "close": "Kapat", + "workspaceRecommended": "Bu çalışma alanı bazı eklentileri tavsiye ediyor.", + "ignoreExtensionRecommendations": "Tüm eklenti tavsiyelerini yok saymak istiyor musunuz?", + "ignoreAll": "Evet, Tümünü Yok Say", + "no": "Hayır", + "cancel": "İptal" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json new file mode 100644 index 00000000000..f6176cf12dd --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/extensions/electron-browser/extensions.contribution.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "extensionsCommands": "Eklentileri Yönet", + "galleryExtensionsCommands": "Galeri Eklentileri Yükle", + "extension": "Eklenti", + "extensions": "Eklentiler", + "view": "Görüntüle", + "extensionsConfigurationTitle": "Eklentiler", + "extensionsAutoUpdate": "Eklentileri otomatik olarak güncelle", + "extensionsIgnoreRecommendations": "Eklenti tavsiyelerini yok say" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/extensions/electron-browser/extensionsActions.i18n.json b/i18n/trk/src/vs/workbench/parts/extensions/electron-browser/extensionsActions.i18n.json new file mode 100644 index 00000000000..25237bc8ead --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/extensions/electron-browser/extensionsActions.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openExtensionsFolder": "Eklentiler Klasörünü Aç", + "installVSIX": "VSIX'ten yükle...", + "InstallVSIXAction.success": "Eklenti başarıyla yüklendi. Etkinleştirmek için yeniden başlatın.", + "InstallVSIXAction.reloadNow": "Şimdi Yeniden Yükle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json b/i18n/trk/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json new file mode 100644 index 00000000000..33992c788d0 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/extensions/electron-browser/extensionsUtils.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "disableOtherKeymapsConfirmation": "Tuş bağlamlarında çakışmalardan kaçınmak için diğer tuş haritaları ({0}) devre dışı bırakılsın mı?", + "yes": "Evet", + "no": "Hayır", + "betterMergeDisabled": "\"Better Merge\" artık yerleşik bir eklenti, yüklenen eklendi devre dışı bırakıldı ve kaldırılabilir.", + "uninstall": "Kaldır", + "later": "Daha Sonra" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.i18n.json b/i18n/trk/src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.i18n.json new file mode 100644 index 00000000000..1a9d49af7b9 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/extensions/electron-browser/extensionsViewlet.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "searchExtensions": "Markette Eklenti Ara", + "extensions": "Eklentiler", + "sort by installs": "Sırala: Yüklenme Sayısına Göre", + "sort by rating": "Sırala: Derecelendirmeye Göre", + "sort by name": "Sırala: Ada Göre", + "no extensions found": "Eklenti yok.", + "suggestProxyError": "Market, 'ECONNREFUSED' döndürdü. Lütfen 'http.proxy' ayarını kontrol edin.", + "outdatedExtensions": "{0} Eski Eklenti" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.i18n.json b/i18n/trk/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.i18n.json new file mode 100644 index 00000000000..c0336e59243 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/extensions/node/extensionsWorkbenchService.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "enableDependeciesConfirmation": "'{0}' eklentisini etkinleştirdiğinizde onun bağımlılıkları da etkinleştirilir. Devam etmek istiyor musunuz?", + "enable": "Evet", + "doNotEnable": "Hayır", + "disableDependeciesConfirmation": "Yalnızca '{0}' eklentisini mi devre dışı bırakmak istersiniz yoksa bağımlılıklarını da devre dışı bırakmak ister misiniz?", + "disableOnly": "Sadece Eklenti", + "disableAll": "Tümü", + "cancel": "İptal", + "singleDependentError": "'{0}' eklentisi devre dışı bırakılamıyor. '{1}' eklentisi buna bağlı.", + "twoDependentsError": "'{0}' eklentisi devre dışı bırakılamıyor. '{1}' ve '{2}' eklentileri buna bağlı.", + "multipleDependentsError": "'{0}' eklentisi devre dışı bırakılamıyor. '{1}, '{2}' eklentileri ve diğerleri buna bağlı." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/feedback/electron-browser/feedback.i18n.json b/i18n/trk/src/vs/workbench/parts/feedback/electron-browser/feedback.i18n.json new file mode 100644 index 00000000000..d8da171200f --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/feedback/electron-browser/feedback.i18n.json @@ -0,0 +1,25 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "sendFeedback": "Geri Bildirimi Tweet'le", + "label.sendASmile": "Geri bildiriminizi bize Tweet'leyin.", + "patchedVersion1": "Kurulumunuz bozuk.", + "patchedVersion2": "Eğer bir hata gönderiyorsanız bunu belirtin.", + "sentiment": "Deneyiminiz nasıldı?", + "smileCaption": "Mutlu", + "frownCaption": "Üzgün", + "other ways to contact us": "Bize ulaşmanın diğer yolları", + "submit a bug": "Bir hata gönder", + "request a missing feature": "Eksik bir özellik talebinde bulun", + "tell us why?": "Bize nedenini söyleyin:", + "commentsHeader": "Açıklamalar", + "tweet": "Tweet'le", + "character left": "karakter kaldı", + "characters left": "karakter kaldı", + "feedbackSending": "Gönderiliyor", + "feedbackSent": "Teşekkürler", + "feedbackSendingError": "Yeniden dene" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/files/browser/editors/binaryFileEditor.i18n.json b/i18n/trk/src/vs/workbench/parts/files/browser/editors/binaryFileEditor.i18n.json new file mode 100644 index 00000000000..4c60c43f74a --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/files/browser/editors/binaryFileEditor.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "binaryFileEditor": "İkili Dosya Görüntüleyici" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/files/browser/editors/textFileEditor.i18n.json b/i18n/trk/src/vs/workbench/parts/files/browser/editors/textFileEditor.i18n.json new file mode 100644 index 00000000000..694dd68c041 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/files/browser/editors/textFileEditor.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "textFileEditor": "Metin Dosyası Düzenleyicisi", + "createFile": "Dosya Oluştur", + "fileEditorWithInputAriaLabel": "{0}. Metin dosyası düzenleyici.", + "fileEditorAriaLabel": "Metin dosyası düzenleyici." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/files/browser/fileActions.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/files/browser/fileActions.contribution.i18n.json new file mode 100644 index 00000000000..c9834694967 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/files/browser/fileActions.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "filesCategory": "Dosyalar", + "revealInSideBar": "Kenar Çubuğunda Ortaya Çıkar", + "acceptLocalChanges": "Yerel değişiklikleri kullan ve diskk içeriklerinin üzerine yaz", + "revertLocalChanges": "Yerel değişiklikleri göz ardı et ve diskteki içeriğe geri dön" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/files/browser/fileActions.i18n.json b/i18n/trk/src/vs/workbench/parts/files/browser/fileActions.i18n.json new file mode 100644 index 00000000000..6081aa828c7 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/files/browser/fileActions.i18n.json @@ -0,0 +1,73 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "retry": "Yeniden Dene", + "rename": "Yeniden Adlandır", + "newFile": "Yeni Dosya", + "newFolder": "Yeni Klasör", + "openFolderFirst": "İçinde dosyalar veya klasörler oluşturmak için ilk olarak bir klasör açın.", + "newUntitledFile": "Yeni İsimsiz Dosya", + "createNewFile": "Yeni Dosya", + "createNewFolder": "Yeni Klasör", + "deleteButtonLabelRecycleBin": "&&Geri Dönüşüm Kutusuna Taşı", + "deleteButtonLabelTrash": "&&Çöp Kutusuna Taşı", + "deleteButtonLabel": "&&Sil", + "dirtyMessageFolderOneDelete": "1 dosyada kaydedilmemiş değişiklik barındıran bir klasörü siliyorsunuz. Devam etmek istiyor musunuz?", + "dirtyMessageFolderDelete": "{0} dosyada kaydedilmemiş değişiklik barındıran bir klasörü siliyorsunuz. Devam etmek istiyor musunuz?", + "dirtyMessageFileDelete": "Kaydedilmemiş değişiklik barındıran bir dosyayı siliyorsunuz. Devam etmek istiyor musunuz?", + "dirtyWarning": "Değişiklikleriniz, kaydetmezseniz kaybolur.", + "confirmMoveTrashMessageFolder": "'{0}' ve içindekileri silmek istediğinizden emin misiniz?", + "confirmMoveTrashMessageFile": "'{0}' öğesini silmek istediğinize emin misiniz?", + "undoBin": "Geri dönüşüm kutusundan geri alabilirsiniz.", + "undoTrash": "Çöp kutusundan geri alabilirsiniz.", + "confirmDeleteMessageFolder": "'{0}' öğesini ve içindekileri kalıcı olarak silmek istediğinizden emin misiniz?", + "confirmDeleteMessageFile": "'{0}' öğesini kalıcı olarak silmek istediğinizden emin misiniz?", + "irreversible": "Bu eylem geri döndürülemez!", + "permDelete": "Kalıcı Olarak Sil", + "delete": "Sil", + "importFiles": "Dosya İçe Aktar", + "confirmOverwrite": "Hedef klasörde aynı ada sahip bir dosya veya klasör zaten var. Değiştirmek istiyor musunuz?", + "replaceButtonLabel": "&&Değiştir", + "copyFile": "Kopyala", + "pasteFile": "Yapıştır", + "duplicateFile": "Çoğalt", + "openToSide": "Yana Aç", + "compareSource": "Karşılaştırma İçin Seç", + "globalCompareFile": "Aktif Dosyayı Karşılaştır...", + "pickHistory": "Karşılaştırmak için daha önce açılan bir dosyayı seçin", + "unableToFileToCompare": "Seçtiğiniz dosya, '{0}' ile karşılaştırılamaz.", + "openFileToCompare": "Bir başka dosya ile karşılaştırmak için ilk olarak bir dosya açın.", + "compareWith": "'{0}' ile karşılaştır", + "compareFiles": "Dosyaları Karşılaştır", + "refresh": "Yenile", + "save": "Kaydet", + "saveAs": "Farklı Kaydet...", + "saveAll": "Tümünü Kaydet", + "saveAllInGroup": "Gruptaki Tümünü Kadet", + "saveFiles": "Kaydedilmemiş Değişiklikler İçeren Dosyaları Kaydet", + "revert": "Dosyayı Geri Döndür", + "focusOpenEditors": "Açık Düzenleyiciler Görünümüne Odakla", + "focusFilesExplorer": "Dosya Gezginine Odakla", + "showInExplorer": "Aktif Dosyayı Kenar Çubuğunda Ortaya Çıkar", + "openFileToShow": "Gezginde göstermek için ilk olarak bir dosya açın", + "collapseExplorerFolders": "Gezgindeki Klasörleri Daralt", + "refreshExplorer": "Gezgini Yenile", + "openFile": "Dosya Aç...", + "openFileInNewWindow": "Aktif Dosyayı Yeni Pencerede Aç", + "openFileToShowInNewWindow": "Yeni pencerede açmak için ilk olarak bir dosya açın", + "revealInWindows": "Gezginde Ortaya Çıkar", + "revealInMac": "Finder'da Ortaya Çıkar", + "openContainer": "İçeren Klasörü Aç", + "revealActiveFileInWindows": "Aktif Dosyayı Windows Gezgini'nde Ortaya Çıkar", + "revealActiveFileInMac": "Aktif Dosyayı Finder'da Ortaya Çıkar", + "openActiveFileContainer": "Aktif Dosyayı İçeren Klasörü Aç", + "copyPath": "Yolu Kopyala", + "copyPathOfActive": "Aktif Dosyanın Yolunu Kopyala", + "emptyFileNameError": "Bir dosya veya klasör adı sağlanması gerekiyor.", + "fileNameExistsError": "Bu konumda bir **{0}** dosyası veya klasörü zaten mevcut. Lütfen başka bir ad seçin.", + "invalidFileNameError": "**{0}** adı, bir dosya veya klasör adı olarak geçerli değildir. Lütfen başka bir ad seçin.", + "filePathTooLongError": "**{0}** adı çok uzun bir yol ile sonuçlanıyor. Lütfen daha kısa bir ad seçin." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/files/browser/fileCommands.i18n.json b/i18n/trk/src/vs/workbench/parts/files/browser/fileCommands.i18n.json new file mode 100644 index 00000000000..699305824d3 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/files/browser/fileCommands.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openFileToCopy": "Yolunu kopyalamak için ilk olarak bir dosya açın", + "openFileToReveal": "Ortaya çıkarmak için ilk olarak bir dosya açın" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/files/browser/files.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/files/browser/files.contribution.i18n.json new file mode 100644 index 00000000000..ab865812eb8 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/files/browser/files.contribution.i18n.json @@ -0,0 +1,41 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "showExplorerViewlet": "Gezgini Göster", + "explore": "Gezgin", + "view": "Görüntüle", + "textFileEditor": "Metin Dosyası Düzenleyicisi", + "binaryFileEditor": "İkili Dosya Düzenleyicisi", + "filesConfigurationTitle": "Dosyalar", + "exclude": "Dosya ve klasörleri hariç tutmak için glob desenlerini yapılandırın.", + "files.exclude.boolean": "Dosya yollarının eşleştirileceği glob deseni. Deseni etkinleştirmek veya devre dışı bırakmak için true veya false olarak ayarlayın.", + "files.exclude.when": "Eşleşen bir dosyanın eşdüzey dosyalarında ek denetim. Eşleşen dosya adı için değişken olarak $(basename) kullanın.", + "associations": "Dillerle dosya ilişkilendirmelerini yapılandırın (ör. \"*.uzanti\": \"html\"). Bunların, kurulu olan dillerin varsayılan ilişkilendirmeleri karşısında önceliği vardır.", + "encoding": "Dosyalar okunurken ve yazılırken kullanılacak varsayılan karakter kümesi kodlaması.", + "autoGuessEncoding": "Etkinleştirildiğinde, dosyaları açarken karakter kümesini tahmin etmeye çalışır", + "eol": "Varsayılan satır sonu karakteri. LF için \\n ve CRLF için \\r\\n kullan.", + "trimTrailingWhitespace": "Etkinleştirildiğinde, bir dosyayı kaydettiğinizde sondaki boşluk kırpılır.", + "insertFinalNewline": "Etkinleştirildiğinde, bir dosyayı kaydederken dosya sonuna bir boş satır ekler.", + "files.autoSave.off": "Kaydedilmemiş değişiklikler içeren bir dosya hiçbir zaman otomatik olarak kaydedilmez.", + "files.autoSave.afterDelay": "Kaydedilmemiş değişiklikler içeren bir dosya, 'files.autoSaveDelay' ayarlandıktan sonra otomatik olarak kaydedilir.", + "files.autoSave.onFocusChange": "Kaydedilmemiş değişiklikler içeren bir dosya, düzenleyici odaktan çıktığı an otomatik olarak kaydedilir.", + "files.autoSave.onWindowChange": "Kaydedilmemiş değişiklikler içeren bir dosya, pencere odaktan çıktığı an otomatik olarak kaydedilir.", + "autoSave": "Kaydedilmemiş değişiklikler içeren dosyaların otomatik kaydedilmesini denetler. Kabul edilen değerler: '{0}', '{1}', '{2}' (düzenleyici odaktan çıktığında), '{3}' (pencere odaktan çıktığında). '{4}' olarak ayarlanırsa, gecikmeyi 'files.autoSaveDelay' ile ayarlayabilirsiniz.", + "autoSaveDelay": "Kaydedilmemiş değişiklikler içeren bir dosyanın kaç ms gecikmeli otomatik olarak kaydedileceğini denetler. Sadece 'files.autoSave', '{0}' olarak ayarlandığında uygulanır.", + "watcherExclude": "Dosya izlemeden hariç tutulacak dosya yollarının glob desenlerini yapılandırın. Bu ayar değiştiğinde yeniden başlatma gerektirir. Code'un başlangıçta çok fazla CPU zamanı harcadığını görürseniz, başlangıç yüklemesini azaltmak için büyük klasörleri hariç tutabilirsiniz.", + "hotExit.off": "Hızlı çıkışı devre dışı bırak.", + "hotExit.onExit": "Hızlı çıkış, uygulama kapandığında tetiklenir, yani Windows/Linux'da son pencere kapandığında veya workbench.action.quit komutu tetiklendiği zaman (komut paleti, tuş bağı, menü). Bir sonraki başlatmada tüm pencereler yedekleriyle geri yüklenir.", + "hotExit.onExitAndWindowClose": "Hızlı çıkış, uygulama kapandığında tetiklenir, yani Windows/Linux'da son pencere kapandığında veya workbench.action.quit komutu tetiklendiği zaman (komut paleti, tuş bağı, menü), ve ayrıca son pencere olmasından bağımsız açık bir klasör bulunan herhangi bir pencere varsa. Bir sonraki başlatmada tüm pencereler yedekleriyle geri yüklenir. Klasör pencerelerini kapatılmadan önceki konumlarına geri yüklemek için \"window.restoreWindows\" ögesini \"all\" olarak ayarlayın.", + "hotExit": "Oturumlar arasında kaydedilmemiş dosyaların hatırlanıp hatırlanmayacağını denetler, düzenleyiciden çıkarken kaydetmek için izin istenmesi atlanacaktır.", + "defaultLanguage": "Yeni dosyalara atanan varsayılan dil modu.", + "editorConfigurationTitle": "Düzenleyici", + "formatOnSave": "Dosyayı kaydederken biçimlendir. Bir biçimlendirici mevcut olmalıdır, dosya otomatik olarak kaydedilmemelidir, ve düzenleyici kapanmıyor olmalıdır.", + "explorerConfigurationTitle": "Dosya Gezgini", + "openEditorsVisible": "Açık Editörler bölmesinde gösterilen düzenleyici sayısı. Bölmeyi gizlemek için 0 olarak ayarlayın.", + "dynamicHeight": "Açık düzenleyiciler bölümü yüksekliğinin öge sayısına göre dinamik olarak uyarlanıp uyarlanmayacağını denetler.", + "autoReveal": "Gezginin dosyaları açarken, onları otomatik olarak ortaya çıkartmasını ve seçmesini denetler.", + "enableDragAndDrop": "Gezgeinin sürükle bırak ile dosyaları ve klasörleri taşımaya izin verip vermeyeceğini denetler." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/files/browser/saveErrorHandler.i18n.json b/i18n/trk/src/vs/workbench/parts/files/browser/saveErrorHandler.i18n.json new file mode 100644 index 00000000000..09d9b7607bd --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/files/browser/saveErrorHandler.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "discard": "At", + "overwrite": "Üzerine Yaz", + "retry": "Yeniden Dene", + "readonlySaveError": "'{0}' kaydedilemedi: Dosya yazmaya karşı korunuyor. Korumayı kaldırmak için 'Üzerine Yaz'ı seçin.", + "genericSaveError": "'{0}' kaydedilemedi: ({1}).", + "staleSaveError": "'{0}' kaydedilemedi: Diskteki içerik daha yeni. Sizdeki sürüm ile disktekini karşılaştırmak için **Karşılaştır**a tıklayın.", + "compareChanges": "Karşılaştır", + "saveConflictDiffLabel": "{0} (diskte) ↔ {1} ({2} uygulamasında) - Kaydetme çakışmasını çöz", + "userGuide": "Değişikliklerinizi **geri al**mak veya diskteki içeriğin **üzerine yaz**mak için düzenleyicideki araç çubuğunu kullanabilirsiniz" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json b/i18n/trk/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json new file mode 100644 index 00000000000..298fda23b22 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/files/browser/views/emptyView.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "explorerSection": "Dosya Gezgini Bölümü", + "openFolder": "Klasör Aç" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/files/browser/views/explorerView.i18n.json b/i18n/trk/src/vs/workbench/parts/files/browser/views/explorerView.i18n.json new file mode 100644 index 00000000000..d8b937fc203 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/files/browser/views/explorerView.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "explorerSection": "Dosya Gezgini Bölümü", + "treeAriaLabel": "Dosya Gezgini" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/files/browser/views/explorerViewer.i18n.json b/i18n/trk/src/vs/workbench/parts/files/browser/views/explorerViewer.i18n.json new file mode 100644 index 00000000000..9dff53f0852 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/files/browser/views/explorerViewer.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "fileInputAriaLabel": "Dosya adı girin. Onaylamak için Enter'a, iptal etmek için Escape tuşuna basın.", + "filesExplorerViewerAriaLabel": "{0}, Dosya Gezgini", + "confirmOverwriteMessage": "'{0}' hedef klasörde zaten mevcut. Değiştirmek istiyor musunuz?", + "irreversible": "Bu eylem geri döndürülemez!", + "replaceButtonLabel": "&&Değiştir" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json b/i18n/trk/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json new file mode 100644 index 00000000000..aa9de346ffc --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/files/browser/views/openEditorsView.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openEditors": "Açık Düzenleyiciler", + "openEditosrSection": "Açık Düzenleyiciler Bölümü", + "treeAriaLabel": "Açık Düzenleyiciler: Aktif Dosyaların Listesi", + "dirtyCounter": "{0} kaydedilmemiş" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/files/browser/views/openEditorsViewer.i18n.json b/i18n/trk/src/vs/workbench/parts/files/browser/views/openEditorsViewer.i18n.json new file mode 100644 index 00000000000..172555e1368 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/files/browser/views/openEditorsViewer.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorGroupAriaLabel": "{0}, Düzenleyici Grubu", + "openEditorAriaLabel": "{0}, Açık Düzenleyici", + "saveAll": "Tümünü Kaydet", + "closeAllUnmodified": "Değiştirilmeyenleri Kapat", + "closeAll": "Tümünü Kapat", + "close": "Kapat", + "closeOthers": "Diğerlerini Kapat" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/files/common/dirtyFilesTracker.i18n.json b/i18n/trk/src/vs/workbench/parts/files/common/dirtyFilesTracker.i18n.json new file mode 100644 index 00000000000..0f88a5b2332 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/files/common/dirtyFilesTracker.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "dirtyFiles": "{0} kaydedilmemiş dosya" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json b/i18n/trk/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json new file mode 100644 index 00000000000..59355f869fc --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/files/common/editors/fileEditorInput.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "orphanedFile": "{0} (diskten silindi)" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/html/browser/html.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/html/browser/html.contribution.i18n.json new file mode 100644 index 00000000000..f9aa2193402 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/html/browser/html.contribution.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "html.editor.label": "Html Önizlemesi" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/html/browser/htmlPreviewPart.i18n.json b/i18n/trk/src/vs/workbench/parts/html/browser/htmlPreviewPart.i18n.json new file mode 100644 index 00000000000..13f1ae29ec6 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/html/browser/htmlPreviewPart.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "html.voidInput": "Geçersiz düzenleyici girdisi." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/html/browser/webview.i18n.json b/i18n/trk/src/vs/workbench/parts/html/browser/webview.i18n.json new file mode 100644 index 00000000000..cc23f3edf72 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/html/browser/webview.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "devtools.webview": "Geliştirici: Web Görünümü Araçları" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/markers/common/messages.i18n.json b/i18n/trk/src/vs/workbench/parts/markers/common/messages.i18n.json new file mode 100644 index 00000000000..80f988e1d75 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/markers/common/messages.i18n.json @@ -0,0 +1,39 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "viewCategory": "Görüntüle", + "problems.view.show.label": "Sorunları Göster", + "problems.panel.configuration.title": "Sorunlar Görünümü", + "problems.panel.configuration.autoreveal": "Sorunlar görünümünün; dosyalar açılırken, dosyaları otomatik olarak ortaya çıkarıp çıkarmayacağını denetler.", + "markers.panel.title.problems": "Sorunlar", + "markers.panel.aria.label.problems.tree": "Dosyalara göre gruplandırılmış sorunlar", + "markers.panel.no.problems.build": "Şu ana kadar çalışma alanında herhangi bir sorun tespit edilmedi.", + "markers.panel.no.problems.filters": "Belirtilen süzgeç ölçütleriyle sonuç bulunamadı", + "markers.panel.action.filter": "Sorunları Süz", + "markers.panel.filter.placeholder": "Türe veya metne göre süz", + "markers.panel.filter.errors": "hatalar", + "markers.panel.filter.warnings": "uyarılar", + "markers.panel.filter.infos": "bilgilendirmeler", + "markers.panel.single.error.label": "1 Hata", + "markers.panel.multiple.errors.label": "{0} Hata", + "markers.panel.single.warning.label": "1 Uyarı", + "markers.panel.multiple.warnings.label": "{0} Uyarı", + "markers.panel.single.info.label": "1 Bilgilendirme", + "markers.panel.multiple.infos.label": "{0} Bilgilendirme", + "markers.panel.single.unknown.label": "1 Bilinmeyen", + "markers.panel.multiple.unknowns.label": "{0} Bilinmeyen", + "markers.panel.at.ln.col.number": "({0}, {1})", + "problems.tree.aria.label.resource": "{0} {1} sorun içeriyor", + "problems.tree.aria.label.error.marker": "{0} tarafından oluşturulan hata: {2}. satırın {3}. karakterinde {1}", + "problems.tree.aria.label.error.marker.nosource": "Hata: {1}. satırın {2}. karakterinde {0}", + "problems.tree.aria.label.warning.marker": "{0} tarafından oluşturulan uyarı: {2}. satırın {3}. karakterinde {1}", + "problems.tree.aria.label.warning.marker.nosource": "Uyarı: {1}. satırın {2}. karakterinde {0}", + "problems.tree.aria.label.info.marker": "{0} tarafından oluşturulan bilgilendirme: {2}. satırın {3}. karakterinde {1}", + "problems.tree.aria.label.info.marker.nosource": "Bilgilendirme: {1}. satırın {2}. karakterinde {0}", + "problems.tree.aria.label.marker": "{0} tarafından oluşturulan sorun: {2}. satırın {3}. karakterinde {1}", + "problems.tree.aria.label.marker.nosource": "Sorun: {1}. satırın {2}. karakterinde {0}", + "errors.warnings.show.label": "Hataları ve Uyarıları Göster" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/markers/electron-browser/markersElectronContributions.i18n.json b/i18n/trk/src/vs/workbench/parts/markers/electron-browser/markersElectronContributions.i18n.json new file mode 100644 index 00000000000..22387f166cb --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/markers/electron-browser/markersElectronContributions.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "copyMarker": "Kopyala" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/nps/electron-browser/nps.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/nps/electron-browser/nps.contribution.i18n.json new file mode 100644 index 00000000000..821add9841d --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/nps/electron-browser/nps.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "surveyQuestion": "Hızlı bir geri bildirim anketine katılmak ister misiniz?", + "takeSurvey": "Ankete Katıl", + "remindLater": "Daha Sonra Hatırlat", + "neverAgain": "Tekrar Gösterme" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/output/browser/output.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/output/browser/output.contribution.i18n.json new file mode 100644 index 00000000000..fe8f6125b1a --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/output/browser/output.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "output": "Çıktı", + "viewCategory": "Görüntüle", + "clearOutput.label": "Çıktıyı Temizle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/output/browser/outputActions.i18n.json b/i18n/trk/src/vs/workbench/parts/output/browser/outputActions.i18n.json new file mode 100644 index 00000000000..c4f84392df6 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/output/browser/outputActions.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleOutput": "Çıktıyı Aç/Kapat", + "clearOutput": "Çıktıyı Temizle", + "toggleOutputScrollLock": "Çıktı Kaydırma Kilidini Aç/Kapat", + "switchToOutput.label": "Çıktıya Geçiş Yap" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/output/browser/outputPanel.i18n.json b/i18n/trk/src/vs/workbench/parts/output/browser/outputPanel.i18n.json new file mode 100644 index 00000000000..1fde8c9ce8a --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/output/browser/outputPanel.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "outputPanelWithInputAriaLabel": "{0}, Çıktı paneli", + "outputPanelAriaLabel": "Çıktı paneli" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/output/common/output.i18n.json b/i18n/trk/src/vs/workbench/parts/output/common/output.i18n.json new file mode 100644 index 00000000000..cfbabebaa61 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/output/common/output.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "output": "Çıktı", + "channel": "'{0}' için" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json new file mode 100644 index 00000000000..dc3e6110e34 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/performance/electron-browser/performance.contribution.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "slow": "Yavaş başlangıç tespit edildi", + "slow.detail": "Az önce yavaş başlangıç yaşadığınız için üzgünüz. Lütfen '{0}' uygulamasını profil oluşturucu etkinleştirilmiş olarak başlatın, profilleri bizle paylaşın, ve biz de başlangıcı yeniden harika yapmak için çok çalışalım.", + "prof.message": "Profiller başarıyla oluşturuldu.", + "prof.detail": "Lütfen bir sorun (bildirimi) oluşturun ve aşağıdaki dosyaları manuel olarak ekleyin:\n{0}", + "prof.restartAndFileIssue": "Sorun Oluştur ve Yeniden Başlat", + "prof.restart": "Yeniden Başlat", + "prof.thanks": "Bize yardımcı olduğunuz için teşekkürler.", + "prof.detail.restart": "'{0}' uygulamasını kullanmaya devam etmek için son bir yeniden başlatma gerekiyor. Katkılarınız için tekrar teşekkür ederiz." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/preferences/browser/keybindingWidgets.i18n.json b/i18n/trk/src/vs/workbench/parts/preferences/browser/keybindingWidgets.i18n.json new file mode 100644 index 00000000000..68b1055180c --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/preferences/browser/keybindingWidgets.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defineKeybinding.initial": "İstenen tuş kombinasyonuna basın ve daha sonra ENTER'a basın. İptal etmek için ESCAPE tuşuna basın.", + "defineKeybinding.chordsTo": "ardından" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json b/i18n/trk/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json new file mode 100644 index 00000000000..a67e224c963 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/preferences/browser/keybindingsEditor.i18n.json @@ -0,0 +1,35 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "keybindingsInputName": "Klavye Kısayolları", + "SearchKeybindings.AriaLabel": "Tuş bağlarını ara", + "SearchKeybindings.Placeholder": "Tuş bağlarını ara", + "sortByPrecedene": "Önceliğe Göre Sırala", + "header-message": "Gelişmiş özelleştirmeler için açın ve düzenleyin", + "keybindings-file-name": "keybindings.json", + "keybindingsLabel": "Tuş bağları", + "changeLabel": "Tuş Bağını Değiştir", + "addLabel": "Tuş Bağını Ekle", + "removeLabel": "Tuş Bağını Kaldır", + "resetLabel": "Tuş Bağını Sıfırla", + "showConflictsLabel": "Çakışmaları Göster", + "copyLabel": "Kopyala", + "error": "Tuş bağını düzenlerken '{0}' hatası. Lütfen 'keybindings.json' dosyasını açın ve kontrol edin.", + "command": "Command", + "keybinding": "Tuş bağı", + "source": "Kaynak", + "when": "Koşul", + "editKeybindingLabelWithKey": "{0} Tuş Bağını Değiştir", + "editKeybindingLabel": "Tuş Bağını Değiştir", + "addKeybindingLabelWithKey": "{0} Tuş Bağını Ekle", + "addKeybindingLabel": "Tuş Bağını Ekle", + "commandAriaLabel": "Komut {0}'dır.", + "keybindingAriaLabel": "Tuş bağı {0}'dır.", + "noKeybinding": "Tuş bağı atanmamış.", + "sourceAriaLabel": "Kaynak {0}'dır.", + "whenAriaLabel": "Koşul {0} şeklindedir.", + "noWhen": "Koşul içeriği yok." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json b/i18n/trk/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json new file mode 100644 index 00000000000..15d8c9861ae --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/preferences/browser/keybindingsEditorContribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defineKeybinding.start": "Tuş Bağı Tanımla", + "defineKeybinding.kbLayoutErrorMessage": "Bu tuş kombinasyonunu geçerli klavye düzeninizde üretemeyeceksiniz.", + "defineKeybinding.kbLayoutLocalAndUSMessage": "Geçerli klavye düzeniniz için **{0}** (Birleşik Devletler standardı için **{1}**).", + "defineKeybinding.kbLayoutLocalMessage": "Geçerli klavye düzeniniz için **{0}**." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/preferences/browser/preferences.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/preferences/browser/preferences.contribution.i18n.json new file mode 100644 index 00000000000..76c31109169 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/preferences/browser/preferences.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defaultPreferencesEditor": "Varsayılan Tercihler Düzenleyicisi", + "keybindingsEditor": "Tuş Bağları Düzenleyicisi", + "preferences": "Tercihler" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json b/i18n/trk/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json new file mode 100644 index 00000000000..0a5d1d96e7e --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/preferences/browser/preferencesActions.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openGlobalSettings": "Kullanıcı Ayarlarını Aç", + "openGlobalKeybindings": "Klavye Kısayollarını Aç", + "openGlobalKeybindingsFile": "Klavye Kısayolları Dosyasını Aç", + "openWorkspaceSettings": "Çalışma Alanı Ayarlarını Aç", + "configureLanguageBasedSettings": "Dile Özel Ayarları Yapılandır...", + "languageDescriptionConfigured": "({0})", + "pickLanguage": "Dili Seç" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/preferences/browser/preferencesEditor.i18n.json b/i18n/trk/src/vs/workbench/parts/preferences/browser/preferencesEditor.i18n.json new file mode 100644 index 00000000000..be88513af74 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/preferences/browser/preferencesEditor.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "settingsEditorName": "Varsayılan Ayarlar", + "SearchSettingsWidget.AriaLabel": "Ayarları ara", + "SearchSettingsWidget.Placeholder": "Ayarları Ara", + "totalSettingsMessage": "Toplam {0} Ayar", + "noSettingsFound": "Sonuç Yok", + "oneSettingFound": "1 ayar eşleşti", + "settingsFound": "{0} ayar eşleşti", + "preferencesAriaLabel": "Varsayılan tercihler. Salt okunabilir metin editörü." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json b/i18n/trk/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json new file mode 100644 index 00000000000..68b7788b3e0 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/preferences/browser/preferencesRenderers.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "errorInvalidConfiguration": "Ayarlara yazılamıyor. Lütfen dosyadaki hataları/uyarıları düzeltin ve tekrar deneyin.", + "editTtile": "Düzenle", + "replaceDefaultValue": "Ayarlarda Değiştir", + "copyDefaultValue": "Ayarlara Kopyala", + "unsupportedPHPExecutablePathSetting": "Bu ayar, bir Kullanıcı Ayarı olmalıdır. PHP'yi çalışma alanı için yapılandırmak için bir PHP dosyasını açın ve durum çubuğundaki 'PHP Yolu'na tıklayın.", + "unsupportedWorkspaceSetting": "Bu ayar, bir Kullanıcı Ayarı olmalıdır." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/preferences/browser/preferencesService.i18n.json b/i18n/trk/src/vs/workbench/parts/preferences/browser/preferencesService.i18n.json new file mode 100644 index 00000000000..edeac2f6a8e --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/preferences/browser/preferencesService.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openFolderFirst": "Çalışma alanı ayarları oluşturmak için ilk olarak bir klasör açın", + "emptyKeybindingsHeader": "Varsayılanların üzerine yazmak için tuş bağlarınızı bu dosyaya yerleştirin", + "defaultKeybindings": "Varsayılan Tuş Bağları", + "emptySettingsHeader": "Varsayılan ayarların üzerine yazmak için ayarlarınızı bu dosyaya yerleştirin.", + "emptySettingsHeader1": "Varsayılan ayarların ve kullanıcı ayarlarının üzerine yazmak için ayarlarınızı bu dosyaya yerleştirin.", + "fail.createSettings": " '{0}' oluşturulamadı ({1})." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/preferences/browser/preferencesWidgets.i18n.json b/i18n/trk/src/vs/workbench/parts/preferences/browser/preferencesWidgets.i18n.json new file mode 100644 index 00000000000..1814392bc96 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/preferences/browser/preferencesWidgets.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "settingsSwitcherBarAriaLabel": "Ayar Değiştirici", + "userSettings": "Kullanıcı Ayarları", + "workspaceSettings": "Çalışma Alanı Ayarları" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.i18n.json b/i18n/trk/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.i18n.json new file mode 100644 index 00000000000..90483c4e7e3 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/preferences/common/keybindingsEditorModel.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "default": "Varsayılan", + "user": "Kullanıcı", + "meta": "meta", + "option": "seçenek" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/preferences/common/preferencesModels.i18n.json b/i18n/trk/src/vs/workbench/parts/preferences/common/preferencesModels.i18n.json new file mode 100644 index 00000000000..dc4c28efe52 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/preferences/common/preferencesModels.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "commonlyUsed": "Yaygın Olarak Kullanılan", + "defaultKeybindingsHeader": "Tuş bağları dosyanıza yerleştirerek tuş bağlarının üzerine yazın." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json b/i18n/trk/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json new file mode 100644 index 00000000000..bef4db281ad --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/quickopen/browser/commandsHandler.i18n.json @@ -0,0 +1,19 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "showTriggerActions": "Tüm Komutları Göster", + "clearCommandHistory": "Komut Geçmişini Temizle", + "showCommands.label": "Komut Paleti...", + "entryAriaLabelWithKey": "{0}, {1}, komutlar", + "entryAriaLabel": "{0}, komutlar", + "canNotRun": "'{0}' komutu buradan çalıştırılamıyor.", + "actionNotEnabled": "'{0}' komutu geçerli bağlamda etkin değil.", + "recentlyUsed": "yakınlarda kullanıldı", + "morecCommands": "diğer komutlar", + "commandLabel": "{0}: {1}", + "cat.title": "{0}: {1}", + "noCommandsMatching": "Eşleşen komut yok" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/quickopen/browser/gotoLineHandler.i18n.json b/i18n/trk/src/vs/workbench/parts/quickopen/browser/gotoLineHandler.i18n.json new file mode 100644 index 00000000000..3d256651499 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/quickopen/browser/gotoLineHandler.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "gotoLine": "Satıra Git...", + "gotoLineLabelEmptyWithLimit": "Gitmek için 1 ile {0} arasında bir satır numarası yazın", + "gotoLineLabelEmpty": "Gidilecek satır numarasını yazın", + "gotoLineColumnLabel": "{0}. satırın {1}. karakterine git", + "gotoLineLabel": "{0} satırına git", + "gotoLineHandlerAriaLabel": "Gidilecek satır numarasını yazın.", + "cannotRunGotoLine": "Satıra gitmek için ilk olarak bir metin dosyası açın" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/quickopen/browser/gotoSymbolHandler.i18n.json b/i18n/trk/src/vs/workbench/parts/quickopen/browser/gotoSymbolHandler.i18n.json new file mode 100644 index 00000000000..0dfa60b61a4 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/quickopen/browser/gotoSymbolHandler.i18n.json @@ -0,0 +1,34 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "gotoSymbol": "Dosyada Sembole Git...", + "symbols": "semboller ({0})", + "method": "yöntemler ({0})", + "function": "fonksiyonlar ({0})", + "_constructor": "oluşturucular ({0})", + "variable": "değişkenler ({0})", + "class": "sınıflar ({0})", + "interface": "arayüzler ({0})", + "namespace": "isim alanları ({0})", + "package": "paketler ({0})", + "modules": "modüller ({0})", + "property": "özellikler ({0})", + "enum": "numaralandırmalar ({0})", + "string": "dizeler ({0})", + "rule": "kurallar ({0})", + "file": "dosyalar ({0})", + "array": "diziler ({0})", + "number": "sayılar ({0})", + "boolean": "boole değerleri ({0})", + "object": "nesneler ({0})", + "key": "anahtarlar ({0})", + "entryAriaLabel": "{0}, semboller", + "noSymbolsMatching": "Eşleşen sembol yok", + "noSymbolsFound": "Sembol bulunamadı", + "gotoSymbolHandlerAriaLabel": "Geçerli düzenleyicideki sembolleri daraltmak için yazmaya başlayın.", + "cannotRunGotoSymbolInFile": "Dosya için sembol bilgisi yok", + "cannotRunGotoSymbol": "Sembole gitmek için ilk olarak bir metin dosyası açın" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/quickopen/browser/helpHandler.i18n.json b/i18n/trk/src/vs/workbench/parts/quickopen/browser/helpHandler.i18n.json new file mode 100644 index 00000000000..81a2056121e --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/quickopen/browser/helpHandler.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, seçici yardımı", + "globalCommands": "genel komutlar", + "editorCommands": "düzenleyici komutları" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.i18n.json new file mode 100644 index 00000000000..fe14853bad6 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/quickopen/browser/quickopen.contribution.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "commandsHandlerDescriptionDefault": "Komutları Göster ve Çalıştır", + "gotoLineDescriptionMac": "Satıra Git", + "gotoLineDescriptionWin": "Satıra Git", + "gotoSymbolDescription": "Dosyada Sembole Git", + "gotoSymbolDescriptionScoped": "Kategoriye Göre Dosyada Sembole Git", + "helpDescription": "Yardımı Göster", + "viewPickerDescription": "Görünümü Aç" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/quickopen/browser/viewPickerHandler.i18n.json b/i18n/trk/src/vs/workbench/parts/quickopen/browser/viewPickerHandler.i18n.json new file mode 100644 index 00000000000..4451c9909c1 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/quickopen/browser/viewPickerHandler.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, görünüm seçici", + "views": "Görünümler", + "panels": "Paneller", + "terminals": "Terminal", + "terminalTitle": "{0}: {1}", + "channels": "Çıktı", + "openView": "Görünümü Aç", + "quickOpenView": "Görünümü Hızlı Aç" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json new file mode 100644 index 00000000000..b803c2770e7 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/relauncher/electron-browser/relauncher.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "relaunchMessage": "Yürürlüğe girmesi için yeniden başlatma gerektiren bir ayar değişti.", + "relaunchDetail": "{0} uygulamasını yeniden başlatmak ve bu ayarı etkinleştirmek için lütfen yeniden başlat butonuna basın.", + "restart": "Yeniden Başlat" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json b/i18n/trk/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json new file mode 100644 index 00000000000..bc11b3fbd68 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/scm/electron-browser/dirtydiffDecorator.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorGutterModifiedBackground": "Değiştirilen satırlar için düzenleyici oluğu arka plan rengi.", + "editorGutterAddedBackground": "Eklenen satırlar için düzenleyici oluğu arka plan rengi.", + "editorGutterDeletedBackground": "Silinen satırlar için düzenleyici oluğu arka plan rengi." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json new file mode 100644 index 00000000000..2fc322d2c8b --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/scm/electron-browser/scm.contribution.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "toggleGitViewlet": "Git'i Göster", + "installAdditionalSCMProviders": "Ek SCM Sağlayıcıları Yükle...", + "source control": "Kaynak Kontrolü", + "toggleSCMViewlet": "SCM'yi Göster", + "view": "Görüntüle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/scm/electron-browser/scmActivity.i18n.json b/i18n/trk/src/vs/workbench/parts/scm/electron-browser/scmActivity.i18n.json new file mode 100644 index 00000000000..e50c48abb0e --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/scm/electron-browser/scmActivity.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "scmPendingChangesBadge": "{0} bekleyen değişiklik" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json b/i18n/trk/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json new file mode 100644 index 00000000000..560a8a41990 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/scm/electron-browser/scmMenus.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "installAdditionalSCMProviders": "Ek SCM Sağlayıcıları Yükle...", + "switch provider": "SCM Sağlayıcısı Değiştir..." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/scm/electron-browser/scmViewlet.i18n.json b/i18n/trk/src/vs/workbench/parts/scm/electron-browser/scmViewlet.i18n.json new file mode 100644 index 00000000000..cd21a41cb42 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/scm/electron-browser/scmViewlet.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "commitMessage": "Mesaj (commit'lemek için {0} tuşlarına basın)", + "source control": "Kaynak Kontrolü", + "viewletTitle": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/search/browser/openAnythingHandler.i18n.json b/i18n/trk/src/vs/workbench/parts/search/browser/openAnythingHandler.i18n.json new file mode 100644 index 00000000000..248e4e17c5b --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/search/browser/openAnythingHandler.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "fileAndTypeResults": "dosya ve sembol sonuçları", + "fileResults": "dosya sonuçları" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/search/browser/openFileHandler.i18n.json b/i18n/trk/src/vs/workbench/parts/search/browser/openFileHandler.i18n.json new file mode 100644 index 00000000000..31b328bf639 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/search/browser/openFileHandler.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, dosya seçici", + "searchResults": "arama sonuçları" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/search/browser/openSymbolHandler.i18n.json b/i18n/trk/src/vs/workbench/parts/search/browser/openSymbolHandler.i18n.json new file mode 100644 index 00000000000..94ab4f45824 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/search/browser/openSymbolHandler.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, sembol seçici", + "symbols": "sembol sonuçları", + "noSymbolsMatching": "Eşleşen sembol yok", + "noSymbolsWithoutInput": "Sembolleri aramak için yazmaya başlayın" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/search/browser/patternInputWidget.i18n.json b/i18n/trk/src/vs/workbench/parts/search/browser/patternInputWidget.i18n.json new file mode 100644 index 00000000000..55adfb8b090 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/search/browser/patternInputWidget.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "defaultLabel": "giriş", + "patternDescription": "Glob Desenlerini Kullan", + "patternHelpInclude": "Eşleşecek kalıp. ör. tüm JavaScript dosyaları ile eşleşmek için **\\*\\*/*.js** veya bir klasör ve tüm alt elemanları ile eşleşmek için **myFolder/\\*\\***.  \n\n**Başvuru**:\n**\\*** 0 veya daha fazla karakterle eşleşir\n**?** 1 karakterle eşleşir\n**\\*\\*** sıfır veya daha fazla klasörle eşleşir\n**[a-z]** bir karakterler aralığı ile eşleşir\n**{a,b}** kalıplardan herhangi biri ile eşleşir)", + "useIgnoreFilesDescription": "Yok Sayma Dosyalarını Kullan", + "useExcludeSettingsDescription": "Hariç Tutma Ayarlarını Kullan" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/search/browser/replaceService.i18n.json b/i18n/trk/src/vs/workbench/parts/search/browser/replaceService.i18n.json new file mode 100644 index 00000000000..279186adb71 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/search/browser/replaceService.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "fileReplaceChanges": "{0} ↔ {1} (Değiştirme Önizlemesi)" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/search/browser/search.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/search/browser/search.contribution.i18n.json new file mode 100644 index 00000000000..31355023a76 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/search/browser/search.contribution.i18n.json @@ -0,0 +1,22 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "showTriggerActions": "Çalışma Alanında Sembole Git...", + "name": "Ara", + "showSearchViewlet": "Aramayı Göster", + "view": "Görüntüle", + "findInFiles": "Dosyalarda Bul", + "openAnythingHandlerDescription": "Dosyaya Git", + "openSymbolDescriptionNormal": "Çalışma Alanında Sembole Git", + "searchOutputChannelTitle": "Ara", + "searchConfigurationTitle": "Ara", + "exclude": "Aramalarda dosyaları ve klasörleri hariç tutmak için glob desenlerini yapılandırın. files.exclude ayarından, tüm glob desenlerini devralır.", + "exclude.boolean": "Dosya yollarının eşleştirileceği glob deseni. Deseni etkinleştirmek veya devre dışı bırakmak için true veya false olarak ayarlayın.", + "exclude.when": "Eşleşen bir dosyanın eşdüzey dosyalarında ek denetim. Eşleşen dosya adı için değişken olarak $(basename) kullanın.", + "useRipgrep": "Metin aramasında Ripgrep kullanılıp kullanılmayacağını denetler", + "useIgnoreFilesByDefault": "Yeni bir çalışma alanında arama yaparken .gitignore ve .ignore dosyalarının varsayılan olarak kullanılıp kullanılmayacağını denetler.", + "search.quickOpen.includeSymbols": "Dosya sonuçlarındaki bir global sembol aramasının sonuçlarının Hızlı Aç'a dahil edilip edilmeyeceğini yapılandırın." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/search/browser/searchActions.i18n.json b/i18n/trk/src/vs/workbench/parts/search/browser/searchActions.i18n.json new file mode 100644 index 00000000000..8b542968177 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/search/browser/searchActions.i18n.json @@ -0,0 +1,21 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "nextSearchTerm": "Sonraki Arama Terimini Göster", + "previousSearchTerm": "Önceki Arama Terimini Göster", + "focusNextInputBox": "Sonraki Girdi Kutusuna Odakla", + "focusPreviousInputBox": "Önceki Girdi Kutusuna Odakla", + "replaceInFiles": "Dosyalardakileri Değiştir", + "findInFolder": "Klasörde Bul", + "RefreshAction.label": "Yenile", + "ClearSearchResultsAction.label": "Arama Sonuçlarını Temizle", + "FocusNextSearchResult.label": "Sonraki Arama Sonucuna Odakla", + "FocusPreviousSearchResult.label": "Önceki Arama Sonucuna Odakla", + "RemoveAction.label": "Kaldır", + "file.replaceAll.label": "Tümünü Değiştir", + "match.replace.label": "Değiştir", + "ConfigureGlobalExclusionsAction.label": "Ayarları Aç" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json b/i18n/trk/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json new file mode 100644 index 00000000000..f94aa8eb873 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/search/browser/searchResultsView.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "searchMatches": "{0} eşleşme bulundu", + "searchMatch": "{0} eşleşme bulundu", + "fileMatchAriaLabel": "{2} klasöründeki {1} dosyasında {0} eşleşme, Arama sonucu", + "replacePreviewResultAria": "{3} metinli satırdaki {2}. sütunda {1} ile arama terimi {0}", + "searchResultAria": "{2} metinli satırdaki {1}. sütunda terim {0} bulundu" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/search/browser/searchViewlet.i18n.json b/i18n/trk/src/vs/workbench/parts/search/browser/searchViewlet.i18n.json new file mode 100644 index 00000000000..a2fb1ccddfd --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/search/browser/searchViewlet.i18n.json @@ -0,0 +1,50 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "moreSearch": "Arama Detaylarını Aç/Kapat", + "searchScope.includes": "dahil edilecek dosyalar", + "label.includes": "Aramaya Dahil Edilen Kalıplar", + "searchScope.excludes": "hariç tutulacak klasörler", + "label.excludes": "Aramada Hariç Tutulan Kalıplar", + "global.searchScope.folders": "ayarlar ile hariç tutulan dosyalar", + "label.global.excludes": "Yapılandırılmış Aramada Hariç Tutulan Kalıplar", + "replaceAll.confirmation.title": "Tümünü Değiştir", + "replaceAll.confirm.button": "Değiştir", + "replaceAll.occurrence.file.message": "{1} dosyadaki {0} tekrarlama '{2}' ile değiştirildi.", + "removeAll.occurrence.file.message": "{1} dosyadaki {0} tekrarlama değiştirildi.", + "replaceAll.occurrence.files.message": "{1} dosyadaki {0} tekrarlama '{2}' ile değiştirildi.", + "removeAll.occurrence.files.message": "{1} dosyadaki {0} tekrarlama değiştirildi.", + "replaceAll.occurrences.file.message": "{1} dosyadaki {0} tekrarlama '{2}' ile değiştirildi.", + "removeAll.occurrences.file.message": "{1} dosyadaki {0} tekrarlama değiştirildi.", + "replaceAll.occurrences.files.message": "{1} dosyadaki {0} tekrarlama '{2}' ile değiştirildi.", + "removeAll.occurrences.files.message": "{1} dosyadaki {0} tekrarlama değiştirildi.", + "removeAll.occurrence.file.confirmation.message": "{1} dosyadaki {0} tekralama '{2}' ile değiştirilsin mi?", + "replaceAll.occurrence.file.confirmation.message": "{1} dosyadaki {0} tekrarlama değiştirilsin mi?", + "removeAll.occurrence.files.confirmation.message": "{1} dosyadaki {0} tekralama '{2}' ile değiştirilsin mi?", + "replaceAll.occurrence.files.confirmation.message": "{1} dosyadaki {0} tekrarlama değiştirilsin mi?", + "removeAll.occurrences.file.confirmation.message": "{1} dosyadaki {0} tekralama '{2}' ile değiştirilsin mi?", + "replaceAll.occurrences.file.confirmation.message": "{1} dosyadaki {0} tekrarlama değiştirilsin mi?", + "removeAll.occurrences.files.confirmation.message": "{1} dosyadaki {0} tekralama '{2}' ile değiştirilsin mi?", + "replaceAll.occurrences.files.confirmation.message": "{1} dosyadaki {0} tekrarlama değiştirilsin mi?", + "treeAriaLabel": "Arama Sonuçları", + "globLabel": "{1} olduğunda {0}", + "searchMaxResultsWarning": "Sonuç kümesi yalnızca tüm eşleşmelerin bir alt kümesini içerir. Lütfen sonuçları daraltmak için aramanızda daha fazla ayrıntı belirtin.", + "searchCanceled": "Arama, hiçbir sonuç bulunamadan iptal edildi - ", + "noResultsIncludesExcludes": "'{0}' içinde '{1}' hariç tutularak sonuç bulunamadı - ", + "noResultsIncludes": "'{0}' içinde sonuç bulunamadı - ", + "noResultsExcludes": "'{0}' hariç tutularak sonuç bulunamadı - ", + "noResultsFound": "Sonuç bulunamadı. Yapılandırılan hariç tutmalar için ayarlarınızı gözden geçirin - ", + "rerunSearch.message": "Yeniden ara", + "rerunSearchInAll.message": "Tüm dosyalarda yeniden ara", + "openSettings.message": "Ayarları Aç", + "ariaSearchResultsStatus": "Arama ile {1} dosyada {0} sonuç bulundu", + "search.file.result": "{1} dosyada {0} sonuç", + "search.files.result": "{1} dosyada {0} sonuç", + "search.file.results": "{1} dosyada {0} sonuç", + "search.files.results": "{1} dosyada {0} sonuç", + "searchWithoutFolder": "Henüz bir klasör açmadınız. Şu an sadece açık dosyalar aranıyor - ", + "openFolder": "Klasör Aç" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/search/browser/searchWidget.i18n.json b/i18n/trk/src/vs/workbench/parts/search/browser/searchWidget.i18n.json new file mode 100644 index 00000000000..ed5a49ea8ea --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/search/browser/searchWidget.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "search.action.replaceAll.disabled.label": "Tümünü Değiştir (Etkinleştirmek İçin Aramayı Gönderin)", + "search.action.replaceAll.enabled.label": "Tümünü Değiştir", + "search.replace.toggle.button.title": "Değiştirmeyi Aç/Kapat", + "label.Search": "Ara: Arama Terimi girin ve aramak için Enter'a, iptal etmek için Escape tuşuna basın", + "search.placeHolder": "Ara", + "label.Replace": "Değiştir: Değiştirme terimini girin ve önizlemek için Enter'a, iptal etmek için Escape tuşuna basın", + "search.replace.placeHolder": "Değiştir", + "regexp.validationFailure": "İfade her öğe ile eşleşiyor" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json b/i18n/trk/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json new file mode 100644 index 00000000000..07bddc32f48 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/snippets/electron-browser/TMSnippets.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.snippets": "Parçacıklara ekleme yapar.", + "vscode.extension.contributes.snippets-language": "Bu parçacığın ekleneceği dilin tanımlayıcısı.", + "vscode.extension.contributes.snippets-path": "Parçacıklar dosyasının yolu. Yol, eklenti klasörüne görecelidir ve genellikle './snippets/' ile başlar.", + "invalid.language": "`contributes.{0}.language` ögesinde bilinmeyen dil. Sağlanan değer: {1}", + "invalid.path.0": "`contributes.{0}.path` ögesinde dize bekleniyor. Sağlanan değer: {1}", + "invalid.path.1": "`contributes.{0}.path` ögesinin ({1}) eklentinin klasöründe ({2}) yer alması bekleniyor. Bu, eklentiyi taşınamaz yapabilir.", + "badVariableUse": "\"{0}\"-parçacığı yüksek olasılıkla parçacık değişkenleri ile parçacık yer tutucularını karıştırıyor. Daha fazla bilgi için https://code.visualstudio.com/docs/editor/userdefinedsnippets#_snippet-syntax adresini ziyaret edin." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/snippets/electron-browser/insertSnippet.i18n.json b/i18n/trk/src/vs/workbench/parts/snippets/electron-browser/insertSnippet.i18n.json new file mode 100644 index 00000000000..c8734bde48f --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/snippets/electron-browser/insertSnippet.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "snippet.suggestions.label": "Parçacık Ekle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json new file mode 100644 index 00000000000..757de65d2f2 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/snippets/electron-browser/snippets.contribution.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "openSnippet.label": "Kullanıcı Parçacıklarını Aç", + "openSnippet.pickLanguage": "Parçacık için Dil seçin", + "openSnippet.errorOnCreate": "{0} oluşturulamadı", + "preferences": "Tercihler", + "snippetSchema.json.default": "Boş parçacık", + "snippetSchema.json": "Kullanıcı parçacığı yapılandırması", + "snippetSchema.json.prefix": "Parçacığı IntelliSense'de seçerken kullanılacak ön ek", + "snippetSchema.json.body": "Parçacık içeriği. İmleç konumlarını tanımlamak için '$1', '${1:varsayilanMetin}' kullanın, en son imleç konumu için '$0' kullanın. Değişken değerlerini '${degiskenAdi}' ve '${degiskenAdi:varsayilanMetin}' ile ekleyin, ör. 'Bu bir dosyadır: $TM_FILENAME'.", + "snippetSchema.json.description": "Parçacık açıklaması." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/snippets/electron-browser/snippetsService.i18n.json b/i18n/trk/src/vs/workbench/parts/snippets/electron-browser/snippetsService.i18n.json new file mode 100644 index 00000000000..67496ec0c54 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/snippets/electron-browser/snippetsService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "detail.userSnippet": "Kullanıcı Parçacığı", + "snippetSuggest.longLabel": "{0}, {1}" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/snippets/electron-browser/tabCompletion.i18n.json b/i18n/trk/src/vs/workbench/parts/snippets/electron-browser/tabCompletion.i18n.json new file mode 100644 index 00000000000..534c795a836 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/snippets/electron-browser/tabCompletion.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tabCompletion": "Ön ekleri eşleştiğinde parçacıkları ekleyin. 'quickSuggestions' etkinleştirilmediği zaman en iyi şekilde çalışır." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json new file mode 100644 index 00000000000..e284a5a8da8 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/surveys/electron-browser/languageSurveys.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "helpUs": "{0} için hizmetimizi iyileştirmemize yardımcı olun", + "takeShortSurvey": "Kısa Ankete Katıl", + "remindLater": "Daha Sonra Hatırlat", + "neverAgain": "Tekrar Gösterme" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json new file mode 100644 index 00000000000..821add9841d --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/surveys/electron-browser/nps.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "surveyQuestion": "Hızlı bir geri bildirim anketine katılmak ister misiniz?", + "takeSurvey": "Ankete Katıl", + "remindLater": "Daha Sonra Hatırlat", + "neverAgain": "Tekrar Gösterme" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json b/i18n/trk/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json new file mode 100644 index 00000000000..6d47af97b30 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/tasks/browser/buildQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksAriaLabel": "Bir derleme görevinin adını girin", + "noTasksMatching": "Eşleşen görev yok", + "noTasksFound": "Derleme görevi bulunamadı" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json b/i18n/trk/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json new file mode 100644 index 00000000000..f17885f7a72 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/tasks/browser/quickOpen.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "entryAriaLabel": "{0}, görevler", + "customizeTask": "Görevi Özelleştir" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json b/i18n/trk/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json new file mode 100644 index 00000000000..d0d2568cfbd --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/tasks/browser/restartQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksAriaLabel": "Yeniden başlatılacak görevin adını girin", + "noTasksMatching": "Eşleşen görev yok", + "noTasksFound": "Yeniden başlatılacak bir görev bulunamadı" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json b/i18n/trk/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json new file mode 100644 index 00000000000..3e235cd503a --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/tasks/browser/taskQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksAriaLabel": "Çalıştırılacak görevin adını girin", + "noTasksMatching": "Eşleşen görev yok", + "noTasksFound": "Görev bulunamadı" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.i18n.json b/i18n/trk/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.i18n.json new file mode 100644 index 00000000000..94241e91741 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/tasks/browser/terminateQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksAriaLabel": "Sonlandırılacak görevin adını girin", + "noTasksMatching": "Eşleşen görev yok", + "noTasksFound": "Sonlandırılacak bir görev bulunamadı" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json b/i18n/trk/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json new file mode 100644 index 00000000000..a68d96b3def --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/tasks/browser/testQuickOpen.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksAriaLabel": "Bir test görevinin adını girin", + "noTasksMatching": "Eşleşen görev yok", + "noTasksFound": "Test görevi bulunamadı" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json b/i18n/trk/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json new file mode 100644 index 00000000000..204c5be86e6 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/tasks/common/taskConfiguration.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "ConfigurationParser.invalidCWD": "Uyarı: options.cwd dize türünde olmalıdır. {0} değeri yok sayıldı.\n", + "ConfigurationParser.noargs": "Hata: komut argümanları dizelerden oluşan bir dizi olmalıdır. Belirtilen değer:\n{0}", + "ConfigurationParser.noShell": "Uyarı: kabuk yapılandırması sadece görevler terminalde çalıştırılırken desteklenir.", + "ConfigurationParser.noName": "Hata: Kapsam bildiriminde Sorun Eşleştirici'nin bir adı olmalıdır:\n{0}\n", + "ConfigurationParser.unknownMatcherKind": "Uyarı: tanımlanan sorun eşleştirici bilinmiyor. Desteklenen türler: dize | ProblemMatcher | (dize | ProblemMatcher)[].\n{0}\n", + "ConfigurationParser.invalidVaraibleReference": "Hata: Geçersiz problemMatcher başvusu: {0}\n", + "ConfigurationParser.noTaskName": "Hata: görevler bir taskName özelliği belirtmelidir. Görev yok sayılacaktır.\n{0}\n", + "taskConfiguration.shellArgs": "Uyarı: '{0}' görevi bir kabuk komutudur ve komut adı veya argümanlarından biri kaçış karakteri içermeyen boşluklar içeriyor. Doğru komut satırı alıntılamasını sağlamak için lütfen argümanları komutlarla birleştirin.", + "taskConfiguration.noCommandOrDependsOn": "Hata: '{0}' görevi bir komut veya dependsOn özelliği belirtmiyor. Görev yok sayılacaktır. Görevin tanımı:\n{1}", + "taskConfiguration.noCommand": "Hata: '{0}' görevi bir komut tanımlamıyor. Görev yok sayılacaktır. Görevin tanımı:\n{1}" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/tasks/common/taskTemplates.i18n.json b/i18n/trk/src/vs/workbench/parts/tasks/common/taskTemplates.i18n.json new file mode 100644 index 00000000000..0ad2a2013d4 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/tasks/common/taskTemplates.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tsc.config": "Bir TypeScript projesi derler", + "tsc.watch": "İzleme moduna bir TypeScript projesi derler", + "dotnetCore": ".NET Core derleme komutu çalıştırır", + "msbuild": "Derleme hedefini çalıştırır", + "externalCommand": "İsteğe bağlı bir harici komut çalıştırma örneği", + "Maven": "Yaygın maven komutlarını çalıştırır" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json b/i18n/trk/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json new file mode 100644 index 00000000000..d02d11f0ce3 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/tasks/electron-browser/jsonSchemaCommon.i18n.json @@ -0,0 +1,39 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "JsonSchema.options": "Ek komut seçenekleri", + "JsonSchema.options.cwd": "Çalıştırılan program veya betiğin geçerli çalışma klasörü. Atlanırsa Code'un geçerli çalışma alanının kök dizini kullanılır.", + "JsonSchema.options.env": "Çalıştırılan program veya kabuğun ortamı. Atlanırsa üst işlemin ortamı kullanılır.", + "JsonSchema.shellConfiguration": "Kullanılacak kabuğu özelleştirir.", + "JsonSchema.shell.executable": "Kullanılacak kabuk.", + "JsonSchema.shell.args": "Kabuk argümanları.", + "JsonSchema.command": "Çalıştırılacak komut. Harici bir program veya bir kabuk komutu olabilir.", + "JsonSchema.tasks.args": "Bu görev çağrıldığında, komuta iletilecek argümanlar.", + "JsonSchema.tasks.taskName": "Görevin adı", + "JsonSchema.tasks.windows": "Windows'a özel komut yapılandırması", + "JsonSchema.tasks.mac": "Mac'e özel komut yapılandırması", + "JsonSchema.tasks.linux": "Linux'a özel komut yapılandırması", + "JsonSchema.tasks.suppressTaskName": "Görev adının komuta argüman olarak eklenip eklenmeyeceğini denetler. Atlanırsa global olarak tanımlanan değer kullanılır.", + "JsonSchema.tasks.showOutput": "Çalışan görev çıktısının görünüp görünmeyeceğini denetler. Atlanırsa global olarak tanımlanan değer kullanılır.", + "JsonSchema.echoCommand": "Çalıştırılan komutun çıktıya yazıp yazmayacağını denetler. Varsayılan olarak kapalıdır.", + "JsonSchema.tasks.watching.deprecation": "Kullanım dışı. Bunun yerine isBackground ögesini kullanın.", + "JsonSchema.tasks.watching": "Çalıştırılan görevin etkin tutulup tutulmadığı ve dosya sistemini izleyip izlemediği.", + "JsonSchema.tasks.background": "Çalıştırılan görevin etkin tutulup tutulmadığı ve arka planda çalışıp çalışmadığı.", + "JsonSchema.tasks.promptOnClose": "VS Code'un çalışan bir görevle kapatılırken kullanıcının uyarılıp uyarılmayacağı.", + "JsonSchema.tasks.build": "Bu görevi, Code'un varsayılan derleme komutuna eşler.", + "JsonSchema.tasks.test": "Bu görevi, Code'un varsayılan test komutuna eşler.", + "JsonSchema.tasks.matchers": "Kullanılacak problem eşleştirici(leri). Bir dize veya bir problem eşleştirici tanımı veya bir dize ve problem eşleştiricileri dizisi.", + "JsonSchema.args": "Komuta iletilecek ek argümanlar.", + "JsonSchema.showOutput": "Çalışan görev çıktısının görünüp görünmeyeceğini denetler. Atlanırsa \"daima\" olarak varsayılır.", + "JsonSchema.watching.deprecation": "Kullanım dışı. Bunun yerine isBackground ögesini kullanın.", + "JsonSchema.watching": "Çalıştırılan görevin etkin tutulup tutulmadığı ve dosya sistemini izleyip izlemediği.", + "JsonSchema.background": "Çalıştırılan görevin etkin tutulup tutulmadığı ve arka planda çalışıp çalışmadığı.", + "JsonSchema.promptOnClose": "VS Code'un arka planda çalışan bir görevle kapatılırken kullanıcının uyarılıp uyarılmayacağı.", + "JsonSchema.suppressTaskName": "Görev adının komuta argüman olarak eklenip eklenmeyeceğini denetler. Varsayılan olarak kapalıdır.", + "JsonSchema.taskSelector": "Bir argümanın, görev olduğunu gösterecek ön ek.", + "JsonSchema.matchers": "Kullanılacak problem eşleştirici(leri). Bir dize veya bir problem eşleştirici tanımı veya bir dize ve problem eşleştiricileri dizisi.", + "JsonSchema.tasks": "Görev yapılandırmaları. Genellikle harici görev çalıştırıcısında tanımlı görevin zenginleştirilmesidir." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json b/i18n/trk/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json new file mode 100644 index 00000000000..8717a0ca787 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v1.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "JsonSchema.version": "Yapılandırmanın sürüm numarası.", + "JsonSchema._runner": "\"runner\" görevini tamamladı. Resmi runner özelliğini kullanın", + "JsonSchema.runner": "Görevin bir işlem olarak çalıştırılıp çalıştırılmayacağını ve çıktının, çıktı penceresinde veya terminalin içinde gösterilip gösterilmeyeceğini denetler.", + "JsonSchema.windows": "Windows'a özel komut yapılandırması", + "JsonSchema.mac": "Mac'e özel komut yapılandırması", + "JsonSchema.linux": "Linux'a özel komut yapılandırması", + "JsonSchema.shell": "Komutun bir kabuk komutu veya harici bir program olup olmadığını belirtir. Atlanırsa hayır olarak kabul edilir." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json b/i18n/trk/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json new file mode 100644 index 00000000000..138ef85921a --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/tasks/electron-browser/jsonSchema_v2.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "JsonSchema.shell": "Komutun bir kabuk komutu veya harici bir program olup olmadığını belirtir. Atlanırsa hayır olarak kabul edilir.", + "JsonSchema.tasks.dependsOn.string": "Bu görevin bağlı olduğu başka bir görev.", + "JsonSchema.tasks.dependsOn.array": "Bu görevin bağlı olduğu diğer görevler.", + "JsonSchema.tasks.group": "Bu görevin ait olduğu çalıştırma grubunu tanımlar. Atlanırsa, görev hiçbir gruba ait olmaz.", + "JsonSchema.tasks.type": "Görevin bir işlem olarak veya bir kabukta komut olarak çalıştırılıp çalıştırılmayacağını tanımlar. Varsayılan işlem olarak çalıştırmaktır.", + "JsonSchema.version": "Yapılandırmanın sürüm numarası.", + "JsonSchema.tasks.customize": "Özelleştirilecek ekleme yapılan görev.", + "JsonSchema.windows": "Windows'a özel komut yapılandırması", + "JsonSchema.mac": "Mac'e özel komut yapılandırması", + "JsonSchema.linux": "Linux'a özel komut yapılandırması" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json new file mode 100644 index 00000000000..536ad1269e0 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/tasks/electron-browser/task.contribution.i18n.json @@ -0,0 +1,51 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "tasksCategory": "Görevler", + "ConfigureTaskRunnerAction.noWorkspace": "Görevler, sadece çalışma alanı klasöründe mevcuttur.", + "ConfigureTaskRunnerAction.quickPick.template": "Bir Görev Çalıştırıcısı Seç", + "ConfigureTaskRunnerAction.autoDetecting": "{0} görevleri otomatik algılanıyor", + "ConfigureTaskRunnerAction.autoDetect": "Görev sisteminin otomatik algılanması başarısız oldu. Varsayılan şablon kullanılıyor. Ayrıntılar için görev çıktısına bakın.", + "ConfigureTaskRunnerAction.autoDetectError": "Görev sisteminin otomatik algılanması sırasında hatalar oluştu. Ayrıntılar için görev çıktısına bakın.", + "ConfigureTaskRunnerAction.failed": " '.vscode' klasörü içinde 'tasks.json' dosyası oluşturulamıyor. Ayrıntılar için görev çıktısına bakın.", + "ConfigureTaskRunnerAction.label": "Görev Çalıştırıcısını Yapılandır", + "ConfigureBuildTaskAction.label": "Derleme Görevini Yapılandır", + "CloseMessageAction.label": "Kapat", + "ShowTerminalAction.label": "Terminali Görüntüle", + "problems": "Sorunlar", + "manyMarkers": "99+", + "tasks": "Görevler", + "TaskSystem.noHotSwap": "Görev yürütme motorunu değiştirmek VS Code'u yeniden başlatmayı gerektirir. Değişiklik yok sayıldı.", + "TaskService.noBuildTask": "Derleme görevi tanımlanmamış. task.json dosyasındaki bir görevi 'isBuildCommand' ile işaretleyin.", + "TaskService.noTestTask": "Test görevi tanımlanmamış. task.json dosyasındaki bir testi 'isTestCommand' ile işaretleyin.", + "TaskServer.noTask": " Çalıştırılmak istenen {0} görevi bulunamadı.", + "customizeParseErrors": "Geçerli görev yapılandırmasında hatalar var. Lütfen, bir görevi özelleştirmeden önce ilk olarak hataları düzeltin.", + "moreThanOneBuildTask": "task.json dosyasında tanımlı çok fazla derleme görevi var. İlk görev çalıştırılıyor.\n", + "TaskSystem.activeSame.background": "Görev zaten aktif ve arka plan modunda. Görevi sonlandırmak için `F1 > görevi sonlandır`ı kullanın", + "TaskSystem.active": "Çalışan bir görev zaten var. Bir başkasını çalıştırmadan önce bu görevi sonlandırın.", + "TaskSystem.restartFailed": "{0} görevini sonlandırma ve yeniden başlatma başarısız oldu", + "TaskSystem.configurationErrors": "Hata: belirtilen görev yapılandırmasında doğrulama hataları var ve kullanılamıyor. Lütfen ilk olarak hataları düzeltin.", + "TaskSystem.invalidTaskJson": "Hata: task.json dosyasının içeriğinde sentaks hataları var. Lütfen, bir görevi çalıştırmadan önce hataları düzeltin.\n", + "TaskSystem.runningTask": "Çalışan bir görev var. Bu görevi sonlandırmak istiyor musunuz?", + "TaskSystem.terminateTask": "&&Görevi Sonlandır", + "TaskSystem.noProcess": "Başlatılan görev artık mevcut değil. Eğer görev arka plan işlemleri oluşturduysa, VS Code'dan çıkmak işlemlerin sahipsiz kalmasına neden olabilir. Bunu önlemek için son arka plan işlemini bekle işaretçisiyle başlatın.", + "TaskSystem.exitAnyways": "Yine de &&Çık", + "TerminateAction.label": "Çalışan Görevi Sonlandır", + "TaskSystem.unknownError": "Bir görev çalıştırılırken hata oluştu. Detaylar için görev günlüğüne bakın.", + "TaskService.noWorkspace": "Görevler, sadece çalışma alanı klasöründe mevcuttur.", + "TerminateAction.noProcess": "Başlatılan işlem artık mevcut değil. Eğer görev arka plan görevleri oluşturduysa, VS Code'dan çıkmak işlemlerin sahipsiz kalmasına neden olabilir.", + "TerminateAction.failed": "Çalışan görevi sonlandırma başarısız oldu.", + "ShowLogAction.label": "Görev Günlüğünü Göster", + "RunTaskAction.label": "Görevi Çalıştır", + "RestartTaskAction.label": "Görevi Yeniden Başlat", + "BuildAction.label": "Derleme Görevini Çalıştır", + "TestAction.label": "Test Görevini Çalıştır", + "quickOpen.task": "Görevi Çalıştır", + "quickOpen.terminateTask": "Görevi Sonlandır", + "quickOpen.restartTask": "Görevi Yeniden Başlat", + "quickOpen.buildTask": "Derleme Görevi", + "quickOpen.testTask": "Test Görevi" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json b/i18n/trk/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json new file mode 100644 index 00000000000..d3492257f35 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/tasks/electron-browser/terminalTaskSystem.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "TerminalTaskSystem.unknownError": "Görev çalıştırılırken bir hata oluştu. Detaylar için görev çıktısı günlüğüne bakın.", + "TerminalTaskSystem.terminalName": "Görev - {0}", + "reuseTerminal": "Terminal görevler tarafından tekrar kullanılacak, kapatmak için herhangi bir tuşa basın.", + "TerminalTaskSystem": "UNC sürücüsünde kabuk komutu yürütülemez.", + "unkownProblemMatcher": "{0} sorun eşleştirici çözümlenemiyor. Eşleştirici yok sayılacaktır." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/tasks/node/processRunnerDetector.i18n.json b/i18n/trk/src/vs/workbench/parts/tasks/node/processRunnerDetector.i18n.json new file mode 100644 index 00000000000..bd7194ed6ee --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/tasks/node/processRunnerDetector.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "TaskSystemDetector.noGulpTasks": "gulp --tasks-simple komutu çalıştırıldığında herhangi bir görev listelemedi. npm install komutunu çalıştırdınız mı?", + "TaskSystemDetector.noJakeTasks": "jake --tasks komutu çalıştırıldığında herhangi bir görev listelemedi. npm install komutunu çalıştırdınız mı?", + "TaskSystemDetector.noGulpProgram": "Gulp, sisteminizde yüklü değil. Yüklemek için npm install -g gulp komutunu çalıştırın.", + "TaskSystemDetector.noJakeProgram": "Jake, sisteminizde yüklü değil. Yüklemek için npm install -g jake komutunu çalıştırın.", + "TaskSystemDetector.noGruntProgram": "Grunt, sisteminizde yüklü değil. Yüklemek için npm install -g grunt komutunu çalıştırın.", + "TaskSystemDetector.noProgram": "{0} programı bulunamadı. Mesaj: {1}", + "TaskSystemDetector.buildTaskDetected": "'{0}' olarak adlandırılmış derleme görevi algılandı.", + "TaskSystemDetector.testTaskDetected": "'{0}' olarak adlandırılmış test görevi algılandı." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json b/i18n/trk/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json new file mode 100644 index 00000000000..f5da8b2c7db --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/tasks/node/processTaskSystem.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "TaskRunnerSystem.unknownError": "Görev çalıştırılırken bir hata oluştu. Detaylar için görev çıktısı günlüğüne bakın.", + "TaskRunnerSystem.watchingBuildTaskFinished": "\nDerleme görevlerinin izlenmesi bitti.", + "TaskRunnerSystem.childProcessError": "Harici program {0} {1} başlatılamadı.", + "TaskRunnerSystem.cancelRequested": "\n'{0}' görevi kullanıcı isteği üzerine sonlandırıldı.", + "unkownProblemMatcher": "{0} sorun eşleştirici çözümlenemiyor. Eşleştirici yok sayılacaktır." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.i18n.json new file mode 100644 index 00000000000..76b62e0169e --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.i18n.json @@ -0,0 +1,30 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminalIntegratedConfigurationTitle": "Entegre Terminal", + "terminal.integrated.shell.linux": "Terminalin Linux'da kullandığı kabuğun yolu.", + "terminal.integrated.shellArgs.linux": "Linux terminalindeyken kullanılacak komut satırı argümanları.", + "terminal.integrated.shell.osx": "Terminalin OS X'de kullandığı kabuğun yolu.", + "terminal.integrated.shellArgs.osx": "OS X terminalindeyken kullanılacak komut satırı argümanları.", + "terminal.integrated.shell.windows": "Terminalin Windows'da kullandığı kabuğun yolu. Windows ile birlikte gelen kabukları kullanırken (cmd, PowerShell veya Bash on Ubuntu), 64 bit sürümlerini kullanmak için C:\\Windows\\System32 yerine C:\\Windows\\sysnative yolunu tercih edin.", + "terminal.integrated.shellArgs.windows": "Windows terminalindeyken kullanılacak komut satırı argümanları.", + "terminal.integrated.rightClickCopyPaste": "Ayarlandığında, terminal içinde sağ tıklandığında bağlam menüsünün görünmesini engeller, onun yerine bir seçim varsa kopyalama yapar, bir seçim yoksa yapıştırma yapar.", + "terminal.integrated.fontFamily": "Terminalin yazı tipi ailesini denetler; bu, varsayılan olarak editor.fontFamily'nin değeridir.", + "terminal.integrated.fontLigatures": "Terminalde yazı tipi ligatürlerinin etkinleştirilip etkinleştirilmeyeceğini denetler.", + "terminal.integrated.fontSize": "Terminaldeki yazı tipi boyutunu piksel olarak denetler.", + "terminal.integrated.lineHeight": "Terminalin satır yüksekliğini denetler, bu sayı gerçek satır yüksekliğini piksel olarak elde etmek için terminal yazı tipi boyutu ile çarpılır.", + "terminal.integrated.enableBold": "Terminalde kalın yazının etkinleştirilip etkinleştirilmeyeceği; bu, terminal kabuğunun desteğini gerektirir.", + "terminal.integrated.cursorBlinking": "Terminaldeki imlecin yanıp sönmesini denetler.", + "terminal.integrated.cursorStyle": "Terminaldeki imlecin stilini denetler.", + "terminal.integrated.scrollback": "Terminalin tamponunda tuttuğu maksimum satır sayısını denetler.", + "terminal.integrated.setLocaleVariables": "Terminal başlangıcında yereli içeren değişkenlerin ayarlanıp ayarlanmayacağını denetler; bu, OS X'de varsayılan olarak açıktır, diğer platformlarda kapalıdır.", + "terminal.integrated.cwd": "Terminalin nerede başlatılacağına ait açık bir yol; bu, kabuk işlemleri için geçerli çalışma klasörü (cwd) olarak kullanılır. Bu, çalışma alanı ayarlarında kök dizini uygun bir cwd değilse özellikle yararlı olabilir.", + "terminal.integrated.confirmOnExit": "Aktif terminal oturumları varken çıkışta onay istenip istenmeyeceği.", + "terminal.integrated.commandsToSkipShell": "Tuş bağlarının kabuğa gönderilmeyip bunun yerine her zaman Code tarafından işleneceği bir komut ID'leri kümesi. Bu, tuş bağlarının normalde kabuk tarafından terminal odakta değilken nasılsa öyle davranmasını sağlar, örnek olarak Hızlı Aç'ı başlatmak için ctrl+p.", + "terminal": "Terminal", + "terminalCategory": "Terminal", + "viewCategory": "Görüntüle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json b/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json new file mode 100644 index 00000000000..7ee287790c0 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalActions.i18n.json @@ -0,0 +1,37 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "workbench.action.terminal.toggleTerminal": "Entegre Terminali Aç/Kapat", + "workbench.action.terminal.kill": "Aktif Terminal Örneğini Sonlandır", + "workbench.action.terminal.kill.short": "Terminali Sonlandır", + "workbench.action.terminal.copySelection": "Seçimi Kopyala", + "workbench.action.terminal.selectAll": "Tümünü Seç", + "workbench.action.terminal.new": "Yeni Entegre Terminal Oluştur", + "workbench.action.terminal.new.short": "Yeni Terminal", + "workbench.action.terminal.focus": "Terminale Odakla", + "workbench.action.terminal.focusNext": "Sonraki Terminale Odakla", + "workbench.action.terminal.focusAtIndex": "{0}. Terminale Odakla", + "workbench.action.terminal.focusPrevious": "Önceki Terminale Odakla", + "workbench.action.terminal.paste": "Aktif Terminale Yapıştır", + "workbench.action.terminal.DefaultShell": "Varsayılan Kabuğu Seç", + "workbench.action.terminal.runSelectedText": "Seçili Metni Aktif Terminalde Çalıştır", + "workbench.action.terminal.runActiveFile": "Aktif Dosyayı Aktif Terminalde Çalıştır", + "workbench.action.terminal.runActiveFile.noFile": "Sadece diskteki dosyalar terminalde çalıştırılabilir", + "workbench.action.terminal.switchTerminalInstance": "Terminal Örneğini Değiştir", + "workbench.action.terminal.scrollDown": "Aşağı Kaydır (Satır)", + "workbench.action.terminal.scrollDownPage": "Aşağı Kaydır (Sayfa)", + "workbench.action.terminal.scrollToBottom": "En Alta Kaydır", + "workbench.action.terminal.scrollUp": "Yukarı Kaydır (Satır)", + "workbench.action.terminal.scrollUpPage": "Yukarı Kaydır (Sayfa)", + "workbench.action.terminal.scrollToTop": "En Üste Kaydır", + "workbench.action.terminal.clear": "Temizle", + "workbench.action.terminal.allowWorkspaceShell": "Çalışma Alanı Kabuk Yapılandırmasına İzin Ver", + "workbench.action.terminal.disallowWorkspaceShell": "Çalışma Alanı Kabuk Yapılandırmasına İzin Verme", + "workbench.action.terminal.rename": "Yeniden Adlandır", + "workbench.action.terminal.rename.prompt": "Terminal adını girin", + "workbench.action.terminal.focusFindWidget": "Bulma Aracına Odakla", + "workbench.action.terminal.hideFindWidget": "Bulma Aracını Gizle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json b/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json new file mode 100644 index 00000000000..56cc70a5239 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminal.background": "Terminalin arka plan rengi; bu, terminalin panelden farklı olarak renklendirilmesini sağlar.", + "terminal.foreground": "Terminalin ön plan rengi.", + "terminal.ansiColor": "Terminalde '{0}' ANSI rengi." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.i18n.json b/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.i18n.json new file mode 100644 index 00000000000..745f1badf0a --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalConfigHelper.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminal.integrated.allowWorkspaceShell": "{0} ögesinin (çalışma alanı ayarı olarak tanımlı) terminalde başlatılmasına izin veriyor musunuz?", + "allow": "İzin Ver", + "disallow": "İzin Verme" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json b/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json new file mode 100644 index 00000000000..baad53fc2a4 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalFindWidget.i18n.json @@ -0,0 +1,12 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "label.find": "Bul", + "placeholder.find": "Bul", + "label.previousMatchButton": "Önceki eşleşme", + "label.nextMatchButton": "Sonraki eşleşme", + "label.closeButton": "Kapat" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json b/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json new file mode 100644 index 00000000000..38dcd5eb951 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalInstance.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminal.integrated.copySelection.noSelection": "Terminalde kopyalanacak bir seçim bulunmuyor", + "terminal.integrated.exitedWithCode": "Terminal işlemi şu çıkış koduyla sonlandı: {0}", + "terminal.integrated.waitOnExit": "Terminali kapatmak için lütfen bir tuşa basın", + "terminal.integrated.launchFailed": "Terminal işlem komutu `{0}{1}` başlatılamadı (çıkış kodu: {2})" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.i18n.json b/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.i18n.json new file mode 100644 index 00000000000..0b0eeab242a --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalLinkHandler.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminalLinkHandler.followLinkCmd": "Bağlantıyı izlemek için Cmd tuşuna basarak tıklayın", + "terminalLinkHandler.followLinkCtrl": "Bağlantıyı izlemek için Ctrl tuşuna basarak tıklayın" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.i18n.json b/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.i18n.json new file mode 100644 index 00000000000..e3fb6347294 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "copy": "Kopyala", + "createNewTerminal": "Yeni Terminal", + "paste": "Yapıştır", + "clear": "Temizle" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalService.i18n.json b/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalService.i18n.json new file mode 100644 index 00000000000..28fa93d323a --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/terminal/electron-browser/terminalService.i18n.json @@ -0,0 +1,15 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "terminal.integrated.chooseWindowsShellInfo": "Özelleştir butonuna tıklayıp varsayılan terminal kabuğunu seçebilirsiniz.", + "customize": "Özelleştir", + "cancel": "İptal", + "never again": "Tamam, Tekrar Gösterme", + "terminal.integrated.chooseWindowsShell": "Tercih ettiğiniz terminal kabuğunu seçin, bunu daha sonra ayarlarınızdan değiştirebilirsiniz", + "terminalService.terminalCloseConfirmationSingular": "Aktif bir terminal oturumu var, sonlandırmak istiyor musunuz?", + "terminalService.terminalCloseConfirmationPlural": "{0} aktif terminal oturumu var, bunları sonlandırmak istiyor musunuz?", + "yes": "Evet" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json new file mode 100644 index 00000000000..ef4e0417b9d --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/themes/electron-browser/themes.contribution.i18n.json @@ -0,0 +1,19 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "selectTheme.label": "Renk Teması", + "installColorThemes": "Ek Renk Temaları Yükle...", + "themes.selectTheme": "Bir Renk Teması Seç (Yukarı/Aşağı Tuşlarıyla Önizleme Yap)", + "selectIconTheme.label": "Dosya Simgesi Teması", + "installIconThemes": "Ek Dosya Simgesi Temaları Yükle...", + "noIconThemeLabel": "Hiçbiri", + "noIconThemeDesc": "Dosya simgelerini devre dışı bırak", + "problemChangingIconTheme": "Simge temasını ayarlama sorunu: {0}", + "themes.selectIconTheme": "Dosya Simgesi Teması Seç", + "generateColorTheme.label": "Geçerli Ayarlardan Renk Teması Oluştur", + "preferences": "Tercihler", + "developer": "Geliştirici" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/trust/electron-browser/unsupportedWorkspaceSettings.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/trust/electron-browser/unsupportedWorkspaceSettings.contribution.i18n.json new file mode 100644 index 00000000000..6e2f9a6845f --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/trust/electron-browser/unsupportedWorkspaceSettings.contribution.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "unsupportedWorkspaceSettings": "Bu çalışma alanı sadece Kullanıcı Ayarları'nda ayarlanabilen ayarlar içeriyor. ({0})", + "openWorkspaceSettings": "Çalışma Alanı Ayarlarını Aç", + "openDocumentation": "Daha Fazla Bilgi Edin", + "ignore": "Yok Say" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/update/electron-browser/releaseNotesInput.i18n.json b/i18n/trk/src/vs/workbench/parts/update/electron-browser/releaseNotesInput.i18n.json new file mode 100644 index 00000000000..cd4ef89692a --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/update/electron-browser/releaseNotesInput.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "releaseNotesInputName": "Sürüm Notları: {0}" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/update/electron-browser/update.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/update/electron-browser/update.contribution.i18n.json new file mode 100644 index 00000000000..a8342747ede --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/update/electron-browser/update.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "release notes": "Sürüm notları", + "updateConfigurationTitle": "Güncelle", + "updateChannel": "Güncelleştirme kanalından otomatik güncelleştirmeler alıp almayacağınızı ayarlayın. Değişiklikten sonra yeniden başlatma gerektirir." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/update/electron-browser/update.i18n.json b/i18n/trk/src/vs/workbench/parts/update/electron-browser/update.i18n.json new file mode 100644 index 00000000000..b03c4aaf230 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/update/electron-browser/update.i18n.json @@ -0,0 +1,32 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "updateNow": "Şimdi Güncelle", + "later": "Daha Sonra", + "unassigned": "atanmamış", + "releaseNotes": "Sürüm Notları", + "showReleaseNotes": "Sürüm Notlarını Göster", + "downloadNow": "Şimdi İndir", + "read the release notes": "{0} v{1} uygulamasına hoş geldiniz! Sürüm Notları'nı okumak ister misiniz?", + "licenseChanged": "Lisans koşullarımız değişti, lütfen inceleyin.", + "license": "Lisansı Oku", + "updateAvailable": "{0} yeniden başlatıldıktan sonra güncellenecektir.", + "thereIsUpdateAvailable": "Bir güncelleştirme var.", + "noUpdatesAvailable": "Şu anda mevcut herhangi bir güncelleme yok.", + "updateIsReady": "Yeni güncelleştirme var.", + "commandPalette": "Komut Paleti...", + "settings": "Ayarlar", + "keyboardShortcuts": "Klavye Kısayolları", + "selectTheme.label": "Renk Teması", + "themes.selectIconTheme.label": "Dosya Simgesi Teması", + "not available": "Güncelleştirme Yok", + "checkingForUpdates": "Güncelleştirmeler Denetleniyor...", + "DownloadUpdate": "Mevcut Güncelleştirmeyi İndir", + "DownloadingUpdate": "Güncelleştirme İndiriliyor...", + "InstallingUpdate": "Güncelleştirme Yükleniyor...", + "restartToUpdate": "Güncelleştirmek için Yeniden Başlatın...", + "checkForUpdates": "Güncelleştirmeleri Denetle..." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/views/browser/views.i18n.json b/i18n/trk/src/vs/workbench/parts/views/browser/views.i18n.json new file mode 100644 index 00000000000..13520a7bd48 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/views/browser/views.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "viewToolbarAriaLabel": "{0} eylem" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json b/i18n/trk/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json new file mode 100644 index 00000000000..e6729315d5a --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/views/browser/viewsExtensionPoint.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "requirearray": "görünümler bir dizi olmalıdır", + "requirestring": "`{0}` özelliği zorunludur ve `string` türünde olmalıdır", + "optstring": "`{0}` özelliği atlanabilir veya `string` türünde olmalıdır", + "vscode.extension.contributes.view.id": "Görünümün tanımlayıcısı. Bunu, `vscode.window.registerTreeDataProviderForView` API ile bir veri sağlayıcısı kaydetmek için kullanın. Ayrıca `onView:${id}` olayını `activationEvents` ögesine kaydederek eklentinizi etkinleştirmeyi tetikleyin.", + "vscode.extension.contributes.view.name": "Görünümün insanlar tarafından okunabilir adı. Gösterilecektir", + "vscode.extension.contributes.view.when": "Bu görünümü göstermek için doğru olması gereken koşul", + "vscode.extension.contributes.views": "Görünümleri düzenleyiciye ekler.", + "views.explorer": "Gezgin Görünümü", + "locationId.invalid": "`{0}` geçerli bir görünüm konumu değil" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json b/i18n/trk/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json new file mode 100644 index 00000000000..069fea26d95 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/watermark/electron-browser/watermark.i18n.json @@ -0,0 +1,24 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "watermark.showCommands": "Tüm Komutları Göster", + "watermark.quickOpen": "Dosyaya Git", + "watermark.openFile": "Dosya Aç", + "watermark.openFolder": "Klasör Aç", + "watermark.openFileFolder": "Dosya veya Klasör Aç", + "watermark.openRecent": "Son Kullanılanları Aç", + "watermark.newUntitledFile": "Yeni İsimsiz Dosya", + "watermark.toggleTerminal": "Terminali Aç/Kapat", + "watermark.findInFiles": "Dosyalarda Bul", + "watermark.startDebugging": "Hata Ayıklamaya Başla", + "watermark.selectTheme": "Temayı Değiştir", + "watermark.selectKeymap": "Tuş Haritasını Değiştir", + "watermark.keybindingsReference": "Klavye Başvurusu", + "watermark.openGlobalKeybindings": "Klavye Kısayolları", + "watermark.unboundCommand": "serbest", + "workbenchConfigurationTitle": "Çalışma Ekranı", + "tips.enabled": "Etkinleştirildiğinde, hiçbir düzenleyici açık değilken filigran ipuçları gösterir" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.i18n.json b/i18n/trk/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.i18n.json new file mode 100644 index 00000000000..0c942884ab6 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/welcome/overlay/browser/welcomeOverlay.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "welcomeOverlay.explorer": "Dosya gezgini", + "welcomeOverlay.search": "Dosyalar arasında ara", + "welcomeOverlay.git": "Kaynak kodu yönetimi", + "welcomeOverlay.debug": "Başlat ve hata ayıkla", + "welcomeOverlay.extensions": "Eklentileri yönet", + "welcomeOverlay.problems": "Hataları ve uyarıları görüntüle", + "welcomeOverlay.commandPalette": "Tüm komutları bul ve çalıştır", + "welcomeOverlay": "Kullanıcı Arayüzüne Genel Bakış", + "hideWelcomeOverlay": "Arayüz Genel Bakışını Gizle", + "help": "Yardım" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json b/i18n/trk/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json new file mode 100644 index 00000000000..807fbc62c15 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/welcome/page/electron-browser/vs_code_welcome_page.i18n.json @@ -0,0 +1,43 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "welcomePage.vscode": "Visual Studio Code", + "welcomePage.editingEvolved": "Düzenleme evrim geçirdi", + "welcomePage.start": "Başlangıç", + "welcomePage.newFile": "Yeni dosya", + "welcomePage.openFolder": "Klasör aç...", + "welcomePage.cloneGitRepository": "Git deposu kopyala...", + "welcomePage.recent": "Son Kullanılanlar", + "welcomePage.moreRecent": "Diğerleri...", + "welcomePage.noRecentFolders": "Son kullanılan klasör yok", + "welcomePage.help": "Yardım", + "welcomePage.keybindingsCheatsheet": "Yazdırılabilir klavye kopya kağıdı", + "welcomePage.introductoryVideos": "Tanıtım videoları", + "welcomePage.productDocumentation": "Ürün belgeleri", + "welcomePage.gitHubRepository": "GitHub deposu", + "welcomePage.stackOverflow": "Stack Overflow", + "welcomePage.showOnStartup": "Başlangıçta hoş geldiniz sayfasını göster", + "welcomePage.customize": "Özelleştir", + "welcomePage.installExtensionPacks": "Araçlar ve diller", + "welcomePage.installExtensionPacksDescription": "{0} ve {1} için destek yükle", + "welcomePage.moreExtensions": "fazlası", + "welcomePage.installKeymapDescription": "Klavye kısayolları yükle", + "welcomePage.installKeymapExtension": "{0} ve {1} için klavye kısayolları yükle", + "welcomePage.others": "diğerleri", + "welcomePage.colorTheme": "Renk teması", + "welcomePage.colorThemeDescription": "Düzenleyici ve kodlarınız sevdiğiniz şekilde görünsün", + "welcomePage.learn": "Öğren", + "welcomePage.showCommands": "Tüm komutları bul ve çalıştır", + "welcomePage.interfaceOverview": "Arayüze genel bakış", + "welcomePage.interfaceOverviewDescription": "Kullanıcı arayüzünün ana bileşenlerini vurgulayan bir kaplamayı görüntüleyin", + "welcomePage.interactivePlayground": "İnteraktif oyun alanı", + "welcomePage.interactivePlaygroundDescription": "Başlıca düzenleyici özelliklerini kısa örneklerle deneyin", + "welcomePage.quickLinks": "Hızlı bağlantılar", + "welcomePage.keybindingsReference": "Klavye kısayolları başvurusu", + "welcomePage.keybindingsReferenceDescription": "En yaygın klavye kısayollarının olduğu yazdırılabilir bir PDF dosyası", + "welcomePage.configureSettings": "Ayarları yapılandır", + "welcomePage.configureSettingsDescription": "Ayarları değiştirerek VS Code'un tam gücünü açın" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json new file mode 100644 index 00000000000..03f771bb69e --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.contribution.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "help": "Yardım" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json b/i18n/trk/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json new file mode 100644 index 00000000000..3c96ac13013 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/welcome/page/electron-browser/welcomePage.i18n.json @@ -0,0 +1,38 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "workbenchConfigurationTitle": "Çalışma Ekranı", + "welcomePage.enabled": "Etkinleştirildiğinde, başlangıçta hoş geldiniz sayfası gösterilir.", + "welcomePage": "Hoş Geldiniz", + "welcomePage.javaScript": "JavaScript", + "welcomePage.typeScript": "TypeScript", + "welcomePage.python": "Python", + "welcomePage.php": "PHP", + "welcomePage.docker": "Docker", + "welcomePage.vim": "Vim", + "welcomePage.sublime": "Sublime", + "welcomePage.atom": "Atom", + "welcomePage.extensionPackAlreadyInstalled": "{0} desteği zaten yüklü.", + "welcomePage.willReloadAfterInstallingExtensionPack": "{0} ek desteği yüklendikten sonra pencere yeniden yüklenecektir.", + "welcomePage.installingExtensionPack": "{0} ek desteği yükleniyor...", + "welcomePage.extensionPackNotFound": "{1} Id'li {0} desteği bulunamadı.", + "welcomePage.keymapAlreadyInstalled": "{0} klavye kısayolları zaten yüklü.", + "welcomePage.willReloadAfterInstallingKeymap": "{0} klavye kısayolları yüklendikten sonra pencere yeniden yüklenecektir.", + "welcomePage.installingKeymap": "{0} klavye kısayolları yükleniyor...", + "welcomePage.keymapNotFound": "{1} Id'li {0} klavye kısayolları bulunamadı.", + "welcome.title": "Hoş Geldiniz", + "welcomePage.openFolderWithPath": "{1} yolundaki {0} klasörünü aç", + "welcomePage.extensionListSeparator": ", ", + "welcomePage.installKeymap": "{0} tuş haritasını yükle", + "welcomePage.installExtensionPack": "{0} ek desteği yükleniyor...", + "welcomePage.installedKeymap": "{0} tuş haritası zaten yüklü", + "welcomePage.installedExtensionPack": "{0} desteği zaten yüklü", + "ok": "Tamam", + "details": "Detaylar", + "cancel": "İptal", + "welcomePage.buttonBackground": "Hoş geldiniz sayfasındaki butonların arka plan rengi.", + "welcomePage.buttonHoverBackground": "Hoş geldiniz sayfasındaki butonların bağlantı vurgusu arka plan rengi." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/welcome/walkThrough/electron-browser/editor/editorWalkThrough.i18n.json b/i18n/trk/src/vs/workbench/parts/welcome/walkThrough/electron-browser/editor/editorWalkThrough.i18n.json new file mode 100644 index 00000000000..80ad1bc8870 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/welcome/walkThrough/electron-browser/editor/editorWalkThrough.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorWalkThrough": "İnteraktif Oyun Alanı", + "editorWalkThrough.title": "İnteraktif Oyun Alanı" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThrough.contribution.i18n.json b/i18n/trk/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThrough.contribution.i18n.json new file mode 100644 index 00000000000..c56d3c14fe8 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThrough.contribution.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "walkThrough.editor.label": "İnteraktif Oyun Alanı", + "help": "Yardım", + "interactivePlayground": "İnteraktif Oyun Alanı" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughActions.i18n.json b/i18n/trk/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughActions.i18n.json new file mode 100644 index 00000000000..9e8d2c57063 --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughActions.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "editorWalkThrough.arrowUp": "Yukarı Kaydır (Satır)", + "editorWalkThrough.arrowDown": "Aşağı Kaydır (Satır)", + "editorWalkThrough.pageUp": "Yukarı Kaydır (Sayfa)", + "editorWalkThrough.pageDown": "Aşağı Kaydır (Sayfa)" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json b/i18n/trk/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json new file mode 100644 index 00000000000..add57fa341b --- /dev/null +++ b/i18n/trk/src/vs/workbench/parts/welcome/walkThrough/electron-browser/walkThroughPart.i18n.json @@ -0,0 +1,10 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "walkThrough.unboundCommand": "serbest", + "walkThrough.gitNotFound": "Git, sisteminizde yüklü değil gibi görünüyor.", + "walkThrough.embeddedEditorBackground": "İnteraktif oyun alanındaki gömülü düzenleyicilerin arka plan rengi." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json b/i18n/trk/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json new file mode 100644 index 00000000000..a5088bc7ca6 --- /dev/null +++ b/i18n/trk/src/vs/workbench/services/configuration/node/configurationEditingService.i18n.json @@ -0,0 +1,17 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "open": "Ayarları Aç", + "close": "Kapat", + "saveAndRetry": "Ayarları Kaydet ve Yeniden Dene", + "errorUnknownKey": "Yapılandırma dosyasına yazılamıyor (Bilinmeyen Anahtar)", + "errorInvalidTarget": "Yapılandırma dosyasına yazılamıyor (Bilinmeyen Hedef)", + "errorNoWorkspaceOpened": "Hiçbir klasör açık olmadığı için ayarlara yazılamıyor. Lütfen ilk olarak bir klasörü açın ve tekrar deneyin.", + "errorInvalidConfiguration": "Ayarlara yazılamıyor. Lütfen dosyadaki hata/uyarıları düzeltmek için **Kullanıcı Ayarları'nı** açın ve tekrar deneyin.", + "errorInvalidConfigurationWorkspace": "Ayarlara yazılamıyor. Lütfen dosyadaki hata/uyarıları düzeltmek için **Çalışma Alanı Ayarları'nı** açın ve tekrar deneyin.", + "errorConfigurationFileDirty": "Dosya kaydedilmemiş değişiklikler içerdiği için ayarlara yazılamıyor. Lütfen dosyadaki hata/uyarıları düzeltmek için **Kullanıcı Ayarları'nı** açın ve tekrar deneyin.", + "errorConfigurationFileDirtyWorkspace": "Dosya kaydedilmemiş değişiklikler içerdiği için ayarlara yazılamıyor. Lütfen dosyadaki hata/uyarıları düzeltmek için **Çalışma Alanı Ayarları'nı** açın ve tekrar deneyin." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json b/i18n/trk/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json new file mode 100644 index 00000000000..4289f712979 --- /dev/null +++ b/i18n/trk/src/vs/workbench/services/crashReporter/common/crashReporterService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "telemetryConfigurationTitle": "Telemetri", + "telemetry.enableCrashReporting": "Kilitlenme raporlarının Microsoft'a gönderilmesini etkinleştirin.\nBu seçeneğin yürürlüğe girmesi için yeniden başlatma gerekir." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/services/editor/browser/editorService.i18n.json b/i18n/trk/src/vs/workbench/services/editor/browser/editorService.i18n.json new file mode 100644 index 00000000000..50e968f8ee3 --- /dev/null +++ b/i18n/trk/src/vs/workbench/services/editor/browser/editorService.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "compareLabels": "{0} ↔ {1}" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/services/files/electron-browser/fileService.i18n.json b/i18n/trk/src/vs/workbench/services/files/electron-browser/fileService.i18n.json new file mode 100644 index 00000000000..084090af734 --- /dev/null +++ b/i18n/trk/src/vs/workbench/services/files/electron-browser/fileService.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "netVersionError": "Microsoft .NET Framework 4.5 gerekli. Yüklemek için bağlantıyı izleyin.", + "installNet": ".NET Framework 4.5'i İndir", + "neverShowAgain": "Tekrar Gösterme", + "trashFailed": "'{0}' çöpe taşınamadı" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/services/files/node/fileService.i18n.json b/i18n/trk/src/vs/workbench/services/files/node/fileService.i18n.json new file mode 100644 index 00000000000..2f174109eab --- /dev/null +++ b/i18n/trk/src/vs/workbench/services/files/node/fileService.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "fileInvalidPath": "Geçersiz dosya kaynağı ({0})", + "fileIsDirectoryError": "Dosya bir dizindir ({0})", + "fileBinaryError": "Dosya ikili olarak görünüyor ve metin olarak açılamıyor", + "fileNotFoundError": "Dosya bulunamadı ({0})", + "unableToMoveCopyError": "Taşıma/kopyalama yapılamadı. Dosya, içinde bulunduğu klasörü değiştiriyor.", + "foldersCopyError": "Klasörler çalışma alanına kopyalanamaz. Lütfen kopyalamak için dosyaları tek tek seçin.", + "fileReadOnlyError": "Dosya Salt Okunur" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/services/keybinding/common/keybindingEditing.i18n.json b/i18n/trk/src/vs/workbench/services/keybinding/common/keybindingEditing.i18n.json new file mode 100644 index 00000000000..0e3f3b323f1 --- /dev/null +++ b/i18n/trk/src/vs/workbench/services/keybinding/common/keybindingEditing.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "errorKeybindingsFileDirty": "Dosya kaydedilmemiş değişiklikler içerdiği için yazılamıyor. Lütfen **tuş bağları** dosyasını kaydedin ve tekrar deneyin.", + "parseErrors": "Tuş bağları yazılamadı. Lütfen dosyadaki hata/uyarıları düzeltmek için **tuş bağları dosyasını** açın ve yeniden deneyin.", + "errorInvalidConfiguration": "Tuş bağları yazılamadı. **Tuş bağları dosyasında** Dizi olmayan bir nesne var. Temizlemek için lütfen dosyayı açın ve yeniden deneyin.", + "emptyKeybindingsHeader": "Varsayılanların üzerine yazmak için tuş bağlarınızı bu dosyaya yerleştirin" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/services/keybinding/electron-browser/keybindingService.i18n.json b/i18n/trk/src/vs/workbench/services/keybinding/electron-browser/keybindingService.i18n.json new file mode 100644 index 00000000000..a3dc9a93b6a --- /dev/null +++ b/i18n/trk/src/vs/workbench/services/keybinding/electron-browser/keybindingService.i18n.json @@ -0,0 +1,26 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "nonempty": "boş olmayan değer bekleniyordu.", + "requirestring": "`{0}` özelliği zorunludur ve `string` türünde olmalıdır", + "optstring": "`{0}` özelliği atlanabilir veya `string` türünde olmalıdır", + "vscode.extension.contributes.keybindings.command": "Tuş bağı tetiklendiğinde çalıştırılacak komutun tanımlayıcısı.", + "vscode.extension.contributes.keybindings.key": "Tuş veya tuş dizisi (tuşları artı işaretiyle veya boşluk dizisiyle ayırın, ör. bir akor için Ctrl+O ve Ctrl+L", + "vscode.extension.contributes.keybindings.mac": "Mac'e özel tuş veya tuş dizisi.", + "vscode.extension.contributes.keybindings.linux": "Linux'a özel tuş veya tuş dizisi.", + "vscode.extension.contributes.keybindings.win": "Windows'a özel tuş veya tuş dizisi.", + "vscode.extension.contributes.keybindings.when": "Tuşun aktif olacağı koşul", + "vscode.extension.contributes.keybindings": "Tuş bağlarına ekleme yapar.", + "invalid.keybindings": "Geçersiz `contributes.{0}`: {1}", + "unboundCommands": "Kullanılabilen diğer komutlar şunlardır: ", + "keybindings.json.title": "Tuş bağları yapılandırması", + "keybindings.json.key": "Tuş veya tuş dizisi (boşluk ile ayrılmış olarak)", + "keybindings.json.command": "Yürütülecek komutun adı", + "keybindings.json.when": "Tuşun aktif olacağı koşul", + "keybindings.json.args": "Yürütülecek komuta iletilecek argümanlar.", + "keyboardConfigurationTitle": "Klavye", + "dispatch": "Tuş basımlarının ya `keydown.code` (önerilen) ya da ` keydown.keyCode` kullanarak gönderilmesini denetler." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/services/message/browser/messageList.i18n.json b/i18n/trk/src/vs/workbench/services/message/browser/messageList.i18n.json new file mode 100644 index 00000000000..00c0b8b53d5 --- /dev/null +++ b/i18n/trk/src/vs/workbench/services/message/browser/messageList.i18n.json @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "alertErrorMessage": "Hata: {0}", + "alertWarningMessage": "Uyarı: {0}", + "alertInfoMessage": "Bilgi: {0}", + "error": "Hata", + "warning": "Uyar", + "info": "Bilgi", + "close": "Kapat" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/services/message/electron-browser/messageService.i18n.json b/i18n/trk/src/vs/workbench/services/message/electron-browser/messageService.i18n.json new file mode 100644 index 00000000000..ef993fa147f --- /dev/null +++ b/i18n/trk/src/vs/workbench/services/message/electron-browser/messageService.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "yesButton": "&&Evet", + "cancelButton": "İptal" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/services/mode/common/workbenchModeService.i18n.json b/i18n/trk/src/vs/workbench/services/mode/common/workbenchModeService.i18n.json new file mode 100644 index 00000000000..3adb24cee4c --- /dev/null +++ b/i18n/trk/src/vs/workbench/services/mode/common/workbenchModeService.i18n.json @@ -0,0 +1,16 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "invalid": "Geçersiz `contributes.{0}`. Bir dizi bekleniyordu.", + "invalid.empty": "`contributes.{0}` için boş değer", + "require.id": "`{0}` özelliği zorunludur ve `string` türünde olmalıdır", + "opt.extensions": "`{0}` özelliği atlanabilir veya `string[]` türünde olmalıdır", + "opt.filenames": "`{0}` özelliği atlanabilir veya `string[]` türünde olmalıdır", + "opt.firstLine": "`{0}` özelliği atlanabilir veya `string` türünde olmalıdır", + "opt.configuration": "`{0}` özelliği atlanabilir veya `string` türünde olmalıdır", + "opt.aliases": "`{0}` özelliği atlanabilir veya `string[]` türünde olmalıdır", + "opt.mimetypes": "`{0}` özelliği atlanabilir veya `string[]` türünde olmalıdır" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/services/progress/browser/progressService2.i18n.json b/i18n/trk/src/vs/workbench/services/progress/browser/progressService2.i18n.json new file mode 100644 index 00000000000..6db7d6aae51 --- /dev/null +++ b/i18n/trk/src/vs/workbench/services/progress/browser/progressService2.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "progress.text": "{0} - {1}", + "progress.title": "{0}: {1}" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/services/textfile/common/textFileEditorModel.i18n.json b/i18n/trk/src/vs/workbench/services/textfile/common/textFileEditorModel.i18n.json new file mode 100644 index 00000000000..7c9f89a2ac8 --- /dev/null +++ b/i18n/trk/src/vs/workbench/services/textfile/common/textFileEditorModel.i18n.json @@ -0,0 +1,9 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "saveFileFirst": "Dosya kaydedilmemiş değişiklikler içeriyor. Başka bir kodlama ile yeniden açmadan önce lütfen ilk olarak kaydedin.", + "genericSaveError": "'{0}' kaydedilemedi: ({1})." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/services/textfile/common/textFileService.i18n.json b/i18n/trk/src/vs/workbench/services/textfile/common/textFileService.i18n.json new file mode 100644 index 00000000000..d3399a79e65 --- /dev/null +++ b/i18n/trk/src/vs/workbench/services/textfile/common/textFileService.i18n.json @@ -0,0 +1,8 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "files.backup.failSave": "Dosyalar yedeklenemedi (Hata: {0}), çıkmak için dosyalarınızı kaydetmeyi deneyin." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/services/textfile/electron-browser/textFileService.i18n.json b/i18n/trk/src/vs/workbench/services/textfile/electron-browser/textFileService.i18n.json new file mode 100644 index 00000000000..5284725dbcb --- /dev/null +++ b/i18n/trk/src/vs/workbench/services/textfile/electron-browser/textFileService.i18n.json @@ -0,0 +1,18 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "saveChangesMessage": "{0} dosyasına yaptığınız değişiklikleri kaydetmek istiyor musunuz?", + "saveChangesMessages": "Aşağıdaki {0} dosyaya yaptığınız değişiklikleri kaydetmek istiyor musunuz?", + "moreFile": "...1 ek dosya gösterilmiyor", + "moreFiles": "...{0} ek dosya gösterilmiyor", + "saveAll": "&&Tümünü Kaydet", + "save": "&&Kaydet", + "dontSave": "Kaydet&&me", + "cancel": "İptal", + "saveChangesDetail": "Değişiklikleriniz, kaydetmezseniz kaybolur.", + "allFiles": "Tüm Dosyalar", + "noExt": "Uzantısız" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/services/themes/common/colorThemeSchema.i18n.json b/i18n/trk/src/vs/workbench/services/themes/common/colorThemeSchema.i18n.json new file mode 100644 index 00000000000..70d9757c255 --- /dev/null +++ b/i18n/trk/src/vs/workbench/services/themes/common/colorThemeSchema.i18n.json @@ -0,0 +1,11 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "schema.colors": "Sentaks vurgulaması renkleri", + "schema.properties.name": "Kuralın açıklaması", + "schema.fontStyle": "Kuralın yazı tipi stili: 'italic', 'bold' ve 'underline' kombinasyonu veya bunlardan bir tanesi", + "schema.tokenColors.path": "Bir tmTheme dosyasının yolu (geçerli dosyaya göreli)" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/services/themes/common/fileIconThemeSchema.i18n.json b/i18n/trk/src/vs/workbench/services/themes/common/fileIconThemeSchema.i18n.json new file mode 100644 index 00000000000..93ef7b84d63 --- /dev/null +++ b/i18n/trk/src/vs/workbench/services/themes/common/fileIconThemeSchema.i18n.json @@ -0,0 +1,37 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "schema.folderExpanded": "Genişletilmiş klasörler için klasör simgesi. Genişletilmiş klasör simgesi isteğe bağlıdır. Ayarlanmazsa, klasör için tanımlanan simge gösterilir.", + "schema.folder": "Daraltılmış klasörler için klasör simgesi; eğer folderExpanded ayarlanmamışsa, genişletilen klasörler için de kullanılır.", + "schema.file": "Varsayılan dosya simgesi, bir uzantı, dosya adı veya dil kimliği ile eşleşmeyen tüm dosyalar için gösterilir.", + "schema.folderNames": "Klasör adlarını simgelerle ilişkilendirir. Nesne anahtarı, herhangi bir yol parçası içermeyen klasör adıdır. Örüntüler veya joker karakterlere izin verilmez. Klasör adı eşleştirme büyük/küçük harfe duyarlı değildir.", + "schema.folderName": "İlişkilendirilecek simge tanımı ID'si.", + "schema.folderNamesExpanded": "Klasör adlarını genişletilmiş klasör simgeleriyle ilişkilendirir. Nesne anahtarı, herhangi bir yol parçası içermeyen klasör adıdır. Örüntüler veya joker karakterlere izin verilmez. Klasör adı eşleştirme büyük/küçük harfe duyarlı değildir.", + "schema.folderNameExpanded": "İlişkilendirilecek simge tanımı ID'si.", + "schema.fileExtensions": "Dosya uzantılarını simgelerle ilişkilendirir. Nesne anahtarı, dosya uzantısı adıdır. Uzantı adı, bir dosya adındaki son noktadan sonraki kısmıdır(nokta dahil değil). Uzantılar büyük/küçük harf ayırt etmeksizin karşılaştırılır.", + "schema.fileExtension": "İlişkilendirilecek simge tanımı ID'si.", + "schema.fileNames": "Dosya adlarını simgelerle ilişkilendirir. Nesne anahtarı, herhangi bir yol parçası içermeyen tam dosya adıdır. Dosya adı noktalar ve olası bir dosya uzantısı içerebilir. Örüntüler veya joker karakterlere izin verilmez. Dosya adı eşleştirme büyük/küçük harfe duyarlı değildir.", + "schema.fileName": "İlişkilendirilecek simge tanımı ID'si.", + "schema.languageIds": "Dilleri simgelerle ilişkilendirir. Nesne anahtarı, dil ekleme noktasında tanımlanan dil kimliğidir.", + "schema.languageId": "İlişkilendirilecek simge tanımı ID'si.", + "schema.fonts": "Simge tanımlarında kullanılacak yazı tipleri.", + "schema.id": "Yazı tipinin ID'si.", + "schema.src": "Yazı tipinin konumları.", + "schema.font-path": "Yazı tipi yolu, geçerli simge teması dosyasına göreli yol.", + "schema.font-format": "Yazı tipinin biçimi.", + "schema.font-weight": "Yazı tipinin kalınlığı.", + "schema.font-sstyle": "Yazı tipinin stili.", + "schema.font-size": "Yazı tipinin varsayılan boyutu.", + "schema.iconDefinitions": "Dosyalar simgelerle ilişkilendirirken kullanılabilecek tüm simgelerin açıklaması.", + "schema.iconDefinition": "Bir simge tanımı. Nesne anahtarı, tanımın ID'sidir.", + "schema.iconPath": "SVG veya PNG kullanırken: Görüntünün yolu. Yol, simge kümesi dosyasına görelidir.", + "schema.fontCharacter": "Glif yazı tipi kullanırken: Kullanılacak yazı tipindeki karakter.", + "schema.fontColor": "Glif yazı tipi kullanırken: Kullanılacak renk.", + "schema.fontSize": "Yazı tipi kullanırken: Metin yazı tipi yüzdesine göre yazı tipi boyutu. Ayarlanmazsa, yazı tipi tanımındaki boyut kullanılır.", + "schema.fontId": "Yazı tipi kullanırken: Yazı tipinin kimliği. Ayarlanmazsa, ilk yazı tipi tanımı varsayılan olarak kullanılır.", + "schema.light": "Açık renk temalarındaki dosya simgeleri için isteğe bağlı ilişkilendirmeler.", + "schema.highContrast": "Yüksek karşıtlık renk temalarındaki dosya simgeleri için isteğe bağlı ilişkilendirmeler." +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/services/themes/electron-browser/colorThemeData.i18n.json b/i18n/trk/src/vs/workbench/services/themes/electron-browser/colorThemeData.i18n.json new file mode 100644 index 00000000000..d00686b6cdd --- /dev/null +++ b/i18n/trk/src/vs/workbench/services/themes/electron-browser/colorThemeData.i18n.json @@ -0,0 +1,13 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "error.cannotparsejson": "JSON tema dosyasını ayrıştırma sorunları: {0}", + "error.invalidformat.colors": "Renk teması dosyasını ayrıştırma sorunu: {0}. 'colors' özelliği 'nesne' türünde değil.", + "error.invalidformat.tokenColors": "Renk teması dosyasını ayrıştırma sorunu: {0}. 'tokenColors' özelliği ya renkleri belirten bir dizi ya da bir text mate tema dosyasının yolunu içermelidir", + "error.plist.invalidformat": "tmTheme tema dosyasını ayrıştırma sorunları: {0}. 'settings' dizi değil", + "error.cannotparse": "tmTheme tema dosyasını ayrıştırma sorunları: {0}", + "error.cannotload": "{0} tmTheme tema dosyasını yükleme sorunları: {1}" +} \ No newline at end of file diff --git a/i18n/trk/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json b/i18n/trk/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json new file mode 100644 index 00000000000..96d6b5ce787 --- /dev/null +++ b/i18n/trk/src/vs/workbench/services/themes/electron-browser/workbenchThemeService.i18n.json @@ -0,0 +1,32 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +// Do not edit this file. It is machine generated. +{ + "vscode.extension.contributes.themes": "Textmate renk temalarına ekleme yapar.", + "vscode.extension.contributes.themes.id": "Kullanıcı ayarlarında kullanılan simge teması Id'si.", + "vscode.extension.contributes.themes.label": "Kullanıcı arayüzünde görünen renk temasının etiketi.", + "vscode.extension.contributes.themes.uiTheme": "Editördeki renkleri tanımlayan temel tema: 'vs' açık renk temasıdır, 'vs-dark' koyu renk temasıdır. 'hc-black' ise yüksek kontrast temasıdır.", + "vscode.extension.contributes.themes.path": "tmLanguage dosyasının yolu. Yol, eklenti klasörüne görecelidir ve genellikle './themes/themeFile.tmTheme'dir.", + "vscode.extension.contributes.iconThemes": "Dosya simgesi temalarına ekleme yapar.", + "vscode.extension.contributes.iconThemes.id": "Kullanıcı ayarlarında kullanılan simge teması Id'si.", + "vscode.extension.contributes.iconThemes.label": "Kullanıcı arayüzünde görünen simge temasının etiketi.", + "vscode.extension.contributes.iconThemes.path": "Simge teması tanımlama dosyasının yolu. Yol, eklenti klasörüne görecelidir ve genellikle './icons/awesome-icon-theme.json'dur.", + "migration.completed": "Yeni tema ayarları kullanıcı ayarlarına eklendi. Yedek, {0} konumunda mevcuttur.", + "error.cannotloadtheme": "{0} yüklenemedi: {1}", + "reqarray": "Eklenti noktası `{0}` bir dizi olmalıdır.", + "reqpath": "`contributes.{0}.path` ögesinde dize bekleniyor. Sağlanan değer: {1}", + "invalid.path.1": "`contributes.{0}.path` ögesinin ({1}) eklentinin klasöründe ({2}) yer alması bekleniyor. Bu, eklentiyi taşınamaz yapabilir.", + "reqid": "`contributes.{0}.id` ögesinde dize bekleniyordu. Belirtilen değer: {1}", + "error.cannotloadicontheme": "{0} yüklenemedi", + "error.cannotparseicontheme": "Dosya simgeleri dosyasını ayrıştırma sorunları: {0}", + "colorTheme": "Çalışma ekranında kullanılan renk temasını belirtir.", + "colorThemeError": "Tema bilinmiyor veya yüklenmemiş.", + "iconTheme": "Çalışma ekranında kullanılan simge temasını belirtir.", + "noIconThemeDesc": "Dosya simgesi yok", + "iconThemeError": "Dosya simgesi teması bilinmiyor veya yüklenmemiş.", + "workbenchColors": "Şu an seçili renk temasındaki renkleri geçersiz kılar.", + "workbenchColors.deprecated": "Ayar, artık deneysel değildir ve 'workbench.colorCustomizations' olarak yeniden adlandırılmıştır", + "workbenchColors.deprecatedDescription": "Bunun yerine 'workbench.colorCustomizations' kullanın" +} \ No newline at end of file -- GitLab From df9ef660190ff6219472dd2ef07f658357708ddf Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Sat, 17 Jun 2017 02:03:44 -0700 Subject: [PATCH 0994/1347] Increase contrast of bright black in solarized terminal Fixes #28288 --- .../theme-solarized-dark/themes/solarized-dark-color-theme.json | 2 +- .../themes/solarized-light-color-theme.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json b/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json index f21572d1c11..5309eb6fd1a 100644 --- a/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json +++ b/extensions/theme-solarized-dark/themes/solarized-dark-color-theme.json @@ -467,7 +467,7 @@ "terminal.ansiMagenta": "#d33682", "terminal.ansiCyan": "#2aa198", "terminal.ansiWhite": "#eee8d5", - "terminal.ansiBrightBlack": "#002b36", + "terminal.ansiBrightBlack": "#586e75", "terminal.ansiBrightRed": "#cb4b16", "terminal.ansiBrightGreen": "#586e75", "terminal.ansiBrightYellow": "#657b83", diff --git a/extensions/theme-solarized-light/themes/solarized-light-color-theme.json b/extensions/theme-solarized-light/themes/solarized-light-color-theme.json index 18414462120..d52a797a35f 100644 --- a/extensions/theme-solarized-light/themes/solarized-light-color-theme.json +++ b/extensions/theme-solarized-light/themes/solarized-light-color-theme.json @@ -470,7 +470,7 @@ "terminal.ansiMagenta": "#d33682", "terminal.ansiCyan": "#2aa198", "terminal.ansiWhite": "#eee8d5", - "terminal.ansiBrightBlack": "#002b36", + "terminal.ansiBrightBlack": "#586e75", "terminal.ansiBrightRed": "#cb4b16", "terminal.ansiBrightGreen": "#586e75", "terminal.ansiBrightYellow": "#657b83", -- GitLab From a38b96765db34988416642ad4f873eccda28f1d4 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Sat, 17 Jun 2017 02:40:18 -0700 Subject: [PATCH 0995/1347] Improve nsfw types --- src/typings/nsfw.d.ts | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/src/typings/nsfw.d.ts b/src/typings/nsfw.d.ts index 8d80f6710b4..9f41a8905ce 100644 --- a/src/typings/nsfw.d.ts +++ b/src/typings/nsfw.d.ts @@ -4,7 +4,16 @@ *--------------------------------------------------------------------------------------------*/ declare module 'nsfw' { - function init(dir: string, ...args: any[]); + interface NsfwFunction { + (dir: string, ...args: any[]): any; + actions: { + CREATED: number; + DELETED: number; + MODIFIED: number; + RENAMED: number; + } + } - export = init; + var nsfw: NsfwFunction; + export = nsfw; } -- GitLab From 00b0ae979f7241441427d711a2d0c954cba66eff Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Sat, 17 Jun 2017 03:04:36 -0700 Subject: [PATCH 0996/1347] Add ThrottledDelayer and event normalization --- .../node/watcher/nsfw/nsfwWatcherService.ts | 87 +++++++++---------- 1 file changed, 42 insertions(+), 45 deletions(-) diff --git a/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts b/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts index 717db358dfb..b314e9a331e 100644 --- a/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts +++ b/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts @@ -8,19 +8,21 @@ import { IWatcherService, IWatcherRequest } from 'vs/workbench/services/files/no import { TPromise } from "vs/base/common/winjs.base"; import watcher = require('vs/workbench/services/files/node/watcher/common'); import * as path from 'path'; +import { ThrottledDelayer } from 'vs/base/common/async'; +import { FileChangeType } from 'vs/platform/files/common/files'; -const nsfwEventActionToRawChangeType = { - 0: 1, // Created - 1: 2, // Deleted - 2: 0, // Modified - // TODO: handle rename event type - 3: null // Rename -}; +const nsfwActionToRawChangeType: { [key: number]: number } = []; +nsfwActionToRawChangeType[nsfw.actions.CREATED] = FileChangeType.ADDED; +nsfwActionToRawChangeType[nsfw.actions.MODIFIED] = FileChangeType.UPDATED; +nsfwActionToRawChangeType[nsfw.actions.DELETED] = FileChangeType.DELETED; export class NsfwWatcherService implements IWatcherService { + private static FS_EVENT_DELAY = 50; // aggregate and only emit events when changes have stopped for this duration (in ms) + public watch(request: IWatcherRequest): TPromise { - console.log('nsfw ' + nsfw); - console.log('basePath ' + request.basePath); + let undeliveredFileEvents: watcher.IRawFileChange[] = []; + const fileEventDelayer = new ThrottledDelayer(NsfwWatcherService.FS_EVENT_DELAY); + return new TPromise((c, e, p) => { nsfw(request.basePath, events => { if (request.verboseLogging) { @@ -28,47 +30,42 @@ export class NsfwWatcherService implements IWatcherService { events.forEach(e => console.log(e)); console.log('raw events end'); } - const convertedEvents: watcher.IRawFileChange[] = []; - events.forEach(e => { - const c = this._mapNsfwEventToRawFileChanges(e); - if (c && c.length) { - c.forEach(c1 => convertedEvents.push(c1)); + + for (let i = 0; i < events.length; i++) { + const e = events[i]; + if (e.action === nsfw.actions.RENAMED) { + // Rename fires when a file's name changes within a single directory + undeliveredFileEvents.push({ type: FileChangeType.DELETED, path: path.join(e.directory, e.oldFile) }); + undeliveredFileEvents.push({ type: FileChangeType.ADDED, path: path.join(e.directory, e.newFile) }); + } else { + undeliveredFileEvents.push({ + type: nsfwActionToRawChangeType[e.action], + path: path.join(e.directory, e.file) + }); } - }); - if (request.verboseLogging) { - console.log('converted events', convertedEvents); } - // TODO: Utilize fileEventDelayer and watcher.normalize - p(convertedEvents); - }).then(watcher => { - return watcher.start(); - }); - }); - } - - private _mapNsfwEventToRawFileChanges(nsfwEvent: any): watcher.IRawFileChange[] { - // TODO: Handle other event types (directory change?) + // Delay and send buffer + fileEventDelayer.trigger(() => { + const events = undeliveredFileEvents; + undeliveredFileEvents = []; - // Convert a rename event to a delete and a create - if (nsfwEvent.action === 3) { - console.log('rename', nsfwEvent); - return [ - { type: 2, path: path.join(nsfwEvent.directory, nsfwEvent.oldFile) }, // Delete - { type: 1, path: path.join(nsfwEvent.directory, nsfwEvent.newFile) } // Create - ]; - } + // Broadcast to clients normalized + const res = watcher.normalize(events); + p(res); - if (!nsfwEvent.directory || !nsfwEvent.file) { - throw new Error('unhandled case'); - // return null; - } - const p = path.join(nsfwEvent.directory, nsfwEvent.file); + // Logging + if (request.verboseLogging) { + res.forEach(r => { + console.log(' >> normalized', r.type === FileChangeType.ADDED ? '[ADDED]' : r.type === FileChangeType.DELETED ? '[DELETED]' : '[CHANGED]', r.path); + }); + } - const event: watcher.IRawFileChange = { - type: nsfwEventActionToRawChangeType[nsfwEvent.action], - path: p - }; - return [event]; + return TPromise.as(null); + }); + }).then(watcher => { + return watcher.start(); + }); + }); } } -- GitLab From b7fab4b8c669870354e87a3fa1453734d58d2f62 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Sat, 17 Jun 2017 03:27:39 -0700 Subject: [PATCH 0997/1347] Support ignored paths --- .../node/watcher/nsfw/nsfwWatcherService.ts | 40 +++++++++++++++---- 1 file changed, 32 insertions(+), 8 deletions(-) diff --git a/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts b/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts index b314e9a331e..d572b239cfd 100644 --- a/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts +++ b/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts @@ -3,11 +3,12 @@ * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ +import * as glob from 'vs/base/common/glob'; +import * as path from 'path'; +import * as watcher from 'vs/workbench/services/files/node/watcher/common'; import nsfw = require('nsfw'); import { IWatcherService, IWatcherRequest } from 'vs/workbench/services/files/node/watcher/unix/watcher'; import { TPromise } from "vs/base/common/winjs.base"; -import watcher = require('vs/workbench/services/files/node/watcher/common'); -import * as path from 'path'; import { ThrottledDelayer } from 'vs/base/common/async'; import { FileChangeType } from 'vs/platform/files/common/files'; @@ -19,7 +20,16 @@ nsfwActionToRawChangeType[nsfw.actions.DELETED] = FileChangeType.DELETED; export class NsfwWatcherService implements IWatcherService { private static FS_EVENT_DELAY = 50; // aggregate and only emit events when changes have stopped for this duration (in ms) + private _ignored: string[]; + + constructor() {} + public watch(request: IWatcherRequest): TPromise { + if (request.verboseLogging) { + console.log('request', request); + } + + this._ignored = request.ignored; let undeliveredFileEvents: watcher.IRawFileChange[] = []; const fileEventDelayer = new ThrottledDelayer(NsfwWatcherService.FS_EVENT_DELAY); @@ -32,16 +42,26 @@ export class NsfwWatcherService implements IWatcherService { } for (let i = 0; i < events.length; i++) { + let absolutePath: string; const e = events[i]; if (e.action === nsfw.actions.RENAMED) { // Rename fires when a file's name changes within a single directory - undeliveredFileEvents.push({ type: FileChangeType.DELETED, path: path.join(e.directory, e.oldFile) }); - undeliveredFileEvents.push({ type: FileChangeType.ADDED, path: path.join(e.directory, e.newFile) }); + absolutePath = path.join(e.directory, e.oldFile); + if (!this._isPathIgnored(absolutePath)) { + undeliveredFileEvents.push({ type: FileChangeType.DELETED, path: absolutePath }); + } + absolutePath = path.join(e.directory, e.newFile); + if (!this._isPathIgnored(absolutePath)) { + undeliveredFileEvents.push({ type: FileChangeType.ADDED, path: absolutePath }); + } } else { - undeliveredFileEvents.push({ - type: nsfwActionToRawChangeType[e.action], - path: path.join(e.directory, e.file) - }); + absolutePath = path.join(e.directory, e.file); + if (!this._isPathIgnored(absolutePath)) { + undeliveredFileEvents.push({ + type: nsfwActionToRawChangeType[e.action], + path: absolutePath + }); + } } } @@ -68,4 +88,8 @@ export class NsfwWatcherService implements IWatcherService { }); }); } + + private _isPathIgnored(absolutePath: string): boolean { + return this._ignored && this._ignored.some(ignore => glob.match(ignore, absolutePath)); + } } -- GitLab From 6645b793b1a741f1b8a6ac88c80207eeb7e90339 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Sat, 17 Jun 2017 03:28:04 -0700 Subject: [PATCH 0998/1347] Improve typings --- src/typings/nsfw.d.ts | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/src/typings/nsfw.d.ts b/src/typings/nsfw.d.ts index 9f41a8905ce..8e0f911eb15 100644 --- a/src/typings/nsfw.d.ts +++ b/src/typings/nsfw.d.ts @@ -4,8 +4,29 @@ *--------------------------------------------------------------------------------------------*/ declare module 'nsfw' { + interface NsfwWatcher { + start(): void; + stop(): void; + } + + interface NsfwWatchingPromise { + then(): void; + } + + interface NsfwStartWatchingPromise { + then(fn: (watcher: NsfwWatcher) => void): NsfwWatchingPromise; + } + + interface NsfwEvent { + action: number; + directory: string; + file?: string; + newFile?: string; + oldFile?: string; + } + interface NsfwFunction { - (dir: string, ...args: any[]): any; + (dir: string, eventHandler: (events: NsfwEvent[]) => void, options?: any): NsfwStartWatchingPromise; actions: { CREATED: number; DELETED: number; -- GitLab From 66154fa1dd6e22217afbb0d4c9e24facc622b50c Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Sat, 17 Jun 2017 04:19:43 -0700 Subject: [PATCH 0999/1347] Allow nsfw file watcher to work alongside others --- src/vs/platform/files/common/files.ts | 1 + src/vs/workbench/buildfile.js | 1 + .../parts/files/browser/files.contribution.ts | 5 + .../files/electron-browser/fileService.ts | 3 +- .../services/files/node/fileService.ts | 25 ++++- .../node/watcher/nsfw/nsfwWatcherService.ts | 19 ++-- .../files/node/watcher/nsfw/watcher.ts | 23 +++++ .../files/node/watcher/nsfw/watcherApp.ts | 14 +++ .../files/node/watcher/nsfw/watcherIpc.ts | 36 ++++++++ .../files/node/watcher/nsfw/watcherService.ts | 92 +++++++++++++++++++ .../files/node/watcher/unix/watcher.ts | 5 + .../files/node/watcher/unix/watcherApp.ts | 4 +- .../files/node/watcher/unix/watcherService.ts | 8 +- 13 files changed, 216 insertions(+), 20 deletions(-) create mode 100644 src/vs/workbench/services/files/node/watcher/nsfw/watcher.ts create mode 100644 src/vs/workbench/services/files/node/watcher/nsfw/watcherApp.ts create mode 100644 src/vs/workbench/services/files/node/watcher/nsfw/watcherIpc.ts create mode 100644 src/vs/workbench/services/files/node/watcher/nsfw/watcherService.ts diff --git a/src/vs/platform/files/common/files.ts b/src/vs/platform/files/common/files.ts index f5616b353fb..702e9190124 100644 --- a/src/vs/platform/files/common/files.ts +++ b/src/vs/platform/files/common/files.ts @@ -538,6 +538,7 @@ export interface IFilesConfiguration { autoSaveDelay: number; eol: string; hotExit: string; + useNsfwFileWatcher: boolean; }; } diff --git a/src/vs/workbench/buildfile.js b/src/vs/workbench/buildfile.js index b4102009d69..576cec8ea90 100644 --- a/src/vs/workbench/buildfile.js +++ b/src/vs/workbench/buildfile.js @@ -24,6 +24,7 @@ exports.collectModules = function (excludes) { createModuleDescription('vs/workbench/services/search/node/searchApp', []), createModuleDescription('vs/workbench/services/search/node/worker/searchWorkerApp', []), createModuleDescription('vs/workbench/services/files/node/watcher/unix/watcherApp', []), + createModuleDescription('vs/workbench/services/files/node/watcher/nsfw/watcherApp', []), createModuleDescription('vs/workbench/node/extensionHostProcess', []), diff --git a/src/vs/workbench/parts/files/browser/files.contribution.ts b/src/vs/workbench/parts/files/browser/files.contribution.ts index 4c4c811c26c..7fe88df5107 100644 --- a/src/vs/workbench/parts/files/browser/files.contribution.ts +++ b/src/vs/workbench/parts/files/browser/files.contribution.ts @@ -275,6 +275,11 @@ configurationRegistry.registerConfiguration({ ], 'description': nls.localize('hotExit', "Controls whether unsaved files are remembered between sessions, allowing the save prompt when exiting the editor to be skipped.", HotExitConfiguration.ON_EXIT, HotExitConfiguration.ON_EXIT_AND_WINDOW_CLOSE) }, + 'files.useNsfwFileWatcher': { + 'type': 'boolean', + 'default': false, + 'description': nls.localize('useNsfwFileWatcher', "Use the new experimental file watcher utilizing the nsfw library.") + }, 'files.defaultLanguage': { 'type': 'string', 'description': nls.localize('defaultLanguage', "The default language mode that is assigned to new files.") diff --git a/src/vs/workbench/services/files/electron-browser/fileService.ts b/src/vs/workbench/services/files/electron-browser/fileService.ts index 4686db922fd..af4a7814979 100644 --- a/src/vs/workbench/services/files/electron-browser/fileService.ts +++ b/src/vs/workbench/services/files/electron-browser/fileService.ts @@ -85,11 +85,12 @@ export class FileService implements IFileService { encodingOverride, watcherIgnoredPatterns, verboseLogging: environmentService.verbose, + useNsfwFileWatcher: configuration.files.useNsfwFileWatcher }; // create service const workspace = this.contextService.getWorkspace(); - this.raw = new NodeFileService(workspace ? workspace.resource.fsPath : void 0, fileServiceConfig); + this.raw = new NodeFileService(workspace ? workspace.resource.fsPath : void 0, fileServiceConfig, contextService); // Listeners this.registerListeners(); diff --git a/src/vs/workbench/services/files/node/fileService.ts b/src/vs/workbench/services/files/node/fileService.ts index 11154b8e8c4..09ca8f8bd56 100644 --- a/src/vs/workbench/services/files/node/fileService.ts +++ b/src/vs/workbench/services/files/node/fileService.ts @@ -26,6 +26,7 @@ import uri from 'vs/base/common/uri'; import nls = require('vs/nls'); import { isWindows, isLinux } from 'vs/base/common/platform'; import { dispose, IDisposable, toDisposable } from 'vs/base/common/lifecycle'; +import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import pfs = require('vs/base/node/pfs'); import encoding = require('vs/base/node/encoding'); @@ -35,6 +36,7 @@ import { FileWatcher as UnixWatcherService } from 'vs/workbench/services/files/n import { FileWatcher as WindowsWatcherService } from 'vs/workbench/services/files/node/watcher/win32/watcherService'; import { toFileChangesEvent, normalize, IRawFileChange } from 'vs/workbench/services/files/node/watcher/common'; import Event, { Emitter } from 'vs/base/common/event'; +import { FileWatcher as NsfwWatcherService } from 'vs/workbench/services/files/node/watcher/nsfw/watcherService'; export interface IEncodingOverride { resource: uri; @@ -51,6 +53,7 @@ export interface IFileServiceOptions { watcherIgnoredPatterns?: string[]; disableWatcher?: boolean; verboseLogging?: boolean; + useNsfwFileWatcher?: boolean; } function etag(stat: fs.Stats): string; @@ -90,7 +93,11 @@ export class FileService implements IFileService { private fileChangesWatchDelayer: ThrottledDelayer; private undeliveredRawFileChangesEvents: IRawFileChange[]; - constructor(basePath: string, options: IFileServiceOptions) { + constructor( + basePath: string, + options: IFileServiceOptions, + private contextService: IWorkspaceContextService + ) { this.toDispose = []; this.basePath = basePath ? paths.normalize(basePath) : void 0; @@ -120,10 +127,15 @@ export class FileService implements IFileService { } if (this.basePath && !this.options.disableWatcher) { - if (isWindows) { - this.setupWin32WorkspaceWatching(); + console.log(this.options); + if (this.options.useNsfwFileWatcher) { + this.setupNsfwWorkspceWatching(); } else { - this.setupUnixWorkspaceWatching(); + if (isWindows) { + this.setupWin32WorkspaceWatching(); + } else { + this.setupUnixWorkspaceWatching(); + } } } @@ -154,6 +166,11 @@ export class FileService implements IFileService { this.toDispose.push(toDisposable(new UnixWatcherService(this.basePath, this.options.watcherIgnoredPatterns, e => this._onFileChanges.fire(e), this.options.errorLogger, this.options.verboseLogging).startWatching())); } + private setupNsfwWorkspceWatching(): void { + const service = new NsfwWatcherService(this.basePath, this.options.watcherIgnoredPatterns, e => this._onFileChanges.fire(e), this.options.errorLogger, this.options.verboseLogging); + this.toDispose.push(toDisposable(service.startWatching())); + } + public resolveFile(resource: uri, options?: IResolveFileOptions): TPromise { return this.resolve(resource, options); } diff --git a/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts b/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts index d572b239cfd..fa39635e569 100644 --- a/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts +++ b/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts @@ -6,9 +6,9 @@ import * as glob from 'vs/base/common/glob'; import * as path from 'path'; import * as watcher from 'vs/workbench/services/files/node/watcher/common'; -import nsfw = require('nsfw'); +import * as nsfw from 'nsfw'; import { IWatcherService, IWatcherRequest } from 'vs/workbench/services/files/node/watcher/unix/watcher'; -import { TPromise } from "vs/base/common/winjs.base"; +import { TPromise } from 'vs/base/common/winjs.base'; import { ThrottledDelayer } from 'vs/base/common/async'; import { FileChangeType } from 'vs/platform/files/common/files'; @@ -20,16 +20,11 @@ nsfwActionToRawChangeType[nsfw.actions.DELETED] = FileChangeType.DELETED; export class NsfwWatcherService implements IWatcherService { private static FS_EVENT_DELAY = 50; // aggregate and only emit events when changes have stopped for this duration (in ms) - private _ignored: string[]; - - constructor() {} - public watch(request: IWatcherRequest): TPromise { if (request.verboseLogging) { console.log('request', request); } - this._ignored = request.ignored; let undeliveredFileEvents: watcher.IRawFileChange[] = []; const fileEventDelayer = new ThrottledDelayer(NsfwWatcherService.FS_EVENT_DELAY); @@ -47,16 +42,16 @@ export class NsfwWatcherService implements IWatcherService { if (e.action === nsfw.actions.RENAMED) { // Rename fires when a file's name changes within a single directory absolutePath = path.join(e.directory, e.oldFile); - if (!this._isPathIgnored(absolutePath)) { + if (!this._isPathIgnored(absolutePath, request.ignored)) { undeliveredFileEvents.push({ type: FileChangeType.DELETED, path: absolutePath }); } absolutePath = path.join(e.directory, e.newFile); - if (!this._isPathIgnored(absolutePath)) { + if (!this._isPathIgnored(absolutePath, request.ignored)) { undeliveredFileEvents.push({ type: FileChangeType.ADDED, path: absolutePath }); } } else { absolutePath = path.join(e.directory, e.file); - if (!this._isPathIgnored(absolutePath)) { + if (!this._isPathIgnored(absolutePath, request.ignored)) { undeliveredFileEvents.push({ type: nsfwActionToRawChangeType[e.action], path: absolutePath @@ -89,7 +84,7 @@ export class NsfwWatcherService implements IWatcherService { }); } - private _isPathIgnored(absolutePath: string): boolean { - return this._ignored && this._ignored.some(ignore => glob.match(ignore, absolutePath)); + private _isPathIgnored(absolutePath: string, ignored: string[]): boolean { + return ignored && ignored.some(ignore => glob.match(ignore, absolutePath)); } } diff --git a/src/vs/workbench/services/files/node/watcher/nsfw/watcher.ts b/src/vs/workbench/services/files/node/watcher/nsfw/watcher.ts new file mode 100644 index 00000000000..2b78d48289f --- /dev/null +++ b/src/vs/workbench/services/files/node/watcher/nsfw/watcher.ts @@ -0,0 +1,23 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +'use strict'; + +import { TPromise } from 'vs/base/common/winjs.base'; + +export interface IWatcherRequest { + basePath: string; + ignored: string[]; + verboseLogging: boolean; +} + +export interface IWatcherService { + watch(request: IWatcherRequest): TPromise; +} + +export interface IFileWatcher { + startWatching(): () => void; + addFolder(folder: string): void; +} \ No newline at end of file diff --git a/src/vs/workbench/services/files/node/watcher/nsfw/watcherApp.ts b/src/vs/workbench/services/files/node/watcher/nsfw/watcherApp.ts new file mode 100644 index 00000000000..6f0942f996e --- /dev/null +++ b/src/vs/workbench/services/files/node/watcher/nsfw/watcherApp.ts @@ -0,0 +1,14 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ +'use strict'; + +import { Server } from 'vs/base/parts/ipc/node/ipc.cp'; +import { WatcherChannel } from 'vs/workbench/services/files/node/watcher/unix/watcherIpc'; +import { NsfwWatcherService } from 'vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService'; + +const server = new Server(); +const service = new NsfwWatcherService(); +const channel = new WatcherChannel(service); +server.registerChannel('watcher', channel); \ No newline at end of file diff --git a/src/vs/workbench/services/files/node/watcher/nsfw/watcherIpc.ts b/src/vs/workbench/services/files/node/watcher/nsfw/watcherIpc.ts new file mode 100644 index 00000000000..f949ab0e6fe --- /dev/null +++ b/src/vs/workbench/services/files/node/watcher/nsfw/watcherIpc.ts @@ -0,0 +1,36 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +'use strict'; + +import { TPromise } from 'vs/base/common/winjs.base'; +import { IChannel } from 'vs/base/parts/ipc/common/ipc'; +import { IWatcherRequest, IWatcherService } from './watcher'; + +export interface IWatcherChannel extends IChannel { + call(command: 'watch', request: IWatcherRequest): TPromise; + call(command: string, arg: any): TPromise; +} + +export class WatcherChannel implements IWatcherChannel { + + constructor(private service: IWatcherService) { } + + call(command: string, arg: any): TPromise { + switch (command) { + case 'watch': return this.service.watch(arg); + } + return undefined; + } +} + +export class WatcherChannelClient implements IWatcherService { + + constructor(private channel: IWatcherChannel) { } + + watch(request: IWatcherRequest): TPromise { + return this.channel.call('watch', request); + } +} \ No newline at end of file diff --git a/src/vs/workbench/services/files/node/watcher/nsfw/watcherService.ts b/src/vs/workbench/services/files/node/watcher/nsfw/watcherService.ts new file mode 100644 index 00000000000..653bed4f4ed --- /dev/null +++ b/src/vs/workbench/services/files/node/watcher/nsfw/watcherService.ts @@ -0,0 +1,92 @@ +/*--------------------------------------------------------------------------------------------- + * Copyright (c) Microsoft Corporation. All rights reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + *--------------------------------------------------------------------------------------------*/ + +'use strict'; + +import { TPromise } from 'vs/base/common/winjs.base'; +import { getNextTickChannel } from 'vs/base/parts/ipc/common/ipc'; +import { Client } from 'vs/base/parts/ipc/node/ipc.cp'; +import uri from 'vs/base/common/uri'; +import { toFileChangesEvent, IRawFileChange } from 'vs/workbench/services/files/node/watcher/common'; +import { IWatcherChannel, WatcherChannelClient } from 'vs/workbench/services/files/node/watcher/unix/watcherIpc'; +import { FileChangesEvent } from 'vs/platform/files/common/files'; +import { IFileWatcher } from "vs/workbench/services/files/node/watcher/unix/watcher"; + +export class FileWatcher implements IFileWatcher { + private static MAX_RESTARTS = 5; + + private isDisposed: boolean; + private restartCounter: number; + + constructor( + private basePath: string, + private ignored: string[], + private onFileChanges: (changes: FileChangesEvent) => void, + private errorLogger: (msg: string) => void, + private verboseLogging: boolean + ) { + this.isDisposed = false; + this.restartCounter = 0; + } + + public startWatching(): () => void { + const args = ['--type=watcherService']; + + const client = new Client( + uri.parse(require.toUrl('bootstrap')).fsPath, + { + serverName: 'Watcher', + args, + env: { + AMD_ENTRYPOINT: 'vs/workbench/services/files/node/watcher/nsfw/watcherApp', + PIPE_LOGGING: 'true', + VERBOSE_LOGGING: this.verboseLogging + } + } + ); + + const channel = getNextTickChannel(client.getChannel('watcher')); + const service = new WatcherChannelClient(channel); + + // Start watching + service.watch({ basePath: this.basePath, ignored: this.ignored, verboseLogging: this.verboseLogging }).then(null, (err) => { + if (!(err instanceof Error && err.name === 'Canceled' && err.message === 'Canceled')) { + return TPromise.wrapError(err); // the service lib uses the promise cancel error to indicate the process died, we do not want to bubble this up + } + return undefined; + }, (events: IRawFileChange[]) => this.onRawFileEvents(events)).done(() => { + + // our watcher app should never be completed because it keeps on watching. being in here indicates + // that the watcher process died and we want to restart it here. we only do it a max number of times + if (!this.isDisposed) { + if (this.restartCounter <= FileWatcher.MAX_RESTARTS) { + this.errorLogger('[FileWatcher] terminated unexpectedly and is restarted again...'); + this.restartCounter++; + // TODO: What do we do for multi-root here? + this.startWatching(); + } else { + this.errorLogger('[FileWatcher] failed to start after retrying for some time, giving up. Please report this as a bug report!'); + } + } + }, this.errorLogger); + + return () => { + client.dispose(); + this.isDisposed = true; + }; + } + + public addFolder(folder: string): void { + console.log('addFolder: ' + folder); + } + + private onRawFileEvents(events: IRawFileChange[]): void { + + // Emit through broadcast service + if (events.length > 0) { + this.onFileChanges(toFileChangesEvent(events)); + } + } +} \ No newline at end of file diff --git a/src/vs/workbench/services/files/node/watcher/unix/watcher.ts b/src/vs/workbench/services/files/node/watcher/unix/watcher.ts index 6961b77f6a2..2b78d48289f 100644 --- a/src/vs/workbench/services/files/node/watcher/unix/watcher.ts +++ b/src/vs/workbench/services/files/node/watcher/unix/watcher.ts @@ -16,3 +16,8 @@ export interface IWatcherRequest { export interface IWatcherService { watch(request: IWatcherRequest): TPromise; } + +export interface IFileWatcher { + startWatching(): () => void; + addFolder(folder: string): void; +} \ No newline at end of file diff --git a/src/vs/workbench/services/files/node/watcher/unix/watcherApp.ts b/src/vs/workbench/services/files/node/watcher/unix/watcherApp.ts index 6f0942f996e..7c91d6c73e3 100644 --- a/src/vs/workbench/services/files/node/watcher/unix/watcherApp.ts +++ b/src/vs/workbench/services/files/node/watcher/unix/watcherApp.ts @@ -6,9 +6,9 @@ import { Server } from 'vs/base/parts/ipc/node/ipc.cp'; import { WatcherChannel } from 'vs/workbench/services/files/node/watcher/unix/watcherIpc'; -import { NsfwWatcherService } from 'vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService'; +import { ChokidarWatcherService } from 'vs/workbench/services/files/node/watcher/unix/chokidarWatcherService'; const server = new Server(); -const service = new NsfwWatcherService(); +const service = new ChokidarWatcherService(); const channel = new WatcherChannel(service); server.registerChannel('watcher', channel); \ No newline at end of file diff --git a/src/vs/workbench/services/files/node/watcher/unix/watcherService.ts b/src/vs/workbench/services/files/node/watcher/unix/watcherService.ts index 1854bcde469..985f1e2281e 100644 --- a/src/vs/workbench/services/files/node/watcher/unix/watcherService.ts +++ b/src/vs/workbench/services/files/node/watcher/unix/watcherService.ts @@ -12,8 +12,9 @@ import uri from 'vs/base/common/uri'; import { toFileChangesEvent, IRawFileChange } from 'vs/workbench/services/files/node/watcher/common'; import { IWatcherChannel, WatcherChannelClient } from 'vs/workbench/services/files/node/watcher/unix/watcherIpc'; import { FileChangesEvent } from 'vs/platform/files/common/files'; +import { IFileWatcher } from "vs/workbench/services/files/node/watcher/unix/watcher"; -export class FileWatcher { +export class FileWatcher implements IFileWatcher { private static MAX_RESTARTS = 5; private isDisposed: boolean; @@ -63,6 +64,7 @@ export class FileWatcher { if (this.restartCounter <= FileWatcher.MAX_RESTARTS) { this.errorLogger('[FileWatcher] terminated unexpectedly and is restarted again...'); this.restartCounter++; + // TODO: What do we do for multi-root here? this.startWatching(); } else { this.errorLogger('[FileWatcher] failed to start after retrying for some time, giving up. Please report this as a bug report!'); @@ -76,6 +78,10 @@ export class FileWatcher { }; } + public addFolder(folder: string): void { + console.log('addFolder: ' + folder); + } + private onRawFileEvents(events: IRawFileChange[]): void { // Emit through broadcast service -- GitLab From 25ab8aaa1cc615aec8029d71a300524e8cbfee80 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Sat, 17 Jun 2017 05:41:22 -0700 Subject: [PATCH 1000/1347] Start working on multiple root file watcher support --- .../services/files/node/fileService.ts | 4 +-- .../node/watcher/nsfw/nsfwWatcherService.ts | 9 +++++- .../files/node/watcher/nsfw/watcher.ts | 1 + .../files/node/watcher/nsfw/watcherApp.ts | 2 +- .../files/node/watcher/nsfw/watcherIpc.ts | 5 +++ .../files/node/watcher/nsfw/watcherService.ts | 31 +++++++++++++++---- .../files/node/watcher/unix/watcher.ts | 5 --- 7 files changed, 41 insertions(+), 16 deletions(-) diff --git a/src/vs/workbench/services/files/node/fileService.ts b/src/vs/workbench/services/files/node/fileService.ts index 09ca8f8bd56..9fb08ad116b 100644 --- a/src/vs/workbench/services/files/node/fileService.ts +++ b/src/vs/workbench/services/files/node/fileService.ts @@ -127,7 +127,6 @@ export class FileService implements IFileService { } if (this.basePath && !this.options.disableWatcher) { - console.log(this.options); if (this.options.useNsfwFileWatcher) { this.setupNsfwWorkspceWatching(); } else { @@ -167,8 +166,7 @@ export class FileService implements IFileService { } private setupNsfwWorkspceWatching(): void { - const service = new NsfwWatcherService(this.basePath, this.options.watcherIgnoredPatterns, e => this._onFileChanges.fire(e), this.options.errorLogger, this.options.verboseLogging); - this.toDispose.push(toDisposable(service.startWatching())); + this.toDispose.push(toDisposable(new NsfwWatcherService(this.basePath, this.options.watcherIgnoredPatterns, e => this._onFileChanges.fire(e), this.options.errorLogger, this.options.verboseLogging, this.contextService).startWatching())); } public resolveFile(resource: uri, options?: IResolveFileOptions): TPromise { diff --git a/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts b/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts index fa39635e569..29cfd0b2fdc 100644 --- a/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts +++ b/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts @@ -7,7 +7,7 @@ import * as glob from 'vs/base/common/glob'; import * as path from 'path'; import * as watcher from 'vs/workbench/services/files/node/watcher/common'; import * as nsfw from 'nsfw'; -import { IWatcherService, IWatcherRequest } from 'vs/workbench/services/files/node/watcher/unix/watcher'; +import { IWatcherService, IWatcherRequest } from 'vs/workbench/services/files/node/watcher/nsfw/watcher'; import { TPromise } from 'vs/base/common/winjs.base'; import { ThrottledDelayer } from 'vs/base/common/async'; import { FileChangeType } from 'vs/platform/files/common/files'; @@ -84,6 +84,13 @@ export class NsfwWatcherService implements IWatcherService { }); } + public setRoots(roots: string[]): TPromise { + console.log('nsfwWatcherService, setRoots', roots); + // TODO: Watch multiple folders + // TODO: Don't watch sub-folders of folders + return TPromise.as(void 0); + } + private _isPathIgnored(absolutePath: string, ignored: string[]): boolean { return ignored && ignored.some(ignore => glob.match(ignore, absolutePath)); } diff --git a/src/vs/workbench/services/files/node/watcher/nsfw/watcher.ts b/src/vs/workbench/services/files/node/watcher/nsfw/watcher.ts index 2b78d48289f..2676e0e2b09 100644 --- a/src/vs/workbench/services/files/node/watcher/nsfw/watcher.ts +++ b/src/vs/workbench/services/files/node/watcher/nsfw/watcher.ts @@ -14,6 +14,7 @@ export interface IWatcherRequest { } export interface IWatcherService { + setRoots(roots: string[]): TPromise; watch(request: IWatcherRequest): TPromise; } diff --git a/src/vs/workbench/services/files/node/watcher/nsfw/watcherApp.ts b/src/vs/workbench/services/files/node/watcher/nsfw/watcherApp.ts index 6f0942f996e..61b892cc45d 100644 --- a/src/vs/workbench/services/files/node/watcher/nsfw/watcherApp.ts +++ b/src/vs/workbench/services/files/node/watcher/nsfw/watcherApp.ts @@ -5,7 +5,7 @@ 'use strict'; import { Server } from 'vs/base/parts/ipc/node/ipc.cp'; -import { WatcherChannel } from 'vs/workbench/services/files/node/watcher/unix/watcherIpc'; +import { WatcherChannel } from 'vs/workbench/services/files/node/watcher/nsfw/watcherIpc'; import { NsfwWatcherService } from 'vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService'; const server = new Server(); diff --git a/src/vs/workbench/services/files/node/watcher/nsfw/watcherIpc.ts b/src/vs/workbench/services/files/node/watcher/nsfw/watcherIpc.ts index f949ab0e6fe..971cdc3594e 100644 --- a/src/vs/workbench/services/files/node/watcher/nsfw/watcherIpc.ts +++ b/src/vs/workbench/services/files/node/watcher/nsfw/watcherIpc.ts @@ -20,6 +20,7 @@ export class WatcherChannel implements IWatcherChannel { call(command: string, arg: any): TPromise { switch (command) { + case 'setRoots': return this.service.setRoots(arg); case 'watch': return this.service.watch(arg); } return undefined; @@ -30,6 +31,10 @@ export class WatcherChannelClient implements IWatcherService { constructor(private channel: IWatcherChannel) { } + setRoots(roots: string[]): TPromise { + return this.channel.call('setRoots', roots); + } + watch(request: IWatcherRequest): TPromise { return this.channel.call('watch', request); } diff --git a/src/vs/workbench/services/files/node/watcher/nsfw/watcherService.ts b/src/vs/workbench/services/files/node/watcher/nsfw/watcherService.ts index 653bed4f4ed..0d739ed5ce1 100644 --- a/src/vs/workbench/services/files/node/watcher/nsfw/watcherService.ts +++ b/src/vs/workbench/services/files/node/watcher/nsfw/watcherService.ts @@ -10,11 +10,11 @@ import { getNextTickChannel } from 'vs/base/parts/ipc/common/ipc'; import { Client } from 'vs/base/parts/ipc/node/ipc.cp'; import uri from 'vs/base/common/uri'; import { toFileChangesEvent, IRawFileChange } from 'vs/workbench/services/files/node/watcher/common'; -import { IWatcherChannel, WatcherChannelClient } from 'vs/workbench/services/files/node/watcher/unix/watcherIpc'; +import { IWatcherChannel, WatcherChannelClient } from 'vs/workbench/services/files/node/watcher/nsfw/watcherIpc'; import { FileChangesEvent } from 'vs/platform/files/common/files'; -import { IFileWatcher } from "vs/workbench/services/files/node/watcher/unix/watcher"; +import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; -export class FileWatcher implements IFileWatcher { +export class FileWatcher { private static MAX_RESTARTS = 5; private isDisposed: boolean; @@ -25,7 +25,8 @@ export class FileWatcher implements IFileWatcher { private ignored: string[], private onFileChanges: (changes: FileChangesEvent) => void, private errorLogger: (msg: string) => void, - private verboseLogging: boolean + private verboseLogging: boolean, + private contextService: IWorkspaceContextService ) { this.isDisposed = false; this.restartCounter = 0; @@ -50,8 +51,11 @@ export class FileWatcher implements IFileWatcher { const channel = getNextTickChannel(client.getChannel('watcher')); const service = new WatcherChannelClient(channel); + const roots = this.contextService.getWorkspace2().roots; + console.log('roots', roots); + // Start watching - service.watch({ basePath: this.basePath, ignored: this.ignored, verboseLogging: this.verboseLogging }).then(null, (err) => { + service.watch({ basePath: roots[0].fsPath, ignored: this.ignored, verboseLogging: this.verboseLogging }).then(null, (err) => { if (!(err instanceof Error && err.name === 'Canceled' && err.message === 'Canceled')) { return TPromise.wrapError(err); // the service lib uses the promise cancel error to indicate the process died, we do not want to bubble this up } @@ -64,7 +68,6 @@ export class FileWatcher implements IFileWatcher { if (this.restartCounter <= FileWatcher.MAX_RESTARTS) { this.errorLogger('[FileWatcher] terminated unexpectedly and is restarted again...'); this.restartCounter++; - // TODO: What do we do for multi-root here? this.startWatching(); } else { this.errorLogger('[FileWatcher] failed to start after retrying for some time, giving up. Please report this as a bug report!'); @@ -72,6 +75,22 @@ export class FileWatcher implements IFileWatcher { } }, this.errorLogger); + for (let i = 1; i < roots.length; i++) { + // TODO: Is ignored is root specific? + console.log('start watching ' + roots[1].fsPath); + service.watch({ basePath: roots[i].fsPath, ignored: this.ignored, verboseLogging: this.verboseLogging }).then(null, (err) => { + if (!(err instanceof Error && err.name === 'Canceled' && err.message === 'Canceled')) { + return TPromise.wrapError(err); // the service lib uses the promise cancel error to indicate the process died, we do not want to bubble this up + } + return undefined; + }, (events: IRawFileChange[]) => this.onRawFileEvents(events)); + } + + this.contextService.onDidChangeWorkspaceRoots(roots => { + service.setRoots(roots.map(r => r.fsPath)); + console.log('roots changed', roots); + }); + return () => { client.dispose(); this.isDisposed = true; diff --git a/src/vs/workbench/services/files/node/watcher/unix/watcher.ts b/src/vs/workbench/services/files/node/watcher/unix/watcher.ts index 2b78d48289f..6961b77f6a2 100644 --- a/src/vs/workbench/services/files/node/watcher/unix/watcher.ts +++ b/src/vs/workbench/services/files/node/watcher/unix/watcher.ts @@ -16,8 +16,3 @@ export interface IWatcherRequest { export interface IWatcherService { watch(request: IWatcherRequest): TPromise; } - -export interface IFileWatcher { - startWatching(): () => void; - addFolder(folder: string): void; -} \ No newline at end of file -- GitLab From da35479b6227fc987625b6ba95db5ee310c6bf6d Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Sat, 17 Jun 2017 15:25:24 -0700 Subject: [PATCH 1001/1347] Improve nsfw logging --- .../node/watcher/nsfw/nsfwWatcherService.ts | 16 +++++++++------- .../files/node/watcher/unix/watcherService.ts | 3 +-- 2 files changed, 10 insertions(+), 9 deletions(-) diff --git a/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts b/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts index 29cfd0b2fdc..54208ee9e4c 100644 --- a/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts +++ b/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts @@ -30,15 +30,17 @@ export class NsfwWatcherService implements IWatcherService { return new TPromise((c, e, p) => { nsfw(request.basePath, events => { - if (request.verboseLogging) { - console.log('raw events start'); - events.forEach(e => console.log(e)); - console.log('raw events end'); - } - for (let i = 0; i < events.length; i++) { - let absolutePath: string; const e = events[i]; + + // Logging + if (request.verboseLogging) { + const logPath = e.action === nsfw.actions.RENAMED ? path.join(e.directory, e.oldFile) + ' -> ' + e.newFile : path.join(e.directory, e.file); + console.log(e.action === nsfw.actions.CREATED ? '[CREATED]' : e.action === nsfw.actions.DELETED ? '[DELETED]' : e.action === nsfw.actions.MODIFIED ? '[CHANGED]' : '[RENAMED]', logPath); + } + + // Convert nsfw event to IRawFileChange and add to queue + let absolutePath: string; if (e.action === nsfw.actions.RENAMED) { // Rename fires when a file's name changes within a single directory absolutePath = path.join(e.directory, e.oldFile); diff --git a/src/vs/workbench/services/files/node/watcher/unix/watcherService.ts b/src/vs/workbench/services/files/node/watcher/unix/watcherService.ts index 985f1e2281e..938b8ab2d60 100644 --- a/src/vs/workbench/services/files/node/watcher/unix/watcherService.ts +++ b/src/vs/workbench/services/files/node/watcher/unix/watcherService.ts @@ -12,9 +12,8 @@ import uri from 'vs/base/common/uri'; import { toFileChangesEvent, IRawFileChange } from 'vs/workbench/services/files/node/watcher/common'; import { IWatcherChannel, WatcherChannelClient } from 'vs/workbench/services/files/node/watcher/unix/watcherIpc'; import { FileChangesEvent } from 'vs/platform/files/common/files'; -import { IFileWatcher } from "vs/workbench/services/files/node/watcher/unix/watcher"; -export class FileWatcher implements IFileWatcher { +export class FileWatcher { private static MAX_RESTARTS = 5; private isDisposed: boolean; -- GitLab From e6f03c842acdfc53fffcba1b690cf38bdb399a3f Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Sat, 17 Jun 2017 16:19:17 -0700 Subject: [PATCH 1002/1347] Support basic multi root watching --- .../node/watcher/nsfw/nsfwWatcherService.ts | 48 +++++++++++++++++-- .../files/node/watcher/nsfw/watcherService.ts | 20 +------- 2 files changed, 46 insertions(+), 22 deletions(-) diff --git a/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts b/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts index 54208ee9e4c..9e699022ca0 100644 --- a/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts +++ b/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts @@ -17,9 +17,16 @@ nsfwActionToRawChangeType[nsfw.actions.CREATED] = FileChangeType.ADDED; nsfwActionToRawChangeType[nsfw.actions.MODIFIED] = FileChangeType.UPDATED; nsfwActionToRawChangeType[nsfw.actions.DELETED] = FileChangeType.DELETED; + +interface IPathWatcher { + watcher?: any; +} + export class NsfwWatcherService implements IWatcherService { private static FS_EVENT_DELAY = 50; // aggregate and only emit events when changes have stopped for this duration (in ms) + private _pathWatchers: { [watchPath: string]: IPathWatcher } = {}; + public watch(request: IWatcherRequest): TPromise { if (request.verboseLogging) { console.log('request', request); @@ -28,7 +35,10 @@ export class NsfwWatcherService implements IWatcherService { let undeliveredFileEvents: watcher.IRawFileChange[] = []; const fileEventDelayer = new ThrottledDelayer(NsfwWatcherService.FS_EVENT_DELAY); - return new TPromise((c, e, p) => { + console.log('starting to watch ' + request.basePath); + this._pathWatchers[request.basePath] = {}; + + const promise = new TPromise((c, e, p) => { nsfw(request.basePath, events => { for (let i = 0; i < events.length; i++) { const e = events[i]; @@ -81,16 +91,48 @@ export class NsfwWatcherService implements IWatcherService { return TPromise.as(null); }); }).then(watcher => { + console.log('watcher ready ' + request.basePath); + this._pathWatchers[request.basePath].watcher = watcher; return watcher.start(); }); }); + + return promise; } public setRoots(roots: string[]): TPromise { - console.log('nsfwWatcherService, setRoots', roots); + const rootsToStartWatching = roots.filter(r => !(r in this._pathWatchers)); + const rootsToStopWatching = Object.keys(this._pathWatchers).filter(r => roots.indexOf(r) === -1); + + // TODO: Don't watch inner folders + // TODO: Move verboseLogging to constructor + // Logging + if (true) { + console.log(`Set watch roots: start: [${rootsToStartWatching.join(',')}], stop: [${rootsToStopWatching.join(',')}]`); + } + + const promises: TPromise[] = []; + if (rootsToStartWatching.length) { + rootsToStartWatching.forEach(root => { + promises.push(this.watch({ + basePath: root, + ignored: [], + // TODO: Inherit from initial request + verboseLogging: true + })); + }); + } + + if (rootsToStopWatching.length) { + rootsToStopWatching.forEach(root => { + this._pathWatchers[root].watcher.stop(); + delete this._pathWatchers[root]; + }); + } + // TODO: Watch multiple folders // TODO: Don't watch sub-folders of folders - return TPromise.as(void 0); + return TPromise.join(promises).then(() => void 0); } private _isPathIgnored(absolutePath: string, ignored: string[]): boolean { diff --git a/src/vs/workbench/services/files/node/watcher/nsfw/watcherService.ts b/src/vs/workbench/services/files/node/watcher/nsfw/watcherService.ts index 0d739ed5ce1..cc5bb1f690d 100644 --- a/src/vs/workbench/services/files/node/watcher/nsfw/watcherService.ts +++ b/src/vs/workbench/services/files/node/watcher/nsfw/watcherService.ts @@ -51,11 +51,8 @@ export class FileWatcher { const channel = getNextTickChannel(client.getChannel('watcher')); const service = new WatcherChannelClient(channel); - const roots = this.contextService.getWorkspace2().roots; - console.log('roots', roots); - // Start watching - service.watch({ basePath: roots[0].fsPath, ignored: this.ignored, verboseLogging: this.verboseLogging }).then(null, (err) => { + service.watch({ basePath: this.basePath, ignored: this.ignored, verboseLogging: this.verboseLogging }).then(null, (err) => { if (!(err instanceof Error && err.name === 'Canceled' && err.message === 'Canceled')) { return TPromise.wrapError(err); // the service lib uses the promise cancel error to indicate the process died, we do not want to bubble this up } @@ -75,17 +72,6 @@ export class FileWatcher { } }, this.errorLogger); - for (let i = 1; i < roots.length; i++) { - // TODO: Is ignored is root specific? - console.log('start watching ' + roots[1].fsPath); - service.watch({ basePath: roots[i].fsPath, ignored: this.ignored, verboseLogging: this.verboseLogging }).then(null, (err) => { - if (!(err instanceof Error && err.name === 'Canceled' && err.message === 'Canceled')) { - return TPromise.wrapError(err); // the service lib uses the promise cancel error to indicate the process died, we do not want to bubble this up - } - return undefined; - }, (events: IRawFileChange[]) => this.onRawFileEvents(events)); - } - this.contextService.onDidChangeWorkspaceRoots(roots => { service.setRoots(roots.map(r => r.fsPath)); console.log('roots changed', roots); @@ -97,10 +83,6 @@ export class FileWatcher { }; } - public addFolder(folder: string): void { - console.log('addFolder: ' + folder); - } - private onRawFileEvents(events: IRawFileChange[]): void { // Emit through broadcast service -- GitLab From 9948719a1297a079e72d652eec84997a4f10b73e Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Sat, 17 Jun 2017 16:34:54 -0700 Subject: [PATCH 1003/1347] Fix test compilation --- .../services/backup/test/node/backupFileService.test.ts | 3 ++- .../test/node/configurationEditingService.test.ts | 4 ++-- .../workbench/services/files/test/node/fileService.test.ts | 7 ++++--- .../keybinding/test/node/keybindingEditing.test.ts | 2 +- 4 files changed, 9 insertions(+), 7 deletions(-) diff --git a/src/vs/workbench/services/backup/test/node/backupFileService.test.ts b/src/vs/workbench/services/backup/test/node/backupFileService.test.ts index 838f9333945..a6eb9b517d6 100644 --- a/src/vs/workbench/services/backup/test/node/backupFileService.test.ts +++ b/src/vs/workbench/services/backup/test/node/backupFileService.test.ts @@ -19,6 +19,7 @@ import { FileService } from 'vs/workbench/services/files/node/fileService'; import { EnvironmentService } from 'vs/platform/environment/node/environmentService'; import { parseArgs } from 'vs/platform/environment/node/argv'; import { RawTextSource } from 'vs/editor/common/model/textSource'; +import { TestContextService } from 'vs/workbench/test/workbenchTestServices'; class TestEnvironmentService extends EnvironmentService { @@ -47,7 +48,7 @@ const untitledBackupPath = path.join(workspaceBackupPath, 'untitled', crypto.cre class TestBackupFileService extends BackupFileService { constructor(workspace: Uri, backupHome: string, workspacesJsonPath: string) { - const fileService = new FileService(workspace.fsPath, { disableWatcher: true }); + const fileService = new FileService(workspace.fsPath, { disableWatcher: true }, new TestContextService()); super(workspaceBackupPath, fileService); } diff --git a/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts b/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts index 8ad27dc8ed3..57e0ce505d0 100644 --- a/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts +++ b/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts @@ -18,7 +18,7 @@ import { parseArgs } from 'vs/platform/environment/node/argv'; import { IWorkspaceContextService, LegacyWorkspace } from 'vs/platform/workspace/common/workspace'; import { EnvironmentService } from 'vs/platform/environment/node/environmentService'; import extfs = require('vs/base/node/extfs'); -import { TestTextFileService, TestEditorGroupService, TestLifecycleService, TestBackupFileService } from 'vs/workbench/test/workbenchTestServices'; +import { TestTextFileService, TestEditorGroupService, TestLifecycleService, TestBackupFileService, TestContextService } from 'vs/workbench/test/workbenchTestServices'; import uuid = require('vs/base/common/uuid'); import { IConfigurationRegistry, Extensions as ConfigurationExtensions } from 'vs/platform/configuration/common/configurationRegistry'; import { WorkspaceConfigurationService } from 'vs/workbench/services/configuration/node/configuration'; @@ -124,7 +124,7 @@ suite('ConfigurationEditingService', () => { instantiationService.stub(ITelemetryService, NullTelemetryService); instantiationService.stub(IModeService, ModeServiceImpl); instantiationService.stub(IModelService, instantiationService.createInstance(ModelServiceImpl)); - instantiationService.stub(IFileService, new FileService(workspaceDir, { disableWatcher: true })); + instantiationService.stub(IFileService, new FileService(workspaceDir, { disableWatcher: true }, new TestContextService())); instantiationService.stub(IUntitledEditorService, instantiationService.createInstance(UntitledEditorService)); instantiationService.stub(ITextFileService, instantiationService.createInstance(TestTextFileService)); diff --git a/src/vs/workbench/services/files/test/node/fileService.test.ts b/src/vs/workbench/services/files/test/node/fileService.test.ts index 846d09bda8d..4622af59cda 100644 --- a/src/vs/workbench/services/files/test/node/fileService.test.ts +++ b/src/vs/workbench/services/files/test/node/fileService.test.ts @@ -19,6 +19,7 @@ import extfs = require('vs/base/node/extfs'); import encodingLib = require('vs/base/node/encoding'); import utils = require('vs/workbench/services/files/test/node/utils'); import { onError } from 'vs/base/test/common/utils'; +import { TestContextService } from "vs/workbench/test/workbenchTestServices"; suite('FileService', () => { let service: FileService; @@ -35,7 +36,7 @@ suite('FileService', () => { return onError(error, done); } - service = new FileService(testDir, { disableWatcher: true }); + service = new FileService(testDir, { disableWatcher: true }, new TestContextService()); done(); }); }); @@ -735,7 +736,7 @@ suite('FileService', () => { encoding: 'windows1252', encodingOverride: encodingOverride, disableWatcher: true - }); + }, new TestContextService()); _service.resolveContent(uri.file(path.join(testDir, 'index.html'))).done(c => { assert.equal(c.encoding, 'windows1252'); @@ -761,7 +762,7 @@ suite('FileService', () => { let _service = new FileService(_testDir, { disableWatcher: true - }); + }, new TestContextService()); extfs.copy(_sourceDir, _testDir, () => { fs.readFile(resource.fsPath, (error, data) => { diff --git a/src/vs/workbench/services/keybinding/test/node/keybindingEditing.test.ts b/src/vs/workbench/services/keybinding/test/node/keybindingEditing.test.ts index dc64fc81dfd..6c72dc9a758 100644 --- a/src/vs/workbench/services/keybinding/test/node/keybindingEditing.test.ts +++ b/src/vs/workbench/services/keybinding/test/node/keybindingEditing.test.ts @@ -73,7 +73,7 @@ suite('Keybindings Editing', () => { instantiationService.stub(ITelemetryService, NullTelemetryService); instantiationService.stub(IModeService, ModeServiceImpl); instantiationService.stub(IModelService, instantiationService.createInstance(ModelServiceImpl)); - instantiationService.stub(IFileService, new FileService(testDir, { disableWatcher: true })); + instantiationService.stub(IFileService, new FileService(testDir, { disableWatcher: true }, new TestContextService())); instantiationService.stub(IUntitledEditorService, instantiationService.createInstance(UntitledEditorService)); instantiationService.stub(ITextFileService, instantiationService.createInstance(TestTextFileService)); instantiationService.stub(ITextModelService, instantiationService.createInstance(TextModelResolverService)); -- GitLab From 7ffcc1987c7d148e4d48654d111278a4045f6ccc Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Sat, 17 Jun 2017 16:54:43 -0700 Subject: [PATCH 1004/1347] Clean up --- .../test/node/configurationEditingService.test.ts | 4 ++-- .../services/files/node/watcher/nsfw/nsfwWatcherService.ts | 6 ++++-- .../services/files/node/watcher/unix/watcherService.ts | 4 ---- 3 files changed, 6 insertions(+), 8 deletions(-) diff --git a/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts b/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts index 57e0ce505d0..6879f91ee30 100644 --- a/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts +++ b/src/vs/workbench/services/configuration/test/node/configurationEditingService.test.ts @@ -18,7 +18,7 @@ import { parseArgs } from 'vs/platform/environment/node/argv'; import { IWorkspaceContextService, LegacyWorkspace } from 'vs/platform/workspace/common/workspace'; import { EnvironmentService } from 'vs/platform/environment/node/environmentService'; import extfs = require('vs/base/node/extfs'); -import { TestTextFileService, TestEditorGroupService, TestLifecycleService, TestBackupFileService, TestContextService } from 'vs/workbench/test/workbenchTestServices'; +import { TestTextFileService, TestEditorGroupService, TestLifecycleService, TestBackupFileService } from 'vs/workbench/test/workbenchTestServices'; import uuid = require('vs/base/common/uuid'); import { IConfigurationRegistry, Extensions as ConfigurationExtensions } from 'vs/platform/configuration/common/configurationRegistry'; import { WorkspaceConfigurationService } from 'vs/workbench/services/configuration/node/configuration'; @@ -124,7 +124,7 @@ suite('ConfigurationEditingService', () => { instantiationService.stub(ITelemetryService, NullTelemetryService); instantiationService.stub(IModeService, ModeServiceImpl); instantiationService.stub(IModelService, instantiationService.createInstance(ModelServiceImpl)); - instantiationService.stub(IFileService, new FileService(workspaceDir, { disableWatcher: true }, new TestContextService())); + instantiationService.stub(IFileService, instantiationService.createInstance(FileService, workspaceDir, { disableWatcher: true })); instantiationService.stub(IUntitledEditorService, instantiationService.createInstance(UntitledEditorService)); instantiationService.stub(ITextFileService, instantiationService.createInstance(TestTextFileService)); diff --git a/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts b/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts index 9e699022ca0..57bbbcd42b5 100644 --- a/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts +++ b/src/vs/workbench/services/files/node/watcher/nsfw/nsfwWatcherService.ts @@ -19,7 +19,10 @@ nsfwActionToRawChangeType[nsfw.actions.DELETED] = FileChangeType.DELETED; interface IPathWatcher { - watcher?: any; + watcher?: { + start(): void; + stop(): void; + }; } export class NsfwWatcherService implements IWatcherService { @@ -130,7 +133,6 @@ export class NsfwWatcherService implements IWatcherService { }); } - // TODO: Watch multiple folders // TODO: Don't watch sub-folders of folders return TPromise.join(promises).then(() => void 0); } diff --git a/src/vs/workbench/services/files/node/watcher/unix/watcherService.ts b/src/vs/workbench/services/files/node/watcher/unix/watcherService.ts index 938b8ab2d60..241ffa853ca 100644 --- a/src/vs/workbench/services/files/node/watcher/unix/watcherService.ts +++ b/src/vs/workbench/services/files/node/watcher/unix/watcherService.ts @@ -77,10 +77,6 @@ export class FileWatcher { }; } - public addFolder(folder: string): void { - console.log('addFolder: ' + folder); - } - private onRawFileEvents(events: IRawFileChange[]): void { // Emit through broadcast service -- GitLab From be5549113b3b2000d0c941832c91d5d434018a90 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Sat, 17 Jun 2017 16:57:11 -0700 Subject: [PATCH 1005/1347] Fix unit tests Broken in e7fc27d746ffc5ad490814d24d49c699213024a8 --- src/vs/workbench/services/textfile/common/textFileService.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vs/workbench/services/textfile/common/textFileService.ts b/src/vs/workbench/services/textfile/common/textFileService.ts index 07ffc8ceeb7..65fed25b13a 100644 --- a/src/vs/workbench/services/textfile/common/textFileService.ts +++ b/src/vs/workbench/services/textfile/common/textFileService.ts @@ -342,7 +342,7 @@ export abstract class TextFileService implements ITextFileService { } // Hot exit - const hotExitMode = configuration && configuration.files && configuration.files.hotExit; + const hotExitMode = configuration && configuration.files ? configuration.files.hotExit : HotExitConfiguration.OFF; if (hotExitMode === HotExitConfiguration.OFF || hotExitMode === HotExitConfiguration.ON_EXIT_AND_WINDOW_CLOSE) { this.configuredHotExit = hotExitMode; } else { -- GitLab From f7eefb63084e0d7c016733ef11833a0335949760 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Sun, 18 Jun 2017 00:30:25 -0700 Subject: [PATCH 1006/1347] Add files.useExperimentalFileWatcher setting --- src/vs/platform/files/common/files.ts | 2 +- src/vs/workbench/parts/files/browser/files.contribution.ts | 4 ++-- .../workbench/services/files/electron-browser/fileService.ts | 2 +- src/vs/workbench/services/files/node/fileService.ts | 4 ++-- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/vs/platform/files/common/files.ts b/src/vs/platform/files/common/files.ts index 702e9190124..54d5089bb3c 100644 --- a/src/vs/platform/files/common/files.ts +++ b/src/vs/platform/files/common/files.ts @@ -538,7 +538,7 @@ export interface IFilesConfiguration { autoSaveDelay: number; eol: string; hotExit: string; - useNsfwFileWatcher: boolean; + useExperimentalFileWatcher: boolean; }; } diff --git a/src/vs/workbench/parts/files/browser/files.contribution.ts b/src/vs/workbench/parts/files/browser/files.contribution.ts index 7fe88df5107..c7f4a9eecf0 100644 --- a/src/vs/workbench/parts/files/browser/files.contribution.ts +++ b/src/vs/workbench/parts/files/browser/files.contribution.ts @@ -275,10 +275,10 @@ configurationRegistry.registerConfiguration({ ], 'description': nls.localize('hotExit', "Controls whether unsaved files are remembered between sessions, allowing the save prompt when exiting the editor to be skipped.", HotExitConfiguration.ON_EXIT, HotExitConfiguration.ON_EXIT_AND_WINDOW_CLOSE) }, - 'files.useNsfwFileWatcher': { + 'files.useExperimentalFileWatcher': { 'type': 'boolean', 'default': false, - 'description': nls.localize('useNsfwFileWatcher', "Use the new experimental file watcher utilizing the nsfw library.") + 'description': nls.localize('useExperimentalFileWatcher', "Use the new experimental file watcher.") }, 'files.defaultLanguage': { 'type': 'string', diff --git a/src/vs/workbench/services/files/electron-browser/fileService.ts b/src/vs/workbench/services/files/electron-browser/fileService.ts index af4a7814979..12d8052b9d1 100644 --- a/src/vs/workbench/services/files/electron-browser/fileService.ts +++ b/src/vs/workbench/services/files/electron-browser/fileService.ts @@ -85,7 +85,7 @@ export class FileService implements IFileService { encodingOverride, watcherIgnoredPatterns, verboseLogging: environmentService.verbose, - useNsfwFileWatcher: configuration.files.useNsfwFileWatcher + useExperimentalFileWatcher: configuration.files.useExperimentalFileWatcher }; // create service diff --git a/src/vs/workbench/services/files/node/fileService.ts b/src/vs/workbench/services/files/node/fileService.ts index 9fb08ad116b..2c1291608a2 100644 --- a/src/vs/workbench/services/files/node/fileService.ts +++ b/src/vs/workbench/services/files/node/fileService.ts @@ -53,7 +53,7 @@ export interface IFileServiceOptions { watcherIgnoredPatterns?: string[]; disableWatcher?: boolean; verboseLogging?: boolean; - useNsfwFileWatcher?: boolean; + useExperimentalFileWatcher?: boolean; } function etag(stat: fs.Stats): string; @@ -127,7 +127,7 @@ export class FileService implements IFileService { } if (this.basePath && !this.options.disableWatcher) { - if (this.options.useNsfwFileWatcher) { + if (this.options.useExperimentalFileWatcher) { this.setupNsfwWorkspceWatching(); } else { if (isWindows) { -- GitLab From cee711bb235eb181b7e344f752978aeee937d229 Mon Sep 17 00:00:00 2001 From: Georgios Andreadis Date: Sun, 18 Jun 2017 11:35:07 +0200 Subject: [PATCH 1007/1347] Improve grammar of config setting description While the former version is technically correct, I consider the proposed version easier to read. --- extensions/git/package.nls.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/extensions/git/package.nls.json b/extensions/git/package.nls.json index c34b7166da3..655074654b2 100644 --- a/extensions/git/package.nls.json +++ b/extensions/git/package.nls.json @@ -40,5 +40,5 @@ "config.ignoreLegacyWarning": "Ignores the legacy Git warning", "config.ignoreLimitWarning": "Ignores the warning when there are too many changes in a repository", "config.defaultCloneDirectory": "The default location where to clone a git repository", - "config.enableSmartCommit": "Commit all changes when there are not staged changes." -} \ No newline at end of file + "config.enableSmartCommit": "Commit all changes when there are no staged changes." +} -- GitLab From 2303df3f9861f5c5db745a6d46a903b71100c451 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Sun, 18 Jun 2017 11:18:51 -0700 Subject: [PATCH 1008/1347] Have navigate workbench commands skip terminal shell by default Fixes #28485 --- .../terminal/electron-browser/terminal.contribution.ts | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts index b12e4812b9b..dcf95c68589 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminal.contribution.ts @@ -29,6 +29,7 @@ import { KeybindingsRegistry } from 'vs/platform/keybinding/common/keybindingsRe import { OpenNextRecentlyUsedEditorInGroupAction, OpenPreviousRecentlyUsedEditorInGroupAction, FocusActiveGroupAction, FocusFirstGroupAction, FocusSecondGroupAction, FocusThirdGroupAction } from 'vs/workbench/browser/parts/editor/editorActions'; import { EDITOR_FONT_DEFAULTS } from 'vs/editor/common/config/editorOptions'; import { registerColors } from './terminalColorRegistry'; +import { NavigateUpAction, NavigateDownAction, NavigateLeftAction, NavigateRightAction } from "vs/workbench/electron-browser/actions"; let configurationRegistry = Registry.as(Extensions.Configuration); configurationRegistry.registerConfiguration({ @@ -188,7 +189,11 @@ configurationRegistry.registerConfiguration({ FocusThirdGroupAction.ID, SelectAllTerminalAction.ID, FocusTerminalFindWidgetAction.ID, - HideTerminalFindWidgetAction.ID + HideTerminalFindWidgetAction.ID, + NavigateUpAction.ID, + NavigateDownAction.ID, + NavigateRightAction.ID, + NavigateLeftAction.ID ].sort() } } -- GitLab From 435f1efb9e5e83a439c9b6492c7e3a807b3a5007 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Sun, 18 Jun 2017 11:26:31 -0700 Subject: [PATCH 1009/1347] Add terminal.selectionBackground theme key Fixes #28397 --- .../parts/terminal/electron-browser/media/xterm.css | 8 -------- .../electron-browser/terminalColorRegistry.ts | 7 ++++++- .../parts/terminal/electron-browser/terminalPanel.ts | 12 ++++-------- 3 files changed, 10 insertions(+), 17 deletions(-) diff --git a/src/vs/workbench/parts/terminal/electron-browser/media/xterm.css b/src/vs/workbench/parts/terminal/electron-browser/media/xterm.css index 66487fab214..866fc265e4f 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/media/xterm.css +++ b/src/vs/workbench/parts/terminal/electron-browser/media/xterm.css @@ -140,14 +140,6 @@ .monaco-workbench .panel.integrated-terminal .xterm .xterm-selection div { position: absolute; - opacity: 0.5; - background-color: #808080; -} -.vs-dark .monaco-workbench .panel.integrated-terminal .xterm .xterm-selection div { - background-color: #808080; -} -.hc-black .monaco-workbench .panel.integrated-terminal .xterm .xterm-selection div { - background-color: #FFF; } .monaco-workbench .panel.integrated-terminal .xterm .xterm-bold { diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.ts index ae1d524a912..92206287ac9 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalColorRegistry.ts @@ -17,8 +17,13 @@ export const TERMINAL_BACKGROUND_COLOR = registerColor('terminal.background', nu export const TERMINAL_FOREGROUND_COLOR = registerColor('terminal.foreground', { light: '#333333', dark: '#CCCCCC', - hc: 'FFFFFF' + hc: '#FFFFFF' }, nls.localize('terminal.foreground', 'The foreground color of the terminal.')); +export const TERMINAL_SELECTION_BACKGROUND_COLOR = registerColor('terminal.selectionBackground', { + light: '#B0B0B0', + dark: '#404040', + hc: '#808080' +}, nls.localize('terminal.selectionBackground', 'The selection background color of the terminal.')); const ansiColorMap = { 'terminal.ansiBlack': { diff --git a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts index ee922268212..7d362f8440b 100644 --- a/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts +++ b/src/vs/workbench/parts/terminal/electron-browser/terminalPanel.ts @@ -16,8 +16,8 @@ import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry'; import { ITerminalService, ITerminalFont, TERMINAL_PANEL_ID } from 'vs/workbench/parts/terminal/common/terminal'; import { IThemeService, ITheme } from 'vs/platform/theme/common/themeService'; import { TerminalFindWidget } from './terminalFindWidget'; -import { ansiColorIdentifiers, TERMINAL_BACKGROUND_COLOR, TERMINAL_FOREGROUND_COLOR } from './terminalColorRegistry'; -import { ColorIdentifier, selectionBackground } from 'vs/platform/theme/common/colorRegistry'; +import { ansiColorIdentifiers, TERMINAL_BACKGROUND_COLOR, TERMINAL_FOREGROUND_COLOR, TERMINAL_SELECTION_BACKGROUND_COLOR } from './terminalColorRegistry'; +import { ColorIdentifier } from 'vs/platform/theme/common/colorRegistry'; import { KillTerminalAction, CreateNewTerminalAction, SwitchTerminalInstanceAction, SwitchTerminalInstanceActionItem, CopyTerminalSelectionAction, TerminalPasteAction, ClearTerminalAction } from 'vs/workbench/parts/terminal/electron-browser/terminalActions'; import { Panel } from 'vs/workbench/browser/panel'; import { StandardMouseEvent } from 'vs/base/browser/mouseEvent'; @@ -277,13 +277,9 @@ export class TerminalPanel extends Panel { `.monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-bar.focus.xterm-cursor-blink .terminal-cursor::before,` + `.monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-underline.focus.xterm-cursor-blink .terminal-cursor::before { background-color: ${fgColor}; }`; } - // Use selection.background as the terminal selection, this is temporary - // until proper color inverting is implemented to ensure contrast. - const selectionColor = theme.getColor(selectionBackground); + const selectionColor = theme.getColor(TERMINAL_SELECTION_BACKGROUND_COLOR); if (selectionColor) { - // selection.background is set to null when not defined by the - // theme, as such it's default values are defined in CSS. - css += `.monaco-workbench .panel.integrated-terminal .xterm .xterm-selection div { background-color: ${selectionColor} !important; }`; + css += `.monaco-workbench .panel.integrated-terminal .xterm .xterm-selection div { background-color: ${selectionColor}; }`; } this._themeStyleElement.innerHTML = css; -- GitLab From 654adde404aa6c48bd9e6d22396d7e117c4f94b0 Mon Sep 17 00:00:00 2001 From: Daniel Imms Date: Sun, 18 Jun 2017 13:10:49 -0700 Subject: [PATCH 1010/1347] Uplevel xterm.js Fixes #28969 Fixes #28972 Fixes #28973 --- npm-shrinkwrap.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/npm-shrinkwrap.json b/npm-shrinkwrap.json index 313e3854986..5b4e3fbfb19 100644 --- a/npm-shrinkwrap.json +++ b/npm-shrinkwrap.json @@ -447,7 +447,7 @@ "xterm": { "version": "2.7.0", "from": "Tyriar/xterm.js#vscode-release/1.14", - "resolved": "git+https://github.com/Tyriar/xterm.js.git#e6fe120ecf93e552573be45867ae03c880319e11" + "resolved": "git+https://github.com/Tyriar/xterm.js.git#da7827f21505ae3d34f750bedbf17ad3f56e6f07" }, "yauzl": { "version": "2.3.1", -- GitLab From 484d69c984af2d5ed73f86fe5a417c0f121b7247 Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Sun, 18 Jun 2017 22:51:42 +0200 Subject: [PATCH 1011/1347] #27823 Fix size is not updated when header is toggled --- src/vs/base/browser/ui/splitview/splitview.ts | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/src/vs/base/browser/ui/splitview/splitview.ts b/src/vs/base/browser/ui/splitview/splitview.ts index 6b2a1d5b20d..7be647dd58b 100644 --- a/src/vs/base/browser/ui/splitview/splitview.ts +++ b/src/vs/base/browser/ui/splitview/splitview.ts @@ -407,6 +407,22 @@ export abstract class AbstractCollapsibleView extends HeaderView { this.updateSize(); } + showHeader(): boolean { + const result = super.showHeader(); + if (result) { + this.updateSize(); + } + return result; + } + + hideHeader(): boolean { + const result = super.hideHeader(); + if (result) { + this.updateSize(); + } + return result; + } + dispose(): void { if (this.headerClickListener) { this.headerClickListener.dispose(); -- GitLab From 0d360bae9156f6ab74a095ba71e8a86c67add4bc Mon Sep 17 00:00:00 2001 From: Sandeep Somavarapu Date: Sun, 18 Jun 2017 22:56:09 +0200 Subject: [PATCH 1012/1347] #27823 Prepare toggling views --- .../parts/debug/browser/debugViewlet.ts | 6 +- .../parts/files/browser/explorerViewlet.ts | 8 +- .../parts/files/browser/views/explorerView.ts | 6 +- .../files/browser/views/openEditorsView.ts | 2 +- src/vs/workbench/parts/views/browser/views.ts | 178 +++++++++++++----- 5 files changed, 141 insertions(+), 59 deletions(-) diff --git a/src/vs/workbench/parts/debug/browser/debugViewlet.ts b/src/vs/workbench/parts/debug/browser/debugViewlet.ts index a6af5531673..b8a38890344 100644 --- a/src/vs/workbench/parts/debug/browser/debugViewlet.ts +++ b/src/vs/workbench/parts/debug/browser/debugViewlet.ts @@ -21,6 +21,7 @@ import { IStorageService } from 'vs/platform/storage/common/storage'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { ViewLocation } from 'vs/workbench/parts/views/browser/viewsRegistry'; import { IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; +import { IContextMenuService } from 'vs/platform/contextview/browser/contextView'; export class DebugViewlet extends ComposedViewsViewlet { @@ -36,9 +37,10 @@ export class DebugViewlet extends ComposedViewsViewlet { @IWorkspaceContextService contextService: IWorkspaceContextService, @IStorageService storageService: IStorageService, @IThemeService themeService: IThemeService, - @IContextKeyService contextKeyService: IContextKeyService + @IContextKeyService contextKeyService: IContextKeyService, + @IContextMenuService contextMenuService: IContextMenuService ) { - super(VIEWLET_ID, ViewLocation.Debug, `${VIEWLET_ID}.state`, telemetryService, storageService, instantiationService, themeService, contextService, contextKeyService); + super(VIEWLET_ID, ViewLocation.Debug, `${VIEWLET_ID}.state`, telemetryService, storageService, instantiationService, themeService, contextService, contextKeyService, contextMenuService); this.progressRunner = null; diff --git a/src/vs/workbench/parts/files/browser/explorerViewlet.ts b/src/vs/workbench/parts/files/browser/explorerViewlet.ts index 43a1d644a1d..1bdd925c1d3 100644 --- a/src/vs/workbench/parts/files/browser/explorerViewlet.ts +++ b/src/vs/workbench/parts/files/browser/explorerViewlet.ts @@ -31,6 +31,7 @@ import { IEditorGroupService } from 'vs/workbench/services/group/common/groupSer import { IContextKeyService, IContextKey } from 'vs/platform/contextkey/common/contextkey'; import { IThemeService } from 'vs/platform/theme/common/themeService'; import { ViewsRegistry, ViewLocation, IViewDescriptor } from 'vs/workbench/parts/views/browser/viewsRegistry'; +import { IContextMenuService } from 'vs/platform/contextview/browser/contextView'; export class ExplorerViewlet extends ComposedViewsViewlet { @@ -50,9 +51,10 @@ export class ExplorerViewlet extends ComposedViewsViewlet { @IInstantiationService protected instantiationService: IInstantiationService, @IContextKeyService contextKeyService: IContextKeyService, @IConfigurationEditingService private configurationEditingService: IConfigurationEditingService, - @IThemeService themeService: IThemeService + @IThemeService themeService: IThemeService, + @IContextMenuService contextMenuService: IContextMenuService ) { - super(VIEWLET_ID, ViewLocation.Explorer, ExplorerViewlet.EXPLORER_VIEWS_STATE, telemetryService, storageService, instantiationService, themeService, contextService, contextKeyService); + super(VIEWLET_ID, ViewLocation.Explorer, ExplorerViewlet.EXPLORER_VIEWS_STATE, telemetryService, storageService, instantiationService, themeService, contextService, contextKeyService, contextMenuService); this.viewletState = new FileViewletState(); this.viewletVisibleContextKey = ExplorerViewletVisibleContext.bindTo(contextKeyService); @@ -105,7 +107,7 @@ export class ExplorerViewlet extends ComposedViewsViewlet { private createExplorerViewDescriptor(): IViewDescriptor { return { id: ExplorerView.ID, - name: '', + name: this.contextService.getWorkspace().name, location: ViewLocation.Explorer, ctor: ExplorerView, order: 1 diff --git a/src/vs/workbench/parts/files/browser/views/explorerView.ts b/src/vs/workbench/parts/files/browser/views/explorerView.ts index bbbae2286f2..64c9d8decb1 100644 --- a/src/vs/workbench/parts/files/browser/views/explorerView.ts +++ b/src/vs/workbench/parts/files/browser/views/explorerView.ts @@ -119,7 +119,7 @@ export class ExplorerView extends CollapsibleView { public renderHeader(container: HTMLElement): void { const titleDiv = $('div.title').appendTo(container); - $('span').text(this.contextService.getWorkspace().name).title(labels.getPathLabel(this.contextService.getWorkspace().resource.fsPath, void 0, this.environmentService)).appendTo(titleDiv); + $('span').text(this.name).title(labels.getPathLabel(this.contextService.getWorkspace().resource.fsPath, void 0, this.environmentService)).appendTo(titleDiv); super.renderHeader(container); } @@ -193,7 +193,7 @@ export class ExplorerView extends CollapsibleView { this.settings[ExplorerView.MEMENTO_LAST_ACTIVE_FILE_RESOURCE] = activeFile.toString(); // Select file if input is inside workspace - if (this.isVisible && this.contextService.isInsideWorkspace(activeFile)) { + if (this.isVisible() && this.contextService.isInsideWorkspace(activeFile)) { const selection = this.hasSelection(activeFile); if (!selection) { this.select(activeFile).done(null, errors.onUnexpectedError); @@ -627,7 +627,7 @@ export class ExplorerView extends CollapsibleView { } private refreshFromEvent(): void { - if (this.isVisible) { + if (this.isVisible()) { this.explorerRefreshDelayer.trigger(() => { if (!this.explorerViewer.getHighlight()) { return this.doRefresh(); diff --git a/src/vs/workbench/parts/files/browser/views/openEditorsView.ts b/src/vs/workbench/parts/files/browser/views/openEditorsView.ts index 2b1f079b929..47275415a09 100644 --- a/src/vs/workbench/parts/files/browser/views/openEditorsView.ts +++ b/src/vs/workbench/parts/files/browser/views/openEditorsView.ts @@ -207,7 +207,7 @@ export class OpenEditorsView extends CollapsibleView { } private onEditorStacksModelChanged(e: IStacksModelChangeEvent): void { - if (this.isDisposed || !this.isVisible || !this.tree) { + if (this.isDisposed || !this.isVisible() || !this.tree) { return; } diff --git a/src/vs/workbench/parts/views/browser/views.ts b/src/vs/workbench/parts/views/browser/views.ts index f263f1c7352..d9fbac64a26 100644 --- a/src/vs/workbench/parts/views/browser/views.ts +++ b/src/vs/workbench/parts/views/browser/views.ts @@ -12,9 +12,10 @@ import { $, Dimension, Builder } from 'vs/base/browser/builder'; import { Scope } from 'vs/workbench/common/memento'; import { dispose, IDisposable } from 'vs/base/common/lifecycle'; import { IAction, IActionRunner } from 'vs/base/common/actions'; -import { IActionItem, ActionsOrientation } from 'vs/base/browser/ui/actionbar/actionbar'; +import { IActionItem, ActionsOrientation, Separator } from 'vs/base/browser/ui/actionbar/actionbar'; +import { Registry } from 'vs/platform/platform'; import { prepareActions } from 'vs/workbench/browser/actions'; -import { Viewlet } from 'vs/workbench/browser/viewlet'; +import { Viewlet, ViewletRegistry, Extensions } from 'vs/workbench/browser/viewlet'; import { ITree } from 'vs/base/parts/tree/browser/tree'; import { DelayedDragHandler } from 'vs/base/browser/dnd'; import { ToolBar } from 'vs/base/browser/ui/toolbar/toolbar'; @@ -28,6 +29,7 @@ import { IInstantiationService } from 'vs/platform/instantiation/common/instanti import { IStorageService, StorageScope } from 'vs/platform/storage/common/storage'; import { IWorkspaceContextService } from 'vs/platform/workspace/common/workspace'; import { IContextKeyService } from 'vs/platform/contextkey/common/contextkey'; +import { StandardMouseEvent } from 'vs/base/browser/mouseEvent'; export interface IViewOptions { @@ -57,6 +59,8 @@ export interface IView extends IBaseView, IThemable { setVisible(visible: boolean): TPromise; + isVisible(): boolean; + getActions(): IAction[]; getSecondaryActions(): IAction[]; @@ -82,6 +86,8 @@ export interface IView extends IBaseView, IThemable { export interface ICollapsibleViewOptions extends IViewOptions { + ariaHeaderLabel?: string; + sizing: ViewSizing; initialBodySize?: number; @@ -96,11 +102,12 @@ export abstract class CollapsibleView extends AbstractCollapsibleView implements protected treeContainer: HTMLElement; protected tree: ITree; protected toDispose: IDisposable[]; - protected isVisible: boolean; protected toolBar: ToolBar; protected actionRunner: IActionRunner; protected isDisposed: boolean; + private _isVisible: boolean; + private dragHandler: DelayedDragHandler; constructor( @@ -109,7 +116,7 @@ export abstract class CollapsibleView extends AbstractCollapsibleView implements protected contextMenuService: IContextMenuService ) { super({ - ariaHeaderLabel: options.name, + ariaHeaderLabel: options.ariaHeaderLabel, sizing: options.sizing, bodySize: options.initialBodySize ? options.initialBodySize : 4 * 22, initialState: options.collapsed ? CollapsibleState.COLLAPSED : CollapsibleState.EXPANDED, @@ -166,9 +173,13 @@ export abstract class CollapsibleView extends AbstractCollapsibleView implements return this.tree; } + public isVisible(): boolean { + return this._isVisible; + } + public setVisible(visible: boolean): TPromise { - if (this.isVisible !== visible) { - this.isVisible = visible; + if (this._isVisible !== visible) { + this._isVisible = visible; this.updateTreeVisibility(this.tree, visible && this.state === CollapsibleState.EXPANDED); } @@ -279,6 +290,8 @@ interface IViewState { size: number; + isHidden: boolean; + } export class ComposedViewsViewlet extends Viewlet { @@ -303,7 +316,8 @@ export class ComposedViewsViewlet extends Viewlet { @IInstantiationService protected instantiationService: IInstantiationService, @IThemeService themeService: IThemeService, @IWorkspaceContextService protected contextService: IWorkspaceContextService, - @IContextKeyService protected contextKeyService: IContextKeyService + @IContextKeyService protected contextKeyService: IContextKeyService, + @IContextMenuService private contextMenuService: IContextMenuService ) { super(id, telemetryService, themeService); @@ -322,6 +336,7 @@ export class ComposedViewsViewlet extends Viewlet { this.viewletContainer = DOM.append(parent.getHTMLElement(), DOM.$('')); this.splitView = this._register(new SplitView(this.viewletContainer)); this._register(this.splitView.onFocus((view: IView) => this.lastFocusedView = view)); + this._register(DOM.addDisposableListener(this.viewletContainer, 'contextmenu', e => this.onContextMenu(new StandardMouseEvent(e)))); return this.onViewDescriptorsChanged() .then(() => { @@ -330,6 +345,14 @@ export class ComposedViewsViewlet extends Viewlet { }); } + public getTitle(): string { + let title = Registry.as(Extensions.Viewlets).getViewlet(this.getId()).name; + if (this.views.length === 1) { + title += ': ' + this.views[0].name; + } + return title; + } + public getActions(): IAction[] { if (this.views.length === 1) { return this.views[0].getActions(); @@ -338,15 +361,24 @@ export class ComposedViewsViewlet extends Viewlet { } public getSecondaryActions(): IAction[] { + let actions = []; if (this.views.length === 1) { - return this.views[0].getSecondaryActions(); + actions = this.views[0].getSecondaryActions(); } - return []; + + if (actions.length) { + actions.push(new Separator()); + } + + actions.push(...this.getToggleVisibilityActions(this.getViewDescriptorsFromRegistry())); + + return actions; } public setVisible(visible: boolean): TPromise { return super.setVisible(visible) - .then(() => TPromise.join(this.views.map((view) => view.setVisible(visible)))) + .then(() => TPromise.join(this.views.filter(view => view.isVisible() !== visible) + .map((view) => view.setVisible(visible)))) .then(() => void 0); } @@ -378,6 +410,39 @@ export class ComposedViewsViewlet extends Viewlet { super.shutdown(); } + private onContextMenu(event: StandardMouseEvent): void { + let anchor: { x: number, y: number } = { x: event.posx, y: event.posy }; + this.contextMenuService.showContextMenu({ + getAnchor: () => anchor, + getActions: () => TPromise.as(this.getSecondaryActions()), + }); + } + + private getToggleVisibilityActions(viewDescriptors: IViewDescriptor[]): IAction[] { + // return viewDescriptors.map(viewDescriptor => ({ + // id: `${viewDescriptor.id}.toggleVisibility`, + // label: viewDescriptor.name, + // checked: this.isCurrentlyVisible(viewDescriptor), + // enabled: this.contextKeyService.contextMatchesRules(viewDescriptor.when), + // run: () => this.toggleViewVisibility(viewDescriptor) + // })); + return []; + } + + protected toggleViewVisibility(viewDescriptor: IViewDescriptor): void { + const view = this.getView(viewDescriptor.id); + let viewState = this.viewsStates.get(viewDescriptor.id); + if (view) { + viewState = viewState || this.createViewState(view); + viewState.isHidden = true; + } else { + viewState = viewState || { collapsed: true, size: void 0, isHidden: false }; + viewState.isHidden = false; + } + this.viewsStates.set(viewDescriptor.id, viewState); + this.updateViews(); + } + private onViewDescriptorsChanged(): TPromise { this.viewsContextKeys.clear(); for (const viewDescriptor of this.getViewDescriptorsFromRegistry()) { @@ -391,6 +456,10 @@ export class ComposedViewsViewlet extends Viewlet { } private onContextChanged(keys: string[]): void { + if (!keys) { + return; + } + let hasToUpdate: boolean = false; for (const key of keys) { if (this.viewsContextKeys.has(key)) { @@ -412,7 +481,7 @@ export class ComposedViewsViewlet extends Viewlet { const registeredViews = this.getViewDescriptorsFromRegistry(); const [visible, toAdd, toRemove] = registeredViews.reduce<[IViewDescriptor[], IViewDescriptor[], IViewDescriptor[]]>((result, viewDescriptor) => { - const isCurrentlyVisible = !!this.getView(viewDescriptor.id); + const isCurrentlyVisible = this.isCurrentlyVisible(viewDescriptor); const canBeVisible = this.canBeVisible(viewDescriptor); if (canBeVisible) { @@ -431,51 +500,59 @@ export class ComposedViewsViewlet extends Viewlet { }, [[], [], []]); - if (!toAdd.length && !toRemove.length) { - return TPromise.as(null); - } + const toCreate = []; - for (const view of this.views) { - let viewState = this.viewsStates.get(view.id); - if (!viewState || view.size !== viewState.size || !view.isExpanded() !== viewState.collapsed) { - viewState = this.createViewState(view); - this.viewsStates.set(view.id, viewState); - this.splitView.updateWeight(view, viewState.size); + if (toAdd.length || toRemove.length) { + for (const view of this.views) { + let viewState = this.viewsStates.get(view.id); + if (!viewState || view.size !== viewState.size || !view.isExpanded() !== viewState.collapsed) { + viewState = { ...this.createViewState(view), isHidden: viewState && viewState.isHidden }; + this.viewsStates.set(view.id, viewState); + this.splitView.updateWeight(view, viewState.size); + } } - } - - if (toRemove.length) { - for (const viewDescriptor of toRemove) { - let view = this.getView(viewDescriptor.id); - this.views.splice(this.views.indexOf(view), 1); - this.splitView.removeView(view); + if (toRemove.length) { + for (const viewDescriptor of toRemove) { + let view = this.getView(viewDescriptor.id); + this.views.splice(this.views.indexOf(view), 1); + this.splitView.removeView(view); + if (this.lastFocusedView === view) { + this.lastFocusedView = null; + } + } } - } - - const toCreate = []; - - for (const viewDescriptor of toAdd) { - let viewState = this.viewsStates.get(viewDescriptor.id); - let index = visible.indexOf(viewDescriptor); - const view = this.createView(viewDescriptor, { - id: viewDescriptor.id, - name: viewDescriptor.name, - actionRunner: this.getActionRunner(), - collapsed: viewState ? viewState.collapsed : void 0, - viewletSettings: this.viewletSettings - }); - toCreate.push(view); - this.views.splice(index, 0, view); - attachHeaderViewStyler(view, this.themeService); - this.splitView.addView(view, viewState && viewState.size ? Math.max(viewState.size, 1) : viewDescriptor.size, index); + for (const viewDescriptor of toAdd) { + let viewState = this.viewsStates.get(viewDescriptor.id); + let index = visible.indexOf(viewDescriptor); + const view = this.createView(viewDescriptor, { + id: viewDescriptor.id, + name: viewDescriptor.name, + actionRunner: this.getActionRunner(), + collapsed: viewState ? viewState.collapsed : void 0, + viewletSettings: this.viewletSettings + }); + toCreate.push(view); + + this.views.splice(index, 0, view); + attachHeaderViewStyler(view, this.themeService); + this.splitView.addView(view, viewState && viewState.size ? Math.max(viewState.size, 1) : viewDescriptor.size, index); + } } return TPromise.join(toCreate.map(view => view.create())) .then(() => this.onViewsUpdated()); } + private isCurrentlyVisible(viewDescriptor: IViewDescriptor): boolean { + return !!this.getView(viewDescriptor.id); + } + private canBeVisible(viewDescriptor: IViewDescriptor): boolean { + const viewstate = this.viewsStates.get(viewDescriptor.id); + if (viewstate && viewstate.isHidden) { + return false; + } return this.contextKeyService.contextMatchesRules(viewDescriptor.when); } @@ -491,13 +568,13 @@ export class ComposedViewsViewlet extends Viewlet { } } + // Update title area since the title actions have changed. + this.updateTitleArea(); + if (this.dimension) { this.layout(this.dimension); } - // Update title area since the title actions have changed. - this.updateTitleArea(); - return this.setVisible(this.isVisible()); } @@ -519,7 +596,7 @@ export class ComposedViewsViewlet extends Viewlet { this.viewsStates.forEach((viewState, id) => { const view = this.getView(id); viewState = view ? this.createViewState(view) : viewState; - viewsStates[id] = { size: viewState.size, collapsed: viewState.collapsed }; + viewsStates[id] = { size: viewState.size, collapsed: viewState.collapsed, isHidden: viewState.isHidden }; }); this.storageService.store(this.viewletStateStorageId, JSON.stringify(viewsStates), this.contextService.hasWorkspace() ? StorageScope.WORKSPACE : StorageScope.GLOBAL); @@ -547,7 +624,8 @@ export class ComposedViewsViewlet extends Viewlet { const size = collapsed && view instanceof CollapsibleView ? view.previousSize : view.size; return { collapsed, - size: size && size > 0 ? size : void 0 + size: size && size > 0 ? size : void 0, + isHidden: false }; } } \ No newline at end of file -- GitLab From 47de9b40026079f3173164e7fdd8aa6d4749ddf0 Mon Sep 17 00:00:00 2001 From: Andre Weinand Date: Sun, 18 Jun 2017 23:42:20 +0200 Subject: [PATCH 1013/1347] node-debug@1.14.4 --- build/gulpfile.vscode.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js index 89cd47827bb..6f2846281f3 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -42,7 +42,7 @@ const nodeModules = ['electron', 'original-fs'] // Build const builtInExtensions = [ - { name: 'ms-vscode.node-debug', version: '1.14.3' }, + { name: 'ms-vscode.node-debug', version: '1.14.4' }, { name: 'ms-vscode.node-debug2', version: '1.14.0' } ]; -- GitLab From fadd172c541486ba1a616723568f1924df5cc742 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Sun, 18 Jun 2017 23:15:38 -0700 Subject: [PATCH 1014/1347] Avoid emmet expansion inside html tag and css selectors. Fixes #28829 --- .../emmet/src/emmetCompletionProvider.ts | 30 ++++++++++++++++--- 1 file changed, 26 insertions(+), 4 deletions(-) diff --git a/extensions/emmet/src/emmetCompletionProvider.ts b/extensions/emmet/src/emmetCompletionProvider.ts index 3ba492bbf12..6a7bf6d89b2 100644 --- a/extensions/emmet/src/emmetCompletionProvider.ts +++ b/extensions/emmet/src/emmetCompletionProvider.ts @@ -6,7 +6,11 @@ import * as vscode from 'vscode'; import { expand, createSnippetsRegistry } from '@emmetio/expand-abbreviation'; -import { getSyntax, getProfile, extractAbbreviation, isStyleSheet } from './util'; +import { getSyntax, getProfile, extractAbbreviation, isStyleSheet, getNode } from './util'; +import parseStylesheet from '@emmetio/css-parser'; +import parse from '@emmetio/html-matcher'; +import Node from '@emmetio/node'; +import { DocumentStreamReader } from './bufferStream'; const field = (index, placeholder) => `\${${index}${placeholder ? ':' + placeholder : ''}}`; const snippetCompletionsCache = new Map(); @@ -22,7 +26,11 @@ export class EmmetCompletionItemProvider implements vscode.CompletionItemProvide let completionItems: vscode.CompletionItem[] = []; let syntax = getSyntax(document); let currentWord = getCurrentWord(document, position); - let expandedAbbr = this.getExpandedAbbreviation(document, position); + + let parseContent = isStyleSheet(syntax) ? parseStylesheet : parse; + let rootNode: Node = parseContent(new DocumentStreamReader(document)); + let currentNode = getNode(rootNode, position); + let expandedAbbr = this.getExpandedAbbreviation(document, position, syntax, currentNode); if (!isStyleSheet(syntax)) { if (expandedAbbr) { @@ -39,7 +47,7 @@ export class EmmetCompletionItemProvider implements vscode.CompletionItemProvide return Promise.resolve(new vscode.CompletionList(completionItems, true)); } - getExpandedAbbreviation(document: vscode.TextDocument, position: vscode.Position): vscode.CompletionItem { + getExpandedAbbreviation(document: vscode.TextDocument, position: vscode.Position, syntax: string, currentNode: Node): vscode.CompletionItem { if (!vscode.workspace.getConfiguration('emmet')['showExpandedAbbreviation']) { return; } @@ -47,7 +55,10 @@ export class EmmetCompletionItemProvider implements vscode.CompletionItemProvide if (!rangeToReplace || !wordToExpand) { return; } - let syntax = getSyntax(document); + if (!isValidLocationForEmmetAbbreviation(currentNode, syntax, position)) { + return; + } + let expandedWord = expand(wordToExpand, { field: field, syntax: syntax, @@ -114,6 +125,17 @@ function removeTabStops(expandedWord: string): string { return expandedWord.replace(/\$\{\d+\}/g, '').replace(/\$\{\d+:([^\}]+)\}/g, '$1'); } +function isValidLocationForEmmetAbbreviation(currentNode: Node, syntax: string, position: vscode.Position): boolean { + if (!currentNode) { + return true; + } + + if (isStyleSheet(syntax)) { + return currentNode.type !== 'rule'; + } + + return position.isAfter(currentNode.open.end); +} -- GitLab From 6757e57fe839b51597ec344e89696b72e98ec379 Mon Sep 17 00:00:00 2001 From: Ramya Achutha Rao Date: Sun, 18 Jun 2017 23:16:20 -0700 Subject: [PATCH 1015/1347] Use css abbreviations inside html style block. Fixes #28039 --- extensions/emmet/src/emmetCompletionProvider.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/extensions/emmet/src/emmetCompletionProvider.ts b/extensions/emmet/src/emmetCompletionProvider.ts index 6a7bf6d89b2..06d6e55dc2b 100644 --- a/extensions/emmet/src/emmetCompletionProvider.ts +++ b/extensions/emmet/src/emmetCompletionProvider.ts @@ -30,6 +30,12 @@ export class EmmetCompletionItemProvider implements vscode.CompletionItemProvide let parseContent = isStyleSheet(syntax) ? parseStylesheet : parse; let rootNode: Node = parseContent(new DocumentStreamReader(document)); let currentNode = getNode(rootNode, position); + + // Inside